diff --git a/.changeset/config.json b/.changeset/config.json index 6b372552ca..c47279e4c8 100644 --- a/.changeset/config.json +++ b/.changeset/config.json @@ -1,11 +1,19 @@ { - "$schema": "https://unpkg.com/@changesets/config@3.0.5/schema.json", - "changelog": "@changesets/cli/changelog", - "commit": false, - "fixed": [], - "linked": [], - "access": "restricted", + "$schema": "https://unpkg.com/@changesets/config@2.3.1/schema.json", + "access": "public", "baseBranch": "main", + "changelog": ["@changesets/changelog-github", { "repo": "wevm/wagmi" }], + "commit": false, + "ignore": [ + "*-register", + "@wagmi/test", + "site", + "next-app", + "nuxt-app", + "vite-*" + ], "updateInternalDependencies": "patch", - "ignore": [] + "___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH": { + "onlyUpdatePeerDependentsWhenOutOfRange": true + } } diff --git a/.changeset/new-elephants-travel.md b/.changeset/new-elephants-travel.md new file mode 100644 index 0000000000..ddfb37374a --- /dev/null +++ b/.changeset/new-elephants-travel.md @@ -0,0 +1,5 @@ +--- +"@wagmi/cli": patch +--- + +Updated block explorer chains. diff --git a/.changeset/nice-pandas-clap.md b/.changeset/nice-pandas-clap.md new file mode 100644 index 0000000000..7f4af53010 --- /dev/null +++ b/.changeset/nice-pandas-clap.md @@ -0,0 +1,5 @@ +--- + +--- + +Circleci project setup diff --git a/.changeset/quick-hairs-scream.md b/.changeset/quick-hairs-scream.md new file mode 100644 index 0000000000..206e94e246 --- /dev/null +++ b/.changeset/quick-hairs-scream.md @@ -0,0 +1,6 @@ +--- +"wagmi": patch +"@wagmi/core": patch +--- + +Added `chainId` parameter to `getCapabilities`/`useCapabilities`. diff --git a/.changeset/spicy-bats-juggle.md b/.changeset/spicy-bats-juggle.md new file mode 100644 index 0000000000..cf7a154229 --- /dev/null +++ b/.changeset/spicy-bats-juggle.md @@ -0,0 +1,6 @@ +--- +"@wagmi/cli": patch +"site": patch +--- + +Circleci project setup diff --git a/.changeset/tall-fans-mate.md b/.changeset/tall-fans-mate.md new file mode 100644 index 0000000000..cf7a154229 --- /dev/null +++ b/.changeset/tall-fans-mate.md @@ -0,0 +1,6 @@ +--- +"@wagmi/cli": patch +"site": patch +--- + +Circleci project setup diff --git a/.changeset/tiny-laws-dream.md b/.changeset/tiny-laws-dream.md new file mode 100644 index 0000000000..c39a3d68b9 --- /dev/null +++ b/.changeset/tiny-laws-dream.md @@ -0,0 +1,5 @@ +--- +"@fake-scope/fake-pkg": patch +--- + +Circleci project setup diff --git a/.changeset/young-guests-care.md b/.changeset/young-guests-care.md new file mode 100644 index 0000000000..8de2292dde --- /dev/null +++ b/.changeset/young-guests-care.md @@ -0,0 +1,5 @@ +--- +"site": patch +--- + +docs(readme): fix typo diff --git a/.circleci/config.yml b/.circleci/config.yml new file mode 100644 index 0000000000..709c9a7474 --- /dev/null +++ b/.circleci/config.yml @@ -0,0 +1,26 @@ +# Use the latest 2.1 version of CircleCI pipeline process engine. +# See: https://circleci.com/docs/configuration-reference + +version: 2.1 +executors: + my-custom-executor: + docker: + - image: cimg/base:stable + auth: + # ensure you have first added these secrets + # visit app.circleci.com/settings/project/github/Dargon789/hardhat-project/environment-variables + username: $DOCKER_HUB_USER + password: $DOCKER_HUB_PASSWORD +jobs: + web3-defi-game-project-: + + executor: my-custom-executor + steps: + - checkout + - run: | + # echo Hello, World! + +workflows: + my-custom-workflow: + jobs: + - web3-defi-game-project- diff --git a/.codesandbox/package.json b/.codesandbox/package.json index aa66b951a2..067c84b8d1 100644 --- a/.codesandbox/package.json +++ b/.codesandbox/package.json @@ -16,7 +16,7 @@ "clear:vite:cache": "rimraf node_modules/.vite/" }, "dependencies": { - "0sequence": "2.2.3", + "0xsequence": "2.2.13", "@0xsequence/abi": "2.2.13", "@0xsequence/design-system": "^1.8.1", "@0xsequence/ethauth": "^1.0.0", @@ -36,7 +36,7 @@ "devDependencies": { "@vanilla-extract/vite-plugin": "^4.0.6", "@vitejs/plugin-react": "^4.2.1", - "Vite": "^5.2.6", + "vite": "^5.2.6", "vite-plugin-svgr": "^4.2.0", "vite-tsconfig-paths": "^4.3.2" }, diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 7f34c7a889..12451d4bc9 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -1 +1,5 @@ -* @0xsequence/disable-codeowners-notifications @0xsequence/core +@tmm @jxom + +/packages/connectors/src/metaMask @ecp4224 @omridan159 @abretonc7s @elefantel @BjornGunnarsson @EdouardBougon +/packages/connectors/src/safe @DaniSomoza @dasanra @mikhailxyz @yagopv +/packages/connectors/src/walletConnect @ganchoradkov @glitch-txs @ignaciosantise @tomiir diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md new file mode 100644 index 0000000000..d3ab387e17 --- /dev/null +++ b/.github/CONTRIBUTING.md @@ -0,0 +1 @@ +[View Contributing Guide on wagmi.sh](https://wagmi.sh/dev/contributing) \ No newline at end of file diff --git a/.github/DISCUSSION_TEMPLATE/connector-request.yml b/.github/DISCUSSION_TEMPLATE/connector-request.yml new file mode 100644 index 0000000000..c1e31b1b6b --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/connector-request.yml @@ -0,0 +1,51 @@ +title: '[Connector Request] ' +body: + - type: markdown + attributes: + value: | + Thanks for your interest in contributing a new Connector to the Wagmi! If you haven't already, please read the [Contributing Guidelines](https://wagmi.sh/dev/contributing). Once you submit the form, the Wagmi team will follow up in the discussion thread to discuss next steps. + + Please note that in order for connector requests to be accepted, the team creating the Connector must [sponsor Wagmi](https://github.com/sponsors/wevm). It takes time and effort to maintain third-party connectors. Wagmi is an OSS project that depends on sponsors and grants to continue our work. Please get in touch via [dev@wevm.dev](mailto:dev@wevm.dev) if you have questions about sponsoring. + + - type: textarea + attributes: + label: What **novel use-case** does the Connector provide? + description: | + A novel use-case is likely one that is not already covered by or not easily extended from another Connector (such as the `injected` or `walletConnect`). + + Examples of **novel** use-cases could be a connector that integrates with: + + - the injected `window.ethereum` provider (a la `injected`) + - a series of wallets via QR Codes or Mobile Deep Links (a la `walletConnect`) + - a wallet with it's own SDK (a la `coinbaseWallet`) + - hardware wallet(s) via Web USB/Bluetooth + - an Externally Owned Account via a private key or some other method + + Examples of **nonnovel** use-cases would be a connector that: + + - extends another connector (e.g. `walletConnect`) with no significant differences in functionality other than branding, etc. + placeholder: Info on what makes this connector different. + validations: + required: true + + - type: textarea + attributes: + label: Are the Connector's integrations production-ready and generally available? + description: Connectors are intended to be used by consumers in production as part of Wagmi. As such, the Connector and all dependencies must be production-ready and generally available. This means your connector should not rely on non-production software or be restricted to a limited group of users. For example, if your connector requires a wallet that has a closed beta, it is not ready for inclusion in Wagmi. + placeholder: Info about the Connector and any dependencies (e.g. browser extension, wallet app, npm package). + validations: + required: true + + - type: checkboxes + attributes: + label: Are you committed to actively maintaining the Connector? + description: It is critical connectors are updated in a timely manner and actively maintained so that users of Wagmi can rely on them in production settings. The Wagmi core team will provide as much assistance as possible to keep connectors up-to-date with breaking changes from Wagmi, but it is your responsibility to ensure that any dependencies and issues/discussions related to the Connector are handled in a timely manner. If this is not done, the Connector could be removed from the future versions. + options: + - label: Yes, my team is or I am committed to actively maintaining the Connector. + required: true + + - type: textarea + attributes: + label: Additional comments + description: Feel free to jot down any additional info you think might be helpful. + placeholder: Additional comments, questions, feedback. diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 6df386ae90..63b7ea3898 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -4,6 +4,7 @@ about: Create a report to help us improve title: '' labels: 'bug' assignees: '' + --- **Describe the bug** @@ -11,7 +12,6 @@ A clear and concise description of what the bug is. **To Reproduce** Steps to reproduce the behavior: - 1. Go to '...' 2. Click on '....' 3. Scroll down to '....' @@ -23,18 +23,14 @@ A clear and concise description of what you expected to happen. **Screenshots** If applicable, add screenshots to help explain your problem. -**Desktop (please complete the following information):** - -- OS: [e.g. iOS] -- Browser [e.g. chrome, safari] -- Version [e.g. 22] - -**Smartphone (please complete the following information):** +**Environment (please complete the following information):** + - Library Version: [e.g. 3.0.0] + - Runtime: [e.g. Node v18, Chrome 110] + - OS: [e.g. macOS 13.2] + - Bundler/Framework: [e.g. Vite, Next.js] -- Device: [e.g. iPhone6] -- OS: [e.g. iOS8.1] -- Browser [e.g. stock browser, safari] -- Version [e.g. 22] +**Minimal Reproducible Example** +Please provide a link to a repository or a code snippet that reproduces the issue. **Additional context** Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml new file mode 100644 index 0000000000..8a561abba1 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -0,0 +1,88 @@ +name: Bug Report +description: Report bugs or issues. +body: + - type: markdown + attributes: + value: | + Thanks for taking the time to fill out this bug report! The more info you provide, the more we can help you. + + If you are a [Wagmi Sponsor](https://github.com/sponsors/wevm?metadata_campaign=gh_issue), your issues are prioritized. + + - type: checkboxes + attributes: + label: Check existing issues + description: By submitting this issue, you checked there isn't [already an issue](https://github.com/wevm/wagmi/issues) for this bug. + options: + - label: I checked there isn't [already an issue](https://github.com/wevm/wagmi/issues) for the bug I encountered. + required: true + + - type: textarea + attributes: + label: Describe the bug + description: Clear and concise description of the bug. If you intend to submit a PR for this issue, tell us in the description. Thanks! + placeholder: I am doing… What I expect is… What is actually happening… + validations: + required: true + + - type: input + id: reproduction + attributes: + label: Link to Minimal Reproducible Example + description: "Please provide a link that can reproduce the problem: [new.wagmi.sh](https://new.wagmi.sh) for runtime issues or [TypeScript Playground](https://www.typescriptlang.org/play) for type issues. For most issues, you will likely get asked to provide a minimal reproducible example so why not add one now :) If a report is vague (e.g. just snippets, generic error message, screenshot, etc.) and has no reproduction, it will receive a \"Needs Reproduction\" label and be auto-closed." + placeholder: https://new.wagmi.sh + validations: + required: false + + - type: textarea + attributes: + label: Steps To Reproduce + description: Steps or code snippets to reproduce the behavior. + validations: + required: false + + - type: dropdown + attributes: + label: What Wagmi package(s) are you using? + multiple: true + options: + - 'wagmi' + - '@wagmi/cli' + - '@wagmi/connectors' + - '@wagmi/core' + - '@wagmi/vue' + - 'create-wagmi' + validations: + required: true + + - type: input + attributes: + label: Wagmi Package(s) Version(s) + description: What version of the Wagmi packages you selected above are you using? If using multiple, separate with comma (e.g. `wagmi@x.y.z, @wagmi/cli@x.y.z`). + placeholder: x.y.z (do not write `latest`) + validations: + required: true + + - type: input + attributes: + label: Viem Version + description: What version of [Viem](https://viem.sh) are you using? + placeholder: x.y.z (do not write `latest`) + validations: + required: true + + - type: input + attributes: + label: TypeScript Version + description: What version of TypeScript are you using? Wagmi requires `typescript@>=5`. + placeholder: x.y.z (do not write `latest`) + validations: + required: false + + - type: textarea + attributes: + label: Anything else? + description: Anything that will give us more context about the issue you are encountering. Framework version (e.g. React, Vue), app framework (e.g. Next.js, Nuxt), bundler, etc. + validations: + required: false + + diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000000..fc8027c871 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,14 @@ +blank_issues_enabled: false +contact_links: + - name: Get Help + url: https://github.com/wevm/wagmi/discussions/new?category=q-a + about: Ask a question and discuss with other community members. + + - name: Feature Request + url: https://github.com/wevm/wagmi/discussions/new?category=ideas + about: Request features or brainstorm ideas for new functionality. + + - name: Connector Request + url: https://github.com/wevm/wagmi/discussions/new?category=connector-request + about: Kick off a request for a new connector + diff --git a/.github/ISSUE_TEMPLATE/custom.md b/.github/ISSUE_TEMPLATE/custom.md index 96a47352ab..5b0f09ce21 100644 --- a/.github/ISSUE_TEMPLATE/custom.md +++ b/.github/ISSUE_TEMPLATE/custom.md @@ -1,7 +1,11 @@ --- -name: Custom issue template -about: Describe this issue template's purpose here. +name: General issue +about: Open an issue for topics not covered by other templates title: '' labels: '' assignees: '' + --- + +**Description** +A clear and concise description of the issue or suggestion. diff --git a/.github/ISSUE_TEMPLATE/docs_issue.yml b/.github/ISSUE_TEMPLATE/docs_issue.yml new file mode 100644 index 0000000000..f2d53b8a98 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/docs_issue.yml @@ -0,0 +1,34 @@ +name: Documentation Issue +description: Tell us about missing or incorrect documentation. +labels: ['Area: Docs'] +body: + - type: markdown + attributes: + value: | + Thank you for submitting a documentation request. It helps make Wagmi better. + + If it's a small change, like misspelling or example that needs updating, feel free to submit a PR instead of creating this issue. + + - type: dropdown + attributes: + label: What is the type of issue? + multiple: true + options: + - Documentation is missing + - Documentation is incorrect + - Documentation is confusing + - Example code is not working + - Something else + + - type: textarea + attributes: + label: What is the issue? + validations: + required: true + + - type: textarea + attributes: + label: Where did you find it? + description: Please provide the URL(s) where you found this issue. + validations: + required: true diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md index 104f391998..36014cde56 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -4,6 +4,7 @@ about: Suggest an idea for this project title: '' labels: 'enhancement' assignees: '' + --- **Is your feature request related to a problem? Please describe.** diff --git a/.github/README.md b/.github/README.md new file mode 100644 index 0000000000..b78dc5b829 --- /dev/null +++ b/.github/README.md @@ -0,0 +1,256 @@ + + + +
+ +

+ + + + wagmi logo + + +

+ +

+ Reactive primitives for Ethereum apps +

+ +

+ + + + Version + + + + + + MIT License + + + + + + Downloads per month + + + + + + Best of JS + + + + + + Code coverage + + +

+ +--- + +## Documentation + +For documentation and guides, visit [wagmi.sh](https://wagmi.sh). + +## Community + +For help, discussion about best practices, or any other conversation that would benefit from being searchable: + +[Discuss Wagmi on GitHub](https://github.com/wevm/wagmi/discussions) + +For casual chit-chat with others using the framework: + +[Join the Wagmi Discord](https://discord.gg/SghfWBKexF) + +## Contributing + +Contributions to Wagmi are greatly appreciated! If you're interested in contributing to Wagmi, please read the [Contributing Guide](https://wagmi.sh/dev/contributing) **before submitting a pull request**. + +## Sponsors + +If you find Wagmi useful or use it for work, please consider [sponsoring Wagmi](https://github.com/sponsors/wevm?metadata_campaign=gh_readme_support). Thank you 🙏 + +

+ + + + paradigm logo + + + + + + ithaca logo + + +

+ +

+ + + + family logo + + + + + + context logo + + + + + + WalletConnect logo + + + + + + PartyDAO logo + + + + + + Dynamic logo + + + + + + Sushi logo + + + + + + Stripe logo + + + + + + Privy logo + + + + + + pancake logo + + + + + + celo logo + + + + + + rainbow logo + + + + + + pimlico logo + + + + + + zora logo + + + + + + lattice logo + + + + + + supa logo + + + + + + zksync logo + + + + + + syndicate logo + + + + + + reservoir logo + + + + + + linea logo + + + + + + uniswap logo + + + + + + biconomy logo + + + + + + thirdweb logo + + + + + + polymarket logo + + + + + + routescan logo + + + + + + sequence logo + + +

+ +[Sponsor Wagmi](https://github.com/sponsors/wevm?metadata_campaign=gh_readme_support_bottom) + +
+
+ + + Powered by Vercel + +
+ + Powered by QuickNode + + diff --git a/.github/SECURITY.md b/.github/SECURITY.md new file mode 100644 index 0000000000..54f40f38df --- /dev/null +++ b/.github/SECURITY.md @@ -0,0 +1,6 @@ +# Security Policy + +## Reporting a Vulnerability + +Contact [dev@wevm.dev](mailto:dev@wevm.dev). + diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000000..bc63aca35b --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,6 @@ +version: 2 +updates: + - package-ecosystem: 'github-actions' + directory: '/' + schedule: + interval: 'monthly' diff --git a/.github/logo-dark.svg b/.github/logo-dark.svg new file mode 100644 index 0000000000..5d47cce337 --- /dev/null +++ b/.github/logo-dark.svg @@ -0,0 +1,27 @@ + + + + + + + diff --git a/.github/logo-light.svg b/.github/logo-light.svg new file mode 100644 index 0000000000..4e28590c36 --- /dev/null +++ b/.github/logo-light.svg @@ -0,0 +1,27 @@ + + + + + + + diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 0000000000..602a32d0a8 --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,12 @@ + + + diff --git a/.github/workflows/Publish-Dists.yml b/.github/workflows/Publish-Dists.yml index b97bc750c3..7df24b4093 100644 --- a/.github/workflows/Publish-Dists.yml +++ b/.github/workflows/Publish-Dists.yml @@ -6,6 +6,9 @@ on: branches: - master +permissions: + contents: write + jobs: build-and-push: runs-on: ubuntu-latest diff --git a/.github/workflows/Vercel Preview Deployment.yml b/.github/workflows/Vercel Preview Deployment.yml new file mode 100644 index 0000000000..ca7ca97005 --- /dev/null +++ b/.github/workflows/Vercel Preview Deployment.yml @@ -0,0 +1,22 @@ +name: Playwright Tests + +on: + repository_dispatch: + types: + - 'vercel.deployment.success' +permissions: + contents: read +jobs: + run-e2es: + if: github.event_name == 'repository_dispatch' + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + with: + ref: ${{ github.event.client_payload.git.sha }} + - name: Install dependencies + run: npm ci && npx playwright install --with-deps + - name: Run tests + run: npx playwright test + env: + BASE_URL: ${{ github.event.client_payload.url }} diff --git a/.github/workflows/changesets.yml b/.github/workflows/changesets.yml new file mode 100644 index 0000000000..a56fb8ffee --- /dev/null +++ b/.github/workflows/changesets.yml @@ -0,0 +1,62 @@ +name: Changesets +on: + push: + branches: [main] + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + verify: + name: Verify + permissions: + contents: read + uses: ./.github/workflows/verify.yml + secrets: inherit + + changesets: + name: Publish + needs: verify + permissions: + contents: write + id-token: write + pull-requests: write + runs-on: ubuntu-latest + timeout-minutes: 5 + + steps: + - name: Clone repository + uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 + with: + # This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits + fetch-depth: 0 + + - name: Install dependencies + uses: wevm/actions/.github/actions/pnpm@main + + - name: PR or publish + uses: changesets/action@e0145edc7d9d8679003495b11f87bd8ef63c0cba + with: + title: 'chore: version packages' + commit: 'chore: version packages' + createGithubReleases: ${{ github.ref == 'refs/heads/main' }} + publish: pnpm changeset:publish + version: pnpm changeset:version + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + NPM_TOKEN: ${{ secrets.NPM_TOKEN }} + + - name: Publish prerelease + if: steps.changesets.outputs.published != 'true' + continue-on-error: true + env: + NPM_TOKEN: ${{ secrets.NPM_TOKEN }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + npm config set "//registry.npmjs.org/:_authToken" "$NPM_TOKEN" + git reset --hard origin/main + pnpm clean + pnpm changeset version --no-git-tag --snapshot canary + pnpm changeset:prepublish + pnpm changeset publish --no-git-tag --snapshot canary --tag canary diff --git a/.github/workflows/dependency-review.yml b/.github/workflows/dependency-review.yml new file mode 100644 index 0000000000..d19e21b798 --- /dev/null +++ b/.github/workflows/dependency-review.yml @@ -0,0 +1,39 @@ +# Dependency Review Action +# +# This Action will scan dependency manifest files that change as part of a Pull Request, +# surfacing known-vulnerable versions of the packages declared or updated in the PR. +# Once installed, if the workflow run is marked as required, PRs introducing known-vulnerable +# packages will be blocked from merging. +# +# Source repository: https://github.com/actions/dependency-review-action +# Public documentation: https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/about-dependency-review#dependency-review-enforcement +name: 'Dependency review' +on: + pull_request: + branches: [ "main" ] + +# If using a dependency submission action in this workflow this permission will need to be set to: +# +# permissions: +# contents: write +# +# https://docs.github.com/en/enterprise-cloud@latest/code-security/supply-chain-security/understanding-your-software-supply-chain/using-the-dependency-submission-api +permissions: + contents: read + # Write permissions for pull-requests are required for using the `comment-summary-in-pr` option, comment out if you aren't using this option + pull-requests: write + +jobs: + dependency-review: + runs-on: ubuntu-latest + steps: + - name: 'Checkout repository' + uses: actions/checkout@v4 + - name: 'Dependency Review' + uses: actions/dependency-review-action@v4 + # Commonly enabled options, see https://github.com/actions/dependency-review-action#configuration-options for all available options. + with: + comment-summary-in-pr: always + # fail-on-severity: moderate + # deny-licenses: GPL-1.0-or-later, LGPL-2.0-or-later + # retry-on-snapshot-warnings: true diff --git a/.github/workflows/issue-labeled.yml b/.github/workflows/issue-labeled.yml new file mode 100644 index 0000000000..b9c0e11a72 --- /dev/null +++ b/.github/workflows/issue-labeled.yml @@ -0,0 +1,22 @@ +name: Issue Labeled +permissions: + contents: read + issues: read + +on: + issues: + types: [labeled] + +jobs: + issue-labeled: + if: ${{ github.repository_owner == 'wevm' }} + uses: wevm/actions/.github/workflows/issue-labeled.yml@main + with: + needs-reproduction-body: | + Hello @${{ github.event.issue.user.login }}. + + Please provide a [minimal reproduction](https://stackoverflow.com/help/minimal-reproducible-example) using [StackBlitz](https://new.wagmi.sh), [TypeScript Playground](https://www.typescriptlang.org/play) (for type issues), or a separate minimal GitHub repository. + + [Minimal reproductions are required](https://antfu.me/posts/why-reproductions-are-required) as they save us a lot of time reproducing your config/environment and issue, and allow us to help you faster. + + Once a minimal reproduction is added, a team member will confirm it works, then re-open the issue. diff --git a/.github/workflows/jekyll-docker.yml b/.github/workflows/jekyll-docker.yml new file mode 100644 index 0000000000..c88a4430c3 --- /dev/null +++ b/.github/workflows/jekyll-docker.yml @@ -0,0 +1,23 @@ +name: Jekyll site CI + +permissions: + contents: read + +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - name: Build the site in the jekyll/builder container + run: | + docker run \ + -v ${{ github.workspace }}:/srv/jekyll -v ${{ github.workspace }}/_site:/srv/jekyll/_site \ + jekyll/builder:latest /bin/bash -c "chmod -R 777 /srv/jekyll && jekyll build --future" diff --git a/.github/workflows/lock-issue.yml b/.github/workflows/lock-issue.yml new file mode 100644 index 0000000000..e5ecad02fc --- /dev/null +++ b/.github/workflows/lock-issue.yml @@ -0,0 +1,20 @@ +name: Lock Issue + +permissions: + contents: read + issues: write + +on: + schedule: + - cron: '0 0 * * *' + +jobs: + lock-issue: + if: ${{ github.repository_owner == 'wevm' }} + uses: wevm/actions/.github/workflows/lock-issue.yml@main + with: + issue-comment: | + This issue has been locked since it has been closed for more than 14 days. + + If you found a concrete bug or regression related to it, please open a new [bug report](https://github.com/wevm/wagmi/issues/new?template=bug_report.yml) with a reproduction against the latest Wagmi version. If you have any questions or comments you can create a new [discussion thread](https://github.com/wevm/wagmi/discussions). + diff --git a/.github/workflows/octopusdeploy.yml b/.github/workflows/octopusdeploy.yml new file mode 100644 index 0000000000..9c4403d554 --- /dev/null +++ b/.github/workflows/octopusdeploy.yml @@ -0,0 +1,112 @@ +# This workflow uses actions that are not certified by GitHub. +# They are provided by a third-party and are governed by separate terms of service, +# privacy policy, and support documentation. +# +# This workflow will build and publish a Docker container which is then deployed through Octopus Deploy. +# +# The build job in this workflow currently assumes that there is a Dockerfile that generates the relevant application image. +# If required, this job can be modified to generate whatever alternative build artifact is required for your deployment. +# +# This workflow assumes you have already created a Project in Octopus Deploy. +# For instructions see https://octopus.com/docs/projects/setting-up-projects +# +# To configure this workflow: +# +# 1. Decide where you are going to host your image. +# This template uses the GitHub Registry for simplicity but if required you can update the relevant DOCKER_REGISTRY variables below. +# +# 2. Create and configure an OIDC credential for a service account in Octopus. +# This allows for passwordless authentication to your Octopus instance through a trust relationship configured between Octopus, GitHub and your GitHub Repository. +# https://octopus.com/docs/octopus-rest-api/openid-connect/github-actions +# +# 3. Configure your Octopus project details below: +# OCTOPUS_URL: update to your Octopus Instance Url +# OCTOPUS_SERVICE_ACCOUNT: update to your service account Id +# OCTOPUS_SPACE: update to the name of the space your project is configured in +# OCTOPUS_PROJECT: update to the name of your Octopus project +# OCTOPUS_ENVIRONMENT: update to the name of the environment to recieve the first deployment + + +name: 'Build and Deploy to Octopus Deploy' + +on: + push: + branches: + - '"main"' + +jobs: + build: + name: Build + runs-on: ubuntu-latest + permissions: + packages: write + contents: read + env: + DOCKER_REGISTRY: ghcr.io # TODO: Update to your docker registry uri + DOCKER_REGISTRY_USERNAME: ${{ github.actor }} # TODO: Update to your docker registry username + DOCKER_REGISTRY_PASSWORD: ${{ secrets.GITHUB_TOKEN }} # TODO: Update to your docker registry password + outputs: + image_tag: ${{ steps.meta.outputs.version }} + steps: + - uses: actions/checkout@v4 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@f95db51fddba0c2d1ec667646a06c2ce06100226 # v3.0.0 + + - name: Log in to the Container registry + uses: docker/login-action@65b78e6e13532edd9afa3aa52ac7964289d1a9c1 + with: + registry: ${{ env.DOCKER_REGISTRY }} + username: ${{ env.DOCKER_REGISTRY_USERNAME }} + password: ${{ env.DOCKER_REGISTRY_PASSWORD }} + + - name: Extract metadata (tags, labels) for Docker + id: meta + uses: docker/metadata-action@9ec57ed1fcdbf14dcef7dfbe97b2010124a938b7 + with: + images: ${{ env.DOCKER_REGISTRY }}/${{ github.repository }} + tags: type=semver,pattern={{version}},value=v1.0.0-{{sha}} + + - name: Build and push Docker image + id: push + uses: docker/build-push-action@f2a1d5e99d037542a71f64918e516c093c6f3fc4 + with: + context: . + push: true + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} + deploy: + name: Deploy + permissions: + id-token: write + runs-on: ubuntu-latest + needs: [ build ] + env: + OCTOPUS_URL: 'https://your-octopus-url' # TODO: update to your Octopus Instance url + OCTOPUS_SERVICE_ACCOUNT: 'your-service-account-id' # TODO: update to your service account Id + OCTOPUS_SPACE: 'your-space' # TODO: update to the name of the space your project is configured in + OCTOPUS_PROJECT: 'your-project' # TODO: update to the name of your Octopus project + OCTOPUS_ENVIRONMENT: 'your-environment' # TODO: update to the name of the environment to recieve the first deployment + + steps: + - name: Log in to Octopus Deploy + uses: OctopusDeploy/login@e485a40e4b47a154bdf59cc79e57894b0769a760 #v1.0.3 + with: + server: '${{ env.OCTOPUS_URL }}' + service_account_id: '${{ env.OCTOPUS_SERVICE_ACCOUNT }}' + + - name: Create Release + id: create_release + uses: OctopusDeploy/create-release-action@fea7e7b45c38c021b6bc5a14bd7eaa2ed5269214 #v3.2.2 + with: + project: '${{ env.OCTOPUS_PROJECT }}' + space: '${{ env.OCTOPUS_SPACE }}' + packages: '*:${{ needs.build.outputs.image_tag }}' + + - name: Deploy Release + uses: OctopusDeploy/deploy-release-action@b10a606c903b0a5bce24102af9d066638ab429ac #v3.2.1 + with: + project: '${{ env.OCTOPUS_PROJECT }}' + space: '${{ env.OCTOPUS_SPACE }}' + release_number: '${{ steps.create_release.outputs.release_number }}' + environments: ${{ env.OCTOPUS_ENVIRONMENT }} diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml new file mode 100644 index 0000000000..bed395582e --- /dev/null +++ b/.github/workflows/pull-request.yml @@ -0,0 +1,35 @@ +name: Pull Request +on: + pull_request: + types: [opened, reopened, synchronize, ready_for_review] + +permissions: + contents: read + +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} + cancel-in-progress: true + +jobs: + verify: + name: Verify + uses: ./.github/workflows/verify.yml + secrets: inherit + + size: + name: Size + runs-on: ubuntu-latest + timeout-minutes: 5 + + steps: + - name: Clone repository + uses: actions/checkout@v4 + + - name: Install dependencies + uses: wevm/actions/.github/actions/pnpm@main + + - name: Report build size + uses: preactjs/compressed-size-action@v2 + with: + pattern: 'packages/**/dist/**' + repo-token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000000..297c74f635 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,44 @@ +name: Release + +on: + push: + branches: + - main + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +permissions: + contents: write + +jobs: + release: + name: Release + runs-on: ubuntu-latest + steps: + - name: Checkout Repo + uses: actions/checkout@v3 + + - name: Setup Node.js 20.x + uses: actions/setup-node@v3 + with: + node-version: 20.x + + - name: Install Dependencies + run: pnpm install + + - name: Create Release Pull Request or Publish to npm + id: changesets + uses: changesets/action@v1 + with: + # This expects you to have a script called release which does a build for your packages and calls changeset publish + publish: pnpm release + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + NPM_TOKEN: ${{ secrets.NPM_TOKEN }} + + - name: Send a Slack notification if a publish happens + if: steps.changesets.outputs.published == 'true' + # You can do something when a publish happens. + run: my-slack-bot send-notification --message "A new version of ${GITHUB_REPOSITORY} was published!" diff --git a/.github/workflows/snapshot.yml b/.github/workflows/snapshot.yml new file mode 100644 index 0000000000..39683bb684 --- /dev/null +++ b/.github/workflows/snapshot.yml @@ -0,0 +1,32 @@ +name: Snapshot +on: + workflow_dispatch: + +jobs: + snapshot: + name: Release snapshot version + permissions: + contents: write + id-token: write + runs-on: ubuntu-latest + timeout-minutes: 5 + + steps: + - name: Clone repository + uses: actions/checkout@v4 + + - name: Install dependencies + uses: wevm/actions/.github/actions/pnpm@main + + - name: Publish Snapshots + continue-on-error: true + env: + NPM_TOKEN: ${{ secrets.NPM_TOKEN }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + snapshot=$(git branch --show-current | tr -cs '[:alnum:]-' '-' | tr '[:upper:]' '[:lower:]' | sed 's/-$//') + npm config set "//registry.npmjs.org/:_authToken" "$NPM_TOKEN" + pnpm clean + pnpm changeset version --no-git-tag --snapshot $snapshot + pnpm changeset:prepublish + pnpm changeset publish --no-git-tag --snapshot $snapshot --tag $snapshot diff --git a/.github/workflows/verify.yml b/.github/workflows/verify.yml new file mode 100644 index 0000000000..8eb4e45f3c --- /dev/null +++ b/.github/workflows/verify.yml @@ -0,0 +1,136 @@ +name: Verify +on: + workflow_call: + workflow_dispatch: + +permissions: + contents: read + +jobs: + check: + name: Check + permissions: + contents: write + runs-on: ubuntu-latest + timeout-minutes: 5 + + steps: + - name: Clone repository + uses: actions/checkout@v4 + with: + token: ${{ secrets.GH_PTOKEN }} + + - name: Install dependencies + uses: wevm/actions/.github/actions/pnpm@main + + - name: Check repo + run: pnpm check:repo + + - name: Check code + run: pnpm check + + - name: Update package versions + run: pnpm version:update + + - uses: stefanzweifel/git-auto-commit-action@v5 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + commit_message: 'chore: format' + commit_user_name: 'github-actions[bot]' + commit_user_email: 'github-actions[bot]@users.noreply.github.com' + + build: + name: Build + needs: check + runs-on: ubuntu-latest + permissions: + contents: read + timeout-minutes: 5 + + steps: + - name: Clone repository + uses: actions/checkout@v4 + + - name: Install dependencies + uses: wevm/actions/.github/actions/pnpm@main + + - name: Build + run: pnpm build + + - name: Publint + run: pnpm test:build + + - name: Check for unused files, dependencies, and exports + run: pnpm knip --production + + types: + name: Types + needs: check + runs-on: ubuntu-latest + permissions: + contents: read + timeout-minutes: 5 + strategy: + matrix: + typescript-version: ['5.7.3', '5.8.3', 'latest'] + viem-version: ['2.29.2', 'latest'] + + steps: + - name: Clone repository + uses: actions/checkout@v4 + + - name: Install dependencies + uses: wevm/actions/.github/actions/pnpm@main + + - run: pnpm add -D -w typescript@${{ matrix.typescript-version }} viem@${{ matrix.viem-version }} + + - name: Link packages + run: pnpm preconstruct + + - name: Check types + run: pnpm check:types + + # Redundant with `pnpm check:types` + # If Vitest adds special features in the future, e.g. type coverage, can add this back! + # - name: Test types + # run: pnpm test:typecheck + + test: + name: Test + runs-on: ubuntu-latest + permissions: + contents: read + timeout-minutes: 10 + strategy: + max-parallel: 3 + matrix: + shard: [1, 2, 3] + total-shards: [3] + + steps: + - name: Clone repository + uses: actions/checkout@v4 + + - name: Install dependencies + uses: wevm/actions/.github/actions/pnpm@main + + - name: Set up foundry + uses: foundry-rs/foundry-toolchain@v1 + with: + version: nightly + + - name: Run tests + uses: nick-fields/retry@v3 + with: + command: CI=true pnpm test:cov --shard=${{ matrix.shard }}/${{ matrix.total-shards }} --retry=3 --bail=1 + max_attempts: 3 + timeout_minutes: 5 + env: + VITE_MAINNET_FORK_URL: ${{ secrets.VITE_MAINNET_FORK_URL }} + VITE_OPTIMISM_FORK_URL: ${{ secrets.VITE_OPTIMISM_FORK_URL }} + + - name: Upload coverage reports to Codecov + uses: codecov/codecov-action@v5 + with: + token: ${{ secrets.CODECOV_TOKEN }} diff --git a/.npmrc b/.npmrc new file mode 100644 index 0000000000..47687565bf --- /dev/null +++ b/.npmrc @@ -0,0 +1,5 @@ +auto-install-peers=false +enable-pre-post-scripts=true +link-workspace-packages=deep +provenance=true +strict-peer-dependencies=false diff --git a/.vscode/extensions.json b/.vscode/extensions.json new file mode 100644 index 0000000000..9cb435094a --- /dev/null +++ b/.vscode/extensions.json @@ -0,0 +1,7 @@ +{ + "recommendations": [ + "biomejs.biome", + "orta.vscode-twoslash-queries", + "Vue.volar" + ] +} diff --git a/.vscode/workspace.code-workspace b/.vscode/workspace.code-workspace new file mode 100644 index 0000000000..0d626129da --- /dev/null +++ b/.vscode/workspace.code-workspace @@ -0,0 +1,16 @@ +{ + "folders": [ + { + "name": "docs", + "path": "../docs" + }, + { + "name": "packages", + "path": "../packages" + }, + { + "name": "playgrounds", + "path": "../playgrounds" + } + ] +} diff --git a/LICENSE b/LICENSE index d645695673..650c3c1c00 100644 --- a/LICENSE +++ b/LICENSE @@ -1,202 +1,21 @@ - - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. +MIT License + +Copyright (c) 2022-present weth, LLC + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md index ae41ffdbd5..15f6f79541 100644 --- a/README.md +++ b/README.md @@ -1,39 +1 @@ -## sequence.js v3 core libraries and SDK - -**NOTE: please see [v2](https://github.com/0xsequence/sequence.js/tree/v2) branch for sequence.js 2.x.x** - ---- - -Sequence v3 core libraries and [wallet-contracts-v3](https://github.com/0xsequence/wallet-contracts-v3) SDK. - -## Packages - -- `@0xsequence/wallet-primitives`: stateless low-level utilities specifically for interacting directly with sequence wallet's smart contracts -- `@0xsequence/wallet-core`: higher level utilities for creating and using sequence wallets -- `@0xsequence/wallet-wdk`: all-in-one wallet development kit for building a sequence wallet product - -## Development - -### Getting Started - -1. Install dependencies: - `pnpm install` - -2. Build all packages: - `pnpm build` - -### Development Workflow - -- Run development mode across all packages: - `pnpm dev` - -- Run tests: - `pnpm test` - - > **Note:** Tests require [anvil](https://github.com/foundry-rs/foundry/tree/master/crates/anvil) and [forge](https://github.com/foundry-rs/foundry) to be installed. You can run a local anvil instance using `pnpm run test:anvil`. - -- Linting and formatting is enforced via git hooks - -## License - -Apache-2.0 +This is a [Vite](https://vitejs.dev) project bootstrapped with [`create-wagmi`](https://github.com/wevm/wagmi/tree/main/packages/create-wagmi). diff --git a/biome.json b/biome.json new file mode 100644 index 0000000000..ce99662cb0 --- /dev/null +++ b/biome.json @@ -0,0 +1,89 @@ +{ + "$schema": "./node_modules/@biomejs/biome/configuration_schema.json", + "files": { + "ignore": ["CHANGELOG.md", "pnpm-lock.yaml", "tsconfig.base.json"] + }, + "formatter": { + "enabled": true, + "formatWithErrors": false, + "indentStyle": "space", + "indentWidth": 2, + "lineWidth": 80 + }, + "linter": { + "ignore": ["packages/create-wagmi/templates/*"], + "enabled": true, + "rules": { + "recommended": true, + "a11y": { + "useButtonType": "off" + }, + "correctness": { + "noUnusedVariables": "error", + "useExhaustiveDependencies": "error" + }, + "performance": { + "noBarrelFile": "error", + "noReExportAll": "error", + "noDelete": "off" + }, + "style": { + "noNonNullAssertion": "off", + "useShorthandArrayType": "error" + }, + "suspicious": { + "noArrayIndexKey": "off", + "noConfusingVoidType": "off", + "noConsoleLog": "error", + "noExplicitAny": "off" + } + } + }, + "javascript": { + "formatter": { + "quoteStyle": "single", + "trailingCommas": "all", + "semicolons": "asNeeded" + } + }, + "organizeImports": { + "enabled": true + }, + "overrides": [ + { + "include": ["*.vue"], + "linter": { + "rules": { + "correctness": { + "noUnusedVariables": "off" + } + } + } + }, + { + "include": ["./scripts/**/*.ts"], + "linter": { + "rules": { + "suspicious": { + "noConsoleLog": "off" + } + } + } + }, + { + "include": ["./playgrounds/**"], + "linter": { + "rules": { + "style": { + "useNodejsImportProtocol": "off" + } + } + } + } + ], + "vcs": { + "enabled": true, + "clientKind": "git", + "useIgnoreFile": true + } +} diff --git a/extras/docs/package.json b/extras/docs/package.json index 738f3ead18..ccf8cc5bbf 100644 --- a/extras/docs/package.json +++ b/extras/docs/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@repo/ui": "workspace:^", - "next": "^15.5.15", + "next": "^15.5.14", "react": "^19.2.3", "react-dom": "^19.2.3" }, diff --git a/extras/web/package.json b/extras/web/package.json index 23e80ac071..53a613f730 100644 --- a/extras/web/package.json +++ b/extras/web/package.json @@ -7,23 +7,22 @@ "dev": "next dev --turbopack --port 3000", "build": "next build", "start": "next start", - "lint": "eslint . --max-warnings 0", + "lint": "next lint --max-warnings 0", "typecheck": "tsc --noEmit", "clean": "rimraf .next" }, "dependencies": { - "@repo/ui": "workspace:^", - "next": "^15.5.15", - "react": "^19.2.3", - "react-dom": "^19.2.3" + "@repo/ui": "workspace:*", + "next": "15.4.10", + "react": "^19.1.0", + "react-dom": "^19.1.0" }, "devDependencies": { - "@repo/eslint-config": "workspace:^", - "@repo/typescript-config": "workspace:^", - "@types/node": "^25.3.0", - "@types/react": "^19.2.7", - "@types/react-dom": "^19.2.3", - "eslint": "^9.39.2", - "typescript": "^5.9.3" + "@repo/eslint-config": "workspace:*", + "@repo/typescript-config": "workspace:*", + "@types/node": "^20.17.57", + "@types/react": "^19.0.0", + "@types/react-dom": "^19.0.0", + "typescript": "5.5.4" } } diff --git a/index.html b/index.html new file mode 100644 index 0000000000..f519ce85a7 --- /dev/null +++ b/index.html @@ -0,0 +1,12 @@ + + + + + + Create Wagmi + + +
+ + + diff --git a/lib/signals-implicit-mode/.env b/lib/signals-implicit-mode/.env deleted file mode 100644 index 6fc16b3cb7..0000000000 --- a/lib/signals-implicit-mode/.env +++ /dev/null @@ -1 +0,0 @@ -PRIVATE_KEY= diff --git a/lib/signals-implicit-mode/.env.sample b/lib/signals-implicit-mode/.env.sample deleted file mode 100644 index 6fc16b3cb7..0000000000 --- a/lib/signals-implicit-mode/.env.sample +++ /dev/null @@ -1 +0,0 @@ -PRIVATE_KEY= diff --git a/lib/signals-implicit-mode/.gas-snapshot b/lib/signals-implicit-mode/.gas-snapshot deleted file mode 100644 index cd1257bd36..0000000000 --- a/lib/signals-implicit-mode/.gas-snapshot +++ /dev/null @@ -1,35 +0,0 @@ -ImplicitProjectRegistryTest:test_addProjectUrl(address,bytes12,string) (runs: 256, μ: 116671, ~: 116810) -ImplicitProjectRegistryTest:test_addProjectUrlBatch(address,bytes12,string[]) (runs: 256, μ: 720585, ~: 728375) -ImplicitProjectRegistryTest:test_addProjectUrlHash(address,bytes12,bytes32) (runs: 256, μ: 112426, ~: 112426) -ImplicitProjectRegistryTest:test_addProjectUrlHashBatch(address,bytes12,bytes32[]) (runs: 256, μ: 597763, ~: 608234) -ImplicitProjectRegistryTest:test_claimProject(address,bytes12) (runs: 256, μ: 39958, ~: 39958) -ImplicitProjectRegistryTest:test_fail_addProjectUrlAlreadyExists(address,bytes12,string) (runs: 256, μ: 112644, ~: 112783) -ImplicitProjectRegistryTest:test_fail_addProjectUrlAlreadyExistsHash(address,bytes12,string) (runs: 256, μ: 111144, ~: 111259) -ImplicitProjectRegistryTest:test_fail_addProjectUrlByNonOwner(address,address,bytes12,string) (runs: 256, μ: 41212, ~: 41173) -ImplicitProjectRegistryTest:test_fail_addProjectUrlHashAlreadyExists(address,bytes12,bytes32) (runs: 256, μ: 108525, ~: 108525) -ImplicitProjectRegistryTest:test_fail_addProjectUrlHashAlreadyExistsFull(address,bytes12,string) (runs: 256, μ: 111099, ~: 111214) -ImplicitProjectRegistryTest:test_fail_addProjectUrlHashBatchByNonOwner(address,address,bytes12,bytes32[]) (runs: 256, μ: 87811, ~: 89313) -ImplicitProjectRegistryTest:test_fail_addProjectUrlHashByNonOwner(address,address,bytes12,bytes32) (runs: 256, μ: 39718, ~: 39718) -ImplicitProjectRegistryTest:test_fail_claimInvalidOwner(bytes12) (runs: 256, μ: 9949, ~: 9949) -ImplicitProjectRegistryTest:test_fail_claimProjectTwice(address,address,bytes12) (runs: 256, μ: 45067, ~: 45067) -ImplicitProjectRegistryTest:test_fail_removeNonexistentUrl(address,bytes12,string) (runs: 256, μ: 43756, ~: 43828) -ImplicitProjectRegistryTest:test_fail_removeNonexistentUrlHash(address,bytes12,bytes32) (runs: 256, μ: 41619, ~: 41619) -ImplicitProjectRegistryTest:test_fail_removeProjectUrlByNonOwner(address,address,bytes12,string) (runs: 256, μ: 41234, ~: 41195) -ImplicitProjectRegistryTest:test_fail_removeProjectUrlHashBatchByNonOwner(address,address,bytes12,bytes32[]) (runs: 256, μ: 593982, ~: 603423) -ImplicitProjectRegistryTest:test_fail_removeProjectUrlHashByNonOwner(address,address,bytes12,bytes32) (runs: 256, μ: 40142, ~: 40142) -ImplicitProjectRegistryTest:test_fail_removeUrlHashWrongIndex(address,bytes12,bytes32[],uint256) (runs: 256, μ: 588246, ~: 596140) -ImplicitProjectRegistryTest:test_fail_transferByNonAdmin(address,address,bytes12) (runs: 256, μ: 40195, ~: 40195) -ImplicitProjectRegistryTest:test_fail_transferInvalidOwner(address,bytes12) (runs: 256, μ: 39035, ~: 39035) -ImplicitProjectRegistryTest:test_fail_validateAttestationWithInvalidUrl(address,address,bytes12,string,string) (runs: 256, μ: 118943, ~: 118930) -ImplicitProjectRegistryTest:test_removeProjectUrl(address,bytes12,string[],uint256) (runs: 256, μ: 677869, ~: 688567) -ImplicitProjectRegistryTest:test_removeProjectUrlHash(address,bytes12,bytes32[],uint256) (runs: 256, μ: 563429, ~: 571346) -ImplicitProjectRegistryTest:test_removeProjectUrlHashBatch(address,bytes12,bytes32[]) (runs: 256, μ: 514463, ~: 522326) -ImplicitProjectRegistryTest:test_removeProjectUrlHashBatchWithInvalidUrlIdxs(address,bytes12,bytes32[],uint256[]) (runs: 256, μ: 231800, ~: 233726) -ImplicitProjectRegistryTest:test_removeProjectUrlHashBatchWithInvalidUrlIdxsOrder(address,bytes12,bytes32[],uint256[]) (runs: 256, μ: 238667, ~: 251592) -ImplicitProjectRegistryTest:test_transferProject(address,address,bytes12,bytes32) (runs: 256, μ: 119694, ~: 119694) -ImplicitProjectRegistryTest:test_validateAttestationMultiple(address,address,bytes12,string[],uint256) (runs: 256, μ: 706695, ~: 712410) -ImplicitProjectRegistryTest:test_validateAttestationSingle(address,address,bytes12,string) (runs: 256, μ: 120772, ~: 120602) -SignalsImplicitModeTest:test_acceptsValidUrl(bytes12,address,string,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),address,(address,uint256,bytes,uint256,bool,bool,uint256)) (runs: 256, μ: 665701, ~: 665732) -SignalsImplicitModeTest:test_acceptsValidUrlFromMultiple(bytes12,address,string[],uint256,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),address,(address,uint256,bytes,uint256,bool,bool,uint256)) (runs: 256, μ: 1254530, ~: 1269578) -SignalsImplicitModeTest:test_rejectsInvalidUrl(bytes32,string,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),address,(address,uint256,bytes,uint256,bool,bool,uint256)) (runs: 256, μ: 562463, ~: 562443) -SignalsImplicitModeTest:test_supportsInterface(bytes32) (runs: 256, μ: 540796, ~: 540796) \ No newline at end of file diff --git a/lib/signals-implicit-mode/.github/workflows/test.yml b/lib/signals-implicit-mode/.github/workflows/test.yml deleted file mode 100644 index 1be6707d7a..0000000000 --- a/lib/signals-implicit-mode/.github/workflows/test.yml +++ /dev/null @@ -1,56 +0,0 @@ -name: CI - -on: - push: - pull_request: - workflow_dispatch: - -env: - FOUNDRY_PROFILE: ci - -jobs: - check: - strategy: - fail-fast: true - - name: Foundry project - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - with: - submodules: false - - - name: Use PAT - run: | - git config --global url."https://${{ secrets.SEQUENCE_V3_PAT }}@github.com/".insteadOf "https://github.com/" - - - name: Download submodules - run: | - git submodule update --init --recursive - - - name: Install Foundry - uses: foundry-rs/foundry-toolchain@v1 - - - name: Show Forge version - run: | - forge --version - - - name: Run Forge fmt - run: | - forge fmt --check - id: fmt - - - name: Run Forge build - run: | - forge build --sizes - id: build - - - name: Run Forge tests - run: | - forge test -vvv - id: test - - - name: Run Coverage report - run: | - forge coverage --nmco "(script|test)" - id: coverage diff --git a/lib/signals-implicit-mode/.gitmodules b/lib/signals-implicit-mode/.gitmodules deleted file mode 100644 index 95a9dda989..0000000000 --- a/lib/signals-implicit-mode/.gitmodules +++ /dev/null @@ -1,9 +0,0 @@ -[submodule "lib/forge-std"] - path = lib/forge-std - url = https://github.com/foundry-rs/forge-std -[submodule "lib/sequence-v3"] - path = lib/sequence-v3 - url = https://github.com/0xsequence/sequence-v3 -[submodule "lib/erc2470-libs"] - path = lib/erc2470-libs - url = https://github.com/ScreamingHawk/erc2470-libs diff --git a/lib/signals-implicit-mode/README.md b/lib/signals-implicit-mode/README.md deleted file mode 100644 index c89779b412..0000000000 --- a/lib/signals-implicit-mode/README.md +++ /dev/null @@ -1,84 +0,0 @@ -# Signals Implicit Mode - -Libraries for managing support for [Sequence Ecosystem Wallet](https://github.com/0xsequence/sequence-v3)'s [implicit sessions](https://github.com/0xsequence/sequence-v3/blob/master/docs/SESSIONS.md). - -## Implicit Registry - -The `ImplicitProjectRegistry` is an ownerless, singleton contract that allows a single contract to define the accepted `redirectUrl`s for their project. Using the registry gives a single point for management of accepted `redirectUrl`s. - -Using the registry is also a quick way to authorize implicit access to contracts from other projects. - -See below _Support Implicit Sessions_ for information on how to integrate with the registry. - -### Register Your Project URLs - -Select your `Project ID`. The project ID is composed of two parts: - -- A 12-byte (24 hex characters) upper portion that you choose -- Your address as the lower 20 bytes - -To claim your project ID, call the `claimProject(bytes12 projectIdUpper)` function. The contract will automatically combine your chosen upper portion with your address to create the full project ID. - -> [!TIP] -> Consider claiming your project ID on every chain you wish to support. Claiming a project ID does not imply you must use it. - -As the project owner, you can: - -- Add supported redirect URLs by calling `addProjectUrl(bytes32 projectId, string memory projectUrl)` -- Remove URLs using `removeProjectUrl(bytes32 projectId, string memory projectUrl)` -- Transfer project ownership using `transferProject(bytes32 projectId, address newOwner)` - -Anyone can list all project URLs using `listProjectUrls(bytes32 projectId)`. - -Integrate your contracts with the registry using your project ID as described in the next section. - -## Support Implicit Sessions - -Import this library into your project using forge. - -```sh -cd -forge install https://github.com/0xsequence/signals-implicit-mode -``` - -Extend the provided abstract contract implementation. - -```solidity -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.13; - -import {SignalsImplicitMode} from "signals-implicit-mode/helper/SignalsImplicitMode.sol"; - -contract ImplicitSupportedContract is SignalsImplicitMode { - constructor(address registry, bytes32 projectId) { - _initializeSignalsImplicitMode(registry, projectId); - } -} -``` - -Optionally, extend the validation by implementing the `_validateImplicitRequest` hook. - -## Run Tests - -```sh -forge test -``` - -## Deploy Contracts - -> [!NOTE] -> This will deploy the `ImplicitProjectRegistry`. Deployments use ERC-2470 for counter factual deployments and will deploy to `0x1dbaE3Df2A510768a36cE998396210Be12508d50`. - -> [!TIP] -> The `ImplicitProjectRegistry` is ownerless and so you are free to use an implementation and claim any `projectId`. You do not need to deploy your own instance. - -Copy the `env.sample` file to `.env` and set the environment variables. - -```sh -cp .env.sample .env -# Edit .env -``` - -```sh -forge script Deploy --rpc-url --broadcast -``` diff --git a/lib/signals-implicit-mode/broadcast/Deploy.s.sol/1/run-1770363485985.json b/lib/signals-implicit-mode/broadcast/Deploy.s.sol/1/run-1770363485985.json deleted file mode 100644 index 523c6482cc..0000000000 --- a/lib/signals-implicit-mode/broadcast/Deploy.s.sol/1/run-1770363485985.json +++ /dev/null @@ -1,58 +0,0 @@ -{ - "transactions": [ - { - "hash": "0x32535d715233a9f552f46cd8e62bfe624ca606e0f9dd6711a3617f08c7737f3e", - "transactionType": "CALL", - "contractName": null, - "contractAddress": "0xce0042b868300000d44a59004da54a005ffdcf9f", - "function": "deploy(bytes,bytes32)", - "arguments": [ - "0x6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea264697066735822122019bab80291bd8d50097cd6215757f008e2916b0f9a4cf413de02f4326173ea4664736f6c634300081c0033", - "0x0000000000000000000000000000000000000000000000000000000000000000" - ], - "transaction": { - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xce0042b868300000d44a59004da54a005ffdcf9f", - "gas": "0x2a588c", - "value": "0x0", - "input": "0x4af63f020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000023936080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea264697066735822122019bab80291bd8d50097cd6215757f008e2916b0f9a4cf413de02f4326173ea4664736f6c634300081c003300000000000000000000000000", - "nonce": "0x12a6", - "chainId": "0x1" - }, - "additionalContracts": [ - { - "transactionType": "CREATE2", - "contractName": "ImplicitProjectRegistry", - "address": "0x899bcf2333159a0b54e562707426c8af262e0243", - "initCode": "0x6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea264697066735822122019bab80291bd8d50097cd6215757f008e2916b0f9a4cf413de02f4326173ea4664736f6c634300081c0033" - } - ], - "isFixedGasLimit": false - } - ], - "receipts": [ - { - "status": "0x1", - "cumulativeGasUsed": "0x1eaa97", - "logs": [], - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "type": "0x2", - "transactionHash": "0x32535d715233a9f552f46cd8e62bfe624ca606e0f9dd6711a3617f08c7737f3e", - "transactionIndex": "0x0", - "blockHash": "0xeb7968668d122ef113e50e9cf21472c5f5ad039a84682b38a389a979bc46a139", - "blockNumber": "0x17441d7", - "gasUsed": "0x1eaa97", - "effectiveGasPrice": "0xf4c91d4", - "blobGasPrice": "0x9", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xce0042b868300000d44a59004da54a005ffdcf9f", - "contractAddress": null - } - ], - "libraries": [], - "pending": [], - "returns": {}, - "timestamp": 1770363485985, - "chain": 1, - "commit": "96c1f12" -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/broadcast/Deploy.s.sol/1/run-1770364554426.json b/lib/signals-implicit-mode/broadcast/Deploy.s.sol/1/run-1770364554426.json deleted file mode 100644 index 46c7dbb4eb..0000000000 --- a/lib/signals-implicit-mode/broadcast/Deploy.s.sol/1/run-1770364554426.json +++ /dev/null @@ -1,58 +0,0 @@ -{ - "transactions": [ - { - "hash": "0x335ccba1cae296bd60532d54cbb8a031788a66869952f27d91e5b7039540df06", - "transactionType": "CALL", - "contractName": null, - "contractAddress": "0xce0042b868300000d44a59004da54a005ffdcf9f", - "function": "deploy(bytes,bytes32)", - "arguments": [ - "0x6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c0033", - "0x0000000000000000000000000000000000000000000000000000000000000000" - ], - "transaction": { - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xce0042b868300000d44a59004da54a005ffdcf9f", - "gas": "0x2a588c", - "value": "0x0", - "input": "0x4af63f020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000023936080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c003300000000000000000000000000", - "nonce": "0x12a8", - "chainId": "0x1" - }, - "additionalContracts": [ - { - "transactionType": "CREATE2", - "contractName": "ImplicitProjectRegistry", - "address": "0x82d1c54520516de908300ff335f74ba9f4b58383", - "initCode": "0x6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c0033" - } - ], - "isFixedGasLimit": false - } - ], - "receipts": [ - { - "status": "0x1", - "cumulativeGasUsed": "0x1eaa97", - "logs": [], - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "type": "0x2", - "transactionHash": "0x335ccba1cae296bd60532d54cbb8a031788a66869952f27d91e5b7039540df06", - "transactionIndex": "0x0", - "blockHash": "0x67cb99d05049219d2e30c424a15256e5f72022267f5751e9fc93013cffefd9fb", - "blockNumber": "0x17441d9", - "gasUsed": "0x1eaa97", - "effectiveGasPrice": "0xbd738bd", - "blobGasPrice": "0x1", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xce0042b868300000d44a59004da54a005ffdcf9f", - "contractAddress": null - } - ], - "libraries": [], - "pending": [], - "returns": {}, - "timestamp": 1770364554426, - "chain": 1, - "commit": "96c1f12" -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/broadcast/Deploy.s.sol/1/run-latest.json b/lib/signals-implicit-mode/broadcast/Deploy.s.sol/1/run-latest.json deleted file mode 100644 index 46c7dbb4eb..0000000000 --- a/lib/signals-implicit-mode/broadcast/Deploy.s.sol/1/run-latest.json +++ /dev/null @@ -1,58 +0,0 @@ -{ - "transactions": [ - { - "hash": "0x335ccba1cae296bd60532d54cbb8a031788a66869952f27d91e5b7039540df06", - "transactionType": "CALL", - "contractName": null, - "contractAddress": "0xce0042b868300000d44a59004da54a005ffdcf9f", - "function": "deploy(bytes,bytes32)", - "arguments": [ - "0x6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c0033", - "0x0000000000000000000000000000000000000000000000000000000000000000" - ], - "transaction": { - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xce0042b868300000d44a59004da54a005ffdcf9f", - "gas": "0x2a588c", - "value": "0x0", - "input": "0x4af63f020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000023936080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c003300000000000000000000000000", - "nonce": "0x12a8", - "chainId": "0x1" - }, - "additionalContracts": [ - { - "transactionType": "CREATE2", - "contractName": "ImplicitProjectRegistry", - "address": "0x82d1c54520516de908300ff335f74ba9f4b58383", - "initCode": "0x6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c0033" - } - ], - "isFixedGasLimit": false - } - ], - "receipts": [ - { - "status": "0x1", - "cumulativeGasUsed": "0x1eaa97", - "logs": [], - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "type": "0x2", - "transactionHash": "0x335ccba1cae296bd60532d54cbb8a031788a66869952f27d91e5b7039540df06", - "transactionIndex": "0x0", - "blockHash": "0x67cb99d05049219d2e30c424a15256e5f72022267f5751e9fc93013cffefd9fb", - "blockNumber": "0x17441d9", - "gasUsed": "0x1eaa97", - "effectiveGasPrice": "0xbd738bd", - "blobGasPrice": "0x1", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xce0042b868300000d44a59004da54a005ffdcf9f", - "contractAddress": null - } - ], - "libraries": [], - "pending": [], - "returns": {}, - "timestamp": 1770364554426, - "chain": 1, - "commit": "96c1f12" -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/cache/Deploy.s.sol/1/run-1770363485985.json b/lib/signals-implicit-mode/cache/Deploy.s.sol/1/run-1770363485985.json deleted file mode 100644 index 3d489aedfd..0000000000 --- a/lib/signals-implicit-mode/cache/Deploy.s.sol/1/run-1770363485985.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "transactions": [ - { - "rpc": "http://127.0.0.1:8545" - } - ] -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/cache/Deploy.s.sol/1/run-1770364554426.json b/lib/signals-implicit-mode/cache/Deploy.s.sol/1/run-1770364554426.json deleted file mode 100644 index 3d489aedfd..0000000000 --- a/lib/signals-implicit-mode/cache/Deploy.s.sol/1/run-1770364554426.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "transactions": [ - { - "rpc": "http://127.0.0.1:8545" - } - ] -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/cache/Deploy.s.sol/1/run-latest.json b/lib/signals-implicit-mode/cache/Deploy.s.sol/1/run-latest.json deleted file mode 100644 index 3d489aedfd..0000000000 --- a/lib/signals-implicit-mode/cache/Deploy.s.sol/1/run-latest.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "transactions": [ - { - "rpc": "http://127.0.0.1:8545" - } - ] -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/cache/solidity-files-cache.json b/lib/signals-implicit-mode/cache/solidity-files-cache.json deleted file mode 100644 index 57ff140eab..0000000000 --- a/lib/signals-implicit-mode/cache/solidity-files-cache.json +++ /dev/null @@ -1 +0,0 @@ -{"_format":"","paths":{"artifacts":"out","build_infos":"out/build-info","sources":"src","tests":"test","scripts":"script","libraries":["dependencies","lib"]},"files":{"lib/forge-std/src/Base.sol":{"lastModificationDate":1770101762022,"contentHash":"f4bd67fdeb49a95a","interfaceReprHash":null,"sourceName":"lib/forge-std/src/Base.sol","imports":["lib/forge-std/src/StdStorage.sol","lib/forge-std/src/Vm.sol"],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"CommonBase":{"0.8.28":{"default":{"path":"Base.sol/CommonBase.json","build_id":"6df801dae8a4cdc2"}}},"ScriptBase":{"0.8.28":{"default":{"path":"Base.sol/ScriptBase.json","build_id":"6df801dae8a4cdc2"}}},"TestBase":{"0.8.28":{"default":{"path":"Base.sol/TestBase.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/Script.sol":{"lastModificationDate":1770101762050,"contentHash":"654eb74437773a2d","interfaceReprHash":null,"sourceName":"lib/forge-std/src/Script.sol","imports":["lib/forge-std/src/Base.sol","lib/forge-std/src/StdChains.sol","lib/forge-std/src/StdCheats.sol","lib/forge-std/src/StdConstants.sol","lib/forge-std/src/StdJson.sol","lib/forge-std/src/StdMath.sol","lib/forge-std/src/StdStorage.sol","lib/forge-std/src/StdStyle.sol","lib/forge-std/src/StdUtils.sol","lib/forge-std/src/Vm.sol","lib/forge-std/src/console.sol","lib/forge-std/src/console2.sol","lib/forge-std/src/interfaces/IMulticall3.sol","lib/forge-std/src/safeconsole.sol"],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"Script":{"0.8.28":{"default":{"path":"Script.sol/Script.json","build_id":"efb7c762ba0fcac7"}}}},"seenByCompiler":true},"lib/forge-std/src/StdAssertions.sol":{"lastModificationDate":1770101762161,"contentHash":"02aafa55c6c27fcf","interfaceReprHash":null,"sourceName":"lib/forge-std/src/StdAssertions.sol","imports":["lib/forge-std/src/Vm.sol"],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"StdAssertions":{"0.8.28":{"default":{"path":"StdAssertions.sol/StdAssertions.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/StdChains.sol":{"lastModificationDate":1770101762162,"contentHash":"0adbf4fecabd792e","interfaceReprHash":null,"sourceName":"lib/forge-std/src/StdChains.sol","imports":["lib/forge-std/src/Vm.sol"],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"StdChains":{"0.8.28":{"default":{"path":"StdChains.sol/StdChains.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/StdCheats.sol":{"lastModificationDate":1770101762163,"contentHash":"30325e8cda32c7ae","interfaceReprHash":null,"sourceName":"lib/forge-std/src/StdCheats.sol","imports":["lib/forge-std/src/StdStorage.sol","lib/forge-std/src/Vm.sol","lib/forge-std/src/console.sol","lib/forge-std/src/console2.sol"],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"StdCheats":{"0.8.28":{"default":{"path":"StdCheats.sol/StdCheats.json","build_id":"6df801dae8a4cdc2"}}},"StdCheatsSafe":{"0.8.28":{"default":{"path":"StdCheats.sol/StdCheatsSafe.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/StdConstants.sol":{"lastModificationDate":1770101762165,"contentHash":"23303eb7e922efe4","interfaceReprHash":null,"sourceName":"lib/forge-std/src/StdConstants.sol","imports":["lib/forge-std/src/Vm.sol","lib/forge-std/src/interfaces/IMulticall3.sol"],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"StdConstants":{"0.8.28":{"default":{"path":"StdConstants.sol/StdConstants.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/StdError.sol":{"lastModificationDate":1770101762166,"contentHash":"a1a86c7115e2cdf3","interfaceReprHash":null,"sourceName":"lib/forge-std/src/StdError.sol","imports":[],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"stdError":{"0.8.28":{"default":{"path":"StdError.sol/stdError.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/StdInvariant.sol":{"lastModificationDate":1770101762167,"contentHash":"0111ef959dff6f54","interfaceReprHash":null,"sourceName":"lib/forge-std/src/StdInvariant.sol","imports":[],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"StdInvariant":{"0.8.28":{"default":{"path":"StdInvariant.sol/StdInvariant.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/StdJson.sol":{"lastModificationDate":1770101762168,"contentHash":"5fb1b35c8fb281fd","interfaceReprHash":null,"sourceName":"lib/forge-std/src/StdJson.sol","imports":["lib/forge-std/src/Vm.sol"],"versionRequirement":">=0.6.0, <0.9.0","artifacts":{"stdJson":{"0.8.28":{"default":{"path":"StdJson.sol/stdJson.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/StdMath.sol":{"lastModificationDate":1770101762169,"contentHash":"72584abebada1e7a","interfaceReprHash":null,"sourceName":"lib/forge-std/src/StdMath.sol","imports":[],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"stdMath":{"0.8.28":{"default":{"path":"StdMath.sol/stdMath.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/StdStorage.sol":{"lastModificationDate":1770101762171,"contentHash":"9a44dcb9bda3bfa9","interfaceReprHash":null,"sourceName":"lib/forge-std/src/StdStorage.sol","imports":["lib/forge-std/src/Vm.sol"],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"stdStorage":{"0.8.28":{"default":{"path":"StdStorage.sol/stdStorage.json","build_id":"6df801dae8a4cdc2"}}},"stdStorageSafe":{"0.8.28":{"default":{"path":"StdStorage.sol/stdStorageSafe.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/StdStyle.sol":{"lastModificationDate":1770101762172,"contentHash":"ee166ef95092736e","interfaceReprHash":null,"sourceName":"lib/forge-std/src/StdStyle.sol","imports":["lib/forge-std/src/Vm.sol"],"versionRequirement":">=0.4.22, <0.9.0","artifacts":{"StdStyle":{"0.8.28":{"default":{"path":"StdStyle.sol/StdStyle.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/StdToml.sol":{"lastModificationDate":1770101762172,"contentHash":"fc667e4ecb7fa86c","interfaceReprHash":null,"sourceName":"lib/forge-std/src/StdToml.sol","imports":["lib/forge-std/src/Vm.sol"],"versionRequirement":">=0.6.0, <0.9.0","artifacts":{"stdToml":{"0.8.28":{"default":{"path":"StdToml.sol/stdToml.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/StdUtils.sol":{"lastModificationDate":1770101762173,"contentHash":"b7cdeb66252de708","interfaceReprHash":null,"sourceName":"lib/forge-std/src/StdUtils.sol","imports":["lib/forge-std/src/Vm.sol","lib/forge-std/src/interfaces/IMulticall3.sol"],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"StdUtils":{"0.8.28":{"default":{"path":"StdUtils.sol/StdUtils.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/Test.sol":{"lastModificationDate":1770101762174,"contentHash":"f56119a09f81c62c","interfaceReprHash":null,"sourceName":"lib/forge-std/src/Test.sol","imports":["lib/forge-std/src/Base.sol","lib/forge-std/src/StdAssertions.sol","lib/forge-std/src/StdChains.sol","lib/forge-std/src/StdCheats.sol","lib/forge-std/src/StdConstants.sol","lib/forge-std/src/StdError.sol","lib/forge-std/src/StdInvariant.sol","lib/forge-std/src/StdJson.sol","lib/forge-std/src/StdMath.sol","lib/forge-std/src/StdStorage.sol","lib/forge-std/src/StdStyle.sol","lib/forge-std/src/StdToml.sol","lib/forge-std/src/StdUtils.sol","lib/forge-std/src/Vm.sol","lib/forge-std/src/console.sol","lib/forge-std/src/console2.sol","lib/forge-std/src/interfaces/IMulticall3.sol","lib/forge-std/src/safeconsole.sol"],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"Test":{"0.8.28":{"default":{"path":"Test.sol/Test.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/Vm.sol":{"lastModificationDate":1770101762176,"contentHash":"803443adcf84cfaa","interfaceReprHash":null,"sourceName":"lib/forge-std/src/Vm.sol","imports":[],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"Vm":{"0.8.28":{"default":{"path":"Vm.sol/Vm.json","build_id":"6df801dae8a4cdc2"}}},"VmSafe":{"0.8.28":{"default":{"path":"Vm.sol/VmSafe.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/console.sol":{"lastModificationDate":1770101762177,"contentHash":"bae85493a76fb054","interfaceReprHash":null,"sourceName":"lib/forge-std/src/console.sol","imports":[],"versionRequirement":">=0.4.22, <0.9.0","artifacts":{"console":{"0.8.28":{"default":{"path":"console.sol/console.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/console2.sol":{"lastModificationDate":1770101762179,"contentHash":"49a7da3dfc404603","interfaceReprHash":null,"sourceName":"lib/forge-std/src/console2.sol","imports":["lib/forge-std/src/console.sol"],"versionRequirement":">=0.4.22, <0.9.0","artifacts":{},"seenByCompiler":true},"lib/forge-std/src/interfaces/IMulticall3.sol":{"lastModificationDate":1770101762364,"contentHash":"b680a332ebf10901","interfaceReprHash":null,"sourceName":"lib/forge-std/src/interfaces/IMulticall3.sol","imports":[],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"IMulticall3":{"0.8.28":{"default":{"path":"IMulticall3.sol/IMulticall3.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/forge-std/src/safeconsole.sol":{"lastModificationDate":1770101762367,"contentHash":"621653b34a6691ea","interfaceReprHash":null,"sourceName":"lib/forge-std/src/safeconsole.sol","imports":[],"versionRequirement":">=0.6.2, <0.9.0","artifacts":{"safeconsole":{"0.8.28":{"default":{"path":"safeconsole.sol/safeconsole.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol":{"lastModificationDate":1770101765184,"contentHash":"3e34bb2b04049795","interfaceReprHash":null,"sourceName":"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol","imports":["lib/forge-std/src/Base.sol","lib/forge-std/src/Script.sol","lib/forge-std/src/StdChains.sol","lib/forge-std/src/StdCheats.sol","lib/forge-std/src/StdConstants.sol","lib/forge-std/src/StdJson.sol","lib/forge-std/src/StdMath.sol","lib/forge-std/src/StdStorage.sol","lib/forge-std/src/StdStyle.sol","lib/forge-std/src/StdUtils.sol","lib/forge-std/src/Vm.sol","lib/forge-std/src/console.sol","lib/forge-std/src/console2.sol","lib/forge-std/src/interfaces/IMulticall3.sol","lib/forge-std/src/safeconsole.sol","lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol"],"versionRequirement":"^0.8.18","artifacts":{"SingletonDeployer":{"0.8.28":{"default":{"path":"SingletonDeployer.s.sol/SingletonDeployer.json","build_id":"efb7c762ba0fcac7"}}}},"seenByCompiler":true},"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol":{"lastModificationDate":1770101765185,"contentHash":"1bda2b8e14acc154","interfaceReprHash":null,"sourceName":"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol","imports":[],"versionRequirement":"^0.8.18","artifacts":{"ISingletonFactory":{"0.8.28":{"default":{"path":"ISingletonFactory.sol/ISingletonFactory.json","build_id":"efb7c762ba0fcac7"}}}},"seenByCompiler":true},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol":{"lastModificationDate":1770101769236,"contentHash":"d909f0608672501c","interfaceReprHash":null,"sourceName":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol","imports":["lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol"],"versionRequirement":"^0.8.20","artifacts":{"ERC165":{"0.8.28":{"default":{"path":"ERC165.sol/ERC165.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol":{"lastModificationDate":1770101769238,"contentHash":"a95786011a8cb3b2","interfaceReprHash":null,"sourceName":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol","imports":[],"versionRequirement":"^0.8.20","artifacts":{"IERC165":{"0.8.28":{"default":{"path":"IERC165.sol/IERC165.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"lastModificationDate":1770101769885,"contentHash":"725b2ff09f17c325","interfaceReprHash":null,"sourceName":"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","imports":["lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","lib/sequence-v3/src/modules/Payload.sol","lib/sequence-v3/src/utils/LibBytes.sol"],"versionRequirement":"^0.8.27","artifacts":{"LibAttestation":{"0.8.28":{"default":{"path":"Attestation.sol/LibAttestation.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"lastModificationDate":1770101769886,"contentHash":"10ed3a2c21a500f2","interfaceReprHash":null,"sourceName":"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","imports":["lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","lib/sequence-v3/src/modules/Payload.sol","lib/sequence-v3/src/utils/LibBytes.sol"],"versionRequirement":"^0.8.27","artifacts":{"ISignalsImplicitMode":{"0.8.28":{"default":{"path":"ISignalsImplicitMode.sol/ISignalsImplicitMode.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/sequence-v3/src/modules/Payload.sol":{"lastModificationDate":1770101769892,"contentHash":"7a00dba6321ef947","interfaceReprHash":null,"sourceName":"lib/sequence-v3/src/modules/Payload.sol","imports":["lib/sequence-v3/src/utils/LibBytes.sol"],"versionRequirement":"^0.8.27","artifacts":{"Payload":{"0.8.28":{"default":{"path":"Payload.sol/Payload.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"lib/sequence-v3/src/utils/LibBytes.sol":{"lastModificationDate":1770101769908,"contentHash":"78548bb647cca49c","interfaceReprHash":null,"sourceName":"lib/sequence-v3/src/utils/LibBytes.sol","imports":[],"versionRequirement":"^0.8.18","artifacts":{"LibBytes":{"0.8.28":{"default":{"path":"LibBytes.sol/LibBytes.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"script/Deploy.s.sol":{"lastModificationDate":1770361770322,"contentHash":"d58cc965f18a84b5","interfaceReprHash":null,"sourceName":"script/Deploy.s.sol","imports":["lib/forge-std/src/Base.sol","lib/forge-std/src/Script.sol","lib/forge-std/src/StdChains.sol","lib/forge-std/src/StdCheats.sol","lib/forge-std/src/StdConstants.sol","lib/forge-std/src/StdJson.sol","lib/forge-std/src/StdMath.sol","lib/forge-std/src/StdStorage.sol","lib/forge-std/src/StdStyle.sol","lib/forge-std/src/StdUtils.sol","lib/forge-std/src/Vm.sol","lib/forge-std/src/console.sol","lib/forge-std/src/console2.sol","lib/forge-std/src/interfaces/IMulticall3.sol","lib/forge-std/src/safeconsole.sol","lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol","lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol","lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","lib/sequence-v3/src/modules/Payload.sol","lib/sequence-v3/src/utils/LibBytes.sol","src/registry/IImplicitProjectRegistry.sol","src/registry/IImplicitProjectValidation.sol","src/registry/ImplicitProjectRegistry.sol"],"versionRequirement":"^0.8.27","artifacts":{"Deploy":{"0.8.28":{"default":{"path":"Deploy.s.sol/Deploy.json","build_id":"efb7c762ba0fcac7"}}}},"seenByCompiler":true},"src/helper/SignalsImplicitMode.sol":{"lastModificationDate":1770361770368,"contentHash":"37ca4b7406fabdbb","interfaceReprHash":null,"sourceName":"src/helper/SignalsImplicitMode.sol","imports":["lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol","lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol","lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","lib/sequence-v3/src/modules/Payload.sol","lib/sequence-v3/src/utils/LibBytes.sol","src/registry/IImplicitProjectValidation.sol"],"versionRequirement":"^0.8.13","artifacts":{"SignalsImplicitMode":{"0.8.28":{"default":{"path":"SignalsImplicitMode.sol/SignalsImplicitMode.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"src/registry/IImplicitProjectRegistry.sol":{"lastModificationDate":1770361770434,"contentHash":"2c79f59dd617050b","interfaceReprHash":null,"sourceName":"src/registry/IImplicitProjectRegistry.sol","imports":["lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","lib/sequence-v3/src/modules/Payload.sol","lib/sequence-v3/src/utils/LibBytes.sol","src/registry/IImplicitProjectValidation.sol"],"versionRequirement":"^0.8.13","artifacts":{"IImplicitProjectRegistry":{"0.8.28":{"default":{"path":"IImplicitProjectRegistry.sol/IImplicitProjectRegistry.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"src/registry/IImplicitProjectValidation.sol":{"lastModificationDate":1770361770369,"contentHash":"0e5a2e7a8b6c7e32","interfaceReprHash":null,"sourceName":"src/registry/IImplicitProjectValidation.sol","imports":["lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","lib/sequence-v3/src/modules/Payload.sol","lib/sequence-v3/src/utils/LibBytes.sol"],"versionRequirement":"^0.8.13","artifacts":{"IImplicitProjectValidation":{"0.8.28":{"default":{"path":"IImplicitProjectValidation.sol/IImplicitProjectValidation.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"src/registry/ImplicitProjectRegistry.sol":{"lastModificationDate":1770361770401,"contentHash":"ef64b470cee9db69","interfaceReprHash":null,"sourceName":"src/registry/ImplicitProjectRegistry.sol","imports":["lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","lib/sequence-v3/src/modules/Payload.sol","lib/sequence-v3/src/utils/LibBytes.sol","src/registry/IImplicitProjectRegistry.sol","src/registry/IImplicitProjectValidation.sol"],"versionRequirement":"^0.8.13","artifacts":{"ImplicitProjectRegistry":{"0.8.28":{"default":{"path":"ImplicitProjectRegistry.sol/ImplicitProjectRegistry.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"test/ImplicitProjectRegistry.t.sol":{"lastModificationDate":1770361770510,"contentHash":"01215c2f20438804","interfaceReprHash":null,"sourceName":"test/ImplicitProjectRegistry.t.sol","imports":["lib/forge-std/src/Base.sol","lib/forge-std/src/StdAssertions.sol","lib/forge-std/src/StdChains.sol","lib/forge-std/src/StdCheats.sol","lib/forge-std/src/StdConstants.sol","lib/forge-std/src/StdError.sol","lib/forge-std/src/StdInvariant.sol","lib/forge-std/src/StdJson.sol","lib/forge-std/src/StdMath.sol","lib/forge-std/src/StdStorage.sol","lib/forge-std/src/StdStyle.sol","lib/forge-std/src/StdToml.sol","lib/forge-std/src/StdUtils.sol","lib/forge-std/src/Test.sol","lib/forge-std/src/Vm.sol","lib/forge-std/src/console.sol","lib/forge-std/src/console2.sol","lib/forge-std/src/interfaces/IMulticall3.sol","lib/forge-std/src/safeconsole.sol","lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol","lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol","lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","lib/sequence-v3/src/modules/Payload.sol","lib/sequence-v3/src/utils/LibBytes.sol","src/helper/SignalsImplicitMode.sol","src/registry/IImplicitProjectRegistry.sol","src/registry/IImplicitProjectValidation.sol","src/registry/ImplicitProjectRegistry.sol","test/TestHelper.sol","test/mock/SignalsImplicitModeMock.sol"],"versionRequirement":"^0.8.13","artifacts":{"ImplicitProjectRegistryTest":{"0.8.28":{"default":{"path":"ImplicitProjectRegistry.t.sol/ImplicitProjectRegistryTest.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"test/SignalsImplicitMode.t.sol":{"lastModificationDate":1770361770325,"contentHash":"53f3acacdb557256","interfaceReprHash":null,"sourceName":"test/SignalsImplicitMode.t.sol","imports":["lib/forge-std/src/Base.sol","lib/forge-std/src/StdAssertions.sol","lib/forge-std/src/StdChains.sol","lib/forge-std/src/StdCheats.sol","lib/forge-std/src/StdConstants.sol","lib/forge-std/src/StdError.sol","lib/forge-std/src/StdInvariant.sol","lib/forge-std/src/StdJson.sol","lib/forge-std/src/StdMath.sol","lib/forge-std/src/StdStorage.sol","lib/forge-std/src/StdStyle.sol","lib/forge-std/src/StdToml.sol","lib/forge-std/src/StdUtils.sol","lib/forge-std/src/Test.sol","lib/forge-std/src/Vm.sol","lib/forge-std/src/console.sol","lib/forge-std/src/console2.sol","lib/forge-std/src/interfaces/IMulticall3.sol","lib/forge-std/src/safeconsole.sol","lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol","lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol","lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","lib/sequence-v3/src/modules/Payload.sol","lib/sequence-v3/src/utils/LibBytes.sol","src/helper/SignalsImplicitMode.sol","src/registry/IImplicitProjectRegistry.sol","src/registry/IImplicitProjectValidation.sol","src/registry/ImplicitProjectRegistry.sol","test/TestHelper.sol","test/mock/SignalsImplicitModeMock.sol"],"versionRequirement":"^0.8.13","artifacts":{"SignalsImplicitModeTest":{"0.8.28":{"default":{"path":"SignalsImplicitMode.t.sol/SignalsImplicitModeTest.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"test/TestHelper.sol":{"lastModificationDate":1770361770382,"contentHash":"a23c385df903ee97","interfaceReprHash":null,"sourceName":"test/TestHelper.sol","imports":[],"versionRequirement":"^0.8.13","artifacts":{"TestHelper":{"0.8.28":{"default":{"path":"TestHelper.sol/TestHelper.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true},"test/mock/SignalsImplicitModeMock.sol":{"lastModificationDate":1770361771227,"contentHash":"b71bc913f2524674","interfaceReprHash":null,"sourceName":"test/mock/SignalsImplicitModeMock.sol","imports":["lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol","lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol","lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","lib/sequence-v3/src/modules/Payload.sol","lib/sequence-v3/src/utils/LibBytes.sol","src/helper/SignalsImplicitMode.sol","src/registry/IImplicitProjectValidation.sol"],"versionRequirement":"^0.8.13","artifacts":{"SignalsImplicitModeMock":{"0.8.28":{"default":{"path":"SignalsImplicitModeMock.sol/SignalsImplicitModeMock.json","build_id":"6df801dae8a4cdc2"}}}},"seenByCompiler":true}},"builds":["6df801dae8a4cdc2","efb7c762ba0fcac7"],"profiles":{"default":{"solc":{"optimizer":{"enabled":false,"runs":200},"metadata":{"useLiteralContent":false,"bytecodeHash":"ipfs","appendCBOR":true},"outputSelection":{"*":{"*":["abi","evm.bytecode.object","evm.bytecode.sourceMap","evm.bytecode.linkReferences","evm.deployedBytecode.object","evm.deployedBytecode.sourceMap","evm.deployedBytecode.linkReferences","evm.deployedBytecode.immutableReferences","evm.methodIdentifiers","metadata"]}},"evmVersion":"paris","viaIR":false,"libraries":{}},"vyper":{"evmVersion":"paris","outputSelection":{"*":{"*":["abi","evm.bytecode","evm.deployedBytecode"]}}}}},"preprocessed":false,"mocks":[]} \ No newline at end of file diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.github/CODEOWNERS b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.github/CODEOWNERS deleted file mode 100644 index beae7aa872..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.github/CODEOWNERS +++ /dev/null @@ -1 +0,0 @@ -* @danipopes @klkvr @mattsse @grandizzy @yash-atreya @zerosnacks @onbjerg @0xrusowsky \ No newline at end of file diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.github/dependabot.yml b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.github/dependabot.yml deleted file mode 100644 index 5ace4600a1..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.github/dependabot.yml +++ /dev/null @@ -1,6 +0,0 @@ -version: 2 -updates: - - package-ecosystem: "github-actions" - directory: "/" - schedule: - interval: "weekly" diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.github/workflows/ci.yml b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.github/workflows/ci.yml deleted file mode 100644 index 0d81c7551c..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.github/workflows/ci.yml +++ /dev/null @@ -1,125 +0,0 @@ -name: CI - -permissions: {} - -on: - workflow_dispatch: - pull_request: - push: - branches: - - master - -jobs: - build: - name: build +${{ matrix.toolchain }} ${{ matrix.flags }} - runs-on: ubuntu-latest - timeout-minutes: 10 - permissions: - contents: read - strategy: - fail-fast: false - matrix: - toolchain: [stable, nightly] - flags: - - "" - - --via-ir - - --use solc:0.8.33 --via-ir - - --use solc:0.8.33 - - --use solc:0.8.13 --via-ir - - --use solc:0.8.13 - steps: - - uses: actions/checkout@v6 - with: - persist-credentials: false - - uses: foundry-rs/foundry-toolchain@v1 - with: - version: ${{ matrix.toolchain }} - - run: forge --version - - run: forge build -vvvvv --skip test --deny warnings ${{ matrix.flags }} --contracts 'test/compilation/*' - - test: - runs-on: ubuntu-latest - timeout-minutes: 10 - permissions: - contents: read - strategy: - fail-fast: false - matrix: - toolchain: [stable, nightly] - steps: - - uses: actions/checkout@v6 - with: - persist-credentials: false - - uses: foundry-rs/foundry-toolchain@v1 - with: - version: ${{ matrix.toolchain }} - - run: forge --version - - run: forge test -vvv - - fmt: - runs-on: ubuntu-latest - timeout-minutes: 10 - permissions: - contents: read - steps: - - uses: actions/checkout@v6 - with: - persist-credentials: false - - uses: foundry-rs/foundry-toolchain@v1 - - run: forge --version - - run: forge fmt --check - - typos: - runs-on: ubuntu-latest - timeout-minutes: 10 - permissions: - contents: read - steps: - - uses: actions/checkout@v6 - with: - persist-credentials: false - - uses: crate-ci/typos@5c19779cb52ea50e151f5a10333ccd269227b5ae # v1 - - codeql: - name: Analyze (${{ matrix.language }}) - runs-on: ubuntu-latest - permissions: - security-events: write - actions: read - contents: read - strategy: - fail-fast: false - matrix: - include: - - language: actions - build-mode: none - steps: - - name: Checkout repository - uses: actions/checkout@v6 - with: - persist-credentials: false - - name: Initialize CodeQL - uses: github/codeql-action/init@v4 - with: - languages: ${{ matrix.language }} - build-mode: ${{ matrix.build-mode }} - - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v4 - with: - category: "/language:${{matrix.language}}" - - ci-success: - runs-on: ubuntu-latest - if: always() - needs: - - build - - test - - fmt - - typos - - codeql - timeout-minutes: 10 - steps: - - name: Decide whether the needed jobs succeeded or failed - uses: re-actors/alls-green@05ac9388f0aebcb5727afa17fcccfecd6f8ec5fe # release/v1 - with: - jobs: ${{ toJSON(needs) }} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.github/workflows/sync.yml b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.github/workflows/sync.yml deleted file mode 100644 index ad4b173cdb..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.github/workflows/sync.yml +++ /dev/null @@ -1,36 +0,0 @@ -name: Sync Release Branch - -permissions: {} - -on: - release: - types: - - created - -jobs: - sync-release-branch: - runs-on: ubuntu-latest - permissions: - contents: write - if: startsWith(github.event.release.tag_name, 'v1') - steps: - - name: Check out the repo - uses: actions/checkout@v6 - with: - persist-credentials: true - fetch-depth: 0 - ref: v1 - - # The email is derived from the bots user id, - # found here: https://api.github.com/users/github-actions%5Bbot%5D - - name: Configure Git - run: | - git config user.name github-actions[bot] - git config user.email 41898282+github-actions[bot]@users.noreply.github.com - - - name: Sync Release Branch - run: | - git fetch --tags - git checkout v1 - git reset --hard ${GITHUB_REF} - git push --force diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.gitignore b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.gitignore deleted file mode 100644 index 756106d388..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -cache/ -out/ -.vscode -.idea diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/CONTRIBUTING.md b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/CONTRIBUTING.md deleted file mode 100644 index 3e84a2b458..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/CONTRIBUTING.md +++ /dev/null @@ -1,193 +0,0 @@ -## Contributing to Foundry - -Thanks for your interest in improving Foundry! - -There are multiple opportunities to contribute at any level. It doesn't matter if you are just getting started with Rust or are the most weathered expert, we can use your help. - -This document will help you get started. **Do not let the document intimidate you**. -It should be considered as a guide to help you navigate the process. - -The [dev Telegram][dev-tg] is available for any concerns you may have that are not covered in this guide. - -### Code of Conduct - -The Foundry project adheres to the [Rust Code of Conduct][rust-coc]. This code of conduct describes the _minimum_ behavior expected from all contributors. - -Instances of violations of the Code of Conduct can be reported by contacting the team at [me@gakonst.com](mailto:me@gakonst.com). - -### Ways to contribute - -There are fundamentally four ways an individual can contribute: - -1. **By opening an issue:** For example, if you believe that you have uncovered a bug - in Foundry, creating a new issue in the issue tracker is the way to report it. -2. **By adding context:** Providing additional context to existing issues, - such as screenshots and code snippets, which help resolve issues. -3. **By resolving issues:** Typically this is done in the form of either - demonstrating that the issue reported is not a problem after all, or more often, - by opening a pull request that fixes the underlying problem, in a concrete and - reviewable manner. - -**Anybody can participate in any stage of contribution**. We urge you to participate in the discussion -around bugs and participate in reviewing PRs. - -### Contributions Related to Spelling and Grammar - -At this time, we will not be accepting contributions that only fix spelling or grammatical errors in documentation, code or -elsewhere. - -### Asking for help - -If you have reviewed existing documentation and still have questions, or you are having problems, you can get help in the following ways: - -- **Asking in the support Telegram:** The [Foundry Support Telegram][support-tg] is a fast and easy way to ask questions. -- **Opening a discussion:** This repository comes with a discussions board where you can also ask for help. Click the "Discussions" tab at the top. - -As Foundry is still in heavy development, the documentation can be a bit scattered. -The [Foundry Book][foundry-book] is our current best-effort attempt at keeping up-to-date information. - -### Submitting a bug report - -When filing a new bug report in the issue tracker, you will be presented with a basic form to fill out. - -If you believe that you have uncovered a bug, please fill out the form to the best of your ability. Do not worry if you cannot answer every detail; just fill in what you can. Contributors will ask follow-up questions if something is unclear. - -The most important pieces of information we need in a bug report are: - -- The Foundry version you are on (and that it is up to date) -- The platform you are on (Windows, macOS, an M1 Mac or Linux) -- Code snippets if this is happening in relation to testing or building code -- Concrete steps to reproduce the bug - -In order to rule out the possibility of the bug being in your project, the code snippets should be as minimal -as possible. It is better if you can reproduce the bug with a small snippet as opposed to an entire project! - -See [this guide][mcve] on how to create a minimal, complete, and verifiable example. - -### Submitting a feature request - -When adding a feature request in the issue tracker, you will be presented with a basic form to fill out. - -Please include as detailed of an explanation as possible of the feature you would like, adding additional context if necessary. - -If you have examples of other tools that have the feature you are requesting, please include them as well. - -### Resolving an issue - -Pull requests are the way concrete changes are made to the code, documentation, and dependencies of Foundry. - -Even minor pull requests, such as those fixing wording, are greatly appreciated. Before making a large change, it is usually -a good idea to first open an issue describing the change to solicit feedback and guidance. This will increase -the likelihood of the PR getting merged. - -Please make sure that the following commands pass if you have changed the code: - -```sh -forge fmt --check -forge test -vvv -``` - -To make sure your changes are compatible with all compiler version targets, run the following commands: - -```sh -forge build --skip test --use solc:0.6.2 -forge build --skip test --use solc:0.6.12 -forge build --skip test --use solc:0.7.0 -forge build --skip test --use solc:0.7.6 -forge build --skip test --use solc:0.8.0 -``` - -The CI will also ensure that the code is formatted correctly and that the tests are passing across all compiler version targets. - -#### Adding cheatcodes - -Please follow the guide outlined in the [cheatcodes](https://github.com/foundry-rs/foundry/blob/master/docs/dev/cheatcodes.md#adding-a-new-cheatcode) documentation of Foundry. - -When making modifications to the native cheatcodes or adding new ones, please make sure to run [`./scripts/vm.py`](./scripts/vm.py) to update the cheatcodes in the [`src/Vm.sol`](./src/Vm.sol) file. - -By default the script will automatically generate the cheatcodes from the [`cheatcodes.json`](https://raw.githubusercontent.com/foundry-rs/foundry/master/crates/cheatcodes/assets/cheatcodes.json) file but alternatively you can provide a path to a JSON file containing the Vm interface, as generated by Foundry, with the `--from` flag. - -```sh -./scripts/vm.py --from path/to/cheatcodes.json -``` - -It is possible that the resulting [`src/Vm.sol`](./src/Vm.sol) file will have some changes that are not directly related to your changes, this is not a problem. - -#### Commits - -It is a recommended best practice to keep your changes as logically grouped as possible within individual commits. There is no limit to the number of commits any single pull request may have, and many contributors find it easier to review changes that are split across multiple commits. - -That said, if you have a number of commits that are "checkpoints" and don't represent a single logical change, please squash those together. - -#### Opening the pull request - -From within GitHub, opening a new pull request will present you with a template that should be filled out. Please try your best at filling out the details, but feel free to skip parts if you're not sure what to put. - -#### Discuss and update - -You will probably get feedback or requests for changes to your pull request. -This is a big part of the submission process, so don't be discouraged! Some contributors may sign off on the pull request right away, others may have more detailed comments or feedback. -This is a necessary part of the process in order to evaluate whether the changes are correct and necessary. - -**Any community member can review a PR, so you might get conflicting feedback**. -Keep an eye out for comments from code owners to provide guidance on conflicting feedback. - -#### Reviewing pull requests - -**Any Foundry community member is welcome to review any pull request**. - -All contributors who choose to review and provide feedback on pull requests have a responsibility to both the project and individual making the contribution. Reviews and feedback must be helpful, insightful, and geared towards improving the contribution as opposed to simply blocking it. If there are reasons why you feel the PR should not be merged, explain what those are. Do not expect to be able to block a PR from advancing simply because you say "no" without giving an explanation. Be open to having your mind changed. Be open to working _with_ the contributor to make the pull request better. - -Reviews that are dismissive or disrespectful of the contributor or any other reviewers are strictly counter to the Code of Conduct. - -When reviewing a pull request, the primary goals are for the codebase to improve and for the person submitting the request to succeed. **Even if a pull request is not merged, the submitter should come away from the experience feeling like their effort was not unappreciated**. Every PR from a new contributor is an opportunity to grow the community. - -##### Review a bit at a time - -Do not overwhelm new contributors. - -It is tempting to micro-optimize and make everything about relative performance, perfect grammar, or exact style matches. Do not succumb to that temptation. - -Focus first on the most significant aspects of the change: - -1. Does this change make sense for Foundry? -2. Does this change make Foundry better, even if only incrementally? -3. Are there clear bugs or larger scale issues that need attending? -4. Are the commit messages readable and correct? If it contains a breaking change, is it clear enough? - -Note that only **incremental** improvement is needed to land a PR. This means that the PR does not need to be perfect, only better than the status quo. Follow-up PRs may be opened to continue iterating. - -When changes are necessary, _request_ them, do not _demand_ them, and **do not assume that the submitter already knows how to add a test or run a benchmark**. - -Specific performance optimization techniques, coding styles and conventions change over time. The first impression you give to a new contributor never does. - -Nits (requests for small changes that are not essential) are fine, but try to avoid stalling the pull request. Most nits can typically be fixed by the Foundry maintainers merging the pull request, but they can also be an opportunity for the contributor to learn a bit more about the project. - -It is always good to clearly indicate nits when you comment, e.g.: `Nit: change foo() to bar(). But this is not blocking`. - -If your comments were addressed but were not folded after new commits, or if they proved to be mistaken, please, [hide them][hiding-a-comment] with the appropriate reason to keep the conversation flow concise and relevant. - -##### Be aware of the person behind the code - -Be aware that _how_ you communicate requests and reviews in your feedback can have a significant impact on the success of the pull request. Yes, we may merge a particular change that makes Foundry better, but the individual might just not want to have anything to do with Foundry ever again. The goal is not just having good code. - -##### Abandoned or stale pull requests - -If a pull request appears to be abandoned or stalled, it is polite to first check with the contributor to see if they intend to continue the work before checking if they would mind if you took it over (especially if it just has nits left). When doing so, it is courteous to give the original contributor credit for the work they started, either by preserving their name and e-mail address in the commit log, or by using the `Author: ` or `Co-authored-by: ` metadata tag in the commits. - -_Adapted from the [ethers-rs contributing guide](https://github.com/gakonst/ethers-rs/blob/master/CONTRIBUTING.md)_. - -### Releasing - -Releases are automatically done by the release workflow when a tag is pushed, however, these steps still need to be taken: - -1. Ensure that the versions in the relevant `Cargo.toml` files are up-to-date. -2. Update documentation links -3. Perform a final audit for breaking changes. - -[rust-coc]: https://github.com/rust-lang/rust/blob/master/CODE_OF_CONDUCT.md -[dev-tg]: https://t.me/foundry_rs -[foundry-book]: https://github.com/foundry-rs/foundry-book -[support-tg]: https://t.me/foundry_support -[mcve]: https://stackoverflow.com/help/mcve -[hiding-a-comment]: https://help.github.com/articles/managing-disruptive-comments/#hiding-a-comment diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/LICENSE-APACHE b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/LICENSE-APACHE deleted file mode 100644 index cf01a499fb..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/LICENSE-APACHE +++ /dev/null @@ -1,203 +0,0 @@ -Copyright Contributors to Forge Standard Library - - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - -TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - -1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - -2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - -3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - -4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - -5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - -6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - -7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - -8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - -9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - -END OF TERMS AND CONDITIONS - -APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - -Copyright [yyyy] [name of copyright owner] - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/LICENSE-MIT b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/LICENSE-MIT deleted file mode 100644 index 28f98304ac..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/LICENSE-MIT +++ /dev/null @@ -1,25 +0,0 @@ -Copyright Contributors to Forge Standard Library - -Permission is hereby granted, free of charge, to any -person obtaining a copy of this software and associated -documentation files (the "Software"), to deal in the -Software without restriction, including without -limitation the rights to use, copy, modify, merge, -publish, distribute, sublicense, and/or sell copies of -the Software, and to permit persons to whom the Software -is furnished to do so, subject to the following -conditions: - -The above copyright notice and this permission notice -shall be included in all copies or substantial portions -of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF -ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED -TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A -PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT -SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR -IN CONNECTION WITH THE SOFTWARE O THE USE OR OTHER -DEALINGS IN THE SOFTWARE.R diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/README.md b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/README.md deleted file mode 100644 index 8eb95bd8ef..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/README.md +++ /dev/null @@ -1,268 +0,0 @@ -# Forge Standard Library • [![CI status](https://github.com/foundry-rs/forge-std/actions/workflows/ci.yml/badge.svg)](https://github.com/foundry-rs/forge-std/actions/workflows/ci.yml) - -Forge Standard Library is a collection of helpful contracts and libraries for use with [Forge and Foundry](https://github.com/foundry-rs/foundry). It leverages Forge's cheatcodes to make writing tests easier and faster, while improving the UX of cheatcodes. - -**Learn how to use Forge-Std with the [📖 Foundry Book (Forge-Std Guide)](https://getfoundry.sh/reference/forge-std/overview/).** - -## Install - -```bash -forge install foundry-rs/forge-std -``` - -## Contracts - -### stdError - -This is a helper contract for errors and reverts. In Forge, this contract is particularly helpful for the `expectRevert` cheatcode, as it provides all compiler built-in errors. - -See the contract itself for all error codes. - -#### Example usage - -```solidity - -import "forge-std/Test.sol"; - -contract TestContract is Test { - ErrorsTest test; - - function setUp() public { - test = new ErrorsTest(); - } - - function testExpectArithmetic() public { - vm.expectRevert(stdError.arithmeticError); - test.arithmeticError(10); - } -} - -contract ErrorsTest { - function arithmeticError(uint256 a) public { - a = a - 100; - } -} -``` - -### stdStorage - -This is a rather large contract due to all of the overloading to make the UX decent. Primarily, it is a wrapper around the `record` and `accesses` cheatcodes. It can _always_ find and write the storage slot(s) associated with a particular variable without knowing the storage layout. The one _major_ caveat to this is while a slot can be found for packed storage variables, we can't write to that variable safely. If a user tries to write to a packed slot, the execution throws an error, unless it is uninitialized (`bytes32(0)`). - -This works by recording all `SLOAD`s and `SSTORE`s during a function call. If there is a single slot read or written to, it immediately returns the slot. Otherwise, behind the scenes, we iterate through and check each one (assuming the user passed in a `depth` parameter). If the variable is a struct, you can pass in a `depth` parameter which is basically the field depth. - -I.e.: - -```solidity -struct T { - // depth 0 - uint256 a; - // depth 1 - uint256 b; -} -``` - -#### Example usage - -```solidity -import "forge-std/Test.sol"; - -contract TestContract is Test { - using stdStorage for StdStorage; - - Storage test; - - function setUp() public { - test = new Storage(); - } - - function testFindExists() public { - // Let's say we want to find the slot for the public - // variable `exists`. We just pass in the function selector - // to the `find` command - uint256 slot = stdstore.target(address(test)).sig("exists()").find(); - assertEq(slot, 0); - } - - function testWriteExists() public { - // Let's say we want to write to the slot for the public - // variable `exists`. We just pass in the function selector - // to the `checked_write` command - stdstore.target(address(test)).sig("exists()").checked_write(100); - assertEq(test.exists(), 100); - } - - // It supports arbitrary storage layouts, like assembly based storage locations - function testFindHidden() public { - // `hidden` is a random hash of a bytes, iteration through slots would - // not find it. Our mechanism does - // Also, you can use the selector instead of a string - uint256 slot = stdstore.target(address(test)).sig(test.hidden.selector).find(); - assertEq(slot, uint256(keccak256("my.random.var"))); - } - - // If targeting a mapping, you have to pass in the keys necessary to perform the find - // i.e.: - function testFindMapping() public { - uint256 slot = stdstore - .target(address(test)) - .sig(test.map_addr.selector) - .with_key(address(this)) - .find(); - // in the `Storage` constructor, we wrote that this address' value was 1 in the map - // so when we load the slot, we expect it to be 1 - assertEq(uint(vm.load(address(test), bytes32(slot))), 1); - } - - // If the target is a struct, you can specify the field depth: - function testFindStruct() public { - // NOTE: see the depth parameter - 0 means 0th field, 1 means 1st field, etc. - uint256 slot_for_a_field = stdstore - .target(address(test)) - .sig(test.basicStruct.selector) - .depth(0) - .find(); - - uint256 slot_for_b_field = stdstore - .target(address(test)) - .sig(test.basicStruct.selector) - .depth(1) - .find(); - - assertEq(uint(vm.load(address(test), bytes32(slot_for_a_field))), 1); - assertEq(uint(vm.load(address(test), bytes32(slot_for_b_field))), 2); - } -} - -// A complex storage contract -contract Storage { - struct UnpackedStruct { - uint256 a; - uint256 b; - } - - constructor() { - map_addr[msg.sender] = 1; - } - - uint256 public exists = 1; - mapping(address => uint256) public map_addr; - // mapping(address => Packed) public map_packed; - mapping(address => UnpackedStruct) public map_struct; - mapping(address => mapping(address => uint256)) public deep_map; - mapping(address => mapping(address => UnpackedStruct)) public deep_map_struct; - UnpackedStruct public basicStruct = UnpackedStruct({ - a: 1, - b: 2 - }); - - function hidden() public view returns (bytes32 t) { - // an extremely hidden storage slot - bytes32 slot = keccak256("my.random.var"); - assembly { - t := sload(slot) - } - } -} -``` - -### stdCheats - -This is a wrapper over miscellaneous cheatcodes that need wrappers to be more dev friendly. Currently there are only functions related to `prank`. In general, users may expect ETH to be put into an address on `prank`, but this is not the case for safety reasons. Explicitly this `hoax` function should only be used for addresses that have expected balances as it will get overwritten. If an address already has ETH, you should just use `prank`. If you want to change that balance explicitly, just use `deal`. If you want to do both, `hoax` is also right for you. - -#### Example usage: - -```solidity - -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity ^0.8.0; - -import "forge-std/Test.sol"; - -// Inherit the stdCheats -contract StdCheatsTest is Test { - Bar test; - function setUp() public { - test = new Bar(); - } - - function testHoax() public { - // we call `hoax`, which gives the target address - // eth and then calls `prank` - hoax(address(1337)); - test.bar{value: 100}(address(1337)); - - // overloaded to allow you to specify how much eth to - // initialize the address with - hoax(address(1337), 1); - test.bar{value: 1}(address(1337)); - } - - function testStartHoax() public { - // we call `startHoax`, which gives the target address - // eth and then calls `startPrank` - // - // it is also overloaded so that you can specify an eth amount - startHoax(address(1337)); - test.bar{value: 100}(address(1337)); - test.bar{value: 100}(address(1337)); - vm.stopPrank(); - test.bar(address(this)); - } -} - -contract Bar { - function bar(address expectedSender) public payable { - require(msg.sender == expectedSender, "!prank"); - } -} -``` - -### Std Assertions - -Contains various assertions. - -### `console.log` - -Usage follows the same format as [Hardhat](https://hardhat.org/hardhat-network/reference/#console-log). -It's recommended to use `console2.sol` as shown below, as this will show the decoded logs in Forge traces. - -```solidity -// import it indirectly via Test.sol -import "forge-std/Test.sol"; -// or directly import it -import "forge-std/console2.sol"; -... -console2.log(someValue); -``` - -If you need compatibility with Hardhat, you must use the standard `console.sol` instead. -Due to a bug in `console.sol`, logs that use `uint256` or `int256` types will not be properly decoded in Forge traces. - -```solidity -// import it indirectly via Test.sol -import "forge-std/Test.sol"; -// or directly import it -import "forge-std/console.sol"; -... -console.log(someValue); -``` - -## Contributing - -See our [contributing guidelines](./CONTRIBUTING.md). - -## Getting Help - -First, see if the answer to your question can be found in [book](https://getfoundry.sh/). - -If the answer is not there: - -- Join the [support Telegram](https://t.me/foundry_support) to get help, or -- Open a [discussion](https://github.com/foundry-rs/foundry/discussions/new/choose) with your question, or -- Open an issue with [the bug](https://github.com/foundry-rs/foundry/issues/new/choose) - -If you want to contribute, or follow along with contributor discussion, you can use our [main telegram](https://t.me/foundry_rs) to chat with us about the development of Foundry! - -## License - -Forge Standard Library is offered under either [MIT](LICENSE-MIT) or [Apache 2.0](LICENSE-APACHE) license. diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/RELEASE_CHECKLIST.md b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/RELEASE_CHECKLIST.md deleted file mode 100644 index 4611de4dce..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/RELEASE_CHECKLIST.md +++ /dev/null @@ -1,12 +0,0 @@ -# Release checklist - -This checklist is meant to be used as a guide for the `forge-std` release process. - -## Steps - -- [ ] Update the version number in `package.json` -- [ ] Open and merge a PR with the version bump -- [ ] Tag the merged commit with the version number: `git tag v` -- [ ] Push the tag to the repository: `git push --tags` -- [ ] Create a new GitHub release with the automatically generated changelog and with the name set to `v` -- [ ] Add `## Featured Changes` section to the top of the release notes diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/scripts/vm.py b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/scripts/vm.py deleted file mode 100644 index c79793b0d5..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/scripts/vm.py +++ /dev/null @@ -1,636 +0,0 @@ -#!/usr/bin/env python3 - -import argparse -import copy -import json -import re -import subprocess -from enum import Enum as PyEnum -from pathlib import Path -from typing import Callable -from urllib import request - -VoidFn = Callable[[], None] - -CHEATCODES_JSON_URL = "https://raw.githubusercontent.com/foundry-rs/foundry/master/crates/cheatcodes/assets/cheatcodes.json" -OUT_PATH = "src/Vm.sol" - -VM_SAFE_DOC = """\ -/// The `VmSafe` interface does not allow manipulation of the EVM state or other actions that may -/// result in Script simulations differing from on-chain execution. It is recommended to only use -/// these cheats in scripts. -""" - -VM_DOC = """\ -/// The `Vm` interface does allow manipulation of the EVM state. These are all intended to be used -/// in tests, but it is not recommended to use these cheats in scripts. -""" - - -def main(): - parser = argparse.ArgumentParser( - description="Generate Vm.sol based on the cheatcodes json created by Foundry") - parser.add_argument( - "--from", - metavar="PATH", - dest="path", - required=False, - help="path to a json file containing the Vm interface, as generated by Foundry") - args = parser.parse_args() - json_str = request.urlopen(CHEATCODES_JSON_URL).read().decode("utf-8") if args.path is None else Path(args.path).read_text() - contract = Cheatcodes.from_json(json_str) - - ccs = contract.cheatcodes - ccs = list(filter(lambda cc: cc.status not in ["experimental", "internal"], ccs)) - ccs.sort(key=lambda cc: cc.func.id) - - safe = list(filter(lambda cc: cc.safety == "safe", ccs)) - safe.sort(key=CmpCheatcode) - unsafe = list(filter(lambda cc: cc.safety == "unsafe", ccs)) - unsafe.sort(key=CmpCheatcode) - assert len(safe) + len(unsafe) == len(ccs) - - prefix_with_group_headers(safe) - prefix_with_group_headers(unsafe) - - out = "" - - out += "// Automatically @generated by scripts/vm.py. Do not modify manually.\n\n" - - pp = CheatcodesPrinter( - spdx_identifier="MIT OR Apache-2.0", - solidity_requirement=">=0.8.13 <0.9.0", - ) - pp.p_prelude() - pp.prelude = False - out += pp.finish() - - out += "\n\n" - out += VM_SAFE_DOC - vm_safe = Cheatcodes( - # TODO: Custom errors were introduced in 0.8.4 - errors=[], # contract.errors - events=contract.events, - enums=contract.enums, - structs=contract.structs, - cheatcodes=safe, - ) - pp.p_contract(vm_safe, "VmSafe") - out += pp.finish() - - out += "\n\n" - out += VM_DOC - vm_unsafe = Cheatcodes( - errors=[], - events=[], - enums=[], - structs=[], - cheatcodes=unsafe, - ) - pp.p_contract(vm_unsafe, "Vm", "VmSafe") - out += pp.finish() - - # Compatibility with <0.8.0 - def memory_to_calldata(m: re.Match) -> str: - return " calldata " + m.group(1) - - out = re.sub(r" memory (.*returns)", memory_to_calldata, out) - - with open(OUT_PATH, "w") as f: - f.write(out) - - forge_fmt = ["forge", "fmt", OUT_PATH] - res = subprocess.run(forge_fmt) - assert res.returncode == 0, f"command failed: {forge_fmt}" - - print(f"Wrote to {OUT_PATH}") - - -class CmpCheatcode: - cheatcode: "Cheatcode" - - def __init__(self, cheatcode: "Cheatcode"): - self.cheatcode = cheatcode - - def __lt__(self, other: "CmpCheatcode") -> bool: - return cmp_cheatcode(self.cheatcode, other.cheatcode) < 0 - - def __eq__(self, other: "CmpCheatcode") -> bool: - return cmp_cheatcode(self.cheatcode, other.cheatcode) == 0 - - def __gt__(self, other: "CmpCheatcode") -> bool: - return cmp_cheatcode(self.cheatcode, other.cheatcode) > 0 - - -def cmp_cheatcode(a: "Cheatcode", b: "Cheatcode") -> int: - if a.group != b.group: - return -1 if a.group < b.group else 1 - if a.status != b.status: - return -1 if a.status < b.status else 1 - if a.safety != b.safety: - return -1 if a.safety < b.safety else 1 - if a.func.id != b.func.id: - return -1 if a.func.id < b.func.id else 1 - return 0 - - -# HACK: A way to add group header comments without having to modify printer code -def prefix_with_group_headers(cheats: list["Cheatcode"]): - s = set() - for i, cheat in enumerate(cheats): - if cheat.group in s: - continue - - s.add(cheat.group) - - c = copy.deepcopy(cheat) - c.func.description = "" - c.func.declaration = f"// ======== {group(c.group)} ========" - cheats.insert(i, c) - return cheats - - -def group(s: str) -> str: - if s == "evm": - return "EVM" - if s == "json": - return "JSON" - return s[0].upper() + s[1:] - - -class Visibility(PyEnum): - EXTERNAL: str = "external" - PUBLIC: str = "public" - INTERNAL: str = "internal" - PRIVATE: str = "private" - - def __str__(self): - return self.value - - -class Mutability(PyEnum): - PURE: str = "pure" - VIEW: str = "view" - NONE: str = "" - - def __str__(self): - return self.value - - -class Function: - id: str - description: str - declaration: str - visibility: Visibility - mutability: Mutability - signature: str - selector: str - selector_bytes: bytes - - def __init__( - self, - id: str, - description: str, - declaration: str, - visibility: Visibility, - mutability: Mutability, - signature: str, - selector: str, - selector_bytes: bytes, - ): - self.id = id - self.description = description - self.declaration = declaration - self.visibility = visibility - self.mutability = mutability - self.signature = signature - self.selector = selector - self.selector_bytes = selector_bytes - - @staticmethod - def from_dict(d: dict) -> "Function": - return Function( - d["id"], - d["description"], - d["declaration"], - Visibility(d["visibility"]), - Mutability(d["mutability"]), - d["signature"], - d["selector"], - bytes(d["selectorBytes"]), - ) - - -class Cheatcode: - func: Function - group: str - status: str - safety: str - - def __init__(self, func: Function, group: str, status: str, safety: str): - self.func = func - self.group = group - self.status = status - self.safety = safety - - @staticmethod - def from_dict(d: dict) -> "Cheatcode": - return Cheatcode( - Function.from_dict(d["func"]), - str(d["group"]), - str(d["status"]), - str(d["safety"]), - ) - - -class Error: - name: str - description: str - declaration: str - - def __init__(self, name: str, description: str, declaration: str): - self.name = name - self.description = description - self.declaration = declaration - - @staticmethod - def from_dict(d: dict) -> "Error": - return Error(**d) - - -class Event: - name: str - description: str - declaration: str - - def __init__(self, name: str, description: str, declaration: str): - self.name = name - self.description = description - self.declaration = declaration - - @staticmethod - def from_dict(d: dict) -> "Event": - return Event(**d) - - -class EnumVariant: - name: str - description: str - - def __init__(self, name: str, description: str): - self.name = name - self.description = description - - -class Enum: - name: str - description: str - variants: list[EnumVariant] - - def __init__(self, name: str, description: str, variants: list[EnumVariant]): - self.name = name - self.description = description - self.variants = variants - - @staticmethod - def from_dict(d: dict) -> "Enum": - return Enum( - d["name"], - d["description"], - list(map(lambda v: EnumVariant(**v), d["variants"])), - ) - - -class StructField: - name: str - ty: str - description: str - - def __init__(self, name: str, ty: str, description: str): - self.name = name - self.ty = ty - self.description = description - - -class Struct: - name: str - description: str - fields: list[StructField] - - def __init__(self, name: str, description: str, fields: list[StructField]): - self.name = name - self.description = description - self.fields = fields - - @staticmethod - def from_dict(d: dict) -> "Struct": - return Struct( - d["name"], - d["description"], - list(map(lambda f: StructField(**f), d["fields"])), - ) - - -class Cheatcodes: - errors: list[Error] - events: list[Event] - enums: list[Enum] - structs: list[Struct] - cheatcodes: list[Cheatcode] - - def __init__( - self, - errors: list[Error], - events: list[Event], - enums: list[Enum], - structs: list[Struct], - cheatcodes: list[Cheatcode], - ): - self.errors = errors - self.events = events - self.enums = enums - self.structs = structs - self.cheatcodes = cheatcodes - - @staticmethod - def from_dict(d: dict) -> "Cheatcodes": - return Cheatcodes( - errors=[Error.from_dict(e) for e in d["errors"]], - events=[Event.from_dict(e) for e in d["events"]], - enums=[Enum.from_dict(e) for e in d["enums"]], - structs=[Struct.from_dict(e) for e in d["structs"]], - cheatcodes=[Cheatcode.from_dict(e) for e in d["cheatcodes"]], - ) - - @staticmethod - def from_json(s) -> "Cheatcodes": - return Cheatcodes.from_dict(json.loads(s)) - - @staticmethod - def from_json_file(file_path: str) -> "Cheatcodes": - with open(file_path, "r") as f: - return Cheatcodes.from_dict(json.load(f)) - - -class Item(PyEnum): - ERROR: str = "error" - EVENT: str = "event" - ENUM: str = "enum" - STRUCT: str = "struct" - FUNCTION: str = "function" - - -class ItemOrder: - _list: list[Item] - - def __init__(self, list: list[Item]) -> None: - assert len(list) <= len(Item), "list must not contain more items than Item" - assert len(list) == len(set(list)), "list must not contain duplicates" - self._list = list - pass - - def get_list(self) -> list[Item]: - return self._list - - @staticmethod - def default() -> "ItemOrder": - return ItemOrder( - [ - Item.ERROR, - Item.EVENT, - Item.ENUM, - Item.STRUCT, - Item.FUNCTION, - ] - ) - - -class CheatcodesPrinter: - buffer: str - - prelude: bool - spdx_identifier: str - solidity_requirement: str - - block_doc_style: bool - - indent_level: int - _indent_str: str - - nl_str: str - - items_order: ItemOrder - - def __init__( - self, - buffer: str = "", - prelude: bool = True, - spdx_identifier: str = "UNLICENSED", - solidity_requirement: str = "", - block_doc_style: bool = False, - indent_level: int = 0, - indent_with: int | str = 4, - nl_str: str = "\n", - items_order: ItemOrder = ItemOrder.default(), - ): - self.prelude = prelude - self.spdx_identifier = spdx_identifier - self.solidity_requirement = solidity_requirement - self.block_doc_style = block_doc_style - self.buffer = buffer - self.indent_level = indent_level - self.nl_str = nl_str - - if isinstance(indent_with, int): - assert indent_with >= 0 - self._indent_str = " " * indent_with - elif isinstance(indent_with, str): - self._indent_str = indent_with - else: - assert False, "indent_with must be int or str" - - self.items_order = items_order - - def finish(self) -> str: - ret = self.buffer.rstrip() - self.buffer = "" - return ret - - def p_contract(self, contract: Cheatcodes, name: str, inherits: str = ""): - if self.prelude: - self.p_prelude(contract) - - self._p_str("interface ") - name = name.strip() - if name != "": - self._p_str(name) - self._p_str(" ") - if inherits != "": - self._p_str("is ") - self._p_str(inherits) - self._p_str(" ") - self._p_str("{") - self._p_nl() - self._with_indent(lambda: self._p_items(contract)) - self._p_str("}") - self._p_nl() - - def _p_items(self, contract: Cheatcodes): - for item in self.items_order.get_list(): - if item == Item.ERROR: - self.p_errors(contract.errors) - elif item == Item.EVENT: - self.p_events(contract.events) - elif item == Item.ENUM: - self.p_enums(contract.enums) - elif item == Item.STRUCT: - self.p_structs(contract.structs) - elif item == Item.FUNCTION: - self.p_functions(contract.cheatcodes) - else: - assert False, f"unknown item {item}" - - def p_prelude(self, contract: Cheatcodes | None = None): - self._p_str(f"// SPDX-License-Identifier: {self.spdx_identifier}") - self._p_nl() - - if self.solidity_requirement != "": - req = self.solidity_requirement - else: - req = ">=0.8.13 <0.9.0" - self._p_str(f"pragma solidity {req};") - self._p_nl() - - self._p_nl() - - def p_errors(self, errors: list[Error]): - for error in errors: - self._p_line(lambda: self.p_error(error)) - - def p_error(self, error: Error): - self._p_comment(error.description, doc=True) - self._p_line(lambda: self._p_str(error.declaration)) - - def p_events(self, events: list[Event]): - for event in events: - self._p_line(lambda: self.p_event(event)) - - def p_event(self, event: Event): - self._p_comment(event.description, doc=True) - self._p_line(lambda: self._p_str(event.declaration)) - - def p_enums(self, enums: list[Enum]): - for enum in enums: - self._p_line(lambda: self.p_enum(enum)) - - def p_enum(self, enum: Enum): - self._p_comment(enum.description, doc=True) - self._p_line(lambda: self._p_str(f"enum {enum.name} {{")) - self._with_indent(lambda: self.p_enum_variants(enum.variants)) - self._p_line(lambda: self._p_str("}")) - - def p_enum_variants(self, variants: list[EnumVariant]): - for i, variant in enumerate(variants): - self._p_indent() - self._p_comment(variant.description) - - self._p_indent() - self._p_str(variant.name) - if i < len(variants) - 1: - self._p_str(",") - self._p_nl() - - def p_structs(self, structs: list[Struct]): - for struct in structs: - self._p_line(lambda: self.p_struct(struct)) - - def p_struct(self, struct: Struct): - self._p_comment(struct.description, doc=True) - self._p_line(lambda: self._p_str(f"struct {struct.name} {{")) - self._with_indent(lambda: self.p_struct_fields(struct.fields)) - self._p_line(lambda: self._p_str("}")) - - def p_struct_fields(self, fields: list[StructField]): - for field in fields: - self._p_line(lambda: self.p_struct_field(field)) - - def p_struct_field(self, field: StructField): - self._p_comment(field.description) - self._p_indented(lambda: self._p_str(f"{field.ty} {field.name};")) - - def p_functions(self, cheatcodes: list[Cheatcode]): - for cheatcode in cheatcodes: - self._p_line(lambda: self.p_function(cheatcode.func)) - - def p_function(self, func: Function): - self._p_comment(func.description, doc=True) - self._p_line(lambda: self._p_str(func.declaration)) - - def _p_comment(self, s: str, doc: bool = False): - s = s.strip() - if s == "": - return - - s = map(lambda line: line.lstrip(), s.split("\n")) - if self.block_doc_style: - self._p_str("/*") - if doc: - self._p_str("*") - self._p_nl() - for line in s: - self._p_indent() - self._p_str(" ") - if doc: - self._p_str("* ") - self._p_str(line) - self._p_nl() - self._p_indent() - self._p_str(" */") - self._p_nl() - else: - first_line = True - for line in s: - if not first_line: - self._p_indent() - first_line = False - - if doc: - self._p_str("/// ") - else: - self._p_str("// ") - self._p_str(line) - self._p_nl() - - def _with_indent(self, f: VoidFn): - self._inc_indent() - f() - self._dec_indent() - - def _p_line(self, f: VoidFn): - self._p_indent() - f() - self._p_nl() - - def _p_indented(self, f: VoidFn): - self._p_indent() - f() - - def _p_indent(self): - for _ in range(self.indent_level): - self._p_str(self._indent_str) - - def _p_nl(self): - self._p_str(self.nl_str) - - def _p_str(self, txt: str): - self.buffer += txt - - def _inc_indent(self): - self.indent_level += 1 - - def _dec_indent(self): - self.indent_level -= 1 - - -if __name__ == "__main__": - main() diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Base.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Base.sol deleted file mode 100644 index d948010fe9..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Base.sol +++ /dev/null @@ -1,48 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {StdStorage} from "./StdStorage.sol"; -import {Vm, VmSafe} from "./Vm.sol"; - -abstract contract CommonBase { - /// @dev Cheat code address. - /// Calculated as `address(uint160(uint256(keccak256("hevm cheat code"))))`. - address internal constant VM_ADDRESS = 0x7109709ECfa91a80626fF3989D68f67F5b1DD12D; - - /// @dev console.sol and console2.sol work by executing a staticcall to this address. - /// Calculated as `address(uint160(uint88(bytes11("console.log"))))`. - address internal constant CONSOLE = 0x000000000000000000636F6e736F6c652e6c6f67; - - /// @dev Used when deploying with create2. - /// Taken from https://github.com/Arachnid/deterministic-deployment-proxy. - address internal constant CREATE2_FACTORY = 0x4e59b44847b379578588920cA78FbF26c0B4956C; - - /// @dev The default address for tx.origin and msg.sender. - /// Calculated as `address(uint160(uint256(keccak256("foundry default caller"))))`. - address internal constant DEFAULT_SENDER = 0x1804c8AB1F12E6bbf3894d4083f33e07309d1f38; - - /// @dev The address of the first contract `CREATE`d by a running test contract. - /// When running tests, each test contract is `CREATE`d by `DEFAULT_SENDER` with nonce 1. - /// Calculated as `VM.computeCreateAddress(VM.computeCreateAddress(DEFAULT_SENDER, 1), 1)`. - address internal constant DEFAULT_TEST_CONTRACT = 0x5615dEB798BB3E4dFa0139dFa1b3D433Cc23b72f; - - /// @dev Deterministic deployment address of the Multicall3 contract. - /// Taken from https://www.multicall3.com. - address internal constant MULTICALL3_ADDRESS = 0xcA11bde05977b3631167028862bE2a173976CA11; - - /// @dev The order of the secp256k1 curve. - uint256 internal constant SECP256K1_ORDER = - 115792089237316195423570985008687907852837564279074904382605163141518161494337; - - uint256 internal constant UINT256_MAX = - 115792089237316195423570985008687907853269984665640564039457584007913129639935; - - Vm internal constant vm = Vm(VM_ADDRESS); - StdStorage internal stdstore; -} - -abstract contract TestBase is CommonBase {} - -abstract contract ScriptBase is CommonBase { - VmSafe internal constant vmSafe = VmSafe(VM_ADDRESS); -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Config.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Config.sol deleted file mode 100644 index 3d35bb583a..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Config.sol +++ /dev/null @@ -1,60 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity ^0.8.13; - -import {console} from "./console.sol"; -import {StdConfig} from "./StdConfig.sol"; -import {CommonBase} from "./Base.sol"; - -/// @notice Boilerplate to streamline the setup of multi-chain environments. -abstract contract Config is CommonBase { - // -- STORAGE (CONFIG + CHAINS + FORKS) ------------------------------------ - - /// @dev Contract instance holding the data from the TOML config file. - StdConfig internal config; - - /// @dev Array of chain IDs for which forks have been created. - uint256[] internal chainIds; - - /// @dev A mapping from a chain ID to its initialized fork ID. - mapping(uint256 => uint256) internal forkOf; - - // -- HELPER FUNCTIONS ----------------------------------------------------- - - /// @notice Loads configuration from a file. - /// - /// @dev This function instantiates a `Config` contract, caching all its config variables. - /// - /// @param filePath: the path to the TOML configuration file. - /// @param writeToFile: whether updates are written back to the TOML file. - function _loadConfig(string memory filePath, bool writeToFile) internal { - console.log("----------"); - console.log(string.concat("Loading config from '", filePath, "'")); - config = new StdConfig(filePath, writeToFile); - vm.makePersistent(address(config)); - console.log("Config successfully loaded"); - console.log("----------"); - } - - /// @notice Loads configuration from a file and creates forks for each specified chain. - /// - /// @dev This function instantiates a `Config` contract, caching all its config variables, - /// reads the configured chain ids, and iterates through them to create a fork for each one. - /// It also creates a map `forkOf[chainId] -> forkId` to easily switch between forks. - /// - /// @param filePath: the path to the TOML configuration file. - /// @param writeToFile: whether updates are written back to the TOML file. - function _loadConfigAndForks(string memory filePath, bool writeToFile) internal { - _loadConfig(filePath, writeToFile); - - console.log("Setting up forks for the configured chains..."); - uint256[] memory chains = config.getChainIds(); - for (uint256 i = 0; i < chains.length; i++) { - uint256 chainId = chains[i]; - uint256 forkId = vm.createFork(config.getRpcUrl(chainId)); - forkOf[chainId] = forkId; - chainIds.push(chainId); - } - console.log("Forks successfully created"); - console.log("----------"); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/LibVariable.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/LibVariable.sol deleted file mode 100644 index 32fe5bfa92..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/LibVariable.sol +++ /dev/null @@ -1,477 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity ^0.8.13; - -// Enable globally. -using LibVariable for Variable global; - -struct Variable { - Type ty; - bytes data; -} - -struct Type { - TypeKind kind; - bool isArray; -} - -enum TypeKind { - None, - Bool, - Address, - Bytes32, - Uint256, - Int256, - String, - Bytes -} - -/// @notice Library for type-safe coercion of the `Variable` struct to concrete types. -/// -/// @dev Ensures that when a `Variable` is cast to a concrete Solidity type, the operation is safe and the -/// underlying type matches what is expected. -/// Provides functions to check types, convert them to strings, and coerce `Variable` instances into -/// both single values and arrays of various types. -/// -/// Usage example: -/// ```solidity -/// import {LibVariable} from "./LibVariable.sol"; -/// -/// contract MyContract { -/// using LibVariable for Variable; -/// StdConfig config; // Assume 'config' is an instance of `StdConfig` and has already been loaded. -/// -/// function readValues() public { -/// // Retrieve a 'uint256' value from the config. -/// uint256 myNumber = config.get("important_number").toUint256(); -/// -/// // Would revert with `TypeMismatch` as 'important_number' isn't a `uint256` in the config file. -/// // string memory notANumber = config.get("important_number").toString(); -/// -/// // Retrieve a address array from the config. -/// address[] memory admins = config.get("whitelisted_admins").toAddressArray(); -/// } -/// } -/// ``` -library LibVariable { - error NotInitialized(); - error TypeMismatch(string expected, string actual); - error UnsafeCast(string message); - - // -- TYPE HELPERS ---------------------------------------------------- - - /// @notice Compares two Type instances for equality. - function isEqual(Type memory self, Type memory other) internal pure returns (bool) { - return self.kind == other.kind && self.isArray == other.isArray; - } - - /// @notice Compares two Type instances for equality. Reverts if they are not equal. - function assertEq(Type memory self, Type memory other) internal pure { - if (!isEqual(self, other)) { - revert TypeMismatch(toString(other), toString(self)); - } - } - - /// @notice Converts a Type struct to its full string representation (i.e. "uint256[]"). - function toString(Type memory self) internal pure returns (string memory) { - string memory tyStr = toString(self.kind); - if (!self.isArray || self.kind == TypeKind.None) { - return tyStr; - } else { - return string.concat(tyStr, "[]"); - } - } - - /// @dev Converts a `TypeKind` enum to its base string representation. - function toString(TypeKind self) internal pure returns (string memory) { - if (self == TypeKind.Bool) return "bool"; - if (self == TypeKind.Address) return "address"; - if (self == TypeKind.Bytes32) return "bytes32"; - if (self == TypeKind.Uint256) return "uint256"; - if (self == TypeKind.Int256) return "int256"; - if (self == TypeKind.String) return "string"; - if (self == TypeKind.Bytes) return "bytes"; - return "none"; - } - - /// @dev Converts a `TypeKind` enum to its base string representation. - function toTomlKey(TypeKind self) internal pure returns (string memory) { - if (self == TypeKind.Bool) return "bool"; - if (self == TypeKind.Address) return "address"; - if (self == TypeKind.Bytes32) return "bytes32"; - if (self == TypeKind.Uint256) return "uint"; - if (self == TypeKind.Int256) return "int"; - if (self == TypeKind.String) return "string"; - if (self == TypeKind.Bytes) return "bytes"; - return "none"; - } - - // -- VARIABLE HELPERS ---------------------------------------------------- - - /// @dev Checks if a `Variable` has been initialized and matches the expected type reverting if not. - modifier check(Variable memory self, Type memory expected) { - assertExists(self); - assertEq(self.ty, expected); - _; - } - - /// @dev Checks if a `Variable` has been initialized, reverting if not. - function assertExists(Variable memory self) public pure { - if (self.ty.kind == TypeKind.None) { - revert NotInitialized(); - } - } - - // -- VARIABLE COERCION FUNCTIONS (SINGLE VALUES) -------------------------- - - /// @notice Coerces a `Variable` to a `bool` value. - function toBool(Variable memory self) internal pure check(self, Type(TypeKind.Bool, false)) returns (bool) { - return abi.decode(self.data, (bool)); - } - - /// @notice Coerces a `Variable` to an `address` value. - function toAddress(Variable memory self) - internal - pure - check(self, Type(TypeKind.Address, false)) - returns (address) - { - return abi.decode(self.data, (address)); - } - - /// @notice Coerces a `Variable` to a `bytes32` value. - function toBytes32(Variable memory self) - internal - pure - check(self, Type(TypeKind.Bytes32, false)) - returns (bytes32) - { - return abi.decode(self.data, (bytes32)); - } - - /// @notice Coerces a `Variable` to a `uint256` value. - function toUint256(Variable memory self) - internal - pure - check(self, Type(TypeKind.Uint256, false)) - returns (uint256) - { - return abi.decode(self.data, (uint256)); - } - - /// @notice Coerces a `Variable` to a `uint128` value, checking for overflow. - function toUint128(Variable memory self) internal pure returns (uint128) { - uint256 value = self.toUint256(); - if (value > type(uint128).max) { - revert UnsafeCast("value does not fit in 'uint128'"); - } - return uint128(value); - } - - /// @notice Coerces a `Variable` to a `uint64` value, checking for overflow. - function toUint64(Variable memory self) internal pure returns (uint64) { - uint256 value = self.toUint256(); - if (value > type(uint64).max) { - revert UnsafeCast("value does not fit in 'uint64'"); - } - return uint64(value); - } - - /// @notice Coerces a `Variable` to a `uint32` value, checking for overflow. - function toUint32(Variable memory self) internal pure returns (uint32) { - uint256 value = self.toUint256(); - if (value > type(uint32).max) { - revert UnsafeCast("value does not fit in 'uint32'"); - } - return uint32(value); - } - - /// @notice Coerces a `Variable` to a `uint16` value, checking for overflow. - function toUint16(Variable memory self) internal pure returns (uint16) { - uint256 value = self.toUint256(); - if (value > type(uint16).max) { - revert UnsafeCast("value does not fit in 'uint16'"); - } - return uint16(value); - } - - /// @notice Coerces a `Variable` to a `uint8` value, checking for overflow. - function toUint8(Variable memory self) internal pure returns (uint8) { - uint256 value = self.toUint256(); - if (value > type(uint8).max) { - revert UnsafeCast("value does not fit in 'uint8'"); - } - return uint8(value); - } - - /// @notice Coerces a `Variable` to an `int256` value. - function toInt256(Variable memory self) internal pure check(self, Type(TypeKind.Int256, false)) returns (int256) { - return abi.decode(self.data, (int256)); - } - - /// @notice Coerces a `Variable` to an `int128` value, checking for overflow/underflow. - function toInt128(Variable memory self) internal pure returns (int128) { - int256 value = self.toInt256(); - if (value > type(int128).max || value < type(int128).min) { - revert UnsafeCast("value does not fit in 'int128'"); - } - return int128(value); - } - - /// @notice Coerces a `Variable` to an `int64` value, checking for overflow/underflow. - function toInt64(Variable memory self) internal pure returns (int64) { - int256 value = self.toInt256(); - if (value > type(int64).max || value < type(int64).min) { - revert UnsafeCast("value does not fit in 'int64'"); - } - return int64(value); - } - - /// @notice Coerces a `Variable` to an `int32` value, checking for overflow/underflow. - function toInt32(Variable memory self) internal pure returns (int32) { - int256 value = self.toInt256(); - if (value > type(int32).max || value < type(int32).min) { - revert UnsafeCast("value does not fit in 'int32'"); - } - return int32(value); - } - - /// @notice Coerces a `Variable` to an `int16` value, checking for overflow/underflow. - function toInt16(Variable memory self) internal pure returns (int16) { - int256 value = self.toInt256(); - if (value > type(int16).max || value < type(int16).min) { - revert UnsafeCast("value does not fit in 'int16'"); - } - return int16(value); - } - - /// @notice Coerces a `Variable` to an `int8` value, checking for overflow/underflow. - function toInt8(Variable memory self) internal pure returns (int8) { - int256 value = self.toInt256(); - if (value > type(int8).max || value < type(int8).min) { - revert UnsafeCast("value does not fit in 'int8'"); - } - return int8(value); - } - - /// @notice Coerces a `Variable` to a `string` value. - function toString(Variable memory self) - internal - pure - check(self, Type(TypeKind.String, false)) - returns (string memory) - { - return abi.decode(self.data, (string)); - } - - /// @notice Coerces a `Variable` to a `bytes` value. - function toBytes(Variable memory self) - internal - pure - check(self, Type(TypeKind.Bytes, false)) - returns (bytes memory) - { - return abi.decode(self.data, (bytes)); - } - - // -- VARIABLE COERCION FUNCTIONS (ARRAYS) --------------------------------- - - /// @notice Coerces a `Variable` to a `bool` array. - function toBoolArray(Variable memory self) - internal - pure - check(self, Type(TypeKind.Bool, true)) - returns (bool[] memory) - { - return abi.decode(self.data, (bool[])); - } - - /// @notice Coerces a `Variable` to an `address` array. - function toAddressArray(Variable memory self) - internal - pure - check(self, Type(TypeKind.Address, true)) - returns (address[] memory) - { - return abi.decode(self.data, (address[])); - } - - /// @notice Coerces a `Variable` to a `bytes32` array. - function toBytes32Array(Variable memory self) - internal - pure - check(self, Type(TypeKind.Bytes32, true)) - returns (bytes32[] memory) - { - return abi.decode(self.data, (bytes32[])); - } - - /// @notice Coerces a `Variable` to a `uint256` array. - function toUint256Array(Variable memory self) - internal - pure - check(self, Type(TypeKind.Uint256, true)) - returns (uint256[] memory) - { - return abi.decode(self.data, (uint256[])); - } - - /// @notice Coerces a `Variable` to a `uint128` array, checking for overflow. - function toUint128Array(Variable memory self) internal pure returns (uint128[] memory) { - uint256[] memory values = self.toUint256Array(); - uint128[] memory result = new uint128[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(uint128).max) { - revert UnsafeCast("value in array does not fit in 'uint128'"); - } - result[i] = uint128(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `uint64` array, checking for overflow. - function toUint64Array(Variable memory self) internal pure returns (uint64[] memory) { - uint256[] memory values = self.toUint256Array(); - uint64[] memory result = new uint64[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(uint64).max) { - revert UnsafeCast("value in array does not fit in 'uint64'"); - } - result[i] = uint64(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `uint32` array, checking for overflow. - function toUint32Array(Variable memory self) internal pure returns (uint32[] memory) { - uint256[] memory values = self.toUint256Array(); - uint32[] memory result = new uint32[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(uint32).max) { - revert UnsafeCast("value in array does not fit in 'uint32'"); - } - result[i] = uint32(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `uint16` array, checking for overflow. - function toUint16Array(Variable memory self) internal pure returns (uint16[] memory) { - uint256[] memory values = self.toUint256Array(); - uint16[] memory result = new uint16[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(uint16).max) { - revert UnsafeCast("value in array does not fit in 'uint16'"); - } - result[i] = uint16(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `uint8` array, checking for overflow. - function toUint8Array(Variable memory self) internal pure returns (uint8[] memory) { - uint256[] memory values = self.toUint256Array(); - uint8[] memory result = new uint8[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(uint8).max) { - revert UnsafeCast("value in array does not fit in 'uint8'"); - } - result[i] = uint8(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to an `int256` array. - function toInt256Array(Variable memory self) - internal - pure - check(self, Type(TypeKind.Int256, true)) - returns (int256[] memory) - { - return abi.decode(self.data, (int256[])); - } - - /// @notice Coerces a `Variable` to a `int128` array, checking for overflow/underflow. - function toInt128Array(Variable memory self) internal pure returns (int128[] memory) { - int256[] memory values = self.toInt256Array(); - int128[] memory result = new int128[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(int128).max || values[i] < type(int128).min) { - revert UnsafeCast("value in array does not fit in 'int128'"); - } - result[i] = int128(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `int64` array, checking for overflow/underflow. - function toInt64Array(Variable memory self) internal pure returns (int64[] memory) { - int256[] memory values = self.toInt256Array(); - int64[] memory result = new int64[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(int64).max || values[i] < type(int64).min) { - revert UnsafeCast("value in array does not fit in 'int64'"); - } - result[i] = int64(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `int32` array, checking for overflow/underflow. - function toInt32Array(Variable memory self) internal pure returns (int32[] memory) { - int256[] memory values = self.toInt256Array(); - int32[] memory result = new int32[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(int32).max || values[i] < type(int32).min) { - revert UnsafeCast("value in array does not fit in 'int32'"); - } - result[i] = int32(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `int16` array, checking for overflow/underflow. - function toInt16Array(Variable memory self) internal pure returns (int16[] memory) { - int256[] memory values = self.toInt256Array(); - int16[] memory result = new int16[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(int16).max || values[i] < type(int16).min) { - revert UnsafeCast("value in array does not fit in 'int16'"); - } - result[i] = int16(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `int8` array, checking for overflow/underflow. - function toInt8Array(Variable memory self) internal pure returns (int8[] memory) { - int256[] memory values = self.toInt256Array(); - int8[] memory result = new int8[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(int8).max || values[i] < type(int8).min) { - revert UnsafeCast("value in array does not fit in 'int8'"); - } - result[i] = int8(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `string` array. - function toStringArray(Variable memory self) - internal - pure - check(self, Type(TypeKind.String, true)) - returns (string[] memory) - { - return abi.decode(self.data, (string[])); - } - - /// @notice Coerces a `Variable` to a `bytes` array. - function toBytesArray(Variable memory self) - internal - pure - check(self, Type(TypeKind.Bytes, true)) - returns (bytes[] memory) - { - return abi.decode(self.data, (bytes[])); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Script.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Script.sol deleted file mode 100644 index d43fa8a7ab..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Script.sol +++ /dev/null @@ -1,28 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -// 💬 ABOUT -// Forge Std's default Script. - -// 🧩 MODULES -import {console} from "./console.sol"; -import {console2} from "./console2.sol"; -import {safeconsole} from "./safeconsole.sol"; -import {StdChains} from "./StdChains.sol"; -import {StdCheatsSafe} from "./StdCheats.sol"; -import {StdConstants} from "./StdConstants.sol"; -import {stdJson} from "./StdJson.sol"; -import {stdMath} from "./StdMath.sol"; -import {StdStorage, stdStorageSafe} from "./StdStorage.sol"; -import {StdStyle} from "./StdStyle.sol"; -import {StdUtils} from "./StdUtils.sol"; -import {VmSafe} from "./Vm.sol"; - -// 📦 BOILERPLATE -import {ScriptBase} from "./Base.sol"; - -// ⭐️ SCRIPT -abstract contract Script is ScriptBase, StdChains, StdCheatsSafe, StdUtils { - // Note: IS_SCRIPT() must return true. - bool public IS_SCRIPT = true; -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdAssertions.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdAssertions.sol deleted file mode 100644 index 96d13964f1..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdAssertions.sol +++ /dev/null @@ -1,779 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {Vm} from "./Vm.sol"; - -abstract contract StdAssertions { - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - - event log(string); - event logs(bytes); - - event log_address(address); - event log_bytes32(bytes32); - event log_int(int256); - event log_uint(uint256); - event log_bytes(bytes); - event log_string(string); - - event log_named_address(string key, address val); - event log_named_bytes32(string key, bytes32 val); - event log_named_decimal_int(string key, int256 val, uint256 decimals); - event log_named_decimal_uint(string key, uint256 val, uint256 decimals); - event log_named_int(string key, int256 val); - event log_named_uint(string key, uint256 val); - event log_named_bytes(string key, bytes val); - event log_named_string(string key, string val); - - event log_array(uint256[] val); - event log_array(int256[] val); - event log_array(address[] val); - event log_named_array(string key, uint256[] val); - event log_named_array(string key, int256[] val); - event log_named_array(string key, address[] val); - - bytes32 private constant FAILED_SLOT = bytes32("failed"); - - bool private _failed; - - function failed() public view returns (bool) { - if (_failed) { - return true; - } else { - return vm.load(address(vm), FAILED_SLOT) != bytes32(0); - } - } - - function fail() internal virtual { - vm.store(address(vm), FAILED_SLOT, bytes32(uint256(1))); - _failed = true; - } - - function fail(string memory message) internal virtual { - fail(); - vm.assertTrue(false, message); - } - - function assertTrue(bool data) internal pure virtual { - if (!data) { - vm.assertTrue(data); - } - } - - function assertTrue(bool data, string memory err) internal pure virtual { - if (!data) { - vm.assertTrue(data, err); - } - } - - function assertFalse(bool data) internal pure virtual { - if (data) { - vm.assertFalse(data); - } - } - - function assertFalse(bool data, string memory err) internal pure virtual { - if (data) { - vm.assertFalse(data, err); - } - } - - function assertEq(bool left, bool right) internal pure virtual { - if (left != right) { - vm.assertEq(left, right); - } - } - - function assertEq(bool left, bool right, string memory err) internal pure virtual { - if (left != right) { - vm.assertEq(left, right, err); - } - } - - function assertEq(uint256 left, uint256 right) internal pure virtual { - if (left != right) { - vm.assertEq(left, right); - } - } - - function assertEq(uint256 left, uint256 right, string memory err) internal pure virtual { - if (left != right) { - vm.assertEq(left, right, err); - } - } - - function assertEqDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertEqDecimal(left, right, decimals); - } - - function assertEqDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertEqDecimal(left, right, decimals, err); - } - - function assertEq(int256 left, int256 right) internal pure virtual { - if (left != right) { - vm.assertEq(left, right); - } - } - - function assertEq(int256 left, int256 right, string memory err) internal pure virtual { - if (left != right) { - vm.assertEq(left, right, err); - } - } - - function assertEqDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertEqDecimal(left, right, decimals); - } - - function assertEqDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertEqDecimal(left, right, decimals, err); - } - - function assertEq(address left, address right) internal pure virtual { - if (left != right) { - vm.assertEq(left, right); - } - } - - function assertEq(address left, address right, string memory err) internal pure virtual { - if (left != right) { - vm.assertEq(left, right, err); - } - } - - function assertEq(bytes32 left, bytes32 right) internal pure virtual { - if (left != right) { - vm.assertEq(left, right); - } - } - - function assertEq(bytes32 left, bytes32 right, string memory err) internal pure virtual { - if (left != right) { - vm.assertEq(left, right, err); - } - } - - function assertEq32(bytes32 left, bytes32 right) internal pure virtual { - if (left != right) { - vm.assertEq(left, right); - } - } - - function assertEq32(bytes32 left, bytes32 right, string memory err) internal pure virtual { - if (left != right) { - vm.assertEq(left, right, err); - } - } - - function assertEq(string memory left, string memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(string memory left, string memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bytes memory left, bytes memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bytes memory left, bytes memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bool[] memory left, bool[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bool[] memory left, bool[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(uint256[] memory left, uint256[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(uint256[] memory left, uint256[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(int256[] memory left, int256[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(int256[] memory left, int256[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(address[] memory left, address[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(address[] memory left, address[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bytes32[] memory left, bytes32[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bytes32[] memory left, bytes32[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(string[] memory left, string[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(string[] memory left, string[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bytes[] memory left, bytes[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bytes[] memory left, bytes[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - // Legacy helper - function assertEqUint(uint256 left, uint256 right) internal pure virtual { - assertEq(left, right); - } - - function assertNotEq(bool left, bool right) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right); - } - } - - function assertNotEq(bool left, bool right, string memory err) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right, err); - } - } - - function assertNotEq(uint256 left, uint256 right) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right); - } - } - - function assertNotEq(uint256 left, uint256 right, string memory err) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right, err); - } - } - - function assertNotEqDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertNotEqDecimal(left, right, decimals); - } - - function assertNotEqDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) - internal - pure - virtual - { - vm.assertNotEqDecimal(left, right, decimals, err); - } - - function assertNotEq(int256 left, int256 right) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right); - } - } - - function assertNotEq(int256 left, int256 right, string memory err) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right, err); - } - } - - function assertNotEqDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertNotEqDecimal(left, right, decimals); - } - - function assertNotEqDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertNotEqDecimal(left, right, decimals, err); - } - - function assertNotEq(address left, address right) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right); - } - } - - function assertNotEq(address left, address right, string memory err) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right, err); - } - } - - function assertNotEq(bytes32 left, bytes32 right) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right); - } - } - - function assertNotEq(bytes32 left, bytes32 right, string memory err) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right, err); - } - } - - function assertNotEq32(bytes32 left, bytes32 right) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right); - } - } - - function assertNotEq32(bytes32 left, bytes32 right, string memory err) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right, err); - } - } - - function assertNotEq(string memory left, string memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(string memory left, string memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bytes memory left, bytes memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bytes memory left, bytes memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bool[] memory left, bool[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bool[] memory left, bool[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(uint256[] memory left, uint256[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(uint256[] memory left, uint256[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(int256[] memory left, int256[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(int256[] memory left, int256[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(address[] memory left, address[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(address[] memory left, address[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bytes32[] memory left, bytes32[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bytes32[] memory left, bytes32[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(string[] memory left, string[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(string[] memory left, string[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bytes[] memory left, bytes[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bytes[] memory left, bytes[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertLt(uint256 left, uint256 right) internal pure virtual { - if (left >= right) { - vm.assertLt(left, right); - } - } - - function assertLt(uint256 left, uint256 right, string memory err) internal pure virtual { - if (left >= right) { - vm.assertLt(left, right, err); - } - } - - function assertLtDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertLtDecimal(left, right, decimals); - } - - function assertLtDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertLtDecimal(left, right, decimals, err); - } - - function assertLt(int256 left, int256 right) internal pure virtual { - if (left >= right) { - vm.assertLt(left, right); - } - } - - function assertLt(int256 left, int256 right, string memory err) internal pure virtual { - if (left >= right) { - vm.assertLt(left, right, err); - } - } - - function assertLtDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertLtDecimal(left, right, decimals); - } - - function assertLtDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertLtDecimal(left, right, decimals, err); - } - - function assertGt(uint256 left, uint256 right) internal pure virtual { - if (left <= right) { - vm.assertGt(left, right); - } - } - - function assertGt(uint256 left, uint256 right, string memory err) internal pure virtual { - if (left <= right) { - vm.assertGt(left, right, err); - } - } - - function assertGtDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertGtDecimal(left, right, decimals); - } - - function assertGtDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertGtDecimal(left, right, decimals, err); - } - - function assertGt(int256 left, int256 right) internal pure virtual { - if (left <= right) { - vm.assertGt(left, right); - } - } - - function assertGt(int256 left, int256 right, string memory err) internal pure virtual { - if (left <= right) { - vm.assertGt(left, right, err); - } - } - - function assertGtDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertGtDecimal(left, right, decimals); - } - - function assertGtDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertGtDecimal(left, right, decimals, err); - } - - function assertLe(uint256 left, uint256 right) internal pure virtual { - if (left > right) { - vm.assertLe(left, right); - } - } - - function assertLe(uint256 left, uint256 right, string memory err) internal pure virtual { - if (left > right) { - vm.assertLe(left, right, err); - } - } - - function assertLeDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertLeDecimal(left, right, decimals); - } - - function assertLeDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertLeDecimal(left, right, decimals, err); - } - - function assertLe(int256 left, int256 right) internal pure virtual { - if (left > right) { - vm.assertLe(left, right); - } - } - - function assertLe(int256 left, int256 right, string memory err) internal pure virtual { - if (left > right) { - vm.assertLe(left, right, err); - } - } - - function assertLeDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertLeDecimal(left, right, decimals); - } - - function assertLeDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertLeDecimal(left, right, decimals, err); - } - - function assertGe(uint256 left, uint256 right) internal pure virtual { - if (left < right) { - vm.assertGe(left, right); - } - } - - function assertGe(uint256 left, uint256 right, string memory err) internal pure virtual { - if (left < right) { - vm.assertGe(left, right, err); - } - } - - function assertGeDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertGeDecimal(left, right, decimals); - } - - function assertGeDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertGeDecimal(left, right, decimals, err); - } - - function assertGe(int256 left, int256 right) internal pure virtual { - if (left < right) { - vm.assertGe(left, right); - } - } - - function assertGe(int256 left, int256 right, string memory err) internal pure virtual { - if (left < right) { - vm.assertGe(left, right, err); - } - } - - function assertGeDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertGeDecimal(left, right, decimals); - } - - function assertGeDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertGeDecimal(left, right, decimals, err); - } - - function assertApproxEqAbs(uint256 left, uint256 right, uint256 maxDelta) internal pure virtual { - vm.assertApproxEqAbs(left, right, maxDelta); - } - - function assertApproxEqAbs(uint256 left, uint256 right, uint256 maxDelta, string memory err) internal pure virtual { - vm.assertApproxEqAbs(left, right, maxDelta, err); - } - - function assertApproxEqAbsDecimal(uint256 left, uint256 right, uint256 maxDelta, uint256 decimals) - internal - pure - virtual - { - vm.assertApproxEqAbsDecimal(left, right, maxDelta, decimals); - } - - function assertApproxEqAbsDecimal( - uint256 left, - uint256 right, - uint256 maxDelta, - uint256 decimals, - string memory err - ) internal pure virtual { - vm.assertApproxEqAbsDecimal(left, right, maxDelta, decimals, err); - } - - function assertApproxEqAbs(int256 left, int256 right, uint256 maxDelta) internal pure virtual { - vm.assertApproxEqAbs(left, right, maxDelta); - } - - function assertApproxEqAbs(int256 left, int256 right, uint256 maxDelta, string memory err) internal pure virtual { - vm.assertApproxEqAbs(left, right, maxDelta, err); - } - - function assertApproxEqAbsDecimal(int256 left, int256 right, uint256 maxDelta, uint256 decimals) - internal - pure - virtual - { - vm.assertApproxEqAbsDecimal(left, right, maxDelta, decimals); - } - - function assertApproxEqAbsDecimal(int256 left, int256 right, uint256 maxDelta, uint256 decimals, string memory err) - internal - pure - virtual - { - vm.assertApproxEqAbsDecimal(left, right, maxDelta, decimals, err); - } - - function assertApproxEqRel( - uint256 left, - uint256 right, - uint256 maxPercentDelta // An 18 decimal fixed point number, where 1e18 == 100% - ) - internal - pure - virtual - { - vm.assertApproxEqRel(left, right, maxPercentDelta); - } - - function assertApproxEqRel( - uint256 left, - uint256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - string memory err - ) - internal - pure - virtual - { - vm.assertApproxEqRel(left, right, maxPercentDelta, err); - } - - function assertApproxEqRelDecimal( - uint256 left, - uint256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - uint256 decimals - ) - internal - pure - virtual - { - vm.assertApproxEqRelDecimal(left, right, maxPercentDelta, decimals); - } - - function assertApproxEqRelDecimal( - uint256 left, - uint256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - uint256 decimals, - string memory err - ) internal pure virtual { - vm.assertApproxEqRelDecimal(left, right, maxPercentDelta, decimals, err); - } - - function assertApproxEqRel(int256 left, int256 right, uint256 maxPercentDelta) internal pure virtual { - vm.assertApproxEqRel(left, right, maxPercentDelta); - } - - function assertApproxEqRel( - int256 left, - int256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - string memory err - ) - internal - pure - virtual - { - vm.assertApproxEqRel(left, right, maxPercentDelta, err); - } - - function assertApproxEqRelDecimal( - int256 left, - int256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - uint256 decimals - ) - internal - pure - virtual - { - vm.assertApproxEqRelDecimal(left, right, maxPercentDelta, decimals); - } - - function assertApproxEqRelDecimal( - int256 left, - int256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - uint256 decimals, - string memory err - ) internal pure virtual { - vm.assertApproxEqRelDecimal(left, right, maxPercentDelta, decimals, err); - } - - // Inherited from DSTest, not used but kept for backwards-compatibility - function checkEq0(bytes memory left, bytes memory right) internal pure returns (bool) { - return keccak256(left) == keccak256(right); - } - - function assertEq0(bytes memory left, bytes memory right) internal pure virtual { - assertEq(left, right); - } - - function assertEq0(bytes memory left, bytes memory right, string memory err) internal pure virtual { - assertEq(left, right, err); - } - - function assertNotEq0(bytes memory left, bytes memory right) internal pure virtual { - assertNotEq(left, right); - } - - function assertNotEq0(bytes memory left, bytes memory right, string memory err) internal pure virtual { - assertNotEq(left, right, err); - } - - function assertEqCall(address target, bytes memory callDataA, bytes memory callDataB) internal virtual { - assertEqCall(target, callDataA, target, callDataB, true); - } - - function assertEqCall(address targetA, bytes memory callDataA, address targetB, bytes memory callDataB) - internal - virtual - { - assertEqCall(targetA, callDataA, targetB, callDataB, true); - } - - function assertEqCall(address target, bytes memory callDataA, bytes memory callDataB, bool strictRevertData) - internal - virtual - { - assertEqCall(target, callDataA, target, callDataB, strictRevertData); - } - - function assertEqCall( - address targetA, - bytes memory callDataA, - address targetB, - bytes memory callDataB, - bool strictRevertData - ) internal virtual { - (bool successA, bytes memory returnDataA) = address(targetA).call(callDataA); - (bool successB, bytes memory returnDataB) = address(targetB).call(callDataB); - - if (successA && successB) { - assertEq(returnDataA, returnDataB, "Call return data does not match"); - } - - if (!successA && !successB && strictRevertData) { - assertEq(returnDataA, returnDataB, "Call revert data does not match"); - } - - if (!successA && successB) { - emit log("Error: Calls were not equal"); - emit log_named_bytes(" Left call revert data", returnDataA); - emit log_named_bytes(" Right call return data", returnDataB); - revert("assertion failed"); - } - - if (successA && !successB) { - emit log("Error: Calls were not equal"); - emit log_named_bytes(" Left call return data", returnDataA); - emit log_named_bytes(" Right call revert data", returnDataB); - revert("assertion failed"); - } - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdChains.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdChains.sol deleted file mode 100644 index e34166c02a..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdChains.sol +++ /dev/null @@ -1,295 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {VmSafe} from "./Vm.sol"; - -/** - * StdChains provides information about EVM compatible chains that can be used in scripts/tests. - * For each chain, the chain's name, chain ID, and a default RPC URL are provided. Chains are - * identified by their alias, which is the same as the alias in the `[rpc_endpoints]` section of - * the `foundry.toml` file. For best UX, ensure the alias in the `foundry.toml` file match the - * alias used in this contract, which can be found as the first argument to the - * `setChainWithDefaultRpcUrl` call in the `initializeStdChains` function. - * - * There are two main ways to use this contract: - * 1. Set a chain with `setChain(string memory chainAlias, ChainData memory chain)` or - * `setChain(string memory chainAlias, Chain memory chain)` - * 2. Get a chain with `getChain(string memory chainAlias)` or `getChain(uint256 chainId)`. - * - * The first time either of those are used, chains are initialized with the default set of RPC URLs. - * This is done in `initializeStdChains`, which uses `setChainWithDefaultRpcUrl`. Defaults are recorded in - * `defaultRpcUrls`. - * - * The `setChain` function is straightforward, and it simply saves off the given chain data. - * - * The `getChain` methods use `getChainWithUpdatedRpcUrl` to return a chain. For example, let's say - * we want to retrieve the RPC URL for `mainnet`: - * - If you have specified data with `setChain`, it will return that. - * - If you have configured a mainnet RPC URL in `foundry.toml`, it will return the URL, provided it - * is valid (e.g. a URL is specified, or an environment variable is given and exists). - * - If neither of the above conditions is met, the default data is returned. - * - * Summarizing the above, the prioritization hierarchy is `setChain` -> `foundry.toml` -> environment variable -> defaults. - */ -abstract contract StdChains { - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - bool private stdChainsInitialized; - - struct ChainData { - string name; - uint256 chainId; - string rpcUrl; - } - - struct Chain { - // The chain name. - string name; - // The chain's Chain ID. - uint256 chainId; - // The chain's alias. (i.e. what gets specified in `foundry.toml`). - string chainAlias; - // A default RPC endpoint for this chain. - // NOTE: This default RPC URL is included for convenience to facilitate quick tests and - // experimentation. Do not use this RPC URL for production test suites, CI, or other heavy - // usage as you will be throttled and this is a disservice to others who need this endpoint. - string rpcUrl; - } - - // Maps from the chain's alias (matching the alias in the `foundry.toml` file) to chain data. - mapping(string => Chain) private chains; - // Maps from the chain's alias to it's default RPC URL. - mapping(string => string) private defaultRpcUrls; - // Maps from a chain ID to it's alias. - mapping(uint256 => string) private idToAlias; - - bool private fallbackToDefaultRpcUrls = true; - - // The RPC URL will be fetched from config or defaultRpcUrls if possible. - function getChain(string memory chainAlias) internal virtual returns (Chain memory chain) { - require(bytes(chainAlias).length != 0, "StdChains getChain(string): Chain alias cannot be the empty string."); - - initializeStdChains(); - chain = chains[chainAlias]; - require( - chain.chainId != 0, - string(abi.encodePacked("StdChains getChain(string): Chain with alias \"", chainAlias, "\" not found.")) - ); - - chain = getChainWithUpdatedRpcUrl(chainAlias, chain); - } - - function getChain(uint256 chainId) internal virtual returns (Chain memory chain) { - require(chainId != 0, "StdChains getChain(uint256): Chain ID cannot be 0."); - initializeStdChains(); - string memory chainAlias = idToAlias[chainId]; - - chain = chains[chainAlias]; - - require( - chain.chainId != 0, - string(abi.encodePacked("StdChains getChain(uint256): Chain with ID ", vm.toString(chainId), " not found.")) - ); - - chain = getChainWithUpdatedRpcUrl(chainAlias, chain); - } - - // set chain info, with priority to argument's rpcUrl field. - function setChain(string memory chainAlias, ChainData memory chain) internal virtual { - require( - bytes(chainAlias).length != 0, - "StdChains setChain(string,ChainData): Chain alias cannot be the empty string." - ); - - require(chain.chainId != 0, "StdChains setChain(string,ChainData): Chain ID cannot be 0."); - - initializeStdChains(); - string memory foundAlias = idToAlias[chain.chainId]; - - require( - bytes(foundAlias).length == 0 || keccak256(bytes(foundAlias)) == keccak256(bytes(chainAlias)), - string( - abi.encodePacked( - "StdChains setChain(string,ChainData): Chain ID ", - vm.toString(chain.chainId), - " already used by \"", - foundAlias, - "\"." - ) - ) - ); - - uint256 oldChainId = chains[chainAlias].chainId; - delete idToAlias[oldChainId]; - - chains[chainAlias] = - Chain({name: chain.name, chainId: chain.chainId, chainAlias: chainAlias, rpcUrl: chain.rpcUrl}); - idToAlias[chain.chainId] = chainAlias; - } - - // set chain info, with priority to argument's rpcUrl field. - function setChain(string memory chainAlias, Chain memory chain) internal virtual { - setChain(chainAlias, ChainData({name: chain.name, chainId: chain.chainId, rpcUrl: chain.rpcUrl})); - } - - function _toUpper(string memory str) private pure returns (string memory) { - bytes memory strb = bytes(str); - bytes memory copy = new bytes(strb.length); - for (uint256 i = 0; i < strb.length; i++) { - bytes1 b = strb[i]; - if (b >= 0x61 && b <= 0x7A) { - copy[i] = bytes1(uint8(b) - 32); - } else { - copy[i] = b; - } - } - return string(copy); - } - - // lookup rpcUrl, in descending order of priority: - // current -> config (foundry.toml) -> environment variable -> default - function getChainWithUpdatedRpcUrl(string memory chainAlias, Chain memory chain) - private - view - returns (Chain memory) - { - if (bytes(chain.rpcUrl).length == 0) { - try vm.rpcUrl(chainAlias) returns (string memory configRpcUrl) { - chain.rpcUrl = configRpcUrl; - } catch (bytes memory err) { - string memory envName = string(abi.encodePacked(_toUpper(chainAlias), "_RPC_URL")); - if (fallbackToDefaultRpcUrls) { - chain.rpcUrl = vm.envOr(envName, defaultRpcUrls[chainAlias]); - } else { - chain.rpcUrl = vm.envString(envName); - } - // Distinguish 'not found' from 'cannot read' - // The upstream error thrown by forge for failing cheats changed so we check both the old and new versions - bytes memory oldNotFoundError = - abi.encodeWithSignature("CheatCodeError", string(abi.encodePacked("invalid rpc url ", chainAlias))); - bytes memory newNotFoundError = abi.encodeWithSignature( - "CheatcodeError(string)", string(abi.encodePacked("invalid rpc url: ", chainAlias)) - ); - bytes32 errHash = keccak256(err); - if ( - (errHash != keccak256(oldNotFoundError) && errHash != keccak256(newNotFoundError)) - || bytes(chain.rpcUrl).length == 0 - ) { - assembly ("memory-safe") { - revert(add(32, err), mload(err)) - } - } - } - } - return chain; - } - - function setFallbackToDefaultRpcUrls(bool useDefault) internal { - fallbackToDefaultRpcUrls = useDefault; - } - - function initializeStdChains() private { - if (stdChainsInitialized) return; - - stdChainsInitialized = true; - - // If adding an RPC here, make sure to test the default RPC URL in `test_Rpcs` in `StdChains.t.sol` - setChainWithDefaultRpcUrl("anvil", ChainData("Anvil", 31337, "http://127.0.0.1:8545")); - setChainWithDefaultRpcUrl("mainnet", ChainData("Mainnet", 1, "https://eth.llamarpc.com")); - setChainWithDefaultRpcUrl( - "sepolia", ChainData("Sepolia", 11155111, "https://sepolia.infura.io/v3/b9794ad1ddf84dfb8c34d6bb5dca2001") - ); - setChainWithDefaultRpcUrl("holesky", ChainData("Holesky", 17000, "https://rpc.holesky.ethpandaops.io")); - setChainWithDefaultRpcUrl("hoodi", ChainData("Hoodi", 560048, "https://rpc.hoodi.ethpandaops.io")); - setChainWithDefaultRpcUrl("optimism", ChainData("Optimism", 10, "https://mainnet.optimism.io")); - setChainWithDefaultRpcUrl( - "optimism_sepolia", ChainData("Optimism Sepolia", 11155420, "https://sepolia.optimism.io") - ); - setChainWithDefaultRpcUrl("arbitrum_one", ChainData("Arbitrum One", 42161, "https://arb1.arbitrum.io/rpc")); - setChainWithDefaultRpcUrl( - "arbitrum_one_sepolia", ChainData("Arbitrum One Sepolia", 421614, "https://sepolia-rollup.arbitrum.io/rpc") - ); - setChainWithDefaultRpcUrl("arbitrum_nova", ChainData("Arbitrum Nova", 42170, "https://nova.arbitrum.io/rpc")); - setChainWithDefaultRpcUrl("polygon", ChainData("Polygon", 137, "https://polygon-rpc.com")); - setChainWithDefaultRpcUrl( - "polygon_amoy", ChainData("Polygon Amoy", 80002, "https://rpc-amoy.polygon.technology") - ); - setChainWithDefaultRpcUrl("avalanche", ChainData("Avalanche", 43114, "https://api.avax.network/ext/bc/C/rpc")); - setChainWithDefaultRpcUrl( - "avalanche_fuji", ChainData("Avalanche Fuji", 43113, "https://api.avax-test.network/ext/bc/C/rpc") - ); - setChainWithDefaultRpcUrl( - "bnb_smart_chain", ChainData("BNB Smart Chain", 56, "https://bsc-dataseed1.binance.org") - ); - setChainWithDefaultRpcUrl( - "bnb_smart_chain_testnet", - ChainData("BNB Smart Chain Testnet", 97, "https://rpc.ankr.com/bsc_testnet_chapel") - ); - setChainWithDefaultRpcUrl("gnosis_chain", ChainData("Gnosis Chain", 100, "https://rpc.gnosischain.com")); - setChainWithDefaultRpcUrl("moonbeam", ChainData("Moonbeam", 1284, "https://rpc.api.moonbeam.network")); - setChainWithDefaultRpcUrl( - "moonriver", ChainData("Moonriver", 1285, "https://rpc.api.moonriver.moonbeam.network") - ); - setChainWithDefaultRpcUrl("moonbase", ChainData("Moonbase", 1287, "https://rpc.testnet.moonbeam.network")); - setChainWithDefaultRpcUrl("base_sepolia", ChainData("Base Sepolia", 84532, "https://sepolia.base.org")); - setChainWithDefaultRpcUrl("base", ChainData("Base", 8453, "https://mainnet.base.org")); - setChainWithDefaultRpcUrl("blast_sepolia", ChainData("Blast Sepolia", 168587773, "https://sepolia.blast.io")); - setChainWithDefaultRpcUrl("blast", ChainData("Blast", 81457, "https://rpc.blast.io")); - setChainWithDefaultRpcUrl("fantom_opera", ChainData("Fantom Opera", 250, "https://rpc.ankr.com/fantom/")); - setChainWithDefaultRpcUrl( - "fantom_opera_testnet", ChainData("Fantom Opera Testnet", 4002, "https://rpc.ankr.com/fantom_testnet/") - ); - setChainWithDefaultRpcUrl("fraxtal", ChainData("Fraxtal", 252, "https://rpc.frax.com")); - setChainWithDefaultRpcUrl("fraxtal_testnet", ChainData("Fraxtal Testnet", 2522, "https://rpc.testnet.frax.com")); - setChainWithDefaultRpcUrl( - "berachain_bartio_testnet", ChainData("Berachain bArtio Testnet", 80084, "https://bartio.rpc.berachain.com") - ); - setChainWithDefaultRpcUrl("flare", ChainData("Flare", 14, "https://flare-api.flare.network/ext/C/rpc")); - setChainWithDefaultRpcUrl( - "flare_coston2", ChainData("Flare Coston2", 114, "https://coston2-api.flare.network/ext/C/rpc") - ); - - setChainWithDefaultRpcUrl("ink", ChainData("Ink", 57073, "https://rpc-gel.inkonchain.com")); - setChainWithDefaultRpcUrl( - "ink_sepolia", ChainData("Ink Sepolia", 763373, "https://rpc-gel-sepolia.inkonchain.com") - ); - - setChainWithDefaultRpcUrl("mode", ChainData("Mode", 34443, "https://mode.drpc.org")); - setChainWithDefaultRpcUrl("mode_sepolia", ChainData("Mode Sepolia", 919, "https://sepolia.mode.network")); - - setChainWithDefaultRpcUrl("zora", ChainData("Zora", 7777777, "https://zora.drpc.org")); - setChainWithDefaultRpcUrl( - "zora_sepolia", ChainData("Zora Sepolia", 999999999, "https://sepolia.rpc.zora.energy") - ); - - setChainWithDefaultRpcUrl("race", ChainData("Race", 6805, "https://racemainnet.io")); - setChainWithDefaultRpcUrl("race_sepolia", ChainData("Race Sepolia", 6806, "https://racemainnet.io")); - - setChainWithDefaultRpcUrl("metal", ChainData("Metal", 1750, "https://metall2.drpc.org")); - setChainWithDefaultRpcUrl("metal_sepolia", ChainData("Metal Sepolia", 1740, "https://testnet.rpc.metall2.com")); - - setChainWithDefaultRpcUrl("binary", ChainData("Binary", 624, "https://rpc.zero.thebinaryholdings.com")); - setChainWithDefaultRpcUrl( - "binary_sepolia", ChainData("Binary Sepolia", 625, "https://rpc.zero.thebinaryholdings.com") - ); - - setChainWithDefaultRpcUrl("orderly", ChainData("Orderly", 291, "https://rpc.orderly.network")); - setChainWithDefaultRpcUrl( - "orderly_sepolia", ChainData("Orderly Sepolia", 4460, "https://testnet-rpc.orderly.org") - ); - - setChainWithDefaultRpcUrl("unichain", ChainData("Unichain", 130, "https://mainnet.unichain.org")); - setChainWithDefaultRpcUrl( - "unichain_sepolia", ChainData("Unichain Sepolia", 1301, "https://sepolia.unichain.org") - ); - } - - // set chain info, with priority to chainAlias' rpc url in foundry.toml - function setChainWithDefaultRpcUrl(string memory chainAlias, ChainData memory chain) private { - string memory rpcUrl = chain.rpcUrl; - defaultRpcUrls[chainAlias] = rpcUrl; - chain.rpcUrl = ""; - setChain(chainAlias, chain); - chain.rpcUrl = rpcUrl; // restore argument - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdCheats.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdCheats.sol deleted file mode 100644 index e5b563fe60..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdCheats.sol +++ /dev/null @@ -1,825 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {StdStorage, stdStorage} from "./StdStorage.sol"; -import {console2} from "./console2.sol"; -import {Vm} from "./Vm.sol"; - -abstract contract StdCheatsSafe { - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - - uint256 private constant UINT256_MAX = - 115792089237316195423570985008687907853269984665640564039457584007913129639935; - - bool private gasMeteringOff; - - // Data structures to parse Transaction objects from the broadcast artifact - // that conform to EIP1559. The Raw structs is what is parsed from the JSON - // and then converted to the one that is used by the user for better UX. - - struct RawTx1559 { - string[] arguments; - address contractAddress; - string contractName; - // json value name = function - string functionSig; - bytes32 hash; - // json value name = tx - RawTx1559Detail txDetail; - // json value name = type - string opcode; - } - - struct RawTx1559Detail { - AccessList[] accessList; - bytes data; - address from; - bytes gas; - bytes nonce; - address to; - bytes txType; - bytes value; - } - - struct Tx1559 { - string[] arguments; - address contractAddress; - string contractName; - string functionSig; - bytes32 hash; - Tx1559Detail txDetail; - string opcode; - } - - struct Tx1559Detail { - AccessList[] accessList; - bytes data; - address from; - uint256 gas; - uint256 nonce; - address to; - uint256 txType; - uint256 value; - } - - // Data structures to parse Transaction objects from the broadcast artifact - // that DO NOT conform to EIP1559. The Raw structs is what is parsed from the JSON - // and then converted to the one that is used by the user for better UX. - - struct TxLegacy { - string[] arguments; - address contractAddress; - string contractName; - string functionSig; - string hash; - string opcode; - TxDetailLegacy transaction; - } - - struct TxDetailLegacy { - AccessList[] accessList; - uint256 chainId; - bytes data; - address from; - uint256 gas; - uint256 gasPrice; - bytes32 hash; - uint256 nonce; - bytes1 opcode; - bytes32 r; - bytes32 s; - uint256 txType; - address to; - uint8 v; - uint256 value; - } - - struct AccessList { - address accessAddress; - bytes32[] storageKeys; - } - - // Data structures to parse Receipt objects from the broadcast artifact. - // The Raw structs is what is parsed from the JSON - // and then converted to the one that is used by the user for better UX. - - struct RawReceipt { - bytes32 blockHash; - bytes blockNumber; - address contractAddress; - bytes cumulativeGasUsed; - bytes effectiveGasPrice; - address from; - bytes gasUsed; - RawReceiptLog[] logs; - bytes logsBloom; - bytes status; - address to; - bytes32 transactionHash; - bytes transactionIndex; - } - - struct Receipt { - bytes32 blockHash; - uint256 blockNumber; - address contractAddress; - uint256 cumulativeGasUsed; - uint256 effectiveGasPrice; - address from; - uint256 gasUsed; - ReceiptLog[] logs; - bytes logsBloom; - uint256 status; - address to; - bytes32 transactionHash; - uint256 transactionIndex; - } - - // Data structures to parse the entire broadcast artifact, assuming the - // transactions conform to EIP1559. - - struct EIP1559ScriptArtifact { - string[] libraries; - string path; - string[] pending; - Receipt[] receipts; - uint256 timestamp; - Tx1559[] transactions; - TxReturn[] txReturns; - } - - struct RawEIP1559ScriptArtifact { - string[] libraries; - string path; - string[] pending; - RawReceipt[] receipts; - TxReturn[] txReturns; - uint256 timestamp; - RawTx1559[] transactions; - } - - struct RawReceiptLog { - // json value = address - address logAddress; - bytes32 blockHash; - bytes blockNumber; - bytes data; - bytes logIndex; - bool removed; - bytes32[] topics; - bytes32 transactionHash; - bytes transactionIndex; - bytes transactionLogIndex; - } - - struct ReceiptLog { - // json value = address - address logAddress; - bytes32 blockHash; - uint256 blockNumber; - bytes data; - uint256 logIndex; - bytes32[] topics; - uint256 transactionIndex; - uint256 transactionLogIndex; - bool removed; - } - - struct TxReturn { - string internalType; - string value; - } - - struct Account { - address addr; - uint256 key; - } - - enum AddressType { - Payable, - NonPayable, - ZeroAddress, - Precompile, - ForgeAddress - } - - // Checks that `addr` is not blacklisted by token contracts that have a blacklist. - function assumeNotBlacklisted(address token, address addr) internal view virtual { - // Nothing to check if `token` is not a contract. - uint256 tokenCodeSize; - assembly { - tokenCodeSize := extcodesize(token) - } - require(tokenCodeSize > 0, "StdCheats assumeNotBlacklisted(address,address): Token address is not a contract."); - - bool success; - bytes memory returnData; - - // 4-byte selector for `isBlacklisted(address)`, used by USDC. - (success, returnData) = token.staticcall(abi.encodeWithSelector(0xfe575a87, addr)); - vm.assume(!success || abi.decode(returnData, (bool)) == false); - - // 4-byte selector for `isBlackListed(address)`, used by USDT. - (success, returnData) = token.staticcall(abi.encodeWithSelector(0xe47d6060, addr)); - vm.assume(!success || abi.decode(returnData, (bool)) == false); - } - - // Checks that `addr` is not blacklisted by token contracts that have a blacklist. - // This is identical to `assumeNotBlacklisted(address,address)` but with a different name, for - // backwards compatibility, since this name was used in the original PR which already has - // a release. This function can be removed in a future release once we want a breaking change. - function assumeNoBlacklisted(address token, address addr) internal view virtual { - assumeNotBlacklisted(token, addr); - } - - function assumeAddressIsNot(address addr, AddressType addressType) internal virtual { - if (addressType == AddressType.Payable) { - assumeNotPayable(addr); - } else if (addressType == AddressType.NonPayable) { - assumePayable(addr); - } else if (addressType == AddressType.ZeroAddress) { - assumeNotZeroAddress(addr); - } else if (addressType == AddressType.Precompile) { - assumeNotPrecompile(addr); - } else if (addressType == AddressType.ForgeAddress) { - assumeNotForgeAddress(addr); - } - } - - function assumeAddressIsNot(address addr, AddressType addressType1, AddressType addressType2) internal virtual { - assumeAddressIsNot(addr, addressType1); - assumeAddressIsNot(addr, addressType2); - } - - function assumeAddressIsNot( - address addr, - AddressType addressType1, - AddressType addressType2, - AddressType addressType3 - ) internal virtual { - assumeAddressIsNot(addr, addressType1); - assumeAddressIsNot(addr, addressType2); - assumeAddressIsNot(addr, addressType3); - } - - function assumeAddressIsNot( - address addr, - AddressType addressType1, - AddressType addressType2, - AddressType addressType3, - AddressType addressType4 - ) internal virtual { - assumeAddressIsNot(addr, addressType1); - assumeAddressIsNot(addr, addressType2); - assumeAddressIsNot(addr, addressType3); - assumeAddressIsNot(addr, addressType4); - } - - // This function checks whether an address, `addr`, is payable. It works by sending 1 wei to - // `addr` and checking the `success` return value. - // NOTE: This function may result in state changes depending on the fallback/receive logic - // implemented by `addr`, which should be taken into account when this function is used. - function _isPayable(address addr) private returns (bool) { - require( - addr.balance < UINT256_MAX, - "StdCheats _isPayable(address): Balance equals max uint256, so it cannot receive any more funds" - ); - uint256 origBalanceTest = address(this).balance; - uint256 origBalanceAddr = address(addr).balance; - - vm.deal(address(this), 1); - (bool success,) = payable(addr).call{value: 1}(""); - - // reset balances - vm.deal(address(this), origBalanceTest); - vm.deal(addr, origBalanceAddr); - - return success; - } - - // NOTE: This function may result in state changes depending on the fallback/receive logic - // implemented by `addr`, which should be taken into account when this function is used. See the - // `_isPayable` method for more information. - function assumePayable(address addr) internal virtual { - vm.assume(_isPayable(addr)); - } - - function assumeNotPayable(address addr) internal virtual { - vm.assume(!_isPayable(addr)); - } - - function assumeNotZeroAddress(address addr) internal pure virtual { - vm.assume(addr != address(0)); - } - - function assumeNotPrecompile(address addr) internal pure virtual { - assumeNotPrecompile(addr, _pureChainId()); - } - - function assumeNotPrecompile(address addr, uint256 chainId) internal pure virtual { - // Note: For some chains like Optimism these are technically predeploys (i.e. bytecode placed at a specific - // address), but the same rationale for excluding them applies so we include those too. - - // These are reserved by Ethereum and may be on all EVM-compatible chains. - vm.assume(addr < address(0x1) || addr > address(0xff)); - - // forgefmt: disable-start - if (chainId == 10 || chainId == 420 || chainId == 11155420) { - // https://github.com/ethereum-optimism/optimism/blob/eaa371a0184b56b7ca6d9eb9cb0a2b78b2ccd864/op-bindings/predeploys/addresses.go#L6-L21 - vm.assume(addr < address(0x4200000000000000000000000000000000000000) || addr > address(0x4200000000000000000000000000000000000800)); - } else if (chainId == 42161 || chainId == 421613) { - // https://developer.arbitrum.io/useful-addresses#arbitrum-precompiles-l2-same-on-all-arb-chains - vm.assume(addr < address(0x0000000000000000000000000000000000000064) || addr > address(0x0000000000000000000000000000000000000068)); - } else if (chainId == 43114 || chainId == 43113) { - // https://github.com/ava-labs/subnet-evm/blob/47c03fd007ecaa6de2c52ea081596e0a88401f58/precompile/params.go#L18-L59 - vm.assume(addr < address(0x0100000000000000000000000000000000000000) || addr > address(0x01000000000000000000000000000000000000ff)); - vm.assume(addr < address(0x0200000000000000000000000000000000000000) || addr > address(0x02000000000000000000000000000000000000FF)); - vm.assume(addr < address(0x0300000000000000000000000000000000000000) || addr > address(0x03000000000000000000000000000000000000Ff)); - } - // forgefmt: disable-end - } - - function assumeNotForgeAddress(address addr) internal pure virtual { - // vm, console, and Create2Deployer addresses - vm.assume( - addr != address(vm) && addr != 0x000000000000000000636F6e736F6c652e6c6f67 - && addr != 0x4e59b44847b379578588920cA78FbF26c0B4956C - ); - } - - function assumeUnusedAddress(address addr) internal view virtual { - uint256 size; - assembly { - size := extcodesize(addr) - } - vm.assume(size == 0); - - assumeNotPrecompile(addr); - assumeNotZeroAddress(addr); - assumeNotForgeAddress(addr); - } - - function readEIP1559ScriptArtifact(string memory path) - internal - view - virtual - returns (EIP1559ScriptArtifact memory) - { - string memory data = vm.readFile(path); - bytes memory parsedData = vm.parseJson(data); - RawEIP1559ScriptArtifact memory rawArtifact = abi.decode(parsedData, (RawEIP1559ScriptArtifact)); - EIP1559ScriptArtifact memory artifact; - artifact.libraries = rawArtifact.libraries; - artifact.path = rawArtifact.path; - artifact.timestamp = rawArtifact.timestamp; - artifact.pending = rawArtifact.pending; - artifact.txReturns = rawArtifact.txReturns; - artifact.receipts = rawToConvertedReceipts(rawArtifact.receipts); - artifact.transactions = rawToConvertedEIPTx1559s(rawArtifact.transactions); - return artifact; - } - - function rawToConvertedEIPTx1559s(RawTx1559[] memory rawTxs) internal pure virtual returns (Tx1559[] memory) { - Tx1559[] memory txs = new Tx1559[](rawTxs.length); - for (uint256 i; i < rawTxs.length; i++) { - txs[i] = rawToConvertedEIPTx1559(rawTxs[i]); - } - return txs; - } - - function rawToConvertedEIPTx1559(RawTx1559 memory rawTx) internal pure virtual returns (Tx1559 memory) { - Tx1559 memory transaction; - transaction.arguments = rawTx.arguments; - transaction.contractAddress = rawTx.contractAddress; - transaction.contractName = rawTx.contractName; - transaction.functionSig = rawTx.functionSig; - transaction.hash = rawTx.hash; - transaction.txDetail = rawToConvertedEIP1559Detail(rawTx.txDetail); - transaction.opcode = rawTx.opcode; - return transaction; - } - - function rawToConvertedEIP1559Detail(RawTx1559Detail memory rawDetail) - internal - pure - virtual - returns (Tx1559Detail memory) - { - Tx1559Detail memory txDetail; - txDetail.data = rawDetail.data; - txDetail.from = rawDetail.from; - txDetail.to = rawDetail.to; - txDetail.nonce = _bytesToUint(rawDetail.nonce); - txDetail.txType = _bytesToUint(rawDetail.txType); - txDetail.value = _bytesToUint(rawDetail.value); - txDetail.gas = _bytesToUint(rawDetail.gas); - txDetail.accessList = rawDetail.accessList; - return txDetail; - } - - function readTx1559s(string memory path) internal view virtual returns (Tx1559[] memory) { - string memory deployData = vm.readFile(path); - bytes memory parsedDeployData = vm.parseJson(deployData, ".transactions"); - RawTx1559[] memory rawTxs = abi.decode(parsedDeployData, (RawTx1559[])); - return rawToConvertedEIPTx1559s(rawTxs); - } - - function readTx1559(string memory path, uint256 index) internal view virtual returns (Tx1559 memory) { - string memory deployData = vm.readFile(path); - string memory key = string(abi.encodePacked(".transactions[", vm.toString(index), "]")); - bytes memory parsedDeployData = vm.parseJson(deployData, key); - RawTx1559 memory rawTx = abi.decode(parsedDeployData, (RawTx1559)); - return rawToConvertedEIPTx1559(rawTx); - } - - // Analogous to readTransactions, but for receipts. - function readReceipts(string memory path) internal view virtual returns (Receipt[] memory) { - string memory deployData = vm.readFile(path); - bytes memory parsedDeployData = vm.parseJson(deployData, ".receipts"); - RawReceipt[] memory rawReceipts = abi.decode(parsedDeployData, (RawReceipt[])); - return rawToConvertedReceipts(rawReceipts); - } - - function readReceipt(string memory path, uint256 index) internal view virtual returns (Receipt memory) { - string memory deployData = vm.readFile(path); - string memory key = string(abi.encodePacked(".receipts[", vm.toString(index), "]")); - bytes memory parsedDeployData = vm.parseJson(deployData, key); - RawReceipt memory rawReceipt = abi.decode(parsedDeployData, (RawReceipt)); - return rawToConvertedReceipt(rawReceipt); - } - - function rawToConvertedReceipts(RawReceipt[] memory rawReceipts) internal pure virtual returns (Receipt[] memory) { - Receipt[] memory receipts = new Receipt[](rawReceipts.length); - for (uint256 i; i < rawReceipts.length; i++) { - receipts[i] = rawToConvertedReceipt(rawReceipts[i]); - } - return receipts; - } - - function rawToConvertedReceipt(RawReceipt memory rawReceipt) internal pure virtual returns (Receipt memory) { - Receipt memory receipt; - receipt.blockHash = rawReceipt.blockHash; - receipt.to = rawReceipt.to; - receipt.from = rawReceipt.from; - receipt.contractAddress = rawReceipt.contractAddress; - receipt.effectiveGasPrice = _bytesToUint(rawReceipt.effectiveGasPrice); - receipt.cumulativeGasUsed = _bytesToUint(rawReceipt.cumulativeGasUsed); - receipt.gasUsed = _bytesToUint(rawReceipt.gasUsed); - receipt.status = _bytesToUint(rawReceipt.status); - receipt.transactionIndex = _bytesToUint(rawReceipt.transactionIndex); - receipt.blockNumber = _bytesToUint(rawReceipt.blockNumber); - receipt.logs = rawToConvertedReceiptLogs(rawReceipt.logs); - receipt.logsBloom = rawReceipt.logsBloom; - receipt.transactionHash = rawReceipt.transactionHash; - return receipt; - } - - function rawToConvertedReceiptLogs(RawReceiptLog[] memory rawLogs) - internal - pure - virtual - returns (ReceiptLog[] memory) - { - ReceiptLog[] memory logs = new ReceiptLog[](rawLogs.length); - for (uint256 i; i < rawLogs.length; i++) { - logs[i].logAddress = rawLogs[i].logAddress; - logs[i].blockHash = rawLogs[i].blockHash; - logs[i].blockNumber = _bytesToUint(rawLogs[i].blockNumber); - logs[i].data = rawLogs[i].data; - logs[i].logIndex = _bytesToUint(rawLogs[i].logIndex); - logs[i].topics = rawLogs[i].topics; - logs[i].transactionIndex = _bytesToUint(rawLogs[i].transactionIndex); - logs[i].transactionLogIndex = _bytesToUint(rawLogs[i].transactionLogIndex); - logs[i].removed = rawLogs[i].removed; - } - return logs; - } - - // Deploy a contract by fetching the contract bytecode from - // the artifacts directory - // e.g. `deployCode(code, abi.encode(arg1,arg2,arg3))` - function deployCode(string memory what, bytes memory args) internal virtual returns (address addr) { - bytes memory bytecode = abi.encodePacked(vm.getCode(what), args); - assembly ("memory-safe") { - addr := create(0, add(bytecode, 0x20), mload(bytecode)) - } - - require(addr != address(0), "StdCheats deployCode(string,bytes): Deployment failed."); - } - - function deployCode(string memory what) internal virtual returns (address addr) { - bytes memory bytecode = vm.getCode(what); - assembly ("memory-safe") { - addr := create(0, add(bytecode, 0x20), mload(bytecode)) - } - - require(addr != address(0), "StdCheats deployCode(string): Deployment failed."); - } - - /// @dev deploy contract with value on construction - function deployCode(string memory what, bytes memory args, uint256 val) internal virtual returns (address addr) { - bytes memory bytecode = abi.encodePacked(vm.getCode(what), args); - assembly ("memory-safe") { - addr := create(val, add(bytecode, 0x20), mload(bytecode)) - } - - require(addr != address(0), "StdCheats deployCode(string,bytes,uint256): Deployment failed."); - } - - function deployCode(string memory what, uint256 val) internal virtual returns (address addr) { - bytes memory bytecode = vm.getCode(what); - assembly ("memory-safe") { - addr := create(val, add(bytecode, 0x20), mload(bytecode)) - } - - require(addr != address(0), "StdCheats deployCode(string,uint256): Deployment failed."); - } - - // creates a labeled address and the corresponding private key - function makeAddrAndKey(string memory name) internal virtual returns (address addr, uint256 privateKey) { - privateKey = uint256(keccak256(abi.encodePacked(name))); - addr = vm.addr(privateKey); - vm.label(addr, name); - } - - // creates a labeled address - function makeAddr(string memory name) internal virtual returns (address addr) { - (addr,) = makeAddrAndKey(name); - } - - // Destroys an account immediately, sending the balance to beneficiary. - // Destroying means: balance will be zero, code will be empty, and nonce will be 0 - // This is similar to selfdestruct but not identical: selfdestruct destroys code and nonce - // only after tx ends, this will run immediately. - function destroyAccount(address who, address beneficiary) internal virtual { - uint256 currBalance = who.balance; - vm.etch(who, abi.encode()); - vm.deal(who, 0); - vm.resetNonce(who); - - uint256 beneficiaryBalance = beneficiary.balance; - vm.deal(beneficiary, currBalance + beneficiaryBalance); - } - - // creates a struct containing both a labeled address and the corresponding private key - function makeAccount(string memory name) internal virtual returns (Account memory account) { - (account.addr, account.key) = makeAddrAndKey(name); - } - - function deriveRememberKey(string memory mnemonic, uint32 index) - internal - virtual - returns (address who, uint256 privateKey) - { - privateKey = vm.deriveKey(mnemonic, index); - who = vm.rememberKey(privateKey); - } - - function _bytesToUint(bytes memory b) private pure returns (uint256) { - require(b.length <= 32, "StdCheats _bytesToUint(bytes): Bytes length exceeds 32."); - return abi.decode(abi.encodePacked(new bytes(32 - b.length), b), (uint256)); - } - - function isFork() internal view virtual returns (bool status) { - try vm.activeFork() { - status = true; - } catch (bytes memory) {} - } - - modifier skipWhenForking() { - if (!isFork()) { - _; - } - } - - modifier skipWhenNotForking() { - if (isFork()) { - _; - } - } - - modifier noGasMetering() { - vm.pauseGasMetering(); - // To prevent turning gas monitoring back on with nested functions that use this modifier, - // we check if gasMetering started in the off position. If it did, we don't want to turn - // it back on until we exit the top level function that used the modifier - // - // i.e. funcA() noGasMetering { funcB() }, where funcB has noGasMetering as well. - // funcA will have `gasStartedOff` as false, funcB will have it as true, - // so we only turn metering back on at the end of the funcA - bool gasStartedOff = gasMeteringOff; - gasMeteringOff = true; - - _; - - // if gas metering was on when this modifier was called, turn it back on at the end - if (!gasStartedOff) { - gasMeteringOff = false; - vm.resumeGasMetering(); - } - } - - // We use this complex approach of `_viewChainId` and `_pureChainId` to ensure there are no - // compiler warnings when accessing chain ID in any solidity version supported by forge-std. We - // can't simply access the chain ID in a normal view or pure function because the solc View Pure - // Checker changed `chainid` from pure to view in 0.8.0. - function _viewChainId() private view returns (uint256 chainId) { - // Assembly required since `block.chainid` was introduced in 0.8.0. - assembly { - chainId := chainid() - } - - address(this); // Silence warnings in older Solc versions. - } - - function _pureChainId() private pure returns (uint256 chainId) { - function() internal view returns (uint256) fnIn = _viewChainId; - function() internal pure returns (uint256) pureChainId; - assembly { - pureChainId := fnIn - } - chainId = pureChainId(); - } -} - -// Wrappers around cheatcodes to avoid footguns -abstract contract StdCheats is StdCheatsSafe { - using stdStorage for StdStorage; - - StdStorage private stdstore; - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - address private constant CONSOLE2_ADDRESS = 0x000000000000000000636F6e736F6c652e6c6f67; - - // Skip forward or rewind time by the specified number of seconds - function skip(uint256 time) internal virtual { - vm.warp(vm.getBlockTimestamp() + time); - } - - function rewind(uint256 time) internal virtual { - vm.warp(vm.getBlockTimestamp() - time); - } - - // Setup a prank from an address that has some ether - function hoax(address msgSender) internal virtual { - vm.deal(msgSender, 1 << 128); - vm.prank(msgSender); - } - - function hoax(address msgSender, uint256 give) internal virtual { - vm.deal(msgSender, give); - vm.prank(msgSender); - } - - function hoax(address msgSender, address origin) internal virtual { - vm.deal(msgSender, 1 << 128); - vm.prank(msgSender, origin); - } - - function hoax(address msgSender, address origin, uint256 give) internal virtual { - vm.deal(msgSender, give); - vm.prank(msgSender, origin); - } - - // Start perpetual prank from an address that has some ether - function startHoax(address msgSender) internal virtual { - vm.deal(msgSender, 1 << 128); - vm.startPrank(msgSender); - } - - function startHoax(address msgSender, uint256 give) internal virtual { - vm.deal(msgSender, give); - vm.startPrank(msgSender); - } - - // Start perpetual prank from an address that has some ether - // tx.origin is set to the origin parameter - function startHoax(address msgSender, address origin) internal virtual { - vm.deal(msgSender, 1 << 128); - vm.startPrank(msgSender, origin); - } - - function startHoax(address msgSender, address origin, uint256 give) internal virtual { - vm.deal(msgSender, give); - vm.startPrank(msgSender, origin); - } - - function changePrank(address msgSender) internal virtual { - console2_log_StdCheats("changePrank is deprecated. Please use vm.startPrank instead."); - vm.stopPrank(); - vm.startPrank(msgSender); - } - - function changePrank(address msgSender, address txOrigin) internal virtual { - console2_log_StdCheats("changePrank is deprecated. Please use vm.startPrank instead."); - vm.stopPrank(); - vm.startPrank(msgSender, txOrigin); - } - - // The same as Vm's `deal` - // Use the alternative signature for ERC20 tokens - function deal(address to, uint256 give) internal virtual { - vm.deal(to, give); - } - - // Set the balance of an account for any ERC20 token - // Use the alternative signature to update `totalSupply` - function deal(address token, address to, uint256 give) internal virtual { - deal(token, to, give, false); - } - - // Set the balance of an account for any ERC1155 token - // Use the alternative signature to update `totalSupply` - function dealERC1155(address token, address to, uint256 id, uint256 give) internal virtual { - dealERC1155(token, to, id, give, false); - } - - function deal(address token, address to, uint256 give, bool adjust) internal virtual { - // get current balance - (, bytes memory balData) = token.staticcall(abi.encodeWithSelector(0x70a08231, to)); - uint256 prevBal = abi.decode(balData, (uint256)); - - // update balance - stdstore.target(token).sig(0x70a08231).with_key(to).checked_write(give); - - // update total supply - if (adjust) { - (, bytes memory totSupData) = token.staticcall(abi.encodeWithSelector(0x18160ddd)); - uint256 totSup = abi.decode(totSupData, (uint256)); - if (give < prevBal) { - totSup -= (prevBal - give); - } else { - totSup += (give - prevBal); - } - stdstore.target(token).sig(0x18160ddd).checked_write(totSup); - } - } - - function dealERC1155(address token, address to, uint256 id, uint256 give, bool adjust) internal virtual { - // get current balance - (, bytes memory balData) = token.staticcall(abi.encodeWithSelector(0x00fdd58e, to, id)); - uint256 prevBal = abi.decode(balData, (uint256)); - - // update balance - stdstore.target(token).sig(0x00fdd58e).with_key(to).with_key(id).checked_write(give); - - // update total supply - if (adjust) { - (, bytes memory totSupData) = token.staticcall(abi.encodeWithSelector(0xbd85b039, id)); - require( - totSupData.length != 0, - "StdCheats deal(address,address,uint,uint,bool): target contract is not ERC1155Supply." - ); - uint256 totSup = abi.decode(totSupData, (uint256)); - if (give < prevBal) { - totSup -= (prevBal - give); - } else { - totSup += (give - prevBal); - } - stdstore.target(token).sig(0xbd85b039).with_key(id).checked_write(totSup); - } - } - - function dealERC721(address token, address to, uint256 id) internal virtual { - // check if token id is already minted and the actual owner. - (bool successMinted, bytes memory ownerData) = token.staticcall(abi.encodeWithSelector(0x6352211e, id)); - require(successMinted, "StdCheats deal(address,address,uint,bool): id not minted."); - - // get owner current balance - (, bytes memory fromBalData) = - token.staticcall(abi.encodeWithSelector(0x70a08231, abi.decode(ownerData, (address)))); - uint256 fromPrevBal = abi.decode(fromBalData, (uint256)); - - // get new user current balance - (, bytes memory toBalData) = token.staticcall(abi.encodeWithSelector(0x70a08231, to)); - uint256 toPrevBal = abi.decode(toBalData, (uint256)); - - // update balances - stdstore.target(token).sig(0x70a08231).with_key(abi.decode(ownerData, (address))).checked_write(--fromPrevBal); - stdstore.target(token).sig(0x70a08231).with_key(to).checked_write(++toPrevBal); - - // update owner - stdstore.target(token).sig(0x6352211e).with_key(id).checked_write(to); - } - - function deployCodeTo(string memory what, address where) internal virtual { - deployCodeTo(what, "", 0, where); - } - - function deployCodeTo(string memory what, bytes memory args, address where) internal virtual { - deployCodeTo(what, args, 0, where); - } - - function deployCodeTo(string memory what, bytes memory args, uint256 value, address where) internal virtual { - bytes memory creationCode = vm.getCode(what); - vm.etch(where, abi.encodePacked(creationCode, args)); - (bool success, bytes memory runtimeBytecode) = where.call{value: value}(""); - require(success, "StdCheats deployCodeTo(string,bytes,uint256,address): Failed to create runtime bytecode."); - vm.etch(where, runtimeBytecode); - } - - // Used to prevent the compilation of console, which shortens the compilation time when console is not used elsewhere. - function console2_log_StdCheats(string memory p0) private view { - (bool status,) = address(CONSOLE2_ADDRESS).staticcall(abi.encodeWithSignature("log(string)", p0)); - status; - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdConfig.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdConfig.sol deleted file mode 100644 index 9eeeea9140..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdConfig.sol +++ /dev/null @@ -1,632 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity ^0.8.13; - -import {VmSafe} from "./Vm.sol"; -import {Variable, Type, TypeKind, LibVariable} from "./LibVariable.sol"; - -/// @notice A contract that parses a toml configuration file and load its -/// variables into storage, automatically casting them, on deployment. -/// -/// @dev This contract assumes a toml structure where top-level keys -/// represent chain ids or aliases. Under each chain key, variables are -/// organized by type in separate sub-tables like `[.]`, where -/// type must be: `bool`, `address`, `bytes32`, `uint`, `ìnt`, `string`, or `bytes`. -/// -/// Supported format: -/// ``` -/// [mainnet] -/// endpoint_url = "${MAINNET_RPC}" -/// -/// [mainnet.bool] -/// is_live = true -/// -/// [mainnet.address] -/// weth = "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2" -/// whitelisted_admins = [ -/// "${MAINNET_ADMIN}", -/// "0x00000000000000000000000000000000deadbeef", -/// "0x000000000000000000000000000000c0ffeebabe" -/// ] -/// -/// [mainnet.uint] -/// important_number = 123 -/// ``` -contract StdConfig { - using LibVariable for Type; - using LibVariable for TypeKind; - - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - /// @dev Types: `bool`, `address`, `bytes32`, `uint`, `ìnt`, `string`, `bytes`. - uint8 private constant NUM_TYPES = 7; - - // -- ERRORS --------------------------------------------------------------- - - error AlreadyInitialized(string key); - error InvalidChainKey(string aliasOrId); - error ChainNotInitialized(uint256 chainId); - error UnableToParseVariable(string key); - error WriteToFileInForbiddenCtxt(); - - // -- STORAGE (CACHE FROM CONFIG FILE) ------------------------------------ - - /// @dev Path to the loaded TOML configuration file. - string private _filePath; - - /// @dev List of top-level keys found in the TOML file, assumed to be chain names/aliases. - string[] private _chainKeys; - - /// @dev Storage for the configured RPC URL for each chain. - mapping(uint256 => string) private _rpcOf; - - /// @dev Storage for values, organized by chain ID and variable key. - mapping(uint256 => mapping(string => bytes)) private _dataOf; - - /// @dev Type cache for runtime checking when casting. - mapping(uint256 => mapping(string => Type)) private _typeOf; - - /// @dev When enabled, `set` will always write updates back to the configuration file. - /// Can only be enabled in a scripting context to prevent file corruption from - /// concurrent I/O access, as tests run in parallel. - bool private _writeToFile; - - // -- CONSTRUCTOR ---------------------------------------------------------- - - /// @notice Reads the TOML file and iterates through each top-level key, which is - /// assumed to be a chain name or ID. For each chain, it caches its RPC - /// endpoint and all variables defined in typed sub-tables like `[.]`, - /// where type must be: `bool`, `address`, `uint`, `bytes32`, `string`, or `bytes`. - /// - /// The constructor attempts to parse each variable first as a single value, - /// and if that fails, as an array of that type. If a variable cannot be - /// parsed as either, the constructor will revert with an error. - /// - /// @param configFilePath: The local path to the TOML configuration file. - /// @param writeToFile: Whether to write updates back to the TOML file. Only for scripts. - constructor(string memory configFilePath, bool writeToFile) { - if (writeToFile && !vm.isContext(VmSafe.ForgeContext.ScriptGroup)) { - revert WriteToFileInForbiddenCtxt(); - } - - _filePath = configFilePath; - _writeToFile = writeToFile; - string memory content = vm.resolveEnv(vm.readFile(configFilePath)); - string[] memory chain_keys = vm.parseTomlKeys(content, "$"); - - // Cache the entire configuration to storage - for (uint256 i = 0; i < chain_keys.length; i++) { - string memory chain_key = chain_keys[i]; - // Ignore top-level keys that are not tables - if (vm.parseTomlKeys(content, string.concat("$.", chain_key)).length == 0) { - continue; - } - uint256 chainId = resolveChainId(chain_key); - _chainKeys.push(chain_key); - - // Cache the configure rpc endpoint for that chain. - // Falls back to `[rpc_endpoints]`. Panics if no rpc endpoint is configured. - try vm.parseTomlString(content, string.concat("$.", chain_key, ".endpoint_url")) returns ( - string memory url - ) { - _rpcOf[chainId] = vm.resolveEnv(url); - } catch { - _rpcOf[chainId] = vm.resolveEnv(vm.rpcUrl(chain_key)); - } - - // Iterate through all the available `TypeKind`s (except `None`) to create the sub-section paths - for (uint8 t = 1; t <= NUM_TYPES; t++) { - TypeKind ty = TypeKind(t); - string memory typePath = string.concat("$.", chain_key, ".", ty.toTomlKey()); - - try vm.parseTomlKeys(content, typePath) returns (string[] memory keys) { - for (uint256 j = 0; j < keys.length; j++) { - string memory key = keys[j]; - if (_typeOf[chainId][key].kind == TypeKind.None) { - _loadAndCacheValue(content, string.concat(typePath, ".", key), chainId, key, ty); - } else { - revert AlreadyInitialized(key); - } - } - } catch {} - } - } - } - - function _loadAndCacheValue( - string memory content, - string memory path, - uint256 chainId, - string memory key, - TypeKind ty - ) private { - bool success = false; - if (ty == TypeKind.Bool) { - try vm.parseTomlBool(content, path) returns (bool val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Bool, false); - success = true; - } catch { - try vm.parseTomlBoolArray(content, path) returns (bool[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Bool, true); - success = true; - } catch {} - } - } else if (ty == TypeKind.Address) { - try vm.parseTomlAddress(content, path) returns (address val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Address, false); - success = true; - } catch { - try vm.parseTomlAddressArray(content, path) returns (address[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Address, true); - success = true; - } catch {} - } - } else if (ty == TypeKind.Bytes32) { - try vm.parseTomlBytes32(content, path) returns (bytes32 val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Bytes32, false); - success = true; - } catch { - try vm.parseTomlBytes32Array(content, path) returns (bytes32[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Bytes32, true); - success = true; - } catch {} - } - } else if (ty == TypeKind.Uint256) { - try vm.parseTomlUint(content, path) returns (uint256 val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Uint256, false); - success = true; - } catch { - try vm.parseTomlUintArray(content, path) returns (uint256[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Uint256, true); - success = true; - } catch {} - } - } else if (ty == TypeKind.Int256) { - try vm.parseTomlInt(content, path) returns (int256 val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Int256, false); - success = true; - } catch { - try vm.parseTomlIntArray(content, path) returns (int256[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Int256, true); - success = true; - } catch {} - } - } else if (ty == TypeKind.Bytes) { - try vm.parseTomlBytes(content, path) returns (bytes memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Bytes, false); - success = true; - } catch { - try vm.parseTomlBytesArray(content, path) returns (bytes[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Bytes, true); - success = true; - } catch {} - } - } else if (ty == TypeKind.String) { - try vm.parseTomlString(content, path) returns (string memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.String, false); - success = true; - } catch { - try vm.parseTomlStringArray(content, path) returns (string[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.String, true); - success = true; - } catch {} - } - } - - if (!success) { - revert UnableToParseVariable(key); - } - } - - // -- HELPER FUNCTIONS ----------------------------------------------------- - - /// @notice Enable or disable automatic writing to the TOML file on `set`. - /// Can only be enabled when scripting. - function writeUpdatesBackToFile(bool enabled) public { - if (enabled && !vm.isContext(VmSafe.ForgeContext.ScriptGroup)) { - revert WriteToFileInForbiddenCtxt(); - } - - _writeToFile = enabled; - } - - /// @notice Resolves a chain alias or a chain id string to its numerical chain id. - /// @param aliasOrId The string representing the chain alias (i.e. "mainnet") or a numerical ID (i.e. "1"). - /// @return The numerical chain ID. - /// @dev It first attempts to parse the input as a number. If that fails, it uses `vm.getChain` to resolve a named alias. - /// Reverts if the alias is not valid or not a number. - function resolveChainId(string memory aliasOrId) public view returns (uint256) { - try vm.parseUint(aliasOrId) returns (uint256 chainId) { - return chainId; - } catch { - try vm.getChain(aliasOrId) returns (VmSafe.Chain memory chainInfo) { - return chainInfo.chainId; - } catch { - revert InvalidChainKey(aliasOrId); - } - } - } - - /// @dev Retrieves the chain key/alias from the configuration based on the chain ID. - function _getChainKeyFromId(uint256 chainId) private view returns (string memory) { - for (uint256 i = 0; i < _chainKeys.length; i++) { - if (resolveChainId(_chainKeys[i]) == chainId) { - return _chainKeys[i]; - } - } - revert ChainNotInitialized(chainId); - } - - /// @dev Ensures type consistency when setting a value - prevents changing types unless uninitialized. - /// Updates type only when the previous type was `None`. - function _ensureTypeConsistency(uint256 chainId, string memory key, Type memory ty) private { - Type memory current = _typeOf[chainId][key]; - - if (current.kind == TypeKind.None) { - _typeOf[chainId][key] = ty; - } else { - current.assertEq(ty); - } - } - - /// @dev Wraps a string in double quotes for JSON compatibility. - function _quote(string memory s) private pure returns (string memory) { - return string.concat('"', s, '"'); - } - - /// @dev Writes a JSON-formatted value to a specific key in the TOML file. - /// @param chainId The chain id to write under. - /// @param ty The type category ('bool', 'address', 'uint', 'bytes32', 'string', or 'bytes'). - /// @param key The variable key name. - /// @param jsonValue The JSON-formatted value to write. - function _writeToToml(uint256 chainId, string memory ty, string memory key, string memory jsonValue) private { - string memory chainKey = _getChainKeyFromId(chainId); - string memory valueKey = string.concat("$.", chainKey, ".", ty, ".", key); - vm.writeToml(jsonValue, _filePath, valueKey); - } - - // -- GETTER FUNCTIONS ----------------------------------------------------- - - /// @dev Reads a variable for a given chain id and key, and returns it in a generic container. - /// The caller should use `LibVariable` to safely coerce the type. - /// Example: `uint256 myVar = config.get("my_key").toUint256();` - /// - /// @param chain_id The chain ID to read from. - /// @param key The key of the variable to retrieve. - /// @return `Variable` struct containing the type and the ABI-encoded value. - function get(uint256 chain_id, string memory key) public view returns (Variable memory) { - return Variable(_typeOf[chain_id][key], _dataOf[chain_id][key]); - } - - /// @dev Reads a variable for the current chain and a given key, and returns it in a generic container. - /// The caller should use `LibVariable` to safely coerce the type. - /// Example: `uint256 myVar = config.get("my_key").toUint256();` - /// - /// @param key The key of the variable to retrieve. - /// @return `Variable` struct containing the type and the ABI-encoded value. - function get(string memory key) public view returns (Variable memory) { - return get(vm.getChainId(), key); - } - - /// @dev Checks the existence of a variable for a given chain ID and key, and returns a boolean. - /// Example: `bool hasKey = config.exists(1, "my_key");` - /// - /// @param chain_id The chain ID to check. - /// @param key The variable key name. - /// @return `bool` indicating whether a variable with the given key exists. - function exists(uint256 chain_id, string memory key) public view returns (bool) { - return _dataOf[chain_id][key].length > 0; - } - - /// @dev Checks the existence of a variable for the current chain id and a given key, and returns a boolean. - /// Example: `bool hasKey = config.exists("my_key");` - /// - /// @param key The variable key name. - /// @return `bool` indicating whether a variable with the given key exists. - function exists(string memory key) public view returns (bool) { - return exists(vm.getChainId(), key); - } - - /// @notice Returns the numerical chain ids for all configured chains. - function getChainIds() public view returns (uint256[] memory) { - string[] memory keys = _chainKeys; - - uint256[] memory ids = new uint256[](keys.length); - for (uint256 i = 0; i < keys.length; i++) { - ids[i] = resolveChainId(keys[i]); - } - - return ids; - } - - /// @notice Reads the RPC URL for a specific chain id. - function getRpcUrl(uint256 chainId) public view returns (string memory) { - return _rpcOf[chainId]; - } - - /// @notice Reads the RPC URL for the current chain. - function getRpcUrl() public view returns (string memory) { - return _rpcOf[vm.getChainId()]; - } - - // -- SETTER FUNCTIONS (SINGLE VALUES) ------------------------------------- - - /// @notice Sets a boolean value for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, bool value) public { - Type memory ty = Type(TypeKind.Bool, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, vm.toString(value)); - } - - /// @notice Sets a boolean value for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, bool value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets an address value for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, address value) public { - Type memory ty = Type(TypeKind.Address, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, _quote(vm.toString(value))); - } - - /// @notice Sets an address value for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, address value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a bytes32 value for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, bytes32 value) public { - Type memory ty = Type(TypeKind.Bytes32, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, _quote(vm.toString(value))); - } - - /// @notice Sets a bytes32 value for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, bytes32 value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a uint256 value for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, uint256 value) public { - Type memory ty = Type(TypeKind.Uint256, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, vm.toString(value)); - } - - /// @notice Sets a uint256 value for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, uint256 value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets an int256 value for a given key and chain ID. - function set(uint256 chainId, string memory key, int256 value) public { - Type memory ty = Type(TypeKind.Int256, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, vm.toString(value)); - } - - /// @notice Sets an int256 value for a given key on the current chain. - function set(string memory key, int256 value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a string value for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, string memory value) public { - Type memory ty = Type(TypeKind.String, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, _quote(value)); - } - - /// @notice Sets a string value for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, string memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a bytes value for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, bytes memory value) public { - Type memory ty = Type(TypeKind.Bytes, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, _quote(vm.toString(value))); - } - - /// @notice Sets a bytes value for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, bytes memory value) public { - set(vm.getChainId(), key, value); - } - - // -- SETTER FUNCTIONS (ARRAYS) -------------------------------------------- - - /// @notice Sets a boolean array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, bool[] memory value) public { - Type memory ty = Type(TypeKind.Bool, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, vm.toString(value[i])); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets a boolean array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, bool[] memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets an address array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, address[] memory value) public { - Type memory ty = Type(TypeKind.Address, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, _quote(vm.toString(value[i]))); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets an address array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, address[] memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a bytes32 array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, bytes32[] memory value) public { - Type memory ty = Type(TypeKind.Bytes32, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, _quote(vm.toString(value[i]))); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets a bytes32 array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, bytes32[] memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a uint256 array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, uint256[] memory value) public { - Type memory ty = Type(TypeKind.Uint256, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, vm.toString(value[i])); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets a uint256 array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, uint256[] memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a int256 array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, int256[] memory value) public { - Type memory ty = Type(TypeKind.Int256, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, vm.toString(value[i])); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets a int256 array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, int256[] memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a string array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, string[] memory value) public { - Type memory ty = Type(TypeKind.String, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, _quote(value[i])); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets a string array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, string[] memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a bytes array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, bytes[] memory value) public { - Type memory ty = Type(TypeKind.Bytes, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, _quote(vm.toString(value[i]))); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets a bytes array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, bytes[] memory value) public { - set(vm.getChainId(), key, value); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdConstants.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdConstants.sol deleted file mode 100644 index 9f069ef8cb..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdConstants.sol +++ /dev/null @@ -1,30 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {IMulticall3} from "./interfaces/IMulticall3.sol"; -import {Vm} from "./Vm.sol"; - -library StdConstants { - /// @dev Cheat code address. - /// Calculated as `address(uint160(uint256(keccak256("hevm cheat code"))))`. - Vm internal constant VM = Vm(0x7109709ECfa91a80626fF3989D68f67F5b1DD12D); - /// @dev console.sol and console2.sol work by executing a staticcall to this address. - /// Calculated as `address(uint160(uint88(bytes11("console.log"))))`. - address internal constant CONSOLE = 0x000000000000000000636F6e736F6c652e6c6f67; - /// @dev Used when deploying with create2. - /// Taken from https://github.com/Arachnid/deterministic-deployment-proxy. - address internal constant CREATE2_FACTORY = 0x4e59b44847b379578588920cA78FbF26c0B4956C; - /// @dev The default address for tx.origin and msg.sender. - /// Calculated as `address(uint160(uint256(keccak256("foundry default caller"))))`. - address internal constant DEFAULT_SENDER = 0x1804c8AB1F12E6bbf3894d4083f33e07309d1f38; - /// @dev The address of the first contract `CREATE`d by a running test contract. - /// When running tests, each test contract is `CREATE`d by `DEFAULT_SENDER` with nonce 1. - /// Calculated as `VM.computeCreateAddress(VM.computeCreateAddress(DEFAULT_SENDER, 1), 1)`. - address internal constant DEFAULT_TEST_CONTRACT = 0x5615dEB798BB3E4dFa0139dFa1b3D433Cc23b72f; - /// @dev Deterministic deployment address of the Multicall3 contract. - /// Taken from https://www.multicall3.com. - IMulticall3 internal constant MULTICALL3_ADDRESS = IMulticall3(0xcA11bde05977b3631167028862bE2a173976CA11); - /// @dev The order of the secp256k1 curve. - uint256 internal constant SECP256K1_ORDER = - 115792089237316195423570985008687907852837564279074904382605163141518161494337; -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdError.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdError.sol deleted file mode 100644 index 24490087c2..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdError.sol +++ /dev/null @@ -1,15 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -// Panics work for versions >=0.8.0, but we lowered the pragma to make this compatible with Test -pragma solidity >=0.8.13 <0.9.0; - -library stdError { - bytes public constant assertionError = abi.encodeWithSignature("Panic(uint256)", 0x01); - bytes public constant arithmeticError = abi.encodeWithSignature("Panic(uint256)", 0x11); - bytes public constant divisionError = abi.encodeWithSignature("Panic(uint256)", 0x12); - bytes public constant enumConversionError = abi.encodeWithSignature("Panic(uint256)", 0x21); - bytes public constant encodeStorageError = abi.encodeWithSignature("Panic(uint256)", 0x22); - bytes public constant popError = abi.encodeWithSignature("Panic(uint256)", 0x31); - bytes public constant indexOOBError = abi.encodeWithSignature("Panic(uint256)", 0x32); - bytes public constant memOverflowError = abi.encodeWithSignature("Panic(uint256)", 0x41); - bytes public constant zeroVarError = abi.encodeWithSignature("Panic(uint256)", 0x51); -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdInvariant.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdInvariant.sol deleted file mode 100644 index 87ea87b348..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdInvariant.sol +++ /dev/null @@ -1,120 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -abstract contract StdInvariant { - struct FuzzSelector { - address addr; - bytes4[] selectors; - } - - struct FuzzArtifactSelector { - string artifact; - bytes4[] selectors; - } - - struct FuzzInterface { - address addr; - string[] artifacts; - } - - address[] private _excludedContracts; - address[] private _excludedSenders; - address[] private _targetedContracts; - address[] private _targetedSenders; - - string[] private _excludedArtifacts; - string[] private _targetedArtifacts; - - FuzzArtifactSelector[] private _targetedArtifactSelectors; - - FuzzSelector[] private _excludedSelectors; - FuzzSelector[] private _targetedSelectors; - - FuzzInterface[] private _targetedInterfaces; - - // Functions for users: - // These are intended to be called in tests. - - function excludeContract(address newExcludedContract_) internal { - _excludedContracts.push(newExcludedContract_); - } - - function excludeSelector(FuzzSelector memory newExcludedSelector_) internal { - _excludedSelectors.push(newExcludedSelector_); - } - - function excludeSender(address newExcludedSender_) internal { - _excludedSenders.push(newExcludedSender_); - } - - function excludeArtifact(string memory newExcludedArtifact_) internal { - _excludedArtifacts.push(newExcludedArtifact_); - } - - function targetArtifact(string memory newTargetedArtifact_) internal { - _targetedArtifacts.push(newTargetedArtifact_); - } - - function targetArtifactSelector(FuzzArtifactSelector memory newTargetedArtifactSelector_) internal { - _targetedArtifactSelectors.push(newTargetedArtifactSelector_); - } - - function targetContract(address newTargetedContract_) internal { - _targetedContracts.push(newTargetedContract_); - } - - function targetSelector(FuzzSelector memory newTargetedSelector_) internal { - _targetedSelectors.push(newTargetedSelector_); - } - - function targetSender(address newTargetedSender_) internal { - _targetedSenders.push(newTargetedSender_); - } - - function targetInterface(FuzzInterface memory newTargetedInterface_) internal { - _targetedInterfaces.push(newTargetedInterface_); - } - - // Functions for forge: - // These are called by forge to run invariant tests and don't need to be called in tests. - - function excludeArtifacts() public view returns (string[] memory excludedArtifacts_) { - excludedArtifacts_ = _excludedArtifacts; - } - - function excludeContracts() public view returns (address[] memory excludedContracts_) { - excludedContracts_ = _excludedContracts; - } - - function excludeSelectors() public view returns (FuzzSelector[] memory excludedSelectors_) { - excludedSelectors_ = _excludedSelectors; - } - - function excludeSenders() public view returns (address[] memory excludedSenders_) { - excludedSenders_ = _excludedSenders; - } - - function targetArtifacts() public view returns (string[] memory targetedArtifacts_) { - targetedArtifacts_ = _targetedArtifacts; - } - - function targetArtifactSelectors() public view returns (FuzzArtifactSelector[] memory targetedArtifactSelectors_) { - targetedArtifactSelectors_ = _targetedArtifactSelectors; - } - - function targetContracts() public view returns (address[] memory targetedContracts_) { - targetedContracts_ = _targetedContracts; - } - - function targetSelectors() public view returns (FuzzSelector[] memory targetedSelectors_) { - targetedSelectors_ = _targetedSelectors; - } - - function targetSenders() public view returns (address[] memory targetedSenders_) { - targetedSenders_ = _targetedSenders; - } - - function targetInterfaces() public view returns (FuzzInterface[] memory targetedInterfaces_) { - targetedInterfaces_ = _targetedInterfaces; - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdJson.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdJson.sol deleted file mode 100644 index 1c9b92e4a1..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdJson.sol +++ /dev/null @@ -1,275 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {VmSafe} from "./Vm.sol"; - -// Helpers for parsing and writing JSON files -// To parse: -// ``` -// using stdJson for string; -// string memory json = vm.readFile(""); -// json.readUint(""); -// ``` -// To write: -// ``` -// using stdJson for string; -// string memory json = "json"; -// json.serialize("a", uint256(123)); -// string memory semiFinal = json.serialize("b", string("test")); -// string memory finalJson = json.serialize("c", semiFinal); -// finalJson.write(""); -// ``` - -library stdJson { - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - function keyExists(string memory json, string memory key) internal view returns (bool) { - return vm.keyExistsJson(json, key); - } - - function parseRaw(string memory json, string memory key) internal pure returns (bytes memory) { - return vm.parseJson(json, key); - } - - function readUint(string memory json, string memory key) internal pure returns (uint256) { - return vm.parseJsonUint(json, key); - } - - function readUintArray(string memory json, string memory key) internal pure returns (uint256[] memory) { - return vm.parseJsonUintArray(json, key); - } - - function readInt(string memory json, string memory key) internal pure returns (int256) { - return vm.parseJsonInt(json, key); - } - - function readIntArray(string memory json, string memory key) internal pure returns (int256[] memory) { - return vm.parseJsonIntArray(json, key); - } - - function readBytes32(string memory json, string memory key) internal pure returns (bytes32) { - return vm.parseJsonBytes32(json, key); - } - - function readBytes32Array(string memory json, string memory key) internal pure returns (bytes32[] memory) { - return vm.parseJsonBytes32Array(json, key); - } - - function readString(string memory json, string memory key) internal pure returns (string memory) { - return vm.parseJsonString(json, key); - } - - function readStringArray(string memory json, string memory key) internal pure returns (string[] memory) { - return vm.parseJsonStringArray(json, key); - } - - function readAddress(string memory json, string memory key) internal pure returns (address) { - return vm.parseJsonAddress(json, key); - } - - function readAddressArray(string memory json, string memory key) internal pure returns (address[] memory) { - return vm.parseJsonAddressArray(json, key); - } - - function readBool(string memory json, string memory key) internal pure returns (bool) { - return vm.parseJsonBool(json, key); - } - - function readBoolArray(string memory json, string memory key) internal pure returns (bool[] memory) { - return vm.parseJsonBoolArray(json, key); - } - - function readBytes(string memory json, string memory key) internal pure returns (bytes memory) { - return vm.parseJsonBytes(json, key); - } - - function readBytesArray(string memory json, string memory key) internal pure returns (bytes[] memory) { - return vm.parseJsonBytesArray(json, key); - } - - function readUintOr(string memory json, string memory key, uint256 defaultValue) internal view returns (uint256) { - return keyExists(json, key) ? readUint(json, key) : defaultValue; - } - - function readUintArrayOr(string memory json, string memory key, uint256[] memory defaultValue) - internal - view - returns (uint256[] memory) - { - return keyExists(json, key) ? readUintArray(json, key) : defaultValue; - } - - function readIntOr(string memory json, string memory key, int256 defaultValue) internal view returns (int256) { - return keyExists(json, key) ? readInt(json, key) : defaultValue; - } - - function readIntArrayOr(string memory json, string memory key, int256[] memory defaultValue) - internal - view - returns (int256[] memory) - { - return keyExists(json, key) ? readIntArray(json, key) : defaultValue; - } - - function readBytes32Or(string memory json, string memory key, bytes32 defaultValue) - internal - view - returns (bytes32) - { - return keyExists(json, key) ? readBytes32(json, key) : defaultValue; - } - - function readBytes32ArrayOr(string memory json, string memory key, bytes32[] memory defaultValue) - internal - view - returns (bytes32[] memory) - { - return keyExists(json, key) ? readBytes32Array(json, key) : defaultValue; - } - - function readStringOr(string memory json, string memory key, string memory defaultValue) - internal - view - returns (string memory) - { - return keyExists(json, key) ? readString(json, key) : defaultValue; - } - - function readStringArrayOr(string memory json, string memory key, string[] memory defaultValue) - internal - view - returns (string[] memory) - { - return keyExists(json, key) ? readStringArray(json, key) : defaultValue; - } - - function readAddressOr(string memory json, string memory key, address defaultValue) - internal - view - returns (address) - { - return keyExists(json, key) ? readAddress(json, key) : defaultValue; - } - - function readAddressArrayOr(string memory json, string memory key, address[] memory defaultValue) - internal - view - returns (address[] memory) - { - return keyExists(json, key) ? readAddressArray(json, key) : defaultValue; - } - - function readBoolOr(string memory json, string memory key, bool defaultValue) internal view returns (bool) { - return keyExists(json, key) ? readBool(json, key) : defaultValue; - } - - function readBoolArrayOr(string memory json, string memory key, bool[] memory defaultValue) - internal - view - returns (bool[] memory) - { - return keyExists(json, key) ? readBoolArray(json, key) : defaultValue; - } - - function readBytesOr(string memory json, string memory key, bytes memory defaultValue) - internal - view - returns (bytes memory) - { - return keyExists(json, key) ? readBytes(json, key) : defaultValue; - } - - function readBytesArrayOr(string memory json, string memory key, bytes[] memory defaultValue) - internal - view - returns (bytes[] memory) - { - return keyExists(json, key) ? readBytesArray(json, key) : defaultValue; - } - - function serialize(string memory jsonKey, string memory rootObject) internal returns (string memory) { - return vm.serializeJson(jsonKey, rootObject); - } - - function serialize(string memory jsonKey, string memory key, bool value) internal returns (string memory) { - return vm.serializeBool(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bool[] memory value) internal returns (string memory) { - return vm.serializeBool(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, uint256 value) internal returns (string memory) { - return vm.serializeUint(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, uint256[] memory value) - internal - returns (string memory) - { - return vm.serializeUint(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, int256 value) internal returns (string memory) { - return vm.serializeInt(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, int256[] memory value) - internal - returns (string memory) - { - return vm.serializeInt(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, address value) internal returns (string memory) { - return vm.serializeAddress(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, address[] memory value) - internal - returns (string memory) - { - return vm.serializeAddress(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes32 value) internal returns (string memory) { - return vm.serializeBytes32(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes32[] memory value) - internal - returns (string memory) - { - return vm.serializeBytes32(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes memory value) internal returns (string memory) { - return vm.serializeBytes(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes[] memory value) - internal - returns (string memory) - { - return vm.serializeBytes(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, string memory value) internal returns (string memory) { - return vm.serializeString(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, string[] memory value) - internal - returns (string memory) - { - return vm.serializeString(jsonKey, key, value); - } - - function write(string memory jsonKey, string memory path) internal { - vm.writeJson(jsonKey, path); - } - - function write(string memory jsonKey, string memory path, string memory valueKey) internal { - vm.writeJson(jsonKey, path, valueKey); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdMath.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdMath.sol deleted file mode 100644 index a8ecc98f72..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdMath.sol +++ /dev/null @@ -1,47 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -library stdMath { - int256 private constant INT256_MIN = -57896044618658097711785492504343953926634992332820282019728792003956564819968; - - function abs(int256 a) internal pure returns (uint256) { - // Required or it will fail when `a = type(int256).min` - if (a == INT256_MIN) { - return 57896044618658097711785492504343953926634992332820282019728792003956564819968; - } - - return uint256(a > 0 ? a : -a); - } - - function delta(uint256 a, uint256 b) internal pure returns (uint256) { - return a > b ? a - b : b - a; - } - - function delta(int256 a, int256 b) internal pure returns (uint256) { - // a and b are of the same sign - // this works thanks to two's complement, the left-most bit is the sign bit - if ((a ^ b) > -1) { - return delta(abs(a), abs(b)); - } - - // a and b are of opposite signs - return abs(a) + abs(b); - } - - function percentDelta(uint256 a, uint256 b) internal pure returns (uint256) { - // Prevent division by zero - require(b != 0, "stdMath percentDelta(uint256,uint256): Divisor is zero"); - uint256 absDelta = delta(a, b); - - return absDelta * 1e18 / b; - } - - function percentDelta(int256 a, int256 b) internal pure returns (uint256) { - uint256 absDelta = delta(a, b); - uint256 absB = abs(b); - // Prevent division by zero - require(absB != 0, "stdMath percentDelta(int256,int256): Divisor is zero"); - - return absDelta * 1e18 / absB; - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdStorage.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdStorage.sol deleted file mode 100644 index d764182b4e..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdStorage.sol +++ /dev/null @@ -1,475 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {Vm} from "./Vm.sol"; - -struct FindData { - uint256 slot; - uint256 offsetLeft; - uint256 offsetRight; - bool found; -} - -struct StdStorage { - mapping(address => mapping(bytes4 => mapping(bytes32 => FindData))) finds; - bytes32[] _keys; - bytes4 _sig; - uint256 _depth; - address _target; - bytes32 _set; - bool _enable_packed_slots; - bytes _calldata; -} - -library stdStorageSafe { - event SlotFound(address who, bytes4 fsig, bytes32 keysHash, uint256 slot); - event WARNING_UninitedSlot(address who, uint256 slot); - - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - uint256 constant UINT256_MAX = 115792089237316195423570985008687907853269984665640564039457584007913129639935; - - function sigs(string memory sigStr) internal pure returns (bytes4) { - return bytes4(keccak256(bytes(sigStr))); - } - - function getCallParams(StdStorage storage self) internal view returns (bytes memory) { - if (self._calldata.length == 0) { - return flatten(self._keys); - } else { - return self._calldata; - } - } - - // Calls target contract with configured parameters - function callTarget(StdStorage storage self) internal view returns (bool, bytes32) { - bytes memory cd = abi.encodePacked(self._sig, getCallParams(self)); - (bool success, bytes memory rdat) = self._target.staticcall(cd); - bytes32 result = bytesToBytes32(rdat, 32 * self._depth); - - return (success, result); - } - - // Tries mutating slot value to determine if the targeted value is stored in it. - // If current value is 0, then we are setting slot value to type(uint256).max - // Otherwise, we set it to 0. That way, return value should always be affected. - function checkSlotMutatesCall(StdStorage storage self, bytes32 slot) internal returns (bool) { - bytes32 prevSlotValue = vm.load(self._target, slot); - (bool success, bytes32 prevReturnValue) = callTarget(self); - - bytes32 testVal = prevReturnValue == bytes32(0) ? bytes32(UINT256_MAX) : bytes32(0); - vm.store(self._target, slot, testVal); - - (, bytes32 newReturnValue) = callTarget(self); - - vm.store(self._target, slot, prevSlotValue); - - return (success && (prevReturnValue != newReturnValue)); - } - - // Tries setting one of the bits in slot to 1 until return value changes. - // Index of resulted bit is an offset packed slot has from left/right side - function findOffset(StdStorage storage self, bytes32 slot, bool left) internal returns (bool, uint256) { - for (uint256 offset = 0; offset < 256; offset++) { - uint256 valueToPut = left ? (1 << (255 - offset)) : (1 << offset); - vm.store(self._target, slot, bytes32(valueToPut)); - - (bool success, bytes32 data) = callTarget(self); - - if (success && (uint256(data) > 0)) { - return (true, offset); - } - } - return (false, 0); - } - - function findOffsets(StdStorage storage self, bytes32 slot) internal returns (bool, uint256, uint256) { - bytes32 prevSlotValue = vm.load(self._target, slot); - - (bool foundLeft, uint256 offsetLeft) = findOffset(self, slot, true); - (bool foundRight, uint256 offsetRight) = findOffset(self, slot, false); - - // `findOffset` may mutate slot value, so we are setting it to initial value - vm.store(self._target, slot, prevSlotValue); - return (foundLeft && foundRight, offsetLeft, offsetRight); - } - - function find(StdStorage storage self) internal returns (FindData storage) { - return find(self, true); - } - - /// @notice find an arbitrary storage slot given a function sig, input data, address of the contract and a value to check against - // slot complexity: - // if flat, will be bytes32(uint256(uint)); - // if map, will be keccak256(abi.encode(key, uint(slot))); - // if deep map, will be keccak256(abi.encode(key1, keccak256(abi.encode(key0, uint(slot))))); - // if map struct, will be bytes32(uint256(keccak256(abi.encode(key1, keccak256(abi.encode(key0, uint(slot)))))) + structFieldDepth); - function find(StdStorage storage self, bool _clear) internal returns (FindData storage) { - address who = self._target; - bytes4 fsig = self._sig; - uint256 field_depth = self._depth; - bytes memory params = getCallParams(self); - - // calldata to test against - if (self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))].found) { - if (_clear) { - clear(self); - } - return self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))]; - } - vm.record(); - (, bytes32 callResult) = callTarget(self); - (bytes32[] memory reads,) = vm.accesses(address(who)); - - if (reads.length == 0) { - revert("stdStorage find(StdStorage): No storage use detected for target."); - } else { - for (uint256 i = reads.length; --i >= 0;) { - bytes32 prev = vm.load(who, reads[i]); - if (prev == bytes32(0)) { - emit WARNING_UninitedSlot(who, uint256(reads[i])); - } - - if (!checkSlotMutatesCall(self, reads[i])) { - continue; - } - - (uint256 offsetLeft, uint256 offsetRight) = (0, 0); - - if (self._enable_packed_slots) { - bool found; - (found, offsetLeft, offsetRight) = findOffsets(self, reads[i]); - if (!found) { - continue; - } - } - - // Check that value between found offsets is equal to the current call result - uint256 curVal = (uint256(prev) & getMaskByOffsets(offsetLeft, offsetRight)) >> offsetRight; - - if (uint256(callResult) != curVal) { - continue; - } - - emit SlotFound(who, fsig, keccak256(abi.encodePacked(params, field_depth)), uint256(reads[i])); - self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))] = - FindData(uint256(reads[i]), offsetLeft, offsetRight, true); - break; - } - } - - require( - self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))].found, - "stdStorage find(StdStorage): Slot(s) not found." - ); - - if (_clear) { - clear(self); - } - return self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))]; - } - - function target(StdStorage storage self, address _target) internal returns (StdStorage storage) { - self._target = _target; - return self; - } - - function sig(StdStorage storage self, bytes4 _sig) internal returns (StdStorage storage) { - self._sig = _sig; - return self; - } - - function sig(StdStorage storage self, string memory _sig) internal returns (StdStorage storage) { - self._sig = sigs(_sig); - return self; - } - - function with_calldata(StdStorage storage self, bytes memory _calldata) internal returns (StdStorage storage) { - self._calldata = _calldata; - return self; - } - - function with_key(StdStorage storage self, address who) internal returns (StdStorage storage) { - self._keys.push(bytes32(uint256(uint160(who)))); - return self; - } - - function with_key(StdStorage storage self, uint256 amt) internal returns (StdStorage storage) { - self._keys.push(bytes32(amt)); - return self; - } - - function with_key(StdStorage storage self, bytes32 key) internal returns (StdStorage storage) { - self._keys.push(key); - return self; - } - - function enable_packed_slots(StdStorage storage self) internal returns (StdStorage storage) { - self._enable_packed_slots = true; - return self; - } - - function depth(StdStorage storage self, uint256 _depth) internal returns (StdStorage storage) { - self._depth = _depth; - return self; - } - - function read(StdStorage storage self) private returns (bytes memory) { - FindData storage data = find(self, false); - uint256 mask = getMaskByOffsets(data.offsetLeft, data.offsetRight); - uint256 value = (uint256(vm.load(self._target, bytes32(data.slot))) & mask) >> data.offsetRight; - clear(self); - return abi.encode(value); - } - - function read_bytes32(StdStorage storage self) internal returns (bytes32) { - return abi.decode(read(self), (bytes32)); - } - - function read_bool(StdStorage storage self) internal returns (bool) { - int256 v = read_int(self); - if (v == 0) return false; - if (v == 1) return true; - revert("stdStorage read_bool(StdStorage): Cannot decode. Make sure you are reading a bool."); - } - - function read_address(StdStorage storage self) internal returns (address) { - return abi.decode(read(self), (address)); - } - - function read_uint(StdStorage storage self) internal returns (uint256) { - return abi.decode(read(self), (uint256)); - } - - function read_int(StdStorage storage self) internal returns (int256) { - return abi.decode(read(self), (int256)); - } - - function parent(StdStorage storage self) internal returns (uint256, bytes32) { - address who = self._target; - uint256 field_depth = self._depth; - vm.startMappingRecording(); - uint256 child = find(self, true).slot - field_depth; - (bool found, bytes32 key, bytes32 parent_slot) = vm.getMappingKeyAndParentOf(who, bytes32(child)); - if (!found) { - revert( - "stdStorage parent(StdStorage): Cannot find parent. Make sure you give a slot and startMappingRecording() has been called." - ); - } - return (uint256(parent_slot), key); - } - - function root(StdStorage storage self) internal returns (uint256) { - address who = self._target; - uint256 field_depth = self._depth; - vm.startMappingRecording(); - uint256 child = find(self, true).slot - field_depth; - bool found; - bytes32 root_slot; - bytes32 parent_slot; - (found,, parent_slot) = vm.getMappingKeyAndParentOf(who, bytes32(child)); - if (!found) { - revert( - "stdStorage root(StdStorage): Cannot find parent. Make sure you give a slot and startMappingRecording() has been called." - ); - } - while (found) { - root_slot = parent_slot; - (found,, parent_slot) = vm.getMappingKeyAndParentOf(who, bytes32(root_slot)); - } - return uint256(root_slot); - } - - function bytesToBytes32(bytes memory b, uint256 offset) private pure returns (bytes32) { - bytes32 out; - - // Cap read length by remaining bytes from `offset`, and at most 32 bytes to avoid out-of-bounds - uint256 max = b.length > offset ? b.length - offset : 0; - if (max > 32) { - max = 32; - } - for (uint256 i = 0; i < max; i++) { - out |= bytes32(b[offset + i] & 0xFF) >> (i * 8); - } - return out; - } - - function flatten(bytes32[] memory b) private pure returns (bytes memory) { - bytes memory result = new bytes(b.length * 32); - for (uint256 i = 0; i < b.length; i++) { - bytes32 k = b[i]; - assembly ("memory-safe") { - mstore(add(result, add(32, mul(32, i))), k) - } - } - - return result; - } - - function clear(StdStorage storage self) internal { - delete self._target; - delete self._sig; - delete self._keys; - delete self._depth; - delete self._enable_packed_slots; - delete self._calldata; - } - - // Returns mask which contains non-zero bits for values between `offsetLeft` and `offsetRight` - // (slotValue & mask) >> offsetRight will be the value of the given packed variable - function getMaskByOffsets(uint256 offsetLeft, uint256 offsetRight) internal pure returns (uint256 mask) { - // mask = ((1 << (256 - (offsetRight + offsetLeft))) - 1) << offsetRight; - // using assembly because (1 << 256) causes overflow - assembly { - mask := shl(offsetRight, sub(shl(sub(256, add(offsetRight, offsetLeft)), 1), 1)) - } - } - - // Returns slot value with updated packed variable. - function getUpdatedSlotValue(bytes32 curValue, uint256 varValue, uint256 offsetLeft, uint256 offsetRight) - internal - pure - returns (bytes32 newValue) - { - return bytes32((uint256(curValue) & ~getMaskByOffsets(offsetLeft, offsetRight)) | (varValue << offsetRight)); - } -} - -library stdStorage { - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - - function sigs(string memory sigStr) internal pure returns (bytes4) { - return stdStorageSafe.sigs(sigStr); - } - - function find(StdStorage storage self) internal returns (uint256) { - return find(self, true); - } - - function find(StdStorage storage self, bool _clear) internal returns (uint256) { - return stdStorageSafe.find(self, _clear).slot; - } - - function target(StdStorage storage self, address _target) internal returns (StdStorage storage) { - return stdStorageSafe.target(self, _target); - } - - function sig(StdStorage storage self, bytes4 _sig) internal returns (StdStorage storage) { - return stdStorageSafe.sig(self, _sig); - } - - function sig(StdStorage storage self, string memory _sig) internal returns (StdStorage storage) { - return stdStorageSafe.sig(self, _sig); - } - - function with_key(StdStorage storage self, address who) internal returns (StdStorage storage) { - return stdStorageSafe.with_key(self, who); - } - - function with_key(StdStorage storage self, uint256 amt) internal returns (StdStorage storage) { - return stdStorageSafe.with_key(self, amt); - } - - function with_key(StdStorage storage self, bytes32 key) internal returns (StdStorage storage) { - return stdStorageSafe.with_key(self, key); - } - - function with_calldata(StdStorage storage self, bytes memory _calldata) internal returns (StdStorage storage) { - return stdStorageSafe.with_calldata(self, _calldata); - } - - function enable_packed_slots(StdStorage storage self) internal returns (StdStorage storage) { - return stdStorageSafe.enable_packed_slots(self); - } - - function depth(StdStorage storage self, uint256 _depth) internal returns (StdStorage storage) { - return stdStorageSafe.depth(self, _depth); - } - - function clear(StdStorage storage self) internal { - stdStorageSafe.clear(self); - } - - function checked_write(StdStorage storage self, address who) internal { - checked_write(self, bytes32(uint256(uint160(who)))); - } - - function checked_write(StdStorage storage self, uint256 amt) internal { - checked_write(self, bytes32(amt)); - } - - function checked_write_int(StdStorage storage self, int256 val) internal { - checked_write(self, bytes32(uint256(val))); - } - - function checked_write(StdStorage storage self, bool write) internal { - bytes32 t; - assembly ("memory-safe") { - t := write - } - checked_write(self, t); - } - - function checked_write(StdStorage storage self, bytes32 set) internal { - address who = self._target; - bytes4 fsig = self._sig; - uint256 field_depth = self._depth; - bytes memory params = stdStorageSafe.getCallParams(self); - - if (!self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))].found) { - find(self, false); - } - FindData storage data = self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))]; - if ((data.offsetLeft + data.offsetRight) > 0) { - uint256 maxVal = 2 ** (256 - (data.offsetLeft + data.offsetRight)); - require( - uint256(set) < maxVal, - string( - abi.encodePacked( - "stdStorage find(StdStorage): Packed slot. We can't fit value greater than ", - vm.toString(maxVal) - ) - ) - ); - } - bytes32 curVal = vm.load(who, bytes32(data.slot)); - bytes32 valToSet = stdStorageSafe.getUpdatedSlotValue(curVal, uint256(set), data.offsetLeft, data.offsetRight); - - vm.store(who, bytes32(data.slot), valToSet); - - (bool success, bytes32 callResult) = stdStorageSafe.callTarget(self); - - if (!success || callResult != set) { - vm.store(who, bytes32(data.slot), curVal); - revert("stdStorage find(StdStorage): Failed to write value."); - } - clear(self); - } - - function read_bytes32(StdStorage storage self) internal returns (bytes32) { - return stdStorageSafe.read_bytes32(self); - } - - function read_bool(StdStorage storage self) internal returns (bool) { - return stdStorageSafe.read_bool(self); - } - - function read_address(StdStorage storage self) internal returns (address) { - return stdStorageSafe.read_address(self); - } - - function read_uint(StdStorage storage self) internal returns (uint256) { - return stdStorageSafe.read_uint(self); - } - - function read_int(StdStorage storage self) internal returns (int256) { - return stdStorageSafe.read_int(self); - } - - function parent(StdStorage storage self) internal returns (uint256, bytes32) { - return stdStorageSafe.parent(self); - } - - function root(StdStorage storage self) internal returns (uint256) { - return stdStorageSafe.root(self); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdStyle.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdStyle.sol deleted file mode 100644 index ad63400fbc..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdStyle.sol +++ /dev/null @@ -1,333 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {VmSafe} from "./Vm.sol"; - -library StdStyle { - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - string constant RED = "\u001b[91m"; - string constant GREEN = "\u001b[92m"; - string constant YELLOW = "\u001b[93m"; - string constant BLUE = "\u001b[94m"; - string constant MAGENTA = "\u001b[95m"; - string constant CYAN = "\u001b[96m"; - string constant BOLD = "\u001b[1m"; - string constant DIM = "\u001b[2m"; - string constant ITALIC = "\u001b[3m"; - string constant UNDERLINE = "\u001b[4m"; - string constant INVERSE = "\u001b[7m"; - string constant RESET = "\u001b[0m"; - - function styleConcat(string memory style, string memory self) private pure returns (string memory) { - return string(abi.encodePacked(style, self, RESET)); - } - - function red(string memory self) internal pure returns (string memory) { - return styleConcat(RED, self); - } - - function red(uint256 self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function red(int256 self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function red(address self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function red(bool self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function redBytes(bytes memory self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function redBytes32(bytes32 self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function green(string memory self) internal pure returns (string memory) { - return styleConcat(GREEN, self); - } - - function green(uint256 self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function green(int256 self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function green(address self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function green(bool self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function greenBytes(bytes memory self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function greenBytes32(bytes32 self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function yellow(string memory self) internal pure returns (string memory) { - return styleConcat(YELLOW, self); - } - - function yellow(uint256 self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellow(int256 self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellow(address self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellow(bool self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellowBytes(bytes memory self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellowBytes32(bytes32 self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function blue(string memory self) internal pure returns (string memory) { - return styleConcat(BLUE, self); - } - - function blue(uint256 self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blue(int256 self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blue(address self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blue(bool self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blueBytes(bytes memory self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blueBytes32(bytes32 self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function magenta(string memory self) internal pure returns (string memory) { - return styleConcat(MAGENTA, self); - } - - function magenta(uint256 self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magenta(int256 self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magenta(address self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magenta(bool self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magentaBytes(bytes memory self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magentaBytes32(bytes32 self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function cyan(string memory self) internal pure returns (string memory) { - return styleConcat(CYAN, self); - } - - function cyan(uint256 self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyan(int256 self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyan(address self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyan(bool self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyanBytes(bytes memory self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyanBytes32(bytes32 self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function bold(string memory self) internal pure returns (string memory) { - return styleConcat(BOLD, self); - } - - function bold(uint256 self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function bold(int256 self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function bold(address self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function bold(bool self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function boldBytes(bytes memory self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function boldBytes32(bytes32 self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function dim(string memory self) internal pure returns (string memory) { - return styleConcat(DIM, self); - } - - function dim(uint256 self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dim(int256 self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dim(address self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dim(bool self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dimBytes(bytes memory self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dimBytes32(bytes32 self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function italic(string memory self) internal pure returns (string memory) { - return styleConcat(ITALIC, self); - } - - function italic(uint256 self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italic(int256 self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italic(address self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italic(bool self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italicBytes(bytes memory self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italicBytes32(bytes32 self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function underline(string memory self) internal pure returns (string memory) { - return styleConcat(UNDERLINE, self); - } - - function underline(uint256 self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underline(int256 self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underline(address self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underline(bool self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underlineBytes(bytes memory self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underlineBytes32(bytes32 self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function inverse(string memory self) internal pure returns (string memory) { - return styleConcat(INVERSE, self); - } - - function inverse(uint256 self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverse(int256 self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverse(address self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverse(bool self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverseBytes(bytes memory self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverseBytes32(bytes32 self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdToml.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdToml.sol deleted file mode 100644 index 3e94ed99f4..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdToml.sol +++ /dev/null @@ -1,275 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {VmSafe} from "./Vm.sol"; - -// Helpers for parsing and writing TOML files -// To parse: -// ``` -// using stdToml for string; -// string memory toml = vm.readFile(""); -// toml.readUint(""); -// ``` -// To write: -// ``` -// using stdToml for string; -// string memory json = "json"; -// json.serialize("a", uint256(123)); -// string memory semiFinal = json.serialize("b", string("test")); -// string memory finalJson = json.serialize("c", semiFinal); -// finalJson.write(""); -// ``` - -library stdToml { - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - function keyExists(string memory toml, string memory key) internal view returns (bool) { - return vm.keyExistsToml(toml, key); - } - - function parseRaw(string memory toml, string memory key) internal pure returns (bytes memory) { - return vm.parseToml(toml, key); - } - - function readUint(string memory toml, string memory key) internal pure returns (uint256) { - return vm.parseTomlUint(toml, key); - } - - function readUintArray(string memory toml, string memory key) internal pure returns (uint256[] memory) { - return vm.parseTomlUintArray(toml, key); - } - - function readInt(string memory toml, string memory key) internal pure returns (int256) { - return vm.parseTomlInt(toml, key); - } - - function readIntArray(string memory toml, string memory key) internal pure returns (int256[] memory) { - return vm.parseTomlIntArray(toml, key); - } - - function readBytes32(string memory toml, string memory key) internal pure returns (bytes32) { - return vm.parseTomlBytes32(toml, key); - } - - function readBytes32Array(string memory toml, string memory key) internal pure returns (bytes32[] memory) { - return vm.parseTomlBytes32Array(toml, key); - } - - function readString(string memory toml, string memory key) internal pure returns (string memory) { - return vm.parseTomlString(toml, key); - } - - function readStringArray(string memory toml, string memory key) internal pure returns (string[] memory) { - return vm.parseTomlStringArray(toml, key); - } - - function readAddress(string memory toml, string memory key) internal pure returns (address) { - return vm.parseTomlAddress(toml, key); - } - - function readAddressArray(string memory toml, string memory key) internal pure returns (address[] memory) { - return vm.parseTomlAddressArray(toml, key); - } - - function readBool(string memory toml, string memory key) internal pure returns (bool) { - return vm.parseTomlBool(toml, key); - } - - function readBoolArray(string memory toml, string memory key) internal pure returns (bool[] memory) { - return vm.parseTomlBoolArray(toml, key); - } - - function readBytes(string memory toml, string memory key) internal pure returns (bytes memory) { - return vm.parseTomlBytes(toml, key); - } - - function readBytesArray(string memory toml, string memory key) internal pure returns (bytes[] memory) { - return vm.parseTomlBytesArray(toml, key); - } - - function readUintOr(string memory toml, string memory key, uint256 defaultValue) internal view returns (uint256) { - return keyExists(toml, key) ? readUint(toml, key) : defaultValue; - } - - function readUintArrayOr(string memory toml, string memory key, uint256[] memory defaultValue) - internal - view - returns (uint256[] memory) - { - return keyExists(toml, key) ? readUintArray(toml, key) : defaultValue; - } - - function readIntOr(string memory toml, string memory key, int256 defaultValue) internal view returns (int256) { - return keyExists(toml, key) ? readInt(toml, key) : defaultValue; - } - - function readIntArrayOr(string memory toml, string memory key, int256[] memory defaultValue) - internal - view - returns (int256[] memory) - { - return keyExists(toml, key) ? readIntArray(toml, key) : defaultValue; - } - - function readBytes32Or(string memory toml, string memory key, bytes32 defaultValue) - internal - view - returns (bytes32) - { - return keyExists(toml, key) ? readBytes32(toml, key) : defaultValue; - } - - function readBytes32ArrayOr(string memory toml, string memory key, bytes32[] memory defaultValue) - internal - view - returns (bytes32[] memory) - { - return keyExists(toml, key) ? readBytes32Array(toml, key) : defaultValue; - } - - function readStringOr(string memory toml, string memory key, string memory defaultValue) - internal - view - returns (string memory) - { - return keyExists(toml, key) ? readString(toml, key) : defaultValue; - } - - function readStringArrayOr(string memory toml, string memory key, string[] memory defaultValue) - internal - view - returns (string[] memory) - { - return keyExists(toml, key) ? readStringArray(toml, key) : defaultValue; - } - - function readAddressOr(string memory toml, string memory key, address defaultValue) - internal - view - returns (address) - { - return keyExists(toml, key) ? readAddress(toml, key) : defaultValue; - } - - function readAddressArrayOr(string memory toml, string memory key, address[] memory defaultValue) - internal - view - returns (address[] memory) - { - return keyExists(toml, key) ? readAddressArray(toml, key) : defaultValue; - } - - function readBoolOr(string memory toml, string memory key, bool defaultValue) internal view returns (bool) { - return keyExists(toml, key) ? readBool(toml, key) : defaultValue; - } - - function readBoolArrayOr(string memory toml, string memory key, bool[] memory defaultValue) - internal - view - returns (bool[] memory) - { - return keyExists(toml, key) ? readBoolArray(toml, key) : defaultValue; - } - - function readBytesOr(string memory toml, string memory key, bytes memory defaultValue) - internal - view - returns (bytes memory) - { - return keyExists(toml, key) ? readBytes(toml, key) : defaultValue; - } - - function readBytesArrayOr(string memory toml, string memory key, bytes[] memory defaultValue) - internal - view - returns (bytes[] memory) - { - return keyExists(toml, key) ? readBytesArray(toml, key) : defaultValue; - } - - function serialize(string memory jsonKey, string memory rootObject) internal returns (string memory) { - return vm.serializeJson(jsonKey, rootObject); - } - - function serialize(string memory jsonKey, string memory key, bool value) internal returns (string memory) { - return vm.serializeBool(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bool[] memory value) internal returns (string memory) { - return vm.serializeBool(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, uint256 value) internal returns (string memory) { - return vm.serializeUint(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, uint256[] memory value) - internal - returns (string memory) - { - return vm.serializeUint(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, int256 value) internal returns (string memory) { - return vm.serializeInt(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, int256[] memory value) - internal - returns (string memory) - { - return vm.serializeInt(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, address value) internal returns (string memory) { - return vm.serializeAddress(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, address[] memory value) - internal - returns (string memory) - { - return vm.serializeAddress(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes32 value) internal returns (string memory) { - return vm.serializeBytes32(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes32[] memory value) - internal - returns (string memory) - { - return vm.serializeBytes32(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes memory value) internal returns (string memory) { - return vm.serializeBytes(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes[] memory value) - internal - returns (string memory) - { - return vm.serializeBytes(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, string memory value) internal returns (string memory) { - return vm.serializeString(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, string[] memory value) - internal - returns (string memory) - { - return vm.serializeString(jsonKey, key, value); - } - - function write(string memory jsonKey, string memory path) internal { - vm.writeToml(jsonKey, path); - } - - function write(string memory jsonKey, string memory path, string memory valueKey) internal { - vm.writeToml(jsonKey, path, valueKey); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdUtils.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdUtils.sol deleted file mode 100644 index 7ecf1bb6c0..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/StdUtils.sol +++ /dev/null @@ -1,200 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {IMulticall3} from "./interfaces/IMulticall3.sol"; -import {StdConstants} from "./StdConstants.sol"; -import {VmSafe} from "./Vm.sol"; - -abstract contract StdUtils { - /*////////////////////////////////////////////////////////////////////////// - CONSTANTS - //////////////////////////////////////////////////////////////////////////*/ - - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - address private constant CONSOLE2_ADDRESS = 0x000000000000000000636F6e736F6c652e6c6f67; - uint256 private constant INT256_MIN_ABS = - 57896044618658097711785492504343953926634992332820282019728792003956564819968; - uint256 private constant SECP256K1_ORDER = - 115792089237316195423570985008687907852837564279074904382605163141518161494337; - uint256 private constant UINT256_MAX = - 115792089237316195423570985008687907853269984665640564039457584007913129639935; - - /*////////////////////////////////////////////////////////////////////////// - INTERNAL FUNCTIONS - //////////////////////////////////////////////////////////////////////////*/ - - function _bound(uint256 x, uint256 min, uint256 max) internal pure virtual returns (uint256 result) { - require(min <= max, "StdUtils bound(uint256,uint256,uint256): Max is less than min."); - // If x is between min and max, return x directly. This is to ensure that dictionary values - // do not get shifted if the min is nonzero. More info: https://github.com/foundry-rs/forge-std/issues/188 - if (x >= min && x <= max) return x; - - uint256 size = max - min + 1; - - // If the value is 0, 1, 2, 3, wrap that to min, min+1, min+2, min+3. Similarly for the UINT256_MAX side. - // This helps ensure coverage of the min/max values. - if (x <= 3 && size > x) return min + x; - if (x >= UINT256_MAX - 3 && size > UINT256_MAX - x) return max - (UINT256_MAX - x); - - // Otherwise, wrap x into the range [min, max], i.e. the range is inclusive. - if (x > max) { - uint256 diff = x - max; - uint256 rem = diff % size; - if (rem == 0) return max; - result = min + rem - 1; - } else if (x < min) { - uint256 diff = min - x; - uint256 rem = diff % size; - if (rem == 0) return min; - result = max - rem + 1; - } - } - - function bound(uint256 x, uint256 min, uint256 max) internal pure virtual returns (uint256 result) { - result = _bound(x, min, max); - } - - function _bound(int256 x, int256 min, int256 max) internal pure virtual returns (int256 result) { - require(min <= max, "StdUtils bound(int256,int256,int256): Max is less than min."); - - // Shifting all int256 values to uint256 to use _bound function. The range of two types are: - // int256 : -(2**255) ~ (2**255 - 1) - // uint256: 0 ~ (2**256 - 1) - // So, add 2**255, INT256_MIN_ABS to the integer values. - // - // If the given integer value is -2**255, we cannot use `-uint256(-x)` because of the overflow. - // So, use `~uint256(x) + 1` instead. - uint256 _x = x < 0 ? (INT256_MIN_ABS - ~uint256(x) - 1) : (uint256(x) + INT256_MIN_ABS); - uint256 _min = min < 0 ? (INT256_MIN_ABS - ~uint256(min) - 1) : (uint256(min) + INT256_MIN_ABS); - uint256 _max = max < 0 ? (INT256_MIN_ABS - ~uint256(max) - 1) : (uint256(max) + INT256_MIN_ABS); - - uint256 y = _bound(_x, _min, _max); - - // To move it back to int256 value, subtract INT256_MIN_ABS at here. - result = y < INT256_MIN_ABS ? int256(~(INT256_MIN_ABS - y) + 1) : int256(y - INT256_MIN_ABS); - } - - function bound(int256 x, int256 min, int256 max) internal pure virtual returns (int256 result) { - result = _bound(x, min, max); - } - - function boundPrivateKey(uint256 privateKey) internal pure virtual returns (uint256 result) { - result = _bound(privateKey, 1, SECP256K1_ORDER - 1); - } - - function bytesToUint(bytes memory b) internal pure virtual returns (uint256) { - require(b.length <= 32, "StdUtils bytesToUint(bytes): Bytes length exceeds 32."); - return abi.decode(abi.encodePacked(new bytes(32 - b.length), b), (uint256)); - } - - /// @dev Compute the address a contract will be deployed at for a given deployer address and nonce - function computeCreateAddress(address deployer, uint256 nonce) internal pure virtual returns (address) { - console2_log_StdUtils("computeCreateAddress is deprecated. Please use vm.computeCreateAddress instead."); - return vm.computeCreateAddress(deployer, nonce); - } - - function computeCreate2Address(bytes32 salt, bytes32 initcodeHash, address deployer) - internal - pure - virtual - returns (address) - { - console2_log_StdUtils("computeCreate2Address is deprecated. Please use vm.computeCreate2Address instead."); - return vm.computeCreate2Address(salt, initcodeHash, deployer); - } - - /// @dev returns the address of a contract created with CREATE2 using the default CREATE2 deployer - function computeCreate2Address(bytes32 salt, bytes32 initCodeHash) internal pure returns (address) { - console2_log_StdUtils("computeCreate2Address is deprecated. Please use vm.computeCreate2Address instead."); - return vm.computeCreate2Address(salt, initCodeHash); - } - - /// @dev returns the hash of the init code (creation code + no args) used in CREATE2 with no constructor arguments - /// @param creationCode the creation code of a contract C, as returned by type(C).creationCode - function hashInitCode(bytes memory creationCode) internal pure returns (bytes32) { - return hashInitCode(creationCode, ""); - } - - /// @dev returns the hash of the init code (creation code + ABI-encoded args) used in CREATE2 - /// @param creationCode the creation code of a contract C, as returned by type(C).creationCode - /// @param args the ABI-encoded arguments to the constructor of C - function hashInitCode(bytes memory creationCode, bytes memory args) internal pure returns (bytes32) { - return keccak256(abi.encodePacked(creationCode, args)); - } - - // Performs a single call with Multicall3 to query the ERC-20 token balances of the given addresses. - function getTokenBalances(address token, address[] memory addresses) - internal - virtual - returns (uint256[] memory balances) - { - uint256 tokenCodeSize; - assembly { - tokenCodeSize := extcodesize(token) - } - require(tokenCodeSize > 0, "StdUtils getTokenBalances(address,address[]): Token address is not a contract."); - - // ABI encode the aggregate call to Multicall3. - uint256 length = addresses.length; - IMulticall3.Call[] memory calls = new IMulticall3.Call[](length); - for (uint256 i = 0; i < length; ++i) { - // 0x70a08231 = bytes4("balanceOf(address)")) - calls[i] = IMulticall3.Call({target: token, callData: abi.encodeWithSelector(0x70a08231, (addresses[i]))}); - } - - // Make the aggregate call. - (, bytes[] memory returnData) = StdConstants.MULTICALL3_ADDRESS.aggregate(calls); - - // ABI decode the return data and return the balances. - balances = new uint256[](length); - for (uint256 i = 0; i < length; ++i) { - balances[i] = abi.decode(returnData[i], (uint256)); - } - } - - /*////////////////////////////////////////////////////////////////////////// - PRIVATE FUNCTIONS - //////////////////////////////////////////////////////////////////////////*/ - - function addressFromLast20Bytes(bytes32 bytesValue) private pure returns (address) { - return address(uint160(uint256(bytesValue))); - } - - // This section is used to prevent the compilation of console, which shortens the compilation time when console is - // not used elsewhere. We also trick the compiler into letting us make the console log methods as `pure` to avoid - // any breaking changes to function signatures. - function _castLogPayloadViewToPure(function(bytes memory) internal view fnIn) - internal - pure - returns (function(bytes memory) internal pure fnOut) - { - assembly { - fnOut := fnIn - } - } - - function _sendLogPayload(bytes memory payload) internal pure { - _castLogPayloadViewToPure(_sendLogPayloadView)(payload); - } - - function _sendLogPayloadView(bytes memory payload) private view { - uint256 payloadLength = payload.length; - address consoleAddress = CONSOLE2_ADDRESS; - assembly ("memory-safe") { - let payloadStart := add(payload, 32) - let r := staticcall(gas(), consoleAddress, payloadStart, payloadLength, 0, 0) - } - } - - function console2_log_StdUtils(string memory p0) private pure { - _sendLogPayload(abi.encodeWithSignature("log(string)", p0)); - } - - function console2_log_StdUtils(string memory p0, uint256 p1) private pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256)", p0, p1)); - } - - function console2_log_StdUtils(string memory p0, string memory p1) private pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string)", p0, p1)); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Test.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Test.sol deleted file mode 100644 index af91dd81cc..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Test.sol +++ /dev/null @@ -1,32 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -// 💬 ABOUT -// Forge Std's default Test. - -// 🧩 MODULES -import {console} from "./console.sol"; -import {console2} from "./console2.sol"; -import {safeconsole} from "./safeconsole.sol"; -import {StdAssertions} from "./StdAssertions.sol"; -import {StdChains} from "./StdChains.sol"; -import {StdCheats} from "./StdCheats.sol"; -import {StdConstants} from "./StdConstants.sol"; -import {stdError} from "./StdError.sol"; -import {StdInvariant} from "./StdInvariant.sol"; -import {stdJson} from "./StdJson.sol"; -import {stdMath} from "./StdMath.sol"; -import {StdStorage, stdStorage} from "./StdStorage.sol"; -import {StdStyle} from "./StdStyle.sol"; -import {stdToml} from "./StdToml.sol"; -import {StdUtils} from "./StdUtils.sol"; -import {Vm} from "./Vm.sol"; - -// 📦 BOILERPLATE -import {TestBase} from "./Base.sol"; - -// ⭐️ TEST -abstract contract Test is TestBase, StdAssertions, StdChains, StdCheats, StdInvariant, StdUtils { - // Note: IS_TEST() must return true. - bool public IS_TEST = true; -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Vm.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Vm.sol deleted file mode 100644 index 5703661ea5..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/Vm.sol +++ /dev/null @@ -1,2500 +0,0 @@ -// Automatically @generated by scripts/vm.py. Do not modify manually. - -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -/// The `VmSafe` interface does not allow manipulation of the EVM state or other actions that may -/// result in Script simulations differing from on-chain execution. It is recommended to only use -/// these cheats in scripts. -interface VmSafe { - /// A modification applied to either `msg.sender` or `tx.origin`. Returned by `readCallers`. - enum CallerMode { - // No caller modification is currently active. - None, - // A one time broadcast triggered by a `vm.broadcast()` call is currently active. - Broadcast, - // A recurrent broadcast triggered by a `vm.startBroadcast()` call is currently active. - RecurrentBroadcast, - // A one time prank triggered by a `vm.prank()` call is currently active. - Prank, - // A recurrent prank triggered by a `vm.startPrank()` call is currently active. - RecurrentPrank - } - - /// The kind of account access that occurred. - enum AccountAccessKind { - // The account was called. - Call, - // The account was called via delegatecall. - DelegateCall, - // The account was called via callcode. - CallCode, - // The account was called via staticcall. - StaticCall, - // The account was created. - Create, - // The account was selfdestructed. - SelfDestruct, - // Synthetic access indicating the current context has resumed after a previous sub-context (AccountAccess). - Resume, - // The account's balance was read. - Balance, - // The account's codesize was read. - Extcodesize, - // The account's codehash was read. - Extcodehash, - // The account's code was copied. - Extcodecopy - } - - /// Forge execution contexts. - enum ForgeContext { - // Test group execution context (test, coverage or snapshot). - TestGroup, - // `forge test` execution context. - Test, - // `forge coverage` execution context. - Coverage, - // `forge snapshot` execution context. - Snapshot, - // Script group execution context (dry run, broadcast or resume). - ScriptGroup, - // `forge script` execution context. - ScriptDryRun, - // `forge script --broadcast` execution context. - ScriptBroadcast, - // `forge script --resume` execution context. - ScriptResume, - // Unknown `forge` execution context. - Unknown - } - - /// The transaction type (`txType`) of the broadcast. - enum BroadcastTxType { - // Represents a CALL broadcast tx. - Call, - // Represents a CREATE broadcast tx. - Create, - // Represents a CREATE2 broadcast tx. - Create2 - } - - /// An Ethereum log. Returned by `getRecordedLogs`. - struct Log { - // The topics of the log, including the signature, if any. - bytes32[] topics; - // The raw data of the log. - bytes data; - // The address of the log's emitter. - address emitter; - } - - /// An RPC URL and its alias. Returned by `rpcUrlStructs`. - struct Rpc { - // The alias of the RPC URL. - string key; - // The RPC URL. - string url; - } - - /// An RPC log object. Returned by `eth_getLogs`. - struct EthGetLogs { - // The address of the log's emitter. - address emitter; - // The topics of the log, including the signature, if any. - bytes32[] topics; - // The raw data of the log. - bytes data; - // The block hash. - bytes32 blockHash; - // The block number. - uint64 blockNumber; - // The transaction hash. - bytes32 transactionHash; - // The transaction index in the block. - uint64 transactionIndex; - // The log index. - uint256 logIndex; - // Whether the log was removed. - bool removed; - } - - /// A single entry in a directory listing. Returned by `readDir`. - struct DirEntry { - // The error message, if any. - string errorMessage; - // The path of the entry. - string path; - // The depth of the entry. - uint64 depth; - // Whether the entry is a directory. - bool isDir; - // Whether the entry is a symlink. - bool isSymlink; - } - - /// Metadata information about a file. - /// This structure is returned from the `fsMetadata` function and represents known - /// metadata about a file such as its permissions, size, modification - /// times, etc. - struct FsMetadata { - // True if this metadata is for a directory. - bool isDir; - // True if this metadata is for a symlink. - bool isSymlink; - // The size of the file, in bytes, this metadata is for. - uint256 length; - // True if this metadata is for a readonly (unwritable) file. - bool readOnly; - // The last modification time listed in this metadata. - uint256 modified; - // The last access time of this metadata. - uint256 accessed; - // The creation time listed in this metadata. - uint256 created; - } - - /// A wallet with a public and private key. - struct Wallet { - // The wallet's address. - address addr; - // The wallet's public key `X`. - uint256 publicKeyX; - // The wallet's public key `Y`. - uint256 publicKeyY; - // The wallet's private key. - uint256 privateKey; - } - - /// The result of a `tryFfi` call. - struct FfiResult { - // The exit code of the call. - int32 exitCode; - // The optionally hex-decoded `stdout` data. - bytes stdout; - // The `stderr` data. - bytes stderr; - } - - /// Information on the chain and fork. - struct ChainInfo { - // The fork identifier. Set to zero if no fork is active. - uint256 forkId; - // The chain ID of the current fork. - uint256 chainId; - } - - /// Information about a blockchain. - struct Chain { - // The chain name. - string name; - // The chain's Chain ID. - uint256 chainId; - // The chain's alias. (i.e. what gets specified in `foundry.toml`). - string chainAlias; - // A default RPC endpoint for this chain. - string rpcUrl; - } - - /// The result of a `stopAndReturnStateDiff` call. - struct AccountAccess { - // The chain and fork the access occurred. - ChainInfo chainInfo; - // The kind of account access that determines what the account is. - // If kind is Call, DelegateCall, StaticCall or CallCode, then the account is the callee. - // If kind is Create, then the account is the newly created account. - // If kind is SelfDestruct, then the account is the selfdestruct recipient. - // If kind is a Resume, then account represents a account context that has resumed. - AccountAccessKind kind; - // The account that was accessed. - // It's either the account created, callee or a selfdestruct recipient for CREATE, CALL or SELFDESTRUCT. - address account; - // What accessed the account. - address accessor; - // If the account was initialized or empty prior to the access. - // An account is considered initialized if it has code, a - // non-zero nonce, or a non-zero balance. - bool initialized; - // The previous balance of the accessed account. - uint256 oldBalance; - // The potential new balance of the accessed account. - // That is, all balance changes are recorded here, even if reverts occurred. - uint256 newBalance; - // Code of the account deployed by CREATE. - bytes deployedCode; - // Value passed along with the account access - uint256 value; - // Input data provided to the CREATE or CALL - bytes data; - // If this access reverted in either the current or parent context. - bool reverted; - // An ordered list of storage accesses made during an account access operation. - StorageAccess[] storageAccesses; - // Call depth traversed during the recording of state differences - uint64 depth; - // The previous nonce of the accessed account. - uint64 oldNonce; - // The new nonce of the accessed account. - uint64 newNonce; - } - - /// The storage accessed during an `AccountAccess`. - struct StorageAccess { - // The account whose storage was accessed. - address account; - // The slot that was accessed. - bytes32 slot; - // If the access was a write. - bool isWrite; - // The previous value of the slot. - bytes32 previousValue; - // The new value of the slot. - bytes32 newValue; - // If the access was reverted. - bool reverted; - } - - /// Gas used. Returned by `lastCallGas`. - struct Gas { - // The gas limit of the call. - uint64 gasLimit; - // The total gas used. - uint64 gasTotalUsed; - // DEPRECATED: The amount of gas used for memory expansion. Ref: - uint64 gasMemoryUsed; - // The amount of gas refunded. - int64 gasRefunded; - // The amount of gas remaining. - uint64 gasRemaining; - } - - /// The result of the `stopDebugTraceRecording` call - struct DebugStep { - // The stack before executing the step of the run. - // stack\[0\] represents the top of the stack. - // and only stack data relevant to the opcode execution is contained. - uint256[] stack; - // The memory input data before executing the step of the run. - // only input data relevant to the opcode execution is contained. - // e.g. for MLOAD, it will have memory\[offset:offset+32\] copied here. - // the offset value can be get by the stack data. - bytes memoryInput; - // The opcode that was accessed. - uint8 opcode; - // The call depth of the step. - uint64 depth; - // Whether the call end up with out of gas error. - bool isOutOfGas; - // The contract address where the opcode is running - address contractAddr; - } - - /// Represents a transaction's broadcast details. - struct BroadcastTxSummary { - // The hash of the transaction that was broadcasted - bytes32 txHash; - // Represent the type of transaction among CALL, CREATE, CREATE2 - BroadcastTxType txType; - // The address of the contract that was called or created. - // This is address of the contract that is created if the txType is CREATE or CREATE2. - address contractAddress; - // The block number the transaction landed in. - uint64 blockNumber; - // Status of the transaction, retrieved from the transaction receipt. - bool success; - } - - /// Holds a signed EIP-7702 authorization for an authority account to delegate to an implementation. - struct SignedDelegation { - // The y-parity of the recovered secp256k1 signature (0 or 1). - uint8 v; - // First 32 bytes of the signature. - bytes32 r; - // Second 32 bytes of the signature. - bytes32 s; - // The current nonce of the authority account at signing time. - // Used to ensure signature can't be replayed after account nonce changes. - uint64 nonce; - // Address of the contract implementation that will be delegated to. - // Gets encoded into delegation code: 0xef0100 || implementation. - address implementation; - } - - /// Represents a "potential" revert reason from a single subsequent call when using `vm.assumeNoReverts`. - /// Reverts that match will result in a FOUNDRY::ASSUME rejection, whereas unmatched reverts will be surfaced - /// as normal. - struct PotentialRevert { - // The allowed origin of the revert opcode; address(0) allows reverts from any address - address reverter; - // When true, only matches on the beginning of the revert data, otherwise, matches on entire revert data - bool partialMatch; - // The data to use to match encountered reverts - bytes revertData; - } - - /// An EIP-2930 access list item. - struct AccessListItem { - // The address to be added in access list. - address target; - // The storage keys to be added in access list. - bytes32[] storageKeys; - } - - // ======== Crypto ======== - - /// Derives a private key from the name, labels the account with that name, and returns the wallet. - function createWallet(string calldata walletLabel) external returns (Wallet memory wallet); - - /// Generates a wallet from the private key and returns the wallet. - function createWallet(uint256 privateKey) external returns (Wallet memory wallet); - - /// Generates a wallet from the private key, labels the account with that name, and returns the wallet. - function createWallet(uint256 privateKey, string calldata walletLabel) external returns (Wallet memory wallet); - - /// Derive a private key from a provided mnemonic string (or mnemonic file path) - /// at the derivation path `m/44'/60'/0'/0/{index}`. - function deriveKey(string calldata mnemonic, uint32 index) external pure returns (uint256 privateKey); - - /// Derive a private key from a provided mnemonic string (or mnemonic file path) - /// at `{derivationPath}{index}`. - function deriveKey(string calldata mnemonic, string calldata derivationPath, uint32 index) - external - pure - returns (uint256 privateKey); - - /// Derive a private key from a provided mnemonic string (or mnemonic file path) in the specified language - /// at the derivation path `m/44'/60'/0'/0/{index}`. - function deriveKey(string calldata mnemonic, uint32 index, string calldata language) - external - pure - returns (uint256 privateKey); - - /// Derive a private key from a provided mnemonic string (or mnemonic file path) in the specified language - /// at `{derivationPath}{index}`. - function deriveKey(string calldata mnemonic, string calldata derivationPath, uint32 index, string calldata language) - external - pure - returns (uint256 privateKey); - - /// Derives secp256r1 public key from the provided `privateKey`. - function publicKeyP256(uint256 privateKey) external pure returns (uint256 publicKeyX, uint256 publicKeyY); - - /// Adds a private key to the local forge wallet and returns the address. - function rememberKey(uint256 privateKey) external returns (address keyAddr); - - /// Derive a set number of wallets from a mnemonic at the derivation path `m/44'/60'/0'/0/{0..count}`. - /// The respective private keys are saved to the local forge wallet for later use and their addresses are returned. - function rememberKeys(string calldata mnemonic, string calldata derivationPath, uint32 count) - external - returns (address[] memory keyAddrs); - - /// Derive a set number of wallets from a mnemonic in the specified language at the derivation path `m/44'/60'/0'/0/{0..count}`. - /// The respective private keys are saved to the local forge wallet for later use and their addresses are returned. - function rememberKeys( - string calldata mnemonic, - string calldata derivationPath, - string calldata language, - uint32 count - ) external returns (address[] memory keyAddrs); - - /// Signs data with a `Wallet`. - /// Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the - /// signature's `s` value, and the recovery id `v` in a single bytes32. - /// This format reduces the signature size from 65 to 64 bytes. - function signCompact(Wallet calldata wallet, bytes32 digest) external returns (bytes32 r, bytes32 vs); - - /// Signs `digest` with `privateKey` using the secp256k1 curve. - /// Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the - /// signature's `s` value, and the recovery id `v` in a single bytes32. - /// This format reduces the signature size from 65 to 64 bytes. - function signCompact(uint256 privateKey, bytes32 digest) external pure returns (bytes32 r, bytes32 vs); - - /// Signs `digest` with signer provided to script using the secp256k1 curve. - /// Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the - /// signature's `s` value, and the recovery id `v` in a single bytes32. - /// This format reduces the signature size from 65 to 64 bytes. - /// If `--sender` is provided, the signer with provided address is used, otherwise, - /// if exactly one signer is provided to the script, that signer is used. - /// Raises error if signer passed through `--sender` does not match any unlocked signers or - /// if `--sender` is not provided and not exactly one signer is passed to the script. - function signCompact(bytes32 digest) external pure returns (bytes32 r, bytes32 vs); - - /// Signs `digest` with signer provided to script using the secp256k1 curve. - /// Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the - /// signature's `s` value, and the recovery id `v` in a single bytes32. - /// This format reduces the signature size from 65 to 64 bytes. - /// Raises error if none of the signers passed into the script have provided address. - function signCompact(address signer, bytes32 digest) external pure returns (bytes32 r, bytes32 vs); - - /// Signs `digest` with `privateKey` using the secp256r1 curve. - function signP256(uint256 privateKey, bytes32 digest) external pure returns (bytes32 r, bytes32 s); - - /// Signs `digest` with `privateKey` on the secp256k1 curve, using the given `nonce` - /// as the raw ephemeral k value in ECDSA (instead of deriving it deterministically). - function signWithNonceUnsafe(uint256 privateKey, bytes32 digest, uint256 nonce) - external - pure - returns (uint8 v, bytes32 r, bytes32 s); - - /// Signs data with a `Wallet`. - function sign(Wallet calldata wallet, bytes32 digest) external returns (uint8 v, bytes32 r, bytes32 s); - - /// Signs `digest` with `privateKey` using the secp256k1 curve. - function sign(uint256 privateKey, bytes32 digest) external pure returns (uint8 v, bytes32 r, bytes32 s); - - /// Signs `digest` with signer provided to script using the secp256k1 curve. - /// If `--sender` is provided, the signer with provided address is used, otherwise, - /// if exactly one signer is provided to the script, that signer is used. - /// Raises error if signer passed through `--sender` does not match any unlocked signers or - /// if `--sender` is not provided and not exactly one signer is passed to the script. - function sign(bytes32 digest) external pure returns (uint8 v, bytes32 r, bytes32 s); - - /// Signs `digest` with signer provided to script using the secp256k1 curve. - /// Raises error if none of the signers passed into the script have provided address. - function sign(address signer, bytes32 digest) external pure returns (uint8 v, bytes32 r, bytes32 s); - - // ======== Environment ======== - - /// Gets the environment variable `name` and parses it as `address`. - /// Reverts if the variable was not found or could not be parsed. - function envAddress(string calldata name) external view returns (address value); - - /// Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envAddress(string calldata name, string calldata delim) external view returns (address[] memory value); - - /// Gets the environment variable `name` and parses it as `bool`. - /// Reverts if the variable was not found or could not be parsed. - function envBool(string calldata name) external view returns (bool value); - - /// Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envBool(string calldata name, string calldata delim) external view returns (bool[] memory value); - - /// Gets the environment variable `name` and parses it as `bytes32`. - /// Reverts if the variable was not found or could not be parsed. - function envBytes32(string calldata name) external view returns (bytes32 value); - - /// Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envBytes32(string calldata name, string calldata delim) external view returns (bytes32[] memory value); - - /// Gets the environment variable `name` and parses it as `bytes`. - /// Reverts if the variable was not found or could not be parsed. - function envBytes(string calldata name) external view returns (bytes memory value); - - /// Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envBytes(string calldata name, string calldata delim) external view returns (bytes[] memory value); - - /// Gets the environment variable `name` and returns true if it exists, else returns false. - function envExists(string calldata name) external view returns (bool result); - - /// Gets the environment variable `name` and parses it as `int256`. - /// Reverts if the variable was not found or could not be parsed. - function envInt(string calldata name) external view returns (int256 value); - - /// Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envInt(string calldata name, string calldata delim) external view returns (int256[] memory value); - - /// Gets the environment variable `name` and parses it as `bool`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, bool defaultValue) external view returns (bool value); - - /// Gets the environment variable `name` and parses it as `uint256`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, uint256 defaultValue) external view returns (uint256 value); - - /// Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, address[] calldata defaultValue) - external - view - returns (address[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, bytes32[] calldata defaultValue) - external - view - returns (bytes32[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, string[] calldata defaultValue) - external - view - returns (string[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, bytes[] calldata defaultValue) - external - view - returns (bytes[] memory value); - - /// Gets the environment variable `name` and parses it as `int256`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, int256 defaultValue) external view returns (int256 value); - - /// Gets the environment variable `name` and parses it as `address`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, address defaultValue) external view returns (address value); - - /// Gets the environment variable `name` and parses it as `bytes32`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, bytes32 defaultValue) external view returns (bytes32 value); - - /// Gets the environment variable `name` and parses it as `string`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata defaultValue) external view returns (string memory value); - - /// Gets the environment variable `name` and parses it as `bytes`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, bytes calldata defaultValue) external view returns (bytes memory value); - - /// Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, bool[] calldata defaultValue) - external - view - returns (bool[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, uint256[] calldata defaultValue) - external - view - returns (uint256[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, int256[] calldata defaultValue) - external - view - returns (int256[] memory value); - - /// Gets the environment variable `name` and parses it as `string`. - /// Reverts if the variable was not found or could not be parsed. - function envString(string calldata name) external view returns (string memory value); - - /// Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envString(string calldata name, string calldata delim) external view returns (string[] memory value); - - /// Gets the environment variable `name` and parses it as `uint256`. - /// Reverts if the variable was not found or could not be parsed. - function envUint(string calldata name) external view returns (uint256 value); - - /// Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envUint(string calldata name, string calldata delim) external view returns (uint256[] memory value); - - /// Returns true if `forge` command was executed in given context. - function isContext(ForgeContext context) external view returns (bool result); - - /// Resolves the env variable placeholders of a given input string. - function resolveEnv(string calldata input) external returns (string memory); - - /// Sets environment variables. - function setEnv(string calldata name, string calldata value) external; - - // ======== EVM ======== - - /// Gets all accessed reads and write slot from a `vm.record` session, for a given address. - function accesses(address target) external view returns (bytes32[] memory readSlots, bytes32[] memory writeSlots); - - /// Gets the address for a given private key. - function addr(uint256 privateKey) external pure returns (address keyAddr); - - /// Gets all the logs according to specified filter. - function eth_getLogs(uint256 fromBlock, uint256 toBlock, address target, bytes32[] calldata topics) - external - view - returns (EthGetLogs[] memory logs); - - /// Gets the current `block.blobbasefee`. - /// You should use this instead of `block.blobbasefee` if you use `vm.blobBaseFee`, as `block.blobbasefee` is assumed to be constant across a transaction, - /// and as a result will get optimized out by the compiler. - /// See https://github.com/foundry-rs/foundry/issues/6180 - function getBlobBaseFee() external view returns (uint256 blobBaseFee); - - /// Gets the current `block.number`. - /// You should use this instead of `block.number` if you use `vm.roll`, as `block.number` is assumed to be constant across a transaction, - /// and as a result will get optimized out by the compiler. - /// See https://github.com/foundry-rs/foundry/issues/6180 - function getBlockNumber() external view returns (uint256 height); - - /// Gets the current `block.timestamp`. - /// You should use this instead of `block.timestamp` if you use `vm.warp`, as `block.timestamp` is assumed to be constant across a transaction, - /// and as a result will get optimized out by the compiler. - /// See https://github.com/foundry-rs/foundry/issues/6180 - function getBlockTimestamp() external view returns (uint256 timestamp); - - /// Gets the current `block.chainid` of the currently selected environment. - /// You should use this instead of `block.chainid` if you use `vm.selectFork` or `vm.createSelectFork`, as `block.chainid` could be assumed - /// to be constant across a transaction, and as a result will get optimized out by the compiler. - /// See https://github.com/foundry-rs/foundry/issues/6180 - function getChainId() external view returns (uint256 blockChainId); - - /// Returns the test or script execution evm version. - /// **Note:** The execution evm version is not the same as the compilation one. - function getEvmVersion() external pure returns (string memory evm); - - /// Gets the map key and parent of a mapping at a given slot, for a given address. - function getMappingKeyAndParentOf(address target, bytes32 elementSlot) - external - view - returns (bool found, bytes32 key, bytes32 parent); - - /// Gets the number of elements in the mapping at the given slot, for a given address. - function getMappingLength(address target, bytes32 mappingSlot) external view returns (uint256 length); - - /// Gets the elements at index idx of the mapping at the given slot, for a given address. The - /// index must be less than the length of the mapping (i.e. the number of keys in the mapping). - function getMappingSlotAt(address target, bytes32 mappingSlot, uint256 idx) external view returns (bytes32 value); - - /// Gets the nonce of an account. - function getNonce(address account) external view returns (uint64 nonce); - - /// Get the nonce of a `Wallet`. - function getNonce(Wallet calldata wallet) external view returns (uint64 nonce); - - /// Gets the RLP encoded block header for a given block number. - /// Returns the block header in the same format as `cast block --raw`. - function getRawBlockHeader(uint256 blockNumber) external view returns (bytes memory rlpHeader); - - /// Gets all the recorded logs. - function getRecordedLogs() external view returns (Log[] memory logs); - - /// Returns state diffs from current `vm.startStateDiffRecording` session. - function getStateDiff() external view returns (string memory diff); - - /// Returns state diffs from current `vm.startStateDiffRecording` session, in json format. - function getStateDiffJson() external view returns (string memory diff); - - /// Returns an array of `StorageAccess` from current `vm.stateStateDiffRecording` session - function getStorageAccesses() external view returns (StorageAccess[] memory storageAccesses); - - /// Returns an array of storage slots occupied by the specified variable. - function getStorageSlots(address target, string calldata variableName) - external - view - returns (uint256[] memory slots); - - /// Gets the gas used in the last call from the callee perspective. - function lastCallGas() external view returns (Gas memory gas); - - /// Loads a storage slot from an address. - function load(address target, bytes32 slot) external view returns (bytes32 data); - - /// Pauses gas metering (i.e. gas usage is not counted). Noop if already paused. - function pauseGasMetering() external; - - /// Records all storage reads and writes. Use `accesses` to get the recorded data. - /// Subsequent calls to `record` will clear the previous data. - function record() external; - - /// Record all the transaction logs. - function recordLogs() external; - - /// Reset gas metering (i.e. gas usage is set to gas limit). - function resetGasMetering() external; - - /// Resumes gas metering (i.e. gas usage is counted again). Noop if already on. - function resumeGasMetering() external; - - /// Performs an Ethereum JSON-RPC request to the current fork URL. - function rpc(string calldata method, string calldata params) external returns (bytes memory data); - - /// Performs an Ethereum JSON-RPC request to the given endpoint. - function rpc(string calldata urlOrAlias, string calldata method, string calldata params) - external - returns (bytes memory data); - - /// Set the exact test or script execution evm version, e.g. `berlin`, `cancun`. - /// **Note:** The execution evm version is not the same as the compilation one. - function setEvmVersion(string calldata evm) external; - - /// Records the debug trace during the run. - function startDebugTraceRecording() external; - - /// Starts recording all map SSTOREs for later retrieval. - function startMappingRecording() external; - - /// Record all account accesses as part of CREATE, CALL or SELFDESTRUCT opcodes in order, - /// along with the context of the calls - function startStateDiffRecording() external; - - /// Stop debug trace recording and returns the recorded debug trace. - function stopAndReturnDebugTraceRecording() external returns (DebugStep[] memory step); - - /// Returns an ordered array of all account accesses from a `vm.startStateDiffRecording` session. - function stopAndReturnStateDiff() external returns (AccountAccess[] memory accountAccesses); - - /// Stops recording all map SSTOREs for later retrieval and clears the recorded data. - function stopMappingRecording() external; - - /// Stops recording storage reads and writes. - function stopRecord() external; - - // ======== Filesystem ======== - - /// Closes file for reading, resetting the offset and allowing to read it from beginning with readLine. - /// `path` is relative to the project root. - function closeFile(string calldata path) external; - - /// Copies the contents of one file to another. This function will **overwrite** the contents of `to`. - /// On success, the total number of bytes copied is returned and it is equal to the length of the `to` file as reported by `metadata`. - /// Both `from` and `to` are relative to the project root. - function copyFile(string calldata from, string calldata to) external returns (uint64 copied); - - /// Creates a new, empty directory at the provided path. - /// This cheatcode will revert in the following situations, but is not limited to just these cases: - /// - User lacks permissions to modify `path`. - /// - A parent of the given path doesn't exist and `recursive` is false. - /// - `path` already exists and `recursive` is false. - /// `path` is relative to the project root. - function createDir(string calldata path, bool recursive) external; - - /// Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Reverts if the target artifact contains unlinked library placeholders. - function deployCode(string calldata artifactPath) external returns (address deployedAddress); - - /// Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Reverts if the target artifact contains unlinked library placeholders. - /// Additionally accepts abi-encoded constructor arguments. - function deployCode(string calldata artifactPath, bytes calldata constructorArgs) - external - returns (address deployedAddress); - - /// Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Reverts if the target artifact contains unlinked library placeholders. - /// Additionally accepts `msg.value`. - function deployCode(string calldata artifactPath, uint256 value) external returns (address deployedAddress); - - /// Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Reverts if the target artifact contains unlinked library placeholders. - /// Additionally accepts abi-encoded constructor arguments and `msg.value`. - function deployCode(string calldata artifactPath, bytes calldata constructorArgs, uint256 value) - external - returns (address deployedAddress); - - /// Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Reverts if the target artifact contains unlinked library placeholders. - function deployCode(string calldata artifactPath, bytes32 salt) external returns (address deployedAddress); - - /// Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Reverts if the target artifact contains unlinked library placeholders. - /// Additionally accepts abi-encoded constructor arguments. - function deployCode(string calldata artifactPath, bytes calldata constructorArgs, bytes32 salt) - external - returns (address deployedAddress); - - /// Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Reverts if the target artifact contains unlinked library placeholders. - /// Additionally accepts `msg.value`. - function deployCode(string calldata artifactPath, uint256 value, bytes32 salt) - external - returns (address deployedAddress); - - /// Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Reverts if the target artifact contains unlinked library placeholders. - /// Additionally accepts abi-encoded constructor arguments and `msg.value`. - function deployCode(string calldata artifactPath, bytes calldata constructorArgs, uint256 value, bytes32 salt) - external - returns (address deployedAddress); - - /// Returns true if the given path points to an existing entity, else returns false. - function exists(string calldata path) external view returns (bool result); - - /// Performs a foreign function call via the terminal. - function ffi(string[] calldata commandInput) external returns (bytes memory result); - - /// Given a path, query the file system to get information about a file, directory, etc. - function fsMetadata(string calldata path) external view returns (FsMetadata memory metadata); - - /// Gets the artifact path from code (aka. creation code). - function getArtifactPathByCode(bytes calldata code) external view returns (string memory path); - - /// Gets the artifact path from deployed code (aka. runtime code). - function getArtifactPathByDeployedCode(bytes calldata deployedCode) external view returns (string memory path); - - /// Returns the most recent broadcast for the given contract on `chainId` matching `txType`. - /// For example: - /// The most recent deployment can be fetched by passing `txType` as `CREATE` or `CREATE2`. - /// The most recent call can be fetched by passing `txType` as `CALL`. - function getBroadcast(string calldata contractName, uint64 chainId, BroadcastTxType txType) - external - view - returns (BroadcastTxSummary memory); - - /// Returns all broadcasts for the given contract on `chainId` with the specified `txType`. - /// Sorted such that the most recent broadcast is the first element, and the oldest is the last. i.e descending order of BroadcastTxSummary.blockNumber. - function getBroadcasts(string calldata contractName, uint64 chainId, BroadcastTxType txType) - external - view - returns (BroadcastTxSummary[] memory); - - /// Returns all broadcasts for the given contract on `chainId`. - /// Sorted such that the most recent broadcast is the first element, and the oldest is the last. i.e descending order of BroadcastTxSummary.blockNumber. - function getBroadcasts(string calldata contractName, uint64 chainId) - external - view - returns (BroadcastTxSummary[] memory); - - /// Gets the creation bytecode from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - function getCode(string calldata artifactPath) external view returns (bytes memory creationBytecode); - - /// Gets the deployed bytecode from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - function getDeployedCode(string calldata artifactPath) external view returns (bytes memory runtimeBytecode); - - /// Returns the most recent deployment for the current `chainId`. - function getDeployment(string calldata contractName) external view returns (address deployedAddress); - - /// Returns the most recent deployment for the given contract on `chainId` - function getDeployment(string calldata contractName, uint64 chainId) external view returns (address deployedAddress); - - /// Returns all deployments for the given contract on `chainId` - /// Sorted in descending order of deployment time i.e descending order of BroadcastTxSummary.blockNumber. - /// The most recent deployment is the first element, and the oldest is the last. - function getDeployments(string calldata contractName, uint64 chainId) - external - view - returns (address[] memory deployedAddresses); - - /// Returns true if the path exists on disk and is pointing at a directory, else returns false. - function isDir(string calldata path) external view returns (bool result); - - /// Returns true if the path exists on disk and is pointing at a regular file, else returns false. - function isFile(string calldata path) external view returns (bool result); - - /// Get the path of the current project root. - function projectRoot() external view returns (string memory path); - - /// Prompts the user for a string value in the terminal. - function prompt(string calldata promptText) external returns (string memory input); - - /// Prompts the user for an address in the terminal. - function promptAddress(string calldata promptText) external returns (address); - - /// Prompts the user for a hidden string value in the terminal. - function promptSecret(string calldata promptText) external returns (string memory input); - - /// Prompts the user for hidden uint256 in the terminal (usually pk). - function promptSecretUint(string calldata promptText) external returns (uint256); - - /// Prompts the user for uint256 in the terminal. - function promptUint(string calldata promptText) external returns (uint256); - - /// Reads the directory at the given path recursively, up to `maxDepth`. - /// `maxDepth` defaults to 1, meaning only the direct children of the given directory will be returned. - /// Follows symbolic links if `followLinks` is true. - function readDir(string calldata path) external view returns (DirEntry[] memory entries); - - /// See `readDir(string)`. - function readDir(string calldata path, uint64 maxDepth) external view returns (DirEntry[] memory entries); - - /// See `readDir(string)`. - function readDir(string calldata path, uint64 maxDepth, bool followLinks) - external - view - returns (DirEntry[] memory entries); - - /// Reads the entire content of file to string. `path` is relative to the project root. - function readFile(string calldata path) external view returns (string memory data); - - /// Reads the entire content of file as binary. `path` is relative to the project root. - function readFileBinary(string calldata path) external view returns (bytes memory data); - - /// Reads next line of file to string. - function readLine(string calldata path) external view returns (string memory line); - - /// Reads a symbolic link, returning the path that the link points to. - /// This cheatcode will revert in the following situations, but is not limited to just these cases: - /// - `path` is not a symbolic link. - /// - `path` does not exist. - function readLink(string calldata linkPath) external view returns (string memory targetPath); - - /// Removes a directory at the provided path. - /// This cheatcode will revert in the following situations, but is not limited to just these cases: - /// - `path` doesn't exist. - /// - `path` isn't a directory. - /// - User lacks permissions to modify `path`. - /// - The directory is not empty and `recursive` is false. - /// `path` is relative to the project root. - function removeDir(string calldata path, bool recursive) external; - - /// Removes a file from the filesystem. - /// This cheatcode will revert in the following situations, but is not limited to just these cases: - /// - `path` points to a directory. - /// - The file doesn't exist. - /// - The user lacks permissions to remove the file. - /// `path` is relative to the project root. - function removeFile(string calldata path) external; - - /// Performs a foreign function call via terminal and returns the exit code, stdout, and stderr. - function tryFfi(string[] calldata commandInput) external returns (FfiResult memory result); - - /// Returns the time since unix epoch in milliseconds. - function unixTime() external view returns (uint256 milliseconds); - - /// Writes data to file, creating a file if it does not exist, and entirely replacing its contents if it does. - /// `path` is relative to the project root. - function writeFile(string calldata path, string calldata data) external; - - /// Writes binary data to a file, creating a file if it does not exist, and entirely replacing its contents if it does. - /// `path` is relative to the project root. - function writeFileBinary(string calldata path, bytes calldata data) external; - - /// Writes line to file, creating a file if it does not exist. - /// `path` is relative to the project root. - function writeLine(string calldata path, string calldata data) external; - - // ======== JSON ======== - - /// Checks if `key` exists in a JSON object. - function keyExistsJson(string calldata json, string calldata key) external view returns (bool); - - /// Parses a string of JSON data at `key` and coerces it to `address`. - function parseJsonAddress(string calldata json, string calldata key) external pure returns (address); - - /// Parses a string of JSON data at `key` and coerces it to `address[]`. - function parseJsonAddressArray(string calldata json, string calldata key) external pure returns (address[] memory); - - /// Parses a string of JSON data at `key` and coerces it to `bool`. - function parseJsonBool(string calldata json, string calldata key) external pure returns (bool); - - /// Parses a string of JSON data at `key` and coerces it to `bool[]`. - function parseJsonBoolArray(string calldata json, string calldata key) external pure returns (bool[] memory); - - /// Parses a string of JSON data at `key` and coerces it to `bytes`. - function parseJsonBytes(string calldata json, string calldata key) external pure returns (bytes memory); - - /// Parses a string of JSON data at `key` and coerces it to `bytes32`. - function parseJsonBytes32(string calldata json, string calldata key) external pure returns (bytes32); - - /// Parses a string of JSON data at `key` and coerces it to `bytes32[]`. - function parseJsonBytes32Array(string calldata json, string calldata key) external pure returns (bytes32[] memory); - - /// Parses a string of JSON data at `key` and coerces it to `bytes[]`. - function parseJsonBytesArray(string calldata json, string calldata key) external pure returns (bytes[] memory); - - /// Parses a string of JSON data at `key` and coerces it to `int256`. - function parseJsonInt(string calldata json, string calldata key) external pure returns (int256); - - /// Parses a string of JSON data at `key` and coerces it to `int256[]`. - function parseJsonIntArray(string calldata json, string calldata key) external pure returns (int256[] memory); - - /// Returns an array of all the keys in a JSON object. - function parseJsonKeys(string calldata json, string calldata key) external pure returns (string[] memory keys); - - /// Parses a string of JSON data at `key` and coerces it to `string`. - function parseJsonString(string calldata json, string calldata key) external pure returns (string memory); - - /// Parses a string of JSON data at `key` and coerces it to `string[]`. - function parseJsonStringArray(string calldata json, string calldata key) external pure returns (string[] memory); - - /// Parses a string of JSON data at `key` and coerces it to type array corresponding to `typeDescription`. - function parseJsonTypeArray(string calldata json, string calldata key, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of JSON data and coerces it to type corresponding to `typeDescription`. - function parseJsonType(string calldata json, string calldata typeDescription) external pure returns (bytes memory); - - /// Parses a string of JSON data at `key` and coerces it to type corresponding to `typeDescription`. - function parseJsonType(string calldata json, string calldata key, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of JSON data at `key` and coerces it to `uint256`. - function parseJsonUint(string calldata json, string calldata key) external pure returns (uint256); - - /// Parses a string of JSON data at `key` and coerces it to `uint256[]`. - function parseJsonUintArray(string calldata json, string calldata key) external pure returns (uint256[] memory); - - /// ABI-encodes a JSON object. - function parseJson(string calldata json) external pure returns (bytes memory abiEncodedData); - - /// ABI-encodes a JSON object at `key`. - function parseJson(string calldata json, string calldata key) external pure returns (bytes memory abiEncodedData); - - /// See `serializeJson`. - function serializeAddress(string calldata objectKey, string calldata valueKey, address value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeAddress(string calldata objectKey, string calldata valueKey, address[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBool(string calldata objectKey, string calldata valueKey, bool value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBool(string calldata objectKey, string calldata valueKey, bool[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBytes32(string calldata objectKey, string calldata valueKey, bytes32 value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBytes32(string calldata objectKey, string calldata valueKey, bytes32[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBytes(string calldata objectKey, string calldata valueKey, bytes calldata value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBytes(string calldata objectKey, string calldata valueKey, bytes[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeInt(string calldata objectKey, string calldata valueKey, int256 value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeInt(string calldata objectKey, string calldata valueKey, int256[] calldata values) - external - returns (string memory json); - - /// Serializes a key and value to a JSON object stored in-memory that can be later written to a file. - /// Returns the stringified version of the specific JSON file up to that moment. - function serializeJson(string calldata objectKey, string calldata value) external returns (string memory json); - - /// See `serializeJson`. - function serializeJsonType(string calldata typeDescription, bytes calldata value) - external - pure - returns (string memory json); - - /// See `serializeJson`. - function serializeJsonType( - string calldata objectKey, - string calldata valueKey, - string calldata typeDescription, - bytes calldata value - ) external returns (string memory json); - - /// See `serializeJson`. - function serializeString(string calldata objectKey, string calldata valueKey, string calldata value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeString(string calldata objectKey, string calldata valueKey, string[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeUintToHex(string calldata objectKey, string calldata valueKey, uint256 value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeUint(string calldata objectKey, string calldata valueKey, uint256 value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeUint(string calldata objectKey, string calldata valueKey, uint256[] calldata values) - external - returns (string memory json); - - /// Write a serialized JSON object to a file. If the file exists, it will be overwritten. - function writeJson(string calldata json, string calldata path) external; - - /// Write a serialized JSON object to an **existing** JSON file, replacing a value with key = - /// This is useful to replace a specific value of a JSON file, without having to parse the entire thing. - /// This cheatcode will create new keys if they didn't previously exist. - function writeJson(string calldata json, string calldata path, string calldata valueKey) external; - - /// Checks if `key` exists in a JSON object - /// `keyExists` is being deprecated in favor of `keyExistsJson`. It will be removed in future versions. - function keyExists(string calldata json, string calldata key) external view returns (bool); - - // ======== Scripting ======== - - /// Attach an EIP-4844 blob to the next call - function attachBlob(bytes calldata blob) external; - - /// Designate the next call as an EIP-7702 transaction - function attachDelegation(SignedDelegation calldata signedDelegation) external; - - /// Designate the next call as an EIP-7702 transaction, with optional cross-chain validity. - function attachDelegation(SignedDelegation calldata signedDelegation, bool crossChain) external; - - /// Takes a signed transaction and broadcasts it to the network. - function broadcastRawTransaction(bytes calldata data) external; - - /// Has the next call (at this call depth only) create transactions that can later be signed and sent onchain. - /// Broadcasting address is determined by checking the following in order: - /// 1. If `--sender` argument was provided, that address is used. - /// 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. - /// 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used. - function broadcast() external; - - /// Has the next call (at this call depth only) create a transaction with the address provided - /// as the sender that can later be signed and sent onchain. - function broadcast(address signer) external; - - /// Has the next call (at this call depth only) create a transaction with the private key - /// provided as the sender that can later be signed and sent onchain. - function broadcast(uint256 privateKey) external; - - /// Returns addresses of available unlocked wallets in the script environment. - function getWallets() external view returns (address[] memory wallets); - - /// Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction - function signAndAttachDelegation(address implementation, uint256 privateKey) - external - returns (SignedDelegation memory signedDelegation); - - /// Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction for specific nonce - function signAndAttachDelegation(address implementation, uint256 privateKey, uint64 nonce) - external - returns (SignedDelegation memory signedDelegation); - - /// Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction, with optional cross-chain validity. - function signAndAttachDelegation(address implementation, uint256 privateKey, bool crossChain) - external - returns (SignedDelegation memory signedDelegation); - - /// Sign an EIP-7702 authorization for delegation - function signDelegation(address implementation, uint256 privateKey) - external - returns (SignedDelegation memory signedDelegation); - - /// Sign an EIP-7702 authorization for delegation for specific nonce - function signDelegation(address implementation, uint256 privateKey, uint64 nonce) - external - returns (SignedDelegation memory signedDelegation); - - /// Sign an EIP-7702 authorization for delegation, with optional cross-chain validity. - function signDelegation(address implementation, uint256 privateKey, bool crossChain) - external - returns (SignedDelegation memory signedDelegation); - - /// Has all subsequent calls (at this call depth only) create transactions that can later be signed and sent onchain. - /// Broadcasting address is determined by checking the following in order: - /// 1. If `--sender` argument was provided, that address is used. - /// 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. - /// 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used. - function startBroadcast() external; - - /// Has all subsequent calls (at this call depth only) create transactions with the address - /// provided that can later be signed and sent onchain. - function startBroadcast(address signer) external; - - /// Has all subsequent calls (at this call depth only) create transactions with the private key - /// provided that can later be signed and sent onchain. - function startBroadcast(uint256 privateKey) external; - - /// Stops collecting onchain transactions. - function stopBroadcast() external; - - // ======== String ======== - - /// Returns true if `search` is found in `subject`, false otherwise. - function contains(string calldata subject, string calldata search) external pure returns (bool result); - - /// Returns the index of the first occurrence of a `key` in an `input` string. - /// Returns `NOT_FOUND` (i.e. `type(uint256).max`) if the `key` is not found. - /// Returns 0 in case of an empty `key`. - function indexOf(string calldata input, string calldata key) external pure returns (uint256); - - /// Parses the given `string` into an `address`. - function parseAddress(string calldata stringifiedValue) external pure returns (address parsedValue); - - /// Parses the given `string` into a `bool`. - function parseBool(string calldata stringifiedValue) external pure returns (bool parsedValue); - - /// Parses the given `string` into `bytes`. - function parseBytes(string calldata stringifiedValue) external pure returns (bytes memory parsedValue); - - /// Parses the given `string` into a `bytes32`. - function parseBytes32(string calldata stringifiedValue) external pure returns (bytes32 parsedValue); - - /// Parses the given `string` into a `int256`. - function parseInt(string calldata stringifiedValue) external pure returns (int256 parsedValue); - - /// Parses the given `string` into a `uint256`. - function parseUint(string calldata stringifiedValue) external pure returns (uint256 parsedValue); - - /// Replaces occurrences of `from` in the given `string` with `to`. - function replace(string calldata input, string calldata from, string calldata to) - external - pure - returns (string memory output); - - /// Splits the given `string` into an array of strings divided by the `delimiter`. - function split(string calldata input, string calldata delimiter) external pure returns (string[] memory outputs); - - /// Converts the given `string` value to Lowercase. - function toLowercase(string calldata input) external pure returns (string memory output); - - /// Converts the given value to a `string`. - function toString(address value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(bytes calldata value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(bytes32 value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(bool value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(uint256 value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(int256 value) external pure returns (string memory stringifiedValue); - - /// Converts the given `string` value to Uppercase. - function toUppercase(string calldata input) external pure returns (string memory output); - - /// Trims leading and trailing whitespace from the given `string` value. - function trim(string calldata input) external pure returns (string memory output); - - // ======== Testing ======== - - /// Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. - /// Formats values with decimals in failure message. - function assertApproxEqAbsDecimal(uint256 left, uint256 right, uint256 maxDelta, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertApproxEqAbsDecimal( - uint256 left, - uint256 right, - uint256 maxDelta, - uint256 decimals, - string calldata error - ) external pure; - - /// Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. - /// Formats values with decimals in failure message. - function assertApproxEqAbsDecimal(int256 left, int256 right, uint256 maxDelta, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertApproxEqAbsDecimal( - int256 left, - int256 right, - uint256 maxDelta, - uint256 decimals, - string calldata error - ) external pure; - - /// Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. - function assertApproxEqAbs(uint256 left, uint256 right, uint256 maxDelta) external pure; - - /// Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. - /// Includes error message into revert string on failure. - function assertApproxEqAbs(uint256 left, uint256 right, uint256 maxDelta, string calldata error) external pure; - - /// Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. - function assertApproxEqAbs(int256 left, int256 right, uint256 maxDelta) external pure; - - /// Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. - /// Includes error message into revert string on failure. - function assertApproxEqAbs(int256 left, int256 right, uint256 maxDelta, string calldata error) external pure; - - /// Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Formats values with decimals in failure message. - function assertApproxEqRelDecimal(uint256 left, uint256 right, uint256 maxPercentDelta, uint256 decimals) - external - pure; - - /// Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertApproxEqRelDecimal( - uint256 left, - uint256 right, - uint256 maxPercentDelta, - uint256 decimals, - string calldata error - ) external pure; - - /// Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Formats values with decimals in failure message. - function assertApproxEqRelDecimal(int256 left, int256 right, uint256 maxPercentDelta, uint256 decimals) - external - pure; - - /// Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertApproxEqRelDecimal( - int256 left, - int256 right, - uint256 maxPercentDelta, - uint256 decimals, - string calldata error - ) external pure; - - /// Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - function assertApproxEqRel(uint256 left, uint256 right, uint256 maxPercentDelta) external pure; - - /// Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Includes error message into revert string on failure. - function assertApproxEqRel(uint256 left, uint256 right, uint256 maxPercentDelta, string calldata error) - external - pure; - - /// Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - function assertApproxEqRel(int256 left, int256 right, uint256 maxPercentDelta) external pure; - - /// Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Includes error message into revert string on failure. - function assertApproxEqRel(int256 left, int256 right, uint256 maxPercentDelta, string calldata error) external pure; - - /// Asserts that two `uint256` values are equal, formatting them with decimals in failure message. - function assertEqDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Asserts that two `uint256` values are equal, formatting them with decimals in failure message. - /// Includes error message into revert string on failure. - function assertEqDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Asserts that two `int256` values are equal, formatting them with decimals in failure message. - function assertEqDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Asserts that two `int256` values are equal, formatting them with decimals in failure message. - /// Includes error message into revert string on failure. - function assertEqDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Asserts that two `bool` values are equal. - function assertEq(bool left, bool right) external pure; - - /// Asserts that two `bool` values are equal and includes error message into revert string on failure. - function assertEq(bool left, bool right, string calldata error) external pure; - - /// Asserts that two `string` values are equal. - function assertEq(string calldata left, string calldata right) external pure; - - /// Asserts that two `string` values are equal and includes error message into revert string on failure. - function assertEq(string calldata left, string calldata right, string calldata error) external pure; - - /// Asserts that two `bytes` values are equal. - function assertEq(bytes calldata left, bytes calldata right) external pure; - - /// Asserts that two `bytes` values are equal and includes error message into revert string on failure. - function assertEq(bytes calldata left, bytes calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bool` values are equal. - function assertEq(bool[] calldata left, bool[] calldata right) external pure; - - /// Asserts that two arrays of `bool` values are equal and includes error message into revert string on failure. - function assertEq(bool[] calldata left, bool[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `uint256 values are equal. - function assertEq(uint256[] calldata left, uint256[] calldata right) external pure; - - /// Asserts that two arrays of `uint256` values are equal and includes error message into revert string on failure. - function assertEq(uint256[] calldata left, uint256[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `int256` values are equal. - function assertEq(int256[] calldata left, int256[] calldata right) external pure; - - /// Asserts that two arrays of `int256` values are equal and includes error message into revert string on failure. - function assertEq(int256[] calldata left, int256[] calldata right, string calldata error) external pure; - - /// Asserts that two `uint256` values are equal. - function assertEq(uint256 left, uint256 right) external pure; - - /// Asserts that two arrays of `address` values are equal. - function assertEq(address[] calldata left, address[] calldata right) external pure; - - /// Asserts that two arrays of `address` values are equal and includes error message into revert string on failure. - function assertEq(address[] calldata left, address[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bytes32` values are equal. - function assertEq(bytes32[] calldata left, bytes32[] calldata right) external pure; - - /// Asserts that two arrays of `bytes32` values are equal and includes error message into revert string on failure. - function assertEq(bytes32[] calldata left, bytes32[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `string` values are equal. - function assertEq(string[] calldata left, string[] calldata right) external pure; - - /// Asserts that two arrays of `string` values are equal and includes error message into revert string on failure. - function assertEq(string[] calldata left, string[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bytes` values are equal. - function assertEq(bytes[] calldata left, bytes[] calldata right) external pure; - - /// Asserts that two arrays of `bytes` values are equal and includes error message into revert string on failure. - function assertEq(bytes[] calldata left, bytes[] calldata right, string calldata error) external pure; - - /// Asserts that two `uint256` values are equal and includes error message into revert string on failure. - function assertEq(uint256 left, uint256 right, string calldata error) external pure; - - /// Asserts that two `int256` values are equal. - function assertEq(int256 left, int256 right) external pure; - - /// Asserts that two `int256` values are equal and includes error message into revert string on failure. - function assertEq(int256 left, int256 right, string calldata error) external pure; - - /// Asserts that two `address` values are equal. - function assertEq(address left, address right) external pure; - - /// Asserts that two `address` values are equal and includes error message into revert string on failure. - function assertEq(address left, address right, string calldata error) external pure; - - /// Asserts that two `bytes32` values are equal. - function assertEq(bytes32 left, bytes32 right) external pure; - - /// Asserts that two `bytes32` values are equal and includes error message into revert string on failure. - function assertEq(bytes32 left, bytes32 right, string calldata error) external pure; - - /// Asserts that the given condition is false. - function assertFalse(bool condition) external pure; - - /// Asserts that the given condition is false and includes error message into revert string on failure. - function assertFalse(bool condition, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than or equal to second. - /// Formats values with decimals in failure message. - function assertGeDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than or equal to second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertGeDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be greater than or equal to second. - /// Formats values with decimals in failure message. - function assertGeDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects first value to be greater than or equal to second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertGeDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than or equal to second. - function assertGe(uint256 left, uint256 right) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than or equal to second. - /// Includes error message into revert string on failure. - function assertGe(uint256 left, uint256 right, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be greater than or equal to second. - function assertGe(int256 left, int256 right) external pure; - - /// Compares two `int256` values. Expects first value to be greater than or equal to second. - /// Includes error message into revert string on failure. - function assertGe(int256 left, int256 right, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than second. - /// Formats values with decimals in failure message. - function assertGtDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertGtDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be greater than second. - /// Formats values with decimals in failure message. - function assertGtDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects first value to be greater than second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertGtDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than second. - function assertGt(uint256 left, uint256 right) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than second. - /// Includes error message into revert string on failure. - function assertGt(uint256 left, uint256 right, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be greater than second. - function assertGt(int256 left, int256 right) external pure; - - /// Compares two `int256` values. Expects first value to be greater than second. - /// Includes error message into revert string on failure. - function assertGt(int256 left, int256 right, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be less than or equal to second. - /// Formats values with decimals in failure message. - function assertLeDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects first value to be less than or equal to second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertLeDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be less than or equal to second. - /// Formats values with decimals in failure message. - function assertLeDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects first value to be less than or equal to second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertLeDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be less than or equal to second. - function assertLe(uint256 left, uint256 right) external pure; - - /// Compares two `uint256` values. Expects first value to be less than or equal to second. - /// Includes error message into revert string on failure. - function assertLe(uint256 left, uint256 right, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be less than or equal to second. - function assertLe(int256 left, int256 right) external pure; - - /// Compares two `int256` values. Expects first value to be less than or equal to second. - /// Includes error message into revert string on failure. - function assertLe(int256 left, int256 right, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be less than second. - /// Formats values with decimals in failure message. - function assertLtDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects first value to be less than second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertLtDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be less than second. - /// Formats values with decimals in failure message. - function assertLtDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects first value to be less than second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertLtDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be less than second. - function assertLt(uint256 left, uint256 right) external pure; - - /// Compares two `uint256` values. Expects first value to be less than second. - /// Includes error message into revert string on failure. - function assertLt(uint256 left, uint256 right, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be less than second. - function assertLt(int256 left, int256 right) external pure; - - /// Compares two `int256` values. Expects first value to be less than second. - /// Includes error message into revert string on failure. - function assertLt(int256 left, int256 right, string calldata error) external pure; - - /// Asserts that two `uint256` values are not equal, formatting them with decimals in failure message. - function assertNotEqDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Asserts that two `uint256` values are not equal, formatting them with decimals in failure message. - /// Includes error message into revert string on failure. - function assertNotEqDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Asserts that two `int256` values are not equal, formatting them with decimals in failure message. - function assertNotEqDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Asserts that two `int256` values are not equal, formatting them with decimals in failure message. - /// Includes error message into revert string on failure. - function assertNotEqDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Asserts that two `bool` values are not equal. - function assertNotEq(bool left, bool right) external pure; - - /// Asserts that two `bool` values are not equal and includes error message into revert string on failure. - function assertNotEq(bool left, bool right, string calldata error) external pure; - - /// Asserts that two `string` values are not equal. - function assertNotEq(string calldata left, string calldata right) external pure; - - /// Asserts that two `string` values are not equal and includes error message into revert string on failure. - function assertNotEq(string calldata left, string calldata right, string calldata error) external pure; - - /// Asserts that two `bytes` values are not equal. - function assertNotEq(bytes calldata left, bytes calldata right) external pure; - - /// Asserts that two `bytes` values are not equal and includes error message into revert string on failure. - function assertNotEq(bytes calldata left, bytes calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bool` values are not equal. - function assertNotEq(bool[] calldata left, bool[] calldata right) external pure; - - /// Asserts that two arrays of `bool` values are not equal and includes error message into revert string on failure. - function assertNotEq(bool[] calldata left, bool[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `uint256` values are not equal. - function assertNotEq(uint256[] calldata left, uint256[] calldata right) external pure; - - /// Asserts that two arrays of `uint256` values are not equal and includes error message into revert string on failure. - function assertNotEq(uint256[] calldata left, uint256[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `int256` values are not equal. - function assertNotEq(int256[] calldata left, int256[] calldata right) external pure; - - /// Asserts that two arrays of `int256` values are not equal and includes error message into revert string on failure. - function assertNotEq(int256[] calldata left, int256[] calldata right, string calldata error) external pure; - - /// Asserts that two `uint256` values are not equal. - function assertNotEq(uint256 left, uint256 right) external pure; - - /// Asserts that two arrays of `address` values are not equal. - function assertNotEq(address[] calldata left, address[] calldata right) external pure; - - /// Asserts that two arrays of `address` values are not equal and includes error message into revert string on failure. - function assertNotEq(address[] calldata left, address[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bytes32` values are not equal. - function assertNotEq(bytes32[] calldata left, bytes32[] calldata right) external pure; - - /// Asserts that two arrays of `bytes32` values are not equal and includes error message into revert string on failure. - function assertNotEq(bytes32[] calldata left, bytes32[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `string` values are not equal. - function assertNotEq(string[] calldata left, string[] calldata right) external pure; - - /// Asserts that two arrays of `string` values are not equal and includes error message into revert string on failure. - function assertNotEq(string[] calldata left, string[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bytes` values are not equal. - function assertNotEq(bytes[] calldata left, bytes[] calldata right) external pure; - - /// Asserts that two arrays of `bytes` values are not equal and includes error message into revert string on failure. - function assertNotEq(bytes[] calldata left, bytes[] calldata right, string calldata error) external pure; - - /// Asserts that two `uint256` values are not equal and includes error message into revert string on failure. - function assertNotEq(uint256 left, uint256 right, string calldata error) external pure; - - /// Asserts that two `int256` values are not equal. - function assertNotEq(int256 left, int256 right) external pure; - - /// Asserts that two `int256` values are not equal and includes error message into revert string on failure. - function assertNotEq(int256 left, int256 right, string calldata error) external pure; - - /// Asserts that two `address` values are not equal. - function assertNotEq(address left, address right) external pure; - - /// Asserts that two `address` values are not equal and includes error message into revert string on failure. - function assertNotEq(address left, address right, string calldata error) external pure; - - /// Asserts that two `bytes32` values are not equal. - function assertNotEq(bytes32 left, bytes32 right) external pure; - - /// Asserts that two `bytes32` values are not equal and includes error message into revert string on failure. - function assertNotEq(bytes32 left, bytes32 right, string calldata error) external pure; - - /// Asserts that the given condition is true. - function assertTrue(bool condition) external pure; - - /// Asserts that the given condition is true and includes error message into revert string on failure. - function assertTrue(bool condition, string calldata error) external pure; - - /// If the condition is false, discard this run's fuzz inputs and generate new ones. - function assume(bool condition) external pure; - - /// Discard this run's fuzz inputs and generate new ones if next call reverted. - function assumeNoRevert() external pure; - - /// Discard this run's fuzz inputs and generate new ones if next call reverts with the potential revert parameters. - function assumeNoRevert(PotentialRevert calldata potentialRevert) external pure; - - /// Discard this run's fuzz inputs and generate new ones if next call reverts with the any of the potential revert parameters. - function assumeNoRevert(PotentialRevert[] calldata potentialReverts) external pure; - - /// Writes a breakpoint to jump to in the debugger. - function breakpoint(string calldata char) external pure; - - /// Writes a conditional breakpoint to jump to in the debugger. - function breakpoint(string calldata char, bool value) external pure; - - /// Returns true if the current Foundry version is greater than or equal to the given version. - /// The given version string must be in the format `major.minor.patch`. - /// This is equivalent to `foundryVersionCmp(version) >= 0`. - function foundryVersionAtLeast(string calldata version) external view returns (bool); - - /// Compares the current Foundry version with the given version string. - /// The given version string must be in the format `major.minor.patch`. - /// Returns: - /// -1 if current Foundry version is less than the given version - /// 0 if current Foundry version equals the given version - /// 1 if current Foundry version is greater than the given version - /// This result can then be used with a comparison operator against `0`. - /// For example, to check if the current Foundry version is greater than or equal to `1.0.0`: - /// `if (foundryVersionCmp("1.0.0") >= 0) { ... }` - function foundryVersionCmp(string calldata version) external view returns (int256); - - /// Returns a Chain struct for specific alias - function getChain(string calldata chainAlias) external view returns (Chain memory chain); - - /// Returns a Chain struct for specific chainId - function getChain(uint256 chainId) external view returns (Chain memory chain); - - /// Returns the Foundry version. - /// Format: -+.. - /// Sample output: 0.3.0-nightly+3cb96bde9b.1737036656.debug - /// Note: Build timestamps may vary slightly across platforms due to separate CI jobs. - /// For reliable version comparisons, use UNIX format (e.g., >= 1700000000) - /// to compare timestamps while ignoring minor time differences. - function getFoundryVersion() external view returns (string memory version); - - /// Returns the RPC url for the given alias. - function rpcUrl(string calldata rpcAlias) external view returns (string memory json); - - /// Returns all rpc urls and their aliases as structs. - function rpcUrlStructs() external view returns (Rpc[] memory urls); - - /// Returns all rpc urls and their aliases `[alias, url][]`. - function rpcUrls() external view returns (string[2][] memory urls); - - /// Suspends execution of the main thread for `duration` milliseconds. - function sleep(uint256 duration) external; - - // ======== Toml ======== - - /// Checks if `key` exists in a TOML table. - function keyExistsToml(string calldata toml, string calldata key) external view returns (bool); - - /// Parses a string of TOML data at `key` and coerces it to `address`. - function parseTomlAddress(string calldata toml, string calldata key) external pure returns (address); - - /// Parses a string of TOML data at `key` and coerces it to `address[]`. - function parseTomlAddressArray(string calldata toml, string calldata key) external pure returns (address[] memory); - - /// Parses a string of TOML data at `key` and coerces it to `bool`. - function parseTomlBool(string calldata toml, string calldata key) external pure returns (bool); - - /// Parses a string of TOML data at `key` and coerces it to `bool[]`. - function parseTomlBoolArray(string calldata toml, string calldata key) external pure returns (bool[] memory); - - /// Parses a string of TOML data at `key` and coerces it to `bytes`. - function parseTomlBytes(string calldata toml, string calldata key) external pure returns (bytes memory); - - /// Parses a string of TOML data at `key` and coerces it to `bytes32`. - function parseTomlBytes32(string calldata toml, string calldata key) external pure returns (bytes32); - - /// Parses a string of TOML data at `key` and coerces it to `bytes32[]`. - function parseTomlBytes32Array(string calldata toml, string calldata key) external pure returns (bytes32[] memory); - - /// Parses a string of TOML data at `key` and coerces it to `bytes[]`. - function parseTomlBytesArray(string calldata toml, string calldata key) external pure returns (bytes[] memory); - - /// Parses a string of TOML data at `key` and coerces it to `int256`. - function parseTomlInt(string calldata toml, string calldata key) external pure returns (int256); - - /// Parses a string of TOML data at `key` and coerces it to `int256[]`. - function parseTomlIntArray(string calldata toml, string calldata key) external pure returns (int256[] memory); - - /// Returns an array of all the keys in a TOML table. - function parseTomlKeys(string calldata toml, string calldata key) external pure returns (string[] memory keys); - - /// Parses a string of TOML data at `key` and coerces it to `string`. - function parseTomlString(string calldata toml, string calldata key) external pure returns (string memory); - - /// Parses a string of TOML data at `key` and coerces it to `string[]`. - function parseTomlStringArray(string calldata toml, string calldata key) external pure returns (string[] memory); - - /// Parses a string of TOML data at `key` and coerces it to type array corresponding to `typeDescription`. - function parseTomlTypeArray(string calldata toml, string calldata key, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of TOML data and coerces it to type corresponding to `typeDescription`. - function parseTomlType(string calldata toml, string calldata typeDescription) external pure returns (bytes memory); - - /// Parses a string of TOML data at `key` and coerces it to type corresponding to `typeDescription`. - function parseTomlType(string calldata toml, string calldata key, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of TOML data at `key` and coerces it to `uint256`. - function parseTomlUint(string calldata toml, string calldata key) external pure returns (uint256); - - /// Parses a string of TOML data at `key` and coerces it to `uint256[]`. - function parseTomlUintArray(string calldata toml, string calldata key) external pure returns (uint256[] memory); - - /// ABI-encodes a TOML table. - function parseToml(string calldata toml) external pure returns (bytes memory abiEncodedData); - - /// ABI-encodes a TOML table at `key`. - function parseToml(string calldata toml, string calldata key) external pure returns (bytes memory abiEncodedData); - - /// Takes serialized JSON, converts to TOML and write a serialized TOML to a file. - function writeToml(string calldata json, string calldata path) external; - - /// Takes serialized JSON, converts to TOML and write a serialized TOML table to an **existing** TOML file, replacing a value with key = - /// This is useful to replace a specific value of a TOML file, without having to parse the entire thing. - /// This cheatcode will create new keys if they didn't previously exist. - function writeToml(string calldata json, string calldata path, string calldata valueKey) external; - - // ======== Utilities ======== - - /// Returns an uint256 value bounded in given range and different from the current one. - function bound(uint256 current, uint256 min, uint256 max) external view returns (uint256); - - /// Returns an int256 value bounded in given range and different from the current one. - function bound(int256 current, int256 min, int256 max) external view returns (int256); - - /// Compute the address of a contract created with CREATE2 using the given CREATE2 deployer. - function computeCreate2Address(bytes32 salt, bytes32 initCodeHash, address deployer) external pure returns (address); - - /// Compute the address of a contract created with CREATE2 using the default CREATE2 deployer. - function computeCreate2Address(bytes32 salt, bytes32 initCodeHash) external pure returns (address); - - /// Compute the address a contract will be deployed at for a given deployer address and nonce. - function computeCreateAddress(address deployer, uint256 nonce) external pure returns (address); - - /// Utility cheatcode to copy storage of `from` contract to another `to` contract. - function copyStorage(address from, address to) external; - - /// Generates the struct hash of the canonical EIP-712 type representation and its abi-encoded data. - /// Supports 2 different inputs: - /// 1. Name of the type (i.e. "PermitSingle"): - /// * requires previous binding generation with `forge bind-json`. - /// * bindings will be retrieved from the path configured in `foundry.toml`. - /// 2. String representation of the type (i.e. "Foo(Bar bar) Bar(uint256 baz)"). - /// * Note: the cheatcode will use the canonical type even if the input is malformated - /// with the wrong order of elements or with extra whitespaces. - function eip712HashStruct(string calldata typeNameOrDefinition, bytes calldata abiEncodedData) - external - pure - returns (bytes32 typeHash); - - /// Generates the struct hash of the canonical EIP-712 type representation and its abi-encoded data. - /// Requires previous binding generation with `forge bind-json`. - /// Params: - /// * `bindingsPath`: path where the output of `forge bind-json` is stored. - /// * `typeName`: Name of the type (i.e. "PermitSingle"). - /// * `abiEncodedData`: ABI-encoded data for the struct that is being hashed. - function eip712HashStruct(string calldata bindingsPath, string calldata typeName, bytes calldata abiEncodedData) - external - pure - returns (bytes32 typeHash); - - /// Generates the hash of the canonical EIP-712 type representation. - /// Supports 2 different inputs: - /// 1. Name of the type (i.e. "Transaction"): - /// * requires previous binding generation with `forge bind-json`. - /// * bindings will be retrieved from the path configured in `foundry.toml`. - /// 2. String representation of the type (i.e. "Foo(Bar bar) Bar(uint256 baz)"). - /// * Note: the cheatcode will output the canonical type even if the input is malformated - /// with the wrong order of elements or with extra whitespaces. - function eip712HashType(string calldata typeNameOrDefinition) external pure returns (bytes32 typeHash); - - /// Generates the hash of the canonical EIP-712 type representation. - /// Requires previous binding generation with `forge bind-json`. - /// Params: - /// * `bindingsPath`: path where the output of `forge bind-json` is stored. - /// * `typeName`: Name of the type (i.e. "Transaction"). - function eip712HashType(string calldata bindingsPath, string calldata typeName) - external - pure - returns (bytes32 typeHash); - - /// Generates a ready-to-sign digest of human-readable typed data following the EIP-712 standard. - function eip712HashTypedData(string calldata jsonData) external pure returns (bytes32 digest); - - /// Returns ENS namehash for provided string. - function ensNamehash(string calldata name) external pure returns (bytes32); - - /// RLP decodes an RLP payload into a list of bytes. - function fromRlp(bytes calldata rlp) external pure returns (bytes[] memory data); - - /// Gets the label for the specified address. - function getLabel(address account) external view returns (string memory currentLabel); - - /// Labels an address in call traces. - function label(address account, string calldata newLabel) external; - - /// Pauses collection of call traces. Useful in cases when you want to skip tracing of - /// complex calls which are not useful for debugging. - function pauseTracing() external view; - - /// Returns a random `address`. - function randomAddress() external view returns (address); - - /// Returns a random `bool`. - function randomBool() external view returns (bool); - - /// Returns a random byte array value of the given length. - function randomBytes(uint256 len) external view returns (bytes memory); - - /// Returns a random fixed-size byte array of length 4. - function randomBytes4() external view returns (bytes4); - - /// Returns a random fixed-size byte array of length 8. - function randomBytes8() external view returns (bytes8); - - /// Returns a random `int256` value. - function randomInt() external view returns (int256); - - /// Returns a random `int256` value of given bits. - function randomInt(uint256 bits) external view returns (int256); - - /// Returns a random uint256 value. - function randomUint() external view returns (uint256); - - /// Returns random uint256 value between the provided range (=min..=max). - function randomUint(uint256 min, uint256 max) external view returns (uint256); - - /// Returns a random `uint256` value of given bits. - function randomUint(uint256 bits) external view returns (uint256); - - /// Unpauses collection of call traces. - function resumeTracing() external view; - - /// Utility cheatcode to set arbitrary storage for given target address. - function setArbitraryStorage(address target) external; - - /// Utility cheatcode to set arbitrary storage for given target address and overwrite - /// any storage slots that have been previously set. - function setArbitraryStorage(address target, bool overwrite) external; - - /// Set RNG seed. - function setSeed(uint256 seed) external; - - /// Randomly shuffles an array. - function shuffle(uint256[] calldata array) external returns (uint256[] memory); - - /// Sorts an array in ascending order. - function sort(uint256[] calldata array) external returns (uint256[] memory); - - /// Encodes a `bytes` value to a base64url string. - function toBase64URL(bytes calldata data) external pure returns (string memory); - - /// Encodes a `string` value to a base64url string. - function toBase64URL(string calldata data) external pure returns (string memory); - - /// Encodes a `bytes` value to a base64 string. - function toBase64(bytes calldata data) external pure returns (string memory); - - /// Encodes a `string` value to a base64 string. - function toBase64(string calldata data) external pure returns (string memory); - - /// RLP encodes a list of bytes into an RLP payload. - function toRlp(bytes[] calldata data) external pure returns (bytes memory); -} - -/// The `Vm` interface does allow manipulation of the EVM state. These are all intended to be used -/// in tests, but it is not recommended to use these cheats in scripts. -interface Vm is VmSafe { - // ======== EVM ======== - - /// Utility cheatcode to set an EIP-2930 access list for all subsequent transactions. - function accessList(AccessListItem[] calldata access) external; - - /// Returns the identifier of the currently active fork. Reverts if no fork is currently active. - function activeFork() external view returns (uint256 forkId); - - /// In forking mode, explicitly grant the given address cheatcode access. - function allowCheatcodes(address account) external; - - /// Sets `block.blobbasefee` - function blobBaseFee(uint256 newBlobBaseFee) external; - - /// Sets the blobhashes in the transaction. - /// Not available on EVM versions before Cancun. - /// If used on unsupported EVM versions it will revert. - function blobhashes(bytes32[] calldata hashes) external; - - /// Sets `block.chainid`. - function chainId(uint256 newChainId) external; - - /// Clears all mocked calls. - function clearMockedCalls() external; - - /// Clones a source account code, state, balance and nonce to a target account and updates in-memory EVM state. - function cloneAccount(address source, address target) external; - - /// Sets `block.coinbase`. - function coinbase(address newCoinbase) external; - - /// Marks the slots of an account and the account address as cold. - function cool(address target) external; - - /// Utility cheatcode to mark specific storage slot as cold, simulating no prior read. - function coolSlot(address target, bytes32 slot) external; - - /// Creates a new fork with the given endpoint and the _latest_ block and returns the identifier of the fork. - function createFork(string calldata urlOrAlias) external returns (uint256 forkId); - - /// Creates a new fork with the given endpoint and block and returns the identifier of the fork. - function createFork(string calldata urlOrAlias, uint256 blockNumber) external returns (uint256 forkId); - - /// Creates a new fork with the given endpoint and at the block the given transaction was mined in, - /// replays all transaction mined in the block before the transaction, and returns the identifier of the fork. - function createFork(string calldata urlOrAlias, bytes32 txHash) external returns (uint256 forkId); - - /// Creates and also selects a new fork with the given endpoint and the latest block and returns the identifier of the fork. - function createSelectFork(string calldata urlOrAlias) external returns (uint256 forkId); - - /// Creates and also selects a new fork with the given endpoint and block and returns the identifier of the fork. - function createSelectFork(string calldata urlOrAlias, uint256 blockNumber) external returns (uint256 forkId); - - /// Creates and also selects new fork with the given endpoint and at the block the given transaction was mined in, - /// replays all transaction mined in the block before the transaction, returns the identifier of the fork. - function createSelectFork(string calldata urlOrAlias, bytes32 txHash) external returns (uint256 forkId); - - /// Sets an address' balance. - function deal(address account, uint256 newBalance) external; - - /// Removes the snapshot with the given ID created by `snapshot`. - /// Takes the snapshot ID to delete. - /// Returns `true` if the snapshot was successfully deleted. - /// Returns `false` if the snapshot does not exist. - function deleteStateSnapshot(uint256 snapshotId) external returns (bool success); - - /// Removes _all_ snapshots previously created by `snapshot`. - function deleteStateSnapshots() external; - - /// Sets `block.difficulty`. - /// Not available on EVM versions from Paris onwards. Use `prevrandao` instead. - /// Reverts if used on unsupported EVM versions. - function difficulty(uint256 newDifficulty) external; - - /// Dump a genesis JSON file's `allocs` to disk. - function dumpState(string calldata pathToStateJson) external; - - /// Sets an address' code. - function etch(address target, bytes calldata newRuntimeBytecode) external; - - /// Sets `block.basefee`. - function fee(uint256 newBasefee) external; - - /// Gets the blockhashes from the current transaction. - /// Not available on EVM versions before Cancun. - /// If used on unsupported EVM versions it will revert. - function getBlobhashes() external view returns (bytes32[] memory hashes); - - /// Returns true if the account is marked as persistent. - function isPersistent(address account) external view returns (bool persistent); - - /// Load a genesis JSON file's `allocs` into the in-memory EVM state. - function loadAllocs(string calldata pathToAllocsJson) external; - - /// Marks that the account(s) should use persistent storage across fork swaps in a multifork setup - /// Meaning, changes made to the state of this account will be kept when switching forks. - function makePersistent(address account) external; - - /// See `makePersistent(address)`. - function makePersistent(address account0, address account1) external; - - /// See `makePersistent(address)`. - function makePersistent(address account0, address account1, address account2) external; - - /// See `makePersistent(address)`. - function makePersistent(address[] calldata accounts) external; - - /// Reverts a call to an address with specified revert data. - function mockCallRevert(address callee, bytes calldata data, bytes calldata revertData) external; - - /// Reverts a call to an address with a specific `msg.value`, with specified revert data. - function mockCallRevert(address callee, uint256 msgValue, bytes calldata data, bytes calldata revertData) external; - - /// Reverts a call to an address with specified revert data. - /// Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`. - function mockCallRevert(address callee, bytes4 data, bytes calldata revertData) external; - - /// Reverts a call to an address with a specific `msg.value`, with specified revert data. - /// Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`. - function mockCallRevert(address callee, uint256 msgValue, bytes4 data, bytes calldata revertData) external; - - /// Mocks a call to an address, returning specified data. - /// Calldata can either be strict or a partial match, e.g. if you only - /// pass a Solidity selector to the expected calldata, then the entire Solidity - /// function will be mocked. - function mockCall(address callee, bytes calldata data, bytes calldata returnData) external; - - /// Mocks a call to an address with a specific `msg.value`, returning specified data. - /// Calldata match takes precedence over `msg.value` in case of ambiguity. - function mockCall(address callee, uint256 msgValue, bytes calldata data, bytes calldata returnData) external; - - /// Mocks a call to an address, returning specified data. - /// Calldata can either be strict or a partial match, e.g. if you only - /// pass a Solidity selector to the expected calldata, then the entire Solidity - /// function will be mocked. - /// Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`. - function mockCall(address callee, bytes4 data, bytes calldata returnData) external; - - /// Mocks a call to an address with a specific `msg.value`, returning specified data. - /// Calldata match takes precedence over `msg.value` in case of ambiguity. - /// Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`. - function mockCall(address callee, uint256 msgValue, bytes4 data, bytes calldata returnData) external; - - /// Mocks multiple calls to an address, returning specified data for each call. - function mockCalls(address callee, bytes calldata data, bytes[] calldata returnData) external; - - /// Mocks multiple calls to an address with a specific `msg.value`, returning specified data for each call. - function mockCalls(address callee, uint256 msgValue, bytes calldata data, bytes[] calldata returnData) external; - - /// Whenever a call is made to `callee` with calldata `data`, this cheatcode instead calls - /// `target` with the same calldata. This functionality is similar to a delegate call made to - /// `target` contract from `callee`. - /// Can be used to substitute a call to a function with another implementation that captures - /// the primary logic of the original function but is easier to reason about. - /// If calldata is not a strict match then partial match by selector is attempted. - function mockFunction(address callee, address target, bytes calldata data) external; - - /// Utility cheatcode to remove any EIP-2930 access list set by `accessList` cheatcode. - function noAccessList() external; - - /// Sets the *next* call's `msg.sender` to be the input address. - function prank(address msgSender) external; - - /// Sets the *next* call's `msg.sender` to be the input address, and the `tx.origin` to be the second input. - function prank(address msgSender, address txOrigin) external; - - /// Sets the *next* delegate call's `msg.sender` to be the input address. - function prank(address msgSender, bool delegateCall) external; - - /// Sets the *next* delegate call's `msg.sender` to be the input address, and the `tx.origin` to be the second input. - function prank(address msgSender, address txOrigin, bool delegateCall) external; - - /// Sets `block.prevrandao`. - /// Not available on EVM versions before Paris. Use `difficulty` instead. - /// If used on unsupported EVM versions it will revert. - function prevrandao(bytes32 newPrevrandao) external; - - /// Sets `block.prevrandao`. - /// Not available on EVM versions before Paris. Use `difficulty` instead. - /// If used on unsupported EVM versions it will revert. - function prevrandao(uint256 newPrevrandao) external; - - /// Reads the current `msg.sender` and `tx.origin` from state and reports if there is any active caller modification. - function readCallers() external view returns (CallerMode callerMode, address msgSender, address txOrigin); - - /// Resets the nonce of an account to 0 for EOAs and 1 for contract accounts. - function resetNonce(address account) external; - - /// Revert the state of the EVM to a previous snapshot - /// Takes the snapshot ID to revert to. - /// Returns `true` if the snapshot was successfully reverted. - /// Returns `false` if the snapshot does not exist. - /// **Note:** This does not automatically delete the snapshot. To delete the snapshot use `deleteStateSnapshot`. - function revertToState(uint256 snapshotId) external returns (bool success); - - /// Revert the state of the EVM to a previous snapshot and automatically deletes the snapshots - /// Takes the snapshot ID to revert to. - /// Returns `true` if the snapshot was successfully reverted and deleted. - /// Returns `false` if the snapshot does not exist. - function revertToStateAndDelete(uint256 snapshotId) external returns (bool success); - - /// Revokes persistent status from the address, previously added via `makePersistent`. - function revokePersistent(address account) external; - - /// See `revokePersistent(address)`. - function revokePersistent(address[] calldata accounts) external; - - /// Sets `block.height`. - function roll(uint256 newHeight) external; - - /// Updates the currently active fork to given block number - /// This is similar to `roll` but for the currently active fork. - function rollFork(uint256 blockNumber) external; - - /// Updates the currently active fork to given transaction. This will `rollFork` with the number - /// of the block the transaction was mined in and replays all transaction mined before it in the block. - function rollFork(bytes32 txHash) external; - - /// Updates the given fork to given block number. - function rollFork(uint256 forkId, uint256 blockNumber) external; - - /// Updates the given fork to block number of the given transaction and replays all transaction mined before it in the block. - function rollFork(uint256 forkId, bytes32 txHash) external; - - /// Takes a fork identifier created by `createFork` and sets the corresponding forked state as active. - function selectFork(uint256 forkId) external; - - /// Set blockhash for the current block. - /// It only sets the blockhash for blocks where `block.number - 256 <= number < block.number`. - function setBlockhash(uint256 blockNumber, bytes32 blockHash) external; - - /// Sets the nonce of an account. Must be higher than the current nonce of the account. - function setNonce(address account, uint64 newNonce) external; - - /// Sets the nonce of an account to an arbitrary value. - function setNonceUnsafe(address account, uint64 newNonce) external; - - /// Snapshot capture the gas usage of the last call by name from the callee perspective. - function snapshotGasLastCall(string calldata name) external returns (uint256 gasUsed); - - /// Snapshot capture the gas usage of the last call by name in a group from the callee perspective. - function snapshotGasLastCall(string calldata group, string calldata name) external returns (uint256 gasUsed); - - /// Snapshot the current state of the evm. - /// Returns the ID of the snapshot that was created. - /// To revert a snapshot use `revertToState`. - function snapshotState() external returns (uint256 snapshotId); - - /// Snapshot capture an arbitrary numerical value by name. - /// The group name is derived from the contract name. - function snapshotValue(string calldata name, uint256 value) external; - - /// Snapshot capture an arbitrary numerical value by name in a group. - function snapshotValue(string calldata group, string calldata name, uint256 value) external; - - /// Sets all subsequent calls' `msg.sender` to be the input address until `stopPrank` is called. - function startPrank(address msgSender) external; - - /// Sets all subsequent calls' `msg.sender` to be the input address until `stopPrank` is called, and the `tx.origin` to be the second input. - function startPrank(address msgSender, address txOrigin) external; - - /// Sets all subsequent delegate calls' `msg.sender` to be the input address until `stopPrank` is called. - function startPrank(address msgSender, bool delegateCall) external; - - /// Sets all subsequent delegate calls' `msg.sender` to be the input address until `stopPrank` is called, and the `tx.origin` to be the second input. - function startPrank(address msgSender, address txOrigin, bool delegateCall) external; - - /// Start a snapshot capture of the current gas usage by name. - /// The group name is derived from the contract name. - function startSnapshotGas(string calldata name) external; - - /// Start a snapshot capture of the current gas usage by name in a group. - function startSnapshotGas(string calldata group, string calldata name) external; - - /// Resets subsequent calls' `msg.sender` to be `address(this)`. - function stopPrank() external; - - /// Stop the snapshot capture of the current gas by latest snapshot name, capturing the gas used since the start. - function stopSnapshotGas() external returns (uint256 gasUsed); - - /// Stop the snapshot capture of the current gas usage by name, capturing the gas used since the start. - /// The group name is derived from the contract name. - function stopSnapshotGas(string calldata name) external returns (uint256 gasUsed); - - /// Stop the snapshot capture of the current gas usage by name in a group, capturing the gas used since the start. - function stopSnapshotGas(string calldata group, string calldata name) external returns (uint256 gasUsed); - - /// Stores a value to an address' storage slot. - function store(address target, bytes32 slot, bytes32 value) external; - - /// Fetches the given transaction from the active fork and executes it on the current state. - function transact(bytes32 txHash) external; - - /// Fetches the given transaction from the given fork and executes it on the current state. - function transact(uint256 forkId, bytes32 txHash) external; - - /// Sets `tx.gasprice`. - function txGasPrice(uint256 newGasPrice) external; - - /// Utility cheatcode to mark specific storage slot as warm, simulating a prior read. - function warmSlot(address target, bytes32 slot) external; - - /// Sets `block.timestamp`. - function warp(uint256 newTimestamp) external; - - /// `deleteSnapshot` is being deprecated in favor of `deleteStateSnapshot`. It will be removed in future versions. - function deleteSnapshot(uint256 snapshotId) external returns (bool success); - - /// `deleteSnapshots` is being deprecated in favor of `deleteStateSnapshots`. It will be removed in future versions. - function deleteSnapshots() external; - - /// `revertToAndDelete` is being deprecated in favor of `revertToStateAndDelete`. It will be removed in future versions. - function revertToAndDelete(uint256 snapshotId) external returns (bool success); - - /// `revertTo` is being deprecated in favor of `revertToState`. It will be removed in future versions. - function revertTo(uint256 snapshotId) external returns (bool success); - - /// `snapshot` is being deprecated in favor of `snapshotState`. It will be removed in future versions. - function snapshot() external returns (uint256 snapshotId); - - // ======== Testing ======== - - /// Expect a call to an address with the specified `msg.value` and calldata, and a *minimum* amount of gas. - function expectCallMinGas(address callee, uint256 msgValue, uint64 minGas, bytes calldata data) external; - - /// Expect given number of calls to an address with the specified `msg.value` and calldata, and a *minimum* amount of gas. - function expectCallMinGas(address callee, uint256 msgValue, uint64 minGas, bytes calldata data, uint64 count) - external; - - /// Expects a call to an address with the specified calldata. - /// Calldata can either be a strict or a partial match. - function expectCall(address callee, bytes calldata data) external; - - /// Expects given number of calls to an address with the specified calldata. - function expectCall(address callee, bytes calldata data, uint64 count) external; - - /// Expects a call to an address with the specified `msg.value` and calldata. - function expectCall(address callee, uint256 msgValue, bytes calldata data) external; - - /// Expects given number of calls to an address with the specified `msg.value` and calldata. - function expectCall(address callee, uint256 msgValue, bytes calldata data, uint64 count) external; - - /// Expect a call to an address with the specified `msg.value`, gas, and calldata. - function expectCall(address callee, uint256 msgValue, uint64 gas, bytes calldata data) external; - - /// Expects given number of calls to an address with the specified `msg.value`, gas, and calldata. - function expectCall(address callee, uint256 msgValue, uint64 gas, bytes calldata data, uint64 count) external; - - /// Expects the deployment of the specified bytecode by the specified address using the CREATE opcode - function expectCreate(bytes calldata bytecode, address deployer) external; - - /// Expects the deployment of the specified bytecode by the specified address using the CREATE2 opcode - function expectCreate2(bytes calldata bytecode, address deployer) external; - - /// Prepare an expected anonymous log with (bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData.). - /// Call this function, then emit an anonymous event, then call a function. Internally after the call, we check if - /// logs were emitted in the expected order with the expected topics and data (as specified by the booleans). - function expectEmitAnonymous(bool checkTopic0, bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData) - external; - - /// Same as the previous method, but also checks supplied address against emitting contract. - function expectEmitAnonymous( - bool checkTopic0, - bool checkTopic1, - bool checkTopic2, - bool checkTopic3, - bool checkData, - address emitter - ) external; - - /// Prepare an expected anonymous log with all topic and data checks enabled. - /// Call this function, then emit an anonymous event, then call a function. Internally after the call, we check if - /// logs were emitted in the expected order with the expected topics and data. - function expectEmitAnonymous() external; - - /// Same as the previous method, but also checks supplied address against emitting contract. - function expectEmitAnonymous(address emitter) external; - - /// Prepare an expected log with (bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData.). - /// Call this function, then emit an event, then call a function. Internally after the call, we check if - /// logs were emitted in the expected order with the expected topics and data (as specified by the booleans). - function expectEmit(bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData) external; - - /// Same as the previous method, but also checks supplied address against emitting contract. - function expectEmit(bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData, address emitter) external; - - /// Prepare an expected log with all topic and data checks enabled. - /// Call this function, then emit an event, then call a function. Internally after the call, we check if - /// logs were emitted in the expected order with the expected topics and data. - function expectEmit() external; - - /// Same as the previous method, but also checks supplied address against emitting contract. - function expectEmit(address emitter) external; - - /// Expect a given number of logs with the provided topics. - function expectEmit(bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData, uint64 count) external; - - /// Expect a given number of logs from a specific emitter with the provided topics. - function expectEmit( - bool checkTopic1, - bool checkTopic2, - bool checkTopic3, - bool checkData, - address emitter, - uint64 count - ) external; - - /// Expect a given number of logs with all topic and data checks enabled. - function expectEmit(uint64 count) external; - - /// Expect a given number of logs from a specific emitter with all topic and data checks enabled. - function expectEmit(address emitter, uint64 count) external; - - /// Expects an error on next call that starts with the revert data. - function expectPartialRevert(bytes4 revertData) external; - - /// Expects an error on next call to reverter address, that starts with the revert data. - function expectPartialRevert(bytes4 revertData, address reverter) external; - - /// Expects an error on next call with any revert data. - function expectRevert() external; - - /// Expects an error on next call that exactly matches the revert data. - function expectRevert(bytes4 revertData) external; - - /// Expects a `count` number of reverts from the upcoming calls from the reverter address that match the revert data. - function expectRevert(bytes4 revertData, address reverter, uint64 count) external; - - /// Expects a `count` number of reverts from the upcoming calls from the reverter address that exactly match the revert data. - function expectRevert(bytes calldata revertData, address reverter, uint64 count) external; - - /// Expects an error on next call that exactly matches the revert data. - function expectRevert(bytes calldata revertData) external; - - /// Expects an error with any revert data on next call to reverter address. - function expectRevert(address reverter) external; - - /// Expects an error from reverter address on next call, with any revert data. - function expectRevert(bytes4 revertData, address reverter) external; - - /// Expects an error from reverter address on next call, that exactly matches the revert data. - function expectRevert(bytes calldata revertData, address reverter) external; - - /// Expects a `count` number of reverts from the upcoming calls with any revert data or reverter. - function expectRevert(uint64 count) external; - - /// Expects a `count` number of reverts from the upcoming calls that match the revert data. - function expectRevert(bytes4 revertData, uint64 count) external; - - /// Expects a `count` number of reverts from the upcoming calls that exactly match the revert data. - function expectRevert(bytes calldata revertData, uint64 count) external; - - /// Expects a `count` number of reverts from the upcoming calls from the reverter address. - function expectRevert(address reverter, uint64 count) external; - - /// Only allows memory writes to offsets [0x00, 0x60) ∪ [min, max) in the current subcontext. If any other - /// memory is written to, the test will fail. Can be called multiple times to add more ranges to the set. - function expectSafeMemory(uint64 min, uint64 max) external; - - /// Only allows memory writes to offsets [0x00, 0x60) ∪ [min, max) in the next created subcontext. - /// If any other memory is written to, the test will fail. Can be called multiple times to add more ranges - /// to the set. - function expectSafeMemoryCall(uint64 min, uint64 max) external; - - /// Marks a test as skipped. Must be called at the top level of a test. - function skip(bool skipTest) external; - - /// Marks a test as skipped with a reason. Must be called at the top level of a test. - function skip(bool skipTest, string calldata reason) external; - - /// Stops all safe memory expectation in the current subcontext. - function stopExpectSafeMemory() external; - - // ======== Utilities ======== - - /// Causes the next contract creation (via new) to fail and return its initcode in the returndata buffer. - /// This allows type-safe access to the initcode payload that would be used for contract creation. - /// Example usage: - /// vm.interceptInitcode(); - /// bytes memory initcode; - /// try new MyContract(param1, param2) { assert(false); } - /// catch (bytes memory interceptedInitcode) { initcode = interceptedInitcode; } - function interceptInitcode() external; -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/console.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/console.sol deleted file mode 100644 index 88acdc8eb6..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/console.sol +++ /dev/null @@ -1,1551 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -library console { - address constant CONSOLE_ADDRESS = 0x000000000000000000636F6e736F6c652e6c6f67; - - function _sendLogPayloadImplementation(bytes memory payload) internal view { - address consoleAddress = CONSOLE_ADDRESS; - assembly ("memory-safe") { - pop(staticcall(gas(), consoleAddress, add(payload, 32), mload(payload), 0, 0)) - } - } - - function _castToPure(function(bytes memory) internal view fnIn) - internal - pure - returns (function(bytes memory) pure fnOut) - { - assembly { - fnOut := fnIn - } - } - - function _sendLogPayload(bytes memory payload) internal pure { - _castToPure(_sendLogPayloadImplementation)(payload); - } - - function log() internal pure { - _sendLogPayload(abi.encodeWithSignature("log()")); - } - - function logInt(int256 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(int256)", p0)); - } - - function logUint(uint256 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256)", p0)); - } - - function logString(string memory p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string)", p0)); - } - - function logBool(bool p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool)", p0)); - } - - function logAddress(address p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address)", p0)); - } - - function logBytes(bytes memory p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes)", p0)); - } - - function logBytes1(bytes1 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes1)", p0)); - } - - function logBytes2(bytes2 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes2)", p0)); - } - - function logBytes3(bytes3 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes3)", p0)); - } - - function logBytes4(bytes4 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes4)", p0)); - } - - function logBytes5(bytes5 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes5)", p0)); - } - - function logBytes6(bytes6 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes6)", p0)); - } - - function logBytes7(bytes7 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes7)", p0)); - } - - function logBytes8(bytes8 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes8)", p0)); - } - - function logBytes9(bytes9 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes9)", p0)); - } - - function logBytes10(bytes10 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes10)", p0)); - } - - function logBytes11(bytes11 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes11)", p0)); - } - - function logBytes12(bytes12 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes12)", p0)); - } - - function logBytes13(bytes13 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes13)", p0)); - } - - function logBytes14(bytes14 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes14)", p0)); - } - - function logBytes15(bytes15 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes15)", p0)); - } - - function logBytes16(bytes16 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes16)", p0)); - } - - function logBytes17(bytes17 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes17)", p0)); - } - - function logBytes18(bytes18 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes18)", p0)); - } - - function logBytes19(bytes19 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes19)", p0)); - } - - function logBytes20(bytes20 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes20)", p0)); - } - - function logBytes21(bytes21 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes21)", p0)); - } - - function logBytes22(bytes22 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes22)", p0)); - } - - function logBytes23(bytes23 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes23)", p0)); - } - - function logBytes24(bytes24 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes24)", p0)); - } - - function logBytes25(bytes25 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes25)", p0)); - } - - function logBytes26(bytes26 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes26)", p0)); - } - - function logBytes27(bytes27 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes27)", p0)); - } - - function logBytes28(bytes28 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes28)", p0)); - } - - function logBytes29(bytes29 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes29)", p0)); - } - - function logBytes30(bytes30 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes30)", p0)); - } - - function logBytes31(bytes31 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes31)", p0)); - } - - function logBytes32(bytes32 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes32)", p0)); - } - - function log(uint256 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256)", p0)); - } - - function log(int256 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(int256)", p0)); - } - - function log(string memory p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string)", p0)); - } - - function log(bool p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool)", p0)); - } - - function log(address p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address)", p0)); - } - - function log(uint256 p0, uint256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256)", p0, p1)); - } - - function log(uint256 p0, string memory p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string)", p0, p1)); - } - - function log(uint256 p0, bool p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool)", p0, p1)); - } - - function log(uint256 p0, address p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address)", p0, p1)); - } - - function log(string memory p0, uint256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256)", p0, p1)); - } - - function log(string memory p0, int256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,int256)", p0, p1)); - } - - function log(string memory p0, string memory p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string)", p0, p1)); - } - - function log(string memory p0, bool p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool)", p0, p1)); - } - - function log(string memory p0, address p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address)", p0, p1)); - } - - function log(bool p0, uint256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256)", p0, p1)); - } - - function log(bool p0, string memory p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string)", p0, p1)); - } - - function log(bool p0, bool p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool)", p0, p1)); - } - - function log(bool p0, address p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address)", p0, p1)); - } - - function log(address p0, uint256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256)", p0, p1)); - } - - function log(address p0, string memory p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string)", p0, p1)); - } - - function log(address p0, bool p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool)", p0, p1)); - } - - function log(address p0, address p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address)", p0, p1)); - } - - function log(uint256 p0, uint256 p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256)", p0, p1, p2)); - } - - function log(uint256 p0, uint256 p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string)", p0, p1, p2)); - } - - function log(uint256 p0, uint256 p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool)", p0, p1, p2)); - } - - function log(uint256 p0, uint256 p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address)", p0, p1, p2)); - } - - function log(uint256 p0, string memory p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256)", p0, p1, p2)); - } - - function log(uint256 p0, string memory p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string)", p0, p1, p2)); - } - - function log(uint256 p0, string memory p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool)", p0, p1, p2)); - } - - function log(uint256 p0, string memory p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address)", p0, p1, p2)); - } - - function log(uint256 p0, bool p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256)", p0, p1, p2)); - } - - function log(uint256 p0, bool p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string)", p0, p1, p2)); - } - - function log(uint256 p0, bool p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool)", p0, p1, p2)); - } - - function log(uint256 p0, bool p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address)", p0, p1, p2)); - } - - function log(uint256 p0, address p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256)", p0, p1, p2)); - } - - function log(uint256 p0, address p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string)", p0, p1, p2)); - } - - function log(uint256 p0, address p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool)", p0, p1, p2)); - } - - function log(uint256 p0, address p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address)", p0, p1, p2)); - } - - function log(string memory p0, uint256 p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256)", p0, p1, p2)); - } - - function log(string memory p0, uint256 p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string)", p0, p1, p2)); - } - - function log(string memory p0, uint256 p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool)", p0, p1, p2)); - } - - function log(string memory p0, uint256 p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address)", p0, p1, p2)); - } - - function log(string memory p0, string memory p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256)", p0, p1, p2)); - } - - function log(string memory p0, string memory p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string)", p0, p1, p2)); - } - - function log(string memory p0, string memory p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool)", p0, p1, p2)); - } - - function log(string memory p0, string memory p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address)", p0, p1, p2)); - } - - function log(string memory p0, bool p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256)", p0, p1, p2)); - } - - function log(string memory p0, bool p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string)", p0, p1, p2)); - } - - function log(string memory p0, bool p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool)", p0, p1, p2)); - } - - function log(string memory p0, bool p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address)", p0, p1, p2)); - } - - function log(string memory p0, address p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256)", p0, p1, p2)); - } - - function log(string memory p0, address p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string)", p0, p1, p2)); - } - - function log(string memory p0, address p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool)", p0, p1, p2)); - } - - function log(string memory p0, address p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address)", p0, p1, p2)); - } - - function log(bool p0, uint256 p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256)", p0, p1, p2)); - } - - function log(bool p0, uint256 p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string)", p0, p1, p2)); - } - - function log(bool p0, uint256 p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool)", p0, p1, p2)); - } - - function log(bool p0, uint256 p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address)", p0, p1, p2)); - } - - function log(bool p0, string memory p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256)", p0, p1, p2)); - } - - function log(bool p0, string memory p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string)", p0, p1, p2)); - } - - function log(bool p0, string memory p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool)", p0, p1, p2)); - } - - function log(bool p0, string memory p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address)", p0, p1, p2)); - } - - function log(bool p0, bool p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256)", p0, p1, p2)); - } - - function log(bool p0, bool p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string)", p0, p1, p2)); - } - - function log(bool p0, bool p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool)", p0, p1, p2)); - } - - function log(bool p0, bool p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address)", p0, p1, p2)); - } - - function log(bool p0, address p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256)", p0, p1, p2)); - } - - function log(bool p0, address p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string)", p0, p1, p2)); - } - - function log(bool p0, address p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool)", p0, p1, p2)); - } - - function log(bool p0, address p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address)", p0, p1, p2)); - } - - function log(address p0, uint256 p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256)", p0, p1, p2)); - } - - function log(address p0, uint256 p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string)", p0, p1, p2)); - } - - function log(address p0, uint256 p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool)", p0, p1, p2)); - } - - function log(address p0, uint256 p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address)", p0, p1, p2)); - } - - function log(address p0, string memory p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256)", p0, p1, p2)); - } - - function log(address p0, string memory p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string)", p0, p1, p2)); - } - - function log(address p0, string memory p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool)", p0, p1, p2)); - } - - function log(address p0, string memory p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address)", p0, p1, p2)); - } - - function log(address p0, bool p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256)", p0, p1, p2)); - } - - function log(address p0, bool p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string)", p0, p1, p2)); - } - - function log(address p0, bool p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool)", p0, p1, p2)); - } - - function log(address p0, bool p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address)", p0, p1, p2)); - } - - function log(address p0, address p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256)", p0, p1, p2)); - } - - function log(address p0, address p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string)", p0, p1, p2)); - } - - function log(address p0, address p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool)", p0, p1, p2)); - } - - function log(address p0, address p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address)", p0, p1, p2)); - } - - function log(uint256 p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address,address)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256,string)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256,address)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string,string)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string,address)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool,string)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool,address)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address,string)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address,address)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256,string)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256,address)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,string)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,address)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,string)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,address)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,string)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,address)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256,string)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256,address)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,string)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,address)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,string)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,address)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,string)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,address)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256,string)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256,address)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,string)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,address)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,string)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,address)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,string)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,address)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256,string)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256,bool)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256,address)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string,string)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string,bool)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string,address)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool,string)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool,bool)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool,address)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address,string)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address,bool)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address,address)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256,string)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256,bool)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256,address)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string,string)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string,bool)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string,address)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,string)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,bool)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,address)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address,string)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address,bool)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address,address)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256,string)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256,bool)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256,address)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,string)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,bool)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,address)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,string)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,bool)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,address)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,string)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,bool)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,address)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256,string)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256,bool)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256,address)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string,string)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string,bool)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string,address)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,string)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,bool)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,address)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address,string)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address,bool)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address,address)", p0, p1, p2, p3)); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/console2.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/console2.sol deleted file mode 100644 index 1ecdbbf723..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/console2.sol +++ /dev/null @@ -1,4 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {console as console2} from "./console.sol"; diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC1155.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC1155.sol deleted file mode 100644 index 9bf979dc5a..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC1155.sol +++ /dev/null @@ -1,105 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {IERC165} from "./IERC165.sol"; - -/// @title ERC-1155 Multi Token Standard -/// @dev See https://eips.ethereum.org/EIPS/eip-1155 -/// Note: The ERC-165 identifier for this interface is 0xd9b67a26. -interface IERC1155 is IERC165 { - /// @dev - /// - Either `TransferSingle` or `TransferBatch` MUST emit when tokens are transferred, including zero value transfers as well as minting or burning (see "Safe Transfer Rules" section of the standard). - /// - The `_operator` argument MUST be the address of an account/contract that is approved to make the transfer (SHOULD be msg.sender). - /// - The `_from` argument MUST be the address of the holder whose balance is decreased. - /// - The `_to` argument MUST be the address of the recipient whose balance is increased. - /// - The `_id` argument MUST be the token type being transferred. - /// - The `_value` argument MUST be the number of tokens the holder balance is decreased by and match what the recipient balance is increased by. - /// - When minting/creating tokens, the `_from` argument MUST be set to `0x0` (i.e. zero address). - /// - When burning/destroying tokens, the `_to` argument MUST be set to `0x0` (i.e. zero address). - event TransferSingle( - address indexed _operator, address indexed _from, address indexed _to, uint256 _id, uint256 _value - ); - - /// @dev - /// - Either `TransferSingle` or `TransferBatch` MUST emit when tokens are transferred, including zero value transfers as well as minting or burning (see "Safe Transfer Rules" section of the standard). - /// - The `_operator` argument MUST be the address of an account/contract that is approved to make the transfer (SHOULD be msg.sender). - /// - The `_from` argument MUST be the address of the holder whose balance is decreased. - /// - The `_to` argument MUST be the address of the recipient whose balance is increased. - /// - The `_ids` argument MUST be the list of tokens being transferred. - /// - The `_values` argument MUST be the list of number of tokens (matching the list and order of tokens specified in _ids) the holder balance is decreased by and match what the recipient balance is increased by. - /// - When minting/creating tokens, the `_from` argument MUST be set to `0x0` (i.e. zero address). - /// - When burning/destroying tokens, the `_to` argument MUST be set to `0x0` (i.e. zero address). - event TransferBatch( - address indexed _operator, address indexed _from, address indexed _to, uint256[] _ids, uint256[] _values - ); - - /// @dev MUST emit when approval for a second party/operator address to manage all tokens for an owner address is enabled or disabled (absence of an event assumes disabled). - event ApprovalForAll(address indexed _owner, address indexed _operator, bool _approved); - - /// @dev MUST emit when the URI is updated for a token ID. URIs are defined in RFC 3986. - /// The URI MUST point to a JSON file that conforms to the "ERC-1155 Metadata URI JSON Schema". - event URI(string _value, uint256 indexed _id); - - /// @notice Transfers `_value` amount of an `_id` from the `_from` address to the `_to` address specified (with safety call). - /// @dev Caller must be approved to manage the tokens being transferred out of the `_from` account (see "Approval" section of the standard). - /// - MUST revert if `_to` is the zero address. - /// - MUST revert if balance of holder for token `_id` is lower than the `_value` sent. - /// - MUST revert on any other error. - /// - MUST emit the `TransferSingle` event to reflect the balance change (see "Safe Transfer Rules" section of the standard). - /// - After the above conditions are met, this function MUST check if `_to` is a smart contract (e.g. code size > 0). If so, it MUST call `onERC1155Received` on `_to` and act appropriately (see "Safe Transfer Rules" section of the standard). - /// @param _from Source address - /// @param _to Target address - /// @param _id ID of the token type - /// @param _value Transfer amount - /// @param _data Additional data with no specified format, MUST be sent unaltered in call to `onERC1155Received` on `_to` - function safeTransferFrom(address _from, address _to, uint256 _id, uint256 _value, bytes calldata _data) external; - - /// @notice Transfers `_values` amount(s) of `_ids` from the `_from` address to the `_to` address specified (with safety call). - /// @dev Caller must be approved to manage the tokens being transferred out of the `_from` account (see "Approval" section of the standard). - /// - MUST revert if `_to` is the zero address. - /// - MUST revert if length of `_ids` is not the same as length of `_values`. - /// - MUST revert if any of the balance(s) of the holder(s) for token(s) in `_ids` is lower than the respective amount(s) in `_values` sent to the recipient. - /// - MUST revert on any other error. - /// - MUST emit `TransferSingle` or `TransferBatch` event(s) such that all the balance changes are reflected (see "Safe Transfer Rules" section of the standard). - /// - Balance changes and events MUST follow the ordering of the arrays (_ids[0]/_values[0] before _ids[1]/_values[1], etc). - /// - After the above conditions for the transfer(s) in the batch are met, this function MUST check if `_to` is a smart contract (e.g. code size > 0). If so, it MUST call the relevant `ERC1155TokenReceiver` hook(s) on `_to` and act appropriately (see "Safe Transfer Rules" section of the standard). - /// @param _from Source address - /// @param _to Target address - /// @param _ids IDs of each token type (order and length must match _values array) - /// @param _values Transfer amounts per token type (order and length must match _ids array) - /// @param _data Additional data with no specified format, MUST be sent unaltered in call to the `ERC1155TokenReceiver` hook(s) on `_to` - function safeBatchTransferFrom( - address _from, - address _to, - uint256[] calldata _ids, - uint256[] calldata _values, - bytes calldata _data - ) external; - - /// @notice Get the balance of an account's tokens. - /// @param _owner The address of the token holder - /// @param _id ID of the token - /// @return The _owner's balance of the token type requested - function balanceOf(address _owner, uint256 _id) external view returns (uint256); - - /// @notice Get the balance of multiple account/token pairs - /// @param _owners The addresses of the token holders - /// @param _ids ID of the tokens - /// @return The _owner's balance of the token types requested (i.e. balance for each (owner, id) pair) - function balanceOfBatch(address[] calldata _owners, uint256[] calldata _ids) - external - view - returns (uint256[] memory); - - /// @notice Enable or disable approval for a third party ("operator") to manage all of the caller's tokens. - /// @dev MUST emit the ApprovalForAll event on success. - /// @param _operator Address to add to the set of authorized operators - /// @param _approved True if the operator is approved, false to revoke approval - function setApprovalForAll(address _operator, bool _approved) external; - - /// @notice Queries the approval status of an operator for a given owner. - /// @param _owner The owner of the tokens - /// @param _operator Address of authorized operator - /// @return True if the operator is approved, false if not - function isApprovedForAll(address _owner, address _operator) external view returns (bool); -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC165.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC165.sol deleted file mode 100644 index fced182216..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC165.sol +++ /dev/null @@ -1,12 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -interface IERC165 { - /// @notice Query if a contract implements an interface - /// @param interfaceID The interface identifier, as specified in ERC-165 - /// @dev Interface identification is specified in ERC-165. This function - /// uses less than 30,000 gas. - /// @return `true` if the contract implements `interfaceID` and - /// `interfaceID` is not 0xffffffff, `false` otherwise - function supportsInterface(bytes4 interfaceID) external view returns (bool); -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC20.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC20.sol deleted file mode 100644 index 1a17fe1341..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC20.sol +++ /dev/null @@ -1,43 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -/// @dev Interface of the ERC20 standard as defined in the EIP. -/// @dev This includes the optional name, symbol, and decimals metadata. -interface IERC20 { - /// @dev Emitted when `value` tokens are moved from one account (`from`) to another (`to`). - event Transfer(address indexed from, address indexed to, uint256 value); - - /// @dev Emitted when the allowance of a `spender` for an `owner` is set, where `value` - /// is the new allowance. - event Approval(address indexed owner, address indexed spender, uint256 value); - - /// @notice Returns the amount of tokens in existence. - function totalSupply() external view returns (uint256); - - /// @notice Returns the amount of tokens owned by `account`. - function balanceOf(address account) external view returns (uint256); - - /// @notice Moves `amount` tokens from the caller's account to `to`. - function transfer(address to, uint256 amount) external returns (bool); - - /// @notice Returns the remaining number of tokens that `spender` is allowed - /// to spend on behalf of `owner` - function allowance(address owner, address spender) external view returns (uint256); - - /// @notice Sets `amount` as the allowance of `spender` over the caller's tokens. - /// @dev Be aware of front-running risks: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 - function approve(address spender, uint256 amount) external returns (bool); - - /// @notice Moves `amount` tokens from `from` to `to` using the allowance mechanism. - /// `amount` is then deducted from the caller's allowance. - function transferFrom(address from, address to, uint256 amount) external returns (bool); - - /// @notice Returns the name of the token. - function name() external view returns (string memory); - - /// @notice Returns the symbol of the token. - function symbol() external view returns (string memory); - - /// @notice Returns the decimals places of the token. - function decimals() external view returns (uint8); -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC4626.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC4626.sol deleted file mode 100644 index 1812c6e990..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC4626.sol +++ /dev/null @@ -1,190 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {IERC20} from "./IERC20.sol"; - -/// @dev Interface of the ERC4626 "Tokenized Vault Standard", as defined in -/// https://eips.ethereum.org/EIPS/eip-4626 -interface IERC4626 is IERC20 { - event Deposit(address indexed sender, address indexed owner, uint256 assets, uint256 shares); - - event Withdraw( - address indexed sender, address indexed receiver, address indexed owner, uint256 assets, uint256 shares - ); - - /// @notice Returns the address of the underlying token used for the Vault for accounting, depositing, and withdrawing. - /// @dev - /// - MUST be an ERC-20 token contract. - /// - MUST NOT revert. - function asset() external view returns (address assetTokenAddress); - - /// @notice Returns the total amount of the underlying asset that is “managed” by Vault. - /// @dev - /// - SHOULD include any compounding that occurs from yield. - /// - MUST be inclusive of any fees that are charged against assets in the Vault. - /// - MUST NOT revert. - function totalAssets() external view returns (uint256 totalManagedAssets); - - /// @notice Returns the amount of shares that the Vault would exchange for the amount of assets provided, in an ideal - /// scenario where all the conditions are met. - /// @dev - /// - MUST NOT be inclusive of any fees that are charged against assets in the Vault. - /// - MUST NOT show any variations depending on the caller. - /// - MUST NOT reflect slippage or other on-chain conditions, when performing the actual exchange. - /// - MUST NOT revert. - /// - /// NOTE: This calculation MAY NOT reflect the “per-user” price-per-share, and instead should reflect the - /// “average-user’s” price-per-share, meaning what the average user should expect to see when exchanging to and - /// from. - function convertToShares(uint256 assets) external view returns (uint256 shares); - - /// @notice Returns the amount of assets that the Vault would exchange for the amount of shares provided, in an ideal - /// scenario where all the conditions are met. - /// @dev - /// - MUST NOT be inclusive of any fees that are charged against assets in the Vault. - /// - MUST NOT show any variations depending on the caller. - /// - MUST NOT reflect slippage or other on-chain conditions, when performing the actual exchange. - /// - MUST NOT revert. - /// - /// NOTE: This calculation MAY NOT reflect the “per-user” price-per-share, and instead should reflect the - /// “average-user’s” price-per-share, meaning what the average user should expect to see when exchanging to and - /// from. - function convertToAssets(uint256 shares) external view returns (uint256 assets); - - /// @notice Returns the maximum amount of the underlying asset that can be deposited into the Vault for the receiver, - /// through a deposit call. - /// @dev - /// - MUST return a limited value if receiver is subject to some deposit limit. - /// - MUST return 2 ** 256 - 1 if there is no limit on the maximum amount of assets that may be deposited. - /// - MUST NOT revert. - function maxDeposit(address receiver) external view returns (uint256 maxAssets); - - /// @notice Allows an on-chain or off-chain user to simulate the effects of their deposit at the current block, given - /// current on-chain conditions. - /// @dev - /// - MUST return as close to and no more than the exact amount of Vault shares that would be minted in a deposit - /// call in the same transaction. I.e. deposit should return the same or more shares as previewDeposit if called - /// in the same transaction. - /// - MUST NOT account for deposit limits like those returned from maxDeposit and should always act as though the - /// deposit would be accepted, regardless if the user has enough tokens approved, etc. - /// - MUST be inclusive of deposit fees. Integrators should be aware of the existence of deposit fees. - /// - MUST NOT revert. - /// - /// NOTE: any unfavorable discrepancy between convertToShares and previewDeposit SHOULD be considered slippage in - /// share price or some other type of condition, meaning the depositor will lose assets by depositing. - function previewDeposit(uint256 assets) external view returns (uint256 shares); - - /// @notice Mints shares Vault shares to receiver by depositing exactly amount of underlying tokens. - /// @dev - /// - MUST emit the Deposit event. - /// - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - /// deposit execution, and are accounted for during deposit. - /// - MUST revert if all of assets cannot be deposited (due to deposit limit being reached, slippage, the user not - /// approving enough underlying tokens to the Vault contract, etc). - /// - /// NOTE: most implementations will require pre-approval of the Vault with the Vault’s underlying asset token. - function deposit(uint256 assets, address receiver) external returns (uint256 shares); - - /// @notice Returns the maximum amount of the Vault shares that can be minted for the receiver, through a mint call. - /// @dev - /// - MUST return a limited value if receiver is subject to some mint limit. - /// - MUST return 2 ** 256 - 1 if there is no limit on the maximum amount of shares that may be minted. - /// - MUST NOT revert. - function maxMint(address receiver) external view returns (uint256 maxShares); - - /// @notice Allows an on-chain or off-chain user to simulate the effects of their mint at the current block, given - /// current on-chain conditions. - /// @dev - /// - MUST return as close to and no fewer than the exact amount of assets that would be deposited in a mint call - /// in the same transaction. I.e. mint should return the same or fewer assets as previewMint if called in the - /// same transaction. - /// - MUST NOT account for mint limits like those returned from maxMint and should always act as though the mint - /// would be accepted, regardless if the user has enough tokens approved, etc. - /// - MUST be inclusive of deposit fees. Integrators should be aware of the existence of deposit fees. - /// - MUST NOT revert. - /// - /// NOTE: any unfavorable discrepancy between convertToAssets and previewMint SHOULD be considered slippage in - /// share price or some other type of condition, meaning the depositor will lose assets by minting. - function previewMint(uint256 shares) external view returns (uint256 assets); - - /// @notice Mints exactly shares Vault shares to receiver by depositing amount of underlying tokens. - /// @dev - /// - MUST emit the Deposit event. - /// - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the mint - /// execution, and are accounted for during mint. - /// - MUST revert if all of shares cannot be minted (due to deposit limit being reached, slippage, the user not - /// approving enough underlying tokens to the Vault contract, etc). - /// - /// NOTE: most implementations will require pre-approval of the Vault with the Vault’s underlying asset token. - function mint(uint256 shares, address receiver) external returns (uint256 assets); - - /// @notice Returns the maximum amount of the underlying asset that can be withdrawn from the owner balance in the - /// Vault, through a withdrawal call. - /// @dev - /// - MUST return a limited value if owner is subject to some withdrawal limit or timelock. - /// - MUST NOT revert. - function maxWithdraw(address owner) external view returns (uint256 maxAssets); - - /// @notice Allows an on-chain or off-chain user to simulate the effects of their withdrawal at the current block, - /// given current on-chain conditions. - /// @dev - /// - MUST return as close to and no fewer than the exact amount of Vault shares that would be burned in a withdraw - /// call in the same transaction. I.e. withdraw should return the same or fewer shares as previewWithdraw if - /// called - /// in the same transaction. - /// - MUST NOT account for withdrawal limits like those returned from maxWithdraw and should always act as though - /// the withdrawal would be accepted, regardless if the user has enough shares, etc. - /// - MUST be inclusive of withdrawal fees. Integrators should be aware of the existence of withdrawal fees. - /// - MUST NOT revert. - /// - /// NOTE: any unfavorable discrepancy between convertToShares and previewWithdraw SHOULD be considered slippage in - /// share price or some other type of condition, meaning the depositor will lose assets by depositing. - function previewWithdraw(uint256 assets) external view returns (uint256 shares); - - /// @notice Burns shares from owner and sends exactly assets of underlying tokens to receiver. - /// @dev - /// - MUST emit the Withdraw event. - /// - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - /// withdraw execution, and are accounted for during withdrawal. - /// - MUST revert if all of assets cannot be withdrawn (due to withdrawal limit being reached, slippage, the owner - /// not having enough shares, etc). - /// - /// Note that some implementations will require pre-requesting to the Vault before a withdrawal may be performed. - /// Those methods should be performed separately. - function withdraw(uint256 assets, address receiver, address owner) external returns (uint256 shares); - - /// @notice Returns the maximum amount of Vault shares that can be redeemed from the owner balance in the Vault, - /// through a redeem call. - /// @dev - /// - MUST return a limited value if owner is subject to some withdrawal limit or timelock. - /// - MUST return balanceOf(owner) if owner is not subject to any withdrawal limit or timelock. - /// - MUST NOT revert. - function maxRedeem(address owner) external view returns (uint256 maxShares); - - /// @notice Allows an on-chain or off-chain user to simulate the effects of their redeemption at the current block, - /// given current on-chain conditions. - /// @dev - /// - MUST return as close to and no more than the exact amount of assets that would be withdrawn in a redeem call - /// in the same transaction. I.e. redeem should return the same or more assets as previewRedeem if called in the - /// same transaction. - /// - MUST NOT account for redemption limits like those returned from maxRedeem and should always act as though the - /// redemption would be accepted, regardless if the user has enough shares, etc. - /// - MUST be inclusive of withdrawal fees. Integrators should be aware of the existence of withdrawal fees. - /// - MUST NOT revert. - /// - /// NOTE: any unfavorable discrepancy between convertToAssets and previewRedeem SHOULD be considered slippage in - /// share price or some other type of condition, meaning the depositor will lose assets by redeeming. - function previewRedeem(uint256 shares) external view returns (uint256 assets); - - /// @notice Burns exactly shares from owner and sends assets of underlying tokens to receiver. - /// @dev - /// - MUST emit the Withdraw event. - /// - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - /// redeem execution, and are accounted for during redeem. - /// - MUST revert if all of shares cannot be redeemed (due to withdrawal limit being reached, slippage, the owner - /// not having enough shares, etc). - /// - /// NOTE: some implementations will require pre-requesting to the Vault before a withdrawal may be performed. - /// Those methods should be performed separately. - function redeem(uint256 shares, address receiver, address owner) external returns (uint256 assets); -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC6909.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC6909.sol deleted file mode 100644 index d448b0fa3f..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC6909.sol +++ /dev/null @@ -1,72 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {IERC165} from "./IERC165.sol"; - -/// @dev Required interface of an ERC-6909 compliant contract, as defined in -/// https://eips.ethereum.org/EIPS/eip-6909 -interface IERC6909 is IERC165 { - /// @dev Emitted when the allowance of a `spender` for an `owner` is set for a token of type `id`. - event Approval(address indexed owner, address indexed spender, uint256 indexed id, uint256 amount); - - /// @dev Emitted when `owner` grants or revokes operator status for a `spender`. - event OperatorSet(address indexed owner, address indexed spender, bool approved); - - /// @dev Emitted when `amount` tokens of type `id` are moved from `sender` to `receiver` initiated by `caller`. - event Transfer( - address caller, address indexed sender, address indexed receiver, uint256 indexed id, uint256 amount - ); - - ///@dev Returns the amount of tokens of type `id` owned by `owner`. - function balanceOf(address owner, uint256 id) external view returns (uint256); - - /// @dev Returns the amount of tokens of type `id` that `spender` is allowed to spend on behalf of `owner`. - /// NOTE: Does not include operator allowances. - function allowance(address owner, address spender, uint256 id) external view returns (uint256); - - /// @dev Returns true if `spender` is set as an operator for `owner`. - function isOperator(address owner, address spender) external view returns (bool); - - /// @dev Sets an approval to `spender` for `amount` tokens of type `id` from the caller's tokens. - /// Must return true. - function approve(address spender, uint256 id, uint256 amount) external returns (bool); - - /// @dev Grants or revokes unlimited transfer permission of any token id to `spender` for the caller's tokens. - /// Must return true. - function setOperator(address spender, bool approved) external returns (bool); - - /// @dev Transfers `amount` of token type `id` from the caller's account to `receiver`. - /// Must return true. - function transfer(address receiver, uint256 id, uint256 amount) external returns (bool); - - /// @dev Transfers `amount` of token type `id` from `sender` to `receiver`. - /// Must return true. - function transferFrom(address sender, address receiver, uint256 id, uint256 amount) external returns (bool); -} - -/// @dev Optional extension of {IERC6909} that adds metadata functions. -interface IERC6909Metadata is IERC6909 { - /// @dev Returns the name of the token of type `id`. - function name(uint256 id) external view returns (string memory); - - /// @dev Returns the ticker symbol of the token of type `id`. - function symbol(uint256 id) external view returns (string memory); - - /// @dev Returns the number of decimals for the token of type `id`. - function decimals(uint256 id) external view returns (uint8); -} - -/// @dev Optional extension of {IERC6909} that adds content URI functions. -interface IERC6909ContentURI is IERC6909 { - /// @dev Returns URI for the contract. - function contractURI() external view returns (string memory); - - /// @dev Returns the URI for the token of type `id`. - function tokenURI(uint256 id) external view returns (string memory); -} - -/// @dev Optional extension of {IERC6909} that adds a token supply function. -interface IERC6909TokenSupply is IERC6909 { - /// @dev Returns the total supply of the token of type `id`. - function totalSupply(uint256 id) external view returns (uint256); -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC721.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC721.sol deleted file mode 100644 index 9a03145ac2..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC721.sol +++ /dev/null @@ -1,164 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {IERC165} from "./IERC165.sol"; - -/// @title ERC-721 Non-Fungible Token Standard -/// @dev See https://eips.ethereum.org/EIPS/eip-721 -/// Note: the ERC-165 identifier for this interface is 0x80ac58cd. -interface IERC721 is IERC165 { - /// @dev This emits when ownership of any NFT changes by any mechanism. - /// This event emits when NFTs are created (`from` == 0) and destroyed - /// (`to` == 0). Exception: during contract creation, any number of NFTs - /// may be created and assigned without emitting Transfer. At the time of - /// any transfer, the approved address for that NFT (if any) is reset to none. - event Transfer(address indexed _from, address indexed _to, uint256 indexed _tokenId); - - /// @dev This emits when the approved address for an NFT is changed or - /// reaffirmed. The zero address indicates there is no approved address. - /// When a Transfer event emits, this also indicates that the approved - /// address for that NFT (if any) is reset to none. - event Approval(address indexed _owner, address indexed _approved, uint256 indexed _tokenId); - - /// @dev This emits when an operator is enabled or disabled for an owner. - /// The operator can manage all NFTs of the owner. - event ApprovalForAll(address indexed _owner, address indexed _operator, bool _approved); - - /// @notice Count all NFTs assigned to an owner - /// @dev NFTs assigned to the zero address are considered invalid, and this - /// function throws for queries about the zero address. - /// @param _owner An address for whom to query the balance - /// @return The number of NFTs owned by `_owner`, possibly zero - function balanceOf(address _owner) external view returns (uint256); - - /// @notice Find the owner of an NFT - /// @dev NFTs assigned to zero address are considered invalid, and queries - /// about them do throw. - /// @param _tokenId The identifier for an NFT - /// @return The address of the owner of the NFT - function ownerOf(uint256 _tokenId) external view returns (address); - - /// @notice Transfers the ownership of an NFT from one address to another address - /// @dev Throws unless `msg.sender` is the current owner, an authorized - /// operator, or the approved address for this NFT. Throws if `_from` is - /// not the current owner. Throws if `_to` is the zero address. Throws if - /// `_tokenId` is not a valid NFT. When transfer is complete, this function - /// checks if `_to` is a smart contract (code size > 0). If so, it calls - /// `onERC721Received` on `_to` and throws if the return value is not - /// `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`. - /// @param _from The current owner of the NFT - /// @param _to The new owner - /// @param _tokenId The NFT to transfer - /// @param data Additional data with no specified format, sent in call to `_to` - function safeTransferFrom(address _from, address _to, uint256 _tokenId, bytes calldata data) external payable; - - /// @notice Transfers the ownership of an NFT from one address to another address - /// @dev This works identically to the other function with an extra data parameter, - /// except this function just sets data to "". - /// @param _from The current owner of the NFT - /// @param _to The new owner - /// @param _tokenId The NFT to transfer - function safeTransferFrom(address _from, address _to, uint256 _tokenId) external payable; - - /// @notice Transfer ownership of an NFT -- THE CALLER IS RESPONSIBLE - /// TO CONFIRM THAT `_to` IS CAPABLE OF RECEIVING NFTS OR ELSE - /// THEY MAY BE PERMANENTLY LOST - /// @dev Throws unless `msg.sender` is the current owner, an authorized - /// operator, or the approved address for this NFT. Throws if `_from` is - /// not the current owner. Throws if `_to` is the zero address. Throws if - /// `_tokenId` is not a valid NFT. - /// @param _from The current owner of the NFT - /// @param _to The new owner - /// @param _tokenId The NFT to transfer - function transferFrom(address _from, address _to, uint256 _tokenId) external payable; - - /// @notice Change or reaffirm the approved address for an NFT - /// @dev The zero address indicates there is no approved address. - /// Throws unless `msg.sender` is the current NFT owner, or an authorized - /// operator of the current owner. - /// @param _approved The new approved NFT controller - /// @param _tokenId The NFT to approve - function approve(address _approved, uint256 _tokenId) external payable; - - /// @notice Enable or disable approval for a third party ("operator") to manage - /// all of `msg.sender`'s assets - /// @dev Emits the ApprovalForAll event. The contract MUST allow - /// multiple operators per owner. - /// @param _operator Address to add to the set of authorized operators - /// @param _approved True if the operator is approved, false to revoke approval - function setApprovalForAll(address _operator, bool _approved) external; - - /// @notice Get the approved address for a single NFT - /// @dev Throws if `_tokenId` is not a valid NFT. - /// @param _tokenId The NFT to find the approved address for - /// @return The approved address for this NFT, or the zero address if there is none - function getApproved(uint256 _tokenId) external view returns (address); - - /// @notice Query if an address is an authorized operator for another address - /// @param _owner The address that owns the NFTs - /// @param _operator The address that acts on behalf of the owner - /// @return True if `_operator` is an approved operator for `_owner`, false otherwise - function isApprovedForAll(address _owner, address _operator) external view returns (bool); -} - -/// @dev Note: the ERC-165 identifier for this interface is 0x150b7a02. -interface IERC721TokenReceiver { - /// @notice Handle the receipt of an NFT - /// @dev The ERC721 smart contract calls this function on the recipient - /// after a `transfer`. This function MAY throw to revert and reject the - /// transfer. Return of other than the magic value MUST result in the - /// transaction being reverted. - /// Note: the contract address is always the message sender. - /// @param _operator The address which called `safeTransferFrom` function - /// @param _from The address which previously owned the token - /// @param _tokenId The NFT identifier which is being transferred - /// @param _data Additional data with no specified format - /// @return `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))` - /// unless throwing - function onERC721Received(address _operator, address _from, uint256 _tokenId, bytes calldata _data) - external - returns (bytes4); -} - -/// @title ERC-721 Non-Fungible Token Standard, optional metadata extension -/// @dev See https://eips.ethereum.org/EIPS/eip-721 -/// Note: the ERC-165 identifier for this interface is 0x5b5e139f. -interface IERC721Metadata is IERC721 { - /// @notice A descriptive name for a collection of NFTs in this contract - function name() external view returns (string memory _name); - - /// @notice An abbreviated name for NFTs in this contract - function symbol() external view returns (string memory _symbol); - - /// @notice A distinct Uniform Resource Identifier (URI) for a given asset. - /// @dev Throws if `_tokenId` is not a valid NFT. URIs are defined in RFC - /// 3986. The URI may point to a JSON file that conforms to the "ERC721 - /// Metadata JSON Schema". - function tokenURI(uint256 _tokenId) external view returns (string memory); -} - -/// @title ERC-721 Non-Fungible Token Standard, optional enumeration extension -/// @dev See https://eips.ethereum.org/EIPS/eip-721 -/// Note: the ERC-165 identifier for this interface is 0x780e9d63. -interface IERC721Enumerable is IERC721 { - /// @notice Count NFTs tracked by this contract - /// @return A count of valid NFTs tracked by this contract, where each one of - /// them has an assigned and queryable owner not equal to the zero address - function totalSupply() external view returns (uint256); - - /// @notice Enumerate valid NFTs - /// @dev Throws if `_index` >= `totalSupply()`. - /// @param _index A counter less than `totalSupply()` - /// @return The token identifier for the `_index`th NFT, - /// (sort order not specified) - function tokenByIndex(uint256 _index) external view returns (uint256); - - /// @notice Enumerate NFTs assigned to an owner - /// @dev Throws if `_index` >= `balanceOf(_owner)` or if - /// `_owner` is the zero address, representing invalid NFTs. - /// @param _owner An address where we are interested in NFTs owned by them - /// @param _index A counter less than `balanceOf(_owner)` - /// @return The token identifier for the `_index`th NFT assigned to `_owner`, - /// (sort order not specified) - function tokenOfOwnerByIndex(address _owner, uint256 _index) external view returns (uint256); -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC7540.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC7540.sol deleted file mode 100644 index 4cb0859246..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC7540.sol +++ /dev/null @@ -1,144 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {IERC7575} from "./IERC7575.sol"; - -/// @dev Interface of the base operator logic of ERC7540, as defined in -/// https://eips.ethereum.org/EIPS/eip-7540 -interface IERC7540Operator { - /** - * @dev The event emitted when an operator is set. - * - * @param controller The address of the controller. - * @param operator The address of the operator. - * @param approved The approval status. - */ - event OperatorSet(address indexed controller, address indexed operator, bool approved); - - /** - * @dev Sets or removes an operator for the caller. - * - * @param operator The address of the operator. - * @param approved The approval status. - * @return Whether the call was executed successfully or not - */ - function setOperator(address operator, bool approved) external returns (bool); - - /** - * @dev Returns `true` if the `operator` is approved as an operator for an `controller`. - * - * @param controller The address of the controller. - * @param operator The address of the operator. - * @return status The approval status - */ - function isOperator(address controller, address operator) external view returns (bool status); -} - -/// @dev Interface of the asynchronous deposit Vault interface of ERC7540, as defined in -/// https://eips.ethereum.org/EIPS/eip-7540 -interface IERC7540Deposit is IERC7540Operator { - event DepositRequest( - address indexed controller, address indexed owner, uint256 indexed requestId, address sender, uint256 assets - ); - /** - * @dev Transfers assets from sender into the Vault and submits a Request for asynchronous deposit. - * - * - MUST support ERC-20 approve / transferFrom on asset as a deposit Request flow. - * - MUST revert if all of assets cannot be requested for deposit. - * - owner MUST be msg.sender unless some unspecified explicit approval is given by the caller, - * approval of ERC-20 tokens from owner to sender is NOT enough. - * - * @param assets the amount of deposit assets to transfer from owner - * @param controller the controller of the request who will be able to operate the request - * @param owner the source of the deposit assets - * - * NOTE: most implementations will require pre-approval of the Vault with the Vault's underlying asset token. - */ - - function requestDeposit(uint256 assets, address controller, address owner) external returns (uint256 requestId); - - /** - * @dev Returns the amount of requested assets in Pending state. - * - * - MUST NOT include any assets in Claimable state for deposit or mint. - * - MUST NOT show any variations depending on the caller. - * - MUST NOT revert unless due to integer overflow caused by an unreasonably large input. - */ - function pendingDepositRequest(uint256 requestId, address controller) external view returns (uint256 pendingAssets); - - /** - * @dev Returns the amount of requested assets in Claimable state for the controller to deposit or mint. - * - * - MUST NOT include any assets in Pending state. - * - MUST NOT show any variations depending on the caller. - * - MUST NOT revert unless due to integer overflow caused by an unreasonably large input. - */ - function claimableDepositRequest(uint256 requestId, address controller) - external - view - returns (uint256 claimableAssets); - - /** - * @dev Mints shares Vault shares to receiver by claiming the Request of the controller. - * - * - MUST emit the Deposit event. - * - controller MUST equal msg.sender unless the controller has approved the msg.sender as an operator. - */ - function deposit(uint256 assets, address receiver, address controller) external returns (uint256 shares); - - /** - * @dev Mints exactly shares Vault shares to receiver by claiming the Request of the controller. - * - * - MUST emit the Deposit event. - * - controller MUST equal msg.sender unless the controller has approved the msg.sender as an operator. - */ - function mint(uint256 shares, address receiver, address controller) external returns (uint256 assets); -} - -/// @dev Interface of the asynchronous deposit Vault interface of ERC7540, as defined in -/// https://eips.ethereum.org/EIPS/eip-7540 -interface IERC7540Redeem is IERC7540Operator { - event RedeemRequest( - address indexed controller, address indexed owner, uint256 indexed requestId, address sender, uint256 assets - ); - - /** - * @dev Assumes control of shares from sender into the Vault and submits a Request for asynchronous redeem. - * - * - MUST support a redeem Request flow where the control of shares is taken from sender directly - * where msg.sender has ERC-20 approval over the shares of owner. - * - MUST revert if all of shares cannot be requested for redeem. - * - * @param shares the amount of shares to be redeemed to transfer from owner - * @param controller the controller of the request who will be able to operate the request - * @param owner the source of the shares to be redeemed - * - * NOTE: most implementations will require pre-approval of the Vault with the Vault's share token. - */ - function requestRedeem(uint256 shares, address controller, address owner) external returns (uint256 requestId); - - /** - * @dev Returns the amount of requested shares in Pending state. - * - * - MUST NOT include any shares in Claimable state for redeem or withdraw. - * - MUST NOT show any variations depending on the caller. - * - MUST NOT revert unless due to integer overflow caused by an unreasonably large input. - */ - function pendingRedeemRequest(uint256 requestId, address controller) external view returns (uint256 pendingShares); - - /** - * @dev Returns the amount of requested shares in Claimable state for the controller to redeem or withdraw. - * - * - MUST NOT include any shares in Pending state for redeem or withdraw. - * - MUST NOT show any variations depending on the caller. - * - MUST NOT revert unless due to integer overflow caused by an unreasonably large input. - */ - function claimableRedeemRequest(uint256 requestId, address controller) - external - view - returns (uint256 claimableShares); -} - -/// @dev Interface of the fully asynchronous Vault interface of ERC7540, as defined in -/// https://eips.ethereum.org/EIPS/eip-7540 -interface IERC7540 is IERC7540Deposit, IERC7540Redeem, IERC7575 {} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC7575.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC7575.sol deleted file mode 100644 index 4d9d03c80e..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IERC7575.sol +++ /dev/null @@ -1,241 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {IERC165} from "./IERC165.sol"; - -/// @dev Interface of the ERC7575 "Multi-Asset ERC-4626 Vaults", as defined in -/// https://eips.ethereum.org/EIPS/eip-7575 -interface IERC7575 is IERC165 { - event Deposit(address indexed sender, address indexed owner, uint256 assets, uint256 shares); - event Withdraw( - address indexed sender, address indexed receiver, address indexed owner, uint256 assets, uint256 shares - ); - - /** - * @dev Returns the address of the underlying token used for the Vault for accounting, depositing, and withdrawing. - * - * - MUST be an ERC-20 token contract. - * - MUST NOT revert. - */ - function asset() external view returns (address assetTokenAddress); - - /** - * @dev Returns the address of the share token - * - * - MUST be an ERC-20 token contract. - * - MUST NOT revert. - */ - function share() external view returns (address shareTokenAddress); - - /** - * @dev Returns the amount of shares that the Vault would exchange for the amount of assets provided, in an ideal - * scenario where all the conditions are met. - * - * - MUST NOT be inclusive of any fees that are charged against assets in the Vault. - * - MUST NOT show any variations depending on the caller. - * - MUST NOT reflect slippage or other on-chain conditions, when performing the actual exchange. - * - MUST NOT revert. - * - * NOTE: This calculation MAY NOT reflect the “per-user” price-per-share, and instead should reflect the - * “average-user’s” price-per-share, meaning what the average user should expect to see when exchanging to and - * from. - */ - function convertToShares(uint256 assets) external view returns (uint256 shares); - - /** - * @dev Returns the amount of assets that the Vault would exchange for the amount of shares provided, in an ideal - * scenario where all the conditions are met. - * - * - MUST NOT be inclusive of any fees that are charged against assets in the Vault. - * - MUST NOT show any variations depending on the caller. - * - MUST NOT reflect slippage or other on-chain conditions, when performing the actual exchange. - * - MUST NOT revert. - * - * NOTE: This calculation MAY NOT reflect the “per-user” price-per-share, and instead should reflect the - * “average-user’s” price-per-share, meaning what the average user should expect to see when exchanging to and - * from. - */ - function convertToAssets(uint256 shares) external view returns (uint256 assets); - - /** - * @dev Returns the total amount of the underlying asset that is “managed” by Vault. - * - * - SHOULD include any compounding that occurs from yield. - * - MUST be inclusive of any fees that are charged against assets in the Vault. - * - MUST NOT revert. - */ - function totalAssets() external view returns (uint256 totalManagedAssets); - - /** - * @dev Returns the maximum amount of the underlying asset that can be deposited into the Vault for the receiver, - * through a deposit call. - * - * - MUST return a limited value if receiver is subject to some deposit limit. - * - MUST return 2 ** 256 - 1 if there is no limit on the maximum amount of assets that may be deposited. - * - MUST NOT revert. - */ - function maxDeposit(address receiver) external view returns (uint256 maxAssets); - - /** - * @dev Allows an on-chain or off-chain user to simulate the effects of their deposit at the current block, given - * current on-chain conditions. - * - * - MUST return as close to and no more than the exact amount of Vault shares that would be minted in a deposit - * call in the same transaction. I.e. deposit should return the same or more shares as previewDeposit if called - * in the same transaction. - * - MUST NOT account for deposit limits like those returned from maxDeposit and should always act as though the - * deposit would be accepted, regardless if the user has enough tokens approved, etc. - * - MUST be inclusive of deposit fees. Integrators should be aware of the existence of deposit fees. - * - MUST NOT revert. - * - * NOTE: any unfavorable discrepancy between convertToShares and previewDeposit SHOULD be considered slippage in - * share price or some other type of condition, meaning the depositor will lose assets by depositing. - */ - function previewDeposit(uint256 assets) external view returns (uint256 shares); - - /** - * @dev Mints shares Vault shares to receiver by depositing exactly amount of underlying tokens. - * - * - MUST emit the Deposit event. - * - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - * deposit execution, and are accounted for during deposit. - * - MUST revert if all of assets cannot be deposited (due to deposit limit being reached, slippage, the user not - * approving enough underlying tokens to the Vault contract, etc). - * - * NOTE: most implementations will require pre-approval of the Vault with the Vault’s underlying asset token. - */ - function deposit(uint256 assets, address receiver) external returns (uint256 shares); - - /** - * @dev Returns the maximum amount of the Vault shares that can be minted for the receiver, through a mint call. - * - MUST return a limited value if receiver is subject to some mint limit. - * - MUST return 2 ** 256 - 1 if there is no limit on the maximum amount of shares that may be minted. - * - MUST NOT revert. - */ - function maxMint(address receiver) external view returns (uint256 maxShares); - - /** - * @dev Allows an on-chain or off-chain user to simulate the effects of their mint at the current block, given - * current on-chain conditions. - * - * - MUST return as close to and no fewer than the exact amount of assets that would be deposited in a mint call - * in the same transaction. I.e. mint should return the same or fewer assets as previewMint if called in the - * same transaction. - * - MUST NOT account for mint limits like those returned from maxMint and should always act as though the mint - * would be accepted, regardless if the user has enough tokens approved, etc. - * - MUST be inclusive of deposit fees. Integrators should be aware of the existence of deposit fees. - * - MUST NOT revert. - * - * NOTE: any unfavorable discrepancy between convertToAssets and previewMint SHOULD be considered slippage in - * share price or some other type of condition, meaning the depositor will lose assets by minting. - */ - function previewMint(uint256 shares) external view returns (uint256 assets); - - /** - * @dev Mints exactly shares Vault shares to receiver by depositing amount of underlying tokens. - * - * - MUST emit the Deposit event. - * - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the mint - * execution, and are accounted for during mint. - * - MUST revert if all of shares cannot be minted (due to deposit limit being reached, slippage, the user not - * approving enough underlying tokens to the Vault contract, etc). - * - * NOTE: most implementations will require pre-approval of the Vault with the Vault’s underlying asset token. - */ - function mint(uint256 shares, address receiver) external returns (uint256 assets); - - /** - * @dev Returns the maximum amount of the underlying asset that can be withdrawn from the owner balance in the - * Vault, through a withdraw call. - * - * - MUST return a limited value if owner is subject to some withdrawal limit or timelock. - * - MUST NOT revert. - */ - function maxWithdraw(address owner) external view returns (uint256 maxAssets); - - /** - * @dev Allows an on-chain or off-chain user to simulate the effects of their withdrawal at the current block, - * given current on-chain conditions. - * - * - MUST return as close to and no fewer than the exact amount of Vault shares that would be burned in a withdraw - * call in the same transaction. I.e. withdraw should return the same or fewer shares as previewWithdraw if - * called - * in the same transaction. - * - MUST NOT account for withdrawal limits like those returned from maxWithdraw and should always act as though - * the withdrawal would be accepted, regardless if the user has enough shares, etc. - * - MUST be inclusive of withdrawal fees. Integrators should be aware of the existence of withdrawal fees. - * - MUST NOT revert. - * - * NOTE: any unfavorable discrepancy between convertToShares and previewWithdraw SHOULD be considered slippage in - * share price or some other type of condition, meaning the depositor will lose assets by depositing. - */ - function previewWithdraw(uint256 assets) external view returns (uint256 shares); - - /** - * @dev Burns shares from owner and sends exactly assets of underlying tokens to receiver. - * - * - MUST emit the Withdraw event. - * - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - * withdraw execution, and are accounted for during withdraw. - * - MUST revert if all of assets cannot be withdrawn (due to withdrawal limit being reached, slippage, the owner - * not having enough shares, etc). - * - * Note that some implementations will require pre-requesting to the Vault before a withdrawal may be performed. - * Those methods should be performed separately. - */ - function withdraw(uint256 assets, address receiver, address owner) external returns (uint256 shares); - - /** - * @dev Returns the maximum amount of Vault shares that can be redeemed from the owner balance in the Vault, - * through a redeem call. - * - * - MUST return a limited value if owner is subject to some withdrawal limit or timelock. - * - MUST return balanceOf(owner) if owner is not subject to any withdrawal limit or timelock. - * - MUST NOT revert. - */ - function maxRedeem(address owner) external view returns (uint256 maxShares); - - /** - * @dev Allows an on-chain or off-chain user to simulate the effects of their redeemption at the current block, - * given current on-chain conditions. - * - * - MUST return as close to and no more than the exact amount of assets that would be withdrawn in a redeem call - * in the same transaction. I.e. redeem should return the same or more assets as previewRedeem if called in the - * same transaction. - * - MUST NOT account for redemption limits like those returned from maxRedeem and should always act as though the - * redemption would be accepted, regardless if the user has enough shares, etc. - * - MUST be inclusive of withdrawal fees. Integrators should be aware of the existence of withdrawal fees. - * - MUST NOT revert. - * - * NOTE: any unfavorable discrepancy between convertToAssets and previewRedeem SHOULD be considered slippage in - * share price or some other type of condition, meaning the depositor will lose assets by redeeming. - */ - function previewRedeem(uint256 shares) external view returns (uint256 assets); - - /** - * @dev Burns exactly shares from owner and sends assets of underlying tokens to receiver. - * - * - MUST emit the Withdraw event. - * - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - * redeem execution, and are accounted for during redeem. - * - MUST revert if all of shares cannot be redeemed (due to withdrawal limit being reached, slippage, the owner - * not having enough shares, etc). - * - * NOTE: some implementations will require pre-requesting to the Vault before a withdrawal may be performed. - * Those methods should be performed separately. - */ - function redeem(uint256 shares, address receiver, address owner) external returns (uint256 assets); -} - -/// @dev Interface of the ERC20 share token, as defined in -/// https://eips.ethereum.org/EIPS/eip-7575 -interface IERC7575Share is IERC165 { - event VaultUpdate(address indexed asset, address vault); - - /** - * @dev Returns the address of the Vault for the given asset. - * - * @param asset the ERC-20 token to deposit with into the Vault - */ - function vault(address asset) external view returns (address); -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IMulticall3.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IMulticall3.sol deleted file mode 100644 index 6a94133e06..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/interfaces/IMulticall3.sol +++ /dev/null @@ -1,68 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -interface IMulticall3 { - struct Call { - address target; - bytes callData; - } - - struct Call3 { - address target; - bool allowFailure; - bytes callData; - } - - struct Call3Value { - address target; - bool allowFailure; - uint256 value; - bytes callData; - } - - struct Result { - bool success; - bytes returnData; - } - - function aggregate(Call[] calldata calls) external payable returns (uint256 blockNumber, bytes[] memory returnData); - - function aggregate3(Call3[] calldata calls) external payable returns (Result[] memory returnData); - - function aggregate3Value(Call3Value[] calldata calls) external payable returns (Result[] memory returnData); - - function blockAndAggregate(Call[] calldata calls) - external - payable - returns (uint256 blockNumber, bytes32 blockHash, Result[] memory returnData); - - function getBasefee() external view returns (uint256 basefee); - - function getBlockHash(uint256 blockNumber) external view returns (bytes32 blockHash); - - function getBlockNumber() external view returns (uint256 blockNumber); - - function getChainId() external view returns (uint256 chainid); - - function getCurrentBlockCoinbase() external view returns (address coinbase); - - function getCurrentBlockDifficulty() external view returns (uint256 difficulty); - - function getCurrentBlockGasLimit() external view returns (uint256 gaslimit); - - function getCurrentBlockTimestamp() external view returns (uint256 timestamp); - - function getEthBalance(address addr) external view returns (uint256 balance); - - function getLastBlockHash() external view returns (bytes32 blockHash); - - function tryAggregate(bool requireSuccess, Call[] calldata calls) - external - payable - returns (Result[] memory returnData); - - function tryBlockAndAggregate(bool requireSuccess, Call[] calldata calls) - external - payable - returns (uint256 blockNumber, bytes32 blockHash, Result[] memory returnData); -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/safeconsole.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/safeconsole.sol deleted file mode 100644 index e12d0600a3..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/src/safeconsole.sol +++ /dev/null @@ -1,13248 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -/// @author philogy -/// @dev Code generated automatically by script. -library safeconsole { - uint256 constant CONSOLE_ADDR = 0x000000000000000000000000000000000000000000636F6e736F6c652e6c6f67; - - // Credit to [0age](https://twitter.com/z0age/status/1654922202930888704) and [0xdapper](https://github.com/foundry-rs/forge-std/pull/374) - // for the view-to-pure log trick. - function _sendLogPayload(uint256 offset, uint256 size) private pure { - function(uint256, uint256) internal view fnIn = _sendLogPayloadView; - function(uint256, uint256) internal pure pureSendLogPayload; - assembly ("memory-safe") { - pureSendLogPayload := fnIn - } - pureSendLogPayload(offset, size); - } - - function _sendLogPayloadView(uint256 offset, uint256 size) private view { - assembly ("memory-safe") { - pop(staticcall(gas(), CONSOLE_ADDR, offset, size, 0x0, 0x0)) - } - } - - function _memcopy(uint256 fromOffset, uint256 toOffset, uint256 length) private pure { - function(uint256, uint256, uint256) internal view fnIn = _memcopyView; - function(uint256, uint256, uint256) internal pure pureMemcopy; - assembly ("memory-safe") { - pureMemcopy := fnIn - } - pureMemcopy(fromOffset, toOffset, length); - } - - function _memcopyView(uint256 fromOffset, uint256 toOffset, uint256 length) private view { - assembly ("memory-safe") { - pop(staticcall(gas(), 0x4, fromOffset, length, toOffset, length)) - } - } - - function logMemory(uint256 offset, uint256 length) internal pure { - if (offset >= 0x60) { - // Sufficient memory before slice to prepare call header. - bytes32 m0; - bytes32 m1; - bytes32 m2; - assembly ("memory-safe") { - m0 := mload(sub(offset, 0x60)) - m1 := mload(sub(offset, 0x40)) - m2 := mload(sub(offset, 0x20)) - // Selector of `log(bytes)`. - mstore(sub(offset, 0x60), 0x0be77f56) - mstore(sub(offset, 0x40), 0x20) - mstore(sub(offset, 0x20), length) - } - _sendLogPayload(offset - 0x44, length + 0x44); - assembly ("memory-safe") { - mstore(sub(offset, 0x60), m0) - mstore(sub(offset, 0x40), m1) - mstore(sub(offset, 0x20), m2) - } - } else { - // Insufficient space, so copy slice forward, add header and reverse. - bytes32 m0; - bytes32 m1; - bytes32 m2; - uint256 endOffset = offset + length; - assembly ("memory-safe") { - m0 := mload(add(endOffset, 0x00)) - m1 := mload(add(endOffset, 0x20)) - m2 := mload(add(endOffset, 0x40)) - } - _memcopy(offset, offset + 0x60, length); - assembly ("memory-safe") { - // Selector of `log(bytes)`. - mstore(add(offset, 0x00), 0x0be77f56) - mstore(add(offset, 0x20), 0x20) - mstore(add(offset, 0x40), length) - } - _sendLogPayload(offset + 0x1c, length + 0x44); - _memcopy(offset + 0x60, offset, length); - assembly ("memory-safe") { - mstore(add(endOffset, 0x00), m0) - mstore(add(endOffset, 0x20), m1) - mstore(add(endOffset, 0x40), m2) - } - } - } - - function log(address p0) internal pure { - bytes32 m0; - bytes32 m1; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - // Selector of `log(address)`. - mstore(0x00, 0x2c2ecbc2) - mstore(0x20, p0) - } - _sendLogPayload(0x1c, 0x24); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - } - } - - function log(bool p0) internal pure { - bytes32 m0; - bytes32 m1; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - // Selector of `log(bool)`. - mstore(0x00, 0x32458eed) - mstore(0x20, p0) - } - _sendLogPayload(0x1c, 0x24); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - } - } - - function log(uint256 p0) internal pure { - bytes32 m0; - bytes32 m1; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - // Selector of `log(uint256)`. - mstore(0x00, 0xf82c50f1) - mstore(0x20, p0) - } - _sendLogPayload(0x1c, 0x24); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - } - } - - function log(bytes32 p0) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(string)`. - mstore(0x00, 0x41304fac) - mstore(0x20, 0x20) - writeString(0x40, p0) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, address p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(address,address)`. - mstore(0x00, 0xdaf0d4aa) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(address p0, bool p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(address,bool)`. - mstore(0x00, 0x75b605d3) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(address p0, uint256 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(address,uint256)`. - mstore(0x00, 0x8309e8a8) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(address p0, bytes32 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,string)`. - mstore(0x00, 0x759f86bb) - mstore(0x20, p0) - mstore(0x40, 0x40) - writeString(0x60, p1) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(bool,address)`. - mstore(0x00, 0x853c4849) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(bool p0, bool p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(bool,bool)`. - mstore(0x00, 0x2a110e83) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(bool p0, uint256 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(bool,uint256)`. - mstore(0x00, 0x399174d3) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(bool p0, bytes32 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,string)`. - mstore(0x00, 0x8feac525) - mstore(0x20, p0) - mstore(0x40, 0x40) - writeString(0x60, p1) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(uint256,address)`. - mstore(0x00, 0x69276c86) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(uint256 p0, bool p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(uint256,bool)`. - mstore(0x00, 0x1c9d7eb3) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(uint256 p0, uint256 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(uint256,uint256)`. - mstore(0x00, 0xf666715a) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(uint256 p0, bytes32 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,string)`. - mstore(0x00, 0x643fd0df) - mstore(0x20, p0) - mstore(0x40, 0x40) - writeString(0x60, p1) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bytes32 p0, address p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(string,address)`. - mstore(0x00, 0x319af333) - mstore(0x20, 0x40) - mstore(0x40, p1) - writeString(0x60, p0) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bytes32 p0, bool p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(string,bool)`. - mstore(0x00, 0xc3b55635) - mstore(0x20, 0x40) - mstore(0x40, p1) - writeString(0x60, p0) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bytes32 p0, uint256 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(string,uint256)`. - mstore(0x00, 0xb60e72cc) - mstore(0x20, 0x40) - mstore(0x40, p1) - writeString(0x60, p0) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bytes32 p0, bytes32 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,string)`. - mstore(0x00, 0x4b5c4277) - mstore(0x20, 0x40) - mstore(0x40, 0x80) - writeString(0x60, p0) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,address,address)`. - mstore(0x00, 0x018c84c2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, address p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,address,bool)`. - mstore(0x00, 0xf2a66286) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, address p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,address,uint256)`. - mstore(0x00, 0x17fe6185) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, address p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,address,string)`. - mstore(0x00, 0x007150be) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bool p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,bool,address)`. - mstore(0x00, 0xf11699ed) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, bool p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,bool,bool)`. - mstore(0x00, 0xeb830c92) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, bool p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,bool,uint256)`. - mstore(0x00, 0x9c4f99fb) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, bool p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,bool,string)`. - mstore(0x00, 0x212255cc) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, uint256 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,uint256,address)`. - mstore(0x00, 0x7bc0d848) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, uint256 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,uint256,bool)`. - mstore(0x00, 0x678209a8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, uint256 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,uint256,uint256)`. - mstore(0x00, 0xb69bcaf6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, uint256 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,uint256,string)`. - mstore(0x00, 0xa1f2e8aa) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bytes32 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,string,address)`. - mstore(0x00, 0xf08744e8) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bytes32 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,string,bool)`. - mstore(0x00, 0xcf020fb1) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bytes32 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,string,uint256)`. - mstore(0x00, 0x67dd6ff1) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bytes32 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(address,string,string)`. - mstore(0x00, 0xfb772265) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, 0xa0) - writeString(0x80, p1) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bool p0, address p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,address,address)`. - mstore(0x00, 0xd2763667) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, address p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,address,bool)`. - mstore(0x00, 0x18c9c746) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, address p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,address,uint256)`. - mstore(0x00, 0x5f7b9afb) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, address p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,address,string)`. - mstore(0x00, 0xde9a9270) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bool p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,bool,address)`. - mstore(0x00, 0x1078f68d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, bool p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,bool,bool)`. - mstore(0x00, 0x50709698) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, bool p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,bool,uint256)`. - mstore(0x00, 0x12f21602) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, bool p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,bool,string)`. - mstore(0x00, 0x2555fa46) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, uint256 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,uint256,address)`. - mstore(0x00, 0x088ef9d2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, uint256 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,uint256,bool)`. - mstore(0x00, 0xe8defba9) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, uint256 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,uint256,uint256)`. - mstore(0x00, 0x37103367) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, uint256 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,uint256,string)`. - mstore(0x00, 0xc3fc3970) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bytes32 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,string,address)`. - mstore(0x00, 0x9591b953) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bytes32 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,string,bool)`. - mstore(0x00, 0xdbb4c247) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bytes32 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,string,uint256)`. - mstore(0x00, 0x1093ee11) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(bool,string,string)`. - mstore(0x00, 0xb076847f) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, 0xa0) - writeString(0x80, p1) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(uint256 p0, address p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,address,address)`. - mstore(0x00, 0xbcfd9be0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, address p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,address,bool)`. - mstore(0x00, 0x9b6ec042) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, address p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,address,uint256)`. - mstore(0x00, 0x5a9b5ed5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, address p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,address,string)`. - mstore(0x00, 0x63cb41f9) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bool p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,bool,address)`. - mstore(0x00, 0x35085f7b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, bool p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,bool,bool)`. - mstore(0x00, 0x20718650) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, bool p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,bool,uint256)`. - mstore(0x00, 0x20098014) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, bool p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,bool,string)`. - mstore(0x00, 0x85775021) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, uint256 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,uint256,address)`. - mstore(0x00, 0x5c96b331) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, uint256 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,uint256,bool)`. - mstore(0x00, 0x4766da72) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,uint256,uint256)`. - mstore(0x00, 0xd1ed7a3c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,uint256,string)`. - mstore(0x00, 0x71d04af2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bytes32 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,string,address)`. - mstore(0x00, 0x7afac959) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bytes32 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,string,bool)`. - mstore(0x00, 0x4ceda75a) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,string,uint256)`. - mstore(0x00, 0x37aa7d4c) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(uint256,string,string)`. - mstore(0x00, 0xb115611f) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, 0xa0) - writeString(0x80, p1) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, address p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,address,address)`. - mstore(0x00, 0xfcec75e0) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, address p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,address,bool)`. - mstore(0x00, 0xc91d5ed4) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, address p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,address,uint256)`. - mstore(0x00, 0x0d26b925) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, address p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,address,string)`. - mstore(0x00, 0xe0e9ad4f) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, 0xa0) - writeString(0x80, p0) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bool p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,bool,address)`. - mstore(0x00, 0x932bbb38) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, bool p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,bool,bool)`. - mstore(0x00, 0x850b7ad6) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, bool p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,bool,uint256)`. - mstore(0x00, 0xc95958d6) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,bool,string)`. - mstore(0x00, 0xe298f47d) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, 0xa0) - writeString(0x80, p0) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, uint256 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,uint256,address)`. - mstore(0x00, 0x1c7ec448) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, uint256 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,uint256,bool)`. - mstore(0x00, 0xca7733b1) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,uint256,uint256)`. - mstore(0x00, 0xca47c4eb) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,uint256,string)`. - mstore(0x00, 0x5970e089) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, 0xa0) - writeString(0x80, p0) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bytes32 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,string,address)`. - mstore(0x00, 0x95ed0195) - mstore(0x20, 0x60) - mstore(0x40, 0xa0) - mstore(0x60, p2) - writeString(0x80, p0) - writeString(0xc0, p1) - } - _sendLogPayload(0x1c, 0xe4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,string,bool)`. - mstore(0x00, 0xb0e0f9b5) - mstore(0x20, 0x60) - mstore(0x40, 0xa0) - mstore(0x60, p2) - writeString(0x80, p0) - writeString(0xc0, p1) - } - _sendLogPayload(0x1c, 0xe4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,string,uint256)`. - mstore(0x00, 0x5821efa1) - mstore(0x20, 0x60) - mstore(0x40, 0xa0) - mstore(0x60, p2) - writeString(0x80, p0) - writeString(0xc0, p1) - } - _sendLogPayload(0x1c, 0xe4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - // Selector of `log(string,string,string)`. - mstore(0x00, 0x2ced7cef) - mstore(0x20, 0x60) - mstore(0x40, 0xa0) - mstore(0x60, 0xe0) - writeString(0x80, p0) - writeString(0xc0, p1) - writeString(0x100, p2) - } - _sendLogPayload(0x1c, 0x124); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - } - } - - function log(address p0, address p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,address,address)`. - mstore(0x00, 0x665bf134) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,address,bool)`. - mstore(0x00, 0x0e378994) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,address,uint256)`. - mstore(0x00, 0x94250d77) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,address,string)`. - mstore(0x00, 0xf808da20) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,bool,address)`. - mstore(0x00, 0x9f1bc36e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,bool,bool)`. - mstore(0x00, 0x2cd4134a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,bool,uint256)`. - mstore(0x00, 0x3971e78c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,bool,string)`. - mstore(0x00, 0xaa6540c8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,uint256,address)`. - mstore(0x00, 0x8da6def5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,uint256,bool)`. - mstore(0x00, 0x9b4254e2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,uint256,uint256)`. - mstore(0x00, 0xbe553481) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,uint256,string)`. - mstore(0x00, 0xfdb4f990) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,string,address)`. - mstore(0x00, 0x8f736d16) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,string,bool)`. - mstore(0x00, 0x6f1a594e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,string,uint256)`. - mstore(0x00, 0xef1cefe7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,address,string,string)`. - mstore(0x00, 0x21bdaf25) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bool p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,address,address)`. - mstore(0x00, 0x660375dd) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,address,bool)`. - mstore(0x00, 0xa6f50b0f) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,address,uint256)`. - mstore(0x00, 0xa75c59de) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,address,string)`. - mstore(0x00, 0x2dd778e6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,bool,address)`. - mstore(0x00, 0xcf394485) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,bool,bool)`. - mstore(0x00, 0xcac43479) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,bool,uint256)`. - mstore(0x00, 0x8c4e5de6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,bool,string)`. - mstore(0x00, 0xdfc4a2e8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,uint256,address)`. - mstore(0x00, 0xccf790a1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,uint256,bool)`. - mstore(0x00, 0xc4643e20) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,uint256,uint256)`. - mstore(0x00, 0x386ff5f4) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,uint256,string)`. - mstore(0x00, 0x0aa6cfad) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,string,address)`. - mstore(0x00, 0x19fd4956) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,string,bool)`. - mstore(0x00, 0x50ad461d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,string,uint256)`. - mstore(0x00, 0x80e6a20b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,bool,string,string)`. - mstore(0x00, 0x475c5c33) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, uint256 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,address,address)`. - mstore(0x00, 0x478d1c62) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,address,bool)`. - mstore(0x00, 0xa1bcc9b3) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,address,uint256)`. - mstore(0x00, 0x100f650e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,address,string)`. - mstore(0x00, 0x1da986ea) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,bool,address)`. - mstore(0x00, 0xa31bfdcc) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,bool,bool)`. - mstore(0x00, 0x3bf5e537) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,bool,uint256)`. - mstore(0x00, 0x22f6b999) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,bool,string)`. - mstore(0x00, 0xc5ad85f9) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,uint256,address)`. - mstore(0x00, 0x20e3984d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,uint256,bool)`. - mstore(0x00, 0x66f1bc67) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,uint256,uint256)`. - mstore(0x00, 0x34f0e636) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,uint256,string)`. - mstore(0x00, 0x4a28c017) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,string,address)`. - mstore(0x00, 0x5c430d47) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,string,bool)`. - mstore(0x00, 0xcf18105c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,string,uint256)`. - mstore(0x00, 0xbf01f891) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,uint256,string,string)`. - mstore(0x00, 0x88a8c406) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,address,address)`. - mstore(0x00, 0x0d36fa20) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,address,bool)`. - mstore(0x00, 0x0df12b76) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,address,uint256)`. - mstore(0x00, 0x457fe3cf) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,address,string)`. - mstore(0x00, 0xf7e36245) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,bool,address)`. - mstore(0x00, 0x205871c2) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,bool,bool)`. - mstore(0x00, 0x5f1d5c9f) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,bool,uint256)`. - mstore(0x00, 0x515e38b6) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,bool,string)`. - mstore(0x00, 0xbc0b61fe) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,uint256,address)`. - mstore(0x00, 0x63183678) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,uint256,bool)`. - mstore(0x00, 0x0ef7e050) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,uint256,uint256)`. - mstore(0x00, 0x1dc8e1b8) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,uint256,string)`. - mstore(0x00, 0x448830a8) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,string,address)`. - mstore(0x00, 0xa04e2f87) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,string,bool)`. - mstore(0x00, 0x35a5071f) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,string,uint256)`. - mstore(0x00, 0x159f8927) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(address,string,string,string)`. - mstore(0x00, 0x5d02c50b) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p1) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bool p0, address p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,address,address)`. - mstore(0x00, 0x1d14d001) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,address,bool)`. - mstore(0x00, 0x46600be0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,address,uint256)`. - mstore(0x00, 0x0c66d1be) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,address,string)`. - mstore(0x00, 0xd812a167) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,bool,address)`. - mstore(0x00, 0x1c41a336) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,bool,bool)`. - mstore(0x00, 0x6a9c478b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,bool,uint256)`. - mstore(0x00, 0x07831502) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,bool,string)`. - mstore(0x00, 0x4a66cb34) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,uint256,address)`. - mstore(0x00, 0x136b05dd) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,uint256,bool)`. - mstore(0x00, 0xd6019f1c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,uint256,uint256)`. - mstore(0x00, 0x7bf181a1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,uint256,string)`. - mstore(0x00, 0x51f09ff8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,string,address)`. - mstore(0x00, 0x6f7c603e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,string,bool)`. - mstore(0x00, 0xe2bfd60b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,string,uint256)`. - mstore(0x00, 0xc21f64c7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,address,string,string)`. - mstore(0x00, 0xa73c1db6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bool p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,address,address)`. - mstore(0x00, 0xf4880ea4) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,address,bool)`. - mstore(0x00, 0xc0a302d8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,address,uint256)`. - mstore(0x00, 0x4c123d57) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,address,string)`. - mstore(0x00, 0xa0a47963) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,bool,address)`. - mstore(0x00, 0x8c329b1a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,bool,bool)`. - mstore(0x00, 0x3b2a5ce0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,bool,uint256)`. - mstore(0x00, 0x6d7045c1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,bool,string)`. - mstore(0x00, 0x2ae408d4) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,uint256,address)`. - mstore(0x00, 0x54a7a9a0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,uint256,bool)`. - mstore(0x00, 0x619e4d0e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,uint256,uint256)`. - mstore(0x00, 0x0bb00eab) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,uint256,string)`. - mstore(0x00, 0x7dd4d0e0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,string,address)`. - mstore(0x00, 0xf9ad2b89) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,string,bool)`. - mstore(0x00, 0xb857163a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,string,uint256)`. - mstore(0x00, 0xe3a9ca2f) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,bool,string,string)`. - mstore(0x00, 0x6d1e8751) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, uint256 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,address,address)`. - mstore(0x00, 0x26f560a8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,address,bool)`. - mstore(0x00, 0xb4c314ff) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,address,uint256)`. - mstore(0x00, 0x1537dc87) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,address,string)`. - mstore(0x00, 0x1bb3b09a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,bool,address)`. - mstore(0x00, 0x9acd3616) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,bool,bool)`. - mstore(0x00, 0xceb5f4d7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,bool,uint256)`. - mstore(0x00, 0x7f9bbca2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,bool,string)`. - mstore(0x00, 0x9143dbb1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,uint256,address)`. - mstore(0x00, 0x00dd87b9) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,uint256,bool)`. - mstore(0x00, 0xbe984353) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,uint256,uint256)`. - mstore(0x00, 0x374bb4b2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,uint256,string)`. - mstore(0x00, 0x8e69fb5d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,string,address)`. - mstore(0x00, 0xfedd1fff) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,string,bool)`. - mstore(0x00, 0xe5e70b2b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,string,uint256)`. - mstore(0x00, 0x6a1199e2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,uint256,string,string)`. - mstore(0x00, 0xf5bc2249) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,address,address)`. - mstore(0x00, 0x2b2b18dc) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,address,bool)`. - mstore(0x00, 0x6dd434ca) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,address,uint256)`. - mstore(0x00, 0xa5cada94) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,address,string)`. - mstore(0x00, 0x12d6c788) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,bool,address)`. - mstore(0x00, 0x538e06ab) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,bool,bool)`. - mstore(0x00, 0xdc5e935b) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,bool,uint256)`. - mstore(0x00, 0x1606a393) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,bool,string)`. - mstore(0x00, 0x483d0416) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,uint256,address)`. - mstore(0x00, 0x1596a1ce) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,uint256,bool)`. - mstore(0x00, 0x6b0e5d53) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,uint256,uint256)`. - mstore(0x00, 0x28863fcb) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,uint256,string)`. - mstore(0x00, 0x1ad96de6) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,string,address)`. - mstore(0x00, 0x97d394d8) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,string,bool)`. - mstore(0x00, 0x1e4b87e5) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,string,uint256)`. - mstore(0x00, 0x7be0c3eb) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(bool,string,string,string)`. - mstore(0x00, 0x1762e32a) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p1) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(uint256 p0, address p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,address,address)`. - mstore(0x00, 0x2488b414) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,address,bool)`. - mstore(0x00, 0x091ffaf5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,address,uint256)`. - mstore(0x00, 0x736efbb6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,address,string)`. - mstore(0x00, 0x031c6f73) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,bool,address)`. - mstore(0x00, 0xef72c513) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,bool,bool)`. - mstore(0x00, 0xe351140f) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,bool,uint256)`. - mstore(0x00, 0x5abd992a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,bool,string)`. - mstore(0x00, 0x90fb06aa) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,uint256,address)`. - mstore(0x00, 0x15c127b5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,uint256,bool)`. - mstore(0x00, 0x5f743a7c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,uint256,uint256)`. - mstore(0x00, 0x0c9cd9c1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,uint256,string)`. - mstore(0x00, 0xddb06521) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,string,address)`. - mstore(0x00, 0x9cba8fff) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,string,bool)`. - mstore(0x00, 0xcc32ab07) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,string,uint256)`. - mstore(0x00, 0x46826b5d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,address,string,string)`. - mstore(0x00, 0x3e128ca3) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bool p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,address,address)`. - mstore(0x00, 0xa1ef4cbb) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,address,bool)`. - mstore(0x00, 0x454d54a5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,address,uint256)`. - mstore(0x00, 0x078287f5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,address,string)`. - mstore(0x00, 0xade052c7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,bool,address)`. - mstore(0x00, 0x69640b59) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,bool,bool)`. - mstore(0x00, 0xb6f577a1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,bool,uint256)`. - mstore(0x00, 0x7464ce23) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,bool,string)`. - mstore(0x00, 0xdddb9561) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,uint256,address)`. - mstore(0x00, 0x88cb6041) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,uint256,bool)`. - mstore(0x00, 0x91a02e2a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,uint256,uint256)`. - mstore(0x00, 0xc6acc7a8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,uint256,string)`. - mstore(0x00, 0xde03e774) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,string,address)`. - mstore(0x00, 0xef529018) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,string,bool)`. - mstore(0x00, 0xeb928d7f) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,string,uint256)`. - mstore(0x00, 0x2c1d0746) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,bool,string,string)`. - mstore(0x00, 0x68c8b8bd) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, uint256 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,address,address)`. - mstore(0x00, 0x56a5d1b1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,address,bool)`. - mstore(0x00, 0x15cac476) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,address,uint256)`. - mstore(0x00, 0x88f6e4b2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,address,string)`. - mstore(0x00, 0x6cde40b8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,bool,address)`. - mstore(0x00, 0x9a816a83) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,bool,bool)`. - mstore(0x00, 0xab085ae6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,bool,uint256)`. - mstore(0x00, 0xeb7f6fd2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,bool,string)`. - mstore(0x00, 0xa5b4fc99) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,uint256,address)`. - mstore(0x00, 0xfa8185af) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,uint256,bool)`. - mstore(0x00, 0xc598d185) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - assembly ("memory-safe") { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,uint256,uint256)`. - mstore(0x00, 0x193fb800) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,uint256,string)`. - mstore(0x00, 0x59cfcbe3) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,string,address)`. - mstore(0x00, 0x42d21db7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,string,bool)`. - mstore(0x00, 0x7af6ab25) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,string,uint256)`. - mstore(0x00, 0x5da297eb) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,uint256,string,string)`. - mstore(0x00, 0x27d8afd2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,address,address)`. - mstore(0x00, 0x6168ed61) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,address,bool)`. - mstore(0x00, 0x90c30a56) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,address,uint256)`. - mstore(0x00, 0xe8d3018d) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,address,string)`. - mstore(0x00, 0x9c3adfa1) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,bool,address)`. - mstore(0x00, 0xae2ec581) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,bool,bool)`. - mstore(0x00, 0xba535d9c) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,bool,uint256)`. - mstore(0x00, 0xcf009880) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,bool,string)`. - mstore(0x00, 0xd2d423cd) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,uint256,address)`. - mstore(0x00, 0x3b2279b4) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,uint256,bool)`. - mstore(0x00, 0x691a8f74) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,uint256,uint256)`. - mstore(0x00, 0x82c25b74) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,uint256,string)`. - mstore(0x00, 0xb7b914ca) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,string,address)`. - mstore(0x00, 0xd583c602) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,string,bool)`. - mstore(0x00, 0xb3a6b6bd) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,string,uint256)`. - mstore(0x00, 0xb028c9bd) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(uint256,string,string,string)`. - mstore(0x00, 0x21ad0683) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p1) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, address p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,address,address)`. - mstore(0x00, 0xed8f28f6) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,address,bool)`. - mstore(0x00, 0xb59dbd60) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,address,uint256)`. - mstore(0x00, 0x8ef3f399) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,address,string)`. - mstore(0x00, 0x800a1c67) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,bool,address)`. - mstore(0x00, 0x223603bd) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,bool,bool)`. - mstore(0x00, 0x79884c2b) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,bool,uint256)`. - mstore(0x00, 0x3e9f866a) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,bool,string)`. - mstore(0x00, 0x0454c079) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,uint256,address)`. - mstore(0x00, 0x63fb8bc5) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,uint256,bool)`. - mstore(0x00, 0xfc4845f0) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,uint256,uint256)`. - mstore(0x00, 0xf8f51b1e) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,uint256,string)`. - mstore(0x00, 0x5a477632) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,string,address)`. - mstore(0x00, 0xaabc9a31) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,string,bool)`. - mstore(0x00, 0x5f15d28c) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,string,uint256)`. - mstore(0x00, 0x91d1112e) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,address,string,string)`. - mstore(0x00, 0x245986f2) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bool p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,address,address)`. - mstore(0x00, 0x33e9dd1d) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,address,bool)`. - mstore(0x00, 0x958c28c6) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,address,uint256)`. - mstore(0x00, 0x5d08bb05) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,address,string)`. - mstore(0x00, 0x2d8e33a4) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,bool,address)`. - mstore(0x00, 0x7190a529) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,bool,bool)`. - mstore(0x00, 0x895af8c5) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,bool,uint256)`. - mstore(0x00, 0x8e3f78a9) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,bool,string)`. - mstore(0x00, 0x9d22d5dd) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,uint256,address)`. - mstore(0x00, 0x935e09bf) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,uint256,bool)`. - mstore(0x00, 0x8af7cf8a) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,uint256,uint256)`. - mstore(0x00, 0x64b5bb67) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,uint256,string)`. - mstore(0x00, 0x742d6ee7) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,string,address)`. - mstore(0x00, 0xe0625b29) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,string,bool)`. - mstore(0x00, 0x3f8a701d) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,string,uint256)`. - mstore(0x00, 0x24f91465) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,bool,string,string)`. - mstore(0x00, 0xa826caeb) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, uint256 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,address,address)`. - mstore(0x00, 0x5ea2b7ae) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,address,bool)`. - mstore(0x00, 0x82112a42) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,address,uint256)`. - mstore(0x00, 0x4f04fdc6) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,address,string)`. - mstore(0x00, 0x9ffb2f93) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,bool,address)`. - mstore(0x00, 0xe0e95b98) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,bool,bool)`. - mstore(0x00, 0x354c36d6) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,bool,uint256)`. - mstore(0x00, 0xe41b6f6f) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,bool,string)`. - mstore(0x00, 0xabf73a98) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,uint256,address)`. - mstore(0x00, 0xe21de278) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,uint256,bool)`. - mstore(0x00, 0x7626db92) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,uint256,uint256)`. - mstore(0x00, 0xa7a87853) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,uint256,string)`. - mstore(0x00, 0x854b3496) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,string,address)`. - mstore(0x00, 0x7c4632a4) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,string,bool)`. - mstore(0x00, 0x7d24491d) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,string,uint256)`. - mstore(0x00, 0xc67ea9d1) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,uint256,string,string)`. - mstore(0x00, 0x5ab84e1f) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,address,address)`. - mstore(0x00, 0x439c7bef) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,address,bool)`. - mstore(0x00, 0x5ccd4e37) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,address,uint256)`. - mstore(0x00, 0x7cc3c607) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,address,string)`. - mstore(0x00, 0xeb1bff80) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,bool,address)`. - mstore(0x00, 0xc371c7db) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,bool,bool)`. - mstore(0x00, 0x40785869) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,bool,uint256)`. - mstore(0x00, 0xd6aefad2) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,bool,string)`. - mstore(0x00, 0x5e84b0ea) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,uint256,address)`. - mstore(0x00, 0x1023f7b2) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,uint256,bool)`. - mstore(0x00, 0xc3a8a654) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,uint256,uint256)`. - mstore(0x00, 0xf45d7d2c) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,uint256,string)`. - mstore(0x00, 0x5d1a971a) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,string,address)`. - mstore(0x00, 0x6d572f44) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, 0x100) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p2) - } - _sendLogPayload(0x1c, 0x144); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,string,bool)`. - mstore(0x00, 0x2c1754ed) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, 0x100) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p2) - } - _sendLogPayload(0x1c, 0x144); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,string,uint256)`. - mstore(0x00, 0x8eafb02b) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, 0x100) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p2) - } - _sendLogPayload(0x1c, 0x144); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - bytes32 m11; - bytes32 m12; - assembly ("memory-safe") { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - m11 := mload(0x160) - m12 := mload(0x180) - // Selector of `log(string,string,string,string)`. - mstore(0x00, 0xde68f20a) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, 0x100) - mstore(0x80, 0x140) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p2) - writeString(0x160, p3) - } - _sendLogPayload(0x1c, 0x184); - assembly ("memory-safe") { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - mstore(0x160, m11) - mstore(0x180, m12) - } - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/CommonBase.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/CommonBase.t.sol deleted file mode 100644 index 28c91a912b..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/CommonBase.t.sol +++ /dev/null @@ -1,44 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {CommonBase} from "../src/Base.sol"; -import {StdConstants} from "../src/StdConstants.sol"; -import {Test} from "../src/Test.sol"; - -contract CommonBaseTest is Test { - function testVmAddressValue() public pure { - assertEq(VM_ADDRESS, address(StdConstants.VM)); - } - - function testConsoleValue() public pure { - assertEq(CONSOLE, StdConstants.CONSOLE); - } - - function testCreate2FactoryValue() public pure { - assertEq(CREATE2_FACTORY, StdConstants.CREATE2_FACTORY); - } - - function testDefaultSenderValue() public pure { - assertEq(DEFAULT_SENDER, StdConstants.DEFAULT_SENDER); - } - - function testDefaultTestContractValue() public pure { - assertEq(DEFAULT_TEST_CONTRACT, StdConstants.DEFAULT_TEST_CONTRACT); - } - - function testMulticall3AddressValue() public pure { - assertEq(MULTICALL3_ADDRESS, address(StdConstants.MULTICALL3_ADDRESS)); - } - - function testSecp256k1OrderValue() public pure { - assertEq(SECP256K1_ORDER, StdConstants.SECP256K1_ORDER); - } - - function testUint256MaxValue() public pure { - assertEq(UINT256_MAX, type(uint256).max); - } - - function testVmValue() public pure { - assertEq(address(vm), address(StdConstants.VM)); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/Config.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/Config.t.sol deleted file mode 100644 index b5f3154d55..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/Config.t.sol +++ /dev/null @@ -1,381 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity ^0.8.13; - -import {Test} from "../src/Test.sol"; -import {Config} from "../src/Config.sol"; -import {StdConfig} from "../src/StdConfig.sol"; - -contract ConfigTest is Test, Config { - function setUp() public { - vm.setEnv("MAINNET_RPC", "https://reth-ethereum.ithaca.xyz/rpc"); - vm.setEnv("WETH_MAINNET", "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"); - vm.setEnv("OPTIMISM_RPC", "https://mainnet.optimism.io"); - vm.setEnv("WETH_OPTIMISM", "0x4200000000000000000000000000000000000006"); - } - - function test_loadConfig() public { - // Deploy the config contract with the test fixture. - _loadConfig("./test/fixtures/config.toml", false); - - // -- MAINNET -------------------------------------------------------------- - - // Read and assert RPC URL for Mainnet (chain ID 1) - assertEq(config.getRpcUrl(1), "https://reth-ethereum.ithaca.xyz/rpc"); - - // Read and assert boolean values - assertTrue(config.get(1, "is_live").toBool()); - bool[] memory bool_array = config.get(1, "bool_array").toBoolArray(); - assertTrue(bool_array[0]); - assertFalse(bool_array[1]); - - // Read and assert address values - assertEq(config.get(1, "weth").toAddress(), 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2); - address[] memory address_array = config.get(1, "deps").toAddressArray(); - assertEq(address_array[0], 0x0000000000000000000000000000000000000000); - assertEq(address_array[1], 0x1111111111111111111111111111111111111111); - - // Read and assert bytes32 values - assertEq(config.get(1, "word").toBytes32(), bytes32(uint256(1234))); - bytes32[] memory bytes32_array = config.get(1, "word_array").toBytes32Array(); - assertEq(bytes32_array[0], bytes32(uint256(5678))); - assertEq(bytes32_array[1], bytes32(uint256(9999))); - - // Read and assert uint values - assertEq(config.get(1, "number").toUint256(), 1234); - uint256[] memory uint_array = config.get(1, "number_array").toUint256Array(); - assertEq(uint_array[0], 5678); - assertEq(uint_array[1], 9999); - - // Read and assert int values - assertEq(config.get(1, "signed_number").toInt256(), -1234); - int256[] memory int_array = config.get(1, "signed_number_array").toInt256Array(); - assertEq(int_array[0], -5678); - assertEq(int_array[1], 9999); - - // Read and assert bytes values - assertEq(config.get(1, "b").toBytes(), hex"abcd"); - bytes[] memory bytes_array = config.get(1, "b_array").toBytesArray(); - assertEq(bytes_array[0], hex"dead"); - assertEq(bytes_array[1], hex"beef"); - - // Read and assert string values - assertEq(config.get(1, "str").toString(), "foo"); - string[] memory string_array = config.get(1, "str_array").toStringArray(); - assertEq(string_array[0], "bar"); - assertEq(string_array[1], "baz"); - - // -- OPTIMISM ------------------------------------------------------------ - - // Read and assert RPC URL for Optimism (chain ID 10) - assertEq(config.getRpcUrl(10), "https://mainnet.optimism.io"); - - // Read and assert boolean values - assertFalse(config.get(10, "is_live").toBool()); - bool_array = config.get(10, "bool_array").toBoolArray(); - assertFalse(bool_array[0]); - assertTrue(bool_array[1]); - - // Read and assert address values - assertEq(config.get(10, "weth").toAddress(), 0x4200000000000000000000000000000000000006); - address_array = config.get(10, "deps").toAddressArray(); - assertEq(address_array[0], 0x2222222222222222222222222222222222222222); - assertEq(address_array[1], 0x3333333333333333333333333333333333333333); - - // Read and assert bytes32 values - assertEq(config.get(10, "word").toBytes32(), bytes32(uint256(9999))); - bytes32_array = config.get(10, "word_array").toBytes32Array(); - assertEq(bytes32_array[0], bytes32(uint256(1234))); - assertEq(bytes32_array[1], bytes32(uint256(5678))); - - // Read and assert uint values - assertEq(config.get(10, "number").toUint256(), 9999); - uint_array = config.get(10, "number_array").toUint256Array(); - assertEq(uint_array[0], 1234); - assertEq(uint_array[1], 5678); - - // Read and assert int values - assertEq(config.get(10, "signed_number").toInt256(), 9999); - int_array = config.get(10, "signed_number_array").toInt256Array(); - assertEq(int_array[0], -1234); - assertEq(int_array[1], -5678); - - // Read and assert bytes values - assertEq(config.get(10, "b").toBytes(), hex"dcba"); - bytes_array = config.get(10, "b_array").toBytesArray(); - assertEq(bytes_array[0], hex"c0ffee"); - assertEq(bytes_array[1], hex"babe"); - - // Read and assert string values - assertEq(config.get(10, "str").toString(), "alice"); - string_array = config.get(10, "str_array").toStringArray(); - assertEq(string_array[0], "bob"); - assertEq(string_array[1], "charlie"); - } - - function test_loadConfigAndForks() public { - _loadConfigAndForks("./test/fixtures/config.toml", false); - - // assert that the map of chain id and fork ids is created and that the chain ids actually match - assertEq(forkOf[1], 0); - vm.selectFork(forkOf[1]); - assertEq(vm.getChainId(), 1); - - assertEq(forkOf[10], 1); - vm.selectFork(forkOf[10]); - assertEq(vm.getChainId(), 10); - } - - function test_configExists() public { - _loadConfig("./test/fixtures/config.toml", false); - - string[] memory keys = new string[](7); - keys[0] = "is_live"; - keys[1] = "weth"; - keys[2] = "word"; - keys[3] = "number"; - keys[4] = "signed_number"; - keys[5] = "b"; - keys[6] = "str"; - - // Read and assert RPC URL for Mainnet (chain ID 1) - assertEq(config.getRpcUrl(1), "https://reth-ethereum.ithaca.xyz/rpc"); - - for (uint256 i = 0; i < keys.length; ++i) { - assertTrue(config.exists(1, keys[i])); - assertFalse(config.exists(1, string.concat(keys[i], "_"))); - } - - // Assert RPC URL for Optimism (chain ID 10) - assertEq(config.getRpcUrl(10), "https://mainnet.optimism.io"); - - for (uint256 i = 0; i < keys.length; ++i) { - assertTrue(config.exists(10, keys[i])); - assertFalse(config.exists(10, string.concat(keys[i], "_"))); - } - } - - function test_writeConfig() public { - // Create a temporary copy of the config file to avoid modifying the original. - string memory originalConfig = "./test/fixtures/config.toml"; - string memory testConfig = "./test/fixtures/config.t.toml"; - vm.copyFile(originalConfig, testConfig); - - // Deploy the config contract with the temporary fixture. - _loadConfig(testConfig, false); - - // Enable writing to file bypassing the context check. - vm.store(address(config), bytes32(uint256(5)), bytes32(uint256(1))); - - { - // Update a single boolean value and verify the change. - config.set(1, "is_live", false); - - assertFalse(config.get(1, "is_live").toBool()); - - string memory content = vm.readFile(testConfig); - assertFalse(vm.parseTomlBool(content, "$.mainnet.bool.is_live")); - - // Update a single address value and verify the change. - address new_addr = 0xDeaDbeefdEAdbeefdEadbEEFdeadbeEFdEaDbeeF; - config.set(1, "weth", new_addr); - - assertEq(config.get(1, "weth").toAddress(), new_addr); - - content = vm.readFile(testConfig); - assertEq(vm.parseTomlAddress(content, "$.mainnet.address.weth"), new_addr); - - // Update a uint array and verify the change. - uint256[] memory new_numbers = new uint256[](3); - new_numbers[0] = 1; - new_numbers[1] = 2; - new_numbers[2] = 3; - config.set(10, "number_array", new_numbers); - - uint256[] memory updated_numbers_mem = config.get(10, "number_array").toUint256Array(); - assertEq(updated_numbers_mem.length, 3); - assertEq(updated_numbers_mem[0], 1); - assertEq(updated_numbers_mem[1], 2); - assertEq(updated_numbers_mem[2], 3); - - content = vm.readFile(testConfig); - uint256[] memory updated_numbers_disk = vm.parseTomlUintArray(content, "$.optimism.uint.number_array"); - assertEq(updated_numbers_disk.length, 3); - assertEq(updated_numbers_disk[0], 1); - assertEq(updated_numbers_disk[1], 2); - assertEq(updated_numbers_disk[2], 3); - - // Update a string array and verify the change. - string[] memory new_strings = new string[](2); - new_strings[0] = "hello"; - new_strings[1] = "world"; - config.set(1, "str_array", new_strings); - - string[] memory updated_strings_mem = config.get(1, "str_array").toStringArray(); - assertEq(updated_strings_mem.length, 2); - assertEq(updated_strings_mem[0], "hello"); - assertEq(updated_strings_mem[1], "world"); - - content = vm.readFile(testConfig); - string[] memory updated_strings_disk = vm.parseTomlStringArray(content, "$.mainnet.string.str_array"); - assertEq(updated_strings_disk.length, 2); - assertEq(updated_strings_disk[0], "hello"); - assertEq(updated_strings_disk[1], "world"); - - // Create a new uint variable and verify the change. - config.set(1, "new_uint", uint256(42)); - - assertEq(config.get(1, "new_uint").toUint256(), 42); - - content = vm.readFile(testConfig); - assertEq(vm.parseTomlUint(content, "$.mainnet.uint.new_uint"), 42); - - // Create a new int variable and verify the change. - config.set(1, "new_int", int256(-42)); - - assertEq(config.get(1, "new_int").toInt256(), -42); - - content = vm.readFile(testConfig); - assertEq(vm.parseTomlInt(content, "$.mainnet.int.new_int"), -42); - - // Create a new int array and verify the change. - int256[] memory new_ints = new int256[](2); - new_ints[0] = -100; - new_ints[1] = 200; - config.set(10, "new_ints", new_ints); - - int256[] memory updated_ints_mem = config.get(10, "new_ints").toInt256Array(); - assertEq(updated_ints_mem.length, 2); - assertEq(updated_ints_mem[0], -100); - assertEq(updated_ints_mem[1], 200); - - content = vm.readFile(testConfig); - int256[] memory updated_ints_disk = vm.parseTomlIntArray(content, "$.optimism.int.new_ints"); - assertEq(updated_ints_disk.length, 2); - assertEq(updated_ints_disk[0], -100); - assertEq(updated_ints_disk[1], 200); - - // Create a new bytes32 array and verify the change. - bytes32[] memory new_words = new bytes32[](2); - new_words[0] = bytes32(uint256(0xDEAD)); - new_words[1] = bytes32(uint256(0xBEEF)); - config.set(10, "new_words", new_words); - - bytes32[] memory updated_words_mem = config.get(10, "new_words").toBytes32Array(); - assertEq(updated_words_mem.length, 2); - assertEq(updated_words_mem[0], new_words[0]); - assertEq(updated_words_mem[1], new_words[1]); - - content = vm.readFile(testConfig); - bytes32[] memory updated_words_disk = vm.parseTomlBytes32Array(content, "$.optimism.bytes32.new_words"); - assertEq(updated_words_disk.length, 2); - assertEq(vm.toString(updated_words_disk[0]), vm.toString(new_words[0])); - assertEq(vm.toString(updated_words_disk[1]), vm.toString(new_words[1])); - } - - // Clean up the temporary file. - vm.removeFile(testConfig); - } - - function test_writeUpdatesBackToFile() public { - // Create a temporary copy of the config file to avoid modifying the original. - string memory originalConfig = "./test/fixtures/config.toml"; - string memory testConfig = "./test/fixtures/write_config.t.toml"; - vm.copyFile(originalConfig, testConfig); - - // Deploy the config contract with `writeToFile = false` (disabled). - _loadConfig(testConfig, false); - - // Update a single boolean value and verify the file is NOT changed. - config.set(1, "is_live", false); - string memory content = vm.readFile(testConfig); - assertTrue(vm.parseTomlBool(content, "$.mainnet.bool.is_live"), "File should not be updated yet"); - - // Enable writing to file bypassing the context check. - vm.store(address(config), bytes32(uint256(5)), bytes32(uint256(1))); - - // Update the value again and verify the file IS changed. - config.set(1, "is_live", false); - content = vm.readFile(testConfig); - assertFalse(vm.parseTomlBool(content, "$.mainnet.bool.is_live"), "File should be updated now"); - - // Disable writing to file. - config.writeUpdatesBackToFile(false); - - // Update the value again and verify the file is NOT changed. - config.set(1, "is_live", true); - content = vm.readFile(testConfig); - assertFalse(vm.parseTomlBool(content, "$.mainnet.bool.is_live"), "File should not be updated again"); - - // Clean up the temporary file. - vm.removeFile(testConfig); - } - - function testRevert_WriteToFileInForbiddenCtxt() public { - // Cannot initialize enabling writing to file unless we are in SCRIPT mode. - vm.expectRevert(StdConfig.WriteToFileInForbiddenCtxt.selector); - _loadConfig("./test/fixtures/config.toml", true); - - // Initialize with `writeToFile = false`. - _loadConfig("./test/fixtures/config.toml", false); - - // Cannot enable writing to file unless we are in SCRIPT mode. - vm.expectRevert(StdConfig.WriteToFileInForbiddenCtxt.selector); - config.writeUpdatesBackToFile(true); - } - - function testRevert_InvalidChainKey() public { - // Create a fixture with an invalid chain key - string memory invalidChainConfig = "./test/fixtures/config_invalid_chain.toml"; - vm.writeFile( - invalidChainConfig, - string.concat( - "[mainnet]\n", - "endpoint_url = \"https://reth-ethereum.ithaca.xyz/rpc\"\n", - "\n", - "[mainnet.uint]\n", - "valid_number = 123\n", - "\n", - "# Invalid chain key (not a number and not a valid alias)\n", - "[invalid_chain]\n", - "endpoint_url = \"https://invalid.com\"\n", - "\n", - "[invalid_chain_9999.uint]\n", - "some_value = 456\n" - ) - ); - - vm.expectRevert(abi.encodeWithSelector(StdConfig.InvalidChainKey.selector, "invalid_chain")); - new StdConfig(invalidChainConfig, false); - vm.removeFile(invalidChainConfig); - } - - function testRevert_ChainNotInitialized() public { - _loadConfig("./test/fixtures/config.toml", false); - - // Enable writing to file bypassing the context check. - vm.store(address(config), bytes32(uint256(5)), bytes32(uint256(1))); - - // Try to write a value for a non-existent chain ID - vm.expectRevert(abi.encodeWithSelector(StdConfig.ChainNotInitialized.selector, uint256(999999))); - config.set(999999, "some_key", uint256(123)); - } - - function testRevert_UnableToParseVariable() public { - // Create a temporary fixture with an unparsable variable - string memory badParseConfig = "./test/fixtures/config_bad_parse.toml"; - vm.writeFile( - badParseConfig, - string.concat( - "[mainnet]\n", - "endpoint_url = \"https://reth-ethereum.ithaca.xyz/rpc\"\n", - "\n", - "[mainnet.uint]\n", - "bad_value = \"not_a_number\"\n" - ) - ); - - vm.expectRevert(abi.encodeWithSelector(StdConfig.UnableToParseVariable.selector, "bad_value")); - new StdConfig(badParseConfig, false); - vm.removeFile(badParseConfig); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/LibVariable.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/LibVariable.t.sol deleted file mode 100644 index abd515cc47..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/LibVariable.t.sol +++ /dev/null @@ -1,452 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity ^0.8.13; - -import {Test} from "../src/Test.sol"; -import {Variable, Type, TypeKind, LibVariable} from "../src/LibVariable.sol"; - -contract LibVariableTest is Test { - using LibVariable for Type; - using LibVariable for TypeKind; - - LibVariableHelper internal helper; - - bytes internal expectedErr; - Variable internal uninitVar; - Variable internal boolVar; - Variable internal addressVar; - Variable internal bytes32Var; - Variable internal uintVar; - Variable internal intVar; - Variable internal stringVar; - Variable internal bytesVar; - Variable internal boolArrayVar; - Variable internal addressArrayVar; - Variable internal bytes32ArrayVar; - Variable internal uintArrayVar; - Variable internal intArrayVar; - Variable internal stringArrayVar; - Variable internal bytesArrayVar; - - function setUp() public { - helper = new LibVariableHelper(); - - // UNINITIALIZED - uninitVar = Variable(Type(TypeKind.None, false), ""); - - // SINGLE VALUES - boolVar = Variable(Type(TypeKind.Bool, false), abi.encode(true)); - addressVar = Variable(Type(TypeKind.Address, false), abi.encode(address(0xdeadbeef))); - bytes32Var = Variable(Type(TypeKind.Bytes32, false), abi.encode(bytes32(uint256(42)))); - uintVar = Variable(Type(TypeKind.Uint256, false), abi.encode(uint256(123))); - intVar = Variable(Type(TypeKind.Int256, false), abi.encode(int256(-123))); - stringVar = Variable(Type(TypeKind.String, false), abi.encode("hello world")); - bytesVar = Variable(Type(TypeKind.Bytes, false), abi.encode(hex"c0ffee")); - - // ARRAY VALUES - bool[] memory bools = new bool[](2); - bools[0] = true; - bools[1] = false; - boolArrayVar = Variable(Type(TypeKind.Bool, true), abi.encode(bools)); - - address[] memory addrs = new address[](2); - addrs[0] = address(0x1); - addrs[1] = address(0x2); - addressArrayVar = Variable(Type(TypeKind.Address, true), abi.encode(addrs)); - - bytes32[] memory b32s = new bytes32[](2); - b32s[0] = bytes32(uint256(1)); - b32s[1] = bytes32(uint256(2)); - bytes32ArrayVar = Variable(Type(TypeKind.Bytes32, true), abi.encode(b32s)); - - uint256[] memory uints = new uint256[](2); - uints[0] = 1; - uints[1] = 2; - uintArrayVar = Variable(Type(TypeKind.Uint256, true), abi.encode(uints)); - - int256[] memory ints = new int256[](2); - ints[0] = -1; - ints[1] = 2; - intArrayVar = Variable(Type(TypeKind.Int256, true), abi.encode(ints)); - - string[] memory strings = new string[](2); - strings[0] = "one"; - strings[1] = "two"; - stringArrayVar = Variable(Type(TypeKind.String, true), abi.encode(strings)); - - bytes[] memory b = new bytes[](2); - b[0] = hex"01"; - b[1] = hex"02"; - bytesArrayVar = Variable(Type(TypeKind.Bytes, true), abi.encode(b)); - } - - // -- SUCCESS CASES -------------------------------------------------------- - - function test_TypeHelpers() public view { - // TypeKind.toString() - assertEq(TypeKind.None.toString(), "none"); - assertEq(TypeKind.Bool.toString(), "bool"); - assertEq(TypeKind.Address.toString(), "address"); - assertEq(TypeKind.Bytes32.toString(), "bytes32"); - assertEq(TypeKind.Uint256.toString(), "uint256"); - assertEq(TypeKind.Int256.toString(), "int256"); - assertEq(TypeKind.String.toString(), "string"); - assertEq(TypeKind.Bytes.toString(), "bytes"); - - // TypeKind.toTomlKey() - assertEq(TypeKind.Uint256.toTomlKey(), "uint"); - assertEq(TypeKind.Int256.toTomlKey(), "int"); - assertEq(TypeKind.Bytes32.toTomlKey(), "bytes32"); - - // Type.toString() - assertEq(boolVar.ty.toString(), "bool"); - assertEq(boolArrayVar.ty.toString(), "bool[]"); - assertEq(uintVar.ty.toString(), "uint256"); - assertEq(uintArrayVar.ty.toString(), "uint256[]"); - assertEq(uninitVar.ty.toString(), "none"); - - // Type.isEqual() - assertTrue(boolVar.ty.isEqual(Type(TypeKind.Bool, false))); - assertFalse(boolVar.ty.isEqual(Type(TypeKind.Bool, true))); - assertFalse(boolVar.ty.isEqual(Type(TypeKind.Address, false))); - - // Type.assertEq() - boolVar.ty.assertEq(Type(TypeKind.Bool, false)); - uintArrayVar.ty.assertEq(Type(TypeKind.Uint256, true)); - } - - function test_Coercion() public view { - // Single values - assertTrue(helper.toBool(boolVar)); - assertEq(helper.toAddress(addressVar), address(0xdeadbeef)); - assertEq(helper.toBytes32(bytes32Var), bytes32(uint256(42))); - assertEq(helper.toUint256(uintVar), 123); - assertEq(helper.toInt256(intVar), -123); - assertEq(helper.toString(stringVar), "hello world"); - assertEq(helper.toBytes(bytesVar), hex"c0ffee"); - - // Bool array - bool[] memory bools = helper.toBoolArray(boolArrayVar); - assertEq(bools.length, 2); - assertTrue(bools[0]); - assertFalse(bools[1]); - - // Address array - address[] memory addrs = helper.toAddressArray(addressArrayVar); - assertEq(addrs.length, 2); - assertEq(addrs[0], address(0x1)); - assertEq(addrs[1], address(0x2)); - - // String array - string[] memory strings = helper.toStringArray(stringArrayVar); - assertEq(strings.length, 2); - assertEq(strings[0], "one"); - assertEq(strings[1], "two"); - - // Bytes32 array - bytes32[] memory b32s = helper.toBytes32Array(bytes32ArrayVar); - assertEq(b32s.length, 2); - assertEq(b32s[0], bytes32(uint256(1))); - assertEq(b32s[1], bytes32(uint256(2))); - - // Int array - int256[] memory ints = helper.toInt256Array(intArrayVar); - assertEq(ints.length, 2); - assertEq(ints[0], -1); - assertEq(ints[1], 2); - - // Bytes array - bytes[] memory b = helper.toBytesArray(bytesArrayVar); - assertEq(b.length, 2); - assertEq(b[0], hex"01"); - assertEq(b[1], hex"02"); - } - - function test_Downcasting() public view { - // Uint downcasting - Variable memory v_uint_small = Variable(Type(TypeKind.Uint256, false), abi.encode(uint256(100))); - assertEq(helper.toUint128(v_uint_small), 100); - assertEq(helper.toUint64(v_uint_small), 100); - assertEq(helper.toUint32(v_uint_small), 100); - assertEq(helper.toUint16(v_uint_small), 100); - assertEq(helper.toUint8(v_uint_small), 100); - - // Uint array downcasting - uint256[] memory small_uints = new uint256[](2); - small_uints[0] = 10; - small_uints[1] = 20; - Variable memory v_uint_array_small = Variable(Type(TypeKind.Uint256, true), abi.encode(small_uints)); - uint8[] memory u8_array = helper.toUint8Array(v_uint_array_small); - assertEq(u8_array[0], 10); - assertEq(u8_array[1], 20); - - // Int downcasting - Variable memory v_int_small_pos = Variable(Type(TypeKind.Int256, false), abi.encode(int256(100))); - Variable memory v_int_small_neg = Variable(Type(TypeKind.Int256, false), abi.encode(int256(-100))); - assertEq(helper.toInt128(v_int_small_pos), 100); - assertEq(helper.toInt64(v_int_small_neg), -100); - assertEq(helper.toInt32(v_int_small_pos), 100); - assertEq(helper.toInt16(v_int_small_neg), -100); - assertEq(helper.toInt8(v_int_small_pos), 100); - - // Int array downcasting - int256[] memory small_ints = new int256[](2); - small_ints[0] = -10; - small_ints[1] = 20; - Variable memory intArraySmall = Variable(Type(TypeKind.Int256, true), abi.encode(small_ints)); - int8[] memory i8_array = helper.toInt8Array(intArraySmall); - assertEq(i8_array[0], -10); - assertEq(i8_array[1], 20); - } - - // -- REVERT CASES --------------------------------------------------------- - - function testRevert_NotInitialized() public { - vm.expectRevert(LibVariable.NotInitialized.selector); - helper.toBool(uninitVar); - - vm.expectRevert(LibVariable.NotInitialized.selector); - helper.toAddressArray(uninitVar); - } - - function testRevert_assertExists() public { - vm.expectRevert(LibVariable.NotInitialized.selector); - helper.assertExists(uninitVar); - } - - function testRevert_TypeMismatch() public { - // Single values - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "uint256", "bool")); - helper.toUint256(boolVar); - - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "address", "string")); - helper.toAddress(stringVar); - - // Arrays - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "uint256[]", "bool[]")); - helper.toUint256Array(boolArrayVar); - - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "address[]", "string[]")); - helper.toAddressArray(stringArrayVar); - - // Single value to array - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "bool[]", "bool")); - helper.toBoolArray(boolVar); - - // Array to single value - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "bool", "bool[]")); - helper.toBool(boolArrayVar); - - // assertEq reverts - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "uint256", "bool")); - helper.assertEq(boolVar.ty, Type(TypeKind.Uint256, false)); - } - - function testRevert_UnsafeCast() public { - // uint overflow - Variable memory uintLarge = Variable(Type(TypeKind.Uint256, false), abi.encode(uint256(type(uint128).max) + 1)); - expectedErr = abi.encodeWithSelector(LibVariable.UnsafeCast.selector, "value does not fit in 'uint128'"); - vm.expectRevert(expectedErr); - helper.toUint128(uintLarge); - - // int overflow - Variable memory intLarge = Variable(Type(TypeKind.Int256, false), abi.encode(int256(type(int128).max) + 1)); - expectedErr = abi.encodeWithSelector(LibVariable.UnsafeCast.selector, "value does not fit in 'int128'"); - - vm.expectRevert(expectedErr); - helper.toInt128(intLarge); - - // int underflow - Variable memory intSmall = Variable(Type(TypeKind.Int256, false), abi.encode(int256(type(int128).min) - 1)); - expectedErr = abi.encodeWithSelector(LibVariable.UnsafeCast.selector, "value does not fit in 'int128'"); - - vm.expectRevert(expectedErr); - helper.toInt128(intSmall); - - // uint array overflow - uint256[] memory uintArray = new uint256[](2); - uintArray[0] = 10; - uintArray[1] = uint256(type(uint64).max) + 1; - Variable memory uintArrayLarge = Variable(Type(TypeKind.Uint256, true), abi.encode(uintArray)); - expectedErr = abi.encodeWithSelector(LibVariable.UnsafeCast.selector, "value in array does not fit in 'uint64'"); - - vm.expectRevert(expectedErr); - helper.toUint64Array(uintArrayLarge); - - // int array overflow - int256[] memory intArray = new int256[](2); - intArray[0] = 10; - intArray[1] = int256(type(int64).max) + 1; - Variable memory intArrayLarge = Variable(Type(TypeKind.Int256, true), abi.encode(intArray)); - expectedErr = abi.encodeWithSelector(LibVariable.UnsafeCast.selector, "value in array does not fit in 'int64'"); - - vm.expectRevert(expectedErr); - helper.toInt64Array(intArrayLarge); - - // int array underflow - intArray[0] = 10; - intArray[1] = int256(type(int64).min) - 1; - Variable memory intArraySmall = Variable(Type(TypeKind.Int256, true), abi.encode(intArray)); - expectedErr = abi.encodeWithSelector(LibVariable.UnsafeCast.selector, "value in array does not fit in 'int64'"); - - vm.expectRevert(expectedErr); - helper.toInt64Array(intArraySmall); - } -} - -/// @dev We must use an external helper contract to ensure proper call depth for `vm.expectRevert`, -/// as direct library calls are inlined by the compiler, causing call depth issues. -contract LibVariableHelper { - using LibVariable for Type; - using LibVariable for TypeKind; - - // Assertions - function assertExists(Variable memory v) external pure { - v.assertExists(); - } - - function assertEq(Type memory t1, Type memory t2) external pure { - t1.assertEq(t2); - } - - // Single Value Coercion - function toBool(Variable memory v) external pure returns (bool) { - return v.toBool(); - } - - function toAddress(Variable memory v) external pure returns (address) { - return v.toAddress(); - } - - function toBytes32(Variable memory v) external pure returns (bytes32) { - return v.toBytes32(); - } - - function toUint256(Variable memory v) external pure returns (uint256) { - return v.toUint256(); - } - - function toInt256(Variable memory v) external pure returns (int256) { - return v.toInt256(); - } - - function toString(Variable memory v) external pure returns (string memory) { - return v.toString(); - } - - function toBytes(Variable memory v) external pure returns (bytes memory) { - return v.toBytes(); - } - - // Array Coercion - function toBoolArray(Variable memory v) external pure returns (bool[] memory) { - return v.toBoolArray(); - } - - function toAddressArray(Variable memory v) external pure returns (address[] memory) { - return v.toAddressArray(); - } - - function toBytes32Array(Variable memory v) external pure returns (bytes32[] memory) { - return v.toBytes32Array(); - } - - function toUint256Array(Variable memory v) external pure returns (uint256[] memory) { - return v.toUint256Array(); - } - - function toInt256Array(Variable memory v) external pure returns (int256[] memory) { - return v.toInt256Array(); - } - - function toStringArray(Variable memory v) external pure returns (string[] memory) { - return v.toStringArray(); - } - - function toBytesArray(Variable memory v) external pure returns (bytes[] memory) { - return v.toBytesArray(); - } - - // Uint Downcasting - function toUint128(Variable memory v) external pure returns (uint128) { - return v.toUint128(); - } - - function toUint64(Variable memory v) external pure returns (uint64) { - return v.toUint64(); - } - - function toUint32(Variable memory v) external pure returns (uint32) { - return v.toUint32(); - } - - function toUint16(Variable memory v) external pure returns (uint16) { - return v.toUint16(); - } - - function toUint8(Variable memory v) external pure returns (uint8) { - return v.toUint8(); - } - - // Int Downcasting - function toInt128(Variable memory v) external pure returns (int128) { - return v.toInt128(); - } - - function toInt64(Variable memory v) external pure returns (int64) { - return v.toInt64(); - } - - function toInt32(Variable memory v) external pure returns (int32) { - return v.toInt32(); - } - - function toInt16(Variable memory v) external pure returns (int16) { - return v.toInt16(); - } - - function toInt8(Variable memory v) external pure returns (int8) { - return v.toInt8(); - } - - // Uint Array Downcasting - function toUint128Array(Variable memory v) external pure returns (uint128[] memory) { - return v.toUint128Array(); - } - - function toUint64Array(Variable memory v) external pure returns (uint64[] memory) { - return v.toUint64Array(); - } - - function toUint32Array(Variable memory v) external pure returns (uint32[] memory) { - return v.toUint32Array(); - } - - function toUint16Array(Variable memory v) external pure returns (uint16[] memory) { - return v.toUint16Array(); - } - - function toUint8Array(Variable memory v) external pure returns (uint8[] memory) { - return v.toUint8Array(); - } - - // Int Array Downcasting - function toInt128Array(Variable memory v) external pure returns (int128[] memory) { - return v.toInt128Array(); - } - - function toInt64Array(Variable memory v) external pure returns (int64[] memory) { - return v.toInt64Array(); - } - - function toInt32Array(Variable memory v) external pure returns (int32[] memory) { - return v.toInt32Array(); - } - - function toInt16Array(Variable memory v) external pure returns (int16[] memory) { - return v.toInt16Array(); - } - - function toInt8Array(Variable memory v) external pure returns (int8[] memory) { - return v.toInt8Array(); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdAssertions.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdAssertions.t.sol deleted file mode 100644 index 3d670cb7e4..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdAssertions.t.sol +++ /dev/null @@ -1,141 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {StdAssertions} from "../src/StdAssertions.sol"; -import {Vm} from "../src/Vm.sol"; - -interface VmInternal is Vm { - function _expectCheatcodeRevert(bytes memory message) external; -} - -contract StdAssertionsTest is StdAssertions { - string constant errorMessage = "User provided message"; - uint256 constant maxDecimals = 77; - - bool constant SHOULD_REVERT = true; - bool constant SHOULD_RETURN = false; - - bool constant STRICT_REVERT_DATA = true; - bool constant NON_STRICT_REVERT_DATA = false; - - VmInternal constant vm = VmInternal(address(uint160(uint256(keccak256("hevm cheat code"))))); - - function testFuzz_AssertEqCall_Return_Pass( - bytes memory callDataA, - bytes memory callDataB, - bytes memory returnData, - bool strictRevertData - ) external { - address targetA = address(new TestMockCall(returnData, SHOULD_RETURN)); - address targetB = address(new TestMockCall(returnData, SHOULD_RETURN)); - - assertEqCall(targetA, callDataA, targetB, callDataB, strictRevertData); - } - - function testFuzz_RevertWhenCalled_AssertEqCall_Return_Fail( - bytes memory callDataA, - bytes memory callDataB, - bytes memory returnDataA, - bytes memory returnDataB, - bool strictRevertData - ) external { - vm.assume(keccak256(returnDataA) != keccak256(returnDataB)); - - address targetA = address(new TestMockCall(returnDataA, SHOULD_RETURN)); - address targetB = address(new TestMockCall(returnDataB, SHOULD_RETURN)); - - vm._expectCheatcodeRevert( - bytes( - string.concat( - "Call return data does not match: ", vm.toString(returnDataA), " != ", vm.toString(returnDataB) - ) - ) - ); - assertEqCall(targetA, callDataA, targetB, callDataB, strictRevertData); - } - - function testFuzz_AssertEqCall_Revert_Pass( - bytes memory callDataA, - bytes memory callDataB, - bytes memory revertDataA, - bytes memory revertDataB - ) external { - address targetA = address(new TestMockCall(revertDataA, SHOULD_REVERT)); - address targetB = address(new TestMockCall(revertDataB, SHOULD_REVERT)); - - assertEqCall(targetA, callDataA, targetB, callDataB, NON_STRICT_REVERT_DATA); - } - - function testFuzz_RevertWhenCalled_AssertEqCall_Revert_Fail( - bytes memory callDataA, - bytes memory callDataB, - bytes memory revertDataA, - bytes memory revertDataB - ) external { - vm.assume(keccak256(revertDataA) != keccak256(revertDataB)); - - address targetA = address(new TestMockCall(revertDataA, SHOULD_REVERT)); - address targetB = address(new TestMockCall(revertDataB, SHOULD_REVERT)); - - vm._expectCheatcodeRevert( - bytes( - string.concat( - "Call revert data does not match: ", vm.toString(revertDataA), " != ", vm.toString(revertDataB) - ) - ) - ); - assertEqCall(targetA, callDataA, targetB, callDataB, STRICT_REVERT_DATA); - } - - function testFuzz_RevertWhenCalled_AssertEqCall_Fail( - bytes memory callDataA, - bytes memory callDataB, - bytes memory returnDataA, - bytes memory returnDataB, - bool strictRevertData - ) external { - address targetA = address(new TestMockCall(returnDataA, SHOULD_RETURN)); - address targetB = address(new TestMockCall(returnDataB, SHOULD_REVERT)); - - vm.expectRevert(bytes("assertion failed")); - this.assertEqCallExternal(targetA, callDataA, targetB, callDataB, strictRevertData); - - vm.expectRevert(bytes("assertion failed")); - this.assertEqCallExternal(targetB, callDataB, targetA, callDataA, strictRevertData); - } - - // Helper function to test outcome of assertEqCall via `expect` cheatcodes - function assertEqCallExternal( - address targetA, - bytes memory callDataA, - address targetB, - bytes memory callDataB, - bool strictRevertData - ) public { - assertEqCall(targetA, callDataA, targetB, callDataB, strictRevertData); - } -} - -contract TestMockCall { - bytes returnData; - bool shouldRevert; - - constructor(bytes memory returnData_, bool shouldRevert_) { - returnData = returnData_; - shouldRevert = shouldRevert_; - } - - fallback() external payable { - bytes memory returnData_ = returnData; - - if (shouldRevert) { - assembly { - revert(add(returnData_, 0x20), mload(returnData_)) - } - } else { - assembly { - return(add(returnData_, 0x20), mload(returnData_)) - } - } - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdChains.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdChains.t.sol deleted file mode 100644 index 8894f4b151..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdChains.t.sol +++ /dev/null @@ -1,227 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {Test} from "../src/Test.sol"; - -contract StdChainsMock is Test { - function exposedGetChain(string memory chainAlias) public returns (Chain memory) { - return getChain(chainAlias); - } - - function exposedGetChain(uint256 chainId) public returns (Chain memory) { - return getChain(chainId); - } - - function exposedSetChain(string memory chainAlias, ChainData memory chainData) public { - setChain(chainAlias, chainData); - } - - function exposedSetFallbackToDefaultRpcUrls(bool useDefault) public { - setFallbackToDefaultRpcUrls(useDefault); - } -} - -contract StdChainsTest is Test { - function test_ChainRpcInitialization() public { - // RPCs specified in `foundry.toml` should be updated. - assertEq(getChain(1).rpcUrl, "https://reth-ethereum.ithaca.xyz/rpc"); - assertEq(getChain("optimism_sepolia").rpcUrl, "https://sepolia.optimism.io/"); - assertEq(getChain("arbitrum_one_sepolia").rpcUrl, "https://sepolia-rollup.arbitrum.io/rpc/"); - - // Environment variables should be the next fallback - assertEq(getChain("arbitrum_nova").rpcUrl, "https://nova.arbitrum.io/rpc"); - vm.setEnv("ARBITRUM_NOVA_RPC_URL", "myoverride"); - assertEq(getChain("arbitrum_nova").rpcUrl, "myoverride"); - vm.setEnv("ARBITRUM_NOVA_RPC_URL", "https://nova.arbitrum.io/rpc"); - - // Cannot override RPCs defined in `foundry.toml` - vm.setEnv("MAINNET_RPC_URL", "myoverride2"); - assertEq(getChain("mainnet").rpcUrl, "https://reth-ethereum.ithaca.xyz/rpc"); - - // Other RPCs should remain unchanged. - assertEq(getChain(31337).rpcUrl, "http://127.0.0.1:8545"); - assertEq(getChain("sepolia").rpcUrl, "https://sepolia.infura.io/v3/b9794ad1ddf84dfb8c34d6bb5dca2001"); - } - - // Named with a leading underscore to clarify this is not intended to be run as a normal test, - // and is intended to be used in the below `test_Rpcs` test. - function _testRpc(string memory rpcAlias) internal { - string memory rpcUrl = getChain(rpcAlias).rpcUrl; - vm.createSelectFork(rpcUrl); - } - - // Ensure we can connect to the default RPC URL for each chain. - // Currently commented out since this is slow and public RPCs are flaky, often resulting in failing CI. - // function test_Rpcs() public { - // _testRpc("mainnet"); - // _testRpc("sepolia"); - // _testRpc("holesky"); - // _testRpc("optimism"); - // _testRpc("optimism_sepolia"); - // _testRpc("arbitrum_one"); - // _testRpc("arbitrum_one_sepolia"); - // _testRpc("arbitrum_nova"); - // _testRpc("polygon"); - // _testRpc("polygon_amoy"); - // _testRpc("avalanche"); - // _testRpc("avalanche_fuji"); - // _testRpc("bnb_smart_chain"); - // _testRpc("bnb_smart_chain_testnet"); - // _testRpc("gnosis_chain"); - // _testRpc("moonbeam"); - // _testRpc("moonriver"); - // _testRpc("moonbase"); - // _testRpc("base_sepolia"); - // _testRpc("base"); - // _testRpc("blast_sepolia"); - // _testRpc("blast"); - // _testRpc("fantom_opera"); - // _testRpc("fantom_opera_testnet"); - // _testRpc("fraxtal"); - // _testRpc("fraxtal_testnet"); - // _testRpc("berachain_bartio_testnet"); - // _testRpc("flare"); - // _testRpc("flare_coston2"); - // } - - function test_RevertIf_ChainNotFound() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(string): Chain with alias \"does_not_exist\" not found."); - stdChainsMock.exposedGetChain("does_not_exist"); - } - - function test_RevertIf_SetChain_ChainIdExist_FirstTest() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains setChain(string,ChainData): Chain ID 31337 already used by \"anvil\"."); - stdChainsMock.exposedSetChain("anvil2", ChainData("Anvil", 31337, "URL")); - } - - function test_RevertIf_ChainBubbleUp() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - stdChainsMock.exposedSetChain("needs_undefined_env_var", ChainData("", 123456789, "")); - // Forge environment variable error. - vm.expectRevert(); - stdChainsMock.exposedGetChain("needs_undefined_env_var"); - } - - function test_RevertIf_SetChain_ChainIdExists_SecondTest() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - stdChainsMock.exposedSetChain("custom_chain", ChainData("Custom Chain", 123456789, "https://custom.chain/")); - - vm.expectRevert('StdChains setChain(string,ChainData): Chain ID 123456789 already used by "custom_chain".'); - - stdChainsMock.exposedSetChain("another_custom_chain", ChainData("", 123456789, "")); - } - - function test_SetChain() public { - setChain("custom_chain", ChainData("Custom Chain", 123456789, "https://custom.chain/")); - Chain memory customChain = getChain("custom_chain"); - assertEq(customChain.name, "Custom Chain"); - assertEq(customChain.chainId, 123456789); - assertEq(customChain.chainAlias, "custom_chain"); - assertEq(customChain.rpcUrl, "https://custom.chain/"); - Chain memory chainById = getChain(123456789); - assertEq(chainById.name, customChain.name); - assertEq(chainById.chainId, customChain.chainId); - assertEq(chainById.chainAlias, customChain.chainAlias); - assertEq(chainById.rpcUrl, customChain.rpcUrl); - customChain.name = "Another Custom Chain"; - customChain.chainId = 987654321; - setChain("another_custom_chain", customChain); - Chain memory anotherCustomChain = getChain("another_custom_chain"); - assertEq(anotherCustomChain.name, "Another Custom Chain"); - assertEq(anotherCustomChain.chainId, 987654321); - assertEq(anotherCustomChain.chainAlias, "another_custom_chain"); - assertEq(anotherCustomChain.rpcUrl, "https://custom.chain/"); - // Verify the first chain data was not overwritten - chainById = getChain(123456789); - assertEq(chainById.name, "Custom Chain"); - assertEq(chainById.chainId, 123456789); - } - - function test_RevertIf_SetEmptyAlias() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains setChain(string,ChainData): Chain alias cannot be the empty string."); - stdChainsMock.exposedSetChain("", ChainData("", 123456789, "")); - } - - function test_RevertIf_SetNoChainId0() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains setChain(string,ChainData): Chain ID cannot be 0."); - stdChainsMock.exposedSetChain("alias", ChainData("", 0, "")); - } - - function test_RevertIf_GetNoChainId0() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(uint256): Chain ID cannot be 0."); - stdChainsMock.exposedGetChain(0); - } - - function test_RevertIf_GetNoEmptyAlias() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(string): Chain alias cannot be the empty string."); - stdChainsMock.exposedGetChain(""); - } - - function test_RevertIf_ChainNotInitialized() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(string): Chain with alias \"no_such_alias\" not found."); - stdChainsMock.exposedGetChain("no_such_alias"); - } - - function test_RevertIf_ChainAliasNotFound() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(uint256): Chain with ID 321 not found."); - - stdChainsMock.exposedGetChain(321); - } - - function test_SetChain_ExistingOne() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - setChain("custom_chain", ChainData("Custom Chain", 123456789, "https://custom.chain/")); - assertEq(getChain(123456789).chainId, 123456789); - - setChain("custom_chain", ChainData("Modified Chain", 9999999999999999999, "https://modified.chain/")); - vm.expectRevert("StdChains getChain(uint256): Chain with ID 123456789 not found."); - stdChainsMock.exposedGetChain(123456789); - - Chain memory modifiedChain = getChain(9999999999999999999); - assertEq(modifiedChain.name, "Modified Chain"); - assertEq(modifiedChain.chainId, 9999999999999999999); - assertEq(modifiedChain.rpcUrl, "https://modified.chain/"); - } - - function test_RevertIf_DontUseDefaultRpcUrl() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - // Should error if default RPCs flag is set to false. - stdChainsMock.exposedSetFallbackToDefaultRpcUrls(false); - vm.expectRevert(); - stdChainsMock.exposedGetChain(31337); - vm.expectRevert(); - stdChainsMock.exposedGetChain("sepolia"); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdCheats.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdCheats.t.sol deleted file mode 100644 index 33c819a68a..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdCheats.t.sol +++ /dev/null @@ -1,638 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {StdCheats} from "../src/StdCheats.sol"; -import {Test} from "../src/Test.sol"; -import {stdJson} from "../src/StdJson.sol"; -import {stdToml} from "../src/StdToml.sol"; -import {IERC20} from "../src/interfaces/IERC20.sol"; - -contract StdCheatsTest is Test { - Bar test; - - using stdJson for string; - - function setUp() public { - test = new Bar(); - } - - function test_Skip() public { - vm.warp(100); - skip(25); - assertEq(block.timestamp, 125); - } - - function test_Rewind() public { - vm.warp(100); - rewind(25); - assertEq(block.timestamp, 75); - } - - function test_Hoax() public { - hoax(address(1337)); - test.bar{value: 100}(address(1337)); - } - - function test_HoaxOrigin() public { - hoax(address(1337), address(1337)); - test.origin{value: 100}(address(1337)); - } - - function test_HoaxDifferentAddresses() public { - hoax(address(1337), address(7331)); - test.origin{value: 100}(address(1337), address(7331)); - } - - function test_StartHoax() public { - startHoax(address(1337)); - test.bar{value: 100}(address(1337)); - test.bar{value: 100}(address(1337)); - vm.stopPrank(); - test.bar(address(this)); - } - - function test_StartHoaxOrigin() public { - startHoax(address(1337), address(1337)); - test.origin{value: 100}(address(1337)); - test.origin{value: 100}(address(1337)); - vm.stopPrank(); - test.bar(address(this)); - } - - function test_ChangePrankMsgSender() public { - vm.startPrank(address(1337)); - test.bar(address(1337)); - changePrank(address(0xdead)); - test.bar(address(0xdead)); - changePrank(address(1337)); - test.bar(address(1337)); - vm.stopPrank(); - } - - function test_ChangePrankMsgSenderAndTxOrigin() public { - vm.startPrank(address(1337), address(1338)); - test.origin(address(1337), address(1338)); - changePrank(address(0xdead), address(0xbeef)); - test.origin(address(0xdead), address(0xbeef)); - changePrank(address(1337), address(1338)); - test.origin(address(1337), address(1338)); - vm.stopPrank(); - } - - function test_MakeAccountEquivalence() public { - Account memory account = makeAccount("1337"); - (address addr, uint256 key) = makeAddrAndKey("1337"); - assertEq(account.addr, addr); - assertEq(account.key, key); - } - - function test_MakeAddrEquivalence() public { - (address addr,) = makeAddrAndKey("1337"); - assertEq(makeAddr("1337"), addr); - } - - function test_MakeAddrSigning() public { - (address addr, uint256 key) = makeAddrAndKey("1337"); - bytes32 hash = keccak256("some_message"); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign(key, hash); - assertEq(ecrecover(hash, v, r, s), addr); - } - - function test_Deal() public { - deal(address(this), 1 ether); - assertEq(address(this).balance, 1 ether); - } - - function test_DealToken() public { - Bar barToken = new Bar(); - address bar = address(barToken); - deal(bar, address(this), 10000e18); - assertEq(barToken.balanceOf(address(this)), 10000e18); - } - - function test_DealTokenAdjustTotalSupply() public { - Bar barToken = new Bar(); - address bar = address(barToken); - deal(bar, address(this), 10000e18, true); - assertEq(barToken.balanceOf(address(this)), 10000e18); - assertEq(barToken.totalSupply(), 20000e18); - deal(bar, address(this), 0, true); - assertEq(barToken.balanceOf(address(this)), 0); - assertEq(barToken.totalSupply(), 10000e18); - } - - function test_DealERC1155Token() public { - BarERC1155 barToken = new BarERC1155(); - address bar = address(barToken); - dealERC1155(bar, address(this), 0, 10000e18, false); - assertEq(barToken.balanceOf(address(this), 0), 10000e18); - } - - function test_DealERC1155TokenAdjustTotalSupply() public { - BarERC1155 barToken = new BarERC1155(); - address bar = address(barToken); - dealERC1155(bar, address(this), 0, 10000e18, true); - assertEq(barToken.balanceOf(address(this), 0), 10000e18); - assertEq(barToken.totalSupply(0), 20000e18); - dealERC1155(bar, address(this), 0, 0, true); - assertEq(barToken.balanceOf(address(this), 0), 0); - assertEq(barToken.totalSupply(0), 10000e18); - } - - function test_DealERC721Token() public { - BarERC721 barToken = new BarERC721(); - address bar = address(barToken); - dealERC721(bar, address(2), 1); - assertEq(barToken.balanceOf(address(2)), 1); - assertEq(barToken.balanceOf(address(1)), 0); - dealERC721(bar, address(1), 2); - assertEq(barToken.balanceOf(address(1)), 1); - assertEq(barToken.balanceOf(bar), 1); - } - - function test_DeployCode() public { - address deployed = deployCode("StdCheats.t.sol:Bar", bytes("")); - assertEq(string(getCode(deployed)), string(getCode(address(test)))); - } - - function test_DestroyAccount() public { - // deploy something to destroy it - BarERC721 barToken = new BarERC721(); - address bar = address(barToken); - vm.setNonce(bar, 10); - deal(bar, 100); - - uint256 prevThisBalance = address(this).balance; - uint256 size; - assembly { - size := extcodesize(bar) - } - - assertGt(size, 0); - assertEq(bar.balance, 100); - assertEq(vm.getNonce(bar), 10); - - destroyAccount(bar, address(this)); - assembly { - size := extcodesize(bar) - } - assertEq(address(this).balance, prevThisBalance + 100); - assertEq(vm.getNonce(bar), 0); - assertEq(size, 0); - assertEq(bar.balance, 0); - } - - function test_DeployCodeNoArgs() public { - address deployed = deployCode("StdCheats.t.sol:Bar"); - assertEq(string(getCode(deployed)), string(getCode(address(test)))); - } - - function test_DeployCodeVal() public { - address deployed = deployCode("StdCheats.t.sol:Bar", bytes(""), 1 ether); - assertEq(string(getCode(deployed)), string(getCode(address(test)))); - assertEq(deployed.balance, 1 ether); - } - - function test_DeployCodeValNoArgs() public { - address deployed = deployCode("StdCheats.t.sol:Bar", 1 ether); - assertEq(string(getCode(deployed)), string(getCode(address(test)))); - assertEq(deployed.balance, 1 ether); - } - - // We need this so we can call "this.deployCode" rather than "deployCode" directly - function deployCodeHelper(string memory what) external { - deployCode(what); - } - - function test_RevertIf_DeployCodeFail() public { - vm.expectRevert(bytes("StdCheats deployCode(string): Deployment failed.")); - this.deployCodeHelper("StdCheats.t.sol:RevertingContract"); - } - - function getCode(address who) internal view returns (bytes memory o_code) { - assembly ("memory-safe") { - // retrieve the size of the code, this needs assembly - let size := extcodesize(who) - // allocate output byte array - this could also be done without assembly - // by using o_code = new bytes(size) - o_code := mload(0x40) - // new "memory end" including padding - mstore(0x40, add(o_code, and(add(add(size, 0x20), 0x1f), not(0x1f)))) - // store length in memory - mstore(o_code, size) - // actually retrieve the code, this needs assembly - extcodecopy(who, add(o_code, 0x20), 0, size) - } - } - - function test_DeriveRememberKey() public { - string memory mnemonic = "test test test test test test test test test test test junk"; - - (address deployer, uint256 privateKey) = deriveRememberKey(mnemonic, 0); - assertEq(deployer, 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266); - assertEq(privateKey, 0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80); - } - - function test_BytesToUint() public pure { - assertEq(3, bytesToUint_test(hex"03")); - assertEq(2, bytesToUint_test(hex"02")); - assertEq(255, bytesToUint_test(hex"ff")); - assertEq(29625, bytesToUint_test(hex"73b9")); - } - - function test_ParseJsonTxDetail() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - string memory json = vm.readFile(path); - bytes memory transactionDetails = json.parseRaw(".transactions[0].tx"); - RawTx1559Detail memory rawTxDetail = abi.decode(transactionDetails, (RawTx1559Detail)); - Tx1559Detail memory txDetail = rawToConvertedEIP1559Detail(rawTxDetail); - assertEq(txDetail.from, 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266); - assertEq(txDetail.to, 0xe7f1725E7734CE288F8367e1Bb143E90bb3F0512); - assertEq( - txDetail.data, - hex"23e99187000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000013370000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000000004" - ); - assertEq(txDetail.nonce, 3); - assertEq(txDetail.txType, 2); - assertEq(txDetail.gas, 29625); - assertEq(txDetail.value, 0); - } - - function test_ReadEIP1559Transaction() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - uint256 index = 0; - Tx1559 memory transaction = readTx1559(path, index); - transaction; - } - - function test_ReadEIP1559Transactions() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - Tx1559[] memory transactions = readTx1559s(path); - transactions; - } - - function test_ReadReceipt() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - uint256 index = 5; - Receipt memory receipt = readReceipt(path, index); - assertEq( - receipt.logsBloom, - hex"00000000000800000000000000000010000000000000000000000000000180000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100" - ); - } - - function test_ReadReceipts() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - Receipt[] memory receipts = readReceipts(path); - receipts; - } - - function test_GasMeteringModifier() public { - uint256 gas_start_normal = gasleft(); - addInLoop(); - uint256 gas_used_normal = gas_start_normal - gasleft(); - - uint256 gas_start_single = gasleft(); - addInLoopNoGas(); - uint256 gas_used_single = gas_start_single - gasleft(); - - uint256 gas_start_double = gasleft(); - addInLoopNoGasNoGas(); - uint256 gas_used_double = gas_start_double - gasleft(); - - assertTrue(gas_used_double + gas_used_single < gas_used_normal); - } - - function addInLoop() internal pure returns (uint256) { - uint256 b; - for (uint256 i; i < 10000; i++) { - b += i; - } - return b; - } - - function addInLoopNoGas() internal noGasMetering returns (uint256) { - return addInLoop(); - } - - function addInLoopNoGasNoGas() internal noGasMetering returns (uint256) { - return addInLoopNoGas(); - } - - function bytesToUint_test(bytes memory b) private pure returns (uint256) { - uint256 number; - for (uint256 i = 0; i < b.length; i++) { - number = number + uint256(uint8(b[i])) * (2 ** (8 * (b.length - (i + 1)))); - } - return number; - } - - function testFuzz_AssumeAddressIsNot(address addr) external { - // skip over Payable and NonPayable enums - for (uint8 i = 2; i < uint8(type(AddressType).max); i++) { - assumeAddressIsNot(addr, AddressType(i)); - } - assertTrue(addr != address(0)); - assertTrue(addr < address(1) || addr > address(9)); - assertTrue(addr != address(vm) || addr != 0x000000000000000000636F6e736F6c652e6c6f67); - } - - function test_AssumePayable() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - - // all should revert since these addresses are not payable - - // VM address - vm.expectRevert(); - stdCheatsMock.exposedAssumePayable(0x7109709ECfa91a80626fF3989D68f67F5b1DD12D); - - // Console address - vm.expectRevert(); - stdCheatsMock.exposedAssumePayable(0x000000000000000000636F6e736F6c652e6c6f67); - - // Create2Deployer - vm.expectRevert(); - stdCheatsMock.exposedAssumePayable(0x4e59b44847b379578588920cA78FbF26c0B4956C); - - // all should pass since these addresses are payable - - // vitalik.eth - stdCheatsMock.exposedAssumePayable(0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045); - - // mock payable contract - MockContractPayable cp = new MockContractPayable(); - stdCheatsMock.exposedAssumePayable(address(cp)); - } - - function test_AssumeNotPayable() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - - // all should pass since these addresses are not payable - - // VM address - stdCheatsMock.exposedAssumeNotPayable(0x7109709ECfa91a80626fF3989D68f67F5b1DD12D); - - // Console address - stdCheatsMock.exposedAssumeNotPayable(0x000000000000000000636F6e736F6c652e6c6f67); - - // Create2Deployer - stdCheatsMock.exposedAssumeNotPayable(0x4e59b44847b379578588920cA78FbF26c0B4956C); - - // all should revert since these addresses are payable - - // vitalik.eth - vm.expectRevert(); - stdCheatsMock.exposedAssumeNotPayable(0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045); - - // mock payable contract - MockContractPayable cp = new MockContractPayable(); - vm.expectRevert(); - stdCheatsMock.exposedAssumeNotPayable(address(cp)); - } - - function testFuzz_AssumeNotPrecompile(address addr) external { - assumeNotPrecompile(addr, getChain("optimism_sepolia").chainId); - assertTrue( - addr < address(1) || (addr > address(9) && addr < address(0x4200000000000000000000000000000000000000)) - || addr > address(0x4200000000000000000000000000000000000800) - ); - } - - function testFuzz_AssumeNotForgeAddress(address addr) external pure { - assumeNotForgeAddress(addr); - assertTrue( - addr != address(vm) && addr != 0x000000000000000000636F6e736F6c652e6c6f67 - && addr != 0x4e59b44847b379578588920cA78FbF26c0B4956C - ); - } - - function test_RevertIf_CannotDeployCodeTo() external { - vm.expectRevert("StdCheats deployCodeTo(string,bytes,uint256,address): Failed to create runtime bytecode."); - this._revertDeployCodeTo(); - } - - function _revertDeployCodeTo() external { - deployCodeTo("StdCheats.t.sol:RevertingContract", address(0)); - } - - function test_DeployCodeTo() external { - address arbitraryAddress = makeAddr("arbitraryAddress"); - - deployCodeTo( - "StdCheats.t.sol:MockContractWithConstructorArgs", - abi.encode(uint256(6), true, bytes20(arbitraryAddress)), - 1 ether, - arbitraryAddress - ); - - MockContractWithConstructorArgs ct = MockContractWithConstructorArgs(arbitraryAddress); - - assertEq(arbitraryAddress.balance, 1 ether); - assertEq(ct.x(), 6); - assertTrue(ct.y()); - assertEq(ct.z(), bytes20(arbitraryAddress)); - } -} - -contract StdCheatsMock is StdCheats { - function exposedAssumePayable(address addr) external { - assumePayable(addr); - } - - function exposedAssumeNotPayable(address addr) external { - assumeNotPayable(addr); - } - - // We deploy a mock version so we can properly test expected reverts. - function exposedAssumeNotBlacklisted(address token, address addr) external view { - return assumeNotBlacklisted(token, addr); - } -} - -contract StdCheatsForkTest is Test { - address internal constant USDC_BLACKLISTED_USER = 0x1E34A77868E19A6647b1f2F47B51ed72dEDE95DD; - address internal constant USDT_BLACKLISTED_USER = 0x8f8a8F4B54a2aAC7799d7bc81368aC27b852822A; - - MockUSDT public USDT; - MockUSDC public USDC; - - function setUp() public { - USDT = new MockUSDT(); - USDC = new MockUSDC(); - - USDC.setBlacklisted(USDC_BLACKLISTED_USER, true); - USDT.setBlacklisted(USDT_BLACKLISTED_USER, true); - } - - function test_RevertIf_CannotAssumeNoBlacklisted_EOA() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - address eoa = vm.addr({privateKey: 1}); - vm.expectRevert("StdCheats assumeNotBlacklisted(address,address): Token address is not a contract."); - stdCheatsMock.exposedAssumeNotBlacklisted(eoa, address(0)); - } - - function testFuzz_AssumeNotBlacklisted_TokenWithoutBlacklist(address addr) external view { - assumeNotBlacklisted(address(USDC), addr); - assumeNotBlacklisted(address(USDT), addr); - assertTrue(true); - } - - function test_RevertIf_AssumeNoBlacklisted_USDC() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - vm.expectRevert(); - stdCheatsMock.exposedAssumeNotBlacklisted(address(USDC), USDC_BLACKLISTED_USER); - } - - function testFuzz_AssumeNotBlacklisted_USDC(address addr) external view { - assumeNotBlacklisted(address(USDC), addr); - assertFalse(USDCLike(USDC).isBlacklisted(addr)); - } - - function test_RevertIf_AssumeNoBlacklisted_USDT() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - vm.expectRevert(); - stdCheatsMock.exposedAssumeNotBlacklisted(address(USDT), USDT_BLACKLISTED_USER); - } - - function testFuzz_AssumeNotBlacklisted_USDT(address addr) external view { - assumeNotBlacklisted(address(USDT), addr); - assertFalse(USDTLike(USDT).isBlackListed(addr)); - } -} - -/// @dev https://etherscan.io/token/0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48#readProxyContract -interface USDCLike { - function isBlacklisted(address) external view returns (bool); -} - -/// @dev https://etherscan.io/token/0xdac17f958d2ee523a2206206994597c13d831ec7#readContract -interface USDTLike { - function isBlackListed(address) external view returns (bool); -} - -contract MockUSDT is USDTLike { - mapping(address => bool) private blacklist; - - function isBlackListed(address addr) external view returns (bool) { - return blacklist[addr]; - } - - function setBlacklisted(address addr, bool value) external { - blacklist[addr] = value; - } -} - -contract MockUSDC is USDCLike { - mapping(address => bool) private blacklist; - - function isBlacklisted(address addr) external view returns (bool) { - return blacklist[addr]; - } - - function setBlacklisted(address addr, bool value) external { - blacklist[addr] = value; - } -} - -contract Bar { - constructor() payable { - /// `DEAL` STDCHEAT - totalSupply = 10000e18; - balanceOf[address(this)] = totalSupply; - } - - /// `HOAX` and `CHANGEPRANK` STDCHEATS - function bar(address expectedSender) public payable { - require(msg.sender == expectedSender, "!prank"); - } - - function origin(address expectedSender) public payable { - require(msg.sender == expectedSender, "!prank"); - require(tx.origin == expectedSender, "!prank"); - } - - function origin(address expectedSender, address expectedOrigin) public payable { - require(msg.sender == expectedSender, "!prank"); - require(tx.origin == expectedOrigin, "!prank"); - } - - /// `DEAL` STDCHEAT - mapping(address => uint256) public balanceOf; - uint256 public totalSupply; -} - -contract BarERC1155 { - constructor() payable { - /// `DEALERC1155` STDCHEAT - _totalSupply[0] = 10000e18; - _balances[0][address(this)] = _totalSupply[0]; - } - - function balanceOf(address account, uint256 id) public view virtual returns (uint256) { - return _balances[id][account]; - } - - function totalSupply(uint256 id) public view virtual returns (uint256) { - return _totalSupply[id]; - } - - /// `DEALERC1155` STDCHEAT - mapping(uint256 => mapping(address => uint256)) private _balances; - mapping(uint256 => uint256) private _totalSupply; -} - -contract BarERC721 { - constructor() payable { - /// `DEALERC721` STDCHEAT - _owners[1] = address(1); - _balances[address(1)] = 1; - _owners[2] = address(this); - _owners[3] = address(this); - _balances[address(this)] = 2; - } - - function balanceOf(address owner) public view virtual returns (uint256) { - return _balances[owner]; - } - - function ownerOf(uint256 tokenId) public view virtual returns (address) { - address owner = _owners[tokenId]; - return owner; - } - - mapping(uint256 => address) private _owners; - mapping(address => uint256) private _balances; -} - -contract RevertingContract { - constructor() { - revert(); - } -} - -contract MockContractWithConstructorArgs { - uint256 public immutable x; - bool public y; - bytes20 public z; - - constructor(uint256 _x, bool _y, bytes20 _z) payable { - x = _x; - y = _y; - z = _z; - } -} - -contract MockContractPayable { - receive() external payable {} -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdConstants.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdConstants.t.sol deleted file mode 100644 index 8ed524ecde..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdConstants.t.sol +++ /dev/null @@ -1,38 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {StdConstants} from "../src/StdConstants.sol"; -import {Test} from "../src/Test.sol"; - -contract StdConstantsTest is Test { - function testVm() public view { - assertEq(StdConstants.VM.getBlockNumber(), 1); - } - - function testVmDerivation() public pure { - assertEq(address(StdConstants.VM), address(uint160(uint256(keccak256("hevm cheat code"))))); - } - - function testConsoleDerivation() public pure { - assertEq(StdConstants.CONSOLE, address(uint160(uint88(bytes11("console.log"))))); - } - - function testDefaultSender() public view { - assertEq(StdConstants.DEFAULT_SENDER, msg.sender); - } - - function testDefaultSenderDerivation() public pure { - assertEq(StdConstants.DEFAULT_SENDER, address(uint160(uint256(keccak256("foundry default caller"))))); - } - - function testDefaultTestContract() public { - assertEq(StdConstants.DEFAULT_TEST_CONTRACT, address(new Dummy())); - } - - function testDefaultTestContractDerivation() public view { - assertEq(address(this), StdConstants.VM.computeCreateAddress(StdConstants.DEFAULT_SENDER, 1)); - assertEq(StdConstants.DEFAULT_TEST_CONTRACT, StdConstants.VM.computeCreateAddress(address(this), 1)); - } -} - -contract Dummy {} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdError.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdError.t.sol deleted file mode 100644 index 7553ce4acc..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdError.t.sol +++ /dev/null @@ -1,119 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {stdError} from "../src/StdError.sol"; -import {Test} from "../src/Test.sol"; - -contract StdErrorsTest is Test { - ErrorsTest test; - - function setUp() public { - test = new ErrorsTest(); - } - - function test_RevertIf_AssertionError() public { - vm.expectRevert(stdError.assertionError); - test.assertionError(); - } - - function test_RevertIf_ArithmeticError() public { - vm.expectRevert(stdError.arithmeticError); - test.arithmeticError(10); - } - - function test_RevertIf_DivisionError() public { - vm.expectRevert(stdError.divisionError); - test.divError(0); - } - - function test_RevertIf_ModError() public { - vm.expectRevert(stdError.divisionError); - test.modError(0); - } - - function test_RevertIf_EnumConversionError() public { - vm.expectRevert(stdError.enumConversionError); - test.enumConversion(1); - } - - function test_RevertIf_EncodeStgError() public { - vm.expectRevert(stdError.encodeStorageError); - test.encodeStgError(); - } - - function test_RevertIf_PopError() public { - vm.expectRevert(stdError.popError); - test.pop(); - } - - function test_RevertIf_IndexOOBError() public { - vm.expectRevert(stdError.indexOOBError); - test.indexOOBError(1); - } - - function test_RevertIf_MemOverflowError() public { - vm.expectRevert(stdError.memOverflowError); - test.mem(); - } - - function test_RevertIf_InternError() public { - vm.expectRevert(stdError.zeroVarError); - test.intern(); - } -} - -contract ErrorsTest { - enum T { - T1 - } - - uint256[] public someArr; - bytes someBytes; - - function assertionError() public pure { - assert(false); - } - - function arithmeticError(uint256 a) public pure { - a -= 100; - } - - function divError(uint256 a) public pure { - 100 / a; - } - - function modError(uint256 a) public pure { - 100 % a; - } - - function enumConversion(uint256 a) public pure { - T(a); - } - - function encodeStgError() public { - assembly ("memory-safe") { - sstore(someBytes.slot, 1) - } - keccak256(someBytes); - } - - function pop() public { - someArr.pop(); - } - - function indexOOBError(uint256 a) public pure { - uint256[] memory t = new uint256[](0); - t[a]; - } - - function mem() public pure { - uint256 l = 2 ** 256 / 32; - new uint256[](l); - } - - function intern() public returns (uint256) { - function(uint256) internal returns (uint256) x; - x(2); - return 7; - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdJson.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdJson.t.sol deleted file mode 100644 index 5594a54a8a..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdJson.t.sol +++ /dev/null @@ -1,49 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {Test, stdJson} from "../src/Test.sol"; - -contract StdJsonTest is Test { - using stdJson for string; - - string root; - string path; - - function setUp() public { - root = vm.projectRoot(); - path = string.concat(root, "/test/fixtures/test.json"); - } - - struct SimpleJson { - uint256 a; - string b; - } - - struct NestedJson { - uint256 a; - string b; - SimpleJson c; - } - - function test_readJson() public view { - string memory json = vm.readFile(path); - assertEq(json.readUint(".a"), 123); - } - - function test_writeJson() public { - string memory json = "json"; - json.serialize("a", uint256(123)); - string memory semiFinal = json.serialize("b", string("test")); - string memory finalJson = json.serialize("c", semiFinal); - finalJson.write(path); - - string memory json_ = vm.readFile(path); - bytes memory data = json_.parseRaw("$"); - NestedJson memory decodedData = abi.decode(data, (NestedJson)); - - assertEq(decodedData.a, 123); - assertEq(decodedData.b, "test"); - assertEq(decodedData.c.a, 123); - assertEq(decodedData.c.b, "test"); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdMath.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdMath.t.sol deleted file mode 100644 index c7a36ed4dc..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdMath.t.sol +++ /dev/null @@ -1,202 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {stdMath} from "../src/StdMath.sol"; -import {Test, stdError} from "../src/Test.sol"; - -contract StdMathMock is Test { - function exposedPercentDelta(uint256 a, uint256 b) public pure returns (uint256) { - return stdMath.percentDelta(a, b); - } - - function exposedPercentDelta(int256 a, int256 b) public pure returns (uint256) { - return stdMath.percentDelta(a, b); - } -} - -contract StdMathTest is Test { - function test_GetAbs() external pure { - assertEq(stdMath.abs(-50), 50); - assertEq(stdMath.abs(50), 50); - assertEq(stdMath.abs(-1337), 1337); - assertEq(stdMath.abs(0), 0); - - assertEq(stdMath.abs(type(int256).min), (type(uint256).max >> 1) + 1); - assertEq(stdMath.abs(type(int256).max), (type(uint256).max >> 1)); - } - - function testFuzz_GetAbs(int256 a) external pure { - uint256 manualAbs = getAbs(a); - - uint256 abs = stdMath.abs(a); - - assertEq(abs, manualAbs); - } - - function test_GetDelta_Uint() external pure { - assertEq(stdMath.delta(uint256(0), uint256(0)), 0); - assertEq(stdMath.delta(uint256(0), uint256(1337)), 1337); - assertEq(stdMath.delta(uint256(0), type(uint64).max), type(uint64).max); - assertEq(stdMath.delta(uint256(0), type(uint128).max), type(uint128).max); - assertEq(stdMath.delta(uint256(0), type(uint256).max), type(uint256).max); - - assertEq(stdMath.delta(0, uint256(0)), 0); - assertEq(stdMath.delta(1337, uint256(0)), 1337); - assertEq(stdMath.delta(type(uint64).max, uint256(0)), type(uint64).max); - assertEq(stdMath.delta(type(uint128).max, uint256(0)), type(uint128).max); - assertEq(stdMath.delta(type(uint256).max, uint256(0)), type(uint256).max); - - assertEq(stdMath.delta(1337, uint256(1337)), 0); - assertEq(stdMath.delta(type(uint256).max, type(uint256).max), 0); - assertEq(stdMath.delta(5000, uint256(1250)), 3750); - } - - function testFuzz_GetDelta_Uint(uint256 a, uint256 b) external pure { - uint256 manualDelta = a > b ? a - b : b - a; - - uint256 delta = stdMath.delta(a, b); - - assertEq(delta, manualDelta); - } - - function test_GetDelta_Int() external pure { - assertEq(stdMath.delta(int256(0), int256(0)), 0); - assertEq(stdMath.delta(int256(0), int256(1337)), 1337); - assertEq(stdMath.delta(int256(0), type(int64).max), type(uint64).max >> 1); - assertEq(stdMath.delta(int256(0), type(int128).max), type(uint128).max >> 1); - assertEq(stdMath.delta(int256(0), type(int256).max), type(uint256).max >> 1); - - assertEq(stdMath.delta(0, int256(0)), 0); - assertEq(stdMath.delta(1337, int256(0)), 1337); - assertEq(stdMath.delta(type(int64).max, int256(0)), type(uint64).max >> 1); - assertEq(stdMath.delta(type(int128).max, int256(0)), type(uint128).max >> 1); - assertEq(stdMath.delta(type(int256).max, int256(0)), type(uint256).max >> 1); - - assertEq(stdMath.delta(-0, int256(0)), 0); - assertEq(stdMath.delta(-1337, int256(0)), 1337); - assertEq(stdMath.delta(type(int64).min, int256(0)), (type(uint64).max >> 1) + 1); - assertEq(stdMath.delta(type(int128).min, int256(0)), (type(uint128).max >> 1) + 1); - assertEq(stdMath.delta(type(int256).min, int256(0)), (type(uint256).max >> 1) + 1); - - assertEq(stdMath.delta(int256(0), -0), 0); - assertEq(stdMath.delta(int256(0), -1337), 1337); - assertEq(stdMath.delta(int256(0), type(int64).min), (type(uint64).max >> 1) + 1); - assertEq(stdMath.delta(int256(0), type(int128).min), (type(uint128).max >> 1) + 1); - assertEq(stdMath.delta(int256(0), type(int256).min), (type(uint256).max >> 1) + 1); - - assertEq(stdMath.delta(1337, int256(1337)), 0); - assertEq(stdMath.delta(type(int256).max, type(int256).max), 0); - assertEq(stdMath.delta(type(int256).min, type(int256).min), 0); - assertEq(stdMath.delta(type(int256).min, type(int256).max), type(uint256).max); - assertEq(stdMath.delta(5000, int256(1250)), 3750); - } - - function testFuzz_GetDelta_Int(int256 a, int256 b) external pure { - uint256 absA = getAbs(a); - uint256 absB = getAbs(b); - uint256 absDelta = absA > absB ? absA - absB : absB - absA; - - uint256 manualDelta; - if ((a >= 0 && b >= 0) || (a < 0 && b < 0)) { - manualDelta = absDelta; - } - // (a < 0 && b >= 0) || (a >= 0 && b < 0) - else { - manualDelta = absA + absB; - } - - uint256 delta = stdMath.delta(a, b); - - assertEq(delta, manualDelta); - } - - function test_GetPercentDelta_Uint() external { - StdMathMock stdMathMock = new StdMathMock(); - - assertEq(stdMath.percentDelta(uint256(0), uint256(1337)), 1e18); - assertEq(stdMath.percentDelta(uint256(0), type(uint64).max), 1e18); - assertEq(stdMath.percentDelta(uint256(0), type(uint128).max), 1e18); - assertEq(stdMath.percentDelta(uint256(0), type(uint192).max), 1e18); - - assertEq(stdMath.percentDelta(1337, uint256(1337)), 0); - assertEq(stdMath.percentDelta(type(uint192).max, type(uint192).max), 0); - assertEq(stdMath.percentDelta(0, uint256(2500)), 1e18); - assertEq(stdMath.percentDelta(2500, uint256(2500)), 0); - assertEq(stdMath.percentDelta(5000, uint256(2500)), 1e18); - assertEq(stdMath.percentDelta(7500, uint256(2500)), 2e18); - - vm.expectRevert("stdMath percentDelta(uint256,uint256): Divisor is zero"); - stdMathMock.exposedPercentDelta(uint256(1), 0); - } - - function testFuzz_GetPercentDelta_Uint(uint192 a, uint192 b) external pure { - vm.assume(b != 0); - uint256 manualDelta = a > b ? a - b : b - a; - - uint256 manualPercentDelta = manualDelta * 1e18 / b; - uint256 percentDelta = stdMath.percentDelta(a, b); - - assertEq(percentDelta, manualPercentDelta); - } - - function test_GetPercentDelta_Int() external { - // We deploy a mock version so we can properly test the revert. - StdMathMock stdMathMock = new StdMathMock(); - - assertEq(stdMath.percentDelta(int256(0), int256(1337)), 1e18); - assertEq(stdMath.percentDelta(int256(0), -1337), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int64).min), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int128).min), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int192).min), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int64).max), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int128).max), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int192).max), 1e18); - - assertEq(stdMath.percentDelta(1337, int256(1337)), 0); - assertEq(stdMath.percentDelta(type(int192).max, type(int192).max), 0); - assertEq(stdMath.percentDelta(type(int192).min, type(int192).min), 0); - - assertEq(stdMath.percentDelta(type(int192).min, type(int192).max), 2e18); // rounds the 1 wei diff down - assertEq(stdMath.percentDelta(type(int192).max, type(int192).min), 2e18 - 1); // rounds the 1 wei diff down - assertEq(stdMath.percentDelta(0, int256(2500)), 1e18); - assertEq(stdMath.percentDelta(2500, int256(2500)), 0); - assertEq(stdMath.percentDelta(5000, int256(2500)), 1e18); - assertEq(stdMath.percentDelta(7500, int256(2500)), 2e18); - - vm.expectRevert("stdMath percentDelta(int256,int256): Divisor is zero"); - stdMathMock.exposedPercentDelta(int256(1), 0); - } - - function testFuzz_GetPercentDelta_Int(int192 a, int192 b) external pure { - vm.assume(b != 0); - uint256 absA = getAbs(a); - uint256 absB = getAbs(b); - uint256 absDelta = absA > absB ? absA - absB : absB - absA; - - uint256 manualDelta; - if ((a >= 0 && b >= 0) || (a < 0 && b < 0)) { - manualDelta = absDelta; - } - // (a < 0 && b >= 0) || (a >= 0 && b < 0) - else { - manualDelta = absA + absB; - } - - uint256 manualPercentDelta = manualDelta * 1e18 / absB; - uint256 percentDelta = stdMath.percentDelta(a, b); - - assertEq(percentDelta, manualPercentDelta); - } - - /*////////////////////////////////////////////////////////////////////////// - HELPERS - //////////////////////////////////////////////////////////////////////////*/ - - function getAbs(int256 a) private pure returns (uint256) { - if (a < 0) { - return a == type(int256).min ? uint256(type(int256).max) + 1 : uint256(-a); - } - - return uint256(a); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdStorage.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdStorage.t.sol deleted file mode 100644 index 6a97ae46ff..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdStorage.t.sol +++ /dev/null @@ -1,485 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {stdStorage, StdStorage} from "../src/StdStorage.sol"; -import {Test} from "../src/Test.sol"; - -contract StdStorageTest is Test { - using stdStorage for StdStorage; - - StorageTest internal test; - - function setUp() public { - test = new StorageTest(); - } - - function test_StorageHidden() public { - assertEq(uint256(keccak256("my.random.var")), stdstore.target(address(test)).sig("hidden()").find()); - } - - function test_StorageObvious() public { - assertEq(uint256(0), stdstore.target(address(test)).sig("exists()").find()); - } - - function test_StorageExtraSload() public { - assertEq(16, stdstore.target(address(test)).sig(test.extra_sload.selector).find()); - } - - function test_StorageCheckedWriteHidden() public { - stdstore.target(address(test)).sig(test.hidden.selector).checked_write(100); - assertEq(uint256(test.hidden()), 100); - } - - function test_StorageCheckedWriteObvious() public { - stdstore.target(address(test)).sig(test.exists.selector).checked_write(100); - assertEq(test.exists(), 100); - } - - function test_StorageCheckedWriteSignedIntegerHidden() public { - stdstore.target(address(test)).sig(test.hidden.selector).checked_write_int(-100); - assertEq(int256(uint256(test.hidden())), -100); - } - - function test_StorageCheckedWriteSignedIntegerObvious() public { - stdstore.target(address(test)).sig(test.tG.selector).checked_write_int(-100); - assertEq(test.tG(), -100); - } - - function test_StorageMapStructA() public { - uint256 slot = - stdstore.target(address(test)).sig(test.map_struct.selector).with_key(address(this)).depth(0).find(); - assertEq(uint256(keccak256(abi.encode(address(this), 4))), slot); - } - - function test_StorageMapStructB() public { - uint256 slot = - stdstore.target(address(test)).sig(test.map_struct.selector).with_key(address(this)).depth(1).find(); - assertEq(uint256(keccak256(abi.encode(address(this), 4))) + 1, slot); - } - - function test_StorageDeepMap() public { - uint256 slot = stdstore.target(address(test)).sig(test.deep_map.selector).with_key(address(this)) - .with_key(address(this)).find(); - assertEq(uint256(keccak256(abi.encode(address(this), keccak256(abi.encode(address(this), uint256(5)))))), slot); - } - - function test_StorageCheckedWriteDeepMap() public { - stdstore.target(address(test)).sig(test.deep_map.selector).with_key(address(this)).with_key(address(this)) - .checked_write(100); - assertEq(100, test.deep_map(address(this), address(this))); - } - - function test_StorageDeepMapStructA() public { - uint256 slot = stdstore.target(address(test)).sig(test.deep_map_struct.selector).with_key(address(this)) - .with_key(address(this)).depth(0).find(); - assertEq( - bytes32( - uint256(keccak256(abi.encode(address(this), keccak256(abi.encode(address(this), uint256(6)))))) + 0 - ), - bytes32(slot) - ); - } - - function test_StorageDeepMapStructB() public { - uint256 slot = stdstore.target(address(test)).sig(test.deep_map_struct.selector).with_key(address(this)) - .with_key(address(this)).depth(1).find(); - assertEq( - bytes32( - uint256(keccak256(abi.encode(address(this), keccak256(abi.encode(address(this), uint256(6)))))) + 1 - ), - bytes32(slot) - ); - } - - function test_StorageCheckedWriteDeepMapStructA() public { - stdstore.target(address(test)).sig(test.deep_map_struct.selector).with_key(address(this)) - .with_key(address(this)).depth(0).checked_write(100); - (uint256 a, uint256 b) = test.deep_map_struct(address(this), address(this)); - assertEq(100, a); - assertEq(0, b); - } - - function test_StorageCheckedWriteDeepMapStructB() public { - stdstore.target(address(test)).sig(test.deep_map_struct.selector).with_key(address(this)) - .with_key(address(this)).depth(1).checked_write(100); - (uint256 a, uint256 b) = test.deep_map_struct(address(this), address(this)); - assertEq(0, a); - assertEq(100, b); - } - - function test_StorageCheckedWriteMapStructA() public { - stdstore.target(address(test)).sig(test.map_struct.selector).with_key(address(this)).depth(0).checked_write(100); - (uint256 a, uint256 b) = test.map_struct(address(this)); - assertEq(a, 100); - assertEq(b, 0); - } - - function test_StorageCheckedWriteMapStructB() public { - stdstore.target(address(test)).sig(test.map_struct.selector).with_key(address(this)).depth(1).checked_write(100); - (uint256 a, uint256 b) = test.map_struct(address(this)); - assertEq(a, 0); - assertEq(b, 100); - } - - function test_StorageStructA() public { - uint256 slot = stdstore.target(address(test)).sig(test.basic.selector).depth(0).find(); - assertEq(uint256(7), slot); - } - - function test_StorageStructB() public { - uint256 slot = stdstore.target(address(test)).sig(test.basic.selector).depth(1).find(); - assertEq(uint256(7) + 1, slot); - } - - function test_StorageCheckedWriteStructA() public { - stdstore.target(address(test)).sig(test.basic.selector).depth(0).checked_write(100); - (uint256 a, uint256 b) = test.basic(); - assertEq(a, 100); - assertEq(b, 1337); - } - - function test_StorageCheckedWriteStructB() public { - stdstore.target(address(test)).sig(test.basic.selector).depth(1).checked_write(100); - (uint256 a, uint256 b) = test.basic(); - assertEq(a, 1337); - assertEq(b, 100); - } - - function test_StorageMapAddrFound() public { - uint256 slot = stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).find(); - assertEq(uint256(keccak256(abi.encode(address(this), uint256(1)))), slot); - } - - function test_StorageMapAddrRoot() public { - (uint256 slot, bytes32 key) = - stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).parent(); - assertEq(address(uint160(uint256(key))), address(this)); - assertEq(uint256(1), slot); - slot = stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).root(); - assertEq(uint256(1), slot); - } - - function test_StorageMapUintFound() public { - uint256 slot = stdstore.target(address(test)).sig(test.map_uint.selector).with_key(100).find(); - assertEq(uint256(keccak256(abi.encode(100, uint256(2)))), slot); - } - - function test_StorageCheckedWriteMapUint() public { - stdstore.target(address(test)).sig(test.map_uint.selector).with_key(100).checked_write(100); - assertEq(100, test.map_uint(100)); - } - - function test_StorageCheckedWriteMapAddr() public { - stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).checked_write(100); - assertEq(100, test.map_addr(address(this))); - } - - function test_StorageCheckedWriteMapBool() public { - stdstore.target(address(test)).sig(test.map_bool.selector).with_key(address(this)).checked_write(true); - assertTrue(test.map_bool(address(this))); - } - - function testFuzz_StorageCheckedWriteMapPacked(address addr, uint128 value) public { - stdstore.enable_packed_slots().target(address(test)).sig(test.read_struct_lower.selector).with_key(addr) - .checked_write(value); - assertEq(test.read_struct_lower(addr), value); - - stdstore.enable_packed_slots().target(address(test)).sig(test.read_struct_upper.selector).with_key(addr) - .checked_write(value); - assertEq(test.read_struct_upper(addr), value); - } - - function test_StorageCheckedWriteMapPackedFullSuccess() public { - uint256 full = test.map_packed(address(1337)); - // keep upper 128, set lower 128 to 1337 - full = (full & (uint256((1 << 128) - 1) << 128)) | 1337; - stdstore.target(address(test)).sig(test.map_packed.selector).with_key(address(uint160(1337))) - .checked_write(full); - assertEq(1337, test.read_struct_lower(address(1337))); - } - - function test_RevertStorageConst() public { - StorageTestTarget target = new StorageTestTarget(test); - - vm.expectRevert("stdStorage find(StdStorage): No storage use detected for target."); - target.expectRevertStorageConst(); - } - - function testFuzz_StorageNativePack(uint248 val1, uint248 val2, bool boolVal1, bool boolVal2) public { - stdstore.enable_packed_slots().target(address(test)).sig(test.tA.selector).checked_write(val1); - stdstore.enable_packed_slots().target(address(test)).sig(test.tB.selector).checked_write(boolVal1); - stdstore.enable_packed_slots().target(address(test)).sig(test.tC.selector).checked_write(boolVal2); - stdstore.enable_packed_slots().target(address(test)).sig(test.tD.selector).checked_write(val2); - - assertEq(test.tA(), val1); - assertEq(test.tB(), boolVal1); - assertEq(test.tC(), boolVal2); - assertEq(test.tD(), val2); - } - - function test_StorageReadBytes32() public { - bytes32 val = stdstore.target(address(test)).sig(test.tE.selector).read_bytes32(); - assertEq(val, hex"1337"); - } - - function test_StorageReadBool_False() public { - bool val = stdstore.target(address(test)).sig(test.tB.selector).read_bool(); - assertEq(val, false); - } - - function test_StorageReadBool_True() public { - bool val = stdstore.target(address(test)).sig(test.tH.selector).read_bool(); - assertEq(val, true); - } - - function test_RevertIf_ReadingNonBoolValue() public { - vm.expectRevert("stdStorage read_bool(StdStorage): Cannot decode. Make sure you are reading a bool."); - this.readNonBoolValue(); - } - - function readNonBoolValue() public { - stdstore.target(address(test)).sig(test.tE.selector).read_bool(); - } - - function test_StorageReadAddress() public { - address val = stdstore.target(address(test)).sig(test.tF.selector).read_address(); - assertEq(val, address(1337)); - } - - function test_StorageReadUint() public { - uint256 val = stdstore.target(address(test)).sig(test.exists.selector).read_uint(); - assertEq(val, 1); - } - - function test_StorageReadInt() public { - int256 val = stdstore.target(address(test)).sig(test.tG.selector).read_int(); - assertEq(val, type(int256).min); - } - - function testFuzz_Packed(uint256 val, uint8 elemToGet) public { - // This function tries an assortment of packed slots, shifts meaning number of elements - // that are packed. Shiftsizes are the size of each element, i.e. 8 means a data type that is 8 bits, 16 == 16 bits, etc. - // Combined, these determine how a slot is packed. Making it random is too hard to avoid global rejection limit - // and make it performant. - - // change the number of shifts - for (uint256 i = 1; i < 5; i++) { - uint256 shifts = i; - - elemToGet = uint8(bound(elemToGet, 0, shifts - 1)); - - uint256[] memory shiftSizes = new uint256[](shifts); - for (uint256 j; j < shifts; j++) { - shiftSizes[j] = 8 * (j + 1); - } - - test.setRandomPacking(val); - - uint256 leftBits; - uint256 rightBits; - for (uint256 j; j < shiftSizes.length; j++) { - if (j < elemToGet) { - leftBits += shiftSizes[j]; - } else if (elemToGet != j) { - rightBits += shiftSizes[j]; - } - } - - // we may have some right bits unaccounted for - leftBits += 256 - (leftBits + shiftSizes[elemToGet] + rightBits); - // clear left bits, then clear right bits and realign - uint256 expectedValToRead = (val << leftBits) >> (leftBits + rightBits); - - uint256 readVal = stdstore.target(address(test)).enable_packed_slots() - .sig("getRandomPacked(uint8,uint8[],uint8)").with_calldata(abi.encode(shifts, shiftSizes, elemToGet)) - .read_uint(); - - assertEq(readVal, expectedValToRead); - } - } - - function testFuzz_Packed2(uint256 nvars, uint256 seed) public { - // Number of random variables to generate. - nvars = bound(nvars, 1, 20); - - // This will decrease as we generate values in the below loop. - uint256 bitsRemaining = 256; - - // Generate a random value and size for each variable. - uint256[] memory vals = new uint256[](nvars); - uint256[] memory sizes = new uint256[](nvars); - uint256[] memory offsets = new uint256[](nvars); - - for (uint256 i = 0; i < nvars; i++) { - // Generate a random value and size. - offsets[i] = i == 0 ? 0 : offsets[i - 1] + sizes[i - 1]; - - uint256 nvarsRemaining = nvars - i; - uint256 maxVarSize = bitsRemaining - nvarsRemaining + 1; - sizes[i] = bound(uint256(keccak256(abi.encodePacked(seed, i + 256))), 1, maxVarSize); - bitsRemaining -= sizes[i]; - - uint256 maxVal; - uint256 varSize = sizes[i]; - assembly { - // mask = (1 << varSize) - 1 - maxVal := sub(shl(varSize, 1), 1) - } - vals[i] = bound(uint256(keccak256(abi.encodePacked(seed, i))), 0, maxVal); - } - - // Pack all values into the slot. - for (uint256 i = 0; i < nvars; i++) { - stdstore.enable_packed_slots().target(address(test)).sig("getRandomPacked(uint256,uint256)") - .with_key(sizes[i]).with_key(offsets[i]).checked_write(vals[i]); - } - - // Verify the read data matches. - for (uint256 i = 0; i < nvars; i++) { - uint256 readVal = stdstore.enable_packed_slots().target(address(test)) - .sig("getRandomPacked(uint256,uint256)").with_key(sizes[i]).with_key(offsets[i]).read_uint(); - - uint256 retVal = test.getRandomPacked(sizes[i], offsets[i]); - - assertEq(readVal, vals[i]); - assertEq(retVal, vals[i]); - } - } - - function testEdgeCaseArray() public { - stdstore.target(address(test)).sig("edgeCaseArray(uint256)").with_key(uint256(0)).checked_write(1); - assertEq(test.edgeCaseArray(0), 1); - } -} - -contract StorageTestTarget { - using stdStorage for StdStorage; - - StdStorage internal stdstore; - StorageTest internal test; - - constructor(StorageTest test_) { - test = test_; - } - - function expectRevertStorageConst() public { - stdstore.target(address(test)).sig("const()").find(); - } -} - -contract StorageTest { - uint256 public exists = 1; - mapping(address => uint256) public map_addr; - mapping(uint256 => uint256) public map_uint; - mapping(address => uint256) public map_packed; - mapping(address => UnpackedStruct) public map_struct; - mapping(address => mapping(address => uint256)) public deep_map; - mapping(address => mapping(address => UnpackedStruct)) public deep_map_struct; - UnpackedStruct public basic; - - uint248 public tA; - bool public tB; - - bool public tC = false; - uint248 public tD = 1; - - struct UnpackedStruct { - uint256 a; - uint256 b; - } - - mapping(address => bool) public map_bool; - - bytes32 public tE = hex"1337"; - address public tF = address(1337); - int256 public tG = type(int256).min; - bool public tH = true; - bytes32 private tI = ~bytes32(hex"1337"); - - uint256 randomPacking; - - // Array with length matching values of elements. - uint256[] public edgeCaseArray = [3, 3, 3]; - - constructor() { - basic = UnpackedStruct({a: 1337, b: 1337}); - - uint256 two = (1 << 128) | 1; - map_packed[msg.sender] = two; - map_packed[address(uint160(1337))] = 1 << 128; - } - - function read_struct_upper(address who) public view returns (uint256) { - return map_packed[who] >> 128; - } - - function read_struct_lower(address who) public view returns (uint256) { - return map_packed[who] & ((1 << 128) - 1); - } - - function hidden() public view returns (bytes32 t) { - bytes32 slot = keccak256("my.random.var"); - assembly ("memory-safe") { - t := sload(slot) - } - } - - function const() public pure returns (bytes32 t) { - t = bytes32(hex"1337"); - } - - function extra_sload() public view returns (bytes32 t) { - // trigger read on slot `tE`, and make a staticcall to make sure compiler doesn't optimize this SLOAD away - assembly { - pop(staticcall(gas(), sload(tE.slot), 0, 0, 0, 0)) - } - t = tI; - } - - function setRandomPacking(uint256 val) public { - randomPacking = val; - } - - function _getMask(uint256 size) internal pure returns (uint256 mask) { - assembly { - // mask = (1 << size) - 1 - mask := sub(shl(size, 1), 1) - } - } - - function setRandomPacking(uint256 val, uint256 size, uint256 offset) public { - // Generate mask based on the size of the value - uint256 mask = _getMask(size); - // Zero out all bits for the word we're about to set - uint256 cleanedWord = randomPacking & ~(mask << offset); - // Place val in the correct spot of the cleaned word - randomPacking = cleanedWord | val << offset; - } - - function getRandomPacked(uint256 size, uint256 offset) public view returns (uint256) { - // Generate mask based on the size of the value - uint256 mask = _getMask(size); - // Shift to place the bits in the correct position, and use mask to zero out remaining bits - return (randomPacking >> offset) & mask; - } - - function getRandomPacked(uint8 shifts, uint8[] memory shiftSizes, uint8 elem) public view returns (uint256) { - require(elem < shifts, "!elem"); - uint256 leftBits; - uint256 rightBits; - - for (uint256 i; i < shiftSizes.length; i++) { - if (i < elem) { - leftBits += shiftSizes[i]; - } else if (elem != i) { - rightBits += shiftSizes[i]; - } - } - - // we may have some right bits unaccounted for - leftBits += 256 - (leftBits + shiftSizes[elem] + rightBits); - - // clear left bits, then clear right bits and realign - return (randomPacking << leftBits) >> (leftBits + rightBits); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdStyle.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdStyle.t.sol deleted file mode 100644 index 1146a8df55..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdStyle.t.sol +++ /dev/null @@ -1,110 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {Test, console2, StdStyle} from "../src/Test.sol"; - -contract StdStyleTest is Test { - function test_StyleColor() public pure { - console2.log(StdStyle.red("StdStyle.red String Test")); - console2.log(StdStyle.red(uint256(10e18))); - console2.log(StdStyle.red(int256(-10e18))); - console2.log(StdStyle.red(true)); - console2.log(StdStyle.red(address(0))); - console2.log(StdStyle.redBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.redBytes32("StdStyle.redBytes32")); - console2.log(StdStyle.green("StdStyle.green String Test")); - console2.log(StdStyle.green(uint256(10e18))); - console2.log(StdStyle.green(int256(-10e18))); - console2.log(StdStyle.green(true)); - console2.log(StdStyle.green(address(0))); - console2.log(StdStyle.greenBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.greenBytes32("StdStyle.greenBytes32")); - console2.log(StdStyle.yellow("StdStyle.yellow String Test")); - console2.log(StdStyle.yellow(uint256(10e18))); - console2.log(StdStyle.yellow(int256(-10e18))); - console2.log(StdStyle.yellow(true)); - console2.log(StdStyle.yellow(address(0))); - console2.log(StdStyle.yellowBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.yellowBytes32("StdStyle.yellowBytes32")); - console2.log(StdStyle.blue("StdStyle.blue String Test")); - console2.log(StdStyle.blue(uint256(10e18))); - console2.log(StdStyle.blue(int256(-10e18))); - console2.log(StdStyle.blue(true)); - console2.log(StdStyle.blue(address(0))); - console2.log(StdStyle.blueBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.blueBytes32("StdStyle.blueBytes32")); - console2.log(StdStyle.magenta("StdStyle.magenta String Test")); - console2.log(StdStyle.magenta(uint256(10e18))); - console2.log(StdStyle.magenta(int256(-10e18))); - console2.log(StdStyle.magenta(true)); - console2.log(StdStyle.magenta(address(0))); - console2.log(StdStyle.magentaBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.magentaBytes32("StdStyle.magentaBytes32")); - console2.log(StdStyle.cyan("StdStyle.cyan String Test")); - console2.log(StdStyle.cyan(uint256(10e18))); - console2.log(StdStyle.cyan(int256(-10e18))); - console2.log(StdStyle.cyan(true)); - console2.log(StdStyle.cyan(address(0))); - console2.log(StdStyle.cyanBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.cyanBytes32("StdStyle.cyanBytes32")); - } - - function test_StyleFontWeight() public pure { - console2.log(StdStyle.bold("StdStyle.bold String Test")); - console2.log(StdStyle.bold(uint256(10e18))); - console2.log(StdStyle.bold(int256(-10e18))); - console2.log(StdStyle.bold(address(0))); - console2.log(StdStyle.bold(true)); - console2.log(StdStyle.boldBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.boldBytes32("StdStyle.boldBytes32")); - console2.log(StdStyle.dim("StdStyle.dim String Test")); - console2.log(StdStyle.dim(uint256(10e18))); - console2.log(StdStyle.dim(int256(-10e18))); - console2.log(StdStyle.dim(address(0))); - console2.log(StdStyle.dim(true)); - console2.log(StdStyle.dimBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.dimBytes32("StdStyle.dimBytes32")); - console2.log(StdStyle.italic("StdStyle.italic String Test")); - console2.log(StdStyle.italic(uint256(10e18))); - console2.log(StdStyle.italic(int256(-10e18))); - console2.log(StdStyle.italic(address(0))); - console2.log(StdStyle.italic(true)); - console2.log(StdStyle.italicBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.italicBytes32("StdStyle.italicBytes32")); - console2.log(StdStyle.underline("StdStyle.underline String Test")); - console2.log(StdStyle.underline(uint256(10e18))); - console2.log(StdStyle.underline(int256(-10e18))); - console2.log(StdStyle.underline(address(0))); - console2.log(StdStyle.underline(true)); - console2.log(StdStyle.underlineBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.underlineBytes32("StdStyle.underlineBytes32")); - console2.log(StdStyle.inverse("StdStyle.inverse String Test")); - console2.log(StdStyle.inverse(uint256(10e18))); - console2.log(StdStyle.inverse(int256(-10e18))); - console2.log(StdStyle.inverse(address(0))); - console2.log(StdStyle.inverse(true)); - console2.log(StdStyle.inverseBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.inverseBytes32("StdStyle.inverseBytes32")); - } - - function test_StyleCombined() public pure { - console2.log(StdStyle.red(StdStyle.bold("Red Bold String Test"))); - console2.log(StdStyle.green(StdStyle.dim(uint256(10e18)))); - console2.log(StdStyle.yellow(StdStyle.italic(int256(-10e18)))); - console2.log(StdStyle.blue(StdStyle.underline(address(0)))); - console2.log(StdStyle.magenta(StdStyle.inverse(true))); - } - - function test_StyleCustom() public pure { - console2.log(h1("Custom Style 1")); - console2.log(h2("Custom Style 2")); - } - - function h1(string memory a) private pure returns (string memory) { - return StdStyle.cyan(StdStyle.inverse(StdStyle.bold(a))); - } - - function h2(string memory a) private pure returns (string memory) { - return StdStyle.magenta(StdStyle.bold(StdStyle.underline(a))); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdToml.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdToml.t.sol deleted file mode 100644 index 306dda99fc..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdToml.t.sol +++ /dev/null @@ -1,49 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {Test, stdToml} from "../src/Test.sol"; - -contract StdTomlTest is Test { - using stdToml for string; - - string root; - string path; - - function setUp() public { - root = vm.projectRoot(); - path = string.concat(root, "/test/fixtures/test.toml"); - } - - struct SimpleToml { - uint256 a; - string b; - } - - struct NestedToml { - uint256 a; - string b; - SimpleToml c; - } - - function test_readToml() public view { - string memory json = vm.readFile(path); - assertEq(json.readUint(".a"), 123); - } - - function test_writeToml() public { - string memory json = "json"; - json.serialize("a", uint256(123)); - string memory semiFinal = json.serialize("b", string("test")); - string memory finalJson = json.serialize("c", semiFinal); - finalJson.write(path); - - string memory toml = vm.readFile(path); - bytes memory data = toml.parseRaw("$"); - NestedToml memory decodedData = abi.decode(data, (NestedToml)); - - assertEq(decodedData.a, 123); - assertEq(decodedData.b, "test"); - assertEq(decodedData.c.a, 123); - assertEq(decodedData.c.b, "test"); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdUtils.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdUtils.t.sol deleted file mode 100644 index c0a3d3acf0..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/StdUtils.t.sol +++ /dev/null @@ -1,342 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {Test, StdUtils} from "../src/Test.sol"; - -contract StdUtilsMock is StdUtils { - // We deploy a mock version so we can properly test expected reverts. - function exposedGetTokenBalances(address token, address[] memory addresses) - external - returns (uint256[] memory balances) - { - return getTokenBalances(token, addresses); - } - - function exposedBound(int256 num, int256 min, int256 max) external pure returns (int256) { - return bound(num, min, max); - } - - function exposedBound(uint256 num, uint256 min, uint256 max) external pure returns (uint256) { - return bound(num, min, max); - } - - function exposedBytesToUint(bytes memory b) external pure returns (uint256) { - return bytesToUint(b); - } -} - -contract StdUtilsTest is Test { - /*////////////////////////////////////////////////////////////////////////// - BOUND UINT - //////////////////////////////////////////////////////////////////////////*/ - - function test_Bound() public pure { - assertEq(bound(uint256(5), 0, 4), 0); - assertEq(bound(uint256(0), 69, 69), 69); - assertEq(bound(uint256(0), 68, 69), 68); - assertEq(bound(uint256(10), 150, 190), 174); - assertEq(bound(uint256(300), 2800, 3200), 3107); - assertEq(bound(uint256(9999), 1337, 6666), 4669); - } - - function test_Bound_WithinRange() public pure { - assertEq(bound(uint256(51), 50, 150), 51); - assertEq(bound(uint256(51), 50, 150), bound(bound(uint256(51), 50, 150), 50, 150)); - assertEq(bound(uint256(149), 50, 150), 149); - assertEq(bound(uint256(149), 50, 150), bound(bound(uint256(149), 50, 150), 50, 150)); - } - - function test_Bound_EdgeCoverage() public pure { - assertEq(bound(uint256(0), 50, 150), 50); - assertEq(bound(uint256(1), 50, 150), 51); - assertEq(bound(uint256(2), 50, 150), 52); - assertEq(bound(uint256(3), 50, 150), 53); - assertEq(bound(type(uint256).max, 50, 150), 150); - assertEq(bound(type(uint256).max - 1, 50, 150), 149); - assertEq(bound(type(uint256).max - 2, 50, 150), 148); - assertEq(bound(type(uint256).max - 3, 50, 150), 147); - } - - function testFuzz_Bound_DistributionIsEven(uint256 min, uint256 size) public pure { - size = size % 100 + 1; - min = bound(min, UINT256_MAX / 2, UINT256_MAX / 2 + size); - uint256 max = min + size - 1; - uint256 result; - - for (uint256 i = 1; i <= size * 4; ++i) { - // x > max - result = bound(max + i, min, max); - assertEq(result, min + (i - 1) % size); - // x < min - result = bound(min - i, min, max); - assertEq(result, max - (i - 1) % size); - } - } - - function testFuzz_Bound(uint256 num, uint256 min, uint256 max) public pure { - if (min > max) (min, max) = (max, min); - - uint256 result = bound(num, min, max); - - assertGe(result, min); - assertLe(result, max); - assertEq(result, bound(result, min, max)); - if (num >= min && num <= max) assertEq(result, num); - } - - function test_BoundUint256Max() public pure { - assertEq(bound(0, type(uint256).max - 1, type(uint256).max), type(uint256).max - 1); - assertEq(bound(1, type(uint256).max - 1, type(uint256).max), type(uint256).max); - } - - function test_RevertIf_BoundMaxLessThanMin() public { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - vm.expectRevert(bytes("StdUtils bound(uint256,uint256,uint256): Max is less than min.")); - stdUtils.exposedBound(uint256(5), 100, 10); - } - - function testFuzz_RevertIf_BoundMaxLessThanMin(uint256 num, uint256 min, uint256 max) public { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - vm.assume(min > max); - vm.expectRevert(bytes("StdUtils bound(uint256,uint256,uint256): Max is less than min.")); - stdUtils.exposedBound(num, min, max); - } - - /*////////////////////////////////////////////////////////////////////////// - BOUND INT - //////////////////////////////////////////////////////////////////////////*/ - - function test_BoundInt() public pure { - assertEq(bound(-3, 0, 4), 2); - assertEq(bound(0, -69, -69), -69); - assertEq(bound(0, -69, -68), -68); - assertEq(bound(-10, 150, 190), 154); - assertEq(bound(-300, 2800, 3200), 2908); - assertEq(bound(9999, -1337, 6666), 1995); - } - - function test_BoundInt_WithinRange() public pure { - assertEq(bound(51, -50, 150), 51); - assertEq(bound(51, -50, 150), bound(bound(51, -50, 150), -50, 150)); - assertEq(bound(149, -50, 150), 149); - assertEq(bound(149, -50, 150), bound(bound(149, -50, 150), -50, 150)); - } - - function test_BoundInt_EdgeCoverage() public pure { - assertEq(bound(type(int256).min, -50, 150), -50); - assertEq(bound(type(int256).min + 1, -50, 150), -49); - assertEq(bound(type(int256).min + 2, -50, 150), -48); - assertEq(bound(type(int256).min + 3, -50, 150), -47); - assertEq(bound(type(int256).min, 10, 150), 10); - assertEq(bound(type(int256).min + 1, 10, 150), 11); - assertEq(bound(type(int256).min + 2, 10, 150), 12); - assertEq(bound(type(int256).min + 3, 10, 150), 13); - - assertEq(bound(type(int256).max, -50, 150), 150); - assertEq(bound(type(int256).max - 1, -50, 150), 149); - assertEq(bound(type(int256).max - 2, -50, 150), 148); - assertEq(bound(type(int256).max - 3, -50, 150), 147); - assertEq(bound(type(int256).max, -50, -10), -10); - assertEq(bound(type(int256).max - 1, -50, -10), -11); - assertEq(bound(type(int256).max - 2, -50, -10), -12); - assertEq(bound(type(int256).max - 3, -50, -10), -13); - } - - function testFuzz_BoundInt_DistributionIsEven(int256 min, uint256 size) public pure { - size = size % 100 + 1; - min = bound(min, -int256(size / 2), int256(size - size / 2)); - int256 max = min + int256(size) - 1; - int256 result; - - for (uint256 i = 1; i <= size * 4; ++i) { - // x > max - result = bound(max + int256(i), min, max); - assertEq(result, min + int256((i - 1) % size)); - // x < min - result = bound(min - int256(i), min, max); - assertEq(result, max - int256((i - 1) % size)); - } - } - - function testFuzz_BoundInt(int256 num, int256 min, int256 max) public pure { - if (min > max) (min, max) = (max, min); - - int256 result = bound(num, min, max); - - assertGe(result, min); - assertLe(result, max); - assertEq(result, bound(result, min, max)); - if (num >= min && num <= max) assertEq(result, num); - } - - function test_BoundIntInt256Max() public pure { - assertEq(bound(0, type(int256).max - 1, type(int256).max), type(int256).max - 1); - assertEq(bound(1, type(int256).max - 1, type(int256).max), type(int256).max); - } - - function test_BoundIntInt256Min() public pure { - assertEq(bound(0, type(int256).min, type(int256).min + 1), type(int256).min); - assertEq(bound(1, type(int256).min, type(int256).min + 1), type(int256).min + 1); - } - - function test_RevertIf_BoundIntMaxLessThanMin() public { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - vm.expectRevert(bytes("StdUtils bound(int256,int256,int256): Max is less than min.")); - stdUtils.exposedBound(-5, 100, 10); - } - - function testFuzz_RevertIf_BoundIntMaxLessThanMin(int256 num, int256 min, int256 max) public { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - vm.assume(min > max); - vm.expectRevert(bytes("StdUtils bound(int256,int256,int256): Max is less than min.")); - stdUtils.exposedBound(num, min, max); - } - - /*////////////////////////////////////////////////////////////////////////// - BOUND PRIVATE KEY - //////////////////////////////////////////////////////////////////////////*/ - - function test_BoundPrivateKey() public pure { - assertEq(boundPrivateKey(0), 1); - assertEq(boundPrivateKey(1), 1); - assertEq(boundPrivateKey(300), 300); - assertEq(boundPrivateKey(9999), 9999); - assertEq(boundPrivateKey(SECP256K1_ORDER - 1), SECP256K1_ORDER - 1); - assertEq(boundPrivateKey(SECP256K1_ORDER), 1); - assertEq(boundPrivateKey(SECP256K1_ORDER + 1), 2); - assertEq(boundPrivateKey(UINT256_MAX), UINT256_MAX & SECP256K1_ORDER - 1); // x&y is equivalent to x-x%y - } - - /*////////////////////////////////////////////////////////////////////////// - BYTES TO UINT - //////////////////////////////////////////////////////////////////////////*/ - - function test_BytesToUint() external pure { - bytes memory maxUint = hex"ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"; - bytes memory two = hex"02"; - bytes memory millionEther = hex"d3c21bcecceda1000000"; - - assertEq(bytesToUint(maxUint), type(uint256).max); - assertEq(bytesToUint(two), 2); - assertEq(bytesToUint(millionEther), 1_000_000 ether); - } - - function test_RevertIf_BytesLengthExceeds32() external { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - bytes memory thirty3Bytes = hex"ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"; - vm.expectRevert("StdUtils bytesToUint(bytes): Bytes length exceeds 32."); - stdUtils.exposedBytesToUint(thirty3Bytes); - } - - /*////////////////////////////////////////////////////////////////////////// - COMPUTE CREATE ADDRESS - //////////////////////////////////////////////////////////////////////////*/ - - function test_ComputeCreateAddress() external pure { - address deployer = 0x6C9FC64A53c1b71FB3f9Af64d1ae3A4931A5f4E9; - uint256 nonce = 14; - address createAddress = computeCreateAddress(deployer, nonce); - assertEq(createAddress, 0x68b3465833fb72A70ecDF485E0e4C7bD8665Fc45); - } - - /*////////////////////////////////////////////////////////////////////////// - COMPUTE CREATE2 ADDRESS - //////////////////////////////////////////////////////////////////////////*/ - - function test_ComputeCreate2Address() external pure { - bytes32 salt = bytes32(uint256(31415)); - bytes32 initcodeHash = keccak256(abi.encode(0x6080)); - address deployer = 0x6C9FC64A53c1b71FB3f9Af64d1ae3A4931A5f4E9; - address create2Address = computeCreate2Address(salt, initcodeHash, deployer); - assertEq(create2Address, 0xB147a5d25748fda14b463EB04B111027C290f4d3); - } - - function test_ComputeCreate2AddressWithDefaultDeployer() external pure { - bytes32 salt = 0xc290c670fde54e5ef686f9132cbc8711e76a98f0333a438a92daa442c71403c0; - bytes32 initcodeHash = hashInitCode(hex"6080", ""); - assertEq(initcodeHash, 0x1a578b7a4b0b5755db6d121b4118d4bc68fe170dca840c59bc922f14175a76b0); - address create2Address = computeCreate2Address(salt, initcodeHash); - assertEq(create2Address, 0xc0ffEe2198a06235aAbFffe5Db0CacF1717f5Ac6); - } -} - -contract StdUtilsForkTest is Test { - /*////////////////////////////////////////////////////////////////////////// - GET TOKEN BALANCES - //////////////////////////////////////////////////////////////////////////*/ - - address internal SHIB = 0x95aD61b0a150d79219dCF64E1E6Cc01f0B64C4cE; - address internal SHIB_HOLDER_0 = 0x855F5981e831D83e6A4b4EBFCAdAa68D92333170; - address internal SHIB_HOLDER_1 = 0x8F509A90c2e47779cA408Fe00d7A72e359229AdA; - address internal SHIB_HOLDER_2 = 0x0e3bbc0D04fF62211F71f3e4C45d82ad76224385; - - address internal USDC = 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48; - address internal USDC_HOLDER_0 = 0xDa9CE944a37d218c3302F6B82a094844C6ECEb17; - address internal USDC_HOLDER_1 = 0x3e67F4721E6d1c41a015f645eFa37BEd854fcf52; - - function setUp() public { - // All tests of the `getTokenBalances` method are fork tests using live contracts. - vm.createSelectFork({urlOrAlias: "mainnet", blockNumber: 16_428_900}); - } - - function test_RevertIf_CannotGetTokenBalances_NonTokenContract() external { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - // The UniswapV2Factory contract has neither a `balanceOf` function nor a fallback function, - // so the `balanceOf` call should revert. - address token = address(0x5C69bEe701ef814a2B6a3EDD4B1652CB9cc5aA6f); - address[] memory addresses = new address[](1); - addresses[0] = USDC_HOLDER_0; - - vm.expectRevert("Multicall3: call failed"); - stdUtils.exposedGetTokenBalances(token, addresses); - } - - function test_RevertIf_CannotGetTokenBalances_EOA() external { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - address eoa = vm.addr({privateKey: 1}); - address[] memory addresses = new address[](1); - addresses[0] = USDC_HOLDER_0; - vm.expectRevert("StdUtils getTokenBalances(address,address[]): Token address is not a contract."); - stdUtils.exposedGetTokenBalances(eoa, addresses); - } - - function test_GetTokenBalances_Empty() external { - address[] memory addresses = new address[](0); - uint256[] memory balances = getTokenBalances(USDC, addresses); - assertEq(balances.length, 0); - } - - function test_GetTokenBalances_USDC() external { - address[] memory addresses = new address[](2); - addresses[0] = USDC_HOLDER_0; - addresses[1] = USDC_HOLDER_1; - uint256[] memory balances = getTokenBalances(USDC, addresses); - assertEq(balances[0], 159_000_000_000_000); - assertEq(balances[1], 131_350_000_000_000); - } - - function test_GetTokenBalances_SHIB() external { - address[] memory addresses = new address[](3); - addresses[0] = SHIB_HOLDER_0; - addresses[1] = SHIB_HOLDER_1; - addresses[2] = SHIB_HOLDER_2; - uint256[] memory balances = getTokenBalances(SHIB, addresses); - assertEq(balances[0], 3_323_256_285_484.42e18); - assertEq(balances[1], 1_271_702_771_149.99999928e18); - assertEq(balances[2], 606_357_106_247e18); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/Vm.t.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/Vm.t.sol deleted file mode 100644 index 8ce466c7e4..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/Vm.t.sol +++ /dev/null @@ -1,18 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {Test} from "../src/Test.sol"; -import {Vm, VmSafe} from "../src/Vm.sol"; - -// These tests ensure that functions are never accidentally removed from a Vm interface, or -// inadvertently moved between Vm and VmSafe. These tests must be updated each time a function is -// added to or removed from Vm or VmSafe. -contract VmTest is Test { - function test_VmInterfaceId() public pure { - assertEq(type(Vm).interfaceId, bytes4(0xe835828d), "Vm"); - } - - function test_VmSafeInterfaceId() public pure { - assertEq(type(VmSafe).interfaceId, bytes4(0x7f58f7be), "VmSafe"); - } -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/compilation/CompilationScript.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/compilation/CompilationScript.sol deleted file mode 100644 index 6efbfa6581..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/compilation/CompilationScript.sol +++ /dev/null @@ -1,8 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {Script} from "../../src/Script.sol"; - -// The purpose of this contract is to benchmark compilation time to avoid accidentally introducing -// a change that results in very long compilation times with via-ir. See https://github.com/foundry-rs/forge-std/issues/207 -contract CompilationScript is Script {} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/compilation/CompilationScriptBase.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/compilation/CompilationScriptBase.sol deleted file mode 100644 index 75329739d3..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/compilation/CompilationScriptBase.sol +++ /dev/null @@ -1,8 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {ScriptBase} from "../../src/Script.sol"; - -// The purpose of this contract is to benchmark compilation time to avoid accidentally introducing -// a change that results in very long compilation times with via-ir. See https://github.com/foundry-rs/forge-std/issues/207 -contract CompilationScriptBase is ScriptBase {} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/compilation/CompilationTest.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/compilation/CompilationTest.sol deleted file mode 100644 index 5ba888e8c1..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/compilation/CompilationTest.sol +++ /dev/null @@ -1,8 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {Test} from "../../src/Test.sol"; - -// The purpose of this contract is to benchmark compilation time to avoid accidentally introducing -// a change that results in very long compilation times with via-ir. See https://github.com/foundry-rs/forge-std/issues/207 -contract CompilationTest is Test {} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/compilation/CompilationTestBase.sol b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/compilation/CompilationTestBase.sol deleted file mode 100644 index 9c081f7897..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/compilation/CompilationTestBase.sol +++ /dev/null @@ -1,8 +0,0 @@ -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.8.13 <0.9.0; - -import {TestBase} from "../../src/Test.sol"; - -// The purpose of this contract is to benchmark compilation time to avoid accidentally introducing -// a change that results in very long compilation times with via-ir. See https://github.com/foundry-rs/forge-std/issues/207 -contract CompilationTestBase is TestBase {} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/fixtures/broadcast.log.json b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/fixtures/broadcast.log.json deleted file mode 100644 index 0a0200bca9..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/fixtures/broadcast.log.json +++ /dev/null @@ -1,187 +0,0 @@ -{ - "transactions": [ - { - "hash": "0xc6006863c267735a11476b7f15b15bc718e117e2da114a2be815dd651e1a509f", - "type": "CALL", - "contractName": "Test", - "contractAddress": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "function": "multiple_arguments(uint256,address,uint256[]):(uint256)", - "arguments": ["1", "0000000000000000000000000000000000001337", "[3,4]"], - "tx": { - "type": "0x02", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "gas": "0x73b9", - "value": "0x0", - "data": "0x23e99187000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000013370000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000000004", - "nonce": "0x3", - "accessList": [] - } - }, - { - "hash": "0xedf2b38d8d896519a947a1acf720f859bb35c0c5ecb8dd7511995b67b9853298", - "type": "CALL", - "contractName": "Test", - "contractAddress": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "function": "inc():(uint256)", - "arguments": [], - "tx": { - "type": "0x02", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "gas": "0xdcb2", - "value": "0x0", - "data": "0x371303c0", - "nonce": "0x4", - "accessList": [] - } - }, - { - "hash": "0xa57e8e3981a6c861442e46c9471bd19cb3e21f9a8a6c63a72e7b5c47c6675a7c", - "type": "CALL", - "contractName": "Test", - "contractAddress": "0x7c6b4bbe207d642d98d5c537142d85209e585087", - "function": "t(uint256):(uint256)", - "arguments": ["1"], - "tx": { - "type": "0x02", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0x7c6b4bbe207d642d98d5c537142d85209e585087", - "gas": "0x8599", - "value": "0x0", - "data": "0xafe29f710000000000000000000000000000000000000000000000000000000000000001", - "nonce": "0x5", - "accessList": [] - } - } - ], - "receipts": [ - { - "transactionHash": "0x481dc86e40bba90403c76f8e144aa9ff04c1da2164299d0298573835f0991181", - "transactionIndex": "0x0", - "blockHash": "0xef0730448490304e5403be0fa8f8ce64f118e9adcca60c07a2ae1ab921d748af", - "blockNumber": "0x1", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": null, - "cumulativeGasUsed": "0x13f3a", - "gasUsed": "0x13f3a", - "contractAddress": "0x5fbdb2315678afecb367f032d93f642f64180aa3", - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0x6a187183545b8a9e7f1790e847139379bf5622baff2cb43acf3f5c79470af782", - "transactionIndex": "0x0", - "blockHash": "0xf3acb96a90071640c2a8c067ae4e16aad87e634ea8d8bbbb5b352fba86ba0148", - "blockNumber": "0x2", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": null, - "cumulativeGasUsed": "0x45d80", - "gasUsed": "0x45d80", - "contractAddress": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0x064ad173b4867bdef2fb60060bbdaf01735fbf10414541ea857772974e74ea9d", - "transactionIndex": "0x0", - "blockHash": "0x8373d02109d3ee06a0225f23da4c161c656ccc48fe0fcee931d325508ae73e58", - "blockNumber": "0x3", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0x4e59b44847b379578588920ca78fbf26c0b4956c", - "cumulativeGasUsed": "0x45feb", - "gasUsed": "0x45feb", - "contractAddress": null, - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0xc6006863c267735a11476b7f15b15bc718e117e2da114a2be815dd651e1a509f", - "transactionIndex": "0x0", - "blockHash": "0x16712fae5c0e18f75045f84363fb6b4d9a9fe25e660c4ce286833a533c97f629", - "blockNumber": "0x4", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "cumulativeGasUsed": "0x5905", - "gasUsed": "0x5905", - "contractAddress": null, - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0xedf2b38d8d896519a947a1acf720f859bb35c0c5ecb8dd7511995b67b9853298", - "transactionIndex": "0x0", - "blockHash": "0x156b88c3eb9a1244ba00a1834f3f70de735b39e3e59006dd03af4fe7d5480c11", - "blockNumber": "0x5", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "cumulativeGasUsed": "0xa9c4", - "gasUsed": "0xa9c4", - "contractAddress": null, - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0xa57e8e3981a6c861442e46c9471bd19cb3e21f9a8a6c63a72e7b5c47c6675a7c", - "transactionIndex": "0x0", - "blockHash": "0xcf61faca67dbb2c28952b0b8a379e53b1505ae0821e84779679390cb8571cadb", - "blockNumber": "0x6", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0x7c6b4bbe207d642d98d5c537142d85209e585087", - "cumulativeGasUsed": "0x66c5", - "gasUsed": "0x66c5", - "contractAddress": null, - "logs": [ - { - "address": "0x7c6b4bbe207d642d98d5c537142d85209e585087", - "topics": [ - "0x0b2e13ff20ac7b474198655583edf70dedd2c1dc980e329c4fbb2fc0748b796b" - ], - "data": "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000046865726500000000000000000000000000000000000000000000000000000000", - "blockHash": "0xcf61faca67dbb2c28952b0b8a379e53b1505ae0821e84779679390cb8571cadb", - "blockNumber": "0x6", - "transactionHash": "0xa57e8e3981a6c861442e46c9471bd19cb3e21f9a8a6c63a72e7b5c47c6675a7c", - "transactionIndex": "0x1", - "logIndex": "0x0", - "transactionLogIndex": "0x0", - "removed": false - } - ], - "status": "0x1", - "logsBloom": "0x00000000000800000000000000000010000000000000000000000000000180000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0x11fbb10230c168ca1e36a7e5c69a6dbcd04fd9e64ede39d10a83e36ee8065c16", - "transactionIndex": "0x0", - "blockHash": "0xf1e0ed2eda4e923626ec74621006ed50b3fc27580dc7b4cf68a07ca77420e29c", - "blockNumber": "0x7", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0x0000000000000000000000000000000000001337", - "cumulativeGasUsed": "0x5208", - "gasUsed": "0x5208", - "contractAddress": null, - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - } - ], - "libraries": [ - "src/Broadcast.t.sol:F:0x5fbdb2315678afecb367f032d93f642f64180aa3" - ], - "pending": [], - "path": "broadcast/Broadcast.t.sol/31337/run-latest.json", - "returns": {}, - "timestamp": 1655140035 -} diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/fixtures/config.toml b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/fixtures/config.toml deleted file mode 100644 index e6dcccca58..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/fixtures/config.toml +++ /dev/null @@ -1,81 +0,0 @@ -# ------------------------------------------------ -# EXAMPLE DEPLOYMENT CONFIG -# ------------------------------------------------ - -# -- MAINNET ------------------------------------- - -[mainnet] -endpoint_url = "${MAINNET_RPC}" - -[mainnet.bool] -is_live = true -bool_array = [true, false] - -[mainnet.address] -weth = "${WETH_MAINNET}" -deps = [ - "0x0000000000000000000000000000000000000000", - "0x1111111111111111111111111111111111111111", -] - -[mainnet.uint] -number = 1234 -number_array = [5678, 9999] - -[mainnet.int] -signed_number = -1234 -signed_number_array = [-5678, 9999] - -[mainnet.bytes32] -word = "0x00000000000000000000000000000000000000000000000000000000000004d2" # 1234 -word_array = [ - "0x000000000000000000000000000000000000000000000000000000000000162e", # 5678 - "0x000000000000000000000000000000000000000000000000000000000000270f", # 9999 -] - -[mainnet.bytes] -b = "0xabcd" -b_array = ["0xdead", "0xbeef"] - -[mainnet.string] -str = "foo" -str_array = ["bar", "baz"] - -# -- OPTIMISM ------------------------------------ - -[optimism] -endpoint_url = "${OPTIMISM_RPC}" - -[optimism.bool] -is_live = false -bool_array = [false, true] - -[optimism.address] -weth = "${WETH_OPTIMISM}" -deps = [ - "0x2222222222222222222222222222222222222222", - "0x3333333333333333333333333333333333333333", -] - -[optimism.uint] -number = 9999 -number_array = [1234, 5678] - -[optimism.int] -signed_number = 9999 -signed_number_array = [-1234, -5678] - -[optimism.bytes32] -word = "0x000000000000000000000000000000000000000000000000000000000000270f" # 9999 -word_array = [ - "0x00000000000000000000000000000000000000000000000000000000000004d2", # 1234 - "0x000000000000000000000000000000000000000000000000000000000000162e", # 5678 -] - -[optimism.bytes] -b = "0xdcba" -b_array = ["0xc0ffee", "0xbabe"] - -[optimism.string] -str = "alice" -str_array = ["bob", "charlie"] diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/fixtures/test.json b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/fixtures/test.json deleted file mode 100644 index caebf6d965..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/fixtures/test.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "a": 123, - "b": "test", - "c": { - "a": 123, - "b": "test" - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/fixtures/test.toml b/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/fixtures/test.toml deleted file mode 100644 index 60692bc750..0000000000 --- a/lib/signals-implicit-mode/dependencies/forge-std-1.14.0/test/fixtures/test.toml +++ /dev/null @@ -1,6 +0,0 @@ -a = 123 -b = "test" - -[c] -a = 123 -b = "test" diff --git a/lib/signals-implicit-mode/foundry.lock b/lib/signals-implicit-mode/foundry.lock deleted file mode 100644 index 9e26dfeeb6..0000000000 --- a/lib/signals-implicit-mode/foundry.lock +++ /dev/null @@ -1 +0,0 @@ -{} \ No newline at end of file diff --git a/lib/signals-implicit-mode/foundry.toml b/lib/signals-implicit-mode/foundry.toml deleted file mode 100644 index 964d26db30..0000000000 --- a/lib/signals-implicit-mode/foundry.toml +++ /dev/null @@ -1,25 +0,0 @@ -[profile.default] -src = "src" -out = "out" -libs = ["lib", "dependencies"] -via-ir = false -solc = "0.8.28" -evm_version = "paris" - -[fmt] -# Explicitly define all formatting rules -multiline_func_header = "params_first" -single_line_statement_blocks = "multi" -sort_imports = true -contract_new_lines = true -override_spacing = false -line_length = 120 -tab_width = 2 -bracket_spacing = true -int_types = "long" -quote_style = "double" -hex_underscore = "remove" -wrap_comments = false - -[dependencies] -forge-std = "1.14.0" diff --git a/lib/signals-implicit-mode/lib/forge-std/.gitattributes b/lib/signals-implicit-mode/lib/forge-std/.gitattributes deleted file mode 100644 index 27042d458c..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/.gitattributes +++ /dev/null @@ -1 +0,0 @@ -src/Vm.sol linguist-generated diff --git a/lib/signals-implicit-mode/lib/forge-std/.github/CODEOWNERS b/lib/signals-implicit-mode/lib/forge-std/.github/CODEOWNERS deleted file mode 100644 index 63b25bbbcb..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/.github/CODEOWNERS +++ /dev/null @@ -1 +0,0 @@ -* @danipopes @klkvr @mattsse @grandizzy @yash-atreya @zerosnacks diff --git a/lib/signals-implicit-mode/lib/forge-std/.github/workflows/ci.yml b/lib/signals-implicit-mode/lib/forge-std/.github/workflows/ci.yml deleted file mode 100644 index 8a4281ed08..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/.github/workflows/ci.yml +++ /dev/null @@ -1,95 +0,0 @@ -name: CI - -on: - workflow_dispatch: - pull_request: - push: - branches: - - master - -jobs: - build: - name: build +${{ matrix.toolchain }} ${{ matrix.flags }} - runs-on: ubuntu-latest - timeout-minutes: 10 - strategy: - fail-fast: false - matrix: - toolchain: [stable, nightly] - flags: - - "" - - --via-ir - - --use solc:0.8.17 --via-ir - - --use solc:0.8.17 - - --use solc:0.8.0 - - --use solc:0.7.6 - - --use solc:0.7.0 - - --use solc:0.6.2 - - --use solc:0.6.12 - steps: - - uses: actions/checkout@v4 - - uses: foundry-rs/foundry-toolchain@v1 - - run: forge --version - - run: | - case "${{ matrix.flags }}" in - *"solc:0.8.0"* | *"solc:0.7"* | *"solc:0.6"*) - forge build --skip test --skip Config --skip StdConfig --skip LibVariable --deny-warnings ${{ matrix.flags }} - ;; - *) - forge build --skip test --deny-warnings ${{ matrix.flags }} - ;; - esac - # via-ir compilation time checks. - - if: contains(matrix.flags, '--via-ir') - run: forge build --skip test --deny-warnings ${{ matrix.flags }} --contracts 'test/compilation/*' - - test: - runs-on: ubuntu-latest - timeout-minutes: 10 - strategy: - fail-fast: false - matrix: - toolchain: [stable, nightly] - steps: - - uses: actions/checkout@v4 - - uses: foundry-rs/foundry-toolchain@v1 - with: - version: ${{ matrix.toolchain }} - - run: forge --version - - run: | - if [ "${{ matrix.toolchain }}" = "stable" ]; then - forge test -vvv --no-match-path "test/Config.t.sol" - else - forge test -vvv - fi - - fmt: - runs-on: ubuntu-latest - timeout-minutes: 10 - steps: - - uses: actions/checkout@v4 - - uses: foundry-rs/foundry-toolchain@v1 - - run: forge --version - - run: forge fmt --check - - typos: - runs-on: ubuntu-latest - timeout-minutes: 10 - steps: - - uses: actions/checkout@v4 - - uses: crate-ci/typos@v1 - - ci-success: - runs-on: ubuntu-latest - if: always() - needs: - - build - - test - - fmt - - typos - timeout-minutes: 10 - steps: - - name: Decide whether the needed jobs succeeded or failed - uses: re-actors/alls-green@release/v1 - with: - jobs: ${{ toJSON(needs) }} diff --git a/lib/signals-implicit-mode/lib/forge-std/.github/workflows/sync.yml b/lib/signals-implicit-mode/lib/forge-std/.github/workflows/sync.yml deleted file mode 100644 index 9b170f0b74..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/.github/workflows/sync.yml +++ /dev/null @@ -1,31 +0,0 @@ -name: Sync Release Branch - -on: - release: - types: - - created - -jobs: - sync-release-branch: - runs-on: ubuntu-latest - if: startsWith(github.event.release.tag_name, 'v1') - steps: - - name: Check out the repo - uses: actions/checkout@v4 - with: - fetch-depth: 0 - ref: v1 - - # The email is derived from the bots user id, - # found here: https://api.github.com/users/github-actions%5Bbot%5D - - name: Configure Git - run: | - git config user.name github-actions[bot] - git config user.email 41898282+github-actions[bot]@users.noreply.github.com - - - name: Sync Release Branch - run: | - git fetch --tags - git checkout v1 - git reset --hard ${GITHUB_REF} - git push --force diff --git a/lib/signals-implicit-mode/lib/forge-std/CONTRIBUTING.md b/lib/signals-implicit-mode/lib/forge-std/CONTRIBUTING.md deleted file mode 100644 index 541e3d46f8..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/CONTRIBUTING.md +++ /dev/null @@ -1,193 +0,0 @@ -## Contributing to Foundry - -Thanks for your interest in improving Foundry! - -There are multiple opportunities to contribute at any level. It doesn't matter if you are just getting started with Rust or are the most weathered expert, we can use your help. - -This document will help you get started. **Do not let the document intimidate you**. -It should be considered as a guide to help you navigate the process. - -The [dev Telegram][dev-tg] is available for any concerns you may have that are not covered in this guide. - -### Code of Conduct - -The Foundry project adheres to the [Rust Code of Conduct][rust-coc]. This code of conduct describes the _minimum_ behavior expected from all contributors. - -Instances of violations of the Code of Conduct can be reported by contacting the team at [me@gakonst.com](mailto:me@gakonst.com). - -### Ways to contribute - -There are fundamentally four ways an individual can contribute: - -1. **By opening an issue:** For example, if you believe that you have uncovered a bug - in Foundry, creating a new issue in the issue tracker is the way to report it. -2. **By adding context:** Providing additional context to existing issues, - such as screenshots and code snippets, which help resolve issues. -3. **By resolving issues:** Typically this is done in the form of either - demonstrating that the issue reported is not a problem after all, or more often, - by opening a pull request that fixes the underlying problem, in a concrete and - reviewable manner. - -**Anybody can participate in any stage of contribution**. We urge you to participate in the discussion -around bugs and participate in reviewing PRs. - -### Contributions Related to Spelling and Grammar - -At this time, we will not be accepting contributions that only fix spelling or grammatical errors in documentation, code or -elsewhere. - -### Asking for help - -If you have reviewed existing documentation and still have questions, or you are having problems, you can get help in the following ways: - -- **Asking in the support Telegram:** The [Foundry Support Telegram][support-tg] is a fast and easy way to ask questions. -- **Opening a discussion:** This repository comes with a discussions board where you can also ask for help. Click the "Discussions" tab at the top. - -As Foundry is still in heavy development, the documentation can be a bit scattered. -The [Foundry Book][foundry-book] is our current best-effort attempt at keeping up-to-date information. - -### Submitting a bug report - -When filing a new bug report in the issue tracker, you will be presented with a basic form to fill out. - -If you believe that you have uncovered a bug, please fill out the form to the best of your ability. Do not worry if you cannot answer every detail; just fill in what you can. Contributors will ask follow-up questions if something is unclear. - -The most important pieces of information we need in a bug report are: - -- The Foundry version you are on (and that it is up to date) -- The platform you are on (Windows, macOS, an M1 Mac or Linux) -- Code snippets if this is happening in relation to testing or building code -- Concrete steps to reproduce the bug - -In order to rule out the possibility of the bug being in your project, the code snippets should be as minimal -as possible. It is better if you can reproduce the bug with a small snippet as opposed to an entire project! - -See [this guide][mcve] on how to create a minimal, complete, and verifiable example. - -### Submitting a feature request - -When adding a feature request in the issue tracker, you will be presented with a basic form to fill out. - -Please include as detailed of an explanation as possible of the feature you would like, adding additional context if necessary. - -If you have examples of other tools that have the feature you are requesting, please include them as well. - -### Resolving an issue - -Pull requests are the way concrete changes are made to the code, documentation, and dependencies of Foundry. - -Even minor pull requests, such as those fixing wording, are greatly appreciated. Before making a large change, it is usually -a good idea to first open an issue describing the change to solicit feedback and guidance. This will increase -the likelihood of the PR getting merged. - -Please make sure that the following commands pass if you have changed the code: - -```sh -forge fmt --check -forge test -vvv -``` - -To make sure your changes are compatible with all compiler version targets, run the following commands: - -```sh -forge build --skip test --use solc:0.6.2 -forge build --skip test --use solc:0.6.12 -forge build --skip test --use solc:0.7.0 -forge build --skip test --use solc:0.7.6 -forge build --skip test --use solc:0.8.0 -``` - -The CI will also ensure that the code is formatted correctly and that the tests are passing across all compiler version targets. - -#### Adding cheatcodes - -Please follow the guide outlined in the [cheatcodes](https://github.com/foundry-rs/foundry/blob/master/docs/dev/cheatcodes.md#adding-a-new-cheatcode) documentation of Foundry. - -When making modifications to the native cheatcodes or adding new ones, please make sure to run [`./scripts/vm.py`](./scripts/vm.py) to update the cheatcodes in the [`src/Vm.sol`](./src/Vm.sol) file. - -By default the script will automatically generate the cheatcodes from the [`cheatcodes.json`](https://raw.githubusercontent.com/foundry-rs/foundry/master/crates/cheatcodes/assets/cheatcodes.json) file but alternatively you can provide a path to a JSON file containing the Vm interface, as generated by Foundry, with the `--from` flag. - -```sh -./scripts/vm.py --from path/to/cheatcodes.json -``` - -It is possible that the resulting [`src/Vm.sol`](./src/Vm.sol) file will have some changes that are not directly related to your changes, this is not a problem. - -#### Commits - -It is a recommended best practice to keep your changes as logically grouped as possible within individual commits. There is no limit to the number of commits any single pull request may have, and many contributors find it easier to review changes that are split across multiple commits. - -That said, if you have a number of commits that are "checkpoints" and don't represent a single logical change, please squash those together. - -#### Opening the pull request - -From within GitHub, opening a new pull request will present you with a template that should be filled out. Please try your best at filling out the details, but feel free to skip parts if you're not sure what to put. - -#### Discuss and update - -You will probably get feedback or requests for changes to your pull request. -This is a big part of the submission process, so don't be discouraged! Some contributors may sign off on the pull request right away, others may have more detailed comments or feedback. -This is a necessary part of the process in order to evaluate whether the changes are correct and necessary. - -**Any community member can review a PR, so you might get conflicting feedback**. -Keep an eye out for comments from code owners to provide guidance on conflicting feedback. - -#### Reviewing pull requests - -**Any Foundry community member is welcome to review any pull request**. - -All contributors who choose to review and provide feedback on pull requests have a responsibility to both the project and individual making the contribution. Reviews and feedback must be helpful, insightful, and geared towards improving the contribution as opposed to simply blocking it. If there are reasons why you feel the PR should not be merged, explain what those are. Do not expect to be able to block a PR from advancing simply because you say "no" without giving an explanation. Be open to having your mind changed. Be open to working _with_ the contributor to make the pull request better. - -Reviews that are dismissive or disrespectful of the contributor or any other reviewers are strictly counter to the Code of Conduct. - -When reviewing a pull request, the primary goals are for the codebase to improve and for the person submitting the request to succeed. **Even if a pull request is not merged, the submitter should come away from the experience feeling like their effort was not unappreciated**. Every PR from a new contributor is an opportunity to grow the community. - -##### Review a bit at a time - -Do not overwhelm new contributors. - -It is tempting to micro-optimize and make everything about relative performance, perfect grammar, or exact style matches. Do not succumb to that temptation.. - -Focus first on the most significant aspects of the change: - -1. Does this change make sense for Foundry? -2. Does this change make Foundry better, even if only incrementally? -3. Are there clear bugs or larger scale issues that need attending? -4. Are the commit messages readable and correct? If it contains a breaking change, is it clear enough? - -Note that only **incremental** improvement is needed to land a PR. This means that the PR does not need to be perfect, only better than the status quo. Follow-up PRs may be opened to continue iterating. - -When changes are necessary, _request_ them, do not _demand_ them, and **do not assume that the submitter already knows how to add a test or run a benchmark**. - -Specific performance optimization techniques, coding styles and conventions change over time. The first impression you give to a new contributor never does. - -Nits (requests for small changes that are not essential) are fine, but try to avoid stalling the pull request. Most nits can typically be fixed by the Foundry maintainers merging the pull request, but they can also be an opportunity for the contributor to learn a bit more about the project. - -It is always good to clearly indicate nits when you comment, e.g.: `Nit: change foo() to bar(). But this is not blocking`. - -If your comments were addressed but were not folded after new commits, or if they proved to be mistaken, please, [hide them][hiding-a-comment] with the appropriate reason to keep the conversation flow concise and relevant. - -##### Be aware of the person behind the code - -Be aware that _how_ you communicate requests and reviews in your feedback can have a significant impact on the success of the pull request. Yes, we may merge a particular change that makes Foundry better, but the individual might just not want to have anything to do with Foundry ever again. The goal is not just having good code. - -##### Abandoned or stale pull requests - -If a pull request appears to be abandoned or stalled, it is polite to first check with the contributor to see if they intend to continue the work before checking if they would mind if you took it over (especially if it just has nits left). When doing so, it is courteous to give the original contributor credit for the work they started, either by preserving their name and e-mail address in the commit log, or by using the `Author: ` or `Co-authored-by: ` metadata tag in the commits. - -_Adapted from the [ethers-rs contributing guide](https://github.com/gakonst/ethers-rs/blob/master/CONTRIBUTING.md)_. - -### Releasing - -Releases are automatically done by the release workflow when a tag is pushed, however, these steps still need to be taken: - -1. Ensure that the versions in the relevant `Cargo.toml` files are up-to-date. -2. Update documentation links -3. Perform a final audit for breaking changes. - -[rust-coc]: https://github.com/rust-lang/rust/blob/master/CODE_OF_CONDUCT.md -[dev-tg]: https://t.me/foundry_rs -[foundry-book]: https://github.com/foundry-rs/foundry-book -[support-tg]: https://t.me/foundry_support -[mcve]: https://stackoverflow.com/help/mcve -[hiding-a-comment]: https://help.github.com/articles/managing-disruptive-comments/#hiding-a-comment diff --git a/lib/signals-implicit-mode/lib/forge-std/LICENSE-APACHE b/lib/signals-implicit-mode/lib/forge-std/LICENSE-APACHE deleted file mode 100644 index cf01a499fb..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/LICENSE-APACHE +++ /dev/null @@ -1,203 +0,0 @@ -Copyright Contributors to Forge Standard Library - - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - -TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - -1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - -2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - -3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - -4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - -5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - -6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - -7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - -8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - -9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - -END OF TERMS AND CONDITIONS - -APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - -Copyright [yyyy] [name of copyright owner] - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. diff --git a/lib/signals-implicit-mode/lib/forge-std/LICENSE-MIT b/lib/signals-implicit-mode/lib/forge-std/LICENSE-MIT deleted file mode 100644 index 28f98304ac..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/LICENSE-MIT +++ /dev/null @@ -1,25 +0,0 @@ -Copyright Contributors to Forge Standard Library - -Permission is hereby granted, free of charge, to any -person obtaining a copy of this software and associated -documentation files (the "Software"), to deal in the -Software without restriction, including without -limitation the rights to use, copy, modify, merge, -publish, distribute, sublicense, and/or sell copies of -the Software, and to permit persons to whom the Software -is furnished to do so, subject to the following -conditions: - -The above copyright notice and this permission notice -shall be included in all copies or substantial portions -of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF -ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED -TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A -PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT -SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR -IN CONNECTION WITH THE SOFTWARE O THE USE OR OTHER -DEALINGS IN THE SOFTWARE.R diff --git a/lib/signals-implicit-mode/lib/forge-std/README.md b/lib/signals-implicit-mode/lib/forge-std/README.md deleted file mode 100644 index 91b16f0154..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/README.md +++ /dev/null @@ -1,268 +0,0 @@ -# Forge Standard Library • [![CI status](https://github.com/foundry-rs/forge-std/actions/workflows/ci.yml/badge.svg)](https://github.com/foundry-rs/forge-std/actions/workflows/ci.yml) - -Forge Standard Library is a collection of helpful contracts and libraries for use with [Forge and Foundry](https://github.com/foundry-rs/foundry). It leverages Forge's cheatcodes to make writing tests easier and faster, while improving the UX of cheatcodes. - -**Learn how to use Forge-Std with the [📖 Foundry Book (Forge-Std Guide)](https://getfoundry.sh/reference/forge-std/overview/).** - -## Install - -```bash -forge install foundry-rs/forge-std -``` - -## Contracts - -### stdError - -This is a helper contract for errors and reverts. In Forge, this contract is particularly helpful for the `expectRevert` cheatcode, as it provides all compiler built-in errors. - -See the contract itself for all error codes. - -#### Example usage - -```solidity - -import "forge-std/Test.sol"; - -contract TestContract is Test { - ErrorsTest test; - - function setUp() public { - test = new ErrorsTest(); - } - - function testExpectArithmetic() public { - vm.expectRevert(stdError.arithmeticError); - test.arithmeticError(10); - } -} - -contract ErrorsTest { - function arithmeticError(uint256 a) public { - a = a - 100; - } -} -``` - -### stdStorage - -This is a rather large contract due to all of the overloading to make the UX decent. Primarily, it is a wrapper around the `record` and `accesses` cheatcodes. It can _always_ find and write the storage slot(s) associated with a particular variable without knowing the storage layout. The one _major_ caveat to this is while a slot can be found for packed storage variables, we can't write to that variable safely. If a user tries to write to a packed slot, the execution throws an error, unless it is uninitialized (`bytes32(0)`). - -This works by recording all `SLOAD`s and `SSTORE`s during a function call. If there is a single slot read or written to, it immediately returns the slot. Otherwise, behind the scenes, we iterate through and check each one (assuming the user passed in a `depth` parameter). If the variable is a struct, you can pass in a `depth` parameter which is basically the field depth. - -I.e.: - -```solidity -struct T { - // depth 0 - uint256 a; - // depth 1 - uint256 b; -} -``` - -#### Example usage - -```solidity -import "forge-std/Test.sol"; - -contract TestContract is Test { - using stdStorage for StdStorage; - - Storage test; - - function setUp() public { - test = new Storage(); - } - - function testFindExists() public { - // Lets say we want to find the slot for the public - // variable `exists`. We just pass in the function selector - // to the `find` command - uint256 slot = stdstore.target(address(test)).sig("exists()").find(); - assertEq(slot, 0); - } - - function testWriteExists() public { - // Lets say we want to write to the slot for the public - // variable `exists`. We just pass in the function selector - // to the `checked_write` command - stdstore.target(address(test)).sig("exists()").checked_write(100); - assertEq(test.exists(), 100); - } - - // It supports arbitrary storage layouts, like assembly based storage locations - function testFindHidden() public { - // `hidden` is a random hash of a bytes, iteration through slots would - // not find it. Our mechanism does - // Also, you can use the selector instead of a string - uint256 slot = stdstore.target(address(test)).sig(test.hidden.selector).find(); - assertEq(slot, uint256(keccak256("my.random.var"))); - } - - // If targeting a mapping, you have to pass in the keys necessary to perform the find - // i.e.: - function testFindMapping() public { - uint256 slot = stdstore - .target(address(test)) - .sig(test.map_addr.selector) - .with_key(address(this)) - .find(); - // in the `Storage` constructor, we wrote that this address' value was 1 in the map - // so when we load the slot, we expect it to be 1 - assertEq(uint(vm.load(address(test), bytes32(slot))), 1); - } - - // If the target is a struct, you can specify the field depth: - function testFindStruct() public { - // NOTE: see the depth parameter - 0 means 0th field, 1 means 1st field, etc. - uint256 slot_for_a_field = stdstore - .target(address(test)) - .sig(test.basicStruct.selector) - .depth(0) - .find(); - - uint256 slot_for_b_field = stdstore - .target(address(test)) - .sig(test.basicStruct.selector) - .depth(1) - .find(); - - assertEq(uint(vm.load(address(test), bytes32(slot_for_a_field))), 1); - assertEq(uint(vm.load(address(test), bytes32(slot_for_b_field))), 2); - } -} - -// A complex storage contract -contract Storage { - struct UnpackedStruct { - uint256 a; - uint256 b; - } - - constructor() { - map_addr[msg.sender] = 1; - } - - uint256 public exists = 1; - mapping(address => uint256) public map_addr; - // mapping(address => Packed) public map_packed; - mapping(address => UnpackedStruct) public map_struct; - mapping(address => mapping(address => uint256)) public deep_map; - mapping(address => mapping(address => UnpackedStruct)) public deep_map_struct; - UnpackedStruct public basicStruct = UnpackedStruct({ - a: 1, - b: 2 - }); - - function hidden() public view returns (bytes32 t) { - // an extremely hidden storage slot - bytes32 slot = keccak256("my.random.var"); - assembly { - t := sload(slot) - } - } -} -``` - -### stdCheats - -This is a wrapper over miscellaneous cheatcodes that need wrappers to be more dev friendly. Currently there are only functions related to `prank`. In general, users may expect ETH to be put into an address on `prank`, but this is not the case for safety reasons. Explicitly this `hoax` function should only be used for addresses that have expected balances as it will get overwritten. If an address already has ETH, you should just use `prank`. If you want to change that balance explicitly, just use `deal`. If you want to do both, `hoax` is also right for you. - -#### Example usage: - -```solidity - -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.0; - -import "forge-std/Test.sol"; - -// Inherit the stdCheats -contract StdCheatsTest is Test { - Bar test; - function setUp() public { - test = new Bar(); - } - - function testHoax() public { - // we call `hoax`, which gives the target address - // eth and then calls `prank` - hoax(address(1337)); - test.bar{value: 100}(address(1337)); - - // overloaded to allow you to specify how much eth to - // initialize the address with - hoax(address(1337), 1); - test.bar{value: 1}(address(1337)); - } - - function testStartHoax() public { - // we call `startHoax`, which gives the target address - // eth and then calls `startPrank` - // - // it is also overloaded so that you can specify an eth amount - startHoax(address(1337)); - test.bar{value: 100}(address(1337)); - test.bar{value: 100}(address(1337)); - vm.stopPrank(); - test.bar(address(this)); - } -} - -contract Bar { - function bar(address expectedSender) public payable { - require(msg.sender == expectedSender, "!prank"); - } -} -``` - -### Std Assertions - -Contains various assertions. - -### `console.log` - -Usage follows the same format as [Hardhat](https://hardhat.org/hardhat-network/reference/#console-log). -It's recommended to use `console2.sol` as shown below, as this will show the decoded logs in Forge traces. - -```solidity -// import it indirectly via Test.sol -import "forge-std/Test.sol"; -// or directly import it -import "forge-std/console2.sol"; -... -console2.log(someValue); -``` - -If you need compatibility with Hardhat, you must use the standard `console.sol` instead. -Due to a bug in `console.sol`, logs that use `uint256` or `int256` types will not be properly decoded in Forge traces. - -```solidity -// import it indirectly via Test.sol -import "forge-std/Test.sol"; -// or directly import it -import "forge-std/console.sol"; -... -console.log(someValue); -``` - -## Contributing - -See our [contributing guidelines](./CONTRIBUTING.md). - -## Getting Help - -First, see if the answer to your question can be found in [book](https://book.getfoundry.sh). - -If the answer is not there: - -- Join the [support Telegram](https://t.me/foundry_support) to get help, or -- Open a [discussion](https://github.com/foundry-rs/foundry/discussions/new/choose) with your question, or -- Open an issue with [the bug](https://github.com/foundry-rs/foundry/issues/new/choose) - -If you want to contribute, or follow along with contributor discussion, you can use our [main telegram](https://t.me/foundry_rs) to chat with us about the development of Foundry! - -## License - -Forge Standard Library is offered under either [MIT](LICENSE-MIT) or [Apache 2.0](LICENSE-APACHE) license. diff --git a/lib/signals-implicit-mode/lib/forge-std/RELEASE_CHECKLIST.md b/lib/signals-implicit-mode/lib/forge-std/RELEASE_CHECKLIST.md deleted file mode 100644 index 4611de4dce..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/RELEASE_CHECKLIST.md +++ /dev/null @@ -1,12 +0,0 @@ -# Release checklist - -This checklist is meant to be used as a guide for the `forge-std` release process. - -## Steps - -- [ ] Update the version number in `package.json` -- [ ] Open and merge a PR with the version bump -- [ ] Tag the merged commit with the version number: `git tag v` -- [ ] Push the tag to the repository: `git push --tags` -- [ ] Create a new GitHub release with the automatically generated changelog and with the name set to `v` -- [ ] Add `## Featured Changes` section to the top of the release notes diff --git a/lib/signals-implicit-mode/lib/forge-std/foundry.toml b/lib/signals-implicit-mode/lib/forge-std/foundry.toml deleted file mode 100644 index b68bd546cc..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/foundry.toml +++ /dev/null @@ -1,27 +0,0 @@ -[profile.default] -fs_permissions = [{ access = "read-write", path = "./" }] -optimizer = true -optimizer_runs = 200 - -# A list of solidity error codes to ignore. -# 3860 = init-code-size -ignored_error_codes = [3860] - -[rpc_endpoints] -# The RPC URLs are modified versions of the default for testing initialization. -mainnet = "https://eth.merkle.io" # Different API key. -optimism_sepolia = "https://sepolia.optimism.io/" # Adds a trailing slash. -arbitrum_one_sepolia = "https://sepolia-rollup.arbitrum.io/rpc/" # Adds a trailing slash. -needs_undefined_env_var = "${UNDEFINED_RPC_URL_PLACEHOLDER}" - -[fmt] -# These are all the `forge fmt` defaults. -line_length = 120 -tab_width = 4 -bracket_spacing = false -int_types = 'long' -multiline_func_header = 'attributes_first' -quote_style = 'double' -number_underscore = 'preserve' -single_line_statement_blocks = 'preserve' -ignore = ["src/console.sol", "src/console2.sol"] diff --git a/lib/signals-implicit-mode/lib/forge-std/package.json b/lib/signals-implicit-mode/lib/forge-std/package.json deleted file mode 100644 index 74e5e66799..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/package.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "name": "forge-std", - "version": "1.10.0", - "description": "Forge Standard Library is a collection of helpful contracts and libraries for use with Forge and Foundry.", - "homepage": "https://book.getfoundry.sh/forge/forge-std", - "bugs": "https://github.com/foundry-rs/forge-std/issues", - "license": "(Apache-2.0 OR MIT)", - "author": "Contributors to Forge Standard Library", - "files": [ - "src/**/*" - ], - "repository": { - "type": "git", - "url": "https://github.com/foundry-rs/forge-std.git" - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/scripts/vm.py b/lib/signals-implicit-mode/lib/forge-std/scripts/vm.py deleted file mode 100644 index 3cd047d36d..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/scripts/vm.py +++ /dev/null @@ -1,646 +0,0 @@ -#!/usr/bin/env python3 - -import argparse -import copy -import json -import re -import subprocess -from enum import Enum as PyEnum -from pathlib import Path -from typing import Callable -from urllib import request - -VoidFn = Callable[[], None] - -CHEATCODES_JSON_URL = "https://raw.githubusercontent.com/foundry-rs/foundry/master/crates/cheatcodes/assets/cheatcodes.json" -OUT_PATH = "src/Vm.sol" - -VM_SAFE_DOC = """\ -/// The `VmSafe` interface does not allow manipulation of the EVM state or other actions that may -/// result in Script simulations differing from on-chain execution. It is recommended to only use -/// these cheats in scripts. -""" - -VM_DOC = """\ -/// The `Vm` interface does allow manipulation of the EVM state. These are all intended to be used -/// in tests, but it is not recommended to use these cheats in scripts. -""" - - -def main(): - parser = argparse.ArgumentParser( - description="Generate Vm.sol based on the cheatcodes json created by Foundry") - parser.add_argument( - "--from", - metavar="PATH", - dest="path", - required=False, - help="path to a json file containing the Vm interface, as generated by Foundry") - args = parser.parse_args() - json_str = request.urlopen(CHEATCODES_JSON_URL).read().decode("utf-8") if args.path is None else Path(args.path).read_text() - contract = Cheatcodes.from_json(json_str) - - ccs = contract.cheatcodes - ccs = list(filter(lambda cc: cc.status not in ["experimental", "internal"], ccs)) - ccs.sort(key=lambda cc: cc.func.id) - - safe = list(filter(lambda cc: cc.safety == "safe", ccs)) - safe.sort(key=CmpCheatcode) - unsafe = list(filter(lambda cc: cc.safety == "unsafe", ccs)) - unsafe.sort(key=CmpCheatcode) - assert len(safe) + len(unsafe) == len(ccs) - - prefix_with_group_headers(safe) - prefix_with_group_headers(unsafe) - - out = "" - - out += "// Automatically @generated by scripts/vm.py. Do not modify manually.\n\n" - - pp = CheatcodesPrinter( - spdx_identifier="MIT OR Apache-2.0", - solidity_requirement=">=0.6.2 <0.9.0", - abicoder_pragma=True, - ) - pp.p_prelude() - pp.prelude = False - out += pp.finish() - - out += "\n\n" - out += VM_SAFE_DOC - vm_safe = Cheatcodes( - # TODO: Custom errors were introduced in 0.8.4 - errors=[], # contract.errors - events=contract.events, - enums=contract.enums, - structs=contract.structs, - cheatcodes=safe, - ) - pp.p_contract(vm_safe, "VmSafe") - out += pp.finish() - - out += "\n\n" - out += VM_DOC - vm_unsafe = Cheatcodes( - errors=[], - events=[], - enums=[], - structs=[], - cheatcodes=unsafe, - ) - pp.p_contract(vm_unsafe, "Vm", "VmSafe") - out += pp.finish() - - # Compatibility with <0.8.0 - def memory_to_calldata(m: re.Match) -> str: - return " calldata " + m.group(1) - - out = re.sub(r" memory (.*returns)", memory_to_calldata, out) - - with open(OUT_PATH, "w") as f: - f.write(out) - - forge_fmt = ["forge", "fmt", OUT_PATH] - res = subprocess.run(forge_fmt) - assert res.returncode == 0, f"command failed: {forge_fmt}" - - print(f"Wrote to {OUT_PATH}") - - -class CmpCheatcode: - cheatcode: "Cheatcode" - - def __init__(self, cheatcode: "Cheatcode"): - self.cheatcode = cheatcode - - def __lt__(self, other: "CmpCheatcode") -> bool: - return cmp_cheatcode(self.cheatcode, other.cheatcode) < 0 - - def __eq__(self, other: "CmpCheatcode") -> bool: - return cmp_cheatcode(self.cheatcode, other.cheatcode) == 0 - - def __gt__(self, other: "CmpCheatcode") -> bool: - return cmp_cheatcode(self.cheatcode, other.cheatcode) > 0 - - -def cmp_cheatcode(a: "Cheatcode", b: "Cheatcode") -> int: - if a.group != b.group: - return -1 if a.group < b.group else 1 - if a.status != b.status: - return -1 if a.status < b.status else 1 - if a.safety != b.safety: - return -1 if a.safety < b.safety else 1 - if a.func.id != b.func.id: - return -1 if a.func.id < b.func.id else 1 - return 0 - - -# HACK: A way to add group header comments without having to modify printer code -def prefix_with_group_headers(cheats: list["Cheatcode"]): - s = set() - for i, cheat in enumerate(cheats): - if cheat.group in s: - continue - - s.add(cheat.group) - - c = copy.deepcopy(cheat) - c.func.description = "" - c.func.declaration = f"// ======== {group(c.group)} ========" - cheats.insert(i, c) - return cheats - - -def group(s: str) -> str: - if s == "evm": - return "EVM" - if s == "json": - return "JSON" - return s[0].upper() + s[1:] - - -class Visibility(PyEnum): - EXTERNAL: str = "external" - PUBLIC: str = "public" - INTERNAL: str = "internal" - PRIVATE: str = "private" - - def __str__(self): - return self.value - - -class Mutability(PyEnum): - PURE: str = "pure" - VIEW: str = "view" - NONE: str = "" - - def __str__(self): - return self.value - - -class Function: - id: str - description: str - declaration: str - visibility: Visibility - mutability: Mutability - signature: str - selector: str - selector_bytes: bytes - - def __init__( - self, - id: str, - description: str, - declaration: str, - visibility: Visibility, - mutability: Mutability, - signature: str, - selector: str, - selector_bytes: bytes, - ): - self.id = id - self.description = description - self.declaration = declaration - self.visibility = visibility - self.mutability = mutability - self.signature = signature - self.selector = selector - self.selector_bytes = selector_bytes - - @staticmethod - def from_dict(d: dict) -> "Function": - return Function( - d["id"], - d["description"], - d["declaration"], - Visibility(d["visibility"]), - Mutability(d["mutability"]), - d["signature"], - d["selector"], - bytes(d["selectorBytes"]), - ) - - -class Cheatcode: - func: Function - group: str - status: str - safety: str - - def __init__(self, func: Function, group: str, status: str, safety: str): - self.func = func - self.group = group - self.status = status - self.safety = safety - - @staticmethod - def from_dict(d: dict) -> "Cheatcode": - return Cheatcode( - Function.from_dict(d["func"]), - str(d["group"]), - str(d["status"]), - str(d["safety"]), - ) - - -class Error: - name: str - description: str - declaration: str - - def __init__(self, name: str, description: str, declaration: str): - self.name = name - self.description = description - self.declaration = declaration - - @staticmethod - def from_dict(d: dict) -> "Error": - return Error(**d) - - -class Event: - name: str - description: str - declaration: str - - def __init__(self, name: str, description: str, declaration: str): - self.name = name - self.description = description - self.declaration = declaration - - @staticmethod - def from_dict(d: dict) -> "Event": - return Event(**d) - - -class EnumVariant: - name: str - description: str - - def __init__(self, name: str, description: str): - self.name = name - self.description = description - - -class Enum: - name: str - description: str - variants: list[EnumVariant] - - def __init__(self, name: str, description: str, variants: list[EnumVariant]): - self.name = name - self.description = description - self.variants = variants - - @staticmethod - def from_dict(d: dict) -> "Enum": - return Enum( - d["name"], - d["description"], - list(map(lambda v: EnumVariant(**v), d["variants"])), - ) - - -class StructField: - name: str - ty: str - description: str - - def __init__(self, name: str, ty: str, description: str): - self.name = name - self.ty = ty - self.description = description - - -class Struct: - name: str - description: str - fields: list[StructField] - - def __init__(self, name: str, description: str, fields: list[StructField]): - self.name = name - self.description = description - self.fields = fields - - @staticmethod - def from_dict(d: dict) -> "Struct": - return Struct( - d["name"], - d["description"], - list(map(lambda f: StructField(**f), d["fields"])), - ) - - -class Cheatcodes: - errors: list[Error] - events: list[Event] - enums: list[Enum] - structs: list[Struct] - cheatcodes: list[Cheatcode] - - def __init__( - self, - errors: list[Error], - events: list[Event], - enums: list[Enum], - structs: list[Struct], - cheatcodes: list[Cheatcode], - ): - self.errors = errors - self.events = events - self.enums = enums - self.structs = structs - self.cheatcodes = cheatcodes - - @staticmethod - def from_dict(d: dict) -> "Cheatcodes": - return Cheatcodes( - errors=[Error.from_dict(e) for e in d["errors"]], - events=[Event.from_dict(e) for e in d["events"]], - enums=[Enum.from_dict(e) for e in d["enums"]], - structs=[Struct.from_dict(e) for e in d["structs"]], - cheatcodes=[Cheatcode.from_dict(e) for e in d["cheatcodes"]], - ) - - @staticmethod - def from_json(s) -> "Cheatcodes": - return Cheatcodes.from_dict(json.loads(s)) - - @staticmethod - def from_json_file(file_path: str) -> "Cheatcodes": - with open(file_path, "r") as f: - return Cheatcodes.from_dict(json.load(f)) - - -class Item(PyEnum): - ERROR: str = "error" - EVENT: str = "event" - ENUM: str = "enum" - STRUCT: str = "struct" - FUNCTION: str = "function" - - -class ItemOrder: - _list: list[Item] - - def __init__(self, list: list[Item]) -> None: - assert len(list) <= len(Item), "list must not contain more items than Item" - assert len(list) == len(set(list)), "list must not contain duplicates" - self._list = list - pass - - def get_list(self) -> list[Item]: - return self._list - - @staticmethod - def default() -> "ItemOrder": - return ItemOrder( - [ - Item.ERROR, - Item.EVENT, - Item.ENUM, - Item.STRUCT, - Item.FUNCTION, - ] - ) - - -class CheatcodesPrinter: - buffer: str - - prelude: bool - spdx_identifier: str - solidity_requirement: str - abicoder_v2: bool - - block_doc_style: bool - - indent_level: int - _indent_str: str - - nl_str: str - - items_order: ItemOrder - - def __init__( - self, - buffer: str = "", - prelude: bool = True, - spdx_identifier: str = "UNLICENSED", - solidity_requirement: str = "", - abicoder_pragma: bool = False, - block_doc_style: bool = False, - indent_level: int = 0, - indent_with: int | str = 4, - nl_str: str = "\n", - items_order: ItemOrder = ItemOrder.default(), - ): - self.prelude = prelude - self.spdx_identifier = spdx_identifier - self.solidity_requirement = solidity_requirement - self.abicoder_v2 = abicoder_pragma - self.block_doc_style = block_doc_style - self.buffer = buffer - self.indent_level = indent_level - self.nl_str = nl_str - - if isinstance(indent_with, int): - assert indent_with >= 0 - self._indent_str = " " * indent_with - elif isinstance(indent_with, str): - self._indent_str = indent_with - else: - assert False, "indent_with must be int or str" - - self.items_order = items_order - - def finish(self) -> str: - ret = self.buffer.rstrip() - self.buffer = "" - return ret - - def p_contract(self, contract: Cheatcodes, name: str, inherits: str = ""): - if self.prelude: - self.p_prelude(contract) - - self._p_str("interface ") - name = name.strip() - if name != "": - self._p_str(name) - self._p_str(" ") - if inherits != "": - self._p_str("is ") - self._p_str(inherits) - self._p_str(" ") - self._p_str("{") - self._p_nl() - self._with_indent(lambda: self._p_items(contract)) - self._p_str("}") - self._p_nl() - - def _p_items(self, contract: Cheatcodes): - for item in self.items_order.get_list(): - if item == Item.ERROR: - self.p_errors(contract.errors) - elif item == Item.EVENT: - self.p_events(contract.events) - elif item == Item.ENUM: - self.p_enums(contract.enums) - elif item == Item.STRUCT: - self.p_structs(contract.structs) - elif item == Item.FUNCTION: - self.p_functions(contract.cheatcodes) - else: - assert False, f"unknown item {item}" - - def p_prelude(self, contract: Cheatcodes | None = None): - self._p_str(f"// SPDX-License-Identifier: {self.spdx_identifier}") - self._p_nl() - - if self.solidity_requirement != "": - req = self.solidity_requirement - elif contract and len(contract.errors) > 0: - req = ">=0.8.4 <0.9.0" - else: - req = ">=0.6.0 <0.9.0" - self._p_str(f"pragma solidity {req};") - self._p_nl() - - if self.abicoder_v2: - self._p_str("pragma experimental ABIEncoderV2;") - self._p_nl() - - self._p_nl() - - def p_errors(self, errors: list[Error]): - for error in errors: - self._p_line(lambda: self.p_error(error)) - - def p_error(self, error: Error): - self._p_comment(error.description, doc=True) - self._p_line(lambda: self._p_str(error.declaration)) - - def p_events(self, events: list[Event]): - for event in events: - self._p_line(lambda: self.p_event(event)) - - def p_event(self, event: Event): - self._p_comment(event.description, doc=True) - self._p_line(lambda: self._p_str(event.declaration)) - - def p_enums(self, enums: list[Enum]): - for enum in enums: - self._p_line(lambda: self.p_enum(enum)) - - def p_enum(self, enum: Enum): - self._p_comment(enum.description, doc=True) - self._p_line(lambda: self._p_str(f"enum {enum.name} {{")) - self._with_indent(lambda: self.p_enum_variants(enum.variants)) - self._p_line(lambda: self._p_str("}")) - - def p_enum_variants(self, variants: list[EnumVariant]): - for i, variant in enumerate(variants): - self._p_indent() - self._p_comment(variant.description) - - self._p_indent() - self._p_str(variant.name) - if i < len(variants) - 1: - self._p_str(",") - self._p_nl() - - def p_structs(self, structs: list[Struct]): - for struct in structs: - self._p_line(lambda: self.p_struct(struct)) - - def p_struct(self, struct: Struct): - self._p_comment(struct.description, doc=True) - self._p_line(lambda: self._p_str(f"struct {struct.name} {{")) - self._with_indent(lambda: self.p_struct_fields(struct.fields)) - self._p_line(lambda: self._p_str("}")) - - def p_struct_fields(self, fields: list[StructField]): - for field in fields: - self._p_line(lambda: self.p_struct_field(field)) - - def p_struct_field(self, field: StructField): - self._p_comment(field.description) - self._p_indented(lambda: self._p_str(f"{field.ty} {field.name};")) - - def p_functions(self, cheatcodes: list[Cheatcode]): - for cheatcode in cheatcodes: - self._p_line(lambda: self.p_function(cheatcode.func)) - - def p_function(self, func: Function): - self._p_comment(func.description, doc=True) - self._p_line(lambda: self._p_str(func.declaration)) - - def _p_comment(self, s: str, doc: bool = False): - s = s.strip() - if s == "": - return - - s = map(lambda line: line.lstrip(), s.split("\n")) - if self.block_doc_style: - self._p_str("/*") - if doc: - self._p_str("*") - self._p_nl() - for line in s: - self._p_indent() - self._p_str(" ") - if doc: - self._p_str("* ") - self._p_str(line) - self._p_nl() - self._p_indent() - self._p_str(" */") - self._p_nl() - else: - first_line = True - for line in s: - if not first_line: - self._p_indent() - first_line = False - - if doc: - self._p_str("/// ") - else: - self._p_str("// ") - self._p_str(line) - self._p_nl() - - def _with_indent(self, f: VoidFn): - self._inc_indent() - f() - self._dec_indent() - - def _p_line(self, f: VoidFn): - self._p_indent() - f() - self._p_nl() - - def _p_indented(self, f: VoidFn): - self._p_indent() - f() - - def _p_indent(self): - for _ in range(self.indent_level): - self._p_str(self._indent_str) - - def _p_nl(self): - self._p_str(self.nl_str) - - def _p_str(self, txt: str): - self.buffer += txt - - def _inc_indent(self): - self.indent_level += 1 - - def _dec_indent(self): - self.indent_level -= 1 - - -if __name__ == "__main__": - main() diff --git a/lib/signals-implicit-mode/lib/forge-std/src/Base.sol b/lib/signals-implicit-mode/lib/forge-std/src/Base.sol deleted file mode 100644 index 52a508210a..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/Base.sol +++ /dev/null @@ -1,48 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -import {StdStorage} from "./StdStorage.sol"; -import {Vm, VmSafe} from "./Vm.sol"; - -abstract contract CommonBase { - /// @dev Cheat code address. - /// Calculated as `address(uint160(uint256(keccak256("hevm cheat code"))))`. - address internal constant VM_ADDRESS = 0x7109709ECfa91a80626fF3989D68f67F5b1DD12D; - - /// @dev console.sol and console2.sol work by executing a staticcall to this address. - /// Calculated as `address(uint160(uint88(bytes11("console.log"))))`. - address internal constant CONSOLE = 0x000000000000000000636F6e736F6c652e6c6f67; - - /// @dev Used when deploying with create2. - /// Taken from https://github.com/Arachnid/deterministic-deployment-proxy. - address internal constant CREATE2_FACTORY = 0x4e59b44847b379578588920cA78FbF26c0B4956C; - - /// @dev The default address for tx.origin and msg.sender. - /// Calculated as `address(uint160(uint256(keccak256("foundry default caller"))))`. - address internal constant DEFAULT_SENDER = 0x1804c8AB1F12E6bbf3894d4083f33e07309d1f38; - - /// @dev The address of the first contract `CREATE`d by a running test contract. - /// When running tests, each test contract is `CREATE`d by `DEFAULT_SENDER` with nonce 1. - /// Calculated as `VM.computeCreateAddress(VM.computeCreateAddress(DEFAULT_SENDER, 1), 1)`. - address internal constant DEFAULT_TEST_CONTRACT = 0x5615dEB798BB3E4dFa0139dFa1b3D433Cc23b72f; - - /// @dev Deterministic deployment address of the Multicall3 contract. - /// Taken from https://www.multicall3.com. - address internal constant MULTICALL3_ADDRESS = 0xcA11bde05977b3631167028862bE2a173976CA11; - - /// @dev The order of the secp256k1 curve. - uint256 internal constant SECP256K1_ORDER = - 115792089237316195423570985008687907852837564279074904382605163141518161494337; - - uint256 internal constant UINT256_MAX = - 115792089237316195423570985008687907853269984665640564039457584007913129639935; - - Vm internal constant vm = Vm(VM_ADDRESS); - StdStorage internal stdstore; -} - -abstract contract TestBase is CommonBase {} - -abstract contract ScriptBase is CommonBase { - VmSafe internal constant vmSafe = VmSafe(VM_ADDRESS); -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/Config.sol b/lib/signals-implicit-mode/lib/forge-std/src/Config.sol deleted file mode 100644 index 1c63c8721b..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/Config.sol +++ /dev/null @@ -1,60 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.13; - -import {console} from "./console.sol"; -import {StdConfig} from "./StdConfig.sol"; -import {CommonBase} from "./Base.sol"; - -/// @notice Boilerplate to streamline the setup of multi-chain environments. -abstract contract Config is CommonBase { - // -- STORAGE (CONFIG + CHAINS + FORKS) ------------------------------------ - - /// @dev Contract instance holding the data from the TOML config file. - StdConfig internal config; - - /// @dev Array of chain IDs for which forks have been created. - uint256[] internal chainIds; - - /// @dev A mapping from a chain ID to its initialized fork ID. - mapping(uint256 => uint256) internal forkOf; - - // -- HELPER FUNCTIONS ----------------------------------------------------- - - /// @notice Loads configuration from a file. - /// - /// @dev This function instantiates a `Config` contract, caching all its config variables. - /// - /// @param filePath: the path to the TOML configuration file. - /// @param writeToFile: whether updates are written back to the TOML file. - function _loadConfig(string memory filePath, bool writeToFile) internal { - console.log("----------"); - console.log(string.concat("Loading config from '", filePath, "'")); - config = new StdConfig(filePath, writeToFile); - vm.makePersistent(address(config)); - console.log("Config successfully loaded"); - console.log("----------"); - } - - /// @notice Loads configuration from a file and creates forks for each specified chain. - /// - /// @dev This function instantiates a `Config` contract, caching all its config variables, - /// reads the configured chain ids, and iterates through them to create a fork for each one. - /// It also creates a map `forkOf[chainId] -> forkId` to easily switch between forks. - /// - /// @param filePath: the path to the TOML configuration file. - /// @param writeToFile: whether updates are written back to the TOML file. - function _loadConfigAndForks(string memory filePath, bool writeToFile) internal { - _loadConfig(filePath, writeToFile); - - console.log("Setting up forks for the configured chains..."); - uint256[] memory chains = config.getChainIds(); - for (uint256 i = 0; i < chains.length; i++) { - uint256 chainId = chains[i]; - uint256 forkId = vm.createFork(config.getRpcUrl(chainId)); - forkOf[chainId] = forkId; - chainIds.push(chainId); - } - console.log("Forks successfully created"); - console.log("----------"); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/LibVariable.sol b/lib/signals-implicit-mode/lib/forge-std/src/LibVariable.sol deleted file mode 100644 index c46b15328d..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/LibVariable.sol +++ /dev/null @@ -1,477 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.13; - -// Enable globally. -using LibVariable for Variable global; - -struct Variable { - Type ty; - bytes data; -} - -struct Type { - TypeKind kind; - bool isArray; -} - -enum TypeKind { - None, - Bool, - Address, - Bytes32, - Uint256, - Int256, - String, - Bytes -} - -/// @notice Library for type-safe coercion of the `Variable` struct to concrete types. -/// -/// @dev Ensures that when a `Variable` is cast to a concrete Solidity type, the operation is safe and the -/// underlying type matches what is expected. -/// Provides functions to check types, convert them to strings, and coerce `Variable` instances into -/// both single values and arrays of various types. -/// -/// Usage example: -/// ```solidity -/// import {LibVariable} from "./LibVariable.sol"; -/// -/// contract MyContract { -/// using LibVariable for Variable; -/// StdConfig config; // Assume 'config' is an instance of `StdConfig` and has already been loaded. -/// -/// function readValues() public { -/// // Retrieve a 'uint256' value from the config. -/// uint256 myNumber = config.get("important_number").toUint256(); -/// -/// // Would revert with `TypeMismatch` as 'important_number' isn't a `uint256` in the config file. -/// // string memory notANumber = config.get("important_number").toString(); -/// -/// // Retrieve a address array from the config. -/// string[] memory admins = config.get("whitelisted_admins").toAddressArray(); -/// } -/// } -/// ``` -library LibVariable { - error NotInitialized(); - error TypeMismatch(string expected, string actual); - error UnsafeCast(string message); - - // -- TYPE HELPERS ---------------------------------------------------- - - /// @notice Compares two Type instances for equality. - function isEqual(Type memory self, Type memory other) internal pure returns (bool) { - return self.kind == other.kind && self.isArray == other.isArray; - } - - /// @notice Compares two Type instances for equality. Reverts if they are not equal. - function assertEq(Type memory self, Type memory other) internal pure { - if (!isEqual(self, other)) { - revert TypeMismatch(toString(other), toString(self)); - } - } - - /// @notice Converts a Type struct to its full string representation (i.e. "uint256[]"). - function toString(Type memory self) internal pure returns (string memory) { - string memory tyStr = toString(self.kind); - if (!self.isArray || self.kind == TypeKind.None) { - return tyStr; - } else { - return string.concat(tyStr, "[]"); - } - } - - /// @dev Converts a `TypeKind` enum to its base string representation. - function toString(TypeKind self) internal pure returns (string memory) { - if (self == TypeKind.Bool) return "bool"; - if (self == TypeKind.Address) return "address"; - if (self == TypeKind.Bytes32) return "bytes32"; - if (self == TypeKind.Uint256) return "uint256"; - if (self == TypeKind.Int256) return "int256"; - if (self == TypeKind.String) return "string"; - if (self == TypeKind.Bytes) return "bytes"; - return "none"; - } - - /// @dev Converts a `TypeKind` enum to its base string representation. - function toTomlKey(TypeKind self) internal pure returns (string memory) { - if (self == TypeKind.Bool) return "bool"; - if (self == TypeKind.Address) return "address"; - if (self == TypeKind.Bytes32) return "bytes32"; - if (self == TypeKind.Uint256) return "uint"; - if (self == TypeKind.Int256) return "int"; - if (self == TypeKind.String) return "string"; - if (self == TypeKind.Bytes) return "bytes"; - return "none"; - } - - // -- VARIABLE HELPERS ---------------------------------------------------- - - /// @dev Checks if a `Variable` has been initialized and matches the expected type reverting if not. - modifier check(Variable memory self, Type memory expected) { - assertExists(self); - assertEq(self.ty, expected); - _; - } - - /// @dev Checks if a `Variable` has been initialized, reverting if not. - function assertExists(Variable memory self) public pure { - if (self.ty.kind == TypeKind.None) { - revert NotInitialized(); - } - } - - // -- VARIABLE COERCION FUNCTIONS (SINGLE VALUES) -------------------------- - - /// @notice Coerces a `Variable` to a `bool` value. - function toBool(Variable memory self) internal pure check(self, Type(TypeKind.Bool, false)) returns (bool) { - return abi.decode(self.data, (bool)); - } - - /// @notice Coerces a `Variable` to an `address` value. - function toAddress(Variable memory self) - internal - pure - check(self, Type(TypeKind.Address, false)) - returns (address) - { - return abi.decode(self.data, (address)); - } - - /// @notice Coerces a `Variable` to a `bytes32` value. - function toBytes32(Variable memory self) - internal - pure - check(self, Type(TypeKind.Bytes32, false)) - returns (bytes32) - { - return abi.decode(self.data, (bytes32)); - } - - /// @notice Coerces a `Variable` to a `uint256` value. - function toUint256(Variable memory self) - internal - pure - check(self, Type(TypeKind.Uint256, false)) - returns (uint256) - { - return abi.decode(self.data, (uint256)); - } - - /// @notice Coerces a `Variable` to a `uint128` value, checking for overflow. - function toUint128(Variable memory self) internal pure returns (uint128) { - uint256 value = self.toUint256(); - if (value > type(uint128).max) { - revert UnsafeCast("value does not fit in 'uint128'"); - } - return uint128(value); - } - - /// @notice Coerces a `Variable` to a `uint64` value, checking for overflow. - function toUint64(Variable memory self) internal pure returns (uint64) { - uint256 value = self.toUint256(); - if (value > type(uint64).max) { - revert UnsafeCast("value does not fit in 'uint64'"); - } - return uint64(value); - } - - /// @notice Coerces a `Variable` to a `uint32` value, checking for overflow. - function toUint32(Variable memory self) internal pure returns (uint32) { - uint256 value = self.toUint256(); - if (value > type(uint32).max) { - revert UnsafeCast("value does not fit in 'uint32'"); - } - return uint32(value); - } - - /// @notice Coerces a `Variable` to a `uint16` value, checking for overflow. - function toUint16(Variable memory self) internal pure returns (uint16) { - uint256 value = self.toUint256(); - if (value > type(uint16).max) { - revert UnsafeCast("value does not fit in 'uint16'"); - } - return uint16(value); - } - - /// @notice Coerces a `Variable` to a `uint8` value, checking for overflow. - function toUint8(Variable memory self) internal pure returns (uint8) { - uint256 value = self.toUint256(); - if (value > type(uint8).max) { - revert UnsafeCast("value does not fit in 'uint8'"); - } - return uint8(value); - } - - /// @notice Coerces a `Variable` to an `int256` value. - function toInt256(Variable memory self) internal pure check(self, Type(TypeKind.Int256, false)) returns (int256) { - return abi.decode(self.data, (int256)); - } - - /// @notice Coerces a `Variable` to an `int128` value, checking for overflow/underflow. - function toInt128(Variable memory self) internal pure returns (int128) { - int256 value = self.toInt256(); - if (value > type(int128).max || value < type(int128).min) { - revert UnsafeCast("value does not fit in 'int128'"); - } - return int128(value); - } - - /// @notice Coerces a `Variable` to an `int64` value, checking for overflow/underflow. - function toInt64(Variable memory self) internal pure returns (int64) { - int256 value = self.toInt256(); - if (value > type(int64).max || value < type(int64).min) { - revert UnsafeCast("value does not fit in 'int64'"); - } - return int64(value); - } - - /// @notice Coerces a `Variable` to an `int32` value, checking for overflow/underflow. - function toInt32(Variable memory self) internal pure returns (int32) { - int256 value = self.toInt256(); - if (value > type(int32).max || value < type(int32).min) { - revert UnsafeCast("value does not fit in 'int32'"); - } - return int32(value); - } - - /// @notice Coerces a `Variable` to an `int16` value, checking for overflow/underflow. - function toInt16(Variable memory self) internal pure returns (int16) { - int256 value = self.toInt256(); - if (value > type(int16).max || value < type(int16).min) { - revert UnsafeCast("value does not fit in 'int16'"); - } - return int16(value); - } - - /// @notice Coerces a `Variable` to an `int8` value, checking for overflow/underflow. - function toInt8(Variable memory self) internal pure returns (int8) { - int256 value = self.toInt256(); - if (value > type(int8).max || value < type(int8).min) { - revert UnsafeCast("value does not fit in 'int8'"); - } - return int8(value); - } - - /// @notice Coerces a `Variable` to a `string` value. - function toString(Variable memory self) - internal - pure - check(self, Type(TypeKind.String, false)) - returns (string memory) - { - return abi.decode(self.data, (string)); - } - - /// @notice Coerces a `Variable` to a `bytes` value. - function toBytes(Variable memory self) - internal - pure - check(self, Type(TypeKind.Bytes, false)) - returns (bytes memory) - { - return abi.decode(self.data, (bytes)); - } - - // -- VARIABLE COERCION FUNCTIONS (ARRAYS) --------------------------------- - - /// @notice Coerces a `Variable` to a `bool` array. - function toBoolArray(Variable memory self) - internal - pure - check(self, Type(TypeKind.Bool, true)) - returns (bool[] memory) - { - return abi.decode(self.data, (bool[])); - } - - /// @notice Coerces a `Variable` to an `address` array. - function toAddressArray(Variable memory self) - internal - pure - check(self, Type(TypeKind.Address, true)) - returns (address[] memory) - { - return abi.decode(self.data, (address[])); - } - - /// @notice Coerces a `Variable` to a `bytes32` array. - function toBytes32Array(Variable memory self) - internal - pure - check(self, Type(TypeKind.Bytes32, true)) - returns (bytes32[] memory) - { - return abi.decode(self.data, (bytes32[])); - } - - /// @notice Coerces a `Variable` to a `uint256` array. - function toUint256Array(Variable memory self) - internal - pure - check(self, Type(TypeKind.Uint256, true)) - returns (uint256[] memory) - { - return abi.decode(self.data, (uint256[])); - } - - /// @notice Coerces a `Variable` to a `uint128` array, checking for overflow. - function toUint128Array(Variable memory self) internal pure returns (uint128[] memory) { - uint256[] memory values = self.toUint256Array(); - uint128[] memory result = new uint128[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(uint128).max) { - revert UnsafeCast("value in array does not fit in 'uint128'"); - } - result[i] = uint128(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `uint64` array, checking for overflow. - function toUint64Array(Variable memory self) internal pure returns (uint64[] memory) { - uint256[] memory values = self.toUint256Array(); - uint64[] memory result = new uint64[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(uint64).max) { - revert UnsafeCast("value in array does not fit in 'uint64'"); - } - result[i] = uint64(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `uint32` array, checking for overflow. - function toUint32Array(Variable memory self) internal pure returns (uint32[] memory) { - uint256[] memory values = self.toUint256Array(); - uint32[] memory result = new uint32[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(uint32).max) { - revert UnsafeCast("value in array does not fit in 'uint32'"); - } - result[i] = uint32(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `uint16` array, checking for overflow. - function toUint16Array(Variable memory self) internal pure returns (uint16[] memory) { - uint256[] memory values = self.toUint256Array(); - uint16[] memory result = new uint16[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(uint16).max) { - revert UnsafeCast("value in array does not fit in 'uint16'"); - } - result[i] = uint16(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `uint8` array, checking for overflow. - function toUint8Array(Variable memory self) internal pure returns (uint8[] memory) { - uint256[] memory values = self.toUint256Array(); - uint8[] memory result = new uint8[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(uint8).max) { - revert UnsafeCast("value in array does not fit in 'uint8'"); - } - result[i] = uint8(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to an `int256` array. - function toInt256Array(Variable memory self) - internal - pure - check(self, Type(TypeKind.Int256, true)) - returns (int256[] memory) - { - return abi.decode(self.data, (int256[])); - } - - /// @notice Coerces a `Variable` to a `int128` array, checking for overflow/underflow. - function toInt128Array(Variable memory self) internal pure returns (int128[] memory) { - int256[] memory values = self.toInt256Array(); - int128[] memory result = new int128[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(int128).max || values[i] < type(int128).min) { - revert UnsafeCast("value in array does not fit in 'int128'"); - } - result[i] = int128(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `int64` array, checking for overflow/underflow. - function toInt64Array(Variable memory self) internal pure returns (int64[] memory) { - int256[] memory values = self.toInt256Array(); - int64[] memory result = new int64[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(int64).max || values[i] < type(int64).min) { - revert UnsafeCast("value in array does not fit in 'int64'"); - } - result[i] = int64(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `int32` array, checking for overflow/underflow. - function toInt32Array(Variable memory self) internal pure returns (int32[] memory) { - int256[] memory values = self.toInt256Array(); - int32[] memory result = new int32[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(int32).max || values[i] < type(int32).min) { - revert UnsafeCast("value in array does not fit in 'int32'"); - } - result[i] = int32(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `int16` array, checking for overflow/underflow. - function toInt16Array(Variable memory self) internal pure returns (int16[] memory) { - int256[] memory values = self.toInt256Array(); - int16[] memory result = new int16[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(int16).max || values[i] < type(int16).min) { - revert UnsafeCast("value in array does not fit in 'int16'"); - } - result[i] = int16(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `int8` array, checking for overflow/underflow. - function toInt8Array(Variable memory self) internal pure returns (int8[] memory) { - int256[] memory values = self.toInt256Array(); - int8[] memory result = new int8[](values.length); - for (uint256 i = 0; i < values.length; i++) { - if (values[i] > type(int8).max || values[i] < type(int8).min) { - revert UnsafeCast("value in array does not fit in 'int8'"); - } - result[i] = int8(values[i]); - } - return result; - } - - /// @notice Coerces a `Variable` to a `string` array. - function toStringArray(Variable memory self) - internal - pure - check(self, Type(TypeKind.String, true)) - returns (string[] memory) - { - return abi.decode(self.data, (string[])); - } - - /// @notice Coerces a `Variable` to a `bytes` array. - function toBytesArray(Variable memory self) - internal - pure - check(self, Type(TypeKind.Bytes, true)) - returns (bytes[] memory) - { - return abi.decode(self.data, (bytes[])); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/Script.sol b/lib/signals-implicit-mode/lib/forge-std/src/Script.sol deleted file mode 100644 index a2e2aa1cd0..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/Script.sol +++ /dev/null @@ -1,28 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -// 💬 ABOUT -// Forge Std's default Script. - -// 🧩 MODULES -import {console} from "./console.sol"; -import {console2} from "./console2.sol"; -import {safeconsole} from "./safeconsole.sol"; -import {StdChains} from "./StdChains.sol"; -import {StdCheatsSafe} from "./StdCheats.sol"; -import {StdConstants} from "./StdConstants.sol"; -import {stdJson} from "./StdJson.sol"; -import {stdMath} from "./StdMath.sol"; -import {StdStorage, stdStorageSafe} from "./StdStorage.sol"; -import {StdStyle} from "./StdStyle.sol"; -import {StdUtils} from "./StdUtils.sol"; -import {VmSafe} from "./Vm.sol"; - -// 📦 BOILERPLATE -import {ScriptBase} from "./Base.sol"; - -// ⭐️ SCRIPT -abstract contract Script is ScriptBase, StdChains, StdCheatsSafe, StdUtils { - // Note: IS_SCRIPT() must return true. - bool public IS_SCRIPT = true; -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdAssertions.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdAssertions.sol deleted file mode 100644 index 4248170da0..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdAssertions.sol +++ /dev/null @@ -1,764 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; -pragma experimental ABIEncoderV2; - -import {Vm} from "./Vm.sol"; - -abstract contract StdAssertions { - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - - event log(string); - event logs(bytes); - - event log_address(address); - event log_bytes32(bytes32); - event log_int(int256); - event log_uint(uint256); - event log_bytes(bytes); - event log_string(string); - - event log_named_address(string key, address val); - event log_named_bytes32(string key, bytes32 val); - event log_named_decimal_int(string key, int256 val, uint256 decimals); - event log_named_decimal_uint(string key, uint256 val, uint256 decimals); - event log_named_int(string key, int256 val); - event log_named_uint(string key, uint256 val); - event log_named_bytes(string key, bytes val); - event log_named_string(string key, string val); - - event log_array(uint256[] val); - event log_array(int256[] val); - event log_array(address[] val); - event log_named_array(string key, uint256[] val); - event log_named_array(string key, int256[] val); - event log_named_array(string key, address[] val); - - bytes32 private constant FAILED_SLOT = bytes32("failed"); - - bool private _failed; - - function failed() public view returns (bool) { - if (_failed) { - return true; - } else { - return vm.load(address(vm), FAILED_SLOT) != bytes32(0); - } - } - - function fail() internal virtual { - vm.store(address(vm), FAILED_SLOT, bytes32(uint256(1))); - _failed = true; - } - - function fail(string memory message) internal virtual { - fail(); - vm.assertTrue(false, message); - } - - function assertTrue(bool data) internal pure virtual { - if (!data) { - vm.assertTrue(data); - } - } - - function assertTrue(bool data, string memory err) internal pure virtual { - if (!data) { - vm.assertTrue(data, err); - } - } - - function assertFalse(bool data) internal pure virtual { - if (data) { - vm.assertFalse(data); - } - } - - function assertFalse(bool data, string memory err) internal pure virtual { - if (data) { - vm.assertFalse(data, err); - } - } - - function assertEq(bool left, bool right) internal pure virtual { - if (left != right) { - vm.assertEq(left, right); - } - } - - function assertEq(bool left, bool right, string memory err) internal pure virtual { - if (left != right) { - vm.assertEq(left, right, err); - } - } - - function assertEq(uint256 left, uint256 right) internal pure virtual { - if (left != right) { - vm.assertEq(left, right); - } - } - - function assertEq(uint256 left, uint256 right, string memory err) internal pure virtual { - if (left != right) { - vm.assertEq(left, right, err); - } - } - - function assertEqDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertEqDecimal(left, right, decimals); - } - - function assertEqDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertEqDecimal(left, right, decimals, err); - } - - function assertEq(int256 left, int256 right) internal pure virtual { - if (left != right) { - vm.assertEq(left, right); - } - } - - function assertEq(int256 left, int256 right, string memory err) internal pure virtual { - if (left != right) { - vm.assertEq(left, right, err); - } - } - - function assertEqDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertEqDecimal(left, right, decimals); - } - - function assertEqDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertEqDecimal(left, right, decimals, err); - } - - function assertEq(address left, address right) internal pure virtual { - if (left != right) { - vm.assertEq(left, right); - } - } - - function assertEq(address left, address right, string memory err) internal pure virtual { - if (left != right) { - vm.assertEq(left, right, err); - } - } - - function assertEq(bytes32 left, bytes32 right) internal pure virtual { - if (left != right) { - vm.assertEq(left, right); - } - } - - function assertEq(bytes32 left, bytes32 right, string memory err) internal pure virtual { - if (left != right) { - vm.assertEq(left, right, err); - } - } - - function assertEq32(bytes32 left, bytes32 right) internal pure virtual { - if (left != right) { - vm.assertEq(left, right); - } - } - - function assertEq32(bytes32 left, bytes32 right, string memory err) internal pure virtual { - if (left != right) { - vm.assertEq(left, right, err); - } - } - - function assertEq(string memory left, string memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(string memory left, string memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bytes memory left, bytes memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bytes memory left, bytes memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bool[] memory left, bool[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bool[] memory left, bool[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(uint256[] memory left, uint256[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(uint256[] memory left, uint256[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(int256[] memory left, int256[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(int256[] memory left, int256[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(address[] memory left, address[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(address[] memory left, address[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bytes32[] memory left, bytes32[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bytes32[] memory left, bytes32[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(string[] memory left, string[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(string[] memory left, string[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bytes[] memory left, bytes[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bytes[] memory left, bytes[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - // Legacy helper - function assertEqUint(uint256 left, uint256 right) internal pure virtual { - assertEq(left, right); - } - - function assertNotEq(bool left, bool right) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right); - } - } - - function assertNotEq(bool left, bool right, string memory err) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right, err); - } - } - - function assertNotEq(uint256 left, uint256 right) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right); - } - } - - function assertNotEq(uint256 left, uint256 right, string memory err) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right, err); - } - } - - function assertNotEqDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertNotEqDecimal(left, right, decimals); - } - - function assertNotEqDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) - internal - pure - virtual - { - vm.assertNotEqDecimal(left, right, decimals, err); - } - - function assertNotEq(int256 left, int256 right) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right); - } - } - - function assertNotEq(int256 left, int256 right, string memory err) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right, err); - } - } - - function assertNotEqDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertNotEqDecimal(left, right, decimals); - } - - function assertNotEqDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertNotEqDecimal(left, right, decimals, err); - } - - function assertNotEq(address left, address right) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right); - } - } - - function assertNotEq(address left, address right, string memory err) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right, err); - } - } - - function assertNotEq(bytes32 left, bytes32 right) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right); - } - } - - function assertNotEq(bytes32 left, bytes32 right, string memory err) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right, err); - } - } - - function assertNotEq32(bytes32 left, bytes32 right) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right); - } - } - - function assertNotEq32(bytes32 left, bytes32 right, string memory err) internal pure virtual { - if (left == right) { - vm.assertNotEq(left, right, err); - } - } - - function assertNotEq(string memory left, string memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(string memory left, string memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bytes memory left, bytes memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bytes memory left, bytes memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bool[] memory left, bool[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bool[] memory left, bool[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(uint256[] memory left, uint256[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(uint256[] memory left, uint256[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(int256[] memory left, int256[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(int256[] memory left, int256[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(address[] memory left, address[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(address[] memory left, address[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bytes32[] memory left, bytes32[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bytes32[] memory left, bytes32[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(string[] memory left, string[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(string[] memory left, string[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bytes[] memory left, bytes[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bytes[] memory left, bytes[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertLt(uint256 left, uint256 right) internal pure virtual { - if (left >= right) { - vm.assertLt(left, right); - } - } - - function assertLt(uint256 left, uint256 right, string memory err) internal pure virtual { - if (left >= right) { - vm.assertLt(left, right, err); - } - } - - function assertLtDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertLtDecimal(left, right, decimals); - } - - function assertLtDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertLtDecimal(left, right, decimals, err); - } - - function assertLt(int256 left, int256 right) internal pure virtual { - if (left >= right) { - vm.assertLt(left, right); - } - } - - function assertLt(int256 left, int256 right, string memory err) internal pure virtual { - if (left >= right) { - vm.assertLt(left, right, err); - } - } - - function assertLtDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertLtDecimal(left, right, decimals); - } - - function assertLtDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertLtDecimal(left, right, decimals, err); - } - - function assertGt(uint256 left, uint256 right) internal pure virtual { - if (left <= right) { - vm.assertGt(left, right); - } - } - - function assertGt(uint256 left, uint256 right, string memory err) internal pure virtual { - if (left <= right) { - vm.assertGt(left, right, err); - } - } - - function assertGtDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertGtDecimal(left, right, decimals); - } - - function assertGtDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertGtDecimal(left, right, decimals, err); - } - - function assertGt(int256 left, int256 right) internal pure virtual { - if (left <= right) { - vm.assertGt(left, right); - } - } - - function assertGt(int256 left, int256 right, string memory err) internal pure virtual { - if (left <= right) { - vm.assertGt(left, right, err); - } - } - - function assertGtDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertGtDecimal(left, right, decimals); - } - - function assertGtDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertGtDecimal(left, right, decimals, err); - } - - function assertLe(uint256 left, uint256 right) internal pure virtual { - if (left > right) { - vm.assertLe(left, right); - } - } - - function assertLe(uint256 left, uint256 right, string memory err) internal pure virtual { - if (left > right) { - vm.assertLe(left, right, err); - } - } - - function assertLeDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertLeDecimal(left, right, decimals); - } - - function assertLeDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertLeDecimal(left, right, decimals, err); - } - - function assertLe(int256 left, int256 right) internal pure virtual { - if (left > right) { - vm.assertLe(left, right); - } - } - - function assertLe(int256 left, int256 right, string memory err) internal pure virtual { - if (left > right) { - vm.assertLe(left, right, err); - } - } - - function assertLeDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertLeDecimal(left, right, decimals); - } - - function assertLeDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertLeDecimal(left, right, decimals, err); - } - - function assertGe(uint256 left, uint256 right) internal pure virtual { - if (left < right) { - vm.assertGe(left, right); - } - } - - function assertGe(uint256 left, uint256 right, string memory err) internal pure virtual { - if (left < right) { - vm.assertGe(left, right, err); - } - } - - function assertGeDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertGeDecimal(left, right, decimals); - } - - function assertGeDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertGeDecimal(left, right, decimals, err); - } - - function assertGe(int256 left, int256 right) internal pure virtual { - if (left < right) { - vm.assertGe(left, right); - } - } - - function assertGe(int256 left, int256 right, string memory err) internal pure virtual { - if (left < right) { - vm.assertGe(left, right, err); - } - } - - function assertGeDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertGeDecimal(left, right, decimals); - } - - function assertGeDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertGeDecimal(left, right, decimals, err); - } - - function assertApproxEqAbs(uint256 left, uint256 right, uint256 maxDelta) internal pure virtual { - vm.assertApproxEqAbs(left, right, maxDelta); - } - - function assertApproxEqAbs(uint256 left, uint256 right, uint256 maxDelta, string memory err) - internal - pure - virtual - { - vm.assertApproxEqAbs(left, right, maxDelta, err); - } - - function assertApproxEqAbsDecimal(uint256 left, uint256 right, uint256 maxDelta, uint256 decimals) - internal - pure - virtual - { - vm.assertApproxEqAbsDecimal(left, right, maxDelta, decimals); - } - - function assertApproxEqAbsDecimal( - uint256 left, - uint256 right, - uint256 maxDelta, - uint256 decimals, - string memory err - ) internal pure virtual { - vm.assertApproxEqAbsDecimal(left, right, maxDelta, decimals, err); - } - - function assertApproxEqAbs(int256 left, int256 right, uint256 maxDelta) internal pure virtual { - vm.assertApproxEqAbs(left, right, maxDelta); - } - - function assertApproxEqAbs(int256 left, int256 right, uint256 maxDelta, string memory err) internal pure virtual { - vm.assertApproxEqAbs(left, right, maxDelta, err); - } - - function assertApproxEqAbsDecimal(int256 left, int256 right, uint256 maxDelta, uint256 decimals) - internal - pure - virtual - { - vm.assertApproxEqAbsDecimal(left, right, maxDelta, decimals); - } - - function assertApproxEqAbsDecimal(int256 left, int256 right, uint256 maxDelta, uint256 decimals, string memory err) - internal - pure - virtual - { - vm.assertApproxEqAbsDecimal(left, right, maxDelta, decimals, err); - } - - function assertApproxEqRel( - uint256 left, - uint256 right, - uint256 maxPercentDelta // An 18 decimal fixed point number, where 1e18 == 100% - ) internal pure virtual { - vm.assertApproxEqRel(left, right, maxPercentDelta); - } - - function assertApproxEqRel( - uint256 left, - uint256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - string memory err - ) internal pure virtual { - vm.assertApproxEqRel(left, right, maxPercentDelta, err); - } - - function assertApproxEqRelDecimal( - uint256 left, - uint256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - uint256 decimals - ) internal pure virtual { - vm.assertApproxEqRelDecimal(left, right, maxPercentDelta, decimals); - } - - function assertApproxEqRelDecimal( - uint256 left, - uint256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - uint256 decimals, - string memory err - ) internal pure virtual { - vm.assertApproxEqRelDecimal(left, right, maxPercentDelta, decimals, err); - } - - function assertApproxEqRel(int256 left, int256 right, uint256 maxPercentDelta) internal pure virtual { - vm.assertApproxEqRel(left, right, maxPercentDelta); - } - - function assertApproxEqRel( - int256 left, - int256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - string memory err - ) internal pure virtual { - vm.assertApproxEqRel(left, right, maxPercentDelta, err); - } - - function assertApproxEqRelDecimal( - int256 left, - int256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - uint256 decimals - ) internal pure virtual { - vm.assertApproxEqRelDecimal(left, right, maxPercentDelta, decimals); - } - - function assertApproxEqRelDecimal( - int256 left, - int256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - uint256 decimals, - string memory err - ) internal pure virtual { - vm.assertApproxEqRelDecimal(left, right, maxPercentDelta, decimals, err); - } - - // Inherited from DSTest, not used but kept for backwards-compatibility - function checkEq0(bytes memory left, bytes memory right) internal pure returns (bool) { - return keccak256(left) == keccak256(right); - } - - function assertEq0(bytes memory left, bytes memory right) internal pure virtual { - assertEq(left, right); - } - - function assertEq0(bytes memory left, bytes memory right, string memory err) internal pure virtual { - assertEq(left, right, err); - } - - function assertNotEq0(bytes memory left, bytes memory right) internal pure virtual { - assertNotEq(left, right); - } - - function assertNotEq0(bytes memory left, bytes memory right, string memory err) internal pure virtual { - assertNotEq(left, right, err); - } - - function assertEqCall(address target, bytes memory callDataA, bytes memory callDataB) internal virtual { - assertEqCall(target, callDataA, target, callDataB, true); - } - - function assertEqCall(address targetA, bytes memory callDataA, address targetB, bytes memory callDataB) - internal - virtual - { - assertEqCall(targetA, callDataA, targetB, callDataB, true); - } - - function assertEqCall(address target, bytes memory callDataA, bytes memory callDataB, bool strictRevertData) - internal - virtual - { - assertEqCall(target, callDataA, target, callDataB, strictRevertData); - } - - function assertEqCall( - address targetA, - bytes memory callDataA, - address targetB, - bytes memory callDataB, - bool strictRevertData - ) internal virtual { - (bool successA, bytes memory returnDataA) = address(targetA).call(callDataA); - (bool successB, bytes memory returnDataB) = address(targetB).call(callDataB); - - if (successA && successB) { - assertEq(returnDataA, returnDataB, "Call return data does not match"); - } - - if (!successA && !successB && strictRevertData) { - assertEq(returnDataA, returnDataB, "Call revert data does not match"); - } - - if (!successA && successB) { - emit log("Error: Calls were not equal"); - emit log_named_bytes(" Left call revert data", returnDataA); - emit log_named_bytes(" Right call return data", returnDataB); - revert("assertion failed"); - } - - if (successA && !successB) { - emit log("Error: Calls were not equal"); - emit log_named_bytes(" Left call return data", returnDataA); - emit log_named_bytes(" Right call revert data", returnDataB); - revert("assertion failed"); - } - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdChains.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdChains.sol deleted file mode 100644 index 3bc5f43af1..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdChains.sol +++ /dev/null @@ -1,287 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; -pragma experimental ABIEncoderV2; - -import {VmSafe} from "./Vm.sol"; - -/** - * StdChains provides information about EVM compatible chains that can be used in scripts/tests. - * For each chain, the chain's name, chain ID, and a default RPC URL are provided. Chains are - * identified by their alias, which is the same as the alias in the `[rpc_endpoints]` section of - * the `foundry.toml` file. For best UX, ensure the alias in the `foundry.toml` file match the - * alias used in this contract, which can be found as the first argument to the - * `setChainWithDefaultRpcUrl` call in the `initializeStdChains` function. - * - * There are two main ways to use this contract: - * 1. Set a chain with `setChain(string memory chainAlias, ChainData memory chain)` or - * `setChain(string memory chainAlias, Chain memory chain)` - * 2. Get a chain with `getChain(string memory chainAlias)` or `getChain(uint256 chainId)`. - * - * The first time either of those are used, chains are initialized with the default set of RPC URLs. - * This is done in `initializeStdChains`, which uses `setChainWithDefaultRpcUrl`. Defaults are recorded in - * `defaultRpcUrls`. - * - * The `setChain` function is straightforward, and it simply saves off the given chain data. - * - * The `getChain` methods use `getChainWithUpdatedRpcUrl` to return a chain. For example, let's say - * we want to retrieve the RPC URL for `mainnet`: - * - If you have specified data with `setChain`, it will return that. - * - If you have configured a mainnet RPC URL in `foundry.toml`, it will return the URL, provided it - * is valid (e.g. a URL is specified, or an environment variable is given and exists). - * - If neither of the above conditions is met, the default data is returned. - * - * Summarizing the above, the prioritization hierarchy is `setChain` -> `foundry.toml` -> environment variable -> defaults. - */ -abstract contract StdChains { - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - bool private stdChainsInitialized; - - struct ChainData { - string name; - uint256 chainId; - string rpcUrl; - } - - struct Chain { - // The chain name. - string name; - // The chain's Chain ID. - uint256 chainId; - // The chain's alias. (i.e. what gets specified in `foundry.toml`). - string chainAlias; - // A default RPC endpoint for this chain. - // NOTE: This default RPC URL is included for convenience to facilitate quick tests and - // experimentation. Do not use this RPC URL for production test suites, CI, or other heavy - // usage as you will be throttled and this is a disservice to others who need this endpoint. - string rpcUrl; - } - - // Maps from the chain's alias (matching the alias in the `foundry.toml` file) to chain data. - mapping(string => Chain) private chains; - // Maps from the chain's alias to it's default RPC URL. - mapping(string => string) private defaultRpcUrls; - // Maps from a chain ID to it's alias. - mapping(uint256 => string) private idToAlias; - - bool private fallbackToDefaultRpcUrls = true; - - // The RPC URL will be fetched from config or defaultRpcUrls if possible. - function getChain(string memory chainAlias) internal virtual returns (Chain memory chain) { - require(bytes(chainAlias).length != 0, "StdChains getChain(string): Chain alias cannot be the empty string."); - - initializeStdChains(); - chain = chains[chainAlias]; - require( - chain.chainId != 0, - string(abi.encodePacked("StdChains getChain(string): Chain with alias \"", chainAlias, "\" not found.")) - ); - - chain = getChainWithUpdatedRpcUrl(chainAlias, chain); - } - - function getChain(uint256 chainId) internal virtual returns (Chain memory chain) { - require(chainId != 0, "StdChains getChain(uint256): Chain ID cannot be 0."); - initializeStdChains(); - string memory chainAlias = idToAlias[chainId]; - - chain = chains[chainAlias]; - - require( - chain.chainId != 0, - string(abi.encodePacked("StdChains getChain(uint256): Chain with ID ", vm.toString(chainId), " not found.")) - ); - - chain = getChainWithUpdatedRpcUrl(chainAlias, chain); - } - - // set chain info, with priority to argument's rpcUrl field. - function setChain(string memory chainAlias, ChainData memory chain) internal virtual { - require( - bytes(chainAlias).length != 0, - "StdChains setChain(string,ChainData): Chain alias cannot be the empty string." - ); - - require(chain.chainId != 0, "StdChains setChain(string,ChainData): Chain ID cannot be 0."); - - initializeStdChains(); - string memory foundAlias = idToAlias[chain.chainId]; - - require( - bytes(foundAlias).length == 0 || keccak256(bytes(foundAlias)) == keccak256(bytes(chainAlias)), - string( - abi.encodePacked( - "StdChains setChain(string,ChainData): Chain ID ", - vm.toString(chain.chainId), - " already used by \"", - foundAlias, - "\"." - ) - ) - ); - - uint256 oldChainId = chains[chainAlias].chainId; - delete idToAlias[oldChainId]; - - chains[chainAlias] = - Chain({name: chain.name, chainId: chain.chainId, chainAlias: chainAlias, rpcUrl: chain.rpcUrl}); - idToAlias[chain.chainId] = chainAlias; - } - - // set chain info, with priority to argument's rpcUrl field. - function setChain(string memory chainAlias, Chain memory chain) internal virtual { - setChain(chainAlias, ChainData({name: chain.name, chainId: chain.chainId, rpcUrl: chain.rpcUrl})); - } - - function _toUpper(string memory str) private pure returns (string memory) { - bytes memory strb = bytes(str); - bytes memory copy = new bytes(strb.length); - for (uint256 i = 0; i < strb.length; i++) { - bytes1 b = strb[i]; - if (b >= 0x61 && b <= 0x7A) { - copy[i] = bytes1(uint8(b) - 32); - } else { - copy[i] = b; - } - } - return string(copy); - } - - // lookup rpcUrl, in descending order of priority: - // current -> config (foundry.toml) -> environment variable -> default - function getChainWithUpdatedRpcUrl(string memory chainAlias, Chain memory chain) - private - view - returns (Chain memory) - { - if (bytes(chain.rpcUrl).length == 0) { - try vm.rpcUrl(chainAlias) returns (string memory configRpcUrl) { - chain.rpcUrl = configRpcUrl; - } catch (bytes memory err) { - string memory envName = string(abi.encodePacked(_toUpper(chainAlias), "_RPC_URL")); - if (fallbackToDefaultRpcUrls) { - chain.rpcUrl = vm.envOr(envName, defaultRpcUrls[chainAlias]); - } else { - chain.rpcUrl = vm.envString(envName); - } - // Distinguish 'not found' from 'cannot read' - // The upstream error thrown by forge for failing cheats changed so we check both the old and new versions - bytes memory oldNotFoundError = - abi.encodeWithSignature("CheatCodeError", string(abi.encodePacked("invalid rpc url ", chainAlias))); - bytes memory newNotFoundError = abi.encodeWithSignature( - "CheatcodeError(string)", string(abi.encodePacked("invalid rpc url: ", chainAlias)) - ); - bytes32 errHash = keccak256(err); - if ( - (errHash != keccak256(oldNotFoundError) && errHash != keccak256(newNotFoundError)) - || bytes(chain.rpcUrl).length == 0 - ) { - /// @solidity memory-safe-assembly - assembly { - revert(add(32, err), mload(err)) - } - } - } - } - return chain; - } - - function setFallbackToDefaultRpcUrls(bool useDefault) internal { - fallbackToDefaultRpcUrls = useDefault; - } - - function initializeStdChains() private { - if (stdChainsInitialized) return; - - stdChainsInitialized = true; - - // If adding an RPC here, make sure to test the default RPC URL in `test_Rpcs` in `StdChains.t.sol` - setChainWithDefaultRpcUrl("anvil", ChainData("Anvil", 31337, "http://127.0.0.1:8545")); - setChainWithDefaultRpcUrl("mainnet", ChainData("Mainnet", 1, "https://eth.llamarpc.com")); - setChainWithDefaultRpcUrl( - "sepolia", ChainData("Sepolia", 11155111, "https://sepolia.infura.io/v3/b9794ad1ddf84dfb8c34d6bb5dca2001") - ); - setChainWithDefaultRpcUrl("holesky", ChainData("Holesky", 17000, "https://rpc.holesky.ethpandaops.io")); - setChainWithDefaultRpcUrl("hoodi", ChainData("Hoodi", 560048, "https://rpc.hoodi.ethpandaops.io")); - setChainWithDefaultRpcUrl("optimism", ChainData("Optimism", 10, "https://mainnet.optimism.io")); - setChainWithDefaultRpcUrl( - "optimism_sepolia", ChainData("Optimism Sepolia", 11155420, "https://sepolia.optimism.io") - ); - setChainWithDefaultRpcUrl("arbitrum_one", ChainData("Arbitrum One", 42161, "https://arb1.arbitrum.io/rpc")); - setChainWithDefaultRpcUrl( - "arbitrum_one_sepolia", ChainData("Arbitrum One Sepolia", 421614, "https://sepolia-rollup.arbitrum.io/rpc") - ); - setChainWithDefaultRpcUrl("arbitrum_nova", ChainData("Arbitrum Nova", 42170, "https://nova.arbitrum.io/rpc")); - setChainWithDefaultRpcUrl("polygon", ChainData("Polygon", 137, "https://polygon-rpc.com")); - setChainWithDefaultRpcUrl( - "polygon_amoy", ChainData("Polygon Amoy", 80002, "https://rpc-amoy.polygon.technology") - ); - setChainWithDefaultRpcUrl("avalanche", ChainData("Avalanche", 43114, "https://api.avax.network/ext/bc/C/rpc")); - setChainWithDefaultRpcUrl( - "avalanche_fuji", ChainData("Avalanche Fuji", 43113, "https://api.avax-test.network/ext/bc/C/rpc") - ); - setChainWithDefaultRpcUrl( - "bnb_smart_chain", ChainData("BNB Smart Chain", 56, "https://bsc-dataseed1.binance.org") - ); - setChainWithDefaultRpcUrl( - "bnb_smart_chain_testnet", - ChainData("BNB Smart Chain Testnet", 97, "https://rpc.ankr.com/bsc_testnet_chapel") - ); - setChainWithDefaultRpcUrl("gnosis_chain", ChainData("Gnosis Chain", 100, "https://rpc.gnosischain.com")); - setChainWithDefaultRpcUrl("moonbeam", ChainData("Moonbeam", 1284, "https://rpc.api.moonbeam.network")); - setChainWithDefaultRpcUrl( - "moonriver", ChainData("Moonriver", 1285, "https://rpc.api.moonriver.moonbeam.network") - ); - setChainWithDefaultRpcUrl("moonbase", ChainData("Moonbase", 1287, "https://rpc.testnet.moonbeam.network")); - setChainWithDefaultRpcUrl("base_sepolia", ChainData("Base Sepolia", 84532, "https://sepolia.base.org")); - setChainWithDefaultRpcUrl("base", ChainData("Base", 8453, "https://mainnet.base.org")); - setChainWithDefaultRpcUrl("blast_sepolia", ChainData("Blast Sepolia", 168587773, "https://sepolia.blast.io")); - setChainWithDefaultRpcUrl("blast", ChainData("Blast", 81457, "https://rpc.blast.io")); - setChainWithDefaultRpcUrl("fantom_opera", ChainData("Fantom Opera", 250, "https://rpc.ankr.com/fantom/")); - setChainWithDefaultRpcUrl( - "fantom_opera_testnet", ChainData("Fantom Opera Testnet", 4002, "https://rpc.ankr.com/fantom_testnet/") - ); - setChainWithDefaultRpcUrl("fraxtal", ChainData("Fraxtal", 252, "https://rpc.frax.com")); - setChainWithDefaultRpcUrl("fraxtal_testnet", ChainData("Fraxtal Testnet", 2522, "https://rpc.testnet.frax.com")); - setChainWithDefaultRpcUrl( - "berachain_bartio_testnet", ChainData("Berachain bArtio Testnet", 80084, "https://bartio.rpc.berachain.com") - ); - setChainWithDefaultRpcUrl("flare", ChainData("Flare", 14, "https://flare-api.flare.network/ext/C/rpc")); - setChainWithDefaultRpcUrl( - "flare_coston2", ChainData("Flare Coston2", 114, "https://coston2-api.flare.network/ext/C/rpc") - ); - - setChainWithDefaultRpcUrl("mode", ChainData("Mode", 34443, "https://mode.drpc.org")); - setChainWithDefaultRpcUrl("mode_sepolia", ChainData("Mode Sepolia", 919, "https://sepolia.mode.network")); - - setChainWithDefaultRpcUrl("zora", ChainData("Zora", 7777777, "https://zora.drpc.org")); - setChainWithDefaultRpcUrl( - "zora_sepolia", ChainData("Zora Sepolia", 999999999, "https://sepolia.rpc.zora.energy") - ); - - setChainWithDefaultRpcUrl("race", ChainData("Race", 6805, "https://racemainnet.io")); - setChainWithDefaultRpcUrl("race_sepolia", ChainData("Race Sepolia", 6806, "https://racemainnet.io")); - - setChainWithDefaultRpcUrl("metal", ChainData("Metal", 1750, "https://metall2.drpc.org")); - setChainWithDefaultRpcUrl("metal_sepolia", ChainData("Metal Sepolia", 1740, "https://testnet.rpc.metall2.com")); - - setChainWithDefaultRpcUrl("binary", ChainData("Binary", 624, "https://rpc.zero.thebinaryholdings.com")); - setChainWithDefaultRpcUrl( - "binary_sepolia", ChainData("Binary Sepolia", 625, "https://rpc.zero.thebinaryholdings.com") - ); - - setChainWithDefaultRpcUrl("orderly", ChainData("Orderly", 291, "https://rpc.orderly.network")); - setChainWithDefaultRpcUrl( - "orderly_sepolia", ChainData("Orderly Sepolia", 4460, "https://testnet-rpc.orderly.org") - ); - } - - // set chain info, with priority to chainAlias' rpc url in foundry.toml - function setChainWithDefaultRpcUrl(string memory chainAlias, ChainData memory chain) private { - string memory rpcUrl = chain.rpcUrl; - defaultRpcUrls[chainAlias] = rpcUrl; - chain.rpcUrl = ""; - setChain(chainAlias, chain); - chain.rpcUrl = rpcUrl; // restore argument - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdCheats.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdCheats.sol deleted file mode 100644 index 9f360dec21..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdCheats.sol +++ /dev/null @@ -1,829 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -import {StdStorage, stdStorage} from "./StdStorage.sol"; -import {console2} from "./console2.sol"; -import {Vm} from "./Vm.sol"; - -abstract contract StdCheatsSafe { - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - - uint256 private constant UINT256_MAX = - 115792089237316195423570985008687907853269984665640564039457584007913129639935; - - bool private gasMeteringOff; - - // Data structures to parse Transaction objects from the broadcast artifact - // that conform to EIP1559. The Raw structs is what is parsed from the JSON - // and then converted to the one that is used by the user for better UX. - - struct RawTx1559 { - string[] arguments; - address contractAddress; - string contractName; - // json value name = function - string functionSig; - bytes32 hash; - // json value name = tx - RawTx1559Detail txDetail; - // json value name = type - string opcode; - } - - struct RawTx1559Detail { - AccessList[] accessList; - bytes data; - address from; - bytes gas; - bytes nonce; - address to; - bytes txType; - bytes value; - } - - struct Tx1559 { - string[] arguments; - address contractAddress; - string contractName; - string functionSig; - bytes32 hash; - Tx1559Detail txDetail; - string opcode; - } - - struct Tx1559Detail { - AccessList[] accessList; - bytes data; - address from; - uint256 gas; - uint256 nonce; - address to; - uint256 txType; - uint256 value; - } - - // Data structures to parse Transaction objects from the broadcast artifact - // that DO NOT conform to EIP1559. The Raw structs is what is parsed from the JSON - // and then converted to the one that is used by the user for better UX. - - struct TxLegacy { - string[] arguments; - address contractAddress; - string contractName; - string functionSig; - string hash; - string opcode; - TxDetailLegacy transaction; - } - - struct TxDetailLegacy { - AccessList[] accessList; - uint256 chainId; - bytes data; - address from; - uint256 gas; - uint256 gasPrice; - bytes32 hash; - uint256 nonce; - bytes1 opcode; - bytes32 r; - bytes32 s; - uint256 txType; - address to; - uint8 v; - uint256 value; - } - - struct AccessList { - address accessAddress; - bytes32[] storageKeys; - } - - // Data structures to parse Receipt objects from the broadcast artifact. - // The Raw structs is what is parsed from the JSON - // and then converted to the one that is used by the user for better UX. - - struct RawReceipt { - bytes32 blockHash; - bytes blockNumber; - address contractAddress; - bytes cumulativeGasUsed; - bytes effectiveGasPrice; - address from; - bytes gasUsed; - RawReceiptLog[] logs; - bytes logsBloom; - bytes status; - address to; - bytes32 transactionHash; - bytes transactionIndex; - } - - struct Receipt { - bytes32 blockHash; - uint256 blockNumber; - address contractAddress; - uint256 cumulativeGasUsed; - uint256 effectiveGasPrice; - address from; - uint256 gasUsed; - ReceiptLog[] logs; - bytes logsBloom; - uint256 status; - address to; - bytes32 transactionHash; - uint256 transactionIndex; - } - - // Data structures to parse the entire broadcast artifact, assuming the - // transactions conform to EIP1559. - - struct EIP1559ScriptArtifact { - string[] libraries; - string path; - string[] pending; - Receipt[] receipts; - uint256 timestamp; - Tx1559[] transactions; - TxReturn[] txReturns; - } - - struct RawEIP1559ScriptArtifact { - string[] libraries; - string path; - string[] pending; - RawReceipt[] receipts; - TxReturn[] txReturns; - uint256 timestamp; - RawTx1559[] transactions; - } - - struct RawReceiptLog { - // json value = address - address logAddress; - bytes32 blockHash; - bytes blockNumber; - bytes data; - bytes logIndex; - bool removed; - bytes32[] topics; - bytes32 transactionHash; - bytes transactionIndex; - bytes transactionLogIndex; - } - - struct ReceiptLog { - // json value = address - address logAddress; - bytes32 blockHash; - uint256 blockNumber; - bytes data; - uint256 logIndex; - bytes32[] topics; - uint256 transactionIndex; - uint256 transactionLogIndex; - bool removed; - } - - struct TxReturn { - string internalType; - string value; - } - - struct Account { - address addr; - uint256 key; - } - - enum AddressType { - Payable, - NonPayable, - ZeroAddress, - Precompile, - ForgeAddress - } - - // Checks that `addr` is not blacklisted by token contracts that have a blacklist. - function assumeNotBlacklisted(address token, address addr) internal view virtual { - // Nothing to check if `token` is not a contract. - uint256 tokenCodeSize; - assembly { - tokenCodeSize := extcodesize(token) - } - require(tokenCodeSize > 0, "StdCheats assumeNotBlacklisted(address,address): Token address is not a contract."); - - bool success; - bytes memory returnData; - - // 4-byte selector for `isBlacklisted(address)`, used by USDC. - (success, returnData) = token.staticcall(abi.encodeWithSelector(0xfe575a87, addr)); - vm.assume(!success || abi.decode(returnData, (bool)) == false); - - // 4-byte selector for `isBlackListed(address)`, used by USDT. - (success, returnData) = token.staticcall(abi.encodeWithSelector(0xe47d6060, addr)); - vm.assume(!success || abi.decode(returnData, (bool)) == false); - } - - // Checks that `addr` is not blacklisted by token contracts that have a blacklist. - // This is identical to `assumeNotBlacklisted(address,address)` but with a different name, for - // backwards compatibility, since this name was used in the original PR which already has - // a release. This function can be removed in a future release once we want a breaking change. - function assumeNoBlacklisted(address token, address addr) internal view virtual { - assumeNotBlacklisted(token, addr); - } - - function assumeAddressIsNot(address addr, AddressType addressType) internal virtual { - if (addressType == AddressType.Payable) { - assumeNotPayable(addr); - } else if (addressType == AddressType.NonPayable) { - assumePayable(addr); - } else if (addressType == AddressType.ZeroAddress) { - assumeNotZeroAddress(addr); - } else if (addressType == AddressType.Precompile) { - assumeNotPrecompile(addr); - } else if (addressType == AddressType.ForgeAddress) { - assumeNotForgeAddress(addr); - } - } - - function assumeAddressIsNot(address addr, AddressType addressType1, AddressType addressType2) internal virtual { - assumeAddressIsNot(addr, addressType1); - assumeAddressIsNot(addr, addressType2); - } - - function assumeAddressIsNot( - address addr, - AddressType addressType1, - AddressType addressType2, - AddressType addressType3 - ) internal virtual { - assumeAddressIsNot(addr, addressType1); - assumeAddressIsNot(addr, addressType2); - assumeAddressIsNot(addr, addressType3); - } - - function assumeAddressIsNot( - address addr, - AddressType addressType1, - AddressType addressType2, - AddressType addressType3, - AddressType addressType4 - ) internal virtual { - assumeAddressIsNot(addr, addressType1); - assumeAddressIsNot(addr, addressType2); - assumeAddressIsNot(addr, addressType3); - assumeAddressIsNot(addr, addressType4); - } - - // This function checks whether an address, `addr`, is payable. It works by sending 1 wei to - // `addr` and checking the `success` return value. - // NOTE: This function may result in state changes depending on the fallback/receive logic - // implemented by `addr`, which should be taken into account when this function is used. - function _isPayable(address addr) private returns (bool) { - require( - addr.balance < UINT256_MAX, - "StdCheats _isPayable(address): Balance equals max uint256, so it cannot receive any more funds" - ); - uint256 origBalanceTest = address(this).balance; - uint256 origBalanceAddr = address(addr).balance; - - vm.deal(address(this), 1); - (bool success,) = payable(addr).call{value: 1}(""); - - // reset balances - vm.deal(address(this), origBalanceTest); - vm.deal(addr, origBalanceAddr); - - return success; - } - - // NOTE: This function may result in state changes depending on the fallback/receive logic - // implemented by `addr`, which should be taken into account when this function is used. See the - // `_isPayable` method for more information. - function assumePayable(address addr) internal virtual { - vm.assume(_isPayable(addr)); - } - - function assumeNotPayable(address addr) internal virtual { - vm.assume(!_isPayable(addr)); - } - - function assumeNotZeroAddress(address addr) internal pure virtual { - vm.assume(addr != address(0)); - } - - function assumeNotPrecompile(address addr) internal pure virtual { - assumeNotPrecompile(addr, _pureChainId()); - } - - function assumeNotPrecompile(address addr, uint256 chainId) internal pure virtual { - // Note: For some chains like Optimism these are technically predeploys (i.e. bytecode placed at a specific - // address), but the same rationale for excluding them applies so we include those too. - - // These are reserved by Ethereum and may be on all EVM-compatible chains. - vm.assume(addr < address(0x1) || addr > address(0xff)); - - // forgefmt: disable-start - if (chainId == 10 || chainId == 420) { - // https://github.com/ethereum-optimism/optimism/blob/eaa371a0184b56b7ca6d9eb9cb0a2b78b2ccd864/op-bindings/predeploys/addresses.go#L6-L21 - vm.assume(addr < address(0x4200000000000000000000000000000000000000) || addr > address(0x4200000000000000000000000000000000000800)); - } else if (chainId == 42161 || chainId == 421613) { - // https://developer.arbitrum.io/useful-addresses#arbitrum-precompiles-l2-same-on-all-arb-chains - vm.assume(addr < address(0x0000000000000000000000000000000000000064) || addr > address(0x0000000000000000000000000000000000000068)); - } else if (chainId == 43114 || chainId == 43113) { - // https://github.com/ava-labs/subnet-evm/blob/47c03fd007ecaa6de2c52ea081596e0a88401f58/precompile/params.go#L18-L59 - vm.assume(addr < address(0x0100000000000000000000000000000000000000) || addr > address(0x01000000000000000000000000000000000000ff)); - vm.assume(addr < address(0x0200000000000000000000000000000000000000) || addr > address(0x02000000000000000000000000000000000000FF)); - vm.assume(addr < address(0x0300000000000000000000000000000000000000) || addr > address(0x03000000000000000000000000000000000000Ff)); - } - // forgefmt: disable-end - } - - function assumeNotForgeAddress(address addr) internal pure virtual { - // vm, console, and Create2Deployer addresses - vm.assume( - addr != address(vm) && addr != 0x000000000000000000636F6e736F6c652e6c6f67 - && addr != 0x4e59b44847b379578588920cA78FbF26c0B4956C - ); - } - - function assumeUnusedAddress(address addr) internal view virtual { - uint256 size; - assembly { - size := extcodesize(addr) - } - vm.assume(size == 0); - - assumeNotPrecompile(addr); - assumeNotZeroAddress(addr); - assumeNotForgeAddress(addr); - } - - function readEIP1559ScriptArtifact(string memory path) - internal - view - virtual - returns (EIP1559ScriptArtifact memory) - { - string memory data = vm.readFile(path); - bytes memory parsedData = vm.parseJson(data); - RawEIP1559ScriptArtifact memory rawArtifact = abi.decode(parsedData, (RawEIP1559ScriptArtifact)); - EIP1559ScriptArtifact memory artifact; - artifact.libraries = rawArtifact.libraries; - artifact.path = rawArtifact.path; - artifact.timestamp = rawArtifact.timestamp; - artifact.pending = rawArtifact.pending; - artifact.txReturns = rawArtifact.txReturns; - artifact.receipts = rawToConvertedReceipts(rawArtifact.receipts); - artifact.transactions = rawToConvertedEIPTx1559s(rawArtifact.transactions); - return artifact; - } - - function rawToConvertedEIPTx1559s(RawTx1559[] memory rawTxs) internal pure virtual returns (Tx1559[] memory) { - Tx1559[] memory txs = new Tx1559[](rawTxs.length); - for (uint256 i; i < rawTxs.length; i++) { - txs[i] = rawToConvertedEIPTx1559(rawTxs[i]); - } - return txs; - } - - function rawToConvertedEIPTx1559(RawTx1559 memory rawTx) internal pure virtual returns (Tx1559 memory) { - Tx1559 memory transaction; - transaction.arguments = rawTx.arguments; - transaction.contractName = rawTx.contractName; - transaction.functionSig = rawTx.functionSig; - transaction.hash = rawTx.hash; - transaction.txDetail = rawToConvertedEIP1559Detail(rawTx.txDetail); - transaction.opcode = rawTx.opcode; - return transaction; - } - - function rawToConvertedEIP1559Detail(RawTx1559Detail memory rawDetail) - internal - pure - virtual - returns (Tx1559Detail memory) - { - Tx1559Detail memory txDetail; - txDetail.data = rawDetail.data; - txDetail.from = rawDetail.from; - txDetail.to = rawDetail.to; - txDetail.nonce = _bytesToUint(rawDetail.nonce); - txDetail.txType = _bytesToUint(rawDetail.txType); - txDetail.value = _bytesToUint(rawDetail.value); - txDetail.gas = _bytesToUint(rawDetail.gas); - txDetail.accessList = rawDetail.accessList; - return txDetail; - } - - function readTx1559s(string memory path) internal view virtual returns (Tx1559[] memory) { - string memory deployData = vm.readFile(path); - bytes memory parsedDeployData = vm.parseJson(deployData, ".transactions"); - RawTx1559[] memory rawTxs = abi.decode(parsedDeployData, (RawTx1559[])); - return rawToConvertedEIPTx1559s(rawTxs); - } - - function readTx1559(string memory path, uint256 index) internal view virtual returns (Tx1559 memory) { - string memory deployData = vm.readFile(path); - string memory key = string(abi.encodePacked(".transactions[", vm.toString(index), "]")); - bytes memory parsedDeployData = vm.parseJson(deployData, key); - RawTx1559 memory rawTx = abi.decode(parsedDeployData, (RawTx1559)); - return rawToConvertedEIPTx1559(rawTx); - } - - // Analogous to readTransactions, but for receipts. - function readReceipts(string memory path) internal view virtual returns (Receipt[] memory) { - string memory deployData = vm.readFile(path); - bytes memory parsedDeployData = vm.parseJson(deployData, ".receipts"); - RawReceipt[] memory rawReceipts = abi.decode(parsedDeployData, (RawReceipt[])); - return rawToConvertedReceipts(rawReceipts); - } - - function readReceipt(string memory path, uint256 index) internal view virtual returns (Receipt memory) { - string memory deployData = vm.readFile(path); - string memory key = string(abi.encodePacked(".receipts[", vm.toString(index), "]")); - bytes memory parsedDeployData = vm.parseJson(deployData, key); - RawReceipt memory rawReceipt = abi.decode(parsedDeployData, (RawReceipt)); - return rawToConvertedReceipt(rawReceipt); - } - - function rawToConvertedReceipts(RawReceipt[] memory rawReceipts) internal pure virtual returns (Receipt[] memory) { - Receipt[] memory receipts = new Receipt[](rawReceipts.length); - for (uint256 i; i < rawReceipts.length; i++) { - receipts[i] = rawToConvertedReceipt(rawReceipts[i]); - } - return receipts; - } - - function rawToConvertedReceipt(RawReceipt memory rawReceipt) internal pure virtual returns (Receipt memory) { - Receipt memory receipt; - receipt.blockHash = rawReceipt.blockHash; - receipt.to = rawReceipt.to; - receipt.from = rawReceipt.from; - receipt.contractAddress = rawReceipt.contractAddress; - receipt.effectiveGasPrice = _bytesToUint(rawReceipt.effectiveGasPrice); - receipt.cumulativeGasUsed = _bytesToUint(rawReceipt.cumulativeGasUsed); - receipt.gasUsed = _bytesToUint(rawReceipt.gasUsed); - receipt.status = _bytesToUint(rawReceipt.status); - receipt.transactionIndex = _bytesToUint(rawReceipt.transactionIndex); - receipt.blockNumber = _bytesToUint(rawReceipt.blockNumber); - receipt.logs = rawToConvertedReceiptLogs(rawReceipt.logs); - receipt.logsBloom = rawReceipt.logsBloom; - receipt.transactionHash = rawReceipt.transactionHash; - return receipt; - } - - function rawToConvertedReceiptLogs(RawReceiptLog[] memory rawLogs) - internal - pure - virtual - returns (ReceiptLog[] memory) - { - ReceiptLog[] memory logs = new ReceiptLog[](rawLogs.length); - for (uint256 i; i < rawLogs.length; i++) { - logs[i].logAddress = rawLogs[i].logAddress; - logs[i].blockHash = rawLogs[i].blockHash; - logs[i].blockNumber = _bytesToUint(rawLogs[i].blockNumber); - logs[i].data = rawLogs[i].data; - logs[i].logIndex = _bytesToUint(rawLogs[i].logIndex); - logs[i].topics = rawLogs[i].topics; - logs[i].transactionIndex = _bytesToUint(rawLogs[i].transactionIndex); - logs[i].transactionLogIndex = _bytesToUint(rawLogs[i].transactionLogIndex); - logs[i].removed = rawLogs[i].removed; - } - return logs; - } - - // Deploy a contract by fetching the contract bytecode from - // the artifacts directory - // e.g. `deployCode(code, abi.encode(arg1,arg2,arg3))` - function deployCode(string memory what, bytes memory args) internal virtual returns (address addr) { - bytes memory bytecode = abi.encodePacked(vm.getCode(what), args); - /// @solidity memory-safe-assembly - assembly { - addr := create(0, add(bytecode, 0x20), mload(bytecode)) - } - - require(addr != address(0), "StdCheats deployCode(string,bytes): Deployment failed."); - } - - function deployCode(string memory what) internal virtual returns (address addr) { - bytes memory bytecode = vm.getCode(what); - /// @solidity memory-safe-assembly - assembly { - addr := create(0, add(bytecode, 0x20), mload(bytecode)) - } - - require(addr != address(0), "StdCheats deployCode(string): Deployment failed."); - } - - /// @dev deploy contract with value on construction - function deployCode(string memory what, bytes memory args, uint256 val) internal virtual returns (address addr) { - bytes memory bytecode = abi.encodePacked(vm.getCode(what), args); - /// @solidity memory-safe-assembly - assembly { - addr := create(val, add(bytecode, 0x20), mload(bytecode)) - } - - require(addr != address(0), "StdCheats deployCode(string,bytes,uint256): Deployment failed."); - } - - function deployCode(string memory what, uint256 val) internal virtual returns (address addr) { - bytes memory bytecode = vm.getCode(what); - /// @solidity memory-safe-assembly - assembly { - addr := create(val, add(bytecode, 0x20), mload(bytecode)) - } - - require(addr != address(0), "StdCheats deployCode(string,uint256): Deployment failed."); - } - - // creates a labeled address and the corresponding private key - function makeAddrAndKey(string memory name) internal virtual returns (address addr, uint256 privateKey) { - privateKey = uint256(keccak256(abi.encodePacked(name))); - addr = vm.addr(privateKey); - vm.label(addr, name); - } - - // creates a labeled address - function makeAddr(string memory name) internal virtual returns (address addr) { - (addr,) = makeAddrAndKey(name); - } - - // Destroys an account immediately, sending the balance to beneficiary. - // Destroying means: balance will be zero, code will be empty, and nonce will be 0 - // This is similar to selfdestruct but not identical: selfdestruct destroys code and nonce - // only after tx ends, this will run immediately. - function destroyAccount(address who, address beneficiary) internal virtual { - uint256 currBalance = who.balance; - vm.etch(who, abi.encode()); - vm.deal(who, 0); - vm.resetNonce(who); - - uint256 beneficiaryBalance = beneficiary.balance; - vm.deal(beneficiary, currBalance + beneficiaryBalance); - } - - // creates a struct containing both a labeled address and the corresponding private key - function makeAccount(string memory name) internal virtual returns (Account memory account) { - (account.addr, account.key) = makeAddrAndKey(name); - } - - function deriveRememberKey(string memory mnemonic, uint32 index) - internal - virtual - returns (address who, uint256 privateKey) - { - privateKey = vm.deriveKey(mnemonic, index); - who = vm.rememberKey(privateKey); - } - - function _bytesToUint(bytes memory b) private pure returns (uint256) { - require(b.length <= 32, "StdCheats _bytesToUint(bytes): Bytes length exceeds 32."); - return abi.decode(abi.encodePacked(new bytes(32 - b.length), b), (uint256)); - } - - function isFork() internal view virtual returns (bool status) { - try vm.activeFork() { - status = true; - } catch (bytes memory) {} - } - - modifier skipWhenForking() { - if (!isFork()) { - _; - } - } - - modifier skipWhenNotForking() { - if (isFork()) { - _; - } - } - - modifier noGasMetering() { - vm.pauseGasMetering(); - // To prevent turning gas monitoring back on with nested functions that use this modifier, - // we check if gasMetering started in the off position. If it did, we don't want to turn - // it back on until we exit the top level function that used the modifier - // - // i.e. funcA() noGasMetering { funcB() }, where funcB has noGasMetering as well. - // funcA will have `gasStartedOff` as false, funcB will have it as true, - // so we only turn metering back on at the end of the funcA - bool gasStartedOff = gasMeteringOff; - gasMeteringOff = true; - - _; - - // if gas metering was on when this modifier was called, turn it back on at the end - if (!gasStartedOff) { - gasMeteringOff = false; - vm.resumeGasMetering(); - } - } - - // We use this complex approach of `_viewChainId` and `_pureChainId` to ensure there are no - // compiler warnings when accessing chain ID in any solidity version supported by forge-std. We - // can't simply access the chain ID in a normal view or pure function because the solc View Pure - // Checker changed `chainid` from pure to view in 0.8.0. - function _viewChainId() private view returns (uint256 chainId) { - // Assembly required since `block.chainid` was introduced in 0.8.0. - assembly { - chainId := chainid() - } - - address(this); // Silence warnings in older Solc versions. - } - - function _pureChainId() private pure returns (uint256 chainId) { - function() internal view returns (uint256) fnIn = _viewChainId; - function() internal pure returns (uint256) pureChainId; - assembly { - pureChainId := fnIn - } - chainId = pureChainId(); - } -} - -// Wrappers around cheatcodes to avoid footguns -abstract contract StdCheats is StdCheatsSafe { - using stdStorage for StdStorage; - - StdStorage private stdstore; - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - address private constant CONSOLE2_ADDRESS = 0x000000000000000000636F6e736F6c652e6c6f67; - - // Skip forward or rewind time by the specified number of seconds - function skip(uint256 time) internal virtual { - vm.warp(vm.getBlockTimestamp() + time); - } - - function rewind(uint256 time) internal virtual { - vm.warp(vm.getBlockTimestamp() - time); - } - - // Setup a prank from an address that has some ether - function hoax(address msgSender) internal virtual { - vm.deal(msgSender, 1 << 128); - vm.prank(msgSender); - } - - function hoax(address msgSender, uint256 give) internal virtual { - vm.deal(msgSender, give); - vm.prank(msgSender); - } - - function hoax(address msgSender, address origin) internal virtual { - vm.deal(msgSender, 1 << 128); - vm.prank(msgSender, origin); - } - - function hoax(address msgSender, address origin, uint256 give) internal virtual { - vm.deal(msgSender, give); - vm.prank(msgSender, origin); - } - - // Start perpetual prank from an address that has some ether - function startHoax(address msgSender) internal virtual { - vm.deal(msgSender, 1 << 128); - vm.startPrank(msgSender); - } - - function startHoax(address msgSender, uint256 give) internal virtual { - vm.deal(msgSender, give); - vm.startPrank(msgSender); - } - - // Start perpetual prank from an address that has some ether - // tx.origin is set to the origin parameter - function startHoax(address msgSender, address origin) internal virtual { - vm.deal(msgSender, 1 << 128); - vm.startPrank(msgSender, origin); - } - - function startHoax(address msgSender, address origin, uint256 give) internal virtual { - vm.deal(msgSender, give); - vm.startPrank(msgSender, origin); - } - - function changePrank(address msgSender) internal virtual { - console2_log_StdCheats("changePrank is deprecated. Please use vm.startPrank instead."); - vm.stopPrank(); - vm.startPrank(msgSender); - } - - function changePrank(address msgSender, address txOrigin) internal virtual { - vm.stopPrank(); - vm.startPrank(msgSender, txOrigin); - } - - // The same as Vm's `deal` - // Use the alternative signature for ERC20 tokens - function deal(address to, uint256 give) internal virtual { - vm.deal(to, give); - } - - // Set the balance of an account for any ERC20 token - // Use the alternative signature to update `totalSupply` - function deal(address token, address to, uint256 give) internal virtual { - deal(token, to, give, false); - } - - // Set the balance of an account for any ERC1155 token - // Use the alternative signature to update `totalSupply` - function dealERC1155(address token, address to, uint256 id, uint256 give) internal virtual { - dealERC1155(token, to, id, give, false); - } - - function deal(address token, address to, uint256 give, bool adjust) internal virtual { - // get current balance - (, bytes memory balData) = token.staticcall(abi.encodeWithSelector(0x70a08231, to)); - uint256 prevBal = abi.decode(balData, (uint256)); - - // update balance - stdstore.target(token).sig(0x70a08231).with_key(to).checked_write(give); - - // update total supply - if (adjust) { - (, bytes memory totSupData) = token.staticcall(abi.encodeWithSelector(0x18160ddd)); - uint256 totSup = abi.decode(totSupData, (uint256)); - if (give < prevBal) { - totSup -= (prevBal - give); - } else { - totSup += (give - prevBal); - } - stdstore.target(token).sig(0x18160ddd).checked_write(totSup); - } - } - - function dealERC1155(address token, address to, uint256 id, uint256 give, bool adjust) internal virtual { - // get current balance - (, bytes memory balData) = token.staticcall(abi.encodeWithSelector(0x00fdd58e, to, id)); - uint256 prevBal = abi.decode(balData, (uint256)); - - // update balance - stdstore.target(token).sig(0x00fdd58e).with_key(to).with_key(id).checked_write(give); - - // update total supply - if (adjust) { - (, bytes memory totSupData) = token.staticcall(abi.encodeWithSelector(0xbd85b039, id)); - require( - totSupData.length != 0, - "StdCheats deal(address,address,uint,uint,bool): target contract is not ERC1155Supply." - ); - uint256 totSup = abi.decode(totSupData, (uint256)); - if (give < prevBal) { - totSup -= (prevBal - give); - } else { - totSup += (give - prevBal); - } - stdstore.target(token).sig(0xbd85b039).with_key(id).checked_write(totSup); - } - } - - function dealERC721(address token, address to, uint256 id) internal virtual { - // check if token id is already minted and the actual owner. - (bool successMinted, bytes memory ownerData) = token.staticcall(abi.encodeWithSelector(0x6352211e, id)); - require(successMinted, "StdCheats deal(address,address,uint,bool): id not minted."); - - // get owner current balance - (, bytes memory fromBalData) = - token.staticcall(abi.encodeWithSelector(0x70a08231, abi.decode(ownerData, (address)))); - uint256 fromPrevBal = abi.decode(fromBalData, (uint256)); - - // get new user current balance - (, bytes memory toBalData) = token.staticcall(abi.encodeWithSelector(0x70a08231, to)); - uint256 toPrevBal = abi.decode(toBalData, (uint256)); - - // update balances - stdstore.target(token).sig(0x70a08231).with_key(abi.decode(ownerData, (address))).checked_write(--fromPrevBal); - stdstore.target(token).sig(0x70a08231).with_key(to).checked_write(++toPrevBal); - - // update owner - stdstore.target(token).sig(0x6352211e).with_key(id).checked_write(to); - } - - function deployCodeTo(string memory what, address where) internal virtual { - deployCodeTo(what, "", 0, where); - } - - function deployCodeTo(string memory what, bytes memory args, address where) internal virtual { - deployCodeTo(what, args, 0, where); - } - - function deployCodeTo(string memory what, bytes memory args, uint256 value, address where) internal virtual { - bytes memory creationCode = vm.getCode(what); - vm.etch(where, abi.encodePacked(creationCode, args)); - (bool success, bytes memory runtimeBytecode) = where.call{value: value}(""); - require(success, "StdCheats deployCodeTo(string,bytes,uint256,address): Failed to create runtime bytecode."); - vm.etch(where, runtimeBytecode); - } - - // Used to prevent the compilation of console, which shortens the compilation time when console is not used elsewhere. - function console2_log_StdCheats(string memory p0) private view { - (bool status,) = address(CONSOLE2_ADDRESS).staticcall(abi.encodeWithSignature("log(string)", p0)); - status; - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdConfig.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdConfig.sol deleted file mode 100644 index 506ac34a58..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdConfig.sol +++ /dev/null @@ -1,612 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.13; - -import {VmSafe} from "./Vm.sol"; -import {Variable, Type, TypeKind, LibVariable} from "./LibVariable.sol"; - -/// @notice A contract that parses a toml configuration file and load its -/// variables into storage, automatically casting them, on deployment. -/// -/// @dev This contract assumes a toml structure where top-level keys -/// represent chain ids or aliases. Under each chain key, variables are -/// organized by type in separate sub-tables like `[.]`, where -/// type must be: `bool`, `address`, `bytes32`, `uint`, `ìnt`, `string`, or `bytes`. -/// -/// Supported format: -/// ``` -/// [mainnet] -/// endpoint_url = "${MAINNET_RPC}" -/// -/// [mainnet.bool] -/// is_live = true -/// -/// [mainnet.address] -/// weth = "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2" -/// whitelisted_admins = [ -/// "${MAINNET_ADMIN}", -/// "0x00000000000000000000000000000000deadbeef", -/// "0x000000000000000000000000000000c0ffeebabe" -/// ] -/// -/// [mainnet.uint] -/// important_number = 123 -/// ``` -contract StdConfig { - using LibVariable for Type; - using LibVariable for TypeKind; - - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - /// @dev Types: `bool`, `address`, `bytes32`, `uint`, `ìnt`, `string`, `bytes`. - uint8 private constant NUM_TYPES = 7; - - // -- ERRORS --------------------------------------------------------------- - - error AlreadyInitialized(string key); - error InvalidChainKey(string aliasOrId); - error ChainNotInitialized(uint256 chainId); - error UnableToParseVariable(string key); - error WriteToFileInForbiddenCtxt(); - - // -- STORAGE (CACHE FROM CONFIG FILE) ------------------------------------ - - /// @dev Path to the loaded TOML configuration file. - string private _filePath; - - /// @dev List of top-level keys found in the TOML file, assumed to be chain names/aliases. - string[] private _chainKeys; - - /// @dev Storage for the configured RPC URL for each chain. - mapping(uint256 => string) private _rpcOf; - - /// @dev Storage for values, organized by chain ID and variable key. - mapping(uint256 => mapping(string => bytes)) private _dataOf; - - /// @dev Type cache for runtime checking when casting. - mapping(uint256 => mapping(string => Type)) private _typeOf; - - /// @dev When enabled, `set` will always write updates back to the configuration file. - /// Can only be enabled in a scripting context to prevent file corruption from - /// concurrent I/O access, as tests run in parallel. - bool private _writeToFile; - - // -- CONSTRUCTOR ---------------------------------------------------------- - - /// @notice Reads the TOML file and iterates through each top-level key, which is - /// assumed to be a chain name or ID. For each chain, it caches its RPC - /// endpoint and all variables defined in typed sub-tables like `[.]`, - /// where type must be: `bool`, `address`, `uint`, `bytes32`, `string`, or `bytes`. - /// - /// The constructor attempts to parse each variable first as a single value, - /// and if that fails, as an array of that type. If a variable cannot be - /// parsed as either, the constructor will revert with an error. - /// - /// @param configFilePath: The local path to the TOML configuration file. - /// @param writeToFile: Whether to write updates back to the TOML file. Only for scripts. - constructor(string memory configFilePath, bool writeToFile) { - if (writeToFile && !vm.isContext(VmSafe.ForgeContext.ScriptGroup)) { - revert WriteToFileInForbiddenCtxt(); - } - - _filePath = configFilePath; - _writeToFile = writeToFile; - string memory content = vm.resolveEnv(vm.readFile(configFilePath)); - string[] memory chain_keys = vm.parseTomlKeys(content, "$"); - - // Cache the entire configuration to storage - for (uint256 i = 0; i < chain_keys.length; i++) { - string memory chain_key = chain_keys[i]; - // Ignore top-level keys that are not tables - if (vm.parseTomlKeys(content, string.concat("$.", chain_key)).length == 0) { - continue; - } - uint256 chainId = resolveChainId(chain_key); - _chainKeys.push(chain_key); - - // Cache the configure rpc endpoint for that chain. - // Falls back to `[rpc_endpoints]`. Panics if no rpc endpoint is configured. - try vm.parseTomlString(content, string.concat("$.", chain_key, ".endpoint_url")) returns (string memory url) - { - _rpcOf[chainId] = vm.resolveEnv(url); - } catch { - _rpcOf[chainId] = vm.resolveEnv(vm.rpcUrl(chain_key)); - } - - // Iterate through all the available `TypeKind`s (except `None`) to create the sub-section paths - for (uint8 t = 1; t <= NUM_TYPES; t++) { - TypeKind ty = TypeKind(t); - string memory typePath = string.concat("$.", chain_key, ".", ty.toTomlKey()); - - try vm.parseTomlKeys(content, typePath) returns (string[] memory keys) { - for (uint256 j = 0; j < keys.length; j++) { - string memory key = keys[j]; - if (_typeOf[chainId][key].kind == TypeKind.None) { - _loadAndCacheValue(content, string.concat(typePath, ".", key), chainId, key, ty); - } else { - revert AlreadyInitialized(key); - } - } - } catch {} // Section does not exist, ignore. - } - } - } - - function _loadAndCacheValue( - string memory content, - string memory path, - uint256 chainId, - string memory key, - TypeKind ty - ) private { - bool success = false; - if (ty == TypeKind.Bool) { - try vm.parseTomlBool(content, path) returns (bool val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Bool, false); - success = true; - } catch { - try vm.parseTomlBoolArray(content, path) returns (bool[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Bool, true); - success = true; - } catch {} - } - } else if (ty == TypeKind.Address) { - try vm.parseTomlAddress(content, path) returns (address val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Address, false); - success = true; - } catch { - try vm.parseTomlAddressArray(content, path) returns (address[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Address, true); - success = true; - } catch {} - } - } else if (ty == TypeKind.Bytes32) { - try vm.parseTomlBytes32(content, path) returns (bytes32 val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Bytes32, false); - success = true; - } catch { - try vm.parseTomlBytes32Array(content, path) returns (bytes32[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Bytes32, true); - success = true; - } catch {} - } - } else if (ty == TypeKind.Uint256) { - try vm.parseTomlUint(content, path) returns (uint256 val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Uint256, false); - success = true; - } catch { - try vm.parseTomlUintArray(content, path) returns (uint256[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Uint256, true); - success = true; - } catch {} - } - } else if (ty == TypeKind.Int256) { - try vm.parseTomlInt(content, path) returns (int256 val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Int256, false); - success = true; - } catch { - try vm.parseTomlIntArray(content, path) returns (int256[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Int256, true); - success = true; - } catch {} - } - } else if (ty == TypeKind.Bytes) { - try vm.parseTomlBytes(content, path) returns (bytes memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Bytes, false); - success = true; - } catch { - try vm.parseTomlBytesArray(content, path) returns (bytes[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.Bytes, true); - success = true; - } catch {} - } - } else if (ty == TypeKind.String) { - try vm.parseTomlString(content, path) returns (string memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.String, false); - success = true; - } catch { - try vm.parseTomlStringArray(content, path) returns (string[] memory val) { - _dataOf[chainId][key] = abi.encode(val); - _typeOf[chainId][key] = Type(TypeKind.String, true); - success = true; - } catch {} - } - } - - if (!success) { - revert UnableToParseVariable(key); - } - } - - // -- HELPER FUNCTIONS ----------------------------------------------------- - - /// @notice Enable or disable automatic writing to the TOML file on `set`. - /// Can only be enabled when scripting. - function writeUpdatesBackToFile(bool enabled) public { - if (enabled && !vm.isContext(VmSafe.ForgeContext.ScriptGroup)) { - revert WriteToFileInForbiddenCtxt(); - } - - _writeToFile = enabled; - } - - /// @notice Resolves a chain alias or a chain id string to its numerical chain id. - /// @param aliasOrId The string representing the chain alias (i.e. "mainnet") or a numerical ID (i.e. "1"). - /// @return The numerical chain ID. - /// @dev It first attempts to parse the input as a number. If that fails, it uses `vm.getChain` to resolve a named alias. - /// Reverts if the alias is not valid or not a number. - function resolveChainId(string memory aliasOrId) public view returns (uint256) { - try vm.parseUint(aliasOrId) returns (uint256 chainId) { - return chainId; - } catch { - try vm.getChain(aliasOrId) returns (VmSafe.Chain memory chainInfo) { - return chainInfo.chainId; - } catch { - revert InvalidChainKey(aliasOrId); - } - } - } - - /// @dev Retrieves the chain key/alias from the configuration based on the chain ID. - function _getChainKeyFromId(uint256 chainId) private view returns (string memory) { - for (uint256 i = 0; i < _chainKeys.length; i++) { - if (resolveChainId(_chainKeys[i]) == chainId) { - return _chainKeys[i]; - } - } - revert ChainNotInitialized(chainId); - } - - /// @dev Ensures type consistency when setting a value - prevents changing types unless uninitialized. - /// Updates type only when the previous type was `None`. - function _ensureTypeConsistency(uint256 chainId, string memory key, Type memory ty) private { - Type memory current = _typeOf[chainId][key]; - - if (current.kind == TypeKind.None) { - _typeOf[chainId][key] = ty; - } else { - current.assertEq(ty); - } - } - - /// @dev Wraps a string in double quotes for JSON compatibility. - function _quote(string memory s) private pure returns (string memory) { - return string.concat('"', s, '"'); - } - - /// @dev Writes a JSON-formatted value to a specific key in the TOML file. - /// @param chainId The chain id to write under. - /// @param ty The type category ('bool', 'address', 'uint', 'bytes32', 'string', or 'bytes'). - /// @param key The variable key name. - /// @param jsonValue The JSON-formatted value to write. - function _writeToToml(uint256 chainId, string memory ty, string memory key, string memory jsonValue) private { - string memory chainKey = _getChainKeyFromId(chainId); - string memory valueKey = string.concat("$.", chainKey, ".", ty, ".", key); - vm.writeToml(jsonValue, _filePath, valueKey); - } - - // -- GETTER FUNCTIONS ----------------------------------------------------- - - /// @dev Reads a variable for a given chain id and key, and returns it in a generic container. - /// The caller should use `LibVariable` to safely coerce the type. - /// Example: `uint256 myVar = config.get("my_key").toUint256();` - /// - /// @param chain_id The chain ID to read from. - /// @param key The key of the variable to retrieve. - /// @return `Variable` struct containing the type and the ABI-encoded value. - function get(uint256 chain_id, string memory key) public view returns (Variable memory) { - return Variable(_typeOf[chain_id][key], _dataOf[chain_id][key]); - } - - /// @dev Reads a variable for the current chain and a given key, and returns it in a generic container. - /// The caller should use `LibVariable` to safely coerce the type. - /// Example: `uint256 myVar = config.get("my_key").toUint256();` - /// - /// @param key The key of the variable to retrieve. - /// @return `Variable` struct containing the type and the ABI-encoded value. - function get(string memory key) public view returns (Variable memory) { - return get(vm.getChainId(), key); - } - - /// @notice Returns the numerical chain ids for all configured chains. - function getChainIds() public view returns (uint256[] memory) { - string[] memory keys = _chainKeys; - - uint256[] memory ids = new uint256[](keys.length); - for (uint256 i = 0; i < keys.length; i++) { - ids[i] = resolveChainId(keys[i]); - } - - return ids; - } - - /// @notice Reads the RPC URL for a specific chain id. - function getRpcUrl(uint256 chainId) public view returns (string memory) { - return _rpcOf[chainId]; - } - - /// @notice Reads the RPC URL for the current chain. - function getRpcUrl() public view returns (string memory) { - return _rpcOf[vm.getChainId()]; - } - - // -- SETTER FUNCTIONS (SINGLE VALUES) ------------------------------------- - - /// @notice Sets a boolean value for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, bool value) public { - Type memory ty = Type(TypeKind.Bool, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, vm.toString(value)); - } - - /// @notice Sets a boolean value for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, bool value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets an address value for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, address value) public { - Type memory ty = Type(TypeKind.Address, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, _quote(vm.toString(value))); - } - - /// @notice Sets an address value for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, address value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a bytes32 value for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, bytes32 value) public { - Type memory ty = Type(TypeKind.Bytes32, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, _quote(vm.toString(value))); - } - - /// @notice Sets a bytes32 value for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, bytes32 value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a uint256 value for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, uint256 value) public { - Type memory ty = Type(TypeKind.Uint256, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, vm.toString(value)); - } - - /// @notice Sets a uint256 value for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, uint256 value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets an int256 value for a given key and chain ID. - function set(uint256 chainId, string memory key, int256 value) public { - Type memory ty = Type(TypeKind.Int256, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, vm.toString(value)); - } - - /// @notice Sets an int256 value for a given key on the current chain. - function set(string memory key, int256 value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a string value for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, string memory value) public { - Type memory ty = Type(TypeKind.String, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, _quote(value)); - } - - /// @notice Sets a string value for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, string memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a bytes value for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, bytes memory value) public { - Type memory ty = Type(TypeKind.Bytes, false); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) _writeToToml(chainId, ty.kind.toTomlKey(), key, _quote(vm.toString(value))); - } - - /// @notice Sets a bytes value for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, bytes memory value) public { - set(vm.getChainId(), key, value); - } - - // -- SETTER FUNCTIONS (ARRAYS) -------------------------------------------- - - /// @notice Sets a boolean array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, bool[] memory value) public { - Type memory ty = Type(TypeKind.Bool, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, vm.toString(value[i])); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets a boolean array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, bool[] memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets an address array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, address[] memory value) public { - Type memory ty = Type(TypeKind.Address, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, _quote(vm.toString(value[i]))); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets an address array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, address[] memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a bytes32 array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, bytes32[] memory value) public { - Type memory ty = Type(TypeKind.Bytes32, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, _quote(vm.toString(value[i]))); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets a bytes32 array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, bytes32[] memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a uint256 array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, uint256[] memory value) public { - Type memory ty = Type(TypeKind.Uint256, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, vm.toString(value[i])); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets a uint256 array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, uint256[] memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a int256 array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, int256[] memory value) public { - Type memory ty = Type(TypeKind.Int256, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, vm.toString(value[i])); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets a int256 array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, int256[] memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a string array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, string[] memory value) public { - Type memory ty = Type(TypeKind.String, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, _quote(value[i])); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets a string array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, string[] memory value) public { - set(vm.getChainId(), key, value); - } - - /// @notice Sets a bytes array for a given key and chain ID. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(uint256 chainId, string memory key, bytes[] memory value) public { - Type memory ty = Type(TypeKind.Bytes, true); - _ensureTypeConsistency(chainId, key, ty); - _dataOf[chainId][key] = abi.encode(value); - if (_writeToFile) { - string memory json = "["; - for (uint256 i = 0; i < value.length; i++) { - json = string.concat(json, _quote(vm.toString(value[i]))); - if (i < value.length - 1) json = string.concat(json, ","); - } - json = string.concat(json, "]"); - _writeToToml(chainId, ty.kind.toTomlKey(), key, json); - } - } - - /// @notice Sets a bytes array for a given key on the current chain. - /// @dev Sets the cached value in storage and writes the change back to the TOML file if `autoWrite` is enabled. - function set(string memory key, bytes[] memory value) public { - set(vm.getChainId(), key, value); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdConstants.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdConstants.sol deleted file mode 100644 index 2047d2b33d..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdConstants.sol +++ /dev/null @@ -1,30 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -import {IMulticall3} from "./interfaces/IMulticall3.sol"; -import {Vm} from "./Vm.sol"; - -library StdConstants { - /// @dev Cheat code address. - /// Calculated as `address(uint160(uint256(keccak256("hevm cheat code"))))`. - Vm internal constant VM = Vm(0x7109709ECfa91a80626fF3989D68f67F5b1DD12D); - /// @dev console.sol and console2.sol work by executing a staticcall to this address. - /// Calculated as `address(uint160(uint88(bytes11("console.log"))))`. - address internal constant CONSOLE = 0x000000000000000000636F6e736F6c652e6c6f67; - /// @dev Used when deploying with create2. - /// Taken from https://github.com/Arachnid/deterministic-deployment-proxy. - address internal constant CREATE2_FACTORY = 0x4e59b44847b379578588920cA78FbF26c0B4956C; - /// @dev The default address for tx.origin and msg.sender. - /// Calculated as `address(uint160(uint256(keccak256("foundry default caller"))))`. - address internal constant DEFAULT_SENDER = 0x1804c8AB1F12E6bbf3894d4083f33e07309d1f38; - /// @dev The address of the first contract `CREATE`d by a running test contract. - /// When running tests, each test contract is `CREATE`d by `DEFAULT_SENDER` with nonce 1. - /// Calculated as `VM.computeCreateAddress(VM.computeCreateAddress(DEFAULT_SENDER, 1), 1)`. - address internal constant DEFAULT_TEST_CONTRACT = 0x5615dEB798BB3E4dFa0139dFa1b3D433Cc23b72f; - /// @dev Deterministic deployment address of the Multicall3 contract. - /// Taken from https://www.multicall3.com. - IMulticall3 internal constant MULTICALL3_ADDRESS = IMulticall3(0xcA11bde05977b3631167028862bE2a173976CA11); - /// @dev The order of the secp256k1 curve. - uint256 internal constant SECP256K1_ORDER = - 115792089237316195423570985008687907852837564279074904382605163141518161494337; -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdError.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdError.sol deleted file mode 100644 index a302191faa..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdError.sol +++ /dev/null @@ -1,15 +0,0 @@ -// SPDX-License-Identifier: MIT -// Panics work for versions >=0.8.0, but we lowered the pragma to make this compatible with Test -pragma solidity >=0.6.2 <0.9.0; - -library stdError { - bytes public constant assertionError = abi.encodeWithSignature("Panic(uint256)", 0x01); - bytes public constant arithmeticError = abi.encodeWithSignature("Panic(uint256)", 0x11); - bytes public constant divisionError = abi.encodeWithSignature("Panic(uint256)", 0x12); - bytes public constant enumConversionError = abi.encodeWithSignature("Panic(uint256)", 0x21); - bytes public constant encodeStorageError = abi.encodeWithSignature("Panic(uint256)", 0x22); - bytes public constant popError = abi.encodeWithSignature("Panic(uint256)", 0x31); - bytes public constant indexOOBError = abi.encodeWithSignature("Panic(uint256)", 0x32); - bytes public constant memOverflowError = abi.encodeWithSignature("Panic(uint256)", 0x41); - bytes public constant zeroVarError = abi.encodeWithSignature("Panic(uint256)", 0x51); -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdInvariant.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdInvariant.sol deleted file mode 100644 index 056db98fcf..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdInvariant.sol +++ /dev/null @@ -1,122 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -abstract contract StdInvariant { - struct FuzzSelector { - address addr; - bytes4[] selectors; - } - - struct FuzzArtifactSelector { - string artifact; - bytes4[] selectors; - } - - struct FuzzInterface { - address addr; - string[] artifacts; - } - - address[] private _excludedContracts; - address[] private _excludedSenders; - address[] private _targetedContracts; - address[] private _targetedSenders; - - string[] private _excludedArtifacts; - string[] private _targetedArtifacts; - - FuzzArtifactSelector[] private _targetedArtifactSelectors; - - FuzzSelector[] private _excludedSelectors; - FuzzSelector[] private _targetedSelectors; - - FuzzInterface[] private _targetedInterfaces; - - // Functions for users: - // These are intended to be called in tests. - - function excludeContract(address newExcludedContract_) internal { - _excludedContracts.push(newExcludedContract_); - } - - function excludeSelector(FuzzSelector memory newExcludedSelector_) internal { - _excludedSelectors.push(newExcludedSelector_); - } - - function excludeSender(address newExcludedSender_) internal { - _excludedSenders.push(newExcludedSender_); - } - - function excludeArtifact(string memory newExcludedArtifact_) internal { - _excludedArtifacts.push(newExcludedArtifact_); - } - - function targetArtifact(string memory newTargetedArtifact_) internal { - _targetedArtifacts.push(newTargetedArtifact_); - } - - function targetArtifactSelector(FuzzArtifactSelector memory newTargetedArtifactSelector_) internal { - _targetedArtifactSelectors.push(newTargetedArtifactSelector_); - } - - function targetContract(address newTargetedContract_) internal { - _targetedContracts.push(newTargetedContract_); - } - - function targetSelector(FuzzSelector memory newTargetedSelector_) internal { - _targetedSelectors.push(newTargetedSelector_); - } - - function targetSender(address newTargetedSender_) internal { - _targetedSenders.push(newTargetedSender_); - } - - function targetInterface(FuzzInterface memory newTargetedInterface_) internal { - _targetedInterfaces.push(newTargetedInterface_); - } - - // Functions for forge: - // These are called by forge to run invariant tests and don't need to be called in tests. - - function excludeArtifacts() public view returns (string[] memory excludedArtifacts_) { - excludedArtifacts_ = _excludedArtifacts; - } - - function excludeContracts() public view returns (address[] memory excludedContracts_) { - excludedContracts_ = _excludedContracts; - } - - function excludeSelectors() public view returns (FuzzSelector[] memory excludedSelectors_) { - excludedSelectors_ = _excludedSelectors; - } - - function excludeSenders() public view returns (address[] memory excludedSenders_) { - excludedSenders_ = _excludedSenders; - } - - function targetArtifacts() public view returns (string[] memory targetedArtifacts_) { - targetedArtifacts_ = _targetedArtifacts; - } - - function targetArtifactSelectors() public view returns (FuzzArtifactSelector[] memory targetedArtifactSelectors_) { - targetedArtifactSelectors_ = _targetedArtifactSelectors; - } - - function targetContracts() public view returns (address[] memory targetedContracts_) { - targetedContracts_ = _targetedContracts; - } - - function targetSelectors() public view returns (FuzzSelector[] memory targetedSelectors_) { - targetedSelectors_ = _targetedSelectors; - } - - function targetSenders() public view returns (address[] memory targetedSenders_) { - targetedSenders_ = _targetedSenders; - } - - function targetInterfaces() public view returns (FuzzInterface[] memory targetedInterfaces_) { - targetedInterfaces_ = _targetedInterfaces; - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdJson.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdJson.sol deleted file mode 100644 index 2a033c03a7..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdJson.sol +++ /dev/null @@ -1,283 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.0 <0.9.0; - -pragma experimental ABIEncoderV2; - -import {VmSafe} from "./Vm.sol"; - -// Helpers for parsing and writing JSON files -// To parse: -// ``` -// using stdJson for string; -// string memory json = vm.readFile(""); -// json.readUint(""); -// ``` -// To write: -// ``` -// using stdJson for string; -// string memory json = "json"; -// json.serialize("a", uint256(123)); -// string memory semiFinal = json.serialize("b", string("test")); -// string memory finalJson = json.serialize("c", semiFinal); -// finalJson.write(""); -// ``` - -library stdJson { - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - function keyExists(string memory json, string memory key) internal view returns (bool) { - return vm.keyExistsJson(json, key); - } - - function parseRaw(string memory json, string memory key) internal pure returns (bytes memory) { - return vm.parseJson(json, key); - } - - function readUint(string memory json, string memory key) internal pure returns (uint256) { - return vm.parseJsonUint(json, key); - } - - function readUintArray(string memory json, string memory key) internal pure returns (uint256[] memory) { - return vm.parseJsonUintArray(json, key); - } - - function readInt(string memory json, string memory key) internal pure returns (int256) { - return vm.parseJsonInt(json, key); - } - - function readIntArray(string memory json, string memory key) internal pure returns (int256[] memory) { - return vm.parseJsonIntArray(json, key); - } - - function readBytes32(string memory json, string memory key) internal pure returns (bytes32) { - return vm.parseJsonBytes32(json, key); - } - - function readBytes32Array(string memory json, string memory key) internal pure returns (bytes32[] memory) { - return vm.parseJsonBytes32Array(json, key); - } - - function readString(string memory json, string memory key) internal pure returns (string memory) { - return vm.parseJsonString(json, key); - } - - function readStringArray(string memory json, string memory key) internal pure returns (string[] memory) { - return vm.parseJsonStringArray(json, key); - } - - function readAddress(string memory json, string memory key) internal pure returns (address) { - return vm.parseJsonAddress(json, key); - } - - function readAddressArray(string memory json, string memory key) internal pure returns (address[] memory) { - return vm.parseJsonAddressArray(json, key); - } - - function readBool(string memory json, string memory key) internal pure returns (bool) { - return vm.parseJsonBool(json, key); - } - - function readBoolArray(string memory json, string memory key) internal pure returns (bool[] memory) { - return vm.parseJsonBoolArray(json, key); - } - - function readBytes(string memory json, string memory key) internal pure returns (bytes memory) { - return vm.parseJsonBytes(json, key); - } - - function readBytesArray(string memory json, string memory key) internal pure returns (bytes[] memory) { - return vm.parseJsonBytesArray(json, key); - } - - function readUintOr(string memory json, string memory key, uint256 defaultValue) internal view returns (uint256) { - return keyExists(json, key) ? readUint(json, key) : defaultValue; - } - - function readUintArrayOr(string memory json, string memory key, uint256[] memory defaultValue) - internal - view - returns (uint256[] memory) - { - return keyExists(json, key) ? readUintArray(json, key) : defaultValue; - } - - function readIntOr(string memory json, string memory key, int256 defaultValue) internal view returns (int256) { - return keyExists(json, key) ? readInt(json, key) : defaultValue; - } - - function readIntArrayOr(string memory json, string memory key, int256[] memory defaultValue) - internal - view - returns (int256[] memory) - { - return keyExists(json, key) ? readIntArray(json, key) : defaultValue; - } - - function readBytes32Or(string memory json, string memory key, bytes32 defaultValue) - internal - view - returns (bytes32) - { - return keyExists(json, key) ? readBytes32(json, key) : defaultValue; - } - - function readBytes32ArrayOr(string memory json, string memory key, bytes32[] memory defaultValue) - internal - view - returns (bytes32[] memory) - { - return keyExists(json, key) ? readBytes32Array(json, key) : defaultValue; - } - - function readStringOr(string memory json, string memory key, string memory defaultValue) - internal - view - returns (string memory) - { - return keyExists(json, key) ? readString(json, key) : defaultValue; - } - - function readStringArrayOr(string memory json, string memory key, string[] memory defaultValue) - internal - view - returns (string[] memory) - { - return keyExists(json, key) ? readStringArray(json, key) : defaultValue; - } - - function readAddressOr(string memory json, string memory key, address defaultValue) - internal - view - returns (address) - { - return keyExists(json, key) ? readAddress(json, key) : defaultValue; - } - - function readAddressArrayOr(string memory json, string memory key, address[] memory defaultValue) - internal - view - returns (address[] memory) - { - return keyExists(json, key) ? readAddressArray(json, key) : defaultValue; - } - - function readBoolOr(string memory json, string memory key, bool defaultValue) internal view returns (bool) { - return keyExists(json, key) ? readBool(json, key) : defaultValue; - } - - function readBoolArrayOr(string memory json, string memory key, bool[] memory defaultValue) - internal - view - returns (bool[] memory) - { - return keyExists(json, key) ? readBoolArray(json, key) : defaultValue; - } - - function readBytesOr(string memory json, string memory key, bytes memory defaultValue) - internal - view - returns (bytes memory) - { - return keyExists(json, key) ? readBytes(json, key) : defaultValue; - } - - function readBytesArrayOr(string memory json, string memory key, bytes[] memory defaultValue) - internal - view - returns (bytes[] memory) - { - return keyExists(json, key) ? readBytesArray(json, key) : defaultValue; - } - - function serialize(string memory jsonKey, string memory rootObject) internal returns (string memory) { - return vm.serializeJson(jsonKey, rootObject); - } - - function serialize(string memory jsonKey, string memory key, bool value) internal returns (string memory) { - return vm.serializeBool(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bool[] memory value) - internal - returns (string memory) - { - return vm.serializeBool(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, uint256 value) internal returns (string memory) { - return vm.serializeUint(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, uint256[] memory value) - internal - returns (string memory) - { - return vm.serializeUint(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, int256 value) internal returns (string memory) { - return vm.serializeInt(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, int256[] memory value) - internal - returns (string memory) - { - return vm.serializeInt(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, address value) internal returns (string memory) { - return vm.serializeAddress(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, address[] memory value) - internal - returns (string memory) - { - return vm.serializeAddress(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes32 value) internal returns (string memory) { - return vm.serializeBytes32(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes32[] memory value) - internal - returns (string memory) - { - return vm.serializeBytes32(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes memory value) internal returns (string memory) { - return vm.serializeBytes(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes[] memory value) - internal - returns (string memory) - { - return vm.serializeBytes(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, string memory value) - internal - returns (string memory) - { - return vm.serializeString(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, string[] memory value) - internal - returns (string memory) - { - return vm.serializeString(jsonKey, key, value); - } - - function write(string memory jsonKey, string memory path) internal { - vm.writeJson(jsonKey, path); - } - - function write(string memory jsonKey, string memory path, string memory valueKey) internal { - vm.writeJson(jsonKey, path, valueKey); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdMath.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdMath.sol deleted file mode 100644 index 459523bdac..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdMath.sol +++ /dev/null @@ -1,43 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -library stdMath { - int256 private constant INT256_MIN = -57896044618658097711785492504343953926634992332820282019728792003956564819968; - - function abs(int256 a) internal pure returns (uint256) { - // Required or it will fail when `a = type(int256).min` - if (a == INT256_MIN) { - return 57896044618658097711785492504343953926634992332820282019728792003956564819968; - } - - return uint256(a > 0 ? a : -a); - } - - function delta(uint256 a, uint256 b) internal pure returns (uint256) { - return a > b ? a - b : b - a; - } - - function delta(int256 a, int256 b) internal pure returns (uint256) { - // a and b are of the same sign - // this works thanks to two's complement, the left-most bit is the sign bit - if ((a ^ b) > -1) { - return delta(abs(a), abs(b)); - } - - // a and b are of opposite signs - return abs(a) + abs(b); - } - - function percentDelta(uint256 a, uint256 b) internal pure returns (uint256) { - uint256 absDelta = delta(a, b); - - return absDelta * 1e18 / b; - } - - function percentDelta(int256 a, int256 b) internal pure returns (uint256) { - uint256 absDelta = delta(a, b); - uint256 absB = abs(b); - - return absDelta * 1e18 / absB; - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdStorage.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdStorage.sol deleted file mode 100644 index 1627af7534..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdStorage.sol +++ /dev/null @@ -1,473 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -import {Vm} from "./Vm.sol"; - -struct FindData { - uint256 slot; - uint256 offsetLeft; - uint256 offsetRight; - bool found; -} - -struct StdStorage { - mapping(address => mapping(bytes4 => mapping(bytes32 => FindData))) finds; - bytes32[] _keys; - bytes4 _sig; - uint256 _depth; - address _target; - bytes32 _set; - bool _enable_packed_slots; - bytes _calldata; -} - -library stdStorageSafe { - event SlotFound(address who, bytes4 fsig, bytes32 keysHash, uint256 slot); - event WARNING_UninitedSlot(address who, uint256 slot); - - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - uint256 constant UINT256_MAX = 115792089237316195423570985008687907853269984665640564039457584007913129639935; - - function sigs(string memory sigStr) internal pure returns (bytes4) { - return bytes4(keccak256(bytes(sigStr))); - } - - function getCallParams(StdStorage storage self) internal view returns (bytes memory) { - if (self._calldata.length == 0) { - return flatten(self._keys); - } else { - return self._calldata; - } - } - - // Calls target contract with configured parameters - function callTarget(StdStorage storage self) internal view returns (bool, bytes32) { - bytes memory cd = abi.encodePacked(self._sig, getCallParams(self)); - (bool success, bytes memory rdat) = self._target.staticcall(cd); - bytes32 result = bytesToBytes32(rdat, 32 * self._depth); - - return (success, result); - } - - // Tries mutating slot value to determine if the targeted value is stored in it. - // If current value is 0, then we are setting slot value to type(uint256).max - // Otherwise, we set it to 0. That way, return value should always be affected. - function checkSlotMutatesCall(StdStorage storage self, bytes32 slot) internal returns (bool) { - bytes32 prevSlotValue = vm.load(self._target, slot); - (bool success, bytes32 prevReturnValue) = callTarget(self); - - bytes32 testVal = prevReturnValue == bytes32(0) ? bytes32(UINT256_MAX) : bytes32(0); - vm.store(self._target, slot, testVal); - - (, bytes32 newReturnValue) = callTarget(self); - - vm.store(self._target, slot, prevSlotValue); - - return (success && (prevReturnValue != newReturnValue)); - } - - // Tries setting one of the bits in slot to 1 until return value changes. - // Index of resulted bit is an offset packed slot has from left/right side - function findOffset(StdStorage storage self, bytes32 slot, bool left) internal returns (bool, uint256) { - for (uint256 offset = 0; offset < 256; offset++) { - uint256 valueToPut = left ? (1 << (255 - offset)) : (1 << offset); - vm.store(self._target, slot, bytes32(valueToPut)); - - (bool success, bytes32 data) = callTarget(self); - - if (success && (uint256(data) > 0)) { - return (true, offset); - } - } - return (false, 0); - } - - function findOffsets(StdStorage storage self, bytes32 slot) internal returns (bool, uint256, uint256) { - bytes32 prevSlotValue = vm.load(self._target, slot); - - (bool foundLeft, uint256 offsetLeft) = findOffset(self, slot, true); - (bool foundRight, uint256 offsetRight) = findOffset(self, slot, false); - - // `findOffset` may mutate slot value, so we are setting it to initial value - vm.store(self._target, slot, prevSlotValue); - return (foundLeft && foundRight, offsetLeft, offsetRight); - } - - function find(StdStorage storage self) internal returns (FindData storage) { - return find(self, true); - } - - /// @notice find an arbitrary storage slot given a function sig, input data, address of the contract and a value to check against - // slot complexity: - // if flat, will be bytes32(uint256(uint)); - // if map, will be keccak256(abi.encode(key, uint(slot))); - // if deep map, will be keccak256(abi.encode(key1, keccak256(abi.encode(key0, uint(slot))))); - // if map struct, will be bytes32(uint256(keccak256(abi.encode(key1, keccak256(abi.encode(key0, uint(slot)))))) + structFieldDepth); - function find(StdStorage storage self, bool _clear) internal returns (FindData storage) { - address who = self._target; - bytes4 fsig = self._sig; - uint256 field_depth = self._depth; - bytes memory params = getCallParams(self); - - // calldata to test against - if (self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))].found) { - if (_clear) { - clear(self); - } - return self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))]; - } - vm.record(); - (, bytes32 callResult) = callTarget(self); - (bytes32[] memory reads,) = vm.accesses(address(who)); - - if (reads.length == 0) { - revert("stdStorage find(StdStorage): No storage use detected for target."); - } else { - for (uint256 i = reads.length; --i >= 0;) { - bytes32 prev = vm.load(who, reads[i]); - if (prev == bytes32(0)) { - emit WARNING_UninitedSlot(who, uint256(reads[i])); - } - - if (!checkSlotMutatesCall(self, reads[i])) { - continue; - } - - (uint256 offsetLeft, uint256 offsetRight) = (0, 0); - - if (self._enable_packed_slots) { - bool found; - (found, offsetLeft, offsetRight) = findOffsets(self, reads[i]); - if (!found) { - continue; - } - } - - // Check that value between found offsets is equal to the current call result - uint256 curVal = (uint256(prev) & getMaskByOffsets(offsetLeft, offsetRight)) >> offsetRight; - - if (uint256(callResult) != curVal) { - continue; - } - - emit SlotFound(who, fsig, keccak256(abi.encodePacked(params, field_depth)), uint256(reads[i])); - self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))] = - FindData(uint256(reads[i]), offsetLeft, offsetRight, true); - break; - } - } - - require( - self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))].found, - "stdStorage find(StdStorage): Slot(s) not found." - ); - - if (_clear) { - clear(self); - } - return self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))]; - } - - function target(StdStorage storage self, address _target) internal returns (StdStorage storage) { - self._target = _target; - return self; - } - - function sig(StdStorage storage self, bytes4 _sig) internal returns (StdStorage storage) { - self._sig = _sig; - return self; - } - - function sig(StdStorage storage self, string memory _sig) internal returns (StdStorage storage) { - self._sig = sigs(_sig); - return self; - } - - function with_calldata(StdStorage storage self, bytes memory _calldata) internal returns (StdStorage storage) { - self._calldata = _calldata; - return self; - } - - function with_key(StdStorage storage self, address who) internal returns (StdStorage storage) { - self._keys.push(bytes32(uint256(uint160(who)))); - return self; - } - - function with_key(StdStorage storage self, uint256 amt) internal returns (StdStorage storage) { - self._keys.push(bytes32(amt)); - return self; - } - - function with_key(StdStorage storage self, bytes32 key) internal returns (StdStorage storage) { - self._keys.push(key); - return self; - } - - function enable_packed_slots(StdStorage storage self) internal returns (StdStorage storage) { - self._enable_packed_slots = true; - return self; - } - - function depth(StdStorage storage self, uint256 _depth) internal returns (StdStorage storage) { - self._depth = _depth; - return self; - } - - function read(StdStorage storage self) private returns (bytes memory) { - FindData storage data = find(self, false); - uint256 mask = getMaskByOffsets(data.offsetLeft, data.offsetRight); - uint256 value = (uint256(vm.load(self._target, bytes32(data.slot))) & mask) >> data.offsetRight; - clear(self); - return abi.encode(value); - } - - function read_bytes32(StdStorage storage self) internal returns (bytes32) { - return abi.decode(read(self), (bytes32)); - } - - function read_bool(StdStorage storage self) internal returns (bool) { - int256 v = read_int(self); - if (v == 0) return false; - if (v == 1) return true; - revert("stdStorage read_bool(StdStorage): Cannot decode. Make sure you are reading a bool."); - } - - function read_address(StdStorage storage self) internal returns (address) { - return abi.decode(read(self), (address)); - } - - function read_uint(StdStorage storage self) internal returns (uint256) { - return abi.decode(read(self), (uint256)); - } - - function read_int(StdStorage storage self) internal returns (int256) { - return abi.decode(read(self), (int256)); - } - - function parent(StdStorage storage self) internal returns (uint256, bytes32) { - address who = self._target; - uint256 field_depth = self._depth; - vm.startMappingRecording(); - uint256 child = find(self, true).slot - field_depth; - (bool found, bytes32 key, bytes32 parent_slot) = vm.getMappingKeyAndParentOf(who, bytes32(child)); - if (!found) { - revert( - "stdStorage read_bool(StdStorage): Cannot find parent. Make sure you give a slot and startMappingRecording() has been called." - ); - } - return (uint256(parent_slot), key); - } - - function root(StdStorage storage self) internal returns (uint256) { - address who = self._target; - uint256 field_depth = self._depth; - vm.startMappingRecording(); - uint256 child = find(self, true).slot - field_depth; - bool found; - bytes32 root_slot; - bytes32 parent_slot; - (found,, parent_slot) = vm.getMappingKeyAndParentOf(who, bytes32(child)); - if (!found) { - revert( - "stdStorage read_bool(StdStorage): Cannot find parent. Make sure you give a slot and startMappingRecording() has been called." - ); - } - while (found) { - root_slot = parent_slot; - (found,, parent_slot) = vm.getMappingKeyAndParentOf(who, bytes32(root_slot)); - } - return uint256(root_slot); - } - - function bytesToBytes32(bytes memory b, uint256 offset) private pure returns (bytes32) { - bytes32 out; - - uint256 max = b.length > 32 ? 32 : b.length; - for (uint256 i = 0; i < max; i++) { - out |= bytes32(b[offset + i] & 0xFF) >> (i * 8); - } - return out; - } - - function flatten(bytes32[] memory b) private pure returns (bytes memory) { - bytes memory result = new bytes(b.length * 32); - for (uint256 i = 0; i < b.length; i++) { - bytes32 k = b[i]; - /// @solidity memory-safe-assembly - assembly { - mstore(add(result, add(32, mul(32, i))), k) - } - } - - return result; - } - - function clear(StdStorage storage self) internal { - delete self._target; - delete self._sig; - delete self._keys; - delete self._depth; - delete self._enable_packed_slots; - delete self._calldata; - } - - // Returns mask which contains non-zero bits for values between `offsetLeft` and `offsetRight` - // (slotValue & mask) >> offsetRight will be the value of the given packed variable - function getMaskByOffsets(uint256 offsetLeft, uint256 offsetRight) internal pure returns (uint256 mask) { - // mask = ((1 << (256 - (offsetRight + offsetLeft))) - 1) << offsetRight; - // using assembly because (1 << 256) causes overflow - assembly { - mask := shl(offsetRight, sub(shl(sub(256, add(offsetRight, offsetLeft)), 1), 1)) - } - } - - // Returns slot value with updated packed variable. - function getUpdatedSlotValue(bytes32 curValue, uint256 varValue, uint256 offsetLeft, uint256 offsetRight) - internal - pure - returns (bytes32 newValue) - { - return bytes32((uint256(curValue) & ~getMaskByOffsets(offsetLeft, offsetRight)) | (varValue << offsetRight)); - } -} - -library stdStorage { - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - - function sigs(string memory sigStr) internal pure returns (bytes4) { - return stdStorageSafe.sigs(sigStr); - } - - function find(StdStorage storage self) internal returns (uint256) { - return find(self, true); - } - - function find(StdStorage storage self, bool _clear) internal returns (uint256) { - return stdStorageSafe.find(self, _clear).slot; - } - - function target(StdStorage storage self, address _target) internal returns (StdStorage storage) { - return stdStorageSafe.target(self, _target); - } - - function sig(StdStorage storage self, bytes4 _sig) internal returns (StdStorage storage) { - return stdStorageSafe.sig(self, _sig); - } - - function sig(StdStorage storage self, string memory _sig) internal returns (StdStorage storage) { - return stdStorageSafe.sig(self, _sig); - } - - function with_key(StdStorage storage self, address who) internal returns (StdStorage storage) { - return stdStorageSafe.with_key(self, who); - } - - function with_key(StdStorage storage self, uint256 amt) internal returns (StdStorage storage) { - return stdStorageSafe.with_key(self, amt); - } - - function with_key(StdStorage storage self, bytes32 key) internal returns (StdStorage storage) { - return stdStorageSafe.with_key(self, key); - } - - function with_calldata(StdStorage storage self, bytes memory _calldata) internal returns (StdStorage storage) { - return stdStorageSafe.with_calldata(self, _calldata); - } - - function enable_packed_slots(StdStorage storage self) internal returns (StdStorage storage) { - return stdStorageSafe.enable_packed_slots(self); - } - - function depth(StdStorage storage self, uint256 _depth) internal returns (StdStorage storage) { - return stdStorageSafe.depth(self, _depth); - } - - function clear(StdStorage storage self) internal { - stdStorageSafe.clear(self); - } - - function checked_write(StdStorage storage self, address who) internal { - checked_write(self, bytes32(uint256(uint160(who)))); - } - - function checked_write(StdStorage storage self, uint256 amt) internal { - checked_write(self, bytes32(amt)); - } - - function checked_write_int(StdStorage storage self, int256 val) internal { - checked_write(self, bytes32(uint256(val))); - } - - function checked_write(StdStorage storage self, bool write) internal { - bytes32 t; - /// @solidity memory-safe-assembly - assembly { - t := write - } - checked_write(self, t); - } - - function checked_write(StdStorage storage self, bytes32 set) internal { - address who = self._target; - bytes4 fsig = self._sig; - uint256 field_depth = self._depth; - bytes memory params = stdStorageSafe.getCallParams(self); - - if (!self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))].found) { - find(self, false); - } - FindData storage data = self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))]; - if ((data.offsetLeft + data.offsetRight) > 0) { - uint256 maxVal = 2 ** (256 - (data.offsetLeft + data.offsetRight)); - require( - uint256(set) < maxVal, - string( - abi.encodePacked( - "stdStorage find(StdStorage): Packed slot. We can't fit value greater than ", - vm.toString(maxVal) - ) - ) - ); - } - bytes32 curVal = vm.load(who, bytes32(data.slot)); - bytes32 valToSet = stdStorageSafe.getUpdatedSlotValue(curVal, uint256(set), data.offsetLeft, data.offsetRight); - - vm.store(who, bytes32(data.slot), valToSet); - - (bool success, bytes32 callResult) = stdStorageSafe.callTarget(self); - - if (!success || callResult != set) { - vm.store(who, bytes32(data.slot), curVal); - revert("stdStorage find(StdStorage): Failed to write value."); - } - clear(self); - } - - function read_bytes32(StdStorage storage self) internal returns (bytes32) { - return stdStorageSafe.read_bytes32(self); - } - - function read_bool(StdStorage storage self) internal returns (bool) { - return stdStorageSafe.read_bool(self); - } - - function read_address(StdStorage storage self) internal returns (address) { - return stdStorageSafe.read_address(self); - } - - function read_uint(StdStorage storage self) internal returns (uint256) { - return stdStorageSafe.read_uint(self); - } - - function read_int(StdStorage storage self) internal returns (int256) { - return stdStorageSafe.read_int(self); - } - - function parent(StdStorage storage self) internal returns (uint256, bytes32) { - return stdStorageSafe.parent(self); - } - - function root(StdStorage storage self) internal returns (uint256) { - return stdStorageSafe.root(self); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdStyle.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdStyle.sol deleted file mode 100644 index d371e0c60a..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdStyle.sol +++ /dev/null @@ -1,333 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.4.22 <0.9.0; - -import {VmSafe} from "./Vm.sol"; - -library StdStyle { - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - string constant RED = "\u001b[91m"; - string constant GREEN = "\u001b[92m"; - string constant YELLOW = "\u001b[93m"; - string constant BLUE = "\u001b[94m"; - string constant MAGENTA = "\u001b[95m"; - string constant CYAN = "\u001b[96m"; - string constant BOLD = "\u001b[1m"; - string constant DIM = "\u001b[2m"; - string constant ITALIC = "\u001b[3m"; - string constant UNDERLINE = "\u001b[4m"; - string constant INVERSE = "\u001b[7m"; - string constant RESET = "\u001b[0m"; - - function styleConcat(string memory style, string memory self) private pure returns (string memory) { - return string(abi.encodePacked(style, self, RESET)); - } - - function red(string memory self) internal pure returns (string memory) { - return styleConcat(RED, self); - } - - function red(uint256 self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function red(int256 self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function red(address self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function red(bool self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function redBytes(bytes memory self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function redBytes32(bytes32 self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function green(string memory self) internal pure returns (string memory) { - return styleConcat(GREEN, self); - } - - function green(uint256 self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function green(int256 self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function green(address self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function green(bool self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function greenBytes(bytes memory self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function greenBytes32(bytes32 self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function yellow(string memory self) internal pure returns (string memory) { - return styleConcat(YELLOW, self); - } - - function yellow(uint256 self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellow(int256 self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellow(address self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellow(bool self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellowBytes(bytes memory self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellowBytes32(bytes32 self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function blue(string memory self) internal pure returns (string memory) { - return styleConcat(BLUE, self); - } - - function blue(uint256 self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blue(int256 self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blue(address self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blue(bool self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blueBytes(bytes memory self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blueBytes32(bytes32 self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function magenta(string memory self) internal pure returns (string memory) { - return styleConcat(MAGENTA, self); - } - - function magenta(uint256 self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magenta(int256 self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magenta(address self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magenta(bool self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magentaBytes(bytes memory self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magentaBytes32(bytes32 self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function cyan(string memory self) internal pure returns (string memory) { - return styleConcat(CYAN, self); - } - - function cyan(uint256 self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyan(int256 self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyan(address self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyan(bool self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyanBytes(bytes memory self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyanBytes32(bytes32 self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function bold(string memory self) internal pure returns (string memory) { - return styleConcat(BOLD, self); - } - - function bold(uint256 self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function bold(int256 self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function bold(address self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function bold(bool self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function boldBytes(bytes memory self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function boldBytes32(bytes32 self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function dim(string memory self) internal pure returns (string memory) { - return styleConcat(DIM, self); - } - - function dim(uint256 self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dim(int256 self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dim(address self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dim(bool self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dimBytes(bytes memory self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dimBytes32(bytes32 self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function italic(string memory self) internal pure returns (string memory) { - return styleConcat(ITALIC, self); - } - - function italic(uint256 self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italic(int256 self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italic(address self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italic(bool self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italicBytes(bytes memory self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italicBytes32(bytes32 self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function underline(string memory self) internal pure returns (string memory) { - return styleConcat(UNDERLINE, self); - } - - function underline(uint256 self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underline(int256 self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underline(address self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underline(bool self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underlineBytes(bytes memory self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underlineBytes32(bytes32 self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function inverse(string memory self) internal pure returns (string memory) { - return styleConcat(INVERSE, self); - } - - function inverse(uint256 self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverse(int256 self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverse(address self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverse(bool self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverseBytes(bytes memory self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverseBytes32(bytes32 self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdToml.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdToml.sol deleted file mode 100644 index 7ad3be2f97..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdToml.sol +++ /dev/null @@ -1,283 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.0 <0.9.0; - -pragma experimental ABIEncoderV2; - -import {VmSafe} from "./Vm.sol"; - -// Helpers for parsing and writing TOML files -// To parse: -// ``` -// using stdToml for string; -// string memory toml = vm.readFile(""); -// toml.readUint(""); -// ``` -// To write: -// ``` -// using stdToml for string; -// string memory json = "json"; -// json.serialize("a", uint256(123)); -// string memory semiFinal = json.serialize("b", string("test")); -// string memory finalJson = json.serialize("c", semiFinal); -// finalJson.write(""); -// ``` - -library stdToml { - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - function keyExists(string memory toml, string memory key) internal view returns (bool) { - return vm.keyExistsToml(toml, key); - } - - function parseRaw(string memory toml, string memory key) internal pure returns (bytes memory) { - return vm.parseToml(toml, key); - } - - function readUint(string memory toml, string memory key) internal pure returns (uint256) { - return vm.parseTomlUint(toml, key); - } - - function readUintArray(string memory toml, string memory key) internal pure returns (uint256[] memory) { - return vm.parseTomlUintArray(toml, key); - } - - function readInt(string memory toml, string memory key) internal pure returns (int256) { - return vm.parseTomlInt(toml, key); - } - - function readIntArray(string memory toml, string memory key) internal pure returns (int256[] memory) { - return vm.parseTomlIntArray(toml, key); - } - - function readBytes32(string memory toml, string memory key) internal pure returns (bytes32) { - return vm.parseTomlBytes32(toml, key); - } - - function readBytes32Array(string memory toml, string memory key) internal pure returns (bytes32[] memory) { - return vm.parseTomlBytes32Array(toml, key); - } - - function readString(string memory toml, string memory key) internal pure returns (string memory) { - return vm.parseTomlString(toml, key); - } - - function readStringArray(string memory toml, string memory key) internal pure returns (string[] memory) { - return vm.parseTomlStringArray(toml, key); - } - - function readAddress(string memory toml, string memory key) internal pure returns (address) { - return vm.parseTomlAddress(toml, key); - } - - function readAddressArray(string memory toml, string memory key) internal pure returns (address[] memory) { - return vm.parseTomlAddressArray(toml, key); - } - - function readBool(string memory toml, string memory key) internal pure returns (bool) { - return vm.parseTomlBool(toml, key); - } - - function readBoolArray(string memory toml, string memory key) internal pure returns (bool[] memory) { - return vm.parseTomlBoolArray(toml, key); - } - - function readBytes(string memory toml, string memory key) internal pure returns (bytes memory) { - return vm.parseTomlBytes(toml, key); - } - - function readBytesArray(string memory toml, string memory key) internal pure returns (bytes[] memory) { - return vm.parseTomlBytesArray(toml, key); - } - - function readUintOr(string memory toml, string memory key, uint256 defaultValue) internal view returns (uint256) { - return keyExists(toml, key) ? readUint(toml, key) : defaultValue; - } - - function readUintArrayOr(string memory toml, string memory key, uint256[] memory defaultValue) - internal - view - returns (uint256[] memory) - { - return keyExists(toml, key) ? readUintArray(toml, key) : defaultValue; - } - - function readIntOr(string memory toml, string memory key, int256 defaultValue) internal view returns (int256) { - return keyExists(toml, key) ? readInt(toml, key) : defaultValue; - } - - function readIntArrayOr(string memory toml, string memory key, int256[] memory defaultValue) - internal - view - returns (int256[] memory) - { - return keyExists(toml, key) ? readIntArray(toml, key) : defaultValue; - } - - function readBytes32Or(string memory toml, string memory key, bytes32 defaultValue) - internal - view - returns (bytes32) - { - return keyExists(toml, key) ? readBytes32(toml, key) : defaultValue; - } - - function readBytes32ArrayOr(string memory toml, string memory key, bytes32[] memory defaultValue) - internal - view - returns (bytes32[] memory) - { - return keyExists(toml, key) ? readBytes32Array(toml, key) : defaultValue; - } - - function readStringOr(string memory toml, string memory key, string memory defaultValue) - internal - view - returns (string memory) - { - return keyExists(toml, key) ? readString(toml, key) : defaultValue; - } - - function readStringArrayOr(string memory toml, string memory key, string[] memory defaultValue) - internal - view - returns (string[] memory) - { - return keyExists(toml, key) ? readStringArray(toml, key) : defaultValue; - } - - function readAddressOr(string memory toml, string memory key, address defaultValue) - internal - view - returns (address) - { - return keyExists(toml, key) ? readAddress(toml, key) : defaultValue; - } - - function readAddressArrayOr(string memory toml, string memory key, address[] memory defaultValue) - internal - view - returns (address[] memory) - { - return keyExists(toml, key) ? readAddressArray(toml, key) : defaultValue; - } - - function readBoolOr(string memory toml, string memory key, bool defaultValue) internal view returns (bool) { - return keyExists(toml, key) ? readBool(toml, key) : defaultValue; - } - - function readBoolArrayOr(string memory toml, string memory key, bool[] memory defaultValue) - internal - view - returns (bool[] memory) - { - return keyExists(toml, key) ? readBoolArray(toml, key) : defaultValue; - } - - function readBytesOr(string memory toml, string memory key, bytes memory defaultValue) - internal - view - returns (bytes memory) - { - return keyExists(toml, key) ? readBytes(toml, key) : defaultValue; - } - - function readBytesArrayOr(string memory toml, string memory key, bytes[] memory defaultValue) - internal - view - returns (bytes[] memory) - { - return keyExists(toml, key) ? readBytesArray(toml, key) : defaultValue; - } - - function serialize(string memory jsonKey, string memory rootObject) internal returns (string memory) { - return vm.serializeJson(jsonKey, rootObject); - } - - function serialize(string memory jsonKey, string memory key, bool value) internal returns (string memory) { - return vm.serializeBool(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bool[] memory value) - internal - returns (string memory) - { - return vm.serializeBool(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, uint256 value) internal returns (string memory) { - return vm.serializeUint(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, uint256[] memory value) - internal - returns (string memory) - { - return vm.serializeUint(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, int256 value) internal returns (string memory) { - return vm.serializeInt(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, int256[] memory value) - internal - returns (string memory) - { - return vm.serializeInt(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, address value) internal returns (string memory) { - return vm.serializeAddress(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, address[] memory value) - internal - returns (string memory) - { - return vm.serializeAddress(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes32 value) internal returns (string memory) { - return vm.serializeBytes32(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes32[] memory value) - internal - returns (string memory) - { - return vm.serializeBytes32(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes memory value) internal returns (string memory) { - return vm.serializeBytes(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes[] memory value) - internal - returns (string memory) - { - return vm.serializeBytes(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, string memory value) - internal - returns (string memory) - { - return vm.serializeString(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, string[] memory value) - internal - returns (string memory) - { - return vm.serializeString(jsonKey, key, value); - } - - function write(string memory jsonKey, string memory path) internal { - vm.writeToml(jsonKey, path); - } - - function write(string memory jsonKey, string memory path, string memory valueKey) internal { - vm.writeToml(jsonKey, path, valueKey); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/StdUtils.sol b/lib/signals-implicit-mode/lib/forge-std/src/StdUtils.sol deleted file mode 100644 index 9321df1430..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/StdUtils.sol +++ /dev/null @@ -1,208 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -import {IMulticall3} from "./interfaces/IMulticall3.sol"; -import {VmSafe} from "./Vm.sol"; - -abstract contract StdUtils { - /*////////////////////////////////////////////////////////////////////////// - CONSTANTS - //////////////////////////////////////////////////////////////////////////*/ - - IMulticall3 private constant multicall = IMulticall3(0xcA11bde05977b3631167028862bE2a173976CA11); - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - address private constant CONSOLE2_ADDRESS = 0x000000000000000000636F6e736F6c652e6c6f67; - uint256 private constant INT256_MIN_ABS = - 57896044618658097711785492504343953926634992332820282019728792003956564819968; - uint256 private constant SECP256K1_ORDER = - 115792089237316195423570985008687907852837564279074904382605163141518161494337; - uint256 private constant UINT256_MAX = - 115792089237316195423570985008687907853269984665640564039457584007913129639935; - - // Used by default when deploying with create2, https://github.com/Arachnid/deterministic-deployment-proxy. - address private constant CREATE2_FACTORY = 0x4e59b44847b379578588920cA78FbF26c0B4956C; - - /*////////////////////////////////////////////////////////////////////////// - INTERNAL FUNCTIONS - //////////////////////////////////////////////////////////////////////////*/ - - function _bound(uint256 x, uint256 min, uint256 max) internal pure virtual returns (uint256 result) { - require(min <= max, "StdUtils bound(uint256,uint256,uint256): Max is less than min."); - // If x is between min and max, return x directly. This is to ensure that dictionary values - // do not get shifted if the min is nonzero. More info: https://github.com/foundry-rs/forge-std/issues/188 - if (x >= min && x <= max) return x; - - uint256 size = max - min + 1; - - // If the value is 0, 1, 2, 3, wrap that to min, min+1, min+2, min+3. Similarly for the UINT256_MAX side. - // This helps ensure coverage of the min/max values. - if (x <= 3 && size > x) return min + x; - if (x >= UINT256_MAX - 3 && size > UINT256_MAX - x) return max - (UINT256_MAX - x); - - // Otherwise, wrap x into the range [min, max], i.e. the range is inclusive. - if (x > max) { - uint256 diff = x - max; - uint256 rem = diff % size; - if (rem == 0) return max; - result = min + rem - 1; - } else if (x < min) { - uint256 diff = min - x; - uint256 rem = diff % size; - if (rem == 0) return min; - result = max - rem + 1; - } - } - - function bound(uint256 x, uint256 min, uint256 max) internal pure virtual returns (uint256 result) { - result = _bound(x, min, max); - console2_log_StdUtils("Bound result", result); - } - - function _bound(int256 x, int256 min, int256 max) internal pure virtual returns (int256 result) { - require(min <= max, "StdUtils bound(int256,int256,int256): Max is less than min."); - - // Shifting all int256 values to uint256 to use _bound function. The range of two types are: - // int256 : -(2**255) ~ (2**255 - 1) - // uint256: 0 ~ (2**256 - 1) - // So, add 2**255, INT256_MIN_ABS to the integer values. - // - // If the given integer value is -2**255, we cannot use `-uint256(-x)` because of the overflow. - // So, use `~uint256(x) + 1` instead. - uint256 _x = x < 0 ? (INT256_MIN_ABS - ~uint256(x) - 1) : (uint256(x) + INT256_MIN_ABS); - uint256 _min = min < 0 ? (INT256_MIN_ABS - ~uint256(min) - 1) : (uint256(min) + INT256_MIN_ABS); - uint256 _max = max < 0 ? (INT256_MIN_ABS - ~uint256(max) - 1) : (uint256(max) + INT256_MIN_ABS); - - uint256 y = _bound(_x, _min, _max); - - // To move it back to int256 value, subtract INT256_MIN_ABS at here. - result = y < INT256_MIN_ABS ? int256(~(INT256_MIN_ABS - y) + 1) : int256(y - INT256_MIN_ABS); - } - - function bound(int256 x, int256 min, int256 max) internal pure virtual returns (int256 result) { - result = _bound(x, min, max); - console2_log_StdUtils("Bound result", vm.toString(result)); - } - - function boundPrivateKey(uint256 privateKey) internal pure virtual returns (uint256 result) { - result = _bound(privateKey, 1, SECP256K1_ORDER - 1); - } - - function bytesToUint(bytes memory b) internal pure virtual returns (uint256) { - require(b.length <= 32, "StdUtils bytesToUint(bytes): Bytes length exceeds 32."); - return abi.decode(abi.encodePacked(new bytes(32 - b.length), b), (uint256)); - } - - /// @dev Compute the address a contract will be deployed at for a given deployer address and nonce - function computeCreateAddress(address deployer, uint256 nonce) internal pure virtual returns (address) { - console2_log_StdUtils("computeCreateAddress is deprecated. Please use vm.computeCreateAddress instead."); - return vm.computeCreateAddress(deployer, nonce); - } - - function computeCreate2Address(bytes32 salt, bytes32 initcodeHash, address deployer) - internal - pure - virtual - returns (address) - { - console2_log_StdUtils("computeCreate2Address is deprecated. Please use vm.computeCreate2Address instead."); - return vm.computeCreate2Address(salt, initcodeHash, deployer); - } - - /// @dev returns the address of a contract created with CREATE2 using the default CREATE2 deployer - function computeCreate2Address(bytes32 salt, bytes32 initCodeHash) internal pure returns (address) { - console2_log_StdUtils("computeCreate2Address is deprecated. Please use vm.computeCreate2Address instead."); - return vm.computeCreate2Address(salt, initCodeHash); - } - - /// @dev returns the hash of the init code (creation code + no args) used in CREATE2 with no constructor arguments - /// @param creationCode the creation code of a contract C, as returned by type(C).creationCode - function hashInitCode(bytes memory creationCode) internal pure returns (bytes32) { - return hashInitCode(creationCode, ""); - } - - /// @dev returns the hash of the init code (creation code + ABI-encoded args) used in CREATE2 - /// @param creationCode the creation code of a contract C, as returned by type(C).creationCode - /// @param args the ABI-encoded arguments to the constructor of C - function hashInitCode(bytes memory creationCode, bytes memory args) internal pure returns (bytes32) { - return keccak256(abi.encodePacked(creationCode, args)); - } - - // Performs a single call with Multicall3 to query the ERC-20 token balances of the given addresses. - function getTokenBalances(address token, address[] memory addresses) - internal - virtual - returns (uint256[] memory balances) - { - uint256 tokenCodeSize; - assembly { - tokenCodeSize := extcodesize(token) - } - require(tokenCodeSize > 0, "StdUtils getTokenBalances(address,address[]): Token address is not a contract."); - - // ABI encode the aggregate call to Multicall3. - uint256 length = addresses.length; - IMulticall3.Call[] memory calls = new IMulticall3.Call[](length); - for (uint256 i = 0; i < length; ++i) { - // 0x70a08231 = bytes4("balanceOf(address)")) - calls[i] = IMulticall3.Call({target: token, callData: abi.encodeWithSelector(0x70a08231, (addresses[i]))}); - } - - // Make the aggregate call. - (, bytes[] memory returnData) = multicall.aggregate(calls); - - // ABI decode the return data and return the balances. - balances = new uint256[](length); - for (uint256 i = 0; i < length; ++i) { - balances[i] = abi.decode(returnData[i], (uint256)); - } - } - - /*////////////////////////////////////////////////////////////////////////// - PRIVATE FUNCTIONS - //////////////////////////////////////////////////////////////////////////*/ - - function addressFromLast20Bytes(bytes32 bytesValue) private pure returns (address) { - return address(uint160(uint256(bytesValue))); - } - - // This section is used to prevent the compilation of console, which shortens the compilation time when console is - // not used elsewhere. We also trick the compiler into letting us make the console log methods as `pure` to avoid - // any breaking changes to function signatures. - function _castLogPayloadViewToPure(function(bytes memory) internal view fnIn) - internal - pure - returns (function(bytes memory) internal pure fnOut) - { - assembly { - fnOut := fnIn - } - } - - function _sendLogPayload(bytes memory payload) internal pure { - _castLogPayloadViewToPure(_sendLogPayloadView)(payload); - } - - function _sendLogPayloadView(bytes memory payload) private view { - uint256 payloadLength = payload.length; - address consoleAddress = CONSOLE2_ADDRESS; - /// @solidity memory-safe-assembly - assembly { - let payloadStart := add(payload, 32) - let r := staticcall(gas(), consoleAddress, payloadStart, payloadLength, 0, 0) - } - } - - function console2_log_StdUtils(string memory p0) private pure { - _sendLogPayload(abi.encodeWithSignature("log(string)", p0)); - } - - function console2_log_StdUtils(string memory p0, uint256 p1) private pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256)", p0, p1)); - } - - function console2_log_StdUtils(string memory p0, string memory p1) private pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string)", p0, p1)); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/Test.sol b/lib/signals-implicit-mode/lib/forge-std/src/Test.sol deleted file mode 100644 index 11b18f29f3..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/Test.sol +++ /dev/null @@ -1,34 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -// 💬 ABOUT -// Forge Std's default Test. - -// 🧩 MODULES -import {console} from "./console.sol"; -import {console2} from "./console2.sol"; -import {safeconsole} from "./safeconsole.sol"; -import {StdAssertions} from "./StdAssertions.sol"; -import {StdChains} from "./StdChains.sol"; -import {StdCheats} from "./StdCheats.sol"; -import {StdConstants} from "./StdConstants.sol"; -import {stdError} from "./StdError.sol"; -import {StdInvariant} from "./StdInvariant.sol"; -import {stdJson} from "./StdJson.sol"; -import {stdMath} from "./StdMath.sol"; -import {StdStorage, stdStorage} from "./StdStorage.sol"; -import {StdStyle} from "./StdStyle.sol"; -import {stdToml} from "./StdToml.sol"; -import {StdUtils} from "./StdUtils.sol"; -import {Vm} from "./Vm.sol"; - -// 📦 BOILERPLATE -import {TestBase} from "./Base.sol"; - -// ⭐️ TEST -abstract contract Test is TestBase, StdAssertions, StdChains, StdCheats, StdInvariant, StdUtils { - // Note: IS_TEST() must return true. - bool public IS_TEST = true; -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/Vm.sol b/lib/signals-implicit-mode/lib/forge-std/src/Vm.sol deleted file mode 100644 index cd883706a1..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/Vm.sol +++ /dev/null @@ -1,2494 +0,0 @@ -// Automatically @generated by scripts/vm.py. Do not modify manually. - -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.6.2 <0.9.0; -pragma experimental ABIEncoderV2; - -/// The `VmSafe` interface does not allow manipulation of the EVM state or other actions that may -/// result in Script simulations differing from on-chain execution. It is recommended to only use -/// these cheats in scripts. -interface VmSafe { - /// A modification applied to either `msg.sender` or `tx.origin`. Returned by `readCallers`. - enum CallerMode { - // No caller modification is currently active. - None, - // A one time broadcast triggered by a `vm.broadcast()` call is currently active. - Broadcast, - // A recurrent broadcast triggered by a `vm.startBroadcast()` call is currently active. - RecurrentBroadcast, - // A one time prank triggered by a `vm.prank()` call is currently active. - Prank, - // A recurrent prank triggered by a `vm.startPrank()` call is currently active. - RecurrentPrank - } - - /// The kind of account access that occurred. - enum AccountAccessKind { - // The account was called. - Call, - // The account was called via delegatecall. - DelegateCall, - // The account was called via callcode. - CallCode, - // The account was called via staticcall. - StaticCall, - // The account was created. - Create, - // The account was selfdestructed. - SelfDestruct, - // Synthetic access indicating the current context has resumed after a previous sub-context (AccountAccess). - Resume, - // The account's balance was read. - Balance, - // The account's codesize was read. - Extcodesize, - // The account's codehash was read. - Extcodehash, - // The account's code was copied. - Extcodecopy - } - - /// Forge execution contexts. - enum ForgeContext { - // Test group execution context (test, coverage or snapshot). - TestGroup, - // `forge test` execution context. - Test, - // `forge coverage` execution context. - Coverage, - // `forge snapshot` execution context. - Snapshot, - // Script group execution context (dry run, broadcast or resume). - ScriptGroup, - // `forge script` execution context. - ScriptDryRun, - // `forge script --broadcast` execution context. - ScriptBroadcast, - // `forge script --resume` execution context. - ScriptResume, - // Unknown `forge` execution context. - Unknown - } - - /// The transaction type (`txType`) of the broadcast. - enum BroadcastTxType { - // Represents a CALL broadcast tx. - Call, - // Represents a CREATE broadcast tx. - Create, - // Represents a CREATE2 broadcast tx. - Create2 - } - - /// An Ethereum log. Returned by `getRecordedLogs`. - struct Log { - // The topics of the log, including the signature, if any. - bytes32[] topics; - // The raw data of the log. - bytes data; - // The address of the log's emitter. - address emitter; - } - - /// An RPC URL and its alias. Returned by `rpcUrlStructs`. - struct Rpc { - // The alias of the RPC URL. - string key; - // The RPC URL. - string url; - } - - /// An RPC log object. Returned by `eth_getLogs`. - struct EthGetLogs { - // The address of the log's emitter. - address emitter; - // The topics of the log, including the signature, if any. - bytes32[] topics; - // The raw data of the log. - bytes data; - // The block hash. - bytes32 blockHash; - // The block number. - uint64 blockNumber; - // The transaction hash. - bytes32 transactionHash; - // The transaction index in the block. - uint64 transactionIndex; - // The log index. - uint256 logIndex; - // Whether the log was removed. - bool removed; - } - - /// A single entry in a directory listing. Returned by `readDir`. - struct DirEntry { - // The error message, if any. - string errorMessage; - // The path of the entry. - string path; - // The depth of the entry. - uint64 depth; - // Whether the entry is a directory. - bool isDir; - // Whether the entry is a symlink. - bool isSymlink; - } - - /// Metadata information about a file. - /// This structure is returned from the `fsMetadata` function and represents known - /// metadata about a file such as its permissions, size, modification - /// times, etc. - struct FsMetadata { - // True if this metadata is for a directory. - bool isDir; - // True if this metadata is for a symlink. - bool isSymlink; - // The size of the file, in bytes, this metadata is for. - uint256 length; - // True if this metadata is for a readonly (unwritable) file. - bool readOnly; - // The last modification time listed in this metadata. - uint256 modified; - // The last access time of this metadata. - uint256 accessed; - // The creation time listed in this metadata. - uint256 created; - } - - /// A wallet with a public and private key. - struct Wallet { - // The wallet's address. - address addr; - // The wallet's public key `X`. - uint256 publicKeyX; - // The wallet's public key `Y`. - uint256 publicKeyY; - // The wallet's private key. - uint256 privateKey; - } - - /// The result of a `tryFfi` call. - struct FfiResult { - // The exit code of the call. - int32 exitCode; - // The optionally hex-decoded `stdout` data. - bytes stdout; - // The `stderr` data. - bytes stderr; - } - - /// Information on the chain and fork. - struct ChainInfo { - // The fork identifier. Set to zero if no fork is active. - uint256 forkId; - // The chain ID of the current fork. - uint256 chainId; - } - - /// Information about a blockchain. - struct Chain { - // The chain name. - string name; - // The chain's Chain ID. - uint256 chainId; - // The chain's alias. (i.e. what gets specified in `foundry.toml`). - string chainAlias; - // A default RPC endpoint for this chain. - string rpcUrl; - } - - /// The result of a `stopAndReturnStateDiff` call. - struct AccountAccess { - // The chain and fork the access occurred. - ChainInfo chainInfo; - // The kind of account access that determines what the account is. - // If kind is Call, DelegateCall, StaticCall or CallCode, then the account is the callee. - // If kind is Create, then the account is the newly created account. - // If kind is SelfDestruct, then the account is the selfdestruct recipient. - // If kind is a Resume, then account represents a account context that has resumed. - AccountAccessKind kind; - // The account that was accessed. - // It's either the account created, callee or a selfdestruct recipient for CREATE, CALL or SELFDESTRUCT. - address account; - // What accessed the account. - address accessor; - // If the account was initialized or empty prior to the access. - // An account is considered initialized if it has code, a - // non-zero nonce, or a non-zero balance. - bool initialized; - // The previous balance of the accessed account. - uint256 oldBalance; - // The potential new balance of the accessed account. - // That is, all balance changes are recorded here, even if reverts occurred. - uint256 newBalance; - // Code of the account deployed by CREATE. - bytes deployedCode; - // Value passed along with the account access - uint256 value; - // Input data provided to the CREATE or CALL - bytes data; - // If this access reverted in either the current or parent context. - bool reverted; - // An ordered list of storage accesses made during an account access operation. - StorageAccess[] storageAccesses; - // Call depth traversed during the recording of state differences - uint64 depth; - // The previous nonce of the accessed account. - uint64 oldNonce; - // The new nonce of the accessed account. - uint64 newNonce; - } - - /// The storage accessed during an `AccountAccess`. - struct StorageAccess { - // The account whose storage was accessed. - address account; - // The slot that was accessed. - bytes32 slot; - // If the access was a write. - bool isWrite; - // The previous value of the slot. - bytes32 previousValue; - // The new value of the slot. - bytes32 newValue; - // If the access was reverted. - bool reverted; - } - - /// Gas used. Returned by `lastCallGas`. - struct Gas { - // The gas limit of the call. - uint64 gasLimit; - // The total gas used. - uint64 gasTotalUsed; - // DEPRECATED: The amount of gas used for memory expansion. Ref: - uint64 gasMemoryUsed; - // The amount of gas refunded. - int64 gasRefunded; - // The amount of gas remaining. - uint64 gasRemaining; - } - - /// The result of the `stopDebugTraceRecording` call - struct DebugStep { - // The stack before executing the step of the run. - // stack\[0\] represents the top of the stack. - // and only stack data relevant to the opcode execution is contained. - uint256[] stack; - // The memory input data before executing the step of the run. - // only input data relevant to the opcode execution is contained. - // e.g. for MLOAD, it will have memory\[offset:offset+32\] copied here. - // the offset value can be get by the stack data. - bytes memoryInput; - // The opcode that was accessed. - uint8 opcode; - // The call depth of the step. - uint64 depth; - // Whether the call end up with out of gas error. - bool isOutOfGas; - // The contract address where the opcode is running - address contractAddr; - } - - /// Represents a transaction's broadcast details. - struct BroadcastTxSummary { - // The hash of the transaction that was broadcasted - bytes32 txHash; - // Represent the type of transaction among CALL, CREATE, CREATE2 - BroadcastTxType txType; - // The address of the contract that was called or created. - // This is address of the contract that is created if the txType is CREATE or CREATE2. - address contractAddress; - // The block number the transaction landed in. - uint64 blockNumber; - // Status of the transaction, retrieved from the transaction receipt. - bool success; - } - - /// Holds a signed EIP-7702 authorization for an authority account to delegate to an implementation. - struct SignedDelegation { - // The y-parity of the recovered secp256k1 signature (0 or 1). - uint8 v; - // First 32 bytes of the signature. - bytes32 r; - // Second 32 bytes of the signature. - bytes32 s; - // The current nonce of the authority account at signing time. - // Used to ensure signature can't be replayed after account nonce changes. - uint64 nonce; - // Address of the contract implementation that will be delegated to. - // Gets encoded into delegation code: 0xef0100 || implementation. - address implementation; - } - - /// Represents a "potential" revert reason from a single subsequent call when using `vm.assumeNoReverts`. - /// Reverts that match will result in a FOUNDRY::ASSUME rejection, whereas unmatched reverts will be surfaced - /// as normal. - struct PotentialRevert { - // The allowed origin of the revert opcode; address(0) allows reverts from any address - address reverter; - // When true, only matches on the beginning of the revert data, otherwise, matches on entire revert data - bool partialMatch; - // The data to use to match encountered reverts - bytes revertData; - } - - /// An EIP-2930 access list item. - struct AccessListItem { - // The address to be added in access list. - address target; - // The storage keys to be added in access list. - bytes32[] storageKeys; - } - - // ======== Crypto ======== - - /// Derives a private key from the name, labels the account with that name, and returns the wallet. - function createWallet(string calldata walletLabel) external returns (Wallet memory wallet); - - /// Generates a wallet from the private key and returns the wallet. - function createWallet(uint256 privateKey) external returns (Wallet memory wallet); - - /// Generates a wallet from the private key, labels the account with that name, and returns the wallet. - function createWallet(uint256 privateKey, string calldata walletLabel) external returns (Wallet memory wallet); - - /// Derive a private key from a provided mnemonic string (or mnemonic file path) - /// at the derivation path `m/44'/60'/0'/0/{index}`. - function deriveKey(string calldata mnemonic, uint32 index) external pure returns (uint256 privateKey); - - /// Derive a private key from a provided mnemonic string (or mnemonic file path) - /// at `{derivationPath}{index}`. - function deriveKey(string calldata mnemonic, string calldata derivationPath, uint32 index) - external - pure - returns (uint256 privateKey); - - /// Derive a private key from a provided mnemonic string (or mnemonic file path) in the specified language - /// at the derivation path `m/44'/60'/0'/0/{index}`. - function deriveKey(string calldata mnemonic, uint32 index, string calldata language) - external - pure - returns (uint256 privateKey); - - /// Derive a private key from a provided mnemonic string (or mnemonic file path) in the specified language - /// at `{derivationPath}{index}`. - function deriveKey(string calldata mnemonic, string calldata derivationPath, uint32 index, string calldata language) - external - pure - returns (uint256 privateKey); - - /// Derives secp256r1 public key from the provided `privateKey`. - function publicKeyP256(uint256 privateKey) external pure returns (uint256 publicKeyX, uint256 publicKeyY); - - /// Adds a private key to the local forge wallet and returns the address. - function rememberKey(uint256 privateKey) external returns (address keyAddr); - - /// Derive a set number of wallets from a mnemonic at the derivation path `m/44'/60'/0'/0/{0..count}`. - /// The respective private keys are saved to the local forge wallet for later use and their addresses are returned. - function rememberKeys(string calldata mnemonic, string calldata derivationPath, uint32 count) - external - returns (address[] memory keyAddrs); - - /// Derive a set number of wallets from a mnemonic in the specified language at the derivation path `m/44'/60'/0'/0/{0..count}`. - /// The respective private keys are saved to the local forge wallet for later use and their addresses are returned. - function rememberKeys( - string calldata mnemonic, - string calldata derivationPath, - string calldata language, - uint32 count - ) external returns (address[] memory keyAddrs); - - /// Signs data with a `Wallet`. - /// Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the - /// signature's `s` value, and the recovery id `v` in a single bytes32. - /// This format reduces the signature size from 65 to 64 bytes. - function signCompact(Wallet calldata wallet, bytes32 digest) external returns (bytes32 r, bytes32 vs); - - /// Signs `digest` with `privateKey` using the secp256k1 curve. - /// Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the - /// signature's `s` value, and the recovery id `v` in a single bytes32. - /// This format reduces the signature size from 65 to 64 bytes. - function signCompact(uint256 privateKey, bytes32 digest) external pure returns (bytes32 r, bytes32 vs); - - /// Signs `digest` with signer provided to script using the secp256k1 curve. - /// Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the - /// signature's `s` value, and the recovery id `v` in a single bytes32. - /// This format reduces the signature size from 65 to 64 bytes. - /// If `--sender` is provided, the signer with provided address is used, otherwise, - /// if exactly one signer is provided to the script, that signer is used. - /// Raises error if signer passed through `--sender` does not match any unlocked signers or - /// if `--sender` is not provided and not exactly one signer is passed to the script. - function signCompact(bytes32 digest) external pure returns (bytes32 r, bytes32 vs); - - /// Signs `digest` with signer provided to script using the secp256k1 curve. - /// Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the - /// signature's `s` value, and the recovery id `v` in a single bytes32. - /// This format reduces the signature size from 65 to 64 bytes. - /// Raises error if none of the signers passed into the script have provided address. - function signCompact(address signer, bytes32 digest) external pure returns (bytes32 r, bytes32 vs); - - /// Signs `digest` with `privateKey` using the secp256r1 curve. - function signP256(uint256 privateKey, bytes32 digest) external pure returns (bytes32 r, bytes32 s); - - /// Signs data with a `Wallet`. - function sign(Wallet calldata wallet, bytes32 digest) external returns (uint8 v, bytes32 r, bytes32 s); - - /// Signs `digest` with `privateKey` using the secp256k1 curve. - function sign(uint256 privateKey, bytes32 digest) external pure returns (uint8 v, bytes32 r, bytes32 s); - - /// Signs `digest` with signer provided to script using the secp256k1 curve. - /// If `--sender` is provided, the signer with provided address is used, otherwise, - /// if exactly one signer is provided to the script, that signer is used. - /// Raises error if signer passed through `--sender` does not match any unlocked signers or - /// if `--sender` is not provided and not exactly one signer is passed to the script. - function sign(bytes32 digest) external pure returns (uint8 v, bytes32 r, bytes32 s); - - /// Signs `digest` with signer provided to script using the secp256k1 curve. - /// Raises error if none of the signers passed into the script have provided address. - function sign(address signer, bytes32 digest) external pure returns (uint8 v, bytes32 r, bytes32 s); - - // ======== Environment ======== - - /// Gets the environment variable `name` and parses it as `address`. - /// Reverts if the variable was not found or could not be parsed. - function envAddress(string calldata name) external view returns (address value); - - /// Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envAddress(string calldata name, string calldata delim) external view returns (address[] memory value); - - /// Gets the environment variable `name` and parses it as `bool`. - /// Reverts if the variable was not found or could not be parsed. - function envBool(string calldata name) external view returns (bool value); - - /// Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envBool(string calldata name, string calldata delim) external view returns (bool[] memory value); - - /// Gets the environment variable `name` and parses it as `bytes32`. - /// Reverts if the variable was not found or could not be parsed. - function envBytes32(string calldata name) external view returns (bytes32 value); - - /// Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envBytes32(string calldata name, string calldata delim) external view returns (bytes32[] memory value); - - /// Gets the environment variable `name` and parses it as `bytes`. - /// Reverts if the variable was not found or could not be parsed. - function envBytes(string calldata name) external view returns (bytes memory value); - - /// Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envBytes(string calldata name, string calldata delim) external view returns (bytes[] memory value); - - /// Gets the environment variable `name` and returns true if it exists, else returns false. - function envExists(string calldata name) external view returns (bool result); - - /// Gets the environment variable `name` and parses it as `int256`. - /// Reverts if the variable was not found or could not be parsed. - function envInt(string calldata name) external view returns (int256 value); - - /// Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envInt(string calldata name, string calldata delim) external view returns (int256[] memory value); - - /// Gets the environment variable `name` and parses it as `bool`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, bool defaultValue) external view returns (bool value); - - /// Gets the environment variable `name` and parses it as `uint256`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, uint256 defaultValue) external view returns (uint256 value); - - /// Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, address[] calldata defaultValue) - external - view - returns (address[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, bytes32[] calldata defaultValue) - external - view - returns (bytes32[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, string[] calldata defaultValue) - external - view - returns (string[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, bytes[] calldata defaultValue) - external - view - returns (bytes[] memory value); - - /// Gets the environment variable `name` and parses it as `int256`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, int256 defaultValue) external view returns (int256 value); - - /// Gets the environment variable `name` and parses it as `address`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, address defaultValue) external view returns (address value); - - /// Gets the environment variable `name` and parses it as `bytes32`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, bytes32 defaultValue) external view returns (bytes32 value); - - /// Gets the environment variable `name` and parses it as `string`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata defaultValue) external view returns (string memory value); - - /// Gets the environment variable `name` and parses it as `bytes`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, bytes calldata defaultValue) external view returns (bytes memory value); - - /// Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, bool[] calldata defaultValue) - external - view - returns (bool[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, uint256[] calldata defaultValue) - external - view - returns (uint256[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, int256[] calldata defaultValue) - external - view - returns (int256[] memory value); - - /// Gets the environment variable `name` and parses it as `string`. - /// Reverts if the variable was not found or could not be parsed. - function envString(string calldata name) external view returns (string memory value); - - /// Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envString(string calldata name, string calldata delim) external view returns (string[] memory value); - - /// Gets the environment variable `name` and parses it as `uint256`. - /// Reverts if the variable was not found or could not be parsed. - function envUint(string calldata name) external view returns (uint256 value); - - /// Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envUint(string calldata name, string calldata delim) external view returns (uint256[] memory value); - - /// Returns true if `forge` command was executed in given context. - function isContext(ForgeContext context) external view returns (bool result); - - /// Resolves the env variable placeholders of a given input string. - function resolveEnv(string calldata input) external returns (string memory); - - /// Sets environment variables. - function setEnv(string calldata name, string calldata value) external; - - // ======== EVM ======== - - /// Gets all accessed reads and write slot from a `vm.record` session, for a given address. - function accesses(address target) external view returns (bytes32[] memory readSlots, bytes32[] memory writeSlots); - - /// Gets the address for a given private key. - function addr(uint256 privateKey) external pure returns (address keyAddr); - - /// Gets all the logs according to specified filter. - function eth_getLogs(uint256 fromBlock, uint256 toBlock, address target, bytes32[] calldata topics) - external - view - returns (EthGetLogs[] memory logs); - - /// Gets the current `block.blobbasefee`. - /// You should use this instead of `block.blobbasefee` if you use `vm.blobBaseFee`, as `block.blobbasefee` is assumed to be constant across a transaction, - /// and as a result will get optimized out by the compiler. - /// See https://github.com/foundry-rs/foundry/issues/6180 - function getBlobBaseFee() external view returns (uint256 blobBaseFee); - - /// Gets the current `block.number`. - /// You should use this instead of `block.number` if you use `vm.roll`, as `block.number` is assumed to be constant across a transaction, - /// and as a result will get optimized out by the compiler. - /// See https://github.com/foundry-rs/foundry/issues/6180 - function getBlockNumber() external view returns (uint256 height); - - /// Gets the current `block.timestamp`. - /// You should use this instead of `block.timestamp` if you use `vm.warp`, as `block.timestamp` is assumed to be constant across a transaction, - /// and as a result will get optimized out by the compiler. - /// See https://github.com/foundry-rs/foundry/issues/6180 - function getBlockTimestamp() external view returns (uint256 timestamp); - - /// Gets the current `block.chainid` of the currently selected environment. - /// You should use this instead of `block.chainid` if you use `vm.selectFork` or `vm.createSelectFork`, as `block.chainid` could be assumed - /// to be constant across a transaction, and as a result will get optimized out by the compiler. - /// See https://github.com/foundry-rs/foundry/issues/6180 - function getChainId() external view returns (uint256 blockChainId); - - /// Gets the map key and parent of a mapping at a given slot, for a given address. - function getMappingKeyAndParentOf(address target, bytes32 elementSlot) - external - view - returns (bool found, bytes32 key, bytes32 parent); - - /// Gets the number of elements in the mapping at the given slot, for a given address. - function getMappingLength(address target, bytes32 mappingSlot) external view returns (uint256 length); - - /// Gets the elements at index idx of the mapping at the given slot, for a given address. The - /// index must be less than the length of the mapping (i.e. the number of keys in the mapping). - function getMappingSlotAt(address target, bytes32 mappingSlot, uint256 idx) external view returns (bytes32 value); - - /// Gets the nonce of an account. - function getNonce(address account) external view returns (uint64 nonce); - - /// Get the nonce of a `Wallet`. - function getNonce(Wallet calldata wallet) external view returns (uint64 nonce); - - /// Gets the RLP encoded block header for a given block number. - /// Returns the block header in the same format as `cast block --raw`. - function getRawBlockHeader(uint256 blockNumber) external view returns (bytes memory rlpHeader); - - /// Gets all the recorded logs. - function getRecordedLogs() external view returns (Log[] memory logs); - - /// Returns state diffs from current `vm.startStateDiffRecording` session. - function getStateDiff() external view returns (string memory diff); - - /// Returns state diffs from current `vm.startStateDiffRecording` session, in json format. - function getStateDiffJson() external view returns (string memory diff); - - /// Returns an array of `StorageAccess` from current `vm.stateStateDiffRecording` session - function getStorageAccesses() external view returns (StorageAccess[] memory storageAccesses); - - /// Gets the gas used in the last call from the callee perspective. - function lastCallGas() external view returns (Gas memory gas); - - /// Loads a storage slot from an address. - function load(address target, bytes32 slot) external view returns (bytes32 data); - - /// Pauses gas metering (i.e. gas usage is not counted). Noop if already paused. - function pauseGasMetering() external; - - /// Records all storage reads and writes. Use `accesses` to get the recorded data. - /// Subsequent calls to `record` will clear the previous data. - function record() external; - - /// Record all the transaction logs. - function recordLogs() external; - - /// Reset gas metering (i.e. gas usage is set to gas limit). - function resetGasMetering() external; - - /// Resumes gas metering (i.e. gas usage is counted again). Noop if already on. - function resumeGasMetering() external; - - /// Performs an Ethereum JSON-RPC request to the current fork URL. - function rpc(string calldata method, string calldata params) external returns (bytes memory data); - - /// Performs an Ethereum JSON-RPC request to the given endpoint. - function rpc(string calldata urlOrAlias, string calldata method, string calldata params) - external - returns (bytes memory data); - - /// Records the debug trace during the run. - function startDebugTraceRecording() external; - - /// Starts recording all map SSTOREs for later retrieval. - function startMappingRecording() external; - - /// Record all account accesses as part of CREATE, CALL or SELFDESTRUCT opcodes in order, - /// along with the context of the calls - function startStateDiffRecording() external; - - /// Stop debug trace recording and returns the recorded debug trace. - function stopAndReturnDebugTraceRecording() external returns (DebugStep[] memory step); - - /// Returns an ordered array of all account accesses from a `vm.startStateDiffRecording` session. - function stopAndReturnStateDiff() external returns (AccountAccess[] memory accountAccesses); - - /// Stops recording all map SSTOREs for later retrieval and clears the recorded data. - function stopMappingRecording() external; - - /// Stops recording storage reads and writes. - function stopRecord() external; - - // ======== Filesystem ======== - - /// Closes file for reading, resetting the offset and allowing to read it from beginning with readLine. - /// `path` is relative to the project root. - function closeFile(string calldata path) external; - - /// Copies the contents of one file to another. This function will **overwrite** the contents of `to`. - /// On success, the total number of bytes copied is returned and it is equal to the length of the `to` file as reported by `metadata`. - /// Both `from` and `to` are relative to the project root. - function copyFile(string calldata from, string calldata to) external returns (uint64 copied); - - /// Creates a new, empty directory at the provided path. - /// This cheatcode will revert in the following situations, but is not limited to just these cases: - /// - User lacks permissions to modify `path`. - /// - A parent of the given path doesn't exist and `recursive` is false. - /// - `path` already exists and `recursive` is false. - /// `path` is relative to the project root. - function createDir(string calldata path, bool recursive) external; - - /// Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - function deployCode(string calldata artifactPath) external returns (address deployedAddress); - - /// Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Additionally accepts abi-encoded constructor arguments. - function deployCode(string calldata artifactPath, bytes calldata constructorArgs) - external - returns (address deployedAddress); - - /// Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Additionally accepts `msg.value`. - function deployCode(string calldata artifactPath, uint256 value) external returns (address deployedAddress); - - /// Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Additionally accepts abi-encoded constructor arguments and `msg.value`. - function deployCode(string calldata artifactPath, bytes calldata constructorArgs, uint256 value) - external - returns (address deployedAddress); - - /// Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - function deployCode(string calldata artifactPath, bytes32 salt) external returns (address deployedAddress); - - /// Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Additionally accepts abi-encoded constructor arguments. - function deployCode(string calldata artifactPath, bytes calldata constructorArgs, bytes32 salt) - external - returns (address deployedAddress); - - /// Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Additionally accepts `msg.value`. - function deployCode(string calldata artifactPath, uint256 value, bytes32 salt) - external - returns (address deployedAddress); - - /// Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Additionally accepts abi-encoded constructor arguments and `msg.value`. - function deployCode(string calldata artifactPath, bytes calldata constructorArgs, uint256 value, bytes32 salt) - external - returns (address deployedAddress); - - /// Returns true if the given path points to an existing entity, else returns false. - function exists(string calldata path) external view returns (bool result); - - /// Performs a foreign function call via the terminal. - function ffi(string[] calldata commandInput) external returns (bytes memory result); - - /// Given a path, query the file system to get information about a file, directory, etc. - function fsMetadata(string calldata path) external view returns (FsMetadata memory metadata); - - /// Gets the artifact path from code (aka. creation code). - function getArtifactPathByCode(bytes calldata code) external view returns (string memory path); - - /// Gets the artifact path from deployed code (aka. runtime code). - function getArtifactPathByDeployedCode(bytes calldata deployedCode) external view returns (string memory path); - - /// Returns the most recent broadcast for the given contract on `chainId` matching `txType`. - /// For example: - /// The most recent deployment can be fetched by passing `txType` as `CREATE` or `CREATE2`. - /// The most recent call can be fetched by passing `txType` as `CALL`. - function getBroadcast(string calldata contractName, uint64 chainId, BroadcastTxType txType) - external - view - returns (BroadcastTxSummary memory); - - /// Returns all broadcasts for the given contract on `chainId` with the specified `txType`. - /// Sorted such that the most recent broadcast is the first element, and the oldest is the last. i.e descending order of BroadcastTxSummary.blockNumber. - function getBroadcasts(string calldata contractName, uint64 chainId, BroadcastTxType txType) - external - view - returns (BroadcastTxSummary[] memory); - - /// Returns all broadcasts for the given contract on `chainId`. - /// Sorted such that the most recent broadcast is the first element, and the oldest is the last. i.e descending order of BroadcastTxSummary.blockNumber. - function getBroadcasts(string calldata contractName, uint64 chainId) - external - view - returns (BroadcastTxSummary[] memory); - - /// Gets the creation bytecode from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - function getCode(string calldata artifactPath) external view returns (bytes memory creationBytecode); - - /// Gets the deployed bytecode from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - function getDeployedCode(string calldata artifactPath) external view returns (bytes memory runtimeBytecode); - - /// Returns the most recent deployment for the current `chainId`. - function getDeployment(string calldata contractName) external view returns (address deployedAddress); - - /// Returns the most recent deployment for the given contract on `chainId` - function getDeployment(string calldata contractName, uint64 chainId) - external - view - returns (address deployedAddress); - - /// Returns all deployments for the given contract on `chainId` - /// Sorted in descending order of deployment time i.e descending order of BroadcastTxSummary.blockNumber. - /// The most recent deployment is the first element, and the oldest is the last. - function getDeployments(string calldata contractName, uint64 chainId) - external - view - returns (address[] memory deployedAddresses); - - /// Returns true if the path exists on disk and is pointing at a directory, else returns false. - function isDir(string calldata path) external view returns (bool result); - - /// Returns true if the path exists on disk and is pointing at a regular file, else returns false. - function isFile(string calldata path) external view returns (bool result); - - /// Get the path of the current project root. - function projectRoot() external view returns (string memory path); - - /// Prompts the user for a string value in the terminal. - function prompt(string calldata promptText) external returns (string memory input); - - /// Prompts the user for an address in the terminal. - function promptAddress(string calldata promptText) external returns (address); - - /// Prompts the user for a hidden string value in the terminal. - function promptSecret(string calldata promptText) external returns (string memory input); - - /// Prompts the user for hidden uint256 in the terminal (usually pk). - function promptSecretUint(string calldata promptText) external returns (uint256); - - /// Prompts the user for uint256 in the terminal. - function promptUint(string calldata promptText) external returns (uint256); - - /// Reads the directory at the given path recursively, up to `maxDepth`. - /// `maxDepth` defaults to 1, meaning only the direct children of the given directory will be returned. - /// Follows symbolic links if `followLinks` is true. - function readDir(string calldata path) external view returns (DirEntry[] memory entries); - - /// See `readDir(string)`. - function readDir(string calldata path, uint64 maxDepth) external view returns (DirEntry[] memory entries); - - /// See `readDir(string)`. - function readDir(string calldata path, uint64 maxDepth, bool followLinks) - external - view - returns (DirEntry[] memory entries); - - /// Reads the entire content of file to string. `path` is relative to the project root. - function readFile(string calldata path) external view returns (string memory data); - - /// Reads the entire content of file as binary. `path` is relative to the project root. - function readFileBinary(string calldata path) external view returns (bytes memory data); - - /// Reads next line of file to string. - function readLine(string calldata path) external view returns (string memory line); - - /// Reads a symbolic link, returning the path that the link points to. - /// This cheatcode will revert in the following situations, but is not limited to just these cases: - /// - `path` is not a symbolic link. - /// - `path` does not exist. - function readLink(string calldata linkPath) external view returns (string memory targetPath); - - /// Removes a directory at the provided path. - /// This cheatcode will revert in the following situations, but is not limited to just these cases: - /// - `path` doesn't exist. - /// - `path` isn't a directory. - /// - User lacks permissions to modify `path`. - /// - The directory is not empty and `recursive` is false. - /// `path` is relative to the project root. - function removeDir(string calldata path, bool recursive) external; - - /// Removes a file from the filesystem. - /// This cheatcode will revert in the following situations, but is not limited to just these cases: - /// - `path` points to a directory. - /// - The file doesn't exist. - /// - The user lacks permissions to remove the file. - /// `path` is relative to the project root. - function removeFile(string calldata path) external; - - /// Performs a foreign function call via terminal and returns the exit code, stdout, and stderr. - function tryFfi(string[] calldata commandInput) external returns (FfiResult memory result); - - /// Returns the time since unix epoch in milliseconds. - function unixTime() external view returns (uint256 milliseconds); - - /// Writes data to file, creating a file if it does not exist, and entirely replacing its contents if it does. - /// `path` is relative to the project root. - function writeFile(string calldata path, string calldata data) external; - - /// Writes binary data to a file, creating a file if it does not exist, and entirely replacing its contents if it does. - /// `path` is relative to the project root. - function writeFileBinary(string calldata path, bytes calldata data) external; - - /// Writes line to file, creating a file if it does not exist. - /// `path` is relative to the project root. - function writeLine(string calldata path, string calldata data) external; - - // ======== JSON ======== - - /// Checks if `key` exists in a JSON object. - function keyExistsJson(string calldata json, string calldata key) external view returns (bool); - - /// Parses a string of JSON data at `key` and coerces it to `address`. - function parseJsonAddress(string calldata json, string calldata key) external pure returns (address); - - /// Parses a string of JSON data at `key` and coerces it to `address[]`. - function parseJsonAddressArray(string calldata json, string calldata key) - external - pure - returns (address[] memory); - - /// Parses a string of JSON data at `key` and coerces it to `bool`. - function parseJsonBool(string calldata json, string calldata key) external pure returns (bool); - - /// Parses a string of JSON data at `key` and coerces it to `bool[]`. - function parseJsonBoolArray(string calldata json, string calldata key) external pure returns (bool[] memory); - - /// Parses a string of JSON data at `key` and coerces it to `bytes`. - function parseJsonBytes(string calldata json, string calldata key) external pure returns (bytes memory); - - /// Parses a string of JSON data at `key` and coerces it to `bytes32`. - function parseJsonBytes32(string calldata json, string calldata key) external pure returns (bytes32); - - /// Parses a string of JSON data at `key` and coerces it to `bytes32[]`. - function parseJsonBytes32Array(string calldata json, string calldata key) - external - pure - returns (bytes32[] memory); - - /// Parses a string of JSON data at `key` and coerces it to `bytes[]`. - function parseJsonBytesArray(string calldata json, string calldata key) external pure returns (bytes[] memory); - - /// Parses a string of JSON data at `key` and coerces it to `int256`. - function parseJsonInt(string calldata json, string calldata key) external pure returns (int256); - - /// Parses a string of JSON data at `key` and coerces it to `int256[]`. - function parseJsonIntArray(string calldata json, string calldata key) external pure returns (int256[] memory); - - /// Returns an array of all the keys in a JSON object. - function parseJsonKeys(string calldata json, string calldata key) external pure returns (string[] memory keys); - - /// Parses a string of JSON data at `key` and coerces it to `string`. - function parseJsonString(string calldata json, string calldata key) external pure returns (string memory); - - /// Parses a string of JSON data at `key` and coerces it to `string[]`. - function parseJsonStringArray(string calldata json, string calldata key) external pure returns (string[] memory); - - /// Parses a string of JSON data at `key` and coerces it to type array corresponding to `typeDescription`. - function parseJsonTypeArray(string calldata json, string calldata key, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of JSON data and coerces it to type corresponding to `typeDescription`. - function parseJsonType(string calldata json, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of JSON data at `key` and coerces it to type corresponding to `typeDescription`. - function parseJsonType(string calldata json, string calldata key, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of JSON data at `key` and coerces it to `uint256`. - function parseJsonUint(string calldata json, string calldata key) external pure returns (uint256); - - /// Parses a string of JSON data at `key` and coerces it to `uint256[]`. - function parseJsonUintArray(string calldata json, string calldata key) external pure returns (uint256[] memory); - - /// ABI-encodes a JSON object. - function parseJson(string calldata json) external pure returns (bytes memory abiEncodedData); - - /// ABI-encodes a JSON object at `key`. - function parseJson(string calldata json, string calldata key) external pure returns (bytes memory abiEncodedData); - - /// See `serializeJson`. - function serializeAddress(string calldata objectKey, string calldata valueKey, address value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeAddress(string calldata objectKey, string calldata valueKey, address[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBool(string calldata objectKey, string calldata valueKey, bool value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBool(string calldata objectKey, string calldata valueKey, bool[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBytes32(string calldata objectKey, string calldata valueKey, bytes32 value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBytes32(string calldata objectKey, string calldata valueKey, bytes32[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBytes(string calldata objectKey, string calldata valueKey, bytes calldata value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBytes(string calldata objectKey, string calldata valueKey, bytes[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeInt(string calldata objectKey, string calldata valueKey, int256 value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeInt(string calldata objectKey, string calldata valueKey, int256[] calldata values) - external - returns (string memory json); - - /// Serializes a key and value to a JSON object stored in-memory that can be later written to a file. - /// Returns the stringified version of the specific JSON file up to that moment. - function serializeJson(string calldata objectKey, string calldata value) external returns (string memory json); - - /// See `serializeJson`. - function serializeJsonType(string calldata typeDescription, bytes calldata value) - external - pure - returns (string memory json); - - /// See `serializeJson`. - function serializeJsonType( - string calldata objectKey, - string calldata valueKey, - string calldata typeDescription, - bytes calldata value - ) external returns (string memory json); - - /// See `serializeJson`. - function serializeString(string calldata objectKey, string calldata valueKey, string calldata value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeString(string calldata objectKey, string calldata valueKey, string[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeUintToHex(string calldata objectKey, string calldata valueKey, uint256 value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeUint(string calldata objectKey, string calldata valueKey, uint256 value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeUint(string calldata objectKey, string calldata valueKey, uint256[] calldata values) - external - returns (string memory json); - - /// Write a serialized JSON object to a file. If the file exists, it will be overwritten. - function writeJson(string calldata json, string calldata path) external; - - /// Write a serialized JSON object to an **existing** JSON file, replacing a value with key = - /// This is useful to replace a specific value of a JSON file, without having to parse the entire thing. - /// This cheatcode will create new keys if they didn't previously exist. - function writeJson(string calldata json, string calldata path, string calldata valueKey) external; - - /// Checks if `key` exists in a JSON object - /// `keyExists` is being deprecated in favor of `keyExistsJson`. It will be removed in future versions. - function keyExists(string calldata json, string calldata key) external view returns (bool); - - // ======== Scripting ======== - - /// Attach an EIP-4844 blob to the next call - function attachBlob(bytes calldata blob) external; - - /// Designate the next call as an EIP-7702 transaction - function attachDelegation(SignedDelegation calldata signedDelegation) external; - - /// Designate the next call as an EIP-7702 transaction, with optional cross-chain validity. - function attachDelegation(SignedDelegation calldata signedDelegation, bool crossChain) external; - - /// Takes a signed transaction and broadcasts it to the network. - function broadcastRawTransaction(bytes calldata data) external; - - /// Has the next call (at this call depth only) create transactions that can later be signed and sent onchain. - /// Broadcasting address is determined by checking the following in order: - /// 1. If `--sender` argument was provided, that address is used. - /// 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. - /// 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used. - function broadcast() external; - - /// Has the next call (at this call depth only) create a transaction with the address provided - /// as the sender that can later be signed and sent onchain. - function broadcast(address signer) external; - - /// Has the next call (at this call depth only) create a transaction with the private key - /// provided as the sender that can later be signed and sent onchain. - function broadcast(uint256 privateKey) external; - - /// Returns addresses of available unlocked wallets in the script environment. - function getWallets() external view returns (address[] memory wallets); - - /// Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction - function signAndAttachDelegation(address implementation, uint256 privateKey) - external - returns (SignedDelegation memory signedDelegation); - - /// Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction for specific nonce - function signAndAttachDelegation(address implementation, uint256 privateKey, uint64 nonce) - external - returns (SignedDelegation memory signedDelegation); - - /// Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction, with optional cross-chain validity. - function signAndAttachDelegation(address implementation, uint256 privateKey, bool crossChain) - external - returns (SignedDelegation memory signedDelegation); - - /// Sign an EIP-7702 authorization for delegation - function signDelegation(address implementation, uint256 privateKey) - external - returns (SignedDelegation memory signedDelegation); - - /// Sign an EIP-7702 authorization for delegation for specific nonce - function signDelegation(address implementation, uint256 privateKey, uint64 nonce) - external - returns (SignedDelegation memory signedDelegation); - - /// Sign an EIP-7702 authorization for delegation, with optional cross-chain validity. - function signDelegation(address implementation, uint256 privateKey, bool crossChain) - external - returns (SignedDelegation memory signedDelegation); - - /// Has all subsequent calls (at this call depth only) create transactions that can later be signed and sent onchain. - /// Broadcasting address is determined by checking the following in order: - /// 1. If `--sender` argument was provided, that address is used. - /// 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. - /// 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used. - function startBroadcast() external; - - /// Has all subsequent calls (at this call depth only) create transactions with the address - /// provided that can later be signed and sent onchain. - function startBroadcast(address signer) external; - - /// Has all subsequent calls (at this call depth only) create transactions with the private key - /// provided that can later be signed and sent onchain. - function startBroadcast(uint256 privateKey) external; - - /// Stops collecting onchain transactions. - function stopBroadcast() external; - - // ======== String ======== - - /// Returns true if `search` is found in `subject`, false otherwise. - function contains(string calldata subject, string calldata search) external pure returns (bool result); - - /// Returns the index of the first occurrence of a `key` in an `input` string. - /// Returns `NOT_FOUND` (i.e. `type(uint256).max`) if the `key` is not found. - /// Returns 0 in case of an empty `key`. - function indexOf(string calldata input, string calldata key) external pure returns (uint256); - - /// Parses the given `string` into an `address`. - function parseAddress(string calldata stringifiedValue) external pure returns (address parsedValue); - - /// Parses the given `string` into a `bool`. - function parseBool(string calldata stringifiedValue) external pure returns (bool parsedValue); - - /// Parses the given `string` into `bytes`. - function parseBytes(string calldata stringifiedValue) external pure returns (bytes memory parsedValue); - - /// Parses the given `string` into a `bytes32`. - function parseBytes32(string calldata stringifiedValue) external pure returns (bytes32 parsedValue); - - /// Parses the given `string` into a `int256`. - function parseInt(string calldata stringifiedValue) external pure returns (int256 parsedValue); - - /// Parses the given `string` into a `uint256`. - function parseUint(string calldata stringifiedValue) external pure returns (uint256 parsedValue); - - /// Replaces occurrences of `from` in the given `string` with `to`. - function replace(string calldata input, string calldata from, string calldata to) - external - pure - returns (string memory output); - - /// Splits the given `string` into an array of strings divided by the `delimiter`. - function split(string calldata input, string calldata delimiter) external pure returns (string[] memory outputs); - - /// Converts the given `string` value to Lowercase. - function toLowercase(string calldata input) external pure returns (string memory output); - - /// Converts the given value to a `string`. - function toString(address value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(bytes calldata value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(bytes32 value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(bool value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(uint256 value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(int256 value) external pure returns (string memory stringifiedValue); - - /// Converts the given `string` value to Uppercase. - function toUppercase(string calldata input) external pure returns (string memory output); - - /// Trims leading and trailing whitespace from the given `string` value. - function trim(string calldata input) external pure returns (string memory output); - - // ======== Testing ======== - - /// Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. - /// Formats values with decimals in failure message. - function assertApproxEqAbsDecimal(uint256 left, uint256 right, uint256 maxDelta, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertApproxEqAbsDecimal( - uint256 left, - uint256 right, - uint256 maxDelta, - uint256 decimals, - string calldata error - ) external pure; - - /// Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. - /// Formats values with decimals in failure message. - function assertApproxEqAbsDecimal(int256 left, int256 right, uint256 maxDelta, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertApproxEqAbsDecimal( - int256 left, - int256 right, - uint256 maxDelta, - uint256 decimals, - string calldata error - ) external pure; - - /// Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. - function assertApproxEqAbs(uint256 left, uint256 right, uint256 maxDelta) external pure; - - /// Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. - /// Includes error message into revert string on failure. - function assertApproxEqAbs(uint256 left, uint256 right, uint256 maxDelta, string calldata error) external pure; - - /// Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. - function assertApproxEqAbs(int256 left, int256 right, uint256 maxDelta) external pure; - - /// Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. - /// Includes error message into revert string on failure. - function assertApproxEqAbs(int256 left, int256 right, uint256 maxDelta, string calldata error) external pure; - - /// Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Formats values with decimals in failure message. - function assertApproxEqRelDecimal(uint256 left, uint256 right, uint256 maxPercentDelta, uint256 decimals) - external - pure; - - /// Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertApproxEqRelDecimal( - uint256 left, - uint256 right, - uint256 maxPercentDelta, - uint256 decimals, - string calldata error - ) external pure; - - /// Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Formats values with decimals in failure message. - function assertApproxEqRelDecimal(int256 left, int256 right, uint256 maxPercentDelta, uint256 decimals) - external - pure; - - /// Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertApproxEqRelDecimal( - int256 left, - int256 right, - uint256 maxPercentDelta, - uint256 decimals, - string calldata error - ) external pure; - - /// Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - function assertApproxEqRel(uint256 left, uint256 right, uint256 maxPercentDelta) external pure; - - /// Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Includes error message into revert string on failure. - function assertApproxEqRel(uint256 left, uint256 right, uint256 maxPercentDelta, string calldata error) - external - pure; - - /// Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - function assertApproxEqRel(int256 left, int256 right, uint256 maxPercentDelta) external pure; - - /// Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Includes error message into revert string on failure. - function assertApproxEqRel(int256 left, int256 right, uint256 maxPercentDelta, string calldata error) - external - pure; - - /// Asserts that two `uint256` values are equal, formatting them with decimals in failure message. - function assertEqDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Asserts that two `uint256` values are equal, formatting them with decimals in failure message. - /// Includes error message into revert string on failure. - function assertEqDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Asserts that two `int256` values are equal, formatting them with decimals in failure message. - function assertEqDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Asserts that two `int256` values are equal, formatting them with decimals in failure message. - /// Includes error message into revert string on failure. - function assertEqDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Asserts that two `bool` values are equal. - function assertEq(bool left, bool right) external pure; - - /// Asserts that two `bool` values are equal and includes error message into revert string on failure. - function assertEq(bool left, bool right, string calldata error) external pure; - - /// Asserts that two `string` values are equal. - function assertEq(string calldata left, string calldata right) external pure; - - /// Asserts that two `string` values are equal and includes error message into revert string on failure. - function assertEq(string calldata left, string calldata right, string calldata error) external pure; - - /// Asserts that two `bytes` values are equal. - function assertEq(bytes calldata left, bytes calldata right) external pure; - - /// Asserts that two `bytes` values are equal and includes error message into revert string on failure. - function assertEq(bytes calldata left, bytes calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bool` values are equal. - function assertEq(bool[] calldata left, bool[] calldata right) external pure; - - /// Asserts that two arrays of `bool` values are equal and includes error message into revert string on failure. - function assertEq(bool[] calldata left, bool[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `uint256 values are equal. - function assertEq(uint256[] calldata left, uint256[] calldata right) external pure; - - /// Asserts that two arrays of `uint256` values are equal and includes error message into revert string on failure. - function assertEq(uint256[] calldata left, uint256[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `int256` values are equal. - function assertEq(int256[] calldata left, int256[] calldata right) external pure; - - /// Asserts that two arrays of `int256` values are equal and includes error message into revert string on failure. - function assertEq(int256[] calldata left, int256[] calldata right, string calldata error) external pure; - - /// Asserts that two `uint256` values are equal. - function assertEq(uint256 left, uint256 right) external pure; - - /// Asserts that two arrays of `address` values are equal. - function assertEq(address[] calldata left, address[] calldata right) external pure; - - /// Asserts that two arrays of `address` values are equal and includes error message into revert string on failure. - function assertEq(address[] calldata left, address[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bytes32` values are equal. - function assertEq(bytes32[] calldata left, bytes32[] calldata right) external pure; - - /// Asserts that two arrays of `bytes32` values are equal and includes error message into revert string on failure. - function assertEq(bytes32[] calldata left, bytes32[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `string` values are equal. - function assertEq(string[] calldata left, string[] calldata right) external pure; - - /// Asserts that two arrays of `string` values are equal and includes error message into revert string on failure. - function assertEq(string[] calldata left, string[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bytes` values are equal. - function assertEq(bytes[] calldata left, bytes[] calldata right) external pure; - - /// Asserts that two arrays of `bytes` values are equal and includes error message into revert string on failure. - function assertEq(bytes[] calldata left, bytes[] calldata right, string calldata error) external pure; - - /// Asserts that two `uint256` values are equal and includes error message into revert string on failure. - function assertEq(uint256 left, uint256 right, string calldata error) external pure; - - /// Asserts that two `int256` values are equal. - function assertEq(int256 left, int256 right) external pure; - - /// Asserts that two `int256` values are equal and includes error message into revert string on failure. - function assertEq(int256 left, int256 right, string calldata error) external pure; - - /// Asserts that two `address` values are equal. - function assertEq(address left, address right) external pure; - - /// Asserts that two `address` values are equal and includes error message into revert string on failure. - function assertEq(address left, address right, string calldata error) external pure; - - /// Asserts that two `bytes32` values are equal. - function assertEq(bytes32 left, bytes32 right) external pure; - - /// Asserts that two `bytes32` values are equal and includes error message into revert string on failure. - function assertEq(bytes32 left, bytes32 right, string calldata error) external pure; - - /// Asserts that the given condition is false. - function assertFalse(bool condition) external pure; - - /// Asserts that the given condition is false and includes error message into revert string on failure. - function assertFalse(bool condition, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than or equal to second. - /// Formats values with decimals in failure message. - function assertGeDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than or equal to second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertGeDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be greater than or equal to second. - /// Formats values with decimals in failure message. - function assertGeDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects first value to be greater than or equal to second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertGeDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than or equal to second. - function assertGe(uint256 left, uint256 right) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than or equal to second. - /// Includes error message into revert string on failure. - function assertGe(uint256 left, uint256 right, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be greater than or equal to second. - function assertGe(int256 left, int256 right) external pure; - - /// Compares two `int256` values. Expects first value to be greater than or equal to second. - /// Includes error message into revert string on failure. - function assertGe(int256 left, int256 right, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than second. - /// Formats values with decimals in failure message. - function assertGtDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertGtDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be greater than second. - /// Formats values with decimals in failure message. - function assertGtDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects first value to be greater than second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertGtDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than second. - function assertGt(uint256 left, uint256 right) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than second. - /// Includes error message into revert string on failure. - function assertGt(uint256 left, uint256 right, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be greater than second. - function assertGt(int256 left, int256 right) external pure; - - /// Compares two `int256` values. Expects first value to be greater than second. - /// Includes error message into revert string on failure. - function assertGt(int256 left, int256 right, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be less than or equal to second. - /// Formats values with decimals in failure message. - function assertLeDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects first value to be less than or equal to second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertLeDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be less than or equal to second. - /// Formats values with decimals in failure message. - function assertLeDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects first value to be less than or equal to second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertLeDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be less than or equal to second. - function assertLe(uint256 left, uint256 right) external pure; - - /// Compares two `uint256` values. Expects first value to be less than or equal to second. - /// Includes error message into revert string on failure. - function assertLe(uint256 left, uint256 right, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be less than or equal to second. - function assertLe(int256 left, int256 right) external pure; - - /// Compares two `int256` values. Expects first value to be less than or equal to second. - /// Includes error message into revert string on failure. - function assertLe(int256 left, int256 right, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be less than second. - /// Formats values with decimals in failure message. - function assertLtDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects first value to be less than second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertLtDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be less than second. - /// Formats values with decimals in failure message. - function assertLtDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects first value to be less than second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertLtDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be less than second. - function assertLt(uint256 left, uint256 right) external pure; - - /// Compares two `uint256` values. Expects first value to be less than second. - /// Includes error message into revert string on failure. - function assertLt(uint256 left, uint256 right, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be less than second. - function assertLt(int256 left, int256 right) external pure; - - /// Compares two `int256` values. Expects first value to be less than second. - /// Includes error message into revert string on failure. - function assertLt(int256 left, int256 right, string calldata error) external pure; - - /// Asserts that two `uint256` values are not equal, formatting them with decimals in failure message. - function assertNotEqDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Asserts that two `uint256` values are not equal, formatting them with decimals in failure message. - /// Includes error message into revert string on failure. - function assertNotEqDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Asserts that two `int256` values are not equal, formatting them with decimals in failure message. - function assertNotEqDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Asserts that two `int256` values are not equal, formatting them with decimals in failure message. - /// Includes error message into revert string on failure. - function assertNotEqDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Asserts that two `bool` values are not equal. - function assertNotEq(bool left, bool right) external pure; - - /// Asserts that two `bool` values are not equal and includes error message into revert string on failure. - function assertNotEq(bool left, bool right, string calldata error) external pure; - - /// Asserts that two `string` values are not equal. - function assertNotEq(string calldata left, string calldata right) external pure; - - /// Asserts that two `string` values are not equal and includes error message into revert string on failure. - function assertNotEq(string calldata left, string calldata right, string calldata error) external pure; - - /// Asserts that two `bytes` values are not equal. - function assertNotEq(bytes calldata left, bytes calldata right) external pure; - - /// Asserts that two `bytes` values are not equal and includes error message into revert string on failure. - function assertNotEq(bytes calldata left, bytes calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bool` values are not equal. - function assertNotEq(bool[] calldata left, bool[] calldata right) external pure; - - /// Asserts that two arrays of `bool` values are not equal and includes error message into revert string on failure. - function assertNotEq(bool[] calldata left, bool[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `uint256` values are not equal. - function assertNotEq(uint256[] calldata left, uint256[] calldata right) external pure; - - /// Asserts that two arrays of `uint256` values are not equal and includes error message into revert string on failure. - function assertNotEq(uint256[] calldata left, uint256[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `int256` values are not equal. - function assertNotEq(int256[] calldata left, int256[] calldata right) external pure; - - /// Asserts that two arrays of `int256` values are not equal and includes error message into revert string on failure. - function assertNotEq(int256[] calldata left, int256[] calldata right, string calldata error) external pure; - - /// Asserts that two `uint256` values are not equal. - function assertNotEq(uint256 left, uint256 right) external pure; - - /// Asserts that two arrays of `address` values are not equal. - function assertNotEq(address[] calldata left, address[] calldata right) external pure; - - /// Asserts that two arrays of `address` values are not equal and includes error message into revert string on failure. - function assertNotEq(address[] calldata left, address[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bytes32` values are not equal. - function assertNotEq(bytes32[] calldata left, bytes32[] calldata right) external pure; - - /// Asserts that two arrays of `bytes32` values are not equal and includes error message into revert string on failure. - function assertNotEq(bytes32[] calldata left, bytes32[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `string` values are not equal. - function assertNotEq(string[] calldata left, string[] calldata right) external pure; - - /// Asserts that two arrays of `string` values are not equal and includes error message into revert string on failure. - function assertNotEq(string[] calldata left, string[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bytes` values are not equal. - function assertNotEq(bytes[] calldata left, bytes[] calldata right) external pure; - - /// Asserts that two arrays of `bytes` values are not equal and includes error message into revert string on failure. - function assertNotEq(bytes[] calldata left, bytes[] calldata right, string calldata error) external pure; - - /// Asserts that two `uint256` values are not equal and includes error message into revert string on failure. - function assertNotEq(uint256 left, uint256 right, string calldata error) external pure; - - /// Asserts that two `int256` values are not equal. - function assertNotEq(int256 left, int256 right) external pure; - - /// Asserts that two `int256` values are not equal and includes error message into revert string on failure. - function assertNotEq(int256 left, int256 right, string calldata error) external pure; - - /// Asserts that two `address` values are not equal. - function assertNotEq(address left, address right) external pure; - - /// Asserts that two `address` values are not equal and includes error message into revert string on failure. - function assertNotEq(address left, address right, string calldata error) external pure; - - /// Asserts that two `bytes32` values are not equal. - function assertNotEq(bytes32 left, bytes32 right) external pure; - - /// Asserts that two `bytes32` values are not equal and includes error message into revert string on failure. - function assertNotEq(bytes32 left, bytes32 right, string calldata error) external pure; - - /// Asserts that the given condition is true. - function assertTrue(bool condition) external pure; - - /// Asserts that the given condition is true and includes error message into revert string on failure. - function assertTrue(bool condition, string calldata error) external pure; - - /// If the condition is false, discard this run's fuzz inputs and generate new ones. - function assume(bool condition) external pure; - - /// Discard this run's fuzz inputs and generate new ones if next call reverted. - function assumeNoRevert() external pure; - - /// Discard this run's fuzz inputs and generate new ones if next call reverts with the potential revert parameters. - function assumeNoRevert(PotentialRevert calldata potentialRevert) external pure; - - /// Discard this run's fuzz inputs and generate new ones if next call reverts with the any of the potential revert parameters. - function assumeNoRevert(PotentialRevert[] calldata potentialReverts) external pure; - - /// Writes a breakpoint to jump to in the debugger. - function breakpoint(string calldata char) external pure; - - /// Writes a conditional breakpoint to jump to in the debugger. - function breakpoint(string calldata char, bool value) external pure; - - /// Returns true if the current Foundry version is greater than or equal to the given version. - /// The given version string must be in the format `major.minor.patch`. - /// This is equivalent to `foundryVersionCmp(version) >= 0`. - function foundryVersionAtLeast(string calldata version) external view returns (bool); - - /// Compares the current Foundry version with the given version string. - /// The given version string must be in the format `major.minor.patch`. - /// Returns: - /// -1 if current Foundry version is less than the given version - /// 0 if current Foundry version equals the given version - /// 1 if current Foundry version is greater than the given version - /// This result can then be used with a comparison operator against `0`. - /// For example, to check if the current Foundry version is greater than or equal to `1.0.0`: - /// `if (foundryVersionCmp("1.0.0") >= 0) { ... }` - function foundryVersionCmp(string calldata version) external view returns (int256); - - /// Returns a Chain struct for specific alias - function getChain(string calldata chainAlias) external view returns (Chain memory chain); - - /// Returns a Chain struct for specific chainId - function getChain(uint256 chainId) external view returns (Chain memory chain); - - /// Returns the Foundry version. - /// Format: -+.. - /// Sample output: 0.3.0-nightly+3cb96bde9b.1737036656.debug - /// Note: Build timestamps may vary slightly across platforms due to separate CI jobs. - /// For reliable version comparisons, use UNIX format (e.g., >= 1700000000) - /// to compare timestamps while ignoring minor time differences. - function getFoundryVersion() external view returns (string memory version); - - /// Returns the RPC url for the given alias. - function rpcUrl(string calldata rpcAlias) external view returns (string memory json); - - /// Returns all rpc urls and their aliases as structs. - function rpcUrlStructs() external view returns (Rpc[] memory urls); - - /// Returns all rpc urls and their aliases `[alias, url][]`. - function rpcUrls() external view returns (string[2][] memory urls); - - /// Suspends execution of the main thread for `duration` milliseconds. - function sleep(uint256 duration) external; - - // ======== Toml ======== - - /// Checks if `key` exists in a TOML table. - function keyExistsToml(string calldata toml, string calldata key) external view returns (bool); - - /// Parses a string of TOML data at `key` and coerces it to `address`. - function parseTomlAddress(string calldata toml, string calldata key) external pure returns (address); - - /// Parses a string of TOML data at `key` and coerces it to `address[]`. - function parseTomlAddressArray(string calldata toml, string calldata key) - external - pure - returns (address[] memory); - - /// Parses a string of TOML data at `key` and coerces it to `bool`. - function parseTomlBool(string calldata toml, string calldata key) external pure returns (bool); - - /// Parses a string of TOML data at `key` and coerces it to `bool[]`. - function parseTomlBoolArray(string calldata toml, string calldata key) external pure returns (bool[] memory); - - /// Parses a string of TOML data at `key` and coerces it to `bytes`. - function parseTomlBytes(string calldata toml, string calldata key) external pure returns (bytes memory); - - /// Parses a string of TOML data at `key` and coerces it to `bytes32`. - function parseTomlBytes32(string calldata toml, string calldata key) external pure returns (bytes32); - - /// Parses a string of TOML data at `key` and coerces it to `bytes32[]`. - function parseTomlBytes32Array(string calldata toml, string calldata key) - external - pure - returns (bytes32[] memory); - - /// Parses a string of TOML data at `key` and coerces it to `bytes[]`. - function parseTomlBytesArray(string calldata toml, string calldata key) external pure returns (bytes[] memory); - - /// Parses a string of TOML data at `key` and coerces it to `int256`. - function parseTomlInt(string calldata toml, string calldata key) external pure returns (int256); - - /// Parses a string of TOML data at `key` and coerces it to `int256[]`. - function parseTomlIntArray(string calldata toml, string calldata key) external pure returns (int256[] memory); - - /// Returns an array of all the keys in a TOML table. - function parseTomlKeys(string calldata toml, string calldata key) external pure returns (string[] memory keys); - - /// Parses a string of TOML data at `key` and coerces it to `string`. - function parseTomlString(string calldata toml, string calldata key) external pure returns (string memory); - - /// Parses a string of TOML data at `key` and coerces it to `string[]`. - function parseTomlStringArray(string calldata toml, string calldata key) external pure returns (string[] memory); - - /// Parses a string of TOML data at `key` and coerces it to type array corresponding to `typeDescription`. - function parseTomlTypeArray(string calldata toml, string calldata key, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of TOML data and coerces it to type corresponding to `typeDescription`. - function parseTomlType(string calldata toml, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of TOML data at `key` and coerces it to type corresponding to `typeDescription`. - function parseTomlType(string calldata toml, string calldata key, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of TOML data at `key` and coerces it to `uint256`. - function parseTomlUint(string calldata toml, string calldata key) external pure returns (uint256); - - /// Parses a string of TOML data at `key` and coerces it to `uint256[]`. - function parseTomlUintArray(string calldata toml, string calldata key) external pure returns (uint256[] memory); - - /// ABI-encodes a TOML table. - function parseToml(string calldata toml) external pure returns (bytes memory abiEncodedData); - - /// ABI-encodes a TOML table at `key`. - function parseToml(string calldata toml, string calldata key) external pure returns (bytes memory abiEncodedData); - - /// Takes serialized JSON, converts to TOML and write a serialized TOML to a file. - function writeToml(string calldata json, string calldata path) external; - - /// Takes serialized JSON, converts to TOML and write a serialized TOML table to an **existing** TOML file, replacing a value with key = - /// This is useful to replace a specific value of a TOML file, without having to parse the entire thing. - /// This cheatcode will create new keys if they didn't previously exist. - function writeToml(string calldata json, string calldata path, string calldata valueKey) external; - - // ======== Utilities ======== - - /// Returns an uint256 value bounded in given range and different from the current one. - function bound(uint256 current, uint256 min, uint256 max) external view returns (uint256); - - /// Returns an int256 value bounded in given range and different from the current one. - function bound(int256 current, int256 min, int256 max) external view returns (int256); - - /// Compute the address of a contract created with CREATE2 using the given CREATE2 deployer. - function computeCreate2Address(bytes32 salt, bytes32 initCodeHash, address deployer) - external - pure - returns (address); - - /// Compute the address of a contract created with CREATE2 using the default CREATE2 deployer. - function computeCreate2Address(bytes32 salt, bytes32 initCodeHash) external pure returns (address); - - /// Compute the address a contract will be deployed at for a given deployer address and nonce. - function computeCreateAddress(address deployer, uint256 nonce) external pure returns (address); - - /// Utility cheatcode to copy storage of `from` contract to another `to` contract. - function copyStorage(address from, address to) external; - - /// Generates the struct hash of the canonical EIP-712 type representation and its abi-encoded data. - /// Supports 2 different inputs: - /// 1. Name of the type (i.e. "PermitSingle"): - /// * requires previous binding generation with `forge bind-json`. - /// * bindings will be retrieved from the path configured in `foundry.toml`. - /// 2. String representation of the type (i.e. "Foo(Bar bar) Bar(uint256 baz)"). - /// * Note: the cheatcode will use the canonical type even if the input is malformated - /// with the wrong order of elements or with extra whitespaces. - function eip712HashStruct(string calldata typeNameOrDefinition, bytes calldata abiEncodedData) - external - pure - returns (bytes32 typeHash); - - /// Generates the struct hash of the canonical EIP-712 type representation and its abi-encoded data. - /// Requires previous binding generation with `forge bind-json`. - /// Params: - /// * `bindingsPath`: path where the output of `forge bind-json` is stored. - /// * `typeName`: Name of the type (i.e. "PermitSingle"). - /// * `abiEncodedData`: ABI-encoded data for the struct that is being hashed. - function eip712HashStruct(string calldata bindingsPath, string calldata typeName, bytes calldata abiEncodedData) - external - pure - returns (bytes32 typeHash); - - /// Generates the hash of the canonical EIP-712 type representation. - /// Supports 2 different inputs: - /// 1. Name of the type (i.e. "Transaction"): - /// * requires previous binding generation with `forge bind-json`. - /// * bindings will be retrieved from the path configured in `foundry.toml`. - /// 2. String representation of the type (i.e. "Foo(Bar bar) Bar(uint256 baz)"). - /// * Note: the cheatcode will output the canonical type even if the input is malformated - /// with the wrong order of elements or with extra whitespaces. - function eip712HashType(string calldata typeNameOrDefinition) external pure returns (bytes32 typeHash); - - /// Generates the hash of the canonical EIP-712 type representation. - /// Requires previous binding generation with `forge bind-json`. - /// Params: - /// * `bindingsPath`: path where the output of `forge bind-json` is stored. - /// * `typeName`: Name of the type (i.e. "Transaction"). - function eip712HashType(string calldata bindingsPath, string calldata typeName) - external - pure - returns (bytes32 typeHash); - - /// Generates a ready-to-sign digest of human-readable typed data following the EIP-712 standard. - function eip712HashTypedData(string calldata jsonData) external pure returns (bytes32 digest); - - /// Returns ENS namehash for provided string. - function ensNamehash(string calldata name) external pure returns (bytes32); - - /// Gets the label for the specified address. - function getLabel(address account) external view returns (string memory currentLabel); - - /// Labels an address in call traces. - function label(address account, string calldata newLabel) external; - - /// Pauses collection of call traces. Useful in cases when you want to skip tracing of - /// complex calls which are not useful for debugging. - function pauseTracing() external view; - - /// Returns a random `address`. - function randomAddress() external view returns (address); - - /// Returns a random `bool`. - function randomBool() external view returns (bool); - - /// Returns a random byte array value of the given length. - function randomBytes(uint256 len) external view returns (bytes memory); - - /// Returns a random fixed-size byte array of length 4. - function randomBytes4() external view returns (bytes4); - - /// Returns a random fixed-size byte array of length 8. - function randomBytes8() external view returns (bytes8); - - /// Returns a random `int256` value. - function randomInt() external view returns (int256); - - /// Returns a random `int256` value of given bits. - function randomInt(uint256 bits) external view returns (int256); - - /// Returns a random uint256 value. - function randomUint() external view returns (uint256); - - /// Returns random uint256 value between the provided range (=min..=max). - function randomUint(uint256 min, uint256 max) external view returns (uint256); - - /// Returns a random `uint256` value of given bits. - function randomUint(uint256 bits) external view returns (uint256); - - /// Unpauses collection of call traces. - function resumeTracing() external view; - - /// Utility cheatcode to set arbitrary storage for given target address. - function setArbitraryStorage(address target) external; - - /// Utility cheatcode to set arbitrary storage for given target address and overwrite - /// any storage slots that have been previously set. - function setArbitraryStorage(address target, bool overwrite) external; - - /// Set RNG seed. - function setSeed(uint256 seed) external; - - /// Randomly shuffles an array. - function shuffle(uint256[] calldata array) external returns (uint256[] memory); - - /// Sorts an array in ascending order. - function sort(uint256[] calldata array) external returns (uint256[] memory); - - /// Encodes a `bytes` value to a base64url string. - function toBase64URL(bytes calldata data) external pure returns (string memory); - - /// Encodes a `string` value to a base64url string. - function toBase64URL(string calldata data) external pure returns (string memory); - - /// Encodes a `bytes` value to a base64 string. - function toBase64(bytes calldata data) external pure returns (string memory); - - /// Encodes a `string` value to a base64 string. - function toBase64(string calldata data) external pure returns (string memory); -} - -/// The `Vm` interface does allow manipulation of the EVM state. These are all intended to be used -/// in tests, but it is not recommended to use these cheats in scripts. -interface Vm is VmSafe { - // ======== EVM ======== - - /// Utility cheatcode to set an EIP-2930 access list for all subsequent transactions. - function accessList(AccessListItem[] calldata access) external; - - /// Returns the identifier of the currently active fork. Reverts if no fork is currently active. - function activeFork() external view returns (uint256 forkId); - - /// In forking mode, explicitly grant the given address cheatcode access. - function allowCheatcodes(address account) external; - - /// Sets `block.blobbasefee` - function blobBaseFee(uint256 newBlobBaseFee) external; - - /// Sets the blobhashes in the transaction. - /// Not available on EVM versions before Cancun. - /// If used on unsupported EVM versions it will revert. - function blobhashes(bytes32[] calldata hashes) external; - - /// Sets `block.chainid`. - function chainId(uint256 newChainId) external; - - /// Clears all mocked calls. - function clearMockedCalls() external; - - /// Clones a source account code, state, balance and nonce to a target account and updates in-memory EVM state. - function cloneAccount(address source, address target) external; - - /// Sets `block.coinbase`. - function coinbase(address newCoinbase) external; - - /// Marks the slots of an account and the account address as cold. - function cool(address target) external; - - /// Utility cheatcode to mark specific storage slot as cold, simulating no prior read. - function coolSlot(address target, bytes32 slot) external; - - /// Creates a new fork with the given endpoint and the _latest_ block and returns the identifier of the fork. - function createFork(string calldata urlOrAlias) external returns (uint256 forkId); - - /// Creates a new fork with the given endpoint and block and returns the identifier of the fork. - function createFork(string calldata urlOrAlias, uint256 blockNumber) external returns (uint256 forkId); - - /// Creates a new fork with the given endpoint and at the block the given transaction was mined in, - /// replays all transaction mined in the block before the transaction, and returns the identifier of the fork. - function createFork(string calldata urlOrAlias, bytes32 txHash) external returns (uint256 forkId); - - /// Creates and also selects a new fork with the given endpoint and the latest block and returns the identifier of the fork. - function createSelectFork(string calldata urlOrAlias) external returns (uint256 forkId); - - /// Creates and also selects a new fork with the given endpoint and block and returns the identifier of the fork. - function createSelectFork(string calldata urlOrAlias, uint256 blockNumber) external returns (uint256 forkId); - - /// Creates and also selects new fork with the given endpoint and at the block the given transaction was mined in, - /// replays all transaction mined in the block before the transaction, returns the identifier of the fork. - function createSelectFork(string calldata urlOrAlias, bytes32 txHash) external returns (uint256 forkId); - - /// Sets an address' balance. - function deal(address account, uint256 newBalance) external; - - /// Removes the snapshot with the given ID created by `snapshot`. - /// Takes the snapshot ID to delete. - /// Returns `true` if the snapshot was successfully deleted. - /// Returns `false` if the snapshot does not exist. - function deleteStateSnapshot(uint256 snapshotId) external returns (bool success); - - /// Removes _all_ snapshots previously created by `snapshot`. - function deleteStateSnapshots() external; - - /// Sets `block.difficulty`. - /// Not available on EVM versions from Paris onwards. Use `prevrandao` instead. - /// Reverts if used on unsupported EVM versions. - function difficulty(uint256 newDifficulty) external; - - /// Dump a genesis JSON file's `allocs` to disk. - function dumpState(string calldata pathToStateJson) external; - - /// Sets an address' code. - function etch(address target, bytes calldata newRuntimeBytecode) external; - - /// Sets `block.basefee`. - function fee(uint256 newBasefee) external; - - /// Gets the blockhashes from the current transaction. - /// Not available on EVM versions before Cancun. - /// If used on unsupported EVM versions it will revert. - function getBlobhashes() external view returns (bytes32[] memory hashes); - - /// Returns true if the account is marked as persistent. - function isPersistent(address account) external view returns (bool persistent); - - /// Load a genesis JSON file's `allocs` into the in-memory EVM state. - function loadAllocs(string calldata pathToAllocsJson) external; - - /// Marks that the account(s) should use persistent storage across fork swaps in a multifork setup - /// Meaning, changes made to the state of this account will be kept when switching forks. - function makePersistent(address account) external; - - /// See `makePersistent(address)`. - function makePersistent(address account0, address account1) external; - - /// See `makePersistent(address)`. - function makePersistent(address account0, address account1, address account2) external; - - /// See `makePersistent(address)`. - function makePersistent(address[] calldata accounts) external; - - /// Reverts a call to an address with specified revert data. - function mockCallRevert(address callee, bytes calldata data, bytes calldata revertData) external; - - /// Reverts a call to an address with a specific `msg.value`, with specified revert data. - function mockCallRevert(address callee, uint256 msgValue, bytes calldata data, bytes calldata revertData) - external; - - /// Reverts a call to an address with specified revert data. - /// Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`. - function mockCallRevert(address callee, bytes4 data, bytes calldata revertData) external; - - /// Reverts a call to an address with a specific `msg.value`, with specified revert data. - /// Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`. - function mockCallRevert(address callee, uint256 msgValue, bytes4 data, bytes calldata revertData) external; - - /// Mocks a call to an address, returning specified data. - /// Calldata can either be strict or a partial match, e.g. if you only - /// pass a Solidity selector to the expected calldata, then the entire Solidity - /// function will be mocked. - function mockCall(address callee, bytes calldata data, bytes calldata returnData) external; - - /// Mocks a call to an address with a specific `msg.value`, returning specified data. - /// Calldata match takes precedence over `msg.value` in case of ambiguity. - function mockCall(address callee, uint256 msgValue, bytes calldata data, bytes calldata returnData) external; - - /// Mocks a call to an address, returning specified data. - /// Calldata can either be strict or a partial match, e.g. if you only - /// pass a Solidity selector to the expected calldata, then the entire Solidity - /// function will be mocked. - /// Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`. - function mockCall(address callee, bytes4 data, bytes calldata returnData) external; - - /// Mocks a call to an address with a specific `msg.value`, returning specified data. - /// Calldata match takes precedence over `msg.value` in case of ambiguity. - /// Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`. - function mockCall(address callee, uint256 msgValue, bytes4 data, bytes calldata returnData) external; - - /// Mocks multiple calls to an address, returning specified data for each call. - function mockCalls(address callee, bytes calldata data, bytes[] calldata returnData) external; - - /// Mocks multiple calls to an address with a specific `msg.value`, returning specified data for each call. - function mockCalls(address callee, uint256 msgValue, bytes calldata data, bytes[] calldata returnData) external; - - /// Whenever a call is made to `callee` with calldata `data`, this cheatcode instead calls - /// `target` with the same calldata. This functionality is similar to a delegate call made to - /// `target` contract from `callee`. - /// Can be used to substitute a call to a function with another implementation that captures - /// the primary logic of the original function but is easier to reason about. - /// If calldata is not a strict match then partial match by selector is attempted. - function mockFunction(address callee, address target, bytes calldata data) external; - - /// Utility cheatcode to remove any EIP-2930 access list set by `accessList` cheatcode. - function noAccessList() external; - - /// Sets the *next* call's `msg.sender` to be the input address. - function prank(address msgSender) external; - - /// Sets the *next* call's `msg.sender` to be the input address, and the `tx.origin` to be the second input. - function prank(address msgSender, address txOrigin) external; - - /// Sets the *next* delegate call's `msg.sender` to be the input address. - function prank(address msgSender, bool delegateCall) external; - - /// Sets the *next* delegate call's `msg.sender` to be the input address, and the `tx.origin` to be the second input. - function prank(address msgSender, address txOrigin, bool delegateCall) external; - - /// Sets `block.prevrandao`. - /// Not available on EVM versions before Paris. Use `difficulty` instead. - /// If used on unsupported EVM versions it will revert. - function prevrandao(bytes32 newPrevrandao) external; - - /// Sets `block.prevrandao`. - /// Not available on EVM versions before Paris. Use `difficulty` instead. - /// If used on unsupported EVM versions it will revert. - function prevrandao(uint256 newPrevrandao) external; - - /// Reads the current `msg.sender` and `tx.origin` from state and reports if there is any active caller modification. - function readCallers() external view returns (CallerMode callerMode, address msgSender, address txOrigin); - - /// Resets the nonce of an account to 0 for EOAs and 1 for contract accounts. - function resetNonce(address account) external; - - /// Revert the state of the EVM to a previous snapshot - /// Takes the snapshot ID to revert to. - /// Returns `true` if the snapshot was successfully reverted. - /// Returns `false` if the snapshot does not exist. - /// **Note:** This does not automatically delete the snapshot. To delete the snapshot use `deleteStateSnapshot`. - function revertToState(uint256 snapshotId) external returns (bool success); - - /// Revert the state of the EVM to a previous snapshot and automatically deletes the snapshots - /// Takes the snapshot ID to revert to. - /// Returns `true` if the snapshot was successfully reverted and deleted. - /// Returns `false` if the snapshot does not exist. - function revertToStateAndDelete(uint256 snapshotId) external returns (bool success); - - /// Revokes persistent status from the address, previously added via `makePersistent`. - function revokePersistent(address account) external; - - /// See `revokePersistent(address)`. - function revokePersistent(address[] calldata accounts) external; - - /// Sets `block.height`. - function roll(uint256 newHeight) external; - - /// Updates the currently active fork to given block number - /// This is similar to `roll` but for the currently active fork. - function rollFork(uint256 blockNumber) external; - - /// Updates the currently active fork to given transaction. This will `rollFork` with the number - /// of the block the transaction was mined in and replays all transaction mined before it in the block. - function rollFork(bytes32 txHash) external; - - /// Updates the given fork to given block number. - function rollFork(uint256 forkId, uint256 blockNumber) external; - - /// Updates the given fork to block number of the given transaction and replays all transaction mined before it in the block. - function rollFork(uint256 forkId, bytes32 txHash) external; - - /// Takes a fork identifier created by `createFork` and sets the corresponding forked state as active. - function selectFork(uint256 forkId) external; - - /// Set blockhash for the current block. - /// It only sets the blockhash for blocks where `block.number - 256 <= number < block.number`. - function setBlockhash(uint256 blockNumber, bytes32 blockHash) external; - - /// Sets the nonce of an account. Must be higher than the current nonce of the account. - function setNonce(address account, uint64 newNonce) external; - - /// Sets the nonce of an account to an arbitrary value. - function setNonceUnsafe(address account, uint64 newNonce) external; - - /// Snapshot capture the gas usage of the last call by name from the callee perspective. - function snapshotGasLastCall(string calldata name) external returns (uint256 gasUsed); - - /// Snapshot capture the gas usage of the last call by name in a group from the callee perspective. - function snapshotGasLastCall(string calldata group, string calldata name) external returns (uint256 gasUsed); - - /// Snapshot the current state of the evm. - /// Returns the ID of the snapshot that was created. - /// To revert a snapshot use `revertToState`. - function snapshotState() external returns (uint256 snapshotId); - - /// Snapshot capture an arbitrary numerical value by name. - /// The group name is derived from the contract name. - function snapshotValue(string calldata name, uint256 value) external; - - /// Snapshot capture an arbitrary numerical value by name in a group. - function snapshotValue(string calldata group, string calldata name, uint256 value) external; - - /// Sets all subsequent calls' `msg.sender` to be the input address until `stopPrank` is called. - function startPrank(address msgSender) external; - - /// Sets all subsequent calls' `msg.sender` to be the input address until `stopPrank` is called, and the `tx.origin` to be the second input. - function startPrank(address msgSender, address txOrigin) external; - - /// Sets all subsequent delegate calls' `msg.sender` to be the input address until `stopPrank` is called. - function startPrank(address msgSender, bool delegateCall) external; - - /// Sets all subsequent delegate calls' `msg.sender` to be the input address until `stopPrank` is called, and the `tx.origin` to be the second input. - function startPrank(address msgSender, address txOrigin, bool delegateCall) external; - - /// Start a snapshot capture of the current gas usage by name. - /// The group name is derived from the contract name. - function startSnapshotGas(string calldata name) external; - - /// Start a snapshot capture of the current gas usage by name in a group. - function startSnapshotGas(string calldata group, string calldata name) external; - - /// Resets subsequent calls' `msg.sender` to be `address(this)`. - function stopPrank() external; - - /// Stop the snapshot capture of the current gas by latest snapshot name, capturing the gas used since the start. - function stopSnapshotGas() external returns (uint256 gasUsed); - - /// Stop the snapshot capture of the current gas usage by name, capturing the gas used since the start. - /// The group name is derived from the contract name. - function stopSnapshotGas(string calldata name) external returns (uint256 gasUsed); - - /// Stop the snapshot capture of the current gas usage by name in a group, capturing the gas used since the start. - function stopSnapshotGas(string calldata group, string calldata name) external returns (uint256 gasUsed); - - /// Stores a value to an address' storage slot. - function store(address target, bytes32 slot, bytes32 value) external; - - /// Fetches the given transaction from the active fork and executes it on the current state. - function transact(bytes32 txHash) external; - - /// Fetches the given transaction from the given fork and executes it on the current state. - function transact(uint256 forkId, bytes32 txHash) external; - - /// Sets `tx.gasprice`. - function txGasPrice(uint256 newGasPrice) external; - - /// Utility cheatcode to mark specific storage slot as warm, simulating a prior read. - function warmSlot(address target, bytes32 slot) external; - - /// Sets `block.timestamp`. - function warp(uint256 newTimestamp) external; - - /// `deleteSnapshot` is being deprecated in favor of `deleteStateSnapshot`. It will be removed in future versions. - function deleteSnapshot(uint256 snapshotId) external returns (bool success); - - /// `deleteSnapshots` is being deprecated in favor of `deleteStateSnapshots`. It will be removed in future versions. - function deleteSnapshots() external; - - /// `revertToAndDelete` is being deprecated in favor of `revertToStateAndDelete`. It will be removed in future versions. - function revertToAndDelete(uint256 snapshotId) external returns (bool success); - - /// `revertTo` is being deprecated in favor of `revertToState`. It will be removed in future versions. - function revertTo(uint256 snapshotId) external returns (bool success); - - /// `snapshot` is being deprecated in favor of `snapshotState`. It will be removed in future versions. - function snapshot() external returns (uint256 snapshotId); - - // ======== Testing ======== - - /// Expect a call to an address with the specified `msg.value` and calldata, and a *minimum* amount of gas. - function expectCallMinGas(address callee, uint256 msgValue, uint64 minGas, bytes calldata data) external; - - /// Expect given number of calls to an address with the specified `msg.value` and calldata, and a *minimum* amount of gas. - function expectCallMinGas(address callee, uint256 msgValue, uint64 minGas, bytes calldata data, uint64 count) - external; - - /// Expects a call to an address with the specified calldata. - /// Calldata can either be a strict or a partial match. - function expectCall(address callee, bytes calldata data) external; - - /// Expects given number of calls to an address with the specified calldata. - function expectCall(address callee, bytes calldata data, uint64 count) external; - - /// Expects a call to an address with the specified `msg.value` and calldata. - function expectCall(address callee, uint256 msgValue, bytes calldata data) external; - - /// Expects given number of calls to an address with the specified `msg.value` and calldata. - function expectCall(address callee, uint256 msgValue, bytes calldata data, uint64 count) external; - - /// Expect a call to an address with the specified `msg.value`, gas, and calldata. - function expectCall(address callee, uint256 msgValue, uint64 gas, bytes calldata data) external; - - /// Expects given number of calls to an address with the specified `msg.value`, gas, and calldata. - function expectCall(address callee, uint256 msgValue, uint64 gas, bytes calldata data, uint64 count) external; - - /// Expects the deployment of the specified bytecode by the specified address using the CREATE opcode - function expectCreate(bytes calldata bytecode, address deployer) external; - - /// Expects the deployment of the specified bytecode by the specified address using the CREATE2 opcode - function expectCreate2(bytes calldata bytecode, address deployer) external; - - /// Prepare an expected anonymous log with (bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData.). - /// Call this function, then emit an anonymous event, then call a function. Internally after the call, we check if - /// logs were emitted in the expected order with the expected topics and data (as specified by the booleans). - function expectEmitAnonymous(bool checkTopic0, bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData) - external; - - /// Same as the previous method, but also checks supplied address against emitting contract. - function expectEmitAnonymous( - bool checkTopic0, - bool checkTopic1, - bool checkTopic2, - bool checkTopic3, - bool checkData, - address emitter - ) external; - - /// Prepare an expected anonymous log with all topic and data checks enabled. - /// Call this function, then emit an anonymous event, then call a function. Internally after the call, we check if - /// logs were emitted in the expected order with the expected topics and data. - function expectEmitAnonymous() external; - - /// Same as the previous method, but also checks supplied address against emitting contract. - function expectEmitAnonymous(address emitter) external; - - /// Prepare an expected log with (bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData.). - /// Call this function, then emit an event, then call a function. Internally after the call, we check if - /// logs were emitted in the expected order with the expected topics and data (as specified by the booleans). - function expectEmit(bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData) external; - - /// Same as the previous method, but also checks supplied address against emitting contract. - function expectEmit(bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData, address emitter) - external; - - /// Prepare an expected log with all topic and data checks enabled. - /// Call this function, then emit an event, then call a function. Internally after the call, we check if - /// logs were emitted in the expected order with the expected topics and data. - function expectEmit() external; - - /// Same as the previous method, but also checks supplied address against emitting contract. - function expectEmit(address emitter) external; - - /// Expect a given number of logs with the provided topics. - function expectEmit(bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData, uint64 count) external; - - /// Expect a given number of logs from a specific emitter with the provided topics. - function expectEmit( - bool checkTopic1, - bool checkTopic2, - bool checkTopic3, - bool checkData, - address emitter, - uint64 count - ) external; - - /// Expect a given number of logs with all topic and data checks enabled. - function expectEmit(uint64 count) external; - - /// Expect a given number of logs from a specific emitter with all topic and data checks enabled. - function expectEmit(address emitter, uint64 count) external; - - /// Expects an error on next call that starts with the revert data. - function expectPartialRevert(bytes4 revertData) external; - - /// Expects an error on next call to reverter address, that starts with the revert data. - function expectPartialRevert(bytes4 revertData, address reverter) external; - - /// Expects an error on next call with any revert data. - function expectRevert() external; - - /// Expects an error on next call that exactly matches the revert data. - function expectRevert(bytes4 revertData) external; - - /// Expects a `count` number of reverts from the upcoming calls from the reverter address that match the revert data. - function expectRevert(bytes4 revertData, address reverter, uint64 count) external; - - /// Expects a `count` number of reverts from the upcoming calls from the reverter address that exactly match the revert data. - function expectRevert(bytes calldata revertData, address reverter, uint64 count) external; - - /// Expects an error on next call that exactly matches the revert data. - function expectRevert(bytes calldata revertData) external; - - /// Expects an error with any revert data on next call to reverter address. - function expectRevert(address reverter) external; - - /// Expects an error from reverter address on next call, with any revert data. - function expectRevert(bytes4 revertData, address reverter) external; - - /// Expects an error from reverter address on next call, that exactly matches the revert data. - function expectRevert(bytes calldata revertData, address reverter) external; - - /// Expects a `count` number of reverts from the upcoming calls with any revert data or reverter. - function expectRevert(uint64 count) external; - - /// Expects a `count` number of reverts from the upcoming calls that match the revert data. - function expectRevert(bytes4 revertData, uint64 count) external; - - /// Expects a `count` number of reverts from the upcoming calls that exactly match the revert data. - function expectRevert(bytes calldata revertData, uint64 count) external; - - /// Expects a `count` number of reverts from the upcoming calls from the reverter address. - function expectRevert(address reverter, uint64 count) external; - - /// Only allows memory writes to offsets [0x00, 0x60) ∪ [min, max) in the current subcontext. If any other - /// memory is written to, the test will fail. Can be called multiple times to add more ranges to the set. - function expectSafeMemory(uint64 min, uint64 max) external; - - /// Only allows memory writes to offsets [0x00, 0x60) ∪ [min, max) in the next created subcontext. - /// If any other memory is written to, the test will fail. Can be called multiple times to add more ranges - /// to the set. - function expectSafeMemoryCall(uint64 min, uint64 max) external; - - /// Marks a test as skipped. Must be called at the top level of a test. - function skip(bool skipTest) external; - - /// Marks a test as skipped with a reason. Must be called at the top level of a test. - function skip(bool skipTest, string calldata reason) external; - - /// Stops all safe memory expectation in the current subcontext. - function stopExpectSafeMemory() external; - - // ======== Utilities ======== - - /// Causes the next contract creation (via new) to fail and return its initcode in the returndata buffer. - /// This allows type-safe access to the initcode payload that would be used for contract creation. - /// Example usage: - /// vm.interceptInitcode(); - /// bytes memory initcode; - /// try new MyContract(param1, param2) { assert(false); } - /// catch (bytes memory interceptedInitcode) { initcode = interceptedInitcode; } - function interceptInitcode() external; -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/console.sol b/lib/signals-implicit-mode/lib/forge-std/src/console.sol deleted file mode 100644 index 4fdb6679ed..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/console.sol +++ /dev/null @@ -1,1560 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.4.22 <0.9.0; - -library console { - address constant CONSOLE_ADDRESS = - 0x000000000000000000636F6e736F6c652e6c6f67; - - function _sendLogPayloadImplementation(bytes memory payload) internal view { - address consoleAddress = CONSOLE_ADDRESS; - /// @solidity memory-safe-assembly - assembly { - pop( - staticcall( - gas(), - consoleAddress, - add(payload, 32), - mload(payload), - 0, - 0 - ) - ) - } - } - - function _castToPure( - function(bytes memory) internal view fnIn - ) internal pure returns (function(bytes memory) pure fnOut) { - assembly { - fnOut := fnIn - } - } - - function _sendLogPayload(bytes memory payload) internal pure { - _castToPure(_sendLogPayloadImplementation)(payload); - } - - function log() internal pure { - _sendLogPayload(abi.encodeWithSignature("log()")); - } - - function logInt(int256 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(int256)", p0)); - } - - function logUint(uint256 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256)", p0)); - } - - function logString(string memory p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string)", p0)); - } - - function logBool(bool p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool)", p0)); - } - - function logAddress(address p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address)", p0)); - } - - function logBytes(bytes memory p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes)", p0)); - } - - function logBytes1(bytes1 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes1)", p0)); - } - - function logBytes2(bytes2 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes2)", p0)); - } - - function logBytes3(bytes3 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes3)", p0)); - } - - function logBytes4(bytes4 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes4)", p0)); - } - - function logBytes5(bytes5 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes5)", p0)); - } - - function logBytes6(bytes6 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes6)", p0)); - } - - function logBytes7(bytes7 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes7)", p0)); - } - - function logBytes8(bytes8 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes8)", p0)); - } - - function logBytes9(bytes9 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes9)", p0)); - } - - function logBytes10(bytes10 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes10)", p0)); - } - - function logBytes11(bytes11 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes11)", p0)); - } - - function logBytes12(bytes12 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes12)", p0)); - } - - function logBytes13(bytes13 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes13)", p0)); - } - - function logBytes14(bytes14 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes14)", p0)); - } - - function logBytes15(bytes15 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes15)", p0)); - } - - function logBytes16(bytes16 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes16)", p0)); - } - - function logBytes17(bytes17 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes17)", p0)); - } - - function logBytes18(bytes18 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes18)", p0)); - } - - function logBytes19(bytes19 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes19)", p0)); - } - - function logBytes20(bytes20 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes20)", p0)); - } - - function logBytes21(bytes21 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes21)", p0)); - } - - function logBytes22(bytes22 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes22)", p0)); - } - - function logBytes23(bytes23 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes23)", p0)); - } - - function logBytes24(bytes24 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes24)", p0)); - } - - function logBytes25(bytes25 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes25)", p0)); - } - - function logBytes26(bytes26 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes26)", p0)); - } - - function logBytes27(bytes27 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes27)", p0)); - } - - function logBytes28(bytes28 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes28)", p0)); - } - - function logBytes29(bytes29 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes29)", p0)); - } - - function logBytes30(bytes30 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes30)", p0)); - } - - function logBytes31(bytes31 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes31)", p0)); - } - - function logBytes32(bytes32 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes32)", p0)); - } - - function log(uint256 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256)", p0)); - } - - function log(int256 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(int256)", p0)); - } - - function log(string memory p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string)", p0)); - } - - function log(bool p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool)", p0)); - } - - function log(address p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address)", p0)); - } - - function log(uint256 p0, uint256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256)", p0, p1)); - } - - function log(uint256 p0, string memory p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string)", p0, p1)); - } - - function log(uint256 p0, bool p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool)", p0, p1)); - } - - function log(uint256 p0, address p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address)", p0, p1)); - } - - function log(string memory p0, uint256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256)", p0, p1)); - } - - function log(string memory p0, int256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,int256)", p0, p1)); - } - - function log(string memory p0, string memory p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string)", p0, p1)); - } - - function log(string memory p0, bool p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool)", p0, p1)); - } - - function log(string memory p0, address p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address)", p0, p1)); - } - - function log(bool p0, uint256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256)", p0, p1)); - } - - function log(bool p0, string memory p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string)", p0, p1)); - } - - function log(bool p0, bool p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool)", p0, p1)); - } - - function log(bool p0, address p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address)", p0, p1)); - } - - function log(address p0, uint256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256)", p0, p1)); - } - - function log(address p0, string memory p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string)", p0, p1)); - } - - function log(address p0, bool p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool)", p0, p1)); - } - - function log(address p0, address p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address)", p0, p1)); - } - - function log(uint256 p0, uint256 p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256)", p0, p1, p2)); - } - - function log(uint256 p0, uint256 p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string)", p0, p1, p2)); - } - - function log(uint256 p0, uint256 p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool)", p0, p1, p2)); - } - - function log(uint256 p0, uint256 p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address)", p0, p1, p2)); - } - - function log(uint256 p0, string memory p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256)", p0, p1, p2)); - } - - function log(uint256 p0, string memory p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string)", p0, p1, p2)); - } - - function log(uint256 p0, string memory p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool)", p0, p1, p2)); - } - - function log(uint256 p0, string memory p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address)", p0, p1, p2)); - } - - function log(uint256 p0, bool p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256)", p0, p1, p2)); - } - - function log(uint256 p0, bool p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string)", p0, p1, p2)); - } - - function log(uint256 p0, bool p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool)", p0, p1, p2)); - } - - function log(uint256 p0, bool p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address)", p0, p1, p2)); - } - - function log(uint256 p0, address p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256)", p0, p1, p2)); - } - - function log(uint256 p0, address p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string)", p0, p1, p2)); - } - - function log(uint256 p0, address p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool)", p0, p1, p2)); - } - - function log(uint256 p0, address p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address)", p0, p1, p2)); - } - - function log(string memory p0, uint256 p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256)", p0, p1, p2)); - } - - function log(string memory p0, uint256 p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string)", p0, p1, p2)); - } - - function log(string memory p0, uint256 p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool)", p0, p1, p2)); - } - - function log(string memory p0, uint256 p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address)", p0, p1, p2)); - } - - function log(string memory p0, string memory p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256)", p0, p1, p2)); - } - - function log(string memory p0, string memory p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string)", p0, p1, p2)); - } - - function log(string memory p0, string memory p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool)", p0, p1, p2)); - } - - function log(string memory p0, string memory p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address)", p0, p1, p2)); - } - - function log(string memory p0, bool p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256)", p0, p1, p2)); - } - - function log(string memory p0, bool p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string)", p0, p1, p2)); - } - - function log(string memory p0, bool p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool)", p0, p1, p2)); - } - - function log(string memory p0, bool p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address)", p0, p1, p2)); - } - - function log(string memory p0, address p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256)", p0, p1, p2)); - } - - function log(string memory p0, address p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string)", p0, p1, p2)); - } - - function log(string memory p0, address p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool)", p0, p1, p2)); - } - - function log(string memory p0, address p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address)", p0, p1, p2)); - } - - function log(bool p0, uint256 p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256)", p0, p1, p2)); - } - - function log(bool p0, uint256 p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string)", p0, p1, p2)); - } - - function log(bool p0, uint256 p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool)", p0, p1, p2)); - } - - function log(bool p0, uint256 p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address)", p0, p1, p2)); - } - - function log(bool p0, string memory p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256)", p0, p1, p2)); - } - - function log(bool p0, string memory p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string)", p0, p1, p2)); - } - - function log(bool p0, string memory p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool)", p0, p1, p2)); - } - - function log(bool p0, string memory p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address)", p0, p1, p2)); - } - - function log(bool p0, bool p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256)", p0, p1, p2)); - } - - function log(bool p0, bool p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string)", p0, p1, p2)); - } - - function log(bool p0, bool p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool)", p0, p1, p2)); - } - - function log(bool p0, bool p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address)", p0, p1, p2)); - } - - function log(bool p0, address p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256)", p0, p1, p2)); - } - - function log(bool p0, address p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string)", p0, p1, p2)); - } - - function log(bool p0, address p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool)", p0, p1, p2)); - } - - function log(bool p0, address p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address)", p0, p1, p2)); - } - - function log(address p0, uint256 p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256)", p0, p1, p2)); - } - - function log(address p0, uint256 p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string)", p0, p1, p2)); - } - - function log(address p0, uint256 p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool)", p0, p1, p2)); - } - - function log(address p0, uint256 p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address)", p0, p1, p2)); - } - - function log(address p0, string memory p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256)", p0, p1, p2)); - } - - function log(address p0, string memory p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string)", p0, p1, p2)); - } - - function log(address p0, string memory p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool)", p0, p1, p2)); - } - - function log(address p0, string memory p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address)", p0, p1, p2)); - } - - function log(address p0, bool p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256)", p0, p1, p2)); - } - - function log(address p0, bool p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string)", p0, p1, p2)); - } - - function log(address p0, bool p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool)", p0, p1, p2)); - } - - function log(address p0, bool p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address)", p0, p1, p2)); - } - - function log(address p0, address p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256)", p0, p1, p2)); - } - - function log(address p0, address p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string)", p0, p1, p2)); - } - - function log(address p0, address p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool)", p0, p1, p2)); - } - - function log(address p0, address p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address)", p0, p1, p2)); - } - - function log(uint256 p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address,address)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256,string)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256,address)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string,string)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string,address)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool,string)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool,address)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address,string)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address,address)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256,string)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256,address)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,string)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,address)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,string)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,address)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,string)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,address)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256,string)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256,address)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,string)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,address)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,string)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,address)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,string)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,address)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256,string)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256,address)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,string)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,address)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,string)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,address)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,string)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,address)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256,string)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256,bool)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256,address)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string,string)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string,bool)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string,address)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool,string)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool,bool)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool,address)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address,string)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address,bool)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address,address)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256,string)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256,bool)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256,address)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string,string)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string,bool)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string,address)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,string)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,bool)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,address)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address,string)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address,bool)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address,address)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256,string)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256,bool)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256,address)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,string)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,bool)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,address)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,string)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,bool)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,address)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,string)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,bool)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,address)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256,string)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256,bool)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256,address)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string,string)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string,bool)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string,address)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,string)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,bool)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,address)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address,string)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address,bool)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address,address)", p0, p1, p2, p3)); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/console2.sol b/lib/signals-implicit-mode/lib/forge-std/src/console2.sol deleted file mode 100644 index 03531d91d3..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/console2.sol +++ /dev/null @@ -1,4 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.4.22 <0.9.0; - -import {console as console2} from "./console.sol"; diff --git a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC1155.sol b/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC1155.sol deleted file mode 100644 index ffc82984a7..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC1155.sol +++ /dev/null @@ -1,105 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -import {IERC165} from "./IERC165.sol"; - -/// @title ERC-1155 Multi Token Standard -/// @dev See https://eips.ethereum.org/EIPS/eip-1155 -/// Note: The ERC-165 identifier for this interface is 0xd9b67a26. -interface IERC1155 is IERC165 { - /// @dev - /// - Either `TransferSingle` or `TransferBatch` MUST emit when tokens are transferred, including zero value transfers as well as minting or burning (see "Safe Transfer Rules" section of the standard). - /// - The `_operator` argument MUST be the address of an account/contract that is approved to make the transfer (SHOULD be msg.sender). - /// - The `_from` argument MUST be the address of the holder whose balance is decreased. - /// - The `_to` argument MUST be the address of the recipient whose balance is increased. - /// - The `_id` argument MUST be the token type being transferred. - /// - The `_value` argument MUST be the number of tokens the holder balance is decreased by and match what the recipient balance is increased by. - /// - When minting/creating tokens, the `_from` argument MUST be set to `0x0` (i.e. zero address). - /// - When burning/destroying tokens, the `_to` argument MUST be set to `0x0` (i.e. zero address). - event TransferSingle( - address indexed _operator, address indexed _from, address indexed _to, uint256 _id, uint256 _value - ); - - /// @dev - /// - Either `TransferSingle` or `TransferBatch` MUST emit when tokens are transferred, including zero value transfers as well as minting or burning (see "Safe Transfer Rules" section of the standard). - /// - The `_operator` argument MUST be the address of an account/contract that is approved to make the transfer (SHOULD be msg.sender). - /// - The `_from` argument MUST be the address of the holder whose balance is decreased. - /// - The `_to` argument MUST be the address of the recipient whose balance is increased. - /// - The `_ids` argument MUST be the list of tokens being transferred. - /// - The `_values` argument MUST be the list of number of tokens (matching the list and order of tokens specified in _ids) the holder balance is decreased by and match what the recipient balance is increased by. - /// - When minting/creating tokens, the `_from` argument MUST be set to `0x0` (i.e. zero address). - /// - When burning/destroying tokens, the `_to` argument MUST be set to `0x0` (i.e. zero address). - event TransferBatch( - address indexed _operator, address indexed _from, address indexed _to, uint256[] _ids, uint256[] _values - ); - - /// @dev MUST emit when approval for a second party/operator address to manage all tokens for an owner address is enabled or disabled (absence of an event assumes disabled). - event ApprovalForAll(address indexed _owner, address indexed _operator, bool _approved); - - /// @dev MUST emit when the URI is updated for a token ID. URIs are defined in RFC 3986. - /// The URI MUST point to a JSON file that conforms to the "ERC-1155 Metadata URI JSON Schema". - event URI(string _value, uint256 indexed _id); - - /// @notice Transfers `_value` amount of an `_id` from the `_from` address to the `_to` address specified (with safety call). - /// @dev Caller must be approved to manage the tokens being transferred out of the `_from` account (see "Approval" section of the standard). - /// - MUST revert if `_to` is the zero address. - /// - MUST revert if balance of holder for token `_id` is lower than the `_value` sent. - /// - MUST revert on any other error. - /// - MUST emit the `TransferSingle` event to reflect the balance change (see "Safe Transfer Rules" section of the standard). - /// - After the above conditions are met, this function MUST check if `_to` is a smart contract (e.g. code size > 0). If so, it MUST call `onERC1155Received` on `_to` and act appropriately (see "Safe Transfer Rules" section of the standard). - /// @param _from Source address - /// @param _to Target address - /// @param _id ID of the token type - /// @param _value Transfer amount - /// @param _data Additional data with no specified format, MUST be sent unaltered in call to `onERC1155Received` on `_to` - function safeTransferFrom(address _from, address _to, uint256 _id, uint256 _value, bytes calldata _data) external; - - /// @notice Transfers `_values` amount(s) of `_ids` from the `_from` address to the `_to` address specified (with safety call). - /// @dev Caller must be approved to manage the tokens being transferred out of the `_from` account (see "Approval" section of the standard). - /// - MUST revert if `_to` is the zero address. - /// - MUST revert if length of `_ids` is not the same as length of `_values`. - /// - MUST revert if any of the balance(s) of the holder(s) for token(s) in `_ids` is lower than the respective amount(s) in `_values` sent to the recipient. - /// - MUST revert on any other error. - /// - MUST emit `TransferSingle` or `TransferBatch` event(s) such that all the balance changes are reflected (see "Safe Transfer Rules" section of the standard). - /// - Balance changes and events MUST follow the ordering of the arrays (_ids[0]/_values[0] before _ids[1]/_values[1], etc). - /// - After the above conditions for the transfer(s) in the batch are met, this function MUST check if `_to` is a smart contract (e.g. code size > 0). If so, it MUST call the relevant `ERC1155TokenReceiver` hook(s) on `_to` and act appropriately (see "Safe Transfer Rules" section of the standard). - /// @param _from Source address - /// @param _to Target address - /// @param _ids IDs of each token type (order and length must match _values array) - /// @param _values Transfer amounts per token type (order and length must match _ids array) - /// @param _data Additional data with no specified format, MUST be sent unaltered in call to the `ERC1155TokenReceiver` hook(s) on `_to` - function safeBatchTransferFrom( - address _from, - address _to, - uint256[] calldata _ids, - uint256[] calldata _values, - bytes calldata _data - ) external; - - /// @notice Get the balance of an account's tokens. - /// @param _owner The address of the token holder - /// @param _id ID of the token - /// @return The _owner's balance of the token type requested - function balanceOf(address _owner, uint256 _id) external view returns (uint256); - - /// @notice Get the balance of multiple account/token pairs - /// @param _owners The addresses of the token holders - /// @param _ids ID of the tokens - /// @return The _owner's balance of the token types requested (i.e. balance for each (owner, id) pair) - function balanceOfBatch(address[] calldata _owners, uint256[] calldata _ids) - external - view - returns (uint256[] memory); - - /// @notice Enable or disable approval for a third party ("operator") to manage all of the caller's tokens. - /// @dev MUST emit the ApprovalForAll event on success. - /// @param _operator Address to add to the set of authorized operators - /// @param _approved True if the operator is approved, false to revoke approval - function setApprovalForAll(address _operator, bool _approved) external; - - /// @notice Queries the approval status of an operator for a given owner. - /// @param _owner The owner of the tokens - /// @param _operator Address of authorized operator - /// @return True if the operator is approved, false if not - function isApprovedForAll(address _owner, address _operator) external view returns (bool); -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC165.sol b/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC165.sol deleted file mode 100644 index 9af4bf800f..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC165.sol +++ /dev/null @@ -1,12 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -interface IERC165 { - /// @notice Query if a contract implements an interface - /// @param interfaceID The interface identifier, as specified in ERC-165 - /// @dev Interface identification is specified in ERC-165. This function - /// uses less than 30,000 gas. - /// @return `true` if the contract implements `interfaceID` and - /// `interfaceID` is not 0xffffffff, `false` otherwise - function supportsInterface(bytes4 interfaceID) external view returns (bool); -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC20.sol b/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC20.sol deleted file mode 100644 index ba40806c3b..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC20.sol +++ /dev/null @@ -1,43 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -/// @dev Interface of the ERC20 standard as defined in the EIP. -/// @dev This includes the optional name, symbol, and decimals metadata. -interface IERC20 { - /// @dev Emitted when `value` tokens are moved from one account (`from`) to another (`to`). - event Transfer(address indexed from, address indexed to, uint256 value); - - /// @dev Emitted when the allowance of a `spender` for an `owner` is set, where `value` - /// is the new allowance. - event Approval(address indexed owner, address indexed spender, uint256 value); - - /// @notice Returns the amount of tokens in existence. - function totalSupply() external view returns (uint256); - - /// @notice Returns the amount of tokens owned by `account`. - function balanceOf(address account) external view returns (uint256); - - /// @notice Moves `amount` tokens from the caller's account to `to`. - function transfer(address to, uint256 amount) external returns (bool); - - /// @notice Returns the remaining number of tokens that `spender` is allowed - /// to spend on behalf of `owner` - function allowance(address owner, address spender) external view returns (uint256); - - /// @notice Sets `amount` as the allowance of `spender` over the caller's tokens. - /// @dev Be aware of front-running risks: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 - function approve(address spender, uint256 amount) external returns (bool); - - /// @notice Moves `amount` tokens from `from` to `to` using the allowance mechanism. - /// `amount` is then deducted from the caller's allowance. - function transferFrom(address from, address to, uint256 amount) external returns (bool); - - /// @notice Returns the name of the token. - function name() external view returns (string memory); - - /// @notice Returns the symbol of the token. - function symbol() external view returns (string memory); - - /// @notice Returns the decimals places of the token. - function decimals() external view returns (uint8); -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC4626.sol b/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC4626.sol deleted file mode 100644 index c645a0fecf..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC4626.sol +++ /dev/null @@ -1,190 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -import {IERC20} from "./IERC20.sol"; - -/// @dev Interface of the ERC4626 "Tokenized Vault Standard", as defined in -/// https://eips.ethereum.org/EIPS/eip-4626 -interface IERC4626 is IERC20 { - event Deposit(address indexed sender, address indexed owner, uint256 assets, uint256 shares); - - event Withdraw( - address indexed sender, address indexed receiver, address indexed owner, uint256 assets, uint256 shares - ); - - /// @notice Returns the address of the underlying token used for the Vault for accounting, depositing, and withdrawing. - /// @dev - /// - MUST be an ERC-20 token contract. - /// - MUST NOT revert. - function asset() external view returns (address assetTokenAddress); - - /// @notice Returns the total amount of the underlying asset that is “managed” by Vault. - /// @dev - /// - SHOULD include any compounding that occurs from yield. - /// - MUST be inclusive of any fees that are charged against assets in the Vault. - /// - MUST NOT revert. - function totalAssets() external view returns (uint256 totalManagedAssets); - - /// @notice Returns the amount of shares that the Vault would exchange for the amount of assets provided, in an ideal - /// scenario where all the conditions are met. - /// @dev - /// - MUST NOT be inclusive of any fees that are charged against assets in the Vault. - /// - MUST NOT show any variations depending on the caller. - /// - MUST NOT reflect slippage or other on-chain conditions, when performing the actual exchange. - /// - MUST NOT revert. - /// - /// NOTE: This calculation MAY NOT reflect the “per-user” price-per-share, and instead should reflect the - /// “average-user’s” price-per-share, meaning what the average user should expect to see when exchanging to and - /// from. - function convertToShares(uint256 assets) external view returns (uint256 shares); - - /// @notice Returns the amount of assets that the Vault would exchange for the amount of shares provided, in an ideal - /// scenario where all the conditions are met. - /// @dev - /// - MUST NOT be inclusive of any fees that are charged against assets in the Vault. - /// - MUST NOT show any variations depending on the caller. - /// - MUST NOT reflect slippage or other on-chain conditions, when performing the actual exchange. - /// - MUST NOT revert. - /// - /// NOTE: This calculation MAY NOT reflect the “per-user” price-per-share, and instead should reflect the - /// “average-user’s” price-per-share, meaning what the average user should expect to see when exchanging to and - /// from. - function convertToAssets(uint256 shares) external view returns (uint256 assets); - - /// @notice Returns the maximum amount of the underlying asset that can be deposited into the Vault for the receiver, - /// through a deposit call. - /// @dev - /// - MUST return a limited value if receiver is subject to some deposit limit. - /// - MUST return 2 ** 256 - 1 if there is no limit on the maximum amount of assets that may be deposited. - /// - MUST NOT revert. - function maxDeposit(address receiver) external view returns (uint256 maxAssets); - - /// @notice Allows an on-chain or off-chain user to simulate the effects of their deposit at the current block, given - /// current on-chain conditions. - /// @dev - /// - MUST return as close to and no more than the exact amount of Vault shares that would be minted in a deposit - /// call in the same transaction. I.e. deposit should return the same or more shares as previewDeposit if called - /// in the same transaction. - /// - MUST NOT account for deposit limits like those returned from maxDeposit and should always act as though the - /// deposit would be accepted, regardless if the user has enough tokens approved, etc. - /// - MUST be inclusive of deposit fees. Integrators should be aware of the existence of deposit fees. - /// - MUST NOT revert. - /// - /// NOTE: any unfavorable discrepancy between convertToShares and previewDeposit SHOULD be considered slippage in - /// share price or some other type of condition, meaning the depositor will lose assets by depositing. - function previewDeposit(uint256 assets) external view returns (uint256 shares); - - /// @notice Mints shares Vault shares to receiver by depositing exactly amount of underlying tokens. - /// @dev - /// - MUST emit the Deposit event. - /// - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - /// deposit execution, and are accounted for during deposit. - /// - MUST revert if all of assets cannot be deposited (due to deposit limit being reached, slippage, the user not - /// approving enough underlying tokens to the Vault contract, etc). - /// - /// NOTE: most implementations will require pre-approval of the Vault with the Vault’s underlying asset token. - function deposit(uint256 assets, address receiver) external returns (uint256 shares); - - /// @notice Returns the maximum amount of the Vault shares that can be minted for the receiver, through a mint call. - /// @dev - /// - MUST return a limited value if receiver is subject to some mint limit. - /// - MUST return 2 ** 256 - 1 if there is no limit on the maximum amount of shares that may be minted. - /// - MUST NOT revert. - function maxMint(address receiver) external view returns (uint256 maxShares); - - /// @notice Allows an on-chain or off-chain user to simulate the effects of their mint at the current block, given - /// current on-chain conditions. - /// @dev - /// - MUST return as close to and no fewer than the exact amount of assets that would be deposited in a mint call - /// in the same transaction. I.e. mint should return the same or fewer assets as previewMint if called in the - /// same transaction. - /// - MUST NOT account for mint limits like those returned from maxMint and should always act as though the mint - /// would be accepted, regardless if the user has enough tokens approved, etc. - /// - MUST be inclusive of deposit fees. Integrators should be aware of the existence of deposit fees. - /// - MUST NOT revert. - /// - /// NOTE: any unfavorable discrepancy between convertToAssets and previewMint SHOULD be considered slippage in - /// share price or some other type of condition, meaning the depositor will lose assets by minting. - function previewMint(uint256 shares) external view returns (uint256 assets); - - /// @notice Mints exactly shares Vault shares to receiver by depositing amount of underlying tokens. - /// @dev - /// - MUST emit the Deposit event. - /// - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the mint - /// execution, and are accounted for during mint. - /// - MUST revert if all of shares cannot be minted (due to deposit limit being reached, slippage, the user not - /// approving enough underlying tokens to the Vault contract, etc). - /// - /// NOTE: most implementations will require pre-approval of the Vault with the Vault’s underlying asset token. - function mint(uint256 shares, address receiver) external returns (uint256 assets); - - /// @notice Returns the maximum amount of the underlying asset that can be withdrawn from the owner balance in the - /// Vault, through a withdrawal call. - /// @dev - /// - MUST return a limited value if owner is subject to some withdrawal limit or timelock. - /// - MUST NOT revert. - function maxWithdraw(address owner) external view returns (uint256 maxAssets); - - /// @notice Allows an on-chain or off-chain user to simulate the effects of their withdrawal at the current block, - /// given current on-chain conditions. - /// @dev - /// - MUST return as close to and no fewer than the exact amount of Vault shares that would be burned in a withdraw - /// call in the same transaction. I.e. withdraw should return the same or fewer shares as previewWithdraw if - /// called - /// in the same transaction. - /// - MUST NOT account for withdrawal limits like those returned from maxWithdraw and should always act as though - /// the withdrawal would be accepted, regardless if the user has enough shares, etc. - /// - MUST be inclusive of withdrawal fees. Integrators should be aware of the existence of withdrawal fees. - /// - MUST NOT revert. - /// - /// NOTE: any unfavorable discrepancy between convertToShares and previewWithdraw SHOULD be considered slippage in - /// share price or some other type of condition, meaning the depositor will lose assets by depositing. - function previewWithdraw(uint256 assets) external view returns (uint256 shares); - - /// @notice Burns shares from owner and sends exactly assets of underlying tokens to receiver. - /// @dev - /// - MUST emit the Withdraw event. - /// - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - /// withdraw execution, and are accounted for during withdrawal. - /// - MUST revert if all of assets cannot be withdrawn (due to withdrawal limit being reached, slippage, the owner - /// not having enough shares, etc). - /// - /// Note that some implementations will require pre-requesting to the Vault before a withdrawal may be performed. - /// Those methods should be performed separately. - function withdraw(uint256 assets, address receiver, address owner) external returns (uint256 shares); - - /// @notice Returns the maximum amount of Vault shares that can be redeemed from the owner balance in the Vault, - /// through a redeem call. - /// @dev - /// - MUST return a limited value if owner is subject to some withdrawal limit or timelock. - /// - MUST return balanceOf(owner) if owner is not subject to any withdrawal limit or timelock. - /// - MUST NOT revert. - function maxRedeem(address owner) external view returns (uint256 maxShares); - - /// @notice Allows an on-chain or off-chain user to simulate the effects of their redeemption at the current block, - /// given current on-chain conditions. - /// @dev - /// - MUST return as close to and no more than the exact amount of assets that would be withdrawn in a redeem call - /// in the same transaction. I.e. redeem should return the same or more assets as previewRedeem if called in the - /// same transaction. - /// - MUST NOT account for redemption limits like those returned from maxRedeem and should always act as though the - /// redemption would be accepted, regardless if the user has enough shares, etc. - /// - MUST be inclusive of withdrawal fees. Integrators should be aware of the existence of withdrawal fees. - /// - MUST NOT revert. - /// - /// NOTE: any unfavorable discrepancy between convertToAssets and previewRedeem SHOULD be considered slippage in - /// share price or some other type of condition, meaning the depositor will lose assets by redeeming. - function previewRedeem(uint256 shares) external view returns (uint256 assets); - - /// @notice Burns exactly shares from owner and sends assets of underlying tokens to receiver. - /// @dev - /// - MUST emit the Withdraw event. - /// - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - /// redeem execution, and are accounted for during redeem. - /// - MUST revert if all of shares cannot be redeemed (due to withdrawal limit being reached, slippage, the owner - /// not having enough shares, etc). - /// - /// NOTE: some implementations will require pre-requesting to the Vault before a withdrawal may be performed. - /// Those methods should be performed separately. - function redeem(uint256 shares, address receiver, address owner) external returns (uint256 assets); -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC6909.sol b/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC6909.sol deleted file mode 100644 index 6e11cb460d..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC6909.sol +++ /dev/null @@ -1,72 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -import {IERC165} from "./IERC165.sol"; - -/// @dev Required interface of an ERC-6909 compliant contract, as defined in -/// https://eips.ethereum.org/EIPS/eip-6909 -interface IERC6909 is IERC165 { - /// @dev Emitted when the allowance of a `spender` for an `owner` is set for a token of type `id`. - event Approval(address indexed owner, address indexed spender, uint256 indexed id, uint256 amount); - - /// @dev Emitted when `owner` grants or revokes operator status for a `spender`. - event OperatorSet(address indexed owner, address indexed spender, bool approved); - - /// @dev Emitted when `amount` tokens of type `id` are moved from `sender` to `receiver` initiated by `caller`. - event Transfer( - address caller, address indexed sender, address indexed receiver, uint256 indexed id, uint256 amount - ); - - ///@dev Returns the amount of tokens of type `id` owned by `owner`. - function balanceOf(address owner, uint256 id) external view returns (uint256); - - /// @dev Returns the amount of tokens of type `id` that `spender` is allowed to spend on behalf of `owner`. - /// NOTE: Does not include operator allowances. - function allowance(address owner, address spender, uint256 id) external view returns (uint256); - - /// @dev Returns true if `spender` is set as an operator for `owner`. - function isOperator(address owner, address spender) external view returns (bool); - - /// @dev Sets an approval to `spender` for `amount` tokens of type `id` from the caller's tokens. - /// Must return true. - function approve(address spender, uint256 id, uint256 amount) external returns (bool); - - /// @dev Grants or revokes unlimited transfer permission of any token id to `spender` for the caller's tokens. - /// Must return true. - function setOperator(address spender, bool approved) external returns (bool); - - /// @dev Transfers `amount` of token type `id` from the caller's account to `receiver`. - /// Must return true. - function transfer(address receiver, uint256 id, uint256 amount) external returns (bool); - - /// @dev Transfers `amount` of token type `id` from `sender` to `receiver`. - /// Must return true. - function transferFrom(address sender, address receiver, uint256 id, uint256 amount) external returns (bool); -} - -/// @dev Optional extension of {IERC6909} that adds metadata functions. -interface IERC6909Metadata is IERC6909 { - /// @dev Returns the name of the token of type `id`. - function name(uint256 id) external view returns (string memory); - - /// @dev Returns the ticker symbol of the token of type `id`. - function symbol(uint256 id) external view returns (string memory); - - /// @dev Returns the number of decimals for the token of type `id`. - function decimals(uint256 id) external view returns (uint8); -} - -/// @dev Optional extension of {IERC6909} that adds content URI functions. -interface IERC6909ContentURI is IERC6909 { - /// @dev Returns URI for the contract. - function contractURI() external view returns (string memory); - - /// @dev Returns the URI for the token of type `id`. - function tokenURI(uint256 id) external view returns (string memory); -} - -/// @dev Optional extension of {IERC6909} that adds a token supply function. -interface IERC6909TokenSupply is IERC6909 { - /// @dev Returns the total supply of the token of type `id`. - function totalSupply(uint256 id) external view returns (uint256); -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC721.sol b/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC721.sol deleted file mode 100644 index 21a4a94dea..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC721.sol +++ /dev/null @@ -1,164 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -import {IERC165} from "./IERC165.sol"; - -/// @title ERC-721 Non-Fungible Token Standard -/// @dev See https://eips.ethereum.org/EIPS/eip-721 -/// Note: the ERC-165 identifier for this interface is 0x80ac58cd. -interface IERC721 is IERC165 { - /// @dev This emits when ownership of any NFT changes by any mechanism. - /// This event emits when NFTs are created (`from` == 0) and destroyed - /// (`to` == 0). Exception: during contract creation, any number of NFTs - /// may be created and assigned without emitting Transfer. At the time of - /// any transfer, the approved address for that NFT (if any) is reset to none. - event Transfer(address indexed _from, address indexed _to, uint256 indexed _tokenId); - - /// @dev This emits when the approved address for an NFT is changed or - /// reaffirmed. The zero address indicates there is no approved address. - /// When a Transfer event emits, this also indicates that the approved - /// address for that NFT (if any) is reset to none. - event Approval(address indexed _owner, address indexed _approved, uint256 indexed _tokenId); - - /// @dev This emits when an operator is enabled or disabled for an owner. - /// The operator can manage all NFTs of the owner. - event ApprovalForAll(address indexed _owner, address indexed _operator, bool _approved); - - /// @notice Count all NFTs assigned to an owner - /// @dev NFTs assigned to the zero address are considered invalid, and this - /// function throws for queries about the zero address. - /// @param _owner An address for whom to query the balance - /// @return The number of NFTs owned by `_owner`, possibly zero - function balanceOf(address _owner) external view returns (uint256); - - /// @notice Find the owner of an NFT - /// @dev NFTs assigned to zero address are considered invalid, and queries - /// about them do throw. - /// @param _tokenId The identifier for an NFT - /// @return The address of the owner of the NFT - function ownerOf(uint256 _tokenId) external view returns (address); - - /// @notice Transfers the ownership of an NFT from one address to another address - /// @dev Throws unless `msg.sender` is the current owner, an authorized - /// operator, or the approved address for this NFT. Throws if `_from` is - /// not the current owner. Throws if `_to` is the zero address. Throws if - /// `_tokenId` is not a valid NFT. When transfer is complete, this function - /// checks if `_to` is a smart contract (code size > 0). If so, it calls - /// `onERC721Received` on `_to` and throws if the return value is not - /// `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`. - /// @param _from The current owner of the NFT - /// @param _to The new owner - /// @param _tokenId The NFT to transfer - /// @param data Additional data with no specified format, sent in call to `_to` - function safeTransferFrom(address _from, address _to, uint256 _tokenId, bytes calldata data) external payable; - - /// @notice Transfers the ownership of an NFT from one address to another address - /// @dev This works identically to the other function with an extra data parameter, - /// except this function just sets data to "". - /// @param _from The current owner of the NFT - /// @param _to The new owner - /// @param _tokenId The NFT to transfer - function safeTransferFrom(address _from, address _to, uint256 _tokenId) external payable; - - /// @notice Transfer ownership of an NFT -- THE CALLER IS RESPONSIBLE - /// TO CONFIRM THAT `_to` IS CAPABLE OF RECEIVING NFTS OR ELSE - /// THEY MAY BE PERMANENTLY LOST - /// @dev Throws unless `msg.sender` is the current owner, an authorized - /// operator, or the approved address for this NFT. Throws if `_from` is - /// not the current owner. Throws if `_to` is the zero address. Throws if - /// `_tokenId` is not a valid NFT. - /// @param _from The current owner of the NFT - /// @param _to The new owner - /// @param _tokenId The NFT to transfer - function transferFrom(address _from, address _to, uint256 _tokenId) external payable; - - /// @notice Change or reaffirm the approved address for an NFT - /// @dev The zero address indicates there is no approved address. - /// Throws unless `msg.sender` is the current NFT owner, or an authorized - /// operator of the current owner. - /// @param _approved The new approved NFT controller - /// @param _tokenId The NFT to approve - function approve(address _approved, uint256 _tokenId) external payable; - - /// @notice Enable or disable approval for a third party ("operator") to manage - /// all of `msg.sender`'s assets - /// @dev Emits the ApprovalForAll event. The contract MUST allow - /// multiple operators per owner. - /// @param _operator Address to add to the set of authorized operators - /// @param _approved True if the operator is approved, false to revoke approval - function setApprovalForAll(address _operator, bool _approved) external; - - /// @notice Get the approved address for a single NFT - /// @dev Throws if `_tokenId` is not a valid NFT. - /// @param _tokenId The NFT to find the approved address for - /// @return The approved address for this NFT, or the zero address if there is none - function getApproved(uint256 _tokenId) external view returns (address); - - /// @notice Query if an address is an authorized operator for another address - /// @param _owner The address that owns the NFTs - /// @param _operator The address that acts on behalf of the owner - /// @return True if `_operator` is an approved operator for `_owner`, false otherwise - function isApprovedForAll(address _owner, address _operator) external view returns (bool); -} - -/// @dev Note: the ERC-165 identifier for this interface is 0x150b7a02. -interface IERC721TokenReceiver { - /// @notice Handle the receipt of an NFT - /// @dev The ERC721 smart contract calls this function on the recipient - /// after a `transfer`. This function MAY throw to revert and reject the - /// transfer. Return of other than the magic value MUST result in the - /// transaction being reverted. - /// Note: the contract address is always the message sender. - /// @param _operator The address which called `safeTransferFrom` function - /// @param _from The address which previously owned the token - /// @param _tokenId The NFT identifier which is being transferred - /// @param _data Additional data with no specified format - /// @return `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))` - /// unless throwing - function onERC721Received(address _operator, address _from, uint256 _tokenId, bytes calldata _data) - external - returns (bytes4); -} - -/// @title ERC-721 Non-Fungible Token Standard, optional metadata extension -/// @dev See https://eips.ethereum.org/EIPS/eip-721 -/// Note: the ERC-165 identifier for this interface is 0x5b5e139f. -interface IERC721Metadata is IERC721 { - /// @notice A descriptive name for a collection of NFTs in this contract - function name() external view returns (string memory _name); - - /// @notice An abbreviated name for NFTs in this contract - function symbol() external view returns (string memory _symbol); - - /// @notice A distinct Uniform Resource Identifier (URI) for a given asset. - /// @dev Throws if `_tokenId` is not a valid NFT. URIs are defined in RFC - /// 3986. The URI may point to a JSON file that conforms to the "ERC721 - /// Metadata JSON Schema". - function tokenURI(uint256 _tokenId) external view returns (string memory); -} - -/// @title ERC-721 Non-Fungible Token Standard, optional enumeration extension -/// @dev See https://eips.ethereum.org/EIPS/eip-721 -/// Note: the ERC-165 identifier for this interface is 0x780e9d63. -interface IERC721Enumerable is IERC721 { - /// @notice Count NFTs tracked by this contract - /// @return A count of valid NFTs tracked by this contract, where each one of - /// them has an assigned and queryable owner not equal to the zero address - function totalSupply() external view returns (uint256); - - /// @notice Enumerate valid NFTs - /// @dev Throws if `_index` >= `totalSupply()`. - /// @param _index A counter less than `totalSupply()` - /// @return The token identifier for the `_index`th NFT, - /// (sort order not specified) - function tokenByIndex(uint256 _index) external view returns (uint256); - - /// @notice Enumerate NFTs assigned to an owner - /// @dev Throws if `_index` >= `balanceOf(_owner)` or if - /// `_owner` is the zero address, representing invalid NFTs. - /// @param _owner An address where we are interested in NFTs owned by them - /// @param _index A counter less than `balanceOf(_owner)` - /// @return The token identifier for the `_index`th NFT assigned to `_owner`, - /// (sort order not specified) - function tokenOfOwnerByIndex(address _owner, uint256 _index) external view returns (uint256); -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC7540.sol b/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC7540.sol deleted file mode 100644 index 91a38ca359..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC7540.sol +++ /dev/null @@ -1,150 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -import {IERC7575} from "./IERC7575.sol"; - -/// @dev Interface of the base operator logic of ERC7540, as defined in -/// https://eips.ethereum.org/EIPS/eip-7540 -interface IERC7540Operator { - /** - * @dev The event emitted when an operator is set. - * - * @param controller The address of the controller. - * @param operator The address of the operator. - * @param approved The approval status. - */ - event OperatorSet(address indexed controller, address indexed operator, bool approved); - - /** - * @dev Sets or removes an operator for the caller. - * - * @param operator The address of the operator. - * @param approved The approval status. - * @return Whether the call was executed successfully or not - */ - function setOperator(address operator, bool approved) external returns (bool); - - /** - * @dev Returns `true` if the `operator` is approved as an operator for an `controller`. - * - * @param controller The address of the controller. - * @param operator The address of the operator. - * @return status The approval status - */ - function isOperator(address controller, address operator) external view returns (bool status); -} - -/// @dev Interface of the asynchronous deposit Vault interface of ERC7540, as defined in -/// https://eips.ethereum.org/EIPS/eip-7540 -interface IERC7540Deposit is IERC7540Operator { - event DepositRequest( - address indexed controller, address indexed owner, uint256 indexed requestId, address sender, uint256 assets - ); - /** - * @dev Transfers assets from sender into the Vault and submits a Request for asynchronous deposit. - * - * - MUST support ERC-20 approve / transferFrom on asset as a deposit Request flow. - * - MUST revert if all of assets cannot be requested for deposit. - * - owner MUST be msg.sender unless some unspecified explicit approval is given by the caller, - * approval of ERC-20 tokens from owner to sender is NOT enough. - * - * @param assets the amount of deposit assets to transfer from owner - * @param controller the controller of the request who will be able to operate the request - * @param owner the source of the deposit assets - * - * NOTE: most implementations will require pre-approval of the Vault with the Vault's underlying asset token. - */ - - function requestDeposit(uint256 assets, address controller, address owner) external returns (uint256 requestId); - - /** - * @dev Returns the amount of requested assets in Pending state. - * - * - MUST NOT include any assets in Claimable state for deposit or mint. - * - MUST NOT show any variations depending on the caller. - * - MUST NOT revert unless due to integer overflow caused by an unreasonably large input. - */ - function pendingDepositRequest(uint256 requestId, address controller) - external - view - returns (uint256 pendingAssets); - - /** - * @dev Returns the amount of requested assets in Claimable state for the controller to deposit or mint. - * - * - MUST NOT include any assets in Pending state. - * - MUST NOT show any variations depending on the caller. - * - MUST NOT revert unless due to integer overflow caused by an unreasonably large input. - */ - function claimableDepositRequest(uint256 requestId, address controller) - external - view - returns (uint256 claimableAssets); - - /** - * @dev Mints shares Vault shares to receiver by claiming the Request of the controller. - * - * - MUST emit the Deposit event. - * - controller MUST equal msg.sender unless the controller has approved the msg.sender as an operator. - */ - function deposit(uint256 assets, address receiver, address controller) external returns (uint256 shares); - - /** - * @dev Mints exactly shares Vault shares to receiver by claiming the Request of the controller. - * - * - MUST emit the Deposit event. - * - controller MUST equal msg.sender unless the controller has approved the msg.sender as an operator. - */ - function mint(uint256 shares, address receiver, address controller) external returns (uint256 assets); -} - -/// @dev Interface of the asynchronous deposit Vault interface of ERC7540, as defined in -/// https://eips.ethereum.org/EIPS/eip-7540 -interface IERC7540Redeem is IERC7540Operator { - event RedeemRequest( - address indexed controller, address indexed owner, uint256 indexed requestId, address sender, uint256 assets - ); - - /** - * @dev Assumes control of shares from sender into the Vault and submits a Request for asynchronous redeem. - * - * - MUST support a redeem Request flow where the control of shares is taken from sender directly - * where msg.sender has ERC-20 approval over the shares of owner. - * - MUST revert if all of shares cannot be requested for redeem. - * - * @param shares the amount of shares to be redeemed to transfer from owner - * @param controller the controller of the request who will be able to operate the request - * @param owner the source of the shares to be redeemed - * - * NOTE: most implementations will require pre-approval of the Vault with the Vault's share token. - */ - function requestRedeem(uint256 shares, address controller, address owner) external returns (uint256 requestId); - - /** - * @dev Returns the amount of requested shares in Pending state. - * - * - MUST NOT include any shares in Claimable state for redeem or withdraw. - * - MUST NOT show any variations depending on the caller. - * - MUST NOT revert unless due to integer overflow caused by an unreasonably large input. - */ - function pendingRedeemRequest(uint256 requestId, address controller) - external - view - returns (uint256 pendingShares); - - /** - * @dev Returns the amount of requested shares in Claimable state for the controller to redeem or withdraw. - * - * - MUST NOT include any shares in Pending state for redeem or withdraw. - * - MUST NOT show any variations depending on the caller. - * - MUST NOT revert unless due to integer overflow caused by an unreasonably large input. - */ - function claimableRedeemRequest(uint256 requestId, address controller) - external - view - returns (uint256 claimableShares); -} - -/// @dev Interface of the fully asynchronous Vault interface of ERC7540, as defined in -/// https://eips.ethereum.org/EIPS/eip-7540 -interface IERC7540 is IERC7540Deposit, IERC7540Redeem, IERC7575 {} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC7575.sol b/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC7575.sol deleted file mode 100644 index 207e3e7fec..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IERC7575.sol +++ /dev/null @@ -1,241 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -import {IERC165} from "./IERC165.sol"; - -/// @dev Interface of the ERC7575 "Multi-Asset ERC-4626 Vaults", as defined in -/// https://eips.ethereum.org/EIPS/eip-7575 -interface IERC7575 is IERC165 { - event Deposit(address indexed sender, address indexed owner, uint256 assets, uint256 shares); - event Withdraw( - address indexed sender, address indexed receiver, address indexed owner, uint256 assets, uint256 shares - ); - - /** - * @dev Returns the address of the underlying token used for the Vault for accounting, depositing, and withdrawing. - * - * - MUST be an ERC-20 token contract. - * - MUST NOT revert. - */ - function asset() external view returns (address assetTokenAddress); - - /** - * @dev Returns the address of the share token - * - * - MUST be an ERC-20 token contract. - * - MUST NOT revert. - */ - function share() external view returns (address shareTokenAddress); - - /** - * @dev Returns the amount of shares that the Vault would exchange for the amount of assets provided, in an ideal - * scenario where all the conditions are met. - * - * - MUST NOT be inclusive of any fees that are charged against assets in the Vault. - * - MUST NOT show any variations depending on the caller. - * - MUST NOT reflect slippage or other on-chain conditions, when performing the actual exchange. - * - MUST NOT revert. - * - * NOTE: This calculation MAY NOT reflect the “per-user” price-per-share, and instead should reflect the - * “average-user’s” price-per-share, meaning what the average user should expect to see when exchanging to and - * from. - */ - function convertToShares(uint256 assets) external view returns (uint256 shares); - - /** - * @dev Returns the amount of assets that the Vault would exchange for the amount of shares provided, in an ideal - * scenario where all the conditions are met. - * - * - MUST NOT be inclusive of any fees that are charged against assets in the Vault. - * - MUST NOT show any variations depending on the caller. - * - MUST NOT reflect slippage or other on-chain conditions, when performing the actual exchange. - * - MUST NOT revert. - * - * NOTE: This calculation MAY NOT reflect the “per-user” price-per-share, and instead should reflect the - * “average-user’s” price-per-share, meaning what the average user should expect to see when exchanging to and - * from. - */ - function convertToAssets(uint256 shares) external view returns (uint256 assets); - - /** - * @dev Returns the total amount of the underlying asset that is “managed” by Vault. - * - * - SHOULD include any compounding that occurs from yield. - * - MUST be inclusive of any fees that are charged against assets in the Vault. - * - MUST NOT revert. - */ - function totalAssets() external view returns (uint256 totalManagedAssets); - - /** - * @dev Returns the maximum amount of the underlying asset that can be deposited into the Vault for the receiver, - * through a deposit call. - * - * - MUST return a limited value if receiver is subject to some deposit limit. - * - MUST return 2 ** 256 - 1 if there is no limit on the maximum amount of assets that may be deposited. - * - MUST NOT revert. - */ - function maxDeposit(address receiver) external view returns (uint256 maxAssets); - - /** - * @dev Allows an on-chain or off-chain user to simulate the effects of their deposit at the current block, given - * current on-chain conditions. - * - * - MUST return as close to and no more than the exact amount of Vault shares that would be minted in a deposit - * call in the same transaction. I.e. deposit should return the same or more shares as previewDeposit if called - * in the same transaction. - * - MUST NOT account for deposit limits like those returned from maxDeposit and should always act as though the - * deposit would be accepted, regardless if the user has enough tokens approved, etc. - * - MUST be inclusive of deposit fees. Integrators should be aware of the existence of deposit fees. - * - MUST NOT revert. - * - * NOTE: any unfavorable discrepancy between convertToShares and previewDeposit SHOULD be considered slippage in - * share price or some other type of condition, meaning the depositor will lose assets by depositing. - */ - function previewDeposit(uint256 assets) external view returns (uint256 shares); - - /** - * @dev Mints shares Vault shares to receiver by depositing exactly amount of underlying tokens. - * - * - MUST emit the Deposit event. - * - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - * deposit execution, and are accounted for during deposit. - * - MUST revert if all of assets cannot be deposited (due to deposit limit being reached, slippage, the user not - * approving enough underlying tokens to the Vault contract, etc). - * - * NOTE: most implementations will require pre-approval of the Vault with the Vault’s underlying asset token. - */ - function deposit(uint256 assets, address receiver) external returns (uint256 shares); - - /** - * @dev Returns the maximum amount of the Vault shares that can be minted for the receiver, through a mint call. - * - MUST return a limited value if receiver is subject to some mint limit. - * - MUST return 2 ** 256 - 1 if there is no limit on the maximum amount of shares that may be minted. - * - MUST NOT revert. - */ - function maxMint(address receiver) external view returns (uint256 maxShares); - - /** - * @dev Allows an on-chain or off-chain user to simulate the effects of their mint at the current block, given - * current on-chain conditions. - * - * - MUST return as close to and no fewer than the exact amount of assets that would be deposited in a mint call - * in the same transaction. I.e. mint should return the same or fewer assets as previewMint if called in the - * same transaction. - * - MUST NOT account for mint limits like those returned from maxMint and should always act as though the mint - * would be accepted, regardless if the user has enough tokens approved, etc. - * - MUST be inclusive of deposit fees. Integrators should be aware of the existence of deposit fees. - * - MUST NOT revert. - * - * NOTE: any unfavorable discrepancy between convertToAssets and previewMint SHOULD be considered slippage in - * share price or some other type of condition, meaning the depositor will lose assets by minting. - */ - function previewMint(uint256 shares) external view returns (uint256 assets); - - /** - * @dev Mints exactly shares Vault shares to receiver by depositing amount of underlying tokens. - * - * - MUST emit the Deposit event. - * - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the mint - * execution, and are accounted for during mint. - * - MUST revert if all of shares cannot be minted (due to deposit limit being reached, slippage, the user not - * approving enough underlying tokens to the Vault contract, etc). - * - * NOTE: most implementations will require pre-approval of the Vault with the Vault’s underlying asset token. - */ - function mint(uint256 shares, address receiver) external returns (uint256 assets); - - /** - * @dev Returns the maximum amount of the underlying asset that can be withdrawn from the owner balance in the - * Vault, through a withdraw call. - * - * - MUST return a limited value if owner is subject to some withdrawal limit or timelock. - * - MUST NOT revert. - */ - function maxWithdraw(address owner) external view returns (uint256 maxAssets); - - /** - * @dev Allows an on-chain or off-chain user to simulate the effects of their withdrawal at the current block, - * given current on-chain conditions. - * - * - MUST return as close to and no fewer than the exact amount of Vault shares that would be burned in a withdraw - * call in the same transaction. I.e. withdraw should return the same or fewer shares as previewWithdraw if - * called - * in the same transaction. - * - MUST NOT account for withdrawal limits like those returned from maxWithdraw and should always act as though - * the withdrawal would be accepted, regardless if the user has enough shares, etc. - * - MUST be inclusive of withdrawal fees. Integrators should be aware of the existence of withdrawal fees. - * - MUST NOT revert. - * - * NOTE: any unfavorable discrepancy between convertToShares and previewWithdraw SHOULD be considered slippage in - * share price or some other type of condition, meaning the depositor will lose assets by depositing. - */ - function previewWithdraw(uint256 assets) external view returns (uint256 shares); - - /** - * @dev Burns shares from owner and sends exactly assets of underlying tokens to receiver. - * - * - MUST emit the Withdraw event. - * - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - * withdraw execution, and are accounted for during withdraw. - * - MUST revert if all of assets cannot be withdrawn (due to withdrawal limit being reached, slippage, the owner - * not having enough shares, etc). - * - * Note that some implementations will require pre-requesting to the Vault before a withdrawal may be performed. - * Those methods should be performed separately. - */ - function withdraw(uint256 assets, address receiver, address owner) external returns (uint256 shares); - - /** - * @dev Returns the maximum amount of Vault shares that can be redeemed from the owner balance in the Vault, - * through a redeem call. - * - * - MUST return a limited value if owner is subject to some withdrawal limit or timelock. - * - MUST return balanceOf(owner) if owner is not subject to any withdrawal limit or timelock. - * - MUST NOT revert. - */ - function maxRedeem(address owner) external view returns (uint256 maxShares); - - /** - * @dev Allows an on-chain or off-chain user to simulate the effects of their redeemption at the current block, - * given current on-chain conditions. - * - * - MUST return as close to and no more than the exact amount of assets that would be withdrawn in a redeem call - * in the same transaction. I.e. redeem should return the same or more assets as previewRedeem if called in the - * same transaction. - * - MUST NOT account for redemption limits like those returned from maxRedeem and should always act as though the - * redemption would be accepted, regardless if the user has enough shares, etc. - * - MUST be inclusive of withdrawal fees. Integrators should be aware of the existence of withdrawal fees. - * - MUST NOT revert. - * - * NOTE: any unfavorable discrepancy between convertToAssets and previewRedeem SHOULD be considered slippage in - * share price or some other type of condition, meaning the depositor will lose assets by redeeming. - */ - function previewRedeem(uint256 shares) external view returns (uint256 assets); - - /** - * @dev Burns exactly shares from owner and sends assets of underlying tokens to receiver. - * - * - MUST emit the Withdraw event. - * - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - * redeem execution, and are accounted for during redeem. - * - MUST revert if all of shares cannot be redeemed (due to withdrawal limit being reached, slippage, the owner - * not having enough shares, etc). - * - * NOTE: some implementations will require pre-requesting to the Vault before a withdrawal may be performed. - * Those methods should be performed separately. - */ - function redeem(uint256 shares, address receiver, address owner) external returns (uint256 assets); -} - -/// @dev Interface of the ERC20 share token, as defined in -/// https://eips.ethereum.org/EIPS/eip-7575 -interface IERC7575Share is IERC165 { - event VaultUpdate(address indexed asset, address vault); - - /** - * @dev Returns the address of the Vault for the given asset. - * - * @param asset the ERC-20 token to deposit with into the Vault - */ - function vault(address asset) external view returns (address); -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IMulticall3.sol b/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IMulticall3.sol deleted file mode 100644 index 0d031b71dc..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/interfaces/IMulticall3.sol +++ /dev/null @@ -1,73 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -interface IMulticall3 { - struct Call { - address target; - bytes callData; - } - - struct Call3 { - address target; - bool allowFailure; - bytes callData; - } - - struct Call3Value { - address target; - bool allowFailure; - uint256 value; - bytes callData; - } - - struct Result { - bool success; - bytes returnData; - } - - function aggregate(Call[] calldata calls) - external - payable - returns (uint256 blockNumber, bytes[] memory returnData); - - function aggregate3(Call3[] calldata calls) external payable returns (Result[] memory returnData); - - function aggregate3Value(Call3Value[] calldata calls) external payable returns (Result[] memory returnData); - - function blockAndAggregate(Call[] calldata calls) - external - payable - returns (uint256 blockNumber, bytes32 blockHash, Result[] memory returnData); - - function getBasefee() external view returns (uint256 basefee); - - function getBlockHash(uint256 blockNumber) external view returns (bytes32 blockHash); - - function getBlockNumber() external view returns (uint256 blockNumber); - - function getChainId() external view returns (uint256 chainid); - - function getCurrentBlockCoinbase() external view returns (address coinbase); - - function getCurrentBlockDifficulty() external view returns (uint256 difficulty); - - function getCurrentBlockGasLimit() external view returns (uint256 gaslimit); - - function getCurrentBlockTimestamp() external view returns (uint256 timestamp); - - function getEthBalance(address addr) external view returns (uint256 balance); - - function getLastBlockHash() external view returns (bytes32 blockHash); - - function tryAggregate(bool requireSuccess, Call[] calldata calls) - external - payable - returns (Result[] memory returnData); - - function tryBlockAndAggregate(bool requireSuccess, Call[] calldata calls) - external - payable - returns (uint256 blockNumber, bytes32 blockHash, Result[] memory returnData); -} diff --git a/lib/signals-implicit-mode/lib/forge-std/src/safeconsole.sol b/lib/signals-implicit-mode/lib/forge-std/src/safeconsole.sol deleted file mode 100644 index 87c475a5b0..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/src/safeconsole.sol +++ /dev/null @@ -1,13937 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -/// @author philogy -/// @dev Code generated automatically by script. -library safeconsole { - uint256 constant CONSOLE_ADDR = 0x000000000000000000000000000000000000000000636F6e736F6c652e6c6f67; - - // Credit to [0age](https://twitter.com/z0age/status/1654922202930888704) and [0xdapper](https://github.com/foundry-rs/forge-std/pull/374) - // for the view-to-pure log trick. - function _sendLogPayload(uint256 offset, uint256 size) private pure { - function(uint256, uint256) internal view fnIn = _sendLogPayloadView; - function(uint256, uint256) internal pure pureSendLogPayload; - /// @solidity memory-safe-assembly - assembly { - pureSendLogPayload := fnIn - } - pureSendLogPayload(offset, size); - } - - function _sendLogPayloadView(uint256 offset, uint256 size) private view { - /// @solidity memory-safe-assembly - assembly { - pop(staticcall(gas(), CONSOLE_ADDR, offset, size, 0x0, 0x0)) - } - } - - function _memcopy(uint256 fromOffset, uint256 toOffset, uint256 length) private pure { - function(uint256, uint256, uint256) internal view fnIn = _memcopyView; - function(uint256, uint256, uint256) internal pure pureMemcopy; - /// @solidity memory-safe-assembly - assembly { - pureMemcopy := fnIn - } - pureMemcopy(fromOffset, toOffset, length); - } - - function _memcopyView(uint256 fromOffset, uint256 toOffset, uint256 length) private view { - /// @solidity memory-safe-assembly - assembly { - pop(staticcall(gas(), 0x4, fromOffset, length, toOffset, length)) - } - } - - function logMemory(uint256 offset, uint256 length) internal pure { - if (offset >= 0x60) { - // Sufficient memory before slice to prepare call header. - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(sub(offset, 0x60)) - m1 := mload(sub(offset, 0x40)) - m2 := mload(sub(offset, 0x20)) - // Selector of `log(bytes)`. - mstore(sub(offset, 0x60), 0x0be77f56) - mstore(sub(offset, 0x40), 0x20) - mstore(sub(offset, 0x20), length) - } - _sendLogPayload(offset - 0x44, length + 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(sub(offset, 0x60), m0) - mstore(sub(offset, 0x40), m1) - mstore(sub(offset, 0x20), m2) - } - } else { - // Insufficient space, so copy slice forward, add header and reverse. - bytes32 m0; - bytes32 m1; - bytes32 m2; - uint256 endOffset = offset + length; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(add(endOffset, 0x00)) - m1 := mload(add(endOffset, 0x20)) - m2 := mload(add(endOffset, 0x40)) - } - _memcopy(offset, offset + 0x60, length); - /// @solidity memory-safe-assembly - assembly { - // Selector of `log(bytes)`. - mstore(add(offset, 0x00), 0x0be77f56) - mstore(add(offset, 0x20), 0x20) - mstore(add(offset, 0x40), length) - } - _sendLogPayload(offset + 0x1c, length + 0x44); - _memcopy(offset + 0x60, offset, length); - /// @solidity memory-safe-assembly - assembly { - mstore(add(endOffset, 0x00), m0) - mstore(add(endOffset, 0x20), m1) - mstore(add(endOffset, 0x40), m2) - } - } - } - - function log(address p0) internal pure { - bytes32 m0; - bytes32 m1; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - // Selector of `log(address)`. - mstore(0x00, 0x2c2ecbc2) - mstore(0x20, p0) - } - _sendLogPayload(0x1c, 0x24); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - } - } - - function log(bool p0) internal pure { - bytes32 m0; - bytes32 m1; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - // Selector of `log(bool)`. - mstore(0x00, 0x32458eed) - mstore(0x20, p0) - } - _sendLogPayload(0x1c, 0x24); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - } - } - - function log(uint256 p0) internal pure { - bytes32 m0; - bytes32 m1; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - // Selector of `log(uint256)`. - mstore(0x00, 0xf82c50f1) - mstore(0x20, p0) - } - _sendLogPayload(0x1c, 0x24); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - } - } - - function log(bytes32 p0) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(string)`. - mstore(0x00, 0x41304fac) - mstore(0x20, 0x20) - writeString(0x40, p0) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, address p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(address,address)`. - mstore(0x00, 0xdaf0d4aa) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(address p0, bool p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(address,bool)`. - mstore(0x00, 0x75b605d3) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(address p0, uint256 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(address,uint256)`. - mstore(0x00, 0x8309e8a8) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(address p0, bytes32 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,string)`. - mstore(0x00, 0x759f86bb) - mstore(0x20, p0) - mstore(0x40, 0x40) - writeString(0x60, p1) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(bool,address)`. - mstore(0x00, 0x853c4849) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(bool p0, bool p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(bool,bool)`. - mstore(0x00, 0x2a110e83) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(bool p0, uint256 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(bool,uint256)`. - mstore(0x00, 0x399174d3) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(bool p0, bytes32 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,string)`. - mstore(0x00, 0x8feac525) - mstore(0x20, p0) - mstore(0x40, 0x40) - writeString(0x60, p1) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(uint256,address)`. - mstore(0x00, 0x69276c86) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(uint256 p0, bool p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(uint256,bool)`. - mstore(0x00, 0x1c9d7eb3) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(uint256 p0, uint256 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(uint256,uint256)`. - mstore(0x00, 0xf666715a) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(uint256 p0, bytes32 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,string)`. - mstore(0x00, 0x643fd0df) - mstore(0x20, p0) - mstore(0x40, 0x40) - writeString(0x60, p1) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bytes32 p0, address p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(string,address)`. - mstore(0x00, 0x319af333) - mstore(0x20, 0x40) - mstore(0x40, p1) - writeString(0x60, p0) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bytes32 p0, bool p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(string,bool)`. - mstore(0x00, 0xc3b55635) - mstore(0x20, 0x40) - mstore(0x40, p1) - writeString(0x60, p0) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bytes32 p0, uint256 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(string,uint256)`. - mstore(0x00, 0xb60e72cc) - mstore(0x20, 0x40) - mstore(0x40, p1) - writeString(0x60, p0) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bytes32 p0, bytes32 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,string)`. - mstore(0x00, 0x4b5c4277) - mstore(0x20, 0x40) - mstore(0x40, 0x80) - writeString(0x60, p0) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,address,address)`. - mstore(0x00, 0x018c84c2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, address p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,address,bool)`. - mstore(0x00, 0xf2a66286) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, address p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,address,uint256)`. - mstore(0x00, 0x17fe6185) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, address p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,address,string)`. - mstore(0x00, 0x007150be) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bool p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,bool,address)`. - mstore(0x00, 0xf11699ed) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, bool p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,bool,bool)`. - mstore(0x00, 0xeb830c92) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, bool p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,bool,uint256)`. - mstore(0x00, 0x9c4f99fb) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, bool p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,bool,string)`. - mstore(0x00, 0x212255cc) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, uint256 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,uint256,address)`. - mstore(0x00, 0x7bc0d848) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, uint256 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,uint256,bool)`. - mstore(0x00, 0x678209a8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, uint256 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,uint256,uint256)`. - mstore(0x00, 0xb69bcaf6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, uint256 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,uint256,string)`. - mstore(0x00, 0xa1f2e8aa) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bytes32 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,string,address)`. - mstore(0x00, 0xf08744e8) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bytes32 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,string,bool)`. - mstore(0x00, 0xcf020fb1) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bytes32 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,string,uint256)`. - mstore(0x00, 0x67dd6ff1) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bytes32 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(address,string,string)`. - mstore(0x00, 0xfb772265) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, 0xa0) - writeString(0x80, p1) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bool p0, address p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,address,address)`. - mstore(0x00, 0xd2763667) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, address p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,address,bool)`. - mstore(0x00, 0x18c9c746) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, address p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,address,uint256)`. - mstore(0x00, 0x5f7b9afb) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, address p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,address,string)`. - mstore(0x00, 0xde9a9270) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bool p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,bool,address)`. - mstore(0x00, 0x1078f68d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, bool p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,bool,bool)`. - mstore(0x00, 0x50709698) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, bool p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,bool,uint256)`. - mstore(0x00, 0x12f21602) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, bool p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,bool,string)`. - mstore(0x00, 0x2555fa46) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, uint256 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,uint256,address)`. - mstore(0x00, 0x088ef9d2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, uint256 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,uint256,bool)`. - mstore(0x00, 0xe8defba9) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, uint256 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,uint256,uint256)`. - mstore(0x00, 0x37103367) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, uint256 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,uint256,string)`. - mstore(0x00, 0xc3fc3970) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bytes32 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,string,address)`. - mstore(0x00, 0x9591b953) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bytes32 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,string,bool)`. - mstore(0x00, 0xdbb4c247) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bytes32 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,string,uint256)`. - mstore(0x00, 0x1093ee11) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(bool,string,string)`. - mstore(0x00, 0xb076847f) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, 0xa0) - writeString(0x80, p1) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(uint256 p0, address p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,address,address)`. - mstore(0x00, 0xbcfd9be0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, address p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,address,bool)`. - mstore(0x00, 0x9b6ec042) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, address p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,address,uint256)`. - mstore(0x00, 0x5a9b5ed5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, address p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,address,string)`. - mstore(0x00, 0x63cb41f9) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bool p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,bool,address)`. - mstore(0x00, 0x35085f7b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, bool p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,bool,bool)`. - mstore(0x00, 0x20718650) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, bool p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,bool,uint256)`. - mstore(0x00, 0x20098014) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, bool p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,bool,string)`. - mstore(0x00, 0x85775021) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, uint256 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,uint256,address)`. - mstore(0x00, 0x5c96b331) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, uint256 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,uint256,bool)`. - mstore(0x00, 0x4766da72) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,uint256,uint256)`. - mstore(0x00, 0xd1ed7a3c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,uint256,string)`. - mstore(0x00, 0x71d04af2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bytes32 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,string,address)`. - mstore(0x00, 0x7afac959) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bytes32 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,string,bool)`. - mstore(0x00, 0x4ceda75a) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,string,uint256)`. - mstore(0x00, 0x37aa7d4c) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(uint256,string,string)`. - mstore(0x00, 0xb115611f) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, 0xa0) - writeString(0x80, p1) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, address p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,address,address)`. - mstore(0x00, 0xfcec75e0) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, address p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,address,bool)`. - mstore(0x00, 0xc91d5ed4) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, address p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,address,uint256)`. - mstore(0x00, 0x0d26b925) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, address p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,address,string)`. - mstore(0x00, 0xe0e9ad4f) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, 0xa0) - writeString(0x80, p0) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bool p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,bool,address)`. - mstore(0x00, 0x932bbb38) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, bool p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,bool,bool)`. - mstore(0x00, 0x850b7ad6) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, bool p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,bool,uint256)`. - mstore(0x00, 0xc95958d6) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,bool,string)`. - mstore(0x00, 0xe298f47d) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, 0xa0) - writeString(0x80, p0) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, uint256 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,uint256,address)`. - mstore(0x00, 0x1c7ec448) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, uint256 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,uint256,bool)`. - mstore(0x00, 0xca7733b1) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,uint256,uint256)`. - mstore(0x00, 0xca47c4eb) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,uint256,string)`. - mstore(0x00, 0x5970e089) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, 0xa0) - writeString(0x80, p0) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bytes32 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,string,address)`. - mstore(0x00, 0x95ed0195) - mstore(0x20, 0x60) - mstore(0x40, 0xa0) - mstore(0x60, p2) - writeString(0x80, p0) - writeString(0xc0, p1) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,string,bool)`. - mstore(0x00, 0xb0e0f9b5) - mstore(0x20, 0x60) - mstore(0x40, 0xa0) - mstore(0x60, p2) - writeString(0x80, p0) - writeString(0xc0, p1) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,string,uint256)`. - mstore(0x00, 0x5821efa1) - mstore(0x20, 0x60) - mstore(0x40, 0xa0) - mstore(0x60, p2) - writeString(0x80, p0) - writeString(0xc0, p1) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - // Selector of `log(string,string,string)`. - mstore(0x00, 0x2ced7cef) - mstore(0x20, 0x60) - mstore(0x40, 0xa0) - mstore(0x60, 0xe0) - writeString(0x80, p0) - writeString(0xc0, p1) - writeString(0x100, p2) - } - _sendLogPayload(0x1c, 0x124); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - } - } - - function log(address p0, address p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,address,address)`. - mstore(0x00, 0x665bf134) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,address,bool)`. - mstore(0x00, 0x0e378994) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,address,uint256)`. - mstore(0x00, 0x94250d77) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,address,string)`. - mstore(0x00, 0xf808da20) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,bool,address)`. - mstore(0x00, 0x9f1bc36e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,bool,bool)`. - mstore(0x00, 0x2cd4134a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,bool,uint256)`. - mstore(0x00, 0x3971e78c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,bool,string)`. - mstore(0x00, 0xaa6540c8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,uint256,address)`. - mstore(0x00, 0x8da6def5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,uint256,bool)`. - mstore(0x00, 0x9b4254e2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,uint256,uint256)`. - mstore(0x00, 0xbe553481) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,uint256,string)`. - mstore(0x00, 0xfdb4f990) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,string,address)`. - mstore(0x00, 0x8f736d16) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,string,bool)`. - mstore(0x00, 0x6f1a594e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,string,uint256)`. - mstore(0x00, 0xef1cefe7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,address,string,string)`. - mstore(0x00, 0x21bdaf25) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bool p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,address,address)`. - mstore(0x00, 0x660375dd) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,address,bool)`. - mstore(0x00, 0xa6f50b0f) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,address,uint256)`. - mstore(0x00, 0xa75c59de) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,address,string)`. - mstore(0x00, 0x2dd778e6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,bool,address)`. - mstore(0x00, 0xcf394485) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,bool,bool)`. - mstore(0x00, 0xcac43479) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,bool,uint256)`. - mstore(0x00, 0x8c4e5de6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,bool,string)`. - mstore(0x00, 0xdfc4a2e8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,uint256,address)`. - mstore(0x00, 0xccf790a1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,uint256,bool)`. - mstore(0x00, 0xc4643e20) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,uint256,uint256)`. - mstore(0x00, 0x386ff5f4) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,uint256,string)`. - mstore(0x00, 0x0aa6cfad) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,string,address)`. - mstore(0x00, 0x19fd4956) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,string,bool)`. - mstore(0x00, 0x50ad461d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,string,uint256)`. - mstore(0x00, 0x80e6a20b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,bool,string,string)`. - mstore(0x00, 0x475c5c33) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, uint256 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,address,address)`. - mstore(0x00, 0x478d1c62) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,address,bool)`. - mstore(0x00, 0xa1bcc9b3) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,address,uint256)`. - mstore(0x00, 0x100f650e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,address,string)`. - mstore(0x00, 0x1da986ea) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,bool,address)`. - mstore(0x00, 0xa31bfdcc) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,bool,bool)`. - mstore(0x00, 0x3bf5e537) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,bool,uint256)`. - mstore(0x00, 0x22f6b999) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,bool,string)`. - mstore(0x00, 0xc5ad85f9) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,uint256,address)`. - mstore(0x00, 0x20e3984d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,uint256,bool)`. - mstore(0x00, 0x66f1bc67) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,uint256,uint256)`. - mstore(0x00, 0x34f0e636) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,uint256,string)`. - mstore(0x00, 0x4a28c017) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,string,address)`. - mstore(0x00, 0x5c430d47) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,string,bool)`. - mstore(0x00, 0xcf18105c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,string,uint256)`. - mstore(0x00, 0xbf01f891) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,uint256,string,string)`. - mstore(0x00, 0x88a8c406) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,address,address)`. - mstore(0x00, 0x0d36fa20) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,address,bool)`. - mstore(0x00, 0x0df12b76) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,address,uint256)`. - mstore(0x00, 0x457fe3cf) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,address,string)`. - mstore(0x00, 0xf7e36245) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,bool,address)`. - mstore(0x00, 0x205871c2) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,bool,bool)`. - mstore(0x00, 0x5f1d5c9f) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,bool,uint256)`. - mstore(0x00, 0x515e38b6) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,bool,string)`. - mstore(0x00, 0xbc0b61fe) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,uint256,address)`. - mstore(0x00, 0x63183678) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,uint256,bool)`. - mstore(0x00, 0x0ef7e050) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,uint256,uint256)`. - mstore(0x00, 0x1dc8e1b8) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,uint256,string)`. - mstore(0x00, 0x448830a8) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,string,address)`. - mstore(0x00, 0xa04e2f87) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,string,bool)`. - mstore(0x00, 0x35a5071f) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,string,uint256)`. - mstore(0x00, 0x159f8927) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(address,string,string,string)`. - mstore(0x00, 0x5d02c50b) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p1) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bool p0, address p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,address,address)`. - mstore(0x00, 0x1d14d001) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,address,bool)`. - mstore(0x00, 0x46600be0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,address,uint256)`. - mstore(0x00, 0x0c66d1be) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,address,string)`. - mstore(0x00, 0xd812a167) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,bool,address)`. - mstore(0x00, 0x1c41a336) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,bool,bool)`. - mstore(0x00, 0x6a9c478b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,bool,uint256)`. - mstore(0x00, 0x07831502) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,bool,string)`. - mstore(0x00, 0x4a66cb34) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,uint256,address)`. - mstore(0x00, 0x136b05dd) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,uint256,bool)`. - mstore(0x00, 0xd6019f1c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,uint256,uint256)`. - mstore(0x00, 0x7bf181a1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,uint256,string)`. - mstore(0x00, 0x51f09ff8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,string,address)`. - mstore(0x00, 0x6f7c603e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,string,bool)`. - mstore(0x00, 0xe2bfd60b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,string,uint256)`. - mstore(0x00, 0xc21f64c7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,address,string,string)`. - mstore(0x00, 0xa73c1db6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bool p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,address,address)`. - mstore(0x00, 0xf4880ea4) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,address,bool)`. - mstore(0x00, 0xc0a302d8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,address,uint256)`. - mstore(0x00, 0x4c123d57) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,address,string)`. - mstore(0x00, 0xa0a47963) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,bool,address)`. - mstore(0x00, 0x8c329b1a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,bool,bool)`. - mstore(0x00, 0x3b2a5ce0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,bool,uint256)`. - mstore(0x00, 0x6d7045c1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,bool,string)`. - mstore(0x00, 0x2ae408d4) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,uint256,address)`. - mstore(0x00, 0x54a7a9a0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,uint256,bool)`. - mstore(0x00, 0x619e4d0e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,uint256,uint256)`. - mstore(0x00, 0x0bb00eab) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,uint256,string)`. - mstore(0x00, 0x7dd4d0e0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,string,address)`. - mstore(0x00, 0xf9ad2b89) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,string,bool)`. - mstore(0x00, 0xb857163a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,string,uint256)`. - mstore(0x00, 0xe3a9ca2f) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,bool,string,string)`. - mstore(0x00, 0x6d1e8751) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, uint256 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,address,address)`. - mstore(0x00, 0x26f560a8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,address,bool)`. - mstore(0x00, 0xb4c314ff) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,address,uint256)`. - mstore(0x00, 0x1537dc87) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,address,string)`. - mstore(0x00, 0x1bb3b09a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,bool,address)`. - mstore(0x00, 0x9acd3616) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,bool,bool)`. - mstore(0x00, 0xceb5f4d7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,bool,uint256)`. - mstore(0x00, 0x7f9bbca2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,bool,string)`. - mstore(0x00, 0x9143dbb1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,uint256,address)`. - mstore(0x00, 0x00dd87b9) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,uint256,bool)`. - mstore(0x00, 0xbe984353) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,uint256,uint256)`. - mstore(0x00, 0x374bb4b2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,uint256,string)`. - mstore(0x00, 0x8e69fb5d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,string,address)`. - mstore(0x00, 0xfedd1fff) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,string,bool)`. - mstore(0x00, 0xe5e70b2b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,string,uint256)`. - mstore(0x00, 0x6a1199e2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,uint256,string,string)`. - mstore(0x00, 0xf5bc2249) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,address,address)`. - mstore(0x00, 0x2b2b18dc) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,address,bool)`. - mstore(0x00, 0x6dd434ca) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,address,uint256)`. - mstore(0x00, 0xa5cada94) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,address,string)`. - mstore(0x00, 0x12d6c788) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,bool,address)`. - mstore(0x00, 0x538e06ab) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,bool,bool)`. - mstore(0x00, 0xdc5e935b) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,bool,uint256)`. - mstore(0x00, 0x1606a393) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,bool,string)`. - mstore(0x00, 0x483d0416) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,uint256,address)`. - mstore(0x00, 0x1596a1ce) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,uint256,bool)`. - mstore(0x00, 0x6b0e5d53) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,uint256,uint256)`. - mstore(0x00, 0x28863fcb) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,uint256,string)`. - mstore(0x00, 0x1ad96de6) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,string,address)`. - mstore(0x00, 0x97d394d8) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,string,bool)`. - mstore(0x00, 0x1e4b87e5) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,string,uint256)`. - mstore(0x00, 0x7be0c3eb) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(bool,string,string,string)`. - mstore(0x00, 0x1762e32a) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p1) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(uint256 p0, address p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,address,address)`. - mstore(0x00, 0x2488b414) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,address,bool)`. - mstore(0x00, 0x091ffaf5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,address,uint256)`. - mstore(0x00, 0x736efbb6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,address,string)`. - mstore(0x00, 0x031c6f73) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,bool,address)`. - mstore(0x00, 0xef72c513) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,bool,bool)`. - mstore(0x00, 0xe351140f) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,bool,uint256)`. - mstore(0x00, 0x5abd992a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,bool,string)`. - mstore(0x00, 0x90fb06aa) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,uint256,address)`. - mstore(0x00, 0x15c127b5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,uint256,bool)`. - mstore(0x00, 0x5f743a7c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,uint256,uint256)`. - mstore(0x00, 0x0c9cd9c1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,uint256,string)`. - mstore(0x00, 0xddb06521) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,string,address)`. - mstore(0x00, 0x9cba8fff) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,string,bool)`. - mstore(0x00, 0xcc32ab07) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,string,uint256)`. - mstore(0x00, 0x46826b5d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,address,string,string)`. - mstore(0x00, 0x3e128ca3) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bool p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,address,address)`. - mstore(0x00, 0xa1ef4cbb) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,address,bool)`. - mstore(0x00, 0x454d54a5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,address,uint256)`. - mstore(0x00, 0x078287f5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,address,string)`. - mstore(0x00, 0xade052c7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,bool,address)`. - mstore(0x00, 0x69640b59) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,bool,bool)`. - mstore(0x00, 0xb6f577a1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,bool,uint256)`. - mstore(0x00, 0x7464ce23) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,bool,string)`. - mstore(0x00, 0xdddb9561) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,uint256,address)`. - mstore(0x00, 0x88cb6041) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,uint256,bool)`. - mstore(0x00, 0x91a02e2a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,uint256,uint256)`. - mstore(0x00, 0xc6acc7a8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,uint256,string)`. - mstore(0x00, 0xde03e774) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,string,address)`. - mstore(0x00, 0xef529018) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,string,bool)`. - mstore(0x00, 0xeb928d7f) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,string,uint256)`. - mstore(0x00, 0x2c1d0746) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,bool,string,string)`. - mstore(0x00, 0x68c8b8bd) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, uint256 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,address,address)`. - mstore(0x00, 0x56a5d1b1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,address,bool)`. - mstore(0x00, 0x15cac476) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,address,uint256)`. - mstore(0x00, 0x88f6e4b2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,address,string)`. - mstore(0x00, 0x6cde40b8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,bool,address)`. - mstore(0x00, 0x9a816a83) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,bool,bool)`. - mstore(0x00, 0xab085ae6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,bool,uint256)`. - mstore(0x00, 0xeb7f6fd2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,bool,string)`. - mstore(0x00, 0xa5b4fc99) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,uint256,address)`. - mstore(0x00, 0xfa8185af) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,uint256,bool)`. - mstore(0x00, 0xc598d185) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,uint256,uint256)`. - mstore(0x00, 0x193fb800) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,uint256,string)`. - mstore(0x00, 0x59cfcbe3) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,string,address)`. - mstore(0x00, 0x42d21db7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,string,bool)`. - mstore(0x00, 0x7af6ab25) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,string,uint256)`. - mstore(0x00, 0x5da297eb) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,uint256,string,string)`. - mstore(0x00, 0x27d8afd2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,address,address)`. - mstore(0x00, 0x6168ed61) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,address,bool)`. - mstore(0x00, 0x90c30a56) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,address,uint256)`. - mstore(0x00, 0xe8d3018d) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,address,string)`. - mstore(0x00, 0x9c3adfa1) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,bool,address)`. - mstore(0x00, 0xae2ec581) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,bool,bool)`. - mstore(0x00, 0xba535d9c) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,bool,uint256)`. - mstore(0x00, 0xcf009880) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,bool,string)`. - mstore(0x00, 0xd2d423cd) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,uint256,address)`. - mstore(0x00, 0x3b2279b4) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,uint256,bool)`. - mstore(0x00, 0x691a8f74) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,uint256,uint256)`. - mstore(0x00, 0x82c25b74) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,uint256,string)`. - mstore(0x00, 0xb7b914ca) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,string,address)`. - mstore(0x00, 0xd583c602) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,string,bool)`. - mstore(0x00, 0xb3a6b6bd) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,string,uint256)`. - mstore(0x00, 0xb028c9bd) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(uint256,string,string,string)`. - mstore(0x00, 0x21ad0683) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p1) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, address p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,address,address)`. - mstore(0x00, 0xed8f28f6) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,address,bool)`. - mstore(0x00, 0xb59dbd60) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,address,uint256)`. - mstore(0x00, 0x8ef3f399) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,address,string)`. - mstore(0x00, 0x800a1c67) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,bool,address)`. - mstore(0x00, 0x223603bd) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,bool,bool)`. - mstore(0x00, 0x79884c2b) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,bool,uint256)`. - mstore(0x00, 0x3e9f866a) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,bool,string)`. - mstore(0x00, 0x0454c079) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,uint256,address)`. - mstore(0x00, 0x63fb8bc5) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,uint256,bool)`. - mstore(0x00, 0xfc4845f0) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,uint256,uint256)`. - mstore(0x00, 0xf8f51b1e) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,uint256,string)`. - mstore(0x00, 0x5a477632) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,string,address)`. - mstore(0x00, 0xaabc9a31) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,string,bool)`. - mstore(0x00, 0x5f15d28c) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,string,uint256)`. - mstore(0x00, 0x91d1112e) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,address,string,string)`. - mstore(0x00, 0x245986f2) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bool p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,address,address)`. - mstore(0x00, 0x33e9dd1d) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,address,bool)`. - mstore(0x00, 0x958c28c6) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,address,uint256)`. - mstore(0x00, 0x5d08bb05) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,address,string)`. - mstore(0x00, 0x2d8e33a4) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,bool,address)`. - mstore(0x00, 0x7190a529) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,bool,bool)`. - mstore(0x00, 0x895af8c5) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,bool,uint256)`. - mstore(0x00, 0x8e3f78a9) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,bool,string)`. - mstore(0x00, 0x9d22d5dd) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,uint256,address)`. - mstore(0x00, 0x935e09bf) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,uint256,bool)`. - mstore(0x00, 0x8af7cf8a) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,uint256,uint256)`. - mstore(0x00, 0x64b5bb67) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,uint256,string)`. - mstore(0x00, 0x742d6ee7) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,string,address)`. - mstore(0x00, 0xe0625b29) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,string,bool)`. - mstore(0x00, 0x3f8a701d) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,string,uint256)`. - mstore(0x00, 0x24f91465) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,bool,string,string)`. - mstore(0x00, 0xa826caeb) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, uint256 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,address,address)`. - mstore(0x00, 0x5ea2b7ae) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,address,bool)`. - mstore(0x00, 0x82112a42) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,address,uint256)`. - mstore(0x00, 0x4f04fdc6) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,address,string)`. - mstore(0x00, 0x9ffb2f93) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,bool,address)`. - mstore(0x00, 0xe0e95b98) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,bool,bool)`. - mstore(0x00, 0x354c36d6) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,bool,uint256)`. - mstore(0x00, 0xe41b6f6f) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,bool,string)`. - mstore(0x00, 0xabf73a98) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,uint256,address)`. - mstore(0x00, 0xe21de278) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,uint256,bool)`. - mstore(0x00, 0x7626db92) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,uint256,uint256)`. - mstore(0x00, 0xa7a87853) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,uint256,string)`. - mstore(0x00, 0x854b3496) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,string,address)`. - mstore(0x00, 0x7c4632a4) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,string,bool)`. - mstore(0x00, 0x7d24491d) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,string,uint256)`. - mstore(0x00, 0xc67ea9d1) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,uint256,string,string)`. - mstore(0x00, 0x5ab84e1f) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,address,address)`. - mstore(0x00, 0x439c7bef) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,address,bool)`. - mstore(0x00, 0x5ccd4e37) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,address,uint256)`. - mstore(0x00, 0x7cc3c607) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,address,string)`. - mstore(0x00, 0xeb1bff80) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,bool,address)`. - mstore(0x00, 0xc371c7db) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,bool,bool)`. - mstore(0x00, 0x40785869) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,bool,uint256)`. - mstore(0x00, 0xd6aefad2) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,bool,string)`. - mstore(0x00, 0x5e84b0ea) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,uint256,address)`. - mstore(0x00, 0x1023f7b2) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,uint256,bool)`. - mstore(0x00, 0xc3a8a654) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,uint256,uint256)`. - mstore(0x00, 0xf45d7d2c) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,uint256,string)`. - mstore(0x00, 0x5d1a971a) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,string,address)`. - mstore(0x00, 0x6d572f44) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, 0x100) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p2) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,string,bool)`. - mstore(0x00, 0x2c1754ed) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, 0x100) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p2) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,string,uint256)`. - mstore(0x00, 0x8eafb02b) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, 0x100) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p2) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - bytes32 m11; - bytes32 m12; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - m11 := mload(0x160) - m12 := mload(0x180) - // Selector of `log(string,string,string,string)`. - mstore(0x00, 0xde68f20a) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, 0x100) - mstore(0x80, 0x140) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p2) - writeString(0x160, p3) - } - _sendLogPayload(0x1c, 0x184); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - mstore(0x160, m11) - mstore(0x180, m12) - } - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/CommonBase.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/CommonBase.t.sol deleted file mode 100644 index 4a6eb34fd8..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/CommonBase.t.sol +++ /dev/null @@ -1,44 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {CommonBase} from "../src/Base.sol"; -import {StdConstants} from "../src/StdConstants.sol"; -import {Test} from "../src/Test.sol"; - -contract CommonBaseTest is Test { - function testVmAddressValue() public pure { - assertEq(VM_ADDRESS, address(StdConstants.VM)); - } - - function testConsoleValue() public pure { - assertEq(CONSOLE, StdConstants.CONSOLE); - } - - function testCreate2FactoryValue() public pure { - assertEq(CREATE2_FACTORY, StdConstants.CREATE2_FACTORY); - } - - function testDefaultSenderValue() public pure { - assertEq(DEFAULT_SENDER, StdConstants.DEFAULT_SENDER); - } - - function testDefaultTestContractValue() public pure { - assertEq(DEFAULT_TEST_CONTRACT, StdConstants.DEFAULT_TEST_CONTRACT); - } - - function testMulticall3AddressValue() public pure { - assertEq(MULTICALL3_ADDRESS, address(StdConstants.MULTICALL3_ADDRESS)); - } - - function testSecp256k1OrderValue() public pure { - assertEq(SECP256K1_ORDER, StdConstants.SECP256K1_ORDER); - } - - function testUint256MaxValue() public pure { - assertEq(UINT256_MAX, type(uint256).max); - } - - function testVmValue() public pure { - assertEq(address(vm), address(StdConstants.VM)); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/Config.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/Config.t.sol deleted file mode 100644 index 8e2342cade..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/Config.t.sol +++ /dev/null @@ -1,352 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.13; - -import {Test} from "../src/Test.sol"; -import {Config} from "../src/Config.sol"; -import {StdConfig} from "../src/StdConfig.sol"; - -contract ConfigTest is Test, Config { - function setUp() public { - vm.setEnv("MAINNET_RPC", "https://eth.llamarpc.com"); - vm.setEnv("WETH_MAINNET", "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"); - vm.setEnv("OPTIMISM_RPC", "https://mainnet.optimism.io"); - vm.setEnv("WETH_OPTIMISM", "0x4200000000000000000000000000000000000006"); - } - - function test_loadConfig() public { - // Deploy the config contract with the test fixture. - _loadConfig("./test/fixtures/config.toml", false); - - // -- MAINNET -------------------------------------------------------------- - - // Read and assert RPC URL for Mainnet (chain ID 1) - assertEq(config.getRpcUrl(1), "https://eth.llamarpc.com"); - - // Read and assert boolean values - assertTrue(config.get(1, "is_live").toBool()); - bool[] memory bool_array = config.get(1, "bool_array").toBoolArray(); - assertTrue(bool_array[0]); - assertFalse(bool_array[1]); - - // Read and assert address values - assertEq(config.get(1, "weth").toAddress(), 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2); - address[] memory address_array = config.get(1, "deps").toAddressArray(); - assertEq(address_array[0], 0x0000000000000000000000000000000000000000); - assertEq(address_array[1], 0x1111111111111111111111111111111111111111); - - // Read and assert bytes32 values - assertEq(config.get(1, "word").toBytes32(), bytes32(uint256(1234))); - bytes32[] memory bytes32_array = config.get(1, "word_array").toBytes32Array(); - assertEq(bytes32_array[0], bytes32(uint256(5678))); - assertEq(bytes32_array[1], bytes32(uint256(9999))); - - // Read and assert uint values - assertEq(config.get(1, "number").toUint256(), 1234); - uint256[] memory uint_array = config.get(1, "number_array").toUint256Array(); - assertEq(uint_array[0], 5678); - assertEq(uint_array[1], 9999); - - // Read and assert int values - assertEq(config.get(1, "signed_number").toInt256(), -1234); - int256[] memory int_array = config.get(1, "signed_number_array").toInt256Array(); - assertEq(int_array[0], -5678); - assertEq(int_array[1], 9999); - - // Read and assert bytes values - assertEq(config.get(1, "b").toBytes(), hex"abcd"); - bytes[] memory bytes_array = config.get(1, "b_array").toBytesArray(); - assertEq(bytes_array[0], hex"dead"); - assertEq(bytes_array[1], hex"beef"); - - // Read and assert string values - assertEq(config.get(1, "str").toString(), "foo"); - string[] memory string_array = config.get(1, "str_array").toStringArray(); - assertEq(string_array[0], "bar"); - assertEq(string_array[1], "baz"); - - // -- OPTIMISM ------------------------------------------------------------ - - // Read and assert RPC URL for Optimism (chain ID 10) - assertEq(config.getRpcUrl(10), "https://mainnet.optimism.io"); - - // Read and assert boolean values - assertFalse(config.get(10, "is_live").toBool()); - bool_array = config.get(10, "bool_array").toBoolArray(); - assertFalse(bool_array[0]); - assertTrue(bool_array[1]); - - // Read and assert address values - assertEq(config.get(10, "weth").toAddress(), 0x4200000000000000000000000000000000000006); - address_array = config.get(10, "deps").toAddressArray(); - assertEq(address_array[0], 0x2222222222222222222222222222222222222222); - assertEq(address_array[1], 0x3333333333333333333333333333333333333333); - - // Read and assert bytes32 values - assertEq(config.get(10, "word").toBytes32(), bytes32(uint256(9999))); - bytes32_array = config.get(10, "word_array").toBytes32Array(); - assertEq(bytes32_array[0], bytes32(uint256(1234))); - assertEq(bytes32_array[1], bytes32(uint256(5678))); - - // Read and assert uint values - assertEq(config.get(10, "number").toUint256(), 9999); - uint_array = config.get(10, "number_array").toUint256Array(); - assertEq(uint_array[0], 1234); - assertEq(uint_array[1], 5678); - - // Read and assert int values - assertEq(config.get(10, "signed_number").toInt256(), 9999); - int_array = config.get(10, "signed_number_array").toInt256Array(); - assertEq(int_array[0], -1234); - assertEq(int_array[1], -5678); - - // Read and assert bytes values - assertEq(config.get(10, "b").toBytes(), hex"dcba"); - bytes_array = config.get(10, "b_array").toBytesArray(); - assertEq(bytes_array[0], hex"c0ffee"); - assertEq(bytes_array[1], hex"babe"); - - // Read and assert string values - assertEq(config.get(10, "str").toString(), "alice"); - string_array = config.get(10, "str_array").toStringArray(); - assertEq(string_array[0], "bob"); - assertEq(string_array[1], "charlie"); - } - - function test_loadConfigAndForks() public { - _loadConfigAndForks("./test/fixtures/config.toml", false); - - // assert that the map of chain id and fork ids is created and that the chain ids actually match - assertEq(forkOf[1], 0); - vm.selectFork(forkOf[1]); - assertEq(vm.getChainId(), 1); - - assertEq(forkOf[10], 1); - vm.selectFork(forkOf[10]); - assertEq(vm.getChainId(), 10); - } - - function test_writeConfig() public { - // Create a temporary copy of the config file to avoid modifying the original. - string memory originalConfig = "./test/fixtures/config.toml"; - string memory testConfig = "./test/fixtures/config.t.toml"; - vm.copyFile(originalConfig, testConfig); - - // Deploy the config contract with the temporary fixture. - _loadConfig(testConfig, false); - - // Enable writing to file bypassing the context check. - vm.store(address(config), bytes32(uint256(5)), bytes32(uint256(1))); - - { - // Update a single boolean value and verify the change. - config.set(1, "is_live", false); - - assertFalse(config.get(1, "is_live").toBool()); - - string memory content = vm.readFile(testConfig); - assertFalse(vm.parseTomlBool(content, "$.mainnet.bool.is_live")); - - // Update a single address value and verify the change. - address new_addr = 0xDeaDbeefdEAdbeefdEadbEEFdeadbeEFdEaDbeeF; - config.set(1, "weth", new_addr); - - assertEq(config.get(1, "weth").toAddress(), new_addr); - - content = vm.readFile(testConfig); - assertEq(vm.parseTomlAddress(content, "$.mainnet.address.weth"), new_addr); - - // Update a uint array and verify the change. - uint256[] memory new_numbers = new uint256[](3); - new_numbers[0] = 1; - new_numbers[1] = 2; - new_numbers[2] = 3; - config.set(10, "number_array", new_numbers); - - uint256[] memory updated_numbers_mem = config.get(10, "number_array").toUint256Array(); - assertEq(updated_numbers_mem.length, 3); - assertEq(updated_numbers_mem[0], 1); - assertEq(updated_numbers_mem[1], 2); - assertEq(updated_numbers_mem[2], 3); - - content = vm.readFile(testConfig); - uint256[] memory updated_numbers_disk = vm.parseTomlUintArray(content, "$.optimism.uint.number_array"); - assertEq(updated_numbers_disk.length, 3); - assertEq(updated_numbers_disk[0], 1); - assertEq(updated_numbers_disk[1], 2); - assertEq(updated_numbers_disk[2], 3); - - // Update a string array and verify the change. - string[] memory new_strings = new string[](2); - new_strings[0] = "hello"; - new_strings[1] = "world"; - config.set(1, "str_array", new_strings); - - string[] memory updated_strings_mem = config.get(1, "str_array").toStringArray(); - assertEq(updated_strings_mem.length, 2); - assertEq(updated_strings_mem[0], "hello"); - assertEq(updated_strings_mem[1], "world"); - - content = vm.readFile(testConfig); - string[] memory updated_strings_disk = vm.parseTomlStringArray(content, "$.mainnet.string.str_array"); - assertEq(updated_strings_disk.length, 2); - assertEq(updated_strings_disk[0], "hello"); - assertEq(updated_strings_disk[1], "world"); - - // Create a new uint variable and verify the change. - config.set(1, "new_uint", uint256(42)); - - assertEq(config.get(1, "new_uint").toUint256(), 42); - - content = vm.readFile(testConfig); - assertEq(vm.parseTomlUint(content, "$.mainnet.uint.new_uint"), 42); - - // Create a new int variable and verify the change. - config.set(1, "new_int", int256(-42)); - - assertEq(config.get(1, "new_int").toInt256(), -42); - - content = vm.readFile(testConfig); - assertEq(vm.parseTomlInt(content, "$.mainnet.int.new_int"), -42); - - // Create a new int array and verify the change. - int256[] memory new_ints = new int256[](2); - new_ints[0] = -100; - new_ints[1] = 200; - config.set(10, "new_ints", new_ints); - - int256[] memory updated_ints_mem = config.get(10, "new_ints").toInt256Array(); - assertEq(updated_ints_mem.length, 2); - assertEq(updated_ints_mem[0], -100); - assertEq(updated_ints_mem[1], 200); - - content = vm.readFile(testConfig); - int256[] memory updated_ints_disk = vm.parseTomlIntArray(content, "$.optimism.int.new_ints"); - assertEq(updated_ints_disk.length, 2); - assertEq(updated_ints_disk[0], -100); - assertEq(updated_ints_disk[1], 200); - - // Create a new bytes32 array and verify the change. - bytes32[] memory new_words = new bytes32[](2); - new_words[0] = bytes32(uint256(0xDEAD)); - new_words[1] = bytes32(uint256(0xBEEF)); - config.set(10, "new_words", new_words); - - bytes32[] memory updated_words_mem = config.get(10, "new_words").toBytes32Array(); - assertEq(updated_words_mem.length, 2); - assertEq(updated_words_mem[0], new_words[0]); - assertEq(updated_words_mem[1], new_words[1]); - - content = vm.readFile(testConfig); - bytes32[] memory updated_words_disk = vm.parseTomlBytes32Array(content, "$.optimism.bytes32.new_words"); - assertEq(updated_words_disk.length, 2); - assertEq(vm.toString(updated_words_disk[0]), vm.toString(new_words[0])); - assertEq(vm.toString(updated_words_disk[1]), vm.toString(new_words[1])); - } - - // Clean up the temporary file. - vm.removeFile(testConfig); - } - - function test_writeUpdatesBackToFile() public { - // Create a temporary copy of the config file to avoid modifying the original. - string memory originalConfig = "./test/fixtures/config.toml"; - string memory testConfig = "./test/fixtures/write_config.t.toml"; - vm.copyFile(originalConfig, testConfig); - - // Deploy the config contract with `writeToFile = false` (disabled). - _loadConfig(testConfig, false); - - // Update a single boolean value and verify the file is NOT changed. - config.set(1, "is_live", false); - string memory content = vm.readFile(testConfig); - assertTrue(vm.parseTomlBool(content, "$.mainnet.bool.is_live"), "File should not be updated yet"); - - // Enable writing to file bypassing the context check. - vm.store(address(config), bytes32(uint256(5)), bytes32(uint256(1))); - - // Update the value again and verify the file IS changed. - config.set(1, "is_live", false); - content = vm.readFile(testConfig); - assertFalse(vm.parseTomlBool(content, "$.mainnet.bool.is_live"), "File should be updated now"); - - // Disable writing to file. - config.writeUpdatesBackToFile(false); - - // Update the value again and verify the file is NOT changed. - config.set(1, "is_live", true); - content = vm.readFile(testConfig); - assertFalse(vm.parseTomlBool(content, "$.mainnet.bool.is_live"), "File should not be updated again"); - - // Clean up the temporary file. - vm.removeFile(testConfig); - } - - function testRevert_WriteToFileInForbiddenCtxt() public { - // Cannot initialize enabling writing to file unless we are in SCRIPT mode. - vm.expectRevert(StdConfig.WriteToFileInForbiddenCtxt.selector); - _loadConfig("./test/fixtures/config.toml", true); - - // Initialize with `writeToFile = false`. - _loadConfig("./test/fixtures/config.toml", false); - - // Cannot enable writing to file unless we are in SCRIPT mode. - vm.expectRevert(StdConfig.WriteToFileInForbiddenCtxt.selector); - config.writeUpdatesBackToFile(true); - } - - function testRevert_InvalidChainKey() public { - // Create a fixture with an invalid chain key - string memory invalidChainConfig = "./test/fixtures/config_invalid_chain.toml"; - vm.writeFile( - invalidChainConfig, - string.concat( - "[mainnet]\n", - "endpoint_url = \"https://eth.llamarpc.com\"\n", - "\n", - "[mainnet.uint]\n", - "valid_number = 123\n", - "\n", - "# Invalid chain key (not a number and not a valid alias)\n", - "[invalid_chain]\n", - "endpoint_url = \"https://invalid.com\"\n", - "\n", - "[invalid_chain_9999.uint]\n", - "some_value = 456\n" - ) - ); - - vm.expectRevert(abi.encodeWithSelector(StdConfig.InvalidChainKey.selector, "invalid_chain")); - new StdConfig(invalidChainConfig, false); - vm.removeFile(invalidChainConfig); - } - - function testRevert_ChainNotInitialized() public { - _loadConfig("./test/fixtures/config.toml", false); - - // Enable writing to file bypassing the context check. - vm.store(address(config), bytes32(uint256(5)), bytes32(uint256(1))); - - // Try to write a value for a non-existent chain ID - vm.expectRevert(abi.encodeWithSelector(StdConfig.ChainNotInitialized.selector, uint256(999999))); - config.set(999999, "some_key", uint256(123)); - } - - function testRevert_UnableToParseVariable() public { - // Create a temporary fixture with an unparsable variable - string memory badParseConfig = "./test/fixtures/config_bad_parse.toml"; - vm.writeFile( - badParseConfig, - string.concat( - "[mainnet]\n", - "endpoint_url = \"https://eth.llamarpc.com\"\n", - "\n", - "[mainnet.uint]\n", - "bad_value = \"not_a_number\"\n" - ) - ); - - vm.expectRevert(abi.encodeWithSelector(StdConfig.UnableToParseVariable.selector, "bad_value")); - new StdConfig(badParseConfig, false); - vm.removeFile(badParseConfig); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/LibVariable.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/LibVariable.t.sol deleted file mode 100644 index 2fc00a91ab..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/LibVariable.t.sol +++ /dev/null @@ -1,434 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.13; - -import {Test} from "../src/Test.sol"; -import {Variable, Type, TypeKind, LibVariable} from "../src/LibVariable.sol"; - -contract LibVariableTest is Test { - using LibVariable for Type; - using LibVariable for TypeKind; - - LibVariableHelper internal helper; - - bytes internal expectedErr; - Variable internal uninitVar; - Variable internal boolVar; - Variable internal addressVar; - Variable internal bytes32Var; - Variable internal uintVar; - Variable internal intVar; - Variable internal stringVar; - Variable internal bytesVar; - Variable internal boolArrayVar; - Variable internal addressArrayVar; - Variable internal bytes32ArrayVar; - Variable internal uintArrayVar; - Variable internal intArrayVar; - Variable internal stringArrayVar; - Variable internal bytesArrayVar; - - function setUp() public { - helper = new LibVariableHelper(); - - // UNINITIALIZED - uninitVar = Variable(Type(TypeKind.None, false), ""); - - // SINGLE VALUES - boolVar = Variable(Type(TypeKind.Bool, false), abi.encode(true)); - addressVar = Variable(Type(TypeKind.Address, false), abi.encode(address(0xdeadbeef))); - bytes32Var = Variable(Type(TypeKind.Bytes32, false), abi.encode(bytes32(uint256(42)))); - uintVar = Variable(Type(TypeKind.Uint256, false), abi.encode(uint256(123))); - intVar = Variable(Type(TypeKind.Int256, false), abi.encode(int256(-123))); - stringVar = Variable(Type(TypeKind.String, false), abi.encode("hello world")); - bytesVar = Variable(Type(TypeKind.Bytes, false), abi.encode(hex"c0ffee")); - - // ARRAY VALUES - bool[] memory bools = new bool[](2); - bools[0] = true; - bools[1] = false; - boolArrayVar = Variable(Type(TypeKind.Bool, true), abi.encode(bools)); - - address[] memory addrs = new address[](2); - addrs[0] = address(0x1); - addrs[1] = address(0x2); - addressArrayVar = Variable(Type(TypeKind.Address, true), abi.encode(addrs)); - - bytes32[] memory b32s = new bytes32[](2); - b32s[0] = bytes32(uint256(1)); - b32s[1] = bytes32(uint256(2)); - bytes32ArrayVar = Variable(Type(TypeKind.Bytes32, true), abi.encode(b32s)); - - uint256[] memory uints = new uint256[](2); - uints[0] = 1; - uints[1] = 2; - uintArrayVar = Variable(Type(TypeKind.Uint256, true), abi.encode(uints)); - - int256[] memory ints = new int256[](2); - ints[0] = -1; - ints[1] = 2; - intArrayVar = Variable(Type(TypeKind.Int256, true), abi.encode(ints)); - - string[] memory strings = new string[](2); - strings[0] = "one"; - strings[1] = "two"; - stringArrayVar = Variable(Type(TypeKind.String, true), abi.encode(strings)); - - bytes[] memory b = new bytes[](2); - b[0] = hex"01"; - b[1] = hex"02"; - bytesArrayVar = Variable(Type(TypeKind.Bytes, true), abi.encode(b)); - } - - // -- SUCCESS CASES -------------------------------------------------------- - - function test_TypeHelpers() public view { - // TypeKind.toString() - assertEq(TypeKind.None.toString(), "none"); - assertEq(TypeKind.Bool.toString(), "bool"); - assertEq(TypeKind.Address.toString(), "address"); - assertEq(TypeKind.Bytes32.toString(), "bytes32"); - assertEq(TypeKind.Uint256.toString(), "uint256"); - assertEq(TypeKind.Int256.toString(), "int256"); - assertEq(TypeKind.String.toString(), "string"); - assertEq(TypeKind.Bytes.toString(), "bytes"); - - // TypeKind.toTomlKey() - assertEq(TypeKind.Uint256.toTomlKey(), "uint"); - assertEq(TypeKind.Int256.toTomlKey(), "int"); - assertEq(TypeKind.Bytes32.toTomlKey(), "bytes32"); - - // Type.toString() - assertEq(boolVar.ty.toString(), "bool"); - assertEq(boolArrayVar.ty.toString(), "bool[]"); - assertEq(uintVar.ty.toString(), "uint256"); - assertEq(uintArrayVar.ty.toString(), "uint256[]"); - assertEq(uninitVar.ty.toString(), "none"); - - // Type.isEqual() - assertTrue(boolVar.ty.isEqual(Type(TypeKind.Bool, false))); - assertFalse(boolVar.ty.isEqual(Type(TypeKind.Bool, true))); - assertFalse(boolVar.ty.isEqual(Type(TypeKind.Address, false))); - - // Type.assertEq() - boolVar.ty.assertEq(Type(TypeKind.Bool, false)); - uintArrayVar.ty.assertEq(Type(TypeKind.Uint256, true)); - } - - function test_Coercion() public view { - // Single values - assertTrue(helper.toBool(boolVar)); - assertEq(helper.toAddress(addressVar), address(0xdeadbeef)); - assertEq(helper.toBytes32(bytes32Var), bytes32(uint256(42))); - assertEq(helper.toUint256(uintVar), 123); - assertEq(helper.toInt256(intVar), -123); - assertEq(helper.toString(stringVar), "hello world"); - assertEq(helper.toBytes(bytesVar), hex"c0ffee"); - - // Bool array - bool[] memory bools = helper.toBoolArray(boolArrayVar); - assertEq(bools.length, 2); - assertTrue(bools[0]); - assertFalse(bools[1]); - - // Address array - address[] memory addrs = helper.toAddressArray(addressArrayVar); - assertEq(addrs.length, 2); - assertEq(addrs[0], address(0x1)); - assertEq(addrs[1], address(0x2)); - - // String array - string[] memory strings = helper.toStringArray(stringArrayVar); - assertEq(strings.length, 2); - assertEq(strings[0], "one"); - assertEq(strings[1], "two"); - } - - function test_Downcasting() public view { - // Uint downcasting - Variable memory v_uint_small = Variable(Type(TypeKind.Uint256, false), abi.encode(uint256(100))); - assertEq(helper.toUint128(v_uint_small), 100); - assertEq(helper.toUint64(v_uint_small), 100); - assertEq(helper.toUint32(v_uint_small), 100); - assertEq(helper.toUint16(v_uint_small), 100); - assertEq(helper.toUint8(v_uint_small), 100); - - // Uint array downcasting - uint256[] memory small_uints = new uint256[](2); - small_uints[0] = 10; - small_uints[1] = 20; - Variable memory v_uint_array_small = Variable(Type(TypeKind.Uint256, true), abi.encode(small_uints)); - uint8[] memory u8_array = helper.toUint8Array(v_uint_array_small); - assertEq(u8_array[0], 10); - assertEq(u8_array[1], 20); - - // Int downcasting - Variable memory v_int_small_pos = Variable(Type(TypeKind.Int256, false), abi.encode(int256(100))); - Variable memory v_int_small_neg = Variable(Type(TypeKind.Int256, false), abi.encode(int256(-100))); - assertEq(helper.toInt128(v_int_small_pos), 100); - assertEq(helper.toInt64(v_int_small_neg), -100); - assertEq(helper.toInt32(v_int_small_pos), 100); - assertEq(helper.toInt16(v_int_small_neg), -100); - assertEq(helper.toInt8(v_int_small_pos), 100); - - // Int array downcasting - int256[] memory small_ints = new int256[](2); - small_ints[0] = -10; - small_ints[1] = 20; - Variable memory intArraySmall = Variable(Type(TypeKind.Int256, true), abi.encode(small_ints)); - int8[] memory i8_array = helper.toInt8Array(intArraySmall); - assertEq(i8_array[0], -10); - assertEq(i8_array[1], 20); - } - - // -- REVERT CASES --------------------------------------------------------- - - function testRevert_NotInitialized() public { - vm.expectRevert(LibVariable.NotInitialized.selector); - helper.toBool(uninitVar); - - vm.expectRevert(LibVariable.NotInitialized.selector); - helper.toAddressArray(uninitVar); - } - - function testRevert_assertExists() public { - vm.expectRevert(LibVariable.NotInitialized.selector); - helper.assertExists(uninitVar); - } - - function testRevert_TypeMismatch() public { - // Single values - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "uint256", "bool")); - helper.toUint256(boolVar); - - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "address", "string")); - helper.toAddress(stringVar); - - // Arrays - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "uint256[]", "bool[]")); - helper.toUint256Array(boolArrayVar); - - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "address[]", "string[]")); - helper.toAddressArray(stringArrayVar); - - // Single value to array - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "bool[]", "bool")); - helper.toBoolArray(boolVar); - - // Array to single value - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "bool", "bool[]")); - helper.toBool(boolArrayVar); - - // assertEq reverts - vm.expectRevert(abi.encodeWithSelector(LibVariable.TypeMismatch.selector, "uint256", "bool")); - helper.assertEq(boolVar.ty, Type(TypeKind.Uint256, false)); - } - - function testRevert_UnsafeCast() public { - // uint overflow - Variable memory uintLarge = Variable(Type(TypeKind.Uint256, false), abi.encode(uint256(type(uint128).max) + 1)); - expectedErr = abi.encodeWithSelector(LibVariable.UnsafeCast.selector, "value does not fit in 'uint128'"); - vm.expectRevert(expectedErr); - helper.toUint128(uintLarge); - - // int overflow - Variable memory intLarge = Variable(Type(TypeKind.Int256, false), abi.encode(int256(type(int128).max) + 1)); - expectedErr = abi.encodeWithSelector(LibVariable.UnsafeCast.selector, "value does not fit in 'int128'"); - - vm.expectRevert(expectedErr); - helper.toInt128(intLarge); - - // int underflow - Variable memory intSmall = Variable(Type(TypeKind.Int256, false), abi.encode(int256(type(int128).min) - 1)); - expectedErr = abi.encodeWithSelector(LibVariable.UnsafeCast.selector, "value does not fit in 'int128'"); - - vm.expectRevert(expectedErr); - helper.toInt128(intSmall); - - // uint array overflow - uint256[] memory uintArray = new uint256[](2); - uintArray[0] = 10; - uintArray[1] = uint256(type(uint64).max) + 1; - Variable memory uintArrayLarge = Variable(Type(TypeKind.Uint256, true), abi.encode(uintArray)); - expectedErr = abi.encodeWithSelector(LibVariable.UnsafeCast.selector, "value in array does not fit in 'uint64'"); - - vm.expectRevert(expectedErr); - helper.toUint64Array(uintArrayLarge); - - // int array overflow - int256[] memory intArray = new int256[](2); - intArray[0] = 10; - intArray[1] = int256(type(int64).max) + 1; - Variable memory intArrayLarge = Variable(Type(TypeKind.Int256, true), abi.encode(intArray)); - expectedErr = abi.encodeWithSelector(LibVariable.UnsafeCast.selector, "value in array does not fit in 'int64'"); - - vm.expectRevert(expectedErr); - helper.toInt64Array(intArrayLarge); - - // int array underflow - intArray[0] = 10; - intArray[1] = int256(type(int64).min) - 1; - Variable memory intArraySmall = Variable(Type(TypeKind.Int256, true), abi.encode(intArray)); - expectedErr = abi.encodeWithSelector(LibVariable.UnsafeCast.selector, "value in array does not fit in 'int64'"); - - vm.expectRevert(expectedErr); - helper.toInt64Array(intArraySmall); - } -} - -/// @dev We must use an external helper contract to ensure proper call depth for `vm.expectRevert`, -/// as direct library calls are inlined by the compiler, causing call depth issues. -contract LibVariableHelper { - using LibVariable for Type; - using LibVariable for TypeKind; - - // Assertions - function assertExists(Variable memory v) external pure { - v.assertExists(); - } - - function assertEq(Type memory t1, Type memory t2) external pure { - t1.assertEq(t2); - } - - // Single Value Coercion - function toBool(Variable memory v) external pure returns (bool) { - return v.toBool(); - } - - function toAddress(Variable memory v) external pure returns (address) { - return v.toAddress(); - } - - function toBytes32(Variable memory v) external pure returns (bytes32) { - return v.toBytes32(); - } - - function toUint256(Variable memory v) external pure returns (uint256) { - return v.toUint256(); - } - - function toInt256(Variable memory v) external pure returns (int256) { - return v.toInt256(); - } - - function toString(Variable memory v) external pure returns (string memory) { - return v.toString(); - } - - function toBytes(Variable memory v) external pure returns (bytes memory) { - return v.toBytes(); - } - - // Array Coercion - function toBoolArray(Variable memory v) external pure returns (bool[] memory) { - return v.toBoolArray(); - } - - function toAddressArray(Variable memory v) external pure returns (address[] memory) { - return v.toAddressArray(); - } - - function toBytes32Array(Variable memory v) external pure returns (bytes32[] memory) { - return v.toBytes32Array(); - } - - function toUint256Array(Variable memory v) external pure returns (uint256[] memory) { - return v.toUint256Array(); - } - - function toInt256Array(Variable memory v) external pure returns (int256[] memory) { - return v.toInt256Array(); - } - - function toStringArray(Variable memory v) external pure returns (string[] memory) { - return v.toStringArray(); - } - - function toBytesArray(Variable memory v) external pure returns (bytes[] memory) { - return v.toBytesArray(); - } - - // Uint Downcasting - function toUint128(Variable memory v) external pure returns (uint128) { - return v.toUint128(); - } - - function toUint64(Variable memory v) external pure returns (uint64) { - return v.toUint64(); - } - - function toUint32(Variable memory v) external pure returns (uint32) { - return v.toUint32(); - } - - function toUint16(Variable memory v) external pure returns (uint16) { - return v.toUint16(); - } - - function toUint8(Variable memory v) external pure returns (uint8) { - return v.toUint8(); - } - - // Int Downcasting - function toInt128(Variable memory v) external pure returns (int128) { - return v.toInt128(); - } - - function toInt64(Variable memory v) external pure returns (int64) { - return v.toInt64(); - } - - function toInt32(Variable memory v) external pure returns (int32) { - return v.toInt32(); - } - - function toInt16(Variable memory v) external pure returns (int16) { - return v.toInt16(); - } - - function toInt8(Variable memory v) external pure returns (int8) { - return v.toInt8(); - } - - // Uint Array Downcasting - function toUint128Array(Variable memory v) external pure returns (uint128[] memory) { - return v.toUint128Array(); - } - - function toUint64Array(Variable memory v) external pure returns (uint64[] memory) { - return v.toUint64Array(); - } - - function toUint32Array(Variable memory v) external pure returns (uint32[] memory) { - return v.toUint32Array(); - } - - function toUint16Array(Variable memory v) external pure returns (uint16[] memory) { - return v.toUint16Array(); - } - - function toUint8Array(Variable memory v) external pure returns (uint8[] memory) { - return v.toUint8Array(); - } - - // Int Array Downcasting - function toInt128Array(Variable memory v) external pure returns (int128[] memory) { - return v.toInt128Array(); - } - - function toInt64Array(Variable memory v) external pure returns (int64[] memory) { - return v.toInt64Array(); - } - - function toInt32Array(Variable memory v) external pure returns (int32[] memory) { - return v.toInt32Array(); - } - - function toInt16Array(Variable memory v) external pure returns (int16[] memory) { - return v.toInt16Array(); - } - - function toInt8Array(Variable memory v) external pure returns (int8[] memory) { - return v.toInt8Array(); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/StdAssertions.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/StdAssertions.t.sol deleted file mode 100644 index acc0c1e812..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/StdAssertions.t.sol +++ /dev/null @@ -1,141 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {StdAssertions} from "../src/StdAssertions.sol"; -import {Vm} from "../src/Vm.sol"; - -interface VmInternal is Vm { - function _expectCheatcodeRevert(bytes memory message) external; -} - -contract StdAssertionsTest is StdAssertions { - string constant errorMessage = "User provided message"; - uint256 constant maxDecimals = 77; - - bool constant SHOULD_REVERT = true; - bool constant SHOULD_RETURN = false; - - bool constant STRICT_REVERT_DATA = true; - bool constant NON_STRICT_REVERT_DATA = false; - - VmInternal constant vm = VmInternal(address(uint160(uint256(keccak256("hevm cheat code"))))); - - function testFuzz_AssertEqCall_Return_Pass( - bytes memory callDataA, - bytes memory callDataB, - bytes memory returnData, - bool strictRevertData - ) external { - address targetA = address(new TestMockCall(returnData, SHOULD_RETURN)); - address targetB = address(new TestMockCall(returnData, SHOULD_RETURN)); - - assertEqCall(targetA, callDataA, targetB, callDataB, strictRevertData); - } - - function testFuzz_RevertWhenCalled_AssertEqCall_Return_Fail( - bytes memory callDataA, - bytes memory callDataB, - bytes memory returnDataA, - bytes memory returnDataB, - bool strictRevertData - ) external { - vm.assume(keccak256(returnDataA) != keccak256(returnDataB)); - - address targetA = address(new TestMockCall(returnDataA, SHOULD_RETURN)); - address targetB = address(new TestMockCall(returnDataB, SHOULD_RETURN)); - - vm._expectCheatcodeRevert( - bytes( - string.concat( - "Call return data does not match: ", vm.toString(returnDataA), " != ", vm.toString(returnDataB) - ) - ) - ); - assertEqCall(targetA, callDataA, targetB, callDataB, strictRevertData); - } - - function testFuzz_AssertEqCall_Revert_Pass( - bytes memory callDataA, - bytes memory callDataB, - bytes memory revertDataA, - bytes memory revertDataB - ) external { - address targetA = address(new TestMockCall(revertDataA, SHOULD_REVERT)); - address targetB = address(new TestMockCall(revertDataB, SHOULD_REVERT)); - - assertEqCall(targetA, callDataA, targetB, callDataB, NON_STRICT_REVERT_DATA); - } - - function testFuzz_RevertWhenCalled_AssertEqCall_Revert_Fail( - bytes memory callDataA, - bytes memory callDataB, - bytes memory revertDataA, - bytes memory revertDataB - ) external { - vm.assume(keccak256(revertDataA) != keccak256(revertDataB)); - - address targetA = address(new TestMockCall(revertDataA, SHOULD_REVERT)); - address targetB = address(new TestMockCall(revertDataB, SHOULD_REVERT)); - - vm._expectCheatcodeRevert( - bytes( - string.concat( - "Call revert data does not match: ", vm.toString(revertDataA), " != ", vm.toString(revertDataB) - ) - ) - ); - assertEqCall(targetA, callDataA, targetB, callDataB, STRICT_REVERT_DATA); - } - - function testFuzz_RevertWhenCalled_AssertEqCall_Fail( - bytes memory callDataA, - bytes memory callDataB, - bytes memory returnDataA, - bytes memory returnDataB, - bool strictRevertData - ) external { - address targetA = address(new TestMockCall(returnDataA, SHOULD_RETURN)); - address targetB = address(new TestMockCall(returnDataB, SHOULD_REVERT)); - - vm.expectRevert(bytes("assertion failed")); - this.assertEqCallExternal(targetA, callDataA, targetB, callDataB, strictRevertData); - - vm.expectRevert(bytes("assertion failed")); - this.assertEqCallExternal(targetB, callDataB, targetA, callDataA, strictRevertData); - } - - // Helper function to test outcome of assertEqCall via `expect` cheatcodes - function assertEqCallExternal( - address targetA, - bytes memory callDataA, - address targetB, - bytes memory callDataB, - bool strictRevertData - ) public { - assertEqCall(targetA, callDataA, targetB, callDataB, strictRevertData); - } -} - -contract TestMockCall { - bytes returnData; - bool shouldRevert; - - constructor(bytes memory returnData_, bool shouldRevert_) { - returnData = returnData_; - shouldRevert = shouldRevert_; - } - - fallback() external payable { - bytes memory returnData_ = returnData; - - if (shouldRevert) { - assembly { - revert(add(returnData_, 0x20), mload(returnData_)) - } - } else { - assembly { - return(add(returnData_, 0x20), mload(returnData_)) - } - } - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/StdChains.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/StdChains.t.sol deleted file mode 100644 index 9522b37d02..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/StdChains.t.sol +++ /dev/null @@ -1,227 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {Test} from "../src/Test.sol"; - -contract StdChainsMock is Test { - function exposed_getChain(string memory chainAlias) public returns (Chain memory) { - return getChain(chainAlias); - } - - function exposed_getChain(uint256 chainId) public returns (Chain memory) { - return getChain(chainId); - } - - function exposed_setChain(string memory chainAlias, ChainData memory chainData) public { - setChain(chainAlias, chainData); - } - - function exposed_setFallbackToDefaultRpcUrls(bool useDefault) public { - setFallbackToDefaultRpcUrls(useDefault); - } -} - -contract StdChainsTest is Test { - function test_ChainRpcInitialization() public { - // RPCs specified in `foundry.toml` should be updated. - assertEq(getChain(1).rpcUrl, "https://eth.merkle.io"); - assertEq(getChain("optimism_sepolia").rpcUrl, "https://sepolia.optimism.io/"); - assertEq(getChain("arbitrum_one_sepolia").rpcUrl, "https://sepolia-rollup.arbitrum.io/rpc/"); - - // Environment variables should be the next fallback - assertEq(getChain("arbitrum_nova").rpcUrl, "https://nova.arbitrum.io/rpc"); - vm.setEnv("ARBITRUM_NOVA_RPC_URL", "myoverride"); - assertEq(getChain("arbitrum_nova").rpcUrl, "myoverride"); - vm.setEnv("ARBITRUM_NOVA_RPC_URL", "https://nova.arbitrum.io/rpc"); - - // Cannot override RPCs defined in `foundry.toml` - vm.setEnv("MAINNET_RPC_URL", "myoverride2"); - assertEq(getChain("mainnet").rpcUrl, "https://eth.merkle.io"); - - // Other RPCs should remain unchanged. - assertEq(getChain(31337).rpcUrl, "http://127.0.0.1:8545"); - assertEq(getChain("sepolia").rpcUrl, "https://sepolia.infura.io/v3/b9794ad1ddf84dfb8c34d6bb5dca2001"); - } - - // Named with a leading underscore to clarify this is not intended to be run as a normal test, - // and is intended to be used in the below `test_Rpcs` test. - function _testRpc(string memory rpcAlias) internal { - string memory rpcUrl = getChain(rpcAlias).rpcUrl; - vm.createSelectFork(rpcUrl); - } - - // Ensure we can connect to the default RPC URL for each chain. - // Currently commented out since this is slow and public RPCs are flaky, often resulting in failing CI. - // function test_Rpcs() public { - // _testRpc("mainnet"); - // _testRpc("sepolia"); - // _testRpc("holesky"); - // _testRpc("optimism"); - // _testRpc("optimism_sepolia"); - // _testRpc("arbitrum_one"); - // _testRpc("arbitrum_one_sepolia"); - // _testRpc("arbitrum_nova"); - // _testRpc("polygon"); - // _testRpc("polygon_amoy"); - // _testRpc("avalanche"); - // _testRpc("avalanche_fuji"); - // _testRpc("bnb_smart_chain"); - // _testRpc("bnb_smart_chain_testnet"); - // _testRpc("gnosis_chain"); - // _testRpc("moonbeam"); - // _testRpc("moonriver"); - // _testRpc("moonbase"); - // _testRpc("base_sepolia"); - // _testRpc("base"); - // _testRpc("blast_sepolia"); - // _testRpc("blast"); - // _testRpc("fantom_opera"); - // _testRpc("fantom_opera_testnet"); - // _testRpc("fraxtal"); - // _testRpc("fraxtal_testnet"); - // _testRpc("berachain_bartio_testnet"); - // _testRpc("flare"); - // _testRpc("flare_coston2"); - // } - - function test_RevertIf_ChainNotFound() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(string): Chain with alias \"does_not_exist\" not found."); - stdChainsMock.exposed_getChain("does_not_exist"); - } - - function test_RevertIf_SetChain_ChainIdExist_FirstTest() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains setChain(string,ChainData): Chain ID 31337 already used by \"anvil\"."); - stdChainsMock.exposed_setChain("anvil2", ChainData("Anvil", 31337, "URL")); - } - - function test_RevertIf_ChainBubbleUp() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - stdChainsMock.exposed_setChain("needs_undefined_env_var", ChainData("", 123456789, "")); - // Forge environment variable error. - vm.expectRevert(); - stdChainsMock.exposed_getChain("needs_undefined_env_var"); - } - - function test_RevertIf_SetChain_ChainIdExists_SecondTest() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - stdChainsMock.exposed_setChain("custom_chain", ChainData("Custom Chain", 123456789, "https://custom.chain/")); - - vm.expectRevert('StdChains setChain(string,ChainData): Chain ID 123456789 already used by "custom_chain".'); - - stdChainsMock.exposed_setChain("another_custom_chain", ChainData("", 123456789, "")); - } - - function test_SetChain() public { - setChain("custom_chain", ChainData("Custom Chain", 123456789, "https://custom.chain/")); - Chain memory customChain = getChain("custom_chain"); - assertEq(customChain.name, "Custom Chain"); - assertEq(customChain.chainId, 123456789); - assertEq(customChain.chainAlias, "custom_chain"); - assertEq(customChain.rpcUrl, "https://custom.chain/"); - Chain memory chainById = getChain(123456789); - assertEq(chainById.name, customChain.name); - assertEq(chainById.chainId, customChain.chainId); - assertEq(chainById.chainAlias, customChain.chainAlias); - assertEq(chainById.rpcUrl, customChain.rpcUrl); - customChain.name = "Another Custom Chain"; - customChain.chainId = 987654321; - setChain("another_custom_chain", customChain); - Chain memory anotherCustomChain = getChain("another_custom_chain"); - assertEq(anotherCustomChain.name, "Another Custom Chain"); - assertEq(anotherCustomChain.chainId, 987654321); - assertEq(anotherCustomChain.chainAlias, "another_custom_chain"); - assertEq(anotherCustomChain.rpcUrl, "https://custom.chain/"); - // Verify the first chain data was not overwritten - chainById = getChain(123456789); - assertEq(chainById.name, "Custom Chain"); - assertEq(chainById.chainId, 123456789); - } - - function test_RevertIf_SetEmptyAlias() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains setChain(string,ChainData): Chain alias cannot be the empty string."); - stdChainsMock.exposed_setChain("", ChainData("", 123456789, "")); - } - - function test_RevertIf_SetNoChainId0() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains setChain(string,ChainData): Chain ID cannot be 0."); - stdChainsMock.exposed_setChain("alias", ChainData("", 0, "")); - } - - function test_RevertIf_GetNoChainId0() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(uint256): Chain ID cannot be 0."); - stdChainsMock.exposed_getChain(0); - } - - function test_RevertIf_GetNoEmptyAlias() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(string): Chain alias cannot be the empty string."); - stdChainsMock.exposed_getChain(""); - } - - function test_RevertIf_ChainNotInitialized() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(string): Chain with alias \"no_such_alias\" not found."); - stdChainsMock.exposed_getChain("no_such_alias"); - } - - function test_RevertIf_ChainAliasNotFound() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(uint256): Chain with ID 321 not found."); - - stdChainsMock.exposed_getChain(321); - } - - function test_SetChain_ExistingOne() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - setChain("custom_chain", ChainData("Custom Chain", 123456789, "https://custom.chain/")); - assertEq(getChain(123456789).chainId, 123456789); - - setChain("custom_chain", ChainData("Modified Chain", 9999999999999999999, "https://modified.chain/")); - vm.expectRevert("StdChains getChain(uint256): Chain with ID 123456789 not found."); - stdChainsMock.exposed_getChain(123456789); - - Chain memory modifiedChain = getChain(9999999999999999999); - assertEq(modifiedChain.name, "Modified Chain"); - assertEq(modifiedChain.chainId, 9999999999999999999); - assertEq(modifiedChain.rpcUrl, "https://modified.chain/"); - } - - function test_RevertIf_DontUseDefaultRpcUrl() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - // Should error if default RPCs flag is set to false. - stdChainsMock.exposed_setFallbackToDefaultRpcUrls(false); - vm.expectRevert(); - stdChainsMock.exposed_getChain(31337); - vm.expectRevert(); - stdChainsMock.exposed_getChain("sepolia"); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/StdCheats.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/StdCheats.t.sol deleted file mode 100644 index 57dbcc2915..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/StdCheats.t.sol +++ /dev/null @@ -1,639 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {StdCheats} from "../src/StdCheats.sol"; -import {Test} from "../src/Test.sol"; -import {stdJson} from "../src/StdJson.sol"; -import {stdToml} from "../src/StdToml.sol"; -import {IERC20} from "../src/interfaces/IERC20.sol"; - -contract StdCheatsTest is Test { - Bar test; - - using stdJson for string; - - function setUp() public { - test = new Bar(); - } - - function test_Skip() public { - vm.warp(100); - skip(25); - assertEq(block.timestamp, 125); - } - - function test_Rewind() public { - vm.warp(100); - rewind(25); - assertEq(block.timestamp, 75); - } - - function test_Hoax() public { - hoax(address(1337)); - test.bar{value: 100}(address(1337)); - } - - function test_HoaxOrigin() public { - hoax(address(1337), address(1337)); - test.origin{value: 100}(address(1337)); - } - - function test_HoaxDifferentAddresses() public { - hoax(address(1337), address(7331)); - test.origin{value: 100}(address(1337), address(7331)); - } - - function test_StartHoax() public { - startHoax(address(1337)); - test.bar{value: 100}(address(1337)); - test.bar{value: 100}(address(1337)); - vm.stopPrank(); - test.bar(address(this)); - } - - function test_StartHoaxOrigin() public { - startHoax(address(1337), address(1337)); - test.origin{value: 100}(address(1337)); - test.origin{value: 100}(address(1337)); - vm.stopPrank(); - test.bar(address(this)); - } - - function test_ChangePrankMsgSender() public { - vm.startPrank(address(1337)); - test.bar(address(1337)); - changePrank(address(0xdead)); - test.bar(address(0xdead)); - changePrank(address(1337)); - test.bar(address(1337)); - vm.stopPrank(); - } - - function test_ChangePrankMsgSenderAndTxOrigin() public { - vm.startPrank(address(1337), address(1338)); - test.origin(address(1337), address(1338)); - changePrank(address(0xdead), address(0xbeef)); - test.origin(address(0xdead), address(0xbeef)); - changePrank(address(1337), address(1338)); - test.origin(address(1337), address(1338)); - vm.stopPrank(); - } - - function test_MakeAccountEquivalence() public { - Account memory account = makeAccount("1337"); - (address addr, uint256 key) = makeAddrAndKey("1337"); - assertEq(account.addr, addr); - assertEq(account.key, key); - } - - function test_MakeAddrEquivalence() public { - (address addr,) = makeAddrAndKey("1337"); - assertEq(makeAddr("1337"), addr); - } - - function test_MakeAddrSigning() public { - (address addr, uint256 key) = makeAddrAndKey("1337"); - bytes32 hash = keccak256("some_message"); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign(key, hash); - assertEq(ecrecover(hash, v, r, s), addr); - } - - function test_Deal() public { - deal(address(this), 1 ether); - assertEq(address(this).balance, 1 ether); - } - - function test_DealToken() public { - Bar barToken = new Bar(); - address bar = address(barToken); - deal(bar, address(this), 10000e18); - assertEq(barToken.balanceOf(address(this)), 10000e18); - } - - function test_DealTokenAdjustTotalSupply() public { - Bar barToken = new Bar(); - address bar = address(barToken); - deal(bar, address(this), 10000e18, true); - assertEq(barToken.balanceOf(address(this)), 10000e18); - assertEq(barToken.totalSupply(), 20000e18); - deal(bar, address(this), 0, true); - assertEq(barToken.balanceOf(address(this)), 0); - assertEq(barToken.totalSupply(), 10000e18); - } - - function test_DealERC1155Token() public { - BarERC1155 barToken = new BarERC1155(); - address bar = address(barToken); - dealERC1155(bar, address(this), 0, 10000e18, false); - assertEq(barToken.balanceOf(address(this), 0), 10000e18); - } - - function test_DealERC1155TokenAdjustTotalSupply() public { - BarERC1155 barToken = new BarERC1155(); - address bar = address(barToken); - dealERC1155(bar, address(this), 0, 10000e18, true); - assertEq(barToken.balanceOf(address(this), 0), 10000e18); - assertEq(barToken.totalSupply(0), 20000e18); - dealERC1155(bar, address(this), 0, 0, true); - assertEq(barToken.balanceOf(address(this), 0), 0); - assertEq(barToken.totalSupply(0), 10000e18); - } - - function test_DealERC721Token() public { - BarERC721 barToken = new BarERC721(); - address bar = address(barToken); - dealERC721(bar, address(2), 1); - assertEq(barToken.balanceOf(address(2)), 1); - assertEq(barToken.balanceOf(address(1)), 0); - dealERC721(bar, address(1), 2); - assertEq(barToken.balanceOf(address(1)), 1); - assertEq(barToken.balanceOf(bar), 1); - } - - function test_DeployCode() public { - address deployed = deployCode("StdCheats.t.sol:Bar", bytes("")); - assertEq(string(getCode(deployed)), string(getCode(address(test)))); - } - - function test_DestroyAccount() public { - // deploy something to destroy it - BarERC721 barToken = new BarERC721(); - address bar = address(barToken); - vm.setNonce(bar, 10); - deal(bar, 100); - - uint256 prevThisBalance = address(this).balance; - uint256 size; - assembly { - size := extcodesize(bar) - } - - assertGt(size, 0); - assertEq(bar.balance, 100); - assertEq(vm.getNonce(bar), 10); - - destroyAccount(bar, address(this)); - assembly { - size := extcodesize(bar) - } - assertEq(address(this).balance, prevThisBalance + 100); - assertEq(vm.getNonce(bar), 0); - assertEq(size, 0); - assertEq(bar.balance, 0); - } - - function test_DeployCodeNoArgs() public { - address deployed = deployCode("StdCheats.t.sol:Bar"); - assertEq(string(getCode(deployed)), string(getCode(address(test)))); - } - - function test_DeployCodeVal() public { - address deployed = deployCode("StdCheats.t.sol:Bar", bytes(""), 1 ether); - assertEq(string(getCode(deployed)), string(getCode(address(test)))); - assertEq(deployed.balance, 1 ether); - } - - function test_DeployCodeValNoArgs() public { - address deployed = deployCode("StdCheats.t.sol:Bar", 1 ether); - assertEq(string(getCode(deployed)), string(getCode(address(test)))); - assertEq(deployed.balance, 1 ether); - } - - // We need this so we can call "this.deployCode" rather than "deployCode" directly - function deployCodeHelper(string memory what) external { - deployCode(what); - } - - function test_RevertIf_DeployCodeFail() public { - vm.expectRevert(bytes("StdCheats deployCode(string): Deployment failed.")); - this.deployCodeHelper("StdCheats.t.sol:RevertingContract"); - } - - function getCode(address who) internal view returns (bytes memory o_code) { - /// @solidity memory-safe-assembly - assembly { - // retrieve the size of the code, this needs assembly - let size := extcodesize(who) - // allocate output byte array - this could also be done without assembly - // by using o_code = new bytes(size) - o_code := mload(0x40) - // new "memory end" including padding - mstore(0x40, add(o_code, and(add(add(size, 0x20), 0x1f), not(0x1f)))) - // store length in memory - mstore(o_code, size) - // actually retrieve the code, this needs assembly - extcodecopy(who, add(o_code, 0x20), 0, size) - } - } - - function test_DeriveRememberKey() public { - string memory mnemonic = "test test test test test test test test test test test junk"; - - (address deployer, uint256 privateKey) = deriveRememberKey(mnemonic, 0); - assertEq(deployer, 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266); - assertEq(privateKey, 0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80); - } - - function test_BytesToUint() public pure { - assertEq(3, bytesToUint_test(hex"03")); - assertEq(2, bytesToUint_test(hex"02")); - assertEq(255, bytesToUint_test(hex"ff")); - assertEq(29625, bytesToUint_test(hex"73b9")); - } - - function test_ParseJsonTxDetail() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - string memory json = vm.readFile(path); - bytes memory transactionDetails = json.parseRaw(".transactions[0].tx"); - RawTx1559Detail memory rawTxDetail = abi.decode(transactionDetails, (RawTx1559Detail)); - Tx1559Detail memory txDetail = rawToConvertedEIP1559Detail(rawTxDetail); - assertEq(txDetail.from, 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266); - assertEq(txDetail.to, 0xe7f1725E7734CE288F8367e1Bb143E90bb3F0512); - assertEq( - txDetail.data, - hex"23e99187000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000013370000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000000004" - ); - assertEq(txDetail.nonce, 3); - assertEq(txDetail.txType, 2); - assertEq(txDetail.gas, 29625); - assertEq(txDetail.value, 0); - } - - function test_ReadEIP1559Transaction() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - uint256 index = 0; - Tx1559 memory transaction = readTx1559(path, index); - transaction; - } - - function test_ReadEIP1559Transactions() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - Tx1559[] memory transactions = readTx1559s(path); - transactions; - } - - function test_ReadReceipt() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - uint256 index = 5; - Receipt memory receipt = readReceipt(path, index); - assertEq( - receipt.logsBloom, - hex"00000000000800000000000000000010000000000000000000000000000180000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100" - ); - } - - function test_ReadReceipts() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - Receipt[] memory receipts = readReceipts(path); - receipts; - } - - function test_GasMeteringModifier() public { - uint256 gas_start_normal = gasleft(); - addInLoop(); - uint256 gas_used_normal = gas_start_normal - gasleft(); - - uint256 gas_start_single = gasleft(); - addInLoopNoGas(); - uint256 gas_used_single = gas_start_single - gasleft(); - - uint256 gas_start_double = gasleft(); - addInLoopNoGasNoGas(); - uint256 gas_used_double = gas_start_double - gasleft(); - - assertTrue(gas_used_double + gas_used_single < gas_used_normal); - } - - function addInLoop() internal pure returns (uint256) { - uint256 b; - for (uint256 i; i < 10000; i++) { - b += i; - } - return b; - } - - function addInLoopNoGas() internal noGasMetering returns (uint256) { - return addInLoop(); - } - - function addInLoopNoGasNoGas() internal noGasMetering returns (uint256) { - return addInLoopNoGas(); - } - - function bytesToUint_test(bytes memory b) private pure returns (uint256) { - uint256 number; - for (uint256 i = 0; i < b.length; i++) { - number = number + uint256(uint8(b[i])) * (2 ** (8 * (b.length - (i + 1)))); - } - return number; - } - - function testFuzz_AssumeAddressIsNot(address addr) external { - // skip over Payable and NonPayable enums - for (uint8 i = 2; i < uint8(type(AddressType).max); i++) { - assumeAddressIsNot(addr, AddressType(i)); - } - assertTrue(addr != address(0)); - assertTrue(addr < address(1) || addr > address(9)); - assertTrue(addr != address(vm) || addr != 0x000000000000000000636F6e736F6c652e6c6f67); - } - - function test_AssumePayable() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - - // all should revert since these addresses are not payable - - // VM address - vm.expectRevert(); - stdCheatsMock.exposed_assumePayable(0x7109709ECfa91a80626fF3989D68f67F5b1DD12D); - - // Console address - vm.expectRevert(); - stdCheatsMock.exposed_assumePayable(0x000000000000000000636F6e736F6c652e6c6f67); - - // Create2Deployer - vm.expectRevert(); - stdCheatsMock.exposed_assumePayable(0x4e59b44847b379578588920cA78FbF26c0B4956C); - - // all should pass since these addresses are payable - - // vitalik.eth - stdCheatsMock.exposed_assumePayable(0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045); - - // mock payable contract - MockContractPayable cp = new MockContractPayable(); - stdCheatsMock.exposed_assumePayable(address(cp)); - } - - function test_AssumeNotPayable() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - - // all should pass since these addresses are not payable - - // VM address - stdCheatsMock.exposed_assumeNotPayable(0x7109709ECfa91a80626fF3989D68f67F5b1DD12D); - - // Console address - stdCheatsMock.exposed_assumeNotPayable(0x000000000000000000636F6e736F6c652e6c6f67); - - // Create2Deployer - stdCheatsMock.exposed_assumeNotPayable(0x4e59b44847b379578588920cA78FbF26c0B4956C); - - // all should revert since these addresses are payable - - // vitalik.eth - vm.expectRevert(); - stdCheatsMock.exposed_assumeNotPayable(0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045); - - // mock payable contract - MockContractPayable cp = new MockContractPayable(); - vm.expectRevert(); - stdCheatsMock.exposed_assumeNotPayable(address(cp)); - } - - function testFuzz_AssumeNotPrecompile(address addr) external { - assumeNotPrecompile(addr, getChain("optimism_sepolia").chainId); - assertTrue( - addr < address(1) || (addr > address(9) && addr < address(0x4200000000000000000000000000000000000000)) - || addr > address(0x4200000000000000000000000000000000000800) - ); - } - - function testFuzz_AssumeNotForgeAddress(address addr) external pure { - assumeNotForgeAddress(addr); - assertTrue( - addr != address(vm) && addr != 0x000000000000000000636F6e736F6c652e6c6f67 - && addr != 0x4e59b44847b379578588920cA78FbF26c0B4956C - ); - } - - function test_RevertIf_CannotDeployCodeTo() external { - vm.expectRevert("StdCheats deployCodeTo(string,bytes,uint256,address): Failed to create runtime bytecode."); - this._revertDeployCodeTo(); - } - - function _revertDeployCodeTo() external { - deployCodeTo("StdCheats.t.sol:RevertingContract", address(0)); - } - - function test_DeployCodeTo() external { - address arbitraryAddress = makeAddr("arbitraryAddress"); - - deployCodeTo( - "StdCheats.t.sol:MockContractWithConstructorArgs", - abi.encode(uint256(6), true, bytes20(arbitraryAddress)), - 1 ether, - arbitraryAddress - ); - - MockContractWithConstructorArgs ct = MockContractWithConstructorArgs(arbitraryAddress); - - assertEq(arbitraryAddress.balance, 1 ether); - assertEq(ct.x(), 6); - assertTrue(ct.y()); - assertEq(ct.z(), bytes20(arbitraryAddress)); - } -} - -contract StdCheatsMock is StdCheats { - function exposed_assumePayable(address addr) external { - assumePayable(addr); - } - - function exposed_assumeNotPayable(address addr) external { - assumeNotPayable(addr); - } - - // We deploy a mock version so we can properly test expected reverts. - function exposed_assumeNotBlacklisted(address token, address addr) external view { - return assumeNotBlacklisted(token, addr); - } -} - -contract StdCheatsForkTest is Test { - address internal constant USDC_BLACKLISTED_USER = 0x1E34A77868E19A6647b1f2F47B51ed72dEDE95DD; - address internal constant USDT_BLACKLISTED_USER = 0x8f8a8F4B54a2aAC7799d7bc81368aC27b852822A; - - MockUSDT public USDT; - MockUSDC public USDC; - - function setUp() public { - USDT = new MockUSDT(); - USDC = new MockUSDC(); - - USDC.setBlacklisted(USDC_BLACKLISTED_USER, true); - USDT.setBlacklisted(USDT_BLACKLISTED_USER, true); - } - - function test_RevertIf_CannotAssumeNoBlacklisted_EOA() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - address eoa = vm.addr({privateKey: 1}); - vm.expectRevert("StdCheats assumeNotBlacklisted(address,address): Token address is not a contract."); - stdCheatsMock.exposed_assumeNotBlacklisted(eoa, address(0)); - } - - function testFuzz_AssumeNotBlacklisted_TokenWithoutBlacklist(address addr) external view { - assumeNotBlacklisted(address(USDC), addr); - assumeNotBlacklisted(address(USDT), addr); - assertTrue(true); - } - - function test_RevertIf_AssumeNoBlacklisted_USDC() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - vm.expectRevert(); - stdCheatsMock.exposed_assumeNotBlacklisted(address(USDC), USDC_BLACKLISTED_USER); - } - - function testFuzz_AssumeNotBlacklisted_USDC(address addr) external view { - assumeNotBlacklisted(address(USDC), addr); - assertFalse(USDCLike(USDC).isBlacklisted(addr)); - } - - function test_RevertIf_AssumeNoBlacklisted_USDT() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - vm.expectRevert(); - stdCheatsMock.exposed_assumeNotBlacklisted(address(USDT), USDT_BLACKLISTED_USER); - } - - function testFuzz_AssumeNotBlacklisted_USDT(address addr) external view { - assumeNotBlacklisted(address(USDT), addr); - assertFalse(USDTLike(USDT).isBlackListed(addr)); - } -} - -/// @dev https://etherscan.io/token/0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48#readProxyContract -interface USDCLike { - function isBlacklisted(address) external view returns (bool); -} - -/// @dev https://etherscan.io/token/0xdac17f958d2ee523a2206206994597c13d831ec7#readContract -interface USDTLike { - function isBlackListed(address) external view returns (bool); -} - -contract MockUSDT is USDTLike { - mapping(address => bool) private blacklist; - - function isBlackListed(address addr) external view returns (bool) { - return blacklist[addr]; - } - - function setBlacklisted(address addr, bool value) external { - blacklist[addr] = value; - } -} - -contract MockUSDC is USDCLike { - mapping(address => bool) private blacklist; - - function isBlacklisted(address addr) external view returns (bool) { - return blacklist[addr]; - } - - function setBlacklisted(address addr, bool value) external { - blacklist[addr] = value; - } -} - -contract Bar { - constructor() payable { - /// `DEAL` STDCHEAT - totalSupply = 10000e18; - balanceOf[address(this)] = totalSupply; - } - - /// `HOAX` and `CHANGEPRANK` STDCHEATS - function bar(address expectedSender) public payable { - require(msg.sender == expectedSender, "!prank"); - } - - function origin(address expectedSender) public payable { - require(msg.sender == expectedSender, "!prank"); - require(tx.origin == expectedSender, "!prank"); - } - - function origin(address expectedSender, address expectedOrigin) public payable { - require(msg.sender == expectedSender, "!prank"); - require(tx.origin == expectedOrigin, "!prank"); - } - - /// `DEAL` STDCHEAT - mapping(address => uint256) public balanceOf; - uint256 public totalSupply; -} - -contract BarERC1155 { - constructor() payable { - /// `DEALERC1155` STDCHEAT - _totalSupply[0] = 10000e18; - _balances[0][address(this)] = _totalSupply[0]; - } - - function balanceOf(address account, uint256 id) public view virtual returns (uint256) { - return _balances[id][account]; - } - - function totalSupply(uint256 id) public view virtual returns (uint256) { - return _totalSupply[id]; - } - - /// `DEALERC1155` STDCHEAT - mapping(uint256 => mapping(address => uint256)) private _balances; - mapping(uint256 => uint256) private _totalSupply; -} - -contract BarERC721 { - constructor() payable { - /// `DEALERC721` STDCHEAT - _owners[1] = address(1); - _balances[address(1)] = 1; - _owners[2] = address(this); - _owners[3] = address(this); - _balances[address(this)] = 2; - } - - function balanceOf(address owner) public view virtual returns (uint256) { - return _balances[owner]; - } - - function ownerOf(uint256 tokenId) public view virtual returns (address) { - address owner = _owners[tokenId]; - return owner; - } - - mapping(uint256 => address) private _owners; - mapping(address => uint256) private _balances; -} - -contract RevertingContract { - constructor() { - revert(); - } -} - -contract MockContractWithConstructorArgs { - uint256 public immutable x; - bool public y; - bytes20 public z; - - constructor(uint256 _x, bool _y, bytes20 _z) payable { - x = _x; - y = _y; - z = _z; - } -} - -contract MockContractPayable { - receive() external payable {} -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/StdConstants.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/StdConstants.t.sol deleted file mode 100644 index 7a00530f48..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/StdConstants.t.sol +++ /dev/null @@ -1,38 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {StdConstants} from "../src/StdConstants.sol"; -import {Test} from "../src/Test.sol"; - -contract StdConstantsTest is Test { - function testVm() public view { - assertEq(StdConstants.VM.getBlockNumber(), 1); - } - - function testVmDerivation() public pure { - assertEq(address(StdConstants.VM), address(uint160(uint256(keccak256("hevm cheat code"))))); - } - - function testConsoleDerivation() public pure { - assertEq(StdConstants.CONSOLE, address(uint160(uint88(bytes11("console.log"))))); - } - - function testDefaultSender() public view { - assertEq(StdConstants.DEFAULT_SENDER, msg.sender); - } - - function testDefaultSenderDerivation() public pure { - assertEq(StdConstants.DEFAULT_SENDER, address(uint160(uint256(keccak256("foundry default caller"))))); - } - - function testDefaultTestContract() public { - assertEq(StdConstants.DEFAULT_TEST_CONTRACT, address(new Dummy())); - } - - function testDefaultTestContractDerivation() public view { - assertEq(address(this), StdConstants.VM.computeCreateAddress(StdConstants.DEFAULT_SENDER, 1)); - assertEq(StdConstants.DEFAULT_TEST_CONTRACT, StdConstants.VM.computeCreateAddress(address(this), 1)); - } -} - -contract Dummy {} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/StdError.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/StdError.t.sol deleted file mode 100644 index 29803d5d52..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/StdError.t.sol +++ /dev/null @@ -1,120 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.8.0 <0.9.0; - -import {stdError} from "../src/StdError.sol"; -import {Test} from "../src/Test.sol"; - -contract StdErrorsTest is Test { - ErrorsTest test; - - function setUp() public { - test = new ErrorsTest(); - } - - function test_RevertIf_AssertionError() public { - vm.expectRevert(stdError.assertionError); - test.assertionError(); - } - - function test_RevertIf_ArithmeticError() public { - vm.expectRevert(stdError.arithmeticError); - test.arithmeticError(10); - } - - function test_RevertIf_DivisionError() public { - vm.expectRevert(stdError.divisionError); - test.divError(0); - } - - function test_RevertIf_ModError() public { - vm.expectRevert(stdError.divisionError); - test.modError(0); - } - - function test_RevertIf_EnumConversionError() public { - vm.expectRevert(stdError.enumConversionError); - test.enumConversion(1); - } - - function test_RevertIf_EncodeStgError() public { - vm.expectRevert(stdError.encodeStorageError); - test.encodeStgError(); - } - - function test_RevertIf_PopError() public { - vm.expectRevert(stdError.popError); - test.pop(); - } - - function test_RevertIf_IndexOOBError() public { - vm.expectRevert(stdError.indexOOBError); - test.indexOOBError(1); - } - - function test_RevertIf_MemOverflowError() public { - vm.expectRevert(stdError.memOverflowError); - test.mem(); - } - - function test_RevertIf_InternError() public { - vm.expectRevert(stdError.zeroVarError); - test.intern(); - } -} - -contract ErrorsTest { - enum T { - T1 - } - - uint256[] public someArr; - bytes someBytes; - - function assertionError() public pure { - assert(false); - } - - function arithmeticError(uint256 a) public pure { - a -= 100; - } - - function divError(uint256 a) public pure { - 100 / a; - } - - function modError(uint256 a) public pure { - 100 % a; - } - - function enumConversion(uint256 a) public pure { - T(a); - } - - function encodeStgError() public { - /// @solidity memory-safe-assembly - assembly { - sstore(someBytes.slot, 1) - } - keccak256(someBytes); - } - - function pop() public { - someArr.pop(); - } - - function indexOOBError(uint256 a) public pure { - uint256[] memory t = new uint256[](0); - t[a]; - } - - function mem() public pure { - uint256 l = 2 ** 256 / 32; - new uint256[](l); - } - - function intern() public returns (uint256) { - function(uint256) internal returns (uint256) x; - x(2); - return 7; - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/StdJson.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/StdJson.t.sol deleted file mode 100644 index 6bedfcc9a8..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/StdJson.t.sol +++ /dev/null @@ -1,49 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {Test, stdJson} from "../src/Test.sol"; - -contract StdJsonTest is Test { - using stdJson for string; - - string root; - string path; - - function setUp() public { - root = vm.projectRoot(); - path = string.concat(root, "/test/fixtures/test.json"); - } - - struct SimpleJson { - uint256 a; - string b; - } - - struct NestedJson { - uint256 a; - string b; - SimpleJson c; - } - - function test_readJson() public view { - string memory json = vm.readFile(path); - assertEq(json.readUint(".a"), 123); - } - - function test_writeJson() public { - string memory json = "json"; - json.serialize("a", uint256(123)); - string memory semiFinal = json.serialize("b", string("test")); - string memory finalJson = json.serialize("c", semiFinal); - finalJson.write(path); - - string memory json_ = vm.readFile(path); - bytes memory data = json_.parseRaw("$"); - NestedJson memory decodedData = abi.decode(data, (NestedJson)); - - assertEq(decodedData.a, 123); - assertEq(decodedData.b, "test"); - assertEq(decodedData.c.a, 123); - assertEq(decodedData.c.b, "test"); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/StdMath.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/StdMath.t.sol deleted file mode 100644 index d1269a02ac..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/StdMath.t.sol +++ /dev/null @@ -1,202 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.8.0 <0.9.0; - -import {stdMath} from "../src/StdMath.sol"; -import {Test, stdError} from "../src/Test.sol"; - -contract StdMathMock is Test { - function exposed_percentDelta(uint256 a, uint256 b) public pure returns (uint256) { - return stdMath.percentDelta(a, b); - } - - function exposed_percentDelta(int256 a, int256 b) public pure returns (uint256) { - return stdMath.percentDelta(a, b); - } -} - -contract StdMathTest is Test { - function test_GetAbs() external pure { - assertEq(stdMath.abs(-50), 50); - assertEq(stdMath.abs(50), 50); - assertEq(stdMath.abs(-1337), 1337); - assertEq(stdMath.abs(0), 0); - - assertEq(stdMath.abs(type(int256).min), (type(uint256).max >> 1) + 1); - assertEq(stdMath.abs(type(int256).max), (type(uint256).max >> 1)); - } - - function testFuzz_GetAbs(int256 a) external pure { - uint256 manualAbs = getAbs(a); - - uint256 abs = stdMath.abs(a); - - assertEq(abs, manualAbs); - } - - function test_GetDelta_Uint() external pure { - assertEq(stdMath.delta(uint256(0), uint256(0)), 0); - assertEq(stdMath.delta(uint256(0), uint256(1337)), 1337); - assertEq(stdMath.delta(uint256(0), type(uint64).max), type(uint64).max); - assertEq(stdMath.delta(uint256(0), type(uint128).max), type(uint128).max); - assertEq(stdMath.delta(uint256(0), type(uint256).max), type(uint256).max); - - assertEq(stdMath.delta(0, uint256(0)), 0); - assertEq(stdMath.delta(1337, uint256(0)), 1337); - assertEq(stdMath.delta(type(uint64).max, uint256(0)), type(uint64).max); - assertEq(stdMath.delta(type(uint128).max, uint256(0)), type(uint128).max); - assertEq(stdMath.delta(type(uint256).max, uint256(0)), type(uint256).max); - - assertEq(stdMath.delta(1337, uint256(1337)), 0); - assertEq(stdMath.delta(type(uint256).max, type(uint256).max), 0); - assertEq(stdMath.delta(5000, uint256(1250)), 3750); - } - - function testFuzz_GetDelta_Uint(uint256 a, uint256 b) external pure { - uint256 manualDelta = a > b ? a - b : b - a; - - uint256 delta = stdMath.delta(a, b); - - assertEq(delta, manualDelta); - } - - function test_GetDelta_Int() external pure { - assertEq(stdMath.delta(int256(0), int256(0)), 0); - assertEq(stdMath.delta(int256(0), int256(1337)), 1337); - assertEq(stdMath.delta(int256(0), type(int64).max), type(uint64).max >> 1); - assertEq(stdMath.delta(int256(0), type(int128).max), type(uint128).max >> 1); - assertEq(stdMath.delta(int256(0), type(int256).max), type(uint256).max >> 1); - - assertEq(stdMath.delta(0, int256(0)), 0); - assertEq(stdMath.delta(1337, int256(0)), 1337); - assertEq(stdMath.delta(type(int64).max, int256(0)), type(uint64).max >> 1); - assertEq(stdMath.delta(type(int128).max, int256(0)), type(uint128).max >> 1); - assertEq(stdMath.delta(type(int256).max, int256(0)), type(uint256).max >> 1); - - assertEq(stdMath.delta(-0, int256(0)), 0); - assertEq(stdMath.delta(-1337, int256(0)), 1337); - assertEq(stdMath.delta(type(int64).min, int256(0)), (type(uint64).max >> 1) + 1); - assertEq(stdMath.delta(type(int128).min, int256(0)), (type(uint128).max >> 1) + 1); - assertEq(stdMath.delta(type(int256).min, int256(0)), (type(uint256).max >> 1) + 1); - - assertEq(stdMath.delta(int256(0), -0), 0); - assertEq(stdMath.delta(int256(0), -1337), 1337); - assertEq(stdMath.delta(int256(0), type(int64).min), (type(uint64).max >> 1) + 1); - assertEq(stdMath.delta(int256(0), type(int128).min), (type(uint128).max >> 1) + 1); - assertEq(stdMath.delta(int256(0), type(int256).min), (type(uint256).max >> 1) + 1); - - assertEq(stdMath.delta(1337, int256(1337)), 0); - assertEq(stdMath.delta(type(int256).max, type(int256).max), 0); - assertEq(stdMath.delta(type(int256).min, type(int256).min), 0); - assertEq(stdMath.delta(type(int256).min, type(int256).max), type(uint256).max); - assertEq(stdMath.delta(5000, int256(1250)), 3750); - } - - function testFuzz_GetDelta_Int(int256 a, int256 b) external pure { - uint256 absA = getAbs(a); - uint256 absB = getAbs(b); - uint256 absDelta = absA > absB ? absA - absB : absB - absA; - - uint256 manualDelta; - if ((a >= 0 && b >= 0) || (a < 0 && b < 0)) { - manualDelta = absDelta; - } - // (a < 0 && b >= 0) || (a >= 0 && b < 0) - else { - manualDelta = absA + absB; - } - - uint256 delta = stdMath.delta(a, b); - - assertEq(delta, manualDelta); - } - - function test_GetPercentDelta_Uint() external { - StdMathMock stdMathMock = new StdMathMock(); - - assertEq(stdMath.percentDelta(uint256(0), uint256(1337)), 1e18); - assertEq(stdMath.percentDelta(uint256(0), type(uint64).max), 1e18); - assertEq(stdMath.percentDelta(uint256(0), type(uint128).max), 1e18); - assertEq(stdMath.percentDelta(uint256(0), type(uint192).max), 1e18); - - assertEq(stdMath.percentDelta(1337, uint256(1337)), 0); - assertEq(stdMath.percentDelta(type(uint192).max, type(uint192).max), 0); - assertEq(stdMath.percentDelta(0, uint256(2500)), 1e18); - assertEq(stdMath.percentDelta(2500, uint256(2500)), 0); - assertEq(stdMath.percentDelta(5000, uint256(2500)), 1e18); - assertEq(stdMath.percentDelta(7500, uint256(2500)), 2e18); - - vm.expectRevert(stdError.divisionError); - stdMathMock.exposed_percentDelta(uint256(1), 0); - } - - function testFuzz_GetPercentDelta_Uint(uint192 a, uint192 b) external pure { - vm.assume(b != 0); - uint256 manualDelta = a > b ? a - b : b - a; - - uint256 manualPercentDelta = manualDelta * 1e18 / b; - uint256 percentDelta = stdMath.percentDelta(a, b); - - assertEq(percentDelta, manualPercentDelta); - } - - function test_GetPercentDelta_Int() external { - // We deploy a mock version so we can properly test the revert. - StdMathMock stdMathMock = new StdMathMock(); - - assertEq(stdMath.percentDelta(int256(0), int256(1337)), 1e18); - assertEq(stdMath.percentDelta(int256(0), -1337), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int64).min), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int128).min), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int192).min), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int64).max), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int128).max), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int192).max), 1e18); - - assertEq(stdMath.percentDelta(1337, int256(1337)), 0); - assertEq(stdMath.percentDelta(type(int192).max, type(int192).max), 0); - assertEq(stdMath.percentDelta(type(int192).min, type(int192).min), 0); - - assertEq(stdMath.percentDelta(type(int192).min, type(int192).max), 2e18); // rounds the 1 wei diff down - assertEq(stdMath.percentDelta(type(int192).max, type(int192).min), 2e18 - 1); // rounds the 1 wei diff down - assertEq(stdMath.percentDelta(0, int256(2500)), 1e18); - assertEq(stdMath.percentDelta(2500, int256(2500)), 0); - assertEq(stdMath.percentDelta(5000, int256(2500)), 1e18); - assertEq(stdMath.percentDelta(7500, int256(2500)), 2e18); - - vm.expectRevert(stdError.divisionError); - stdMathMock.exposed_percentDelta(int256(1), 0); - } - - function testFuzz_GetPercentDelta_Int(int192 a, int192 b) external pure { - vm.assume(b != 0); - uint256 absA = getAbs(a); - uint256 absB = getAbs(b); - uint256 absDelta = absA > absB ? absA - absB : absB - absA; - - uint256 manualDelta; - if ((a >= 0 && b >= 0) || (a < 0 && b < 0)) { - manualDelta = absDelta; - } - // (a < 0 && b >= 0) || (a >= 0 && b < 0) - else { - manualDelta = absA + absB; - } - - uint256 manualPercentDelta = manualDelta * 1e18 / absB; - uint256 percentDelta = stdMath.percentDelta(a, b); - - assertEq(percentDelta, manualPercentDelta); - } - - /*////////////////////////////////////////////////////////////////////////// - HELPERS - //////////////////////////////////////////////////////////////////////////*/ - - function getAbs(int256 a) private pure returns (uint256) { - if (a < 0) { - return a == type(int256).min ? uint256(type(int256).max) + 1 : uint256(-a); - } - - return uint256(a); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/StdStorage.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/StdStorage.t.sol deleted file mode 100644 index 46604f8668..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/StdStorage.t.sol +++ /dev/null @@ -1,488 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {stdStorage, StdStorage} from "../src/StdStorage.sol"; -import {Test} from "../src/Test.sol"; - -contract StdStorageTest is Test { - using stdStorage for StdStorage; - - StorageTest internal test; - - function setUp() public { - test = new StorageTest(); - } - - function test_StorageHidden() public { - assertEq(uint256(keccak256("my.random.var")), stdstore.target(address(test)).sig("hidden()").find()); - } - - function test_StorageObvious() public { - assertEq(uint256(0), stdstore.target(address(test)).sig("exists()").find()); - } - - function test_StorageExtraSload() public { - assertEq(16, stdstore.target(address(test)).sig(test.extra_sload.selector).find()); - } - - function test_StorageCheckedWriteHidden() public { - stdstore.target(address(test)).sig(test.hidden.selector).checked_write(100); - assertEq(uint256(test.hidden()), 100); - } - - function test_StorageCheckedWriteObvious() public { - stdstore.target(address(test)).sig(test.exists.selector).checked_write(100); - assertEq(test.exists(), 100); - } - - function test_StorageCheckedWriteSignedIntegerHidden() public { - stdstore.target(address(test)).sig(test.hidden.selector).checked_write_int(-100); - assertEq(int256(uint256(test.hidden())), -100); - } - - function test_StorageCheckedWriteSignedIntegerObvious() public { - stdstore.target(address(test)).sig(test.tG.selector).checked_write_int(-100); - assertEq(test.tG(), -100); - } - - function test_StorageMapStructA() public { - uint256 slot = - stdstore.target(address(test)).sig(test.map_struct.selector).with_key(address(this)).depth(0).find(); - assertEq(uint256(keccak256(abi.encode(address(this), 4))), slot); - } - - function test_StorageMapStructB() public { - uint256 slot = - stdstore.target(address(test)).sig(test.map_struct.selector).with_key(address(this)).depth(1).find(); - assertEq(uint256(keccak256(abi.encode(address(this), 4))) + 1, slot); - } - - function test_StorageDeepMap() public { - uint256 slot = stdstore.target(address(test)).sig(test.deep_map.selector).with_key(address(this)).with_key( - address(this) - ).find(); - assertEq(uint256(keccak256(abi.encode(address(this), keccak256(abi.encode(address(this), uint256(5)))))), slot); - } - - function test_StorageCheckedWriteDeepMap() public { - stdstore.target(address(test)).sig(test.deep_map.selector).with_key(address(this)).with_key(address(this)) - .checked_write(100); - assertEq(100, test.deep_map(address(this), address(this))); - } - - function test_StorageDeepMapStructA() public { - uint256 slot = stdstore.target(address(test)).sig(test.deep_map_struct.selector).with_key(address(this)) - .with_key(address(this)).depth(0).find(); - assertEq( - bytes32(uint256(keccak256(abi.encode(address(this), keccak256(abi.encode(address(this), uint256(6)))))) + 0), - bytes32(slot) - ); - } - - function test_StorageDeepMapStructB() public { - uint256 slot = stdstore.target(address(test)).sig(test.deep_map_struct.selector).with_key(address(this)) - .with_key(address(this)).depth(1).find(); - assertEq( - bytes32(uint256(keccak256(abi.encode(address(this), keccak256(abi.encode(address(this), uint256(6)))))) + 1), - bytes32(slot) - ); - } - - function test_StorageCheckedWriteDeepMapStructA() public { - stdstore.target(address(test)).sig(test.deep_map_struct.selector).with_key(address(this)).with_key( - address(this) - ).depth(0).checked_write(100); - (uint256 a, uint256 b) = test.deep_map_struct(address(this), address(this)); - assertEq(100, a); - assertEq(0, b); - } - - function test_StorageCheckedWriteDeepMapStructB() public { - stdstore.target(address(test)).sig(test.deep_map_struct.selector).with_key(address(this)).with_key( - address(this) - ).depth(1).checked_write(100); - (uint256 a, uint256 b) = test.deep_map_struct(address(this), address(this)); - assertEq(0, a); - assertEq(100, b); - } - - function test_StorageCheckedWriteMapStructA() public { - stdstore.target(address(test)).sig(test.map_struct.selector).with_key(address(this)).depth(0).checked_write(100); - (uint256 a, uint256 b) = test.map_struct(address(this)); - assertEq(a, 100); - assertEq(b, 0); - } - - function test_StorageCheckedWriteMapStructB() public { - stdstore.target(address(test)).sig(test.map_struct.selector).with_key(address(this)).depth(1).checked_write(100); - (uint256 a, uint256 b) = test.map_struct(address(this)); - assertEq(a, 0); - assertEq(b, 100); - } - - function test_StorageStructA() public { - uint256 slot = stdstore.target(address(test)).sig(test.basic.selector).depth(0).find(); - assertEq(uint256(7), slot); - } - - function test_StorageStructB() public { - uint256 slot = stdstore.target(address(test)).sig(test.basic.selector).depth(1).find(); - assertEq(uint256(7) + 1, slot); - } - - function test_StorageCheckedWriteStructA() public { - stdstore.target(address(test)).sig(test.basic.selector).depth(0).checked_write(100); - (uint256 a, uint256 b) = test.basic(); - assertEq(a, 100); - assertEq(b, 1337); - } - - function test_StorageCheckedWriteStructB() public { - stdstore.target(address(test)).sig(test.basic.selector).depth(1).checked_write(100); - (uint256 a, uint256 b) = test.basic(); - assertEq(a, 1337); - assertEq(b, 100); - } - - function test_StorageMapAddrFound() public { - uint256 slot = stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).find(); - assertEq(uint256(keccak256(abi.encode(address(this), uint256(1)))), slot); - } - - function test_StorageMapAddrRoot() public { - (uint256 slot, bytes32 key) = - stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).parent(); - assertEq(address(uint160(uint256(key))), address(this)); - assertEq(uint256(1), slot); - slot = stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).root(); - assertEq(uint256(1), slot); - } - - function test_StorageMapUintFound() public { - uint256 slot = stdstore.target(address(test)).sig(test.map_uint.selector).with_key(100).find(); - assertEq(uint256(keccak256(abi.encode(100, uint256(2)))), slot); - } - - function test_StorageCheckedWriteMapUint() public { - stdstore.target(address(test)).sig(test.map_uint.selector).with_key(100).checked_write(100); - assertEq(100, test.map_uint(100)); - } - - function test_StorageCheckedWriteMapAddr() public { - stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).checked_write(100); - assertEq(100, test.map_addr(address(this))); - } - - function test_StorageCheckedWriteMapBool() public { - stdstore.target(address(test)).sig(test.map_bool.selector).with_key(address(this)).checked_write(true); - assertTrue(test.map_bool(address(this))); - } - - function testFuzz_StorageCheckedWriteMapPacked(address addr, uint128 value) public { - stdstore.enable_packed_slots().target(address(test)).sig(test.read_struct_lower.selector).with_key(addr) - .checked_write(value); - assertEq(test.read_struct_lower(addr), value); - - stdstore.enable_packed_slots().target(address(test)).sig(test.read_struct_upper.selector).with_key(addr) - .checked_write(value); - assertEq(test.read_struct_upper(addr), value); - } - - function test_StorageCheckedWriteMapPackedFullSuccess() public { - uint256 full = test.map_packed(address(1337)); - // keep upper 128, set lower 128 to 1337 - full = (full & (uint256((1 << 128) - 1) << 128)) | 1337; - stdstore.target(address(test)).sig(test.map_packed.selector).with_key(address(uint160(1337))).checked_write( - full - ); - assertEq(1337, test.read_struct_lower(address(1337))); - } - - function test_RevertStorageConst() public { - StorageTestTarget target = new StorageTestTarget(test); - - vm.expectRevert("stdStorage find(StdStorage): No storage use detected for target."); - target.expectRevertStorageConst(); - } - - function testFuzz_StorageNativePack(uint248 val1, uint248 val2, bool boolVal1, bool boolVal2) public { - stdstore.enable_packed_slots().target(address(test)).sig(test.tA.selector).checked_write(val1); - stdstore.enable_packed_slots().target(address(test)).sig(test.tB.selector).checked_write(boolVal1); - stdstore.enable_packed_slots().target(address(test)).sig(test.tC.selector).checked_write(boolVal2); - stdstore.enable_packed_slots().target(address(test)).sig(test.tD.selector).checked_write(val2); - - assertEq(test.tA(), val1); - assertEq(test.tB(), boolVal1); - assertEq(test.tC(), boolVal2); - assertEq(test.tD(), val2); - } - - function test_StorageReadBytes32() public { - bytes32 val = stdstore.target(address(test)).sig(test.tE.selector).read_bytes32(); - assertEq(val, hex"1337"); - } - - function test_StorageReadBool_False() public { - bool val = stdstore.target(address(test)).sig(test.tB.selector).read_bool(); - assertEq(val, false); - } - - function test_StorageReadBool_True() public { - bool val = stdstore.target(address(test)).sig(test.tH.selector).read_bool(); - assertEq(val, true); - } - - function test_RevertIf_ReadingNonBoolValue() public { - vm.expectRevert("stdStorage read_bool(StdStorage): Cannot decode. Make sure you are reading a bool."); - this.readNonBoolValue(); - } - - function readNonBoolValue() public { - stdstore.target(address(test)).sig(test.tE.selector).read_bool(); - } - - function test_StorageReadAddress() public { - address val = stdstore.target(address(test)).sig(test.tF.selector).read_address(); - assertEq(val, address(1337)); - } - - function test_StorageReadUint() public { - uint256 val = stdstore.target(address(test)).sig(test.exists.selector).read_uint(); - assertEq(val, 1); - } - - function test_StorageReadInt() public { - int256 val = stdstore.target(address(test)).sig(test.tG.selector).read_int(); - assertEq(val, type(int256).min); - } - - function testFuzz_Packed(uint256 val, uint8 elemToGet) public { - // This function tries an assortment of packed slots, shifts meaning number of elements - // that are packed. Shiftsizes are the size of each element, i.e. 8 means a data type that is 8 bits, 16 == 16 bits, etc. - // Combined, these determine how a slot is packed. Making it random is too hard to avoid global rejection limit - // and make it performant. - - // change the number of shifts - for (uint256 i = 1; i < 5; i++) { - uint256 shifts = i; - - elemToGet = uint8(bound(elemToGet, 0, shifts - 1)); - - uint256[] memory shiftSizes = new uint256[](shifts); - for (uint256 j; j < shifts; j++) { - shiftSizes[j] = 8 * (j + 1); - } - - test.setRandomPacking(val); - - uint256 leftBits; - uint256 rightBits; - for (uint256 j; j < shiftSizes.length; j++) { - if (j < elemToGet) { - leftBits += shiftSizes[j]; - } else if (elemToGet != j) { - rightBits += shiftSizes[j]; - } - } - - // we may have some right bits unaccounted for - leftBits += 256 - (leftBits + shiftSizes[elemToGet] + rightBits); - // clear left bits, then clear right bits and realign - uint256 expectedValToRead = (val << leftBits) >> (leftBits + rightBits); - - uint256 readVal = stdstore.target(address(test)).enable_packed_slots().sig( - "getRandomPacked(uint8,uint8[],uint8)" - ).with_calldata(abi.encode(shifts, shiftSizes, elemToGet)).read_uint(); - - assertEq(readVal, expectedValToRead); - } - } - - function testFuzz_Packed2(uint256 nvars, uint256 seed) public { - // Number of random variables to generate. - nvars = bound(nvars, 1, 20); - - // This will decrease as we generate values in the below loop. - uint256 bitsRemaining = 256; - - // Generate a random value and size for each variable. - uint256[] memory vals = new uint256[](nvars); - uint256[] memory sizes = new uint256[](nvars); - uint256[] memory offsets = new uint256[](nvars); - - for (uint256 i = 0; i < nvars; i++) { - // Generate a random value and size. - offsets[i] = i == 0 ? 0 : offsets[i - 1] + sizes[i - 1]; - - uint256 nvarsRemaining = nvars - i; - uint256 maxVarSize = bitsRemaining - nvarsRemaining + 1; - sizes[i] = bound(uint256(keccak256(abi.encodePacked(seed, i + 256))), 1, maxVarSize); - bitsRemaining -= sizes[i]; - - uint256 maxVal; - uint256 varSize = sizes[i]; - assembly { - // mask = (1 << varSize) - 1 - maxVal := sub(shl(varSize, 1), 1) - } - vals[i] = bound(uint256(keccak256(abi.encodePacked(seed, i))), 0, maxVal); - } - - // Pack all values into the slot. - for (uint256 i = 0; i < nvars; i++) { - stdstore.enable_packed_slots().target(address(test)).sig("getRandomPacked(uint256,uint256)").with_key( - sizes[i] - ).with_key(offsets[i]).checked_write(vals[i]); - } - - // Verify the read data matches. - for (uint256 i = 0; i < nvars; i++) { - uint256 readVal = stdstore.enable_packed_slots().target(address(test)).sig( - "getRandomPacked(uint256,uint256)" - ).with_key(sizes[i]).with_key(offsets[i]).read_uint(); - - uint256 retVal = test.getRandomPacked(sizes[i], offsets[i]); - - assertEq(readVal, vals[i]); - assertEq(retVal, vals[i]); - } - } - - function testEdgeCaseArray() public { - stdstore.target(address(test)).sig("edgeCaseArray(uint256)").with_key(uint256(0)).checked_write(1); - assertEq(test.edgeCaseArray(0), 1); - } -} - -contract StorageTestTarget { - using stdStorage for StdStorage; - - StdStorage internal stdstore; - StorageTest internal test; - - constructor(StorageTest test_) { - test = test_; - } - - function expectRevertStorageConst() public { - stdstore.target(address(test)).sig("const()").find(); - } -} - -contract StorageTest { - uint256 public exists = 1; - mapping(address => uint256) public map_addr; - mapping(uint256 => uint256) public map_uint; - mapping(address => uint256) public map_packed; - mapping(address => UnpackedStruct) public map_struct; - mapping(address => mapping(address => uint256)) public deep_map; - mapping(address => mapping(address => UnpackedStruct)) public deep_map_struct; - UnpackedStruct public basic; - - uint248 public tA; - bool public tB; - - bool public tC = false; - uint248 public tD = 1; - - struct UnpackedStruct { - uint256 a; - uint256 b; - } - - mapping(address => bool) public map_bool; - - bytes32 public tE = hex"1337"; - address public tF = address(1337); - int256 public tG = type(int256).min; - bool public tH = true; - bytes32 private tI = ~bytes32(hex"1337"); - - uint256 randomPacking; - - // Array with length matching values of elements. - uint256[] public edgeCaseArray = [3, 3, 3]; - - constructor() { - basic = UnpackedStruct({a: 1337, b: 1337}); - - uint256 two = (1 << 128) | 1; - map_packed[msg.sender] = two; - map_packed[address(uint160(1337))] = 1 << 128; - } - - function read_struct_upper(address who) public view returns (uint256) { - return map_packed[who] >> 128; - } - - function read_struct_lower(address who) public view returns (uint256) { - return map_packed[who] & ((1 << 128) - 1); - } - - function hidden() public view returns (bytes32 t) { - bytes32 slot = keccak256("my.random.var"); - /// @solidity memory-safe-assembly - assembly { - t := sload(slot) - } - } - - function const() public pure returns (bytes32 t) { - t = bytes32(hex"1337"); - } - - function extra_sload() public view returns (bytes32 t) { - // trigger read on slot `tE`, and make a staticcall to make sure compiler doesn't optimize this SLOAD away - assembly { - pop(staticcall(gas(), sload(tE.slot), 0, 0, 0, 0)) - } - t = tI; - } - - function setRandomPacking(uint256 val) public { - randomPacking = val; - } - - function _getMask(uint256 size) internal pure returns (uint256 mask) { - assembly { - // mask = (1 << size) - 1 - mask := sub(shl(size, 1), 1) - } - } - - function setRandomPacking(uint256 val, uint256 size, uint256 offset) public { - // Generate mask based on the size of the value - uint256 mask = _getMask(size); - // Zero out all bits for the word we're about to set - uint256 cleanedWord = randomPacking & ~(mask << offset); - // Place val in the correct spot of the cleaned word - randomPacking = cleanedWord | val << offset; - } - - function getRandomPacked(uint256 size, uint256 offset) public view returns (uint256) { - // Generate mask based on the size of the value - uint256 mask = _getMask(size); - // Shift to place the bits in the correct position, and use mask to zero out remaining bits - return (randomPacking >> offset) & mask; - } - - function getRandomPacked(uint8 shifts, uint8[] memory shiftSizes, uint8 elem) public view returns (uint256) { - require(elem < shifts, "!elem"); - uint256 leftBits; - uint256 rightBits; - - for (uint256 i; i < shiftSizes.length; i++) { - if (i < elem) { - leftBits += shiftSizes[i]; - } else if (elem != i) { - rightBits += shiftSizes[i]; - } - } - - // we may have some right bits unaccounted for - leftBits += 256 - (leftBits + shiftSizes[elem] + rightBits); - - // clear left bits, then clear right bits and realign - return (randomPacking << leftBits) >> (leftBits + rightBits); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/StdStyle.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/StdStyle.t.sol deleted file mode 100644 index 974e756fe5..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/StdStyle.t.sol +++ /dev/null @@ -1,110 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {Test, console2, StdStyle} from "../src/Test.sol"; - -contract StdStyleTest is Test { - function test_StyleColor() public pure { - console2.log(StdStyle.red("StdStyle.red String Test")); - console2.log(StdStyle.red(uint256(10e18))); - console2.log(StdStyle.red(int256(-10e18))); - console2.log(StdStyle.red(true)); - console2.log(StdStyle.red(address(0))); - console2.log(StdStyle.redBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.redBytes32("StdStyle.redBytes32")); - console2.log(StdStyle.green("StdStyle.green String Test")); - console2.log(StdStyle.green(uint256(10e18))); - console2.log(StdStyle.green(int256(-10e18))); - console2.log(StdStyle.green(true)); - console2.log(StdStyle.green(address(0))); - console2.log(StdStyle.greenBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.greenBytes32("StdStyle.greenBytes32")); - console2.log(StdStyle.yellow("StdStyle.yellow String Test")); - console2.log(StdStyle.yellow(uint256(10e18))); - console2.log(StdStyle.yellow(int256(-10e18))); - console2.log(StdStyle.yellow(true)); - console2.log(StdStyle.yellow(address(0))); - console2.log(StdStyle.yellowBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.yellowBytes32("StdStyle.yellowBytes32")); - console2.log(StdStyle.blue("StdStyle.blue String Test")); - console2.log(StdStyle.blue(uint256(10e18))); - console2.log(StdStyle.blue(int256(-10e18))); - console2.log(StdStyle.blue(true)); - console2.log(StdStyle.blue(address(0))); - console2.log(StdStyle.blueBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.blueBytes32("StdStyle.blueBytes32")); - console2.log(StdStyle.magenta("StdStyle.magenta String Test")); - console2.log(StdStyle.magenta(uint256(10e18))); - console2.log(StdStyle.magenta(int256(-10e18))); - console2.log(StdStyle.magenta(true)); - console2.log(StdStyle.magenta(address(0))); - console2.log(StdStyle.magentaBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.magentaBytes32("StdStyle.magentaBytes32")); - console2.log(StdStyle.cyan("StdStyle.cyan String Test")); - console2.log(StdStyle.cyan(uint256(10e18))); - console2.log(StdStyle.cyan(int256(-10e18))); - console2.log(StdStyle.cyan(true)); - console2.log(StdStyle.cyan(address(0))); - console2.log(StdStyle.cyanBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.cyanBytes32("StdStyle.cyanBytes32")); - } - - function test_StyleFontWeight() public pure { - console2.log(StdStyle.bold("StdStyle.bold String Test")); - console2.log(StdStyle.bold(uint256(10e18))); - console2.log(StdStyle.bold(int256(-10e18))); - console2.log(StdStyle.bold(address(0))); - console2.log(StdStyle.bold(true)); - console2.log(StdStyle.boldBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.boldBytes32("StdStyle.boldBytes32")); - console2.log(StdStyle.dim("StdStyle.dim String Test")); - console2.log(StdStyle.dim(uint256(10e18))); - console2.log(StdStyle.dim(int256(-10e18))); - console2.log(StdStyle.dim(address(0))); - console2.log(StdStyle.dim(true)); - console2.log(StdStyle.dimBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.dimBytes32("StdStyle.dimBytes32")); - console2.log(StdStyle.italic("StdStyle.italic String Test")); - console2.log(StdStyle.italic(uint256(10e18))); - console2.log(StdStyle.italic(int256(-10e18))); - console2.log(StdStyle.italic(address(0))); - console2.log(StdStyle.italic(true)); - console2.log(StdStyle.italicBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.italicBytes32("StdStyle.italicBytes32")); - console2.log(StdStyle.underline("StdStyle.underline String Test")); - console2.log(StdStyle.underline(uint256(10e18))); - console2.log(StdStyle.underline(int256(-10e18))); - console2.log(StdStyle.underline(address(0))); - console2.log(StdStyle.underline(true)); - console2.log(StdStyle.underlineBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.underlineBytes32("StdStyle.underlineBytes32")); - console2.log(StdStyle.inverse("StdStyle.inverse String Test")); - console2.log(StdStyle.inverse(uint256(10e18))); - console2.log(StdStyle.inverse(int256(-10e18))); - console2.log(StdStyle.inverse(address(0))); - console2.log(StdStyle.inverse(true)); - console2.log(StdStyle.inverseBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.inverseBytes32("StdStyle.inverseBytes32")); - } - - function test_StyleCombined() public pure { - console2.log(StdStyle.red(StdStyle.bold("Red Bold String Test"))); - console2.log(StdStyle.green(StdStyle.dim(uint256(10e18)))); - console2.log(StdStyle.yellow(StdStyle.italic(int256(-10e18)))); - console2.log(StdStyle.blue(StdStyle.underline(address(0)))); - console2.log(StdStyle.magenta(StdStyle.inverse(true))); - } - - function test_StyleCustom() public pure { - console2.log(h1("Custom Style 1")); - console2.log(h2("Custom Style 2")); - } - - function h1(string memory a) private pure returns (string memory) { - return StdStyle.cyan(StdStyle.inverse(StdStyle.bold(a))); - } - - function h2(string memory a) private pure returns (string memory) { - return StdStyle.magenta(StdStyle.bold(StdStyle.underline(a))); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/StdToml.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/StdToml.t.sol deleted file mode 100644 index 5a45f4f5c9..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/StdToml.t.sol +++ /dev/null @@ -1,49 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {Test, stdToml} from "../src/Test.sol"; - -contract StdTomlTest is Test { - using stdToml for string; - - string root; - string path; - - function setUp() public { - root = vm.projectRoot(); - path = string.concat(root, "/test/fixtures/test.toml"); - } - - struct SimpleToml { - uint256 a; - string b; - } - - struct NestedToml { - uint256 a; - string b; - SimpleToml c; - } - - function test_readToml() public view { - string memory json = vm.readFile(path); - assertEq(json.readUint(".a"), 123); - } - - function test_writeToml() public { - string memory json = "json"; - json.serialize("a", uint256(123)); - string memory semiFinal = json.serialize("b", string("test")); - string memory finalJson = json.serialize("c", semiFinal); - finalJson.write(path); - - string memory toml = vm.readFile(path); - bytes memory data = toml.parseRaw("$"); - NestedToml memory decodedData = abi.decode(data, (NestedToml)); - - assertEq(decodedData.a, 123); - assertEq(decodedData.b, "test"); - assertEq(decodedData.c.a, 123); - assertEq(decodedData.c.b, "test"); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/StdUtils.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/StdUtils.t.sol deleted file mode 100644 index aee801b2cf..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/StdUtils.t.sol +++ /dev/null @@ -1,342 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {Test, StdUtils} from "../src/Test.sol"; - -contract StdUtilsMock is StdUtils { - // We deploy a mock version so we can properly test expected reverts. - function exposed_getTokenBalances(address token, address[] memory addresses) - external - returns (uint256[] memory balances) - { - return getTokenBalances(token, addresses); - } - - function exposed_bound(int256 num, int256 min, int256 max) external pure returns (int256) { - return bound(num, min, max); - } - - function exposed_bound(uint256 num, uint256 min, uint256 max) external pure returns (uint256) { - return bound(num, min, max); - } - - function exposed_bytesToUint(bytes memory b) external pure returns (uint256) { - return bytesToUint(b); - } -} - -contract StdUtilsTest is Test { - /*////////////////////////////////////////////////////////////////////////// - BOUND UINT - //////////////////////////////////////////////////////////////////////////*/ - - function test_Bound() public pure { - assertEq(bound(uint256(5), 0, 4), 0); - assertEq(bound(uint256(0), 69, 69), 69); - assertEq(bound(uint256(0), 68, 69), 68); - assertEq(bound(uint256(10), 150, 190), 174); - assertEq(bound(uint256(300), 2800, 3200), 3107); - assertEq(bound(uint256(9999), 1337, 6666), 4669); - } - - function test_Bound_WithinRange() public pure { - assertEq(bound(uint256(51), 50, 150), 51); - assertEq(bound(uint256(51), 50, 150), bound(bound(uint256(51), 50, 150), 50, 150)); - assertEq(bound(uint256(149), 50, 150), 149); - assertEq(bound(uint256(149), 50, 150), bound(bound(uint256(149), 50, 150), 50, 150)); - } - - function test_Bound_EdgeCoverage() public pure { - assertEq(bound(uint256(0), 50, 150), 50); - assertEq(bound(uint256(1), 50, 150), 51); - assertEq(bound(uint256(2), 50, 150), 52); - assertEq(bound(uint256(3), 50, 150), 53); - assertEq(bound(type(uint256).max, 50, 150), 150); - assertEq(bound(type(uint256).max - 1, 50, 150), 149); - assertEq(bound(type(uint256).max - 2, 50, 150), 148); - assertEq(bound(type(uint256).max - 3, 50, 150), 147); - } - - function testFuzz_Bound_DistributionIsEven(uint256 min, uint256 size) public pure { - size = size % 100 + 1; - min = bound(min, UINT256_MAX / 2, UINT256_MAX / 2 + size); - uint256 max = min + size - 1; - uint256 result; - - for (uint256 i = 1; i <= size * 4; ++i) { - // x > max - result = bound(max + i, min, max); - assertEq(result, min + (i - 1) % size); - // x < min - result = bound(min - i, min, max); - assertEq(result, max - (i - 1) % size); - } - } - - function testFuzz_Bound(uint256 num, uint256 min, uint256 max) public pure { - if (min > max) (min, max) = (max, min); - - uint256 result = bound(num, min, max); - - assertGe(result, min); - assertLe(result, max); - assertEq(result, bound(result, min, max)); - if (num >= min && num <= max) assertEq(result, num); - } - - function test_BoundUint256Max() public pure { - assertEq(bound(0, type(uint256).max - 1, type(uint256).max), type(uint256).max - 1); - assertEq(bound(1, type(uint256).max - 1, type(uint256).max), type(uint256).max); - } - - function test_RevertIf_BoundMaxLessThanMin() public { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - vm.expectRevert(bytes("StdUtils bound(uint256,uint256,uint256): Max is less than min.")); - stdUtils.exposed_bound(uint256(5), 100, 10); - } - - function testFuzz_RevertIf_BoundMaxLessThanMin(uint256 num, uint256 min, uint256 max) public { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - vm.assume(min > max); - vm.expectRevert(bytes("StdUtils bound(uint256,uint256,uint256): Max is less than min.")); - stdUtils.exposed_bound(num, min, max); - } - - /*////////////////////////////////////////////////////////////////////////// - BOUND INT - //////////////////////////////////////////////////////////////////////////*/ - - function test_BoundInt() public pure { - assertEq(bound(-3, 0, 4), 2); - assertEq(bound(0, -69, -69), -69); - assertEq(bound(0, -69, -68), -68); - assertEq(bound(-10, 150, 190), 154); - assertEq(bound(-300, 2800, 3200), 2908); - assertEq(bound(9999, -1337, 6666), 1995); - } - - function test_BoundInt_WithinRange() public pure { - assertEq(bound(51, -50, 150), 51); - assertEq(bound(51, -50, 150), bound(bound(51, -50, 150), -50, 150)); - assertEq(bound(149, -50, 150), 149); - assertEq(bound(149, -50, 150), bound(bound(149, -50, 150), -50, 150)); - } - - function test_BoundInt_EdgeCoverage() public pure { - assertEq(bound(type(int256).min, -50, 150), -50); - assertEq(bound(type(int256).min + 1, -50, 150), -49); - assertEq(bound(type(int256).min + 2, -50, 150), -48); - assertEq(bound(type(int256).min + 3, -50, 150), -47); - assertEq(bound(type(int256).min, 10, 150), 10); - assertEq(bound(type(int256).min + 1, 10, 150), 11); - assertEq(bound(type(int256).min + 2, 10, 150), 12); - assertEq(bound(type(int256).min + 3, 10, 150), 13); - - assertEq(bound(type(int256).max, -50, 150), 150); - assertEq(bound(type(int256).max - 1, -50, 150), 149); - assertEq(bound(type(int256).max - 2, -50, 150), 148); - assertEq(bound(type(int256).max - 3, -50, 150), 147); - assertEq(bound(type(int256).max, -50, -10), -10); - assertEq(bound(type(int256).max - 1, -50, -10), -11); - assertEq(bound(type(int256).max - 2, -50, -10), -12); - assertEq(bound(type(int256).max - 3, -50, -10), -13); - } - - function testFuzz_BoundInt_DistributionIsEven(int256 min, uint256 size) public pure { - size = size % 100 + 1; - min = bound(min, -int256(size / 2), int256(size - size / 2)); - int256 max = min + int256(size) - 1; - int256 result; - - for (uint256 i = 1; i <= size * 4; ++i) { - // x > max - result = bound(max + int256(i), min, max); - assertEq(result, min + int256((i - 1) % size)); - // x < min - result = bound(min - int256(i), min, max); - assertEq(result, max - int256((i - 1) % size)); - } - } - - function testFuzz_BoundInt(int256 num, int256 min, int256 max) public pure { - if (min > max) (min, max) = (max, min); - - int256 result = bound(num, min, max); - - assertGe(result, min); - assertLe(result, max); - assertEq(result, bound(result, min, max)); - if (num >= min && num <= max) assertEq(result, num); - } - - function test_BoundIntInt256Max() public pure { - assertEq(bound(0, type(int256).max - 1, type(int256).max), type(int256).max - 1); - assertEq(bound(1, type(int256).max - 1, type(int256).max), type(int256).max); - } - - function test_BoundIntInt256Min() public pure { - assertEq(bound(0, type(int256).min, type(int256).min + 1), type(int256).min); - assertEq(bound(1, type(int256).min, type(int256).min + 1), type(int256).min + 1); - } - - function test_RevertIf_BoundIntMaxLessThanMin() public { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - vm.expectRevert(bytes("StdUtils bound(int256,int256,int256): Max is less than min.")); - stdUtils.exposed_bound(-5, 100, 10); - } - - function testFuzz_RevertIf_BoundIntMaxLessThanMin(int256 num, int256 min, int256 max) public { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - vm.assume(min > max); - vm.expectRevert(bytes("StdUtils bound(int256,int256,int256): Max is less than min.")); - stdUtils.exposed_bound(num, min, max); - } - - /*////////////////////////////////////////////////////////////////////////// - BOUND PRIVATE KEY - //////////////////////////////////////////////////////////////////////////*/ - - function test_BoundPrivateKey() public pure { - assertEq(boundPrivateKey(0), 1); - assertEq(boundPrivateKey(1), 1); - assertEq(boundPrivateKey(300), 300); - assertEq(boundPrivateKey(9999), 9999); - assertEq(boundPrivateKey(SECP256K1_ORDER - 1), SECP256K1_ORDER - 1); - assertEq(boundPrivateKey(SECP256K1_ORDER), 1); - assertEq(boundPrivateKey(SECP256K1_ORDER + 1), 2); - assertEq(boundPrivateKey(UINT256_MAX), UINT256_MAX & SECP256K1_ORDER - 1); // x&y is equivalent to x-x%y - } - - /*////////////////////////////////////////////////////////////////////////// - BYTES TO UINT - //////////////////////////////////////////////////////////////////////////*/ - - function test_BytesToUint() external pure { - bytes memory maxUint = hex"ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"; - bytes memory two = hex"02"; - bytes memory millionEther = hex"d3c21bcecceda1000000"; - - assertEq(bytesToUint(maxUint), type(uint256).max); - assertEq(bytesToUint(two), 2); - assertEq(bytesToUint(millionEther), 1_000_000 ether); - } - - function test_RevertIf_BytesLengthExceeds32() external { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - bytes memory thirty3Bytes = hex"ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"; - vm.expectRevert("StdUtils bytesToUint(bytes): Bytes length exceeds 32."); - stdUtils.exposed_bytesToUint(thirty3Bytes); - } - - /*////////////////////////////////////////////////////////////////////////// - COMPUTE CREATE ADDRESS - //////////////////////////////////////////////////////////////////////////*/ - - function test_ComputeCreateAddress() external pure { - address deployer = 0x6C9FC64A53c1b71FB3f9Af64d1ae3A4931A5f4E9; - uint256 nonce = 14; - address createAddress = computeCreateAddress(deployer, nonce); - assertEq(createAddress, 0x68b3465833fb72A70ecDF485E0e4C7bD8665Fc45); - } - - /*////////////////////////////////////////////////////////////////////////// - COMPUTE CREATE2 ADDRESS - //////////////////////////////////////////////////////////////////////////*/ - - function test_ComputeCreate2Address() external pure { - bytes32 salt = bytes32(uint256(31415)); - bytes32 initcodeHash = keccak256(abi.encode(0x6080)); - address deployer = 0x6C9FC64A53c1b71FB3f9Af64d1ae3A4931A5f4E9; - address create2Address = computeCreate2Address(salt, initcodeHash, deployer); - assertEq(create2Address, 0xB147a5d25748fda14b463EB04B111027C290f4d3); - } - - function test_ComputeCreate2AddressWithDefaultDeployer() external pure { - bytes32 salt = 0xc290c670fde54e5ef686f9132cbc8711e76a98f0333a438a92daa442c71403c0; - bytes32 initcodeHash = hashInitCode(hex"6080", ""); - assertEq(initcodeHash, 0x1a578b7a4b0b5755db6d121b4118d4bc68fe170dca840c59bc922f14175a76b0); - address create2Address = computeCreate2Address(salt, initcodeHash); - assertEq(create2Address, 0xc0ffEe2198a06235aAbFffe5Db0CacF1717f5Ac6); - } -} - -contract StdUtilsForkTest is Test { - /*////////////////////////////////////////////////////////////////////////// - GET TOKEN BALANCES - //////////////////////////////////////////////////////////////////////////*/ - - address internal SHIB = 0x95aD61b0a150d79219dCF64E1E6Cc01f0B64C4cE; - address internal SHIB_HOLDER_0 = 0x855F5981e831D83e6A4b4EBFCAdAa68D92333170; - address internal SHIB_HOLDER_1 = 0x8F509A90c2e47779cA408Fe00d7A72e359229AdA; - address internal SHIB_HOLDER_2 = 0x0e3bbc0D04fF62211F71f3e4C45d82ad76224385; - - address internal USDC = 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48; - address internal USDC_HOLDER_0 = 0xDa9CE944a37d218c3302F6B82a094844C6ECEb17; - address internal USDC_HOLDER_1 = 0x3e67F4721E6d1c41a015f645eFa37BEd854fcf52; - - function setUp() public { - // All tests of the `getTokenBalances` method are fork tests using live contracts. - vm.createSelectFork({urlOrAlias: "mainnet", blockNumber: 16_428_900}); - } - - function test_RevertIf_CannotGetTokenBalances_NonTokenContract() external { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - // The UniswapV2Factory contract has neither a `balanceOf` function nor a fallback function, - // so the `balanceOf` call should revert. - address token = address(0x5C69bEe701ef814a2B6a3EDD4B1652CB9cc5aA6f); - address[] memory addresses = new address[](1); - addresses[0] = USDC_HOLDER_0; - - vm.expectRevert("Multicall3: call failed"); - stdUtils.exposed_getTokenBalances(token, addresses); - } - - function test_RevertIf_CannotGetTokenBalances_EOA() external { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - address eoa = vm.addr({privateKey: 1}); - address[] memory addresses = new address[](1); - addresses[0] = USDC_HOLDER_0; - vm.expectRevert("StdUtils getTokenBalances(address,address[]): Token address is not a contract."); - stdUtils.exposed_getTokenBalances(eoa, addresses); - } - - function test_GetTokenBalances_Empty() external { - address[] memory addresses = new address[](0); - uint256[] memory balances = getTokenBalances(USDC, addresses); - assertEq(balances.length, 0); - } - - function test_GetTokenBalances_USDC() external { - address[] memory addresses = new address[](2); - addresses[0] = USDC_HOLDER_0; - addresses[1] = USDC_HOLDER_1; - uint256[] memory balances = getTokenBalances(USDC, addresses); - assertEq(balances[0], 159_000_000_000_000); - assertEq(balances[1], 131_350_000_000_000); - } - - function test_GetTokenBalances_SHIB() external { - address[] memory addresses = new address[](3); - addresses[0] = SHIB_HOLDER_0; - addresses[1] = SHIB_HOLDER_1; - addresses[2] = SHIB_HOLDER_2; - uint256[] memory balances = getTokenBalances(SHIB, addresses); - assertEq(balances[0], 3_323_256_285_484.42e18); - assertEq(balances[1], 1_271_702_771_149.99999928e18); - assertEq(balances[2], 606_357_106_247e18); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/Vm.t.sol b/lib/signals-implicit-mode/lib/forge-std/test/Vm.t.sol deleted file mode 100644 index 1b99e3db11..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/Vm.t.sol +++ /dev/null @@ -1,18 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.8.0 <0.9.0; - -import {Test} from "../src/Test.sol"; -import {Vm, VmSafe} from "../src/Vm.sol"; - -// These tests ensure that functions are never accidentally removed from a Vm interface, or -// inadvertently moved between Vm and VmSafe. These tests must be updated each time a function is -// added to or removed from Vm or VmSafe. -contract VmTest is Test { - function test_VmInterfaceId() public pure { - assertEq(type(Vm).interfaceId, bytes4(0xe835828d), "Vm"); - } - - function test_VmSafeInterfaceId() public pure { - assertEq(type(VmSafe).interfaceId, bytes4(0xe02727c3), "VmSafe"); - } -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/compilation/CompilationScript.sol b/lib/signals-implicit-mode/lib/forge-std/test/compilation/CompilationScript.sol deleted file mode 100644 index d3d88a0b5c..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/compilation/CompilationScript.sol +++ /dev/null @@ -1,10 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -import {Script} from "../../src/Script.sol"; - -// The purpose of this contract is to benchmark compilation time to avoid accidentally introducing -// a change that results in very long compilation times with via-ir. See https://github.com/foundry-rs/forge-std/issues/207 -contract CompilationScript is Script {} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/compilation/CompilationScriptBase.sol b/lib/signals-implicit-mode/lib/forge-std/test/compilation/CompilationScriptBase.sol deleted file mode 100644 index 65b5bedbe2..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/compilation/CompilationScriptBase.sol +++ /dev/null @@ -1,10 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -import {ScriptBase} from "../../src/Script.sol"; - -// The purpose of this contract is to benchmark compilation time to avoid accidentally introducing -// a change that results in very long compilation times with via-ir. See https://github.com/foundry-rs/forge-std/issues/207 -contract CompilationScriptBase is ScriptBase {} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/compilation/CompilationTest.sol b/lib/signals-implicit-mode/lib/forge-std/test/compilation/CompilationTest.sol deleted file mode 100644 index 2a9dec57f0..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/compilation/CompilationTest.sol +++ /dev/null @@ -1,10 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -import {Test} from "../../src/Test.sol"; - -// The purpose of this contract is to benchmark compilation time to avoid accidentally introducing -// a change that results in very long compilation times with via-ir. See https://github.com/foundry-rs/forge-std/issues/207 -contract CompilationTest is Test {} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/compilation/CompilationTestBase.sol b/lib/signals-implicit-mode/lib/forge-std/test/compilation/CompilationTestBase.sol deleted file mode 100644 index 32b3fc5be6..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/compilation/CompilationTestBase.sol +++ /dev/null @@ -1,10 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -import {TestBase} from "../../src/Test.sol"; - -// The purpose of this contract is to benchmark compilation time to avoid accidentally introducing -// a change that results in very long compilation times with via-ir. See https://github.com/foundry-rs/forge-std/issues/207 -contract CompilationTestBase is TestBase {} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/fixtures/broadcast.log.json b/lib/signals-implicit-mode/lib/forge-std/test/fixtures/broadcast.log.json deleted file mode 100644 index 0a0200bca9..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/fixtures/broadcast.log.json +++ /dev/null @@ -1,187 +0,0 @@ -{ - "transactions": [ - { - "hash": "0xc6006863c267735a11476b7f15b15bc718e117e2da114a2be815dd651e1a509f", - "type": "CALL", - "contractName": "Test", - "contractAddress": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "function": "multiple_arguments(uint256,address,uint256[]):(uint256)", - "arguments": ["1", "0000000000000000000000000000000000001337", "[3,4]"], - "tx": { - "type": "0x02", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "gas": "0x73b9", - "value": "0x0", - "data": "0x23e99187000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000013370000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000000004", - "nonce": "0x3", - "accessList": [] - } - }, - { - "hash": "0xedf2b38d8d896519a947a1acf720f859bb35c0c5ecb8dd7511995b67b9853298", - "type": "CALL", - "contractName": "Test", - "contractAddress": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "function": "inc():(uint256)", - "arguments": [], - "tx": { - "type": "0x02", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "gas": "0xdcb2", - "value": "0x0", - "data": "0x371303c0", - "nonce": "0x4", - "accessList": [] - } - }, - { - "hash": "0xa57e8e3981a6c861442e46c9471bd19cb3e21f9a8a6c63a72e7b5c47c6675a7c", - "type": "CALL", - "contractName": "Test", - "contractAddress": "0x7c6b4bbe207d642d98d5c537142d85209e585087", - "function": "t(uint256):(uint256)", - "arguments": ["1"], - "tx": { - "type": "0x02", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0x7c6b4bbe207d642d98d5c537142d85209e585087", - "gas": "0x8599", - "value": "0x0", - "data": "0xafe29f710000000000000000000000000000000000000000000000000000000000000001", - "nonce": "0x5", - "accessList": [] - } - } - ], - "receipts": [ - { - "transactionHash": "0x481dc86e40bba90403c76f8e144aa9ff04c1da2164299d0298573835f0991181", - "transactionIndex": "0x0", - "blockHash": "0xef0730448490304e5403be0fa8f8ce64f118e9adcca60c07a2ae1ab921d748af", - "blockNumber": "0x1", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": null, - "cumulativeGasUsed": "0x13f3a", - "gasUsed": "0x13f3a", - "contractAddress": "0x5fbdb2315678afecb367f032d93f642f64180aa3", - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0x6a187183545b8a9e7f1790e847139379bf5622baff2cb43acf3f5c79470af782", - "transactionIndex": "0x0", - "blockHash": "0xf3acb96a90071640c2a8c067ae4e16aad87e634ea8d8bbbb5b352fba86ba0148", - "blockNumber": "0x2", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": null, - "cumulativeGasUsed": "0x45d80", - "gasUsed": "0x45d80", - "contractAddress": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0x064ad173b4867bdef2fb60060bbdaf01735fbf10414541ea857772974e74ea9d", - "transactionIndex": "0x0", - "blockHash": "0x8373d02109d3ee06a0225f23da4c161c656ccc48fe0fcee931d325508ae73e58", - "blockNumber": "0x3", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0x4e59b44847b379578588920ca78fbf26c0b4956c", - "cumulativeGasUsed": "0x45feb", - "gasUsed": "0x45feb", - "contractAddress": null, - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0xc6006863c267735a11476b7f15b15bc718e117e2da114a2be815dd651e1a509f", - "transactionIndex": "0x0", - "blockHash": "0x16712fae5c0e18f75045f84363fb6b4d9a9fe25e660c4ce286833a533c97f629", - "blockNumber": "0x4", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "cumulativeGasUsed": "0x5905", - "gasUsed": "0x5905", - "contractAddress": null, - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0xedf2b38d8d896519a947a1acf720f859bb35c0c5ecb8dd7511995b67b9853298", - "transactionIndex": "0x0", - "blockHash": "0x156b88c3eb9a1244ba00a1834f3f70de735b39e3e59006dd03af4fe7d5480c11", - "blockNumber": "0x5", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "cumulativeGasUsed": "0xa9c4", - "gasUsed": "0xa9c4", - "contractAddress": null, - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0xa57e8e3981a6c861442e46c9471bd19cb3e21f9a8a6c63a72e7b5c47c6675a7c", - "transactionIndex": "0x0", - "blockHash": "0xcf61faca67dbb2c28952b0b8a379e53b1505ae0821e84779679390cb8571cadb", - "blockNumber": "0x6", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0x7c6b4bbe207d642d98d5c537142d85209e585087", - "cumulativeGasUsed": "0x66c5", - "gasUsed": "0x66c5", - "contractAddress": null, - "logs": [ - { - "address": "0x7c6b4bbe207d642d98d5c537142d85209e585087", - "topics": [ - "0x0b2e13ff20ac7b474198655583edf70dedd2c1dc980e329c4fbb2fc0748b796b" - ], - "data": "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000046865726500000000000000000000000000000000000000000000000000000000", - "blockHash": "0xcf61faca67dbb2c28952b0b8a379e53b1505ae0821e84779679390cb8571cadb", - "blockNumber": "0x6", - "transactionHash": "0xa57e8e3981a6c861442e46c9471bd19cb3e21f9a8a6c63a72e7b5c47c6675a7c", - "transactionIndex": "0x1", - "logIndex": "0x0", - "transactionLogIndex": "0x0", - "removed": false - } - ], - "status": "0x1", - "logsBloom": "0x00000000000800000000000000000010000000000000000000000000000180000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0x11fbb10230c168ca1e36a7e5c69a6dbcd04fd9e64ede39d10a83e36ee8065c16", - "transactionIndex": "0x0", - "blockHash": "0xf1e0ed2eda4e923626ec74621006ed50b3fc27580dc7b4cf68a07ca77420e29c", - "blockNumber": "0x7", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0x0000000000000000000000000000000000001337", - "cumulativeGasUsed": "0x5208", - "gasUsed": "0x5208", - "contractAddress": null, - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - } - ], - "libraries": [ - "src/Broadcast.t.sol:F:0x5fbdb2315678afecb367f032d93f642f64180aa3" - ], - "pending": [], - "path": "broadcast/Broadcast.t.sol/31337/run-latest.json", - "returns": {}, - "timestamp": 1655140035 -} diff --git a/lib/signals-implicit-mode/lib/forge-std/test/fixtures/config.toml b/lib/signals-implicit-mode/lib/forge-std/test/fixtures/config.toml deleted file mode 100644 index e6dcccca58..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/fixtures/config.toml +++ /dev/null @@ -1,81 +0,0 @@ -# ------------------------------------------------ -# EXAMPLE DEPLOYMENT CONFIG -# ------------------------------------------------ - -# -- MAINNET ------------------------------------- - -[mainnet] -endpoint_url = "${MAINNET_RPC}" - -[mainnet.bool] -is_live = true -bool_array = [true, false] - -[mainnet.address] -weth = "${WETH_MAINNET}" -deps = [ - "0x0000000000000000000000000000000000000000", - "0x1111111111111111111111111111111111111111", -] - -[mainnet.uint] -number = 1234 -number_array = [5678, 9999] - -[mainnet.int] -signed_number = -1234 -signed_number_array = [-5678, 9999] - -[mainnet.bytes32] -word = "0x00000000000000000000000000000000000000000000000000000000000004d2" # 1234 -word_array = [ - "0x000000000000000000000000000000000000000000000000000000000000162e", # 5678 - "0x000000000000000000000000000000000000000000000000000000000000270f", # 9999 -] - -[mainnet.bytes] -b = "0xabcd" -b_array = ["0xdead", "0xbeef"] - -[mainnet.string] -str = "foo" -str_array = ["bar", "baz"] - -# -- OPTIMISM ------------------------------------ - -[optimism] -endpoint_url = "${OPTIMISM_RPC}" - -[optimism.bool] -is_live = false -bool_array = [false, true] - -[optimism.address] -weth = "${WETH_OPTIMISM}" -deps = [ - "0x2222222222222222222222222222222222222222", - "0x3333333333333333333333333333333333333333", -] - -[optimism.uint] -number = 9999 -number_array = [1234, 5678] - -[optimism.int] -signed_number = 9999 -signed_number_array = [-1234, -5678] - -[optimism.bytes32] -word = "0x000000000000000000000000000000000000000000000000000000000000270f" # 9999 -word_array = [ - "0x00000000000000000000000000000000000000000000000000000000000004d2", # 1234 - "0x000000000000000000000000000000000000000000000000000000000000162e", # 5678 -] - -[optimism.bytes] -b = "0xdcba" -b_array = ["0xc0ffee", "0xbabe"] - -[optimism.string] -str = "alice" -str_array = ["bob", "charlie"] diff --git a/lib/signals-implicit-mode/lib/forge-std/test/fixtures/test.json b/lib/signals-implicit-mode/lib/forge-std/test/fixtures/test.json deleted file mode 100644 index caebf6d965..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/fixtures/test.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "a": 123, - "b": "test", - "c": { - "a": 123, - "b": "test" - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/forge-std/test/fixtures/test.toml b/lib/signals-implicit-mode/lib/forge-std/test/fixtures/test.toml deleted file mode 100644 index 60692bc750..0000000000 --- a/lib/signals-implicit-mode/lib/forge-std/test/fixtures/test.toml +++ /dev/null @@ -1,6 +0,0 @@ -a = 123 -b = "test" - -[c] -a = 123 -b = "test" diff --git a/lib/signals-implicit-mode/lib/sequence-v3/.env.sample b/lib/signals-implicit-mode/lib/sequence-v3/.env.sample deleted file mode 100644 index 323d6deba4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/.env.sample +++ /dev/null @@ -1,7 +0,0 @@ -PRIVATE_KEY= -ERC4337_ENTRY_POINT_V7=0x0000000071727De22E5E9d8BAf0edAc6f37da032 - -SEQ_SDK_RPC_URL_PREFIX="http://localhost:" -SEQ_SDK_RPC_URL_SUFFIX="/rpc" -SEQ_SDK_RPC_MIN_PORT=9999 -SEQ_SDK_RPC_MAX_PORT=9999 diff --git a/lib/signals-implicit-mode/lib/sequence-v3/.github/workflows/tests.yml b/lib/signals-implicit-mode/lib/sequence-v3/.github/workflows/tests.yml deleted file mode 100644 index 8c2a4a90ee..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/.github/workflows/tests.yml +++ /dev/null @@ -1,148 +0,0 @@ -name: Tests -concurrency: - group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.sha }} - cancel-in-progress: true - -on: - workflow_dispatch: - inputs: - sdk_type: - description: 'Type of test to run: go or typescript' - required: true - type: choice - options: - - go - - typescript - commit_hash: - description: 'Commit hash of the SDK to test against' - required: false - type: string - push: - branches: - - master - pull_request: - branches: - - master - -jobs: - test: - runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - include: - - name: Go SDK - sdk_type: go - repo_name: go-sequence - clone_url: https://github.com/0xsequence/go-sequence.git - repo_url: https://github.com/0xsequence/go-sequence.git - ssh_url: git@github.com:0xsequence/go-sequence.git - default_branch: v3-core - setup_tool: go - setup_version: '1.23' - build_cmd: go mod tidy && go build -o sequence-server ./cmd/sequence - server_cmd: ./sequence-server server & - - name: Typescript SDK - sdk_type: typescript - repo_name: sequence.js - clone_url: https://github.com/0xsequence/sequence.js.git - repo_url: https://github.com/0xsequence/sequence.js.git - ssh_url: git@github.com:0xsequence/sequence.js.git - default_branch: master - setup_tool: node - setup_version: '20' - build_cmd: npm install -g pnpm && pnpm install && pnpm run build:packages - server_cmd: pnpm dev:server & - - steps: - - name: Determine SDK Git Commit - id: determine_commit - run: | - if [ "${{ github.event_name }}" == "workflow_dispatch" ] && [ -n "${{ github.event.inputs.commit_hash }}" ]; then - echo "commit=${{ github.event.inputs.commit_hash }}" >> $GITHUB_OUTPUT - else - echo "commit=${{ matrix.default_branch }}" >> $GITHUB_OUTPUT - fi - - name: Checkout - uses: actions/checkout@v4 - - name: Clone SDK Repo - run: | - git clone ${{ matrix.clone_url }} sdk-repo - cd sdk-repo - git checkout ${{ steps.determine_commit.outputs.commit }} - cd .. - - name: Set Up Go Environment - if: ${{ matrix.setup_tool == 'go' }} - uses: actions/setup-go@v4 - with: - ${{ matrix.setup_tool }}-version: ${{ matrix.setup_version }} - - name: Set Up Node Environment - if: ${{ matrix.setup_tool == 'node' }} - uses: actions/setup-node@v4 - with: - node-version: ${{ matrix.setup_version }} - - name: Install Foundry - uses: foundry-rs/foundry-toolchain@v1 - - name: Install Foundry Dependencies - run: forge install - - name: Run Build Server - run: ${{ matrix.build_cmd }} - working-directory: sdk-repo - - name: Run Server - run: ${{ matrix.server_cmd }} - working-directory: sdk-repo - - name: Wait for Server - run: | - sleep 10 - curl -s http://localhost:9999/rpc -H "Content-type: application/json" -X POST -d '{"jsonrpc":"2.0","method":"eth_syncing","params":[],"id":1}' || (echo "Server not ready"; exit 1) - echo "Server is ready" - - name: Install Dependencies - run: forge install - - name: Run Tests - id: run_tests - continue-on-error: true - run: | - forge test --mp test/modules/BaseSig.t.sol - forge test --mp test/modules/Calls.t.sol - forge test --mp test/modules/Hooks.t.sol - forge test --mp test/modules/Implementation.t.sol - forge test --mp test/modules/Nonce.t.sol - forge test --mp test/modules/Payload.t.sol - forge test --mp test/Factory.t.sol - forge test --mp test/Guest.t.sol - forge test --mp test/Stage1Module.t.sol - forge test --mp test/Wallet.t.sol - env: - SEQ_SDK_RPC_URL_PREFIX: 'http://localhost:' - SEQ_SDK_RPC_URL_SUFFIX: '/rpc' - SEQ_SDK_RPC_MIN_PORT: '9999' - SEQ_SDK_RPC_MAX_PORT: '9999' - - name: Report Status - if: ${{ github.event_name != 'workflow_dispatch' }} - run: | - echo "status=${{ steps.run_tests.outcome == 'success' && 'success' || 'failure' }}" >> $GITHUB_OUTPUT - - name: Fail Job If Tests Fail - if: ${{ github.event_name != 'workflow_dispatch' && steps.run_tests.outcome == 'failure' }} - run: exit 1 - - name: Update Status - if: ${{ github.event_name == 'workflow_dispatch' }} - continue-on-error: true - uses: actions/github-script@v6 - with: - script: | - const { owner, repo } = context; - const publicOwner = '0xsequence'; - const publicRepo = ${{ matrix.repo_name }}; - const repoUrl = ${{ matrix.repo_url }} - const commitSha = '${{ github.event.inputs.commit_hash }}'; - const token = '${{ secrets.GITHUB_TOKEN }}'; - const octokit = new Octokit({ auth: token }); - const state = '${{ steps.run_tests.outcome == 'success' && 'success' || 'failure' }}'; - await octokit.rest.repos.createCommitStatus({ - owner: publicOwner, - repo: publicRepo, - sha: commitSha, - state: state, - target_url: repoUrl, - description: `The build was ${state}` - }); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/.gitmodules b/lib/signals-implicit-mode/lib/sequence-v3/.gitmodules deleted file mode 100644 index 9d59c56721..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/.gitmodules +++ /dev/null @@ -1,12 +0,0 @@ -[submodule "lib/openzeppelin-contracts"] - path = lib/openzeppelin-contracts - url = https://github.com/OpenZeppelin/openzeppelin-contracts -[submodule "lib/erc2470-libs"] - path = lib/erc2470-libs - url = https://github.com/ScreamingHawk/erc2470-libs -[submodule "lib/forge-std"] - path = lib/forge-std - url = https://github.com/foundry-rs/forge-std -[submodule "lib/account-abstraction"] - path = lib/account-abstraction - url = https://github.com/eth-infinitism/account-abstraction diff --git a/lib/signals-implicit-mode/lib/sequence-v3/.prettierignore b/lib/signals-implicit-mode/lib/sequence-v3/.prettierignore deleted file mode 100644 index f77cc09947..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/.prettierignore +++ /dev/null @@ -1,4 +0,0 @@ -node_modules -**/node_modules -lib -**/lib diff --git a/lib/signals-implicit-mode/lib/sequence-v3/.prettierrc b/lib/signals-implicit-mode/lib/sequence-v3/.prettierrc deleted file mode 100644 index 6fe562bd5b..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/.prettierrc +++ /dev/null @@ -1,7 +0,0 @@ -{ - "semi": false, - "singleQuote": true, - "tabWidth": 2, - "printWidth": 100, - "trailingComma": "es5" -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/LICENSE b/lib/signals-implicit-mode/lib/sequence-v3/LICENSE deleted file mode 100644 index 261eeb9e9f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/LICENSE +++ /dev/null @@ -1,201 +0,0 @@ - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/README.md b/lib/signals-implicit-mode/lib/sequence-v3/README.md deleted file mode 100644 index 6399141a1e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/README.md +++ /dev/null @@ -1,53 +0,0 @@ -# Sequence v3 wallet contracts - -Sequence v3 wallet contracts, with implicit and explicit smart sessions. - -## Development Setup - -Install dependencies - -```sh -pnpm install -``` - -Git hooks will be automatically installed. - -## Testing - -Install the [Sequence v3 SDK](https://github.com/0xsequence/sequence.js) and run a server using the following command: - -```sh -cd ../sequence.js -pnpm build:packages -pnpm dev:server -``` - -Copy the `env.sample` file to `.env` and set the environment variables. - -```sh -cp .env.sample .env -# Edit .env -``` - -Run tests - -```sh -forge test -``` - -Run coverage (ignoring scripts and test files). - -```sh -forge coverage --no-match-coverage "(script|test)" -# Or to generate and view in browser -forge coverage --no-match-coverage "(script|test)" --report lcov && genhtml -o report --branch-coverage lcov.info && py -m http.server -d report -``` - -Deploy contracts - -```sh -forge script Deploy --rpc-url --broadcast -``` - -> [!NOTE] -> Deployments use ERC-2470 for counter factual deployments. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/build_proxy.sh b/lib/signals-implicit-mode/lib/sequence-v3/build_proxy.sh deleted file mode 100644 index ce510d2b8f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/build_proxy.sh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/bash -SOL_VERSION="^0.8.0" -HUFF_FILE="./src/Wallet.huff" -SOL_OUT="./src/Wallet.sol" -BYTECODE=$(huff -z -e paris "$HUFF_FILE" CONSTRUCTOR | sed 's/^0x//') -HUFF_RAW=$(cat "$HUFF_FILE") -cat > "$SOL_OUT" < Threshold - -All signature parts must meet their respective thresholds. - -### Payload order - -1. The first signature recovers the given Payload. If its threshold is met, then it generates an `imageHash` which corresponds to the root of a Merkle tree that defines the configuration of the wallet. - -2. Following signatures recover the `imageHash` of the previous signature, bundled within a payload of the `KIND_CONFIG_UPDATE` kind. They, in turn, recover to their own next `imageHash`. - -3. After the last signature has been recovered, the resulting `imageHash` must match the one defined by the contract. - -``` -┌──────────────┐ ┌─────────────────────┐ ┌─────────────────────┐ -│Main payload │ │Config update payload│ │Config update payload│ -│(e.g. send tx)│ │ImageHash 1 │ │ImageHash 2 │ -└─────────────┬┘ └─▲──────────────────┬┘ └─▲──────────────────┬┘ - │ │ │ │ │ - Recover ──┤ │ Recover ──┤ │ Recover ──┤ - │ │ │ │ │ - ┌──────────▼┐ Generate │ ┌──────────▼┐ Generate │ ┌──────────▼┐ - │ImageHash 1├──────────┘ │ImageHash 2├──────────┘ │ImageHash 3│ - └───────────┘ └───────────┘ └─────┬─────┘ - │ - │ - │ - ╔═════▼═════╗ - ║ Is valid? ║ - ╚═══════════╝ -``` - -### Checkpoint - -Each wallet configuration defines a checkpoint, checkpoints define a strict order in which these configurations can be used **in the context of a chained signature**, this acts as a form of replay protection that blocks the usage of a previous section of the state channel **in case the state channel ever repeats configurations**. - -For example, a wallet has a configuration with signers `A & B`, then it is updated to `A, B & C` and then updated back again to `A & B`. Afterwards, another update is queued, this time to `A, B & D`. Without the checkpoints, a malicious actor (C) may exploit the first update (where `C` was added) even if the wallet already evicted `C` as a signer. - -``` - Checkpoint 2 -> 0 forbidden - ┌─────────────────────────────────────────────┐ - │ │ - x │ -┌───────────────┐ ┌─────────────────┐ ┌─────────────┴─┐ ┌─────────────────┐ -│Signers: A & B │ │Signers: A, B & C│ │Signers: A & B │ │Signers: A, B & D│ -│Checkpoint: 0 ├────▶│Checkpoint: 1 ├────▶│Checkpoint: 2 ├────▶│Checkpoint: 3 │ -└───────────────┘ └─────────────────┘ └───────────────┘ └─────────────────┘ -``` - -## **3. Checkpointer** - -The checkpointer is an optional interface that helps wallets keep track of the latest valid configuration without publishing every intermediate step to all chains. - -Because wallets exist on multiple chains, unused networks often lag behind and accumulate old states. The checkpointer solves this by announcing the last known valid configuration. Anything older is automatically considered invalid. - -Wallet contracts don't specify how the checkpointer works internally. Its only job is to clearly state the latest valid configuration to prevent older states from being reused. - -### Disabled checkpointer - -Even when a checkpointer is defined by the configuration, the checkpointer has the capability to "disable" itself. This is useful for implementing escape hatches like timelocks or challenge periods, in case that the checkpointer becomes unresponsive or malicious. When the checkpointer announces a snapshot with `imageHash == bytes32(0)` it is considered disabled. - -Notice that there is **no built in mechanism** to force the checkpointer to become disabled from within the wallet, any mechanism that may challenge and disable the checkpointer must be implemented on the checkpointer contract. - -### Checkpointer data - -When a checkpointer is defined by the configuration, obtaining the latest snapshot from it requires passing a generic `data` field to the checkpointer contract. This `data` field is provided within the signature, and it is entirely opaque to the wallet contract. - -It wouldn't make sense for the checkpointer to be able to provide the snapshot directly from contract storage, as this would move the requirement of having to settle the state channel from the wallet contract to the checkpointer contract, instead, it is expected that the checkpointer will use the `data` field to validate a proof of the snapshot. - -The proof may be implemented as a simple merkle proof, a signature from a trusted party or T.E.E., a zk proof from a keystore rollup, or any other mechanism that may allow the checkpointer to provide a valid snapshot. - -### Checkpointer scenarios - -Different scenarios exist depending on the current state of the wallet, state channel and checkpointer, and the relationship between them. - -#### 1. Full sync - -This happens when the wallet contract configuration is set to the latest configuration defined by the state channel, and the checkpointer reports the same configuration. - -This scenario does not require the usage of chained signatures, as regular signatures are sufficient when the configuration that is being used matches the one defined by the contract. - -``` - Checkpointer - ┌───────────────────────────────────────────────┐ - │ Wallet │ - │ ┌─────────────────────┐ │ - │ ┌──────────────┐ │ ┌──────────────┐ │ │ - │ │ Config A & B ├──────┼──▶ Config A & C │ │ │ - │ └──────┬───────┘ │ └──────────────┘ │ │ - │ │ └─────────────────────┘ │ - └────────┼──────────────────────────────────────┘ - │ - ▼ -Old state - Irrelevant -``` - -> Notice that even if no chained signatures are used, the checkpointer is still required to provide a valid snapshot of the latest configuration. - -#### 2. Checkpointer Ahead, Wallet Behind - -The state channel is ahead of the wallet contract, but the checkpointer knows about the latest configuration. In this scenario, the checkpointer provides a snapshot for the latest configuration, and the wallet **must** use a chained signature to sign the payload, using that latest configuration. - -``` - Checkpointer - ┌────────────────────────────────────────────────────────────────────┐ - │ Wallet │ - │ ┌─────────────────────┐ │ - │ ┌──────────────┐ │ ┌──────────────┐ │ ┌──────────────┐ │ - │ │ Config A & B ├──────┼──▶ Config A & C ├───┼─────▶ Config D & C │ │ - │ └──────┬───────┘ │ └──────────────┘ │ └───────┬──────┘ │ - │ │ └─────────────────────┘ │ │ - └────────┼──────────────────────────────────────────────────┼────────┘ - │ │ - ▼ ▼ -Old state - Irrelevant Latest state -``` - -#### 3. Checkpointer Behind, Wallet Synced - -The checkpointer is behind the wallet contract, and there are no pending configurations in the state channel. In this scenario, the checkpointer will provide a snapshot with a checkpoint that is behind the wallet contract, and this will make the wallet contract ignore the checkpointer's snapshot. - -This scenario may happen if the wallet is manually updated to a new configuration without notifying the checkpointer, or if the checkpointer hasn't had time to "react" and "catch up" with the wallet contract. It may be possible that the checkpointer is offline, and not reacting to any configuration changes. - -``` - Checkpointer Wallet - ┌──────────────────┐ ┌─────────────────────┐ - │ ┌──────────────┐ │ │ ┌──────────────┐ │ - │ │ Config A & B ├─┼────┼──▶ Config A & C │ │ - │ └──────┬───────┘ │ │ └──────────────┘ │ - └────────┼─────────┘ └─────────────────────┘ - │ - │ - ▼ -Old state - Irrelevant -``` - -#### 4. Wallet Behind, Checkpointer Further Behind - -The checkpointer is behind the wallet contract, and there are pending configurations in the state channel. This scenario is very similar to the previous one, the only difference is that the wallet will use a chained signature to sign the payload, using the latest configuration. - -Even if the wallet uses a chained signature, since the checkpointer's snapshot checkpoint is behind the wallet contract, the wallet will not use the checkpointer's snapshot. - -``` - Checkpointer Wallet - ┌──────────────────┐ ┌─────────────────────┐ - │ ┌──────────────┐ │ │ ┌──────────────┐ │ ┌──────────────┐ - │ │ Config A & B ├─┼────┼──▶ Config A & C ├───┼─────▶ Config B & C │ - │ └──────┬───────┘ │ │ └──────────────┘ │ └──────┬───────┘ - └────────┼─────────┘ └─────────────────────┘ │ - │ │ - │ │ - ▼ ▼ -Old state - Irrelevant Latest state -``` - -#### 5. Checkpointer Ahead, Wallet Behind, State Channel Further Ahead - -The state channel has multiple configuration updates, the checkpointer is ahead of the wallet contract, yet the state channel goes further than the checkpointer. This scenario may happen if the latest configuration update happened recently and the checkpointer hasn't updated yet. - -In this scenario, the checkpointer provides a snapshot, the wallet contract enforces a chained signature to sign the payload, forcing that the chained signature, at some point, goes over the checkpointer's snapshot. - -``` - Checkpointer - ┌────────────────────────────────────────────────────────────────────┐ - │ Wallet │ - │ ┌─────────────────────┐ │ - │ ┌──────────────┐ │ ┌──────────────┐ │ ┌──────────────┐ │ ┌──────────────┐ - │ │ Config A & B ├──────┼──▶ Config A & C ├───┼─────▶ Config D & C ├─┼───────▶ Config D & E │ - │ └──────┬───────┘ │ └──────────────┘ │ └──────────────┘ │ └──────┬───────┘ - │ │ └─────────────────────┘ │ │ - └────────┼───────────────────────────────────────────────────────────┘ │ - │ │ - ▼ ▼ -Old state - Irrelevant Latest state -``` - -#### 6. Wallet Synced, Checkpointer Dangling Ahead - -The checkpointer may report a future configuration that is not part of the state channel. This may happen if the checkpointer is misbehaving, malicious, or there is a state channel update that has only been revealed to the checkpointer. - -In this scenario, the checkpointer contract **must** provide with an escape hatch mechanism for either: - -1. Provide the link to the dangling configuration -2. Disable itself - -``` - Checkpointer - ┌────────────────────────────────────────────────────────────────────┐ - │ Wallet │ - │ ┌─────────────────────┐ │ - │ ┌──────────────┐ │ ┌──────────────┐ │ ┌──────────────┐ │ - │ │ Config A & B ├──────┼──▶ Config A & C ├───┼─x │ Config D & C │ │ - │ └──────┬───────┘ │ └───────┬──────┘ │ └───────┬──────┘ │ - │ │ └──────────┼──────────┘ │ │ - └────────┼─────────────────────────┼────────────────────────┼────────┘ - │ │ │ - ▼ ▼ ▼ -Old state - Irrelevant Latest state Dangling, not linked -``` - -### Checkpointer signature format - -Signatures that involve a checkpointer contain two additional pieces of data, the "checkpointer address" that is used to identify the checkpointer (and to be able to reconstruct the merkle root), and the "checkpointer data" which is needed to obtain the snapshot from the checkpointer. - -#### Non-chained signatures - -When non-chained signatures are used, the signature flag **must** have the `X1XX XXXX` bit set (`flag & 0x08 == 0x08`), this signals to the wallet contract that the signature involves a checkpointer, afterwards fixed 20 bytes are read to obtain the checkpointer address, and the next 3 bytes are read to obtain the checkpointer data size, after which the checkpointer data is read. - -``` - ┌───▶ 1 byte global flag - │ must have the 2nd bit - │ set to 1 to signal a chained ┌───▶ 3 bytes define the size - │ signature │ of the checkpointer data - │ │ -──┴─ ───┴── -0x40 6974206973207265616c6C792073756E6E791aDd 001271 6b656570206275696c64696e67... - ──┬───────────────────────────────────── ─┬─────────────────────────── - │ │ - └─▶ 20 byte address └─▶ Dynamic size checkpointer - determines the address data - of the checkpointer -``` - -#### Chained signatures - -If chained signatures are used, then the encoding becomes slightly more complex. The reason for this is that the **only** checkpointer that is used is the one that is defined by the wallet contract, **checkpointers provided by the state channel are ignored**. - -This is intended behavior, as the checkpointer is in charge of overseeing the state channel, thus it wouldn't be safe for the state channel to be able to provide a checkpointer, as it could self-authorize the state channel. This would negate the purpose of having a checkpointer in the first place. - -There is a challenge with this, when a chained signature is encoded, the configuration that corresponds to the wallet contract is provided **at the end of the chain**, which is a problem, because we need to obtain the snapshot at the beginning of the chain, in order to validate if the state channel ever "goes over" the snapshot provided by the checkpointer. - -Additionally, intermediary configurations need to have their checkpointers provided, as it is needed to reconstruct the merkle root. However no checkpointer data is needed, as these intermediate checkpointers are not called. - -To solve this, when a chained signature is used, and the onchain configuration contains a checkpointer, the checkpointer of the **last** configuration is moved at the beginning of the chain, alongside its checkpointer data, and no checkpointer data is provided for the intermediate signature parts. - -``` - ┌─▶ 2nd. bit signals checkpointer ┌──▶ The checkpointer and data is only - │ │ provided once, as part of the - │ ┌▶ 8th. bit signals chained │ chained signatures, and not of - ┴ ┴ │ the individual parts - 0100 0001 │ - ▲ ┌───────────────────────────────────┴─────────────────────────────────────────┐ - │ │ 3 byte Size │ - ──┴─│ ────── │ - 0x41│6974206973207265616c6C792073756E6E791aDd 001271 6b656570206275696c64696e67...│─┐ - │──────────────────────────────────────── ────────────────────────────────────│ │ - │Checkpointer address □ Checkpointer data │ │ - └─────────────────────╫───────────────────────────────────────────────────────┘ │ -╔═══════════════════════════╝ │ -║ ┌────────────────────────────────────────────────────────────────────────────────┘ -║ │ -║ │ Payload signature ┌─▶ No checkpointer data -║ │ ┌───────────────────────────────────────────┼───────────────────┐ -║ │ │ x │ -║ └───▶│44 6974206973207265616c6C792073756E6E791aDd 03 01 5151515151...│─┐ -║ │─┬───────────────────────────────────────── │ │ -║ └─┼─────────────────────────────────────────────────────────────┘ │ -║ │ │ -║ └───▶ Signature requires checkpointer │ -║ but no checkpointer data is │ -║ required as it is only for root │ -║ recovery │ -║ │ -║ Checkpointer may or may not match │ -║ │ -║ ┌──────────────────────────────────────────────────────┐ │ -║ ┌─────┤ Intermediary signatures follow the previous format ├─────────┘ -║ │ └──────────────────────────────────────────────────────┘ -║ │ -║ │ Final signature -║ │ ┌────────────────────────────────┐ -║ │ │ │ -║ └───▶│04 03 01 5252525252552525252... │ -║ │ x ───────────────────┬── │ -║ └──┼─────────────────────────┼───┘ -║ │ │ -║ └▶ No checkpointer │ -║ No checkpointer data └────▶ Regular signature body -║ -╚════════════▷ Recovery uses the checkpointer - that got at the start of the - chained signature -``` - -### Checkpointer control flow - -In summary, only the checkpointer that is defined by the wallet contract is used. If a non-chained signature is used, it has to either match the checkpointer's snapshot, or it must be behind the wallet contract. - -If a chained signature is used, then at some point during the chain, the snapshot provided by the checkpointer must match with one of the recovered configurations, this may also happen at the final signature. If this does not happen, the final signature (that corresponds to the wallet contract) **must** be ahead of the checkpointer's snapshot. - -``` - ╔═══════════════════╗ - ║ ║ - ║ Validation ║ - ║ start ║ - ║ ║ - ╚═════════╤═════════╝ - │ - │ - │ - ┌─────────▼─────────┐ - │ │ - │ Obtain snapshot │ - │ │ - │ │ - └─────────┬─────────┘ - │ - │ - │ - ╔═══════════════════╗ ╭─────────▼─────────╮ - ║ ║ │ Is snapshot │ - ║ Approved by ║ Yes│ equal to │ - ║ checkpointer ◀────────┤ bytes32(0)? │ - ║ ║ │ │ - ╚═══════════════════╝ ╰─────────┬─────────╯ - │No - │ - │ - ╭─────────▼─────────╮ - │ │ - │ Is chained │ Yes - │ signature? ├────────────────╮ - │ │ │ - ╰─────────┬─────────╯ │ - │No │ - │ │ - │ │ - ╔═══════════════════╗ ┌─────────▼─────────┐ │ - ║ ║ │ │ │ - ║ Rejected by ║ │ Recover │ │ - ║ checkpointer ║ │ image hash │ │ - ║ ║ │ │ │ - ╚═════════▲═════════╝ └─────────┬─────────┘ │ - │ │ │ - │ │ │ - │No │ │ - ╭─────────┴─────────╮ ╭─────────▼─────────╮ │ - │ │ │ │ │ - │ Checkpoint below │ No │ Matches │ │ - │ snapshot? ◀────────┤ snapshot? │ │ - │ │ │ │ │ - ╰─────────┬─────────╯ ╰─────────┬─────────╯ │ - │Yes │Yes │ - │ │ │ - │ │ │ - │ ╔═════════▼═════════╗ │ - │ ║ ║ │ - │ ║ Approved by ║ │ - └──────────────────▶ checkpointer ║ │ - ║ ║ │ - ╚═══════════════════╝ │ - │ - │ - │ - ┌───────────────▼───┐ - │ │ - │ Recover │ - ┌──────────────────▶ image hash │ - │ │ │ - │ └─────────┬─────────┘ - │ │ - │ │ - │No │ - ╭─────────┴─────────╮ ╭─────────▼─────────╮ - │ │ │ │ - Yes│ Was the last │ No │ Matches │ - ┌──────────────────┤ signature part? ◀────────┤ snapshot? │ - │ │ │ │ │ - │ ╰─────────▲─────────╯ ╰─────────┬─────────╯ - │ │ │Yes - │ │ │ - │ │ │ -╭─────────▼─────────╮ │ ┌─────────▼─────────┐ -│ │ │ │ │ -│ Was the snapshot │Yes │ │ Consume │ -│ consumed? ├─────────────┐ └──────────────────┤ snapshot │ -│ │ │ │ │ -╰─────────┬─────────╯ │ └───────────────────┘ - │No │ - │ │ - │ │ -╭─────────▼─────────╮ ╔════▼══════════════╗ -│ │ ║ ║ -│ Last checkpoint │Yes ║ Approved by ║ -│ below snapshot? ├────────▶ checkpointer ║ -│ │ ║ ║ -╰─────────┬─────────╯ ╚═══════════════════╝ - │No - │ - │ -╔═════════▼═════════╗ -║ ║ -║ Rejected by ║ -║ checkpointer ║ -║ ║ -╚═══════════════════╝ -``` diff --git a/lib/signals-implicit-mode/lib/sequence-v3/docs/CONFIGURATIONS.md b/lib/signals-implicit-mode/lib/sequence-v3/docs/CONFIGURATIONS.md deleted file mode 100644 index 8d0c7d5195..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/docs/CONFIGURATIONS.md +++ /dev/null @@ -1,279 +0,0 @@ -# Sequence chained signatures - -This document provides a description on how the Sequence wallet contracts define and handle sets of signers, checkpoints, extensions and other parameters that fall within the scope of its "configuration". - -## **1. Overview** - -All Sequence wallets have a defined "configuration", this is the set of parameters that governs the wallet's behavior. - -The configuration includes: - -- The threshold needed to authorize a transaction. -- The set of signers, and their corresponding weights. -- The current "checkpoint", which determines the order of configuration updates. -- Any "extensions" that are enabled, with their corresponding parameters. -- The "checkpointer" contract, which acts as a connector for a keystore rollup. -- Any pre-authorized transactions or messages, that are considered signed by the wallet. - -All these parameters are encoded into leaves of a merkle tree, of which the root is stored either as counter-factual information during wallet creation (as the salt of the `CREATE2` opcode), or directly within the contract storage; this "merkle root" is internally referred as the `imageHash` of the wallet. - -Since the wallet contract does not have direct access to the configuration, every time a signature is provided, the signature must provide both the "signature parts" that may be needed for the individual signers, as well as the "merkle proof" that allows the wallet contract to reconstruct the `imageHash` and thus validate the signature. - -## **2. Tree structure** - -The tree is a **sparse binary merkle tree**, this allows for more frequently accessed parameters to be stored closer to the root, making merkle proofs more efficient. Some elements like the `checkpointer`, `checkpoint` and `threshold` have fixed positions at the top of the tree, afterwards the other leaves can be arranged in any order. - -The top of the tree looks like: - -``` -imageHash = keccak256( - keccak256( - keccak256( - ...leaves, - threshold - ), - checkpoint - ), - checkpointer || address(0) -) -``` - -The `checkpointer` is optional, if it is not provided it still has to be included in the merkle tree, it will be automatically set to `address(0)` if the signature flags do not set the `CHECKPOINTER` bit. - -``` - ┌────────────────┐ - │ │ - │ Image hash │ - │ │ - └───▲────────▲───┘ - │ │ - ┌───┘ └────┐ - │ ┌──────────┼───────────┐ - ╭────┴───╮ │ ┌───────┴────────┐ │ - │ │ │ │ │ ├────▶ This section is - │ │ │ │ Checkpointer │ │ always in the tree. - │ │ │ │ │ │ - ╰─▲────▲─╯ │ └────────────────┘ │ It won't be shown - │ │ │ │ in the other diagrams. - │ └────┼──────────┐ │ - │ │ │ │ - ╭─┴──────╮ │ ┌───────┴────────┐ │ - │ │ │ │ │ │ - │ │ │ │ Checkpoint │ │ - │ │ │ │ │ │ - ╰─▲────▲─╯ │ └────────────────┘ │ - │ │ │ │ - │ └────┼──────────┐ │ - │ │ │ │ -╔═════════╧══════╗ │ ┌───────┴────────┐ │ -║ ... rest ║ │ │ │ │ -║ of the tree ║ │ │ Threshold │ │ -║ ║ │ │ │ │ -╚════════════════╝ │ └────────────────┘ │ - └──────────────────────┘ -``` - -## **3. Leaf types** - -### 3.1 Signer leaf - -Signer leaves are used to specify signer addresses, meaning that when a valid signature is provided, the wallet will count their weight towards the threshold. Signer leaves do not specify if they are ERC1271 signers or not, instead this is determined when the signature is encoded. - -``` - ┌────────────────┐ - │ │ - │ Image hash │ - │ │ - └───▲────────▲───┘ - │ │ - ┌───┘ └──────┐ - │ │ - ╭────┴───╮ ╔═════════╧═════════╗ - │ │ ║Checkpointer: 0x ║ - │ │ ║Checkpoint: 0 ║ - │ │ ║Threshold: 1 ║ - ╰─▲────▲─╯ ╚═══════════════════╝ - │ │ - ┌───────┘ └──────┐ - │ │ - │ │ -┌────────────────┐ ┌────────────────┐ -│ Signer 0xaaa │ │ Signer 0xbbb │ -│ Weight: 1 │ │ Weight: 1 │ -│ │ │ │ -└────────────────┘ └────────────────┘ -``` - -The hash of a signer leaf is computed as: - -``` -leaf = keccak256( - "Sequence signer:\n", - address, - weight -) -``` - -> Notice that any address that is registered **more than once** will be counted **multiple times** in the threshold. - -### 3.2 Hardcoded signature leaf - -Hardcoded signature leaves allow for the configuration to automatically sign a specific payload, this is useful for pre-approving transactions, for example pre-approving an approval for an ERC20 at the same time as the wallet is created. - -If a payload hash matches the hardcoded hash (subdigest), the weight counted towards the threshold will automatically be bumped to `type(uint256).max`, ensuring the signature to be valid. - -``` - ┌────────────────┐ - │ │ - │ Image hash │ - │ │ - └───▲────────▲───┘ - │ │ - ┌───────┘ └────────┐ - │ │ -┌───────┴────────┐ ╔═════════╧═════════╗ -│ Subdigest: │ ║Checkpointer: 0x ║ -│ 0x11223344 │ ║Checkpoint: 0 ║ -│ │ ║Threshold: 1 ║ -└────────────────┘ ╚═══════════════════╝ -``` - -The hash of a hardcoded signature leaf is computed as: - -``` -leaf = keccak256( - "Sequence static digest:\n", - subdigest -) -``` - -### 3.3 Any address hardcoded signature leaf - -This works very similarly to the hardcoded signature leaf, but the hash of the payload is computed setting its ERC712 domain separator to `address(0)` instead of the wallet's address. - -This allows for pre-approving transactions before the wallet has counterfactually been defined, otherwise attempting to compute the hash would require the wallet's address to be known beforehand, and determining the address would require the hash to be known beforehand, causing a recursive dependency. - -After a wallet is created, it is recommended to use the hardcoded signature leaf instead, as it is more efficient. - -The hash of an any address hardcoded signature leaf is computed as: - -``` -leaf = keccak256( - "Sequence any address subdigest:\n", - subdigest -) -``` - -### 3.4 Nested configuration leaf - -Nested configuration leaves are used to specify nested configuration trees, this allows for certain sets of signers to be grouped in such a way that their signing power is limited by a threshold. It can also allow to augment the signing power of a set of signers, by making them have no signing power individually but still be able to sign as a group. - -They have their own internal thresholds, internally they work exactly as the parent "main" tree, but externally they can only contribute their own weight. - -``` - ┌────────────────┐ - │ │ - │ Image hash │ - │ │ - └───▲────────▲───┘ - │ │ - ┌───┘ └──────┐ - │ │ - ╭────┴───╮ ╔═════════╧═════════╗ - │ │ ║ Checkpointer: 0x ║ - │ │ ║ Checkpoint: 0 ║ - │ │ ║ Threshold: 2 ║ - ╰─▲────▲─╯ ╚═══════════════════╝ - │ │ - ┌──────┘ └──────┐ - │ │ ────┐ -┌──────────┴─────┐ ┌─────┴──────────┐ │ -│ Signer 0xaaa │ │ Threshold: 1 │ ├─▶ The maximum weight -│ Weight: 1 │ │ Weight: 1 │ │ of 0xbbb and 0xccc -│ │ │ │ │ can't exceed 1 -└────────────────┘ └─────▲────▲─────┘ │ - │ │ │ Forced either of - ┌──────┘ └──────┐ │ them to be combined - │ │ │ with 0xaaa - ┌──────────┴─────┐ ┌─────┴──────────┐ │ - │ Signer: 0xbbb │ │ Signer 0xccc │ │ - │ Weight: 1 │ │ Weight: 2 │ │ - │ │ │ │ │ - └────────────────┘ └────────────────┘ │ - ────┘ -``` - -The hash of a nested tree is computed as: - -``` -leaf = keccak256( - "Sequence nested config:\n", - node, - threshold, - weight -) -``` - -### 3.5 Sapient Signer Leaf - -Sapient signer leaves work similarly to Signer leaves, but have 3 key distinctions: - -1. Sapient signers **must** always be smart contracts, EOA signers are not allowed -2. Sapient signers **do not** use the ERC1271 interface, instead they get passed a fully decoded `Payload` to sign -3. Sapient signatures are not validated, they are **recovered** into a hash - -When a sapient signer leaf is added to a configuration, it must define its `address`, `weight` and `imageHash`. The `imageHash` represents the expected value that the sapient signer **must recover** for the signature to be valid. - -This allows sapient signers to act as **extensions** of the configuration tree, they can define their own leaf types and overall structures, alongside arbitrary logic. This allows for extensions to be configured per wallet without having to rely on the contract storage of the extension, as the definition of the configuration resides in the same `imageHash`. - -``` - ┌────────────────┐ - │ │ - │ Image hash │ - │ │ - └───▲────────▲───┘ - │ │ - ┌───┘ └──────┐ - │ │ - ╭────┴───╮ ╔═════════╧═════════╗ - │ │ ║ Checkpointer: 0x ║ - │ │ ║ Checkpoint: 0 ║ - │ │ ║ Threshold: 2 ║ - ╰─▲────▲─╯ ╚═══════════════════╝ - │ │ - ┌──────┘ └──────┐ - │ │ ────┐ - ┌──────────┴─────┐ ┌─────┴──────────┐ ├─▶ The passkey sapient - │ Signer 0xaaa │ │ Passkey │ │ signer uses its tree - │ Weight: 1 │ │ weight: 1 │ │ to define public - │ │ │imageHash: 0xabc│ │ keys and - └────────────────┘ └─────▲────▲─────┘ │ configuration - │ │ │ parameters. - ┌───────────────┘ └───────────────┐ │ - │ │ │ Signatures must be - ╭─────┴──╮ ╭──┴─────╮ │ able to recover the - │ │ │ │ │ inner root of the - │ │ │ │ │ tree to be - │ │ │ │ │ considered valid. - ╰─▲────▲─╯ ╰─▲────▲─╯ │ - │ │ │ │ │ - ┌──────┘ └──────┐ ┌──────┘ └──────┐ │ - │ │ │ │ │ -┌────────┴───────┐ ┌───────┴────────┐ ┌────────┴───────┐ ┌───────┴────────┐ │ -│ │ │ │ │ Require user │ │ │ │ -│ Pubkey X │ │ Pubkey Y │ │ verification │ │ Metadata │ │ -│ │ │ │ │ true/false │ │ │ │ -└────────────────┘ └────────────────┘ └────────────────┘ └────────────────┘ │ - ────┘ -``` - -The hash of a sapient signer leaf is: - -``` -leaf = keccak256( - "Sequence sapient config:\n", - address, - weight, - imageHash -) -``` diff --git a/lib/signals-implicit-mode/lib/sequence-v3/docs/PAYLOAD.md b/lib/signals-implicit-mode/lib/sequence-v3/docs/PAYLOAD.md deleted file mode 100644 index 61d71e55f0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/docs/PAYLOAD.md +++ /dev/null @@ -1,392 +0,0 @@ -# Sequence Payload System Documentation - -This document provides a comprehensive overview of how the Sequence wallet contracts encode, decode, and execute payloads. It explains the payload structure, encoding schemes, execution flow, and how payloads integrate with the broader signature and configuration systems. - ---- - -## **1. Overview** - -The Sequence payload system is the core mechanism through which wallets execute batched operations. Payloads are encoded data structures that contain: - -- **Transaction calls** with target addresses, values, and calldata -- **Configuration updates** for wallet parameters -- **Message validations** for arbitrary data signing -- **Digest verifications** for ERC-1271 compatibility - -Payloads are designed to be: - -1. **Gas-efficient** through compact binary encoding -2. **Flexible** to support various operation types -3. **Secure** through EIP-712 structured hashing -4. **Batchable** to execute multiple operations atomically - ---- - -## **2. Payload Types** - -The system supports four distinct payload kinds, each serving different purposes: - -### **2.1 Transaction Payloads (`KIND_TRANSACTIONS = 0x00`)** - -Transaction payloads contain batched calls to external contracts or self-execution logic. These are the most common payload type and support: - -- Multiple contract calls in sequence -- Value transfers with calls -- Delegate calls for extension execution -- Gas limit specifications -- Error handling behaviors -- Fallback-only execution modes - -### **2.2 Message Payloads (`KIND_MESSAGE = 0x01`)** - -Message payloads allow wallets to sign arbitrary data for off-chain verification. This is useful for: - -- Meta-transactions -- Off-chain authorization -- Cross-chain message signing -- General-purpose data signing - -### **2.3 Configuration Update Payloads (`KIND_CONFIG_UPDATE = 0x02`)** - -Configuration update payloads enable wallet reconfiguration through: - -- Signer set modifications -- Threshold adjustments -- Extension enablement/disablement -- Checkpoint updates - -### **2.4 Digest Payloads (`KIND_DIGEST = 0x03`)** - -Digest payloads provide ERC-1271 compatibility by allowing wallets to validate pre-computed message hashes. - ---- - -## **3. Payload Structure** - -### **3.1 Core Payload Structure** - -All payloads share a common structure defined by the `Decoded` struct: - -```solidity -struct Decoded { - uint8 kind; // Payload type identifier - bool noChainId; // Chain ID inclusion flag - // Transaction-specific fields - Call[] calls; // Array of call operations - uint256 space; // Nonce space identifier - uint256 nonce; // Nonce value for replay protection - // Message-specific fields - bytes message; // Raw message data - // Configuration-specific fields - bytes32 imageHash; // New configuration hash - // Digest-specific fields - bytes32 digest; // Pre-computed message hash - // Common fields - address[] parentWallets; // Parent wallet addresses -} -``` - -### **3.2 Call Structure** - -Individual calls within transaction payloads are defined by the `Call` struct: - -```solidity -struct Call { - address to; // Target contract address - uint256 value; // ETH value to send - bytes data; // Calldata for the call - uint256 gasLimit; // Gas limit for execution - bool delegateCall; // Delegate call flag - bool onlyFallback; // Fallback-only execution - uint256 behaviorOnError; // Error handling strategy -} -``` - ---- - -## **4. Payload Encoding** - -### **4.1 Transaction Payload Encoding** - -Transaction payloads use a compact binary encoding scheme optimized for gas efficiency. The encoding follows this structure: - -``` -┌─────────────────────────────────────────────────────────────────────────────┐ -│ Global Flag (1 byte) │ -│ ┌─────────────────────────────────────────────────────────────────────────┐ │ -│ │ Bit 0: Space flag (0 = read space, 1 = space is 0) │ │ -│ │ Bits 1-3: Nonce size (0-7 bytes) │ │ -│ │ Bit 4: Single call flag (0 = multiple calls, 1 = single call) │ │ -│ │ Bit 5: Call count size (0 = 1 byte, 1 = 2 bytes) │ │ -│ │ Bits 6-7: Reserved │ │ -│ └─────────────────────────────────────────────────────────────────────────┘ │ -├─────────────────────────────────────────────────────────────────────────────┤ -│ Space (0 or 20 bytes) - only if space flag is 0 │ -├─────────────────────────────────────────────────────────────────────────────┤ -│ Nonce (0-7 bytes) - size determined by bits 1-3 │ -├─────────────────────────────────────────────────────────────────────────────┤ -│ Call Count (1-2 bytes) - size determined by bit 5 │ -├─────────────────────────────────────────────────────────────────────────────┤ -│ Call Array (call count length) │ -│ ┌─────────────────────────────────────────────────────────────────────────┐ │ -│ │ Call Flags (1 byte) │ │ -│ │ ┌─────────────────────────────────────────────────────────────────────┐ │ │ -│ │ │ Bit 0: Self-call flag (0 = external, 1 = self) │ │ │ -│ │ │ Bit 1: Value flag (0 = no value, 1 = has value) │ │ │ -│ │ │ Bit 2: Data flag (0 = no data, 1 = has data) │ │ │ -│ │ │ Bit 3: Gas limit flag (0 = no limit, 1 = has limit) │ │ │ -│ │ │ Bit 4: Delegate call flag │ │ │ -│ │ │ Bit 5: Fallback-only flag │ │ │ -│ │ │ Bits 6-7: Behavior on error (00=ignore, 01=revert, 10=abort) │ │ │ -│ │ └─────────────────────────────────────────────────────────────────────┘ │ │ -│ ├─────────────────────────────────────────────────────────────────────────┤ │ -│ │ Target Address (0 or 20 bytes) - only if not self-call │ │ -│ ├─────────────────────────────────────────────────────────────────────────┤ │ -│ │ Value (0 or 32 bytes) - only if value flag is set │ │ -│ ├─────────────────────────────────────────────────────────────────────────┤ │ -│ │ Data Size (0 or 3 bytes) - only if data flag is set │ │ -│ ├─────────────────────────────────────────────────────────────────────────┤ │ -│ │ Data (0 or N bytes) - only if data flag is set │ │ -│ ├─────────────────────────────────────────────────────────────────────────┤ │ -│ │ Gas Limit (0 or 32 bytes) - only if gas limit flag is set │ │ -│ └─────────────────────────────────────────────────────────────────────────┘ │ -└─────────────────────────────────────────────────────────────────────────────┘ -``` - -### **4.2 Global Flag Breakdown** - -The global flag byte controls the overall payload structure: - -``` -Global Flag: [7][6][5][4][3][2][1][0] - │ │ │ │ │ │ │ └── [0] Space flag - │ │ │ │ │ │ └───── [1][0] Nonce size - │ │ │ │ │ └──────── [2][1] Nonce size - │ │ │ │ └─────────── [3][2] Nonce size - │ │ │ └────────────── [4] Single call flag - │ │ └───────────────── [5] Call count size - │ └──────────────────── [6] Reserved - └─────────────────────── [7] Reserved -``` - -**Space Flag (Bit 0):** - -- `0`: Read 20-byte space address from payload -- `1`: Set space to 0 (default space) - -**Nonce Size (Bits 1-3):** - -- `000`: No nonce (nonce = 0) -- `001`: 1-byte nonce -- `010`: 2-byte nonce -- `011`: 3-byte nonce -- `100`: 4-byte nonce -- `101`: 5-byte nonce -- `110`: 6-byte nonce -- `111`: 7-byte nonce - -**Single Call Flag (Bit 4):** - -- `0`: Multiple calls (read call count) -- `1`: Single call (call count = 1) - -**Call Count Size (Bit 5):** - -- `0`: Call count stored in 1 byte -- `1`: Call count stored in 2 bytes - -### **4.3 Call Flags Breakdown** - -Each call begins with a flags byte that controls its execution parameters: - -``` -Call Flags: [7][6][5][4][3][2][1][0] - │ │ │ │ │ │ │ └─── [0] Self-call flag - │ │ │ │ │ │ └────── [1] Value flag - │ │ │ │ │ └───────── [2] Data flag - │ │ │ │ └──────────── [3] Gas limit flag - │ │ │ └─────────────── [4] Delegate call flag - │ │ └────────────────── [5] Fallback-only flag - │ └───────────────────── [6][0] Behavior on error - └──────────────────────── [7][1] Behavior on error -``` - -**Self-call Flag (Bit 0):** - -- `0`: External call (read target address) -- `1`: Self-call (target = address(this)) - -**Value Flag (Bit 1):** - -- `0`: No ETH value -- `1`: Read 32-byte value from payload - -**Data Flag (Bit 2):** - -- `0`: No calldata -- `1`: Read 3-byte data size + N bytes of data - -**Gas Limit Flag (Bit 3):** - -- `0`: Use remaining gas -- `1`: Read 32-byte gas limit from payload - -**Delegate Call Flag (Bit 4):** - -- `0`: Regular call -- `1`: Delegate call - -**Fallback-only Flag (Bit 5):** - -- `0`: Execute normally -- `1`: Only execute if previous call failed - -**Behavior on Error (Bits 6-7):** - -- `00`: Ignore error, continue execution -- `01`: Revert entire transaction -- `10`: Abort execution, stop processing -- `11`: Reserved - ---- - -## **5. Payload Execution** - -### **5.1 Execution Flow** - -The payload execution follows this sequence: - -1. **Decode Payload**: Parse the binary payload into structured data -2. **Nonce Validation**: Consume the nonce to prevent replay attacks -3. **Signature Verification**: Validate the signature against the payload -4. **Call Execution**: Execute each call in sequence -5. **Error Handling**: Apply error handling based on call configuration - -### **5.2 Call Execution Modes** - -#### **Regular Calls** - -Standard contract calls that execute with the specified parameters and return control to the wallet. - -#### **Delegate Calls** - -Execute code in the context of the wallet contract, allowing extensions to modify wallet state. - -#### **Fallback-only Calls** - -Only execute when the immediately preceding call fails (and has the `BEHAVIOR_IGNORE_ERROR` behavior), enabling conditional execution flows. See Error Handling Strategies below. - -### **5.3 Error Handling Strategies** - -The system provides three error handling behaviors: - -1. **Ignore Error (`BEHAVIOR_IGNORE_ERROR`)** - - Continue execution with subsequent calls - - Set error flag for fallback-only calls - - Emit `CallFailed` event - -2. **Revert on Error (`BEHAVIOR_REVERT_ON_ERROR`)** - - Revert entire transaction - - Rollback all state changes - - Emit `Reverted` error - -3. **Abort on Error (`BEHAVIOR_ABORT_ON_ERROR`)** - - Stop processing remaining calls - - Keep successful call results - - Emit `CallAborted` event - ---- - -## **6. EIP-712 Integration** - -### **6.1 Domain Separator** - -Payloads use EIP-712 for structured hashing with the domain: - -``` -EIP712Domain( - name: "Sequence Wallet" - version: "3" - chainId: block.chainid (or 0 if noChainId) - verifyingContract: wallet address -) -``` - -### **6.2 Type Hashes** - -Each payload type has a specific type hash: - -- **Calls**: `keccak256("Calls(Call[] calls,uint256 space,uint256 nonce,address[] wallets)")` -- **Message**: `keccak256("Message(bytes message,address[] wallets)")` -- **ConfigUpdate**: `keccak256("ConfigUpdate(bytes32 imageHash,address[] wallets)")` - -### **6.3 Call Hashing** - -Individual calls are hashed using: - -``` -keccak256( - CALL_TYPEHASH, - to, - value, - keccak256(data), - gasLimit, - delegateCall, - onlyFallback, - behaviorOnError -) -``` - ---- - -## **7. Gas Optimization Features** - -### **7.1 Compact Encoding** - -The payload system uses several techniques to minimize gas costs: - -- **Flag-based encoding**: Single bytes control multiple parameters -- **Variable-length fields**: Only encode necessary data -- **Self-call optimization**: Avoid 20-byte address encoding for self-calls -- **Conditional encoding**: Skip fields that have default values - -### **7.2 Batch Processing** - -Multiple calls can be executed in a single transaction, reducing: - -- Transaction overhead -- Gas costs for multiple operations -- Network congestion -- User interaction requirements - ---- - -## **8. Security Considerations** - -### **8.1 Replay Protection** - -- **Nonce system**: Each payload requires a unique nonce -- **Space isolation**: Different nonce spaces prevent cross-contamination -- **Chain ID binding**: Prevents cross-chain replay attacks - -### **8.2 Access Control** - -- **Signature validation**: All payloads require valid signatures -- **Configuration binding**: Payloads are tied to specific wallet configurations -- **Extension isolation**: Delegate calls are restricted to approved extensions - -### **8.3 Error Handling** - -- **Graceful degradation**: Failed calls don't necessarily fail the entire batch -- **Gas protection**: Individual gas limits prevent infinite loops -- **State consistency**: Error behaviors maintain wallet integrity - ---- - -## **Conclusion** - -The Sequence payload system provides a powerful, gas-efficient mechanism for executing complex wallet operations. Through its compact binary encoding, flexible call structures, and comprehensive error handling, it enables wallets to perform sophisticated multi-step operations while maintaining security and efficiency. - -The system's integration with the broader Sequence ecosystem—including chained signatures, smart sessions, and configuration management—creates a cohesive framework for advanced wallet functionality. The payload system serves as the execution engine that brings together all these components into a unified user experience. - -This documentation serves as a technical reference for developers implementing and extending the payload system, providing both high-level architectural understanding and detailed implementation guidance. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/docs/SESSIONS.md b/lib/signals-implicit-mode/lib/sequence-v3/docs/SESSIONS.md deleted file mode 100644 index b764bd190a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/docs/SESSIONS.md +++ /dev/null @@ -1,502 +0,0 @@ -# Ecosystem Wallets Smart Sessions Documentation - -This document provides an in-depth overview of the smart sessions system in Ecosystem wallets. It explains the encoding of signatures and configurations, details the permissions system, and distinguishes between explicit sessions and implicit sessions. - ---- - -## Overview - -Ecosystem wallets smart sessions enable batched call authorization via signed payloads. Two primary session modes are supported: - -- **Explicit Sessions:** - Explicit sessions are part of the wallet's configuration. Their permissions are granted counter factually - derived from signature calldata. These permissions can be added or removed with a configuration update. As the configuration is tied to the wallet's image hash, any change to the wallet (and thus its image hash) immediately affects which explicit session permissions remain valid. - -- **Implicit Sessions:** - Implicit sessions are automatically able to sign on behalf of the wallet when they present an attestation that is signed by the wallet's identity signer. This mode leverages off-chain attestations and enforces additional constraints (e.g., blacklisting) to protect against misuse. - ---- - -## Signature Encoding - -Signature encoding consists of **three** main parts: - -1. **Session Configuration Encoding** -2. **Attestation List Encoding** -3. **Call Signatures Encoding** - -Each part uses a specific layout and bit-level structure to efficiently encode the required data. - ---- - -### 1. Session Configuration Encoding - -The session configuration is embedded within the signature as follows: - -``` -┌─────────────────────────────────────────────────────┐ -│ uint24 dataSize │ -│ ┌───────────────────────────────────────────────┐ │ -│ │ Session Configuration Bytes (dataSize bytes) │ │ -│ └───────────────────────────────────────────────┘ │ -└─────────────────────────────────────────────────────┘ -``` - -Within these configuration bytes, the data is structured as a series of tagged nodes. Each node begins with a flag byte that indicates the node type and any associated metadata. - -#### Flag Byte Structure - -``` - ┌───────────────────────────────┐ - │ Bits 7..4: FLAG │ (Identifies the node type) - │ Bits 3..0: Additional Data │ (Depends on the FLAG) - └───────────────────────────────┘ -``` - -The following flags are defined: - -- **0x00: Permissions Node** -- **0x01: Node (Pre-hashed 32-byte value)** -- **0x02: Branch (Nested encoding)** -- **0x03: Blacklist** -- **0x04: Identity Signer** - -> [!IMPORTANT] -> There must be exactly **one** Identity Signer and at most one Blacklist node. Multiple entries will trigger a validation error. If there are any implicit sessions (attestations), a blacklist is mandatory. - -#### Permissions Node (FLAG 0x00) - -This node encodes session permissions for a specific signer: - -``` -Permissions Node Layout: - ┌─────────────────────────────────────────────┐ - │ Flag Byte │ - │ ┌────────────────────────┐ │ - │ │ Bits 7..4: FLAG (0x00) │ │ - │ │ Bits 3..0: Unused │ │ - │ └────────────────────────┘ │ - │ Signer (address) │ - │ Value Limit (uint256) │ - │ Deadline (uint256) │ - │ Permissions Array (encoded permissions) │ - └─────────────────────────────────────────────┘ -``` - -##### Permission Object Encoding - -Each permission object is structured as follows: - -``` -Permission Encoding: - ┌─────────────────────────────┐ - │ Target Address │ - │ Rules Count (uint8) │ - │ ┌─────────────────────────┐ │ - │ │ Parameter Rule 1 │ │ - │ │ Parameter Rule 2 │ │ ... (if any) - │ └─────────────────────────┘ │ - └─────────────────────────────┘ -``` - -If the **Rules Count** is zero, the permission is considered _open_, allowing any call that targets the specified address without additional parameter restrictions. - -##### Parameter Rule Encoding - -Each parameter rule enforces conditions on the call data: - -``` -Parameter Rule Encoding: - ┌──────────────────────────────────────────────────────────────┐ - │ Operation & Cumulative Flag (1 byte) │ - │ ┌────────────────────────────────────────────────────────┐ │ - │ │ Bits 7..1 (0xFE): Operation (e.g., 0 = EQUAL, etc.) │ │ - │ │ Bit 0 (0x01): Cumulative flag (1 = cumulative) │ │ - │ └────────────────────────────────────────────────────────┘ │ - │ Value (bytes32) │ - │ Offset (uint256) │ - │ Mask (bytes32) │ - └──────────────────────────────────────────────────────────────┘ -``` - -> [!TIP] -> A permission with an empty rules array is treated as _open_, granting unrestricted access to the target, subject only to other constraints such as value limits and deadlines. - -#### Node (FLAG 0x01) - -This node includes a 32-byte pre-hashed value: - -``` -Node Layout: - ┌──────────────────────────────┐ - │ Flag Byte │ - │ ┌────────────────────────┐ │ - │ │ Bits 7..4: FLAG (0x01) │ │ - │ │ Bits 3..0: Unused │ │ - │ └────────────────────────┘ │ - │ Node Hash (bytes32) │ - └──────────────────────────────┘ -``` - -This node is an optimization to reduce the size of the configuration tree in calldata. By using this node, unused permissions or configuration segments can be hidden, while still allowing the complete image hash to be derived. - -#### Branch (FLAG 0x02) - -Branches allow for the recursive grouping of nested configuration nodes into a single unit. They are used to bundle together multiple nodes - such as several permissions nodes or even other branch nodes - so that the entire collection can be processed as one entity. This design minimizes redundancy and optimizes the calldata size by avoiding repeated encoding of common structures. - -``` -Branch Node Layout: - ┌──────────────────────────────────────────────┐ - │ Flag Byte │ - │ ┌────────────────────────────────────────┐ │ - │ │ Bits 7..4: FLAG (0x02) │ │ - │ │ Bits 3..0: Size of size field in bytes │ │ - │ └────────────────────────────────────────┘ │ - │ Size (uintX, where X is determined above) │ - │ Branch Data (nested configuration bytes) │ - └──────────────────────────────────────────────┘ -``` - -The **Size** field specifies the total number of bytes that the branch occupies. The size of this field is determined by the additional data portion of the flag byte (bits 3..0), which indicates how many bytes are used to encode the size. The branch data that follows can include a mix of permissions nodes, pre-hashed nodes, blacklists, and even other branches. When processing a branch: - -- The branch data is parsed recursively, with each nested node being processed according to its own flag. -- The leaf hashes of all nested nodes are computed. -- These individual hashes are then combined (e.g., using `LibOptim.fkeccak256`) to produce a single cumulative hash representing the entire branch. -- This branch hash is then integrated into the parent configuration's image hash, ensuring that all the nested information contributes to the final cryptographic fingerprint. - -> [!TIP] -> Branch nodes are especially useful for modularizing the configuration structure. They allow logically related nodes to be grouped together, which not only improves organization but also potentially reduces the overall size of the calldata by allowing unused leaves to be rolled up into a single node. - -#### Blacklist (FLAG 0x03) - -The blacklist node specifies addresses that are disallowed for implicit sessions. This includes both target addresses that cannot be called and session signers that are not allowed to make implicit calls. - -``` -Blacklist Node Layout: - ┌──────────────────────────────────────────────┐ - │ Flag Byte │ - │ ┌────────────────────────────────────────┐ │ - │ │ Bits 7..4: FLAG (0x03) │ │ - │ │ Bits 3..0: Blacklist count or 0x0F │ │ - │ └────────────────────────────────────────┘ │ - │ [Optional] Extended Count (uint16) │ - │ Blacklisted Addresses (sorted array) │ - └──────────────────────────────────────────────┘ -``` - -The blacklist count is encoded in the additional data portion of the flag byte (bits 3..0): - -- If the count is 14 or less, it is stored directly in these bits -- If the count is 15 or more, these bits are set to 0x0F and the actual count is stored in the next 2 bytes as a uint16 - -The blacklist serves two security purposes: - -1. Prevents implicit sessions from calling specific target addresses -2. Blocks specific session signers from making any implicit calls - -When an implicit session call is made, both the session signer and the target address are checked against the blacklist. If either appears in the blacklist, the call will be rejected with a `BlacklistedAddress` error. - -> [!IMPORTANT] -> For implicit sessions, the blacklist is mandatory. The blacklist addresses must be sorted or validation will fail. This is to allow a binary search during validation. - -> [!WARNING] -> The blacklist doesn't not prevent explicit sessions from calling blacklisted addresses or prevent explicit signers. To block an explicit session or it's permissions, update the wallet configuration to remove the explicit session. - -#### Identity Signer (FLAG 0x04) - -Specifies the identity signer used for attestation verification: - -``` -Identity Signer Layout: - ┌──────────────────────────────┐ - │ Flag Byte │ - │ ┌────────────────────────┐ │ - │ │ Bits 7..4: FLAG (0x04) │ │ - │ │ Bits 3..0: Unused │ │ - │ └────────────────────────┘ │ - │ Identity Signer (address) │ - └──────────────────────────────┘ -``` - -> [!IMPORTANT] -> The configuration must include exactly one identity signer. Duplicate or missing entries trigger an error. - ---- - -### 2. Attestation List Encoding - -After reading the session configuration, a single byte `attestationCount` indicates how many attestations follow: - -``` -┌─────────────────────────────────────────────────────┐ -│ uint8 attestationCount │ -│ ┌────────────────────────────────────────────────┐ │ -│ │ Attestation + identity signature │ │ -│ │ ... repeated attestationCount times ... │ │ -│ └────────────────────────────────────────────────┘ │ -└─────────────────────────────────────────────────────┘ -``` - -Each attestation is encoded as described in [Attestation (Implicit Sessions)](#attestation-implicit-sessions) below, then followed by a single identity signature from the configured identity signer (in EIP-2098 compact form). - -If `attestationCount > 0` but no blacklist node was present in the configuration, validation fails. - ---- - -### 3. Call Signatures Encoding - -Each call in the payload is accompanied by a call signature. The encoding differs slightly for explicit sessions and implicit sessions. - -#### Call Signature Structure - -``` -Call Signature Layout: - ┌─────────────────────────────────────────────────────────────┐ - │ Flag Byte │ - │ ┌────────────────────────────────────────────────────────┐│ - │ │ Bit 7 (0x80): isImplicit flag ││ - │ │ Bits 6..0 (0x7F): If implicit, this is the attestation ││ - │ │ index; if explicit, this is the ││ - │ │ session permission index ││ - │ └────────────────────────────────────────────────────────┘│ - │ Session Signature (EIP-2098 compact: see below) │ - └─────────────────────────────────────────────────────────────┘ -``` - -> [!IMPORTANT] -> The flag byte is critical for distinguishing call types. For implicit sessions, the most significant bit (Bit 7) must be set. For explicit sessions, the lower 7 bits represent the permission index. - -The session signature is an ECDSA signature of the call and replay protection information in the payload (nonce, space and chainId). - -No attestation data is embedded here for implicit calls; instead, each implicit call references an attestation by index from the Attestation List. - -#### EIP-2098 Compact Signature Encoding - -Compact signatures follows the [EIP-2098](https://eip.tools/eip/2098) compact signature format. In this format, the signature is encoded as follows: - -``` -EIP-2098 Compact Encoding: - ┌─────────────────────────────────────────────────────────────┐ - │ 256-bit r value │ - │ 1-bit yParity (encoded into s) │ - │ 255-bit s value │ - └─────────────────────────────────────────────────────────────┘ -``` - -This encoding merges the `v` value into the `s` value, reducing the overall signature size while maintaining full signature recovery capability. - ---- - -## Permissions System - -The permissions system governs what actions a session signer is allowed to execute within explicit sessions. It is designed to be flexible, allowing validations on any field within the call data through the use of **value**, **offset**, and **mask** parameters. - -### Session Permissions (Explicit Sessions) - -Defined in the `SessionPermissions` struct, these include: - -- **Signer:** Authorized session signer. -- **Value Limit:** Maximum native token value allowed. -- **Deadline:** Expiration timestamp (0 indicates no deadline). -- **Permissions Array:** List of permission objects. - -> [!WARNING] -> If a session's deadline is set and the current block timestamp exceeds it, the session is considered expired and all calls will be rejected. - -### Permission Object and Parameter Rules - -Each permission object specifies a target contract and a set of rules that define acceptable call parameters. - -#### Permission Object Recap - -``` -Permission Object: - ┌────────────────────────────────┐ - │ Target Address │ - │ Rules Count (uint8) │ - │ Rules (array of ParameterRule) │ - └────────────────────────────────┘ -``` - -#### Parameter Rule Recap - -``` -Parameter Rule: - ┌────────────────────────────────────────────────────────────┐ - │ Operation & Cumulative Flag (1 byte) │ - │ ┌──────────────────────────────────────────────────────┐ │ - │ │ Bits 7..1 (0xFE): Operation (e.g., 0 = EQUAL, etc.) │ │ - │ │ Bit 0 (0x01): Cumulative flag (1 = cumulative) │ │ - │ └──────────────────────────────────────────────────────┘ │ - │ Value (bytes32) │ - │ Offset (uint256) │ - │ Mask (bytes32) │ - └────────────────────────────────────────────────────────────┘ -``` - -> [!TIP] -> A permission with an empty rules array is treated as _open_, granting unrestricted access to the target, subject only to other constraints such as value limits and deadlines. - ---- - -## Detailed Permission Rules and Validation - -The permission rules mechanism provides a powerful and flexible method to validate any field within the call data. Here's a detailed look at how the rules work: - -### Components of a Permission Rule - -- **Value:** - The expected value (stored as a `bytes32`) used for comparison. - -- **Offset:** - The byte offset in the call data from which the 32-byte parameter is extracted. - -- **Mask:** - A bitmask applied to the extracted data. This isolates the relevant bits, allowing validation even when the field is embedded within a larger data structure. - -### Validation Process - -For each rule, the validation function performs the following steps: - -1. **Extraction:** - Read 32 bytes from the call data starting at the specified offset: - - ```solidity - bytes32 extracted_value = call.data.readBytes32(rule.offset); - ``` - -2. **Masking:** - Apply the mask to isolate the target bits: - - ```solidity - bytes32 masked_value = extracted_value & rule.mask; - ``` - -3. **Comparison:** - Compare the masked value with the expected value using the defined operation: - - **EQUAL:** The masked value must exactly equal the expected value. - - **LESS_THAN_OR_EQUAL:** The masked value must be less than or equal to the expected value. - - **GREATER_THAN_OR_EQUAL:** The masked value must be greater than or equal to the expected value. - - **NOT_EQUAL:** The masked value must not equal the expected value. - -> [!TIP] -> This approach allows validation on any field within the call data regardless of its format or position. - -### The Cumulative Flag - -When the **cumulative** flag is set on a permission rule: - -1. **Cumulative Calculation:** - The value extracted from the current call is added to a previously recorded usage amount (stored in the payload's usage limits or persistent storage). - -2. **Threshold Comparison:** - The cumulative total (current value plus previous usage) is compared against the threshold defined by the rule. - -3. **Preceding Update:** - Because cumulative values persist across multiple calls, a preceding call to `incrementUsageLimit` is required. This call updates the on-chain storage with the new cumulative total, ensuring that future validations reflect the updated usage. - -> [!WARNING] -> Cumulative usage is tracked using hashes: `keccak256(abi.encode(signer, permission, ruleIdx))` for rules and `keccak256(abi.encode(signer, VALUE_TRACKING_ADDRESS))` for native tokens. Modifying a permission creates a new hash, so the old usage state must be considered when modifying a permission. - -### Example: ERC20.transfer - -Consider an ERC20 token `transfer` function: - -```solidity -function transfer(address to, uint256 amount) returns (bool); -``` - -**Call Data Layout:** - -- **4 bytes:** Function selector. -- **32 bytes:** Encoded `to` address. -- **32 bytes:** Encoded `amount`. - -**Permission Rule Setup:** - -- **Target:** - The ERC20 token contract address. - -- **Offset:** - `36` bytes (4 bytes for the function selector + 32 bytes for the `to` address) - this is where the `amount` parameter begins. - -- **Mask:** - A full mask (`0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF`) to extract the entire 32-byte value. - -- **Value:** - `100 * 10^18` (expressed as a `bytes32` value) to represent a maximum transfer amount of 100 tokens (assuming 18 decimals). - -- **Operation:** - `LESS_THAN_OR_EQUAL` - ensuring the transfer amount does not exceed the threshold. - -- **Cumulative Flag (optional):** - If you want to enforce a cumulative limit (e.g., a daily cap), set the cumulative flag. Each transfer's amount is then added to a cumulative total that must not exceed the threshold, with an `incrementUsageLimit` call required to update the stored value. - -> [!NOTE] -> ERC20.transfer Example Recap: The permission rule extracts the `amount` parameter from call data at offset 36, applies a mask to isolate the full value, and verifies that the value is less than or equal to 100 \* 10^18. Optionally, if the cumulative flag is set, it enforces a cumulative limit across multiple calls. In practice, the permission would also include a rule to check the function selector, ensuring that the call is to the `transfer` function. - ---- - -## Attestation (Implicit Sessions) - -Implicit sessions use an attestation to verify that the session signer is approved. The attestation is encoded and then validated by the target contract. - -### Attestation Encoding - -``` -Attestation Encoding: - ┌──────────────────────────────────────────────┐ - │ Approved Signer (address) │ - │ Identity Type (bytes4) │ - │ Issuer Hash (bytes32) │ - │ Audience Hash (bytes32) │ - │ Application Data Length (uint24) │ - │ Application Data (variable bytes) │ - │ Redirect URL Length (uint24) │ - │ Redirect URL (variable string) │ - │ Issued At (uint64) │ - └──────────────────────────────────────────────┘ -``` - -The Attestation data obtained during authentication. The `Identity Type` is the type of identity that was used to authenticate the user. The `Issuer Hash` is the hash of the issuer. The `Audience Hash` is the hash of the audience. The `Application Data` can be provided by the dapp. The `Auth Data` contains the redirect URL (string) and issuance timestamp (uint64). - -> [!WARNING] -> The `Application Data` length is encoded using a `uint24`. Ensure that data lengths are within these limits. - -> [!NOTE] -> The `Redirect URL` length is encoded using a `uint24`, and the `Issued At` field is a `uint64` timestamp representing when the attestation was issued. The encoding order is: `redirectUrlLength` (uint24), `redirectUrl` (string), `issuedAt` (uint64). - -### Attestation Validation - -- The attestation's **approved signer** must match the session signer. -- A magic value is generated using a combination of a prefix, the wallet address, the attestation's audience hash, and issuer hash. -- The attestation signature is validated against the identity signer from the configuration. -- The target contract's `acceptImplicitRequest` function must return the expected magic value; otherwise, the call is rejected. - -> [!WARNING] -> Implicit sessions require a properly encoded blacklist in the configuration. Calls to a blacklisted address will be rejected, and missing blacklist data will cause validation errors. - ---- - -## Future Improvements - -Several improvements can be made - -> [!NOTE] -> Configuration Flexibility: Introduce versioning or additional flags in the configuration encoding to support new features while preserving backward compatibility. Allow dynamic adjustments without breaking the merkle tree-based image hash structure. - -> [!NOTE] -> Gas Optimization: Optimize the recursive encoding/decoding logic for configurations with a large number of permissions or deep branch nesting to reduce gas costs. - -> [!NOTE] -> Call Signature Optimization: Optimize the call signature encoding to reduce the size of the calldata. A potential target for optimization is to remove repeated encodings of the same attestation data. - -> [!NOTE] -> Advanced Permission Rules: Extend the permission system to support more complex conditional checks or dynamic rule adjustments. Provide improved error messages and diagnostic tools for failed validations. - ---- - -## Conclusion - -The smart sessions system in Ecosystem wallets offers a flexible framework for authorizing batched operations via signed payloads. By leveraging detailed encoding schemes for configuration, permissions, and attestations - and by deriving an image hash that cryptographically fingerprints the configuration tree (even when sparse) - the system supports both explicit sessions and implicit sessions while ensuring robust validation. The detailed permission rules, including the use of **value**, **offset**, and **mask**, provide granular control over call data validation, and the cumulative flag facilitates persistent limits across calls. The outlined future improvements aim to enhance security, efficiency, and usability as the system evolves. - -This documentation serves as a technical guide for developers integrating and extending the smart sessions framework, providing both detailed encoding breakdowns and practical considerations for deployment and further development. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/docs/SIGNATURE.md b/lib/signals-implicit-mode/lib/sequence-v3/docs/SIGNATURE.md deleted file mode 100644 index 38d1fb6954..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/docs/SIGNATURE.md +++ /dev/null @@ -1,367 +0,0 @@ -# **Technical Document: Sequence Signature Encoding** - -This document describes, in detail, how the Sequence signature encoding is structured, how each part is packed into bytes, and how chained signatures and top-level signatures work. It is purely technical, explaining the bit layouts, flags, and usage with examples. - ---- - -## **1. Overview** - -Sequence uses a specialized signature format that: - -1. Has a **top-level signature** that includes: - - A single "signature flag" byte that encodes multiple fields (checkpointer usage, signature type, checkpoint size, threshold size, etc.). - - (Optionally) data related to an on-chain checkpointer contract. - - A notion of _chained signatures_ vs. _normal signatures_ vs. _“no chain id”_ signatures. - - A final threshold and checkpoint value that tie into the overall wallet or contract logic. - -2. Contains a **merkle-like structure** for the signers at the “branch” level, where each “leaf” or “node” is encoded using a separate mini-flag nibble. This is parsed with a loop in the `recoverBranch` function. - -3. Supports multiple sub-signature types, such as ECDSA (`FLAG_SIGNATURE_HASH` or `FLAG_SIGNATURE_ETH_SIGN`), ERC-1271 contract-based checks, nested “multi-sig inside multi-sig,” and special “sapient” signatures. Each sub-signature or branch piece is prefixed by one byte: the top nibble is the “flag type” and the bottom nibble contains per-flag configuration bits (like weight, sizes, or additional bits for `v`). - ---- - -## **2. Top-level Signature Format** - -When `recover` is first invoked, it reads the **first byte** of the signature as `signatureFlag`. That byte is bit-packed as follows (with bit `0` as the least-significant bit): - -``` - ┌─────────────── Bit 7 (0x80) : Static signature - │ ┌───────────── Bit 6 (0x40) : Checkpointer usage flag - │ │ ┌─────────── Bit 5 (0x20) : Threshold size indicator (0 => 1 byte, 1 => 2 bytes) - │ │ │ ┌──────── Bits 4..2 (0x1C) : Checkpoint size (encoded as an integer 0..7) - │ │ │ │ ┌───── Bit 1 (0x02) : "no chain id" signature type - │ │ │ │ │ ┌─── Bit 0 (0x01) : "chained" signature type -[7 6 5 432 1 0] -``` - -We can break this down more concretely: - -1. **Bit 7** set (`0x80`) indicates a static signature: - - When set, the signature has been pre-stored in contract storage and bypasses normal validation - - Validation only checks: - - That the stored expiry timestamp has not passed - - That the stored signer matches the transaction sender (or is unset with `address(0)`) -1. **Bit 6** set (`0x40`) means the signature includes an external **imageHash checkpointer**: - - If set, the signature will contain: - - The checkpointer contract `address` - - A 3-byte length for the “checkpointer data” - - That data, passed to `ICheckpointer(checkpointer).snapshotFor(...)` -1. **Bits 4..2** (the field `((signatureFlag & 0x1c) >> 2)`) define the **checkpoint size** in bytes. Possible values are `0..7`. If this value is `N`, then the next `N` bytes of the signature after reading the flag (and optional checkpointer data) represent the **checkpoint**. -1. **Bit 5** (`0x20`) sets how many bytes are used to read the threshold. If it is `0`, the threshold is read as 1 byte; if it is `1`, the threshold is read as 2 bytes. (Hence `( (signatureFlag & 0x20) >> 5 ) + 1`.) -1. **Bit 1** (`0x02`) indicates the “no chain id” signature. If set, `_payload.noChainId` is true. This affects how `_payload.hash()` is computed. -1. **Bit 0** (`0x01`) indicates the signature is **chained**. In that case, the code calls `recoverChained`, which processes multiple sub-signatures in sequence. - -Putting it together: - -- If bit `0` is set, we do a **chained** approach: The signature is composed of chunks, each chunk specifying a length and then a nested signature. -- Otherwise, we do a “regular” top-level parse: we read the checkpoint size, threshold size, then parse the “branch” for signers. - -### **Example of a Top-level Signature Byte** - -Suppose the top-level `signatureFlag` is `0x74` in hex. Converting `0x74` to binary: - -``` -0x74 = 01110100 in binary - ^ ^ ^ ^ -bit 7: 0 (reserved) -bit 6: 1 => checkpointer usage -bit 5: 1 => threshold uses 2 bytes -bits 4..2: 101 => checkpoint size = 5 bytes -bit 1: 0 => normal (not "no chain id") -bit 0: 0 => not chained -``` - -From this: - -- We first read an `address` for the checkpointer, then read 3 bytes for the checkpointer data length, etc. -- We know we must parse **5 bytes** for the checkpoint value. -- Then parse **2 bytes** for the threshold. -- Then parse the remainder as the merkle-branch structure for signers. - ---- - -## **3. Chained Signatures** - -When **bit 0** is set (the least-significant bit), the signature is **chained**. Instead of the usual approach (parsing threshold, checkpoint, etc. from that same byte), the code calls: - -```solidity -recoverChained(_payload, snapshot, _signature); -``` - -A chained signature is a series of **signature chunks**, each chunk defined like this: - -``` -[3-byte length] [chunk of that length] -[3-byte length] [chunk of that length] -... -``` - -Each chunk can itself be a top-level signature in the sense that it calls `recover(...)` again—except it ignores checkpointer details after the first chunk. The code enforces: - -- Each chunk recovers `(threshold, weight, imageHash, checkpoint)`. -- If `weight < threshold`, it reverts with `LowWeightChainedSignature`. -- The `checkpoint` must be **strictly less** than the previous chunk’s `checkpoint`, ensuring correct ordering (`WrongChainedCheckpointOrder`). -- All but the first chunk are interpreted as a “configuration update” with a special “linkedPayload.” - -This allows multiple signature instructions to be “chained” in a single byte array. - -``` - 0 1 2 3 - |----- byte indices: 0..2 => 3-byte length L1 - |----- next L1 bytes => chunk #1 - ... - |----- next 3 bytes => length L2 - |----- next L2 bytes => chunk #2 - ... - |----- next 3 bytes => length L3 - |----- next L3 bytes => chunk #3 - ... - -``` - -Each chunk is itself a “top-level style signature” minus the repeated checkpointer usage. The final `(threshold, weight, imageHash, checkpoint)` from the last chunk can be used to validate the overall signature. - ---- - -## **4. Branch-Level Parsing** - -Regardless of whether it is a chained signature or a direct one, eventually the code calls: - -```solidity -recoverBranch(_payload, opHash, _signature) -``` - -This function loops over the remainder of the signature, reading one byte at a time as the “header” for a sub-signature or branch item. We’ll call that one byte `firstByte`. The code extracts: - -- `flag = (firstByte & 0xf0) >> 4;` (the top nibble) -- The lower nibble is used as “free bits.” - -### **4.1 Flag Values** - -The contract defines constants: - -| Constant Name | Value (Decimal) | Purpose | -| -------------------------------------- | --------------- | ----------------------------------------------------------------------------------------------------- | -| `FLAG_SIGNATURE_HASH` | 0 | ECDSA signature with `r,yParityAndS` (ERC-2098 compact) directly against `_opHash`. | -| `FLAG_ADDRESS` | 1 | Just an address “leaf” (with no actual ECDSA check) | -| `FLAG_SIGNATURE_ERC1271` | 2 | A contract-based signature check using `isValidSignature(opHash, signature)` | -| `FLAG_NODE` | 3 | Includes a raw 32-byte node hash in the merkle root. No weight added. | -| `FLAG_BRANCH` | 4 | Nested branch. The next bytes specify length, then recursion into `recoverBranch`. | -| `FLAG_SUBDIGEST` | 5 | Hard-coded “accepted subdigest.” If `_opHash` matches the stored 32 bytes, infinite weight. | -| `FLAG_NESTED` | 6 | A nested multi-sig node with an internal threshold plus an external weight. | -| `FLAG_SIGNATURE_ETH_SIGN` | 7 | ECDSA signature in “Eth_sign” format (`"\x19Ethereum Signed Message:\n32" + opHash`), using ERC-2098. | -| `FLAG_SIGNATURE_ANY_ADDRESS_SUBDIGEST` | 8 | `FLAG_SUBDIGEST` but with counter factual support. | -| `FLAG_SIGNATURE_SAPIENT` | 9 | A specialized “sapient” signature with an `ISapient` contract check. | -| `FLAG_SIGNATURE_SAPIENT_COMPACT` | 10 | A specialized “sapient” signature with `ISapientCompact` and `_opHash` only. | - -When the parser sees `flag == someValue`, it dispatches to the corresponding block. Each block interprets the lower nibble differently. - ---- - -## **5. Detailed Flag-by-Flag Format** - -Below are the internal mini-formats for each **flag**. Recall that in code, `firstByte` is the single byte at the start of each item, and we do: - -``` -flag = (firstByte & 0xf0) >> 4; // top nibble -// "free nibble" = (firstByte & 0x0f) -``` - -Each bullet will show how the bits in the “free nibble” are used. - ---- - -### 5.1 **Signature Hash** (`flag = 0`) - -- Uses **ERC-2098** to parse the signature in 64 bytes (`r` + `yParityAndS`). -- The free nibble bits [3..0] define the signer's weight (0 => we read the weight from the next byte, else 1..15). -- After reading `r` (32 bytes) and `yParityAndS` (32 bytes), the top bit of `yParityAndS` (bit 255) is `yParity` (0 or 1), which is added to 27 to form `v`. The remaining 255 bits are `s`. -- We then perform `ecrecover(_opHash, v, r, s)`. - -**Example** -If the sub-signature byte is `0x05` (`0000 0101` in binary), then top nibble=0 => `FLAG_SIGNATURE_HASH`, free nibble=5 => weight=5. We do **not** read an extra byte for the weight. Next, we read 64 bytes as the compact signature: 32 bytes for `r`, 32 bytes for `yParityAndS`. If the top bit of `yParityAndS` is 0 => `v=27`; if it is 1 => `v=28`. The rest is `s`. Then we do `ecrecover`. - ---- - -### 5.2 **Address** (`flag = 1`) - -- Takes an address leaf (no ECDSA). -- The free nibble bits 3..0 define the weight in the same scheme: - - If those bits are zero, read an extra byte for weight. - - Else use that 1..15 as the weight. -- Then reads 20 bytes for the address. -- Merges `_leafForAddressAndWeight(addr, weight)`. - ---- - -### 5.3 **Signature ERC-1271** (`flag = 2`) - -- The free nibble bits are used as: - - The bottom two bits are the weight (with the same “0 => dynamic read, else 1..3” logic). - - The next two bits define the size of the “signature size” field: 0..3 means we read 0..3 bytes to get the dynamic length of the next part. -- Then we read 20 bytes for the contract address, read that dynamic-size signature, and call `IERC1271(addr).isValidSignature(_opHash, data)`. If it returns the magic value `0x1626ba7e`, it is valid; otherwise revert. -- Weight is added if valid. - -**Example** - -``` -firstByte = 0x2D -> 0010 1101 in binary - top nibble = 2 -> FLAG_SIGNATURE_ERC1271 - free nibble = 0xD = 1101 in binary - bits 3..2 = 11 -> sizeSize=3 => read 3 bytes to get length - bits 1..0 = 01 -> weight=1 -``` - -Then parse next 3 bytes to discover how big the signature is, read it, do the 1271 check. - ---- - -### 5.4 **Node** (`flag = 3`) - -- No free bits used. -- Simply reads a 32-byte “node hash” and merges it. -- No weight is added. - ---- - -### 5.5 **Branch** (`flag = 4`) - -- The free nibble bits 3..0 define how many bytes are used to read the upcoming “branch size.” -- Once the branch size is read, we extract that many bytes as a sub-branch, and recursively call `recoverBranch` on that sub-slice. -- We get `(nweight, nodeHash)` from that sub-branch, add `nweight` to the total, and merge the nodeHash into the root. - ---- - -### 5.6 **Subdigest** (`flag = 5`) - -- The code reads a 32-byte “hardcoded subdigest.” If it matches the `_opHash`, sets `weight = type(uint256).max`. -- Merges `_leafForHardcodedSubdigest(hardcoded)`. - -This effectively means “if the 32 bytes match the current operation hash, we grant infinite weight.” - ---- - -### 5.7 **Nested** (`flag = 6`) - -- The free nibble is split: - - The bottom two bits define the “external weight.” Again, `0 => read from next byte, else 1..3`. - - The next two bits define the “internal threshold” size. If `0`, read 2 bytes from the next portion for that threshold, else 1..3 is just 1..3? - - Then read 3 bytes to get the length of the nested sub-branch, parse it. That yields `(internalWeight, internalRoot)`. - - If `internalWeight >= internalThreshold`, we add the external weight to the total. Finally, we merge `_leafForNested(internalRoot, internalThreshold, externalWeight)` into the root. - -**Example** - -``` -firstByte = 0x64 -> 0110 0100 in binary - top nibble = 6 -> FLAG_NESTED - free nibble = 0x4 = 0100 in binary - bits 3..2 = 01 -> internalThreshold=1 - bits 1..0 = 00 -> externalWeight => read from next byte -``` - -Then read next byte for externalWeight, read next 2 bytes for threshold if needed, etc. - ---- - -### 5.8 **Signature ETH Sign** (`flag = 7`) - -- Similar to `FLAG_SIGNATURE_HASH`, but recovers via: - -``` -ecrecover( keccak256("\x19Ethereum Signed Message:\n32" + _opHash), v, r, s ) -``` - -- Uses **ERC-2098**: we read 64 bytes (32 for `r`, 32 for `yParityAndS`), retrieve `yParity` from the top bit, add 27 to form `v`, and use the remainder as `s`. -- The free nibble bits [3..0] define the weight (0 => dynamic read, else 1..15). - ---- - -### 5.9 **Signature Any Address Subgiest** (`flag = 8`) - -- The code reads a 32-byte "hardcoded subdigest." If it matches `_payload.hashFor(address(0))`, sets `weight = type(uint256).max`. -- Merges `_leafForAnyAddressSubdigest(anyAddressOpHash)`. - -This effectively means "if the 32 bytes match the operation hash computed for address(0), we grant infinite weight." This allows for counter-factual payloads. - ---- - -### 5.10 **Signature Sapient** (`flag = 9`) - -- The free nibble is structured like `ERC1271`: some bits define how many bytes to read for the signature, some bits define the weight. -- Then it calls `ISapient(addr).recoverSapientSignature(_payload, data)`, which must return a “sapientImageHash” used in `_leafForSapient`. -- Weight is added if valid. - ---- - -### 5.11 **Signature Sapient Compact** (`flag = 10`) - -- Same approach as `FLAG_SIGNATURE_SAPIENT`, except the contract uses `ISapientCompact.recoverSapientSignatureCompact(_opHash, data)` instead, passing only `_opHash`. - ---- - -## **6. Merkle Root Construction** - -The branch parser accumulates a “root” by repeatedly combining leaves with the function: - -```solidity -root = LibOptim.fkeccak256(root, leaf) -``` - -In each sub-flag block, a leaf is computed, for example: - -- `_leafForAddressAndWeight(address, weight)` -- `_leafForNested(internalRoot, threshold, externalWeight)` -- `_leafForHardcodedSubdigest(someDigest)` -- etc. - -The final `root` is combined with the threshold and checkpoint (and checkpointer address, if present) to yield the final “imageHash.” That is used to tie the signatures to a specific configuration or permission set. - ---- - -## **7. Example Putting it All Together** - -Below is a hypothetical top-level signature that is **not** chained, uses a checkpointer, has a 2-byte threshold, a 1-byte checkpoint, and then includes a single ECDSA leaf: - -1. **signatureFlag** = `0x6C` => in binary `0110 1100` - - Bit 6 => `1`, so we have a checkpointer - - Bit 5 => `1`, threshold uses 2 bytes - - Bits 4..2 => `110` => checkpoint size = 6 bytes - - Bit 1 => `0`, normal chain id usage - - Bit 0 => `0`, not chained -2. We read: - - `checkpointer` address (20 bytes) - - 3-byte checkpointer data size => parse that data - - 6 bytes => the “checkpoint” number - - 2 bytes => the threshold -3. We jump into `recoverBranch`, and the next 1-byte might be `0x02` in hex => top nibble=0 => `FLAG_SIGNATURE_HASH` with free nibble=2 => weight=2. Then parse 64 bytes for ERC-2098. We derive `v` from the top bit of the second 32 bytes, do ecrecover, and merge the address in the merkle root. - -Finally, the code compares the final computed image hash, checks if we pass threshold vs. weight, checks snapshot logic, and returns `(threshold, weight, imageHash, checkpoint)`. - ---- - -## **8. Snapshot and Checkpointer Logic** - -If the top-level byte indicates we have a checkpointer (`bit 6` set), we read: - -- The checkpointer’s address -- The next 3 bytes => `checkpointerDataSize` -- That many bytes => `checkpointerData` - -We call: - -```solidity -snapshot = ICheckpointer(checkpointer).snapshotFor(address(this), checkpointerData); -``` - -This yields a `Snapshot { imageHash, checkpoint }`. If the final signature’s computed `imageHash` and `checkpoint` do not properly exceed or match the snapshot, the code can revert with `UnusedSnapshot`. - ---- - -## **9. Summary** - -1. **Top-level “signatureFlag”** byte sets the “checkpointer usage,” “signature type,” “checkpoint size,” “threshold size,” etc. -2. If the signature is **chained**, parse a series of sub-signatures, each of which in turn calls the normal `recover`. -3. Eventually, a **branch** parse is done with `recoverBranch`, which looks at many items. Each item is marked by a single byte whose **top nibble** identifies the flag (ECDSA, ERC1271, sub-branch, nested multi-sig, etc.), and whose **bottom nibble** has special bits (like the signers’ weight, or signature-size format). -4. The final output is `(threshold, weight, imageHash, checkpoint)` plus snapshot checks if any. - -This structure allows advanced multi-signature logic, nested multi-sigs, infinite weight if a known subdigest matches `_opHash`, and optional checkpointer extension. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/foundry.toml b/lib/signals-implicit-mode/lib/sequence-v3/foundry.toml deleted file mode 100644 index bd0622cc14..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/foundry.toml +++ /dev/null @@ -1,31 +0,0 @@ -[profile.default] -src = "src" -out = "out" -libs = ["lib"] -via-ir = true -optimizer = true -optimizer_runs = 4294967295 -fs_permissions = [{ access = "read-write", path = "/tmp"}] -solc = "0.8.28" -evm_version = "paris" -remappings = [ - "account-abstraction/=lib/account-abstraction/contracts/" -] - -[fuzz] -max_test_rejects = 1000000 - -[fmt] -# Explicitly define all formatting rules -multiline_func_header = "params_first" -single_line_statement_blocks = "multi" -sort_imports = true -contract_new_lines = true -override_spacing = false -line_length = 120 -tab_width = 2 -bracket_spacing = true -int_types = "long" -quote_style = "double" -hex_underscore = "remove" -wrap_comments = false diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lefthook.yml b/lib/signals-implicit-mode/lib/sequence-v3/lefthook.yml deleted file mode 100644 index 6adffd9a53..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lefthook.yml +++ /dev/null @@ -1,8 +0,0 @@ -pre-commit: - commands: - forge-fmt: - glob: '**/*.sol' - run: forge fmt {staged_files} && git add {staged_files} - prettier: - glob: '**/*.{js,jsx,ts,tsx,json,md,yml,yaml}' - run: pnpm prettier --write {staged_files} && git add {staged_files} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.eslintrc.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.eslintrc.js deleted file mode 100644 index fde1d6d696..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.eslintrc.js +++ /dev/null @@ -1,79 +0,0 @@ -module.exports = { - env: { - browser: true, - es6: true, - jest: true, - mocha: true, - node: true - }, - globals: { - artifacts: false, - assert: false, - contract: false, - web3: false - }, - extends: - [ - 'standard-with-typescript' - ], - // This is needed to add configuration to rules with type information - parser: '@typescript-eslint/parser', - parserOptions: { - project: ['./tsconfig.json'] - }, - ignorePatterns: [ - '.eslintrc.js', - '**/types/truffle-contracts', - 'coverage', - 'dist/' - ], - rules: { - 'no-console': 'off', - '@typescript-eslint/no-var-requires': 'off', - '@typescript-eslint/return-await': 'off', - '@typescript-eslint/no-unnecessary-type-assertion': 'off', - '@typescript-eslint/require-array-sort-compare': ['error', - { - ignoreStringArrays: true - } - ] - }, - overrides: [ - { - files: '*', - rules: { - '@typescript-eslint/naming-convention': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/restrict-template-expressions': 'off' - } - }, - { - files: [ - '**/test/**/*.ts' - ], - rules: { - 'no-unused-expressions': 'off', - // chai assertions trigger this rule - '@typescript-eslint/no-unused-expressions': 'off', - '@typescript-eslint/no-non-null-assertion': 'off' - } - }, - { - // otherwise it will raise an error in every JavaScript file - files: ['*.ts'], - rules: { - '@typescript-eslint/prefer-ts-expect-error': 'off', - // allow using '${val}' with numbers, bool and null types - '@typescript-eslint/restrict-template-expressions': [ - 'error', - { - allowNumber: true, - allowBoolean: true, - allowNullish: true, - allowNullable: true - } - ] - } - } - ] -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.github/workflows/build.yml b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.github/workflows/build.yml deleted file mode 100644 index c2ef0af864..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.github/workflows/build.yml +++ /dev/null @@ -1,89 +0,0 @@ -name: Build -on: - push: - branches: - - '*' - pull_request: - types: [opened, reopened, synchronize] - -env: - TS_NODE_TRANSPILE_ONLY: 1 - FORCE_COLORS: 1 - -# todo: extract shared seto/checkout/install/compile, instead of repeat in each job. -jobs: - - test: - runs-on: ubuntu-latest - - steps: - - uses: actions/setup-node@v1 - with: - node-version: '16' - - uses: actions/checkout@v1 - - uses: actions/cache@v2 - with: - path: node_modules - key: ${{ runner.os }}-${{ hashFiles('yarn.lock') }} - - run: yarn install - - run: yarn compile - - run: yarn tsc - - - run: yarn run ci - - gas-checks: - runs-on: ubuntu-latest - services: - localgeth: - image: dtr22/geth-dev - - steps: - - uses: actions/setup-node@v1 - with: - node-version: '16' - - uses: actions/checkout@v1 - - uses: actions/cache@v2 - with: - path: node_modules - key: ${{ runner.os }}-${{ hashFiles('yarn.lock') }} - - run: yarn install - - run: yarn compile - - run: yarn ci-gas-calc - - lint: - runs-on: ubuntu-latest - steps: - - uses: actions/setup-node@v1 - with: - node-version: '16' - - uses: actions/checkout@v1 - - uses: actions/cache@v2 - with: - path: node_modules - key: ${{ runner.os }}-${{ hashFiles('yarn.lock') }} - - run: yarn install - - run: yarn lint - - coverage: - runs-on: ubuntu-latest - steps: - - uses: actions/setup-node@v1 - with: - node-version: '16' - - uses: actions/checkout@v1 - - uses: actions/cache@v2 - with: - path: node_modules - key: ${{ runner.os }}-${{ hashFiles('yarn.lock') }} - - run: yarn install - - - run: yarn compile - - - run: FORCE_COLOR=1 yarn coverage - - uses: actions/upload-artifact@v2 - with: - name: solidity-coverage - path: | - coverage/ - coverage.json - diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.solcover.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.solcover.js deleted file mode 100644 index 851e37d61d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.solcover.js +++ /dev/null @@ -1,8 +0,0 @@ -module.exports = { - skipFiles: [ - "test", - "samples/bls/lib", - "utils/Exec.sol" - ], - configureYulOptimizer: true, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.solhint.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.solhint.json deleted file mode 100644 index 2b5dda040c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.solhint.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "extends": "solhint:recommended", - "rules": { - "compiler-version": ["error",">=0.7.5"], - "func-visibility": ["off",{"ignoreConstructors":true}], - "custom-errors": ["off"], - "explicit-types": ["warn", "explicit"], - "no-global-import": ["off"], - "immutable-vars-naming": ["off"], - "mark-callable-contracts": ["off"] - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.solhintignore b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.solhintignore deleted file mode 100644 index 4972aa1be6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/.solhintignore +++ /dev/null @@ -1 +0,0 @@ -contracts/samples/bls/lib/ diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/LICENSE b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/LICENSE deleted file mode 100644 index f288702d2f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/README.md b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/README.md deleted file mode 100644 index 57216f8272..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/README.md +++ /dev/null @@ -1,11 +0,0 @@ -Implementation of contracts for [ERC-4337](https://eips.ethereum.org/EIPS/eip-4337) account abstraction via alternative mempool. - -# Resources - -[Vitalik's post on account abstraction without Ethereum protocol changes](https://medium.com/infinitism/erc-4337-account-abstraction-without-ethereum-protocol-changes-d75c9d94dc4a) - -[Discord server](http://discord.gg/fbDyENb6Y9) - -[Bundler reference implementation](https://github.com/eth-infinitism/bundler) - -[Bundler specification test suite](https://github.com/eth-infinitism/bundler-spec-tests) diff --git "a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/audits/EIP_4337_\342\200\223_Ethereum_Account_Abstraction_Incremental_Audit_Feb_2023.pdf" "b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/audits/EIP_4337_\342\200\223_Ethereum_Account_Abstraction_Incremental_Audit_Feb_2023.pdf" deleted file mode 100644 index 7050f47a62..0000000000 Binary files "a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/audits/EIP_4337_\342\200\223_Ethereum_Account_Abstraction_Incremental_Audit_Feb_2023.pdf" and /dev/null differ diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/BaseAccount.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/BaseAccount.sol deleted file mode 100644 index 459fc6ab3c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/BaseAccount.sol +++ /dev/null @@ -1,113 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -/* solhint-disable avoid-low-level-calls */ -/* solhint-disable no-empty-blocks */ - -import "../interfaces/IAccount.sol"; -import "../interfaces/IEntryPoint.sol"; -import "./UserOperationLib.sol"; - -/** - * Basic account implementation. - * This contract provides the basic logic for implementing the IAccount interface - validateUserOp - * Specific account implementation should inherit it and provide the account-specific logic. - */ -abstract contract BaseAccount is IAccount { - using UserOperationLib for PackedUserOperation; - - /** - * Return the account nonce. - * This method returns the next sequential nonce. - * For a nonce of a specific key, use `entrypoint.getNonce(account, key)` - */ - function getNonce() public view virtual returns (uint256) { - return entryPoint().getNonce(address(this), 0); - } - - /** - * Return the entryPoint used by this account. - * Subclass should return the current entryPoint used by this account. - */ - function entryPoint() public view virtual returns (IEntryPoint); - - /// @inheritdoc IAccount - function validateUserOp( - PackedUserOperation calldata userOp, - bytes32 userOpHash, - uint256 missingAccountFunds - ) external virtual override returns (uint256 validationData) { - _requireFromEntryPoint(); - validationData = _validateSignature(userOp, userOpHash); - _validateNonce(userOp.nonce); - _payPrefund(missingAccountFunds); - } - - /** - * Ensure the request comes from the known entrypoint. - */ - function _requireFromEntryPoint() internal view virtual { - require( - msg.sender == address(entryPoint()), - "account: not from EntryPoint" - ); - } - - /** - * Validate the signature is valid for this message. - * @param userOp - Validate the userOp.signature field. - * @param userOpHash - Convenient field: the hash of the request, to check the signature against. - * (also hashes the entrypoint and chain id) - * @return validationData - Signature and time-range of this operation. - * <20-byte> aggregatorOrSigFail - 0 for valid signature, 1 to mark signature failure, - * otherwise, an address of an aggregator contract. - * <6-byte> validUntil - last timestamp this operation is valid. 0 for "indefinite" - * <6-byte> validAfter - first timestamp this operation is valid - * If the account doesn't use time-range, it is enough to return - * SIG_VALIDATION_FAILED value (1) for signature failure. - * Note that the validation code cannot use block.timestamp (or block.number) directly. - */ - function _validateSignature( - PackedUserOperation calldata userOp, - bytes32 userOpHash - ) internal virtual returns (uint256 validationData); - - /** - * Validate the nonce of the UserOperation. - * This method may validate the nonce requirement of this account. - * e.g. - * To limit the nonce to use sequenced UserOps only (no "out of order" UserOps): - * `require(nonce < type(uint64).max)` - * For a hypothetical account that *requires* the nonce to be out-of-order: - * `require(nonce & type(uint64).max == 0)` - * - * The actual nonce uniqueness is managed by the EntryPoint, and thus no other - * action is needed by the account itself. - * - * @param nonce to validate - * - * solhint-disable-next-line no-empty-blocks - */ - function _validateNonce(uint256 nonce) internal view virtual { - } - - /** - * Sends to the entrypoint (msg.sender) the missing funds for this transaction. - * SubClass MAY override this method for better funds management - * (e.g. send to the entryPoint more than the minimum required, so that in future transactions - * it will not be required to send again). - * @param missingAccountFunds - The minimum value this method should send the entrypoint. - * This value MAY be zero, in case there is enough deposit, - * or the userOp has a paymaster. - */ - function _payPrefund(uint256 missingAccountFunds) internal virtual { - if (missingAccountFunds != 0) { - (bool success, ) = payable(msg.sender).call{ - value: missingAccountFunds, - gas: type(uint256).max - }(""); - (success); - //ignore failure (its EntryPoint's job to verify, not account.) - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/BasePaymaster.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/BasePaymaster.sol deleted file mode 100644 index 9bcb6fe63d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/BasePaymaster.sol +++ /dev/null @@ -1,151 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -/* solhint-disable reason-string */ - -import "@openzeppelin/contracts/access/Ownable.sol"; -import "@openzeppelin/contracts/utils/introspection/IERC165.sol"; -import "../interfaces/IPaymaster.sol"; -import "../interfaces/IEntryPoint.sol"; -import "./UserOperationLib.sol"; -/** - * Helper class for creating a paymaster. - * provides helper methods for staking. - * Validates that the postOp is called only by the entryPoint. - */ -abstract contract BasePaymaster is IPaymaster, Ownable { - IEntryPoint public immutable entryPoint; - - uint256 internal constant PAYMASTER_VALIDATION_GAS_OFFSET = UserOperationLib.PAYMASTER_VALIDATION_GAS_OFFSET; - uint256 internal constant PAYMASTER_POSTOP_GAS_OFFSET = UserOperationLib.PAYMASTER_POSTOP_GAS_OFFSET; - uint256 internal constant PAYMASTER_DATA_OFFSET = UserOperationLib.PAYMASTER_DATA_OFFSET; - - constructor(IEntryPoint _entryPoint) Ownable(msg.sender) { - _validateEntryPointInterface(_entryPoint); - entryPoint = _entryPoint; - } - - //sanity check: make sure this EntryPoint was compiled against the same - // IEntryPoint of this paymaster - function _validateEntryPointInterface(IEntryPoint _entryPoint) internal virtual { - require(IERC165(address(_entryPoint)).supportsInterface(type(IEntryPoint).interfaceId), "IEntryPoint interface mismatch"); - } - - /// @inheritdoc IPaymaster - function validatePaymasterUserOp( - PackedUserOperation calldata userOp, - bytes32 userOpHash, - uint256 maxCost - ) external override returns (bytes memory context, uint256 validationData) { - _requireFromEntryPoint(); - return _validatePaymasterUserOp(userOp, userOpHash, maxCost); - } - - /** - * Validate a user operation. - * @param userOp - The user operation. - * @param userOpHash - The hash of the user operation. - * @param maxCost - The maximum cost of the user operation. - */ - function _validatePaymasterUserOp( - PackedUserOperation calldata userOp, - bytes32 userOpHash, - uint256 maxCost - ) internal virtual returns (bytes memory context, uint256 validationData); - - /// @inheritdoc IPaymaster - function postOp( - PostOpMode mode, - bytes calldata context, - uint256 actualGasCost, - uint256 actualUserOpFeePerGas - ) external override { - _requireFromEntryPoint(); - _postOp(mode, context, actualGasCost, actualUserOpFeePerGas); - } - - /** - * Post-operation handler. - * (verified to be called only through the entryPoint) - * @dev If subclass returns a non-empty context from validatePaymasterUserOp, - * it must also implement this method. - * @param mode - Enum with the following options: - * opSucceeded - User operation succeeded. - * opReverted - User op reverted. The paymaster still has to pay for gas. - * postOpReverted - never passed in a call to postOp(). - * @param context - The context value returned by validatePaymasterUserOp - * @param actualGasCost - Actual gas used so far (without this postOp call). - * @param actualUserOpFeePerGas - the gas price this UserOp pays. This value is based on the UserOp's maxFeePerGas - * and maxPriorityFee (and basefee) - * It is not the same as tx.gasprice, which is what the bundler pays. - */ - function _postOp( - PostOpMode mode, - bytes calldata context, - uint256 actualGasCost, - uint256 actualUserOpFeePerGas - ) internal virtual { - (mode, context, actualGasCost, actualUserOpFeePerGas); // unused params - // subclass must override this method if validatePaymasterUserOp returns a context - revert("must override"); - } - - /** - * Add a deposit for this paymaster, used for paying for transaction fees. - */ - function deposit() public payable { - entryPoint.depositTo{value: msg.value}(address(this)); - } - - /** - * Withdraw value from the deposit. - * @param withdrawAddress - Target to send to. - * @param amount - Amount to withdraw. - */ - function withdrawTo( - address payable withdrawAddress, - uint256 amount - ) public onlyOwner { - entryPoint.withdrawTo(withdrawAddress, amount); - } - - /** - * Add stake for this paymaster. - * This method can also carry eth value to add to the current stake. - * @param unstakeDelaySec - The unstake delay for this paymaster. Can only be increased. - */ - function addStake(uint32 unstakeDelaySec) external payable onlyOwner { - entryPoint.addStake{value: msg.value}(unstakeDelaySec); - } - - /** - * Return current paymaster's deposit on the entryPoint. - */ - function getDeposit() public view returns (uint256) { - return entryPoint.balanceOf(address(this)); - } - - /** - * Unlock the stake, in order to withdraw it. - * The paymaster can't serve requests once unlocked, until it calls addStake again - */ - function unlockStake() external onlyOwner { - entryPoint.unlockStake(); - } - - /** - * Withdraw the entire paymaster's stake. - * stake must be unlocked first (and then wait for the unstakeDelay to be over) - * @param withdrawAddress - The address to send withdrawn value. - */ - function withdrawStake(address payable withdrawAddress) external onlyOwner { - entryPoint.withdrawStake(withdrawAddress); - } - - /** - * Validate the call is made from a valid entrypoint - */ - function _requireFromEntryPoint() internal virtual { - require(msg.sender == address(entryPoint), "Sender not EntryPoint"); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/EntryPoint.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/EntryPoint.sol deleted file mode 100644 index 44501524df..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/EntryPoint.sol +++ /dev/null @@ -1,800 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; -/* solhint-disable avoid-low-level-calls */ -/* solhint-disable no-inline-assembly */ - -import "../interfaces/IAccount.sol"; -import "../interfaces/IAccountExecute.sol"; -import "../interfaces/IPaymaster.sol"; -import "../interfaces/IEntryPoint.sol"; - -import "../utils/Exec.sol"; -import "./StakeManager.sol"; -import "./SenderCreator.sol"; -import "./Helpers.sol"; -import "./NonceManager.sol"; -import "./UserOperationLib.sol"; - -import "@openzeppelin/contracts/utils/introspection/ERC165.sol"; -import "@openzeppelin/contracts/utils/ReentrancyGuard.sol"; - -/* - * Account-Abstraction (EIP-4337) singleton EntryPoint implementation. - * Only one instance required on each chain. - */ - -/// @custom:security-contact https://bounty.ethereum.org -contract EntryPoint is IEntryPoint, StakeManager, NonceManager, ReentrancyGuard, ERC165 { - - using UserOperationLib for PackedUserOperation; - - SenderCreator private immutable _senderCreator = new SenderCreator(); - - function senderCreator() internal view virtual returns (SenderCreator) { - return _senderCreator; - } - - //compensate for innerHandleOps' emit message and deposit refund. - // allow some slack for future gas price changes. - uint256 private constant INNER_GAS_OVERHEAD = 10000; - - // Marker for inner call revert on out of gas - bytes32 private constant INNER_OUT_OF_GAS = hex"deaddead"; - bytes32 private constant INNER_REVERT_LOW_PREFUND = hex"deadaa51"; - - uint256 private constant REVERT_REASON_MAX_LEN = 2048; - uint256 private constant PENALTY_PERCENT = 10; - - /// @inheritdoc IERC165 - function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { - // note: solidity "type(IEntryPoint).interfaceId" is without inherited methods but we want to check everything - return interfaceId == (type(IEntryPoint).interfaceId ^ type(IStakeManager).interfaceId ^ type(INonceManager).interfaceId) || - interfaceId == type(IEntryPoint).interfaceId || - interfaceId == type(IStakeManager).interfaceId || - interfaceId == type(INonceManager).interfaceId || - super.supportsInterface(interfaceId); - } - - /** - * Compensate the caller's beneficiary address with the collected fees of all UserOperations. - * @param beneficiary - The address to receive the fees. - * @param amount - Amount to transfer. - */ - function _compensate(address payable beneficiary, uint256 amount) internal { - require(beneficiary != address(0), "AA90 invalid beneficiary"); - (bool success, ) = beneficiary.call{value: amount}(""); - require(success, "AA91 failed send to beneficiary"); - } - - /** - * Execute a user operation. - * @param opIndex - Index into the opInfo array. - * @param userOp - The userOp to execute. - * @param opInfo - The opInfo filled by validatePrepayment for this userOp. - * @return collected - The total amount this userOp paid. - */ - function _executeUserOp( - uint256 opIndex, - PackedUserOperation calldata userOp, - UserOpInfo memory opInfo - ) - internal - returns - (uint256 collected) { - uint256 preGas = gasleft(); - bytes memory context = getMemoryBytesFromOffset(opInfo.contextOffset); - bool success; - { - uint256 saveFreePtr; - assembly ("memory-safe") { - saveFreePtr := mload(0x40) - } - bytes calldata callData = userOp.callData; - bytes memory innerCall; - bytes4 methodSig; - assembly { - let len := callData.length - if gt(len, 3) { - methodSig := calldataload(callData.offset) - } - } - if (methodSig == IAccountExecute.executeUserOp.selector) { - bytes memory executeUserOp = abi.encodeCall(IAccountExecute.executeUserOp, (userOp, opInfo.userOpHash)); - innerCall = abi.encodeCall(this.innerHandleOp, (executeUserOp, opInfo, context)); - } else - { - innerCall = abi.encodeCall(this.innerHandleOp, (callData, opInfo, context)); - } - assembly ("memory-safe") { - success := call(gas(), address(), 0, add(innerCall, 0x20), mload(innerCall), 0, 32) - collected := mload(0) - mstore(0x40, saveFreePtr) - } - } - if (!success) { - bytes32 innerRevertCode; - assembly ("memory-safe") { - let len := returndatasize() - if eq(32,len) { - returndatacopy(0, 0, 32) - innerRevertCode := mload(0) - } - } - if (innerRevertCode == INNER_OUT_OF_GAS) { - // handleOps was called with gas limit too low. abort entire bundle. - //can only be caused by bundler (leaving not enough gas for inner call) - revert FailedOp(opIndex, "AA95 out of gas"); - } else if (innerRevertCode == INNER_REVERT_LOW_PREFUND) { - // innerCall reverted on prefund too low. treat entire prefund as "gas cost" - uint256 actualGas = preGas - gasleft() + opInfo.preOpGas; - uint256 actualGasCost = opInfo.prefund; - emitPrefundTooLow(opInfo); - emitUserOperationEvent(opInfo, false, actualGasCost, actualGas); - collected = actualGasCost; - } else { - emit PostOpRevertReason( - opInfo.userOpHash, - opInfo.mUserOp.sender, - opInfo.mUserOp.nonce, - Exec.getReturnData(REVERT_REASON_MAX_LEN) - ); - - uint256 actualGas = preGas - gasleft() + opInfo.preOpGas; - collected = _postExecution( - IPaymaster.PostOpMode.postOpReverted, - opInfo, - context, - actualGas - ); - } - } - } - - function emitUserOperationEvent(UserOpInfo memory opInfo, bool success, uint256 actualGasCost, uint256 actualGas) internal virtual { - emit UserOperationEvent( - opInfo.userOpHash, - opInfo.mUserOp.sender, - opInfo.mUserOp.paymaster, - opInfo.mUserOp.nonce, - success, - actualGasCost, - actualGas - ); - } - - function emitPrefundTooLow(UserOpInfo memory opInfo) internal virtual { - emit UserOperationPrefundTooLow( - opInfo.userOpHash, - opInfo.mUserOp.sender, - opInfo.mUserOp.nonce - ); - } - - /// @inheritdoc IEntryPoint - function handleOps( - PackedUserOperation[] calldata ops, - address payable beneficiary - ) public nonReentrant { - uint256 opslen = ops.length; - UserOpInfo[] memory opInfos = new UserOpInfo[](opslen); - - unchecked { - for (uint256 i = 0; i < opslen; i++) { - UserOpInfo memory opInfo = opInfos[i]; - ( - uint256 validationData, - uint256 pmValidationData - ) = _validatePrepayment(i, ops[i], opInfo); - _validateAccountAndPaymasterValidationData( - i, - validationData, - pmValidationData, - address(0) - ); - } - - uint256 collected = 0; - emit BeforeExecution(); - - for (uint256 i = 0; i < opslen; i++) { - collected += _executeUserOp(i, ops[i], opInfos[i]); - } - - _compensate(beneficiary, collected); - } - } - - /// @inheritdoc IEntryPoint - function handleAggregatedOps( - UserOpsPerAggregator[] calldata opsPerAggregator, - address payable beneficiary - ) public nonReentrant { - - uint256 opasLen = opsPerAggregator.length; - uint256 totalOps = 0; - for (uint256 i = 0; i < opasLen; i++) { - UserOpsPerAggregator calldata opa = opsPerAggregator[i]; - PackedUserOperation[] calldata ops = opa.userOps; - IAggregator aggregator = opa.aggregator; - - //address(1) is special marker of "signature error" - require( - address(aggregator) != address(1), - "AA96 invalid aggregator" - ); - - if (address(aggregator) != address(0)) { - // solhint-disable-next-line no-empty-blocks - try aggregator.validateSignatures(ops, opa.signature) {} catch { - revert SignatureValidationFailed(address(aggregator)); - } - } - - totalOps += ops.length; - } - - UserOpInfo[] memory opInfos = new UserOpInfo[](totalOps); - - uint256 opIndex = 0; - for (uint256 a = 0; a < opasLen; a++) { - UserOpsPerAggregator calldata opa = opsPerAggregator[a]; - PackedUserOperation[] calldata ops = opa.userOps; - IAggregator aggregator = opa.aggregator; - - uint256 opslen = ops.length; - for (uint256 i = 0; i < opslen; i++) { - UserOpInfo memory opInfo = opInfos[opIndex]; - ( - uint256 validationData, - uint256 paymasterValidationData - ) = _validatePrepayment(opIndex, ops[i], opInfo); - _validateAccountAndPaymasterValidationData( - i, - validationData, - paymasterValidationData, - address(aggregator) - ); - opIndex++; - } - } - - emit BeforeExecution(); - - uint256 collected = 0; - opIndex = 0; - for (uint256 a = 0; a < opasLen; a++) { - UserOpsPerAggregator calldata opa = opsPerAggregator[a]; - emit SignatureAggregatorChanged(address(opa.aggregator)); - PackedUserOperation[] calldata ops = opa.userOps; - uint256 opslen = ops.length; - - for (uint256 i = 0; i < opslen; i++) { - collected += _executeUserOp(opIndex, ops[i], opInfos[opIndex]); - opIndex++; - } - } - emit SignatureAggregatorChanged(address(0)); - - _compensate(beneficiary, collected); - } - - /** - * A memory copy of UserOp static fields only. - * Excluding: callData, initCode and signature. Replacing paymasterAndData with paymaster. - */ - struct MemoryUserOp { - address sender; - uint256 nonce; - uint256 verificationGasLimit; - uint256 callGasLimit; - uint256 paymasterVerificationGasLimit; - uint256 paymasterPostOpGasLimit; - uint256 preVerificationGas; - address paymaster; - uint256 maxFeePerGas; - uint256 maxPriorityFeePerGas; - } - - struct UserOpInfo { - MemoryUserOp mUserOp; - bytes32 userOpHash; - uint256 prefund; - uint256 contextOffset; - uint256 preOpGas; - } - - /** - * Inner function to handle a UserOperation. - * Must be declared "external" to open a call context, but it can only be called by handleOps. - * @param callData - The callData to execute. - * @param opInfo - The UserOpInfo struct. - * @param context - The context bytes. - * @return actualGasCost - the actual cost in eth this UserOperation paid for gas - */ - function innerHandleOp( - bytes memory callData, - UserOpInfo memory opInfo, - bytes calldata context - ) external returns (uint256 actualGasCost) { - uint256 preGas = gasleft(); - require(msg.sender == address(this), "AA92 internal call only"); - MemoryUserOp memory mUserOp = opInfo.mUserOp; - - uint256 callGasLimit = mUserOp.callGasLimit; - unchecked { - // handleOps was called with gas limit too low. abort entire bundle. - if ( - gasleft() * 63 / 64 < - callGasLimit + - mUserOp.paymasterPostOpGasLimit + - INNER_GAS_OVERHEAD - ) { - assembly ("memory-safe") { - mstore(0, INNER_OUT_OF_GAS) - revert(0, 32) - } - } - } - - IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded; - if (callData.length > 0) { - bool success = Exec.call(mUserOp.sender, 0, callData, callGasLimit); - if (!success) { - bytes memory result = Exec.getReturnData(REVERT_REASON_MAX_LEN); - if (result.length > 0) { - emit UserOperationRevertReason( - opInfo.userOpHash, - mUserOp.sender, - mUserOp.nonce, - result - ); - } - mode = IPaymaster.PostOpMode.opReverted; - } - } - - unchecked { - uint256 actualGas = preGas - gasleft() + opInfo.preOpGas; - return _postExecution(mode, opInfo, context, actualGas); - } - } - - /// @inheritdoc IEntryPoint - function getUserOpHash( - PackedUserOperation calldata userOp - ) public view returns (bytes32) { - return - keccak256(abi.encode(userOp.hash(), address(this), block.chainid)); - } - - /** - * Copy general fields from userOp into the memory opInfo structure. - * @param userOp - The user operation. - * @param mUserOp - The memory user operation. - */ - function _copyUserOpToMemory( - PackedUserOperation calldata userOp, - MemoryUserOp memory mUserOp - ) internal pure { - mUserOp.sender = userOp.sender; - mUserOp.nonce = userOp.nonce; - (mUserOp.verificationGasLimit, mUserOp.callGasLimit) = UserOperationLib.unpackUints(userOp.accountGasLimits); - mUserOp.preVerificationGas = userOp.preVerificationGas; - (mUserOp.maxPriorityFeePerGas, mUserOp.maxFeePerGas) = UserOperationLib.unpackUints(userOp.gasFees); - bytes calldata paymasterAndData = userOp.paymasterAndData; - if (paymasterAndData.length > 0) { - require( - paymasterAndData.length >= UserOperationLib.PAYMASTER_DATA_OFFSET, - "AA93 invalid paymasterAndData" - ); - (mUserOp.paymaster, mUserOp.paymasterVerificationGasLimit, mUserOp.paymasterPostOpGasLimit) = UserOperationLib.unpackPaymasterStaticFields(paymasterAndData); - } else { - mUserOp.paymaster = address(0); - mUserOp.paymasterVerificationGasLimit = 0; - mUserOp.paymasterPostOpGasLimit = 0; - } - } - - /** - * Get the required prefunded gas fee amount for an operation. - * @param mUserOp - The user operation in memory. - */ - function _getRequiredPrefund( - MemoryUserOp memory mUserOp - ) internal pure returns (uint256 requiredPrefund) { - unchecked { - uint256 requiredGas = mUserOp.verificationGasLimit + - mUserOp.callGasLimit + - mUserOp.paymasterVerificationGasLimit + - mUserOp.paymasterPostOpGasLimit + - mUserOp.preVerificationGas; - - requiredPrefund = requiredGas * mUserOp.maxFeePerGas; - } - } - - /** - * Create sender smart contract account if init code is provided. - * @param opIndex - The operation index. - * @param opInfo - The operation info. - * @param initCode - The init code for the smart contract account. - */ - function _createSenderIfNeeded( - uint256 opIndex, - UserOpInfo memory opInfo, - bytes calldata initCode - ) internal { - if (initCode.length != 0) { - address sender = opInfo.mUserOp.sender; - if (sender.code.length != 0) - revert FailedOp(opIndex, "AA10 sender already constructed"); - address sender1 = senderCreator().createSender{ - gas: opInfo.mUserOp.verificationGasLimit - }(initCode); - if (sender1 == address(0)) - revert FailedOp(opIndex, "AA13 initCode failed or OOG"); - if (sender1 != sender) - revert FailedOp(opIndex, "AA14 initCode must return sender"); - if (sender1.code.length == 0) - revert FailedOp(opIndex, "AA15 initCode must create sender"); - address factory = address(bytes20(initCode[0:20])); - emit AccountDeployed( - opInfo.userOpHash, - sender, - factory, - opInfo.mUserOp.paymaster - ); - } - } - - /// @inheritdoc IEntryPoint - function getSenderAddress(bytes calldata initCode) public { - address sender = senderCreator().createSender(initCode); - revert SenderAddressResult(sender); - } - - /** - * Call account.validateUserOp. - * Revert (with FailedOp) in case validateUserOp reverts, or account didn't send required prefund. - * Decrement account's deposit if needed. - * @param opIndex - The operation index. - * @param op - The user operation. - * @param opInfo - The operation info. - * @param requiredPrefund - The required prefund amount. - */ - function _validateAccountPrepayment( - uint256 opIndex, - PackedUserOperation calldata op, - UserOpInfo memory opInfo, - uint256 requiredPrefund, - uint256 verificationGasLimit - ) - internal - returns ( - uint256 validationData - ) - { - unchecked { - MemoryUserOp memory mUserOp = opInfo.mUserOp; - address sender = mUserOp.sender; - _createSenderIfNeeded(opIndex, opInfo, op.initCode); - address paymaster = mUserOp.paymaster; - uint256 missingAccountFunds = 0; - if (paymaster == address(0)) { - uint256 bal = balanceOf(sender); - missingAccountFunds = bal > requiredPrefund - ? 0 - : requiredPrefund - bal; - } - try - IAccount(sender).validateUserOp{ - gas: verificationGasLimit - }(op, opInfo.userOpHash, missingAccountFunds) - returns (uint256 _validationData) { - validationData = _validationData; - } catch { - revert FailedOpWithRevert(opIndex, "AA23 reverted", Exec.getReturnData(REVERT_REASON_MAX_LEN)); - } - if (paymaster == address(0)) { - DepositInfo storage senderInfo = deposits[sender]; - uint256 deposit = senderInfo.deposit; - if (requiredPrefund > deposit) { - revert FailedOp(opIndex, "AA21 didn't pay prefund"); - } - senderInfo.deposit = deposit - requiredPrefund; - } - } - } - - /** - * In case the request has a paymaster: - * - Validate paymaster has enough deposit. - * - Call paymaster.validatePaymasterUserOp. - * - Revert with proper FailedOp in case paymaster reverts. - * - Decrement paymaster's deposit. - * @param opIndex - The operation index. - * @param op - The user operation. - * @param opInfo - The operation info. - * @param requiredPreFund - The required prefund amount. - */ - function _validatePaymasterPrepayment( - uint256 opIndex, - PackedUserOperation calldata op, - UserOpInfo memory opInfo, - uint256 requiredPreFund - ) internal returns (bytes memory context, uint256 validationData) { - unchecked { - uint256 preGas = gasleft(); - MemoryUserOp memory mUserOp = opInfo.mUserOp; - address paymaster = mUserOp.paymaster; - DepositInfo storage paymasterInfo = deposits[paymaster]; - uint256 deposit = paymasterInfo.deposit; - if (deposit < requiredPreFund) { - revert FailedOp(opIndex, "AA31 paymaster deposit too low"); - } - paymasterInfo.deposit = deposit - requiredPreFund; - uint256 pmVerificationGasLimit = mUserOp.paymasterVerificationGasLimit; - try - IPaymaster(paymaster).validatePaymasterUserOp{gas: pmVerificationGasLimit}( - op, - opInfo.userOpHash, - requiredPreFund - ) - returns (bytes memory _context, uint256 _validationData) { - context = _context; - validationData = _validationData; - } catch { - revert FailedOpWithRevert(opIndex, "AA33 reverted", Exec.getReturnData(REVERT_REASON_MAX_LEN)); - } - if (preGas - gasleft() > pmVerificationGasLimit) { - revert FailedOp(opIndex, "AA36 over paymasterVerificationGasLimit"); - } - } - } - - /** - * Revert if either account validationData or paymaster validationData is expired. - * @param opIndex - The operation index. - * @param validationData - The account validationData. - * @param paymasterValidationData - The paymaster validationData. - * @param expectedAggregator - The expected aggregator. - */ - function _validateAccountAndPaymasterValidationData( - uint256 opIndex, - uint256 validationData, - uint256 paymasterValidationData, - address expectedAggregator - ) internal view { - (address aggregator, bool outOfTimeRange) = _getValidationData( - validationData - ); - if (expectedAggregator != aggregator) { - revert FailedOp(opIndex, "AA24 signature error"); - } - if (outOfTimeRange) { - revert FailedOp(opIndex, "AA22 expired or not due"); - } - // pmAggregator is not a real signature aggregator: we don't have logic to handle it as address. - // Non-zero address means that the paymaster fails due to some signature check (which is ok only during estimation). - address pmAggregator; - (pmAggregator, outOfTimeRange) = _getValidationData( - paymasterValidationData - ); - if (pmAggregator != address(0)) { - revert FailedOp(opIndex, "AA34 signature error"); - } - if (outOfTimeRange) { - revert FailedOp(opIndex, "AA32 paymaster expired or not due"); - } - } - - /** - * Parse validationData into its components. - * @param validationData - The packed validation data (sigFailed, validAfter, validUntil). - * @return aggregator the aggregator of the validationData - * @return outOfTimeRange true if current time is outside the time range of this validationData. - */ - function _getValidationData( - uint256 validationData - ) internal view returns (address aggregator, bool outOfTimeRange) { - if (validationData == 0) { - return (address(0), false); - } - ValidationData memory data = _parseValidationData(validationData); - // solhint-disable-next-line not-rely-on-time - outOfTimeRange = block.timestamp > data.validUntil || block.timestamp < data.validAfter; - aggregator = data.aggregator; - } - - /** - * Validate account and paymaster (if defined) and - * also make sure total validation doesn't exceed verificationGasLimit. - * This method is called off-chain (simulateValidation()) and on-chain (from handleOps) - * @param opIndex - The index of this userOp into the "opInfos" array. - * @param userOp - The userOp to validate. - */ - function _validatePrepayment( - uint256 opIndex, - PackedUserOperation calldata userOp, - UserOpInfo memory outOpInfo - ) - internal - returns (uint256 validationData, uint256 paymasterValidationData) - { - uint256 preGas = gasleft(); - MemoryUserOp memory mUserOp = outOpInfo.mUserOp; - _copyUserOpToMemory(userOp, mUserOp); - outOpInfo.userOpHash = getUserOpHash(userOp); - - // Validate all numeric values in userOp are well below 128 bit, so they can safely be added - // and multiplied without causing overflow. - uint256 verificationGasLimit = mUserOp.verificationGasLimit; - uint256 maxGasValues = mUserOp.preVerificationGas | - verificationGasLimit | - mUserOp.callGasLimit | - mUserOp.paymasterVerificationGasLimit | - mUserOp.paymasterPostOpGasLimit | - mUserOp.maxFeePerGas | - mUserOp.maxPriorityFeePerGas; - require(maxGasValues <= type(uint120).max, "AA94 gas values overflow"); - - uint256 requiredPreFund = _getRequiredPrefund(mUserOp); - validationData = _validateAccountPrepayment( - opIndex, - userOp, - outOpInfo, - requiredPreFund, - verificationGasLimit - ); - - if (!_validateAndUpdateNonce(mUserOp.sender, mUserOp.nonce)) { - revert FailedOp(opIndex, "AA25 invalid account nonce"); - } - - unchecked { - if (preGas - gasleft() > verificationGasLimit) { - revert FailedOp(opIndex, "AA26 over verificationGasLimit"); - } - } - - bytes memory context; - if (mUserOp.paymaster != address(0)) { - (context, paymasterValidationData) = _validatePaymasterPrepayment( - opIndex, - userOp, - outOpInfo, - requiredPreFund - ); - } - unchecked { - outOpInfo.prefund = requiredPreFund; - outOpInfo.contextOffset = getOffsetOfMemoryBytes(context); - outOpInfo.preOpGas = preGas - gasleft() + userOp.preVerificationGas; - } - } - - /** - * Process post-operation, called just after the callData is executed. - * If a paymaster is defined and its validation returned a non-empty context, its postOp is called. - * The excess amount is refunded to the account (or paymaster - if it was used in the request). - * @param mode - Whether is called from innerHandleOp, or outside (postOpReverted). - * @param opInfo - UserOp fields and info collected during validation. - * @param context - The context returned in validatePaymasterUserOp. - * @param actualGas - The gas used so far by this user operation. - */ - function _postExecution( - IPaymaster.PostOpMode mode, - UserOpInfo memory opInfo, - bytes memory context, - uint256 actualGas - ) private returns (uint256 actualGasCost) { - uint256 preGas = gasleft(); - unchecked { - address refundAddress; - MemoryUserOp memory mUserOp = opInfo.mUserOp; - uint256 gasPrice = getUserOpGasPrice(mUserOp); - - address paymaster = mUserOp.paymaster; - if (paymaster == address(0)) { - refundAddress = mUserOp.sender; - } else { - refundAddress = paymaster; - if (context.length > 0) { - actualGasCost = actualGas * gasPrice; - if (mode != IPaymaster.PostOpMode.postOpReverted) { - try IPaymaster(paymaster).postOp{ - gas: mUserOp.paymasterPostOpGasLimit - }(mode, context, actualGasCost, gasPrice) - // solhint-disable-next-line no-empty-blocks - {} catch { - bytes memory reason = Exec.getReturnData(REVERT_REASON_MAX_LEN); - revert PostOpReverted(reason); - } - } - } - } - actualGas += preGas - gasleft(); - - // Calculating a penalty for unused execution gas - { - uint256 executionGasLimit = mUserOp.callGasLimit + mUserOp.paymasterPostOpGasLimit; - uint256 executionGasUsed = actualGas - opInfo.preOpGas; - // this check is required for the gas used within EntryPoint and not covered by explicit gas limits - if (executionGasLimit > executionGasUsed) { - uint256 unusedGas = executionGasLimit - executionGasUsed; - uint256 unusedGasPenalty = (unusedGas * PENALTY_PERCENT) / 100; - actualGas += unusedGasPenalty; - } - } - - actualGasCost = actualGas * gasPrice; - uint256 prefund = opInfo.prefund; - if (prefund < actualGasCost) { - if (mode == IPaymaster.PostOpMode.postOpReverted) { - actualGasCost = prefund; - emitPrefundTooLow(opInfo); - emitUserOperationEvent(opInfo, false, actualGasCost, actualGas); - } else { - assembly ("memory-safe") { - mstore(0, INNER_REVERT_LOW_PREFUND) - revert(0, 32) - } - } - } else { - uint256 refund = prefund - actualGasCost; - _incrementDeposit(refundAddress, refund); - bool success = mode == IPaymaster.PostOpMode.opSucceeded; - emitUserOperationEvent(opInfo, success, actualGasCost, actualGas); - } - } // unchecked - } - - /** - * The gas price this UserOp agrees to pay. - * Relayer/block builder might submit the TX with higher priorityFee, but the user should not. - * @param mUserOp - The userOp to get the gas price from. - */ - function getUserOpGasPrice( - MemoryUserOp memory mUserOp - ) internal view returns (uint256) { - unchecked { - uint256 maxFeePerGas = mUserOp.maxFeePerGas; - uint256 maxPriorityFeePerGas = mUserOp.maxPriorityFeePerGas; - if (maxFeePerGas == maxPriorityFeePerGas) { - //legacy mode (for networks that don't support basefee opcode) - return maxFeePerGas; - } - return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee); - } - } - - /** - * The offset of the given bytes in memory. - * @param data - The bytes to get the offset of. - */ - function getOffsetOfMemoryBytes( - bytes memory data - ) internal pure returns (uint256 offset) { - assembly { - offset := data - } - } - - /** - * The bytes in memory at the given offset. - * @param offset - The offset to get the bytes from. - */ - function getMemoryBytesFromOffset( - uint256 offset - ) internal pure returns (bytes memory data) { - assembly ("memory-safe") { - data := offset - } - } - - /// @inheritdoc IEntryPoint - function delegateAndRevert(address target, bytes calldata data) external { - (bool success, bytes memory ret) = target.delegatecall(data); - revert DelegateAndRevert(success, ret); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/EntryPointSimulations.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/EntryPointSimulations.sol deleted file mode 100644 index b8c41ea12c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/EntryPointSimulations.sol +++ /dev/null @@ -1,190 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -/* solhint-disable avoid-low-level-calls */ -/* solhint-disable no-inline-assembly */ - -import "./EntryPoint.sol"; -import "../interfaces/IEntryPointSimulations.sol"; - -/* - * This contract inherits the EntryPoint and extends it with the view-only methods that are executed by - * the bundler in order to check UserOperation validity and estimate its gas consumption. - * This contract should never be deployed on-chain and is only used as a parameter for the "eth_call" request. - */ -contract EntryPointSimulations is EntryPoint, IEntryPointSimulations { - // solhint-disable-next-line var-name-mixedcase - AggregatorStakeInfo private NOT_AGGREGATED = AggregatorStakeInfo(address(0), StakeInfo(0, 0)); - - SenderCreator private _senderCreator; - - function initSenderCreator() internal virtual { - //this is the address of the first contract created with CREATE by this address. - address createdObj = address(uint160(uint256(keccak256(abi.encodePacked(hex"d694", address(this), hex"01"))))); - _senderCreator = SenderCreator(createdObj); - } - - function senderCreator() internal view virtual override returns (SenderCreator) { - // return the same senderCreator as real EntryPoint. - // this call is slightly (100) more expensive than EntryPoint's access to immutable member - return _senderCreator; - } - - /** - * simulation contract should not be deployed, and specifically, accounts should not trust - * it as entrypoint, since the simulation functions don't check the signatures - */ - constructor() { - require(block.number < 100, "should not be deployed"); - } - - /// @inheritdoc IEntryPointSimulations - function simulateValidation( - PackedUserOperation calldata userOp - ) - external - returns ( - ValidationResult memory - ){ - UserOpInfo memory outOpInfo; - - _simulationOnlyValidations(userOp); - ( - uint256 validationData, - uint256 paymasterValidationData - ) = _validatePrepayment(0, userOp, outOpInfo); - StakeInfo memory paymasterInfo = _getStakeInfo( - outOpInfo.mUserOp.paymaster - ); - StakeInfo memory senderInfo = _getStakeInfo(outOpInfo.mUserOp.sender); - StakeInfo memory factoryInfo; - { - bytes calldata initCode = userOp.initCode; - address factory = initCode.length >= 20 - ? address(bytes20(initCode[0 : 20])) - : address(0); - factoryInfo = _getStakeInfo(factory); - } - - address aggregator = address(uint160(validationData)); - ReturnInfo memory returnInfo = ReturnInfo( - outOpInfo.preOpGas, - outOpInfo.prefund, - validationData, - paymasterValidationData, - getMemoryBytesFromOffset(outOpInfo.contextOffset) - ); - - AggregatorStakeInfo memory aggregatorInfo = NOT_AGGREGATED; - if (uint160(aggregator) != SIG_VALIDATION_SUCCESS && uint160(aggregator) != SIG_VALIDATION_FAILED) { - aggregatorInfo = AggregatorStakeInfo( - aggregator, - _getStakeInfo(aggregator) - ); - } - return ValidationResult( - returnInfo, - senderInfo, - factoryInfo, - paymasterInfo, - aggregatorInfo - ); - } - - /// @inheritdoc IEntryPointSimulations - function simulateHandleOp( - PackedUserOperation calldata op, - address target, - bytes calldata targetCallData - ) - external nonReentrant - returns ( - ExecutionResult memory - ){ - UserOpInfo memory opInfo; - _simulationOnlyValidations(op); - ( - uint256 validationData, - uint256 paymasterValidationData - ) = _validatePrepayment(0, op, opInfo); - - uint256 paid = _executeUserOp(0, op, opInfo); - bool targetSuccess; - bytes memory targetResult; - if (target != address(0)) { - (targetSuccess, targetResult) = target.call(targetCallData); - } - return ExecutionResult( - opInfo.preOpGas, - paid, - validationData, - paymasterValidationData, - targetSuccess, - targetResult - ); - } - - function _simulationOnlyValidations( - PackedUserOperation calldata userOp - ) - internal - { - //initialize senderCreator(). we can't rely on constructor - initSenderCreator(); - - try - this._validateSenderAndPaymaster( - userOp.initCode, - userOp.sender, - userOp.paymasterAndData - ) - // solhint-disable-next-line no-empty-blocks - {} catch Error(string memory revertReason) { - if (bytes(revertReason).length != 0) { - revert FailedOp(0, revertReason); - } - } - } - - /** - * Called only during simulation. - * This function always reverts to prevent warm/cold storage differentiation in simulation vs execution. - * @param initCode - The smart account constructor code. - * @param sender - The sender address. - * @param paymasterAndData - The paymaster address (followed by other params, ignored by this method) - */ - function _validateSenderAndPaymaster( - bytes calldata initCode, - address sender, - bytes calldata paymasterAndData - ) external view { - if (initCode.length == 0 && sender.code.length == 0) { - // it would revert anyway. but give a meaningful message - revert("AA20 account not deployed"); - } - if (paymasterAndData.length >= 20) { - address paymaster = address(bytes20(paymasterAndData[0 : 20])); - if (paymaster.code.length == 0) { - // It would revert anyway. but give a meaningful message. - revert("AA30 paymaster not deployed"); - } - } - // always revert - revert(""); - } - - //make sure depositTo cost is more than normal EntryPoint's cost, - // to mitigate DoS vector on the bundler - // empiric test showed that without this wrapper, simulation depositTo costs less.. - function depositTo(address account) public override(IStakeManager, StakeManager) payable { - unchecked{ - // silly code, to waste some gas to make sure depositTo is always little more - // expensive than on-chain call - uint256 x = 1; - while (x < 5) { - x++; - } - StakeManager.depositTo(account); - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/Helpers.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/Helpers.sol deleted file mode 100644 index 8579008613..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/Helpers.sol +++ /dev/null @@ -1,106 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -/* solhint-disable no-inline-assembly */ - - - /* - * For simulation purposes, validateUserOp (and validatePaymasterUserOp) - * must return this value in case of signature failure, instead of revert. - */ -uint256 constant SIG_VALIDATION_FAILED = 1; - - -/* - * For simulation purposes, validateUserOp (and validatePaymasterUserOp) - * return this value on success. - */ -uint256 constant SIG_VALIDATION_SUCCESS = 0; - - -/** - * Returned data from validateUserOp. - * validateUserOp returns a uint256, which is created by `_packedValidationData` and - * parsed by `_parseValidationData`. - * @param aggregator - address(0) - The account validated the signature by itself. - * address(1) - The account failed to validate the signature. - * otherwise - This is an address of a signature aggregator that must - * be used to validate the signature. - * @param validAfter - This UserOp is valid only after this timestamp. - * @param validaUntil - This UserOp is valid only up to this timestamp. - */ -struct ValidationData { - address aggregator; - uint48 validAfter; - uint48 validUntil; -} - -/** - * Extract sigFailed, validAfter, validUntil. - * Also convert zero validUntil to type(uint48).max. - * @param validationData - The packed validation data. - */ -function _parseValidationData( - uint256 validationData -) pure returns (ValidationData memory data) { - address aggregator = address(uint160(validationData)); - uint48 validUntil = uint48(validationData >> 160); - if (validUntil == 0) { - validUntil = type(uint48).max; - } - uint48 validAfter = uint48(validationData >> (48 + 160)); - return ValidationData(aggregator, validAfter, validUntil); -} - -/** - * Helper to pack the return value for validateUserOp. - * @param data - The ValidationData to pack. - */ -function _packValidationData( - ValidationData memory data -) pure returns (uint256) { - return - uint160(data.aggregator) | - (uint256(data.validUntil) << 160) | - (uint256(data.validAfter) << (160 + 48)); -} - -/** - * Helper to pack the return value for validateUserOp, when not using an aggregator. - * @param sigFailed - True for signature failure, false for success. - * @param validUntil - Last timestamp this UserOperation is valid (or zero for infinite). - * @param validAfter - First timestamp this UserOperation is valid. - */ -function _packValidationData( - bool sigFailed, - uint48 validUntil, - uint48 validAfter -) pure returns (uint256) { - return - (sigFailed ? 1 : 0) | - (uint256(validUntil) << 160) | - (uint256(validAfter) << (160 + 48)); -} - -/** - * keccak function over calldata. - * @dev copy calldata into memory, do keccak and drop allocated memory. Strangely, this is more efficient than letting solidity do it. - */ - function calldataKeccak(bytes calldata data) pure returns (bytes32 ret) { - assembly ("memory-safe") { - let mem := mload(0x40) - let len := data.length - calldatacopy(mem, data.offset, len) - ret := keccak256(mem, len) - } - } - - -/** - * The minimum of two numbers. - * @param a - First number. - * @param b - Second number. - */ - function min(uint256 a, uint256 b) pure returns (uint256) { - return a < b ? a : b; - } diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/NonceManager.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/NonceManager.sol deleted file mode 100644 index 7bef62e99d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/NonceManager.sol +++ /dev/null @@ -1,43 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -import "../interfaces/INonceManager.sol"; - -/** - * nonce management functionality - */ -abstract contract NonceManager is INonceManager { - - /** - * The next valid sequence number for a given nonce key. - */ - mapping(address => mapping(uint192 => uint256)) public nonceSequenceNumber; - - /// @inheritdoc INonceManager - function getNonce(address sender, uint192 key) - public view override returns (uint256 nonce) { - return nonceSequenceNumber[sender][key] | (uint256(key) << 64); - } - - // allow an account to manually increment its own nonce. - // (mainly so that during construction nonce can be made non-zero, - // to "absorb" the gas cost of first nonce increment to 1st transaction (construction), - // not to 2nd transaction) - function incrementNonce(uint192 key) public override { - nonceSequenceNumber[msg.sender][key]++; - } - - /** - * validate nonce uniqueness for this account. - * called just after validateUserOp() - * @return true if the nonce was incremented successfully. - * false if the current nonce doesn't match the given one. - */ - function _validateAndUpdateNonce(address sender, uint256 nonce) internal returns (bool) { - - uint192 key = uint192(nonce >> 64); - uint64 seq = uint64(nonce); - return nonceSequenceNumber[sender][key]++ == seq; - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/SenderCreator.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/SenderCreator.sol deleted file mode 100644 index 43ea80367e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/SenderCreator.sol +++ /dev/null @@ -1,38 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -/** - * Helper contract for EntryPoint, to call userOp.initCode from a "neutral" address, - * which is explicitly not the entryPoint itself. - */ -contract SenderCreator { - /** - * Call the "initCode" factory to create and return the sender account address. - * @param initCode - The initCode value from a UserOp. contains 20 bytes of factory address, - * followed by calldata. - * @return sender - The returned address of the created account, or zero address on failure. - */ - function createSender( - bytes calldata initCode - ) external returns (address sender) { - address factory = address(bytes20(initCode[0:20])); - bytes memory initCallData = initCode[20:]; - bool success; - /* solhint-disable no-inline-assembly */ - assembly ("memory-safe") { - success := call( - gas(), - factory, - 0, - add(initCallData, 0x20), - mload(initCallData), - 0, - 32 - ) - sender := mload(0) - } - if (!success) { - sender = address(0); - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/StakeManager.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/StakeManager.sol deleted file mode 100644 index f90210b7e3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/StakeManager.sol +++ /dev/null @@ -1,145 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0-only -pragma solidity ^0.8.23; - -import "../interfaces/IStakeManager.sol"; - -/* solhint-disable avoid-low-level-calls */ -/* solhint-disable not-rely-on-time */ - -/** - * Manage deposits and stakes. - * Deposit is just a balance used to pay for UserOperations (either by a paymaster or an account). - * Stake is value locked for at least "unstakeDelay" by a paymaster. - */ -abstract contract StakeManager is IStakeManager { - /// maps paymaster to their deposits and stakes - mapping(address => DepositInfo) public deposits; - - /// @inheritdoc IStakeManager - function getDepositInfo( - address account - ) public view returns (DepositInfo memory info) { - return deposits[account]; - } - - /** - * Internal method to return just the stake info. - * @param addr - The account to query. - */ - function _getStakeInfo( - address addr - ) internal view returns (StakeInfo memory info) { - DepositInfo storage depositInfo = deposits[addr]; - info.stake = depositInfo.stake; - info.unstakeDelaySec = depositInfo.unstakeDelaySec; - } - - /// @inheritdoc IStakeManager - function balanceOf(address account) public view returns (uint256) { - return deposits[account].deposit; - } - - receive() external payable { - depositTo(msg.sender); - } - - /** - * Increments an account's deposit. - * @param account - The account to increment. - * @param amount - The amount to increment by. - * @return the updated deposit of this account - */ - function _incrementDeposit(address account, uint256 amount) internal returns (uint256) { - DepositInfo storage info = deposits[account]; - uint256 newAmount = info.deposit + amount; - info.deposit = newAmount; - return newAmount; - } - - /** - * Add to the deposit of the given account. - * @param account - The account to add to. - */ - function depositTo(address account) public virtual payable { - uint256 newDeposit = _incrementDeposit(account, msg.value); - emit Deposited(account, newDeposit); - } - - /** - * Add to the account's stake - amount and delay - * any pending unstake is first cancelled. - * @param unstakeDelaySec The new lock duration before the deposit can be withdrawn. - */ - function addStake(uint32 unstakeDelaySec) public payable { - DepositInfo storage info = deposits[msg.sender]; - require(unstakeDelaySec > 0, "must specify unstake delay"); - require( - unstakeDelaySec >= info.unstakeDelaySec, - "cannot decrease unstake time" - ); - uint256 stake = info.stake + msg.value; - require(stake > 0, "no stake specified"); - require(stake <= type(uint112).max, "stake overflow"); - deposits[msg.sender] = DepositInfo( - info.deposit, - true, - uint112(stake), - unstakeDelaySec, - 0 - ); - emit StakeLocked(msg.sender, stake, unstakeDelaySec); - } - - /** - * Attempt to unlock the stake. - * The value can be withdrawn (using withdrawStake) after the unstake delay. - */ - function unlockStake() external { - DepositInfo storage info = deposits[msg.sender]; - require(info.unstakeDelaySec != 0, "not staked"); - require(info.staked, "already unstaking"); - uint48 withdrawTime = uint48(block.timestamp) + info.unstakeDelaySec; - info.withdrawTime = withdrawTime; - info.staked = false; - emit StakeUnlocked(msg.sender, withdrawTime); - } - - /** - * Withdraw from the (unlocked) stake. - * Must first call unlockStake and wait for the unstakeDelay to pass. - * @param withdrawAddress - The address to send withdrawn value. - */ - function withdrawStake(address payable withdrawAddress) external { - DepositInfo storage info = deposits[msg.sender]; - uint256 stake = info.stake; - require(stake > 0, "No stake to withdraw"); - require(info.withdrawTime > 0, "must call unlockStake() first"); - require( - info.withdrawTime <= block.timestamp, - "Stake withdrawal is not due" - ); - info.unstakeDelaySec = 0; - info.withdrawTime = 0; - info.stake = 0; - emit StakeWithdrawn(msg.sender, withdrawAddress, stake); - (bool success,) = withdrawAddress.call{value: stake}(""); - require(success, "failed to withdraw stake"); - } - - /** - * Withdraw from the deposit. - * @param withdrawAddress - The address to send withdrawn value. - * @param withdrawAmount - The amount to withdraw. - */ - function withdrawTo( - address payable withdrawAddress, - uint256 withdrawAmount - ) external { - DepositInfo storage info = deposits[msg.sender]; - require(withdrawAmount <= info.deposit, "Withdraw amount too large"); - info.deposit = info.deposit - withdrawAmount; - emit Withdrawn(msg.sender, withdrawAddress, withdrawAmount); - (bool success,) = withdrawAddress.call{value: withdrawAmount}(""); - require(success, "failed to withdraw"); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/UserOperationLib.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/UserOperationLib.sol deleted file mode 100644 index dcf5740cc2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/core/UserOperationLib.sol +++ /dev/null @@ -1,139 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -/* solhint-disable no-inline-assembly */ - -import "../interfaces/PackedUserOperation.sol"; -import {calldataKeccak, min} from "./Helpers.sol"; - -/** - * Utility functions helpful when working with UserOperation structs. - */ -library UserOperationLib { - - uint256 public constant PAYMASTER_VALIDATION_GAS_OFFSET = 20; - uint256 public constant PAYMASTER_POSTOP_GAS_OFFSET = 36; - uint256 public constant PAYMASTER_DATA_OFFSET = 52; - /** - * Get sender from user operation data. - * @param userOp - The user operation data. - */ - function getSender( - PackedUserOperation calldata userOp - ) internal pure returns (address) { - address data; - //read sender from userOp, which is first userOp member (saves 800 gas...) - assembly { - data := calldataload(userOp) - } - return address(uint160(data)); - } - - /** - * Relayer/block builder might submit the TX with higher priorityFee, - * but the user should not pay above what he signed for. - * @param userOp - The user operation data. - */ - function gasPrice( - PackedUserOperation calldata userOp - ) internal view returns (uint256) { - unchecked { - (uint256 maxPriorityFeePerGas, uint256 maxFeePerGas) = unpackUints(userOp.gasFees); - if (maxFeePerGas == maxPriorityFeePerGas) { - //legacy mode (for networks that don't support basefee opcode) - return maxFeePerGas; - } - return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee); - } - } - - /** - * Pack the user operation data into bytes for hashing. - * @param userOp - The user operation data. - */ - function encode( - PackedUserOperation calldata userOp - ) internal pure returns (bytes memory ret) { - address sender = getSender(userOp); - uint256 nonce = userOp.nonce; - bytes32 hashInitCode = calldataKeccak(userOp.initCode); - bytes32 hashCallData = calldataKeccak(userOp.callData); - bytes32 accountGasLimits = userOp.accountGasLimits; - uint256 preVerificationGas = userOp.preVerificationGas; - bytes32 gasFees = userOp.gasFees; - bytes32 hashPaymasterAndData = calldataKeccak(userOp.paymasterAndData); - - return abi.encode( - sender, nonce, - hashInitCode, hashCallData, - accountGasLimits, preVerificationGas, gasFees, - hashPaymasterAndData - ); - } - - function unpackUints( - bytes32 packed - ) internal pure returns (uint256 high128, uint256 low128) { - return (uint128(bytes16(packed)), uint128(uint256(packed))); - } - - //unpack just the high 128-bits from a packed value - function unpackHigh128(bytes32 packed) internal pure returns (uint256) { - return uint256(packed) >> 128; - } - - // unpack just the low 128-bits from a packed value - function unpackLow128(bytes32 packed) internal pure returns (uint256) { - return uint128(uint256(packed)); - } - - function unpackMaxPriorityFeePerGas(PackedUserOperation calldata userOp) - internal pure returns (uint256) { - return unpackHigh128(userOp.gasFees); - } - - function unpackMaxFeePerGas(PackedUserOperation calldata userOp) - internal pure returns (uint256) { - return unpackLow128(userOp.gasFees); - } - - function unpackVerificationGasLimit(PackedUserOperation calldata userOp) - internal pure returns (uint256) { - return unpackHigh128(userOp.accountGasLimits); - } - - function unpackCallGasLimit(PackedUserOperation calldata userOp) - internal pure returns (uint256) { - return unpackLow128(userOp.accountGasLimits); - } - - function unpackPaymasterVerificationGasLimit(PackedUserOperation calldata userOp) - internal pure returns (uint256) { - return uint128(bytes16(userOp.paymasterAndData[PAYMASTER_VALIDATION_GAS_OFFSET : PAYMASTER_POSTOP_GAS_OFFSET])); - } - - function unpackPostOpGasLimit(PackedUserOperation calldata userOp) - internal pure returns (uint256) { - return uint128(bytes16(userOp.paymasterAndData[PAYMASTER_POSTOP_GAS_OFFSET : PAYMASTER_DATA_OFFSET])); - } - - function unpackPaymasterStaticFields( - bytes calldata paymasterAndData - ) internal pure returns (address paymaster, uint256 validationGasLimit, uint256 postOpGasLimit) { - return ( - address(bytes20(paymasterAndData[: PAYMASTER_VALIDATION_GAS_OFFSET])), - uint128(bytes16(paymasterAndData[PAYMASTER_VALIDATION_GAS_OFFSET : PAYMASTER_POSTOP_GAS_OFFSET])), - uint128(bytes16(paymasterAndData[PAYMASTER_POSTOP_GAS_OFFSET : PAYMASTER_DATA_OFFSET])) - ); - } - - /** - * Hash the user operation data. - * @param userOp - The user operation data. - */ - function hash( - PackedUserOperation calldata userOp - ) internal pure returns (bytes32) { - return keccak256(encode(userOp)); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IAccount.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IAccount.sol deleted file mode 100644 index e3b355fbc2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IAccount.sol +++ /dev/null @@ -1,39 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity >=0.7.5; - -import "./PackedUserOperation.sol"; - -interface IAccount { - /** - * Validate user's signature and nonce - * the entryPoint will make the call to the recipient only if this validation call returns successfully. - * signature failure should be reported by returning SIG_VALIDATION_FAILED (1). - * This allows making a "simulation call" without a valid signature - * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure. - * - * @dev Must validate caller is the entryPoint. - * Must validate the signature and nonce - * @param userOp - The operation that is about to be executed. - * @param userOpHash - Hash of the user's request data. can be used as the basis for signature. - * @param missingAccountFunds - Missing funds on the account's deposit in the entrypoint. - * This is the minimum amount to transfer to the sender(entryPoint) to be - * able to make the call. The excess is left as a deposit in the entrypoint - * for future calls. Can be withdrawn anytime using "entryPoint.withdrawTo()". - * In case there is a paymaster in the request (or the current deposit is high - * enough), this value will be zero. - * @return validationData - Packaged ValidationData structure. use `_packValidationData` and - * `_unpackValidationData` to encode and decode. - * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure, - * otherwise, an address of an "authorizer" contract. - * <6-byte> validUntil - Last timestamp this operation is valid. 0 for "indefinite" - * <6-byte> validAfter - First timestamp this operation is valid - * If an account doesn't use time-range, it is enough to - * return SIG_VALIDATION_FAILED value (1) for signature failure. - * Note that the validation code cannot use block.timestamp (or block.number) directly. - */ - function validateUserOp( - PackedUserOperation calldata userOp, - bytes32 userOpHash, - uint256 missingAccountFunds - ) external returns (uint256 validationData); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IAccountExecute.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IAccountExecute.sol deleted file mode 100644 index 4433c80ce3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IAccountExecute.sol +++ /dev/null @@ -1,20 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity >=0.7.5; - -import "./PackedUserOperation.sol"; - -interface IAccountExecute { - /** - * Account may implement this execute method. - * passing this methodSig at the beginning of callData will cause the entryPoint to pass the full UserOp (and hash) - * to the account. - * The account should skip the methodSig, and use the callData (and optionally, other UserOp fields) - * - * @param userOp - The operation that was just validated. - * @param userOpHash - Hash of the user's request data. - */ - function executeUserOp( - PackedUserOperation calldata userOp, - bytes32 userOpHash - ) external; -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IAggregator.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IAggregator.sol deleted file mode 100644 index 070d8f27a2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IAggregator.sol +++ /dev/null @@ -1,44 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity >=0.7.5; - -import "./PackedUserOperation.sol"; - -/** - * Aggregated Signatures validator. - */ -interface IAggregator { - /** - * Validate aggregated signature. - * Revert if the aggregated signature does not match the given list of operations. - * @param userOps - Array of UserOperations to validate the signature for. - * @param signature - The aggregated signature. - */ - function validateSignatures( - PackedUserOperation[] calldata userOps, - bytes calldata signature - ) external view; - - /** - * Validate signature of a single userOp. - * This method should be called by bundler after EntryPointSimulation.simulateValidation() returns - * the aggregator this account uses. - * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps. - * @param userOp - The userOperation received from the user. - * @return sigForUserOp - The value to put into the signature field of the userOp when calling handleOps. - * (usually empty, unless account and aggregator support some kind of "multisig". - */ - function validateUserOpSignature( - PackedUserOperation calldata userOp - ) external view returns (bytes memory sigForUserOp); - - /** - * Aggregate multiple signatures into a single value. - * This method is called off-chain to calculate the signature to pass with handleOps() - * bundler MAY use optimized custom code perform this aggregation. - * @param userOps - Array of UserOperations to collect the signatures from. - * @return aggregatedSignature - The aggregated signature. - */ - function aggregateSignatures( - PackedUserOperation[] calldata userOps - ) external view returns (bytes memory aggregatedSignature); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IEntryPoint.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IEntryPoint.sol deleted file mode 100644 index 28c26f98e6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IEntryPoint.sol +++ /dev/null @@ -1,223 +0,0 @@ -/** - ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation. - ** Only one instance required on each chain. - **/ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity >=0.7.5; - -/* solhint-disable avoid-low-level-calls */ -/* solhint-disable no-inline-assembly */ -/* solhint-disable reason-string */ - -import "./PackedUserOperation.sol"; -import "./IStakeManager.sol"; -import "./IAggregator.sol"; -import "./INonceManager.sol"; - -interface IEntryPoint is IStakeManager, INonceManager { - /*** - * An event emitted after each successful request. - * @param userOpHash - Unique identifier for the request (hash its entire content, except signature). - * @param sender - The account that generates this request. - * @param paymaster - If non-null, the paymaster that pays for this request. - * @param nonce - The nonce value from the request. - * @param success - True if the sender transaction succeeded, false if reverted. - * @param actualGasCost - Actual amount paid (by account or paymaster) for this UserOperation. - * @param actualGasUsed - Total gas used by this UserOperation (including preVerification, creation, - * validation and execution). - */ - event UserOperationEvent( - bytes32 indexed userOpHash, - address indexed sender, - address indexed paymaster, - uint256 nonce, - bool success, - uint256 actualGasCost, - uint256 actualGasUsed - ); - - /** - * Account "sender" was deployed. - * @param userOpHash - The userOp that deployed this account. UserOperationEvent will follow. - * @param sender - The account that is deployed - * @param factory - The factory used to deploy this account (in the initCode) - * @param paymaster - The paymaster used by this UserOp - */ - event AccountDeployed( - bytes32 indexed userOpHash, - address indexed sender, - address factory, - address paymaster - ); - - /** - * An event emitted if the UserOperation "callData" reverted with non-zero length. - * @param userOpHash - The request unique identifier. - * @param sender - The sender of this request. - * @param nonce - The nonce used in the request. - * @param revertReason - The return bytes from the (reverted) call to "callData". - */ - event UserOperationRevertReason( - bytes32 indexed userOpHash, - address indexed sender, - uint256 nonce, - bytes revertReason - ); - - /** - * An event emitted if the UserOperation Paymaster's "postOp" call reverted with non-zero length. - * @param userOpHash - The request unique identifier. - * @param sender - The sender of this request. - * @param nonce - The nonce used in the request. - * @param revertReason - The return bytes from the (reverted) call to "callData". - */ - event PostOpRevertReason( - bytes32 indexed userOpHash, - address indexed sender, - uint256 nonce, - bytes revertReason - ); - - /** - * UserOp consumed more than prefund. The UserOperation is reverted, and no refund is made. - * @param userOpHash - The request unique identifier. - * @param sender - The sender of this request. - * @param nonce - The nonce used in the request. - */ - event UserOperationPrefundTooLow( - bytes32 indexed userOpHash, - address indexed sender, - uint256 nonce - ); - - /** - * An event emitted by handleOps(), before starting the execution loop. - * Any event emitted before this event, is part of the validation. - */ - event BeforeExecution(); - - /** - * Signature aggregator used by the following UserOperationEvents within this bundle. - * @param aggregator - The aggregator used for the following UserOperationEvents. - */ - event SignatureAggregatorChanged(address indexed aggregator); - - /** - * A custom revert error of handleOps, to identify the offending op. - * Should be caught in off-chain handleOps simulation and not happen on-chain. - * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts. - * NOTE: If simulateValidation passes successfully, there should be no reason for handleOps to fail on it. - * @param opIndex - Index into the array of ops to the failed one (in simulateValidation, this is always zero). - * @param reason - Revert reason. The string starts with a unique code "AAmn", - * where "m" is "1" for factory, "2" for account and "3" for paymaster issues, - * so a failure can be attributed to the correct entity. - */ - error FailedOp(uint256 opIndex, string reason); - - /** - * A custom revert error of handleOps, to report a revert by account or paymaster. - * @param opIndex - Index into the array of ops to the failed one (in simulateValidation, this is always zero). - * @param reason - Revert reason. see FailedOp(uint256,string), above - * @param inner - data from inner cought revert reason - * @dev note that inner is truncated to 2048 bytes - */ - error FailedOpWithRevert(uint256 opIndex, string reason, bytes inner); - - error PostOpReverted(bytes returnData); - - /** - * Error case when a signature aggregator fails to verify the aggregated signature it had created. - * @param aggregator The aggregator that failed to verify the signature - */ - error SignatureValidationFailed(address aggregator); - - // Return value of getSenderAddress. - error SenderAddressResult(address sender); - - // UserOps handled, per aggregator. - struct UserOpsPerAggregator { - PackedUserOperation[] userOps; - // Aggregator address - IAggregator aggregator; - // Aggregated signature - bytes signature; - } - - /** - * Execute a batch of UserOperations. - * No signature aggregator is used. - * If any account requires an aggregator (that is, it returned an aggregator when - * performing simulateValidation), then handleAggregatedOps() must be used instead. - * @param ops - The operations to execute. - * @param beneficiary - The address to receive the fees. - */ - function handleOps( - PackedUserOperation[] calldata ops, - address payable beneficiary - ) external; - - /** - * Execute a batch of UserOperation with Aggregators - * @param opsPerAggregator - The operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts). - * @param beneficiary - The address to receive the fees. - */ - function handleAggregatedOps( - UserOpsPerAggregator[] calldata opsPerAggregator, - address payable beneficiary - ) external; - - /** - * Generate a request Id - unique identifier for this request. - * The request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid. - * @param userOp - The user operation to generate the request ID for. - * @return hash the hash of this UserOperation - */ - function getUserOpHash( - PackedUserOperation calldata userOp - ) external view returns (bytes32); - - /** - * Gas and return values during simulation. - * @param preOpGas - The gas used for validation (including preValidationGas) - * @param prefund - The required prefund for this operation - * @param accountValidationData - returned validationData from account. - * @param paymasterValidationData - return validationData from paymaster. - * @param paymasterContext - Returned by validatePaymasterUserOp (to be passed into postOp) - */ - struct ReturnInfo { - uint256 preOpGas; - uint256 prefund; - uint256 accountValidationData; - uint256 paymasterValidationData; - bytes paymasterContext; - } - - /** - * Returned aggregated signature info: - * The aggregator returned by the account, and its current stake. - */ - struct AggregatorStakeInfo { - address aggregator; - StakeInfo stakeInfo; - } - - /** - * Get counterfactual sender address. - * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation. - * This method always revert, and returns the address in SenderAddressResult error - * @param initCode - The constructor code to be passed into the UserOperation. - */ - function getSenderAddress(bytes memory initCode) external; - - error DelegateAndRevert(bool success, bytes ret); - - /** - * Helper method for dry-run testing. - * @dev calling this method, the EntryPoint will make a delegatecall to the given data, and report (via revert) the result. - * The method always revert, so is only useful off-chain for dry run calls, in cases where state-override to replace - * actual EntryPoint code is less convenient. - * @param target a target contract to make a delegatecall from entrypoint - * @param data data to pass to target in a delegatecall - */ - function delegateAndRevert(address target, bytes calldata data) external; -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IEntryPointSimulations.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IEntryPointSimulations.sol deleted file mode 100644 index a5a894f216..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IEntryPointSimulations.sol +++ /dev/null @@ -1,73 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity >=0.7.5; - -import "./PackedUserOperation.sol"; -import "./IEntryPoint.sol"; - -interface IEntryPointSimulations is IEntryPoint { - // Return value of simulateHandleOp. - struct ExecutionResult { - uint256 preOpGas; - uint256 paid; - uint256 accountValidationData; - uint256 paymasterValidationData; - bool targetSuccess; - bytes targetResult; - } - - /** - * Successful result from simulateValidation. - * If the account returns a signature aggregator the "aggregatorInfo" struct is filled in as well. - * @param returnInfo Gas and time-range returned values - * @param senderInfo Stake information about the sender - * @param factoryInfo Stake information about the factory (if any) - * @param paymasterInfo Stake information about the paymaster (if any) - * @param aggregatorInfo Signature aggregation info (if the account requires signature aggregator) - * Bundler MUST use it to verify the signature, or reject the UserOperation. - */ - struct ValidationResult { - ReturnInfo returnInfo; - StakeInfo senderInfo; - StakeInfo factoryInfo; - StakeInfo paymasterInfo; - AggregatorStakeInfo aggregatorInfo; - } - - /** - * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp. - * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage - * outside the account's data. - * @param userOp - The user operation to validate. - * @return the validation result structure - */ - function simulateValidation( - PackedUserOperation calldata userOp - ) - external - returns ( - ValidationResult memory - ); - - /** - * Simulate full execution of a UserOperation (including both validation and target execution) - * It performs full validation of the UserOperation, but ignores signature error. - * An optional target address is called after the userop succeeds, - * and its value is returned (before the entire call is reverted). - * Note that in order to collect the the success/failure of the target call, it must be executed - * with trace enabled to track the emitted events. - * @param op The UserOperation to simulate. - * @param target - If nonzero, a target address to call after userop simulation. If called, - * the targetSuccess and targetResult are set to the return from that call. - * @param targetCallData - CallData to pass to target address. - * @return the execution result structure - */ - function simulateHandleOp( - PackedUserOperation calldata op, - address target, - bytes calldata targetCallData - ) - external - returns ( - ExecutionResult memory - ); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/INonceManager.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/INonceManager.sol deleted file mode 100644 index 2f993f6875..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/INonceManager.sol +++ /dev/null @@ -1,27 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity >=0.7.5; - -interface INonceManager { - - /** - * Return the next nonce for this sender. - * Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop) - * But UserOp with different keys can come with arbitrary order. - * - * @param sender the account address - * @param key the high 192 bit of the nonce - * @return nonce a full nonce to pass for next UserOp with this sender. - */ - function getNonce(address sender, uint192 key) - external view returns (uint256 nonce); - - /** - * Manually increment the nonce of the sender. - * This method is exposed just for completeness.. - * Account does NOT need to call it, neither during validation, nor elsewhere, - * as the EntryPoint will update the nonce regardless. - * Possible use-case is call it with various keys to "initialize" their nonces to one, so that future - * UserOperations will not pay extra for the first transaction with a given key. - */ - function incrementNonce(uint192 key) external; -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IPaymaster.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IPaymaster.sol deleted file mode 100644 index 9176a0b242..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IPaymaster.sol +++ /dev/null @@ -1,63 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity >=0.7.5; - -import "./PackedUserOperation.sol"; - -/** - * The interface exposed by a paymaster contract, who agrees to pay the gas for user's operations. - * A paymaster must hold a stake to cover the required entrypoint stake and also the gas for the transaction. - */ -interface IPaymaster { - enum PostOpMode { - // User op succeeded. - opSucceeded, - // User op reverted. Still has to pay for gas. - opReverted, - // Only used internally in the EntryPoint (cleanup after postOp reverts). Never calling paymaster with this value - postOpReverted - } - - /** - * Payment validation: check if paymaster agrees to pay. - * Must verify sender is the entryPoint. - * Revert to reject this request. - * Note that bundlers will reject this method if it changes the state, unless the paymaster is trusted (whitelisted). - * The paymaster pre-pays using its deposit, and receive back a refund after the postOp method returns. - * @param userOp - The user operation. - * @param userOpHash - Hash of the user's request data. - * @param maxCost - The maximum cost of this transaction (based on maximum gas and gas price from userOp). - * @return context - Value to send to a postOp. Zero length to signify postOp is not required. - * @return validationData - Signature and time-range of this operation, encoded the same as the return - * value of validateUserOperation. - * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure, - * other values are invalid for paymaster. - * <6-byte> validUntil - last timestamp this operation is valid. 0 for "indefinite" - * <6-byte> validAfter - first timestamp this operation is valid - * Note that the validation code cannot use block.timestamp (or block.number) directly. - */ - function validatePaymasterUserOp( - PackedUserOperation calldata userOp, - bytes32 userOpHash, - uint256 maxCost - ) external returns (bytes memory context, uint256 validationData); - - /** - * Post-operation handler. - * Must verify sender is the entryPoint. - * @param mode - Enum with the following options: - * opSucceeded - User operation succeeded. - * opReverted - User op reverted. The paymaster still has to pay for gas. - * postOpReverted - never passed in a call to postOp(). - * @param context - The context value returned by validatePaymasterUserOp - * @param actualGasCost - Actual gas used so far (without this postOp call). - * @param actualUserOpFeePerGas - the gas price this UserOp pays. This value is based on the UserOp's maxFeePerGas - * and maxPriorityFee (and basefee) - * It is not the same as tx.gasprice, which is what the bundler pays. - */ - function postOp( - PostOpMode mode, - bytes calldata context, - uint256 actualGasCost, - uint256 actualUserOpFeePerGas - ) external; -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IStakeManager.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IStakeManager.sol deleted file mode 100644 index 69083e93f5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/IStakeManager.sol +++ /dev/null @@ -1,111 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0-only -pragma solidity >=0.7.5; - -/** - * Manage deposits and stakes. - * Deposit is just a balance used to pay for UserOperations (either by a paymaster or an account). - * Stake is value locked for at least "unstakeDelay" by the staked entity. - */ -interface IStakeManager { - event Deposited(address indexed account, uint256 totalDeposit); - - event Withdrawn( - address indexed account, - address withdrawAddress, - uint256 amount - ); - - // Emitted when stake or unstake delay are modified. - event StakeLocked( - address indexed account, - uint256 totalStaked, - uint256 unstakeDelaySec - ); - - // Emitted once a stake is scheduled for withdrawal. - event StakeUnlocked(address indexed account, uint256 withdrawTime); - - event StakeWithdrawn( - address indexed account, - address withdrawAddress, - uint256 amount - ); - - /** - * @param deposit - The entity's deposit. - * @param staked - True if this entity is staked. - * @param stake - Actual amount of ether staked for this entity. - * @param unstakeDelaySec - Minimum delay to withdraw the stake. - * @param withdrawTime - First block timestamp where 'withdrawStake' will be callable, or zero if already locked. - * @dev Sizes were chosen so that deposit fits into one cell (used during handleOp) - * and the rest fit into a 2nd cell (used during stake/unstake) - * - 112 bit allows for 10^15 eth - * - 48 bit for full timestamp - * - 32 bit allows 150 years for unstake delay - */ - struct DepositInfo { - uint256 deposit; - bool staked; - uint112 stake; - uint32 unstakeDelaySec; - uint48 withdrawTime; - } - - // API struct used by getStakeInfo and simulateValidation. - struct StakeInfo { - uint256 stake; - uint256 unstakeDelaySec; - } - - /** - * Get deposit info. - * @param account - The account to query. - * @return info - Full deposit information of given account. - */ - function getDepositInfo( - address account - ) external view returns (DepositInfo memory info); - - /** - * Get account balance. - * @param account - The account to query. - * @return - The deposit (for gas payment) of the account. - */ - function balanceOf(address account) external view returns (uint256); - - /** - * Add to the deposit of the given account. - * @param account - The account to add to. - */ - function depositTo(address account) external payable; - - /** - * Add to the account's stake - amount and delay - * any pending unstake is first cancelled. - * @param _unstakeDelaySec - The new lock duration before the deposit can be withdrawn. - */ - function addStake(uint32 _unstakeDelaySec) external payable; - - /** - * Attempt to unlock the stake. - * The value can be withdrawn (using withdrawStake) after the unstake delay. - */ - function unlockStake() external; - - /** - * Withdraw from the (unlocked) stake. - * Must first call unlockStake and wait for the unstakeDelay to pass. - * @param withdrawAddress - The address to send withdrawn value. - */ - function withdrawStake(address payable withdrawAddress) external; - - /** - * Withdraw from the deposit. - * @param withdrawAddress - The address to send withdrawn value. - * @param withdrawAmount - The amount to withdraw. - */ - function withdrawTo( - address payable withdrawAddress, - uint256 withdrawAmount - ) external; -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/PackedUserOperation.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/PackedUserOperation.sol deleted file mode 100644 index fe20de5657..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/interfaces/PackedUserOperation.sol +++ /dev/null @@ -1,28 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity >=0.7.5; - -/** - * User Operation struct - * @param sender - The sender account of this request. - * @param nonce - Unique value the sender uses to verify it is not a replay. - * @param initCode - If set, the account contract will be created by this constructor/ - * @param callData - The method call to execute on this account. - * @param accountGasLimits - Packed gas limits for validateUserOp and gas limit passed to the callData method call. - * @param preVerificationGas - Gas not calculated by the handleOps method, but added to the gas paid. - * Covers batch overhead. - * @param gasFees - packed gas fields maxPriorityFeePerGas and maxFeePerGas - Same as EIP-1559 gas parameters. - * @param paymasterAndData - If set, this field holds the paymaster address, verification gas limit, postOp gas limit and paymaster-specific extra data - * The paymaster will pay for the transaction instead of the sender. - * @param signature - Sender-verified signature over the entire request, the EntryPoint address and the chain ID. - */ -struct PackedUserOperation { - address sender; - uint256 nonce; - bytes initCode; - bytes callData; - bytes32 accountGasLimits; - uint256 preVerificationGas; - bytes32 gasFees; - bytes paymasterAndData; - bytes signature; -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/package.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/package.json deleted file mode 100644 index bb1703cb75..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/package.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "name": "@account-abstraction/contracts", - "description": "Account Abstraction (EIP 4337) contracts", - "version": "0.7.0", - "scripts": { - "prepack": "../scripts/prepack-contracts-package.sh", - "postpack": "../scripts/postpack-contracts-package.sh" - }, - "repository": { - "type": "git", - "url": "https://github.com/eth-infinitism/account-abstraction" - }, - "keywords": [ - "solidity", - "ethereum", - "smart", - "contracts", - "account-abstraction", - "erc-4337" - ], - "license": "MIT", - "bugs": { - "url": "https://github.com/eth-infinitism/account-abstraction/issues" - }, - "dependencies": { - "@openzeppelin/contracts": "^5.0.0", - "@uniswap/v3-periphery": "^1.4.3" - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/LegacyTokenPaymaster.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/LegacyTokenPaymaster.sol deleted file mode 100644 index 1589696dd1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/LegacyTokenPaymaster.sol +++ /dev/null @@ -1,115 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -/* solhint-disable reason-string */ - -import "@openzeppelin/contracts/token/ERC20/ERC20.sol"; -import "../core/BasePaymaster.sol"; -import "../core/UserOperationLib.sol"; -import "../core/Helpers.sol"; - -/** - * A sample paymaster that defines itself as a token to pay for gas. - * The paymaster IS the token to use, since a paymaster cannot use an external contract. - * Also, the exchange rate has to be fixed, since it can't reference an external Uniswap or other exchange contract. - * subclass should override "getTokenValueOfEth" to provide actual token exchange rate, settable by the owner. - * Known Limitation: this paymaster is exploitable when put into a batch with multiple ops (of different accounts): - * - while a single op can't exploit the paymaster (if postOp fails to withdraw the tokens, the user's op is reverted, - * and then we know we can withdraw the tokens), multiple ops with different senders (all using this paymaster) - * in a batch can withdraw funds from 2nd and further ops, forcing the paymaster itself to pay (from its deposit) - * - Possible workarounds are either use a more complex paymaster scheme (e.g. the DepositPaymaster) or - * to whitelist the account and the called method ids. - */ -contract LegacyTokenPaymaster is BasePaymaster, ERC20 { - using UserOperationLib for PackedUserOperation; - - //calculated cost of the postOp - uint256 constant public COST_OF_POST = 15000; - - address public immutable theFactory; - - constructor(address accountFactory, string memory _symbol, IEntryPoint _entryPoint) ERC20(_symbol, _symbol) BasePaymaster(_entryPoint) { - theFactory = accountFactory; - //make it non-empty - _mint(address(this), 1); - - //owner is allowed to withdraw tokens from the paymaster's balance - _approve(address(this), msg.sender, type(uint256).max); - } - - - /** - * helpers for owner, to mint and withdraw tokens. - * @param recipient - the address that will receive the minted tokens. - * @param amount - the amount it will receive. - */ - function mintTokens(address recipient, uint256 amount) external onlyOwner { - _mint(recipient, amount); - } - - /** - * transfer paymaster ownership. - * owner of this paymaster is allowed to withdraw funds (tokens transferred to this paymaster's balance) - * when changing owner, the old owner's withdrawal rights are revoked. - */ - function transferOwnership(address newOwner) public override virtual onlyOwner { - // remove allowance of current owner - _approve(address(this), owner(), 0); - super.transferOwnership(newOwner); - // new owner is allowed to withdraw tokens from the paymaster's balance - _approve(address(this), newOwner, type(uint256).max); - } - - //Note: this method assumes a fixed ratio of token-to-eth. subclass should override to supply oracle - // or a setter. - function getTokenValueOfEth(uint256 valueEth) internal view virtual returns (uint256 valueToken) { - return valueEth / 100; - } - - /** - * validate the request: - * if this is a constructor call, make sure it is a known account. - * verify the sender has enough tokens. - * (since the paymaster is also the token, there is no notion of "approval") - */ - function _validatePaymasterUserOp(PackedUserOperation calldata userOp, bytes32 /*userOpHash*/, uint256 requiredPreFund) - internal view override returns (bytes memory context, uint256 validationData) { - uint256 tokenPrefund = getTokenValueOfEth(requiredPreFund); - - uint256 postOpGasLimit = userOp.unpackPostOpGasLimit(); - require( postOpGasLimit > COST_OF_POST, "TokenPaymaster: gas too low for postOp"); - - if (userOp.initCode.length != 0) { - _validateConstructor(userOp); - require(balanceOf(userOp.sender) >= tokenPrefund, "TokenPaymaster: no balance (pre-create)"); - } else { - - require(balanceOf(userOp.sender) >= tokenPrefund, "TokenPaymaster: no balance"); - } - - return (abi.encode(userOp.sender), SIG_VALIDATION_SUCCESS); - } - - // when constructing an account, validate constructor code and parameters - // we trust our factory (and that it doesn't have any other public methods) - function _validateConstructor(PackedUserOperation calldata userOp) internal virtual view { - address factory = address(bytes20(userOp.initCode[0 : 20])); - require(factory == theFactory, "TokenPaymaster: wrong account factory"); - } - - /** - * actual charge of user. - * this method will be called just after the user's TX with mode==OpSucceeded|OpReverted (account pays in both cases) - * BUT: if the user changed its balance in a way that will cause postOp to revert, then it gets called again, after reverting - * the user's TX , back to the state it was before the transaction started (before the validatePaymasterUserOp), - * and the transaction should succeed there. - */ - function _postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost, uint256 actualUserOpFeePerGas) internal override { - //we don't really care about the mode, we just pay the gas with the user's tokens. - (mode); - address sender = abi.decode(context, (address)); - uint256 charge = getTokenValueOfEth(actualGasCost + COST_OF_POST * actualUserOpFeePerGas); - //actualGasCost is known to be no larger than the above requiredPreFund, so the transfer should succeed. - _transfer(sender, address(this), charge); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/SimpleAccount.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/SimpleAccount.sol deleted file mode 100644 index 61af6ca6bf..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/SimpleAccount.sol +++ /dev/null @@ -1,150 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -/* solhint-disable avoid-low-level-calls */ -/* solhint-disable no-inline-assembly */ -/* solhint-disable reason-string */ - -import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; -import "@openzeppelin/contracts/utils/cryptography/MessageHashUtils.sol"; -import "@openzeppelin/contracts/proxy/utils/Initializable.sol"; -import "@openzeppelin/contracts/proxy/utils/UUPSUpgradeable.sol"; -import "../core/BaseAccount.sol"; -import "../core/Helpers.sol"; -import "./callback/TokenCallbackHandler.sol"; - -/** - * minimal account. - * this is sample minimal account. - * has execute, eth handling methods - * has a single signer that can send requests through the entryPoint. - */ -contract SimpleAccount is BaseAccount, TokenCallbackHandler, UUPSUpgradeable, Initializable { - address public owner; - - IEntryPoint private immutable _entryPoint; - - event SimpleAccountInitialized(IEntryPoint indexed entryPoint, address indexed owner); - - modifier onlyOwner() { - _onlyOwner(); - _; - } - - /// @inheritdoc BaseAccount - function entryPoint() public view virtual override returns (IEntryPoint) { - return _entryPoint; - } - - // solhint-disable-next-line no-empty-blocks - receive() external payable {} - - constructor(IEntryPoint anEntryPoint) { - _entryPoint = anEntryPoint; - _disableInitializers(); - } - - function _onlyOwner() internal view { - //directly from EOA owner, or through the account itself (which gets redirected through execute()) - require(msg.sender == owner || msg.sender == address(this), "only owner"); - } - - /** - * execute a transaction (called directly from owner, or by entryPoint) - * @param dest destination address to call - * @param value the value to pass in this call - * @param func the calldata to pass in this call - */ - function execute(address dest, uint256 value, bytes calldata func) external { - _requireFromEntryPointOrOwner(); - _call(dest, value, func); - } - - /** - * execute a sequence of transactions - * @dev to reduce gas consumption for trivial case (no value), use a zero-length array to mean zero value - * @param dest an array of destination addresses - * @param value an array of values to pass to each call. can be zero-length for no-value calls - * @param func an array of calldata to pass to each call - */ - function executeBatch(address[] calldata dest, uint256[] calldata value, bytes[] calldata func) external { - _requireFromEntryPointOrOwner(); - require(dest.length == func.length && (value.length == 0 || value.length == func.length), "wrong array lengths"); - if (value.length == 0) { - for (uint256 i = 0; i < dest.length; i++) { - _call(dest[i], 0, func[i]); - } - } else { - for (uint256 i = 0; i < dest.length; i++) { - _call(dest[i], value[i], func[i]); - } - } - } - - /** - * @dev The _entryPoint member is immutable, to reduce gas consumption. To upgrade EntryPoint, - * a new implementation of SimpleAccount must be deployed with the new EntryPoint address, then upgrading - * the implementation by calling `upgradeTo()` - * @param anOwner the owner (signer) of this account - */ - function initialize(address anOwner) public virtual initializer { - _initialize(anOwner); - } - - function _initialize(address anOwner) internal virtual { - owner = anOwner; - emit SimpleAccountInitialized(_entryPoint, owner); - } - - // Require the function call went through EntryPoint or owner - function _requireFromEntryPointOrOwner() internal view { - require(msg.sender == address(entryPoint()) || msg.sender == owner, "account: not Owner or EntryPoint"); - } - - /// implement template method of BaseAccount - function _validateSignature(PackedUserOperation calldata userOp, bytes32 userOpHash) - internal override virtual returns (uint256 validationData) { - bytes32 hash = MessageHashUtils.toEthSignedMessageHash(userOpHash); - if (owner != ECDSA.recover(hash, userOp.signature)) - return SIG_VALIDATION_FAILED; - return SIG_VALIDATION_SUCCESS; - } - - function _call(address target, uint256 value, bytes memory data) internal { - (bool success, bytes memory result) = target.call{value: value}(data); - if (!success) { - assembly { - revert(add(result, 32), mload(result)) - } - } - } - - /** - * check current account deposit in the entryPoint - */ - function getDeposit() public view returns (uint256) { - return entryPoint().balanceOf(address(this)); - } - - /** - * deposit more funds for this account in the entryPoint - */ - function addDeposit() public payable { - entryPoint().depositTo{value: msg.value}(address(this)); - } - - /** - * withdraw value from the account's deposit - * @param withdrawAddress target to send to - * @param amount to withdraw - */ - function withdrawDepositTo(address payable withdrawAddress, uint256 amount) public onlyOwner { - entryPoint().withdrawTo(withdrawAddress, amount); - } - - function _authorizeUpgrade(address newImplementation) internal view override { - (newImplementation); - _onlyOwner(); - } -} - diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/SimpleAccountFactory.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/SimpleAccountFactory.sol deleted file mode 100644 index 5afa2ce60c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/SimpleAccountFactory.sol +++ /dev/null @@ -1,52 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -import "@openzeppelin/contracts/utils/Create2.sol"; -import "@openzeppelin/contracts/proxy/ERC1967/ERC1967Proxy.sol"; - -import "./SimpleAccount.sol"; - -/** - * A sample factory contract for SimpleAccount - * A UserOperations "initCode" holds the address of the factory, and a method call (to createAccount, in this sample factory). - * The factory's createAccount returns the target account address even if it is already installed. - * This way, the entryPoint.getSenderAddress() can be called either before or after the account is created. - */ -contract SimpleAccountFactory { - SimpleAccount public immutable accountImplementation; - - constructor(IEntryPoint _entryPoint) { - accountImplementation = new SimpleAccount(_entryPoint); - } - - /** - * create an account, and return its address. - * returns the address even if the account is already deployed. - * Note that during UserOperation execution, this method is called only if the account is not deployed. - * This method returns an existing account address so that entryPoint.getSenderAddress() would work even after account creation - */ - function createAccount(address owner,uint256 salt) public returns (SimpleAccount ret) { - address addr = getAddress(owner, salt); - uint256 codeSize = addr.code.length; - if (codeSize > 0) { - return SimpleAccount(payable(addr)); - } - ret = SimpleAccount(payable(new ERC1967Proxy{salt : bytes32(salt)}( - address(accountImplementation), - abi.encodeCall(SimpleAccount.initialize, (owner)) - ))); - } - - /** - * calculate the counterfactual address of this account as it would be returned by createAccount() - */ - function getAddress(address owner,uint256 salt) public view returns (address) { - return Create2.computeAddress(bytes32(salt), keccak256(abi.encodePacked( - type(ERC1967Proxy).creationCode, - abi.encode( - address(accountImplementation), - abi.encodeCall(SimpleAccount.initialize, (owner)) - ) - ))); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/TokenPaymaster.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/TokenPaymaster.sol deleted file mode 100644 index 1d4c50d63c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/TokenPaymaster.sol +++ /dev/null @@ -1,217 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -// Import the required libraries and contracts -import "@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol"; -import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol"; -import "@openzeppelin/contracts/utils/cryptography/EIP712.sol"; - -import "../interfaces/IEntryPoint.sol"; -import "../core/BasePaymaster.sol"; -import "../core/Helpers.sol"; -import "./utils/UniswapHelper.sol"; -import "./utils/OracleHelper.sol"; - -/// @title Sample ERC-20 Token Paymaster for ERC-4337 -/// This Paymaster covers gas fees in exchange for ERC20 tokens charged using allowance pre-issued by ERC-4337 accounts. -/// The contract refunds excess tokens if the actual gas cost is lower than the initially provided amount. -/// The token price cannot be queried in the validation code due to storage access restrictions of ERC-4337. -/// The price is cached inside the contract and is updated in the 'postOp' stage if the change is >10%. -/// It is theoretically possible the token has depreciated so much since the last 'postOp' the refund becomes negative. -/// The contract reverts the inner user transaction in that case but keeps the charge. -/// The contract also allows honest clients to prepay tokens at a higher price to avoid getting reverted. -/// It also allows updating price configuration and withdrawing tokens by the contract owner. -/// The contract uses an Oracle to fetch the latest token prices. -/// @dev Inherits from BasePaymaster. -contract TokenPaymaster is BasePaymaster, UniswapHelper, OracleHelper { - - using UserOperationLib for PackedUserOperation; - - struct TokenPaymasterConfig { - /// @notice The price markup percentage applied to the token price (1e26 = 100%). Ranges from 1e26 to 2e26 - uint256 priceMarkup; - - /// @notice Exchange tokens to native currency if the EntryPoint balance of this Paymaster falls below this value - uint128 minEntryPointBalance; - - /// @notice Estimated gas cost for refunding tokens after the transaction is completed - uint48 refundPostopCost; - - /// @notice Transactions are only valid as long as the cached price is not older than this value - uint48 priceMaxAge; - } - - event ConfigUpdated(TokenPaymasterConfig tokenPaymasterConfig); - - event UserOperationSponsored(address indexed user, uint256 actualTokenCharge, uint256 actualGasCost, uint256 actualTokenPriceWithMarkup); - - event Received(address indexed sender, uint256 value); - - /// @notice All 'price' variables are multiplied by this value to avoid rounding up - uint256 private constant PRICE_DENOMINATOR = 1e26; - - TokenPaymasterConfig public tokenPaymasterConfig; - - /// @notice Initializes the TokenPaymaster contract with the given parameters. - /// @param _token The ERC20 token used for transaction fee payments. - /// @param _entryPoint The EntryPoint contract used in the Account Abstraction infrastructure. - /// @param _wrappedNative The ERC-20 token that wraps the native asset for current chain. - /// @param _uniswap The Uniswap V3 SwapRouter contract. - /// @param _tokenPaymasterConfig The configuration for the Token Paymaster. - /// @param _oracleHelperConfig The configuration for the Oracle Helper. - /// @param _uniswapHelperConfig The configuration for the Uniswap Helper. - /// @param _owner The address that will be set as the owner of the contract. - constructor( - IERC20Metadata _token, - IEntryPoint _entryPoint, - IERC20 _wrappedNative, - ISwapRouter _uniswap, - TokenPaymasterConfig memory _tokenPaymasterConfig, - OracleHelperConfig memory _oracleHelperConfig, - UniswapHelperConfig memory _uniswapHelperConfig, - address _owner - ) - BasePaymaster( - _entryPoint - ) - OracleHelper( - _oracleHelperConfig - ) - UniswapHelper( - _token, - _wrappedNative, - _uniswap, - _uniswapHelperConfig - ) - { - setTokenPaymasterConfig(_tokenPaymasterConfig); - transferOwnership(_owner); - } - - /// @notice Updates the configuration for the Token Paymaster. - /// @param _tokenPaymasterConfig The new configuration struct. - function setTokenPaymasterConfig( - TokenPaymasterConfig memory _tokenPaymasterConfig - ) public onlyOwner { - require(_tokenPaymasterConfig.priceMarkup <= 2 * PRICE_DENOMINATOR, "TPM: price markup too high"); - require(_tokenPaymasterConfig.priceMarkup >= PRICE_DENOMINATOR, "TPM: price markup too low"); - tokenPaymasterConfig = _tokenPaymasterConfig; - emit ConfigUpdated(_tokenPaymasterConfig); - } - - function setUniswapConfiguration( - UniswapHelperConfig memory _uniswapHelperConfig - ) external onlyOwner { - _setUniswapHelperConfiguration(_uniswapHelperConfig); - } - - /// @notice Allows the contract owner to withdraw a specified amount of tokens from the contract. - /// @param to The address to transfer the tokens to. - /// @param amount The amount of tokens to transfer. - function withdrawToken(address to, uint256 amount) external onlyOwner { - SafeERC20.safeTransfer(token, to, amount); - } - - /// @notice Validates a paymaster user operation and calculates the required token amount for the transaction. - /// @param userOp The user operation data. - /// @param requiredPreFund The maximum cost (in native token) the paymaster has to prefund. - /// @return context The context containing the token amount and user sender address (if applicable). - /// @return validationResult A uint256 value indicating the result of the validation (always 0 in this implementation). - function _validatePaymasterUserOp(PackedUserOperation calldata userOp, bytes32, uint256 requiredPreFund) - internal - override - returns (bytes memory context, uint256 validationResult) {unchecked { - uint256 priceMarkup = tokenPaymasterConfig.priceMarkup; - uint256 dataLength = userOp.paymasterAndData.length - PAYMASTER_DATA_OFFSET; - require(dataLength == 0 || dataLength == 32, - "TPM: invalid data length" - ); - uint256 maxFeePerGas = userOp.unpackMaxFeePerGas(); - uint256 refundPostopCost = tokenPaymasterConfig.refundPostopCost; - require(refundPostopCost < userOp.unpackPostOpGasLimit(), "TPM: postOpGasLimit too low"); - uint256 preChargeNative = requiredPreFund + (refundPostopCost * maxFeePerGas); - // note: as price is in native-asset-per-token and we want more tokens increasing it means dividing it by markup - uint256 cachedPriceWithMarkup = cachedPrice * PRICE_DENOMINATOR / priceMarkup; - if (dataLength == 32) { - uint256 clientSuppliedPrice = uint256(bytes32(userOp.paymasterAndData[PAYMASTER_DATA_OFFSET : PAYMASTER_DATA_OFFSET + 32])); - if (clientSuppliedPrice < cachedPriceWithMarkup) { - // note: smaller number means 'more native asset per token' - cachedPriceWithMarkup = clientSuppliedPrice; - } - } - uint256 tokenAmount = weiToToken(preChargeNative, cachedPriceWithMarkup); - SafeERC20.safeTransferFrom(token, userOp.sender, address(this), tokenAmount); - context = abi.encode(tokenAmount, userOp.sender); - validationResult = _packValidationData( - false, - uint48(cachedPriceTimestamp + tokenPaymasterConfig.priceMaxAge), - 0 - ); - } - } - - /// @notice Performs post-operation tasks, such as updating the token price and refunding excess tokens. - /// @dev This function is called after a user operation has been executed or reverted. - /// @param context The context containing the token amount and user sender address. - /// @param actualGasCost The actual gas cost of the transaction. - /// @param actualUserOpFeePerGas - the gas price this UserOp pays. This value is based on the UserOp's maxFeePerGas - // and maxPriorityFee (and basefee) - // It is not the same as tx.gasprice, which is what the bundler pays. - function _postOp(PostOpMode, bytes calldata context, uint256 actualGasCost, uint256 actualUserOpFeePerGas) internal override { - unchecked { - uint256 priceMarkup = tokenPaymasterConfig.priceMarkup; - ( - uint256 preCharge, - address userOpSender - ) = abi.decode(context, (uint256, address)); - uint256 _cachedPrice = updateCachedPrice(false); - // note: as price is in native-asset-per-token and we want more tokens increasing it means dividing it by markup - uint256 cachedPriceWithMarkup = _cachedPrice * PRICE_DENOMINATOR / priceMarkup; - // Refund tokens based on actual gas cost - uint256 actualChargeNative = actualGasCost + tokenPaymasterConfig.refundPostopCost * actualUserOpFeePerGas; - uint256 actualTokenNeeded = weiToToken(actualChargeNative, cachedPriceWithMarkup); - if (preCharge > actualTokenNeeded) { - // If the initially provided token amount is greater than the actual amount needed, refund the difference - SafeERC20.safeTransfer( - token, - userOpSender, - preCharge - actualTokenNeeded - ); - } else if (preCharge < actualTokenNeeded) { - // Attempt to cover Paymaster's gas expenses by withdrawing the 'overdraft' from the client - // If the transfer reverts also revert the 'postOp' to remove the incentive to cheat - SafeERC20.safeTransferFrom( - token, - userOpSender, - address(this), - actualTokenNeeded - preCharge - ); - } - - emit UserOperationSponsored(userOpSender, actualTokenNeeded, actualGasCost, cachedPriceWithMarkup); - refillEntryPointDeposit(_cachedPrice); - } - } - - /// @notice If necessary this function uses this Paymaster's token balance to refill the deposit on EntryPoint - /// @param _cachedPrice the token price that will be used to calculate the swap amount. - function refillEntryPointDeposit(uint256 _cachedPrice) private { - uint256 currentEntryPointBalance = entryPoint.balanceOf(address(this)); - if ( - currentEntryPointBalance < tokenPaymasterConfig.minEntryPointBalance - ) { - uint256 swappedWeth = _maybeSwapTokenToWeth(token, _cachedPrice); - unwrapWeth(swappedWeth); - entryPoint.depositTo{value: address(this).balance}(address(this)); - } - } - - receive() external payable { - emit Received(msg.sender, msg.value); - } - - function withdrawEth(address payable recipient, uint256 amount) external onlyOwner { - (bool success,) = recipient.call{value: amount}(""); - require(success, "withdraw failed"); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/VerifyingPaymaster.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/VerifyingPaymaster.sol deleted file mode 100644 index 1ddce2f47c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/VerifyingPaymaster.sol +++ /dev/null @@ -1,96 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -/* solhint-disable reason-string */ -/* solhint-disable no-inline-assembly */ - -import "../core/BasePaymaster.sol"; -import "../core/UserOperationLib.sol"; -import "../core/Helpers.sol"; -import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; -import "@openzeppelin/contracts/utils/cryptography/MessageHashUtils.sol"; -/** - * A sample paymaster that uses external service to decide whether to pay for the UserOp. - * The paymaster trusts an external signer to sign the transaction. - * The calling user must pass the UserOp to that external signer first, which performs - * whatever off-chain verification before signing the UserOp. - * Note that this signature is NOT a replacement for the account-specific signature: - * - the paymaster checks a signature to agree to PAY for GAS. - * - the account checks a signature to prove identity and account ownership. - */ -contract VerifyingPaymaster is BasePaymaster { - - using UserOperationLib for PackedUserOperation; - - address public immutable verifyingSigner; - - uint256 private constant VALID_TIMESTAMP_OFFSET = PAYMASTER_DATA_OFFSET; - - uint256 private constant SIGNATURE_OFFSET = VALID_TIMESTAMP_OFFSET + 64; - - constructor(IEntryPoint _entryPoint, address _verifyingSigner) BasePaymaster(_entryPoint) { - verifyingSigner = _verifyingSigner; - } - - /** - * return the hash we're going to sign off-chain (and validate on-chain) - * this method is called by the off-chain service, to sign the request. - * it is called on-chain from the validatePaymasterUserOp, to validate the signature. - * note that this signature covers all fields of the UserOperation, except the "paymasterAndData", - * which will carry the signature itself. - */ - function getHash(PackedUserOperation calldata userOp, uint48 validUntil, uint48 validAfter) - public view returns (bytes32) { - //can't use userOp.hash(), since it contains also the paymasterAndData itself. - address sender = userOp.getSender(); - return - keccak256( - abi.encode( - sender, - userOp.nonce, - keccak256(userOp.initCode), - keccak256(userOp.callData), - userOp.accountGasLimits, - uint256(bytes32(userOp.paymasterAndData[PAYMASTER_VALIDATION_GAS_OFFSET : PAYMASTER_DATA_OFFSET])), - userOp.preVerificationGas, - userOp.gasFees, - block.chainid, - address(this), - validUntil, - validAfter - ) - ); - } - - /** - * verify our external signer signed this request. - * the "paymasterAndData" is expected to be the paymaster and a signature over the entire request params - * paymasterAndData[:20] : address(this) - * paymasterAndData[20:84] : abi.encode(validUntil, validAfter) - * paymasterAndData[84:] : signature - */ - function _validatePaymasterUserOp(PackedUserOperation calldata userOp, bytes32 /*userOpHash*/, uint256 requiredPreFund) - internal view override returns (bytes memory context, uint256 validationData) { - (requiredPreFund); - - (uint48 validUntil, uint48 validAfter, bytes calldata signature) = parsePaymasterAndData(userOp.paymasterAndData); - //ECDSA library supports both 64 and 65-byte long signatures. - // we only "require" it here so that the revert reason on invalid signature will be of "VerifyingPaymaster", and not "ECDSA" - require(signature.length == 64 || signature.length == 65, "VerifyingPaymaster: invalid signature length in paymasterAndData"); - bytes32 hash = MessageHashUtils.toEthSignedMessageHash(getHash(userOp, validUntil, validAfter)); - - //don't revert on signature failure: return SIG_VALIDATION_FAILED - if (verifyingSigner != ECDSA.recover(hash, signature)) { - return ("", _packValidationData(true, validUntil, validAfter)); - } - - //no need for other on-chain validation: entire UserOp should have been checked - // by the external service prior to signing it. - return ("", _packValidationData(false, validUntil, validAfter)); - } - - function parsePaymasterAndData(bytes calldata paymasterAndData) public pure returns (uint48 validUntil, uint48 validAfter, bytes calldata signature) { - (validUntil, validAfter) = abi.decode(paymasterAndData[VALID_TIMESTAMP_OFFSET :], (uint48, uint48)); - signature = paymasterAndData[SIGNATURE_OFFSET :]; - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/BLSAccount.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/BLSAccount.sol deleted file mode 100644 index cd480a792c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/BLSAccount.sol +++ /dev/null @@ -1,65 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -import "../SimpleAccount.sol"; -import "./IBLSAccount.sol"; -import "../../core/Helpers.sol"; - -/** - * Minimal BLS-based account that uses an aggregated signature. - * The account must maintain its own BLS public key, and expose its trusted signature aggregator. - * Note that unlike the "standard" SimpleAccount, this account can't be called directly - * (normal SimpleAccount uses its "signer" address as both the ecrecover signer, and as a legitimate - * Ethereum sender address. Obviously, a BLS public key is not a valid Ethereum sender address.) - */ -contract BLSAccount is SimpleAccount, IBLSAccount { - address public immutable aggregator; - uint256[4] private publicKey; - - // The constructor is used only for the "implementation" and only sets immutable values. - // Mutable value slots for proxy accounts are set by the 'initialize' function. - constructor(IEntryPoint anEntryPoint, address anAggregator) SimpleAccount(anEntryPoint) { - aggregator = anAggregator; - } - - /** - * The initializer for the BLSAccount instance. - * @param aPublicKey public key from a BLS keypair that will have a full ownership and control of this account. - */ - function initialize(uint256[4] memory aPublicKey) public virtual initializer { - super._initialize(address(0)); - _setBlsPublicKey(aPublicKey); - } - - function _validateSignature(PackedUserOperation calldata userOp, bytes32 userOpHash) - internal override view returns (uint256 validationData) { - - (userOp, userOpHash); - if (userOp.initCode.length != 0) { - // BLSSignatureAggregator.getUserOpPublicKey() assumes that during account creation, the public key is - // the suffix of the initCode. - // The account MUST validate it - bytes32 pubKeyHash = keccak256(abi.encode(getBlsPublicKey())); - require(keccak256(userOp.initCode[userOp.initCode.length - 128 :]) == pubKeyHash, "wrong pubkey"); - } - return _packValidationData(ValidationData(aggregator, 0,0)); - } - - /** - * Allows the owner to set or change the BLS key. - * @param newPublicKey public key from a BLS keypair that will have a full ownership and control of this account. - */ - function setBlsPublicKey(uint256[4] memory newPublicKey) public onlyOwner { - _setBlsPublicKey(newPublicKey); - } - - function _setBlsPublicKey(uint256[4] memory newPublicKey) internal { - emit PublicKeyChanged(publicKey, newPublicKey); - publicKey = newPublicKey; - } - - /// @inheritdoc IBLSAccount - function getBlsPublicKey() public override view returns (uint256[4] memory) { - return publicKey; - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/BLSAccountFactory.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/BLSAccountFactory.sol deleted file mode 100644 index 95947142fb..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/BLSAccountFactory.sol +++ /dev/null @@ -1,61 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -import "@openzeppelin/contracts/utils/Create2.sol"; -import "@openzeppelin/contracts/proxy/ERC1967/ERC1967Proxy.sol"; - -import "../../interfaces/IEntryPoint.sol"; -import "./BLSAccount.sol"; - -/* solhint-disable no-inline-assembly */ - -/** - * Based on SimpleAccountFactory. - * Cannot be a subclass since both constructor and createAccount depend on the - * constructor and initializer of the actual account contract. - */ -contract BLSAccountFactory { - BLSAccount public immutable accountImplementation; - - constructor(IEntryPoint entryPoint, address aggregator){ - accountImplementation = new BLSAccount(entryPoint, aggregator); - } - - /** - * create an account, and return its address. - * returns the address even if the account is already deployed. - * Note that during UserOperation execution, this method is called only if the account is not deployed. - * This method returns an existing account address so that entryPoint.getSenderAddress() would work even after account creation - * Also note that our BLSSignatureAggregator requires that the public key is the last parameter - */ - function createAccount(uint256 salt, uint256[4] calldata aPublicKey) public returns (BLSAccount) { - - // the BLSSignatureAggregator depends on the public-key being the last 4 uint256 of msg.data. - uint256 slot; - assembly {slot := aPublicKey} - require(slot == msg.data.length - 128, "wrong pubkey offset"); - - address addr = getAddress(salt, aPublicKey); - uint256 codeSize = addr.code.length; - if (codeSize > 0) { - return BLSAccount(payable(addr)); - } - return BLSAccount(payable(new ERC1967Proxy{salt : bytes32(salt)}( - address(accountImplementation), - abi.encodeCall(BLSAccount.initialize, aPublicKey) - ))); - } - - /** - * calculate the counterfactual address of this account as it would be returned by createAccount() - */ - function getAddress(uint256 salt, uint256[4] memory aPublicKey) public view returns (address) { - return Create2.computeAddress(bytes32(salt), keccak256(abi.encodePacked( - type(ERC1967Proxy).creationCode, - abi.encode( - address(accountImplementation), - abi.encodeCall(BLSAccount.initialize, (aPublicKey)) - ) - ))); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/BLSHelper.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/BLSHelper.sol deleted file mode 100644 index a1a1971343..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/BLSHelper.sol +++ /dev/null @@ -1,232 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -// code taken from : https://github.com/witnet/elliptic-curve-solidity/blob/master/contracts/EllipticCurve.sol -// missing core functions from "thehubbleproject/bls": jacAdd (and sum) -library BLSHelper { - - struct XY { - uint256 x; - uint256 y; - } - /** - * sum all the points in the array - * NOTE: the "ecAdd" (below) has a special case where x1==y2. - * @param points an array of bytes32[2], representing an (x,y) of a point - * @param _pp the modulus of the curve - * @return ret the sum of all points - */ - function sum(XY[] memory points, uint256 _pp) internal pure returns (XY memory ret){ - uint256 x = points[0].x; - uint256 y = points[0].y; - uint256 z = 1; - - for (uint256 i = 1; i < points.length; i++) { - (x, y, z) = jacAdd(x, y, z, points[i].x, points[i].y, 1, _pp); - } - (x, y) = toAffine(x, y, z, _pp); - ret.x = x; - ret.y = y; - } - - /// @dev Adds two points (x1, y1, z1) and (x2, y2, z2). - /// @param _x1 coordinate x of P1 - /// @param _y1 coordinate y of P1 - /// @param _z1 coordinate z of P1 - /// @param _x2 coordinate x of square - /// @param _y2 coordinate y of square - /// @param _z2 coordinate z of square - /// @param _pp the modulus - /// @return (qx, qy, qz) P1+square in Jacobian - function jacAdd( - uint256 _x1, - uint256 _y1, - uint256 _z1, - uint256 _x2, - uint256 _y2, - uint256 _z2, - uint256 _pp) - internal pure returns (uint256, uint256, uint256) - { - if (_x1 == 0 && _y1 == 0) - return (_x2, _y2, _z2); - if (_x2 == 0 && _y2 == 0) - return (_x1, _y1, _z1); - - // We follow the equations described in https://pdfs.semanticscholar.org/5c64/29952e08025a9649c2b0ba32518e9a7fb5c2.pdf Section 5 - uint256[4] memory zs; - // z1^2, z1^3, z2^2, z2^3 - zs[0] = mulmod(_z1, _z1, _pp); - zs[1] = mulmod(_z1, zs[0], _pp); - zs[2] = mulmod(_z2, _z2, _pp); - zs[3] = mulmod(_z2, zs[2], _pp); - - // u1, s1, u2, s2 - zs = [ - mulmod(_x1, zs[2], _pp), - mulmod(_y1, zs[3], _pp), - mulmod(_x2, zs[0], _pp), - mulmod(_y2, zs[1], _pp) - ]; - - // In case of zs[0] == zs[2] && zs[1] == zs[3], double function should be used - require(zs[0] != zs[2] || zs[1] != zs[3], "Use jacDouble function instead"); - - uint256[4] memory hr; - //h - hr[0] = addmod(zs[2], _pp - zs[0], _pp); - //r - hr[1] = addmod(zs[3], _pp - zs[1], _pp); - //h^2 - hr[2] = mulmod(hr[0], hr[0], _pp); - // h^3 - hr[3] = mulmod(hr[2], hr[0], _pp); - // qx = -h^3 -2u1h^2+r^2 - uint256 qx = addmod(mulmod(hr[1], hr[1], _pp), _pp - hr[3], _pp); - qx = addmod(qx, _pp - mulmod(2, mulmod(zs[0], hr[2], _pp), _pp), _pp); - // qy = -s1*z1*h^3+r(u1*h^2 -x^3) - uint256 qy = mulmod(hr[1], addmod(mulmod(zs[0], hr[2], _pp), _pp - qx, _pp), _pp); - qy = addmod(qy, _pp - mulmod(zs[1], hr[3], _pp), _pp); - // qz = h*z1*z2 - uint256 qz = mulmod(hr[0], mulmod(_z1, _z2, _pp), _pp); - return (qx, qy, qz); - } - - - /// @dev Converts a point (x, y, z) expressed in Jacobian coordinates to affine coordinates (x', y', 1). - /// @param _x coordinate x - /// @param _y coordinate y - /// @param _z coordinate z - /// @param _pp the modulus - /// @return (x', y') affine coordinates - function toAffine( - uint256 _x, - uint256 _y, - uint256 _z, - uint256 _pp) - internal pure returns (uint256, uint256) - { - uint256 zInv = invMod(_z, _pp); - uint256 zInv2 = mulmod(zInv, zInv, _pp); - uint256 x2 = mulmod(_x, zInv2, _pp); - uint256 y2 = mulmod(_y, mulmod(zInv, zInv2, _pp), _pp); - - return (x2, y2); - } - - - /// @dev Modular euclidean inverse of a number (mod p). - /// @param _x The number - /// @param _pp The modulus - /// @return q such that x*q = 1 (mod _pp) - function invMod(uint256 _x, uint256 _pp) internal pure returns (uint256) { - require(_x != 0 && _x != _pp && _pp != 0, "Invalid number"); - uint256 q = 0; - uint256 newT = 1; - uint256 r = _pp; - uint256 t; - while (_x != 0) { - t = r / _x; - (q, newT) = (newT, addmod(q, (_pp - mulmod(t, newT, _pp)), _pp)); - (r, _x) = (_x, r - t * _x); - } - - return q; - } - - /// @dev Doubles a point (x, y, z). - /// @param _x coordinate x of P1 - /// @param _y coordinate y of P1 - /// @param _z coordinate z of P1 - /// @param _aa the a scalar in the curve equation - /// @param _pp the modulus - /// @return (qx, qy, qz) 2P in Jacobian - function jacDouble( - uint256 _x, - uint256 _y, - uint256 _z, - uint256 _aa, - uint256 _pp) - internal pure returns (uint256, uint256, uint256) - { - if (_z == 0) - return (_x, _y, _z); - - // We follow the equations described in https://pdfs.semanticscholar.org/5c64/29952e08025a9649c2b0ba32518e9a7fb5c2.pdf Section 5 - // Note: there is a bug in the paper regarding the m parameter, M=3*(x1^2)+a*(z1^4) - // x, y, z at this point represent the squares of _x, _y, _z - uint256 x = mulmod(_x, _x, _pp); //x1^2 - uint256 y = mulmod(_y, _y, _pp); //y1^2 - uint256 z = mulmod(_z, _z, _pp); //z1^2 - - // s - uint256 s = mulmod(4, mulmod(_x, y, _pp), _pp); - // m - uint256 m = addmod(mulmod(3, x, _pp), mulmod(_aa, mulmod(z, z, _pp), _pp), _pp); - - // x, y, z at this point will be reassigned and rather represent qx, qy, qz from the paper - // This allows to reduce the gas cost and stack footprint of the algorithm - // qx - x = addmod(mulmod(m, m, _pp), _pp - addmod(s, s, _pp), _pp); - // qy = -8*y1^4 + M(S-T) - y = addmod(mulmod(m, addmod(s, _pp - x, _pp), _pp), _pp - mulmod(8, mulmod(y, y, _pp), _pp), _pp); - // qz = 2*y1*z1 - z = mulmod(2, mulmod(_y, _z, _pp), _pp); - - return (x, y, z); - } - - /// @dev Add two points (x1, y1) and (x2, y2) in affine coordinates. - /// @param _x1 coordinate x of P1 - /// @param _y1 coordinate y of P1 - /// @param _x2 coordinate x of P2 - /// @param _y2 coordinate y of P2 - /// @param _aa constant of the curve - /// @param _pp the modulus - /// @return (qx, qy) = P1+P2 in affine coordinates - function ecAdd( - uint256 _x1, - uint256 _y1, - uint256 _x2, - uint256 _y2, - uint256 _aa, - uint256 _pp) - internal pure returns (uint256, uint256) - { - uint256 x = 0; - uint256 y = 0; - uint256 z = 0; - - // Double if x1==x2 else add - if (_x1 == _x2) { - // y1 = -y2 mod p - if (addmod(_y1, _y2, _pp) == 0) { - return (0, 0); - } else { - // P1 = P2 - (x, y, z) = jacDouble( - _x1, - _y1, - 1, - _aa, - _pp); - } - } else { - (x, y, z) = jacAdd( - _x1, - _y1, - 1, - _x2, - _y2, - 1, - _pp); - } - // Get back to affine - return toAffine( - x, - y, - z, - _pp); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/BLSSignatureAggregator.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/BLSSignatureAggregator.sol deleted file mode 100644 index a2ac0f3255..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/BLSSignatureAggregator.sol +++ /dev/null @@ -1,171 +0,0 @@ -//SPDX-License-Identifier: Unlicense -pragma solidity ^0.8.23; - -import "../../interfaces/IAggregator.sol"; -import "../../interfaces/IEntryPoint.sol"; -import "../../core/UserOperationLib.sol"; -import {BLSOpen} from "./lib/BLSOpen.sol"; -import "./IBLSAccount.sol"; -import "./BLSHelper.sol"; - -/** - * A BLS-based signature aggregator, to validate aggregated signature of multiple UserOps if BLSAccount - */ -contract BLSSignatureAggregator is IAggregator { - using UserOperationLib for PackedUserOperation; - - bytes32 public constant BLS_DOMAIN = keccak256("eip4337.bls.domain"); - - //copied from BLS.sol - uint256 public constant N = 21888242871839275222246405745257275088696311157297823662689037894645226208583; - - address public immutable entryPoint; - - constructor(address _entryPoint) { - entryPoint = _entryPoint; - } - - /** - * return the public key of this account. - * @param userOp the UserOperation that we need the account's public key for. - * @return publicKey - the public key from a BLS keypair the Aggregator will use to verify this UserOp; - * normally public key will be queried from the deployed BLSAccount itself; - * the public key will be read from the 'initCode' if the account is not deployed yet; - */ - function getUserOpPublicKey(PackedUserOperation memory userOp) public view returns (uint256[4] memory publicKey) { - bytes memory initCode = userOp.initCode; - if (initCode.length > 0) { - publicKey = getTrailingPublicKey(initCode); - } else { - return IBLSAccount(userOp.sender).getBlsPublicKey{gas : 50000}(); - } - } - - /** - * return the trailing 4 words of input data - */ - function getTrailingPublicKey(bytes memory data) public pure returns (uint256[4] memory publicKey) { - uint256 len = data.length; - require(len > 32 * 4, "data too short for sig"); - - /* solhint-disable-next-line no-inline-assembly */ - assembly { - // actual buffer starts at data+32, so last 128 bytes start at data+32+len-128 = data+len-96 - let ofs := sub(add(data, len), 96) - mstore(publicKey, mload(ofs)) - mstore(add(publicKey, 32), mload(add(ofs, 32))) - mstore(add(publicKey, 64), mload(add(ofs, 64))) - mstore(add(publicKey, 96), mload(add(ofs, 96))) - } - } - - /// @inheritdoc IAggregator - function validateSignatures(PackedUserOperation[] calldata userOps, bytes calldata signature) - external view override { - require(signature.length == 64, "BLS: invalid signature"); - (uint256[2] memory blsSignature) = abi.decode(signature, (uint256[2])); - - uint256 userOpsLen = userOps.length; - uint256[4][] memory blsPublicKeys = new uint256[4][](userOpsLen); - uint256[2][] memory messages = new uint256[2][](userOpsLen); - for (uint256 i = 0; i < userOpsLen; i++) { - - PackedUserOperation memory userOp = userOps[i]; - blsPublicKeys[i] = getUserOpPublicKey(userOp); - - messages[i] = _userOpToMessage(userOp, _getPublicKeyHash(blsPublicKeys[i])); - } - require(BLSOpen.verifyMultiple(blsSignature, blsPublicKeys, messages), "BLS: validateSignatures failed"); - } - - /** - * get a hash of userOp - * NOTE: this hash is not the same as UserOperation.hash() - * (slightly less efficient, since it uses memory userOp) - */ - function internalUserOpHash(PackedUserOperation memory userOp) internal pure returns (bytes32) { - return keccak256(abi.encode( - userOp.sender, - userOp.nonce, - keccak256(userOp.initCode), - keccak256(userOp.callData), - userOp.accountGasLimits, - userOp.preVerificationGas, - userOp.gasFees, - keccak256(userOp.paymasterAndData) - )); - } - - /** - * return the BLS "message" for the given UserOp. - * the account checks the signature over this value using its public key - */ - function userOpToMessage(PackedUserOperation memory userOp) public view returns (uint256[2] memory) { - bytes32 publicKeyHash = _getPublicKeyHash(getUserOpPublicKey(userOp)); - return _userOpToMessage(userOp, publicKeyHash); - } - - function _userOpToMessage(PackedUserOperation memory userOp, bytes32 publicKeyHash) internal view returns (uint256[2] memory) { - bytes32 userOpHash = _getUserOpHash(userOp, publicKeyHash); - return BLSOpen.hashToPoint(BLS_DOMAIN, abi.encodePacked(userOpHash)); - } - - - function getUserOpHash(PackedUserOperation memory userOp) public view returns (bytes32) { - bytes32 publicKeyHash = _getPublicKeyHash(getUserOpPublicKey(userOp)); - return _getUserOpHash(userOp, publicKeyHash); - } - - function _getUserOpHash(PackedUserOperation memory userOp, bytes32 publicKeyHash) internal view returns (bytes32) { - return keccak256(abi.encode(internalUserOpHash(userOp), publicKeyHash, address(this), block.chainid, entryPoint)); - } - - function _getPublicKeyHash(uint256[4] memory publicKey) internal pure returns(bytes32) { - return keccak256(abi.encode(publicKey)); - } - /** - * validate signature of a single userOp - * This method is called after EntryPoint.simulateValidation() returns an aggregator. - * First it validates the signature over the userOp. then it return data to be used when creating the handleOps: - * @param userOp the userOperation received from the user. - * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps. - * (usually empty, unless account and aggregator support some kind of "multisig" - */ - function validateUserOpSignature(PackedUserOperation calldata userOp) - external view returns (bytes memory sigForUserOp) { - uint256[2] memory signature = abi.decode(userOp.signature, (uint256[2])); - uint256[4] memory pubkey = getUserOpPublicKey(userOp); - uint256[2] memory message = _userOpToMessage(userOp, _getPublicKeyHash(pubkey)); - - require(BLSOpen.verifySingle(signature, pubkey, message), "BLS: wrong sig"); - return ""; - } - - - /** - * aggregate multiple signatures into a single value. - * This method is called off-chain to calculate the signature to pass with handleOps() - * bundler MAY use optimized custom code perform this aggregation - * @param userOps array of UserOperations to collect the signatures from. - * @return aggregatedSignature the aggregated signature - */ - function aggregateSignatures(PackedUserOperation[] calldata userOps) external pure returns (bytes memory aggregatedSignature) { - BLSHelper.XY[] memory points = new BLSHelper.XY[](userOps.length); - for (uint256 i = 0; i < points.length; i++) { - (uint256 x, uint256 y) = abi.decode(userOps[i].signature, (uint256, uint256)); - points[i] = BLSHelper.XY(x, y); - } - BLSHelper.XY memory sum = BLSHelper.sum(points, N); - return abi.encode(sum.x, sum.y); - } - - /** - * allow staking for this aggregator - * there is no limit on stake or delay, but it is not a problem, since it is a permissionless - * signature aggregator, which doesn't support unstaking. - * @param unstakeDelaySec - the required unstaked delay - */ - function addStake(uint32 unstakeDelaySec) external payable { - IEntryPoint(entryPoint).addStake{value : msg.value}(unstakeDelaySec); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/IBLSAccount.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/IBLSAccount.sol deleted file mode 100644 index c7d0e7f6cb..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/IBLSAccount.sol +++ /dev/null @@ -1,16 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0-only -pragma solidity >=0.7.5; - -import "../../interfaces/IAccount.sol"; - -/** - * a BLS account should expose its own public key. - */ -interface IBLSAccount is IAccount { - event PublicKeyChanged(uint256[4] oldPublicKey, uint256[4] newPublicKey); - - /** - * @return public key from a BLS keypair that is used to verify the BLS signature, both separately and aggregated. - */ - function getBlsPublicKey() external view returns (uint256[4] memory); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/lib/BLSOpen.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/lib/BLSOpen.sol deleted file mode 100644 index 914955b3d7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/lib/BLSOpen.sol +++ /dev/null @@ -1,64 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.23; - -import { BLS } from "./hubble-contracts/contracts/libs/BLS.sol"; - -library BLSOpen { - function verifySingle( - uint256[2] memory signature, - uint256[4] memory pubkey, - uint256[2] memory message - ) external view returns (bool) { - uint256[4][] memory pubkeys = new uint256[4][](1); - uint256[2][] memory messages = new uint256[2][](1); - pubkeys[0] = pubkey; - messages[0] = message; - - (bool verified, bool callSuccess) = BLS.verifyMultiple( - signature, - pubkeys, - messages - ); - return callSuccess && verified; - - // // NB: (result, success) opposite of `call` convention (success, result). - // (bool verified, bool callSuccess) = BLS.verifySingle( - // signature, - // pubkey, - // message - // ); - // return callSuccess && verified; - } - - function verifyMultiple( - uint256[2] memory signature, - uint256[4][] memory pubkeys, - uint256[2][] memory messages - ) external view returns (bool) { - (bool verified, bool callSuccess) = BLS.verifyMultiple( - signature, - pubkeys, - messages - ); - return callSuccess && verified; - } - - function hashToPoint( - bytes32 domain, - bytes memory message - ) external view returns (uint256[2] memory) { - return BLS.hashToPoint( - domain, - message - ); - } - - function isZeroBLSKey(uint256[4] memory blsKey) public pure returns (bool) { - bool isZero = true; - for (uint256 i=0; isZero && i<4; i++) { - isZero = (blsKey[i] == 0); - } - return isZero; - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/lib/hubble-contracts/contracts/libs/BLS.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/lib/hubble-contracts/contracts/libs/BLS.sol deleted file mode 100644 index e02bc10c36..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/lib/hubble-contracts/contracts/libs/BLS.sol +++ /dev/null @@ -1,440 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >= 0.6.12; - -import { ModexpInverse, ModexpSqrt } from "./ModExp.sol"; -import { - BNPairingPrecompileCostEstimator -} from "./BNPairingPrecompileCostEstimator.sol"; - -/** - @title Boneh–Lynn–Shacham (BLS) signature scheme on Barreto-Naehrig 254 bit curve (BN-254) - @notice We use BLS signature aggregation to reduce the size of signature data to store on chain. - @dev We use G1 points for signatures and messages, and G2 points for public keys - */ -library BLS { - // Field order - // prettier-ignore - uint256 private constant N = 21888242871839275222246405745257275088696311157297823662689037894645226208583; - - // Negated genarator of G2 - // prettier-ignore - uint256 private constant N_G2_X1 = 11559732032986387107991004021392285783925812861821192530917403151452391805634; - // prettier-ignore - uint256 private constant N_G2_X0 = 10857046999023057135944570762232829481370756359578518086990519993285655852781; - // prettier-ignore - uint256 private constant N_G2_Y1 = 17805874995975841540914202342111839520379459829704422454583296818431106115052; - // prettier-ignore - uint256 private constant N_G2_Y0 = 13392588948715843804641432497768002650278120570034223513918757245338268106653; - - // sqrt(-3) - // prettier-ignore - uint256 private constant Z0 = 0x0000000000000000b3c4d79d41a91759a9e4c7e359b6b89eaec68e62effffffd; - // (sqrt(-3) - 1) / 2 - // prettier-ignore - uint256 private constant Z1 = 0x000000000000000059e26bcea0d48bacd4f263f1acdb5c4f5763473177fffffe; - - // prettier-ignore - uint256 private constant T24 = 0x1000000000000000000000000000000000000000000000000; - // prettier-ignore - uint256 private constant MASK24 = 0xffffffffffffffffffffffffffffffffffffffffffffffff; - - // estimator address -// address private constant COST_ESTIMATOR_ADDRESS = new 0x22E4a5251C1F02de8369Dd6f192033F6CB7531A4; - - function verifySingle( - uint256[2] memory signature, - uint256[4] memory pubkey, - uint256[2] memory message - ) internal view returns (bool, bool) { - uint256[12] memory input = - [ - signature[0], - signature[1], - N_G2_X1, - N_G2_X0, - N_G2_Y1, - N_G2_Y0, - message[0], - message[1], - pubkey[1], - pubkey[0], - pubkey[3], - pubkey[2] - ]; - uint256[1] memory out; - uint256 precompileGasCost = gasleft(); -// BNPairingPrecompileCostEstimator(COST_ESTIMATOR_ADDRESS).getGasCost( -// 2 -// ); - bool callSuccess; - // solium-disable-next-line security/no-inline-assembly - assembly { - callSuccess := staticcall( - precompileGasCost, - 8, - input, - 384, - out, - 0x20 - ) - } - if (!callSuccess) { - return (false, false); - } - return (out[0] != 0, true); - } - - function verifyMultiple( - uint256[2] memory signature, - uint256[4][] memory pubkeys, - uint256[2][] memory messages - ) internal view returns (bool checkResult, bool callSuccess) { - uint256 size = pubkeys.length; - require(size > 0, "BLS: number of public key is zero"); - require( - size == messages.length, - "BLS: number of public keys and messages must be equal" - ); - uint256 inputSize = (size + 1) * 6; - uint256[] memory input = new uint256[](inputSize); - input[0] = signature[0]; - input[1] = signature[1]; - input[2] = N_G2_X1; - input[3] = N_G2_X0; - input[4] = N_G2_Y1; - input[5] = N_G2_Y0; - for (uint256 i = 0; i < size; i++) { - input[i * 6 + 6] = messages[i][0]; - input[i * 6 + 7] = messages[i][1]; - input[i * 6 + 8] = pubkeys[i][1]; - input[i * 6 + 9] = pubkeys[i][0]; - input[i * 6 + 10] = pubkeys[i][3]; - input[i * 6 + 11] = pubkeys[i][2]; - } - uint256[1] memory out; - - // prettier-ignore - uint256 precompileGasCost = gasleft(); -// uint256 precompileGasCost = BNPairingPrecompileCostEstimator(COST_ESTIMATOR_ADDRESS).getGasCost(size + 1); - // solium-disable-next-line security/no-inline-assembly - assembly { - callSuccess := staticcall( - precompileGasCost, - 8, - add(input, 0x20), - mul(inputSize, 0x20), - out, - 0x20 - ) - } - if (!callSuccess) { - return (false, false); - } - return (out[0] != 0, true); - } - - /** - @notice Fouque-Tibouchi Hash to Curve - */ - function hashToPoint(bytes32 domain, bytes memory message) - internal - view - returns (uint256[2] memory) - { - uint256[2] memory u = hashToField(domain, message); - uint256[2] memory p0 = mapToPoint(u[0]); - uint256[2] memory p1 = mapToPoint(u[1]); - uint256[4] memory bnAddInput; - bnAddInput[0] = p0[0]; - bnAddInput[1] = p0[1]; - bnAddInput[2] = p1[0]; - bnAddInput[3] = p1[1]; - bool success; - // solium-disable-next-line security/no-inline-assembly - assembly { - success := staticcall(sub(gas(), 2000), 6, bnAddInput, 128, p0, 64) - switch success - case 0 { - invalid() - } - } - require(success, "BLS: bn add call failed"); - return p0; - } - - function mapToPoint(uint256 _x) - internal - pure - returns (uint256[2] memory p) - { - require(_x < N, "mapToPointFT: invalid field element"); - uint256 x = _x; - - (, bool decision) = sqrt(x); - - uint256 a0 = mulmod(x, x, N); - a0 = addmod(a0, 4, N); - uint256 a1 = mulmod(x, Z0, N); - uint256 a2 = mulmod(a1, a0, N); - a2 = inverse(a2); - a1 = mulmod(a1, a1, N); - a1 = mulmod(a1, a2, N); - - // x1 - a1 = mulmod(x, a1, N); - x = addmod(Z1, N - a1, N); - // check curve - a1 = mulmod(x, x, N); - a1 = mulmod(a1, x, N); - a1 = addmod(a1, 3, N); - bool found; - (a1, found) = sqrt(a1); - if (found) { - if (!decision) { - a1 = N - a1; - } - return [x, a1]; - } - - // x2 - x = N - addmod(x, 1, N); - // check curve - a1 = mulmod(x, x, N); - a1 = mulmod(a1, x, N); - a1 = addmod(a1, 3, N); - (a1, found) = sqrt(a1); - if (found) { - if (!decision) { - a1 = N - a1; - } - return [x, a1]; - } - - // x3 - x = mulmod(a0, a0, N); - x = mulmod(x, x, N); - x = mulmod(x, a2, N); - x = mulmod(x, a2, N); - x = addmod(x, 1, N); - // must be on curve - a1 = mulmod(x, x, N); - a1 = mulmod(a1, x, N); - a1 = addmod(a1, 3, N); - (a1, found) = sqrt(a1); - require(found, "BLS: bad ft mapping implementation"); - if (!decision) { - a1 = N - a1; - } - return [x, a1]; - } - - function isValidSignature(uint256[2] memory signature) - internal - pure - returns (bool) - { - if ((signature[0] >= N) || (signature[1] >= N)) { - return false; - } else { - return isOnCurveG1(signature); - } - } - - function isOnCurveG1(uint256[2] memory point) - internal - pure - returns (bool _isOnCurve) - { - // solium-disable-next-line security/no-inline-assembly - assembly { - let t0 := mload(point) - let t1 := mload(add(point, 32)) - let t2 := mulmod(t0, t0, N) - t2 := mulmod(t2, t0, N) - t2 := addmod(t2, 3, N) - t1 := mulmod(t1, t1, N) - _isOnCurve := eq(t1, t2) - } - } - - function isOnCurveG2(uint256[4] memory point) - internal - pure - returns (bool _isOnCurve) - { - // solium-disable-next-line security/no-inline-assembly - assembly { - // x0, x1 - let t0 := mload(point) - let t1 := mload(add(point, 32)) - // x0 ^ 2 - let t2 := mulmod(t0, t0, N) - // x1 ^ 2 - let t3 := mulmod(t1, t1, N) - // 3 * x0 ^ 2 - let t4 := add(add(t2, t2), t2) - // 3 * x1 ^ 2 - let t5 := addmod(add(t3, t3), t3, N) - // x0 * (x0 ^ 2 - 3 * x1 ^ 2) - t2 := mulmod(add(t2, sub(N, t5)), t0, N) - // x1 * (3 * x0 ^ 2 - x1 ^ 2) - t3 := mulmod(add(t4, sub(N, t3)), t1, N) - - // x ^ 3 + b - t0 := addmod( - t2, - 0x2b149d40ceb8aaae81be18991be06ac3b5b4c5e559dbefa33267e6dc24a138e5, - N - ) - t1 := addmod( - t3, - 0x009713b03af0fed4cd2cafadeed8fdf4a74fa084e52d1852e4a2bd0685c315d2, - N - ) - - // y0, y1 - t2 := mload(add(point, 64)) - t3 := mload(add(point, 96)) - // y ^ 2 - t4 := mulmod(addmod(t2, t3, N), addmod(t2, sub(N, t3), N), N) - t3 := mulmod(shl(1, t2), t3, N) - - // y ^ 2 == x ^ 3 + b - _isOnCurve := and(eq(t0, t4), eq(t1, t3)) - } - } - - function sqrt(uint256 xx) internal pure returns (uint256 x, bool hasRoot) { - x = ModexpSqrt.run(xx); - hasRoot = mulmod(x, x, N) == xx; - } - - function inverse(uint256 a) internal pure returns (uint256) { - return ModexpInverse.run(a); - } - - function hashToField(bytes32 domain, bytes memory messages) - internal - pure - returns (uint256[2] memory) - { - bytes memory _msg = expandMsgTo96(domain, messages); - uint256 u0; - uint256 u1; - uint256 a0; - uint256 a1; - // solium-disable-next-line security/no-inline-assembly - assembly { - let p := add(_msg, 24) - u1 := and(mload(p), MASK24) - p := add(_msg, 48) - u0 := and(mload(p), MASK24) - a0 := addmod(mulmod(u1, T24, N), u0, N) - p := add(_msg, 72) - u1 := and(mload(p), MASK24) - p := add(_msg, 96) - u0 := and(mload(p), MASK24) - a1 := addmod(mulmod(u1, T24, N), u0, N) - } - return [a0, a1]; - } - - function expandMsgTo96(bytes32 domain, bytes memory message) - internal - pure - returns (bytes memory) - { - // zero<64>|msg|lib_str<2>|I2OSP(0, 1)<1>|dst|dst_len<1> - uint256 t0 = message.length; - bytes memory msg0 = new bytes(32 + t0 + 64 + 4); - bytes memory out = new bytes(96); - // b0 - // solium-disable-next-line security/no-inline-assembly - assembly { - let p := add(msg0, 96) - for { - let z := 0 - } lt(z, t0) { - z := add(z, 32) - } { - mstore(add(p, z), mload(add(message, add(z, 32)))) - } - p := add(p, t0) - - mstore8(p, 0) - p := add(p, 1) - mstore8(p, 96) - p := add(p, 1) - mstore8(p, 0) - p := add(p, 1) - - mstore(p, domain) - p := add(p, 32) - mstore8(p, 32) - } - bytes32 b0 = sha256(msg0); - bytes32 bi; - t0 = 32 + 34; - - // resize intermediate message - // solium-disable-next-line security/no-inline-assembly - assembly { - mstore(msg0, t0) - } - - // b1 - - // solium-disable-next-line security/no-inline-assembly - assembly { - mstore(add(msg0, 32), b0) - mstore8(add(msg0, 64), 1) - mstore(add(msg0, 65), domain) - mstore8(add(msg0, add(32, 65)), 32) - } - - bi = sha256(msg0); - - // solium-disable-next-line security/no-inline-assembly - assembly { - mstore(add(out, 32), bi) - } - - // b2 - - // solium-disable-next-line security/no-inline-assembly - assembly { - let t := xor(b0, bi) - mstore(add(msg0, 32), t) - mstore8(add(msg0, 64), 2) - mstore(add(msg0, 65), domain) - mstore8(add(msg0, add(32, 65)), 32) - } - - bi = sha256(msg0); - - // solium-disable-next-line security/no-inline-assembly - assembly { - mstore(add(out, 64), bi) - } - - // b3 - - // solium-disable-next-line security/no-inline-assembly - assembly { - let t := xor(b0, bi) - mstore(add(msg0, 32), t) - mstore8(add(msg0, 64), 3) - mstore(add(msg0, 65), domain) - mstore8(add(msg0, add(32, 65)), 32) - } - - bi = sha256(msg0); - - // solium-disable-next-line security/no-inline-assembly - assembly { - mstore(add(out, 96), bi) - } - - return out; - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/lib/hubble-contracts/contracts/libs/ModExp.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/lib/hubble-contracts/contracts/libs/ModExp.sol deleted file mode 100644 index 6fd08f118c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/bls/lib/hubble-contracts/contracts/libs/ModExp.sol +++ /dev/null @@ -1,652 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >= 0.6.12; - -/** - @title Compute Inverse by Modular Exponentiation - @notice Compute $input^(N - 2) mod N$ using Addition Chain method. - Where N = 0x30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47 - and N - 2 = 0x30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd45 - @dev the function body is generated with the modified addchain script - see https://github.com/kobigurk/addchain/commit/2c37a2ace567a9bdc680b4e929c94aaaa3ec700f - */ -library ModexpInverse { - function run(uint256 t2) internal pure returns (uint256 t0) { - // solium-disable-next-line security/no-inline-assembly - assembly { - let - n - := 0x30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47 - t0 := mulmod(t2, t2, n) - let t5 := mulmod(t0, t2, n) - let t1 := mulmod(t5, t0, n) - let t3 := mulmod(t5, t5, n) - let t8 := mulmod(t1, t0, n) - let t4 := mulmod(t3, t5, n) - let t6 := mulmod(t3, t1, n) - t0 := mulmod(t3, t3, n) - let t7 := mulmod(t8, t3, n) - t3 := mulmod(t4, t3, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t7, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t1, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t1, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t7, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t1, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t1, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t1, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t1, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t4, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t1, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t7, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t3, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t3, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t4, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t3, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t1, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t1, n) - } - } -} - -/** - @title Compute Squre Root by Modular Exponentiation - @notice Compute $input^{(N + 1) / 4} mod N$ using Addition Chain method. - Where N = 0x30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47 - and (N + 1) / 4 = 0xc19139cb84c680a6e14116da060561765e05aa45a1c72a34f082305b61f3f52 - */ -library ModexpSqrt { - function run(uint256 t6) internal pure returns (uint256 t0) { - // solium-disable-next-line security/no-inline-assembly - assembly { - let - n - := 0x30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47 - - t0 := mulmod(t6, t6, n) - let t4 := mulmod(t0, t6, n) - let t2 := mulmod(t4, t0, n) - let t3 := mulmod(t4, t4, n) - let t8 := mulmod(t2, t0, n) - let t1 := mulmod(t3, t4, n) - let t5 := mulmod(t3, t2, n) - t0 := mulmod(t3, t3, n) - let t7 := mulmod(t8, t3, n) - t3 := mulmod(t1, t3, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t4, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t4, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t7, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t4, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t7, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t4, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t4, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t1, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t8, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t7, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t3, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t6, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t4, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t5, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t4, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t4, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t3, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t1, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t3, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t2, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t0, n) - t0 := mulmod(t0, t1, n) - t0 := mulmod(t0, t0, n) - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/callback/TokenCallbackHandler.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/callback/TokenCallbackHandler.sol deleted file mode 100644 index 2b4a72ffc1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/callback/TokenCallbackHandler.sol +++ /dev/null @@ -1,51 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -/* solhint-disable no-empty-blocks */ - -import "@openzeppelin/contracts/utils/introspection/IERC165.sol"; -import "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol"; -import "@openzeppelin/contracts/token/ERC1155/IERC1155Receiver.sol"; - -/** - * Token callback handler. - * Handles supported tokens' callbacks, allowing account receiving these tokens. - */ -abstract contract TokenCallbackHandler is IERC721Receiver, IERC1155Receiver { - - function onERC721Received( - address, - address, - uint256, - bytes calldata - ) external pure override returns (bytes4) { - return IERC721Receiver.onERC721Received.selector; - } - - function onERC1155Received( - address, - address, - uint256, - uint256, - bytes calldata - ) external pure override returns (bytes4) { - return IERC1155Receiver.onERC1155Received.selector; - } - - function onERC1155BatchReceived( - address, - address, - uint256[] calldata, - uint256[] calldata, - bytes calldata - ) external pure override returns (bytes4) { - return IERC1155Receiver.onERC1155BatchReceived.selector; - } - - function supportsInterface(bytes4 interfaceId) external view virtual override returns (bool) { - return - interfaceId == type(IERC721Receiver).interfaceId || - interfaceId == type(IERC1155Receiver).interfaceId || - interfaceId == type(IERC165).interfaceId; - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/utils/IOracle.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/utils/IOracle.sol deleted file mode 100644 index a8c2381263..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/utils/IOracle.sol +++ /dev/null @@ -1,10 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.23; - -interface IOracle { - function decimals() external view returns (uint8); - function latestRoundData() - external - view - returns (uint80 roundId, int256 answer, uint256 startedAt, uint256 updatedAt, uint80 answeredInRound); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/utils/OracleHelper.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/utils/OracleHelper.sol deleted file mode 100644 index 49e6fcf5c5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/utils/OracleHelper.sol +++ /dev/null @@ -1,170 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -/* solhint-disable not-rely-on-time */ - -import "./IOracle.sol"; - -/// @title Helper functions for dealing with various forms of price feed oracles. -/// @notice Maintains a price cache and updates the current price if needed. -/// In the best case scenario we have a direct oracle from the token to the native asset. -/// Also support tokens that have no direct price oracle to the native asset. -/// Sometimes oracles provide the price in the opposite direction of what we need in the moment. -abstract contract OracleHelper { - - event TokenPriceUpdated(uint256 currentPrice, uint256 previousPrice, uint256 cachedPriceTimestamp); - - uint256 private constant PRICE_DENOMINATOR = 1e26; - - struct OracleHelperConfig { - - /// @notice The price cache will be returned without even fetching the oracles for this number of seconds - uint48 cacheTimeToLive; - - /// @notice The maximum acceptable age of the price oracle round - uint48 maxOracleRoundAge; - - /// @notice The Oracle contract used to fetch the latest token prices - IOracle tokenOracle; - - /// @notice The Oracle contract used to fetch the latest native asset prices. Only needed if tokenToNativeOracle flag is not set. - IOracle nativeOracle; - - /// @notice If 'true' we will fetch price directly from tokenOracle - /// @notice If 'false' we will use nativeOracle to establish a token price through a shared third currency - bool tokenToNativeOracle; - - /// @notice 'false' if price is bridging-asset-per-token (or native-asset-per-token), 'true' if price is tokens-per-bridging-asset - bool tokenOracleReverse; - - /// @notice 'false' if price is bridging-asset-per-native-asset, 'true' if price is native-asset-per-bridging-asset - bool nativeOracleReverse; - - /// @notice The price update threshold percentage from PRICE_DENOMINATOR that triggers a price update (1e26 = 100%) - uint256 priceUpdateThreshold; - - } - - /// @notice The cached token price from the Oracle, always in (native-asset-per-token) * PRICE_DENOMINATOR format - uint256 public cachedPrice; - - /// @notice The timestamp of a block when the cached price was updated - uint48 public cachedPriceTimestamp; - - OracleHelperConfig private oracleHelperConfig; - - /// @notice The "10^(tokenOracle.decimals)" value used for the price calculation - uint128 private tokenOracleDecimalPower; - - /// @notice The "10^(nativeOracle.decimals)" value used for the price calculation - uint128 private nativeOracleDecimalPower; - - constructor ( - OracleHelperConfig memory _oracleHelperConfig - ) { - cachedPrice = type(uint256).max; // initialize the storage slot to invalid value - _setOracleConfiguration( - _oracleHelperConfig - ); - } - - function _setOracleConfiguration( - OracleHelperConfig memory _oracleHelperConfig - ) private { - oracleHelperConfig = _oracleHelperConfig; - require(_oracleHelperConfig.priceUpdateThreshold <= PRICE_DENOMINATOR, "TPM: update threshold too high"); - tokenOracleDecimalPower = uint128(10 ** oracleHelperConfig.tokenOracle.decimals()); - if (oracleHelperConfig.tokenToNativeOracle) { - require(address(oracleHelperConfig.nativeOracle) == address(0), "TPM: native oracle must be zero"); - nativeOracleDecimalPower = 1; - } else { - nativeOracleDecimalPower = uint128(10 ** oracleHelperConfig.nativeOracle.decimals()); - } - } - - /// @notice Updates the token price by fetching the latest price from the Oracle. - /// @param force true to force cache update, even if called after short time or the change is lower than the update threshold. - /// @return newPrice the new cached token price - function updateCachedPrice(bool force) public returns (uint256) { - uint256 cacheTimeToLive = oracleHelperConfig.cacheTimeToLive; - uint256 cacheAge = block.timestamp - cachedPriceTimestamp; - if (!force && cacheAge <= cacheTimeToLive) { - return cachedPrice; - } - uint256 priceUpdateThreshold = oracleHelperConfig.priceUpdateThreshold; - IOracle tokenOracle = oracleHelperConfig.tokenOracle; - IOracle nativeOracle = oracleHelperConfig.nativeOracle; - - uint256 _cachedPrice = cachedPrice; - uint256 tokenPrice = fetchPrice(tokenOracle); - uint256 nativeAssetPrice = 1; - // If the 'TokenOracle' returns the price in the native asset units there is no need to fetch native asset price - if (!oracleHelperConfig.tokenToNativeOracle) { - nativeAssetPrice = fetchPrice(nativeOracle); - } - uint256 newPrice = calculatePrice( - tokenPrice, - nativeAssetPrice, - oracleHelperConfig.tokenOracleReverse, - oracleHelperConfig.nativeOracleReverse - ); - uint256 priceRatio = PRICE_DENOMINATOR * newPrice / _cachedPrice; - bool updateRequired = force || - priceRatio > PRICE_DENOMINATOR + priceUpdateThreshold || - priceRatio < PRICE_DENOMINATOR - priceUpdateThreshold; - if (!updateRequired) { - return _cachedPrice; - } - cachedPrice = newPrice; - cachedPriceTimestamp = uint48(block.timestamp); - emit TokenPriceUpdated(newPrice, _cachedPrice, cachedPriceTimestamp); - return newPrice; - } - - /** - * Calculate the effective price of the selected token denominated in native asset. - * - * @param tokenPrice - the price of the token relative to a native asset or a bridging asset like the U.S. dollar. - * @param nativeAssetPrice - the price of the native asset relative to a bridging asset or 1 if no bridging needed. - * @param tokenOracleReverse - flag indicating direction of the "tokenPrice". - * @param nativeOracleReverse - flag indicating direction of the "nativeAssetPrice". - * @return the native-asset-per-token price multiplied by the PRICE_DENOMINATOR constant. - */ - function calculatePrice( - uint256 tokenPrice, - uint256 nativeAssetPrice, - bool tokenOracleReverse, - bool nativeOracleReverse - ) private view returns (uint256){ - // tokenPrice is normalized as bridging-asset-per-token - if (tokenOracleReverse) { - // inverting tokenPrice that was tokens-per-bridging-asset (or tokens-per-native-asset) - tokenPrice = PRICE_DENOMINATOR * tokenOracleDecimalPower / tokenPrice; - } else { - // tokenPrice already bridging-asset-per-token (or native-asset-per-token) - tokenPrice = PRICE_DENOMINATOR * tokenPrice / tokenOracleDecimalPower; - } - - if (nativeOracleReverse) { - // multiplying by nativeAssetPrice that is native-asset-per-bridging-asset - // => result = (bridging-asset / token) * (native-asset / bridging-asset) = native-asset / token - return nativeAssetPrice * tokenPrice / nativeOracleDecimalPower; - } else { - // dividing by nativeAssetPrice that is bridging-asset-per-native-asset - // => result = (bridging-asset / token) / (bridging-asset / native-asset) = native-asset / token - return tokenPrice * nativeOracleDecimalPower / nativeAssetPrice; - } - } - - /// @notice Fetches the latest price from the given Oracle. - /// @dev This function is used to get the latest price from the tokenOracle or nativeOracle. - /// @param _oracle The Oracle contract to fetch the price from. - /// @return price The latest price fetched from the Oracle. - function fetchPrice(IOracle _oracle) internal view returns (uint256 price) { - (uint80 roundId, int256 answer,, uint256 updatedAt, uint80 answeredInRound) = _oracle.latestRoundData(); - require(answer > 0, "TPM: Chainlink price <= 0"); - require(updatedAt >= block.timestamp - oracleHelperConfig.maxOracleRoundAge, "TPM: Incomplete round"); - require(answeredInRound >= roundId, "TPM: Stale price"); - price = uint256(answer); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/utils/UniswapHelper.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/utils/UniswapHelper.sol deleted file mode 100644 index a670ced8d2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/samples/utils/UniswapHelper.sol +++ /dev/null @@ -1,111 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.23; - -/* solhint-disable not-rely-on-time */ - -import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; - -import "@uniswap/v3-periphery/contracts/interfaces/ISwapRouter.sol"; -import "@uniswap/v3-periphery/contracts/interfaces/IPeripheryPayments.sol"; - -abstract contract UniswapHelper { - event UniswapReverted(address tokenIn, address tokenOut, uint256 amountIn, uint256 amountOutMin); - - uint256 private constant PRICE_DENOMINATOR = 1e26; - - struct UniswapHelperConfig { - /// @notice Minimum native asset amount to receive from a single swap - uint256 minSwapAmount; - - uint24 uniswapPoolFee; - - uint8 slippage; - } - - /// @notice The Uniswap V3 SwapRouter contract - ISwapRouter public immutable uniswap; - - /// @notice The ERC20 token used for transaction fee payments - IERC20 public immutable token; - - /// @notice The ERC-20 token that wraps the native asset for current chain - IERC20 public immutable wrappedNative; - - UniswapHelperConfig private uniswapHelperConfig; - - constructor( - IERC20 _token, - IERC20 _wrappedNative, - ISwapRouter _uniswap, - UniswapHelperConfig memory _uniswapHelperConfig - ){ - _token.approve(address(_uniswap), type(uint256).max); - token = _token; - wrappedNative = _wrappedNative; - uniswap = _uniswap; - _setUniswapHelperConfiguration(_uniswapHelperConfig); - } - - function _setUniswapHelperConfiguration(UniswapHelperConfig memory _uniswapHelperConfig) internal { - uniswapHelperConfig = _uniswapHelperConfig; - } - - function _maybeSwapTokenToWeth(IERC20 tokenIn, uint256 quote) internal returns (uint256) { - uint256 tokenBalance = tokenIn.balanceOf(address(this)); - uint256 amountOutMin = addSlippage(tokenToWei(tokenBalance, quote), uniswapHelperConfig.slippage); - if (amountOutMin < uniswapHelperConfig.minSwapAmount) { - return 0; - } - // note: calling 'swapToToken' but destination token is Wrapped Ether - return swapToToken( - address(tokenIn), - address(wrappedNative), - tokenBalance, - amountOutMin, - uniswapHelperConfig.uniswapPoolFee - ); - } - - function addSlippage(uint256 amount, uint8 slippage) private pure returns (uint256) { - return amount * (1000 - slippage) / 1000; - } - - - function tokenToWei(uint256 amount, uint256 price) public pure returns (uint256) { - return amount * price / PRICE_DENOMINATOR; - } - - function weiToToken(uint256 amount, uint256 price) public pure returns (uint256) { - return amount * PRICE_DENOMINATOR / price; - } - - function unwrapWeth(uint256 amount) internal { - IPeripheryPayments(address(uniswap)).unwrapWETH9(amount, address(this)); - } - - // swap ERC-20 tokens at market price - function swapToToken( - address tokenIn, - address tokenOut, - uint256 amountIn, - uint256 amountOutMin, - uint24 fee - ) internal returns (uint256 amountOut) { - ISwapRouter.ExactInputSingleParams memory params = ISwapRouter.ExactInputSingleParams( - tokenIn, //tokenIn - tokenOut, //tokenOut - fee, - address(uniswap), - block.timestamp, //deadline - amountIn, - amountOutMin, - 0 - ); - try uniswap.exactInputSingle(params) returns (uint256 _amountOut) { - amountOut = _amountOut; - } catch { - emit UniswapReverted(tokenIn, tokenOut, amountIn, amountOutMin); - amountOut = 0; - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/utils/Exec.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/utils/Exec.sol deleted file mode 100644 index ee8d71ac0d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/contracts/utils/Exec.sol +++ /dev/null @@ -1,70 +0,0 @@ -// SPDX-License-Identifier: LGPL-3.0-only -pragma solidity ^0.8.23; - -// solhint-disable no-inline-assembly - -/** - * Utility functions helpful when making different kinds of contract calls in Solidity. - */ -library Exec { - - function call( - address to, - uint256 value, - bytes memory data, - uint256 txGas - ) internal returns (bool success) { - assembly ("memory-safe") { - success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0) - } - } - - function staticcall( - address to, - bytes memory data, - uint256 txGas - ) internal view returns (bool success) { - assembly ("memory-safe") { - success := staticcall(txGas, to, add(data, 0x20), mload(data), 0, 0) - } - } - - function delegateCall( - address to, - bytes memory data, - uint256 txGas - ) internal returns (bool success) { - assembly ("memory-safe") { - success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0) - } - } - - // get returned data from last call or calldelegate - function getReturnData(uint256 maxLen) internal pure returns (bytes memory returnData) { - assembly ("memory-safe") { - let len := returndatasize() - if gt(len, maxLen) { - len := maxLen - } - let ptr := mload(0x40) - mstore(0x40, add(ptr, add(len, 0x20))) - mstore(ptr, len) - returndatacopy(add(ptr, 0x20), 0, len) - returnData := ptr - } - } - - // revert with explicit byte array (probably reverted info from call) - function revertWithData(bytes memory returnData) internal pure { - assembly ("memory-safe") { - revert(add(returnData, 32), mload(returnData)) - } - } - - function callAndRevert(address to, bytes memory data, uint256 maxLen) internal { - bool success = call(to,0,data,gasleft()); - if (!success) { - revertWithData(getReturnData(maxLen)); - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deploy/1_deploy_entrypoint.ts b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deploy/1_deploy_entrypoint.ts deleted file mode 100644 index fbfdb836b4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deploy/1_deploy_entrypoint.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { HardhatRuntimeEnvironment } from 'hardhat/types' -import { DeployFunction } from 'hardhat-deploy/types' -import { ethers } from 'hardhat' - -const deployEntryPoint: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { - const provider = ethers.provider - const from = await provider.getSigner().getAddress() - - const ret = await hre.deployments.deploy('EntryPoint', { - from, - args: [], - gasLimit: 6e6, - deterministicDeployment: process.env.SALT ?? true, - log: true, - }) - console.log('==entrypoint addr=', ret.address) -} - -export default deployEntryPoint diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deploy/2_deploy_SimpleAccountFactory.ts b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deploy/2_deploy_SimpleAccountFactory.ts deleted file mode 100644 index 88d7429155..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deploy/2_deploy_SimpleAccountFactory.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { HardhatRuntimeEnvironment } from 'hardhat/types' -import { DeployFunction } from 'hardhat-deploy/types' -import { ethers } from 'hardhat' - -const deploySimpleAccountFactory: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { - const provider = ethers.provider - const from = await provider.getSigner().getAddress() - const network = await provider.getNetwork() - // only deploy on local test network. - - const forceDeployFactory = process.argv.join(' ').match(/simple-account-factory/) != null - - if (!forceDeployFactory && network.chainId !== 31337 && network.chainId !== 1337) { - return - } - - const entrypoint = await hre.deployments.get('EntryPoint') - await hre.deployments.deploy('SimpleAccountFactory', { - from, - args: [entrypoint.address], - gasLimit: 6e6, - log: true, - deterministicDeployment: true, - }) - - await hre.deployments.deploy('TestCounter', { - from, - deterministicDeployment: true, - log: true, - }) -} - -export default deploySimpleAccountFactory diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/arbitrum/.chainId b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/arbitrum/.chainId deleted file mode 100644 index 7df83ecbe3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/arbitrum/.chainId +++ /dev/null @@ -1 +0,0 @@ -42161 \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/arbitrum/EntryPoint.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/arbitrum/EntryPoint.json deleted file mode 100644 index 916c239083..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/arbitrum/EntryPoint.json +++ /dev/null @@ -1,1318 +0,0 @@ -{ - "address": "0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789", - "abi": [ - { - "inputs": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "paid", - "type": "uint256" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bool", - "name": "targetSuccess", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "targetResult", - "type": "bytes" - } - ], - "name": "ExecutionResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "opIndex", - "type": "uint256" - }, - { - "internalType": "string", - "name": "reason", - "type": "string" - } - ], - "name": "FailedOp", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - } - ], - "name": "SenderAddressResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureValidationFailed", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - } - ], - "name": "ValidationResult", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "stakeInfo", - "type": "tuple" - } - ], - "internalType": "struct IEntryPoint.AggregatorStakeInfo", - "name": "aggregatorInfo", - "type": "tuple" - } - ], - "name": "ValidationResultWithAggregation", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "factory", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "paymaster", - "type": "address" - } - ], - "name": "AccountDeployed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [], - "name": "BeforeExecution", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalDeposit", - "type": "uint256" - } - ], - "name": "Deposited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureAggregatorChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalStaked", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "name": "StakeLocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "withdrawTime", - "type": "uint256" - } - ], - "name": "StakeUnlocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "StakeWithdrawn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasUsed", - "type": "uint256" - } - ], - "name": "UserOperationEvent", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "revertReason", - "type": "bytes" - } - ], - "name": "UserOperationRevertReason", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "Withdrawn", - "type": "event" - }, - { - "inputs": [], - "name": "SIG_VALIDATION_FAILED", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - } - ], - "name": "_validateSenderAndPaymaster", - "outputs": [], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - } - ], - "name": "addStake", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "depositTo", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "deposits", - "outputs": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "getDepositInfo", - "outputs": [ - { - "components": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "internalType": "struct IStakeManager.DepositInfo", - "name": "info", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "getNonce", - "outputs": [ - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - } - ], - "name": "getSenderAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "getUserOpHash", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "userOps", - "type": "tuple[]" - }, - { - "internalType": "contract IAggregator", - "name": "aggregator", - "type": "address" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.UserOpsPerAggregator[]", - "name": "opsPerAggregator", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleAggregatedOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "ops", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "incrementNonce", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.MemoryUserOp", - "name": "mUserOp", - "type": "tuple" - }, - { - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "contextOffset", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.UserOpInfo", - "name": "opInfo", - "type": "tuple" - }, - { - "internalType": "bytes", - "name": "context", - "type": "bytes" - } - ], - "name": "innerHandleOp", - "outputs": [ - { - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - }, - { - "internalType": "uint192", - "name": "", - "type": "uint192" - } - ], - "name": "nonceSequenceNumber", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "op", - "type": "tuple" - }, - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "targetCallData", - "type": "bytes" - } - ], - "name": "simulateHandleOp", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "simulateValidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unlockStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - } - ], - "name": "withdrawStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "withdrawAmount", - "type": "uint256" - } - ], - "name": "withdrawTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "args": [], - "numDeployments": 1, - "solcInputHash": "a4c52f0671aad8941c53d6ead2063803", - "metadata": "{\"compiler\":{\"version\":\"0.8.17+commit.8df45f5f\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"paid\",\"type\":\"uint256\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bool\",\"name\":\"targetSuccess\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"targetResult\",\"type\":\"bytes\"}],\"name\":\"ExecutionResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"opIndex\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\"}],\"name\":\"FailedOp\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderAddressResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureValidationFailed\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResult\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"stakeInfo\",\"type\":\"tuple\"}],\"internalType\":\"struct IEntryPoint.AggregatorStakeInfo\",\"name\":\"aggregatorInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResultWithAggregation\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"factory\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"}],\"name\":\"AccountDeployed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"BeforeExecution\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalDeposit\",\"type\":\"uint256\"}],\"name\":\"Deposited\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureAggregatorChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalStaked\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"name\":\"StakeLocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"withdrawTime\",\"type\":\"uint256\"}],\"name\":\"StakeUnlocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"StakeWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasUsed\",\"type\":\"uint256\"}],\"name\":\"UserOperationEvent\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"revertReason\",\"type\":\"bytes\"}],\"name\":\"UserOperationRevertReason\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Withdrawn\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"SIG_VALIDATION_FAILED\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"}],\"name\":\"_validateSenderAndPaymaster\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"}],\"name\":\"addStake\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"depositTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"deposits\",\"outputs\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getDepositInfo\",\"outputs\":[{\"components\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"internalType\":\"struct IStakeManager.DepositInfo\",\"name\":\"info\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"}],\"name\":\"getSenderAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"getUserOpHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"userOps\",\"type\":\"tuple[]\"},{\"internalType\":\"contract IAggregator\",\"name\":\"aggregator\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.UserOpsPerAggregator[]\",\"name\":\"opsPerAggregator\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleAggregatedOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"ops\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"incrementNonce\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.MemoryUserOp\",\"name\":\"mUserOp\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"contextOffset\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.UserOpInfo\",\"name\":\"opInfo\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"context\",\"type\":\"bytes\"}],\"name\":\"innerHandleOp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"\",\"type\":\"uint192\"}],\"name\":\"nonceSequenceNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"op\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"targetCallData\",\"type\":\"bytes\"}],\"name\":\"simulateHandleOp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"simulateValidation\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unlockStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"}],\"name\":\"withdrawStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"withdrawAmount\",\"type\":\"uint256\"}],\"name\":\"withdrawTo\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"errors\":{\"FailedOp(uint256,string)\":[{\"params\":{\"opIndex\":\"- index into the array of ops to the failed one (in simulateValidation, this is always zero)\",\"reason\":\"- revert reason The string starts with a unique code \\\"AAmn\\\", where \\\"m\\\" is \\\"1\\\" for factory, \\\"2\\\" for account and \\\"3\\\" for paymaster issues, so a failure can be attributed to the correct entity. Should be caught in off-chain handleOps simulation and not happen on-chain. Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\"}}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"params\":{\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"params\":{\"aggregatorInfo\":\"signature aggregation info (if the account requires signature aggregator) bundler MUST use it to verify the signature, or reject the UserOperation\",\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}]},\"kind\":\"dev\",\"methods\":{\"addStake(uint32)\":{\"params\":{\"unstakeDelaySec\":\"the new lock duration before the deposit can be withdrawn.\"}},\"getDepositInfo(address)\":{\"returns\":{\"info\":\"- full deposit information of given account\"}},\"getNonce(address,uint192)\":{\"params\":{\"key\":\"the high 192 bit of the nonce\",\"sender\":\"the account address\"},\"returns\":{\"nonce\":\"a full nonce to pass for next UserOp with this sender.\"}},\"getSenderAddress(bytes)\":{\"params\":{\"initCode\":\"the constructor code to be passed into the UserOperation.\"}},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"opsPerAggregator\":\"the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\"}},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"ops\":\"the operations to execute\"}},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"params\":{\"op\":\"the UserOperation to simulate\",\"target\":\"if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult are set to the return from that call.\",\"targetCallData\":\"callData to pass to target address\"}},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"details\":\"this method always revert. Successful result is ValidationResult error. other errors are failures.The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\",\"params\":{\"userOp\":\"the user operation to validate.\"}},\"withdrawStake(address)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\"}},\"withdrawTo(address,uint256)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\",\"withdrawAmount\":\"the amount to withdraw.\"}}},\"version\":1},\"userdoc\":{\"errors\":{\"ExecutionResult(uint256,uint256,uint48,uint48,bool,bytes)\":[{\"notice\":\"return value of simulateHandleOp\"}],\"FailedOp(uint256,string)\":[{\"notice\":\"a custom revert error of handleOps, to identify the offending op. NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\"}],\"SenderAddressResult(address)\":[{\"notice\":\"return value of getSenderAddress\"}],\"SignatureValidationFailed(address)\":[{\"notice\":\"error case when a signature aggregator fails to verify the aggregated signature it had created.\"}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"notice\":\"Successful result from simulateValidation.\"}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"notice\":\"Successful result from simulateValidation, if the account returns a signature aggregator\"}]},\"events\":{\"AccountDeployed(bytes32,address,address,address)\":{\"notice\":\"account \\\"sender\\\" was deployed.\"},\"BeforeExecution()\":{\"notice\":\"an event emitted by handleOps(), before starting the execution loop. any event emitted before this event, is part of the validation.\"},\"SignatureAggregatorChanged(address)\":{\"notice\":\"signature aggregator used by the following UserOperationEvents within this bundle.\"},\"StakeLocked(address,uint256,uint256)\":{\"notice\":\"Emitted when stake or unstake delay are modified\"},\"StakeUnlocked(address,uint256)\":{\"notice\":\"Emitted once a stake is scheduled for withdrawal\"},\"UserOperationRevertReason(bytes32,address,uint256,bytes)\":{\"notice\":\"An event emitted if the UserOperation \\\"callData\\\" reverted with non-zero length\"}},\"kind\":\"user\",\"methods\":{\"SIG_VALIDATION_FAILED()\":{\"notice\":\"for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value in case of signature failure, instead of revert.\"},\"_validateSenderAndPaymaster(bytes,address,bytes)\":{\"notice\":\"Called only during simulation. This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\"},\"addStake(uint32)\":{\"notice\":\"add to the account's stake - amount and delay any pending unstake is first cancelled.\"},\"balanceOf(address)\":{\"notice\":\"return the deposit (for gas payment) of the account\"},\"depositTo(address)\":{\"notice\":\"add to the deposit of the given account\"},\"deposits(address)\":{\"notice\":\"maps paymaster to their deposits and stakes\"},\"getNonce(address,uint192)\":{\"notice\":\"Return the next nonce for this sender. Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop) But UserOp with different keys can come with arbitrary order.\"},\"getSenderAddress(bytes)\":{\"notice\":\"Get counterfactual sender address. Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation. this method always revert, and returns the address in SenderAddressResult error\"},\"getUserOpHash((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"generate a request Id - unique identifier for this request. the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\"},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperation with Aggregators\"},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperations. no signature aggregator is used. if any account requires an aggregator (that is, it returned an aggregator when performing simulateValidation), then handleAggregatedOps() must be used instead.\"},\"incrementNonce(uint192)\":{\"notice\":\"Manually increment the nonce of the sender. This method is exposed just for completeness.. Account does NOT need to call it, neither during validation, nor elsewhere, as the EntryPoint will update the nonce regardless. Possible use-case is call it with various keys to \\\"initialize\\\" their nonces to one, so that future UserOperations will not pay extra for the first transaction with a given key.\"},\"innerHandleOp(bytes,((address,uint256,uint256,uint256,uint256,address,uint256,uint256),bytes32,uint256,uint256,uint256),bytes)\":{\"notice\":\"inner function to handle a UserOperation. Must be declared \\\"external\\\" to open a call context, but it can only be called by handleOps.\"},\"nonceSequenceNumber(address,uint192)\":{\"notice\":\"The next valid sequence number for a given nonce key.\"},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"notice\":\"simulate full execution of a UserOperation (including both validation and target execution) this method will always revert with \\\"ExecutionResult\\\". it performs full validation of the UserOperation, but ignores signature error. an optional target address is called after the userop succeeds, and its value is returned (before the entire call is reverted) Note that in order to collect the the success/failure of the target call, it must be executed with trace enabled to track the emitted events.\"},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\"},\"unlockStake()\":{\"notice\":\"attempt to unlock the stake. the value can be withdrawn (using withdrawStake) after the unstake delay.\"},\"withdrawStake(address)\":{\"notice\":\"withdraw from the (unlocked) stake. must first call unlockStake and wait for the unstakeDelay to pass\"},\"withdrawTo(address,uint256)\":{\"notice\":\"withdraw from the deposit.\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/core/EntryPoint.sol\":\"EntryPoint\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":1000000},\"remappings\":[],\"viaIR\":true},\"sources\":{\"@openzeppelin/contracts/security/ReentrancyGuard.sol\":{\"keccak256\":\"0x190dd6f8d592b7e4e930feb7f4313aeb8e1c4ad3154c27ce1cf6a512fc30d8cc\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://4ce8dfb62d0c4fa260d6eec8f1cd47f5f2a044e11bde5b31d18072fa6e7d9010\",\"dweb:/ipfs/QmTyFztU3tLEcEDnqqiaW4UJetqsU77LXc6pjc9oTXCK5u\"]},\"contracts/core/EntryPoint.sol\":{\"keccak256\":\"0x04f86318b47f052d7308795ffae6ecec0d023d2458b4e17751b89a0e4acfcdc6\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://c9f6e359c8dbe875ad974d3a0fb7b3d62319a6b115c44bac1e4587ae2ad2edaf\",\"dweb:/ipfs/QmTSWTov2rUeYk8cwzrtsd3uVXokCYok4gMiZ1sPs9tycH\"]},\"contracts/core/Helpers.sol\":{\"keccak256\":\"0x591c87519f7155d1909210276b77925ab2722a99b7b5d5649aecc36ebbdb045a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://69643e83f68e6a13d5075c7565bfce326673b0bd98c432033c4603ea84835746\",\"dweb:/ipfs/QmSwSzjYyV7qudi5vvsmzHMG2Z4YJZxX51RRXXVCLaNcEU\"]},\"contracts/core/NonceManager.sol\":{\"keccak256\":\"0xa17a4a6fde70088ab18ffe6df830f3efa31f1cd0e1a7160336c96e3c94984d25\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://b38615df9f80c56282b72888e9ba1eb1a9413fa67a0dbf094deda7af9feb38e7\",\"dweb:/ipfs/QmSzcXetEJRH4UHuUmZiSgX6bFgfqHWfmyuxVnh4NosMk1\"]},\"contracts/core/SenderCreator.sol\":{\"keccak256\":\"0x44b9449fec82d6cdfb01d52fdd5a72f90099c651316123810cf9633f00b018c2\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a9c0487390e72638681d175c45bc92425c802fffdca4bd0ae8457782ee284612\",\"dweb:/ipfs/QmVbzuehCUWJWqEHyMWuc6cRVbxfcMdFsmGL9o4Wz7WY2x\"]},\"contracts/core/StakeManager.sol\":{\"keccak256\":\"0x21aa0956382bd000b1b8c3b1d19ca6ebcd6c9029eebb19c612fb38ee5dd2430a\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://0a625c8795354d9f429367f9c1d14eb8af7db9c7f2c2a2033e2066ced76a573a\",\"dweb:/ipfs/Qmd1j6UarUg54q1G2HCNCLQz8XGVZR1qxX7eQ6cytHpQPN\"]},\"contracts/interfaces/IAccount.sol\":{\"keccak256\":\"0x556a0e5980de18e90b115553ed502408155ba35f58642823010d9288047bc418\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a0f420134b79596db8737173c7b933ae0a33059e107b6327c43aa40d4744a9e4\",\"dweb:/ipfs/QmRo8s1AhXmEMV7uPYnbpYwU19e9Bk6jmYBJTiPx3Fo85W\"]},\"contracts/interfaces/IAggregator.sol\":{\"keccak256\":\"0x060e9ddb0152250c269ba0640dc5753834ac44cf182a2837d508c0c529cae26a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://20ed837bc5909c89ff1910246bf245a5dad6840aa939382e1694964eb7dbd37b\",\"dweb:/ipfs/QmTMybRq5yyghPDDs1ZCNAVB9sSJ4WHe6Q9mejuKPTAdNP\"]},\"contracts/interfaces/IEntryPoint.sol\":{\"keccak256\":\"0x3a90bf308819ed125fa4202f880999caff8a8686633b8ddb79a30ca240d5b8f8\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://d2d21cc92c2fdab2b58d21bc25d4cd0e8c284b922528a186b087b818d54bc6cf\",\"dweb:/ipfs/QmT1qrfuBjsv2rmRCDn8mgPXHp94hARJwzbcDuBLDTbFWd\"]},\"contracts/interfaces/INonceManager.sol\":{\"keccak256\":\"0x509871e6c63663cdcc3eba19920fe84e991f38b289b1377ac3c3a6d9f22d7e12\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://00fe21b4349b24c50df60e1a705179293982bd9e7a32b78d4bac9620f89e7fe2\",\"dweb:/ipfs/QmSFFYGfUwQbVa6hASjU7YxTvgi2HkfrPr4X5oPHscHg8b\"]},\"contracts/interfaces/IPaymaster.sol\":{\"keccak256\":\"0x36858ba8685024974f533530420688da3454d29996ebc42e410673a1ed2ec456\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://616cbcf51778b1961b7f20a547bec7efae6d1d565df0f651926241ed8bde9ad8\",\"dweb:/ipfs/QmaVsgffUUmeUJYgStvRr8cNZ1LBbrc3FYNLW4JT1dVLia\"]},\"contracts/interfaces/IStakeManager.sol\":{\"keccak256\":\"0xd227b02888cd4ac68daebcdfd992ec00f9fff66fa3b3bb16f656cd582fa3480f\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://b389da4714a138be63704a576a482505eab2855e263b38a93706395d8d42e7c3\",\"dweb:/ipfs/QmeeAZpdHwUXxqP8pxA7GNtoCGBmmH4FaqLLwScVKGxtxZ\"]},\"contracts/interfaces/UserOperation.sol\":{\"keccak256\":\"0x61374003361059087fdcf17967a7bba052badeaf5c7f0ae689166f8aafd3a45c\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://6ff83c59432e733bf6304dda27cd4b0f34401917dd535e2669cc842d2d26568c\",\"dweb:/ipfs/QmPJbHU5TAjHqUTZzAcicEeG2nknmwCN43L4EW9LHbknTN\"]},\"contracts/utils/Exec.sol\":{\"keccak256\":\"0x5b232117afbc2939f3ffc92745614867e9e1d475a3e1e5443adae13c200174f1\",\"license\":\"LGPL-3.0-only\",\"urls\":[\"bzz-raw://62e7365379a06ead7b47637945bcaee095d51aab1d3ac00ddec69443e6cbe9fe\",\"dweb:/ipfs/QmctG3aw4U3KMSMeJKoLJ1NJewjMWfppnd1m3kxNTe39Uy\"]}},\"version\":1}", - "bytecode": "0x60a080604052346200008957600160025561022c8181016001600160401b038111838210176200007357829162005d18833903906000f080156200006757608052604051615c8990816200008f82396080518181816113df01528181613e9501526141b60152f35b6040513d6000823e3d90fd5b634e487b7160e01b600052604160045260246000fd5b600080fdfe60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c634300081100336080806040523461001657610210908161001c8239f35b600080fdfe6080604052600436101561001257600080fd5b6000803560e01c63570e1a361461002857600080fd5b346100c95760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126100c95760043567ffffffffffffffff918282116100c957366023830112156100c95781600401359283116100c95736602484840101116100c9576100c561009e84602485016100fc565b60405173ffffffffffffffffffffffffffffffffffffffff90911681529081906020820190565b0390f35b80fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b90806014116101bb5767ffffffffffffffff917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec82018381116101cd575b604051937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f81600b8701160116850190858210908211176101c0575b604052808452602084019036848401116101bb576020946000600c819682946014880187378301015251923560601c5af19060005191156101b557565b60009150565b600080fd5b6101c86100cc565b610178565b6101d56100cc565b61013a56fea26469706673582212201927e80b76ab9b71c952137dd676621a9fdf520c25928815636594036eb1c40364736f6c63430008110033", - "deployedBytecode": "0x60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c63430008110033" -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/arbitrum/solcInputs/a4c52f0671aad8941c53d6ead2063803.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/arbitrum/solcInputs/a4c52f0671aad8941c53d6ead2063803.json deleted file mode 100644 index dd58ba5a3e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/arbitrum/solcInputs/a4c52f0671aad8941c53d6ead2063803.json +++ /dev/null @@ -1,68 +0,0 @@ -{ - "language": "Solidity", - "sources": { - "@openzeppelin/contracts/security/ReentrancyGuard.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (security/ReentrancyGuard.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Contract module that helps prevent reentrant calls to a function.\n *\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\n * available, which can be applied to functions to make sure there are no nested\n * (reentrant) calls to them.\n *\n * Note that because there is a single `nonReentrant` guard, functions marked as\n * `nonReentrant` may not call one another. This can be worked around by making\n * those functions `private`, and then adding `external` `nonReentrant` entry\n * points to them.\n *\n * TIP: If you would like to learn more about reentrancy and alternative ways\n * to protect against it, check out our blog post\n * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].\n */\nabstract contract ReentrancyGuard {\n // Booleans are more expensive than uint256 or any type that takes up a full\n // word because each write operation emits an extra SLOAD to first read the\n // slot's contents, replace the bits taken up by the boolean, and then write\n // back. This is the compiler's defense against contract upgrades and\n // pointer aliasing, and it cannot be disabled.\n\n // The values being non-zero value makes deployment a bit more expensive,\n // but in exchange the refund on every call to nonReentrant will be lower in\n // amount. Since refunds are capped to a percentage of the total\n // transaction's gas, it is best to keep them low in cases like this one, to\n // increase the likelihood of the full refund coming into effect.\n uint256 private constant _NOT_ENTERED = 1;\n uint256 private constant _ENTERED = 2;\n\n uint256 private _status;\n\n constructor() {\n _status = _NOT_ENTERED;\n }\n\n /**\n * @dev Prevents a contract from calling itself, directly or indirectly.\n * Calling a `nonReentrant` function from another `nonReentrant`\n * function is not supported. It is possible to prevent this from happening\n * by making the `nonReentrant` function external, and making it call a\n * `private` function that does the actual work.\n */\n modifier nonReentrant() {\n _nonReentrantBefore();\n _;\n _nonReentrantAfter();\n }\n\n function _nonReentrantBefore() private {\n // On the first call to nonReentrant, _status will be _NOT_ENTERED\n require(_status != _ENTERED, \"ReentrancyGuard: reentrant call\");\n\n // Any calls to nonReentrant after this point will fail\n _status = _ENTERED;\n }\n\n function _nonReentrantAfter() private {\n // By storing the original value once again, a refund is triggered (see\n // https://eips.ethereum.org/EIPS/eip-2200)\n _status = _NOT_ENTERED;\n }\n}\n" - }, - "contracts/core/EntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IPaymaster.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\n\nimport \"../utils/Exec.sol\";\nimport \"./StakeManager.sol\";\nimport \"./SenderCreator.sol\";\nimport \"./Helpers.sol\";\nimport \"./NonceManager.sol\";\nimport \"@openzeppelin/contracts/security/ReentrancyGuard.sol\";\n\ncontract EntryPoint is IEntryPoint, StakeManager, NonceManager, ReentrancyGuard {\n\n using UserOperationLib for UserOperation;\n\n SenderCreator private immutable senderCreator = new SenderCreator();\n\n // internal value used during simulation: need to query aggregator.\n address private constant SIMULATE_FIND_AGGREGATOR = address(1);\n\n // marker for inner call revert on out of gas\n bytes32 private constant INNER_OUT_OF_GAS = hex'deaddead';\n\n uint256 private constant REVERT_REASON_MAX_LEN = 2048;\n\n /**\n * for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value\n * in case of signature failure, instead of revert.\n */\n uint256 public constant SIG_VALIDATION_FAILED = 1;\n\n /**\n * compensate the caller's beneficiary address with the collected fees of all UserOperations.\n * @param beneficiary the address to receive the fees\n * @param amount amount to transfer.\n */\n function _compensate(address payable beneficiary, uint256 amount) internal {\n require(beneficiary != address(0), \"AA90 invalid beneficiary\");\n (bool success,) = beneficiary.call{value : amount}(\"\");\n require(success, \"AA91 failed send to beneficiary\");\n }\n\n /**\n * execute a user op\n * @param opIndex index into the opInfo array\n * @param userOp the userOp to execute\n * @param opInfo the opInfo filled by validatePrepayment for this userOp.\n * @return collected the total amount this userOp paid.\n */\n function _executeUserOp(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory opInfo) private returns (uint256 collected) {\n uint256 preGas = gasleft();\n bytes memory context = getMemoryBytesFromOffset(opInfo.contextOffset);\n\n try this.innerHandleOp(userOp.callData, opInfo, context) returns (uint256 _actualGasCost) {\n collected = _actualGasCost;\n } catch {\n bytes32 innerRevertCode;\n assembly {\n returndatacopy(0, 0, 32)\n innerRevertCode := mload(0)\n }\n // handleOps was called with gas limit too low. abort entire bundle.\n if (innerRevertCode == INNER_OUT_OF_GAS) {\n //report paymaster, since if it is not deliberately caused by the bundler,\n // it must be a revert caused by paymaster.\n revert FailedOp(opIndex, \"AA95 out of gas\");\n }\n\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n collected = _handlePostOp(opIndex, IPaymaster.PostOpMode.postOpReverted, opInfo, context, actualGas);\n }\n }\n\n /**\n * Execute a batch of UserOperations.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) public nonReentrant {\n\n uint256 opslen = ops.length;\n UserOpInfo[] memory opInfos = new UserOpInfo[](opslen);\n\n unchecked {\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[i];\n (uint256 validationData, uint256 pmValidationData) = _validatePrepayment(i, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, pmValidationData, address(0));\n }\n\n uint256 collected = 0;\n emit BeforeExecution();\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(i, ops[i], opInfos[i]);\n }\n\n _compensate(beneficiary, collected);\n } //unchecked\n }\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) public nonReentrant {\n\n uint256 opasLen = opsPerAggregator.length;\n uint256 totalOps = 0;\n for (uint256 i = 0; i < opasLen; i++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[i];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n //address(1) is special marker of \"signature error\"\n require(address(aggregator) != address(1), \"AA96 invalid aggregator\");\n\n if (address(aggregator) != address(0)) {\n // solhint-disable-next-line no-empty-blocks\n try aggregator.validateSignatures(ops, opa.signature) {}\n catch {\n revert SignatureValidationFailed(address(aggregator));\n }\n }\n\n totalOps += ops.length;\n }\n\n UserOpInfo[] memory opInfos = new UserOpInfo[](totalOps);\n\n emit BeforeExecution();\n\n uint256 opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n uint256 opslen = ops.length;\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[opIndex];\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(opIndex, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, paymasterValidationData, address(aggregator));\n opIndex++;\n }\n }\n\n uint256 collected = 0;\n opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n emit SignatureAggregatorChanged(address(opa.aggregator));\n UserOperation[] calldata ops = opa.userOps;\n uint256 opslen = ops.length;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(opIndex, ops[i], opInfos[opIndex]);\n opIndex++;\n }\n }\n emit SignatureAggregatorChanged(address(0));\n\n _compensate(beneficiary, collected);\n }\n\n /// @inheritdoc IEntryPoint\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external override {\n\n UserOpInfo memory opInfo;\n _simulationOnlyValidations(op);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, op, opInfo);\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n\n numberMarker();\n uint256 paid = _executeUserOp(0, op, opInfo);\n numberMarker();\n bool targetSuccess;\n bytes memory targetResult;\n if (target != address(0)) {\n (targetSuccess, targetResult) = target.call(targetCallData);\n }\n revert ExecutionResult(opInfo.preOpGas, paid, data.validAfter, data.validUntil, targetSuccess, targetResult);\n }\n\n\n // A memory copy of UserOp static fields only.\n // Excluding: callData, initCode and signature. Replacing paymasterAndData with paymaster.\n struct MemoryUserOp {\n address sender;\n uint256 nonce;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n address paymaster;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n }\n\n struct UserOpInfo {\n MemoryUserOp mUserOp;\n bytes32 userOpHash;\n uint256 prefund;\n uint256 contextOffset;\n uint256 preOpGas;\n }\n\n /**\n * inner function to handle a UserOperation.\n * Must be declared \"external\" to open a call context, but it can only be called by handleOps.\n */\n function innerHandleOp(bytes memory callData, UserOpInfo memory opInfo, bytes calldata context) external returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n require(msg.sender == address(this), \"AA92 internal call only\");\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n\n uint callGasLimit = mUserOp.callGasLimit;\n unchecked {\n // handleOps was called with gas limit too low. abort entire bundle.\n if (gasleft() < callGasLimit + mUserOp.verificationGasLimit + 5000) {\n assembly {\n mstore(0, INNER_OUT_OF_GAS)\n revert(0, 32)\n }\n }\n }\n\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\n if (callData.length > 0) {\n bool success = Exec.call(mUserOp.sender, 0, callData, callGasLimit);\n if (!success) {\n bytes memory result = Exec.getReturnData(REVERT_REASON_MAX_LEN);\n if (result.length > 0) {\n emit UserOperationRevertReason(opInfo.userOpHash, mUserOp.sender, mUserOp.nonce, result);\n }\n mode = IPaymaster.PostOpMode.opReverted;\n }\n }\n\n unchecked {\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n //note: opIndex is ignored (relevant only if mode==postOpReverted, which is only possible outside of innerHandleOp)\n return _handlePostOp(0, mode, opInfo, context, actualGas);\n }\n }\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) public view returns (bytes32) {\n return keccak256(abi.encode(userOp.hash(), address(this), block.chainid));\n }\n\n /**\n * copy general fields from userOp into the memory opInfo structure.\n */\n function _copyUserOpToMemory(UserOperation calldata userOp, MemoryUserOp memory mUserOp) internal pure {\n mUserOp.sender = userOp.sender;\n mUserOp.nonce = userOp.nonce;\n mUserOp.callGasLimit = userOp.callGasLimit;\n mUserOp.verificationGasLimit = userOp.verificationGasLimit;\n mUserOp.preVerificationGas = userOp.preVerificationGas;\n mUserOp.maxFeePerGas = userOp.maxFeePerGas;\n mUserOp.maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes calldata paymasterAndData = userOp.paymasterAndData;\n if (paymasterAndData.length > 0) {\n require(paymasterAndData.length >= 20, \"AA93 invalid paymasterAndData\");\n mUserOp.paymaster = address(bytes20(paymasterAndData[: 20]));\n } else {\n mUserOp.paymaster = address(0);\n }\n }\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external {\n UserOpInfo memory outOpInfo;\n\n _simulationOnlyValidations(userOp);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, userOp, outOpInfo);\n StakeInfo memory paymasterInfo = _getStakeInfo(outOpInfo.mUserOp.paymaster);\n StakeInfo memory senderInfo = _getStakeInfo(outOpInfo.mUserOp.sender);\n StakeInfo memory factoryInfo;\n {\n bytes calldata initCode = userOp.initCode;\n address factory = initCode.length >= 20 ? address(bytes20(initCode[0 : 20])) : address(0);\n factoryInfo = _getStakeInfo(factory);\n }\n\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n address aggregator = data.aggregator;\n bool sigFailed = aggregator == address(1);\n ReturnInfo memory returnInfo = ReturnInfo(outOpInfo.preOpGas, outOpInfo.prefund,\n sigFailed, data.validAfter, data.validUntil, getMemoryBytesFromOffset(outOpInfo.contextOffset));\n\n if (aggregator != address(0) && aggregator != address(1)) {\n AggregatorStakeInfo memory aggregatorInfo = AggregatorStakeInfo(aggregator, _getStakeInfo(aggregator));\n revert ValidationResultWithAggregation(returnInfo, senderInfo, factoryInfo, paymasterInfo, aggregatorInfo);\n }\n revert ValidationResult(returnInfo, senderInfo, factoryInfo, paymasterInfo);\n\n }\n\n function _getRequiredPrefund(MemoryUserOp memory mUserOp) internal pure returns (uint256 requiredPrefund) {\n unchecked {\n //when using a Paymaster, the verificationGasLimit is used also to as a limit for the postOp call.\n // our security model might call postOp eventually twice\n uint256 mul = mUserOp.paymaster != address(0) ? 3 : 1;\n uint256 requiredGas = mUserOp.callGasLimit + mUserOp.verificationGasLimit * mul + mUserOp.preVerificationGas;\n\n requiredPrefund = requiredGas * mUserOp.maxFeePerGas;\n }\n }\n\n // create the sender's contract if needed.\n function _createSenderIfNeeded(uint256 opIndex, UserOpInfo memory opInfo, bytes calldata initCode) internal {\n if (initCode.length != 0) {\n address sender = opInfo.mUserOp.sender;\n if (sender.code.length != 0) revert FailedOp(opIndex, \"AA10 sender already constructed\");\n address sender1 = senderCreator.createSender{gas : opInfo.mUserOp.verificationGasLimit}(initCode);\n if (sender1 == address(0)) revert FailedOp(opIndex, \"AA13 initCode failed or OOG\");\n if (sender1 != sender) revert FailedOp(opIndex, \"AA14 initCode must return sender\");\n if (sender1.code.length == 0) revert FailedOp(opIndex, \"AA15 initCode must create sender\");\n address factory = address(bytes20(initCode[0 : 20]));\n emit AccountDeployed(opInfo.userOpHash, sender, factory, opInfo.mUserOp.paymaster);\n }\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes calldata initCode) public {\n address sender = senderCreator.createSender(initCode);\n revert SenderAddressResult(sender);\n }\n\n function _simulationOnlyValidations(UserOperation calldata userOp) internal view {\n // solhint-disable-next-line no-empty-blocks\n try this._validateSenderAndPaymaster(userOp.initCode, userOp.sender, userOp.paymasterAndData) {}\n catch Error(string memory revertReason) {\n if (bytes(revertReason).length != 0) {\n revert FailedOp(0, revertReason);\n }\n }\n }\n\n /**\n * Called only during simulation.\n * This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\n */\n function _validateSenderAndPaymaster(bytes calldata initCode, address sender, bytes calldata paymasterAndData) external view {\n if (initCode.length == 0 && sender.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA20 account not deployed\");\n }\n if (paymasterAndData.length >= 20) {\n address paymaster = address(bytes20(paymasterAndData[0 : 20]));\n if (paymaster.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA30 paymaster not deployed\");\n }\n }\n // always revert\n revert(\"\");\n }\n\n /**\n * call account.validateUserOp.\n * revert (with FailedOp) in case validateUserOp reverts, or account didn't send required prefund.\n * decrement account's deposit if needed\n */\n function _validateAccountPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPrefund)\n internal returns (uint256 gasUsedByValidateAccountPrepayment, uint256 validationData) {\n unchecked {\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n address sender = mUserOp.sender;\n _createSenderIfNeeded(opIndex, opInfo, op.initCode);\n address paymaster = mUserOp.paymaster;\n numberMarker();\n uint256 missingAccountFunds = 0;\n if (paymaster == address(0)) {\n uint256 bal = balanceOf(sender);\n missingAccountFunds = bal > requiredPrefund ? 0 : requiredPrefund - bal;\n }\n try IAccount(sender).validateUserOp{gas : mUserOp.verificationGasLimit}(op, opInfo.userOpHash, missingAccountFunds)\n returns (uint256 _validationData) {\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA23 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA23 reverted (or OOG)\");\n }\n if (paymaster == address(0)) {\n DepositInfo storage senderInfo = deposits[sender];\n uint256 deposit = senderInfo.deposit;\n if (requiredPrefund > deposit) {\n revert FailedOp(opIndex, \"AA21 didn't pay prefund\");\n }\n senderInfo.deposit = uint112(deposit - requiredPrefund);\n }\n gasUsedByValidateAccountPrepayment = preGas - gasleft();\n }\n }\n\n /**\n * In case the request has a paymaster:\n * Validate paymaster has enough deposit.\n * Call paymaster.validatePaymasterUserOp.\n * Revert with proper FailedOp in case paymaster reverts.\n * Decrement paymaster's deposit\n */\n function _validatePaymasterPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPreFund, uint256 gasUsedByValidateAccountPrepayment)\n internal returns (bytes memory context, uint256 validationData) {\n unchecked {\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 verificationGasLimit = mUserOp.verificationGasLimit;\n require(verificationGasLimit > gasUsedByValidateAccountPrepayment, \"AA41 too little verificationGas\");\n uint256 gas = verificationGasLimit - gasUsedByValidateAccountPrepayment;\n\n address paymaster = mUserOp.paymaster;\n DepositInfo storage paymasterInfo = deposits[paymaster];\n uint256 deposit = paymasterInfo.deposit;\n if (deposit < requiredPreFund) {\n revert FailedOp(opIndex, \"AA31 paymaster deposit too low\");\n }\n paymasterInfo.deposit = uint112(deposit - requiredPreFund);\n try IPaymaster(paymaster).validatePaymasterUserOp{gas : gas}(op, opInfo.userOpHash, requiredPreFund) returns (bytes memory _context, uint256 _validationData){\n context = _context;\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA33 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA33 reverted (or OOG)\");\n }\n }\n }\n\n /**\n * revert if either account validationData or paymaster validationData is expired\n */\n function _validateAccountAndPaymasterValidationData(uint256 opIndex, uint256 validationData, uint256 paymasterValidationData, address expectedAggregator) internal view {\n (address aggregator, bool outOfTimeRange) = _getValidationData(validationData);\n if (expectedAggregator != aggregator) {\n revert FailedOp(opIndex, \"AA24 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA22 expired or not due\");\n }\n //pmAggregator is not a real signature aggregator: we don't have logic to handle it as address.\n // non-zero address means that the paymaster fails due to some signature check (which is ok only during estimation)\n address pmAggregator;\n (pmAggregator, outOfTimeRange) = _getValidationData(paymasterValidationData);\n if (pmAggregator != address(0)) {\n revert FailedOp(opIndex, \"AA34 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA32 paymaster expired or not due\");\n }\n }\n\n function _getValidationData(uint256 validationData) internal view returns (address aggregator, bool outOfTimeRange) {\n if (validationData == 0) {\n return (address(0), false);\n }\n ValidationData memory data = _parseValidationData(validationData);\n // solhint-disable-next-line not-rely-on-time\n outOfTimeRange = block.timestamp > data.validUntil || block.timestamp < data.validAfter;\n aggregator = data.aggregator;\n }\n\n /**\n * validate account and paymaster (if defined).\n * also make sure total validation doesn't exceed verificationGasLimit\n * this method is called off-chain (simulateValidation()) and on-chain (from handleOps)\n * @param opIndex the index of this userOp into the \"opInfos\" array\n * @param userOp the userOp to validate\n */\n function _validatePrepayment(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory outOpInfo)\n private returns (uint256 validationData, uint256 paymasterValidationData) {\n\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = outOpInfo.mUserOp;\n _copyUserOpToMemory(userOp, mUserOp);\n outOpInfo.userOpHash = getUserOpHash(userOp);\n\n // validate all numeric values in userOp are well below 128 bit, so they can safely be added\n // and multiplied without causing overflow\n uint256 maxGasValues = mUserOp.preVerificationGas | mUserOp.verificationGasLimit | mUserOp.callGasLimit |\n userOp.maxFeePerGas | userOp.maxPriorityFeePerGas;\n require(maxGasValues <= type(uint120).max, \"AA94 gas values overflow\");\n\n uint256 gasUsedByValidateAccountPrepayment;\n (uint256 requiredPreFund) = _getRequiredPrefund(mUserOp);\n (gasUsedByValidateAccountPrepayment, validationData) = _validateAccountPrepayment(opIndex, userOp, outOpInfo, requiredPreFund);\n\n if (!_validateAndUpdateNonce(mUserOp.sender, mUserOp.nonce)) {\n revert FailedOp(opIndex, \"AA25 invalid account nonce\");\n }\n\n //a \"marker\" where account opcode validation is done and paymaster opcode validation is about to start\n // (used only by off-chain simulateValidation)\n numberMarker();\n\n bytes memory context;\n if (mUserOp.paymaster != address(0)) {\n (context, paymasterValidationData) = _validatePaymasterPrepayment(opIndex, userOp, outOpInfo, requiredPreFund, gasUsedByValidateAccountPrepayment);\n }\n unchecked {\n uint256 gasUsed = preGas - gasleft();\n\n if (userOp.verificationGasLimit < gasUsed) {\n revert FailedOp(opIndex, \"AA40 over verificationGasLimit\");\n }\n outOpInfo.prefund = requiredPreFund;\n outOpInfo.contextOffset = getOffsetOfMemoryBytes(context);\n outOpInfo.preOpGas = preGas - gasleft() + userOp.preVerificationGas;\n }\n }\n\n /**\n * process post-operation.\n * called just after the callData is executed.\n * if a paymaster is defined and its validation returned a non-empty context, its postOp is called.\n * the excess amount is refunded to the account (or paymaster - if it was used in the request)\n * @param opIndex index in the batch\n * @param mode - whether is called from innerHandleOp, or outside (postOpReverted)\n * @param opInfo userOp fields and info collected during validation\n * @param context the context returned in validatePaymasterUserOp\n * @param actualGas the gas used so far by this user operation\n */\n function _handlePostOp(uint256 opIndex, IPaymaster.PostOpMode mode, UserOpInfo memory opInfo, bytes memory context, uint256 actualGas) private returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n unchecked {\n address refundAddress;\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 gasPrice = getUserOpGasPrice(mUserOp);\n\n address paymaster = mUserOp.paymaster;\n if (paymaster == address(0)) {\n refundAddress = mUserOp.sender;\n } else {\n refundAddress = paymaster;\n if (context.length > 0) {\n actualGasCost = actualGas * gasPrice;\n if (mode != IPaymaster.PostOpMode.postOpReverted) {\n IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost);\n } else {\n // solhint-disable-next-line no-empty-blocks\n try IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost) {}\n catch Error(string memory reason) {\n revert FailedOp(opIndex, string.concat(\"AA50 postOp reverted: \", reason));\n }\n catch {\n revert FailedOp(opIndex, \"AA50 postOp revert\");\n }\n }\n }\n }\n actualGas += preGas - gasleft();\n actualGasCost = actualGas * gasPrice;\n if (opInfo.prefund < actualGasCost) {\n revert FailedOp(opIndex, \"AA51 prefund below actualGasCost\");\n }\n uint256 refund = opInfo.prefund - actualGasCost;\n _incrementDeposit(refundAddress, refund);\n bool success = mode == IPaymaster.PostOpMode.opSucceeded;\n emit UserOperationEvent(opInfo.userOpHash, mUserOp.sender, mUserOp.paymaster, mUserOp.nonce, success, actualGasCost, actualGas);\n } // unchecked\n }\n\n /**\n * the gas price this UserOp agrees to pay.\n * relayer/block builder might submit the TX with higher priorityFee, but the user should not\n */\n function getUserOpGasPrice(MemoryUserOp memory mUserOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = mUserOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = mUserOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n\n function getOffsetOfMemoryBytes(bytes memory data) internal pure returns (uint256 offset) {\n assembly {offset := data}\n }\n\n function getMemoryBytesFromOffset(uint256 offset) internal pure returns (bytes memory data) {\n assembly {data := offset}\n }\n\n //place the NUMBER opcode in the code.\n // this is used as a marker during simulation, as this OP is completely banned from the simulated code of the\n // account and paymaster.\n function numberMarker() internal view {\n assembly {mstore(0, number())}\n }\n}\n\n" - }, - "contracts/core/Helpers.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\n/**\n * returned data from validateUserOp.\n * validateUserOp returns a uint256, with is created by `_packedValidationData` and parsed by `_parseValidationData`\n * @param aggregator - address(0) - the account validated the signature by itself.\n * address(1) - the account failed to validate the signature.\n * otherwise - this is an address of a signature aggregator that must be used to validate the signature.\n * @param validAfter - this UserOp is valid only after this timestamp.\n * @param validaUntil - this UserOp is valid only up to this timestamp.\n */\n struct ValidationData {\n address aggregator;\n uint48 validAfter;\n uint48 validUntil;\n }\n\n//extract sigFailed, validAfter, validUntil.\n// also convert zero validUntil to type(uint48).max\n function _parseValidationData(uint validationData) pure returns (ValidationData memory data) {\n address aggregator = address(uint160(validationData));\n uint48 validUntil = uint48(validationData >> 160);\n if (validUntil == 0) {\n validUntil = type(uint48).max;\n }\n uint48 validAfter = uint48(validationData >> (48 + 160));\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n// intersect account and paymaster ranges.\n function _intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) pure returns (ValidationData memory) {\n ValidationData memory accountValidationData = _parseValidationData(validationData);\n ValidationData memory pmValidationData = _parseValidationData(paymasterValidationData);\n address aggregator = accountValidationData.aggregator;\n if (aggregator == address(0)) {\n aggregator = pmValidationData.aggregator;\n }\n uint48 validAfter = accountValidationData.validAfter;\n uint48 validUntil = accountValidationData.validUntil;\n uint48 pmValidAfter = pmValidationData.validAfter;\n uint48 pmValidUntil = pmValidationData.validUntil;\n\n if (validAfter < pmValidAfter) validAfter = pmValidAfter;\n if (validUntil > pmValidUntil) validUntil = pmValidUntil;\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n/**\n * helper to pack the return value for validateUserOp\n * @param data - the ValidationData to pack\n */\n function _packValidationData(ValidationData memory data) pure returns (uint256) {\n return uint160(data.aggregator) | (uint256(data.validUntil) << 160) | (uint256(data.validAfter) << (160 + 48));\n }\n\n/**\n * helper to pack the return value for validateUserOp, when not using an aggregator\n * @param sigFailed - true for signature failure, false for success\n * @param validUntil last timestamp this UserOperation is valid (or zero for infinite)\n * @param validAfter first timestamp this UserOperation is valid\n */\n function _packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) pure returns (uint256) {\n return (sigFailed ? 1 : 0) | (uint256(validUntil) << 160) | (uint256(validAfter) << (160 + 48));\n }\n\n/**\n * keccak function over calldata.\n * @dev copy calldata into memory, do keccak and drop allocated memory. Strangely, this is more efficient than letting solidity do it.\n */\n function calldataKeccak(bytes calldata data) pure returns (bytes32 ret) {\n assembly {\n let mem := mload(0x40)\n let len := data.length\n calldatacopy(mem, data.offset, len)\n ret := keccak256(mem, len)\n }\n }\n\n" - }, - "contracts/core/NonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IEntryPoint.sol\";\n\n/**\n * nonce management functionality\n */\ncontract NonceManager is INonceManager {\n\n /**\n * The next valid sequence number for a given nonce key.\n */\n mapping(address => mapping(uint192 => uint256)) public nonceSequenceNumber;\n\n function getNonce(address sender, uint192 key)\n public view override returns (uint256 nonce) {\n return nonceSequenceNumber[sender][key] | (uint256(key) << 64);\n }\n\n // allow an account to manually increment its own nonce.\n // (mainly so that during construction nonce can be made non-zero,\n // to \"absorb\" the gas cost of first nonce increment to 1st transaction (construction),\n // not to 2nd transaction)\n function incrementNonce(uint192 key) public override {\n nonceSequenceNumber[msg.sender][key]++;\n }\n\n /**\n * validate nonce uniqueness for this account.\n * called just after validateUserOp()\n */\n function _validateAndUpdateNonce(address sender, uint256 nonce) internal returns (bool) {\n\n uint192 key = uint192(nonce >> 64);\n uint64 seq = uint64(nonce);\n return nonceSequenceNumber[sender][key]++ == seq;\n }\n\n}\n" - }, - "contracts/core/SenderCreator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * helper contract for EntryPoint, to call userOp.initCode from a \"neutral\" address,\n * which is explicitly not the entryPoint itself.\n */\ncontract SenderCreator {\n\n /**\n * call the \"initCode\" factory to create and return the sender account address\n * @param initCode the initCode value from a UserOp. contains 20 bytes of factory address, followed by calldata\n * @return sender the returned address of the created account, or zero address on failure.\n */\n function createSender(bytes calldata initCode) external returns (address sender) {\n address factory = address(bytes20(initCode[0 : 20]));\n bytes memory initCallData = initCode[20 :];\n bool success;\n /* solhint-disable no-inline-assembly */\n assembly {\n success := call(gas(), factory, 0, add(initCallData, 0x20), mload(initCallData), 0, 32)\n sender := mload(0)\n }\n if (!success) {\n sender = address(0);\n }\n }\n}\n" - }, - "contracts/core/StakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IStakeManager.sol\";\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable not-rely-on-time */\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by a paymaster.\n */\nabstract contract StakeManager is IStakeManager {\n\n /// maps paymaster to their deposits and stakes\n mapping(address => DepositInfo) public deposits;\n\n /// @inheritdoc IStakeManager\n function getDepositInfo(address account) public view returns (DepositInfo memory info) {\n return deposits[account];\n }\n\n // internal method to return just the stake info\n function _getStakeInfo(address addr) internal view returns (StakeInfo memory info) {\n DepositInfo storage depositInfo = deposits[addr];\n info.stake = depositInfo.stake;\n info.unstakeDelaySec = depositInfo.unstakeDelaySec;\n }\n\n /// return the deposit (for gas payment) of the account\n function balanceOf(address account) public view returns (uint256) {\n return deposits[account].deposit;\n }\n\n receive() external payable {\n depositTo(msg.sender);\n }\n\n function _incrementDeposit(address account, uint256 amount) internal {\n DepositInfo storage info = deposits[account];\n uint256 newAmount = info.deposit + amount;\n require(newAmount <= type(uint112).max, \"deposit overflow\");\n info.deposit = uint112(newAmount);\n }\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) public payable {\n _incrementDeposit(account, msg.value);\n DepositInfo storage info = deposits[account];\n emit Deposited(account, info.deposit);\n }\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 unstakeDelaySec) public payable {\n DepositInfo storage info = deposits[msg.sender];\n require(unstakeDelaySec > 0, \"must specify unstake delay\");\n require(unstakeDelaySec >= info.unstakeDelaySec, \"cannot decrease unstake time\");\n uint256 stake = info.stake + msg.value;\n require(stake > 0, \"no stake specified\");\n require(stake <= type(uint112).max, \"stake overflow\");\n deposits[msg.sender] = DepositInfo(\n info.deposit,\n true,\n uint112(stake),\n unstakeDelaySec,\n 0\n );\n emit StakeLocked(msg.sender, stake, unstakeDelaySec);\n }\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external {\n DepositInfo storage info = deposits[msg.sender];\n require(info.unstakeDelaySec != 0, \"not staked\");\n require(info.staked, \"already unstaking\");\n uint48 withdrawTime = uint48(block.timestamp) + info.unstakeDelaySec;\n info.withdrawTime = withdrawTime;\n info.staked = false;\n emit StakeUnlocked(msg.sender, withdrawTime);\n }\n\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external {\n DepositInfo storage info = deposits[msg.sender];\n uint256 stake = info.stake;\n require(stake > 0, \"No stake to withdraw\");\n require(info.withdrawTime > 0, \"must call unlockStake() first\");\n require(info.withdrawTime <= block.timestamp, \"Stake withdrawal is not due\");\n info.unstakeDelaySec = 0;\n info.withdrawTime = 0;\n info.stake = 0;\n emit StakeWithdrawn(msg.sender, withdrawAddress, stake);\n (bool success,) = withdrawAddress.call{value : stake}(\"\");\n require(success, \"failed to withdraw stake\");\n }\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external {\n DepositInfo storage info = deposits[msg.sender];\n require(withdrawAmount <= info.deposit, \"Withdraw amount too large\");\n info.deposit = uint112(info.deposit - withdrawAmount);\n emit Withdrawn(msg.sender, withdrawAddress, withdrawAmount);\n (bool success,) = withdrawAddress.call{value : withdrawAmount}(\"\");\n require(success, \"failed to withdraw\");\n }\n}\n" - }, - "contracts/interfaces/IAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\ninterface IAccount {\n\n /**\n * Validate user's signature and nonce\n * the entryPoint will make the call to the recipient only if this validation call returns successfully.\n * signature failure should be reported by returning SIG_VALIDATION_FAILED (1).\n * This allows making a \"simulation call\" without a valid signature\n * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure.\n *\n * @dev Must validate caller is the entryPoint.\n * Must validate the signature and nonce\n * @param userOp the operation that is about to be executed.\n * @param userOpHash hash of the user's request data. can be used as the basis for signature.\n * @param missingAccountFunds missing funds on the account's deposit in the entrypoint.\n * This is the minimum amount to transfer to the sender(entryPoint) to be able to make the call.\n * The excess is left as a deposit in the entrypoint, for future calls.\n * can be withdrawn anytime using \"entryPoint.withdrawTo()\"\n * In case there is a paymaster in the request (or the current deposit is high enough), this value will be zero.\n * @return validationData packaged ValidationData structure. use `_packValidationData` and `_unpackValidationData` to encode and decode\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * If an account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external returns (uint256 validationData);\n}\n" - }, - "contracts/interfaces/IAggregator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * Aggregated Signatures validator.\n */\ninterface IAggregator {\n\n /**\n * validate aggregated signature.\n * revert if the aggregated signature does not match the given list of operations.\n */\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external view;\n\n /**\n * validate signature of a single userOp\n * This method is should be called by bundler after EntryPoint.simulateValidation() returns (reverts) with ValidationResultWithAggregation\n * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps.\n * @param userOp the userOperation received from the user.\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\n * (usually empty, unless account and aggregator support some kind of \"multisig\"\n */\n function validateUserOpSignature(UserOperation calldata userOp)\n external view returns (bytes memory sigForUserOp);\n\n /**\n * aggregate multiple signatures into a single value.\n * This method is called off-chain to calculate the signature to pass with handleOps()\n * bundler MAY use optimized custom code perform this aggregation\n * @param userOps array of UserOperations to collect the signatures from.\n * @return aggregatedSignature the aggregated signature\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external view returns (bytes memory aggregatedSignature);\n}\n" - }, - "contracts/interfaces/IEntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"./UserOperation.sol\";\nimport \"./IStakeManager.sol\";\nimport \"./IAggregator.sol\";\nimport \"./INonceManager.sol\";\n\ninterface IEntryPoint is IStakeManager, INonceManager {\n\n /***\n * An event emitted after each successful request\n * @param userOpHash - unique identifier for the request (hash its entire content, except signature).\n * @param sender - the account that generates this request.\n * @param paymaster - if non-null, the paymaster that pays for this request.\n * @param nonce - the nonce value from the request.\n * @param success - true if the sender transaction succeeded, false if reverted.\n * @param actualGasCost - actual amount paid (by account or paymaster) for this UserOperation.\n * @param actualGasUsed - total gas used by this UserOperation (including preVerification, creation, validation and execution).\n */\n event UserOperationEvent(bytes32 indexed userOpHash, address indexed sender, address indexed paymaster, uint256 nonce, bool success, uint256 actualGasCost, uint256 actualGasUsed);\n\n /**\n * account \"sender\" was deployed.\n * @param userOpHash the userOp that deployed this account. UserOperationEvent will follow.\n * @param sender the account that is deployed\n * @param factory the factory used to deploy this account (in the initCode)\n * @param paymaster the paymaster used by this UserOp\n */\n event AccountDeployed(bytes32 indexed userOpHash, address indexed sender, address factory, address paymaster);\n\n /**\n * An event emitted if the UserOperation \"callData\" reverted with non-zero length\n * @param userOpHash the request unique identifier.\n * @param sender the sender of this request\n * @param nonce the nonce used in the request\n * @param revertReason - the return bytes from the (reverted) call to \"callData\".\n */\n event UserOperationRevertReason(bytes32 indexed userOpHash, address indexed sender, uint256 nonce, bytes revertReason);\n\n /**\n * an event emitted by handleOps(), before starting the execution loop.\n * any event emitted before this event, is part of the validation.\n */\n event BeforeExecution();\n\n /**\n * signature aggregator used by the following UserOperationEvents within this bundle.\n */\n event SignatureAggregatorChanged(address indexed aggregator);\n\n /**\n * a custom revert error of handleOps, to identify the offending op.\n * NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\n * @param opIndex - index into the array of ops to the failed one (in simulateValidation, this is always zero)\n * @param reason - revert reason\n * The string starts with a unique code \"AAmn\", where \"m\" is \"1\" for factory, \"2\" for account and \"3\" for paymaster issues,\n * so a failure can be attributed to the correct entity.\n * Should be caught in off-chain handleOps simulation and not happen on-chain.\n * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\n */\n error FailedOp(uint256 opIndex, string reason);\n\n /**\n * error case when a signature aggregator fails to verify the aggregated signature it had created.\n */\n error SignatureValidationFailed(address aggregator);\n\n /**\n * Successful result from simulateValidation.\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n */\n error ValidationResult(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo);\n\n /**\n * Successful result from simulateValidation, if the account returns a signature aggregator\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n * @param aggregatorInfo signature aggregation info (if the account requires signature aggregator)\n * bundler MUST use it to verify the signature, or reject the UserOperation\n */\n error ValidationResultWithAggregation(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo,\n AggregatorStakeInfo aggregatorInfo);\n\n /**\n * return value of getSenderAddress\n */\n error SenderAddressResult(address sender);\n\n /**\n * return value of simulateHandleOp\n */\n error ExecutionResult(uint256 preOpGas, uint256 paid, uint48 validAfter, uint48 validUntil, bool targetSuccess, bytes targetResult);\n\n //UserOps handled, per aggregator\n struct UserOpsPerAggregator {\n UserOperation[] userOps;\n\n // aggregator address\n IAggregator aggregator;\n // aggregated signature\n bytes signature;\n }\n\n /**\n * Execute a batch of UserOperation.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) external;\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) external;\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) external view returns (bytes32);\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external;\n\n /**\n * gas and return values during simulation\n * @param preOpGas the gas used for validation (including preValidationGas)\n * @param prefund the required prefund for this operation\n * @param sigFailed validateUserOp's (or paymaster's) signature check failed\n * @param validAfter - first timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param validUntil - last timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param paymasterContext returned by validatePaymasterUserOp (to be passed into postOp)\n */\n struct ReturnInfo {\n uint256 preOpGas;\n uint256 prefund;\n bool sigFailed;\n uint48 validAfter;\n uint48 validUntil;\n bytes paymasterContext;\n }\n\n /**\n * returned aggregated signature info.\n * the aggregator returned by the account, and its current stake.\n */\n struct AggregatorStakeInfo {\n address aggregator;\n StakeInfo stakeInfo;\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes memory initCode) external;\n\n\n /**\n * simulate full execution of a UserOperation (including both validation and target execution)\n * this method will always revert with \"ExecutionResult\".\n * it performs full validation of the UserOperation, but ignores signature error.\n * an optional target address is called after the userop succeeds, and its value is returned\n * (before the entire call is reverted)\n * Note that in order to collect the the success/failure of the target call, it must be executed\n * with trace enabled to track the emitted events.\n * @param op the UserOperation to simulate\n * @param target if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult\n * are set to the return from that call.\n * @param targetCallData callData to pass to target address\n */\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external;\n}\n\n" - }, - "contracts/interfaces/INonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\ninterface INonceManager {\n\n /**\n * Return the next nonce for this sender.\n * Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop)\n * But UserOp with different keys can come with arbitrary order.\n *\n * @param sender the account address\n * @param key the high 192 bit of the nonce\n * @return nonce a full nonce to pass for next UserOp with this sender.\n */\n function getNonce(address sender, uint192 key)\n external view returns (uint256 nonce);\n\n /**\n * Manually increment the nonce of the sender.\n * This method is exposed just for completeness..\n * Account does NOT need to call it, neither during validation, nor elsewhere,\n * as the EntryPoint will update the nonce regardless.\n * Possible use-case is call it with various keys to \"initialize\" their nonces to one, so that future\n * UserOperations will not pay extra for the first transaction with a given key.\n */\n function incrementNonce(uint192 key) external;\n}\n" - }, - "contracts/interfaces/IPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * the interface exposed by a paymaster contract, who agrees to pay the gas for user's operations.\n * a paymaster must hold a stake to cover the required entrypoint stake and also the gas for the transaction.\n */\ninterface IPaymaster {\n\n enum PostOpMode {\n opSucceeded, // user op succeeded\n opReverted, // user op reverted. still has to pay for gas.\n postOpReverted //user op succeeded, but caused postOp to revert. Now it's a 2nd call, after user's op was deliberately reverted.\n }\n\n /**\n * payment validation: check if paymaster agrees to pay.\n * Must verify sender is the entryPoint.\n * Revert to reject this request.\n * Note that bundlers will reject this method if it changes the state, unless the paymaster is trusted (whitelisted)\n * The paymaster pre-pays using its deposit, and receive back a refund after the postOp method returns.\n * @param userOp the user operation\n * @param userOpHash hash of the user's request data.\n * @param maxCost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\n * @return context value to send to a postOp\n * zero length to signify postOp is not required.\n * @return validationData signature and time-range of this operation, encoded the same as the return value of validateUserOperation\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n external returns (bytes memory context, uint256 validationData);\n\n /**\n * post-operation handler.\n * Must verify sender is the entryPoint\n * @param mode enum with the following options:\n * opSucceeded - user operation succeeded.\n * opReverted - user op reverted. still has to pay for gas.\n * postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n * Now this is the 2nd call, after user's op was deliberately reverted.\n * @param context - the context value returned by validatePaymasterUserOp\n * @param actualGasCost - actual gas used so far (without this postOp call).\n */\n function postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) external;\n}\n" - }, - "contracts/interfaces/IStakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by the staked entity.\n */\ninterface IStakeManager {\n\n event Deposited(\n address indexed account,\n uint256 totalDeposit\n );\n\n event Withdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /// Emitted when stake or unstake delay are modified\n event StakeLocked(\n address indexed account,\n uint256 totalStaked,\n uint256 unstakeDelaySec\n );\n\n /// Emitted once a stake is scheduled for withdrawal\n event StakeUnlocked(\n address indexed account,\n uint256 withdrawTime\n );\n\n event StakeWithdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /**\n * @param deposit the entity's deposit\n * @param staked true if this entity is staked.\n * @param stake actual amount of ether staked for this entity.\n * @param unstakeDelaySec minimum delay to withdraw the stake.\n * @param withdrawTime - first block timestamp where 'withdrawStake' will be callable, or zero if already locked\n * @dev sizes were chosen so that (deposit,staked, stake) fit into one cell (used during handleOps)\n * and the rest fit into a 2nd cell.\n * 112 bit allows for 10^15 eth\n * 48 bit for full timestamp\n * 32 bit allows 150 years for unstake delay\n */\n struct DepositInfo {\n uint112 deposit;\n bool staked;\n uint112 stake;\n uint32 unstakeDelaySec;\n uint48 withdrawTime;\n }\n\n //API struct used by getStakeInfo and simulateValidation\n struct StakeInfo {\n uint256 stake;\n uint256 unstakeDelaySec;\n }\n\n /// @return info - full deposit information of given account\n function getDepositInfo(address account) external view returns (DepositInfo memory info);\n\n /// @return the deposit (for gas payment) of the account\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) external payable;\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param _unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 _unstakeDelaySec) external payable;\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external;\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external;\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external;\n}\n" - }, - "contracts/interfaces/UserOperation.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\nimport {calldataKeccak} from \"../core/Helpers.sol\";\n\n/**\n * User Operation struct\n * @param sender the sender account of this request.\n * @param nonce unique value the sender uses to verify it is not a replay.\n * @param initCode if set, the account contract will be created by this constructor/\n * @param callData the method call to execute on this account.\n * @param callGasLimit the gas limit passed to the callData method call.\n * @param verificationGasLimit gas used for validateUserOp and validatePaymasterUserOp.\n * @param preVerificationGas gas not calculated by the handleOps method, but added to the gas paid. Covers batch overhead.\n * @param maxFeePerGas same as EIP-1559 gas parameter.\n * @param maxPriorityFeePerGas same as EIP-1559 gas parameter.\n * @param paymasterAndData if set, this field holds the paymaster address and paymaster-specific data. the paymaster will pay for the transaction instead of the sender.\n * @param signature sender-verified signature over the entire request, the EntryPoint address and the chain ID.\n */\n struct UserOperation {\n\n address sender;\n uint256 nonce;\n bytes initCode;\n bytes callData;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n bytes paymasterAndData;\n bytes signature;\n }\n\n/**\n * Utility functions helpful when working with UserOperation structs.\n */\nlibrary UserOperationLib {\n\n function getSender(UserOperation calldata userOp) internal pure returns (address) {\n address data;\n //read sender from userOp, which is first userOp member (saves 800 gas...)\n assembly {data := calldataload(userOp)}\n return address(uint160(data));\n }\n\n //relayer/block builder might submit the TX with higher priorityFee, but the user should not\n // pay above what he signed for.\n function gasPrice(UserOperation calldata userOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n address sender = getSender(userOp);\n uint256 nonce = userOp.nonce;\n bytes32 hashInitCode = calldataKeccak(userOp.initCode);\n bytes32 hashCallData = calldataKeccak(userOp.callData);\n uint256 callGasLimit = userOp.callGasLimit;\n uint256 verificationGasLimit = userOp.verificationGasLimit;\n uint256 preVerificationGas = userOp.preVerificationGas;\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes32 hashPaymasterAndData = calldataKeccak(userOp.paymasterAndData);\n\n return abi.encode(\n sender, nonce,\n hashInitCode, hashCallData,\n callGasLimit, verificationGasLimit, preVerificationGas,\n maxFeePerGas, maxPriorityFeePerGas,\n hashPaymasterAndData\n );\n }\n\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\n return keccak256(pack(userOp));\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n}\n" - }, - "contracts/utils/Exec.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.5 <0.9.0;\n\n// solhint-disable no-inline-assembly\n\n/**\n * Utility functions helpful when making different kinds of contract calls in Solidity.\n */\nlibrary Exec {\n\n function call(\n address to,\n uint256 value,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function staticcall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal view returns (bool success) {\n assembly {\n success := staticcall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function delegateCall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n // get returned data from last call or calldelegate\n function getReturnData(uint256 maxLen) internal pure returns (bytes memory returnData) {\n assembly {\n let len := returndatasize()\n if gt(len, maxLen) {\n len := maxLen\n }\n let ptr := mload(0x40)\n mstore(0x40, add(ptr, add(len, 0x20)))\n mstore(ptr, len)\n returndatacopy(add(ptr, 0x20), 0, len)\n returnData := ptr\n }\n }\n\n // revert with explicit byte array (probably reverted info from call)\n function revertWithData(bytes memory returnData) internal pure {\n assembly {\n revert(add(returnData, 32), mload(returnData))\n }\n }\n\n function callAndRevert(address to, bytes memory data, uint256 maxLen) internal {\n bool success = call(to,0,data,gasleft());\n if (!success) {\n revertWithData(getReturnData(maxLen));\n }\n }\n}\n" - } - }, - "settings": { - "optimizer": { - "enabled": true, - "runs": 1000000 - }, - "viaIR": true, - "outputSelection": { - "*": { - "*": [ - "abi", - "evm.bytecode", - "evm.deployedBytecode", - "evm.methodIdentifiers", - "metadata" - ], - "": [ - "ast" - ] - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/gnosis/.chainId b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/gnosis/.chainId deleted file mode 100644 index 105d7d9ad3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/gnosis/.chainId +++ /dev/null @@ -1 +0,0 @@ -100 \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/gnosis/EntryPoint.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/gnosis/EntryPoint.json deleted file mode 100644 index 916c239083..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/gnosis/EntryPoint.json +++ /dev/null @@ -1,1318 +0,0 @@ -{ - "address": "0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789", - "abi": [ - { - "inputs": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "paid", - "type": "uint256" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bool", - "name": "targetSuccess", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "targetResult", - "type": "bytes" - } - ], - "name": "ExecutionResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "opIndex", - "type": "uint256" - }, - { - "internalType": "string", - "name": "reason", - "type": "string" - } - ], - "name": "FailedOp", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - } - ], - "name": "SenderAddressResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureValidationFailed", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - } - ], - "name": "ValidationResult", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "stakeInfo", - "type": "tuple" - } - ], - "internalType": "struct IEntryPoint.AggregatorStakeInfo", - "name": "aggregatorInfo", - "type": "tuple" - } - ], - "name": "ValidationResultWithAggregation", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "factory", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "paymaster", - "type": "address" - } - ], - "name": "AccountDeployed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [], - "name": "BeforeExecution", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalDeposit", - "type": "uint256" - } - ], - "name": "Deposited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureAggregatorChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalStaked", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "name": "StakeLocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "withdrawTime", - "type": "uint256" - } - ], - "name": "StakeUnlocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "StakeWithdrawn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasUsed", - "type": "uint256" - } - ], - "name": "UserOperationEvent", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "revertReason", - "type": "bytes" - } - ], - "name": "UserOperationRevertReason", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "Withdrawn", - "type": "event" - }, - { - "inputs": [], - "name": "SIG_VALIDATION_FAILED", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - } - ], - "name": "_validateSenderAndPaymaster", - "outputs": [], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - } - ], - "name": "addStake", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "depositTo", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "deposits", - "outputs": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "getDepositInfo", - "outputs": [ - { - "components": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "internalType": "struct IStakeManager.DepositInfo", - "name": "info", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "getNonce", - "outputs": [ - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - } - ], - "name": "getSenderAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "getUserOpHash", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "userOps", - "type": "tuple[]" - }, - { - "internalType": "contract IAggregator", - "name": "aggregator", - "type": "address" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.UserOpsPerAggregator[]", - "name": "opsPerAggregator", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleAggregatedOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "ops", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "incrementNonce", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.MemoryUserOp", - "name": "mUserOp", - "type": "tuple" - }, - { - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "contextOffset", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.UserOpInfo", - "name": "opInfo", - "type": "tuple" - }, - { - "internalType": "bytes", - "name": "context", - "type": "bytes" - } - ], - "name": "innerHandleOp", - "outputs": [ - { - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - }, - { - "internalType": "uint192", - "name": "", - "type": "uint192" - } - ], - "name": "nonceSequenceNumber", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "op", - "type": "tuple" - }, - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "targetCallData", - "type": "bytes" - } - ], - "name": "simulateHandleOp", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "simulateValidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unlockStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - } - ], - "name": "withdrawStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "withdrawAmount", - "type": "uint256" - } - ], - "name": "withdrawTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "args": [], - "numDeployments": 1, - "solcInputHash": "a4c52f0671aad8941c53d6ead2063803", - "metadata": "{\"compiler\":{\"version\":\"0.8.17+commit.8df45f5f\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"paid\",\"type\":\"uint256\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bool\",\"name\":\"targetSuccess\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"targetResult\",\"type\":\"bytes\"}],\"name\":\"ExecutionResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"opIndex\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\"}],\"name\":\"FailedOp\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderAddressResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureValidationFailed\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResult\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"stakeInfo\",\"type\":\"tuple\"}],\"internalType\":\"struct IEntryPoint.AggregatorStakeInfo\",\"name\":\"aggregatorInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResultWithAggregation\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"factory\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"}],\"name\":\"AccountDeployed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"BeforeExecution\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalDeposit\",\"type\":\"uint256\"}],\"name\":\"Deposited\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureAggregatorChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalStaked\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"name\":\"StakeLocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"withdrawTime\",\"type\":\"uint256\"}],\"name\":\"StakeUnlocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"StakeWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasUsed\",\"type\":\"uint256\"}],\"name\":\"UserOperationEvent\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"revertReason\",\"type\":\"bytes\"}],\"name\":\"UserOperationRevertReason\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Withdrawn\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"SIG_VALIDATION_FAILED\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"}],\"name\":\"_validateSenderAndPaymaster\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"}],\"name\":\"addStake\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"depositTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"deposits\",\"outputs\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getDepositInfo\",\"outputs\":[{\"components\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"internalType\":\"struct IStakeManager.DepositInfo\",\"name\":\"info\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"}],\"name\":\"getSenderAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"getUserOpHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"userOps\",\"type\":\"tuple[]\"},{\"internalType\":\"contract IAggregator\",\"name\":\"aggregator\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.UserOpsPerAggregator[]\",\"name\":\"opsPerAggregator\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleAggregatedOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"ops\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"incrementNonce\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.MemoryUserOp\",\"name\":\"mUserOp\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"contextOffset\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.UserOpInfo\",\"name\":\"opInfo\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"context\",\"type\":\"bytes\"}],\"name\":\"innerHandleOp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"\",\"type\":\"uint192\"}],\"name\":\"nonceSequenceNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"op\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"targetCallData\",\"type\":\"bytes\"}],\"name\":\"simulateHandleOp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"simulateValidation\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unlockStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"}],\"name\":\"withdrawStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"withdrawAmount\",\"type\":\"uint256\"}],\"name\":\"withdrawTo\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"errors\":{\"FailedOp(uint256,string)\":[{\"params\":{\"opIndex\":\"- index into the array of ops to the failed one (in simulateValidation, this is always zero)\",\"reason\":\"- revert reason The string starts with a unique code \\\"AAmn\\\", where \\\"m\\\" is \\\"1\\\" for factory, \\\"2\\\" for account and \\\"3\\\" for paymaster issues, so a failure can be attributed to the correct entity. Should be caught in off-chain handleOps simulation and not happen on-chain. Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\"}}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"params\":{\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"params\":{\"aggregatorInfo\":\"signature aggregation info (if the account requires signature aggregator) bundler MUST use it to verify the signature, or reject the UserOperation\",\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}]},\"kind\":\"dev\",\"methods\":{\"addStake(uint32)\":{\"params\":{\"unstakeDelaySec\":\"the new lock duration before the deposit can be withdrawn.\"}},\"getDepositInfo(address)\":{\"returns\":{\"info\":\"- full deposit information of given account\"}},\"getNonce(address,uint192)\":{\"params\":{\"key\":\"the high 192 bit of the nonce\",\"sender\":\"the account address\"},\"returns\":{\"nonce\":\"a full nonce to pass for next UserOp with this sender.\"}},\"getSenderAddress(bytes)\":{\"params\":{\"initCode\":\"the constructor code to be passed into the UserOperation.\"}},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"opsPerAggregator\":\"the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\"}},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"ops\":\"the operations to execute\"}},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"params\":{\"op\":\"the UserOperation to simulate\",\"target\":\"if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult are set to the return from that call.\",\"targetCallData\":\"callData to pass to target address\"}},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"details\":\"this method always revert. Successful result is ValidationResult error. other errors are failures.The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\",\"params\":{\"userOp\":\"the user operation to validate.\"}},\"withdrawStake(address)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\"}},\"withdrawTo(address,uint256)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\",\"withdrawAmount\":\"the amount to withdraw.\"}}},\"version\":1},\"userdoc\":{\"errors\":{\"ExecutionResult(uint256,uint256,uint48,uint48,bool,bytes)\":[{\"notice\":\"return value of simulateHandleOp\"}],\"FailedOp(uint256,string)\":[{\"notice\":\"a custom revert error of handleOps, to identify the offending op. NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\"}],\"SenderAddressResult(address)\":[{\"notice\":\"return value of getSenderAddress\"}],\"SignatureValidationFailed(address)\":[{\"notice\":\"error case when a signature aggregator fails to verify the aggregated signature it had created.\"}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"notice\":\"Successful result from simulateValidation.\"}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"notice\":\"Successful result from simulateValidation, if the account returns a signature aggregator\"}]},\"events\":{\"AccountDeployed(bytes32,address,address,address)\":{\"notice\":\"account \\\"sender\\\" was deployed.\"},\"BeforeExecution()\":{\"notice\":\"an event emitted by handleOps(), before starting the execution loop. any event emitted before this event, is part of the validation.\"},\"SignatureAggregatorChanged(address)\":{\"notice\":\"signature aggregator used by the following UserOperationEvents within this bundle.\"},\"StakeLocked(address,uint256,uint256)\":{\"notice\":\"Emitted when stake or unstake delay are modified\"},\"StakeUnlocked(address,uint256)\":{\"notice\":\"Emitted once a stake is scheduled for withdrawal\"},\"UserOperationRevertReason(bytes32,address,uint256,bytes)\":{\"notice\":\"An event emitted if the UserOperation \\\"callData\\\" reverted with non-zero length\"}},\"kind\":\"user\",\"methods\":{\"SIG_VALIDATION_FAILED()\":{\"notice\":\"for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value in case of signature failure, instead of revert.\"},\"_validateSenderAndPaymaster(bytes,address,bytes)\":{\"notice\":\"Called only during simulation. This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\"},\"addStake(uint32)\":{\"notice\":\"add to the account's stake - amount and delay any pending unstake is first cancelled.\"},\"balanceOf(address)\":{\"notice\":\"return the deposit (for gas payment) of the account\"},\"depositTo(address)\":{\"notice\":\"add to the deposit of the given account\"},\"deposits(address)\":{\"notice\":\"maps paymaster to their deposits and stakes\"},\"getNonce(address,uint192)\":{\"notice\":\"Return the next nonce for this sender. Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop) But UserOp with different keys can come with arbitrary order.\"},\"getSenderAddress(bytes)\":{\"notice\":\"Get counterfactual sender address. Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation. this method always revert, and returns the address in SenderAddressResult error\"},\"getUserOpHash((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"generate a request Id - unique identifier for this request. the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\"},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperation with Aggregators\"},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperations. no signature aggregator is used. if any account requires an aggregator (that is, it returned an aggregator when performing simulateValidation), then handleAggregatedOps() must be used instead.\"},\"incrementNonce(uint192)\":{\"notice\":\"Manually increment the nonce of the sender. This method is exposed just for completeness.. Account does NOT need to call it, neither during validation, nor elsewhere, as the EntryPoint will update the nonce regardless. Possible use-case is call it with various keys to \\\"initialize\\\" their nonces to one, so that future UserOperations will not pay extra for the first transaction with a given key.\"},\"innerHandleOp(bytes,((address,uint256,uint256,uint256,uint256,address,uint256,uint256),bytes32,uint256,uint256,uint256),bytes)\":{\"notice\":\"inner function to handle a UserOperation. Must be declared \\\"external\\\" to open a call context, but it can only be called by handleOps.\"},\"nonceSequenceNumber(address,uint192)\":{\"notice\":\"The next valid sequence number for a given nonce key.\"},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"notice\":\"simulate full execution of a UserOperation (including both validation and target execution) this method will always revert with \\\"ExecutionResult\\\". it performs full validation of the UserOperation, but ignores signature error. an optional target address is called after the userop succeeds, and its value is returned (before the entire call is reverted) Note that in order to collect the the success/failure of the target call, it must be executed with trace enabled to track the emitted events.\"},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\"},\"unlockStake()\":{\"notice\":\"attempt to unlock the stake. the value can be withdrawn (using withdrawStake) after the unstake delay.\"},\"withdrawStake(address)\":{\"notice\":\"withdraw from the (unlocked) stake. must first call unlockStake and wait for the unstakeDelay to pass\"},\"withdrawTo(address,uint256)\":{\"notice\":\"withdraw from the deposit.\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/core/EntryPoint.sol\":\"EntryPoint\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":1000000},\"remappings\":[],\"viaIR\":true},\"sources\":{\"@openzeppelin/contracts/security/ReentrancyGuard.sol\":{\"keccak256\":\"0x190dd6f8d592b7e4e930feb7f4313aeb8e1c4ad3154c27ce1cf6a512fc30d8cc\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://4ce8dfb62d0c4fa260d6eec8f1cd47f5f2a044e11bde5b31d18072fa6e7d9010\",\"dweb:/ipfs/QmTyFztU3tLEcEDnqqiaW4UJetqsU77LXc6pjc9oTXCK5u\"]},\"contracts/core/EntryPoint.sol\":{\"keccak256\":\"0x04f86318b47f052d7308795ffae6ecec0d023d2458b4e17751b89a0e4acfcdc6\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://c9f6e359c8dbe875ad974d3a0fb7b3d62319a6b115c44bac1e4587ae2ad2edaf\",\"dweb:/ipfs/QmTSWTov2rUeYk8cwzrtsd3uVXokCYok4gMiZ1sPs9tycH\"]},\"contracts/core/Helpers.sol\":{\"keccak256\":\"0x591c87519f7155d1909210276b77925ab2722a99b7b5d5649aecc36ebbdb045a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://69643e83f68e6a13d5075c7565bfce326673b0bd98c432033c4603ea84835746\",\"dweb:/ipfs/QmSwSzjYyV7qudi5vvsmzHMG2Z4YJZxX51RRXXVCLaNcEU\"]},\"contracts/core/NonceManager.sol\":{\"keccak256\":\"0xa17a4a6fde70088ab18ffe6df830f3efa31f1cd0e1a7160336c96e3c94984d25\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://b38615df9f80c56282b72888e9ba1eb1a9413fa67a0dbf094deda7af9feb38e7\",\"dweb:/ipfs/QmSzcXetEJRH4UHuUmZiSgX6bFgfqHWfmyuxVnh4NosMk1\"]},\"contracts/core/SenderCreator.sol\":{\"keccak256\":\"0x44b9449fec82d6cdfb01d52fdd5a72f90099c651316123810cf9633f00b018c2\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a9c0487390e72638681d175c45bc92425c802fffdca4bd0ae8457782ee284612\",\"dweb:/ipfs/QmVbzuehCUWJWqEHyMWuc6cRVbxfcMdFsmGL9o4Wz7WY2x\"]},\"contracts/core/StakeManager.sol\":{\"keccak256\":\"0x21aa0956382bd000b1b8c3b1d19ca6ebcd6c9029eebb19c612fb38ee5dd2430a\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://0a625c8795354d9f429367f9c1d14eb8af7db9c7f2c2a2033e2066ced76a573a\",\"dweb:/ipfs/Qmd1j6UarUg54q1G2HCNCLQz8XGVZR1qxX7eQ6cytHpQPN\"]},\"contracts/interfaces/IAccount.sol\":{\"keccak256\":\"0x556a0e5980de18e90b115553ed502408155ba35f58642823010d9288047bc418\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a0f420134b79596db8737173c7b933ae0a33059e107b6327c43aa40d4744a9e4\",\"dweb:/ipfs/QmRo8s1AhXmEMV7uPYnbpYwU19e9Bk6jmYBJTiPx3Fo85W\"]},\"contracts/interfaces/IAggregator.sol\":{\"keccak256\":\"0x060e9ddb0152250c269ba0640dc5753834ac44cf182a2837d508c0c529cae26a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://20ed837bc5909c89ff1910246bf245a5dad6840aa939382e1694964eb7dbd37b\",\"dweb:/ipfs/QmTMybRq5yyghPDDs1ZCNAVB9sSJ4WHe6Q9mejuKPTAdNP\"]},\"contracts/interfaces/IEntryPoint.sol\":{\"keccak256\":\"0x3a90bf308819ed125fa4202f880999caff8a8686633b8ddb79a30ca240d5b8f8\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://d2d21cc92c2fdab2b58d21bc25d4cd0e8c284b922528a186b087b818d54bc6cf\",\"dweb:/ipfs/QmT1qrfuBjsv2rmRCDn8mgPXHp94hARJwzbcDuBLDTbFWd\"]},\"contracts/interfaces/INonceManager.sol\":{\"keccak256\":\"0x509871e6c63663cdcc3eba19920fe84e991f38b289b1377ac3c3a6d9f22d7e12\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://00fe21b4349b24c50df60e1a705179293982bd9e7a32b78d4bac9620f89e7fe2\",\"dweb:/ipfs/QmSFFYGfUwQbVa6hASjU7YxTvgi2HkfrPr4X5oPHscHg8b\"]},\"contracts/interfaces/IPaymaster.sol\":{\"keccak256\":\"0x36858ba8685024974f533530420688da3454d29996ebc42e410673a1ed2ec456\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://616cbcf51778b1961b7f20a547bec7efae6d1d565df0f651926241ed8bde9ad8\",\"dweb:/ipfs/QmaVsgffUUmeUJYgStvRr8cNZ1LBbrc3FYNLW4JT1dVLia\"]},\"contracts/interfaces/IStakeManager.sol\":{\"keccak256\":\"0xd227b02888cd4ac68daebcdfd992ec00f9fff66fa3b3bb16f656cd582fa3480f\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://b389da4714a138be63704a576a482505eab2855e263b38a93706395d8d42e7c3\",\"dweb:/ipfs/QmeeAZpdHwUXxqP8pxA7GNtoCGBmmH4FaqLLwScVKGxtxZ\"]},\"contracts/interfaces/UserOperation.sol\":{\"keccak256\":\"0x61374003361059087fdcf17967a7bba052badeaf5c7f0ae689166f8aafd3a45c\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://6ff83c59432e733bf6304dda27cd4b0f34401917dd535e2669cc842d2d26568c\",\"dweb:/ipfs/QmPJbHU5TAjHqUTZzAcicEeG2nknmwCN43L4EW9LHbknTN\"]},\"contracts/utils/Exec.sol\":{\"keccak256\":\"0x5b232117afbc2939f3ffc92745614867e9e1d475a3e1e5443adae13c200174f1\",\"license\":\"LGPL-3.0-only\",\"urls\":[\"bzz-raw://62e7365379a06ead7b47637945bcaee095d51aab1d3ac00ddec69443e6cbe9fe\",\"dweb:/ipfs/QmctG3aw4U3KMSMeJKoLJ1NJewjMWfppnd1m3kxNTe39Uy\"]}},\"version\":1}", - "bytecode": "0x60a080604052346200008957600160025561022c8181016001600160401b038111838210176200007357829162005d18833903906000f080156200006757608052604051615c8990816200008f82396080518181816113df01528181613e9501526141b60152f35b6040513d6000823e3d90fd5b634e487b7160e01b600052604160045260246000fd5b600080fdfe60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c634300081100336080806040523461001657610210908161001c8239f35b600080fdfe6080604052600436101561001257600080fd5b6000803560e01c63570e1a361461002857600080fd5b346100c95760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126100c95760043567ffffffffffffffff918282116100c957366023830112156100c95781600401359283116100c95736602484840101116100c9576100c561009e84602485016100fc565b60405173ffffffffffffffffffffffffffffffffffffffff90911681529081906020820190565b0390f35b80fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b90806014116101bb5767ffffffffffffffff917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec82018381116101cd575b604051937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f81600b8701160116850190858210908211176101c0575b604052808452602084019036848401116101bb576020946000600c819682946014880187378301015251923560601c5af19060005191156101b557565b60009150565b600080fd5b6101c86100cc565b610178565b6101d56100cc565b61013a56fea26469706673582212201927e80b76ab9b71c952137dd676621a9fdf520c25928815636594036eb1c40364736f6c63430008110033", - "deployedBytecode": "0x60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c63430008110033" -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/gnosis/solcInputs/a4c52f0671aad8941c53d6ead2063803.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/gnosis/solcInputs/a4c52f0671aad8941c53d6ead2063803.json deleted file mode 100644 index dd58ba5a3e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/gnosis/solcInputs/a4c52f0671aad8941c53d6ead2063803.json +++ /dev/null @@ -1,68 +0,0 @@ -{ - "language": "Solidity", - "sources": { - "@openzeppelin/contracts/security/ReentrancyGuard.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (security/ReentrancyGuard.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Contract module that helps prevent reentrant calls to a function.\n *\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\n * available, which can be applied to functions to make sure there are no nested\n * (reentrant) calls to them.\n *\n * Note that because there is a single `nonReentrant` guard, functions marked as\n * `nonReentrant` may not call one another. This can be worked around by making\n * those functions `private`, and then adding `external` `nonReentrant` entry\n * points to them.\n *\n * TIP: If you would like to learn more about reentrancy and alternative ways\n * to protect against it, check out our blog post\n * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].\n */\nabstract contract ReentrancyGuard {\n // Booleans are more expensive than uint256 or any type that takes up a full\n // word because each write operation emits an extra SLOAD to first read the\n // slot's contents, replace the bits taken up by the boolean, and then write\n // back. This is the compiler's defense against contract upgrades and\n // pointer aliasing, and it cannot be disabled.\n\n // The values being non-zero value makes deployment a bit more expensive,\n // but in exchange the refund on every call to nonReentrant will be lower in\n // amount. Since refunds are capped to a percentage of the total\n // transaction's gas, it is best to keep them low in cases like this one, to\n // increase the likelihood of the full refund coming into effect.\n uint256 private constant _NOT_ENTERED = 1;\n uint256 private constant _ENTERED = 2;\n\n uint256 private _status;\n\n constructor() {\n _status = _NOT_ENTERED;\n }\n\n /**\n * @dev Prevents a contract from calling itself, directly or indirectly.\n * Calling a `nonReentrant` function from another `nonReentrant`\n * function is not supported. It is possible to prevent this from happening\n * by making the `nonReentrant` function external, and making it call a\n * `private` function that does the actual work.\n */\n modifier nonReentrant() {\n _nonReentrantBefore();\n _;\n _nonReentrantAfter();\n }\n\n function _nonReentrantBefore() private {\n // On the first call to nonReentrant, _status will be _NOT_ENTERED\n require(_status != _ENTERED, \"ReentrancyGuard: reentrant call\");\n\n // Any calls to nonReentrant after this point will fail\n _status = _ENTERED;\n }\n\n function _nonReentrantAfter() private {\n // By storing the original value once again, a refund is triggered (see\n // https://eips.ethereum.org/EIPS/eip-2200)\n _status = _NOT_ENTERED;\n }\n}\n" - }, - "contracts/core/EntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IPaymaster.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\n\nimport \"../utils/Exec.sol\";\nimport \"./StakeManager.sol\";\nimport \"./SenderCreator.sol\";\nimport \"./Helpers.sol\";\nimport \"./NonceManager.sol\";\nimport \"@openzeppelin/contracts/security/ReentrancyGuard.sol\";\n\ncontract EntryPoint is IEntryPoint, StakeManager, NonceManager, ReentrancyGuard {\n\n using UserOperationLib for UserOperation;\n\n SenderCreator private immutable senderCreator = new SenderCreator();\n\n // internal value used during simulation: need to query aggregator.\n address private constant SIMULATE_FIND_AGGREGATOR = address(1);\n\n // marker for inner call revert on out of gas\n bytes32 private constant INNER_OUT_OF_GAS = hex'deaddead';\n\n uint256 private constant REVERT_REASON_MAX_LEN = 2048;\n\n /**\n * for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value\n * in case of signature failure, instead of revert.\n */\n uint256 public constant SIG_VALIDATION_FAILED = 1;\n\n /**\n * compensate the caller's beneficiary address with the collected fees of all UserOperations.\n * @param beneficiary the address to receive the fees\n * @param amount amount to transfer.\n */\n function _compensate(address payable beneficiary, uint256 amount) internal {\n require(beneficiary != address(0), \"AA90 invalid beneficiary\");\n (bool success,) = beneficiary.call{value : amount}(\"\");\n require(success, \"AA91 failed send to beneficiary\");\n }\n\n /**\n * execute a user op\n * @param opIndex index into the opInfo array\n * @param userOp the userOp to execute\n * @param opInfo the opInfo filled by validatePrepayment for this userOp.\n * @return collected the total amount this userOp paid.\n */\n function _executeUserOp(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory opInfo) private returns (uint256 collected) {\n uint256 preGas = gasleft();\n bytes memory context = getMemoryBytesFromOffset(opInfo.contextOffset);\n\n try this.innerHandleOp(userOp.callData, opInfo, context) returns (uint256 _actualGasCost) {\n collected = _actualGasCost;\n } catch {\n bytes32 innerRevertCode;\n assembly {\n returndatacopy(0, 0, 32)\n innerRevertCode := mload(0)\n }\n // handleOps was called with gas limit too low. abort entire bundle.\n if (innerRevertCode == INNER_OUT_OF_GAS) {\n //report paymaster, since if it is not deliberately caused by the bundler,\n // it must be a revert caused by paymaster.\n revert FailedOp(opIndex, \"AA95 out of gas\");\n }\n\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n collected = _handlePostOp(opIndex, IPaymaster.PostOpMode.postOpReverted, opInfo, context, actualGas);\n }\n }\n\n /**\n * Execute a batch of UserOperations.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) public nonReentrant {\n\n uint256 opslen = ops.length;\n UserOpInfo[] memory opInfos = new UserOpInfo[](opslen);\n\n unchecked {\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[i];\n (uint256 validationData, uint256 pmValidationData) = _validatePrepayment(i, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, pmValidationData, address(0));\n }\n\n uint256 collected = 0;\n emit BeforeExecution();\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(i, ops[i], opInfos[i]);\n }\n\n _compensate(beneficiary, collected);\n } //unchecked\n }\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) public nonReentrant {\n\n uint256 opasLen = opsPerAggregator.length;\n uint256 totalOps = 0;\n for (uint256 i = 0; i < opasLen; i++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[i];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n //address(1) is special marker of \"signature error\"\n require(address(aggregator) != address(1), \"AA96 invalid aggregator\");\n\n if (address(aggregator) != address(0)) {\n // solhint-disable-next-line no-empty-blocks\n try aggregator.validateSignatures(ops, opa.signature) {}\n catch {\n revert SignatureValidationFailed(address(aggregator));\n }\n }\n\n totalOps += ops.length;\n }\n\n UserOpInfo[] memory opInfos = new UserOpInfo[](totalOps);\n\n emit BeforeExecution();\n\n uint256 opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n uint256 opslen = ops.length;\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[opIndex];\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(opIndex, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, paymasterValidationData, address(aggregator));\n opIndex++;\n }\n }\n\n uint256 collected = 0;\n opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n emit SignatureAggregatorChanged(address(opa.aggregator));\n UserOperation[] calldata ops = opa.userOps;\n uint256 opslen = ops.length;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(opIndex, ops[i], opInfos[opIndex]);\n opIndex++;\n }\n }\n emit SignatureAggregatorChanged(address(0));\n\n _compensate(beneficiary, collected);\n }\n\n /// @inheritdoc IEntryPoint\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external override {\n\n UserOpInfo memory opInfo;\n _simulationOnlyValidations(op);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, op, opInfo);\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n\n numberMarker();\n uint256 paid = _executeUserOp(0, op, opInfo);\n numberMarker();\n bool targetSuccess;\n bytes memory targetResult;\n if (target != address(0)) {\n (targetSuccess, targetResult) = target.call(targetCallData);\n }\n revert ExecutionResult(opInfo.preOpGas, paid, data.validAfter, data.validUntil, targetSuccess, targetResult);\n }\n\n\n // A memory copy of UserOp static fields only.\n // Excluding: callData, initCode and signature. Replacing paymasterAndData with paymaster.\n struct MemoryUserOp {\n address sender;\n uint256 nonce;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n address paymaster;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n }\n\n struct UserOpInfo {\n MemoryUserOp mUserOp;\n bytes32 userOpHash;\n uint256 prefund;\n uint256 contextOffset;\n uint256 preOpGas;\n }\n\n /**\n * inner function to handle a UserOperation.\n * Must be declared \"external\" to open a call context, but it can only be called by handleOps.\n */\n function innerHandleOp(bytes memory callData, UserOpInfo memory opInfo, bytes calldata context) external returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n require(msg.sender == address(this), \"AA92 internal call only\");\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n\n uint callGasLimit = mUserOp.callGasLimit;\n unchecked {\n // handleOps was called with gas limit too low. abort entire bundle.\n if (gasleft() < callGasLimit + mUserOp.verificationGasLimit + 5000) {\n assembly {\n mstore(0, INNER_OUT_OF_GAS)\n revert(0, 32)\n }\n }\n }\n\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\n if (callData.length > 0) {\n bool success = Exec.call(mUserOp.sender, 0, callData, callGasLimit);\n if (!success) {\n bytes memory result = Exec.getReturnData(REVERT_REASON_MAX_LEN);\n if (result.length > 0) {\n emit UserOperationRevertReason(opInfo.userOpHash, mUserOp.sender, mUserOp.nonce, result);\n }\n mode = IPaymaster.PostOpMode.opReverted;\n }\n }\n\n unchecked {\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n //note: opIndex is ignored (relevant only if mode==postOpReverted, which is only possible outside of innerHandleOp)\n return _handlePostOp(0, mode, opInfo, context, actualGas);\n }\n }\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) public view returns (bytes32) {\n return keccak256(abi.encode(userOp.hash(), address(this), block.chainid));\n }\n\n /**\n * copy general fields from userOp into the memory opInfo structure.\n */\n function _copyUserOpToMemory(UserOperation calldata userOp, MemoryUserOp memory mUserOp) internal pure {\n mUserOp.sender = userOp.sender;\n mUserOp.nonce = userOp.nonce;\n mUserOp.callGasLimit = userOp.callGasLimit;\n mUserOp.verificationGasLimit = userOp.verificationGasLimit;\n mUserOp.preVerificationGas = userOp.preVerificationGas;\n mUserOp.maxFeePerGas = userOp.maxFeePerGas;\n mUserOp.maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes calldata paymasterAndData = userOp.paymasterAndData;\n if (paymasterAndData.length > 0) {\n require(paymasterAndData.length >= 20, \"AA93 invalid paymasterAndData\");\n mUserOp.paymaster = address(bytes20(paymasterAndData[: 20]));\n } else {\n mUserOp.paymaster = address(0);\n }\n }\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external {\n UserOpInfo memory outOpInfo;\n\n _simulationOnlyValidations(userOp);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, userOp, outOpInfo);\n StakeInfo memory paymasterInfo = _getStakeInfo(outOpInfo.mUserOp.paymaster);\n StakeInfo memory senderInfo = _getStakeInfo(outOpInfo.mUserOp.sender);\n StakeInfo memory factoryInfo;\n {\n bytes calldata initCode = userOp.initCode;\n address factory = initCode.length >= 20 ? address(bytes20(initCode[0 : 20])) : address(0);\n factoryInfo = _getStakeInfo(factory);\n }\n\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n address aggregator = data.aggregator;\n bool sigFailed = aggregator == address(1);\n ReturnInfo memory returnInfo = ReturnInfo(outOpInfo.preOpGas, outOpInfo.prefund,\n sigFailed, data.validAfter, data.validUntil, getMemoryBytesFromOffset(outOpInfo.contextOffset));\n\n if (aggregator != address(0) && aggregator != address(1)) {\n AggregatorStakeInfo memory aggregatorInfo = AggregatorStakeInfo(aggregator, _getStakeInfo(aggregator));\n revert ValidationResultWithAggregation(returnInfo, senderInfo, factoryInfo, paymasterInfo, aggregatorInfo);\n }\n revert ValidationResult(returnInfo, senderInfo, factoryInfo, paymasterInfo);\n\n }\n\n function _getRequiredPrefund(MemoryUserOp memory mUserOp) internal pure returns (uint256 requiredPrefund) {\n unchecked {\n //when using a Paymaster, the verificationGasLimit is used also to as a limit for the postOp call.\n // our security model might call postOp eventually twice\n uint256 mul = mUserOp.paymaster != address(0) ? 3 : 1;\n uint256 requiredGas = mUserOp.callGasLimit + mUserOp.verificationGasLimit * mul + mUserOp.preVerificationGas;\n\n requiredPrefund = requiredGas * mUserOp.maxFeePerGas;\n }\n }\n\n // create the sender's contract if needed.\n function _createSenderIfNeeded(uint256 opIndex, UserOpInfo memory opInfo, bytes calldata initCode) internal {\n if (initCode.length != 0) {\n address sender = opInfo.mUserOp.sender;\n if (sender.code.length != 0) revert FailedOp(opIndex, \"AA10 sender already constructed\");\n address sender1 = senderCreator.createSender{gas : opInfo.mUserOp.verificationGasLimit}(initCode);\n if (sender1 == address(0)) revert FailedOp(opIndex, \"AA13 initCode failed or OOG\");\n if (sender1 != sender) revert FailedOp(opIndex, \"AA14 initCode must return sender\");\n if (sender1.code.length == 0) revert FailedOp(opIndex, \"AA15 initCode must create sender\");\n address factory = address(bytes20(initCode[0 : 20]));\n emit AccountDeployed(opInfo.userOpHash, sender, factory, opInfo.mUserOp.paymaster);\n }\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes calldata initCode) public {\n address sender = senderCreator.createSender(initCode);\n revert SenderAddressResult(sender);\n }\n\n function _simulationOnlyValidations(UserOperation calldata userOp) internal view {\n // solhint-disable-next-line no-empty-blocks\n try this._validateSenderAndPaymaster(userOp.initCode, userOp.sender, userOp.paymasterAndData) {}\n catch Error(string memory revertReason) {\n if (bytes(revertReason).length != 0) {\n revert FailedOp(0, revertReason);\n }\n }\n }\n\n /**\n * Called only during simulation.\n * This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\n */\n function _validateSenderAndPaymaster(bytes calldata initCode, address sender, bytes calldata paymasterAndData) external view {\n if (initCode.length == 0 && sender.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA20 account not deployed\");\n }\n if (paymasterAndData.length >= 20) {\n address paymaster = address(bytes20(paymasterAndData[0 : 20]));\n if (paymaster.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA30 paymaster not deployed\");\n }\n }\n // always revert\n revert(\"\");\n }\n\n /**\n * call account.validateUserOp.\n * revert (with FailedOp) in case validateUserOp reverts, or account didn't send required prefund.\n * decrement account's deposit if needed\n */\n function _validateAccountPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPrefund)\n internal returns (uint256 gasUsedByValidateAccountPrepayment, uint256 validationData) {\n unchecked {\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n address sender = mUserOp.sender;\n _createSenderIfNeeded(opIndex, opInfo, op.initCode);\n address paymaster = mUserOp.paymaster;\n numberMarker();\n uint256 missingAccountFunds = 0;\n if (paymaster == address(0)) {\n uint256 bal = balanceOf(sender);\n missingAccountFunds = bal > requiredPrefund ? 0 : requiredPrefund - bal;\n }\n try IAccount(sender).validateUserOp{gas : mUserOp.verificationGasLimit}(op, opInfo.userOpHash, missingAccountFunds)\n returns (uint256 _validationData) {\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA23 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA23 reverted (or OOG)\");\n }\n if (paymaster == address(0)) {\n DepositInfo storage senderInfo = deposits[sender];\n uint256 deposit = senderInfo.deposit;\n if (requiredPrefund > deposit) {\n revert FailedOp(opIndex, \"AA21 didn't pay prefund\");\n }\n senderInfo.deposit = uint112(deposit - requiredPrefund);\n }\n gasUsedByValidateAccountPrepayment = preGas - gasleft();\n }\n }\n\n /**\n * In case the request has a paymaster:\n * Validate paymaster has enough deposit.\n * Call paymaster.validatePaymasterUserOp.\n * Revert with proper FailedOp in case paymaster reverts.\n * Decrement paymaster's deposit\n */\n function _validatePaymasterPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPreFund, uint256 gasUsedByValidateAccountPrepayment)\n internal returns (bytes memory context, uint256 validationData) {\n unchecked {\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 verificationGasLimit = mUserOp.verificationGasLimit;\n require(verificationGasLimit > gasUsedByValidateAccountPrepayment, \"AA41 too little verificationGas\");\n uint256 gas = verificationGasLimit - gasUsedByValidateAccountPrepayment;\n\n address paymaster = mUserOp.paymaster;\n DepositInfo storage paymasterInfo = deposits[paymaster];\n uint256 deposit = paymasterInfo.deposit;\n if (deposit < requiredPreFund) {\n revert FailedOp(opIndex, \"AA31 paymaster deposit too low\");\n }\n paymasterInfo.deposit = uint112(deposit - requiredPreFund);\n try IPaymaster(paymaster).validatePaymasterUserOp{gas : gas}(op, opInfo.userOpHash, requiredPreFund) returns (bytes memory _context, uint256 _validationData){\n context = _context;\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA33 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA33 reverted (or OOG)\");\n }\n }\n }\n\n /**\n * revert if either account validationData or paymaster validationData is expired\n */\n function _validateAccountAndPaymasterValidationData(uint256 opIndex, uint256 validationData, uint256 paymasterValidationData, address expectedAggregator) internal view {\n (address aggregator, bool outOfTimeRange) = _getValidationData(validationData);\n if (expectedAggregator != aggregator) {\n revert FailedOp(opIndex, \"AA24 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA22 expired or not due\");\n }\n //pmAggregator is not a real signature aggregator: we don't have logic to handle it as address.\n // non-zero address means that the paymaster fails due to some signature check (which is ok only during estimation)\n address pmAggregator;\n (pmAggregator, outOfTimeRange) = _getValidationData(paymasterValidationData);\n if (pmAggregator != address(0)) {\n revert FailedOp(opIndex, \"AA34 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA32 paymaster expired or not due\");\n }\n }\n\n function _getValidationData(uint256 validationData) internal view returns (address aggregator, bool outOfTimeRange) {\n if (validationData == 0) {\n return (address(0), false);\n }\n ValidationData memory data = _parseValidationData(validationData);\n // solhint-disable-next-line not-rely-on-time\n outOfTimeRange = block.timestamp > data.validUntil || block.timestamp < data.validAfter;\n aggregator = data.aggregator;\n }\n\n /**\n * validate account and paymaster (if defined).\n * also make sure total validation doesn't exceed verificationGasLimit\n * this method is called off-chain (simulateValidation()) and on-chain (from handleOps)\n * @param opIndex the index of this userOp into the \"opInfos\" array\n * @param userOp the userOp to validate\n */\n function _validatePrepayment(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory outOpInfo)\n private returns (uint256 validationData, uint256 paymasterValidationData) {\n\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = outOpInfo.mUserOp;\n _copyUserOpToMemory(userOp, mUserOp);\n outOpInfo.userOpHash = getUserOpHash(userOp);\n\n // validate all numeric values in userOp are well below 128 bit, so they can safely be added\n // and multiplied without causing overflow\n uint256 maxGasValues = mUserOp.preVerificationGas | mUserOp.verificationGasLimit | mUserOp.callGasLimit |\n userOp.maxFeePerGas | userOp.maxPriorityFeePerGas;\n require(maxGasValues <= type(uint120).max, \"AA94 gas values overflow\");\n\n uint256 gasUsedByValidateAccountPrepayment;\n (uint256 requiredPreFund) = _getRequiredPrefund(mUserOp);\n (gasUsedByValidateAccountPrepayment, validationData) = _validateAccountPrepayment(opIndex, userOp, outOpInfo, requiredPreFund);\n\n if (!_validateAndUpdateNonce(mUserOp.sender, mUserOp.nonce)) {\n revert FailedOp(opIndex, \"AA25 invalid account nonce\");\n }\n\n //a \"marker\" where account opcode validation is done and paymaster opcode validation is about to start\n // (used only by off-chain simulateValidation)\n numberMarker();\n\n bytes memory context;\n if (mUserOp.paymaster != address(0)) {\n (context, paymasterValidationData) = _validatePaymasterPrepayment(opIndex, userOp, outOpInfo, requiredPreFund, gasUsedByValidateAccountPrepayment);\n }\n unchecked {\n uint256 gasUsed = preGas - gasleft();\n\n if (userOp.verificationGasLimit < gasUsed) {\n revert FailedOp(opIndex, \"AA40 over verificationGasLimit\");\n }\n outOpInfo.prefund = requiredPreFund;\n outOpInfo.contextOffset = getOffsetOfMemoryBytes(context);\n outOpInfo.preOpGas = preGas - gasleft() + userOp.preVerificationGas;\n }\n }\n\n /**\n * process post-operation.\n * called just after the callData is executed.\n * if a paymaster is defined and its validation returned a non-empty context, its postOp is called.\n * the excess amount is refunded to the account (or paymaster - if it was used in the request)\n * @param opIndex index in the batch\n * @param mode - whether is called from innerHandleOp, or outside (postOpReverted)\n * @param opInfo userOp fields and info collected during validation\n * @param context the context returned in validatePaymasterUserOp\n * @param actualGas the gas used so far by this user operation\n */\n function _handlePostOp(uint256 opIndex, IPaymaster.PostOpMode mode, UserOpInfo memory opInfo, bytes memory context, uint256 actualGas) private returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n unchecked {\n address refundAddress;\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 gasPrice = getUserOpGasPrice(mUserOp);\n\n address paymaster = mUserOp.paymaster;\n if (paymaster == address(0)) {\n refundAddress = mUserOp.sender;\n } else {\n refundAddress = paymaster;\n if (context.length > 0) {\n actualGasCost = actualGas * gasPrice;\n if (mode != IPaymaster.PostOpMode.postOpReverted) {\n IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost);\n } else {\n // solhint-disable-next-line no-empty-blocks\n try IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost) {}\n catch Error(string memory reason) {\n revert FailedOp(opIndex, string.concat(\"AA50 postOp reverted: \", reason));\n }\n catch {\n revert FailedOp(opIndex, \"AA50 postOp revert\");\n }\n }\n }\n }\n actualGas += preGas - gasleft();\n actualGasCost = actualGas * gasPrice;\n if (opInfo.prefund < actualGasCost) {\n revert FailedOp(opIndex, \"AA51 prefund below actualGasCost\");\n }\n uint256 refund = opInfo.prefund - actualGasCost;\n _incrementDeposit(refundAddress, refund);\n bool success = mode == IPaymaster.PostOpMode.opSucceeded;\n emit UserOperationEvent(opInfo.userOpHash, mUserOp.sender, mUserOp.paymaster, mUserOp.nonce, success, actualGasCost, actualGas);\n } // unchecked\n }\n\n /**\n * the gas price this UserOp agrees to pay.\n * relayer/block builder might submit the TX with higher priorityFee, but the user should not\n */\n function getUserOpGasPrice(MemoryUserOp memory mUserOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = mUserOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = mUserOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n\n function getOffsetOfMemoryBytes(bytes memory data) internal pure returns (uint256 offset) {\n assembly {offset := data}\n }\n\n function getMemoryBytesFromOffset(uint256 offset) internal pure returns (bytes memory data) {\n assembly {data := offset}\n }\n\n //place the NUMBER opcode in the code.\n // this is used as a marker during simulation, as this OP is completely banned from the simulated code of the\n // account and paymaster.\n function numberMarker() internal view {\n assembly {mstore(0, number())}\n }\n}\n\n" - }, - "contracts/core/Helpers.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\n/**\n * returned data from validateUserOp.\n * validateUserOp returns a uint256, with is created by `_packedValidationData` and parsed by `_parseValidationData`\n * @param aggregator - address(0) - the account validated the signature by itself.\n * address(1) - the account failed to validate the signature.\n * otherwise - this is an address of a signature aggregator that must be used to validate the signature.\n * @param validAfter - this UserOp is valid only after this timestamp.\n * @param validaUntil - this UserOp is valid only up to this timestamp.\n */\n struct ValidationData {\n address aggregator;\n uint48 validAfter;\n uint48 validUntil;\n }\n\n//extract sigFailed, validAfter, validUntil.\n// also convert zero validUntil to type(uint48).max\n function _parseValidationData(uint validationData) pure returns (ValidationData memory data) {\n address aggregator = address(uint160(validationData));\n uint48 validUntil = uint48(validationData >> 160);\n if (validUntil == 0) {\n validUntil = type(uint48).max;\n }\n uint48 validAfter = uint48(validationData >> (48 + 160));\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n// intersect account and paymaster ranges.\n function _intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) pure returns (ValidationData memory) {\n ValidationData memory accountValidationData = _parseValidationData(validationData);\n ValidationData memory pmValidationData = _parseValidationData(paymasterValidationData);\n address aggregator = accountValidationData.aggregator;\n if (aggregator == address(0)) {\n aggregator = pmValidationData.aggregator;\n }\n uint48 validAfter = accountValidationData.validAfter;\n uint48 validUntil = accountValidationData.validUntil;\n uint48 pmValidAfter = pmValidationData.validAfter;\n uint48 pmValidUntil = pmValidationData.validUntil;\n\n if (validAfter < pmValidAfter) validAfter = pmValidAfter;\n if (validUntil > pmValidUntil) validUntil = pmValidUntil;\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n/**\n * helper to pack the return value for validateUserOp\n * @param data - the ValidationData to pack\n */\n function _packValidationData(ValidationData memory data) pure returns (uint256) {\n return uint160(data.aggregator) | (uint256(data.validUntil) << 160) | (uint256(data.validAfter) << (160 + 48));\n }\n\n/**\n * helper to pack the return value for validateUserOp, when not using an aggregator\n * @param sigFailed - true for signature failure, false for success\n * @param validUntil last timestamp this UserOperation is valid (or zero for infinite)\n * @param validAfter first timestamp this UserOperation is valid\n */\n function _packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) pure returns (uint256) {\n return (sigFailed ? 1 : 0) | (uint256(validUntil) << 160) | (uint256(validAfter) << (160 + 48));\n }\n\n/**\n * keccak function over calldata.\n * @dev copy calldata into memory, do keccak and drop allocated memory. Strangely, this is more efficient than letting solidity do it.\n */\n function calldataKeccak(bytes calldata data) pure returns (bytes32 ret) {\n assembly {\n let mem := mload(0x40)\n let len := data.length\n calldatacopy(mem, data.offset, len)\n ret := keccak256(mem, len)\n }\n }\n\n" - }, - "contracts/core/NonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IEntryPoint.sol\";\n\n/**\n * nonce management functionality\n */\ncontract NonceManager is INonceManager {\n\n /**\n * The next valid sequence number for a given nonce key.\n */\n mapping(address => mapping(uint192 => uint256)) public nonceSequenceNumber;\n\n function getNonce(address sender, uint192 key)\n public view override returns (uint256 nonce) {\n return nonceSequenceNumber[sender][key] | (uint256(key) << 64);\n }\n\n // allow an account to manually increment its own nonce.\n // (mainly so that during construction nonce can be made non-zero,\n // to \"absorb\" the gas cost of first nonce increment to 1st transaction (construction),\n // not to 2nd transaction)\n function incrementNonce(uint192 key) public override {\n nonceSequenceNumber[msg.sender][key]++;\n }\n\n /**\n * validate nonce uniqueness for this account.\n * called just after validateUserOp()\n */\n function _validateAndUpdateNonce(address sender, uint256 nonce) internal returns (bool) {\n\n uint192 key = uint192(nonce >> 64);\n uint64 seq = uint64(nonce);\n return nonceSequenceNumber[sender][key]++ == seq;\n }\n\n}\n" - }, - "contracts/core/SenderCreator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * helper contract for EntryPoint, to call userOp.initCode from a \"neutral\" address,\n * which is explicitly not the entryPoint itself.\n */\ncontract SenderCreator {\n\n /**\n * call the \"initCode\" factory to create and return the sender account address\n * @param initCode the initCode value from a UserOp. contains 20 bytes of factory address, followed by calldata\n * @return sender the returned address of the created account, or zero address on failure.\n */\n function createSender(bytes calldata initCode) external returns (address sender) {\n address factory = address(bytes20(initCode[0 : 20]));\n bytes memory initCallData = initCode[20 :];\n bool success;\n /* solhint-disable no-inline-assembly */\n assembly {\n success := call(gas(), factory, 0, add(initCallData, 0x20), mload(initCallData), 0, 32)\n sender := mload(0)\n }\n if (!success) {\n sender = address(0);\n }\n }\n}\n" - }, - "contracts/core/StakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IStakeManager.sol\";\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable not-rely-on-time */\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by a paymaster.\n */\nabstract contract StakeManager is IStakeManager {\n\n /// maps paymaster to their deposits and stakes\n mapping(address => DepositInfo) public deposits;\n\n /// @inheritdoc IStakeManager\n function getDepositInfo(address account) public view returns (DepositInfo memory info) {\n return deposits[account];\n }\n\n // internal method to return just the stake info\n function _getStakeInfo(address addr) internal view returns (StakeInfo memory info) {\n DepositInfo storage depositInfo = deposits[addr];\n info.stake = depositInfo.stake;\n info.unstakeDelaySec = depositInfo.unstakeDelaySec;\n }\n\n /// return the deposit (for gas payment) of the account\n function balanceOf(address account) public view returns (uint256) {\n return deposits[account].deposit;\n }\n\n receive() external payable {\n depositTo(msg.sender);\n }\n\n function _incrementDeposit(address account, uint256 amount) internal {\n DepositInfo storage info = deposits[account];\n uint256 newAmount = info.deposit + amount;\n require(newAmount <= type(uint112).max, \"deposit overflow\");\n info.deposit = uint112(newAmount);\n }\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) public payable {\n _incrementDeposit(account, msg.value);\n DepositInfo storage info = deposits[account];\n emit Deposited(account, info.deposit);\n }\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 unstakeDelaySec) public payable {\n DepositInfo storage info = deposits[msg.sender];\n require(unstakeDelaySec > 0, \"must specify unstake delay\");\n require(unstakeDelaySec >= info.unstakeDelaySec, \"cannot decrease unstake time\");\n uint256 stake = info.stake + msg.value;\n require(stake > 0, \"no stake specified\");\n require(stake <= type(uint112).max, \"stake overflow\");\n deposits[msg.sender] = DepositInfo(\n info.deposit,\n true,\n uint112(stake),\n unstakeDelaySec,\n 0\n );\n emit StakeLocked(msg.sender, stake, unstakeDelaySec);\n }\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external {\n DepositInfo storage info = deposits[msg.sender];\n require(info.unstakeDelaySec != 0, \"not staked\");\n require(info.staked, \"already unstaking\");\n uint48 withdrawTime = uint48(block.timestamp) + info.unstakeDelaySec;\n info.withdrawTime = withdrawTime;\n info.staked = false;\n emit StakeUnlocked(msg.sender, withdrawTime);\n }\n\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external {\n DepositInfo storage info = deposits[msg.sender];\n uint256 stake = info.stake;\n require(stake > 0, \"No stake to withdraw\");\n require(info.withdrawTime > 0, \"must call unlockStake() first\");\n require(info.withdrawTime <= block.timestamp, \"Stake withdrawal is not due\");\n info.unstakeDelaySec = 0;\n info.withdrawTime = 0;\n info.stake = 0;\n emit StakeWithdrawn(msg.sender, withdrawAddress, stake);\n (bool success,) = withdrawAddress.call{value : stake}(\"\");\n require(success, \"failed to withdraw stake\");\n }\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external {\n DepositInfo storage info = deposits[msg.sender];\n require(withdrawAmount <= info.deposit, \"Withdraw amount too large\");\n info.deposit = uint112(info.deposit - withdrawAmount);\n emit Withdrawn(msg.sender, withdrawAddress, withdrawAmount);\n (bool success,) = withdrawAddress.call{value : withdrawAmount}(\"\");\n require(success, \"failed to withdraw\");\n }\n}\n" - }, - "contracts/interfaces/IAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\ninterface IAccount {\n\n /**\n * Validate user's signature and nonce\n * the entryPoint will make the call to the recipient only if this validation call returns successfully.\n * signature failure should be reported by returning SIG_VALIDATION_FAILED (1).\n * This allows making a \"simulation call\" without a valid signature\n * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure.\n *\n * @dev Must validate caller is the entryPoint.\n * Must validate the signature and nonce\n * @param userOp the operation that is about to be executed.\n * @param userOpHash hash of the user's request data. can be used as the basis for signature.\n * @param missingAccountFunds missing funds on the account's deposit in the entrypoint.\n * This is the minimum amount to transfer to the sender(entryPoint) to be able to make the call.\n * The excess is left as a deposit in the entrypoint, for future calls.\n * can be withdrawn anytime using \"entryPoint.withdrawTo()\"\n * In case there is a paymaster in the request (or the current deposit is high enough), this value will be zero.\n * @return validationData packaged ValidationData structure. use `_packValidationData` and `_unpackValidationData` to encode and decode\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * If an account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external returns (uint256 validationData);\n}\n" - }, - "contracts/interfaces/IAggregator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * Aggregated Signatures validator.\n */\ninterface IAggregator {\n\n /**\n * validate aggregated signature.\n * revert if the aggregated signature does not match the given list of operations.\n */\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external view;\n\n /**\n * validate signature of a single userOp\n * This method is should be called by bundler after EntryPoint.simulateValidation() returns (reverts) with ValidationResultWithAggregation\n * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps.\n * @param userOp the userOperation received from the user.\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\n * (usually empty, unless account and aggregator support some kind of \"multisig\"\n */\n function validateUserOpSignature(UserOperation calldata userOp)\n external view returns (bytes memory sigForUserOp);\n\n /**\n * aggregate multiple signatures into a single value.\n * This method is called off-chain to calculate the signature to pass with handleOps()\n * bundler MAY use optimized custom code perform this aggregation\n * @param userOps array of UserOperations to collect the signatures from.\n * @return aggregatedSignature the aggregated signature\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external view returns (bytes memory aggregatedSignature);\n}\n" - }, - "contracts/interfaces/IEntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"./UserOperation.sol\";\nimport \"./IStakeManager.sol\";\nimport \"./IAggregator.sol\";\nimport \"./INonceManager.sol\";\n\ninterface IEntryPoint is IStakeManager, INonceManager {\n\n /***\n * An event emitted after each successful request\n * @param userOpHash - unique identifier for the request (hash its entire content, except signature).\n * @param sender - the account that generates this request.\n * @param paymaster - if non-null, the paymaster that pays for this request.\n * @param nonce - the nonce value from the request.\n * @param success - true if the sender transaction succeeded, false if reverted.\n * @param actualGasCost - actual amount paid (by account or paymaster) for this UserOperation.\n * @param actualGasUsed - total gas used by this UserOperation (including preVerification, creation, validation and execution).\n */\n event UserOperationEvent(bytes32 indexed userOpHash, address indexed sender, address indexed paymaster, uint256 nonce, bool success, uint256 actualGasCost, uint256 actualGasUsed);\n\n /**\n * account \"sender\" was deployed.\n * @param userOpHash the userOp that deployed this account. UserOperationEvent will follow.\n * @param sender the account that is deployed\n * @param factory the factory used to deploy this account (in the initCode)\n * @param paymaster the paymaster used by this UserOp\n */\n event AccountDeployed(bytes32 indexed userOpHash, address indexed sender, address factory, address paymaster);\n\n /**\n * An event emitted if the UserOperation \"callData\" reverted with non-zero length\n * @param userOpHash the request unique identifier.\n * @param sender the sender of this request\n * @param nonce the nonce used in the request\n * @param revertReason - the return bytes from the (reverted) call to \"callData\".\n */\n event UserOperationRevertReason(bytes32 indexed userOpHash, address indexed sender, uint256 nonce, bytes revertReason);\n\n /**\n * an event emitted by handleOps(), before starting the execution loop.\n * any event emitted before this event, is part of the validation.\n */\n event BeforeExecution();\n\n /**\n * signature aggregator used by the following UserOperationEvents within this bundle.\n */\n event SignatureAggregatorChanged(address indexed aggregator);\n\n /**\n * a custom revert error of handleOps, to identify the offending op.\n * NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\n * @param opIndex - index into the array of ops to the failed one (in simulateValidation, this is always zero)\n * @param reason - revert reason\n * The string starts with a unique code \"AAmn\", where \"m\" is \"1\" for factory, \"2\" for account and \"3\" for paymaster issues,\n * so a failure can be attributed to the correct entity.\n * Should be caught in off-chain handleOps simulation and not happen on-chain.\n * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\n */\n error FailedOp(uint256 opIndex, string reason);\n\n /**\n * error case when a signature aggregator fails to verify the aggregated signature it had created.\n */\n error SignatureValidationFailed(address aggregator);\n\n /**\n * Successful result from simulateValidation.\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n */\n error ValidationResult(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo);\n\n /**\n * Successful result from simulateValidation, if the account returns a signature aggregator\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n * @param aggregatorInfo signature aggregation info (if the account requires signature aggregator)\n * bundler MUST use it to verify the signature, or reject the UserOperation\n */\n error ValidationResultWithAggregation(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo,\n AggregatorStakeInfo aggregatorInfo);\n\n /**\n * return value of getSenderAddress\n */\n error SenderAddressResult(address sender);\n\n /**\n * return value of simulateHandleOp\n */\n error ExecutionResult(uint256 preOpGas, uint256 paid, uint48 validAfter, uint48 validUntil, bool targetSuccess, bytes targetResult);\n\n //UserOps handled, per aggregator\n struct UserOpsPerAggregator {\n UserOperation[] userOps;\n\n // aggregator address\n IAggregator aggregator;\n // aggregated signature\n bytes signature;\n }\n\n /**\n * Execute a batch of UserOperation.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) external;\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) external;\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) external view returns (bytes32);\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external;\n\n /**\n * gas and return values during simulation\n * @param preOpGas the gas used for validation (including preValidationGas)\n * @param prefund the required prefund for this operation\n * @param sigFailed validateUserOp's (or paymaster's) signature check failed\n * @param validAfter - first timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param validUntil - last timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param paymasterContext returned by validatePaymasterUserOp (to be passed into postOp)\n */\n struct ReturnInfo {\n uint256 preOpGas;\n uint256 prefund;\n bool sigFailed;\n uint48 validAfter;\n uint48 validUntil;\n bytes paymasterContext;\n }\n\n /**\n * returned aggregated signature info.\n * the aggregator returned by the account, and its current stake.\n */\n struct AggregatorStakeInfo {\n address aggregator;\n StakeInfo stakeInfo;\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes memory initCode) external;\n\n\n /**\n * simulate full execution of a UserOperation (including both validation and target execution)\n * this method will always revert with \"ExecutionResult\".\n * it performs full validation of the UserOperation, but ignores signature error.\n * an optional target address is called after the userop succeeds, and its value is returned\n * (before the entire call is reverted)\n * Note that in order to collect the the success/failure of the target call, it must be executed\n * with trace enabled to track the emitted events.\n * @param op the UserOperation to simulate\n * @param target if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult\n * are set to the return from that call.\n * @param targetCallData callData to pass to target address\n */\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external;\n}\n\n" - }, - "contracts/interfaces/INonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\ninterface INonceManager {\n\n /**\n * Return the next nonce for this sender.\n * Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop)\n * But UserOp with different keys can come with arbitrary order.\n *\n * @param sender the account address\n * @param key the high 192 bit of the nonce\n * @return nonce a full nonce to pass for next UserOp with this sender.\n */\n function getNonce(address sender, uint192 key)\n external view returns (uint256 nonce);\n\n /**\n * Manually increment the nonce of the sender.\n * This method is exposed just for completeness..\n * Account does NOT need to call it, neither during validation, nor elsewhere,\n * as the EntryPoint will update the nonce regardless.\n * Possible use-case is call it with various keys to \"initialize\" their nonces to one, so that future\n * UserOperations will not pay extra for the first transaction with a given key.\n */\n function incrementNonce(uint192 key) external;\n}\n" - }, - "contracts/interfaces/IPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * the interface exposed by a paymaster contract, who agrees to pay the gas for user's operations.\n * a paymaster must hold a stake to cover the required entrypoint stake and also the gas for the transaction.\n */\ninterface IPaymaster {\n\n enum PostOpMode {\n opSucceeded, // user op succeeded\n opReverted, // user op reverted. still has to pay for gas.\n postOpReverted //user op succeeded, but caused postOp to revert. Now it's a 2nd call, after user's op was deliberately reverted.\n }\n\n /**\n * payment validation: check if paymaster agrees to pay.\n * Must verify sender is the entryPoint.\n * Revert to reject this request.\n * Note that bundlers will reject this method if it changes the state, unless the paymaster is trusted (whitelisted)\n * The paymaster pre-pays using its deposit, and receive back a refund after the postOp method returns.\n * @param userOp the user operation\n * @param userOpHash hash of the user's request data.\n * @param maxCost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\n * @return context value to send to a postOp\n * zero length to signify postOp is not required.\n * @return validationData signature and time-range of this operation, encoded the same as the return value of validateUserOperation\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n external returns (bytes memory context, uint256 validationData);\n\n /**\n * post-operation handler.\n * Must verify sender is the entryPoint\n * @param mode enum with the following options:\n * opSucceeded - user operation succeeded.\n * opReverted - user op reverted. still has to pay for gas.\n * postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n * Now this is the 2nd call, after user's op was deliberately reverted.\n * @param context - the context value returned by validatePaymasterUserOp\n * @param actualGasCost - actual gas used so far (without this postOp call).\n */\n function postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) external;\n}\n" - }, - "contracts/interfaces/IStakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by the staked entity.\n */\ninterface IStakeManager {\n\n event Deposited(\n address indexed account,\n uint256 totalDeposit\n );\n\n event Withdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /// Emitted when stake or unstake delay are modified\n event StakeLocked(\n address indexed account,\n uint256 totalStaked,\n uint256 unstakeDelaySec\n );\n\n /// Emitted once a stake is scheduled for withdrawal\n event StakeUnlocked(\n address indexed account,\n uint256 withdrawTime\n );\n\n event StakeWithdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /**\n * @param deposit the entity's deposit\n * @param staked true if this entity is staked.\n * @param stake actual amount of ether staked for this entity.\n * @param unstakeDelaySec minimum delay to withdraw the stake.\n * @param withdrawTime - first block timestamp where 'withdrawStake' will be callable, or zero if already locked\n * @dev sizes were chosen so that (deposit,staked, stake) fit into one cell (used during handleOps)\n * and the rest fit into a 2nd cell.\n * 112 bit allows for 10^15 eth\n * 48 bit for full timestamp\n * 32 bit allows 150 years for unstake delay\n */\n struct DepositInfo {\n uint112 deposit;\n bool staked;\n uint112 stake;\n uint32 unstakeDelaySec;\n uint48 withdrawTime;\n }\n\n //API struct used by getStakeInfo and simulateValidation\n struct StakeInfo {\n uint256 stake;\n uint256 unstakeDelaySec;\n }\n\n /// @return info - full deposit information of given account\n function getDepositInfo(address account) external view returns (DepositInfo memory info);\n\n /// @return the deposit (for gas payment) of the account\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) external payable;\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param _unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 _unstakeDelaySec) external payable;\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external;\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external;\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external;\n}\n" - }, - "contracts/interfaces/UserOperation.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\nimport {calldataKeccak} from \"../core/Helpers.sol\";\n\n/**\n * User Operation struct\n * @param sender the sender account of this request.\n * @param nonce unique value the sender uses to verify it is not a replay.\n * @param initCode if set, the account contract will be created by this constructor/\n * @param callData the method call to execute on this account.\n * @param callGasLimit the gas limit passed to the callData method call.\n * @param verificationGasLimit gas used for validateUserOp and validatePaymasterUserOp.\n * @param preVerificationGas gas not calculated by the handleOps method, but added to the gas paid. Covers batch overhead.\n * @param maxFeePerGas same as EIP-1559 gas parameter.\n * @param maxPriorityFeePerGas same as EIP-1559 gas parameter.\n * @param paymasterAndData if set, this field holds the paymaster address and paymaster-specific data. the paymaster will pay for the transaction instead of the sender.\n * @param signature sender-verified signature over the entire request, the EntryPoint address and the chain ID.\n */\n struct UserOperation {\n\n address sender;\n uint256 nonce;\n bytes initCode;\n bytes callData;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n bytes paymasterAndData;\n bytes signature;\n }\n\n/**\n * Utility functions helpful when working with UserOperation structs.\n */\nlibrary UserOperationLib {\n\n function getSender(UserOperation calldata userOp) internal pure returns (address) {\n address data;\n //read sender from userOp, which is first userOp member (saves 800 gas...)\n assembly {data := calldataload(userOp)}\n return address(uint160(data));\n }\n\n //relayer/block builder might submit the TX with higher priorityFee, but the user should not\n // pay above what he signed for.\n function gasPrice(UserOperation calldata userOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n address sender = getSender(userOp);\n uint256 nonce = userOp.nonce;\n bytes32 hashInitCode = calldataKeccak(userOp.initCode);\n bytes32 hashCallData = calldataKeccak(userOp.callData);\n uint256 callGasLimit = userOp.callGasLimit;\n uint256 verificationGasLimit = userOp.verificationGasLimit;\n uint256 preVerificationGas = userOp.preVerificationGas;\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes32 hashPaymasterAndData = calldataKeccak(userOp.paymasterAndData);\n\n return abi.encode(\n sender, nonce,\n hashInitCode, hashCallData,\n callGasLimit, verificationGasLimit, preVerificationGas,\n maxFeePerGas, maxPriorityFeePerGas,\n hashPaymasterAndData\n );\n }\n\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\n return keccak256(pack(userOp));\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n}\n" - }, - "contracts/utils/Exec.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.5 <0.9.0;\n\n// solhint-disable no-inline-assembly\n\n/**\n * Utility functions helpful when making different kinds of contract calls in Solidity.\n */\nlibrary Exec {\n\n function call(\n address to,\n uint256 value,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function staticcall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal view returns (bool success) {\n assembly {\n success := staticcall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function delegateCall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n // get returned data from last call or calldelegate\n function getReturnData(uint256 maxLen) internal pure returns (bytes memory returnData) {\n assembly {\n let len := returndatasize()\n if gt(len, maxLen) {\n len := maxLen\n }\n let ptr := mload(0x40)\n mstore(0x40, add(ptr, add(len, 0x20)))\n mstore(ptr, len)\n returndatacopy(add(ptr, 0x20), 0, len)\n returnData := ptr\n }\n }\n\n // revert with explicit byte array (probably reverted info from call)\n function revertWithData(bytes memory returnData) internal pure {\n assembly {\n revert(add(returnData, 32), mload(returnData))\n }\n }\n\n function callAndRevert(address to, bytes memory data, uint256 maxLen) internal {\n bool success = call(to,0,data,gasleft());\n if (!success) {\n revertWithData(getReturnData(maxLen));\n }\n }\n}\n" - } - }, - "settings": { - "optimizer": { - "enabled": true, - "runs": 1000000 - }, - "viaIR": true, - "outputSelection": { - "*": { - "*": [ - "abi", - "evm.bytecode", - "evm.deployedBytecode", - "evm.methodIdentifiers", - "metadata" - ], - "": [ - "ast" - ] - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/goerli/.chainId b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/goerli/.chainId deleted file mode 100644 index 7813681f5b..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/goerli/.chainId +++ /dev/null @@ -1 +0,0 @@ -5 \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/goerli/EntryPoint.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/goerli/EntryPoint.json deleted file mode 100644 index 916c239083..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/goerli/EntryPoint.json +++ /dev/null @@ -1,1318 +0,0 @@ -{ - "address": "0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789", - "abi": [ - { - "inputs": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "paid", - "type": "uint256" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bool", - "name": "targetSuccess", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "targetResult", - "type": "bytes" - } - ], - "name": "ExecutionResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "opIndex", - "type": "uint256" - }, - { - "internalType": "string", - "name": "reason", - "type": "string" - } - ], - "name": "FailedOp", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - } - ], - "name": "SenderAddressResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureValidationFailed", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - } - ], - "name": "ValidationResult", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "stakeInfo", - "type": "tuple" - } - ], - "internalType": "struct IEntryPoint.AggregatorStakeInfo", - "name": "aggregatorInfo", - "type": "tuple" - } - ], - "name": "ValidationResultWithAggregation", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "factory", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "paymaster", - "type": "address" - } - ], - "name": "AccountDeployed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [], - "name": "BeforeExecution", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalDeposit", - "type": "uint256" - } - ], - "name": "Deposited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureAggregatorChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalStaked", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "name": "StakeLocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "withdrawTime", - "type": "uint256" - } - ], - "name": "StakeUnlocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "StakeWithdrawn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasUsed", - "type": "uint256" - } - ], - "name": "UserOperationEvent", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "revertReason", - "type": "bytes" - } - ], - "name": "UserOperationRevertReason", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "Withdrawn", - "type": "event" - }, - { - "inputs": [], - "name": "SIG_VALIDATION_FAILED", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - } - ], - "name": "_validateSenderAndPaymaster", - "outputs": [], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - } - ], - "name": "addStake", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "depositTo", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "deposits", - "outputs": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "getDepositInfo", - "outputs": [ - { - "components": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "internalType": "struct IStakeManager.DepositInfo", - "name": "info", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "getNonce", - "outputs": [ - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - } - ], - "name": "getSenderAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "getUserOpHash", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "userOps", - "type": "tuple[]" - }, - { - "internalType": "contract IAggregator", - "name": "aggregator", - "type": "address" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.UserOpsPerAggregator[]", - "name": "opsPerAggregator", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleAggregatedOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "ops", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "incrementNonce", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.MemoryUserOp", - "name": "mUserOp", - "type": "tuple" - }, - { - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "contextOffset", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.UserOpInfo", - "name": "opInfo", - "type": "tuple" - }, - { - "internalType": "bytes", - "name": "context", - "type": "bytes" - } - ], - "name": "innerHandleOp", - "outputs": [ - { - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - }, - { - "internalType": "uint192", - "name": "", - "type": "uint192" - } - ], - "name": "nonceSequenceNumber", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "op", - "type": "tuple" - }, - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "targetCallData", - "type": "bytes" - } - ], - "name": "simulateHandleOp", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "simulateValidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unlockStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - } - ], - "name": "withdrawStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "withdrawAmount", - "type": "uint256" - } - ], - "name": "withdrawTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "args": [], - "numDeployments": 1, - "solcInputHash": "a4c52f0671aad8941c53d6ead2063803", - "metadata": "{\"compiler\":{\"version\":\"0.8.17+commit.8df45f5f\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"paid\",\"type\":\"uint256\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bool\",\"name\":\"targetSuccess\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"targetResult\",\"type\":\"bytes\"}],\"name\":\"ExecutionResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"opIndex\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\"}],\"name\":\"FailedOp\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderAddressResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureValidationFailed\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResult\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"stakeInfo\",\"type\":\"tuple\"}],\"internalType\":\"struct IEntryPoint.AggregatorStakeInfo\",\"name\":\"aggregatorInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResultWithAggregation\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"factory\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"}],\"name\":\"AccountDeployed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"BeforeExecution\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalDeposit\",\"type\":\"uint256\"}],\"name\":\"Deposited\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureAggregatorChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalStaked\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"name\":\"StakeLocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"withdrawTime\",\"type\":\"uint256\"}],\"name\":\"StakeUnlocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"StakeWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasUsed\",\"type\":\"uint256\"}],\"name\":\"UserOperationEvent\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"revertReason\",\"type\":\"bytes\"}],\"name\":\"UserOperationRevertReason\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Withdrawn\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"SIG_VALIDATION_FAILED\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"}],\"name\":\"_validateSenderAndPaymaster\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"}],\"name\":\"addStake\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"depositTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"deposits\",\"outputs\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getDepositInfo\",\"outputs\":[{\"components\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"internalType\":\"struct IStakeManager.DepositInfo\",\"name\":\"info\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"}],\"name\":\"getSenderAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"getUserOpHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"userOps\",\"type\":\"tuple[]\"},{\"internalType\":\"contract IAggregator\",\"name\":\"aggregator\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.UserOpsPerAggregator[]\",\"name\":\"opsPerAggregator\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleAggregatedOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"ops\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"incrementNonce\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.MemoryUserOp\",\"name\":\"mUserOp\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"contextOffset\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.UserOpInfo\",\"name\":\"opInfo\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"context\",\"type\":\"bytes\"}],\"name\":\"innerHandleOp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"\",\"type\":\"uint192\"}],\"name\":\"nonceSequenceNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"op\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"targetCallData\",\"type\":\"bytes\"}],\"name\":\"simulateHandleOp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"simulateValidation\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unlockStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"}],\"name\":\"withdrawStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"withdrawAmount\",\"type\":\"uint256\"}],\"name\":\"withdrawTo\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"errors\":{\"FailedOp(uint256,string)\":[{\"params\":{\"opIndex\":\"- index into the array of ops to the failed one (in simulateValidation, this is always zero)\",\"reason\":\"- revert reason The string starts with a unique code \\\"AAmn\\\", where \\\"m\\\" is \\\"1\\\" for factory, \\\"2\\\" for account and \\\"3\\\" for paymaster issues, so a failure can be attributed to the correct entity. Should be caught in off-chain handleOps simulation and not happen on-chain. Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\"}}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"params\":{\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"params\":{\"aggregatorInfo\":\"signature aggregation info (if the account requires signature aggregator) bundler MUST use it to verify the signature, or reject the UserOperation\",\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}]},\"kind\":\"dev\",\"methods\":{\"addStake(uint32)\":{\"params\":{\"unstakeDelaySec\":\"the new lock duration before the deposit can be withdrawn.\"}},\"getDepositInfo(address)\":{\"returns\":{\"info\":\"- full deposit information of given account\"}},\"getNonce(address,uint192)\":{\"params\":{\"key\":\"the high 192 bit of the nonce\",\"sender\":\"the account address\"},\"returns\":{\"nonce\":\"a full nonce to pass for next UserOp with this sender.\"}},\"getSenderAddress(bytes)\":{\"params\":{\"initCode\":\"the constructor code to be passed into the UserOperation.\"}},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"opsPerAggregator\":\"the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\"}},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"ops\":\"the operations to execute\"}},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"params\":{\"op\":\"the UserOperation to simulate\",\"target\":\"if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult are set to the return from that call.\",\"targetCallData\":\"callData to pass to target address\"}},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"details\":\"this method always revert. Successful result is ValidationResult error. other errors are failures.The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\",\"params\":{\"userOp\":\"the user operation to validate.\"}},\"withdrawStake(address)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\"}},\"withdrawTo(address,uint256)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\",\"withdrawAmount\":\"the amount to withdraw.\"}}},\"version\":1},\"userdoc\":{\"errors\":{\"ExecutionResult(uint256,uint256,uint48,uint48,bool,bytes)\":[{\"notice\":\"return value of simulateHandleOp\"}],\"FailedOp(uint256,string)\":[{\"notice\":\"a custom revert error of handleOps, to identify the offending op. NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\"}],\"SenderAddressResult(address)\":[{\"notice\":\"return value of getSenderAddress\"}],\"SignatureValidationFailed(address)\":[{\"notice\":\"error case when a signature aggregator fails to verify the aggregated signature it had created.\"}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"notice\":\"Successful result from simulateValidation.\"}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"notice\":\"Successful result from simulateValidation, if the account returns a signature aggregator\"}]},\"events\":{\"AccountDeployed(bytes32,address,address,address)\":{\"notice\":\"account \\\"sender\\\" was deployed.\"},\"BeforeExecution()\":{\"notice\":\"an event emitted by handleOps(), before starting the execution loop. any event emitted before this event, is part of the validation.\"},\"SignatureAggregatorChanged(address)\":{\"notice\":\"signature aggregator used by the following UserOperationEvents within this bundle.\"},\"StakeLocked(address,uint256,uint256)\":{\"notice\":\"Emitted when stake or unstake delay are modified\"},\"StakeUnlocked(address,uint256)\":{\"notice\":\"Emitted once a stake is scheduled for withdrawal\"},\"UserOperationRevertReason(bytes32,address,uint256,bytes)\":{\"notice\":\"An event emitted if the UserOperation \\\"callData\\\" reverted with non-zero length\"}},\"kind\":\"user\",\"methods\":{\"SIG_VALIDATION_FAILED()\":{\"notice\":\"for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value in case of signature failure, instead of revert.\"},\"_validateSenderAndPaymaster(bytes,address,bytes)\":{\"notice\":\"Called only during simulation. This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\"},\"addStake(uint32)\":{\"notice\":\"add to the account's stake - amount and delay any pending unstake is first cancelled.\"},\"balanceOf(address)\":{\"notice\":\"return the deposit (for gas payment) of the account\"},\"depositTo(address)\":{\"notice\":\"add to the deposit of the given account\"},\"deposits(address)\":{\"notice\":\"maps paymaster to their deposits and stakes\"},\"getNonce(address,uint192)\":{\"notice\":\"Return the next nonce for this sender. Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop) But UserOp with different keys can come with arbitrary order.\"},\"getSenderAddress(bytes)\":{\"notice\":\"Get counterfactual sender address. Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation. this method always revert, and returns the address in SenderAddressResult error\"},\"getUserOpHash((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"generate a request Id - unique identifier for this request. the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\"},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperation with Aggregators\"},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperations. no signature aggregator is used. if any account requires an aggregator (that is, it returned an aggregator when performing simulateValidation), then handleAggregatedOps() must be used instead.\"},\"incrementNonce(uint192)\":{\"notice\":\"Manually increment the nonce of the sender. This method is exposed just for completeness.. Account does NOT need to call it, neither during validation, nor elsewhere, as the EntryPoint will update the nonce regardless. Possible use-case is call it with various keys to \\\"initialize\\\" their nonces to one, so that future UserOperations will not pay extra for the first transaction with a given key.\"},\"innerHandleOp(bytes,((address,uint256,uint256,uint256,uint256,address,uint256,uint256),bytes32,uint256,uint256,uint256),bytes)\":{\"notice\":\"inner function to handle a UserOperation. Must be declared \\\"external\\\" to open a call context, but it can only be called by handleOps.\"},\"nonceSequenceNumber(address,uint192)\":{\"notice\":\"The next valid sequence number for a given nonce key.\"},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"notice\":\"simulate full execution of a UserOperation (including both validation and target execution) this method will always revert with \\\"ExecutionResult\\\". it performs full validation of the UserOperation, but ignores signature error. an optional target address is called after the userop succeeds, and its value is returned (before the entire call is reverted) Note that in order to collect the the success/failure of the target call, it must be executed with trace enabled to track the emitted events.\"},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\"},\"unlockStake()\":{\"notice\":\"attempt to unlock the stake. the value can be withdrawn (using withdrawStake) after the unstake delay.\"},\"withdrawStake(address)\":{\"notice\":\"withdraw from the (unlocked) stake. must first call unlockStake and wait for the unstakeDelay to pass\"},\"withdrawTo(address,uint256)\":{\"notice\":\"withdraw from the deposit.\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/core/EntryPoint.sol\":\"EntryPoint\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":1000000},\"remappings\":[],\"viaIR\":true},\"sources\":{\"@openzeppelin/contracts/security/ReentrancyGuard.sol\":{\"keccak256\":\"0x190dd6f8d592b7e4e930feb7f4313aeb8e1c4ad3154c27ce1cf6a512fc30d8cc\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://4ce8dfb62d0c4fa260d6eec8f1cd47f5f2a044e11bde5b31d18072fa6e7d9010\",\"dweb:/ipfs/QmTyFztU3tLEcEDnqqiaW4UJetqsU77LXc6pjc9oTXCK5u\"]},\"contracts/core/EntryPoint.sol\":{\"keccak256\":\"0x04f86318b47f052d7308795ffae6ecec0d023d2458b4e17751b89a0e4acfcdc6\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://c9f6e359c8dbe875ad974d3a0fb7b3d62319a6b115c44bac1e4587ae2ad2edaf\",\"dweb:/ipfs/QmTSWTov2rUeYk8cwzrtsd3uVXokCYok4gMiZ1sPs9tycH\"]},\"contracts/core/Helpers.sol\":{\"keccak256\":\"0x591c87519f7155d1909210276b77925ab2722a99b7b5d5649aecc36ebbdb045a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://69643e83f68e6a13d5075c7565bfce326673b0bd98c432033c4603ea84835746\",\"dweb:/ipfs/QmSwSzjYyV7qudi5vvsmzHMG2Z4YJZxX51RRXXVCLaNcEU\"]},\"contracts/core/NonceManager.sol\":{\"keccak256\":\"0xa17a4a6fde70088ab18ffe6df830f3efa31f1cd0e1a7160336c96e3c94984d25\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://b38615df9f80c56282b72888e9ba1eb1a9413fa67a0dbf094deda7af9feb38e7\",\"dweb:/ipfs/QmSzcXetEJRH4UHuUmZiSgX6bFgfqHWfmyuxVnh4NosMk1\"]},\"contracts/core/SenderCreator.sol\":{\"keccak256\":\"0x44b9449fec82d6cdfb01d52fdd5a72f90099c651316123810cf9633f00b018c2\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a9c0487390e72638681d175c45bc92425c802fffdca4bd0ae8457782ee284612\",\"dweb:/ipfs/QmVbzuehCUWJWqEHyMWuc6cRVbxfcMdFsmGL9o4Wz7WY2x\"]},\"contracts/core/StakeManager.sol\":{\"keccak256\":\"0x21aa0956382bd000b1b8c3b1d19ca6ebcd6c9029eebb19c612fb38ee5dd2430a\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://0a625c8795354d9f429367f9c1d14eb8af7db9c7f2c2a2033e2066ced76a573a\",\"dweb:/ipfs/Qmd1j6UarUg54q1G2HCNCLQz8XGVZR1qxX7eQ6cytHpQPN\"]},\"contracts/interfaces/IAccount.sol\":{\"keccak256\":\"0x556a0e5980de18e90b115553ed502408155ba35f58642823010d9288047bc418\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a0f420134b79596db8737173c7b933ae0a33059e107b6327c43aa40d4744a9e4\",\"dweb:/ipfs/QmRo8s1AhXmEMV7uPYnbpYwU19e9Bk6jmYBJTiPx3Fo85W\"]},\"contracts/interfaces/IAggregator.sol\":{\"keccak256\":\"0x060e9ddb0152250c269ba0640dc5753834ac44cf182a2837d508c0c529cae26a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://20ed837bc5909c89ff1910246bf245a5dad6840aa939382e1694964eb7dbd37b\",\"dweb:/ipfs/QmTMybRq5yyghPDDs1ZCNAVB9sSJ4WHe6Q9mejuKPTAdNP\"]},\"contracts/interfaces/IEntryPoint.sol\":{\"keccak256\":\"0x3a90bf308819ed125fa4202f880999caff8a8686633b8ddb79a30ca240d5b8f8\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://d2d21cc92c2fdab2b58d21bc25d4cd0e8c284b922528a186b087b818d54bc6cf\",\"dweb:/ipfs/QmT1qrfuBjsv2rmRCDn8mgPXHp94hARJwzbcDuBLDTbFWd\"]},\"contracts/interfaces/INonceManager.sol\":{\"keccak256\":\"0x509871e6c63663cdcc3eba19920fe84e991f38b289b1377ac3c3a6d9f22d7e12\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://00fe21b4349b24c50df60e1a705179293982bd9e7a32b78d4bac9620f89e7fe2\",\"dweb:/ipfs/QmSFFYGfUwQbVa6hASjU7YxTvgi2HkfrPr4X5oPHscHg8b\"]},\"contracts/interfaces/IPaymaster.sol\":{\"keccak256\":\"0x36858ba8685024974f533530420688da3454d29996ebc42e410673a1ed2ec456\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://616cbcf51778b1961b7f20a547bec7efae6d1d565df0f651926241ed8bde9ad8\",\"dweb:/ipfs/QmaVsgffUUmeUJYgStvRr8cNZ1LBbrc3FYNLW4JT1dVLia\"]},\"contracts/interfaces/IStakeManager.sol\":{\"keccak256\":\"0xd227b02888cd4ac68daebcdfd992ec00f9fff66fa3b3bb16f656cd582fa3480f\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://b389da4714a138be63704a576a482505eab2855e263b38a93706395d8d42e7c3\",\"dweb:/ipfs/QmeeAZpdHwUXxqP8pxA7GNtoCGBmmH4FaqLLwScVKGxtxZ\"]},\"contracts/interfaces/UserOperation.sol\":{\"keccak256\":\"0x61374003361059087fdcf17967a7bba052badeaf5c7f0ae689166f8aafd3a45c\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://6ff83c59432e733bf6304dda27cd4b0f34401917dd535e2669cc842d2d26568c\",\"dweb:/ipfs/QmPJbHU5TAjHqUTZzAcicEeG2nknmwCN43L4EW9LHbknTN\"]},\"contracts/utils/Exec.sol\":{\"keccak256\":\"0x5b232117afbc2939f3ffc92745614867e9e1d475a3e1e5443adae13c200174f1\",\"license\":\"LGPL-3.0-only\",\"urls\":[\"bzz-raw://62e7365379a06ead7b47637945bcaee095d51aab1d3ac00ddec69443e6cbe9fe\",\"dweb:/ipfs/QmctG3aw4U3KMSMeJKoLJ1NJewjMWfppnd1m3kxNTe39Uy\"]}},\"version\":1}", - "bytecode": "0x60a080604052346200008957600160025561022c8181016001600160401b038111838210176200007357829162005d18833903906000f080156200006757608052604051615c8990816200008f82396080518181816113df01528181613e9501526141b60152f35b6040513d6000823e3d90fd5b634e487b7160e01b600052604160045260246000fd5b600080fdfe60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c634300081100336080806040523461001657610210908161001c8239f35b600080fdfe6080604052600436101561001257600080fd5b6000803560e01c63570e1a361461002857600080fd5b346100c95760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126100c95760043567ffffffffffffffff918282116100c957366023830112156100c95781600401359283116100c95736602484840101116100c9576100c561009e84602485016100fc565b60405173ffffffffffffffffffffffffffffffffffffffff90911681529081906020820190565b0390f35b80fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b90806014116101bb5767ffffffffffffffff917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec82018381116101cd575b604051937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f81600b8701160116850190858210908211176101c0575b604052808452602084019036848401116101bb576020946000600c819682946014880187378301015251923560601c5af19060005191156101b557565b60009150565b600080fd5b6101c86100cc565b610178565b6101d56100cc565b61013a56fea26469706673582212201927e80b76ab9b71c952137dd676621a9fdf520c25928815636594036eb1c40364736f6c63430008110033", - "deployedBytecode": "0x60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c63430008110033" -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/goerli/solcInputs/a4c52f0671aad8941c53d6ead2063803.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/goerli/solcInputs/a4c52f0671aad8941c53d6ead2063803.json deleted file mode 100644 index dd58ba5a3e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/goerli/solcInputs/a4c52f0671aad8941c53d6ead2063803.json +++ /dev/null @@ -1,68 +0,0 @@ -{ - "language": "Solidity", - "sources": { - "@openzeppelin/contracts/security/ReentrancyGuard.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (security/ReentrancyGuard.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Contract module that helps prevent reentrant calls to a function.\n *\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\n * available, which can be applied to functions to make sure there are no nested\n * (reentrant) calls to them.\n *\n * Note that because there is a single `nonReentrant` guard, functions marked as\n * `nonReentrant` may not call one another. This can be worked around by making\n * those functions `private`, and then adding `external` `nonReentrant` entry\n * points to them.\n *\n * TIP: If you would like to learn more about reentrancy and alternative ways\n * to protect against it, check out our blog post\n * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].\n */\nabstract contract ReentrancyGuard {\n // Booleans are more expensive than uint256 or any type that takes up a full\n // word because each write operation emits an extra SLOAD to first read the\n // slot's contents, replace the bits taken up by the boolean, and then write\n // back. This is the compiler's defense against contract upgrades and\n // pointer aliasing, and it cannot be disabled.\n\n // The values being non-zero value makes deployment a bit more expensive,\n // but in exchange the refund on every call to nonReentrant will be lower in\n // amount. Since refunds are capped to a percentage of the total\n // transaction's gas, it is best to keep them low in cases like this one, to\n // increase the likelihood of the full refund coming into effect.\n uint256 private constant _NOT_ENTERED = 1;\n uint256 private constant _ENTERED = 2;\n\n uint256 private _status;\n\n constructor() {\n _status = _NOT_ENTERED;\n }\n\n /**\n * @dev Prevents a contract from calling itself, directly or indirectly.\n * Calling a `nonReentrant` function from another `nonReentrant`\n * function is not supported. It is possible to prevent this from happening\n * by making the `nonReentrant` function external, and making it call a\n * `private` function that does the actual work.\n */\n modifier nonReentrant() {\n _nonReentrantBefore();\n _;\n _nonReentrantAfter();\n }\n\n function _nonReentrantBefore() private {\n // On the first call to nonReentrant, _status will be _NOT_ENTERED\n require(_status != _ENTERED, \"ReentrancyGuard: reentrant call\");\n\n // Any calls to nonReentrant after this point will fail\n _status = _ENTERED;\n }\n\n function _nonReentrantAfter() private {\n // By storing the original value once again, a refund is triggered (see\n // https://eips.ethereum.org/EIPS/eip-2200)\n _status = _NOT_ENTERED;\n }\n}\n" - }, - "contracts/core/EntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IPaymaster.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\n\nimport \"../utils/Exec.sol\";\nimport \"./StakeManager.sol\";\nimport \"./SenderCreator.sol\";\nimport \"./Helpers.sol\";\nimport \"./NonceManager.sol\";\nimport \"@openzeppelin/contracts/security/ReentrancyGuard.sol\";\n\ncontract EntryPoint is IEntryPoint, StakeManager, NonceManager, ReentrancyGuard {\n\n using UserOperationLib for UserOperation;\n\n SenderCreator private immutable senderCreator = new SenderCreator();\n\n // internal value used during simulation: need to query aggregator.\n address private constant SIMULATE_FIND_AGGREGATOR = address(1);\n\n // marker for inner call revert on out of gas\n bytes32 private constant INNER_OUT_OF_GAS = hex'deaddead';\n\n uint256 private constant REVERT_REASON_MAX_LEN = 2048;\n\n /**\n * for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value\n * in case of signature failure, instead of revert.\n */\n uint256 public constant SIG_VALIDATION_FAILED = 1;\n\n /**\n * compensate the caller's beneficiary address with the collected fees of all UserOperations.\n * @param beneficiary the address to receive the fees\n * @param amount amount to transfer.\n */\n function _compensate(address payable beneficiary, uint256 amount) internal {\n require(beneficiary != address(0), \"AA90 invalid beneficiary\");\n (bool success,) = beneficiary.call{value : amount}(\"\");\n require(success, \"AA91 failed send to beneficiary\");\n }\n\n /**\n * execute a user op\n * @param opIndex index into the opInfo array\n * @param userOp the userOp to execute\n * @param opInfo the opInfo filled by validatePrepayment for this userOp.\n * @return collected the total amount this userOp paid.\n */\n function _executeUserOp(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory opInfo) private returns (uint256 collected) {\n uint256 preGas = gasleft();\n bytes memory context = getMemoryBytesFromOffset(opInfo.contextOffset);\n\n try this.innerHandleOp(userOp.callData, opInfo, context) returns (uint256 _actualGasCost) {\n collected = _actualGasCost;\n } catch {\n bytes32 innerRevertCode;\n assembly {\n returndatacopy(0, 0, 32)\n innerRevertCode := mload(0)\n }\n // handleOps was called with gas limit too low. abort entire bundle.\n if (innerRevertCode == INNER_OUT_OF_GAS) {\n //report paymaster, since if it is not deliberately caused by the bundler,\n // it must be a revert caused by paymaster.\n revert FailedOp(opIndex, \"AA95 out of gas\");\n }\n\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n collected = _handlePostOp(opIndex, IPaymaster.PostOpMode.postOpReverted, opInfo, context, actualGas);\n }\n }\n\n /**\n * Execute a batch of UserOperations.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) public nonReentrant {\n\n uint256 opslen = ops.length;\n UserOpInfo[] memory opInfos = new UserOpInfo[](opslen);\n\n unchecked {\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[i];\n (uint256 validationData, uint256 pmValidationData) = _validatePrepayment(i, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, pmValidationData, address(0));\n }\n\n uint256 collected = 0;\n emit BeforeExecution();\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(i, ops[i], opInfos[i]);\n }\n\n _compensate(beneficiary, collected);\n } //unchecked\n }\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) public nonReentrant {\n\n uint256 opasLen = opsPerAggregator.length;\n uint256 totalOps = 0;\n for (uint256 i = 0; i < opasLen; i++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[i];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n //address(1) is special marker of \"signature error\"\n require(address(aggregator) != address(1), \"AA96 invalid aggregator\");\n\n if (address(aggregator) != address(0)) {\n // solhint-disable-next-line no-empty-blocks\n try aggregator.validateSignatures(ops, opa.signature) {}\n catch {\n revert SignatureValidationFailed(address(aggregator));\n }\n }\n\n totalOps += ops.length;\n }\n\n UserOpInfo[] memory opInfos = new UserOpInfo[](totalOps);\n\n emit BeforeExecution();\n\n uint256 opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n uint256 opslen = ops.length;\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[opIndex];\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(opIndex, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, paymasterValidationData, address(aggregator));\n opIndex++;\n }\n }\n\n uint256 collected = 0;\n opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n emit SignatureAggregatorChanged(address(opa.aggregator));\n UserOperation[] calldata ops = opa.userOps;\n uint256 opslen = ops.length;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(opIndex, ops[i], opInfos[opIndex]);\n opIndex++;\n }\n }\n emit SignatureAggregatorChanged(address(0));\n\n _compensate(beneficiary, collected);\n }\n\n /// @inheritdoc IEntryPoint\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external override {\n\n UserOpInfo memory opInfo;\n _simulationOnlyValidations(op);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, op, opInfo);\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n\n numberMarker();\n uint256 paid = _executeUserOp(0, op, opInfo);\n numberMarker();\n bool targetSuccess;\n bytes memory targetResult;\n if (target != address(0)) {\n (targetSuccess, targetResult) = target.call(targetCallData);\n }\n revert ExecutionResult(opInfo.preOpGas, paid, data.validAfter, data.validUntil, targetSuccess, targetResult);\n }\n\n\n // A memory copy of UserOp static fields only.\n // Excluding: callData, initCode and signature. Replacing paymasterAndData with paymaster.\n struct MemoryUserOp {\n address sender;\n uint256 nonce;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n address paymaster;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n }\n\n struct UserOpInfo {\n MemoryUserOp mUserOp;\n bytes32 userOpHash;\n uint256 prefund;\n uint256 contextOffset;\n uint256 preOpGas;\n }\n\n /**\n * inner function to handle a UserOperation.\n * Must be declared \"external\" to open a call context, but it can only be called by handleOps.\n */\n function innerHandleOp(bytes memory callData, UserOpInfo memory opInfo, bytes calldata context) external returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n require(msg.sender == address(this), \"AA92 internal call only\");\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n\n uint callGasLimit = mUserOp.callGasLimit;\n unchecked {\n // handleOps was called with gas limit too low. abort entire bundle.\n if (gasleft() < callGasLimit + mUserOp.verificationGasLimit + 5000) {\n assembly {\n mstore(0, INNER_OUT_OF_GAS)\n revert(0, 32)\n }\n }\n }\n\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\n if (callData.length > 0) {\n bool success = Exec.call(mUserOp.sender, 0, callData, callGasLimit);\n if (!success) {\n bytes memory result = Exec.getReturnData(REVERT_REASON_MAX_LEN);\n if (result.length > 0) {\n emit UserOperationRevertReason(opInfo.userOpHash, mUserOp.sender, mUserOp.nonce, result);\n }\n mode = IPaymaster.PostOpMode.opReverted;\n }\n }\n\n unchecked {\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n //note: opIndex is ignored (relevant only if mode==postOpReverted, which is only possible outside of innerHandleOp)\n return _handlePostOp(0, mode, opInfo, context, actualGas);\n }\n }\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) public view returns (bytes32) {\n return keccak256(abi.encode(userOp.hash(), address(this), block.chainid));\n }\n\n /**\n * copy general fields from userOp into the memory opInfo structure.\n */\n function _copyUserOpToMemory(UserOperation calldata userOp, MemoryUserOp memory mUserOp) internal pure {\n mUserOp.sender = userOp.sender;\n mUserOp.nonce = userOp.nonce;\n mUserOp.callGasLimit = userOp.callGasLimit;\n mUserOp.verificationGasLimit = userOp.verificationGasLimit;\n mUserOp.preVerificationGas = userOp.preVerificationGas;\n mUserOp.maxFeePerGas = userOp.maxFeePerGas;\n mUserOp.maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes calldata paymasterAndData = userOp.paymasterAndData;\n if (paymasterAndData.length > 0) {\n require(paymasterAndData.length >= 20, \"AA93 invalid paymasterAndData\");\n mUserOp.paymaster = address(bytes20(paymasterAndData[: 20]));\n } else {\n mUserOp.paymaster = address(0);\n }\n }\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external {\n UserOpInfo memory outOpInfo;\n\n _simulationOnlyValidations(userOp);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, userOp, outOpInfo);\n StakeInfo memory paymasterInfo = _getStakeInfo(outOpInfo.mUserOp.paymaster);\n StakeInfo memory senderInfo = _getStakeInfo(outOpInfo.mUserOp.sender);\n StakeInfo memory factoryInfo;\n {\n bytes calldata initCode = userOp.initCode;\n address factory = initCode.length >= 20 ? address(bytes20(initCode[0 : 20])) : address(0);\n factoryInfo = _getStakeInfo(factory);\n }\n\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n address aggregator = data.aggregator;\n bool sigFailed = aggregator == address(1);\n ReturnInfo memory returnInfo = ReturnInfo(outOpInfo.preOpGas, outOpInfo.prefund,\n sigFailed, data.validAfter, data.validUntil, getMemoryBytesFromOffset(outOpInfo.contextOffset));\n\n if (aggregator != address(0) && aggregator != address(1)) {\n AggregatorStakeInfo memory aggregatorInfo = AggregatorStakeInfo(aggregator, _getStakeInfo(aggregator));\n revert ValidationResultWithAggregation(returnInfo, senderInfo, factoryInfo, paymasterInfo, aggregatorInfo);\n }\n revert ValidationResult(returnInfo, senderInfo, factoryInfo, paymasterInfo);\n\n }\n\n function _getRequiredPrefund(MemoryUserOp memory mUserOp) internal pure returns (uint256 requiredPrefund) {\n unchecked {\n //when using a Paymaster, the verificationGasLimit is used also to as a limit for the postOp call.\n // our security model might call postOp eventually twice\n uint256 mul = mUserOp.paymaster != address(0) ? 3 : 1;\n uint256 requiredGas = mUserOp.callGasLimit + mUserOp.verificationGasLimit * mul + mUserOp.preVerificationGas;\n\n requiredPrefund = requiredGas * mUserOp.maxFeePerGas;\n }\n }\n\n // create the sender's contract if needed.\n function _createSenderIfNeeded(uint256 opIndex, UserOpInfo memory opInfo, bytes calldata initCode) internal {\n if (initCode.length != 0) {\n address sender = opInfo.mUserOp.sender;\n if (sender.code.length != 0) revert FailedOp(opIndex, \"AA10 sender already constructed\");\n address sender1 = senderCreator.createSender{gas : opInfo.mUserOp.verificationGasLimit}(initCode);\n if (sender1 == address(0)) revert FailedOp(opIndex, \"AA13 initCode failed or OOG\");\n if (sender1 != sender) revert FailedOp(opIndex, \"AA14 initCode must return sender\");\n if (sender1.code.length == 0) revert FailedOp(opIndex, \"AA15 initCode must create sender\");\n address factory = address(bytes20(initCode[0 : 20]));\n emit AccountDeployed(opInfo.userOpHash, sender, factory, opInfo.mUserOp.paymaster);\n }\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes calldata initCode) public {\n address sender = senderCreator.createSender(initCode);\n revert SenderAddressResult(sender);\n }\n\n function _simulationOnlyValidations(UserOperation calldata userOp) internal view {\n // solhint-disable-next-line no-empty-blocks\n try this._validateSenderAndPaymaster(userOp.initCode, userOp.sender, userOp.paymasterAndData) {}\n catch Error(string memory revertReason) {\n if (bytes(revertReason).length != 0) {\n revert FailedOp(0, revertReason);\n }\n }\n }\n\n /**\n * Called only during simulation.\n * This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\n */\n function _validateSenderAndPaymaster(bytes calldata initCode, address sender, bytes calldata paymasterAndData) external view {\n if (initCode.length == 0 && sender.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA20 account not deployed\");\n }\n if (paymasterAndData.length >= 20) {\n address paymaster = address(bytes20(paymasterAndData[0 : 20]));\n if (paymaster.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA30 paymaster not deployed\");\n }\n }\n // always revert\n revert(\"\");\n }\n\n /**\n * call account.validateUserOp.\n * revert (with FailedOp) in case validateUserOp reverts, or account didn't send required prefund.\n * decrement account's deposit if needed\n */\n function _validateAccountPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPrefund)\n internal returns (uint256 gasUsedByValidateAccountPrepayment, uint256 validationData) {\n unchecked {\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n address sender = mUserOp.sender;\n _createSenderIfNeeded(opIndex, opInfo, op.initCode);\n address paymaster = mUserOp.paymaster;\n numberMarker();\n uint256 missingAccountFunds = 0;\n if (paymaster == address(0)) {\n uint256 bal = balanceOf(sender);\n missingAccountFunds = bal > requiredPrefund ? 0 : requiredPrefund - bal;\n }\n try IAccount(sender).validateUserOp{gas : mUserOp.verificationGasLimit}(op, opInfo.userOpHash, missingAccountFunds)\n returns (uint256 _validationData) {\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA23 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA23 reverted (or OOG)\");\n }\n if (paymaster == address(0)) {\n DepositInfo storage senderInfo = deposits[sender];\n uint256 deposit = senderInfo.deposit;\n if (requiredPrefund > deposit) {\n revert FailedOp(opIndex, \"AA21 didn't pay prefund\");\n }\n senderInfo.deposit = uint112(deposit - requiredPrefund);\n }\n gasUsedByValidateAccountPrepayment = preGas - gasleft();\n }\n }\n\n /**\n * In case the request has a paymaster:\n * Validate paymaster has enough deposit.\n * Call paymaster.validatePaymasterUserOp.\n * Revert with proper FailedOp in case paymaster reverts.\n * Decrement paymaster's deposit\n */\n function _validatePaymasterPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPreFund, uint256 gasUsedByValidateAccountPrepayment)\n internal returns (bytes memory context, uint256 validationData) {\n unchecked {\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 verificationGasLimit = mUserOp.verificationGasLimit;\n require(verificationGasLimit > gasUsedByValidateAccountPrepayment, \"AA41 too little verificationGas\");\n uint256 gas = verificationGasLimit - gasUsedByValidateAccountPrepayment;\n\n address paymaster = mUserOp.paymaster;\n DepositInfo storage paymasterInfo = deposits[paymaster];\n uint256 deposit = paymasterInfo.deposit;\n if (deposit < requiredPreFund) {\n revert FailedOp(opIndex, \"AA31 paymaster deposit too low\");\n }\n paymasterInfo.deposit = uint112(deposit - requiredPreFund);\n try IPaymaster(paymaster).validatePaymasterUserOp{gas : gas}(op, opInfo.userOpHash, requiredPreFund) returns (bytes memory _context, uint256 _validationData){\n context = _context;\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA33 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA33 reverted (or OOG)\");\n }\n }\n }\n\n /**\n * revert if either account validationData or paymaster validationData is expired\n */\n function _validateAccountAndPaymasterValidationData(uint256 opIndex, uint256 validationData, uint256 paymasterValidationData, address expectedAggregator) internal view {\n (address aggregator, bool outOfTimeRange) = _getValidationData(validationData);\n if (expectedAggregator != aggregator) {\n revert FailedOp(opIndex, \"AA24 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA22 expired or not due\");\n }\n //pmAggregator is not a real signature aggregator: we don't have logic to handle it as address.\n // non-zero address means that the paymaster fails due to some signature check (which is ok only during estimation)\n address pmAggregator;\n (pmAggregator, outOfTimeRange) = _getValidationData(paymasterValidationData);\n if (pmAggregator != address(0)) {\n revert FailedOp(opIndex, \"AA34 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA32 paymaster expired or not due\");\n }\n }\n\n function _getValidationData(uint256 validationData) internal view returns (address aggregator, bool outOfTimeRange) {\n if (validationData == 0) {\n return (address(0), false);\n }\n ValidationData memory data = _parseValidationData(validationData);\n // solhint-disable-next-line not-rely-on-time\n outOfTimeRange = block.timestamp > data.validUntil || block.timestamp < data.validAfter;\n aggregator = data.aggregator;\n }\n\n /**\n * validate account and paymaster (if defined).\n * also make sure total validation doesn't exceed verificationGasLimit\n * this method is called off-chain (simulateValidation()) and on-chain (from handleOps)\n * @param opIndex the index of this userOp into the \"opInfos\" array\n * @param userOp the userOp to validate\n */\n function _validatePrepayment(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory outOpInfo)\n private returns (uint256 validationData, uint256 paymasterValidationData) {\n\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = outOpInfo.mUserOp;\n _copyUserOpToMemory(userOp, mUserOp);\n outOpInfo.userOpHash = getUserOpHash(userOp);\n\n // validate all numeric values in userOp are well below 128 bit, so they can safely be added\n // and multiplied without causing overflow\n uint256 maxGasValues = mUserOp.preVerificationGas | mUserOp.verificationGasLimit | mUserOp.callGasLimit |\n userOp.maxFeePerGas | userOp.maxPriorityFeePerGas;\n require(maxGasValues <= type(uint120).max, \"AA94 gas values overflow\");\n\n uint256 gasUsedByValidateAccountPrepayment;\n (uint256 requiredPreFund) = _getRequiredPrefund(mUserOp);\n (gasUsedByValidateAccountPrepayment, validationData) = _validateAccountPrepayment(opIndex, userOp, outOpInfo, requiredPreFund);\n\n if (!_validateAndUpdateNonce(mUserOp.sender, mUserOp.nonce)) {\n revert FailedOp(opIndex, \"AA25 invalid account nonce\");\n }\n\n //a \"marker\" where account opcode validation is done and paymaster opcode validation is about to start\n // (used only by off-chain simulateValidation)\n numberMarker();\n\n bytes memory context;\n if (mUserOp.paymaster != address(0)) {\n (context, paymasterValidationData) = _validatePaymasterPrepayment(opIndex, userOp, outOpInfo, requiredPreFund, gasUsedByValidateAccountPrepayment);\n }\n unchecked {\n uint256 gasUsed = preGas - gasleft();\n\n if (userOp.verificationGasLimit < gasUsed) {\n revert FailedOp(opIndex, \"AA40 over verificationGasLimit\");\n }\n outOpInfo.prefund = requiredPreFund;\n outOpInfo.contextOffset = getOffsetOfMemoryBytes(context);\n outOpInfo.preOpGas = preGas - gasleft() + userOp.preVerificationGas;\n }\n }\n\n /**\n * process post-operation.\n * called just after the callData is executed.\n * if a paymaster is defined and its validation returned a non-empty context, its postOp is called.\n * the excess amount is refunded to the account (or paymaster - if it was used in the request)\n * @param opIndex index in the batch\n * @param mode - whether is called from innerHandleOp, or outside (postOpReverted)\n * @param opInfo userOp fields and info collected during validation\n * @param context the context returned in validatePaymasterUserOp\n * @param actualGas the gas used so far by this user operation\n */\n function _handlePostOp(uint256 opIndex, IPaymaster.PostOpMode mode, UserOpInfo memory opInfo, bytes memory context, uint256 actualGas) private returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n unchecked {\n address refundAddress;\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 gasPrice = getUserOpGasPrice(mUserOp);\n\n address paymaster = mUserOp.paymaster;\n if (paymaster == address(0)) {\n refundAddress = mUserOp.sender;\n } else {\n refundAddress = paymaster;\n if (context.length > 0) {\n actualGasCost = actualGas * gasPrice;\n if (mode != IPaymaster.PostOpMode.postOpReverted) {\n IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost);\n } else {\n // solhint-disable-next-line no-empty-blocks\n try IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost) {}\n catch Error(string memory reason) {\n revert FailedOp(opIndex, string.concat(\"AA50 postOp reverted: \", reason));\n }\n catch {\n revert FailedOp(opIndex, \"AA50 postOp revert\");\n }\n }\n }\n }\n actualGas += preGas - gasleft();\n actualGasCost = actualGas * gasPrice;\n if (opInfo.prefund < actualGasCost) {\n revert FailedOp(opIndex, \"AA51 prefund below actualGasCost\");\n }\n uint256 refund = opInfo.prefund - actualGasCost;\n _incrementDeposit(refundAddress, refund);\n bool success = mode == IPaymaster.PostOpMode.opSucceeded;\n emit UserOperationEvent(opInfo.userOpHash, mUserOp.sender, mUserOp.paymaster, mUserOp.nonce, success, actualGasCost, actualGas);\n } // unchecked\n }\n\n /**\n * the gas price this UserOp agrees to pay.\n * relayer/block builder might submit the TX with higher priorityFee, but the user should not\n */\n function getUserOpGasPrice(MemoryUserOp memory mUserOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = mUserOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = mUserOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n\n function getOffsetOfMemoryBytes(bytes memory data) internal pure returns (uint256 offset) {\n assembly {offset := data}\n }\n\n function getMemoryBytesFromOffset(uint256 offset) internal pure returns (bytes memory data) {\n assembly {data := offset}\n }\n\n //place the NUMBER opcode in the code.\n // this is used as a marker during simulation, as this OP is completely banned from the simulated code of the\n // account and paymaster.\n function numberMarker() internal view {\n assembly {mstore(0, number())}\n }\n}\n\n" - }, - "contracts/core/Helpers.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\n/**\n * returned data from validateUserOp.\n * validateUserOp returns a uint256, with is created by `_packedValidationData` and parsed by `_parseValidationData`\n * @param aggregator - address(0) - the account validated the signature by itself.\n * address(1) - the account failed to validate the signature.\n * otherwise - this is an address of a signature aggregator that must be used to validate the signature.\n * @param validAfter - this UserOp is valid only after this timestamp.\n * @param validaUntil - this UserOp is valid only up to this timestamp.\n */\n struct ValidationData {\n address aggregator;\n uint48 validAfter;\n uint48 validUntil;\n }\n\n//extract sigFailed, validAfter, validUntil.\n// also convert zero validUntil to type(uint48).max\n function _parseValidationData(uint validationData) pure returns (ValidationData memory data) {\n address aggregator = address(uint160(validationData));\n uint48 validUntil = uint48(validationData >> 160);\n if (validUntil == 0) {\n validUntil = type(uint48).max;\n }\n uint48 validAfter = uint48(validationData >> (48 + 160));\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n// intersect account and paymaster ranges.\n function _intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) pure returns (ValidationData memory) {\n ValidationData memory accountValidationData = _parseValidationData(validationData);\n ValidationData memory pmValidationData = _parseValidationData(paymasterValidationData);\n address aggregator = accountValidationData.aggregator;\n if (aggregator == address(0)) {\n aggregator = pmValidationData.aggregator;\n }\n uint48 validAfter = accountValidationData.validAfter;\n uint48 validUntil = accountValidationData.validUntil;\n uint48 pmValidAfter = pmValidationData.validAfter;\n uint48 pmValidUntil = pmValidationData.validUntil;\n\n if (validAfter < pmValidAfter) validAfter = pmValidAfter;\n if (validUntil > pmValidUntil) validUntil = pmValidUntil;\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n/**\n * helper to pack the return value for validateUserOp\n * @param data - the ValidationData to pack\n */\n function _packValidationData(ValidationData memory data) pure returns (uint256) {\n return uint160(data.aggregator) | (uint256(data.validUntil) << 160) | (uint256(data.validAfter) << (160 + 48));\n }\n\n/**\n * helper to pack the return value for validateUserOp, when not using an aggregator\n * @param sigFailed - true for signature failure, false for success\n * @param validUntil last timestamp this UserOperation is valid (or zero for infinite)\n * @param validAfter first timestamp this UserOperation is valid\n */\n function _packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) pure returns (uint256) {\n return (sigFailed ? 1 : 0) | (uint256(validUntil) << 160) | (uint256(validAfter) << (160 + 48));\n }\n\n/**\n * keccak function over calldata.\n * @dev copy calldata into memory, do keccak and drop allocated memory. Strangely, this is more efficient than letting solidity do it.\n */\n function calldataKeccak(bytes calldata data) pure returns (bytes32 ret) {\n assembly {\n let mem := mload(0x40)\n let len := data.length\n calldatacopy(mem, data.offset, len)\n ret := keccak256(mem, len)\n }\n }\n\n" - }, - "contracts/core/NonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IEntryPoint.sol\";\n\n/**\n * nonce management functionality\n */\ncontract NonceManager is INonceManager {\n\n /**\n * The next valid sequence number for a given nonce key.\n */\n mapping(address => mapping(uint192 => uint256)) public nonceSequenceNumber;\n\n function getNonce(address sender, uint192 key)\n public view override returns (uint256 nonce) {\n return nonceSequenceNumber[sender][key] | (uint256(key) << 64);\n }\n\n // allow an account to manually increment its own nonce.\n // (mainly so that during construction nonce can be made non-zero,\n // to \"absorb\" the gas cost of first nonce increment to 1st transaction (construction),\n // not to 2nd transaction)\n function incrementNonce(uint192 key) public override {\n nonceSequenceNumber[msg.sender][key]++;\n }\n\n /**\n * validate nonce uniqueness for this account.\n * called just after validateUserOp()\n */\n function _validateAndUpdateNonce(address sender, uint256 nonce) internal returns (bool) {\n\n uint192 key = uint192(nonce >> 64);\n uint64 seq = uint64(nonce);\n return nonceSequenceNumber[sender][key]++ == seq;\n }\n\n}\n" - }, - "contracts/core/SenderCreator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * helper contract for EntryPoint, to call userOp.initCode from a \"neutral\" address,\n * which is explicitly not the entryPoint itself.\n */\ncontract SenderCreator {\n\n /**\n * call the \"initCode\" factory to create and return the sender account address\n * @param initCode the initCode value from a UserOp. contains 20 bytes of factory address, followed by calldata\n * @return sender the returned address of the created account, or zero address on failure.\n */\n function createSender(bytes calldata initCode) external returns (address sender) {\n address factory = address(bytes20(initCode[0 : 20]));\n bytes memory initCallData = initCode[20 :];\n bool success;\n /* solhint-disable no-inline-assembly */\n assembly {\n success := call(gas(), factory, 0, add(initCallData, 0x20), mload(initCallData), 0, 32)\n sender := mload(0)\n }\n if (!success) {\n sender = address(0);\n }\n }\n}\n" - }, - "contracts/core/StakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IStakeManager.sol\";\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable not-rely-on-time */\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by a paymaster.\n */\nabstract contract StakeManager is IStakeManager {\n\n /// maps paymaster to their deposits and stakes\n mapping(address => DepositInfo) public deposits;\n\n /// @inheritdoc IStakeManager\n function getDepositInfo(address account) public view returns (DepositInfo memory info) {\n return deposits[account];\n }\n\n // internal method to return just the stake info\n function _getStakeInfo(address addr) internal view returns (StakeInfo memory info) {\n DepositInfo storage depositInfo = deposits[addr];\n info.stake = depositInfo.stake;\n info.unstakeDelaySec = depositInfo.unstakeDelaySec;\n }\n\n /// return the deposit (for gas payment) of the account\n function balanceOf(address account) public view returns (uint256) {\n return deposits[account].deposit;\n }\n\n receive() external payable {\n depositTo(msg.sender);\n }\n\n function _incrementDeposit(address account, uint256 amount) internal {\n DepositInfo storage info = deposits[account];\n uint256 newAmount = info.deposit + amount;\n require(newAmount <= type(uint112).max, \"deposit overflow\");\n info.deposit = uint112(newAmount);\n }\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) public payable {\n _incrementDeposit(account, msg.value);\n DepositInfo storage info = deposits[account];\n emit Deposited(account, info.deposit);\n }\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 unstakeDelaySec) public payable {\n DepositInfo storage info = deposits[msg.sender];\n require(unstakeDelaySec > 0, \"must specify unstake delay\");\n require(unstakeDelaySec >= info.unstakeDelaySec, \"cannot decrease unstake time\");\n uint256 stake = info.stake + msg.value;\n require(stake > 0, \"no stake specified\");\n require(stake <= type(uint112).max, \"stake overflow\");\n deposits[msg.sender] = DepositInfo(\n info.deposit,\n true,\n uint112(stake),\n unstakeDelaySec,\n 0\n );\n emit StakeLocked(msg.sender, stake, unstakeDelaySec);\n }\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external {\n DepositInfo storage info = deposits[msg.sender];\n require(info.unstakeDelaySec != 0, \"not staked\");\n require(info.staked, \"already unstaking\");\n uint48 withdrawTime = uint48(block.timestamp) + info.unstakeDelaySec;\n info.withdrawTime = withdrawTime;\n info.staked = false;\n emit StakeUnlocked(msg.sender, withdrawTime);\n }\n\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external {\n DepositInfo storage info = deposits[msg.sender];\n uint256 stake = info.stake;\n require(stake > 0, \"No stake to withdraw\");\n require(info.withdrawTime > 0, \"must call unlockStake() first\");\n require(info.withdrawTime <= block.timestamp, \"Stake withdrawal is not due\");\n info.unstakeDelaySec = 0;\n info.withdrawTime = 0;\n info.stake = 0;\n emit StakeWithdrawn(msg.sender, withdrawAddress, stake);\n (bool success,) = withdrawAddress.call{value : stake}(\"\");\n require(success, \"failed to withdraw stake\");\n }\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external {\n DepositInfo storage info = deposits[msg.sender];\n require(withdrawAmount <= info.deposit, \"Withdraw amount too large\");\n info.deposit = uint112(info.deposit - withdrawAmount);\n emit Withdrawn(msg.sender, withdrawAddress, withdrawAmount);\n (bool success,) = withdrawAddress.call{value : withdrawAmount}(\"\");\n require(success, \"failed to withdraw\");\n }\n}\n" - }, - "contracts/interfaces/IAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\ninterface IAccount {\n\n /**\n * Validate user's signature and nonce\n * the entryPoint will make the call to the recipient only if this validation call returns successfully.\n * signature failure should be reported by returning SIG_VALIDATION_FAILED (1).\n * This allows making a \"simulation call\" without a valid signature\n * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure.\n *\n * @dev Must validate caller is the entryPoint.\n * Must validate the signature and nonce\n * @param userOp the operation that is about to be executed.\n * @param userOpHash hash of the user's request data. can be used as the basis for signature.\n * @param missingAccountFunds missing funds on the account's deposit in the entrypoint.\n * This is the minimum amount to transfer to the sender(entryPoint) to be able to make the call.\n * The excess is left as a deposit in the entrypoint, for future calls.\n * can be withdrawn anytime using \"entryPoint.withdrawTo()\"\n * In case there is a paymaster in the request (or the current deposit is high enough), this value will be zero.\n * @return validationData packaged ValidationData structure. use `_packValidationData` and `_unpackValidationData` to encode and decode\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * If an account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external returns (uint256 validationData);\n}\n" - }, - "contracts/interfaces/IAggregator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * Aggregated Signatures validator.\n */\ninterface IAggregator {\n\n /**\n * validate aggregated signature.\n * revert if the aggregated signature does not match the given list of operations.\n */\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external view;\n\n /**\n * validate signature of a single userOp\n * This method is should be called by bundler after EntryPoint.simulateValidation() returns (reverts) with ValidationResultWithAggregation\n * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps.\n * @param userOp the userOperation received from the user.\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\n * (usually empty, unless account and aggregator support some kind of \"multisig\"\n */\n function validateUserOpSignature(UserOperation calldata userOp)\n external view returns (bytes memory sigForUserOp);\n\n /**\n * aggregate multiple signatures into a single value.\n * This method is called off-chain to calculate the signature to pass with handleOps()\n * bundler MAY use optimized custom code perform this aggregation\n * @param userOps array of UserOperations to collect the signatures from.\n * @return aggregatedSignature the aggregated signature\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external view returns (bytes memory aggregatedSignature);\n}\n" - }, - "contracts/interfaces/IEntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"./UserOperation.sol\";\nimport \"./IStakeManager.sol\";\nimport \"./IAggregator.sol\";\nimport \"./INonceManager.sol\";\n\ninterface IEntryPoint is IStakeManager, INonceManager {\n\n /***\n * An event emitted after each successful request\n * @param userOpHash - unique identifier for the request (hash its entire content, except signature).\n * @param sender - the account that generates this request.\n * @param paymaster - if non-null, the paymaster that pays for this request.\n * @param nonce - the nonce value from the request.\n * @param success - true if the sender transaction succeeded, false if reverted.\n * @param actualGasCost - actual amount paid (by account or paymaster) for this UserOperation.\n * @param actualGasUsed - total gas used by this UserOperation (including preVerification, creation, validation and execution).\n */\n event UserOperationEvent(bytes32 indexed userOpHash, address indexed sender, address indexed paymaster, uint256 nonce, bool success, uint256 actualGasCost, uint256 actualGasUsed);\n\n /**\n * account \"sender\" was deployed.\n * @param userOpHash the userOp that deployed this account. UserOperationEvent will follow.\n * @param sender the account that is deployed\n * @param factory the factory used to deploy this account (in the initCode)\n * @param paymaster the paymaster used by this UserOp\n */\n event AccountDeployed(bytes32 indexed userOpHash, address indexed sender, address factory, address paymaster);\n\n /**\n * An event emitted if the UserOperation \"callData\" reverted with non-zero length\n * @param userOpHash the request unique identifier.\n * @param sender the sender of this request\n * @param nonce the nonce used in the request\n * @param revertReason - the return bytes from the (reverted) call to \"callData\".\n */\n event UserOperationRevertReason(bytes32 indexed userOpHash, address indexed sender, uint256 nonce, bytes revertReason);\n\n /**\n * an event emitted by handleOps(), before starting the execution loop.\n * any event emitted before this event, is part of the validation.\n */\n event BeforeExecution();\n\n /**\n * signature aggregator used by the following UserOperationEvents within this bundle.\n */\n event SignatureAggregatorChanged(address indexed aggregator);\n\n /**\n * a custom revert error of handleOps, to identify the offending op.\n * NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\n * @param opIndex - index into the array of ops to the failed one (in simulateValidation, this is always zero)\n * @param reason - revert reason\n * The string starts with a unique code \"AAmn\", where \"m\" is \"1\" for factory, \"2\" for account and \"3\" for paymaster issues,\n * so a failure can be attributed to the correct entity.\n * Should be caught in off-chain handleOps simulation and not happen on-chain.\n * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\n */\n error FailedOp(uint256 opIndex, string reason);\n\n /**\n * error case when a signature aggregator fails to verify the aggregated signature it had created.\n */\n error SignatureValidationFailed(address aggregator);\n\n /**\n * Successful result from simulateValidation.\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n */\n error ValidationResult(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo);\n\n /**\n * Successful result from simulateValidation, if the account returns a signature aggregator\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n * @param aggregatorInfo signature aggregation info (if the account requires signature aggregator)\n * bundler MUST use it to verify the signature, or reject the UserOperation\n */\n error ValidationResultWithAggregation(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo,\n AggregatorStakeInfo aggregatorInfo);\n\n /**\n * return value of getSenderAddress\n */\n error SenderAddressResult(address sender);\n\n /**\n * return value of simulateHandleOp\n */\n error ExecutionResult(uint256 preOpGas, uint256 paid, uint48 validAfter, uint48 validUntil, bool targetSuccess, bytes targetResult);\n\n //UserOps handled, per aggregator\n struct UserOpsPerAggregator {\n UserOperation[] userOps;\n\n // aggregator address\n IAggregator aggregator;\n // aggregated signature\n bytes signature;\n }\n\n /**\n * Execute a batch of UserOperation.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) external;\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) external;\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) external view returns (bytes32);\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external;\n\n /**\n * gas and return values during simulation\n * @param preOpGas the gas used for validation (including preValidationGas)\n * @param prefund the required prefund for this operation\n * @param sigFailed validateUserOp's (or paymaster's) signature check failed\n * @param validAfter - first timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param validUntil - last timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param paymasterContext returned by validatePaymasterUserOp (to be passed into postOp)\n */\n struct ReturnInfo {\n uint256 preOpGas;\n uint256 prefund;\n bool sigFailed;\n uint48 validAfter;\n uint48 validUntil;\n bytes paymasterContext;\n }\n\n /**\n * returned aggregated signature info.\n * the aggregator returned by the account, and its current stake.\n */\n struct AggregatorStakeInfo {\n address aggregator;\n StakeInfo stakeInfo;\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes memory initCode) external;\n\n\n /**\n * simulate full execution of a UserOperation (including both validation and target execution)\n * this method will always revert with \"ExecutionResult\".\n * it performs full validation of the UserOperation, but ignores signature error.\n * an optional target address is called after the userop succeeds, and its value is returned\n * (before the entire call is reverted)\n * Note that in order to collect the the success/failure of the target call, it must be executed\n * with trace enabled to track the emitted events.\n * @param op the UserOperation to simulate\n * @param target if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult\n * are set to the return from that call.\n * @param targetCallData callData to pass to target address\n */\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external;\n}\n\n" - }, - "contracts/interfaces/INonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\ninterface INonceManager {\n\n /**\n * Return the next nonce for this sender.\n * Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop)\n * But UserOp with different keys can come with arbitrary order.\n *\n * @param sender the account address\n * @param key the high 192 bit of the nonce\n * @return nonce a full nonce to pass for next UserOp with this sender.\n */\n function getNonce(address sender, uint192 key)\n external view returns (uint256 nonce);\n\n /**\n * Manually increment the nonce of the sender.\n * This method is exposed just for completeness..\n * Account does NOT need to call it, neither during validation, nor elsewhere,\n * as the EntryPoint will update the nonce regardless.\n * Possible use-case is call it with various keys to \"initialize\" their nonces to one, so that future\n * UserOperations will not pay extra for the first transaction with a given key.\n */\n function incrementNonce(uint192 key) external;\n}\n" - }, - "contracts/interfaces/IPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * the interface exposed by a paymaster contract, who agrees to pay the gas for user's operations.\n * a paymaster must hold a stake to cover the required entrypoint stake and also the gas for the transaction.\n */\ninterface IPaymaster {\n\n enum PostOpMode {\n opSucceeded, // user op succeeded\n opReverted, // user op reverted. still has to pay for gas.\n postOpReverted //user op succeeded, but caused postOp to revert. Now it's a 2nd call, after user's op was deliberately reverted.\n }\n\n /**\n * payment validation: check if paymaster agrees to pay.\n * Must verify sender is the entryPoint.\n * Revert to reject this request.\n * Note that bundlers will reject this method if it changes the state, unless the paymaster is trusted (whitelisted)\n * The paymaster pre-pays using its deposit, and receive back a refund after the postOp method returns.\n * @param userOp the user operation\n * @param userOpHash hash of the user's request data.\n * @param maxCost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\n * @return context value to send to a postOp\n * zero length to signify postOp is not required.\n * @return validationData signature and time-range of this operation, encoded the same as the return value of validateUserOperation\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n external returns (bytes memory context, uint256 validationData);\n\n /**\n * post-operation handler.\n * Must verify sender is the entryPoint\n * @param mode enum with the following options:\n * opSucceeded - user operation succeeded.\n * opReverted - user op reverted. still has to pay for gas.\n * postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n * Now this is the 2nd call, after user's op was deliberately reverted.\n * @param context - the context value returned by validatePaymasterUserOp\n * @param actualGasCost - actual gas used so far (without this postOp call).\n */\n function postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) external;\n}\n" - }, - "contracts/interfaces/IStakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by the staked entity.\n */\ninterface IStakeManager {\n\n event Deposited(\n address indexed account,\n uint256 totalDeposit\n );\n\n event Withdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /// Emitted when stake or unstake delay are modified\n event StakeLocked(\n address indexed account,\n uint256 totalStaked,\n uint256 unstakeDelaySec\n );\n\n /// Emitted once a stake is scheduled for withdrawal\n event StakeUnlocked(\n address indexed account,\n uint256 withdrawTime\n );\n\n event StakeWithdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /**\n * @param deposit the entity's deposit\n * @param staked true if this entity is staked.\n * @param stake actual amount of ether staked for this entity.\n * @param unstakeDelaySec minimum delay to withdraw the stake.\n * @param withdrawTime - first block timestamp where 'withdrawStake' will be callable, or zero if already locked\n * @dev sizes were chosen so that (deposit,staked, stake) fit into one cell (used during handleOps)\n * and the rest fit into a 2nd cell.\n * 112 bit allows for 10^15 eth\n * 48 bit for full timestamp\n * 32 bit allows 150 years for unstake delay\n */\n struct DepositInfo {\n uint112 deposit;\n bool staked;\n uint112 stake;\n uint32 unstakeDelaySec;\n uint48 withdrawTime;\n }\n\n //API struct used by getStakeInfo and simulateValidation\n struct StakeInfo {\n uint256 stake;\n uint256 unstakeDelaySec;\n }\n\n /// @return info - full deposit information of given account\n function getDepositInfo(address account) external view returns (DepositInfo memory info);\n\n /// @return the deposit (for gas payment) of the account\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) external payable;\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param _unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 _unstakeDelaySec) external payable;\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external;\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external;\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external;\n}\n" - }, - "contracts/interfaces/UserOperation.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\nimport {calldataKeccak} from \"../core/Helpers.sol\";\n\n/**\n * User Operation struct\n * @param sender the sender account of this request.\n * @param nonce unique value the sender uses to verify it is not a replay.\n * @param initCode if set, the account contract will be created by this constructor/\n * @param callData the method call to execute on this account.\n * @param callGasLimit the gas limit passed to the callData method call.\n * @param verificationGasLimit gas used for validateUserOp and validatePaymasterUserOp.\n * @param preVerificationGas gas not calculated by the handleOps method, but added to the gas paid. Covers batch overhead.\n * @param maxFeePerGas same as EIP-1559 gas parameter.\n * @param maxPriorityFeePerGas same as EIP-1559 gas parameter.\n * @param paymasterAndData if set, this field holds the paymaster address and paymaster-specific data. the paymaster will pay for the transaction instead of the sender.\n * @param signature sender-verified signature over the entire request, the EntryPoint address and the chain ID.\n */\n struct UserOperation {\n\n address sender;\n uint256 nonce;\n bytes initCode;\n bytes callData;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n bytes paymasterAndData;\n bytes signature;\n }\n\n/**\n * Utility functions helpful when working with UserOperation structs.\n */\nlibrary UserOperationLib {\n\n function getSender(UserOperation calldata userOp) internal pure returns (address) {\n address data;\n //read sender from userOp, which is first userOp member (saves 800 gas...)\n assembly {data := calldataload(userOp)}\n return address(uint160(data));\n }\n\n //relayer/block builder might submit the TX with higher priorityFee, but the user should not\n // pay above what he signed for.\n function gasPrice(UserOperation calldata userOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n address sender = getSender(userOp);\n uint256 nonce = userOp.nonce;\n bytes32 hashInitCode = calldataKeccak(userOp.initCode);\n bytes32 hashCallData = calldataKeccak(userOp.callData);\n uint256 callGasLimit = userOp.callGasLimit;\n uint256 verificationGasLimit = userOp.verificationGasLimit;\n uint256 preVerificationGas = userOp.preVerificationGas;\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes32 hashPaymasterAndData = calldataKeccak(userOp.paymasterAndData);\n\n return abi.encode(\n sender, nonce,\n hashInitCode, hashCallData,\n callGasLimit, verificationGasLimit, preVerificationGas,\n maxFeePerGas, maxPriorityFeePerGas,\n hashPaymasterAndData\n );\n }\n\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\n return keccak256(pack(userOp));\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n}\n" - }, - "contracts/utils/Exec.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.5 <0.9.0;\n\n// solhint-disable no-inline-assembly\n\n/**\n * Utility functions helpful when making different kinds of contract calls in Solidity.\n */\nlibrary Exec {\n\n function call(\n address to,\n uint256 value,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function staticcall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal view returns (bool success) {\n assembly {\n success := staticcall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function delegateCall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n // get returned data from last call or calldelegate\n function getReturnData(uint256 maxLen) internal pure returns (bytes memory returnData) {\n assembly {\n let len := returndatasize()\n if gt(len, maxLen) {\n len := maxLen\n }\n let ptr := mload(0x40)\n mstore(0x40, add(ptr, add(len, 0x20)))\n mstore(ptr, len)\n returndatacopy(add(ptr, 0x20), 0, len)\n returnData := ptr\n }\n }\n\n // revert with explicit byte array (probably reverted info from call)\n function revertWithData(bytes memory returnData) internal pure {\n assembly {\n revert(add(returnData, 32), mload(returnData))\n }\n }\n\n function callAndRevert(address to, bytes memory data, uint256 maxLen) internal {\n bool success = call(to,0,data,gasleft());\n if (!success) {\n revertWithData(getReturnData(maxLen));\n }\n }\n}\n" - } - }, - "settings": { - "optimizer": { - "enabled": true, - "runs": 1000000 - }, - "viaIR": true, - "outputSelection": { - "*": { - "*": [ - "abi", - "evm.bytecode", - "evm.deployedBytecode", - "evm.methodIdentifiers", - "metadata" - ], - "": [ - "ast" - ] - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/.chainId b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/.chainId deleted file mode 100644 index f70d7bba4a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/.chainId +++ /dev/null @@ -1 +0,0 @@ -42 \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/EntryPoint.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/EntryPoint.json deleted file mode 100644 index 00ddccecc0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/EntryPoint.json +++ /dev/null @@ -1,1073 +0,0 @@ -{ - "address": "0xF63621e54F16eC6e4A732e44EaA7708935f259eF", - "abi": [ - { - "inputs": [ - { - "internalType": "address", - "name": "_create2factory", - "type": "address" - }, - { - "internalType": "uint256", - "name": "_perOpOverhead", - "type": "uint256" - }, - { - "internalType": "uint32", - "name": "_unstakeDelayBlocks", - "type": "uint32" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "opIndex", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "string", - "name": "reason", - "type": "string" - } - ], - "name": "FailedOp", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "reason", - "type": "bytes" - } - ], - "name": "PaymasterPostOpFailed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalStake", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "unstakeDelayBlocks", - "type": "uint256" - } - ], - "name": "StakeAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "withdrawBlock", - "type": "uint256" - } - ], - "name": "StakeUnlocking", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "StakeWithdrawn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasPrice", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bool", - "name": "success", - "type": "bool" - } - ], - "name": "UserOperationEvent", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "revertReason", - "type": "bytes" - } - ], - "name": "UserOperationRevertReason", - "type": "event" - }, - { - "inputs": [], - "name": "addDeposit", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "target", - "type": "address" - } - ], - "name": "addDepositTo", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint32", - "name": "_unstakeDelayBlocks", - "type": "uint32" - } - ], - "name": "addStake", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [], - "name": "create2factory", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address[]", - "name": "paymasters", - "type": "address[]" - } - ], - "name": "getPaymastersStake", - "outputs": [ - { - "internalType": "uint256[]", - "name": "_stakes", - "type": "uint256[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "_salt", - "type": "uint256" - } - ], - "name": "getSenderAddress", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "paymaster", - "type": "address" - } - ], - "name": "getStakeInfo", - "outputs": [ - { - "components": [ - { - "internalType": "uint96", - "name": "stake", - "type": "uint96" - }, - { - "internalType": "uint32", - "name": "unstakeDelayBlocks", - "type": "uint32" - }, - { - "internalType": "uint96", - "name": "withdrawStake", - "type": "uint96" - }, - { - "internalType": "uint32", - "name": "withdrawBlock", - "type": "uint32" - } - ], - "internalType": "struct StakeManager.StakeInfo", - "name": "stakeInfo", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "op", - "type": "tuple" - }, - { - "internalType": "address payable", - "name": "redeemer", - "type": "address" - } - ], - "name": "handleOp", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "ops", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "redeemer", - "type": "address" - } - ], - "name": "handleOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "op", - "type": "tuple" - }, - { - "internalType": "bytes", - "name": "context", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "enum EntryPoint.PaymentMode", - "name": "paymentMode", - "type": "uint8" - } - ], - "name": "internalHandleOp", - "outputs": [ - { - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "addr", - "type": "address" - } - ], - "name": "isContractDeployed", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - } - ], - "name": "isPaymasterStaked", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "uint256", - "name": "requiredStake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "requiredDelayBlocks", - "type": "uint256" - } - ], - "name": "isStaked", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "perOpOverhead", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "gasUsedByPayForSelfOp", - "type": "uint256" - } - ], - "name": "simulatePaymasterValidation", - "outputs": [ - { - "internalType": "bytes", - "name": "context", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "gasUsedByPayForOp", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "simulateWalletValidation", - "outputs": [ - { - "internalType": "uint256", - "name": "gasUsedByPayForSelfOp", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "stakes", - "outputs": [ - { - "internalType": "uint96", - "name": "stake", - "type": "uint96" - }, - { - "internalType": "uint32", - "name": "unstakeDelayBlocks", - "type": "uint32" - }, - { - "internalType": "uint96", - "name": "withdrawStake", - "type": "uint96" - }, - { - "internalType": "uint32", - "name": "withdrawBlock", - "type": "uint32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "unlockStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unstakeDelayBlocks", - "outputs": [ - { - "internalType": "uint32", - "name": "", - "type": "uint32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - } - ], - "name": "withdrawStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "args": [ - "0xce0042B868300000d44A59004Da54A005ffdcf9f", - 22000, - 100 - ], - "solcInputHash": "9255faacf3ae4e81db1326413027bfa0", - "metadata": "{\"compiler\":{\"version\":\"0.8.7+commit.e28d00a7\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_create2factory\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_perOpOverhead\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_unstakeDelayBlocks\",\"type\":\"uint32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"opIndex\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\"}],\"name\":\"FailedOp\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"PaymasterPostOpFailed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalStake\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"unstakeDelayBlocks\",\"type\":\"uint256\"}],\"name\":\"StakeAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"withdrawBlock\",\"type\":\"uint256\"}],\"name\":\"StakeUnlocking\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"StakeWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasPrice\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"UserOperationEvent\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"revertReason\",\"type\":\"bytes\"}],\"name\":\"UserOperationRevertReason\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"addDeposit\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"addDepositTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"_unstakeDelayBlocks\",\"type\":\"uint32\"}],\"name\":\"addStake\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"create2factory\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"paymasters\",\"type\":\"address[]\"}],\"name\":\"getPaymastersStake\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"_stakes\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"_salt\",\"type\":\"uint256\"}],\"name\":\"getSenderAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"}],\"name\":\"getStakeInfo\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"stake\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelayBlocks\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"withdrawStake\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"withdrawBlock\",\"type\":\"uint32\"}],\"internalType\":\"struct StakeManager.StakeInfo\",\"name\":\"stakeInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"op\",\"type\":\"tuple\"},{\"internalType\":\"address payable\",\"name\":\"redeemer\",\"type\":\"address\"}],\"name\":\"handleOp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"ops\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"redeemer\",\"type\":\"address\"}],\"name\":\"handleOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"op\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"context\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"enum EntryPoint.PaymentMode\",\"name\":\"paymentMode\",\"type\":\"uint8\"}],\"name\":\"internalHandleOp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"isContractDeployed\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"}],\"name\":\"isPaymasterStaked\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requiredStake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requiredDelayBlocks\",\"type\":\"uint256\"}],\"name\":\"isStaked\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"perOpOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"},{\"internalType\":\"uint256\",\"name\":\"gasUsedByPayForSelfOp\",\"type\":\"uint256\"}],\"name\":\"simulatePaymasterValidation\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"context\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"gasUsedByPayForOp\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"simulateWalletValidation\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"gasUsedByPayForSelfOp\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"stakes\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"stake\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelayBlocks\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"withdrawStake\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"withdrawBlock\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unlockStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unstakeDelayBlocks\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"}],\"name\":\"withdrawStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{\"handleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,address,bytes,bytes),address)\":{\"params\":{\"op\":\"the operation to execute\",\"redeemer\":\"the contract to redeem the fee\"}},\"simulatePaymasterValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,address,bytes,bytes),uint256)\":{\"params\":{\"gasUsedByPayForSelfOp\":\"- the gas returned by simulateWalletValidation, as these 2 calls should share the same userOp.validationGas quota. The node must also verify it doesn't use banned opcode, and that it doesn't reference storage outside the paymaster's data\",\"userOp\":\"the user operation to validate.\"}},\"simulateWalletValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,address,bytes,bytes))\":{\"returns\":{\"gasUsedByPayForSelfOp\":\"- gas used by the validation, to pass into simulatePaymasterValidation. The node must also verify it doesn't use banned opcode, and that it doesn't reference storage outside the wallet's data\"}}},\"version\":1},\"userdoc\":{\"events\":{\"StakeUnlocking(address,uint256)\":{\"notice\":\"Emitted once a stake is scheduled for withdrawal\"}},\"kind\":\"user\",\"methods\":{\"addDeposit()\":{\"notice\":\"add a deposit (just like stake, but with lock=0 cancel any pending unlock\"},\"addStake(uint32)\":{\"notice\":\"add stake value for this paymaster. cancel any pending unlock\"},\"handleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,address,bytes,bytes),address)\":{\"notice\":\"Execute the given UserOperation.\"},\"simulatePaymasterValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,address,bytes,bytes),uint256)\":{\"notice\":\"Simulate a call to paymaster.verifyPaymasterUserOp do nothing if has no paymaster.\"},\"simulateWalletValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,address,bytes,bytes))\":{\"notice\":\"Simulate a call for wallet.verifyUserOp. Call must not revert.\"},\"stakes(address)\":{\"notice\":\"maps relay managers to their stakes\"},\"unstakeDelayBlocks()\":{\"notice\":\"minimum number of blocks to after 'unlock' before amount can be withdrawn.\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/EntryPoint.sol\":\"EntryPoint\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\",\"useLiteralContent\":true},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"contracts/EntryPoint.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.7;\\n\\nimport \\\"./StakeManager.sol\\\";\\nimport \\\"./UserOperation.sol\\\";\\nimport \\\"./IWallet.sol\\\";\\nimport \\\"./IPaymaster.sol\\\";\\n\\ninterface ICreate2Deployer {\\n function deploy(bytes memory _initCode, bytes32 _salt) external returns (address);\\n}\\n\\ncontract EntryPoint is StakeManager {\\n\\n using UserOperationLib for UserOperation;\\n // paymaster locked stake\\n // (actual stake should be higher, to cover actual call cost)\\n uint256 constant PAYMASTER_STAKE = 1 ether;\\n\\n enum PaymentMode {\\n paymasterStake, // if paymaster is set, use paymaster's stake to pay.\\n walletStake, // wallet has enough stake to pay for request.\\n walletEth // wallet has no stake. paying with eth.\\n }\\n\\n uint public immutable perOpOverhead;\\n address public immutable create2factory;\\n\\n event UserOperationEvent(address indexed sender, address indexed paymaster, uint nonce, uint actualGasCost, uint actualGasPrice, bool success);\\n event UserOperationRevertReason(address indexed sender, uint nonce, bytes revertReason);\\n\\n event PaymasterPostOpFailed(address indexed sender, address indexed paymaster, uint nonce, bytes reason);\\n\\n //handleOps reverts with this error struct, to mark the offending op\\n // NOTE: if simulateOp passes successfully, there should be no reason for handleOps to fail on it.\\n // @param opIndex - index into the array of ops to the failed one (in simulateOp, this is always zero)\\n // @param paymaster - if paymaster.verifyPaymasterUserOp fails, this will be the paymaster's address. if verifyUserOp failed,\\n // this value will be zero (since it failed before accessing the paymaster)\\n // @param reason - revert reason\\n // only to aid troubleshooting of wallet/paymaster reverts\\n error FailedOp(uint opIndex, address paymaster, string reason);\\n\\n constructor(address _create2factory, uint _perOpOverhead, uint32 _unstakeDelayBlocks) StakeManager(_unstakeDelayBlocks) {\\n create2factory = _create2factory;\\n perOpOverhead = _perOpOverhead;\\n }\\n\\n receive() external payable {}\\n\\n /**\\n * Execute the given UserOperation.\\n * @param op the operation to execute\\n * @param redeemer the contract to redeem the fee\\n */\\n function handleOp(UserOperation calldata op, address payable redeemer) public {\\n\\n uint preGas = gasleft();\\n\\n (uint256 prefund, PaymentMode paymentMode, bytes memory context) = _validatePrepayment(0, op);\\n uint preOpGas = preGas - gasleft() + perOpOverhead;\\n\\n uint actualGasCost;\\n\\n try this.internalHandleOp(op, context, preOpGas, prefund, paymentMode) returns (uint _actualGasCost) {\\n actualGasCost = _actualGasCost;\\n } catch {\\n uint actualGas = preGas - gasleft() + preOpGas;\\n actualGasCost = handlePostOp(IPaymaster.PostOpMode.postOpReverted, op, context, actualGas, prefund, paymentMode);\\n }\\n\\n redeem(redeemer, actualGasCost);\\n }\\n\\n function redeem(address payable redeemer, uint amount) internal {\\n redeemer.transfer(amount);\\n }\\n\\n function handleOps(UserOperation[] calldata ops, address payable redeemer) public {\\n\\n uint opslen = ops.length;\\n uint256[] memory preOpGas = new uint256[](opslen);\\n bytes32[] memory contexts = new bytes32[](opslen);\\n uint256[] memory prefunds = new uint256[](opslen);\\n PaymentMode[] memory paymentModes = new PaymentMode[](opslen);\\n\\n for (uint i = 0; i < opslen; i++) {\\n uint preGas = gasleft();\\n UserOperation calldata op = ops[i];\\n\\n bytes memory context;\\n bytes32 contextOffset;\\n (prefunds[i], paymentModes[i], context) = _validatePrepayment(i, op);\\n assembly {contextOffset := context}\\n contexts[i] = contextOffset;\\n preOpGas[i] = preGas - gasleft() + perOpOverhead;\\n }\\n\\n uint collected = 0;\\n\\n for (uint i = 0; i < ops.length; i++) {\\n uint preGas = gasleft();\\n UserOperation calldata op = ops[i];\\n bytes32 contextOffset = contexts[i];\\n bytes memory context;\\n assembly {context := contextOffset}\\n uint preOpGasi = preOpGas[i];\\n uint prefundi = prefunds[i];\\n PaymentMode paymentModei = paymentModes[i];\\n\\n try this.internalHandleOp(op, context, preOpGasi, prefundi, paymentModei) returns (uint _actualGasCost) {\\n collected += _actualGasCost;\\n } catch {\\n uint actualGas = preGas - gasleft() + preOpGasi;\\n collected += handlePostOp(IPaymaster.PostOpMode.postOpReverted, op, context, actualGas, prefundi, paymentModei);\\n }\\n }\\n\\n redeem(redeemer, collected);\\n }\\n\\n function internalHandleOp(UserOperation calldata op, bytes calldata context, uint preOpGas, uint prefund, PaymentMode paymentMode) external returns (uint actualGasCost) {\\n uint preGas = gasleft();\\n require(msg.sender == address(this));\\n\\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\\n if (op.callData.length > 0) {\\n\\n (bool success,bytes memory result) = address(op.getSender()).call{gas : op.callGas}(op.callData);\\n if (!success && result.length > 0) {\\n emit UserOperationRevertReason(op.getSender(), op.nonce, result);\\n mode = IPaymaster.PostOpMode.opReverted;\\n }\\n }\\n\\n uint actualGas = preGas - gasleft() + preOpGas;\\n return handlePostOp(mode, op, context, actualGas, prefund, paymentMode);\\n }\\n\\n /**\\n * Simulate a call for wallet.verifyUserOp.\\n * Call must not revert.\\n * @return gasUsedByPayForSelfOp - gas used by the validation, to pass into simulatePaymasterValidation.\\n * The node must also verify it doesn't use banned opcode, and that it doesn't reference storage outside the wallet's data\\n */\\n function simulateWalletValidation(UserOperation calldata userOp) external returns (uint gasUsedByPayForSelfOp){\\n require(msg.sender == address(0), \\\"must be called off-chain with from=zero-addr\\\");\\n (uint requiredPreFund, PaymentMode paymentMode) = getPaymentInfo(userOp);\\n (gasUsedByPayForSelfOp,) = _validateWalletPrepayment(0, userOp, requiredPreFund, paymentMode);\\n }\\n\\n function getPaymentInfo(UserOperation calldata userOp) internal view returns (uint requiredPrefund, PaymentMode paymentMode) {\\n requiredPrefund = userOp.requiredPreFund(perOpOverhead);\\n if (userOp.hasPaymaster()) {\\n paymentMode = PaymentMode.paymasterStake;\\n } else if (isStaked(userOp.getSender(), requiredPrefund, 0)) {\\n paymentMode = PaymentMode.walletStake;\\n } else {\\n paymentMode = PaymentMode.walletEth;\\n }\\n }\\n\\n /**\\n * Simulate a call to paymaster.verifyPaymasterUserOp\\n * do nothing if has no paymaster.\\n * @param userOp the user operation to validate.\\n * @param gasUsedByPayForSelfOp - the gas returned by simulateWalletValidation, as these 2 calls should share\\n * the same userOp.validationGas quota.\\n * The node must also verify it doesn't use banned opcode, and that it doesn't reference storage outside the paymaster's data\\n */\\n function simulatePaymasterValidation(UserOperation calldata userOp, uint gasUsedByPayForSelfOp) external view returns (bytes memory context, uint gasUsedByPayForOp){\\n (uint requiredPreFund, PaymentMode paymentMode) = getPaymentInfo(userOp);\\n if (paymentMode != PaymentMode.paymasterStake) {\\n return (\\\"\\\", 0);\\n }\\n return _validatePaymasterPrepayment(0, userOp, requiredPreFund, gasUsedByPayForSelfOp);\\n }\\n\\n // get the sender address, or use \\\"create2\\\" to create it.\\n // note that the gas allocation for this creation is deterministic (by the size of callData),\\n // so it is not checked on-chain, and adds to the gas used by verifyUserOp\\n function _createSenderIfNeeded(UserOperation calldata op) internal {\\n if (op.initCode.length != 0) {\\n //its a create operation. run the create2\\n // note that we're still under the gas limit of validate, so probably\\n // this create2 creates a proxy account.\\n // appending signer makes the request unique, so no one else can make this request.\\n //nonce is meaningless during create, so we re-purpose it as salt\\n address sender1 = ICreate2Deployer(create2factory).deploy(op.initCode, bytes32(op.nonce));\\n require(sender1 != address(0), \\\"create2 failed\\\");\\n require(sender1 == op.getSender(), \\\"sender doesn't match create2 address\\\");\\n }\\n }\\n\\n //get counterfactual sender address.\\n // use the initCode and salt in the UserOperation tot create this sender contract\\n function getSenderAddress(bytes memory initCode, uint _salt) public view returns (address) {\\n bytes32 hash = keccak256(\\n abi.encodePacked(\\n bytes1(0xff),\\n address(create2factory),\\n _salt,\\n keccak256(initCode)\\n )\\n );\\n\\n // NOTE: cast last 20 bytes of hash to address\\n return address(uint160(uint256(hash)));\\n }\\n\\n //call wallet.verifyUserOp, and validate that it paid as needed.\\n // return actual value sent from wallet to \\\"this\\\"\\n function _validateWalletPrepayment(uint opIndex, UserOperation calldata op, uint requiredPrefund, PaymentMode paymentMode) internal returns (uint gasUsedByPayForSelfOp, uint prefund) {\\n uint preGas = gasleft();\\n _createSenderIfNeeded(op);\\n uint preBalance = address(this).balance;\\n uint requiredEthPrefund = 0;\\n if (paymentMode == PaymentMode.walletEth) {\\n requiredEthPrefund = requiredPrefund;\\n } else if (paymentMode == PaymentMode.walletStake) {\\n _prefundFromSender(op, requiredPrefund);\\n } else {\\n // paymaster pays in handlePostOp\\n }\\n try IWallet(op.getSender()).verifyUserOp{gas : op.verificationGas}(op, requiredEthPrefund) {\\n } catch Error(string memory revertReason) {\\n revert FailedOp(opIndex, address(0), revertReason);\\n } catch {\\n revert FailedOp(opIndex, address(0), \\\"\\\");\\n }\\n uint actualEthPrefund = address(this).balance - preBalance;\\n\\n if (paymentMode == PaymentMode.walletEth) {\\n if (actualEthPrefund < requiredEthPrefund) {\\n revert FailedOp(opIndex, address(0), \\\"wallet didn't pay prefund\\\");\\n }\\n prefund = actualEthPrefund;\\n } else if (paymentMode == PaymentMode.walletStake) {\\n if (actualEthPrefund != 0) {\\n revert FailedOp(opIndex, address(0), \\\"using wallet stake but wallet paid eth\\\");\\n }\\n prefund = requiredPrefund;\\n } else {\\n if (actualEthPrefund != 0) {\\n revert FailedOp(opIndex, address(0), \\\"has paymaster but wallet paid\\\");\\n }\\n prefund = requiredPrefund;\\n }\\n\\n gasUsedByPayForSelfOp = preGas - gasleft();\\n }\\n\\n //validate paymaster.verifyPaymasterUserOp\\n function _validatePaymasterPrepayment(uint opIndex, UserOperation calldata op, uint requiredPreFund, uint gasUsedByPayForSelfOp) internal view returns (bytes memory context, uint gasUsedByPayForOp) {\\n uint preGas = gasleft();\\n if (!isValidStake(op, requiredPreFund)) {\\n revert FailedOp(opIndex, op.paymaster, \\\"not enough stake\\\");\\n }\\n //no pre-pay from paymaster\\n uint gas = op.verificationGas - gasUsedByPayForSelfOp;\\n try IPaymaster(op.paymaster).verifyPaymasterUserOp{gas : gas}(op, requiredPreFund) returns (bytes memory _context){\\n context = _context;\\n } catch Error(string memory revertReason) {\\n revert FailedOp(opIndex, op.paymaster, revertReason);\\n } catch {\\n revert FailedOp(opIndex, op.paymaster, \\\"\\\");\\n }\\n gasUsedByPayForOp = preGas - gasleft();\\n }\\n\\n function _validatePrepayment(uint opIndex, UserOperation calldata userOp) private returns (uint prefund, PaymentMode paymentMode, bytes memory context){\\n\\n uint preGas = gasleft();\\n uint gasUsedByPayForSelfOp;\\n uint requiredPreFund;\\n (requiredPreFund, paymentMode) = getPaymentInfo(userOp);\\n\\n (gasUsedByPayForSelfOp, prefund) = _validateWalletPrepayment(opIndex, userOp, requiredPreFund, paymentMode);\\n\\n uint gasUsedByPayForOp = 0;\\n if (paymentMode == PaymentMode.paymasterStake) {\\n (context, gasUsedByPayForOp) = _validatePaymasterPrepayment(opIndex, userOp, requiredPreFund, gasUsedByPayForSelfOp);\\n } else {\\n context = \\\"\\\";\\n }\\n uint gasUsed = preGas - gasleft();\\n\\n if (userOp.verificationGas < gasUsed) {\\n revert FailedOp(opIndex, userOp.paymaster, \\\"Used more than verificationGas\\\");\\n }\\n }\\n\\n function getPaymastersStake(address[] calldata paymasters) external view returns (uint[] memory _stakes) {\\n _stakes = new uint[](paymasters.length);\\n for (uint i = 0; i < paymasters.length; i++) {\\n _stakes[i] = stakes[paymasters[i]].stake;\\n }\\n }\\n\\n function handlePostOp(IPaymaster.PostOpMode mode, UserOperation calldata op, bytes memory context, uint actualGas, uint prefund, PaymentMode paymentMode) private returns (uint actualGasCost) {\\n uint preGas = gasleft();\\n uint gasPrice = UserOperationLib.gasPrice(op);\\n actualGasCost = actualGas * gasPrice;\\n if (paymentMode != PaymentMode.paymasterStake) {\\n if (prefund < actualGasCost) {\\n revert (\\\"wallet prefund below actualGasCost\\\");\\n }\\n uint refund = prefund - actualGasCost;\\n if (paymentMode == PaymentMode.walletStake) {\\n _refundSenderStake(op, refund);\\n } else {\\n _refundSender(op, refund);\\n }\\n } else {\\n if (context.length > 0) {\\n //if paymaster.postOp reverts:\\n // - emit a message (just for sake of debugging of this poor paymaster)\\n // - paymaster still pays (from its stake)\\n try IPaymaster(op.paymaster).postOp(mode, context, actualGasCost) {}\\n catch (bytes memory errdata) {\\n emit PaymasterPostOpFailed(op.getSender(), op.paymaster, op.nonce, errdata);\\n }\\n }\\n //paymaster pays for full gas, including for postOp (and revert event)\\n actualGas += preGas - gasleft();\\n actualGasCost = actualGas * gasPrice;\\n //paymaster balance known to be high enough, and to be locked for this block\\n stakes[op.paymaster].stake -= uint96(actualGasCost);\\n }\\n _emitLog(op, actualGasCost, gasPrice, mode == IPaymaster.PostOpMode.opSucceeded);\\n }\\n\\n function _emitLog(UserOperation calldata op, uint actualGasCost, uint gasPrice, bool success) internal {\\n emit UserOperationEvent(op.getSender(), op.paymaster, op.nonce, actualGasCost, gasPrice, success);\\n }\\n\\n function _prefundFromSender(UserOperation calldata userOp, uint requiredPrefund) internal {\\n stakes[userOp.getSender()].stake -= uint96(requiredPrefund);\\n }\\n\\n function _refundSender(UserOperation calldata userOp, uint refund) internal {\\n //NOTE: deliberately ignoring revert: wallet should accept refund.\\n bool sendOk = payable(userOp.getSender()).send(refund);\\n (sendOk);\\n }\\n function _refundSenderStake(UserOperation calldata userOp, uint refund) internal {\\n stakes[userOp.getSender()].stake += uint96(refund);\\n }\\n\\n function isValidStake(UserOperation calldata userOp, uint requiredPreFund) internal view returns (bool) {\\n return isPaymasterStaked(userOp.paymaster, PAYMASTER_STAKE + requiredPreFund);\\n }\\n\\n function isPaymasterStaked(address paymaster, uint stake) public view returns (bool) {\\n return isStaked(paymaster, stake, unstakeDelayBlocks);\\n }\\n\\n function isContractDeployed(address addr) external view returns (bool) {\\n bytes32 hash;\\n assembly {\\n hash := extcodehash(addr)\\n }\\n return hash != bytes32(0);\\n }\\n}\\n\\n\",\"keccak256\":\"0x8b15a6fcb66f95fc079400ff2b38de805405ce6c23c4bbbc1bcd24bb6cabefb0\",\"license\":\"GPL-3.0\"},\"contracts/IPaymaster.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.7;\\n\\nimport \\\"./UserOperation.sol\\\";\\n\\ninterface IPaymaster {\\n\\n enum PostOpMode {\\n opSucceeded, // user op succeeded\\n opReverted, // user op reverted. still has to pay for gas.\\n postOpReverted //user op succeeded, but caused postOp to revert. Now its a 2nd call, after user's op was deliberately reverted.\\n }\\n // payment validation: check if paymaster agree to pay (using its stake)\\n // revert to reject this request.\\n // actual payment is done after postOp is called, by deducting actual call cost form the paymaster's stake.\\n // @param userOp the user operation\\n // @param maxcost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\\n // @returns context value to send to a postOp\\n // zero length to signify postOp is not required.\\n function verifyPaymasterUserOp(UserOperation calldata userOp, uint maxcost) external view returns (bytes memory context);\\n\\n // post-operation handler.\\n // @param mode\\n // opSucceeded - user operation succeeded.\\n // opReverted - user op reverted. still has to pay for gas.\\n // postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\\n // Now this is the 2nd call, after user's op was deliberately reverted.\\n // @param context - the context value returned by verifyPaymasterUserOp\\n // @param actualGasCost - actual gas used so far (without this postOp call).\\n function postOp(PostOpMode mode, bytes calldata context, uint actualGasCost) external;\\n}\\n\",\"keccak256\":\"0xef51907c5520d22e74cc7804b30634cdc6d2cbf2fe96b77d0b6785a53c4545a5\",\"license\":\"GPL-3.0\"},\"contracts/IWallet.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.7;\\n\\nimport \\\"./UserOperation.sol\\\";\\n\\ninterface IWallet {\\n\\n // validate user's signature and nonce\\n // @param requiredPrefund how much this wallet should pre-fund the transaction.\\n // @note that after execution, the excess is sent back to the wallet.\\n // @note if requiredPrefund is zero, the wallet MUST NOT send anything (the paymaster pays)\\n function verifyUserOp(UserOperation calldata userOp, uint requiredPrefund) external;\\n}\\n\",\"keccak256\":\"0x29f98a4e6033cd10007dcc9b569fda950413cc91d8560a67f20a35e8185c9228\",\"license\":\"GPL-3.0\"},\"contracts/StakeManager.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0-only\\npragma solidity ^0.8;\\n\\nimport \\\"hardhat/console.sol\\\";\\n\\ncontract StakeManager {\\n\\n /// minimum number of blocks to after 'unlock' before amount can be withdrawn.\\n uint32 immutable public unstakeDelayBlocks;\\n\\n constructor(uint32 _unstakeDelayBlocks) {\\n unstakeDelayBlocks = _unstakeDelayBlocks;\\n }\\n\\n event StakeAdded(\\n address indexed paymaster,\\n uint256 totalStake,\\n uint256 unstakeDelayBlocks\\n );\\n\\n /// Emitted once a stake is scheduled for withdrawal\\n event StakeUnlocking(\\n address indexed paymaster,\\n uint256 withdrawBlock\\n );\\n\\n event StakeWithdrawn(\\n address indexed paymaster,\\n address withdrawAddress,\\n uint256 amount\\n );\\n\\n /// @param stake - amount of ether staked for this paymaster\\n /// @param withdrawStake - once 'unlocked' the value is no longer staked.\\n /// @param withdrawBlock - first block number 'withdraw' will be callable, or zero if the unlock has not been called\\n struct StakeInfo {\\n uint96 stake;\\n uint32 unstakeDelayBlocks;\\n uint96 withdrawStake;\\n uint32 withdrawBlock;\\n }\\n\\n /// maps relay managers to their stakes\\n mapping(address => StakeInfo) public stakes;\\n\\n function getStakeInfo(address paymaster) external view returns (StakeInfo memory stakeInfo) {\\n return stakes[paymaster];\\n }\\n\\n /**\\n * add a deposit (just like stake, but with lock=0\\n * cancel any pending unlock\\n */\\n function addDeposit() external payable {\\n addStake(0);\\n }\\n\\n //add deposit to another account (doesn't change lock status)\\n function addDepositTo(address target) external payable {\\n stakes[target].stake += uint96(msg.value);\\n }\\n\\n /**\\n * add stake value for this paymaster.\\n * cancel any pending unlock\\n */\\n function addStake(uint32 _unstakeDelayBlocks) public payable {\\n require(_unstakeDelayBlocks >= stakes[msg.sender].unstakeDelayBlocks, \\\"cannot decrease unstake blocks\\\");\\n uint96 stake = uint96(stakes[msg.sender].stake + msg.value + stakes[msg.sender].withdrawStake);\\n stakes[msg.sender] = StakeInfo(\\n stake,\\n _unstakeDelayBlocks,\\n 0,\\n 0);\\n emit StakeAdded(msg.sender, stake, _unstakeDelayBlocks);\\n }\\n\\n function unlockStake() external {\\n StakeInfo storage info = stakes[msg.sender];\\n require(info.withdrawBlock == 0, \\\"already pending\\\");\\n require(info.stake != 0 && info.unstakeDelayBlocks != 0, \\\"no stake to unlock\\\");\\n uint32 withdrawBlock = uint32(block.number) + info.unstakeDelayBlocks;\\n info.withdrawBlock = withdrawBlock;\\n info.withdrawStake = info.stake;\\n info.stake = 0;\\n emit StakeUnlocking(msg.sender, withdrawBlock);\\n }\\n\\n function withdrawStake(address payable withdrawAddress) external {\\n StakeInfo memory info = stakes[msg.sender];\\n if (info.unstakeDelayBlocks != 0) {\\n require(info.withdrawStake > 0, \\\"no unlocked stake\\\");\\n require(info.withdrawBlock <= block.number, \\\"Withdrawal is not due\\\");\\n }\\n uint256 amount = info.withdrawStake + info.stake;\\n stakes[msg.sender] = StakeInfo(0, info.unstakeDelayBlocks, 0, 0);\\n withdrawAddress.transfer(amount);\\n emit StakeWithdrawn(msg.sender, withdrawAddress, amount);\\n }\\n\\n function isStaked(address paymaster, uint requiredStake, uint requiredDelayBlocks) public view returns (bool) {\\n StakeInfo memory stakeInfo = stakes[paymaster];\\n return stakeInfo.stake >= requiredStake && stakeInfo.unstakeDelayBlocks >= requiredDelayBlocks;\\n }\\n}\\n\",\"keccak256\":\"0x238f903aceaaa89fd289d99c16ff660b6f911837f50ccf3fc3bb94653024b1aa\",\"license\":\"GPL-3.0-only\"},\"contracts/UserOperation.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.7;\\n\\nimport \\\"hardhat/console.sol\\\";\\n\\n struct UserOperation {\\n\\n address sender;\\n uint256 nonce;\\n bytes initCode;\\n bytes callData;\\n uint callGas;\\n uint verificationGas;\\n uint preVerificationGas;\\n uint maxFeePerGas;\\n uint maxPriorityFeePerGas;\\n address paymaster;\\n bytes paymasterData;\\n bytes signature;\\n }\\n\\nlibrary UserOperationLib {\\n\\n function getSender(UserOperation calldata userOp) internal view returns (address ret) {\\n assembly {ret := calldataload(userOp)}\\n }\\n\\n //relayer/miner might submit the TX with higher priorityFee, but the user should not\\n // pay above what he signed for.\\n function gasPrice(UserOperation calldata userOp) internal view returns (uint) {\\n unchecked {\\n return min(userOp.maxFeePerGas, userOp.maxPriorityFeePerGas + block.basefee);\\n }\\n }\\n\\n function requiredGas(UserOperation calldata userOp) internal pure returns (uint) {\\n unchecked {\\n return userOp.callGas + userOp.verificationGas + userOp.preVerificationGas;\\n }\\n }\\n\\n function requiredPreFund(UserOperation calldata userOp, uint overhead) internal view returns (uint prefund) {\\n return (requiredGas(userOp) + overhead) * gasPrice(userOp);\\n }\\n\\n function hasPaymaster(UserOperation calldata userOp) internal pure returns (bool) {\\n return userOp.paymaster != address(0);\\n }\\n\\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\\n //lighter signature scheme. must match UserOp.ts#packUserOp\\n bytes calldata sig = userOp.signature;\\n assembly {\\n let ofs := userOp\\n let len := sub(sub(sig.offset, ofs), 32)\\n ret := mload(0x40)\\n mstore(0x40, add(ret, add(len, 32)))\\n mstore(ret, len)\\n calldatacopy(add(ret, 32), ofs, len)\\n }\\n return ret;\\n\\n //TODO: eip712-style ?\\n return abi.encode(\\n userOp.sender,\\n userOp.nonce,\\n keccak256(userOp.initCode),\\n keccak256(userOp.callData),\\n userOp.callGas,\\n userOp.verificationGas,\\n userOp.preVerificationGas,\\n userOp.maxFeePerGas,\\n userOp.maxPriorityFeePerGas,\\n userOp.paymaster,\\n keccak256(userOp.paymasterData)\\n );\\n }\\n\\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\\n return keccak256(abi.encodePacked(\\\"\\\\x19Ethereum Signed Message:\\\\n32\\\",\\n keccak256(pack(userOp))));\\n }\\n\\n function min(uint a, uint b) internal pure returns (uint) {\\n return a < b ? a : b;\\n }\\n}\\n\",\"keccak256\":\"0x7ea8383b9bbd8cfa5a96f59e1f37c20a681daa798b80d67eb52ade3c53f3ea30\",\"license\":\"GPL-3.0\"},\"hardhat/console.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity >= 0.4.22 <0.9.0;\\n\\nlibrary console {\\n\\taddress constant CONSOLE_ADDRESS = address(0x000000000000000000636F6e736F6c652e6c6f67);\\n\\n\\tfunction _sendLogPayload(bytes memory payload) private view {\\n\\t\\tuint256 payloadLength = payload.length;\\n\\t\\taddress consoleAddress = CONSOLE_ADDRESS;\\n\\t\\tassembly {\\n\\t\\t\\tlet payloadStart := add(payload, 32)\\n\\t\\t\\tlet r := staticcall(gas(), consoleAddress, payloadStart, payloadLength, 0, 0)\\n\\t\\t}\\n\\t}\\n\\n\\tfunction log() internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log()\\\"));\\n\\t}\\n\\n\\tfunction logInt(int p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(int)\\\", p0));\\n\\t}\\n\\n\\tfunction logUint(uint p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint)\\\", p0));\\n\\t}\\n\\n\\tfunction logString(string memory p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string)\\\", p0));\\n\\t}\\n\\n\\tfunction logBool(bool p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool)\\\", p0));\\n\\t}\\n\\n\\tfunction logAddress(address p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes(bytes memory p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes1(bytes1 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes1)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes2(bytes2 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes2)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes3(bytes3 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes3)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes4(bytes4 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes4)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes5(bytes5 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes5)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes6(bytes6 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes6)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes7(bytes7 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes7)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes8(bytes8 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes8)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes9(bytes9 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes9)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes10(bytes10 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes10)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes11(bytes11 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes11)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes12(bytes12 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes12)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes13(bytes13 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes13)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes14(bytes14 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes14)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes15(bytes15 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes15)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes16(bytes16 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes16)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes17(bytes17 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes17)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes18(bytes18 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes18)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes19(bytes19 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes19)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes20(bytes20 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes20)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes21(bytes21 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes21)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes22(bytes22 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes22)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes23(bytes23 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes23)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes24(bytes24 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes24)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes25(bytes25 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes25)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes26(bytes26 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes26)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes27(bytes27 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes27)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes28(bytes28 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes28)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes29(bytes29 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes29)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes30(bytes30 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes30)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes31(bytes31 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes31)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes32(bytes32 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes32)\\\", p0));\\n\\t}\\n\\n\\tfunction log(uint p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint)\\\", p0));\\n\\t}\\n\\n\\tfunction log(string memory p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string)\\\", p0));\\n\\t}\\n\\n\\tfunction log(bool p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool)\\\", p0));\\n\\t}\\n\\n\\tfunction log(address p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address)\\\", p0));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(address p0, address p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n}\\n\",\"keccak256\":\"0x72b6a1d297cd3b033d7c2e4a7e7864934bb767db6453623f1c3082c6534547f4\",\"license\":\"MIT\"}},\"version\":1}", - "bytecode": "0x60e06040523480156200001157600080fd5b5060405162002cc738038062002cc7833981016040819052620000349162000060565b60e01b6001600160e01b03191660805260609190911b6001600160601b03191660c05260a052620000bb565b6000806000606084860312156200007657600080fd5b83516001600160a01b03811681146200008e57600080fd5b60208501516040860151919450925063ffffffff81168114620000b057600080fd5b809150509250925092565b60805160e01c60a05160c05160601c612bac6200011b60003960008181610156015281816103e50152611f350152600081816102af01528181610a0a01528181611330015261187101526000818161056e01526107f50152612bac6000f3fe6080604052600436106101235760003560e01c8063af2ed7d7116100a0578063c345315311610064578063c345315314610446578063dbbabd6a1461053c578063e7c350e31461055c578063f20751eb146105a5578063f3737f19146105c657600080fd5b8063af2ed7d71461033a578063bb9fe6bf1461035a578063bf55512e1461036f578063c23a5cea1461038f578063c31e4354146103af57600080fd5b80632815c17b116100e75780632815c17b146102755780634a58db1914610295578063643407ce1461029d578063739b8950146102df578063828190131461030c57600080fd5b80630396cb601461012f5780630bfb68471461014457806316934fc4146101955780631c112a44146102255780631fa75c861461025557600080fd5b3661012a57005b600080fd5b61014261013d366004612540565b6105d9565b005b34801561015057600080fd5b506101787f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020015b60405180910390f35b3480156101a157600080fd5b506101ee6101b0366004612161565b6000602081905290815260409020546001600160601b038082169163ffffffff600160601b8204811692600160801b83041691600160e01b90041684565b604080516001600160601b03958616815263ffffffff9485166020820152949092169184019190915216606082015260800161018c565b34801561023157600080fd5b506102456102403660046121c7565b610764565b604051901515815260200161018c565b34801561026157600080fd5b5061024561027036600461219b565b6107ec565b34801561028157600080fd5b5061014261029036600461223d565b610826565b610142610c24565b3480156102a957600080fd5b506102d17f000000000000000000000000000000000000000000000000000000000000000081565b60405190815260200161018c565b3480156102eb57600080fd5b506102ff6102fa3660046121fc565b610c30565b60405161018c91906126dd565b34801561031857600080fd5b5061032c6103273660046124e3565b610d09565b60405161018c929190612745565b34801561034657600080fd5b506102d161035536600461242a565b610d70565b34801561036657600080fd5b50610142610ee2565b34801561037b57600080fd5b506102d161038a36600461239d565b611055565b34801561039b57600080fd5b506101426103aa366004612161565b6110e0565b3480156103bb57600080fd5b506101786103ca366004612314565b8151602092830120604080516001600160f81b0319818601527f000000000000000000000000000000000000000000000000000000000000000060601b6bffffffffffffffffffffffff191660218201526035810193909352605580840192909252805180840390920182526075909201909152805191012090565b34801561045257600080fd5b506104eb610461366004612161565b604080516080810182526000808252602082018190529181018290526060810191909152506001600160a01b031660009081526020818152604091829020825160808101845290546001600160601b03808216835263ffffffff600160601b8304811694840194909452600160801b82041693820193909352600160e01b90920416606082015290565b60405161018c919060006080820190506001600160601b03808451168352602084015163ffffffff808216602086015282604087015116604086015280606087015116606086015250505092915050565b34801561054857600080fd5b506101426105573660046123d9565b611311565b34801561056857600080fd5b506105907f000000000000000000000000000000000000000000000000000000000000000081565b60405163ffffffff909116815260200161018c565b3480156105b157600080fd5b506102456105c0366004612161565b3f151590565b6101426105d4366004612161565b61142b565b3360009081526020819052604090205463ffffffff600160601b9091048116908216101561064e5760405162461bcd60e51b815260206004820152601e60248201527f63616e6e6f7420646563726561736520756e7374616b6520626c6f636b73000060448201526064015b60405180910390fd5b336000908152602081905260408120546001600160601b03600160801b820481169161067c9134911661290f565b610686919061290f565b604080516080810182526001600160601b0383811680835263ffffffff878116602080860182815260008789018181526060890182815233808452838652928b902099518a54945192519151908a166001600160801b031990951694909417600160601b92881692909202919091176001600160801b0316600160801b91909816026001600160e01b031696909617600160e01b91909416029290921790945584519182528101929092529293507f270d6dd254edd1d985c81cf7861b8f28fb06b6d719df04d90464034d4341244091015b60405180910390a25050565b6001600160a01b038316600090815260208181526040808320815160808101835290546001600160601b0380821680845263ffffffff600160601b8404811696850196909652600160801b830490911693830193909352600160e01b9004909216606083015284118015906107e3575082816020015163ffffffff1610155b95945050505050565b600061081f83837f000000000000000000000000000000000000000000000000000000000000000063ffffffff16610764565b9392505050565b816000816001600160401b0381111561084157610841612a88565b60405190808252806020026020018201604052801561086a578160200160208202803683370190505b5090506000826001600160401b0381111561088757610887612a88565b6040519080825280602002602001820160405280156108b0578160200160208202803683370190505b5090506000836001600160401b038111156108cd576108cd612a88565b6040519080825280602002602001820160405280156108f6578160200160208202803683370190505b5090506000846001600160401b0381111561091357610913612a88565b60405190808252806020026020018201604052801561093c578160200160208202803683370190505b50905060005b85811015610a735760005a9050368a8a8481811061096257610962612a72565b90506020028101906109749190612882565b9050606060006109848584611483565b89888151811061099657610996612a72565b602002602001018989815181106109af576109af612a72565b602002602001018296508360028111156109cb576109cb612a5c565b60028111156109dc576109dc612a5c565b81525083815250505050819050808886815181106109fc576109fc612a72565b6020026020010181815250507f00000000000000000000000000000000000000000000000000000000000000005a610a349086612990565b610a3e919061290f565b898681518110610a5057610a50612a72565b602002602001018181525050505050508080610a6b90612a2b565b915050610942565b506000805b88811015610c0e5760005a9050368b8b84818110610a9857610a98612a72565b9050602002810190610aaa9190612882565b90506000878481518110610ac057610ac0612a72565b60200260200101519050606081905060008a8681518110610ae357610ae3612a72565b602002602001015190506000898781518110610b0157610b01612a72565b602002602001015190506000898881518110610b1f57610b1f612a72565b60200260200101519050306001600160a01b031663af2ed7d787868686866040518663ffffffff1660e01b8152600401610b5d959493929190612799565b602060405180830381600087803b158015610b7757600080fd5b505af1925050508015610ba7575060408051601f3d908101601f19168201909252610ba491810190612527565b60015b610be6576000835a610bb9908a612990565b610bc3919061290f565b9050610bd460028887848787611589565b610bde908b61290f565b995050610bf4565b610bf0818b61290f565b9950505b505050505050508080610c0690612a2b565b915050610a78565b50610c19878261182d565b505050505050505050565b610c2e60006105d9565b565b6060816001600160401b03811115610c4a57610c4a612a88565b604051908082528060200260200182016040528015610c73578160200160208202803683370190505b50905060005b82811015610d0257600080858584818110610c9657610c96612a72565b9050602002016020810190610cab9190612161565b6001600160a01b0316815260208101919091526040016000205482516001600160601b0390911690839083908110610ce557610ce5612a72565b602090810291909101015280610cfa81612a2b565b915050610c79565b5092915050565b60606000806000610d1986611868565b90925090506000816002811115610d3257610d32612a5c565b14610d555760006040518060200160405280600081525090935093505050610d69565b610d6260008784886118cf565b9350935050505b9250929050565b6000805a9050333014610d8257600080fd5b600080610d9260608b018b61283c565b90501115610e74576000808a356001600160a01b031660808c0135610dba60608e018e61283c565b604051610dc89291906126cd565b60006040518083038160008787f1925050503d8060008114610e06576040519150601f19603f3d011682016040523d82523d6000602084013e610e0b565b606091505b509150915081158015610e1f575060008151115b15610e71578a356001600160a01b03167fbe4889eb241fb33bc0e9873f6e442f4c5dc653a55e7ad8bca2f001c9b3d818fb8c6020013583604051610e64929190612823565b60405180910390a2600192505b50505b6000865a610e829085612990565b610e8c919061290f565b9050610ed4828b8b8b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508792508c91508b9050611589565b9a9950505050505050505050565b3360009081526020819052604090208054600160e01b900463ffffffff1615610f3f5760405162461bcd60e51b815260206004820152600f60248201526e616c72656164792070656e64696e6760881b6044820152606401610645565b80546001600160601b031615801590610f6557508054600160601b900463ffffffff1615155b610fa65760405162461bcd60e51b81526020600482015260126024820152716e6f207374616b6520746f20756e6c6f636b60701b6044820152606401610645565b8054600090610fc290600160601b900463ffffffff1643612927565b82546001600160801b0381166bffffffffffffffffffffffff60801b19600160e01b63ffffffff8516908102918216929092176001600160601b039384169190931617600160801b02919091176bffffffffffffffffffffffff1916845560405190815290915033907fab3a43860ac8cdb29929ba1a1f556b4decf9617f4811c190010e1672e55839b190602001610758565b600033156110ba5760405162461bcd60e51b815260206004820152602c60248201527f6d7573742062652063616c6c6564206f66662d636861696e207769746820667260448201526b37b69ebd32b93796b0b2323960a11b6064820152608401610645565b6000806110c684611868565b915091506110d76000858484611aab565b50949350505050565b3360009081526020818152604091829020825160808101845290546001600160601b03808216835263ffffffff600160601b83048116948401859052600160801b830490911694830194909452600160e01b90049092166060830152156111e457600081604001516001600160601b0316116111925760405162461bcd60e51b81526020600482015260116024820152706e6f20756e6c6f636b6564207374616b6560781b6044820152606401610645565b43816060015163ffffffff1611156111e45760405162461bcd60e51b81526020600482015260156024820152745769746864726177616c206973206e6f742064756560581b6044820152606401610645565b805160408201516000916111f79161294f565b60408051608081018252600080825260208681015163ffffffff9081168285019081528486018481526060860185815233865293859052868520955186549251915194518416600160e01b026001600160e01b036001600160601b03968716600160801b02166001600160801b0393909516600160601b026001600160801b031990941691861691909117929092171691909117179092559151921692506001600160a01b0385169183156108fc0291849190818181858888f193505050501580156112c7573d6000803e3d6000fd5b50604080516001600160a01b03851681526020810183905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda3910160405180910390a2505050565b60005a90506000806000611326600087611483565b92509250925060007f00000000000000000000000000000000000000000000000000000000000000005a61135a9087612990565b611364919061290f565b60405163af2ed7d760e01b8152909150600090309063af2ed7d790611395908b90879087908b908b90600401612799565b602060405180830381600087803b1580156113af57600080fd5b505af19250505080156113df575060408051601f3d908101601f191682019092526113dc91810190612527565b60015b611414576000825a6113f19089612990565b6113fb919061290f565b905061140c60028a86848a8a611589565b915050611417565b90505b611421878261182d565b5050505050505050565b6001600160a01b0381166000908152602081905260408120805434929061145c9084906001600160601b031661294f565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555050565b600080606060005a905060008061149987611868565b955090506114a988888388611aab565b965091506000808660028111156114c2576114c2612a5c565b14156114de576114d4898984866118cf565b90955090506114f1565b6040518060200160405280600081525094505b60005a6114fe9086612990565b9050808960a00135101561157d578961151f6101408b016101208c01612161565b60405162fa072b60e01b815260048101929092526001600160a01b0316602482015260606044820152601e60648201527f55736564206d6f7265207468616e20766572696669636174696f6e4761730000608482015260a401610645565b50505050509250925092565b6000805a9050600061159a88611d77565b90506115a68187612971565b925060008460028111156115bc576115bc612a5c565b14611663578285101561161c5760405162461bcd60e51b815260206004820152602260248201527f77616c6c65742070726566756e642062656c6f772061637475616c476173436f6044820152611cdd60f21b6064820152608401610645565b60006116288487612990565b9050600185600281111561163e5761163e612a5c565b14156116535761164e8982611d94565b61165d565b61165d8982611dee565b50611801565b86511561176f5761167c61014089016101208a01612161565b6001600160a01b031663a9a234098a89866040518463ffffffff1660e01b81526004016116ab93929190612767565b600060405180830381600087803b1580156116c557600080fd5b505af19250505080156116d6575060015b61176f573d808015611704576040519150601f19603f3d011682016040523d82523d6000602084013e611709565b606091505b5061171c6101408a016101208b01612161565b6001600160a01b031689356001600160a01b03167f45197bfe91c32368fd75a4fcab42a1eff7699e79df0e171a343537be7657efb68b6020013584604051611765929190612823565b60405180910390a3505b5a61177a9083612990565b611784908761290f565b95506117908187612971565b9250826000806117a86101408c016101208d01612161565b6001600160a01b031681526020810191909152604001600090812080549091906117dc9084906001600160601b03166129a7565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b61182188848360008d600281111561181b5761181b612a5c565b14611e1b565b50509695505050505050565b6040516001600160a01b0383169082156108fc029083906000818181858888f19350505050158015611863573d6000803e3d6000fd5b505050565b600080611895837f0000000000000000000000000000000000000000000000000000000000000000611e97565b91506118a083611ec6565b156118ad57506000915091565b6118ba8335836000610764565b156118c757506001915091565b506002915091565b60606000805a90506118e18686611eec565b61194957866118f861014088016101208901612161565b60405162fa072b60e01b815260048101929092526001600160a01b0316602482015260606044820152601060648201526f6e6f7420656e6f756768207374616b6560801b608482015260a401610645565b60006119598560a0890135612990565b905061196d61014088016101208901612161565b6001600160a01b03166380fd44d58289896040518463ffffffff1660e01b815260040161199b9291906127e6565b60006040518083038187803b1580156119b357600080fd5b5086fa935050505080156119e957506040513d6000823e601f3d908101601f191682016040526119e69190810190612293565b60015b611a91576119f5612a9e565b806308c379a01415611a445750611a0a612aba565b80611a155750611a46565b88611a286101408a016101208b01612161565b8260405162fa072b60e01b8152600401610645939291906127f9565b505b87611a5961014089016101208a01612161565b60405162fa072b60e01b815260048101929092526001600160a01b031660248201526060604482015260006064820152608401610645565b93505a611a9e9083612990565b9250505094509492505050565b60008060005a9050611abc86611f15565b4760006002866002811115611ad357611ad3612a5c565b1415611ae0575085611b04565b6001866002811115611af457611af4612a5c565b1415611b0457611b04888861209d565b6040516307dfd9cf60e51b81526001600160a01b038935169063fbfb39e09060a08b013590611b39908c9086906004016127e6565b600060405180830381600088803b158015611b5357600080fd5b5087f193505050508015611b65575060015b611be257611b71612a9e565b806308c379a01415611bb05750611b86612aba565b80611b915750611bb2565b8960008260405162fa072b60e01b8152600401610645939291906127f9565b505b60405162fa072b60e01b8152600481018a9052600060248201819052606060448301526064820152608401610645565b6000611bee8347612990565b90506002876002811115611c0457611c04612a5c565b1415611c705781811015611c685760405162fa072b60e01b8152600481018b90526000602482015260606044820152601960648201527f77616c6c6574206469646e2774207061792070726566756e6400000000000000608482015260a401610645565b809450611d5d565b6001876002811115611c8457611c84612a5c565b1415611cfd578015611cf55760405162fa072b60e01b8152600481018b90526000602482015260606044820152602660648201527f7573696e672077616c6c6574207374616b65206275742077616c6c65742070616084820152650d2c840cae8d60d31b60a482015260c401610645565b879450611d5d565b8015611d595760405162fa072b60e01b8152600481018b90526000602482015260606044820152601d60648201527f686173207061796d6173746572206275742077616c6c65742070616964000000608482015260a401610645565b8794505b5a611d689085612990565b95505050505094509492505050565b6000611d8e8260e0013548846101000135016120cf565b92915050565b6001600160a01b0382351660009081526020819052604081208054839290611dc69084906001600160601b031661294f565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050565b6040516000906001600160a01b038435169083156108fc0290849084818181858888f15050505050505050565b611e2d61014085016101208601612161565b6001600160a01b03168435604080516020808901358252810187905290810185905283151560608201526001600160a01b0391909116907fc27a60e61c14607957b41fa2dad696de47b2d80e390d0eaaf1514c0cd20342939060800160405180910390a350505050565b6000611ea283611d77565b611ebc83608086013560a08701350160c08701350161290f565b61081f9190612971565b600080611edb61014084016101208501612161565b6001600160a01b0316141592915050565b600061081f611f0361014085016101208601612161565b61027084670de0b6b3a764000061290f565b611f22604082018261283c565b15905061209a5760006001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016634af63f02611f67604085018561283c565b6040516001600160e01b031960e085901b168152611f8f929190602088013590600401612721565b602060405180830381600087803b158015611fa957600080fd5b505af1158015611fbd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611fe1919061217e565b90506001600160a01b03811661202a5760405162461bcd60e51b815260206004820152600e60248201526d18dc99585d194c8819985a5b195960921b6044820152606401610645565b81356001600160a01b0316816001600160a01b0316146120985760405162461bcd60e51b8152602060048201526024808201527f73656e64657220646f65736e2774206d617463682063726561746532206164646044820152637265737360e01b6064820152608401610645565b505b50565b6001600160a01b0382351660009081526020819052604081208054839290611dc69084906001600160601b03166129a7565b60008183106120de578161081f565b5090919050565b80356120f081612b61565b919050565b60008083601f84011261210757600080fd5b5081356001600160401b0381111561211e57600080fd5b6020830191508360208260051b8501011115610d6957600080fd5b8035600381106120f057600080fd5b6000610180828403121561215b57600080fd5b50919050565b60006020828403121561217357600080fd5b813561081f81612b61565b60006020828403121561219057600080fd5b815161081f81612b61565b600080604083850312156121ae57600080fd5b82356121b981612b61565b946020939093013593505050565b6000806000606084860312156121dc57600080fd5b83356121e781612b61565b95602085013595506040909401359392505050565b6000806020838503121561220f57600080fd5b82356001600160401b0381111561222557600080fd5b612231858286016120f5565b90969095509350505050565b60008060006040848603121561225257600080fd5b83356001600160401b0381111561226857600080fd5b612274868287016120f5565b909450925050602084013561228881612b61565b809150509250925092565b6000602082840312156122a557600080fd5b81516001600160401b038111156122bb57600080fd5b8201601f810184136122cc57600080fd5b80516122d7816128a3565b6040516122e482826129ff565b8281528660208486010111156122f957600080fd5b61230a8360208301602087016129cf565b9695505050505050565b6000806040838503121561232757600080fd5b82356001600160401b0381111561233d57600080fd5b8301601f8101851361234e57600080fd5b8035612359816128a3565b60405161236682826129ff565b82815287602084860101111561237b57600080fd5b8260208501602083013760006020938201840152979590910135955050505050565b6000602082840312156123af57600080fd5b81356001600160401b038111156123c557600080fd5b6123d184828501612148565b949350505050565b600080604083850312156123ec57600080fd5b82356001600160401b0381111561240257600080fd5b61240e85828601612148565b925050602083013561241f81612b61565b809150509250929050565b60008060008060008060a0878903121561244357600080fd5b86356001600160401b038082111561245a57600080fd5b6124668a838b01612148565b9750602089013591508082111561247c57600080fd5b818901915089601f83011261249057600080fd5b81358181111561249f57600080fd5b8a60208285010111156124b157600080fd5b60208301975080965050505060408701359250606087013591506124d760808801612139565b90509295509295509295565b600080604083850312156124f657600080fd5b82356001600160401b0381111561250c57600080fd5b61251885828601612148565b95602094909401359450505050565b60006020828403121561253957600080fd5b5051919050565b60006020828403121561255257600080fd5b813563ffffffff8116811461081f57600080fd5b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b600081518084526125a78160208601602086016129cf565b601f01601f19169290920160200192915050565b60006101806125da846125cd856120e5565b6001600160a01b03169052565b602083013560208501526125f160408401846128ca565b8260408701526126048387018284612566565b9250505061261560608401846128ca565b8583036060870152612628838284612566565b925050506080830135608085015260a083013560a085015260c083013560c085015260e083013560e085015261010080840135818601525061012061266e8185016120e5565b6001600160a01b03169085015261014061268a848201856128ca565b8684038388015261269c848284612566565b93505050506101606126b0818501856128ca565b868403838801526126c2848284612566565b979650505050505050565b8183823760009101908152919050565b6020808252825182820181905260009190848201906040850190845b81811015612715578351835292840192918401916001016126f9565b50909695505050505050565b604081526000612735604083018587612566565b9050826020830152949350505050565b604081526000612758604083018561258f565b90508260208301529392505050565b61277084612b43565b838152606060208201526000612789606083018561258f565b9050826040830152949350505050565b60a0815260006127ac60a08301886125bb565b82810360208401526127be818861258f565b9150508460408301528360608301526127d683612b43565b8260808301529695505050505050565b60408152600061275860408301856125bb565b8381526001600160a01b03831660208201526060604082018190526000906107e39083018461258f565b8281526040602082015260006123d1604083018461258f565b6000808335601e1984360301811261285357600080fd5b8301803591506001600160401b0382111561286d57600080fd5b602001915036819003821315610d6957600080fd5b6000823561017e1983360301811261289957600080fd5b9190910192915050565b60006001600160401b038211156128bc576128bc612a88565b50601f01601f191660200190565b6000808335601e198436030181126128e157600080fd5b83016020810192503590506001600160401b0381111561290057600080fd5b803603831315610d6957600080fd5b6000821982111561292257612922612a46565b500190565b600063ffffffff80831681851680830382111561294657612946612a46565b01949350505050565b60006001600160601b0380831681851680830382111561294657612946612a46565b600081600019048311821515161561298b5761298b612a46565b500290565b6000828210156129a2576129a2612a46565b500390565b60006001600160601b03838116908316818110156129c7576129c7612a46565b039392505050565b60005b838110156129ea5781810151838201526020016129d2565b838111156129f9576000848401525b50505050565b601f8201601f191681016001600160401b0381118282101715612a2457612a24612a88565b6040525050565b6000600019821415612a3f57612a3f612a46565b5060010190565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052602160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b600060033d1115612ab75760046000803e5060005160e01c5b90565b600060443d1015612ac85790565b6040516003193d81016004833e81513d6001600160401b038160248401118184111715612af757505050505090565b8285019150815181811115612b0f5750505050505090565b843d8701016020828501011115612b295750505050505090565b612b38602082860101876129ff565b509095945050505050565b6003811061209a57634e487b7160e01b600052602160045260246000fd5b6001600160a01b038116811461209a57600080fdfea26469706673582212207d15049d6b9c7e811e26d8092a0a93a7d0ccb320de507c9e54141a4480435a1c64736f6c63430008070033", - "deployedBytecode": "0x6080604052600436106101235760003560e01c8063af2ed7d7116100a0578063c345315311610064578063c345315314610446578063dbbabd6a1461053c578063e7c350e31461055c578063f20751eb146105a5578063f3737f19146105c657600080fd5b8063af2ed7d71461033a578063bb9fe6bf1461035a578063bf55512e1461036f578063c23a5cea1461038f578063c31e4354146103af57600080fd5b80632815c17b116100e75780632815c17b146102755780634a58db1914610295578063643407ce1461029d578063739b8950146102df578063828190131461030c57600080fd5b80630396cb601461012f5780630bfb68471461014457806316934fc4146101955780631c112a44146102255780631fa75c861461025557600080fd5b3661012a57005b600080fd5b61014261013d366004612540565b6105d9565b005b34801561015057600080fd5b506101787f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020015b60405180910390f35b3480156101a157600080fd5b506101ee6101b0366004612161565b6000602081905290815260409020546001600160601b038082169163ffffffff600160601b8204811692600160801b83041691600160e01b90041684565b604080516001600160601b03958616815263ffffffff9485166020820152949092169184019190915216606082015260800161018c565b34801561023157600080fd5b506102456102403660046121c7565b610764565b604051901515815260200161018c565b34801561026157600080fd5b5061024561027036600461219b565b6107ec565b34801561028157600080fd5b5061014261029036600461223d565b610826565b610142610c24565b3480156102a957600080fd5b506102d17f000000000000000000000000000000000000000000000000000000000000000081565b60405190815260200161018c565b3480156102eb57600080fd5b506102ff6102fa3660046121fc565b610c30565b60405161018c91906126dd565b34801561031857600080fd5b5061032c6103273660046124e3565b610d09565b60405161018c929190612745565b34801561034657600080fd5b506102d161035536600461242a565b610d70565b34801561036657600080fd5b50610142610ee2565b34801561037b57600080fd5b506102d161038a36600461239d565b611055565b34801561039b57600080fd5b506101426103aa366004612161565b6110e0565b3480156103bb57600080fd5b506101786103ca366004612314565b8151602092830120604080516001600160f81b0319818601527f000000000000000000000000000000000000000000000000000000000000000060601b6bffffffffffffffffffffffff191660218201526035810193909352605580840192909252805180840390920182526075909201909152805191012090565b34801561045257600080fd5b506104eb610461366004612161565b604080516080810182526000808252602082018190529181018290526060810191909152506001600160a01b031660009081526020818152604091829020825160808101845290546001600160601b03808216835263ffffffff600160601b8304811694840194909452600160801b82041693820193909352600160e01b90920416606082015290565b60405161018c919060006080820190506001600160601b03808451168352602084015163ffffffff808216602086015282604087015116604086015280606087015116606086015250505092915050565b34801561054857600080fd5b506101426105573660046123d9565b611311565b34801561056857600080fd5b506105907f000000000000000000000000000000000000000000000000000000000000000081565b60405163ffffffff909116815260200161018c565b3480156105b157600080fd5b506102456105c0366004612161565b3f151590565b6101426105d4366004612161565b61142b565b3360009081526020819052604090205463ffffffff600160601b9091048116908216101561064e5760405162461bcd60e51b815260206004820152601e60248201527f63616e6e6f7420646563726561736520756e7374616b6520626c6f636b73000060448201526064015b60405180910390fd5b336000908152602081905260408120546001600160601b03600160801b820481169161067c9134911661290f565b610686919061290f565b604080516080810182526001600160601b0383811680835263ffffffff878116602080860182815260008789018181526060890182815233808452838652928b902099518a54945192519151908a166001600160801b031990951694909417600160601b92881692909202919091176001600160801b0316600160801b91909816026001600160e01b031696909617600160e01b91909416029290921790945584519182528101929092529293507f270d6dd254edd1d985c81cf7861b8f28fb06b6d719df04d90464034d4341244091015b60405180910390a25050565b6001600160a01b038316600090815260208181526040808320815160808101835290546001600160601b0380821680845263ffffffff600160601b8404811696850196909652600160801b830490911693830193909352600160e01b9004909216606083015284118015906107e3575082816020015163ffffffff1610155b95945050505050565b600061081f83837f000000000000000000000000000000000000000000000000000000000000000063ffffffff16610764565b9392505050565b816000816001600160401b0381111561084157610841612a88565b60405190808252806020026020018201604052801561086a578160200160208202803683370190505b5090506000826001600160401b0381111561088757610887612a88565b6040519080825280602002602001820160405280156108b0578160200160208202803683370190505b5090506000836001600160401b038111156108cd576108cd612a88565b6040519080825280602002602001820160405280156108f6578160200160208202803683370190505b5090506000846001600160401b0381111561091357610913612a88565b60405190808252806020026020018201604052801561093c578160200160208202803683370190505b50905060005b85811015610a735760005a9050368a8a8481811061096257610962612a72565b90506020028101906109749190612882565b9050606060006109848584611483565b89888151811061099657610996612a72565b602002602001018989815181106109af576109af612a72565b602002602001018296508360028111156109cb576109cb612a5c565b60028111156109dc576109dc612a5c565b81525083815250505050819050808886815181106109fc576109fc612a72565b6020026020010181815250507f00000000000000000000000000000000000000000000000000000000000000005a610a349086612990565b610a3e919061290f565b898681518110610a5057610a50612a72565b602002602001018181525050505050508080610a6b90612a2b565b915050610942565b506000805b88811015610c0e5760005a9050368b8b84818110610a9857610a98612a72565b9050602002810190610aaa9190612882565b90506000878481518110610ac057610ac0612a72565b60200260200101519050606081905060008a8681518110610ae357610ae3612a72565b602002602001015190506000898781518110610b0157610b01612a72565b602002602001015190506000898881518110610b1f57610b1f612a72565b60200260200101519050306001600160a01b031663af2ed7d787868686866040518663ffffffff1660e01b8152600401610b5d959493929190612799565b602060405180830381600087803b158015610b7757600080fd5b505af1925050508015610ba7575060408051601f3d908101601f19168201909252610ba491810190612527565b60015b610be6576000835a610bb9908a612990565b610bc3919061290f565b9050610bd460028887848787611589565b610bde908b61290f565b995050610bf4565b610bf0818b61290f565b9950505b505050505050508080610c0690612a2b565b915050610a78565b50610c19878261182d565b505050505050505050565b610c2e60006105d9565b565b6060816001600160401b03811115610c4a57610c4a612a88565b604051908082528060200260200182016040528015610c73578160200160208202803683370190505b50905060005b82811015610d0257600080858584818110610c9657610c96612a72565b9050602002016020810190610cab9190612161565b6001600160a01b0316815260208101919091526040016000205482516001600160601b0390911690839083908110610ce557610ce5612a72565b602090810291909101015280610cfa81612a2b565b915050610c79565b5092915050565b60606000806000610d1986611868565b90925090506000816002811115610d3257610d32612a5c565b14610d555760006040518060200160405280600081525090935093505050610d69565b610d6260008784886118cf565b9350935050505b9250929050565b6000805a9050333014610d8257600080fd5b600080610d9260608b018b61283c565b90501115610e74576000808a356001600160a01b031660808c0135610dba60608e018e61283c565b604051610dc89291906126cd565b60006040518083038160008787f1925050503d8060008114610e06576040519150601f19603f3d011682016040523d82523d6000602084013e610e0b565b606091505b509150915081158015610e1f575060008151115b15610e71578a356001600160a01b03167fbe4889eb241fb33bc0e9873f6e442f4c5dc653a55e7ad8bca2f001c9b3d818fb8c6020013583604051610e64929190612823565b60405180910390a2600192505b50505b6000865a610e829085612990565b610e8c919061290f565b9050610ed4828b8b8b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508792508c91508b9050611589565b9a9950505050505050505050565b3360009081526020819052604090208054600160e01b900463ffffffff1615610f3f5760405162461bcd60e51b815260206004820152600f60248201526e616c72656164792070656e64696e6760881b6044820152606401610645565b80546001600160601b031615801590610f6557508054600160601b900463ffffffff1615155b610fa65760405162461bcd60e51b81526020600482015260126024820152716e6f207374616b6520746f20756e6c6f636b60701b6044820152606401610645565b8054600090610fc290600160601b900463ffffffff1643612927565b82546001600160801b0381166bffffffffffffffffffffffff60801b19600160e01b63ffffffff8516908102918216929092176001600160601b039384169190931617600160801b02919091176bffffffffffffffffffffffff1916845560405190815290915033907fab3a43860ac8cdb29929ba1a1f556b4decf9617f4811c190010e1672e55839b190602001610758565b600033156110ba5760405162461bcd60e51b815260206004820152602c60248201527f6d7573742062652063616c6c6564206f66662d636861696e207769746820667260448201526b37b69ebd32b93796b0b2323960a11b6064820152608401610645565b6000806110c684611868565b915091506110d76000858484611aab565b50949350505050565b3360009081526020818152604091829020825160808101845290546001600160601b03808216835263ffffffff600160601b83048116948401859052600160801b830490911694830194909452600160e01b90049092166060830152156111e457600081604001516001600160601b0316116111925760405162461bcd60e51b81526020600482015260116024820152706e6f20756e6c6f636b6564207374616b6560781b6044820152606401610645565b43816060015163ffffffff1611156111e45760405162461bcd60e51b81526020600482015260156024820152745769746864726177616c206973206e6f742064756560581b6044820152606401610645565b805160408201516000916111f79161294f565b60408051608081018252600080825260208681015163ffffffff9081168285019081528486018481526060860185815233865293859052868520955186549251915194518416600160e01b026001600160e01b036001600160601b03968716600160801b02166001600160801b0393909516600160601b026001600160801b031990941691861691909117929092171691909117179092559151921692506001600160a01b0385169183156108fc0291849190818181858888f193505050501580156112c7573d6000803e3d6000fd5b50604080516001600160a01b03851681526020810183905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda3910160405180910390a2505050565b60005a90506000806000611326600087611483565b92509250925060007f00000000000000000000000000000000000000000000000000000000000000005a61135a9087612990565b611364919061290f565b60405163af2ed7d760e01b8152909150600090309063af2ed7d790611395908b90879087908b908b90600401612799565b602060405180830381600087803b1580156113af57600080fd5b505af19250505080156113df575060408051601f3d908101601f191682019092526113dc91810190612527565b60015b611414576000825a6113f19089612990565b6113fb919061290f565b905061140c60028a86848a8a611589565b915050611417565b90505b611421878261182d565b5050505050505050565b6001600160a01b0381166000908152602081905260408120805434929061145c9084906001600160601b031661294f565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555050565b600080606060005a905060008061149987611868565b955090506114a988888388611aab565b965091506000808660028111156114c2576114c2612a5c565b14156114de576114d4898984866118cf565b90955090506114f1565b6040518060200160405280600081525094505b60005a6114fe9086612990565b9050808960a00135101561157d578961151f6101408b016101208c01612161565b60405162fa072b60e01b815260048101929092526001600160a01b0316602482015260606044820152601e60648201527f55736564206d6f7265207468616e20766572696669636174696f6e4761730000608482015260a401610645565b50505050509250925092565b6000805a9050600061159a88611d77565b90506115a68187612971565b925060008460028111156115bc576115bc612a5c565b14611663578285101561161c5760405162461bcd60e51b815260206004820152602260248201527f77616c6c65742070726566756e642062656c6f772061637475616c476173436f6044820152611cdd60f21b6064820152608401610645565b60006116288487612990565b9050600185600281111561163e5761163e612a5c565b14156116535761164e8982611d94565b61165d565b61165d8982611dee565b50611801565b86511561176f5761167c61014089016101208a01612161565b6001600160a01b031663a9a234098a89866040518463ffffffff1660e01b81526004016116ab93929190612767565b600060405180830381600087803b1580156116c557600080fd5b505af19250505080156116d6575060015b61176f573d808015611704576040519150601f19603f3d011682016040523d82523d6000602084013e611709565b606091505b5061171c6101408a016101208b01612161565b6001600160a01b031689356001600160a01b03167f45197bfe91c32368fd75a4fcab42a1eff7699e79df0e171a343537be7657efb68b6020013584604051611765929190612823565b60405180910390a3505b5a61177a9083612990565b611784908761290f565b95506117908187612971565b9250826000806117a86101408c016101208d01612161565b6001600160a01b031681526020810191909152604001600090812080549091906117dc9084906001600160601b03166129a7565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b61182188848360008d600281111561181b5761181b612a5c565b14611e1b565b50509695505050505050565b6040516001600160a01b0383169082156108fc029083906000818181858888f19350505050158015611863573d6000803e3d6000fd5b505050565b600080611895837f0000000000000000000000000000000000000000000000000000000000000000611e97565b91506118a083611ec6565b156118ad57506000915091565b6118ba8335836000610764565b156118c757506001915091565b506002915091565b60606000805a90506118e18686611eec565b61194957866118f861014088016101208901612161565b60405162fa072b60e01b815260048101929092526001600160a01b0316602482015260606044820152601060648201526f6e6f7420656e6f756768207374616b6560801b608482015260a401610645565b60006119598560a0890135612990565b905061196d61014088016101208901612161565b6001600160a01b03166380fd44d58289896040518463ffffffff1660e01b815260040161199b9291906127e6565b60006040518083038187803b1580156119b357600080fd5b5086fa935050505080156119e957506040513d6000823e601f3d908101601f191682016040526119e69190810190612293565b60015b611a91576119f5612a9e565b806308c379a01415611a445750611a0a612aba565b80611a155750611a46565b88611a286101408a016101208b01612161565b8260405162fa072b60e01b8152600401610645939291906127f9565b505b87611a5961014089016101208a01612161565b60405162fa072b60e01b815260048101929092526001600160a01b031660248201526060604482015260006064820152608401610645565b93505a611a9e9083612990565b9250505094509492505050565b60008060005a9050611abc86611f15565b4760006002866002811115611ad357611ad3612a5c565b1415611ae0575085611b04565b6001866002811115611af457611af4612a5c565b1415611b0457611b04888861209d565b6040516307dfd9cf60e51b81526001600160a01b038935169063fbfb39e09060a08b013590611b39908c9086906004016127e6565b600060405180830381600088803b158015611b5357600080fd5b5087f193505050508015611b65575060015b611be257611b71612a9e565b806308c379a01415611bb05750611b86612aba565b80611b915750611bb2565b8960008260405162fa072b60e01b8152600401610645939291906127f9565b505b60405162fa072b60e01b8152600481018a9052600060248201819052606060448301526064820152608401610645565b6000611bee8347612990565b90506002876002811115611c0457611c04612a5c565b1415611c705781811015611c685760405162fa072b60e01b8152600481018b90526000602482015260606044820152601960648201527f77616c6c6574206469646e2774207061792070726566756e6400000000000000608482015260a401610645565b809450611d5d565b6001876002811115611c8457611c84612a5c565b1415611cfd578015611cf55760405162fa072b60e01b8152600481018b90526000602482015260606044820152602660648201527f7573696e672077616c6c6574207374616b65206275742077616c6c65742070616084820152650d2c840cae8d60d31b60a482015260c401610645565b879450611d5d565b8015611d595760405162fa072b60e01b8152600481018b90526000602482015260606044820152601d60648201527f686173207061796d6173746572206275742077616c6c65742070616964000000608482015260a401610645565b8794505b5a611d689085612990565b95505050505094509492505050565b6000611d8e8260e0013548846101000135016120cf565b92915050565b6001600160a01b0382351660009081526020819052604081208054839290611dc69084906001600160601b031661294f565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050565b6040516000906001600160a01b038435169083156108fc0290849084818181858888f15050505050505050565b611e2d61014085016101208601612161565b6001600160a01b03168435604080516020808901358252810187905290810185905283151560608201526001600160a01b0391909116907fc27a60e61c14607957b41fa2dad696de47b2d80e390d0eaaf1514c0cd20342939060800160405180910390a350505050565b6000611ea283611d77565b611ebc83608086013560a08701350160c08701350161290f565b61081f9190612971565b600080611edb61014084016101208501612161565b6001600160a01b0316141592915050565b600061081f611f0361014085016101208601612161565b61027084670de0b6b3a764000061290f565b611f22604082018261283c565b15905061209a5760006001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016634af63f02611f67604085018561283c565b6040516001600160e01b031960e085901b168152611f8f929190602088013590600401612721565b602060405180830381600087803b158015611fa957600080fd5b505af1158015611fbd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611fe1919061217e565b90506001600160a01b03811661202a5760405162461bcd60e51b815260206004820152600e60248201526d18dc99585d194c8819985a5b195960921b6044820152606401610645565b81356001600160a01b0316816001600160a01b0316146120985760405162461bcd60e51b8152602060048201526024808201527f73656e64657220646f65736e2774206d617463682063726561746532206164646044820152637265737360e01b6064820152608401610645565b505b50565b6001600160a01b0382351660009081526020819052604081208054839290611dc69084906001600160601b03166129a7565b60008183106120de578161081f565b5090919050565b80356120f081612b61565b919050565b60008083601f84011261210757600080fd5b5081356001600160401b0381111561211e57600080fd5b6020830191508360208260051b8501011115610d6957600080fd5b8035600381106120f057600080fd5b6000610180828403121561215b57600080fd5b50919050565b60006020828403121561217357600080fd5b813561081f81612b61565b60006020828403121561219057600080fd5b815161081f81612b61565b600080604083850312156121ae57600080fd5b82356121b981612b61565b946020939093013593505050565b6000806000606084860312156121dc57600080fd5b83356121e781612b61565b95602085013595506040909401359392505050565b6000806020838503121561220f57600080fd5b82356001600160401b0381111561222557600080fd5b612231858286016120f5565b90969095509350505050565b60008060006040848603121561225257600080fd5b83356001600160401b0381111561226857600080fd5b612274868287016120f5565b909450925050602084013561228881612b61565b809150509250925092565b6000602082840312156122a557600080fd5b81516001600160401b038111156122bb57600080fd5b8201601f810184136122cc57600080fd5b80516122d7816128a3565b6040516122e482826129ff565b8281528660208486010111156122f957600080fd5b61230a8360208301602087016129cf565b9695505050505050565b6000806040838503121561232757600080fd5b82356001600160401b0381111561233d57600080fd5b8301601f8101851361234e57600080fd5b8035612359816128a3565b60405161236682826129ff565b82815287602084860101111561237b57600080fd5b8260208501602083013760006020938201840152979590910135955050505050565b6000602082840312156123af57600080fd5b81356001600160401b038111156123c557600080fd5b6123d184828501612148565b949350505050565b600080604083850312156123ec57600080fd5b82356001600160401b0381111561240257600080fd5b61240e85828601612148565b925050602083013561241f81612b61565b809150509250929050565b60008060008060008060a0878903121561244357600080fd5b86356001600160401b038082111561245a57600080fd5b6124668a838b01612148565b9750602089013591508082111561247c57600080fd5b818901915089601f83011261249057600080fd5b81358181111561249f57600080fd5b8a60208285010111156124b157600080fd5b60208301975080965050505060408701359250606087013591506124d760808801612139565b90509295509295509295565b600080604083850312156124f657600080fd5b82356001600160401b0381111561250c57600080fd5b61251885828601612148565b95602094909401359450505050565b60006020828403121561253957600080fd5b5051919050565b60006020828403121561255257600080fd5b813563ffffffff8116811461081f57600080fd5b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b600081518084526125a78160208601602086016129cf565b601f01601f19169290920160200192915050565b60006101806125da846125cd856120e5565b6001600160a01b03169052565b602083013560208501526125f160408401846128ca565b8260408701526126048387018284612566565b9250505061261560608401846128ca565b8583036060870152612628838284612566565b925050506080830135608085015260a083013560a085015260c083013560c085015260e083013560e085015261010080840135818601525061012061266e8185016120e5565b6001600160a01b03169085015261014061268a848201856128ca565b8684038388015261269c848284612566565b93505050506101606126b0818501856128ca565b868403838801526126c2848284612566565b979650505050505050565b8183823760009101908152919050565b6020808252825182820181905260009190848201906040850190845b81811015612715578351835292840192918401916001016126f9565b50909695505050505050565b604081526000612735604083018587612566565b9050826020830152949350505050565b604081526000612758604083018561258f565b90508260208301529392505050565b61277084612b43565b838152606060208201526000612789606083018561258f565b9050826040830152949350505050565b60a0815260006127ac60a08301886125bb565b82810360208401526127be818861258f565b9150508460408301528360608301526127d683612b43565b8260808301529695505050505050565b60408152600061275860408301856125bb565b8381526001600160a01b03831660208201526060604082018190526000906107e39083018461258f565b8281526040602082015260006123d1604083018461258f565b6000808335601e1984360301811261285357600080fd5b8301803591506001600160401b0382111561286d57600080fd5b602001915036819003821315610d6957600080fd5b6000823561017e1983360301811261289957600080fd5b9190910192915050565b60006001600160401b038211156128bc576128bc612a88565b50601f01601f191660200190565b6000808335601e198436030181126128e157600080fd5b83016020810192503590506001600160401b0381111561290057600080fd5b803603831315610d6957600080fd5b6000821982111561292257612922612a46565b500190565b600063ffffffff80831681851680830382111561294657612946612a46565b01949350505050565b60006001600160601b0380831681851680830382111561294657612946612a46565b600081600019048311821515161561298b5761298b612a46565b500290565b6000828210156129a2576129a2612a46565b500390565b60006001600160601b03838116908316818110156129c7576129c7612a46565b039392505050565b60005b838110156129ea5781810151838201526020016129d2565b838111156129f9576000848401525b50505050565b601f8201601f191681016001600160401b0381118282101715612a2457612a24612a88565b6040525050565b6000600019821415612a3f57612a3f612a46565b5060010190565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052602160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b600060033d1115612ab75760046000803e5060005160e01c5b90565b600060443d1015612ac85790565b6040516003193d81016004833e81513d6001600160401b038160248401118184111715612af757505050505090565b8285019150815181811115612b0f5750505050505090565b843d8701016020828501011115612b295750505050505090565b612b38602082860101876129ff565b509095945050505050565b6003811061209a57634e487b7160e01b600052602160045260246000fd5b6001600160a01b038116811461209a57600080fdfea26469706673582212207d15049d6b9c7e811e26d8092a0a93a7d0ccb320de507c9e54141a4480435a1c64736f6c63430008070033", - "devdoc": { - "kind": "dev", - "methods": { - "handleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,address,bytes,bytes),address)": { - "params": { - "op": "the operation to execute", - "redeemer": "the contract to redeem the fee" - } - }, - "simulatePaymasterValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,address,bytes,bytes),uint256)": { - "params": { - "gasUsedByPayForSelfOp": "- the gas returned by simulateWalletValidation, as these 2 calls should share the same userOp.validationGas quota. The node must also verify it doesn't use banned opcode, and that it doesn't reference storage outside the paymaster's data", - "userOp": "the user operation to validate." - } - }, - "simulateWalletValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,address,bytes,bytes))": { - "returns": { - "gasUsedByPayForSelfOp": "- gas used by the validation, to pass into simulatePaymasterValidation. The node must also verify it doesn't use banned opcode, and that it doesn't reference storage outside the wallet's data" - } - } - }, - "version": 1 - }, - "userdoc": { - "events": { - "StakeUnlocking(address,uint256)": { - "notice": "Emitted once a stake is scheduled for withdrawal" - } - }, - "kind": "user", - "methods": { - "addDeposit()": { - "notice": "add a deposit (just like stake, but with lock=0 cancel any pending unlock" - }, - "addStake(uint32)": { - "notice": "add stake value for this paymaster. cancel any pending unlock" - }, - "handleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,address,bytes,bytes),address)": { - "notice": "Execute the given UserOperation." - }, - "simulatePaymasterValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,address,bytes,bytes),uint256)": { - "notice": "Simulate a call to paymaster.verifyPaymasterUserOp do nothing if has no paymaster." - }, - "simulateWalletValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,address,bytes,bytes))": { - "notice": "Simulate a call for wallet.verifyUserOp. Call must not revert." - }, - "stakes(address)": { - "notice": "maps relay managers to their stakes" - }, - "unstakeDelayBlocks()": { - "notice": "minimum number of blocks to after 'unlock' before amount can be withdrawn." - } - }, - "version": 1 - }, - "storageLayout": { - "storage": [ - { - "astId": 2325, - "contract": "contracts/EntryPoint.sol:EntryPoint", - "label": "stakes", - "offset": 0, - "slot": "0", - "type": "t_mapping(t_address,t_struct(StakeInfo)2319_storage)" - } - ], - "types": { - "t_address": { - "encoding": "inplace", - "label": "address", - "numberOfBytes": "20" - }, - "t_mapping(t_address,t_struct(StakeInfo)2319_storage)": { - "encoding": "mapping", - "key": "t_address", - "label": "mapping(address => struct StakeManager.StakeInfo)", - "numberOfBytes": "32", - "value": "t_struct(StakeInfo)2319_storage" - }, - "t_struct(StakeInfo)2319_storage": { - "encoding": "inplace", - "label": "struct StakeManager.StakeInfo", - "members": [ - { - "astId": 2312, - "contract": "contracts/EntryPoint.sol:EntryPoint", - "label": "stake", - "offset": 0, - "slot": "0", - "type": "t_uint96" - }, - { - "astId": 2314, - "contract": "contracts/EntryPoint.sol:EntryPoint", - "label": "unstakeDelayBlocks", - "offset": 12, - "slot": "0", - "type": "t_uint32" - }, - { - "astId": 2316, - "contract": "contracts/EntryPoint.sol:EntryPoint", - "label": "withdrawStake", - "offset": 16, - "slot": "0", - "type": "t_uint96" - }, - { - "astId": 2318, - "contract": "contracts/EntryPoint.sol:EntryPoint", - "label": "withdrawBlock", - "offset": 28, - "slot": "0", - "type": "t_uint32" - } - ], - "numberOfBytes": "32" - }, - "t_uint32": { - "encoding": "inplace", - "label": "uint32", - "numberOfBytes": "4" - }, - "t_uint96": { - "encoding": "inplace", - "label": "uint96", - "numberOfBytes": "12" - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/SimpleWallet.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/SimpleWallet.json deleted file mode 100644 index 6b14b548fc..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/SimpleWallet.json +++ /dev/null @@ -1,338 +0,0 @@ -{ - "address": "0x16d53bCF7d1614D0fF81559abB94bfBC7d3B84D9", - "abi": [ - { - "inputs": [ - { - "internalType": "contract EntryPoint", - "name": "_entryPoint", - "type": "address" - }, - { - "internalType": "address", - "name": "_owner", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "contract EntryPoint", - "name": "oldEntryPoint", - "type": "address" - }, - { - "indexed": false, - "internalType": "contract EntryPoint", - "name": "newEntryPoint", - "type": "address" - } - ], - "name": "EntryPointChanged", - "type": "event" - }, - { - "inputs": [], - "name": "addDeposit", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [], - "name": "entryPoint", - "outputs": [ - { - "internalType": "contract EntryPoint", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "dest", - "type": "address" - }, - { - "internalType": "uint256", - "name": "value", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "func", - "type": "bytes" - } - ], - "name": "exec", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "dest", - "type": "address" - }, - { - "internalType": "uint256", - "name": "value", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "func", - "type": "bytes" - } - ], - "name": "execFromEntryPoint", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "nonce", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "dest", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract EntryPoint", - "name": "_entryPoint", - "type": "address" - } - ], - "name": "updateEntryPoint", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "requiredPrefund", - "type": "uint256" - } - ], - "name": "verifyUserOp", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - } - ], - "name": "withdrawDeposit", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "args": [ - "0xF63621e54F16eC6e4A732e44EaA7708935f259eF", - "0xd21934eD8eAf27a67f0A70042Af50A1D6d195E81" - ], - "solcInputHash": "9255faacf3ae4e81db1326413027bfa0", - "metadata": "{\"compiler\":{\"version\":\"0.8.7+commit.e28d00a7\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"contract EntryPoint\",\"name\":\"_entryPoint\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_owner\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"contract EntryPoint\",\"name\":\"oldEntryPoint\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"contract EntryPoint\",\"name\":\"newEntryPoint\",\"type\":\"address\"}],\"name\":\"EntryPointChanged\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"addDeposit\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"entryPoint\",\"outputs\":[{\"internalType\":\"contract EntryPoint\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"dest\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"func\",\"type\":\"bytes\"}],\"name\":\"exec\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"dest\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"func\",\"type\":\"bytes\"}],\"name\":\"execFromEntryPoint\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"nonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"dest\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contract EntryPoint\",\"name\":\"_entryPoint\",\"type\":\"address\"}],\"name\":\"updateEntryPoint\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"},{\"internalType\":\"uint256\",\"name\":\"requiredPrefund\",\"type\":\"uint256\"}],\"name\":\"verifyUserOp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"}],\"name\":\"withdrawDeposit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/samples/SimpleWallet.sol\":\"SimpleWallet\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\",\"useLiteralContent\":true},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"contracts/EntryPoint.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.7;\\n\\nimport \\\"./StakeManager.sol\\\";\\nimport \\\"./UserOperation.sol\\\";\\nimport \\\"./IWallet.sol\\\";\\nimport \\\"./IPaymaster.sol\\\";\\n\\ninterface ICreate2Deployer {\\n function deploy(bytes memory _initCode, bytes32 _salt) external returns (address);\\n}\\n\\ncontract EntryPoint is StakeManager {\\n\\n using UserOperationLib for UserOperation;\\n // paymaster locked stake\\n // (actual stake should be higher, to cover actual call cost)\\n uint256 constant PAYMASTER_STAKE = 1 ether;\\n\\n enum PaymentMode {\\n paymasterStake, // if paymaster is set, use paymaster's stake to pay.\\n walletStake, // wallet has enough stake to pay for request.\\n walletEth // wallet has no stake. paying with eth.\\n }\\n\\n uint public immutable perOpOverhead;\\n address public immutable create2factory;\\n\\n event UserOperationEvent(address indexed sender, address indexed paymaster, uint nonce, uint actualGasCost, uint actualGasPrice, bool success);\\n event UserOperationRevertReason(address indexed sender, uint nonce, bytes revertReason);\\n\\n event PaymasterPostOpFailed(address indexed sender, address indexed paymaster, uint nonce, bytes reason);\\n\\n //handleOps reverts with this error struct, to mark the offending op\\n // NOTE: if simulateOp passes successfully, there should be no reason for handleOps to fail on it.\\n // @param opIndex - index into the array of ops to the failed one (in simulateOp, this is always zero)\\n // @param paymaster - if paymaster.verifyPaymasterUserOp fails, this will be the paymaster's address. if verifyUserOp failed,\\n // this value will be zero (since it failed before accessing the paymaster)\\n // @param reason - revert reason\\n // only to aid troubleshooting of wallet/paymaster reverts\\n error FailedOp(uint opIndex, address paymaster, string reason);\\n\\n constructor(address _create2factory, uint _perOpOverhead, uint32 _unstakeDelayBlocks) StakeManager(_unstakeDelayBlocks) {\\n create2factory = _create2factory;\\n perOpOverhead = _perOpOverhead;\\n }\\n\\n receive() external payable {}\\n\\n /**\\n * Execute the given UserOperation.\\n * @param op the operation to execute\\n * @param redeemer the contract to redeem the fee\\n */\\n function handleOp(UserOperation calldata op, address payable redeemer) public {\\n\\n uint preGas = gasleft();\\n\\n (uint256 prefund, PaymentMode paymentMode, bytes memory context) = _validatePrepayment(0, op);\\n uint preOpGas = preGas - gasleft() + perOpOverhead;\\n\\n uint actualGasCost;\\n\\n try this.internalHandleOp(op, context, preOpGas, prefund, paymentMode) returns (uint _actualGasCost) {\\n actualGasCost = _actualGasCost;\\n } catch {\\n uint actualGas = preGas - gasleft() + preOpGas;\\n actualGasCost = handlePostOp(IPaymaster.PostOpMode.postOpReverted, op, context, actualGas, prefund, paymentMode);\\n }\\n\\n redeem(redeemer, actualGasCost);\\n }\\n\\n function redeem(address payable redeemer, uint amount) internal {\\n redeemer.transfer(amount);\\n }\\n\\n function handleOps(UserOperation[] calldata ops, address payable redeemer) public {\\n\\n uint opslen = ops.length;\\n uint256[] memory preOpGas = new uint256[](opslen);\\n bytes32[] memory contexts = new bytes32[](opslen);\\n uint256[] memory prefunds = new uint256[](opslen);\\n PaymentMode[] memory paymentModes = new PaymentMode[](opslen);\\n\\n for (uint i = 0; i < opslen; i++) {\\n uint preGas = gasleft();\\n UserOperation calldata op = ops[i];\\n\\n bytes memory context;\\n bytes32 contextOffset;\\n (prefunds[i], paymentModes[i], context) = _validatePrepayment(i, op);\\n assembly {contextOffset := context}\\n contexts[i] = contextOffset;\\n preOpGas[i] = preGas - gasleft() + perOpOverhead;\\n }\\n\\n uint collected = 0;\\n\\n for (uint i = 0; i < ops.length; i++) {\\n uint preGas = gasleft();\\n UserOperation calldata op = ops[i];\\n bytes32 contextOffset = contexts[i];\\n bytes memory context;\\n assembly {context := contextOffset}\\n uint preOpGasi = preOpGas[i];\\n uint prefundi = prefunds[i];\\n PaymentMode paymentModei = paymentModes[i];\\n\\n try this.internalHandleOp(op, context, preOpGasi, prefundi, paymentModei) returns (uint _actualGasCost) {\\n collected += _actualGasCost;\\n } catch {\\n uint actualGas = preGas - gasleft() + preOpGasi;\\n collected += handlePostOp(IPaymaster.PostOpMode.postOpReverted, op, context, actualGas, prefundi, paymentModei);\\n }\\n }\\n\\n redeem(redeemer, collected);\\n }\\n\\n function internalHandleOp(UserOperation calldata op, bytes calldata context, uint preOpGas, uint prefund, PaymentMode paymentMode) external returns (uint actualGasCost) {\\n uint preGas = gasleft();\\n require(msg.sender == address(this));\\n\\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\\n if (op.callData.length > 0) {\\n\\n (bool success,bytes memory result) = address(op.getSender()).call{gas : op.callGas}(op.callData);\\n if (!success && result.length > 0) {\\n emit UserOperationRevertReason(op.getSender(), op.nonce, result);\\n mode = IPaymaster.PostOpMode.opReverted;\\n }\\n }\\n\\n uint actualGas = preGas - gasleft() + preOpGas;\\n return handlePostOp(mode, op, context, actualGas, prefund, paymentMode);\\n }\\n\\n /**\\n * Simulate a call for wallet.verifyUserOp.\\n * Call must not revert.\\n * @return gasUsedByPayForSelfOp - gas used by the validation, to pass into simulatePaymasterValidation.\\n * The node must also verify it doesn't use banned opcode, and that it doesn't reference storage outside the wallet's data\\n */\\n function simulateWalletValidation(UserOperation calldata userOp) external returns (uint gasUsedByPayForSelfOp){\\n require(msg.sender == address(0), \\\"must be called off-chain with from=zero-addr\\\");\\n (uint requiredPreFund, PaymentMode paymentMode) = getPaymentInfo(userOp);\\n (gasUsedByPayForSelfOp,) = _validateWalletPrepayment(0, userOp, requiredPreFund, paymentMode);\\n }\\n\\n function getPaymentInfo(UserOperation calldata userOp) internal view returns (uint requiredPrefund, PaymentMode paymentMode) {\\n requiredPrefund = userOp.requiredPreFund(perOpOverhead);\\n if (userOp.hasPaymaster()) {\\n paymentMode = PaymentMode.paymasterStake;\\n } else if (isStaked(userOp.getSender(), requiredPrefund, 0)) {\\n paymentMode = PaymentMode.walletStake;\\n } else {\\n paymentMode = PaymentMode.walletEth;\\n }\\n }\\n\\n /**\\n * Simulate a call to paymaster.verifyPaymasterUserOp\\n * do nothing if has no paymaster.\\n * @param userOp the user operation to validate.\\n * @param gasUsedByPayForSelfOp - the gas returned by simulateWalletValidation, as these 2 calls should share\\n * the same userOp.validationGas quota.\\n * The node must also verify it doesn't use banned opcode, and that it doesn't reference storage outside the paymaster's data\\n */\\n function simulatePaymasterValidation(UserOperation calldata userOp, uint gasUsedByPayForSelfOp) external view returns (bytes memory context, uint gasUsedByPayForOp){\\n (uint requiredPreFund, PaymentMode paymentMode) = getPaymentInfo(userOp);\\n if (paymentMode != PaymentMode.paymasterStake) {\\n return (\\\"\\\", 0);\\n }\\n return _validatePaymasterPrepayment(0, userOp, requiredPreFund, gasUsedByPayForSelfOp);\\n }\\n\\n // get the sender address, or use \\\"create2\\\" to create it.\\n // note that the gas allocation for this creation is deterministic (by the size of callData),\\n // so it is not checked on-chain, and adds to the gas used by verifyUserOp\\n function _createSenderIfNeeded(UserOperation calldata op) internal {\\n if (op.initCode.length != 0) {\\n //its a create operation. run the create2\\n // note that we're still under the gas limit of validate, so probably\\n // this create2 creates a proxy account.\\n // appending signer makes the request unique, so no one else can make this request.\\n //nonce is meaningless during create, so we re-purpose it as salt\\n address sender1 = ICreate2Deployer(create2factory).deploy(op.initCode, bytes32(op.nonce));\\n require(sender1 != address(0), \\\"create2 failed\\\");\\n require(sender1 == op.getSender(), \\\"sender doesn't match create2 address\\\");\\n }\\n }\\n\\n //get counterfactual sender address.\\n // use the initCode and salt in the UserOperation tot create this sender contract\\n function getSenderAddress(bytes memory initCode, uint _salt) public view returns (address) {\\n bytes32 hash = keccak256(\\n abi.encodePacked(\\n bytes1(0xff),\\n address(create2factory),\\n _salt,\\n keccak256(initCode)\\n )\\n );\\n\\n // NOTE: cast last 20 bytes of hash to address\\n return address(uint160(uint256(hash)));\\n }\\n\\n //call wallet.verifyUserOp, and validate that it paid as needed.\\n // return actual value sent from wallet to \\\"this\\\"\\n function _validateWalletPrepayment(uint opIndex, UserOperation calldata op, uint requiredPrefund, PaymentMode paymentMode) internal returns (uint gasUsedByPayForSelfOp, uint prefund) {\\n uint preGas = gasleft();\\n _createSenderIfNeeded(op);\\n uint preBalance = address(this).balance;\\n uint requiredEthPrefund = 0;\\n if (paymentMode == PaymentMode.walletEth) {\\n requiredEthPrefund = requiredPrefund;\\n } else if (paymentMode == PaymentMode.walletStake) {\\n _prefundFromSender(op, requiredPrefund);\\n } else {\\n // paymaster pays in handlePostOp\\n }\\n try IWallet(op.getSender()).verifyUserOp{gas : op.verificationGas}(op, requiredEthPrefund) {\\n } catch Error(string memory revertReason) {\\n revert FailedOp(opIndex, address(0), revertReason);\\n } catch {\\n revert FailedOp(opIndex, address(0), \\\"\\\");\\n }\\n uint actualEthPrefund = address(this).balance - preBalance;\\n\\n if (paymentMode == PaymentMode.walletEth) {\\n if (actualEthPrefund < requiredEthPrefund) {\\n revert FailedOp(opIndex, address(0), \\\"wallet didn't pay prefund\\\");\\n }\\n prefund = actualEthPrefund;\\n } else if (paymentMode == PaymentMode.walletStake) {\\n if (actualEthPrefund != 0) {\\n revert FailedOp(opIndex, address(0), \\\"using wallet stake but wallet paid eth\\\");\\n }\\n prefund = requiredPrefund;\\n } else {\\n if (actualEthPrefund != 0) {\\n revert FailedOp(opIndex, address(0), \\\"has paymaster but wallet paid\\\");\\n }\\n prefund = requiredPrefund;\\n }\\n\\n gasUsedByPayForSelfOp = preGas - gasleft();\\n }\\n\\n //validate paymaster.verifyPaymasterUserOp\\n function _validatePaymasterPrepayment(uint opIndex, UserOperation calldata op, uint requiredPreFund, uint gasUsedByPayForSelfOp) internal view returns (bytes memory context, uint gasUsedByPayForOp) {\\n uint preGas = gasleft();\\n if (!isValidStake(op, requiredPreFund)) {\\n revert FailedOp(opIndex, op.paymaster, \\\"not enough stake\\\");\\n }\\n //no pre-pay from paymaster\\n uint gas = op.verificationGas - gasUsedByPayForSelfOp;\\n try IPaymaster(op.paymaster).verifyPaymasterUserOp{gas : gas}(op, requiredPreFund) returns (bytes memory _context){\\n context = _context;\\n } catch Error(string memory revertReason) {\\n revert FailedOp(opIndex, op.paymaster, revertReason);\\n } catch {\\n revert FailedOp(opIndex, op.paymaster, \\\"\\\");\\n }\\n gasUsedByPayForOp = preGas - gasleft();\\n }\\n\\n function _validatePrepayment(uint opIndex, UserOperation calldata userOp) private returns (uint prefund, PaymentMode paymentMode, bytes memory context){\\n\\n uint preGas = gasleft();\\n uint gasUsedByPayForSelfOp;\\n uint requiredPreFund;\\n (requiredPreFund, paymentMode) = getPaymentInfo(userOp);\\n\\n (gasUsedByPayForSelfOp, prefund) = _validateWalletPrepayment(opIndex, userOp, requiredPreFund, paymentMode);\\n\\n uint gasUsedByPayForOp = 0;\\n if (paymentMode == PaymentMode.paymasterStake) {\\n (context, gasUsedByPayForOp) = _validatePaymasterPrepayment(opIndex, userOp, requiredPreFund, gasUsedByPayForSelfOp);\\n } else {\\n context = \\\"\\\";\\n }\\n uint gasUsed = preGas - gasleft();\\n\\n if (userOp.verificationGas < gasUsed) {\\n revert FailedOp(opIndex, userOp.paymaster, \\\"Used more than verificationGas\\\");\\n }\\n }\\n\\n function getPaymastersStake(address[] calldata paymasters) external view returns (uint[] memory _stakes) {\\n _stakes = new uint[](paymasters.length);\\n for (uint i = 0; i < paymasters.length; i++) {\\n _stakes[i] = stakes[paymasters[i]].stake;\\n }\\n }\\n\\n function handlePostOp(IPaymaster.PostOpMode mode, UserOperation calldata op, bytes memory context, uint actualGas, uint prefund, PaymentMode paymentMode) private returns (uint actualGasCost) {\\n uint preGas = gasleft();\\n uint gasPrice = UserOperationLib.gasPrice(op);\\n actualGasCost = actualGas * gasPrice;\\n if (paymentMode != PaymentMode.paymasterStake) {\\n if (prefund < actualGasCost) {\\n revert (\\\"wallet prefund below actualGasCost\\\");\\n }\\n uint refund = prefund - actualGasCost;\\n if (paymentMode == PaymentMode.walletStake) {\\n _refundSenderStake(op, refund);\\n } else {\\n _refundSender(op, refund);\\n }\\n } else {\\n if (context.length > 0) {\\n //if paymaster.postOp reverts:\\n // - emit a message (just for sake of debugging of this poor paymaster)\\n // - paymaster still pays (from its stake)\\n try IPaymaster(op.paymaster).postOp(mode, context, actualGasCost) {}\\n catch (bytes memory errdata) {\\n emit PaymasterPostOpFailed(op.getSender(), op.paymaster, op.nonce, errdata);\\n }\\n }\\n //paymaster pays for full gas, including for postOp (and revert event)\\n actualGas += preGas - gasleft();\\n actualGasCost = actualGas * gasPrice;\\n //paymaster balance known to be high enough, and to be locked for this block\\n stakes[op.paymaster].stake -= uint96(actualGasCost);\\n }\\n _emitLog(op, actualGasCost, gasPrice, mode == IPaymaster.PostOpMode.opSucceeded);\\n }\\n\\n function _emitLog(UserOperation calldata op, uint actualGasCost, uint gasPrice, bool success) internal {\\n emit UserOperationEvent(op.getSender(), op.paymaster, op.nonce, actualGasCost, gasPrice, success);\\n }\\n\\n function _prefundFromSender(UserOperation calldata userOp, uint requiredPrefund) internal {\\n stakes[userOp.getSender()].stake -= uint96(requiredPrefund);\\n }\\n\\n function _refundSender(UserOperation calldata userOp, uint refund) internal {\\n //NOTE: deliberately ignoring revert: wallet should accept refund.\\n bool sendOk = payable(userOp.getSender()).send(refund);\\n (sendOk);\\n }\\n function _refundSenderStake(UserOperation calldata userOp, uint refund) internal {\\n stakes[userOp.getSender()].stake += uint96(refund);\\n }\\n\\n function isValidStake(UserOperation calldata userOp, uint requiredPreFund) internal view returns (bool) {\\n return isPaymasterStaked(userOp.paymaster, PAYMASTER_STAKE + requiredPreFund);\\n }\\n\\n function isPaymasterStaked(address paymaster, uint stake) public view returns (bool) {\\n return isStaked(paymaster, stake, unstakeDelayBlocks);\\n }\\n\\n function isContractDeployed(address addr) external view returns (bool) {\\n bytes32 hash;\\n assembly {\\n hash := extcodehash(addr)\\n }\\n return hash != bytes32(0);\\n }\\n}\\n\\n\",\"keccak256\":\"0x8b15a6fcb66f95fc079400ff2b38de805405ce6c23c4bbbc1bcd24bb6cabefb0\",\"license\":\"GPL-3.0\"},\"contracts/IPaymaster.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.7;\\n\\nimport \\\"./UserOperation.sol\\\";\\n\\ninterface IPaymaster {\\n\\n enum PostOpMode {\\n opSucceeded, // user op succeeded\\n opReverted, // user op reverted. still has to pay for gas.\\n postOpReverted //user op succeeded, but caused postOp to revert. Now its a 2nd call, after user's op was deliberately reverted.\\n }\\n // payment validation: check if paymaster agree to pay (using its stake)\\n // revert to reject this request.\\n // actual payment is done after postOp is called, by deducting actual call cost form the paymaster's stake.\\n // @param userOp the user operation\\n // @param maxcost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\\n // @returns context value to send to a postOp\\n // zero length to signify postOp is not required.\\n function verifyPaymasterUserOp(UserOperation calldata userOp, uint maxcost) external view returns (bytes memory context);\\n\\n // post-operation handler.\\n // @param mode\\n // opSucceeded - user operation succeeded.\\n // opReverted - user op reverted. still has to pay for gas.\\n // postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\\n // Now this is the 2nd call, after user's op was deliberately reverted.\\n // @param context - the context value returned by verifyPaymasterUserOp\\n // @param actualGasCost - actual gas used so far (without this postOp call).\\n function postOp(PostOpMode mode, bytes calldata context, uint actualGasCost) external;\\n}\\n\",\"keccak256\":\"0xef51907c5520d22e74cc7804b30634cdc6d2cbf2fe96b77d0b6785a53c4545a5\",\"license\":\"GPL-3.0\"},\"contracts/IWallet.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.7;\\n\\nimport \\\"./UserOperation.sol\\\";\\n\\ninterface IWallet {\\n\\n // validate user's signature and nonce\\n // @param requiredPrefund how much this wallet should pre-fund the transaction.\\n // @note that after execution, the excess is sent back to the wallet.\\n // @note if requiredPrefund is zero, the wallet MUST NOT send anything (the paymaster pays)\\n function verifyUserOp(UserOperation calldata userOp, uint requiredPrefund) external;\\n}\\n\",\"keccak256\":\"0x29f98a4e6033cd10007dcc9b569fda950413cc91d8560a67f20a35e8185c9228\",\"license\":\"GPL-3.0\"},\"contracts/StakeManager.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0-only\\npragma solidity ^0.8;\\n\\nimport \\\"hardhat/console.sol\\\";\\n\\ncontract StakeManager {\\n\\n /// minimum number of blocks to after 'unlock' before amount can be withdrawn.\\n uint32 immutable public unstakeDelayBlocks;\\n\\n constructor(uint32 _unstakeDelayBlocks) {\\n unstakeDelayBlocks = _unstakeDelayBlocks;\\n }\\n\\n event StakeAdded(\\n address indexed paymaster,\\n uint256 totalStake,\\n uint256 unstakeDelayBlocks\\n );\\n\\n /// Emitted once a stake is scheduled for withdrawal\\n event StakeUnlocking(\\n address indexed paymaster,\\n uint256 withdrawBlock\\n );\\n\\n event StakeWithdrawn(\\n address indexed paymaster,\\n address withdrawAddress,\\n uint256 amount\\n );\\n\\n /// @param stake - amount of ether staked for this paymaster\\n /// @param withdrawStake - once 'unlocked' the value is no longer staked.\\n /// @param withdrawBlock - first block number 'withdraw' will be callable, or zero if the unlock has not been called\\n struct StakeInfo {\\n uint96 stake;\\n uint32 unstakeDelayBlocks;\\n uint96 withdrawStake;\\n uint32 withdrawBlock;\\n }\\n\\n /// maps relay managers to their stakes\\n mapping(address => StakeInfo) public stakes;\\n\\n function getStakeInfo(address paymaster) external view returns (StakeInfo memory stakeInfo) {\\n return stakes[paymaster];\\n }\\n\\n /**\\n * add a deposit (just like stake, but with lock=0\\n * cancel any pending unlock\\n */\\n function addDeposit() external payable {\\n addStake(0);\\n }\\n\\n //add deposit to another account (doesn't change lock status)\\n function addDepositTo(address target) external payable {\\n stakes[target].stake += uint96(msg.value);\\n }\\n\\n /**\\n * add stake value for this paymaster.\\n * cancel any pending unlock\\n */\\n function addStake(uint32 _unstakeDelayBlocks) public payable {\\n require(_unstakeDelayBlocks >= stakes[msg.sender].unstakeDelayBlocks, \\\"cannot decrease unstake blocks\\\");\\n uint96 stake = uint96(stakes[msg.sender].stake + msg.value + stakes[msg.sender].withdrawStake);\\n stakes[msg.sender] = StakeInfo(\\n stake,\\n _unstakeDelayBlocks,\\n 0,\\n 0);\\n emit StakeAdded(msg.sender, stake, _unstakeDelayBlocks);\\n }\\n\\n function unlockStake() external {\\n StakeInfo storage info = stakes[msg.sender];\\n require(info.withdrawBlock == 0, \\\"already pending\\\");\\n require(info.stake != 0 && info.unstakeDelayBlocks != 0, \\\"no stake to unlock\\\");\\n uint32 withdrawBlock = uint32(block.number) + info.unstakeDelayBlocks;\\n info.withdrawBlock = withdrawBlock;\\n info.withdrawStake = info.stake;\\n info.stake = 0;\\n emit StakeUnlocking(msg.sender, withdrawBlock);\\n }\\n\\n function withdrawStake(address payable withdrawAddress) external {\\n StakeInfo memory info = stakes[msg.sender];\\n if (info.unstakeDelayBlocks != 0) {\\n require(info.withdrawStake > 0, \\\"no unlocked stake\\\");\\n require(info.withdrawBlock <= block.number, \\\"Withdrawal is not due\\\");\\n }\\n uint256 amount = info.withdrawStake + info.stake;\\n stakes[msg.sender] = StakeInfo(0, info.unstakeDelayBlocks, 0, 0);\\n withdrawAddress.transfer(amount);\\n emit StakeWithdrawn(msg.sender, withdrawAddress, amount);\\n }\\n\\n function isStaked(address paymaster, uint requiredStake, uint requiredDelayBlocks) public view returns (bool) {\\n StakeInfo memory stakeInfo = stakes[paymaster];\\n return stakeInfo.stake >= requiredStake && stakeInfo.unstakeDelayBlocks >= requiredDelayBlocks;\\n }\\n}\\n\",\"keccak256\":\"0x238f903aceaaa89fd289d99c16ff660b6f911837f50ccf3fc3bb94653024b1aa\",\"license\":\"GPL-3.0-only\"},\"contracts/UserOperation.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.7;\\n\\nimport \\\"hardhat/console.sol\\\";\\n\\n struct UserOperation {\\n\\n address sender;\\n uint256 nonce;\\n bytes initCode;\\n bytes callData;\\n uint callGas;\\n uint verificationGas;\\n uint preVerificationGas;\\n uint maxFeePerGas;\\n uint maxPriorityFeePerGas;\\n address paymaster;\\n bytes paymasterData;\\n bytes signature;\\n }\\n\\nlibrary UserOperationLib {\\n\\n function getSender(UserOperation calldata userOp) internal view returns (address ret) {\\n assembly {ret := calldataload(userOp)}\\n }\\n\\n //relayer/miner might submit the TX with higher priorityFee, but the user should not\\n // pay above what he signed for.\\n function gasPrice(UserOperation calldata userOp) internal view returns (uint) {\\n unchecked {\\n return min(userOp.maxFeePerGas, userOp.maxPriorityFeePerGas + block.basefee);\\n }\\n }\\n\\n function requiredGas(UserOperation calldata userOp) internal pure returns (uint) {\\n unchecked {\\n return userOp.callGas + userOp.verificationGas + userOp.preVerificationGas;\\n }\\n }\\n\\n function requiredPreFund(UserOperation calldata userOp, uint overhead) internal view returns (uint prefund) {\\n return (requiredGas(userOp) + overhead) * gasPrice(userOp);\\n }\\n\\n function hasPaymaster(UserOperation calldata userOp) internal pure returns (bool) {\\n return userOp.paymaster != address(0);\\n }\\n\\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\\n //lighter signature scheme. must match UserOp.ts#packUserOp\\n bytes calldata sig = userOp.signature;\\n assembly {\\n let ofs := userOp\\n let len := sub(sub(sig.offset, ofs), 32)\\n ret := mload(0x40)\\n mstore(0x40, add(ret, add(len, 32)))\\n mstore(ret, len)\\n calldatacopy(add(ret, 32), ofs, len)\\n }\\n return ret;\\n\\n //TODO: eip712-style ?\\n return abi.encode(\\n userOp.sender,\\n userOp.nonce,\\n keccak256(userOp.initCode),\\n keccak256(userOp.callData),\\n userOp.callGas,\\n userOp.verificationGas,\\n userOp.preVerificationGas,\\n userOp.maxFeePerGas,\\n userOp.maxPriorityFeePerGas,\\n userOp.paymaster,\\n keccak256(userOp.paymasterData)\\n );\\n }\\n\\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\\n return keccak256(abi.encodePacked(\\\"\\\\x19Ethereum Signed Message:\\\\n32\\\",\\n keccak256(pack(userOp))));\\n }\\n\\n function min(uint a, uint b) internal pure returns (uint) {\\n return a < b ? a : b;\\n }\\n}\\n\",\"keccak256\":\"0x7ea8383b9bbd8cfa5a96f59e1f37c20a681daa798b80d67eb52ade3c53f3ea30\",\"license\":\"GPL-3.0\"},\"contracts/samples/SimpleWallet.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.7;\\n\\nimport \\\"../IWallet.sol\\\";\\nimport \\\"../EntryPoint.sol\\\";\\n\\nimport \\\"hardhat/console.sol\\\";\\n\\n//minimal wallet\\n// this is sample minimal wallet.\\n// has execute, eth handling methods\\n// has a single signer that can send requests through the entryPoint.\\ncontract SimpleWallet is IWallet {\\n using UserOperationLib for UserOperation;\\n struct OwnerNonce {\\n uint96 nonce;\\n address owner;\\n }\\n OwnerNonce ownerNonce;\\n EntryPoint public entryPoint;\\n\\n function nonce() public view returns (uint) {\\n return ownerNonce.nonce;\\n }\\n\\n function owner() public view returns(address) {\\n return ownerNonce.owner;\\n }\\n\\n event EntryPointChanged(EntryPoint oldEntryPoint, EntryPoint newEntryPoint);\\n\\n receive() external payable {}\\n\\n constructor(EntryPoint _entryPoint, address _owner) {\\n entryPoint = _entryPoint;\\n ownerNonce.owner = _owner;\\n }\\n\\n modifier onlyOwner() {\\n _onlyOwner();\\n _;\\n }\\n\\n function _onlyOwner() internal view {\\n //directly from EOA owner, or through the entryPoint (which gets redirected through execFromEntryPoint)\\n require(msg.sender == ownerNonce.owner || msg.sender == address(this), \\\"only owner\\\");\\n }\\n\\n function transfer(address payable dest, uint amount) external onlyOwner {\\n dest.transfer(amount);\\n }\\n\\n function exec(address dest, uint value, bytes calldata func) external onlyOwner {\\n _call(dest, value, func);\\n }\\n\\n function updateEntryPoint(EntryPoint _entryPoint) external onlyOwner {\\n emit EntryPointChanged(entryPoint, _entryPoint);\\n entryPoint = _entryPoint;\\n }\\n\\n function _requireFromEntryPoint() internal view {\\n require(msg.sender == address(entryPoint), \\\"wallet: not from EntryPoint\\\");\\n }\\n\\n function verifyUserOp(UserOperation calldata userOp, uint requiredPrefund) external override {\\n _requireFromEntryPoint();\\n _validateSignature(userOp);\\n _validateAndIncrementNonce(userOp);\\n _payPrefund(requiredPrefund);\\n }\\n\\n function _payPrefund(uint requiredPrefund) internal {\\n if (requiredPrefund != 0) {\\n (bool success) = payable(msg.sender).send(requiredPrefund);\\n (success);\\n //ignore failure (its EntryPoint's job to verify, not wallet.)\\n }\\n }\\n\\n //called by entryPoint, only after verifyUserOp succeeded.\\n function execFromEntryPoint(address dest, uint value, bytes calldata func) external {\\n _requireFromEntryPoint();\\n _call(dest, value, func);\\n }\\n\\n function _validateAndIncrementNonce(UserOperation calldata userOp) internal {\\n //during construction, the \\\"nonce\\\" field hold the salt.\\n // if we assert it is zero, then we allow only a single wallet per owner.\\n if (userOp.initCode.length == 0) {\\n require(ownerNonce.nonce++ == userOp.nonce, \\\"wallet: invalid nonce\\\");\\n }\\n }\\n\\n function _validateSignature(UserOperation calldata userOp) internal view {\\n\\n bytes32 hash = userOp.hash();\\n (bytes32 r, bytes32 s, uint8 v) = _rsv(userOp.signature);\\n\\n require(owner() == _ecrecover(hash, v, r, s), \\\"wallet: wrong signature\\\");\\n }\\n\\n function _rsv(bytes calldata signature) internal pure returns (bytes32 r, bytes32 s, uint8 v) {\\n\\n require(signature.length == 65, \\\"wallet: invalid signature length\\\");\\n assembly {\\n r := calldataload(signature.offset)\\n s := calldataload(add(signature.offset, 0x20))\\n v := byte(0, calldataload(add(signature.offset, 0x40)))\\n }\\n }\\n\\n function _ecrecover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address) {\\n return ecrecover(hash, v, r, s);\\n }\\n\\n function _call(address sender, uint value, bytes memory data) internal {\\n (bool success, bytes memory result) = sender.call{value : value}(data);\\n if (!success) {\\n assembly {\\n revert(result, add(result, 32))\\n }\\n }\\n }\\n\\n function addDeposit() public payable {\\n entryPoint.addDeposit{value : msg.value}();\\n }\\n\\n function withdrawDeposit(address payable withdrawAddress) public {\\n entryPoint.withdrawStake(withdrawAddress);\\n }\\n}\\n\",\"keccak256\":\"0xf3afea609dd9502a958ce8dbbef6fd2271663c750d356cf911a082f2fa4e7d4b\",\"license\":\"GPL-3.0\"},\"hardhat/console.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity >= 0.4.22 <0.9.0;\\n\\nlibrary console {\\n\\taddress constant CONSOLE_ADDRESS = address(0x000000000000000000636F6e736F6c652e6c6f67);\\n\\n\\tfunction _sendLogPayload(bytes memory payload) private view {\\n\\t\\tuint256 payloadLength = payload.length;\\n\\t\\taddress consoleAddress = CONSOLE_ADDRESS;\\n\\t\\tassembly {\\n\\t\\t\\tlet payloadStart := add(payload, 32)\\n\\t\\t\\tlet r := staticcall(gas(), consoleAddress, payloadStart, payloadLength, 0, 0)\\n\\t\\t}\\n\\t}\\n\\n\\tfunction log() internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log()\\\"));\\n\\t}\\n\\n\\tfunction logInt(int p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(int)\\\", p0));\\n\\t}\\n\\n\\tfunction logUint(uint p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint)\\\", p0));\\n\\t}\\n\\n\\tfunction logString(string memory p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string)\\\", p0));\\n\\t}\\n\\n\\tfunction logBool(bool p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool)\\\", p0));\\n\\t}\\n\\n\\tfunction logAddress(address p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes(bytes memory p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes1(bytes1 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes1)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes2(bytes2 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes2)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes3(bytes3 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes3)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes4(bytes4 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes4)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes5(bytes5 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes5)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes6(bytes6 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes6)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes7(bytes7 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes7)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes8(bytes8 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes8)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes9(bytes9 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes9)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes10(bytes10 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes10)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes11(bytes11 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes11)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes12(bytes12 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes12)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes13(bytes13 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes13)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes14(bytes14 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes14)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes15(bytes15 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes15)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes16(bytes16 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes16)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes17(bytes17 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes17)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes18(bytes18 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes18)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes19(bytes19 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes19)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes20(bytes20 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes20)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes21(bytes21 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes21)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes22(bytes22 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes22)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes23(bytes23 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes23)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes24(bytes24 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes24)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes25(bytes25 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes25)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes26(bytes26 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes26)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes27(bytes27 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes27)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes28(bytes28 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes28)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes29(bytes29 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes29)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes30(bytes30 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes30)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes31(bytes31 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes31)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes32(bytes32 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes32)\\\", p0));\\n\\t}\\n\\n\\tfunction log(uint p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint)\\\", p0));\\n\\t}\\n\\n\\tfunction log(string memory p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string)\\\", p0));\\n\\t}\\n\\n\\tfunction log(bool p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool)\\\", p0));\\n\\t}\\n\\n\\tfunction log(address p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address)\\\", p0));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(address p0, address p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n}\\n\",\"keccak256\":\"0x72b6a1d297cd3b033d7c2e4a7e7864934bb767db6453623f1c3082c6534547f4\",\"license\":\"MIT\"}},\"version\":1}", - "bytecode": "0x608060405234801561001057600080fd5b50604051610aed380380610aed83398101604081905261002f91610077565b600180546001600160a01b039384166001600160a01b031990911617905560008054919092166c01000000000000000000000000026001600160601b039091161790556100c9565b6000806040838503121561008a57600080fd5b8251610095816100b1565b60208401519092506100a6816100b1565b809150509250929050565b6001600160a01b03811681146100c657600080fd5b50565b610a15806100d86000396000f3fe6080604052600436106100955760003560e01c80638da5cb5b116100595780638da5cb5b1461012b578063a9059cbb14610169578063affed0e014610189578063b0d691fe146101b0578063fbfb39e0146101d057600080fd5b80630565bb67146100a15780631b71bb6e146100c35780634a58db19146100e357806351e41700146100eb57806380c5c7d01461010b57600080fd5b3661009c57005b600080fd5b3480156100ad57600080fd5b506100c16100bc366004610846565b6101f0565b005b3480156100cf57600080fd5b506100c16100de3660046107f6565b61023f565b6100c16102b0565b3480156100f757600080fd5b506100c16101063660046107f6565b61031b565b34801561011757600080fd5b506100c1610126366004610846565b610362565b34801561013757600080fd5b50600054600160601b90046001600160a01b03165b6040516001600160a01b0390911681526020015b60405180910390f35b34801561017557600080fd5b506100c161018436600461081a565b61036a565b34801561019557600080fd5b506000546001600160601b0316604051908152602001610160565b3480156101bc57600080fd5b5060015461014c906001600160a01b031681565b3480156101dc57600080fd5b506100c16101eb3660046108cf565b6103ad565b6101f86103d4565b610239848484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061043392505050565b50505050565b6102476103d4565b600154604080516001600160a01b03928316815291831660208301527f450909c1478d09248269d4ad4fa8cba61ca3f50faed58c7aedefa51c7f62b83a910160405180910390a1600180546001600160a01b0319166001600160a01b0392909216919091179055565b600160009054906101000a90046001600160a01b03166001600160a01b0316634a58db19346040518263ffffffff1660e01b81526004016000604051808303818588803b15801561030057600080fd5b505af1158015610314573d6000803e3d6000fd5b5050505050565b60015460405163611d2e7560e11b81526001600160a01b0383811660048301529091169063c23a5cea90602401600060405180830381600087803b15801561030057600080fd5b6101f86104a2565b6103726103d4565b6040516001600160a01b0383169082156108fc029083906000818181858888f193505050501580156103a8573d6000803e3d6000fd5b505050565b6103b56104a2565b6103be826104fc565b6103c7826105ae565b6103d081610658565b5050565b600054600160601b90046001600160a01b03163314806103f357503330145b6104315760405162461bcd60e51b815260206004820152600a60248201526937b7363c9037bbb732b960b11b60448201526064015b60405180910390fd5b565b600080846001600160a01b0316848460405161044f919061090c565b60006040518083038185875af1925050503d806000811461048c576040519150601f19603f3d011682016040523d82523d6000602084013e610491565b606091505b509150915081610314576020810181fd5b6001546001600160a01b031633146104315760405162461bcd60e51b815260206004820152601b60248201527f77616c6c65743a206e6f742066726f6d20456e747279506f696e7400000000006044820152606401610428565b600061050782610680565b90506000808061052361051e610160870187610947565b6106e3565b9250925092506105358482858561074f565b6001600160a01b03166105586000546001600160a01b03600160601b9091041690565b6001600160a01b0316146103145760405162461bcd60e51b815260206004820152601760248201527f77616c6c65743a2077726f6e67207369676e61747572650000000000000000006044820152606401610428565b6105bb6040820182610947565b1515905061065557600080546020830135916001600160601b0390911690806105e383610995565b91906101000a8154816001600160601b0302191690836001600160601b031602179055506001600160601b0316146106555760405162461bcd60e51b815260206004820152601560248201527477616c6c65743a20696e76616c6964206e6f6e636560581b6044820152606401610428565b50565b801561065557604051600090339083156108fc0290849084818181858888f150505050505050565b600061068b826107b7565b80516020918201206040517f19457468657265756d205369676e6564204d6573736167653a0a33320000000092810192909252603c820152605c01604051602081830303815290604052805190602001209050919050565b60008080604184146107375760405162461bcd60e51b815260206004820181905260248201527f77616c6c65743a20696e76616c6964207369676e6174757265206c656e6774686044820152606401610428565b50508235936020840135936040013560001a92509050565b6040805160008082526020820180845287905260ff861692820192909252606081018490526080810183905260019060a0016020604051602081039080840390855afa1580156107a3573d6000803e3d6000fd5b5050604051601f1901519695505050505050565b60603660006107ca610160850185610947565b915091508360208184030360405194506020810185016040528085528082602087013750505050919050565b60006020828403121561080857600080fd5b8135610813816109ca565b9392505050565b6000806040838503121561082d57600080fd5b8235610838816109ca565b946020939093013593505050565b6000806000806060858703121561085c57600080fd5b8435610867816109ca565b935060208501359250604085013567ffffffffffffffff8082111561088b57600080fd5b818701915087601f83011261089f57600080fd5b8135818111156108ae57600080fd5b8860208285010111156108c057600080fd5b95989497505060200194505050565b600080604083850312156108e257600080fd5b823567ffffffffffffffff8111156108f957600080fd5b8301610180818603121561083857600080fd5b6000825160005b8181101561092d5760208186018101518583015201610913565b8181111561093c576000828501525b509190910192915050565b6000808335601e1984360301811261095e57600080fd5b83018035915067ffffffffffffffff82111561097957600080fd5b60200191503681900382131561098e57600080fd5b9250929050565b60006001600160601b03808316818114156109c057634e487b7160e01b600052601160045260246000fd5b6001019392505050565b6001600160a01b038116811461065557600080fdfea264697066735822122060a95252b25b23dd208aa04a5a7d75efffd9ee1f7980d087a2ac978cfed715bd64736f6c63430008070033", - "deployedBytecode": "0x6080604052600436106100955760003560e01c80638da5cb5b116100595780638da5cb5b1461012b578063a9059cbb14610169578063affed0e014610189578063b0d691fe146101b0578063fbfb39e0146101d057600080fd5b80630565bb67146100a15780631b71bb6e146100c35780634a58db19146100e357806351e41700146100eb57806380c5c7d01461010b57600080fd5b3661009c57005b600080fd5b3480156100ad57600080fd5b506100c16100bc366004610846565b6101f0565b005b3480156100cf57600080fd5b506100c16100de3660046107f6565b61023f565b6100c16102b0565b3480156100f757600080fd5b506100c16101063660046107f6565b61031b565b34801561011757600080fd5b506100c1610126366004610846565b610362565b34801561013757600080fd5b50600054600160601b90046001600160a01b03165b6040516001600160a01b0390911681526020015b60405180910390f35b34801561017557600080fd5b506100c161018436600461081a565b61036a565b34801561019557600080fd5b506000546001600160601b0316604051908152602001610160565b3480156101bc57600080fd5b5060015461014c906001600160a01b031681565b3480156101dc57600080fd5b506100c16101eb3660046108cf565b6103ad565b6101f86103d4565b610239848484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061043392505050565b50505050565b6102476103d4565b600154604080516001600160a01b03928316815291831660208301527f450909c1478d09248269d4ad4fa8cba61ca3f50faed58c7aedefa51c7f62b83a910160405180910390a1600180546001600160a01b0319166001600160a01b0392909216919091179055565b600160009054906101000a90046001600160a01b03166001600160a01b0316634a58db19346040518263ffffffff1660e01b81526004016000604051808303818588803b15801561030057600080fd5b505af1158015610314573d6000803e3d6000fd5b5050505050565b60015460405163611d2e7560e11b81526001600160a01b0383811660048301529091169063c23a5cea90602401600060405180830381600087803b15801561030057600080fd5b6101f86104a2565b6103726103d4565b6040516001600160a01b0383169082156108fc029083906000818181858888f193505050501580156103a8573d6000803e3d6000fd5b505050565b6103b56104a2565b6103be826104fc565b6103c7826105ae565b6103d081610658565b5050565b600054600160601b90046001600160a01b03163314806103f357503330145b6104315760405162461bcd60e51b815260206004820152600a60248201526937b7363c9037bbb732b960b11b60448201526064015b60405180910390fd5b565b600080846001600160a01b0316848460405161044f919061090c565b60006040518083038185875af1925050503d806000811461048c576040519150601f19603f3d011682016040523d82523d6000602084013e610491565b606091505b509150915081610314576020810181fd5b6001546001600160a01b031633146104315760405162461bcd60e51b815260206004820152601b60248201527f77616c6c65743a206e6f742066726f6d20456e747279506f696e7400000000006044820152606401610428565b600061050782610680565b90506000808061052361051e610160870187610947565b6106e3565b9250925092506105358482858561074f565b6001600160a01b03166105586000546001600160a01b03600160601b9091041690565b6001600160a01b0316146103145760405162461bcd60e51b815260206004820152601760248201527f77616c6c65743a2077726f6e67207369676e61747572650000000000000000006044820152606401610428565b6105bb6040820182610947565b1515905061065557600080546020830135916001600160601b0390911690806105e383610995565b91906101000a8154816001600160601b0302191690836001600160601b031602179055506001600160601b0316146106555760405162461bcd60e51b815260206004820152601560248201527477616c6c65743a20696e76616c6964206e6f6e636560581b6044820152606401610428565b50565b801561065557604051600090339083156108fc0290849084818181858888f150505050505050565b600061068b826107b7565b80516020918201206040517f19457468657265756d205369676e6564204d6573736167653a0a33320000000092810192909252603c820152605c01604051602081830303815290604052805190602001209050919050565b60008080604184146107375760405162461bcd60e51b815260206004820181905260248201527f77616c6c65743a20696e76616c6964207369676e6174757265206c656e6774686044820152606401610428565b50508235936020840135936040013560001a92509050565b6040805160008082526020820180845287905260ff861692820192909252606081018490526080810183905260019060a0016020604051602081039080840390855afa1580156107a3573d6000803e3d6000fd5b5050604051601f1901519695505050505050565b60603660006107ca610160850185610947565b915091508360208184030360405194506020810185016040528085528082602087013750505050919050565b60006020828403121561080857600080fd5b8135610813816109ca565b9392505050565b6000806040838503121561082d57600080fd5b8235610838816109ca565b946020939093013593505050565b6000806000806060858703121561085c57600080fd5b8435610867816109ca565b935060208501359250604085013567ffffffffffffffff8082111561088b57600080fd5b818701915087601f83011261089f57600080fd5b8135818111156108ae57600080fd5b8860208285010111156108c057600080fd5b95989497505060200194505050565b600080604083850312156108e257600080fd5b823567ffffffffffffffff8111156108f957600080fd5b8301610180818603121561083857600080fd5b6000825160005b8181101561092d5760208186018101518583015201610913565b8181111561093c576000828501525b509190910192915050565b6000808335601e1984360301811261095e57600080fd5b83018035915067ffffffffffffffff82111561097957600080fd5b60200191503681900382131561098e57600080fd5b9250929050565b60006001600160601b03808316818114156109c057634e487b7160e01b600052601160045260246000fd5b6001019392505050565b6001600160a01b038116811461065557600080fdfea264697066735822122060a95252b25b23dd208aa04a5a7d75efffd9ee1f7980d087a2ac978cfed715bd64736f6c63430008070033", - "devdoc": { - "kind": "dev", - "methods": {}, - "version": 1 - }, - "userdoc": { - "kind": "user", - "methods": {}, - "version": 1 - }, - "storageLayout": { - "storage": [ - { - "astId": 2814, - "contract": "contracts/samples/SimpleWallet.sol:SimpleWallet", - "label": "ownerNonce", - "offset": 0, - "slot": "0", - "type": "t_struct(OwnerNonce)2811_storage" - }, - { - "astId": 2817, - "contract": "contracts/samples/SimpleWallet.sol:SimpleWallet", - "label": "entryPoint", - "offset": 0, - "slot": "1", - "type": "t_contract(EntryPoint)2231" - } - ], - "types": { - "t_address": { - "encoding": "inplace", - "label": "address", - "numberOfBytes": "20" - }, - "t_contract(EntryPoint)2231": { - "encoding": "inplace", - "label": "contract EntryPoint", - "numberOfBytes": "20" - }, - "t_struct(OwnerNonce)2811_storage": { - "encoding": "inplace", - "label": "struct SimpleWallet.OwnerNonce", - "members": [ - { - "astId": 2808, - "contract": "contracts/samples/SimpleWallet.sol:SimpleWallet", - "label": "nonce", - "offset": 0, - "slot": "0", - "type": "t_uint96" - }, - { - "astId": 2810, - "contract": "contracts/samples/SimpleWallet.sol:SimpleWallet", - "label": "owner", - "offset": 12, - "slot": "0", - "type": "t_address" - } - ], - "numberOfBytes": "32" - }, - "t_uint96": { - "encoding": "inplace", - "label": "uint96", - "numberOfBytes": "12" - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/TestCounter.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/TestCounter.json deleted file mode 100644 index 0dbb2ce013..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/TestCounter.json +++ /dev/null @@ -1,118 +0,0 @@ -{ - "address": "0x4B52ceEDE2e695CAeDBC1Cc8E7f9d5Ef18F0EeF5", - "abi": [ - { - "inputs": [], - "name": "count", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "counters", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "repeat", - "type": "uint256" - }, - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "name": "gasWaster", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } - ], - "args": [], - "solcInputHash": "9255faacf3ae4e81db1326413027bfa0", - "metadata": "{\"compiler\":{\"version\":\"0.8.7+commit.e28d00a7\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"name\":\"count\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"repeat\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"name\":\"gasWaster\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/test/TestCounter.sol\":\"TestCounter\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\",\"useLiteralContent\":true},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"contracts/IWallet.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.7;\\n\\nimport \\\"./UserOperation.sol\\\";\\n\\ninterface IWallet {\\n\\n // validate user's signature and nonce\\n // @param requiredPrefund how much this wallet should pre-fund the transaction.\\n // @note that after execution, the excess is sent back to the wallet.\\n // @note if requiredPrefund is zero, the wallet MUST NOT send anything (the paymaster pays)\\n function verifyUserOp(UserOperation calldata userOp, uint requiredPrefund) external;\\n}\\n\",\"keccak256\":\"0x29f98a4e6033cd10007dcc9b569fda950413cc91d8560a67f20a35e8185c9228\",\"license\":\"GPL-3.0\"},\"contracts/UserOperation.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.7;\\n\\nimport \\\"hardhat/console.sol\\\";\\n\\n struct UserOperation {\\n\\n address sender;\\n uint256 nonce;\\n bytes initCode;\\n bytes callData;\\n uint callGas;\\n uint verificationGas;\\n uint preVerificationGas;\\n uint maxFeePerGas;\\n uint maxPriorityFeePerGas;\\n address paymaster;\\n bytes paymasterData;\\n bytes signature;\\n }\\n\\nlibrary UserOperationLib {\\n\\n function getSender(UserOperation calldata userOp) internal view returns (address ret) {\\n assembly {ret := calldataload(userOp)}\\n }\\n\\n //relayer/miner might submit the TX with higher priorityFee, but the user should not\\n // pay above what he signed for.\\n function gasPrice(UserOperation calldata userOp) internal view returns (uint) {\\n unchecked {\\n return min(userOp.maxFeePerGas, userOp.maxPriorityFeePerGas + block.basefee);\\n }\\n }\\n\\n function requiredGas(UserOperation calldata userOp) internal pure returns (uint) {\\n unchecked {\\n return userOp.callGas + userOp.verificationGas + userOp.preVerificationGas;\\n }\\n }\\n\\n function requiredPreFund(UserOperation calldata userOp, uint overhead) internal view returns (uint prefund) {\\n return (requiredGas(userOp) + overhead) * gasPrice(userOp);\\n }\\n\\n function hasPaymaster(UserOperation calldata userOp) internal pure returns (bool) {\\n return userOp.paymaster != address(0);\\n }\\n\\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\\n //lighter signature scheme. must match UserOp.ts#packUserOp\\n bytes calldata sig = userOp.signature;\\n assembly {\\n let ofs := userOp\\n let len := sub(sub(sig.offset, ofs), 32)\\n ret := mload(0x40)\\n mstore(0x40, add(ret, add(len, 32)))\\n mstore(ret, len)\\n calldatacopy(add(ret, 32), ofs, len)\\n }\\n return ret;\\n\\n //TODO: eip712-style ?\\n return abi.encode(\\n userOp.sender,\\n userOp.nonce,\\n keccak256(userOp.initCode),\\n keccak256(userOp.callData),\\n userOp.callGas,\\n userOp.verificationGas,\\n userOp.preVerificationGas,\\n userOp.maxFeePerGas,\\n userOp.maxPriorityFeePerGas,\\n userOp.paymaster,\\n keccak256(userOp.paymasterData)\\n );\\n }\\n\\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\\n return keccak256(abi.encodePacked(\\\"\\\\x19Ethereum Signed Message:\\\\n32\\\",\\n keccak256(pack(userOp))));\\n }\\n\\n function min(uint a, uint b) internal pure returns (uint) {\\n return a < b ? a : b;\\n }\\n}\\n\",\"keccak256\":\"0x7ea8383b9bbd8cfa5a96f59e1f37c20a681daa798b80d67eb52ade3c53f3ea30\",\"license\":\"GPL-3.0\"},\"contracts/test/TestCounter.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.7;\\n\\nimport \\\"../UserOperation.sol\\\";\\nimport \\\"../IWallet.sol\\\";\\n\\n//sample \\\"receiver\\\" contract, for testing \\\"exec\\\" from wallet.\\ncontract TestCounter {\\n mapping(address => uint) public counters;\\n\\n function count() public {\\n counters[msg.sender] = counters[msg.sender] + 1;\\n\\n }\\n\\n //helper method to waste gas\\n // repeat - waste gas on writing storage in a loop\\n // junk - dynamic buffer to stress the function size.\\n mapping(uint => uint) xxx;\\n uint offset;\\n\\n function gasWaster(uint repeat, string calldata /*junk*/) external {\\n for (uint i = 1; i <= repeat; i++) {\\n offset++;\\n xxx[offset] = i;\\n }\\n }\\n}\",\"keccak256\":\"0xfa15d72740c6ba7c1aca1925e27774b3701a585e866960ca70460ae55e0ae7d3\",\"license\":\"GPL-3.0\"},\"hardhat/console.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity >= 0.4.22 <0.9.0;\\n\\nlibrary console {\\n\\taddress constant CONSOLE_ADDRESS = address(0x000000000000000000636F6e736F6c652e6c6f67);\\n\\n\\tfunction _sendLogPayload(bytes memory payload) private view {\\n\\t\\tuint256 payloadLength = payload.length;\\n\\t\\taddress consoleAddress = CONSOLE_ADDRESS;\\n\\t\\tassembly {\\n\\t\\t\\tlet payloadStart := add(payload, 32)\\n\\t\\t\\tlet r := staticcall(gas(), consoleAddress, payloadStart, payloadLength, 0, 0)\\n\\t\\t}\\n\\t}\\n\\n\\tfunction log() internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log()\\\"));\\n\\t}\\n\\n\\tfunction logInt(int p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(int)\\\", p0));\\n\\t}\\n\\n\\tfunction logUint(uint p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint)\\\", p0));\\n\\t}\\n\\n\\tfunction logString(string memory p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string)\\\", p0));\\n\\t}\\n\\n\\tfunction logBool(bool p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool)\\\", p0));\\n\\t}\\n\\n\\tfunction logAddress(address p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes(bytes memory p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes1(bytes1 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes1)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes2(bytes2 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes2)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes3(bytes3 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes3)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes4(bytes4 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes4)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes5(bytes5 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes5)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes6(bytes6 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes6)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes7(bytes7 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes7)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes8(bytes8 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes8)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes9(bytes9 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes9)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes10(bytes10 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes10)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes11(bytes11 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes11)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes12(bytes12 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes12)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes13(bytes13 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes13)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes14(bytes14 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes14)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes15(bytes15 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes15)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes16(bytes16 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes16)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes17(bytes17 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes17)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes18(bytes18 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes18)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes19(bytes19 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes19)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes20(bytes20 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes20)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes21(bytes21 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes21)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes22(bytes22 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes22)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes23(bytes23 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes23)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes24(bytes24 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes24)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes25(bytes25 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes25)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes26(bytes26 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes26)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes27(bytes27 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes27)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes28(bytes28 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes28)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes29(bytes29 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes29)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes30(bytes30 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes30)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes31(bytes31 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes31)\\\", p0));\\n\\t}\\n\\n\\tfunction logBytes32(bytes32 p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bytes32)\\\", p0));\\n\\t}\\n\\n\\tfunction log(uint p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint)\\\", p0));\\n\\t}\\n\\n\\tfunction log(string memory p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string)\\\", p0));\\n\\t}\\n\\n\\tfunction log(bool p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool)\\\", p0));\\n\\t}\\n\\n\\tfunction log(address p0) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address)\\\", p0));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(address p0, address p1) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address)\\\", p0, p1));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address)\\\", p0, p1, p2));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, uint p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,uint,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, string memory p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,string,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, bool p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,bool,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(uint p0, address p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(uint,address,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, uint p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,uint,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, string memory p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,string,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, bool p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,bool,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(string memory p0, address p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(string,address,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, uint p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,uint,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, string memory p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,string,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, bool p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,bool,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(bool p0, address p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(bool,address,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, uint p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,uint,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, string memory p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,string,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, bool p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,bool,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, uint p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,uint,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, string memory p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,string,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, bool p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,bool,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2, uint p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address,uint)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2, string memory p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address,string)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2, bool p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address,bool)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n\\tfunction log(address p0, address p1, address p2, address p3) internal view {\\n\\t\\t_sendLogPayload(abi.encodeWithSignature(\\\"log(address,address,address,address)\\\", p0, p1, p2, p3));\\n\\t}\\n\\n}\\n\",\"keccak256\":\"0x72b6a1d297cd3b033d7c2e4a7e7864934bb767db6453623f1c3082c6534547f4\",\"license\":\"MIT\"}},\"version\":1}", - "bytecode": "0x608060405234801561001057600080fd5b50610238806100206000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c806306661abd14610046578063a1b4689014610050578063be65ab8c14610063575b600080fd5b61004e610095565b005b61004e61005e36600461013d565b6100c2565b61008361007136600461010d565b60006020819052908152604090205481565b60405190815260200160405180910390f35b336000908152602081905260409020546100b09060016101b9565b33600090815260208190526040902055565b60015b83811161010757600280549060006100dc836101d1565b90915550506002546000908152600160205260409020819055806100ff816101d1565b9150506100c5565b50505050565b60006020828403121561011f57600080fd5b81356001600160a01b038116811461013657600080fd5b9392505050565b60008060006040848603121561015257600080fd5b83359250602084013567ffffffffffffffff8082111561017157600080fd5b818601915086601f83011261018557600080fd5b81358181111561019457600080fd5b8760208285010111156101a657600080fd5b6020830194508093505050509250925092565b600082198211156101cc576101cc6101ec565b500190565b60006000198214156101e5576101e56101ec565b5060010190565b634e487b7160e01b600052601160045260246000fdfea26469706673582212202705b7732e8fc4fb811ca9240189d156e252ec8b1aef99971c2fc2cdbeb336d764736f6c63430008070033", - "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100415760003560e01c806306661abd14610046578063a1b4689014610050578063be65ab8c14610063575b600080fd5b61004e610095565b005b61004e61005e36600461013d565b6100c2565b61008361007136600461010d565b60006020819052908152604090205481565b60405190815260200160405180910390f35b336000908152602081905260409020546100b09060016101b9565b33600090815260208190526040902055565b60015b83811161010757600280549060006100dc836101d1565b90915550506002546000908152600160205260409020819055806100ff816101d1565b9150506100c5565b50505050565b60006020828403121561011f57600080fd5b81356001600160a01b038116811461013657600080fd5b9392505050565b60008060006040848603121561015257600080fd5b83359250602084013567ffffffffffffffff8082111561017157600080fd5b818601915086601f83011261018557600080fd5b81358181111561019457600080fd5b8760208285010111156101a657600080fd5b6020830194508093505050509250925092565b600082198211156101cc576101cc6101ec565b500190565b60006000198214156101e5576101e56101ec565b5060010190565b634e487b7160e01b600052601160045260246000fdfea26469706673582212202705b7732e8fc4fb811ca9240189d156e252ec8b1aef99971c2fc2cdbeb336d764736f6c63430008070033", - "devdoc": { - "kind": "dev", - "methods": {}, - "version": 1 - }, - "userdoc": { - "kind": "user", - "methods": {}, - "version": 1 - }, - "storageLayout": { - "storage": [ - { - "astId": 3638, - "contract": "contracts/test/TestCounter.sol:TestCounter", - "label": "counters", - "offset": 0, - "slot": "0", - "type": "t_mapping(t_address,t_uint256)" - }, - { - "astId": 3658, - "contract": "contracts/test/TestCounter.sol:TestCounter", - "label": "xxx", - "offset": 0, - "slot": "1", - "type": "t_mapping(t_uint256,t_uint256)" - }, - { - "astId": 3660, - "contract": "contracts/test/TestCounter.sol:TestCounter", - "label": "offset", - "offset": 0, - "slot": "2", - "type": "t_uint256" - } - ], - "types": { - "t_address": { - "encoding": "inplace", - "label": "address", - "numberOfBytes": "20" - }, - "t_mapping(t_address,t_uint256)": { - "encoding": "mapping", - "key": "t_address", - "label": "mapping(address => uint256)", - "numberOfBytes": "32", - "value": "t_uint256" - }, - "t_mapping(t_uint256,t_uint256)": { - "encoding": "mapping", - "key": "t_uint256", - "label": "mapping(uint256 => uint256)", - "numberOfBytes": "32", - "value": "t_uint256" - }, - "t_uint256": { - "encoding": "inplace", - "label": "uint256", - "numberOfBytes": "32" - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/solcInputs/9255faacf3ae4e81db1326413027bfa0.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/solcInputs/9255faacf3ae4e81db1326413027bfa0.json deleted file mode 100644 index 5a05e3bbbe..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/kovan/solcInputs/9255faacf3ae4e81db1326413027bfa0.json +++ /dev/null @@ -1,86 +0,0 @@ -{ - "language": "Solidity", - "sources": { - "contracts/EntryPoint.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.7;\n\nimport \"./StakeManager.sol\";\nimport \"./UserOperation.sol\";\nimport \"./IWallet.sol\";\nimport \"./IPaymaster.sol\";\n\ninterface ICreate2Deployer {\n function deploy(bytes memory _initCode, bytes32 _salt) external returns (address);\n}\n\ncontract EntryPoint is StakeManager {\n\n using UserOperationLib for UserOperation;\n // paymaster locked stake\n // (actual stake should be higher, to cover actual call cost)\n uint256 constant PAYMASTER_STAKE = 1 ether;\n\n enum PaymentMode {\n paymasterStake, // if paymaster is set, use paymaster's stake to pay.\n walletStake, // wallet has enough stake to pay for request.\n walletEth // wallet has no stake. paying with eth.\n }\n\n uint public immutable perOpOverhead;\n address public immutable create2factory;\n\n event UserOperationEvent(address indexed sender, address indexed paymaster, uint nonce, uint actualGasCost, uint actualGasPrice, bool success);\n event UserOperationRevertReason(address indexed sender, uint nonce, bytes revertReason);\n\n event PaymasterPostOpFailed(address indexed sender, address indexed paymaster, uint nonce, bytes reason);\n\n //handleOps reverts with this error struct, to mark the offending op\n // NOTE: if simulateOp passes successfully, there should be no reason for handleOps to fail on it.\n // @param opIndex - index into the array of ops to the failed one (in simulateOp, this is always zero)\n // @param paymaster - if paymaster.verifyPaymasterUserOp fails, this will be the paymaster's address. if verifyUserOp failed,\n // this value will be zero (since it failed before accessing the paymaster)\n // @param reason - revert reason\n // only to aid troubleshooting of wallet/paymaster reverts\n error FailedOp(uint opIndex, address paymaster, string reason);\n\n constructor(address _create2factory, uint _perOpOverhead, uint32 _unstakeDelayBlocks) StakeManager(_unstakeDelayBlocks) {\n create2factory = _create2factory;\n perOpOverhead = _perOpOverhead;\n }\n\n receive() external payable {}\n\n /**\n * Execute the given UserOperation.\n * @param op the operation to execute\n * @param redeemer the contract to redeem the fee\n */\n function handleOp(UserOperation calldata op, address payable redeemer) public {\n\n uint preGas = gasleft();\n\n (uint256 prefund, PaymentMode paymentMode, bytes memory context) = _validatePrepayment(0, op);\n uint preOpGas = preGas - gasleft() + perOpOverhead;\n\n uint actualGasCost;\n\n try this.internalHandleOp(op, context, preOpGas, prefund, paymentMode) returns (uint _actualGasCost) {\n actualGasCost = _actualGasCost;\n } catch {\n uint actualGas = preGas - gasleft() + preOpGas;\n actualGasCost = handlePostOp(IPaymaster.PostOpMode.postOpReverted, op, context, actualGas, prefund, paymentMode);\n }\n\n redeem(redeemer, actualGasCost);\n }\n\n function redeem(address payable redeemer, uint amount) internal {\n redeemer.transfer(amount);\n }\n\n function handleOps(UserOperation[] calldata ops, address payable redeemer) public {\n\n uint opslen = ops.length;\n uint256[] memory preOpGas = new uint256[](opslen);\n bytes32[] memory contexts = new bytes32[](opslen);\n uint256[] memory prefunds = new uint256[](opslen);\n PaymentMode[] memory paymentModes = new PaymentMode[](opslen);\n\n for (uint i = 0; i < opslen; i++) {\n uint preGas = gasleft();\n UserOperation calldata op = ops[i];\n\n bytes memory context;\n bytes32 contextOffset;\n (prefunds[i], paymentModes[i], context) = _validatePrepayment(i, op);\n assembly {contextOffset := context}\n contexts[i] = contextOffset;\n preOpGas[i] = preGas - gasleft() + perOpOverhead;\n }\n\n uint collected = 0;\n\n for (uint i = 0; i < ops.length; i++) {\n uint preGas = gasleft();\n UserOperation calldata op = ops[i];\n bytes32 contextOffset = contexts[i];\n bytes memory context;\n assembly {context := contextOffset}\n uint preOpGasi = preOpGas[i];\n uint prefundi = prefunds[i];\n PaymentMode paymentModei = paymentModes[i];\n\n try this.internalHandleOp(op, context, preOpGasi, prefundi, paymentModei) returns (uint _actualGasCost) {\n collected += _actualGasCost;\n } catch {\n uint actualGas = preGas - gasleft() + preOpGasi;\n collected += handlePostOp(IPaymaster.PostOpMode.postOpReverted, op, context, actualGas, prefundi, paymentModei);\n }\n }\n\n redeem(redeemer, collected);\n }\n\n function internalHandleOp(UserOperation calldata op, bytes calldata context, uint preOpGas, uint prefund, PaymentMode paymentMode) external returns (uint actualGasCost) {\n uint preGas = gasleft();\n require(msg.sender == address(this));\n\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\n if (op.callData.length > 0) {\n\n (bool success,bytes memory result) = address(op.getSender()).call{gas : op.callGas}(op.callData);\n if (!success && result.length > 0) {\n emit UserOperationRevertReason(op.getSender(), op.nonce, result);\n mode = IPaymaster.PostOpMode.opReverted;\n }\n }\n\n uint actualGas = preGas - gasleft() + preOpGas;\n return handlePostOp(mode, op, context, actualGas, prefund, paymentMode);\n }\n\n /**\n * Simulate a call for wallet.verifyUserOp.\n * Call must not revert.\n * @return gasUsedByPayForSelfOp - gas used by the validation, to pass into simulatePaymasterValidation.\n * The node must also verify it doesn't use banned opcode, and that it doesn't reference storage outside the wallet's data\n */\n function simulateWalletValidation(UserOperation calldata userOp) external returns (uint gasUsedByPayForSelfOp){\n require(msg.sender == address(0), \"must be called off-chain with from=zero-addr\");\n (uint requiredPreFund, PaymentMode paymentMode) = getPaymentInfo(userOp);\n (gasUsedByPayForSelfOp,) = _validateWalletPrepayment(0, userOp, requiredPreFund, paymentMode);\n }\n\n function getPaymentInfo(UserOperation calldata userOp) internal view returns (uint requiredPrefund, PaymentMode paymentMode) {\n requiredPrefund = userOp.requiredPreFund(perOpOverhead);\n if (userOp.hasPaymaster()) {\n paymentMode = PaymentMode.paymasterStake;\n } else if (isStaked(userOp.getSender(), requiredPrefund, 0)) {\n paymentMode = PaymentMode.walletStake;\n } else {\n paymentMode = PaymentMode.walletEth;\n }\n }\n\n /**\n * Simulate a call to paymaster.verifyPaymasterUserOp\n * do nothing if has no paymaster.\n * @param userOp the user operation to validate.\n * @param gasUsedByPayForSelfOp - the gas returned by simulateWalletValidation, as these 2 calls should share\n * the same userOp.validationGas quota.\n * The node must also verify it doesn't use banned opcode, and that it doesn't reference storage outside the paymaster's data\n */\n function simulatePaymasterValidation(UserOperation calldata userOp, uint gasUsedByPayForSelfOp) external view returns (bytes memory context, uint gasUsedByPayForOp){\n (uint requiredPreFund, PaymentMode paymentMode) = getPaymentInfo(userOp);\n if (paymentMode != PaymentMode.paymasterStake) {\n return (\"\", 0);\n }\n return _validatePaymasterPrepayment(0, userOp, requiredPreFund, gasUsedByPayForSelfOp);\n }\n\n // get the sender address, or use \"create2\" to create it.\n // note that the gas allocation for this creation is deterministic (by the size of callData),\n // so it is not checked on-chain, and adds to the gas used by verifyUserOp\n function _createSenderIfNeeded(UserOperation calldata op) internal {\n if (op.initCode.length != 0) {\n //its a create operation. run the create2\n // note that we're still under the gas limit of validate, so probably\n // this create2 creates a proxy account.\n // appending signer makes the request unique, so no one else can make this request.\n //nonce is meaningless during create, so we re-purpose it as salt\n address sender1 = ICreate2Deployer(create2factory).deploy(op.initCode, bytes32(op.nonce));\n require(sender1 != address(0), \"create2 failed\");\n require(sender1 == op.getSender(), \"sender doesn't match create2 address\");\n }\n }\n\n //get counterfactual sender address.\n // use the initCode and salt in the UserOperation tot create this sender contract\n function getSenderAddress(bytes memory initCode, uint _salt) public view returns (address) {\n bytes32 hash = keccak256(\n abi.encodePacked(\n bytes1(0xff),\n address(create2factory),\n _salt,\n keccak256(initCode)\n )\n );\n\n // NOTE: cast last 20 bytes of hash to address\n return address(uint160(uint256(hash)));\n }\n\n //call wallet.verifyUserOp, and validate that it paid as needed.\n // return actual value sent from wallet to \"this\"\n function _validateWalletPrepayment(uint opIndex, UserOperation calldata op, uint requiredPrefund, PaymentMode paymentMode) internal returns (uint gasUsedByPayForSelfOp, uint prefund) {\n uint preGas = gasleft();\n _createSenderIfNeeded(op);\n uint preBalance = address(this).balance;\n uint requiredEthPrefund = 0;\n if (paymentMode == PaymentMode.walletEth) {\n requiredEthPrefund = requiredPrefund;\n } else if (paymentMode == PaymentMode.walletStake) {\n _prefundFromSender(op, requiredPrefund);\n } else {\n // paymaster pays in handlePostOp\n }\n try IWallet(op.getSender()).verifyUserOp{gas : op.verificationGas}(op, requiredEthPrefund) {\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, address(0), revertReason);\n } catch {\n revert FailedOp(opIndex, address(0), \"\");\n }\n uint actualEthPrefund = address(this).balance - preBalance;\n\n if (paymentMode == PaymentMode.walletEth) {\n if (actualEthPrefund < requiredEthPrefund) {\n revert FailedOp(opIndex, address(0), \"wallet didn't pay prefund\");\n }\n prefund = actualEthPrefund;\n } else if (paymentMode == PaymentMode.walletStake) {\n if (actualEthPrefund != 0) {\n revert FailedOp(opIndex, address(0), \"using wallet stake but wallet paid eth\");\n }\n prefund = requiredPrefund;\n } else {\n if (actualEthPrefund != 0) {\n revert FailedOp(opIndex, address(0), \"has paymaster but wallet paid\");\n }\n prefund = requiredPrefund;\n }\n\n gasUsedByPayForSelfOp = preGas - gasleft();\n }\n\n //validate paymaster.verifyPaymasterUserOp\n function _validatePaymasterPrepayment(uint opIndex, UserOperation calldata op, uint requiredPreFund, uint gasUsedByPayForSelfOp) internal view returns (bytes memory context, uint gasUsedByPayForOp) {\n uint preGas = gasleft();\n if (!isValidStake(op, requiredPreFund)) {\n revert FailedOp(opIndex, op.paymaster, \"not enough stake\");\n }\n //no pre-pay from paymaster\n uint gas = op.verificationGas - gasUsedByPayForSelfOp;\n try IPaymaster(op.paymaster).verifyPaymasterUserOp{gas : gas}(op, requiredPreFund) returns (bytes memory _context){\n context = _context;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, op.paymaster, revertReason);\n } catch {\n revert FailedOp(opIndex, op.paymaster, \"\");\n }\n gasUsedByPayForOp = preGas - gasleft();\n }\n\n function _validatePrepayment(uint opIndex, UserOperation calldata userOp) private returns (uint prefund, PaymentMode paymentMode, bytes memory context){\n\n uint preGas = gasleft();\n uint gasUsedByPayForSelfOp;\n uint requiredPreFund;\n (requiredPreFund, paymentMode) = getPaymentInfo(userOp);\n\n (gasUsedByPayForSelfOp, prefund) = _validateWalletPrepayment(opIndex, userOp, requiredPreFund, paymentMode);\n\n uint gasUsedByPayForOp = 0;\n if (paymentMode == PaymentMode.paymasterStake) {\n (context, gasUsedByPayForOp) = _validatePaymasterPrepayment(opIndex, userOp, requiredPreFund, gasUsedByPayForSelfOp);\n } else {\n context = \"\";\n }\n uint gasUsed = preGas - gasleft();\n\n if (userOp.verificationGas < gasUsed) {\n revert FailedOp(opIndex, userOp.paymaster, \"Used more than verificationGas\");\n }\n }\n\n function getPaymastersStake(address[] calldata paymasters) external view returns (uint[] memory _stakes) {\n _stakes = new uint[](paymasters.length);\n for (uint i = 0; i < paymasters.length; i++) {\n _stakes[i] = stakes[paymasters[i]].stake;\n }\n }\n\n function handlePostOp(IPaymaster.PostOpMode mode, UserOperation calldata op, bytes memory context, uint actualGas, uint prefund, PaymentMode paymentMode) private returns (uint actualGasCost) {\n uint preGas = gasleft();\n uint gasPrice = UserOperationLib.gasPrice(op);\n actualGasCost = actualGas * gasPrice;\n if (paymentMode != PaymentMode.paymasterStake) {\n if (prefund < actualGasCost) {\n revert (\"wallet prefund below actualGasCost\");\n }\n uint refund = prefund - actualGasCost;\n if (paymentMode == PaymentMode.walletStake) {\n _refundSenderStake(op, refund);\n } else {\n _refundSender(op, refund);\n }\n } else {\n if (context.length > 0) {\n //if paymaster.postOp reverts:\n // - emit a message (just for sake of debugging of this poor paymaster)\n // - paymaster still pays (from its stake)\n try IPaymaster(op.paymaster).postOp(mode, context, actualGasCost) {}\n catch (bytes memory errdata) {\n emit PaymasterPostOpFailed(op.getSender(), op.paymaster, op.nonce, errdata);\n }\n }\n //paymaster pays for full gas, including for postOp (and revert event)\n actualGas += preGas - gasleft();\n actualGasCost = actualGas * gasPrice;\n //paymaster balance known to be high enough, and to be locked for this block\n stakes[op.paymaster].stake -= uint96(actualGasCost);\n }\n _emitLog(op, actualGasCost, gasPrice, mode == IPaymaster.PostOpMode.opSucceeded);\n }\n\n function _emitLog(UserOperation calldata op, uint actualGasCost, uint gasPrice, bool success) internal {\n emit UserOperationEvent(op.getSender(), op.paymaster, op.nonce, actualGasCost, gasPrice, success);\n }\n\n function _prefundFromSender(UserOperation calldata userOp, uint requiredPrefund) internal {\n stakes[userOp.getSender()].stake -= uint96(requiredPrefund);\n }\n\n function _refundSender(UserOperation calldata userOp, uint refund) internal {\n //NOTE: deliberately ignoring revert: wallet should accept refund.\n bool sendOk = payable(userOp.getSender()).send(refund);\n (sendOk);\n }\n function _refundSenderStake(UserOperation calldata userOp, uint refund) internal {\n stakes[userOp.getSender()].stake += uint96(refund);\n }\n\n function isValidStake(UserOperation calldata userOp, uint requiredPreFund) internal view returns (bool) {\n return isPaymasterStaked(userOp.paymaster, PAYMASTER_STAKE + requiredPreFund);\n }\n\n function isPaymasterStaked(address paymaster, uint stake) public view returns (bool) {\n return isStaked(paymaster, stake, unstakeDelayBlocks);\n }\n\n function isContractDeployed(address addr) external view returns (bool) {\n bytes32 hash;\n assembly {\n hash := extcodehash(addr)\n }\n return hash != bytes32(0);\n }\n}\n\n" - }, - "contracts/StakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8;\n\nimport \"hardhat/console.sol\";\n\ncontract StakeManager {\n\n /// minimum number of blocks to after 'unlock' before amount can be withdrawn.\n uint32 immutable public unstakeDelayBlocks;\n\n constructor(uint32 _unstakeDelayBlocks) {\n unstakeDelayBlocks = _unstakeDelayBlocks;\n }\n\n event StakeAdded(\n address indexed paymaster,\n uint256 totalStake,\n uint256 unstakeDelayBlocks\n );\n\n /// Emitted once a stake is scheduled for withdrawal\n event StakeUnlocking(\n address indexed paymaster,\n uint256 withdrawBlock\n );\n\n event StakeWithdrawn(\n address indexed paymaster,\n address withdrawAddress,\n uint256 amount\n );\n\n /// @param stake - amount of ether staked for this paymaster\n /// @param withdrawStake - once 'unlocked' the value is no longer staked.\n /// @param withdrawBlock - first block number 'withdraw' will be callable, or zero if the unlock has not been called\n struct StakeInfo {\n uint96 stake;\n uint32 unstakeDelayBlocks;\n uint96 withdrawStake;\n uint32 withdrawBlock;\n }\n\n /// maps relay managers to their stakes\n mapping(address => StakeInfo) public stakes;\n\n function getStakeInfo(address paymaster) external view returns (StakeInfo memory stakeInfo) {\n return stakes[paymaster];\n }\n\n /**\n * add a deposit (just like stake, but with lock=0\n * cancel any pending unlock\n */\n function addDeposit() external payable {\n addStake(0);\n }\n\n //add deposit to another account (doesn't change lock status)\n function addDepositTo(address target) external payable {\n stakes[target].stake += uint96(msg.value);\n }\n\n /**\n * add stake value for this paymaster.\n * cancel any pending unlock\n */\n function addStake(uint32 _unstakeDelayBlocks) public payable {\n require(_unstakeDelayBlocks >= stakes[msg.sender].unstakeDelayBlocks, \"cannot decrease unstake blocks\");\n uint96 stake = uint96(stakes[msg.sender].stake + msg.value + stakes[msg.sender].withdrawStake);\n stakes[msg.sender] = StakeInfo(\n stake,\n _unstakeDelayBlocks,\n 0,\n 0);\n emit StakeAdded(msg.sender, stake, _unstakeDelayBlocks);\n }\n\n function unlockStake() external {\n StakeInfo storage info = stakes[msg.sender];\n require(info.withdrawBlock == 0, \"already pending\");\n require(info.stake != 0 && info.unstakeDelayBlocks != 0, \"no stake to unlock\");\n uint32 withdrawBlock = uint32(block.number) + info.unstakeDelayBlocks;\n info.withdrawBlock = withdrawBlock;\n info.withdrawStake = info.stake;\n info.stake = 0;\n emit StakeUnlocking(msg.sender, withdrawBlock);\n }\n\n function withdrawStake(address payable withdrawAddress) external {\n StakeInfo memory info = stakes[msg.sender];\n if (info.unstakeDelayBlocks != 0) {\n require(info.withdrawStake > 0, \"no unlocked stake\");\n require(info.withdrawBlock <= block.number, \"Withdrawal is not due\");\n }\n uint256 amount = info.withdrawStake + info.stake;\n stakes[msg.sender] = StakeInfo(0, info.unstakeDelayBlocks, 0, 0);\n withdrawAddress.transfer(amount);\n emit StakeWithdrawn(msg.sender, withdrawAddress, amount);\n }\n\n function isStaked(address paymaster, uint requiredStake, uint requiredDelayBlocks) public view returns (bool) {\n StakeInfo memory stakeInfo = stakes[paymaster];\n return stakeInfo.stake >= requiredStake && stakeInfo.unstakeDelayBlocks >= requiredDelayBlocks;\n }\n}\n" - }, - "contracts/UserOperation.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.7;\n\nimport \"hardhat/console.sol\";\n\n struct UserOperation {\n\n address sender;\n uint256 nonce;\n bytes initCode;\n bytes callData;\n uint callGas;\n uint verificationGas;\n uint preVerificationGas;\n uint maxFeePerGas;\n uint maxPriorityFeePerGas;\n address paymaster;\n bytes paymasterData;\n bytes signature;\n }\n\nlibrary UserOperationLib {\n\n function getSender(UserOperation calldata userOp) internal view returns (address ret) {\n assembly {ret := calldataload(userOp)}\n }\n\n //relayer/miner might submit the TX with higher priorityFee, but the user should not\n // pay above what he signed for.\n function gasPrice(UserOperation calldata userOp) internal view returns (uint) {\n unchecked {\n return min(userOp.maxFeePerGas, userOp.maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function requiredGas(UserOperation calldata userOp) internal pure returns (uint) {\n unchecked {\n return userOp.callGas + userOp.verificationGas + userOp.preVerificationGas;\n }\n }\n\n function requiredPreFund(UserOperation calldata userOp, uint overhead) internal view returns (uint prefund) {\n return (requiredGas(userOp) + overhead) * gasPrice(userOp);\n }\n\n function hasPaymaster(UserOperation calldata userOp) internal pure returns (bool) {\n return userOp.paymaster != address(0);\n }\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n //lighter signature scheme. must match UserOp.ts#packUserOp\n bytes calldata sig = userOp.signature;\n assembly {\n let ofs := userOp\n let len := sub(sub(sig.offset, ofs), 32)\n ret := mload(0x40)\n mstore(0x40, add(ret, add(len, 32)))\n mstore(ret, len)\n calldatacopy(add(ret, 32), ofs, len)\n }\n return ret;\n\n //TODO: eip712-style ?\n return abi.encode(\n userOp.sender,\n userOp.nonce,\n keccak256(userOp.initCode),\n keccak256(userOp.callData),\n userOp.callGas,\n userOp.verificationGas,\n userOp.preVerificationGas,\n userOp.maxFeePerGas,\n userOp.maxPriorityFeePerGas,\n userOp.paymaster,\n keccak256(userOp.paymasterData)\n );\n }\n\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\n return keccak256(abi.encodePacked(\"\\x19Ethereum Signed Message:\\n32\",\n keccak256(pack(userOp))));\n }\n\n function min(uint a, uint b) internal pure returns (uint) {\n return a < b ? a : b;\n }\n}\n" - }, - "contracts/IWallet.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.7;\n\nimport \"./UserOperation.sol\";\n\ninterface IWallet {\n\n // validate user's signature and nonce\n // @param requiredPrefund how much this wallet should pre-fund the transaction.\n // @note that after execution, the excess is sent back to the wallet.\n // @note if requiredPrefund is zero, the wallet MUST NOT send anything (the paymaster pays)\n function verifyUserOp(UserOperation calldata userOp, uint requiredPrefund) external;\n}\n" - }, - "contracts/IPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.7;\n\nimport \"./UserOperation.sol\";\n\ninterface IPaymaster {\n\n enum PostOpMode {\n opSucceeded, // user op succeeded\n opReverted, // user op reverted. still has to pay for gas.\n postOpReverted //user op succeeded, but caused postOp to revert. Now its a 2nd call, after user's op was deliberately reverted.\n }\n // payment validation: check if paymaster agree to pay (using its stake)\n // revert to reject this request.\n // actual payment is done after postOp is called, by deducting actual call cost form the paymaster's stake.\n // @param userOp the user operation\n // @param maxcost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\n // @returns context value to send to a postOp\n // zero length to signify postOp is not required.\n function verifyPaymasterUserOp(UserOperation calldata userOp, uint maxcost) external view returns (bytes memory context);\n\n // post-operation handler.\n // @param mode\n // opSucceeded - user operation succeeded.\n // opReverted - user op reverted. still has to pay for gas.\n // postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n // Now this is the 2nd call, after user's op was deliberately reverted.\n // @param context - the context value returned by verifyPaymasterUserOp\n // @param actualGasCost - actual gas used so far (without this postOp call).\n function postOp(PostOpMode mode, bytes calldata context, uint actualGasCost) external;\n}\n" - }, - "hardhat/console.sol": { - "content": "// SPDX-License-Identifier: MIT\npragma solidity >= 0.4.22 <0.9.0;\n\nlibrary console {\n\taddress constant CONSOLE_ADDRESS = address(0x000000000000000000636F6e736F6c652e6c6f67);\n\n\tfunction _sendLogPayload(bytes memory payload) private view {\n\t\tuint256 payloadLength = payload.length;\n\t\taddress consoleAddress = CONSOLE_ADDRESS;\n\t\tassembly {\n\t\t\tlet payloadStart := add(payload, 32)\n\t\t\tlet r := staticcall(gas(), consoleAddress, payloadStart, payloadLength, 0, 0)\n\t\t}\n\t}\n\n\tfunction log() internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log()\"));\n\t}\n\n\tfunction logInt(int p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(int)\", p0));\n\t}\n\n\tfunction logUint(uint p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint)\", p0));\n\t}\n\n\tfunction logString(string memory p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string)\", p0));\n\t}\n\n\tfunction logBool(bool p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool)\", p0));\n\t}\n\n\tfunction logAddress(address p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address)\", p0));\n\t}\n\n\tfunction logBytes(bytes memory p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes)\", p0));\n\t}\n\n\tfunction logBytes1(bytes1 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes1)\", p0));\n\t}\n\n\tfunction logBytes2(bytes2 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes2)\", p0));\n\t}\n\n\tfunction logBytes3(bytes3 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes3)\", p0));\n\t}\n\n\tfunction logBytes4(bytes4 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes4)\", p0));\n\t}\n\n\tfunction logBytes5(bytes5 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes5)\", p0));\n\t}\n\n\tfunction logBytes6(bytes6 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes6)\", p0));\n\t}\n\n\tfunction logBytes7(bytes7 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes7)\", p0));\n\t}\n\n\tfunction logBytes8(bytes8 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes8)\", p0));\n\t}\n\n\tfunction logBytes9(bytes9 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes9)\", p0));\n\t}\n\n\tfunction logBytes10(bytes10 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes10)\", p0));\n\t}\n\n\tfunction logBytes11(bytes11 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes11)\", p0));\n\t}\n\n\tfunction logBytes12(bytes12 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes12)\", p0));\n\t}\n\n\tfunction logBytes13(bytes13 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes13)\", p0));\n\t}\n\n\tfunction logBytes14(bytes14 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes14)\", p0));\n\t}\n\n\tfunction logBytes15(bytes15 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes15)\", p0));\n\t}\n\n\tfunction logBytes16(bytes16 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes16)\", p0));\n\t}\n\n\tfunction logBytes17(bytes17 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes17)\", p0));\n\t}\n\n\tfunction logBytes18(bytes18 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes18)\", p0));\n\t}\n\n\tfunction logBytes19(bytes19 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes19)\", p0));\n\t}\n\n\tfunction logBytes20(bytes20 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes20)\", p0));\n\t}\n\n\tfunction logBytes21(bytes21 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes21)\", p0));\n\t}\n\n\tfunction logBytes22(bytes22 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes22)\", p0));\n\t}\n\n\tfunction logBytes23(bytes23 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes23)\", p0));\n\t}\n\n\tfunction logBytes24(bytes24 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes24)\", p0));\n\t}\n\n\tfunction logBytes25(bytes25 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes25)\", p0));\n\t}\n\n\tfunction logBytes26(bytes26 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes26)\", p0));\n\t}\n\n\tfunction logBytes27(bytes27 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes27)\", p0));\n\t}\n\n\tfunction logBytes28(bytes28 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes28)\", p0));\n\t}\n\n\tfunction logBytes29(bytes29 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes29)\", p0));\n\t}\n\n\tfunction logBytes30(bytes30 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes30)\", p0));\n\t}\n\n\tfunction logBytes31(bytes31 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes31)\", p0));\n\t}\n\n\tfunction logBytes32(bytes32 p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bytes32)\", p0));\n\t}\n\n\tfunction log(uint p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint)\", p0));\n\t}\n\n\tfunction log(string memory p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string)\", p0));\n\t}\n\n\tfunction log(bool p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool)\", p0));\n\t}\n\n\tfunction log(address p0) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address)\", p0));\n\t}\n\n\tfunction log(uint p0, uint p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint)\", p0, p1));\n\t}\n\n\tfunction log(uint p0, string memory p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string)\", p0, p1));\n\t}\n\n\tfunction log(uint p0, bool p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool)\", p0, p1));\n\t}\n\n\tfunction log(uint p0, address p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address)\", p0, p1));\n\t}\n\n\tfunction log(string memory p0, uint p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint)\", p0, p1));\n\t}\n\n\tfunction log(string memory p0, string memory p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string)\", p0, p1));\n\t}\n\n\tfunction log(string memory p0, bool p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool)\", p0, p1));\n\t}\n\n\tfunction log(string memory p0, address p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address)\", p0, p1));\n\t}\n\n\tfunction log(bool p0, uint p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint)\", p0, p1));\n\t}\n\n\tfunction log(bool p0, string memory p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string)\", p0, p1));\n\t}\n\n\tfunction log(bool p0, bool p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool)\", p0, p1));\n\t}\n\n\tfunction log(bool p0, address p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address)\", p0, p1));\n\t}\n\n\tfunction log(address p0, uint p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint)\", p0, p1));\n\t}\n\n\tfunction log(address p0, string memory p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string)\", p0, p1));\n\t}\n\n\tfunction log(address p0, bool p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool)\", p0, p1));\n\t}\n\n\tfunction log(address p0, address p1) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address)\", p0, p1));\n\t}\n\n\tfunction log(uint p0, uint p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, uint p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, uint p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, uint p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, string memory p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, string memory p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, string memory p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, string memory p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, bool p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, bool p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, bool p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, bool p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, address p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, address p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, address p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, address p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, uint p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, uint p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, uint p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, uint p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, string memory p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, string memory p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, string memory p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, string memory p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, bool p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, bool p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, bool p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, bool p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, address p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, address p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, address p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(string memory p0, address p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, uint p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, uint p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, uint p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, uint p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, string memory p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, string memory p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, string memory p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, string memory p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, bool p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, bool p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, bool p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, bool p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, address p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, address p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, address p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(bool p0, address p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, uint p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, uint p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, uint p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, uint p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, string memory p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, string memory p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, string memory p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, string memory p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, bool p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, bool p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, bool p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, bool p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, address p1, uint p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,uint)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, address p1, string memory p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,string)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, address p1, bool p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,bool)\", p0, p1, p2));\n\t}\n\n\tfunction log(address p0, address p1, address p2) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,address)\", p0, p1, p2));\n\t}\n\n\tfunction log(uint p0, uint p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, uint p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,uint,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, string memory p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,string,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, bool p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,bool,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(uint p0, address p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(uint,address,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, uint p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,uint,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, string memory p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,string,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, bool p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,bool,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(string memory p0, address p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(string,address,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, uint p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,uint,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, string memory p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,string,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, bool p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,bool,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(bool p0, address p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(bool,address,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, uint p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,uint,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, string memory p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,string,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, bool p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,bool,address,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, uint p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,uint,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, uint p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,uint,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, uint p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,uint,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, uint p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,uint,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, string memory p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,string,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, string memory p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,string,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, string memory p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,string,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, string memory p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,string,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, bool p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,bool,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, bool p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,bool,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, bool p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,bool,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, bool p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,bool,address)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, address p2, uint p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,address,uint)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, address p2, string memory p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,address,string)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, address p2, bool p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,address,bool)\", p0, p1, p2, p3));\n\t}\n\n\tfunction log(address p0, address p1, address p2, address p3) internal view {\n\t\t_sendLogPayload(abi.encodeWithSignature(\"log(address,address,address,address)\", p0, p1, p2, p3));\n\t}\n\n}\n" - }, - "contracts/samples/VerifyingPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.7;\n\nimport \"../IPaymaster.sol\";\nimport \"../EntryPoint.sol\";\n\n/**\n * A sample paymaster that uses external service to decide whether to pay for the UserOp.\n * The paymaster trusts an external signer to sign the transaction.\n * The calling user must pass the UserOp to that external signer first, which performs\n * whatever off-chain verification before signing the UserOp.\n * Note that this signature is NOT a replacement for wallet signature:\n * - the paymaster signs to agree to PAY for GAS.\n * - the wallet signs to prove identity and wallet ownership.\n */\ncontract VerifyingPaymaster is IPaymaster {\n\n using UserOperationLib for UserOperation;\n\n EntryPoint public immutable entryPoint;\n address public immutable verifyingSigner;\n\n constructor(EntryPoint _entryPoint, address _verifyingSigner) {\n entryPoint = _entryPoint;\n verifyingSigner = _verifyingSigner;\n }\n\n function addStake() external payable {\n entryPoint.addStake{value : msg.value}(entryPoint.unstakeDelayBlocks());\n }\n\n // verify our external signer signed this request.\n // the \"paymasterData\" is supposed to be a signature over the entire request params\n function verifyPaymasterUserOp(UserOperation calldata userOp, uint requiredPreFund) external view override returns (bytes memory context) {\n (requiredPreFund);\n\n bytes32 hash = userOp.hash();\n require( userOp.paymasterData.length >= 65, \"VerifyingPaymaster: invalid signature length in paymasterData\");\n (bytes32 r, bytes32 s) = abi.decode(userOp.paymasterData, (bytes32, bytes32));\n uint8 v = uint8(userOp.paymasterData[64]);\n require(verifyingSigner == ecrecover(hash, v, r, s), \"VerifyingPaymaster: wrong signature\");\n\n //no other on-chain validation: entire UserOp should have been checked by the external service,\n // prior signing it.\n return \"\";\n }\n\n function postOp(PostOpMode, bytes calldata, uint) external pure override {\n //should never get called. returned \"0\" from verifyPaymasterUserOp\n revert();\n }\n}\n" - }, - "contracts/samples/TokenPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.7;\n\nimport \"@openzeppelin/contracts/access/Ownable.sol\";\nimport \"@openzeppelin/contracts/token/ERC20/ERC20.sol\";\nimport \"../IPaymaster.sol\";\nimport \"../EntryPoint.sol\";\nimport \"./SimpleWalletForTokens.sol\";\nimport \"hardhat/console.sol\";\n\n/**\n * A sample paymaster that define itself as a token to pay for gas.\n * The paymaster IS the token to use, since a paymaster cannot use an external contract.\n * also, the exchange rate has to be fixed, since it can't refernce external Uniswap os other exchange contract.\n */\ncontract TokenPaymaster is Ownable, ERC20, IPaymaster {\n\n //calculated cost of the postOp\n uint COST_OF_POST = 3000;\n\n EntryPoint entryPoint;\n bytes32 immutable knownWallet;\n\n constructor(string memory _symbol, EntryPoint _entryPoint) ERC20(_symbol, _symbol) {\n entryPoint = _entryPoint;\n knownWallet = keccak256(type(SimpleWallet).creationCode);\n// knownWallets[keccak256(type(SimpleWallet).creationCode)] = true;\n approve(owner(), type(uint).max);\n }\n\n //helpers for owner, to mint and withdraw tokens.\n function mintTokens(address recipient, uint amount) external onlyOwner {\n _mint(recipient, amount);\n }\n\n //owner should call and put eth into it.\n function addStake() external payable {\n entryPoint.addStake{value : msg.value}(entryPoint.unstakeDelayBlocks());\n }\n\n //TODO: this method assumes a fixed ratio of token-to-eth. should use oracle.\n function ethToToken(uint valueEth) internal pure returns (uint valueToken) {\n return valueEth / 100;\n }\n\n // verify that the user has enough tokens.\n function verifyPaymasterUserOp(UserOperation calldata userOp, uint requiredPreFund) external view override returns (bytes memory context) {\n uint tokenPrefund = ethToToken(requiredPreFund);\n\n if (userOp.initCode.length != 0) {\n bytes32 bytecodeHash = keccak256(userOp.initCode[0:userOp.initCode.length-64]);\n require(knownWallet == bytecodeHash, \"TokenPaymaster: unknown wallet constructor\");\n\n //verify the token constructor params:\n // first param (of 2) should be our entryPoint\n bytes32 entryPointParam = bytes32(userOp.initCode[userOp.initCode.length-64:]);\n require( address(uint160(uint256(entryPointParam))) == address(entryPoint), \"wrong paymaster in constructor\");\n\n //TODO: must also whitelist init function (callData), since that what will call \"token.approve(paymaster)\"\n //no \"allowance\" check during creation (we trust known constructor/init function)\n require(balanceOf(userOp.sender) > tokenPrefund, \"TokenPaymaster: no balance (pre-create)\");\n } else {\n\n require(balanceOf(userOp.sender) > tokenPrefund, \"TokenPaymaster: no balance\");\n }\n\n //since we ARE the token, we don't need approval to _transfer() value from user's balance.\n // if (token.allowance(userOp.sender, address(this)) < tokenPrefund) {\n //\n // //TODO: allowance too low. just before reverting, can check if current operation is \"token.approve(paymaster)\"\n // // this is a multi-step operation: first, verify \"callData\" is exec(token, innerData)\n // // (this requires knowing the \"execute\" signature of the wallet\n // // then verify that \"innerData\" is approve(paymaster,-1)\n // revert(\"TokenPaymaster: no allowance\");\n // }\n return abi.encode(userOp.sender);\n }\n\n //actual charge of user.\n // this method will be called just after the user's TX with postRevert=false.\n // BUT: if the user changed its balance and that postOp reverted, then it gets called again, after reverting\n // the user's TX\n function postOp(PostOpMode mode, bytes calldata context, uint actualGasCost) external override {\n //we don't really care about the mode, we just pay the gas with the user's tokens.\n (mode);\n address sender = abi.decode(context, (address));\n uint charge = ethToToken(actualGasCost + COST_OF_POST);\n //actualGasCost is known to be no larger than the above requiredPreFund, so the transfer should succeed.\n _transfer(sender, address(this), charge);\n }\n}\n" - }, - "@openzeppelin/contracts/access/Ownable.sol": { - "content": "// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\nimport \"../utils/Context.sol\";\n\n/**\n * @dev Contract module which provides a basic access control mechanism, where\n * there is an account (an owner) that can be granted exclusive access to\n * specific functions.\n *\n * By default, the owner account will be the one that deploys the contract. This\n * can later be changed with {transferOwnership}.\n *\n * This module is used through inheritance. It will make available the modifier\n * `onlyOwner`, which can be applied to your functions to restrict their use to\n * the owner.\n */\nabstract contract Ownable is Context {\n address private _owner;\n\n event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);\n\n /**\n * @dev Initializes the contract setting the deployer as the initial owner.\n */\n constructor() {\n _setOwner(_msgSender());\n }\n\n /**\n * @dev Returns the address of the current owner.\n */\n function owner() public view virtual returns (address) {\n return _owner;\n }\n\n /**\n * @dev Throws if called by any account other than the owner.\n */\n modifier onlyOwner() {\n require(owner() == _msgSender(), \"Ownable: caller is not the owner\");\n _;\n }\n\n /**\n * @dev Leaves the contract without owner. It will not be possible to call\n * `onlyOwner` functions anymore. Can only be called by the current owner.\n *\n * NOTE: Renouncing ownership will leave the contract without an owner,\n * thereby removing any functionality that is only available to the owner.\n */\n function renounceOwnership() public virtual onlyOwner {\n _setOwner(address(0));\n }\n\n /**\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\n * Can only be called by the current owner.\n */\n function transferOwnership(address newOwner) public virtual onlyOwner {\n require(newOwner != address(0), \"Ownable: new owner is the zero address\");\n _setOwner(newOwner);\n }\n\n function _setOwner(address newOwner) private {\n address oldOwner = _owner;\n _owner = newOwner;\n emit OwnershipTransferred(oldOwner, newOwner);\n }\n}\n" - }, - "@openzeppelin/contracts/token/ERC20/ERC20.sol": { - "content": "// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\nimport \"./IERC20.sol\";\nimport \"./extensions/IERC20Metadata.sol\";\nimport \"../../utils/Context.sol\";\n\n/**\n * @dev Implementation of the {IERC20} interface.\n *\n * This implementation is agnostic to the way tokens are created. This means\n * that a supply mechanism has to be added in a derived contract using {_mint}.\n * For a generic mechanism see {ERC20PresetMinterPauser}.\n *\n * TIP: For a detailed writeup see our guide\n * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How\n * to implement supply mechanisms].\n *\n * We have followed general OpenZeppelin Contracts guidelines: functions revert\n * instead returning `false` on failure. This behavior is nonetheless\n * conventional and does not conflict with the expectations of ERC20\n * applications.\n *\n * Additionally, an {Approval} event is emitted on calls to {transferFrom}.\n * This allows applications to reconstruct the allowance for all accounts just\n * by listening to said events. Other implementations of the EIP may not emit\n * these events, as it isn't required by the specification.\n *\n * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}\n * functions have been added to mitigate the well-known issues around setting\n * allowances. See {IERC20-approve}.\n */\ncontract ERC20 is Context, IERC20, IERC20Metadata {\n mapping(address => uint256) private _balances;\n\n mapping(address => mapping(address => uint256)) private _allowances;\n\n uint256 private _totalSupply;\n\n string private _name;\n string private _symbol;\n\n /**\n * @dev Sets the values for {name} and {symbol}.\n *\n * The default value of {decimals} is 18. To select a different value for\n * {decimals} you should overload it.\n *\n * All two of these values are immutable: they can only be set once during\n * construction.\n */\n constructor(string memory name_, string memory symbol_) {\n _name = name_;\n _symbol = symbol_;\n }\n\n /**\n * @dev Returns the name of the token.\n */\n function name() public view virtual override returns (string memory) {\n return _name;\n }\n\n /**\n * @dev Returns the symbol of the token, usually a shorter version of the\n * name.\n */\n function symbol() public view virtual override returns (string memory) {\n return _symbol;\n }\n\n /**\n * @dev Returns the number of decimals used to get its user representation.\n * For example, if `decimals` equals `2`, a balance of `505` tokens should\n * be displayed to a user as `5.05` (`505 / 10 ** 2`).\n *\n * Tokens usually opt for a value of 18, imitating the relationship between\n * Ether and Wei. This is the value {ERC20} uses, unless this function is\n * overridden;\n *\n * NOTE: This information is only used for _display_ purposes: it in\n * no way affects any of the arithmetic of the contract, including\n * {IERC20-balanceOf} and {IERC20-transfer}.\n */\n function decimals() public view virtual override returns (uint8) {\n return 18;\n }\n\n /**\n * @dev See {IERC20-totalSupply}.\n */\n function totalSupply() public view virtual override returns (uint256) {\n return _totalSupply;\n }\n\n /**\n * @dev See {IERC20-balanceOf}.\n */\n function balanceOf(address account) public view virtual override returns (uint256) {\n return _balances[account];\n }\n\n /**\n * @dev See {IERC20-transfer}.\n *\n * Requirements:\n *\n * - `recipient` cannot be the zero address.\n * - the caller must have a balance of at least `amount`.\n */\n function transfer(address recipient, uint256 amount) public virtual override returns (bool) {\n _transfer(_msgSender(), recipient, amount);\n return true;\n }\n\n /**\n * @dev See {IERC20-allowance}.\n */\n function allowance(address owner, address spender) public view virtual override returns (uint256) {\n return _allowances[owner][spender];\n }\n\n /**\n * @dev See {IERC20-approve}.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n */\n function approve(address spender, uint256 amount) public virtual override returns (bool) {\n _approve(_msgSender(), spender, amount);\n return true;\n }\n\n /**\n * @dev See {IERC20-transferFrom}.\n *\n * Emits an {Approval} event indicating the updated allowance. This is not\n * required by the EIP. See the note at the beginning of {ERC20}.\n *\n * Requirements:\n *\n * - `sender` and `recipient` cannot be the zero address.\n * - `sender` must have a balance of at least `amount`.\n * - the caller must have allowance for ``sender``'s tokens of at least\n * `amount`.\n */\n function transferFrom(\n address sender,\n address recipient,\n uint256 amount\n ) public virtual override returns (bool) {\n _transfer(sender, recipient, amount);\n\n uint256 currentAllowance = _allowances[sender][_msgSender()];\n require(currentAllowance >= amount, \"ERC20: transfer amount exceeds allowance\");\n unchecked {\n _approve(sender, _msgSender(), currentAllowance - amount);\n }\n\n return true;\n }\n\n /**\n * @dev Atomically increases the allowance granted to `spender` by the caller.\n *\n * This is an alternative to {approve} that can be used as a mitigation for\n * problems described in {IERC20-approve}.\n *\n * Emits an {Approval} event indicating the updated allowance.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n */\n function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {\n _approve(_msgSender(), spender, _allowances[_msgSender()][spender] + addedValue);\n return true;\n }\n\n /**\n * @dev Atomically decreases the allowance granted to `spender` by the caller.\n *\n * This is an alternative to {approve} that can be used as a mitigation for\n * problems described in {IERC20-approve}.\n *\n * Emits an {Approval} event indicating the updated allowance.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n * - `spender` must have allowance for the caller of at least\n * `subtractedValue`.\n */\n function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {\n uint256 currentAllowance = _allowances[_msgSender()][spender];\n require(currentAllowance >= subtractedValue, \"ERC20: decreased allowance below zero\");\n unchecked {\n _approve(_msgSender(), spender, currentAllowance - subtractedValue);\n }\n\n return true;\n }\n\n /**\n * @dev Moves `amount` of tokens from `sender` to `recipient`.\n *\n * This internal function is equivalent to {transfer}, and can be used to\n * e.g. implement automatic token fees, slashing mechanisms, etc.\n *\n * Emits a {Transfer} event.\n *\n * Requirements:\n *\n * - `sender` cannot be the zero address.\n * - `recipient` cannot be the zero address.\n * - `sender` must have a balance of at least `amount`.\n */\n function _transfer(\n address sender,\n address recipient,\n uint256 amount\n ) internal virtual {\n require(sender != address(0), \"ERC20: transfer from the zero address\");\n require(recipient != address(0), \"ERC20: transfer to the zero address\");\n\n _beforeTokenTransfer(sender, recipient, amount);\n\n uint256 senderBalance = _balances[sender];\n require(senderBalance >= amount, \"ERC20: transfer amount exceeds balance\");\n unchecked {\n _balances[sender] = senderBalance - amount;\n }\n _balances[recipient] += amount;\n\n emit Transfer(sender, recipient, amount);\n\n _afterTokenTransfer(sender, recipient, amount);\n }\n\n /** @dev Creates `amount` tokens and assigns them to `account`, increasing\n * the total supply.\n *\n * Emits a {Transfer} event with `from` set to the zero address.\n *\n * Requirements:\n *\n * - `account` cannot be the zero address.\n */\n function _mint(address account, uint256 amount) internal virtual {\n require(account != address(0), \"ERC20: mint to the zero address\");\n\n _beforeTokenTransfer(address(0), account, amount);\n\n _totalSupply += amount;\n _balances[account] += amount;\n emit Transfer(address(0), account, amount);\n\n _afterTokenTransfer(address(0), account, amount);\n }\n\n /**\n * @dev Destroys `amount` tokens from `account`, reducing the\n * total supply.\n *\n * Emits a {Transfer} event with `to` set to the zero address.\n *\n * Requirements:\n *\n * - `account` cannot be the zero address.\n * - `account` must have at least `amount` tokens.\n */\n function _burn(address account, uint256 amount) internal virtual {\n require(account != address(0), \"ERC20: burn from the zero address\");\n\n _beforeTokenTransfer(account, address(0), amount);\n\n uint256 accountBalance = _balances[account];\n require(accountBalance >= amount, \"ERC20: burn amount exceeds balance\");\n unchecked {\n _balances[account] = accountBalance - amount;\n }\n _totalSupply -= amount;\n\n emit Transfer(account, address(0), amount);\n\n _afterTokenTransfer(account, address(0), amount);\n }\n\n /**\n * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.\n *\n * This internal function is equivalent to `approve`, and can be used to\n * e.g. set automatic allowances for certain subsystems, etc.\n *\n * Emits an {Approval} event.\n *\n * Requirements:\n *\n * - `owner` cannot be the zero address.\n * - `spender` cannot be the zero address.\n */\n function _approve(\n address owner,\n address spender,\n uint256 amount\n ) internal virtual {\n require(owner != address(0), \"ERC20: approve from the zero address\");\n require(spender != address(0), \"ERC20: approve to the zero address\");\n\n _allowances[owner][spender] = amount;\n emit Approval(owner, spender, amount);\n }\n\n /**\n * @dev Hook that is called before any transfer of tokens. This includes\n * minting and burning.\n *\n * Calling conditions:\n *\n * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens\n * will be transferred to `to`.\n * - when `from` is zero, `amount` tokens will be minted for `to`.\n * - when `to` is zero, `amount` of ``from``'s tokens will be burned.\n * - `from` and `to` are never both zero.\n *\n * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].\n */\n function _beforeTokenTransfer(\n address from,\n address to,\n uint256 amount\n ) internal virtual {}\n\n /**\n * @dev Hook that is called after any transfer of tokens. This includes\n * minting and burning.\n *\n * Calling conditions:\n *\n * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens\n * has been transferred to `to`.\n * - when `from` is zero, `amount` tokens have been minted for `to`.\n * - when `to` is zero, `amount` of ``from``'s tokens have been burned.\n * - `from` and `to` are never both zero.\n *\n * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].\n */\n function _afterTokenTransfer(\n address from,\n address to,\n uint256 amount\n ) internal virtual {}\n}\n" - }, - "contracts/samples/SimpleWalletForTokens.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.7;\n\nimport \"./SimpleWallet.sol\";\nimport \"@openzeppelin/contracts/token/ERC20/IERC20.sol\";\n\n//in order to be created with tokens, the wallet has to have allowance to the paymaster in advance.\n// the simplest strategy is assign the allowance in the constructor or init function\ncontract SimpleWalletForTokens is SimpleWallet {\n\n constructor(EntryPoint _entryPoint, address _owner, IERC20 token, address paymaster) SimpleWallet(_entryPoint, _owner) {\n token.approve(paymaster, type(uint).max);\n }\n}\n" - }, - "@openzeppelin/contracts/utils/Context.sol": { - "content": "// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Provides information about the current execution context, including the\n * sender of the transaction and its data. While these are generally available\n * via msg.sender and msg.data, they should not be accessed in such a direct\n * manner, since when dealing with meta-transactions the account sending and\n * paying for execution may not be the actual sender (as far as an application\n * is concerned).\n *\n * This contract is only required for intermediate, library-like contracts.\n */\nabstract contract Context {\n function _msgSender() internal view virtual returns (address) {\n return msg.sender;\n }\n\n function _msgData() internal view virtual returns (bytes calldata) {\n return msg.data;\n }\n}\n" - }, - "@openzeppelin/contracts/token/ERC20/IERC20.sol": { - "content": "// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Interface of the ERC20 standard as defined in the EIP.\n */\ninterface IERC20 {\n /**\n * @dev Returns the amount of tokens in existence.\n */\n function totalSupply() external view returns (uint256);\n\n /**\n * @dev Returns the amount of tokens owned by `account`.\n */\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * @dev Moves `amount` tokens from the caller's account to `recipient`.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n * Emits a {Transfer} event.\n */\n function transfer(address recipient, uint256 amount) external returns (bool);\n\n /**\n * @dev Returns the remaining number of tokens that `spender` will be\n * allowed to spend on behalf of `owner` through {transferFrom}. This is\n * zero by default.\n *\n * This value changes when {approve} or {transferFrom} are called.\n */\n function allowance(address owner, address spender) external view returns (uint256);\n\n /**\n * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n * IMPORTANT: Beware that changing an allowance with this method brings the risk\n * that someone may use both the old and the new allowance by unfortunate\n * transaction ordering. One possible solution to mitigate this race\n * condition is to first reduce the spender's allowance to 0 and set the\n * desired value afterwards:\n * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729\n *\n * Emits an {Approval} event.\n */\n function approve(address spender, uint256 amount) external returns (bool);\n\n /**\n * @dev Moves `amount` tokens from `sender` to `recipient` using the\n * allowance mechanism. `amount` is then deducted from the caller's\n * allowance.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n * Emits a {Transfer} event.\n */\n function transferFrom(\n address sender,\n address recipient,\n uint256 amount\n ) external returns (bool);\n\n /**\n * @dev Emitted when `value` tokens are moved from one account (`from`) to\n * another (`to`).\n *\n * Note that `value` may be zero.\n */\n event Transfer(address indexed from, address indexed to, uint256 value);\n\n /**\n * @dev Emitted when the allowance of a `spender` for an `owner` is set by\n * a call to {approve}. `value` is the new allowance.\n */\n event Approval(address indexed owner, address indexed spender, uint256 value);\n}\n" - }, - "@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol": { - "content": "// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\nimport \"../IERC20.sol\";\n\n/**\n * @dev Interface for the optional metadata functions from the ERC20 standard.\n *\n * _Available since v4.1._\n */\ninterface IERC20Metadata is IERC20 {\n /**\n * @dev Returns the name of the token.\n */\n function name() external view returns (string memory);\n\n /**\n * @dev Returns the symbol of the token.\n */\n function symbol() external view returns (string memory);\n\n /**\n * @dev Returns the decimals places of the token.\n */\n function decimals() external view returns (uint8);\n}\n" - }, - "contracts/samples/SimpleWallet.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.7;\n\nimport \"../IWallet.sol\";\nimport \"../EntryPoint.sol\";\n\nimport \"hardhat/console.sol\";\n\n//minimal wallet\n// this is sample minimal wallet.\n// has execute, eth handling methods\n// has a single signer that can send requests through the entryPoint.\ncontract SimpleWallet is IWallet {\n using UserOperationLib for UserOperation;\n struct OwnerNonce {\n uint96 nonce;\n address owner;\n }\n OwnerNonce ownerNonce;\n EntryPoint public entryPoint;\n\n function nonce() public view returns (uint) {\n return ownerNonce.nonce;\n }\n\n function owner() public view returns(address) {\n return ownerNonce.owner;\n }\n\n event EntryPointChanged(EntryPoint oldEntryPoint, EntryPoint newEntryPoint);\n\n receive() external payable {}\n\n constructor(EntryPoint _entryPoint, address _owner) {\n entryPoint = _entryPoint;\n ownerNonce.owner = _owner;\n }\n\n modifier onlyOwner() {\n _onlyOwner();\n _;\n }\n\n function _onlyOwner() internal view {\n //directly from EOA owner, or through the entryPoint (which gets redirected through execFromEntryPoint)\n require(msg.sender == ownerNonce.owner || msg.sender == address(this), \"only owner\");\n }\n\n function transfer(address payable dest, uint amount) external onlyOwner {\n dest.transfer(amount);\n }\n\n function exec(address dest, uint value, bytes calldata func) external onlyOwner {\n _call(dest, value, func);\n }\n\n function updateEntryPoint(EntryPoint _entryPoint) external onlyOwner {\n emit EntryPointChanged(entryPoint, _entryPoint);\n entryPoint = _entryPoint;\n }\n\n function _requireFromEntryPoint() internal view {\n require(msg.sender == address(entryPoint), \"wallet: not from EntryPoint\");\n }\n\n function verifyUserOp(UserOperation calldata userOp, uint requiredPrefund) external override {\n _requireFromEntryPoint();\n _validateSignature(userOp);\n _validateAndIncrementNonce(userOp);\n _payPrefund(requiredPrefund);\n }\n\n function _payPrefund(uint requiredPrefund) internal {\n if (requiredPrefund != 0) {\n (bool success) = payable(msg.sender).send(requiredPrefund);\n (success);\n //ignore failure (its EntryPoint's job to verify, not wallet.)\n }\n }\n\n //called by entryPoint, only after verifyUserOp succeeded.\n function execFromEntryPoint(address dest, uint value, bytes calldata func) external {\n _requireFromEntryPoint();\n _call(dest, value, func);\n }\n\n function _validateAndIncrementNonce(UserOperation calldata userOp) internal {\n //during construction, the \"nonce\" field hold the salt.\n // if we assert it is zero, then we allow only a single wallet per owner.\n if (userOp.initCode.length == 0) {\n require(ownerNonce.nonce++ == userOp.nonce, \"wallet: invalid nonce\");\n }\n }\n\n function _validateSignature(UserOperation calldata userOp) internal view {\n\n bytes32 hash = userOp.hash();\n (bytes32 r, bytes32 s, uint8 v) = _rsv(userOp.signature);\n\n require(owner() == _ecrecover(hash, v, r, s), \"wallet: wrong signature\");\n }\n\n function _rsv(bytes calldata signature) internal pure returns (bytes32 r, bytes32 s, uint8 v) {\n\n require(signature.length == 65, \"wallet: invalid signature length\");\n assembly {\n r := calldataload(signature.offset)\n s := calldataload(add(signature.offset, 0x20))\n v := byte(0, calldataload(add(signature.offset, 0x40)))\n }\n }\n\n function _ecrecover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address) {\n return ecrecover(hash, v, r, s);\n }\n\n function _call(address sender, uint value, bytes memory data) internal {\n (bool success, bytes memory result) = sender.call{value : value}(data);\n if (!success) {\n assembly {\n revert(result, add(result, 32))\n }\n }\n }\n\n function addDeposit() public payable {\n entryPoint.addDeposit{value : msg.value}();\n }\n\n function withdrawDeposit(address payable withdrawAddress) public {\n entryPoint.withdrawStake(withdrawAddress);\n }\n}\n" - }, - "contracts/samples/TestToken.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.7;\n\nimport \"@openzeppelin/contracts/token/ERC20/ERC20.sol\";\n\ncontract TestToken is ERC20 {\n constructor ()\n ERC20(\"TST\", \"TestToken\") {\n }\n\n function mint(address sender, uint amount) external {\n _mint(sender, amount);\n }\n}\n" - }, - "contracts/test/TestUtil.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.7;\n\nimport \"../UserOperation.sol\";\nimport \"../IWallet.sol\";\n\ncontract TestUtil {\n using UserOperationLib for UserOperation;\n\n function packUserOp(UserOperation calldata op) external pure returns (bytes memory){\n return op.pack();\n }\n\n function prefund(UserOperation calldata op) public view returns (uint) {\n return op.requiredPreFund(0);\n }\n\n}" - }, - "contracts/test/TestCounter.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.7;\n\nimport \"../UserOperation.sol\";\nimport \"../IWallet.sol\";\n\n//sample \"receiver\" contract, for testing \"exec\" from wallet.\ncontract TestCounter {\n mapping(address => uint) public counters;\n\n function count() public {\n counters[msg.sender] = counters[msg.sender] + 1;\n\n }\n\n //helper method to waste gas\n // repeat - waste gas on writing storage in a loop\n // junk - dynamic buffer to stress the function size.\n mapping(uint => uint) xxx;\n uint offset;\n\n function gasWaster(uint repeat, string calldata /*junk*/) external {\n for (uint i = 1; i <= repeat; i++) {\n offset++;\n xxx[offset] = i;\n }\n }\n}" - } - }, - "settings": { - "optimizer": { - "enabled": true, - "runs": 200 - }, - "outputSelection": { - "*": { - "*": [ - "abi", - "evm.bytecode", - "evm.deployedBytecode", - "evm.methodIdentifiers", - "metadata", - "devdoc", - "userdoc", - "storageLayout", - "evm.gasEstimates" - ], - "": [ - "ast" - ] - } - }, - "metadata": { - "useLiteralContent": true - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/.chainId b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/.chainId deleted file mode 100644 index 56a6051ca2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/.chainId +++ /dev/null @@ -1 +0,0 @@ -1 \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/EntryPoint.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/EntryPoint.json deleted file mode 100644 index 037750fba7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/EntryPoint.json +++ /dev/null @@ -1,1318 +0,0 @@ -{ - "address": "0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789", - "abi": [ - { - "inputs": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "paid", - "type": "uint256" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bool", - "name": "targetSuccess", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "targetResult", - "type": "bytes" - } - ], - "name": "ExecutionResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "opIndex", - "type": "uint256" - }, - { - "internalType": "string", - "name": "reason", - "type": "string" - } - ], - "name": "FailedOp", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - } - ], - "name": "SenderAddressResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureValidationFailed", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - } - ], - "name": "ValidationResult", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "stakeInfo", - "type": "tuple" - } - ], - "internalType": "struct IEntryPoint.AggregatorStakeInfo", - "name": "aggregatorInfo", - "type": "tuple" - } - ], - "name": "ValidationResultWithAggregation", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "factory", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "paymaster", - "type": "address" - } - ], - "name": "AccountDeployed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [], - "name": "BeforeExecution", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalDeposit", - "type": "uint256" - } - ], - "name": "Deposited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureAggregatorChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalStaked", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "name": "StakeLocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "withdrawTime", - "type": "uint256" - } - ], - "name": "StakeUnlocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "StakeWithdrawn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasUsed", - "type": "uint256" - } - ], - "name": "UserOperationEvent", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "revertReason", - "type": "bytes" - } - ], - "name": "UserOperationRevertReason", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "Withdrawn", - "type": "event" - }, - { - "inputs": [], - "name": "SIG_VALIDATION_FAILED", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - } - ], - "name": "_validateSenderAndPaymaster", - "outputs": [], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - } - ], - "name": "addStake", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "depositTo", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "deposits", - "outputs": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "getDepositInfo", - "outputs": [ - { - "components": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "internalType": "struct IStakeManager.DepositInfo", - "name": "info", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "getNonce", - "outputs": [ - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - } - ], - "name": "getSenderAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "getUserOpHash", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "userOps", - "type": "tuple[]" - }, - { - "internalType": "contract IAggregator", - "name": "aggregator", - "type": "address" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.UserOpsPerAggregator[]", - "name": "opsPerAggregator", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleAggregatedOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "ops", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "incrementNonce", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.MemoryUserOp", - "name": "mUserOp", - "type": "tuple" - }, - { - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "contextOffset", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.UserOpInfo", - "name": "opInfo", - "type": "tuple" - }, - { - "internalType": "bytes", - "name": "context", - "type": "bytes" - } - ], - "name": "innerHandleOp", - "outputs": [ - { - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - }, - { - "internalType": "uint192", - "name": "", - "type": "uint192" - } - ], - "name": "nonceSequenceNumber", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "op", - "type": "tuple" - }, - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "targetCallData", - "type": "bytes" - } - ], - "name": "simulateHandleOp", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "simulateValidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unlockStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - } - ], - "name": "withdrawStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "withdrawAmount", - "type": "uint256" - } - ], - "name": "withdrawTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "args": [], - "numDeployments": 2, - "solcInputHash": "a4c52f0671aad8941c53d6ead2063803", - "metadata": "{\"compiler\":{\"version\":\"0.8.17+commit.8df45f5f\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"paid\",\"type\":\"uint256\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bool\",\"name\":\"targetSuccess\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"targetResult\",\"type\":\"bytes\"}],\"name\":\"ExecutionResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"opIndex\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\"}],\"name\":\"FailedOp\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderAddressResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureValidationFailed\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResult\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"stakeInfo\",\"type\":\"tuple\"}],\"internalType\":\"struct IEntryPoint.AggregatorStakeInfo\",\"name\":\"aggregatorInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResultWithAggregation\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"factory\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"}],\"name\":\"AccountDeployed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"BeforeExecution\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalDeposit\",\"type\":\"uint256\"}],\"name\":\"Deposited\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureAggregatorChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalStaked\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"name\":\"StakeLocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"withdrawTime\",\"type\":\"uint256\"}],\"name\":\"StakeUnlocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"StakeWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasUsed\",\"type\":\"uint256\"}],\"name\":\"UserOperationEvent\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"revertReason\",\"type\":\"bytes\"}],\"name\":\"UserOperationRevertReason\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Withdrawn\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"SIG_VALIDATION_FAILED\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"}],\"name\":\"_validateSenderAndPaymaster\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"}],\"name\":\"addStake\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"depositTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"deposits\",\"outputs\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getDepositInfo\",\"outputs\":[{\"components\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"internalType\":\"struct IStakeManager.DepositInfo\",\"name\":\"info\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"}],\"name\":\"getSenderAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"getUserOpHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"userOps\",\"type\":\"tuple[]\"},{\"internalType\":\"contract IAggregator\",\"name\":\"aggregator\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.UserOpsPerAggregator[]\",\"name\":\"opsPerAggregator\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleAggregatedOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"ops\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"incrementNonce\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.MemoryUserOp\",\"name\":\"mUserOp\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"contextOffset\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.UserOpInfo\",\"name\":\"opInfo\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"context\",\"type\":\"bytes\"}],\"name\":\"innerHandleOp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"\",\"type\":\"uint192\"}],\"name\":\"nonceSequenceNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"op\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"targetCallData\",\"type\":\"bytes\"}],\"name\":\"simulateHandleOp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"simulateValidation\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unlockStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"}],\"name\":\"withdrawStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"withdrawAmount\",\"type\":\"uint256\"}],\"name\":\"withdrawTo\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"errors\":{\"FailedOp(uint256,string)\":[{\"params\":{\"opIndex\":\"- index into the array of ops to the failed one (in simulateValidation, this is always zero)\",\"reason\":\"- revert reason The string starts with a unique code \\\"AAmn\\\", where \\\"m\\\" is \\\"1\\\" for factory, \\\"2\\\" for account and \\\"3\\\" for paymaster issues, so a failure can be attributed to the correct entity. Should be caught in off-chain handleOps simulation and not happen on-chain. Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\"}}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"params\":{\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"params\":{\"aggregatorInfo\":\"signature aggregation info (if the account requires signature aggregator) bundler MUST use it to verify the signature, or reject the UserOperation\",\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}]},\"kind\":\"dev\",\"methods\":{\"addStake(uint32)\":{\"params\":{\"unstakeDelaySec\":\"the new lock duration before the deposit can be withdrawn.\"}},\"getDepositInfo(address)\":{\"returns\":{\"info\":\"- full deposit information of given account\"}},\"getNonce(address,uint192)\":{\"params\":{\"key\":\"the high 192 bit of the nonce\",\"sender\":\"the account address\"},\"returns\":{\"nonce\":\"a full nonce to pass for next UserOp with this sender.\"}},\"getSenderAddress(bytes)\":{\"params\":{\"initCode\":\"the constructor code to be passed into the UserOperation.\"}},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"opsPerAggregator\":\"the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\"}},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"ops\":\"the operations to execute\"}},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"params\":{\"op\":\"the UserOperation to simulate\",\"target\":\"if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult are set to the return from that call.\",\"targetCallData\":\"callData to pass to target address\"}},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"details\":\"this method always revert. Successful result is ValidationResult error. other errors are failures.The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\",\"params\":{\"userOp\":\"the user operation to validate.\"}},\"withdrawStake(address)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\"}},\"withdrawTo(address,uint256)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\",\"withdrawAmount\":\"the amount to withdraw.\"}}},\"version\":1},\"userdoc\":{\"errors\":{\"ExecutionResult(uint256,uint256,uint48,uint48,bool,bytes)\":[{\"notice\":\"return value of simulateHandleOp\"}],\"FailedOp(uint256,string)\":[{\"notice\":\"a custom revert error of handleOps, to identify the offending op. NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\"}],\"SenderAddressResult(address)\":[{\"notice\":\"return value of getSenderAddress\"}],\"SignatureValidationFailed(address)\":[{\"notice\":\"error case when a signature aggregator fails to verify the aggregated signature it had created.\"}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"notice\":\"Successful result from simulateValidation.\"}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"notice\":\"Successful result from simulateValidation, if the account returns a signature aggregator\"}]},\"events\":{\"AccountDeployed(bytes32,address,address,address)\":{\"notice\":\"account \\\"sender\\\" was deployed.\"},\"BeforeExecution()\":{\"notice\":\"an event emitted by handleOps(), before starting the execution loop. any event emitted before this event, is part of the validation.\"},\"SignatureAggregatorChanged(address)\":{\"notice\":\"signature aggregator used by the following UserOperationEvents within this bundle.\"},\"StakeLocked(address,uint256,uint256)\":{\"notice\":\"Emitted when stake or unstake delay are modified\"},\"StakeUnlocked(address,uint256)\":{\"notice\":\"Emitted once a stake is scheduled for withdrawal\"},\"UserOperationRevertReason(bytes32,address,uint256,bytes)\":{\"notice\":\"An event emitted if the UserOperation \\\"callData\\\" reverted with non-zero length\"}},\"kind\":\"user\",\"methods\":{\"SIG_VALIDATION_FAILED()\":{\"notice\":\"for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value in case of signature failure, instead of revert.\"},\"_validateSenderAndPaymaster(bytes,address,bytes)\":{\"notice\":\"Called only during simulation. This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\"},\"addStake(uint32)\":{\"notice\":\"add to the account's stake - amount and delay any pending unstake is first cancelled.\"},\"balanceOf(address)\":{\"notice\":\"return the deposit (for gas payment) of the account\"},\"depositTo(address)\":{\"notice\":\"add to the deposit of the given account\"},\"deposits(address)\":{\"notice\":\"maps paymaster to their deposits and stakes\"},\"getNonce(address,uint192)\":{\"notice\":\"Return the next nonce for this sender. Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop) But UserOp with different keys can come with arbitrary order.\"},\"getSenderAddress(bytes)\":{\"notice\":\"Get counterfactual sender address. Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation. this method always revert, and returns the address in SenderAddressResult error\"},\"getUserOpHash((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"generate a request Id - unique identifier for this request. the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\"},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperation with Aggregators\"},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperations. no signature aggregator is used. if any account requires an aggregator (that is, it returned an aggregator when performing simulateValidation), then handleAggregatedOps() must be used instead.\"},\"incrementNonce(uint192)\":{\"notice\":\"Manually increment the nonce of the sender. This method is exposed just for completeness.. Account does NOT need to call it, neither during validation, nor elsewhere, as the EntryPoint will update the nonce regardless. Possible use-case is call it with various keys to \\\"initialize\\\" their nonces to one, so that future UserOperations will not pay extra for the first transaction with a given key.\"},\"innerHandleOp(bytes,((address,uint256,uint256,uint256,uint256,address,uint256,uint256),bytes32,uint256,uint256,uint256),bytes)\":{\"notice\":\"inner function to handle a UserOperation. Must be declared \\\"external\\\" to open a call context, but it can only be called by handleOps.\"},\"nonceSequenceNumber(address,uint192)\":{\"notice\":\"The next valid sequence number for a given nonce key.\"},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"notice\":\"simulate full execution of a UserOperation (including both validation and target execution) this method will always revert with \\\"ExecutionResult\\\". it performs full validation of the UserOperation, but ignores signature error. an optional target address is called after the userop succeeds, and its value is returned (before the entire call is reverted) Note that in order to collect the the success/failure of the target call, it must be executed with trace enabled to track the emitted events.\"},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\"},\"unlockStake()\":{\"notice\":\"attempt to unlock the stake. the value can be withdrawn (using withdrawStake) after the unstake delay.\"},\"withdrawStake(address)\":{\"notice\":\"withdraw from the (unlocked) stake. must first call unlockStake and wait for the unstakeDelay to pass\"},\"withdrawTo(address,uint256)\":{\"notice\":\"withdraw from the deposit.\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/core/EntryPoint.sol\":\"EntryPoint\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":1000000},\"remappings\":[],\"viaIR\":true},\"sources\":{\"@openzeppelin/contracts/security/ReentrancyGuard.sol\":{\"keccak256\":\"0x190dd6f8d592b7e4e930feb7f4313aeb8e1c4ad3154c27ce1cf6a512fc30d8cc\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://4ce8dfb62d0c4fa260d6eec8f1cd47f5f2a044e11bde5b31d18072fa6e7d9010\",\"dweb:/ipfs/QmTyFztU3tLEcEDnqqiaW4UJetqsU77LXc6pjc9oTXCK5u\"]},\"contracts/core/EntryPoint.sol\":{\"keccak256\":\"0x04f86318b47f052d7308795ffae6ecec0d023d2458b4e17751b89a0e4acfcdc6\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://c9f6e359c8dbe875ad974d3a0fb7b3d62319a6b115c44bac1e4587ae2ad2edaf\",\"dweb:/ipfs/QmTSWTov2rUeYk8cwzrtsd3uVXokCYok4gMiZ1sPs9tycH\"]},\"contracts/core/Helpers.sol\":{\"keccak256\":\"0x591c87519f7155d1909210276b77925ab2722a99b7b5d5649aecc36ebbdb045a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://69643e83f68e6a13d5075c7565bfce326673b0bd98c432033c4603ea84835746\",\"dweb:/ipfs/QmSwSzjYyV7qudi5vvsmzHMG2Z4YJZxX51RRXXVCLaNcEU\"]},\"contracts/core/NonceManager.sol\":{\"keccak256\":\"0xa17a4a6fde70088ab18ffe6df830f3efa31f1cd0e1a7160336c96e3c94984d25\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://b38615df9f80c56282b72888e9ba1eb1a9413fa67a0dbf094deda7af9feb38e7\",\"dweb:/ipfs/QmSzcXetEJRH4UHuUmZiSgX6bFgfqHWfmyuxVnh4NosMk1\"]},\"contracts/core/SenderCreator.sol\":{\"keccak256\":\"0x44b9449fec82d6cdfb01d52fdd5a72f90099c651316123810cf9633f00b018c2\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a9c0487390e72638681d175c45bc92425c802fffdca4bd0ae8457782ee284612\",\"dweb:/ipfs/QmVbzuehCUWJWqEHyMWuc6cRVbxfcMdFsmGL9o4Wz7WY2x\"]},\"contracts/core/StakeManager.sol\":{\"keccak256\":\"0x21aa0956382bd000b1b8c3b1d19ca6ebcd6c9029eebb19c612fb38ee5dd2430a\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://0a625c8795354d9f429367f9c1d14eb8af7db9c7f2c2a2033e2066ced76a573a\",\"dweb:/ipfs/Qmd1j6UarUg54q1G2HCNCLQz8XGVZR1qxX7eQ6cytHpQPN\"]},\"contracts/interfaces/IAccount.sol\":{\"keccak256\":\"0x556a0e5980de18e90b115553ed502408155ba35f58642823010d9288047bc418\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a0f420134b79596db8737173c7b933ae0a33059e107b6327c43aa40d4744a9e4\",\"dweb:/ipfs/QmRo8s1AhXmEMV7uPYnbpYwU19e9Bk6jmYBJTiPx3Fo85W\"]},\"contracts/interfaces/IAggregator.sol\":{\"keccak256\":\"0x060e9ddb0152250c269ba0640dc5753834ac44cf182a2837d508c0c529cae26a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://20ed837bc5909c89ff1910246bf245a5dad6840aa939382e1694964eb7dbd37b\",\"dweb:/ipfs/QmTMybRq5yyghPDDs1ZCNAVB9sSJ4WHe6Q9mejuKPTAdNP\"]},\"contracts/interfaces/IEntryPoint.sol\":{\"keccak256\":\"0x3a90bf308819ed125fa4202f880999caff8a8686633b8ddb79a30ca240d5b8f8\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://d2d21cc92c2fdab2b58d21bc25d4cd0e8c284b922528a186b087b818d54bc6cf\",\"dweb:/ipfs/QmT1qrfuBjsv2rmRCDn8mgPXHp94hARJwzbcDuBLDTbFWd\"]},\"contracts/interfaces/INonceManager.sol\":{\"keccak256\":\"0x509871e6c63663cdcc3eba19920fe84e991f38b289b1377ac3c3a6d9f22d7e12\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://00fe21b4349b24c50df60e1a705179293982bd9e7a32b78d4bac9620f89e7fe2\",\"dweb:/ipfs/QmSFFYGfUwQbVa6hASjU7YxTvgi2HkfrPr4X5oPHscHg8b\"]},\"contracts/interfaces/IPaymaster.sol\":{\"keccak256\":\"0x36858ba8685024974f533530420688da3454d29996ebc42e410673a1ed2ec456\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://616cbcf51778b1961b7f20a547bec7efae6d1d565df0f651926241ed8bde9ad8\",\"dweb:/ipfs/QmaVsgffUUmeUJYgStvRr8cNZ1LBbrc3FYNLW4JT1dVLia\"]},\"contracts/interfaces/IStakeManager.sol\":{\"keccak256\":\"0xd227b02888cd4ac68daebcdfd992ec00f9fff66fa3b3bb16f656cd582fa3480f\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://b389da4714a138be63704a576a482505eab2855e263b38a93706395d8d42e7c3\",\"dweb:/ipfs/QmeeAZpdHwUXxqP8pxA7GNtoCGBmmH4FaqLLwScVKGxtxZ\"]},\"contracts/interfaces/UserOperation.sol\":{\"keccak256\":\"0x61374003361059087fdcf17967a7bba052badeaf5c7f0ae689166f8aafd3a45c\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://6ff83c59432e733bf6304dda27cd4b0f34401917dd535e2669cc842d2d26568c\",\"dweb:/ipfs/QmPJbHU5TAjHqUTZzAcicEeG2nknmwCN43L4EW9LHbknTN\"]},\"contracts/utils/Exec.sol\":{\"keccak256\":\"0x5b232117afbc2939f3ffc92745614867e9e1d475a3e1e5443adae13c200174f1\",\"license\":\"LGPL-3.0-only\",\"urls\":[\"bzz-raw://62e7365379a06ead7b47637945bcaee095d51aab1d3ac00ddec69443e6cbe9fe\",\"dweb:/ipfs/QmctG3aw4U3KMSMeJKoLJ1NJewjMWfppnd1m3kxNTe39Uy\"]}},\"version\":1}", - "bytecode": "0x60a080604052346200008957600160025561022c8181016001600160401b038111838210176200007357829162005d18833903906000f080156200006757608052604051615c8990816200008f82396080518181816113df01528181613e9501526141b60152f35b6040513d6000823e3d90fd5b634e487b7160e01b600052604160045260246000fd5b600080fdfe60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c634300081100336080806040523461001657610210908161001c8239f35b600080fdfe6080604052600436101561001257600080fd5b6000803560e01c63570e1a361461002857600080fd5b346100c95760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126100c95760043567ffffffffffffffff918282116100c957366023830112156100c95781600401359283116100c95736602484840101116100c9576100c561009e84602485016100fc565b60405173ffffffffffffffffffffffffffffffffffffffff90911681529081906020820190565b0390f35b80fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b90806014116101bb5767ffffffffffffffff917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec82018381116101cd575b604051937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f81600b8701160116850190858210908211176101c0575b604052808452602084019036848401116101bb576020946000600c819682946014880187378301015251923560601c5af19060005191156101b557565b60009150565b600080fd5b6101c86100cc565b610178565b6101d56100cc565b61013a56fea26469706673582212201927e80b76ab9b71c952137dd676621a9fdf520c25928815636594036eb1c40364736f6c63430008110033", - "deployedBytecode": "0x60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c63430008110033" -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/SimpleAccountFactory.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/SimpleAccountFactory.json deleted file mode 100644 index 4559ec0adf..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/SimpleAccountFactory.json +++ /dev/null @@ -1,107 +0,0 @@ -{ - "address": "0x9406Cc6185a346906296840746125a0E44976454", - "abi": [ - { - "inputs": [ - { - "internalType": "contract IEntryPoint", - "name": "_entryPoint", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "inputs": [], - "name": "accountImplementation", - "outputs": [ - { - "internalType": "contract SimpleAccount", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "uint256", - "name": "salt", - "type": "uint256" - } - ], - "name": "createAccount", - "outputs": [ - { - "internalType": "contract SimpleAccount", - "name": "ret", - "type": "address" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "uint256", - "name": "salt", - "type": "uint256" - } - ], - "name": "getAddress", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - } - ], - "args": [ - "0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789" - ], - "numDeployments": 1, - "solcInputHash": "02113a2ed1850c3774563305ee607f11", - "metadata": "{\"compiler\":{\"version\":\"0.8.15+commit.e14f2714\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"contract IEntryPoint\",\"name\":\"_entryPoint\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"accountImplementation\",\"outputs\":[{\"internalType\":\"contract SimpleAccount\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"salt\",\"type\":\"uint256\"}],\"name\":\"createAccount\",\"outputs\":[{\"internalType\":\"contract SimpleAccount\",\"name\":\"ret\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"salt\",\"type\":\"uint256\"}],\"name\":\"getAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"createAccount(address,uint256)\":{\"notice\":\"create an account, and return its address. returns the address even if the account is already deployed. Note that during UserOperation execution, this method is called only if the account is not deployed. This method returns an existing account address so that entryPoint.getSenderAddress() would work even after account creation\"},\"getAddress(address,uint256)\":{\"notice\":\"calculate the counterfactual address of this account as it would be returned by createAccount()\"}},\"notice\":\"A sample factory contract for SimpleAccount A UserOperations \\\"initCode\\\" holds the address of the factory, and a method call (to createAccount, in this sample factory). The factory's createAccount returns the target account address even if it is already installed. This way, the entryPoint.getSenderAddress() can be called either before or after the account is created.\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/samples/SimpleAccountFactory.sol\":\"SimpleAccountFactory\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\",\"useLiteralContent\":true},\"optimizer\":{\"enabled\":true,\"runs\":1000000},\"remappings\":[]},\"sources\":{\"@openzeppelin/contracts/interfaces/draft-IERC1822.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.5.0) (interfaces/draft-IERC1822.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev ERC1822: Universal Upgradeable Proxy Standard (UUPS) documents a method for upgradeability through a simplified\\n * proxy whose upgrades are fully controlled by the current implementation.\\n */\\ninterface IERC1822Proxiable {\\n /**\\n * @dev Returns the storage slot that the proxiable contract assumes is being used to store the implementation\\n * address.\\n *\\n * IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks\\n * bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this\\n * function revert if invoked through a proxy.\\n */\\n function proxiableUUID() external view returns (bytes32);\\n}\\n\",\"keccak256\":\"0x1d4afe6cb24200cc4545eed814ecf5847277dfe5d613a1707aad5fceecebcfff\",\"license\":\"MIT\"},\"@openzeppelin/contracts/proxy/ERC1967/ERC1967Proxy.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.7.0) (proxy/ERC1967/ERC1967Proxy.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../Proxy.sol\\\";\\nimport \\\"./ERC1967Upgrade.sol\\\";\\n\\n/**\\n * @dev This contract implements an upgradeable proxy. It is upgradeable because calls are delegated to an\\n * implementation address that can be changed. This address is stored in storage in the location specified by\\n * https://eips.ethereum.org/EIPS/eip-1967[EIP1967], so that it doesn't conflict with the storage layout of the\\n * implementation behind the proxy.\\n */\\ncontract ERC1967Proxy is Proxy, ERC1967Upgrade {\\n /**\\n * @dev Initializes the upgradeable proxy with an initial implementation specified by `_logic`.\\n *\\n * If `_data` is nonempty, it's used as data in a delegate call to `_logic`. This will typically be an encoded\\n * function call, and allows initializing the storage of the proxy like a Solidity constructor.\\n */\\n constructor(address _logic, bytes memory _data) payable {\\n _upgradeToAndCall(_logic, _data, false);\\n }\\n\\n /**\\n * @dev Returns the current implementation address.\\n */\\n function _implementation() internal view virtual override returns (address impl) {\\n return ERC1967Upgrade._getImplementation();\\n }\\n}\\n\",\"keccak256\":\"0xa2b22da3032e50b55f95ec1d13336102d675f341167aa76db571ef7f8bb7975d\",\"license\":\"MIT\"},\"@openzeppelin/contracts/proxy/ERC1967/ERC1967Upgrade.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.5.0) (proxy/ERC1967/ERC1967Upgrade.sol)\\n\\npragma solidity ^0.8.2;\\n\\nimport \\\"../beacon/IBeacon.sol\\\";\\nimport \\\"../../interfaces/draft-IERC1822.sol\\\";\\nimport \\\"../../utils/Address.sol\\\";\\nimport \\\"../../utils/StorageSlot.sol\\\";\\n\\n/**\\n * @dev This abstract contract provides getters and event emitting update functions for\\n * https://eips.ethereum.org/EIPS/eip-1967[EIP1967] slots.\\n *\\n * _Available since v4.1._\\n *\\n * @custom:oz-upgrades-unsafe-allow delegatecall\\n */\\nabstract contract ERC1967Upgrade {\\n // This is the keccak-256 hash of \\\"eip1967.proxy.rollback\\\" subtracted by 1\\n bytes32 private constant _ROLLBACK_SLOT = 0x4910fdfa16fed3260ed0e7147f7cc6da11a60208b5b9406d12a635614ffd9143;\\n\\n /**\\n * @dev Storage slot with the address of the current implementation.\\n * This is the keccak-256 hash of \\\"eip1967.proxy.implementation\\\" subtracted by 1, and is\\n * validated in the constructor.\\n */\\n bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;\\n\\n /**\\n * @dev Emitted when the implementation is upgraded.\\n */\\n event Upgraded(address indexed implementation);\\n\\n /**\\n * @dev Returns the current implementation address.\\n */\\n function _getImplementation() internal view returns (address) {\\n return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;\\n }\\n\\n /**\\n * @dev Stores a new address in the EIP1967 implementation slot.\\n */\\n function _setImplementation(address newImplementation) private {\\n require(Address.isContract(newImplementation), \\\"ERC1967: new implementation is not a contract\\\");\\n StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;\\n }\\n\\n /**\\n * @dev Perform implementation upgrade\\n *\\n * Emits an {Upgraded} event.\\n */\\n function _upgradeTo(address newImplementation) internal {\\n _setImplementation(newImplementation);\\n emit Upgraded(newImplementation);\\n }\\n\\n /**\\n * @dev Perform implementation upgrade with additional setup call.\\n *\\n * Emits an {Upgraded} event.\\n */\\n function _upgradeToAndCall(\\n address newImplementation,\\n bytes memory data,\\n bool forceCall\\n ) internal {\\n _upgradeTo(newImplementation);\\n if (data.length > 0 || forceCall) {\\n Address.functionDelegateCall(newImplementation, data);\\n }\\n }\\n\\n /**\\n * @dev Perform implementation upgrade with security checks for UUPS proxies, and additional setup call.\\n *\\n * Emits an {Upgraded} event.\\n */\\n function _upgradeToAndCallUUPS(\\n address newImplementation,\\n bytes memory data,\\n bool forceCall\\n ) internal {\\n // Upgrades from old implementations will perform a rollback test. This test requires the new\\n // implementation to upgrade back to the old, non-ERC1822 compliant, implementation. Removing\\n // this special case will break upgrade paths from old UUPS implementation to new ones.\\n if (StorageSlot.getBooleanSlot(_ROLLBACK_SLOT).value) {\\n _setImplementation(newImplementation);\\n } else {\\n try IERC1822Proxiable(newImplementation).proxiableUUID() returns (bytes32 slot) {\\n require(slot == _IMPLEMENTATION_SLOT, \\\"ERC1967Upgrade: unsupported proxiableUUID\\\");\\n } catch {\\n revert(\\\"ERC1967Upgrade: new implementation is not UUPS\\\");\\n }\\n _upgradeToAndCall(newImplementation, data, forceCall);\\n }\\n }\\n\\n /**\\n * @dev Storage slot with the admin of the contract.\\n * This is the keccak-256 hash of \\\"eip1967.proxy.admin\\\" subtracted by 1, and is\\n * validated in the constructor.\\n */\\n bytes32 internal constant _ADMIN_SLOT = 0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103;\\n\\n /**\\n * @dev Emitted when the admin account has changed.\\n */\\n event AdminChanged(address previousAdmin, address newAdmin);\\n\\n /**\\n * @dev Returns the current admin.\\n */\\n function _getAdmin() internal view returns (address) {\\n return StorageSlot.getAddressSlot(_ADMIN_SLOT).value;\\n }\\n\\n /**\\n * @dev Stores a new address in the EIP1967 admin slot.\\n */\\n function _setAdmin(address newAdmin) private {\\n require(newAdmin != address(0), \\\"ERC1967: new admin is the zero address\\\");\\n StorageSlot.getAddressSlot(_ADMIN_SLOT).value = newAdmin;\\n }\\n\\n /**\\n * @dev Changes the admin of the proxy.\\n *\\n * Emits an {AdminChanged} event.\\n */\\n function _changeAdmin(address newAdmin) internal {\\n emit AdminChanged(_getAdmin(), newAdmin);\\n _setAdmin(newAdmin);\\n }\\n\\n /**\\n * @dev The storage slot of the UpgradeableBeacon contract which defines the implementation for this proxy.\\n * This is bytes32(uint256(keccak256('eip1967.proxy.beacon')) - 1)) and is validated in the constructor.\\n */\\n bytes32 internal constant _BEACON_SLOT = 0xa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d50;\\n\\n /**\\n * @dev Emitted when the beacon is upgraded.\\n */\\n event BeaconUpgraded(address indexed beacon);\\n\\n /**\\n * @dev Returns the current beacon.\\n */\\n function _getBeacon() internal view returns (address) {\\n return StorageSlot.getAddressSlot(_BEACON_SLOT).value;\\n }\\n\\n /**\\n * @dev Stores a new beacon in the EIP1967 beacon slot.\\n */\\n function _setBeacon(address newBeacon) private {\\n require(Address.isContract(newBeacon), \\\"ERC1967: new beacon is not a contract\\\");\\n require(\\n Address.isContract(IBeacon(newBeacon).implementation()),\\n \\\"ERC1967: beacon implementation is not a contract\\\"\\n );\\n StorageSlot.getAddressSlot(_BEACON_SLOT).value = newBeacon;\\n }\\n\\n /**\\n * @dev Perform beacon upgrade with additional setup call. Note: This upgrades the address of the beacon, it does\\n * not upgrade the implementation contained in the beacon (see {UpgradeableBeacon-_setImplementation} for that).\\n *\\n * Emits a {BeaconUpgraded} event.\\n */\\n function _upgradeBeaconToAndCall(\\n address newBeacon,\\n bytes memory data,\\n bool forceCall\\n ) internal {\\n _setBeacon(newBeacon);\\n emit BeaconUpgraded(newBeacon);\\n if (data.length > 0 || forceCall) {\\n Address.functionDelegateCall(IBeacon(newBeacon).implementation(), data);\\n }\\n }\\n}\\n\",\"keccak256\":\"0xabf3f59bc0e5423eae45e459dbe92e7052c6983628d39008590edc852a62f94a\",\"license\":\"MIT\"},\"@openzeppelin/contracts/proxy/Proxy.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.6.0) (proxy/Proxy.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev This abstract contract provides a fallback function that delegates all calls to another contract using the EVM\\n * instruction `delegatecall`. We refer to the second contract as the _implementation_ behind the proxy, and it has to\\n * be specified by overriding the virtual {_implementation} function.\\n *\\n * Additionally, delegation to the implementation can be triggered manually through the {_fallback} function, or to a\\n * different contract through the {_delegate} function.\\n *\\n * The success and return data of the delegated call will be returned back to the caller of the proxy.\\n */\\nabstract contract Proxy {\\n /**\\n * @dev Delegates the current call to `implementation`.\\n *\\n * This function does not return to its internal call site, it will return directly to the external caller.\\n */\\n function _delegate(address implementation) internal virtual {\\n assembly {\\n // Copy msg.data. We take full control of memory in this inline assembly\\n // block because it will not return to Solidity code. We overwrite the\\n // Solidity scratch pad at memory position 0.\\n calldatacopy(0, 0, calldatasize())\\n\\n // Call the implementation.\\n // out and outsize are 0 because we don't know the size yet.\\n let result := delegatecall(gas(), implementation, 0, calldatasize(), 0, 0)\\n\\n // Copy the returned data.\\n returndatacopy(0, 0, returndatasize())\\n\\n switch result\\n // delegatecall returns 0 on error.\\n case 0 {\\n revert(0, returndatasize())\\n }\\n default {\\n return(0, returndatasize())\\n }\\n }\\n }\\n\\n /**\\n * @dev This is a virtual function that should be overridden so it returns the address to which the fallback function\\n * and {_fallback} should delegate.\\n */\\n function _implementation() internal view virtual returns (address);\\n\\n /**\\n * @dev Delegates the current call to the address returned by `_implementation()`.\\n *\\n * This function does not return to its internal call site, it will return directly to the external caller.\\n */\\n function _fallback() internal virtual {\\n _beforeFallback();\\n _delegate(_implementation());\\n }\\n\\n /**\\n * @dev Fallback function that delegates calls to the address returned by `_implementation()`. Will run if no other\\n * function in the contract matches the call data.\\n */\\n fallback() external payable virtual {\\n _fallback();\\n }\\n\\n /**\\n * @dev Fallback function that delegates calls to the address returned by `_implementation()`. Will run if call data\\n * is empty.\\n */\\n receive() external payable virtual {\\n _fallback();\\n }\\n\\n /**\\n * @dev Hook that is called before falling back to the implementation. Can happen as part of a manual `_fallback`\\n * call, or as part of the Solidity `fallback` or `receive` functions.\\n *\\n * If overridden should call `super._beforeFallback()`.\\n */\\n function _beforeFallback() internal virtual {}\\n}\\n\",\"keccak256\":\"0xc130fe33f1b2132158531a87734153293f6d07bc263ff4ac90e85da9c82c0e27\",\"license\":\"MIT\"},\"@openzeppelin/contracts/proxy/beacon/IBeacon.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (proxy/beacon/IBeacon.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev This is the interface that {BeaconProxy} expects of its beacon.\\n */\\ninterface IBeacon {\\n /**\\n * @dev Must return an address that can be used as a delegate call target.\\n *\\n * {BeaconProxy} will check that this address is a contract.\\n */\\n function implementation() external view returns (address);\\n}\\n\",\"keccak256\":\"0xd50a3421ac379ccb1be435fa646d66a65c986b4924f0849839f08692f39dde61\",\"license\":\"MIT\"},\"@openzeppelin/contracts/proxy/utils/Initializable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (proxy/utils/Initializable.sol)\\n\\npragma solidity ^0.8.2;\\n\\nimport \\\"../../utils/Address.sol\\\";\\n\\n/**\\n * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed\\n * behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an\\n * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer\\n * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.\\n *\\n * The initialization functions use a version number. Once a version number is used, it is consumed and cannot be\\n * reused. This mechanism prevents re-execution of each \\\"step\\\" but allows the creation of new initialization steps in\\n * case an upgrade adds a module that needs to be initialized.\\n *\\n * For example:\\n *\\n * [.hljs-theme-light.nopadding]\\n * ```\\n * contract MyToken is ERC20Upgradeable {\\n * function initialize() initializer public {\\n * __ERC20_init(\\\"MyToken\\\", \\\"MTK\\\");\\n * }\\n * }\\n * contract MyTokenV2 is MyToken, ERC20PermitUpgradeable {\\n * function initializeV2() reinitializer(2) public {\\n * __ERC20Permit_init(\\\"MyToken\\\");\\n * }\\n * }\\n * ```\\n *\\n * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as\\n * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.\\n *\\n * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure\\n * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.\\n *\\n * [CAUTION]\\n * ====\\n * Avoid leaving a contract uninitialized.\\n *\\n * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation\\n * contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke\\n * the {_disableInitializers} function in the constructor to automatically lock it when it is deployed:\\n *\\n * [.hljs-theme-light.nopadding]\\n * ```\\n * /// @custom:oz-upgrades-unsafe-allow constructor\\n * constructor() {\\n * _disableInitializers();\\n * }\\n * ```\\n * ====\\n */\\nabstract contract Initializable {\\n /**\\n * @dev Indicates that the contract has been initialized.\\n * @custom:oz-retyped-from bool\\n */\\n uint8 private _initialized;\\n\\n /**\\n * @dev Indicates that the contract is in the process of being initialized.\\n */\\n bool private _initializing;\\n\\n /**\\n * @dev Triggered when the contract has been initialized or reinitialized.\\n */\\n event Initialized(uint8 version);\\n\\n /**\\n * @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope,\\n * `onlyInitializing` functions can be used to initialize parent contracts.\\n *\\n * Similar to `reinitializer(1)`, except that functions marked with `initializer` can be nested in the context of a\\n * constructor.\\n *\\n * Emits an {Initialized} event.\\n */\\n modifier initializer() {\\n bool isTopLevelCall = !_initializing;\\n require(\\n (isTopLevelCall && _initialized < 1) || (!Address.isContract(address(this)) && _initialized == 1),\\n \\\"Initializable: contract is already initialized\\\"\\n );\\n _initialized = 1;\\n if (isTopLevelCall) {\\n _initializing = true;\\n }\\n _;\\n if (isTopLevelCall) {\\n _initializing = false;\\n emit Initialized(1);\\n }\\n }\\n\\n /**\\n * @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the\\n * contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be\\n * used to initialize parent contracts.\\n *\\n * A reinitializer may be used after the original initialization step. This is essential to configure modules that\\n * are added through upgrades and that require initialization.\\n *\\n * When `version` is 1, this modifier is similar to `initializer`, except that functions marked with `reinitializer`\\n * cannot be nested. If one is invoked in the context of another, execution will revert.\\n *\\n * Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in\\n * a contract, executing them in the right order is up to the developer or operator.\\n *\\n * WARNING: setting the version to 255 will prevent any future reinitialization.\\n *\\n * Emits an {Initialized} event.\\n */\\n modifier reinitializer(uint8 version) {\\n require(!_initializing && _initialized < version, \\\"Initializable: contract is already initialized\\\");\\n _initialized = version;\\n _initializing = true;\\n _;\\n _initializing = false;\\n emit Initialized(version);\\n }\\n\\n /**\\n * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the\\n * {initializer} and {reinitializer} modifiers, directly or indirectly.\\n */\\n modifier onlyInitializing() {\\n require(_initializing, \\\"Initializable: contract is not initializing\\\");\\n _;\\n }\\n\\n /**\\n * @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call.\\n * Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized\\n * to any version. It is recommended to use this to lock implementation contracts that are designed to be called\\n * through proxies.\\n *\\n * Emits an {Initialized} event the first time it is successfully executed.\\n */\\n function _disableInitializers() internal virtual {\\n require(!_initializing, \\\"Initializable: contract is initializing\\\");\\n if (_initialized < type(uint8).max) {\\n _initialized = type(uint8).max;\\n emit Initialized(type(uint8).max);\\n }\\n }\\n\\n /**\\n * @dev Internal function that returns the initialized version. Returns `_initialized`\\n */\\n function _getInitializedVersion() internal view returns (uint8) {\\n return _initialized;\\n }\\n\\n /**\\n * @dev Internal function that returns the initialized version. Returns `_initializing`\\n */\\n function _isInitializing() internal view returns (bool) {\\n return _initializing;\\n }\\n}\\n\",\"keccak256\":\"0xcee5467d5d873fb75dae6f98c01a8d25dd609f9d0374c7d39217bd5f9539a2d6\",\"license\":\"MIT\"},\"@openzeppelin/contracts/proxy/utils/UUPSUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (proxy/utils/UUPSUpgradeable.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../../interfaces/draft-IERC1822.sol\\\";\\nimport \\\"../ERC1967/ERC1967Upgrade.sol\\\";\\n\\n/**\\n * @dev An upgradeability mechanism designed for UUPS proxies. The functions included here can perform an upgrade of an\\n * {ERC1967Proxy}, when this contract is set as the implementation behind such a proxy.\\n *\\n * A security mechanism ensures that an upgrade does not turn off upgradeability accidentally, although this risk is\\n * reinstated if the upgrade retains upgradeability but removes the security mechanism, e.g. by replacing\\n * `UUPSUpgradeable` with a custom implementation of upgrades.\\n *\\n * The {_authorizeUpgrade} function must be overridden to include access restriction to the upgrade mechanism.\\n *\\n * _Available since v4.1._\\n */\\nabstract contract UUPSUpgradeable is IERC1822Proxiable, ERC1967Upgrade {\\n /// @custom:oz-upgrades-unsafe-allow state-variable-immutable state-variable-assignment\\n address private immutable __self = address(this);\\n\\n /**\\n * @dev Check that the execution is being performed through a delegatecall call and that the execution context is\\n * a proxy contract with an implementation (as defined in ERC1967) pointing to self. This should only be the case\\n * for UUPS and transparent proxies that are using the current contract as their implementation. Execution of a\\n * function through ERC1167 minimal proxies (clones) would not normally pass this test, but is not guaranteed to\\n * fail.\\n */\\n modifier onlyProxy() {\\n require(address(this) != __self, \\\"Function must be called through delegatecall\\\");\\n require(_getImplementation() == __self, \\\"Function must be called through active proxy\\\");\\n _;\\n }\\n\\n /**\\n * @dev Check that the execution is not being performed through a delegate call. This allows a function to be\\n * callable on the implementing contract but not through proxies.\\n */\\n modifier notDelegated() {\\n require(address(this) == __self, \\\"UUPSUpgradeable: must not be called through delegatecall\\\");\\n _;\\n }\\n\\n /**\\n * @dev Implementation of the ERC1822 {proxiableUUID} function. This returns the storage slot used by the\\n * implementation. It is used to validate the implementation's compatibility when performing an upgrade.\\n *\\n * IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks\\n * bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this\\n * function revert if invoked through a proxy. This is guaranteed by the `notDelegated` modifier.\\n */\\n function proxiableUUID() external view virtual override notDelegated returns (bytes32) {\\n return _IMPLEMENTATION_SLOT;\\n }\\n\\n /**\\n * @dev Upgrade the implementation of the proxy to `newImplementation`.\\n *\\n * Calls {_authorizeUpgrade}.\\n *\\n * Emits an {Upgraded} event.\\n */\\n function upgradeTo(address newImplementation) external virtual onlyProxy {\\n _authorizeUpgrade(newImplementation);\\n _upgradeToAndCallUUPS(newImplementation, new bytes(0), false);\\n }\\n\\n /**\\n * @dev Upgrade the implementation of the proxy to `newImplementation`, and subsequently execute the function call\\n * encoded in `data`.\\n *\\n * Calls {_authorizeUpgrade}.\\n *\\n * Emits an {Upgraded} event.\\n */\\n function upgradeToAndCall(address newImplementation, bytes memory data) external payable virtual onlyProxy {\\n _authorizeUpgrade(newImplementation);\\n _upgradeToAndCallUUPS(newImplementation, data, true);\\n }\\n\\n /**\\n * @dev Function that should revert when `msg.sender` is not authorized to upgrade the contract. Called by\\n * {upgradeTo} and {upgradeToAndCall}.\\n *\\n * Normally, this function will use an xref:access.adoc[access control] modifier such as {Ownable-onlyOwner}.\\n *\\n * ```solidity\\n * function _authorizeUpgrade(address) internal override onlyOwner {}\\n * ```\\n */\\n function _authorizeUpgrade(address newImplementation) internal virtual;\\n}\\n\",\"keccak256\":\"0x85cc5aca68692044586dc5ca19a9868d3288f6b35d1085c620dd0278ed0abdaa\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC1155/IERC1155Receiver.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC1155/IERC1155Receiver.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../../utils/introspection/IERC165.sol\\\";\\n\\n/**\\n * @dev _Available since v3.1._\\n */\\ninterface IERC1155Receiver is IERC165 {\\n /**\\n * @dev Handles the receipt of a single ERC1155 token type. This function is\\n * called at the end of a `safeTransferFrom` after the balance has been updated.\\n *\\n * NOTE: To accept the transfer, this must return\\n * `bytes4(keccak256(\\\"onERC1155Received(address,address,uint256,uint256,bytes)\\\"))`\\n * (i.e. 0xf23a6e61, or its own function selector).\\n *\\n * @param operator The address which initiated the transfer (i.e. msg.sender)\\n * @param from The address which previously owned the token\\n * @param id The ID of the token being transferred\\n * @param value The amount of tokens being transferred\\n * @param data Additional data with no specified format\\n * @return `bytes4(keccak256(\\\"onERC1155Received(address,address,uint256,uint256,bytes)\\\"))` if transfer is allowed\\n */\\n function onERC1155Received(\\n address operator,\\n address from,\\n uint256 id,\\n uint256 value,\\n bytes calldata data\\n ) external returns (bytes4);\\n\\n /**\\n * @dev Handles the receipt of a multiple ERC1155 token types. This function\\n * is called at the end of a `safeBatchTransferFrom` after the balances have\\n * been updated.\\n *\\n * NOTE: To accept the transfer(s), this must return\\n * `bytes4(keccak256(\\\"onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)\\\"))`\\n * (i.e. 0xbc197c81, or its own function selector).\\n *\\n * @param operator The address which initiated the batch transfer (i.e. msg.sender)\\n * @param from The address which previously owned the token\\n * @param ids An array containing ids of each token being transferred (order and length must match values array)\\n * @param values An array containing amounts of each token being transferred (order and length must match ids array)\\n * @param data Additional data with no specified format\\n * @return `bytes4(keccak256(\\\"onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)\\\"))` if transfer is allowed\\n */\\n function onERC1155BatchReceived(\\n address operator,\\n address from,\\n uint256[] calldata ids,\\n uint256[] calldata values,\\n bytes calldata data\\n ) external returns (bytes4);\\n}\\n\",\"keccak256\":\"0xeb373f1fdc7b755c6a750123a9b9e3a8a02c1470042fd6505d875000a80bde0b\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @title ERC721 token receiver interface\\n * @dev Interface for any contract that wants to support safeTransfers\\n * from ERC721 asset contracts.\\n */\\ninterface IERC721Receiver {\\n /**\\n * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}\\n * by `operator` from `from`, this function is called.\\n *\\n * It must return its Solidity selector to confirm the token transfer.\\n * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.\\n *\\n * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`.\\n */\\n function onERC721Received(\\n address operator,\\n address from,\\n uint256 tokenId,\\n bytes calldata data\\n ) external returns (bytes4);\\n}\\n\",\"keccak256\":\"0xa82b58eca1ee256be466e536706850163d2ec7821945abd6b4778cfb3bee37da\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC777/IERC777Recipient.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (token/ERC777/IERC777Recipient.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Interface of the ERC777TokensRecipient standard as defined in the EIP.\\n *\\n * Accounts can be notified of {IERC777} tokens being sent to them by having a\\n * contract implement this interface (contract holders can be their own\\n * implementer) and registering it on the\\n * https://eips.ethereum.org/EIPS/eip-1820[ERC1820 global registry].\\n *\\n * See {IERC1820Registry} and {ERC1820Implementer}.\\n */\\ninterface IERC777Recipient {\\n /**\\n * @dev Called by an {IERC777} token contract whenever tokens are being\\n * moved or created into a registered account (`to`). The type of operation\\n * is conveyed by `from` being the zero address or not.\\n *\\n * This call occurs _after_ the token contract's state is updated, so\\n * {IERC777-balanceOf}, etc., can be used to query the post-operation state.\\n *\\n * This function may revert to prevent the operation from being executed.\\n */\\n function tokensReceived(\\n address operator,\\n address from,\\n address to,\\n uint256 amount,\\n bytes calldata userData,\\n bytes calldata operatorData\\n ) external;\\n}\\n\",\"keccak256\":\"0x1a5d61db2733202ba361e6d6741cd2e662380e22b80e987eacfc91973f2267dc\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Address.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/Address.sol)\\n\\npragma solidity ^0.8.1;\\n\\n/**\\n * @dev Collection of functions related to the address type\\n */\\nlibrary Address {\\n /**\\n * @dev Returns true if `account` is a contract.\\n *\\n * [IMPORTANT]\\n * ====\\n * It is unsafe to assume that an address for which this function returns\\n * false is an externally-owned account (EOA) and not a contract.\\n *\\n * Among others, `isContract` will return false for the following\\n * types of addresses:\\n *\\n * - an externally-owned account\\n * - a contract in construction\\n * - an address where a contract will be created\\n * - an address where a contract lived, but was destroyed\\n * ====\\n *\\n * [IMPORTANT]\\n * ====\\n * You shouldn't rely on `isContract` to protect against flash loan attacks!\\n *\\n * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets\\n * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract\\n * constructor.\\n * ====\\n */\\n function isContract(address account) internal view returns (bool) {\\n // This method relies on extcodesize/address.code.length, which returns 0\\n // for contracts in construction, since the code is only stored at the end\\n // of the constructor execution.\\n\\n return account.code.length > 0;\\n }\\n\\n /**\\n * @dev Replacement for Solidity's `transfer`: sends `amount` wei to\\n * `recipient`, forwarding all available gas and reverting on errors.\\n *\\n * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost\\n * of certain opcodes, possibly making contracts go over the 2300 gas limit\\n * imposed by `transfer`, making them unable to receive funds via\\n * `transfer`. {sendValue} removes this limitation.\\n *\\n * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].\\n *\\n * IMPORTANT: because control is transferred to `recipient`, care must be\\n * taken to not create reentrancy vulnerabilities. Consider using\\n * {ReentrancyGuard} or the\\n * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].\\n */\\n function sendValue(address payable recipient, uint256 amount) internal {\\n require(address(this).balance >= amount, \\\"Address: insufficient balance\\\");\\n\\n (bool success, ) = recipient.call{value: amount}(\\\"\\\");\\n require(success, \\\"Address: unable to send value, recipient may have reverted\\\");\\n }\\n\\n /**\\n * @dev Performs a Solidity function call using a low level `call`. A\\n * plain `call` is an unsafe replacement for a function call: use this\\n * function instead.\\n *\\n * If `target` reverts with a revert reason, it is bubbled up by this\\n * function (like regular Solidity function calls).\\n *\\n * Returns the raw returned data. To convert to the expected return value,\\n * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].\\n *\\n * Requirements:\\n *\\n * - `target` must be a contract.\\n * - calling `target` with `data` must not revert.\\n *\\n * _Available since v3.1._\\n */\\n function functionCall(address target, bytes memory data) internal returns (bytes memory) {\\n return functionCallWithValue(target, data, 0, \\\"Address: low-level call failed\\\");\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with\\n * `errorMessage` as a fallback revert reason when `target` reverts.\\n *\\n * _Available since v3.1._\\n */\\n function functionCall(\\n address target,\\n bytes memory data,\\n string memory errorMessage\\n ) internal returns (bytes memory) {\\n return functionCallWithValue(target, data, 0, errorMessage);\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\\n * but also transferring `value` wei to `target`.\\n *\\n * Requirements:\\n *\\n * - the calling contract must have an ETH balance of at least `value`.\\n * - the called Solidity function must be `payable`.\\n *\\n * _Available since v3.1._\\n */\\n function functionCallWithValue(\\n address target,\\n bytes memory data,\\n uint256 value\\n ) internal returns (bytes memory) {\\n return functionCallWithValue(target, data, value, \\\"Address: low-level call with value failed\\\");\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but\\n * with `errorMessage` as a fallback revert reason when `target` reverts.\\n *\\n * _Available since v3.1._\\n */\\n function functionCallWithValue(\\n address target,\\n bytes memory data,\\n uint256 value,\\n string memory errorMessage\\n ) internal returns (bytes memory) {\\n require(address(this).balance >= value, \\\"Address: insufficient balance for call\\\");\\n (bool success, bytes memory returndata) = target.call{value: value}(data);\\n return verifyCallResultFromTarget(target, success, returndata, errorMessage);\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\\n * but performing a static call.\\n *\\n * _Available since v3.3._\\n */\\n function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {\\n return functionStaticCall(target, data, \\\"Address: low-level static call failed\\\");\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\\n * but performing a static call.\\n *\\n * _Available since v3.3._\\n */\\n function functionStaticCall(\\n address target,\\n bytes memory data,\\n string memory errorMessage\\n ) internal view returns (bytes memory) {\\n (bool success, bytes memory returndata) = target.staticcall(data);\\n return verifyCallResultFromTarget(target, success, returndata, errorMessage);\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\\n * but performing a delegate call.\\n *\\n * _Available since v3.4._\\n */\\n function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {\\n return functionDelegateCall(target, data, \\\"Address: low-level delegate call failed\\\");\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\\n * but performing a delegate call.\\n *\\n * _Available since v3.4._\\n */\\n function functionDelegateCall(\\n address target,\\n bytes memory data,\\n string memory errorMessage\\n ) internal returns (bytes memory) {\\n (bool success, bytes memory returndata) = target.delegatecall(data);\\n return verifyCallResultFromTarget(target, success, returndata, errorMessage);\\n }\\n\\n /**\\n * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling\\n * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.\\n *\\n * _Available since v4.8._\\n */\\n function verifyCallResultFromTarget(\\n address target,\\n bool success,\\n bytes memory returndata,\\n string memory errorMessage\\n ) internal view returns (bytes memory) {\\n if (success) {\\n if (returndata.length == 0) {\\n // only check isContract if the call was successful and the return data is empty\\n // otherwise we already know that it was a contract\\n require(isContract(target), \\\"Address: call to non-contract\\\");\\n }\\n return returndata;\\n } else {\\n _revert(returndata, errorMessage);\\n }\\n }\\n\\n /**\\n * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the\\n * revert reason or using the provided one.\\n *\\n * _Available since v4.3._\\n */\\n function verifyCallResult(\\n bool success,\\n bytes memory returndata,\\n string memory errorMessage\\n ) internal pure returns (bytes memory) {\\n if (success) {\\n return returndata;\\n } else {\\n _revert(returndata, errorMessage);\\n }\\n }\\n\\n function _revert(bytes memory returndata, string memory errorMessage) private pure {\\n // Look for revert reason and bubble it up if present\\n if (returndata.length > 0) {\\n // The easiest way to bubble the revert reason is using memory via assembly\\n /// @solidity memory-safe-assembly\\n assembly {\\n let returndata_size := mload(returndata)\\n revert(add(32, returndata), returndata_size)\\n }\\n } else {\\n revert(errorMessage);\\n }\\n }\\n}\\n\",\"keccak256\":\"0xf96f969e24029d43d0df89e59d365f277021dac62b48e1c1e3ebe0acdd7f1ca1\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Create2.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/Create2.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Helper to make usage of the `CREATE2` EVM opcode easier and safer.\\n * `CREATE2` can be used to compute in advance the address where a smart\\n * contract will be deployed, which allows for interesting new mechanisms known\\n * as 'counterfactual interactions'.\\n *\\n * See the https://eips.ethereum.org/EIPS/eip-1014#motivation[EIP] for more\\n * information.\\n */\\nlibrary Create2 {\\n /**\\n * @dev Deploys a contract using `CREATE2`. The address where the contract\\n * will be deployed can be known in advance via {computeAddress}.\\n *\\n * The bytecode for a contract can be obtained from Solidity with\\n * `type(contractName).creationCode`.\\n *\\n * Requirements:\\n *\\n * - `bytecode` must not be empty.\\n * - `salt` must have not been used for `bytecode` already.\\n * - the factory must have a balance of at least `amount`.\\n * - if `amount` is non-zero, `bytecode` must have a `payable` constructor.\\n */\\n function deploy(\\n uint256 amount,\\n bytes32 salt,\\n bytes memory bytecode\\n ) internal returns (address addr) {\\n require(address(this).balance >= amount, \\\"Create2: insufficient balance\\\");\\n require(bytecode.length != 0, \\\"Create2: bytecode length is zero\\\");\\n /// @solidity memory-safe-assembly\\n assembly {\\n addr := create2(amount, add(bytecode, 0x20), mload(bytecode), salt)\\n }\\n require(addr != address(0), \\\"Create2: Failed on deploy\\\");\\n }\\n\\n /**\\n * @dev Returns the address where a contract will be stored if deployed via {deploy}. Any change in the\\n * `bytecodeHash` or `salt` will result in a new destination address.\\n */\\n function computeAddress(bytes32 salt, bytes32 bytecodeHash) internal view returns (address) {\\n return computeAddress(salt, bytecodeHash, address(this));\\n }\\n\\n /**\\n * @dev Returns the address where a contract will be stored if deployed via {deploy} from a contract located at\\n * `deployer`. If `deployer` is this contract's address, returns the same value as {computeAddress}.\\n */\\n function computeAddress(\\n bytes32 salt,\\n bytes32 bytecodeHash,\\n address deployer\\n ) internal pure returns (address addr) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n let ptr := mload(0x40) // Get free memory pointer\\n\\n // | | \\u2193 ptr ... \\u2193 ptr + 0x0B (start) ... \\u2193 ptr + 0x20 ... \\u2193 ptr + 0x40 ... |\\n // |-------------------|---------------------------------------------------------------------------|\\n // | bytecodeHash | CCCCCCCCCCCCC...CC |\\n // | salt | BBBBBBBBBBBBB...BB |\\n // | deployer | 000000...0000AAAAAAAAAAAAAAAAAAA...AA |\\n // | 0xFF | FF |\\n // |-------------------|---------------------------------------------------------------------------|\\n // | memory | 000000...00FFAAAAAAAAAAAAAAAAAAA...AABBBBBBBBBBBBB...BBCCCCCCCCCCCCC...CC |\\n // | keccak(start, 85) | \\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191\\u2191 |\\n\\n mstore(add(ptr, 0x40), bytecodeHash)\\n mstore(add(ptr, 0x20), salt)\\n mstore(ptr, deployer) // Right-aligned with 12 preceding garbage bytes\\n let start := add(ptr, 0x0b) // The hashed data starts at the final garbage byte which we will set to 0xff\\n mstore8(start, 0xff)\\n addr := keccak256(start, 85)\\n }\\n }\\n}\\n\",\"keccak256\":\"0xafc07f37809f74d9c66d6461cc0f85fb5147ab855acd0acc30af4b2272130c61\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/StorageSlot.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.7.0) (utils/StorageSlot.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Library for reading and writing primitive types to specific storage slots.\\n *\\n * Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts.\\n * This library helps with reading and writing to such slots without the need for inline assembly.\\n *\\n * The functions in this library return Slot structs that contain a `value` member that can be used to read or write.\\n *\\n * Example usage to set ERC1967 implementation slot:\\n * ```\\n * contract ERC1967 {\\n * bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;\\n *\\n * function _getImplementation() internal view returns (address) {\\n * return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;\\n * }\\n *\\n * function _setImplementation(address newImplementation) internal {\\n * require(Address.isContract(newImplementation), \\\"ERC1967: new implementation is not a contract\\\");\\n * StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;\\n * }\\n * }\\n * ```\\n *\\n * _Available since v4.1 for `address`, `bool`, `bytes32`, and `uint256`._\\n */\\nlibrary StorageSlot {\\n struct AddressSlot {\\n address value;\\n }\\n\\n struct BooleanSlot {\\n bool value;\\n }\\n\\n struct Bytes32Slot {\\n bytes32 value;\\n }\\n\\n struct Uint256Slot {\\n uint256 value;\\n }\\n\\n /**\\n * @dev Returns an `AddressSlot` with member `value` located at `slot`.\\n */\\n function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n r.slot := slot\\n }\\n }\\n\\n /**\\n * @dev Returns an `BooleanSlot` with member `value` located at `slot`.\\n */\\n function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n r.slot := slot\\n }\\n }\\n\\n /**\\n * @dev Returns an `Bytes32Slot` with member `value` located at `slot`.\\n */\\n function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n r.slot := slot\\n }\\n }\\n\\n /**\\n * @dev Returns an `Uint256Slot` with member `value` located at `slot`.\\n */\\n function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n r.slot := slot\\n }\\n }\\n}\\n\",\"keccak256\":\"0xd5c50c54bf02740ebd122ff06832546cb5fa84486d52695a9ccfd11666e0c81d\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Strings.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/Strings.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"./math/Math.sol\\\";\\n\\n/**\\n * @dev String operations.\\n */\\nlibrary Strings {\\n bytes16 private constant _SYMBOLS = \\\"0123456789abcdef\\\";\\n uint8 private constant _ADDRESS_LENGTH = 20;\\n\\n /**\\n * @dev Converts a `uint256` to its ASCII `string` decimal representation.\\n */\\n function toString(uint256 value) internal pure returns (string memory) {\\n unchecked {\\n uint256 length = Math.log10(value) + 1;\\n string memory buffer = new string(length);\\n uint256 ptr;\\n /// @solidity memory-safe-assembly\\n assembly {\\n ptr := add(buffer, add(32, length))\\n }\\n while (true) {\\n ptr--;\\n /// @solidity memory-safe-assembly\\n assembly {\\n mstore8(ptr, byte(mod(value, 10), _SYMBOLS))\\n }\\n value /= 10;\\n if (value == 0) break;\\n }\\n return buffer;\\n }\\n }\\n\\n /**\\n * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.\\n */\\n function toHexString(uint256 value) internal pure returns (string memory) {\\n unchecked {\\n return toHexString(value, Math.log256(value) + 1);\\n }\\n }\\n\\n /**\\n * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.\\n */\\n function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {\\n bytes memory buffer = new bytes(2 * length + 2);\\n buffer[0] = \\\"0\\\";\\n buffer[1] = \\\"x\\\";\\n for (uint256 i = 2 * length + 1; i > 1; --i) {\\n buffer[i] = _SYMBOLS[value & 0xf];\\n value >>= 4;\\n }\\n require(value == 0, \\\"Strings: hex length insufficient\\\");\\n return string(buffer);\\n }\\n\\n /**\\n * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation.\\n */\\n function toHexString(address addr) internal pure returns (string memory) {\\n return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);\\n }\\n}\\n\",\"keccak256\":\"0xa4d1d62251f8574deb032a35fc948386a9b4de74b812d4f545a1ac120486b48a\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/cryptography/ECDSA.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/ECDSA.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../Strings.sol\\\";\\n\\n/**\\n * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations.\\n *\\n * These functions can be used to verify that a message was signed by the holder\\n * of the private keys of a given address.\\n */\\nlibrary ECDSA {\\n enum RecoverError {\\n NoError,\\n InvalidSignature,\\n InvalidSignatureLength,\\n InvalidSignatureS,\\n InvalidSignatureV // Deprecated in v4.8\\n }\\n\\n function _throwError(RecoverError error) private pure {\\n if (error == RecoverError.NoError) {\\n return; // no error: do nothing\\n } else if (error == RecoverError.InvalidSignature) {\\n revert(\\\"ECDSA: invalid signature\\\");\\n } else if (error == RecoverError.InvalidSignatureLength) {\\n revert(\\\"ECDSA: invalid signature length\\\");\\n } else if (error == RecoverError.InvalidSignatureS) {\\n revert(\\\"ECDSA: invalid signature 's' value\\\");\\n }\\n }\\n\\n /**\\n * @dev Returns the address that signed a hashed message (`hash`) with\\n * `signature` or error string. This address can then be used for verification purposes.\\n *\\n * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:\\n * this function rejects them by requiring the `s` value to be in the lower\\n * half order, and the `v` value to be either 27 or 28.\\n *\\n * IMPORTANT: `hash` _must_ be the result of a hash operation for the\\n * verification to be secure: it is possible to craft signatures that\\n * recover to arbitrary addresses for non-hashed data. A safe way to ensure\\n * this is by receiving a hash of the original message (which may otherwise\\n * be too long), and then calling {toEthSignedMessageHash} on it.\\n *\\n * Documentation for signature generation:\\n * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js]\\n * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers]\\n *\\n * _Available since v4.3._\\n */\\n function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) {\\n if (signature.length == 65) {\\n bytes32 r;\\n bytes32 s;\\n uint8 v;\\n // ecrecover takes the signature parameters, and the only way to get them\\n // currently is to use assembly.\\n /// @solidity memory-safe-assembly\\n assembly {\\n r := mload(add(signature, 0x20))\\n s := mload(add(signature, 0x40))\\n v := byte(0, mload(add(signature, 0x60)))\\n }\\n return tryRecover(hash, v, r, s);\\n } else {\\n return (address(0), RecoverError.InvalidSignatureLength);\\n }\\n }\\n\\n /**\\n * @dev Returns the address that signed a hashed message (`hash`) with\\n * `signature`. This address can then be used for verification purposes.\\n *\\n * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:\\n * this function rejects them by requiring the `s` value to be in the lower\\n * half order, and the `v` value to be either 27 or 28.\\n *\\n * IMPORTANT: `hash` _must_ be the result of a hash operation for the\\n * verification to be secure: it is possible to craft signatures that\\n * recover to arbitrary addresses for non-hashed data. A safe way to ensure\\n * this is by receiving a hash of the original message (which may otherwise\\n * be too long), and then calling {toEthSignedMessageHash} on it.\\n */\\n function recover(bytes32 hash, bytes memory signature) internal pure returns (address) {\\n (address recovered, RecoverError error) = tryRecover(hash, signature);\\n _throwError(error);\\n return recovered;\\n }\\n\\n /**\\n * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately.\\n *\\n * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures]\\n *\\n * _Available since v4.3._\\n */\\n function tryRecover(\\n bytes32 hash,\\n bytes32 r,\\n bytes32 vs\\n ) internal pure returns (address, RecoverError) {\\n bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff);\\n uint8 v = uint8((uint256(vs) >> 255) + 27);\\n return tryRecover(hash, v, r, s);\\n }\\n\\n /**\\n * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately.\\n *\\n * _Available since v4.2._\\n */\\n function recover(\\n bytes32 hash,\\n bytes32 r,\\n bytes32 vs\\n ) internal pure returns (address) {\\n (address recovered, RecoverError error) = tryRecover(hash, r, vs);\\n _throwError(error);\\n return recovered;\\n }\\n\\n /**\\n * @dev Overload of {ECDSA-tryRecover} that receives the `v`,\\n * `r` and `s` signature fields separately.\\n *\\n * _Available since v4.3._\\n */\\n function tryRecover(\\n bytes32 hash,\\n uint8 v,\\n bytes32 r,\\n bytes32 s\\n ) internal pure returns (address, RecoverError) {\\n // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature\\n // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines\\n // the valid range for s in (301): 0 < s < secp256k1n \\u00f7 2 + 1, and for v in (302): v \\u2208 {27, 28}. Most\\n // signatures from current libraries generate a unique signature with an s-value in the lower half order.\\n //\\n // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value\\n // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or\\n // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept\\n // these malleable signatures as well.\\n if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) {\\n return (address(0), RecoverError.InvalidSignatureS);\\n }\\n\\n // If the signature is valid (and not malleable), return the signer address\\n address signer = ecrecover(hash, v, r, s);\\n if (signer == address(0)) {\\n return (address(0), RecoverError.InvalidSignature);\\n }\\n\\n return (signer, RecoverError.NoError);\\n }\\n\\n /**\\n * @dev Overload of {ECDSA-recover} that receives the `v`,\\n * `r` and `s` signature fields separately.\\n */\\n function recover(\\n bytes32 hash,\\n uint8 v,\\n bytes32 r,\\n bytes32 s\\n ) internal pure returns (address) {\\n (address recovered, RecoverError error) = tryRecover(hash, v, r, s);\\n _throwError(error);\\n return recovered;\\n }\\n\\n /**\\n * @dev Returns an Ethereum Signed Message, created from a `hash`. This\\n * produces hash corresponding to the one signed with the\\n * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]\\n * JSON-RPC method as part of EIP-191.\\n *\\n * See {recover}.\\n */\\n function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) {\\n // 32 is the length in bytes of hash,\\n // enforced by the type signature above\\n return keccak256(abi.encodePacked(\\\"\\\\x19Ethereum Signed Message:\\\\n32\\\", hash));\\n }\\n\\n /**\\n * @dev Returns an Ethereum Signed Message, created from `s`. This\\n * produces hash corresponding to the one signed with the\\n * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]\\n * JSON-RPC method as part of EIP-191.\\n *\\n * See {recover}.\\n */\\n function toEthSignedMessageHash(bytes memory s) internal pure returns (bytes32) {\\n return keccak256(abi.encodePacked(\\\"\\\\x19Ethereum Signed Message:\\\\n\\\", Strings.toString(s.length), s));\\n }\\n\\n /**\\n * @dev Returns an Ethereum Signed Typed Data, created from a\\n * `domainSeparator` and a `structHash`. This produces hash corresponding\\n * to the one signed with the\\n * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`]\\n * JSON-RPC method as part of EIP-712.\\n *\\n * See {recover}.\\n */\\n function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) {\\n return keccak256(abi.encodePacked(\\\"\\\\x19\\\\x01\\\", domainSeparator, structHash));\\n }\\n}\\n\",\"keccak256\":\"0xda898fa084aa1ddfdb346e6a40459e00a59d87071cce7c315a46d648dd71d0ba\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/introspection/IERC165.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Interface of the ERC165 standard, as defined in the\\n * https://eips.ethereum.org/EIPS/eip-165[EIP].\\n *\\n * Implementers can declare support of contract interfaces, which can then be\\n * queried by others ({ERC165Checker}).\\n *\\n * For an implementation, see {ERC165}.\\n */\\ninterface IERC165 {\\n /**\\n * @dev Returns true if this contract implements the interface defined by\\n * `interfaceId`. See the corresponding\\n * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]\\n * to learn more about how these ids are created.\\n *\\n * This function call must use less than 30 000 gas.\\n */\\n function supportsInterface(bytes4 interfaceId) external view returns (bool);\\n}\\n\",\"keccak256\":\"0x447a5f3ddc18419d41ff92b3773fb86471b1db25773e07f877f548918a185bf1\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/math/Math.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/Math.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Standard math utilities missing in the Solidity language.\\n */\\nlibrary Math {\\n enum Rounding {\\n Down, // Toward negative infinity\\n Up, // Toward infinity\\n Zero // Toward zero\\n }\\n\\n /**\\n * @dev Returns the largest of two numbers.\\n */\\n function max(uint256 a, uint256 b) internal pure returns (uint256) {\\n return a > b ? a : b;\\n }\\n\\n /**\\n * @dev Returns the smallest of two numbers.\\n */\\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\\n return a < b ? a : b;\\n }\\n\\n /**\\n * @dev Returns the average of two numbers. The result is rounded towards\\n * zero.\\n */\\n function average(uint256 a, uint256 b) internal pure returns (uint256) {\\n // (a + b) / 2 can overflow.\\n return (a & b) + (a ^ b) / 2;\\n }\\n\\n /**\\n * @dev Returns the ceiling of the division of two numbers.\\n *\\n * This differs from standard division with `/` in that it rounds up instead\\n * of rounding down.\\n */\\n function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {\\n // (a + b - 1) / b can overflow on addition, so we distribute.\\n return a == 0 ? 0 : (a - 1) / b + 1;\\n }\\n\\n /**\\n * @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or denominator == 0\\n * @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv)\\n * with further edits by Uniswap Labs also under MIT license.\\n */\\n function mulDiv(\\n uint256 x,\\n uint256 y,\\n uint256 denominator\\n ) internal pure returns (uint256 result) {\\n unchecked {\\n // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use\\n // use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256\\n // variables such that product = prod1 * 2^256 + prod0.\\n uint256 prod0; // Least significant 256 bits of the product\\n uint256 prod1; // Most significant 256 bits of the product\\n assembly {\\n let mm := mulmod(x, y, not(0))\\n prod0 := mul(x, y)\\n prod1 := sub(sub(mm, prod0), lt(mm, prod0))\\n }\\n\\n // Handle non-overflow cases, 256 by 256 division.\\n if (prod1 == 0) {\\n return prod0 / denominator;\\n }\\n\\n // Make sure the result is less than 2^256. Also prevents denominator == 0.\\n require(denominator > prod1);\\n\\n ///////////////////////////////////////////////\\n // 512 by 256 division.\\n ///////////////////////////////////////////////\\n\\n // Make division exact by subtracting the remainder from [prod1 prod0].\\n uint256 remainder;\\n assembly {\\n // Compute remainder using mulmod.\\n remainder := mulmod(x, y, denominator)\\n\\n // Subtract 256 bit number from 512 bit number.\\n prod1 := sub(prod1, gt(remainder, prod0))\\n prod0 := sub(prod0, remainder)\\n }\\n\\n // Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1.\\n // See https://cs.stackexchange.com/q/138556/92363.\\n\\n // Does not overflow because the denominator cannot be zero at this stage in the function.\\n uint256 twos = denominator & (~denominator + 1);\\n assembly {\\n // Divide denominator by twos.\\n denominator := div(denominator, twos)\\n\\n // Divide [prod1 prod0] by twos.\\n prod0 := div(prod0, twos)\\n\\n // Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one.\\n twos := add(div(sub(0, twos), twos), 1)\\n }\\n\\n // Shift in bits from prod1 into prod0.\\n prod0 |= prod1 * twos;\\n\\n // Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such\\n // that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for\\n // four bits. That is, denominator * inv = 1 mod 2^4.\\n uint256 inverse = (3 * denominator) ^ 2;\\n\\n // Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also works\\n // in modular arithmetic, doubling the correct bits in each step.\\n inverse *= 2 - denominator * inverse; // inverse mod 2^8\\n inverse *= 2 - denominator * inverse; // inverse mod 2^16\\n inverse *= 2 - denominator * inverse; // inverse mod 2^32\\n inverse *= 2 - denominator * inverse; // inverse mod 2^64\\n inverse *= 2 - denominator * inverse; // inverse mod 2^128\\n inverse *= 2 - denominator * inverse; // inverse mod 2^256\\n\\n // Because the division is now exact we can divide by multiplying with the modular inverse of denominator.\\n // This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is\\n // less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1\\n // is no longer required.\\n result = prod0 * inverse;\\n return result;\\n }\\n }\\n\\n /**\\n * @notice Calculates x * y / denominator with full precision, following the selected rounding direction.\\n */\\n function mulDiv(\\n uint256 x,\\n uint256 y,\\n uint256 denominator,\\n Rounding rounding\\n ) internal pure returns (uint256) {\\n uint256 result = mulDiv(x, y, denominator);\\n if (rounding == Rounding.Up && mulmod(x, y, denominator) > 0) {\\n result += 1;\\n }\\n return result;\\n }\\n\\n /**\\n * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded down.\\n *\\n * Inspired by Henry S. Warren, Jr.'s \\\"Hacker's Delight\\\" (Chapter 11).\\n */\\n function sqrt(uint256 a) internal pure returns (uint256) {\\n if (a == 0) {\\n return 0;\\n }\\n\\n // For our first guess, we get the biggest power of 2 which is smaller than the square root of the target.\\n //\\n // We know that the \\\"msb\\\" (most significant bit) of our target number `a` is a power of 2 such that we have\\n // `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`.\\n //\\n // This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)`\\n // \\u2192 `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))`\\n // \\u2192 `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)`\\n //\\n // Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit.\\n uint256 result = 1 << (log2(a) >> 1);\\n\\n // At this point `result` is an estimation with one bit of precision. We know the true value is a uint128,\\n // since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at\\n // every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision\\n // into the expected uint128 result.\\n unchecked {\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n return min(result, a / result);\\n }\\n }\\n\\n /**\\n * @notice Calculates sqrt(a), following the selected rounding direction.\\n */\\n function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) {\\n unchecked {\\n uint256 result = sqrt(a);\\n return result + (rounding == Rounding.Up && result * result < a ? 1 : 0);\\n }\\n }\\n\\n /**\\n * @dev Return the log in base 2, rounded down, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log2(uint256 value) internal pure returns (uint256) {\\n uint256 result = 0;\\n unchecked {\\n if (value >> 128 > 0) {\\n value >>= 128;\\n result += 128;\\n }\\n if (value >> 64 > 0) {\\n value >>= 64;\\n result += 64;\\n }\\n if (value >> 32 > 0) {\\n value >>= 32;\\n result += 32;\\n }\\n if (value >> 16 > 0) {\\n value >>= 16;\\n result += 16;\\n }\\n if (value >> 8 > 0) {\\n value >>= 8;\\n result += 8;\\n }\\n if (value >> 4 > 0) {\\n value >>= 4;\\n result += 4;\\n }\\n if (value >> 2 > 0) {\\n value >>= 2;\\n result += 2;\\n }\\n if (value >> 1 > 0) {\\n result += 1;\\n }\\n }\\n return result;\\n }\\n\\n /**\\n * @dev Return the log in base 2, following the selected rounding direction, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log2(uint256 value, Rounding rounding) internal pure returns (uint256) {\\n unchecked {\\n uint256 result = log2(value);\\n return result + (rounding == Rounding.Up && 1 << result < value ? 1 : 0);\\n }\\n }\\n\\n /**\\n * @dev Return the log in base 10, rounded down, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log10(uint256 value) internal pure returns (uint256) {\\n uint256 result = 0;\\n unchecked {\\n if (value >= 10**64) {\\n value /= 10**64;\\n result += 64;\\n }\\n if (value >= 10**32) {\\n value /= 10**32;\\n result += 32;\\n }\\n if (value >= 10**16) {\\n value /= 10**16;\\n result += 16;\\n }\\n if (value >= 10**8) {\\n value /= 10**8;\\n result += 8;\\n }\\n if (value >= 10**4) {\\n value /= 10**4;\\n result += 4;\\n }\\n if (value >= 10**2) {\\n value /= 10**2;\\n result += 2;\\n }\\n if (value >= 10**1) {\\n result += 1;\\n }\\n }\\n return result;\\n }\\n\\n /**\\n * @dev Return the log in base 10, following the selected rounding direction, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log10(uint256 value, Rounding rounding) internal pure returns (uint256) {\\n unchecked {\\n uint256 result = log10(value);\\n return result + (rounding == Rounding.Up && 10**result < value ? 1 : 0);\\n }\\n }\\n\\n /**\\n * @dev Return the log in base 256, rounded down, of a positive value.\\n * Returns 0 if given 0.\\n *\\n * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string.\\n */\\n function log256(uint256 value) internal pure returns (uint256) {\\n uint256 result = 0;\\n unchecked {\\n if (value >> 128 > 0) {\\n value >>= 128;\\n result += 16;\\n }\\n if (value >> 64 > 0) {\\n value >>= 64;\\n result += 8;\\n }\\n if (value >> 32 > 0) {\\n value >>= 32;\\n result += 4;\\n }\\n if (value >> 16 > 0) {\\n value >>= 16;\\n result += 2;\\n }\\n if (value >> 8 > 0) {\\n result += 1;\\n }\\n }\\n return result;\\n }\\n\\n /**\\n * @dev Return the log in base 10, following the selected rounding direction, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log256(uint256 value, Rounding rounding) internal pure returns (uint256) {\\n unchecked {\\n uint256 result = log256(value);\\n return result + (rounding == Rounding.Up && 1 << (result * 8) < value ? 1 : 0);\\n }\\n }\\n}\\n\",\"keccak256\":\"0xa1e8e83cd0087785df04ac79fb395d9f3684caeaf973d9e2c71caef723a3a5d6\",\"license\":\"MIT\"},\"contracts/core/BaseAccount.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.12;\\n\\n/* solhint-disable avoid-low-level-calls */\\n/* solhint-disable no-empty-blocks */\\n\\nimport \\\"../interfaces/IAccount.sol\\\";\\nimport \\\"../interfaces/IEntryPoint.sol\\\";\\nimport \\\"./Helpers.sol\\\";\\n\\n/**\\n * Basic account implementation.\\n * this contract provides the basic logic for implementing the IAccount interface - validateUserOp\\n * specific account implementation should inherit it and provide the account-specific logic\\n */\\nabstract contract BaseAccount is IAccount {\\n using UserOperationLib for UserOperation;\\n\\n //return value in case of signature failure, with no time-range.\\n // equivalent to _packValidationData(true,0,0);\\n uint256 constant internal SIG_VALIDATION_FAILED = 1;\\n\\n /**\\n * Return the account nonce.\\n * This method returns the next sequential nonce.\\n * For a nonce of a specific key, use `entrypoint.getNonce(account, key)`\\n */\\n function getNonce() public view virtual returns (uint256) {\\n return entryPoint().getNonce(address(this), 0);\\n }\\n\\n /**\\n * return the entryPoint used by this account.\\n * subclass should return the current entryPoint used by this account.\\n */\\n function entryPoint() public view virtual returns (IEntryPoint);\\n\\n /**\\n * Validate user's signature and nonce.\\n * subclass doesn't need to override this method. Instead, it should override the specific internal validation methods.\\n */\\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\\n external override virtual returns (uint256 validationData) {\\n _requireFromEntryPoint();\\n validationData = _validateSignature(userOp, userOpHash);\\n _validateNonce(userOp.nonce);\\n _payPrefund(missingAccountFunds);\\n }\\n\\n /**\\n * ensure the request comes from the known entrypoint.\\n */\\n function _requireFromEntryPoint() internal virtual view {\\n require(msg.sender == address(entryPoint()), \\\"account: not from EntryPoint\\\");\\n }\\n\\n /**\\n * validate the signature is valid for this message.\\n * @param userOp validate the userOp.signature field\\n * @param userOpHash convenient field: the hash of the request, to check the signature against\\n * (also hashes the entrypoint and chain id)\\n * @return validationData signature and time-range of this operation\\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\\n * otherwise, an address of an \\\"authorizer\\\" contract.\\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \\\"indefinite\\\"\\n * <6-byte> validAfter - first timestamp this operation is valid\\n * If the account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\\n */\\n function _validateSignature(UserOperation calldata userOp, bytes32 userOpHash)\\n internal virtual returns (uint256 validationData);\\n\\n /**\\n * Validate the nonce of the UserOperation.\\n * This method may validate the nonce requirement of this account.\\n * e.g.\\n * To limit the nonce to use sequenced UserOps only (no \\\"out of order\\\" UserOps):\\n * `require(nonce < type(uint64).max)`\\n * For a hypothetical account that *requires* the nonce to be out-of-order:\\n * `require(nonce & type(uint64).max == 0)`\\n *\\n * The actual nonce uniqueness is managed by the EntryPoint, and thus no other\\n * action is needed by the account itself.\\n *\\n * @param nonce to validate\\n *\\n * solhint-disable-next-line no-empty-blocks\\n */\\n function _validateNonce(uint256 nonce) internal view virtual {\\n }\\n\\n /**\\n * sends to the entrypoint (msg.sender) the missing funds for this transaction.\\n * subclass MAY override this method for better funds management\\n * (e.g. send to the entryPoint more than the minimum required, so that in future transactions\\n * it will not be required to send again)\\n * @param missingAccountFunds the minimum value this method should send the entrypoint.\\n * this value MAY be zero, in case there is enough deposit, or the userOp has a paymaster.\\n */\\n function _payPrefund(uint256 missingAccountFunds) internal virtual {\\n if (missingAccountFunds != 0) {\\n (bool success,) = payable(msg.sender).call{value : missingAccountFunds, gas : type(uint256).max}(\\\"\\\");\\n (success);\\n //ignore failure (its EntryPoint's job to verify, not account.)\\n }\\n }\\n}\\n\",\"keccak256\":\"0x5eb3253b32fd8ba8ae7b9d83da8e9924254a4d3d17a8772b41280e8572974b3c\",\"license\":\"GPL-3.0\"},\"contracts/core/Helpers.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.12;\\n\\n/* solhint-disable no-inline-assembly */\\n\\n/**\\n * returned data from validateUserOp.\\n * validateUserOp returns a uint256, with is created by `_packedValidationData` and parsed by `_parseValidationData`\\n * @param aggregator - address(0) - the account validated the signature by itself.\\n * address(1) - the account failed to validate the signature.\\n * otherwise - this is an address of a signature aggregator that must be used to validate the signature.\\n * @param validAfter - this UserOp is valid only after this timestamp.\\n * @param validaUntil - this UserOp is valid only up to this timestamp.\\n */\\n struct ValidationData {\\n address aggregator;\\n uint48 validAfter;\\n uint48 validUntil;\\n }\\n\\n//extract sigFailed, validAfter, validUntil.\\n// also convert zero validUntil to type(uint48).max\\n function _parseValidationData(uint validationData) pure returns (ValidationData memory data) {\\n address aggregator = address(uint160(validationData));\\n uint48 validUntil = uint48(validationData >> 160);\\n if (validUntil == 0) {\\n validUntil = type(uint48).max;\\n }\\n uint48 validAfter = uint48(validationData >> (48 + 160));\\n return ValidationData(aggregator, validAfter, validUntil);\\n }\\n\\n// intersect account and paymaster ranges.\\n function _intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) pure returns (ValidationData memory) {\\n ValidationData memory accountValidationData = _parseValidationData(validationData);\\n ValidationData memory pmValidationData = _parseValidationData(paymasterValidationData);\\n address aggregator = accountValidationData.aggregator;\\n if (aggregator == address(0)) {\\n aggregator = pmValidationData.aggregator;\\n }\\n uint48 validAfter = accountValidationData.validAfter;\\n uint48 validUntil = accountValidationData.validUntil;\\n uint48 pmValidAfter = pmValidationData.validAfter;\\n uint48 pmValidUntil = pmValidationData.validUntil;\\n\\n if (validAfter < pmValidAfter) validAfter = pmValidAfter;\\n if (validUntil > pmValidUntil) validUntil = pmValidUntil;\\n return ValidationData(aggregator, validAfter, validUntil);\\n }\\n\\n/**\\n * helper to pack the return value for validateUserOp\\n * @param data - the ValidationData to pack\\n */\\n function _packValidationData(ValidationData memory data) pure returns (uint256) {\\n return uint160(data.aggregator) | (uint256(data.validUntil) << 160) | (uint256(data.validAfter) << (160 + 48));\\n }\\n\\n/**\\n * helper to pack the return value for validateUserOp, when not using an aggregator\\n * @param sigFailed - true for signature failure, false for success\\n * @param validUntil last timestamp this UserOperation is valid (or zero for infinite)\\n * @param validAfter first timestamp this UserOperation is valid\\n */\\n function _packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) pure returns (uint256) {\\n return (sigFailed ? 1 : 0) | (uint256(validUntil) << 160) | (uint256(validAfter) << (160 + 48));\\n }\\n\\n/**\\n * keccak function over calldata.\\n * @dev copy calldata into memory, do keccak and drop allocated memory. Strangely, this is more efficient than letting solidity do it.\\n */\\n function calldataKeccak(bytes calldata data) pure returns (bytes32 ret) {\\n assembly {\\n let mem := mload(0x40)\\n let len := data.length\\n calldatacopy(mem, data.offset, len)\\n ret := keccak256(mem, len)\\n }\\n }\\n\\n\",\"keccak256\":\"0x591c87519f7155d1909210276b77925ab2722a99b7b5d5649aecc36ebbdb045a\",\"license\":\"GPL-3.0\"},\"contracts/interfaces/IAccount.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.12;\\n\\nimport \\\"./UserOperation.sol\\\";\\n\\ninterface IAccount {\\n\\n /**\\n * Validate user's signature and nonce\\n * the entryPoint will make the call to the recipient only if this validation call returns successfully.\\n * signature failure should be reported by returning SIG_VALIDATION_FAILED (1).\\n * This allows making a \\\"simulation call\\\" without a valid signature\\n * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure.\\n *\\n * @dev Must validate caller is the entryPoint.\\n * Must validate the signature and nonce\\n * @param userOp the operation that is about to be executed.\\n * @param userOpHash hash of the user's request data. can be used as the basis for signature.\\n * @param missingAccountFunds missing funds on the account's deposit in the entrypoint.\\n * This is the minimum amount to transfer to the sender(entryPoint) to be able to make the call.\\n * The excess is left as a deposit in the entrypoint, for future calls.\\n * can be withdrawn anytime using \\\"entryPoint.withdrawTo()\\\"\\n * In case there is a paymaster in the request (or the current deposit is high enough), this value will be zero.\\n * @return validationData packaged ValidationData structure. use `_packValidationData` and `_unpackValidationData` to encode and decode\\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\\n * otherwise, an address of an \\\"authorizer\\\" contract.\\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \\\"indefinite\\\"\\n * <6-byte> validAfter - first timestamp this operation is valid\\n * If an account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\\n */\\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\\n external returns (uint256 validationData);\\n}\\n\",\"keccak256\":\"0x556a0e5980de18e90b115553ed502408155ba35f58642823010d9288047bc418\",\"license\":\"GPL-3.0\"},\"contracts/interfaces/IAggregator.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.12;\\n\\nimport \\\"./UserOperation.sol\\\";\\n\\n/**\\n * Aggregated Signatures validator.\\n */\\ninterface IAggregator {\\n\\n /**\\n * validate aggregated signature.\\n * revert if the aggregated signature does not match the given list of operations.\\n */\\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external view;\\n\\n /**\\n * validate signature of a single userOp\\n * This method is should be called by bundler after EntryPoint.simulateValidation() returns (reverts) with ValidationResultWithAggregation\\n * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps.\\n * @param userOp the userOperation received from the user.\\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\\n * (usually empty, unless account and aggregator support some kind of \\\"multisig\\\"\\n */\\n function validateUserOpSignature(UserOperation calldata userOp)\\n external view returns (bytes memory sigForUserOp);\\n\\n /**\\n * aggregate multiple signatures into a single value.\\n * This method is called off-chain to calculate the signature to pass with handleOps()\\n * bundler MAY use optimized custom code perform this aggregation\\n * @param userOps array of UserOperations to collect the signatures from.\\n * @return aggregatedSignature the aggregated signature\\n */\\n function aggregateSignatures(UserOperation[] calldata userOps) external view returns (bytes memory aggregatedSignature);\\n}\\n\",\"keccak256\":\"0x060e9ddb0152250c269ba0640dc5753834ac44cf182a2837d508c0c529cae26a\",\"license\":\"GPL-3.0\"},\"contracts/interfaces/IEntryPoint.sol\":{\"content\":\"/**\\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\\n ** Only one instance required on each chain.\\n **/\\n// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.12;\\n\\n/* solhint-disable avoid-low-level-calls */\\n/* solhint-disable no-inline-assembly */\\n/* solhint-disable reason-string */\\n\\nimport \\\"./UserOperation.sol\\\";\\nimport \\\"./IStakeManager.sol\\\";\\nimport \\\"./IAggregator.sol\\\";\\nimport \\\"./INonceManager.sol\\\";\\n\\ninterface IEntryPoint is IStakeManager, INonceManager {\\n\\n /***\\n * An event emitted after each successful request\\n * @param userOpHash - unique identifier for the request (hash its entire content, except signature).\\n * @param sender - the account that generates this request.\\n * @param paymaster - if non-null, the paymaster that pays for this request.\\n * @param nonce - the nonce value from the request.\\n * @param success - true if the sender transaction succeeded, false if reverted.\\n * @param actualGasCost - actual amount paid (by account or paymaster) for this UserOperation.\\n * @param actualGasUsed - total gas used by this UserOperation (including preVerification, creation, validation and execution).\\n */\\n event UserOperationEvent(bytes32 indexed userOpHash, address indexed sender, address indexed paymaster, uint256 nonce, bool success, uint256 actualGasCost, uint256 actualGasUsed);\\n\\n /**\\n * account \\\"sender\\\" was deployed.\\n * @param userOpHash the userOp that deployed this account. UserOperationEvent will follow.\\n * @param sender the account that is deployed\\n * @param factory the factory used to deploy this account (in the initCode)\\n * @param paymaster the paymaster used by this UserOp\\n */\\n event AccountDeployed(bytes32 indexed userOpHash, address indexed sender, address factory, address paymaster);\\n\\n /**\\n * An event emitted if the UserOperation \\\"callData\\\" reverted with non-zero length\\n * @param userOpHash the request unique identifier.\\n * @param sender the sender of this request\\n * @param nonce the nonce used in the request\\n * @param revertReason - the return bytes from the (reverted) call to \\\"callData\\\".\\n */\\n event UserOperationRevertReason(bytes32 indexed userOpHash, address indexed sender, uint256 nonce, bytes revertReason);\\n\\n /**\\n * an event emitted by handleOps(), before starting the execution loop.\\n * any event emitted before this event, is part of the validation.\\n */\\n event BeforeExecution();\\n\\n /**\\n * signature aggregator used by the following UserOperationEvents within this bundle.\\n */\\n event SignatureAggregatorChanged(address indexed aggregator);\\n\\n /**\\n * a custom revert error of handleOps, to identify the offending op.\\n * NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\\n * @param opIndex - index into the array of ops to the failed one (in simulateValidation, this is always zero)\\n * @param reason - revert reason\\n * The string starts with a unique code \\\"AAmn\\\", where \\\"m\\\" is \\\"1\\\" for factory, \\\"2\\\" for account and \\\"3\\\" for paymaster issues,\\n * so a failure can be attributed to the correct entity.\\n * Should be caught in off-chain handleOps simulation and not happen on-chain.\\n * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\\n */\\n error FailedOp(uint256 opIndex, string reason);\\n\\n /**\\n * error case when a signature aggregator fails to verify the aggregated signature it had created.\\n */\\n error SignatureValidationFailed(address aggregator);\\n\\n /**\\n * Successful result from simulateValidation.\\n * @param returnInfo gas and time-range returned values\\n * @param senderInfo stake information about the sender\\n * @param factoryInfo stake information about the factory (if any)\\n * @param paymasterInfo stake information about the paymaster (if any)\\n */\\n error ValidationResult(ReturnInfo returnInfo,\\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo);\\n\\n /**\\n * Successful result from simulateValidation, if the account returns a signature aggregator\\n * @param returnInfo gas and time-range returned values\\n * @param senderInfo stake information about the sender\\n * @param factoryInfo stake information about the factory (if any)\\n * @param paymasterInfo stake information about the paymaster (if any)\\n * @param aggregatorInfo signature aggregation info (if the account requires signature aggregator)\\n * bundler MUST use it to verify the signature, or reject the UserOperation\\n */\\n error ValidationResultWithAggregation(ReturnInfo returnInfo,\\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo,\\n AggregatorStakeInfo aggregatorInfo);\\n\\n /**\\n * return value of getSenderAddress\\n */\\n error SenderAddressResult(address sender);\\n\\n /**\\n * return value of simulateHandleOp\\n */\\n error ExecutionResult(uint256 preOpGas, uint256 paid, uint48 validAfter, uint48 validUntil, bool targetSuccess, bytes targetResult);\\n\\n //UserOps handled, per aggregator\\n struct UserOpsPerAggregator {\\n UserOperation[] userOps;\\n\\n // aggregator address\\n IAggregator aggregator;\\n // aggregated signature\\n bytes signature;\\n }\\n\\n /**\\n * Execute a batch of UserOperation.\\n * no signature aggregator is used.\\n * if any account requires an aggregator (that is, it returned an aggregator when\\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\\n * @param ops the operations to execute\\n * @param beneficiary the address to receive the fees\\n */\\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) external;\\n\\n /**\\n * Execute a batch of UserOperation with Aggregators\\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\\n * @param beneficiary the address to receive the fees\\n */\\n function handleAggregatedOps(\\n UserOpsPerAggregator[] calldata opsPerAggregator,\\n address payable beneficiary\\n ) external;\\n\\n /**\\n * generate a request Id - unique identifier for this request.\\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\\n */\\n function getUserOpHash(UserOperation calldata userOp) external view returns (bytes32);\\n\\n /**\\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\\n * @param userOp the user operation to validate.\\n */\\n function simulateValidation(UserOperation calldata userOp) external;\\n\\n /**\\n * gas and return values during simulation\\n * @param preOpGas the gas used for validation (including preValidationGas)\\n * @param prefund the required prefund for this operation\\n * @param sigFailed validateUserOp's (or paymaster's) signature check failed\\n * @param validAfter - first timestamp this UserOp is valid (merging account and paymaster time-range)\\n * @param validUntil - last timestamp this UserOp is valid (merging account and paymaster time-range)\\n * @param paymasterContext returned by validatePaymasterUserOp (to be passed into postOp)\\n */\\n struct ReturnInfo {\\n uint256 preOpGas;\\n uint256 prefund;\\n bool sigFailed;\\n uint48 validAfter;\\n uint48 validUntil;\\n bytes paymasterContext;\\n }\\n\\n /**\\n * returned aggregated signature info.\\n * the aggregator returned by the account, and its current stake.\\n */\\n struct AggregatorStakeInfo {\\n address aggregator;\\n StakeInfo stakeInfo;\\n }\\n\\n /**\\n * Get counterfactual sender address.\\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\\n * this method always revert, and returns the address in SenderAddressResult error\\n * @param initCode the constructor code to be passed into the UserOperation.\\n */\\n function getSenderAddress(bytes memory initCode) external;\\n\\n\\n /**\\n * simulate full execution of a UserOperation (including both validation and target execution)\\n * this method will always revert with \\\"ExecutionResult\\\".\\n * it performs full validation of the UserOperation, but ignores signature error.\\n * an optional target address is called after the userop succeeds, and its value is returned\\n * (before the entire call is reverted)\\n * Note that in order to collect the the success/failure of the target call, it must be executed\\n * with trace enabled to track the emitted events.\\n * @param op the UserOperation to simulate\\n * @param target if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult\\n * are set to the return from that call.\\n * @param targetCallData callData to pass to target address\\n */\\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external;\\n}\\n\\n\",\"keccak256\":\"0x3a90bf308819ed125fa4202f880999caff8a8686633b8ddb79a30ca240d5b8f8\",\"license\":\"GPL-3.0\"},\"contracts/interfaces/INonceManager.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.12;\\n\\ninterface INonceManager {\\n\\n /**\\n * Return the next nonce for this sender.\\n * Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop)\\n * But UserOp with different keys can come with arbitrary order.\\n *\\n * @param sender the account address\\n * @param key the high 192 bit of the nonce\\n * @return nonce a full nonce to pass for next UserOp with this sender.\\n */\\n function getNonce(address sender, uint192 key)\\n external view returns (uint256 nonce);\\n\\n /**\\n * Manually increment the nonce of the sender.\\n * This method is exposed just for completeness..\\n * Account does NOT need to call it, neither during validation, nor elsewhere,\\n * as the EntryPoint will update the nonce regardless.\\n * Possible use-case is call it with various keys to \\\"initialize\\\" their nonces to one, so that future\\n * UserOperations will not pay extra for the first transaction with a given key.\\n */\\n function incrementNonce(uint192 key) external;\\n}\\n\",\"keccak256\":\"0x509871e6c63663cdcc3eba19920fe84e991f38b289b1377ac3c3a6d9f22d7e12\",\"license\":\"GPL-3.0\"},\"contracts/interfaces/IStakeManager.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0-only\\npragma solidity ^0.8.12;\\n\\n/**\\n * manage deposits and stakes.\\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\\n * stake is value locked for at least \\\"unstakeDelay\\\" by the staked entity.\\n */\\ninterface IStakeManager {\\n\\n event Deposited(\\n address indexed account,\\n uint256 totalDeposit\\n );\\n\\n event Withdrawn(\\n address indexed account,\\n address withdrawAddress,\\n uint256 amount\\n );\\n\\n /// Emitted when stake or unstake delay are modified\\n event StakeLocked(\\n address indexed account,\\n uint256 totalStaked,\\n uint256 unstakeDelaySec\\n );\\n\\n /// Emitted once a stake is scheduled for withdrawal\\n event StakeUnlocked(\\n address indexed account,\\n uint256 withdrawTime\\n );\\n\\n event StakeWithdrawn(\\n address indexed account,\\n address withdrawAddress,\\n uint256 amount\\n );\\n\\n /**\\n * @param deposit the entity's deposit\\n * @param staked true if this entity is staked.\\n * @param stake actual amount of ether staked for this entity.\\n * @param unstakeDelaySec minimum delay to withdraw the stake.\\n * @param withdrawTime - first block timestamp where 'withdrawStake' will be callable, or zero if already locked\\n * @dev sizes were chosen so that (deposit,staked, stake) fit into one cell (used during handleOps)\\n * and the rest fit into a 2nd cell.\\n * 112 bit allows for 10^15 eth\\n * 48 bit for full timestamp\\n * 32 bit allows 150 years for unstake delay\\n */\\n struct DepositInfo {\\n uint112 deposit;\\n bool staked;\\n uint112 stake;\\n uint32 unstakeDelaySec;\\n uint48 withdrawTime;\\n }\\n\\n //API struct used by getStakeInfo and simulateValidation\\n struct StakeInfo {\\n uint256 stake;\\n uint256 unstakeDelaySec;\\n }\\n\\n /// @return info - full deposit information of given account\\n function getDepositInfo(address account) external view returns (DepositInfo memory info);\\n\\n /// @return the deposit (for gas payment) of the account\\n function balanceOf(address account) external view returns (uint256);\\n\\n /**\\n * add to the deposit of the given account\\n */\\n function depositTo(address account) external payable;\\n\\n /**\\n * add to the account's stake - amount and delay\\n * any pending unstake is first cancelled.\\n * @param _unstakeDelaySec the new lock duration before the deposit can be withdrawn.\\n */\\n function addStake(uint32 _unstakeDelaySec) external payable;\\n\\n /**\\n * attempt to unlock the stake.\\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\\n */\\n function unlockStake() external;\\n\\n /**\\n * withdraw from the (unlocked) stake.\\n * must first call unlockStake and wait for the unstakeDelay to pass\\n * @param withdrawAddress the address to send withdrawn value.\\n */\\n function withdrawStake(address payable withdrawAddress) external;\\n\\n /**\\n * withdraw from the deposit.\\n * @param withdrawAddress the address to send withdrawn value.\\n * @param withdrawAmount the amount to withdraw.\\n */\\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external;\\n}\\n\",\"keccak256\":\"0xd227b02888cd4ac68daebcdfd992ec00f9fff66fa3b3bb16f656cd582fa3480f\",\"license\":\"GPL-3.0-only\"},\"contracts/interfaces/UserOperation.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.12;\\n\\n/* solhint-disable no-inline-assembly */\\n\\nimport {calldataKeccak} from \\\"../core/Helpers.sol\\\";\\n\\n/**\\n * User Operation struct\\n * @param sender the sender account of this request.\\n * @param nonce unique value the sender uses to verify it is not a replay.\\n * @param initCode if set, the account contract will be created by this constructor/\\n * @param callData the method call to execute on this account.\\n * @param callGasLimit the gas limit passed to the callData method call.\\n * @param verificationGasLimit gas used for validateUserOp and validatePaymasterUserOp.\\n * @param preVerificationGas gas not calculated by the handleOps method, but added to the gas paid. Covers batch overhead.\\n * @param maxFeePerGas same as EIP-1559 gas parameter.\\n * @param maxPriorityFeePerGas same as EIP-1559 gas parameter.\\n * @param paymasterAndData if set, this field holds the paymaster address and paymaster-specific data. the paymaster will pay for the transaction instead of the sender.\\n * @param signature sender-verified signature over the entire request, the EntryPoint address and the chain ID.\\n */\\n struct UserOperation {\\n\\n address sender;\\n uint256 nonce;\\n bytes initCode;\\n bytes callData;\\n uint256 callGasLimit;\\n uint256 verificationGasLimit;\\n uint256 preVerificationGas;\\n uint256 maxFeePerGas;\\n uint256 maxPriorityFeePerGas;\\n bytes paymasterAndData;\\n bytes signature;\\n }\\n\\n/**\\n * Utility functions helpful when working with UserOperation structs.\\n */\\nlibrary UserOperationLib {\\n\\n function getSender(UserOperation calldata userOp) internal pure returns (address) {\\n address data;\\n //read sender from userOp, which is first userOp member (saves 800 gas...)\\n assembly {data := calldataload(userOp)}\\n return address(uint160(data));\\n }\\n\\n //relayer/block builder might submit the TX with higher priorityFee, but the user should not\\n // pay above what he signed for.\\n function gasPrice(UserOperation calldata userOp) internal view returns (uint256) {\\n unchecked {\\n uint256 maxFeePerGas = userOp.maxFeePerGas;\\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\\n if (maxFeePerGas == maxPriorityFeePerGas) {\\n //legacy mode (for networks that don't support basefee opcode)\\n return maxFeePerGas;\\n }\\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\\n }\\n }\\n\\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\\n address sender = getSender(userOp);\\n uint256 nonce = userOp.nonce;\\n bytes32 hashInitCode = calldataKeccak(userOp.initCode);\\n bytes32 hashCallData = calldataKeccak(userOp.callData);\\n uint256 callGasLimit = userOp.callGasLimit;\\n uint256 verificationGasLimit = userOp.verificationGasLimit;\\n uint256 preVerificationGas = userOp.preVerificationGas;\\n uint256 maxFeePerGas = userOp.maxFeePerGas;\\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\\n bytes32 hashPaymasterAndData = calldataKeccak(userOp.paymasterAndData);\\n\\n return abi.encode(\\n sender, nonce,\\n hashInitCode, hashCallData,\\n callGasLimit, verificationGasLimit, preVerificationGas,\\n maxFeePerGas, maxPriorityFeePerGas,\\n hashPaymasterAndData\\n );\\n }\\n\\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\\n return keccak256(pack(userOp));\\n }\\n\\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\\n return a < b ? a : b;\\n }\\n}\\n\",\"keccak256\":\"0x61374003361059087fdcf17967a7bba052badeaf5c7f0ae689166f8aafd3a45c\",\"license\":\"GPL-3.0\"},\"contracts/samples/SimpleAccount.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.12;\\n\\n/* solhint-disable avoid-low-level-calls */\\n/* solhint-disable no-inline-assembly */\\n/* solhint-disable reason-string */\\n\\nimport \\\"@openzeppelin/contracts/utils/cryptography/ECDSA.sol\\\";\\nimport \\\"@openzeppelin/contracts/proxy/utils/Initializable.sol\\\";\\nimport \\\"@openzeppelin/contracts/proxy/utils/UUPSUpgradeable.sol\\\";\\n\\nimport \\\"../core/BaseAccount.sol\\\";\\nimport \\\"./callback/TokenCallbackHandler.sol\\\";\\n\\n/**\\n * minimal account.\\n * this is sample minimal account.\\n * has execute, eth handling methods\\n * has a single signer that can send requests through the entryPoint.\\n */\\ncontract SimpleAccount is BaseAccount, TokenCallbackHandler, UUPSUpgradeable, Initializable {\\n using ECDSA for bytes32;\\n\\n address public owner;\\n\\n IEntryPoint private immutable _entryPoint;\\n\\n event SimpleAccountInitialized(IEntryPoint indexed entryPoint, address indexed owner);\\n\\n modifier onlyOwner() {\\n _onlyOwner();\\n _;\\n }\\n\\n /// @inheritdoc BaseAccount\\n function entryPoint() public view virtual override returns (IEntryPoint) {\\n return _entryPoint;\\n }\\n\\n\\n // solhint-disable-next-line no-empty-blocks\\n receive() external payable {}\\n\\n constructor(IEntryPoint anEntryPoint) {\\n _entryPoint = anEntryPoint;\\n _disableInitializers();\\n }\\n\\n function _onlyOwner() internal view {\\n //directly from EOA owner, or through the account itself (which gets redirected through execute())\\n require(msg.sender == owner || msg.sender == address(this), \\\"only owner\\\");\\n }\\n\\n /**\\n * execute a transaction (called directly from owner, or by entryPoint)\\n */\\n function execute(address dest, uint256 value, bytes calldata func) external {\\n _requireFromEntryPointOrOwner();\\n _call(dest, value, func);\\n }\\n\\n /**\\n * execute a sequence of transactions\\n */\\n function executeBatch(address[] calldata dest, bytes[] calldata func) external {\\n _requireFromEntryPointOrOwner();\\n require(dest.length == func.length, \\\"wrong array lengths\\\");\\n for (uint256 i = 0; i < dest.length; i++) {\\n _call(dest[i], 0, func[i]);\\n }\\n }\\n\\n /**\\n * @dev The _entryPoint member is immutable, to reduce gas consumption. To upgrade EntryPoint,\\n * a new implementation of SimpleAccount must be deployed with the new EntryPoint address, then upgrading\\n * the implementation by calling `upgradeTo()`\\n */\\n function initialize(address anOwner) public virtual initializer {\\n _initialize(anOwner);\\n }\\n\\n function _initialize(address anOwner) internal virtual {\\n owner = anOwner;\\n emit SimpleAccountInitialized(_entryPoint, owner);\\n }\\n\\n // Require the function call went through EntryPoint or owner\\n function _requireFromEntryPointOrOwner() internal view {\\n require(msg.sender == address(entryPoint()) || msg.sender == owner, \\\"account: not Owner or EntryPoint\\\");\\n }\\n\\n /// implement template method of BaseAccount\\n function _validateSignature(UserOperation calldata userOp, bytes32 userOpHash)\\n internal override virtual returns (uint256 validationData) {\\n bytes32 hash = userOpHash.toEthSignedMessageHash();\\n if (owner != hash.recover(userOp.signature))\\n return SIG_VALIDATION_FAILED;\\n return 0;\\n }\\n\\n function _call(address target, uint256 value, bytes memory data) internal {\\n (bool success, bytes memory result) = target.call{value : value}(data);\\n if (!success) {\\n assembly {\\n revert(add(result, 32), mload(result))\\n }\\n }\\n }\\n\\n /**\\n * check current account deposit in the entryPoint\\n */\\n function getDeposit() public view returns (uint256) {\\n return entryPoint().balanceOf(address(this));\\n }\\n\\n /**\\n * deposit more funds for this account in the entryPoint\\n */\\n function addDeposit() public payable {\\n entryPoint().depositTo{value : msg.value}(address(this));\\n }\\n\\n /**\\n * withdraw value from the account's deposit\\n * @param withdrawAddress target to send to\\n * @param amount to withdraw\\n */\\n function withdrawDepositTo(address payable withdrawAddress, uint256 amount) public onlyOwner {\\n entryPoint().withdrawTo(withdrawAddress, amount);\\n }\\n\\n function _authorizeUpgrade(address newImplementation) internal view override {\\n (newImplementation);\\n _onlyOwner();\\n }\\n}\\n\\n\",\"keccak256\":\"0x295bb73ecafb78a11e7418cc91d5f3c7f5fd5b2eba5e063d1e7d6bb6163192d4\",\"license\":\"GPL-3.0\"},\"contracts/samples/SimpleAccountFactory.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.12;\\n\\nimport \\\"@openzeppelin/contracts/utils/Create2.sol\\\";\\nimport \\\"@openzeppelin/contracts/proxy/ERC1967/ERC1967Proxy.sol\\\";\\n\\nimport \\\"./SimpleAccount.sol\\\";\\n\\n/**\\n * A sample factory contract for SimpleAccount\\n * A UserOperations \\\"initCode\\\" holds the address of the factory, and a method call (to createAccount, in this sample factory).\\n * The factory's createAccount returns the target account address even if it is already installed.\\n * This way, the entryPoint.getSenderAddress() can be called either before or after the account is created.\\n */\\ncontract SimpleAccountFactory {\\n SimpleAccount public immutable accountImplementation;\\n\\n constructor(IEntryPoint _entryPoint) {\\n accountImplementation = new SimpleAccount(_entryPoint);\\n }\\n\\n /**\\n * create an account, and return its address.\\n * returns the address even if the account is already deployed.\\n * Note that during UserOperation execution, this method is called only if the account is not deployed.\\n * This method returns an existing account address so that entryPoint.getSenderAddress() would work even after account creation\\n */\\n function createAccount(address owner,uint256 salt) public returns (SimpleAccount ret) {\\n address addr = getAddress(owner, salt);\\n uint codeSize = addr.code.length;\\n if (codeSize > 0) {\\n return SimpleAccount(payable(addr));\\n }\\n ret = SimpleAccount(payable(new ERC1967Proxy{salt : bytes32(salt)}(\\n address(accountImplementation),\\n abi.encodeCall(SimpleAccount.initialize, (owner))\\n )));\\n }\\n\\n /**\\n * calculate the counterfactual address of this account as it would be returned by createAccount()\\n */\\n function getAddress(address owner,uint256 salt) public view returns (address) {\\n return Create2.computeAddress(bytes32(salt), keccak256(abi.encodePacked(\\n type(ERC1967Proxy).creationCode,\\n abi.encode(\\n address(accountImplementation),\\n abi.encodeCall(SimpleAccount.initialize, (owner))\\n )\\n )));\\n }\\n}\\n\",\"keccak256\":\"0xf2cb4f3889e79edb11aab8d8451e379691813fc6b945ca0b5c3a08017c27b5ed\",\"license\":\"GPL-3.0\"},\"contracts/samples/callback/TokenCallbackHandler.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0\\npragma solidity ^0.8.12;\\n\\n/* solhint-disable no-empty-blocks */\\n\\nimport \\\"@openzeppelin/contracts/utils/introspection/IERC165.sol\\\";\\nimport \\\"@openzeppelin/contracts/token/ERC777/IERC777Recipient.sol\\\";\\nimport \\\"@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol\\\";\\nimport \\\"@openzeppelin/contracts/token/ERC1155/IERC1155Receiver.sol\\\";\\n\\n/**\\n * Token callback handler.\\n * Handles supported tokens' callbacks, allowing account receiving these tokens.\\n */\\ncontract TokenCallbackHandler is IERC777Recipient, IERC721Receiver, IERC1155Receiver {\\n function tokensReceived(\\n address,\\n address,\\n address,\\n uint256,\\n bytes calldata,\\n bytes calldata\\n ) external pure override {\\n }\\n\\n function onERC721Received(\\n address,\\n address,\\n uint256,\\n bytes calldata\\n ) external pure override returns (bytes4) {\\n return IERC721Receiver.onERC721Received.selector;\\n }\\n\\n function onERC1155Received(\\n address,\\n address,\\n uint256,\\n uint256,\\n bytes calldata\\n ) external pure override returns (bytes4) {\\n return IERC1155Receiver.onERC1155Received.selector;\\n }\\n\\n function onERC1155BatchReceived(\\n address,\\n address,\\n uint256[] calldata,\\n uint256[] calldata,\\n bytes calldata\\n ) external pure override returns (bytes4) {\\n return IERC1155Receiver.onERC1155BatchReceived.selector;\\n }\\n\\n function supportsInterface(bytes4 interfaceId) external view virtual override returns (bool) {\\n return\\n interfaceId == type(IERC721Receiver).interfaceId ||\\n interfaceId == type(IERC1155Receiver).interfaceId ||\\n interfaceId == type(IERC165).interfaceId;\\n }\\n}\\n\",\"keccak256\":\"0xfff3df5f5211d71158bb017ff791dc4fa85db53890f7bd72bac3a43d89e83752\",\"license\":\"GPL-3.0\"}},\"version\":1}", - "bytecode": "0x60a060405234801561001057600080fd5b5060405161336238038061336283398101604081905261002f91610088565b8060405161003c9061007b565b6001600160a01b039091168152602001604051809103906000f080158015610068573d6000803e3d6000fd5b506001600160a01b0316608052506100b8565b6125dc80610d8683390190565b60006020828403121561009a57600080fd5b81516001600160a01b03811681146100b157600080fd5b9392505050565b608051610ca66100e060003960008181604b0152818161011401526102580152610ca66000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c806311464fbe146100465780635fbfb9cf146100965780638cb84e18146100a9575b600080fd5b61006d7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b61006d6100a436600461039d565b6100bc565b61006d6100b736600461039d565b6101ee565b6000806100c984846101ee565b905073ffffffffffffffffffffffffffffffffffffffff81163b80156100f1575090506101e8565b60405173ffffffffffffffffffffffffffffffffffffffff8616602482015284907f000000000000000000000000000000000000000000000000000000000000000090604401604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fc4d66de800000000000000000000000000000000000000000000000000000000179052516101b790610390565b6101c2929190610412565b8190604051809103906000f59050801580156101e2573d6000803e3d6000fd5b50925050505b92915050565b60006103578260001b6040518060200161020790610390565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082820381018352601f90910116604081905273ffffffffffffffffffffffffffffffffffffffff871660248201527f000000000000000000000000000000000000000000000000000000000000000090604401604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fc4d66de800000000000000000000000000000000000000000000000000000000179052905161030093929101610412565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529082905261033c9291602001610480565b6040516020818303038152906040528051906020012061035e565b9392505050565b60006103578383306000604051836040820152846020820152828152600b8101905060ff815360559020949350505050565b6107c1806104b083390190565b600080604083850312156103b057600080fd5b823573ffffffffffffffffffffffffffffffffffffffff811681146103d457600080fd5b946020939093013593505050565b60005b838110156103fd5781810151838201526020016103e5565b8381111561040c576000848401525b50505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000825180604084015261044d8160608501602087016103e2565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016060019392505050565b600083516104928184602088016103e2565b8351908301906104a68183602088016103e2565b0194935050505056fe60806040526040516107c13803806107c183398101604081905261002291610321565b61002e82826000610035565b505061043e565b61003e8361006b565b60008251118061004b5750805b156100665761006483836100ab60201b6100291760201c565b505b505050565b610074816100d7565b6040516001600160a01b038216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b60606100d0838360405180606001604052806027815260200161079a602791396101a9565b9392505050565b6100ea8161022260201b6100551760201c565b6101515760405162461bcd60e51b815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201526c1bdd08184818dbdb9d1c9858dd609a1b60648201526084015b60405180910390fd5b806101887f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc60001b61023160201b6100711760201c565b80546001600160a01b0319166001600160a01b039290921691909117905550565b6060600080856001600160a01b0316856040516101c691906103ef565b600060405180830381855af49150503d8060008114610201576040519150601f19603f3d011682016040523d82523d6000602084013e610206565b606091505b50909250905061021886838387610234565b9695505050505050565b6001600160a01b03163b151590565b90565b606083156102a357825160000361029c576001600160a01b0385163b61029c5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610148565b50816102ad565b6102ad83836102b5565b949350505050565b8151156102c55781518083602001fd5b8060405162461bcd60e51b8152600401610148919061040b565b634e487b7160e01b600052604160045260246000fd5b60005b838110156103105781810151838201526020016102f8565b838111156100645750506000910152565b6000806040838503121561033457600080fd5b82516001600160a01b038116811461034b57600080fd5b60208401519092506001600160401b038082111561036857600080fd5b818501915085601f83011261037c57600080fd5b81518181111561038e5761038e6102df565b604051601f8201601f19908116603f011681019083821181831017156103b6576103b66102df565b816040528281528860208487010111156103cf57600080fd5b6103e08360208301602088016102f5565b80955050505050509250929050565b600082516104018184602087016102f5565b9190910192915050565b602081526000825180602084015261042a8160408501602087016102f5565b601f01601f19169190910160400192915050565b61034d8061044d6000396000f3fe60806040523661001357610011610017565b005b6100115b610027610022610074565b6100b9565b565b606061004e83836040518060600160405280602781526020016102f1602791396100dd565b9392505050565b73ffffffffffffffffffffffffffffffffffffffff163b151590565b90565b60006100b47f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5473ffffffffffffffffffffffffffffffffffffffff1690565b905090565b3660008037600080366000845af43d6000803e8080156100d8573d6000f35b3d6000fd5b60606000808573ffffffffffffffffffffffffffffffffffffffff16856040516101079190610283565b600060405180830381855af49150503d8060008114610142576040519150601f19603f3d011682016040523d82523d6000602084013e610147565b606091505b509150915061015886838387610162565b9695505050505050565b606083156101fd5782516000036101f65773ffffffffffffffffffffffffffffffffffffffff85163b6101f6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064015b60405180910390fd5b5081610207565b610207838361020f565b949350505050565b81511561021f5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101ed919061029f565b60005b8381101561026e578181015183820152602001610256565b8381111561027d576000848401525b50505050565b60008251610295818460208701610253565b9190910192915050565b60208152600082518060208401526102be816040850160208701610253565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fe416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a26469706673582212201cd78ab6a31213989661cff2d7d05fc9b9c38b1a848e8249e2e398659a9eb7e364736f6c634300080f0033416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a264697066735822122070aa03035a81441673770173c347020a4af1bf8f651ceebc066752c059bdbac764736f6c634300080f003360c0604052306080523480156200001557600080fd5b50604051620025dc380380620025dc833981016040819052620000389162000118565b6001600160a01b03811660a0526200004f62000056565b506200014a565b600054610100900460ff1615620000c35760405162461bcd60e51b815260206004820152602760248201527f496e697469616c697a61626c653a20636f6e747261637420697320696e697469604482015266616c697a696e6760c81b606482015260840160405180910390fd5b60005460ff908116101562000116576000805460ff191660ff9081179091556040519081527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b565b6000602082840312156200012b57600080fd5b81516001600160a01b03811681146200014357600080fd5b9392505050565b60805160a05161241f620001bd6000396000818161032f015281816108810152818161092801528181610d4c01528181610f9d01528181610fe40152818161133601526115f501526000818161066b0152818161071b015281816109ec01528181610a9c0152610be5015261241f6000f3fe60806040526004361061012c5760003560e01c806352d1902d116100a5578063bc197c8111610074578063c4d66de811610059578063c4d66de8146103d0578063d087d288146103f0578063f23a6e611461040557600080fd5b8063bc197c8114610373578063c399ec88146103bb57600080fd5b806352d1902d146102b35780638da5cb5b146102c8578063b0d691fe14610320578063b61d27f61461035357600080fd5b80633659cfe6116100fc5780634a58db19116100e15780634a58db19146102785780634d44560d146102805780634f1ef286146102a057600080fd5b80633659cfe61461022a5780633a871cdd1461024a57600080fd5b806223de291461013857806301ffc9a71461015f578063150b7a021461019457806318dfb3c71461020a57600080fd5b3661013357005b600080fd5b34801561014457600080fd5b5061015d610153366004611cbf565b5050505050505050565b005b34801561016b57600080fd5b5061017f61017a366004611d70565b61044b565b60405190151581526020015b60405180910390f35b3480156101a057600080fd5b506101d96101af366004611db2565b7f150b7a020000000000000000000000000000000000000000000000000000000095945050505050565b6040517fffffffff00000000000000000000000000000000000000000000000000000000909116815260200161018b565b34801561021657600080fd5b5061015d610225366004611e6a565b610530565b34801561023657600080fd5b5061015d610245366004611ed6565b610654565b34801561025657600080fd5b5061026a610265366004611ef3565b610859565b60405190815260200161018b565b61015d61087f565b34801561028c57600080fd5b5061015d61029b366004611f47565b61091e565b61015d6102ae366004611fa2565b6109d5565b3480156102bf57600080fd5b5061026a610bcb565b3480156102d457600080fd5b506000546102fb9062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161018b565b34801561032c57600080fd5b507f00000000000000000000000000000000000000000000000000000000000000006102fb565b34801561035f57600080fd5b5061015d61036e366004612084565b610cb7565b34801561037f57600080fd5b506101d961038e3660046120d4565b7fbc197c810000000000000000000000000000000000000000000000000000000098975050505050505050565b3480156103c757600080fd5b5061026a610d06565b3480156103dc57600080fd5b5061015d6103eb366004611ed6565b610dbd565b3480156103fc57600080fd5b5061026a610f50565b34801561041157600080fd5b506101d9610420366004612172565b7ff23a6e61000000000000000000000000000000000000000000000000000000009695505050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f150b7a020000000000000000000000000000000000000000000000000000000014806104de57507fffffffff0000000000000000000000000000000000000000000000000000000082167f4e2312e000000000000000000000000000000000000000000000000000000000145b8061052a57507fffffffff0000000000000000000000000000000000000000000000000000000082167f01ffc9a700000000000000000000000000000000000000000000000000000000145b92915050565b610538610fcc565b8281146105a6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f77726f6e67206172726179206c656e677468730000000000000000000000000060448201526064015b60405180910390fd5b60005b8381101561064d5761063b8585838181106105c6576105c66121ee565b90506020020160208101906105db9190611ed6565b60008585858181106105ef576105ef6121ee565b9050602002810190610601919061221d565b8080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061109592505050565b8061064581612282565b9150506105a9565b5050505050565b73ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000163003610719576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f46756e6374696f6e206d7573742062652063616c6c6564207468726f7567682060448201527f64656c656761746563616c6c0000000000000000000000000000000000000000606482015260840161059d565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1661078e7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff1614610831576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f46756e6374696f6e206d7573742062652063616c6c6564207468726f7567682060448201527f6163746976652070726f78790000000000000000000000000000000000000000606482015260840161059d565b61083a81611112565b604080516000808252602082019092526108569183919061111a565b50565b600061086361131e565b61086d84846113bd565b9050610878826114a3565b9392505050565b7f00000000000000000000000000000000000000000000000000000000000000006040517fb760faf900000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff919091169063b760faf99034906024016000604051808303818588803b15801561090a57600080fd5b505af115801561064d573d6000803e3d6000fd5b61092661150e565b7f00000000000000000000000000000000000000000000000000000000000000006040517f205c287800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff848116600483015260248201849052919091169063205c287890604401600060405180830381600087803b1580156109b957600080fd5b505af11580156109cd573d6000803e3d6000fd5b505050505050565b73ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000163003610a9a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f46756e6374696f6e206d7573742062652063616c6c6564207468726f7567682060448201527f64656c656761746563616c6c0000000000000000000000000000000000000000606482015260840161059d565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16610b0f7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff1614610bb2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f46756e6374696f6e206d7573742062652063616c6c6564207468726f7567682060448201527f6163746976652070726f78790000000000000000000000000000000000000000606482015260840161059d565b610bbb82611112565b610bc78282600161111a565b5050565b60003073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610c92576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603860248201527f555550535570677261646561626c653a206d757374206e6f742062652063616c60448201527f6c6564207468726f7567682064656c656761746563616c6c0000000000000000606482015260840161059d565b507f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc90565b610cbf610fcc565b610d00848484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061109592505050565b50505050565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009073ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016906370a08231906024015b602060405180830381865afa158015610d94573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610db891906122e1565b905090565b600054610100900460ff1615808015610ddd5750600054600160ff909116105b80610df75750303b158015610df7575060005460ff166001145b610e83576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a6564000000000000000000000000000000000000606482015260840161059d565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790558015610ee157600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b610eea8261159f565b8015610bc757600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6040517f35567e1a0000000000000000000000000000000000000000000000000000000081523060048201526000602482018190529073ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016906335567e1a90604401610d77565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016148061102d575060005462010000900473ffffffffffffffffffffffffffffffffffffffff1633145b611093576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f6163636f756e743a206e6f74204f776e6572206f7220456e747279506f696e74604482015260640161059d565b565b6000808473ffffffffffffffffffffffffffffffffffffffff1684846040516110be9190612326565b60006040518083038185875af1925050503d80600081146110fb576040519150601f19603f3d011682016040523d82523d6000602084013e611100565b606091505b50915091508161064d57805160208201fd5b61085661150e565b7f4910fdfa16fed3260ed0e7147f7cc6da11a60208b5b9406d12a635614ffd91435460ff16156111525761114d8361163e565b505050565b8273ffffffffffffffffffffffffffffffffffffffff166352d1902d6040518163ffffffff1660e01b8152600401602060405180830381865afa9250505080156111d7575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092526111d4918101906122e1565b60015b611263576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f45524331393637557067726164653a206e657720696d706c656d656e7461746960448201527f6f6e206973206e6f742055555053000000000000000000000000000000000000606482015260840161059d565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc8114611312576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602960248201527f45524331393637557067726164653a20756e737570706f727465642070726f7860448201527f6961626c65555549440000000000000000000000000000000000000000000000606482015260840161059d565b5061114d838383611748565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611093576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f6163636f756e743a206e6f742066726f6d20456e747279506f696e7400000000604482015260640161059d565b600080611417836040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b905061146761142a61014086018661221d565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250859392505061176d9050565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff90811691161461149957600191505061052a565b5060009392505050565b80156108565760405160009033907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90849084818181858888f193505050503d806000811461064d576040519150601f19603f3d011682016040523d82523d6000602084013e61064d565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff1633148061153957503330145b611093576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6f6e6c79206f776e657200000000000000000000000000000000000000000000604482015260640161059d565b600080547fffffffffffffffffffff0000000000000000000000000000000000000000ffff166201000073ffffffffffffffffffffffffffffffffffffffff8481168202929092178084556040519190048216927f0000000000000000000000000000000000000000000000000000000000000000909216917f47e55c76e7a6f1fd8996a1da8008c1ea29699cca35e7bcd057f2dec313b6e5de91a350565b73ffffffffffffffffffffffffffffffffffffffff81163b6116e2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201527f6f74206120636f6e747261637400000000000000000000000000000000000000606482015260840161059d565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b61175183611791565b60008251118061175e5750805b1561114d57610d0083836117de565b600080600061177c8585611803565b9150915061178981611848565b509392505050565b61179a8161163e565b60405173ffffffffffffffffffffffffffffffffffffffff8216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b606061087883836040518060600160405280602781526020016123c3602791396119fb565b60008082516041036118395760208301516040840151606085015160001a61182d87828585611a80565b94509450505050611841565b506000905060025b9250929050565b600081600481111561185c5761185c612342565b036118645750565b600181600481111561187857611878612342565b036118df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f45434453413a20696e76616c6964207369676e61747572650000000000000000604482015260640161059d565b60028160048111156118f3576118f3612342565b0361195a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e67746800604482015260640161059d565b600381600481111561196e5761196e612342565b03610856576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c60448201527f7565000000000000000000000000000000000000000000000000000000000000606482015260840161059d565b60606000808573ffffffffffffffffffffffffffffffffffffffff1685604051611a259190612326565b600060405180830381855af49150503d8060008114611a60576040519150601f19603f3d011682016040523d82523d6000602084013e611a65565b606091505b5091509150611a7686838387611b6f565b9695505050505050565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0831115611ab75750600090506003611b66565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015611b0b573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff8116611b5f57600060019250925050611b66565b9150600090505b94509492505050565b60608315611c05578251600003611bfe5773ffffffffffffffffffffffffffffffffffffffff85163b611bfe576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161059d565b5081611c0f565b611c0f8383611c17565b949350505050565b815115611c275781518083602001fd5b806040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161059d9190612371565b73ffffffffffffffffffffffffffffffffffffffff8116811461085657600080fd5b60008083601f840112611c8f57600080fd5b50813567ffffffffffffffff811115611ca757600080fd5b60208301915083602082850101111561184157600080fd5b60008060008060008060008060c0898b031215611cdb57600080fd5b8835611ce681611c5b565b97506020890135611cf681611c5b565b96506040890135611d0681611c5b565b955060608901359450608089013567ffffffffffffffff80821115611d2a57600080fd5b611d368c838d01611c7d565b909650945060a08b0135915080821115611d4f57600080fd5b50611d5c8b828c01611c7d565b999c989b5096995094979396929594505050565b600060208284031215611d8257600080fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461087857600080fd5b600080600080600060808688031215611dca57600080fd5b8535611dd581611c5b565b94506020860135611de581611c5b565b935060408601359250606086013567ffffffffffffffff811115611e0857600080fd5b611e1488828901611c7d565b969995985093965092949392505050565b60008083601f840112611e3757600080fd5b50813567ffffffffffffffff811115611e4f57600080fd5b6020830191508360208260051b850101111561184157600080fd5b60008060008060408587031215611e8057600080fd5b843567ffffffffffffffff80821115611e9857600080fd5b611ea488838901611e25565b90965094506020870135915080821115611ebd57600080fd5b50611eca87828801611e25565b95989497509550505050565b600060208284031215611ee857600080fd5b813561087881611c5b565b600080600060608486031215611f0857600080fd5b833567ffffffffffffffff811115611f1f57600080fd5b84016101608187031215611f3257600080fd5b95602085013595506040909401359392505050565b60008060408385031215611f5a57600080fd5b8235611f6581611c5b565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60008060408385031215611fb557600080fd5b8235611fc081611c5b565b9150602083013567ffffffffffffffff80821115611fdd57600080fd5b818501915085601f830112611ff157600080fd5b81358181111561200357612003611f73565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f0116810190838211818310171561204957612049611f73565b8160405282815288602084870101111561206257600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b6000806000806060858703121561209a57600080fd5b84356120a581611c5b565b935060208501359250604085013567ffffffffffffffff8111156120c857600080fd5b611eca87828801611c7d565b60008060008060008060008060a0898b0312156120f057600080fd5b88356120fb81611c5b565b9750602089013561210b81611c5b565b9650604089013567ffffffffffffffff8082111561212857600080fd5b6121348c838d01611e25565b909850965060608b013591508082111561214d57600080fd5b6121598c838d01611e25565b909650945060808b0135915080821115611d4f57600080fd5b60008060008060008060a0878903121561218b57600080fd5b863561219681611c5b565b955060208701356121a681611c5b565b94506040870135935060608701359250608087013567ffffffffffffffff8111156121d057600080fd5b6121dc89828a01611c7d565b979a9699509497509295939492505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261225257600080fd5b83018035915067ffffffffffffffff82111561226d57600080fd5b60200191503681900382131561184157600080fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036122da577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b5060010190565b6000602082840312156122f357600080fd5b5051919050565b60005b838110156123155781810151838201526020016122fd565b83811115610d005750506000910152565b600082516123388184602087016122fa565b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60208152600082518060208401526123908160408501602087016122fa565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fe416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a2646970667358221220e7edcd8c7b9333c2bbdd5f8fa69f1cd2cb0f5cbfa76648b9830bcf0cbfef288e64736f6c634300080f0033", - "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100415760003560e01c806311464fbe146100465780635fbfb9cf146100965780638cb84e18146100a9575b600080fd5b61006d7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b61006d6100a436600461039d565b6100bc565b61006d6100b736600461039d565b6101ee565b6000806100c984846101ee565b905073ffffffffffffffffffffffffffffffffffffffff81163b80156100f1575090506101e8565b60405173ffffffffffffffffffffffffffffffffffffffff8616602482015284907f000000000000000000000000000000000000000000000000000000000000000090604401604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fc4d66de800000000000000000000000000000000000000000000000000000000179052516101b790610390565b6101c2929190610412565b8190604051809103906000f59050801580156101e2573d6000803e3d6000fd5b50925050505b92915050565b60006103578260001b6040518060200161020790610390565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082820381018352601f90910116604081905273ffffffffffffffffffffffffffffffffffffffff871660248201527f000000000000000000000000000000000000000000000000000000000000000090604401604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fc4d66de800000000000000000000000000000000000000000000000000000000179052905161030093929101610412565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529082905261033c9291602001610480565b6040516020818303038152906040528051906020012061035e565b9392505050565b60006103578383306000604051836040820152846020820152828152600b8101905060ff815360559020949350505050565b6107c1806104b083390190565b600080604083850312156103b057600080fd5b823573ffffffffffffffffffffffffffffffffffffffff811681146103d457600080fd5b946020939093013593505050565b60005b838110156103fd5781810151838201526020016103e5565b8381111561040c576000848401525b50505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000825180604084015261044d8160608501602087016103e2565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016060019392505050565b600083516104928184602088016103e2565b8351908301906104a68183602088016103e2565b0194935050505056fe60806040526040516107c13803806107c183398101604081905261002291610321565b61002e82826000610035565b505061043e565b61003e8361006b565b60008251118061004b5750805b156100665761006483836100ab60201b6100291760201c565b505b505050565b610074816100d7565b6040516001600160a01b038216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b60606100d0838360405180606001604052806027815260200161079a602791396101a9565b9392505050565b6100ea8161022260201b6100551760201c565b6101515760405162461bcd60e51b815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201526c1bdd08184818dbdb9d1c9858dd609a1b60648201526084015b60405180910390fd5b806101887f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc60001b61023160201b6100711760201c565b80546001600160a01b0319166001600160a01b039290921691909117905550565b6060600080856001600160a01b0316856040516101c691906103ef565b600060405180830381855af49150503d8060008114610201576040519150601f19603f3d011682016040523d82523d6000602084013e610206565b606091505b50909250905061021886838387610234565b9695505050505050565b6001600160a01b03163b151590565b90565b606083156102a357825160000361029c576001600160a01b0385163b61029c5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610148565b50816102ad565b6102ad83836102b5565b949350505050565b8151156102c55781518083602001fd5b8060405162461bcd60e51b8152600401610148919061040b565b634e487b7160e01b600052604160045260246000fd5b60005b838110156103105781810151838201526020016102f8565b838111156100645750506000910152565b6000806040838503121561033457600080fd5b82516001600160a01b038116811461034b57600080fd5b60208401519092506001600160401b038082111561036857600080fd5b818501915085601f83011261037c57600080fd5b81518181111561038e5761038e6102df565b604051601f8201601f19908116603f011681019083821181831017156103b6576103b66102df565b816040528281528860208487010111156103cf57600080fd5b6103e08360208301602088016102f5565b80955050505050509250929050565b600082516104018184602087016102f5565b9190910192915050565b602081526000825180602084015261042a8160408501602087016102f5565b601f01601f19169190910160400192915050565b61034d8061044d6000396000f3fe60806040523661001357610011610017565b005b6100115b610027610022610074565b6100b9565b565b606061004e83836040518060600160405280602781526020016102f1602791396100dd565b9392505050565b73ffffffffffffffffffffffffffffffffffffffff163b151590565b90565b60006100b47f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5473ffffffffffffffffffffffffffffffffffffffff1690565b905090565b3660008037600080366000845af43d6000803e8080156100d8573d6000f35b3d6000fd5b60606000808573ffffffffffffffffffffffffffffffffffffffff16856040516101079190610283565b600060405180830381855af49150503d8060008114610142576040519150601f19603f3d011682016040523d82523d6000602084013e610147565b606091505b509150915061015886838387610162565b9695505050505050565b606083156101fd5782516000036101f65773ffffffffffffffffffffffffffffffffffffffff85163b6101f6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064015b60405180910390fd5b5081610207565b610207838361020f565b949350505050565b81511561021f5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101ed919061029f565b60005b8381101561026e578181015183820152602001610256565b8381111561027d576000848401525b50505050565b60008251610295818460208701610253565b9190910192915050565b60208152600082518060208401526102be816040850160208701610253565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fe416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a26469706673582212201cd78ab6a31213989661cff2d7d05fc9b9c38b1a848e8249e2e398659a9eb7e364736f6c634300080f0033416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a264697066735822122070aa03035a81441673770173c347020a4af1bf8f651ceebc066752c059bdbac764736f6c634300080f0033", - "devdoc": { - "kind": "dev", - "methods": {}, - "version": 1 - }, - "userdoc": { - "kind": "user", - "methods": { - "createAccount(address,uint256)": { - "notice": "create an account, and return its address. returns the address even if the account is already deployed. Note that during UserOperation execution, this method is called only if the account is not deployed. This method returns an existing account address so that entryPoint.getSenderAddress() would work even after account creation" - }, - "getAddress(address,uint256)": { - "notice": "calculate the counterfactual address of this account as it would be returned by createAccount()" - } - }, - "notice": "A sample factory contract for SimpleAccount A UserOperations \"initCode\" holds the address of the factory, and a method call (to createAccount, in this sample factory). The factory's createAccount returns the target account address even if it is already installed. This way, the entryPoint.getSenderAddress() can be called either before or after the account is created.", - "version": 1 - }, - "storageLayout": { - "storage": [], - "types": null - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/solcInputs/02113a2ed1850c3774563305ee607f11.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/solcInputs/02113a2ed1850c3774563305ee607f11.json deleted file mode 100644 index 0df6e95752..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/solcInputs/02113a2ed1850c3774563305ee607f11.json +++ /dev/null @@ -1,329 +0,0 @@ -{ - "language": "Solidity", - "sources": { - "@gnosis.pm/safe-contracts/contracts/base/Executor.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\nimport \"../common/Enum.sol\";\n\n/// @title Executor - A contract that can execute transactions\n/// @author Richard Meissner - \ncontract Executor {\n function execute(\n address to,\n uint256 value,\n bytes memory data,\n Enum.Operation operation,\n uint256 txGas\n ) internal returns (bool success) {\n if (operation == Enum.Operation.DelegateCall) {\n // solhint-disable-next-line no-inline-assembly\n assembly {\n success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n } else {\n // solhint-disable-next-line no-inline-assembly\n assembly {\n success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0)\n }\n }\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/base/FallbackManager.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\nimport \"../common/SelfAuthorized.sol\";\n\n/// @title Fallback Manager - A contract that manages fallback calls made to this contract\n/// @author Richard Meissner - \ncontract FallbackManager is SelfAuthorized {\n event ChangedFallbackHandler(address handler);\n\n // keccak256(\"fallback_manager.handler.address\")\n bytes32 internal constant FALLBACK_HANDLER_STORAGE_SLOT = 0x6c9a6c4a39284e37ed1cf53d337577d14212a4870fb976a4366c693b939918d5;\n\n function internalSetFallbackHandler(address handler) internal {\n bytes32 slot = FALLBACK_HANDLER_STORAGE_SLOT;\n // solhint-disable-next-line no-inline-assembly\n assembly {\n sstore(slot, handler)\n }\n }\n\n /// @dev Allows to add a contract to handle fallback calls.\n /// Only fallback calls without value and with data will be forwarded.\n /// This can only be done via a Safe transaction.\n /// @param handler contract to handle fallbacks calls.\n function setFallbackHandler(address handler) public authorized {\n internalSetFallbackHandler(handler);\n emit ChangedFallbackHandler(handler);\n }\n\n // solhint-disable-next-line payable-fallback,no-complex-fallback\n fallback() external {\n bytes32 slot = FALLBACK_HANDLER_STORAGE_SLOT;\n // solhint-disable-next-line no-inline-assembly\n assembly {\n let handler := sload(slot)\n if iszero(handler) {\n return(0, 0)\n }\n calldatacopy(0, 0, calldatasize())\n // The msg.sender address is shifted to the left by 12 bytes to remove the padding\n // Then the address without padding is stored right after the calldata\n mstore(calldatasize(), shl(96, caller()))\n // Add 20 bytes for the address appended add the end\n let success := call(gas(), handler, 0, 0, add(calldatasize(), 20), 0, 0)\n returndatacopy(0, 0, returndatasize())\n if iszero(success) {\n revert(0, returndatasize())\n }\n return(0, returndatasize())\n }\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/base/GuardManager.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\nimport \"../common/Enum.sol\";\nimport \"../common/SelfAuthorized.sol\";\n\ninterface Guard {\n function checkTransaction(\n address to,\n uint256 value,\n bytes memory data,\n Enum.Operation operation,\n uint256 safeTxGas,\n uint256 baseGas,\n uint256 gasPrice,\n address gasToken,\n address payable refundReceiver,\n bytes memory signatures,\n address msgSender\n ) external;\n\n function checkAfterExecution(bytes32 txHash, bool success) external;\n}\n\n/// @title Fallback Manager - A contract that manages fallback calls made to this contract\n/// @author Richard Meissner - \ncontract GuardManager is SelfAuthorized {\n event ChangedGuard(address guard);\n // keccak256(\"guard_manager.guard.address\")\n bytes32 internal constant GUARD_STORAGE_SLOT = 0x4a204f620c8c5ccdca3fd54d003badd85ba500436a431f0cbda4f558c93c34c8;\n\n /// @dev Set a guard that checks transactions before execution\n /// @param guard The address of the guard to be used or the 0 address to disable the guard\n function setGuard(address guard) external authorized {\n bytes32 slot = GUARD_STORAGE_SLOT;\n // solhint-disable-next-line no-inline-assembly\n assembly {\n sstore(slot, guard)\n }\n emit ChangedGuard(guard);\n }\n\n function getGuard() internal view returns (address guard) {\n bytes32 slot = GUARD_STORAGE_SLOT;\n // solhint-disable-next-line no-inline-assembly\n assembly {\n guard := sload(slot)\n }\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/base/ModuleManager.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\nimport \"../common/Enum.sol\";\nimport \"../common/SelfAuthorized.sol\";\nimport \"./Executor.sol\";\n\n/// @title Module Manager - A contract that manages modules that can execute transactions via this contract\n/// @author Stefan George - \n/// @author Richard Meissner - \ncontract ModuleManager is SelfAuthorized, Executor {\n event EnabledModule(address module);\n event DisabledModule(address module);\n event ExecutionFromModuleSuccess(address indexed module);\n event ExecutionFromModuleFailure(address indexed module);\n\n address internal constant SENTINEL_MODULES = address(0x1);\n\n mapping(address => address) internal modules;\n\n function setupModules(address to, bytes memory data) internal {\n require(modules[SENTINEL_MODULES] == address(0), \"GS100\");\n modules[SENTINEL_MODULES] = SENTINEL_MODULES;\n if (to != address(0))\n // Setup has to complete successfully or transaction fails.\n require(execute(to, 0, data, Enum.Operation.DelegateCall, gasleft()), \"GS000\");\n }\n\n /// @dev Allows to add a module to the whitelist.\n /// This can only be done via a Safe transaction.\n /// @notice Enables the module `module` for the Safe.\n /// @param module Module to be whitelisted.\n function enableModule(address module) public authorized {\n // Module address cannot be null or sentinel.\n require(module != address(0) && module != SENTINEL_MODULES, \"GS101\");\n // Module cannot be added twice.\n require(modules[module] == address(0), \"GS102\");\n modules[module] = modules[SENTINEL_MODULES];\n modules[SENTINEL_MODULES] = module;\n emit EnabledModule(module);\n }\n\n /// @dev Allows to remove a module from the whitelist.\n /// This can only be done via a Safe transaction.\n /// @notice Disables the module `module` for the Safe.\n /// @param prevModule Module that pointed to the module to be removed in the linked list\n /// @param module Module to be removed.\n function disableModule(address prevModule, address module) public authorized {\n // Validate module address and check that it corresponds to module index.\n require(module != address(0) && module != SENTINEL_MODULES, \"GS101\");\n require(modules[prevModule] == module, \"GS103\");\n modules[prevModule] = modules[module];\n modules[module] = address(0);\n emit DisabledModule(module);\n }\n\n /// @dev Allows a Module to execute a Safe transaction without any further confirmations.\n /// @param to Destination address of module transaction.\n /// @param value Ether value of module transaction.\n /// @param data Data payload of module transaction.\n /// @param operation Operation type of module transaction.\n function execTransactionFromModule(\n address to,\n uint256 value,\n bytes memory data,\n Enum.Operation operation\n ) public virtual returns (bool success) {\n // Only whitelisted modules are allowed.\n require(msg.sender != SENTINEL_MODULES && modules[msg.sender] != address(0), \"GS104\");\n // Execute transaction without further confirmations.\n success = execute(to, value, data, operation, gasleft());\n if (success) emit ExecutionFromModuleSuccess(msg.sender);\n else emit ExecutionFromModuleFailure(msg.sender);\n }\n\n /// @dev Allows a Module to execute a Safe transaction without any further confirmations and return data\n /// @param to Destination address of module transaction.\n /// @param value Ether value of module transaction.\n /// @param data Data payload of module transaction.\n /// @param operation Operation type of module transaction.\n function execTransactionFromModuleReturnData(\n address to,\n uint256 value,\n bytes memory data,\n Enum.Operation operation\n ) public returns (bool success, bytes memory returnData) {\n success = execTransactionFromModule(to, value, data, operation);\n // solhint-disable-next-line no-inline-assembly\n assembly {\n // Load free memory location\n let ptr := mload(0x40)\n // We allocate memory for the return data by setting the free memory location to\n // current free memory location + data size + 32 bytes for data size value\n mstore(0x40, add(ptr, add(returndatasize(), 0x20)))\n // Store the size\n mstore(ptr, returndatasize())\n // Store the data\n returndatacopy(add(ptr, 0x20), 0, returndatasize())\n // Point the return data to the correct memory location\n returnData := ptr\n }\n }\n\n /// @dev Returns if an module is enabled\n /// @return True if the module is enabled\n function isModuleEnabled(address module) public view returns (bool) {\n return SENTINEL_MODULES != module && modules[module] != address(0);\n }\n\n /// @dev Returns array of modules.\n /// @param start Start of the page.\n /// @param pageSize Maximum number of modules that should be returned.\n /// @return array Array of modules.\n /// @return next Start of the next page.\n function getModulesPaginated(address start, uint256 pageSize) external view returns (address[] memory array, address next) {\n // Init array with max page size\n array = new address[](pageSize);\n\n // Populate return array\n uint256 moduleCount = 0;\n address currentModule = modules[start];\n while (currentModule != address(0x0) && currentModule != SENTINEL_MODULES && moduleCount < pageSize) {\n array[moduleCount] = currentModule;\n currentModule = modules[currentModule];\n moduleCount++;\n }\n next = currentModule;\n // Set correct size of returned array\n // solhint-disable-next-line no-inline-assembly\n assembly {\n mstore(array, moduleCount)\n }\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/base/OwnerManager.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\nimport \"../common/SelfAuthorized.sol\";\n\n/// @title OwnerManager - Manages a set of owners and a threshold to perform actions.\n/// @author Stefan George - \n/// @author Richard Meissner - \ncontract OwnerManager is SelfAuthorized {\n event AddedOwner(address owner);\n event RemovedOwner(address owner);\n event ChangedThreshold(uint256 threshold);\n\n address internal constant SENTINEL_OWNERS = address(0x1);\n\n mapping(address => address) internal owners;\n uint256 internal ownerCount;\n uint256 internal threshold;\n\n /// @dev Setup function sets initial storage of contract.\n /// @param _owners List of Safe owners.\n /// @param _threshold Number of required confirmations for a Safe transaction.\n function setupOwners(address[] memory _owners, uint256 _threshold) internal {\n // Threshold can only be 0 at initialization.\n // Check ensures that setup function can only be called once.\n require(threshold == 0, \"GS200\");\n // Validate that threshold is smaller than number of added owners.\n require(_threshold <= _owners.length, \"GS201\");\n // There has to be at least one Safe owner.\n require(_threshold >= 1, \"GS202\");\n // Initializing Safe owners.\n address currentOwner = SENTINEL_OWNERS;\n for (uint256 i = 0; i < _owners.length; i++) {\n // Owner address cannot be null.\n address owner = _owners[i];\n require(owner != address(0) && owner != SENTINEL_OWNERS && owner != address(this) && currentOwner != owner, \"GS203\");\n // No duplicate owners allowed.\n require(owners[owner] == address(0), \"GS204\");\n owners[currentOwner] = owner;\n currentOwner = owner;\n }\n owners[currentOwner] = SENTINEL_OWNERS;\n ownerCount = _owners.length;\n threshold = _threshold;\n }\n\n /// @dev Allows to add a new owner to the Safe and update the threshold at the same time.\n /// This can only be done via a Safe transaction.\n /// @notice Adds the owner `owner` to the Safe and updates the threshold to `_threshold`.\n /// @param owner New owner address.\n /// @param _threshold New threshold.\n function addOwnerWithThreshold(address owner, uint256 _threshold) public authorized {\n // Owner address cannot be null, the sentinel or the Safe itself.\n require(owner != address(0) && owner != SENTINEL_OWNERS && owner != address(this), \"GS203\");\n // No duplicate owners allowed.\n require(owners[owner] == address(0), \"GS204\");\n owners[owner] = owners[SENTINEL_OWNERS];\n owners[SENTINEL_OWNERS] = owner;\n ownerCount++;\n emit AddedOwner(owner);\n // Change threshold if threshold was changed.\n if (threshold != _threshold) changeThreshold(_threshold);\n }\n\n /// @dev Allows to remove an owner from the Safe and update the threshold at the same time.\n /// This can only be done via a Safe transaction.\n /// @notice Removes the owner `owner` from the Safe and updates the threshold to `_threshold`.\n /// @param prevOwner Owner that pointed to the owner to be removed in the linked list\n /// @param owner Owner address to be removed.\n /// @param _threshold New threshold.\n function removeOwner(\n address prevOwner,\n address owner,\n uint256 _threshold\n ) public authorized {\n // Only allow to remove an owner, if threshold can still be reached.\n require(ownerCount - 1 >= _threshold, \"GS201\");\n // Validate owner address and check that it corresponds to owner index.\n require(owner != address(0) && owner != SENTINEL_OWNERS, \"GS203\");\n require(owners[prevOwner] == owner, \"GS205\");\n owners[prevOwner] = owners[owner];\n owners[owner] = address(0);\n ownerCount--;\n emit RemovedOwner(owner);\n // Change threshold if threshold was changed.\n if (threshold != _threshold) changeThreshold(_threshold);\n }\n\n /// @dev Allows to swap/replace an owner from the Safe with another address.\n /// This can only be done via a Safe transaction.\n /// @notice Replaces the owner `oldOwner` in the Safe with `newOwner`.\n /// @param prevOwner Owner that pointed to the owner to be replaced in the linked list\n /// @param oldOwner Owner address to be replaced.\n /// @param newOwner New owner address.\n function swapOwner(\n address prevOwner,\n address oldOwner,\n address newOwner\n ) public authorized {\n // Owner address cannot be null, the sentinel or the Safe itself.\n require(newOwner != address(0) && newOwner != SENTINEL_OWNERS && newOwner != address(this), \"GS203\");\n // No duplicate owners allowed.\n require(owners[newOwner] == address(0), \"GS204\");\n // Validate oldOwner address and check that it corresponds to owner index.\n require(oldOwner != address(0) && oldOwner != SENTINEL_OWNERS, \"GS203\");\n require(owners[prevOwner] == oldOwner, \"GS205\");\n owners[newOwner] = owners[oldOwner];\n owners[prevOwner] = newOwner;\n owners[oldOwner] = address(0);\n emit RemovedOwner(oldOwner);\n emit AddedOwner(newOwner);\n }\n\n /// @dev Allows to update the number of required confirmations by Safe owners.\n /// This can only be done via a Safe transaction.\n /// @notice Changes the threshold of the Safe to `_threshold`.\n /// @param _threshold New threshold.\n function changeThreshold(uint256 _threshold) public authorized {\n // Validate that threshold is smaller than number of owners.\n require(_threshold <= ownerCount, \"GS201\");\n // There has to be at least one Safe owner.\n require(_threshold >= 1, \"GS202\");\n threshold = _threshold;\n emit ChangedThreshold(threshold);\n }\n\n function getThreshold() public view returns (uint256) {\n return threshold;\n }\n\n function isOwner(address owner) public view returns (bool) {\n return owner != SENTINEL_OWNERS && owners[owner] != address(0);\n }\n\n /// @dev Returns array of owners.\n /// @return Array of Safe owners.\n function getOwners() public view returns (address[] memory) {\n address[] memory array = new address[](ownerCount);\n\n // populate return array\n uint256 index = 0;\n address currentOwner = owners[SENTINEL_OWNERS];\n while (currentOwner != SENTINEL_OWNERS) {\n array[index] = currentOwner;\n currentOwner = owners[currentOwner];\n index++;\n }\n return array;\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/common/Enum.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/// @title Enum - Collection of enums\n/// @author Richard Meissner - \ncontract Enum {\n enum Operation {Call, DelegateCall}\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/common/EtherPaymentFallback.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/// @title EtherPaymentFallback - A contract that has a fallback to accept ether payments\n/// @author Richard Meissner - \ncontract EtherPaymentFallback {\n event SafeReceived(address indexed sender, uint256 value);\n\n /// @dev Fallback function accepts Ether transactions.\n receive() external payable {\n emit SafeReceived(msg.sender, msg.value);\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/common/SecuredTokenTransfer.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/// @title SecuredTokenTransfer - Secure token transfer\n/// @author Richard Meissner - \ncontract SecuredTokenTransfer {\n /// @dev Transfers a token and returns if it was a success\n /// @param token Token that should be transferred\n /// @param receiver Receiver to whom the token should be transferred\n /// @param amount The amount of tokens that should be transferred\n function transferToken(\n address token,\n address receiver,\n uint256 amount\n ) internal returns (bool transferred) {\n // 0xa9059cbb - keccack(\"transfer(address,uint256)\")\n bytes memory data = abi.encodeWithSelector(0xa9059cbb, receiver, amount);\n // solhint-disable-next-line no-inline-assembly\n assembly {\n // We write the return value to scratch space.\n // See https://docs.soliditylang.org/en/v0.7.6/internals/layout_in_memory.html#layout-in-memory\n let success := call(sub(gas(), 10000), token, 0, add(data, 0x20), mload(data), 0, 0x20)\n switch returndatasize()\n case 0 {\n transferred := success\n }\n case 0x20 {\n transferred := iszero(or(iszero(success), iszero(mload(0))))\n }\n default {\n transferred := 0\n }\n }\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/common/SelfAuthorized.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/// @title SelfAuthorized - authorizes current contract to perform actions\n/// @author Richard Meissner - \ncontract SelfAuthorized {\n function requireSelfCall() private view {\n require(msg.sender == address(this), \"GS031\");\n }\n\n modifier authorized() {\n // This is a function call as it minimized the bytecode size\n requireSelfCall();\n _;\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/common/SignatureDecoder.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/// @title SignatureDecoder - Decodes signatures that a encoded as bytes\n/// @author Richard Meissner - \ncontract SignatureDecoder {\n /// @dev divides bytes signature into `uint8 v, bytes32 r, bytes32 s`.\n /// @notice Make sure to peform a bounds check for @param pos, to avoid out of bounds access on @param signatures\n /// @param pos which signature to read. A prior bounds check of this parameter should be performed, to avoid out of bounds access\n /// @param signatures concatenated rsv signatures\n function signatureSplit(bytes memory signatures, uint256 pos)\n internal\n pure\n returns (\n uint8 v,\n bytes32 r,\n bytes32 s\n )\n {\n // The signature format is a compact form of:\n // {bytes32 r}{bytes32 s}{uint8 v}\n // Compact means, uint8 is not padded to 32 bytes.\n // solhint-disable-next-line no-inline-assembly\n assembly {\n let signaturePos := mul(0x41, pos)\n r := mload(add(signatures, add(signaturePos, 0x20)))\n s := mload(add(signatures, add(signaturePos, 0x40)))\n // Here we are loading the last 32 bytes, including 31 bytes\n // of 's'. There is no 'mload8' to do this.\n //\n // 'byte' is not working due to the Solidity parser, so lets\n // use the second best option, 'and'\n v := and(mload(add(signatures, add(signaturePos, 0x41))), 0xff)\n }\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/common/Singleton.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/// @title Singleton - Base for singleton contracts (should always be first super contract)\n/// This contract is tightly coupled to our proxy contract (see `proxies/GnosisSafeProxy.sol`)\n/// @author Richard Meissner - \ncontract Singleton {\n // singleton always needs to be first declared variable, to ensure that it is at the same location as in the Proxy contract.\n // It should also always be ensured that the address is stored alone (uses a full word)\n address private singleton;\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/common/StorageAccessible.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/// @title StorageAccessible - generic base contract that allows callers to access all internal storage.\n/// @notice See https://github.com/gnosis/util-contracts/blob/bb5fe5fb5df6d8400998094fb1b32a178a47c3a1/contracts/StorageAccessible.sol\ncontract StorageAccessible {\n /**\n * @dev Reads `length` bytes of storage in the currents contract\n * @param offset - the offset in the current contract's storage in words to start reading from\n * @param length - the number of words (32 bytes) of data to read\n * @return the bytes that were read.\n */\n function getStorageAt(uint256 offset, uint256 length) public view returns (bytes memory) {\n bytes memory result = new bytes(length * 32);\n for (uint256 index = 0; index < length; index++) {\n // solhint-disable-next-line no-inline-assembly\n assembly {\n let word := sload(add(offset, index))\n mstore(add(add(result, 0x20), mul(index, 0x20)), word)\n }\n }\n return result;\n }\n\n /**\n * @dev Performs a delegetecall on a targetContract in the context of self.\n * Internally reverts execution to avoid side effects (making it static).\n *\n * This method reverts with data equal to `abi.encode(bool(success), bytes(response))`.\n * Specifically, the `returndata` after a call to this method will be:\n * `success:bool || response.length:uint256 || response:bytes`.\n *\n * @param targetContract Address of the contract containing the code to execute.\n * @param calldataPayload Calldata that should be sent to the target contract (encoded method name and arguments).\n */\n function simulateAndRevert(address targetContract, bytes memory calldataPayload) external {\n // solhint-disable-next-line no-inline-assembly\n assembly {\n let success := delegatecall(gas(), targetContract, add(calldataPayload, 0x20), mload(calldataPayload), 0, 0)\n\n mstore(0x00, success)\n mstore(0x20, returndatasize())\n returndatacopy(0x40, 0, returndatasize())\n revert(0, add(returndatasize(), 0x40))\n }\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/examples/libraries/GnosisSafeStorage.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/// @title GnosisSafeStorage - Storage layout of the Safe contracts to be used in libraries\n/// @author Richard Meissner - \ncontract GnosisSafeStorage {\n // From /common/Singleton.sol\n address internal singleton;\n // From /common/ModuleManager.sol\n mapping(address => address) internal modules;\n // From /common/OwnerManager.sol\n mapping(address => address) internal owners;\n uint256 internal ownerCount;\n uint256 internal threshold;\n\n // From /GnosisSafe.sol\n bytes32 internal nonce;\n bytes32 internal domainSeparator;\n mapping(bytes32 => uint256) internal signedMessages;\n mapping(address => mapping(bytes32 => uint256)) internal approvedHashes;\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/external/GnosisSafeMath.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/**\n * @title GnosisSafeMath\n * @dev Math operations with safety checks that revert on error\n * Renamed from SafeMath to GnosisSafeMath to avoid conflicts\n * TODO: remove once open zeppelin update to solc 0.5.0\n */\nlibrary GnosisSafeMath {\n /**\n * @dev Multiplies two numbers, reverts on overflow.\n */\n function mul(uint256 a, uint256 b) internal pure returns (uint256) {\n // Gas optimization: this is cheaper than requiring 'a' not being zero, but the\n // benefit is lost if 'b' is also tested.\n // See: https://github.com/OpenZeppelin/openzeppelin-solidity/pull/522\n if (a == 0) {\n return 0;\n }\n\n uint256 c = a * b;\n require(c / a == b);\n\n return c;\n }\n\n /**\n * @dev Subtracts two numbers, reverts on overflow (i.e. if subtrahend is greater than minuend).\n */\n function sub(uint256 a, uint256 b) internal pure returns (uint256) {\n require(b <= a);\n uint256 c = a - b;\n\n return c;\n }\n\n /**\n * @dev Adds two numbers, reverts on overflow.\n */\n function add(uint256 a, uint256 b) internal pure returns (uint256) {\n uint256 c = a + b;\n require(c >= a);\n\n return c;\n }\n\n /**\n * @dev Returns the largest of two numbers.\n */\n function max(uint256 a, uint256 b) internal pure returns (uint256) {\n return a >= b ? a : b;\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/GnosisSafe.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\nimport \"./base/ModuleManager.sol\";\nimport \"./base/OwnerManager.sol\";\nimport \"./base/FallbackManager.sol\";\nimport \"./base/GuardManager.sol\";\nimport \"./common/EtherPaymentFallback.sol\";\nimport \"./common/Singleton.sol\";\nimport \"./common/SignatureDecoder.sol\";\nimport \"./common/SecuredTokenTransfer.sol\";\nimport \"./common/StorageAccessible.sol\";\nimport \"./interfaces/ISignatureValidator.sol\";\nimport \"./external/GnosisSafeMath.sol\";\n\n/// @title Gnosis Safe - A multisignature wallet with support for confirmations using signed messages based on ERC191.\n/// @author Stefan George - \n/// @author Richard Meissner - \ncontract GnosisSafe is\n EtherPaymentFallback,\n Singleton,\n ModuleManager,\n OwnerManager,\n SignatureDecoder,\n SecuredTokenTransfer,\n ISignatureValidatorConstants,\n FallbackManager,\n StorageAccessible,\n GuardManager\n{\n using GnosisSafeMath for uint256;\n\n string public constant VERSION = \"1.3.0\";\n\n // keccak256(\n // \"EIP712Domain(uint256 chainId,address verifyingContract)\"\n // );\n bytes32 private constant DOMAIN_SEPARATOR_TYPEHASH = 0x47e79534a245952e8b16893a336b85a3d9ea9fa8c573f3d803afb92a79469218;\n\n // keccak256(\n // \"SafeTx(address to,uint256 value,bytes data,uint8 operation,uint256 safeTxGas,uint256 baseGas,uint256 gasPrice,address gasToken,address refundReceiver,uint256 nonce)\"\n // );\n bytes32 private constant SAFE_TX_TYPEHASH = 0xbb8310d486368db6bd6f849402fdd73ad53d316b5a4b2644ad6efe0f941286d8;\n\n event SafeSetup(address indexed initiator, address[] owners, uint256 threshold, address initializer, address fallbackHandler);\n event ApproveHash(bytes32 indexed approvedHash, address indexed owner);\n event SignMsg(bytes32 indexed msgHash);\n event ExecutionFailure(bytes32 txHash, uint256 payment);\n event ExecutionSuccess(bytes32 txHash, uint256 payment);\n\n uint256 public nonce;\n bytes32 private _deprecatedDomainSeparator;\n // Mapping to keep track of all message hashes that have been approve by ALL REQUIRED owners\n mapping(bytes32 => uint256) public signedMessages;\n // Mapping to keep track of all hashes (message or transaction) that have been approve by ANY owners\n mapping(address => mapping(bytes32 => uint256)) public approvedHashes;\n\n // This constructor ensures that this contract can only be used as a master copy for Proxy contracts\n constructor() {\n // By setting the threshold it is not possible to call setup anymore,\n // so we create a Safe with 0 owners and threshold 1.\n // This is an unusable Safe, perfect for the singleton\n threshold = 1;\n }\n\n /// @dev Setup function sets initial storage of contract.\n /// @param _owners List of Safe owners.\n /// @param _threshold Number of required confirmations for a Safe transaction.\n /// @param to Contract address for optional delegate call.\n /// @param data Data payload for optional delegate call.\n /// @param fallbackHandler Handler for fallback calls to this contract\n /// @param paymentToken Token that should be used for the payment (0 is ETH)\n /// @param payment Value that should be paid\n /// @param paymentReceiver Adddress that should receive the payment (or 0 if tx.origin)\n function setup(\n address[] calldata _owners,\n uint256 _threshold,\n address to,\n bytes calldata data,\n address fallbackHandler,\n address paymentToken,\n uint256 payment,\n address payable paymentReceiver\n ) external {\n // setupOwners checks if the Threshold is already set, therefore preventing that this method is called twice\n setupOwners(_owners, _threshold);\n if (fallbackHandler != address(0)) internalSetFallbackHandler(fallbackHandler);\n // As setupOwners can only be called if the contract has not been initialized we don't need a check for setupModules\n setupModules(to, data);\n\n if (payment > 0) {\n // To avoid running into issues with EIP-170 we reuse the handlePayment function (to avoid adjusting code of that has been verified we do not adjust the method itself)\n // baseGas = 0, gasPrice = 1 and gas = payment => amount = (payment + 0) * 1 = payment\n handlePayment(payment, 0, 1, paymentToken, paymentReceiver);\n }\n emit SafeSetup(msg.sender, _owners, _threshold, to, fallbackHandler);\n }\n\n /// @dev Allows to execute a Safe transaction confirmed by required number of owners and then pays the account that submitted the transaction.\n /// Note: The fees are always transferred, even if the user transaction fails.\n /// @param to Destination address of Safe transaction.\n /// @param value Ether value of Safe transaction.\n /// @param data Data payload of Safe transaction.\n /// @param operation Operation type of Safe transaction.\n /// @param safeTxGas Gas that should be used for the Safe transaction.\n /// @param baseGas Gas costs that are independent of the transaction execution(e.g. base transaction fee, signature check, payment of the refund)\n /// @param gasPrice Gas price that should be used for the payment calculation.\n /// @param gasToken Token address (or 0 if ETH) that is used for the payment.\n /// @param refundReceiver Address of receiver of gas payment (or 0 if tx.origin).\n /// @param signatures Packed signature data ({bytes32 r}{bytes32 s}{uint8 v})\n function execTransaction(\n address to,\n uint256 value,\n bytes calldata data,\n Enum.Operation operation,\n uint256 safeTxGas,\n uint256 baseGas,\n uint256 gasPrice,\n address gasToken,\n address payable refundReceiver,\n bytes memory signatures\n ) public payable virtual returns (bool success) {\n bytes32 txHash;\n // Use scope here to limit variable lifetime and prevent `stack too deep` errors\n {\n bytes memory txHashData =\n encodeTransactionData(\n // Transaction info\n to,\n value,\n data,\n operation,\n safeTxGas,\n // Payment info\n baseGas,\n gasPrice,\n gasToken,\n refundReceiver,\n // Signature info\n nonce\n );\n // Increase nonce and execute transaction.\n nonce++;\n txHash = keccak256(txHashData);\n checkSignatures(txHash, txHashData, signatures);\n }\n address guard = getGuard();\n {\n if (guard != address(0)) {\n Guard(guard).checkTransaction(\n // Transaction info\n to,\n value,\n data,\n operation,\n safeTxGas,\n // Payment info\n baseGas,\n gasPrice,\n gasToken,\n refundReceiver,\n // Signature info\n signatures,\n msg.sender\n );\n }\n }\n // We require some gas to emit the events (at least 2500) after the execution and some to perform code until the execution (500)\n // We also include the 1/64 in the check that is not send along with a call to counteract potential shortings because of EIP-150\n require(gasleft() >= ((safeTxGas * 64) / 63).max(safeTxGas + 2500) + 500, \"GS010\");\n // Use scope here to limit variable lifetime and prevent `stack too deep` errors\n {\n uint256 gasUsed = gasleft();\n // If the gasPrice is 0 we assume that nearly all available gas can be used (it is always more than safeTxGas)\n // We only substract 2500 (compared to the 3000 before) to ensure that the amount passed is still higher than safeTxGas\n success = execute(to, value, data, operation, gasPrice == 0 ? (gasleft() - 2500) : safeTxGas);\n gasUsed = gasUsed.sub(gasleft());\n // If no safeTxGas and no gasPrice was set (e.g. both are 0), then the internal tx is required to be successful\n // This makes it possible to use `estimateGas` without issues, as it searches for the minimum gas where the tx doesn't revert\n require(success || safeTxGas != 0 || gasPrice != 0, \"GS013\");\n // We transfer the calculated tx costs to the tx.origin to avoid sending it to intermediate contracts that have made calls\n uint256 payment = 0;\n if (gasPrice > 0) {\n payment = handlePayment(gasUsed, baseGas, gasPrice, gasToken, refundReceiver);\n }\n if (success) emit ExecutionSuccess(txHash, payment);\n else emit ExecutionFailure(txHash, payment);\n }\n {\n if (guard != address(0)) {\n Guard(guard).checkAfterExecution(txHash, success);\n }\n }\n }\n\n function handlePayment(\n uint256 gasUsed,\n uint256 baseGas,\n uint256 gasPrice,\n address gasToken,\n address payable refundReceiver\n ) private returns (uint256 payment) {\n // solhint-disable-next-line avoid-tx-origin\n address payable receiver = refundReceiver == address(0) ? payable(tx.origin) : refundReceiver;\n if (gasToken == address(0)) {\n // For ETH we will only adjust the gas price to not be higher than the actual used gas price\n payment = gasUsed.add(baseGas).mul(gasPrice < tx.gasprice ? gasPrice : tx.gasprice);\n require(receiver.send(payment), \"GS011\");\n } else {\n payment = gasUsed.add(baseGas).mul(gasPrice);\n require(transferToken(gasToken, receiver, payment), \"GS012\");\n }\n }\n\n /**\n * @dev Checks whether the signature provided is valid for the provided data, hash. Will revert otherwise.\n * @param dataHash Hash of the data (could be either a message hash or transaction hash)\n * @param data That should be signed (this is passed to an external validator contract)\n * @param signatures Signature data that should be verified. Can be ECDSA signature, contract signature (EIP-1271) or approved hash.\n */\n function checkSignatures(\n bytes32 dataHash,\n bytes memory data,\n bytes memory signatures\n ) public view {\n // Load threshold to avoid multiple storage loads\n uint256 _threshold = threshold;\n // Check that a threshold is set\n require(_threshold > 0, \"GS001\");\n checkNSignatures(dataHash, data, signatures, _threshold);\n }\n\n /**\n * @dev Checks whether the signature provided is valid for the provided data, hash. Will revert otherwise.\n * @param dataHash Hash of the data (could be either a message hash or transaction hash)\n * @param data That should be signed (this is passed to an external validator contract)\n * @param signatures Signature data that should be verified. Can be ECDSA signature, contract signature (EIP-1271) or approved hash.\n * @param requiredSignatures Amount of required valid signatures.\n */\n function checkNSignatures(\n bytes32 dataHash,\n bytes memory data,\n bytes memory signatures,\n uint256 requiredSignatures\n ) public view {\n // Check that the provided signature data is not too short\n require(signatures.length >= requiredSignatures.mul(65), \"GS020\");\n // There cannot be an owner with address 0.\n address lastOwner = address(0);\n address currentOwner;\n uint8 v;\n bytes32 r;\n bytes32 s;\n uint256 i;\n for (i = 0; i < requiredSignatures; i++) {\n (v, r, s) = signatureSplit(signatures, i);\n if (v == 0) {\n // If v is 0 then it is a contract signature\n // When handling contract signatures the address of the contract is encoded into r\n currentOwner = address(uint160(uint256(r)));\n\n // Check that signature data pointer (s) is not pointing inside the static part of the signatures bytes\n // This check is not completely accurate, since it is possible that more signatures than the threshold are send.\n // Here we only check that the pointer is not pointing inside the part that is being processed\n require(uint256(s) >= requiredSignatures.mul(65), \"GS021\");\n\n // Check that signature data pointer (s) is in bounds (points to the length of data -> 32 bytes)\n require(uint256(s).add(32) <= signatures.length, \"GS022\");\n\n // Check if the contract signature is in bounds: start of data is s + 32 and end is start + signature length\n uint256 contractSignatureLen;\n // solhint-disable-next-line no-inline-assembly\n assembly {\n contractSignatureLen := mload(add(add(signatures, s), 0x20))\n }\n require(uint256(s).add(32).add(contractSignatureLen) <= signatures.length, \"GS023\");\n\n // Check signature\n bytes memory contractSignature;\n // solhint-disable-next-line no-inline-assembly\n assembly {\n // The signature data for contract signatures is appended to the concatenated signatures and the offset is stored in s\n contractSignature := add(add(signatures, s), 0x20)\n }\n require(ISignatureValidator(currentOwner).isValidSignature(data, contractSignature) == EIP1271_MAGIC_VALUE, \"GS024\");\n } else if (v == 1) {\n // If v is 1 then it is an approved hash\n // When handling approved hashes the address of the approver is encoded into r\n currentOwner = address(uint160(uint256(r)));\n // Hashes are automatically approved by the sender of the message or when they have been pre-approved via a separate transaction\n require(msg.sender == currentOwner || approvedHashes[currentOwner][dataHash] != 0, \"GS025\");\n } else if (v > 30) {\n // If v > 30 then default va (27,28) has been adjusted for eth_sign flow\n // To support eth_sign and similar we adjust v and hash the messageHash with the Ethereum message prefix before applying ecrecover\n currentOwner = ecrecover(keccak256(abi.encodePacked(\"\\x19Ethereum Signed Message:\\n32\", dataHash)), v - 4, r, s);\n } else {\n // Default is the ecrecover flow with the provided data hash\n // Use ecrecover with the messageHash for EOA signatures\n currentOwner = ecrecover(dataHash, v, r, s);\n }\n require(currentOwner > lastOwner && owners[currentOwner] != address(0) && currentOwner != SENTINEL_OWNERS, \"GS026\");\n lastOwner = currentOwner;\n }\n }\n\n /// @dev Allows to estimate a Safe transaction.\n /// This method is only meant for estimation purpose, therefore the call will always revert and encode the result in the revert data.\n /// Since the `estimateGas` function includes refunds, call this method to get an estimated of the costs that are deducted from the safe with `execTransaction`\n /// @param to Destination address of Safe transaction.\n /// @param value Ether value of Safe transaction.\n /// @param data Data payload of Safe transaction.\n /// @param operation Operation type of Safe transaction.\n /// @return Estimate without refunds and overhead fees (base transaction and payload data gas costs).\n /// @notice Deprecated in favor of common/StorageAccessible.sol and will be removed in next version.\n function requiredTxGas(\n address to,\n uint256 value,\n bytes calldata data,\n Enum.Operation operation\n ) external returns (uint256) {\n uint256 startGas = gasleft();\n // We don't provide an error message here, as we use it to return the estimate\n require(execute(to, value, data, operation, gasleft()));\n uint256 requiredGas = startGas - gasleft();\n // Convert response to string and return via error message\n revert(string(abi.encodePacked(requiredGas)));\n }\n\n /**\n * @dev Marks a hash as approved. This can be used to validate a hash that is used by a signature.\n * @param hashToApprove The hash that should be marked as approved for signatures that are verified by this contract.\n */\n function approveHash(bytes32 hashToApprove) external {\n require(owners[msg.sender] != address(0), \"GS030\");\n approvedHashes[msg.sender][hashToApprove] = 1;\n emit ApproveHash(hashToApprove, msg.sender);\n }\n\n /// @dev Returns the chain id used by this contract.\n function getChainId() public view returns (uint256) {\n uint256 id;\n // solhint-disable-next-line no-inline-assembly\n assembly {\n id := chainid()\n }\n return id;\n }\n\n function domainSeparator() public view returns (bytes32) {\n return keccak256(abi.encode(DOMAIN_SEPARATOR_TYPEHASH, getChainId(), this));\n }\n\n /// @dev Returns the bytes that are hashed to be signed by owners.\n /// @param to Destination address.\n /// @param value Ether value.\n /// @param data Data payload.\n /// @param operation Operation type.\n /// @param safeTxGas Gas that should be used for the safe transaction.\n /// @param baseGas Gas costs for that are independent of the transaction execution(e.g. base transaction fee, signature check, payment of the refund)\n /// @param gasPrice Maximum gas price that should be used for this transaction.\n /// @param gasToken Token address (or 0 if ETH) that is used for the payment.\n /// @param refundReceiver Address of receiver of gas payment (or 0 if tx.origin).\n /// @param _nonce Transaction nonce.\n /// @return Transaction hash bytes.\n function encodeTransactionData(\n address to,\n uint256 value,\n bytes calldata data,\n Enum.Operation operation,\n uint256 safeTxGas,\n uint256 baseGas,\n uint256 gasPrice,\n address gasToken,\n address refundReceiver,\n uint256 _nonce\n ) public view returns (bytes memory) {\n bytes32 safeTxHash =\n keccak256(\n abi.encode(\n SAFE_TX_TYPEHASH,\n to,\n value,\n keccak256(data),\n operation,\n safeTxGas,\n baseGas,\n gasPrice,\n gasToken,\n refundReceiver,\n _nonce\n )\n );\n return abi.encodePacked(bytes1(0x19), bytes1(0x01), domainSeparator(), safeTxHash);\n }\n\n /// @dev Returns hash to be signed by owners.\n /// @param to Destination address.\n /// @param value Ether value.\n /// @param data Data payload.\n /// @param operation Operation type.\n /// @param safeTxGas Fas that should be used for the safe transaction.\n /// @param baseGas Gas costs for data used to trigger the safe transaction.\n /// @param gasPrice Maximum gas price that should be used for this transaction.\n /// @param gasToken Token address (or 0 if ETH) that is used for the payment.\n /// @param refundReceiver Address of receiver of gas payment (or 0 if tx.origin).\n /// @param _nonce Transaction nonce.\n /// @return Transaction hash.\n function getTransactionHash(\n address to,\n uint256 value,\n bytes calldata data,\n Enum.Operation operation,\n uint256 safeTxGas,\n uint256 baseGas,\n uint256 gasPrice,\n address gasToken,\n address refundReceiver,\n uint256 _nonce\n ) public view returns (bytes32) {\n return keccak256(encodeTransactionData(to, value, data, operation, safeTxGas, baseGas, gasPrice, gasToken, refundReceiver, _nonce));\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/handler/DefaultCallbackHandler.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\nimport \"../interfaces/ERC1155TokenReceiver.sol\";\nimport \"../interfaces/ERC721TokenReceiver.sol\";\nimport \"../interfaces/ERC777TokensRecipient.sol\";\nimport \"../interfaces/IERC165.sol\";\n\n/// @title Default Callback Handler - returns true for known token callbacks\n/// @author Richard Meissner - \ncontract DefaultCallbackHandler is ERC1155TokenReceiver, ERC777TokensRecipient, ERC721TokenReceiver, IERC165 {\n string public constant NAME = \"Default Callback Handler\";\n string public constant VERSION = \"1.0.0\";\n\n function onERC1155Received(\n address,\n address,\n uint256,\n uint256,\n bytes calldata\n ) external pure override returns (bytes4) {\n return 0xf23a6e61;\n }\n\n function onERC1155BatchReceived(\n address,\n address,\n uint256[] calldata,\n uint256[] calldata,\n bytes calldata\n ) external pure override returns (bytes4) {\n return 0xbc197c81;\n }\n\n function onERC721Received(\n address,\n address,\n uint256,\n bytes calldata\n ) external pure override returns (bytes4) {\n return 0x150b7a02;\n }\n\n function tokensReceived(\n address,\n address,\n address,\n uint256,\n bytes calldata,\n bytes calldata\n ) external pure override {\n // We implement this for completeness, doesn't really have any value\n }\n\n function supportsInterface(bytes4 interfaceId) external view virtual override returns (bool) {\n return\n interfaceId == type(ERC1155TokenReceiver).interfaceId ||\n interfaceId == type(ERC721TokenReceiver).interfaceId ||\n interfaceId == type(IERC165).interfaceId;\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/interfaces/ERC1155TokenReceiver.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/**\n Note: The ERC-165 identifier for this interface is 0x4e2312e0.\n*/\ninterface ERC1155TokenReceiver {\n /**\n @notice Handle the receipt of a single ERC1155 token type.\n @dev An ERC1155-compliant smart contract MUST call this function on the token recipient contract, at the end of a `safeTransferFrom` after the balance has been updated. \n This function MUST return `bytes4(keccak256(\"onERC1155Received(address,address,uint256,uint256,bytes)\"))` (i.e. 0xf23a6e61) if it accepts the transfer.\n This function MUST revert if it rejects the transfer.\n Return of any other value than the prescribed keccak256 generated value MUST result in the transaction being reverted by the caller.\n @param _operator The address which initiated the transfer (i.e. msg.sender)\n @param _from The address which previously owned the token\n @param _id The ID of the token being transferred\n @param _value The amount of tokens being transferred\n @param _data Additional data with no specified format\n @return `bytes4(keccak256(\"onERC1155Received(address,address,uint256,uint256,bytes)\"))`\n */\n function onERC1155Received(\n address _operator,\n address _from,\n uint256 _id,\n uint256 _value,\n bytes calldata _data\n ) external returns (bytes4);\n\n /**\n @notice Handle the receipt of multiple ERC1155 token types.\n @dev An ERC1155-compliant smart contract MUST call this function on the token recipient contract, at the end of a `safeBatchTransferFrom` after the balances have been updated. \n This function MUST return `bytes4(keccak256(\"onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)\"))` (i.e. 0xbc197c81) if it accepts the transfer(s).\n This function MUST revert if it rejects the transfer(s).\n Return of any other value than the prescribed keccak256 generated value MUST result in the transaction being reverted by the caller.\n @param _operator The address which initiated the batch transfer (i.e. msg.sender)\n @param _from The address which previously owned the token\n @param _ids An array containing ids of each token being transferred (order and length must match _values array)\n @param _values An array containing amounts of each token being transferred (order and length must match _ids array)\n @param _data Additional data with no specified format\n @return `bytes4(keccak256(\"onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)\"))`\n */\n function onERC1155BatchReceived(\n address _operator,\n address _from,\n uint256[] calldata _ids,\n uint256[] calldata _values,\n bytes calldata _data\n ) external returns (bytes4);\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/interfaces/ERC721TokenReceiver.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/// @dev Note: the ERC-165 identifier for this interface is 0x150b7a02.\ninterface ERC721TokenReceiver {\n /// @notice Handle the receipt of an NFT\n /// @dev The ERC721 smart contract calls this function on the recipient\n /// after a `transfer`. This function MAY throw to revert and reject the\n /// transfer. Return of other than the magic value MUST result in the\n /// transaction being reverted.\n /// Note: the contract address is always the message sender.\n /// @param _operator The address which called `safeTransferFrom` function\n /// @param _from The address which previously owned the token\n /// @param _tokenId The NFT identifier which is being transferred\n /// @param _data Additional data with no specified format\n /// @return `bytes4(keccak256(\"onERC721Received(address,address,uint256,bytes)\"))`\n /// unless throwing\n function onERC721Received(\n address _operator,\n address _from,\n uint256 _tokenId,\n bytes calldata _data\n ) external returns (bytes4);\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/interfaces/ERC777TokensRecipient.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\ninterface ERC777TokensRecipient {\n function tokensReceived(\n address operator,\n address from,\n address to,\n uint256 amount,\n bytes calldata data,\n bytes calldata operatorData\n ) external;\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/interfaces/IERC165.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/// @notice More details at https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/utils/introspection/IERC165.sol\ninterface IERC165 {\n /**\n * @dev Returns true if this contract implements the interface defined by\n * `interfaceId`. See the corresponding\n * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]\n * to learn more about how these ids are created.\n *\n * This function call must use less than 30 000 gas.\n */\n function supportsInterface(bytes4 interfaceId) external view returns (bool);\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/interfaces/ISignatureValidator.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\ncontract ISignatureValidatorConstants {\n // bytes4(keccak256(\"isValidSignature(bytes,bytes)\")\n bytes4 internal constant EIP1271_MAGIC_VALUE = 0x20c13b0b;\n}\n\nabstract contract ISignatureValidator is ISignatureValidatorConstants {\n /**\n * @dev Should return whether the signature provided is valid for the provided data\n * @param _data Arbitrary length data signed on the behalf of address(this)\n * @param _signature Signature byte array associated with _data\n *\n * MUST return the bytes4 magic value 0x20c13b0b when function passes.\n * MUST NOT modify state (using STATICCALL for solc < 0.5, view modifier for solc > 0.5)\n * MUST allow external calls\n */\n function isValidSignature(bytes memory _data, bytes memory _signature) public view virtual returns (bytes4);\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/proxies/GnosisSafeProxy.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\n/// @title IProxy - Helper interface to access masterCopy of the Proxy on-chain\n/// @author Richard Meissner - \ninterface IProxy {\n function masterCopy() external view returns (address);\n}\n\n/// @title GnosisSafeProxy - Generic proxy contract allows to execute all transactions applying the code of a master contract.\n/// @author Stefan George - \n/// @author Richard Meissner - \ncontract GnosisSafeProxy {\n // singleton always needs to be first declared variable, to ensure that it is at the same location in the contracts to which calls are delegated.\n // To reduce deployment costs this variable is internal and needs to be retrieved via `getStorageAt`\n address internal singleton;\n\n /// @dev Constructor function sets address of singleton contract.\n /// @param _singleton Singleton address.\n constructor(address _singleton) {\n require(_singleton != address(0), \"Invalid singleton address provided\");\n singleton = _singleton;\n }\n\n /// @dev Fallback function forwards all transactions and returns all received return data.\n fallback() external payable {\n // solhint-disable-next-line no-inline-assembly\n assembly {\n let _singleton := and(sload(0), 0xffffffffffffffffffffffffffffffffffffffff)\n // 0xa619486e == keccak(\"masterCopy()\"). The value is right padded to 32-bytes with 0s\n if eq(calldataload(0), 0xa619486e00000000000000000000000000000000000000000000000000000000) {\n mstore(0, _singleton)\n return(0, 0x20)\n }\n calldatacopy(0, 0, calldatasize())\n let success := delegatecall(gas(), _singleton, 0, calldatasize(), 0, 0)\n returndatacopy(0, 0, returndatasize())\n if eq(success, 0) {\n revert(0, returndatasize())\n }\n return(0, returndatasize())\n }\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/proxies/GnosisSafeProxyFactory.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\n\nimport \"./GnosisSafeProxy.sol\";\nimport \"./IProxyCreationCallback.sol\";\n\n/// @title Proxy Factory - Allows to create new proxy contact and execute a message call to the new proxy within one transaction.\n/// @author Stefan George - \ncontract GnosisSafeProxyFactory {\n event ProxyCreation(GnosisSafeProxy proxy, address singleton);\n\n /// @dev Allows to create new proxy contact and execute a message call to the new proxy within one transaction.\n /// @param singleton Address of singleton contract.\n /// @param data Payload for message call sent to new proxy contract.\n function createProxy(address singleton, bytes memory data) public returns (GnosisSafeProxy proxy) {\n proxy = new GnosisSafeProxy(singleton);\n if (data.length > 0)\n // solhint-disable-next-line no-inline-assembly\n assembly {\n if eq(call(gas(), proxy, 0, add(data, 0x20), mload(data), 0, 0), 0) {\n revert(0, 0)\n }\n }\n emit ProxyCreation(proxy, singleton);\n }\n\n /// @dev Allows to retrieve the runtime code of a deployed Proxy. This can be used to check that the expected Proxy was deployed.\n function proxyRuntimeCode() public pure returns (bytes memory) {\n return type(GnosisSafeProxy).runtimeCode;\n }\n\n /// @dev Allows to retrieve the creation code used for the Proxy deployment. With this it is easily possible to calculate predicted address.\n function proxyCreationCode() public pure returns (bytes memory) {\n return type(GnosisSafeProxy).creationCode;\n }\n\n /// @dev Allows to create new proxy contact using CREATE2 but it doesn't run the initializer.\n /// This method is only meant as an utility to be called from other methods\n /// @param _singleton Address of singleton contract.\n /// @param initializer Payload for message call sent to new proxy contract.\n /// @param saltNonce Nonce that will be used to generate the salt to calculate the address of the new proxy contract.\n function deployProxyWithNonce(\n address _singleton,\n bytes memory initializer,\n uint256 saltNonce\n ) internal returns (GnosisSafeProxy proxy) {\n // If the initializer changes the proxy address should change too. Hashing the initializer data is cheaper than just concatinating it\n bytes32 salt = keccak256(abi.encodePacked(keccak256(initializer), saltNonce));\n bytes memory deploymentData = abi.encodePacked(type(GnosisSafeProxy).creationCode, uint256(uint160(_singleton)));\n // solhint-disable-next-line no-inline-assembly\n assembly {\n proxy := create2(0x0, add(0x20, deploymentData), mload(deploymentData), salt)\n }\n require(address(proxy) != address(0), \"Create2 call failed\");\n }\n\n /// @dev Allows to create new proxy contact and execute a message call to the new proxy within one transaction.\n /// @param _singleton Address of singleton contract.\n /// @param initializer Payload for message call sent to new proxy contract.\n /// @param saltNonce Nonce that will be used to generate the salt to calculate the address of the new proxy contract.\n function createProxyWithNonce(\n address _singleton,\n bytes memory initializer,\n uint256 saltNonce\n ) public returns (GnosisSafeProxy proxy) {\n proxy = deployProxyWithNonce(_singleton, initializer, saltNonce);\n if (initializer.length > 0)\n // solhint-disable-next-line no-inline-assembly\n assembly {\n if eq(call(gas(), proxy, 0, add(initializer, 0x20), mload(initializer), 0, 0), 0) {\n revert(0, 0)\n }\n }\n emit ProxyCreation(proxy, _singleton);\n }\n\n /// @dev Allows to create new proxy contact, execute a message call to the new proxy and call a specified callback within one transaction\n /// @param _singleton Address of singleton contract.\n /// @param initializer Payload for message call sent to new proxy contract.\n /// @param saltNonce Nonce that will be used to generate the salt to calculate the address of the new proxy contract.\n /// @param callback Callback that will be invoced after the new proxy contract has been successfully deployed and initialized.\n function createProxyWithCallback(\n address _singleton,\n bytes memory initializer,\n uint256 saltNonce,\n IProxyCreationCallback callback\n ) public returns (GnosisSafeProxy proxy) {\n uint256 saltNonceWithCallback = uint256(keccak256(abi.encodePacked(saltNonce, callback)));\n proxy = createProxyWithNonce(_singleton, initializer, saltNonceWithCallback);\n if (address(callback) != address(0)) callback.proxyCreated(proxy, _singleton, initializer, saltNonce);\n }\n\n /// @dev Allows to get the address for a new proxy contact created via `createProxyWithNonce`\n /// This method is only meant for address calculation purpose when you use an initializer that would revert,\n /// therefore the response is returned with a revert. When calling this method set `from` to the address of the proxy factory.\n /// @param _singleton Address of singleton contract.\n /// @param initializer Payload for message call sent to new proxy contract.\n /// @param saltNonce Nonce that will be used to generate the salt to calculate the address of the new proxy contract.\n function calculateCreateProxyWithNonceAddress(\n address _singleton,\n bytes calldata initializer,\n uint256 saltNonce\n ) external returns (GnosisSafeProxy proxy) {\n proxy = deployProxyWithNonce(_singleton, initializer, saltNonce);\n revert(string(abi.encodePacked(proxy)));\n }\n}\n" - }, - "@gnosis.pm/safe-contracts/contracts/proxies/IProxyCreationCallback.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.0 <0.9.0;\nimport \"./GnosisSafeProxy.sol\";\n\ninterface IProxyCreationCallback {\n function proxyCreated(\n GnosisSafeProxy proxy,\n address _singleton,\n bytes calldata initializer,\n uint256 saltNonce\n ) external;\n}\n" - }, - "@openzeppelin/contracts/access/Ownable.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)\n\npragma solidity ^0.8.0;\n\nimport \"../utils/Context.sol\";\n\n/**\n * @dev Contract module which provides a basic access control mechanism, where\n * there is an account (an owner) that can be granted exclusive access to\n * specific functions.\n *\n * By default, the owner account will be the one that deploys the contract. This\n * can later be changed with {transferOwnership}.\n *\n * This module is used through inheritance. It will make available the modifier\n * `onlyOwner`, which can be applied to your functions to restrict their use to\n * the owner.\n */\nabstract contract Ownable is Context {\n address private _owner;\n\n event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);\n\n /**\n * @dev Initializes the contract setting the deployer as the initial owner.\n */\n constructor() {\n _transferOwnership(_msgSender());\n }\n\n /**\n * @dev Throws if called by any account other than the owner.\n */\n modifier onlyOwner() {\n _checkOwner();\n _;\n }\n\n /**\n * @dev Returns the address of the current owner.\n */\n function owner() public view virtual returns (address) {\n return _owner;\n }\n\n /**\n * @dev Throws if the sender is not the owner.\n */\n function _checkOwner() internal view virtual {\n require(owner() == _msgSender(), \"Ownable: caller is not the owner\");\n }\n\n /**\n * @dev Leaves the contract without owner. It will not be possible to call\n * `onlyOwner` functions anymore. Can only be called by the current owner.\n *\n * NOTE: Renouncing ownership will leave the contract without an owner,\n * thereby removing any functionality that is only available to the owner.\n */\n function renounceOwnership() public virtual onlyOwner {\n _transferOwnership(address(0));\n }\n\n /**\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\n * Can only be called by the current owner.\n */\n function transferOwnership(address newOwner) public virtual onlyOwner {\n require(newOwner != address(0), \"Ownable: new owner is the zero address\");\n _transferOwnership(newOwner);\n }\n\n /**\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\n * Internal function without access restriction.\n */\n function _transferOwnership(address newOwner) internal virtual {\n address oldOwner = _owner;\n _owner = newOwner;\n emit OwnershipTransferred(oldOwner, newOwner);\n }\n}\n" - }, - "@openzeppelin/contracts/interfaces/draft-IERC1822.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.5.0) (interfaces/draft-IERC1822.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev ERC1822: Universal Upgradeable Proxy Standard (UUPS) documents a method for upgradeability through a simplified\n * proxy whose upgrades are fully controlled by the current implementation.\n */\ninterface IERC1822Proxiable {\n /**\n * @dev Returns the storage slot that the proxiable contract assumes is being used to store the implementation\n * address.\n *\n * IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks\n * bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this\n * function revert if invoked through a proxy.\n */\n function proxiableUUID() external view returns (bytes32);\n}\n" - }, - "@openzeppelin/contracts/interfaces/IERC1271.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts v4.4.1 (interfaces/IERC1271.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Interface of the ERC1271 standard signature validation method for\n * contracts as defined in https://eips.ethereum.org/EIPS/eip-1271[ERC-1271].\n *\n * _Available since v4.1._\n */\ninterface IERC1271 {\n /**\n * @dev Should return whether the signature provided is valid for the provided data\n * @param hash Hash of the data to be signed\n * @param signature Signature byte array associated with _data\n */\n function isValidSignature(bytes32 hash, bytes memory signature) external view returns (bytes4 magicValue);\n}\n" - }, - "@openzeppelin/contracts/proxy/beacon/IBeacon.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts v4.4.1 (proxy/beacon/IBeacon.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev This is the interface that {BeaconProxy} expects of its beacon.\n */\ninterface IBeacon {\n /**\n * @dev Must return an address that can be used as a delegate call target.\n *\n * {BeaconProxy} will check that this address is a contract.\n */\n function implementation() external view returns (address);\n}\n" - }, - "@openzeppelin/contracts/proxy/ERC1967/ERC1967Proxy.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.7.0) (proxy/ERC1967/ERC1967Proxy.sol)\n\npragma solidity ^0.8.0;\n\nimport \"../Proxy.sol\";\nimport \"./ERC1967Upgrade.sol\";\n\n/**\n * @dev This contract implements an upgradeable proxy. It is upgradeable because calls are delegated to an\n * implementation address that can be changed. This address is stored in storage in the location specified by\n * https://eips.ethereum.org/EIPS/eip-1967[EIP1967], so that it doesn't conflict with the storage layout of the\n * implementation behind the proxy.\n */\ncontract ERC1967Proxy is Proxy, ERC1967Upgrade {\n /**\n * @dev Initializes the upgradeable proxy with an initial implementation specified by `_logic`.\n *\n * If `_data` is nonempty, it's used as data in a delegate call to `_logic`. This will typically be an encoded\n * function call, and allows initializing the storage of the proxy like a Solidity constructor.\n */\n constructor(address _logic, bytes memory _data) payable {\n _upgradeToAndCall(_logic, _data, false);\n }\n\n /**\n * @dev Returns the current implementation address.\n */\n function _implementation() internal view virtual override returns (address impl) {\n return ERC1967Upgrade._getImplementation();\n }\n}\n" - }, - "@openzeppelin/contracts/proxy/ERC1967/ERC1967Upgrade.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.5.0) (proxy/ERC1967/ERC1967Upgrade.sol)\n\npragma solidity ^0.8.2;\n\nimport \"../beacon/IBeacon.sol\";\nimport \"../../interfaces/draft-IERC1822.sol\";\nimport \"../../utils/Address.sol\";\nimport \"../../utils/StorageSlot.sol\";\n\n/**\n * @dev This abstract contract provides getters and event emitting update functions for\n * https://eips.ethereum.org/EIPS/eip-1967[EIP1967] slots.\n *\n * _Available since v4.1._\n *\n * @custom:oz-upgrades-unsafe-allow delegatecall\n */\nabstract contract ERC1967Upgrade {\n // This is the keccak-256 hash of \"eip1967.proxy.rollback\" subtracted by 1\n bytes32 private constant _ROLLBACK_SLOT = 0x4910fdfa16fed3260ed0e7147f7cc6da11a60208b5b9406d12a635614ffd9143;\n\n /**\n * @dev Storage slot with the address of the current implementation.\n * This is the keccak-256 hash of \"eip1967.proxy.implementation\" subtracted by 1, and is\n * validated in the constructor.\n */\n bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;\n\n /**\n * @dev Emitted when the implementation is upgraded.\n */\n event Upgraded(address indexed implementation);\n\n /**\n * @dev Returns the current implementation address.\n */\n function _getImplementation() internal view returns (address) {\n return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;\n }\n\n /**\n * @dev Stores a new address in the EIP1967 implementation slot.\n */\n function _setImplementation(address newImplementation) private {\n require(Address.isContract(newImplementation), \"ERC1967: new implementation is not a contract\");\n StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;\n }\n\n /**\n * @dev Perform implementation upgrade\n *\n * Emits an {Upgraded} event.\n */\n function _upgradeTo(address newImplementation) internal {\n _setImplementation(newImplementation);\n emit Upgraded(newImplementation);\n }\n\n /**\n * @dev Perform implementation upgrade with additional setup call.\n *\n * Emits an {Upgraded} event.\n */\n function _upgradeToAndCall(\n address newImplementation,\n bytes memory data,\n bool forceCall\n ) internal {\n _upgradeTo(newImplementation);\n if (data.length > 0 || forceCall) {\n Address.functionDelegateCall(newImplementation, data);\n }\n }\n\n /**\n * @dev Perform implementation upgrade with security checks for UUPS proxies, and additional setup call.\n *\n * Emits an {Upgraded} event.\n */\n function _upgradeToAndCallUUPS(\n address newImplementation,\n bytes memory data,\n bool forceCall\n ) internal {\n // Upgrades from old implementations will perform a rollback test. This test requires the new\n // implementation to upgrade back to the old, non-ERC1822 compliant, implementation. Removing\n // this special case will break upgrade paths from old UUPS implementation to new ones.\n if (StorageSlot.getBooleanSlot(_ROLLBACK_SLOT).value) {\n _setImplementation(newImplementation);\n } else {\n try IERC1822Proxiable(newImplementation).proxiableUUID() returns (bytes32 slot) {\n require(slot == _IMPLEMENTATION_SLOT, \"ERC1967Upgrade: unsupported proxiableUUID\");\n } catch {\n revert(\"ERC1967Upgrade: new implementation is not UUPS\");\n }\n _upgradeToAndCall(newImplementation, data, forceCall);\n }\n }\n\n /**\n * @dev Storage slot with the admin of the contract.\n * This is the keccak-256 hash of \"eip1967.proxy.admin\" subtracted by 1, and is\n * validated in the constructor.\n */\n bytes32 internal constant _ADMIN_SLOT = 0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103;\n\n /**\n * @dev Emitted when the admin account has changed.\n */\n event AdminChanged(address previousAdmin, address newAdmin);\n\n /**\n * @dev Returns the current admin.\n */\n function _getAdmin() internal view returns (address) {\n return StorageSlot.getAddressSlot(_ADMIN_SLOT).value;\n }\n\n /**\n * @dev Stores a new address in the EIP1967 admin slot.\n */\n function _setAdmin(address newAdmin) private {\n require(newAdmin != address(0), \"ERC1967: new admin is the zero address\");\n StorageSlot.getAddressSlot(_ADMIN_SLOT).value = newAdmin;\n }\n\n /**\n * @dev Changes the admin of the proxy.\n *\n * Emits an {AdminChanged} event.\n */\n function _changeAdmin(address newAdmin) internal {\n emit AdminChanged(_getAdmin(), newAdmin);\n _setAdmin(newAdmin);\n }\n\n /**\n * @dev The storage slot of the UpgradeableBeacon contract which defines the implementation for this proxy.\n * This is bytes32(uint256(keccak256('eip1967.proxy.beacon')) - 1)) and is validated in the constructor.\n */\n bytes32 internal constant _BEACON_SLOT = 0xa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d50;\n\n /**\n * @dev Emitted when the beacon is upgraded.\n */\n event BeaconUpgraded(address indexed beacon);\n\n /**\n * @dev Returns the current beacon.\n */\n function _getBeacon() internal view returns (address) {\n return StorageSlot.getAddressSlot(_BEACON_SLOT).value;\n }\n\n /**\n * @dev Stores a new beacon in the EIP1967 beacon slot.\n */\n function _setBeacon(address newBeacon) private {\n require(Address.isContract(newBeacon), \"ERC1967: new beacon is not a contract\");\n require(\n Address.isContract(IBeacon(newBeacon).implementation()),\n \"ERC1967: beacon implementation is not a contract\"\n );\n StorageSlot.getAddressSlot(_BEACON_SLOT).value = newBeacon;\n }\n\n /**\n * @dev Perform beacon upgrade with additional setup call. Note: This upgrades the address of the beacon, it does\n * not upgrade the implementation contained in the beacon (see {UpgradeableBeacon-_setImplementation} for that).\n *\n * Emits a {BeaconUpgraded} event.\n */\n function _upgradeBeaconToAndCall(\n address newBeacon,\n bytes memory data,\n bool forceCall\n ) internal {\n _setBeacon(newBeacon);\n emit BeaconUpgraded(newBeacon);\n if (data.length > 0 || forceCall) {\n Address.functionDelegateCall(IBeacon(newBeacon).implementation(), data);\n }\n }\n}\n" - }, - "@openzeppelin/contracts/proxy/Proxy.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.6.0) (proxy/Proxy.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev This abstract contract provides a fallback function that delegates all calls to another contract using the EVM\n * instruction `delegatecall`. We refer to the second contract as the _implementation_ behind the proxy, and it has to\n * be specified by overriding the virtual {_implementation} function.\n *\n * Additionally, delegation to the implementation can be triggered manually through the {_fallback} function, or to a\n * different contract through the {_delegate} function.\n *\n * The success and return data of the delegated call will be returned back to the caller of the proxy.\n */\nabstract contract Proxy {\n /**\n * @dev Delegates the current call to `implementation`.\n *\n * This function does not return to its internal call site, it will return directly to the external caller.\n */\n function _delegate(address implementation) internal virtual {\n assembly {\n // Copy msg.data. We take full control of memory in this inline assembly\n // block because it will not return to Solidity code. We overwrite the\n // Solidity scratch pad at memory position 0.\n calldatacopy(0, 0, calldatasize())\n\n // Call the implementation.\n // out and outsize are 0 because we don't know the size yet.\n let result := delegatecall(gas(), implementation, 0, calldatasize(), 0, 0)\n\n // Copy the returned data.\n returndatacopy(0, 0, returndatasize())\n\n switch result\n // delegatecall returns 0 on error.\n case 0 {\n revert(0, returndatasize())\n }\n default {\n return(0, returndatasize())\n }\n }\n }\n\n /**\n * @dev This is a virtual function that should be overridden so it returns the address to which the fallback function\n * and {_fallback} should delegate.\n */\n function _implementation() internal view virtual returns (address);\n\n /**\n * @dev Delegates the current call to the address returned by `_implementation()`.\n *\n * This function does not return to its internal call site, it will return directly to the external caller.\n */\n function _fallback() internal virtual {\n _beforeFallback();\n _delegate(_implementation());\n }\n\n /**\n * @dev Fallback function that delegates calls to the address returned by `_implementation()`. Will run if no other\n * function in the contract matches the call data.\n */\n fallback() external payable virtual {\n _fallback();\n }\n\n /**\n * @dev Fallback function that delegates calls to the address returned by `_implementation()`. Will run if call data\n * is empty.\n */\n receive() external payable virtual {\n _fallback();\n }\n\n /**\n * @dev Hook that is called before falling back to the implementation. Can happen as part of a manual `_fallback`\n * call, or as part of the Solidity `fallback` or `receive` functions.\n *\n * If overridden should call `super._beforeFallback()`.\n */\n function _beforeFallback() internal virtual {}\n}\n" - }, - "@openzeppelin/contracts/proxy/utils/Initializable.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (proxy/utils/Initializable.sol)\n\npragma solidity ^0.8.2;\n\nimport \"../../utils/Address.sol\";\n\n/**\n * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed\n * behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an\n * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer\n * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.\n *\n * The initialization functions use a version number. Once a version number is used, it is consumed and cannot be\n * reused. This mechanism prevents re-execution of each \"step\" but allows the creation of new initialization steps in\n * case an upgrade adds a module that needs to be initialized.\n *\n * For example:\n *\n * [.hljs-theme-light.nopadding]\n * ```\n * contract MyToken is ERC20Upgradeable {\n * function initialize() initializer public {\n * __ERC20_init(\"MyToken\", \"MTK\");\n * }\n * }\n * contract MyTokenV2 is MyToken, ERC20PermitUpgradeable {\n * function initializeV2() reinitializer(2) public {\n * __ERC20Permit_init(\"MyToken\");\n * }\n * }\n * ```\n *\n * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as\n * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.\n *\n * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure\n * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.\n *\n * [CAUTION]\n * ====\n * Avoid leaving a contract uninitialized.\n *\n * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation\n * contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke\n * the {_disableInitializers} function in the constructor to automatically lock it when it is deployed:\n *\n * [.hljs-theme-light.nopadding]\n * ```\n * /// @custom:oz-upgrades-unsafe-allow constructor\n * constructor() {\n * _disableInitializers();\n * }\n * ```\n * ====\n */\nabstract contract Initializable {\n /**\n * @dev Indicates that the contract has been initialized.\n * @custom:oz-retyped-from bool\n */\n uint8 private _initialized;\n\n /**\n * @dev Indicates that the contract is in the process of being initialized.\n */\n bool private _initializing;\n\n /**\n * @dev Triggered when the contract has been initialized or reinitialized.\n */\n event Initialized(uint8 version);\n\n /**\n * @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope,\n * `onlyInitializing` functions can be used to initialize parent contracts.\n *\n * Similar to `reinitializer(1)`, except that functions marked with `initializer` can be nested in the context of a\n * constructor.\n *\n * Emits an {Initialized} event.\n */\n modifier initializer() {\n bool isTopLevelCall = !_initializing;\n require(\n (isTopLevelCall && _initialized < 1) || (!Address.isContract(address(this)) && _initialized == 1),\n \"Initializable: contract is already initialized\"\n );\n _initialized = 1;\n if (isTopLevelCall) {\n _initializing = true;\n }\n _;\n if (isTopLevelCall) {\n _initializing = false;\n emit Initialized(1);\n }\n }\n\n /**\n * @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the\n * contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be\n * used to initialize parent contracts.\n *\n * A reinitializer may be used after the original initialization step. This is essential to configure modules that\n * are added through upgrades and that require initialization.\n *\n * When `version` is 1, this modifier is similar to `initializer`, except that functions marked with `reinitializer`\n * cannot be nested. If one is invoked in the context of another, execution will revert.\n *\n * Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in\n * a contract, executing them in the right order is up to the developer or operator.\n *\n * WARNING: setting the version to 255 will prevent any future reinitialization.\n *\n * Emits an {Initialized} event.\n */\n modifier reinitializer(uint8 version) {\n require(!_initializing && _initialized < version, \"Initializable: contract is already initialized\");\n _initialized = version;\n _initializing = true;\n _;\n _initializing = false;\n emit Initialized(version);\n }\n\n /**\n * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the\n * {initializer} and {reinitializer} modifiers, directly or indirectly.\n */\n modifier onlyInitializing() {\n require(_initializing, \"Initializable: contract is not initializing\");\n _;\n }\n\n /**\n * @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call.\n * Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized\n * to any version. It is recommended to use this to lock implementation contracts that are designed to be called\n * through proxies.\n *\n * Emits an {Initialized} event the first time it is successfully executed.\n */\n function _disableInitializers() internal virtual {\n require(!_initializing, \"Initializable: contract is initializing\");\n if (_initialized < type(uint8).max) {\n _initialized = type(uint8).max;\n emit Initialized(type(uint8).max);\n }\n }\n\n /**\n * @dev Internal function that returns the initialized version. Returns `_initialized`\n */\n function _getInitializedVersion() internal view returns (uint8) {\n return _initialized;\n }\n\n /**\n * @dev Internal function that returns the initialized version. Returns `_initializing`\n */\n function _isInitializing() internal view returns (bool) {\n return _initializing;\n }\n}\n" - }, - "@openzeppelin/contracts/proxy/utils/UUPSUpgradeable.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (proxy/utils/UUPSUpgradeable.sol)\n\npragma solidity ^0.8.0;\n\nimport \"../../interfaces/draft-IERC1822.sol\";\nimport \"../ERC1967/ERC1967Upgrade.sol\";\n\n/**\n * @dev An upgradeability mechanism designed for UUPS proxies. The functions included here can perform an upgrade of an\n * {ERC1967Proxy}, when this contract is set as the implementation behind such a proxy.\n *\n * A security mechanism ensures that an upgrade does not turn off upgradeability accidentally, although this risk is\n * reinstated if the upgrade retains upgradeability but removes the security mechanism, e.g. by replacing\n * `UUPSUpgradeable` with a custom implementation of upgrades.\n *\n * The {_authorizeUpgrade} function must be overridden to include access restriction to the upgrade mechanism.\n *\n * _Available since v4.1._\n */\nabstract contract UUPSUpgradeable is IERC1822Proxiable, ERC1967Upgrade {\n /// @custom:oz-upgrades-unsafe-allow state-variable-immutable state-variable-assignment\n address private immutable __self = address(this);\n\n /**\n * @dev Check that the execution is being performed through a delegatecall call and that the execution context is\n * a proxy contract with an implementation (as defined in ERC1967) pointing to self. This should only be the case\n * for UUPS and transparent proxies that are using the current contract as their implementation. Execution of a\n * function through ERC1167 minimal proxies (clones) would not normally pass this test, but is not guaranteed to\n * fail.\n */\n modifier onlyProxy() {\n require(address(this) != __self, \"Function must be called through delegatecall\");\n require(_getImplementation() == __self, \"Function must be called through active proxy\");\n _;\n }\n\n /**\n * @dev Check that the execution is not being performed through a delegate call. This allows a function to be\n * callable on the implementing contract but not through proxies.\n */\n modifier notDelegated() {\n require(address(this) == __self, \"UUPSUpgradeable: must not be called through delegatecall\");\n _;\n }\n\n /**\n * @dev Implementation of the ERC1822 {proxiableUUID} function. This returns the storage slot used by the\n * implementation. It is used to validate the implementation's compatibility when performing an upgrade.\n *\n * IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks\n * bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this\n * function revert if invoked through a proxy. This is guaranteed by the `notDelegated` modifier.\n */\n function proxiableUUID() external view virtual override notDelegated returns (bytes32) {\n return _IMPLEMENTATION_SLOT;\n }\n\n /**\n * @dev Upgrade the implementation of the proxy to `newImplementation`.\n *\n * Calls {_authorizeUpgrade}.\n *\n * Emits an {Upgraded} event.\n */\n function upgradeTo(address newImplementation) external virtual onlyProxy {\n _authorizeUpgrade(newImplementation);\n _upgradeToAndCallUUPS(newImplementation, new bytes(0), false);\n }\n\n /**\n * @dev Upgrade the implementation of the proxy to `newImplementation`, and subsequently execute the function call\n * encoded in `data`.\n *\n * Calls {_authorizeUpgrade}.\n *\n * Emits an {Upgraded} event.\n */\n function upgradeToAndCall(address newImplementation, bytes memory data) external payable virtual onlyProxy {\n _authorizeUpgrade(newImplementation);\n _upgradeToAndCallUUPS(newImplementation, data, true);\n }\n\n /**\n * @dev Function that should revert when `msg.sender` is not authorized to upgrade the contract. Called by\n * {upgradeTo} and {upgradeToAndCall}.\n *\n * Normally, this function will use an xref:access.adoc[access control] modifier such as {Ownable-onlyOwner}.\n *\n * ```solidity\n * function _authorizeUpgrade(address) internal override onlyOwner {}\n * ```\n */\n function _authorizeUpgrade(address newImplementation) internal virtual;\n}\n" - }, - "@openzeppelin/contracts/security/ReentrancyGuard.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (security/ReentrancyGuard.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Contract module that helps prevent reentrant calls to a function.\n *\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\n * available, which can be applied to functions to make sure there are no nested\n * (reentrant) calls to them.\n *\n * Note that because there is a single `nonReentrant` guard, functions marked as\n * `nonReentrant` may not call one another. This can be worked around by making\n * those functions `private`, and then adding `external` `nonReentrant` entry\n * points to them.\n *\n * TIP: If you would like to learn more about reentrancy and alternative ways\n * to protect against it, check out our blog post\n * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].\n */\nabstract contract ReentrancyGuard {\n // Booleans are more expensive than uint256 or any type that takes up a full\n // word because each write operation emits an extra SLOAD to first read the\n // slot's contents, replace the bits taken up by the boolean, and then write\n // back. This is the compiler's defense against contract upgrades and\n // pointer aliasing, and it cannot be disabled.\n\n // The values being non-zero value makes deployment a bit more expensive,\n // but in exchange the refund on every call to nonReentrant will be lower in\n // amount. Since refunds are capped to a percentage of the total\n // transaction's gas, it is best to keep them low in cases like this one, to\n // increase the likelihood of the full refund coming into effect.\n uint256 private constant _NOT_ENTERED = 1;\n uint256 private constant _ENTERED = 2;\n\n uint256 private _status;\n\n constructor() {\n _status = _NOT_ENTERED;\n }\n\n /**\n * @dev Prevents a contract from calling itself, directly or indirectly.\n * Calling a `nonReentrant` function from another `nonReentrant`\n * function is not supported. It is possible to prevent this from happening\n * by making the `nonReentrant` function external, and making it call a\n * `private` function that does the actual work.\n */\n modifier nonReentrant() {\n _nonReentrantBefore();\n _;\n _nonReentrantAfter();\n }\n\n function _nonReentrantBefore() private {\n // On the first call to nonReentrant, _status will be _NOT_ENTERED\n require(_status != _ENTERED, \"ReentrancyGuard: reentrant call\");\n\n // Any calls to nonReentrant after this point will fail\n _status = _ENTERED;\n }\n\n function _nonReentrantAfter() private {\n // By storing the original value once again, a refund is triggered (see\n // https://eips.ethereum.org/EIPS/eip-2200)\n _status = _NOT_ENTERED;\n }\n}\n" - }, - "@openzeppelin/contracts/token/ERC1155/IERC1155Receiver.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC1155/IERC1155Receiver.sol)\n\npragma solidity ^0.8.0;\n\nimport \"../../utils/introspection/IERC165.sol\";\n\n/**\n * @dev _Available since v3.1._\n */\ninterface IERC1155Receiver is IERC165 {\n /**\n * @dev Handles the receipt of a single ERC1155 token type. This function is\n * called at the end of a `safeTransferFrom` after the balance has been updated.\n *\n * NOTE: To accept the transfer, this must return\n * `bytes4(keccak256(\"onERC1155Received(address,address,uint256,uint256,bytes)\"))`\n * (i.e. 0xf23a6e61, or its own function selector).\n *\n * @param operator The address which initiated the transfer (i.e. msg.sender)\n * @param from The address which previously owned the token\n * @param id The ID of the token being transferred\n * @param value The amount of tokens being transferred\n * @param data Additional data with no specified format\n * @return `bytes4(keccak256(\"onERC1155Received(address,address,uint256,uint256,bytes)\"))` if transfer is allowed\n */\n function onERC1155Received(\n address operator,\n address from,\n uint256 id,\n uint256 value,\n bytes calldata data\n ) external returns (bytes4);\n\n /**\n * @dev Handles the receipt of a multiple ERC1155 token types. This function\n * is called at the end of a `safeBatchTransferFrom` after the balances have\n * been updated.\n *\n * NOTE: To accept the transfer(s), this must return\n * `bytes4(keccak256(\"onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)\"))`\n * (i.e. 0xbc197c81, or its own function selector).\n *\n * @param operator The address which initiated the batch transfer (i.e. msg.sender)\n * @param from The address which previously owned the token\n * @param ids An array containing ids of each token being transferred (order and length must match values array)\n * @param values An array containing amounts of each token being transferred (order and length must match ids array)\n * @param data Additional data with no specified format\n * @return `bytes4(keccak256(\"onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)\"))` if transfer is allowed\n */\n function onERC1155BatchReceived(\n address operator,\n address from,\n uint256[] calldata ids,\n uint256[] calldata values,\n bytes calldata data\n ) external returns (bytes4);\n}\n" - }, - "@openzeppelin/contracts/token/ERC20/ERC20.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/ERC20.sol)\n\npragma solidity ^0.8.0;\n\nimport \"./IERC20.sol\";\nimport \"./extensions/IERC20Metadata.sol\";\nimport \"../../utils/Context.sol\";\n\n/**\n * @dev Implementation of the {IERC20} interface.\n *\n * This implementation is agnostic to the way tokens are created. This means\n * that a supply mechanism has to be added in a derived contract using {_mint}.\n * For a generic mechanism see {ERC20PresetMinterPauser}.\n *\n * TIP: For a detailed writeup see our guide\n * https://forum.openzeppelin.com/t/how-to-implement-erc20-supply-mechanisms/226[How\n * to implement supply mechanisms].\n *\n * We have followed general OpenZeppelin Contracts guidelines: functions revert\n * instead returning `false` on failure. This behavior is nonetheless\n * conventional and does not conflict with the expectations of ERC20\n * applications.\n *\n * Additionally, an {Approval} event is emitted on calls to {transferFrom}.\n * This allows applications to reconstruct the allowance for all accounts just\n * by listening to said events. Other implementations of the EIP may not emit\n * these events, as it isn't required by the specification.\n *\n * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}\n * functions have been added to mitigate the well-known issues around setting\n * allowances. See {IERC20-approve}.\n */\ncontract ERC20 is Context, IERC20, IERC20Metadata {\n mapping(address => uint256) private _balances;\n\n mapping(address => mapping(address => uint256)) private _allowances;\n\n uint256 private _totalSupply;\n\n string private _name;\n string private _symbol;\n\n /**\n * @dev Sets the values for {name} and {symbol}.\n *\n * The default value of {decimals} is 18. To select a different value for\n * {decimals} you should overload it.\n *\n * All two of these values are immutable: they can only be set once during\n * construction.\n */\n constructor(string memory name_, string memory symbol_) {\n _name = name_;\n _symbol = symbol_;\n }\n\n /**\n * @dev Returns the name of the token.\n */\n function name() public view virtual override returns (string memory) {\n return _name;\n }\n\n /**\n * @dev Returns the symbol of the token, usually a shorter version of the\n * name.\n */\n function symbol() public view virtual override returns (string memory) {\n return _symbol;\n }\n\n /**\n * @dev Returns the number of decimals used to get its user representation.\n * For example, if `decimals` equals `2`, a balance of `505` tokens should\n * be displayed to a user as `5.05` (`505 / 10 ** 2`).\n *\n * Tokens usually opt for a value of 18, imitating the relationship between\n * Ether and Wei. This is the value {ERC20} uses, unless this function is\n * overridden;\n *\n * NOTE: This information is only used for _display_ purposes: it in\n * no way affects any of the arithmetic of the contract, including\n * {IERC20-balanceOf} and {IERC20-transfer}.\n */\n function decimals() public view virtual override returns (uint8) {\n return 18;\n }\n\n /**\n * @dev See {IERC20-totalSupply}.\n */\n function totalSupply() public view virtual override returns (uint256) {\n return _totalSupply;\n }\n\n /**\n * @dev See {IERC20-balanceOf}.\n */\n function balanceOf(address account) public view virtual override returns (uint256) {\n return _balances[account];\n }\n\n /**\n * @dev See {IERC20-transfer}.\n *\n * Requirements:\n *\n * - `to` cannot be the zero address.\n * - the caller must have a balance of at least `amount`.\n */\n function transfer(address to, uint256 amount) public virtual override returns (bool) {\n address owner = _msgSender();\n _transfer(owner, to, amount);\n return true;\n }\n\n /**\n * @dev See {IERC20-allowance}.\n */\n function allowance(address owner, address spender) public view virtual override returns (uint256) {\n return _allowances[owner][spender];\n }\n\n /**\n * @dev See {IERC20-approve}.\n *\n * NOTE: If `amount` is the maximum `uint256`, the allowance is not updated on\n * `transferFrom`. This is semantically equivalent to an infinite approval.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n */\n function approve(address spender, uint256 amount) public virtual override returns (bool) {\n address owner = _msgSender();\n _approve(owner, spender, amount);\n return true;\n }\n\n /**\n * @dev See {IERC20-transferFrom}.\n *\n * Emits an {Approval} event indicating the updated allowance. This is not\n * required by the EIP. See the note at the beginning of {ERC20}.\n *\n * NOTE: Does not update the allowance if the current allowance\n * is the maximum `uint256`.\n *\n * Requirements:\n *\n * - `from` and `to` cannot be the zero address.\n * - `from` must have a balance of at least `amount`.\n * - the caller must have allowance for ``from``'s tokens of at least\n * `amount`.\n */\n function transferFrom(\n address from,\n address to,\n uint256 amount\n ) public virtual override returns (bool) {\n address spender = _msgSender();\n _spendAllowance(from, spender, amount);\n _transfer(from, to, amount);\n return true;\n }\n\n /**\n * @dev Atomically increases the allowance granted to `spender` by the caller.\n *\n * This is an alternative to {approve} that can be used as a mitigation for\n * problems described in {IERC20-approve}.\n *\n * Emits an {Approval} event indicating the updated allowance.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n */\n function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {\n address owner = _msgSender();\n _approve(owner, spender, allowance(owner, spender) + addedValue);\n return true;\n }\n\n /**\n * @dev Atomically decreases the allowance granted to `spender` by the caller.\n *\n * This is an alternative to {approve} that can be used as a mitigation for\n * problems described in {IERC20-approve}.\n *\n * Emits an {Approval} event indicating the updated allowance.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n * - `spender` must have allowance for the caller of at least\n * `subtractedValue`.\n */\n function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {\n address owner = _msgSender();\n uint256 currentAllowance = allowance(owner, spender);\n require(currentAllowance >= subtractedValue, \"ERC20: decreased allowance below zero\");\n unchecked {\n _approve(owner, spender, currentAllowance - subtractedValue);\n }\n\n return true;\n }\n\n /**\n * @dev Moves `amount` of tokens from `from` to `to`.\n *\n * This internal function is equivalent to {transfer}, and can be used to\n * e.g. implement automatic token fees, slashing mechanisms, etc.\n *\n * Emits a {Transfer} event.\n *\n * Requirements:\n *\n * - `from` cannot be the zero address.\n * - `to` cannot be the zero address.\n * - `from` must have a balance of at least `amount`.\n */\n function _transfer(\n address from,\n address to,\n uint256 amount\n ) internal virtual {\n require(from != address(0), \"ERC20: transfer from the zero address\");\n require(to != address(0), \"ERC20: transfer to the zero address\");\n\n _beforeTokenTransfer(from, to, amount);\n\n uint256 fromBalance = _balances[from];\n require(fromBalance >= amount, \"ERC20: transfer amount exceeds balance\");\n unchecked {\n _balances[from] = fromBalance - amount;\n // Overflow not possible: the sum of all balances is capped by totalSupply, and the sum is preserved by\n // decrementing then incrementing.\n _balances[to] += amount;\n }\n\n emit Transfer(from, to, amount);\n\n _afterTokenTransfer(from, to, amount);\n }\n\n /** @dev Creates `amount` tokens and assigns them to `account`, increasing\n * the total supply.\n *\n * Emits a {Transfer} event with `from` set to the zero address.\n *\n * Requirements:\n *\n * - `account` cannot be the zero address.\n */\n function _mint(address account, uint256 amount) internal virtual {\n require(account != address(0), \"ERC20: mint to the zero address\");\n\n _beforeTokenTransfer(address(0), account, amount);\n\n _totalSupply += amount;\n unchecked {\n // Overflow not possible: balance + amount is at most totalSupply + amount, which is checked above.\n _balances[account] += amount;\n }\n emit Transfer(address(0), account, amount);\n\n _afterTokenTransfer(address(0), account, amount);\n }\n\n /**\n * @dev Destroys `amount` tokens from `account`, reducing the\n * total supply.\n *\n * Emits a {Transfer} event with `to` set to the zero address.\n *\n * Requirements:\n *\n * - `account` cannot be the zero address.\n * - `account` must have at least `amount` tokens.\n */\n function _burn(address account, uint256 amount) internal virtual {\n require(account != address(0), \"ERC20: burn from the zero address\");\n\n _beforeTokenTransfer(account, address(0), amount);\n\n uint256 accountBalance = _balances[account];\n require(accountBalance >= amount, \"ERC20: burn amount exceeds balance\");\n unchecked {\n _balances[account] = accountBalance - amount;\n // Overflow not possible: amount <= accountBalance <= totalSupply.\n _totalSupply -= amount;\n }\n\n emit Transfer(account, address(0), amount);\n\n _afterTokenTransfer(account, address(0), amount);\n }\n\n /**\n * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.\n *\n * This internal function is equivalent to `approve`, and can be used to\n * e.g. set automatic allowances for certain subsystems, etc.\n *\n * Emits an {Approval} event.\n *\n * Requirements:\n *\n * - `owner` cannot be the zero address.\n * - `spender` cannot be the zero address.\n */\n function _approve(\n address owner,\n address spender,\n uint256 amount\n ) internal virtual {\n require(owner != address(0), \"ERC20: approve from the zero address\");\n require(spender != address(0), \"ERC20: approve to the zero address\");\n\n _allowances[owner][spender] = amount;\n emit Approval(owner, spender, amount);\n }\n\n /**\n * @dev Updates `owner` s allowance for `spender` based on spent `amount`.\n *\n * Does not update the allowance amount in case of infinite allowance.\n * Revert if not enough allowance is available.\n *\n * Might emit an {Approval} event.\n */\n function _spendAllowance(\n address owner,\n address spender,\n uint256 amount\n ) internal virtual {\n uint256 currentAllowance = allowance(owner, spender);\n if (currentAllowance != type(uint256).max) {\n require(currentAllowance >= amount, \"ERC20: insufficient allowance\");\n unchecked {\n _approve(owner, spender, currentAllowance - amount);\n }\n }\n }\n\n /**\n * @dev Hook that is called before any transfer of tokens. This includes\n * minting and burning.\n *\n * Calling conditions:\n *\n * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens\n * will be transferred to `to`.\n * - when `from` is zero, `amount` tokens will be minted for `to`.\n * - when `to` is zero, `amount` of ``from``'s tokens will be burned.\n * - `from` and `to` are never both zero.\n *\n * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].\n */\n function _beforeTokenTransfer(\n address from,\n address to,\n uint256 amount\n ) internal virtual {}\n\n /**\n * @dev Hook that is called after any transfer of tokens. This includes\n * minting and burning.\n *\n * Calling conditions:\n *\n * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens\n * has been transferred to `to`.\n * - when `from` is zero, `amount` tokens have been minted for `to`.\n * - when `to` is zero, `amount` of ``from``'s tokens have been burned.\n * - `from` and `to` are never both zero.\n *\n * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].\n */\n function _afterTokenTransfer(\n address from,\n address to,\n uint256 amount\n ) internal virtual {}\n}\n" - }, - "@openzeppelin/contracts/token/ERC20/extensions/draft-IERC20Permit.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/draft-IERC20Permit.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in\n * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].\n *\n * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by\n * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't\n * need to send a transaction, and thus is not required to hold Ether at all.\n */\ninterface IERC20Permit {\n /**\n * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens,\n * given ``owner``'s signed approval.\n *\n * IMPORTANT: The same issues {IERC20-approve} has related to transaction\n * ordering also apply here.\n *\n * Emits an {Approval} event.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n * - `deadline` must be a timestamp in the future.\n * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner`\n * over the EIP712-formatted function arguments.\n * - the signature must use ``owner``'s current nonce (see {nonces}).\n *\n * For more information on the signature format, see the\n * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP\n * section].\n */\n function permit(\n address owner,\n address spender,\n uint256 value,\n uint256 deadline,\n uint8 v,\n bytes32 r,\n bytes32 s\n ) external;\n\n /**\n * @dev Returns the current nonce for `owner`. This value must be\n * included whenever a signature is generated for {permit}.\n *\n * Every successful call to {permit} increases ``owner``'s nonce by one. This\n * prevents a signature from being used multiple times.\n */\n function nonces(address owner) external view returns (uint256);\n\n /**\n * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}.\n */\n // solhint-disable-next-line func-name-mixedcase\n function DOMAIN_SEPARATOR() external view returns (bytes32);\n}\n" - }, - "@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol)\n\npragma solidity ^0.8.0;\n\nimport \"../IERC20.sol\";\n\n/**\n * @dev Interface for the optional metadata functions from the ERC20 standard.\n *\n * _Available since v4.1._\n */\ninterface IERC20Metadata is IERC20 {\n /**\n * @dev Returns the name of the token.\n */\n function name() external view returns (string memory);\n\n /**\n * @dev Returns the symbol of the token.\n */\n function symbol() external view returns (string memory);\n\n /**\n * @dev Returns the decimals places of the token.\n */\n function decimals() external view returns (uint8);\n}\n" - }, - "@openzeppelin/contracts/token/ERC20/IERC20.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Interface of the ERC20 standard as defined in the EIP.\n */\ninterface IERC20 {\n /**\n * @dev Emitted when `value` tokens are moved from one account (`from`) to\n * another (`to`).\n *\n * Note that `value` may be zero.\n */\n event Transfer(address indexed from, address indexed to, uint256 value);\n\n /**\n * @dev Emitted when the allowance of a `spender` for an `owner` is set by\n * a call to {approve}. `value` is the new allowance.\n */\n event Approval(address indexed owner, address indexed spender, uint256 value);\n\n /**\n * @dev Returns the amount of tokens in existence.\n */\n function totalSupply() external view returns (uint256);\n\n /**\n * @dev Returns the amount of tokens owned by `account`.\n */\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * @dev Moves `amount` tokens from the caller's account to `to`.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n * Emits a {Transfer} event.\n */\n function transfer(address to, uint256 amount) external returns (bool);\n\n /**\n * @dev Returns the remaining number of tokens that `spender` will be\n * allowed to spend on behalf of `owner` through {transferFrom}. This is\n * zero by default.\n *\n * This value changes when {approve} or {transferFrom} are called.\n */\n function allowance(address owner, address spender) external view returns (uint256);\n\n /**\n * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n * IMPORTANT: Beware that changing an allowance with this method brings the risk\n * that someone may use both the old and the new allowance by unfortunate\n * transaction ordering. One possible solution to mitigate this race\n * condition is to first reduce the spender's allowance to 0 and set the\n * desired value afterwards:\n * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729\n *\n * Emits an {Approval} event.\n */\n function approve(address spender, uint256 amount) external returns (bool);\n\n /**\n * @dev Moves `amount` tokens from `from` to `to` using the\n * allowance mechanism. `amount` is then deducted from the caller's\n * allowance.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n * Emits a {Transfer} event.\n */\n function transferFrom(\n address from,\n address to,\n uint256 amount\n ) external returns (bool);\n}\n" - }, - "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/utils/SafeERC20.sol)\n\npragma solidity ^0.8.0;\n\nimport \"../IERC20.sol\";\nimport \"../extensions/draft-IERC20Permit.sol\";\nimport \"../../../utils/Address.sol\";\n\n/**\n * @title SafeERC20\n * @dev Wrappers around ERC20 operations that throw on failure (when the token\n * contract returns false). Tokens that return no value (and instead revert or\n * throw on failure) are also supported, non-reverting calls are assumed to be\n * successful.\n * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,\n * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.\n */\nlibrary SafeERC20 {\n using Address for address;\n\n function safeTransfer(\n IERC20 token,\n address to,\n uint256 value\n ) internal {\n _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));\n }\n\n function safeTransferFrom(\n IERC20 token,\n address from,\n address to,\n uint256 value\n ) internal {\n _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));\n }\n\n /**\n * @dev Deprecated. This function has issues similar to the ones found in\n * {IERC20-approve}, and its usage is discouraged.\n *\n * Whenever possible, use {safeIncreaseAllowance} and\n * {safeDecreaseAllowance} instead.\n */\n function safeApprove(\n IERC20 token,\n address spender,\n uint256 value\n ) internal {\n // safeApprove should only be called when setting an initial allowance,\n // or when resetting it to zero. To increase and decrease it, use\n // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'\n require(\n (value == 0) || (token.allowance(address(this), spender) == 0),\n \"SafeERC20: approve from non-zero to non-zero allowance\"\n );\n _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));\n }\n\n function safeIncreaseAllowance(\n IERC20 token,\n address spender,\n uint256 value\n ) internal {\n uint256 newAllowance = token.allowance(address(this), spender) + value;\n _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));\n }\n\n function safeDecreaseAllowance(\n IERC20 token,\n address spender,\n uint256 value\n ) internal {\n unchecked {\n uint256 oldAllowance = token.allowance(address(this), spender);\n require(oldAllowance >= value, \"SafeERC20: decreased allowance below zero\");\n uint256 newAllowance = oldAllowance - value;\n _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));\n }\n }\n\n function safePermit(\n IERC20Permit token,\n address owner,\n address spender,\n uint256 value,\n uint256 deadline,\n uint8 v,\n bytes32 r,\n bytes32 s\n ) internal {\n uint256 nonceBefore = token.nonces(owner);\n token.permit(owner, spender, value, deadline, v, r, s);\n uint256 nonceAfter = token.nonces(owner);\n require(nonceAfter == nonceBefore + 1, \"SafeERC20: permit did not succeed\");\n }\n\n /**\n * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement\n * on the return value: the return value is optional (but if data is returned, it must not be false).\n * @param token The token targeted by the call.\n * @param data The call data (encoded using abi.encode or one of its variants).\n */\n function _callOptionalReturn(IERC20 token, bytes memory data) private {\n // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since\n // we're implementing it ourselves. We use {Address-functionCall} to perform this call, which verifies that\n // the target address contains contract code and also asserts for success in the low-level call.\n\n bytes memory returndata = address(token).functionCall(data, \"SafeERC20: low-level call failed\");\n if (returndata.length > 0) {\n // Return data is optional\n require(abi.decode(returndata, (bool)), \"SafeERC20: ERC20 operation did not succeed\");\n }\n }\n}\n" - }, - "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @title ERC721 token receiver interface\n * @dev Interface for any contract that wants to support safeTransfers\n * from ERC721 asset contracts.\n */\ninterface IERC721Receiver {\n /**\n * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}\n * by `operator` from `from`, this function is called.\n *\n * It must return its Solidity selector to confirm the token transfer.\n * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.\n *\n * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`.\n */\n function onERC721Received(\n address operator,\n address from,\n uint256 tokenId,\n bytes calldata data\n ) external returns (bytes4);\n}\n" - }, - "@openzeppelin/contracts/token/ERC777/IERC777Recipient.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts v4.4.1 (token/ERC777/IERC777Recipient.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Interface of the ERC777TokensRecipient standard as defined in the EIP.\n *\n * Accounts can be notified of {IERC777} tokens being sent to them by having a\n * contract implement this interface (contract holders can be their own\n * implementer) and registering it on the\n * https://eips.ethereum.org/EIPS/eip-1820[ERC1820 global registry].\n *\n * See {IERC1820Registry} and {ERC1820Implementer}.\n */\ninterface IERC777Recipient {\n /**\n * @dev Called by an {IERC777} token contract whenever tokens are being\n * moved or created into a registered account (`to`). The type of operation\n * is conveyed by `from` being the zero address or not.\n *\n * This call occurs _after_ the token contract's state is updated, so\n * {IERC777-balanceOf}, etc., can be used to query the post-operation state.\n *\n * This function may revert to prevent the operation from being executed.\n */\n function tokensReceived(\n address operator,\n address from,\n address to,\n uint256 amount,\n bytes calldata userData,\n bytes calldata operatorData\n ) external;\n}\n" - }, - "@openzeppelin/contracts/utils/Address.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/Address.sol)\n\npragma solidity ^0.8.1;\n\n/**\n * @dev Collection of functions related to the address type\n */\nlibrary Address {\n /**\n * @dev Returns true if `account` is a contract.\n *\n * [IMPORTANT]\n * ====\n * It is unsafe to assume that an address for which this function returns\n * false is an externally-owned account (EOA) and not a contract.\n *\n * Among others, `isContract` will return false for the following\n * types of addresses:\n *\n * - an externally-owned account\n * - a contract in construction\n * - an address where a contract will be created\n * - an address where a contract lived, but was destroyed\n * ====\n *\n * [IMPORTANT]\n * ====\n * You shouldn't rely on `isContract` to protect against flash loan attacks!\n *\n * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets\n * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract\n * constructor.\n * ====\n */\n function isContract(address account) internal view returns (bool) {\n // This method relies on extcodesize/address.code.length, which returns 0\n // for contracts in construction, since the code is only stored at the end\n // of the constructor execution.\n\n return account.code.length > 0;\n }\n\n /**\n * @dev Replacement for Solidity's `transfer`: sends `amount` wei to\n * `recipient`, forwarding all available gas and reverting on errors.\n *\n * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost\n * of certain opcodes, possibly making contracts go over the 2300 gas limit\n * imposed by `transfer`, making them unable to receive funds via\n * `transfer`. {sendValue} removes this limitation.\n *\n * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].\n *\n * IMPORTANT: because control is transferred to `recipient`, care must be\n * taken to not create reentrancy vulnerabilities. Consider using\n * {ReentrancyGuard} or the\n * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].\n */\n function sendValue(address payable recipient, uint256 amount) internal {\n require(address(this).balance >= amount, \"Address: insufficient balance\");\n\n (bool success, ) = recipient.call{value: amount}(\"\");\n require(success, \"Address: unable to send value, recipient may have reverted\");\n }\n\n /**\n * @dev Performs a Solidity function call using a low level `call`. A\n * plain `call` is an unsafe replacement for a function call: use this\n * function instead.\n *\n * If `target` reverts with a revert reason, it is bubbled up by this\n * function (like regular Solidity function calls).\n *\n * Returns the raw returned data. To convert to the expected return value,\n * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].\n *\n * Requirements:\n *\n * - `target` must be a contract.\n * - calling `target` with `data` must not revert.\n *\n * _Available since v3.1._\n */\n function functionCall(address target, bytes memory data) internal returns (bytes memory) {\n return functionCallWithValue(target, data, 0, \"Address: low-level call failed\");\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with\n * `errorMessage` as a fallback revert reason when `target` reverts.\n *\n * _Available since v3.1._\n */\n function functionCall(\n address target,\n bytes memory data,\n string memory errorMessage\n ) internal returns (bytes memory) {\n return functionCallWithValue(target, data, 0, errorMessage);\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n * but also transferring `value` wei to `target`.\n *\n * Requirements:\n *\n * - the calling contract must have an ETH balance of at least `value`.\n * - the called Solidity function must be `payable`.\n *\n * _Available since v3.1._\n */\n function functionCallWithValue(\n address target,\n bytes memory data,\n uint256 value\n ) internal returns (bytes memory) {\n return functionCallWithValue(target, data, value, \"Address: low-level call with value failed\");\n }\n\n /**\n * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but\n * with `errorMessage` as a fallback revert reason when `target` reverts.\n *\n * _Available since v3.1._\n */\n function functionCallWithValue(\n address target,\n bytes memory data,\n uint256 value,\n string memory errorMessage\n ) internal returns (bytes memory) {\n require(address(this).balance >= value, \"Address: insufficient balance for call\");\n (bool success, bytes memory returndata) = target.call{value: value}(data);\n return verifyCallResultFromTarget(target, success, returndata, errorMessage);\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n * but performing a static call.\n *\n * _Available since v3.3._\n */\n function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {\n return functionStaticCall(target, data, \"Address: low-level static call failed\");\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\n * but performing a static call.\n *\n * _Available since v3.3._\n */\n function functionStaticCall(\n address target,\n bytes memory data,\n string memory errorMessage\n ) internal view returns (bytes memory) {\n (bool success, bytes memory returndata) = target.staticcall(data);\n return verifyCallResultFromTarget(target, success, returndata, errorMessage);\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n * but performing a delegate call.\n *\n * _Available since v3.4._\n */\n function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {\n return functionDelegateCall(target, data, \"Address: low-level delegate call failed\");\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\n * but performing a delegate call.\n *\n * _Available since v3.4._\n */\n function functionDelegateCall(\n address target,\n bytes memory data,\n string memory errorMessage\n ) internal returns (bytes memory) {\n (bool success, bytes memory returndata) = target.delegatecall(data);\n return verifyCallResultFromTarget(target, success, returndata, errorMessage);\n }\n\n /**\n * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling\n * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.\n *\n * _Available since v4.8._\n */\n function verifyCallResultFromTarget(\n address target,\n bool success,\n bytes memory returndata,\n string memory errorMessage\n ) internal view returns (bytes memory) {\n if (success) {\n if (returndata.length == 0) {\n // only check isContract if the call was successful and the return data is empty\n // otherwise we already know that it was a contract\n require(isContract(target), \"Address: call to non-contract\");\n }\n return returndata;\n } else {\n _revert(returndata, errorMessage);\n }\n }\n\n /**\n * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the\n * revert reason or using the provided one.\n *\n * _Available since v4.3._\n */\n function verifyCallResult(\n bool success,\n bytes memory returndata,\n string memory errorMessage\n ) internal pure returns (bytes memory) {\n if (success) {\n return returndata;\n } else {\n _revert(returndata, errorMessage);\n }\n }\n\n function _revert(bytes memory returndata, string memory errorMessage) private pure {\n // Look for revert reason and bubble it up if present\n if (returndata.length > 0) {\n // The easiest way to bubble the revert reason is using memory via assembly\n /// @solidity memory-safe-assembly\n assembly {\n let returndata_size := mload(returndata)\n revert(add(32, returndata), returndata_size)\n }\n } else {\n revert(errorMessage);\n }\n }\n}\n" - }, - "@openzeppelin/contracts/utils/Context.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Provides information about the current execution context, including the\n * sender of the transaction and its data. While these are generally available\n * via msg.sender and msg.data, they should not be accessed in such a direct\n * manner, since when dealing with meta-transactions the account sending and\n * paying for execution may not be the actual sender (as far as an application\n * is concerned).\n *\n * This contract is only required for intermediate, library-like contracts.\n */\nabstract contract Context {\n function _msgSender() internal view virtual returns (address) {\n return msg.sender;\n }\n\n function _msgData() internal view virtual returns (bytes calldata) {\n return msg.data;\n }\n}\n" - }, - "@openzeppelin/contracts/utils/Create2.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/Create2.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Helper to make usage of the `CREATE2` EVM opcode easier and safer.\n * `CREATE2` can be used to compute in advance the address where a smart\n * contract will be deployed, which allows for interesting new mechanisms known\n * as 'counterfactual interactions'.\n *\n * See the https://eips.ethereum.org/EIPS/eip-1014#motivation[EIP] for more\n * information.\n */\nlibrary Create2 {\n /**\n * @dev Deploys a contract using `CREATE2`. The address where the contract\n * will be deployed can be known in advance via {computeAddress}.\n *\n * The bytecode for a contract can be obtained from Solidity with\n * `type(contractName).creationCode`.\n *\n * Requirements:\n *\n * - `bytecode` must not be empty.\n * - `salt` must have not been used for `bytecode` already.\n * - the factory must have a balance of at least `amount`.\n * - if `amount` is non-zero, `bytecode` must have a `payable` constructor.\n */\n function deploy(\n uint256 amount,\n bytes32 salt,\n bytes memory bytecode\n ) internal returns (address addr) {\n require(address(this).balance >= amount, \"Create2: insufficient balance\");\n require(bytecode.length != 0, \"Create2: bytecode length is zero\");\n /// @solidity memory-safe-assembly\n assembly {\n addr := create2(amount, add(bytecode, 0x20), mload(bytecode), salt)\n }\n require(addr != address(0), \"Create2: Failed on deploy\");\n }\n\n /**\n * @dev Returns the address where a contract will be stored if deployed via {deploy}. Any change in the\n * `bytecodeHash` or `salt` will result in a new destination address.\n */\n function computeAddress(bytes32 salt, bytes32 bytecodeHash) internal view returns (address) {\n return computeAddress(salt, bytecodeHash, address(this));\n }\n\n /**\n * @dev Returns the address where a contract will be stored if deployed via {deploy} from a contract located at\n * `deployer`. If `deployer` is this contract's address, returns the same value as {computeAddress}.\n */\n function computeAddress(\n bytes32 salt,\n bytes32 bytecodeHash,\n address deployer\n ) internal pure returns (address addr) {\n /// @solidity memory-safe-assembly\n assembly {\n let ptr := mload(0x40) // Get free memory pointer\n\n // | | ↓ ptr ... ↓ ptr + 0x0B (start) ... ↓ ptr + 0x20 ... ↓ ptr + 0x40 ... |\n // |-------------------|---------------------------------------------------------------------------|\n // | bytecodeHash | CCCCCCCCCCCCC...CC |\n // | salt | BBBBBBBBBBBBB...BB |\n // | deployer | 000000...0000AAAAAAAAAAAAAAAAAAA...AA |\n // | 0xFF | FF |\n // |-------------------|---------------------------------------------------------------------------|\n // | memory | 000000...00FFAAAAAAAAAAAAAAAAAAA...AABBBBBBBBBBBBB...BBCCCCCCCCCCCCC...CC |\n // | keccak(start, 85) | ↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑ |\n\n mstore(add(ptr, 0x40), bytecodeHash)\n mstore(add(ptr, 0x20), salt)\n mstore(ptr, deployer) // Right-aligned with 12 preceding garbage bytes\n let start := add(ptr, 0x0b) // The hashed data starts at the final garbage byte which we will set to 0xff\n mstore8(start, 0xff)\n addr := keccak256(start, 85)\n }\n }\n}\n" - }, - "@openzeppelin/contracts/utils/cryptography/ECDSA.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/ECDSA.sol)\n\npragma solidity ^0.8.0;\n\nimport \"../Strings.sol\";\n\n/**\n * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations.\n *\n * These functions can be used to verify that a message was signed by the holder\n * of the private keys of a given address.\n */\nlibrary ECDSA {\n enum RecoverError {\n NoError,\n InvalidSignature,\n InvalidSignatureLength,\n InvalidSignatureS,\n InvalidSignatureV // Deprecated in v4.8\n }\n\n function _throwError(RecoverError error) private pure {\n if (error == RecoverError.NoError) {\n return; // no error: do nothing\n } else if (error == RecoverError.InvalidSignature) {\n revert(\"ECDSA: invalid signature\");\n } else if (error == RecoverError.InvalidSignatureLength) {\n revert(\"ECDSA: invalid signature length\");\n } else if (error == RecoverError.InvalidSignatureS) {\n revert(\"ECDSA: invalid signature 's' value\");\n }\n }\n\n /**\n * @dev Returns the address that signed a hashed message (`hash`) with\n * `signature` or error string. This address can then be used for verification purposes.\n *\n * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:\n * this function rejects them by requiring the `s` value to be in the lower\n * half order, and the `v` value to be either 27 or 28.\n *\n * IMPORTANT: `hash` _must_ be the result of a hash operation for the\n * verification to be secure: it is possible to craft signatures that\n * recover to arbitrary addresses for non-hashed data. A safe way to ensure\n * this is by receiving a hash of the original message (which may otherwise\n * be too long), and then calling {toEthSignedMessageHash} on it.\n *\n * Documentation for signature generation:\n * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js]\n * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers]\n *\n * _Available since v4.3._\n */\n function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) {\n if (signature.length == 65) {\n bytes32 r;\n bytes32 s;\n uint8 v;\n // ecrecover takes the signature parameters, and the only way to get them\n // currently is to use assembly.\n /// @solidity memory-safe-assembly\n assembly {\n r := mload(add(signature, 0x20))\n s := mload(add(signature, 0x40))\n v := byte(0, mload(add(signature, 0x60)))\n }\n return tryRecover(hash, v, r, s);\n } else {\n return (address(0), RecoverError.InvalidSignatureLength);\n }\n }\n\n /**\n * @dev Returns the address that signed a hashed message (`hash`) with\n * `signature`. This address can then be used for verification purposes.\n *\n * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:\n * this function rejects them by requiring the `s` value to be in the lower\n * half order, and the `v` value to be either 27 or 28.\n *\n * IMPORTANT: `hash` _must_ be the result of a hash operation for the\n * verification to be secure: it is possible to craft signatures that\n * recover to arbitrary addresses for non-hashed data. A safe way to ensure\n * this is by receiving a hash of the original message (which may otherwise\n * be too long), and then calling {toEthSignedMessageHash} on it.\n */\n function recover(bytes32 hash, bytes memory signature) internal pure returns (address) {\n (address recovered, RecoverError error) = tryRecover(hash, signature);\n _throwError(error);\n return recovered;\n }\n\n /**\n * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately.\n *\n * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures]\n *\n * _Available since v4.3._\n */\n function tryRecover(\n bytes32 hash,\n bytes32 r,\n bytes32 vs\n ) internal pure returns (address, RecoverError) {\n bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff);\n uint8 v = uint8((uint256(vs) >> 255) + 27);\n return tryRecover(hash, v, r, s);\n }\n\n /**\n * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately.\n *\n * _Available since v4.2._\n */\n function recover(\n bytes32 hash,\n bytes32 r,\n bytes32 vs\n ) internal pure returns (address) {\n (address recovered, RecoverError error) = tryRecover(hash, r, vs);\n _throwError(error);\n return recovered;\n }\n\n /**\n * @dev Overload of {ECDSA-tryRecover} that receives the `v`,\n * `r` and `s` signature fields separately.\n *\n * _Available since v4.3._\n */\n function tryRecover(\n bytes32 hash,\n uint8 v,\n bytes32 r,\n bytes32 s\n ) internal pure returns (address, RecoverError) {\n // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature\n // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines\n // the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most\n // signatures from current libraries generate a unique signature with an s-value in the lower half order.\n //\n // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value\n // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or\n // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept\n // these malleable signatures as well.\n if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) {\n return (address(0), RecoverError.InvalidSignatureS);\n }\n\n // If the signature is valid (and not malleable), return the signer address\n address signer = ecrecover(hash, v, r, s);\n if (signer == address(0)) {\n return (address(0), RecoverError.InvalidSignature);\n }\n\n return (signer, RecoverError.NoError);\n }\n\n /**\n * @dev Overload of {ECDSA-recover} that receives the `v`,\n * `r` and `s` signature fields separately.\n */\n function recover(\n bytes32 hash,\n uint8 v,\n bytes32 r,\n bytes32 s\n ) internal pure returns (address) {\n (address recovered, RecoverError error) = tryRecover(hash, v, r, s);\n _throwError(error);\n return recovered;\n }\n\n /**\n * @dev Returns an Ethereum Signed Message, created from a `hash`. This\n * produces hash corresponding to the one signed with the\n * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]\n * JSON-RPC method as part of EIP-191.\n *\n * See {recover}.\n */\n function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) {\n // 32 is the length in bytes of hash,\n // enforced by the type signature above\n return keccak256(abi.encodePacked(\"\\x19Ethereum Signed Message:\\n32\", hash));\n }\n\n /**\n * @dev Returns an Ethereum Signed Message, created from `s`. This\n * produces hash corresponding to the one signed with the\n * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]\n * JSON-RPC method as part of EIP-191.\n *\n * See {recover}.\n */\n function toEthSignedMessageHash(bytes memory s) internal pure returns (bytes32) {\n return keccak256(abi.encodePacked(\"\\x19Ethereum Signed Message:\\n\", Strings.toString(s.length), s));\n }\n\n /**\n * @dev Returns an Ethereum Signed Typed Data, created from a\n * `domainSeparator` and a `structHash`. This produces hash corresponding\n * to the one signed with the\n * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`]\n * JSON-RPC method as part of EIP-712.\n *\n * See {recover}.\n */\n function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) {\n return keccak256(abi.encodePacked(\"\\x19\\x01\", domainSeparator, structHash));\n }\n}\n" - }, - "@openzeppelin/contracts/utils/introspection/IERC165.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Interface of the ERC165 standard, as defined in the\n * https://eips.ethereum.org/EIPS/eip-165[EIP].\n *\n * Implementers can declare support of contract interfaces, which can then be\n * queried by others ({ERC165Checker}).\n *\n * For an implementation, see {ERC165}.\n */\ninterface IERC165 {\n /**\n * @dev Returns true if this contract implements the interface defined by\n * `interfaceId`. See the corresponding\n * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]\n * to learn more about how these ids are created.\n *\n * This function call must use less than 30 000 gas.\n */\n function supportsInterface(bytes4 interfaceId) external view returns (bool);\n}\n" - }, - "@openzeppelin/contracts/utils/math/Math.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/Math.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Standard math utilities missing in the Solidity language.\n */\nlibrary Math {\n enum Rounding {\n Down, // Toward negative infinity\n Up, // Toward infinity\n Zero // Toward zero\n }\n\n /**\n * @dev Returns the largest of two numbers.\n */\n function max(uint256 a, uint256 b) internal pure returns (uint256) {\n return a > b ? a : b;\n }\n\n /**\n * @dev Returns the smallest of two numbers.\n */\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n\n /**\n * @dev Returns the average of two numbers. The result is rounded towards\n * zero.\n */\n function average(uint256 a, uint256 b) internal pure returns (uint256) {\n // (a + b) / 2 can overflow.\n return (a & b) + (a ^ b) / 2;\n }\n\n /**\n * @dev Returns the ceiling of the division of two numbers.\n *\n * This differs from standard division with `/` in that it rounds up instead\n * of rounding down.\n */\n function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {\n // (a + b - 1) / b can overflow on addition, so we distribute.\n return a == 0 ? 0 : (a - 1) / b + 1;\n }\n\n /**\n * @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or denominator == 0\n * @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv)\n * with further edits by Uniswap Labs also under MIT license.\n */\n function mulDiv(\n uint256 x,\n uint256 y,\n uint256 denominator\n ) internal pure returns (uint256 result) {\n unchecked {\n // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use\n // use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256\n // variables such that product = prod1 * 2^256 + prod0.\n uint256 prod0; // Least significant 256 bits of the product\n uint256 prod1; // Most significant 256 bits of the product\n assembly {\n let mm := mulmod(x, y, not(0))\n prod0 := mul(x, y)\n prod1 := sub(sub(mm, prod0), lt(mm, prod0))\n }\n\n // Handle non-overflow cases, 256 by 256 division.\n if (prod1 == 0) {\n return prod0 / denominator;\n }\n\n // Make sure the result is less than 2^256. Also prevents denominator == 0.\n require(denominator > prod1);\n\n ///////////////////////////////////////////////\n // 512 by 256 division.\n ///////////////////////////////////////////////\n\n // Make division exact by subtracting the remainder from [prod1 prod0].\n uint256 remainder;\n assembly {\n // Compute remainder using mulmod.\n remainder := mulmod(x, y, denominator)\n\n // Subtract 256 bit number from 512 bit number.\n prod1 := sub(prod1, gt(remainder, prod0))\n prod0 := sub(prod0, remainder)\n }\n\n // Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1.\n // See https://cs.stackexchange.com/q/138556/92363.\n\n // Does not overflow because the denominator cannot be zero at this stage in the function.\n uint256 twos = denominator & (~denominator + 1);\n assembly {\n // Divide denominator by twos.\n denominator := div(denominator, twos)\n\n // Divide [prod1 prod0] by twos.\n prod0 := div(prod0, twos)\n\n // Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one.\n twos := add(div(sub(0, twos), twos), 1)\n }\n\n // Shift in bits from prod1 into prod0.\n prod0 |= prod1 * twos;\n\n // Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such\n // that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for\n // four bits. That is, denominator * inv = 1 mod 2^4.\n uint256 inverse = (3 * denominator) ^ 2;\n\n // Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also works\n // in modular arithmetic, doubling the correct bits in each step.\n inverse *= 2 - denominator * inverse; // inverse mod 2^8\n inverse *= 2 - denominator * inverse; // inverse mod 2^16\n inverse *= 2 - denominator * inverse; // inverse mod 2^32\n inverse *= 2 - denominator * inverse; // inverse mod 2^64\n inverse *= 2 - denominator * inverse; // inverse mod 2^128\n inverse *= 2 - denominator * inverse; // inverse mod 2^256\n\n // Because the division is now exact we can divide by multiplying with the modular inverse of denominator.\n // This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is\n // less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1\n // is no longer required.\n result = prod0 * inverse;\n return result;\n }\n }\n\n /**\n * @notice Calculates x * y / denominator with full precision, following the selected rounding direction.\n */\n function mulDiv(\n uint256 x,\n uint256 y,\n uint256 denominator,\n Rounding rounding\n ) internal pure returns (uint256) {\n uint256 result = mulDiv(x, y, denominator);\n if (rounding == Rounding.Up && mulmod(x, y, denominator) > 0) {\n result += 1;\n }\n return result;\n }\n\n /**\n * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded down.\n *\n * Inspired by Henry S. Warren, Jr.'s \"Hacker's Delight\" (Chapter 11).\n */\n function sqrt(uint256 a) internal pure returns (uint256) {\n if (a == 0) {\n return 0;\n }\n\n // For our first guess, we get the biggest power of 2 which is smaller than the square root of the target.\n //\n // We know that the \"msb\" (most significant bit) of our target number `a` is a power of 2 such that we have\n // `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`.\n //\n // This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)`\n // → `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))`\n // → `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)`\n //\n // Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit.\n uint256 result = 1 << (log2(a) >> 1);\n\n // At this point `result` is an estimation with one bit of precision. We know the true value is a uint128,\n // since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at\n // every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision\n // into the expected uint128 result.\n unchecked {\n result = (result + a / result) >> 1;\n result = (result + a / result) >> 1;\n result = (result + a / result) >> 1;\n result = (result + a / result) >> 1;\n result = (result + a / result) >> 1;\n result = (result + a / result) >> 1;\n result = (result + a / result) >> 1;\n return min(result, a / result);\n }\n }\n\n /**\n * @notice Calculates sqrt(a), following the selected rounding direction.\n */\n function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) {\n unchecked {\n uint256 result = sqrt(a);\n return result + (rounding == Rounding.Up && result * result < a ? 1 : 0);\n }\n }\n\n /**\n * @dev Return the log in base 2, rounded down, of a positive value.\n * Returns 0 if given 0.\n */\n function log2(uint256 value) internal pure returns (uint256) {\n uint256 result = 0;\n unchecked {\n if (value >> 128 > 0) {\n value >>= 128;\n result += 128;\n }\n if (value >> 64 > 0) {\n value >>= 64;\n result += 64;\n }\n if (value >> 32 > 0) {\n value >>= 32;\n result += 32;\n }\n if (value >> 16 > 0) {\n value >>= 16;\n result += 16;\n }\n if (value >> 8 > 0) {\n value >>= 8;\n result += 8;\n }\n if (value >> 4 > 0) {\n value >>= 4;\n result += 4;\n }\n if (value >> 2 > 0) {\n value >>= 2;\n result += 2;\n }\n if (value >> 1 > 0) {\n result += 1;\n }\n }\n return result;\n }\n\n /**\n * @dev Return the log in base 2, following the selected rounding direction, of a positive value.\n * Returns 0 if given 0.\n */\n function log2(uint256 value, Rounding rounding) internal pure returns (uint256) {\n unchecked {\n uint256 result = log2(value);\n return result + (rounding == Rounding.Up && 1 << result < value ? 1 : 0);\n }\n }\n\n /**\n * @dev Return the log in base 10, rounded down, of a positive value.\n * Returns 0 if given 0.\n */\n function log10(uint256 value) internal pure returns (uint256) {\n uint256 result = 0;\n unchecked {\n if (value >= 10**64) {\n value /= 10**64;\n result += 64;\n }\n if (value >= 10**32) {\n value /= 10**32;\n result += 32;\n }\n if (value >= 10**16) {\n value /= 10**16;\n result += 16;\n }\n if (value >= 10**8) {\n value /= 10**8;\n result += 8;\n }\n if (value >= 10**4) {\n value /= 10**4;\n result += 4;\n }\n if (value >= 10**2) {\n value /= 10**2;\n result += 2;\n }\n if (value >= 10**1) {\n result += 1;\n }\n }\n return result;\n }\n\n /**\n * @dev Return the log in base 10, following the selected rounding direction, of a positive value.\n * Returns 0 if given 0.\n */\n function log10(uint256 value, Rounding rounding) internal pure returns (uint256) {\n unchecked {\n uint256 result = log10(value);\n return result + (rounding == Rounding.Up && 10**result < value ? 1 : 0);\n }\n }\n\n /**\n * @dev Return the log in base 256, rounded down, of a positive value.\n * Returns 0 if given 0.\n *\n * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string.\n */\n function log256(uint256 value) internal pure returns (uint256) {\n uint256 result = 0;\n unchecked {\n if (value >> 128 > 0) {\n value >>= 128;\n result += 16;\n }\n if (value >> 64 > 0) {\n value >>= 64;\n result += 8;\n }\n if (value >> 32 > 0) {\n value >>= 32;\n result += 4;\n }\n if (value >> 16 > 0) {\n value >>= 16;\n result += 2;\n }\n if (value >> 8 > 0) {\n result += 1;\n }\n }\n return result;\n }\n\n /**\n * @dev Return the log in base 10, following the selected rounding direction, of a positive value.\n * Returns 0 if given 0.\n */\n function log256(uint256 value, Rounding rounding) internal pure returns (uint256) {\n unchecked {\n uint256 result = log256(value);\n return result + (rounding == Rounding.Up && 1 << (result * 8) < value ? 1 : 0);\n }\n }\n}\n" - }, - "@openzeppelin/contracts/utils/StorageSlot.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.7.0) (utils/StorageSlot.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Library for reading and writing primitive types to specific storage slots.\n *\n * Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts.\n * This library helps with reading and writing to such slots without the need for inline assembly.\n *\n * The functions in this library return Slot structs that contain a `value` member that can be used to read or write.\n *\n * Example usage to set ERC1967 implementation slot:\n * ```\n * contract ERC1967 {\n * bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;\n *\n * function _getImplementation() internal view returns (address) {\n * return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;\n * }\n *\n * function _setImplementation(address newImplementation) internal {\n * require(Address.isContract(newImplementation), \"ERC1967: new implementation is not a contract\");\n * StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;\n * }\n * }\n * ```\n *\n * _Available since v4.1 for `address`, `bool`, `bytes32`, and `uint256`._\n */\nlibrary StorageSlot {\n struct AddressSlot {\n address value;\n }\n\n struct BooleanSlot {\n bool value;\n }\n\n struct Bytes32Slot {\n bytes32 value;\n }\n\n struct Uint256Slot {\n uint256 value;\n }\n\n /**\n * @dev Returns an `AddressSlot` with member `value` located at `slot`.\n */\n function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) {\n /// @solidity memory-safe-assembly\n assembly {\n r.slot := slot\n }\n }\n\n /**\n * @dev Returns an `BooleanSlot` with member `value` located at `slot`.\n */\n function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) {\n /// @solidity memory-safe-assembly\n assembly {\n r.slot := slot\n }\n }\n\n /**\n * @dev Returns an `Bytes32Slot` with member `value` located at `slot`.\n */\n function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) {\n /// @solidity memory-safe-assembly\n assembly {\n r.slot := slot\n }\n }\n\n /**\n * @dev Returns an `Uint256Slot` with member `value` located at `slot`.\n */\n function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) {\n /// @solidity memory-safe-assembly\n assembly {\n r.slot := slot\n }\n }\n}\n" - }, - "@openzeppelin/contracts/utils/Strings.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/Strings.sol)\n\npragma solidity ^0.8.0;\n\nimport \"./math/Math.sol\";\n\n/**\n * @dev String operations.\n */\nlibrary Strings {\n bytes16 private constant _SYMBOLS = \"0123456789abcdef\";\n uint8 private constant _ADDRESS_LENGTH = 20;\n\n /**\n * @dev Converts a `uint256` to its ASCII `string` decimal representation.\n */\n function toString(uint256 value) internal pure returns (string memory) {\n unchecked {\n uint256 length = Math.log10(value) + 1;\n string memory buffer = new string(length);\n uint256 ptr;\n /// @solidity memory-safe-assembly\n assembly {\n ptr := add(buffer, add(32, length))\n }\n while (true) {\n ptr--;\n /// @solidity memory-safe-assembly\n assembly {\n mstore8(ptr, byte(mod(value, 10), _SYMBOLS))\n }\n value /= 10;\n if (value == 0) break;\n }\n return buffer;\n }\n }\n\n /**\n * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.\n */\n function toHexString(uint256 value) internal pure returns (string memory) {\n unchecked {\n return toHexString(value, Math.log256(value) + 1);\n }\n }\n\n /**\n * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.\n */\n function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {\n bytes memory buffer = new bytes(2 * length + 2);\n buffer[0] = \"0\";\n buffer[1] = \"x\";\n for (uint256 i = 2 * length + 1; i > 1; --i) {\n buffer[i] = _SYMBOLS[value & 0xf];\n value >>= 4;\n }\n require(value == 0, \"Strings: hex length insufficient\");\n return string(buffer);\n }\n\n /**\n * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation.\n */\n function toHexString(address addr) internal pure returns (string memory) {\n return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);\n }\n}\n" - }, - "contracts/core/BaseAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-empty-blocks */\n\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\nimport \"./Helpers.sol\";\n\n/**\n * Basic account implementation.\n * this contract provides the basic logic for implementing the IAccount interface - validateUserOp\n * specific account implementation should inherit it and provide the account-specific logic\n */\nabstract contract BaseAccount is IAccount {\n using UserOperationLib for UserOperation;\n\n //return value in case of signature failure, with no time-range.\n // equivalent to _packValidationData(true,0,0);\n uint256 constant internal SIG_VALIDATION_FAILED = 1;\n\n /**\n * Return the account nonce.\n * This method returns the next sequential nonce.\n * For a nonce of a specific key, use `entrypoint.getNonce(account, key)`\n */\n function getNonce() public view virtual returns (uint256) {\n return entryPoint().getNonce(address(this), 0);\n }\n\n /**\n * return the entryPoint used by this account.\n * subclass should return the current entryPoint used by this account.\n */\n function entryPoint() public view virtual returns (IEntryPoint);\n\n /**\n * Validate user's signature and nonce.\n * subclass doesn't need to override this method. Instead, it should override the specific internal validation methods.\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external override virtual returns (uint256 validationData) {\n _requireFromEntryPoint();\n validationData = _validateSignature(userOp, userOpHash);\n _validateNonce(userOp.nonce);\n _payPrefund(missingAccountFunds);\n }\n\n /**\n * ensure the request comes from the known entrypoint.\n */\n function _requireFromEntryPoint() internal virtual view {\n require(msg.sender == address(entryPoint()), \"account: not from EntryPoint\");\n }\n\n /**\n * validate the signature is valid for this message.\n * @param userOp validate the userOp.signature field\n * @param userOpHash convenient field: the hash of the request, to check the signature against\n * (also hashes the entrypoint and chain id)\n * @return validationData signature and time-range of this operation\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * If the account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function _validateSignature(UserOperation calldata userOp, bytes32 userOpHash)\n internal virtual returns (uint256 validationData);\n\n /**\n * Validate the nonce of the UserOperation.\n * This method may validate the nonce requirement of this account.\n * e.g.\n * To limit the nonce to use sequenced UserOps only (no \"out of order\" UserOps):\n * `require(nonce < type(uint64).max)`\n * For a hypothetical account that *requires* the nonce to be out-of-order:\n * `require(nonce & type(uint64).max == 0)`\n *\n * The actual nonce uniqueness is managed by the EntryPoint, and thus no other\n * action is needed by the account itself.\n *\n * @param nonce to validate\n *\n * solhint-disable-next-line no-empty-blocks\n */\n function _validateNonce(uint256 nonce) internal view virtual {\n }\n\n /**\n * sends to the entrypoint (msg.sender) the missing funds for this transaction.\n * subclass MAY override this method for better funds management\n * (e.g. send to the entryPoint more than the minimum required, so that in future transactions\n * it will not be required to send again)\n * @param missingAccountFunds the minimum value this method should send the entrypoint.\n * this value MAY be zero, in case there is enough deposit, or the userOp has a paymaster.\n */\n function _payPrefund(uint256 missingAccountFunds) internal virtual {\n if (missingAccountFunds != 0) {\n (bool success,) = payable(msg.sender).call{value : missingAccountFunds, gas : type(uint256).max}(\"\");\n (success);\n //ignore failure (its EntryPoint's job to verify, not account.)\n }\n }\n}\n" - }, - "contracts/core/BasePaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n\n/* solhint-disable reason-string */\n\nimport \"@openzeppelin/contracts/access/Ownable.sol\";\nimport \"../interfaces/IPaymaster.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\nimport \"./Helpers.sol\";\n\n/**\n * Helper class for creating a paymaster.\n * provides helper methods for staking.\n * validates that the postOp is called only by the entryPoint\n */\nabstract contract BasePaymaster is IPaymaster, Ownable {\n\n IEntryPoint immutable public entryPoint;\n\n constructor(IEntryPoint _entryPoint) {\n entryPoint = _entryPoint;\n }\n\n /// @inheritdoc IPaymaster\n function validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n external override returns (bytes memory context, uint256 validationData) {\n _requireFromEntryPoint();\n return _validatePaymasterUserOp(userOp, userOpHash, maxCost);\n }\n\n function _validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n internal virtual returns (bytes memory context, uint256 validationData);\n\n /// @inheritdoc IPaymaster\n function postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) external override {\n _requireFromEntryPoint();\n _postOp(mode, context, actualGasCost);\n }\n\n /**\n * post-operation handler.\n * (verified to be called only through the entryPoint)\n * @dev if subclass returns a non-empty context from validatePaymasterUserOp, it must also implement this method.\n * @param mode enum with the following options:\n * opSucceeded - user operation succeeded.\n * opReverted - user op reverted. still has to pay for gas.\n * postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n * Now this is the 2nd call, after user's op was deliberately reverted.\n * @param context - the context value returned by validatePaymasterUserOp\n * @param actualGasCost - actual gas used so far (without this postOp call).\n */\n function _postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) internal virtual {\n\n (mode,context,actualGasCost); // unused params\n // subclass must override this method if validatePaymasterUserOp returns a context\n revert(\"must override\");\n }\n\n /**\n * add a deposit for this paymaster, used for paying for transaction fees\n */\n function deposit() public payable {\n entryPoint.depositTo{value : msg.value}(address(this));\n }\n\n /**\n * withdraw value from the deposit\n * @param withdrawAddress target to send to\n * @param amount to withdraw\n */\n function withdrawTo(address payable withdrawAddress, uint256 amount) public onlyOwner {\n entryPoint.withdrawTo(withdrawAddress, amount);\n }\n /**\n * add stake for this paymaster.\n * This method can also carry eth value to add to the current stake.\n * @param unstakeDelaySec - the unstake delay for this paymaster. Can only be increased.\n */\n function addStake(uint32 unstakeDelaySec) external payable onlyOwner {\n entryPoint.addStake{value : msg.value}(unstakeDelaySec);\n }\n\n /**\n * return current paymaster's deposit on the entryPoint.\n */\n function getDeposit() public view returns (uint256) {\n return entryPoint.balanceOf(address(this));\n }\n\n /**\n * unlock the stake, in order to withdraw it.\n * The paymaster can't serve requests once unlocked, until it calls addStake again\n */\n function unlockStake() external onlyOwner {\n entryPoint.unlockStake();\n }\n\n /**\n * withdraw the entire paymaster's stake.\n * stake must be unlocked first (and then wait for the unstakeDelay to be over)\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external onlyOwner {\n entryPoint.withdrawStake(withdrawAddress);\n }\n\n /// validate the call is made from a valid entrypoint\n function _requireFromEntryPoint() internal virtual {\n require(msg.sender == address(entryPoint), \"Sender not EntryPoint\");\n }\n}\n" - }, - "contracts/core/EntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IPaymaster.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\n\nimport \"../utils/Exec.sol\";\nimport \"./StakeManager.sol\";\nimport \"./SenderCreator.sol\";\nimport \"./Helpers.sol\";\nimport \"./NonceManager.sol\";\nimport \"@openzeppelin/contracts/security/ReentrancyGuard.sol\";\n\ncontract EntryPoint is IEntryPoint, StakeManager, NonceManager, ReentrancyGuard {\n\n using UserOperationLib for UserOperation;\n\n SenderCreator private immutable senderCreator = new SenderCreator();\n\n // internal value used during simulation: need to query aggregator.\n address private constant SIMULATE_FIND_AGGREGATOR = address(1);\n\n // marker for inner call revert on out of gas\n bytes32 private constant INNER_OUT_OF_GAS = hex'deaddead';\n\n uint256 private constant REVERT_REASON_MAX_LEN = 2048;\n\n /**\n * for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value\n * in case of signature failure, instead of revert.\n */\n uint256 public constant SIG_VALIDATION_FAILED = 1;\n\n /**\n * compensate the caller's beneficiary address with the collected fees of all UserOperations.\n * @param beneficiary the address to receive the fees\n * @param amount amount to transfer.\n */\n function _compensate(address payable beneficiary, uint256 amount) internal {\n require(beneficiary != address(0), \"AA90 invalid beneficiary\");\n (bool success,) = beneficiary.call{value : amount}(\"\");\n require(success, \"AA91 failed send to beneficiary\");\n }\n\n /**\n * execute a user op\n * @param opIndex index into the opInfo array\n * @param userOp the userOp to execute\n * @param opInfo the opInfo filled by validatePrepayment for this userOp.\n * @return collected the total amount this userOp paid.\n */\n function _executeUserOp(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory opInfo) private returns (uint256 collected) {\n uint256 preGas = gasleft();\n bytes memory context = getMemoryBytesFromOffset(opInfo.contextOffset);\n\n try this.innerHandleOp(userOp.callData, opInfo, context) returns (uint256 _actualGasCost) {\n collected = _actualGasCost;\n } catch {\n bytes32 innerRevertCode;\n assembly {\n returndatacopy(0, 0, 32)\n innerRevertCode := mload(0)\n }\n // handleOps was called with gas limit too low. abort entire bundle.\n if (innerRevertCode == INNER_OUT_OF_GAS) {\n //report paymaster, since if it is not deliberately caused by the bundler,\n // it must be a revert caused by paymaster.\n revert FailedOp(opIndex, \"AA95 out of gas\");\n }\n\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n collected = _handlePostOp(opIndex, IPaymaster.PostOpMode.postOpReverted, opInfo, context, actualGas);\n }\n }\n\n /**\n * Execute a batch of UserOperations.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) public nonReentrant {\n\n uint256 opslen = ops.length;\n UserOpInfo[] memory opInfos = new UserOpInfo[](opslen);\n\n unchecked {\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[i];\n (uint256 validationData, uint256 pmValidationData) = _validatePrepayment(i, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, pmValidationData, address(0));\n }\n\n uint256 collected = 0;\n emit BeforeExecution();\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(i, ops[i], opInfos[i]);\n }\n\n _compensate(beneficiary, collected);\n } //unchecked\n }\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) public nonReentrant {\n\n uint256 opasLen = opsPerAggregator.length;\n uint256 totalOps = 0;\n for (uint256 i = 0; i < opasLen; i++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[i];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n //address(1) is special marker of \"signature error\"\n require(address(aggregator) != address(1), \"AA96 invalid aggregator\");\n\n if (address(aggregator) != address(0)) {\n // solhint-disable-next-line no-empty-blocks\n try aggregator.validateSignatures(ops, opa.signature) {}\n catch {\n revert SignatureValidationFailed(address(aggregator));\n }\n }\n\n totalOps += ops.length;\n }\n\n UserOpInfo[] memory opInfos = new UserOpInfo[](totalOps);\n\n emit BeforeExecution();\n\n uint256 opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n uint256 opslen = ops.length;\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[opIndex];\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(opIndex, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, paymasterValidationData, address(aggregator));\n opIndex++;\n }\n }\n\n uint256 collected = 0;\n opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n emit SignatureAggregatorChanged(address(opa.aggregator));\n UserOperation[] calldata ops = opa.userOps;\n uint256 opslen = ops.length;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(opIndex, ops[i], opInfos[opIndex]);\n opIndex++;\n }\n }\n emit SignatureAggregatorChanged(address(0));\n\n _compensate(beneficiary, collected);\n }\n\n /// @inheritdoc IEntryPoint\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external override {\n\n UserOpInfo memory opInfo;\n _simulationOnlyValidations(op);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, op, opInfo);\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n\n numberMarker();\n uint256 paid = _executeUserOp(0, op, opInfo);\n numberMarker();\n bool targetSuccess;\n bytes memory targetResult;\n if (target != address(0)) {\n (targetSuccess, targetResult) = target.call(targetCallData);\n }\n revert ExecutionResult(opInfo.preOpGas, paid, data.validAfter, data.validUntil, targetSuccess, targetResult);\n }\n\n\n // A memory copy of UserOp static fields only.\n // Excluding: callData, initCode and signature. Replacing paymasterAndData with paymaster.\n struct MemoryUserOp {\n address sender;\n uint256 nonce;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n address paymaster;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n }\n\n struct UserOpInfo {\n MemoryUserOp mUserOp;\n bytes32 userOpHash;\n uint256 prefund;\n uint256 contextOffset;\n uint256 preOpGas;\n }\n\n /**\n * inner function to handle a UserOperation.\n * Must be declared \"external\" to open a call context, but it can only be called by handleOps.\n */\n function innerHandleOp(bytes memory callData, UserOpInfo memory opInfo, bytes calldata context) external returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n require(msg.sender == address(this), \"AA92 internal call only\");\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n\n uint callGasLimit = mUserOp.callGasLimit;\n unchecked {\n // handleOps was called with gas limit too low. abort entire bundle.\n if (gasleft() < callGasLimit + mUserOp.verificationGasLimit + 5000) {\n assembly {\n mstore(0, INNER_OUT_OF_GAS)\n revert(0, 32)\n }\n }\n }\n\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\n if (callData.length > 0) {\n bool success = Exec.call(mUserOp.sender, 0, callData, callGasLimit);\n if (!success) {\n bytes memory result = Exec.getReturnData(REVERT_REASON_MAX_LEN);\n if (result.length > 0) {\n emit UserOperationRevertReason(opInfo.userOpHash, mUserOp.sender, mUserOp.nonce, result);\n }\n mode = IPaymaster.PostOpMode.opReverted;\n }\n }\n\n unchecked {\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n //note: opIndex is ignored (relevant only if mode==postOpReverted, which is only possible outside of innerHandleOp)\n return _handlePostOp(0, mode, opInfo, context, actualGas);\n }\n }\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) public view returns (bytes32) {\n return keccak256(abi.encode(userOp.hash(), address(this), block.chainid));\n }\n\n /**\n * copy general fields from userOp into the memory opInfo structure.\n */\n function _copyUserOpToMemory(UserOperation calldata userOp, MemoryUserOp memory mUserOp) internal pure {\n mUserOp.sender = userOp.sender;\n mUserOp.nonce = userOp.nonce;\n mUserOp.callGasLimit = userOp.callGasLimit;\n mUserOp.verificationGasLimit = userOp.verificationGasLimit;\n mUserOp.preVerificationGas = userOp.preVerificationGas;\n mUserOp.maxFeePerGas = userOp.maxFeePerGas;\n mUserOp.maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes calldata paymasterAndData = userOp.paymasterAndData;\n if (paymasterAndData.length > 0) {\n require(paymasterAndData.length >= 20, \"AA93 invalid paymasterAndData\");\n mUserOp.paymaster = address(bytes20(paymasterAndData[: 20]));\n } else {\n mUserOp.paymaster = address(0);\n }\n }\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external {\n UserOpInfo memory outOpInfo;\n\n _simulationOnlyValidations(userOp);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, userOp, outOpInfo);\n StakeInfo memory paymasterInfo = _getStakeInfo(outOpInfo.mUserOp.paymaster);\n StakeInfo memory senderInfo = _getStakeInfo(outOpInfo.mUserOp.sender);\n StakeInfo memory factoryInfo;\n {\n bytes calldata initCode = userOp.initCode;\n address factory = initCode.length >= 20 ? address(bytes20(initCode[0 : 20])) : address(0);\n factoryInfo = _getStakeInfo(factory);\n }\n\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n address aggregator = data.aggregator;\n bool sigFailed = aggregator == address(1);\n ReturnInfo memory returnInfo = ReturnInfo(outOpInfo.preOpGas, outOpInfo.prefund,\n sigFailed, data.validAfter, data.validUntil, getMemoryBytesFromOffset(outOpInfo.contextOffset));\n\n if (aggregator != address(0) && aggregator != address(1)) {\n AggregatorStakeInfo memory aggregatorInfo = AggregatorStakeInfo(aggregator, _getStakeInfo(aggregator));\n revert ValidationResultWithAggregation(returnInfo, senderInfo, factoryInfo, paymasterInfo, aggregatorInfo);\n }\n revert ValidationResult(returnInfo, senderInfo, factoryInfo, paymasterInfo);\n\n }\n\n function _getRequiredPrefund(MemoryUserOp memory mUserOp) internal pure returns (uint256 requiredPrefund) {\n unchecked {\n //when using a Paymaster, the verificationGasLimit is used also to as a limit for the postOp call.\n // our security model might call postOp eventually twice\n uint256 mul = mUserOp.paymaster != address(0) ? 3 : 1;\n uint256 requiredGas = mUserOp.callGasLimit + mUserOp.verificationGasLimit * mul + mUserOp.preVerificationGas;\n\n requiredPrefund = requiredGas * mUserOp.maxFeePerGas;\n }\n }\n\n // create the sender's contract if needed.\n function _createSenderIfNeeded(uint256 opIndex, UserOpInfo memory opInfo, bytes calldata initCode) internal {\n if (initCode.length != 0) {\n address sender = opInfo.mUserOp.sender;\n if (sender.code.length != 0) revert FailedOp(opIndex, \"AA10 sender already constructed\");\n address sender1 = senderCreator.createSender{gas : opInfo.mUserOp.verificationGasLimit}(initCode);\n if (sender1 == address(0)) revert FailedOp(opIndex, \"AA13 initCode failed or OOG\");\n if (sender1 != sender) revert FailedOp(opIndex, \"AA14 initCode must return sender\");\n if (sender1.code.length == 0) revert FailedOp(opIndex, \"AA15 initCode must create sender\");\n address factory = address(bytes20(initCode[0 : 20]));\n emit AccountDeployed(opInfo.userOpHash, sender, factory, opInfo.mUserOp.paymaster);\n }\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes calldata initCode) public {\n address sender = senderCreator.createSender(initCode);\n revert SenderAddressResult(sender);\n }\n\n function _simulationOnlyValidations(UserOperation calldata userOp) internal view {\n // solhint-disable-next-line no-empty-blocks\n try this._validateSenderAndPaymaster(userOp.initCode, userOp.sender, userOp.paymasterAndData) {}\n catch Error(string memory revertReason) {\n if (bytes(revertReason).length != 0) {\n revert FailedOp(0, revertReason);\n }\n }\n }\n\n /**\n * Called only during simulation.\n * This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\n */\n function _validateSenderAndPaymaster(bytes calldata initCode, address sender, bytes calldata paymasterAndData) external view {\n if (initCode.length == 0 && sender.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA20 account not deployed\");\n }\n if (paymasterAndData.length >= 20) {\n address paymaster = address(bytes20(paymasterAndData[0 : 20]));\n if (paymaster.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA30 paymaster not deployed\");\n }\n }\n // always revert\n revert(\"\");\n }\n\n /**\n * call account.validateUserOp.\n * revert (with FailedOp) in case validateUserOp reverts, or account didn't send required prefund.\n * decrement account's deposit if needed\n */\n function _validateAccountPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPrefund)\n internal returns (uint256 gasUsedByValidateAccountPrepayment, uint256 validationData) {\n unchecked {\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n address sender = mUserOp.sender;\n _createSenderIfNeeded(opIndex, opInfo, op.initCode);\n address paymaster = mUserOp.paymaster;\n numberMarker();\n uint256 missingAccountFunds = 0;\n if (paymaster == address(0)) {\n uint256 bal = balanceOf(sender);\n missingAccountFunds = bal > requiredPrefund ? 0 : requiredPrefund - bal;\n }\n try IAccount(sender).validateUserOp{gas : mUserOp.verificationGasLimit}(op, opInfo.userOpHash, missingAccountFunds)\n returns (uint256 _validationData) {\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA23 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA23 reverted (or OOG)\");\n }\n if (paymaster == address(0)) {\n DepositInfo storage senderInfo = deposits[sender];\n uint256 deposit = senderInfo.deposit;\n if (requiredPrefund > deposit) {\n revert FailedOp(opIndex, \"AA21 didn't pay prefund\");\n }\n senderInfo.deposit = uint112(deposit - requiredPrefund);\n }\n gasUsedByValidateAccountPrepayment = preGas - gasleft();\n }\n }\n\n /**\n * In case the request has a paymaster:\n * Validate paymaster has enough deposit.\n * Call paymaster.validatePaymasterUserOp.\n * Revert with proper FailedOp in case paymaster reverts.\n * Decrement paymaster's deposit\n */\n function _validatePaymasterPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPreFund, uint256 gasUsedByValidateAccountPrepayment)\n internal returns (bytes memory context, uint256 validationData) {\n unchecked {\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 verificationGasLimit = mUserOp.verificationGasLimit;\n require(verificationGasLimit > gasUsedByValidateAccountPrepayment, \"AA41 too little verificationGas\");\n uint256 gas = verificationGasLimit - gasUsedByValidateAccountPrepayment;\n\n address paymaster = mUserOp.paymaster;\n DepositInfo storage paymasterInfo = deposits[paymaster];\n uint256 deposit = paymasterInfo.deposit;\n if (deposit < requiredPreFund) {\n revert FailedOp(opIndex, \"AA31 paymaster deposit too low\");\n }\n paymasterInfo.deposit = uint112(deposit - requiredPreFund);\n try IPaymaster(paymaster).validatePaymasterUserOp{gas : gas}(op, opInfo.userOpHash, requiredPreFund) returns (bytes memory _context, uint256 _validationData){\n context = _context;\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA33 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA33 reverted (or OOG)\");\n }\n }\n }\n\n /**\n * revert if either account validationData or paymaster validationData is expired\n */\n function _validateAccountAndPaymasterValidationData(uint256 opIndex, uint256 validationData, uint256 paymasterValidationData, address expectedAggregator) internal view {\n (address aggregator, bool outOfTimeRange) = _getValidationData(validationData);\n if (expectedAggregator != aggregator) {\n revert FailedOp(opIndex, \"AA24 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA22 expired or not due\");\n }\n //pmAggregator is not a real signature aggregator: we don't have logic to handle it as address.\n // non-zero address means that the paymaster fails due to some signature check (which is ok only during estimation)\n address pmAggregator;\n (pmAggregator, outOfTimeRange) = _getValidationData(paymasterValidationData);\n if (pmAggregator != address(0)) {\n revert FailedOp(opIndex, \"AA34 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA32 paymaster expired or not due\");\n }\n }\n\n function _getValidationData(uint256 validationData) internal view returns (address aggregator, bool outOfTimeRange) {\n if (validationData == 0) {\n return (address(0), false);\n }\n ValidationData memory data = _parseValidationData(validationData);\n // solhint-disable-next-line not-rely-on-time\n outOfTimeRange = block.timestamp > data.validUntil || block.timestamp < data.validAfter;\n aggregator = data.aggregator;\n }\n\n /**\n * validate account and paymaster (if defined).\n * also make sure total validation doesn't exceed verificationGasLimit\n * this method is called off-chain (simulateValidation()) and on-chain (from handleOps)\n * @param opIndex the index of this userOp into the \"opInfos\" array\n * @param userOp the userOp to validate\n */\n function _validatePrepayment(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory outOpInfo)\n private returns (uint256 validationData, uint256 paymasterValidationData) {\n\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = outOpInfo.mUserOp;\n _copyUserOpToMemory(userOp, mUserOp);\n outOpInfo.userOpHash = getUserOpHash(userOp);\n\n // validate all numeric values in userOp are well below 128 bit, so they can safely be added\n // and multiplied without causing overflow\n uint256 maxGasValues = mUserOp.preVerificationGas | mUserOp.verificationGasLimit | mUserOp.callGasLimit |\n userOp.maxFeePerGas | userOp.maxPriorityFeePerGas;\n require(maxGasValues <= type(uint120).max, \"AA94 gas values overflow\");\n\n uint256 gasUsedByValidateAccountPrepayment;\n (uint256 requiredPreFund) = _getRequiredPrefund(mUserOp);\n (gasUsedByValidateAccountPrepayment, validationData) = _validateAccountPrepayment(opIndex, userOp, outOpInfo, requiredPreFund);\n\n if (!_validateAndUpdateNonce(mUserOp.sender, mUserOp.nonce)) {\n revert FailedOp(opIndex, \"AA25 invalid account nonce\");\n }\n\n //a \"marker\" where account opcode validation is done and paymaster opcode validation is about to start\n // (used only by off-chain simulateValidation)\n numberMarker();\n\n bytes memory context;\n if (mUserOp.paymaster != address(0)) {\n (context, paymasterValidationData) = _validatePaymasterPrepayment(opIndex, userOp, outOpInfo, requiredPreFund, gasUsedByValidateAccountPrepayment);\n }\n unchecked {\n uint256 gasUsed = preGas - gasleft();\n\n if (userOp.verificationGasLimit < gasUsed) {\n revert FailedOp(opIndex, \"AA40 over verificationGasLimit\");\n }\n outOpInfo.prefund = requiredPreFund;\n outOpInfo.contextOffset = getOffsetOfMemoryBytes(context);\n outOpInfo.preOpGas = preGas - gasleft() + userOp.preVerificationGas;\n }\n }\n\n /**\n * process post-operation.\n * called just after the callData is executed.\n * if a paymaster is defined and its validation returned a non-empty context, its postOp is called.\n * the excess amount is refunded to the account (or paymaster - if it was used in the request)\n * @param opIndex index in the batch\n * @param mode - whether is called from innerHandleOp, or outside (postOpReverted)\n * @param opInfo userOp fields and info collected during validation\n * @param context the context returned in validatePaymasterUserOp\n * @param actualGas the gas used so far by this user operation\n */\n function _handlePostOp(uint256 opIndex, IPaymaster.PostOpMode mode, UserOpInfo memory opInfo, bytes memory context, uint256 actualGas) private returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n unchecked {\n address refundAddress;\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 gasPrice = getUserOpGasPrice(mUserOp);\n\n address paymaster = mUserOp.paymaster;\n if (paymaster == address(0)) {\n refundAddress = mUserOp.sender;\n } else {\n refundAddress = paymaster;\n if (context.length > 0) {\n actualGasCost = actualGas * gasPrice;\n if (mode != IPaymaster.PostOpMode.postOpReverted) {\n IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost);\n } else {\n // solhint-disable-next-line no-empty-blocks\n try IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost) {}\n catch Error(string memory reason) {\n revert FailedOp(opIndex, string.concat(\"AA50 postOp reverted: \", reason));\n }\n catch {\n revert FailedOp(opIndex, \"AA50 postOp revert\");\n }\n }\n }\n }\n actualGas += preGas - gasleft();\n actualGasCost = actualGas * gasPrice;\n if (opInfo.prefund < actualGasCost) {\n revert FailedOp(opIndex, \"AA51 prefund below actualGasCost\");\n }\n uint256 refund = opInfo.prefund - actualGasCost;\n _incrementDeposit(refundAddress, refund);\n bool success = mode == IPaymaster.PostOpMode.opSucceeded;\n emit UserOperationEvent(opInfo.userOpHash, mUserOp.sender, mUserOp.paymaster, mUserOp.nonce, success, actualGasCost, actualGas);\n } // unchecked\n }\n\n /**\n * the gas price this UserOp agrees to pay.\n * relayer/block builder might submit the TX with higher priorityFee, but the user should not\n */\n function getUserOpGasPrice(MemoryUserOp memory mUserOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = mUserOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = mUserOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n\n function getOffsetOfMemoryBytes(bytes memory data) internal pure returns (uint256 offset) {\n assembly {offset := data}\n }\n\n function getMemoryBytesFromOffset(uint256 offset) internal pure returns (bytes memory data) {\n assembly {data := offset}\n }\n\n //place the NUMBER opcode in the code.\n // this is used as a marker during simulation, as this OP is completely banned from the simulated code of the\n // account and paymaster.\n function numberMarker() internal view {\n assembly {mstore(0, number())}\n }\n}\n\n" - }, - "contracts/core/Helpers.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\n/**\n * returned data from validateUserOp.\n * validateUserOp returns a uint256, with is created by `_packedValidationData` and parsed by `_parseValidationData`\n * @param aggregator - address(0) - the account validated the signature by itself.\n * address(1) - the account failed to validate the signature.\n * otherwise - this is an address of a signature aggregator that must be used to validate the signature.\n * @param validAfter - this UserOp is valid only after this timestamp.\n * @param validaUntil - this UserOp is valid only up to this timestamp.\n */\n struct ValidationData {\n address aggregator;\n uint48 validAfter;\n uint48 validUntil;\n }\n\n//extract sigFailed, validAfter, validUntil.\n// also convert zero validUntil to type(uint48).max\n function _parseValidationData(uint validationData) pure returns (ValidationData memory data) {\n address aggregator = address(uint160(validationData));\n uint48 validUntil = uint48(validationData >> 160);\n if (validUntil == 0) {\n validUntil = type(uint48).max;\n }\n uint48 validAfter = uint48(validationData >> (48 + 160));\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n// intersect account and paymaster ranges.\n function _intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) pure returns (ValidationData memory) {\n ValidationData memory accountValidationData = _parseValidationData(validationData);\n ValidationData memory pmValidationData = _parseValidationData(paymasterValidationData);\n address aggregator = accountValidationData.aggregator;\n if (aggregator == address(0)) {\n aggregator = pmValidationData.aggregator;\n }\n uint48 validAfter = accountValidationData.validAfter;\n uint48 validUntil = accountValidationData.validUntil;\n uint48 pmValidAfter = pmValidationData.validAfter;\n uint48 pmValidUntil = pmValidationData.validUntil;\n\n if (validAfter < pmValidAfter) validAfter = pmValidAfter;\n if (validUntil > pmValidUntil) validUntil = pmValidUntil;\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n/**\n * helper to pack the return value for validateUserOp\n * @param data - the ValidationData to pack\n */\n function _packValidationData(ValidationData memory data) pure returns (uint256) {\n return uint160(data.aggregator) | (uint256(data.validUntil) << 160) | (uint256(data.validAfter) << (160 + 48));\n }\n\n/**\n * helper to pack the return value for validateUserOp, when not using an aggregator\n * @param sigFailed - true for signature failure, false for success\n * @param validUntil last timestamp this UserOperation is valid (or zero for infinite)\n * @param validAfter first timestamp this UserOperation is valid\n */\n function _packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) pure returns (uint256) {\n return (sigFailed ? 1 : 0) | (uint256(validUntil) << 160) | (uint256(validAfter) << (160 + 48));\n }\n\n/**\n * keccak function over calldata.\n * @dev copy calldata into memory, do keccak and drop allocated memory. Strangely, this is more efficient than letting solidity do it.\n */\n function calldataKeccak(bytes calldata data) pure returns (bytes32 ret) {\n assembly {\n let mem := mload(0x40)\n let len := data.length\n calldatacopy(mem, data.offset, len)\n ret := keccak256(mem, len)\n }\n }\n\n" - }, - "contracts/core/NonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IEntryPoint.sol\";\n\n/**\n * nonce management functionality\n */\ncontract NonceManager is INonceManager {\n\n /**\n * The next valid sequence number for a given nonce key.\n */\n mapping(address => mapping(uint192 => uint256)) public nonceSequenceNumber;\n\n function getNonce(address sender, uint192 key)\n public view override returns (uint256 nonce) {\n return nonceSequenceNumber[sender][key] | (uint256(key) << 64);\n }\n\n // allow an account to manually increment its own nonce.\n // (mainly so that during construction nonce can be made non-zero,\n // to \"absorb\" the gas cost of first nonce increment to 1st transaction (construction),\n // not to 2nd transaction)\n function incrementNonce(uint192 key) public override {\n nonceSequenceNumber[msg.sender][key]++;\n }\n\n /**\n * validate nonce uniqueness for this account.\n * called just after validateUserOp()\n */\n function _validateAndUpdateNonce(address sender, uint256 nonce) internal returns (bool) {\n\n uint192 key = uint192(nonce >> 64);\n uint64 seq = uint64(nonce);\n return nonceSequenceNumber[sender][key]++ == seq;\n }\n\n}\n" - }, - "contracts/core/SenderCreator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * helper contract for EntryPoint, to call userOp.initCode from a \"neutral\" address,\n * which is explicitly not the entryPoint itself.\n */\ncontract SenderCreator {\n\n /**\n * call the \"initCode\" factory to create and return the sender account address\n * @param initCode the initCode value from a UserOp. contains 20 bytes of factory address, followed by calldata\n * @return sender the returned address of the created account, or zero address on failure.\n */\n function createSender(bytes calldata initCode) external returns (address sender) {\n address factory = address(bytes20(initCode[0 : 20]));\n bytes memory initCallData = initCode[20 :];\n bool success;\n /* solhint-disable no-inline-assembly */\n assembly {\n success := call(gas(), factory, 0, add(initCallData, 0x20), mload(initCallData), 0, 32)\n sender := mload(0)\n }\n if (!success) {\n sender = address(0);\n }\n }\n}\n" - }, - "contracts/core/StakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IStakeManager.sol\";\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable not-rely-on-time */\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by a paymaster.\n */\nabstract contract StakeManager is IStakeManager {\n\n /// maps paymaster to their deposits and stakes\n mapping(address => DepositInfo) public deposits;\n\n /// @inheritdoc IStakeManager\n function getDepositInfo(address account) public view returns (DepositInfo memory info) {\n return deposits[account];\n }\n\n // internal method to return just the stake info\n function _getStakeInfo(address addr) internal view returns (StakeInfo memory info) {\n DepositInfo storage depositInfo = deposits[addr];\n info.stake = depositInfo.stake;\n info.unstakeDelaySec = depositInfo.unstakeDelaySec;\n }\n\n /// return the deposit (for gas payment) of the account\n function balanceOf(address account) public view returns (uint256) {\n return deposits[account].deposit;\n }\n\n receive() external payable {\n depositTo(msg.sender);\n }\n\n function _incrementDeposit(address account, uint256 amount) internal {\n DepositInfo storage info = deposits[account];\n uint256 newAmount = info.deposit + amount;\n require(newAmount <= type(uint112).max, \"deposit overflow\");\n info.deposit = uint112(newAmount);\n }\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) public payable {\n _incrementDeposit(account, msg.value);\n DepositInfo storage info = deposits[account];\n emit Deposited(account, info.deposit);\n }\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 unstakeDelaySec) public payable {\n DepositInfo storage info = deposits[msg.sender];\n require(unstakeDelaySec > 0, \"must specify unstake delay\");\n require(unstakeDelaySec >= info.unstakeDelaySec, \"cannot decrease unstake time\");\n uint256 stake = info.stake + msg.value;\n require(stake > 0, \"no stake specified\");\n require(stake <= type(uint112).max, \"stake overflow\");\n deposits[msg.sender] = DepositInfo(\n info.deposit,\n true,\n uint112(stake),\n unstakeDelaySec,\n 0\n );\n emit StakeLocked(msg.sender, stake, unstakeDelaySec);\n }\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external {\n DepositInfo storage info = deposits[msg.sender];\n require(info.unstakeDelaySec != 0, \"not staked\");\n require(info.staked, \"already unstaking\");\n uint48 withdrawTime = uint48(block.timestamp) + info.unstakeDelaySec;\n info.withdrawTime = withdrawTime;\n info.staked = false;\n emit StakeUnlocked(msg.sender, withdrawTime);\n }\n\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external {\n DepositInfo storage info = deposits[msg.sender];\n uint256 stake = info.stake;\n require(stake > 0, \"No stake to withdraw\");\n require(info.withdrawTime > 0, \"must call unlockStake() first\");\n require(info.withdrawTime <= block.timestamp, \"Stake withdrawal is not due\");\n info.unstakeDelaySec = 0;\n info.withdrawTime = 0;\n info.stake = 0;\n emit StakeWithdrawn(msg.sender, withdrawAddress, stake);\n (bool success,) = withdrawAddress.call{value : stake}(\"\");\n require(success, \"failed to withdraw stake\");\n }\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external {\n DepositInfo storage info = deposits[msg.sender];\n require(withdrawAmount <= info.deposit, \"Withdraw amount too large\");\n info.deposit = uint112(info.deposit - withdrawAmount);\n emit Withdrawn(msg.sender, withdrawAddress, withdrawAmount);\n (bool success,) = withdrawAddress.call{value : withdrawAmount}(\"\");\n require(success, \"failed to withdraw\");\n }\n}\n" - }, - "contracts/interfaces/IAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\ninterface IAccount {\n\n /**\n * Validate user's signature and nonce\n * the entryPoint will make the call to the recipient only if this validation call returns successfully.\n * signature failure should be reported by returning SIG_VALIDATION_FAILED (1).\n * This allows making a \"simulation call\" without a valid signature\n * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure.\n *\n * @dev Must validate caller is the entryPoint.\n * Must validate the signature and nonce\n * @param userOp the operation that is about to be executed.\n * @param userOpHash hash of the user's request data. can be used as the basis for signature.\n * @param missingAccountFunds missing funds on the account's deposit in the entrypoint.\n * This is the minimum amount to transfer to the sender(entryPoint) to be able to make the call.\n * The excess is left as a deposit in the entrypoint, for future calls.\n * can be withdrawn anytime using \"entryPoint.withdrawTo()\"\n * In case there is a paymaster in the request (or the current deposit is high enough), this value will be zero.\n * @return validationData packaged ValidationData structure. use `_packValidationData` and `_unpackValidationData` to encode and decode\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * If an account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external returns (uint256 validationData);\n}\n" - }, - "contracts/interfaces/IAggregator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * Aggregated Signatures validator.\n */\ninterface IAggregator {\n\n /**\n * validate aggregated signature.\n * revert if the aggregated signature does not match the given list of operations.\n */\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external view;\n\n /**\n * validate signature of a single userOp\n * This method is should be called by bundler after EntryPoint.simulateValidation() returns (reverts) with ValidationResultWithAggregation\n * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps.\n * @param userOp the userOperation received from the user.\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\n * (usually empty, unless account and aggregator support some kind of \"multisig\"\n */\n function validateUserOpSignature(UserOperation calldata userOp)\n external view returns (bytes memory sigForUserOp);\n\n /**\n * aggregate multiple signatures into a single value.\n * This method is called off-chain to calculate the signature to pass with handleOps()\n * bundler MAY use optimized custom code perform this aggregation\n * @param userOps array of UserOperations to collect the signatures from.\n * @return aggregatedSignature the aggregated signature\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external view returns (bytes memory aggregatedSignature);\n}\n" - }, - "contracts/interfaces/IEntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"./UserOperation.sol\";\nimport \"./IStakeManager.sol\";\nimport \"./IAggregator.sol\";\nimport \"./INonceManager.sol\";\n\ninterface IEntryPoint is IStakeManager, INonceManager {\n\n /***\n * An event emitted after each successful request\n * @param userOpHash - unique identifier for the request (hash its entire content, except signature).\n * @param sender - the account that generates this request.\n * @param paymaster - if non-null, the paymaster that pays for this request.\n * @param nonce - the nonce value from the request.\n * @param success - true if the sender transaction succeeded, false if reverted.\n * @param actualGasCost - actual amount paid (by account or paymaster) for this UserOperation.\n * @param actualGasUsed - total gas used by this UserOperation (including preVerification, creation, validation and execution).\n */\n event UserOperationEvent(bytes32 indexed userOpHash, address indexed sender, address indexed paymaster, uint256 nonce, bool success, uint256 actualGasCost, uint256 actualGasUsed);\n\n /**\n * account \"sender\" was deployed.\n * @param userOpHash the userOp that deployed this account. UserOperationEvent will follow.\n * @param sender the account that is deployed\n * @param factory the factory used to deploy this account (in the initCode)\n * @param paymaster the paymaster used by this UserOp\n */\n event AccountDeployed(bytes32 indexed userOpHash, address indexed sender, address factory, address paymaster);\n\n /**\n * An event emitted if the UserOperation \"callData\" reverted with non-zero length\n * @param userOpHash the request unique identifier.\n * @param sender the sender of this request\n * @param nonce the nonce used in the request\n * @param revertReason - the return bytes from the (reverted) call to \"callData\".\n */\n event UserOperationRevertReason(bytes32 indexed userOpHash, address indexed sender, uint256 nonce, bytes revertReason);\n\n /**\n * an event emitted by handleOps(), before starting the execution loop.\n * any event emitted before this event, is part of the validation.\n */\n event BeforeExecution();\n\n /**\n * signature aggregator used by the following UserOperationEvents within this bundle.\n */\n event SignatureAggregatorChanged(address indexed aggregator);\n\n /**\n * a custom revert error of handleOps, to identify the offending op.\n * NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\n * @param opIndex - index into the array of ops to the failed one (in simulateValidation, this is always zero)\n * @param reason - revert reason\n * The string starts with a unique code \"AAmn\", where \"m\" is \"1\" for factory, \"2\" for account and \"3\" for paymaster issues,\n * so a failure can be attributed to the correct entity.\n * Should be caught in off-chain handleOps simulation and not happen on-chain.\n * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\n */\n error FailedOp(uint256 opIndex, string reason);\n\n /**\n * error case when a signature aggregator fails to verify the aggregated signature it had created.\n */\n error SignatureValidationFailed(address aggregator);\n\n /**\n * Successful result from simulateValidation.\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n */\n error ValidationResult(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo);\n\n /**\n * Successful result from simulateValidation, if the account returns a signature aggregator\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n * @param aggregatorInfo signature aggregation info (if the account requires signature aggregator)\n * bundler MUST use it to verify the signature, or reject the UserOperation\n */\n error ValidationResultWithAggregation(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo,\n AggregatorStakeInfo aggregatorInfo);\n\n /**\n * return value of getSenderAddress\n */\n error SenderAddressResult(address sender);\n\n /**\n * return value of simulateHandleOp\n */\n error ExecutionResult(uint256 preOpGas, uint256 paid, uint48 validAfter, uint48 validUntil, bool targetSuccess, bytes targetResult);\n\n //UserOps handled, per aggregator\n struct UserOpsPerAggregator {\n UserOperation[] userOps;\n\n // aggregator address\n IAggregator aggregator;\n // aggregated signature\n bytes signature;\n }\n\n /**\n * Execute a batch of UserOperation.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) external;\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) external;\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) external view returns (bytes32);\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external;\n\n /**\n * gas and return values during simulation\n * @param preOpGas the gas used for validation (including preValidationGas)\n * @param prefund the required prefund for this operation\n * @param sigFailed validateUserOp's (or paymaster's) signature check failed\n * @param validAfter - first timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param validUntil - last timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param paymasterContext returned by validatePaymasterUserOp (to be passed into postOp)\n */\n struct ReturnInfo {\n uint256 preOpGas;\n uint256 prefund;\n bool sigFailed;\n uint48 validAfter;\n uint48 validUntil;\n bytes paymasterContext;\n }\n\n /**\n * returned aggregated signature info.\n * the aggregator returned by the account, and its current stake.\n */\n struct AggregatorStakeInfo {\n address aggregator;\n StakeInfo stakeInfo;\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes memory initCode) external;\n\n\n /**\n * simulate full execution of a UserOperation (including both validation and target execution)\n * this method will always revert with \"ExecutionResult\".\n * it performs full validation of the UserOperation, but ignores signature error.\n * an optional target address is called after the userop succeeds, and its value is returned\n * (before the entire call is reverted)\n * Note that in order to collect the the success/failure of the target call, it must be executed\n * with trace enabled to track the emitted events.\n * @param op the UserOperation to simulate\n * @param target if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult\n * are set to the return from that call.\n * @param targetCallData callData to pass to target address\n */\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external;\n}\n\n" - }, - "contracts/interfaces/INonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\ninterface INonceManager {\n\n /**\n * Return the next nonce for this sender.\n * Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop)\n * But UserOp with different keys can come with arbitrary order.\n *\n * @param sender the account address\n * @param key the high 192 bit of the nonce\n * @return nonce a full nonce to pass for next UserOp with this sender.\n */\n function getNonce(address sender, uint192 key)\n external view returns (uint256 nonce);\n\n /**\n * Manually increment the nonce of the sender.\n * This method is exposed just for completeness..\n * Account does NOT need to call it, neither during validation, nor elsewhere,\n * as the EntryPoint will update the nonce regardless.\n * Possible use-case is call it with various keys to \"initialize\" their nonces to one, so that future\n * UserOperations will not pay extra for the first transaction with a given key.\n */\n function incrementNonce(uint192 key) external;\n}\n" - }, - "contracts/interfaces/IPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * the interface exposed by a paymaster contract, who agrees to pay the gas for user's operations.\n * a paymaster must hold a stake to cover the required entrypoint stake and also the gas for the transaction.\n */\ninterface IPaymaster {\n\n enum PostOpMode {\n opSucceeded, // user op succeeded\n opReverted, // user op reverted. still has to pay for gas.\n postOpReverted //user op succeeded, but caused postOp to revert. Now it's a 2nd call, after user's op was deliberately reverted.\n }\n\n /**\n * payment validation: check if paymaster agrees to pay.\n * Must verify sender is the entryPoint.\n * Revert to reject this request.\n * Note that bundlers will reject this method if it changes the state, unless the paymaster is trusted (whitelisted)\n * The paymaster pre-pays using its deposit, and receive back a refund after the postOp method returns.\n * @param userOp the user operation\n * @param userOpHash hash of the user's request data.\n * @param maxCost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\n * @return context value to send to a postOp\n * zero length to signify postOp is not required.\n * @return validationData signature and time-range of this operation, encoded the same as the return value of validateUserOperation\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n external returns (bytes memory context, uint256 validationData);\n\n /**\n * post-operation handler.\n * Must verify sender is the entryPoint\n * @param mode enum with the following options:\n * opSucceeded - user operation succeeded.\n * opReverted - user op reverted. still has to pay for gas.\n * postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n * Now this is the 2nd call, after user's op was deliberately reverted.\n * @param context - the context value returned by validatePaymasterUserOp\n * @param actualGasCost - actual gas used so far (without this postOp call).\n */\n function postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) external;\n}\n" - }, - "contracts/interfaces/IStakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by the staked entity.\n */\ninterface IStakeManager {\n\n event Deposited(\n address indexed account,\n uint256 totalDeposit\n );\n\n event Withdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /// Emitted when stake or unstake delay are modified\n event StakeLocked(\n address indexed account,\n uint256 totalStaked,\n uint256 unstakeDelaySec\n );\n\n /// Emitted once a stake is scheduled for withdrawal\n event StakeUnlocked(\n address indexed account,\n uint256 withdrawTime\n );\n\n event StakeWithdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /**\n * @param deposit the entity's deposit\n * @param staked true if this entity is staked.\n * @param stake actual amount of ether staked for this entity.\n * @param unstakeDelaySec minimum delay to withdraw the stake.\n * @param withdrawTime - first block timestamp where 'withdrawStake' will be callable, or zero if already locked\n * @dev sizes were chosen so that (deposit,staked, stake) fit into one cell (used during handleOps)\n * and the rest fit into a 2nd cell.\n * 112 bit allows for 10^15 eth\n * 48 bit for full timestamp\n * 32 bit allows 150 years for unstake delay\n */\n struct DepositInfo {\n uint112 deposit;\n bool staked;\n uint112 stake;\n uint32 unstakeDelaySec;\n uint48 withdrawTime;\n }\n\n //API struct used by getStakeInfo and simulateValidation\n struct StakeInfo {\n uint256 stake;\n uint256 unstakeDelaySec;\n }\n\n /// @return info - full deposit information of given account\n function getDepositInfo(address account) external view returns (DepositInfo memory info);\n\n /// @return the deposit (for gas payment) of the account\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) external payable;\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param _unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 _unstakeDelaySec) external payable;\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external;\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external;\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external;\n}\n" - }, - "contracts/interfaces/UserOperation.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\nimport {calldataKeccak} from \"../core/Helpers.sol\";\n\n/**\n * User Operation struct\n * @param sender the sender account of this request.\n * @param nonce unique value the sender uses to verify it is not a replay.\n * @param initCode if set, the account contract will be created by this constructor/\n * @param callData the method call to execute on this account.\n * @param callGasLimit the gas limit passed to the callData method call.\n * @param verificationGasLimit gas used for validateUserOp and validatePaymasterUserOp.\n * @param preVerificationGas gas not calculated by the handleOps method, but added to the gas paid. Covers batch overhead.\n * @param maxFeePerGas same as EIP-1559 gas parameter.\n * @param maxPriorityFeePerGas same as EIP-1559 gas parameter.\n * @param paymasterAndData if set, this field holds the paymaster address and paymaster-specific data. the paymaster will pay for the transaction instead of the sender.\n * @param signature sender-verified signature over the entire request, the EntryPoint address and the chain ID.\n */\n struct UserOperation {\n\n address sender;\n uint256 nonce;\n bytes initCode;\n bytes callData;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n bytes paymasterAndData;\n bytes signature;\n }\n\n/**\n * Utility functions helpful when working with UserOperation structs.\n */\nlibrary UserOperationLib {\n\n function getSender(UserOperation calldata userOp) internal pure returns (address) {\n address data;\n //read sender from userOp, which is first userOp member (saves 800 gas...)\n assembly {data := calldataload(userOp)}\n return address(uint160(data));\n }\n\n //relayer/block builder might submit the TX with higher priorityFee, but the user should not\n // pay above what he signed for.\n function gasPrice(UserOperation calldata userOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n address sender = getSender(userOp);\n uint256 nonce = userOp.nonce;\n bytes32 hashInitCode = calldataKeccak(userOp.initCode);\n bytes32 hashCallData = calldataKeccak(userOp.callData);\n uint256 callGasLimit = userOp.callGasLimit;\n uint256 verificationGasLimit = userOp.verificationGasLimit;\n uint256 preVerificationGas = userOp.preVerificationGas;\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes32 hashPaymasterAndData = calldataKeccak(userOp.paymasterAndData);\n\n return abi.encode(\n sender, nonce,\n hashInitCode, hashCallData,\n callGasLimit, verificationGasLimit, preVerificationGas,\n maxFeePerGas, maxPriorityFeePerGas,\n hashPaymasterAndData\n );\n }\n\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\n return keccak256(pack(userOp));\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n}\n" - }, - "contracts/samples/bls/BLSAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../SimpleAccount.sol\";\nimport \"./IBLSAccount.sol\";\n\n/**\n * Minimal BLS-based account that uses an aggregated signature.\n * The account must maintain its own BLS public key, and expose its trusted signature aggregator.\n * Note that unlike the \"standard\" SimpleAccount, this account can't be called directly\n * (normal SimpleAccount uses its \"signer\" address as both the ecrecover signer, and as a legitimate\n * Ethereum sender address. Obviously, a BLS public key is not a valid Ethereum sender address.)\n */\ncontract BLSAccount is SimpleAccount, IBLSAccount {\n address public immutable aggregator;\n uint256[4] private publicKey;\n\n // The constructor is used only for the \"implementation\" and only sets immutable values.\n // Mutable value slots for proxy accounts are set by the 'initialize' function.\n constructor(IEntryPoint anEntryPoint, address anAggregator) SimpleAccount(anEntryPoint) {\n aggregator = anAggregator;\n }\n\n /**\n * The initializer for the BLSAccount instance.\n * @param aPublicKey public key from a BLS keypair that will have a full ownership and control of this account.\n */\n function initialize(uint256[4] memory aPublicKey) public virtual initializer {\n super._initialize(address(0));\n _setBlsPublicKey(aPublicKey);\n }\n\n function _validateSignature(UserOperation calldata userOp, bytes32 userOpHash)\n internal override view returns (uint256 validationData) {\n\n (userOp, userOpHash);\n if (userOp.initCode.length != 0) {\n // BLSSignatureAggregator.getUserOpPublicKey() assumes that during account creation, the public key is\n // the suffix of the initCode.\n // The account MUST validate it\n bytes32 pubKeyHash = keccak256(abi.encode(getBlsPublicKey()));\n require(keccak256(userOp.initCode[userOp.initCode.length - 128 :]) == pubKeyHash, \"wrong pubkey\");\n }\n return _packValidationData(ValidationData(aggregator, 0,0));\n }\n\n /**\n * Allows the owner to set or change the BLS key.\n * @param newPublicKey public key from a BLS keypair that will have a full ownership and control of this account.\n */\n function setBlsPublicKey(uint256[4] memory newPublicKey) public onlyOwner {\n _setBlsPublicKey(newPublicKey);\n }\n\n function _setBlsPublicKey(uint256[4] memory newPublicKey) internal {\n emit PublicKeyChanged(publicKey, newPublicKey);\n publicKey = newPublicKey;\n }\n\n /// @inheritdoc IBLSAccount\n function getBlsPublicKey() public override view returns (uint256[4] memory) {\n return publicKey;\n }\n}\n" - }, - "contracts/samples/bls/BLSAccountFactory.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"@openzeppelin/contracts/utils/Create2.sol\";\nimport \"@openzeppelin/contracts/proxy/ERC1967/ERC1967Proxy.sol\";\n\nimport \"../../interfaces/IEntryPoint.sol\";\nimport \"./BLSAccount.sol\";\n\n/* solhint-disable no-inline-assembly */\n\n/**\n * Based on SimpleAccountFactory.\n * Cannot be a subclass since both constructor and createAccount depend on the\n * constructor and initializer of the actual account contract.\n */\ncontract BLSAccountFactory {\n BLSAccount public immutable accountImplementation;\n\n constructor(IEntryPoint entryPoint, address aggregator){\n accountImplementation = new BLSAccount(entryPoint, aggregator);\n }\n\n /**\n * create an account, and return its address.\n * returns the address even if the account is already deployed.\n * Note that during UserOperation execution, this method is called only if the account is not deployed.\n * This method returns an existing account address so that entryPoint.getSenderAddress() would work even after account creation\n * Also note that our BLSSignatureAggregator requires that the public key is the last parameter\n */\n function createAccount(uint256 salt, uint256[4] calldata aPublicKey) public returns (BLSAccount) {\n\n // the BLSSignatureAggregator depends on the public-key being the last 4 uint256 of msg.data.\n uint slot;\n assembly {slot := aPublicKey}\n require(slot == msg.data.length - 128, \"wrong pubkey offset\");\n\n address addr = getAddress(salt, aPublicKey);\n uint codeSize = addr.code.length;\n if (codeSize > 0) {\n return BLSAccount(payable(addr));\n }\n return BLSAccount(payable(new ERC1967Proxy{salt : bytes32(salt)}(\n address(accountImplementation),\n abi.encodeCall(BLSAccount.initialize, aPublicKey)\n )));\n }\n\n /**\n * calculate the counterfactual address of this account as it would be returned by createAccount()\n */\n function getAddress(uint256 salt, uint256[4] memory aPublicKey) public view returns (address) {\n return Create2.computeAddress(bytes32(salt), keccak256(abi.encodePacked(\n type(ERC1967Proxy).creationCode,\n abi.encode(\n address(accountImplementation),\n abi.encodeCall(BLSAccount.initialize, (aPublicKey))\n )\n )));\n }\n}\n" - }, - "contracts/samples/bls/BLSHelper.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n// code taken from : https://github.com/witnet/elliptic-curve-solidity/blob/master/contracts/EllipticCurve.sol\n// missing core functions from \"thehubbleproject/bls\": jacAdd (and sum)\nlibrary BLSHelper {\n\n struct XY {\n uint x;\n uint y;\n }\n /**\n * sum all the points in the array\n * NOTE: the \"ecAdd\" (below) has a special case where x1==y2.\n * @param points an array of bytes32[2], representing an (x,y) of a point\n * @param _pp the modulus of the curve\n * @return ret the sum of all points\n */\n function sum(XY[] memory points, uint256 _pp) internal pure returns (XY memory ret){\n uint x = points[0].x;\n uint y = points[0].y;\n uint z = 1;\n\n for (uint i = 1; i < points.length; i++) {\n (x, y, z) = jacAdd(x, y, z, points[i].x, points[i].y, 1, _pp);\n }\n (x, y) = toAffine(x, y, z, _pp);\n ret.x = x;\n ret.y = y;\n }\n\n /// @dev Adds two points (x1, y1, z1) and (x2, y2, z2).\n /// @param _x1 coordinate x of P1\n /// @param _y1 coordinate y of P1\n /// @param _z1 coordinate z of P1\n /// @param _x2 coordinate x of square\n /// @param _y2 coordinate y of square\n /// @param _z2 coordinate z of square\n /// @param _pp the modulus\n /// @return (qx, qy, qz) P1+square in Jacobian\n function jacAdd(\n uint256 _x1,\n uint256 _y1,\n uint256 _z1,\n uint256 _x2,\n uint256 _y2,\n uint256 _z2,\n uint256 _pp)\n internal pure returns (uint256, uint256, uint256)\n {\n if (_x1 == 0 && _y1 == 0)\n return (_x2, _y2, _z2);\n if (_x2 == 0 && _y2 == 0)\n return (_x1, _y1, _z1);\n\n // We follow the equations described in https://pdfs.semanticscholar.org/5c64/29952e08025a9649c2b0ba32518e9a7fb5c2.pdf Section 5\n uint[4] memory zs;\n // z1^2, z1^3, z2^2, z2^3\n zs[0] = mulmod(_z1, _z1, _pp);\n zs[1] = mulmod(_z1, zs[0], _pp);\n zs[2] = mulmod(_z2, _z2, _pp);\n zs[3] = mulmod(_z2, zs[2], _pp);\n\n // u1, s1, u2, s2\n zs = [\n mulmod(_x1, zs[2], _pp),\n mulmod(_y1, zs[3], _pp),\n mulmod(_x2, zs[0], _pp),\n mulmod(_y2, zs[1], _pp)\n ];\n\n // In case of zs[0] == zs[2] && zs[1] == zs[3], double function should be used\n require(zs[0] != zs[2] || zs[1] != zs[3], \"Use jacDouble function instead\");\n\n uint[4] memory hr;\n //h\n hr[0] = addmod(zs[2], _pp - zs[0], _pp);\n //r\n hr[1] = addmod(zs[3], _pp - zs[1], _pp);\n //h^2\n hr[2] = mulmod(hr[0], hr[0], _pp);\n // h^3\n hr[3] = mulmod(hr[2], hr[0], _pp);\n // qx = -h^3 -2u1h^2+r^2\n uint256 qx = addmod(mulmod(hr[1], hr[1], _pp), _pp - hr[3], _pp);\n qx = addmod(qx, _pp - mulmod(2, mulmod(zs[0], hr[2], _pp), _pp), _pp);\n // qy = -s1*z1*h^3+r(u1*h^2 -x^3)\n uint256 qy = mulmod(hr[1], addmod(mulmod(zs[0], hr[2], _pp), _pp - qx, _pp), _pp);\n qy = addmod(qy, _pp - mulmod(zs[1], hr[3], _pp), _pp);\n // qz = h*z1*z2\n uint256 qz = mulmod(hr[0], mulmod(_z1, _z2, _pp), _pp);\n return (qx, qy, qz);\n }\n\n\n /// @dev Converts a point (x, y, z) expressed in Jacobian coordinates to affine coordinates (x', y', 1).\n /// @param _x coordinate x\n /// @param _y coordinate y\n /// @param _z coordinate z\n /// @param _pp the modulus\n /// @return (x', y') affine coordinates\n function toAffine(\n uint256 _x,\n uint256 _y,\n uint256 _z,\n uint256 _pp)\n internal pure returns (uint256, uint256)\n {\n uint256 zInv = invMod(_z, _pp);\n uint256 zInv2 = mulmod(zInv, zInv, _pp);\n uint256 x2 = mulmod(_x, zInv2, _pp);\n uint256 y2 = mulmod(_y, mulmod(zInv, zInv2, _pp), _pp);\n\n return (x2, y2);\n }\n\n\n /// @dev Modular euclidean inverse of a number (mod p).\n /// @param _x The number\n /// @param _pp The modulus\n /// @return q such that x*q = 1 (mod _pp)\n function invMod(uint256 _x, uint256 _pp) internal pure returns (uint256) {\n require(_x != 0 && _x != _pp && _pp != 0, \"Invalid number\");\n uint256 q = 0;\n uint256 newT = 1;\n uint256 r = _pp;\n uint256 t;\n while (_x != 0) {\n t = r / _x;\n (q, newT) = (newT, addmod(q, (_pp - mulmod(t, newT, _pp)), _pp));\n (r, _x) = (_x, r - t * _x);\n }\n\n return q;\n }\n\n /// @dev Doubles a point (x, y, z).\n /// @param _x coordinate x of P1\n /// @param _y coordinate y of P1\n /// @param _z coordinate z of P1\n /// @param _aa the a scalar in the curve equation\n /// @param _pp the modulus\n /// @return (qx, qy, qz) 2P in Jacobian\n function jacDouble(\n uint256 _x,\n uint256 _y,\n uint256 _z,\n uint256 _aa,\n uint256 _pp)\n internal pure returns (uint256, uint256, uint256)\n {\n if (_z == 0)\n return (_x, _y, _z);\n\n // We follow the equations described in https://pdfs.semanticscholar.org/5c64/29952e08025a9649c2b0ba32518e9a7fb5c2.pdf Section 5\n // Note: there is a bug in the paper regarding the m parameter, M=3*(x1^2)+a*(z1^4)\n // x, y, z at this point represent the squares of _x, _y, _z\n uint256 x = mulmod(_x, _x, _pp); //x1^2\n uint256 y = mulmod(_y, _y, _pp); //y1^2\n uint256 z = mulmod(_z, _z, _pp); //z1^2\n\n // s\n uint s = mulmod(4, mulmod(_x, y, _pp), _pp);\n // m\n uint m = addmod(mulmod(3, x, _pp), mulmod(_aa, mulmod(z, z, _pp), _pp), _pp);\n\n // x, y, z at this point will be reassigned and rather represent qx, qy, qz from the paper\n // This allows to reduce the gas cost and stack footprint of the algorithm\n // qx\n x = addmod(mulmod(m, m, _pp), _pp - addmod(s, s, _pp), _pp);\n // qy = -8*y1^4 + M(S-T)\n y = addmod(mulmod(m, addmod(s, _pp - x, _pp), _pp), _pp - mulmod(8, mulmod(y, y, _pp), _pp), _pp);\n // qz = 2*y1*z1\n z = mulmod(2, mulmod(_y, _z, _pp), _pp);\n\n return (x, y, z);\n }\n\n /// @dev Add two points (x1, y1) and (x2, y2) in affine coordinates.\n /// @param _x1 coordinate x of P1\n /// @param _y1 coordinate y of P1\n /// @param _x2 coordinate x of P2\n /// @param _y2 coordinate y of P2\n /// @param _aa constant of the curve\n /// @param _pp the modulus\n /// @return (qx, qy) = P1+P2 in affine coordinates\n function ecAdd(\n uint256 _x1,\n uint256 _y1,\n uint256 _x2,\n uint256 _y2,\n uint256 _aa,\n uint256 _pp)\n internal pure returns (uint256, uint256)\n {\n uint x = 0;\n uint y = 0;\n uint z = 0;\n\n // Double if x1==x2 else add\n if (_x1 == _x2) {\n // y1 = -y2 mod p\n if (addmod(_y1, _y2, _pp) == 0) {\n return (0, 0);\n } else {\n // P1 = P2\n (x, y, z) = jacDouble(\n _x1,\n _y1,\n 1,\n _aa,\n _pp);\n }\n } else {\n (x, y, z) = jacAdd(\n _x1,\n _y1,\n 1,\n _x2,\n _y2,\n 1,\n _pp);\n }\n // Get back to affine\n return toAffine(\n x,\n y,\n z,\n _pp);\n }\n\n}\n" - }, - "contracts/samples/bls/BLSSignatureAggregator.sol": { - "content": "//SPDX-License-Identifier: Unlicense\npragma solidity >=0.8.4 <0.9.0;\npragma abicoder v2;\n\nimport \"../../interfaces/IAggregator.sol\";\nimport \"../../interfaces/IEntryPoint.sol\";\nimport {BLSOpen} from \"./lib/BLSOpen.sol\";\nimport \"./IBLSAccount.sol\";\nimport \"./BLSHelper.sol\";\n\n/**\n * A BLS-based signature aggregator, to validate aggregated signature of multiple UserOps if BLSAccount\n */\ncontract BLSSignatureAggregator is IAggregator {\n using UserOperationLib for UserOperation;\n\n bytes32 public constant BLS_DOMAIN = keccak256(\"eip4337.bls.domain\");\n\n //copied from BLS.sol\n uint256 public constant N = 21888242871839275222246405745257275088696311157297823662689037894645226208583;\n\n /**\n * @return publicKey - the public key from a BLS keypair the Aggregator will use to verify this UserOp;\n * normally public key will be queried from the deployed BLSAccount itself;\n * the public key will be read from the 'initCode' if the account is not deployed yet;\n */\n function getUserOpPublicKey(UserOperation memory userOp) public view returns (uint256[4] memory publicKey) {\n bytes memory initCode = userOp.initCode;\n if (initCode.length > 0) {\n publicKey = getTrailingPublicKey(initCode);\n } else {\n return IBLSAccount(userOp.sender).getBlsPublicKey{gas : 50000}();\n }\n }\n\n /**\n * return the trailing 4 words of input data\n */\n function getTrailingPublicKey(bytes memory data) public pure returns (uint256[4] memory publicKey) {\n uint len = data.length;\n require(len > 32 * 4, \"data too short for sig\");\n\n /* solhint-disable-next-line no-inline-assembly */\n assembly {\n // actual buffer starts at data+32, so last 128 bytes start at data+32+len-128 = data+len-96\n let ofs := sub(add(data, len), 96)\n mstore(publicKey, mload(ofs))\n mstore(add(publicKey, 32), mload(add(ofs, 32)))\n mstore(add(publicKey, 64), mload(add(ofs, 64)))\n mstore(add(publicKey, 96), mload(add(ofs, 96)))\n }\n }\n\n /// @inheritdoc IAggregator\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature)\n external view override {\n require(signature.length == 64, \"BLS: invalid signature\");\n (uint256[2] memory blsSignature) = abi.decode(signature, (uint256[2]));\n\n uint userOpsLen = userOps.length;\n uint256[4][] memory blsPublicKeys = new uint256[4][](userOpsLen);\n uint256[2][] memory messages = new uint256[2][](userOpsLen);\n for (uint256 i = 0; i < userOpsLen; i++) {\n\n UserOperation memory userOp = userOps[i];\n blsPublicKeys[i] = getUserOpPublicKey(userOp);\n\n messages[i] = _userOpToMessage(userOp, _getPublicKeyHash(blsPublicKeys[i]));\n }\n require(BLSOpen.verifyMultiple(blsSignature, blsPublicKeys, messages), \"BLS: validateSignatures failed\");\n }\n\n /**\n * get a hash of userOp\n * NOTE: this hash is not the same as UserOperation.hash()\n * (slightly less efficient, since it uses memory userOp)\n */\n function internalUserOpHash(UserOperation memory userOp) internal pure returns (bytes32) {\n return keccak256(abi.encode(\n userOp.sender,\n userOp.nonce,\n keccak256(userOp.initCode),\n keccak256(userOp.callData),\n userOp.callGasLimit,\n userOp.verificationGasLimit,\n userOp.preVerificationGas,\n userOp.maxFeePerGas,\n userOp.maxPriorityFeePerGas,\n keccak256(userOp.paymasterAndData)\n ));\n }\n\n /**\n * return the BLS \"message\" for the given UserOp.\n * the account checks the signature over this value using its public key\n */\n function userOpToMessage(UserOperation memory userOp) public view returns (uint256[2] memory) {\n bytes32 publicKeyHash = _getPublicKeyHash(getUserOpPublicKey(userOp));\n return _userOpToMessage(userOp, publicKeyHash);\n }\n\n function _userOpToMessage(UserOperation memory userOp, bytes32 publicKeyHash) internal view returns (uint256[2] memory) {\n bytes32 userOpHash = _getUserOpHash(userOp, publicKeyHash);\n return BLSOpen.hashToPoint(BLS_DOMAIN, abi.encodePacked(userOpHash));\n }\n\n // helper for test\n function getUserOpHash(UserOperation memory userOp) public view returns (bytes32) {\n bytes32 publicKeyHash = _getPublicKeyHash(getUserOpPublicKey(userOp));\n return _getUserOpHash(userOp, publicKeyHash);\n }\n\n function _getUserOpHash(UserOperation memory userOp, bytes32 publicKeyHash) internal view returns (bytes32) {\n return keccak256(abi.encode(internalUserOpHash(userOp), publicKeyHash, address(this), block.chainid));\n }\n\n function _getPublicKeyHash(uint256[4] memory publicKey) internal pure returns(bytes32) {\n return keccak256(abi.encode(publicKey));\n }\n /**\n * validate signature of a single userOp\n * This method is called after EntryPoint.simulateValidation() returns an aggregator.\n * First it validates the signature over the userOp. then it return data to be used when creating the handleOps:\n * @param userOp the userOperation received from the user.\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\n * (usually empty, unless account and aggregator support some kind of \"multisig\"\n */\n function validateUserOpSignature(UserOperation calldata userOp)\n external view returns (bytes memory sigForUserOp) {\n uint256[2] memory signature = abi.decode(userOp.signature, (uint256[2]));\n uint256[4] memory pubkey = getUserOpPublicKey(userOp);\n uint256[2] memory message = _userOpToMessage(userOp, _getPublicKeyHash(pubkey));\n\n require(BLSOpen.verifySingle(signature, pubkey, message), \"BLS: wrong sig\");\n return \"\";\n }\n\n\n /**\n * aggregate multiple signatures into a single value.\n * This method is called off-chain to calculate the signature to pass with handleOps()\n * bundler MAY use optimized custom code perform this aggregation\n * @param userOps array of UserOperations to collect the signatures from.\n * @return aggregatedSignature the aggregated signature\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external pure returns (bytes memory aggregatedSignature) {\n BLSHelper.XY[] memory points = new BLSHelper.XY[](userOps.length);\n for (uint i = 0; i < points.length; i++) {\n (uint256 x, uint256 y) = abi.decode(userOps[i].signature, (uint256, uint256));\n points[i] = BLSHelper.XY(x, y);\n }\n BLSHelper.XY memory sum = BLSHelper.sum(points, N);\n return abi.encode(sum.x, sum.y);\n }\n\n /**\n * allow staking for this aggregator\n * there is no limit on stake or delay, but it is not a problem, since it is a permissionless\n * signature aggregator, which doesn't support unstaking.\n */\n function addStake(IEntryPoint entryPoint, uint32 delay) external payable {\n entryPoint.addStake{value : msg.value}(delay);\n }\n}\n" - }, - "contracts/samples/bls/IBLSAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity >=0.7.6;\n\nimport \"../../interfaces/IAccount.sol\";\n\n/**\n * a BLS account should expose its own public key.\n */\ninterface IBLSAccount is IAccount {\n event PublicKeyChanged(uint256[4] oldPublicKey, uint256[4] newPublicKey);\n\n /**\n * @return public key from a BLS keypair that is used to verify the BLS signature, both separately and aggregated.\n */\n function getBlsPublicKey() external view returns (uint256[4] memory);\n}\n" - }, - "contracts/samples/bls/lib/BLSOpen.sol": { - "content": "// SPDX-License-Identifier: MIT\npragma solidity >= 0.6.12;\n\nimport { BLS } from \"./hubble-contracts/contracts/libs/BLS.sol\";\n\nlibrary BLSOpen {\n function verifySingle(\n uint256[2] memory signature,\n uint256[4] memory pubkey,\n uint256[2] memory message\n ) external view returns (bool) {\n uint256[4][] memory pubkeys = new uint256[4][](1);\n uint256[2][] memory messages = new uint256[2][](1);\n pubkeys[0] = pubkey;\n messages[0] = message;\n\n (bool verified, bool callSuccess) = BLS.verifyMultiple(\n signature,\n pubkeys,\n messages\n );\n return callSuccess && verified;\n\n // // NB: (result, success) opposite of `call` convention (success, result).\n // (bool verified, bool callSuccess) = BLS.verifySingle(\n // signature,\n // pubkey,\n // message\n // );\n // return callSuccess && verified;\n }\n\n function verifyMultiple(\n uint256[2] memory signature,\n uint256[4][] memory pubkeys,\n uint256[2][] memory messages\n ) external view returns (bool) {\n (bool verified, bool callSuccess) = BLS.verifyMultiple(\n signature,\n pubkeys,\n messages\n );\n return callSuccess && verified;\n }\n\n function hashToPoint(\n bytes32 domain,\n bytes memory message\n ) external view returns (uint256[2] memory) {\n return BLS.hashToPoint(\n domain,\n message\n );\n }\n\n function isZeroBLSKey(uint256[4] memory blsKey) public pure returns (bool) {\n bool isZero = true;\n for (uint256 i=0; isZero && i<4; i++) {\n isZero = (blsKey[i] == 0);\n }\n return isZero;\n }\n\n}\n" - }, - "contracts/samples/bls/lib/hubble-contracts/contracts/libs/BLS.sol": { - "content": "// SPDX-License-Identifier: MIT\npragma solidity >= 0.6.12;\n\nimport { ModexpInverse, ModexpSqrt } from \"./ModExp.sol\";\nimport {\n BNPairingPrecompileCostEstimator\n} from \"./BNPairingPrecompileCostEstimator.sol\";\n\n/**\n @title Boneh–Lynn–Shacham (BLS) signature scheme on Barreto-Naehrig 254 bit curve (BN-254)\n @notice We use BLS signature aggregation to reduce the size of signature data to store on chain.\n @dev We use G1 points for signatures and messages, and G2 points for public keys\n */\nlibrary BLS {\n // Field order\n // prettier-ignore\n uint256 private constant N = 21888242871839275222246405745257275088696311157297823662689037894645226208583;\n\n // Negated genarator of G2\n // prettier-ignore\n uint256 private constant N_G2_X1 = 11559732032986387107991004021392285783925812861821192530917403151452391805634;\n // prettier-ignore\n uint256 private constant N_G2_X0 = 10857046999023057135944570762232829481370756359578518086990519993285655852781;\n // prettier-ignore\n uint256 private constant N_G2_Y1 = 17805874995975841540914202342111839520379459829704422454583296818431106115052;\n // prettier-ignore\n uint256 private constant N_G2_Y0 = 13392588948715843804641432497768002650278120570034223513918757245338268106653;\n\n // sqrt(-3)\n // prettier-ignore\n uint256 private constant Z0 = 0x0000000000000000b3c4d79d41a91759a9e4c7e359b6b89eaec68e62effffffd;\n // (sqrt(-3) - 1) / 2\n // prettier-ignore\n uint256 private constant Z1 = 0x000000000000000059e26bcea0d48bacd4f263f1acdb5c4f5763473177fffffe;\n\n // prettier-ignore\n uint256 private constant T24 = 0x1000000000000000000000000000000000000000000000000;\n // prettier-ignore\n uint256 private constant MASK24 = 0xffffffffffffffffffffffffffffffffffffffffffffffff;\n\n // estimator address\n// address private constant COST_ESTIMATOR_ADDRESS = new 0x22E4a5251C1F02de8369Dd6f192033F6CB7531A4;\n\n function verifySingle(\n uint256[2] memory signature,\n uint256[4] memory pubkey,\n uint256[2] memory message\n ) internal view returns (bool, bool) {\n uint256[12] memory input =\n [\n signature[0],\n signature[1],\n N_G2_X1,\n N_G2_X0,\n N_G2_Y1,\n N_G2_Y0,\n message[0],\n message[1],\n pubkey[1],\n pubkey[0],\n pubkey[3],\n pubkey[2]\n ];\n uint256[1] memory out;\n uint256 precompileGasCost = gasleft();\n// BNPairingPrecompileCostEstimator(COST_ESTIMATOR_ADDRESS).getGasCost(\n// 2\n// );\n bool callSuccess;\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n callSuccess := staticcall(\n precompileGasCost,\n 8,\n input,\n 384,\n out,\n 0x20\n )\n }\n if (!callSuccess) {\n return (false, false);\n }\n return (out[0] != 0, true);\n }\n\n function verifyMultiple(\n uint256[2] memory signature,\n uint256[4][] memory pubkeys,\n uint256[2][] memory messages\n ) internal view returns (bool checkResult, bool callSuccess) {\n uint256 size = pubkeys.length;\n require(size > 0, \"BLS: number of public key is zero\");\n require(\n size == messages.length,\n \"BLS: number of public keys and messages must be equal\"\n );\n uint256 inputSize = (size + 1) * 6;\n uint256[] memory input = new uint256[](inputSize);\n input[0] = signature[0];\n input[1] = signature[1];\n input[2] = N_G2_X1;\n input[3] = N_G2_X0;\n input[4] = N_G2_Y1;\n input[5] = N_G2_Y0;\n for (uint256 i = 0; i < size; i++) {\n input[i * 6 + 6] = messages[i][0];\n input[i * 6 + 7] = messages[i][1];\n input[i * 6 + 8] = pubkeys[i][1];\n input[i * 6 + 9] = pubkeys[i][0];\n input[i * 6 + 10] = pubkeys[i][3];\n input[i * 6 + 11] = pubkeys[i][2];\n }\n uint256[1] memory out;\n\n // prettier-ignore\n uint256 precompileGasCost = gasleft();\n// uint256 precompileGasCost = BNPairingPrecompileCostEstimator(COST_ESTIMATOR_ADDRESS).getGasCost(size + 1);\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n callSuccess := staticcall(\n precompileGasCost,\n 8,\n add(input, 0x20),\n mul(inputSize, 0x20),\n out,\n 0x20\n )\n }\n if (!callSuccess) {\n return (false, false);\n }\n return (out[0] != 0, true);\n }\n\n /**\n @notice Fouque-Tibouchi Hash to Curve\n */\n function hashToPoint(bytes32 domain, bytes memory message)\n internal\n view\n returns (uint256[2] memory)\n {\n uint256[2] memory u = hashToField(domain, message);\n uint256[2] memory p0 = mapToPoint(u[0]);\n uint256[2] memory p1 = mapToPoint(u[1]);\n uint256[4] memory bnAddInput;\n bnAddInput[0] = p0[0];\n bnAddInput[1] = p0[1];\n bnAddInput[2] = p1[0];\n bnAddInput[3] = p1[1];\n bool success;\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n success := staticcall(sub(gas(), 2000), 6, bnAddInput, 128, p0, 64)\n switch success\n case 0 {\n invalid()\n }\n }\n require(success, \"BLS: bn add call failed\");\n return p0;\n }\n\n function mapToPoint(uint256 _x)\n internal\n pure\n returns (uint256[2] memory p)\n {\n require(_x < N, \"mapToPointFT: invalid field element\");\n uint256 x = _x;\n\n (, bool decision) = sqrt(x);\n\n uint256 a0 = mulmod(x, x, N);\n a0 = addmod(a0, 4, N);\n uint256 a1 = mulmod(x, Z0, N);\n uint256 a2 = mulmod(a1, a0, N);\n a2 = inverse(a2);\n a1 = mulmod(a1, a1, N);\n a1 = mulmod(a1, a2, N);\n\n // x1\n a1 = mulmod(x, a1, N);\n x = addmod(Z1, N - a1, N);\n // check curve\n a1 = mulmod(x, x, N);\n a1 = mulmod(a1, x, N);\n a1 = addmod(a1, 3, N);\n bool found;\n (a1, found) = sqrt(a1);\n if (found) {\n if (!decision) {\n a1 = N - a1;\n }\n return [x, a1];\n }\n\n // x2\n x = N - addmod(x, 1, N);\n // check curve\n a1 = mulmod(x, x, N);\n a1 = mulmod(a1, x, N);\n a1 = addmod(a1, 3, N);\n (a1, found) = sqrt(a1);\n if (found) {\n if (!decision) {\n a1 = N - a1;\n }\n return [x, a1];\n }\n\n // x3\n x = mulmod(a0, a0, N);\n x = mulmod(x, x, N);\n x = mulmod(x, a2, N);\n x = mulmod(x, a2, N);\n x = addmod(x, 1, N);\n // must be on curve\n a1 = mulmod(x, x, N);\n a1 = mulmod(a1, x, N);\n a1 = addmod(a1, 3, N);\n (a1, found) = sqrt(a1);\n require(found, \"BLS: bad ft mapping implementation\");\n if (!decision) {\n a1 = N - a1;\n }\n return [x, a1];\n }\n\n function isValidSignature(uint256[2] memory signature)\n internal\n pure\n returns (bool)\n {\n if ((signature[0] >= N) || (signature[1] >= N)) {\n return false;\n } else {\n return isOnCurveG1(signature);\n }\n }\n\n function isOnCurveG1(uint256[2] memory point)\n internal\n pure\n returns (bool _isOnCurve)\n {\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n let t0 := mload(point)\n let t1 := mload(add(point, 32))\n let t2 := mulmod(t0, t0, N)\n t2 := mulmod(t2, t0, N)\n t2 := addmod(t2, 3, N)\n t1 := mulmod(t1, t1, N)\n _isOnCurve := eq(t1, t2)\n }\n }\n\n function isOnCurveG2(uint256[4] memory point)\n internal\n pure\n returns (bool _isOnCurve)\n {\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n // x0, x1\n let t0 := mload(point)\n let t1 := mload(add(point, 32))\n // x0 ^ 2\n let t2 := mulmod(t0, t0, N)\n // x1 ^ 2\n let t3 := mulmod(t1, t1, N)\n // 3 * x0 ^ 2\n let t4 := add(add(t2, t2), t2)\n // 3 * x1 ^ 2\n let t5 := addmod(add(t3, t3), t3, N)\n // x0 * (x0 ^ 2 - 3 * x1 ^ 2)\n t2 := mulmod(add(t2, sub(N, t5)), t0, N)\n // x1 * (3 * x0 ^ 2 - x1 ^ 2)\n t3 := mulmod(add(t4, sub(N, t3)), t1, N)\n\n // x ^ 3 + b\n t0 := addmod(\n t2,\n 0x2b149d40ceb8aaae81be18991be06ac3b5b4c5e559dbefa33267e6dc24a138e5,\n N\n )\n t1 := addmod(\n t3,\n 0x009713b03af0fed4cd2cafadeed8fdf4a74fa084e52d1852e4a2bd0685c315d2,\n N\n )\n\n // y0, y1\n t2 := mload(add(point, 64))\n t3 := mload(add(point, 96))\n // y ^ 2\n t4 := mulmod(addmod(t2, t3, N), addmod(t2, sub(N, t3), N), N)\n t3 := mulmod(shl(1, t2), t3, N)\n\n // y ^ 2 == x ^ 3 + b\n _isOnCurve := and(eq(t0, t4), eq(t1, t3))\n }\n }\n\n function sqrt(uint256 xx) internal pure returns (uint256 x, bool hasRoot) {\n x = ModexpSqrt.run(xx);\n hasRoot = mulmod(x, x, N) == xx;\n }\n\n function inverse(uint256 a) internal pure returns (uint256) {\n return ModexpInverse.run(a);\n }\n\n function hashToField(bytes32 domain, bytes memory messages)\n internal\n pure\n returns (uint256[2] memory)\n {\n bytes memory _msg = expandMsgTo96(domain, messages);\n uint256 u0;\n uint256 u1;\n uint256 a0;\n uint256 a1;\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n let p := add(_msg, 24)\n u1 := and(mload(p), MASK24)\n p := add(_msg, 48)\n u0 := and(mload(p), MASK24)\n a0 := addmod(mulmod(u1, T24, N), u0, N)\n p := add(_msg, 72)\n u1 := and(mload(p), MASK24)\n p := add(_msg, 96)\n u0 := and(mload(p), MASK24)\n a1 := addmod(mulmod(u1, T24, N), u0, N)\n }\n return [a0, a1];\n }\n\n function expandMsgTo96(bytes32 domain, bytes memory message)\n internal\n pure\n returns (bytes memory)\n {\n // zero<64>|msg|lib_str<2>|I2OSP(0, 1)<1>|dst|dst_len<1>\n uint256 t0 = message.length;\n bytes memory msg0 = new bytes(32 + t0 + 64 + 4);\n bytes memory out = new bytes(96);\n // b0\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n let p := add(msg0, 96)\n for {\n let z := 0\n } lt(z, t0) {\n z := add(z, 32)\n } {\n mstore(add(p, z), mload(add(message, add(z, 32))))\n }\n p := add(p, t0)\n\n mstore8(p, 0)\n p := add(p, 1)\n mstore8(p, 96)\n p := add(p, 1)\n mstore8(p, 0)\n p := add(p, 1)\n\n mstore(p, domain)\n p := add(p, 32)\n mstore8(p, 32)\n }\n bytes32 b0 = sha256(msg0);\n bytes32 bi;\n t0 = 32 + 34;\n\n // resize intermediate message\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n mstore(msg0, t0)\n }\n\n // b1\n\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n mstore(add(msg0, 32), b0)\n mstore8(add(msg0, 64), 1)\n mstore(add(msg0, 65), domain)\n mstore8(add(msg0, add(32, 65)), 32)\n }\n\n bi = sha256(msg0);\n\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n mstore(add(out, 32), bi)\n }\n\n // b2\n\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n let t := xor(b0, bi)\n mstore(add(msg0, 32), t)\n mstore8(add(msg0, 64), 2)\n mstore(add(msg0, 65), domain)\n mstore8(add(msg0, add(32, 65)), 32)\n }\n\n bi = sha256(msg0);\n\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n mstore(add(out, 64), bi)\n }\n\n // b3\n\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n let t := xor(b0, bi)\n mstore(add(msg0, 32), t)\n mstore8(add(msg0, 64), 3)\n mstore(add(msg0, 65), domain)\n mstore8(add(msg0, add(32, 65)), 32)\n }\n\n bi = sha256(msg0);\n\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n mstore(add(out, 96), bi)\n }\n\n return out;\n }\n}\n" - }, - "contracts/samples/bls/lib/hubble-contracts/contracts/libs/BNPairingPrecompileCostEstimator.sol": { - "content": "// SPDX-License-Identifier: MIT\npragma solidity >=0.6.12;\n\ncontract BNPairingPrecompileCostEstimator {\n uint256 public baseCost;\n uint256 public perPairCost;\n\n // G1 Generator\n uint256 private constant G1_X = 1;\n uint256 private constant G1_Y = 2;\n\n // G2 genarator\n // prettier-ignore\n uint256 private constant G2_X0 = 10857046999023057135944570762232829481370756359578518086990519993285655852781;\n // prettier-ignore\n uint256 private constant G2_X1 = 11559732032986387107991004021392285783925812861821192530917403151452391805634;\n // prettier-ignore\n uint256 private constant G2_Y0 = 8495653923123431417604973247489272438418190587263600148770280649306958101930;\n // prettier-ignore\n uint256 private constant G2_Y1 = 4082367875863433681332203403145435568316851327593401208105741076214120093531;\n\n // G2 negated genarator y coordinates\n // prettier-ignore\n uint256 private constant N_G2_Y0 = 13392588948715843804641432497768002650278120570034223513918757245338268106653;\n // prettier-ignore\n uint256 private constant N_G2_Y1 = 17805874995975841540914202342111839520379459829704422454583296818431106115052;\n\n function run() external {\n _run();\n }\n\n function getGasCost(uint256 pairCount) external view returns (uint256) {\n return pairCount * perPairCost + baseCost;\n }\n\n function _run() internal {\n uint256 gasCost1Pair = _gasCost1Pair();\n uint256 gasCost2Pair = _gasCost2Pair();\n perPairCost = gasCost2Pair - gasCost1Pair;\n baseCost = gasCost1Pair - perPairCost;\n }\n\n function _gasCost1Pair() internal view returns (uint256) {\n uint256[6] memory input = [G1_X, G1_Y, G2_X1, G2_X0, G2_Y1, G2_Y0];\n uint256[1] memory out;\n bool callSuccess;\n uint256 suppliedGas = gasleft() - 2000;\n require(\n gasleft() > 2000,\n \"BNPairingPrecompileCostEstimator: not enough gas, single pair\"\n );\n uint256 gasT0 = gasleft();\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n callSuccess := staticcall(suppliedGas, 8, input, 192, out, 0x20)\n }\n uint256 gasCost = gasT0 - gasleft();\n require(\n callSuccess,\n \"BNPairingPrecompileCostEstimator: single pair call is failed\"\n );\n require(\n out[0] == 0,\n \"BNPairingPrecompileCostEstimator: single pair call result must be 0\"\n );\n return gasCost;\n }\n\n function _gasCost2Pair() internal view returns (uint256) {\n uint256[12] memory input =\n [\n G1_X,\n G1_Y,\n G2_X1,\n G2_X0,\n G2_Y1,\n G2_Y0,\n G1_X,\n G1_Y,\n G2_X1,\n G2_X0,\n N_G2_Y1,\n N_G2_Y0\n ];\n uint256[1] memory out;\n bool callSuccess;\n uint256 suppliedGas = gasleft() - 2000;\n require(\n gasleft() > 2000,\n \"BNPairingPrecompileCostEstimator: not enough gas, couple pair\"\n );\n uint256 gasT0 = gasleft();\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n callSuccess := staticcall(suppliedGas, 8, input, 384, out, 0x20)\n }\n uint256 gasCost = gasT0 - gasleft();\n require(\n callSuccess,\n \"BNPairingPrecompileCostEstimator: couple pair call is failed\"\n );\n require(\n out[0] == 1,\n \"BNPairingPrecompileCostEstimator: couple pair call result must be 1\"\n );\n return gasCost;\n }\n}\n" - }, - "contracts/samples/bls/lib/hubble-contracts/contracts/libs/ModExp.sol": { - "content": "// SPDX-License-Identifier: MIT\npragma solidity >= 0.6.12;\n\n/**\n @title Compute Inverse by Modular Exponentiation\n @notice Compute $input^(N - 2) mod N$ using Addition Chain method.\n Where N = 0x30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47\n and N - 2 = 0x30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd45\n @dev the function body is generated with the modified addchain script\n see https://github.com/kobigurk/addchain/commit/2c37a2ace567a9bdc680b4e929c94aaaa3ec700f\n */\nlibrary ModexpInverse {\n function run(uint256 t2) internal pure returns (uint256 t0) {\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n let\n n\n := 0x30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47\n t0 := mulmod(t2, t2, n)\n let t5 := mulmod(t0, t2, n)\n let t1 := mulmod(t5, t0, n)\n let t3 := mulmod(t5, t5, n)\n let t8 := mulmod(t1, t0, n)\n let t4 := mulmod(t3, t5, n)\n let t6 := mulmod(t3, t1, n)\n t0 := mulmod(t3, t3, n)\n let t7 := mulmod(t8, t3, n)\n t3 := mulmod(t4, t3, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t7, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t1, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t1, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t7, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t1, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t1, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t1, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t1, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t4, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t1, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t7, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t3, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t3, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t4, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t3, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t1, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t1, n)\n }\n }\n}\n\n/**\n @title Compute Squre Root by Modular Exponentiation\n @notice Compute $input^{(N + 1) / 4} mod N$ using Addition Chain method.\n Where N = 0x30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47\n and (N + 1) / 4 = 0xc19139cb84c680a6e14116da060561765e05aa45a1c72a34f082305b61f3f52\n */\nlibrary ModexpSqrt {\n function run(uint256 t6) internal pure returns (uint256 t0) {\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n let\n n\n := 0x30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47\n\n t0 := mulmod(t6, t6, n)\n let t4 := mulmod(t0, t6, n)\n let t2 := mulmod(t4, t0, n)\n let t3 := mulmod(t4, t4, n)\n let t8 := mulmod(t2, t0, n)\n let t1 := mulmod(t3, t4, n)\n let t5 := mulmod(t3, t2, n)\n t0 := mulmod(t3, t3, n)\n let t7 := mulmod(t8, t3, n)\n t3 := mulmod(t1, t3, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t4, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t4, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t7, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t4, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t7, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t4, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t4, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t1, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t8, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t7, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t3, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t6, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t4, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t5, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t4, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t4, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t3, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t1, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t3, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t2, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t0, n)\n t0 := mulmod(t0, t1, n)\n t0 := mulmod(t0, t0, n)\n }\n }\n}\n" - }, - "contracts/samples/callback/TokenCallbackHandler.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-empty-blocks */\n\nimport \"@openzeppelin/contracts/utils/introspection/IERC165.sol\";\nimport \"@openzeppelin/contracts/token/ERC777/IERC777Recipient.sol\";\nimport \"@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol\";\nimport \"@openzeppelin/contracts/token/ERC1155/IERC1155Receiver.sol\";\n\n/**\n * Token callback handler.\n * Handles supported tokens' callbacks, allowing account receiving these tokens.\n */\ncontract TokenCallbackHandler is IERC777Recipient, IERC721Receiver, IERC1155Receiver {\n function tokensReceived(\n address,\n address,\n address,\n uint256,\n bytes calldata,\n bytes calldata\n ) external pure override {\n }\n\n function onERC721Received(\n address,\n address,\n uint256,\n bytes calldata\n ) external pure override returns (bytes4) {\n return IERC721Receiver.onERC721Received.selector;\n }\n\n function onERC1155Received(\n address,\n address,\n uint256,\n uint256,\n bytes calldata\n ) external pure override returns (bytes4) {\n return IERC1155Receiver.onERC1155Received.selector;\n }\n\n function onERC1155BatchReceived(\n address,\n address,\n uint256[] calldata,\n uint256[] calldata,\n bytes calldata\n ) external pure override returns (bytes4) {\n return IERC1155Receiver.onERC1155BatchReceived.selector;\n }\n\n function supportsInterface(bytes4 interfaceId) external view virtual override returns (bool) {\n return\n interfaceId == type(IERC721Receiver).interfaceId ||\n interfaceId == type(IERC1155Receiver).interfaceId ||\n interfaceId == type(IERC165).interfaceId;\n }\n}\n" - }, - "contracts/samples/DepositPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable reason-string */\n\nimport \"@openzeppelin/contracts/token/ERC20/IERC20.sol\";\nimport \"@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol\";\n\nimport \"../core/BasePaymaster.sol\";\nimport \"./IOracle.sol\";\n\n/**\n * A token-based paymaster that accepts token deposits\n * The deposit is only a safeguard: the user pays with his token balance.\n * only if the user didn't approve() the paymaster, or if the token balance is not enough, the deposit will be used.\n * thus the required deposit is to cover just one method call.\n * The deposit is locked for the current block: the user must issue unlockTokenDeposit() to be allowed to withdraw\n * (but can't use the deposit for this or further operations)\n *\n * paymasterAndData holds the paymaster address followed by the token address to use.\n * @notice This paymaster will be rejected by the standard rules of EIP4337, as it uses an external oracle.\n * (the standard rules ban accessing data of an external contract)\n * It can only be used if it is \"whitelisted\" by the bundler.\n * (technically, it can be used by an \"oracle\" which returns a static value, without accessing any storage)\n */\ncontract DepositPaymaster is BasePaymaster {\n\n using UserOperationLib for UserOperation;\n using SafeERC20 for IERC20;\n\n //calculated cost of the postOp\n uint256 constant public COST_OF_POST = 35000;\n\n IOracle private constant NULL_ORACLE = IOracle(address(0));\n mapping(IERC20 => IOracle) public oracles;\n mapping(IERC20 => mapping(address => uint256)) public balances;\n mapping(address => uint256) public unlockBlock;\n\n constructor(IEntryPoint _entryPoint) BasePaymaster(_entryPoint) {\n //owner account is unblocked, to allow withdraw of paid tokens;\n unlockTokenDeposit();\n }\n\n /**\n * owner of the paymaster should add supported tokens\n */\n function addToken(IERC20 token, IOracle tokenPriceOracle) external onlyOwner {\n require(oracles[token] == NULL_ORACLE, \"Token already set\");\n oracles[token] = tokenPriceOracle;\n }\n\n /**\n * deposit tokens that a specific account can use to pay for gas.\n * The sender must first approve this paymaster to withdraw these tokens (they are only withdrawn in this method).\n * Note depositing the tokens is equivalent to transferring them to the \"account\" - only the account can later\n * use them - either as gas, or using withdrawTo()\n *\n * @param token the token to deposit.\n * @param account the account to deposit for.\n * @param amount the amount of token to deposit.\n */\n function addDepositFor(IERC20 token, address account, uint256 amount) external {\n //(sender must have approval for the paymaster)\n token.safeTransferFrom(msg.sender, address(this), amount);\n require(oracles[token] != NULL_ORACLE, \"unsupported token\");\n balances[token][account] += amount;\n if (msg.sender == account) {\n lockTokenDeposit();\n }\n }\n\n /**\n * @return amount - the amount of given token deposited to the Paymaster.\n * @return _unlockBlock - the block height at which the deposit can be withdrawn.\n */\n function depositInfo(IERC20 token, address account) public view returns (uint256 amount, uint256 _unlockBlock) {\n amount = balances[token][account];\n _unlockBlock = unlockBlock[account];\n }\n\n /**\n * unlock deposit, so that it can be withdrawn.\n * can't be called in the same block as withdrawTo()\n */\n function unlockTokenDeposit() public {\n unlockBlock[msg.sender] = block.number;\n }\n\n /**\n * lock the tokens deposited for this account so they can be used to pay for gas.\n * after calling unlockTokenDeposit(), the account can't use this paymaster until the deposit is locked.\n */\n function lockTokenDeposit() public {\n unlockBlock[msg.sender] = 0;\n }\n\n /**\n * withdraw tokens.\n * can only be called after unlock() is called in a previous block.\n * @param token the token deposit to withdraw\n * @param target address to send to\n * @param amount amount to withdraw\n */\n function withdrawTokensTo(IERC20 token, address target, uint256 amount) public {\n require(unlockBlock[msg.sender] != 0 && block.number > unlockBlock[msg.sender], \"DepositPaymaster: must unlockTokenDeposit\");\n balances[token][msg.sender] -= amount;\n token.safeTransfer(target, amount);\n }\n\n /**\n * translate the given eth value to token amount\n * @param token the token to use\n * @param ethBought the required eth value we want to \"buy\"\n * @return requiredTokens the amount of tokens required to get this amount of eth\n */\n function getTokenValueOfEth(IERC20 token, uint256 ethBought) internal view virtual returns (uint256 requiredTokens) {\n IOracle oracle = oracles[token];\n require(oracle != NULL_ORACLE, \"DepositPaymaster: unsupported token\");\n return oracle.getTokenValueOfEth(ethBought);\n }\n\n /**\n * Validate the request:\n * The sender should have enough deposit to pay the max possible cost.\n * Note that the sender's balance is not checked. If it fails to pay from its balance,\n * this deposit will be used to compensate the paymaster for the transaction.\n */\n function _validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n internal view override returns (bytes memory context, uint256 validationData) {\n\n (userOpHash);\n // verificationGasLimit is dual-purposed, as gas limit for postOp. make sure it is high enough\n require(userOp.verificationGasLimit > COST_OF_POST, \"DepositPaymaster: gas too low for postOp\");\n\n bytes calldata paymasterAndData = userOp.paymasterAndData;\n require(paymasterAndData.length == 20+20, \"DepositPaymaster: paymasterAndData must specify token\");\n IERC20 token = IERC20(address(bytes20(paymasterAndData[20:])));\n address account = userOp.getSender();\n uint256 maxTokenCost = getTokenValueOfEth(token, maxCost);\n uint256 gasPriceUserOp = userOp.gasPrice();\n require(unlockBlock[account] == 0, \"DepositPaymaster: deposit not locked\");\n require(balances[token][account] >= maxTokenCost, \"DepositPaymaster: deposit too low\");\n return (abi.encode(account, token, gasPriceUserOp, maxTokenCost, maxCost),0);\n }\n\n /**\n * perform the post-operation to charge the sender for the gas.\n * in normal mode, use transferFrom to withdraw enough tokens from the sender's balance.\n * in case the transferFrom fails, the _postOp reverts and the entryPoint will call it again,\n * this time in *postOpReverted* mode.\n * In this mode, we use the deposit to pay (which we validated to be large enough)\n */\n function _postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) internal override {\n\n (address account, IERC20 token, uint256 gasPricePostOp, uint256 maxTokenCost, uint256 maxCost) = abi.decode(context, (address, IERC20, uint256, uint256, uint256));\n //use same conversion rate as used for validation.\n uint256 actualTokenCost = (actualGasCost + COST_OF_POST * gasPricePostOp) * maxTokenCost / maxCost;\n if (mode != PostOpMode.postOpReverted) {\n // attempt to pay with tokens:\n token.safeTransferFrom(account, address(this), actualTokenCost);\n } else {\n //in case above transferFrom failed, pay with deposit:\n balances[token][account] -= actualTokenCost;\n }\n balances[token][owner()] += actualTokenCost;\n }\n}\n" - }, - "contracts/samples/gnosis/EIP4337Fallback.sol": { - "content": "//SPDX-License-Identifier: GPL\npragma solidity ^0.8.7;\n\n/* solhint-disable no-inline-assembly */\n\nimport \"@gnosis.pm/safe-contracts/contracts/handler/DefaultCallbackHandler.sol\";\nimport \"@gnosis.pm/safe-contracts/contracts/GnosisSafe.sol\";\nimport \"@openzeppelin/contracts/interfaces/IERC1271.sol\";\nimport \"@openzeppelin/contracts/utils/cryptography/ECDSA.sol\";\nimport \"../../interfaces/IAccount.sol\";\nimport \"./EIP4337Manager.sol\";\n\nusing ECDSA for bytes32;\n\n/**\n * The GnosisSafe enables adding custom functions implementation to the Safe by setting a 'fallbackHandler'.\n * This 'fallbackHandler' adds an implementation of 'validateUserOp' to the GnosisSafe.\n * Note that the implementation of the 'validateUserOp' method is located in the EIP4337Manager.\n * Upon receiving the 'validateUserOp', a Safe with EIP4337Fallback enabled makes a 'delegatecall' to EIP4337Manager.\n */\ncontract EIP4337Fallback is DefaultCallbackHandler, IAccount, IERC1271 {\n bytes4 internal constant ERC1271_MAGIC_VALUE = 0x1626ba7e;\n\n address immutable public eip4337manager;\n constructor(address _eip4337manager) {\n eip4337manager = _eip4337manager;\n }\n\n /**\n * delegate the contract call to the EIP4337Manager\n */\n function delegateToManager() internal returns (bytes memory) {\n // delegate entire msg.data (including the appended \"msg.sender\") to the EIP4337Manager\n // will work only for GnosisSafe contracts\n GnosisSafe safe = GnosisSafe(payable(msg.sender));\n (bool success, bytes memory ret) = safe.execTransactionFromModuleReturnData(eip4337manager, 0, msg.data, Enum.Operation.DelegateCall);\n if (!success) {\n assembly {\n revert(add(ret, 32), mload(ret))\n }\n }\n return ret;\n }\n\n /**\n * called from the Safe. delegate actual work to EIP4337Manager\n */\n function validateUserOp(UserOperation calldata, bytes32, uint256) override external returns (uint256 deadline){\n bytes memory ret = delegateToManager();\n return abi.decode(ret, (uint256));\n }\n\n /**\n * Helper for wallet to get the next nonce.\n */\n function getNonce() public returns (uint256 nonce) {\n bytes memory ret = delegateToManager();\n (nonce) = abi.decode(ret, (uint256));\n }\n\n /**\n * called from the Safe. delegate actual work to EIP4337Manager\n */\n function executeAndRevert(\n address,\n uint256,\n bytes memory,\n Enum.Operation\n ) external {\n delegateToManager();\n }\n\n function isValidSignature(\n bytes32 _hash,\n bytes memory _signature\n ) external override view returns (bytes4) {\n bytes32 hash = _hash.toEthSignedMessageHash();\n address recovered = hash.recover(_signature);\n\n GnosisSafe safe = GnosisSafe(payable(address(msg.sender)));\n\n // Validate signatures\n if (safe.isOwner(recovered)) {\n return ERC1271_MAGIC_VALUE;\n } else {\n return 0xffffffff;\n }\n }\n}\n" - }, - "contracts/samples/gnosis/EIP4337Manager.sol": { - "content": "//SPDX-License-Identifier: GPL\npragma solidity ^0.8.7;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"@openzeppelin/contracts/utils/cryptography/ECDSA.sol\";\nimport \"@gnosis.pm/safe-contracts/contracts/GnosisSafe.sol\";\nimport \"@gnosis.pm/safe-contracts/contracts/base/Executor.sol\";\nimport \"@gnosis.pm/safe-contracts/contracts/examples/libraries/GnosisSafeStorage.sol\";\nimport \"./EIP4337Fallback.sol\";\nimport \"../../interfaces/IAccount.sol\";\nimport \"../../interfaces/IEntryPoint.sol\";\nimport \"../../utils/Exec.sol\";\n\n using ECDSA for bytes32;\n\n/**\n * Main EIP4337 module.\n * Called (through the fallback module) using \"delegate\" from the GnosisSafe as an \"IAccount\",\n * so must implement validateUserOp\n * holds an immutable reference to the EntryPoint\n * Inherits GnosisSafe so that it can reference the memory storage\n */\ncontract EIP4337Manager is IAccount, GnosisSafeStorage, Executor {\n\n address public immutable eip4337Fallback;\n address public immutable entryPoint;\n\n // return value in case of signature failure, with no time-range.\n // equivalent to _packValidationData(true,0,0);\n uint256 constant internal SIG_VALIDATION_FAILED = 1;\n\n address internal constant SENTINEL_MODULES = address(0x1);\n\n constructor(address anEntryPoint) {\n entryPoint = anEntryPoint;\n eip4337Fallback = address(new EIP4337Fallback(address(this)));\n }\n\n /**\n * delegate-called (using execFromModule) through the fallback, so \"real\" msg.sender is attached as last 20 bytes\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external override returns (uint256 validationData) {\n address msgSender = address(bytes20(msg.data[msg.data.length - 20 :]));\n require(msgSender == entryPoint, \"account: not from entrypoint\");\n\n GnosisSafe pThis = GnosisSafe(payable(address(this)));\n bytes32 hash = userOpHash.toEthSignedMessageHash();\n address recovered = hash.recover(userOp.signature);\n require(threshold == 1, \"account: only threshold 1\");\n if (!pThis.isOwner(recovered)) {\n validationData = SIG_VALIDATION_FAILED;\n }\n\n // mimic normal Safe nonce behaviour: prevent parallel nonces\n require(userOp.nonce < type(uint64).max, \"account: nonsequential nonce\");\n\n if (missingAccountFunds > 0) {\n //Note: MAY pay more than the minimum, to deposit for future transactions\n (bool success,) = payable(msgSender).call{value : missingAccountFunds}(\"\");\n (success);\n //ignore failure (its EntryPoint's job to verify, not account.)\n }\n }\n\n /**\n * Execute a call but also revert if the execution fails.\n * The default behavior of the Safe is to not revert if the call fails,\n * which is challenging for integrating with ERC4337 because then the\n * EntryPoint wouldn't know to emit the UserOperationRevertReason event,\n * which the frontend/client uses to capture the reason for the failure.\n */\n function executeAndRevert(\n address to,\n uint256 value,\n bytes memory data,\n Enum.Operation operation\n ) external {\n address msgSender = address(bytes20(msg.data[msg.data.length - 20 :]));\n require(msgSender == entryPoint, \"account: not from entrypoint\");\n require(msg.sender == eip4337Fallback, \"account: not from EIP4337Fallback\");\n\n bool success = execute(\n to,\n value,\n data,\n operation,\n type(uint256).max\n );\n\n bytes memory returnData = Exec.getReturnData(type(uint256).max);\n // Revert with the actual reason string\n // Adopted from: https://github.com/Uniswap/v3-periphery/blob/464a8a49611272f7349c970e0fadb7ec1d3c1086/contracts/base/Multicall.sol#L16-L23\n if (!success) {\n if (returnData.length < 68) revert();\n assembly {\n returnData := add(returnData, 0x04)\n }\n revert(abi.decode(returnData, (string)));\n }\n }\n\n /**\n * Helper for wallet to get the next nonce.\n */\n function getNonce() public view returns (uint256) {\n return IEntryPoint(entryPoint).getNonce(address(this), 0);\n }\n\n /**\n * set up a safe as EIP-4337 enabled.\n * called from the GnosisSafeAccountFactory during construction time\n * - enable 3 modules (this module, fallback and the entrypoint)\n * - this method is called with delegateCall, so the module (usually itself) is passed as parameter, and \"this\" is the safe itself\n */\n function setup4337Modules(\n EIP4337Manager manager //the manager (this contract)\n ) external {\n GnosisSafe safe = GnosisSafe(payable(address(this)));\n require(!safe.isModuleEnabled(manager.entryPoint()), \"setup4337Modules: entrypoint already enabled\");\n require(!safe.isModuleEnabled(manager.eip4337Fallback()), \"setup4337Modules: eip4337Fallback already enabled\");\n safe.enableModule(manager.entryPoint());\n safe.enableModule(manager.eip4337Fallback());\n }\n\n /**\n * replace EIP4337 module, to support a new EntryPoint.\n * must be called using execTransaction and Enum.Operation.DelegateCall\n * @param prevModule returned by getCurrentEIP4337Manager\n * @param oldManager the old EIP4337 manager to remove, returned by getCurrentEIP4337Manager\n * @param newManager the new EIP4337Manager, usually with a new EntryPoint\n */\n function replaceEIP4337Manager(address prevModule, EIP4337Manager oldManager, EIP4337Manager newManager) public {\n GnosisSafe pThis = GnosisSafe(payable(address(this)));\n address oldFallback = oldManager.eip4337Fallback();\n require(pThis.isModuleEnabled(oldFallback), \"replaceEIP4337Manager: oldManager is not active\");\n pThis.disableModule(oldFallback, oldManager.entryPoint());\n pThis.disableModule(prevModule, oldFallback);\n\n address eip4337fallback = newManager.eip4337Fallback();\n\n pThis.enableModule(newManager.entryPoint());\n pThis.enableModule(eip4337fallback);\n pThis.setFallbackHandler(eip4337fallback);\n\n validateEip4337(pThis, newManager);\n }\n\n /**\n * Validate this gnosisSafe is callable through the EntryPoint.\n * the test is might be incomplete: we check that we reach our validateUserOp and fail on signature.\n * we don't test full transaction\n */\n function validateEip4337(GnosisSafe safe, EIP4337Manager manager) public {\n\n // this prevents mistaken replaceEIP4337Manager to disable the module completely.\n // minimal signature that pass \"recover\"\n bytes memory sig = new bytes(65);\n sig[64] = bytes1(uint8(27));\n sig[2] = bytes1(uint8(1));\n sig[35] = bytes1(uint8(1));\n uint256 nonce = uint256(IEntryPoint(manager.entryPoint()).getNonce(address(safe), 0));\n UserOperation memory userOp = UserOperation(address(safe), nonce, \"\", \"\", 0, 1000000, 0, 0, 0, \"\", sig);\n UserOperation[] memory userOps = new UserOperation[](1);\n userOps[0] = userOp;\n IEntryPoint _entryPoint = IEntryPoint(payable(manager.entryPoint()));\n try _entryPoint.handleOps(userOps, payable(msg.sender)) {\n revert(\"validateEip4337: handleOps must fail\");\n } catch (bytes memory error) {\n if (keccak256(error) != keccak256(abi.encodeWithSignature(\"FailedOp(uint256,string)\", 0, \"AA24 signature error\"))) {\n revert(string(error));\n }\n }\n }\n /**\n * enumerate modules, and find the currently active EIP4337 manager (and previous module)\n * @return prev prev module, needed by replaceEIP4337Manager\n * @return manager the current active EIP4337Manager\n */\n function getCurrentEIP4337Manager(GnosisSafe safe) public view returns (address prev, address manager) {\n prev = address(SENTINEL_MODULES);\n (address[] memory modules,) = safe.getModulesPaginated(SENTINEL_MODULES, 100);\n for (uint i = 0; i < modules.length; i++) {\n address module = modules[i];\n try EIP4337Fallback(module).eip4337manager() returns (address _manager) {\n return (prev, _manager);\n }\n // solhint-disable-next-line no-empty-blocks\n catch {}\n prev = module;\n }\n return (address(0), address(0));\n }\n}\n" - }, - "contracts/samples/gnosis/GnosisAccountFactory.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"@openzeppelin/contracts/utils/Create2.sol\";\nimport \"@gnosis.pm/safe-contracts/contracts/proxies/GnosisSafeProxyFactory.sol\";\nimport \"./EIP4337Manager.sol\";\n\n/**\n * A wrapper factory contract to deploy GnosisSafe as an ERC-4337 account contract.\n */\ncontract GnosisSafeAccountFactory {\n\n GnosisSafeProxyFactory public immutable proxyFactory;\n address public immutable safeSingleton;\n EIP4337Manager public immutable eip4337Manager;\n\n constructor(GnosisSafeProxyFactory _proxyFactory, address _safeSingleton, EIP4337Manager _eip4337Manager) {\n proxyFactory = _proxyFactory;\n safeSingleton = _safeSingleton;\n eip4337Manager = _eip4337Manager;\n }\n\n function createAccount(address owner,uint256 salt) public returns (address) {\n address addr = getAddress(owner, salt);\n uint codeSize = addr.code.length;\n if (codeSize > 0) {\n return addr;\n }\n return address(proxyFactory.createProxyWithNonce(\n safeSingleton, getInitializer(owner), salt));\n }\n\n function getInitializer(address owner) internal view returns (bytes memory) {\n address[] memory owners = new address[](1);\n owners[0] = owner;\n uint threshold = 1;\n address eip4337fallback = eip4337Manager.eip4337Fallback();\n\n bytes memory setup4337Modules = abi.encodeCall(\n EIP4337Manager.setup4337Modules, (eip4337Manager));\n\n return abi.encodeCall(GnosisSafe.setup, (\n owners, threshold,\n address (eip4337Manager), setup4337Modules,\n eip4337fallback,\n address(0), 0, payable(0) //no payment receiver\n ));\n }\n\n /**\n * calculate the counterfactual address of this account as it would be returned by createAccount()\n * (uses the same \"create2 signature\" used by GnosisSafeProxyFactory.createProxyWithNonce)\n */\n function getAddress(address owner,uint256 salt) public view returns (address) {\n bytes memory initializer = getInitializer(owner);\n //copied from deployProxyWithNonce\n bytes32 salt2 = keccak256(abi.encodePacked(keccak256(initializer), salt));\n bytes memory deploymentData = abi.encodePacked(proxyFactory.proxyCreationCode(), uint256(uint160(safeSingleton)));\n return Create2.computeAddress(bytes32(salt2), keccak256(deploymentData), address (proxyFactory));\n }\n}\n" - }, - "contracts/samples/IOracle.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\ninterface IOracle {\n\n /**\n * return amount of tokens that are required to receive that much eth.\n */\n function getTokenValueOfEth(uint256 ethOutput) external view returns (uint256 tokenInput);\n}\n\n" - }, - "contracts/samples/SimpleAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"@openzeppelin/contracts/utils/cryptography/ECDSA.sol\";\nimport \"@openzeppelin/contracts/proxy/utils/Initializable.sol\";\nimport \"@openzeppelin/contracts/proxy/utils/UUPSUpgradeable.sol\";\n\nimport \"../core/BaseAccount.sol\";\nimport \"./callback/TokenCallbackHandler.sol\";\n\n/**\n * minimal account.\n * this is sample minimal account.\n * has execute, eth handling methods\n * has a single signer that can send requests through the entryPoint.\n */\ncontract SimpleAccount is BaseAccount, TokenCallbackHandler, UUPSUpgradeable, Initializable {\n using ECDSA for bytes32;\n\n address public owner;\n\n IEntryPoint private immutable _entryPoint;\n\n event SimpleAccountInitialized(IEntryPoint indexed entryPoint, address indexed owner);\n\n modifier onlyOwner() {\n _onlyOwner();\n _;\n }\n\n /// @inheritdoc BaseAccount\n function entryPoint() public view virtual override returns (IEntryPoint) {\n return _entryPoint;\n }\n\n\n // solhint-disable-next-line no-empty-blocks\n receive() external payable {}\n\n constructor(IEntryPoint anEntryPoint) {\n _entryPoint = anEntryPoint;\n _disableInitializers();\n }\n\n function _onlyOwner() internal view {\n //directly from EOA owner, or through the account itself (which gets redirected through execute())\n require(msg.sender == owner || msg.sender == address(this), \"only owner\");\n }\n\n /**\n * execute a transaction (called directly from owner, or by entryPoint)\n */\n function execute(address dest, uint256 value, bytes calldata func) external {\n _requireFromEntryPointOrOwner();\n _call(dest, value, func);\n }\n\n /**\n * execute a sequence of transactions\n */\n function executeBatch(address[] calldata dest, bytes[] calldata func) external {\n _requireFromEntryPointOrOwner();\n require(dest.length == func.length, \"wrong array lengths\");\n for (uint256 i = 0; i < dest.length; i++) {\n _call(dest[i], 0, func[i]);\n }\n }\n\n /**\n * @dev The _entryPoint member is immutable, to reduce gas consumption. To upgrade EntryPoint,\n * a new implementation of SimpleAccount must be deployed with the new EntryPoint address, then upgrading\n * the implementation by calling `upgradeTo()`\n */\n function initialize(address anOwner) public virtual initializer {\n _initialize(anOwner);\n }\n\n function _initialize(address anOwner) internal virtual {\n owner = anOwner;\n emit SimpleAccountInitialized(_entryPoint, owner);\n }\n\n // Require the function call went through EntryPoint or owner\n function _requireFromEntryPointOrOwner() internal view {\n require(msg.sender == address(entryPoint()) || msg.sender == owner, \"account: not Owner or EntryPoint\");\n }\n\n /// implement template method of BaseAccount\n function _validateSignature(UserOperation calldata userOp, bytes32 userOpHash)\n internal override virtual returns (uint256 validationData) {\n bytes32 hash = userOpHash.toEthSignedMessageHash();\n if (owner != hash.recover(userOp.signature))\n return SIG_VALIDATION_FAILED;\n return 0;\n }\n\n function _call(address target, uint256 value, bytes memory data) internal {\n (bool success, bytes memory result) = target.call{value : value}(data);\n if (!success) {\n assembly {\n revert(add(result, 32), mload(result))\n }\n }\n }\n\n /**\n * check current account deposit in the entryPoint\n */\n function getDeposit() public view returns (uint256) {\n return entryPoint().balanceOf(address(this));\n }\n\n /**\n * deposit more funds for this account in the entryPoint\n */\n function addDeposit() public payable {\n entryPoint().depositTo{value : msg.value}(address(this));\n }\n\n /**\n * withdraw value from the account's deposit\n * @param withdrawAddress target to send to\n * @param amount to withdraw\n */\n function withdrawDepositTo(address payable withdrawAddress, uint256 amount) public onlyOwner {\n entryPoint().withdrawTo(withdrawAddress, amount);\n }\n\n function _authorizeUpgrade(address newImplementation) internal view override {\n (newImplementation);\n _onlyOwner();\n }\n}\n\n" - }, - "contracts/samples/SimpleAccountFactory.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"@openzeppelin/contracts/utils/Create2.sol\";\nimport \"@openzeppelin/contracts/proxy/ERC1967/ERC1967Proxy.sol\";\n\nimport \"./SimpleAccount.sol\";\n\n/**\n * A sample factory contract for SimpleAccount\n * A UserOperations \"initCode\" holds the address of the factory, and a method call (to createAccount, in this sample factory).\n * The factory's createAccount returns the target account address even if it is already installed.\n * This way, the entryPoint.getSenderAddress() can be called either before or after the account is created.\n */\ncontract SimpleAccountFactory {\n SimpleAccount public immutable accountImplementation;\n\n constructor(IEntryPoint _entryPoint) {\n accountImplementation = new SimpleAccount(_entryPoint);\n }\n\n /**\n * create an account, and return its address.\n * returns the address even if the account is already deployed.\n * Note that during UserOperation execution, this method is called only if the account is not deployed.\n * This method returns an existing account address so that entryPoint.getSenderAddress() would work even after account creation\n */\n function createAccount(address owner,uint256 salt) public returns (SimpleAccount ret) {\n address addr = getAddress(owner, salt);\n uint codeSize = addr.code.length;\n if (codeSize > 0) {\n return SimpleAccount(payable(addr));\n }\n ret = SimpleAccount(payable(new ERC1967Proxy{salt : bytes32(salt)}(\n address(accountImplementation),\n abi.encodeCall(SimpleAccount.initialize, (owner))\n )));\n }\n\n /**\n * calculate the counterfactual address of this account as it would be returned by createAccount()\n */\n function getAddress(address owner,uint256 salt) public view returns (address) {\n return Create2.computeAddress(bytes32(salt), keccak256(abi.encodePacked(\n type(ERC1967Proxy).creationCode,\n abi.encode(\n address(accountImplementation),\n abi.encodeCall(SimpleAccount.initialize, (owner))\n )\n )));\n }\n}\n" - }, - "contracts/samples/TokenPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable reason-string */\n\nimport \"@openzeppelin/contracts/token/ERC20/ERC20.sol\";\nimport \"../core/BasePaymaster.sol\";\n\n/**\n * A sample paymaster that defines itself as a token to pay for gas.\n * The paymaster IS the token to use, since a paymaster cannot use an external contract.\n * Also, the exchange rate has to be fixed, since it can't reference an external Uniswap or other exchange contract.\n * subclass should override \"getTokenValueOfEth\" to provide actual token exchange rate, settable by the owner.\n * Known Limitation: this paymaster is exploitable when put into a batch with multiple ops (of different accounts):\n * - while a single op can't exploit the paymaster (if postOp fails to withdraw the tokens, the user's op is reverted,\n * and then we know we can withdraw the tokens), multiple ops with different senders (all using this paymaster)\n * in a batch can withdraw funds from 2nd and further ops, forcing the paymaster itself to pay (from its deposit)\n * - Possible workarounds are either use a more complex paymaster scheme (e.g. the DepositPaymaster) or\n * to whitelist the account and the called method ids.\n */\ncontract TokenPaymaster is BasePaymaster, ERC20 {\n\n //calculated cost of the postOp\n uint256 constant public COST_OF_POST = 15000;\n\n address public immutable theFactory;\n\n constructor(address accountFactory, string memory _symbol, IEntryPoint _entryPoint) ERC20(_symbol, _symbol) BasePaymaster(_entryPoint) {\n theFactory = accountFactory;\n //make it non-empty\n _mint(address(this), 1);\n\n //owner is allowed to withdraw tokens from the paymaster's balance\n _approve(address(this), msg.sender, type(uint).max);\n }\n\n\n /**\n * helpers for owner, to mint and withdraw tokens.\n * @param recipient - the address that will receive the minted tokens.\n * @param amount - the amount it will receive.\n */\n function mintTokens(address recipient, uint256 amount) external onlyOwner {\n _mint(recipient, amount);\n }\n\n /**\n * transfer paymaster ownership.\n * owner of this paymaster is allowed to withdraw funds (tokens transferred to this paymaster's balance)\n * when changing owner, the old owner's withdrawal rights are revoked.\n */\n function transferOwnership(address newOwner) public override virtual onlyOwner {\n // remove allowance of current owner\n _approve(address(this), owner(), 0);\n super.transferOwnership(newOwner);\n // new owner is allowed to withdraw tokens from the paymaster's balance\n _approve(address(this), newOwner, type(uint).max);\n }\n\n //Note: this method assumes a fixed ratio of token-to-eth. subclass should override to supply oracle\n // or a setter.\n function getTokenValueOfEth(uint256 valueEth) internal view virtual returns (uint256 valueToken) {\n return valueEth / 100;\n }\n\n /**\n * validate the request:\n * if this is a constructor call, make sure it is a known account.\n * verify the sender has enough tokens.\n * (since the paymaster is also the token, there is no notion of \"approval\")\n */\n function _validatePaymasterUserOp(UserOperation calldata userOp, bytes32 /*userOpHash*/, uint256 requiredPreFund)\n internal view override returns (bytes memory context, uint256 validationData) {\n uint256 tokenPrefund = getTokenValueOfEth(requiredPreFund);\n\n // verificationGasLimit is dual-purposed, as gas limit for postOp. make sure it is high enough\n // make sure that verificationGasLimit is high enough to handle postOp\n require(userOp.verificationGasLimit > COST_OF_POST, \"TokenPaymaster: gas too low for postOp\");\n\n if (userOp.initCode.length != 0) {\n _validateConstructor(userOp);\n require(balanceOf(userOp.sender) >= tokenPrefund, \"TokenPaymaster: no balance (pre-create)\");\n } else {\n\n require(balanceOf(userOp.sender) >= tokenPrefund, \"TokenPaymaster: no balance\");\n }\n\n return (abi.encode(userOp.sender), 0);\n }\n\n // when constructing an account, validate constructor code and parameters\n // we trust our factory (and that it doesn't have any other public methods)\n function _validateConstructor(UserOperation calldata userOp) internal virtual view {\n address factory = address(bytes20(userOp.initCode[0 : 20]));\n require(factory == theFactory, \"TokenPaymaster: wrong account factory\");\n }\n\n /**\n * actual charge of user.\n * this method will be called just after the user's TX with mode==OpSucceeded|OpReverted (account pays in both cases)\n * BUT: if the user changed its balance in a way that will cause postOp to revert, then it gets called again, after reverting\n * the user's TX , back to the state it was before the transaction started (before the validatePaymasterUserOp),\n * and the transaction should succeed there.\n */\n function _postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) internal override {\n //we don't really care about the mode, we just pay the gas with the user's tokens.\n (mode);\n address sender = abi.decode(context, (address));\n uint256 charge = getTokenValueOfEth(actualGasCost + COST_OF_POST);\n //actualGasCost is known to be no larger than the above requiredPreFund, so the transfer should succeed.\n _transfer(sender, address(this), charge);\n }\n}\n" - }, - "contracts/samples/VerifyingPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable reason-string */\n/* solhint-disable no-inline-assembly */\n\nimport \"../core/BasePaymaster.sol\";\nimport \"@openzeppelin/contracts/utils/cryptography/ECDSA.sol\";\n/**\n * A sample paymaster that uses external service to decide whether to pay for the UserOp.\n * The paymaster trusts an external signer to sign the transaction.\n * The calling user must pass the UserOp to that external signer first, which performs\n * whatever off-chain verification before signing the UserOp.\n * Note that this signature is NOT a replacement for the account-specific signature:\n * - the paymaster checks a signature to agree to PAY for GAS.\n * - the account checks a signature to prove identity and account ownership.\n */\ncontract VerifyingPaymaster is BasePaymaster {\n\n using ECDSA for bytes32;\n using UserOperationLib for UserOperation;\n\n address public immutable verifyingSigner;\n\n uint256 private constant VALID_TIMESTAMP_OFFSET = 20;\n\n uint256 private constant SIGNATURE_OFFSET = 84;\n\n constructor(IEntryPoint _entryPoint, address _verifyingSigner) BasePaymaster(_entryPoint) {\n verifyingSigner = _verifyingSigner;\n }\n\n mapping(address => uint256) public senderNonce;\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n // lighter signature scheme. must match UserOp.ts#packUserOp\n bytes calldata pnd = userOp.paymasterAndData;\n // copy directly the userOp from calldata up to (but not including) the paymasterAndData.\n // this encoding depends on the ABI encoding of calldata, but is much lighter to copy\n // than referencing each field separately.\n assembly {\n let ofs := userOp\n let len := sub(sub(pnd.offset, ofs), 32)\n ret := mload(0x40)\n mstore(0x40, add(ret, add(len, 32)))\n mstore(ret, len)\n calldatacopy(add(ret, 32), ofs, len)\n }\n }\n\n /**\n * return the hash we're going to sign off-chain (and validate on-chain)\n * this method is called by the off-chain service, to sign the request.\n * it is called on-chain from the validatePaymasterUserOp, to validate the signature.\n * note that this signature covers all fields of the UserOperation, except the \"paymasterAndData\",\n * which will carry the signature itself.\n */\n function getHash(UserOperation calldata userOp, uint48 validUntil, uint48 validAfter)\n public view returns (bytes32) {\n //can't use userOp.hash(), since it contains also the paymasterAndData itself.\n\n return keccak256(abi.encode(\n pack(userOp),\n block.chainid,\n address(this),\n senderNonce[userOp.getSender()],\n validUntil,\n validAfter\n ));\n }\n\n /**\n * verify our external signer signed this request.\n * the \"paymasterAndData\" is expected to be the paymaster and a signature over the entire request params\n * paymasterAndData[:20] : address(this)\n * paymasterAndData[20:84] : abi.encode(validUntil, validAfter)\n * paymasterAndData[84:] : signature\n */\n function _validatePaymasterUserOp(UserOperation calldata userOp, bytes32 /*userOpHash*/, uint256 requiredPreFund)\n internal override returns (bytes memory context, uint256 validationData) {\n (requiredPreFund);\n\n (uint48 validUntil, uint48 validAfter, bytes calldata signature) = parsePaymasterAndData(userOp.paymasterAndData);\n //ECDSA library supports both 64 and 65-byte long signatures.\n // we only \"require\" it here so that the revert reason on invalid signature will be of \"VerifyingPaymaster\", and not \"ECDSA\"\n require(signature.length == 64 || signature.length == 65, \"VerifyingPaymaster: invalid signature length in paymasterAndData\");\n bytes32 hash = ECDSA.toEthSignedMessageHash(getHash(userOp, validUntil, validAfter));\n senderNonce[userOp.getSender()]++;\n\n //don't revert on signature failure: return SIG_VALIDATION_FAILED\n if (verifyingSigner != ECDSA.recover(hash, signature)) {\n return (\"\",_packValidationData(true,validUntil,validAfter));\n }\n\n //no need for other on-chain validation: entire UserOp should have been checked\n // by the external service prior to signing it.\n return (\"\",_packValidationData(false,validUntil,validAfter));\n }\n\n function parsePaymasterAndData(bytes calldata paymasterAndData) public pure returns(uint48 validUntil, uint48 validAfter, bytes calldata signature) {\n (validUntil, validAfter) = abi.decode(paymasterAndData[VALID_TIMESTAMP_OFFSET:SIGNATURE_OFFSET],(uint48, uint48));\n signature = paymasterAndData[SIGNATURE_OFFSET:];\n }\n}\n" - }, - "contracts/test/BrokenBlsAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"@openzeppelin/contracts/utils/Create2.sol\";\nimport \"@openzeppelin/contracts/proxy/ERC1967/ERC1967Proxy.sol\";\n\nimport \"../samples/SimpleAccount.sol\";\nimport \"../samples/bls/IBLSAccount.sol\";\n\n/**\n * for testing: a BLS account that fails to return its public-key (completely ignores its publickey)\n * this is a copy of the normal bls account, but it returns a public-key unrelated to the one it is constructed with.\n */\ncontract BrokenBLSAccount is SimpleAccount, IBLSAccount {\n address public immutable aggregator;\n\n // The constructor is used only for the \"implementation\" and only sets immutable values.\n // Mutable values slots for proxy accounts are set by the 'initialize' function.\n constructor(IEntryPoint anEntryPoint, address anAggregator) SimpleAccount(anEntryPoint) {\n aggregator = anAggregator;\n }\n\n function initialize(uint256[4] memory aPublicKey) public virtual initializer {\n (aPublicKey);\n super._initialize(address(0));\n }\n\n function _validateSignature(UserOperation calldata userOp, bytes32 userOpHash)\n internal override view returns (uint256 validationData) {\n\n (userOp, userOpHash);\n return _packValidationData(ValidationData(aggregator, 0,0));\n }\n\n function getBlsPublicKey() external override pure returns (uint256[4] memory) {\n uint256[4] memory pubkey;\n return pubkey;\n }\n}\n\n\n/**\n * Based n SimpleAccountFactory\n * can't be a subclass, since both constructor and createAccount depend on the\n * actual wallet contract constructor and initializer\n */\ncontract BrokenBLSAccountFactory {\n BrokenBLSAccount public immutable accountImplementation;\n\n constructor(IEntryPoint entryPoint, address aggregator){\n accountImplementation = new BrokenBLSAccount(entryPoint, aggregator);\n }\n\n /**\n * create an account, and return its address.\n * returns the address even if the account is already deployed.\n * Note that during UserOperation execution, this method is called only if the account is not deployed.\n * This method returns an existing account address so that entryPoint.getSenderAddress() would work even after account creation\n * Also note that out BLSSignatureAggregator requires that the public-key is the last parameter\n */\n function createAccount(uint salt, uint256[4] memory aPublicKey) public returns (BrokenBLSAccount) {\n\n address addr = getAddress(salt, aPublicKey);\n uint codeSize = addr.code.length;\n if (codeSize > 0) {\n return BrokenBLSAccount(payable(addr));\n }\n return BrokenBLSAccount(payable(new ERC1967Proxy{salt : bytes32(salt)}(\n address(accountImplementation),\n abi.encodeCall(BrokenBLSAccount.initialize, aPublicKey)\n )));\n }\n\n /**\n * calculate the counterfactual address of this account as it would be returned by createAccount()\n */\n function getAddress(uint salt, uint256[4] memory aPublicKey) public view returns (address) {\n return Create2.computeAddress(bytes32(salt), keccak256(abi.encodePacked(\n type(ERC1967Proxy).creationCode,\n abi.encode(\n address(accountImplementation),\n abi.encodeCall(BrokenBLSAccount.initialize, (aPublicKey))\n )\n )));\n }\n}\n" - }, - "contracts/test/MaliciousAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\nimport \"../core/EntryPoint.sol\";\n\ncontract MaliciousAccount is IAccount {\n IEntryPoint private ep;\n constructor(IEntryPoint _ep) payable {\n ep = _ep;\n }\n function validateUserOp(UserOperation calldata userOp, bytes32, uint256 missingAccountFunds)\n external returns (uint256 validationData) {\n ep.depositTo{value : missingAccountFunds}(address(this));\n // Now calculate basefee per EntryPoint.getUserOpGasPrice() and compare it to the basefe we pass off-chain in the signature\n uint256 externalBaseFee = abi.decode(userOp.signature, (uint256));\n uint256 requiredGas = userOp.callGasLimit + userOp.verificationGasLimit + userOp.preVerificationGas;\n uint256 gasPrice = missingAccountFunds / requiredGas;\n uint256 basefee = gasPrice - userOp.maxPriorityFeePerGas;\n require (basefee == externalBaseFee, \"Revert after first validation\");\n return 0;\n }\n}\n" - }, - "contracts/test/TestAggregatedAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../samples/SimpleAccount.sol\";\n\n/**\n * test aggregated-signature account.\n * works only with TestAggregatedSignature, which doesn't really check signature, but nonce sum\n * a true aggregated account should expose data (e.g. its public key) to the aggregator.\n */\ncontract TestAggregatedAccount is SimpleAccount {\n address public immutable aggregator;\n\n // The constructor is used only for the \"implementation\" and only sets immutable values.\n // Mutable value slots for proxy accounts are set by the 'initialize' function.\n constructor(IEntryPoint anEntryPoint, address anAggregator) SimpleAccount(anEntryPoint) {\n aggregator = anAggregator;\n }\n\n /// @inheritdoc SimpleAccount\n function initialize(address) public virtual override initializer {\n super._initialize(address(0));\n }\n\n function _validateSignature(UserOperation calldata userOp, bytes32 userOpHash)\n internal override view returns (uint256 validationData) {\n (userOp, userOpHash);\n return _packValidationData(ValidationData(aggregator, 0, 0));\n }\n}\n" - }, - "contracts/test/TestAggregatedAccountFactory.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"@openzeppelin/contracts/utils/Create2.sol\";\nimport \"@openzeppelin/contracts/proxy/ERC1967/ERC1967Proxy.sol\";\n\nimport \"./TestAggregatedAccount.sol\";\n\n/**\n * Based on SimpleAccountFactory.\n * Cannot be a subclass since both constructor and createAccount depend on the\n * constructor and initializer of the actual account contract.\n */\ncontract TestAggregatedAccountFactory {\n TestAggregatedAccount public immutable accountImplementation;\n\n constructor(IEntryPoint anEntryPoint, address anAggregator){\n accountImplementation = new TestAggregatedAccount(anEntryPoint, anAggregator);\n }\n\n /**\n * create an account, and return its address.\n * returns the address even if the account is already deployed.\n * Note that during UserOperation execution, this method is called only if the account is not deployed.\n * This method returns an existing account address so that entryPoint.getSenderAddress() would work even after account creation\n */\n function createAccount(address owner,uint256 salt) public returns (TestAggregatedAccount ret) {\n address addr = getAddress(owner, salt);\n uint codeSize = addr.code.length;\n if (codeSize > 0) {\n return TestAggregatedAccount(payable(addr));\n }\n ret = TestAggregatedAccount(payable(new ERC1967Proxy{salt : bytes32(salt)}(\n address(accountImplementation),\n abi.encodeCall(TestAggregatedAccount.initialize, (owner))\n )));\n }\n\n /**\n * calculate the counterfactual address of this account as it would be returned by createAccount()\n */\n function getAddress(address owner,uint256 salt) public view returns (address) {\n return Create2.computeAddress(bytes32(salt), keccak256(abi.encodePacked(\n type(ERC1967Proxy).creationCode,\n abi.encode(\n address(accountImplementation),\n abi.encodeCall(TestAggregatedAccount.initialize, (owner))\n )\n )));\n }\n}\n" - }, - "contracts/test/TestCounter.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n//sample \"receiver\" contract, for testing \"exec\" from account.\ncontract TestCounter {\n mapping(address => uint256) public counters;\n\n function count() public {\n counters[msg.sender] = counters[msg.sender] + 1;\n }\n\n function countFail() public pure {\n revert(\"count failed\");\n }\n\n function justemit() public {\n emit CalledFrom(msg.sender);\n }\n\n event CalledFrom(address sender);\n\n //helper method to waste gas\n // repeat - waste gas on writing storage in a loop\n // junk - dynamic buffer to stress the function size.\n mapping(uint256 => uint256) public xxx;\n uint256 public offset;\n\n function gasWaster(uint256 repeat, string calldata /*junk*/) external {\n for (uint256 i = 1; i <= repeat; i++) {\n offset++;\n xxx[offset] = i;\n }\n }\n}\n" - }, - "contracts/test/TestExpirePaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../core/BasePaymaster.sol\";\n\n/**\n * test expiry mechanism: paymasterData encodes the \"validUntil\" and validAfter\" times\n */\ncontract TestExpirePaymaster is BasePaymaster {\n // solhint-disable no-empty-blocks\n constructor(IEntryPoint _entryPoint) BasePaymaster(_entryPoint)\n {}\n\n function _validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n internal virtual override view\n returns (bytes memory context, uint256 validationData) {\n (userOp, userOpHash, maxCost);\n (uint48 validAfter, uint48 validUntil) = abi.decode(userOp.paymasterAndData[20 :], (uint48, uint48));\n validationData = _packValidationData(false, validUntil, validAfter);\n context = \"\";\n }\n}\n" - }, - "contracts/test/TestExpiryAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../samples/SimpleAccount.sol\";\n\n/**\n * A test account, for testing expiry.\n * add \"temporary\" owners, each with a time range (since..till) times for each.\n * NOTE: this is not a full \"session key\" implementation: a real session key should probably limit\n * other things, like target contracts and methods to be called.\n * also, the \"since\" value is not really useful, only for testing the entrypoint.\n */\ncontract TestExpiryAccount is SimpleAccount {\n using ECDSA for bytes32;\n\n mapping(address => uint48) public ownerAfter;\n mapping(address => uint48) public ownerUntil;\n\n // solhint-disable-next-line no-empty-blocks\n constructor(IEntryPoint anEntryPoint) SimpleAccount(anEntryPoint) {}\n\n function initialize(address anOwner) public virtual override initializer {\n super._initialize(anOwner);\n addTemporaryOwner(anOwner, 0, type(uint48).max);\n }\n\n // As this is a test contract, no need for proxy, so no need to disable init\n // solhint-disable-next-line no-empty-blocks\n function _disableInitializers() internal override {}\n\n function addTemporaryOwner(address owner, uint48 _after, uint48 _until) public onlyOwner {\n require(_until > _after, \"wrong until/after\");\n ownerAfter[owner] = _after;\n ownerUntil[owner] = _until;\n }\n\n /// implement template method of BaseAccount\n function _validateSignature(UserOperation calldata userOp, bytes32 userOpHash)\n internal override view returns (uint256 validationData) {\n bytes32 hash = userOpHash.toEthSignedMessageHash();\n address signer = hash.recover(userOp.signature);\n uint48 _until = ownerUntil[signer];\n uint48 _after = ownerAfter[signer];\n\n //we have \"until\" value for all valid owners. so zero means \"invalid signature\"\n bool sigFailed = _until == 0;\n return _packValidationData(sigFailed, _until, _after);\n }\n}\n" - }, - "contracts/test/TestHelpers.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../core/Helpers.sol\";\n\ncontract TestHelpers {\n\n function parseValidationData(uint validationData) public pure returns (ValidationData memory) {\n return _parseValidationData(validationData);\n }\n\n function intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) public pure returns (ValidationData memory) {\n return _intersectTimeRange(validationData, paymasterValidationData);\n }\n\n function packValidationDataStruct(ValidationData memory data) public pure returns (uint256) {\n return _packValidationData(data);\n }\n\n function packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) public pure returns (uint256) {\n return _packValidationData(sigFailed, validUntil, validAfter);\n }\n}\n" - }, - "contracts/test/TestOracle.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../samples/IOracle.sol\";\n\ncontract TestOracle is IOracle {\n function getTokenValueOfEth(uint256 ethOutput) external pure override returns (uint256 tokenInput) {\n return ethOutput * 2;\n }\n}\n" - }, - "contracts/test/TestPaymasterAcceptAll.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../core/BasePaymaster.sol\";\n\n/**\n * test paymaster, that pays for everything, without any check.\n */\ncontract TestPaymasterAcceptAll is BasePaymaster {\n\n constructor(IEntryPoint _entryPoint) BasePaymaster(_entryPoint) {\n // to support \"deterministic address\" factory\n // solhint-disable avoid-tx-origin\n if (tx.origin != msg.sender) {\n _transferOwnership(tx.origin);\n }\n\n }\n\n function _validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n internal virtual override view\n returns (bytes memory context, uint256 validationData) {\n (userOp, userOpHash, maxCost);\n return (\"\", maxCost == 12345 ? 1 : 0);\n }\n}\n" - }, - "contracts/test/TestRevertAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n/* solhint-disable no-inline-assembly */\n\nimport \"../samples/SimpleAccount.sol\";\ncontract TestRevertAccount is IAccount {\n IEntryPoint private ep;\n constructor(IEntryPoint _ep) payable {\n ep = _ep;\n }\n\n function validateUserOp(UserOperation calldata, bytes32, uint256 missingAccountFunds)\n external override returns (uint256 validationData) {\n ep.depositTo{value : missingAccountFunds}(address(this));\n return 0;\n }\n\n function revertLong(uint256 length) public pure{\n assembly {\n revert(0, length)\n }\n }\n}\n" - }, - "contracts/test/TestSignatureAggregator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable reason-string */\n\nimport \"../interfaces/IAggregator.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\nimport \"../samples/SimpleAccount.sol\";\n\n/**\n * test signature aggregator.\n * the aggregated signature is the SUM of the nonce fields..\n */\ncontract TestSignatureAggregator is IAggregator {\n\n /// @inheritdoc IAggregator\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external pure override {\n uint sum = 0;\n for (uint i = 0; i < userOps.length; i++) {\n uint nonce = userOps[i].nonce;\n sum += nonce;\n }\n require(signature.length == 32, \"TestSignatureValidator: sig must be uint\");\n (uint sig) = abi.decode(signature, (uint));\n require(sig == sum, \"TestSignatureValidator: aggregated signature mismatch (nonce sum)\");\n }\n\n /// @inheritdoc IAggregator\n function validateUserOpSignature(UserOperation calldata)\n external pure returns (bytes memory) {\n return \"\";\n }\n\n /**\n * dummy test aggregator: sum all nonce values of UserOps.\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external pure returns (bytes memory aggregatedSignature) {\n uint sum = 0;\n for (uint i = 0; i < userOps.length; i++) {\n sum += userOps[i].nonce;\n }\n return abi.encode(sum);\n }\n\n /**\n * Calls the 'addStake' method of the EntryPoint. Forwards the entire msg.value to this call.\n * @param entryPoint - the EntryPoint to send the stake to.\n * @param delay - the new lock duration before the deposit can be withdrawn.\n */\n function addStake(IEntryPoint entryPoint, uint32 delay) external payable {\n entryPoint.addStake{value: msg.value}(delay);\n }\n}\n" - }, - "contracts/test/TestToken.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"@openzeppelin/contracts/token/ERC20/ERC20.sol\";\n\ncontract TestToken is ERC20 {\n constructor ()\n // solhint-disable-next-line no-empty-blocks\n ERC20(\"TST\", \"TestToken\") {\n }\n\n function mint(address sender, uint256 amount) external {\n _mint(sender, amount);\n }\n}\n" - }, - "contracts/test/TestUtil.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../interfaces/UserOperation.sol\";\n\ncontract TestUtil {\n using UserOperationLib for UserOperation;\n\n function packUserOp(UserOperation calldata op) external pure returns (bytes memory){\n return op.pack();\n }\n\n}\n" - }, - "contracts/test/TestWarmColdAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n/* solhint-disable no-inline-assembly */\n\nimport \"../interfaces/IEntryPoint.sol\";\nimport \"../interfaces/IAccount.sol\";\n\n// Using eip-2929 (https://eips.ethereum.org/EIPS/eip-2929) warm/cold storage access gas costs to detect simulation vs execution\n// COLD_ACCOUNT_ACCESS_COST == 2600, COLD_SLOAD_COST == 2100, WARM_STORAGE_READ_COST == 100\ncontract TestWarmColdAccount is IAccount {\n IEntryPoint private ep;\n uint public state = 1;\n constructor(IEntryPoint _ep) payable {\n ep = _ep;\n }\n\n function validateUserOp(UserOperation calldata userOp, bytes32, uint256 missingAccountFunds)\n external override returns (uint256 validationData) {\n ep.depositTo{value : missingAccountFunds}(address(this));\n if (userOp.nonce == 1) {\n // can only succeed if storage is already warm\n this.touchStorage{gas: 1000}();\n } else if (userOp.nonce == 2) {\n address paymaster = address(bytes20(userOp.paymasterAndData[: 20]));\n // can only succeed if storage is already warm\n this.touchPaymaster{gas: 1000}(paymaster);\n }\n return 0;\n }\n\n function touchStorage() public view returns (uint256) {\n return state;\n }\n\n function touchPaymaster(address paymaster) public view returns (uint256) {\n return paymaster.code.length;\n }\n}\n" - }, - "contracts/utils/Exec.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.5 <0.9.0;\n\n// solhint-disable no-inline-assembly\n\n/**\n * Utility functions helpful when making different kinds of contract calls in Solidity.\n */\nlibrary Exec {\n\n function call(\n address to,\n uint256 value,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function staticcall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal view returns (bool success) {\n assembly {\n success := staticcall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function delegateCall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n // get returned data from last call or calldelegate\n function getReturnData(uint256 maxLen) internal pure returns (bytes memory returnData) {\n assembly {\n let len := returndatasize()\n if gt(len, maxLen) {\n len := maxLen\n }\n let ptr := mload(0x40)\n mstore(0x40, add(ptr, add(len, 0x20)))\n mstore(ptr, len)\n returndatacopy(add(ptr, 0x20), 0, len)\n returnData := ptr\n }\n }\n\n // revert with explicit byte array (probably reverted info from call)\n function revertWithData(bytes memory returnData) internal pure {\n assembly {\n revert(add(returnData, 32), mload(returnData))\n }\n }\n\n function callAndRevert(address to, bytes memory data, uint256 maxLen) internal {\n bool success = call(to,0,data,gasleft());\n if (!success) {\n revertWithData(getReturnData(maxLen));\n }\n }\n}\n" - } - }, - "settings": { - "optimizer": { - "enabled": true, - "runs": 1000000 - }, - "outputSelection": { - "*": { - "*": [ - "abi", - "evm.bytecode", - "evm.deployedBytecode", - "evm.methodIdentifiers", - "metadata", - "devdoc", - "userdoc", - "storageLayout", - "evm.gasEstimates" - ], - "": [ - "ast" - ] - } - }, - "metadata": { - "useLiteralContent": true - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/solcInputs/a4c52f0671aad8941c53d6ead2063803.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/solcInputs/a4c52f0671aad8941c53d6ead2063803.json deleted file mode 100644 index dd58ba5a3e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/solcInputs/a4c52f0671aad8941c53d6ead2063803.json +++ /dev/null @@ -1,68 +0,0 @@ -{ - "language": "Solidity", - "sources": { - "@openzeppelin/contracts/security/ReentrancyGuard.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (security/ReentrancyGuard.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Contract module that helps prevent reentrant calls to a function.\n *\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\n * available, which can be applied to functions to make sure there are no nested\n * (reentrant) calls to them.\n *\n * Note that because there is a single `nonReentrant` guard, functions marked as\n * `nonReentrant` may not call one another. This can be worked around by making\n * those functions `private`, and then adding `external` `nonReentrant` entry\n * points to them.\n *\n * TIP: If you would like to learn more about reentrancy and alternative ways\n * to protect against it, check out our blog post\n * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].\n */\nabstract contract ReentrancyGuard {\n // Booleans are more expensive than uint256 or any type that takes up a full\n // word because each write operation emits an extra SLOAD to first read the\n // slot's contents, replace the bits taken up by the boolean, and then write\n // back. This is the compiler's defense against contract upgrades and\n // pointer aliasing, and it cannot be disabled.\n\n // The values being non-zero value makes deployment a bit more expensive,\n // but in exchange the refund on every call to nonReentrant will be lower in\n // amount. Since refunds are capped to a percentage of the total\n // transaction's gas, it is best to keep them low in cases like this one, to\n // increase the likelihood of the full refund coming into effect.\n uint256 private constant _NOT_ENTERED = 1;\n uint256 private constant _ENTERED = 2;\n\n uint256 private _status;\n\n constructor() {\n _status = _NOT_ENTERED;\n }\n\n /**\n * @dev Prevents a contract from calling itself, directly or indirectly.\n * Calling a `nonReentrant` function from another `nonReentrant`\n * function is not supported. It is possible to prevent this from happening\n * by making the `nonReentrant` function external, and making it call a\n * `private` function that does the actual work.\n */\n modifier nonReentrant() {\n _nonReentrantBefore();\n _;\n _nonReentrantAfter();\n }\n\n function _nonReentrantBefore() private {\n // On the first call to nonReentrant, _status will be _NOT_ENTERED\n require(_status != _ENTERED, \"ReentrancyGuard: reentrant call\");\n\n // Any calls to nonReentrant after this point will fail\n _status = _ENTERED;\n }\n\n function _nonReentrantAfter() private {\n // By storing the original value once again, a refund is triggered (see\n // https://eips.ethereum.org/EIPS/eip-2200)\n _status = _NOT_ENTERED;\n }\n}\n" - }, - "contracts/core/EntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IPaymaster.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\n\nimport \"../utils/Exec.sol\";\nimport \"./StakeManager.sol\";\nimport \"./SenderCreator.sol\";\nimport \"./Helpers.sol\";\nimport \"./NonceManager.sol\";\nimport \"@openzeppelin/contracts/security/ReentrancyGuard.sol\";\n\ncontract EntryPoint is IEntryPoint, StakeManager, NonceManager, ReentrancyGuard {\n\n using UserOperationLib for UserOperation;\n\n SenderCreator private immutable senderCreator = new SenderCreator();\n\n // internal value used during simulation: need to query aggregator.\n address private constant SIMULATE_FIND_AGGREGATOR = address(1);\n\n // marker for inner call revert on out of gas\n bytes32 private constant INNER_OUT_OF_GAS = hex'deaddead';\n\n uint256 private constant REVERT_REASON_MAX_LEN = 2048;\n\n /**\n * for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value\n * in case of signature failure, instead of revert.\n */\n uint256 public constant SIG_VALIDATION_FAILED = 1;\n\n /**\n * compensate the caller's beneficiary address with the collected fees of all UserOperations.\n * @param beneficiary the address to receive the fees\n * @param amount amount to transfer.\n */\n function _compensate(address payable beneficiary, uint256 amount) internal {\n require(beneficiary != address(0), \"AA90 invalid beneficiary\");\n (bool success,) = beneficiary.call{value : amount}(\"\");\n require(success, \"AA91 failed send to beneficiary\");\n }\n\n /**\n * execute a user op\n * @param opIndex index into the opInfo array\n * @param userOp the userOp to execute\n * @param opInfo the opInfo filled by validatePrepayment for this userOp.\n * @return collected the total amount this userOp paid.\n */\n function _executeUserOp(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory opInfo) private returns (uint256 collected) {\n uint256 preGas = gasleft();\n bytes memory context = getMemoryBytesFromOffset(opInfo.contextOffset);\n\n try this.innerHandleOp(userOp.callData, opInfo, context) returns (uint256 _actualGasCost) {\n collected = _actualGasCost;\n } catch {\n bytes32 innerRevertCode;\n assembly {\n returndatacopy(0, 0, 32)\n innerRevertCode := mload(0)\n }\n // handleOps was called with gas limit too low. abort entire bundle.\n if (innerRevertCode == INNER_OUT_OF_GAS) {\n //report paymaster, since if it is not deliberately caused by the bundler,\n // it must be a revert caused by paymaster.\n revert FailedOp(opIndex, \"AA95 out of gas\");\n }\n\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n collected = _handlePostOp(opIndex, IPaymaster.PostOpMode.postOpReverted, opInfo, context, actualGas);\n }\n }\n\n /**\n * Execute a batch of UserOperations.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) public nonReentrant {\n\n uint256 opslen = ops.length;\n UserOpInfo[] memory opInfos = new UserOpInfo[](opslen);\n\n unchecked {\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[i];\n (uint256 validationData, uint256 pmValidationData) = _validatePrepayment(i, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, pmValidationData, address(0));\n }\n\n uint256 collected = 0;\n emit BeforeExecution();\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(i, ops[i], opInfos[i]);\n }\n\n _compensate(beneficiary, collected);\n } //unchecked\n }\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) public nonReentrant {\n\n uint256 opasLen = opsPerAggregator.length;\n uint256 totalOps = 0;\n for (uint256 i = 0; i < opasLen; i++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[i];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n //address(1) is special marker of \"signature error\"\n require(address(aggregator) != address(1), \"AA96 invalid aggregator\");\n\n if (address(aggregator) != address(0)) {\n // solhint-disable-next-line no-empty-blocks\n try aggregator.validateSignatures(ops, opa.signature) {}\n catch {\n revert SignatureValidationFailed(address(aggregator));\n }\n }\n\n totalOps += ops.length;\n }\n\n UserOpInfo[] memory opInfos = new UserOpInfo[](totalOps);\n\n emit BeforeExecution();\n\n uint256 opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n uint256 opslen = ops.length;\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[opIndex];\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(opIndex, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, paymasterValidationData, address(aggregator));\n opIndex++;\n }\n }\n\n uint256 collected = 0;\n opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n emit SignatureAggregatorChanged(address(opa.aggregator));\n UserOperation[] calldata ops = opa.userOps;\n uint256 opslen = ops.length;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(opIndex, ops[i], opInfos[opIndex]);\n opIndex++;\n }\n }\n emit SignatureAggregatorChanged(address(0));\n\n _compensate(beneficiary, collected);\n }\n\n /// @inheritdoc IEntryPoint\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external override {\n\n UserOpInfo memory opInfo;\n _simulationOnlyValidations(op);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, op, opInfo);\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n\n numberMarker();\n uint256 paid = _executeUserOp(0, op, opInfo);\n numberMarker();\n bool targetSuccess;\n bytes memory targetResult;\n if (target != address(0)) {\n (targetSuccess, targetResult) = target.call(targetCallData);\n }\n revert ExecutionResult(opInfo.preOpGas, paid, data.validAfter, data.validUntil, targetSuccess, targetResult);\n }\n\n\n // A memory copy of UserOp static fields only.\n // Excluding: callData, initCode and signature. Replacing paymasterAndData with paymaster.\n struct MemoryUserOp {\n address sender;\n uint256 nonce;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n address paymaster;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n }\n\n struct UserOpInfo {\n MemoryUserOp mUserOp;\n bytes32 userOpHash;\n uint256 prefund;\n uint256 contextOffset;\n uint256 preOpGas;\n }\n\n /**\n * inner function to handle a UserOperation.\n * Must be declared \"external\" to open a call context, but it can only be called by handleOps.\n */\n function innerHandleOp(bytes memory callData, UserOpInfo memory opInfo, bytes calldata context) external returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n require(msg.sender == address(this), \"AA92 internal call only\");\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n\n uint callGasLimit = mUserOp.callGasLimit;\n unchecked {\n // handleOps was called with gas limit too low. abort entire bundle.\n if (gasleft() < callGasLimit + mUserOp.verificationGasLimit + 5000) {\n assembly {\n mstore(0, INNER_OUT_OF_GAS)\n revert(0, 32)\n }\n }\n }\n\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\n if (callData.length > 0) {\n bool success = Exec.call(mUserOp.sender, 0, callData, callGasLimit);\n if (!success) {\n bytes memory result = Exec.getReturnData(REVERT_REASON_MAX_LEN);\n if (result.length > 0) {\n emit UserOperationRevertReason(opInfo.userOpHash, mUserOp.sender, mUserOp.nonce, result);\n }\n mode = IPaymaster.PostOpMode.opReverted;\n }\n }\n\n unchecked {\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n //note: opIndex is ignored (relevant only if mode==postOpReverted, which is only possible outside of innerHandleOp)\n return _handlePostOp(0, mode, opInfo, context, actualGas);\n }\n }\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) public view returns (bytes32) {\n return keccak256(abi.encode(userOp.hash(), address(this), block.chainid));\n }\n\n /**\n * copy general fields from userOp into the memory opInfo structure.\n */\n function _copyUserOpToMemory(UserOperation calldata userOp, MemoryUserOp memory mUserOp) internal pure {\n mUserOp.sender = userOp.sender;\n mUserOp.nonce = userOp.nonce;\n mUserOp.callGasLimit = userOp.callGasLimit;\n mUserOp.verificationGasLimit = userOp.verificationGasLimit;\n mUserOp.preVerificationGas = userOp.preVerificationGas;\n mUserOp.maxFeePerGas = userOp.maxFeePerGas;\n mUserOp.maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes calldata paymasterAndData = userOp.paymasterAndData;\n if (paymasterAndData.length > 0) {\n require(paymasterAndData.length >= 20, \"AA93 invalid paymasterAndData\");\n mUserOp.paymaster = address(bytes20(paymasterAndData[: 20]));\n } else {\n mUserOp.paymaster = address(0);\n }\n }\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external {\n UserOpInfo memory outOpInfo;\n\n _simulationOnlyValidations(userOp);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, userOp, outOpInfo);\n StakeInfo memory paymasterInfo = _getStakeInfo(outOpInfo.mUserOp.paymaster);\n StakeInfo memory senderInfo = _getStakeInfo(outOpInfo.mUserOp.sender);\n StakeInfo memory factoryInfo;\n {\n bytes calldata initCode = userOp.initCode;\n address factory = initCode.length >= 20 ? address(bytes20(initCode[0 : 20])) : address(0);\n factoryInfo = _getStakeInfo(factory);\n }\n\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n address aggregator = data.aggregator;\n bool sigFailed = aggregator == address(1);\n ReturnInfo memory returnInfo = ReturnInfo(outOpInfo.preOpGas, outOpInfo.prefund,\n sigFailed, data.validAfter, data.validUntil, getMemoryBytesFromOffset(outOpInfo.contextOffset));\n\n if (aggregator != address(0) && aggregator != address(1)) {\n AggregatorStakeInfo memory aggregatorInfo = AggregatorStakeInfo(aggregator, _getStakeInfo(aggregator));\n revert ValidationResultWithAggregation(returnInfo, senderInfo, factoryInfo, paymasterInfo, aggregatorInfo);\n }\n revert ValidationResult(returnInfo, senderInfo, factoryInfo, paymasterInfo);\n\n }\n\n function _getRequiredPrefund(MemoryUserOp memory mUserOp) internal pure returns (uint256 requiredPrefund) {\n unchecked {\n //when using a Paymaster, the verificationGasLimit is used also to as a limit for the postOp call.\n // our security model might call postOp eventually twice\n uint256 mul = mUserOp.paymaster != address(0) ? 3 : 1;\n uint256 requiredGas = mUserOp.callGasLimit + mUserOp.verificationGasLimit * mul + mUserOp.preVerificationGas;\n\n requiredPrefund = requiredGas * mUserOp.maxFeePerGas;\n }\n }\n\n // create the sender's contract if needed.\n function _createSenderIfNeeded(uint256 opIndex, UserOpInfo memory opInfo, bytes calldata initCode) internal {\n if (initCode.length != 0) {\n address sender = opInfo.mUserOp.sender;\n if (sender.code.length != 0) revert FailedOp(opIndex, \"AA10 sender already constructed\");\n address sender1 = senderCreator.createSender{gas : opInfo.mUserOp.verificationGasLimit}(initCode);\n if (sender1 == address(0)) revert FailedOp(opIndex, \"AA13 initCode failed or OOG\");\n if (sender1 != sender) revert FailedOp(opIndex, \"AA14 initCode must return sender\");\n if (sender1.code.length == 0) revert FailedOp(opIndex, \"AA15 initCode must create sender\");\n address factory = address(bytes20(initCode[0 : 20]));\n emit AccountDeployed(opInfo.userOpHash, sender, factory, opInfo.mUserOp.paymaster);\n }\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes calldata initCode) public {\n address sender = senderCreator.createSender(initCode);\n revert SenderAddressResult(sender);\n }\n\n function _simulationOnlyValidations(UserOperation calldata userOp) internal view {\n // solhint-disable-next-line no-empty-blocks\n try this._validateSenderAndPaymaster(userOp.initCode, userOp.sender, userOp.paymasterAndData) {}\n catch Error(string memory revertReason) {\n if (bytes(revertReason).length != 0) {\n revert FailedOp(0, revertReason);\n }\n }\n }\n\n /**\n * Called only during simulation.\n * This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\n */\n function _validateSenderAndPaymaster(bytes calldata initCode, address sender, bytes calldata paymasterAndData) external view {\n if (initCode.length == 0 && sender.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA20 account not deployed\");\n }\n if (paymasterAndData.length >= 20) {\n address paymaster = address(bytes20(paymasterAndData[0 : 20]));\n if (paymaster.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA30 paymaster not deployed\");\n }\n }\n // always revert\n revert(\"\");\n }\n\n /**\n * call account.validateUserOp.\n * revert (with FailedOp) in case validateUserOp reverts, or account didn't send required prefund.\n * decrement account's deposit if needed\n */\n function _validateAccountPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPrefund)\n internal returns (uint256 gasUsedByValidateAccountPrepayment, uint256 validationData) {\n unchecked {\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n address sender = mUserOp.sender;\n _createSenderIfNeeded(opIndex, opInfo, op.initCode);\n address paymaster = mUserOp.paymaster;\n numberMarker();\n uint256 missingAccountFunds = 0;\n if (paymaster == address(0)) {\n uint256 bal = balanceOf(sender);\n missingAccountFunds = bal > requiredPrefund ? 0 : requiredPrefund - bal;\n }\n try IAccount(sender).validateUserOp{gas : mUserOp.verificationGasLimit}(op, opInfo.userOpHash, missingAccountFunds)\n returns (uint256 _validationData) {\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA23 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA23 reverted (or OOG)\");\n }\n if (paymaster == address(0)) {\n DepositInfo storage senderInfo = deposits[sender];\n uint256 deposit = senderInfo.deposit;\n if (requiredPrefund > deposit) {\n revert FailedOp(opIndex, \"AA21 didn't pay prefund\");\n }\n senderInfo.deposit = uint112(deposit - requiredPrefund);\n }\n gasUsedByValidateAccountPrepayment = preGas - gasleft();\n }\n }\n\n /**\n * In case the request has a paymaster:\n * Validate paymaster has enough deposit.\n * Call paymaster.validatePaymasterUserOp.\n * Revert with proper FailedOp in case paymaster reverts.\n * Decrement paymaster's deposit\n */\n function _validatePaymasterPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPreFund, uint256 gasUsedByValidateAccountPrepayment)\n internal returns (bytes memory context, uint256 validationData) {\n unchecked {\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 verificationGasLimit = mUserOp.verificationGasLimit;\n require(verificationGasLimit > gasUsedByValidateAccountPrepayment, \"AA41 too little verificationGas\");\n uint256 gas = verificationGasLimit - gasUsedByValidateAccountPrepayment;\n\n address paymaster = mUserOp.paymaster;\n DepositInfo storage paymasterInfo = deposits[paymaster];\n uint256 deposit = paymasterInfo.deposit;\n if (deposit < requiredPreFund) {\n revert FailedOp(opIndex, \"AA31 paymaster deposit too low\");\n }\n paymasterInfo.deposit = uint112(deposit - requiredPreFund);\n try IPaymaster(paymaster).validatePaymasterUserOp{gas : gas}(op, opInfo.userOpHash, requiredPreFund) returns (bytes memory _context, uint256 _validationData){\n context = _context;\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA33 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA33 reverted (or OOG)\");\n }\n }\n }\n\n /**\n * revert if either account validationData or paymaster validationData is expired\n */\n function _validateAccountAndPaymasterValidationData(uint256 opIndex, uint256 validationData, uint256 paymasterValidationData, address expectedAggregator) internal view {\n (address aggregator, bool outOfTimeRange) = _getValidationData(validationData);\n if (expectedAggregator != aggregator) {\n revert FailedOp(opIndex, \"AA24 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA22 expired or not due\");\n }\n //pmAggregator is not a real signature aggregator: we don't have logic to handle it as address.\n // non-zero address means that the paymaster fails due to some signature check (which is ok only during estimation)\n address pmAggregator;\n (pmAggregator, outOfTimeRange) = _getValidationData(paymasterValidationData);\n if (pmAggregator != address(0)) {\n revert FailedOp(opIndex, \"AA34 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA32 paymaster expired or not due\");\n }\n }\n\n function _getValidationData(uint256 validationData) internal view returns (address aggregator, bool outOfTimeRange) {\n if (validationData == 0) {\n return (address(0), false);\n }\n ValidationData memory data = _parseValidationData(validationData);\n // solhint-disable-next-line not-rely-on-time\n outOfTimeRange = block.timestamp > data.validUntil || block.timestamp < data.validAfter;\n aggregator = data.aggregator;\n }\n\n /**\n * validate account and paymaster (if defined).\n * also make sure total validation doesn't exceed verificationGasLimit\n * this method is called off-chain (simulateValidation()) and on-chain (from handleOps)\n * @param opIndex the index of this userOp into the \"opInfos\" array\n * @param userOp the userOp to validate\n */\n function _validatePrepayment(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory outOpInfo)\n private returns (uint256 validationData, uint256 paymasterValidationData) {\n\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = outOpInfo.mUserOp;\n _copyUserOpToMemory(userOp, mUserOp);\n outOpInfo.userOpHash = getUserOpHash(userOp);\n\n // validate all numeric values in userOp are well below 128 bit, so they can safely be added\n // and multiplied without causing overflow\n uint256 maxGasValues = mUserOp.preVerificationGas | mUserOp.verificationGasLimit | mUserOp.callGasLimit |\n userOp.maxFeePerGas | userOp.maxPriorityFeePerGas;\n require(maxGasValues <= type(uint120).max, \"AA94 gas values overflow\");\n\n uint256 gasUsedByValidateAccountPrepayment;\n (uint256 requiredPreFund) = _getRequiredPrefund(mUserOp);\n (gasUsedByValidateAccountPrepayment, validationData) = _validateAccountPrepayment(opIndex, userOp, outOpInfo, requiredPreFund);\n\n if (!_validateAndUpdateNonce(mUserOp.sender, mUserOp.nonce)) {\n revert FailedOp(opIndex, \"AA25 invalid account nonce\");\n }\n\n //a \"marker\" where account opcode validation is done and paymaster opcode validation is about to start\n // (used only by off-chain simulateValidation)\n numberMarker();\n\n bytes memory context;\n if (mUserOp.paymaster != address(0)) {\n (context, paymasterValidationData) = _validatePaymasterPrepayment(opIndex, userOp, outOpInfo, requiredPreFund, gasUsedByValidateAccountPrepayment);\n }\n unchecked {\n uint256 gasUsed = preGas - gasleft();\n\n if (userOp.verificationGasLimit < gasUsed) {\n revert FailedOp(opIndex, \"AA40 over verificationGasLimit\");\n }\n outOpInfo.prefund = requiredPreFund;\n outOpInfo.contextOffset = getOffsetOfMemoryBytes(context);\n outOpInfo.preOpGas = preGas - gasleft() + userOp.preVerificationGas;\n }\n }\n\n /**\n * process post-operation.\n * called just after the callData is executed.\n * if a paymaster is defined and its validation returned a non-empty context, its postOp is called.\n * the excess amount is refunded to the account (or paymaster - if it was used in the request)\n * @param opIndex index in the batch\n * @param mode - whether is called from innerHandleOp, or outside (postOpReverted)\n * @param opInfo userOp fields and info collected during validation\n * @param context the context returned in validatePaymasterUserOp\n * @param actualGas the gas used so far by this user operation\n */\n function _handlePostOp(uint256 opIndex, IPaymaster.PostOpMode mode, UserOpInfo memory opInfo, bytes memory context, uint256 actualGas) private returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n unchecked {\n address refundAddress;\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 gasPrice = getUserOpGasPrice(mUserOp);\n\n address paymaster = mUserOp.paymaster;\n if (paymaster == address(0)) {\n refundAddress = mUserOp.sender;\n } else {\n refundAddress = paymaster;\n if (context.length > 0) {\n actualGasCost = actualGas * gasPrice;\n if (mode != IPaymaster.PostOpMode.postOpReverted) {\n IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost);\n } else {\n // solhint-disable-next-line no-empty-blocks\n try IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost) {}\n catch Error(string memory reason) {\n revert FailedOp(opIndex, string.concat(\"AA50 postOp reverted: \", reason));\n }\n catch {\n revert FailedOp(opIndex, \"AA50 postOp revert\");\n }\n }\n }\n }\n actualGas += preGas - gasleft();\n actualGasCost = actualGas * gasPrice;\n if (opInfo.prefund < actualGasCost) {\n revert FailedOp(opIndex, \"AA51 prefund below actualGasCost\");\n }\n uint256 refund = opInfo.prefund - actualGasCost;\n _incrementDeposit(refundAddress, refund);\n bool success = mode == IPaymaster.PostOpMode.opSucceeded;\n emit UserOperationEvent(opInfo.userOpHash, mUserOp.sender, mUserOp.paymaster, mUserOp.nonce, success, actualGasCost, actualGas);\n } // unchecked\n }\n\n /**\n * the gas price this UserOp agrees to pay.\n * relayer/block builder might submit the TX with higher priorityFee, but the user should not\n */\n function getUserOpGasPrice(MemoryUserOp memory mUserOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = mUserOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = mUserOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n\n function getOffsetOfMemoryBytes(bytes memory data) internal pure returns (uint256 offset) {\n assembly {offset := data}\n }\n\n function getMemoryBytesFromOffset(uint256 offset) internal pure returns (bytes memory data) {\n assembly {data := offset}\n }\n\n //place the NUMBER opcode in the code.\n // this is used as a marker during simulation, as this OP is completely banned from the simulated code of the\n // account and paymaster.\n function numberMarker() internal view {\n assembly {mstore(0, number())}\n }\n}\n\n" - }, - "contracts/core/Helpers.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\n/**\n * returned data from validateUserOp.\n * validateUserOp returns a uint256, with is created by `_packedValidationData` and parsed by `_parseValidationData`\n * @param aggregator - address(0) - the account validated the signature by itself.\n * address(1) - the account failed to validate the signature.\n * otherwise - this is an address of a signature aggregator that must be used to validate the signature.\n * @param validAfter - this UserOp is valid only after this timestamp.\n * @param validaUntil - this UserOp is valid only up to this timestamp.\n */\n struct ValidationData {\n address aggregator;\n uint48 validAfter;\n uint48 validUntil;\n }\n\n//extract sigFailed, validAfter, validUntil.\n// also convert zero validUntil to type(uint48).max\n function _parseValidationData(uint validationData) pure returns (ValidationData memory data) {\n address aggregator = address(uint160(validationData));\n uint48 validUntil = uint48(validationData >> 160);\n if (validUntil == 0) {\n validUntil = type(uint48).max;\n }\n uint48 validAfter = uint48(validationData >> (48 + 160));\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n// intersect account and paymaster ranges.\n function _intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) pure returns (ValidationData memory) {\n ValidationData memory accountValidationData = _parseValidationData(validationData);\n ValidationData memory pmValidationData = _parseValidationData(paymasterValidationData);\n address aggregator = accountValidationData.aggregator;\n if (aggregator == address(0)) {\n aggregator = pmValidationData.aggregator;\n }\n uint48 validAfter = accountValidationData.validAfter;\n uint48 validUntil = accountValidationData.validUntil;\n uint48 pmValidAfter = pmValidationData.validAfter;\n uint48 pmValidUntil = pmValidationData.validUntil;\n\n if (validAfter < pmValidAfter) validAfter = pmValidAfter;\n if (validUntil > pmValidUntil) validUntil = pmValidUntil;\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n/**\n * helper to pack the return value for validateUserOp\n * @param data - the ValidationData to pack\n */\n function _packValidationData(ValidationData memory data) pure returns (uint256) {\n return uint160(data.aggregator) | (uint256(data.validUntil) << 160) | (uint256(data.validAfter) << (160 + 48));\n }\n\n/**\n * helper to pack the return value for validateUserOp, when not using an aggregator\n * @param sigFailed - true for signature failure, false for success\n * @param validUntil last timestamp this UserOperation is valid (or zero for infinite)\n * @param validAfter first timestamp this UserOperation is valid\n */\n function _packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) pure returns (uint256) {\n return (sigFailed ? 1 : 0) | (uint256(validUntil) << 160) | (uint256(validAfter) << (160 + 48));\n }\n\n/**\n * keccak function over calldata.\n * @dev copy calldata into memory, do keccak and drop allocated memory. Strangely, this is more efficient than letting solidity do it.\n */\n function calldataKeccak(bytes calldata data) pure returns (bytes32 ret) {\n assembly {\n let mem := mload(0x40)\n let len := data.length\n calldatacopy(mem, data.offset, len)\n ret := keccak256(mem, len)\n }\n }\n\n" - }, - "contracts/core/NonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IEntryPoint.sol\";\n\n/**\n * nonce management functionality\n */\ncontract NonceManager is INonceManager {\n\n /**\n * The next valid sequence number for a given nonce key.\n */\n mapping(address => mapping(uint192 => uint256)) public nonceSequenceNumber;\n\n function getNonce(address sender, uint192 key)\n public view override returns (uint256 nonce) {\n return nonceSequenceNumber[sender][key] | (uint256(key) << 64);\n }\n\n // allow an account to manually increment its own nonce.\n // (mainly so that during construction nonce can be made non-zero,\n // to \"absorb\" the gas cost of first nonce increment to 1st transaction (construction),\n // not to 2nd transaction)\n function incrementNonce(uint192 key) public override {\n nonceSequenceNumber[msg.sender][key]++;\n }\n\n /**\n * validate nonce uniqueness for this account.\n * called just after validateUserOp()\n */\n function _validateAndUpdateNonce(address sender, uint256 nonce) internal returns (bool) {\n\n uint192 key = uint192(nonce >> 64);\n uint64 seq = uint64(nonce);\n return nonceSequenceNumber[sender][key]++ == seq;\n }\n\n}\n" - }, - "contracts/core/SenderCreator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * helper contract for EntryPoint, to call userOp.initCode from a \"neutral\" address,\n * which is explicitly not the entryPoint itself.\n */\ncontract SenderCreator {\n\n /**\n * call the \"initCode\" factory to create and return the sender account address\n * @param initCode the initCode value from a UserOp. contains 20 bytes of factory address, followed by calldata\n * @return sender the returned address of the created account, or zero address on failure.\n */\n function createSender(bytes calldata initCode) external returns (address sender) {\n address factory = address(bytes20(initCode[0 : 20]));\n bytes memory initCallData = initCode[20 :];\n bool success;\n /* solhint-disable no-inline-assembly */\n assembly {\n success := call(gas(), factory, 0, add(initCallData, 0x20), mload(initCallData), 0, 32)\n sender := mload(0)\n }\n if (!success) {\n sender = address(0);\n }\n }\n}\n" - }, - "contracts/core/StakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IStakeManager.sol\";\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable not-rely-on-time */\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by a paymaster.\n */\nabstract contract StakeManager is IStakeManager {\n\n /// maps paymaster to their deposits and stakes\n mapping(address => DepositInfo) public deposits;\n\n /// @inheritdoc IStakeManager\n function getDepositInfo(address account) public view returns (DepositInfo memory info) {\n return deposits[account];\n }\n\n // internal method to return just the stake info\n function _getStakeInfo(address addr) internal view returns (StakeInfo memory info) {\n DepositInfo storage depositInfo = deposits[addr];\n info.stake = depositInfo.stake;\n info.unstakeDelaySec = depositInfo.unstakeDelaySec;\n }\n\n /// return the deposit (for gas payment) of the account\n function balanceOf(address account) public view returns (uint256) {\n return deposits[account].deposit;\n }\n\n receive() external payable {\n depositTo(msg.sender);\n }\n\n function _incrementDeposit(address account, uint256 amount) internal {\n DepositInfo storage info = deposits[account];\n uint256 newAmount = info.deposit + amount;\n require(newAmount <= type(uint112).max, \"deposit overflow\");\n info.deposit = uint112(newAmount);\n }\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) public payable {\n _incrementDeposit(account, msg.value);\n DepositInfo storage info = deposits[account];\n emit Deposited(account, info.deposit);\n }\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 unstakeDelaySec) public payable {\n DepositInfo storage info = deposits[msg.sender];\n require(unstakeDelaySec > 0, \"must specify unstake delay\");\n require(unstakeDelaySec >= info.unstakeDelaySec, \"cannot decrease unstake time\");\n uint256 stake = info.stake + msg.value;\n require(stake > 0, \"no stake specified\");\n require(stake <= type(uint112).max, \"stake overflow\");\n deposits[msg.sender] = DepositInfo(\n info.deposit,\n true,\n uint112(stake),\n unstakeDelaySec,\n 0\n );\n emit StakeLocked(msg.sender, stake, unstakeDelaySec);\n }\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external {\n DepositInfo storage info = deposits[msg.sender];\n require(info.unstakeDelaySec != 0, \"not staked\");\n require(info.staked, \"already unstaking\");\n uint48 withdrawTime = uint48(block.timestamp) + info.unstakeDelaySec;\n info.withdrawTime = withdrawTime;\n info.staked = false;\n emit StakeUnlocked(msg.sender, withdrawTime);\n }\n\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external {\n DepositInfo storage info = deposits[msg.sender];\n uint256 stake = info.stake;\n require(stake > 0, \"No stake to withdraw\");\n require(info.withdrawTime > 0, \"must call unlockStake() first\");\n require(info.withdrawTime <= block.timestamp, \"Stake withdrawal is not due\");\n info.unstakeDelaySec = 0;\n info.withdrawTime = 0;\n info.stake = 0;\n emit StakeWithdrawn(msg.sender, withdrawAddress, stake);\n (bool success,) = withdrawAddress.call{value : stake}(\"\");\n require(success, \"failed to withdraw stake\");\n }\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external {\n DepositInfo storage info = deposits[msg.sender];\n require(withdrawAmount <= info.deposit, \"Withdraw amount too large\");\n info.deposit = uint112(info.deposit - withdrawAmount);\n emit Withdrawn(msg.sender, withdrawAddress, withdrawAmount);\n (bool success,) = withdrawAddress.call{value : withdrawAmount}(\"\");\n require(success, \"failed to withdraw\");\n }\n}\n" - }, - "contracts/interfaces/IAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\ninterface IAccount {\n\n /**\n * Validate user's signature and nonce\n * the entryPoint will make the call to the recipient only if this validation call returns successfully.\n * signature failure should be reported by returning SIG_VALIDATION_FAILED (1).\n * This allows making a \"simulation call\" without a valid signature\n * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure.\n *\n * @dev Must validate caller is the entryPoint.\n * Must validate the signature and nonce\n * @param userOp the operation that is about to be executed.\n * @param userOpHash hash of the user's request data. can be used as the basis for signature.\n * @param missingAccountFunds missing funds on the account's deposit in the entrypoint.\n * This is the minimum amount to transfer to the sender(entryPoint) to be able to make the call.\n * The excess is left as a deposit in the entrypoint, for future calls.\n * can be withdrawn anytime using \"entryPoint.withdrawTo()\"\n * In case there is a paymaster in the request (or the current deposit is high enough), this value will be zero.\n * @return validationData packaged ValidationData structure. use `_packValidationData` and `_unpackValidationData` to encode and decode\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * If an account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external returns (uint256 validationData);\n}\n" - }, - "contracts/interfaces/IAggregator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * Aggregated Signatures validator.\n */\ninterface IAggregator {\n\n /**\n * validate aggregated signature.\n * revert if the aggregated signature does not match the given list of operations.\n */\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external view;\n\n /**\n * validate signature of a single userOp\n * This method is should be called by bundler after EntryPoint.simulateValidation() returns (reverts) with ValidationResultWithAggregation\n * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps.\n * @param userOp the userOperation received from the user.\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\n * (usually empty, unless account and aggregator support some kind of \"multisig\"\n */\n function validateUserOpSignature(UserOperation calldata userOp)\n external view returns (bytes memory sigForUserOp);\n\n /**\n * aggregate multiple signatures into a single value.\n * This method is called off-chain to calculate the signature to pass with handleOps()\n * bundler MAY use optimized custom code perform this aggregation\n * @param userOps array of UserOperations to collect the signatures from.\n * @return aggregatedSignature the aggregated signature\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external view returns (bytes memory aggregatedSignature);\n}\n" - }, - "contracts/interfaces/IEntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"./UserOperation.sol\";\nimport \"./IStakeManager.sol\";\nimport \"./IAggregator.sol\";\nimport \"./INonceManager.sol\";\n\ninterface IEntryPoint is IStakeManager, INonceManager {\n\n /***\n * An event emitted after each successful request\n * @param userOpHash - unique identifier for the request (hash its entire content, except signature).\n * @param sender - the account that generates this request.\n * @param paymaster - if non-null, the paymaster that pays for this request.\n * @param nonce - the nonce value from the request.\n * @param success - true if the sender transaction succeeded, false if reverted.\n * @param actualGasCost - actual amount paid (by account or paymaster) for this UserOperation.\n * @param actualGasUsed - total gas used by this UserOperation (including preVerification, creation, validation and execution).\n */\n event UserOperationEvent(bytes32 indexed userOpHash, address indexed sender, address indexed paymaster, uint256 nonce, bool success, uint256 actualGasCost, uint256 actualGasUsed);\n\n /**\n * account \"sender\" was deployed.\n * @param userOpHash the userOp that deployed this account. UserOperationEvent will follow.\n * @param sender the account that is deployed\n * @param factory the factory used to deploy this account (in the initCode)\n * @param paymaster the paymaster used by this UserOp\n */\n event AccountDeployed(bytes32 indexed userOpHash, address indexed sender, address factory, address paymaster);\n\n /**\n * An event emitted if the UserOperation \"callData\" reverted with non-zero length\n * @param userOpHash the request unique identifier.\n * @param sender the sender of this request\n * @param nonce the nonce used in the request\n * @param revertReason - the return bytes from the (reverted) call to \"callData\".\n */\n event UserOperationRevertReason(bytes32 indexed userOpHash, address indexed sender, uint256 nonce, bytes revertReason);\n\n /**\n * an event emitted by handleOps(), before starting the execution loop.\n * any event emitted before this event, is part of the validation.\n */\n event BeforeExecution();\n\n /**\n * signature aggregator used by the following UserOperationEvents within this bundle.\n */\n event SignatureAggregatorChanged(address indexed aggregator);\n\n /**\n * a custom revert error of handleOps, to identify the offending op.\n * NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\n * @param opIndex - index into the array of ops to the failed one (in simulateValidation, this is always zero)\n * @param reason - revert reason\n * The string starts with a unique code \"AAmn\", where \"m\" is \"1\" for factory, \"2\" for account and \"3\" for paymaster issues,\n * so a failure can be attributed to the correct entity.\n * Should be caught in off-chain handleOps simulation and not happen on-chain.\n * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\n */\n error FailedOp(uint256 opIndex, string reason);\n\n /**\n * error case when a signature aggregator fails to verify the aggregated signature it had created.\n */\n error SignatureValidationFailed(address aggregator);\n\n /**\n * Successful result from simulateValidation.\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n */\n error ValidationResult(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo);\n\n /**\n * Successful result from simulateValidation, if the account returns a signature aggregator\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n * @param aggregatorInfo signature aggregation info (if the account requires signature aggregator)\n * bundler MUST use it to verify the signature, or reject the UserOperation\n */\n error ValidationResultWithAggregation(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo,\n AggregatorStakeInfo aggregatorInfo);\n\n /**\n * return value of getSenderAddress\n */\n error SenderAddressResult(address sender);\n\n /**\n * return value of simulateHandleOp\n */\n error ExecutionResult(uint256 preOpGas, uint256 paid, uint48 validAfter, uint48 validUntil, bool targetSuccess, bytes targetResult);\n\n //UserOps handled, per aggregator\n struct UserOpsPerAggregator {\n UserOperation[] userOps;\n\n // aggregator address\n IAggregator aggregator;\n // aggregated signature\n bytes signature;\n }\n\n /**\n * Execute a batch of UserOperation.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) external;\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) external;\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) external view returns (bytes32);\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external;\n\n /**\n * gas and return values during simulation\n * @param preOpGas the gas used for validation (including preValidationGas)\n * @param prefund the required prefund for this operation\n * @param sigFailed validateUserOp's (or paymaster's) signature check failed\n * @param validAfter - first timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param validUntil - last timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param paymasterContext returned by validatePaymasterUserOp (to be passed into postOp)\n */\n struct ReturnInfo {\n uint256 preOpGas;\n uint256 prefund;\n bool sigFailed;\n uint48 validAfter;\n uint48 validUntil;\n bytes paymasterContext;\n }\n\n /**\n * returned aggregated signature info.\n * the aggregator returned by the account, and its current stake.\n */\n struct AggregatorStakeInfo {\n address aggregator;\n StakeInfo stakeInfo;\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes memory initCode) external;\n\n\n /**\n * simulate full execution of a UserOperation (including both validation and target execution)\n * this method will always revert with \"ExecutionResult\".\n * it performs full validation of the UserOperation, but ignores signature error.\n * an optional target address is called after the userop succeeds, and its value is returned\n * (before the entire call is reverted)\n * Note that in order to collect the the success/failure of the target call, it must be executed\n * with trace enabled to track the emitted events.\n * @param op the UserOperation to simulate\n * @param target if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult\n * are set to the return from that call.\n * @param targetCallData callData to pass to target address\n */\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external;\n}\n\n" - }, - "contracts/interfaces/INonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\ninterface INonceManager {\n\n /**\n * Return the next nonce for this sender.\n * Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop)\n * But UserOp with different keys can come with arbitrary order.\n *\n * @param sender the account address\n * @param key the high 192 bit of the nonce\n * @return nonce a full nonce to pass for next UserOp with this sender.\n */\n function getNonce(address sender, uint192 key)\n external view returns (uint256 nonce);\n\n /**\n * Manually increment the nonce of the sender.\n * This method is exposed just for completeness..\n * Account does NOT need to call it, neither during validation, nor elsewhere,\n * as the EntryPoint will update the nonce regardless.\n * Possible use-case is call it with various keys to \"initialize\" their nonces to one, so that future\n * UserOperations will not pay extra for the first transaction with a given key.\n */\n function incrementNonce(uint192 key) external;\n}\n" - }, - "contracts/interfaces/IPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * the interface exposed by a paymaster contract, who agrees to pay the gas for user's operations.\n * a paymaster must hold a stake to cover the required entrypoint stake and also the gas for the transaction.\n */\ninterface IPaymaster {\n\n enum PostOpMode {\n opSucceeded, // user op succeeded\n opReverted, // user op reverted. still has to pay for gas.\n postOpReverted //user op succeeded, but caused postOp to revert. Now it's a 2nd call, after user's op was deliberately reverted.\n }\n\n /**\n * payment validation: check if paymaster agrees to pay.\n * Must verify sender is the entryPoint.\n * Revert to reject this request.\n * Note that bundlers will reject this method if it changes the state, unless the paymaster is trusted (whitelisted)\n * The paymaster pre-pays using its deposit, and receive back a refund after the postOp method returns.\n * @param userOp the user operation\n * @param userOpHash hash of the user's request data.\n * @param maxCost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\n * @return context value to send to a postOp\n * zero length to signify postOp is not required.\n * @return validationData signature and time-range of this operation, encoded the same as the return value of validateUserOperation\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n external returns (bytes memory context, uint256 validationData);\n\n /**\n * post-operation handler.\n * Must verify sender is the entryPoint\n * @param mode enum with the following options:\n * opSucceeded - user operation succeeded.\n * opReverted - user op reverted. still has to pay for gas.\n * postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n * Now this is the 2nd call, after user's op was deliberately reverted.\n * @param context - the context value returned by validatePaymasterUserOp\n * @param actualGasCost - actual gas used so far (without this postOp call).\n */\n function postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) external;\n}\n" - }, - "contracts/interfaces/IStakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by the staked entity.\n */\ninterface IStakeManager {\n\n event Deposited(\n address indexed account,\n uint256 totalDeposit\n );\n\n event Withdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /// Emitted when stake or unstake delay are modified\n event StakeLocked(\n address indexed account,\n uint256 totalStaked,\n uint256 unstakeDelaySec\n );\n\n /// Emitted once a stake is scheduled for withdrawal\n event StakeUnlocked(\n address indexed account,\n uint256 withdrawTime\n );\n\n event StakeWithdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /**\n * @param deposit the entity's deposit\n * @param staked true if this entity is staked.\n * @param stake actual amount of ether staked for this entity.\n * @param unstakeDelaySec minimum delay to withdraw the stake.\n * @param withdrawTime - first block timestamp where 'withdrawStake' will be callable, or zero if already locked\n * @dev sizes were chosen so that (deposit,staked, stake) fit into one cell (used during handleOps)\n * and the rest fit into a 2nd cell.\n * 112 bit allows for 10^15 eth\n * 48 bit for full timestamp\n * 32 bit allows 150 years for unstake delay\n */\n struct DepositInfo {\n uint112 deposit;\n bool staked;\n uint112 stake;\n uint32 unstakeDelaySec;\n uint48 withdrawTime;\n }\n\n //API struct used by getStakeInfo and simulateValidation\n struct StakeInfo {\n uint256 stake;\n uint256 unstakeDelaySec;\n }\n\n /// @return info - full deposit information of given account\n function getDepositInfo(address account) external view returns (DepositInfo memory info);\n\n /// @return the deposit (for gas payment) of the account\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) external payable;\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param _unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 _unstakeDelaySec) external payable;\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external;\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external;\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external;\n}\n" - }, - "contracts/interfaces/UserOperation.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\nimport {calldataKeccak} from \"../core/Helpers.sol\";\n\n/**\n * User Operation struct\n * @param sender the sender account of this request.\n * @param nonce unique value the sender uses to verify it is not a replay.\n * @param initCode if set, the account contract will be created by this constructor/\n * @param callData the method call to execute on this account.\n * @param callGasLimit the gas limit passed to the callData method call.\n * @param verificationGasLimit gas used for validateUserOp and validatePaymasterUserOp.\n * @param preVerificationGas gas not calculated by the handleOps method, but added to the gas paid. Covers batch overhead.\n * @param maxFeePerGas same as EIP-1559 gas parameter.\n * @param maxPriorityFeePerGas same as EIP-1559 gas parameter.\n * @param paymasterAndData if set, this field holds the paymaster address and paymaster-specific data. the paymaster will pay for the transaction instead of the sender.\n * @param signature sender-verified signature over the entire request, the EntryPoint address and the chain ID.\n */\n struct UserOperation {\n\n address sender;\n uint256 nonce;\n bytes initCode;\n bytes callData;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n bytes paymasterAndData;\n bytes signature;\n }\n\n/**\n * Utility functions helpful when working with UserOperation structs.\n */\nlibrary UserOperationLib {\n\n function getSender(UserOperation calldata userOp) internal pure returns (address) {\n address data;\n //read sender from userOp, which is first userOp member (saves 800 gas...)\n assembly {data := calldataload(userOp)}\n return address(uint160(data));\n }\n\n //relayer/block builder might submit the TX with higher priorityFee, but the user should not\n // pay above what he signed for.\n function gasPrice(UserOperation calldata userOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n address sender = getSender(userOp);\n uint256 nonce = userOp.nonce;\n bytes32 hashInitCode = calldataKeccak(userOp.initCode);\n bytes32 hashCallData = calldataKeccak(userOp.callData);\n uint256 callGasLimit = userOp.callGasLimit;\n uint256 verificationGasLimit = userOp.verificationGasLimit;\n uint256 preVerificationGas = userOp.preVerificationGas;\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes32 hashPaymasterAndData = calldataKeccak(userOp.paymasterAndData);\n\n return abi.encode(\n sender, nonce,\n hashInitCode, hashCallData,\n callGasLimit, verificationGasLimit, preVerificationGas,\n maxFeePerGas, maxPriorityFeePerGas,\n hashPaymasterAndData\n );\n }\n\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\n return keccak256(pack(userOp));\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n}\n" - }, - "contracts/utils/Exec.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.5 <0.9.0;\n\n// solhint-disable no-inline-assembly\n\n/**\n * Utility functions helpful when making different kinds of contract calls in Solidity.\n */\nlibrary Exec {\n\n function call(\n address to,\n uint256 value,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function staticcall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal view returns (bool success) {\n assembly {\n success := staticcall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function delegateCall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n // get returned data from last call or calldelegate\n function getReturnData(uint256 maxLen) internal pure returns (bytes memory returnData) {\n assembly {\n let len := returndatasize()\n if gt(len, maxLen) {\n len := maxLen\n }\n let ptr := mload(0x40)\n mstore(0x40, add(ptr, add(len, 0x20)))\n mstore(ptr, len)\n returndatacopy(add(ptr, 0x20), 0, len)\n returnData := ptr\n }\n }\n\n // revert with explicit byte array (probably reverted info from call)\n function revertWithData(bytes memory returnData) internal pure {\n assembly {\n revert(add(returnData, 32), mload(returnData))\n }\n }\n\n function callAndRevert(address to, bytes memory data, uint256 maxLen) internal {\n bool success = call(to,0,data,gasleft());\n if (!success) {\n revertWithData(getReturnData(maxLen));\n }\n }\n}\n" - } - }, - "settings": { - "optimizer": { - "enabled": true, - "runs": 1000000 - }, - "viaIR": true, - "outputSelection": { - "*": { - "*": [ - "abi", - "evm.bytecode", - "evm.deployedBytecode", - "evm.methodIdentifiers", - "metadata" - ], - "": [ - "ast" - ] - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/solcInputs/cfbebdf1101dd2bc0f310cb0b7d62cb7.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/solcInputs/cfbebdf1101dd2bc0f310cb0b7d62cb7.json deleted file mode 100644 index dd27f82ce6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mainnet/solcInputs/cfbebdf1101dd2bc0f310cb0b7d62cb7.json +++ /dev/null @@ -1,59 +0,0 @@ -{ - "language": "Solidity", - "sources": { - "contracts/core/EntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IPaymaster.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\n\nimport \"../utils/Exec.sol\";\nimport \"./StakeManager.sol\";\nimport \"./SenderCreator.sol\";\nimport \"./Helpers.sol\";\n\ncontract EntryPoint is IEntryPoint, StakeManager {\n\n using UserOperationLib for UserOperation;\n\n SenderCreator private immutable senderCreator = new SenderCreator();\n\n // internal value used during simulation: need to query aggregator.\n address private constant SIMULATE_FIND_AGGREGATOR = address(1);\n\n // marker for inner call revert on out of gas\n bytes32 private constant INNER_OUT_OF_GAS = hex'deaddead';\n\n uint256 private constant REVERT_REASON_MAX_LEN = 2048;\n\n /**\n * for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value\n * in case of signature failure, instead of revert.\n */\n uint256 public constant SIG_VALIDATION_FAILED = 1;\n\n /**\n * compensate the caller's beneficiary address with the collected fees of all UserOperations.\n * @param beneficiary the address to receive the fees\n * @param amount amount to transfer.\n */\n function _compensate(address payable beneficiary, uint256 amount) internal {\n require(beneficiary != address(0), \"AA90 invalid beneficiary\");\n (bool success,) = beneficiary.call{value : amount}(\"\");\n require(success, \"AA91 failed send to beneficiary\");\n }\n\n /**\n * execute a user op\n * @param opIndex index into the opInfo array\n * @param userOp the userOp to execute\n * @param opInfo the opInfo filled by validatePrepayment for this userOp.\n * @return collected the total amount this userOp paid.\n */\n function _executeUserOp(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory opInfo) private returns (uint256 collected) {\n uint256 preGas = gasleft();\n bytes memory context = getMemoryBytesFromOffset(opInfo.contextOffset);\n\n try this.innerHandleOp(userOp.callData, opInfo, context) returns (uint256 _actualGasCost) {\n collected = _actualGasCost;\n } catch {\n bytes32 innerRevertCode;\n assembly {\n returndatacopy(0, 0, 32)\n innerRevertCode := mload(0)\n }\n // handleOps was called with gas limit too low. abort entire bundle.\n if (innerRevertCode == INNER_OUT_OF_GAS) {\n //report paymaster, since if it is not deliberately caused by the bundler,\n // it must be a revert caused by paymaster.\n revert FailedOp(opIndex, \"AA95 out of gas\");\n }\n\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n collected = _handlePostOp(opIndex, IPaymaster.PostOpMode.postOpReverted, opInfo, context, actualGas);\n }\n }\n\n /**\n * Execute a batch of UserOperations.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) public {\n\n uint256 opslen = ops.length;\n UserOpInfo[] memory opInfos = new UserOpInfo[](opslen);\n\n unchecked {\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[i];\n (uint256 validationData, uint256 pmValidationData) = _validatePrepayment(i, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, pmValidationData, address(0));\n }\n\n uint256 collected = 0;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(i, ops[i], opInfos[i]);\n }\n\n _compensate(beneficiary, collected);\n } //unchecked\n }\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) public {\n\n uint256 opasLen = opsPerAggregator.length;\n uint256 totalOps = 0;\n for (uint256 i = 0; i < opasLen; i++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[i];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n //address(1) is special marker of \"signature error\"\n require(address(aggregator) != address(1), \"AA96 invalid aggregator\");\n\n if (address(aggregator) != address(0)) {\n // solhint-disable-next-line no-empty-blocks\n try aggregator.validateSignatures(ops, opa.signature) {}\n catch {\n revert SignatureValidationFailed(address(aggregator));\n }\n }\n\n totalOps += ops.length;\n }\n\n UserOpInfo[] memory opInfos = new UserOpInfo[](totalOps);\n\n uint256 opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n uint256 opslen = ops.length;\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[opIndex];\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(opIndex, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, paymasterValidationData, address(aggregator));\n opIndex++;\n }\n }\n\n uint256 collected = 0;\n opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n emit SignatureAggregatorChanged(address(opa.aggregator));\n UserOperation[] calldata ops = opa.userOps;\n uint256 opslen = ops.length;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(opIndex, ops[i], opInfos[opIndex]);\n opIndex++;\n }\n }\n emit SignatureAggregatorChanged(address(0));\n\n _compensate(beneficiary, collected);\n }\n\n /// @inheritdoc IEntryPoint\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external override {\n\n UserOpInfo memory opInfo;\n _simulationOnlyValidations(op);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, op, opInfo);\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n\n numberMarker();\n uint256 paid = _executeUserOp(0, op, opInfo);\n numberMarker();\n bool targetSuccess;\n bytes memory targetResult;\n if (target != address(0)) {\n (targetSuccess, targetResult) = target.call(targetCallData);\n }\n revert ExecutionResult(opInfo.preOpGas, paid, data.validAfter, data.validUntil, targetSuccess, targetResult);\n }\n\n\n // A memory copy of UserOp static fields only.\n // Excluding: callData, initCode and signature. Replacing paymasterAndData with paymaster.\n struct MemoryUserOp {\n address sender;\n uint256 nonce;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n address paymaster;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n }\n\n struct UserOpInfo {\n MemoryUserOp mUserOp;\n bytes32 userOpHash;\n uint256 prefund;\n uint256 contextOffset;\n uint256 preOpGas;\n }\n\n /**\n * inner function to handle a UserOperation.\n * Must be declared \"external\" to open a call context, but it can only be called by handleOps.\n */\n function innerHandleOp(bytes memory callData, UserOpInfo memory opInfo, bytes calldata context) external returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n require(msg.sender == address(this), \"AA92 internal call only\");\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n\n uint callGasLimit = mUserOp.callGasLimit;\n unchecked {\n // handleOps was called with gas limit too low. abort entire bundle.\n if (gasleft() < callGasLimit + mUserOp.verificationGasLimit + 5000) {\n assembly {\n mstore(0, INNER_OUT_OF_GAS)\n revert(0, 32)\n }\n }\n }\n\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\n if (callData.length > 0) {\n bool success = Exec.call(mUserOp.sender, 0, callData, callGasLimit);\n if (!success) {\n bytes memory result = Exec.getReturnData(REVERT_REASON_MAX_LEN);\n if (result.length > 0) {\n emit UserOperationRevertReason(opInfo.userOpHash, mUserOp.sender, mUserOp.nonce, result);\n }\n mode = IPaymaster.PostOpMode.opReverted;\n }\n }\n\n unchecked {\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n //note: opIndex is ignored (relevant only if mode==postOpReverted, which is only possible outside of innerHandleOp)\n return _handlePostOp(0, mode, opInfo, context, actualGas);\n }\n }\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) public view returns (bytes32) {\n return keccak256(abi.encode(userOp.hash(), address(this), block.chainid));\n }\n\n /**\n * copy general fields from userOp into the memory opInfo structure.\n */\n function _copyUserOpToMemory(UserOperation calldata userOp, MemoryUserOp memory mUserOp) internal pure {\n mUserOp.sender = userOp.sender;\n mUserOp.nonce = userOp.nonce;\n mUserOp.callGasLimit = userOp.callGasLimit;\n mUserOp.verificationGasLimit = userOp.verificationGasLimit;\n mUserOp.preVerificationGas = userOp.preVerificationGas;\n mUserOp.maxFeePerGas = userOp.maxFeePerGas;\n mUserOp.maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes calldata paymasterAndData = userOp.paymasterAndData;\n if (paymasterAndData.length > 0) {\n require(paymasterAndData.length >= 20, \"AA93 invalid paymasterAndData\");\n mUserOp.paymaster = address(bytes20(paymasterAndData[: 20]));\n } else {\n mUserOp.paymaster = address(0);\n }\n }\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external {\n UserOpInfo memory outOpInfo;\n\n _simulationOnlyValidations(userOp);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, userOp, outOpInfo);\n StakeInfo memory paymasterInfo = _getStakeInfo(outOpInfo.mUserOp.paymaster);\n StakeInfo memory senderInfo = _getStakeInfo(outOpInfo.mUserOp.sender);\n StakeInfo memory factoryInfo;\n {\n bytes calldata initCode = userOp.initCode;\n address factory = initCode.length >= 20 ? address(bytes20(initCode[0 : 20])) : address(0);\n factoryInfo = _getStakeInfo(factory);\n }\n\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n address aggregator = data.aggregator;\n bool sigFailed = aggregator == address(1);\n ReturnInfo memory returnInfo = ReturnInfo(outOpInfo.preOpGas, outOpInfo.prefund,\n sigFailed, data.validAfter, data.validUntil, getMemoryBytesFromOffset(outOpInfo.contextOffset));\n\n if (aggregator != address(0) && aggregator != address(1)) {\n AggregatorStakeInfo memory aggregatorInfo = AggregatorStakeInfo(aggregator, _getStakeInfo(aggregator));\n revert ValidationResultWithAggregation(returnInfo, senderInfo, factoryInfo, paymasterInfo, aggregatorInfo);\n }\n revert ValidationResult(returnInfo, senderInfo, factoryInfo, paymasterInfo);\n\n }\n\n function _getRequiredPrefund(MemoryUserOp memory mUserOp) internal pure returns (uint256 requiredPrefund) {\n unchecked {\n //when using a Paymaster, the verificationGasLimit is used also to as a limit for the postOp call.\n // our security model might call postOp eventually twice\n uint256 mul = mUserOp.paymaster != address(0) ? 3 : 1;\n uint256 requiredGas = mUserOp.callGasLimit + mUserOp.verificationGasLimit * mul + mUserOp.preVerificationGas;\n\n requiredPrefund = requiredGas * mUserOp.maxFeePerGas;\n }\n }\n\n // create the sender's contract if needed.\n function _createSenderIfNeeded(uint256 opIndex, UserOpInfo memory opInfo, bytes calldata initCode) internal {\n if (initCode.length != 0) {\n address sender = opInfo.mUserOp.sender;\n if (sender.code.length != 0) revert FailedOp(opIndex, \"AA10 sender already constructed\");\n address sender1 = senderCreator.createSender{gas : opInfo.mUserOp.verificationGasLimit}(initCode);\n if (sender1 == address(0)) revert FailedOp(opIndex, \"AA13 initCode failed or OOG\");\n if (sender1 != sender) revert FailedOp(opIndex, \"AA14 initCode must return sender\");\n if (sender1.code.length == 0) revert FailedOp(opIndex, \"AA15 initCode must create sender\");\n address factory = address(bytes20(initCode[0 : 20]));\n emit AccountDeployed(opInfo.userOpHash, sender, factory, opInfo.mUserOp.paymaster);\n }\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes calldata initCode) public {\n revert SenderAddressResult(senderCreator.createSender(initCode));\n }\n\n function _simulationOnlyValidations(UserOperation calldata userOp) internal view {\n // solhint-disable-next-line no-empty-blocks\n try this._validateSenderAndPaymaster(userOp.initCode, userOp.sender, userOp.paymasterAndData) {}\n catch Error(string memory revertReason) {\n if (bytes(revertReason).length != 0) {\n revert FailedOp(0, revertReason);\n }\n }\n }\n\n /**\n * Called only during simulation.\n * This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\n */\n function _validateSenderAndPaymaster(bytes calldata initCode, address sender, bytes calldata paymasterAndData) external view {\n if (initCode.length == 0 && sender.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA20 account not deployed\");\n }\n if (paymasterAndData.length >= 20) {\n address paymaster = address(bytes20(paymasterAndData[0 : 20]));\n if (paymaster.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA30 paymaster not deployed\");\n }\n }\n // always revert\n revert(\"\");\n }\n\n /**\n * call account.validateUserOp.\n * revert (with FailedOp) in case validateUserOp reverts, or account didn't send required prefund.\n * decrement account's deposit if needed\n */\n function _validateAccountPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPrefund)\n internal returns (uint256 gasUsedByValidateAccountPrepayment, uint256 validationData) {\n unchecked {\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n address sender = mUserOp.sender;\n _createSenderIfNeeded(opIndex, opInfo, op.initCode);\n address paymaster = mUserOp.paymaster;\n numberMarker();\n uint256 missingAccountFunds = 0;\n if (paymaster == address(0)) {\n uint256 bal = balanceOf(sender);\n missingAccountFunds = bal > requiredPrefund ? 0 : requiredPrefund - bal;\n }\n try IAccount(sender).validateUserOp{gas : mUserOp.verificationGasLimit}(op, opInfo.userOpHash, missingAccountFunds)\n returns (uint256 _validationData) {\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA23 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA23 reverted (or OOG)\");\n }\n if (paymaster == address(0)) {\n DepositInfo storage senderInfo = deposits[sender];\n uint256 deposit = senderInfo.deposit;\n if (requiredPrefund > deposit) {\n revert FailedOp(opIndex, \"AA21 didn't pay prefund\");\n }\n senderInfo.deposit = uint112(deposit - requiredPrefund);\n }\n gasUsedByValidateAccountPrepayment = preGas - gasleft();\n }\n }\n\n /**\n * In case the request has a paymaster:\n * Validate paymaster has enough deposit.\n * Call paymaster.validatePaymasterUserOp.\n * Revert with proper FailedOp in case paymaster reverts.\n * Decrement paymaster's deposit\n */\n function _validatePaymasterPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPreFund, uint256 gasUsedByValidateAccountPrepayment)\n internal returns (bytes memory context, uint256 validationData) {\n unchecked {\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 verificationGasLimit = mUserOp.verificationGasLimit;\n require(verificationGasLimit > gasUsedByValidateAccountPrepayment, \"AA41 too little verificationGas\");\n uint256 gas = verificationGasLimit - gasUsedByValidateAccountPrepayment;\n\n address paymaster = mUserOp.paymaster;\n DepositInfo storage paymasterInfo = deposits[paymaster];\n uint256 deposit = paymasterInfo.deposit;\n if (deposit < requiredPreFund) {\n revert FailedOp(opIndex, \"AA31 paymaster deposit too low\");\n }\n paymasterInfo.deposit = uint112(deposit - requiredPreFund);\n try IPaymaster(paymaster).validatePaymasterUserOp{gas : gas}(op, opInfo.userOpHash, requiredPreFund) returns (bytes memory _context, uint256 _validationData){\n context = _context;\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA33 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA33 reverted (or OOG)\");\n }\n }\n }\n\n /**\n * revert if either account validationData or paymaster validationData is expired\n */\n function _validateAccountAndPaymasterValidationData(uint256 opIndex, uint256 validationData, uint256 paymasterValidationData, address expectedAggregator) internal view {\n (address aggregator, bool outOfTimeRange) = _getValidationData(validationData);\n if (expectedAggregator != aggregator) {\n revert FailedOp(opIndex, \"AA24 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA22 expired or not due\");\n }\n //pmAggregator is not a real signature aggregator: we don't have logic to handle it as address.\n // non-zero address means that the paymaster fails due to some signature check (which is ok only during estimation)\n address pmAggregator;\n (pmAggregator, outOfTimeRange) = _getValidationData(paymasterValidationData);\n if (pmAggregator != address(0)) {\n revert FailedOp(opIndex, \"AA34 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA32 paymaster expired or not due\");\n }\n }\n\n function _getValidationData(uint256 validationData) internal view returns (address aggregator, bool outOfTimeRange) {\n if (validationData == 0) {\n return (address(0), false);\n }\n ValidationData memory data = _parseValidationData(validationData);\n // solhint-disable-next-line not-rely-on-time\n outOfTimeRange = block.timestamp > data.validUntil || block.timestamp < data.validAfter;\n aggregator = data.aggregator;\n }\n\n /**\n * validate account and paymaster (if defined).\n * also make sure total validation doesn't exceed verificationGasLimit\n * this method is called off-chain (simulateValidation()) and on-chain (from handleOps)\n * @param opIndex the index of this userOp into the \"opInfos\" array\n * @param userOp the userOp to validate\n */\n function _validatePrepayment(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory outOpInfo)\n private returns (uint256 validationData, uint256 paymasterValidationData) {\n\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = outOpInfo.mUserOp;\n _copyUserOpToMemory(userOp, mUserOp);\n outOpInfo.userOpHash = getUserOpHash(userOp);\n\n // validate all numeric values in userOp are well below 128 bit, so they can safely be added\n // and multiplied without causing overflow\n uint256 maxGasValues = mUserOp.preVerificationGas | mUserOp.verificationGasLimit | mUserOp.callGasLimit |\n userOp.maxFeePerGas | userOp.maxPriorityFeePerGas;\n require(maxGasValues <= type(uint120).max, \"AA94 gas values overflow\");\n\n uint256 gasUsedByValidateAccountPrepayment;\n (uint256 requiredPreFund) = _getRequiredPrefund(mUserOp);\n (gasUsedByValidateAccountPrepayment, validationData) = _validateAccountPrepayment(opIndex, userOp, outOpInfo, requiredPreFund);\n //a \"marker\" where account opcode validation is done and paymaster opcode validation is about to start\n // (used only by off-chain simulateValidation)\n numberMarker();\n\n bytes memory context;\n if (mUserOp.paymaster != address(0)) {\n (context, paymasterValidationData) = _validatePaymasterPrepayment(opIndex, userOp, outOpInfo, requiredPreFund, gasUsedByValidateAccountPrepayment);\n }\n unchecked {\n uint256 gasUsed = preGas - gasleft();\n\n if (userOp.verificationGasLimit < gasUsed) {\n revert FailedOp(opIndex, \"AA40 over verificationGasLimit\");\n }\n outOpInfo.prefund = requiredPreFund;\n outOpInfo.contextOffset = getOffsetOfMemoryBytes(context);\n outOpInfo.preOpGas = preGas - gasleft() + userOp.preVerificationGas;\n }\n }\n\n /**\n * process post-operation.\n * called just after the callData is executed.\n * if a paymaster is defined and its validation returned a non-empty context, its postOp is called.\n * the excess amount is refunded to the account (or paymaster - if it was used in the request)\n * @param opIndex index in the batch\n * @param mode - whether is called from innerHandleOp, or outside (postOpReverted)\n * @param opInfo userOp fields and info collected during validation\n * @param context the context returned in validatePaymasterUserOp\n * @param actualGas the gas used so far by this user operation\n */\n function _handlePostOp(uint256 opIndex, IPaymaster.PostOpMode mode, UserOpInfo memory opInfo, bytes memory context, uint256 actualGas) private returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n unchecked {\n address refundAddress;\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 gasPrice = getUserOpGasPrice(mUserOp);\n\n address paymaster = mUserOp.paymaster;\n if (paymaster == address(0)) {\n refundAddress = mUserOp.sender;\n } else {\n refundAddress = paymaster;\n if (context.length > 0) {\n actualGasCost = actualGas * gasPrice;\n if (mode != IPaymaster.PostOpMode.postOpReverted) {\n IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost);\n } else {\n // solhint-disable-next-line no-empty-blocks\n try IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost) {}\n catch Error(string memory reason) {\n revert FailedOp(opIndex, string.concat(\"AA50 postOp reverted: \", reason));\n }\n catch {\n revert FailedOp(opIndex, \"AA50 postOp revert\");\n }\n }\n }\n }\n actualGas += preGas - gasleft();\n actualGasCost = actualGas * gasPrice;\n if (opInfo.prefund < actualGasCost) {\n revert FailedOp(opIndex, \"AA51 prefund below actualGasCost\");\n }\n uint256 refund = opInfo.prefund - actualGasCost;\n _incrementDeposit(refundAddress, refund);\n bool success = mode == IPaymaster.PostOpMode.opSucceeded;\n emit UserOperationEvent(opInfo.userOpHash, mUserOp.sender, mUserOp.paymaster, mUserOp.nonce, success, actualGasCost, actualGas);\n } // unchecked\n }\n\n /**\n * the gas price this UserOp agrees to pay.\n * relayer/block builder might submit the TX with higher priorityFee, but the user should not\n */\n function getUserOpGasPrice(MemoryUserOp memory mUserOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = mUserOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = mUserOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n\n function getOffsetOfMemoryBytes(bytes memory data) internal pure returns (uint256 offset) {\n assembly {offset := data}\n }\n\n function getMemoryBytesFromOffset(uint256 offset) internal pure returns (bytes memory data) {\n assembly {data := offset}\n }\n\n //place the NUMBER opcode in the code.\n // this is used as a marker during simulation, as this OP is completely banned from the simulated code of the\n // account and paymaster.\n function numberMarker() internal view {\n assembly {mstore(0, number())}\n }\n}\n\n" - }, - "contracts/core/Helpers.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * returned data from validateUserOp.\n * validateUserOp returns a uint256, with is created by `_packedValidationData` and parsed by `_parseValidationData`\n * @param aggregator - address(0) - the account validated the signature by itself.\n * address(1) - the account failed to validate the signature.\n * otherwise - this is an address of a signature aggregator that must be used to validate the signature.\n * @param validAfter - this UserOp is valid only after this timestamp.\n * @param validaUntil - this UserOp is valid only up to this timestamp.\n */\n struct ValidationData {\n address aggregator;\n uint48 validAfter;\n uint48 validUntil;\n }\n\n//extract sigFailed, validAfter, validUntil.\n// also convert zero validUntil to type(uint48).max\n function _parseValidationData(uint validationData) pure returns (ValidationData memory data) {\n address aggregator = address(uint160(validationData));\n uint48 validUntil = uint48(validationData >> 160);\n if (validUntil == 0) {\n validUntil = type(uint48).max;\n }\n uint48 validAfter = uint48(validationData >> (48 + 160));\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n// intersect account and paymaster ranges.\n function _intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) pure returns (ValidationData memory) {\n ValidationData memory accountValidationData = _parseValidationData(validationData);\n ValidationData memory pmValidationData = _parseValidationData(paymasterValidationData);\n address aggregator = accountValidationData.aggregator;\n if (aggregator == address(0)) {\n aggregator = pmValidationData.aggregator;\n }\n uint48 validAfter = accountValidationData.validAfter;\n uint48 validUntil = accountValidationData.validUntil;\n uint48 pmValidAfter = pmValidationData.validAfter;\n uint48 pmValidUntil = pmValidationData.validUntil;\n\n if (validAfter < pmValidAfter) validAfter = pmValidAfter;\n if (validUntil > pmValidUntil) validUntil = pmValidUntil;\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n/**\n * helper to pack the return value for validateUserOp\n * @param data - the ValidationData to pack\n */\n function _packValidationData(ValidationData memory data) pure returns (uint256) {\n return uint160(data.aggregator) | (uint256(data.validUntil) << 160) | (uint256(data.validAfter) << (160 + 48));\n }\n\n/**\n * helper to pack the return value for validateUserOp, when not using an aggregator\n * @param sigFailed - true for signature failure, false for success\n * @param validUntil last timestamp this UserOperation is valid (or zero for infinite)\n * @param validAfter first timestamp this UserOperation is valid\n */\n function _packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) pure returns (uint256) {\n return (sigFailed ? 1 : 0) | (uint256(validUntil) << 160) | (uint256(validAfter) << (160 + 48));\n }\n" - }, - "contracts/core/SenderCreator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * helper contract for EntryPoint, to call userOp.initCode from a \"neutral\" address,\n * which is explicitly not the entryPoint itself.\n */\ncontract SenderCreator {\n\n /**\n * call the \"initCode\" factory to create and return the sender account address\n * @param initCode the initCode value from a UserOp. contains 20 bytes of factory address, followed by calldata\n * @return sender the returned address of the created account, or zero address on failure.\n */\n function createSender(bytes calldata initCode) external returns (address sender) {\n address factory = address(bytes20(initCode[0 : 20]));\n bytes memory initCallData = initCode[20 :];\n bool success;\n /* solhint-disable no-inline-assembly */\n assembly {\n success := call(gas(), factory, 0, add(initCallData, 0x20), mload(initCallData), 0, 32)\n sender := mload(0)\n }\n if (!success) {\n sender = address(0);\n }\n }\n}\n" - }, - "contracts/core/StakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IStakeManager.sol\";\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable not-rely-on-time */\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by a paymaster.\n */\nabstract contract StakeManager is IStakeManager {\n\n /// maps paymaster to their deposits and stakes\n mapping(address => DepositInfo) public deposits;\n\n /// @inheritdoc IStakeManager\n function getDepositInfo(address account) public view returns (DepositInfo memory info) {\n return deposits[account];\n }\n\n // internal method to return just the stake info\n function _getStakeInfo(address addr) internal view returns (StakeInfo memory info) {\n DepositInfo storage depositInfo = deposits[addr];\n info.stake = depositInfo.stake;\n info.unstakeDelaySec = depositInfo.unstakeDelaySec;\n }\n\n /// return the deposit (for gas payment) of the account\n function balanceOf(address account) public view returns (uint256) {\n return deposits[account].deposit;\n }\n\n receive() external payable {\n depositTo(msg.sender);\n }\n\n function _incrementDeposit(address account, uint256 amount) internal {\n DepositInfo storage info = deposits[account];\n uint256 newAmount = info.deposit + amount;\n require(newAmount <= type(uint112).max, \"deposit overflow\");\n info.deposit = uint112(newAmount);\n }\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) public payable {\n _incrementDeposit(account, msg.value);\n DepositInfo storage info = deposits[account];\n emit Deposited(account, info.deposit);\n }\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 unstakeDelaySec) public payable {\n DepositInfo storage info = deposits[msg.sender];\n require(unstakeDelaySec > 0, \"must specify unstake delay\");\n require(unstakeDelaySec >= info.unstakeDelaySec, \"cannot decrease unstake time\");\n uint256 stake = info.stake + msg.value;\n require(stake > 0, \"no stake specified\");\n require(stake <= type(uint112).max, \"stake overflow\");\n deposits[msg.sender] = DepositInfo(\n info.deposit,\n true,\n uint112(stake),\n unstakeDelaySec,\n 0\n );\n emit StakeLocked(msg.sender, stake, unstakeDelaySec);\n }\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external {\n DepositInfo storage info = deposits[msg.sender];\n require(info.unstakeDelaySec != 0, \"not staked\");\n require(info.staked, \"already unstaking\");\n uint48 withdrawTime = uint48(block.timestamp) + info.unstakeDelaySec;\n info.withdrawTime = withdrawTime;\n info.staked = false;\n emit StakeUnlocked(msg.sender, withdrawTime);\n }\n\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external {\n DepositInfo storage info = deposits[msg.sender];\n uint256 stake = info.stake;\n require(stake > 0, \"No stake to withdraw\");\n require(info.withdrawTime > 0, \"must call unlockStake() first\");\n require(info.withdrawTime <= block.timestamp, \"Stake withdrawal is not due\");\n info.unstakeDelaySec = 0;\n info.withdrawTime = 0;\n info.stake = 0;\n emit StakeWithdrawn(msg.sender, withdrawAddress, stake);\n (bool success,) = withdrawAddress.call{value : stake}(\"\");\n require(success, \"failed to withdraw stake\");\n }\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external {\n DepositInfo storage info = deposits[msg.sender];\n require(withdrawAmount <= info.deposit, \"Withdraw amount too large\");\n info.deposit = uint112(info.deposit - withdrawAmount);\n emit Withdrawn(msg.sender, withdrawAddress, withdrawAmount);\n (bool success,) = withdrawAddress.call{value : withdrawAmount}(\"\");\n require(success, \"failed to withdraw\");\n }\n}\n" - }, - "contracts/interfaces/IAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\ninterface IAccount {\n\n /**\n * Validate user's signature and nonce\n * the entryPoint will make the call to the recipient only if this validation call returns successfully.\n * signature failure should be reported by returning SIG_VALIDATION_FAILED (1).\n * This allows making a \"simulation call\" without a valid signature\n * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure.\n *\n * @dev Must validate caller is the entryPoint.\n * Must validate the signature and nonce\n * @param userOp the operation that is about to be executed.\n * @param userOpHash hash of the user's request data. can be used as the basis for signature.\n * @param missingAccountFunds missing funds on the account's deposit in the entrypoint.\n * This is the minimum amount to transfer to the sender(entryPoint) to be able to make the call.\n * The excess is left as a deposit in the entrypoint, for future calls.\n * can be withdrawn anytime using \"entryPoint.withdrawTo()\"\n * In case there is a paymaster in the request (or the current deposit is high enough), this value will be zero.\n * @return validationData packaged ValidationData structure. use `_packValidationData` and `_unpackValidationData` to encode and decode\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * If an account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external returns (uint256 validationData);\n}\n" - }, - "contracts/interfaces/IAggregator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * Aggregated Signatures validator.\n */\ninterface IAggregator {\n\n /**\n * validate aggregated signature.\n * revert if the aggregated signature does not match the given list of operations.\n */\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external view;\n\n /**\n * validate signature of a single userOp\n * This method is should be called by bundler after EntryPoint.simulateValidation() returns (reverts) with ValidationResultWithAggregation\n * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps.\n * @param userOp the userOperation received from the user.\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\n * (usually empty, unless account and aggregator support some kind of \"multisig\"\n */\n function validateUserOpSignature(UserOperation calldata userOp)\n external view returns (bytes memory sigForUserOp);\n\n /**\n * aggregate multiple signatures into a single value.\n * This method is called off-chain to calculate the signature to pass with handleOps()\n * bundler MAY use optimized custom code perform this aggregation\n * @param userOps array of UserOperations to collect the signatures from.\n * @return aggregatedSignature the aggregated signature\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external view returns (bytes memory aggregatedSignature);\n}\n" - }, - "contracts/interfaces/IEntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"./UserOperation.sol\";\nimport \"./IStakeManager.sol\";\nimport \"./IAggregator.sol\";\n\ninterface IEntryPoint is IStakeManager {\n\n /***\n * An event emitted after each successful request\n * @param userOpHash - unique identifier for the request (hash its entire content, except signature).\n * @param sender - the account that generates this request.\n * @param paymaster - if non-null, the paymaster that pays for this request.\n * @param nonce - the nonce value from the request.\n * @param success - true if the sender transaction succeeded, false if reverted.\n * @param actualGasCost - actual amount paid (by account or paymaster) for this UserOperation.\n * @param actualGasUsed - total gas used by this UserOperation (including preVerification, creation, validation and execution).\n */\n event UserOperationEvent(bytes32 indexed userOpHash, address indexed sender, address indexed paymaster, uint256 nonce, bool success, uint256 actualGasCost, uint256 actualGasUsed);\n\n /**\n * account \"sender\" was deployed.\n * @param userOpHash the userOp that deployed this account. UserOperationEvent will follow.\n * @param sender the account that is deployed\n * @param factory the factory used to deploy this account (in the initCode)\n * @param paymaster the paymaster used by this UserOp\n */\n event AccountDeployed(bytes32 indexed userOpHash, address indexed sender, address factory, address paymaster);\n\n /**\n * An event emitted if the UserOperation \"callData\" reverted with non-zero length\n * @param userOpHash the request unique identifier.\n * @param sender the sender of this request\n * @param nonce the nonce used in the request\n * @param revertReason - the return bytes from the (reverted) call to \"callData\".\n */\n event UserOperationRevertReason(bytes32 indexed userOpHash, address indexed sender, uint256 nonce, bytes revertReason);\n\n /**\n * signature aggregator used by the following UserOperationEvents within this bundle.\n */\n event SignatureAggregatorChanged(address indexed aggregator);\n\n /**\n * a custom revert error of handleOps, to identify the offending op.\n * NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\n * @param opIndex - index into the array of ops to the failed one (in simulateValidation, this is always zero)\n * @param reason - revert reason\n * The string starts with a unique code \"AAmn\", where \"m\" is \"1\" for factory, \"2\" for account and \"3\" for paymaster issues,\n * so a failure can be attributed to the correct entity.\n * Should be caught in off-chain handleOps simulation and not happen on-chain.\n * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\n */\n error FailedOp(uint256 opIndex, string reason);\n\n /**\n * error case when a signature aggregator fails to verify the aggregated signature it had created.\n */\n error SignatureValidationFailed(address aggregator);\n\n /**\n * Successful result from simulateValidation.\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n */\n error ValidationResult(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo);\n\n /**\n * Successful result from simulateValidation, if the account returns a signature aggregator\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n * @param aggregatorInfo signature aggregation info (if the account requires signature aggregator)\n * bundler MUST use it to verify the signature, or reject the UserOperation\n */\n error ValidationResultWithAggregation(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo,\n AggregatorStakeInfo aggregatorInfo);\n\n /**\n * return value of getSenderAddress\n */\n error SenderAddressResult(address sender);\n\n /**\n * return value of simulateHandleOp\n */\n error ExecutionResult(uint256 preOpGas, uint256 paid, uint48 validAfter, uint48 validUntil, bool targetSuccess, bytes targetResult);\n\n //UserOps handled, per aggregator\n struct UserOpsPerAggregator {\n UserOperation[] userOps;\n\n // aggregator address\n IAggregator aggregator;\n // aggregated signature\n bytes signature;\n }\n\n /**\n * Execute a batch of UserOperation.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) external;\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) external;\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) external view returns (bytes32);\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external;\n\n /**\n * gas and return values during simulation\n * @param preOpGas the gas used for validation (including preValidationGas)\n * @param prefund the required prefund for this operation\n * @param sigFailed validateUserOp's (or paymaster's) signature check failed\n * @param validAfter - first timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param validUntil - last timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param paymasterContext returned by validatePaymasterUserOp (to be passed into postOp)\n */\n struct ReturnInfo {\n uint256 preOpGas;\n uint256 prefund;\n bool sigFailed;\n uint48 validAfter;\n uint48 validUntil;\n bytes paymasterContext;\n }\n\n /**\n * returned aggregated signature info.\n * the aggregator returned by the account, and its current stake.\n */\n struct AggregatorStakeInfo {\n address aggregator;\n StakeInfo stakeInfo;\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes memory initCode) external;\n\n\n /**\n * simulate full execution of a UserOperation (including both validation and target execution)\n * this method will always revert with \"ExecutionResult\".\n * it performs full validation of the UserOperation, but ignores signature error.\n * an optional target address is called after the userop succeeds, and its value is returned\n * (before the entire call is reverted)\n * Note that in order to collect the the success/failure of the target call, it must be executed\n * with trace enabled to track the emitted events.\n * @param op the UserOperation to simulate\n * @param target if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult\n * are set to the return from that call.\n * @param targetCallData callData to pass to target address\n */\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external;\n}\n\n" - }, - "contracts/interfaces/IPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * the interface exposed by a paymaster contract, who agrees to pay the gas for user's operations.\n * a paymaster must hold a stake to cover the required entrypoint stake and also the gas for the transaction.\n */\ninterface IPaymaster {\n\n enum PostOpMode {\n opSucceeded, // user op succeeded\n opReverted, // user op reverted. still has to pay for gas.\n postOpReverted //user op succeeded, but caused postOp to revert. Now it's a 2nd call, after user's op was deliberately reverted.\n }\n\n /**\n * payment validation: check if paymaster agrees to pay.\n * Must verify sender is the entryPoint.\n * Revert to reject this request.\n * Note that bundlers will reject this method if it changes the state, unless the paymaster is trusted (whitelisted)\n * The paymaster pre-pays using its deposit, and receive back a refund after the postOp method returns.\n * @param userOp the user operation\n * @param userOpHash hash of the user's request data.\n * @param maxCost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\n * @return context value to send to a postOp\n * zero length to signify postOp is not required.\n * @return validationData signature and time-range of this operation, encoded the same as the return value of validateUserOperation\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n external returns (bytes memory context, uint256 validationData);\n\n /**\n * post-operation handler.\n * Must verify sender is the entryPoint\n * @param mode enum with the following options:\n * opSucceeded - user operation succeeded.\n * opReverted - user op reverted. still has to pay for gas.\n * postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n * Now this is the 2nd call, after user's op was deliberately reverted.\n * @param context - the context value returned by validatePaymasterUserOp\n * @param actualGasCost - actual gas used so far (without this postOp call).\n */\n function postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) external;\n}\n" - }, - "contracts/interfaces/IStakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by the staked entity.\n */\ninterface IStakeManager {\n\n event Deposited(\n address indexed account,\n uint256 totalDeposit\n );\n\n event Withdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /// Emitted when stake or unstake delay are modified\n event StakeLocked(\n address indexed account,\n uint256 totalStaked,\n uint256 unstakeDelaySec\n );\n\n /// Emitted once a stake is scheduled for withdrawal\n event StakeUnlocked(\n address indexed account,\n uint256 withdrawTime\n );\n\n event StakeWithdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /**\n * @param deposit the entity's deposit\n * @param staked true if this entity is staked.\n * @param stake actual amount of ether staked for this entity.\n * @param unstakeDelaySec minimum delay to withdraw the stake.\n * @param withdrawTime - first block timestamp where 'withdrawStake' will be callable, or zero if already locked\n * @dev sizes were chosen so that (deposit,staked, stake) fit into one cell (used during handleOps)\n * and the rest fit into a 2nd cell.\n * 112 bit allows for 10^15 eth\n * 48 bit for full timestamp\n * 32 bit allows 150 years for unstake delay\n */\n struct DepositInfo {\n uint112 deposit;\n bool staked;\n uint112 stake;\n uint32 unstakeDelaySec;\n uint48 withdrawTime;\n }\n\n //API struct used by getStakeInfo and simulateValidation\n struct StakeInfo {\n uint256 stake;\n uint256 unstakeDelaySec;\n }\n\n /// @return info - full deposit information of given account\n function getDepositInfo(address account) external view returns (DepositInfo memory info);\n\n /// @return the deposit (for gas payment) of the account\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) external payable;\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param _unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 _unstakeDelaySec) external payable;\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external;\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external;\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external;\n}\n" - }, - "contracts/interfaces/UserOperation.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\n /**\n * User Operation struct\n * @param sender the sender account of this request.\n * @param nonce unique value the sender uses to verify it is not a replay.\n * @param initCode if set, the account contract will be created by this constructor/\n * @param callData the method call to execute on this account.\n * @param callGasLimit the gas limit passed to the callData method call.\n * @param verificationGasLimit gas used for validateUserOp and validatePaymasterUserOp.\n * @param preVerificationGas gas not calculated by the handleOps method, but added to the gas paid. Covers batch overhead.\n * @param maxFeePerGas same as EIP-1559 gas parameter.\n * @param maxPriorityFeePerGas same as EIP-1559 gas parameter.\n * @param paymasterAndData if set, this field holds the paymaster address and paymaster-specific data. the paymaster will pay for the transaction instead of the sender.\n * @param signature sender-verified signature over the entire request, the EntryPoint address and the chain ID.\n */\n struct UserOperation {\n\n address sender;\n uint256 nonce;\n bytes initCode;\n bytes callData;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n bytes paymasterAndData;\n bytes signature;\n }\n\n/**\n * Utility functions helpful when working with UserOperation structs.\n */\nlibrary UserOperationLib {\n\n function getSender(UserOperation calldata userOp) internal pure returns (address) {\n address data;\n //read sender from userOp, which is first userOp member (saves 800 gas...)\n assembly {data := calldataload(userOp)}\n return address(uint160(data));\n }\n\n //relayer/block builder might submit the TX with higher priorityFee, but the user should not\n // pay above what he signed for.\n function gasPrice(UserOperation calldata userOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n //lighter signature scheme. must match UserOp.ts#packUserOp\n bytes calldata sig = userOp.signature;\n // copy directly the userOp from calldata up to (but not including) the signature.\n // this encoding depends on the ABI encoding of calldata, but is much lighter to copy\n // than referencing each field separately.\n assembly {\n let ofs := userOp\n let len := sub(sub(sig.offset, ofs), 32)\n ret := mload(0x40)\n mstore(0x40, add(ret, add(len, 32)))\n mstore(ret, len)\n calldatacopy(add(ret, 32), ofs, len)\n }\n }\n\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\n return keccak256(pack(userOp));\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n}\n" - }, - "contracts/utils/Exec.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.5 <0.9.0;\n\n// solhint-disable no-inline-assembly\n\n/**\n * Utility functions helpful when making different kinds of contract calls in Solidity.\n */\nlibrary Exec {\n\n function call(\n address to,\n uint256 value,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function staticcall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal view returns (bool success) {\n assembly {\n success := staticcall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function delegateCall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n // get returned data from last call or calldelegate\n function getReturnData(uint256 maxLen) internal pure returns (bytes memory returnData) {\n assembly {\n let len := returndatasize()\n if gt(len, maxLen) {\n len := maxLen\n }\n let ptr := mload(0x40)\n mstore(0x40, add(ptr, add(len, 0x20)))\n mstore(ptr, len)\n returndatacopy(add(ptr, 0x20), 0, len)\n returnData := ptr\n }\n }\n\n // revert with explicit byte array (probably reverted info from call)\n function revertWithData(bytes memory returnData) internal pure {\n assembly {\n revert(add(returnData, 32), mload(returnData))\n }\n }\n\n function callAndRevert(address to, bytes memory data, uint256 maxLen) internal {\n bool success = call(to,0,data,gasleft());\n if (!success) {\n revertWithData(getReturnData(maxLen));\n }\n }\n}\n" - } - }, - "settings": { - "optimizer": { - "enabled": true, - "runs": 1000000 - }, - "viaIR": true, - "outputSelection": { - "*": { - "*": [ - "abi", - "evm.bytecode", - "evm.deployedBytecode", - "evm.methodIdentifiers", - "metadata" - ], - "": [ - "ast" - ] - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/matic/.chainId b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/matic/.chainId deleted file mode 100644 index 065fd3e79c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/matic/.chainId +++ /dev/null @@ -1 +0,0 @@ -137 diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/matic/EntryPoint.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/matic/EntryPoint.json deleted file mode 100644 index 037750fba7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/matic/EntryPoint.json +++ /dev/null @@ -1,1318 +0,0 @@ -{ - "address": "0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789", - "abi": [ - { - "inputs": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "paid", - "type": "uint256" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bool", - "name": "targetSuccess", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "targetResult", - "type": "bytes" - } - ], - "name": "ExecutionResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "opIndex", - "type": "uint256" - }, - { - "internalType": "string", - "name": "reason", - "type": "string" - } - ], - "name": "FailedOp", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - } - ], - "name": "SenderAddressResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureValidationFailed", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - } - ], - "name": "ValidationResult", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "stakeInfo", - "type": "tuple" - } - ], - "internalType": "struct IEntryPoint.AggregatorStakeInfo", - "name": "aggregatorInfo", - "type": "tuple" - } - ], - "name": "ValidationResultWithAggregation", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "factory", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "paymaster", - "type": "address" - } - ], - "name": "AccountDeployed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [], - "name": "BeforeExecution", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalDeposit", - "type": "uint256" - } - ], - "name": "Deposited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureAggregatorChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalStaked", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "name": "StakeLocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "withdrawTime", - "type": "uint256" - } - ], - "name": "StakeUnlocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "StakeWithdrawn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasUsed", - "type": "uint256" - } - ], - "name": "UserOperationEvent", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "revertReason", - "type": "bytes" - } - ], - "name": "UserOperationRevertReason", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "Withdrawn", - "type": "event" - }, - { - "inputs": [], - "name": "SIG_VALIDATION_FAILED", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - } - ], - "name": "_validateSenderAndPaymaster", - "outputs": [], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - } - ], - "name": "addStake", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "depositTo", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "deposits", - "outputs": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "getDepositInfo", - "outputs": [ - { - "components": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "internalType": "struct IStakeManager.DepositInfo", - "name": "info", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "getNonce", - "outputs": [ - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - } - ], - "name": "getSenderAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "getUserOpHash", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "userOps", - "type": "tuple[]" - }, - { - "internalType": "contract IAggregator", - "name": "aggregator", - "type": "address" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.UserOpsPerAggregator[]", - "name": "opsPerAggregator", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleAggregatedOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "ops", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "incrementNonce", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.MemoryUserOp", - "name": "mUserOp", - "type": "tuple" - }, - { - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "contextOffset", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.UserOpInfo", - "name": "opInfo", - "type": "tuple" - }, - { - "internalType": "bytes", - "name": "context", - "type": "bytes" - } - ], - "name": "innerHandleOp", - "outputs": [ - { - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - }, - { - "internalType": "uint192", - "name": "", - "type": "uint192" - } - ], - "name": "nonceSequenceNumber", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "op", - "type": "tuple" - }, - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "targetCallData", - "type": "bytes" - } - ], - "name": "simulateHandleOp", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "simulateValidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unlockStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - } - ], - "name": "withdrawStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "withdrawAmount", - "type": "uint256" - } - ], - "name": "withdrawTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "args": [], - "numDeployments": 2, - "solcInputHash": "a4c52f0671aad8941c53d6ead2063803", - "metadata": "{\"compiler\":{\"version\":\"0.8.17+commit.8df45f5f\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"paid\",\"type\":\"uint256\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bool\",\"name\":\"targetSuccess\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"targetResult\",\"type\":\"bytes\"}],\"name\":\"ExecutionResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"opIndex\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\"}],\"name\":\"FailedOp\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderAddressResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureValidationFailed\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResult\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"stakeInfo\",\"type\":\"tuple\"}],\"internalType\":\"struct IEntryPoint.AggregatorStakeInfo\",\"name\":\"aggregatorInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResultWithAggregation\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"factory\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"}],\"name\":\"AccountDeployed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"BeforeExecution\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalDeposit\",\"type\":\"uint256\"}],\"name\":\"Deposited\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureAggregatorChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalStaked\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"name\":\"StakeLocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"withdrawTime\",\"type\":\"uint256\"}],\"name\":\"StakeUnlocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"StakeWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasUsed\",\"type\":\"uint256\"}],\"name\":\"UserOperationEvent\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"revertReason\",\"type\":\"bytes\"}],\"name\":\"UserOperationRevertReason\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Withdrawn\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"SIG_VALIDATION_FAILED\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"}],\"name\":\"_validateSenderAndPaymaster\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"}],\"name\":\"addStake\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"depositTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"deposits\",\"outputs\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getDepositInfo\",\"outputs\":[{\"components\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"internalType\":\"struct IStakeManager.DepositInfo\",\"name\":\"info\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"}],\"name\":\"getSenderAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"getUserOpHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"userOps\",\"type\":\"tuple[]\"},{\"internalType\":\"contract IAggregator\",\"name\":\"aggregator\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.UserOpsPerAggregator[]\",\"name\":\"opsPerAggregator\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleAggregatedOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"ops\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"incrementNonce\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.MemoryUserOp\",\"name\":\"mUserOp\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"contextOffset\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.UserOpInfo\",\"name\":\"opInfo\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"context\",\"type\":\"bytes\"}],\"name\":\"innerHandleOp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"\",\"type\":\"uint192\"}],\"name\":\"nonceSequenceNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"op\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"targetCallData\",\"type\":\"bytes\"}],\"name\":\"simulateHandleOp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"simulateValidation\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unlockStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"}],\"name\":\"withdrawStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"withdrawAmount\",\"type\":\"uint256\"}],\"name\":\"withdrawTo\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"errors\":{\"FailedOp(uint256,string)\":[{\"params\":{\"opIndex\":\"- index into the array of ops to the failed one (in simulateValidation, this is always zero)\",\"reason\":\"- revert reason The string starts with a unique code \\\"AAmn\\\", where \\\"m\\\" is \\\"1\\\" for factory, \\\"2\\\" for account and \\\"3\\\" for paymaster issues, so a failure can be attributed to the correct entity. Should be caught in off-chain handleOps simulation and not happen on-chain. Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\"}}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"params\":{\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"params\":{\"aggregatorInfo\":\"signature aggregation info (if the account requires signature aggregator) bundler MUST use it to verify the signature, or reject the UserOperation\",\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}]},\"kind\":\"dev\",\"methods\":{\"addStake(uint32)\":{\"params\":{\"unstakeDelaySec\":\"the new lock duration before the deposit can be withdrawn.\"}},\"getDepositInfo(address)\":{\"returns\":{\"info\":\"- full deposit information of given account\"}},\"getNonce(address,uint192)\":{\"params\":{\"key\":\"the high 192 bit of the nonce\",\"sender\":\"the account address\"},\"returns\":{\"nonce\":\"a full nonce to pass for next UserOp with this sender.\"}},\"getSenderAddress(bytes)\":{\"params\":{\"initCode\":\"the constructor code to be passed into the UserOperation.\"}},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"opsPerAggregator\":\"the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\"}},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"ops\":\"the operations to execute\"}},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"params\":{\"op\":\"the UserOperation to simulate\",\"target\":\"if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult are set to the return from that call.\",\"targetCallData\":\"callData to pass to target address\"}},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"details\":\"this method always revert. Successful result is ValidationResult error. other errors are failures.The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\",\"params\":{\"userOp\":\"the user operation to validate.\"}},\"withdrawStake(address)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\"}},\"withdrawTo(address,uint256)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\",\"withdrawAmount\":\"the amount to withdraw.\"}}},\"version\":1},\"userdoc\":{\"errors\":{\"ExecutionResult(uint256,uint256,uint48,uint48,bool,bytes)\":[{\"notice\":\"return value of simulateHandleOp\"}],\"FailedOp(uint256,string)\":[{\"notice\":\"a custom revert error of handleOps, to identify the offending op. NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\"}],\"SenderAddressResult(address)\":[{\"notice\":\"return value of getSenderAddress\"}],\"SignatureValidationFailed(address)\":[{\"notice\":\"error case when a signature aggregator fails to verify the aggregated signature it had created.\"}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"notice\":\"Successful result from simulateValidation.\"}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"notice\":\"Successful result from simulateValidation, if the account returns a signature aggregator\"}]},\"events\":{\"AccountDeployed(bytes32,address,address,address)\":{\"notice\":\"account \\\"sender\\\" was deployed.\"},\"BeforeExecution()\":{\"notice\":\"an event emitted by handleOps(), before starting the execution loop. any event emitted before this event, is part of the validation.\"},\"SignatureAggregatorChanged(address)\":{\"notice\":\"signature aggregator used by the following UserOperationEvents within this bundle.\"},\"StakeLocked(address,uint256,uint256)\":{\"notice\":\"Emitted when stake or unstake delay are modified\"},\"StakeUnlocked(address,uint256)\":{\"notice\":\"Emitted once a stake is scheduled for withdrawal\"},\"UserOperationRevertReason(bytes32,address,uint256,bytes)\":{\"notice\":\"An event emitted if the UserOperation \\\"callData\\\" reverted with non-zero length\"}},\"kind\":\"user\",\"methods\":{\"SIG_VALIDATION_FAILED()\":{\"notice\":\"for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value in case of signature failure, instead of revert.\"},\"_validateSenderAndPaymaster(bytes,address,bytes)\":{\"notice\":\"Called only during simulation. This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\"},\"addStake(uint32)\":{\"notice\":\"add to the account's stake - amount and delay any pending unstake is first cancelled.\"},\"balanceOf(address)\":{\"notice\":\"return the deposit (for gas payment) of the account\"},\"depositTo(address)\":{\"notice\":\"add to the deposit of the given account\"},\"deposits(address)\":{\"notice\":\"maps paymaster to their deposits and stakes\"},\"getNonce(address,uint192)\":{\"notice\":\"Return the next nonce for this sender. Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop) But UserOp with different keys can come with arbitrary order.\"},\"getSenderAddress(bytes)\":{\"notice\":\"Get counterfactual sender address. Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation. this method always revert, and returns the address in SenderAddressResult error\"},\"getUserOpHash((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"generate a request Id - unique identifier for this request. the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\"},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperation with Aggregators\"},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperations. no signature aggregator is used. if any account requires an aggregator (that is, it returned an aggregator when performing simulateValidation), then handleAggregatedOps() must be used instead.\"},\"incrementNonce(uint192)\":{\"notice\":\"Manually increment the nonce of the sender. This method is exposed just for completeness.. Account does NOT need to call it, neither during validation, nor elsewhere, as the EntryPoint will update the nonce regardless. Possible use-case is call it with various keys to \\\"initialize\\\" their nonces to one, so that future UserOperations will not pay extra for the first transaction with a given key.\"},\"innerHandleOp(bytes,((address,uint256,uint256,uint256,uint256,address,uint256,uint256),bytes32,uint256,uint256,uint256),bytes)\":{\"notice\":\"inner function to handle a UserOperation. Must be declared \\\"external\\\" to open a call context, but it can only be called by handleOps.\"},\"nonceSequenceNumber(address,uint192)\":{\"notice\":\"The next valid sequence number for a given nonce key.\"},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"notice\":\"simulate full execution of a UserOperation (including both validation and target execution) this method will always revert with \\\"ExecutionResult\\\". it performs full validation of the UserOperation, but ignores signature error. an optional target address is called after the userop succeeds, and its value is returned (before the entire call is reverted) Note that in order to collect the the success/failure of the target call, it must be executed with trace enabled to track the emitted events.\"},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\"},\"unlockStake()\":{\"notice\":\"attempt to unlock the stake. the value can be withdrawn (using withdrawStake) after the unstake delay.\"},\"withdrawStake(address)\":{\"notice\":\"withdraw from the (unlocked) stake. must first call unlockStake and wait for the unstakeDelay to pass\"},\"withdrawTo(address,uint256)\":{\"notice\":\"withdraw from the deposit.\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/core/EntryPoint.sol\":\"EntryPoint\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":1000000},\"remappings\":[],\"viaIR\":true},\"sources\":{\"@openzeppelin/contracts/security/ReentrancyGuard.sol\":{\"keccak256\":\"0x190dd6f8d592b7e4e930feb7f4313aeb8e1c4ad3154c27ce1cf6a512fc30d8cc\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://4ce8dfb62d0c4fa260d6eec8f1cd47f5f2a044e11bde5b31d18072fa6e7d9010\",\"dweb:/ipfs/QmTyFztU3tLEcEDnqqiaW4UJetqsU77LXc6pjc9oTXCK5u\"]},\"contracts/core/EntryPoint.sol\":{\"keccak256\":\"0x04f86318b47f052d7308795ffae6ecec0d023d2458b4e17751b89a0e4acfcdc6\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://c9f6e359c8dbe875ad974d3a0fb7b3d62319a6b115c44bac1e4587ae2ad2edaf\",\"dweb:/ipfs/QmTSWTov2rUeYk8cwzrtsd3uVXokCYok4gMiZ1sPs9tycH\"]},\"contracts/core/Helpers.sol\":{\"keccak256\":\"0x591c87519f7155d1909210276b77925ab2722a99b7b5d5649aecc36ebbdb045a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://69643e83f68e6a13d5075c7565bfce326673b0bd98c432033c4603ea84835746\",\"dweb:/ipfs/QmSwSzjYyV7qudi5vvsmzHMG2Z4YJZxX51RRXXVCLaNcEU\"]},\"contracts/core/NonceManager.sol\":{\"keccak256\":\"0xa17a4a6fde70088ab18ffe6df830f3efa31f1cd0e1a7160336c96e3c94984d25\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://b38615df9f80c56282b72888e9ba1eb1a9413fa67a0dbf094deda7af9feb38e7\",\"dweb:/ipfs/QmSzcXetEJRH4UHuUmZiSgX6bFgfqHWfmyuxVnh4NosMk1\"]},\"contracts/core/SenderCreator.sol\":{\"keccak256\":\"0x44b9449fec82d6cdfb01d52fdd5a72f90099c651316123810cf9633f00b018c2\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a9c0487390e72638681d175c45bc92425c802fffdca4bd0ae8457782ee284612\",\"dweb:/ipfs/QmVbzuehCUWJWqEHyMWuc6cRVbxfcMdFsmGL9o4Wz7WY2x\"]},\"contracts/core/StakeManager.sol\":{\"keccak256\":\"0x21aa0956382bd000b1b8c3b1d19ca6ebcd6c9029eebb19c612fb38ee5dd2430a\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://0a625c8795354d9f429367f9c1d14eb8af7db9c7f2c2a2033e2066ced76a573a\",\"dweb:/ipfs/Qmd1j6UarUg54q1G2HCNCLQz8XGVZR1qxX7eQ6cytHpQPN\"]},\"contracts/interfaces/IAccount.sol\":{\"keccak256\":\"0x556a0e5980de18e90b115553ed502408155ba35f58642823010d9288047bc418\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a0f420134b79596db8737173c7b933ae0a33059e107b6327c43aa40d4744a9e4\",\"dweb:/ipfs/QmRo8s1AhXmEMV7uPYnbpYwU19e9Bk6jmYBJTiPx3Fo85W\"]},\"contracts/interfaces/IAggregator.sol\":{\"keccak256\":\"0x060e9ddb0152250c269ba0640dc5753834ac44cf182a2837d508c0c529cae26a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://20ed837bc5909c89ff1910246bf245a5dad6840aa939382e1694964eb7dbd37b\",\"dweb:/ipfs/QmTMybRq5yyghPDDs1ZCNAVB9sSJ4WHe6Q9mejuKPTAdNP\"]},\"contracts/interfaces/IEntryPoint.sol\":{\"keccak256\":\"0x3a90bf308819ed125fa4202f880999caff8a8686633b8ddb79a30ca240d5b8f8\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://d2d21cc92c2fdab2b58d21bc25d4cd0e8c284b922528a186b087b818d54bc6cf\",\"dweb:/ipfs/QmT1qrfuBjsv2rmRCDn8mgPXHp94hARJwzbcDuBLDTbFWd\"]},\"contracts/interfaces/INonceManager.sol\":{\"keccak256\":\"0x509871e6c63663cdcc3eba19920fe84e991f38b289b1377ac3c3a6d9f22d7e12\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://00fe21b4349b24c50df60e1a705179293982bd9e7a32b78d4bac9620f89e7fe2\",\"dweb:/ipfs/QmSFFYGfUwQbVa6hASjU7YxTvgi2HkfrPr4X5oPHscHg8b\"]},\"contracts/interfaces/IPaymaster.sol\":{\"keccak256\":\"0x36858ba8685024974f533530420688da3454d29996ebc42e410673a1ed2ec456\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://616cbcf51778b1961b7f20a547bec7efae6d1d565df0f651926241ed8bde9ad8\",\"dweb:/ipfs/QmaVsgffUUmeUJYgStvRr8cNZ1LBbrc3FYNLW4JT1dVLia\"]},\"contracts/interfaces/IStakeManager.sol\":{\"keccak256\":\"0xd227b02888cd4ac68daebcdfd992ec00f9fff66fa3b3bb16f656cd582fa3480f\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://b389da4714a138be63704a576a482505eab2855e263b38a93706395d8d42e7c3\",\"dweb:/ipfs/QmeeAZpdHwUXxqP8pxA7GNtoCGBmmH4FaqLLwScVKGxtxZ\"]},\"contracts/interfaces/UserOperation.sol\":{\"keccak256\":\"0x61374003361059087fdcf17967a7bba052badeaf5c7f0ae689166f8aafd3a45c\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://6ff83c59432e733bf6304dda27cd4b0f34401917dd535e2669cc842d2d26568c\",\"dweb:/ipfs/QmPJbHU5TAjHqUTZzAcicEeG2nknmwCN43L4EW9LHbknTN\"]},\"contracts/utils/Exec.sol\":{\"keccak256\":\"0x5b232117afbc2939f3ffc92745614867e9e1d475a3e1e5443adae13c200174f1\",\"license\":\"LGPL-3.0-only\",\"urls\":[\"bzz-raw://62e7365379a06ead7b47637945bcaee095d51aab1d3ac00ddec69443e6cbe9fe\",\"dweb:/ipfs/QmctG3aw4U3KMSMeJKoLJ1NJewjMWfppnd1m3kxNTe39Uy\"]}},\"version\":1}", - "bytecode": "0x60a080604052346200008957600160025561022c8181016001600160401b038111838210176200007357829162005d18833903906000f080156200006757608052604051615c8990816200008f82396080518181816113df01528181613e9501526141b60152f35b6040513d6000823e3d90fd5b634e487b7160e01b600052604160045260246000fd5b600080fdfe60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c634300081100336080806040523461001657610210908161001c8239f35b600080fdfe6080604052600436101561001257600080fd5b6000803560e01c63570e1a361461002857600080fd5b346100c95760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126100c95760043567ffffffffffffffff918282116100c957366023830112156100c95781600401359283116100c95736602484840101116100c9576100c561009e84602485016100fc565b60405173ffffffffffffffffffffffffffffffffffffffff90911681529081906020820190565b0390f35b80fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b90806014116101bb5767ffffffffffffffff917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec82018381116101cd575b604051937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f81600b8701160116850190858210908211176101c0575b604052808452602084019036848401116101bb576020946000600c819682946014880187378301015251923560601c5af19060005191156101b557565b60009150565b600080fd5b6101c86100cc565b610178565b6101d56100cc565b61013a56fea26469706673582212201927e80b76ab9b71c952137dd676621a9fdf520c25928815636594036eb1c40364736f6c63430008110033", - "deployedBytecode": "0x60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c63430008110033" -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/matic/solcInputs/a4c52f0671aad8941c53d6ead2063803.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/matic/solcInputs/a4c52f0671aad8941c53d6ead2063803.json deleted file mode 100644 index dd58ba5a3e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/matic/solcInputs/a4c52f0671aad8941c53d6ead2063803.json +++ /dev/null @@ -1,68 +0,0 @@ -{ - "language": "Solidity", - "sources": { - "@openzeppelin/contracts/security/ReentrancyGuard.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (security/ReentrancyGuard.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Contract module that helps prevent reentrant calls to a function.\n *\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\n * available, which can be applied to functions to make sure there are no nested\n * (reentrant) calls to them.\n *\n * Note that because there is a single `nonReentrant` guard, functions marked as\n * `nonReentrant` may not call one another. This can be worked around by making\n * those functions `private`, and then adding `external` `nonReentrant` entry\n * points to them.\n *\n * TIP: If you would like to learn more about reentrancy and alternative ways\n * to protect against it, check out our blog post\n * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].\n */\nabstract contract ReentrancyGuard {\n // Booleans are more expensive than uint256 or any type that takes up a full\n // word because each write operation emits an extra SLOAD to first read the\n // slot's contents, replace the bits taken up by the boolean, and then write\n // back. This is the compiler's defense against contract upgrades and\n // pointer aliasing, and it cannot be disabled.\n\n // The values being non-zero value makes deployment a bit more expensive,\n // but in exchange the refund on every call to nonReentrant will be lower in\n // amount. Since refunds are capped to a percentage of the total\n // transaction's gas, it is best to keep them low in cases like this one, to\n // increase the likelihood of the full refund coming into effect.\n uint256 private constant _NOT_ENTERED = 1;\n uint256 private constant _ENTERED = 2;\n\n uint256 private _status;\n\n constructor() {\n _status = _NOT_ENTERED;\n }\n\n /**\n * @dev Prevents a contract from calling itself, directly or indirectly.\n * Calling a `nonReentrant` function from another `nonReentrant`\n * function is not supported. It is possible to prevent this from happening\n * by making the `nonReentrant` function external, and making it call a\n * `private` function that does the actual work.\n */\n modifier nonReentrant() {\n _nonReentrantBefore();\n _;\n _nonReentrantAfter();\n }\n\n function _nonReentrantBefore() private {\n // On the first call to nonReentrant, _status will be _NOT_ENTERED\n require(_status != _ENTERED, \"ReentrancyGuard: reentrant call\");\n\n // Any calls to nonReentrant after this point will fail\n _status = _ENTERED;\n }\n\n function _nonReentrantAfter() private {\n // By storing the original value once again, a refund is triggered (see\n // https://eips.ethereum.org/EIPS/eip-2200)\n _status = _NOT_ENTERED;\n }\n}\n" - }, - "contracts/core/EntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IPaymaster.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\n\nimport \"../utils/Exec.sol\";\nimport \"./StakeManager.sol\";\nimport \"./SenderCreator.sol\";\nimport \"./Helpers.sol\";\nimport \"./NonceManager.sol\";\nimport \"@openzeppelin/contracts/security/ReentrancyGuard.sol\";\n\ncontract EntryPoint is IEntryPoint, StakeManager, NonceManager, ReentrancyGuard {\n\n using UserOperationLib for UserOperation;\n\n SenderCreator private immutable senderCreator = new SenderCreator();\n\n // internal value used during simulation: need to query aggregator.\n address private constant SIMULATE_FIND_AGGREGATOR = address(1);\n\n // marker for inner call revert on out of gas\n bytes32 private constant INNER_OUT_OF_GAS = hex'deaddead';\n\n uint256 private constant REVERT_REASON_MAX_LEN = 2048;\n\n /**\n * for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value\n * in case of signature failure, instead of revert.\n */\n uint256 public constant SIG_VALIDATION_FAILED = 1;\n\n /**\n * compensate the caller's beneficiary address with the collected fees of all UserOperations.\n * @param beneficiary the address to receive the fees\n * @param amount amount to transfer.\n */\n function _compensate(address payable beneficiary, uint256 amount) internal {\n require(beneficiary != address(0), \"AA90 invalid beneficiary\");\n (bool success,) = beneficiary.call{value : amount}(\"\");\n require(success, \"AA91 failed send to beneficiary\");\n }\n\n /**\n * execute a user op\n * @param opIndex index into the opInfo array\n * @param userOp the userOp to execute\n * @param opInfo the opInfo filled by validatePrepayment for this userOp.\n * @return collected the total amount this userOp paid.\n */\n function _executeUserOp(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory opInfo) private returns (uint256 collected) {\n uint256 preGas = gasleft();\n bytes memory context = getMemoryBytesFromOffset(opInfo.contextOffset);\n\n try this.innerHandleOp(userOp.callData, opInfo, context) returns (uint256 _actualGasCost) {\n collected = _actualGasCost;\n } catch {\n bytes32 innerRevertCode;\n assembly {\n returndatacopy(0, 0, 32)\n innerRevertCode := mload(0)\n }\n // handleOps was called with gas limit too low. abort entire bundle.\n if (innerRevertCode == INNER_OUT_OF_GAS) {\n //report paymaster, since if it is not deliberately caused by the bundler,\n // it must be a revert caused by paymaster.\n revert FailedOp(opIndex, \"AA95 out of gas\");\n }\n\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n collected = _handlePostOp(opIndex, IPaymaster.PostOpMode.postOpReverted, opInfo, context, actualGas);\n }\n }\n\n /**\n * Execute a batch of UserOperations.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) public nonReentrant {\n\n uint256 opslen = ops.length;\n UserOpInfo[] memory opInfos = new UserOpInfo[](opslen);\n\n unchecked {\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[i];\n (uint256 validationData, uint256 pmValidationData) = _validatePrepayment(i, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, pmValidationData, address(0));\n }\n\n uint256 collected = 0;\n emit BeforeExecution();\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(i, ops[i], opInfos[i]);\n }\n\n _compensate(beneficiary, collected);\n } //unchecked\n }\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) public nonReentrant {\n\n uint256 opasLen = opsPerAggregator.length;\n uint256 totalOps = 0;\n for (uint256 i = 0; i < opasLen; i++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[i];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n //address(1) is special marker of \"signature error\"\n require(address(aggregator) != address(1), \"AA96 invalid aggregator\");\n\n if (address(aggregator) != address(0)) {\n // solhint-disable-next-line no-empty-blocks\n try aggregator.validateSignatures(ops, opa.signature) {}\n catch {\n revert SignatureValidationFailed(address(aggregator));\n }\n }\n\n totalOps += ops.length;\n }\n\n UserOpInfo[] memory opInfos = new UserOpInfo[](totalOps);\n\n emit BeforeExecution();\n\n uint256 opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n uint256 opslen = ops.length;\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[opIndex];\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(opIndex, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, paymasterValidationData, address(aggregator));\n opIndex++;\n }\n }\n\n uint256 collected = 0;\n opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n emit SignatureAggregatorChanged(address(opa.aggregator));\n UserOperation[] calldata ops = opa.userOps;\n uint256 opslen = ops.length;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(opIndex, ops[i], opInfos[opIndex]);\n opIndex++;\n }\n }\n emit SignatureAggregatorChanged(address(0));\n\n _compensate(beneficiary, collected);\n }\n\n /// @inheritdoc IEntryPoint\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external override {\n\n UserOpInfo memory opInfo;\n _simulationOnlyValidations(op);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, op, opInfo);\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n\n numberMarker();\n uint256 paid = _executeUserOp(0, op, opInfo);\n numberMarker();\n bool targetSuccess;\n bytes memory targetResult;\n if (target != address(0)) {\n (targetSuccess, targetResult) = target.call(targetCallData);\n }\n revert ExecutionResult(opInfo.preOpGas, paid, data.validAfter, data.validUntil, targetSuccess, targetResult);\n }\n\n\n // A memory copy of UserOp static fields only.\n // Excluding: callData, initCode and signature. Replacing paymasterAndData with paymaster.\n struct MemoryUserOp {\n address sender;\n uint256 nonce;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n address paymaster;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n }\n\n struct UserOpInfo {\n MemoryUserOp mUserOp;\n bytes32 userOpHash;\n uint256 prefund;\n uint256 contextOffset;\n uint256 preOpGas;\n }\n\n /**\n * inner function to handle a UserOperation.\n * Must be declared \"external\" to open a call context, but it can only be called by handleOps.\n */\n function innerHandleOp(bytes memory callData, UserOpInfo memory opInfo, bytes calldata context) external returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n require(msg.sender == address(this), \"AA92 internal call only\");\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n\n uint callGasLimit = mUserOp.callGasLimit;\n unchecked {\n // handleOps was called with gas limit too low. abort entire bundle.\n if (gasleft() < callGasLimit + mUserOp.verificationGasLimit + 5000) {\n assembly {\n mstore(0, INNER_OUT_OF_GAS)\n revert(0, 32)\n }\n }\n }\n\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\n if (callData.length > 0) {\n bool success = Exec.call(mUserOp.sender, 0, callData, callGasLimit);\n if (!success) {\n bytes memory result = Exec.getReturnData(REVERT_REASON_MAX_LEN);\n if (result.length > 0) {\n emit UserOperationRevertReason(opInfo.userOpHash, mUserOp.sender, mUserOp.nonce, result);\n }\n mode = IPaymaster.PostOpMode.opReverted;\n }\n }\n\n unchecked {\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n //note: opIndex is ignored (relevant only if mode==postOpReverted, which is only possible outside of innerHandleOp)\n return _handlePostOp(0, mode, opInfo, context, actualGas);\n }\n }\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) public view returns (bytes32) {\n return keccak256(abi.encode(userOp.hash(), address(this), block.chainid));\n }\n\n /**\n * copy general fields from userOp into the memory opInfo structure.\n */\n function _copyUserOpToMemory(UserOperation calldata userOp, MemoryUserOp memory mUserOp) internal pure {\n mUserOp.sender = userOp.sender;\n mUserOp.nonce = userOp.nonce;\n mUserOp.callGasLimit = userOp.callGasLimit;\n mUserOp.verificationGasLimit = userOp.verificationGasLimit;\n mUserOp.preVerificationGas = userOp.preVerificationGas;\n mUserOp.maxFeePerGas = userOp.maxFeePerGas;\n mUserOp.maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes calldata paymasterAndData = userOp.paymasterAndData;\n if (paymasterAndData.length > 0) {\n require(paymasterAndData.length >= 20, \"AA93 invalid paymasterAndData\");\n mUserOp.paymaster = address(bytes20(paymasterAndData[: 20]));\n } else {\n mUserOp.paymaster = address(0);\n }\n }\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external {\n UserOpInfo memory outOpInfo;\n\n _simulationOnlyValidations(userOp);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, userOp, outOpInfo);\n StakeInfo memory paymasterInfo = _getStakeInfo(outOpInfo.mUserOp.paymaster);\n StakeInfo memory senderInfo = _getStakeInfo(outOpInfo.mUserOp.sender);\n StakeInfo memory factoryInfo;\n {\n bytes calldata initCode = userOp.initCode;\n address factory = initCode.length >= 20 ? address(bytes20(initCode[0 : 20])) : address(0);\n factoryInfo = _getStakeInfo(factory);\n }\n\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n address aggregator = data.aggregator;\n bool sigFailed = aggregator == address(1);\n ReturnInfo memory returnInfo = ReturnInfo(outOpInfo.preOpGas, outOpInfo.prefund,\n sigFailed, data.validAfter, data.validUntil, getMemoryBytesFromOffset(outOpInfo.contextOffset));\n\n if (aggregator != address(0) && aggregator != address(1)) {\n AggregatorStakeInfo memory aggregatorInfo = AggregatorStakeInfo(aggregator, _getStakeInfo(aggregator));\n revert ValidationResultWithAggregation(returnInfo, senderInfo, factoryInfo, paymasterInfo, aggregatorInfo);\n }\n revert ValidationResult(returnInfo, senderInfo, factoryInfo, paymasterInfo);\n\n }\n\n function _getRequiredPrefund(MemoryUserOp memory mUserOp) internal pure returns (uint256 requiredPrefund) {\n unchecked {\n //when using a Paymaster, the verificationGasLimit is used also to as a limit for the postOp call.\n // our security model might call postOp eventually twice\n uint256 mul = mUserOp.paymaster != address(0) ? 3 : 1;\n uint256 requiredGas = mUserOp.callGasLimit + mUserOp.verificationGasLimit * mul + mUserOp.preVerificationGas;\n\n requiredPrefund = requiredGas * mUserOp.maxFeePerGas;\n }\n }\n\n // create the sender's contract if needed.\n function _createSenderIfNeeded(uint256 opIndex, UserOpInfo memory opInfo, bytes calldata initCode) internal {\n if (initCode.length != 0) {\n address sender = opInfo.mUserOp.sender;\n if (sender.code.length != 0) revert FailedOp(opIndex, \"AA10 sender already constructed\");\n address sender1 = senderCreator.createSender{gas : opInfo.mUserOp.verificationGasLimit}(initCode);\n if (sender1 == address(0)) revert FailedOp(opIndex, \"AA13 initCode failed or OOG\");\n if (sender1 != sender) revert FailedOp(opIndex, \"AA14 initCode must return sender\");\n if (sender1.code.length == 0) revert FailedOp(opIndex, \"AA15 initCode must create sender\");\n address factory = address(bytes20(initCode[0 : 20]));\n emit AccountDeployed(opInfo.userOpHash, sender, factory, opInfo.mUserOp.paymaster);\n }\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes calldata initCode) public {\n address sender = senderCreator.createSender(initCode);\n revert SenderAddressResult(sender);\n }\n\n function _simulationOnlyValidations(UserOperation calldata userOp) internal view {\n // solhint-disable-next-line no-empty-blocks\n try this._validateSenderAndPaymaster(userOp.initCode, userOp.sender, userOp.paymasterAndData) {}\n catch Error(string memory revertReason) {\n if (bytes(revertReason).length != 0) {\n revert FailedOp(0, revertReason);\n }\n }\n }\n\n /**\n * Called only during simulation.\n * This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\n */\n function _validateSenderAndPaymaster(bytes calldata initCode, address sender, bytes calldata paymasterAndData) external view {\n if (initCode.length == 0 && sender.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA20 account not deployed\");\n }\n if (paymasterAndData.length >= 20) {\n address paymaster = address(bytes20(paymasterAndData[0 : 20]));\n if (paymaster.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA30 paymaster not deployed\");\n }\n }\n // always revert\n revert(\"\");\n }\n\n /**\n * call account.validateUserOp.\n * revert (with FailedOp) in case validateUserOp reverts, or account didn't send required prefund.\n * decrement account's deposit if needed\n */\n function _validateAccountPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPrefund)\n internal returns (uint256 gasUsedByValidateAccountPrepayment, uint256 validationData) {\n unchecked {\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n address sender = mUserOp.sender;\n _createSenderIfNeeded(opIndex, opInfo, op.initCode);\n address paymaster = mUserOp.paymaster;\n numberMarker();\n uint256 missingAccountFunds = 0;\n if (paymaster == address(0)) {\n uint256 bal = balanceOf(sender);\n missingAccountFunds = bal > requiredPrefund ? 0 : requiredPrefund - bal;\n }\n try IAccount(sender).validateUserOp{gas : mUserOp.verificationGasLimit}(op, opInfo.userOpHash, missingAccountFunds)\n returns (uint256 _validationData) {\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA23 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA23 reverted (or OOG)\");\n }\n if (paymaster == address(0)) {\n DepositInfo storage senderInfo = deposits[sender];\n uint256 deposit = senderInfo.deposit;\n if (requiredPrefund > deposit) {\n revert FailedOp(opIndex, \"AA21 didn't pay prefund\");\n }\n senderInfo.deposit = uint112(deposit - requiredPrefund);\n }\n gasUsedByValidateAccountPrepayment = preGas - gasleft();\n }\n }\n\n /**\n * In case the request has a paymaster:\n * Validate paymaster has enough deposit.\n * Call paymaster.validatePaymasterUserOp.\n * Revert with proper FailedOp in case paymaster reverts.\n * Decrement paymaster's deposit\n */\n function _validatePaymasterPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPreFund, uint256 gasUsedByValidateAccountPrepayment)\n internal returns (bytes memory context, uint256 validationData) {\n unchecked {\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 verificationGasLimit = mUserOp.verificationGasLimit;\n require(verificationGasLimit > gasUsedByValidateAccountPrepayment, \"AA41 too little verificationGas\");\n uint256 gas = verificationGasLimit - gasUsedByValidateAccountPrepayment;\n\n address paymaster = mUserOp.paymaster;\n DepositInfo storage paymasterInfo = deposits[paymaster];\n uint256 deposit = paymasterInfo.deposit;\n if (deposit < requiredPreFund) {\n revert FailedOp(opIndex, \"AA31 paymaster deposit too low\");\n }\n paymasterInfo.deposit = uint112(deposit - requiredPreFund);\n try IPaymaster(paymaster).validatePaymasterUserOp{gas : gas}(op, opInfo.userOpHash, requiredPreFund) returns (bytes memory _context, uint256 _validationData){\n context = _context;\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA33 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA33 reverted (or OOG)\");\n }\n }\n }\n\n /**\n * revert if either account validationData or paymaster validationData is expired\n */\n function _validateAccountAndPaymasterValidationData(uint256 opIndex, uint256 validationData, uint256 paymasterValidationData, address expectedAggregator) internal view {\n (address aggregator, bool outOfTimeRange) = _getValidationData(validationData);\n if (expectedAggregator != aggregator) {\n revert FailedOp(opIndex, \"AA24 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA22 expired or not due\");\n }\n //pmAggregator is not a real signature aggregator: we don't have logic to handle it as address.\n // non-zero address means that the paymaster fails due to some signature check (which is ok only during estimation)\n address pmAggregator;\n (pmAggregator, outOfTimeRange) = _getValidationData(paymasterValidationData);\n if (pmAggregator != address(0)) {\n revert FailedOp(opIndex, \"AA34 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA32 paymaster expired or not due\");\n }\n }\n\n function _getValidationData(uint256 validationData) internal view returns (address aggregator, bool outOfTimeRange) {\n if (validationData == 0) {\n return (address(0), false);\n }\n ValidationData memory data = _parseValidationData(validationData);\n // solhint-disable-next-line not-rely-on-time\n outOfTimeRange = block.timestamp > data.validUntil || block.timestamp < data.validAfter;\n aggregator = data.aggregator;\n }\n\n /**\n * validate account and paymaster (if defined).\n * also make sure total validation doesn't exceed verificationGasLimit\n * this method is called off-chain (simulateValidation()) and on-chain (from handleOps)\n * @param opIndex the index of this userOp into the \"opInfos\" array\n * @param userOp the userOp to validate\n */\n function _validatePrepayment(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory outOpInfo)\n private returns (uint256 validationData, uint256 paymasterValidationData) {\n\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = outOpInfo.mUserOp;\n _copyUserOpToMemory(userOp, mUserOp);\n outOpInfo.userOpHash = getUserOpHash(userOp);\n\n // validate all numeric values in userOp are well below 128 bit, so they can safely be added\n // and multiplied without causing overflow\n uint256 maxGasValues = mUserOp.preVerificationGas | mUserOp.verificationGasLimit | mUserOp.callGasLimit |\n userOp.maxFeePerGas | userOp.maxPriorityFeePerGas;\n require(maxGasValues <= type(uint120).max, \"AA94 gas values overflow\");\n\n uint256 gasUsedByValidateAccountPrepayment;\n (uint256 requiredPreFund) = _getRequiredPrefund(mUserOp);\n (gasUsedByValidateAccountPrepayment, validationData) = _validateAccountPrepayment(opIndex, userOp, outOpInfo, requiredPreFund);\n\n if (!_validateAndUpdateNonce(mUserOp.sender, mUserOp.nonce)) {\n revert FailedOp(opIndex, \"AA25 invalid account nonce\");\n }\n\n //a \"marker\" where account opcode validation is done and paymaster opcode validation is about to start\n // (used only by off-chain simulateValidation)\n numberMarker();\n\n bytes memory context;\n if (mUserOp.paymaster != address(0)) {\n (context, paymasterValidationData) = _validatePaymasterPrepayment(opIndex, userOp, outOpInfo, requiredPreFund, gasUsedByValidateAccountPrepayment);\n }\n unchecked {\n uint256 gasUsed = preGas - gasleft();\n\n if (userOp.verificationGasLimit < gasUsed) {\n revert FailedOp(opIndex, \"AA40 over verificationGasLimit\");\n }\n outOpInfo.prefund = requiredPreFund;\n outOpInfo.contextOffset = getOffsetOfMemoryBytes(context);\n outOpInfo.preOpGas = preGas - gasleft() + userOp.preVerificationGas;\n }\n }\n\n /**\n * process post-operation.\n * called just after the callData is executed.\n * if a paymaster is defined and its validation returned a non-empty context, its postOp is called.\n * the excess amount is refunded to the account (or paymaster - if it was used in the request)\n * @param opIndex index in the batch\n * @param mode - whether is called from innerHandleOp, or outside (postOpReverted)\n * @param opInfo userOp fields and info collected during validation\n * @param context the context returned in validatePaymasterUserOp\n * @param actualGas the gas used so far by this user operation\n */\n function _handlePostOp(uint256 opIndex, IPaymaster.PostOpMode mode, UserOpInfo memory opInfo, bytes memory context, uint256 actualGas) private returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n unchecked {\n address refundAddress;\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 gasPrice = getUserOpGasPrice(mUserOp);\n\n address paymaster = mUserOp.paymaster;\n if (paymaster == address(0)) {\n refundAddress = mUserOp.sender;\n } else {\n refundAddress = paymaster;\n if (context.length > 0) {\n actualGasCost = actualGas * gasPrice;\n if (mode != IPaymaster.PostOpMode.postOpReverted) {\n IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost);\n } else {\n // solhint-disable-next-line no-empty-blocks\n try IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost) {}\n catch Error(string memory reason) {\n revert FailedOp(opIndex, string.concat(\"AA50 postOp reverted: \", reason));\n }\n catch {\n revert FailedOp(opIndex, \"AA50 postOp revert\");\n }\n }\n }\n }\n actualGas += preGas - gasleft();\n actualGasCost = actualGas * gasPrice;\n if (opInfo.prefund < actualGasCost) {\n revert FailedOp(opIndex, \"AA51 prefund below actualGasCost\");\n }\n uint256 refund = opInfo.prefund - actualGasCost;\n _incrementDeposit(refundAddress, refund);\n bool success = mode == IPaymaster.PostOpMode.opSucceeded;\n emit UserOperationEvent(opInfo.userOpHash, mUserOp.sender, mUserOp.paymaster, mUserOp.nonce, success, actualGasCost, actualGas);\n } // unchecked\n }\n\n /**\n * the gas price this UserOp agrees to pay.\n * relayer/block builder might submit the TX with higher priorityFee, but the user should not\n */\n function getUserOpGasPrice(MemoryUserOp memory mUserOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = mUserOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = mUserOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n\n function getOffsetOfMemoryBytes(bytes memory data) internal pure returns (uint256 offset) {\n assembly {offset := data}\n }\n\n function getMemoryBytesFromOffset(uint256 offset) internal pure returns (bytes memory data) {\n assembly {data := offset}\n }\n\n //place the NUMBER opcode in the code.\n // this is used as a marker during simulation, as this OP is completely banned from the simulated code of the\n // account and paymaster.\n function numberMarker() internal view {\n assembly {mstore(0, number())}\n }\n}\n\n" - }, - "contracts/core/Helpers.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\n/**\n * returned data from validateUserOp.\n * validateUserOp returns a uint256, with is created by `_packedValidationData` and parsed by `_parseValidationData`\n * @param aggregator - address(0) - the account validated the signature by itself.\n * address(1) - the account failed to validate the signature.\n * otherwise - this is an address of a signature aggregator that must be used to validate the signature.\n * @param validAfter - this UserOp is valid only after this timestamp.\n * @param validaUntil - this UserOp is valid only up to this timestamp.\n */\n struct ValidationData {\n address aggregator;\n uint48 validAfter;\n uint48 validUntil;\n }\n\n//extract sigFailed, validAfter, validUntil.\n// also convert zero validUntil to type(uint48).max\n function _parseValidationData(uint validationData) pure returns (ValidationData memory data) {\n address aggregator = address(uint160(validationData));\n uint48 validUntil = uint48(validationData >> 160);\n if (validUntil == 0) {\n validUntil = type(uint48).max;\n }\n uint48 validAfter = uint48(validationData >> (48 + 160));\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n// intersect account and paymaster ranges.\n function _intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) pure returns (ValidationData memory) {\n ValidationData memory accountValidationData = _parseValidationData(validationData);\n ValidationData memory pmValidationData = _parseValidationData(paymasterValidationData);\n address aggregator = accountValidationData.aggregator;\n if (aggregator == address(0)) {\n aggregator = pmValidationData.aggregator;\n }\n uint48 validAfter = accountValidationData.validAfter;\n uint48 validUntil = accountValidationData.validUntil;\n uint48 pmValidAfter = pmValidationData.validAfter;\n uint48 pmValidUntil = pmValidationData.validUntil;\n\n if (validAfter < pmValidAfter) validAfter = pmValidAfter;\n if (validUntil > pmValidUntil) validUntil = pmValidUntil;\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n/**\n * helper to pack the return value for validateUserOp\n * @param data - the ValidationData to pack\n */\n function _packValidationData(ValidationData memory data) pure returns (uint256) {\n return uint160(data.aggregator) | (uint256(data.validUntil) << 160) | (uint256(data.validAfter) << (160 + 48));\n }\n\n/**\n * helper to pack the return value for validateUserOp, when not using an aggregator\n * @param sigFailed - true for signature failure, false for success\n * @param validUntil last timestamp this UserOperation is valid (or zero for infinite)\n * @param validAfter first timestamp this UserOperation is valid\n */\n function _packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) pure returns (uint256) {\n return (sigFailed ? 1 : 0) | (uint256(validUntil) << 160) | (uint256(validAfter) << (160 + 48));\n }\n\n/**\n * keccak function over calldata.\n * @dev copy calldata into memory, do keccak and drop allocated memory. Strangely, this is more efficient than letting solidity do it.\n */\n function calldataKeccak(bytes calldata data) pure returns (bytes32 ret) {\n assembly {\n let mem := mload(0x40)\n let len := data.length\n calldatacopy(mem, data.offset, len)\n ret := keccak256(mem, len)\n }\n }\n\n" - }, - "contracts/core/NonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IEntryPoint.sol\";\n\n/**\n * nonce management functionality\n */\ncontract NonceManager is INonceManager {\n\n /**\n * The next valid sequence number for a given nonce key.\n */\n mapping(address => mapping(uint192 => uint256)) public nonceSequenceNumber;\n\n function getNonce(address sender, uint192 key)\n public view override returns (uint256 nonce) {\n return nonceSequenceNumber[sender][key] | (uint256(key) << 64);\n }\n\n // allow an account to manually increment its own nonce.\n // (mainly so that during construction nonce can be made non-zero,\n // to \"absorb\" the gas cost of first nonce increment to 1st transaction (construction),\n // not to 2nd transaction)\n function incrementNonce(uint192 key) public override {\n nonceSequenceNumber[msg.sender][key]++;\n }\n\n /**\n * validate nonce uniqueness for this account.\n * called just after validateUserOp()\n */\n function _validateAndUpdateNonce(address sender, uint256 nonce) internal returns (bool) {\n\n uint192 key = uint192(nonce >> 64);\n uint64 seq = uint64(nonce);\n return nonceSequenceNumber[sender][key]++ == seq;\n }\n\n}\n" - }, - "contracts/core/SenderCreator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * helper contract for EntryPoint, to call userOp.initCode from a \"neutral\" address,\n * which is explicitly not the entryPoint itself.\n */\ncontract SenderCreator {\n\n /**\n * call the \"initCode\" factory to create and return the sender account address\n * @param initCode the initCode value from a UserOp. contains 20 bytes of factory address, followed by calldata\n * @return sender the returned address of the created account, or zero address on failure.\n */\n function createSender(bytes calldata initCode) external returns (address sender) {\n address factory = address(bytes20(initCode[0 : 20]));\n bytes memory initCallData = initCode[20 :];\n bool success;\n /* solhint-disable no-inline-assembly */\n assembly {\n success := call(gas(), factory, 0, add(initCallData, 0x20), mload(initCallData), 0, 32)\n sender := mload(0)\n }\n if (!success) {\n sender = address(0);\n }\n }\n}\n" - }, - "contracts/core/StakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IStakeManager.sol\";\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable not-rely-on-time */\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by a paymaster.\n */\nabstract contract StakeManager is IStakeManager {\n\n /// maps paymaster to their deposits and stakes\n mapping(address => DepositInfo) public deposits;\n\n /// @inheritdoc IStakeManager\n function getDepositInfo(address account) public view returns (DepositInfo memory info) {\n return deposits[account];\n }\n\n // internal method to return just the stake info\n function _getStakeInfo(address addr) internal view returns (StakeInfo memory info) {\n DepositInfo storage depositInfo = deposits[addr];\n info.stake = depositInfo.stake;\n info.unstakeDelaySec = depositInfo.unstakeDelaySec;\n }\n\n /// return the deposit (for gas payment) of the account\n function balanceOf(address account) public view returns (uint256) {\n return deposits[account].deposit;\n }\n\n receive() external payable {\n depositTo(msg.sender);\n }\n\n function _incrementDeposit(address account, uint256 amount) internal {\n DepositInfo storage info = deposits[account];\n uint256 newAmount = info.deposit + amount;\n require(newAmount <= type(uint112).max, \"deposit overflow\");\n info.deposit = uint112(newAmount);\n }\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) public payable {\n _incrementDeposit(account, msg.value);\n DepositInfo storage info = deposits[account];\n emit Deposited(account, info.deposit);\n }\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 unstakeDelaySec) public payable {\n DepositInfo storage info = deposits[msg.sender];\n require(unstakeDelaySec > 0, \"must specify unstake delay\");\n require(unstakeDelaySec >= info.unstakeDelaySec, \"cannot decrease unstake time\");\n uint256 stake = info.stake + msg.value;\n require(stake > 0, \"no stake specified\");\n require(stake <= type(uint112).max, \"stake overflow\");\n deposits[msg.sender] = DepositInfo(\n info.deposit,\n true,\n uint112(stake),\n unstakeDelaySec,\n 0\n );\n emit StakeLocked(msg.sender, stake, unstakeDelaySec);\n }\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external {\n DepositInfo storage info = deposits[msg.sender];\n require(info.unstakeDelaySec != 0, \"not staked\");\n require(info.staked, \"already unstaking\");\n uint48 withdrawTime = uint48(block.timestamp) + info.unstakeDelaySec;\n info.withdrawTime = withdrawTime;\n info.staked = false;\n emit StakeUnlocked(msg.sender, withdrawTime);\n }\n\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external {\n DepositInfo storage info = deposits[msg.sender];\n uint256 stake = info.stake;\n require(stake > 0, \"No stake to withdraw\");\n require(info.withdrawTime > 0, \"must call unlockStake() first\");\n require(info.withdrawTime <= block.timestamp, \"Stake withdrawal is not due\");\n info.unstakeDelaySec = 0;\n info.withdrawTime = 0;\n info.stake = 0;\n emit StakeWithdrawn(msg.sender, withdrawAddress, stake);\n (bool success,) = withdrawAddress.call{value : stake}(\"\");\n require(success, \"failed to withdraw stake\");\n }\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external {\n DepositInfo storage info = deposits[msg.sender];\n require(withdrawAmount <= info.deposit, \"Withdraw amount too large\");\n info.deposit = uint112(info.deposit - withdrawAmount);\n emit Withdrawn(msg.sender, withdrawAddress, withdrawAmount);\n (bool success,) = withdrawAddress.call{value : withdrawAmount}(\"\");\n require(success, \"failed to withdraw\");\n }\n}\n" - }, - "contracts/interfaces/IAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\ninterface IAccount {\n\n /**\n * Validate user's signature and nonce\n * the entryPoint will make the call to the recipient only if this validation call returns successfully.\n * signature failure should be reported by returning SIG_VALIDATION_FAILED (1).\n * This allows making a \"simulation call\" without a valid signature\n * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure.\n *\n * @dev Must validate caller is the entryPoint.\n * Must validate the signature and nonce\n * @param userOp the operation that is about to be executed.\n * @param userOpHash hash of the user's request data. can be used as the basis for signature.\n * @param missingAccountFunds missing funds on the account's deposit in the entrypoint.\n * This is the minimum amount to transfer to the sender(entryPoint) to be able to make the call.\n * The excess is left as a deposit in the entrypoint, for future calls.\n * can be withdrawn anytime using \"entryPoint.withdrawTo()\"\n * In case there is a paymaster in the request (or the current deposit is high enough), this value will be zero.\n * @return validationData packaged ValidationData structure. use `_packValidationData` and `_unpackValidationData` to encode and decode\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * If an account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external returns (uint256 validationData);\n}\n" - }, - "contracts/interfaces/IAggregator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * Aggregated Signatures validator.\n */\ninterface IAggregator {\n\n /**\n * validate aggregated signature.\n * revert if the aggregated signature does not match the given list of operations.\n */\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external view;\n\n /**\n * validate signature of a single userOp\n * This method is should be called by bundler after EntryPoint.simulateValidation() returns (reverts) with ValidationResultWithAggregation\n * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps.\n * @param userOp the userOperation received from the user.\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\n * (usually empty, unless account and aggregator support some kind of \"multisig\"\n */\n function validateUserOpSignature(UserOperation calldata userOp)\n external view returns (bytes memory sigForUserOp);\n\n /**\n * aggregate multiple signatures into a single value.\n * This method is called off-chain to calculate the signature to pass with handleOps()\n * bundler MAY use optimized custom code perform this aggregation\n * @param userOps array of UserOperations to collect the signatures from.\n * @return aggregatedSignature the aggregated signature\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external view returns (bytes memory aggregatedSignature);\n}\n" - }, - "contracts/interfaces/IEntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"./UserOperation.sol\";\nimport \"./IStakeManager.sol\";\nimport \"./IAggregator.sol\";\nimport \"./INonceManager.sol\";\n\ninterface IEntryPoint is IStakeManager, INonceManager {\n\n /***\n * An event emitted after each successful request\n * @param userOpHash - unique identifier for the request (hash its entire content, except signature).\n * @param sender - the account that generates this request.\n * @param paymaster - if non-null, the paymaster that pays for this request.\n * @param nonce - the nonce value from the request.\n * @param success - true if the sender transaction succeeded, false if reverted.\n * @param actualGasCost - actual amount paid (by account or paymaster) for this UserOperation.\n * @param actualGasUsed - total gas used by this UserOperation (including preVerification, creation, validation and execution).\n */\n event UserOperationEvent(bytes32 indexed userOpHash, address indexed sender, address indexed paymaster, uint256 nonce, bool success, uint256 actualGasCost, uint256 actualGasUsed);\n\n /**\n * account \"sender\" was deployed.\n * @param userOpHash the userOp that deployed this account. UserOperationEvent will follow.\n * @param sender the account that is deployed\n * @param factory the factory used to deploy this account (in the initCode)\n * @param paymaster the paymaster used by this UserOp\n */\n event AccountDeployed(bytes32 indexed userOpHash, address indexed sender, address factory, address paymaster);\n\n /**\n * An event emitted if the UserOperation \"callData\" reverted with non-zero length\n * @param userOpHash the request unique identifier.\n * @param sender the sender of this request\n * @param nonce the nonce used in the request\n * @param revertReason - the return bytes from the (reverted) call to \"callData\".\n */\n event UserOperationRevertReason(bytes32 indexed userOpHash, address indexed sender, uint256 nonce, bytes revertReason);\n\n /**\n * an event emitted by handleOps(), before starting the execution loop.\n * any event emitted before this event, is part of the validation.\n */\n event BeforeExecution();\n\n /**\n * signature aggregator used by the following UserOperationEvents within this bundle.\n */\n event SignatureAggregatorChanged(address indexed aggregator);\n\n /**\n * a custom revert error of handleOps, to identify the offending op.\n * NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\n * @param opIndex - index into the array of ops to the failed one (in simulateValidation, this is always zero)\n * @param reason - revert reason\n * The string starts with a unique code \"AAmn\", where \"m\" is \"1\" for factory, \"2\" for account and \"3\" for paymaster issues,\n * so a failure can be attributed to the correct entity.\n * Should be caught in off-chain handleOps simulation and not happen on-chain.\n * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\n */\n error FailedOp(uint256 opIndex, string reason);\n\n /**\n * error case when a signature aggregator fails to verify the aggregated signature it had created.\n */\n error SignatureValidationFailed(address aggregator);\n\n /**\n * Successful result from simulateValidation.\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n */\n error ValidationResult(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo);\n\n /**\n * Successful result from simulateValidation, if the account returns a signature aggregator\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n * @param aggregatorInfo signature aggregation info (if the account requires signature aggregator)\n * bundler MUST use it to verify the signature, or reject the UserOperation\n */\n error ValidationResultWithAggregation(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo,\n AggregatorStakeInfo aggregatorInfo);\n\n /**\n * return value of getSenderAddress\n */\n error SenderAddressResult(address sender);\n\n /**\n * return value of simulateHandleOp\n */\n error ExecutionResult(uint256 preOpGas, uint256 paid, uint48 validAfter, uint48 validUntil, bool targetSuccess, bytes targetResult);\n\n //UserOps handled, per aggregator\n struct UserOpsPerAggregator {\n UserOperation[] userOps;\n\n // aggregator address\n IAggregator aggregator;\n // aggregated signature\n bytes signature;\n }\n\n /**\n * Execute a batch of UserOperation.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) external;\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) external;\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) external view returns (bytes32);\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external;\n\n /**\n * gas and return values during simulation\n * @param preOpGas the gas used for validation (including preValidationGas)\n * @param prefund the required prefund for this operation\n * @param sigFailed validateUserOp's (or paymaster's) signature check failed\n * @param validAfter - first timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param validUntil - last timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param paymasterContext returned by validatePaymasterUserOp (to be passed into postOp)\n */\n struct ReturnInfo {\n uint256 preOpGas;\n uint256 prefund;\n bool sigFailed;\n uint48 validAfter;\n uint48 validUntil;\n bytes paymasterContext;\n }\n\n /**\n * returned aggregated signature info.\n * the aggregator returned by the account, and its current stake.\n */\n struct AggregatorStakeInfo {\n address aggregator;\n StakeInfo stakeInfo;\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes memory initCode) external;\n\n\n /**\n * simulate full execution of a UserOperation (including both validation and target execution)\n * this method will always revert with \"ExecutionResult\".\n * it performs full validation of the UserOperation, but ignores signature error.\n * an optional target address is called after the userop succeeds, and its value is returned\n * (before the entire call is reverted)\n * Note that in order to collect the the success/failure of the target call, it must be executed\n * with trace enabled to track the emitted events.\n * @param op the UserOperation to simulate\n * @param target if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult\n * are set to the return from that call.\n * @param targetCallData callData to pass to target address\n */\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external;\n}\n\n" - }, - "contracts/interfaces/INonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\ninterface INonceManager {\n\n /**\n * Return the next nonce for this sender.\n * Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop)\n * But UserOp with different keys can come with arbitrary order.\n *\n * @param sender the account address\n * @param key the high 192 bit of the nonce\n * @return nonce a full nonce to pass for next UserOp with this sender.\n */\n function getNonce(address sender, uint192 key)\n external view returns (uint256 nonce);\n\n /**\n * Manually increment the nonce of the sender.\n * This method is exposed just for completeness..\n * Account does NOT need to call it, neither during validation, nor elsewhere,\n * as the EntryPoint will update the nonce regardless.\n * Possible use-case is call it with various keys to \"initialize\" their nonces to one, so that future\n * UserOperations will not pay extra for the first transaction with a given key.\n */\n function incrementNonce(uint192 key) external;\n}\n" - }, - "contracts/interfaces/IPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * the interface exposed by a paymaster contract, who agrees to pay the gas for user's operations.\n * a paymaster must hold a stake to cover the required entrypoint stake and also the gas for the transaction.\n */\ninterface IPaymaster {\n\n enum PostOpMode {\n opSucceeded, // user op succeeded\n opReverted, // user op reverted. still has to pay for gas.\n postOpReverted //user op succeeded, but caused postOp to revert. Now it's a 2nd call, after user's op was deliberately reverted.\n }\n\n /**\n * payment validation: check if paymaster agrees to pay.\n * Must verify sender is the entryPoint.\n * Revert to reject this request.\n * Note that bundlers will reject this method if it changes the state, unless the paymaster is trusted (whitelisted)\n * The paymaster pre-pays using its deposit, and receive back a refund after the postOp method returns.\n * @param userOp the user operation\n * @param userOpHash hash of the user's request data.\n * @param maxCost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\n * @return context value to send to a postOp\n * zero length to signify postOp is not required.\n * @return validationData signature and time-range of this operation, encoded the same as the return value of validateUserOperation\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n external returns (bytes memory context, uint256 validationData);\n\n /**\n * post-operation handler.\n * Must verify sender is the entryPoint\n * @param mode enum with the following options:\n * opSucceeded - user operation succeeded.\n * opReverted - user op reverted. still has to pay for gas.\n * postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n * Now this is the 2nd call, after user's op was deliberately reverted.\n * @param context - the context value returned by validatePaymasterUserOp\n * @param actualGasCost - actual gas used so far (without this postOp call).\n */\n function postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) external;\n}\n" - }, - "contracts/interfaces/IStakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by the staked entity.\n */\ninterface IStakeManager {\n\n event Deposited(\n address indexed account,\n uint256 totalDeposit\n );\n\n event Withdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /// Emitted when stake or unstake delay are modified\n event StakeLocked(\n address indexed account,\n uint256 totalStaked,\n uint256 unstakeDelaySec\n );\n\n /// Emitted once a stake is scheduled for withdrawal\n event StakeUnlocked(\n address indexed account,\n uint256 withdrawTime\n );\n\n event StakeWithdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /**\n * @param deposit the entity's deposit\n * @param staked true if this entity is staked.\n * @param stake actual amount of ether staked for this entity.\n * @param unstakeDelaySec minimum delay to withdraw the stake.\n * @param withdrawTime - first block timestamp where 'withdrawStake' will be callable, or zero if already locked\n * @dev sizes were chosen so that (deposit,staked, stake) fit into one cell (used during handleOps)\n * and the rest fit into a 2nd cell.\n * 112 bit allows for 10^15 eth\n * 48 bit for full timestamp\n * 32 bit allows 150 years for unstake delay\n */\n struct DepositInfo {\n uint112 deposit;\n bool staked;\n uint112 stake;\n uint32 unstakeDelaySec;\n uint48 withdrawTime;\n }\n\n //API struct used by getStakeInfo and simulateValidation\n struct StakeInfo {\n uint256 stake;\n uint256 unstakeDelaySec;\n }\n\n /// @return info - full deposit information of given account\n function getDepositInfo(address account) external view returns (DepositInfo memory info);\n\n /// @return the deposit (for gas payment) of the account\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) external payable;\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param _unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 _unstakeDelaySec) external payable;\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external;\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external;\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external;\n}\n" - }, - "contracts/interfaces/UserOperation.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\nimport {calldataKeccak} from \"../core/Helpers.sol\";\n\n/**\n * User Operation struct\n * @param sender the sender account of this request.\n * @param nonce unique value the sender uses to verify it is not a replay.\n * @param initCode if set, the account contract will be created by this constructor/\n * @param callData the method call to execute on this account.\n * @param callGasLimit the gas limit passed to the callData method call.\n * @param verificationGasLimit gas used for validateUserOp and validatePaymasterUserOp.\n * @param preVerificationGas gas not calculated by the handleOps method, but added to the gas paid. Covers batch overhead.\n * @param maxFeePerGas same as EIP-1559 gas parameter.\n * @param maxPriorityFeePerGas same as EIP-1559 gas parameter.\n * @param paymasterAndData if set, this field holds the paymaster address and paymaster-specific data. the paymaster will pay for the transaction instead of the sender.\n * @param signature sender-verified signature over the entire request, the EntryPoint address and the chain ID.\n */\n struct UserOperation {\n\n address sender;\n uint256 nonce;\n bytes initCode;\n bytes callData;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n bytes paymasterAndData;\n bytes signature;\n }\n\n/**\n * Utility functions helpful when working with UserOperation structs.\n */\nlibrary UserOperationLib {\n\n function getSender(UserOperation calldata userOp) internal pure returns (address) {\n address data;\n //read sender from userOp, which is first userOp member (saves 800 gas...)\n assembly {data := calldataload(userOp)}\n return address(uint160(data));\n }\n\n //relayer/block builder might submit the TX with higher priorityFee, but the user should not\n // pay above what he signed for.\n function gasPrice(UserOperation calldata userOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n address sender = getSender(userOp);\n uint256 nonce = userOp.nonce;\n bytes32 hashInitCode = calldataKeccak(userOp.initCode);\n bytes32 hashCallData = calldataKeccak(userOp.callData);\n uint256 callGasLimit = userOp.callGasLimit;\n uint256 verificationGasLimit = userOp.verificationGasLimit;\n uint256 preVerificationGas = userOp.preVerificationGas;\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes32 hashPaymasterAndData = calldataKeccak(userOp.paymasterAndData);\n\n return abi.encode(\n sender, nonce,\n hashInitCode, hashCallData,\n callGasLimit, verificationGasLimit, preVerificationGas,\n maxFeePerGas, maxPriorityFeePerGas,\n hashPaymasterAndData\n );\n }\n\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\n return keccak256(pack(userOp));\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n}\n" - }, - "contracts/utils/Exec.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.5 <0.9.0;\n\n// solhint-disable no-inline-assembly\n\n/**\n * Utility functions helpful when making different kinds of contract calls in Solidity.\n */\nlibrary Exec {\n\n function call(\n address to,\n uint256 value,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function staticcall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal view returns (bool success) {\n assembly {\n success := staticcall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function delegateCall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n // get returned data from last call or calldelegate\n function getReturnData(uint256 maxLen) internal pure returns (bytes memory returnData) {\n assembly {\n let len := returndatasize()\n if gt(len, maxLen) {\n len := maxLen\n }\n let ptr := mload(0x40)\n mstore(0x40, add(ptr, add(len, 0x20)))\n mstore(ptr, len)\n returndatacopy(add(ptr, 0x20), 0, len)\n returnData := ptr\n }\n }\n\n // revert with explicit byte array (probably reverted info from call)\n function revertWithData(bytes memory returnData) internal pure {\n assembly {\n revert(add(returnData, 32), mload(returnData))\n }\n }\n\n function callAndRevert(address to, bytes memory data, uint256 maxLen) internal {\n bool success = call(to,0,data,gasleft());\n if (!success) {\n revertWithData(getReturnData(maxLen));\n }\n }\n}\n" - } - }, - "settings": { - "optimizer": { - "enabled": true, - "runs": 1000000 - }, - "viaIR": true, - "outputSelection": { - "*": { - "*": [ - "abi", - "evm.bytecode", - "evm.deployedBytecode", - "evm.methodIdentifiers", - "metadata" - ], - "": [ - "ast" - ] - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/matic/solcInputs/cfbebdf1101dd2bc0f310cb0b7d62cb7.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/matic/solcInputs/cfbebdf1101dd2bc0f310cb0b7d62cb7.json deleted file mode 100644 index dd27f82ce6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/matic/solcInputs/cfbebdf1101dd2bc0f310cb0b7d62cb7.json +++ /dev/null @@ -1,59 +0,0 @@ -{ - "language": "Solidity", - "sources": { - "contracts/core/EntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IPaymaster.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\n\nimport \"../utils/Exec.sol\";\nimport \"./StakeManager.sol\";\nimport \"./SenderCreator.sol\";\nimport \"./Helpers.sol\";\n\ncontract EntryPoint is IEntryPoint, StakeManager {\n\n using UserOperationLib for UserOperation;\n\n SenderCreator private immutable senderCreator = new SenderCreator();\n\n // internal value used during simulation: need to query aggregator.\n address private constant SIMULATE_FIND_AGGREGATOR = address(1);\n\n // marker for inner call revert on out of gas\n bytes32 private constant INNER_OUT_OF_GAS = hex'deaddead';\n\n uint256 private constant REVERT_REASON_MAX_LEN = 2048;\n\n /**\n * for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value\n * in case of signature failure, instead of revert.\n */\n uint256 public constant SIG_VALIDATION_FAILED = 1;\n\n /**\n * compensate the caller's beneficiary address with the collected fees of all UserOperations.\n * @param beneficiary the address to receive the fees\n * @param amount amount to transfer.\n */\n function _compensate(address payable beneficiary, uint256 amount) internal {\n require(beneficiary != address(0), \"AA90 invalid beneficiary\");\n (bool success,) = beneficiary.call{value : amount}(\"\");\n require(success, \"AA91 failed send to beneficiary\");\n }\n\n /**\n * execute a user op\n * @param opIndex index into the opInfo array\n * @param userOp the userOp to execute\n * @param opInfo the opInfo filled by validatePrepayment for this userOp.\n * @return collected the total amount this userOp paid.\n */\n function _executeUserOp(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory opInfo) private returns (uint256 collected) {\n uint256 preGas = gasleft();\n bytes memory context = getMemoryBytesFromOffset(opInfo.contextOffset);\n\n try this.innerHandleOp(userOp.callData, opInfo, context) returns (uint256 _actualGasCost) {\n collected = _actualGasCost;\n } catch {\n bytes32 innerRevertCode;\n assembly {\n returndatacopy(0, 0, 32)\n innerRevertCode := mload(0)\n }\n // handleOps was called with gas limit too low. abort entire bundle.\n if (innerRevertCode == INNER_OUT_OF_GAS) {\n //report paymaster, since if it is not deliberately caused by the bundler,\n // it must be a revert caused by paymaster.\n revert FailedOp(opIndex, \"AA95 out of gas\");\n }\n\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n collected = _handlePostOp(opIndex, IPaymaster.PostOpMode.postOpReverted, opInfo, context, actualGas);\n }\n }\n\n /**\n * Execute a batch of UserOperations.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) public {\n\n uint256 opslen = ops.length;\n UserOpInfo[] memory opInfos = new UserOpInfo[](opslen);\n\n unchecked {\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[i];\n (uint256 validationData, uint256 pmValidationData) = _validatePrepayment(i, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, pmValidationData, address(0));\n }\n\n uint256 collected = 0;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(i, ops[i], opInfos[i]);\n }\n\n _compensate(beneficiary, collected);\n } //unchecked\n }\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) public {\n\n uint256 opasLen = opsPerAggregator.length;\n uint256 totalOps = 0;\n for (uint256 i = 0; i < opasLen; i++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[i];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n //address(1) is special marker of \"signature error\"\n require(address(aggregator) != address(1), \"AA96 invalid aggregator\");\n\n if (address(aggregator) != address(0)) {\n // solhint-disable-next-line no-empty-blocks\n try aggregator.validateSignatures(ops, opa.signature) {}\n catch {\n revert SignatureValidationFailed(address(aggregator));\n }\n }\n\n totalOps += ops.length;\n }\n\n UserOpInfo[] memory opInfos = new UserOpInfo[](totalOps);\n\n uint256 opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n uint256 opslen = ops.length;\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[opIndex];\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(opIndex, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, paymasterValidationData, address(aggregator));\n opIndex++;\n }\n }\n\n uint256 collected = 0;\n opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n emit SignatureAggregatorChanged(address(opa.aggregator));\n UserOperation[] calldata ops = opa.userOps;\n uint256 opslen = ops.length;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(opIndex, ops[i], opInfos[opIndex]);\n opIndex++;\n }\n }\n emit SignatureAggregatorChanged(address(0));\n\n _compensate(beneficiary, collected);\n }\n\n /// @inheritdoc IEntryPoint\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external override {\n\n UserOpInfo memory opInfo;\n _simulationOnlyValidations(op);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, op, opInfo);\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n\n numberMarker();\n uint256 paid = _executeUserOp(0, op, opInfo);\n numberMarker();\n bool targetSuccess;\n bytes memory targetResult;\n if (target != address(0)) {\n (targetSuccess, targetResult) = target.call(targetCallData);\n }\n revert ExecutionResult(opInfo.preOpGas, paid, data.validAfter, data.validUntil, targetSuccess, targetResult);\n }\n\n\n // A memory copy of UserOp static fields only.\n // Excluding: callData, initCode and signature. Replacing paymasterAndData with paymaster.\n struct MemoryUserOp {\n address sender;\n uint256 nonce;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n address paymaster;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n }\n\n struct UserOpInfo {\n MemoryUserOp mUserOp;\n bytes32 userOpHash;\n uint256 prefund;\n uint256 contextOffset;\n uint256 preOpGas;\n }\n\n /**\n * inner function to handle a UserOperation.\n * Must be declared \"external\" to open a call context, but it can only be called by handleOps.\n */\n function innerHandleOp(bytes memory callData, UserOpInfo memory opInfo, bytes calldata context) external returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n require(msg.sender == address(this), \"AA92 internal call only\");\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n\n uint callGasLimit = mUserOp.callGasLimit;\n unchecked {\n // handleOps was called with gas limit too low. abort entire bundle.\n if (gasleft() < callGasLimit + mUserOp.verificationGasLimit + 5000) {\n assembly {\n mstore(0, INNER_OUT_OF_GAS)\n revert(0, 32)\n }\n }\n }\n\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\n if (callData.length > 0) {\n bool success = Exec.call(mUserOp.sender, 0, callData, callGasLimit);\n if (!success) {\n bytes memory result = Exec.getReturnData(REVERT_REASON_MAX_LEN);\n if (result.length > 0) {\n emit UserOperationRevertReason(opInfo.userOpHash, mUserOp.sender, mUserOp.nonce, result);\n }\n mode = IPaymaster.PostOpMode.opReverted;\n }\n }\n\n unchecked {\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n //note: opIndex is ignored (relevant only if mode==postOpReverted, which is only possible outside of innerHandleOp)\n return _handlePostOp(0, mode, opInfo, context, actualGas);\n }\n }\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) public view returns (bytes32) {\n return keccak256(abi.encode(userOp.hash(), address(this), block.chainid));\n }\n\n /**\n * copy general fields from userOp into the memory opInfo structure.\n */\n function _copyUserOpToMemory(UserOperation calldata userOp, MemoryUserOp memory mUserOp) internal pure {\n mUserOp.sender = userOp.sender;\n mUserOp.nonce = userOp.nonce;\n mUserOp.callGasLimit = userOp.callGasLimit;\n mUserOp.verificationGasLimit = userOp.verificationGasLimit;\n mUserOp.preVerificationGas = userOp.preVerificationGas;\n mUserOp.maxFeePerGas = userOp.maxFeePerGas;\n mUserOp.maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes calldata paymasterAndData = userOp.paymasterAndData;\n if (paymasterAndData.length > 0) {\n require(paymasterAndData.length >= 20, \"AA93 invalid paymasterAndData\");\n mUserOp.paymaster = address(bytes20(paymasterAndData[: 20]));\n } else {\n mUserOp.paymaster = address(0);\n }\n }\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external {\n UserOpInfo memory outOpInfo;\n\n _simulationOnlyValidations(userOp);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, userOp, outOpInfo);\n StakeInfo memory paymasterInfo = _getStakeInfo(outOpInfo.mUserOp.paymaster);\n StakeInfo memory senderInfo = _getStakeInfo(outOpInfo.mUserOp.sender);\n StakeInfo memory factoryInfo;\n {\n bytes calldata initCode = userOp.initCode;\n address factory = initCode.length >= 20 ? address(bytes20(initCode[0 : 20])) : address(0);\n factoryInfo = _getStakeInfo(factory);\n }\n\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n address aggregator = data.aggregator;\n bool sigFailed = aggregator == address(1);\n ReturnInfo memory returnInfo = ReturnInfo(outOpInfo.preOpGas, outOpInfo.prefund,\n sigFailed, data.validAfter, data.validUntil, getMemoryBytesFromOffset(outOpInfo.contextOffset));\n\n if (aggregator != address(0) && aggregator != address(1)) {\n AggregatorStakeInfo memory aggregatorInfo = AggregatorStakeInfo(aggregator, _getStakeInfo(aggregator));\n revert ValidationResultWithAggregation(returnInfo, senderInfo, factoryInfo, paymasterInfo, aggregatorInfo);\n }\n revert ValidationResult(returnInfo, senderInfo, factoryInfo, paymasterInfo);\n\n }\n\n function _getRequiredPrefund(MemoryUserOp memory mUserOp) internal pure returns (uint256 requiredPrefund) {\n unchecked {\n //when using a Paymaster, the verificationGasLimit is used also to as a limit for the postOp call.\n // our security model might call postOp eventually twice\n uint256 mul = mUserOp.paymaster != address(0) ? 3 : 1;\n uint256 requiredGas = mUserOp.callGasLimit + mUserOp.verificationGasLimit * mul + mUserOp.preVerificationGas;\n\n requiredPrefund = requiredGas * mUserOp.maxFeePerGas;\n }\n }\n\n // create the sender's contract if needed.\n function _createSenderIfNeeded(uint256 opIndex, UserOpInfo memory opInfo, bytes calldata initCode) internal {\n if (initCode.length != 0) {\n address sender = opInfo.mUserOp.sender;\n if (sender.code.length != 0) revert FailedOp(opIndex, \"AA10 sender already constructed\");\n address sender1 = senderCreator.createSender{gas : opInfo.mUserOp.verificationGasLimit}(initCode);\n if (sender1 == address(0)) revert FailedOp(opIndex, \"AA13 initCode failed or OOG\");\n if (sender1 != sender) revert FailedOp(opIndex, \"AA14 initCode must return sender\");\n if (sender1.code.length == 0) revert FailedOp(opIndex, \"AA15 initCode must create sender\");\n address factory = address(bytes20(initCode[0 : 20]));\n emit AccountDeployed(opInfo.userOpHash, sender, factory, opInfo.mUserOp.paymaster);\n }\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes calldata initCode) public {\n revert SenderAddressResult(senderCreator.createSender(initCode));\n }\n\n function _simulationOnlyValidations(UserOperation calldata userOp) internal view {\n // solhint-disable-next-line no-empty-blocks\n try this._validateSenderAndPaymaster(userOp.initCode, userOp.sender, userOp.paymasterAndData) {}\n catch Error(string memory revertReason) {\n if (bytes(revertReason).length != 0) {\n revert FailedOp(0, revertReason);\n }\n }\n }\n\n /**\n * Called only during simulation.\n * This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\n */\n function _validateSenderAndPaymaster(bytes calldata initCode, address sender, bytes calldata paymasterAndData) external view {\n if (initCode.length == 0 && sender.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA20 account not deployed\");\n }\n if (paymasterAndData.length >= 20) {\n address paymaster = address(bytes20(paymasterAndData[0 : 20]));\n if (paymaster.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA30 paymaster not deployed\");\n }\n }\n // always revert\n revert(\"\");\n }\n\n /**\n * call account.validateUserOp.\n * revert (with FailedOp) in case validateUserOp reverts, or account didn't send required prefund.\n * decrement account's deposit if needed\n */\n function _validateAccountPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPrefund)\n internal returns (uint256 gasUsedByValidateAccountPrepayment, uint256 validationData) {\n unchecked {\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n address sender = mUserOp.sender;\n _createSenderIfNeeded(opIndex, opInfo, op.initCode);\n address paymaster = mUserOp.paymaster;\n numberMarker();\n uint256 missingAccountFunds = 0;\n if (paymaster == address(0)) {\n uint256 bal = balanceOf(sender);\n missingAccountFunds = bal > requiredPrefund ? 0 : requiredPrefund - bal;\n }\n try IAccount(sender).validateUserOp{gas : mUserOp.verificationGasLimit}(op, opInfo.userOpHash, missingAccountFunds)\n returns (uint256 _validationData) {\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA23 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA23 reverted (or OOG)\");\n }\n if (paymaster == address(0)) {\n DepositInfo storage senderInfo = deposits[sender];\n uint256 deposit = senderInfo.deposit;\n if (requiredPrefund > deposit) {\n revert FailedOp(opIndex, \"AA21 didn't pay prefund\");\n }\n senderInfo.deposit = uint112(deposit - requiredPrefund);\n }\n gasUsedByValidateAccountPrepayment = preGas - gasleft();\n }\n }\n\n /**\n * In case the request has a paymaster:\n * Validate paymaster has enough deposit.\n * Call paymaster.validatePaymasterUserOp.\n * Revert with proper FailedOp in case paymaster reverts.\n * Decrement paymaster's deposit\n */\n function _validatePaymasterPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPreFund, uint256 gasUsedByValidateAccountPrepayment)\n internal returns (bytes memory context, uint256 validationData) {\n unchecked {\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 verificationGasLimit = mUserOp.verificationGasLimit;\n require(verificationGasLimit > gasUsedByValidateAccountPrepayment, \"AA41 too little verificationGas\");\n uint256 gas = verificationGasLimit - gasUsedByValidateAccountPrepayment;\n\n address paymaster = mUserOp.paymaster;\n DepositInfo storage paymasterInfo = deposits[paymaster];\n uint256 deposit = paymasterInfo.deposit;\n if (deposit < requiredPreFund) {\n revert FailedOp(opIndex, \"AA31 paymaster deposit too low\");\n }\n paymasterInfo.deposit = uint112(deposit - requiredPreFund);\n try IPaymaster(paymaster).validatePaymasterUserOp{gas : gas}(op, opInfo.userOpHash, requiredPreFund) returns (bytes memory _context, uint256 _validationData){\n context = _context;\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA33 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA33 reverted (or OOG)\");\n }\n }\n }\n\n /**\n * revert if either account validationData or paymaster validationData is expired\n */\n function _validateAccountAndPaymasterValidationData(uint256 opIndex, uint256 validationData, uint256 paymasterValidationData, address expectedAggregator) internal view {\n (address aggregator, bool outOfTimeRange) = _getValidationData(validationData);\n if (expectedAggregator != aggregator) {\n revert FailedOp(opIndex, \"AA24 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA22 expired or not due\");\n }\n //pmAggregator is not a real signature aggregator: we don't have logic to handle it as address.\n // non-zero address means that the paymaster fails due to some signature check (which is ok only during estimation)\n address pmAggregator;\n (pmAggregator, outOfTimeRange) = _getValidationData(paymasterValidationData);\n if (pmAggregator != address(0)) {\n revert FailedOp(opIndex, \"AA34 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA32 paymaster expired or not due\");\n }\n }\n\n function _getValidationData(uint256 validationData) internal view returns (address aggregator, bool outOfTimeRange) {\n if (validationData == 0) {\n return (address(0), false);\n }\n ValidationData memory data = _parseValidationData(validationData);\n // solhint-disable-next-line not-rely-on-time\n outOfTimeRange = block.timestamp > data.validUntil || block.timestamp < data.validAfter;\n aggregator = data.aggregator;\n }\n\n /**\n * validate account and paymaster (if defined).\n * also make sure total validation doesn't exceed verificationGasLimit\n * this method is called off-chain (simulateValidation()) and on-chain (from handleOps)\n * @param opIndex the index of this userOp into the \"opInfos\" array\n * @param userOp the userOp to validate\n */\n function _validatePrepayment(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory outOpInfo)\n private returns (uint256 validationData, uint256 paymasterValidationData) {\n\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = outOpInfo.mUserOp;\n _copyUserOpToMemory(userOp, mUserOp);\n outOpInfo.userOpHash = getUserOpHash(userOp);\n\n // validate all numeric values in userOp are well below 128 bit, so they can safely be added\n // and multiplied without causing overflow\n uint256 maxGasValues = mUserOp.preVerificationGas | mUserOp.verificationGasLimit | mUserOp.callGasLimit |\n userOp.maxFeePerGas | userOp.maxPriorityFeePerGas;\n require(maxGasValues <= type(uint120).max, \"AA94 gas values overflow\");\n\n uint256 gasUsedByValidateAccountPrepayment;\n (uint256 requiredPreFund) = _getRequiredPrefund(mUserOp);\n (gasUsedByValidateAccountPrepayment, validationData) = _validateAccountPrepayment(opIndex, userOp, outOpInfo, requiredPreFund);\n //a \"marker\" where account opcode validation is done and paymaster opcode validation is about to start\n // (used only by off-chain simulateValidation)\n numberMarker();\n\n bytes memory context;\n if (mUserOp.paymaster != address(0)) {\n (context, paymasterValidationData) = _validatePaymasterPrepayment(opIndex, userOp, outOpInfo, requiredPreFund, gasUsedByValidateAccountPrepayment);\n }\n unchecked {\n uint256 gasUsed = preGas - gasleft();\n\n if (userOp.verificationGasLimit < gasUsed) {\n revert FailedOp(opIndex, \"AA40 over verificationGasLimit\");\n }\n outOpInfo.prefund = requiredPreFund;\n outOpInfo.contextOffset = getOffsetOfMemoryBytes(context);\n outOpInfo.preOpGas = preGas - gasleft() + userOp.preVerificationGas;\n }\n }\n\n /**\n * process post-operation.\n * called just after the callData is executed.\n * if a paymaster is defined and its validation returned a non-empty context, its postOp is called.\n * the excess amount is refunded to the account (or paymaster - if it was used in the request)\n * @param opIndex index in the batch\n * @param mode - whether is called from innerHandleOp, or outside (postOpReverted)\n * @param opInfo userOp fields and info collected during validation\n * @param context the context returned in validatePaymasterUserOp\n * @param actualGas the gas used so far by this user operation\n */\n function _handlePostOp(uint256 opIndex, IPaymaster.PostOpMode mode, UserOpInfo memory opInfo, bytes memory context, uint256 actualGas) private returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n unchecked {\n address refundAddress;\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 gasPrice = getUserOpGasPrice(mUserOp);\n\n address paymaster = mUserOp.paymaster;\n if (paymaster == address(0)) {\n refundAddress = mUserOp.sender;\n } else {\n refundAddress = paymaster;\n if (context.length > 0) {\n actualGasCost = actualGas * gasPrice;\n if (mode != IPaymaster.PostOpMode.postOpReverted) {\n IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost);\n } else {\n // solhint-disable-next-line no-empty-blocks\n try IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost) {}\n catch Error(string memory reason) {\n revert FailedOp(opIndex, string.concat(\"AA50 postOp reverted: \", reason));\n }\n catch {\n revert FailedOp(opIndex, \"AA50 postOp revert\");\n }\n }\n }\n }\n actualGas += preGas - gasleft();\n actualGasCost = actualGas * gasPrice;\n if (opInfo.prefund < actualGasCost) {\n revert FailedOp(opIndex, \"AA51 prefund below actualGasCost\");\n }\n uint256 refund = opInfo.prefund - actualGasCost;\n _incrementDeposit(refundAddress, refund);\n bool success = mode == IPaymaster.PostOpMode.opSucceeded;\n emit UserOperationEvent(opInfo.userOpHash, mUserOp.sender, mUserOp.paymaster, mUserOp.nonce, success, actualGasCost, actualGas);\n } // unchecked\n }\n\n /**\n * the gas price this UserOp agrees to pay.\n * relayer/block builder might submit the TX with higher priorityFee, but the user should not\n */\n function getUserOpGasPrice(MemoryUserOp memory mUserOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = mUserOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = mUserOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n\n function getOffsetOfMemoryBytes(bytes memory data) internal pure returns (uint256 offset) {\n assembly {offset := data}\n }\n\n function getMemoryBytesFromOffset(uint256 offset) internal pure returns (bytes memory data) {\n assembly {data := offset}\n }\n\n //place the NUMBER opcode in the code.\n // this is used as a marker during simulation, as this OP is completely banned from the simulated code of the\n // account and paymaster.\n function numberMarker() internal view {\n assembly {mstore(0, number())}\n }\n}\n\n" - }, - "contracts/core/Helpers.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * returned data from validateUserOp.\n * validateUserOp returns a uint256, with is created by `_packedValidationData` and parsed by `_parseValidationData`\n * @param aggregator - address(0) - the account validated the signature by itself.\n * address(1) - the account failed to validate the signature.\n * otherwise - this is an address of a signature aggregator that must be used to validate the signature.\n * @param validAfter - this UserOp is valid only after this timestamp.\n * @param validaUntil - this UserOp is valid only up to this timestamp.\n */\n struct ValidationData {\n address aggregator;\n uint48 validAfter;\n uint48 validUntil;\n }\n\n//extract sigFailed, validAfter, validUntil.\n// also convert zero validUntil to type(uint48).max\n function _parseValidationData(uint validationData) pure returns (ValidationData memory data) {\n address aggregator = address(uint160(validationData));\n uint48 validUntil = uint48(validationData >> 160);\n if (validUntil == 0) {\n validUntil = type(uint48).max;\n }\n uint48 validAfter = uint48(validationData >> (48 + 160));\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n// intersect account and paymaster ranges.\n function _intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) pure returns (ValidationData memory) {\n ValidationData memory accountValidationData = _parseValidationData(validationData);\n ValidationData memory pmValidationData = _parseValidationData(paymasterValidationData);\n address aggregator = accountValidationData.aggregator;\n if (aggregator == address(0)) {\n aggregator = pmValidationData.aggregator;\n }\n uint48 validAfter = accountValidationData.validAfter;\n uint48 validUntil = accountValidationData.validUntil;\n uint48 pmValidAfter = pmValidationData.validAfter;\n uint48 pmValidUntil = pmValidationData.validUntil;\n\n if (validAfter < pmValidAfter) validAfter = pmValidAfter;\n if (validUntil > pmValidUntil) validUntil = pmValidUntil;\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n/**\n * helper to pack the return value for validateUserOp\n * @param data - the ValidationData to pack\n */\n function _packValidationData(ValidationData memory data) pure returns (uint256) {\n return uint160(data.aggregator) | (uint256(data.validUntil) << 160) | (uint256(data.validAfter) << (160 + 48));\n }\n\n/**\n * helper to pack the return value for validateUserOp, when not using an aggregator\n * @param sigFailed - true for signature failure, false for success\n * @param validUntil last timestamp this UserOperation is valid (or zero for infinite)\n * @param validAfter first timestamp this UserOperation is valid\n */\n function _packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) pure returns (uint256) {\n return (sigFailed ? 1 : 0) | (uint256(validUntil) << 160) | (uint256(validAfter) << (160 + 48));\n }\n" - }, - "contracts/core/SenderCreator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * helper contract for EntryPoint, to call userOp.initCode from a \"neutral\" address,\n * which is explicitly not the entryPoint itself.\n */\ncontract SenderCreator {\n\n /**\n * call the \"initCode\" factory to create and return the sender account address\n * @param initCode the initCode value from a UserOp. contains 20 bytes of factory address, followed by calldata\n * @return sender the returned address of the created account, or zero address on failure.\n */\n function createSender(bytes calldata initCode) external returns (address sender) {\n address factory = address(bytes20(initCode[0 : 20]));\n bytes memory initCallData = initCode[20 :];\n bool success;\n /* solhint-disable no-inline-assembly */\n assembly {\n success := call(gas(), factory, 0, add(initCallData, 0x20), mload(initCallData), 0, 32)\n sender := mload(0)\n }\n if (!success) {\n sender = address(0);\n }\n }\n}\n" - }, - "contracts/core/StakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IStakeManager.sol\";\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable not-rely-on-time */\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by a paymaster.\n */\nabstract contract StakeManager is IStakeManager {\n\n /// maps paymaster to their deposits and stakes\n mapping(address => DepositInfo) public deposits;\n\n /// @inheritdoc IStakeManager\n function getDepositInfo(address account) public view returns (DepositInfo memory info) {\n return deposits[account];\n }\n\n // internal method to return just the stake info\n function _getStakeInfo(address addr) internal view returns (StakeInfo memory info) {\n DepositInfo storage depositInfo = deposits[addr];\n info.stake = depositInfo.stake;\n info.unstakeDelaySec = depositInfo.unstakeDelaySec;\n }\n\n /// return the deposit (for gas payment) of the account\n function balanceOf(address account) public view returns (uint256) {\n return deposits[account].deposit;\n }\n\n receive() external payable {\n depositTo(msg.sender);\n }\n\n function _incrementDeposit(address account, uint256 amount) internal {\n DepositInfo storage info = deposits[account];\n uint256 newAmount = info.deposit + amount;\n require(newAmount <= type(uint112).max, \"deposit overflow\");\n info.deposit = uint112(newAmount);\n }\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) public payable {\n _incrementDeposit(account, msg.value);\n DepositInfo storage info = deposits[account];\n emit Deposited(account, info.deposit);\n }\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 unstakeDelaySec) public payable {\n DepositInfo storage info = deposits[msg.sender];\n require(unstakeDelaySec > 0, \"must specify unstake delay\");\n require(unstakeDelaySec >= info.unstakeDelaySec, \"cannot decrease unstake time\");\n uint256 stake = info.stake + msg.value;\n require(stake > 0, \"no stake specified\");\n require(stake <= type(uint112).max, \"stake overflow\");\n deposits[msg.sender] = DepositInfo(\n info.deposit,\n true,\n uint112(stake),\n unstakeDelaySec,\n 0\n );\n emit StakeLocked(msg.sender, stake, unstakeDelaySec);\n }\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external {\n DepositInfo storage info = deposits[msg.sender];\n require(info.unstakeDelaySec != 0, \"not staked\");\n require(info.staked, \"already unstaking\");\n uint48 withdrawTime = uint48(block.timestamp) + info.unstakeDelaySec;\n info.withdrawTime = withdrawTime;\n info.staked = false;\n emit StakeUnlocked(msg.sender, withdrawTime);\n }\n\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external {\n DepositInfo storage info = deposits[msg.sender];\n uint256 stake = info.stake;\n require(stake > 0, \"No stake to withdraw\");\n require(info.withdrawTime > 0, \"must call unlockStake() first\");\n require(info.withdrawTime <= block.timestamp, \"Stake withdrawal is not due\");\n info.unstakeDelaySec = 0;\n info.withdrawTime = 0;\n info.stake = 0;\n emit StakeWithdrawn(msg.sender, withdrawAddress, stake);\n (bool success,) = withdrawAddress.call{value : stake}(\"\");\n require(success, \"failed to withdraw stake\");\n }\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external {\n DepositInfo storage info = deposits[msg.sender];\n require(withdrawAmount <= info.deposit, \"Withdraw amount too large\");\n info.deposit = uint112(info.deposit - withdrawAmount);\n emit Withdrawn(msg.sender, withdrawAddress, withdrawAmount);\n (bool success,) = withdrawAddress.call{value : withdrawAmount}(\"\");\n require(success, \"failed to withdraw\");\n }\n}\n" - }, - "contracts/interfaces/IAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\ninterface IAccount {\n\n /**\n * Validate user's signature and nonce\n * the entryPoint will make the call to the recipient only if this validation call returns successfully.\n * signature failure should be reported by returning SIG_VALIDATION_FAILED (1).\n * This allows making a \"simulation call\" without a valid signature\n * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure.\n *\n * @dev Must validate caller is the entryPoint.\n * Must validate the signature and nonce\n * @param userOp the operation that is about to be executed.\n * @param userOpHash hash of the user's request data. can be used as the basis for signature.\n * @param missingAccountFunds missing funds on the account's deposit in the entrypoint.\n * This is the minimum amount to transfer to the sender(entryPoint) to be able to make the call.\n * The excess is left as a deposit in the entrypoint, for future calls.\n * can be withdrawn anytime using \"entryPoint.withdrawTo()\"\n * In case there is a paymaster in the request (or the current deposit is high enough), this value will be zero.\n * @return validationData packaged ValidationData structure. use `_packValidationData` and `_unpackValidationData` to encode and decode\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * If an account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external returns (uint256 validationData);\n}\n" - }, - "contracts/interfaces/IAggregator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * Aggregated Signatures validator.\n */\ninterface IAggregator {\n\n /**\n * validate aggregated signature.\n * revert if the aggregated signature does not match the given list of operations.\n */\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external view;\n\n /**\n * validate signature of a single userOp\n * This method is should be called by bundler after EntryPoint.simulateValidation() returns (reverts) with ValidationResultWithAggregation\n * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps.\n * @param userOp the userOperation received from the user.\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\n * (usually empty, unless account and aggregator support some kind of \"multisig\"\n */\n function validateUserOpSignature(UserOperation calldata userOp)\n external view returns (bytes memory sigForUserOp);\n\n /**\n * aggregate multiple signatures into a single value.\n * This method is called off-chain to calculate the signature to pass with handleOps()\n * bundler MAY use optimized custom code perform this aggregation\n * @param userOps array of UserOperations to collect the signatures from.\n * @return aggregatedSignature the aggregated signature\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external view returns (bytes memory aggregatedSignature);\n}\n" - }, - "contracts/interfaces/IEntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"./UserOperation.sol\";\nimport \"./IStakeManager.sol\";\nimport \"./IAggregator.sol\";\n\ninterface IEntryPoint is IStakeManager {\n\n /***\n * An event emitted after each successful request\n * @param userOpHash - unique identifier for the request (hash its entire content, except signature).\n * @param sender - the account that generates this request.\n * @param paymaster - if non-null, the paymaster that pays for this request.\n * @param nonce - the nonce value from the request.\n * @param success - true if the sender transaction succeeded, false if reverted.\n * @param actualGasCost - actual amount paid (by account or paymaster) for this UserOperation.\n * @param actualGasUsed - total gas used by this UserOperation (including preVerification, creation, validation and execution).\n */\n event UserOperationEvent(bytes32 indexed userOpHash, address indexed sender, address indexed paymaster, uint256 nonce, bool success, uint256 actualGasCost, uint256 actualGasUsed);\n\n /**\n * account \"sender\" was deployed.\n * @param userOpHash the userOp that deployed this account. UserOperationEvent will follow.\n * @param sender the account that is deployed\n * @param factory the factory used to deploy this account (in the initCode)\n * @param paymaster the paymaster used by this UserOp\n */\n event AccountDeployed(bytes32 indexed userOpHash, address indexed sender, address factory, address paymaster);\n\n /**\n * An event emitted if the UserOperation \"callData\" reverted with non-zero length\n * @param userOpHash the request unique identifier.\n * @param sender the sender of this request\n * @param nonce the nonce used in the request\n * @param revertReason - the return bytes from the (reverted) call to \"callData\".\n */\n event UserOperationRevertReason(bytes32 indexed userOpHash, address indexed sender, uint256 nonce, bytes revertReason);\n\n /**\n * signature aggregator used by the following UserOperationEvents within this bundle.\n */\n event SignatureAggregatorChanged(address indexed aggregator);\n\n /**\n * a custom revert error of handleOps, to identify the offending op.\n * NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\n * @param opIndex - index into the array of ops to the failed one (in simulateValidation, this is always zero)\n * @param reason - revert reason\n * The string starts with a unique code \"AAmn\", where \"m\" is \"1\" for factory, \"2\" for account and \"3\" for paymaster issues,\n * so a failure can be attributed to the correct entity.\n * Should be caught in off-chain handleOps simulation and not happen on-chain.\n * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\n */\n error FailedOp(uint256 opIndex, string reason);\n\n /**\n * error case when a signature aggregator fails to verify the aggregated signature it had created.\n */\n error SignatureValidationFailed(address aggregator);\n\n /**\n * Successful result from simulateValidation.\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n */\n error ValidationResult(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo);\n\n /**\n * Successful result from simulateValidation, if the account returns a signature aggregator\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n * @param aggregatorInfo signature aggregation info (if the account requires signature aggregator)\n * bundler MUST use it to verify the signature, or reject the UserOperation\n */\n error ValidationResultWithAggregation(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo,\n AggregatorStakeInfo aggregatorInfo);\n\n /**\n * return value of getSenderAddress\n */\n error SenderAddressResult(address sender);\n\n /**\n * return value of simulateHandleOp\n */\n error ExecutionResult(uint256 preOpGas, uint256 paid, uint48 validAfter, uint48 validUntil, bool targetSuccess, bytes targetResult);\n\n //UserOps handled, per aggregator\n struct UserOpsPerAggregator {\n UserOperation[] userOps;\n\n // aggregator address\n IAggregator aggregator;\n // aggregated signature\n bytes signature;\n }\n\n /**\n * Execute a batch of UserOperation.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) external;\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) external;\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) external view returns (bytes32);\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external;\n\n /**\n * gas and return values during simulation\n * @param preOpGas the gas used for validation (including preValidationGas)\n * @param prefund the required prefund for this operation\n * @param sigFailed validateUserOp's (or paymaster's) signature check failed\n * @param validAfter - first timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param validUntil - last timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param paymasterContext returned by validatePaymasterUserOp (to be passed into postOp)\n */\n struct ReturnInfo {\n uint256 preOpGas;\n uint256 prefund;\n bool sigFailed;\n uint48 validAfter;\n uint48 validUntil;\n bytes paymasterContext;\n }\n\n /**\n * returned aggregated signature info.\n * the aggregator returned by the account, and its current stake.\n */\n struct AggregatorStakeInfo {\n address aggregator;\n StakeInfo stakeInfo;\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes memory initCode) external;\n\n\n /**\n * simulate full execution of a UserOperation (including both validation and target execution)\n * this method will always revert with \"ExecutionResult\".\n * it performs full validation of the UserOperation, but ignores signature error.\n * an optional target address is called after the userop succeeds, and its value is returned\n * (before the entire call is reverted)\n * Note that in order to collect the the success/failure of the target call, it must be executed\n * with trace enabled to track the emitted events.\n * @param op the UserOperation to simulate\n * @param target if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult\n * are set to the return from that call.\n * @param targetCallData callData to pass to target address\n */\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external;\n}\n\n" - }, - "contracts/interfaces/IPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * the interface exposed by a paymaster contract, who agrees to pay the gas for user's operations.\n * a paymaster must hold a stake to cover the required entrypoint stake and also the gas for the transaction.\n */\ninterface IPaymaster {\n\n enum PostOpMode {\n opSucceeded, // user op succeeded\n opReverted, // user op reverted. still has to pay for gas.\n postOpReverted //user op succeeded, but caused postOp to revert. Now it's a 2nd call, after user's op was deliberately reverted.\n }\n\n /**\n * payment validation: check if paymaster agrees to pay.\n * Must verify sender is the entryPoint.\n * Revert to reject this request.\n * Note that bundlers will reject this method if it changes the state, unless the paymaster is trusted (whitelisted)\n * The paymaster pre-pays using its deposit, and receive back a refund after the postOp method returns.\n * @param userOp the user operation\n * @param userOpHash hash of the user's request data.\n * @param maxCost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\n * @return context value to send to a postOp\n * zero length to signify postOp is not required.\n * @return validationData signature and time-range of this operation, encoded the same as the return value of validateUserOperation\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n external returns (bytes memory context, uint256 validationData);\n\n /**\n * post-operation handler.\n * Must verify sender is the entryPoint\n * @param mode enum with the following options:\n * opSucceeded - user operation succeeded.\n * opReverted - user op reverted. still has to pay for gas.\n * postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n * Now this is the 2nd call, after user's op was deliberately reverted.\n * @param context - the context value returned by validatePaymasterUserOp\n * @param actualGasCost - actual gas used so far (without this postOp call).\n */\n function postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) external;\n}\n" - }, - "contracts/interfaces/IStakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by the staked entity.\n */\ninterface IStakeManager {\n\n event Deposited(\n address indexed account,\n uint256 totalDeposit\n );\n\n event Withdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /// Emitted when stake or unstake delay are modified\n event StakeLocked(\n address indexed account,\n uint256 totalStaked,\n uint256 unstakeDelaySec\n );\n\n /// Emitted once a stake is scheduled for withdrawal\n event StakeUnlocked(\n address indexed account,\n uint256 withdrawTime\n );\n\n event StakeWithdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /**\n * @param deposit the entity's deposit\n * @param staked true if this entity is staked.\n * @param stake actual amount of ether staked for this entity.\n * @param unstakeDelaySec minimum delay to withdraw the stake.\n * @param withdrawTime - first block timestamp where 'withdrawStake' will be callable, or zero if already locked\n * @dev sizes were chosen so that (deposit,staked, stake) fit into one cell (used during handleOps)\n * and the rest fit into a 2nd cell.\n * 112 bit allows for 10^15 eth\n * 48 bit for full timestamp\n * 32 bit allows 150 years for unstake delay\n */\n struct DepositInfo {\n uint112 deposit;\n bool staked;\n uint112 stake;\n uint32 unstakeDelaySec;\n uint48 withdrawTime;\n }\n\n //API struct used by getStakeInfo and simulateValidation\n struct StakeInfo {\n uint256 stake;\n uint256 unstakeDelaySec;\n }\n\n /// @return info - full deposit information of given account\n function getDepositInfo(address account) external view returns (DepositInfo memory info);\n\n /// @return the deposit (for gas payment) of the account\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) external payable;\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param _unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 _unstakeDelaySec) external payable;\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external;\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external;\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external;\n}\n" - }, - "contracts/interfaces/UserOperation.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\n /**\n * User Operation struct\n * @param sender the sender account of this request.\n * @param nonce unique value the sender uses to verify it is not a replay.\n * @param initCode if set, the account contract will be created by this constructor/\n * @param callData the method call to execute on this account.\n * @param callGasLimit the gas limit passed to the callData method call.\n * @param verificationGasLimit gas used for validateUserOp and validatePaymasterUserOp.\n * @param preVerificationGas gas not calculated by the handleOps method, but added to the gas paid. Covers batch overhead.\n * @param maxFeePerGas same as EIP-1559 gas parameter.\n * @param maxPriorityFeePerGas same as EIP-1559 gas parameter.\n * @param paymasterAndData if set, this field holds the paymaster address and paymaster-specific data. the paymaster will pay for the transaction instead of the sender.\n * @param signature sender-verified signature over the entire request, the EntryPoint address and the chain ID.\n */\n struct UserOperation {\n\n address sender;\n uint256 nonce;\n bytes initCode;\n bytes callData;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n bytes paymasterAndData;\n bytes signature;\n }\n\n/**\n * Utility functions helpful when working with UserOperation structs.\n */\nlibrary UserOperationLib {\n\n function getSender(UserOperation calldata userOp) internal pure returns (address) {\n address data;\n //read sender from userOp, which is first userOp member (saves 800 gas...)\n assembly {data := calldataload(userOp)}\n return address(uint160(data));\n }\n\n //relayer/block builder might submit the TX with higher priorityFee, but the user should not\n // pay above what he signed for.\n function gasPrice(UserOperation calldata userOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n //lighter signature scheme. must match UserOp.ts#packUserOp\n bytes calldata sig = userOp.signature;\n // copy directly the userOp from calldata up to (but not including) the signature.\n // this encoding depends on the ABI encoding of calldata, but is much lighter to copy\n // than referencing each field separately.\n assembly {\n let ofs := userOp\n let len := sub(sub(sig.offset, ofs), 32)\n ret := mload(0x40)\n mstore(0x40, add(ret, add(len, 32)))\n mstore(ret, len)\n calldatacopy(add(ret, 32), ofs, len)\n }\n }\n\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\n return keccak256(pack(userOp));\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n}\n" - }, - "contracts/utils/Exec.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.5 <0.9.0;\n\n// solhint-disable no-inline-assembly\n\n/**\n * Utility functions helpful when making different kinds of contract calls in Solidity.\n */\nlibrary Exec {\n\n function call(\n address to,\n uint256 value,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function staticcall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal view returns (bool success) {\n assembly {\n success := staticcall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function delegateCall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n // get returned data from last call or calldelegate\n function getReturnData(uint256 maxLen) internal pure returns (bytes memory returnData) {\n assembly {\n let len := returndatasize()\n if gt(len, maxLen) {\n len := maxLen\n }\n let ptr := mload(0x40)\n mstore(0x40, add(ptr, add(len, 0x20)))\n mstore(ptr, len)\n returndatacopy(add(ptr, 0x20), 0, len)\n returnData := ptr\n }\n }\n\n // revert with explicit byte array (probably reverted info from call)\n function revertWithData(bytes memory returnData) internal pure {\n assembly {\n revert(add(returnData, 32), mload(returnData))\n }\n }\n\n function callAndRevert(address to, bytes memory data, uint256 maxLen) internal {\n bool success = call(to,0,data,gasleft());\n if (!success) {\n revertWithData(getReturnData(maxLen));\n }\n }\n}\n" - } - }, - "settings": { - "optimizer": { - "enabled": true, - "runs": 1000000 - }, - "viaIR": true, - "outputSelection": { - "*": { - "*": [ - "abi", - "evm.bytecode", - "evm.deployedBytecode", - "evm.methodIdentifiers", - "metadata" - ], - "": [ - "ast" - ] - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mumbai/.chainId b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mumbai/.chainId deleted file mode 100644 index d7e2f72ced..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mumbai/.chainId +++ /dev/null @@ -1 +0,0 @@ -80001 \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mumbai/EntryPoint.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mumbai/EntryPoint.json deleted file mode 100644 index 916c239083..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mumbai/EntryPoint.json +++ /dev/null @@ -1,1318 +0,0 @@ -{ - "address": "0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789", - "abi": [ - { - "inputs": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "paid", - "type": "uint256" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bool", - "name": "targetSuccess", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "targetResult", - "type": "bytes" - } - ], - "name": "ExecutionResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "opIndex", - "type": "uint256" - }, - { - "internalType": "string", - "name": "reason", - "type": "string" - } - ], - "name": "FailedOp", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - } - ], - "name": "SenderAddressResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureValidationFailed", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - } - ], - "name": "ValidationResult", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "stakeInfo", - "type": "tuple" - } - ], - "internalType": "struct IEntryPoint.AggregatorStakeInfo", - "name": "aggregatorInfo", - "type": "tuple" - } - ], - "name": "ValidationResultWithAggregation", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "factory", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "paymaster", - "type": "address" - } - ], - "name": "AccountDeployed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [], - "name": "BeforeExecution", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalDeposit", - "type": "uint256" - } - ], - "name": "Deposited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureAggregatorChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalStaked", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "name": "StakeLocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "withdrawTime", - "type": "uint256" - } - ], - "name": "StakeUnlocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "StakeWithdrawn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasUsed", - "type": "uint256" - } - ], - "name": "UserOperationEvent", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "revertReason", - "type": "bytes" - } - ], - "name": "UserOperationRevertReason", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "Withdrawn", - "type": "event" - }, - { - "inputs": [], - "name": "SIG_VALIDATION_FAILED", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - } - ], - "name": "_validateSenderAndPaymaster", - "outputs": [], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - } - ], - "name": "addStake", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "depositTo", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "deposits", - "outputs": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "getDepositInfo", - "outputs": [ - { - "components": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "internalType": "struct IStakeManager.DepositInfo", - "name": "info", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "getNonce", - "outputs": [ - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - } - ], - "name": "getSenderAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "getUserOpHash", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "userOps", - "type": "tuple[]" - }, - { - "internalType": "contract IAggregator", - "name": "aggregator", - "type": "address" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.UserOpsPerAggregator[]", - "name": "opsPerAggregator", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleAggregatedOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "ops", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "incrementNonce", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.MemoryUserOp", - "name": "mUserOp", - "type": "tuple" - }, - { - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "contextOffset", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.UserOpInfo", - "name": "opInfo", - "type": "tuple" - }, - { - "internalType": "bytes", - "name": "context", - "type": "bytes" - } - ], - "name": "innerHandleOp", - "outputs": [ - { - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - }, - { - "internalType": "uint192", - "name": "", - "type": "uint192" - } - ], - "name": "nonceSequenceNumber", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "op", - "type": "tuple" - }, - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "targetCallData", - "type": "bytes" - } - ], - "name": "simulateHandleOp", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "simulateValidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unlockStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - } - ], - "name": "withdrawStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "withdrawAmount", - "type": "uint256" - } - ], - "name": "withdrawTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "args": [], - "numDeployments": 1, - "solcInputHash": "a4c52f0671aad8941c53d6ead2063803", - "metadata": "{\"compiler\":{\"version\":\"0.8.17+commit.8df45f5f\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"paid\",\"type\":\"uint256\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bool\",\"name\":\"targetSuccess\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"targetResult\",\"type\":\"bytes\"}],\"name\":\"ExecutionResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"opIndex\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\"}],\"name\":\"FailedOp\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderAddressResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureValidationFailed\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResult\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"stakeInfo\",\"type\":\"tuple\"}],\"internalType\":\"struct IEntryPoint.AggregatorStakeInfo\",\"name\":\"aggregatorInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResultWithAggregation\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"factory\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"}],\"name\":\"AccountDeployed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"BeforeExecution\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalDeposit\",\"type\":\"uint256\"}],\"name\":\"Deposited\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureAggregatorChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalStaked\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"name\":\"StakeLocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"withdrawTime\",\"type\":\"uint256\"}],\"name\":\"StakeUnlocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"StakeWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasUsed\",\"type\":\"uint256\"}],\"name\":\"UserOperationEvent\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"revertReason\",\"type\":\"bytes\"}],\"name\":\"UserOperationRevertReason\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Withdrawn\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"SIG_VALIDATION_FAILED\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"}],\"name\":\"_validateSenderAndPaymaster\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"}],\"name\":\"addStake\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"depositTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"deposits\",\"outputs\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getDepositInfo\",\"outputs\":[{\"components\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"internalType\":\"struct IStakeManager.DepositInfo\",\"name\":\"info\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"}],\"name\":\"getSenderAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"getUserOpHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"userOps\",\"type\":\"tuple[]\"},{\"internalType\":\"contract IAggregator\",\"name\":\"aggregator\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.UserOpsPerAggregator[]\",\"name\":\"opsPerAggregator\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleAggregatedOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"ops\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"incrementNonce\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.MemoryUserOp\",\"name\":\"mUserOp\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"contextOffset\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.UserOpInfo\",\"name\":\"opInfo\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"context\",\"type\":\"bytes\"}],\"name\":\"innerHandleOp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"\",\"type\":\"uint192\"}],\"name\":\"nonceSequenceNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"op\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"targetCallData\",\"type\":\"bytes\"}],\"name\":\"simulateHandleOp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"simulateValidation\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unlockStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"}],\"name\":\"withdrawStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"withdrawAmount\",\"type\":\"uint256\"}],\"name\":\"withdrawTo\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"errors\":{\"FailedOp(uint256,string)\":[{\"params\":{\"opIndex\":\"- index into the array of ops to the failed one (in simulateValidation, this is always zero)\",\"reason\":\"- revert reason The string starts with a unique code \\\"AAmn\\\", where \\\"m\\\" is \\\"1\\\" for factory, \\\"2\\\" for account and \\\"3\\\" for paymaster issues, so a failure can be attributed to the correct entity. Should be caught in off-chain handleOps simulation and not happen on-chain. Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\"}}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"params\":{\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"params\":{\"aggregatorInfo\":\"signature aggregation info (if the account requires signature aggregator) bundler MUST use it to verify the signature, or reject the UserOperation\",\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}]},\"kind\":\"dev\",\"methods\":{\"addStake(uint32)\":{\"params\":{\"unstakeDelaySec\":\"the new lock duration before the deposit can be withdrawn.\"}},\"getDepositInfo(address)\":{\"returns\":{\"info\":\"- full deposit information of given account\"}},\"getNonce(address,uint192)\":{\"params\":{\"key\":\"the high 192 bit of the nonce\",\"sender\":\"the account address\"},\"returns\":{\"nonce\":\"a full nonce to pass for next UserOp with this sender.\"}},\"getSenderAddress(bytes)\":{\"params\":{\"initCode\":\"the constructor code to be passed into the UserOperation.\"}},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"opsPerAggregator\":\"the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\"}},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"ops\":\"the operations to execute\"}},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"params\":{\"op\":\"the UserOperation to simulate\",\"target\":\"if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult are set to the return from that call.\",\"targetCallData\":\"callData to pass to target address\"}},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"details\":\"this method always revert. Successful result is ValidationResult error. other errors are failures.The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\",\"params\":{\"userOp\":\"the user operation to validate.\"}},\"withdrawStake(address)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\"}},\"withdrawTo(address,uint256)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\",\"withdrawAmount\":\"the amount to withdraw.\"}}},\"version\":1},\"userdoc\":{\"errors\":{\"ExecutionResult(uint256,uint256,uint48,uint48,bool,bytes)\":[{\"notice\":\"return value of simulateHandleOp\"}],\"FailedOp(uint256,string)\":[{\"notice\":\"a custom revert error of handleOps, to identify the offending op. NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\"}],\"SenderAddressResult(address)\":[{\"notice\":\"return value of getSenderAddress\"}],\"SignatureValidationFailed(address)\":[{\"notice\":\"error case when a signature aggregator fails to verify the aggregated signature it had created.\"}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"notice\":\"Successful result from simulateValidation.\"}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"notice\":\"Successful result from simulateValidation, if the account returns a signature aggregator\"}]},\"events\":{\"AccountDeployed(bytes32,address,address,address)\":{\"notice\":\"account \\\"sender\\\" was deployed.\"},\"BeforeExecution()\":{\"notice\":\"an event emitted by handleOps(), before starting the execution loop. any event emitted before this event, is part of the validation.\"},\"SignatureAggregatorChanged(address)\":{\"notice\":\"signature aggregator used by the following UserOperationEvents within this bundle.\"},\"StakeLocked(address,uint256,uint256)\":{\"notice\":\"Emitted when stake or unstake delay are modified\"},\"StakeUnlocked(address,uint256)\":{\"notice\":\"Emitted once a stake is scheduled for withdrawal\"},\"UserOperationRevertReason(bytes32,address,uint256,bytes)\":{\"notice\":\"An event emitted if the UserOperation \\\"callData\\\" reverted with non-zero length\"}},\"kind\":\"user\",\"methods\":{\"SIG_VALIDATION_FAILED()\":{\"notice\":\"for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value in case of signature failure, instead of revert.\"},\"_validateSenderAndPaymaster(bytes,address,bytes)\":{\"notice\":\"Called only during simulation. This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\"},\"addStake(uint32)\":{\"notice\":\"add to the account's stake - amount and delay any pending unstake is first cancelled.\"},\"balanceOf(address)\":{\"notice\":\"return the deposit (for gas payment) of the account\"},\"depositTo(address)\":{\"notice\":\"add to the deposit of the given account\"},\"deposits(address)\":{\"notice\":\"maps paymaster to their deposits and stakes\"},\"getNonce(address,uint192)\":{\"notice\":\"Return the next nonce for this sender. Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop) But UserOp with different keys can come with arbitrary order.\"},\"getSenderAddress(bytes)\":{\"notice\":\"Get counterfactual sender address. Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation. this method always revert, and returns the address in SenderAddressResult error\"},\"getUserOpHash((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"generate a request Id - unique identifier for this request. the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\"},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperation with Aggregators\"},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperations. no signature aggregator is used. if any account requires an aggregator (that is, it returned an aggregator when performing simulateValidation), then handleAggregatedOps() must be used instead.\"},\"incrementNonce(uint192)\":{\"notice\":\"Manually increment the nonce of the sender. This method is exposed just for completeness.. Account does NOT need to call it, neither during validation, nor elsewhere, as the EntryPoint will update the nonce regardless. Possible use-case is call it with various keys to \\\"initialize\\\" their nonces to one, so that future UserOperations will not pay extra for the first transaction with a given key.\"},\"innerHandleOp(bytes,((address,uint256,uint256,uint256,uint256,address,uint256,uint256),bytes32,uint256,uint256,uint256),bytes)\":{\"notice\":\"inner function to handle a UserOperation. Must be declared \\\"external\\\" to open a call context, but it can only be called by handleOps.\"},\"nonceSequenceNumber(address,uint192)\":{\"notice\":\"The next valid sequence number for a given nonce key.\"},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"notice\":\"simulate full execution of a UserOperation (including both validation and target execution) this method will always revert with \\\"ExecutionResult\\\". it performs full validation of the UserOperation, but ignores signature error. an optional target address is called after the userop succeeds, and its value is returned (before the entire call is reverted) Note that in order to collect the the success/failure of the target call, it must be executed with trace enabled to track the emitted events.\"},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\"},\"unlockStake()\":{\"notice\":\"attempt to unlock the stake. the value can be withdrawn (using withdrawStake) after the unstake delay.\"},\"withdrawStake(address)\":{\"notice\":\"withdraw from the (unlocked) stake. must first call unlockStake and wait for the unstakeDelay to pass\"},\"withdrawTo(address,uint256)\":{\"notice\":\"withdraw from the deposit.\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/core/EntryPoint.sol\":\"EntryPoint\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":1000000},\"remappings\":[],\"viaIR\":true},\"sources\":{\"@openzeppelin/contracts/security/ReentrancyGuard.sol\":{\"keccak256\":\"0x190dd6f8d592b7e4e930feb7f4313aeb8e1c4ad3154c27ce1cf6a512fc30d8cc\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://4ce8dfb62d0c4fa260d6eec8f1cd47f5f2a044e11bde5b31d18072fa6e7d9010\",\"dweb:/ipfs/QmTyFztU3tLEcEDnqqiaW4UJetqsU77LXc6pjc9oTXCK5u\"]},\"contracts/core/EntryPoint.sol\":{\"keccak256\":\"0x04f86318b47f052d7308795ffae6ecec0d023d2458b4e17751b89a0e4acfcdc6\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://c9f6e359c8dbe875ad974d3a0fb7b3d62319a6b115c44bac1e4587ae2ad2edaf\",\"dweb:/ipfs/QmTSWTov2rUeYk8cwzrtsd3uVXokCYok4gMiZ1sPs9tycH\"]},\"contracts/core/Helpers.sol\":{\"keccak256\":\"0x591c87519f7155d1909210276b77925ab2722a99b7b5d5649aecc36ebbdb045a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://69643e83f68e6a13d5075c7565bfce326673b0bd98c432033c4603ea84835746\",\"dweb:/ipfs/QmSwSzjYyV7qudi5vvsmzHMG2Z4YJZxX51RRXXVCLaNcEU\"]},\"contracts/core/NonceManager.sol\":{\"keccak256\":\"0xa17a4a6fde70088ab18ffe6df830f3efa31f1cd0e1a7160336c96e3c94984d25\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://b38615df9f80c56282b72888e9ba1eb1a9413fa67a0dbf094deda7af9feb38e7\",\"dweb:/ipfs/QmSzcXetEJRH4UHuUmZiSgX6bFgfqHWfmyuxVnh4NosMk1\"]},\"contracts/core/SenderCreator.sol\":{\"keccak256\":\"0x44b9449fec82d6cdfb01d52fdd5a72f90099c651316123810cf9633f00b018c2\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a9c0487390e72638681d175c45bc92425c802fffdca4bd0ae8457782ee284612\",\"dweb:/ipfs/QmVbzuehCUWJWqEHyMWuc6cRVbxfcMdFsmGL9o4Wz7WY2x\"]},\"contracts/core/StakeManager.sol\":{\"keccak256\":\"0x21aa0956382bd000b1b8c3b1d19ca6ebcd6c9029eebb19c612fb38ee5dd2430a\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://0a625c8795354d9f429367f9c1d14eb8af7db9c7f2c2a2033e2066ced76a573a\",\"dweb:/ipfs/Qmd1j6UarUg54q1G2HCNCLQz8XGVZR1qxX7eQ6cytHpQPN\"]},\"contracts/interfaces/IAccount.sol\":{\"keccak256\":\"0x556a0e5980de18e90b115553ed502408155ba35f58642823010d9288047bc418\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a0f420134b79596db8737173c7b933ae0a33059e107b6327c43aa40d4744a9e4\",\"dweb:/ipfs/QmRo8s1AhXmEMV7uPYnbpYwU19e9Bk6jmYBJTiPx3Fo85W\"]},\"contracts/interfaces/IAggregator.sol\":{\"keccak256\":\"0x060e9ddb0152250c269ba0640dc5753834ac44cf182a2837d508c0c529cae26a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://20ed837bc5909c89ff1910246bf245a5dad6840aa939382e1694964eb7dbd37b\",\"dweb:/ipfs/QmTMybRq5yyghPDDs1ZCNAVB9sSJ4WHe6Q9mejuKPTAdNP\"]},\"contracts/interfaces/IEntryPoint.sol\":{\"keccak256\":\"0x3a90bf308819ed125fa4202f880999caff8a8686633b8ddb79a30ca240d5b8f8\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://d2d21cc92c2fdab2b58d21bc25d4cd0e8c284b922528a186b087b818d54bc6cf\",\"dweb:/ipfs/QmT1qrfuBjsv2rmRCDn8mgPXHp94hARJwzbcDuBLDTbFWd\"]},\"contracts/interfaces/INonceManager.sol\":{\"keccak256\":\"0x509871e6c63663cdcc3eba19920fe84e991f38b289b1377ac3c3a6d9f22d7e12\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://00fe21b4349b24c50df60e1a705179293982bd9e7a32b78d4bac9620f89e7fe2\",\"dweb:/ipfs/QmSFFYGfUwQbVa6hASjU7YxTvgi2HkfrPr4X5oPHscHg8b\"]},\"contracts/interfaces/IPaymaster.sol\":{\"keccak256\":\"0x36858ba8685024974f533530420688da3454d29996ebc42e410673a1ed2ec456\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://616cbcf51778b1961b7f20a547bec7efae6d1d565df0f651926241ed8bde9ad8\",\"dweb:/ipfs/QmaVsgffUUmeUJYgStvRr8cNZ1LBbrc3FYNLW4JT1dVLia\"]},\"contracts/interfaces/IStakeManager.sol\":{\"keccak256\":\"0xd227b02888cd4ac68daebcdfd992ec00f9fff66fa3b3bb16f656cd582fa3480f\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://b389da4714a138be63704a576a482505eab2855e263b38a93706395d8d42e7c3\",\"dweb:/ipfs/QmeeAZpdHwUXxqP8pxA7GNtoCGBmmH4FaqLLwScVKGxtxZ\"]},\"contracts/interfaces/UserOperation.sol\":{\"keccak256\":\"0x61374003361059087fdcf17967a7bba052badeaf5c7f0ae689166f8aafd3a45c\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://6ff83c59432e733bf6304dda27cd4b0f34401917dd535e2669cc842d2d26568c\",\"dweb:/ipfs/QmPJbHU5TAjHqUTZzAcicEeG2nknmwCN43L4EW9LHbknTN\"]},\"contracts/utils/Exec.sol\":{\"keccak256\":\"0x5b232117afbc2939f3ffc92745614867e9e1d475a3e1e5443adae13c200174f1\",\"license\":\"LGPL-3.0-only\",\"urls\":[\"bzz-raw://62e7365379a06ead7b47637945bcaee095d51aab1d3ac00ddec69443e6cbe9fe\",\"dweb:/ipfs/QmctG3aw4U3KMSMeJKoLJ1NJewjMWfppnd1m3kxNTe39Uy\"]}},\"version\":1}", - "bytecode": "0x60a080604052346200008957600160025561022c8181016001600160401b038111838210176200007357829162005d18833903906000f080156200006757608052604051615c8990816200008f82396080518181816113df01528181613e9501526141b60152f35b6040513d6000823e3d90fd5b634e487b7160e01b600052604160045260246000fd5b600080fdfe60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c634300081100336080806040523461001657610210908161001c8239f35b600080fdfe6080604052600436101561001257600080fd5b6000803560e01c63570e1a361461002857600080fd5b346100c95760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126100c95760043567ffffffffffffffff918282116100c957366023830112156100c95781600401359283116100c95736602484840101116100c9576100c561009e84602485016100fc565b60405173ffffffffffffffffffffffffffffffffffffffff90911681529081906020820190565b0390f35b80fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b90806014116101bb5767ffffffffffffffff917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec82018381116101cd575b604051937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f81600b8701160116850190858210908211176101c0575b604052808452602084019036848401116101bb576020946000600c819682946014880187378301015251923560601c5af19060005191156101b557565b60009150565b600080fd5b6101c86100cc565b610178565b6101d56100cc565b61013a56fea26469706673582212201927e80b76ab9b71c952137dd676621a9fdf520c25928815636594036eb1c40364736f6c63430008110033", - "deployedBytecode": "0x60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c63430008110033" -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mumbai/solcInputs/a4c52f0671aad8941c53d6ead2063803.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mumbai/solcInputs/a4c52f0671aad8941c53d6ead2063803.json deleted file mode 100644 index dd58ba5a3e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/mumbai/solcInputs/a4c52f0671aad8941c53d6ead2063803.json +++ /dev/null @@ -1,68 +0,0 @@ -{ - "language": "Solidity", - "sources": { - "@openzeppelin/contracts/security/ReentrancyGuard.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (security/ReentrancyGuard.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Contract module that helps prevent reentrant calls to a function.\n *\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\n * available, which can be applied to functions to make sure there are no nested\n * (reentrant) calls to them.\n *\n * Note that because there is a single `nonReentrant` guard, functions marked as\n * `nonReentrant` may not call one another. This can be worked around by making\n * those functions `private`, and then adding `external` `nonReentrant` entry\n * points to them.\n *\n * TIP: If you would like to learn more about reentrancy and alternative ways\n * to protect against it, check out our blog post\n * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].\n */\nabstract contract ReentrancyGuard {\n // Booleans are more expensive than uint256 or any type that takes up a full\n // word because each write operation emits an extra SLOAD to first read the\n // slot's contents, replace the bits taken up by the boolean, and then write\n // back. This is the compiler's defense against contract upgrades and\n // pointer aliasing, and it cannot be disabled.\n\n // The values being non-zero value makes deployment a bit more expensive,\n // but in exchange the refund on every call to nonReentrant will be lower in\n // amount. Since refunds are capped to a percentage of the total\n // transaction's gas, it is best to keep them low in cases like this one, to\n // increase the likelihood of the full refund coming into effect.\n uint256 private constant _NOT_ENTERED = 1;\n uint256 private constant _ENTERED = 2;\n\n uint256 private _status;\n\n constructor() {\n _status = _NOT_ENTERED;\n }\n\n /**\n * @dev Prevents a contract from calling itself, directly or indirectly.\n * Calling a `nonReentrant` function from another `nonReentrant`\n * function is not supported. It is possible to prevent this from happening\n * by making the `nonReentrant` function external, and making it call a\n * `private` function that does the actual work.\n */\n modifier nonReentrant() {\n _nonReentrantBefore();\n _;\n _nonReentrantAfter();\n }\n\n function _nonReentrantBefore() private {\n // On the first call to nonReentrant, _status will be _NOT_ENTERED\n require(_status != _ENTERED, \"ReentrancyGuard: reentrant call\");\n\n // Any calls to nonReentrant after this point will fail\n _status = _ENTERED;\n }\n\n function _nonReentrantAfter() private {\n // By storing the original value once again, a refund is triggered (see\n // https://eips.ethereum.org/EIPS/eip-2200)\n _status = _NOT_ENTERED;\n }\n}\n" - }, - "contracts/core/EntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IPaymaster.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\n\nimport \"../utils/Exec.sol\";\nimport \"./StakeManager.sol\";\nimport \"./SenderCreator.sol\";\nimport \"./Helpers.sol\";\nimport \"./NonceManager.sol\";\nimport \"@openzeppelin/contracts/security/ReentrancyGuard.sol\";\n\ncontract EntryPoint is IEntryPoint, StakeManager, NonceManager, ReentrancyGuard {\n\n using UserOperationLib for UserOperation;\n\n SenderCreator private immutable senderCreator = new SenderCreator();\n\n // internal value used during simulation: need to query aggregator.\n address private constant SIMULATE_FIND_AGGREGATOR = address(1);\n\n // marker for inner call revert on out of gas\n bytes32 private constant INNER_OUT_OF_GAS = hex'deaddead';\n\n uint256 private constant REVERT_REASON_MAX_LEN = 2048;\n\n /**\n * for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value\n * in case of signature failure, instead of revert.\n */\n uint256 public constant SIG_VALIDATION_FAILED = 1;\n\n /**\n * compensate the caller's beneficiary address with the collected fees of all UserOperations.\n * @param beneficiary the address to receive the fees\n * @param amount amount to transfer.\n */\n function _compensate(address payable beneficiary, uint256 amount) internal {\n require(beneficiary != address(0), \"AA90 invalid beneficiary\");\n (bool success,) = beneficiary.call{value : amount}(\"\");\n require(success, \"AA91 failed send to beneficiary\");\n }\n\n /**\n * execute a user op\n * @param opIndex index into the opInfo array\n * @param userOp the userOp to execute\n * @param opInfo the opInfo filled by validatePrepayment for this userOp.\n * @return collected the total amount this userOp paid.\n */\n function _executeUserOp(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory opInfo) private returns (uint256 collected) {\n uint256 preGas = gasleft();\n bytes memory context = getMemoryBytesFromOffset(opInfo.contextOffset);\n\n try this.innerHandleOp(userOp.callData, opInfo, context) returns (uint256 _actualGasCost) {\n collected = _actualGasCost;\n } catch {\n bytes32 innerRevertCode;\n assembly {\n returndatacopy(0, 0, 32)\n innerRevertCode := mload(0)\n }\n // handleOps was called with gas limit too low. abort entire bundle.\n if (innerRevertCode == INNER_OUT_OF_GAS) {\n //report paymaster, since if it is not deliberately caused by the bundler,\n // it must be a revert caused by paymaster.\n revert FailedOp(opIndex, \"AA95 out of gas\");\n }\n\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n collected = _handlePostOp(opIndex, IPaymaster.PostOpMode.postOpReverted, opInfo, context, actualGas);\n }\n }\n\n /**\n * Execute a batch of UserOperations.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) public nonReentrant {\n\n uint256 opslen = ops.length;\n UserOpInfo[] memory opInfos = new UserOpInfo[](opslen);\n\n unchecked {\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[i];\n (uint256 validationData, uint256 pmValidationData) = _validatePrepayment(i, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, pmValidationData, address(0));\n }\n\n uint256 collected = 0;\n emit BeforeExecution();\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(i, ops[i], opInfos[i]);\n }\n\n _compensate(beneficiary, collected);\n } //unchecked\n }\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) public nonReentrant {\n\n uint256 opasLen = opsPerAggregator.length;\n uint256 totalOps = 0;\n for (uint256 i = 0; i < opasLen; i++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[i];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n //address(1) is special marker of \"signature error\"\n require(address(aggregator) != address(1), \"AA96 invalid aggregator\");\n\n if (address(aggregator) != address(0)) {\n // solhint-disable-next-line no-empty-blocks\n try aggregator.validateSignatures(ops, opa.signature) {}\n catch {\n revert SignatureValidationFailed(address(aggregator));\n }\n }\n\n totalOps += ops.length;\n }\n\n UserOpInfo[] memory opInfos = new UserOpInfo[](totalOps);\n\n emit BeforeExecution();\n\n uint256 opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n uint256 opslen = ops.length;\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[opIndex];\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(opIndex, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, paymasterValidationData, address(aggregator));\n opIndex++;\n }\n }\n\n uint256 collected = 0;\n opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n emit SignatureAggregatorChanged(address(opa.aggregator));\n UserOperation[] calldata ops = opa.userOps;\n uint256 opslen = ops.length;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(opIndex, ops[i], opInfos[opIndex]);\n opIndex++;\n }\n }\n emit SignatureAggregatorChanged(address(0));\n\n _compensate(beneficiary, collected);\n }\n\n /// @inheritdoc IEntryPoint\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external override {\n\n UserOpInfo memory opInfo;\n _simulationOnlyValidations(op);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, op, opInfo);\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n\n numberMarker();\n uint256 paid = _executeUserOp(0, op, opInfo);\n numberMarker();\n bool targetSuccess;\n bytes memory targetResult;\n if (target != address(0)) {\n (targetSuccess, targetResult) = target.call(targetCallData);\n }\n revert ExecutionResult(opInfo.preOpGas, paid, data.validAfter, data.validUntil, targetSuccess, targetResult);\n }\n\n\n // A memory copy of UserOp static fields only.\n // Excluding: callData, initCode and signature. Replacing paymasterAndData with paymaster.\n struct MemoryUserOp {\n address sender;\n uint256 nonce;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n address paymaster;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n }\n\n struct UserOpInfo {\n MemoryUserOp mUserOp;\n bytes32 userOpHash;\n uint256 prefund;\n uint256 contextOffset;\n uint256 preOpGas;\n }\n\n /**\n * inner function to handle a UserOperation.\n * Must be declared \"external\" to open a call context, but it can only be called by handleOps.\n */\n function innerHandleOp(bytes memory callData, UserOpInfo memory opInfo, bytes calldata context) external returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n require(msg.sender == address(this), \"AA92 internal call only\");\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n\n uint callGasLimit = mUserOp.callGasLimit;\n unchecked {\n // handleOps was called with gas limit too low. abort entire bundle.\n if (gasleft() < callGasLimit + mUserOp.verificationGasLimit + 5000) {\n assembly {\n mstore(0, INNER_OUT_OF_GAS)\n revert(0, 32)\n }\n }\n }\n\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\n if (callData.length > 0) {\n bool success = Exec.call(mUserOp.sender, 0, callData, callGasLimit);\n if (!success) {\n bytes memory result = Exec.getReturnData(REVERT_REASON_MAX_LEN);\n if (result.length > 0) {\n emit UserOperationRevertReason(opInfo.userOpHash, mUserOp.sender, mUserOp.nonce, result);\n }\n mode = IPaymaster.PostOpMode.opReverted;\n }\n }\n\n unchecked {\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n //note: opIndex is ignored (relevant only if mode==postOpReverted, which is only possible outside of innerHandleOp)\n return _handlePostOp(0, mode, opInfo, context, actualGas);\n }\n }\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) public view returns (bytes32) {\n return keccak256(abi.encode(userOp.hash(), address(this), block.chainid));\n }\n\n /**\n * copy general fields from userOp into the memory opInfo structure.\n */\n function _copyUserOpToMemory(UserOperation calldata userOp, MemoryUserOp memory mUserOp) internal pure {\n mUserOp.sender = userOp.sender;\n mUserOp.nonce = userOp.nonce;\n mUserOp.callGasLimit = userOp.callGasLimit;\n mUserOp.verificationGasLimit = userOp.verificationGasLimit;\n mUserOp.preVerificationGas = userOp.preVerificationGas;\n mUserOp.maxFeePerGas = userOp.maxFeePerGas;\n mUserOp.maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes calldata paymasterAndData = userOp.paymasterAndData;\n if (paymasterAndData.length > 0) {\n require(paymasterAndData.length >= 20, \"AA93 invalid paymasterAndData\");\n mUserOp.paymaster = address(bytes20(paymasterAndData[: 20]));\n } else {\n mUserOp.paymaster = address(0);\n }\n }\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external {\n UserOpInfo memory outOpInfo;\n\n _simulationOnlyValidations(userOp);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, userOp, outOpInfo);\n StakeInfo memory paymasterInfo = _getStakeInfo(outOpInfo.mUserOp.paymaster);\n StakeInfo memory senderInfo = _getStakeInfo(outOpInfo.mUserOp.sender);\n StakeInfo memory factoryInfo;\n {\n bytes calldata initCode = userOp.initCode;\n address factory = initCode.length >= 20 ? address(bytes20(initCode[0 : 20])) : address(0);\n factoryInfo = _getStakeInfo(factory);\n }\n\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n address aggregator = data.aggregator;\n bool sigFailed = aggregator == address(1);\n ReturnInfo memory returnInfo = ReturnInfo(outOpInfo.preOpGas, outOpInfo.prefund,\n sigFailed, data.validAfter, data.validUntil, getMemoryBytesFromOffset(outOpInfo.contextOffset));\n\n if (aggregator != address(0) && aggregator != address(1)) {\n AggregatorStakeInfo memory aggregatorInfo = AggregatorStakeInfo(aggregator, _getStakeInfo(aggregator));\n revert ValidationResultWithAggregation(returnInfo, senderInfo, factoryInfo, paymasterInfo, aggregatorInfo);\n }\n revert ValidationResult(returnInfo, senderInfo, factoryInfo, paymasterInfo);\n\n }\n\n function _getRequiredPrefund(MemoryUserOp memory mUserOp) internal pure returns (uint256 requiredPrefund) {\n unchecked {\n //when using a Paymaster, the verificationGasLimit is used also to as a limit for the postOp call.\n // our security model might call postOp eventually twice\n uint256 mul = mUserOp.paymaster != address(0) ? 3 : 1;\n uint256 requiredGas = mUserOp.callGasLimit + mUserOp.verificationGasLimit * mul + mUserOp.preVerificationGas;\n\n requiredPrefund = requiredGas * mUserOp.maxFeePerGas;\n }\n }\n\n // create the sender's contract if needed.\n function _createSenderIfNeeded(uint256 opIndex, UserOpInfo memory opInfo, bytes calldata initCode) internal {\n if (initCode.length != 0) {\n address sender = opInfo.mUserOp.sender;\n if (sender.code.length != 0) revert FailedOp(opIndex, \"AA10 sender already constructed\");\n address sender1 = senderCreator.createSender{gas : opInfo.mUserOp.verificationGasLimit}(initCode);\n if (sender1 == address(0)) revert FailedOp(opIndex, \"AA13 initCode failed or OOG\");\n if (sender1 != sender) revert FailedOp(opIndex, \"AA14 initCode must return sender\");\n if (sender1.code.length == 0) revert FailedOp(opIndex, \"AA15 initCode must create sender\");\n address factory = address(bytes20(initCode[0 : 20]));\n emit AccountDeployed(opInfo.userOpHash, sender, factory, opInfo.mUserOp.paymaster);\n }\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes calldata initCode) public {\n address sender = senderCreator.createSender(initCode);\n revert SenderAddressResult(sender);\n }\n\n function _simulationOnlyValidations(UserOperation calldata userOp) internal view {\n // solhint-disable-next-line no-empty-blocks\n try this._validateSenderAndPaymaster(userOp.initCode, userOp.sender, userOp.paymasterAndData) {}\n catch Error(string memory revertReason) {\n if (bytes(revertReason).length != 0) {\n revert FailedOp(0, revertReason);\n }\n }\n }\n\n /**\n * Called only during simulation.\n * This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\n */\n function _validateSenderAndPaymaster(bytes calldata initCode, address sender, bytes calldata paymasterAndData) external view {\n if (initCode.length == 0 && sender.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA20 account not deployed\");\n }\n if (paymasterAndData.length >= 20) {\n address paymaster = address(bytes20(paymasterAndData[0 : 20]));\n if (paymaster.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA30 paymaster not deployed\");\n }\n }\n // always revert\n revert(\"\");\n }\n\n /**\n * call account.validateUserOp.\n * revert (with FailedOp) in case validateUserOp reverts, or account didn't send required prefund.\n * decrement account's deposit if needed\n */\n function _validateAccountPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPrefund)\n internal returns (uint256 gasUsedByValidateAccountPrepayment, uint256 validationData) {\n unchecked {\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n address sender = mUserOp.sender;\n _createSenderIfNeeded(opIndex, opInfo, op.initCode);\n address paymaster = mUserOp.paymaster;\n numberMarker();\n uint256 missingAccountFunds = 0;\n if (paymaster == address(0)) {\n uint256 bal = balanceOf(sender);\n missingAccountFunds = bal > requiredPrefund ? 0 : requiredPrefund - bal;\n }\n try IAccount(sender).validateUserOp{gas : mUserOp.verificationGasLimit}(op, opInfo.userOpHash, missingAccountFunds)\n returns (uint256 _validationData) {\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA23 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA23 reverted (or OOG)\");\n }\n if (paymaster == address(0)) {\n DepositInfo storage senderInfo = deposits[sender];\n uint256 deposit = senderInfo.deposit;\n if (requiredPrefund > deposit) {\n revert FailedOp(opIndex, \"AA21 didn't pay prefund\");\n }\n senderInfo.deposit = uint112(deposit - requiredPrefund);\n }\n gasUsedByValidateAccountPrepayment = preGas - gasleft();\n }\n }\n\n /**\n * In case the request has a paymaster:\n * Validate paymaster has enough deposit.\n * Call paymaster.validatePaymasterUserOp.\n * Revert with proper FailedOp in case paymaster reverts.\n * Decrement paymaster's deposit\n */\n function _validatePaymasterPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPreFund, uint256 gasUsedByValidateAccountPrepayment)\n internal returns (bytes memory context, uint256 validationData) {\n unchecked {\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 verificationGasLimit = mUserOp.verificationGasLimit;\n require(verificationGasLimit > gasUsedByValidateAccountPrepayment, \"AA41 too little verificationGas\");\n uint256 gas = verificationGasLimit - gasUsedByValidateAccountPrepayment;\n\n address paymaster = mUserOp.paymaster;\n DepositInfo storage paymasterInfo = deposits[paymaster];\n uint256 deposit = paymasterInfo.deposit;\n if (deposit < requiredPreFund) {\n revert FailedOp(opIndex, \"AA31 paymaster deposit too low\");\n }\n paymasterInfo.deposit = uint112(deposit - requiredPreFund);\n try IPaymaster(paymaster).validatePaymasterUserOp{gas : gas}(op, opInfo.userOpHash, requiredPreFund) returns (bytes memory _context, uint256 _validationData){\n context = _context;\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA33 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA33 reverted (or OOG)\");\n }\n }\n }\n\n /**\n * revert if either account validationData or paymaster validationData is expired\n */\n function _validateAccountAndPaymasterValidationData(uint256 opIndex, uint256 validationData, uint256 paymasterValidationData, address expectedAggregator) internal view {\n (address aggregator, bool outOfTimeRange) = _getValidationData(validationData);\n if (expectedAggregator != aggregator) {\n revert FailedOp(opIndex, \"AA24 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA22 expired or not due\");\n }\n //pmAggregator is not a real signature aggregator: we don't have logic to handle it as address.\n // non-zero address means that the paymaster fails due to some signature check (which is ok only during estimation)\n address pmAggregator;\n (pmAggregator, outOfTimeRange) = _getValidationData(paymasterValidationData);\n if (pmAggregator != address(0)) {\n revert FailedOp(opIndex, \"AA34 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA32 paymaster expired or not due\");\n }\n }\n\n function _getValidationData(uint256 validationData) internal view returns (address aggregator, bool outOfTimeRange) {\n if (validationData == 0) {\n return (address(0), false);\n }\n ValidationData memory data = _parseValidationData(validationData);\n // solhint-disable-next-line not-rely-on-time\n outOfTimeRange = block.timestamp > data.validUntil || block.timestamp < data.validAfter;\n aggregator = data.aggregator;\n }\n\n /**\n * validate account and paymaster (if defined).\n * also make sure total validation doesn't exceed verificationGasLimit\n * this method is called off-chain (simulateValidation()) and on-chain (from handleOps)\n * @param opIndex the index of this userOp into the \"opInfos\" array\n * @param userOp the userOp to validate\n */\n function _validatePrepayment(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory outOpInfo)\n private returns (uint256 validationData, uint256 paymasterValidationData) {\n\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = outOpInfo.mUserOp;\n _copyUserOpToMemory(userOp, mUserOp);\n outOpInfo.userOpHash = getUserOpHash(userOp);\n\n // validate all numeric values in userOp are well below 128 bit, so they can safely be added\n // and multiplied without causing overflow\n uint256 maxGasValues = mUserOp.preVerificationGas | mUserOp.verificationGasLimit | mUserOp.callGasLimit |\n userOp.maxFeePerGas | userOp.maxPriorityFeePerGas;\n require(maxGasValues <= type(uint120).max, \"AA94 gas values overflow\");\n\n uint256 gasUsedByValidateAccountPrepayment;\n (uint256 requiredPreFund) = _getRequiredPrefund(mUserOp);\n (gasUsedByValidateAccountPrepayment, validationData) = _validateAccountPrepayment(opIndex, userOp, outOpInfo, requiredPreFund);\n\n if (!_validateAndUpdateNonce(mUserOp.sender, mUserOp.nonce)) {\n revert FailedOp(opIndex, \"AA25 invalid account nonce\");\n }\n\n //a \"marker\" where account opcode validation is done and paymaster opcode validation is about to start\n // (used only by off-chain simulateValidation)\n numberMarker();\n\n bytes memory context;\n if (mUserOp.paymaster != address(0)) {\n (context, paymasterValidationData) = _validatePaymasterPrepayment(opIndex, userOp, outOpInfo, requiredPreFund, gasUsedByValidateAccountPrepayment);\n }\n unchecked {\n uint256 gasUsed = preGas - gasleft();\n\n if (userOp.verificationGasLimit < gasUsed) {\n revert FailedOp(opIndex, \"AA40 over verificationGasLimit\");\n }\n outOpInfo.prefund = requiredPreFund;\n outOpInfo.contextOffset = getOffsetOfMemoryBytes(context);\n outOpInfo.preOpGas = preGas - gasleft() + userOp.preVerificationGas;\n }\n }\n\n /**\n * process post-operation.\n * called just after the callData is executed.\n * if a paymaster is defined and its validation returned a non-empty context, its postOp is called.\n * the excess amount is refunded to the account (or paymaster - if it was used in the request)\n * @param opIndex index in the batch\n * @param mode - whether is called from innerHandleOp, or outside (postOpReverted)\n * @param opInfo userOp fields and info collected during validation\n * @param context the context returned in validatePaymasterUserOp\n * @param actualGas the gas used so far by this user operation\n */\n function _handlePostOp(uint256 opIndex, IPaymaster.PostOpMode mode, UserOpInfo memory opInfo, bytes memory context, uint256 actualGas) private returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n unchecked {\n address refundAddress;\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 gasPrice = getUserOpGasPrice(mUserOp);\n\n address paymaster = mUserOp.paymaster;\n if (paymaster == address(0)) {\n refundAddress = mUserOp.sender;\n } else {\n refundAddress = paymaster;\n if (context.length > 0) {\n actualGasCost = actualGas * gasPrice;\n if (mode != IPaymaster.PostOpMode.postOpReverted) {\n IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost);\n } else {\n // solhint-disable-next-line no-empty-blocks\n try IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost) {}\n catch Error(string memory reason) {\n revert FailedOp(opIndex, string.concat(\"AA50 postOp reverted: \", reason));\n }\n catch {\n revert FailedOp(opIndex, \"AA50 postOp revert\");\n }\n }\n }\n }\n actualGas += preGas - gasleft();\n actualGasCost = actualGas * gasPrice;\n if (opInfo.prefund < actualGasCost) {\n revert FailedOp(opIndex, \"AA51 prefund below actualGasCost\");\n }\n uint256 refund = opInfo.prefund - actualGasCost;\n _incrementDeposit(refundAddress, refund);\n bool success = mode == IPaymaster.PostOpMode.opSucceeded;\n emit UserOperationEvent(opInfo.userOpHash, mUserOp.sender, mUserOp.paymaster, mUserOp.nonce, success, actualGasCost, actualGas);\n } // unchecked\n }\n\n /**\n * the gas price this UserOp agrees to pay.\n * relayer/block builder might submit the TX with higher priorityFee, but the user should not\n */\n function getUserOpGasPrice(MemoryUserOp memory mUserOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = mUserOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = mUserOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n\n function getOffsetOfMemoryBytes(bytes memory data) internal pure returns (uint256 offset) {\n assembly {offset := data}\n }\n\n function getMemoryBytesFromOffset(uint256 offset) internal pure returns (bytes memory data) {\n assembly {data := offset}\n }\n\n //place the NUMBER opcode in the code.\n // this is used as a marker during simulation, as this OP is completely banned from the simulated code of the\n // account and paymaster.\n function numberMarker() internal view {\n assembly {mstore(0, number())}\n }\n}\n\n" - }, - "contracts/core/Helpers.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\n/**\n * returned data from validateUserOp.\n * validateUserOp returns a uint256, with is created by `_packedValidationData` and parsed by `_parseValidationData`\n * @param aggregator - address(0) - the account validated the signature by itself.\n * address(1) - the account failed to validate the signature.\n * otherwise - this is an address of a signature aggregator that must be used to validate the signature.\n * @param validAfter - this UserOp is valid only after this timestamp.\n * @param validaUntil - this UserOp is valid only up to this timestamp.\n */\n struct ValidationData {\n address aggregator;\n uint48 validAfter;\n uint48 validUntil;\n }\n\n//extract sigFailed, validAfter, validUntil.\n// also convert zero validUntil to type(uint48).max\n function _parseValidationData(uint validationData) pure returns (ValidationData memory data) {\n address aggregator = address(uint160(validationData));\n uint48 validUntil = uint48(validationData >> 160);\n if (validUntil == 0) {\n validUntil = type(uint48).max;\n }\n uint48 validAfter = uint48(validationData >> (48 + 160));\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n// intersect account and paymaster ranges.\n function _intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) pure returns (ValidationData memory) {\n ValidationData memory accountValidationData = _parseValidationData(validationData);\n ValidationData memory pmValidationData = _parseValidationData(paymasterValidationData);\n address aggregator = accountValidationData.aggregator;\n if (aggregator == address(0)) {\n aggregator = pmValidationData.aggregator;\n }\n uint48 validAfter = accountValidationData.validAfter;\n uint48 validUntil = accountValidationData.validUntil;\n uint48 pmValidAfter = pmValidationData.validAfter;\n uint48 pmValidUntil = pmValidationData.validUntil;\n\n if (validAfter < pmValidAfter) validAfter = pmValidAfter;\n if (validUntil > pmValidUntil) validUntil = pmValidUntil;\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n/**\n * helper to pack the return value for validateUserOp\n * @param data - the ValidationData to pack\n */\n function _packValidationData(ValidationData memory data) pure returns (uint256) {\n return uint160(data.aggregator) | (uint256(data.validUntil) << 160) | (uint256(data.validAfter) << (160 + 48));\n }\n\n/**\n * helper to pack the return value for validateUserOp, when not using an aggregator\n * @param sigFailed - true for signature failure, false for success\n * @param validUntil last timestamp this UserOperation is valid (or zero for infinite)\n * @param validAfter first timestamp this UserOperation is valid\n */\n function _packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) pure returns (uint256) {\n return (sigFailed ? 1 : 0) | (uint256(validUntil) << 160) | (uint256(validAfter) << (160 + 48));\n }\n\n/**\n * keccak function over calldata.\n * @dev copy calldata into memory, do keccak and drop allocated memory. Strangely, this is more efficient than letting solidity do it.\n */\n function calldataKeccak(bytes calldata data) pure returns (bytes32 ret) {\n assembly {\n let mem := mload(0x40)\n let len := data.length\n calldatacopy(mem, data.offset, len)\n ret := keccak256(mem, len)\n }\n }\n\n" - }, - "contracts/core/NonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IEntryPoint.sol\";\n\n/**\n * nonce management functionality\n */\ncontract NonceManager is INonceManager {\n\n /**\n * The next valid sequence number for a given nonce key.\n */\n mapping(address => mapping(uint192 => uint256)) public nonceSequenceNumber;\n\n function getNonce(address sender, uint192 key)\n public view override returns (uint256 nonce) {\n return nonceSequenceNumber[sender][key] | (uint256(key) << 64);\n }\n\n // allow an account to manually increment its own nonce.\n // (mainly so that during construction nonce can be made non-zero,\n // to \"absorb\" the gas cost of first nonce increment to 1st transaction (construction),\n // not to 2nd transaction)\n function incrementNonce(uint192 key) public override {\n nonceSequenceNumber[msg.sender][key]++;\n }\n\n /**\n * validate nonce uniqueness for this account.\n * called just after validateUserOp()\n */\n function _validateAndUpdateNonce(address sender, uint256 nonce) internal returns (bool) {\n\n uint192 key = uint192(nonce >> 64);\n uint64 seq = uint64(nonce);\n return nonceSequenceNumber[sender][key]++ == seq;\n }\n\n}\n" - }, - "contracts/core/SenderCreator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * helper contract for EntryPoint, to call userOp.initCode from a \"neutral\" address,\n * which is explicitly not the entryPoint itself.\n */\ncontract SenderCreator {\n\n /**\n * call the \"initCode\" factory to create and return the sender account address\n * @param initCode the initCode value from a UserOp. contains 20 bytes of factory address, followed by calldata\n * @return sender the returned address of the created account, or zero address on failure.\n */\n function createSender(bytes calldata initCode) external returns (address sender) {\n address factory = address(bytes20(initCode[0 : 20]));\n bytes memory initCallData = initCode[20 :];\n bool success;\n /* solhint-disable no-inline-assembly */\n assembly {\n success := call(gas(), factory, 0, add(initCallData, 0x20), mload(initCallData), 0, 32)\n sender := mload(0)\n }\n if (!success) {\n sender = address(0);\n }\n }\n}\n" - }, - "contracts/core/StakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IStakeManager.sol\";\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable not-rely-on-time */\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by a paymaster.\n */\nabstract contract StakeManager is IStakeManager {\n\n /// maps paymaster to their deposits and stakes\n mapping(address => DepositInfo) public deposits;\n\n /// @inheritdoc IStakeManager\n function getDepositInfo(address account) public view returns (DepositInfo memory info) {\n return deposits[account];\n }\n\n // internal method to return just the stake info\n function _getStakeInfo(address addr) internal view returns (StakeInfo memory info) {\n DepositInfo storage depositInfo = deposits[addr];\n info.stake = depositInfo.stake;\n info.unstakeDelaySec = depositInfo.unstakeDelaySec;\n }\n\n /// return the deposit (for gas payment) of the account\n function balanceOf(address account) public view returns (uint256) {\n return deposits[account].deposit;\n }\n\n receive() external payable {\n depositTo(msg.sender);\n }\n\n function _incrementDeposit(address account, uint256 amount) internal {\n DepositInfo storage info = deposits[account];\n uint256 newAmount = info.deposit + amount;\n require(newAmount <= type(uint112).max, \"deposit overflow\");\n info.deposit = uint112(newAmount);\n }\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) public payable {\n _incrementDeposit(account, msg.value);\n DepositInfo storage info = deposits[account];\n emit Deposited(account, info.deposit);\n }\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 unstakeDelaySec) public payable {\n DepositInfo storage info = deposits[msg.sender];\n require(unstakeDelaySec > 0, \"must specify unstake delay\");\n require(unstakeDelaySec >= info.unstakeDelaySec, \"cannot decrease unstake time\");\n uint256 stake = info.stake + msg.value;\n require(stake > 0, \"no stake specified\");\n require(stake <= type(uint112).max, \"stake overflow\");\n deposits[msg.sender] = DepositInfo(\n info.deposit,\n true,\n uint112(stake),\n unstakeDelaySec,\n 0\n );\n emit StakeLocked(msg.sender, stake, unstakeDelaySec);\n }\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external {\n DepositInfo storage info = deposits[msg.sender];\n require(info.unstakeDelaySec != 0, \"not staked\");\n require(info.staked, \"already unstaking\");\n uint48 withdrawTime = uint48(block.timestamp) + info.unstakeDelaySec;\n info.withdrawTime = withdrawTime;\n info.staked = false;\n emit StakeUnlocked(msg.sender, withdrawTime);\n }\n\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external {\n DepositInfo storage info = deposits[msg.sender];\n uint256 stake = info.stake;\n require(stake > 0, \"No stake to withdraw\");\n require(info.withdrawTime > 0, \"must call unlockStake() first\");\n require(info.withdrawTime <= block.timestamp, \"Stake withdrawal is not due\");\n info.unstakeDelaySec = 0;\n info.withdrawTime = 0;\n info.stake = 0;\n emit StakeWithdrawn(msg.sender, withdrawAddress, stake);\n (bool success,) = withdrawAddress.call{value : stake}(\"\");\n require(success, \"failed to withdraw stake\");\n }\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external {\n DepositInfo storage info = deposits[msg.sender];\n require(withdrawAmount <= info.deposit, \"Withdraw amount too large\");\n info.deposit = uint112(info.deposit - withdrawAmount);\n emit Withdrawn(msg.sender, withdrawAddress, withdrawAmount);\n (bool success,) = withdrawAddress.call{value : withdrawAmount}(\"\");\n require(success, \"failed to withdraw\");\n }\n}\n" - }, - "contracts/interfaces/IAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\ninterface IAccount {\n\n /**\n * Validate user's signature and nonce\n * the entryPoint will make the call to the recipient only if this validation call returns successfully.\n * signature failure should be reported by returning SIG_VALIDATION_FAILED (1).\n * This allows making a \"simulation call\" without a valid signature\n * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure.\n *\n * @dev Must validate caller is the entryPoint.\n * Must validate the signature and nonce\n * @param userOp the operation that is about to be executed.\n * @param userOpHash hash of the user's request data. can be used as the basis for signature.\n * @param missingAccountFunds missing funds on the account's deposit in the entrypoint.\n * This is the minimum amount to transfer to the sender(entryPoint) to be able to make the call.\n * The excess is left as a deposit in the entrypoint, for future calls.\n * can be withdrawn anytime using \"entryPoint.withdrawTo()\"\n * In case there is a paymaster in the request (or the current deposit is high enough), this value will be zero.\n * @return validationData packaged ValidationData structure. use `_packValidationData` and `_unpackValidationData` to encode and decode\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * If an account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external returns (uint256 validationData);\n}\n" - }, - "contracts/interfaces/IAggregator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * Aggregated Signatures validator.\n */\ninterface IAggregator {\n\n /**\n * validate aggregated signature.\n * revert if the aggregated signature does not match the given list of operations.\n */\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external view;\n\n /**\n * validate signature of a single userOp\n * This method is should be called by bundler after EntryPoint.simulateValidation() returns (reverts) with ValidationResultWithAggregation\n * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps.\n * @param userOp the userOperation received from the user.\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\n * (usually empty, unless account and aggregator support some kind of \"multisig\"\n */\n function validateUserOpSignature(UserOperation calldata userOp)\n external view returns (bytes memory sigForUserOp);\n\n /**\n * aggregate multiple signatures into a single value.\n * This method is called off-chain to calculate the signature to pass with handleOps()\n * bundler MAY use optimized custom code perform this aggregation\n * @param userOps array of UserOperations to collect the signatures from.\n * @return aggregatedSignature the aggregated signature\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external view returns (bytes memory aggregatedSignature);\n}\n" - }, - "contracts/interfaces/IEntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"./UserOperation.sol\";\nimport \"./IStakeManager.sol\";\nimport \"./IAggregator.sol\";\nimport \"./INonceManager.sol\";\n\ninterface IEntryPoint is IStakeManager, INonceManager {\n\n /***\n * An event emitted after each successful request\n * @param userOpHash - unique identifier for the request (hash its entire content, except signature).\n * @param sender - the account that generates this request.\n * @param paymaster - if non-null, the paymaster that pays for this request.\n * @param nonce - the nonce value from the request.\n * @param success - true if the sender transaction succeeded, false if reverted.\n * @param actualGasCost - actual amount paid (by account or paymaster) for this UserOperation.\n * @param actualGasUsed - total gas used by this UserOperation (including preVerification, creation, validation and execution).\n */\n event UserOperationEvent(bytes32 indexed userOpHash, address indexed sender, address indexed paymaster, uint256 nonce, bool success, uint256 actualGasCost, uint256 actualGasUsed);\n\n /**\n * account \"sender\" was deployed.\n * @param userOpHash the userOp that deployed this account. UserOperationEvent will follow.\n * @param sender the account that is deployed\n * @param factory the factory used to deploy this account (in the initCode)\n * @param paymaster the paymaster used by this UserOp\n */\n event AccountDeployed(bytes32 indexed userOpHash, address indexed sender, address factory, address paymaster);\n\n /**\n * An event emitted if the UserOperation \"callData\" reverted with non-zero length\n * @param userOpHash the request unique identifier.\n * @param sender the sender of this request\n * @param nonce the nonce used in the request\n * @param revertReason - the return bytes from the (reverted) call to \"callData\".\n */\n event UserOperationRevertReason(bytes32 indexed userOpHash, address indexed sender, uint256 nonce, bytes revertReason);\n\n /**\n * an event emitted by handleOps(), before starting the execution loop.\n * any event emitted before this event, is part of the validation.\n */\n event BeforeExecution();\n\n /**\n * signature aggregator used by the following UserOperationEvents within this bundle.\n */\n event SignatureAggregatorChanged(address indexed aggregator);\n\n /**\n * a custom revert error of handleOps, to identify the offending op.\n * NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\n * @param opIndex - index into the array of ops to the failed one (in simulateValidation, this is always zero)\n * @param reason - revert reason\n * The string starts with a unique code \"AAmn\", where \"m\" is \"1\" for factory, \"2\" for account and \"3\" for paymaster issues,\n * so a failure can be attributed to the correct entity.\n * Should be caught in off-chain handleOps simulation and not happen on-chain.\n * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\n */\n error FailedOp(uint256 opIndex, string reason);\n\n /**\n * error case when a signature aggregator fails to verify the aggregated signature it had created.\n */\n error SignatureValidationFailed(address aggregator);\n\n /**\n * Successful result from simulateValidation.\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n */\n error ValidationResult(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo);\n\n /**\n * Successful result from simulateValidation, if the account returns a signature aggregator\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n * @param aggregatorInfo signature aggregation info (if the account requires signature aggregator)\n * bundler MUST use it to verify the signature, or reject the UserOperation\n */\n error ValidationResultWithAggregation(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo,\n AggregatorStakeInfo aggregatorInfo);\n\n /**\n * return value of getSenderAddress\n */\n error SenderAddressResult(address sender);\n\n /**\n * return value of simulateHandleOp\n */\n error ExecutionResult(uint256 preOpGas, uint256 paid, uint48 validAfter, uint48 validUntil, bool targetSuccess, bytes targetResult);\n\n //UserOps handled, per aggregator\n struct UserOpsPerAggregator {\n UserOperation[] userOps;\n\n // aggregator address\n IAggregator aggregator;\n // aggregated signature\n bytes signature;\n }\n\n /**\n * Execute a batch of UserOperation.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) external;\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) external;\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) external view returns (bytes32);\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external;\n\n /**\n * gas and return values during simulation\n * @param preOpGas the gas used for validation (including preValidationGas)\n * @param prefund the required prefund for this operation\n * @param sigFailed validateUserOp's (or paymaster's) signature check failed\n * @param validAfter - first timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param validUntil - last timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param paymasterContext returned by validatePaymasterUserOp (to be passed into postOp)\n */\n struct ReturnInfo {\n uint256 preOpGas;\n uint256 prefund;\n bool sigFailed;\n uint48 validAfter;\n uint48 validUntil;\n bytes paymasterContext;\n }\n\n /**\n * returned aggregated signature info.\n * the aggregator returned by the account, and its current stake.\n */\n struct AggregatorStakeInfo {\n address aggregator;\n StakeInfo stakeInfo;\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes memory initCode) external;\n\n\n /**\n * simulate full execution of a UserOperation (including both validation and target execution)\n * this method will always revert with \"ExecutionResult\".\n * it performs full validation of the UserOperation, but ignores signature error.\n * an optional target address is called after the userop succeeds, and its value is returned\n * (before the entire call is reverted)\n * Note that in order to collect the the success/failure of the target call, it must be executed\n * with trace enabled to track the emitted events.\n * @param op the UserOperation to simulate\n * @param target if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult\n * are set to the return from that call.\n * @param targetCallData callData to pass to target address\n */\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external;\n}\n\n" - }, - "contracts/interfaces/INonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\ninterface INonceManager {\n\n /**\n * Return the next nonce for this sender.\n * Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop)\n * But UserOp with different keys can come with arbitrary order.\n *\n * @param sender the account address\n * @param key the high 192 bit of the nonce\n * @return nonce a full nonce to pass for next UserOp with this sender.\n */\n function getNonce(address sender, uint192 key)\n external view returns (uint256 nonce);\n\n /**\n * Manually increment the nonce of the sender.\n * This method is exposed just for completeness..\n * Account does NOT need to call it, neither during validation, nor elsewhere,\n * as the EntryPoint will update the nonce regardless.\n * Possible use-case is call it with various keys to \"initialize\" their nonces to one, so that future\n * UserOperations will not pay extra for the first transaction with a given key.\n */\n function incrementNonce(uint192 key) external;\n}\n" - }, - "contracts/interfaces/IPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * the interface exposed by a paymaster contract, who agrees to pay the gas for user's operations.\n * a paymaster must hold a stake to cover the required entrypoint stake and also the gas for the transaction.\n */\ninterface IPaymaster {\n\n enum PostOpMode {\n opSucceeded, // user op succeeded\n opReverted, // user op reverted. still has to pay for gas.\n postOpReverted //user op succeeded, but caused postOp to revert. Now it's a 2nd call, after user's op was deliberately reverted.\n }\n\n /**\n * payment validation: check if paymaster agrees to pay.\n * Must verify sender is the entryPoint.\n * Revert to reject this request.\n * Note that bundlers will reject this method if it changes the state, unless the paymaster is trusted (whitelisted)\n * The paymaster pre-pays using its deposit, and receive back a refund after the postOp method returns.\n * @param userOp the user operation\n * @param userOpHash hash of the user's request data.\n * @param maxCost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\n * @return context value to send to a postOp\n * zero length to signify postOp is not required.\n * @return validationData signature and time-range of this operation, encoded the same as the return value of validateUserOperation\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n external returns (bytes memory context, uint256 validationData);\n\n /**\n * post-operation handler.\n * Must verify sender is the entryPoint\n * @param mode enum with the following options:\n * opSucceeded - user operation succeeded.\n * opReverted - user op reverted. still has to pay for gas.\n * postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n * Now this is the 2nd call, after user's op was deliberately reverted.\n * @param context - the context value returned by validatePaymasterUserOp\n * @param actualGasCost - actual gas used so far (without this postOp call).\n */\n function postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) external;\n}\n" - }, - "contracts/interfaces/IStakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by the staked entity.\n */\ninterface IStakeManager {\n\n event Deposited(\n address indexed account,\n uint256 totalDeposit\n );\n\n event Withdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /// Emitted when stake or unstake delay are modified\n event StakeLocked(\n address indexed account,\n uint256 totalStaked,\n uint256 unstakeDelaySec\n );\n\n /// Emitted once a stake is scheduled for withdrawal\n event StakeUnlocked(\n address indexed account,\n uint256 withdrawTime\n );\n\n event StakeWithdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /**\n * @param deposit the entity's deposit\n * @param staked true if this entity is staked.\n * @param stake actual amount of ether staked for this entity.\n * @param unstakeDelaySec minimum delay to withdraw the stake.\n * @param withdrawTime - first block timestamp where 'withdrawStake' will be callable, or zero if already locked\n * @dev sizes were chosen so that (deposit,staked, stake) fit into one cell (used during handleOps)\n * and the rest fit into a 2nd cell.\n * 112 bit allows for 10^15 eth\n * 48 bit for full timestamp\n * 32 bit allows 150 years for unstake delay\n */\n struct DepositInfo {\n uint112 deposit;\n bool staked;\n uint112 stake;\n uint32 unstakeDelaySec;\n uint48 withdrawTime;\n }\n\n //API struct used by getStakeInfo and simulateValidation\n struct StakeInfo {\n uint256 stake;\n uint256 unstakeDelaySec;\n }\n\n /// @return info - full deposit information of given account\n function getDepositInfo(address account) external view returns (DepositInfo memory info);\n\n /// @return the deposit (for gas payment) of the account\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) external payable;\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param _unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 _unstakeDelaySec) external payable;\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external;\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external;\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external;\n}\n" - }, - "contracts/interfaces/UserOperation.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\nimport {calldataKeccak} from \"../core/Helpers.sol\";\n\n/**\n * User Operation struct\n * @param sender the sender account of this request.\n * @param nonce unique value the sender uses to verify it is not a replay.\n * @param initCode if set, the account contract will be created by this constructor/\n * @param callData the method call to execute on this account.\n * @param callGasLimit the gas limit passed to the callData method call.\n * @param verificationGasLimit gas used for validateUserOp and validatePaymasterUserOp.\n * @param preVerificationGas gas not calculated by the handleOps method, but added to the gas paid. Covers batch overhead.\n * @param maxFeePerGas same as EIP-1559 gas parameter.\n * @param maxPriorityFeePerGas same as EIP-1559 gas parameter.\n * @param paymasterAndData if set, this field holds the paymaster address and paymaster-specific data. the paymaster will pay for the transaction instead of the sender.\n * @param signature sender-verified signature over the entire request, the EntryPoint address and the chain ID.\n */\n struct UserOperation {\n\n address sender;\n uint256 nonce;\n bytes initCode;\n bytes callData;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n bytes paymasterAndData;\n bytes signature;\n }\n\n/**\n * Utility functions helpful when working with UserOperation structs.\n */\nlibrary UserOperationLib {\n\n function getSender(UserOperation calldata userOp) internal pure returns (address) {\n address data;\n //read sender from userOp, which is first userOp member (saves 800 gas...)\n assembly {data := calldataload(userOp)}\n return address(uint160(data));\n }\n\n //relayer/block builder might submit the TX with higher priorityFee, but the user should not\n // pay above what he signed for.\n function gasPrice(UserOperation calldata userOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n address sender = getSender(userOp);\n uint256 nonce = userOp.nonce;\n bytes32 hashInitCode = calldataKeccak(userOp.initCode);\n bytes32 hashCallData = calldataKeccak(userOp.callData);\n uint256 callGasLimit = userOp.callGasLimit;\n uint256 verificationGasLimit = userOp.verificationGasLimit;\n uint256 preVerificationGas = userOp.preVerificationGas;\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes32 hashPaymasterAndData = calldataKeccak(userOp.paymasterAndData);\n\n return abi.encode(\n sender, nonce,\n hashInitCode, hashCallData,\n callGasLimit, verificationGasLimit, preVerificationGas,\n maxFeePerGas, maxPriorityFeePerGas,\n hashPaymasterAndData\n );\n }\n\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\n return keccak256(pack(userOp));\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n}\n" - }, - "contracts/utils/Exec.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.5 <0.9.0;\n\n// solhint-disable no-inline-assembly\n\n/**\n * Utility functions helpful when making different kinds of contract calls in Solidity.\n */\nlibrary Exec {\n\n function call(\n address to,\n uint256 value,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function staticcall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal view returns (bool success) {\n assembly {\n success := staticcall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function delegateCall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n // get returned data from last call or calldelegate\n function getReturnData(uint256 maxLen) internal pure returns (bytes memory returnData) {\n assembly {\n let len := returndatasize()\n if gt(len, maxLen) {\n len := maxLen\n }\n let ptr := mload(0x40)\n mstore(0x40, add(ptr, add(len, 0x20)))\n mstore(ptr, len)\n returndatacopy(add(ptr, 0x20), 0, len)\n returnData := ptr\n }\n }\n\n // revert with explicit byte array (probably reverted info from call)\n function revertWithData(bytes memory returnData) internal pure {\n assembly {\n revert(add(returnData, 32), mload(returnData))\n }\n }\n\n function callAndRevert(address to, bytes memory data, uint256 maxLen) internal {\n bool success = call(to,0,data,gasleft());\n if (!success) {\n revertWithData(getReturnData(maxLen));\n }\n }\n}\n" - } - }, - "settings": { - "optimizer": { - "enabled": true, - "runs": 1000000 - }, - "viaIR": true, - "outputSelection": { - "*": { - "*": [ - "abi", - "evm.bytecode", - "evm.deployedBytecode", - "evm.methodIdentifiers", - "metadata" - ], - "": [ - "ast" - ] - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/optimism/.chainId b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/optimism/.chainId deleted file mode 100644 index 9a037142aa..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/optimism/.chainId +++ /dev/null @@ -1 +0,0 @@ -10 \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/optimism/EntryPoint.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/optimism/EntryPoint.json deleted file mode 100644 index 916c239083..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/optimism/EntryPoint.json +++ /dev/null @@ -1,1318 +0,0 @@ -{ - "address": "0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789", - "abi": [ - { - "inputs": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "paid", - "type": "uint256" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bool", - "name": "targetSuccess", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "targetResult", - "type": "bytes" - } - ], - "name": "ExecutionResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "opIndex", - "type": "uint256" - }, - { - "internalType": "string", - "name": "reason", - "type": "string" - } - ], - "name": "FailedOp", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - } - ], - "name": "SenderAddressResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureValidationFailed", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - } - ], - "name": "ValidationResult", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "stakeInfo", - "type": "tuple" - } - ], - "internalType": "struct IEntryPoint.AggregatorStakeInfo", - "name": "aggregatorInfo", - "type": "tuple" - } - ], - "name": "ValidationResultWithAggregation", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "factory", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "paymaster", - "type": "address" - } - ], - "name": "AccountDeployed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [], - "name": "BeforeExecution", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalDeposit", - "type": "uint256" - } - ], - "name": "Deposited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureAggregatorChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalStaked", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "name": "StakeLocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "withdrawTime", - "type": "uint256" - } - ], - "name": "StakeUnlocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "StakeWithdrawn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasUsed", - "type": "uint256" - } - ], - "name": "UserOperationEvent", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "revertReason", - "type": "bytes" - } - ], - "name": "UserOperationRevertReason", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "Withdrawn", - "type": "event" - }, - { - "inputs": [], - "name": "SIG_VALIDATION_FAILED", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - } - ], - "name": "_validateSenderAndPaymaster", - "outputs": [], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - } - ], - "name": "addStake", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "depositTo", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "deposits", - "outputs": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "getDepositInfo", - "outputs": [ - { - "components": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "internalType": "struct IStakeManager.DepositInfo", - "name": "info", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "getNonce", - "outputs": [ - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - } - ], - "name": "getSenderAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "getUserOpHash", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "userOps", - "type": "tuple[]" - }, - { - "internalType": "contract IAggregator", - "name": "aggregator", - "type": "address" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.UserOpsPerAggregator[]", - "name": "opsPerAggregator", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleAggregatedOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "ops", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "incrementNonce", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.MemoryUserOp", - "name": "mUserOp", - "type": "tuple" - }, - { - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "contextOffset", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.UserOpInfo", - "name": "opInfo", - "type": "tuple" - }, - { - "internalType": "bytes", - "name": "context", - "type": "bytes" - } - ], - "name": "innerHandleOp", - "outputs": [ - { - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - }, - { - "internalType": "uint192", - "name": "", - "type": "uint192" - } - ], - "name": "nonceSequenceNumber", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "op", - "type": "tuple" - }, - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "targetCallData", - "type": "bytes" - } - ], - "name": "simulateHandleOp", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "simulateValidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unlockStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - } - ], - "name": "withdrawStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "withdrawAmount", - "type": "uint256" - } - ], - "name": "withdrawTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "args": [], - "numDeployments": 1, - "solcInputHash": "a4c52f0671aad8941c53d6ead2063803", - "metadata": "{\"compiler\":{\"version\":\"0.8.17+commit.8df45f5f\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"paid\",\"type\":\"uint256\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bool\",\"name\":\"targetSuccess\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"targetResult\",\"type\":\"bytes\"}],\"name\":\"ExecutionResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"opIndex\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\"}],\"name\":\"FailedOp\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderAddressResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureValidationFailed\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResult\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"stakeInfo\",\"type\":\"tuple\"}],\"internalType\":\"struct IEntryPoint.AggregatorStakeInfo\",\"name\":\"aggregatorInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResultWithAggregation\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"factory\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"}],\"name\":\"AccountDeployed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"BeforeExecution\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalDeposit\",\"type\":\"uint256\"}],\"name\":\"Deposited\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureAggregatorChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalStaked\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"name\":\"StakeLocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"withdrawTime\",\"type\":\"uint256\"}],\"name\":\"StakeUnlocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"StakeWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasUsed\",\"type\":\"uint256\"}],\"name\":\"UserOperationEvent\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"revertReason\",\"type\":\"bytes\"}],\"name\":\"UserOperationRevertReason\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Withdrawn\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"SIG_VALIDATION_FAILED\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"}],\"name\":\"_validateSenderAndPaymaster\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"}],\"name\":\"addStake\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"depositTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"deposits\",\"outputs\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getDepositInfo\",\"outputs\":[{\"components\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"internalType\":\"struct IStakeManager.DepositInfo\",\"name\":\"info\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"}],\"name\":\"getSenderAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"getUserOpHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"userOps\",\"type\":\"tuple[]\"},{\"internalType\":\"contract IAggregator\",\"name\":\"aggregator\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.UserOpsPerAggregator[]\",\"name\":\"opsPerAggregator\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleAggregatedOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"ops\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"incrementNonce\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.MemoryUserOp\",\"name\":\"mUserOp\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"contextOffset\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.UserOpInfo\",\"name\":\"opInfo\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"context\",\"type\":\"bytes\"}],\"name\":\"innerHandleOp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"\",\"type\":\"uint192\"}],\"name\":\"nonceSequenceNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"op\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"targetCallData\",\"type\":\"bytes\"}],\"name\":\"simulateHandleOp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"simulateValidation\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unlockStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"}],\"name\":\"withdrawStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"withdrawAmount\",\"type\":\"uint256\"}],\"name\":\"withdrawTo\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"errors\":{\"FailedOp(uint256,string)\":[{\"params\":{\"opIndex\":\"- index into the array of ops to the failed one (in simulateValidation, this is always zero)\",\"reason\":\"- revert reason The string starts with a unique code \\\"AAmn\\\", where \\\"m\\\" is \\\"1\\\" for factory, \\\"2\\\" for account and \\\"3\\\" for paymaster issues, so a failure can be attributed to the correct entity. Should be caught in off-chain handleOps simulation and not happen on-chain. Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\"}}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"params\":{\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"params\":{\"aggregatorInfo\":\"signature aggregation info (if the account requires signature aggregator) bundler MUST use it to verify the signature, or reject the UserOperation\",\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}]},\"kind\":\"dev\",\"methods\":{\"addStake(uint32)\":{\"params\":{\"unstakeDelaySec\":\"the new lock duration before the deposit can be withdrawn.\"}},\"getDepositInfo(address)\":{\"returns\":{\"info\":\"- full deposit information of given account\"}},\"getNonce(address,uint192)\":{\"params\":{\"key\":\"the high 192 bit of the nonce\",\"sender\":\"the account address\"},\"returns\":{\"nonce\":\"a full nonce to pass for next UserOp with this sender.\"}},\"getSenderAddress(bytes)\":{\"params\":{\"initCode\":\"the constructor code to be passed into the UserOperation.\"}},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"opsPerAggregator\":\"the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\"}},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"ops\":\"the operations to execute\"}},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"params\":{\"op\":\"the UserOperation to simulate\",\"target\":\"if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult are set to the return from that call.\",\"targetCallData\":\"callData to pass to target address\"}},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"details\":\"this method always revert. Successful result is ValidationResult error. other errors are failures.The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\",\"params\":{\"userOp\":\"the user operation to validate.\"}},\"withdrawStake(address)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\"}},\"withdrawTo(address,uint256)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\",\"withdrawAmount\":\"the amount to withdraw.\"}}},\"version\":1},\"userdoc\":{\"errors\":{\"ExecutionResult(uint256,uint256,uint48,uint48,bool,bytes)\":[{\"notice\":\"return value of simulateHandleOp\"}],\"FailedOp(uint256,string)\":[{\"notice\":\"a custom revert error of handleOps, to identify the offending op. NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\"}],\"SenderAddressResult(address)\":[{\"notice\":\"return value of getSenderAddress\"}],\"SignatureValidationFailed(address)\":[{\"notice\":\"error case when a signature aggregator fails to verify the aggregated signature it had created.\"}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"notice\":\"Successful result from simulateValidation.\"}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"notice\":\"Successful result from simulateValidation, if the account returns a signature aggregator\"}]},\"events\":{\"AccountDeployed(bytes32,address,address,address)\":{\"notice\":\"account \\\"sender\\\" was deployed.\"},\"BeforeExecution()\":{\"notice\":\"an event emitted by handleOps(), before starting the execution loop. any event emitted before this event, is part of the validation.\"},\"SignatureAggregatorChanged(address)\":{\"notice\":\"signature aggregator used by the following UserOperationEvents within this bundle.\"},\"StakeLocked(address,uint256,uint256)\":{\"notice\":\"Emitted when stake or unstake delay are modified\"},\"StakeUnlocked(address,uint256)\":{\"notice\":\"Emitted once a stake is scheduled for withdrawal\"},\"UserOperationRevertReason(bytes32,address,uint256,bytes)\":{\"notice\":\"An event emitted if the UserOperation \\\"callData\\\" reverted with non-zero length\"}},\"kind\":\"user\",\"methods\":{\"SIG_VALIDATION_FAILED()\":{\"notice\":\"for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value in case of signature failure, instead of revert.\"},\"_validateSenderAndPaymaster(bytes,address,bytes)\":{\"notice\":\"Called only during simulation. This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\"},\"addStake(uint32)\":{\"notice\":\"add to the account's stake - amount and delay any pending unstake is first cancelled.\"},\"balanceOf(address)\":{\"notice\":\"return the deposit (for gas payment) of the account\"},\"depositTo(address)\":{\"notice\":\"add to the deposit of the given account\"},\"deposits(address)\":{\"notice\":\"maps paymaster to their deposits and stakes\"},\"getNonce(address,uint192)\":{\"notice\":\"Return the next nonce for this sender. Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop) But UserOp with different keys can come with arbitrary order.\"},\"getSenderAddress(bytes)\":{\"notice\":\"Get counterfactual sender address. Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation. this method always revert, and returns the address in SenderAddressResult error\"},\"getUserOpHash((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"generate a request Id - unique identifier for this request. the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\"},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperation with Aggregators\"},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperations. no signature aggregator is used. if any account requires an aggregator (that is, it returned an aggregator when performing simulateValidation), then handleAggregatedOps() must be used instead.\"},\"incrementNonce(uint192)\":{\"notice\":\"Manually increment the nonce of the sender. This method is exposed just for completeness.. Account does NOT need to call it, neither during validation, nor elsewhere, as the EntryPoint will update the nonce regardless. Possible use-case is call it with various keys to \\\"initialize\\\" their nonces to one, so that future UserOperations will not pay extra for the first transaction with a given key.\"},\"innerHandleOp(bytes,((address,uint256,uint256,uint256,uint256,address,uint256,uint256),bytes32,uint256,uint256,uint256),bytes)\":{\"notice\":\"inner function to handle a UserOperation. Must be declared \\\"external\\\" to open a call context, but it can only be called by handleOps.\"},\"nonceSequenceNumber(address,uint192)\":{\"notice\":\"The next valid sequence number for a given nonce key.\"},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"notice\":\"simulate full execution of a UserOperation (including both validation and target execution) this method will always revert with \\\"ExecutionResult\\\". it performs full validation of the UserOperation, but ignores signature error. an optional target address is called after the userop succeeds, and its value is returned (before the entire call is reverted) Note that in order to collect the the success/failure of the target call, it must be executed with trace enabled to track the emitted events.\"},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\"},\"unlockStake()\":{\"notice\":\"attempt to unlock the stake. the value can be withdrawn (using withdrawStake) after the unstake delay.\"},\"withdrawStake(address)\":{\"notice\":\"withdraw from the (unlocked) stake. must first call unlockStake and wait for the unstakeDelay to pass\"},\"withdrawTo(address,uint256)\":{\"notice\":\"withdraw from the deposit.\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/core/EntryPoint.sol\":\"EntryPoint\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":1000000},\"remappings\":[],\"viaIR\":true},\"sources\":{\"@openzeppelin/contracts/security/ReentrancyGuard.sol\":{\"keccak256\":\"0x190dd6f8d592b7e4e930feb7f4313aeb8e1c4ad3154c27ce1cf6a512fc30d8cc\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://4ce8dfb62d0c4fa260d6eec8f1cd47f5f2a044e11bde5b31d18072fa6e7d9010\",\"dweb:/ipfs/QmTyFztU3tLEcEDnqqiaW4UJetqsU77LXc6pjc9oTXCK5u\"]},\"contracts/core/EntryPoint.sol\":{\"keccak256\":\"0x04f86318b47f052d7308795ffae6ecec0d023d2458b4e17751b89a0e4acfcdc6\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://c9f6e359c8dbe875ad974d3a0fb7b3d62319a6b115c44bac1e4587ae2ad2edaf\",\"dweb:/ipfs/QmTSWTov2rUeYk8cwzrtsd3uVXokCYok4gMiZ1sPs9tycH\"]},\"contracts/core/Helpers.sol\":{\"keccak256\":\"0x591c87519f7155d1909210276b77925ab2722a99b7b5d5649aecc36ebbdb045a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://69643e83f68e6a13d5075c7565bfce326673b0bd98c432033c4603ea84835746\",\"dweb:/ipfs/QmSwSzjYyV7qudi5vvsmzHMG2Z4YJZxX51RRXXVCLaNcEU\"]},\"contracts/core/NonceManager.sol\":{\"keccak256\":\"0xa17a4a6fde70088ab18ffe6df830f3efa31f1cd0e1a7160336c96e3c94984d25\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://b38615df9f80c56282b72888e9ba1eb1a9413fa67a0dbf094deda7af9feb38e7\",\"dweb:/ipfs/QmSzcXetEJRH4UHuUmZiSgX6bFgfqHWfmyuxVnh4NosMk1\"]},\"contracts/core/SenderCreator.sol\":{\"keccak256\":\"0x44b9449fec82d6cdfb01d52fdd5a72f90099c651316123810cf9633f00b018c2\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a9c0487390e72638681d175c45bc92425c802fffdca4bd0ae8457782ee284612\",\"dweb:/ipfs/QmVbzuehCUWJWqEHyMWuc6cRVbxfcMdFsmGL9o4Wz7WY2x\"]},\"contracts/core/StakeManager.sol\":{\"keccak256\":\"0x21aa0956382bd000b1b8c3b1d19ca6ebcd6c9029eebb19c612fb38ee5dd2430a\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://0a625c8795354d9f429367f9c1d14eb8af7db9c7f2c2a2033e2066ced76a573a\",\"dweb:/ipfs/Qmd1j6UarUg54q1G2HCNCLQz8XGVZR1qxX7eQ6cytHpQPN\"]},\"contracts/interfaces/IAccount.sol\":{\"keccak256\":\"0x556a0e5980de18e90b115553ed502408155ba35f58642823010d9288047bc418\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a0f420134b79596db8737173c7b933ae0a33059e107b6327c43aa40d4744a9e4\",\"dweb:/ipfs/QmRo8s1AhXmEMV7uPYnbpYwU19e9Bk6jmYBJTiPx3Fo85W\"]},\"contracts/interfaces/IAggregator.sol\":{\"keccak256\":\"0x060e9ddb0152250c269ba0640dc5753834ac44cf182a2837d508c0c529cae26a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://20ed837bc5909c89ff1910246bf245a5dad6840aa939382e1694964eb7dbd37b\",\"dweb:/ipfs/QmTMybRq5yyghPDDs1ZCNAVB9sSJ4WHe6Q9mejuKPTAdNP\"]},\"contracts/interfaces/IEntryPoint.sol\":{\"keccak256\":\"0x3a90bf308819ed125fa4202f880999caff8a8686633b8ddb79a30ca240d5b8f8\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://d2d21cc92c2fdab2b58d21bc25d4cd0e8c284b922528a186b087b818d54bc6cf\",\"dweb:/ipfs/QmT1qrfuBjsv2rmRCDn8mgPXHp94hARJwzbcDuBLDTbFWd\"]},\"contracts/interfaces/INonceManager.sol\":{\"keccak256\":\"0x509871e6c63663cdcc3eba19920fe84e991f38b289b1377ac3c3a6d9f22d7e12\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://00fe21b4349b24c50df60e1a705179293982bd9e7a32b78d4bac9620f89e7fe2\",\"dweb:/ipfs/QmSFFYGfUwQbVa6hASjU7YxTvgi2HkfrPr4X5oPHscHg8b\"]},\"contracts/interfaces/IPaymaster.sol\":{\"keccak256\":\"0x36858ba8685024974f533530420688da3454d29996ebc42e410673a1ed2ec456\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://616cbcf51778b1961b7f20a547bec7efae6d1d565df0f651926241ed8bde9ad8\",\"dweb:/ipfs/QmaVsgffUUmeUJYgStvRr8cNZ1LBbrc3FYNLW4JT1dVLia\"]},\"contracts/interfaces/IStakeManager.sol\":{\"keccak256\":\"0xd227b02888cd4ac68daebcdfd992ec00f9fff66fa3b3bb16f656cd582fa3480f\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://b389da4714a138be63704a576a482505eab2855e263b38a93706395d8d42e7c3\",\"dweb:/ipfs/QmeeAZpdHwUXxqP8pxA7GNtoCGBmmH4FaqLLwScVKGxtxZ\"]},\"contracts/interfaces/UserOperation.sol\":{\"keccak256\":\"0x61374003361059087fdcf17967a7bba052badeaf5c7f0ae689166f8aafd3a45c\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://6ff83c59432e733bf6304dda27cd4b0f34401917dd535e2669cc842d2d26568c\",\"dweb:/ipfs/QmPJbHU5TAjHqUTZzAcicEeG2nknmwCN43L4EW9LHbknTN\"]},\"contracts/utils/Exec.sol\":{\"keccak256\":\"0x5b232117afbc2939f3ffc92745614867e9e1d475a3e1e5443adae13c200174f1\",\"license\":\"LGPL-3.0-only\",\"urls\":[\"bzz-raw://62e7365379a06ead7b47637945bcaee095d51aab1d3ac00ddec69443e6cbe9fe\",\"dweb:/ipfs/QmctG3aw4U3KMSMeJKoLJ1NJewjMWfppnd1m3kxNTe39Uy\"]}},\"version\":1}", - "bytecode": "0x60a080604052346200008957600160025561022c8181016001600160401b038111838210176200007357829162005d18833903906000f080156200006757608052604051615c8990816200008f82396080518181816113df01528181613e9501526141b60152f35b6040513d6000823e3d90fd5b634e487b7160e01b600052604160045260246000fd5b600080fdfe60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c634300081100336080806040523461001657610210908161001c8239f35b600080fdfe6080604052600436101561001257600080fd5b6000803560e01c63570e1a361461002857600080fd5b346100c95760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126100c95760043567ffffffffffffffff918282116100c957366023830112156100c95781600401359283116100c95736602484840101116100c9576100c561009e84602485016100fc565b60405173ffffffffffffffffffffffffffffffffffffffff90911681529081906020820190565b0390f35b80fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b90806014116101bb5767ffffffffffffffff917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec82018381116101cd575b604051937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f81600b8701160116850190858210908211176101c0575b604052808452602084019036848401116101bb576020946000600c819682946014880187378301015251923560601c5af19060005191156101b557565b60009150565b600080fd5b6101c86100cc565b610178565b6101d56100cc565b61013a56fea26469706673582212201927e80b76ab9b71c952137dd676621a9fdf520c25928815636594036eb1c40364736f6c63430008110033", - "deployedBytecode": "0x60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c63430008110033" -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/optimism/solcInputs/a4c52f0671aad8941c53d6ead2063803.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/optimism/solcInputs/a4c52f0671aad8941c53d6ead2063803.json deleted file mode 100644 index dd58ba5a3e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/optimism/solcInputs/a4c52f0671aad8941c53d6ead2063803.json +++ /dev/null @@ -1,68 +0,0 @@ -{ - "language": "Solidity", - "sources": { - "@openzeppelin/contracts/security/ReentrancyGuard.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (security/ReentrancyGuard.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Contract module that helps prevent reentrant calls to a function.\n *\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\n * available, which can be applied to functions to make sure there are no nested\n * (reentrant) calls to them.\n *\n * Note that because there is a single `nonReentrant` guard, functions marked as\n * `nonReentrant` may not call one another. This can be worked around by making\n * those functions `private`, and then adding `external` `nonReentrant` entry\n * points to them.\n *\n * TIP: If you would like to learn more about reentrancy and alternative ways\n * to protect against it, check out our blog post\n * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].\n */\nabstract contract ReentrancyGuard {\n // Booleans are more expensive than uint256 or any type that takes up a full\n // word because each write operation emits an extra SLOAD to first read the\n // slot's contents, replace the bits taken up by the boolean, and then write\n // back. This is the compiler's defense against contract upgrades and\n // pointer aliasing, and it cannot be disabled.\n\n // The values being non-zero value makes deployment a bit more expensive,\n // but in exchange the refund on every call to nonReentrant will be lower in\n // amount. Since refunds are capped to a percentage of the total\n // transaction's gas, it is best to keep them low in cases like this one, to\n // increase the likelihood of the full refund coming into effect.\n uint256 private constant _NOT_ENTERED = 1;\n uint256 private constant _ENTERED = 2;\n\n uint256 private _status;\n\n constructor() {\n _status = _NOT_ENTERED;\n }\n\n /**\n * @dev Prevents a contract from calling itself, directly or indirectly.\n * Calling a `nonReentrant` function from another `nonReentrant`\n * function is not supported. It is possible to prevent this from happening\n * by making the `nonReentrant` function external, and making it call a\n * `private` function that does the actual work.\n */\n modifier nonReentrant() {\n _nonReentrantBefore();\n _;\n _nonReentrantAfter();\n }\n\n function _nonReentrantBefore() private {\n // On the first call to nonReentrant, _status will be _NOT_ENTERED\n require(_status != _ENTERED, \"ReentrancyGuard: reentrant call\");\n\n // Any calls to nonReentrant after this point will fail\n _status = _ENTERED;\n }\n\n function _nonReentrantAfter() private {\n // By storing the original value once again, a refund is triggered (see\n // https://eips.ethereum.org/EIPS/eip-2200)\n _status = _NOT_ENTERED;\n }\n}\n" - }, - "contracts/core/EntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IPaymaster.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\n\nimport \"../utils/Exec.sol\";\nimport \"./StakeManager.sol\";\nimport \"./SenderCreator.sol\";\nimport \"./Helpers.sol\";\nimport \"./NonceManager.sol\";\nimport \"@openzeppelin/contracts/security/ReentrancyGuard.sol\";\n\ncontract EntryPoint is IEntryPoint, StakeManager, NonceManager, ReentrancyGuard {\n\n using UserOperationLib for UserOperation;\n\n SenderCreator private immutable senderCreator = new SenderCreator();\n\n // internal value used during simulation: need to query aggregator.\n address private constant SIMULATE_FIND_AGGREGATOR = address(1);\n\n // marker for inner call revert on out of gas\n bytes32 private constant INNER_OUT_OF_GAS = hex'deaddead';\n\n uint256 private constant REVERT_REASON_MAX_LEN = 2048;\n\n /**\n * for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value\n * in case of signature failure, instead of revert.\n */\n uint256 public constant SIG_VALIDATION_FAILED = 1;\n\n /**\n * compensate the caller's beneficiary address with the collected fees of all UserOperations.\n * @param beneficiary the address to receive the fees\n * @param amount amount to transfer.\n */\n function _compensate(address payable beneficiary, uint256 amount) internal {\n require(beneficiary != address(0), \"AA90 invalid beneficiary\");\n (bool success,) = beneficiary.call{value : amount}(\"\");\n require(success, \"AA91 failed send to beneficiary\");\n }\n\n /**\n * execute a user op\n * @param opIndex index into the opInfo array\n * @param userOp the userOp to execute\n * @param opInfo the opInfo filled by validatePrepayment for this userOp.\n * @return collected the total amount this userOp paid.\n */\n function _executeUserOp(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory opInfo) private returns (uint256 collected) {\n uint256 preGas = gasleft();\n bytes memory context = getMemoryBytesFromOffset(opInfo.contextOffset);\n\n try this.innerHandleOp(userOp.callData, opInfo, context) returns (uint256 _actualGasCost) {\n collected = _actualGasCost;\n } catch {\n bytes32 innerRevertCode;\n assembly {\n returndatacopy(0, 0, 32)\n innerRevertCode := mload(0)\n }\n // handleOps was called with gas limit too low. abort entire bundle.\n if (innerRevertCode == INNER_OUT_OF_GAS) {\n //report paymaster, since if it is not deliberately caused by the bundler,\n // it must be a revert caused by paymaster.\n revert FailedOp(opIndex, \"AA95 out of gas\");\n }\n\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n collected = _handlePostOp(opIndex, IPaymaster.PostOpMode.postOpReverted, opInfo, context, actualGas);\n }\n }\n\n /**\n * Execute a batch of UserOperations.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) public nonReentrant {\n\n uint256 opslen = ops.length;\n UserOpInfo[] memory opInfos = new UserOpInfo[](opslen);\n\n unchecked {\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[i];\n (uint256 validationData, uint256 pmValidationData) = _validatePrepayment(i, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, pmValidationData, address(0));\n }\n\n uint256 collected = 0;\n emit BeforeExecution();\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(i, ops[i], opInfos[i]);\n }\n\n _compensate(beneficiary, collected);\n } //unchecked\n }\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) public nonReentrant {\n\n uint256 opasLen = opsPerAggregator.length;\n uint256 totalOps = 0;\n for (uint256 i = 0; i < opasLen; i++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[i];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n //address(1) is special marker of \"signature error\"\n require(address(aggregator) != address(1), \"AA96 invalid aggregator\");\n\n if (address(aggregator) != address(0)) {\n // solhint-disable-next-line no-empty-blocks\n try aggregator.validateSignatures(ops, opa.signature) {}\n catch {\n revert SignatureValidationFailed(address(aggregator));\n }\n }\n\n totalOps += ops.length;\n }\n\n UserOpInfo[] memory opInfos = new UserOpInfo[](totalOps);\n\n emit BeforeExecution();\n\n uint256 opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n uint256 opslen = ops.length;\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[opIndex];\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(opIndex, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, paymasterValidationData, address(aggregator));\n opIndex++;\n }\n }\n\n uint256 collected = 0;\n opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n emit SignatureAggregatorChanged(address(opa.aggregator));\n UserOperation[] calldata ops = opa.userOps;\n uint256 opslen = ops.length;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(opIndex, ops[i], opInfos[opIndex]);\n opIndex++;\n }\n }\n emit SignatureAggregatorChanged(address(0));\n\n _compensate(beneficiary, collected);\n }\n\n /// @inheritdoc IEntryPoint\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external override {\n\n UserOpInfo memory opInfo;\n _simulationOnlyValidations(op);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, op, opInfo);\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n\n numberMarker();\n uint256 paid = _executeUserOp(0, op, opInfo);\n numberMarker();\n bool targetSuccess;\n bytes memory targetResult;\n if (target != address(0)) {\n (targetSuccess, targetResult) = target.call(targetCallData);\n }\n revert ExecutionResult(opInfo.preOpGas, paid, data.validAfter, data.validUntil, targetSuccess, targetResult);\n }\n\n\n // A memory copy of UserOp static fields only.\n // Excluding: callData, initCode and signature. Replacing paymasterAndData with paymaster.\n struct MemoryUserOp {\n address sender;\n uint256 nonce;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n address paymaster;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n }\n\n struct UserOpInfo {\n MemoryUserOp mUserOp;\n bytes32 userOpHash;\n uint256 prefund;\n uint256 contextOffset;\n uint256 preOpGas;\n }\n\n /**\n * inner function to handle a UserOperation.\n * Must be declared \"external\" to open a call context, but it can only be called by handleOps.\n */\n function innerHandleOp(bytes memory callData, UserOpInfo memory opInfo, bytes calldata context) external returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n require(msg.sender == address(this), \"AA92 internal call only\");\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n\n uint callGasLimit = mUserOp.callGasLimit;\n unchecked {\n // handleOps was called with gas limit too low. abort entire bundle.\n if (gasleft() < callGasLimit + mUserOp.verificationGasLimit + 5000) {\n assembly {\n mstore(0, INNER_OUT_OF_GAS)\n revert(0, 32)\n }\n }\n }\n\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\n if (callData.length > 0) {\n bool success = Exec.call(mUserOp.sender, 0, callData, callGasLimit);\n if (!success) {\n bytes memory result = Exec.getReturnData(REVERT_REASON_MAX_LEN);\n if (result.length > 0) {\n emit UserOperationRevertReason(opInfo.userOpHash, mUserOp.sender, mUserOp.nonce, result);\n }\n mode = IPaymaster.PostOpMode.opReverted;\n }\n }\n\n unchecked {\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n //note: opIndex is ignored (relevant only if mode==postOpReverted, which is only possible outside of innerHandleOp)\n return _handlePostOp(0, mode, opInfo, context, actualGas);\n }\n }\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) public view returns (bytes32) {\n return keccak256(abi.encode(userOp.hash(), address(this), block.chainid));\n }\n\n /**\n * copy general fields from userOp into the memory opInfo structure.\n */\n function _copyUserOpToMemory(UserOperation calldata userOp, MemoryUserOp memory mUserOp) internal pure {\n mUserOp.sender = userOp.sender;\n mUserOp.nonce = userOp.nonce;\n mUserOp.callGasLimit = userOp.callGasLimit;\n mUserOp.verificationGasLimit = userOp.verificationGasLimit;\n mUserOp.preVerificationGas = userOp.preVerificationGas;\n mUserOp.maxFeePerGas = userOp.maxFeePerGas;\n mUserOp.maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes calldata paymasterAndData = userOp.paymasterAndData;\n if (paymasterAndData.length > 0) {\n require(paymasterAndData.length >= 20, \"AA93 invalid paymasterAndData\");\n mUserOp.paymaster = address(bytes20(paymasterAndData[: 20]));\n } else {\n mUserOp.paymaster = address(0);\n }\n }\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external {\n UserOpInfo memory outOpInfo;\n\n _simulationOnlyValidations(userOp);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, userOp, outOpInfo);\n StakeInfo memory paymasterInfo = _getStakeInfo(outOpInfo.mUserOp.paymaster);\n StakeInfo memory senderInfo = _getStakeInfo(outOpInfo.mUserOp.sender);\n StakeInfo memory factoryInfo;\n {\n bytes calldata initCode = userOp.initCode;\n address factory = initCode.length >= 20 ? address(bytes20(initCode[0 : 20])) : address(0);\n factoryInfo = _getStakeInfo(factory);\n }\n\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n address aggregator = data.aggregator;\n bool sigFailed = aggregator == address(1);\n ReturnInfo memory returnInfo = ReturnInfo(outOpInfo.preOpGas, outOpInfo.prefund,\n sigFailed, data.validAfter, data.validUntil, getMemoryBytesFromOffset(outOpInfo.contextOffset));\n\n if (aggregator != address(0) && aggregator != address(1)) {\n AggregatorStakeInfo memory aggregatorInfo = AggregatorStakeInfo(aggregator, _getStakeInfo(aggregator));\n revert ValidationResultWithAggregation(returnInfo, senderInfo, factoryInfo, paymasterInfo, aggregatorInfo);\n }\n revert ValidationResult(returnInfo, senderInfo, factoryInfo, paymasterInfo);\n\n }\n\n function _getRequiredPrefund(MemoryUserOp memory mUserOp) internal pure returns (uint256 requiredPrefund) {\n unchecked {\n //when using a Paymaster, the verificationGasLimit is used also to as a limit for the postOp call.\n // our security model might call postOp eventually twice\n uint256 mul = mUserOp.paymaster != address(0) ? 3 : 1;\n uint256 requiredGas = mUserOp.callGasLimit + mUserOp.verificationGasLimit * mul + mUserOp.preVerificationGas;\n\n requiredPrefund = requiredGas * mUserOp.maxFeePerGas;\n }\n }\n\n // create the sender's contract if needed.\n function _createSenderIfNeeded(uint256 opIndex, UserOpInfo memory opInfo, bytes calldata initCode) internal {\n if (initCode.length != 0) {\n address sender = opInfo.mUserOp.sender;\n if (sender.code.length != 0) revert FailedOp(opIndex, \"AA10 sender already constructed\");\n address sender1 = senderCreator.createSender{gas : opInfo.mUserOp.verificationGasLimit}(initCode);\n if (sender1 == address(0)) revert FailedOp(opIndex, \"AA13 initCode failed or OOG\");\n if (sender1 != sender) revert FailedOp(opIndex, \"AA14 initCode must return sender\");\n if (sender1.code.length == 0) revert FailedOp(opIndex, \"AA15 initCode must create sender\");\n address factory = address(bytes20(initCode[0 : 20]));\n emit AccountDeployed(opInfo.userOpHash, sender, factory, opInfo.mUserOp.paymaster);\n }\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes calldata initCode) public {\n address sender = senderCreator.createSender(initCode);\n revert SenderAddressResult(sender);\n }\n\n function _simulationOnlyValidations(UserOperation calldata userOp) internal view {\n // solhint-disable-next-line no-empty-blocks\n try this._validateSenderAndPaymaster(userOp.initCode, userOp.sender, userOp.paymasterAndData) {}\n catch Error(string memory revertReason) {\n if (bytes(revertReason).length != 0) {\n revert FailedOp(0, revertReason);\n }\n }\n }\n\n /**\n * Called only during simulation.\n * This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\n */\n function _validateSenderAndPaymaster(bytes calldata initCode, address sender, bytes calldata paymasterAndData) external view {\n if (initCode.length == 0 && sender.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA20 account not deployed\");\n }\n if (paymasterAndData.length >= 20) {\n address paymaster = address(bytes20(paymasterAndData[0 : 20]));\n if (paymaster.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA30 paymaster not deployed\");\n }\n }\n // always revert\n revert(\"\");\n }\n\n /**\n * call account.validateUserOp.\n * revert (with FailedOp) in case validateUserOp reverts, or account didn't send required prefund.\n * decrement account's deposit if needed\n */\n function _validateAccountPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPrefund)\n internal returns (uint256 gasUsedByValidateAccountPrepayment, uint256 validationData) {\n unchecked {\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n address sender = mUserOp.sender;\n _createSenderIfNeeded(opIndex, opInfo, op.initCode);\n address paymaster = mUserOp.paymaster;\n numberMarker();\n uint256 missingAccountFunds = 0;\n if (paymaster == address(0)) {\n uint256 bal = balanceOf(sender);\n missingAccountFunds = bal > requiredPrefund ? 0 : requiredPrefund - bal;\n }\n try IAccount(sender).validateUserOp{gas : mUserOp.verificationGasLimit}(op, opInfo.userOpHash, missingAccountFunds)\n returns (uint256 _validationData) {\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA23 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA23 reverted (or OOG)\");\n }\n if (paymaster == address(0)) {\n DepositInfo storage senderInfo = deposits[sender];\n uint256 deposit = senderInfo.deposit;\n if (requiredPrefund > deposit) {\n revert FailedOp(opIndex, \"AA21 didn't pay prefund\");\n }\n senderInfo.deposit = uint112(deposit - requiredPrefund);\n }\n gasUsedByValidateAccountPrepayment = preGas - gasleft();\n }\n }\n\n /**\n * In case the request has a paymaster:\n * Validate paymaster has enough deposit.\n * Call paymaster.validatePaymasterUserOp.\n * Revert with proper FailedOp in case paymaster reverts.\n * Decrement paymaster's deposit\n */\n function _validatePaymasterPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPreFund, uint256 gasUsedByValidateAccountPrepayment)\n internal returns (bytes memory context, uint256 validationData) {\n unchecked {\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 verificationGasLimit = mUserOp.verificationGasLimit;\n require(verificationGasLimit > gasUsedByValidateAccountPrepayment, \"AA41 too little verificationGas\");\n uint256 gas = verificationGasLimit - gasUsedByValidateAccountPrepayment;\n\n address paymaster = mUserOp.paymaster;\n DepositInfo storage paymasterInfo = deposits[paymaster];\n uint256 deposit = paymasterInfo.deposit;\n if (deposit < requiredPreFund) {\n revert FailedOp(opIndex, \"AA31 paymaster deposit too low\");\n }\n paymasterInfo.deposit = uint112(deposit - requiredPreFund);\n try IPaymaster(paymaster).validatePaymasterUserOp{gas : gas}(op, opInfo.userOpHash, requiredPreFund) returns (bytes memory _context, uint256 _validationData){\n context = _context;\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA33 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA33 reverted (or OOG)\");\n }\n }\n }\n\n /**\n * revert if either account validationData or paymaster validationData is expired\n */\n function _validateAccountAndPaymasterValidationData(uint256 opIndex, uint256 validationData, uint256 paymasterValidationData, address expectedAggregator) internal view {\n (address aggregator, bool outOfTimeRange) = _getValidationData(validationData);\n if (expectedAggregator != aggregator) {\n revert FailedOp(opIndex, \"AA24 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA22 expired or not due\");\n }\n //pmAggregator is not a real signature aggregator: we don't have logic to handle it as address.\n // non-zero address means that the paymaster fails due to some signature check (which is ok only during estimation)\n address pmAggregator;\n (pmAggregator, outOfTimeRange) = _getValidationData(paymasterValidationData);\n if (pmAggregator != address(0)) {\n revert FailedOp(opIndex, \"AA34 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA32 paymaster expired or not due\");\n }\n }\n\n function _getValidationData(uint256 validationData) internal view returns (address aggregator, bool outOfTimeRange) {\n if (validationData == 0) {\n return (address(0), false);\n }\n ValidationData memory data = _parseValidationData(validationData);\n // solhint-disable-next-line not-rely-on-time\n outOfTimeRange = block.timestamp > data.validUntil || block.timestamp < data.validAfter;\n aggregator = data.aggregator;\n }\n\n /**\n * validate account and paymaster (if defined).\n * also make sure total validation doesn't exceed verificationGasLimit\n * this method is called off-chain (simulateValidation()) and on-chain (from handleOps)\n * @param opIndex the index of this userOp into the \"opInfos\" array\n * @param userOp the userOp to validate\n */\n function _validatePrepayment(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory outOpInfo)\n private returns (uint256 validationData, uint256 paymasterValidationData) {\n\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = outOpInfo.mUserOp;\n _copyUserOpToMemory(userOp, mUserOp);\n outOpInfo.userOpHash = getUserOpHash(userOp);\n\n // validate all numeric values in userOp are well below 128 bit, so they can safely be added\n // and multiplied without causing overflow\n uint256 maxGasValues = mUserOp.preVerificationGas | mUserOp.verificationGasLimit | mUserOp.callGasLimit |\n userOp.maxFeePerGas | userOp.maxPriorityFeePerGas;\n require(maxGasValues <= type(uint120).max, \"AA94 gas values overflow\");\n\n uint256 gasUsedByValidateAccountPrepayment;\n (uint256 requiredPreFund) = _getRequiredPrefund(mUserOp);\n (gasUsedByValidateAccountPrepayment, validationData) = _validateAccountPrepayment(opIndex, userOp, outOpInfo, requiredPreFund);\n\n if (!_validateAndUpdateNonce(mUserOp.sender, mUserOp.nonce)) {\n revert FailedOp(opIndex, \"AA25 invalid account nonce\");\n }\n\n //a \"marker\" where account opcode validation is done and paymaster opcode validation is about to start\n // (used only by off-chain simulateValidation)\n numberMarker();\n\n bytes memory context;\n if (mUserOp.paymaster != address(0)) {\n (context, paymasterValidationData) = _validatePaymasterPrepayment(opIndex, userOp, outOpInfo, requiredPreFund, gasUsedByValidateAccountPrepayment);\n }\n unchecked {\n uint256 gasUsed = preGas - gasleft();\n\n if (userOp.verificationGasLimit < gasUsed) {\n revert FailedOp(opIndex, \"AA40 over verificationGasLimit\");\n }\n outOpInfo.prefund = requiredPreFund;\n outOpInfo.contextOffset = getOffsetOfMemoryBytes(context);\n outOpInfo.preOpGas = preGas - gasleft() + userOp.preVerificationGas;\n }\n }\n\n /**\n * process post-operation.\n * called just after the callData is executed.\n * if a paymaster is defined and its validation returned a non-empty context, its postOp is called.\n * the excess amount is refunded to the account (or paymaster - if it was used in the request)\n * @param opIndex index in the batch\n * @param mode - whether is called from innerHandleOp, or outside (postOpReverted)\n * @param opInfo userOp fields and info collected during validation\n * @param context the context returned in validatePaymasterUserOp\n * @param actualGas the gas used so far by this user operation\n */\n function _handlePostOp(uint256 opIndex, IPaymaster.PostOpMode mode, UserOpInfo memory opInfo, bytes memory context, uint256 actualGas) private returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n unchecked {\n address refundAddress;\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 gasPrice = getUserOpGasPrice(mUserOp);\n\n address paymaster = mUserOp.paymaster;\n if (paymaster == address(0)) {\n refundAddress = mUserOp.sender;\n } else {\n refundAddress = paymaster;\n if (context.length > 0) {\n actualGasCost = actualGas * gasPrice;\n if (mode != IPaymaster.PostOpMode.postOpReverted) {\n IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost);\n } else {\n // solhint-disable-next-line no-empty-blocks\n try IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost) {}\n catch Error(string memory reason) {\n revert FailedOp(opIndex, string.concat(\"AA50 postOp reverted: \", reason));\n }\n catch {\n revert FailedOp(opIndex, \"AA50 postOp revert\");\n }\n }\n }\n }\n actualGas += preGas - gasleft();\n actualGasCost = actualGas * gasPrice;\n if (opInfo.prefund < actualGasCost) {\n revert FailedOp(opIndex, \"AA51 prefund below actualGasCost\");\n }\n uint256 refund = opInfo.prefund - actualGasCost;\n _incrementDeposit(refundAddress, refund);\n bool success = mode == IPaymaster.PostOpMode.opSucceeded;\n emit UserOperationEvent(opInfo.userOpHash, mUserOp.sender, mUserOp.paymaster, mUserOp.nonce, success, actualGasCost, actualGas);\n } // unchecked\n }\n\n /**\n * the gas price this UserOp agrees to pay.\n * relayer/block builder might submit the TX with higher priorityFee, but the user should not\n */\n function getUserOpGasPrice(MemoryUserOp memory mUserOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = mUserOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = mUserOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n\n function getOffsetOfMemoryBytes(bytes memory data) internal pure returns (uint256 offset) {\n assembly {offset := data}\n }\n\n function getMemoryBytesFromOffset(uint256 offset) internal pure returns (bytes memory data) {\n assembly {data := offset}\n }\n\n //place the NUMBER opcode in the code.\n // this is used as a marker during simulation, as this OP is completely banned from the simulated code of the\n // account and paymaster.\n function numberMarker() internal view {\n assembly {mstore(0, number())}\n }\n}\n\n" - }, - "contracts/core/Helpers.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\n/**\n * returned data from validateUserOp.\n * validateUserOp returns a uint256, with is created by `_packedValidationData` and parsed by `_parseValidationData`\n * @param aggregator - address(0) - the account validated the signature by itself.\n * address(1) - the account failed to validate the signature.\n * otherwise - this is an address of a signature aggregator that must be used to validate the signature.\n * @param validAfter - this UserOp is valid only after this timestamp.\n * @param validaUntil - this UserOp is valid only up to this timestamp.\n */\n struct ValidationData {\n address aggregator;\n uint48 validAfter;\n uint48 validUntil;\n }\n\n//extract sigFailed, validAfter, validUntil.\n// also convert zero validUntil to type(uint48).max\n function _parseValidationData(uint validationData) pure returns (ValidationData memory data) {\n address aggregator = address(uint160(validationData));\n uint48 validUntil = uint48(validationData >> 160);\n if (validUntil == 0) {\n validUntil = type(uint48).max;\n }\n uint48 validAfter = uint48(validationData >> (48 + 160));\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n// intersect account and paymaster ranges.\n function _intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) pure returns (ValidationData memory) {\n ValidationData memory accountValidationData = _parseValidationData(validationData);\n ValidationData memory pmValidationData = _parseValidationData(paymasterValidationData);\n address aggregator = accountValidationData.aggregator;\n if (aggregator == address(0)) {\n aggregator = pmValidationData.aggregator;\n }\n uint48 validAfter = accountValidationData.validAfter;\n uint48 validUntil = accountValidationData.validUntil;\n uint48 pmValidAfter = pmValidationData.validAfter;\n uint48 pmValidUntil = pmValidationData.validUntil;\n\n if (validAfter < pmValidAfter) validAfter = pmValidAfter;\n if (validUntil > pmValidUntil) validUntil = pmValidUntil;\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n/**\n * helper to pack the return value for validateUserOp\n * @param data - the ValidationData to pack\n */\n function _packValidationData(ValidationData memory data) pure returns (uint256) {\n return uint160(data.aggregator) | (uint256(data.validUntil) << 160) | (uint256(data.validAfter) << (160 + 48));\n }\n\n/**\n * helper to pack the return value for validateUserOp, when not using an aggregator\n * @param sigFailed - true for signature failure, false for success\n * @param validUntil last timestamp this UserOperation is valid (or zero for infinite)\n * @param validAfter first timestamp this UserOperation is valid\n */\n function _packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) pure returns (uint256) {\n return (sigFailed ? 1 : 0) | (uint256(validUntil) << 160) | (uint256(validAfter) << (160 + 48));\n }\n\n/**\n * keccak function over calldata.\n * @dev copy calldata into memory, do keccak and drop allocated memory. Strangely, this is more efficient than letting solidity do it.\n */\n function calldataKeccak(bytes calldata data) pure returns (bytes32 ret) {\n assembly {\n let mem := mload(0x40)\n let len := data.length\n calldatacopy(mem, data.offset, len)\n ret := keccak256(mem, len)\n }\n }\n\n" - }, - "contracts/core/NonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IEntryPoint.sol\";\n\n/**\n * nonce management functionality\n */\ncontract NonceManager is INonceManager {\n\n /**\n * The next valid sequence number for a given nonce key.\n */\n mapping(address => mapping(uint192 => uint256)) public nonceSequenceNumber;\n\n function getNonce(address sender, uint192 key)\n public view override returns (uint256 nonce) {\n return nonceSequenceNumber[sender][key] | (uint256(key) << 64);\n }\n\n // allow an account to manually increment its own nonce.\n // (mainly so that during construction nonce can be made non-zero,\n // to \"absorb\" the gas cost of first nonce increment to 1st transaction (construction),\n // not to 2nd transaction)\n function incrementNonce(uint192 key) public override {\n nonceSequenceNumber[msg.sender][key]++;\n }\n\n /**\n * validate nonce uniqueness for this account.\n * called just after validateUserOp()\n */\n function _validateAndUpdateNonce(address sender, uint256 nonce) internal returns (bool) {\n\n uint192 key = uint192(nonce >> 64);\n uint64 seq = uint64(nonce);\n return nonceSequenceNumber[sender][key]++ == seq;\n }\n\n}\n" - }, - "contracts/core/SenderCreator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * helper contract for EntryPoint, to call userOp.initCode from a \"neutral\" address,\n * which is explicitly not the entryPoint itself.\n */\ncontract SenderCreator {\n\n /**\n * call the \"initCode\" factory to create and return the sender account address\n * @param initCode the initCode value from a UserOp. contains 20 bytes of factory address, followed by calldata\n * @return sender the returned address of the created account, or zero address on failure.\n */\n function createSender(bytes calldata initCode) external returns (address sender) {\n address factory = address(bytes20(initCode[0 : 20]));\n bytes memory initCallData = initCode[20 :];\n bool success;\n /* solhint-disable no-inline-assembly */\n assembly {\n success := call(gas(), factory, 0, add(initCallData, 0x20), mload(initCallData), 0, 32)\n sender := mload(0)\n }\n if (!success) {\n sender = address(0);\n }\n }\n}\n" - }, - "contracts/core/StakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IStakeManager.sol\";\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable not-rely-on-time */\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by a paymaster.\n */\nabstract contract StakeManager is IStakeManager {\n\n /// maps paymaster to their deposits and stakes\n mapping(address => DepositInfo) public deposits;\n\n /// @inheritdoc IStakeManager\n function getDepositInfo(address account) public view returns (DepositInfo memory info) {\n return deposits[account];\n }\n\n // internal method to return just the stake info\n function _getStakeInfo(address addr) internal view returns (StakeInfo memory info) {\n DepositInfo storage depositInfo = deposits[addr];\n info.stake = depositInfo.stake;\n info.unstakeDelaySec = depositInfo.unstakeDelaySec;\n }\n\n /// return the deposit (for gas payment) of the account\n function balanceOf(address account) public view returns (uint256) {\n return deposits[account].deposit;\n }\n\n receive() external payable {\n depositTo(msg.sender);\n }\n\n function _incrementDeposit(address account, uint256 amount) internal {\n DepositInfo storage info = deposits[account];\n uint256 newAmount = info.deposit + amount;\n require(newAmount <= type(uint112).max, \"deposit overflow\");\n info.deposit = uint112(newAmount);\n }\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) public payable {\n _incrementDeposit(account, msg.value);\n DepositInfo storage info = deposits[account];\n emit Deposited(account, info.deposit);\n }\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 unstakeDelaySec) public payable {\n DepositInfo storage info = deposits[msg.sender];\n require(unstakeDelaySec > 0, \"must specify unstake delay\");\n require(unstakeDelaySec >= info.unstakeDelaySec, \"cannot decrease unstake time\");\n uint256 stake = info.stake + msg.value;\n require(stake > 0, \"no stake specified\");\n require(stake <= type(uint112).max, \"stake overflow\");\n deposits[msg.sender] = DepositInfo(\n info.deposit,\n true,\n uint112(stake),\n unstakeDelaySec,\n 0\n );\n emit StakeLocked(msg.sender, stake, unstakeDelaySec);\n }\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external {\n DepositInfo storage info = deposits[msg.sender];\n require(info.unstakeDelaySec != 0, \"not staked\");\n require(info.staked, \"already unstaking\");\n uint48 withdrawTime = uint48(block.timestamp) + info.unstakeDelaySec;\n info.withdrawTime = withdrawTime;\n info.staked = false;\n emit StakeUnlocked(msg.sender, withdrawTime);\n }\n\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external {\n DepositInfo storage info = deposits[msg.sender];\n uint256 stake = info.stake;\n require(stake > 0, \"No stake to withdraw\");\n require(info.withdrawTime > 0, \"must call unlockStake() first\");\n require(info.withdrawTime <= block.timestamp, \"Stake withdrawal is not due\");\n info.unstakeDelaySec = 0;\n info.withdrawTime = 0;\n info.stake = 0;\n emit StakeWithdrawn(msg.sender, withdrawAddress, stake);\n (bool success,) = withdrawAddress.call{value : stake}(\"\");\n require(success, \"failed to withdraw stake\");\n }\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external {\n DepositInfo storage info = deposits[msg.sender];\n require(withdrawAmount <= info.deposit, \"Withdraw amount too large\");\n info.deposit = uint112(info.deposit - withdrawAmount);\n emit Withdrawn(msg.sender, withdrawAddress, withdrawAmount);\n (bool success,) = withdrawAddress.call{value : withdrawAmount}(\"\");\n require(success, \"failed to withdraw\");\n }\n}\n" - }, - "contracts/interfaces/IAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\ninterface IAccount {\n\n /**\n * Validate user's signature and nonce\n * the entryPoint will make the call to the recipient only if this validation call returns successfully.\n * signature failure should be reported by returning SIG_VALIDATION_FAILED (1).\n * This allows making a \"simulation call\" without a valid signature\n * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure.\n *\n * @dev Must validate caller is the entryPoint.\n * Must validate the signature and nonce\n * @param userOp the operation that is about to be executed.\n * @param userOpHash hash of the user's request data. can be used as the basis for signature.\n * @param missingAccountFunds missing funds on the account's deposit in the entrypoint.\n * This is the minimum amount to transfer to the sender(entryPoint) to be able to make the call.\n * The excess is left as a deposit in the entrypoint, for future calls.\n * can be withdrawn anytime using \"entryPoint.withdrawTo()\"\n * In case there is a paymaster in the request (or the current deposit is high enough), this value will be zero.\n * @return validationData packaged ValidationData structure. use `_packValidationData` and `_unpackValidationData` to encode and decode\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * If an account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external returns (uint256 validationData);\n}\n" - }, - "contracts/interfaces/IAggregator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * Aggregated Signatures validator.\n */\ninterface IAggregator {\n\n /**\n * validate aggregated signature.\n * revert if the aggregated signature does not match the given list of operations.\n */\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external view;\n\n /**\n * validate signature of a single userOp\n * This method is should be called by bundler after EntryPoint.simulateValidation() returns (reverts) with ValidationResultWithAggregation\n * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps.\n * @param userOp the userOperation received from the user.\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\n * (usually empty, unless account and aggregator support some kind of \"multisig\"\n */\n function validateUserOpSignature(UserOperation calldata userOp)\n external view returns (bytes memory sigForUserOp);\n\n /**\n * aggregate multiple signatures into a single value.\n * This method is called off-chain to calculate the signature to pass with handleOps()\n * bundler MAY use optimized custom code perform this aggregation\n * @param userOps array of UserOperations to collect the signatures from.\n * @return aggregatedSignature the aggregated signature\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external view returns (bytes memory aggregatedSignature);\n}\n" - }, - "contracts/interfaces/IEntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"./UserOperation.sol\";\nimport \"./IStakeManager.sol\";\nimport \"./IAggregator.sol\";\nimport \"./INonceManager.sol\";\n\ninterface IEntryPoint is IStakeManager, INonceManager {\n\n /***\n * An event emitted after each successful request\n * @param userOpHash - unique identifier for the request (hash its entire content, except signature).\n * @param sender - the account that generates this request.\n * @param paymaster - if non-null, the paymaster that pays for this request.\n * @param nonce - the nonce value from the request.\n * @param success - true if the sender transaction succeeded, false if reverted.\n * @param actualGasCost - actual amount paid (by account or paymaster) for this UserOperation.\n * @param actualGasUsed - total gas used by this UserOperation (including preVerification, creation, validation and execution).\n */\n event UserOperationEvent(bytes32 indexed userOpHash, address indexed sender, address indexed paymaster, uint256 nonce, bool success, uint256 actualGasCost, uint256 actualGasUsed);\n\n /**\n * account \"sender\" was deployed.\n * @param userOpHash the userOp that deployed this account. UserOperationEvent will follow.\n * @param sender the account that is deployed\n * @param factory the factory used to deploy this account (in the initCode)\n * @param paymaster the paymaster used by this UserOp\n */\n event AccountDeployed(bytes32 indexed userOpHash, address indexed sender, address factory, address paymaster);\n\n /**\n * An event emitted if the UserOperation \"callData\" reverted with non-zero length\n * @param userOpHash the request unique identifier.\n * @param sender the sender of this request\n * @param nonce the nonce used in the request\n * @param revertReason - the return bytes from the (reverted) call to \"callData\".\n */\n event UserOperationRevertReason(bytes32 indexed userOpHash, address indexed sender, uint256 nonce, bytes revertReason);\n\n /**\n * an event emitted by handleOps(), before starting the execution loop.\n * any event emitted before this event, is part of the validation.\n */\n event BeforeExecution();\n\n /**\n * signature aggregator used by the following UserOperationEvents within this bundle.\n */\n event SignatureAggregatorChanged(address indexed aggregator);\n\n /**\n * a custom revert error of handleOps, to identify the offending op.\n * NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\n * @param opIndex - index into the array of ops to the failed one (in simulateValidation, this is always zero)\n * @param reason - revert reason\n * The string starts with a unique code \"AAmn\", where \"m\" is \"1\" for factory, \"2\" for account and \"3\" for paymaster issues,\n * so a failure can be attributed to the correct entity.\n * Should be caught in off-chain handleOps simulation and not happen on-chain.\n * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\n */\n error FailedOp(uint256 opIndex, string reason);\n\n /**\n * error case when a signature aggregator fails to verify the aggregated signature it had created.\n */\n error SignatureValidationFailed(address aggregator);\n\n /**\n * Successful result from simulateValidation.\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n */\n error ValidationResult(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo);\n\n /**\n * Successful result from simulateValidation, if the account returns a signature aggregator\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n * @param aggregatorInfo signature aggregation info (if the account requires signature aggregator)\n * bundler MUST use it to verify the signature, or reject the UserOperation\n */\n error ValidationResultWithAggregation(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo,\n AggregatorStakeInfo aggregatorInfo);\n\n /**\n * return value of getSenderAddress\n */\n error SenderAddressResult(address sender);\n\n /**\n * return value of simulateHandleOp\n */\n error ExecutionResult(uint256 preOpGas, uint256 paid, uint48 validAfter, uint48 validUntil, bool targetSuccess, bytes targetResult);\n\n //UserOps handled, per aggregator\n struct UserOpsPerAggregator {\n UserOperation[] userOps;\n\n // aggregator address\n IAggregator aggregator;\n // aggregated signature\n bytes signature;\n }\n\n /**\n * Execute a batch of UserOperation.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) external;\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) external;\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) external view returns (bytes32);\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external;\n\n /**\n * gas and return values during simulation\n * @param preOpGas the gas used for validation (including preValidationGas)\n * @param prefund the required prefund for this operation\n * @param sigFailed validateUserOp's (or paymaster's) signature check failed\n * @param validAfter - first timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param validUntil - last timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param paymasterContext returned by validatePaymasterUserOp (to be passed into postOp)\n */\n struct ReturnInfo {\n uint256 preOpGas;\n uint256 prefund;\n bool sigFailed;\n uint48 validAfter;\n uint48 validUntil;\n bytes paymasterContext;\n }\n\n /**\n * returned aggregated signature info.\n * the aggregator returned by the account, and its current stake.\n */\n struct AggregatorStakeInfo {\n address aggregator;\n StakeInfo stakeInfo;\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes memory initCode) external;\n\n\n /**\n * simulate full execution of a UserOperation (including both validation and target execution)\n * this method will always revert with \"ExecutionResult\".\n * it performs full validation of the UserOperation, but ignores signature error.\n * an optional target address is called after the userop succeeds, and its value is returned\n * (before the entire call is reverted)\n * Note that in order to collect the the success/failure of the target call, it must be executed\n * with trace enabled to track the emitted events.\n * @param op the UserOperation to simulate\n * @param target if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult\n * are set to the return from that call.\n * @param targetCallData callData to pass to target address\n */\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external;\n}\n\n" - }, - "contracts/interfaces/INonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\ninterface INonceManager {\n\n /**\n * Return the next nonce for this sender.\n * Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop)\n * But UserOp with different keys can come with arbitrary order.\n *\n * @param sender the account address\n * @param key the high 192 bit of the nonce\n * @return nonce a full nonce to pass for next UserOp with this sender.\n */\n function getNonce(address sender, uint192 key)\n external view returns (uint256 nonce);\n\n /**\n * Manually increment the nonce of the sender.\n * This method is exposed just for completeness..\n * Account does NOT need to call it, neither during validation, nor elsewhere,\n * as the EntryPoint will update the nonce regardless.\n * Possible use-case is call it with various keys to \"initialize\" their nonces to one, so that future\n * UserOperations will not pay extra for the first transaction with a given key.\n */\n function incrementNonce(uint192 key) external;\n}\n" - }, - "contracts/interfaces/IPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * the interface exposed by a paymaster contract, who agrees to pay the gas for user's operations.\n * a paymaster must hold a stake to cover the required entrypoint stake and also the gas for the transaction.\n */\ninterface IPaymaster {\n\n enum PostOpMode {\n opSucceeded, // user op succeeded\n opReverted, // user op reverted. still has to pay for gas.\n postOpReverted //user op succeeded, but caused postOp to revert. Now it's a 2nd call, after user's op was deliberately reverted.\n }\n\n /**\n * payment validation: check if paymaster agrees to pay.\n * Must verify sender is the entryPoint.\n * Revert to reject this request.\n * Note that bundlers will reject this method if it changes the state, unless the paymaster is trusted (whitelisted)\n * The paymaster pre-pays using its deposit, and receive back a refund after the postOp method returns.\n * @param userOp the user operation\n * @param userOpHash hash of the user's request data.\n * @param maxCost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\n * @return context value to send to a postOp\n * zero length to signify postOp is not required.\n * @return validationData signature and time-range of this operation, encoded the same as the return value of validateUserOperation\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n external returns (bytes memory context, uint256 validationData);\n\n /**\n * post-operation handler.\n * Must verify sender is the entryPoint\n * @param mode enum with the following options:\n * opSucceeded - user operation succeeded.\n * opReverted - user op reverted. still has to pay for gas.\n * postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n * Now this is the 2nd call, after user's op was deliberately reverted.\n * @param context - the context value returned by validatePaymasterUserOp\n * @param actualGasCost - actual gas used so far (without this postOp call).\n */\n function postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) external;\n}\n" - }, - "contracts/interfaces/IStakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by the staked entity.\n */\ninterface IStakeManager {\n\n event Deposited(\n address indexed account,\n uint256 totalDeposit\n );\n\n event Withdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /// Emitted when stake or unstake delay are modified\n event StakeLocked(\n address indexed account,\n uint256 totalStaked,\n uint256 unstakeDelaySec\n );\n\n /// Emitted once a stake is scheduled for withdrawal\n event StakeUnlocked(\n address indexed account,\n uint256 withdrawTime\n );\n\n event StakeWithdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /**\n * @param deposit the entity's deposit\n * @param staked true if this entity is staked.\n * @param stake actual amount of ether staked for this entity.\n * @param unstakeDelaySec minimum delay to withdraw the stake.\n * @param withdrawTime - first block timestamp where 'withdrawStake' will be callable, or zero if already locked\n * @dev sizes were chosen so that (deposit,staked, stake) fit into one cell (used during handleOps)\n * and the rest fit into a 2nd cell.\n * 112 bit allows for 10^15 eth\n * 48 bit for full timestamp\n * 32 bit allows 150 years for unstake delay\n */\n struct DepositInfo {\n uint112 deposit;\n bool staked;\n uint112 stake;\n uint32 unstakeDelaySec;\n uint48 withdrawTime;\n }\n\n //API struct used by getStakeInfo and simulateValidation\n struct StakeInfo {\n uint256 stake;\n uint256 unstakeDelaySec;\n }\n\n /// @return info - full deposit information of given account\n function getDepositInfo(address account) external view returns (DepositInfo memory info);\n\n /// @return the deposit (for gas payment) of the account\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) external payable;\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param _unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 _unstakeDelaySec) external payable;\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external;\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external;\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external;\n}\n" - }, - "contracts/interfaces/UserOperation.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\nimport {calldataKeccak} from \"../core/Helpers.sol\";\n\n/**\n * User Operation struct\n * @param sender the sender account of this request.\n * @param nonce unique value the sender uses to verify it is not a replay.\n * @param initCode if set, the account contract will be created by this constructor/\n * @param callData the method call to execute on this account.\n * @param callGasLimit the gas limit passed to the callData method call.\n * @param verificationGasLimit gas used for validateUserOp and validatePaymasterUserOp.\n * @param preVerificationGas gas not calculated by the handleOps method, but added to the gas paid. Covers batch overhead.\n * @param maxFeePerGas same as EIP-1559 gas parameter.\n * @param maxPriorityFeePerGas same as EIP-1559 gas parameter.\n * @param paymasterAndData if set, this field holds the paymaster address and paymaster-specific data. the paymaster will pay for the transaction instead of the sender.\n * @param signature sender-verified signature over the entire request, the EntryPoint address and the chain ID.\n */\n struct UserOperation {\n\n address sender;\n uint256 nonce;\n bytes initCode;\n bytes callData;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n bytes paymasterAndData;\n bytes signature;\n }\n\n/**\n * Utility functions helpful when working with UserOperation structs.\n */\nlibrary UserOperationLib {\n\n function getSender(UserOperation calldata userOp) internal pure returns (address) {\n address data;\n //read sender from userOp, which is first userOp member (saves 800 gas...)\n assembly {data := calldataload(userOp)}\n return address(uint160(data));\n }\n\n //relayer/block builder might submit the TX with higher priorityFee, but the user should not\n // pay above what he signed for.\n function gasPrice(UserOperation calldata userOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n address sender = getSender(userOp);\n uint256 nonce = userOp.nonce;\n bytes32 hashInitCode = calldataKeccak(userOp.initCode);\n bytes32 hashCallData = calldataKeccak(userOp.callData);\n uint256 callGasLimit = userOp.callGasLimit;\n uint256 verificationGasLimit = userOp.verificationGasLimit;\n uint256 preVerificationGas = userOp.preVerificationGas;\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes32 hashPaymasterAndData = calldataKeccak(userOp.paymasterAndData);\n\n return abi.encode(\n sender, nonce,\n hashInitCode, hashCallData,\n callGasLimit, verificationGasLimit, preVerificationGas,\n maxFeePerGas, maxPriorityFeePerGas,\n hashPaymasterAndData\n );\n }\n\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\n return keccak256(pack(userOp));\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n}\n" - }, - "contracts/utils/Exec.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.5 <0.9.0;\n\n// solhint-disable no-inline-assembly\n\n/**\n * Utility functions helpful when making different kinds of contract calls in Solidity.\n */\nlibrary Exec {\n\n function call(\n address to,\n uint256 value,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function staticcall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal view returns (bool success) {\n assembly {\n success := staticcall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function delegateCall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n // get returned data from last call or calldelegate\n function getReturnData(uint256 maxLen) internal pure returns (bytes memory returnData) {\n assembly {\n let len := returndatasize()\n if gt(len, maxLen) {\n len := maxLen\n }\n let ptr := mload(0x40)\n mstore(0x40, add(ptr, add(len, 0x20)))\n mstore(ptr, len)\n returndatacopy(add(ptr, 0x20), 0, len)\n returnData := ptr\n }\n }\n\n // revert with explicit byte array (probably reverted info from call)\n function revertWithData(bytes memory returnData) internal pure {\n assembly {\n revert(add(returnData, 32), mload(returnData))\n }\n }\n\n function callAndRevert(address to, bytes memory data, uint256 maxLen) internal {\n bool success = call(to,0,data,gasleft());\n if (!success) {\n revertWithData(getReturnData(maxLen));\n }\n }\n}\n" - } - }, - "settings": { - "optimizer": { - "enabled": true, - "runs": 1000000 - }, - "viaIR": true, - "outputSelection": { - "*": { - "*": [ - "abi", - "evm.bytecode", - "evm.deployedBytecode", - "evm.methodIdentifiers", - "metadata" - ], - "": [ - "ast" - ] - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/sepolia/.chainId b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/sepolia/.chainId deleted file mode 100644 index bd8d1cd44c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/sepolia/.chainId +++ /dev/null @@ -1 +0,0 @@ -11155111 \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/sepolia/EntryPoint.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/sepolia/EntryPoint.json deleted file mode 100644 index 916c239083..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/sepolia/EntryPoint.json +++ /dev/null @@ -1,1318 +0,0 @@ -{ - "address": "0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789", - "abi": [ - { - "inputs": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "paid", - "type": "uint256" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bool", - "name": "targetSuccess", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "targetResult", - "type": "bytes" - } - ], - "name": "ExecutionResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "opIndex", - "type": "uint256" - }, - { - "internalType": "string", - "name": "reason", - "type": "string" - } - ], - "name": "FailedOp", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - } - ], - "name": "SenderAddressResult", - "type": "error" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureValidationFailed", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - } - ], - "name": "ValidationResult", - "type": "error" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "sigFailed", - "type": "bool" - }, - { - "internalType": "uint48", - "name": "validAfter", - "type": "uint48" - }, - { - "internalType": "uint48", - "name": "validUntil", - "type": "uint48" - }, - { - "internalType": "bytes", - "name": "paymasterContext", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.ReturnInfo", - "name": "returnInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "senderInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "factoryInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "paymasterInfo", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "aggregator", - "type": "address" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "stake", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "internalType": "struct IStakeManager.StakeInfo", - "name": "stakeInfo", - "type": "tuple" - } - ], - "internalType": "struct IEntryPoint.AggregatorStakeInfo", - "name": "aggregatorInfo", - "type": "tuple" - } - ], - "name": "ValidationResultWithAggregation", - "type": "error" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "factory", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "paymaster", - "type": "address" - } - ], - "name": "AccountDeployed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [], - "name": "BeforeExecution", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalDeposit", - "type": "uint256" - } - ], - "name": "Deposited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "aggregator", - "type": "address" - } - ], - "name": "SignatureAggregatorChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "totalStaked", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "unstakeDelaySec", - "type": "uint256" - } - ], - "name": "StakeLocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "withdrawTime", - "type": "uint256" - } - ], - "name": "StakeUnlocked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "StakeWithdrawn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "actualGasUsed", - "type": "uint256" - } - ], - "name": "UserOperationEvent", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "indexed": true, - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "revertReason", - "type": "bytes" - } - ], - "name": "UserOperationRevertReason", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "account", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "withdrawAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "Withdrawn", - "type": "event" - }, - { - "inputs": [], - "name": "SIG_VALIDATION_FAILED", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - } - ], - "name": "_validateSenderAndPaymaster", - "outputs": [], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - } - ], - "name": "addStake", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "depositTo", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "deposits", - "outputs": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "account", - "type": "address" - } - ], - "name": "getDepositInfo", - "outputs": [ - { - "components": [ - { - "internalType": "uint112", - "name": "deposit", - "type": "uint112" - }, - { - "internalType": "bool", - "name": "staked", - "type": "bool" - }, - { - "internalType": "uint112", - "name": "stake", - "type": "uint112" - }, - { - "internalType": "uint32", - "name": "unstakeDelaySec", - "type": "uint32" - }, - { - "internalType": "uint48", - "name": "withdrawTime", - "type": "uint48" - } - ], - "internalType": "struct IStakeManager.DepositInfo", - "name": "info", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "getNonce", - "outputs": [ - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - } - ], - "name": "getSenderAddress", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "getUserOpHash", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "userOps", - "type": "tuple[]" - }, - { - "internalType": "contract IAggregator", - "name": "aggregator", - "type": "address" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct IEntryPoint.UserOpsPerAggregator[]", - "name": "opsPerAggregator", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleAggregatedOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation[]", - "name": "ops", - "type": "tuple[]" - }, - { - "internalType": "address payable", - "name": "beneficiary", - "type": "address" - } - ], - "name": "handleOps", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint192", - "name": "key", - "type": "uint192" - } - ], - "name": "incrementNonce", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "components": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "address", - "name": "paymaster", - "type": "address" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.MemoryUserOp", - "name": "mUserOp", - "type": "tuple" - }, - { - "internalType": "bytes32", - "name": "userOpHash", - "type": "bytes32" - }, - { - "internalType": "uint256", - "name": "prefund", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "contextOffset", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preOpGas", - "type": "uint256" - } - ], - "internalType": "struct EntryPoint.UserOpInfo", - "name": "opInfo", - "type": "tuple" - }, - { - "internalType": "bytes", - "name": "context", - "type": "bytes" - } - ], - "name": "innerHandleOp", - "outputs": [ - { - "internalType": "uint256", - "name": "actualGasCost", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - }, - { - "internalType": "uint192", - "name": "", - "type": "uint192" - } - ], - "name": "nonceSequenceNumber", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "op", - "type": "tuple" - }, - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "targetCallData", - "type": "bytes" - } - ], - "name": "simulateHandleOp", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "sender", - "type": "address" - }, - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "initCode", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "callGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "verificationGasLimit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "preVerificationGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxFeePerGas", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxPriorityFeePerGas", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "paymasterAndData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - } - ], - "internalType": "struct UserOperation", - "name": "userOp", - "type": "tuple" - } - ], - "name": "simulateValidation", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "unlockStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - } - ], - "name": "withdrawStake", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "withdrawAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "withdrawAmount", - "type": "uint256" - } - ], - "name": "withdrawTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "args": [], - "numDeployments": 1, - "solcInputHash": "a4c52f0671aad8941c53d6ead2063803", - "metadata": "{\"compiler\":{\"version\":\"0.8.17+commit.8df45f5f\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"paid\",\"type\":\"uint256\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bool\",\"name\":\"targetSuccess\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"targetResult\",\"type\":\"bytes\"}],\"name\":\"ExecutionResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"opIndex\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\"}],\"name\":\"FailedOp\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderAddressResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureValidationFailed\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResult\",\"type\":\"error\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"sigFailed\",\"type\":\"bool\"},{\"internalType\":\"uint48\",\"name\":\"validAfter\",\"type\":\"uint48\"},{\"internalType\":\"uint48\",\"name\":\"validUntil\",\"type\":\"uint48\"},{\"internalType\":\"bytes\",\"name\":\"paymasterContext\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.ReturnInfo\",\"name\":\"returnInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"senderInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"factoryInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"paymasterInfo\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"stake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"internalType\":\"struct IStakeManager.StakeInfo\",\"name\":\"stakeInfo\",\"type\":\"tuple\"}],\"internalType\":\"struct IEntryPoint.AggregatorStakeInfo\",\"name\":\"aggregatorInfo\",\"type\":\"tuple\"}],\"name\":\"ValidationResultWithAggregation\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"factory\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"}],\"name\":\"AccountDeployed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"BeforeExecution\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalDeposit\",\"type\":\"uint256\"}],\"name\":\"Deposited\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"aggregator\",\"type\":\"address\"}],\"name\":\"SignatureAggregatorChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalStaked\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"unstakeDelaySec\",\"type\":\"uint256\"}],\"name\":\"StakeLocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"withdrawTime\",\"type\":\"uint256\"}],\"name\":\"StakeUnlocked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"StakeWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"actualGasUsed\",\"type\":\"uint256\"}],\"name\":\"UserOperationEvent\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"revertReason\",\"type\":\"bytes\"}],\"name\":\"UserOperationRevertReason\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Withdrawn\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"SIG_VALIDATION_FAILED\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"}],\"name\":\"_validateSenderAndPaymaster\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"}],\"name\":\"addStake\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"depositTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"deposits\",\"outputs\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getDepositInfo\",\"outputs\":[{\"components\":[{\"internalType\":\"uint112\",\"name\":\"deposit\",\"type\":\"uint112\"},{\"internalType\":\"bool\",\"name\":\"staked\",\"type\":\"bool\"},{\"internalType\":\"uint112\",\"name\":\"stake\",\"type\":\"uint112\"},{\"internalType\":\"uint32\",\"name\":\"unstakeDelaySec\",\"type\":\"uint32\"},{\"internalType\":\"uint48\",\"name\":\"withdrawTime\",\"type\":\"uint48\"}],\"internalType\":\"struct IStakeManager.DepositInfo\",\"name\":\"info\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"}],\"name\":\"getSenderAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"getUserOpHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"userOps\",\"type\":\"tuple[]\"},{\"internalType\":\"contract IAggregator\",\"name\":\"aggregator\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct IEntryPoint.UserOpsPerAggregator[]\",\"name\":\"opsPerAggregator\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleAggregatedOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation[]\",\"name\":\"ops\",\"type\":\"tuple[]\"},{\"internalType\":\"address payable\",\"name\":\"beneficiary\",\"type\":\"address\"}],\"name\":\"handleOps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint192\",\"name\":\"key\",\"type\":\"uint192\"}],\"name\":\"incrementNonce\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymaster\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.MemoryUserOp\",\"name\":\"mUserOp\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"userOpHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"prefund\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"contextOffset\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preOpGas\",\"type\":\"uint256\"}],\"internalType\":\"struct EntryPoint.UserOpInfo\",\"name\":\"opInfo\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"context\",\"type\":\"bytes\"}],\"name\":\"innerHandleOp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"actualGasCost\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"\",\"type\":\"uint192\"}],\"name\":\"nonceSequenceNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"op\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"targetCallData\",\"type\":\"bytes\"}],\"name\":\"simulateHandleOp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"callGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"verificationGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"preVerificationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPriorityFeePerGas\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"paymasterAndData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"internalType\":\"struct UserOperation\",\"name\":\"userOp\",\"type\":\"tuple\"}],\"name\":\"simulateValidation\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unlockStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"}],\"name\":\"withdrawStake\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"withdrawAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"withdrawAmount\",\"type\":\"uint256\"}],\"name\":\"withdrawTo\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"errors\":{\"FailedOp(uint256,string)\":[{\"params\":{\"opIndex\":\"- index into the array of ops to the failed one (in simulateValidation, this is always zero)\",\"reason\":\"- revert reason The string starts with a unique code \\\"AAmn\\\", where \\\"m\\\" is \\\"1\\\" for factory, \\\"2\\\" for account and \\\"3\\\" for paymaster issues, so a failure can be attributed to the correct entity. Should be caught in off-chain handleOps simulation and not happen on-chain. Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\"}}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"params\":{\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"params\":{\"aggregatorInfo\":\"signature aggregation info (if the account requires signature aggregator) bundler MUST use it to verify the signature, or reject the UserOperation\",\"factoryInfo\":\"stake information about the factory (if any)\",\"paymasterInfo\":\"stake information about the paymaster (if any)\",\"returnInfo\":\"gas and time-range returned values\",\"senderInfo\":\"stake information about the sender\"}}]},\"kind\":\"dev\",\"methods\":{\"addStake(uint32)\":{\"params\":{\"unstakeDelaySec\":\"the new lock duration before the deposit can be withdrawn.\"}},\"getDepositInfo(address)\":{\"returns\":{\"info\":\"- full deposit information of given account\"}},\"getNonce(address,uint192)\":{\"params\":{\"key\":\"the high 192 bit of the nonce\",\"sender\":\"the account address\"},\"returns\":{\"nonce\":\"a full nonce to pass for next UserOp with this sender.\"}},\"getSenderAddress(bytes)\":{\"params\":{\"initCode\":\"the constructor code to be passed into the UserOperation.\"}},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"opsPerAggregator\":\"the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\"}},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"params\":{\"beneficiary\":\"the address to receive the fees\",\"ops\":\"the operations to execute\"}},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"params\":{\"op\":\"the UserOperation to simulate\",\"target\":\"if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult are set to the return from that call.\",\"targetCallData\":\"callData to pass to target address\"}},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"details\":\"this method always revert. Successful result is ValidationResult error. other errors are failures.The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\",\"params\":{\"userOp\":\"the user operation to validate.\"}},\"withdrawStake(address)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\"}},\"withdrawTo(address,uint256)\":{\"params\":{\"withdrawAddress\":\"the address to send withdrawn value.\",\"withdrawAmount\":\"the amount to withdraw.\"}}},\"version\":1},\"userdoc\":{\"errors\":{\"ExecutionResult(uint256,uint256,uint48,uint48,bool,bytes)\":[{\"notice\":\"return value of simulateHandleOp\"}],\"FailedOp(uint256,string)\":[{\"notice\":\"a custom revert error of handleOps, to identify the offending op. NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\"}],\"SenderAddressResult(address)\":[{\"notice\":\"return value of getSenderAddress\"}],\"SignatureValidationFailed(address)\":[{\"notice\":\"error case when a signature aggregator fails to verify the aggregated signature it had created.\"}],\"ValidationResult((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256))\":[{\"notice\":\"Successful result from simulateValidation.\"}],\"ValidationResultWithAggregation((uint256,uint256,bool,uint48,uint48,bytes),(uint256,uint256),(uint256,uint256),(uint256,uint256),(address,(uint256,uint256)))\":[{\"notice\":\"Successful result from simulateValidation, if the account returns a signature aggregator\"}]},\"events\":{\"AccountDeployed(bytes32,address,address,address)\":{\"notice\":\"account \\\"sender\\\" was deployed.\"},\"BeforeExecution()\":{\"notice\":\"an event emitted by handleOps(), before starting the execution loop. any event emitted before this event, is part of the validation.\"},\"SignatureAggregatorChanged(address)\":{\"notice\":\"signature aggregator used by the following UserOperationEvents within this bundle.\"},\"StakeLocked(address,uint256,uint256)\":{\"notice\":\"Emitted when stake or unstake delay are modified\"},\"StakeUnlocked(address,uint256)\":{\"notice\":\"Emitted once a stake is scheduled for withdrawal\"},\"UserOperationRevertReason(bytes32,address,uint256,bytes)\":{\"notice\":\"An event emitted if the UserOperation \\\"callData\\\" reverted with non-zero length\"}},\"kind\":\"user\",\"methods\":{\"SIG_VALIDATION_FAILED()\":{\"notice\":\"for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value in case of signature failure, instead of revert.\"},\"_validateSenderAndPaymaster(bytes,address,bytes)\":{\"notice\":\"Called only during simulation. This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\"},\"addStake(uint32)\":{\"notice\":\"add to the account's stake - amount and delay any pending unstake is first cancelled.\"},\"balanceOf(address)\":{\"notice\":\"return the deposit (for gas payment) of the account\"},\"depositTo(address)\":{\"notice\":\"add to the deposit of the given account\"},\"deposits(address)\":{\"notice\":\"maps paymaster to their deposits and stakes\"},\"getNonce(address,uint192)\":{\"notice\":\"Return the next nonce for this sender. Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop) But UserOp with different keys can come with arbitrary order.\"},\"getSenderAddress(bytes)\":{\"notice\":\"Get counterfactual sender address. Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation. this method always revert, and returns the address in SenderAddressResult error\"},\"getUserOpHash((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"generate a request Id - unique identifier for this request. the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\"},\"handleAggregatedOps(((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperation with Aggregators\"},\"handleOps((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)[],address)\":{\"notice\":\"Execute a batch of UserOperations. no signature aggregator is used. if any account requires an aggregator (that is, it returned an aggregator when performing simulateValidation), then handleAggregatedOps() must be used instead.\"},\"incrementNonce(uint192)\":{\"notice\":\"Manually increment the nonce of the sender. This method is exposed just for completeness.. Account does NOT need to call it, neither during validation, nor elsewhere, as the EntryPoint will update the nonce regardless. Possible use-case is call it with various keys to \\\"initialize\\\" their nonces to one, so that future UserOperations will not pay extra for the first transaction with a given key.\"},\"innerHandleOp(bytes,((address,uint256,uint256,uint256,uint256,address,uint256,uint256),bytes32,uint256,uint256,uint256),bytes)\":{\"notice\":\"inner function to handle a UserOperation. Must be declared \\\"external\\\" to open a call context, but it can only be called by handleOps.\"},\"nonceSequenceNumber(address,uint192)\":{\"notice\":\"The next valid sequence number for a given nonce key.\"},\"simulateHandleOp((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes),address,bytes)\":{\"notice\":\"simulate full execution of a UserOperation (including both validation and target execution) this method will always revert with \\\"ExecutionResult\\\". it performs full validation of the UserOperation, but ignores signature error. an optional target address is called after the userop succeeds, and its value is returned (before the entire call is reverted) Note that in order to collect the the success/failure of the target call, it must be executed with trace enabled to track the emitted events.\"},\"simulateValidation((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes))\":{\"notice\":\"Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\"},\"unlockStake()\":{\"notice\":\"attempt to unlock the stake. the value can be withdrawn (using withdrawStake) after the unstake delay.\"},\"withdrawStake(address)\":{\"notice\":\"withdraw from the (unlocked) stake. must first call unlockStake and wait for the unstakeDelay to pass\"},\"withdrawTo(address,uint256)\":{\"notice\":\"withdraw from the deposit.\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/core/EntryPoint.sol\":\"EntryPoint\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":1000000},\"remappings\":[],\"viaIR\":true},\"sources\":{\"@openzeppelin/contracts/security/ReentrancyGuard.sol\":{\"keccak256\":\"0x190dd6f8d592b7e4e930feb7f4313aeb8e1c4ad3154c27ce1cf6a512fc30d8cc\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://4ce8dfb62d0c4fa260d6eec8f1cd47f5f2a044e11bde5b31d18072fa6e7d9010\",\"dweb:/ipfs/QmTyFztU3tLEcEDnqqiaW4UJetqsU77LXc6pjc9oTXCK5u\"]},\"contracts/core/EntryPoint.sol\":{\"keccak256\":\"0x04f86318b47f052d7308795ffae6ecec0d023d2458b4e17751b89a0e4acfcdc6\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://c9f6e359c8dbe875ad974d3a0fb7b3d62319a6b115c44bac1e4587ae2ad2edaf\",\"dweb:/ipfs/QmTSWTov2rUeYk8cwzrtsd3uVXokCYok4gMiZ1sPs9tycH\"]},\"contracts/core/Helpers.sol\":{\"keccak256\":\"0x591c87519f7155d1909210276b77925ab2722a99b7b5d5649aecc36ebbdb045a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://69643e83f68e6a13d5075c7565bfce326673b0bd98c432033c4603ea84835746\",\"dweb:/ipfs/QmSwSzjYyV7qudi5vvsmzHMG2Z4YJZxX51RRXXVCLaNcEU\"]},\"contracts/core/NonceManager.sol\":{\"keccak256\":\"0xa17a4a6fde70088ab18ffe6df830f3efa31f1cd0e1a7160336c96e3c94984d25\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://b38615df9f80c56282b72888e9ba1eb1a9413fa67a0dbf094deda7af9feb38e7\",\"dweb:/ipfs/QmSzcXetEJRH4UHuUmZiSgX6bFgfqHWfmyuxVnh4NosMk1\"]},\"contracts/core/SenderCreator.sol\":{\"keccak256\":\"0x44b9449fec82d6cdfb01d52fdd5a72f90099c651316123810cf9633f00b018c2\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a9c0487390e72638681d175c45bc92425c802fffdca4bd0ae8457782ee284612\",\"dweb:/ipfs/QmVbzuehCUWJWqEHyMWuc6cRVbxfcMdFsmGL9o4Wz7WY2x\"]},\"contracts/core/StakeManager.sol\":{\"keccak256\":\"0x21aa0956382bd000b1b8c3b1d19ca6ebcd6c9029eebb19c612fb38ee5dd2430a\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://0a625c8795354d9f429367f9c1d14eb8af7db9c7f2c2a2033e2066ced76a573a\",\"dweb:/ipfs/Qmd1j6UarUg54q1G2HCNCLQz8XGVZR1qxX7eQ6cytHpQPN\"]},\"contracts/interfaces/IAccount.sol\":{\"keccak256\":\"0x556a0e5980de18e90b115553ed502408155ba35f58642823010d9288047bc418\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://a0f420134b79596db8737173c7b933ae0a33059e107b6327c43aa40d4744a9e4\",\"dweb:/ipfs/QmRo8s1AhXmEMV7uPYnbpYwU19e9Bk6jmYBJTiPx3Fo85W\"]},\"contracts/interfaces/IAggregator.sol\":{\"keccak256\":\"0x060e9ddb0152250c269ba0640dc5753834ac44cf182a2837d508c0c529cae26a\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://20ed837bc5909c89ff1910246bf245a5dad6840aa939382e1694964eb7dbd37b\",\"dweb:/ipfs/QmTMybRq5yyghPDDs1ZCNAVB9sSJ4WHe6Q9mejuKPTAdNP\"]},\"contracts/interfaces/IEntryPoint.sol\":{\"keccak256\":\"0x3a90bf308819ed125fa4202f880999caff8a8686633b8ddb79a30ca240d5b8f8\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://d2d21cc92c2fdab2b58d21bc25d4cd0e8c284b922528a186b087b818d54bc6cf\",\"dweb:/ipfs/QmT1qrfuBjsv2rmRCDn8mgPXHp94hARJwzbcDuBLDTbFWd\"]},\"contracts/interfaces/INonceManager.sol\":{\"keccak256\":\"0x509871e6c63663cdcc3eba19920fe84e991f38b289b1377ac3c3a6d9f22d7e12\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://00fe21b4349b24c50df60e1a705179293982bd9e7a32b78d4bac9620f89e7fe2\",\"dweb:/ipfs/QmSFFYGfUwQbVa6hASjU7YxTvgi2HkfrPr4X5oPHscHg8b\"]},\"contracts/interfaces/IPaymaster.sol\":{\"keccak256\":\"0x36858ba8685024974f533530420688da3454d29996ebc42e410673a1ed2ec456\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://616cbcf51778b1961b7f20a547bec7efae6d1d565df0f651926241ed8bde9ad8\",\"dweb:/ipfs/QmaVsgffUUmeUJYgStvRr8cNZ1LBbrc3FYNLW4JT1dVLia\"]},\"contracts/interfaces/IStakeManager.sol\":{\"keccak256\":\"0xd227b02888cd4ac68daebcdfd992ec00f9fff66fa3b3bb16f656cd582fa3480f\",\"license\":\"GPL-3.0-only\",\"urls\":[\"bzz-raw://b389da4714a138be63704a576a482505eab2855e263b38a93706395d8d42e7c3\",\"dweb:/ipfs/QmeeAZpdHwUXxqP8pxA7GNtoCGBmmH4FaqLLwScVKGxtxZ\"]},\"contracts/interfaces/UserOperation.sol\":{\"keccak256\":\"0x61374003361059087fdcf17967a7bba052badeaf5c7f0ae689166f8aafd3a45c\",\"license\":\"GPL-3.0\",\"urls\":[\"bzz-raw://6ff83c59432e733bf6304dda27cd4b0f34401917dd535e2669cc842d2d26568c\",\"dweb:/ipfs/QmPJbHU5TAjHqUTZzAcicEeG2nknmwCN43L4EW9LHbknTN\"]},\"contracts/utils/Exec.sol\":{\"keccak256\":\"0x5b232117afbc2939f3ffc92745614867e9e1d475a3e1e5443adae13c200174f1\",\"license\":\"LGPL-3.0-only\",\"urls\":[\"bzz-raw://62e7365379a06ead7b47637945bcaee095d51aab1d3ac00ddec69443e6cbe9fe\",\"dweb:/ipfs/QmctG3aw4U3KMSMeJKoLJ1NJewjMWfppnd1m3kxNTe39Uy\"]}},\"version\":1}", - "bytecode": "0x60a080604052346200008957600160025561022c8181016001600160401b038111838210176200007357829162005d18833903906000f080156200006757608052604051615c8990816200008f82396080518181816113df01528181613e9501526141b60152f35b6040513d6000823e3d90fd5b634e487b7160e01b600052604160045260246000fd5b600080fdfe60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c634300081100336080806040523461001657610210908161001c8239f35b600080fdfe6080604052600436101561001257600080fd5b6000803560e01c63570e1a361461002857600080fd5b346100c95760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126100c95760043567ffffffffffffffff918282116100c957366023830112156100c95781600401359283116100c95736602484840101116100c9576100c561009e84602485016100fc565b60405173ffffffffffffffffffffffffffffffffffffffff90911681529081906020820190565b0390f35b80fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b90806014116101bb5767ffffffffffffffff917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec82018381116101cd575b604051937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f81600b8701160116850190858210908211176101c0575b604052808452602084019036848401116101bb576020946000600c819682946014880187378301015251923560601c5af19060005191156101b557565b60009150565b600080fd5b6101c86100cc565b610178565b6101d56100cc565b61013a56fea26469706673582212201927e80b76ab9b71c952137dd676621a9fdf520c25928815636594036eb1c40364736f6c63430008110033", - "deployedBytecode": "0x60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c63430008110033" -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/sepolia/solcInputs/a4c52f0671aad8941c53d6ead2063803.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/sepolia/solcInputs/a4c52f0671aad8941c53d6ead2063803.json deleted file mode 100644 index dd58ba5a3e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/deployments/sepolia/solcInputs/a4c52f0671aad8941c53d6ead2063803.json +++ /dev/null @@ -1,68 +0,0 @@ -{ - "language": "Solidity", - "sources": { - "@openzeppelin/contracts/security/ReentrancyGuard.sol": { - "content": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.8.0) (security/ReentrancyGuard.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Contract module that helps prevent reentrant calls to a function.\n *\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\n * available, which can be applied to functions to make sure there are no nested\n * (reentrant) calls to them.\n *\n * Note that because there is a single `nonReentrant` guard, functions marked as\n * `nonReentrant` may not call one another. This can be worked around by making\n * those functions `private`, and then adding `external` `nonReentrant` entry\n * points to them.\n *\n * TIP: If you would like to learn more about reentrancy and alternative ways\n * to protect against it, check out our blog post\n * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].\n */\nabstract contract ReentrancyGuard {\n // Booleans are more expensive than uint256 or any type that takes up a full\n // word because each write operation emits an extra SLOAD to first read the\n // slot's contents, replace the bits taken up by the boolean, and then write\n // back. This is the compiler's defense against contract upgrades and\n // pointer aliasing, and it cannot be disabled.\n\n // The values being non-zero value makes deployment a bit more expensive,\n // but in exchange the refund on every call to nonReentrant will be lower in\n // amount. Since refunds are capped to a percentage of the total\n // transaction's gas, it is best to keep them low in cases like this one, to\n // increase the likelihood of the full refund coming into effect.\n uint256 private constant _NOT_ENTERED = 1;\n uint256 private constant _ENTERED = 2;\n\n uint256 private _status;\n\n constructor() {\n _status = _NOT_ENTERED;\n }\n\n /**\n * @dev Prevents a contract from calling itself, directly or indirectly.\n * Calling a `nonReentrant` function from another `nonReentrant`\n * function is not supported. It is possible to prevent this from happening\n * by making the `nonReentrant` function external, and making it call a\n * `private` function that does the actual work.\n */\n modifier nonReentrant() {\n _nonReentrantBefore();\n _;\n _nonReentrantAfter();\n }\n\n function _nonReentrantBefore() private {\n // On the first call to nonReentrant, _status will be _NOT_ENTERED\n require(_status != _ENTERED, \"ReentrancyGuard: reentrant call\");\n\n // Any calls to nonReentrant after this point will fail\n _status = _ENTERED;\n }\n\n function _nonReentrantAfter() private {\n // By storing the original value once again, a refund is triggered (see\n // https://eips.ethereum.org/EIPS/eip-2200)\n _status = _NOT_ENTERED;\n }\n}\n" - }, - "contracts/core/EntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n\nimport \"../interfaces/IAccount.sol\";\nimport \"../interfaces/IPaymaster.sol\";\nimport \"../interfaces/IEntryPoint.sol\";\n\nimport \"../utils/Exec.sol\";\nimport \"./StakeManager.sol\";\nimport \"./SenderCreator.sol\";\nimport \"./Helpers.sol\";\nimport \"./NonceManager.sol\";\nimport \"@openzeppelin/contracts/security/ReentrancyGuard.sol\";\n\ncontract EntryPoint is IEntryPoint, StakeManager, NonceManager, ReentrancyGuard {\n\n using UserOperationLib for UserOperation;\n\n SenderCreator private immutable senderCreator = new SenderCreator();\n\n // internal value used during simulation: need to query aggregator.\n address private constant SIMULATE_FIND_AGGREGATOR = address(1);\n\n // marker for inner call revert on out of gas\n bytes32 private constant INNER_OUT_OF_GAS = hex'deaddead';\n\n uint256 private constant REVERT_REASON_MAX_LEN = 2048;\n\n /**\n * for simulation purposes, validateUserOp (and validatePaymasterUserOp) must return this value\n * in case of signature failure, instead of revert.\n */\n uint256 public constant SIG_VALIDATION_FAILED = 1;\n\n /**\n * compensate the caller's beneficiary address with the collected fees of all UserOperations.\n * @param beneficiary the address to receive the fees\n * @param amount amount to transfer.\n */\n function _compensate(address payable beneficiary, uint256 amount) internal {\n require(beneficiary != address(0), \"AA90 invalid beneficiary\");\n (bool success,) = beneficiary.call{value : amount}(\"\");\n require(success, \"AA91 failed send to beneficiary\");\n }\n\n /**\n * execute a user op\n * @param opIndex index into the opInfo array\n * @param userOp the userOp to execute\n * @param opInfo the opInfo filled by validatePrepayment for this userOp.\n * @return collected the total amount this userOp paid.\n */\n function _executeUserOp(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory opInfo) private returns (uint256 collected) {\n uint256 preGas = gasleft();\n bytes memory context = getMemoryBytesFromOffset(opInfo.contextOffset);\n\n try this.innerHandleOp(userOp.callData, opInfo, context) returns (uint256 _actualGasCost) {\n collected = _actualGasCost;\n } catch {\n bytes32 innerRevertCode;\n assembly {\n returndatacopy(0, 0, 32)\n innerRevertCode := mload(0)\n }\n // handleOps was called with gas limit too low. abort entire bundle.\n if (innerRevertCode == INNER_OUT_OF_GAS) {\n //report paymaster, since if it is not deliberately caused by the bundler,\n // it must be a revert caused by paymaster.\n revert FailedOp(opIndex, \"AA95 out of gas\");\n }\n\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n collected = _handlePostOp(opIndex, IPaymaster.PostOpMode.postOpReverted, opInfo, context, actualGas);\n }\n }\n\n /**\n * Execute a batch of UserOperations.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) public nonReentrant {\n\n uint256 opslen = ops.length;\n UserOpInfo[] memory opInfos = new UserOpInfo[](opslen);\n\n unchecked {\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[i];\n (uint256 validationData, uint256 pmValidationData) = _validatePrepayment(i, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, pmValidationData, address(0));\n }\n\n uint256 collected = 0;\n emit BeforeExecution();\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(i, ops[i], opInfos[i]);\n }\n\n _compensate(beneficiary, collected);\n } //unchecked\n }\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) public nonReentrant {\n\n uint256 opasLen = opsPerAggregator.length;\n uint256 totalOps = 0;\n for (uint256 i = 0; i < opasLen; i++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[i];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n //address(1) is special marker of \"signature error\"\n require(address(aggregator) != address(1), \"AA96 invalid aggregator\");\n\n if (address(aggregator) != address(0)) {\n // solhint-disable-next-line no-empty-blocks\n try aggregator.validateSignatures(ops, opa.signature) {}\n catch {\n revert SignatureValidationFailed(address(aggregator));\n }\n }\n\n totalOps += ops.length;\n }\n\n UserOpInfo[] memory opInfos = new UserOpInfo[](totalOps);\n\n emit BeforeExecution();\n\n uint256 opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n UserOperation[] calldata ops = opa.userOps;\n IAggregator aggregator = opa.aggregator;\n\n uint256 opslen = ops.length;\n for (uint256 i = 0; i < opslen; i++) {\n UserOpInfo memory opInfo = opInfos[opIndex];\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(opIndex, ops[i], opInfo);\n _validateAccountAndPaymasterValidationData(i, validationData, paymasterValidationData, address(aggregator));\n opIndex++;\n }\n }\n\n uint256 collected = 0;\n opIndex = 0;\n for (uint256 a = 0; a < opasLen; a++) {\n UserOpsPerAggregator calldata opa = opsPerAggregator[a];\n emit SignatureAggregatorChanged(address(opa.aggregator));\n UserOperation[] calldata ops = opa.userOps;\n uint256 opslen = ops.length;\n\n for (uint256 i = 0; i < opslen; i++) {\n collected += _executeUserOp(opIndex, ops[i], opInfos[opIndex]);\n opIndex++;\n }\n }\n emit SignatureAggregatorChanged(address(0));\n\n _compensate(beneficiary, collected);\n }\n\n /// @inheritdoc IEntryPoint\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external override {\n\n UserOpInfo memory opInfo;\n _simulationOnlyValidations(op);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, op, opInfo);\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n\n numberMarker();\n uint256 paid = _executeUserOp(0, op, opInfo);\n numberMarker();\n bool targetSuccess;\n bytes memory targetResult;\n if (target != address(0)) {\n (targetSuccess, targetResult) = target.call(targetCallData);\n }\n revert ExecutionResult(opInfo.preOpGas, paid, data.validAfter, data.validUntil, targetSuccess, targetResult);\n }\n\n\n // A memory copy of UserOp static fields only.\n // Excluding: callData, initCode and signature. Replacing paymasterAndData with paymaster.\n struct MemoryUserOp {\n address sender;\n uint256 nonce;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n address paymaster;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n }\n\n struct UserOpInfo {\n MemoryUserOp mUserOp;\n bytes32 userOpHash;\n uint256 prefund;\n uint256 contextOffset;\n uint256 preOpGas;\n }\n\n /**\n * inner function to handle a UserOperation.\n * Must be declared \"external\" to open a call context, but it can only be called by handleOps.\n */\n function innerHandleOp(bytes memory callData, UserOpInfo memory opInfo, bytes calldata context) external returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n require(msg.sender == address(this), \"AA92 internal call only\");\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n\n uint callGasLimit = mUserOp.callGasLimit;\n unchecked {\n // handleOps was called with gas limit too low. abort entire bundle.\n if (gasleft() < callGasLimit + mUserOp.verificationGasLimit + 5000) {\n assembly {\n mstore(0, INNER_OUT_OF_GAS)\n revert(0, 32)\n }\n }\n }\n\n IPaymaster.PostOpMode mode = IPaymaster.PostOpMode.opSucceeded;\n if (callData.length > 0) {\n bool success = Exec.call(mUserOp.sender, 0, callData, callGasLimit);\n if (!success) {\n bytes memory result = Exec.getReturnData(REVERT_REASON_MAX_LEN);\n if (result.length > 0) {\n emit UserOperationRevertReason(opInfo.userOpHash, mUserOp.sender, mUserOp.nonce, result);\n }\n mode = IPaymaster.PostOpMode.opReverted;\n }\n }\n\n unchecked {\n uint256 actualGas = preGas - gasleft() + opInfo.preOpGas;\n //note: opIndex is ignored (relevant only if mode==postOpReverted, which is only possible outside of innerHandleOp)\n return _handlePostOp(0, mode, opInfo, context, actualGas);\n }\n }\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) public view returns (bytes32) {\n return keccak256(abi.encode(userOp.hash(), address(this), block.chainid));\n }\n\n /**\n * copy general fields from userOp into the memory opInfo structure.\n */\n function _copyUserOpToMemory(UserOperation calldata userOp, MemoryUserOp memory mUserOp) internal pure {\n mUserOp.sender = userOp.sender;\n mUserOp.nonce = userOp.nonce;\n mUserOp.callGasLimit = userOp.callGasLimit;\n mUserOp.verificationGasLimit = userOp.verificationGasLimit;\n mUserOp.preVerificationGas = userOp.preVerificationGas;\n mUserOp.maxFeePerGas = userOp.maxFeePerGas;\n mUserOp.maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes calldata paymasterAndData = userOp.paymasterAndData;\n if (paymasterAndData.length > 0) {\n require(paymasterAndData.length >= 20, \"AA93 invalid paymasterAndData\");\n mUserOp.paymaster = address(bytes20(paymasterAndData[: 20]));\n } else {\n mUserOp.paymaster = address(0);\n }\n }\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external {\n UserOpInfo memory outOpInfo;\n\n _simulationOnlyValidations(userOp);\n (uint256 validationData, uint256 paymasterValidationData) = _validatePrepayment(0, userOp, outOpInfo);\n StakeInfo memory paymasterInfo = _getStakeInfo(outOpInfo.mUserOp.paymaster);\n StakeInfo memory senderInfo = _getStakeInfo(outOpInfo.mUserOp.sender);\n StakeInfo memory factoryInfo;\n {\n bytes calldata initCode = userOp.initCode;\n address factory = initCode.length >= 20 ? address(bytes20(initCode[0 : 20])) : address(0);\n factoryInfo = _getStakeInfo(factory);\n }\n\n ValidationData memory data = _intersectTimeRange(validationData, paymasterValidationData);\n address aggregator = data.aggregator;\n bool sigFailed = aggregator == address(1);\n ReturnInfo memory returnInfo = ReturnInfo(outOpInfo.preOpGas, outOpInfo.prefund,\n sigFailed, data.validAfter, data.validUntil, getMemoryBytesFromOffset(outOpInfo.contextOffset));\n\n if (aggregator != address(0) && aggregator != address(1)) {\n AggregatorStakeInfo memory aggregatorInfo = AggregatorStakeInfo(aggregator, _getStakeInfo(aggregator));\n revert ValidationResultWithAggregation(returnInfo, senderInfo, factoryInfo, paymasterInfo, aggregatorInfo);\n }\n revert ValidationResult(returnInfo, senderInfo, factoryInfo, paymasterInfo);\n\n }\n\n function _getRequiredPrefund(MemoryUserOp memory mUserOp) internal pure returns (uint256 requiredPrefund) {\n unchecked {\n //when using a Paymaster, the verificationGasLimit is used also to as a limit for the postOp call.\n // our security model might call postOp eventually twice\n uint256 mul = mUserOp.paymaster != address(0) ? 3 : 1;\n uint256 requiredGas = mUserOp.callGasLimit + mUserOp.verificationGasLimit * mul + mUserOp.preVerificationGas;\n\n requiredPrefund = requiredGas * mUserOp.maxFeePerGas;\n }\n }\n\n // create the sender's contract if needed.\n function _createSenderIfNeeded(uint256 opIndex, UserOpInfo memory opInfo, bytes calldata initCode) internal {\n if (initCode.length != 0) {\n address sender = opInfo.mUserOp.sender;\n if (sender.code.length != 0) revert FailedOp(opIndex, \"AA10 sender already constructed\");\n address sender1 = senderCreator.createSender{gas : opInfo.mUserOp.verificationGasLimit}(initCode);\n if (sender1 == address(0)) revert FailedOp(opIndex, \"AA13 initCode failed or OOG\");\n if (sender1 != sender) revert FailedOp(opIndex, \"AA14 initCode must return sender\");\n if (sender1.code.length == 0) revert FailedOp(opIndex, \"AA15 initCode must create sender\");\n address factory = address(bytes20(initCode[0 : 20]));\n emit AccountDeployed(opInfo.userOpHash, sender, factory, opInfo.mUserOp.paymaster);\n }\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes calldata initCode) public {\n address sender = senderCreator.createSender(initCode);\n revert SenderAddressResult(sender);\n }\n\n function _simulationOnlyValidations(UserOperation calldata userOp) internal view {\n // solhint-disable-next-line no-empty-blocks\n try this._validateSenderAndPaymaster(userOp.initCode, userOp.sender, userOp.paymasterAndData) {}\n catch Error(string memory revertReason) {\n if (bytes(revertReason).length != 0) {\n revert FailedOp(0, revertReason);\n }\n }\n }\n\n /**\n * Called only during simulation.\n * This function always reverts to prevent warm/cold storage differentiation in simulation vs execution.\n */\n function _validateSenderAndPaymaster(bytes calldata initCode, address sender, bytes calldata paymasterAndData) external view {\n if (initCode.length == 0 && sender.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA20 account not deployed\");\n }\n if (paymasterAndData.length >= 20) {\n address paymaster = address(bytes20(paymasterAndData[0 : 20]));\n if (paymaster.code.length == 0) {\n // it would revert anyway. but give a meaningful message\n revert(\"AA30 paymaster not deployed\");\n }\n }\n // always revert\n revert(\"\");\n }\n\n /**\n * call account.validateUserOp.\n * revert (with FailedOp) in case validateUserOp reverts, or account didn't send required prefund.\n * decrement account's deposit if needed\n */\n function _validateAccountPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPrefund)\n internal returns (uint256 gasUsedByValidateAccountPrepayment, uint256 validationData) {\n unchecked {\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n address sender = mUserOp.sender;\n _createSenderIfNeeded(opIndex, opInfo, op.initCode);\n address paymaster = mUserOp.paymaster;\n numberMarker();\n uint256 missingAccountFunds = 0;\n if (paymaster == address(0)) {\n uint256 bal = balanceOf(sender);\n missingAccountFunds = bal > requiredPrefund ? 0 : requiredPrefund - bal;\n }\n try IAccount(sender).validateUserOp{gas : mUserOp.verificationGasLimit}(op, opInfo.userOpHash, missingAccountFunds)\n returns (uint256 _validationData) {\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA23 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA23 reverted (or OOG)\");\n }\n if (paymaster == address(0)) {\n DepositInfo storage senderInfo = deposits[sender];\n uint256 deposit = senderInfo.deposit;\n if (requiredPrefund > deposit) {\n revert FailedOp(opIndex, \"AA21 didn't pay prefund\");\n }\n senderInfo.deposit = uint112(deposit - requiredPrefund);\n }\n gasUsedByValidateAccountPrepayment = preGas - gasleft();\n }\n }\n\n /**\n * In case the request has a paymaster:\n * Validate paymaster has enough deposit.\n * Call paymaster.validatePaymasterUserOp.\n * Revert with proper FailedOp in case paymaster reverts.\n * Decrement paymaster's deposit\n */\n function _validatePaymasterPrepayment(uint256 opIndex, UserOperation calldata op, UserOpInfo memory opInfo, uint256 requiredPreFund, uint256 gasUsedByValidateAccountPrepayment)\n internal returns (bytes memory context, uint256 validationData) {\n unchecked {\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 verificationGasLimit = mUserOp.verificationGasLimit;\n require(verificationGasLimit > gasUsedByValidateAccountPrepayment, \"AA41 too little verificationGas\");\n uint256 gas = verificationGasLimit - gasUsedByValidateAccountPrepayment;\n\n address paymaster = mUserOp.paymaster;\n DepositInfo storage paymasterInfo = deposits[paymaster];\n uint256 deposit = paymasterInfo.deposit;\n if (deposit < requiredPreFund) {\n revert FailedOp(opIndex, \"AA31 paymaster deposit too low\");\n }\n paymasterInfo.deposit = uint112(deposit - requiredPreFund);\n try IPaymaster(paymaster).validatePaymasterUserOp{gas : gas}(op, opInfo.userOpHash, requiredPreFund) returns (bytes memory _context, uint256 _validationData){\n context = _context;\n validationData = _validationData;\n } catch Error(string memory revertReason) {\n revert FailedOp(opIndex, string.concat(\"AA33 reverted: \", revertReason));\n } catch {\n revert FailedOp(opIndex, \"AA33 reverted (or OOG)\");\n }\n }\n }\n\n /**\n * revert if either account validationData or paymaster validationData is expired\n */\n function _validateAccountAndPaymasterValidationData(uint256 opIndex, uint256 validationData, uint256 paymasterValidationData, address expectedAggregator) internal view {\n (address aggregator, bool outOfTimeRange) = _getValidationData(validationData);\n if (expectedAggregator != aggregator) {\n revert FailedOp(opIndex, \"AA24 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA22 expired or not due\");\n }\n //pmAggregator is not a real signature aggregator: we don't have logic to handle it as address.\n // non-zero address means that the paymaster fails due to some signature check (which is ok only during estimation)\n address pmAggregator;\n (pmAggregator, outOfTimeRange) = _getValidationData(paymasterValidationData);\n if (pmAggregator != address(0)) {\n revert FailedOp(opIndex, \"AA34 signature error\");\n }\n if (outOfTimeRange) {\n revert FailedOp(opIndex, \"AA32 paymaster expired or not due\");\n }\n }\n\n function _getValidationData(uint256 validationData) internal view returns (address aggregator, bool outOfTimeRange) {\n if (validationData == 0) {\n return (address(0), false);\n }\n ValidationData memory data = _parseValidationData(validationData);\n // solhint-disable-next-line not-rely-on-time\n outOfTimeRange = block.timestamp > data.validUntil || block.timestamp < data.validAfter;\n aggregator = data.aggregator;\n }\n\n /**\n * validate account and paymaster (if defined).\n * also make sure total validation doesn't exceed verificationGasLimit\n * this method is called off-chain (simulateValidation()) and on-chain (from handleOps)\n * @param opIndex the index of this userOp into the \"opInfos\" array\n * @param userOp the userOp to validate\n */\n function _validatePrepayment(uint256 opIndex, UserOperation calldata userOp, UserOpInfo memory outOpInfo)\n private returns (uint256 validationData, uint256 paymasterValidationData) {\n\n uint256 preGas = gasleft();\n MemoryUserOp memory mUserOp = outOpInfo.mUserOp;\n _copyUserOpToMemory(userOp, mUserOp);\n outOpInfo.userOpHash = getUserOpHash(userOp);\n\n // validate all numeric values in userOp are well below 128 bit, so they can safely be added\n // and multiplied without causing overflow\n uint256 maxGasValues = mUserOp.preVerificationGas | mUserOp.verificationGasLimit | mUserOp.callGasLimit |\n userOp.maxFeePerGas | userOp.maxPriorityFeePerGas;\n require(maxGasValues <= type(uint120).max, \"AA94 gas values overflow\");\n\n uint256 gasUsedByValidateAccountPrepayment;\n (uint256 requiredPreFund) = _getRequiredPrefund(mUserOp);\n (gasUsedByValidateAccountPrepayment, validationData) = _validateAccountPrepayment(opIndex, userOp, outOpInfo, requiredPreFund);\n\n if (!_validateAndUpdateNonce(mUserOp.sender, mUserOp.nonce)) {\n revert FailedOp(opIndex, \"AA25 invalid account nonce\");\n }\n\n //a \"marker\" where account opcode validation is done and paymaster opcode validation is about to start\n // (used only by off-chain simulateValidation)\n numberMarker();\n\n bytes memory context;\n if (mUserOp.paymaster != address(0)) {\n (context, paymasterValidationData) = _validatePaymasterPrepayment(opIndex, userOp, outOpInfo, requiredPreFund, gasUsedByValidateAccountPrepayment);\n }\n unchecked {\n uint256 gasUsed = preGas - gasleft();\n\n if (userOp.verificationGasLimit < gasUsed) {\n revert FailedOp(opIndex, \"AA40 over verificationGasLimit\");\n }\n outOpInfo.prefund = requiredPreFund;\n outOpInfo.contextOffset = getOffsetOfMemoryBytes(context);\n outOpInfo.preOpGas = preGas - gasleft() + userOp.preVerificationGas;\n }\n }\n\n /**\n * process post-operation.\n * called just after the callData is executed.\n * if a paymaster is defined and its validation returned a non-empty context, its postOp is called.\n * the excess amount is refunded to the account (or paymaster - if it was used in the request)\n * @param opIndex index in the batch\n * @param mode - whether is called from innerHandleOp, or outside (postOpReverted)\n * @param opInfo userOp fields and info collected during validation\n * @param context the context returned in validatePaymasterUserOp\n * @param actualGas the gas used so far by this user operation\n */\n function _handlePostOp(uint256 opIndex, IPaymaster.PostOpMode mode, UserOpInfo memory opInfo, bytes memory context, uint256 actualGas) private returns (uint256 actualGasCost) {\n uint256 preGas = gasleft();\n unchecked {\n address refundAddress;\n MemoryUserOp memory mUserOp = opInfo.mUserOp;\n uint256 gasPrice = getUserOpGasPrice(mUserOp);\n\n address paymaster = mUserOp.paymaster;\n if (paymaster == address(0)) {\n refundAddress = mUserOp.sender;\n } else {\n refundAddress = paymaster;\n if (context.length > 0) {\n actualGasCost = actualGas * gasPrice;\n if (mode != IPaymaster.PostOpMode.postOpReverted) {\n IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost);\n } else {\n // solhint-disable-next-line no-empty-blocks\n try IPaymaster(paymaster).postOp{gas : mUserOp.verificationGasLimit}(mode, context, actualGasCost) {}\n catch Error(string memory reason) {\n revert FailedOp(opIndex, string.concat(\"AA50 postOp reverted: \", reason));\n }\n catch {\n revert FailedOp(opIndex, \"AA50 postOp revert\");\n }\n }\n }\n }\n actualGas += preGas - gasleft();\n actualGasCost = actualGas * gasPrice;\n if (opInfo.prefund < actualGasCost) {\n revert FailedOp(opIndex, \"AA51 prefund below actualGasCost\");\n }\n uint256 refund = opInfo.prefund - actualGasCost;\n _incrementDeposit(refundAddress, refund);\n bool success = mode == IPaymaster.PostOpMode.opSucceeded;\n emit UserOperationEvent(opInfo.userOpHash, mUserOp.sender, mUserOp.paymaster, mUserOp.nonce, success, actualGasCost, actualGas);\n } // unchecked\n }\n\n /**\n * the gas price this UserOp agrees to pay.\n * relayer/block builder might submit the TX with higher priorityFee, but the user should not\n */\n function getUserOpGasPrice(MemoryUserOp memory mUserOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = mUserOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = mUserOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n\n function getOffsetOfMemoryBytes(bytes memory data) internal pure returns (uint256 offset) {\n assembly {offset := data}\n }\n\n function getMemoryBytesFromOffset(uint256 offset) internal pure returns (bytes memory data) {\n assembly {data := offset}\n }\n\n //place the NUMBER opcode in the code.\n // this is used as a marker during simulation, as this OP is completely banned from the simulated code of the\n // account and paymaster.\n function numberMarker() internal view {\n assembly {mstore(0, number())}\n }\n}\n\n" - }, - "contracts/core/Helpers.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\n/**\n * returned data from validateUserOp.\n * validateUserOp returns a uint256, with is created by `_packedValidationData` and parsed by `_parseValidationData`\n * @param aggregator - address(0) - the account validated the signature by itself.\n * address(1) - the account failed to validate the signature.\n * otherwise - this is an address of a signature aggregator that must be used to validate the signature.\n * @param validAfter - this UserOp is valid only after this timestamp.\n * @param validaUntil - this UserOp is valid only up to this timestamp.\n */\n struct ValidationData {\n address aggregator;\n uint48 validAfter;\n uint48 validUntil;\n }\n\n//extract sigFailed, validAfter, validUntil.\n// also convert zero validUntil to type(uint48).max\n function _parseValidationData(uint validationData) pure returns (ValidationData memory data) {\n address aggregator = address(uint160(validationData));\n uint48 validUntil = uint48(validationData >> 160);\n if (validUntil == 0) {\n validUntil = type(uint48).max;\n }\n uint48 validAfter = uint48(validationData >> (48 + 160));\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n// intersect account and paymaster ranges.\n function _intersectTimeRange(uint256 validationData, uint256 paymasterValidationData) pure returns (ValidationData memory) {\n ValidationData memory accountValidationData = _parseValidationData(validationData);\n ValidationData memory pmValidationData = _parseValidationData(paymasterValidationData);\n address aggregator = accountValidationData.aggregator;\n if (aggregator == address(0)) {\n aggregator = pmValidationData.aggregator;\n }\n uint48 validAfter = accountValidationData.validAfter;\n uint48 validUntil = accountValidationData.validUntil;\n uint48 pmValidAfter = pmValidationData.validAfter;\n uint48 pmValidUntil = pmValidationData.validUntil;\n\n if (validAfter < pmValidAfter) validAfter = pmValidAfter;\n if (validUntil > pmValidUntil) validUntil = pmValidUntil;\n return ValidationData(aggregator, validAfter, validUntil);\n }\n\n/**\n * helper to pack the return value for validateUserOp\n * @param data - the ValidationData to pack\n */\n function _packValidationData(ValidationData memory data) pure returns (uint256) {\n return uint160(data.aggregator) | (uint256(data.validUntil) << 160) | (uint256(data.validAfter) << (160 + 48));\n }\n\n/**\n * helper to pack the return value for validateUserOp, when not using an aggregator\n * @param sigFailed - true for signature failure, false for success\n * @param validUntil last timestamp this UserOperation is valid (or zero for infinite)\n * @param validAfter first timestamp this UserOperation is valid\n */\n function _packValidationData(bool sigFailed, uint48 validUntil, uint48 validAfter) pure returns (uint256) {\n return (sigFailed ? 1 : 0) | (uint256(validUntil) << 160) | (uint256(validAfter) << (160 + 48));\n }\n\n/**\n * keccak function over calldata.\n * @dev copy calldata into memory, do keccak and drop allocated memory. Strangely, this is more efficient than letting solidity do it.\n */\n function calldataKeccak(bytes calldata data) pure returns (bytes32 ret) {\n assembly {\n let mem := mload(0x40)\n let len := data.length\n calldatacopy(mem, data.offset, len)\n ret := keccak256(mem, len)\n }\n }\n\n" - }, - "contracts/core/NonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IEntryPoint.sol\";\n\n/**\n * nonce management functionality\n */\ncontract NonceManager is INonceManager {\n\n /**\n * The next valid sequence number for a given nonce key.\n */\n mapping(address => mapping(uint192 => uint256)) public nonceSequenceNumber;\n\n function getNonce(address sender, uint192 key)\n public view override returns (uint256 nonce) {\n return nonceSequenceNumber[sender][key] | (uint256(key) << 64);\n }\n\n // allow an account to manually increment its own nonce.\n // (mainly so that during construction nonce can be made non-zero,\n // to \"absorb\" the gas cost of first nonce increment to 1st transaction (construction),\n // not to 2nd transaction)\n function incrementNonce(uint192 key) public override {\n nonceSequenceNumber[msg.sender][key]++;\n }\n\n /**\n * validate nonce uniqueness for this account.\n * called just after validateUserOp()\n */\n function _validateAndUpdateNonce(address sender, uint256 nonce) internal returns (bool) {\n\n uint192 key = uint192(nonce >> 64);\n uint64 seq = uint64(nonce);\n return nonceSequenceNumber[sender][key]++ == seq;\n }\n\n}\n" - }, - "contracts/core/SenderCreator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/**\n * helper contract for EntryPoint, to call userOp.initCode from a \"neutral\" address,\n * which is explicitly not the entryPoint itself.\n */\ncontract SenderCreator {\n\n /**\n * call the \"initCode\" factory to create and return the sender account address\n * @param initCode the initCode value from a UserOp. contains 20 bytes of factory address, followed by calldata\n * @return sender the returned address of the created account, or zero address on failure.\n */\n function createSender(bytes calldata initCode) external returns (address sender) {\n address factory = address(bytes20(initCode[0 : 20]));\n bytes memory initCallData = initCode[20 :];\n bool success;\n /* solhint-disable no-inline-assembly */\n assembly {\n success := call(gas(), factory, 0, add(initCallData, 0x20), mload(initCallData), 0, 32)\n sender := mload(0)\n }\n if (!success) {\n sender = address(0);\n }\n }\n}\n" - }, - "contracts/core/StakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\nimport \"../interfaces/IStakeManager.sol\";\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable not-rely-on-time */\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by a paymaster.\n */\nabstract contract StakeManager is IStakeManager {\n\n /// maps paymaster to their deposits and stakes\n mapping(address => DepositInfo) public deposits;\n\n /// @inheritdoc IStakeManager\n function getDepositInfo(address account) public view returns (DepositInfo memory info) {\n return deposits[account];\n }\n\n // internal method to return just the stake info\n function _getStakeInfo(address addr) internal view returns (StakeInfo memory info) {\n DepositInfo storage depositInfo = deposits[addr];\n info.stake = depositInfo.stake;\n info.unstakeDelaySec = depositInfo.unstakeDelaySec;\n }\n\n /// return the deposit (for gas payment) of the account\n function balanceOf(address account) public view returns (uint256) {\n return deposits[account].deposit;\n }\n\n receive() external payable {\n depositTo(msg.sender);\n }\n\n function _incrementDeposit(address account, uint256 amount) internal {\n DepositInfo storage info = deposits[account];\n uint256 newAmount = info.deposit + amount;\n require(newAmount <= type(uint112).max, \"deposit overflow\");\n info.deposit = uint112(newAmount);\n }\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) public payable {\n _incrementDeposit(account, msg.value);\n DepositInfo storage info = deposits[account];\n emit Deposited(account, info.deposit);\n }\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 unstakeDelaySec) public payable {\n DepositInfo storage info = deposits[msg.sender];\n require(unstakeDelaySec > 0, \"must specify unstake delay\");\n require(unstakeDelaySec >= info.unstakeDelaySec, \"cannot decrease unstake time\");\n uint256 stake = info.stake + msg.value;\n require(stake > 0, \"no stake specified\");\n require(stake <= type(uint112).max, \"stake overflow\");\n deposits[msg.sender] = DepositInfo(\n info.deposit,\n true,\n uint112(stake),\n unstakeDelaySec,\n 0\n );\n emit StakeLocked(msg.sender, stake, unstakeDelaySec);\n }\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external {\n DepositInfo storage info = deposits[msg.sender];\n require(info.unstakeDelaySec != 0, \"not staked\");\n require(info.staked, \"already unstaking\");\n uint48 withdrawTime = uint48(block.timestamp) + info.unstakeDelaySec;\n info.withdrawTime = withdrawTime;\n info.staked = false;\n emit StakeUnlocked(msg.sender, withdrawTime);\n }\n\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external {\n DepositInfo storage info = deposits[msg.sender];\n uint256 stake = info.stake;\n require(stake > 0, \"No stake to withdraw\");\n require(info.withdrawTime > 0, \"must call unlockStake() first\");\n require(info.withdrawTime <= block.timestamp, \"Stake withdrawal is not due\");\n info.unstakeDelaySec = 0;\n info.withdrawTime = 0;\n info.stake = 0;\n emit StakeWithdrawn(msg.sender, withdrawAddress, stake);\n (bool success,) = withdrawAddress.call{value : stake}(\"\");\n require(success, \"failed to withdraw stake\");\n }\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external {\n DepositInfo storage info = deposits[msg.sender];\n require(withdrawAmount <= info.deposit, \"Withdraw amount too large\");\n info.deposit = uint112(info.deposit - withdrawAmount);\n emit Withdrawn(msg.sender, withdrawAddress, withdrawAmount);\n (bool success,) = withdrawAddress.call{value : withdrawAmount}(\"\");\n require(success, \"failed to withdraw\");\n }\n}\n" - }, - "contracts/interfaces/IAccount.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\ninterface IAccount {\n\n /**\n * Validate user's signature and nonce\n * the entryPoint will make the call to the recipient only if this validation call returns successfully.\n * signature failure should be reported by returning SIG_VALIDATION_FAILED (1).\n * This allows making a \"simulation call\" without a valid signature\n * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure.\n *\n * @dev Must validate caller is the entryPoint.\n * Must validate the signature and nonce\n * @param userOp the operation that is about to be executed.\n * @param userOpHash hash of the user's request data. can be used as the basis for signature.\n * @param missingAccountFunds missing funds on the account's deposit in the entrypoint.\n * This is the minimum amount to transfer to the sender(entryPoint) to be able to make the call.\n * The excess is left as a deposit in the entrypoint, for future calls.\n * can be withdrawn anytime using \"entryPoint.withdrawTo()\"\n * In case there is a paymaster in the request (or the current deposit is high enough), this value will be zero.\n * @return validationData packaged ValidationData structure. use `_packValidationData` and `_unpackValidationData` to encode and decode\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * If an account doesn't use time-range, it is enough to return SIG_VALIDATION_FAILED value (1) for signature failure.\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validateUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)\n external returns (uint256 validationData);\n}\n" - }, - "contracts/interfaces/IAggregator.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * Aggregated Signatures validator.\n */\ninterface IAggregator {\n\n /**\n * validate aggregated signature.\n * revert if the aggregated signature does not match the given list of operations.\n */\n function validateSignatures(UserOperation[] calldata userOps, bytes calldata signature) external view;\n\n /**\n * validate signature of a single userOp\n * This method is should be called by bundler after EntryPoint.simulateValidation() returns (reverts) with ValidationResultWithAggregation\n * First it validates the signature over the userOp. Then it returns data to be used when creating the handleOps.\n * @param userOp the userOperation received from the user.\n * @return sigForUserOp the value to put into the signature field of the userOp when calling handleOps.\n * (usually empty, unless account and aggregator support some kind of \"multisig\"\n */\n function validateUserOpSignature(UserOperation calldata userOp)\n external view returns (bytes memory sigForUserOp);\n\n /**\n * aggregate multiple signatures into a single value.\n * This method is called off-chain to calculate the signature to pass with handleOps()\n * bundler MAY use optimized custom code perform this aggregation\n * @param userOps array of UserOperations to collect the signatures from.\n * @return aggregatedSignature the aggregated signature\n */\n function aggregateSignatures(UserOperation[] calldata userOps) external view returns (bytes memory aggregatedSignature);\n}\n" - }, - "contracts/interfaces/IEntryPoint.sol": { - "content": "/**\n ** Account-Abstraction (EIP-4337) singleton EntryPoint implementation.\n ** Only one instance required on each chain.\n **/\n// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable avoid-low-level-calls */\n/* solhint-disable no-inline-assembly */\n/* solhint-disable reason-string */\n\nimport \"./UserOperation.sol\";\nimport \"./IStakeManager.sol\";\nimport \"./IAggregator.sol\";\nimport \"./INonceManager.sol\";\n\ninterface IEntryPoint is IStakeManager, INonceManager {\n\n /***\n * An event emitted after each successful request\n * @param userOpHash - unique identifier for the request (hash its entire content, except signature).\n * @param sender - the account that generates this request.\n * @param paymaster - if non-null, the paymaster that pays for this request.\n * @param nonce - the nonce value from the request.\n * @param success - true if the sender transaction succeeded, false if reverted.\n * @param actualGasCost - actual amount paid (by account or paymaster) for this UserOperation.\n * @param actualGasUsed - total gas used by this UserOperation (including preVerification, creation, validation and execution).\n */\n event UserOperationEvent(bytes32 indexed userOpHash, address indexed sender, address indexed paymaster, uint256 nonce, bool success, uint256 actualGasCost, uint256 actualGasUsed);\n\n /**\n * account \"sender\" was deployed.\n * @param userOpHash the userOp that deployed this account. UserOperationEvent will follow.\n * @param sender the account that is deployed\n * @param factory the factory used to deploy this account (in the initCode)\n * @param paymaster the paymaster used by this UserOp\n */\n event AccountDeployed(bytes32 indexed userOpHash, address indexed sender, address factory, address paymaster);\n\n /**\n * An event emitted if the UserOperation \"callData\" reverted with non-zero length\n * @param userOpHash the request unique identifier.\n * @param sender the sender of this request\n * @param nonce the nonce used in the request\n * @param revertReason - the return bytes from the (reverted) call to \"callData\".\n */\n event UserOperationRevertReason(bytes32 indexed userOpHash, address indexed sender, uint256 nonce, bytes revertReason);\n\n /**\n * an event emitted by handleOps(), before starting the execution loop.\n * any event emitted before this event, is part of the validation.\n */\n event BeforeExecution();\n\n /**\n * signature aggregator used by the following UserOperationEvents within this bundle.\n */\n event SignatureAggregatorChanged(address indexed aggregator);\n\n /**\n * a custom revert error of handleOps, to identify the offending op.\n * NOTE: if simulateValidation passes successfully, there should be no reason for handleOps to fail on it.\n * @param opIndex - index into the array of ops to the failed one (in simulateValidation, this is always zero)\n * @param reason - revert reason\n * The string starts with a unique code \"AAmn\", where \"m\" is \"1\" for factory, \"2\" for account and \"3\" for paymaster issues,\n * so a failure can be attributed to the correct entity.\n * Should be caught in off-chain handleOps simulation and not happen on-chain.\n * Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts.\n */\n error FailedOp(uint256 opIndex, string reason);\n\n /**\n * error case when a signature aggregator fails to verify the aggregated signature it had created.\n */\n error SignatureValidationFailed(address aggregator);\n\n /**\n * Successful result from simulateValidation.\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n */\n error ValidationResult(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo);\n\n /**\n * Successful result from simulateValidation, if the account returns a signature aggregator\n * @param returnInfo gas and time-range returned values\n * @param senderInfo stake information about the sender\n * @param factoryInfo stake information about the factory (if any)\n * @param paymasterInfo stake information about the paymaster (if any)\n * @param aggregatorInfo signature aggregation info (if the account requires signature aggregator)\n * bundler MUST use it to verify the signature, or reject the UserOperation\n */\n error ValidationResultWithAggregation(ReturnInfo returnInfo,\n StakeInfo senderInfo, StakeInfo factoryInfo, StakeInfo paymasterInfo,\n AggregatorStakeInfo aggregatorInfo);\n\n /**\n * return value of getSenderAddress\n */\n error SenderAddressResult(address sender);\n\n /**\n * return value of simulateHandleOp\n */\n error ExecutionResult(uint256 preOpGas, uint256 paid, uint48 validAfter, uint48 validUntil, bool targetSuccess, bytes targetResult);\n\n //UserOps handled, per aggregator\n struct UserOpsPerAggregator {\n UserOperation[] userOps;\n\n // aggregator address\n IAggregator aggregator;\n // aggregated signature\n bytes signature;\n }\n\n /**\n * Execute a batch of UserOperation.\n * no signature aggregator is used.\n * if any account requires an aggregator (that is, it returned an aggregator when\n * performing simulateValidation), then handleAggregatedOps() must be used instead.\n * @param ops the operations to execute\n * @param beneficiary the address to receive the fees\n */\n function handleOps(UserOperation[] calldata ops, address payable beneficiary) external;\n\n /**\n * Execute a batch of UserOperation with Aggregators\n * @param opsPerAggregator the operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)\n * @param beneficiary the address to receive the fees\n */\n function handleAggregatedOps(\n UserOpsPerAggregator[] calldata opsPerAggregator,\n address payable beneficiary\n ) external;\n\n /**\n * generate a request Id - unique identifier for this request.\n * the request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid.\n */\n function getUserOpHash(UserOperation calldata userOp) external view returns (bytes32);\n\n /**\n * Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp.\n * @dev this method always revert. Successful result is ValidationResult error. other errors are failures.\n * @dev The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.\n * @param userOp the user operation to validate.\n */\n function simulateValidation(UserOperation calldata userOp) external;\n\n /**\n * gas and return values during simulation\n * @param preOpGas the gas used for validation (including preValidationGas)\n * @param prefund the required prefund for this operation\n * @param sigFailed validateUserOp's (or paymaster's) signature check failed\n * @param validAfter - first timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param validUntil - last timestamp this UserOp is valid (merging account and paymaster time-range)\n * @param paymasterContext returned by validatePaymasterUserOp (to be passed into postOp)\n */\n struct ReturnInfo {\n uint256 preOpGas;\n uint256 prefund;\n bool sigFailed;\n uint48 validAfter;\n uint48 validUntil;\n bytes paymasterContext;\n }\n\n /**\n * returned aggregated signature info.\n * the aggregator returned by the account, and its current stake.\n */\n struct AggregatorStakeInfo {\n address aggregator;\n StakeInfo stakeInfo;\n }\n\n /**\n * Get counterfactual sender address.\n * Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation.\n * this method always revert, and returns the address in SenderAddressResult error\n * @param initCode the constructor code to be passed into the UserOperation.\n */\n function getSenderAddress(bytes memory initCode) external;\n\n\n /**\n * simulate full execution of a UserOperation (including both validation and target execution)\n * this method will always revert with \"ExecutionResult\".\n * it performs full validation of the UserOperation, but ignores signature error.\n * an optional target address is called after the userop succeeds, and its value is returned\n * (before the entire call is reverted)\n * Note that in order to collect the the success/failure of the target call, it must be executed\n * with trace enabled to track the emitted events.\n * @param op the UserOperation to simulate\n * @param target if nonzero, a target address to call after userop simulation. If called, the targetSuccess and targetResult\n * are set to the return from that call.\n * @param targetCallData callData to pass to target address\n */\n function simulateHandleOp(UserOperation calldata op, address target, bytes calldata targetCallData) external;\n}\n\n" - }, - "contracts/interfaces/INonceManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\ninterface INonceManager {\n\n /**\n * Return the next nonce for this sender.\n * Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop)\n * But UserOp with different keys can come with arbitrary order.\n *\n * @param sender the account address\n * @param key the high 192 bit of the nonce\n * @return nonce a full nonce to pass for next UserOp with this sender.\n */\n function getNonce(address sender, uint192 key)\n external view returns (uint256 nonce);\n\n /**\n * Manually increment the nonce of the sender.\n * This method is exposed just for completeness..\n * Account does NOT need to call it, neither during validation, nor elsewhere,\n * as the EntryPoint will update the nonce regardless.\n * Possible use-case is call it with various keys to \"initialize\" their nonces to one, so that future\n * UserOperations will not pay extra for the first transaction with a given key.\n */\n function incrementNonce(uint192 key) external;\n}\n" - }, - "contracts/interfaces/IPaymaster.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\nimport \"./UserOperation.sol\";\n\n/**\n * the interface exposed by a paymaster contract, who agrees to pay the gas for user's operations.\n * a paymaster must hold a stake to cover the required entrypoint stake and also the gas for the transaction.\n */\ninterface IPaymaster {\n\n enum PostOpMode {\n opSucceeded, // user op succeeded\n opReverted, // user op reverted. still has to pay for gas.\n postOpReverted //user op succeeded, but caused postOp to revert. Now it's a 2nd call, after user's op was deliberately reverted.\n }\n\n /**\n * payment validation: check if paymaster agrees to pay.\n * Must verify sender is the entryPoint.\n * Revert to reject this request.\n * Note that bundlers will reject this method if it changes the state, unless the paymaster is trusted (whitelisted)\n * The paymaster pre-pays using its deposit, and receive back a refund after the postOp method returns.\n * @param userOp the user operation\n * @param userOpHash hash of the user's request data.\n * @param maxCost the maximum cost of this transaction (based on maximum gas and gas price from userOp)\n * @return context value to send to a postOp\n * zero length to signify postOp is not required.\n * @return validationData signature and time-range of this operation, encoded the same as the return value of validateUserOperation\n * <20-byte> sigAuthorizer - 0 for valid signature, 1 to mark signature failure,\n * otherwise, an address of an \"authorizer\" contract.\n * <6-byte> validUntil - last timestamp this operation is valid. 0 for \"indefinite\"\n * <6-byte> validAfter - first timestamp this operation is valid\n * Note that the validation code cannot use block.timestamp (or block.number) directly.\n */\n function validatePaymasterUserOp(UserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost)\n external returns (bytes memory context, uint256 validationData);\n\n /**\n * post-operation handler.\n * Must verify sender is the entryPoint\n * @param mode enum with the following options:\n * opSucceeded - user operation succeeded.\n * opReverted - user op reverted. still has to pay for gas.\n * postOpReverted - user op succeeded, but caused postOp (in mode=opSucceeded) to revert.\n * Now this is the 2nd call, after user's op was deliberately reverted.\n * @param context - the context value returned by validatePaymasterUserOp\n * @param actualGasCost - actual gas used so far (without this postOp call).\n */\n function postOp(PostOpMode mode, bytes calldata context, uint256 actualGasCost) external;\n}\n" - }, - "contracts/interfaces/IStakeManager.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0-only\npragma solidity ^0.8.12;\n\n/**\n * manage deposits and stakes.\n * deposit is just a balance used to pay for UserOperations (either by a paymaster or an account)\n * stake is value locked for at least \"unstakeDelay\" by the staked entity.\n */\ninterface IStakeManager {\n\n event Deposited(\n address indexed account,\n uint256 totalDeposit\n );\n\n event Withdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /// Emitted when stake or unstake delay are modified\n event StakeLocked(\n address indexed account,\n uint256 totalStaked,\n uint256 unstakeDelaySec\n );\n\n /// Emitted once a stake is scheduled for withdrawal\n event StakeUnlocked(\n address indexed account,\n uint256 withdrawTime\n );\n\n event StakeWithdrawn(\n address indexed account,\n address withdrawAddress,\n uint256 amount\n );\n\n /**\n * @param deposit the entity's deposit\n * @param staked true if this entity is staked.\n * @param stake actual amount of ether staked for this entity.\n * @param unstakeDelaySec minimum delay to withdraw the stake.\n * @param withdrawTime - first block timestamp where 'withdrawStake' will be callable, or zero if already locked\n * @dev sizes were chosen so that (deposit,staked, stake) fit into one cell (used during handleOps)\n * and the rest fit into a 2nd cell.\n * 112 bit allows for 10^15 eth\n * 48 bit for full timestamp\n * 32 bit allows 150 years for unstake delay\n */\n struct DepositInfo {\n uint112 deposit;\n bool staked;\n uint112 stake;\n uint32 unstakeDelaySec;\n uint48 withdrawTime;\n }\n\n //API struct used by getStakeInfo and simulateValidation\n struct StakeInfo {\n uint256 stake;\n uint256 unstakeDelaySec;\n }\n\n /// @return info - full deposit information of given account\n function getDepositInfo(address account) external view returns (DepositInfo memory info);\n\n /// @return the deposit (for gas payment) of the account\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * add to the deposit of the given account\n */\n function depositTo(address account) external payable;\n\n /**\n * add to the account's stake - amount and delay\n * any pending unstake is first cancelled.\n * @param _unstakeDelaySec the new lock duration before the deposit can be withdrawn.\n */\n function addStake(uint32 _unstakeDelaySec) external payable;\n\n /**\n * attempt to unlock the stake.\n * the value can be withdrawn (using withdrawStake) after the unstake delay.\n */\n function unlockStake() external;\n\n /**\n * withdraw from the (unlocked) stake.\n * must first call unlockStake and wait for the unstakeDelay to pass\n * @param withdrawAddress the address to send withdrawn value.\n */\n function withdrawStake(address payable withdrawAddress) external;\n\n /**\n * withdraw from the deposit.\n * @param withdrawAddress the address to send withdrawn value.\n * @param withdrawAmount the amount to withdraw.\n */\n function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external;\n}\n" - }, - "contracts/interfaces/UserOperation.sol": { - "content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity ^0.8.12;\n\n/* solhint-disable no-inline-assembly */\n\nimport {calldataKeccak} from \"../core/Helpers.sol\";\n\n/**\n * User Operation struct\n * @param sender the sender account of this request.\n * @param nonce unique value the sender uses to verify it is not a replay.\n * @param initCode if set, the account contract will be created by this constructor/\n * @param callData the method call to execute on this account.\n * @param callGasLimit the gas limit passed to the callData method call.\n * @param verificationGasLimit gas used for validateUserOp and validatePaymasterUserOp.\n * @param preVerificationGas gas not calculated by the handleOps method, but added to the gas paid. Covers batch overhead.\n * @param maxFeePerGas same as EIP-1559 gas parameter.\n * @param maxPriorityFeePerGas same as EIP-1559 gas parameter.\n * @param paymasterAndData if set, this field holds the paymaster address and paymaster-specific data. the paymaster will pay for the transaction instead of the sender.\n * @param signature sender-verified signature over the entire request, the EntryPoint address and the chain ID.\n */\n struct UserOperation {\n\n address sender;\n uint256 nonce;\n bytes initCode;\n bytes callData;\n uint256 callGasLimit;\n uint256 verificationGasLimit;\n uint256 preVerificationGas;\n uint256 maxFeePerGas;\n uint256 maxPriorityFeePerGas;\n bytes paymasterAndData;\n bytes signature;\n }\n\n/**\n * Utility functions helpful when working with UserOperation structs.\n */\nlibrary UserOperationLib {\n\n function getSender(UserOperation calldata userOp) internal pure returns (address) {\n address data;\n //read sender from userOp, which is first userOp member (saves 800 gas...)\n assembly {data := calldataload(userOp)}\n return address(uint160(data));\n }\n\n //relayer/block builder might submit the TX with higher priorityFee, but the user should not\n // pay above what he signed for.\n function gasPrice(UserOperation calldata userOp) internal view returns (uint256) {\n unchecked {\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n if (maxFeePerGas == maxPriorityFeePerGas) {\n //legacy mode (for networks that don't support basefee opcode)\n return maxFeePerGas;\n }\n return min(maxFeePerGas, maxPriorityFeePerGas + block.basefee);\n }\n }\n\n function pack(UserOperation calldata userOp) internal pure returns (bytes memory ret) {\n address sender = getSender(userOp);\n uint256 nonce = userOp.nonce;\n bytes32 hashInitCode = calldataKeccak(userOp.initCode);\n bytes32 hashCallData = calldataKeccak(userOp.callData);\n uint256 callGasLimit = userOp.callGasLimit;\n uint256 verificationGasLimit = userOp.verificationGasLimit;\n uint256 preVerificationGas = userOp.preVerificationGas;\n uint256 maxFeePerGas = userOp.maxFeePerGas;\n uint256 maxPriorityFeePerGas = userOp.maxPriorityFeePerGas;\n bytes32 hashPaymasterAndData = calldataKeccak(userOp.paymasterAndData);\n\n return abi.encode(\n sender, nonce,\n hashInitCode, hashCallData,\n callGasLimit, verificationGasLimit, preVerificationGas,\n maxFeePerGas, maxPriorityFeePerGas,\n hashPaymasterAndData\n );\n }\n\n function hash(UserOperation calldata userOp) internal pure returns (bytes32) {\n return keccak256(pack(userOp));\n }\n\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\n return a < b ? a : b;\n }\n}\n" - }, - "contracts/utils/Exec.sol": { - "content": "// SPDX-License-Identifier: LGPL-3.0-only\npragma solidity >=0.7.5 <0.9.0;\n\n// solhint-disable no-inline-assembly\n\n/**\n * Utility functions helpful when making different kinds of contract calls in Solidity.\n */\nlibrary Exec {\n\n function call(\n address to,\n uint256 value,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := call(txGas, to, value, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function staticcall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal view returns (bool success) {\n assembly {\n success := staticcall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n function delegateCall(\n address to,\n bytes memory data,\n uint256 txGas\n ) internal returns (bool success) {\n assembly {\n success := delegatecall(txGas, to, add(data, 0x20), mload(data), 0, 0)\n }\n }\n\n // get returned data from last call or calldelegate\n function getReturnData(uint256 maxLen) internal pure returns (bytes memory returnData) {\n assembly {\n let len := returndatasize()\n if gt(len, maxLen) {\n len := maxLen\n }\n let ptr := mload(0x40)\n mstore(0x40, add(ptr, add(len, 0x20)))\n mstore(ptr, len)\n returndatacopy(add(ptr, 0x20), 0, len)\n returnData := ptr\n }\n }\n\n // revert with explicit byte array (probably reverted info from call)\n function revertWithData(bytes memory returnData) internal pure {\n assembly {\n revert(add(returnData, 32), mload(returnData))\n }\n }\n\n function callAndRevert(address to, bytes memory data, uint256 maxLen) internal {\n bool success = call(to,0,data,gasleft());\n if (!success) {\n revertWithData(getReturnData(maxLen));\n }\n }\n}\n" - } - }, - "settings": { - "optimizer": { - "enabled": true, - "runs": 1000000 - }, - "viaIR": true, - "outputSelection": { - "*": { - "*": [ - "abi", - "evm.bytecode", - "evm.deployedBytecode", - "evm.methodIdentifiers", - "metadata" - ], - "": [ - "ast" - ] - } - } - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/ERCS/erc-4337.md b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/ERCS/erc-4337.md deleted file mode 100644 index ef0e923709..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/ERCS/erc-4337.md +++ /dev/null @@ -1,1017 +0,0 @@ ---- -eip: 4337 -title: Account Abstraction Using Alt Mempool -description: An account abstraction proposal which completely avoids consensus-layer protocol changes, instead relying on higher-layer infrastructure. -author: Vitalik Buterin (@vbuterin), Yoav Weiss (@yoavw), Dror Tirosh (@drortirosh), Shahaf Nacson (@shahafn), Alex Forshtat (@forshtat), Kristof Gazso (@kristofgazso), Tjaden Hess (@tjade273) -discussions-to: https://ethereum-magicians.org/t/erc-4337-account-abstraction-via-entry-point-contract-specification/7160 -status: Draft -type: Standards Track -category: ERC -created: 2021-09-29 -requires: 7562 ---- - -## Abstract - -An account abstraction proposal which completely avoids the need for consensus-layer protocol changes. Instead of adding new protocol features and changing the bottom-layer transaction type, this proposal instead introduces a higher-layer pseudo-transaction object called a `UserOperation`. Users send `UserOperation` objects into a separate mempool. A special class of actor called bundlers package up a set of these objects into a transaction making a `handleOps` call to a special contract, and that transaction then gets included in a block. - -## Motivation - -See also `https://ethereum-magicians.org/t/implementing-account-abstraction-as-part-of-eth1-x/4020` and the links therein for historical work and motivation, and [EIP-2938](./eip-2938.md) for a consensus layer proposal for implementing the same goal. - -This proposal takes a different approach, avoiding any adjustments to the consensus layer. It seeks to achieve the following goals: - -- **Achieve the key goal of account abstraction**: allow users to use smart contract wallets containing arbitrary verification logic instead of EOAs as their primary account. Completely remove any need at all for users to also have EOAs (as status quo SC wallets and [EIP-3074](./eip-3074.md) both require) -- **Decentralization** - - Allow any bundler (think: block builder) to participate in the process of including account-abstracted user operations - - Work with all activity happening over a public mempool; users do not need to know the direct communication addresses (eg. IP, onion) of any specific actors - - Avoid trust assumptions on bundlers -- **Do not require any Ethereum consensus changes**: Ethereum consensus layer development is focusing on the merge and later on scalability-oriented features, and there may not be any opportunity for further protocol changes for a long time. Hence, to increase the chance of faster adoption, this proposal avoids Ethereum consensus changes. -- **Try to support other use cases** - - Privacy-preserving applications - - Atomic multi-operations (similar goal to [EIP-3074]) - - Pay tx fees with [ERC-20](./erc-20.md) tokens, allow developers to pay fees for their users, and [EIP-3074]-like **sponsored transaction** use cases more generally - - Support aggregated signature (e.g. BLS) - -## Specification - -### Definitions - -- **UserOperation** - a structure that describes a transaction to be sent on behalf of a user. To avoid confusion, it is not named "transaction". - - Like a transaction, it contains "sender", "to", "calldata", "maxFeePerGas", "maxPriorityFee", "signature", "nonce" - - unlike a transaction, it contains several other fields, described below - - also, the "signature" field usage is not defined by the protocol, but by each account implementation -- **Sender** - the account contract sending a user operation. -- **EntryPoint** - a singleton contract to execute bundles of UserOperations. Bundlers/Clients whitelist the supported entrypoint. -- **Bundler** - a node (block builder) that can handle UserOperations, - create a valid an EntryPoint.handleOps() transaction, - and add it to the block while it is still valid. - This can be achieved by a number of ways: - - Bundler can act as a block builder itself - - If the bundler is not a block builder, it MUST work with the block building infrastructure such as `mev-boost` or - other kind of PBS (proposer-builder separation) - - The `bundler` can also rely on an experimental `eth_sendRawTransactionConditional` RPC API if it is available. -- **Aggregator** - a helper contract trusted by accounts to validate an aggregated signature. Bundlers/Clients whitelist the supported aggregators. - -To avoid Ethereum consensus changes, we do not attempt to create new transaction types for account-abstracted transactions. Instead, users package up the action they want their account to take in a struct named `UserOperation`: - -| Field | Type | Description | -| ------------------------------- | --------- | ----------------------------------------------------------------------------- | -| `sender` | `address` | The account making the operation | -| `nonce` | `uint256` | Anti-replay parameter (see "Semi-abstracted Nonce Support" ) | -| `factory` | `address` | account factory, only for new accounts | -| `factoryData` | `bytes` | data for account factory (only if account factory exists) | -| `callData` | `bytes` | The data to pass to the `sender` during the main execution call | -| `callGasLimit` | `uint256` | The amount of gas to allocate the main execution call | -| `verificationGasLimit` | `uint256` | The amount of gas to allocate for the verification step | -| `preVerificationGas` | `uint256` | Extra gas to pay the bunder | -| `maxFeePerGas` | `uint256` | Maximum fee per gas (similar to [EIP-1559](./eip-1559.md) `max_fee_per_gas`) | -| `maxPriorityFeePerGas` | `uint256` | Maximum priority fee per gas (similar to EIP-1559 `max_priority_fee_per_gas`) | -| `paymaster` | `address` | Address of paymaster contract, (or empty, if account pays for itself) | -| `paymasterVerificationGasLimit` | `uint256` | The amount of gas to allocate for the paymaster validation code | -| `paymasterPostOpGasLimit` | `uint256` | The amount of gas to allocate for the paymaster post-operation code | -| `paymasterData` | `bytes` | Data for paymaster (only if paymaster exists) | -| `signature` | `bytes` | Data passed into the account to verify authorization | - -Users send `UserOperation` objects to a dedicated user operation mempool. The are not concerned with the packed version. -A specialized class of actors called **bundlers** (either block builders running special-purpose code, or users that can relay transactions to block builders eg. through a bundle marketplace such as Flashbots that can guarantee next-block-or-never inclusion) listen in on the user operation mempool, and create **bundle transactions**. A bundle transaction packages up multiple `UserOperation` objects into a single `handleOps` call to a pre-published global **entry point contract**. - -To prevent replay attacks (both cross-chain and multiple `EntryPoint` implementations), the `signature` should depend on `chainid` and the `EntryPoint` address. - -When passed to on-chain contacts (the EntryPoint contract, and then to account and paymaster), a packed version of the above structure is used: - -| Field | Type | Description | -| -------------------- | --------- | ---------------------------------------------------------------------- | -| `sender` | `address` | | -| `nonce` | `uint256` | | -| `initCode` | `bytes` | concatenation of factory address and factoryData (or empty) | -| `callData` | `bytes` | | -| `accountGasLimits` | `bytes32` | concatenation of verificationGas (16 bytes) and callGas (16 bytes) | -| `preVerificationGas` | `uint256` | | -| `gasFees` | `bytes32` | concatenation of maxPriorityFee (16 bytes) and maxFeePerGas (16 bytes) | -| `paymasterAndData` | `bytes` | concatenation of paymaster fields (or empty) | -| `signature` | `bytes` | | - -The core interface of the entry point contract is as follows: - -```solidity -function handleOps(PackedUserOperation[] calldata ops, address payable beneficiary); - -function handleAggregatedOps( - UserOpsPerAggregator[] calldata opsPerAggregator, - address payable beneficiary -); - -struct UserOpsPerAggregator { - PackedUserOperation[] userOps; - IAggregator aggregator; - bytes signature; -} -``` - -The core interface required for an account to have is: - -```solidity -interface IAccount { - function validateUserOp - (PackedUserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds) - external returns (uint256 validationData); -} -``` - -The `userOpHash` is a hash over the userOp (except signature), entryPoint and chainId. - -The account: - -- MUST validate the caller is a trusted EntryPoint -- If the account does not support signature aggregation, it MUST validate the signature is a valid signature of the `userOpHash`, and - SHOULD return SIG_VALIDATION_FAILED (and not revert) on signature mismatch. Any other error MUST revert. -- MUST pay the entryPoint (caller) at least the "missingAccountFunds" (which might be zero, in case current account's deposit is high enough) -- The account MAY pay more than this minimum, to cover future transactions (it can always issue `withdrawTo` to retrieve it) -- The return value MUST be packed of `authorizer`, `validUntil` and `validAfter` timestamps. - - authorizer - 0 for valid signature, 1 to mark signature failure. Otherwise, an address of an authorizer contract. This ERC defines "signature aggregator" as authorizer. - - `validUntil` is 6-byte timestamp value, or zero for "infinite". The UserOp is valid only up to this time. - - `validAfter` is 6-byte timestamp. The UserOp is valid only after this time. - -An account that works with aggregated signature, should return its signature aggregator address in the "sigAuthorizer" return value of validateUserOp. -It MAY ignore the signature field. - -The account MAY implement the interface `IAccountExecute` - -```solidity -interface IAccountExecute { - function executeUserOp(PackedUserOperation calldata userOp, bytes32 userOpHash) external; -} -``` - -This method will be called by the entryPoint with the current UserOperation, instead of executing the `callData` itself on the account. - -The core interface required by an aggregator is: - -```solidity -interface IAggregator { - - function validateUserOpSignature(PackedUserOperation calldata userOp) - external view returns (bytes memory sigForUserOp); - - function aggregateSignatures(PackedUserOperation[] calldata userOps) external view returns (bytes memory aggregatesSignature); - - function validateSignatures(PackedUserOperation[] calldata userOps, bytes calldata signature) view external; -} -``` - -- If an account uses an aggregator (returns it from validateUserOp), then its address is returned by `simulateValidation()` (in `aggregatorInfo`) -- To accept the UserOp, the bundler must call **validateUserOpSignature()** to validate the userOp's signature. -- **aggregateSignatures()** must aggregate all UserOp signature into a single value. -- Note that the above methods are helper method for the bundler. The bundler MAY use a native library to perform the same validation and aggregation logic. -- **validateSignatures()** MUST validate the aggregated signature matches for all UserOperations in the array, and revert otherwise. - This method is called on-chain by `handleOps()` - -#### Semi-abstracted Nonce Support - -In Ethereum protocol, the sequential transaction `nonce` value is used as a replay protection method as well as to -determine the valid order of transaction being included in blocks. - -It also contributes to the transaction hash uniqueness, as a transaction by the same sender with the same -nonce may not be included in the chain twice. - -However, requiring a single sequential `nonce` value is limiting the senders' ability to define their custom logic -with regard to transaction ordering and replay protection. - -Instead of sequential `nonce` we implement a nonce mechanism that uses a single `uint256` nonce value in the `UserOperation`, -but treats it as two values: - -- 192-bit "key" -- 64-bit "sequence" - -These values are represented on-chain in the `EntryPoint` contract. -We define the following method in the `EntryPoint` interface to expose these values: - -```solidity -function getNonce(address sender, uint192 key) external view returns (uint256 nonce); -``` - -For each `key` the `sequence` is validated and incremented sequentially and monotonically by the `EntryPoint` for -each UserOperation, however a new key can be introduced with an arbitrary value at any point. - -This approach maintains the guarantee of `UserOperation` hash uniqueness on-chain on the protocol level while allowing -wallets to implement any custom logic they may need operating on a 192-bit "key" field, while fitting the 32 byte word. - -##### Reading and validating the nonce - -When preparing the UserOp clients may make a view call to this method to determine a valid value for the `nonce` field. - -Bundler's validation of a UserOp should start with `getNonce` to ensure the transaction has a valid `nonce` field. - -If the bundler is willing to accept multiple UserOperations by the same sender into their mempool, -this bundler is supposed to track the `key` and `sequence` pair of the UserOperations already added in the mempool. - -##### Usage examples - -1. Classic sequential nonce. - - In order to require the wallet to have classic, sequential nonce, the validation function should perform: - - ```solidity - require(userOp.nonce> 64; - if (sig == ADMIN_METHODSIG) { - require(key == ADMIN_KEY, "wrong nonce-key for admin operation"); - } else { - require(key == 0, "wrong nonce-key for normal operation"); - } - ``` - -#### Using signature aggregators - -An account signifies it uses signature aggregation returning its address from `validateUserOp`. -During `simulateValidation`, this aggregator is returned as part of the `aggregatorInfo` struct. - -The bundler should first accept the aggregator (validate its stake info and that it is not throttled/banned) -Then it MUST verify the userOp using `aggregator.validateUserOpSignature()`. This method returned an alternate signature (usually empty) that should be used during bundling. -The bundler MUST call `validateUserOp` a second time on the account with the UserOperation using that returned signature. - -Signature aggregator MUST be staked. -Bundlers MAY throttle down and ban aggregators in case they take too much resources (or revert) when the above methods are called in view mode, or if the signature aggregation fails. - -### Required entry point contract functionality - -There are 2 separate entry point methods: `handleOps` and `handleAggregatedOps` - -- `handleOps` handle userOps of accounts that don't require any signature aggregator. -- `handleAggregatedOps` can handle a batch that contains userOps of multiple aggregators (and also requests without any aggregator) -- `handleAggregatedOps` performs the same logic below as `handleOps`, but it must transfer the correct aggregator to each userOp, and also must call `validateSignatures` on each aggregator before doing all the per-account validation. - The entry point's `handleOps` function must perform the following steps (we first describe the simpler non-paymaster case). It must make two loops, the **verification loop** and the **execution loop**. In the verification loop, the `handleOps` call must perform the following steps for each `UserOperation`: - -- **Create the account if it does not yet exist**, using the initcode provided in the `UserOperation`. If the account does not exist, _and_ the initcode is empty, or does not deploy a contract at the "sender" address, the call must fail. -- calculate the maximum possible fee the account needs to pay (based on validation and call gas limits, and current gas values) -- calculate the fee the account must add to its "deposit" in the EntryPoint -- **Call `validateUserOp` on the account**, passing in the `UserOperation`, its hash and the required fee. The account should verify the operation's signature, and pay the fee if the account considers the operation valid. If any `validateUserOp` call fails, `handleOps` must skip execution of at least that operation, and may revert entirely. -- Validate the account's deposit in the entryPoint is high enough to cover the max possible cost (cover the already-done verification and max execution gas) - -In the execution loop, the `handleOps` call must perform the following steps for each `UserOperation`: - -- **Call the account with the `UserOperation`'s calldata**. It's up to the account to choose how to parse the calldata; an expected workflow is for the account to have an `execute` function that parses the remaining calldata as a series of one or more calls that the account should make. -- If the calldata starts with the methodsig `IAccountExecute.executeUserOp`, then the EntryPoint must build a calldata by encoding `executeUserOp(userOp,userOpHash)` and call the account using that calldata. -- After the call, refund the account's deposit with the excess gas cost that was pre-charged.\ - A penalty of `10%` (`UNUSED_GAS_PENALTY_PERCENT`) is applied on the amount of gas that is refunded.\ - This penalty is necessary to prevent the UserOps from reserving large parts of the gas space in the bundle but leaving it unused and preventing the bundler from including other UserOperations. -- After the execution of all calls, pay the collected fees from all UserOperations to the bundler's provided address - -![](../assets/erc-4337/bundle-seq.svg) - -Before accepting a `UserOperation`, bundlers should use an RPC method to locally call the `simulateValidation` function on the entry point, to verify that the signature is correct and the operation actually pays fees; see the [Simulation section below](#simulation) for details. -A node/bundler SHOULD drop (not add to the mempool) a `UserOperation` that fails the validation - -### Extension: paymasters - -We extend the entry point logic to support **paymasters** that can sponsor transactions for other users. This feature can be used to allow application developers to subsidize fees for their users, allow users to pay fees with [ERC-20](./erc-20.md) tokens and many other use cases. When the paymasterAndData field in the UserOp is not empty, the entry point implements a different flow for that UserOperation: - -![](../assets/erc-4337/bundle-seq-pm.svg) - -During the verification loop, in addition to calling `validateUserOp`, the `handleOps` execution also must check that the paymaster has enough ETH deposited with the entry point to pay for the operation, and then call `validatePaymasterUserOp` on the paymaster to verify that the paymaster is willing to pay for the operation. Note that in this case, the `validateUserOp` is called with a `missingAccountFunds` of 0 to reflect that the account's deposit is not used for payment for this userOp. - -If the paymaster's validatePaymasterUserOp returns a "context", then `handleOps` must call `postOp` on the paymaster after making the main execution call. - -Maliciously crafted paymasters _can_ DoS the system. To prevent this, we use a reputation system. paymaster must either limit its storage usage, or have a stake. see the [reputation, throttling and banning section](#reputation-scoring-and-throttlingbanning-for-global-entities) for details. - -The paymaster interface is as follows: - -```solidity -function validatePaymasterUserOp - (PackedUserOperation calldata userOp, bytes32 userOpHash, uint256 maxCost) - external returns (bytes memory context, uint256 validationData); - -function postOp - (PostOpMode mode, bytes calldata context, uint256 actualGasCost, uint256 actualUserOpFeePerGas) - external; - -enum PostOpMode { - opSucceeded, // user op succeeded - opReverted, // user op reverted. still has to pay for gas. - postOpReverted // Regardless of the UserOp call status, the postOp reverted, and caused both executions to revert. -} -``` - -The EntryPoint must implement the following API to let entities like paymasters to have a stake, and thus have more flexibility in their storage access (see [reputation, throttling and banning section](#reputation-scoring-and-throttlingbanning-for-global-entities) for details.) - -```solidity -// add a stake to the calling entity -function addStake(uint32 _unstakeDelaySec) external payable - -// unlock the stake (must wait unstakeDelay before can withdraw) -function unlockStake() external - -// withdraw the unlocked stake -function withdrawStake(address payable withdrawAddress) external -``` - -The paymaster must also have a deposit, which the entry point will charge UserOperation costs from. -The deposit (for paying gas fees) is separate from the stake (which is locked). - -The EntryPoint must implement the following interface to allow paymasters (and optionally accounts) manage their deposit: - -```c++ -// return the deposit of an account -function balanceOf(address account) public view returns (uint256) - -// add to the deposit of the given account -function depositTo(address account) public payable - -// withdraw from the deposit of the current account -function withdrawTo(address payable withdrawAddress, uint256 withdrawAmount) external -``` - -### Client behavior upon receiving a UserOperation - -When a client receives a `UserOperation`, it must first run some basic sanity checks, namely that: - -- Either the `sender` is an existing contract, or the `initCode` is not empty (but not both) -- If `initCode` is not empty, parse its first 20 bytes as a factory address. Record whether the factory is staked, in case the later simulation indicates that it needs to be. If the factory accesses global state, it must be staked - see [reputation, throttling and banning section](#reputation-scoring-and-throttlingbanning-for-global-entities) for details. -- The `verificationGasLimit` is sufficiently low (`<= MAX_VERIFICATION_GAS`) and the `preVerificationGas` is sufficiently high (enough to pay for the calldata gas cost of serializing the `UserOperation` plus `PRE_VERIFICATION_OVERHEAD_GAS`) -- The `paymasterAndData` is either empty, or start with the **paymaster** address, which is a contract that (i) currently has nonempty code on chain, (ii) has a sufficient deposit to pay for the UserOperation, and (iii) is not currently banned. During simulation, the paymaster's stake is also checked, depending on its storage usage - see [reputation, throttling and banning section](#reputation-scoring-and-throttlingbanning-for-global-entities) for details. -- The callgas is at least the cost of a `CALL` with non-zero value. -- The `maxFeePerGas` and `maxPriorityFeePerGas` are above a configurable minimum value that the client is willing to accept. At the minimum, they are sufficiently high to be included with the current `block.basefee`. -- The sender doesn't have another `UserOperation` already present in the pool (or it replaces an existing entry with the same sender and nonce, with a higher `maxPriorityFeePerGas` and an equally increased `maxFeePerGas`). Only one `UserOperation` per sender may be included in a single batch. A sender is exempt from this rule and may have multiple `UserOperations` in the pool and in a batch if it is staked (see [reputation, throttling and banning section](#reputation-scoring-and-throttlingbanning-for-global-entities) below), but this exception is of limited use to normal accounts. - -If the `UserOperation` object passes these sanity checks, the client must next run the first op simulation, and if the simulation succeeds, the client must add the op to the pool. A second simulation must also happen during bundling to make sure the UserOperation is still valid. - -### Simulation - -#### Simulation Rationale - -In order to add a UserOperation into the mempool (and later to add it into a bundle) we need to "simulate" its validation to make sure it is valid, and that it is capable of paying for its own execution. -In addition, we need to verify that the same will hold true when executed on-chain. -For this purpose, a UserOperation is not allowed to access any information that might change between simulation and execution, such as current block time, number, hash etc. -In addition, a UserOperation is only allowed to access data related to this sender address: Multiple UserOperations should not access the same storage, so that it is impossible to invalidate a large number of UserOperations with a single state change. -There are 3 special contracts that interact with the account: the factory (initCode) that deploys the contract, the paymaster that can pay for the gas, and signature aggregator (described later) -Each of these contracts is also restricted in its storage access, to make sure UserOperation validations are isolated. - -#### Specification: - -To simulate a `UserOperation` validation, the client makes a view call to `simulateValidation(userop)`. - -The EntryPoint itself does not implement the simulation methods. Instead, when making the simulation view call, -The bundler should provide the alternate EntryPointSimulations code, which extends the EntryPoint with the simulation methods. - -The simulation core methods: - -```solidity - -struct ValidationResult { - ReturnInfo returnInfo; - StakeInfo senderInfo; - StakeInfo factoryInfo; - StakeInfo paymasterInfo; - AggregatorStakeInfo aggregatorInfo; -} - -function simulateValidation(PackedUserOperation calldata userOp) -external returns (ValidationResult memory); - -struct ReturnInfo { - uint256 preOpGas; - uint256 prefund; - uint256 accountValidationData; - uint256 paymasterValidationData; - bytes paymasterContext; -} - -struct AggregatorStakeInfo { - address aggregator; - StakeInfo stakeInfo; -} - -struct StakeInfo { - uint256 stake; - uint256 unstakeDelaySec; -} - - -``` - -This method returns `ValidationResult` or revert on validation failure. -The node should drop the UserOperation if the simulation fails (either by revert or by "signature failure") - -The simulated call performs the full validation, by calling: - -1. If `initCode` is present, create the account. -2. `account.validateUserOp`. -3. if specified a paymaster: `paymaster.validatePaymasterUserOp`. - -The simulateValidation should validate the return value (validationData) returned by the account's `validateUserOp` and paymaster's `validatePaymasterUserOp`. -The account MAY return an aggregator. See [Using Signature Aggregator](#using-signature-aggregators) -The paymaster MUST return either "0" (success) or SIG_VALIDATION_FAILED for aggregator, and not an address. -Either return value may contain a "validAfter" and "validUntil" timestamps, which is the time-range that this UserOperation is valid on-chain. -A node MAY drop a UserOperation if it expires too soon (e.g. wouldn't make it to the next block) by either the account or paymaster. -If the `ValidationResult` includes `sigFail`, the client SHOULD drop the `UserOperation`. - -In order to prevent DoS attack on bundlers, they must make sure the validation methods above pass the validation rules, which constraint their usage of opcodes and storage. -For the complete procedure see [ERC-7562](./erc-7562.md) - -#### Alternative Mempools - -The simulation rules above are strict and prevent the ability of paymasters and signature aggregators to grief the system. -However, there might be use-cases where specific paymasters (and signature aggregators) can be validated -(through manual auditing) and verified that they cannot cause any problem, while still require relaxing of the opcode rules. -A bundler cannot simply "whitelist" request from a specific paymaster: if that paymaster is not accepted by all -bundlers, then its support will be sporadic at best. -Instead, we introduce the term "alternate mempool": a modified validation rules, and procedure of propagating them to other bundlers. - -The procedure of using alternate mempools is defined in [ERC-7562](./erc-7562.md#Alt-mempools-rules) - -### Bundling - -During bundling, the client should: - -- Exclude UserOps that access any sender address of another UserOp in the same batch. -- Exclude UserOps that access any address created by another UserOp validation in the same batch (via a factory). -- For each paymaster used in the batch, keep track of the balance while adding UserOps. Ensure that it has sufficient deposit to pay for all the UserOps that use it. -- Sort UserOps by aggregator, to create the lists of UserOps-per-aggregator. -- For each aggregator, run the aggregator-specific code to create aggregated signature, and update the UserOps - -After creating the batch, before including the transaction in a block, the client should: - -- Run `debug_traceCall` with maximum possible gas, to enforce the validation rules on opcode and storage access. - as well as to verify the entire `handleOps` batch transaction, - and use the consumed gas for the actual transaction execution. -- If the call reverted, the bundler MUST use the trace result to find the entity that reverted the call. \ - This is the last entity that is CALL'ed by the EntryPoint prior to the revert. \ - (the bundler cannot assume the revert is `FailedOp`) -- If any verification context rule was violated the bundlers should treat it the same as - if this UserOperation reverted. -- Remove the offending UserOperation from the current bundle and from mempool. -- If the error is caused by a `factory` or a `paymaster`, and the `sender` - of the UserOp **is not** a staked entity, then issue a "ban" (see ["Reputation, throttling and banning"](#reputation-scoring-and-throttlingbanning-for-global-entities)) - for the guilty factory or paymaster. -- If the error is caused by a `factory` or a `paymaster`, and the `sender` - of the UserOp **is** a staked entity, do not ban the `factory` / `paymaster` from the mempool. - Instead, issue a "ban" for the staked `sender` entity. -- Repeat until `debug_traceCall` succeeds. - -As staked entries may use some kind of transient storage to communicate data between UserOperations in the same bundle, -it is critical that the exact same opcode and precompile banning rules as well as storage access rules are enforced -for the `handleOps` validation in its entirety as for individual UserOperations. -Otherwise, attackers may be able to use the banned opcodes to detect running on-chain and trigger a `FailedOp` revert. - -When a bundler includes a bundle in a block it must ensure that earlier transactions in the block don't make any UserOperation fail. It should either use access lists to prevent conflicts, or place the bundle as the first transaction in the block. - -### Error codes. - -While performing validation, the EntryPoint must revert on failures. During simulation, the calling bundler MUST be able to determine which entity (factory, account or paymaster) caused the failure. -The attribution of revert to entity is done using the call-tracing: the last entity called by the EntryPoint prior the revert is the entity that caused the revert. - -- For diagnostic purposes, the EntryPoint must only revert with explicit FailedOp() or FailedOpWithRevert() errors. -- The message of the error starts with event code, AA## -- Event code starting with "AA1" signify an error during account creation -- Event code starting with "AA2" signify an error during account validation (validateUserOp) -- Event code starting with "AA3" signify an error during paymaster validation (validatePaymasterUserOp) - -## Rationale - -The main challenge with a purely smart contract wallet based account abstraction system is DoS safety: how can a block builder including an operation make sure that it will actually pay fees, without having to first execute the entire operation? Requiring the block builder to execute the entire operation opens a DoS attack vector, as an attacker could easily send many operations that pretend to pay a fee but then revert at the last moment after a long execution. Similarly, to prevent attackers from cheaply clogging the mempool, nodes in the P2P network need to check if an operation will pay a fee before they are willing to forward it. - -The first step is clean separation between validation (acceptance of UserOperation, and acceptance to pay) and execution. -In this proposal, we expect accounts to have a `validateUserOp` method that takes as input a `UserOperation`, and verify the signature and pay the fee. -Only if this method returns successfully, the execution will happen. - -The entry point-based approach allows for a clean separation between verification and execution, and keeps accounts' logic simple. It enforces the simple rule that only after validation is successful (and the UserOp can pay), the execution is done, and also guarantees the fee payment. - -The last step is protecting the bundlers from denial-of-service attacks by a mass number of UserOperation that appear to be valid (and pay) but that eventually revert, and thus block the bundler from processing valid UserOperations. -For this purpose, the bundler requires a set of [restrictions on the validation function](./erc-7526.md), to prevent such denial-of-service attacks. - -### Reputation scoring and throttling/banning for global entities - -#### Reputation Rationale. - -UserOperation's storage access rules prevent them from interfere with each other. -But "global" entities - paymasters, factories and aggregators are accessed by multiple UserOperations, and thus might invalidate multiple previously-valid UserOperations. - -To prevent abuse, we throttle down (or completely ban for a period of time) an entity that causes invalidation of large number of UserOperations in the mempool. -To prevent such entities from "sybil-attack", we require them to stake with the system, and thus make such DoS attack very expensive. -Note that this stake is never slashed, and can be withdrawn any time (after unstake delay) - -Unstaked entities are allowed, under the rules below. - -When staked, an entity is less restricted in its memory usage. - -The stake value is not enforced on-chain, but specifically by each node while simulating a transaction. - -### Paymasters - -Paymaster contracts allow abstraction of gas: having a contract, that is not the sender of the transaction, pay for the transaction fees. - -Paymaster architecture allows them to follow the model of "pre-charge, and later refund". -E.g. a token-paymaster may pre-charge the user with the max possible price of the transaction, and refund the user with the excess afterwards. - -### First-time account creation - -It is an important design goal of this proposal to replicate the key property of EOAs that users do not need to perform some custom action or rely on an existing user to create their wallet; they can simply generate an address locally and immediately start accepting funds. - -The wallet creation itself is done by a "factory" contract, with wallet-specific data. -The factory is expected to use CREATE2 (not CREATE) to create the wallet, so that the order of creation of wallets doesn't interfere with the generated addresses. -The `initCode` field (if non-zero length) is parsed as a 20-byte address, followed by "calldata" to pass to this address. -This method call is expected to create a wallet and return its address. -If the factory does use CREATE2 or some other deterministic method to create the wallet, it's expected to return the wallet address even if the wallet has already been created. This is to make it easier for clients to query the address without knowing if the wallet has already been deployed, by simulating a call to `entryPoint.getSenderAddress()`, which calls the factory under the hood. -When `initCode` is specified, if either the `sender` address points to an existing contract, or (after calling the initCode) the `sender` address still does not exist, -then the operation is aborted. -The `initCode` MUST NOT be called directly from the entryPoint, but from another address. -The contract created by this factory method should accept a call to `validateUserOp` to validate the UserOp's signature. -For security reasons, it is important that the generated contract address will depend on the initial signature. -This way, even if someone can create a wallet at that address, he can't set different credentials to control it. -The factory has to be staked if it accesses global storage - see [reputation, throttling and banning section](#reputation-scoring-and-throttlingbanning-for-global-entities) for details. - -NOTE: In order for the wallet to determine the "counterfactual" address of the wallet (prior its creation), -it should make a static call to the `entryPoint.getSenderAddress()` - -### Entry point upgrading - -Accounts are encouraged to be DELEGATECALL forwarding contracts for gas efficiency and to allow account upgradability. The account code is expected to hard-code the entry point into their code for gas efficiency. If a new entry point is introduced, whether to add new functionality, improve gas efficiency, or fix a critical security bug, users can self-call to replace their account's code address with a new code address containing code that points to a new entry point. During an upgrade process, it's expected that two mempools will run in parallel. - -### RPC methods (eth namespace) - -#### \* eth_sendUserOperation - -eth_sendUserOperation submits a User Operation object to the User Operation pool of the client. The client MUST validate the UserOperation, and return a result accordingly. - -The result `SHOULD` be set to the **userOpHash** if and only if the request passed simulation and was accepted in the client's User Operation pool. If the validation, simulation, or User Operation pool inclusion fails, `result` `SHOULD NOT` be returned. Rather, the client `SHOULD` return the failure reason. - -##### Parameters: - -1. **UserOperation** a full user-operation struct. All fields MUST be set as hex values. empty `bytes` block (e.g. empty `initCode`) MUST be set to `"0x"` -2. **factory** and **factoryData** - either both exist, or none -3. paymaster fields (**paymaster**, **paymasterData**, **paymasterValidationGasLimit**, **paymasterPostOpGasLimit**) either all exist, or none. -4. **EntryPoint** the entrypoint address the request should be sent through. this MUST be one of the entry points returned by the `supportedEntryPoints` rpc call. - -##### Return value: - -- If the UserOperation is valid, the client MUST return the calculated **userOpHash** for it -- in case of failure, MUST return an `error` result object, with `code` and `message`. The error code and message SHOULD be set as follows: - - **code: -32602** - invalid UserOperation struct/fields - - **code: -32500** - transaction rejected by entryPoint's simulateValidation, during wallet creation or validation - - The `message` field MUST be set to the FailedOp's "`AAxx`" error message from the EntryPoint - - **code: -32501** - transaction rejected by paymaster's validatePaymasterUserOp - - The `message` field SHOULD be set to the revert message from the paymaster - - The `data` field MUST contain a `paymaster` value - - **code: -32502** - transaction rejected because of opcode validation - - **code: -32503** - UserOperation out of time-range: either wallet or paymaster returned a time-range, and it is already expired (or will expire soon) - - The `data` field SHOULD contain the `validUntil` and `validAfter` values - - The `data` field SHOULD contain a `paymaster` value, if this error was triggered by the paymaster - - **code: -32504** - transaction rejected because paymaster (or signature aggregator) is throttled/banned - - The `data` field SHOULD contain a `paymaster` or `aggregator` value, depending on the failed entity - - **code: -32505** - transaction rejected because paymaster (or signature aggregator) stake or unstake-delay is too low - - The `data` field SHOULD contain a `paymaster` or `aggregator` value, depending on the failed entity - - The `data` field SHOULD contain a `minimumStake` and `minimumUnstakeDelay` - - **code: -32506** - transaction rejected because wallet specified unsupported signature aggregator - - The `data` field SHOULD contain an `aggregator` value - - **code: -32507** - transaction rejected because of wallet signature check failed (or paymaster signature, if the paymaster uses its data as signature) - -##### Example: - -Request: - -```json= -{ - "jsonrpc": "2.0", - "id": 1, - "method": "eth_sendUserOperation", - "params": [ - { - sender, // address - nonce, // uint256 - factory, // address - factoryData, // bytes - callData, // bytes - callGasLimit, // uint256 - verificationGasLimit, // uint256 - preVerificationGas, // uint256 - maxFeePerGas, // uint256 - maxPriorityFeePerGas, // uint256 - paymaster, // address - paymasterVerificationGasLimit, // uint256 - paymasterPostOpGasLimit, // uint256 - paymasterData, // bytes - signature // bytes - }, - entryPoint // address - ] -} - -``` - -Response: - -``` -{ - "jsonrpc": "2.0", - "id": 1, - "result": "0x1234...5678" -} -``` - -##### Example failure responses: - -```json -{ - "jsonrpc": "2.0", - "id": 1, - "error": { - "message": "AA21 didn't pay prefund", - "code": -32500 - } -} -``` - -```json -{ - "jsonrpc": "2.0", - "id": 1, - "error": { - "message": "paymaster stake too low", - "data": { - "paymaster": "0x123456789012345678901234567890123456790", - "minimumStake": "0xde0b6b3a7640000", - "minimumUnstakeDelay": "0x15180" - }, - "code": -32504 - } -} -``` - -#### \* eth_estimateUserOperationGas - -Estimate the gas values for a UserOperation. -Given UserOperation optionally without gas limits and gas prices, return the needed gas limits. -The signature field is ignored by the wallet, so that the operation will not require user's approval. -Still, it might require putting a "semi-valid" signature (e.g. a signature in the right length) - -**Parameters**: - -- Same as `eth_sendUserOperation`\ - gas limits (and prices) parameters are optional, but are used if specified. - `maxFeePerGas` and `maxPriorityFeePerGas` default to zero, so no payment is required by neither account nor paymaster. -- Optionally accepts the `State Override Set` to allow users to modify the state during the gas estimation.\ - This field as well as its behavior is equivalent to the ones defined for `eth_call` RPC method. - -**Return Values:** - -- **preVerificationGas** gas overhead of this UserOperation -- **verificationGasLimit** actual gas used by the validation of this UserOperation -- **callGasLimit** value used by inner account execution -- **paymasterVerificationGasLimit** value used for paymaster verification (if paymaster exists in the UserOperation) -- **paymasterPostOpGasLimit** value used for paymaster post op execution (if paymaster exists in the UserOperation) - -##### Error Codes: - -Same as `eth_sendUserOperation` -This operation may also return an error if the inner call to the account contract reverts. - -#### \* eth_getUserOperationByHash - -Return a UserOperation based on a hash (userOpHash) returned by `eth_sendUserOperation` - -**Parameters** - -- **hash** a userOpHash value returned by `eth_sendUserOperation` - -**Return value**: - -- If the UserOperation is included in a block: - - Return a full UserOperation, with the addition of `entryPoint`, `blockNumber`, `blockHash` and `transactionHash`. - -- Else if the UserOperation is pending in the bundler's mempool: - - MAY return `null`, or: a full UserOperation, with the addition of the `entryPoint` field and a `null` value for `blockNumber`, `blockHash` and `transactionHash`. - -- Else: - - Return `null` - -#### \* eth_getUserOperationReceipt - -Return a UserOperation receipt based on a hash (userOpHash) returned by `eth_sendUserOperation` - -**Parameters** - -- **hash** a userOpHash value returned by `eth_sendUserOperation` - -**Return value**: - -`null` in case the UserOperation is not yet included in a block, or: - -- **userOpHash** the request hash -- **entryPoint** -- **sender** -- **nonce** -- **paymaster** the paymaster used for this userOp (or empty) -- **actualGasCost** - actual amount paid (by account or paymaster) for this UserOperation -- **actualGasUsed** - total gas used by this UserOperation (including preVerification, creation, validation and execution) -- **success** boolean - did this execution completed without revert -- **reason** in case of revert, this is the revert reason -- **logs** the logs generated by this UserOperation (not including logs of other UserOperations in the same bundle) -- **receipt** the TransactionReceipt object. - Note that the returned TransactionReceipt is for the entire bundle, not only for this UserOperation. - -#### \* eth_supportedEntryPoints - -Returns an array of the entryPoint addresses supported by the client. The first element of the array `SHOULD` be the entryPoint addressed preferred by the client. - -```json= -# Request -{ - "jsonrpc": "2.0", - "id": 1, - "method": "eth_supportedEntryPoints", - "params": [] -} - -# Response -{ - "jsonrpc": "2.0", - "id": 1, - "result": [ - "0xcd01C8aa8995A59eB7B2627E69b40e0524B5ecf8", - "0x7A0A0d159218E6a2f407B99173A2b12A6DDfC2a6" - ] -} -``` - -#### \* eth_chainId - -Returns [EIP-155](./eip-155.md) Chain ID. - -```json= -# Request -{ - "jsonrpc": "2.0", - "id": 1, - "method": "eth_chainId", - "params": [] -} - -# Response -{ - "jsonrpc": "2.0", - "id": 1, - "result": "0x1" -} -``` - -### RPC methods (debug Namespace) - -This api must only be available on testing mode and is required by the compatibility test suite. In production, any `debug_*` rpc calls should be blocked. - -#### \* debug_bundler_clearState - -Clears the bundler mempool and reputation data of paymasters/accounts/factories/aggregators. - -```json= -# Request -{ - "jsonrpc": "2.0", - "id": 1, - "method": "debug_bundler_clearState", - "params": [] -} - -# Response -{ - "jsonrpc": "2.0", - "id": 1, - "result": "ok" -} -``` - -#### \* debug_bundler_dumpMempool - -Dumps the current UserOperations mempool - -**Parameters:** - -- **EntryPoint** the entrypoint used by eth_sendUserOperation - -**Returns:** - -`array` - Array of UserOperations currently in the mempool. - -```json= -# Request -{ - "jsonrpc": "2.0", - "id": 1, - "method": "debug_bundler_dumpMempool", - "params": ["0x1306b01bC3e4AD202612D3843387e94737673F53"] -} - -# Response -{ - "jsonrpc": "2.0", - "id": 1, - "result": [ - { - sender, // address - nonce, // uint256 - factory, // address - factoryData, // bytes - callData, // bytes - callGasLimit, // uint256 - verificationGasLimit, // uint256 - preVerificationGas, // uint256 - maxFeePerGas, // uint256 - maxPriorityFeePerGas, // uint256 - signature // bytes - } - ] -} -``` - -#### \* debug_bundler_sendBundleNow - -Forces the bundler to build and execute a bundle from the mempool as `handleOps()` transaction. - -Returns: `transactionHash` - -```json= -# Request -{ - "jsonrpc": "2.0", - "id": 1, - "method": "debug_bundler_sendBundleNow", - "params": [] -} - -# Response -{ - "jsonrpc": "2.0", - "id": 1, - "result": "0xdead9e43632ac70c46b4003434058b18db0ad809617bd29f3448d46ca9085576" -} -``` - -#### \* debug_bundler_setBundlingMode - -Sets bundling mode. - -After setting mode to "manual", an explicit call to debug_bundler_sendBundleNow is required to send a bundle. - -##### parameters: - -`mode` - 'manual' | 'auto' - -```json= -# Request -{ - "jsonrpc": "2.0", - "id": 1, - "method": "debug_bundler_setBundlingMode", - "params": ["manual"] -} - -# Response -{ - "jsonrpc": "2.0", - "id": 1, - "result": "ok" -} -``` - -#### \* debug_bundler_setReputation - -Sets reputation of given addresses. parameters: - -**Parameters:** - -- An array of reputation entries to add/replace, with the fields: - - `address` - The address to set the reputation for. - - `opsSeen` - number of times a user operations with that entity was seen and added to the mempool - - `opsIncluded` - number of times a user operations that uses this entity was included on-chain - -- **EntryPoint** the entrypoint used by eth_sendUserOperation - -```json= -# Request -{ - "jsonrpc": "2.0", - "id": 1, - "method": "debug_bundler_setReputation", - "params": [ - [ - { - "address": "0x7A0A0d159218E6a2f407B99173A2b12A6DDfC2a6", - "opsSeen": "0x14", - "opsIncluded": "0x0D" - } - ], - "0x1306b01bC3e4AD202612D3843387e94737673F53" - ] -} - -# Response -{ - "jsonrpc": "2.0", - "id": 1, - "result": "ok" -} -``` - -#### \* debug_bundler_dumpReputation - -Returns the reputation data of all observed addresses. -Returns an array of reputation objects, each with the fields described above in `debug_bundler_setReputation` with the - -**Parameters:** - -- **EntryPoint** the entrypoint used by eth_sendUserOperation - -**Return value:** - -An array of reputation entries with the fields: - -- `address` - The address to set the reputation for. -- `opsSeen` - number of times a user operations with that entity was seen and added to the mempool -- `opsIncluded` - number of times a user operations that uses this entity was included on-chain -- `status` - (string) The status of the address in the bundler 'ok' | 'throttled' | 'banned'. - -```json= -# Request -{ - "jsonrpc": "2.0", - "id": 1, - "method": "debug_bundler_dumpReputation", - "params": ["0x1306b01bC3e4AD202612D3843387e94737673F53"] -} - -# Response -{ - "jsonrpc": "2.0", - "id": 1, - "result": [ - { "address": "0x7A0A0d159218E6a2f407B99173A2b12A6DDfC2a6", - "opsSeen": "0x14", - "opsIncluded": "0x13", - "status": "ok" - } - ] -} -``` - -#### \* debug_bundler_addUserOps - -Accept UserOperations into the mempool. -Assume the given UserOperations all pass validation (without actually validating them), and accept them directly into th mempool - -**Parameters:** - -- An array of UserOperations - -```json= -# Request -{ - "jsonrpc": "2.0", - "id": 1, - "method": "debug_bundler_addUserOps", - "params": [ - [ - { sender: "0xa...", ... }, - { sender: "0xb...", ... } - ] - ] -} - -# Response -{ - "jsonrpc": "2.0", - "id": 1, - "result": "ok" -} -``` - -## Backwards Compatibility - -This ERC does not change the consensus layer, so there are no backwards compatibility issues for Ethereum as a whole. Unfortunately it is not easily compatible with pre-[ERC-4337](./eip-4337.md) accounts, because those accounts do not have a `validateUserOp` function. If the account has a function for authorizing a trusted op submitter, then this could be fixed by creating an [ERC-4337](./eip-4337.md) compatible account that re-implements the verification logic as a wrapper and setting it to be the original account's trusted op submitter. - -## Reference Implementation - -See `https://github.com/eth-infinitism/account-abstraction/tree/main/contracts` - -## Security Considerations - -The entry point contract will need to be very heavily audited and formally verified, because it will serve as a central trust point for _all_ [ERC-4337]. In total, this architecture reduces auditing and formal verification load for the ecosystem, because the amount of work that individual _accounts_ have to do becomes much smaller (they need only verify the `validateUserOp` function and its "check signature and pay fees" logic) and check that other functions are `msg.sender == ENTRY_POINT` gated (perhaps also allowing `msg.sender == self`), but it is nevertheless the case that this is done precisely by concentrating security risk in the entry point contract that needs to be verified to be very robust. - -Verification would need to cover two primary claims (not including claims needed to protect paymasters, and claims needed to establish p2p-level DoS resistance): - -- **Safety against arbitrary hijacking**: The entry point only calls an account generically if `validateUserOp` to that specific account has passed (and with `op.calldata` equal to the generic call's calldata) -- **Safety against fee draining**: If the entry point calls `validateUserOp` and passes, it also must make the generic call with calldata equal to `op.calldata` - -## Copyright - -Copyright and related rights waived via [CC0](../LICENSE.md). diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/ERCS/erc-7562.md b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/ERCS/erc-7562.md deleted file mode 100644 index 6126265cf1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/ERCS/erc-7562.md +++ /dev/null @@ -1,393 +0,0 @@ ---- -eip: 7562 -title: Account Abstraction Validation Scope Rules -description: A set of limitations on validation EVM code to protect Account Abstraction nodes from denial-of-service attacks through unpaid computation. -author: Yoav Weiss (@yoavw), Dror Tirosh (@drortirosh), Alex Forshtat (@forshtat), Shahaf Nacson (@shahafn) -discussions-to: https://ethereum-magicians.org/t/erc-7562-account-abstraction-validation-scope-rules/16683 -status: Draft -type: Standards Track -category: ERC -created: 2023-09-01 ---- - -## Abstract - -This document describes the rules we impose on the validation context of Account Abstraction transactions, -such as [ERC-4337](./erc-4337.md) `UserOperation` or [RIP-7560](./rip-7560.md) (Native Account Abstraction), which are enforced off-chain by a -block builder or a standalone bundler, and the rationale behind each one of them. - -## Motivation - -With Account-Abstraction, instead of hard-coded logic for processing a transaction (validation, gas-payment, and execution), this logic is executed by EVM code. -The benefits for the account are countless - - -- abstracting the validation allows the contract to use different signature schemes, multisig configuration, custom recovery, and more. -- abstracting gas payments allows easy onboarding by 3rd party payments, paying with tokens, cross-chain gas payments -- abstracting execution allows batch transactions - -All of the above are missing from the EOA account model. - -However, there is one rule a transaction must follow to preserve the decentralized network: once submitted into the network (the mempool), the transaction is guaranteed to pay. This comes to prevent denial of service attacks on the network. - -The EOA model implicitly follows the rule: a valid transaction can't become invalid without payment by the account: e.g account balance can't be reduced (except with a higher paying transaction) - -This simple rule makes the network sustainable and DoS-protected: the network can't be cheaply attacked by a mass of transactions. An attack (sending a mass of transactions) is expensive, and gets more expensive as the network clogs. Legitimate users pay more, and can delay operations to avoid the cost, but the attacker pays a huge (and increasing) amount to keep the network clogged. - -For Account-Abstraction system we want to keep the same rule, so that attempting a DoS attack on the network should be as expensive. -In order to do so, we add the following validation rules. - -For the actual interfaces of those contract-based accounts see the definitions in ERC-4337 and RIP-7560. - -This documentation uses the terminology "UserOperation" for a transaction created by a smart contract account, and closely follows [ERC-4337](./erc-4337.md) terminology. -However, the rules apply to any account-abstraction framework that uses EVM code to perform transaction validation and makes a distinction between validation and execution. - -## Rationale - -All transactions initiated by EOAs have an implicit validation phase where balance, nonce, and signature are -checked to be valid for the current state of the Ethereum blockchain. -Once the transaction is checked to be valid by a node, only another transaction by the same EOA can modify the Ethereum -state in a way that makes the first transaction invalid. - -With Account Abstraction, however, the validation can also include an arbitrary EVM code and rely on storage as well, -which means that unrelated `UserOperations` or transactions may invalidate each other. - -If not addressed, this would make the job of maintaining a mempool of valid `UserOperations` and producing valid -bundles computationally infeasible and susceptible to DoS attacks. - -This document describes a set of validation rules that if applied by a bundler before accepting a `UserOperation` -into the mempool can prevent such attacks. - -### The high-level goal - -The purpose of this specification is to define a consensus between nodes (bundlers or block-builders) when processing incoming UserOperations from an external source. -This external source for UserOperations is either an end-user node (via RPC) or another node in the p2p network. - -The protocol tries to detect "spam" - which are large bursts of UserOperations that cannot be included on-chain (and thus can't pay). -The network is protected by throttling down requests from such spammer nodes. - -All nodes in the network must have the same definition of "spam": otherwise, if some nodes accept some type of UserOperations and propagate them while others consider them spam, those "forgiving" nodes will be considered "spammers" by the rest of the nodes, and the network effectively gets split. - -### The processing flow of a UserOperation - -- First, a UserOperation is received - either via RPC (submitted on behalf of a single application) or via the p2p protocol, from another node in the mempool. -- The node performs validation on the UserOperation, and then adds it to its in-memory mempool, and submits it to its peers. -- Lastly, when building a block, a node collects UserOperations from the mempool, performs a 2nd validation to make sure they are all still valid as a bundle and submits them into the next block. - -### The need for 2nd validation before submitting a block - -A normal Ethereum transaction in the mempool can be invalidated if another transaction was received with the same nonce. That other transaction had to increase the gas price in order to replace the first one, so it satisfied the rule of "must pay to get included into the mempool" -With contract-based accounts, since the UserOperation validity may depend on mutable state, other transactions may invalidate a previously valid UserOperation, so we must check it before inclusion - -### Rationale of limiting opcodes: - -- the validation is performed off-chain, before creating a block. Some opcodes access information that is known only when creating the block. -- using those opcodes while validating a transaction can easily create a validation rule that will succeed off-chain, but always revert on-chain, and thus cause a DoS attack. -- a simple example is `require block.number==12345`. It can be valid when validating the UserOperation and adding it to the mempool - but will be invalid when attempting to include it on-chain at a later block. - -### Rationale for limiting storage access - -- We need UserOperation validations not to overlap so that a single storage change can't easily invalidate a large number of UserOperations in the mempool. By limiting UserOperations to access storage associated with the account itself, we know that we can for sure include a single UserOperation for each account in a bundle -- (A bundler MAY include more than one UserOperation of an account in a bundle, MUST first validate them together) - -### Rationale of requiring a stake - -We want to be able to allow globally-used contracts (paymasters, factories) to use storage not associated with the account, but still prevent them from -spamming the mempool. -If a contract causes too many UserOperations to fail in their second validation after succeeding in their first, we can throttle its use in the mempool. -By requiring such a contract to have a stake, we prevent a "Sybil attack", by making it expensive to create a large number of such paymasters to continue the spam attack. - -By following the validation rules, we can detect contracts that cause spam UserOperations, and throttle them. -The stake comes to prevent the fast re-creation of malicious entities. -The stake is never slashed (since it is only used for off-chain detection) but is locked for a period of time, which makes such an attack much more expensive. - -### Definition of the `mass invalidation attack` - -A possible set of actions is considered to be a `mass invalidation attack` on the network if a large number of -`UserOperations` that did pass the initial validation and were accepted by nodes and propagated further into the -mempool to other bundlers in the network becomes invalid and not eligible for inclusion in a block. - -There are 3 ways to perform such an attack: - -1. Submit `UserOperation`s that pass the initial validation, but later fail the re-validation - that is performed during the bundle creation. -2. Submit `UserOperation`s that are valid in isolation during validation, but when bundled - together become invalid. -3. Submit valid `UserOperation`s but "front-run" them by executing a state change on the - network that causes them to become invalid. The "front-run" in question must be economically viable. - -To prevent such attacks, we attempt to "sandbox" the validation code. -We isolate the validation code from other `UserOperations`, from external changes to the storage, and -from information about the environment such as a current block timestamp. - -### What is not considered a `mass invalidation attack` - -A `UserOperation` that fails the initial validation by a receiving node without entering its mempool is not -considered an attack. The node is expected to apply web2 security measures and throttle requests based on API key, -source IP address, etc. -RPC nodes already do that to prevent being spammed with invalid transactions which also have a validation cost. -P2P nodes already have (and should apply) a scoring mechanism to determine spammer nodes. - -Also, if the invalidation of `N` UserOperations from the mempool costs `N*X` with a sufficiently large `X`, it is not considered an economically viable attack. - -- The minimum change to cause an invalidation is a storage change (5k gas) -- Assuming a Node can sustain processing 2000 invalid UserOps per block, the cost of a DoS attack is 10M gas per block. -- The above value is high, but we take further measures to make such an attack more expensive. - -## Specification - -### Rule Types - -There are two types of rules: - -- **Network-wide rules** rules that MUST be applied to each UserOperation before accepting it into the local mempool and propagating it. - These rules include the opcode and storage rules. - - Failing these validation rules SHOULD drop the UserOperation - - Failing these validations during 2nd validation phase (before submitting a bundle) SHOULD degrade - the reputation of the offending entity - - Bundler MUST NOT propagate UserOperations that fail the validation rules, otherwise - it will be considered a "spammer" by other bundlers in the mempool, and get disconnected. - -- **Local rules** - These are "soft" rules, based on the reputation of entities. - These rules come to protect the bundler itself from spamming attacks. - - Bundlers SHOULD drop such UserOperations without performing validation. - - Bundlers SHOULD NOT propagate such UserOperations to other bundlers. - - Bundlers SHOULD NOT consider another bundler a "spammer" if it does. - -### Constants - -| Title | Value | Comment | -| ------------------------------------ | --------------------------- | ------------------------------------------------------------------------------- | -| `MIN_UNSTAKE_DELAY` | 86400 | 1 day | -| `MIN_STAKE_VALUE` | Adjustable per chain value | Equivalent to ~$1000 in native tokens | -| `SAME_SENDER_MEMPOOL_COUNT` | 4 | | -| `SAME_UNSTAKED_ENTITY_MEMPOOL_COUNT` | 10 | | -| `THROTTLED_ENTITY_MEMPOOL_COUNT` | 4 | Number of `UserOperations` with a throttled entity that can stay in the mempool | -| `THROTTLED_ENTITY_LIVE_BLOCKS` | 10 | Number of blocks a `UserOperations` with a throttled entity can stay in mempool | -| `THROTTLED_ENTITY_BUNDLE_COUNT` | 4 | | -| `MIN_INCLUSION_RATE_DENOMINATOR` | 100 (client) \ 10 (bundler) | | -| `THROTTLING_SLACK` | 10 | | -| `BAN_SLACK` | 50 | | -| `BAN_OPS_SEEN_PENALTY` | 10000 | | -| `MAX_OPS_ALLOWED_UNSTAKED_ENTITY` | 10000 | - -### Validation Rules - -### **Definitions**: - -1. **Validation Phases**: there are up to 3 phases of validation - 1. smart account deployment - 2. smart account validation - 3. paymaster validation. -2. **Entity**: a contract that is explicitly specified by the `UserOperation`. - Includes the `factory`, `paymaster`, `aggregator`, and staked `account`, as discussed below. \ - Each "validation phase" is attributed to a single entity. \ - Entity contracts must have non-empty code on-chain. -3. **Canonical Mempool**: The rules defined in this document apply to the main mempool shared by all bundlers on the network. -4. **Staked Entity:** an entity that has a locked stake of at least `MIN_STAKE_VALUE` - and an unstake delay of at least `MIN_UNSTAKE_DELAY`. -5. **Associated storage:** a storage slot of any smart contract is considered to be "associated" with address `A` if: - 1. The slot value is `A` - 2. The slot value was calculated as `keccak(A||x)+n`, where `x` is a `bytes32` value, and `n` is a value in the range 0..128 -6. **Using an address**: accessing the code of a given address in any way. - This can be done by executing `*CALL` or `EXTCODE*` opcodes for a given address. - -### Reputation Definitions - -1. **opsSeen**: a per-entity counter of how many times a unique valid `UserOperation` referencing this entity - was received by this bundler. - This includes `UserOperation` received via incoming RPC calls or through a P2P mempool protocol. - -2. **opsIncluded**: a per-entity counter of how many times a unique valid `UserOperation` referencing this entity - appeared in an actual included `UserOperation`. \ - Calculation of this value is based on UserOperationEvents and is only counted for `UserOperations` that were - previously counted as `opsSeen` by this bundler. -3. Both values are updated every hour as `value = value * 23 // 24` \ - Effectively, the value is reduced to 1% after 4 days. -4. **inclusionRate**: Relation of `opsIncluded` to `opsSeen` - -### Reputation Calculation - -We define a value `max_seen = opsSeen // MIN_INCLUSION_RATE_DENOMINATOR`. - -The reputation state of each entity is determined as follows: - -1. **BANNED**: `max_seen > opsIncluded + BAN_SLACK` -2. **THROTTLED**: `max_seen > opsIncluded + THROTTLING_SLACK` -3. **OK**: otherwise - -Note that new entities start with an `OK` reputation. - -To help make sense of these params, note that a malicious paymaster can at most cause the network (only the p2p network, not the blockchain) to process `BAN_SLACK * MIN_INCLUSION_RATE_DENOMINATOR / 24` non-paying ops per hour. - -### Running the Validation Rules - -1. A block builder or a bundler should perform a full validation before accepting a `UserOperation` into its mempool. -2. During the validation phase, the bundler should trace the execution and apply all the rules defined in this document. -3. A bundler should also perform a full validation of the entire bundle before submission. -4. The validation rules prevent an unstaked entity from detecting the bundle validation. - However, a malicious staked entity can detect that it is running in a bundle validation and cause a revert. -5. The failed `UserOperation` should be dropped from the bundle. -6. The staked entity that caused a revert violated the Account Abstraction rules and should be marked as `THROTTLED`. - -### Mempool Validation Rules - -1. A `UserOperation` is broadcast over the P2P protocol with the following information: - 1. The `UserOperation` itself - 2. The blockhash this `UserOperation` was originally verified against. -2. Once a `UserOperation` is received from another bundler it should be verified locally by a receiving bundler. -3. A received `UserOperation` may fail any of the reasonable static checks, such as: \ - invalid format, values below minimum, submitted with a blockhash that isn't recent, etc. \ - In this case, the bundler should drop this particular `UserOperation` but keep the connection. -4. The bundler should check the `UserOperation` against the nonces of last-included bundles. \ - Silently drop `UserOperations` with `nonce` that was recently included. - This invalidation is likely attributable to a network race condition and should not cause a reputation change. -5. If a received `UserOperation` fails against the current block: - 1. Retry the validation against the block the `UserOperation` was originally verified against. - 2. If it succeeds, silently drop the `UserOperation` and keep the connection. - 3. If it fails, mark the sender as a "spammer" - -### Opcode Rules - -- Block access from opcodes that access information outside of storage and code (aka "environment"). - - **[OP-011]** Blocked Opcodes: - - `BALANCE` (`0x31`) - - `ORIGIN` (`0x32`) - - `GASPRICE` (`0x3A`) - - `BLOCKHASH` (`0x40`) - - `COINBASE` (`0x41`) - - `TIMESTAMP` (`0x42`) - - `NUMBER` (`0x43`) - - `PREVRANDAO`/`DIFFICULTY` (`0x44`) - - `GASLIMIT` (`0x45`) - - `SELFBALANCE` (`0x47`) - - `BASEFEE` (`0x48`) - - `GAS` (`0x5A`) - - `CREATE` (`0xF0`) - - `INVALID` (`0xFE`) - - `SELFDESTRUCT` (`0xFF`) - - **[OP-012]** `GAS `opcode is allowed, but only if followed immediately by `*CALL` instructions.\ - This is a common way to pass all remaining gas to an external call, and it means that the actual value is - consumed from the stack immediately and cannot be accessed by any other opcode. - - **[OP-13]** any "unassigned" opcode. -- **[OP-020]** Revert on "out of gas" is forbidden as it can "leak" the gas limit or the current call stack depth. -- Contract creation: - - **[OP-031]** `CREATE2` is allowed exactly once in the deployment phase and must deploy code for the "sender" address. -- Access to an address without a deployed code is forbidden: - - **[OP-041]** For `EXTCODE*` and `*CALL` opcodes. - - **[OP-042]** Exception: access to the "sender" address is allowed. - This is only possible in `factory` code during the deployment phase. -- Allowed access to the `EntryPoint` address: - - **[OP-051]** May call `EXTCODESIZE ISZERO`\ - This pattern is used to check destination has a code before the `depositTo` function is called. - - **[OP-052]** May call `depositTo(sender)` with any value from either the `sender` or `factory`. - - **[OP-053]** May call the fallback function from the `sender` with any value. - - **[OP-054]** Any other access to the `EntryPoint` is forbidden. -- `*CALL` opcodes: - - **[OP-061]** `CALL` with `value` is forbidden. The only exception is a call to the `EntryPoint` described above. - - **[OP-062]** Precompiles: - - Only allow known accepted precompiles on the network, that do not access anything in the blockchain state or environment. - - The core precompiles 0x1 .. 0x9 - - The [RIP-7212](./rip-7212.md) sec256r1 precompile, on networks that accepted it. -- **[OP-070]** Transient Storage slots defined in [EIP-1153](./eip-1153) and accessed using `TLOAD` (`0x5c`) and `TSTORE` (`0x5d`) opcodes - are treated exactly like persistent storage (SLOAD/SSTORE). - -### Code Rules - -- **[COD-010]** Between the first and the second validations, the `EXTCODEHASH` value of any visited address, - entity, or referenced library, may not be changed.\ - If the code is modified, the UserOperation is considered invalid. - -### Storage Rules - -The permanent storage access with `SLOAD` and `SSTORE` instructions within each phase is limited as follows: - -- **[STO-010]** Access to the "account" storage is always allowed. -- Access to associated storage of the account in an external (non-entity) contract is allowed if either: - - **[STO-021]** The account already exists. - - **[STO-022]** There is an `initCode` and the `factory` contract is staked. -- If the entity (`paymaster`, `factory`) is staked, then it is also allowed: - - **[STO-031]** Access the entity's own storage. - - **[STO-032]** Read/Write Access to storage slots that are associated with the entity, in any non-entity contract. - - **[STO-033]** Read-only access to any storage in non-entity contract. - -### Local Rules - -Local storage rules protect the bundler against denial of service at the time of bundling. They do not affect mempool propagation and cannot cause a bundler to be marked as a "spammer". - -- **[STO-040]** `UserOperation` may not use an entity address (`factory`/`paymaster`/`aggregator`) that is used as an "account" in another `UserOperation` in the mempool. \ - This means that `Paymaster` and `Factory` contracts cannot practically be an "account" contract as well. -- **[STO-041]** `UserOperation` may not use associated storage (of either its account or from staked entity) in a contract that is a "sender" of another UserOperation in the mempool. - -### General Reputation Rules - -The following reputation rules apply for all staked entities, and for unstaked paymasters. All rules apply to all of these entities unless specified otherwise. - -- **[GREP-010]** A `BANNED` address is not allowed into the mempool.\ - Also, all existing `UserOperations` referencing this address are removed from the mempool. -- **[GREP-020]** A `THROTTLED` address is limited to: - - `THROTTLED_ENTITY_MEMPOOL_COUNT` entries in the mempool. - - `THROTTLED_ENTITY_BUNDLE_COUNT` `UserOperations` in a bundle. - - Can remain in the mempool only for `THROTTLED_ENTITY_LIVE_BLOCKS`. -- **[GREP-040]** If an entity fails the bundle creation after passing second validation, its `opsSeen` set to `BAN_OPS_SEEN_PENALTY`, and `opsIncluded` to zero, causing it to be `BANNED`. - -### Staked Entities Reputation Rules - -- **[SREP-010]** The "canonical mempool" defines a staked entity if it has `MIN_STAKE_VALUE` and unstake delay of `MIN_UNSTAKE_DELAY` -- **[SREP-020]** An `OK` staked entity is unlimited by the reputation rule. - - Allowed in unlimited numbers in the mempool. - - Allowed in unlimited numbers in a bundle. - -### Entity-specific Rules - -- **[EREP-010]** For each `paymaster`, the mempool must maintain the total gas `UserOperations` using this `paymaster` may consume. - - Do not add a `UserOperation` to the mempool if the maximum total gas cost, including the new `UserOperation`, is above the deposit of the `paymaster` at the current gas price. -- **[EREP-015]** A `paymaster` should not have its opsSeen incremented on failure of factory or account - - When running 2nd validation (before inclusion in a bundle), if a UserOperation fails because of factory or account error (either a FailOp revert or validation rule), then the paymaster's opsSeen valid is decremented by 1. -- **[EREP-020]** A staked factory is "accountable" for account breaking the rules. \ - That is, if the `validateUserOp()` is rejected for any reason in a `UserOperation` that has an `initCode`, it is treated as if the factory caused this failure, and thus this affects its reputation. -- **[EREP-030]** A Staked Account is accountable for failures in other entities (`paymaster`, `aggregator`) even if they are staked. -- **[EREP-040]** An `aggregator` must be staked, regardless of storage usage. - -### Unstaked Paymasters Reputation Rules - -- Definitions: - - **`opsSeen`, `opsIncluded`, and reputation calculation** are defined above. - - `UnstakedReputation` of an entity determines the maximum number of entries using this entity allowed in the mempool. - - `opsAllowed` is a reputation-based calculation for an unstaked entity, representing how many `UserOperations` it is allowed to have in the mempool. - - Rules: - - **[UREP-010]** An unstaked sender is only allowed to have `SAME_SENDER_MEMPOOL_COUNT` `UserOperation`s in the mempool. A staked sender is only limited by the SREP rules. - - **[UREP-020]** For an unstaked paymaster only that is not throttled/banned: \ - `opsAllowed = SAME_UNSTAKED_ENTITY_MEMPOOL_COUNT + inclusionRate * min(opsIncluded, MAX_OPS_ALLOWED_UNSTAKED_ENTITY)`. - - This is a default of `SAME_UNSTAKED_ENTITY_MEMPOOL_COUNT` for new entity - -### Alt-mempools Rules - -Alternate mempool is an agreed-upon rule that the bundlers may opt into, in addition to the canonical mempool -The alt-mempool "topic" is a unique identifier. By convention, this is the IPFS hash of the document describing (in clear test and YAML file) the specifics of this alt mempool - -- **[ALT-010]** The bundler listens to the alt-mempool "topic" over the P2P protocol -- **[ALT-020]** The alt mempool rules MUST be checked only when a canonical rule is violated - - That is, if validation follows the canonical rules above, it is not considered part of an alt-mempool. -- **[ALT-021]** Such a `UserOperation` (that violates the canonical rules) is checked against all the "alternate mempools", and is considered part of all those alt-mempools -- **[ALT-030]** Bundlers SHOULD forward `UserOperations` to other bundlers only once, regardless of how many (shared) alt-mempools they have. \ - The receiving bundler validates the `UserOperations`, and based on the above rules (and subscribed alt-mempools) decides which alt-mempools to propagate it to. -- **[ALT-040]** opsInclude and opsSeen of entities are kept per alt-mempool. That is, an entity can be considered throttled (or banned) in one mempool, while still active on another. - -### Alt-mempool Reputation - -Alt-mempools are served by the same bundlers participating in the canonical mempool, but change the rules and may introduce denial-of-service attack vectors. To prevent them from taking the canonical mempool or other alt mempools down with them, a reputation is managed for each. An alt mempool that causes too many invalidations gets throttled. This limits the scope of the attack and lets the bundler continue doing its work for other mempools. - -- **[AREP-010]** each alt-mempool manages "opsSeen" and "opsIncluded", much like entities. The opsSeen is incremented after `UserOperation` initial validation, where it is considered part of this mempool. - The "opsIncluded" is incremented after this UserOperation is included on-chain (either by this bundler, or another) -- **[AREP-020]** the alt-mempool becomes THROTTLED based on the [Reputation Calculation](#reputation-calculation) - -## Security Considerations - -This document describes the security considerations bundlers must take to protect themselves (and the entire mempool network) -from denial-of-service attacks. - -## Copyright - -Copyright and related rights waived via [CC0](../LICENSE.md). diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/assets/erc-4337/bundle-seq-pm.svg b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/assets/erc-4337/bundle-seq-pm.svg deleted file mode 100644 index 67befce8e6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/assets/erc-4337/bundle-seq-pm.svg +++ /dev/null @@ -1 +0,0 @@ -EntryPointAccountPaymasterAccount21handleOps(userOps[]):Validation2validateUserOp3validatePaymasterUserOp4deduct paymaster depositExecution5exec6postOp7refund paymaster8compensate(beneficiary) \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/assets/erc-4337/bundle-seq.svg b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/assets/erc-4337/bundle-seq.svg deleted file mode 100644 index a637d705e1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/assets/erc-4337/bundle-seq.svg +++ /dev/null @@ -1 +0,0 @@ -EntryPointFactoryAccountAccount21handleOps(userOps[]):Validations2create (initCode)3create4account5validateUserOp6deposit7deduct account deposit8validateUserOp9deposit10deduct account2 depositExecutions11exec12refund account113exec14refund account215compensate(beneficiary) \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/assets/erc-4337/image1.png b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/assets/erc-4337/image1.png deleted file mode 100644 index ced8ea57d3..0000000000 Binary files a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/assets/erc-4337/image1.png and /dev/null differ diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/assets/erc-4337/image2.png b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/assets/erc-4337/image2.png deleted file mode 100644 index 6d0c6f71a4..0000000000 Binary files a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/erc/assets/erc-4337/image2.png and /dev/null differ diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/0-init-gas-checker.ts b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/0-init-gas-checker.ts deleted file mode 100644 index 78d6b7fc71..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/0-init-gas-checker.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { GasCheckCollector, GasChecker } from './GasChecker' - -describe('gas calculations', function () { - this.timeout(60000) - const g = new GasChecker() - - it('warmup', async function () { - await GasCheckCollector.init() - // dummy run - first run is slower. - await g.runTest({ title: 'simple', count: 1, diffLastGas: false }) - }) -}) diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/1-simple-wallet.gas.ts b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/1-simple-wallet.gas.ts deleted file mode 100644 index 0943d1f0d7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/1-simple-wallet.gas.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { GasChecker } from './GasChecker' - -context('simple account', function () { - this.timeout(60000) - const g = new GasChecker() - - it('simple 1', async function () { - await g.addTestRow({ title: 'simple', count: 1, diffLastGas: false }) - await g.addTestRow({ title: 'simple - diff from previous', count: 2, diffLastGas: true }) - }) - - it('simple 10', async function () { - if (g.skipLong()) this.skip() - await g.addTestRow({ title: 'simple', count: 10, diffLastGas: false }) - await g.addTestRow({ title: 'simple - diff from previous', count: 11, diffLastGas: true }) - }) -}) diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/2-paymaster.gas.ts b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/2-paymaster.gas.ts deleted file mode 100644 index ec95f9ad04..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/2-paymaster.gas.ts +++ /dev/null @@ -1,59 +0,0 @@ -import { parseEther } from 'ethers/lib/utils' -import { TestPaymasterAcceptAll__factory } from '../typechain' -import { ethers } from 'hardhat' -import { GasChecker } from './GasChecker' -import { Create2Factory } from '../src/Create2Factory' -import { hexValue } from '@ethersproject/bytes' - -const ethersSigner = ethers.provider.getSigner() - -context('Minimal Paymaster', function () { - this.timeout(60000) - const g = new GasChecker() - - let paymasterAddress: string - before(async () => { - const paymasterInit = hexValue( - new TestPaymasterAcceptAll__factory(ethersSigner).getDeployTransaction(g.entryPoint().address) - .data! - ) - paymasterAddress = await new Create2Factory(ethers.provider, ethersSigner).deploy( - paymasterInit, - 0 - ) - const paymaster = TestPaymasterAcceptAll__factory.connect(paymasterAddress, ethersSigner) - await paymaster.addStake(1, { value: 1 }) - await g.entryPoint().depositTo(paymaster.address, { value: parseEther('10') }) - }) - it('simple paymaster', async function () { - await g.addTestRow({ - title: 'simple paymaster', - count: 1, - paymaster: paymasterAddress, - diffLastGas: false, - }) - await g.addTestRow({ - title: 'simple paymaster with diff', - count: 2, - paymaster: paymasterAddress, - diffLastGas: true, - }) - }) - - it('simple paymaster 10', async function () { - if (g.skipLong()) this.skip() - - await g.addTestRow({ - title: 'simple paymaster', - count: 10, - paymaster: paymasterAddress, - diffLastGas: false, - }) - await g.addTestRow({ - title: 'simple paymaster with diff', - count: 11, - paymaster: paymasterAddress, - diffLastGas: true, - }) - }) -}) diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/3-huge-tx-gas.ts b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/3-huge-tx-gas.ts deleted file mode 100644 index 2983473c5d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/3-huge-tx-gas.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { DefaultGasTestInfo, GasChecker } from './GasChecker' - -context('huge tx - 5k', function () { - this.timeout(60000) - const huge = DefaultGasTestInfo.destCallData!.padEnd(10240, 'f') - const g = new GasChecker() - - it('big tx 5k', async () => { - await g.addTestRow({ title: 'big tx 5k', count: 1, destCallData: huge, diffLastGas: false }) - await g.addTestRow({ - title: 'big tx - diff from previous', - count: 2, - destCallData: huge, - diffLastGas: true, - }) - }) - it('big tx 10', async function () { - if (g.skipLong()) this.skip() - await g.addTestRow({ title: 'big tx 5k', count: 10, destCallData: huge, diffLastGas: false }) - await g.addTestRow({ - title: 'big tx - diff from previous', - count: 11, - destCallData: huge, - diffLastGas: true, - }) - }) -}) diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/4-paymaster-postop.gas.ts b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/4-paymaster-postop.gas.ts deleted file mode 100644 index d33e385069..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/4-paymaster-postop.gas.ts +++ /dev/null @@ -1,62 +0,0 @@ -import { parseEther } from 'ethers/lib/utils' -import { TestPaymasterWithPostOp__factory } from '../typechain' -import { ethers } from 'hardhat' -import { GasChecker } from './GasChecker' -import { Create2Factory } from '../src/Create2Factory' -import { hexValue } from '@ethersproject/bytes' - -const ethersSigner = ethers.provider.getSigner() - -context('Paymaster with PostOp', function () { - this.timeout(60000) - const g = new GasChecker() - - let paymasterAddress: string - - before(async () => { - const paymasterInit = hexValue( - new TestPaymasterWithPostOp__factory(ethersSigner).getDeployTransaction( - g.entryPoint().address - ).data! - ) - paymasterAddress = await new Create2Factory(ethers.provider, ethersSigner).deploy( - paymasterInit, - 0 - ) - const paymaster = TestPaymasterWithPostOp__factory.connect(paymasterAddress, ethersSigner) - await paymaster.addStake(1, { value: 1 }) - await g.entryPoint().depositTo(paymaster.address, { value: parseEther('10') }) - }) - - it('paymaster with PostOp', async function () { - await g.addTestRow({ - title: 'paymaster+postOp', - count: 1, - paymaster: paymasterAddress, - diffLastGas: false, - }) - await g.addTestRow({ - title: 'paymaster+postOp with diff', - count: 2, - paymaster: paymasterAddress, - diffLastGas: true, - }) - }) - - it('paymaster with postOp 10', async function () { - if (g.skipLong()) this.skip() - - await g.addTestRow({ - title: 'paymaster+postOp', - count: 10, - paymaster: paymasterAddress, - diffLastGas: false, - }) - await g.addTestRow({ - title: 'paymaster+postOp with diff', - count: 11, - paymaster: paymasterAddress, - diffLastGas: true, - }) - }) -}) diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/5-token-paymaster.gas.ts b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/5-token-paymaster.gas.ts deleted file mode 100644 index 985d1ac979..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/5-token-paymaster.gas.ts +++ /dev/null @@ -1,159 +0,0 @@ -import { parseEther } from 'ethers/lib/utils' -import { - TestERC20__factory, - TestOracle2__factory, - TestUniswap__factory, - TestWrappedNativeToken__factory, - TokenPaymaster, - TokenPaymaster__factory, -} from '../typechain' -import { ethers } from 'hardhat' -import { GasCheckCollector, GasChecker } from './GasChecker' -import { Create2Factory } from '../src/Create2Factory' -import { hexValue } from '@ethersproject/bytes' -import { - OracleHelper as OracleHelperNamespace, - UniswapHelper as UniswapHelperNamespace, -} from '../typechain/contracts/samples/TokenPaymaster' -import { BigNumber } from 'ethers' -import { createAccountOwner } from '../test/testutils' -// const ethersSigner = ethers.provider.getSigner() - -context('Token Paymaster', function () { - this.timeout(60000) - const g = new GasChecker() - - let paymasterAddress: string - before(async () => { - await GasCheckCollector.init() - const globalSigner = ethers.provider.getSigner() - const create2Factory = new Create2Factory(ethers.provider, globalSigner) - - const ethersSigner = createAccountOwner() - await globalSigner.sendTransaction({ to: ethersSigner.getAddress(), value: parseEther('10') }) - - const minEntryPointBalance = (1e17).toString() - const initialPriceToken = 100000000 // USD per TOK - const initialPriceEther = 500000000 // USD per ETH - const priceDenominator = BigNumber.from(10).pow(26) - - const tokenInit = await new TestERC20__factory(ethersSigner).getDeployTransaction(6) - const tokenAddress = await create2Factory.deploy(tokenInit, 0) - const token = TestERC20__factory.connect(tokenAddress, ethersSigner) - - const wethInit = await new TestWrappedNativeToken__factory(ethersSigner).getDeployTransaction() - const wethAddress = await create2Factory.deploy(wethInit, 0) - const testUniswapInit = await new TestUniswap__factory(ethersSigner).getDeployTransaction( - wethAddress - ) - const testUniswapAddress = await create2Factory.deploy(testUniswapInit, 0) - - const tokenPaymasterConfig: TokenPaymaster.TokenPaymasterConfigStruct = { - priceMaxAge: 86400, - refundPostopCost: 40000, - minEntryPointBalance, - priceMarkup: priceDenominator.mul(15).div(10), // +50% - } - - const nativeAssetOracleInit = await new TestOracle2__factory(ethersSigner).getDeployTransaction( - initialPriceEther, - 8 - ) - const nativeAssetOracleAddress = await create2Factory.deploy( - nativeAssetOracleInit, - 0, - 10_000_000 - ) - const tokenOracleInit = await new TestOracle2__factory(ethersSigner).getDeployTransaction( - initialPriceToken, - 8 - ) - const tokenOracleAddress = await create2Factory.deploy(tokenOracleInit, 0, 10_000_000) - - const oracleHelperConfig: OracleHelperNamespace.OracleHelperConfigStruct = { - cacheTimeToLive: 100000000, - maxOracleRoundAge: 0, - nativeOracle: nativeAssetOracleAddress, - nativeOracleReverse: false, - priceUpdateThreshold: priceDenominator.mul(2).div(10), // +20% - tokenOracle: tokenOracleAddress, - tokenOracleReverse: false, - tokenToNativeOracle: false, - } - - const uniswapHelperConfig: UniswapHelperNamespace.UniswapHelperConfigStruct = { - minSwapAmount: 1, - slippage: 5, - uniswapPoolFee: 3, - } - - const owner = await ethersSigner.getAddress() - - const paymasterInit = hexValue( - new TokenPaymaster__factory(ethersSigner).getDeployTransaction( - tokenAddress, - g.entryPoint().address, - wethAddress, - testUniswapAddress, - tokenPaymasterConfig, - oracleHelperConfig, - uniswapHelperConfig, - owner - ).data! - ) - paymasterAddress = await create2Factory.deploy(paymasterInit, 0) - const paymaster = TokenPaymaster__factory.connect(paymasterAddress, ethersSigner) - await paymaster.addStake(1, { value: 1 }) - await g.entryPoint().depositTo(paymaster.address, { value: parseEther('10') }) - await paymaster.updateCachedPrice(true) - await g.createAccounts1(11) - await token.sudoMint(await ethersSigner.getAddress(), parseEther('20')) - await token.transfer(paymaster.address, parseEther('0.1')) - for (const address of g.createdAccounts) { - await token.transfer(address, parseEther('1')) - await token.sudoApprove(address, paymaster.address, ethers.constants.MaxUint256) - } - - console.log('==addresses:', { - ethersSigner: await ethersSigner.getAddress(), - paymasterAddress, - nativeAssetOracleAddress, - tokenOracleAddress, - tokenAddress, - owner, - createdAccounts: g.createdAccounts, - }) - }) - - it('token paymaster', async function () { - await g.addTestRow({ - title: 'token paymaster', - count: 1, - paymaster: paymasterAddress, - diffLastGas: false, - }) - await g.addTestRow({ - title: 'token paymaster with diff', - count: 2, - paymaster: paymasterAddress, - diffLastGas: true, - }) - }) - - it('token paymaster 10', async function () { - if (g.skipLong()) this.skip() - - await g.addTestRow({ - title: 'token paymaster', - count: 10, - paymaster: paymasterAddress, - diffLastGas: false, - }) - await g.addTestRow({ - title: 'token paymaster with diff', - count: 11, - paymaster: paymasterAddress, - diffLastGas: true, - }) - }) -}) diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/GasChecker.ts b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/GasChecker.ts deleted file mode 100644 index 8a30d215a6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/gascalc/GasChecker.ts +++ /dev/null @@ -1,459 +0,0 @@ -// calculate gas usage of different bundle sizes -import '../test/aa.init' -import { defaultAbiCoder, hexConcat, parseEther } from 'ethers/lib/utils' -import { - AddressZero, - checkForGeth, - createAddress, - createAccountOwner, - deployEntryPoint, - decodeRevertReason, -} from '../test/testutils' -import { - EntryPoint, - EntryPoint__factory, - SimpleAccountFactory, - SimpleAccountFactory__factory, - SimpleAccount__factory, -} from '../typechain' -import { BigNumberish, Wallet } from 'ethers' -import hre from 'hardhat' -import { fillSignAndPack, fillUserOp, packUserOp, signUserOp } from '../test/UserOp' -import { TransactionReceipt } from '@ethersproject/abstract-provider' -import { table, TableUserConfig } from 'table' -import { Create2Factory } from '../src/Create2Factory' -import * as fs from 'fs' -import { SimpleAccountInterface } from '../typechain/contracts/samples/SimpleAccount' -import { PackedUserOperation } from '../test/UserOperation' -import { expect } from 'chai' - -const gasCheckerLogFile = './reports/gas-checker.txt' - -const ethers = hre.ethers -const provider = hre.ethers.provider -let ethersSigner = provider.getSigner() -let lastGasUsed: number - -const minDepositOrBalance = parseEther('0.1') - -const getBalance = hre.ethers.provider.getBalance - -function range(n: number): number[] { - return Array(n) - .fill(0) - .map((val, index) => index) -} - -interface GasTestInfo { - title: string - diffLastGas: boolean - paymaster: string - count: number - // address, or 'random' or 'self' (for account itself) - dest: string - destValue: BigNumberish - destCallData: string - beneficiary: string - gasPrice: number -} - -export const DefaultGasTestInfo: Partial = { - dest: 'self', // destination is the account itself. - destValue: parseEther('0'), - destCallData: '0xb0d691fe', // entryPoint() - gasPrice: 10e9, -} - -interface GasTestResult { - title: string - count: number - gasUsed: number // actual gas used - accountEst: number // estimateGas of the inner transaction (from EP to account) - gasDiff?: number // different from last test's gas used - receipt?: TransactionReceipt -} - -/** - * singleton contract used by all GasChecker modules ("tests") - * init() static method - - * - create the singleton the first time (or return its existing instance) - * run - */ - -// gas estimate of the "execFromSingleton" methods -// we assume a given call signature has the same gas usage -// (TODO: the estimate also depends on contract code. for test purposes, assume each contract implementation has different method signature) -// at the end of the checks, we report the gas usage of all those method calls -const gasEstimatePerExec: { [key: string]: { title: string; accountEst: number } } = {} - -/** - * helper contract to generate gas test. - * see runTest() method for "test template" info - * override for different account implementation: - * - accountInitCode() - the constructor code - * - accountExec() the account execution method. - */ -export class GasChecker { - accounts: { [account: string]: Wallet } = {} - - accountOwner: Wallet - - accountInterface: SimpleAccountInterface - - constructor() { - this.accountOwner = createAccountOwner() - this.accountInterface = SimpleAccount__factory.createInterface() - void GasCheckCollector.init() - } - - // generate the "exec" calldata for this account - accountExec(dest: string, value: BigNumberish, data: string): string { - return this.accountInterface.encodeFunctionData('execute', [dest, value, data]) - } - - // generate the account "creation code" - accountInitCode(factory: SimpleAccountFactory, salt: BigNumberish): string { - return hexConcat([ - factory.address, - factory.interface.encodeFunctionData('createAccount', [this.accountOwner.address, salt]), - ]) - } - - createdAccounts = new Set() - - /** - * create accounts up to this counter. - * make sure they all have balance. - * do nothing for account already created - * @param count - */ - async createAccounts1(count: number): Promise { - const create2Factory = new Create2Factory(this.entryPoint().provider) - const factoryAddress = await create2Factory.deploy( - hexConcat([ - SimpleAccountFactory__factory.bytecode, - defaultAbiCoder.encode(['address'], [this.entryPoint().address]), - ]), - 0, - 2885201 - ) - console.log('factaddr', factoryAddress) - const fact = SimpleAccountFactory__factory.connect(factoryAddress, ethersSigner) - // create accounts - const creationOps: PackedUserOperation[] = [] - for (const n of range(count)) { - const salt = n - // const initCode = this.accountInitCode(fact, salt) - - const addr = await fact.getAddress(this.accountOwner.address, salt) - - if (!this.createdAccounts.has(addr)) { - // explicit call to fillUseROp with no "entryPoint", to make sure we manually fill everything and - // not attempt to fill from blockchain. - const op = signUserOp( - await fillUserOp({ - sender: addr, - nonce: 0, - callGasLimit: 30000, - verificationGasLimit: 1000000, - // paymasterAndData: paymaster, - preVerificationGas: 1, - maxFeePerGas: 0, - }), - this.accountOwner, - this.entryPoint().address, - await provider.getNetwork().then((net) => net.chainId) - ) - creationOps.push(packUserOp(op)) - this.createdAccounts.add(addr) - } - - this.accounts[addr] = this.accountOwner - // deploy if not already deployed. - await fact.createAccount(this.accountOwner.address, salt) - const accountBalance = await GasCheckCollector.inst.entryPoint.balanceOf(addr) - if (accountBalance.lte(minDepositOrBalance)) { - await GasCheckCollector.inst.entryPoint.depositTo(addr, { - value: minDepositOrBalance.mul(5), - }) - } - } - await this.entryPoint().handleOps(creationOps, ethersSigner.getAddress()) - } - - /** - * helper: run a test scenario, and add a table row - * @param params - test parameters. missing values filled in from DefaultGasTestInfo - * note that 2 important params are methods: accountExec() and accountInitCode() - */ - async addTestRow(params: Partial): Promise { - await GasCheckCollector.init() - GasCheckCollector.inst.addRow(await this.runTest(params)) - } - - /** - * run a single test scenario - * @param params - test parameters. missing values filled in from DefaultGasTestInfo - * note that 2 important params are methods: accountExec() and accountInitCode() - */ - async runTest(params: Partial): Promise { - // eslint-disable-next-line @typescript-eslint/consistent-type-assertions - const info: GasTestInfo = { ...DefaultGasTestInfo, ...params } as GasTestInfo - - console.debug('== running test count=', info.count) - - // fill accounts up to this code. - await this.createAccounts1(info.count) - - let accountEst: number = 0 - const userOps = await Promise.all( - range(info.count) - .map((index) => Object.entries(this.accounts)[index]) - .map(async ([account, accountOwner]) => { - const paymaster = info.paymaster - - let { dest, destValue, destCallData } = info - if (dest === 'self') { - dest = account - } else if (dest === 'random') { - dest = createAddress() - const destBalance = await getBalance(dest) - if (destBalance.eq(0)) { - console.log('dest replenish', dest) - await ethersSigner.sendTransaction({ to: dest, value: 1 }) - } - } - const accountExecFromEntryPoint = this.accountExec(dest, destValue, destCallData) - - // remove the "dest" from the key to the saved estimations - // so we have a single estimation per method. - const estimateGasKey = this.accountExec(AddressZero, destValue, destCallData) - - let est = gasEstimatePerExec[estimateGasKey] - // technically, each UserOp needs estimate - but we know they are all the same for each test. - if (est == null) { - const accountEst = ( - await ethers.provider.estimateGas({ - from: GasCheckCollector.inst.entryPoint.address, - to: account, - data: accountExecFromEntryPoint, - }) - ).toNumber() - est = gasEstimatePerExec[estimateGasKey] = { accountEst, title: info.title } - } - // console.debug('== account est=', accountEst.toString()) - accountEst = est.accountEst - const op = await fillSignAndPack( - { - sender: account, - callData: accountExecFromEntryPoint, - maxPriorityFeePerGas: info.gasPrice, - maxFeePerGas: info.gasPrice, - callGasLimit: accountEst, - verificationGasLimit: 1000000, - paymaster: paymaster, - paymasterVerificationGasLimit: 50000, - paymasterPostOpGasLimit: 50000, - preVerificationGas: 1, - }, - accountOwner, - GasCheckCollector.inst.entryPoint - ) - // const packed = packUserOp(op, false) - // console.log('== packed cost=', callDataCost(packed), packed) - return op - }) - ) - - const txdata = GasCheckCollector.inst.entryPoint.interface.encodeFunctionData('handleOps', [ - userOps, - info.beneficiary, - ]) - console.log('=== encoded data=', txdata.length) - const gasEst = await GasCheckCollector.inst.entryPoint.estimateGas - .handleOps(userOps, info.beneficiary, {}) - .catch((e) => { - const data = e.error?.data?.data ?? e.error?.data - if (data != null) { - const e1 = GasCheckCollector.inst.entryPoint.interface.parseError(data) - throw new Error(`${e1.name}(${e1.args?.toString()})`) - } - throw e - }) - const ret = await GasCheckCollector.inst.entryPoint.handleOps(userOps, info.beneficiary, { - gasLimit: gasEst.mul(3).div(2), - }) - const rcpt = await ret.wait() - const gasUsed = rcpt.gasUsed.toNumber() - const countSuccessOps = rcpt.events?.filter( - (e) => e.event === 'UserOperationEvent' && e.args?.success - ).length - - rcpt.events - ?.filter((e) => e.event?.match(/PostOpRevertReason|UserOperationRevertReason/)) - .find((e) => { - // console.log(e.event, e.args) - throw new Error(`${e.event}(${decodeRevertReason(e.args?.revertReason)})`) - }) - // check for failure with no revert reason (e.g. OOG) - expect(countSuccessOps).to.eq( - userOps.length, - 'Some UserOps failed to execute (with no revert reason)' - ) - - console.debug('count', info.count, 'gasUsed', gasUsed) - const gasDiff = gasUsed - lastGasUsed - if (info.diffLastGas) { - console.debug('\tgas diff=', gasDiff) - } - lastGasUsed = gasUsed - console.debug('handleOps tx.hash=', rcpt.transactionHash) - const ret1: GasTestResult = { - count: info.count, - gasUsed, - accountEst, - title: info.title, - // receipt: rcpt - } - if (info.diffLastGas) { - ret1.gasDiff = gasDiff - } - console.debug(ret1) - return ret1 - } - - // helper methods to access the GasCheckCollector singleton - addRow(res: GasTestResult): void { - GasCheckCollector.inst.addRow(res) - } - - entryPoint(): EntryPoint { - return GasCheckCollector.inst.entryPoint - } - - skipLong(): boolean { - return process.env.SKIP_LONG != null - } -} - -export class GasCheckCollector { - static inst: GasCheckCollector - static initPromise?: Promise - - entryPoint: EntryPoint - - static async init(): Promise { - if (this.inst == null) { - if (this.initPromise == null) { - this.initPromise = new GasCheckCollector()._init() - } - this.inst = await this.initPromise - } - } - - async _init(entryPointAddressOrTest: string = 'test'): Promise { - console.log('signer=', await ethersSigner.getAddress()) - DefaultGasTestInfo.beneficiary = createAddress() - - const bal = await getBalance(ethersSigner.getAddress()) - if (bal.gt(parseEther('100000000'))) { - console.log('DONT use geth miner.. use account 2 instead') - await checkForGeth() - ethersSigner = ethers.provider.getSigner(2) - } - - if (entryPointAddressOrTest === 'test') { - this.entryPoint = await deployEntryPoint(provider) - } else { - this.entryPoint = EntryPoint__factory.connect(entryPointAddressOrTest, ethersSigner) - } - - const tableHeaders = [ - 'handleOps description ', - 'count', - 'total gasUsed', - 'per UserOp gas\n(delta for\none UserOp)', - // 'account.exec()\nestimateGas', - 'per UserOp overhead\n(compared to\naccount.exec())', - ] - - this.initTable(tableHeaders) - return this - } - - tableConfig: TableUserConfig - tabRows: any[] - - /** - * initialize our formatted table. - * each header define the width of the column, so make sure to pad with spaces - * (we stream the table, so can't learn the content length) - */ - initTable(tableHeaders: string[]): void { - console.log('inittable') - - // multiline header - check the length of the longest line. - // function columnWidth (header: string): number { - // return Math.max(...header.split('\n').map(s => s.length)) - // } - - this.tableConfig = { - columnDefault: { alignment: 'right' }, - columns: [{ alignment: 'left' }], - // columns: tableHeaders.map((header, index) => ({ - // alignment: index == 0 ? 'left' : 'right', - // width: columnWidth(header) - // })), - // columnCount: tableHeaders.length - } - this.tabRows = [tableHeaders] - } - - doneTable(): void { - fs.rmSync(gasCheckerLogFile, { force: true }) - const write = (s: string): void => { - console.log(s) - fs.appendFileSync(gasCheckerLogFile, s + '\n') - } - - write('== gas estimate of direct calling the account\'s "execute" method') - write( - ' the destination is "account.entryPoint()", which is known to be "hot" address used by this account' - ) - write( - ' it little higher than EOA call: its an exec from entrypoint (or account owner) into account contract, verifying msg.sender and exec to target)' - ) - - write( - table( - Object.values(gasEstimatePerExec).map((row) => [ - `gas estimate "${row.title}"`, - row.accountEst, - ]), - this.tableConfig - ) - ) - - const tableOutput = table(this.tabRows, this.tableConfig) - write(tableOutput) - // process.exit(0) - } - - addRow(res: GasTestResult): void { - const gasUsed = res.gasDiff != null ? '' : res.gasUsed // hide "total gasUsed" if there is a diff - const perOp = res.gasDiff != null ? res.gasDiff - res.accountEst : '' - - this.tabRows.push([ - res.title, - res.count, - gasUsed, - res.gasDiff ?? '', - // res.accountEst, - perOp, - ]) - } -} - -after(() => { - GasCheckCollector.inst.doneTable() -}) diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/hardhat.config.ts b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/hardhat.config.ts deleted file mode 100644 index e27408cb26..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/hardhat.config.ts +++ /dev/null @@ -1,86 +0,0 @@ -import '@nomiclabs/hardhat-waffle' -import '@typechain/hardhat' -import { HardhatUserConfig, task } from 'hardhat/config' -import 'hardhat-deploy' -import '@nomiclabs/hardhat-etherscan' - -import 'solidity-coverage' - -import * as fs from 'fs' - -const SALT = '0x90d8084deab30c2a37c45e8d47f49f2f7965183cb6990a98943ef94940681de3' -process.env.SALT = process.env.SALT ?? SALT - -task('deploy', 'Deploy contracts').addFlag( - 'simpleAccountFactory', - 'deploy sample factory (by default, enabled only on localhost)' -) - -const mnemonicFileName = process.env.MNEMONIC_FILE! -let mnemonic = 'test '.repeat(11) + 'junk' -if (fs.existsSync(mnemonicFileName)) { - mnemonic = fs.readFileSync(mnemonicFileName, 'ascii') -} - -function getNetwork1(url: string): { url: string; accounts: { mnemonic: string } } { - return { - url, - accounts: { mnemonic }, - } -} - -function getNetwork(name: string): { url: string; accounts: { mnemonic: string } } { - return getNetwork1(`https://${name}.infura.io/v3/${process.env.INFURA_ID}`) - // return getNetwork1(`wss://${name}.infura.io/ws/v3/${process.env.INFURA_ID}`) -} - -const optimizedComilerSettings = { - version: '0.8.23', - settings: { - optimizer: { enabled: true, runs: 1000000 }, - viaIR: true, - }, -} - -// You need to export an object to set up your config -// Go to https://hardhat.org/config/ to learn more - -const config: HardhatUserConfig = { - solidity: { - compilers: [ - { - version: '0.8.23', - settings: { - optimizer: { enabled: true, runs: 1000000 }, - }, - }, - ], - overrides: { - 'contracts/core/EntryPoint.sol': optimizedComilerSettings, - 'contracts/samples/SimpleAccount.sol': optimizedComilerSettings, - }, - }, - networks: { - dev: { url: 'http://localhost:8545' }, - // github action starts localgeth service, for gas calculations - localgeth: { url: 'http://localgeth:8545' }, - goerli: getNetwork('goerli'), - sepolia: getNetwork('sepolia'), - proxy: getNetwork1('http://localhost:8545'), - }, - mocha: { - timeout: 10000, - }, - // @ts-ignore - etherscan: { - apiKey: process.env.ETHERSCAN_API_KEY, - }, -} - -// coverage chokes on the "compilers" settings -if (process.env.COVERAGE != null) { - // @ts-ignore - config.solidity = config.solidity.compilers[0] -} - -export default config diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/package.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/package.json deleted file mode 100644 index 21f3550be4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/package.json +++ /dev/null @@ -1,71 +0,0 @@ -{ - "name": "accountabstraction", - "version": "0.7.0", - "description": "ERC-4337 Account Abstraction Implementation", - "scripts": { - "clean": "rm -rf cache artifacts typechain typechain-types", - "compile": "./scripts/hh-wrapper compile", - "tsc": "tsc", - "lint": "yarn compile && yarn run lint:sol && yarn run lint:js ", - "lint:js": "eslint -f unix .", - "lint-fix": "eslint -f unix . --fix", - "lint:sol": "solhint -f unix \"contracts/**/*.sol\" --max-warnings 0", - "gas-calc": "./scripts/gascalc", - "mocha-gascalc": "TS_NODE_TRANSPILE_ONLY=1 npx ts-mocha --bail gascalc/*", - "test": "./scripts/hh-wrapper test", - "coverage": "COVERAGE=1 hardhat coverage", - "deploy": "./scripts/hh-wrapper deploy", - "test-dev": "hardhat test --network dev", - "ci": "yarn compile && hardhat test && yarn run runop", - "ci-gas-calc": "yarn gas-calc && yarn check-gas-reports", - "check-gas-reports": "./scripts/check-gas-reports", - "runop": "hardhat run src/runop.ts " - }, - "keywords": [], - "author": "", - "license": "ISC", - "devDependencies": { - "@nomicfoundation/hardhat-chai-matchers": "^1.0.6", - "@nomiclabs/hardhat-ethers": "^2.0.2", - "@nomiclabs/hardhat-waffle": "^2.0.1", - "@typechain/ethers-v5": "^10.1.0", - "@types/chai": "^4.2.21", - "@types/node": "^16.4.12", - "@typescript-eslint/eslint-plugin": "^5.30.5", - "@typescript-eslint/parser": "^5.30.5", - "@uniswap/v3-periphery": "^1.4.3", - "chai": "^4.3.4", - "eslint": "^8.19.0", - "eslint-config-standard": "^17.0.0", - "eslint-config-standard-with-typescript": "^21.0.1", - "eslint-plugin-import": "^2.26.0", - "eslint-plugin-node": "^11.1.0", - "eslint-plugin-promise": "^6.0.0", - "eslint-plugin-standard": "^5.0.0", - "ethereum-waffle": "^3.4.0", - "ethers": "^5.4.2", - "hardhat": "^2.17.2", - "solhint": "^3.3.7", - "ts-generator": "^0.1.1", - "ts-mocha": "^10.0.0", - "ts-node": "^10.1.0", - "typechain": "^8.1.0" - }, - "dependencies": { - "@nomiclabs/hardhat-etherscan": "^2.1.6", - "@openzeppelin/contracts": "^5.0.0", - "@thehubbleproject/bls": "^0.5.1", - "@typechain/hardhat": "^2.3.0", - "@types/debug": "^4.1.12", - "@types/mocha": "^9.0.0", - "debug": "^4.3.4", - "ethereumjs-util": "^7.1.0", - "ethereumjs-wallet": "^1.0.1", - "hardhat-deploy": "^0.11.23", - "hardhat-deploy-ethers": "^0.3.0-beta.11", - "solidity-coverage": "^0.8.4", - "source-map-support": "^0.5.19", - "table": "^6.8.0", - "typescript": "^4.3.5" - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/reports/gas-checker.txt b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/reports/gas-checker.txt deleted file mode 100644 index 692322bf7e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/reports/gas-checker.txt +++ /dev/null @@ -1,55 +0,0 @@ -== gas estimate of direct calling the account's "execute" method - the destination is "account.entryPoint()", which is known to be "hot" address used by this account - it little higher than EOA call: its an exec from entrypoint (or account owner) into account contract, verifying msg.sender and exec to target) -╔══════════════════════════╤════════╗ -║ gas estimate "simple" │ 28979 ║ -╟──────────────────────────┼────────╢ -║ gas estimate "big tx 5k" │ 125224 ║ -╚══════════════════════════╧════════╝ - -╔════════════════════════════════╤═══════╤═══════════════╤════════════════╤═════════════════════╗ -║ handleOps description │ count │ total gasUsed │ per UserOp gas │ per UserOp overhead ║ -║ │ │ │ (delta for │ (compared to ║ -║ │ │ │ one UserOp) │ account.exec()) ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ simple │ 1 │ 79994 │ │ ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ simple - diff from previous │ 2 │ │ 42192 │ 13213 ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ simple │ 10 │ 459921 │ │ ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ simple - diff from previous │ 11 │ │ 42223 │ 13244 ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ simple paymaster │ 1 │ 86113 │ │ ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ simple paymaster with diff │ 2 │ │ 41024 │ 12045 ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ simple paymaster │ 10 │ 455444 │ │ ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ simple paymaster with diff │ 11 │ │ 41088 │ 12109 ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ big tx 5k │ 1 │ 181026 │ │ ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ big tx - diff from previous │ 2 │ │ 142714 │ 17490 ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ big tx 5k │ 10 │ 1465443 │ │ ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ big tx - diff from previous │ 11 │ │ 142686 │ 17462 ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ paymaster+postOp │ 1 │ 87712 │ │ ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ paymaster+postOp with diff │ 2 │ │ 42671 │ 13692 ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ paymaster+postOp │ 10 │ 471754 │ │ ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ paymaster+postOp with diff │ 11 │ │ 42728 │ 13749 ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ token paymaster │ 1 │ 128777 │ │ ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ token paymaster with diff │ 2 │ │ 66386 │ 37407 ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ token paymaster │ 10 │ 726504 │ │ ║ -╟────────────────────────────────┼───────┼───────────────┼────────────────┼─────────────────────╢ -║ token paymaster with diff │ 11 │ │ 66394 │ 37415 ║ -╚════════════════════════════════╧═══════╧═══════════════╧════════════════╧═════════════════════╝ - diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/check-gas-reports b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/check-gas-reports deleted file mode 100644 index d0af47d1b9..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/check-gas-reports +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/bash -# make sure gas reports are checked in with this commit -# dump report diff -# exit with "1" if there is a diff, zero if no diff - -folder=${1:-reports} -git diff --color=always $folder -git diff ${folder} | grep -q . - -if [ "$?" == 1 ]; then - #diff with no error - ok - exit -else - echo ERROR: found above unchecked reports. - exit 1 -fi - diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/docker-gascalc b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/docker-gascalc deleted file mode 100644 index 05c0eb274f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/docker-gascalc +++ /dev/null @@ -1,7 +0,0 @@ -# run "yarn gas-calc" using geth with docker. -# (if you have geth running on localhost:8545, its faster with "HARDHAT_NETWORK=dev yarn gas-calc") -docker-compose -f `dirname $0`/docker-gascalc.yml up --abort-on-container-exit -exit=$? -docker-compose -f `dirname $0`/docker-gascalc.yml down -exit $exit - diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/docker-gascalc.yml b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/docker-gascalc.yml deleted file mode 100644 index 9dd3901fce..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/docker-gascalc.yml +++ /dev/null @@ -1,20 +0,0 @@ -version: '2' - -services: - test: - image: node:18 - container_name: gascalc - depends_on: - - localgeth - volumes: - - ..:/app - working_dir: /app - restart: "no" - environment: - - HARDHAT_NETWORK=localgeth - command: "yarn mocha-gascalc" - - #configuration is a copy of github/.workflows/build.xml - localgeth: - image: dtr22/geth-dev - container_name: localgeth diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/gascalc b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/gascalc deleted file mode 100644 index b82f5327cd..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/gascalc +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/bash - -# run gascalc, assuming "geth" is running on localhost, port 8545 -cd `dirname $0`/.. -function getClientVersion() { - curl -m 1 -s -d '{"method":"web3_clientVersion","params":[],"id":1234,"jsonrpc":"2.0"}' -H content-type:application/json localhost:8545 -} - -if [[ `getClientVersion` =~ "Geth" ]]; then - echo Using GETH on localhost:8545 - HARDHAT_NETWORK=dev yarn mocha-gascalc -else - echo No GETH running on localhost:8545. Using docker.. - ./scripts/docker-gascalc -fi diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/hh-wrapper b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/hh-wrapper deleted file mode 100644 index ada7d62db2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/hh-wrapper +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash - -set -euo pipefail -export FORCE_COLOR=1 -hardhat "$@" 2>&1 | `dirname $0`/solcErrors diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/postpack-contracts-package.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/postpack-contracts-package.sh deleted file mode 100644 index 6e1b239800..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/postpack-contracts-package.sh +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/bash -xe -#echo postpack for "contracts" package -cd `dirname $0`/.. -pwd -rm -rf contracts/artifacts - diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/prepack-contracts-package.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/prepack-contracts-package.sh deleted file mode 100644 index eac8c94b12..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/prepack-contracts-package.sh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/bash -xe -#echo prepack for "contracts" package - -cd `dirname $0`/.. -pwd -if git status contracts | grep -v 'nothing to commit'|tee /dev/stderr |grep -q Untracked; then - exit 1 -fi - -yarn clean -yarn compile -cd contracts - -rm -rf artifacts - -mkdir -p artifacts -cp `find ../artifacts/contracts -type f | grep -v -E 'test|Test|dbg|bls|IOracle'` artifacts/ diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/sample-script.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/sample-script.js deleted file mode 100644 index a2885d5394..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/account-abstraction/scripts/sample-script.js +++ /dev/null @@ -1,32 +0,0 @@ -// We require the Hardhat Runtime Environment explicitly here. This is optional -// but useful for running the script in a standalone fashion through `node - - -++++ - - diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/docs/templates/contract.hbs b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/docs/templates/contract.hbs deleted file mode 100644 index aaca0a3cc5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/docs/templates/contract.hbs +++ /dev/null @@ -1,137 +0,0 @@ -{{#each items}} -:{{name}}: pass:normal[xref:#{{anchor}}[`++{{name}}++`]] -{{/each}} - -[.contract] -[[{{anchor}}]] -=== `++{{name}}++` link:https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v{{oz-version}}/{{__item_context.file.absolutePath}}[{github-icon},role=heading-link] - -[.hljs-theme-light.nopadding] -```solidity -import "@openzeppelin/{{__item_context.file.absolutePath}}"; -``` - -{{{natspec.dev}}} - -{{#if modifiers}} -[.contract-index] -.Modifiers --- -{{#each modifiers}} -* {xref-{{anchor~}} }[`++{{name}}({{names params}})++`] -{{/each}} --- -{{/if}} - -{{#if has-functions}} -[.contract-index] -.Functions --- -{{#each inherited-functions}} -{{#unless @first}} -[.contract-subindex-inherited] -.{{contract.name}} -{{/unless}} -{{#each functions}} -* {xref-{{anchor~}} }[`++{{name}}({{names params}})++`] -{{/each}} - -{{/each}} --- -{{/if}} - -{{#if has-events}} -[.contract-index] -.Events --- -{{#each inheritance}} -{{#unless @first}} -[.contract-subindex-inherited] -.{{name}} -{{/unless}} -{{#each events}} -* {xref-{{anchor~}} }[`++{{name}}({{names params}})++`] -{{/each}} - -{{/each}} --- -{{/if}} - -{{#if has-errors}} -[.contract-index] -.Errors --- -{{#each inheritance}} -{{#unless @first}} -[.contract-subindex-inherited] -.{{name}} -{{/unless}} -{{#each errors}} -* {xref-{{anchor~}} }[`++{{name}}({{names params}})++`] -{{/each}} - -{{/each}} --- -{{/if}} - -{{#if has-internal-variables}} -[.contract-index] -.Internal Variables --- -{{#each inheritance}} -{{#unless @first}} -[.contract-subindex-inherited] -.{{name}} -{{/unless}} -{{#each internal-variables}} -* {xref-{{anchor~}} }[`++{{typeDescriptions.typeString}} {{#if constant}}constant{{/if}} {{name}}++`] -{{/each}} - -{{/each}} --- -{{/if}} - -{{#each modifiers}} -[.contract-item] -[[{{anchor}}]] -==== `[.contract-item-name]#++{{name}}++#++({{typed-params params}})++` [.item-kind]#modifier# - -{{{natspec.dev}}} - -{{/each}} - -{{#each functions}} -[.contract-item] -[[{{anchor}}]] -==== `[.contract-item-name]#++{{name}}++#++({{typed-params params}}){{#if returns2}} → {{typed-params returns2}}{{/if}}++` [.item-kind]#{{visibility}}# - -{{{natspec.dev}}} - -{{/each}} - -{{#each events}} -[.contract-item] -[[{{anchor}}]] -==== `[.contract-item-name]#++{{name}}++#++({{typed-params params}})++` [.item-kind]#event# - -{{{natspec.dev}}} - -{{/each}} - -{{#each errors}} -[.contract-item] -[[{{anchor}}]] -==== `[.contract-item-name]#++{{name}}++#++({{typed-params params}})++` [.item-kind]#error# - -{{{natspec.dev}}} - -{{/each}} - -{{#each internal-variables}} -[.contract-item] -[[{{anchor}}]] -==== `{{typeDescriptions.typeString}} [.contract-item-name]#++{{name}}++#` [.item-kind]#internal{{#if constant}} constant{{/if}}# - -{{{natspec.dev}}} - -{{/each}} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/docs/templates/helpers.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/docs/templates/helpers.js deleted file mode 100644 index 1b6383549d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/docs/templates/helpers.js +++ /dev/null @@ -1,46 +0,0 @@ -const { version } = require('../../package.json'); - -module.exports['oz-version'] = () => version; - -module.exports['readme-path'] = opts => { - return 'contracts/' + opts.data.root.id.replace(/\.adoc$/, '') + '/README.adoc'; -}; - -module.exports.names = params => params?.map(p => p.name).join(', '); - -module.exports['typed-params'] = params => { - return params?.map(p => `${p.type}${p.indexed ? ' indexed' : ''}${p.name ? ' ' + p.name : ''}`).join(', '); -}; - -const slug = (module.exports.slug = str => { - if (str === undefined) { - throw new Error('Missing argument'); - } - return str.replace(/\W/g, '-'); -}); - -const linksCache = new WeakMap(); - -function getAllLinks(items) { - if (linksCache.has(items)) { - return linksCache.get(items); - } - const res = {}; - linksCache.set(items, res); - for (const item of items) { - res[`xref-${item.anchor}`] = `xref:${item.__item_context.page}#${item.anchor}`; - res[slug(item.fullName)] = `pass:normal[xref:${item.__item_context.page}#${item.anchor}[\`${item.fullName}\`]]`; - } - return res; -} - -module.exports['with-prelude'] = opts => { - const links = getAllLinks(opts.data.site.items); - const contents = opts.fn(); - const neededLinks = contents - .match(/\{[-._a-z0-9]+\}/gi) - .map(m => m.replace(/^\{(.+)\}$/, '$1')) - .filter(k => k in links); - const prelude = neededLinks.map(k => `:${k}: ${links[k]}`).join('\n'); - return prelude + '\n' + contents; -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/docs/templates/page.hbs b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/docs/templates/page.hbs deleted file mode 100644 index cab050acb5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/docs/templates/page.hbs +++ /dev/null @@ -1,4 +0,0 @@ -:github-icon: pass:[] -{{#with-prelude}} -{{readme (readme-path)}} -{{/with-prelude}} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/docs/templates/properties.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/docs/templates/properties.js deleted file mode 100644 index 52eebac547..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/docs/templates/properties.js +++ /dev/null @@ -1,72 +0,0 @@ -const { isNodeType, findAll } = require('solidity-ast/utils'); -const { slug } = require('./helpers'); - -module.exports.anchor = function anchor({ item, contract }) { - let res = ''; - if (contract) { - res += contract.name + '-'; - } - res += item.name; - if ('parameters' in item) { - const signature = item.parameters.parameters.map(v => v.typeName.typeDescriptions.typeString).join(','); - res += slug('(' + signature + ')'); - } - if (isNodeType('VariableDeclaration', item)) { - res += '-' + slug(item.typeName.typeDescriptions.typeString); - } - return res; -}; - -module.exports.inheritance = function ({ item, build }) { - if (!isNodeType('ContractDefinition', item)) { - throw new Error('used inherited-items on non-contract'); - } - - return item.linearizedBaseContracts - .map(id => build.deref('ContractDefinition', id)) - .filter((c, i) => c.name !== 'Context' || i === 0); -}; - -module.exports['has-functions'] = function ({ item }) { - return item.inheritance.some(c => c.functions.length > 0); -}; - -module.exports['has-events'] = function ({ item }) { - return item.inheritance.some(c => c.events.length > 0); -}; - -module.exports['has-errors'] = function ({ item }) { - return item.inheritance.some(c => c.errors.length > 0); -}; - -module.exports['internal-variables'] = function ({ item }) { - return item.variables.filter(({ visibility }) => visibility === 'internal'); -}; - -module.exports['has-internal-variables'] = function ({ item }) { - return module.exports['internal-variables']({ item }).length > 0; -}; - -module.exports.functions = function ({ item }) { - return [ - ...[...findAll('FunctionDefinition', item)].filter(f => f.visibility !== 'private'), - ...[...findAll('VariableDeclaration', item)].filter(f => f.visibility === 'public'), - ]; -}; - -module.exports.returns2 = function ({ item }) { - if (isNodeType('VariableDeclaration', item)) { - return [{ type: item.typeDescriptions.typeString }]; - } else { - return item.returns; - } -}; - -module.exports['inherited-functions'] = function ({ item }) { - const { inheritance } = item; - const baseFunctions = new Set(inheritance.flatMap(c => c.functions.flatMap(f => f.baseFunctions ?? []))); - return inheritance.map((contract, i) => ({ - contract, - functions: contract.functions.filter(f => !baseFunctions.has(f.id) && (f.name !== 'constructor' || i === 0)), - })); -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/eslint.config.mjs b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/eslint.config.mjs deleted file mode 100644 index 00fcc95bb4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/eslint.config.mjs +++ /dev/null @@ -1,26 +0,0 @@ -import js from '@eslint/js'; -import { includeIgnoreFile } from '@eslint/compat'; -import prettier from 'eslint-config-prettier'; -import globals from 'globals'; -import path from 'path'; - -export default [ - js.configs.recommended, - prettier, - { - languageOptions: { - ecmaVersion: 2022, - globals: { - ...globals.browser, - ...globals.mocha, - ...globals.node, - artifacts: 'readonly', - contract: 'readonly', - web3: 'readonly', - extendEnvironment: 'readonly', - expect: 'readonly', - }, - }, - }, - includeIgnoreFile(path.resolve(import.meta.dirname, '.gitignore')), -]; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/foundry.toml b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/foundry.toml deleted file mode 100644 index 78dd078122..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/foundry.toml +++ /dev/null @@ -1,15 +0,0 @@ -[profile.default] -solc_version = '0.8.24' -evm_version = 'cancun' -optimizer = true -optimizer-runs = 200 -src = 'contracts' -out = 'out' -libs = ['node_modules', 'lib'] -test = 'test' -cache_path = 'cache_forge' -fs_permissions = [{ access = "read", path = "./test/bin" }] - -[fuzz] -runs = 5000 -max_test_rejects = 150000 diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/fv-requirements.txt b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/fv-requirements.txt deleted file mode 100644 index 608b4de24a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/fv-requirements.txt +++ /dev/null @@ -1,4 +0,0 @@ -certora-cli==4.13.1 -# File uses a custom name (fv-requirements.txt) so that it isn't picked by Netlify's build -# whose latest Python version is 0.3.8, incompatible with most recent versions of Halmos -halmos==0.2.0 diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat.config.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat.config.js deleted file mode 100644 index d39d3d0732..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat.config.js +++ /dev/null @@ -1,124 +0,0 @@ -/// ENVVAR -// - COMPILER: compiler version (default: 0.8.24) -// - SRC: contracts folder to compile (default: contracts) -// - RUNS: number of optimization runs (default: 200) -// - IR: enable IR compilation (default: false) -// - COVERAGE: enable coverage report (default: false) -// - GAS: enable gas report (default: false) -// - COINMARKETCAP: coinmarketcap api key for USD value in gas report -// - CI: output gas report to file instead of stdout - -const fs = require('fs'); -const path = require('path'); - -const { argv } = require('yargs/yargs')() - .env('') - .options({ - // Compilation settings - compiler: { - alias: 'compileVersion', - type: 'string', - default: '0.8.24', - }, - src: { - alias: 'source', - type: 'string', - default: 'contracts', - }, - runs: { - alias: 'optimizationRuns', - type: 'number', - default: 200, - }, - ir: { - alias: 'enableIR', - type: 'boolean', - default: false, - }, - evm: { - alias: 'evmVersion', - type: 'string', - default: 'cancun', - }, - // Extra modules - coverage: { - type: 'boolean', - default: false, - }, - gas: { - alias: 'enableGasReport', - type: 'boolean', - default: false, - }, - coinmarketcap: { - alias: 'coinmarketcapApiKey', - type: 'string', - }, - }); - -require('@nomicfoundation/hardhat-chai-matchers'); -require('@nomicfoundation/hardhat-ethers'); -require('hardhat-exposed'); -require('hardhat-gas-reporter'); -require('hardhat-ignore-warnings'); -require('solidity-coverage'); -require('solidity-docgen'); - -for (const f of fs.readdirSync(path.join(__dirname, 'hardhat'))) { - require(path.join(__dirname, 'hardhat', f)); -} - -/** - * @type import('hardhat/config').HardhatUserConfig - */ -module.exports = { - solidity: { - version: argv.compiler, - settings: { - optimizer: { - enabled: true, - runs: argv.runs, - }, - evmVersion: argv.evm, - viaIR: argv.ir, - outputSelection: { '*': { '*': ['storageLayout'] } }, - }, - }, - warnings: { - 'contracts-exposed/**/*': { - 'code-size': 'off', - 'initcode-size': 'off', - }, - '*': { - 'code-size': true, - 'unused-param': !argv.coverage, // coverage causes unused-param warnings - 'transient-storage': false, - default: 'error', - }, - }, - networks: { - hardhat: { - hardfork: argv.evm, - // Exposed contracts often exceed the maximum contract size. For normal contract, - // we rely on the `code-size` compiler warning, that will cause a compilation error. - allowUnlimitedContractSize: true, - initialBaseFeePerGas: argv.coverage ? 0 : undefined, - }, - }, - exposed: { - imports: true, - initializers: true, - exclude: ['vendor/**/*', '**/*WithInit.sol'], - }, - gasReporter: { - enabled: argv.gas, - showMethodSig: true, - includeBytecodeInJSON: true, - currency: 'USD', - coinmarketcap: argv.coinmarketcap, - }, - paths: { - sources: argv.src, - }, - docgen: require('./docs/config'), -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/async-test-sanity.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/async-test-sanity.js deleted file mode 100644 index c05e5bd489..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/async-test-sanity.js +++ /dev/null @@ -1,3 +0,0 @@ -process.on('unhandledRejection', reason => { - throw new Error(reason); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/env-artifacts.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/env-artifacts.js deleted file mode 100644 index e97ae6468e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/env-artifacts.js +++ /dev/null @@ -1,29 +0,0 @@ -const { HardhatError } = require('hardhat/internal/core/errors'); - -function isExpectedError(e, suffix) { - // HH700: Artifact not found - from https://hardhat.org/hardhat-runner/docs/errors#HH700 - return HardhatError.isHardhatError(e) && e.number === 700 && suffix !== ''; -} - -// Modifies the artifact require functions so that instead of X it loads the XUpgradeable contract. -// This allows us to run the same test suite on both the original and the transpiled and renamed Upgradeable contracts. -extendEnvironment(hre => { - const suffixes = ['UpgradeableWithInit', 'Upgradeable', '']; - - // Ethers - const originalReadArtifact = hre.artifacts.readArtifact; - hre.artifacts.readArtifact = async function (name) { - for (const suffix of suffixes) { - try { - return await originalReadArtifact.call(this, name + suffix); - } catch (e) { - if (isExpectedError(e, suffix)) { - continue; - } else { - throw e; - } - } - } - throw new Error('Unreachable'); - }; -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/ignore-unreachable-warnings.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/ignore-unreachable-warnings.js deleted file mode 100644 index 8e3e34340f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/ignore-unreachable-warnings.js +++ /dev/null @@ -1,45 +0,0 @@ -// Warnings about unreachable code are emitted with a source location that corresponds to the unreachable code. -// We have some testing contracts that purposely cause unreachable code, but said code is in the library contracts, and -// with hardhat-ignore-warnings we are not able to selectively ignore them without potentially ignoring relevant -// warnings that we don't want to miss. -// Thus, we need to handle these warnings separately. We force Hardhat to compile them in a separate compilation job and -// then ignore the warnings about unreachable code that come from that compilation job. - -const { task } = require('hardhat/config'); -const { - TASK_COMPILE_SOLIDITY_GET_COMPILATION_JOB_FOR_FILE, - TASK_COMPILE_SOLIDITY_COMPILE, -} = require('hardhat/builtin-tasks/task-names'); - -const marker = Symbol('unreachable'); -const markedCache = new WeakMap(); - -task(TASK_COMPILE_SOLIDITY_GET_COMPILATION_JOB_FOR_FILE, async (params, _, runSuper) => { - const job = await runSuper(params); - // If the file is in the unreachable directory, we make a copy of the config and mark it, which will cause it to get - // compiled separately (along with the other marked files). - if (params.file.sourceName.startsWith('contracts/mocks/') && /\bunreachable\b/.test(params.file.sourceName)) { - const originalConfig = job.solidityConfig; - let markedConfig = markedCache.get(originalConfig); - if (markedConfig === undefined) { - markedConfig = { ...originalConfig, [marker]: true }; - markedCache.set(originalConfig, markedConfig); - } - job.solidityConfig = markedConfig; - } - return job; -}); - -const W_UNREACHABLE_CODE = '5740'; - -task(TASK_COMPILE_SOLIDITY_COMPILE, async (params, _, runSuper) => { - const marked = params.compilationJob.solidityConfig[marker]; - const result = await runSuper(params); - if (marked) { - result.output = { - ...result.output, - errors: result.output.errors?.filter(e => e.severity !== 'warning' || e.errorCode !== W_UNREACHABLE_CODE), - }; - } - return result; -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/remappings.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/remappings.js deleted file mode 100644 index cd9984d440..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/remappings.js +++ /dev/null @@ -1,18 +0,0 @@ -const fs = require('fs'); -const { task } = require('hardhat/config'); -const { TASK_COMPILE_GET_REMAPPINGS } = require('hardhat/builtin-tasks/task-names'); - -task(TASK_COMPILE_GET_REMAPPINGS).setAction((taskArgs, env, runSuper) => - runSuper().then(remappings => - Object.assign( - remappings, - Object.fromEntries( - fs - .readFileSync('remappings.txt', 'utf-8') - .split('\n') - .filter(Boolean) - .map(line => line.trim().split('=')), - ), - ), - ), -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/skip-foundry-tests.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/skip-foundry-tests.js deleted file mode 100644 index 965ba37c39..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/skip-foundry-tests.js +++ /dev/null @@ -1,6 +0,0 @@ -const { subtask } = require('hardhat/config'); -const { TASK_COMPILE_SOLIDITY_GET_SOURCE_PATHS } = require('hardhat/builtin-tasks/task-names'); - -subtask(TASK_COMPILE_SOLIDITY_GET_SOURCE_PATHS).setAction(async (_, __, runSuper) => - (await runSuper()).filter(path => !path.endsWith('.t.sol')), -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/task-test-get-files.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/task-test-get-files.js deleted file mode 100644 index 108f40a42c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/hardhat/task-test-get-files.js +++ /dev/null @@ -1,25 +0,0 @@ -const { internalTask } = require('hardhat/config'); -const { TASK_TEST_GET_TEST_FILES } = require('hardhat/builtin-tasks/task-names'); - -// Modifies `hardhat test` to skip the proxy tests after proxies are removed by the transpiler for upgradeability. - -internalTask(TASK_TEST_GET_TEST_FILES).setAction(async (args, hre, runSuper) => { - const path = require('path'); - const { promises: fs } = require('fs'); - - const hasProxies = await fs - .access(path.join(hre.config.paths.sources, 'proxy/Proxy.sol')) - .then(() => true) - .catch(() => false); - - const ignoredIfProxy = [ - 'proxy/beacon/BeaconProxy.test.js', - 'proxy/beacon/UpgradeableBeacon.test.js', - 'proxy/ERC1967/ERC1967Proxy.test.js', - 'proxy/transparent/ProxyAdmin.test.js', - 'proxy/transparent/TransparentUpgradeableProxy.test.js', - 'proxy/utils/UUPSUpgradeable.test.js', - ].map(p => path.join(hre.config.paths.tests, p)); - - return (await runSuper(args)).filter(file => hasProxies || !ignoredIfProxy.includes(file)); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/ERC4626.prop.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/ERC4626.prop.sol deleted file mode 100644 index c34512baa3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/ERC4626.prop.sol +++ /dev/null @@ -1,404 +0,0 @@ -// SPDX-License-Identifier: AGPL-3.0 -pragma solidity >=0.8.0 <0.9.0; - -import "forge-std/Test.sol"; - -// TODO: use interface provided by forge-std v1.0.0 or later -// import {IERC20} from "forge-std/interfaces/IERC20.sol"; -interface IERC20 { - event Transfer(address indexed from, address indexed to, uint value); - event Approval(address indexed owner, address indexed spender, uint value); - function totalSupply() external view returns (uint); - function balanceOf(address account) external view returns (uint); - function transfer(address to, uint amount) external returns (bool); - function allowance(address owner, address spender) external view returns (uint); - function approve(address spender, uint amount) external returns (bool); - function transferFrom(address from, address to, uint amount) external returns (bool); -} - -// TODO: use interface provided by forge-std v1.0.0 or later -// import {IERC4626} from "forge-std/interfaces/IERC4626.sol"; -interface IERC4626 is IERC20 { - event Deposit(address indexed caller, address indexed owner, uint assets, uint shares); - event Withdraw(address indexed caller, address indexed receiver, address indexed owner, uint assets, uint shares); - function asset() external view returns (address assetTokenAddress); - function totalAssets() external view returns (uint totalManagedAssets); - function convertToShares(uint assets) external view returns (uint shares); - function convertToAssets(uint shares) external view returns (uint assets); - function maxDeposit(address receiver) external view returns (uint maxAssets); - function previewDeposit(uint assets) external view returns (uint shares); - function deposit(uint assets, address receiver) external returns (uint shares); - function maxMint(address receiver) external view returns (uint maxShares); - function previewMint(uint shares) external view returns (uint assets); - function mint(uint shares, address receiver) external returns (uint assets); - function maxWithdraw(address owner) external view returns (uint maxAssets); - function previewWithdraw(uint assets) external view returns (uint shares); - function withdraw(uint assets, address receiver, address owner) external returns (uint shares); - function maxRedeem(address owner) external view returns (uint maxShares); - function previewRedeem(uint shares) external view returns (uint assets); - function redeem(uint shares, address receiver, address owner) external returns (uint assets); -} - -abstract contract ERC4626Prop is Test { - uint internal _delta_; - - address internal _underlying_; - address internal _vault_; - - bool internal _vaultMayBeEmpty; - bool internal _unlimitedAmount; - - // - // asset - // - - // asset - // "MUST NOT revert." - function prop_asset(address caller) public { - vm.prank(caller); IERC4626(_vault_).asset(); - } - - // totalAssets - // "MUST NOT revert." - function prop_totalAssets(address caller) public { - vm.prank(caller); IERC4626(_vault_).totalAssets(); - } - - // - // convert - // - - // convertToShares - // "MUST NOT show any variations depending on the caller." - function prop_convertToShares(address caller1, address caller2, uint assets) public { - vm.prank(caller1); uint res1 = vault_convertToShares(assets); // "MAY revert due to integer overflow caused by an unreasonably large input." - vm.prank(caller2); uint res2 = vault_convertToShares(assets); // "MAY revert due to integer overflow caused by an unreasonably large input." - assertEq(res1, res2); - } - - // convertToAssets - // "MUST NOT show any variations depending on the caller." - function prop_convertToAssets(address caller1, address caller2, uint shares) public { - vm.prank(caller1); uint res1 = vault_convertToAssets(shares); // "MAY revert due to integer overflow caused by an unreasonably large input." - vm.prank(caller2); uint res2 = vault_convertToAssets(shares); // "MAY revert due to integer overflow caused by an unreasonably large input." - assertEq(res1, res2); - } - - // - // deposit - // - - // maxDeposit - // "MUST NOT revert." - function prop_maxDeposit(address caller, address receiver) public { - vm.prank(caller); IERC4626(_vault_).maxDeposit(receiver); - } - - // previewDeposit - // "MUST return as close to and no more than the exact amount of Vault - // shares that would be minted in a deposit call in the same transaction. - // I.e. deposit should return the same or more shares as previewDeposit if - // called in the same transaction." - function prop_previewDeposit(address caller, address receiver, address other, uint assets) public { - vm.prank(other); uint sharesPreview = vault_previewDeposit(assets); // "MAY revert due to other conditions that would also cause deposit to revert." - vm.prank(caller); uint sharesActual = vault_deposit(assets, receiver); - assertApproxGeAbs(sharesActual, sharesPreview, _delta_); - } - - // deposit - function prop_deposit(address caller, address receiver, uint assets) public { - uint oldCallerAsset = IERC20(_underlying_).balanceOf(caller); - uint oldReceiverShare = IERC20(_vault_).balanceOf(receiver); - uint oldAllowance = IERC20(_underlying_).allowance(caller, _vault_); - - vm.prank(caller); uint shares = vault_deposit(assets, receiver); - - uint newCallerAsset = IERC20(_underlying_).balanceOf(caller); - uint newReceiverShare = IERC20(_vault_).balanceOf(receiver); - uint newAllowance = IERC20(_underlying_).allowance(caller, _vault_); - - assertApproxEqAbs(newCallerAsset, oldCallerAsset - assets, _delta_, "asset"); // NOTE: this may fail if the caller is a contract in which the asset is stored - assertApproxEqAbs(newReceiverShare, oldReceiverShare + shares, _delta_, "share"); - if (oldAllowance != type(uint).max) assertApproxEqAbs(newAllowance, oldAllowance - assets, _delta_, "allowance"); - } - - // - // mint - // - - // maxMint - // "MUST NOT revert." - function prop_maxMint(address caller, address receiver) public { - vm.prank(caller); IERC4626(_vault_).maxMint(receiver); - } - - // previewMint - // "MUST return as close to and no fewer than the exact amount of assets - // that would be deposited in a mint call in the same transaction. I.e. mint - // should return the same or fewer assets as previewMint if called in the - // same transaction." - function prop_previewMint(address caller, address receiver, address other, uint shares) public { - vm.prank(other); uint assetsPreview = vault_previewMint(shares); - vm.prank(caller); uint assetsActual = vault_mint(shares, receiver); - assertApproxLeAbs(assetsActual, assetsPreview, _delta_); - } - - // mint - function prop_mint(address caller, address receiver, uint shares) public { - uint oldCallerAsset = IERC20(_underlying_).balanceOf(caller); - uint oldReceiverShare = IERC20(_vault_).balanceOf(receiver); - uint oldAllowance = IERC20(_underlying_).allowance(caller, _vault_); - - vm.prank(caller); uint assets = vault_mint(shares, receiver); - - uint newCallerAsset = IERC20(_underlying_).balanceOf(caller); - uint newReceiverShare = IERC20(_vault_).balanceOf(receiver); - uint newAllowance = IERC20(_underlying_).allowance(caller, _vault_); - - assertApproxEqAbs(newCallerAsset, oldCallerAsset - assets, _delta_, "asset"); // NOTE: this may fail if the caller is a contract in which the asset is stored - assertApproxEqAbs(newReceiverShare, oldReceiverShare + shares, _delta_, "share"); - if (oldAllowance != type(uint).max) assertApproxEqAbs(newAllowance, oldAllowance - assets, _delta_, "allowance"); - } - - // - // withdraw - // - - // maxWithdraw - // "MUST NOT revert." - // NOTE: some implementations failed due to arithmetic overflow - function prop_maxWithdraw(address caller, address owner) public { - vm.prank(caller); IERC4626(_vault_).maxWithdraw(owner); - } - - // previewWithdraw - // "MUST return as close to and no fewer than the exact amount of Vault - // shares that would be burned in a withdraw call in the same transaction. - // I.e. withdraw should return the same or fewer shares as previewWithdraw - // if called in the same transaction." - function prop_previewWithdraw(address caller, address receiver, address owner, address other, uint assets) public { - vm.prank(other); uint preview = vault_previewWithdraw(assets); - vm.prank(caller); uint actual = vault_withdraw(assets, receiver, owner); - assertApproxLeAbs(actual, preview, _delta_); - } - - // withdraw - function prop_withdraw(address caller, address receiver, address owner, uint assets) public { - uint oldReceiverAsset = IERC20(_underlying_).balanceOf(receiver); - uint oldOwnerShare = IERC20(_vault_).balanceOf(owner); - uint oldAllowance = IERC20(_vault_).allowance(owner, caller); - - vm.prank(caller); uint shares = vault_withdraw(assets, receiver, owner); - - uint newReceiverAsset = IERC20(_underlying_).balanceOf(receiver); - uint newOwnerShare = IERC20(_vault_).balanceOf(owner); - uint newAllowance = IERC20(_vault_).allowance(owner, caller); - - assertApproxEqAbs(newOwnerShare, oldOwnerShare - shares, _delta_, "share"); - assertApproxEqAbs(newReceiverAsset, oldReceiverAsset + assets, _delta_, "asset"); // NOTE: this may fail if the receiver is a contract in which the asset is stored - if (caller != owner && oldAllowance != type(uint).max) assertApproxEqAbs(newAllowance, oldAllowance - shares, _delta_, "allowance"); - - assertTrue(caller == owner || oldAllowance != 0 || (shares == 0 && assets == 0), "access control"); - } - - // - // redeem - // - - // maxRedeem - // "MUST NOT revert." - function prop_maxRedeem(address caller, address owner) public { - vm.prank(caller); IERC4626(_vault_).maxRedeem(owner); - } - - // previewRedeem - // "MUST return as close to and no more than the exact amount of assets that - // would be withdrawn in a redeem call in the same transaction. I.e. redeem - // should return the same or more assets as previewRedeem if called in the - // same transaction." - function prop_previewRedeem(address caller, address receiver, address owner, address other, uint shares) public { - vm.prank(other); uint preview = vault_previewRedeem(shares); - vm.prank(caller); uint actual = vault_redeem(shares, receiver, owner); - assertApproxGeAbs(actual, preview, _delta_); - } - - // redeem - function prop_redeem(address caller, address receiver, address owner, uint shares) public { - uint oldReceiverAsset = IERC20(_underlying_).balanceOf(receiver); - uint oldOwnerShare = IERC20(_vault_).balanceOf(owner); - uint oldAllowance = IERC20(_vault_).allowance(owner, caller); - - vm.prank(caller); uint assets = vault_redeem(shares, receiver, owner); - - uint newReceiverAsset = IERC20(_underlying_).balanceOf(receiver); - uint newOwnerShare = IERC20(_vault_).balanceOf(owner); - uint newAllowance = IERC20(_vault_).allowance(owner, caller); - - assertApproxEqAbs(newOwnerShare, oldOwnerShare - shares, _delta_, "share"); - assertApproxEqAbs(newReceiverAsset, oldReceiverAsset + assets, _delta_, "asset"); // NOTE: this may fail if the receiver is a contract in which the asset is stored - if (caller != owner && oldAllowance != type(uint).max) assertApproxEqAbs(newAllowance, oldAllowance - shares, _delta_, "allowance"); - - assertTrue(caller == owner || oldAllowance != 0 || (shares == 0 && assets == 0), "access control"); - } - - // - // round trip properties - // - - // redeem(deposit(a)) <= a - function prop_RT_deposit_redeem(address caller, uint assets) public { - if (!_vaultMayBeEmpty) vm.assume(IERC20(_vault_).totalSupply() > 0); - vm.prank(caller); uint shares = vault_deposit(assets, caller); - vm.prank(caller); uint assets2 = vault_redeem(shares, caller, caller); - assertApproxLeAbs(assets2, assets, _delta_); - } - - // s = deposit(a) - // s' = withdraw(a) - // s' >= s - function prop_RT_deposit_withdraw(address caller, uint assets) public { - if (!_vaultMayBeEmpty) vm.assume(IERC20(_vault_).totalSupply() > 0); - vm.prank(caller); uint shares1 = vault_deposit(assets, caller); - vm.prank(caller); uint shares2 = vault_withdraw(assets, caller, caller); - assertApproxGeAbs(shares2, shares1, _delta_); - } - - // deposit(redeem(s)) <= s - function prop_RT_redeem_deposit(address caller, uint shares) public { - vm.prank(caller); uint assets = vault_redeem(shares, caller, caller); - if (!_vaultMayBeEmpty) vm.assume(IERC20(_vault_).totalSupply() > 0); - vm.prank(caller); uint shares2 = vault_deposit(assets, caller); - assertApproxLeAbs(shares2, shares, _delta_); - } - - // a = redeem(s) - // a' = mint(s) - // a' >= a - function prop_RT_redeem_mint(address caller, uint shares) public { - vm.prank(caller); uint assets1 = vault_redeem(shares, caller, caller); - if (!_vaultMayBeEmpty) vm.assume(IERC20(_vault_).totalSupply() > 0); - vm.prank(caller); uint assets2 = vault_mint(shares, caller); - assertApproxGeAbs(assets2, assets1, _delta_); - } - - // withdraw(mint(s)) >= s - function prop_RT_mint_withdraw(address caller, uint shares) public { - if (!_vaultMayBeEmpty) vm.assume(IERC20(_vault_).totalSupply() > 0); - vm.prank(caller); uint assets = vault_mint(shares, caller); - vm.prank(caller); uint shares2 = vault_withdraw(assets, caller, caller); - assertApproxGeAbs(shares2, shares, _delta_); - } - - // a = mint(s) - // a' = redeem(s) - // a' <= a - function prop_RT_mint_redeem(address caller, uint shares) public { - if (!_vaultMayBeEmpty) vm.assume(IERC20(_vault_).totalSupply() > 0); - vm.prank(caller); uint assets1 = vault_mint(shares, caller); - vm.prank(caller); uint assets2 = vault_redeem(shares, caller, caller); - assertApproxLeAbs(assets2, assets1, _delta_); - } - - // mint(withdraw(a)) >= a - function prop_RT_withdraw_mint(address caller, uint assets) public { - vm.prank(caller); uint shares = vault_withdraw(assets, caller, caller); - if (!_vaultMayBeEmpty) vm.assume(IERC20(_vault_).totalSupply() > 0); - vm.prank(caller); uint assets2 = vault_mint(shares, caller); - assertApproxGeAbs(assets2, assets, _delta_); - } - - // s = withdraw(a) - // s' = deposit(a) - // s' <= s - function prop_RT_withdraw_deposit(address caller, uint assets) public { - vm.prank(caller); uint shares1 = vault_withdraw(assets, caller, caller); - if (!_vaultMayBeEmpty) vm.assume(IERC20(_vault_).totalSupply() > 0); - vm.prank(caller); uint shares2 = vault_deposit(assets, caller); - assertApproxLeAbs(shares2, shares1, _delta_); - } - - // - // utils - // - - function vault_convertToShares(uint assets) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.convertToShares.selector, assets)); - } - function vault_convertToAssets(uint shares) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.convertToAssets.selector, shares)); - } - - function vault_maxDeposit(address receiver) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.maxDeposit.selector, receiver)); - } - function vault_maxMint(address receiver) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.maxMint.selector, receiver)); - } - function vault_maxWithdraw(address owner) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.maxWithdraw.selector, owner)); - } - function vault_maxRedeem(address owner) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.maxRedeem.selector, owner)); - } - - function vault_previewDeposit(uint assets) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.previewDeposit.selector, assets)); - } - function vault_previewMint(uint shares) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.previewMint.selector, shares)); - } - function vault_previewWithdraw(uint assets) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.previewWithdraw.selector, assets)); - } - function vault_previewRedeem(uint shares) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.previewRedeem.selector, shares)); - } - - function vault_deposit(uint assets, address receiver) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.deposit.selector, assets, receiver)); - } - function vault_mint(uint shares, address receiver) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.mint.selector, shares, receiver)); - } - function vault_withdraw(uint assets, address receiver, address owner) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.withdraw.selector, assets, receiver, owner)); - } - function vault_redeem(uint shares, address receiver, address owner) internal returns (uint) { - return _call_vault(abi.encodeWithSelector(IERC4626.redeem.selector, shares, receiver, owner)); - } - - function _call_vault(bytes memory data) internal returns (uint) { - (bool success, bytes memory retdata) = _vault_.call(data); - if (success) return abi.decode(retdata, (uint)); - vm.assume(false); // if reverted, discard the current fuzz inputs, and let the fuzzer to start a new fuzz run - return 0; // silence warning - } - - function assertApproxGeAbs(uint a, uint b, uint maxDelta) internal { - if (!(a >= b)) { - uint dt = b - a; - if (dt > maxDelta) { - emit log ("Error: a >=~ b not satisfied [uint]"); - emit log_named_uint (" Value a", a); - emit log_named_uint (" Value b", b); - emit log_named_uint (" Max Delta", maxDelta); - emit log_named_uint (" Delta", dt); - fail(); - } - } - } - - function assertApproxLeAbs(uint a, uint b, uint maxDelta) internal { - if (!(a <= b)) { - uint dt = a - b; - if (dt > maxDelta) { - emit log ("Error: a <=~ b not satisfied [uint]"); - emit log_named_uint (" Value a", a); - emit log_named_uint (" Value b", b); - emit log_named_uint (" Max Delta", maxDelta); - emit log_named_uint (" Delta", dt); - fail(); - } - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/ERC4626.test.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/ERC4626.test.sol deleted file mode 100644 index 6254a05470..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/ERC4626.test.sol +++ /dev/null @@ -1,349 +0,0 @@ -// SPDX-License-Identifier: AGPL-3.0 -pragma solidity >=0.8.0 <0.9.0; - -import "./ERC4626.prop.sol"; - -interface IMockERC20 is IERC20 { - function mint(address to, uint value) external; - function burn(address from, uint value) external; -} - -abstract contract ERC4626Test is ERC4626Prop { - function setUp() public virtual; - - uint constant N = 4; - - struct Init { - address[N] user; - uint[N] share; - uint[N] asset; - int yield; - } - - // setup initial vault state as follows: - // - // totalAssets == sum(init.share) + init.yield - // totalShares == sum(init.share) - // - // init.user[i]'s assets == init.asset[i] - // init.user[i]'s shares == init.share[i] - function setUpVault(Init memory init) public virtual { - // setup initial shares and assets for individual users - for (uint i = 0; i < N; i++) { - address user = init.user[i]; - vm.assume(_isEOA(user)); - // shares - uint shares = init.share[i]; - try IMockERC20(_underlying_).mint(user, shares) {} catch { vm.assume(false); } - _approve(_underlying_, user, _vault_, shares); - vm.prank(user); try IERC4626(_vault_).deposit(shares, user) {} catch { vm.assume(false); } - // assets - uint assets = init.asset[i]; - try IMockERC20(_underlying_).mint(user, assets) {} catch { vm.assume(false); } - } - - // setup initial yield for vault - setUpYield(init); - } - - // setup initial yield - function setUpYield(Init memory init) public virtual { - if (init.yield >= 0) { // gain - uint gain = uint(init.yield); - try IMockERC20(_underlying_).mint(_vault_, gain) {} catch { vm.assume(false); } // this can be replaced by calling yield generating functions if provided by the vault - } else { // loss - vm.assume(init.yield > type(int).min); // avoid overflow in conversion - uint loss = uint(-1 * init.yield); - try IMockERC20(_underlying_).burn(_vault_, loss) {} catch { vm.assume(false); } // this can be replaced by calling yield generating functions if provided by the vault - } - } - - // - // asset - // - - function test_asset(Init memory init) public virtual { - setUpVault(init); - address caller = init.user[0]; - prop_asset(caller); - } - - function test_totalAssets(Init memory init) public virtual { - setUpVault(init); - address caller = init.user[0]; - prop_totalAssets(caller); - } - - // - // convert - // - - function test_convertToShares(Init memory init, uint assets) public virtual { - setUpVault(init); - address caller1 = init.user[0]; - address caller2 = init.user[1]; - prop_convertToShares(caller1, caller2, assets); - } - - function test_convertToAssets(Init memory init, uint shares) public virtual { - setUpVault(init); - address caller1 = init.user[0]; - address caller2 = init.user[1]; - prop_convertToAssets(caller1, caller2, shares); - } - - // - // deposit - // - - function test_maxDeposit(Init memory init) public virtual { - setUpVault(init); - address caller = init.user[0]; - address receiver = init.user[1]; - prop_maxDeposit(caller, receiver); - } - - function test_previewDeposit(Init memory init, uint assets) public virtual { - setUpVault(init); - address caller = init.user[0]; - address receiver = init.user[1]; - address other = init.user[2]; - assets = bound(assets, 0, _max_deposit(caller)); - _approve(_underlying_, caller, _vault_, type(uint).max); - prop_previewDeposit(caller, receiver, other, assets); - } - - function test_deposit(Init memory init, uint assets, uint allowance) public virtual { - setUpVault(init); - address caller = init.user[0]; - address receiver = init.user[1]; - assets = bound(assets, 0, _max_deposit(caller)); - _approve(_underlying_, caller, _vault_, allowance); - prop_deposit(caller, receiver, assets); - } - - // - // mint - // - - function test_maxMint(Init memory init) public virtual { - setUpVault(init); - address caller = init.user[0]; - address receiver = init.user[1]; - prop_maxMint(caller, receiver); - } - - function test_previewMint(Init memory init, uint shares) public virtual { - setUpVault(init); - address caller = init.user[0]; - address receiver = init.user[1]; - address other = init.user[2]; - shares = bound(shares, 0, _max_mint(caller)); - _approve(_underlying_, caller, _vault_, type(uint).max); - prop_previewMint(caller, receiver, other, shares); - } - - function test_mint(Init memory init, uint shares, uint allowance) public virtual { - setUpVault(init); - address caller = init.user[0]; - address receiver = init.user[1]; - shares = bound(shares, 0, _max_mint(caller)); - _approve(_underlying_, caller, _vault_, allowance); - prop_mint(caller, receiver, shares); - } - - // - // withdraw - // - - function test_maxWithdraw(Init memory init) public virtual { - setUpVault(init); - address caller = init.user[0]; - address owner = init.user[1]; - prop_maxWithdraw(caller, owner); - } - - function test_previewWithdraw(Init memory init, uint assets) public virtual { - setUpVault(init); - address caller = init.user[0]; - address receiver = init.user[1]; - address owner = init.user[2]; - address other = init.user[3]; - assets = bound(assets, 0, _max_withdraw(owner)); - _approve(_vault_, owner, caller, type(uint).max); - prop_previewWithdraw(caller, receiver, owner, other, assets); - } - - function test_withdraw(Init memory init, uint assets, uint allowance) public virtual { - setUpVault(init); - address caller = init.user[0]; - address receiver = init.user[1]; - address owner = init.user[2]; - assets = bound(assets, 0, _max_withdraw(owner)); - _approve(_vault_, owner, caller, allowance); - prop_withdraw(caller, receiver, owner, assets); - } - - function testFail_withdraw(Init memory init, uint assets) public virtual { - setUpVault(init); - address caller = init.user[0]; - address receiver = init.user[1]; - address owner = init.user[2]; - assets = bound(assets, 0, _max_withdraw(owner)); - vm.assume(caller != owner); - vm.assume(assets > 0); - _approve(_vault_, owner, caller, 0); - vm.prank(caller); uint shares = IERC4626(_vault_).withdraw(assets, receiver, owner); - assertGt(shares, 0); // this assert is expected to fail - } - - // - // redeem - // - - function test_maxRedeem(Init memory init) public virtual { - setUpVault(init); - address caller = init.user[0]; - address owner = init.user[1]; - prop_maxRedeem(caller, owner); - } - - function test_previewRedeem(Init memory init, uint shares) public virtual { - setUpVault(init); - address caller = init.user[0]; - address receiver = init.user[1]; - address owner = init.user[2]; - address other = init.user[3]; - shares = bound(shares, 0, _max_redeem(owner)); - _approve(_vault_, owner, caller, type(uint).max); - prop_previewRedeem(caller, receiver, owner, other, shares); - } - - function test_redeem(Init memory init, uint shares, uint allowance) public virtual { - setUpVault(init); - address caller = init.user[0]; - address receiver = init.user[1]; - address owner = init.user[2]; - shares = bound(shares, 0, _max_redeem(owner)); - _approve(_vault_, owner, caller, allowance); - prop_redeem(caller, receiver, owner, shares); - } - - function testFail_redeem(Init memory init, uint shares) public virtual { - setUpVault(init); - address caller = init.user[0]; - address receiver = init.user[1]; - address owner = init.user[2]; - shares = bound(shares, 0, _max_redeem(owner)); - vm.assume(caller != owner); - vm.assume(shares > 0); - _approve(_vault_, owner, caller, 0); - vm.prank(caller); IERC4626(_vault_).redeem(shares, receiver, owner); - } - - // - // round trip tests - // - - function test_RT_deposit_redeem(Init memory init, uint assets) public virtual { - setUpVault(init); - address caller = init.user[0]; - assets = bound(assets, 0, _max_deposit(caller)); - _approve(_underlying_, caller, _vault_, type(uint).max); - prop_RT_deposit_redeem(caller, assets); - } - - function test_RT_deposit_withdraw(Init memory init, uint assets) public virtual { - setUpVault(init); - address caller = init.user[0]; - assets = bound(assets, 0, _max_deposit(caller)); - _approve(_underlying_, caller, _vault_, type(uint).max); - prop_RT_deposit_withdraw(caller, assets); - } - - function test_RT_redeem_deposit(Init memory init, uint shares) public virtual { - setUpVault(init); - address caller = init.user[0]; - shares = bound(shares, 0, _max_redeem(caller)); - _approve(_underlying_, caller, _vault_, type(uint).max); - prop_RT_redeem_deposit(caller, shares); - } - - function test_RT_redeem_mint(Init memory init, uint shares) public virtual { - setUpVault(init); - address caller = init.user[0]; - shares = bound(shares, 0, _max_redeem(caller)); - _approve(_underlying_, caller, _vault_, type(uint).max); - prop_RT_redeem_mint(caller, shares); - } - - function test_RT_mint_withdraw(Init memory init, uint shares) public virtual { - setUpVault(init); - address caller = init.user[0]; - shares = bound(shares, 0, _max_mint(caller)); - _approve(_underlying_, caller, _vault_, type(uint).max); - prop_RT_mint_withdraw(caller, shares); - } - - function test_RT_mint_redeem(Init memory init, uint shares) public virtual { - setUpVault(init); - address caller = init.user[0]; - shares = bound(shares, 0, _max_mint(caller)); - _approve(_underlying_, caller, _vault_, type(uint).max); - prop_RT_mint_redeem(caller, shares); - } - - function test_RT_withdraw_mint(Init memory init, uint assets) public virtual { - setUpVault(init); - address caller = init.user[0]; - assets = bound(assets, 0, _max_withdraw(caller)); - _approve(_underlying_, caller, _vault_, type(uint).max); - prop_RT_withdraw_mint(caller, assets); - } - - function test_RT_withdraw_deposit(Init memory init, uint assets) public virtual { - setUpVault(init); - address caller = init.user[0]; - assets = bound(assets, 0, _max_withdraw(caller)); - _approve(_underlying_, caller, _vault_, type(uint).max); - prop_RT_withdraw_deposit(caller, assets); - } - - // - // utils - // - - function _isContract(address account) internal view returns (bool) { return account.code.length > 0; } - function _isEOA (address account) internal view returns (bool) { return account.code.length == 0; } - - function _approve(address token, address owner, address spender, uint amount) internal { - vm.prank(owner); _safeApprove(token, spender, 0); - vm.prank(owner); _safeApprove(token, spender, amount); - } - - function _safeApprove(address token, address spender, uint amount) internal { - (bool success, bytes memory retdata) = token.call(abi.encodeWithSelector(IERC20.approve.selector, spender, amount)); - vm.assume(success); - if (retdata.length > 0) vm.assume(abi.decode(retdata, (bool))); - } - - function _max_deposit(address from) internal virtual returns (uint) { - if (_unlimitedAmount) return type(uint).max; - return IERC20(_underlying_).balanceOf(from); - } - - function _max_mint(address from) internal virtual returns (uint) { - if (_unlimitedAmount) return type(uint).max; - return vault_convertToShares(IERC20(_underlying_).balanceOf(from)); - } - - function _max_withdraw(address from) internal virtual returns (uint) { - if (_unlimitedAmount) return type(uint).max; - return vault_convertToAssets(IERC20(_vault_).balanceOf(from)); // may be different from maxWithdraw(from) - } - - function _max_redeem(address from) internal virtual returns (uint) { - if (_unlimitedAmount) return type(uint).max; - return IERC20(_vault_).balanceOf(from); // may be different from maxRedeem(from) - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/LICENSE b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/LICENSE deleted file mode 100644 index 0ad25db4bd..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/LICENSE +++ /dev/null @@ -1,661 +0,0 @@ - GNU AFFERO GENERAL PUBLIC LICENSE - Version 3, 19 November 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU Affero General Public License is a free, copyleft license for -software and other kinds of works, specifically designed to ensure -cooperation with the community in the case of network server software. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -our General Public Licenses are intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - Developers that use our General Public Licenses protect your rights -with two steps: (1) assert copyright on the software, and (2) offer -you this License which gives you legal permission to copy, distribute -and/or modify the software. - - A secondary benefit of defending all users' freedom is that -improvements made in alternate versions of the program, if they -receive widespread use, become available for other developers to -incorporate. Many developers of free software are heartened and -encouraged by the resulting cooperation. However, in the case of -software used on network servers, this result may fail to come about. -The GNU General Public License permits making a modified version and -letting the public access it on a server without ever releasing its -source code to the public. - - The GNU Affero General Public License is designed specifically to -ensure that, in such cases, the modified source code becomes available -to the community. It requires the operator of a network server to -provide the source code of the modified version running there to the -users of that server. Therefore, public use of a modified version, on -a publicly accessible server, gives the public access to the source -code of the modified version. - - An older license, called the Affero General Public License and -published by Affero, was designed to accomplish similar goals. This is -a different license, not a version of the Affero GPL, but Affero has -released a new version of the Affero GPL which permits relicensing under -this license. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU Affero General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Remote Network Interaction; Use with the GNU General Public License. - - Notwithstanding any other provision of this License, if you modify the -Program, your modified version must prominently offer all users -interacting with it remotely through a computer network (if your version -supports such interaction) an opportunity to receive the Corresponding -Source of your version by providing access to the Corresponding Source -from a network server at no charge, through some standard or customary -means of facilitating copying of software. This Corresponding Source -shall include the Corresponding Source for any work covered by version 3 -of the GNU General Public License that is incorporated pursuant to the -following paragraph. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the work with which it is combined will remain governed by version -3 of the GNU General Public License. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU Affero General Public License from time to time. Such new versions -will be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU Affero General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU Affero General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU Affero General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU Affero General Public License as published - by the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU Affero General Public License for more details. - - You should have received a copy of the GNU Affero General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If your software can interact with users remotely through a computer -network, you should also make sure that it provides a way for users to -get its source. For example, if your program is a web application, its -interface could display a "Source" link that leads users to an archive -of the code. There are many ways you could offer source, and different -solutions will be better for different programs; see section 13 for the -specific requirements. - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU AGPL, see -. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/README.md b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/README.md deleted file mode 100644 index c4731fc67d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/README.md +++ /dev/null @@ -1,121 +0,0 @@ -# ERC4626 Property Tests - -Foundry (dapptools-style) property-based tests for [ERC4626] standard conformance. - -[ERC4626]: https://eips.ethereum.org/EIPS/eip-4626 - -You can read our post on "_[Generalized property tests for ERC4626 vaults][post]_." - -[post]: https://a16zcrypto.com/generalized-property-tests-for-erc4626-vaults - -## Overview - -#### What is it? - -- Test suites for checking if the given ERC4626 implementation satisfies the **standard requirements**. -- Dapptools-style **property-based tests** for fuzzing or symbolic execution testing. -- Tests that are **independent** from implementation details, thus applicable for any ERC4626 vaults. - -#### What isn’t it? - -- It does NOT test implementation-specific details, e.g., how to generate and distribute yields, how to compute the share price, etc. - -#### Testing properties: - -- **Round-trip properties**: no one can make a free profit by depositing and immediately withdrawing back and forth. - -- **Functional correctness**: the `deposit()`, `mint()`, `withdraw()`, and `redeem()` functions update the balance and allowance properly. - -- The `preview{Deposit,Redeem}()` functions **MUST NOT over-estimate** the exact amount.[^1] - -[^1]: That is, the `deposit()` and `redeem()` functions “MUST return the same or more amounts as their preview function if called in the same transaction.” - -- The `preview{Mint,Withdraw}()` functions **MUST NOT under-estimate** the exact amount.[^2] - -[^2]: That is, the `mint()` and `withdraw()` functions “MUST return the same or fewer amounts as their preview function if called in the same transaction.” - -- The `convertTo{Shares,Assets}` functions “**MUST NOT show any variations** depending on the caller.” - -- The `asset()`, `totalAssets()`, and `max{Deposit,Mint,Withdraw,Redeem}()` functions “**MUST NOT revert**.” - -## Usage - -**Step 0**: Install [foundry] and add [forge-std] in your vault repo: - -```bash -$ curl -L https://foundry.paradigm.xyz | bash - -$ cd /path/to/your-erc4626-vault -$ forge install foundry-rs/forge-std -``` - -[foundry]: https://getfoundry.sh/ -[forge-std]: https://github.com/foundry-rs/forge-std - -**Step 1**: Add this [erc4626-tests] as a dependency to your vault: - -```bash -$ cd /path/to/your-erc4626-vault -$ forge install a16z/erc4626-tests -``` - -[erc4626-tests]: https://github.com/a16z/erc4626-tests - -**Step 2**: Extend the abstract test contract [`ERC4626Test`](ERC4626.test.sol) with your own custom vault setup method, for example: - -```solidity -// SPDX-License-Identifier: AGPL-3.0 -pragma solidity >=0.8.0 <0.9.0; - -import 'erc4626-tests/ERC4626.test.sol'; - -import { ERC20Mock } from '/path/to/mocks/ERC20Mock.sol'; -import { ERC4626Mock } from '/path/to/mocks/ERC4626Mock.sol'; - -contract ERC4626StdTest is ERC4626Test { - function setUp() public override { - _underlying_ = address(new ERC20Mock('Mock ERC20', 'MERC20', 18)); - _vault_ = address(new ERC4626Mock(ERC20Mock(__underlying__), 'Mock ERC4626', 'MERC4626')); - _delta_ = 0; - _vaultMayBeEmpty = false; - _unlimitedAmount = false; - } -} -``` - -Specifically, set the state variables as follows: - -- `_vault_`: the address of your ERC4626 vault. -- `_underlying_`: the address of the underlying asset of your vault. Note that the default `setupVault()` and `setupYield()` methods of `ERC4626Test` assume that it implements `mint(address to, uint value)` and `burn(address from, uint value)`. You can override the setup methods with your own if such `mint()` and `burn()` are not implemented. -- `_delta_`: the maximum approximation error size to be passed to [`assertApproxEqAbs()`]. It must be given as an absolute value (not a percentage) in the smallest unit (e.g., Wei or Satoshi). Note that all the tests are expected to pass with `__delta__ == 0` as long as your vault follows the [preferred rounding direction] as specified in the standard. If your vault doesn't follow the preferred rounding direction, you can set `__delta__` to a reasonable size of rounding errors where the adversarial profit of exploiting such rounding errors stays sufficiently small compared to the gas cost. (You can read our [post] for more about the adversarial profit.) -- `_vaultMayBeEmpty`: when set to false, fuzz inputs that empties the vault are ignored. -- `_unlimitedAmount`: when set to false, fuzz inputs are restricted to the currently available amount from the caller. Limiting the amount can speed up fuzzing, but may miss some edge cases. - -[`assertApproxEqAbs()`]: https://book.getfoundry.sh/reference/forge-std/assertApproxEqAbs -[preferred rounding direction]: https://eips.ethereum.org/EIPS/eip-4626#security-considerations - -**Step 3**: Run `forge test` - -``` -$ forge test -``` - -## Examples - -Below are examples of adding these property tests to existing ERC4626 vaults: - -- [OpenZeppelin ERC4626] [[diff](https://github.com/daejunpark/openzeppelin-contracts/pull/1/files)] -- [Solmate ERC4626] [[diff](https://github.com/daejunpark/solmate/pull/1/files)] -- [Revenue Distribution Token] [[diff](https://github.com/daejunpark/revenue-distribution-token/pull/1/files)] -- [Yield Daddy ERC4626 wrappers] [[diff](https://github.com/daejunpark/yield-daddy/pull/1/files)][^bug] - -[OpenZeppelin ERC4626]: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/a1948250ab8c441f6d327a65754cb20d2b1b4554/contracts/token/ERC20/extensions/ERC4626.sol -[Solmate ERC4626]: https://github.com/transmissions11/solmate/blob/c2594bf4635ad773a8f4763e20b7e79582e41535/src/mixins/ERC4626.sol -[Revenue Distribution Token]: https://github.com/maple-labs/revenue-distribution-token/blob/be9592fd72bfa7142a217507f2d5500a7856329e/contracts/RevenueDistributionToken.sol -[Yield Daddy ERC4626 wrappers]: https://github.com/timeless-fi/yield-daddy - -[^bug]: Our property tests indeed revealed an [issue](https://github.com/timeless-fi/yield-daddy/issues/7) in their eToken testing mock contract. The tests passed after it is [fixed](https://github.com/daejunpark/yield-daddy/commit/721cf4bd766805fd409455434aa5fd1a9b2df25c). - -## Disclaimer - -_These smart contracts are being provided as is. No guarantee, representation or warranty is being made, express or implied, as to the safety or correctness of the user interface or the smart contracts. They have not been audited and as such there can be no assurance they will work as intended, and users may experience delays, failures, errors, omissions or loss of transmitted information. THE SMART CONTRACTS CONTAINED HEREIN ARE FURNISHED AS IS, WHERE IS, WITH ALL FAULTS AND WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING ANY WARRANTY OF MERCHANTABILITY, NON-INFRINGEMENT OR FITNESS FOR ANY PARTICULAR PURPOSE. Further, use of any of these smart contracts may be restricted or prohibited under applicable law, including securities laws, and it is therefore strongly advised for you to contact a reputable attorney in any jurisdiction where these smart contracts may be accessible for any questions or concerns with respect thereto. Further, no information provided in this repo should be construed as investment advice or legal advice for any particular facts or circumstances, and is not meant to replace competent counsel. a16z is not liable for any use of the foregoing, and users should proceed with caution and use at their own risk. See a16z.com/disclosures for more info._ diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/.gitattributes b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/.gitattributes deleted file mode 100644 index 27042d458c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/.gitattributes +++ /dev/null @@ -1 +0,0 @@ -src/Vm.sol linguist-generated diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/.github/workflows/ci.yml b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/.github/workflows/ci.yml deleted file mode 100644 index 2d68e91fba..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/.github/workflows/ci.yml +++ /dev/null @@ -1,128 +0,0 @@ -name: CI - -on: - workflow_dispatch: - pull_request: - push: - branches: - - master - -jobs: - build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - - name: Install Foundry - uses: foundry-rs/foundry-toolchain@v1 - with: - version: nightly - - - name: Print forge version - run: forge --version - - # Backwards compatibility checks: - # - the oldest and newest version of each supported minor version - # - versions with specific issues - - name: Check compatibility with latest - if: always() - run: | - output=$(forge build --skip test) - if echo "$output" | grep -q "Warning"; then - echo "$output" - exit 1 - fi - - - name: Check compatibility with 0.8.0 - if: always() - run: | - output=$(forge build --skip test --use solc:0.8.0) - if echo "$output" | grep -q "Warning"; then - echo "$output" - exit 1 - fi - - - name: Check compatibility with 0.7.6 - if: always() - run: | - output=$(forge build --skip test --use solc:0.7.6) - if echo "$output" | grep -q "Warning"; then - echo "$output" - exit 1 - fi - - - name: Check compatibility with 0.7.0 - if: always() - run: | - output=$(forge build --skip test --use solc:0.7.0) - if echo "$output" | grep -q "Warning"; then - echo "$output" - exit 1 - fi - - - name: Check compatibility with 0.6.12 - if: always() - run: | - output=$(forge build --skip test --use solc:0.6.12) - if echo "$output" | grep -q "Warning"; then - echo "$output" - exit 1 - fi - - - name: Check compatibility with 0.6.2 - if: always() - run: | - output=$(forge build --skip test --use solc:0.6.2) - if echo "$output" | grep -q "Warning"; then - echo "$output" - exit 1 - fi - - # via-ir compilation time checks. - - name: Measure compilation time of Test with 0.8.17 --via-ir - if: always() - run: forge build --skip test --contracts test/compilation/CompilationTest.sol --use solc:0.8.17 --via-ir - - - name: Measure compilation time of TestBase with 0.8.17 --via-ir - if: always() - run: forge build --skip test --contracts test/compilation/CompilationTestBase.sol --use solc:0.8.17 --via-ir - - - name: Measure compilation time of Script with 0.8.17 --via-ir - if: always() - run: forge build --skip test --contracts test/compilation/CompilationScript.sol --use solc:0.8.17 --via-ir - - - name: Measure compilation time of ScriptBase with 0.8.17 --via-ir - if: always() - run: forge build --skip test --contracts test/compilation/CompilationScriptBase.sol --use solc:0.8.17 --via-ir - - test: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - - name: Install Foundry - uses: foundry-rs/foundry-toolchain@v1 - with: - version: nightly - - - name: Print forge version - run: forge --version - - - name: Run tests - run: forge test -vvv - - fmt: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - - name: Install Foundry - uses: foundry-rs/foundry-toolchain@v1 - with: - version: nightly - - - name: Print forge version - run: forge --version - - - name: Check formatting - run: forge fmt --check diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/.github/workflows/sync.yml b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/.github/workflows/sync.yml deleted file mode 100644 index 9b170f0b74..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/.github/workflows/sync.yml +++ /dev/null @@ -1,31 +0,0 @@ -name: Sync Release Branch - -on: - release: - types: - - created - -jobs: - sync-release-branch: - runs-on: ubuntu-latest - if: startsWith(github.event.release.tag_name, 'v1') - steps: - - name: Check out the repo - uses: actions/checkout@v4 - with: - fetch-depth: 0 - ref: v1 - - # The email is derived from the bots user id, - # found here: https://api.github.com/users/github-actions%5Bbot%5D - - name: Configure Git - run: | - git config user.name github-actions[bot] - git config user.email 41898282+github-actions[bot]@users.noreply.github.com - - - name: Sync Release Branch - run: | - git fetch --tags - git checkout v1 - git reset --hard ${GITHUB_REF} - git push --force diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/LICENSE-APACHE b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/LICENSE-APACHE deleted file mode 100644 index cf01a499fb..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/LICENSE-APACHE +++ /dev/null @@ -1,203 +0,0 @@ -Copyright Contributors to Forge Standard Library - - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - -TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - -1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - -2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - -3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - -4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - -5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - -6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - -7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - -8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - -9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - -END OF TERMS AND CONDITIONS - -APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - -Copyright [yyyy] [name of copyright owner] - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/LICENSE-MIT b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/LICENSE-MIT deleted file mode 100644 index 28f98304ac..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/LICENSE-MIT +++ /dev/null @@ -1,25 +0,0 @@ -Copyright Contributors to Forge Standard Library - -Permission is hereby granted, free of charge, to any -person obtaining a copy of this software and associated -documentation files (the "Software"), to deal in the -Software without restriction, including without -limitation the rights to use, copy, modify, merge, -publish, distribute, sublicense, and/or sell copies of -the Software, and to permit persons to whom the Software -is furnished to do so, subject to the following -conditions: - -The above copyright notice and this permission notice -shall be included in all copies or substantial portions -of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF -ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED -TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A -PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT -SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR -IN CONNECTION WITH THE SOFTWARE O THE USE OR OTHER -DEALINGS IN THE SOFTWARE.R diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/README.md b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/README.md deleted file mode 100644 index 230aaf2638..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/README.md +++ /dev/null @@ -1,235 +0,0 @@ -# Forge Standard Library • [![CI status](https://github.com/foundry-rs/forge-std/actions/workflows/ci.yml/badge.svg)](https://github.com/foundry-rs/forge-std/actions/workflows/ci.yml) - -Forge Standard Library is a collection of helpful contracts and libraries for use with [Forge and Foundry](https://github.com/foundry-rs/foundry). It leverages Forge's cheatcodes to make writing tests easier and faster, while improving the UX of cheatcodes. - -**Learn how to use Forge-Std with the [📖 Foundry Book (Forge-Std Guide)](https://book.getfoundry.sh/forge/forge-std.html).** - -## Install - -```bash -forge install foundry-rs/forge-std -``` - -## Contracts - -### stdError - -This is a helper contract for errors and reverts. In Forge, this contract is particularly helpful for the `expectRevert` cheatcode, as it provides all compiler builtin errors. - -See the contract itself for all error codes. - -#### Example usage - -```solidity -import 'forge-std/Test.sol'; - -contract TestContract is Test { - ErrorsTest test; - - function setUp() public { - test = new ErrorsTest(); - } - - function testExpectArithmetic() public { - vm.expectRevert(stdError.arithmeticError); - test.arithmeticError(10); - } -} - -contract ErrorsTest { - function arithmeticError(uint256 a) public { - uint256 a = a - 100; - } -} -``` - -### stdStorage - -This is a rather large contract due to all of the overloading to make the UX decent. Primarily, it is a wrapper around the `record` and `accesses` cheatcodes. It can _always_ find and write the storage slot(s) associated with a particular variable without knowing the storage layout. The one _major_ caveat to this is while a slot can be found for packed storage variables, we can't write to that variable safely. If a user tries to write to a packed slot, the execution throws an error, unless it is uninitialized (`bytes32(0)`). - -This works by recording all `SLOAD`s and `SSTORE`s during a function call. If there is a single slot read or written to, it immediately returns the slot. Otherwise, behind the scenes, we iterate through and check each one (assuming the user passed in a `depth` parameter). If the variable is a struct, you can pass in a `depth` parameter which is basically the field depth. - -I.e.: - -```solidity -struct T { - // depth 0 - uint256 a; - // depth 1 - uint256 b; -} -``` - -#### Example usage - -```solidity -import 'forge-std/Test.sol'; - -contract TestContract is Test { - using stdStorage for StdStorage; - - Storage test; - - function setUp() public { - test = new Storage(); - } - - function testFindExists() public { - // Lets say we want to find the slot for the public - // variable `exists`. We just pass in the function selector - // to the `find` command - uint256 slot = stdstore.target(address(test)).sig('exists()').find(); - assertEq(slot, 0); - } - - function testWriteExists() public { - // Lets say we want to write to the slot for the public - // variable `exists`. We just pass in the function selector - // to the `checked_write` command - stdstore.target(address(test)).sig('exists()').checked_write(100); - assertEq(test.exists(), 100); - } - - // It supports arbitrary storage layouts, like assembly based storage locations - function testFindHidden() public { - // `hidden` is a random hash of a bytes, iteration through slots would - // not find it. Our mechanism does - // Also, you can use the selector instead of a string - uint256 slot = stdstore.target(address(test)).sig(test.hidden.selector).find(); - assertEq(slot, uint256(keccak256('my.random.var'))); - } - - // If targeting a mapping, you have to pass in the keys necessary to perform the find - // i.e.: - function testFindMapping() public { - uint256 slot = stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).find(); - // in the `Storage` constructor, we wrote that this address' value was 1 in the map - // so when we load the slot, we expect it to be 1 - assertEq(uint(vm.load(address(test), bytes32(slot))), 1); - } - - // If the target is a struct, you can specify the field depth: - function testFindStruct() public { - // NOTE: see the depth parameter - 0 means 0th field, 1 means 1st field, etc. - uint256 slot_for_a_field = stdstore.target(address(test)).sig(test.basicStruct.selector).depth(0).find(); - - uint256 slot_for_b_field = stdstore.target(address(test)).sig(test.basicStruct.selector).depth(1).find(); - - assertEq(uint(vm.load(address(test), bytes32(slot_for_a_field))), 1); - assertEq(uint(vm.load(address(test), bytes32(slot_for_b_field))), 2); - } -} - -// A complex storage contract -contract Storage { - struct UnpackedStruct { - uint256 a; - uint256 b; - } - - constructor() { - map_addr[msg.sender] = 1; - } - - uint256 public exists = 1; - mapping(address => uint256) public map_addr; - // mapping(address => Packed) public map_packed; - mapping(address => UnpackedStruct) public map_struct; - mapping(address => mapping(address => uint256)) public deep_map; - mapping(address => mapping(address => UnpackedStruct)) public deep_map_struct; - UnpackedStruct public basicStruct = UnpackedStruct({ a: 1, b: 2 }); - - function hidden() public view returns (bytes32 t) { - // an extremely hidden storage slot - bytes32 slot = keccak256('my.random.var'); - assembly { - t := sload(slot) - } - } -} -``` - -### stdCheats - -This is a wrapper over miscellaneous cheatcodes that need wrappers to be more dev friendly. Currently there are only functions related to `prank`. In general, users may expect ETH to be put into an address on `prank`, but this is not the case for safety reasons. Explicitly this `hoax` function should only be used for addresses that have expected balances as it will get overwritten. If an address already has ETH, you should just use `prank`. If you want to change that balance explicitly, just use `deal`. If you want to do both, `hoax` is also right for you. - -#### Example usage: - -```solidity -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.0; - -import 'forge-std/Test.sol'; - -// Inherit the stdCheats -contract StdCheatsTest is Test { - Bar test; - function setUp() public { - test = new Bar(); - } - - function testHoax() public { - // we call `hoax`, which gives the target address - // eth and then calls `prank` - hoax(address(1337)); - test.bar{ value: 100 }(address(1337)); - - // overloaded to allow you to specify how much eth to - // initialize the address with - hoax(address(1337), 1); - test.bar{ value: 1 }(address(1337)); - } - - function testStartHoax() public { - // we call `startHoax`, which gives the target address - // eth and then calls `startPrank` - // - // it is also overloaded so that you can specify an eth amount - startHoax(address(1337)); - test.bar{ value: 100 }(address(1337)); - test.bar{ value: 100 }(address(1337)); - vm.stopPrank(); - test.bar(address(this)); - } -} - -contract Bar { - function bar(address expectedSender) public payable { - require(msg.sender == expectedSender, '!prank'); - } -} -``` - -### Std Assertions - -Contains various assertions. - -### `console.log` - -Usage follows the same format as [Hardhat](https://hardhat.org/hardhat-network/reference/#console-log). -It's recommended to use `console2.sol` as shown below, as this will show the decoded logs in Forge traces. - -```solidity -// import it indirectly via Test.sol -import "forge-std/Test.sol"; -// or directly import it -import "forge-std/console2.sol"; -... -console2.log(someValue); -``` - -If you need compatibility with Hardhat, you must use the standard `console.sol` instead. -Due to a bug in `console.sol`, logs that use `uint256` or `int256` types will not be properly decoded in Forge traces. - -```solidity -// import it indirectly via Test.sol -import "forge-std/Test.sol"; -// or directly import it -import "forge-std/console.sol"; -... -console.log(someValue); -``` - -## License - -Forge Standard Library is offered under either [MIT](LICENSE-MIT) or [Apache 2.0](LICENSE-APACHE) license. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/foundry.toml b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/foundry.toml deleted file mode 100644 index 2bc66fa77f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/foundry.toml +++ /dev/null @@ -1,21 +0,0 @@ -[profile.default] -fs_permissions = [{ access = "read-write", path = "./"}] - -[rpc_endpoints] -# The RPC URLs are modified versions of the default for testing initialization. -mainnet = "https://eth-mainnet.alchemyapi.io/v2/WV407BEiBmjNJfKo9Uo_55u0z0ITyCOX" # Different API key. -optimism_sepolia = "https://sepolia.optimism.io/" # Adds a trailing slash. -arbitrum_one_sepolia = "https://sepolia-rollup.arbitrum.io/rpc/" # Adds a trailing slash. -needs_undefined_env_var = "${UNDEFINED_RPC_URL_PLACEHOLDER}" - -[fmt] -# These are all the `forge fmt` defaults. -line_length = 120 -tab_width = 4 -bracket_spacing = false -int_types = 'long' -multiline_func_header = 'attributes_first' -quote_style = 'double' -number_underscore = 'preserve' -single_line_statement_blocks = 'preserve' -ignore = ["src/console.sol", "src/console2.sol"] \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/package.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/package.json deleted file mode 100644 index 9bc3d242cb..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/package.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "name": "forge-std", - "version": "1.9.3", - "description": "Forge Standard Library is a collection of helpful contracts and libraries for use with Forge and Foundry.", - "homepage": "https://book.getfoundry.sh/forge/forge-std", - "bugs": "https://github.com/foundry-rs/forge-std/issues", - "license": "(Apache-2.0 OR MIT)", - "author": "Contributors to Forge Standard Library", - "files": [ - "src/**/*" - ], - "repository": { - "type": "git", - "url": "https://github.com/foundry-rs/forge-std.git" - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/scripts/vm.py b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/scripts/vm.py deleted file mode 100644 index f0537db9b6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/scripts/vm.py +++ /dev/null @@ -1,635 +0,0 @@ -#!/usr/bin/env python3 - -import copy -import json -import re -import subprocess -from enum import Enum as PyEnum -from typing import Callable -from urllib import request - -VoidFn = Callable[[], None] - -CHEATCODES_JSON_URL = "https://raw.githubusercontent.com/foundry-rs/foundry/master/crates/cheatcodes/assets/cheatcodes.json" -OUT_PATH = "src/Vm.sol" - -VM_SAFE_DOC = """\ -/// The `VmSafe` interface does not allow manipulation of the EVM state or other actions that may -/// result in Script simulations differing from on-chain execution. It is recommended to only use -/// these cheats in scripts. -""" - -VM_DOC = """\ -/// The `Vm` interface does allow manipulation of the EVM state. These are all intended to be used -/// in tests, but it is not recommended to use these cheats in scripts. -""" - - -def main(): - json_str = request.urlopen(CHEATCODES_JSON_URL).read().decode("utf-8") - contract = Cheatcodes.from_json(json_str) - - ccs = contract.cheatcodes - ccs = list(filter(lambda cc: cc.status not in ["experimental", "internal"], ccs)) - ccs.sort(key=lambda cc: cc.func.id) - - safe = list(filter(lambda cc: cc.safety == "safe", ccs)) - safe.sort(key=CmpCheatcode) - unsafe = list(filter(lambda cc: cc.safety == "unsafe", ccs)) - unsafe.sort(key=CmpCheatcode) - assert len(safe) + len(unsafe) == len(ccs) - - prefix_with_group_headers(safe) - prefix_with_group_headers(unsafe) - - out = "" - - out += "// Automatically @generated by scripts/vm.py. Do not modify manually.\n\n" - - pp = CheatcodesPrinter( - spdx_identifier="MIT OR Apache-2.0", - solidity_requirement=">=0.6.2 <0.9.0", - abicoder_pragma=True, - ) - pp.p_prelude() - pp.prelude = False - out += pp.finish() - - out += "\n\n" - out += VM_SAFE_DOC - vm_safe = Cheatcodes( - # TODO: Custom errors were introduced in 0.8.4 - errors=[], # contract.errors - events=contract.events, - enums=contract.enums, - structs=contract.structs, - cheatcodes=safe, - ) - pp.p_contract(vm_safe, "VmSafe") - out += pp.finish() - - out += "\n\n" - out += VM_DOC - vm_unsafe = Cheatcodes( - errors=[], - events=[], - enums=[], - structs=[], - cheatcodes=unsafe, - ) - pp.p_contract(vm_unsafe, "Vm", "VmSafe") - out += pp.finish() - - # Compatibility with <0.8.0 - def memory_to_calldata(m: re.Match) -> str: - return " calldata " + m.group(1) - - out = re.sub(r" memory (.*returns)", memory_to_calldata, out) - - with open(OUT_PATH, "w") as f: - f.write(out) - - forge_fmt = ["forge", "fmt", OUT_PATH] - res = subprocess.run(forge_fmt) - assert res.returncode == 0, f"command failed: {forge_fmt}" - - print(f"Wrote to {OUT_PATH}") - - -class CmpCheatcode: - cheatcode: "Cheatcode" - - def __init__(self, cheatcode: "Cheatcode"): - self.cheatcode = cheatcode - - def __lt__(self, other: "CmpCheatcode") -> bool: - return cmp_cheatcode(self.cheatcode, other.cheatcode) < 0 - - def __eq__(self, other: "CmpCheatcode") -> bool: - return cmp_cheatcode(self.cheatcode, other.cheatcode) == 0 - - def __gt__(self, other: "CmpCheatcode") -> bool: - return cmp_cheatcode(self.cheatcode, other.cheatcode) > 0 - - -def cmp_cheatcode(a: "Cheatcode", b: "Cheatcode") -> int: - if a.group != b.group: - return -1 if a.group < b.group else 1 - if a.status != b.status: - return -1 if a.status < b.status else 1 - if a.safety != b.safety: - return -1 if a.safety < b.safety else 1 - if a.func.id != b.func.id: - return -1 if a.func.id < b.func.id else 1 - return 0 - - -# HACK: A way to add group header comments without having to modify printer code -def prefix_with_group_headers(cheats: list["Cheatcode"]): - s = set() - for i, cheat in enumerate(cheats): - if cheat.group in s: - continue - - s.add(cheat.group) - - c = copy.deepcopy(cheat) - c.func.description = "" - c.func.declaration = f"// ======== {group(c.group)} ========" - cheats.insert(i, c) - return cheats - - -def group(s: str) -> str: - if s == "evm": - return "EVM" - if s == "json": - return "JSON" - return s[0].upper() + s[1:] - - -class Visibility(PyEnum): - EXTERNAL: str = "external" - PUBLIC: str = "public" - INTERNAL: str = "internal" - PRIVATE: str = "private" - - def __str__(self): - return self.value - - -class Mutability(PyEnum): - PURE: str = "pure" - VIEW: str = "view" - NONE: str = "" - - def __str__(self): - return self.value - - -class Function: - id: str - description: str - declaration: str - visibility: Visibility - mutability: Mutability - signature: str - selector: str - selector_bytes: bytes - - def __init__( - self, - id: str, - description: str, - declaration: str, - visibility: Visibility, - mutability: Mutability, - signature: str, - selector: str, - selector_bytes: bytes, - ): - self.id = id - self.description = description - self.declaration = declaration - self.visibility = visibility - self.mutability = mutability - self.signature = signature - self.selector = selector - self.selector_bytes = selector_bytes - - @staticmethod - def from_dict(d: dict) -> "Function": - return Function( - d["id"], - d["description"], - d["declaration"], - Visibility(d["visibility"]), - Mutability(d["mutability"]), - d["signature"], - d["selector"], - bytes(d["selectorBytes"]), - ) - - -class Cheatcode: - func: Function - group: str - status: str - safety: str - - def __init__(self, func: Function, group: str, status: str, safety: str): - self.func = func - self.group = group - self.status = status - self.safety = safety - - @staticmethod - def from_dict(d: dict) -> "Cheatcode": - return Cheatcode( - Function.from_dict(d["func"]), - str(d["group"]), - str(d["status"]), - str(d["safety"]), - ) - - -class Error: - name: str - description: str - declaration: str - - def __init__(self, name: str, description: str, declaration: str): - self.name = name - self.description = description - self.declaration = declaration - - @staticmethod - def from_dict(d: dict) -> "Error": - return Error(**d) - - -class Event: - name: str - description: str - declaration: str - - def __init__(self, name: str, description: str, declaration: str): - self.name = name - self.description = description - self.declaration = declaration - - @staticmethod - def from_dict(d: dict) -> "Event": - return Event(**d) - - -class EnumVariant: - name: str - description: str - - def __init__(self, name: str, description: str): - self.name = name - self.description = description - - -class Enum: - name: str - description: str - variants: list[EnumVariant] - - def __init__(self, name: str, description: str, variants: list[EnumVariant]): - self.name = name - self.description = description - self.variants = variants - - @staticmethod - def from_dict(d: dict) -> "Enum": - return Enum( - d["name"], - d["description"], - list(map(lambda v: EnumVariant(**v), d["variants"])), - ) - - -class StructField: - name: str - ty: str - description: str - - def __init__(self, name: str, ty: str, description: str): - self.name = name - self.ty = ty - self.description = description - - -class Struct: - name: str - description: str - fields: list[StructField] - - def __init__(self, name: str, description: str, fields: list[StructField]): - self.name = name - self.description = description - self.fields = fields - - @staticmethod - def from_dict(d: dict) -> "Struct": - return Struct( - d["name"], - d["description"], - list(map(lambda f: StructField(**f), d["fields"])), - ) - - -class Cheatcodes: - errors: list[Error] - events: list[Event] - enums: list[Enum] - structs: list[Struct] - cheatcodes: list[Cheatcode] - - def __init__( - self, - errors: list[Error], - events: list[Event], - enums: list[Enum], - structs: list[Struct], - cheatcodes: list[Cheatcode], - ): - self.errors = errors - self.events = events - self.enums = enums - self.structs = structs - self.cheatcodes = cheatcodes - - @staticmethod - def from_dict(d: dict) -> "Cheatcodes": - return Cheatcodes( - errors=[Error.from_dict(e) for e in d["errors"]], - events=[Event.from_dict(e) for e in d["events"]], - enums=[Enum.from_dict(e) for e in d["enums"]], - structs=[Struct.from_dict(e) for e in d["structs"]], - cheatcodes=[Cheatcode.from_dict(e) for e in d["cheatcodes"]], - ) - - @staticmethod - def from_json(s) -> "Cheatcodes": - return Cheatcodes.from_dict(json.loads(s)) - - @staticmethod - def from_json_file(file_path: str) -> "Cheatcodes": - with open(file_path, "r") as f: - return Cheatcodes.from_dict(json.load(f)) - - -class Item(PyEnum): - ERROR: str = "error" - EVENT: str = "event" - ENUM: str = "enum" - STRUCT: str = "struct" - FUNCTION: str = "function" - - -class ItemOrder: - _list: list[Item] - - def __init__(self, list: list[Item]) -> None: - assert len(list) <= len(Item), "list must not contain more items than Item" - assert len(list) == len(set(list)), "list must not contain duplicates" - self._list = list - pass - - def get_list(self) -> list[Item]: - return self._list - - @staticmethod - def default() -> "ItemOrder": - return ItemOrder( - [ - Item.ERROR, - Item.EVENT, - Item.ENUM, - Item.STRUCT, - Item.FUNCTION, - ] - ) - - -class CheatcodesPrinter: - buffer: str - - prelude: bool - spdx_identifier: str - solidity_requirement: str - abicoder_v2: bool - - block_doc_style: bool - - indent_level: int - _indent_str: str - - nl_str: str - - items_order: ItemOrder - - def __init__( - self, - buffer: str = "", - prelude: bool = True, - spdx_identifier: str = "UNLICENSED", - solidity_requirement: str = "", - abicoder_pragma: bool = False, - block_doc_style: bool = False, - indent_level: int = 0, - indent_with: int | str = 4, - nl_str: str = "\n", - items_order: ItemOrder = ItemOrder.default(), - ): - self.prelude = prelude - self.spdx_identifier = spdx_identifier - self.solidity_requirement = solidity_requirement - self.abicoder_v2 = abicoder_pragma - self.block_doc_style = block_doc_style - self.buffer = buffer - self.indent_level = indent_level - self.nl_str = nl_str - - if isinstance(indent_with, int): - assert indent_with >= 0 - self._indent_str = " " * indent_with - elif isinstance(indent_with, str): - self._indent_str = indent_with - else: - assert False, "indent_with must be int or str" - - self.items_order = items_order - - def finish(self) -> str: - ret = self.buffer.rstrip() - self.buffer = "" - return ret - - def p_contract(self, contract: Cheatcodes, name: str, inherits: str = ""): - if self.prelude: - self.p_prelude(contract) - - self._p_str("interface ") - name = name.strip() - if name != "": - self._p_str(name) - self._p_str(" ") - if inherits != "": - self._p_str("is ") - self._p_str(inherits) - self._p_str(" ") - self._p_str("{") - self._p_nl() - self._with_indent(lambda: self._p_items(contract)) - self._p_str("}") - self._p_nl() - - def _p_items(self, contract: Cheatcodes): - for item in self.items_order.get_list(): - if item == Item.ERROR: - self.p_errors(contract.errors) - elif item == Item.EVENT: - self.p_events(contract.events) - elif item == Item.ENUM: - self.p_enums(contract.enums) - elif item == Item.STRUCT: - self.p_structs(contract.structs) - elif item == Item.FUNCTION: - self.p_functions(contract.cheatcodes) - else: - assert False, f"unknown item {item}" - - def p_prelude(self, contract: Cheatcodes | None = None): - self._p_str(f"// SPDX-License-Identifier: {self.spdx_identifier}") - self._p_nl() - - if self.solidity_requirement != "": - req = self.solidity_requirement - elif contract and len(contract.errors) > 0: - req = ">=0.8.4 <0.9.0" - else: - req = ">=0.6.0 <0.9.0" - self._p_str(f"pragma solidity {req};") - self._p_nl() - - if self.abicoder_v2: - self._p_str("pragma experimental ABIEncoderV2;") - self._p_nl() - - self._p_nl() - - def p_errors(self, errors: list[Error]): - for error in errors: - self._p_line(lambda: self.p_error(error)) - - def p_error(self, error: Error): - self._p_comment(error.description, doc=True) - self._p_line(lambda: self._p_str(error.declaration)) - - def p_events(self, events: list[Event]): - for event in events: - self._p_line(lambda: self.p_event(event)) - - def p_event(self, event: Event): - self._p_comment(event.description, doc=True) - self._p_line(lambda: self._p_str(event.declaration)) - - def p_enums(self, enums: list[Enum]): - for enum in enums: - self._p_line(lambda: self.p_enum(enum)) - - def p_enum(self, enum: Enum): - self._p_comment(enum.description, doc=True) - self._p_line(lambda: self._p_str(f"enum {enum.name} {{")) - self._with_indent(lambda: self.p_enum_variants(enum.variants)) - self._p_line(lambda: self._p_str("}")) - - def p_enum_variants(self, variants: list[EnumVariant]): - for i, variant in enumerate(variants): - self._p_indent() - self._p_comment(variant.description) - - self._p_indent() - self._p_str(variant.name) - if i < len(variants) - 1: - self._p_str(",") - self._p_nl() - - def p_structs(self, structs: list[Struct]): - for struct in structs: - self._p_line(lambda: self.p_struct(struct)) - - def p_struct(self, struct: Struct): - self._p_comment(struct.description, doc=True) - self._p_line(lambda: self._p_str(f"struct {struct.name} {{")) - self._with_indent(lambda: self.p_struct_fields(struct.fields)) - self._p_line(lambda: self._p_str("}")) - - def p_struct_fields(self, fields: list[StructField]): - for field in fields: - self._p_line(lambda: self.p_struct_field(field)) - - def p_struct_field(self, field: StructField): - self._p_comment(field.description) - self._p_indented(lambda: self._p_str(f"{field.ty} {field.name};")) - - def p_functions(self, cheatcodes: list[Cheatcode]): - for cheatcode in cheatcodes: - self._p_line(lambda: self.p_function(cheatcode.func)) - - def p_function(self, func: Function): - self._p_comment(func.description, doc=True) - self._p_line(lambda: self._p_str(func.declaration)) - - def _p_comment(self, s: str, doc: bool = False): - s = s.strip() - if s == "": - return - - s = map(lambda line: line.lstrip(), s.split("\n")) - if self.block_doc_style: - self._p_str("/*") - if doc: - self._p_str("*") - self._p_nl() - for line in s: - self._p_indent() - self._p_str(" ") - if doc: - self._p_str("* ") - self._p_str(line) - self._p_nl() - self._p_indent() - self._p_str(" */") - self._p_nl() - else: - first_line = True - for line in s: - if not first_line: - self._p_indent() - first_line = False - - if doc: - self._p_str("/// ") - else: - self._p_str("// ") - self._p_str(line) - self._p_nl() - - def _with_indent(self, f: VoidFn): - self._inc_indent() - f() - self._dec_indent() - - def _p_line(self, f: VoidFn): - self._p_indent() - f() - self._p_nl() - - def _p_indented(self, f: VoidFn): - self._p_indent() - f() - - def _p_indent(self): - for _ in range(self.indent_level): - self._p_str(self._indent_str) - - def _p_nl(self): - self._p_str(self.nl_str) - - def _p_str(self, txt: str): - self.buffer += txt - - def _inc_indent(self): - self.indent_level += 1 - - def _dec_indent(self): - self.indent_level -= 1 - - -if __name__ == "__main__": - main() diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/Base.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/Base.sol deleted file mode 100644 index 851ac0cd2b..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/Base.sol +++ /dev/null @@ -1,35 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -import {StdStorage} from "./StdStorage.sol"; -import {Vm, VmSafe} from "./Vm.sol"; - -abstract contract CommonBase { - // Cheat code address, 0x7109709ECfa91a80626fF3989D68f67F5b1DD12D. - address internal constant VM_ADDRESS = address(uint160(uint256(keccak256("hevm cheat code")))); - // console.sol and console2.sol work by executing a staticcall to this address. - address internal constant CONSOLE = 0x000000000000000000636F6e736F6c652e6c6f67; - // Used when deploying with create2, https://github.com/Arachnid/deterministic-deployment-proxy. - address internal constant CREATE2_FACTORY = 0x4e59b44847b379578588920cA78FbF26c0B4956C; - // Default address for tx.origin and msg.sender, 0x1804c8AB1F12E6bbf3894d4083f33e07309d1f38. - address internal constant DEFAULT_SENDER = address(uint160(uint256(keccak256("foundry default caller")))); - // Address of the test contract, deployed by the DEFAULT_SENDER. - address internal constant DEFAULT_TEST_CONTRACT = 0x5615dEB798BB3E4dFa0139dFa1b3D433Cc23b72f; - // Deterministic deployment address of the Multicall3 contract. - address internal constant MULTICALL3_ADDRESS = 0xcA11bde05977b3631167028862bE2a173976CA11; - // The order of the secp256k1 curve. - uint256 internal constant SECP256K1_ORDER = - 115792089237316195423570985008687907852837564279074904382605163141518161494337; - - uint256 internal constant UINT256_MAX = - 115792089237316195423570985008687907853269984665640564039457584007913129639935; - - Vm internal constant vm = Vm(VM_ADDRESS); - StdStorage internal stdstore; -} - -abstract contract TestBase is CommonBase {} - -abstract contract ScriptBase is CommonBase { - VmSafe internal constant vmSafe = VmSafe(VM_ADDRESS); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/Script.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/Script.sol deleted file mode 100644 index 94e75f6cbc..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/Script.sol +++ /dev/null @@ -1,27 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -// 💬 ABOUT -// Forge Std's default Script. - -// 🧩 MODULES -import {console} from "./console.sol"; -import {console2} from "./console2.sol"; -import {safeconsole} from "./safeconsole.sol"; -import {StdChains} from "./StdChains.sol"; -import {StdCheatsSafe} from "./StdCheats.sol"; -import {stdJson} from "./StdJson.sol"; -import {stdMath} from "./StdMath.sol"; -import {StdStorage, stdStorageSafe} from "./StdStorage.sol"; -import {StdStyle} from "./StdStyle.sol"; -import {StdUtils} from "./StdUtils.sol"; -import {VmSafe} from "./Vm.sol"; - -// 📦 BOILERPLATE -import {ScriptBase} from "./Base.sol"; - -// ⭐️ SCRIPT -abstract contract Script is ScriptBase, StdChains, StdCheatsSafe, StdUtils { - // Note: IS_SCRIPT() must return true. - bool public IS_SCRIPT = true; -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdAssertions.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdAssertions.sol deleted file mode 100644 index 857ecd5704..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdAssertions.sol +++ /dev/null @@ -1,669 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; -pragma experimental ABIEncoderV2; - -import {Vm} from "./Vm.sol"; - -abstract contract StdAssertions { - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - - event log(string); - event logs(bytes); - - event log_address(address); - event log_bytes32(bytes32); - event log_int(int256); - event log_uint(uint256); - event log_bytes(bytes); - event log_string(string); - - event log_named_address(string key, address val); - event log_named_bytes32(string key, bytes32 val); - event log_named_decimal_int(string key, int256 val, uint256 decimals); - event log_named_decimal_uint(string key, uint256 val, uint256 decimals); - event log_named_int(string key, int256 val); - event log_named_uint(string key, uint256 val); - event log_named_bytes(string key, bytes val); - event log_named_string(string key, string val); - - event log_array(uint256[] val); - event log_array(int256[] val); - event log_array(address[] val); - event log_named_array(string key, uint256[] val); - event log_named_array(string key, int256[] val); - event log_named_array(string key, address[] val); - - bool private _failed; - - function failed() public view returns (bool) { - if (_failed) { - return _failed; - } else { - return vm.load(address(vm), bytes32("failed")) != bytes32(0); - } - } - - function fail() internal virtual { - vm.store(address(vm), bytes32("failed"), bytes32(uint256(1))); - _failed = true; - } - - function assertTrue(bool data) internal pure virtual { - vm.assertTrue(data); - } - - function assertTrue(bool data, string memory err) internal pure virtual { - vm.assertTrue(data, err); - } - - function assertFalse(bool data) internal pure virtual { - vm.assertFalse(data); - } - - function assertFalse(bool data, string memory err) internal pure virtual { - vm.assertFalse(data, err); - } - - function assertEq(bool left, bool right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bool left, bool right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(uint256 left, uint256 right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(uint256 left, uint256 right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEqDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertEqDecimal(left, right, decimals); - } - - function assertEqDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertEqDecimal(left, right, decimals, err); - } - - function assertEq(int256 left, int256 right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(int256 left, int256 right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEqDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertEqDecimal(left, right, decimals); - } - - function assertEqDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertEqDecimal(left, right, decimals, err); - } - - function assertEq(address left, address right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(address left, address right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bytes32 left, bytes32 right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bytes32 left, bytes32 right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq32(bytes32 left, bytes32 right) internal pure virtual { - assertEq(left, right); - } - - function assertEq32(bytes32 left, bytes32 right, string memory err) internal pure virtual { - assertEq(left, right, err); - } - - function assertEq(string memory left, string memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(string memory left, string memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bytes memory left, bytes memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bytes memory left, bytes memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bool[] memory left, bool[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bool[] memory left, bool[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(uint256[] memory left, uint256[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(uint256[] memory left, uint256[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(int256[] memory left, int256[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(int256[] memory left, int256[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(address[] memory left, address[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(address[] memory left, address[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bytes32[] memory left, bytes32[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bytes32[] memory left, bytes32[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(string[] memory left, string[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(string[] memory left, string[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - function assertEq(bytes[] memory left, bytes[] memory right) internal pure virtual { - vm.assertEq(left, right); - } - - function assertEq(bytes[] memory left, bytes[] memory right, string memory err) internal pure virtual { - vm.assertEq(left, right, err); - } - - // Legacy helper - function assertEqUint(uint256 left, uint256 right) internal pure virtual { - assertEq(left, right); - } - - function assertNotEq(bool left, bool right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bool left, bool right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(uint256 left, uint256 right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(uint256 left, uint256 right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEqDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertNotEqDecimal(left, right, decimals); - } - - function assertNotEqDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) - internal - pure - virtual - { - vm.assertNotEqDecimal(left, right, decimals, err); - } - - function assertNotEq(int256 left, int256 right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(int256 left, int256 right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEqDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertNotEqDecimal(left, right, decimals); - } - - function assertNotEqDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertNotEqDecimal(left, right, decimals, err); - } - - function assertNotEq(address left, address right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(address left, address right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bytes32 left, bytes32 right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bytes32 left, bytes32 right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq32(bytes32 left, bytes32 right) internal pure virtual { - assertNotEq(left, right); - } - - function assertNotEq32(bytes32 left, bytes32 right, string memory err) internal pure virtual { - assertNotEq(left, right, err); - } - - function assertNotEq(string memory left, string memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(string memory left, string memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bytes memory left, bytes memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bytes memory left, bytes memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bool[] memory left, bool[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bool[] memory left, bool[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(uint256[] memory left, uint256[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(uint256[] memory left, uint256[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(int256[] memory left, int256[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(int256[] memory left, int256[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(address[] memory left, address[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(address[] memory left, address[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bytes32[] memory left, bytes32[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bytes32[] memory left, bytes32[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(string[] memory left, string[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(string[] memory left, string[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertNotEq(bytes[] memory left, bytes[] memory right) internal pure virtual { - vm.assertNotEq(left, right); - } - - function assertNotEq(bytes[] memory left, bytes[] memory right, string memory err) internal pure virtual { - vm.assertNotEq(left, right, err); - } - - function assertLt(uint256 left, uint256 right) internal pure virtual { - vm.assertLt(left, right); - } - - function assertLt(uint256 left, uint256 right, string memory err) internal pure virtual { - vm.assertLt(left, right, err); - } - - function assertLtDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertLtDecimal(left, right, decimals); - } - - function assertLtDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertLtDecimal(left, right, decimals, err); - } - - function assertLt(int256 left, int256 right) internal pure virtual { - vm.assertLt(left, right); - } - - function assertLt(int256 left, int256 right, string memory err) internal pure virtual { - vm.assertLt(left, right, err); - } - - function assertLtDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertLtDecimal(left, right, decimals); - } - - function assertLtDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertLtDecimal(left, right, decimals, err); - } - - function assertGt(uint256 left, uint256 right) internal pure virtual { - vm.assertGt(left, right); - } - - function assertGt(uint256 left, uint256 right, string memory err) internal pure virtual { - vm.assertGt(left, right, err); - } - - function assertGtDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertGtDecimal(left, right, decimals); - } - - function assertGtDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertGtDecimal(left, right, decimals, err); - } - - function assertGt(int256 left, int256 right) internal pure virtual { - vm.assertGt(left, right); - } - - function assertGt(int256 left, int256 right, string memory err) internal pure virtual { - vm.assertGt(left, right, err); - } - - function assertGtDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertGtDecimal(left, right, decimals); - } - - function assertGtDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertGtDecimal(left, right, decimals, err); - } - - function assertLe(uint256 left, uint256 right) internal pure virtual { - vm.assertLe(left, right); - } - - function assertLe(uint256 left, uint256 right, string memory err) internal pure virtual { - vm.assertLe(left, right, err); - } - - function assertLeDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertLeDecimal(left, right, decimals); - } - - function assertLeDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertLeDecimal(left, right, decimals, err); - } - - function assertLe(int256 left, int256 right) internal pure virtual { - vm.assertLe(left, right); - } - - function assertLe(int256 left, int256 right, string memory err) internal pure virtual { - vm.assertLe(left, right, err); - } - - function assertLeDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertLeDecimal(left, right, decimals); - } - - function assertLeDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertLeDecimal(left, right, decimals, err); - } - - function assertGe(uint256 left, uint256 right) internal pure virtual { - vm.assertGe(left, right); - } - - function assertGe(uint256 left, uint256 right, string memory err) internal pure virtual { - vm.assertGe(left, right, err); - } - - function assertGeDecimal(uint256 left, uint256 right, uint256 decimals) internal pure virtual { - vm.assertGeDecimal(left, right, decimals); - } - - function assertGeDecimal(uint256 left, uint256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertGeDecimal(left, right, decimals, err); - } - - function assertGe(int256 left, int256 right) internal pure virtual { - vm.assertGe(left, right); - } - - function assertGe(int256 left, int256 right, string memory err) internal pure virtual { - vm.assertGe(left, right, err); - } - - function assertGeDecimal(int256 left, int256 right, uint256 decimals) internal pure virtual { - vm.assertGeDecimal(left, right, decimals); - } - - function assertGeDecimal(int256 left, int256 right, uint256 decimals, string memory err) internal pure virtual { - vm.assertGeDecimal(left, right, decimals, err); - } - - function assertApproxEqAbs(uint256 left, uint256 right, uint256 maxDelta) internal pure virtual { - vm.assertApproxEqAbs(left, right, maxDelta); - } - - function assertApproxEqAbs(uint256 left, uint256 right, uint256 maxDelta, string memory err) - internal - pure - virtual - { - vm.assertApproxEqAbs(left, right, maxDelta, err); - } - - function assertApproxEqAbsDecimal(uint256 left, uint256 right, uint256 maxDelta, uint256 decimals) - internal - pure - virtual - { - vm.assertApproxEqAbsDecimal(left, right, maxDelta, decimals); - } - - function assertApproxEqAbsDecimal( - uint256 left, - uint256 right, - uint256 maxDelta, - uint256 decimals, - string memory err - ) internal pure virtual { - vm.assertApproxEqAbsDecimal(left, right, maxDelta, decimals, err); - } - - function assertApproxEqAbs(int256 left, int256 right, uint256 maxDelta) internal pure virtual { - vm.assertApproxEqAbs(left, right, maxDelta); - } - - function assertApproxEqAbs(int256 left, int256 right, uint256 maxDelta, string memory err) internal pure virtual { - vm.assertApproxEqAbs(left, right, maxDelta, err); - } - - function assertApproxEqAbsDecimal(int256 left, int256 right, uint256 maxDelta, uint256 decimals) - internal - pure - virtual - { - vm.assertApproxEqAbsDecimal(left, right, maxDelta, decimals); - } - - function assertApproxEqAbsDecimal(int256 left, int256 right, uint256 maxDelta, uint256 decimals, string memory err) - internal - pure - virtual - { - vm.assertApproxEqAbsDecimal(left, right, maxDelta, decimals, err); - } - - function assertApproxEqRel( - uint256 left, - uint256 right, - uint256 maxPercentDelta // An 18 decimal fixed point number, where 1e18 == 100% - ) internal pure virtual { - vm.assertApproxEqRel(left, right, maxPercentDelta); - } - - function assertApproxEqRel( - uint256 left, - uint256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - string memory err - ) internal pure virtual { - vm.assertApproxEqRel(left, right, maxPercentDelta, err); - } - - function assertApproxEqRelDecimal( - uint256 left, - uint256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - uint256 decimals - ) internal pure virtual { - vm.assertApproxEqRelDecimal(left, right, maxPercentDelta, decimals); - } - - function assertApproxEqRelDecimal( - uint256 left, - uint256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - uint256 decimals, - string memory err - ) internal pure virtual { - vm.assertApproxEqRelDecimal(left, right, maxPercentDelta, decimals, err); - } - - function assertApproxEqRel(int256 left, int256 right, uint256 maxPercentDelta) internal pure virtual { - vm.assertApproxEqRel(left, right, maxPercentDelta); - } - - function assertApproxEqRel( - int256 left, - int256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - string memory err - ) internal pure virtual { - vm.assertApproxEqRel(left, right, maxPercentDelta, err); - } - - function assertApproxEqRelDecimal( - int256 left, - int256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - uint256 decimals - ) internal pure virtual { - vm.assertApproxEqRelDecimal(left, right, maxPercentDelta, decimals); - } - - function assertApproxEqRelDecimal( - int256 left, - int256 right, - uint256 maxPercentDelta, // An 18 decimal fixed point number, where 1e18 == 100% - uint256 decimals, - string memory err - ) internal pure virtual { - vm.assertApproxEqRelDecimal(left, right, maxPercentDelta, decimals, err); - } - - // Inherited from DSTest, not used but kept for backwards-compatibility - function checkEq0(bytes memory left, bytes memory right) internal pure returns (bool) { - return keccak256(left) == keccak256(right); - } - - function assertEq0(bytes memory left, bytes memory right) internal pure virtual { - assertEq(left, right); - } - - function assertEq0(bytes memory left, bytes memory right, string memory err) internal pure virtual { - assertEq(left, right, err); - } - - function assertNotEq0(bytes memory left, bytes memory right) internal pure virtual { - assertNotEq(left, right); - } - - function assertNotEq0(bytes memory left, bytes memory right, string memory err) internal pure virtual { - assertNotEq(left, right, err); - } - - function assertEqCall(address target, bytes memory callDataA, bytes memory callDataB) internal virtual { - assertEqCall(target, callDataA, target, callDataB, true); - } - - function assertEqCall(address targetA, bytes memory callDataA, address targetB, bytes memory callDataB) - internal - virtual - { - assertEqCall(targetA, callDataA, targetB, callDataB, true); - } - - function assertEqCall(address target, bytes memory callDataA, bytes memory callDataB, bool strictRevertData) - internal - virtual - { - assertEqCall(target, callDataA, target, callDataB, strictRevertData); - } - - function assertEqCall( - address targetA, - bytes memory callDataA, - address targetB, - bytes memory callDataB, - bool strictRevertData - ) internal virtual { - (bool successA, bytes memory returnDataA) = address(targetA).call(callDataA); - (bool successB, bytes memory returnDataB) = address(targetB).call(callDataB); - - if (successA && successB) { - assertEq(returnDataA, returnDataB, "Call return data does not match"); - } - - if (!successA && !successB && strictRevertData) { - assertEq(returnDataA, returnDataB, "Call revert data does not match"); - } - - if (!successA && successB) { - emit log("Error: Calls were not equal"); - emit log_named_bytes(" Left call revert data", returnDataA); - emit log_named_bytes(" Right call return data", returnDataB); - revert("assertion failed"); - } - - if (successA && !successB) { - emit log("Error: Calls were not equal"); - emit log_named_bytes(" Left call return data", returnDataA); - emit log_named_bytes(" Right call revert data", returnDataB); - revert("assertion failed"); - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdChains.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdChains.sol deleted file mode 100644 index 9ca1b82d9e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdChains.sol +++ /dev/null @@ -1,263 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -import {VmSafe} from "./Vm.sol"; - -/** - * StdChains provides information about EVM compatible chains that can be used in scripts/tests. - * For each chain, the chain's name, chain ID, and a default RPC URL are provided. Chains are - * identified by their alias, which is the same as the alias in the `[rpc_endpoints]` section of - * the `foundry.toml` file. For best UX, ensure the alias in the `foundry.toml` file match the - * alias used in this contract, which can be found as the first argument to the - * `setChainWithDefaultRpcUrl` call in the `initializeStdChains` function. - * - * There are two main ways to use this contract: - * 1. Set a chain with `setChain(string memory chainAlias, ChainData memory chain)` or - * `setChain(string memory chainAlias, Chain memory chain)` - * 2. Get a chain with `getChain(string memory chainAlias)` or `getChain(uint256 chainId)`. - * - * The first time either of those are used, chains are initialized with the default set of RPC URLs. - * This is done in `initializeStdChains`, which uses `setChainWithDefaultRpcUrl`. Defaults are recorded in - * `defaultRpcUrls`. - * - * The `setChain` function is straightforward, and it simply saves off the given chain data. - * - * The `getChain` methods use `getChainWithUpdatedRpcUrl` to return a chain. For example, let's say - * we want to retrieve the RPC URL for `mainnet`: - * - If you have specified data with `setChain`, it will return that. - * - If you have configured a mainnet RPC URL in `foundry.toml`, it will return the URL, provided it - * is valid (e.g. a URL is specified, or an environment variable is given and exists). - * - If neither of the above conditions is met, the default data is returned. - * - * Summarizing the above, the prioritization hierarchy is `setChain` -> `foundry.toml` -> environment variable -> defaults. - */ -abstract contract StdChains { - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - bool private stdChainsInitialized; - - struct ChainData { - string name; - uint256 chainId; - string rpcUrl; - } - - struct Chain { - // The chain name. - string name; - // The chain's Chain ID. - uint256 chainId; - // The chain's alias. (i.e. what gets specified in `foundry.toml`). - string chainAlias; - // A default RPC endpoint for this chain. - // NOTE: This default RPC URL is included for convenience to facilitate quick tests and - // experimentation. Do not use this RPC URL for production test suites, CI, or other heavy - // usage as you will be throttled and this is a disservice to others who need this endpoint. - string rpcUrl; - } - - // Maps from the chain's alias (matching the alias in the `foundry.toml` file) to chain data. - mapping(string => Chain) private chains; - // Maps from the chain's alias to it's default RPC URL. - mapping(string => string) private defaultRpcUrls; - // Maps from a chain ID to it's alias. - mapping(uint256 => string) private idToAlias; - - bool private fallbackToDefaultRpcUrls = true; - - // The RPC URL will be fetched from config or defaultRpcUrls if possible. - function getChain(string memory chainAlias) internal virtual returns (Chain memory chain) { - require(bytes(chainAlias).length != 0, "StdChains getChain(string): Chain alias cannot be the empty string."); - - initializeStdChains(); - chain = chains[chainAlias]; - require( - chain.chainId != 0, - string(abi.encodePacked("StdChains getChain(string): Chain with alias \"", chainAlias, "\" not found.")) - ); - - chain = getChainWithUpdatedRpcUrl(chainAlias, chain); - } - - function getChain(uint256 chainId) internal virtual returns (Chain memory chain) { - require(chainId != 0, "StdChains getChain(uint256): Chain ID cannot be 0."); - initializeStdChains(); - string memory chainAlias = idToAlias[chainId]; - - chain = chains[chainAlias]; - - require( - chain.chainId != 0, - string(abi.encodePacked("StdChains getChain(uint256): Chain with ID ", vm.toString(chainId), " not found.")) - ); - - chain = getChainWithUpdatedRpcUrl(chainAlias, chain); - } - - // set chain info, with priority to argument's rpcUrl field. - function setChain(string memory chainAlias, ChainData memory chain) internal virtual { - require( - bytes(chainAlias).length != 0, - "StdChains setChain(string,ChainData): Chain alias cannot be the empty string." - ); - - require(chain.chainId != 0, "StdChains setChain(string,ChainData): Chain ID cannot be 0."); - - initializeStdChains(); - string memory foundAlias = idToAlias[chain.chainId]; - - require( - bytes(foundAlias).length == 0 || keccak256(bytes(foundAlias)) == keccak256(bytes(chainAlias)), - string( - abi.encodePacked( - "StdChains setChain(string,ChainData): Chain ID ", - vm.toString(chain.chainId), - " already used by \"", - foundAlias, - "\"." - ) - ) - ); - - uint256 oldChainId = chains[chainAlias].chainId; - delete idToAlias[oldChainId]; - - chains[chainAlias] = - Chain({name: chain.name, chainId: chain.chainId, chainAlias: chainAlias, rpcUrl: chain.rpcUrl}); - idToAlias[chain.chainId] = chainAlias; - } - - // set chain info, with priority to argument's rpcUrl field. - function setChain(string memory chainAlias, Chain memory chain) internal virtual { - setChain(chainAlias, ChainData({name: chain.name, chainId: chain.chainId, rpcUrl: chain.rpcUrl})); - } - - function _toUpper(string memory str) private pure returns (string memory) { - bytes memory strb = bytes(str); - bytes memory copy = new bytes(strb.length); - for (uint256 i = 0; i < strb.length; i++) { - bytes1 b = strb[i]; - if (b >= 0x61 && b <= 0x7A) { - copy[i] = bytes1(uint8(b) - 32); - } else { - copy[i] = b; - } - } - return string(copy); - } - - // lookup rpcUrl, in descending order of priority: - // current -> config (foundry.toml) -> environment variable -> default - function getChainWithUpdatedRpcUrl(string memory chainAlias, Chain memory chain) - private - view - returns (Chain memory) - { - if (bytes(chain.rpcUrl).length == 0) { - try vm.rpcUrl(chainAlias) returns (string memory configRpcUrl) { - chain.rpcUrl = configRpcUrl; - } catch (bytes memory err) { - string memory envName = string(abi.encodePacked(_toUpper(chainAlias), "_RPC_URL")); - if (fallbackToDefaultRpcUrls) { - chain.rpcUrl = vm.envOr(envName, defaultRpcUrls[chainAlias]); - } else { - chain.rpcUrl = vm.envString(envName); - } - // Distinguish 'not found' from 'cannot read' - // The upstream error thrown by forge for failing cheats changed so we check both the old and new versions - bytes memory oldNotFoundError = - abi.encodeWithSignature("CheatCodeError", string(abi.encodePacked("invalid rpc url ", chainAlias))); - bytes memory newNotFoundError = abi.encodeWithSignature( - "CheatcodeError(string)", string(abi.encodePacked("invalid rpc url: ", chainAlias)) - ); - bytes32 errHash = keccak256(err); - if ( - (errHash != keccak256(oldNotFoundError) && errHash != keccak256(newNotFoundError)) - || bytes(chain.rpcUrl).length == 0 - ) { - /// @solidity memory-safe-assembly - assembly { - revert(add(32, err), mload(err)) - } - } - } - } - return chain; - } - - function setFallbackToDefaultRpcUrls(bool useDefault) internal { - fallbackToDefaultRpcUrls = useDefault; - } - - function initializeStdChains() private { - if (stdChainsInitialized) return; - - stdChainsInitialized = true; - - // If adding an RPC here, make sure to test the default RPC URL in `test_Rpcs` in `StdChains.t.sol` - setChainWithDefaultRpcUrl("anvil", ChainData("Anvil", 31337, "http://127.0.0.1:8545")); - setChainWithDefaultRpcUrl( - "mainnet", ChainData("Mainnet", 1, "https://eth-mainnet.alchemyapi.io/v2/pwc5rmJhrdoaSEfimoKEmsvOjKSmPDrP") - ); - setChainWithDefaultRpcUrl( - "sepolia", ChainData("Sepolia", 11155111, "https://sepolia.infura.io/v3/b9794ad1ddf84dfb8c34d6bb5dca2001") - ); - setChainWithDefaultRpcUrl("holesky", ChainData("Holesky", 17000, "https://rpc.holesky.ethpandaops.io")); - setChainWithDefaultRpcUrl("optimism", ChainData("Optimism", 10, "https://mainnet.optimism.io")); - setChainWithDefaultRpcUrl( - "optimism_sepolia", ChainData("Optimism Sepolia", 11155420, "https://sepolia.optimism.io") - ); - setChainWithDefaultRpcUrl("arbitrum_one", ChainData("Arbitrum One", 42161, "https://arb1.arbitrum.io/rpc")); - setChainWithDefaultRpcUrl( - "arbitrum_one_sepolia", ChainData("Arbitrum One Sepolia", 421614, "https://sepolia-rollup.arbitrum.io/rpc") - ); - setChainWithDefaultRpcUrl("arbitrum_nova", ChainData("Arbitrum Nova", 42170, "https://nova.arbitrum.io/rpc")); - setChainWithDefaultRpcUrl("polygon", ChainData("Polygon", 137, "https://polygon-rpc.com")); - setChainWithDefaultRpcUrl( - "polygon_amoy", ChainData("Polygon Amoy", 80002, "https://rpc-amoy.polygon.technology") - ); - setChainWithDefaultRpcUrl("avalanche", ChainData("Avalanche", 43114, "https://api.avax.network/ext/bc/C/rpc")); - setChainWithDefaultRpcUrl( - "avalanche_fuji", ChainData("Avalanche Fuji", 43113, "https://api.avax-test.network/ext/bc/C/rpc") - ); - setChainWithDefaultRpcUrl( - "bnb_smart_chain", ChainData("BNB Smart Chain", 56, "https://bsc-dataseed1.binance.org") - ); - setChainWithDefaultRpcUrl( - "bnb_smart_chain_testnet", - ChainData("BNB Smart Chain Testnet", 97, "https://rpc.ankr.com/bsc_testnet_chapel") - ); - setChainWithDefaultRpcUrl("gnosis_chain", ChainData("Gnosis Chain", 100, "https://rpc.gnosischain.com")); - setChainWithDefaultRpcUrl("moonbeam", ChainData("Moonbeam", 1284, "https://rpc.api.moonbeam.network")); - setChainWithDefaultRpcUrl( - "moonriver", ChainData("Moonriver", 1285, "https://rpc.api.moonriver.moonbeam.network") - ); - setChainWithDefaultRpcUrl("moonbase", ChainData("Moonbase", 1287, "https://rpc.testnet.moonbeam.network")); - setChainWithDefaultRpcUrl("base_sepolia", ChainData("Base Sepolia", 84532, "https://sepolia.base.org")); - setChainWithDefaultRpcUrl("base", ChainData("Base", 8453, "https://mainnet.base.org")); - setChainWithDefaultRpcUrl("blast_sepolia", ChainData("Blast Sepolia", 168587773, "https://sepolia.blast.io")); - setChainWithDefaultRpcUrl("blast", ChainData("Blast", 81457, "https://rpc.blast.io")); - setChainWithDefaultRpcUrl("fantom_opera", ChainData("Fantom Opera", 250, "https://rpc.ankr.com/fantom/")); - setChainWithDefaultRpcUrl( - "fantom_opera_testnet", ChainData("Fantom Opera Testnet", 4002, "https://rpc.ankr.com/fantom_testnet/") - ); - setChainWithDefaultRpcUrl("fraxtal", ChainData("Fraxtal", 252, "https://rpc.frax.com")); - setChainWithDefaultRpcUrl("fraxtal_testnet", ChainData("Fraxtal Testnet", 2522, "https://rpc.testnet.frax.com")); - setChainWithDefaultRpcUrl( - "berachain_bartio_testnet", ChainData("Berachain bArtio Testnet", 80084, "https://bartio.rpc.berachain.com") - ); - setChainWithDefaultRpcUrl("flare", ChainData("Flare", 14, "https://flare-api.flare.network/ext/C/rpc")); - setChainWithDefaultRpcUrl( - "flare_coston2", ChainData("Flare Coston2", 114, "https://coston2-api.flare.network/ext/C/rpc") - ); - } - - // set chain info, with priority to chainAlias' rpc url in foundry.toml - function setChainWithDefaultRpcUrl(string memory chainAlias, ChainData memory chain) private { - string memory rpcUrl = chain.rpcUrl; - defaultRpcUrls[chainAlias] = rpcUrl; - chain.rpcUrl = ""; - setChain(chainAlias, chain); - chain.rpcUrl = rpcUrl; // restore argument - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdCheats.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdCheats.sol deleted file mode 100644 index 95850d118e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdCheats.sol +++ /dev/null @@ -1,817 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -import {StdStorage, stdStorage} from "./StdStorage.sol"; -import {console2} from "./console2.sol"; -import {Vm} from "./Vm.sol"; - -abstract contract StdCheatsSafe { - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - - uint256 private constant UINT256_MAX = - 115792089237316195423570985008687907853269984665640564039457584007913129639935; - - bool private gasMeteringOff; - - // Data structures to parse Transaction objects from the broadcast artifact - // that conform to EIP1559. The Raw structs is what is parsed from the JSON - // and then converted to the one that is used by the user for better UX. - - struct RawTx1559 { - string[] arguments; - address contractAddress; - string contractName; - // json value name = function - string functionSig; - bytes32 hash; - // json value name = tx - RawTx1559Detail txDetail; - // json value name = type - string opcode; - } - - struct RawTx1559Detail { - AccessList[] accessList; - bytes data; - address from; - bytes gas; - bytes nonce; - address to; - bytes txType; - bytes value; - } - - struct Tx1559 { - string[] arguments; - address contractAddress; - string contractName; - string functionSig; - bytes32 hash; - Tx1559Detail txDetail; - string opcode; - } - - struct Tx1559Detail { - AccessList[] accessList; - bytes data; - address from; - uint256 gas; - uint256 nonce; - address to; - uint256 txType; - uint256 value; - } - - // Data structures to parse Transaction objects from the broadcast artifact - // that DO NOT conform to EIP1559. The Raw structs is what is parsed from the JSON - // and then converted to the one that is used by the user for better UX. - - struct TxLegacy { - string[] arguments; - address contractAddress; - string contractName; - string functionSig; - string hash; - string opcode; - TxDetailLegacy transaction; - } - - struct TxDetailLegacy { - AccessList[] accessList; - uint256 chainId; - bytes data; - address from; - uint256 gas; - uint256 gasPrice; - bytes32 hash; - uint256 nonce; - bytes1 opcode; - bytes32 r; - bytes32 s; - uint256 txType; - address to; - uint8 v; - uint256 value; - } - - struct AccessList { - address accessAddress; - bytes32[] storageKeys; - } - - // Data structures to parse Receipt objects from the broadcast artifact. - // The Raw structs is what is parsed from the JSON - // and then converted to the one that is used by the user for better UX. - - struct RawReceipt { - bytes32 blockHash; - bytes blockNumber; - address contractAddress; - bytes cumulativeGasUsed; - bytes effectiveGasPrice; - address from; - bytes gasUsed; - RawReceiptLog[] logs; - bytes logsBloom; - bytes status; - address to; - bytes32 transactionHash; - bytes transactionIndex; - } - - struct Receipt { - bytes32 blockHash; - uint256 blockNumber; - address contractAddress; - uint256 cumulativeGasUsed; - uint256 effectiveGasPrice; - address from; - uint256 gasUsed; - ReceiptLog[] logs; - bytes logsBloom; - uint256 status; - address to; - bytes32 transactionHash; - uint256 transactionIndex; - } - - // Data structures to parse the entire broadcast artifact, assuming the - // transactions conform to EIP1559. - - struct EIP1559ScriptArtifact { - string[] libraries; - string path; - string[] pending; - Receipt[] receipts; - uint256 timestamp; - Tx1559[] transactions; - TxReturn[] txReturns; - } - - struct RawEIP1559ScriptArtifact { - string[] libraries; - string path; - string[] pending; - RawReceipt[] receipts; - TxReturn[] txReturns; - uint256 timestamp; - RawTx1559[] transactions; - } - - struct RawReceiptLog { - // json value = address - address logAddress; - bytes32 blockHash; - bytes blockNumber; - bytes data; - bytes logIndex; - bool removed; - bytes32[] topics; - bytes32 transactionHash; - bytes transactionIndex; - bytes transactionLogIndex; - } - - struct ReceiptLog { - // json value = address - address logAddress; - bytes32 blockHash; - uint256 blockNumber; - bytes data; - uint256 logIndex; - bytes32[] topics; - uint256 transactionIndex; - uint256 transactionLogIndex; - bool removed; - } - - struct TxReturn { - string internalType; - string value; - } - - struct Account { - address addr; - uint256 key; - } - - enum AddressType { - Payable, - NonPayable, - ZeroAddress, - Precompile, - ForgeAddress - } - - // Checks that `addr` is not blacklisted by token contracts that have a blacklist. - function assumeNotBlacklisted(address token, address addr) internal view virtual { - // Nothing to check if `token` is not a contract. - uint256 tokenCodeSize; - assembly { - tokenCodeSize := extcodesize(token) - } - require(tokenCodeSize > 0, "StdCheats assumeNotBlacklisted(address,address): Token address is not a contract."); - - bool success; - bytes memory returnData; - - // 4-byte selector for `isBlacklisted(address)`, used by USDC. - (success, returnData) = token.staticcall(abi.encodeWithSelector(0xfe575a87, addr)); - vm.assume(!success || abi.decode(returnData, (bool)) == false); - - // 4-byte selector for `isBlackListed(address)`, used by USDT. - (success, returnData) = token.staticcall(abi.encodeWithSelector(0xe47d6060, addr)); - vm.assume(!success || abi.decode(returnData, (bool)) == false); - } - - // Checks that `addr` is not blacklisted by token contracts that have a blacklist. - // This is identical to `assumeNotBlacklisted(address,address)` but with a different name, for - // backwards compatibility, since this name was used in the original PR which already has - // a release. This function can be removed in a future release once we want a breaking change. - function assumeNoBlacklisted(address token, address addr) internal view virtual { - assumeNotBlacklisted(token, addr); - } - - function assumeAddressIsNot(address addr, AddressType addressType) internal virtual { - if (addressType == AddressType.Payable) { - assumeNotPayable(addr); - } else if (addressType == AddressType.NonPayable) { - assumePayable(addr); - } else if (addressType == AddressType.ZeroAddress) { - assumeNotZeroAddress(addr); - } else if (addressType == AddressType.Precompile) { - assumeNotPrecompile(addr); - } else if (addressType == AddressType.ForgeAddress) { - assumeNotForgeAddress(addr); - } - } - - function assumeAddressIsNot(address addr, AddressType addressType1, AddressType addressType2) internal virtual { - assumeAddressIsNot(addr, addressType1); - assumeAddressIsNot(addr, addressType2); - } - - function assumeAddressIsNot( - address addr, - AddressType addressType1, - AddressType addressType2, - AddressType addressType3 - ) internal virtual { - assumeAddressIsNot(addr, addressType1); - assumeAddressIsNot(addr, addressType2); - assumeAddressIsNot(addr, addressType3); - } - - function assumeAddressIsNot( - address addr, - AddressType addressType1, - AddressType addressType2, - AddressType addressType3, - AddressType addressType4 - ) internal virtual { - assumeAddressIsNot(addr, addressType1); - assumeAddressIsNot(addr, addressType2); - assumeAddressIsNot(addr, addressType3); - assumeAddressIsNot(addr, addressType4); - } - - // This function checks whether an address, `addr`, is payable. It works by sending 1 wei to - // `addr` and checking the `success` return value. - // NOTE: This function may result in state changes depending on the fallback/receive logic - // implemented by `addr`, which should be taken into account when this function is used. - function _isPayable(address addr) private returns (bool) { - require( - addr.balance < UINT256_MAX, - "StdCheats _isPayable(address): Balance equals max uint256, so it cannot receive any more funds" - ); - uint256 origBalanceTest = address(this).balance; - uint256 origBalanceAddr = address(addr).balance; - - vm.deal(address(this), 1); - (bool success,) = payable(addr).call{value: 1}(""); - - // reset balances - vm.deal(address(this), origBalanceTest); - vm.deal(addr, origBalanceAddr); - - return success; - } - - // NOTE: This function may result in state changes depending on the fallback/receive logic - // implemented by `addr`, which should be taken into account when this function is used. See the - // `_isPayable` method for more information. - function assumePayable(address addr) internal virtual { - vm.assume(_isPayable(addr)); - } - - function assumeNotPayable(address addr) internal virtual { - vm.assume(!_isPayable(addr)); - } - - function assumeNotZeroAddress(address addr) internal pure virtual { - vm.assume(addr != address(0)); - } - - function assumeNotPrecompile(address addr) internal pure virtual { - assumeNotPrecompile(addr, _pureChainId()); - } - - function assumeNotPrecompile(address addr, uint256 chainId) internal pure virtual { - // Note: For some chains like Optimism these are technically predeploys (i.e. bytecode placed at a specific - // address), but the same rationale for excluding them applies so we include those too. - - // These are reserved by Ethereum and may be on all EVM-compatible chains. - vm.assume(addr < address(0x1) || addr > address(0xff)); - - // forgefmt: disable-start - if (chainId == 10 || chainId == 420) { - // https://github.com/ethereum-optimism/optimism/blob/eaa371a0184b56b7ca6d9eb9cb0a2b78b2ccd864/op-bindings/predeploys/addresses.go#L6-L21 - vm.assume(addr < address(0x4200000000000000000000000000000000000000) || addr > address(0x4200000000000000000000000000000000000800)); - } else if (chainId == 42161 || chainId == 421613) { - // https://developer.arbitrum.io/useful-addresses#arbitrum-precompiles-l2-same-on-all-arb-chains - vm.assume(addr < address(0x0000000000000000000000000000000000000064) || addr > address(0x0000000000000000000000000000000000000068)); - } else if (chainId == 43114 || chainId == 43113) { - // https://github.com/ava-labs/subnet-evm/blob/47c03fd007ecaa6de2c52ea081596e0a88401f58/precompile/params.go#L18-L59 - vm.assume(addr < address(0x0100000000000000000000000000000000000000) || addr > address(0x01000000000000000000000000000000000000ff)); - vm.assume(addr < address(0x0200000000000000000000000000000000000000) || addr > address(0x02000000000000000000000000000000000000FF)); - vm.assume(addr < address(0x0300000000000000000000000000000000000000) || addr > address(0x03000000000000000000000000000000000000Ff)); - } - // forgefmt: disable-end - } - - function assumeNotForgeAddress(address addr) internal pure virtual { - // vm, console, and Create2Deployer addresses - vm.assume( - addr != address(vm) && addr != 0x000000000000000000636F6e736F6c652e6c6f67 - && addr != 0x4e59b44847b379578588920cA78FbF26c0B4956C - ); - } - - function readEIP1559ScriptArtifact(string memory path) - internal - view - virtual - returns (EIP1559ScriptArtifact memory) - { - string memory data = vm.readFile(path); - bytes memory parsedData = vm.parseJson(data); - RawEIP1559ScriptArtifact memory rawArtifact = abi.decode(parsedData, (RawEIP1559ScriptArtifact)); - EIP1559ScriptArtifact memory artifact; - artifact.libraries = rawArtifact.libraries; - artifact.path = rawArtifact.path; - artifact.timestamp = rawArtifact.timestamp; - artifact.pending = rawArtifact.pending; - artifact.txReturns = rawArtifact.txReturns; - artifact.receipts = rawToConvertedReceipts(rawArtifact.receipts); - artifact.transactions = rawToConvertedEIPTx1559s(rawArtifact.transactions); - return artifact; - } - - function rawToConvertedEIPTx1559s(RawTx1559[] memory rawTxs) internal pure virtual returns (Tx1559[] memory) { - Tx1559[] memory txs = new Tx1559[](rawTxs.length); - for (uint256 i; i < rawTxs.length; i++) { - txs[i] = rawToConvertedEIPTx1559(rawTxs[i]); - } - return txs; - } - - function rawToConvertedEIPTx1559(RawTx1559 memory rawTx) internal pure virtual returns (Tx1559 memory) { - Tx1559 memory transaction; - transaction.arguments = rawTx.arguments; - transaction.contractName = rawTx.contractName; - transaction.functionSig = rawTx.functionSig; - transaction.hash = rawTx.hash; - transaction.txDetail = rawToConvertedEIP1559Detail(rawTx.txDetail); - transaction.opcode = rawTx.opcode; - return transaction; - } - - function rawToConvertedEIP1559Detail(RawTx1559Detail memory rawDetail) - internal - pure - virtual - returns (Tx1559Detail memory) - { - Tx1559Detail memory txDetail; - txDetail.data = rawDetail.data; - txDetail.from = rawDetail.from; - txDetail.to = rawDetail.to; - txDetail.nonce = _bytesToUint(rawDetail.nonce); - txDetail.txType = _bytesToUint(rawDetail.txType); - txDetail.value = _bytesToUint(rawDetail.value); - txDetail.gas = _bytesToUint(rawDetail.gas); - txDetail.accessList = rawDetail.accessList; - return txDetail; - } - - function readTx1559s(string memory path) internal view virtual returns (Tx1559[] memory) { - string memory deployData = vm.readFile(path); - bytes memory parsedDeployData = vm.parseJson(deployData, ".transactions"); - RawTx1559[] memory rawTxs = abi.decode(parsedDeployData, (RawTx1559[])); - return rawToConvertedEIPTx1559s(rawTxs); - } - - function readTx1559(string memory path, uint256 index) internal view virtual returns (Tx1559 memory) { - string memory deployData = vm.readFile(path); - string memory key = string(abi.encodePacked(".transactions[", vm.toString(index), "]")); - bytes memory parsedDeployData = vm.parseJson(deployData, key); - RawTx1559 memory rawTx = abi.decode(parsedDeployData, (RawTx1559)); - return rawToConvertedEIPTx1559(rawTx); - } - - // Analogous to readTransactions, but for receipts. - function readReceipts(string memory path) internal view virtual returns (Receipt[] memory) { - string memory deployData = vm.readFile(path); - bytes memory parsedDeployData = vm.parseJson(deployData, ".receipts"); - RawReceipt[] memory rawReceipts = abi.decode(parsedDeployData, (RawReceipt[])); - return rawToConvertedReceipts(rawReceipts); - } - - function readReceipt(string memory path, uint256 index) internal view virtual returns (Receipt memory) { - string memory deployData = vm.readFile(path); - string memory key = string(abi.encodePacked(".receipts[", vm.toString(index), "]")); - bytes memory parsedDeployData = vm.parseJson(deployData, key); - RawReceipt memory rawReceipt = abi.decode(parsedDeployData, (RawReceipt)); - return rawToConvertedReceipt(rawReceipt); - } - - function rawToConvertedReceipts(RawReceipt[] memory rawReceipts) internal pure virtual returns (Receipt[] memory) { - Receipt[] memory receipts = new Receipt[](rawReceipts.length); - for (uint256 i; i < rawReceipts.length; i++) { - receipts[i] = rawToConvertedReceipt(rawReceipts[i]); - } - return receipts; - } - - function rawToConvertedReceipt(RawReceipt memory rawReceipt) internal pure virtual returns (Receipt memory) { - Receipt memory receipt; - receipt.blockHash = rawReceipt.blockHash; - receipt.to = rawReceipt.to; - receipt.from = rawReceipt.from; - receipt.contractAddress = rawReceipt.contractAddress; - receipt.effectiveGasPrice = _bytesToUint(rawReceipt.effectiveGasPrice); - receipt.cumulativeGasUsed = _bytesToUint(rawReceipt.cumulativeGasUsed); - receipt.gasUsed = _bytesToUint(rawReceipt.gasUsed); - receipt.status = _bytesToUint(rawReceipt.status); - receipt.transactionIndex = _bytesToUint(rawReceipt.transactionIndex); - receipt.blockNumber = _bytesToUint(rawReceipt.blockNumber); - receipt.logs = rawToConvertedReceiptLogs(rawReceipt.logs); - receipt.logsBloom = rawReceipt.logsBloom; - receipt.transactionHash = rawReceipt.transactionHash; - return receipt; - } - - function rawToConvertedReceiptLogs(RawReceiptLog[] memory rawLogs) - internal - pure - virtual - returns (ReceiptLog[] memory) - { - ReceiptLog[] memory logs = new ReceiptLog[](rawLogs.length); - for (uint256 i; i < rawLogs.length; i++) { - logs[i].logAddress = rawLogs[i].logAddress; - logs[i].blockHash = rawLogs[i].blockHash; - logs[i].blockNumber = _bytesToUint(rawLogs[i].blockNumber); - logs[i].data = rawLogs[i].data; - logs[i].logIndex = _bytesToUint(rawLogs[i].logIndex); - logs[i].topics = rawLogs[i].topics; - logs[i].transactionIndex = _bytesToUint(rawLogs[i].transactionIndex); - logs[i].transactionLogIndex = _bytesToUint(rawLogs[i].transactionLogIndex); - logs[i].removed = rawLogs[i].removed; - } - return logs; - } - - // Deploy a contract by fetching the contract bytecode from - // the artifacts directory - // e.g. `deployCode(code, abi.encode(arg1,arg2,arg3))` - function deployCode(string memory what, bytes memory args) internal virtual returns (address addr) { - bytes memory bytecode = abi.encodePacked(vm.getCode(what), args); - /// @solidity memory-safe-assembly - assembly { - addr := create(0, add(bytecode, 0x20), mload(bytecode)) - } - - require(addr != address(0), "StdCheats deployCode(string,bytes): Deployment failed."); - } - - function deployCode(string memory what) internal virtual returns (address addr) { - bytes memory bytecode = vm.getCode(what); - /// @solidity memory-safe-assembly - assembly { - addr := create(0, add(bytecode, 0x20), mload(bytecode)) - } - - require(addr != address(0), "StdCheats deployCode(string): Deployment failed."); - } - - /// @dev deploy contract with value on construction - function deployCode(string memory what, bytes memory args, uint256 val) internal virtual returns (address addr) { - bytes memory bytecode = abi.encodePacked(vm.getCode(what), args); - /// @solidity memory-safe-assembly - assembly { - addr := create(val, add(bytecode, 0x20), mload(bytecode)) - } - - require(addr != address(0), "StdCheats deployCode(string,bytes,uint256): Deployment failed."); - } - - function deployCode(string memory what, uint256 val) internal virtual returns (address addr) { - bytes memory bytecode = vm.getCode(what); - /// @solidity memory-safe-assembly - assembly { - addr := create(val, add(bytecode, 0x20), mload(bytecode)) - } - - require(addr != address(0), "StdCheats deployCode(string,uint256): Deployment failed."); - } - - // creates a labeled address and the corresponding private key - function makeAddrAndKey(string memory name) internal virtual returns (address addr, uint256 privateKey) { - privateKey = uint256(keccak256(abi.encodePacked(name))); - addr = vm.addr(privateKey); - vm.label(addr, name); - } - - // creates a labeled address - function makeAddr(string memory name) internal virtual returns (address addr) { - (addr,) = makeAddrAndKey(name); - } - - // Destroys an account immediately, sending the balance to beneficiary. - // Destroying means: balance will be zero, code will be empty, and nonce will be 0 - // This is similar to selfdestruct but not identical: selfdestruct destroys code and nonce - // only after tx ends, this will run immediately. - function destroyAccount(address who, address beneficiary) internal virtual { - uint256 currBalance = who.balance; - vm.etch(who, abi.encode()); - vm.deal(who, 0); - vm.resetNonce(who); - - uint256 beneficiaryBalance = beneficiary.balance; - vm.deal(beneficiary, currBalance + beneficiaryBalance); - } - - // creates a struct containing both a labeled address and the corresponding private key - function makeAccount(string memory name) internal virtual returns (Account memory account) { - (account.addr, account.key) = makeAddrAndKey(name); - } - - function deriveRememberKey(string memory mnemonic, uint32 index) - internal - virtual - returns (address who, uint256 privateKey) - { - privateKey = vm.deriveKey(mnemonic, index); - who = vm.rememberKey(privateKey); - } - - function _bytesToUint(bytes memory b) private pure returns (uint256) { - require(b.length <= 32, "StdCheats _bytesToUint(bytes): Bytes length exceeds 32."); - return abi.decode(abi.encodePacked(new bytes(32 - b.length), b), (uint256)); - } - - function isFork() internal view virtual returns (bool status) { - try vm.activeFork() { - status = true; - } catch (bytes memory) {} - } - - modifier skipWhenForking() { - if (!isFork()) { - _; - } - } - - modifier skipWhenNotForking() { - if (isFork()) { - _; - } - } - - modifier noGasMetering() { - vm.pauseGasMetering(); - // To prevent turning gas monitoring back on with nested functions that use this modifier, - // we check if gasMetering started in the off position. If it did, we don't want to turn - // it back on until we exit the top level function that used the modifier - // - // i.e. funcA() noGasMetering { funcB() }, where funcB has noGasMetering as well. - // funcA will have `gasStartedOff` as false, funcB will have it as true, - // so we only turn metering back on at the end of the funcA - bool gasStartedOff = gasMeteringOff; - gasMeteringOff = true; - - _; - - // if gas metering was on when this modifier was called, turn it back on at the end - if (!gasStartedOff) { - gasMeteringOff = false; - vm.resumeGasMetering(); - } - } - - // We use this complex approach of `_viewChainId` and `_pureChainId` to ensure there are no - // compiler warnings when accessing chain ID in any solidity version supported by forge-std. We - // can't simply access the chain ID in a normal view or pure function because the solc View Pure - // Checker changed `chainid` from pure to view in 0.8.0. - function _viewChainId() private view returns (uint256 chainId) { - // Assembly required since `block.chainid` was introduced in 0.8.0. - assembly { - chainId := chainid() - } - - address(this); // Silence warnings in older Solc versions. - } - - function _pureChainId() private pure returns (uint256 chainId) { - function() internal view returns (uint256) fnIn = _viewChainId; - function() internal pure returns (uint256) pureChainId; - assembly { - pureChainId := fnIn - } - chainId = pureChainId(); - } -} - -// Wrappers around cheatcodes to avoid footguns -abstract contract StdCheats is StdCheatsSafe { - using stdStorage for StdStorage; - - StdStorage private stdstore; - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - address private constant CONSOLE2_ADDRESS = 0x000000000000000000636F6e736F6c652e6c6f67; - - // Skip forward or rewind time by the specified number of seconds - function skip(uint256 time) internal virtual { - vm.warp(block.timestamp + time); - } - - function rewind(uint256 time) internal virtual { - vm.warp(block.timestamp - time); - } - - // Setup a prank from an address that has some ether - function hoax(address msgSender) internal virtual { - vm.deal(msgSender, 1 << 128); - vm.prank(msgSender); - } - - function hoax(address msgSender, uint256 give) internal virtual { - vm.deal(msgSender, give); - vm.prank(msgSender); - } - - function hoax(address msgSender, address origin) internal virtual { - vm.deal(msgSender, 1 << 128); - vm.prank(msgSender, origin); - } - - function hoax(address msgSender, address origin, uint256 give) internal virtual { - vm.deal(msgSender, give); - vm.prank(msgSender, origin); - } - - // Start perpetual prank from an address that has some ether - function startHoax(address msgSender) internal virtual { - vm.deal(msgSender, 1 << 128); - vm.startPrank(msgSender); - } - - function startHoax(address msgSender, uint256 give) internal virtual { - vm.deal(msgSender, give); - vm.startPrank(msgSender); - } - - // Start perpetual prank from an address that has some ether - // tx.origin is set to the origin parameter - function startHoax(address msgSender, address origin) internal virtual { - vm.deal(msgSender, 1 << 128); - vm.startPrank(msgSender, origin); - } - - function startHoax(address msgSender, address origin, uint256 give) internal virtual { - vm.deal(msgSender, give); - vm.startPrank(msgSender, origin); - } - - function changePrank(address msgSender) internal virtual { - console2_log_StdCheats("changePrank is deprecated. Please use vm.startPrank instead."); - vm.stopPrank(); - vm.startPrank(msgSender); - } - - function changePrank(address msgSender, address txOrigin) internal virtual { - vm.stopPrank(); - vm.startPrank(msgSender, txOrigin); - } - - // The same as Vm's `deal` - // Use the alternative signature for ERC20 tokens - function deal(address to, uint256 give) internal virtual { - vm.deal(to, give); - } - - // Set the balance of an account for any ERC20 token - // Use the alternative signature to update `totalSupply` - function deal(address token, address to, uint256 give) internal virtual { - deal(token, to, give, false); - } - - // Set the balance of an account for any ERC1155 token - // Use the alternative signature to update `totalSupply` - function dealERC1155(address token, address to, uint256 id, uint256 give) internal virtual { - dealERC1155(token, to, id, give, false); - } - - function deal(address token, address to, uint256 give, bool adjust) internal virtual { - // get current balance - (, bytes memory balData) = token.staticcall(abi.encodeWithSelector(0x70a08231, to)); - uint256 prevBal = abi.decode(balData, (uint256)); - - // update balance - stdstore.target(token).sig(0x70a08231).with_key(to).checked_write(give); - - // update total supply - if (adjust) { - (, bytes memory totSupData) = token.staticcall(abi.encodeWithSelector(0x18160ddd)); - uint256 totSup = abi.decode(totSupData, (uint256)); - if (give < prevBal) { - totSup -= (prevBal - give); - } else { - totSup += (give - prevBal); - } - stdstore.target(token).sig(0x18160ddd).checked_write(totSup); - } - } - - function dealERC1155(address token, address to, uint256 id, uint256 give, bool adjust) internal virtual { - // get current balance - (, bytes memory balData) = token.staticcall(abi.encodeWithSelector(0x00fdd58e, to, id)); - uint256 prevBal = abi.decode(balData, (uint256)); - - // update balance - stdstore.target(token).sig(0x00fdd58e).with_key(to).with_key(id).checked_write(give); - - // update total supply - if (adjust) { - (, bytes memory totSupData) = token.staticcall(abi.encodeWithSelector(0xbd85b039, id)); - require( - totSupData.length != 0, - "StdCheats deal(address,address,uint,uint,bool): target contract is not ERC1155Supply." - ); - uint256 totSup = abi.decode(totSupData, (uint256)); - if (give < prevBal) { - totSup -= (prevBal - give); - } else { - totSup += (give - prevBal); - } - stdstore.target(token).sig(0xbd85b039).with_key(id).checked_write(totSup); - } - } - - function dealERC721(address token, address to, uint256 id) internal virtual { - // check if token id is already minted and the actual owner. - (bool successMinted, bytes memory ownerData) = token.staticcall(abi.encodeWithSelector(0x6352211e, id)); - require(successMinted, "StdCheats deal(address,address,uint,bool): id not minted."); - - // get owner current balance - (, bytes memory fromBalData) = - token.staticcall(abi.encodeWithSelector(0x70a08231, abi.decode(ownerData, (address)))); - uint256 fromPrevBal = abi.decode(fromBalData, (uint256)); - - // get new user current balance - (, bytes memory toBalData) = token.staticcall(abi.encodeWithSelector(0x70a08231, to)); - uint256 toPrevBal = abi.decode(toBalData, (uint256)); - - // update balances - stdstore.target(token).sig(0x70a08231).with_key(abi.decode(ownerData, (address))).checked_write(--fromPrevBal); - stdstore.target(token).sig(0x70a08231).with_key(to).checked_write(++toPrevBal); - - // update owner - stdstore.target(token).sig(0x6352211e).with_key(id).checked_write(to); - } - - function deployCodeTo(string memory what, address where) internal virtual { - deployCodeTo(what, "", 0, where); - } - - function deployCodeTo(string memory what, bytes memory args, address where) internal virtual { - deployCodeTo(what, args, 0, where); - } - - function deployCodeTo(string memory what, bytes memory args, uint256 value, address where) internal virtual { - bytes memory creationCode = vm.getCode(what); - vm.etch(where, abi.encodePacked(creationCode, args)); - (bool success, bytes memory runtimeBytecode) = where.call{value: value}(""); - require(success, "StdCheats deployCodeTo(string,bytes,uint256,address): Failed to create runtime bytecode."); - vm.etch(where, runtimeBytecode); - } - - // Used to prevent the compilation of console, which shortens the compilation time when console is not used elsewhere. - function console2_log_StdCheats(string memory p0) private view { - (bool status,) = address(CONSOLE2_ADDRESS).staticcall(abi.encodeWithSignature("log(string)", p0)); - status; - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdError.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdError.sol deleted file mode 100644 index a302191faa..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdError.sol +++ /dev/null @@ -1,15 +0,0 @@ -// SPDX-License-Identifier: MIT -// Panics work for versions >=0.8.0, but we lowered the pragma to make this compatible with Test -pragma solidity >=0.6.2 <0.9.0; - -library stdError { - bytes public constant assertionError = abi.encodeWithSignature("Panic(uint256)", 0x01); - bytes public constant arithmeticError = abi.encodeWithSignature("Panic(uint256)", 0x11); - bytes public constant divisionError = abi.encodeWithSignature("Panic(uint256)", 0x12); - bytes public constant enumConversionError = abi.encodeWithSignature("Panic(uint256)", 0x21); - bytes public constant encodeStorageError = abi.encodeWithSignature("Panic(uint256)", 0x22); - bytes public constant popError = abi.encodeWithSignature("Panic(uint256)", 0x31); - bytes public constant indexOOBError = abi.encodeWithSignature("Panic(uint256)", 0x32); - bytes public constant memOverflowError = abi.encodeWithSignature("Panic(uint256)", 0x41); - bytes public constant zeroVarError = abi.encodeWithSignature("Panic(uint256)", 0x51); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdInvariant.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdInvariant.sol deleted file mode 100644 index 056db98fcf..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdInvariant.sol +++ /dev/null @@ -1,122 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -abstract contract StdInvariant { - struct FuzzSelector { - address addr; - bytes4[] selectors; - } - - struct FuzzArtifactSelector { - string artifact; - bytes4[] selectors; - } - - struct FuzzInterface { - address addr; - string[] artifacts; - } - - address[] private _excludedContracts; - address[] private _excludedSenders; - address[] private _targetedContracts; - address[] private _targetedSenders; - - string[] private _excludedArtifacts; - string[] private _targetedArtifacts; - - FuzzArtifactSelector[] private _targetedArtifactSelectors; - - FuzzSelector[] private _excludedSelectors; - FuzzSelector[] private _targetedSelectors; - - FuzzInterface[] private _targetedInterfaces; - - // Functions for users: - // These are intended to be called in tests. - - function excludeContract(address newExcludedContract_) internal { - _excludedContracts.push(newExcludedContract_); - } - - function excludeSelector(FuzzSelector memory newExcludedSelector_) internal { - _excludedSelectors.push(newExcludedSelector_); - } - - function excludeSender(address newExcludedSender_) internal { - _excludedSenders.push(newExcludedSender_); - } - - function excludeArtifact(string memory newExcludedArtifact_) internal { - _excludedArtifacts.push(newExcludedArtifact_); - } - - function targetArtifact(string memory newTargetedArtifact_) internal { - _targetedArtifacts.push(newTargetedArtifact_); - } - - function targetArtifactSelector(FuzzArtifactSelector memory newTargetedArtifactSelector_) internal { - _targetedArtifactSelectors.push(newTargetedArtifactSelector_); - } - - function targetContract(address newTargetedContract_) internal { - _targetedContracts.push(newTargetedContract_); - } - - function targetSelector(FuzzSelector memory newTargetedSelector_) internal { - _targetedSelectors.push(newTargetedSelector_); - } - - function targetSender(address newTargetedSender_) internal { - _targetedSenders.push(newTargetedSender_); - } - - function targetInterface(FuzzInterface memory newTargetedInterface_) internal { - _targetedInterfaces.push(newTargetedInterface_); - } - - // Functions for forge: - // These are called by forge to run invariant tests and don't need to be called in tests. - - function excludeArtifacts() public view returns (string[] memory excludedArtifacts_) { - excludedArtifacts_ = _excludedArtifacts; - } - - function excludeContracts() public view returns (address[] memory excludedContracts_) { - excludedContracts_ = _excludedContracts; - } - - function excludeSelectors() public view returns (FuzzSelector[] memory excludedSelectors_) { - excludedSelectors_ = _excludedSelectors; - } - - function excludeSenders() public view returns (address[] memory excludedSenders_) { - excludedSenders_ = _excludedSenders; - } - - function targetArtifacts() public view returns (string[] memory targetedArtifacts_) { - targetedArtifacts_ = _targetedArtifacts; - } - - function targetArtifactSelectors() public view returns (FuzzArtifactSelector[] memory targetedArtifactSelectors_) { - targetedArtifactSelectors_ = _targetedArtifactSelectors; - } - - function targetContracts() public view returns (address[] memory targetedContracts_) { - targetedContracts_ = _targetedContracts; - } - - function targetSelectors() public view returns (FuzzSelector[] memory targetedSelectors_) { - targetedSelectors_ = _targetedSelectors; - } - - function targetSenders() public view returns (address[] memory targetedSenders_) { - targetedSenders_ = _targetedSenders; - } - - function targetInterfaces() public view returns (FuzzInterface[] memory targetedInterfaces_) { - targetedInterfaces_ = _targetedInterfaces; - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdJson.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdJson.sol deleted file mode 100644 index 2a033c03a7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdJson.sol +++ /dev/null @@ -1,283 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.0 <0.9.0; - -pragma experimental ABIEncoderV2; - -import {VmSafe} from "./Vm.sol"; - -// Helpers for parsing and writing JSON files -// To parse: -// ``` -// using stdJson for string; -// string memory json = vm.readFile(""); -// json.readUint(""); -// ``` -// To write: -// ``` -// using stdJson for string; -// string memory json = "json"; -// json.serialize("a", uint256(123)); -// string memory semiFinal = json.serialize("b", string("test")); -// string memory finalJson = json.serialize("c", semiFinal); -// finalJson.write(""); -// ``` - -library stdJson { - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - function keyExists(string memory json, string memory key) internal view returns (bool) { - return vm.keyExistsJson(json, key); - } - - function parseRaw(string memory json, string memory key) internal pure returns (bytes memory) { - return vm.parseJson(json, key); - } - - function readUint(string memory json, string memory key) internal pure returns (uint256) { - return vm.parseJsonUint(json, key); - } - - function readUintArray(string memory json, string memory key) internal pure returns (uint256[] memory) { - return vm.parseJsonUintArray(json, key); - } - - function readInt(string memory json, string memory key) internal pure returns (int256) { - return vm.parseJsonInt(json, key); - } - - function readIntArray(string memory json, string memory key) internal pure returns (int256[] memory) { - return vm.parseJsonIntArray(json, key); - } - - function readBytes32(string memory json, string memory key) internal pure returns (bytes32) { - return vm.parseJsonBytes32(json, key); - } - - function readBytes32Array(string memory json, string memory key) internal pure returns (bytes32[] memory) { - return vm.parseJsonBytes32Array(json, key); - } - - function readString(string memory json, string memory key) internal pure returns (string memory) { - return vm.parseJsonString(json, key); - } - - function readStringArray(string memory json, string memory key) internal pure returns (string[] memory) { - return vm.parseJsonStringArray(json, key); - } - - function readAddress(string memory json, string memory key) internal pure returns (address) { - return vm.parseJsonAddress(json, key); - } - - function readAddressArray(string memory json, string memory key) internal pure returns (address[] memory) { - return vm.parseJsonAddressArray(json, key); - } - - function readBool(string memory json, string memory key) internal pure returns (bool) { - return vm.parseJsonBool(json, key); - } - - function readBoolArray(string memory json, string memory key) internal pure returns (bool[] memory) { - return vm.parseJsonBoolArray(json, key); - } - - function readBytes(string memory json, string memory key) internal pure returns (bytes memory) { - return vm.parseJsonBytes(json, key); - } - - function readBytesArray(string memory json, string memory key) internal pure returns (bytes[] memory) { - return vm.parseJsonBytesArray(json, key); - } - - function readUintOr(string memory json, string memory key, uint256 defaultValue) internal view returns (uint256) { - return keyExists(json, key) ? readUint(json, key) : defaultValue; - } - - function readUintArrayOr(string memory json, string memory key, uint256[] memory defaultValue) - internal - view - returns (uint256[] memory) - { - return keyExists(json, key) ? readUintArray(json, key) : defaultValue; - } - - function readIntOr(string memory json, string memory key, int256 defaultValue) internal view returns (int256) { - return keyExists(json, key) ? readInt(json, key) : defaultValue; - } - - function readIntArrayOr(string memory json, string memory key, int256[] memory defaultValue) - internal - view - returns (int256[] memory) - { - return keyExists(json, key) ? readIntArray(json, key) : defaultValue; - } - - function readBytes32Or(string memory json, string memory key, bytes32 defaultValue) - internal - view - returns (bytes32) - { - return keyExists(json, key) ? readBytes32(json, key) : defaultValue; - } - - function readBytes32ArrayOr(string memory json, string memory key, bytes32[] memory defaultValue) - internal - view - returns (bytes32[] memory) - { - return keyExists(json, key) ? readBytes32Array(json, key) : defaultValue; - } - - function readStringOr(string memory json, string memory key, string memory defaultValue) - internal - view - returns (string memory) - { - return keyExists(json, key) ? readString(json, key) : defaultValue; - } - - function readStringArrayOr(string memory json, string memory key, string[] memory defaultValue) - internal - view - returns (string[] memory) - { - return keyExists(json, key) ? readStringArray(json, key) : defaultValue; - } - - function readAddressOr(string memory json, string memory key, address defaultValue) - internal - view - returns (address) - { - return keyExists(json, key) ? readAddress(json, key) : defaultValue; - } - - function readAddressArrayOr(string memory json, string memory key, address[] memory defaultValue) - internal - view - returns (address[] memory) - { - return keyExists(json, key) ? readAddressArray(json, key) : defaultValue; - } - - function readBoolOr(string memory json, string memory key, bool defaultValue) internal view returns (bool) { - return keyExists(json, key) ? readBool(json, key) : defaultValue; - } - - function readBoolArrayOr(string memory json, string memory key, bool[] memory defaultValue) - internal - view - returns (bool[] memory) - { - return keyExists(json, key) ? readBoolArray(json, key) : defaultValue; - } - - function readBytesOr(string memory json, string memory key, bytes memory defaultValue) - internal - view - returns (bytes memory) - { - return keyExists(json, key) ? readBytes(json, key) : defaultValue; - } - - function readBytesArrayOr(string memory json, string memory key, bytes[] memory defaultValue) - internal - view - returns (bytes[] memory) - { - return keyExists(json, key) ? readBytesArray(json, key) : defaultValue; - } - - function serialize(string memory jsonKey, string memory rootObject) internal returns (string memory) { - return vm.serializeJson(jsonKey, rootObject); - } - - function serialize(string memory jsonKey, string memory key, bool value) internal returns (string memory) { - return vm.serializeBool(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bool[] memory value) - internal - returns (string memory) - { - return vm.serializeBool(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, uint256 value) internal returns (string memory) { - return vm.serializeUint(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, uint256[] memory value) - internal - returns (string memory) - { - return vm.serializeUint(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, int256 value) internal returns (string memory) { - return vm.serializeInt(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, int256[] memory value) - internal - returns (string memory) - { - return vm.serializeInt(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, address value) internal returns (string memory) { - return vm.serializeAddress(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, address[] memory value) - internal - returns (string memory) - { - return vm.serializeAddress(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes32 value) internal returns (string memory) { - return vm.serializeBytes32(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes32[] memory value) - internal - returns (string memory) - { - return vm.serializeBytes32(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes memory value) internal returns (string memory) { - return vm.serializeBytes(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes[] memory value) - internal - returns (string memory) - { - return vm.serializeBytes(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, string memory value) - internal - returns (string memory) - { - return vm.serializeString(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, string[] memory value) - internal - returns (string memory) - { - return vm.serializeString(jsonKey, key, value); - } - - function write(string memory jsonKey, string memory path) internal { - vm.writeJson(jsonKey, path); - } - - function write(string memory jsonKey, string memory path, string memory valueKey) internal { - vm.writeJson(jsonKey, path, valueKey); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdMath.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdMath.sol deleted file mode 100644 index 459523bdac..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdMath.sol +++ /dev/null @@ -1,43 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -library stdMath { - int256 private constant INT256_MIN = -57896044618658097711785492504343953926634992332820282019728792003956564819968; - - function abs(int256 a) internal pure returns (uint256) { - // Required or it will fail when `a = type(int256).min` - if (a == INT256_MIN) { - return 57896044618658097711785492504343953926634992332820282019728792003956564819968; - } - - return uint256(a > 0 ? a : -a); - } - - function delta(uint256 a, uint256 b) internal pure returns (uint256) { - return a > b ? a - b : b - a; - } - - function delta(int256 a, int256 b) internal pure returns (uint256) { - // a and b are of the same sign - // this works thanks to two's complement, the left-most bit is the sign bit - if ((a ^ b) > -1) { - return delta(abs(a), abs(b)); - } - - // a and b are of opposite signs - return abs(a) + abs(b); - } - - function percentDelta(uint256 a, uint256 b) internal pure returns (uint256) { - uint256 absDelta = delta(a, b); - - return absDelta * 1e18 / b; - } - - function percentDelta(int256 a, int256 b) internal pure returns (uint256) { - uint256 absDelta = delta(a, b); - uint256 absB = abs(b); - - return absDelta * 1e18 / absB; - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdStorage.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdStorage.sol deleted file mode 100644 index bf3223dee5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdStorage.sol +++ /dev/null @@ -1,473 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -import {Vm} from "./Vm.sol"; - -struct FindData { - uint256 slot; - uint256 offsetLeft; - uint256 offsetRight; - bool found; -} - -struct StdStorage { - mapping(address => mapping(bytes4 => mapping(bytes32 => FindData))) finds; - bytes32[] _keys; - bytes4 _sig; - uint256 _depth; - address _target; - bytes32 _set; - bool _enable_packed_slots; - bytes _calldata; -} - -library stdStorageSafe { - event SlotFound(address who, bytes4 fsig, bytes32 keysHash, uint256 slot); - event WARNING_UninitedSlot(address who, uint256 slot); - - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - uint256 constant UINT256_MAX = 115792089237316195423570985008687907853269984665640564039457584007913129639935; - - function sigs(string memory sigStr) internal pure returns (bytes4) { - return bytes4(keccak256(bytes(sigStr))); - } - - function getCallParams(StdStorage storage self) internal view returns (bytes memory) { - if (self._calldata.length == 0) { - return flatten(self._keys); - } else { - return self._calldata; - } - } - - // Calls target contract with configured parameters - function callTarget(StdStorage storage self) internal view returns (bool, bytes32) { - bytes memory cald = abi.encodePacked(self._sig, getCallParams(self)); - (bool success, bytes memory rdat) = self._target.staticcall(cald); - bytes32 result = bytesToBytes32(rdat, 32 * self._depth); - - return (success, result); - } - - // Tries mutating slot value to determine if the targeted value is stored in it. - // If current value is 0, then we are setting slot value to type(uint256).max - // Otherwise, we set it to 0. That way, return value should always be affected. - function checkSlotMutatesCall(StdStorage storage self, bytes32 slot) internal returns (bool) { - bytes32 prevSlotValue = vm.load(self._target, slot); - (bool success, bytes32 prevReturnValue) = callTarget(self); - - bytes32 testVal = prevReturnValue == bytes32(0) ? bytes32(UINT256_MAX) : bytes32(0); - vm.store(self._target, slot, testVal); - - (, bytes32 newReturnValue) = callTarget(self); - - vm.store(self._target, slot, prevSlotValue); - - return (success && (prevReturnValue != newReturnValue)); - } - - // Tries setting one of the bits in slot to 1 until return value changes. - // Index of resulted bit is an offset packed slot has from left/right side - function findOffset(StdStorage storage self, bytes32 slot, bool left) internal returns (bool, uint256) { - for (uint256 offset = 0; offset < 256; offset++) { - uint256 valueToPut = left ? (1 << (255 - offset)) : (1 << offset); - vm.store(self._target, slot, bytes32(valueToPut)); - - (bool success, bytes32 data) = callTarget(self); - - if (success && (uint256(data) > 0)) { - return (true, offset); - } - } - return (false, 0); - } - - function findOffsets(StdStorage storage self, bytes32 slot) internal returns (bool, uint256, uint256) { - bytes32 prevSlotValue = vm.load(self._target, slot); - - (bool foundLeft, uint256 offsetLeft) = findOffset(self, slot, true); - (bool foundRight, uint256 offsetRight) = findOffset(self, slot, false); - - // `findOffset` may mutate slot value, so we are setting it to initial value - vm.store(self._target, slot, prevSlotValue); - return (foundLeft && foundRight, offsetLeft, offsetRight); - } - - function find(StdStorage storage self) internal returns (FindData storage) { - return find(self, true); - } - - /// @notice find an arbitrary storage slot given a function sig, input data, address of the contract and a value to check against - // slot complexity: - // if flat, will be bytes32(uint256(uint)); - // if map, will be keccak256(abi.encode(key, uint(slot))); - // if deep map, will be keccak256(abi.encode(key1, keccak256(abi.encode(key0, uint(slot))))); - // if map struct, will be bytes32(uint256(keccak256(abi.encode(key1, keccak256(abi.encode(key0, uint(slot)))))) + structFieldDepth); - function find(StdStorage storage self, bool _clear) internal returns (FindData storage) { - address who = self._target; - bytes4 fsig = self._sig; - uint256 field_depth = self._depth; - bytes memory params = getCallParams(self); - - // calldata to test against - if (self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))].found) { - if (_clear) { - clear(self); - } - return self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))]; - } - vm.record(); - (, bytes32 callResult) = callTarget(self); - (bytes32[] memory reads,) = vm.accesses(address(who)); - - if (reads.length == 0) { - revert("stdStorage find(StdStorage): No storage use detected for target."); - } else { - for (uint256 i = reads.length; --i >= 0;) { - bytes32 prev = vm.load(who, reads[i]); - if (prev == bytes32(0)) { - emit WARNING_UninitedSlot(who, uint256(reads[i])); - } - - if (!checkSlotMutatesCall(self, reads[i])) { - continue; - } - - (uint256 offsetLeft, uint256 offsetRight) = (0, 0); - - if (self._enable_packed_slots) { - bool found; - (found, offsetLeft, offsetRight) = findOffsets(self, reads[i]); - if (!found) { - continue; - } - } - - // Check that value between found offsets is equal to the current call result - uint256 curVal = (uint256(prev) & getMaskByOffsets(offsetLeft, offsetRight)) >> offsetRight; - - if (uint256(callResult) != curVal) { - continue; - } - - emit SlotFound(who, fsig, keccak256(abi.encodePacked(params, field_depth)), uint256(reads[i])); - self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))] = - FindData(uint256(reads[i]), offsetLeft, offsetRight, true); - break; - } - } - - require( - self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))].found, - "stdStorage find(StdStorage): Slot(s) not found." - ); - - if (_clear) { - clear(self); - } - return self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))]; - } - - function target(StdStorage storage self, address _target) internal returns (StdStorage storage) { - self._target = _target; - return self; - } - - function sig(StdStorage storage self, bytes4 _sig) internal returns (StdStorage storage) { - self._sig = _sig; - return self; - } - - function sig(StdStorage storage self, string memory _sig) internal returns (StdStorage storage) { - self._sig = sigs(_sig); - return self; - } - - function with_calldata(StdStorage storage self, bytes memory _calldata) internal returns (StdStorage storage) { - self._calldata = _calldata; - return self; - } - - function with_key(StdStorage storage self, address who) internal returns (StdStorage storage) { - self._keys.push(bytes32(uint256(uint160(who)))); - return self; - } - - function with_key(StdStorage storage self, uint256 amt) internal returns (StdStorage storage) { - self._keys.push(bytes32(amt)); - return self; - } - - function with_key(StdStorage storage self, bytes32 key) internal returns (StdStorage storage) { - self._keys.push(key); - return self; - } - - function enable_packed_slots(StdStorage storage self) internal returns (StdStorage storage) { - self._enable_packed_slots = true; - return self; - } - - function depth(StdStorage storage self, uint256 _depth) internal returns (StdStorage storage) { - self._depth = _depth; - return self; - } - - function read(StdStorage storage self) private returns (bytes memory) { - FindData storage data = find(self, false); - uint256 mask = getMaskByOffsets(data.offsetLeft, data.offsetRight); - uint256 value = (uint256(vm.load(self._target, bytes32(data.slot))) & mask) >> data.offsetRight; - clear(self); - return abi.encode(value); - } - - function read_bytes32(StdStorage storage self) internal returns (bytes32) { - return abi.decode(read(self), (bytes32)); - } - - function read_bool(StdStorage storage self) internal returns (bool) { - int256 v = read_int(self); - if (v == 0) return false; - if (v == 1) return true; - revert("stdStorage read_bool(StdStorage): Cannot decode. Make sure you are reading a bool."); - } - - function read_address(StdStorage storage self) internal returns (address) { - return abi.decode(read(self), (address)); - } - - function read_uint(StdStorage storage self) internal returns (uint256) { - return abi.decode(read(self), (uint256)); - } - - function read_int(StdStorage storage self) internal returns (int256) { - return abi.decode(read(self), (int256)); - } - - function parent(StdStorage storage self) internal returns (uint256, bytes32) { - address who = self._target; - uint256 field_depth = self._depth; - vm.startMappingRecording(); - uint256 child = find(self, true).slot - field_depth; - (bool found, bytes32 key, bytes32 parent_slot) = vm.getMappingKeyAndParentOf(who, bytes32(child)); - if (!found) { - revert( - "stdStorage read_bool(StdStorage): Cannot find parent. Make sure you give a slot and startMappingRecording() has been called." - ); - } - return (uint256(parent_slot), key); - } - - function root(StdStorage storage self) internal returns (uint256) { - address who = self._target; - uint256 field_depth = self._depth; - vm.startMappingRecording(); - uint256 child = find(self, true).slot - field_depth; - bool found; - bytes32 root_slot; - bytes32 parent_slot; - (found,, parent_slot) = vm.getMappingKeyAndParentOf(who, bytes32(child)); - if (!found) { - revert( - "stdStorage read_bool(StdStorage): Cannot find parent. Make sure you give a slot and startMappingRecording() has been called." - ); - } - while (found) { - root_slot = parent_slot; - (found,, parent_slot) = vm.getMappingKeyAndParentOf(who, bytes32(root_slot)); - } - return uint256(root_slot); - } - - function bytesToBytes32(bytes memory b, uint256 offset) private pure returns (bytes32) { - bytes32 out; - - uint256 max = b.length > 32 ? 32 : b.length; - for (uint256 i = 0; i < max; i++) { - out |= bytes32(b[offset + i] & 0xFF) >> (i * 8); - } - return out; - } - - function flatten(bytes32[] memory b) private pure returns (bytes memory) { - bytes memory result = new bytes(b.length * 32); - for (uint256 i = 0; i < b.length; i++) { - bytes32 k = b[i]; - /// @solidity memory-safe-assembly - assembly { - mstore(add(result, add(32, mul(32, i))), k) - } - } - - return result; - } - - function clear(StdStorage storage self) internal { - delete self._target; - delete self._sig; - delete self._keys; - delete self._depth; - delete self._enable_packed_slots; - delete self._calldata; - } - - // Returns mask which contains non-zero bits for values between `offsetLeft` and `offsetRight` - // (slotValue & mask) >> offsetRight will be the value of the given packed variable - function getMaskByOffsets(uint256 offsetLeft, uint256 offsetRight) internal pure returns (uint256 mask) { - // mask = ((1 << (256 - (offsetRight + offsetLeft))) - 1) << offsetRight; - // using assembly because (1 << 256) causes overflow - assembly { - mask := shl(offsetRight, sub(shl(sub(256, add(offsetRight, offsetLeft)), 1), 1)) - } - } - - // Returns slot value with updated packed variable. - function getUpdatedSlotValue(bytes32 curValue, uint256 varValue, uint256 offsetLeft, uint256 offsetRight) - internal - pure - returns (bytes32 newValue) - { - return bytes32((uint256(curValue) & ~getMaskByOffsets(offsetLeft, offsetRight)) | (varValue << offsetRight)); - } -} - -library stdStorage { - Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); - - function sigs(string memory sigStr) internal pure returns (bytes4) { - return stdStorageSafe.sigs(sigStr); - } - - function find(StdStorage storage self) internal returns (uint256) { - return find(self, true); - } - - function find(StdStorage storage self, bool _clear) internal returns (uint256) { - return stdStorageSafe.find(self, _clear).slot; - } - - function target(StdStorage storage self, address _target) internal returns (StdStorage storage) { - return stdStorageSafe.target(self, _target); - } - - function sig(StdStorage storage self, bytes4 _sig) internal returns (StdStorage storage) { - return stdStorageSafe.sig(self, _sig); - } - - function sig(StdStorage storage self, string memory _sig) internal returns (StdStorage storage) { - return stdStorageSafe.sig(self, _sig); - } - - function with_key(StdStorage storage self, address who) internal returns (StdStorage storage) { - return stdStorageSafe.with_key(self, who); - } - - function with_key(StdStorage storage self, uint256 amt) internal returns (StdStorage storage) { - return stdStorageSafe.with_key(self, amt); - } - - function with_key(StdStorage storage self, bytes32 key) internal returns (StdStorage storage) { - return stdStorageSafe.with_key(self, key); - } - - function with_calldata(StdStorage storage self, bytes memory _calldata) internal returns (StdStorage storage) { - return stdStorageSafe.with_calldata(self, _calldata); - } - - function enable_packed_slots(StdStorage storage self) internal returns (StdStorage storage) { - return stdStorageSafe.enable_packed_slots(self); - } - - function depth(StdStorage storage self, uint256 _depth) internal returns (StdStorage storage) { - return stdStorageSafe.depth(self, _depth); - } - - function clear(StdStorage storage self) internal { - stdStorageSafe.clear(self); - } - - function checked_write(StdStorage storage self, address who) internal { - checked_write(self, bytes32(uint256(uint160(who)))); - } - - function checked_write(StdStorage storage self, uint256 amt) internal { - checked_write(self, bytes32(amt)); - } - - function checked_write_int(StdStorage storage self, int256 val) internal { - checked_write(self, bytes32(uint256(val))); - } - - function checked_write(StdStorage storage self, bool write) internal { - bytes32 t; - /// @solidity memory-safe-assembly - assembly { - t := write - } - checked_write(self, t); - } - - function checked_write(StdStorage storage self, bytes32 set) internal { - address who = self._target; - bytes4 fsig = self._sig; - uint256 field_depth = self._depth; - bytes memory params = stdStorageSafe.getCallParams(self); - - if (!self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))].found) { - find(self, false); - } - FindData storage data = self.finds[who][fsig][keccak256(abi.encodePacked(params, field_depth))]; - if ((data.offsetLeft + data.offsetRight) > 0) { - uint256 maxVal = 2 ** (256 - (data.offsetLeft + data.offsetRight)); - require( - uint256(set) < maxVal, - string( - abi.encodePacked( - "stdStorage find(StdStorage): Packed slot. We can't fit value greater than ", - vm.toString(maxVal) - ) - ) - ); - } - bytes32 curVal = vm.load(who, bytes32(data.slot)); - bytes32 valToSet = stdStorageSafe.getUpdatedSlotValue(curVal, uint256(set), data.offsetLeft, data.offsetRight); - - vm.store(who, bytes32(data.slot), valToSet); - - (bool success, bytes32 callResult) = stdStorageSafe.callTarget(self); - - if (!success || callResult != set) { - vm.store(who, bytes32(data.slot), curVal); - revert("stdStorage find(StdStorage): Failed to write value."); - } - clear(self); - } - - function read_bytes32(StdStorage storage self) internal returns (bytes32) { - return stdStorageSafe.read_bytes32(self); - } - - function read_bool(StdStorage storage self) internal returns (bool) { - return stdStorageSafe.read_bool(self); - } - - function read_address(StdStorage storage self) internal returns (address) { - return stdStorageSafe.read_address(self); - } - - function read_uint(StdStorage storage self) internal returns (uint256) { - return stdStorageSafe.read_uint(self); - } - - function read_int(StdStorage storage self) internal returns (int256) { - return stdStorageSafe.read_int(self); - } - - function parent(StdStorage storage self) internal returns (uint256, bytes32) { - return stdStorageSafe.parent(self); - } - - function root(StdStorage storage self) internal returns (uint256) { - return stdStorageSafe.root(self); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdStyle.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdStyle.sol deleted file mode 100644 index d371e0c60a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdStyle.sol +++ /dev/null @@ -1,333 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.4.22 <0.9.0; - -import {VmSafe} from "./Vm.sol"; - -library StdStyle { - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - string constant RED = "\u001b[91m"; - string constant GREEN = "\u001b[92m"; - string constant YELLOW = "\u001b[93m"; - string constant BLUE = "\u001b[94m"; - string constant MAGENTA = "\u001b[95m"; - string constant CYAN = "\u001b[96m"; - string constant BOLD = "\u001b[1m"; - string constant DIM = "\u001b[2m"; - string constant ITALIC = "\u001b[3m"; - string constant UNDERLINE = "\u001b[4m"; - string constant INVERSE = "\u001b[7m"; - string constant RESET = "\u001b[0m"; - - function styleConcat(string memory style, string memory self) private pure returns (string memory) { - return string(abi.encodePacked(style, self, RESET)); - } - - function red(string memory self) internal pure returns (string memory) { - return styleConcat(RED, self); - } - - function red(uint256 self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function red(int256 self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function red(address self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function red(bool self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function redBytes(bytes memory self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function redBytes32(bytes32 self) internal pure returns (string memory) { - return red(vm.toString(self)); - } - - function green(string memory self) internal pure returns (string memory) { - return styleConcat(GREEN, self); - } - - function green(uint256 self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function green(int256 self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function green(address self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function green(bool self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function greenBytes(bytes memory self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function greenBytes32(bytes32 self) internal pure returns (string memory) { - return green(vm.toString(self)); - } - - function yellow(string memory self) internal pure returns (string memory) { - return styleConcat(YELLOW, self); - } - - function yellow(uint256 self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellow(int256 self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellow(address self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellow(bool self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellowBytes(bytes memory self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function yellowBytes32(bytes32 self) internal pure returns (string memory) { - return yellow(vm.toString(self)); - } - - function blue(string memory self) internal pure returns (string memory) { - return styleConcat(BLUE, self); - } - - function blue(uint256 self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blue(int256 self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blue(address self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blue(bool self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blueBytes(bytes memory self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function blueBytes32(bytes32 self) internal pure returns (string memory) { - return blue(vm.toString(self)); - } - - function magenta(string memory self) internal pure returns (string memory) { - return styleConcat(MAGENTA, self); - } - - function magenta(uint256 self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magenta(int256 self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magenta(address self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magenta(bool self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magentaBytes(bytes memory self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function magentaBytes32(bytes32 self) internal pure returns (string memory) { - return magenta(vm.toString(self)); - } - - function cyan(string memory self) internal pure returns (string memory) { - return styleConcat(CYAN, self); - } - - function cyan(uint256 self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyan(int256 self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyan(address self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyan(bool self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyanBytes(bytes memory self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function cyanBytes32(bytes32 self) internal pure returns (string memory) { - return cyan(vm.toString(self)); - } - - function bold(string memory self) internal pure returns (string memory) { - return styleConcat(BOLD, self); - } - - function bold(uint256 self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function bold(int256 self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function bold(address self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function bold(bool self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function boldBytes(bytes memory self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function boldBytes32(bytes32 self) internal pure returns (string memory) { - return bold(vm.toString(self)); - } - - function dim(string memory self) internal pure returns (string memory) { - return styleConcat(DIM, self); - } - - function dim(uint256 self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dim(int256 self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dim(address self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dim(bool self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dimBytes(bytes memory self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function dimBytes32(bytes32 self) internal pure returns (string memory) { - return dim(vm.toString(self)); - } - - function italic(string memory self) internal pure returns (string memory) { - return styleConcat(ITALIC, self); - } - - function italic(uint256 self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italic(int256 self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italic(address self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italic(bool self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italicBytes(bytes memory self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function italicBytes32(bytes32 self) internal pure returns (string memory) { - return italic(vm.toString(self)); - } - - function underline(string memory self) internal pure returns (string memory) { - return styleConcat(UNDERLINE, self); - } - - function underline(uint256 self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underline(int256 self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underline(address self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underline(bool self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underlineBytes(bytes memory self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function underlineBytes32(bytes32 self) internal pure returns (string memory) { - return underline(vm.toString(self)); - } - - function inverse(string memory self) internal pure returns (string memory) { - return styleConcat(INVERSE, self); - } - - function inverse(uint256 self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverse(int256 self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverse(address self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverse(bool self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverseBytes(bytes memory self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } - - function inverseBytes32(bytes32 self) internal pure returns (string memory) { - return inverse(vm.toString(self)); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdToml.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdToml.sol deleted file mode 100644 index 7ad3be2f97..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdToml.sol +++ /dev/null @@ -1,283 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.0 <0.9.0; - -pragma experimental ABIEncoderV2; - -import {VmSafe} from "./Vm.sol"; - -// Helpers for parsing and writing TOML files -// To parse: -// ``` -// using stdToml for string; -// string memory toml = vm.readFile(""); -// toml.readUint(""); -// ``` -// To write: -// ``` -// using stdToml for string; -// string memory json = "json"; -// json.serialize("a", uint256(123)); -// string memory semiFinal = json.serialize("b", string("test")); -// string memory finalJson = json.serialize("c", semiFinal); -// finalJson.write(""); -// ``` - -library stdToml { - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - - function keyExists(string memory toml, string memory key) internal view returns (bool) { - return vm.keyExistsToml(toml, key); - } - - function parseRaw(string memory toml, string memory key) internal pure returns (bytes memory) { - return vm.parseToml(toml, key); - } - - function readUint(string memory toml, string memory key) internal pure returns (uint256) { - return vm.parseTomlUint(toml, key); - } - - function readUintArray(string memory toml, string memory key) internal pure returns (uint256[] memory) { - return vm.parseTomlUintArray(toml, key); - } - - function readInt(string memory toml, string memory key) internal pure returns (int256) { - return vm.parseTomlInt(toml, key); - } - - function readIntArray(string memory toml, string memory key) internal pure returns (int256[] memory) { - return vm.parseTomlIntArray(toml, key); - } - - function readBytes32(string memory toml, string memory key) internal pure returns (bytes32) { - return vm.parseTomlBytes32(toml, key); - } - - function readBytes32Array(string memory toml, string memory key) internal pure returns (bytes32[] memory) { - return vm.parseTomlBytes32Array(toml, key); - } - - function readString(string memory toml, string memory key) internal pure returns (string memory) { - return vm.parseTomlString(toml, key); - } - - function readStringArray(string memory toml, string memory key) internal pure returns (string[] memory) { - return vm.parseTomlStringArray(toml, key); - } - - function readAddress(string memory toml, string memory key) internal pure returns (address) { - return vm.parseTomlAddress(toml, key); - } - - function readAddressArray(string memory toml, string memory key) internal pure returns (address[] memory) { - return vm.parseTomlAddressArray(toml, key); - } - - function readBool(string memory toml, string memory key) internal pure returns (bool) { - return vm.parseTomlBool(toml, key); - } - - function readBoolArray(string memory toml, string memory key) internal pure returns (bool[] memory) { - return vm.parseTomlBoolArray(toml, key); - } - - function readBytes(string memory toml, string memory key) internal pure returns (bytes memory) { - return vm.parseTomlBytes(toml, key); - } - - function readBytesArray(string memory toml, string memory key) internal pure returns (bytes[] memory) { - return vm.parseTomlBytesArray(toml, key); - } - - function readUintOr(string memory toml, string memory key, uint256 defaultValue) internal view returns (uint256) { - return keyExists(toml, key) ? readUint(toml, key) : defaultValue; - } - - function readUintArrayOr(string memory toml, string memory key, uint256[] memory defaultValue) - internal - view - returns (uint256[] memory) - { - return keyExists(toml, key) ? readUintArray(toml, key) : defaultValue; - } - - function readIntOr(string memory toml, string memory key, int256 defaultValue) internal view returns (int256) { - return keyExists(toml, key) ? readInt(toml, key) : defaultValue; - } - - function readIntArrayOr(string memory toml, string memory key, int256[] memory defaultValue) - internal - view - returns (int256[] memory) - { - return keyExists(toml, key) ? readIntArray(toml, key) : defaultValue; - } - - function readBytes32Or(string memory toml, string memory key, bytes32 defaultValue) - internal - view - returns (bytes32) - { - return keyExists(toml, key) ? readBytes32(toml, key) : defaultValue; - } - - function readBytes32ArrayOr(string memory toml, string memory key, bytes32[] memory defaultValue) - internal - view - returns (bytes32[] memory) - { - return keyExists(toml, key) ? readBytes32Array(toml, key) : defaultValue; - } - - function readStringOr(string memory toml, string memory key, string memory defaultValue) - internal - view - returns (string memory) - { - return keyExists(toml, key) ? readString(toml, key) : defaultValue; - } - - function readStringArrayOr(string memory toml, string memory key, string[] memory defaultValue) - internal - view - returns (string[] memory) - { - return keyExists(toml, key) ? readStringArray(toml, key) : defaultValue; - } - - function readAddressOr(string memory toml, string memory key, address defaultValue) - internal - view - returns (address) - { - return keyExists(toml, key) ? readAddress(toml, key) : defaultValue; - } - - function readAddressArrayOr(string memory toml, string memory key, address[] memory defaultValue) - internal - view - returns (address[] memory) - { - return keyExists(toml, key) ? readAddressArray(toml, key) : defaultValue; - } - - function readBoolOr(string memory toml, string memory key, bool defaultValue) internal view returns (bool) { - return keyExists(toml, key) ? readBool(toml, key) : defaultValue; - } - - function readBoolArrayOr(string memory toml, string memory key, bool[] memory defaultValue) - internal - view - returns (bool[] memory) - { - return keyExists(toml, key) ? readBoolArray(toml, key) : defaultValue; - } - - function readBytesOr(string memory toml, string memory key, bytes memory defaultValue) - internal - view - returns (bytes memory) - { - return keyExists(toml, key) ? readBytes(toml, key) : defaultValue; - } - - function readBytesArrayOr(string memory toml, string memory key, bytes[] memory defaultValue) - internal - view - returns (bytes[] memory) - { - return keyExists(toml, key) ? readBytesArray(toml, key) : defaultValue; - } - - function serialize(string memory jsonKey, string memory rootObject) internal returns (string memory) { - return vm.serializeJson(jsonKey, rootObject); - } - - function serialize(string memory jsonKey, string memory key, bool value) internal returns (string memory) { - return vm.serializeBool(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bool[] memory value) - internal - returns (string memory) - { - return vm.serializeBool(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, uint256 value) internal returns (string memory) { - return vm.serializeUint(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, uint256[] memory value) - internal - returns (string memory) - { - return vm.serializeUint(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, int256 value) internal returns (string memory) { - return vm.serializeInt(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, int256[] memory value) - internal - returns (string memory) - { - return vm.serializeInt(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, address value) internal returns (string memory) { - return vm.serializeAddress(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, address[] memory value) - internal - returns (string memory) - { - return vm.serializeAddress(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes32 value) internal returns (string memory) { - return vm.serializeBytes32(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes32[] memory value) - internal - returns (string memory) - { - return vm.serializeBytes32(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes memory value) internal returns (string memory) { - return vm.serializeBytes(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, bytes[] memory value) - internal - returns (string memory) - { - return vm.serializeBytes(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, string memory value) - internal - returns (string memory) - { - return vm.serializeString(jsonKey, key, value); - } - - function serialize(string memory jsonKey, string memory key, string[] memory value) - internal - returns (string memory) - { - return vm.serializeString(jsonKey, key, value); - } - - function write(string memory jsonKey, string memory path) internal { - vm.writeToml(jsonKey, path); - } - - function write(string memory jsonKey, string memory path, string memory valueKey) internal { - vm.writeToml(jsonKey, path, valueKey); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdUtils.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdUtils.sol deleted file mode 100644 index 5d120439fe..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/StdUtils.sol +++ /dev/null @@ -1,226 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -import {IMulticall3} from "./interfaces/IMulticall3.sol"; -import {MockERC20} from "./mocks/MockERC20.sol"; -import {MockERC721} from "./mocks/MockERC721.sol"; -import {VmSafe} from "./Vm.sol"; - -abstract contract StdUtils { - /*////////////////////////////////////////////////////////////////////////// - CONSTANTS - //////////////////////////////////////////////////////////////////////////*/ - - IMulticall3 private constant multicall = IMulticall3(0xcA11bde05977b3631167028862bE2a173976CA11); - VmSafe private constant vm = VmSafe(address(uint160(uint256(keccak256("hevm cheat code"))))); - address private constant CONSOLE2_ADDRESS = 0x000000000000000000636F6e736F6c652e6c6f67; - uint256 private constant INT256_MIN_ABS = - 57896044618658097711785492504343953926634992332820282019728792003956564819968; - uint256 private constant SECP256K1_ORDER = - 115792089237316195423570985008687907852837564279074904382605163141518161494337; - uint256 private constant UINT256_MAX = - 115792089237316195423570985008687907853269984665640564039457584007913129639935; - - // Used by default when deploying with create2, https://github.com/Arachnid/deterministic-deployment-proxy. - address private constant CREATE2_FACTORY = 0x4e59b44847b379578588920cA78FbF26c0B4956C; - - /*////////////////////////////////////////////////////////////////////////// - INTERNAL FUNCTIONS - //////////////////////////////////////////////////////////////////////////*/ - - function _bound(uint256 x, uint256 min, uint256 max) internal pure virtual returns (uint256 result) { - require(min <= max, "StdUtils bound(uint256,uint256,uint256): Max is less than min."); - // If x is between min and max, return x directly. This is to ensure that dictionary values - // do not get shifted if the min is nonzero. More info: https://github.com/foundry-rs/forge-std/issues/188 - if (x >= min && x <= max) return x; - - uint256 size = max - min + 1; - - // If the value is 0, 1, 2, 3, wrap that to min, min+1, min+2, min+3. Similarly for the UINT256_MAX side. - // This helps ensure coverage of the min/max values. - if (x <= 3 && size > x) return min + x; - if (x >= UINT256_MAX - 3 && size > UINT256_MAX - x) return max - (UINT256_MAX - x); - - // Otherwise, wrap x into the range [min, max], i.e. the range is inclusive. - if (x > max) { - uint256 diff = x - max; - uint256 rem = diff % size; - if (rem == 0) return max; - result = min + rem - 1; - } else if (x < min) { - uint256 diff = min - x; - uint256 rem = diff % size; - if (rem == 0) return min; - result = max - rem + 1; - } - } - - function bound(uint256 x, uint256 min, uint256 max) internal pure virtual returns (uint256 result) { - result = _bound(x, min, max); - console2_log_StdUtils("Bound result", result); - } - - function _bound(int256 x, int256 min, int256 max) internal pure virtual returns (int256 result) { - require(min <= max, "StdUtils bound(int256,int256,int256): Max is less than min."); - - // Shifting all int256 values to uint256 to use _bound function. The range of two types are: - // int256 : -(2**255) ~ (2**255 - 1) - // uint256: 0 ~ (2**256 - 1) - // So, add 2**255, INT256_MIN_ABS to the integer values. - // - // If the given integer value is -2**255, we cannot use `-uint256(-x)` because of the overflow. - // So, use `~uint256(x) + 1` instead. - uint256 _x = x < 0 ? (INT256_MIN_ABS - ~uint256(x) - 1) : (uint256(x) + INT256_MIN_ABS); - uint256 _min = min < 0 ? (INT256_MIN_ABS - ~uint256(min) - 1) : (uint256(min) + INT256_MIN_ABS); - uint256 _max = max < 0 ? (INT256_MIN_ABS - ~uint256(max) - 1) : (uint256(max) + INT256_MIN_ABS); - - uint256 y = _bound(_x, _min, _max); - - // To move it back to int256 value, subtract INT256_MIN_ABS at here. - result = y < INT256_MIN_ABS ? int256(~(INT256_MIN_ABS - y) + 1) : int256(y - INT256_MIN_ABS); - } - - function bound(int256 x, int256 min, int256 max) internal pure virtual returns (int256 result) { - result = _bound(x, min, max); - console2_log_StdUtils("Bound result", vm.toString(result)); - } - - function boundPrivateKey(uint256 privateKey) internal pure virtual returns (uint256 result) { - result = _bound(privateKey, 1, SECP256K1_ORDER - 1); - } - - function bytesToUint(bytes memory b) internal pure virtual returns (uint256) { - require(b.length <= 32, "StdUtils bytesToUint(bytes): Bytes length exceeds 32."); - return abi.decode(abi.encodePacked(new bytes(32 - b.length), b), (uint256)); - } - - /// @dev Compute the address a contract will be deployed at for a given deployer address and nonce - /// @notice adapted from Solmate implementation (https://github.com/Rari-Capital/solmate/blob/main/src/utils/LibRLP.sol) - function computeCreateAddress(address deployer, uint256 nonce) internal pure virtual returns (address) { - console2_log_StdUtils("computeCreateAddress is deprecated. Please use vm.computeCreateAddress instead."); - return vm.computeCreateAddress(deployer, nonce); - } - - function computeCreate2Address(bytes32 salt, bytes32 initcodeHash, address deployer) - internal - pure - virtual - returns (address) - { - console2_log_StdUtils("computeCreate2Address is deprecated. Please use vm.computeCreate2Address instead."); - return vm.computeCreate2Address(salt, initcodeHash, deployer); - } - - /// @dev returns the address of a contract created with CREATE2 using the default CREATE2 deployer - function computeCreate2Address(bytes32 salt, bytes32 initCodeHash) internal pure returns (address) { - console2_log_StdUtils("computeCreate2Address is deprecated. Please use vm.computeCreate2Address instead."); - return vm.computeCreate2Address(salt, initCodeHash); - } - - /// @dev returns an initialized mock ERC20 contract - function deployMockERC20(string memory name, string memory symbol, uint8 decimals) - internal - returns (MockERC20 mock) - { - mock = new MockERC20(); - mock.initialize(name, symbol, decimals); - } - - /// @dev returns an initialized mock ERC721 contract - function deployMockERC721(string memory name, string memory symbol) internal returns (MockERC721 mock) { - mock = new MockERC721(); - mock.initialize(name, symbol); - } - - /// @dev returns the hash of the init code (creation code + no args) used in CREATE2 with no constructor arguments - /// @param creationCode the creation code of a contract C, as returned by type(C).creationCode - function hashInitCode(bytes memory creationCode) internal pure returns (bytes32) { - return hashInitCode(creationCode, ""); - } - - /// @dev returns the hash of the init code (creation code + ABI-encoded args) used in CREATE2 - /// @param creationCode the creation code of a contract C, as returned by type(C).creationCode - /// @param args the ABI-encoded arguments to the constructor of C - function hashInitCode(bytes memory creationCode, bytes memory args) internal pure returns (bytes32) { - return keccak256(abi.encodePacked(creationCode, args)); - } - - // Performs a single call with Multicall3 to query the ERC-20 token balances of the given addresses. - function getTokenBalances(address token, address[] memory addresses) - internal - virtual - returns (uint256[] memory balances) - { - uint256 tokenCodeSize; - assembly { - tokenCodeSize := extcodesize(token) - } - require(tokenCodeSize > 0, "StdUtils getTokenBalances(address,address[]): Token address is not a contract."); - - // ABI encode the aggregate call to Multicall3. - uint256 length = addresses.length; - IMulticall3.Call[] memory calls = new IMulticall3.Call[](length); - for (uint256 i = 0; i < length; ++i) { - // 0x70a08231 = bytes4("balanceOf(address)")) - calls[i] = IMulticall3.Call({target: token, callData: abi.encodeWithSelector(0x70a08231, (addresses[i]))}); - } - - // Make the aggregate call. - (, bytes[] memory returnData) = multicall.aggregate(calls); - - // ABI decode the return data and return the balances. - balances = new uint256[](length); - for (uint256 i = 0; i < length; ++i) { - balances[i] = abi.decode(returnData[i], (uint256)); - } - } - - /*////////////////////////////////////////////////////////////////////////// - PRIVATE FUNCTIONS - //////////////////////////////////////////////////////////////////////////*/ - - function addressFromLast20Bytes(bytes32 bytesValue) private pure returns (address) { - return address(uint160(uint256(bytesValue))); - } - - // This section is used to prevent the compilation of console, which shortens the compilation time when console is - // not used elsewhere. We also trick the compiler into letting us make the console log methods as `pure` to avoid - // any breaking changes to function signatures. - function _castLogPayloadViewToPure(function(bytes memory) internal view fnIn) - internal - pure - returns (function(bytes memory) internal pure fnOut) - { - assembly { - fnOut := fnIn - } - } - - function _sendLogPayload(bytes memory payload) internal pure { - _castLogPayloadViewToPure(_sendLogPayloadView)(payload); - } - - function _sendLogPayloadView(bytes memory payload) private view { - uint256 payloadLength = payload.length; - address consoleAddress = CONSOLE2_ADDRESS; - /// @solidity memory-safe-assembly - assembly { - let payloadStart := add(payload, 32) - let r := staticcall(gas(), consoleAddress, payloadStart, payloadLength, 0, 0) - } - } - - function console2_log_StdUtils(string memory p0) private pure { - _sendLogPayload(abi.encodeWithSignature("log(string)", p0)); - } - - function console2_log_StdUtils(string memory p0, uint256 p1) private pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256)", p0, p1)); - } - - function console2_log_StdUtils(string memory p0, string memory p1) private pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string)", p0, p1)); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/Test.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/Test.sol deleted file mode 100644 index 5ff60ea3f6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/Test.sol +++ /dev/null @@ -1,33 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -// 💬 ABOUT -// Forge Std's default Test. - -// 🧩 MODULES -import {console} from "./console.sol"; -import {console2} from "./console2.sol"; -import {safeconsole} from "./safeconsole.sol"; -import {StdAssertions} from "./StdAssertions.sol"; -import {StdChains} from "./StdChains.sol"; -import {StdCheats} from "./StdCheats.sol"; -import {stdError} from "./StdError.sol"; -import {StdInvariant} from "./StdInvariant.sol"; -import {stdJson} from "./StdJson.sol"; -import {stdMath} from "./StdMath.sol"; -import {StdStorage, stdStorage} from "./StdStorage.sol"; -import {StdStyle} from "./StdStyle.sol"; -import {stdToml} from "./StdToml.sol"; -import {StdUtils} from "./StdUtils.sol"; -import {Vm} from "./Vm.sol"; - -// 📦 BOILERPLATE -import {TestBase} from "./Base.sol"; - -// ⭐️ TEST -abstract contract Test is TestBase, StdAssertions, StdChains, StdCheats, StdInvariant, StdUtils { - // Note: IS_TEST() must return true. - bool public IS_TEST = true; -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/Vm.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/Vm.sol deleted file mode 100644 index 591508c097..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/Vm.sol +++ /dev/null @@ -1,1968 +0,0 @@ -// Automatically @generated by scripts/vm.py. Do not modify manually. - -// SPDX-License-Identifier: MIT OR Apache-2.0 -pragma solidity >=0.6.2 <0.9.0; -pragma experimental ABIEncoderV2; - -/// The `VmSafe` interface does not allow manipulation of the EVM state or other actions that may -/// result in Script simulations differing from on-chain execution. It is recommended to only use -/// these cheats in scripts. -interface VmSafe { - /// A modification applied to either `msg.sender` or `tx.origin`. Returned by `readCallers`. - enum CallerMode { - // No caller modification is currently active. - None, - // A one time broadcast triggered by a `vm.broadcast()` call is currently active. - Broadcast, - // A recurrent broadcast triggered by a `vm.startBroadcast()` call is currently active. - RecurrentBroadcast, - // A one time prank triggered by a `vm.prank()` call is currently active. - Prank, - // A recurrent prank triggered by a `vm.startPrank()` call is currently active. - RecurrentPrank - } - - /// The kind of account access that occurred. - enum AccountAccessKind { - // The account was called. - Call, - // The account was called via delegatecall. - DelegateCall, - // The account was called via callcode. - CallCode, - // The account was called via staticcall. - StaticCall, - // The account was created. - Create, - // The account was selfdestructed. - SelfDestruct, - // Synthetic access indicating the current context has resumed after a previous sub-context (AccountAccess). - Resume, - // The account's balance was read. - Balance, - // The account's codesize was read. - Extcodesize, - // The account's codehash was read. - Extcodehash, - // The account's code was copied. - Extcodecopy - } - - /// Forge execution contexts. - enum ForgeContext { - // Test group execution context (test, coverage or snapshot). - TestGroup, - // `forge test` execution context. - Test, - // `forge coverage` execution context. - Coverage, - // `forge snapshot` execution context. - Snapshot, - // Script group execution context (dry run, broadcast or resume). - ScriptGroup, - // `forge script` execution context. - ScriptDryRun, - // `forge script --broadcast` execution context. - ScriptBroadcast, - // `forge script --resume` execution context. - ScriptResume, - // Unknown `forge` execution context. - Unknown - } - - /// An Ethereum log. Returned by `getRecordedLogs`. - struct Log { - // The topics of the log, including the signature, if any. - bytes32[] topics; - // The raw data of the log. - bytes data; - // The address of the log's emitter. - address emitter; - } - - /// An RPC URL and its alias. Returned by `rpcUrlStructs`. - struct Rpc { - // The alias of the RPC URL. - string key; - // The RPC URL. - string url; - } - - /// An RPC log object. Returned by `eth_getLogs`. - struct EthGetLogs { - // The address of the log's emitter. - address emitter; - // The topics of the log, including the signature, if any. - bytes32[] topics; - // The raw data of the log. - bytes data; - // The block hash. - bytes32 blockHash; - // The block number. - uint64 blockNumber; - // The transaction hash. - bytes32 transactionHash; - // The transaction index in the block. - uint64 transactionIndex; - // The log index. - uint256 logIndex; - // Whether the log was removed. - bool removed; - } - - /// A single entry in a directory listing. Returned by `readDir`. - struct DirEntry { - // The error message, if any. - string errorMessage; - // The path of the entry. - string path; - // The depth of the entry. - uint64 depth; - // Whether the entry is a directory. - bool isDir; - // Whether the entry is a symlink. - bool isSymlink; - } - - /// Metadata information about a file. - /// This structure is returned from the `fsMetadata` function and represents known - /// metadata about a file such as its permissions, size, modification - /// times, etc. - struct FsMetadata { - // True if this metadata is for a directory. - bool isDir; - // True if this metadata is for a symlink. - bool isSymlink; - // The size of the file, in bytes, this metadata is for. - uint256 length; - // True if this metadata is for a readonly (unwritable) file. - bool readOnly; - // The last modification time listed in this metadata. - uint256 modified; - // The last access time of this metadata. - uint256 accessed; - // The creation time listed in this metadata. - uint256 created; - } - - /// A wallet with a public and private key. - struct Wallet { - // The wallet's address. - address addr; - // The wallet's public key `X`. - uint256 publicKeyX; - // The wallet's public key `Y`. - uint256 publicKeyY; - // The wallet's private key. - uint256 privateKey; - } - - /// The result of a `tryFfi` call. - struct FfiResult { - // The exit code of the call. - int32 exitCode; - // The optionally hex-decoded `stdout` data. - bytes stdout; - // The `stderr` data. - bytes stderr; - } - - /// Information on the chain and fork. - struct ChainInfo { - // The fork identifier. Set to zero if no fork is active. - uint256 forkId; - // The chain ID of the current fork. - uint256 chainId; - } - - /// The result of a `stopAndReturnStateDiff` call. - struct AccountAccess { - // The chain and fork the access occurred. - ChainInfo chainInfo; - // The kind of account access that determines what the account is. - // If kind is Call, DelegateCall, StaticCall or CallCode, then the account is the callee. - // If kind is Create, then the account is the newly created account. - // If kind is SelfDestruct, then the account is the selfdestruct recipient. - // If kind is a Resume, then account represents a account context that has resumed. - AccountAccessKind kind; - // The account that was accessed. - // It's either the account created, callee or a selfdestruct recipient for CREATE, CALL or SELFDESTRUCT. - address account; - // What accessed the account. - address accessor; - // If the account was initialized or empty prior to the access. - // An account is considered initialized if it has code, a - // non-zero nonce, or a non-zero balance. - bool initialized; - // The previous balance of the accessed account. - uint256 oldBalance; - // The potential new balance of the accessed account. - // That is, all balance changes are recorded here, even if reverts occurred. - uint256 newBalance; - // Code of the account deployed by CREATE. - bytes deployedCode; - // Value passed along with the account access - uint256 value; - // Input data provided to the CREATE or CALL - bytes data; - // If this access reverted in either the current or parent context. - bool reverted; - // An ordered list of storage accesses made during an account access operation. - StorageAccess[] storageAccesses; - // Call depth traversed during the recording of state differences - uint64 depth; - } - - /// The storage accessed during an `AccountAccess`. - struct StorageAccess { - // The account whose storage was accessed. - address account; - // The slot that was accessed. - bytes32 slot; - // If the access was a write. - bool isWrite; - // The previous value of the slot. - bytes32 previousValue; - // The new value of the slot. - bytes32 newValue; - // If the access was reverted. - bool reverted; - } - - /// Gas used. Returned by `lastCallGas`. - struct Gas { - // The gas limit of the call. - uint64 gasLimit; - // The total gas used. - uint64 gasTotalUsed; - // DEPRECATED: The amount of gas used for memory expansion. Ref: - uint64 gasMemoryUsed; - // The amount of gas refunded. - int64 gasRefunded; - // The amount of gas remaining. - uint64 gasRemaining; - } - - // ======== Crypto ======== - - /// Derives a private key from the name, labels the account with that name, and returns the wallet. - function createWallet(string calldata walletLabel) external returns (Wallet memory wallet); - - /// Generates a wallet from the private key and returns the wallet. - function createWallet(uint256 privateKey) external returns (Wallet memory wallet); - - /// Generates a wallet from the private key, labels the account with that name, and returns the wallet. - function createWallet(uint256 privateKey, string calldata walletLabel) external returns (Wallet memory wallet); - - /// Derive a private key from a provided mnenomic string (or mnenomic file path) - /// at the derivation path `m/44'/60'/0'/0/{index}`. - function deriveKey(string calldata mnemonic, uint32 index) external pure returns (uint256 privateKey); - - /// Derive a private key from a provided mnenomic string (or mnenomic file path) - /// at `{derivationPath}{index}`. - function deriveKey(string calldata mnemonic, string calldata derivationPath, uint32 index) - external - pure - returns (uint256 privateKey); - - /// Derive a private key from a provided mnenomic string (or mnenomic file path) in the specified language - /// at the derivation path `m/44'/60'/0'/0/{index}`. - function deriveKey(string calldata mnemonic, uint32 index, string calldata language) - external - pure - returns (uint256 privateKey); - - /// Derive a private key from a provided mnenomic string (or mnenomic file path) in the specified language - /// at `{derivationPath}{index}`. - function deriveKey(string calldata mnemonic, string calldata derivationPath, uint32 index, string calldata language) - external - pure - returns (uint256 privateKey); - - /// Derives secp256r1 public key from the provided `privateKey`. - function publicKeyP256(uint256 privateKey) external pure returns (uint256 publicKeyX, uint256 publicKeyY); - - /// Adds a private key to the local forge wallet and returns the address. - function rememberKey(uint256 privateKey) external returns (address keyAddr); - - /// Signs data with a `Wallet`. - /// Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the - /// signature's `s` value, and the recovery id `v` in a single bytes32. - /// This format reduces the signature size from 65 to 64 bytes. - function signCompact(Wallet calldata wallet, bytes32 digest) external returns (bytes32 r, bytes32 vs); - - /// Signs `digest` with `privateKey` using the secp256k1 curve. - /// Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the - /// signature's `s` value, and the recovery id `v` in a single bytes32. - /// This format reduces the signature size from 65 to 64 bytes. - function signCompact(uint256 privateKey, bytes32 digest) external pure returns (bytes32 r, bytes32 vs); - - /// Signs `digest` with signer provided to script using the secp256k1 curve. - /// Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the - /// signature's `s` value, and the recovery id `v` in a single bytes32. - /// This format reduces the signature size from 65 to 64 bytes. - /// If `--sender` is provided, the signer with provided address is used, otherwise, - /// if exactly one signer is provided to the script, that signer is used. - /// Raises error if signer passed through `--sender` does not match any unlocked signers or - /// if `--sender` is not provided and not exactly one signer is passed to the script. - function signCompact(bytes32 digest) external pure returns (bytes32 r, bytes32 vs); - - /// Signs `digest` with signer provided to script using the secp256k1 curve. - /// Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the - /// signature's `s` value, and the recovery id `v` in a single bytes32. - /// This format reduces the signature size from 65 to 64 bytes. - /// Raises error if none of the signers passed into the script have provided address. - function signCompact(address signer, bytes32 digest) external pure returns (bytes32 r, bytes32 vs); - - /// Signs `digest` with `privateKey` using the secp256r1 curve. - function signP256(uint256 privateKey, bytes32 digest) external pure returns (bytes32 r, bytes32 s); - - /// Signs data with a `Wallet`. - function sign(Wallet calldata wallet, bytes32 digest) external returns (uint8 v, bytes32 r, bytes32 s); - - /// Signs `digest` with `privateKey` using the secp256k1 curve. - function sign(uint256 privateKey, bytes32 digest) external pure returns (uint8 v, bytes32 r, bytes32 s); - - /// Signs `digest` with signer provided to script using the secp256k1 curve. - /// If `--sender` is provided, the signer with provided address is used, otherwise, - /// if exactly one signer is provided to the script, that signer is used. - /// Raises error if signer passed through `--sender` does not match any unlocked signers or - /// if `--sender` is not provided and not exactly one signer is passed to the script. - function sign(bytes32 digest) external pure returns (uint8 v, bytes32 r, bytes32 s); - - /// Signs `digest` with signer provided to script using the secp256k1 curve. - /// Raises error if none of the signers passed into the script have provided address. - function sign(address signer, bytes32 digest) external pure returns (uint8 v, bytes32 r, bytes32 s); - - // ======== Environment ======== - - /// Gets the environment variable `name` and parses it as `address`. - /// Reverts if the variable was not found or could not be parsed. - function envAddress(string calldata name) external view returns (address value); - - /// Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envAddress(string calldata name, string calldata delim) external view returns (address[] memory value); - - /// Gets the environment variable `name` and parses it as `bool`. - /// Reverts if the variable was not found or could not be parsed. - function envBool(string calldata name) external view returns (bool value); - - /// Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envBool(string calldata name, string calldata delim) external view returns (bool[] memory value); - - /// Gets the environment variable `name` and parses it as `bytes32`. - /// Reverts if the variable was not found or could not be parsed. - function envBytes32(string calldata name) external view returns (bytes32 value); - - /// Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envBytes32(string calldata name, string calldata delim) external view returns (bytes32[] memory value); - - /// Gets the environment variable `name` and parses it as `bytes`. - /// Reverts if the variable was not found or could not be parsed. - function envBytes(string calldata name) external view returns (bytes memory value); - - /// Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envBytes(string calldata name, string calldata delim) external view returns (bytes[] memory value); - - /// Gets the environment variable `name` and returns true if it exists, else returns false. - function envExists(string calldata name) external view returns (bool result); - - /// Gets the environment variable `name` and parses it as `int256`. - /// Reverts if the variable was not found or could not be parsed. - function envInt(string calldata name) external view returns (int256 value); - - /// Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envInt(string calldata name, string calldata delim) external view returns (int256[] memory value); - - /// Gets the environment variable `name` and parses it as `bool`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, bool defaultValue) external view returns (bool value); - - /// Gets the environment variable `name` and parses it as `uint256`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, uint256 defaultValue) external view returns (uint256 value); - - /// Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, address[] calldata defaultValue) - external - view - returns (address[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, bytes32[] calldata defaultValue) - external - view - returns (bytes32[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, string[] calldata defaultValue) - external - view - returns (string[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, bytes[] calldata defaultValue) - external - view - returns (bytes[] memory value); - - /// Gets the environment variable `name` and parses it as `int256`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, int256 defaultValue) external view returns (int256 value); - - /// Gets the environment variable `name` and parses it as `address`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, address defaultValue) external view returns (address value); - - /// Gets the environment variable `name` and parses it as `bytes32`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, bytes32 defaultValue) external view returns (bytes32 value); - - /// Gets the environment variable `name` and parses it as `string`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata defaultValue) external view returns (string memory value); - - /// Gets the environment variable `name` and parses it as `bytes`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, bytes calldata defaultValue) external view returns (bytes memory value); - - /// Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, bool[] calldata defaultValue) - external - view - returns (bool[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, uint256[] calldata defaultValue) - external - view - returns (uint256[] memory value); - - /// Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. - /// Reverts if the variable could not be parsed. - /// Returns `defaultValue` if the variable was not found. - function envOr(string calldata name, string calldata delim, int256[] calldata defaultValue) - external - view - returns (int256[] memory value); - - /// Gets the environment variable `name` and parses it as `string`. - /// Reverts if the variable was not found or could not be parsed. - function envString(string calldata name) external view returns (string memory value); - - /// Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envString(string calldata name, string calldata delim) external view returns (string[] memory value); - - /// Gets the environment variable `name` and parses it as `uint256`. - /// Reverts if the variable was not found or could not be parsed. - function envUint(string calldata name) external view returns (uint256 value); - - /// Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. - /// Reverts if the variable was not found or could not be parsed. - function envUint(string calldata name, string calldata delim) external view returns (uint256[] memory value); - - /// Returns true if `forge` command was executed in given context. - function isContext(ForgeContext context) external view returns (bool result); - - /// Sets environment variables. - function setEnv(string calldata name, string calldata value) external; - - // ======== EVM ======== - - /// Gets all accessed reads and write slot from a `vm.record` session, for a given address. - function accesses(address target) external returns (bytes32[] memory readSlots, bytes32[] memory writeSlots); - - /// Gets the address for a given private key. - function addr(uint256 privateKey) external pure returns (address keyAddr); - - /// Gets all the logs according to specified filter. - function eth_getLogs(uint256 fromBlock, uint256 toBlock, address target, bytes32[] calldata topics) - external - returns (EthGetLogs[] memory logs); - - /// Gets the current `block.blobbasefee`. - /// You should use this instead of `block.blobbasefee` if you use `vm.blobBaseFee`, as `block.blobbasefee` is assumed to be constant across a transaction, - /// and as a result will get optimized out by the compiler. - /// See https://github.com/foundry-rs/foundry/issues/6180 - function getBlobBaseFee() external view returns (uint256 blobBaseFee); - - /// Gets the current `block.number`. - /// You should use this instead of `block.number` if you use `vm.roll`, as `block.number` is assumed to be constant across a transaction, - /// and as a result will get optimized out by the compiler. - /// See https://github.com/foundry-rs/foundry/issues/6180 - function getBlockNumber() external view returns (uint256 height); - - /// Gets the current `block.timestamp`. - /// You should use this instead of `block.timestamp` if you use `vm.warp`, as `block.timestamp` is assumed to be constant across a transaction, - /// and as a result will get optimized out by the compiler. - /// See https://github.com/foundry-rs/foundry/issues/6180 - function getBlockTimestamp() external view returns (uint256 timestamp); - - /// Gets the map key and parent of a mapping at a given slot, for a given address. - function getMappingKeyAndParentOf(address target, bytes32 elementSlot) - external - returns (bool found, bytes32 key, bytes32 parent); - - /// Gets the number of elements in the mapping at the given slot, for a given address. - function getMappingLength(address target, bytes32 mappingSlot) external returns (uint256 length); - - /// Gets the elements at index idx of the mapping at the given slot, for a given address. The - /// index must be less than the length of the mapping (i.e. the number of keys in the mapping). - function getMappingSlotAt(address target, bytes32 mappingSlot, uint256 idx) external returns (bytes32 value); - - /// Gets the nonce of an account. - function getNonce(address account) external view returns (uint64 nonce); - - /// Get the nonce of a `Wallet`. - function getNonce(Wallet calldata wallet) external returns (uint64 nonce); - - /// Gets all the recorded logs. - function getRecordedLogs() external returns (Log[] memory logs); - - /// Gets the gas used in the last call. - function lastCallGas() external view returns (Gas memory gas); - - /// Loads a storage slot from an address. - function load(address target, bytes32 slot) external view returns (bytes32 data); - - /// Pauses gas metering (i.e. gas usage is not counted). Noop if already paused. - function pauseGasMetering() external; - - /// Records all storage reads and writes. - function record() external; - - /// Record all the transaction logs. - function recordLogs() external; - - /// Reset gas metering (i.e. gas usage is set to gas limit). - function resetGasMetering() external; - - /// Resumes gas metering (i.e. gas usage is counted again). Noop if already on. - function resumeGasMetering() external; - - /// Performs an Ethereum JSON-RPC request to the current fork URL. - function rpc(string calldata method, string calldata params) external returns (bytes memory data); - - /// Performs an Ethereum JSON-RPC request to the given endpoint. - function rpc(string calldata urlOrAlias, string calldata method, string calldata params) - external - returns (bytes memory data); - - /// Starts recording all map SSTOREs for later retrieval. - function startMappingRecording() external; - - /// Record all account accesses as part of CREATE, CALL or SELFDESTRUCT opcodes in order, - /// along with the context of the calls - function startStateDiffRecording() external; - - /// Returns an ordered array of all account accesses from a `vm.startStateDiffRecording` session. - function stopAndReturnStateDiff() external returns (AccountAccess[] memory accountAccesses); - - /// Stops recording all map SSTOREs for later retrieval and clears the recorded data. - function stopMappingRecording() external; - - // ======== Filesystem ======== - - /// Closes file for reading, resetting the offset and allowing to read it from beginning with readLine. - /// `path` is relative to the project root. - function closeFile(string calldata path) external; - - /// Copies the contents of one file to another. This function will **overwrite** the contents of `to`. - /// On success, the total number of bytes copied is returned and it is equal to the length of the `to` file as reported by `metadata`. - /// Both `from` and `to` are relative to the project root. - function copyFile(string calldata from, string calldata to) external returns (uint64 copied); - - /// Creates a new, empty directory at the provided path. - /// This cheatcode will revert in the following situations, but is not limited to just these cases: - /// - User lacks permissions to modify `path`. - /// - A parent of the given path doesn't exist and `recursive` is false. - /// - `path` already exists and `recursive` is false. - /// `path` is relative to the project root. - function createDir(string calldata path, bool recursive) external; - - /// Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - function deployCode(string calldata artifactPath) external returns (address deployedAddress); - - /// Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - /// Additionally accepts abi-encoded constructor arguments. - function deployCode(string calldata artifactPath, bytes calldata constructorArgs) - external - returns (address deployedAddress); - - /// Returns true if the given path points to an existing entity, else returns false. - function exists(string calldata path) external returns (bool result); - - /// Performs a foreign function call via the terminal. - function ffi(string[] calldata commandInput) external returns (bytes memory result); - - /// Given a path, query the file system to get information about a file, directory, etc. - function fsMetadata(string calldata path) external view returns (FsMetadata memory metadata); - - /// Gets the artifact path from code (aka. creation code). - function getArtifactPathByCode(bytes calldata code) external view returns (string memory path); - - /// Gets the artifact path from deployed code (aka. runtime code). - function getArtifactPathByDeployedCode(bytes calldata deployedCode) external view returns (string memory path); - - /// Gets the creation bytecode from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - function getCode(string calldata artifactPath) external view returns (bytes memory creationBytecode); - - /// Gets the deployed bytecode from an artifact file. Takes in the relative path to the json file or the path to the - /// artifact in the form of :: where and parts are optional. - function getDeployedCode(string calldata artifactPath) external view returns (bytes memory runtimeBytecode); - - /// Returns true if the path exists on disk and is pointing at a directory, else returns false. - function isDir(string calldata path) external returns (bool result); - - /// Returns true if the path exists on disk and is pointing at a regular file, else returns false. - function isFile(string calldata path) external returns (bool result); - - /// Get the path of the current project root. - function projectRoot() external view returns (string memory path); - - /// Prompts the user for a string value in the terminal. - function prompt(string calldata promptText) external returns (string memory input); - - /// Prompts the user for an address in the terminal. - function promptAddress(string calldata promptText) external returns (address); - - /// Prompts the user for a hidden string value in the terminal. - function promptSecret(string calldata promptText) external returns (string memory input); - - /// Prompts the user for hidden uint256 in the terminal (usually pk). - function promptSecretUint(string calldata promptText) external returns (uint256); - - /// Prompts the user for uint256 in the terminal. - function promptUint(string calldata promptText) external returns (uint256); - - /// Reads the directory at the given path recursively, up to `maxDepth`. - /// `maxDepth` defaults to 1, meaning only the direct children of the given directory will be returned. - /// Follows symbolic links if `followLinks` is true. - function readDir(string calldata path) external view returns (DirEntry[] memory entries); - - /// See `readDir(string)`. - function readDir(string calldata path, uint64 maxDepth) external view returns (DirEntry[] memory entries); - - /// See `readDir(string)`. - function readDir(string calldata path, uint64 maxDepth, bool followLinks) - external - view - returns (DirEntry[] memory entries); - - /// Reads the entire content of file to string. `path` is relative to the project root. - function readFile(string calldata path) external view returns (string memory data); - - /// Reads the entire content of file as binary. `path` is relative to the project root. - function readFileBinary(string calldata path) external view returns (bytes memory data); - - /// Reads next line of file to string. - function readLine(string calldata path) external view returns (string memory line); - - /// Reads a symbolic link, returning the path that the link points to. - /// This cheatcode will revert in the following situations, but is not limited to just these cases: - /// - `path` is not a symbolic link. - /// - `path` does not exist. - function readLink(string calldata linkPath) external view returns (string memory targetPath); - - /// Removes a directory at the provided path. - /// This cheatcode will revert in the following situations, but is not limited to just these cases: - /// - `path` doesn't exist. - /// - `path` isn't a directory. - /// - User lacks permissions to modify `path`. - /// - The directory is not empty and `recursive` is false. - /// `path` is relative to the project root. - function removeDir(string calldata path, bool recursive) external; - - /// Removes a file from the filesystem. - /// This cheatcode will revert in the following situations, but is not limited to just these cases: - /// - `path` points to a directory. - /// - The file doesn't exist. - /// - The user lacks permissions to remove the file. - /// `path` is relative to the project root. - function removeFile(string calldata path) external; - - /// Performs a foreign function call via terminal and returns the exit code, stdout, and stderr. - function tryFfi(string[] calldata commandInput) external returns (FfiResult memory result); - - /// Returns the time since unix epoch in milliseconds. - function unixTime() external returns (uint256 milliseconds); - - /// Writes data to file, creating a file if it does not exist, and entirely replacing its contents if it does. - /// `path` is relative to the project root. - function writeFile(string calldata path, string calldata data) external; - - /// Writes binary data to a file, creating a file if it does not exist, and entirely replacing its contents if it does. - /// `path` is relative to the project root. - function writeFileBinary(string calldata path, bytes calldata data) external; - - /// Writes line to file, creating a file if it does not exist. - /// `path` is relative to the project root. - function writeLine(string calldata path, string calldata data) external; - - // ======== JSON ======== - - /// Checks if `key` exists in a JSON object. - function keyExistsJson(string calldata json, string calldata key) external view returns (bool); - - /// Parses a string of JSON data at `key` and coerces it to `address`. - function parseJsonAddress(string calldata json, string calldata key) external pure returns (address); - - /// Parses a string of JSON data at `key` and coerces it to `address[]`. - function parseJsonAddressArray(string calldata json, string calldata key) - external - pure - returns (address[] memory); - - /// Parses a string of JSON data at `key` and coerces it to `bool`. - function parseJsonBool(string calldata json, string calldata key) external pure returns (bool); - - /// Parses a string of JSON data at `key` and coerces it to `bool[]`. - function parseJsonBoolArray(string calldata json, string calldata key) external pure returns (bool[] memory); - - /// Parses a string of JSON data at `key` and coerces it to `bytes`. - function parseJsonBytes(string calldata json, string calldata key) external pure returns (bytes memory); - - /// Parses a string of JSON data at `key` and coerces it to `bytes32`. - function parseJsonBytes32(string calldata json, string calldata key) external pure returns (bytes32); - - /// Parses a string of JSON data at `key` and coerces it to `bytes32[]`. - function parseJsonBytes32Array(string calldata json, string calldata key) - external - pure - returns (bytes32[] memory); - - /// Parses a string of JSON data at `key` and coerces it to `bytes[]`. - function parseJsonBytesArray(string calldata json, string calldata key) external pure returns (bytes[] memory); - - /// Parses a string of JSON data at `key` and coerces it to `int256`. - function parseJsonInt(string calldata json, string calldata key) external pure returns (int256); - - /// Parses a string of JSON data at `key` and coerces it to `int256[]`. - function parseJsonIntArray(string calldata json, string calldata key) external pure returns (int256[] memory); - - /// Returns an array of all the keys in a JSON object. - function parseJsonKeys(string calldata json, string calldata key) external pure returns (string[] memory keys); - - /// Parses a string of JSON data at `key` and coerces it to `string`. - function parseJsonString(string calldata json, string calldata key) external pure returns (string memory); - - /// Parses a string of JSON data at `key` and coerces it to `string[]`. - function parseJsonStringArray(string calldata json, string calldata key) external pure returns (string[] memory); - - /// Parses a string of JSON data at `key` and coerces it to type array corresponding to `typeDescription`. - function parseJsonTypeArray(string calldata json, string calldata key, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of JSON data and coerces it to type corresponding to `typeDescription`. - function parseJsonType(string calldata json, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of JSON data at `key` and coerces it to type corresponding to `typeDescription`. - function parseJsonType(string calldata json, string calldata key, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of JSON data at `key` and coerces it to `uint256`. - function parseJsonUint(string calldata json, string calldata key) external pure returns (uint256); - - /// Parses a string of JSON data at `key` and coerces it to `uint256[]`. - function parseJsonUintArray(string calldata json, string calldata key) external pure returns (uint256[] memory); - - /// ABI-encodes a JSON object. - function parseJson(string calldata json) external pure returns (bytes memory abiEncodedData); - - /// ABI-encodes a JSON object at `key`. - function parseJson(string calldata json, string calldata key) external pure returns (bytes memory abiEncodedData); - - /// See `serializeJson`. - function serializeAddress(string calldata objectKey, string calldata valueKey, address value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeAddress(string calldata objectKey, string calldata valueKey, address[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBool(string calldata objectKey, string calldata valueKey, bool value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBool(string calldata objectKey, string calldata valueKey, bool[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBytes32(string calldata objectKey, string calldata valueKey, bytes32 value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBytes32(string calldata objectKey, string calldata valueKey, bytes32[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBytes(string calldata objectKey, string calldata valueKey, bytes calldata value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeBytes(string calldata objectKey, string calldata valueKey, bytes[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeInt(string calldata objectKey, string calldata valueKey, int256 value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeInt(string calldata objectKey, string calldata valueKey, int256[] calldata values) - external - returns (string memory json); - - /// Serializes a key and value to a JSON object stored in-memory that can be later written to a file. - /// Returns the stringified version of the specific JSON file up to that moment. - function serializeJson(string calldata objectKey, string calldata value) external returns (string memory json); - - /// See `serializeJson`. - function serializeJsonType(string calldata typeDescription, bytes calldata value) - external - pure - returns (string memory json); - - /// See `serializeJson`. - function serializeJsonType( - string calldata objectKey, - string calldata valueKey, - string calldata typeDescription, - bytes calldata value - ) external returns (string memory json); - - /// See `serializeJson`. - function serializeString(string calldata objectKey, string calldata valueKey, string calldata value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeString(string calldata objectKey, string calldata valueKey, string[] calldata values) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeUintToHex(string calldata objectKey, string calldata valueKey, uint256 value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeUint(string calldata objectKey, string calldata valueKey, uint256 value) - external - returns (string memory json); - - /// See `serializeJson`. - function serializeUint(string calldata objectKey, string calldata valueKey, uint256[] calldata values) - external - returns (string memory json); - - /// Write a serialized JSON object to a file. If the file exists, it will be overwritten. - function writeJson(string calldata json, string calldata path) external; - - /// Write a serialized JSON object to an **existing** JSON file, replacing a value with key = - /// This is useful to replace a specific value of a JSON file, without having to parse the entire thing. - function writeJson(string calldata json, string calldata path, string calldata valueKey) external; - - /// Checks if `key` exists in a JSON object - /// `keyExists` is being deprecated in favor of `keyExistsJson`. It will be removed in future versions. - function keyExists(string calldata json, string calldata key) external view returns (bool); - - // ======== Scripting ======== - - /// Takes a signed transaction and broadcasts it to the network. - function broadcastRawTransaction(bytes calldata data) external; - - /// Has the next call (at this call depth only) create transactions that can later be signed and sent onchain. - /// Broadcasting address is determined by checking the following in order: - /// 1. If `--sender` argument was provided, that address is used. - /// 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. - /// 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used. - function broadcast() external; - - /// Has the next call (at this call depth only) create a transaction with the address provided - /// as the sender that can later be signed and sent onchain. - function broadcast(address signer) external; - - /// Has the next call (at this call depth only) create a transaction with the private key - /// provided as the sender that can later be signed and sent onchain. - function broadcast(uint256 privateKey) external; - - /// Has all subsequent calls (at this call depth only) create transactions that can later be signed and sent onchain. - /// Broadcasting address is determined by checking the following in order: - /// 1. If `--sender` argument was provided, that address is used. - /// 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. - /// 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used. - function startBroadcast() external; - - /// Has all subsequent calls (at this call depth only) create transactions with the address - /// provided that can later be signed and sent onchain. - function startBroadcast(address signer) external; - - /// Has all subsequent calls (at this call depth only) create transactions with the private key - /// provided that can later be signed and sent onchain. - function startBroadcast(uint256 privateKey) external; - - /// Stops collecting onchain transactions. - function stopBroadcast() external; - - // ======== String ======== - - /// Returns the index of the first occurrence of a `key` in an `input` string. - /// Returns `NOT_FOUND` (i.e. `type(uint256).max`) if the `key` is not found. - /// Returns 0 in case of an empty `key`. - function indexOf(string calldata input, string calldata key) external pure returns (uint256); - - /// Parses the given `string` into an `address`. - function parseAddress(string calldata stringifiedValue) external pure returns (address parsedValue); - - /// Parses the given `string` into a `bool`. - function parseBool(string calldata stringifiedValue) external pure returns (bool parsedValue); - - /// Parses the given `string` into `bytes`. - function parseBytes(string calldata stringifiedValue) external pure returns (bytes memory parsedValue); - - /// Parses the given `string` into a `bytes32`. - function parseBytes32(string calldata stringifiedValue) external pure returns (bytes32 parsedValue); - - /// Parses the given `string` into a `int256`. - function parseInt(string calldata stringifiedValue) external pure returns (int256 parsedValue); - - /// Parses the given `string` into a `uint256`. - function parseUint(string calldata stringifiedValue) external pure returns (uint256 parsedValue); - - /// Replaces occurrences of `from` in the given `string` with `to`. - function replace(string calldata input, string calldata from, string calldata to) - external - pure - returns (string memory output); - - /// Splits the given `string` into an array of strings divided by the `delimiter`. - function split(string calldata input, string calldata delimiter) external pure returns (string[] memory outputs); - - /// Converts the given `string` value to Lowercase. - function toLowercase(string calldata input) external pure returns (string memory output); - - /// Converts the given value to a `string`. - function toString(address value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(bytes calldata value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(bytes32 value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(bool value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(uint256 value) external pure returns (string memory stringifiedValue); - - /// Converts the given value to a `string`. - function toString(int256 value) external pure returns (string memory stringifiedValue); - - /// Converts the given `string` value to Uppercase. - function toUppercase(string calldata input) external pure returns (string memory output); - - /// Trims leading and trailing whitespace from the given `string` value. - function trim(string calldata input) external pure returns (string memory output); - - // ======== Testing ======== - - /// Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. - /// Formats values with decimals in failure message. - function assertApproxEqAbsDecimal(uint256 left, uint256 right, uint256 maxDelta, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertApproxEqAbsDecimal( - uint256 left, - uint256 right, - uint256 maxDelta, - uint256 decimals, - string calldata error - ) external pure; - - /// Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. - /// Formats values with decimals in failure message. - function assertApproxEqAbsDecimal(int256 left, int256 right, uint256 maxDelta, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertApproxEqAbsDecimal( - int256 left, - int256 right, - uint256 maxDelta, - uint256 decimals, - string calldata error - ) external pure; - - /// Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. - function assertApproxEqAbs(uint256 left, uint256 right, uint256 maxDelta) external pure; - - /// Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. - /// Includes error message into revert string on failure. - function assertApproxEqAbs(uint256 left, uint256 right, uint256 maxDelta, string calldata error) external pure; - - /// Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. - function assertApproxEqAbs(int256 left, int256 right, uint256 maxDelta) external pure; - - /// Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. - /// Includes error message into revert string on failure. - function assertApproxEqAbs(int256 left, int256 right, uint256 maxDelta, string calldata error) external pure; - - /// Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Formats values with decimals in failure message. - function assertApproxEqRelDecimal(uint256 left, uint256 right, uint256 maxPercentDelta, uint256 decimals) - external - pure; - - /// Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertApproxEqRelDecimal( - uint256 left, - uint256 right, - uint256 maxPercentDelta, - uint256 decimals, - string calldata error - ) external pure; - - /// Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Formats values with decimals in failure message. - function assertApproxEqRelDecimal(int256 left, int256 right, uint256 maxPercentDelta, uint256 decimals) - external - pure; - - /// Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertApproxEqRelDecimal( - int256 left, - int256 right, - uint256 maxPercentDelta, - uint256 decimals, - string calldata error - ) external pure; - - /// Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - function assertApproxEqRel(uint256 left, uint256 right, uint256 maxPercentDelta) external pure; - - /// Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Includes error message into revert string on failure. - function assertApproxEqRel(uint256 left, uint256 right, uint256 maxPercentDelta, string calldata error) - external - pure; - - /// Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - function assertApproxEqRel(int256 left, int256 right, uint256 maxPercentDelta) external pure; - - /// Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. - /// `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% - /// Includes error message into revert string on failure. - function assertApproxEqRel(int256 left, int256 right, uint256 maxPercentDelta, string calldata error) - external - pure; - - /// Asserts that two `uint256` values are equal, formatting them with decimals in failure message. - function assertEqDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Asserts that two `uint256` values are equal, formatting them with decimals in failure message. - /// Includes error message into revert string on failure. - function assertEqDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Asserts that two `int256` values are equal, formatting them with decimals in failure message. - function assertEqDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Asserts that two `int256` values are equal, formatting them with decimals in failure message. - /// Includes error message into revert string on failure. - function assertEqDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Asserts that two `bool` values are equal. - function assertEq(bool left, bool right) external pure; - - /// Asserts that two `bool` values are equal and includes error message into revert string on failure. - function assertEq(bool left, bool right, string calldata error) external pure; - - /// Asserts that two `string` values are equal. - function assertEq(string calldata left, string calldata right) external pure; - - /// Asserts that two `string` values are equal and includes error message into revert string on failure. - function assertEq(string calldata left, string calldata right, string calldata error) external pure; - - /// Asserts that two `bytes` values are equal. - function assertEq(bytes calldata left, bytes calldata right) external pure; - - /// Asserts that two `bytes` values are equal and includes error message into revert string on failure. - function assertEq(bytes calldata left, bytes calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bool` values are equal. - function assertEq(bool[] calldata left, bool[] calldata right) external pure; - - /// Asserts that two arrays of `bool` values are equal and includes error message into revert string on failure. - function assertEq(bool[] calldata left, bool[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `uint256 values are equal. - function assertEq(uint256[] calldata left, uint256[] calldata right) external pure; - - /// Asserts that two arrays of `uint256` values are equal and includes error message into revert string on failure. - function assertEq(uint256[] calldata left, uint256[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `int256` values are equal. - function assertEq(int256[] calldata left, int256[] calldata right) external pure; - - /// Asserts that two arrays of `int256` values are equal and includes error message into revert string on failure. - function assertEq(int256[] calldata left, int256[] calldata right, string calldata error) external pure; - - /// Asserts that two `uint256` values are equal. - function assertEq(uint256 left, uint256 right) external pure; - - /// Asserts that two arrays of `address` values are equal. - function assertEq(address[] calldata left, address[] calldata right) external pure; - - /// Asserts that two arrays of `address` values are equal and includes error message into revert string on failure. - function assertEq(address[] calldata left, address[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bytes32` values are equal. - function assertEq(bytes32[] calldata left, bytes32[] calldata right) external pure; - - /// Asserts that two arrays of `bytes32` values are equal and includes error message into revert string on failure. - function assertEq(bytes32[] calldata left, bytes32[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `string` values are equal. - function assertEq(string[] calldata left, string[] calldata right) external pure; - - /// Asserts that two arrays of `string` values are equal and includes error message into revert string on failure. - function assertEq(string[] calldata left, string[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bytes` values are equal. - function assertEq(bytes[] calldata left, bytes[] calldata right) external pure; - - /// Asserts that two arrays of `bytes` values are equal and includes error message into revert string on failure. - function assertEq(bytes[] calldata left, bytes[] calldata right, string calldata error) external pure; - - /// Asserts that two `uint256` values are equal and includes error message into revert string on failure. - function assertEq(uint256 left, uint256 right, string calldata error) external pure; - - /// Asserts that two `int256` values are equal. - function assertEq(int256 left, int256 right) external pure; - - /// Asserts that two `int256` values are equal and includes error message into revert string on failure. - function assertEq(int256 left, int256 right, string calldata error) external pure; - - /// Asserts that two `address` values are equal. - function assertEq(address left, address right) external pure; - - /// Asserts that two `address` values are equal and includes error message into revert string on failure. - function assertEq(address left, address right, string calldata error) external pure; - - /// Asserts that two `bytes32` values are equal. - function assertEq(bytes32 left, bytes32 right) external pure; - - /// Asserts that two `bytes32` values are equal and includes error message into revert string on failure. - function assertEq(bytes32 left, bytes32 right, string calldata error) external pure; - - /// Asserts that the given condition is false. - function assertFalse(bool condition) external pure; - - /// Asserts that the given condition is false and includes error message into revert string on failure. - function assertFalse(bool condition, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than or equal to second. - /// Formats values with decimals in failure message. - function assertGeDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than or equal to second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertGeDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be greater than or equal to second. - /// Formats values with decimals in failure message. - function assertGeDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects first value to be greater than or equal to second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertGeDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than or equal to second. - function assertGe(uint256 left, uint256 right) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than or equal to second. - /// Includes error message into revert string on failure. - function assertGe(uint256 left, uint256 right, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be greater than or equal to second. - function assertGe(int256 left, int256 right) external pure; - - /// Compares two `int256` values. Expects first value to be greater than or equal to second. - /// Includes error message into revert string on failure. - function assertGe(int256 left, int256 right, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than second. - /// Formats values with decimals in failure message. - function assertGtDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertGtDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be greater than second. - /// Formats values with decimals in failure message. - function assertGtDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects first value to be greater than second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertGtDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than second. - function assertGt(uint256 left, uint256 right) external pure; - - /// Compares two `uint256` values. Expects first value to be greater than second. - /// Includes error message into revert string on failure. - function assertGt(uint256 left, uint256 right, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be greater than second. - function assertGt(int256 left, int256 right) external pure; - - /// Compares two `int256` values. Expects first value to be greater than second. - /// Includes error message into revert string on failure. - function assertGt(int256 left, int256 right, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be less than or equal to second. - /// Formats values with decimals in failure message. - function assertLeDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects first value to be less than or equal to second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertLeDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be less than or equal to second. - /// Formats values with decimals in failure message. - function assertLeDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects first value to be less than or equal to second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertLeDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be less than or equal to second. - function assertLe(uint256 left, uint256 right) external pure; - - /// Compares two `uint256` values. Expects first value to be less than or equal to second. - /// Includes error message into revert string on failure. - function assertLe(uint256 left, uint256 right, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be less than or equal to second. - function assertLe(int256 left, int256 right) external pure; - - /// Compares two `int256` values. Expects first value to be less than or equal to second. - /// Includes error message into revert string on failure. - function assertLe(int256 left, int256 right, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be less than second. - /// Formats values with decimals in failure message. - function assertLtDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Compares two `uint256` values. Expects first value to be less than second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertLtDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be less than second. - /// Formats values with decimals in failure message. - function assertLtDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Compares two `int256` values. Expects first value to be less than second. - /// Formats values with decimals in failure message. Includes error message into revert string on failure. - function assertLtDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Compares two `uint256` values. Expects first value to be less than second. - function assertLt(uint256 left, uint256 right) external pure; - - /// Compares two `uint256` values. Expects first value to be less than second. - /// Includes error message into revert string on failure. - function assertLt(uint256 left, uint256 right, string calldata error) external pure; - - /// Compares two `int256` values. Expects first value to be less than second. - function assertLt(int256 left, int256 right) external pure; - - /// Compares two `int256` values. Expects first value to be less than second. - /// Includes error message into revert string on failure. - function assertLt(int256 left, int256 right, string calldata error) external pure; - - /// Asserts that two `uint256` values are not equal, formatting them with decimals in failure message. - function assertNotEqDecimal(uint256 left, uint256 right, uint256 decimals) external pure; - - /// Asserts that two `uint256` values are not equal, formatting them with decimals in failure message. - /// Includes error message into revert string on failure. - function assertNotEqDecimal(uint256 left, uint256 right, uint256 decimals, string calldata error) external pure; - - /// Asserts that two `int256` values are not equal, formatting them with decimals in failure message. - function assertNotEqDecimal(int256 left, int256 right, uint256 decimals) external pure; - - /// Asserts that two `int256` values are not equal, formatting them with decimals in failure message. - /// Includes error message into revert string on failure. - function assertNotEqDecimal(int256 left, int256 right, uint256 decimals, string calldata error) external pure; - - /// Asserts that two `bool` values are not equal. - function assertNotEq(bool left, bool right) external pure; - - /// Asserts that two `bool` values are not equal and includes error message into revert string on failure. - function assertNotEq(bool left, bool right, string calldata error) external pure; - - /// Asserts that two `string` values are not equal. - function assertNotEq(string calldata left, string calldata right) external pure; - - /// Asserts that two `string` values are not equal and includes error message into revert string on failure. - function assertNotEq(string calldata left, string calldata right, string calldata error) external pure; - - /// Asserts that two `bytes` values are not equal. - function assertNotEq(bytes calldata left, bytes calldata right) external pure; - - /// Asserts that two `bytes` values are not equal and includes error message into revert string on failure. - function assertNotEq(bytes calldata left, bytes calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bool` values are not equal. - function assertNotEq(bool[] calldata left, bool[] calldata right) external pure; - - /// Asserts that two arrays of `bool` values are not equal and includes error message into revert string on failure. - function assertNotEq(bool[] calldata left, bool[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `uint256` values are not equal. - function assertNotEq(uint256[] calldata left, uint256[] calldata right) external pure; - - /// Asserts that two arrays of `uint256` values are not equal and includes error message into revert string on failure. - function assertNotEq(uint256[] calldata left, uint256[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `int256` values are not equal. - function assertNotEq(int256[] calldata left, int256[] calldata right) external pure; - - /// Asserts that two arrays of `int256` values are not equal and includes error message into revert string on failure. - function assertNotEq(int256[] calldata left, int256[] calldata right, string calldata error) external pure; - - /// Asserts that two `uint256` values are not equal. - function assertNotEq(uint256 left, uint256 right) external pure; - - /// Asserts that two arrays of `address` values are not equal. - function assertNotEq(address[] calldata left, address[] calldata right) external pure; - - /// Asserts that two arrays of `address` values are not equal and includes error message into revert string on failure. - function assertNotEq(address[] calldata left, address[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bytes32` values are not equal. - function assertNotEq(bytes32[] calldata left, bytes32[] calldata right) external pure; - - /// Asserts that two arrays of `bytes32` values are not equal and includes error message into revert string on failure. - function assertNotEq(bytes32[] calldata left, bytes32[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `string` values are not equal. - function assertNotEq(string[] calldata left, string[] calldata right) external pure; - - /// Asserts that two arrays of `string` values are not equal and includes error message into revert string on failure. - function assertNotEq(string[] calldata left, string[] calldata right, string calldata error) external pure; - - /// Asserts that two arrays of `bytes` values are not equal. - function assertNotEq(bytes[] calldata left, bytes[] calldata right) external pure; - - /// Asserts that two arrays of `bytes` values are not equal and includes error message into revert string on failure. - function assertNotEq(bytes[] calldata left, bytes[] calldata right, string calldata error) external pure; - - /// Asserts that two `uint256` values are not equal and includes error message into revert string on failure. - function assertNotEq(uint256 left, uint256 right, string calldata error) external pure; - - /// Asserts that two `int256` values are not equal. - function assertNotEq(int256 left, int256 right) external pure; - - /// Asserts that two `int256` values are not equal and includes error message into revert string on failure. - function assertNotEq(int256 left, int256 right, string calldata error) external pure; - - /// Asserts that two `address` values are not equal. - function assertNotEq(address left, address right) external pure; - - /// Asserts that two `address` values are not equal and includes error message into revert string on failure. - function assertNotEq(address left, address right, string calldata error) external pure; - - /// Asserts that two `bytes32` values are not equal. - function assertNotEq(bytes32 left, bytes32 right) external pure; - - /// Asserts that two `bytes32` values are not equal and includes error message into revert string on failure. - function assertNotEq(bytes32 left, bytes32 right, string calldata error) external pure; - - /// Asserts that the given condition is true. - function assertTrue(bool condition) external pure; - - /// Asserts that the given condition is true and includes error message into revert string on failure. - function assertTrue(bool condition, string calldata error) external pure; - - /// If the condition is false, discard this run's fuzz inputs and generate new ones. - function assume(bool condition) external pure; - - /// Discard this run's fuzz inputs and generate new ones if next call reverted. - function assumeNoRevert() external pure; - - /// Writes a breakpoint to jump to in the debugger. - function breakpoint(string calldata char) external; - - /// Writes a conditional breakpoint to jump to in the debugger. - function breakpoint(string calldata char, bool value) external; - - /// Returns the Foundry version. - /// Format: ++ - /// Sample output: 0.2.0+faa94c384+202407110019 - /// Note: Build timestamps may vary slightly across platforms due to separate CI jobs. - /// For reliable version comparisons, use YYYYMMDD0000 format (e.g., >= 202407110000) - /// to compare timestamps while ignoring minor time differences. - function getFoundryVersion() external view returns (string memory version); - - /// Returns the RPC url for the given alias. - function rpcUrl(string calldata rpcAlias) external view returns (string memory json); - - /// Returns all rpc urls and their aliases as structs. - function rpcUrlStructs() external view returns (Rpc[] memory urls); - - /// Returns all rpc urls and their aliases `[alias, url][]`. - function rpcUrls() external view returns (string[2][] memory urls); - - /// Suspends execution of the main thread for `duration` milliseconds. - function sleep(uint256 duration) external; - - // ======== Toml ======== - - /// Checks if `key` exists in a TOML table. - function keyExistsToml(string calldata toml, string calldata key) external view returns (bool); - - /// Parses a string of TOML data at `key` and coerces it to `address`. - function parseTomlAddress(string calldata toml, string calldata key) external pure returns (address); - - /// Parses a string of TOML data at `key` and coerces it to `address[]`. - function parseTomlAddressArray(string calldata toml, string calldata key) - external - pure - returns (address[] memory); - - /// Parses a string of TOML data at `key` and coerces it to `bool`. - function parseTomlBool(string calldata toml, string calldata key) external pure returns (bool); - - /// Parses a string of TOML data at `key` and coerces it to `bool[]`. - function parseTomlBoolArray(string calldata toml, string calldata key) external pure returns (bool[] memory); - - /// Parses a string of TOML data at `key` and coerces it to `bytes`. - function parseTomlBytes(string calldata toml, string calldata key) external pure returns (bytes memory); - - /// Parses a string of TOML data at `key` and coerces it to `bytes32`. - function parseTomlBytes32(string calldata toml, string calldata key) external pure returns (bytes32); - - /// Parses a string of TOML data at `key` and coerces it to `bytes32[]`. - function parseTomlBytes32Array(string calldata toml, string calldata key) - external - pure - returns (bytes32[] memory); - - /// Parses a string of TOML data at `key` and coerces it to `bytes[]`. - function parseTomlBytesArray(string calldata toml, string calldata key) external pure returns (bytes[] memory); - - /// Parses a string of TOML data at `key` and coerces it to `int256`. - function parseTomlInt(string calldata toml, string calldata key) external pure returns (int256); - - /// Parses a string of TOML data at `key` and coerces it to `int256[]`. - function parseTomlIntArray(string calldata toml, string calldata key) external pure returns (int256[] memory); - - /// Returns an array of all the keys in a TOML table. - function parseTomlKeys(string calldata toml, string calldata key) external pure returns (string[] memory keys); - - /// Parses a string of TOML data at `key` and coerces it to `string`. - function parseTomlString(string calldata toml, string calldata key) external pure returns (string memory); - - /// Parses a string of TOML data at `key` and coerces it to `string[]`. - function parseTomlStringArray(string calldata toml, string calldata key) external pure returns (string[] memory); - - /// Parses a string of TOML data at `key` and coerces it to type array corresponding to `typeDescription`. - function parseTomlTypeArray(string calldata toml, string calldata key, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of TOML data and coerces it to type corresponding to `typeDescription`. - function parseTomlType(string calldata toml, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of TOML data at `key` and coerces it to type corresponding to `typeDescription`. - function parseTomlType(string calldata toml, string calldata key, string calldata typeDescription) - external - pure - returns (bytes memory); - - /// Parses a string of TOML data at `key` and coerces it to `uint256`. - function parseTomlUint(string calldata toml, string calldata key) external pure returns (uint256); - - /// Parses a string of TOML data at `key` and coerces it to `uint256[]`. - function parseTomlUintArray(string calldata toml, string calldata key) external pure returns (uint256[] memory); - - /// ABI-encodes a TOML table. - function parseToml(string calldata toml) external pure returns (bytes memory abiEncodedData); - - /// ABI-encodes a TOML table at `key`. - function parseToml(string calldata toml, string calldata key) external pure returns (bytes memory abiEncodedData); - - /// Takes serialized JSON, converts to TOML and write a serialized TOML to a file. - function writeToml(string calldata json, string calldata path) external; - - /// Takes serialized JSON, converts to TOML and write a serialized TOML table to an **existing** TOML file, replacing a value with key = - /// This is useful to replace a specific value of a TOML file, without having to parse the entire thing. - function writeToml(string calldata json, string calldata path, string calldata valueKey) external; - - // ======== Utilities ======== - - /// Compute the address of a contract created with CREATE2 using the given CREATE2 deployer. - function computeCreate2Address(bytes32 salt, bytes32 initCodeHash, address deployer) - external - pure - returns (address); - - /// Compute the address of a contract created with CREATE2 using the default CREATE2 deployer. - function computeCreate2Address(bytes32 salt, bytes32 initCodeHash) external pure returns (address); - - /// Compute the address a contract will be deployed at for a given deployer address and nonce. - function computeCreateAddress(address deployer, uint256 nonce) external pure returns (address); - - /// Utility cheatcode to copy storage of `from` contract to another `to` contract. - function copyStorage(address from, address to) external; - - /// Returns ENS namehash for provided string. - function ensNamehash(string calldata name) external pure returns (bytes32); - - /// Gets the label for the specified address. - function getLabel(address account) external view returns (string memory currentLabel); - - /// Labels an address in call traces. - function label(address account, string calldata newLabel) external; - - /// Pauses collection of call traces. Useful in cases when you want to skip tracing of - /// complex calls which are not useful for debugging. - function pauseTracing() external view; - - /// Returns a random `address`. - function randomAddress() external returns (address); - - /// Returns an random `bool`. - function randomBool() external view returns (bool); - - /// Returns an random byte array value of the given length. - function randomBytes(uint256 len) external view returns (bytes memory); - - /// Returns an random `int256` value. - function randomInt() external view returns (int256); - - /// Returns an random `int256` value of given bits. - function randomInt(uint256 bits) external view returns (int256); - - /// Returns a random uint256 value. - function randomUint() external returns (uint256); - - /// Returns random uint256 value between the provided range (=min..=max). - function randomUint(uint256 min, uint256 max) external returns (uint256); - - /// Returns an random `uint256` value of given bits. - function randomUint(uint256 bits) external view returns (uint256); - - /// Unpauses collection of call traces. - function resumeTracing() external view; - - /// Utility cheatcode to set arbitrary storage for given target address. - function setArbitraryStorage(address target) external; - - /// Encodes a `bytes` value to a base64url string. - function toBase64URL(bytes calldata data) external pure returns (string memory); - - /// Encodes a `string` value to a base64url string. - function toBase64URL(string calldata data) external pure returns (string memory); - - /// Encodes a `bytes` value to a base64 string. - function toBase64(bytes calldata data) external pure returns (string memory); - - /// Encodes a `string` value to a base64 string. - function toBase64(string calldata data) external pure returns (string memory); -} - -/// The `Vm` interface does allow manipulation of the EVM state. These are all intended to be used -/// in tests, but it is not recommended to use these cheats in scripts. -interface Vm is VmSafe { - // ======== EVM ======== - - /// Returns the identifier of the currently active fork. Reverts if no fork is currently active. - function activeFork() external view returns (uint256 forkId); - - /// In forking mode, explicitly grant the given address cheatcode access. - function allowCheatcodes(address account) external; - - /// Sets `block.blobbasefee` - function blobBaseFee(uint256 newBlobBaseFee) external; - - /// Sets the blobhashes in the transaction. - /// Not available on EVM versions before Cancun. - /// If used on unsupported EVM versions it will revert. - function blobhashes(bytes32[] calldata hashes) external; - - /// Sets `block.chainid`. - function chainId(uint256 newChainId) external; - - /// Clears all mocked calls. - function clearMockedCalls() external; - - /// Sets `block.coinbase`. - function coinbase(address newCoinbase) external; - - /// Creates a new fork with the given endpoint and the _latest_ block and returns the identifier of the fork. - function createFork(string calldata urlOrAlias) external returns (uint256 forkId); - - /// Creates a new fork with the given endpoint and block and returns the identifier of the fork. - function createFork(string calldata urlOrAlias, uint256 blockNumber) external returns (uint256 forkId); - - /// Creates a new fork with the given endpoint and at the block the given transaction was mined in, - /// replays all transaction mined in the block before the transaction, and returns the identifier of the fork. - function createFork(string calldata urlOrAlias, bytes32 txHash) external returns (uint256 forkId); - - /// Creates and also selects a new fork with the given endpoint and the latest block and returns the identifier of the fork. - function createSelectFork(string calldata urlOrAlias) external returns (uint256 forkId); - - /// Creates and also selects a new fork with the given endpoint and block and returns the identifier of the fork. - function createSelectFork(string calldata urlOrAlias, uint256 blockNumber) external returns (uint256 forkId); - - /// Creates and also selects new fork with the given endpoint and at the block the given transaction was mined in, - /// replays all transaction mined in the block before the transaction, returns the identifier of the fork. - function createSelectFork(string calldata urlOrAlias, bytes32 txHash) external returns (uint256 forkId); - - /// Sets an address' balance. - function deal(address account, uint256 newBalance) external; - - /// Removes the snapshot with the given ID created by `snapshot`. - /// Takes the snapshot ID to delete. - /// Returns `true` if the snapshot was successfully deleted. - /// Returns `false` if the snapshot does not exist. - function deleteSnapshot(uint256 snapshotId) external returns (bool success); - - /// Removes _all_ snapshots previously created by `snapshot`. - function deleteSnapshots() external; - - /// Sets `block.difficulty`. - /// Not available on EVM versions from Paris onwards. Use `prevrandao` instead. - /// Reverts if used on unsupported EVM versions. - function difficulty(uint256 newDifficulty) external; - - /// Dump a genesis JSON file's `allocs` to disk. - function dumpState(string calldata pathToStateJson) external; - - /// Sets an address' code. - function etch(address target, bytes calldata newRuntimeBytecode) external; - - /// Sets `block.basefee`. - function fee(uint256 newBasefee) external; - - /// Gets the blockhashes from the current transaction. - /// Not available on EVM versions before Cancun. - /// If used on unsupported EVM versions it will revert. - function getBlobhashes() external view returns (bytes32[] memory hashes); - - /// Returns true if the account is marked as persistent. - function isPersistent(address account) external view returns (bool persistent); - - /// Load a genesis JSON file's `allocs` into the in-memory revm state. - function loadAllocs(string calldata pathToAllocsJson) external; - - /// Marks that the account(s) should use persistent storage across fork swaps in a multifork setup - /// Meaning, changes made to the state of this account will be kept when switching forks. - function makePersistent(address account) external; - - /// See `makePersistent(address)`. - function makePersistent(address account0, address account1) external; - - /// See `makePersistent(address)`. - function makePersistent(address account0, address account1, address account2) external; - - /// See `makePersistent(address)`. - function makePersistent(address[] calldata accounts) external; - - /// Reverts a call to an address with specified revert data. - function mockCallRevert(address callee, bytes calldata data, bytes calldata revertData) external; - - /// Reverts a call to an address with a specific `msg.value`, with specified revert data. - function mockCallRevert(address callee, uint256 msgValue, bytes calldata data, bytes calldata revertData) - external; - - /// Mocks a call to an address, returning specified data. - /// Calldata can either be strict or a partial match, e.g. if you only - /// pass a Solidity selector to the expected calldata, then the entire Solidity - /// function will be mocked. - function mockCall(address callee, bytes calldata data, bytes calldata returnData) external; - - /// Mocks a call to an address with a specific `msg.value`, returning specified data. - /// Calldata match takes precedence over `msg.value` in case of ambiguity. - function mockCall(address callee, uint256 msgValue, bytes calldata data, bytes calldata returnData) external; - - /// Whenever a call is made to `callee` with calldata `data`, this cheatcode instead calls - /// `target` with the same calldata. This functionality is similar to a delegate call made to - /// `target` contract from `callee`. - /// Can be used to substitute a call to a function with another implementation that captures - /// the primary logic of the original function but is easier to reason about. - /// If calldata is not a strict match then partial match by selector is attempted. - function mockFunction(address callee, address target, bytes calldata data) external; - - /// Sets the *next* call's `msg.sender` to be the input address. - function prank(address msgSender) external; - - /// Sets the *next* call's `msg.sender` to be the input address, and the `tx.origin` to be the second input. - function prank(address msgSender, address txOrigin) external; - - /// Sets `block.prevrandao`. - /// Not available on EVM versions before Paris. Use `difficulty` instead. - /// If used on unsupported EVM versions it will revert. - function prevrandao(bytes32 newPrevrandao) external; - - /// Sets `block.prevrandao`. - /// Not available on EVM versions before Paris. Use `difficulty` instead. - /// If used on unsupported EVM versions it will revert. - function prevrandao(uint256 newPrevrandao) external; - - /// Reads the current `msg.sender` and `tx.origin` from state and reports if there is any active caller modification. - function readCallers() external returns (CallerMode callerMode, address msgSender, address txOrigin); - - /// Resets the nonce of an account to 0 for EOAs and 1 for contract accounts. - function resetNonce(address account) external; - - /// Revert the state of the EVM to a previous snapshot - /// Takes the snapshot ID to revert to. - /// Returns `true` if the snapshot was successfully reverted. - /// Returns `false` if the snapshot does not exist. - /// **Note:** This does not automatically delete the snapshot. To delete the snapshot use `deleteSnapshot`. - function revertTo(uint256 snapshotId) external returns (bool success); - - /// Revert the state of the EVM to a previous snapshot and automatically deletes the snapshots - /// Takes the snapshot ID to revert to. - /// Returns `true` if the snapshot was successfully reverted and deleted. - /// Returns `false` if the snapshot does not exist. - function revertToAndDelete(uint256 snapshotId) external returns (bool success); - - /// Revokes persistent status from the address, previously added via `makePersistent`. - function revokePersistent(address account) external; - - /// See `revokePersistent(address)`. - function revokePersistent(address[] calldata accounts) external; - - /// Sets `block.height`. - function roll(uint256 newHeight) external; - - /// Updates the currently active fork to given block number - /// This is similar to `roll` but for the currently active fork. - function rollFork(uint256 blockNumber) external; - - /// Updates the currently active fork to given transaction. This will `rollFork` with the number - /// of the block the transaction was mined in and replays all transaction mined before it in the block. - function rollFork(bytes32 txHash) external; - - /// Updates the given fork to given block number. - function rollFork(uint256 forkId, uint256 blockNumber) external; - - /// Updates the given fork to block number of the given transaction and replays all transaction mined before it in the block. - function rollFork(uint256 forkId, bytes32 txHash) external; - - /// Takes a fork identifier created by `createFork` and sets the corresponding forked state as active. - function selectFork(uint256 forkId) external; - - /// Set blockhash for the current block. - /// It only sets the blockhash for blocks where `block.number - 256 <= number < block.number`. - function setBlockhash(uint256 blockNumber, bytes32 blockHash) external; - - /// Sets the nonce of an account. Must be higher than the current nonce of the account. - function setNonce(address account, uint64 newNonce) external; - - /// Sets the nonce of an account to an arbitrary value. - function setNonceUnsafe(address account, uint64 newNonce) external; - - /// Snapshot the current state of the evm. - /// Returns the ID of the snapshot that was created. - /// To revert a snapshot use `revertTo`. - function snapshot() external returns (uint256 snapshotId); - - /// Sets all subsequent calls' `msg.sender` to be the input address until `stopPrank` is called. - function startPrank(address msgSender) external; - - /// Sets all subsequent calls' `msg.sender` to be the input address until `stopPrank` is called, and the `tx.origin` to be the second input. - function startPrank(address msgSender, address txOrigin) external; - - /// Resets subsequent calls' `msg.sender` to be `address(this)`. - function stopPrank() external; - - /// Stores a value to an address' storage slot. - function store(address target, bytes32 slot, bytes32 value) external; - - /// Fetches the given transaction from the active fork and executes it on the current state. - function transact(bytes32 txHash) external; - - /// Fetches the given transaction from the given fork and executes it on the current state. - function transact(uint256 forkId, bytes32 txHash) external; - - /// Sets `tx.gasprice`. - function txGasPrice(uint256 newGasPrice) external; - - /// Sets `block.timestamp`. - function warp(uint256 newTimestamp) external; - - // ======== Testing ======== - - /// Expect a call to an address with the specified `msg.value` and calldata, and a *minimum* amount of gas. - function expectCallMinGas(address callee, uint256 msgValue, uint64 minGas, bytes calldata data) external; - - /// Expect given number of calls to an address with the specified `msg.value` and calldata, and a *minimum* amount of gas. - function expectCallMinGas(address callee, uint256 msgValue, uint64 minGas, bytes calldata data, uint64 count) - external; - - /// Expects a call to an address with the specified calldata. - /// Calldata can either be a strict or a partial match. - function expectCall(address callee, bytes calldata data) external; - - /// Expects given number of calls to an address with the specified calldata. - function expectCall(address callee, bytes calldata data, uint64 count) external; - - /// Expects a call to an address with the specified `msg.value` and calldata. - function expectCall(address callee, uint256 msgValue, bytes calldata data) external; - - /// Expects given number of calls to an address with the specified `msg.value` and calldata. - function expectCall(address callee, uint256 msgValue, bytes calldata data, uint64 count) external; - - /// Expect a call to an address with the specified `msg.value`, gas, and calldata. - function expectCall(address callee, uint256 msgValue, uint64 gas, bytes calldata data) external; - - /// Expects given number of calls to an address with the specified `msg.value`, gas, and calldata. - function expectCall(address callee, uint256 msgValue, uint64 gas, bytes calldata data, uint64 count) external; - - /// Prepare an expected anonymous log with (bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData.). - /// Call this function, then emit an anonymous event, then call a function. Internally after the call, we check if - /// logs were emitted in the expected order with the expected topics and data (as specified by the booleans). - function expectEmitAnonymous(bool checkTopic0, bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData) - external; - - /// Same as the previous method, but also checks supplied address against emitting contract. - function expectEmitAnonymous( - bool checkTopic0, - bool checkTopic1, - bool checkTopic2, - bool checkTopic3, - bool checkData, - address emitter - ) external; - - /// Prepare an expected anonymous log with all topic and data checks enabled. - /// Call this function, then emit an anonymous event, then call a function. Internally after the call, we check if - /// logs were emitted in the expected order with the expected topics and data. - function expectEmitAnonymous() external; - - /// Same as the previous method, but also checks supplied address against emitting contract. - function expectEmitAnonymous(address emitter) external; - - /// Prepare an expected log with (bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData.). - /// Call this function, then emit an event, then call a function. Internally after the call, we check if - /// logs were emitted in the expected order with the expected topics and data (as specified by the booleans). - function expectEmit(bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData) external; - - /// Same as the previous method, but also checks supplied address against emitting contract. - function expectEmit(bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData, address emitter) - external; - - /// Prepare an expected log with all topic and data checks enabled. - /// Call this function, then emit an event, then call a function. Internally after the call, we check if - /// logs were emitted in the expected order with the expected topics and data. - function expectEmit() external; - - /// Same as the previous method, but also checks supplied address against emitting contract. - function expectEmit(address emitter) external; - - /// Expects an error on next call that starts with the revert data. - function expectPartialRevert(bytes4 revertData) external; - - /// Expects an error on next call to reverter address, that starts with the revert data. - function expectPartialRevert(bytes4 revertData, address reverter) external; - - /// Expects an error on next call with any revert data. - function expectRevert() external; - - /// Expects an error on next call that exactly matches the revert data. - function expectRevert(bytes4 revertData) external; - - /// Expects an error on next call that exactly matches the revert data. - function expectRevert(bytes calldata revertData) external; - - /// Expects an error with any revert data on next call to reverter address. - function expectRevert(address reverter) external; - - /// Expects an error from reverter address on next call, with any revert data. - function expectRevert(bytes4 revertData, address reverter) external; - - /// Expects an error from reverter address on next call, that exactly matches the revert data. - function expectRevert(bytes calldata revertData, address reverter) external; - - /// Only allows memory writes to offsets [0x00, 0x60) ∪ [min, max) in the current subcontext. If any other - /// memory is written to, the test will fail. Can be called multiple times to add more ranges to the set. - function expectSafeMemory(uint64 min, uint64 max) external; - - /// Only allows memory writes to offsets [0x00, 0x60) ∪ [min, max) in the next created subcontext. - /// If any other memory is written to, the test will fail. Can be called multiple times to add more ranges - /// to the set. - function expectSafeMemoryCall(uint64 min, uint64 max) external; - - /// Marks a test as skipped. Must be called at the top level of a test. - function skip(bool skipTest) external; - - /// Marks a test as skipped with a reason. Must be called at the top level of a test. - function skip(bool skipTest, string calldata reason) external; - - /// Stops all safe memory expectation in the current subcontext. - function stopExpectSafeMemory() external; -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/console.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/console.sol deleted file mode 100644 index 4fdb6679ed..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/console.sol +++ /dev/null @@ -1,1560 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.4.22 <0.9.0; - -library console { - address constant CONSOLE_ADDRESS = - 0x000000000000000000636F6e736F6c652e6c6f67; - - function _sendLogPayloadImplementation(bytes memory payload) internal view { - address consoleAddress = CONSOLE_ADDRESS; - /// @solidity memory-safe-assembly - assembly { - pop( - staticcall( - gas(), - consoleAddress, - add(payload, 32), - mload(payload), - 0, - 0 - ) - ) - } - } - - function _castToPure( - function(bytes memory) internal view fnIn - ) internal pure returns (function(bytes memory) pure fnOut) { - assembly { - fnOut := fnIn - } - } - - function _sendLogPayload(bytes memory payload) internal pure { - _castToPure(_sendLogPayloadImplementation)(payload); - } - - function log() internal pure { - _sendLogPayload(abi.encodeWithSignature("log()")); - } - - function logInt(int256 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(int256)", p0)); - } - - function logUint(uint256 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256)", p0)); - } - - function logString(string memory p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string)", p0)); - } - - function logBool(bool p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool)", p0)); - } - - function logAddress(address p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address)", p0)); - } - - function logBytes(bytes memory p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes)", p0)); - } - - function logBytes1(bytes1 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes1)", p0)); - } - - function logBytes2(bytes2 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes2)", p0)); - } - - function logBytes3(bytes3 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes3)", p0)); - } - - function logBytes4(bytes4 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes4)", p0)); - } - - function logBytes5(bytes5 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes5)", p0)); - } - - function logBytes6(bytes6 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes6)", p0)); - } - - function logBytes7(bytes7 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes7)", p0)); - } - - function logBytes8(bytes8 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes8)", p0)); - } - - function logBytes9(bytes9 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes9)", p0)); - } - - function logBytes10(bytes10 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes10)", p0)); - } - - function logBytes11(bytes11 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes11)", p0)); - } - - function logBytes12(bytes12 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes12)", p0)); - } - - function logBytes13(bytes13 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes13)", p0)); - } - - function logBytes14(bytes14 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes14)", p0)); - } - - function logBytes15(bytes15 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes15)", p0)); - } - - function logBytes16(bytes16 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes16)", p0)); - } - - function logBytes17(bytes17 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes17)", p0)); - } - - function logBytes18(bytes18 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes18)", p0)); - } - - function logBytes19(bytes19 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes19)", p0)); - } - - function logBytes20(bytes20 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes20)", p0)); - } - - function logBytes21(bytes21 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes21)", p0)); - } - - function logBytes22(bytes22 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes22)", p0)); - } - - function logBytes23(bytes23 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes23)", p0)); - } - - function logBytes24(bytes24 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes24)", p0)); - } - - function logBytes25(bytes25 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes25)", p0)); - } - - function logBytes26(bytes26 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes26)", p0)); - } - - function logBytes27(bytes27 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes27)", p0)); - } - - function logBytes28(bytes28 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes28)", p0)); - } - - function logBytes29(bytes29 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes29)", p0)); - } - - function logBytes30(bytes30 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes30)", p0)); - } - - function logBytes31(bytes31 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes31)", p0)); - } - - function logBytes32(bytes32 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bytes32)", p0)); - } - - function log(uint256 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256)", p0)); - } - - function log(int256 p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(int256)", p0)); - } - - function log(string memory p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string)", p0)); - } - - function log(bool p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool)", p0)); - } - - function log(address p0) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address)", p0)); - } - - function log(uint256 p0, uint256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256)", p0, p1)); - } - - function log(uint256 p0, string memory p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string)", p0, p1)); - } - - function log(uint256 p0, bool p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool)", p0, p1)); - } - - function log(uint256 p0, address p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address)", p0, p1)); - } - - function log(string memory p0, uint256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256)", p0, p1)); - } - - function log(string memory p0, int256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,int256)", p0, p1)); - } - - function log(string memory p0, string memory p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string)", p0, p1)); - } - - function log(string memory p0, bool p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool)", p0, p1)); - } - - function log(string memory p0, address p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address)", p0, p1)); - } - - function log(bool p0, uint256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256)", p0, p1)); - } - - function log(bool p0, string memory p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string)", p0, p1)); - } - - function log(bool p0, bool p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool)", p0, p1)); - } - - function log(bool p0, address p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address)", p0, p1)); - } - - function log(address p0, uint256 p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256)", p0, p1)); - } - - function log(address p0, string memory p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string)", p0, p1)); - } - - function log(address p0, bool p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool)", p0, p1)); - } - - function log(address p0, address p1) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address)", p0, p1)); - } - - function log(uint256 p0, uint256 p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256)", p0, p1, p2)); - } - - function log(uint256 p0, uint256 p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string)", p0, p1, p2)); - } - - function log(uint256 p0, uint256 p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool)", p0, p1, p2)); - } - - function log(uint256 p0, uint256 p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address)", p0, p1, p2)); - } - - function log(uint256 p0, string memory p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256)", p0, p1, p2)); - } - - function log(uint256 p0, string memory p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string)", p0, p1, p2)); - } - - function log(uint256 p0, string memory p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool)", p0, p1, p2)); - } - - function log(uint256 p0, string memory p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address)", p0, p1, p2)); - } - - function log(uint256 p0, bool p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256)", p0, p1, p2)); - } - - function log(uint256 p0, bool p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string)", p0, p1, p2)); - } - - function log(uint256 p0, bool p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool)", p0, p1, p2)); - } - - function log(uint256 p0, bool p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address)", p0, p1, p2)); - } - - function log(uint256 p0, address p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256)", p0, p1, p2)); - } - - function log(uint256 p0, address p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string)", p0, p1, p2)); - } - - function log(uint256 p0, address p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool)", p0, p1, p2)); - } - - function log(uint256 p0, address p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address)", p0, p1, p2)); - } - - function log(string memory p0, uint256 p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256)", p0, p1, p2)); - } - - function log(string memory p0, uint256 p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string)", p0, p1, p2)); - } - - function log(string memory p0, uint256 p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool)", p0, p1, p2)); - } - - function log(string memory p0, uint256 p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address)", p0, p1, p2)); - } - - function log(string memory p0, string memory p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256)", p0, p1, p2)); - } - - function log(string memory p0, string memory p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string)", p0, p1, p2)); - } - - function log(string memory p0, string memory p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool)", p0, p1, p2)); - } - - function log(string memory p0, string memory p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address)", p0, p1, p2)); - } - - function log(string memory p0, bool p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256)", p0, p1, p2)); - } - - function log(string memory p0, bool p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string)", p0, p1, p2)); - } - - function log(string memory p0, bool p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool)", p0, p1, p2)); - } - - function log(string memory p0, bool p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address)", p0, p1, p2)); - } - - function log(string memory p0, address p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256)", p0, p1, p2)); - } - - function log(string memory p0, address p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string)", p0, p1, p2)); - } - - function log(string memory p0, address p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool)", p0, p1, p2)); - } - - function log(string memory p0, address p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address)", p0, p1, p2)); - } - - function log(bool p0, uint256 p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256)", p0, p1, p2)); - } - - function log(bool p0, uint256 p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string)", p0, p1, p2)); - } - - function log(bool p0, uint256 p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool)", p0, p1, p2)); - } - - function log(bool p0, uint256 p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address)", p0, p1, p2)); - } - - function log(bool p0, string memory p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256)", p0, p1, p2)); - } - - function log(bool p0, string memory p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string)", p0, p1, p2)); - } - - function log(bool p0, string memory p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool)", p0, p1, p2)); - } - - function log(bool p0, string memory p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address)", p0, p1, p2)); - } - - function log(bool p0, bool p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256)", p0, p1, p2)); - } - - function log(bool p0, bool p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string)", p0, p1, p2)); - } - - function log(bool p0, bool p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool)", p0, p1, p2)); - } - - function log(bool p0, bool p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address)", p0, p1, p2)); - } - - function log(bool p0, address p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256)", p0, p1, p2)); - } - - function log(bool p0, address p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string)", p0, p1, p2)); - } - - function log(bool p0, address p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool)", p0, p1, p2)); - } - - function log(bool p0, address p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address)", p0, p1, p2)); - } - - function log(address p0, uint256 p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256)", p0, p1, p2)); - } - - function log(address p0, uint256 p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string)", p0, p1, p2)); - } - - function log(address p0, uint256 p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool)", p0, p1, p2)); - } - - function log(address p0, uint256 p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address)", p0, p1, p2)); - } - - function log(address p0, string memory p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256)", p0, p1, p2)); - } - - function log(address p0, string memory p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string)", p0, p1, p2)); - } - - function log(address p0, string memory p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool)", p0, p1, p2)); - } - - function log(address p0, string memory p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address)", p0, p1, p2)); - } - - function log(address p0, bool p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256)", p0, p1, p2)); - } - - function log(address p0, bool p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string)", p0, p1, p2)); - } - - function log(address p0, bool p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool)", p0, p1, p2)); - } - - function log(address p0, bool p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address)", p0, p1, p2)); - } - - function log(address p0, address p1, uint256 p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256)", p0, p1, p2)); - } - - function log(address p0, address p1, string memory p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string)", p0, p1, p2)); - } - - function log(address p0, address p1, bool p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool)", p0, p1, p2)); - } - - function log(address p0, address p1, address p2) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address)", p0, p1, p2)); - } - - function log(uint256 p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,uint256,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,string,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,bool,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, uint256 p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,uint256,address,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,uint256,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,string,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,bool,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, string memory p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,string,address,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,uint256,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,string,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,bool,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, bool p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,bool,address,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,uint256,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,string,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,bool,address)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address,uint256)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address,string)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address,bool)", p0, p1, p2, p3)); - } - - function log(uint256 p0, address p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(uint256,address,address,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,uint256,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,string,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,bool,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, uint256 p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,uint256,address,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,uint256,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,string,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, string memory p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,string,address,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint256,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, bool p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,uint256,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,string,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,address)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address,uint256)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address,string)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address,bool)", p0, p1, p2, p3)); - } - - function log(string memory p0, address p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(string,address,address,address)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256,string)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,uint256,address)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string,string)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,string,address)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool,string)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,bool,address)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address,string)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, uint256 p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,uint256,address,address)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256,string)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint256,address)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,string)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,address)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,string)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,address)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,string)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, string memory p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,address)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256,string)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint256,address)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,string)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,address)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,string)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,address)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,string)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, bool p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,address)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256,string)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint256,address)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,string)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,address)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,string)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,address)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,uint256)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,string)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,bool)", p0, p1, p2, p3)); - } - - function log(bool p0, address p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,address)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256,string)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256,bool)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,uint256,address)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string,string)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string,bool)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,string,address)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool,string)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool,bool)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,bool,address)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address,string)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address,bool)", p0, p1, p2, p3)); - } - - function log(address p0, uint256 p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,uint256,address,address)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256,string)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256,bool)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,uint256,address)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string,string)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string,bool)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,string,address)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,string)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,bool)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,address)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address,string)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address,bool)", p0, p1, p2, p3)); - } - - function log(address p0, string memory p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,string,address,address)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256,string)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256,bool)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint256,address)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,string)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,bool)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,address)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,string)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,bool)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,address)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,string)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,bool)", p0, p1, p2, p3)); - } - - function log(address p0, bool p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,address)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, uint256 p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, uint256 p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256,string)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, uint256 p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256,bool)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, uint256 p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,uint256,address)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, string memory p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, string memory p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string,string)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, string memory p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string,bool)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, string memory p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,string,address)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, bool p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, bool p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,string)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, bool p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,bool)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, bool p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,address)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, address p2, uint256 p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address,uint256)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, address p2, string memory p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address,string)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, address p2, bool p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address,bool)", p0, p1, p2, p3)); - } - - function log(address p0, address p1, address p2, address p3) internal pure { - _sendLogPayload(abi.encodeWithSignature("log(address,address,address,address)", p0, p1, p2, p3)); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/console2.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/console2.sol deleted file mode 100644 index 03531d91d3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/console2.sol +++ /dev/null @@ -1,4 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.4.22 <0.9.0; - -import {console as console2} from "./console.sol"; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC1155.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC1155.sol deleted file mode 100644 index f7dd2b4106..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC1155.sol +++ /dev/null @@ -1,105 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -import "./IERC165.sol"; - -/// @title ERC-1155 Multi Token Standard -/// @dev See https://eips.ethereum.org/EIPS/eip-1155 -/// Note: The ERC-165 identifier for this interface is 0xd9b67a26. -interface IERC1155 is IERC165 { - /// @dev - /// - Either `TransferSingle` or `TransferBatch` MUST emit when tokens are transferred, including zero value transfers as well as minting or burning (see "Safe Transfer Rules" section of the standard). - /// - The `_operator` argument MUST be the address of an account/contract that is approved to make the transfer (SHOULD be msg.sender). - /// - The `_from` argument MUST be the address of the holder whose balance is decreased. - /// - The `_to` argument MUST be the address of the recipient whose balance is increased. - /// - The `_id` argument MUST be the token type being transferred. - /// - The `_value` argument MUST be the number of tokens the holder balance is decreased by and match what the recipient balance is increased by. - /// - When minting/creating tokens, the `_from` argument MUST be set to `0x0` (i.e. zero address). - /// - When burning/destroying tokens, the `_to` argument MUST be set to `0x0` (i.e. zero address). - event TransferSingle( - address indexed _operator, address indexed _from, address indexed _to, uint256 _id, uint256 _value - ); - - /// @dev - /// - Either `TransferSingle` or `TransferBatch` MUST emit when tokens are transferred, including zero value transfers as well as minting or burning (see "Safe Transfer Rules" section of the standard). - /// - The `_operator` argument MUST be the address of an account/contract that is approved to make the transfer (SHOULD be msg.sender). - /// - The `_from` argument MUST be the address of the holder whose balance is decreased. - /// - The `_to` argument MUST be the address of the recipient whose balance is increased. - /// - The `_ids` argument MUST be the list of tokens being transferred. - /// - The `_values` argument MUST be the list of number of tokens (matching the list and order of tokens specified in _ids) the holder balance is decreased by and match what the recipient balance is increased by. - /// - When minting/creating tokens, the `_from` argument MUST be set to `0x0` (i.e. zero address). - /// - When burning/destroying tokens, the `_to` argument MUST be set to `0x0` (i.e. zero address). - event TransferBatch( - address indexed _operator, address indexed _from, address indexed _to, uint256[] _ids, uint256[] _values - ); - - /// @dev MUST emit when approval for a second party/operator address to manage all tokens for an owner address is enabled or disabled (absence of an event assumes disabled). - event ApprovalForAll(address indexed _owner, address indexed _operator, bool _approved); - - /// @dev MUST emit when the URI is updated for a token ID. URIs are defined in RFC 3986. - /// The URI MUST point to a JSON file that conforms to the "ERC-1155 Metadata URI JSON Schema". - event URI(string _value, uint256 indexed _id); - - /// @notice Transfers `_value` amount of an `_id` from the `_from` address to the `_to` address specified (with safety call). - /// @dev Caller must be approved to manage the tokens being transferred out of the `_from` account (see "Approval" section of the standard). - /// - MUST revert if `_to` is the zero address. - /// - MUST revert if balance of holder for token `_id` is lower than the `_value` sent. - /// - MUST revert on any other error. - /// - MUST emit the `TransferSingle` event to reflect the balance change (see "Safe Transfer Rules" section of the standard). - /// - After the above conditions are met, this function MUST check if `_to` is a smart contract (e.g. code size > 0). If so, it MUST call `onERC1155Received` on `_to` and act appropriately (see "Safe Transfer Rules" section of the standard). - /// @param _from Source address - /// @param _to Target address - /// @param _id ID of the token type - /// @param _value Transfer amount - /// @param _data Additional data with no specified format, MUST be sent unaltered in call to `onERC1155Received` on `_to` - function safeTransferFrom(address _from, address _to, uint256 _id, uint256 _value, bytes calldata _data) external; - - /// @notice Transfers `_values` amount(s) of `_ids` from the `_from` address to the `_to` address specified (with safety call). - /// @dev Caller must be approved to manage the tokens being transferred out of the `_from` account (see "Approval" section of the standard). - /// - MUST revert if `_to` is the zero address. - /// - MUST revert if length of `_ids` is not the same as length of `_values`. - /// - MUST revert if any of the balance(s) of the holder(s) for token(s) in `_ids` is lower than the respective amount(s) in `_values` sent to the recipient. - /// - MUST revert on any other error. - /// - MUST emit `TransferSingle` or `TransferBatch` event(s) such that all the balance changes are reflected (see "Safe Transfer Rules" section of the standard). - /// - Balance changes and events MUST follow the ordering of the arrays (_ids[0]/_values[0] before _ids[1]/_values[1], etc). - /// - After the above conditions for the transfer(s) in the batch are met, this function MUST check if `_to` is a smart contract (e.g. code size > 0). If so, it MUST call the relevant `ERC1155TokenReceiver` hook(s) on `_to` and act appropriately (see "Safe Transfer Rules" section of the standard). - /// @param _from Source address - /// @param _to Target address - /// @param _ids IDs of each token type (order and length must match _values array) - /// @param _values Transfer amounts per token type (order and length must match _ids array) - /// @param _data Additional data with no specified format, MUST be sent unaltered in call to the `ERC1155TokenReceiver` hook(s) on `_to` - function safeBatchTransferFrom( - address _from, - address _to, - uint256[] calldata _ids, - uint256[] calldata _values, - bytes calldata _data - ) external; - - /// @notice Get the balance of an account's tokens. - /// @param _owner The address of the token holder - /// @param _id ID of the token - /// @return The _owner's balance of the token type requested - function balanceOf(address _owner, uint256 _id) external view returns (uint256); - - /// @notice Get the balance of multiple account/token pairs - /// @param _owners The addresses of the token holders - /// @param _ids ID of the tokens - /// @return The _owner's balance of the token types requested (i.e. balance for each (owner, id) pair) - function balanceOfBatch(address[] calldata _owners, uint256[] calldata _ids) - external - view - returns (uint256[] memory); - - /// @notice Enable or disable approval for a third party ("operator") to manage all of the caller's tokens. - /// @dev MUST emit the ApprovalForAll event on success. - /// @param _operator Address to add to the set of authorized operators - /// @param _approved True if the operator is approved, false to revoke approval - function setApprovalForAll(address _operator, bool _approved) external; - - /// @notice Queries the approval status of an operator for a given owner. - /// @param _owner The owner of the tokens - /// @param _operator Address of authorized operator - /// @return True if the operator is approved, false if not - function isApprovedForAll(address _owner, address _operator) external view returns (bool); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC165.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC165.sol deleted file mode 100644 index 9af4bf800f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC165.sol +++ /dev/null @@ -1,12 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -interface IERC165 { - /// @notice Query if a contract implements an interface - /// @param interfaceID The interface identifier, as specified in ERC-165 - /// @dev Interface identification is specified in ERC-165. This function - /// uses less than 30,000 gas. - /// @return `true` if the contract implements `interfaceID` and - /// `interfaceID` is not 0xffffffff, `false` otherwise - function supportsInterface(bytes4 interfaceID) external view returns (bool); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC20.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC20.sol deleted file mode 100644 index ba40806c3b..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC20.sol +++ /dev/null @@ -1,43 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -/// @dev Interface of the ERC20 standard as defined in the EIP. -/// @dev This includes the optional name, symbol, and decimals metadata. -interface IERC20 { - /// @dev Emitted when `value` tokens are moved from one account (`from`) to another (`to`). - event Transfer(address indexed from, address indexed to, uint256 value); - - /// @dev Emitted when the allowance of a `spender` for an `owner` is set, where `value` - /// is the new allowance. - event Approval(address indexed owner, address indexed spender, uint256 value); - - /// @notice Returns the amount of tokens in existence. - function totalSupply() external view returns (uint256); - - /// @notice Returns the amount of tokens owned by `account`. - function balanceOf(address account) external view returns (uint256); - - /// @notice Moves `amount` tokens from the caller's account to `to`. - function transfer(address to, uint256 amount) external returns (bool); - - /// @notice Returns the remaining number of tokens that `spender` is allowed - /// to spend on behalf of `owner` - function allowance(address owner, address spender) external view returns (uint256); - - /// @notice Sets `amount` as the allowance of `spender` over the caller's tokens. - /// @dev Be aware of front-running risks: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 - function approve(address spender, uint256 amount) external returns (bool); - - /// @notice Moves `amount` tokens from `from` to `to` using the allowance mechanism. - /// `amount` is then deducted from the caller's allowance. - function transferFrom(address from, address to, uint256 amount) external returns (bool); - - /// @notice Returns the name of the token. - function name() external view returns (string memory); - - /// @notice Returns the symbol of the token. - function symbol() external view returns (string memory); - - /// @notice Returns the decimals places of the token. - function decimals() external view returns (uint8); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC4626.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC4626.sol deleted file mode 100644 index 391eeb4de7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC4626.sol +++ /dev/null @@ -1,190 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -import "./IERC20.sol"; - -/// @dev Interface of the ERC4626 "Tokenized Vault Standard", as defined in -/// https://eips.ethereum.org/EIPS/eip-4626 -interface IERC4626 is IERC20 { - event Deposit(address indexed sender, address indexed owner, uint256 assets, uint256 shares); - - event Withdraw( - address indexed sender, address indexed receiver, address indexed owner, uint256 assets, uint256 shares - ); - - /// @notice Returns the address of the underlying token used for the Vault for accounting, depositing, and withdrawing. - /// @dev - /// - MUST be an ERC-20 token contract. - /// - MUST NOT revert. - function asset() external view returns (address assetTokenAddress); - - /// @notice Returns the total amount of the underlying asset that is “managed” by Vault. - /// @dev - /// - SHOULD include any compounding that occurs from yield. - /// - MUST be inclusive of any fees that are charged against assets in the Vault. - /// - MUST NOT revert. - function totalAssets() external view returns (uint256 totalManagedAssets); - - /// @notice Returns the amount of shares that the Vault would exchange for the amount of assets provided, in an ideal - /// scenario where all the conditions are met. - /// @dev - /// - MUST NOT be inclusive of any fees that are charged against assets in the Vault. - /// - MUST NOT show any variations depending on the caller. - /// - MUST NOT reflect slippage or other on-chain conditions, when performing the actual exchange. - /// - MUST NOT revert. - /// - /// NOTE: This calculation MAY NOT reflect the “per-user” price-per-share, and instead should reflect the - /// “average-user’s” price-per-share, meaning what the average user should expect to see when exchanging to and - /// from. - function convertToShares(uint256 assets) external view returns (uint256 shares); - - /// @notice Returns the amount of assets that the Vault would exchange for the amount of shares provided, in an ideal - /// scenario where all the conditions are met. - /// @dev - /// - MUST NOT be inclusive of any fees that are charged against assets in the Vault. - /// - MUST NOT show any variations depending on the caller. - /// - MUST NOT reflect slippage or other on-chain conditions, when performing the actual exchange. - /// - MUST NOT revert. - /// - /// NOTE: This calculation MAY NOT reflect the “per-user” price-per-share, and instead should reflect the - /// “average-user’s” price-per-share, meaning what the average user should expect to see when exchanging to and - /// from. - function convertToAssets(uint256 shares) external view returns (uint256 assets); - - /// @notice Returns the maximum amount of the underlying asset that can be deposited into the Vault for the receiver, - /// through a deposit call. - /// @dev - /// - MUST return a limited value if receiver is subject to some deposit limit. - /// - MUST return 2 ** 256 - 1 if there is no limit on the maximum amount of assets that may be deposited. - /// - MUST NOT revert. - function maxDeposit(address receiver) external view returns (uint256 maxAssets); - - /// @notice Allows an on-chain or off-chain user to simulate the effects of their deposit at the current block, given - /// current on-chain conditions. - /// @dev - /// - MUST return as close to and no more than the exact amount of Vault shares that would be minted in a deposit - /// call in the same transaction. I.e. deposit should return the same or more shares as previewDeposit if called - /// in the same transaction. - /// - MUST NOT account for deposit limits like those returned from maxDeposit and should always act as though the - /// deposit would be accepted, regardless if the user has enough tokens approved, etc. - /// - MUST be inclusive of deposit fees. Integrators should be aware of the existence of deposit fees. - /// - MUST NOT revert. - /// - /// NOTE: any unfavorable discrepancy between convertToShares and previewDeposit SHOULD be considered slippage in - /// share price or some other type of condition, meaning the depositor will lose assets by depositing. - function previewDeposit(uint256 assets) external view returns (uint256 shares); - - /// @notice Mints shares Vault shares to receiver by depositing exactly amount of underlying tokens. - /// @dev - /// - MUST emit the Deposit event. - /// - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - /// deposit execution, and are accounted for during deposit. - /// - MUST revert if all of assets cannot be deposited (due to deposit limit being reached, slippage, the user not - /// approving enough underlying tokens to the Vault contract, etc). - /// - /// NOTE: most implementations will require pre-approval of the Vault with the Vault’s underlying asset token. - function deposit(uint256 assets, address receiver) external returns (uint256 shares); - - /// @notice Returns the maximum amount of the Vault shares that can be minted for the receiver, through a mint call. - /// @dev - /// - MUST return a limited value if receiver is subject to some mint limit. - /// - MUST return 2 ** 256 - 1 if there is no limit on the maximum amount of shares that may be minted. - /// - MUST NOT revert. - function maxMint(address receiver) external view returns (uint256 maxShares); - - /// @notice Allows an on-chain or off-chain user to simulate the effects of their mint at the current block, given - /// current on-chain conditions. - /// @dev - /// - MUST return as close to and no fewer than the exact amount of assets that would be deposited in a mint call - /// in the same transaction. I.e. mint should return the same or fewer assets as previewMint if called in the - /// same transaction. - /// - MUST NOT account for mint limits like those returned from maxMint and should always act as though the mint - /// would be accepted, regardless if the user has enough tokens approved, etc. - /// - MUST be inclusive of deposit fees. Integrators should be aware of the existence of deposit fees. - /// - MUST NOT revert. - /// - /// NOTE: any unfavorable discrepancy between convertToAssets and previewMint SHOULD be considered slippage in - /// share price or some other type of condition, meaning the depositor will lose assets by minting. - function previewMint(uint256 shares) external view returns (uint256 assets); - - /// @notice Mints exactly shares Vault shares to receiver by depositing amount of underlying tokens. - /// @dev - /// - MUST emit the Deposit event. - /// - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the mint - /// execution, and are accounted for during mint. - /// - MUST revert if all of shares cannot be minted (due to deposit limit being reached, slippage, the user not - /// approving enough underlying tokens to the Vault contract, etc). - /// - /// NOTE: most implementations will require pre-approval of the Vault with the Vault’s underlying asset token. - function mint(uint256 shares, address receiver) external returns (uint256 assets); - - /// @notice Returns the maximum amount of the underlying asset that can be withdrawn from the owner balance in the - /// Vault, through a withdrawal call. - /// @dev - /// - MUST return a limited value if owner is subject to some withdrawal limit or timelock. - /// - MUST NOT revert. - function maxWithdraw(address owner) external view returns (uint256 maxAssets); - - /// @notice Allows an on-chain or off-chain user to simulate the effects of their withdrawal at the current block, - /// given current on-chain conditions. - /// @dev - /// - MUST return as close to and no fewer than the exact amount of Vault shares that would be burned in a withdraw - /// call in the same transaction. I.e. withdraw should return the same or fewer shares as previewWithdraw if - /// called - /// in the same transaction. - /// - MUST NOT account for withdrawal limits like those returned from maxWithdraw and should always act as though - /// the withdrawal would be accepted, regardless if the user has enough shares, etc. - /// - MUST be inclusive of withdrawal fees. Integrators should be aware of the existence of withdrawal fees. - /// - MUST NOT revert. - /// - /// NOTE: any unfavorable discrepancy between convertToShares and previewWithdraw SHOULD be considered slippage in - /// share price or some other type of condition, meaning the depositor will lose assets by depositing. - function previewWithdraw(uint256 assets) external view returns (uint256 shares); - - /// @notice Burns shares from owner and sends exactly assets of underlying tokens to receiver. - /// @dev - /// - MUST emit the Withdraw event. - /// - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - /// withdraw execution, and are accounted for during withdrawal. - /// - MUST revert if all of assets cannot be withdrawn (due to withdrawal limit being reached, slippage, the owner - /// not having enough shares, etc). - /// - /// Note that some implementations will require pre-requesting to the Vault before a withdrawal may be performed. - /// Those methods should be performed separately. - function withdraw(uint256 assets, address receiver, address owner) external returns (uint256 shares); - - /// @notice Returns the maximum amount of Vault shares that can be redeemed from the owner balance in the Vault, - /// through a redeem call. - /// @dev - /// - MUST return a limited value if owner is subject to some withdrawal limit or timelock. - /// - MUST return balanceOf(owner) if owner is not subject to any withdrawal limit or timelock. - /// - MUST NOT revert. - function maxRedeem(address owner) external view returns (uint256 maxShares); - - /// @notice Allows an on-chain or off-chain user to simulate the effects of their redeemption at the current block, - /// given current on-chain conditions. - /// @dev - /// - MUST return as close to and no more than the exact amount of assets that would be withdrawn in a redeem call - /// in the same transaction. I.e. redeem should return the same or more assets as previewRedeem if called in the - /// same transaction. - /// - MUST NOT account for redemption limits like those returned from maxRedeem and should always act as though the - /// redemption would be accepted, regardless if the user has enough shares, etc. - /// - MUST be inclusive of withdrawal fees. Integrators should be aware of the existence of withdrawal fees. - /// - MUST NOT revert. - /// - /// NOTE: any unfavorable discrepancy between convertToAssets and previewRedeem SHOULD be considered slippage in - /// share price or some other type of condition, meaning the depositor will lose assets by redeeming. - function previewRedeem(uint256 shares) external view returns (uint256 assets); - - /// @notice Burns exactly shares from owner and sends assets of underlying tokens to receiver. - /// @dev - /// - MUST emit the Withdraw event. - /// - MAY support an additional flow in which the underlying tokens are owned by the Vault contract before the - /// redeem execution, and are accounted for during redeem. - /// - MUST revert if all of shares cannot be redeemed (due to withdrawal limit being reached, slippage, the owner - /// not having enough shares, etc). - /// - /// NOTE: some implementations will require pre-requesting to the Vault before a withdrawal may be performed. - /// Those methods should be performed separately. - function redeem(uint256 shares, address receiver, address owner) external returns (uint256 assets); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC721.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC721.sol deleted file mode 100644 index 0a16f45cc5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IERC721.sol +++ /dev/null @@ -1,164 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; - -import "./IERC165.sol"; - -/// @title ERC-721 Non-Fungible Token Standard -/// @dev See https://eips.ethereum.org/EIPS/eip-721 -/// Note: the ERC-165 identifier for this interface is 0x80ac58cd. -interface IERC721 is IERC165 { - /// @dev This emits when ownership of any NFT changes by any mechanism. - /// This event emits when NFTs are created (`from` == 0) and destroyed - /// (`to` == 0). Exception: during contract creation, any number of NFTs - /// may be created and assigned without emitting Transfer. At the time of - /// any transfer, the approved address for that NFT (if any) is reset to none. - event Transfer(address indexed _from, address indexed _to, uint256 indexed _tokenId); - - /// @dev This emits when the approved address for an NFT is changed or - /// reaffirmed. The zero address indicates there is no approved address. - /// When a Transfer event emits, this also indicates that the approved - /// address for that NFT (if any) is reset to none. - event Approval(address indexed _owner, address indexed _approved, uint256 indexed _tokenId); - - /// @dev This emits when an operator is enabled or disabled for an owner. - /// The operator can manage all NFTs of the owner. - event ApprovalForAll(address indexed _owner, address indexed _operator, bool _approved); - - /// @notice Count all NFTs assigned to an owner - /// @dev NFTs assigned to the zero address are considered invalid, and this - /// function throws for queries about the zero address. - /// @param _owner An address for whom to query the balance - /// @return The number of NFTs owned by `_owner`, possibly zero - function balanceOf(address _owner) external view returns (uint256); - - /// @notice Find the owner of an NFT - /// @dev NFTs assigned to zero address are considered invalid, and queries - /// about them do throw. - /// @param _tokenId The identifier for an NFT - /// @return The address of the owner of the NFT - function ownerOf(uint256 _tokenId) external view returns (address); - - /// @notice Transfers the ownership of an NFT from one address to another address - /// @dev Throws unless `msg.sender` is the current owner, an authorized - /// operator, or the approved address for this NFT. Throws if `_from` is - /// not the current owner. Throws if `_to` is the zero address. Throws if - /// `_tokenId` is not a valid NFT. When transfer is complete, this function - /// checks if `_to` is a smart contract (code size > 0). If so, it calls - /// `onERC721Received` on `_to` and throws if the return value is not - /// `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`. - /// @param _from The current owner of the NFT - /// @param _to The new owner - /// @param _tokenId The NFT to transfer - /// @param data Additional data with no specified format, sent in call to `_to` - function safeTransferFrom(address _from, address _to, uint256 _tokenId, bytes calldata data) external payable; - - /// @notice Transfers the ownership of an NFT from one address to another address - /// @dev This works identically to the other function with an extra data parameter, - /// except this function just sets data to "". - /// @param _from The current owner of the NFT - /// @param _to The new owner - /// @param _tokenId The NFT to transfer - function safeTransferFrom(address _from, address _to, uint256 _tokenId) external payable; - - /// @notice Transfer ownership of an NFT -- THE CALLER IS RESPONSIBLE - /// TO CONFIRM THAT `_to` IS CAPABLE OF RECEIVING NFTS OR ELSE - /// THEY MAY BE PERMANENTLY LOST - /// @dev Throws unless `msg.sender` is the current owner, an authorized - /// operator, or the approved address for this NFT. Throws if `_from` is - /// not the current owner. Throws if `_to` is the zero address. Throws if - /// `_tokenId` is not a valid NFT. - /// @param _from The current owner of the NFT - /// @param _to The new owner - /// @param _tokenId The NFT to transfer - function transferFrom(address _from, address _to, uint256 _tokenId) external payable; - - /// @notice Change or reaffirm the approved address for an NFT - /// @dev The zero address indicates there is no approved address. - /// Throws unless `msg.sender` is the current NFT owner, or an authorized - /// operator of the current owner. - /// @param _approved The new approved NFT controller - /// @param _tokenId The NFT to approve - function approve(address _approved, uint256 _tokenId) external payable; - - /// @notice Enable or disable approval for a third party ("operator") to manage - /// all of `msg.sender`'s assets - /// @dev Emits the ApprovalForAll event. The contract MUST allow - /// multiple operators per owner. - /// @param _operator Address to add to the set of authorized operators - /// @param _approved True if the operator is approved, false to revoke approval - function setApprovalForAll(address _operator, bool _approved) external; - - /// @notice Get the approved address for a single NFT - /// @dev Throws if `_tokenId` is not a valid NFT. - /// @param _tokenId The NFT to find the approved address for - /// @return The approved address for this NFT, or the zero address if there is none - function getApproved(uint256 _tokenId) external view returns (address); - - /// @notice Query if an address is an authorized operator for another address - /// @param _owner The address that owns the NFTs - /// @param _operator The address that acts on behalf of the owner - /// @return True if `_operator` is an approved operator for `_owner`, false otherwise - function isApprovedForAll(address _owner, address _operator) external view returns (bool); -} - -/// @dev Note: the ERC-165 identifier for this interface is 0x150b7a02. -interface IERC721TokenReceiver { - /// @notice Handle the receipt of an NFT - /// @dev The ERC721 smart contract calls this function on the recipient - /// after a `transfer`. This function MAY throw to revert and reject the - /// transfer. Return of other than the magic value MUST result in the - /// transaction being reverted. - /// Note: the contract address is always the message sender. - /// @param _operator The address which called `safeTransferFrom` function - /// @param _from The address which previously owned the token - /// @param _tokenId The NFT identifier which is being transferred - /// @param _data Additional data with no specified format - /// @return `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))` - /// unless throwing - function onERC721Received(address _operator, address _from, uint256 _tokenId, bytes calldata _data) - external - returns (bytes4); -} - -/// @title ERC-721 Non-Fungible Token Standard, optional metadata extension -/// @dev See https://eips.ethereum.org/EIPS/eip-721 -/// Note: the ERC-165 identifier for this interface is 0x5b5e139f. -interface IERC721Metadata is IERC721 { - /// @notice A descriptive name for a collection of NFTs in this contract - function name() external view returns (string memory _name); - - /// @notice An abbreviated name for NFTs in this contract - function symbol() external view returns (string memory _symbol); - - /// @notice A distinct Uniform Resource Identifier (URI) for a given asset. - /// @dev Throws if `_tokenId` is not a valid NFT. URIs are defined in RFC - /// 3986. The URI may point to a JSON file that conforms to the "ERC721 - /// Metadata JSON Schema". - function tokenURI(uint256 _tokenId) external view returns (string memory); -} - -/// @title ERC-721 Non-Fungible Token Standard, optional enumeration extension -/// @dev See https://eips.ethereum.org/EIPS/eip-721 -/// Note: the ERC-165 identifier for this interface is 0x780e9d63. -interface IERC721Enumerable is IERC721 { - /// @notice Count NFTs tracked by this contract - /// @return A count of valid NFTs tracked by this contract, where each one of - /// them has an assigned and queryable owner not equal to the zero address - function totalSupply() external view returns (uint256); - - /// @notice Enumerate valid NFTs - /// @dev Throws if `_index` >= `totalSupply()`. - /// @param _index A counter less than `totalSupply()` - /// @return The token identifier for the `_index`th NFT, - /// (sort order not specified) - function tokenByIndex(uint256 _index) external view returns (uint256); - - /// @notice Enumerate NFTs assigned to an owner - /// @dev Throws if `_index` >= `balanceOf(_owner)` or if - /// `_owner` is the zero address, representing invalid NFTs. - /// @param _owner An address where we are interested in NFTs owned by them - /// @param _index A counter less than `balanceOf(_owner)` - /// @return The token identifier for the `_index`th NFT assigned to `_owner`, - /// (sort order not specified) - function tokenOfOwnerByIndex(address _owner, uint256 _index) external view returns (uint256); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IMulticall3.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IMulticall3.sol deleted file mode 100644 index 0d031b71dc..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/interfaces/IMulticall3.sol +++ /dev/null @@ -1,73 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -interface IMulticall3 { - struct Call { - address target; - bytes callData; - } - - struct Call3 { - address target; - bool allowFailure; - bytes callData; - } - - struct Call3Value { - address target; - bool allowFailure; - uint256 value; - bytes callData; - } - - struct Result { - bool success; - bytes returnData; - } - - function aggregate(Call[] calldata calls) - external - payable - returns (uint256 blockNumber, bytes[] memory returnData); - - function aggregate3(Call3[] calldata calls) external payable returns (Result[] memory returnData); - - function aggregate3Value(Call3Value[] calldata calls) external payable returns (Result[] memory returnData); - - function blockAndAggregate(Call[] calldata calls) - external - payable - returns (uint256 blockNumber, bytes32 blockHash, Result[] memory returnData); - - function getBasefee() external view returns (uint256 basefee); - - function getBlockHash(uint256 blockNumber) external view returns (bytes32 blockHash); - - function getBlockNumber() external view returns (uint256 blockNumber); - - function getChainId() external view returns (uint256 chainid); - - function getCurrentBlockCoinbase() external view returns (address coinbase); - - function getCurrentBlockDifficulty() external view returns (uint256 difficulty); - - function getCurrentBlockGasLimit() external view returns (uint256 gaslimit); - - function getCurrentBlockTimestamp() external view returns (uint256 timestamp); - - function getEthBalance(address addr) external view returns (uint256 balance); - - function getLastBlockHash() external view returns (bytes32 blockHash); - - function tryAggregate(bool requireSuccess, Call[] calldata calls) - external - payable - returns (Result[] memory returnData); - - function tryBlockAndAggregate(bool requireSuccess, Call[] calldata calls) - external - payable - returns (uint256 blockNumber, bytes32 blockHash, Result[] memory returnData); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/mocks/MockERC20.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/mocks/MockERC20.sol deleted file mode 100644 index 2a022fa34d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/mocks/MockERC20.sol +++ /dev/null @@ -1,234 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -import {IERC20} from "../interfaces/IERC20.sol"; - -/// @notice This is a mock contract of the ERC20 standard for testing purposes only, it SHOULD NOT be used in production. -/// @dev Forked from: https://github.com/transmissions11/solmate/blob/0384dbaaa4fcb5715738a9254a7c0a4cb62cf458/src/tokens/ERC20.sol -contract MockERC20 is IERC20 { - /*////////////////////////////////////////////////////////////// - METADATA STORAGE - //////////////////////////////////////////////////////////////*/ - - string internal _name; - - string internal _symbol; - - uint8 internal _decimals; - - function name() external view override returns (string memory) { - return _name; - } - - function symbol() external view override returns (string memory) { - return _symbol; - } - - function decimals() external view override returns (uint8) { - return _decimals; - } - - /*////////////////////////////////////////////////////////////// - ERC20 STORAGE - //////////////////////////////////////////////////////////////*/ - - uint256 internal _totalSupply; - - mapping(address => uint256) internal _balanceOf; - - mapping(address => mapping(address => uint256)) internal _allowance; - - function totalSupply() external view override returns (uint256) { - return _totalSupply; - } - - function balanceOf(address owner) external view override returns (uint256) { - return _balanceOf[owner]; - } - - function allowance(address owner, address spender) external view override returns (uint256) { - return _allowance[owner][spender]; - } - - /*////////////////////////////////////////////////////////////// - EIP-2612 STORAGE - //////////////////////////////////////////////////////////////*/ - - uint256 internal INITIAL_CHAIN_ID; - - bytes32 internal INITIAL_DOMAIN_SEPARATOR; - - mapping(address => uint256) public nonces; - - /*////////////////////////////////////////////////////////////// - INITIALIZE - //////////////////////////////////////////////////////////////*/ - - /// @dev A bool to track whether the contract has been initialized. - bool private initialized; - - /// @dev To hide constructor warnings across solc versions due to different constructor visibility requirements and - /// syntaxes, we add an initialization function that can be called only once. - function initialize(string memory name_, string memory symbol_, uint8 decimals_) public { - require(!initialized, "ALREADY_INITIALIZED"); - - _name = name_; - _symbol = symbol_; - _decimals = decimals_; - - INITIAL_CHAIN_ID = _pureChainId(); - INITIAL_DOMAIN_SEPARATOR = computeDomainSeparator(); - - initialized = true; - } - - /*////////////////////////////////////////////////////////////// - ERC20 LOGIC - //////////////////////////////////////////////////////////////*/ - - function approve(address spender, uint256 amount) public virtual override returns (bool) { - _allowance[msg.sender][spender] = amount; - - emit Approval(msg.sender, spender, amount); - - return true; - } - - function transfer(address to, uint256 amount) public virtual override returns (bool) { - _balanceOf[msg.sender] = _sub(_balanceOf[msg.sender], amount); - _balanceOf[to] = _add(_balanceOf[to], amount); - - emit Transfer(msg.sender, to, amount); - - return true; - } - - function transferFrom(address from, address to, uint256 amount) public virtual override returns (bool) { - uint256 allowed = _allowance[from][msg.sender]; // Saves gas for limited approvals. - - if (allowed != ~uint256(0)) _allowance[from][msg.sender] = _sub(allowed, amount); - - _balanceOf[from] = _sub(_balanceOf[from], amount); - _balanceOf[to] = _add(_balanceOf[to], amount); - - emit Transfer(from, to, amount); - - return true; - } - - /*////////////////////////////////////////////////////////////// - EIP-2612 LOGIC - //////////////////////////////////////////////////////////////*/ - - function permit(address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s) - public - virtual - { - require(deadline >= block.timestamp, "PERMIT_DEADLINE_EXPIRED"); - - address recoveredAddress = ecrecover( - keccak256( - abi.encodePacked( - "\x19\x01", - DOMAIN_SEPARATOR(), - keccak256( - abi.encode( - keccak256( - "Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)" - ), - owner, - spender, - value, - nonces[owner]++, - deadline - ) - ) - ) - ), - v, - r, - s - ); - - require(recoveredAddress != address(0) && recoveredAddress == owner, "INVALID_SIGNER"); - - _allowance[recoveredAddress][spender] = value; - - emit Approval(owner, spender, value); - } - - function DOMAIN_SEPARATOR() public view virtual returns (bytes32) { - return _pureChainId() == INITIAL_CHAIN_ID ? INITIAL_DOMAIN_SEPARATOR : computeDomainSeparator(); - } - - function computeDomainSeparator() internal view virtual returns (bytes32) { - return keccak256( - abi.encode( - keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"), - keccak256(bytes(_name)), - keccak256("1"), - _pureChainId(), - address(this) - ) - ); - } - - /*////////////////////////////////////////////////////////////// - INTERNAL MINT/BURN LOGIC - //////////////////////////////////////////////////////////////*/ - - function _mint(address to, uint256 amount) internal virtual { - _totalSupply = _add(_totalSupply, amount); - _balanceOf[to] = _add(_balanceOf[to], amount); - - emit Transfer(address(0), to, amount); - } - - function _burn(address from, uint256 amount) internal virtual { - _balanceOf[from] = _sub(_balanceOf[from], amount); - _totalSupply = _sub(_totalSupply, amount); - - emit Transfer(from, address(0), amount); - } - - /*////////////////////////////////////////////////////////////// - INTERNAL SAFE MATH LOGIC - //////////////////////////////////////////////////////////////*/ - - function _add(uint256 a, uint256 b) internal pure returns (uint256) { - uint256 c = a + b; - require(c >= a, "ERC20: addition overflow"); - return c; - } - - function _sub(uint256 a, uint256 b) internal pure returns (uint256) { - require(a >= b, "ERC20: subtraction underflow"); - return a - b; - } - - /*////////////////////////////////////////////////////////////// - HELPERS - //////////////////////////////////////////////////////////////*/ - - // We use this complex approach of `_viewChainId` and `_pureChainId` to ensure there are no - // compiler warnings when accessing chain ID in any solidity version supported by forge-std. We - // can't simply access the chain ID in a normal view or pure function because the solc View Pure - // Checker changed `chainid` from pure to view in 0.8.0. - function _viewChainId() private view returns (uint256 chainId) { - // Assembly required since `block.chainid` was introduced in 0.8.0. - assembly { - chainId := chainid() - } - - address(this); // Silence warnings in older Solc versions. - } - - function _pureChainId() private pure returns (uint256 chainId) { - function() internal view returns (uint256) fnIn = _viewChainId; - function() internal pure returns (uint256) pureChainId; - assembly { - pureChainId := fnIn - } - chainId = pureChainId(); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/mocks/MockERC721.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/mocks/MockERC721.sol deleted file mode 100644 index 7a4909e58c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/mocks/MockERC721.sol +++ /dev/null @@ -1,231 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -import {IERC721Metadata, IERC721TokenReceiver} from "../interfaces/IERC721.sol"; - -/// @notice This is a mock contract of the ERC721 standard for testing purposes only, it SHOULD NOT be used in production. -/// @dev Forked from: https://github.com/transmissions11/solmate/blob/0384dbaaa4fcb5715738a9254a7c0a4cb62cf458/src/tokens/ERC721.sol -contract MockERC721 is IERC721Metadata { - /*////////////////////////////////////////////////////////////// - METADATA STORAGE/LOGIC - //////////////////////////////////////////////////////////////*/ - - string internal _name; - - string internal _symbol; - - function name() external view override returns (string memory) { - return _name; - } - - function symbol() external view override returns (string memory) { - return _symbol; - } - - function tokenURI(uint256 id) public view virtual override returns (string memory) {} - - /*////////////////////////////////////////////////////////////// - ERC721 BALANCE/OWNER STORAGE - //////////////////////////////////////////////////////////////*/ - - mapping(uint256 => address) internal _ownerOf; - - mapping(address => uint256) internal _balanceOf; - - function ownerOf(uint256 id) public view virtual override returns (address owner) { - require((owner = _ownerOf[id]) != address(0), "NOT_MINTED"); - } - - function balanceOf(address owner) public view virtual override returns (uint256) { - require(owner != address(0), "ZERO_ADDRESS"); - - return _balanceOf[owner]; - } - - /*////////////////////////////////////////////////////////////// - ERC721 APPROVAL STORAGE - //////////////////////////////////////////////////////////////*/ - - mapping(uint256 => address) internal _getApproved; - - mapping(address => mapping(address => bool)) internal _isApprovedForAll; - - function getApproved(uint256 id) public view virtual override returns (address) { - return _getApproved[id]; - } - - function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { - return _isApprovedForAll[owner][operator]; - } - - /*////////////////////////////////////////////////////////////// - INITIALIZE - //////////////////////////////////////////////////////////////*/ - - /// @dev A bool to track whether the contract has been initialized. - bool private initialized; - - /// @dev To hide constructor warnings across solc versions due to different constructor visibility requirements and - /// syntaxes, we add an initialization function that can be called only once. - function initialize(string memory name_, string memory symbol_) public { - require(!initialized, "ALREADY_INITIALIZED"); - - _name = name_; - _symbol = symbol_; - - initialized = true; - } - - /*////////////////////////////////////////////////////////////// - ERC721 LOGIC - //////////////////////////////////////////////////////////////*/ - - function approve(address spender, uint256 id) public payable virtual override { - address owner = _ownerOf[id]; - - require(msg.sender == owner || _isApprovedForAll[owner][msg.sender], "NOT_AUTHORIZED"); - - _getApproved[id] = spender; - - emit Approval(owner, spender, id); - } - - function setApprovalForAll(address operator, bool approved) public virtual override { - _isApprovedForAll[msg.sender][operator] = approved; - - emit ApprovalForAll(msg.sender, operator, approved); - } - - function transferFrom(address from, address to, uint256 id) public payable virtual override { - require(from == _ownerOf[id], "WRONG_FROM"); - - require(to != address(0), "INVALID_RECIPIENT"); - - require( - msg.sender == from || _isApprovedForAll[from][msg.sender] || msg.sender == _getApproved[id], - "NOT_AUTHORIZED" - ); - - // Underflow of the sender's balance is impossible because we check for - // ownership above and the recipient's balance can't realistically overflow. - _balanceOf[from]--; - - _balanceOf[to]++; - - _ownerOf[id] = to; - - delete _getApproved[id]; - - emit Transfer(from, to, id); - } - - function safeTransferFrom(address from, address to, uint256 id) public payable virtual override { - transferFrom(from, to, id); - - require( - !_isContract(to) - || IERC721TokenReceiver(to).onERC721Received(msg.sender, from, id, "") - == IERC721TokenReceiver.onERC721Received.selector, - "UNSAFE_RECIPIENT" - ); - } - - function safeTransferFrom(address from, address to, uint256 id, bytes memory data) - public - payable - virtual - override - { - transferFrom(from, to, id); - - require( - !_isContract(to) - || IERC721TokenReceiver(to).onERC721Received(msg.sender, from, id, data) - == IERC721TokenReceiver.onERC721Received.selector, - "UNSAFE_RECIPIENT" - ); - } - - /*////////////////////////////////////////////////////////////// - ERC165 LOGIC - //////////////////////////////////////////////////////////////*/ - - function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { - return interfaceId == 0x01ffc9a7 // ERC165 Interface ID for ERC165 - || interfaceId == 0x80ac58cd // ERC165 Interface ID for ERC721 - || interfaceId == 0x5b5e139f; // ERC165 Interface ID for ERC721Metadata - } - - /*////////////////////////////////////////////////////////////// - INTERNAL MINT/BURN LOGIC - //////////////////////////////////////////////////////////////*/ - - function _mint(address to, uint256 id) internal virtual { - require(to != address(0), "INVALID_RECIPIENT"); - - require(_ownerOf[id] == address(0), "ALREADY_MINTED"); - - // Counter overflow is incredibly unrealistic. - - _balanceOf[to]++; - - _ownerOf[id] = to; - - emit Transfer(address(0), to, id); - } - - function _burn(uint256 id) internal virtual { - address owner = _ownerOf[id]; - - require(owner != address(0), "NOT_MINTED"); - - _balanceOf[owner]--; - - delete _ownerOf[id]; - - delete _getApproved[id]; - - emit Transfer(owner, address(0), id); - } - - /*////////////////////////////////////////////////////////////// - INTERNAL SAFE MINT LOGIC - //////////////////////////////////////////////////////////////*/ - - function _safeMint(address to, uint256 id) internal virtual { - _mint(to, id); - - require( - !_isContract(to) - || IERC721TokenReceiver(to).onERC721Received(msg.sender, address(0), id, "") - == IERC721TokenReceiver.onERC721Received.selector, - "UNSAFE_RECIPIENT" - ); - } - - function _safeMint(address to, uint256 id, bytes memory data) internal virtual { - _mint(to, id); - - require( - !_isContract(to) - || IERC721TokenReceiver(to).onERC721Received(msg.sender, address(0), id, data) - == IERC721TokenReceiver.onERC721Received.selector, - "UNSAFE_RECIPIENT" - ); - } - - /*////////////////////////////////////////////////////////////// - HELPERS - //////////////////////////////////////////////////////////////*/ - - function _isContract(address _addr) private view returns (bool) { - uint256 codeLength; - - // Assembly required for versions < 0.8.0 to check extcodesize. - assembly { - codeLength := extcodesize(_addr) - } - - return codeLength > 0; - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/safeconsole.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/safeconsole.sol deleted file mode 100644 index 87c475a5b0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/src/safeconsole.sol +++ /dev/null @@ -1,13937 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -/// @author philogy -/// @dev Code generated automatically by script. -library safeconsole { - uint256 constant CONSOLE_ADDR = 0x000000000000000000000000000000000000000000636F6e736F6c652e6c6f67; - - // Credit to [0age](https://twitter.com/z0age/status/1654922202930888704) and [0xdapper](https://github.com/foundry-rs/forge-std/pull/374) - // for the view-to-pure log trick. - function _sendLogPayload(uint256 offset, uint256 size) private pure { - function(uint256, uint256) internal view fnIn = _sendLogPayloadView; - function(uint256, uint256) internal pure pureSendLogPayload; - /// @solidity memory-safe-assembly - assembly { - pureSendLogPayload := fnIn - } - pureSendLogPayload(offset, size); - } - - function _sendLogPayloadView(uint256 offset, uint256 size) private view { - /// @solidity memory-safe-assembly - assembly { - pop(staticcall(gas(), CONSOLE_ADDR, offset, size, 0x0, 0x0)) - } - } - - function _memcopy(uint256 fromOffset, uint256 toOffset, uint256 length) private pure { - function(uint256, uint256, uint256) internal view fnIn = _memcopyView; - function(uint256, uint256, uint256) internal pure pureMemcopy; - /// @solidity memory-safe-assembly - assembly { - pureMemcopy := fnIn - } - pureMemcopy(fromOffset, toOffset, length); - } - - function _memcopyView(uint256 fromOffset, uint256 toOffset, uint256 length) private view { - /// @solidity memory-safe-assembly - assembly { - pop(staticcall(gas(), 0x4, fromOffset, length, toOffset, length)) - } - } - - function logMemory(uint256 offset, uint256 length) internal pure { - if (offset >= 0x60) { - // Sufficient memory before slice to prepare call header. - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(sub(offset, 0x60)) - m1 := mload(sub(offset, 0x40)) - m2 := mload(sub(offset, 0x20)) - // Selector of `log(bytes)`. - mstore(sub(offset, 0x60), 0x0be77f56) - mstore(sub(offset, 0x40), 0x20) - mstore(sub(offset, 0x20), length) - } - _sendLogPayload(offset - 0x44, length + 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(sub(offset, 0x60), m0) - mstore(sub(offset, 0x40), m1) - mstore(sub(offset, 0x20), m2) - } - } else { - // Insufficient space, so copy slice forward, add header and reverse. - bytes32 m0; - bytes32 m1; - bytes32 m2; - uint256 endOffset = offset + length; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(add(endOffset, 0x00)) - m1 := mload(add(endOffset, 0x20)) - m2 := mload(add(endOffset, 0x40)) - } - _memcopy(offset, offset + 0x60, length); - /// @solidity memory-safe-assembly - assembly { - // Selector of `log(bytes)`. - mstore(add(offset, 0x00), 0x0be77f56) - mstore(add(offset, 0x20), 0x20) - mstore(add(offset, 0x40), length) - } - _sendLogPayload(offset + 0x1c, length + 0x44); - _memcopy(offset + 0x60, offset, length); - /// @solidity memory-safe-assembly - assembly { - mstore(add(endOffset, 0x00), m0) - mstore(add(endOffset, 0x20), m1) - mstore(add(endOffset, 0x40), m2) - } - } - } - - function log(address p0) internal pure { - bytes32 m0; - bytes32 m1; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - // Selector of `log(address)`. - mstore(0x00, 0x2c2ecbc2) - mstore(0x20, p0) - } - _sendLogPayload(0x1c, 0x24); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - } - } - - function log(bool p0) internal pure { - bytes32 m0; - bytes32 m1; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - // Selector of `log(bool)`. - mstore(0x00, 0x32458eed) - mstore(0x20, p0) - } - _sendLogPayload(0x1c, 0x24); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - } - } - - function log(uint256 p0) internal pure { - bytes32 m0; - bytes32 m1; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - // Selector of `log(uint256)`. - mstore(0x00, 0xf82c50f1) - mstore(0x20, p0) - } - _sendLogPayload(0x1c, 0x24); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - } - } - - function log(bytes32 p0) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(string)`. - mstore(0x00, 0x41304fac) - mstore(0x20, 0x20) - writeString(0x40, p0) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, address p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(address,address)`. - mstore(0x00, 0xdaf0d4aa) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(address p0, bool p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(address,bool)`. - mstore(0x00, 0x75b605d3) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(address p0, uint256 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(address,uint256)`. - mstore(0x00, 0x8309e8a8) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(address p0, bytes32 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,string)`. - mstore(0x00, 0x759f86bb) - mstore(0x20, p0) - mstore(0x40, 0x40) - writeString(0x60, p1) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(bool,address)`. - mstore(0x00, 0x853c4849) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(bool p0, bool p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(bool,bool)`. - mstore(0x00, 0x2a110e83) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(bool p0, uint256 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(bool,uint256)`. - mstore(0x00, 0x399174d3) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(bool p0, bytes32 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,string)`. - mstore(0x00, 0x8feac525) - mstore(0x20, p0) - mstore(0x40, 0x40) - writeString(0x60, p1) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(uint256,address)`. - mstore(0x00, 0x69276c86) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(uint256 p0, bool p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(uint256,bool)`. - mstore(0x00, 0x1c9d7eb3) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(uint256 p0, uint256 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - // Selector of `log(uint256,uint256)`. - mstore(0x00, 0xf666715a) - mstore(0x20, p0) - mstore(0x40, p1) - } - _sendLogPayload(0x1c, 0x44); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - } - } - - function log(uint256 p0, bytes32 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,string)`. - mstore(0x00, 0x643fd0df) - mstore(0x20, p0) - mstore(0x40, 0x40) - writeString(0x60, p1) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bytes32 p0, address p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(string,address)`. - mstore(0x00, 0x319af333) - mstore(0x20, 0x40) - mstore(0x40, p1) - writeString(0x60, p0) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bytes32 p0, bool p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(string,bool)`. - mstore(0x00, 0xc3b55635) - mstore(0x20, 0x40) - mstore(0x40, p1) - writeString(0x60, p0) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bytes32 p0, uint256 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(string,uint256)`. - mstore(0x00, 0xb60e72cc) - mstore(0x20, 0x40) - mstore(0x40, p1) - writeString(0x60, p0) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bytes32 p0, bytes32 p1) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,string)`. - mstore(0x00, 0x4b5c4277) - mstore(0x20, 0x40) - mstore(0x40, 0x80) - writeString(0x60, p0) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,address,address)`. - mstore(0x00, 0x018c84c2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, address p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,address,bool)`. - mstore(0x00, 0xf2a66286) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, address p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,address,uint256)`. - mstore(0x00, 0x17fe6185) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, address p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,address,string)`. - mstore(0x00, 0x007150be) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bool p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,bool,address)`. - mstore(0x00, 0xf11699ed) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, bool p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,bool,bool)`. - mstore(0x00, 0xeb830c92) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, bool p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,bool,uint256)`. - mstore(0x00, 0x9c4f99fb) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, bool p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,bool,string)`. - mstore(0x00, 0x212255cc) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, uint256 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,uint256,address)`. - mstore(0x00, 0x7bc0d848) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, uint256 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,uint256,bool)`. - mstore(0x00, 0x678209a8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, uint256 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(address,uint256,uint256)`. - mstore(0x00, 0xb69bcaf6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(address p0, uint256 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,uint256,string)`. - mstore(0x00, 0xa1f2e8aa) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bytes32 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,string,address)`. - mstore(0x00, 0xf08744e8) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bytes32 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,string,bool)`. - mstore(0x00, 0xcf020fb1) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bytes32 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(address,string,uint256)`. - mstore(0x00, 0x67dd6ff1) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(address p0, bytes32 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(address,string,string)`. - mstore(0x00, 0xfb772265) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, 0xa0) - writeString(0x80, p1) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bool p0, address p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,address,address)`. - mstore(0x00, 0xd2763667) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, address p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,address,bool)`. - mstore(0x00, 0x18c9c746) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, address p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,address,uint256)`. - mstore(0x00, 0x5f7b9afb) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, address p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,address,string)`. - mstore(0x00, 0xde9a9270) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bool p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,bool,address)`. - mstore(0x00, 0x1078f68d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, bool p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,bool,bool)`. - mstore(0x00, 0x50709698) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, bool p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,bool,uint256)`. - mstore(0x00, 0x12f21602) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, bool p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,bool,string)`. - mstore(0x00, 0x2555fa46) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, uint256 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,uint256,address)`. - mstore(0x00, 0x088ef9d2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, uint256 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,uint256,bool)`. - mstore(0x00, 0xe8defba9) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, uint256 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(bool,uint256,uint256)`. - mstore(0x00, 0x37103367) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(bool p0, uint256 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,uint256,string)`. - mstore(0x00, 0xc3fc3970) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bytes32 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,string,address)`. - mstore(0x00, 0x9591b953) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bytes32 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,string,bool)`. - mstore(0x00, 0xdbb4c247) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bytes32 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(bool,string,uint256)`. - mstore(0x00, 0x1093ee11) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(bool,string,string)`. - mstore(0x00, 0xb076847f) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, 0xa0) - writeString(0x80, p1) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(uint256 p0, address p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,address,address)`. - mstore(0x00, 0xbcfd9be0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, address p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,address,bool)`. - mstore(0x00, 0x9b6ec042) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, address p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,address,uint256)`. - mstore(0x00, 0x5a9b5ed5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, address p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,address,string)`. - mstore(0x00, 0x63cb41f9) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bool p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,bool,address)`. - mstore(0x00, 0x35085f7b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, bool p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,bool,bool)`. - mstore(0x00, 0x20718650) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, bool p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,bool,uint256)`. - mstore(0x00, 0x20098014) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, bool p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,bool,string)`. - mstore(0x00, 0x85775021) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, uint256 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,uint256,address)`. - mstore(0x00, 0x5c96b331) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, uint256 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,uint256,bool)`. - mstore(0x00, 0x4766da72) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - // Selector of `log(uint256,uint256,uint256)`. - mstore(0x00, 0xd1ed7a3c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - } - _sendLogPayload(0x1c, 0x64); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,uint256,string)`. - mstore(0x00, 0x71d04af2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x60) - writeString(0x80, p2) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bytes32 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,string,address)`. - mstore(0x00, 0x7afac959) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bytes32 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,string,bool)`. - mstore(0x00, 0x4ceda75a) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(uint256,string,uint256)`. - mstore(0x00, 0x37aa7d4c) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, p2) - writeString(0x80, p1) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(uint256,string,string)`. - mstore(0x00, 0xb115611f) - mstore(0x20, p0) - mstore(0x40, 0x60) - mstore(0x60, 0xa0) - writeString(0x80, p1) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, address p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,address,address)`. - mstore(0x00, 0xfcec75e0) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, address p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,address,bool)`. - mstore(0x00, 0xc91d5ed4) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, address p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,address,uint256)`. - mstore(0x00, 0x0d26b925) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, address p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,address,string)`. - mstore(0x00, 0xe0e9ad4f) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, 0xa0) - writeString(0x80, p0) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bool p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,bool,address)`. - mstore(0x00, 0x932bbb38) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, bool p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,bool,bool)`. - mstore(0x00, 0x850b7ad6) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, bool p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,bool,uint256)`. - mstore(0x00, 0xc95958d6) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,bool,string)`. - mstore(0x00, 0xe298f47d) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, 0xa0) - writeString(0x80, p0) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, uint256 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,uint256,address)`. - mstore(0x00, 0x1c7ec448) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, uint256 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,uint256,bool)`. - mstore(0x00, 0xca7733b1) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - // Selector of `log(string,uint256,uint256)`. - mstore(0x00, 0xca47c4eb) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, p2) - writeString(0x80, p0) - } - _sendLogPayload(0x1c, 0xa4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,uint256,string)`. - mstore(0x00, 0x5970e089) - mstore(0x20, 0x60) - mstore(0x40, p1) - mstore(0x60, 0xa0) - writeString(0x80, p0) - writeString(0xc0, p2) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bytes32 p1, address p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,string,address)`. - mstore(0x00, 0x95ed0195) - mstore(0x20, 0x60) - mstore(0x40, 0xa0) - mstore(0x60, p2) - writeString(0x80, p0) - writeString(0xc0, p1) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,string,bool)`. - mstore(0x00, 0xb0e0f9b5) - mstore(0x20, 0x60) - mstore(0x40, 0xa0) - mstore(0x60, p2) - writeString(0x80, p0) - writeString(0xc0, p1) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - // Selector of `log(string,string,uint256)`. - mstore(0x00, 0x5821efa1) - mstore(0x20, 0x60) - mstore(0x40, 0xa0) - mstore(0x60, p2) - writeString(0x80, p0) - writeString(0xc0, p1) - } - _sendLogPayload(0x1c, 0xe4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - // Selector of `log(string,string,string)`. - mstore(0x00, 0x2ced7cef) - mstore(0x20, 0x60) - mstore(0x40, 0xa0) - mstore(0x60, 0xe0) - writeString(0x80, p0) - writeString(0xc0, p1) - writeString(0x100, p2) - } - _sendLogPayload(0x1c, 0x124); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - } - } - - function log(address p0, address p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,address,address)`. - mstore(0x00, 0x665bf134) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,address,bool)`. - mstore(0x00, 0x0e378994) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,address,uint256)`. - mstore(0x00, 0x94250d77) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,address,string)`. - mstore(0x00, 0xf808da20) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,bool,address)`. - mstore(0x00, 0x9f1bc36e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,bool,bool)`. - mstore(0x00, 0x2cd4134a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,bool,uint256)`. - mstore(0x00, 0x3971e78c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,bool,string)`. - mstore(0x00, 0xaa6540c8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,uint256,address)`. - mstore(0x00, 0x8da6def5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,uint256,bool)`. - mstore(0x00, 0x9b4254e2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,address,uint256,uint256)`. - mstore(0x00, 0xbe553481) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, address p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,uint256,string)`. - mstore(0x00, 0xfdb4f990) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,string,address)`. - mstore(0x00, 0x8f736d16) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,string,bool)`. - mstore(0x00, 0x6f1a594e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,address,string,uint256)`. - mstore(0x00, 0xef1cefe7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, address p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,address,string,string)`. - mstore(0x00, 0x21bdaf25) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bool p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,address,address)`. - mstore(0x00, 0x660375dd) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,address,bool)`. - mstore(0x00, 0xa6f50b0f) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,address,uint256)`. - mstore(0x00, 0xa75c59de) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,address,string)`. - mstore(0x00, 0x2dd778e6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,bool,address)`. - mstore(0x00, 0xcf394485) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,bool,bool)`. - mstore(0x00, 0xcac43479) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,bool,uint256)`. - mstore(0x00, 0x8c4e5de6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,bool,string)`. - mstore(0x00, 0xdfc4a2e8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,uint256,address)`. - mstore(0x00, 0xccf790a1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,uint256,bool)`. - mstore(0x00, 0xc4643e20) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,bool,uint256,uint256)`. - mstore(0x00, 0x386ff5f4) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, bool p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,uint256,string)`. - mstore(0x00, 0x0aa6cfad) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,string,address)`. - mstore(0x00, 0x19fd4956) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,string,bool)`. - mstore(0x00, 0x50ad461d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,bool,string,uint256)`. - mstore(0x00, 0x80e6a20b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bool p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,bool,string,string)`. - mstore(0x00, 0x475c5c33) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, uint256 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,address,address)`. - mstore(0x00, 0x478d1c62) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,address,bool)`. - mstore(0x00, 0xa1bcc9b3) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,address,uint256)`. - mstore(0x00, 0x100f650e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,address,string)`. - mstore(0x00, 0x1da986ea) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,bool,address)`. - mstore(0x00, 0xa31bfdcc) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,bool,bool)`. - mstore(0x00, 0x3bf5e537) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,bool,uint256)`. - mstore(0x00, 0x22f6b999) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,bool,string)`. - mstore(0x00, 0xc5ad85f9) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,uint256,address)`. - mstore(0x00, 0x20e3984d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,uint256,bool)`. - mstore(0x00, 0x66f1bc67) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(address,uint256,uint256,uint256)`. - mstore(0x00, 0x34f0e636) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(address p0, uint256 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,uint256,string)`. - mstore(0x00, 0x4a28c017) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,string,address)`. - mstore(0x00, 0x5c430d47) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,string,bool)`. - mstore(0x00, 0xcf18105c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,uint256,string,uint256)`. - mstore(0x00, 0xbf01f891) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, uint256 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,uint256,string,string)`. - mstore(0x00, 0x88a8c406) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,address,address)`. - mstore(0x00, 0x0d36fa20) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,address,bool)`. - mstore(0x00, 0x0df12b76) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,address,uint256)`. - mstore(0x00, 0x457fe3cf) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,address,string)`. - mstore(0x00, 0xf7e36245) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,bool,address)`. - mstore(0x00, 0x205871c2) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,bool,bool)`. - mstore(0x00, 0x5f1d5c9f) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,bool,uint256)`. - mstore(0x00, 0x515e38b6) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,bool,string)`. - mstore(0x00, 0xbc0b61fe) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,uint256,address)`. - mstore(0x00, 0x63183678) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,uint256,bool)`. - mstore(0x00, 0x0ef7e050) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(address,string,uint256,uint256)`. - mstore(0x00, 0x1dc8e1b8) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(address p0, bytes32 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,uint256,string)`. - mstore(0x00, 0x448830a8) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,string,address)`. - mstore(0x00, 0xa04e2f87) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,string,bool)`. - mstore(0x00, 0x35a5071f) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(address,string,string,uint256)`. - mstore(0x00, 0x159f8927) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(address p0, bytes32 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(address,string,string,string)`. - mstore(0x00, 0x5d02c50b) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p1) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bool p0, address p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,address,address)`. - mstore(0x00, 0x1d14d001) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,address,bool)`. - mstore(0x00, 0x46600be0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,address,uint256)`. - mstore(0x00, 0x0c66d1be) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,address,string)`. - mstore(0x00, 0xd812a167) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,bool,address)`. - mstore(0x00, 0x1c41a336) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,bool,bool)`. - mstore(0x00, 0x6a9c478b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,bool,uint256)`. - mstore(0x00, 0x07831502) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,bool,string)`. - mstore(0x00, 0x4a66cb34) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,uint256,address)`. - mstore(0x00, 0x136b05dd) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,uint256,bool)`. - mstore(0x00, 0xd6019f1c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,address,uint256,uint256)`. - mstore(0x00, 0x7bf181a1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, address p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,uint256,string)`. - mstore(0x00, 0x51f09ff8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,string,address)`. - mstore(0x00, 0x6f7c603e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,string,bool)`. - mstore(0x00, 0xe2bfd60b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,address,string,uint256)`. - mstore(0x00, 0xc21f64c7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, address p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,address,string,string)`. - mstore(0x00, 0xa73c1db6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bool p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,address,address)`. - mstore(0x00, 0xf4880ea4) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,address,bool)`. - mstore(0x00, 0xc0a302d8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,address,uint256)`. - mstore(0x00, 0x4c123d57) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,address,string)`. - mstore(0x00, 0xa0a47963) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,bool,address)`. - mstore(0x00, 0x8c329b1a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,bool,bool)`. - mstore(0x00, 0x3b2a5ce0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,bool,uint256)`. - mstore(0x00, 0x6d7045c1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,bool,string)`. - mstore(0x00, 0x2ae408d4) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,uint256,address)`. - mstore(0x00, 0x54a7a9a0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,uint256,bool)`. - mstore(0x00, 0x619e4d0e) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,bool,uint256,uint256)`. - mstore(0x00, 0x0bb00eab) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, bool p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,uint256,string)`. - mstore(0x00, 0x7dd4d0e0) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,string,address)`. - mstore(0x00, 0xf9ad2b89) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,string,bool)`. - mstore(0x00, 0xb857163a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,bool,string,uint256)`. - mstore(0x00, 0xe3a9ca2f) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bool p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,bool,string,string)`. - mstore(0x00, 0x6d1e8751) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, uint256 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,address,address)`. - mstore(0x00, 0x26f560a8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,address,bool)`. - mstore(0x00, 0xb4c314ff) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,address,uint256)`. - mstore(0x00, 0x1537dc87) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,address,string)`. - mstore(0x00, 0x1bb3b09a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,bool,address)`. - mstore(0x00, 0x9acd3616) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,bool,bool)`. - mstore(0x00, 0xceb5f4d7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,bool,uint256)`. - mstore(0x00, 0x7f9bbca2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,bool,string)`. - mstore(0x00, 0x9143dbb1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,uint256,address)`. - mstore(0x00, 0x00dd87b9) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,uint256,bool)`. - mstore(0x00, 0xbe984353) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(bool,uint256,uint256,uint256)`. - mstore(0x00, 0x374bb4b2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(bool p0, uint256 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,uint256,string)`. - mstore(0x00, 0x8e69fb5d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,string,address)`. - mstore(0x00, 0xfedd1fff) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,string,bool)`. - mstore(0x00, 0xe5e70b2b) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,uint256,string,uint256)`. - mstore(0x00, 0x6a1199e2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, uint256 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,uint256,string,string)`. - mstore(0x00, 0xf5bc2249) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,address,address)`. - mstore(0x00, 0x2b2b18dc) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,address,bool)`. - mstore(0x00, 0x6dd434ca) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,address,uint256)`. - mstore(0x00, 0xa5cada94) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,address,string)`. - mstore(0x00, 0x12d6c788) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,bool,address)`. - mstore(0x00, 0x538e06ab) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,bool,bool)`. - mstore(0x00, 0xdc5e935b) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,bool,uint256)`. - mstore(0x00, 0x1606a393) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,bool,string)`. - mstore(0x00, 0x483d0416) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,uint256,address)`. - mstore(0x00, 0x1596a1ce) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,uint256,bool)`. - mstore(0x00, 0x6b0e5d53) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(bool,string,uint256,uint256)`. - mstore(0x00, 0x28863fcb) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bool p0, bytes32 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,uint256,string)`. - mstore(0x00, 0x1ad96de6) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,string,address)`. - mstore(0x00, 0x97d394d8) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,string,bool)`. - mstore(0x00, 0x1e4b87e5) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(bool,string,string,uint256)`. - mstore(0x00, 0x7be0c3eb) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bool p0, bytes32 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(bool,string,string,string)`. - mstore(0x00, 0x1762e32a) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p1) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(uint256 p0, address p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,address,address)`. - mstore(0x00, 0x2488b414) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,address,bool)`. - mstore(0x00, 0x091ffaf5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,address,uint256)`. - mstore(0x00, 0x736efbb6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,address,string)`. - mstore(0x00, 0x031c6f73) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,bool,address)`. - mstore(0x00, 0xef72c513) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,bool,bool)`. - mstore(0x00, 0xe351140f) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,bool,uint256)`. - mstore(0x00, 0x5abd992a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,bool,string)`. - mstore(0x00, 0x90fb06aa) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,uint256,address)`. - mstore(0x00, 0x15c127b5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,uint256,bool)`. - mstore(0x00, 0x5f743a7c) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,address,uint256,uint256)`. - mstore(0x00, 0x0c9cd9c1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, address p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,uint256,string)`. - mstore(0x00, 0xddb06521) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,string,address)`. - mstore(0x00, 0x9cba8fff) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,string,bool)`. - mstore(0x00, 0xcc32ab07) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,address,string,uint256)`. - mstore(0x00, 0x46826b5d) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, address p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,address,string,string)`. - mstore(0x00, 0x3e128ca3) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bool p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,address,address)`. - mstore(0x00, 0xa1ef4cbb) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,address,bool)`. - mstore(0x00, 0x454d54a5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,address,uint256)`. - mstore(0x00, 0x078287f5) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,address,string)`. - mstore(0x00, 0xade052c7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,bool,address)`. - mstore(0x00, 0x69640b59) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,bool,bool)`. - mstore(0x00, 0xb6f577a1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,bool,uint256)`. - mstore(0x00, 0x7464ce23) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,bool,string)`. - mstore(0x00, 0xdddb9561) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,uint256,address)`. - mstore(0x00, 0x88cb6041) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,uint256,bool)`. - mstore(0x00, 0x91a02e2a) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,bool,uint256,uint256)`. - mstore(0x00, 0xc6acc7a8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, bool p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,uint256,string)`. - mstore(0x00, 0xde03e774) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,string,address)`. - mstore(0x00, 0xef529018) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,string,bool)`. - mstore(0x00, 0xeb928d7f) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,bool,string,uint256)`. - mstore(0x00, 0x2c1d0746) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bool p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,bool,string,string)`. - mstore(0x00, 0x68c8b8bd) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, uint256 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,address,address)`. - mstore(0x00, 0x56a5d1b1) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,address,bool)`. - mstore(0x00, 0x15cac476) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,address,uint256)`. - mstore(0x00, 0x88f6e4b2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,address,string)`. - mstore(0x00, 0x6cde40b8) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,bool,address)`. - mstore(0x00, 0x9a816a83) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,bool,bool)`. - mstore(0x00, 0xab085ae6) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,bool,uint256)`. - mstore(0x00, 0xeb7f6fd2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,bool,string)`. - mstore(0x00, 0xa5b4fc99) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,uint256,address)`. - mstore(0x00, 0xfa8185af) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,uint256,bool)`. - mstore(0x00, 0xc598d185) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - /// @solidity memory-safe-assembly - assembly { - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - // Selector of `log(uint256,uint256,uint256,uint256)`. - mstore(0x00, 0x193fb800) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - } - _sendLogPayload(0x1c, 0x84); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - } - } - - function log(uint256 p0, uint256 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,uint256,string)`. - mstore(0x00, 0x59cfcbe3) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0x80) - writeString(0xa0, p3) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,string,address)`. - mstore(0x00, 0x42d21db7) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,string,bool)`. - mstore(0x00, 0x7af6ab25) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,uint256,string,uint256)`. - mstore(0x00, 0x5da297eb) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, p3) - writeString(0xa0, p2) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, uint256 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,uint256,string,string)`. - mstore(0x00, 0x27d8afd2) - mstore(0x20, p0) - mstore(0x40, p1) - mstore(0x60, 0x80) - mstore(0x80, 0xc0) - writeString(0xa0, p2) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,address,address)`. - mstore(0x00, 0x6168ed61) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,address,bool)`. - mstore(0x00, 0x90c30a56) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,address,uint256)`. - mstore(0x00, 0xe8d3018d) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,address,string)`. - mstore(0x00, 0x9c3adfa1) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,bool,address)`. - mstore(0x00, 0xae2ec581) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,bool,bool)`. - mstore(0x00, 0xba535d9c) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,bool,uint256)`. - mstore(0x00, 0xcf009880) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,bool,string)`. - mstore(0x00, 0xd2d423cd) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,uint256,address)`. - mstore(0x00, 0x3b2279b4) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,uint256,bool)`. - mstore(0x00, 0x691a8f74) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(uint256,string,uint256,uint256)`. - mstore(0x00, 0x82c25b74) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p1) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(uint256 p0, bytes32 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,uint256,string)`. - mstore(0x00, 0xb7b914ca) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p1) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,string,address)`. - mstore(0x00, 0xd583c602) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,string,bool)`. - mstore(0x00, 0xb3a6b6bd) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(uint256,string,string,uint256)`. - mstore(0x00, 0xb028c9bd) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p1) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(uint256 p0, bytes32 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(uint256,string,string,string)`. - mstore(0x00, 0x21ad0683) - mstore(0x20, p0) - mstore(0x40, 0x80) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p1) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, address p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,address,address)`. - mstore(0x00, 0xed8f28f6) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,address,bool)`. - mstore(0x00, 0xb59dbd60) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,address,uint256)`. - mstore(0x00, 0x8ef3f399) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,address,string)`. - mstore(0x00, 0x800a1c67) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,bool,address)`. - mstore(0x00, 0x223603bd) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,bool,bool)`. - mstore(0x00, 0x79884c2b) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,bool,uint256)`. - mstore(0x00, 0x3e9f866a) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,bool,string)`. - mstore(0x00, 0x0454c079) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,uint256,address)`. - mstore(0x00, 0x63fb8bc5) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,uint256,bool)`. - mstore(0x00, 0xfc4845f0) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,address,uint256,uint256)`. - mstore(0x00, 0xf8f51b1e) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, address p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,uint256,string)`. - mstore(0x00, 0x5a477632) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,string,address)`. - mstore(0x00, 0xaabc9a31) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,string,bool)`. - mstore(0x00, 0x5f15d28c) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,address,string,uint256)`. - mstore(0x00, 0x91d1112e) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, address p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,address,string,string)`. - mstore(0x00, 0x245986f2) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bool p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,address,address)`. - mstore(0x00, 0x33e9dd1d) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,address,bool)`. - mstore(0x00, 0x958c28c6) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,address,uint256)`. - mstore(0x00, 0x5d08bb05) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,address,string)`. - mstore(0x00, 0x2d8e33a4) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,bool,address)`. - mstore(0x00, 0x7190a529) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,bool,bool)`. - mstore(0x00, 0x895af8c5) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,bool,uint256)`. - mstore(0x00, 0x8e3f78a9) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,bool,string)`. - mstore(0x00, 0x9d22d5dd) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,uint256,address)`. - mstore(0x00, 0x935e09bf) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,uint256,bool)`. - mstore(0x00, 0x8af7cf8a) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,bool,uint256,uint256)`. - mstore(0x00, 0x64b5bb67) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, bool p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,uint256,string)`. - mstore(0x00, 0x742d6ee7) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,string,address)`. - mstore(0x00, 0xe0625b29) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,string,bool)`. - mstore(0x00, 0x3f8a701d) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,bool,string,uint256)`. - mstore(0x00, 0x24f91465) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bool p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,bool,string,string)`. - mstore(0x00, 0xa826caeb) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, uint256 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,address,address)`. - mstore(0x00, 0x5ea2b7ae) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,address,bool)`. - mstore(0x00, 0x82112a42) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,address,uint256)`. - mstore(0x00, 0x4f04fdc6) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,address,string)`. - mstore(0x00, 0x9ffb2f93) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,bool,address)`. - mstore(0x00, 0xe0e95b98) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,bool,bool)`. - mstore(0x00, 0x354c36d6) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,bool,uint256)`. - mstore(0x00, 0xe41b6f6f) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,bool,string)`. - mstore(0x00, 0xabf73a98) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,uint256,address)`. - mstore(0x00, 0xe21de278) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,uint256,bool)`. - mstore(0x00, 0x7626db92) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - // Selector of `log(string,uint256,uint256,uint256)`. - mstore(0x00, 0xa7a87853) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - } - _sendLogPayload(0x1c, 0xc4); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - } - } - - function log(bytes32 p0, uint256 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,uint256,string)`. - mstore(0x00, 0x854b3496) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, p2) - mstore(0x80, 0xc0) - writeString(0xa0, p0) - writeString(0xe0, p3) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,string,address)`. - mstore(0x00, 0x7c4632a4) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,string,bool)`. - mstore(0x00, 0x7d24491d) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,uint256,string,uint256)`. - mstore(0x00, 0xc67ea9d1) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p2) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, uint256 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,uint256,string,string)`. - mstore(0x00, 0x5ab84e1f) - mstore(0x20, 0x80) - mstore(0x40, p1) - mstore(0x60, 0xc0) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p2) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, address p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,address,address)`. - mstore(0x00, 0x439c7bef) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, address p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,address,bool)`. - mstore(0x00, 0x5ccd4e37) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, address p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,address,uint256)`. - mstore(0x00, 0x7cc3c607) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, address p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,address,string)`. - mstore(0x00, 0xeb1bff80) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,bool,address)`. - mstore(0x00, 0xc371c7db) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,bool,bool)`. - mstore(0x00, 0x40785869) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,bool,uint256)`. - mstore(0x00, 0xd6aefad2) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, bool p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,bool,string)`. - mstore(0x00, 0x5e84b0ea) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,uint256,address)`. - mstore(0x00, 0x1023f7b2) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,uint256,bool)`. - mstore(0x00, 0xc3a8a654) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - // Selector of `log(string,string,uint256,uint256)`. - mstore(0x00, 0xf45d7d2c) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - } - _sendLogPayload(0x1c, 0x104); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - } - } - - function log(bytes32 p0, bytes32 p1, uint256 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,uint256,string)`. - mstore(0x00, 0x5d1a971a) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, p2) - mstore(0x80, 0x100) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p3) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2, address p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,string,address)`. - mstore(0x00, 0x6d572f44) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, 0x100) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p2) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2, bool p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,string,bool)`. - mstore(0x00, 0x2c1754ed) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, 0x100) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p2) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2, uint256 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - // Selector of `log(string,string,string,uint256)`. - mstore(0x00, 0x8eafb02b) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, 0x100) - mstore(0x80, p3) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p2) - } - _sendLogPayload(0x1c, 0x144); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - } - } - - function log(bytes32 p0, bytes32 p1, bytes32 p2, bytes32 p3) internal pure { - bytes32 m0; - bytes32 m1; - bytes32 m2; - bytes32 m3; - bytes32 m4; - bytes32 m5; - bytes32 m6; - bytes32 m7; - bytes32 m8; - bytes32 m9; - bytes32 m10; - bytes32 m11; - bytes32 m12; - /// @solidity memory-safe-assembly - assembly { - function writeString(pos, w) { - let length := 0 - for {} lt(length, 0x20) { length := add(length, 1) } { if iszero(byte(length, w)) { break } } - mstore(pos, length) - let shift := sub(256, shl(3, length)) - mstore(add(pos, 0x20), shl(shift, shr(shift, w))) - } - m0 := mload(0x00) - m1 := mload(0x20) - m2 := mload(0x40) - m3 := mload(0x60) - m4 := mload(0x80) - m5 := mload(0xa0) - m6 := mload(0xc0) - m7 := mload(0xe0) - m8 := mload(0x100) - m9 := mload(0x120) - m10 := mload(0x140) - m11 := mload(0x160) - m12 := mload(0x180) - // Selector of `log(string,string,string,string)`. - mstore(0x00, 0xde68f20a) - mstore(0x20, 0x80) - mstore(0x40, 0xc0) - mstore(0x60, 0x100) - mstore(0x80, 0x140) - writeString(0xa0, p0) - writeString(0xe0, p1) - writeString(0x120, p2) - writeString(0x160, p3) - } - _sendLogPayload(0x1c, 0x184); - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, m0) - mstore(0x20, m1) - mstore(0x40, m2) - mstore(0x60, m3) - mstore(0x80, m4) - mstore(0xa0, m5) - mstore(0xc0, m6) - mstore(0xe0, m7) - mstore(0x100, m8) - mstore(0x120, m9) - mstore(0x140, m10) - mstore(0x160, m11) - mstore(0x180, m12) - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdAssertions.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdAssertions.t.sol deleted file mode 100644 index 9385a607a6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdAssertions.t.sol +++ /dev/null @@ -1,145 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {StdAssertions} from "../src/StdAssertions.sol"; -import {Vm} from "../src/Vm.sol"; - -interface VmInternal is Vm { - function _expectCheatcodeRevert(bytes memory message) external; -} - -contract StdAssertionsTest is StdAssertions { - string constant errorMessage = "User provided message"; - uint256 constant maxDecimals = 77; - - bool constant SHOULD_REVERT = true; - bool constant SHOULD_RETURN = false; - - bool constant STRICT_REVERT_DATA = true; - bool constant NON_STRICT_REVERT_DATA = false; - - VmInternal constant vm = VmInternal(address(uint160(uint256(keccak256("hevm cheat code"))))); - - function testFuzz_AssertEqCall_Return_Pass( - bytes memory callDataA, - bytes memory callDataB, - bytes memory returnData, - bool strictRevertData - ) external { - address targetA = address(new TestMockCall(returnData, SHOULD_RETURN)); - address targetB = address(new TestMockCall(returnData, SHOULD_RETURN)); - - assertEqCall(targetA, callDataA, targetB, callDataB, strictRevertData); - } - - function testFuzz_RevertWhenCalled_AssertEqCall_Return_Fail( - bytes memory callDataA, - bytes memory callDataB, - bytes memory returnDataA, - bytes memory returnDataB, - bool strictRevertData - ) external { - vm.assume(keccak256(returnDataA) != keccak256(returnDataB)); - - address targetA = address(new TestMockCall(returnDataA, SHOULD_RETURN)); - address targetB = address(new TestMockCall(returnDataB, SHOULD_RETURN)); - - vm._expectCheatcodeRevert( - bytes( - string.concat( - "Call return data does not match: ", vm.toString(returnDataA), " != ", vm.toString(returnDataB) - ) - ) - ); - assertEqCall(targetA, callDataA, targetB, callDataB, strictRevertData); - } - - function testFuzz_AssertEqCall_Revert_Pass( - bytes memory callDataA, - bytes memory callDataB, - bytes memory revertDataA, - bytes memory revertDataB - ) external { - address targetA = address(new TestMockCall(revertDataA, SHOULD_REVERT)); - address targetB = address(new TestMockCall(revertDataB, SHOULD_REVERT)); - - assertEqCall(targetA, callDataA, targetB, callDataB, NON_STRICT_REVERT_DATA); - } - - function testFuzz_RevertWhenCalled_AssertEqCall_Revert_Fail( - bytes memory callDataA, - bytes memory callDataB, - bytes memory revertDataA, - bytes memory revertDataB - ) external { - vm.assume(keccak256(revertDataA) != keccak256(revertDataB)); - - address targetA = address(new TestMockCall(revertDataA, SHOULD_REVERT)); - address targetB = address(new TestMockCall(revertDataB, SHOULD_REVERT)); - - vm._expectCheatcodeRevert( - bytes( - string.concat( - "Call revert data does not match: ", vm.toString(revertDataA), " != ", vm.toString(revertDataB) - ) - ) - ); - assertEqCall(targetA, callDataA, targetB, callDataB, STRICT_REVERT_DATA); - } - - function testFuzz_RevertWhenCalled_AssertEqCall_Fail( - bytes memory callDataA, - bytes memory callDataB, - bytes memory returnDataA, - bytes memory returnDataB, - bool strictRevertData - ) external { - address targetA = address(new TestMockCall(returnDataA, SHOULD_RETURN)); - address targetB = address(new TestMockCall(returnDataB, SHOULD_REVERT)); - - vm.expectRevert(bytes("assertion failed")); - this.assertEqCallExternal(targetA, callDataA, targetB, callDataB, strictRevertData); - - vm.expectRevert(bytes("assertion failed")); - this.assertEqCallExternal(targetB, callDataB, targetA, callDataA, strictRevertData); - } - - // Helper function to test outcome of assertEqCall via `expect` cheatcodes - function assertEqCallExternal( - address targetA, - bytes memory callDataA, - address targetB, - bytes memory callDataB, - bool strictRevertData - ) public { - assertEqCall(targetA, callDataA, targetB, callDataB, strictRevertData); - } - - function testFailFail() public { - fail(); - } -} - -contract TestMockCall { - bytes returnData; - bool shouldRevert; - - constructor(bytes memory returnData_, bool shouldRevert_) { - returnData = returnData_; - shouldRevert = shouldRevert_; - } - - fallback() external payable { - bytes memory returnData_ = returnData; - - if (shouldRevert) { - assembly { - revert(add(returnData_, 0x20), mload(returnData_)) - } - } else { - assembly { - return(add(returnData_, 0x20), mload(returnData_)) - } - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdChains.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdChains.t.sol deleted file mode 100644 index 48130da5c2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdChains.t.sol +++ /dev/null @@ -1,228 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {Test} from "../src/Test.sol"; - -contract StdChainsMock is Test { - function exposed_getChain(string memory chainAlias) public returns (Chain memory) { - return getChain(chainAlias); - } - - function exposed_getChain(uint256 chainId) public returns (Chain memory) { - return getChain(chainId); - } - - function exposed_setChain(string memory chainAlias, ChainData memory chainData) public { - setChain(chainAlias, chainData); - } - - function exposed_setFallbackToDefaultRpcUrls(bool useDefault) public { - setFallbackToDefaultRpcUrls(useDefault); - } -} - -contract StdChainsTest is Test { - function test_ChainRpcInitialization() public { - // RPCs specified in `foundry.toml` should be updated. - assertEq(getChain(1).rpcUrl, "https://eth-mainnet.alchemyapi.io/v2/WV407BEiBmjNJfKo9Uo_55u0z0ITyCOX"); - assertEq(getChain("optimism_sepolia").rpcUrl, "https://sepolia.optimism.io/"); - assertEq(getChain("arbitrum_one_sepolia").rpcUrl, "https://sepolia-rollup.arbitrum.io/rpc/"); - - // Environment variables should be the next fallback - assertEq(getChain("arbitrum_nova").rpcUrl, "https://nova.arbitrum.io/rpc"); - vm.setEnv("ARBITRUM_NOVA_RPC_URL", "myoverride"); - assertEq(getChain("arbitrum_nova").rpcUrl, "myoverride"); - vm.setEnv("ARBITRUM_NOVA_RPC_URL", "https://nova.arbitrum.io/rpc"); - - // Cannot override RPCs defined in `foundry.toml` - vm.setEnv("MAINNET_RPC_URL", "myoverride2"); - assertEq(getChain("mainnet").rpcUrl, "https://eth-mainnet.alchemyapi.io/v2/WV407BEiBmjNJfKo9Uo_55u0z0ITyCOX"); - - // Other RPCs should remain unchanged. - assertEq(getChain(31337).rpcUrl, "http://127.0.0.1:8545"); - assertEq(getChain("sepolia").rpcUrl, "https://sepolia.infura.io/v3/b9794ad1ddf84dfb8c34d6bb5dca2001"); - } - - // Named with a leading underscore to clarify this is not intended to be run as a normal test, - // and is intended to be used in the below `test_Rpcs` test. - function _testRpc(string memory rpcAlias) internal { - string memory rpcUrl = getChain(rpcAlias).rpcUrl; - vm.createSelectFork(rpcUrl); - } - - // Ensure we can connect to the default RPC URL for each chain. - // Currently commented out since this is slow and public RPCs are flaky, often resulting in failing CI. - // function test_Rpcs() public { - // _testRpc("mainnet"); - // _testRpc("sepolia"); - // _testRpc("holesky"); - // _testRpc("optimism"); - // _testRpc("optimism_sepolia"); - // _testRpc("arbitrum_one"); - // _testRpc("arbitrum_one_sepolia"); - // _testRpc("arbitrum_nova"); - // _testRpc("polygon"); - // _testRpc("polygon_amoy"); - // _testRpc("avalanche"); - // _testRpc("avalanche_fuji"); - // _testRpc("bnb_smart_chain"); - // _testRpc("bnb_smart_chain_testnet"); - // _testRpc("gnosis_chain"); - // _testRpc("moonbeam"); - // _testRpc("moonriver"); - // _testRpc("moonbase"); - // _testRpc("base_sepolia"); - // _testRpc("base"); - // _testRpc("blast_sepolia"); - // _testRpc("blast"); - // _testRpc("fantom_opera"); - // _testRpc("fantom_opera_testnet"); - // _testRpc("fraxtal"); - // _testRpc("fraxtal_testnet"); - // _testRpc("berachain_bartio_testnet"); - // _testRpc("flare"); - // _testRpc("flare_coston2"); - // } - - function test_RevertIf_ChainNotFound() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(string): Chain with alias \"does_not_exist\" not found."); - stdChainsMock.exposed_getChain("does_not_exist"); - } - - function test_RevertIf_SetChain_ChainIdExist_FirstTest() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains setChain(string,ChainData): Chain ID 31337 already used by \"anvil\"."); - stdChainsMock.exposed_setChain("anvil2", ChainData("Anvil", 31337, "URL")); - } - - function test_RevertIf_ChainBubbleUp() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - stdChainsMock.exposed_setChain("needs_undefined_env_var", ChainData("", 123456789, "")); - vm.expectRevert( - "Failed to resolve env var `UNDEFINED_RPC_URL_PLACEHOLDER` in `${UNDEFINED_RPC_URL_PLACEHOLDER}`: environment variable not found" - ); - stdChainsMock.exposed_getChain("needs_undefined_env_var"); - } - - function test_RevertIf_SetChain_ChainIdExists_SecondTest() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - stdChainsMock.exposed_setChain("custom_chain", ChainData("Custom Chain", 123456789, "https://custom.chain/")); - - vm.expectRevert('StdChains setChain(string,ChainData): Chain ID 123456789 already used by "custom_chain".'); - - stdChainsMock.exposed_setChain("another_custom_chain", ChainData("", 123456789, "")); - } - - function test_SetChain() public { - setChain("custom_chain", ChainData("Custom Chain", 123456789, "https://custom.chain/")); - Chain memory customChain = getChain("custom_chain"); - assertEq(customChain.name, "Custom Chain"); - assertEq(customChain.chainId, 123456789); - assertEq(customChain.chainAlias, "custom_chain"); - assertEq(customChain.rpcUrl, "https://custom.chain/"); - Chain memory chainById = getChain(123456789); - assertEq(chainById.name, customChain.name); - assertEq(chainById.chainId, customChain.chainId); - assertEq(chainById.chainAlias, customChain.chainAlias); - assertEq(chainById.rpcUrl, customChain.rpcUrl); - customChain.name = "Another Custom Chain"; - customChain.chainId = 987654321; - setChain("another_custom_chain", customChain); - Chain memory anotherCustomChain = getChain("another_custom_chain"); - assertEq(anotherCustomChain.name, "Another Custom Chain"); - assertEq(anotherCustomChain.chainId, 987654321); - assertEq(anotherCustomChain.chainAlias, "another_custom_chain"); - assertEq(anotherCustomChain.rpcUrl, "https://custom.chain/"); - // Verify the first chain data was not overwritten - chainById = getChain(123456789); - assertEq(chainById.name, "Custom Chain"); - assertEq(chainById.chainId, 123456789); - } - - function test_RevertIf_SetEmptyAlias() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains setChain(string,ChainData): Chain alias cannot be the empty string."); - stdChainsMock.exposed_setChain("", ChainData("", 123456789, "")); - } - - function test_RevertIf_SetNoChainId0() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains setChain(string,ChainData): Chain ID cannot be 0."); - stdChainsMock.exposed_setChain("alias", ChainData("", 0, "")); - } - - function test_RevertIf_GetNoChainId0() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(uint256): Chain ID cannot be 0."); - stdChainsMock.exposed_getChain(0); - } - - function test_RevertIf_GetNoEmptyAlias() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(string): Chain alias cannot be the empty string."); - stdChainsMock.exposed_getChain(""); - } - - function test_RevertIf_ChainIdNotFound() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(string): Chain with alias \"no_such_alias\" not found."); - stdChainsMock.exposed_getChain("no_such_alias"); - } - - function test_RevertIf_ChainAliasNotFound() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - vm.expectRevert("StdChains getChain(uint256): Chain with ID 321 not found."); - - stdChainsMock.exposed_getChain(321); - } - - function test_SetChain_ExistingOne() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - setChain("custom_chain", ChainData("Custom Chain", 123456789, "https://custom.chain/")); - assertEq(getChain(123456789).chainId, 123456789); - - setChain("custom_chain", ChainData("Modified Chain", 999999999, "https://modified.chain/")); - vm.expectRevert("StdChains getChain(uint256): Chain with ID 123456789 not found."); - stdChainsMock.exposed_getChain(123456789); - - Chain memory modifiedChain = getChain(999999999); - assertEq(modifiedChain.name, "Modified Chain"); - assertEq(modifiedChain.chainId, 999999999); - assertEq(modifiedChain.rpcUrl, "https://modified.chain/"); - } - - function test_RevertIf_DontUseDefaultRpcUrl() public { - // We deploy a mock to properly test the revert. - StdChainsMock stdChainsMock = new StdChainsMock(); - - // Should error if default RPCs flag is set to false. - stdChainsMock.exposed_setFallbackToDefaultRpcUrls(false); - vm.expectRevert(); - stdChainsMock.exposed_getChain(31337); - vm.expectRevert(); - stdChainsMock.exposed_getChain("sepolia"); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdCheats.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdCheats.t.sol deleted file mode 100644 index 0a5a832371..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdCheats.t.sol +++ /dev/null @@ -1,618 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {StdCheats} from "../src/StdCheats.sol"; -import {Test} from "../src/Test.sol"; -import {stdJson} from "../src/StdJson.sol"; -import {stdToml} from "../src/StdToml.sol"; -import {IERC20} from "../src/interfaces/IERC20.sol"; - -contract StdCheatsTest is Test { - Bar test; - - using stdJson for string; - - function setUp() public { - test = new Bar(); - } - - function test_Skip() public { - vm.warp(100); - skip(25); - assertEq(block.timestamp, 125); - } - - function test_Rewind() public { - vm.warp(100); - rewind(25); - assertEq(block.timestamp, 75); - } - - function test_Hoax() public { - hoax(address(1337)); - test.bar{value: 100}(address(1337)); - } - - function test_HoaxOrigin() public { - hoax(address(1337), address(1337)); - test.origin{value: 100}(address(1337)); - } - - function test_HoaxDifferentAddresses() public { - hoax(address(1337), address(7331)); - test.origin{value: 100}(address(1337), address(7331)); - } - - function test_StartHoax() public { - startHoax(address(1337)); - test.bar{value: 100}(address(1337)); - test.bar{value: 100}(address(1337)); - vm.stopPrank(); - test.bar(address(this)); - } - - function test_StartHoaxOrigin() public { - startHoax(address(1337), address(1337)); - test.origin{value: 100}(address(1337)); - test.origin{value: 100}(address(1337)); - vm.stopPrank(); - test.bar(address(this)); - } - - function test_ChangePrankMsgSender() public { - vm.startPrank(address(1337)); - test.bar(address(1337)); - changePrank(address(0xdead)); - test.bar(address(0xdead)); - changePrank(address(1337)); - test.bar(address(1337)); - vm.stopPrank(); - } - - function test_ChangePrankMsgSenderAndTxOrigin() public { - vm.startPrank(address(1337), address(1338)); - test.origin(address(1337), address(1338)); - changePrank(address(0xdead), address(0xbeef)); - test.origin(address(0xdead), address(0xbeef)); - changePrank(address(1337), address(1338)); - test.origin(address(1337), address(1338)); - vm.stopPrank(); - } - - function test_MakeAccountEquivalence() public { - Account memory account = makeAccount("1337"); - (address addr, uint256 key) = makeAddrAndKey("1337"); - assertEq(account.addr, addr); - assertEq(account.key, key); - } - - function test_MakeAddrEquivalence() public { - (address addr,) = makeAddrAndKey("1337"); - assertEq(makeAddr("1337"), addr); - } - - function test_MakeAddrSigning() public { - (address addr, uint256 key) = makeAddrAndKey("1337"); - bytes32 hash = keccak256("some_message"); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign(key, hash); - assertEq(ecrecover(hash, v, r, s), addr); - } - - function test_Deal() public { - deal(address(this), 1 ether); - assertEq(address(this).balance, 1 ether); - } - - function test_DealToken() public { - Bar barToken = new Bar(); - address bar = address(barToken); - deal(bar, address(this), 10000e18); - assertEq(barToken.balanceOf(address(this)), 10000e18); - } - - function test_DealTokenAdjustTotalSupply() public { - Bar barToken = new Bar(); - address bar = address(barToken); - deal(bar, address(this), 10000e18, true); - assertEq(barToken.balanceOf(address(this)), 10000e18); - assertEq(barToken.totalSupply(), 20000e18); - deal(bar, address(this), 0, true); - assertEq(barToken.balanceOf(address(this)), 0); - assertEq(barToken.totalSupply(), 10000e18); - } - - function test_DealERC1155Token() public { - BarERC1155 barToken = new BarERC1155(); - address bar = address(barToken); - dealERC1155(bar, address(this), 0, 10000e18, false); - assertEq(barToken.balanceOf(address(this), 0), 10000e18); - } - - function test_DealERC1155TokenAdjustTotalSupply() public { - BarERC1155 barToken = new BarERC1155(); - address bar = address(barToken); - dealERC1155(bar, address(this), 0, 10000e18, true); - assertEq(barToken.balanceOf(address(this), 0), 10000e18); - assertEq(barToken.totalSupply(0), 20000e18); - dealERC1155(bar, address(this), 0, 0, true); - assertEq(barToken.balanceOf(address(this), 0), 0); - assertEq(barToken.totalSupply(0), 10000e18); - } - - function test_DealERC721Token() public { - BarERC721 barToken = new BarERC721(); - address bar = address(barToken); - dealERC721(bar, address(2), 1); - assertEq(barToken.balanceOf(address(2)), 1); - assertEq(barToken.balanceOf(address(1)), 0); - dealERC721(bar, address(1), 2); - assertEq(barToken.balanceOf(address(1)), 1); - assertEq(barToken.balanceOf(bar), 1); - } - - function test_DeployCode() public { - address deployed = deployCode("StdCheats.t.sol:Bar", bytes("")); - assertEq(string(getCode(deployed)), string(getCode(address(test)))); - } - - function test_DestroyAccount() public { - // deploy something to destroy it - BarERC721 barToken = new BarERC721(); - address bar = address(barToken); - vm.setNonce(bar, 10); - deal(bar, 100); - - uint256 prevThisBalance = address(this).balance; - uint256 size; - assembly { - size := extcodesize(bar) - } - - assertGt(size, 0); - assertEq(bar.balance, 100); - assertEq(vm.getNonce(bar), 10); - - destroyAccount(bar, address(this)); - assembly { - size := extcodesize(bar) - } - assertEq(address(this).balance, prevThisBalance + 100); - assertEq(vm.getNonce(bar), 0); - assertEq(size, 0); - assertEq(bar.balance, 0); - } - - function test_DeployCodeNoArgs() public { - address deployed = deployCode("StdCheats.t.sol:Bar"); - assertEq(string(getCode(deployed)), string(getCode(address(test)))); - } - - function test_DeployCodeVal() public { - address deployed = deployCode("StdCheats.t.sol:Bar", bytes(""), 1 ether); - assertEq(string(getCode(deployed)), string(getCode(address(test)))); - assertEq(deployed.balance, 1 ether); - } - - function test_DeployCodeValNoArgs() public { - address deployed = deployCode("StdCheats.t.sol:Bar", 1 ether); - assertEq(string(getCode(deployed)), string(getCode(address(test)))); - assertEq(deployed.balance, 1 ether); - } - - // We need this so we can call "this.deployCode" rather than "deployCode" directly - function deployCodeHelper(string memory what) external { - deployCode(what); - } - - function test_RevertIf_DeployCodeFail() public { - vm.expectRevert(bytes("StdCheats deployCode(string): Deployment failed.")); - this.deployCodeHelper("StdCheats.t.sol:RevertingContract"); - } - - function getCode(address who) internal view returns (bytes memory o_code) { - /// @solidity memory-safe-assembly - assembly { - // retrieve the size of the code, this needs assembly - let size := extcodesize(who) - // allocate output byte array - this could also be done without assembly - // by using o_code = new bytes(size) - o_code := mload(0x40) - // new "memory end" including padding - mstore(0x40, add(o_code, and(add(add(size, 0x20), 0x1f), not(0x1f)))) - // store length in memory - mstore(o_code, size) - // actually retrieve the code, this needs assembly - extcodecopy(who, add(o_code, 0x20), 0, size) - } - } - - function test_DeriveRememberKey() public { - string memory mnemonic = "test test test test test test test test test test test junk"; - - (address deployer, uint256 privateKey) = deriveRememberKey(mnemonic, 0); - assertEq(deployer, 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266); - assertEq(privateKey, 0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80); - } - - function test_BytesToUint() public pure { - assertEq(3, bytesToUint_test(hex"03")); - assertEq(2, bytesToUint_test(hex"02")); - assertEq(255, bytesToUint_test(hex"ff")); - assertEq(29625, bytesToUint_test(hex"73b9")); - } - - function test_ParseJsonTxDetail() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - string memory json = vm.readFile(path); - bytes memory transactionDetails = json.parseRaw(".transactions[0].tx"); - RawTx1559Detail memory rawTxDetail = abi.decode(transactionDetails, (RawTx1559Detail)); - Tx1559Detail memory txDetail = rawToConvertedEIP1559Detail(rawTxDetail); - assertEq(txDetail.from, 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266); - assertEq(txDetail.to, 0xe7f1725E7734CE288F8367e1Bb143E90bb3F0512); - assertEq( - txDetail.data, - hex"23e99187000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000013370000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000000004" - ); - assertEq(txDetail.nonce, 3); - assertEq(txDetail.txType, 2); - assertEq(txDetail.gas, 29625); - assertEq(txDetail.value, 0); - } - - function test_ReadEIP1559Transaction() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - uint256 index = 0; - Tx1559 memory transaction = readTx1559(path, index); - transaction; - } - - function test_ReadEIP1559Transactions() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - Tx1559[] memory transactions = readTx1559s(path); - transactions; - } - - function test_ReadReceipt() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - uint256 index = 5; - Receipt memory receipt = readReceipt(path, index); - assertEq( - receipt.logsBloom, - hex"00000000000800000000000000000010000000000000000000000000000180000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100" - ); - } - - function test_ReadReceipts() public view { - string memory root = vm.projectRoot(); - string memory path = string.concat(root, "/test/fixtures/broadcast.log.json"); - Receipt[] memory receipts = readReceipts(path); - receipts; - } - - function test_GasMeteringModifier() public { - uint256 gas_start_normal = gasleft(); - addInLoop(); - uint256 gas_used_normal = gas_start_normal - gasleft(); - - uint256 gas_start_single = gasleft(); - addInLoopNoGas(); - uint256 gas_used_single = gas_start_single - gasleft(); - - uint256 gas_start_double = gasleft(); - addInLoopNoGasNoGas(); - uint256 gas_used_double = gas_start_double - gasleft(); - - assertTrue(gas_used_double + gas_used_single < gas_used_normal); - } - - function addInLoop() internal pure returns (uint256) { - uint256 b; - for (uint256 i; i < 10000; i++) { - b += i; - } - return b; - } - - function addInLoopNoGas() internal noGasMetering returns (uint256) { - return addInLoop(); - } - - function addInLoopNoGasNoGas() internal noGasMetering returns (uint256) { - return addInLoopNoGas(); - } - - function bytesToUint_test(bytes memory b) private pure returns (uint256) { - uint256 number; - for (uint256 i = 0; i < b.length; i++) { - number = number + uint256(uint8(b[i])) * (2 ** (8 * (b.length - (i + 1)))); - } - return number; - } - - function testFuzz_AssumeAddressIsNot(address addr) external { - // skip over Payable and NonPayable enums - for (uint8 i = 2; i < uint8(type(AddressType).max); i++) { - assumeAddressIsNot(addr, AddressType(i)); - } - assertTrue(addr != address(0)); - assertTrue(addr < address(1) || addr > address(9)); - assertTrue(addr != address(vm) || addr != 0x000000000000000000636F6e736F6c652e6c6f67); - } - - function test_AssumePayable() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - - // all should revert since these addresses are not payable - - // VM address - vm.expectRevert(); - stdCheatsMock.exposed_assumePayable(0x7109709ECfa91a80626fF3989D68f67F5b1DD12D); - - // Console address - vm.expectRevert(); - stdCheatsMock.exposed_assumePayable(0x000000000000000000636F6e736F6c652e6c6f67); - - // Create2Deployer - vm.expectRevert(); - stdCheatsMock.exposed_assumePayable(0x4e59b44847b379578588920cA78FbF26c0B4956C); - - // all should pass since these addresses are payable - - // vitalik.eth - stdCheatsMock.exposed_assumePayable(0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045); - - // mock payable contract - MockContractPayable cp = new MockContractPayable(); - stdCheatsMock.exposed_assumePayable(address(cp)); - } - - function test_AssumeNotPayable() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - - // all should pass since these addresses are not payable - - // VM address - stdCheatsMock.exposed_assumeNotPayable(0x7109709ECfa91a80626fF3989D68f67F5b1DD12D); - - // Console address - stdCheatsMock.exposed_assumeNotPayable(0x000000000000000000636F6e736F6c652e6c6f67); - - // Create2Deployer - stdCheatsMock.exposed_assumeNotPayable(0x4e59b44847b379578588920cA78FbF26c0B4956C); - - // all should revert since these addresses are payable - - // vitalik.eth - vm.expectRevert(); - stdCheatsMock.exposed_assumeNotPayable(0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045); - - // mock payable contract - MockContractPayable cp = new MockContractPayable(); - vm.expectRevert(); - stdCheatsMock.exposed_assumeNotPayable(address(cp)); - } - - function testFuzz_AssumeNotPrecompile(address addr) external { - assumeNotPrecompile(addr, getChain("optimism_sepolia").chainId); - assertTrue( - addr < address(1) || (addr > address(9) && addr < address(0x4200000000000000000000000000000000000000)) - || addr > address(0x4200000000000000000000000000000000000800) - ); - } - - function testFuzz_AssumeNotForgeAddress(address addr) external pure { - assumeNotForgeAddress(addr); - assertTrue( - addr != address(vm) && addr != 0x000000000000000000636F6e736F6c652e6c6f67 - && addr != 0x4e59b44847b379578588920cA78FbF26c0B4956C - ); - } - - function test_RevertIf_CannotDeployCodeTo() external { - vm.expectRevert("StdCheats deployCodeTo(string,bytes,uint256,address): Failed to create runtime bytecode."); - this._revertDeployCodeTo(); - } - - function _revertDeployCodeTo() external { - deployCodeTo("StdCheats.t.sol:RevertingContract", address(0)); - } - - function test_DeployCodeTo() external { - address arbitraryAddress = makeAddr("arbitraryAddress"); - - deployCodeTo( - "StdCheats.t.sol:MockContractWithConstructorArgs", - abi.encode(uint256(6), true, bytes20(arbitraryAddress)), - 1 ether, - arbitraryAddress - ); - - MockContractWithConstructorArgs ct = MockContractWithConstructorArgs(arbitraryAddress); - - assertEq(arbitraryAddress.balance, 1 ether); - assertEq(ct.x(), 6); - assertTrue(ct.y()); - assertEq(ct.z(), bytes20(arbitraryAddress)); - } -} - -contract StdCheatsMock is StdCheats { - function exposed_assumePayable(address addr) external { - assumePayable(addr); - } - - function exposed_assumeNotPayable(address addr) external { - assumeNotPayable(addr); - } - - // We deploy a mock version so we can properly test expected reverts. - function exposed_assumeNotBlacklisted(address token, address addr) external view { - return assumeNotBlacklisted(token, addr); - } -} - -contract StdCheatsForkTest is Test { - address internal constant SHIB = 0x95aD61b0a150d79219dCF64E1E6Cc01f0B64C4cE; - address internal constant USDC = 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48; - address internal constant USDC_BLACKLISTED_USER = 0x1E34A77868E19A6647b1f2F47B51ed72dEDE95DD; - address internal constant USDT = 0xdAC17F958D2ee523a2206206994597C13D831ec7; - address internal constant USDT_BLACKLISTED_USER = 0x8f8a8F4B54a2aAC7799d7bc81368aC27b852822A; - - function setUp() public { - // All tests of the `assumeNotBlacklisted` method are fork tests using live contracts. - vm.createSelectFork({urlOrAlias: "mainnet", blockNumber: 16_428_900}); - } - - function test_RevertIf_CannotAssumeNoBlacklisted_EOA() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - address eoa = vm.addr({privateKey: 1}); - vm.expectRevert("StdCheats assumeNotBlacklisted(address,address): Token address is not a contract."); - stdCheatsMock.exposed_assumeNotBlacklisted(eoa, address(0)); - } - - function testFuzz_AssumeNotBlacklisted_TokenWithoutBlacklist(address addr) external view { - assumeNotBlacklisted(SHIB, addr); - assertTrue(true); - } - - function test_RevertIf_AssumeNoBlacklisted_USDC() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - vm.expectRevert(); - stdCheatsMock.exposed_assumeNotBlacklisted(USDC, USDC_BLACKLISTED_USER); - } - - function testFuzz_AssumeNotBlacklisted_USDC(address addr) external view { - assumeNotBlacklisted(USDC, addr); - assertFalse(USDCLike(USDC).isBlacklisted(addr)); - } - - function test_RevertIf_AssumeNoBlacklisted_USDT() external { - // We deploy a mock version so we can properly test the revert. - StdCheatsMock stdCheatsMock = new StdCheatsMock(); - vm.expectRevert(); - stdCheatsMock.exposed_assumeNotBlacklisted(USDT, USDT_BLACKLISTED_USER); - } - - function testFuzz_AssumeNotBlacklisted_USDT(address addr) external view { - assumeNotBlacklisted(USDT, addr); - assertFalse(USDTLike(USDT).isBlackListed(addr)); - } - - function test_dealUSDC() external { - // roll fork to the point when USDC contract updated to store balance in packed slots - vm.rollFork(19279215); - - uint256 balance = 100e6; - deal(USDC, address(this), balance); - assertEq(IERC20(USDC).balanceOf(address(this)), balance); - } -} - -contract Bar { - constructor() payable { - /// `DEAL` STDCHEAT - totalSupply = 10000e18; - balanceOf[address(this)] = totalSupply; - } - - /// `HOAX` and `CHANGEPRANK` STDCHEATS - function bar(address expectedSender) public payable { - require(msg.sender == expectedSender, "!prank"); - } - - function origin(address expectedSender) public payable { - require(msg.sender == expectedSender, "!prank"); - require(tx.origin == expectedSender, "!prank"); - } - - function origin(address expectedSender, address expectedOrigin) public payable { - require(msg.sender == expectedSender, "!prank"); - require(tx.origin == expectedOrigin, "!prank"); - } - - /// `DEAL` STDCHEAT - mapping(address => uint256) public balanceOf; - uint256 public totalSupply; -} - -contract BarERC1155 { - constructor() payable { - /// `DEALERC1155` STDCHEAT - _totalSupply[0] = 10000e18; - _balances[0][address(this)] = _totalSupply[0]; - } - - function balanceOf(address account, uint256 id) public view virtual returns (uint256) { - return _balances[id][account]; - } - - function totalSupply(uint256 id) public view virtual returns (uint256) { - return _totalSupply[id]; - } - - /// `DEALERC1155` STDCHEAT - mapping(uint256 => mapping(address => uint256)) private _balances; - mapping(uint256 => uint256) private _totalSupply; -} - -contract BarERC721 { - constructor() payable { - /// `DEALERC721` STDCHEAT - _owners[1] = address(1); - _balances[address(1)] = 1; - _owners[2] = address(this); - _owners[3] = address(this); - _balances[address(this)] = 2; - } - - function balanceOf(address owner) public view virtual returns (uint256) { - return _balances[owner]; - } - - function ownerOf(uint256 tokenId) public view virtual returns (address) { - address owner = _owners[tokenId]; - return owner; - } - - mapping(uint256 => address) private _owners; - mapping(address => uint256) private _balances; -} - -interface USDCLike { - function isBlacklisted(address) external view returns (bool); -} - -interface USDTLike { - function isBlackListed(address) external view returns (bool); -} - -contract RevertingContract { - constructor() { - revert(); - } -} - -contract MockContractWithConstructorArgs { - uint256 public immutable x; - bool public y; - bytes20 public z; - - constructor(uint256 _x, bool _y, bytes20 _z) payable { - x = _x; - y = _y; - z = _z; - } -} - -contract MockContractPayable { - receive() external payable {} -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdError.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdError.t.sol deleted file mode 100644 index 29803d5d52..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdError.t.sol +++ /dev/null @@ -1,120 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.8.0 <0.9.0; - -import {stdError} from "../src/StdError.sol"; -import {Test} from "../src/Test.sol"; - -contract StdErrorsTest is Test { - ErrorsTest test; - - function setUp() public { - test = new ErrorsTest(); - } - - function test_RevertIf_AssertionError() public { - vm.expectRevert(stdError.assertionError); - test.assertionError(); - } - - function test_RevertIf_ArithmeticError() public { - vm.expectRevert(stdError.arithmeticError); - test.arithmeticError(10); - } - - function test_RevertIf_DivisionError() public { - vm.expectRevert(stdError.divisionError); - test.divError(0); - } - - function test_RevertIf_ModError() public { - vm.expectRevert(stdError.divisionError); - test.modError(0); - } - - function test_RevertIf_EnumConversionError() public { - vm.expectRevert(stdError.enumConversionError); - test.enumConversion(1); - } - - function test_RevertIf_EncodeStgError() public { - vm.expectRevert(stdError.encodeStorageError); - test.encodeStgError(); - } - - function test_RevertIf_PopError() public { - vm.expectRevert(stdError.popError); - test.pop(); - } - - function test_RevertIf_IndexOOBError() public { - vm.expectRevert(stdError.indexOOBError); - test.indexOOBError(1); - } - - function test_RevertIf_MemOverflowError() public { - vm.expectRevert(stdError.memOverflowError); - test.mem(); - } - - function test_RevertIf_InternError() public { - vm.expectRevert(stdError.zeroVarError); - test.intern(); - } -} - -contract ErrorsTest { - enum T { - T1 - } - - uint256[] public someArr; - bytes someBytes; - - function assertionError() public pure { - assert(false); - } - - function arithmeticError(uint256 a) public pure { - a -= 100; - } - - function divError(uint256 a) public pure { - 100 / a; - } - - function modError(uint256 a) public pure { - 100 % a; - } - - function enumConversion(uint256 a) public pure { - T(a); - } - - function encodeStgError() public { - /// @solidity memory-safe-assembly - assembly { - sstore(someBytes.slot, 1) - } - keccak256(someBytes); - } - - function pop() public { - someArr.pop(); - } - - function indexOOBError(uint256 a) public pure { - uint256[] memory t = new uint256[](0); - t[a]; - } - - function mem() public pure { - uint256 l = 2 ** 256 / 32; - new uint256[](l); - } - - function intern() public returns (uint256) { - function(uint256) internal returns (uint256) x; - x(2); - return 7; - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdJson.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdJson.t.sol deleted file mode 100644 index 6bedfcc9a8..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdJson.t.sol +++ /dev/null @@ -1,49 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {Test, stdJson} from "../src/Test.sol"; - -contract StdJsonTest is Test { - using stdJson for string; - - string root; - string path; - - function setUp() public { - root = vm.projectRoot(); - path = string.concat(root, "/test/fixtures/test.json"); - } - - struct SimpleJson { - uint256 a; - string b; - } - - struct NestedJson { - uint256 a; - string b; - SimpleJson c; - } - - function test_readJson() public view { - string memory json = vm.readFile(path); - assertEq(json.readUint(".a"), 123); - } - - function test_writeJson() public { - string memory json = "json"; - json.serialize("a", uint256(123)); - string memory semiFinal = json.serialize("b", string("test")); - string memory finalJson = json.serialize("c", semiFinal); - finalJson.write(path); - - string memory json_ = vm.readFile(path); - bytes memory data = json_.parseRaw("$"); - NestedJson memory decodedData = abi.decode(data, (NestedJson)); - - assertEq(decodedData.a, 123); - assertEq(decodedData.b, "test"); - assertEq(decodedData.c.a, 123); - assertEq(decodedData.c.b, "test"); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdMath.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdMath.t.sol deleted file mode 100644 index d1269a02ac..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdMath.t.sol +++ /dev/null @@ -1,202 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.8.0 <0.9.0; - -import {stdMath} from "../src/StdMath.sol"; -import {Test, stdError} from "../src/Test.sol"; - -contract StdMathMock is Test { - function exposed_percentDelta(uint256 a, uint256 b) public pure returns (uint256) { - return stdMath.percentDelta(a, b); - } - - function exposed_percentDelta(int256 a, int256 b) public pure returns (uint256) { - return stdMath.percentDelta(a, b); - } -} - -contract StdMathTest is Test { - function test_GetAbs() external pure { - assertEq(stdMath.abs(-50), 50); - assertEq(stdMath.abs(50), 50); - assertEq(stdMath.abs(-1337), 1337); - assertEq(stdMath.abs(0), 0); - - assertEq(stdMath.abs(type(int256).min), (type(uint256).max >> 1) + 1); - assertEq(stdMath.abs(type(int256).max), (type(uint256).max >> 1)); - } - - function testFuzz_GetAbs(int256 a) external pure { - uint256 manualAbs = getAbs(a); - - uint256 abs = stdMath.abs(a); - - assertEq(abs, manualAbs); - } - - function test_GetDelta_Uint() external pure { - assertEq(stdMath.delta(uint256(0), uint256(0)), 0); - assertEq(stdMath.delta(uint256(0), uint256(1337)), 1337); - assertEq(stdMath.delta(uint256(0), type(uint64).max), type(uint64).max); - assertEq(stdMath.delta(uint256(0), type(uint128).max), type(uint128).max); - assertEq(stdMath.delta(uint256(0), type(uint256).max), type(uint256).max); - - assertEq(stdMath.delta(0, uint256(0)), 0); - assertEq(stdMath.delta(1337, uint256(0)), 1337); - assertEq(stdMath.delta(type(uint64).max, uint256(0)), type(uint64).max); - assertEq(stdMath.delta(type(uint128).max, uint256(0)), type(uint128).max); - assertEq(stdMath.delta(type(uint256).max, uint256(0)), type(uint256).max); - - assertEq(stdMath.delta(1337, uint256(1337)), 0); - assertEq(stdMath.delta(type(uint256).max, type(uint256).max), 0); - assertEq(stdMath.delta(5000, uint256(1250)), 3750); - } - - function testFuzz_GetDelta_Uint(uint256 a, uint256 b) external pure { - uint256 manualDelta = a > b ? a - b : b - a; - - uint256 delta = stdMath.delta(a, b); - - assertEq(delta, manualDelta); - } - - function test_GetDelta_Int() external pure { - assertEq(stdMath.delta(int256(0), int256(0)), 0); - assertEq(stdMath.delta(int256(0), int256(1337)), 1337); - assertEq(stdMath.delta(int256(0), type(int64).max), type(uint64).max >> 1); - assertEq(stdMath.delta(int256(0), type(int128).max), type(uint128).max >> 1); - assertEq(stdMath.delta(int256(0), type(int256).max), type(uint256).max >> 1); - - assertEq(stdMath.delta(0, int256(0)), 0); - assertEq(stdMath.delta(1337, int256(0)), 1337); - assertEq(stdMath.delta(type(int64).max, int256(0)), type(uint64).max >> 1); - assertEq(stdMath.delta(type(int128).max, int256(0)), type(uint128).max >> 1); - assertEq(stdMath.delta(type(int256).max, int256(0)), type(uint256).max >> 1); - - assertEq(stdMath.delta(-0, int256(0)), 0); - assertEq(stdMath.delta(-1337, int256(0)), 1337); - assertEq(stdMath.delta(type(int64).min, int256(0)), (type(uint64).max >> 1) + 1); - assertEq(stdMath.delta(type(int128).min, int256(0)), (type(uint128).max >> 1) + 1); - assertEq(stdMath.delta(type(int256).min, int256(0)), (type(uint256).max >> 1) + 1); - - assertEq(stdMath.delta(int256(0), -0), 0); - assertEq(stdMath.delta(int256(0), -1337), 1337); - assertEq(stdMath.delta(int256(0), type(int64).min), (type(uint64).max >> 1) + 1); - assertEq(stdMath.delta(int256(0), type(int128).min), (type(uint128).max >> 1) + 1); - assertEq(stdMath.delta(int256(0), type(int256).min), (type(uint256).max >> 1) + 1); - - assertEq(stdMath.delta(1337, int256(1337)), 0); - assertEq(stdMath.delta(type(int256).max, type(int256).max), 0); - assertEq(stdMath.delta(type(int256).min, type(int256).min), 0); - assertEq(stdMath.delta(type(int256).min, type(int256).max), type(uint256).max); - assertEq(stdMath.delta(5000, int256(1250)), 3750); - } - - function testFuzz_GetDelta_Int(int256 a, int256 b) external pure { - uint256 absA = getAbs(a); - uint256 absB = getAbs(b); - uint256 absDelta = absA > absB ? absA - absB : absB - absA; - - uint256 manualDelta; - if ((a >= 0 && b >= 0) || (a < 0 && b < 0)) { - manualDelta = absDelta; - } - // (a < 0 && b >= 0) || (a >= 0 && b < 0) - else { - manualDelta = absA + absB; - } - - uint256 delta = stdMath.delta(a, b); - - assertEq(delta, manualDelta); - } - - function test_GetPercentDelta_Uint() external { - StdMathMock stdMathMock = new StdMathMock(); - - assertEq(stdMath.percentDelta(uint256(0), uint256(1337)), 1e18); - assertEq(stdMath.percentDelta(uint256(0), type(uint64).max), 1e18); - assertEq(stdMath.percentDelta(uint256(0), type(uint128).max), 1e18); - assertEq(stdMath.percentDelta(uint256(0), type(uint192).max), 1e18); - - assertEq(stdMath.percentDelta(1337, uint256(1337)), 0); - assertEq(stdMath.percentDelta(type(uint192).max, type(uint192).max), 0); - assertEq(stdMath.percentDelta(0, uint256(2500)), 1e18); - assertEq(stdMath.percentDelta(2500, uint256(2500)), 0); - assertEq(stdMath.percentDelta(5000, uint256(2500)), 1e18); - assertEq(stdMath.percentDelta(7500, uint256(2500)), 2e18); - - vm.expectRevert(stdError.divisionError); - stdMathMock.exposed_percentDelta(uint256(1), 0); - } - - function testFuzz_GetPercentDelta_Uint(uint192 a, uint192 b) external pure { - vm.assume(b != 0); - uint256 manualDelta = a > b ? a - b : b - a; - - uint256 manualPercentDelta = manualDelta * 1e18 / b; - uint256 percentDelta = stdMath.percentDelta(a, b); - - assertEq(percentDelta, manualPercentDelta); - } - - function test_GetPercentDelta_Int() external { - // We deploy a mock version so we can properly test the revert. - StdMathMock stdMathMock = new StdMathMock(); - - assertEq(stdMath.percentDelta(int256(0), int256(1337)), 1e18); - assertEq(stdMath.percentDelta(int256(0), -1337), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int64).min), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int128).min), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int192).min), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int64).max), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int128).max), 1e18); - assertEq(stdMath.percentDelta(int256(0), type(int192).max), 1e18); - - assertEq(stdMath.percentDelta(1337, int256(1337)), 0); - assertEq(stdMath.percentDelta(type(int192).max, type(int192).max), 0); - assertEq(stdMath.percentDelta(type(int192).min, type(int192).min), 0); - - assertEq(stdMath.percentDelta(type(int192).min, type(int192).max), 2e18); // rounds the 1 wei diff down - assertEq(stdMath.percentDelta(type(int192).max, type(int192).min), 2e18 - 1); // rounds the 1 wei diff down - assertEq(stdMath.percentDelta(0, int256(2500)), 1e18); - assertEq(stdMath.percentDelta(2500, int256(2500)), 0); - assertEq(stdMath.percentDelta(5000, int256(2500)), 1e18); - assertEq(stdMath.percentDelta(7500, int256(2500)), 2e18); - - vm.expectRevert(stdError.divisionError); - stdMathMock.exposed_percentDelta(int256(1), 0); - } - - function testFuzz_GetPercentDelta_Int(int192 a, int192 b) external pure { - vm.assume(b != 0); - uint256 absA = getAbs(a); - uint256 absB = getAbs(b); - uint256 absDelta = absA > absB ? absA - absB : absB - absA; - - uint256 manualDelta; - if ((a >= 0 && b >= 0) || (a < 0 && b < 0)) { - manualDelta = absDelta; - } - // (a < 0 && b >= 0) || (a >= 0 && b < 0) - else { - manualDelta = absA + absB; - } - - uint256 manualPercentDelta = manualDelta * 1e18 / absB; - uint256 percentDelta = stdMath.percentDelta(a, b); - - assertEq(percentDelta, manualPercentDelta); - } - - /*////////////////////////////////////////////////////////////////////////// - HELPERS - //////////////////////////////////////////////////////////////////////////*/ - - function getAbs(int256 a) private pure returns (uint256) { - if (a < 0) { - return a == type(int256).min ? uint256(type(int256).max) + 1 : uint256(-a); - } - - return uint256(a); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdStorage.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdStorage.t.sol deleted file mode 100644 index fd79abaae7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdStorage.t.sol +++ /dev/null @@ -1,471 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {stdStorage, StdStorage} from "../src/StdStorage.sol"; -import {Test} from "../src/Test.sol"; - -contract StdStorageTest is Test { - using stdStorage for StdStorage; - - StorageTest internal test; - - function setUp() public { - test = new StorageTest(); - } - - function test_StorageHidden() public { - assertEq(uint256(keccak256("my.random.var")), stdstore.target(address(test)).sig("hidden()").find()); - } - - function test_StorageObvious() public { - assertEq(uint256(0), stdstore.target(address(test)).sig("exists()").find()); - } - - function test_StorageExtraSload() public { - assertEq(16, stdstore.target(address(test)).sig(test.extra_sload.selector).find()); - } - - function test_StorageCheckedWriteHidden() public { - stdstore.target(address(test)).sig(test.hidden.selector).checked_write(100); - assertEq(uint256(test.hidden()), 100); - } - - function test_StorageCheckedWriteObvious() public { - stdstore.target(address(test)).sig(test.exists.selector).checked_write(100); - assertEq(test.exists(), 100); - } - - function test_StorageCheckedWriteSignedIntegerHidden() public { - stdstore.target(address(test)).sig(test.hidden.selector).checked_write_int(-100); - assertEq(int256(uint256(test.hidden())), -100); - } - - function test_StorageCheckedWriteSignedIntegerObvious() public { - stdstore.target(address(test)).sig(test.tG.selector).checked_write_int(-100); - assertEq(test.tG(), -100); - } - - function test_StorageMapStructA() public { - uint256 slot = - stdstore.target(address(test)).sig(test.map_struct.selector).with_key(address(this)).depth(0).find(); - assertEq(uint256(keccak256(abi.encode(address(this), 4))), slot); - } - - function test_StorageMapStructB() public { - uint256 slot = - stdstore.target(address(test)).sig(test.map_struct.selector).with_key(address(this)).depth(1).find(); - assertEq(uint256(keccak256(abi.encode(address(this), 4))) + 1, slot); - } - - function test_StorageDeepMap() public { - uint256 slot = stdstore.target(address(test)).sig(test.deep_map.selector).with_key(address(this)).with_key( - address(this) - ).find(); - assertEq(uint256(keccak256(abi.encode(address(this), keccak256(abi.encode(address(this), uint256(5)))))), slot); - } - - function test_StorageCheckedWriteDeepMap() public { - stdstore.target(address(test)).sig(test.deep_map.selector).with_key(address(this)).with_key(address(this)) - .checked_write(100); - assertEq(100, test.deep_map(address(this), address(this))); - } - - function test_StorageDeepMapStructA() public { - uint256 slot = stdstore.target(address(test)).sig(test.deep_map_struct.selector).with_key(address(this)) - .with_key(address(this)).depth(0).find(); - assertEq( - bytes32(uint256(keccak256(abi.encode(address(this), keccak256(abi.encode(address(this), uint256(6)))))) + 0), - bytes32(slot) - ); - } - - function test_StorageDeepMapStructB() public { - uint256 slot = stdstore.target(address(test)).sig(test.deep_map_struct.selector).with_key(address(this)) - .with_key(address(this)).depth(1).find(); - assertEq( - bytes32(uint256(keccak256(abi.encode(address(this), keccak256(abi.encode(address(this), uint256(6)))))) + 1), - bytes32(slot) - ); - } - - function test_StorageCheckedWriteDeepMapStructA() public { - stdstore.target(address(test)).sig(test.deep_map_struct.selector).with_key(address(this)).with_key( - address(this) - ).depth(0).checked_write(100); - (uint256 a, uint256 b) = test.deep_map_struct(address(this), address(this)); - assertEq(100, a); - assertEq(0, b); - } - - function test_StorageCheckedWriteDeepMapStructB() public { - stdstore.target(address(test)).sig(test.deep_map_struct.selector).with_key(address(this)).with_key( - address(this) - ).depth(1).checked_write(100); - (uint256 a, uint256 b) = test.deep_map_struct(address(this), address(this)); - assertEq(0, a); - assertEq(100, b); - } - - function test_StorageCheckedWriteMapStructA() public { - stdstore.target(address(test)).sig(test.map_struct.selector).with_key(address(this)).depth(0).checked_write(100); - (uint256 a, uint256 b) = test.map_struct(address(this)); - assertEq(a, 100); - assertEq(b, 0); - } - - function test_StorageCheckedWriteMapStructB() public { - stdstore.target(address(test)).sig(test.map_struct.selector).with_key(address(this)).depth(1).checked_write(100); - (uint256 a, uint256 b) = test.map_struct(address(this)); - assertEq(a, 0); - assertEq(b, 100); - } - - function test_StorageStructA() public { - uint256 slot = stdstore.target(address(test)).sig(test.basic.selector).depth(0).find(); - assertEq(uint256(7), slot); - } - - function test_StorageStructB() public { - uint256 slot = stdstore.target(address(test)).sig(test.basic.selector).depth(1).find(); - assertEq(uint256(7) + 1, slot); - } - - function test_StorageCheckedWriteStructA() public { - stdstore.target(address(test)).sig(test.basic.selector).depth(0).checked_write(100); - (uint256 a, uint256 b) = test.basic(); - assertEq(a, 100); - assertEq(b, 1337); - } - - function test_StorageCheckedWriteStructB() public { - stdstore.target(address(test)).sig(test.basic.selector).depth(1).checked_write(100); - (uint256 a, uint256 b) = test.basic(); - assertEq(a, 1337); - assertEq(b, 100); - } - - function test_StorageMapAddrFound() public { - uint256 slot = stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).find(); - assertEq(uint256(keccak256(abi.encode(address(this), uint256(1)))), slot); - } - - function test_StorageMapAddrRoot() public { - (uint256 slot, bytes32 key) = - stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).parent(); - assertEq(address(uint160(uint256(key))), address(this)); - assertEq(uint256(1), slot); - slot = stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).root(); - assertEq(uint256(1), slot); - } - - function test_StorageMapUintFound() public { - uint256 slot = stdstore.target(address(test)).sig(test.map_uint.selector).with_key(100).find(); - assertEq(uint256(keccak256(abi.encode(100, uint256(2)))), slot); - } - - function test_StorageCheckedWriteMapUint() public { - stdstore.target(address(test)).sig(test.map_uint.selector).with_key(100).checked_write(100); - assertEq(100, test.map_uint(100)); - } - - function test_StorageCheckedWriteMapAddr() public { - stdstore.target(address(test)).sig(test.map_addr.selector).with_key(address(this)).checked_write(100); - assertEq(100, test.map_addr(address(this))); - } - - function test_StorageCheckedWriteMapBool() public { - stdstore.target(address(test)).sig(test.map_bool.selector).with_key(address(this)).checked_write(true); - assertTrue(test.map_bool(address(this))); - } - - function testFuzz_StorageCheckedWriteMapPacked(address addr, uint128 value) public { - stdstore.enable_packed_slots().target(address(test)).sig(test.read_struct_lower.selector).with_key(addr) - .checked_write(value); - assertEq(test.read_struct_lower(addr), value); - - stdstore.enable_packed_slots().target(address(test)).sig(test.read_struct_upper.selector).with_key(addr) - .checked_write(value); - assertEq(test.read_struct_upper(addr), value); - } - - function test_StorageCheckedWriteMapPackedFullSuccess() public { - uint256 full = test.map_packed(address(1337)); - // keep upper 128, set lower 128 to 1337 - full = (full & (uint256((1 << 128) - 1) << 128)) | 1337; - stdstore.target(address(test)).sig(test.map_packed.selector).with_key(address(uint160(1337))).checked_write( - full - ); - assertEq(1337, test.read_struct_lower(address(1337))); - } - - function testFail_StorageConst() public { - // vm.expectRevert(abi.encodeWithSignature("NotStorage(bytes4)", bytes4(keccak256("const()")))); - stdstore.target(address(test)).sig("const()").find(); - } - - function testFuzz_StorageNativePack(uint248 val1, uint248 val2, bool boolVal1, bool boolVal2) public { - stdstore.enable_packed_slots().target(address(test)).sig(test.tA.selector).checked_write(val1); - stdstore.enable_packed_slots().target(address(test)).sig(test.tB.selector).checked_write(boolVal1); - stdstore.enable_packed_slots().target(address(test)).sig(test.tC.selector).checked_write(boolVal2); - stdstore.enable_packed_slots().target(address(test)).sig(test.tD.selector).checked_write(val2); - - assertEq(test.tA(), val1); - assertEq(test.tB(), boolVal1); - assertEq(test.tC(), boolVal2); - assertEq(test.tD(), val2); - } - - function test_StorageReadBytes32() public { - bytes32 val = stdstore.target(address(test)).sig(test.tE.selector).read_bytes32(); - assertEq(val, hex"1337"); - } - - function test_StorageReadBool_False() public { - bool val = stdstore.target(address(test)).sig(test.tB.selector).read_bool(); - assertEq(val, false); - } - - function test_StorageReadBool_True() public { - bool val = stdstore.target(address(test)).sig(test.tH.selector).read_bool(); - assertEq(val, true); - } - - function test_RevertIf_ReadingNonBoolValue() public { - vm.expectRevert("stdStorage read_bool(StdStorage): Cannot decode. Make sure you are reading a bool."); - this.readNonBoolValue(); - } - - function readNonBoolValue() public { - stdstore.target(address(test)).sig(test.tE.selector).read_bool(); - } - - function test_StorageReadAddress() public { - address val = stdstore.target(address(test)).sig(test.tF.selector).read_address(); - assertEq(val, address(1337)); - } - - function test_StorageReadUint() public { - uint256 val = stdstore.target(address(test)).sig(test.exists.selector).read_uint(); - assertEq(val, 1); - } - - function test_StorageReadInt() public { - int256 val = stdstore.target(address(test)).sig(test.tG.selector).read_int(); - assertEq(val, type(int256).min); - } - - function testFuzz_Packed(uint256 val, uint8 elemToGet) public { - // This function tries an assortment of packed slots, shifts meaning number of elements - // that are packed. Shiftsizes are the size of each element, i.e. 8 means a data type that is 8 bits, 16 == 16 bits, etc. - // Combined, these determine how a slot is packed. Making it random is too hard to avoid global rejection limit - // and make it performant. - - // change the number of shifts - for (uint256 i = 1; i < 5; i++) { - uint256 shifts = i; - - elemToGet = uint8(bound(elemToGet, 0, shifts - 1)); - - uint256[] memory shiftSizes = new uint256[](shifts); - for (uint256 j; j < shifts; j++) { - shiftSizes[j] = 8 * (j + 1); - } - - test.setRandomPacking(val); - - uint256 leftBits; - uint256 rightBits; - for (uint256 j; j < shiftSizes.length; j++) { - if (j < elemToGet) { - leftBits += shiftSizes[j]; - } else if (elemToGet != j) { - rightBits += shiftSizes[j]; - } - } - - // we may have some right bits unaccounted for - leftBits += 256 - (leftBits + shiftSizes[elemToGet] + rightBits); - // clear left bits, then clear right bits and realign - uint256 expectedValToRead = (val << leftBits) >> (leftBits + rightBits); - - uint256 readVal = stdstore.target(address(test)).enable_packed_slots().sig( - "getRandomPacked(uint8,uint8[],uint8)" - ).with_calldata(abi.encode(shifts, shiftSizes, elemToGet)).read_uint(); - - assertEq(readVal, expectedValToRead); - } - } - - function testFuzz_Packed2(uint256 nvars, uint256 seed) public { - // Number of random variables to generate. - nvars = bound(nvars, 1, 20); - - // This will decrease as we generate values in the below loop. - uint256 bitsRemaining = 256; - - // Generate a random value and size for each variable. - uint256[] memory vals = new uint256[](nvars); - uint256[] memory sizes = new uint256[](nvars); - uint256[] memory offsets = new uint256[](nvars); - - for (uint256 i = 0; i < nvars; i++) { - // Generate a random value and size. - offsets[i] = i == 0 ? 0 : offsets[i - 1] + sizes[i - 1]; - - uint256 nvarsRemaining = nvars - i; - uint256 maxVarSize = bitsRemaining - nvarsRemaining + 1; - sizes[i] = bound(uint256(keccak256(abi.encodePacked(seed, i + 256))), 1, maxVarSize); - bitsRemaining -= sizes[i]; - - uint256 maxVal; - uint256 varSize = sizes[i]; - assembly { - // mask = (1 << varSize) - 1 - maxVal := sub(shl(varSize, 1), 1) - } - vals[i] = bound(uint256(keccak256(abi.encodePacked(seed, i))), 0, maxVal); - } - - // Pack all values into the slot. - for (uint256 i = 0; i < nvars; i++) { - stdstore.enable_packed_slots().target(address(test)).sig("getRandomPacked(uint256,uint256)").with_key( - sizes[i] - ).with_key(offsets[i]).checked_write(vals[i]); - } - - // Verify the read data matches. - for (uint256 i = 0; i < nvars; i++) { - uint256 readVal = stdstore.enable_packed_slots().target(address(test)).sig( - "getRandomPacked(uint256,uint256)" - ).with_key(sizes[i]).with_key(offsets[i]).read_uint(); - - uint256 retVal = test.getRandomPacked(sizes[i], offsets[i]); - - assertEq(readVal, vals[i]); - assertEq(retVal, vals[i]); - } - } - - function testEdgeCaseArray() public { - stdstore.target(address(test)).sig("edgeCaseArray(uint256)").with_key(uint256(0)).checked_write(1); - assertEq(test.edgeCaseArray(0), 1); - } -} - -contract StorageTest { - uint256 public exists = 1; - mapping(address => uint256) public map_addr; - mapping(uint256 => uint256) public map_uint; - mapping(address => uint256) public map_packed; - mapping(address => UnpackedStruct) public map_struct; - mapping(address => mapping(address => uint256)) public deep_map; - mapping(address => mapping(address => UnpackedStruct)) public deep_map_struct; - UnpackedStruct public basic; - - uint248 public tA; - bool public tB; - - bool public tC = false; - uint248 public tD = 1; - - struct UnpackedStruct { - uint256 a; - uint256 b; - } - - mapping(address => bool) public map_bool; - - bytes32 public tE = hex"1337"; - address public tF = address(1337); - int256 public tG = type(int256).min; - bool public tH = true; - bytes32 private tI = ~bytes32(hex"1337"); - - uint256 randomPacking; - - // Array with length matching values of elements. - uint256[] public edgeCaseArray = [3, 3, 3]; - - constructor() { - basic = UnpackedStruct({a: 1337, b: 1337}); - - uint256 two = (1 << 128) | 1; - map_packed[msg.sender] = two; - map_packed[address(uint160(1337))] = 1 << 128; - } - - function read_struct_upper(address who) public view returns (uint256) { - return map_packed[who] >> 128; - } - - function read_struct_lower(address who) public view returns (uint256) { - return map_packed[who] & ((1 << 128) - 1); - } - - function hidden() public view returns (bytes32 t) { - bytes32 slot = keccak256("my.random.var"); - /// @solidity memory-safe-assembly - assembly { - t := sload(slot) - } - } - - function const() public pure returns (bytes32 t) { - t = bytes32(hex"1337"); - } - - function extra_sload() public view returns (bytes32 t) { - // trigger read on slot `tE`, and make a staticcall to make sure compiler doesn't optimize this SLOAD away - assembly { - pop(staticcall(gas(), sload(tE.slot), 0, 0, 0, 0)) - } - t = tI; - } - - function setRandomPacking(uint256 val) public { - randomPacking = val; - } - - function _getMask(uint256 size) internal pure returns (uint256 mask) { - assembly { - // mask = (1 << size) - 1 - mask := sub(shl(size, 1), 1) - } - } - - function setRandomPacking(uint256 val, uint256 size, uint256 offset) public { - // Generate mask based on the size of the value - uint256 mask = _getMask(size); - // Zero out all bits for the word we're about to set - uint256 cleanedWord = randomPacking & ~(mask << offset); - // Place val in the correct spot of the cleaned word - randomPacking = cleanedWord | val << offset; - } - - function getRandomPacked(uint256 size, uint256 offset) public view returns (uint256) { - // Generate mask based on the size of the value - uint256 mask = _getMask(size); - // Shift to place the bits in the correct position, and use mask to zero out remaining bits - return (randomPacking >> offset) & mask; - } - - function getRandomPacked(uint8 shifts, uint8[] memory shiftSizes, uint8 elem) public view returns (uint256) { - require(elem < shifts, "!elem"); - uint256 leftBits; - uint256 rightBits; - - for (uint256 i; i < shiftSizes.length; i++) { - if (i < elem) { - leftBits += shiftSizes[i]; - } else if (elem != i) { - rightBits += shiftSizes[i]; - } - } - - // we may have some right bits unaccounted for - leftBits += 256 - (leftBits + shiftSizes[elem] + rightBits); - - // clear left bits, then clear right bits and realign - return (randomPacking << leftBits) >> (leftBits + rightBits); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdStyle.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdStyle.t.sol deleted file mode 100644 index 974e756fe5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdStyle.t.sol +++ /dev/null @@ -1,110 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {Test, console2, StdStyle} from "../src/Test.sol"; - -contract StdStyleTest is Test { - function test_StyleColor() public pure { - console2.log(StdStyle.red("StdStyle.red String Test")); - console2.log(StdStyle.red(uint256(10e18))); - console2.log(StdStyle.red(int256(-10e18))); - console2.log(StdStyle.red(true)); - console2.log(StdStyle.red(address(0))); - console2.log(StdStyle.redBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.redBytes32("StdStyle.redBytes32")); - console2.log(StdStyle.green("StdStyle.green String Test")); - console2.log(StdStyle.green(uint256(10e18))); - console2.log(StdStyle.green(int256(-10e18))); - console2.log(StdStyle.green(true)); - console2.log(StdStyle.green(address(0))); - console2.log(StdStyle.greenBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.greenBytes32("StdStyle.greenBytes32")); - console2.log(StdStyle.yellow("StdStyle.yellow String Test")); - console2.log(StdStyle.yellow(uint256(10e18))); - console2.log(StdStyle.yellow(int256(-10e18))); - console2.log(StdStyle.yellow(true)); - console2.log(StdStyle.yellow(address(0))); - console2.log(StdStyle.yellowBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.yellowBytes32("StdStyle.yellowBytes32")); - console2.log(StdStyle.blue("StdStyle.blue String Test")); - console2.log(StdStyle.blue(uint256(10e18))); - console2.log(StdStyle.blue(int256(-10e18))); - console2.log(StdStyle.blue(true)); - console2.log(StdStyle.blue(address(0))); - console2.log(StdStyle.blueBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.blueBytes32("StdStyle.blueBytes32")); - console2.log(StdStyle.magenta("StdStyle.magenta String Test")); - console2.log(StdStyle.magenta(uint256(10e18))); - console2.log(StdStyle.magenta(int256(-10e18))); - console2.log(StdStyle.magenta(true)); - console2.log(StdStyle.magenta(address(0))); - console2.log(StdStyle.magentaBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.magentaBytes32("StdStyle.magentaBytes32")); - console2.log(StdStyle.cyan("StdStyle.cyan String Test")); - console2.log(StdStyle.cyan(uint256(10e18))); - console2.log(StdStyle.cyan(int256(-10e18))); - console2.log(StdStyle.cyan(true)); - console2.log(StdStyle.cyan(address(0))); - console2.log(StdStyle.cyanBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.cyanBytes32("StdStyle.cyanBytes32")); - } - - function test_StyleFontWeight() public pure { - console2.log(StdStyle.bold("StdStyle.bold String Test")); - console2.log(StdStyle.bold(uint256(10e18))); - console2.log(StdStyle.bold(int256(-10e18))); - console2.log(StdStyle.bold(address(0))); - console2.log(StdStyle.bold(true)); - console2.log(StdStyle.boldBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.boldBytes32("StdStyle.boldBytes32")); - console2.log(StdStyle.dim("StdStyle.dim String Test")); - console2.log(StdStyle.dim(uint256(10e18))); - console2.log(StdStyle.dim(int256(-10e18))); - console2.log(StdStyle.dim(address(0))); - console2.log(StdStyle.dim(true)); - console2.log(StdStyle.dimBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.dimBytes32("StdStyle.dimBytes32")); - console2.log(StdStyle.italic("StdStyle.italic String Test")); - console2.log(StdStyle.italic(uint256(10e18))); - console2.log(StdStyle.italic(int256(-10e18))); - console2.log(StdStyle.italic(address(0))); - console2.log(StdStyle.italic(true)); - console2.log(StdStyle.italicBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.italicBytes32("StdStyle.italicBytes32")); - console2.log(StdStyle.underline("StdStyle.underline String Test")); - console2.log(StdStyle.underline(uint256(10e18))); - console2.log(StdStyle.underline(int256(-10e18))); - console2.log(StdStyle.underline(address(0))); - console2.log(StdStyle.underline(true)); - console2.log(StdStyle.underlineBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.underlineBytes32("StdStyle.underlineBytes32")); - console2.log(StdStyle.inverse("StdStyle.inverse String Test")); - console2.log(StdStyle.inverse(uint256(10e18))); - console2.log(StdStyle.inverse(int256(-10e18))); - console2.log(StdStyle.inverse(address(0))); - console2.log(StdStyle.inverse(true)); - console2.log(StdStyle.inverseBytes(hex"7109709ECfa91a80626fF3989D68f67F5b1DD12D")); - console2.log(StdStyle.inverseBytes32("StdStyle.inverseBytes32")); - } - - function test_StyleCombined() public pure { - console2.log(StdStyle.red(StdStyle.bold("Red Bold String Test"))); - console2.log(StdStyle.green(StdStyle.dim(uint256(10e18)))); - console2.log(StdStyle.yellow(StdStyle.italic(int256(-10e18)))); - console2.log(StdStyle.blue(StdStyle.underline(address(0)))); - console2.log(StdStyle.magenta(StdStyle.inverse(true))); - } - - function test_StyleCustom() public pure { - console2.log(h1("Custom Style 1")); - console2.log(h2("Custom Style 2")); - } - - function h1(string memory a) private pure returns (string memory) { - return StdStyle.cyan(StdStyle.inverse(StdStyle.bold(a))); - } - - function h2(string memory a) private pure returns (string memory) { - return StdStyle.magenta(StdStyle.bold(StdStyle.underline(a))); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdToml.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdToml.t.sol deleted file mode 100644 index 5a45f4f5c9..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdToml.t.sol +++ /dev/null @@ -1,49 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {Test, stdToml} from "../src/Test.sol"; - -contract StdTomlTest is Test { - using stdToml for string; - - string root; - string path; - - function setUp() public { - root = vm.projectRoot(); - path = string.concat(root, "/test/fixtures/test.toml"); - } - - struct SimpleToml { - uint256 a; - string b; - } - - struct NestedToml { - uint256 a; - string b; - SimpleToml c; - } - - function test_readToml() public view { - string memory json = vm.readFile(path); - assertEq(json.readUint(".a"), 123); - } - - function test_writeToml() public { - string memory json = "json"; - json.serialize("a", uint256(123)); - string memory semiFinal = json.serialize("b", string("test")); - string memory finalJson = json.serialize("c", semiFinal); - finalJson.write(path); - - string memory toml = vm.readFile(path); - bytes memory data = toml.parseRaw("$"); - NestedToml memory decodedData = abi.decode(data, (NestedToml)); - - assertEq(decodedData.a, 123); - assertEq(decodedData.b, "test"); - assertEq(decodedData.c.a, 123); - assertEq(decodedData.c.b, "test"); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdUtils.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdUtils.t.sol deleted file mode 100644 index aee801b2cf..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/StdUtils.t.sol +++ /dev/null @@ -1,342 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {Test, StdUtils} from "../src/Test.sol"; - -contract StdUtilsMock is StdUtils { - // We deploy a mock version so we can properly test expected reverts. - function exposed_getTokenBalances(address token, address[] memory addresses) - external - returns (uint256[] memory balances) - { - return getTokenBalances(token, addresses); - } - - function exposed_bound(int256 num, int256 min, int256 max) external pure returns (int256) { - return bound(num, min, max); - } - - function exposed_bound(uint256 num, uint256 min, uint256 max) external pure returns (uint256) { - return bound(num, min, max); - } - - function exposed_bytesToUint(bytes memory b) external pure returns (uint256) { - return bytesToUint(b); - } -} - -contract StdUtilsTest is Test { - /*////////////////////////////////////////////////////////////////////////// - BOUND UINT - //////////////////////////////////////////////////////////////////////////*/ - - function test_Bound() public pure { - assertEq(bound(uint256(5), 0, 4), 0); - assertEq(bound(uint256(0), 69, 69), 69); - assertEq(bound(uint256(0), 68, 69), 68); - assertEq(bound(uint256(10), 150, 190), 174); - assertEq(bound(uint256(300), 2800, 3200), 3107); - assertEq(bound(uint256(9999), 1337, 6666), 4669); - } - - function test_Bound_WithinRange() public pure { - assertEq(bound(uint256(51), 50, 150), 51); - assertEq(bound(uint256(51), 50, 150), bound(bound(uint256(51), 50, 150), 50, 150)); - assertEq(bound(uint256(149), 50, 150), 149); - assertEq(bound(uint256(149), 50, 150), bound(bound(uint256(149), 50, 150), 50, 150)); - } - - function test_Bound_EdgeCoverage() public pure { - assertEq(bound(uint256(0), 50, 150), 50); - assertEq(bound(uint256(1), 50, 150), 51); - assertEq(bound(uint256(2), 50, 150), 52); - assertEq(bound(uint256(3), 50, 150), 53); - assertEq(bound(type(uint256).max, 50, 150), 150); - assertEq(bound(type(uint256).max - 1, 50, 150), 149); - assertEq(bound(type(uint256).max - 2, 50, 150), 148); - assertEq(bound(type(uint256).max - 3, 50, 150), 147); - } - - function testFuzz_Bound_DistributionIsEven(uint256 min, uint256 size) public pure { - size = size % 100 + 1; - min = bound(min, UINT256_MAX / 2, UINT256_MAX / 2 + size); - uint256 max = min + size - 1; - uint256 result; - - for (uint256 i = 1; i <= size * 4; ++i) { - // x > max - result = bound(max + i, min, max); - assertEq(result, min + (i - 1) % size); - // x < min - result = bound(min - i, min, max); - assertEq(result, max - (i - 1) % size); - } - } - - function testFuzz_Bound(uint256 num, uint256 min, uint256 max) public pure { - if (min > max) (min, max) = (max, min); - - uint256 result = bound(num, min, max); - - assertGe(result, min); - assertLe(result, max); - assertEq(result, bound(result, min, max)); - if (num >= min && num <= max) assertEq(result, num); - } - - function test_BoundUint256Max() public pure { - assertEq(bound(0, type(uint256).max - 1, type(uint256).max), type(uint256).max - 1); - assertEq(bound(1, type(uint256).max - 1, type(uint256).max), type(uint256).max); - } - - function test_RevertIf_BoundMaxLessThanMin() public { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - vm.expectRevert(bytes("StdUtils bound(uint256,uint256,uint256): Max is less than min.")); - stdUtils.exposed_bound(uint256(5), 100, 10); - } - - function testFuzz_RevertIf_BoundMaxLessThanMin(uint256 num, uint256 min, uint256 max) public { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - vm.assume(min > max); - vm.expectRevert(bytes("StdUtils bound(uint256,uint256,uint256): Max is less than min.")); - stdUtils.exposed_bound(num, min, max); - } - - /*////////////////////////////////////////////////////////////////////////// - BOUND INT - //////////////////////////////////////////////////////////////////////////*/ - - function test_BoundInt() public pure { - assertEq(bound(-3, 0, 4), 2); - assertEq(bound(0, -69, -69), -69); - assertEq(bound(0, -69, -68), -68); - assertEq(bound(-10, 150, 190), 154); - assertEq(bound(-300, 2800, 3200), 2908); - assertEq(bound(9999, -1337, 6666), 1995); - } - - function test_BoundInt_WithinRange() public pure { - assertEq(bound(51, -50, 150), 51); - assertEq(bound(51, -50, 150), bound(bound(51, -50, 150), -50, 150)); - assertEq(bound(149, -50, 150), 149); - assertEq(bound(149, -50, 150), bound(bound(149, -50, 150), -50, 150)); - } - - function test_BoundInt_EdgeCoverage() public pure { - assertEq(bound(type(int256).min, -50, 150), -50); - assertEq(bound(type(int256).min + 1, -50, 150), -49); - assertEq(bound(type(int256).min + 2, -50, 150), -48); - assertEq(bound(type(int256).min + 3, -50, 150), -47); - assertEq(bound(type(int256).min, 10, 150), 10); - assertEq(bound(type(int256).min + 1, 10, 150), 11); - assertEq(bound(type(int256).min + 2, 10, 150), 12); - assertEq(bound(type(int256).min + 3, 10, 150), 13); - - assertEq(bound(type(int256).max, -50, 150), 150); - assertEq(bound(type(int256).max - 1, -50, 150), 149); - assertEq(bound(type(int256).max - 2, -50, 150), 148); - assertEq(bound(type(int256).max - 3, -50, 150), 147); - assertEq(bound(type(int256).max, -50, -10), -10); - assertEq(bound(type(int256).max - 1, -50, -10), -11); - assertEq(bound(type(int256).max - 2, -50, -10), -12); - assertEq(bound(type(int256).max - 3, -50, -10), -13); - } - - function testFuzz_BoundInt_DistributionIsEven(int256 min, uint256 size) public pure { - size = size % 100 + 1; - min = bound(min, -int256(size / 2), int256(size - size / 2)); - int256 max = min + int256(size) - 1; - int256 result; - - for (uint256 i = 1; i <= size * 4; ++i) { - // x > max - result = bound(max + int256(i), min, max); - assertEq(result, min + int256((i - 1) % size)); - // x < min - result = bound(min - int256(i), min, max); - assertEq(result, max - int256((i - 1) % size)); - } - } - - function testFuzz_BoundInt(int256 num, int256 min, int256 max) public pure { - if (min > max) (min, max) = (max, min); - - int256 result = bound(num, min, max); - - assertGe(result, min); - assertLe(result, max); - assertEq(result, bound(result, min, max)); - if (num >= min && num <= max) assertEq(result, num); - } - - function test_BoundIntInt256Max() public pure { - assertEq(bound(0, type(int256).max - 1, type(int256).max), type(int256).max - 1); - assertEq(bound(1, type(int256).max - 1, type(int256).max), type(int256).max); - } - - function test_BoundIntInt256Min() public pure { - assertEq(bound(0, type(int256).min, type(int256).min + 1), type(int256).min); - assertEq(bound(1, type(int256).min, type(int256).min + 1), type(int256).min + 1); - } - - function test_RevertIf_BoundIntMaxLessThanMin() public { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - vm.expectRevert(bytes("StdUtils bound(int256,int256,int256): Max is less than min.")); - stdUtils.exposed_bound(-5, 100, 10); - } - - function testFuzz_RevertIf_BoundIntMaxLessThanMin(int256 num, int256 min, int256 max) public { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - vm.assume(min > max); - vm.expectRevert(bytes("StdUtils bound(int256,int256,int256): Max is less than min.")); - stdUtils.exposed_bound(num, min, max); - } - - /*////////////////////////////////////////////////////////////////////////// - BOUND PRIVATE KEY - //////////////////////////////////////////////////////////////////////////*/ - - function test_BoundPrivateKey() public pure { - assertEq(boundPrivateKey(0), 1); - assertEq(boundPrivateKey(1), 1); - assertEq(boundPrivateKey(300), 300); - assertEq(boundPrivateKey(9999), 9999); - assertEq(boundPrivateKey(SECP256K1_ORDER - 1), SECP256K1_ORDER - 1); - assertEq(boundPrivateKey(SECP256K1_ORDER), 1); - assertEq(boundPrivateKey(SECP256K1_ORDER + 1), 2); - assertEq(boundPrivateKey(UINT256_MAX), UINT256_MAX & SECP256K1_ORDER - 1); // x&y is equivalent to x-x%y - } - - /*////////////////////////////////////////////////////////////////////////// - BYTES TO UINT - //////////////////////////////////////////////////////////////////////////*/ - - function test_BytesToUint() external pure { - bytes memory maxUint = hex"ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"; - bytes memory two = hex"02"; - bytes memory millionEther = hex"d3c21bcecceda1000000"; - - assertEq(bytesToUint(maxUint), type(uint256).max); - assertEq(bytesToUint(two), 2); - assertEq(bytesToUint(millionEther), 1_000_000 ether); - } - - function test_RevertIf_BytesLengthExceeds32() external { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - bytes memory thirty3Bytes = hex"ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"; - vm.expectRevert("StdUtils bytesToUint(bytes): Bytes length exceeds 32."); - stdUtils.exposed_bytesToUint(thirty3Bytes); - } - - /*////////////////////////////////////////////////////////////////////////// - COMPUTE CREATE ADDRESS - //////////////////////////////////////////////////////////////////////////*/ - - function test_ComputeCreateAddress() external pure { - address deployer = 0x6C9FC64A53c1b71FB3f9Af64d1ae3A4931A5f4E9; - uint256 nonce = 14; - address createAddress = computeCreateAddress(deployer, nonce); - assertEq(createAddress, 0x68b3465833fb72A70ecDF485E0e4C7bD8665Fc45); - } - - /*////////////////////////////////////////////////////////////////////////// - COMPUTE CREATE2 ADDRESS - //////////////////////////////////////////////////////////////////////////*/ - - function test_ComputeCreate2Address() external pure { - bytes32 salt = bytes32(uint256(31415)); - bytes32 initcodeHash = keccak256(abi.encode(0x6080)); - address deployer = 0x6C9FC64A53c1b71FB3f9Af64d1ae3A4931A5f4E9; - address create2Address = computeCreate2Address(salt, initcodeHash, deployer); - assertEq(create2Address, 0xB147a5d25748fda14b463EB04B111027C290f4d3); - } - - function test_ComputeCreate2AddressWithDefaultDeployer() external pure { - bytes32 salt = 0xc290c670fde54e5ef686f9132cbc8711e76a98f0333a438a92daa442c71403c0; - bytes32 initcodeHash = hashInitCode(hex"6080", ""); - assertEq(initcodeHash, 0x1a578b7a4b0b5755db6d121b4118d4bc68fe170dca840c59bc922f14175a76b0); - address create2Address = computeCreate2Address(salt, initcodeHash); - assertEq(create2Address, 0xc0ffEe2198a06235aAbFffe5Db0CacF1717f5Ac6); - } -} - -contract StdUtilsForkTest is Test { - /*////////////////////////////////////////////////////////////////////////// - GET TOKEN BALANCES - //////////////////////////////////////////////////////////////////////////*/ - - address internal SHIB = 0x95aD61b0a150d79219dCF64E1E6Cc01f0B64C4cE; - address internal SHIB_HOLDER_0 = 0x855F5981e831D83e6A4b4EBFCAdAa68D92333170; - address internal SHIB_HOLDER_1 = 0x8F509A90c2e47779cA408Fe00d7A72e359229AdA; - address internal SHIB_HOLDER_2 = 0x0e3bbc0D04fF62211F71f3e4C45d82ad76224385; - - address internal USDC = 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48; - address internal USDC_HOLDER_0 = 0xDa9CE944a37d218c3302F6B82a094844C6ECEb17; - address internal USDC_HOLDER_1 = 0x3e67F4721E6d1c41a015f645eFa37BEd854fcf52; - - function setUp() public { - // All tests of the `getTokenBalances` method are fork tests using live contracts. - vm.createSelectFork({urlOrAlias: "mainnet", blockNumber: 16_428_900}); - } - - function test_RevertIf_CannotGetTokenBalances_NonTokenContract() external { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - // The UniswapV2Factory contract has neither a `balanceOf` function nor a fallback function, - // so the `balanceOf` call should revert. - address token = address(0x5C69bEe701ef814a2B6a3EDD4B1652CB9cc5aA6f); - address[] memory addresses = new address[](1); - addresses[0] = USDC_HOLDER_0; - - vm.expectRevert("Multicall3: call failed"); - stdUtils.exposed_getTokenBalances(token, addresses); - } - - function test_RevertIf_CannotGetTokenBalances_EOA() external { - // We deploy a mock version so we can properly test the revert. - StdUtilsMock stdUtils = new StdUtilsMock(); - - address eoa = vm.addr({privateKey: 1}); - address[] memory addresses = new address[](1); - addresses[0] = USDC_HOLDER_0; - vm.expectRevert("StdUtils getTokenBalances(address,address[]): Token address is not a contract."); - stdUtils.exposed_getTokenBalances(eoa, addresses); - } - - function test_GetTokenBalances_Empty() external { - address[] memory addresses = new address[](0); - uint256[] memory balances = getTokenBalances(USDC, addresses); - assertEq(balances.length, 0); - } - - function test_GetTokenBalances_USDC() external { - address[] memory addresses = new address[](2); - addresses[0] = USDC_HOLDER_0; - addresses[1] = USDC_HOLDER_1; - uint256[] memory balances = getTokenBalances(USDC, addresses); - assertEq(balances[0], 159_000_000_000_000); - assertEq(balances[1], 131_350_000_000_000); - } - - function test_GetTokenBalances_SHIB() external { - address[] memory addresses = new address[](3); - addresses[0] = SHIB_HOLDER_0; - addresses[1] = SHIB_HOLDER_1; - addresses[2] = SHIB_HOLDER_2; - uint256[] memory balances = getTokenBalances(SHIB, addresses); - assertEq(balances[0], 3_323_256_285_484.42e18); - assertEq(balances[1], 1_271_702_771_149.99999928e18); - assertEq(balances[2], 606_357_106_247e18); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/Vm.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/Vm.t.sol deleted file mode 100644 index 7135409db8..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/Vm.t.sol +++ /dev/null @@ -1,18 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.8.0 <0.9.0; - -import {Test} from "../src/Test.sol"; -import {Vm, VmSafe} from "../src/Vm.sol"; - -// These tests ensure that functions are never accidentally removed from a Vm interface, or -// inadvertently moved between Vm and VmSafe. These tests must be updated each time a function is -// added to or removed from Vm or VmSafe. -contract VmTest is Test { - function test_VmInterfaceId() public pure { - assertEq(type(Vm).interfaceId, bytes4(0xa561dbe8), "Vm"); - } - - function test_VmSafeInterfaceId() public pure { - assertEq(type(VmSafe).interfaceId, bytes4(0x681d10d4), "VmSafe"); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/compilation/CompilationScript.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/compilation/CompilationScript.sol deleted file mode 100644 index e205cfff3c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/compilation/CompilationScript.sol +++ /dev/null @@ -1,10 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -import "../../src/Script.sol"; - -// The purpose of this contract is to benchmark compilation time to avoid accidentally introducing -// a change that results in very long compilation times with via-ir. See https://github.com/foundry-rs/forge-std/issues/207 -contract CompilationScript is Script {} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/compilation/CompilationScriptBase.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/compilation/CompilationScriptBase.sol deleted file mode 100644 index ce8e0e9545..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/compilation/CompilationScriptBase.sol +++ /dev/null @@ -1,10 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -import "../../src/Script.sol"; - -// The purpose of this contract is to benchmark compilation time to avoid accidentally introducing -// a change that results in very long compilation times with via-ir. See https://github.com/foundry-rs/forge-std/issues/207 -contract CompilationScriptBase is ScriptBase {} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/compilation/CompilationTest.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/compilation/CompilationTest.sol deleted file mode 100644 index 9beeafeb7d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/compilation/CompilationTest.sol +++ /dev/null @@ -1,10 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -import "../../src/Test.sol"; - -// The purpose of this contract is to benchmark compilation time to avoid accidentally introducing -// a change that results in very long compilation times with via-ir. See https://github.com/foundry-rs/forge-std/issues/207 -contract CompilationTest is Test {} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/compilation/CompilationTestBase.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/compilation/CompilationTestBase.sol deleted file mode 100644 index e993535bc0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/compilation/CompilationTestBase.sol +++ /dev/null @@ -1,10 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.6.2 <0.9.0; - -pragma experimental ABIEncoderV2; - -import "../../src/Test.sol"; - -// The purpose of this contract is to benchmark compilation time to avoid accidentally introducing -// a change that results in very long compilation times with via-ir. See https://github.com/foundry-rs/forge-std/issues/207 -contract CompilationTestBase is TestBase {} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/fixtures/broadcast.log.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/fixtures/broadcast.log.json deleted file mode 100644 index 0a0200bca9..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/fixtures/broadcast.log.json +++ /dev/null @@ -1,187 +0,0 @@ -{ - "transactions": [ - { - "hash": "0xc6006863c267735a11476b7f15b15bc718e117e2da114a2be815dd651e1a509f", - "type": "CALL", - "contractName": "Test", - "contractAddress": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "function": "multiple_arguments(uint256,address,uint256[]):(uint256)", - "arguments": ["1", "0000000000000000000000000000000000001337", "[3,4]"], - "tx": { - "type": "0x02", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "gas": "0x73b9", - "value": "0x0", - "data": "0x23e99187000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000013370000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000000004", - "nonce": "0x3", - "accessList": [] - } - }, - { - "hash": "0xedf2b38d8d896519a947a1acf720f859bb35c0c5ecb8dd7511995b67b9853298", - "type": "CALL", - "contractName": "Test", - "contractAddress": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "function": "inc():(uint256)", - "arguments": [], - "tx": { - "type": "0x02", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "gas": "0xdcb2", - "value": "0x0", - "data": "0x371303c0", - "nonce": "0x4", - "accessList": [] - } - }, - { - "hash": "0xa57e8e3981a6c861442e46c9471bd19cb3e21f9a8a6c63a72e7b5c47c6675a7c", - "type": "CALL", - "contractName": "Test", - "contractAddress": "0x7c6b4bbe207d642d98d5c537142d85209e585087", - "function": "t(uint256):(uint256)", - "arguments": ["1"], - "tx": { - "type": "0x02", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0x7c6b4bbe207d642d98d5c537142d85209e585087", - "gas": "0x8599", - "value": "0x0", - "data": "0xafe29f710000000000000000000000000000000000000000000000000000000000000001", - "nonce": "0x5", - "accessList": [] - } - } - ], - "receipts": [ - { - "transactionHash": "0x481dc86e40bba90403c76f8e144aa9ff04c1da2164299d0298573835f0991181", - "transactionIndex": "0x0", - "blockHash": "0xef0730448490304e5403be0fa8f8ce64f118e9adcca60c07a2ae1ab921d748af", - "blockNumber": "0x1", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": null, - "cumulativeGasUsed": "0x13f3a", - "gasUsed": "0x13f3a", - "contractAddress": "0x5fbdb2315678afecb367f032d93f642f64180aa3", - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0x6a187183545b8a9e7f1790e847139379bf5622baff2cb43acf3f5c79470af782", - "transactionIndex": "0x0", - "blockHash": "0xf3acb96a90071640c2a8c067ae4e16aad87e634ea8d8bbbb5b352fba86ba0148", - "blockNumber": "0x2", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": null, - "cumulativeGasUsed": "0x45d80", - "gasUsed": "0x45d80", - "contractAddress": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0x064ad173b4867bdef2fb60060bbdaf01735fbf10414541ea857772974e74ea9d", - "transactionIndex": "0x0", - "blockHash": "0x8373d02109d3ee06a0225f23da4c161c656ccc48fe0fcee931d325508ae73e58", - "blockNumber": "0x3", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0x4e59b44847b379578588920ca78fbf26c0b4956c", - "cumulativeGasUsed": "0x45feb", - "gasUsed": "0x45feb", - "contractAddress": null, - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0xc6006863c267735a11476b7f15b15bc718e117e2da114a2be815dd651e1a509f", - "transactionIndex": "0x0", - "blockHash": "0x16712fae5c0e18f75045f84363fb6b4d9a9fe25e660c4ce286833a533c97f629", - "blockNumber": "0x4", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "cumulativeGasUsed": "0x5905", - "gasUsed": "0x5905", - "contractAddress": null, - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0xedf2b38d8d896519a947a1acf720f859bb35c0c5ecb8dd7511995b67b9853298", - "transactionIndex": "0x0", - "blockHash": "0x156b88c3eb9a1244ba00a1834f3f70de735b39e3e59006dd03af4fe7d5480c11", - "blockNumber": "0x5", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512", - "cumulativeGasUsed": "0xa9c4", - "gasUsed": "0xa9c4", - "contractAddress": null, - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0xa57e8e3981a6c861442e46c9471bd19cb3e21f9a8a6c63a72e7b5c47c6675a7c", - "transactionIndex": "0x0", - "blockHash": "0xcf61faca67dbb2c28952b0b8a379e53b1505ae0821e84779679390cb8571cadb", - "blockNumber": "0x6", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0x7c6b4bbe207d642d98d5c537142d85209e585087", - "cumulativeGasUsed": "0x66c5", - "gasUsed": "0x66c5", - "contractAddress": null, - "logs": [ - { - "address": "0x7c6b4bbe207d642d98d5c537142d85209e585087", - "topics": [ - "0x0b2e13ff20ac7b474198655583edf70dedd2c1dc980e329c4fbb2fc0748b796b" - ], - "data": "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000046865726500000000000000000000000000000000000000000000000000000000", - "blockHash": "0xcf61faca67dbb2c28952b0b8a379e53b1505ae0821e84779679390cb8571cadb", - "blockNumber": "0x6", - "transactionHash": "0xa57e8e3981a6c861442e46c9471bd19cb3e21f9a8a6c63a72e7b5c47c6675a7c", - "transactionIndex": "0x1", - "logIndex": "0x0", - "transactionLogIndex": "0x0", - "removed": false - } - ], - "status": "0x1", - "logsBloom": "0x00000000000800000000000000000010000000000000000000000000000180000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100", - "effectiveGasPrice": "0xee6b2800" - }, - { - "transactionHash": "0x11fbb10230c168ca1e36a7e5c69a6dbcd04fd9e64ede39d10a83e36ee8065c16", - "transactionIndex": "0x0", - "blockHash": "0xf1e0ed2eda4e923626ec74621006ed50b3fc27580dc7b4cf68a07ca77420e29c", - "blockNumber": "0x7", - "from": "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266", - "to": "0x0000000000000000000000000000000000001337", - "cumulativeGasUsed": "0x5208", - "gasUsed": "0x5208", - "contractAddress": null, - "logs": [], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0xee6b2800" - } - ], - "libraries": [ - "src/Broadcast.t.sol:F:0x5fbdb2315678afecb367f032d93f642f64180aa3" - ], - "pending": [], - "path": "broadcast/Broadcast.t.sol/31337/run-latest.json", - "returns": {}, - "timestamp": 1655140035 -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/fixtures/test.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/fixtures/test.json deleted file mode 100644 index caebf6d965..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/fixtures/test.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "a": 123, - "b": "test", - "c": { - "a": 123, - "b": "test" - } -} \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/fixtures/test.toml b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/fixtures/test.toml deleted file mode 100644 index 60692bc750..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/fixtures/test.toml +++ /dev/null @@ -1,6 +0,0 @@ -a = 123 -b = "test" - -[c] -a = 123 -b = "test" diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/mocks/MockERC20.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/mocks/MockERC20.t.sol deleted file mode 100644 index e246810930..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/mocks/MockERC20.t.sol +++ /dev/null @@ -1,441 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {MockERC20} from "../../src/mocks/MockERC20.sol"; -import {StdCheats} from "../../src/StdCheats.sol"; -import {Test} from "../../src/Test.sol"; - -contract Token_ERC20 is MockERC20 { - constructor(string memory name, string memory symbol, uint8 decimals) { - initialize(name, symbol, decimals); - } - - function mint(address to, uint256 value) public virtual { - _mint(to, value); - } - - function burn(address from, uint256 value) public virtual { - _burn(from, value); - } -} - -contract MockERC20Test is StdCheats, Test { - Token_ERC20 token; - - bytes32 constant PERMIT_TYPEHASH = - keccak256("Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)"); - - function setUp() public { - token = new Token_ERC20("Token", "TKN", 18); - } - - function invariantMetadata() public view { - assertEq(token.name(), "Token"); - assertEq(token.symbol(), "TKN"); - assertEq(token.decimals(), 18); - } - - function testMint() public { - token.mint(address(0xBEEF), 1e18); - - assertEq(token.totalSupply(), 1e18); - assertEq(token.balanceOf(address(0xBEEF)), 1e18); - } - - function testBurn() public { - token.mint(address(0xBEEF), 1e18); - token.burn(address(0xBEEF), 0.9e18); - - assertEq(token.totalSupply(), 1e18 - 0.9e18); - assertEq(token.balanceOf(address(0xBEEF)), 0.1e18); - } - - function testApprove() public { - assertTrue(token.approve(address(0xBEEF), 1e18)); - - assertEq(token.allowance(address(this), address(0xBEEF)), 1e18); - } - - function testTransfer() public { - token.mint(address(this), 1e18); - - assertTrue(token.transfer(address(0xBEEF), 1e18)); - assertEq(token.totalSupply(), 1e18); - - assertEq(token.balanceOf(address(this)), 0); - assertEq(token.balanceOf(address(0xBEEF)), 1e18); - } - - function testTransferFrom() public { - address from = address(0xABCD); - - token.mint(from, 1e18); - - vm.prank(from); - token.approve(address(this), 1e18); - - assertTrue(token.transferFrom(from, address(0xBEEF), 1e18)); - assertEq(token.totalSupply(), 1e18); - - assertEq(token.allowance(from, address(this)), 0); - - assertEq(token.balanceOf(from), 0); - assertEq(token.balanceOf(address(0xBEEF)), 1e18); - } - - function testInfiniteApproveTransferFrom() public { - address from = address(0xABCD); - - token.mint(from, 1e18); - - vm.prank(from); - token.approve(address(this), type(uint256).max); - - assertTrue(token.transferFrom(from, address(0xBEEF), 1e18)); - assertEq(token.totalSupply(), 1e18); - - assertEq(token.allowance(from, address(this)), type(uint256).max); - - assertEq(token.balanceOf(from), 0); - assertEq(token.balanceOf(address(0xBEEF)), 1e18); - } - - function testPermit() public { - uint256 privateKey = 0xBEEF; - address owner = vm.addr(privateKey); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - privateKey, - keccak256( - abi.encodePacked( - "\x19\x01", - token.DOMAIN_SEPARATOR(), - keccak256(abi.encode(PERMIT_TYPEHASH, owner, address(0xCAFE), 1e18, 0, block.timestamp)) - ) - ) - ); - - token.permit(owner, address(0xCAFE), 1e18, block.timestamp, v, r, s); - - assertEq(token.allowance(owner, address(0xCAFE)), 1e18); - assertEq(token.nonces(owner), 1); - } - - function testFailTransferInsufficientBalance() public { - token.mint(address(this), 0.9e18); - token.transfer(address(0xBEEF), 1e18); - } - - function testFailTransferFromInsufficientAllowance() public { - address from = address(0xABCD); - - token.mint(from, 1e18); - - vm.prank(from); - token.approve(address(this), 0.9e18); - - token.transferFrom(from, address(0xBEEF), 1e18); - } - - function testFailTransferFromInsufficientBalance() public { - address from = address(0xABCD); - - token.mint(from, 0.9e18); - - vm.prank(from); - token.approve(address(this), 1e18); - - token.transferFrom(from, address(0xBEEF), 1e18); - } - - function testFailPermitBadNonce() public { - uint256 privateKey = 0xBEEF; - address owner = vm.addr(privateKey); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - privateKey, - keccak256( - abi.encodePacked( - "\x19\x01", - token.DOMAIN_SEPARATOR(), - keccak256(abi.encode(PERMIT_TYPEHASH, owner, address(0xCAFE), 1e18, 1, block.timestamp)) - ) - ) - ); - - token.permit(owner, address(0xCAFE), 1e18, block.timestamp, v, r, s); - } - - function testFailPermitBadDeadline() public { - uint256 privateKey = 0xBEEF; - address owner = vm.addr(privateKey); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - privateKey, - keccak256( - abi.encodePacked( - "\x19\x01", - token.DOMAIN_SEPARATOR(), - keccak256(abi.encode(PERMIT_TYPEHASH, owner, address(0xCAFE), 1e18, 0, block.timestamp)) - ) - ) - ); - - token.permit(owner, address(0xCAFE), 1e18, block.timestamp + 1, v, r, s); - } - - function testFailPermitPastDeadline() public { - uint256 oldTimestamp = block.timestamp; - uint256 privateKey = 0xBEEF; - address owner = vm.addr(privateKey); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - privateKey, - keccak256( - abi.encodePacked( - "\x19\x01", - token.DOMAIN_SEPARATOR(), - keccak256(abi.encode(PERMIT_TYPEHASH, owner, address(0xCAFE), 1e18, 0, oldTimestamp)) - ) - ) - ); - - vm.warp(block.timestamp + 1); - token.permit(owner, address(0xCAFE), 1e18, oldTimestamp, v, r, s); - } - - function testFailPermitReplay() public { - uint256 privateKey = 0xBEEF; - address owner = vm.addr(privateKey); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - privateKey, - keccak256( - abi.encodePacked( - "\x19\x01", - token.DOMAIN_SEPARATOR(), - keccak256(abi.encode(PERMIT_TYPEHASH, owner, address(0xCAFE), 1e18, 0, block.timestamp)) - ) - ) - ); - - token.permit(owner, address(0xCAFE), 1e18, block.timestamp, v, r, s); - token.permit(owner, address(0xCAFE), 1e18, block.timestamp, v, r, s); - } - - function testMetadata(string calldata name, string calldata symbol, uint8 decimals) public { - Token_ERC20 tkn = new Token_ERC20(name, symbol, decimals); - assertEq(tkn.name(), name); - assertEq(tkn.symbol(), symbol); - assertEq(tkn.decimals(), decimals); - } - - function testMint(address from, uint256 amount) public { - token.mint(from, amount); - - assertEq(token.totalSupply(), amount); - assertEq(token.balanceOf(from), amount); - } - - function testBurn(address from, uint256 mintAmount, uint256 burnAmount) public { - burnAmount = bound(burnAmount, 0, mintAmount); - - token.mint(from, mintAmount); - token.burn(from, burnAmount); - - assertEq(token.totalSupply(), mintAmount - burnAmount); - assertEq(token.balanceOf(from), mintAmount - burnAmount); - } - - function testApprove(address to, uint256 amount) public { - assertTrue(token.approve(to, amount)); - - assertEq(token.allowance(address(this), to), amount); - } - - function testTransfer(address from, uint256 amount) public { - token.mint(address(this), amount); - - assertTrue(token.transfer(from, amount)); - assertEq(token.totalSupply(), amount); - - if (address(this) == from) { - assertEq(token.balanceOf(address(this)), amount); - } else { - assertEq(token.balanceOf(address(this)), 0); - assertEq(token.balanceOf(from), amount); - } - } - - function testTransferFrom(address to, uint256 approval, uint256 amount) public { - amount = bound(amount, 0, approval); - - address from = address(0xABCD); - - token.mint(from, amount); - - vm.prank(from); - token.approve(address(this), approval); - - assertTrue(token.transferFrom(from, to, amount)); - assertEq(token.totalSupply(), amount); - - uint256 app = from == address(this) || approval == type(uint256).max ? approval : approval - amount; - assertEq(token.allowance(from, address(this)), app); - - if (from == to) { - assertEq(token.balanceOf(from), amount); - } else { - assertEq(token.balanceOf(from), 0); - assertEq(token.balanceOf(to), amount); - } - } - - function testPermit(uint248 privKey, address to, uint256 amount, uint256 deadline) public { - uint256 privateKey = privKey; - if (deadline < block.timestamp) deadline = block.timestamp; - if (privateKey == 0) privateKey = 1; - - address owner = vm.addr(privateKey); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - privateKey, - keccak256( - abi.encodePacked( - "\x19\x01", - token.DOMAIN_SEPARATOR(), - keccak256(abi.encode(PERMIT_TYPEHASH, owner, to, amount, 0, deadline)) - ) - ) - ); - - token.permit(owner, to, amount, deadline, v, r, s); - - assertEq(token.allowance(owner, to), amount); - assertEq(token.nonces(owner), 1); - } - - function testFailBurnInsufficientBalance(address to, uint256 mintAmount, uint256 burnAmount) public { - burnAmount = bound(burnAmount, mintAmount + 1, type(uint256).max); - - token.mint(to, mintAmount); - token.burn(to, burnAmount); - } - - function testFailTransferInsufficientBalance(address to, uint256 mintAmount, uint256 sendAmount) public { - sendAmount = bound(sendAmount, mintAmount + 1, type(uint256).max); - - token.mint(address(this), mintAmount); - token.transfer(to, sendAmount); - } - - function testFailTransferFromInsufficientAllowance(address to, uint256 approval, uint256 amount) public { - amount = bound(amount, approval + 1, type(uint256).max); - - address from = address(0xABCD); - - token.mint(from, amount); - - vm.prank(from); - token.approve(address(this), approval); - - token.transferFrom(from, to, amount); - } - - function testFailTransferFromInsufficientBalance(address to, uint256 mintAmount, uint256 sendAmount) public { - sendAmount = bound(sendAmount, mintAmount + 1, type(uint256).max); - - address from = address(0xABCD); - - token.mint(from, mintAmount); - - vm.prank(from); - token.approve(address(this), sendAmount); - - token.transferFrom(from, to, sendAmount); - } - - function testFailPermitBadNonce(uint256 privateKey, address to, uint256 amount, uint256 deadline, uint256 nonce) - public - { - if (deadline < block.timestamp) deadline = block.timestamp; - if (privateKey == 0) privateKey = 1; - if (nonce == 0) nonce = 1; - - address owner = vm.addr(privateKey); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - privateKey, - keccak256( - abi.encodePacked( - "\x19\x01", - token.DOMAIN_SEPARATOR(), - keccak256(abi.encode(PERMIT_TYPEHASH, owner, to, amount, nonce, deadline)) - ) - ) - ); - - token.permit(owner, to, amount, deadline, v, r, s); - } - - function testFailPermitBadDeadline(uint256 privateKey, address to, uint256 amount, uint256 deadline) public { - if (deadline < block.timestamp) deadline = block.timestamp; - if (privateKey == 0) privateKey = 1; - - address owner = vm.addr(privateKey); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - privateKey, - keccak256( - abi.encodePacked( - "\x19\x01", - token.DOMAIN_SEPARATOR(), - keccak256(abi.encode(PERMIT_TYPEHASH, owner, to, amount, 0, deadline)) - ) - ) - ); - - token.permit(owner, to, amount, deadline + 1, v, r, s); - } - - function testFailPermitPastDeadline(uint256 privateKey, address to, uint256 amount, uint256 deadline) public { - deadline = bound(deadline, 0, block.timestamp - 1); - if (privateKey == 0) privateKey = 1; - - address owner = vm.addr(privateKey); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - privateKey, - keccak256( - abi.encodePacked( - "\x19\x01", - token.DOMAIN_SEPARATOR(), - keccak256(abi.encode(PERMIT_TYPEHASH, owner, to, amount, 0, deadline)) - ) - ) - ); - - token.permit(owner, to, amount, deadline, v, r, s); - } - - function testFailPermitReplay(uint256 privateKey, address to, uint256 amount, uint256 deadline) public { - if (deadline < block.timestamp) deadline = block.timestamp; - if (privateKey == 0) privateKey = 1; - - address owner = vm.addr(privateKey); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - privateKey, - keccak256( - abi.encodePacked( - "\x19\x01", - token.DOMAIN_SEPARATOR(), - keccak256(abi.encode(PERMIT_TYPEHASH, owner, to, amount, 0, deadline)) - ) - ) - ); - - token.permit(owner, to, amount, deadline, v, r, s); - token.permit(owner, to, amount, deadline, v, r, s); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/mocks/MockERC721.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/mocks/MockERC721.t.sol deleted file mode 100644 index f986d79675..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/forge-std/test/mocks/MockERC721.t.sol +++ /dev/null @@ -1,721 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity >=0.7.0 <0.9.0; - -import {MockERC721, IERC721TokenReceiver} from "../../src/mocks/MockERC721.sol"; -import {StdCheats} from "../../src/StdCheats.sol"; -import {Test} from "../../src/Test.sol"; - -contract ERC721Recipient is IERC721TokenReceiver { - address public operator; - address public from; - uint256 public id; - bytes public data; - - function onERC721Received(address _operator, address _from, uint256 _id, bytes calldata _data) - public - virtual - override - returns (bytes4) - { - operator = _operator; - from = _from; - id = _id; - data = _data; - - return IERC721TokenReceiver.onERC721Received.selector; - } -} - -contract RevertingERC721Recipient is IERC721TokenReceiver { - function onERC721Received(address, address, uint256, bytes calldata) public virtual override returns (bytes4) { - revert(string(abi.encodePacked(IERC721TokenReceiver.onERC721Received.selector))); - } -} - -contract WrongReturnDataERC721Recipient is IERC721TokenReceiver { - function onERC721Received(address, address, uint256, bytes calldata) public virtual override returns (bytes4) { - return 0xCAFEBEEF; - } -} - -contract NonERC721Recipient {} - -contract Token_ERC721 is MockERC721 { - constructor(string memory _name, string memory _symbol) { - initialize(_name, _symbol); - } - - function tokenURI(uint256) public pure virtual override returns (string memory) {} - - function mint(address to, uint256 tokenId) public virtual { - _mint(to, tokenId); - } - - function burn(uint256 tokenId) public virtual { - _burn(tokenId); - } - - function safeMint(address to, uint256 tokenId) public virtual { - _safeMint(to, tokenId); - } - - function safeMint(address to, uint256 tokenId, bytes memory data) public virtual { - _safeMint(to, tokenId, data); - } -} - -contract MockERC721Test is StdCheats, Test { - Token_ERC721 token; - - function setUp() public { - token = new Token_ERC721("Token", "TKN"); - } - - function invariantMetadata() public view { - assertEq(token.name(), "Token"); - assertEq(token.symbol(), "TKN"); - } - - function testMint() public { - token.mint(address(0xBEEF), 1337); - - assertEq(token.balanceOf(address(0xBEEF)), 1); - assertEq(token.ownerOf(1337), address(0xBEEF)); - } - - function testBurn() public { - token.mint(address(0xBEEF), 1337); - token.burn(1337); - - assertEq(token.balanceOf(address(0xBEEF)), 0); - - vm.expectRevert("NOT_MINTED"); - token.ownerOf(1337); - } - - function testApprove() public { - token.mint(address(this), 1337); - - token.approve(address(0xBEEF), 1337); - - assertEq(token.getApproved(1337), address(0xBEEF)); - } - - function testApproveBurn() public { - token.mint(address(this), 1337); - - token.approve(address(0xBEEF), 1337); - - token.burn(1337); - - assertEq(token.balanceOf(address(this)), 0); - assertEq(token.getApproved(1337), address(0)); - - vm.expectRevert("NOT_MINTED"); - token.ownerOf(1337); - } - - function testApproveAll() public { - token.setApprovalForAll(address(0xBEEF), true); - - assertTrue(token.isApprovedForAll(address(this), address(0xBEEF))); - } - - function testTransferFrom() public { - address from = address(0xABCD); - - token.mint(from, 1337); - - vm.prank(from); - token.approve(address(this), 1337); - - token.transferFrom(from, address(0xBEEF), 1337); - - assertEq(token.getApproved(1337), address(0)); - assertEq(token.ownerOf(1337), address(0xBEEF)); - assertEq(token.balanceOf(address(0xBEEF)), 1); - assertEq(token.balanceOf(from), 0); - } - - function testTransferFromSelf() public { - token.mint(address(this), 1337); - - token.transferFrom(address(this), address(0xBEEF), 1337); - - assertEq(token.getApproved(1337), address(0)); - assertEq(token.ownerOf(1337), address(0xBEEF)); - assertEq(token.balanceOf(address(0xBEEF)), 1); - assertEq(token.balanceOf(address(this)), 0); - } - - function testTransferFromApproveAll() public { - address from = address(0xABCD); - - token.mint(from, 1337); - - vm.prank(from); - token.setApprovalForAll(address(this), true); - - token.transferFrom(from, address(0xBEEF), 1337); - - assertEq(token.getApproved(1337), address(0)); - assertEq(token.ownerOf(1337), address(0xBEEF)); - assertEq(token.balanceOf(address(0xBEEF)), 1); - assertEq(token.balanceOf(from), 0); - } - - function testSafeTransferFromToEOA() public { - address from = address(0xABCD); - - token.mint(from, 1337); - - vm.prank(from); - token.setApprovalForAll(address(this), true); - - token.safeTransferFrom(from, address(0xBEEF), 1337); - - assertEq(token.getApproved(1337), address(0)); - assertEq(token.ownerOf(1337), address(0xBEEF)); - assertEq(token.balanceOf(address(0xBEEF)), 1); - assertEq(token.balanceOf(from), 0); - } - - function testSafeTransferFromToERC721Recipient() public { - address from = address(0xABCD); - ERC721Recipient recipient = new ERC721Recipient(); - - token.mint(from, 1337); - - vm.prank(from); - token.setApprovalForAll(address(this), true); - - token.safeTransferFrom(from, address(recipient), 1337); - - assertEq(token.getApproved(1337), address(0)); - assertEq(token.ownerOf(1337), address(recipient)); - assertEq(token.balanceOf(address(recipient)), 1); - assertEq(token.balanceOf(from), 0); - - assertEq(recipient.operator(), address(this)); - assertEq(recipient.from(), from); - assertEq(recipient.id(), 1337); - assertEq(recipient.data(), ""); - } - - function testSafeTransferFromToERC721RecipientWithData() public { - address from = address(0xABCD); - ERC721Recipient recipient = new ERC721Recipient(); - - token.mint(from, 1337); - - vm.prank(from); - token.setApprovalForAll(address(this), true); - - token.safeTransferFrom(from, address(recipient), 1337, "testing 123"); - - assertEq(token.getApproved(1337), address(0)); - assertEq(token.ownerOf(1337), address(recipient)); - assertEq(token.balanceOf(address(recipient)), 1); - assertEq(token.balanceOf(from), 0); - - assertEq(recipient.operator(), address(this)); - assertEq(recipient.from(), from); - assertEq(recipient.id(), 1337); - assertEq(recipient.data(), "testing 123"); - } - - function testSafeMintToEOA() public { - token.safeMint(address(0xBEEF), 1337); - - assertEq(token.ownerOf(1337), address(address(0xBEEF))); - assertEq(token.balanceOf(address(address(0xBEEF))), 1); - } - - function testSafeMintToERC721Recipient() public { - ERC721Recipient to = new ERC721Recipient(); - - token.safeMint(address(to), 1337); - - assertEq(token.ownerOf(1337), address(to)); - assertEq(token.balanceOf(address(to)), 1); - - assertEq(to.operator(), address(this)); - assertEq(to.from(), address(0)); - assertEq(to.id(), 1337); - assertEq(to.data(), ""); - } - - function testSafeMintToERC721RecipientWithData() public { - ERC721Recipient to = new ERC721Recipient(); - - token.safeMint(address(to), 1337, "testing 123"); - - assertEq(token.ownerOf(1337), address(to)); - assertEq(token.balanceOf(address(to)), 1); - - assertEq(to.operator(), address(this)); - assertEq(to.from(), address(0)); - assertEq(to.id(), 1337); - assertEq(to.data(), "testing 123"); - } - - function testFailMintToZero() public { - token.mint(address(0), 1337); - } - - function testFailDoubleMint() public { - token.mint(address(0xBEEF), 1337); - token.mint(address(0xBEEF), 1337); - } - - function testFailBurnUnMinted() public { - token.burn(1337); - } - - function testFailDoubleBurn() public { - token.mint(address(0xBEEF), 1337); - - token.burn(1337); - token.burn(1337); - } - - function testFailApproveUnMinted() public { - token.approve(address(0xBEEF), 1337); - } - - function testFailApproveUnAuthorized() public { - token.mint(address(0xCAFE), 1337); - - token.approve(address(0xBEEF), 1337); - } - - function testFailTransferFromUnOwned() public { - token.transferFrom(address(0xFEED), address(0xBEEF), 1337); - } - - function testFailTransferFromWrongFrom() public { - token.mint(address(0xCAFE), 1337); - - token.transferFrom(address(0xFEED), address(0xBEEF), 1337); - } - - function testFailTransferFromToZero() public { - token.mint(address(this), 1337); - - token.transferFrom(address(this), address(0), 1337); - } - - function testFailTransferFromNotOwner() public { - token.mint(address(0xFEED), 1337); - - token.transferFrom(address(0xFEED), address(0xBEEF), 1337); - } - - function testFailSafeTransferFromToNonERC721Recipient() public { - token.mint(address(this), 1337); - - token.safeTransferFrom(address(this), address(new NonERC721Recipient()), 1337); - } - - function testFailSafeTransferFromToNonERC721RecipientWithData() public { - token.mint(address(this), 1337); - - token.safeTransferFrom(address(this), address(new NonERC721Recipient()), 1337, "testing 123"); - } - - function testFailSafeTransferFromToRevertingERC721Recipient() public { - token.mint(address(this), 1337); - - token.safeTransferFrom(address(this), address(new RevertingERC721Recipient()), 1337); - } - - function testFailSafeTransferFromToRevertingERC721RecipientWithData() public { - token.mint(address(this), 1337); - - token.safeTransferFrom(address(this), address(new RevertingERC721Recipient()), 1337, "testing 123"); - } - - function testFailSafeTransferFromToERC721RecipientWithWrongReturnData() public { - token.mint(address(this), 1337); - - token.safeTransferFrom(address(this), address(new WrongReturnDataERC721Recipient()), 1337); - } - - function testFailSafeTransferFromToERC721RecipientWithWrongReturnDataWithData() public { - token.mint(address(this), 1337); - - token.safeTransferFrom(address(this), address(new WrongReturnDataERC721Recipient()), 1337, "testing 123"); - } - - function testFailSafeMintToNonERC721Recipient() public { - token.safeMint(address(new NonERC721Recipient()), 1337); - } - - function testFailSafeMintToNonERC721RecipientWithData() public { - token.safeMint(address(new NonERC721Recipient()), 1337, "testing 123"); - } - - function testFailSafeMintToRevertingERC721Recipient() public { - token.safeMint(address(new RevertingERC721Recipient()), 1337); - } - - function testFailSafeMintToRevertingERC721RecipientWithData() public { - token.safeMint(address(new RevertingERC721Recipient()), 1337, "testing 123"); - } - - function testFailSafeMintToERC721RecipientWithWrongReturnData() public { - token.safeMint(address(new WrongReturnDataERC721Recipient()), 1337); - } - - function testFailSafeMintToERC721RecipientWithWrongReturnDataWithData() public { - token.safeMint(address(new WrongReturnDataERC721Recipient()), 1337, "testing 123"); - } - - function testFailBalanceOfZeroAddress() public view { - token.balanceOf(address(0)); - } - - function testFailOwnerOfUnminted() public view { - token.ownerOf(1337); - } - - function testMetadata(string memory name, string memory symbol) public { - MockERC721 tkn = new Token_ERC721(name, symbol); - - assertEq(tkn.name(), name); - assertEq(tkn.symbol(), symbol); - } - - function testMint(address to, uint256 id) public { - if (to == address(0)) to = address(0xBEEF); - - token.mint(to, id); - - assertEq(token.balanceOf(to), 1); - assertEq(token.ownerOf(id), to); - } - - function testBurn(address to, uint256 id) public { - if (to == address(0)) to = address(0xBEEF); - - token.mint(to, id); - token.burn(id); - - assertEq(token.balanceOf(to), 0); - - vm.expectRevert("NOT_MINTED"); - token.ownerOf(id); - } - - function testApprove(address to, uint256 id) public { - if (to == address(0)) to = address(0xBEEF); - - token.mint(address(this), id); - - token.approve(to, id); - - assertEq(token.getApproved(id), to); - } - - function testApproveBurn(address to, uint256 id) public { - token.mint(address(this), id); - - token.approve(address(to), id); - - token.burn(id); - - assertEq(token.balanceOf(address(this)), 0); - assertEq(token.getApproved(id), address(0)); - - vm.expectRevert("NOT_MINTED"); - token.ownerOf(id); - } - - function testApproveAll(address to, bool approved) public { - token.setApprovalForAll(to, approved); - - assertEq(token.isApprovedForAll(address(this), to), approved); - } - - function testTransferFrom(uint256 id, address to) public { - address from = address(0xABCD); - - if (to == address(0) || to == from) to = address(0xBEEF); - - token.mint(from, id); - - vm.prank(from); - token.approve(address(this), id); - - token.transferFrom(from, to, id); - - assertEq(token.getApproved(id), address(0)); - assertEq(token.ownerOf(id), to); - assertEq(token.balanceOf(to), 1); - assertEq(token.balanceOf(from), 0); - } - - function testTransferFromSelf(uint256 id, address to) public { - if (to == address(0) || to == address(this)) to = address(0xBEEF); - - token.mint(address(this), id); - - token.transferFrom(address(this), to, id); - - assertEq(token.getApproved(id), address(0)); - assertEq(token.ownerOf(id), to); - assertEq(token.balanceOf(to), 1); - assertEq(token.balanceOf(address(this)), 0); - } - - function testTransferFromApproveAll(uint256 id, address to) public { - address from = address(0xABCD); - - if (to == address(0) || to == from) to = address(0xBEEF); - - token.mint(from, id); - - vm.prank(from); - token.setApprovalForAll(address(this), true); - - token.transferFrom(from, to, id); - - assertEq(token.getApproved(id), address(0)); - assertEq(token.ownerOf(id), to); - assertEq(token.balanceOf(to), 1); - assertEq(token.balanceOf(from), 0); - } - - function testSafeTransferFromToEOA(uint256 id, address to) public { - address from = address(0xABCD); - - if (to == address(0) || to == from) to = address(0xBEEF); - - if (uint256(uint160(to)) <= 18 || to.code.length > 0) return; - - token.mint(from, id); - - vm.prank(from); - token.setApprovalForAll(address(this), true); - - token.safeTransferFrom(from, to, id); - - assertEq(token.getApproved(id), address(0)); - assertEq(token.ownerOf(id), to); - assertEq(token.balanceOf(to), 1); - assertEq(token.balanceOf(from), 0); - } - - function testSafeTransferFromToERC721Recipient(uint256 id) public { - address from = address(0xABCD); - - ERC721Recipient recipient = new ERC721Recipient(); - - token.mint(from, id); - - vm.prank(from); - token.setApprovalForAll(address(this), true); - - token.safeTransferFrom(from, address(recipient), id); - - assertEq(token.getApproved(id), address(0)); - assertEq(token.ownerOf(id), address(recipient)); - assertEq(token.balanceOf(address(recipient)), 1); - assertEq(token.balanceOf(from), 0); - - assertEq(recipient.operator(), address(this)); - assertEq(recipient.from(), from); - assertEq(recipient.id(), id); - assertEq(recipient.data(), ""); - } - - function testSafeTransferFromToERC721RecipientWithData(uint256 id, bytes calldata data) public { - address from = address(0xABCD); - ERC721Recipient recipient = new ERC721Recipient(); - - token.mint(from, id); - - vm.prank(from); - token.setApprovalForAll(address(this), true); - - token.safeTransferFrom(from, address(recipient), id, data); - - assertEq(token.getApproved(id), address(0)); - assertEq(token.ownerOf(id), address(recipient)); - assertEq(token.balanceOf(address(recipient)), 1); - assertEq(token.balanceOf(from), 0); - - assertEq(recipient.operator(), address(this)); - assertEq(recipient.from(), from); - assertEq(recipient.id(), id); - assertEq(recipient.data(), data); - } - - function testSafeMintToEOA(uint256 id, address to) public { - if (to == address(0)) to = address(0xBEEF); - - if (uint256(uint160(to)) <= 18 || to.code.length > 0) return; - - token.safeMint(to, id); - - assertEq(token.ownerOf(id), address(to)); - assertEq(token.balanceOf(address(to)), 1); - } - - function testSafeMintToERC721Recipient(uint256 id) public { - ERC721Recipient to = new ERC721Recipient(); - - token.safeMint(address(to), id); - - assertEq(token.ownerOf(id), address(to)); - assertEq(token.balanceOf(address(to)), 1); - - assertEq(to.operator(), address(this)); - assertEq(to.from(), address(0)); - assertEq(to.id(), id); - assertEq(to.data(), ""); - } - - function testSafeMintToERC721RecipientWithData(uint256 id, bytes calldata data) public { - ERC721Recipient to = new ERC721Recipient(); - - token.safeMint(address(to), id, data); - - assertEq(token.ownerOf(id), address(to)); - assertEq(token.balanceOf(address(to)), 1); - - assertEq(to.operator(), address(this)); - assertEq(to.from(), address(0)); - assertEq(to.id(), id); - assertEq(to.data(), data); - } - - function testFailMintToZero(uint256 id) public { - token.mint(address(0), id); - } - - function testFailDoubleMint(uint256 id, address to) public { - if (to == address(0)) to = address(0xBEEF); - - token.mint(to, id); - token.mint(to, id); - } - - function testFailBurnUnMinted(uint256 id) public { - token.burn(id); - } - - function testFailDoubleBurn(uint256 id, address to) public { - if (to == address(0)) to = address(0xBEEF); - - token.mint(to, id); - - token.burn(id); - token.burn(id); - } - - function testFailApproveUnMinted(uint256 id, address to) public { - token.approve(to, id); - } - - function testFailApproveUnAuthorized(address owner, uint256 id, address to) public { - if (owner == address(0) || owner == address(this)) owner = address(0xBEEF); - - token.mint(owner, id); - - token.approve(to, id); - } - - function testFailTransferFromUnOwned(address from, address to, uint256 id) public { - token.transferFrom(from, to, id); - } - - function testFailTransferFromWrongFrom(address owner, address from, address to, uint256 id) public { - if (owner == address(0)) to = address(0xBEEF); - if (from == owner) revert(); - - token.mint(owner, id); - - token.transferFrom(from, to, id); - } - - function testFailTransferFromToZero(uint256 id) public { - token.mint(address(this), id); - - token.transferFrom(address(this), address(0), id); - } - - function testFailTransferFromNotOwner(address from, address to, uint256 id) public { - if (from == address(this)) from = address(0xBEEF); - - token.mint(from, id); - - token.transferFrom(from, to, id); - } - - function testFailSafeTransferFromToNonERC721Recipient(uint256 id) public { - token.mint(address(this), id); - - token.safeTransferFrom(address(this), address(new NonERC721Recipient()), id); - } - - function testFailSafeTransferFromToNonERC721RecipientWithData(uint256 id, bytes calldata data) public { - token.mint(address(this), id); - - token.safeTransferFrom(address(this), address(new NonERC721Recipient()), id, data); - } - - function testFailSafeTransferFromToRevertingERC721Recipient(uint256 id) public { - token.mint(address(this), id); - - token.safeTransferFrom(address(this), address(new RevertingERC721Recipient()), id); - } - - function testFailSafeTransferFromToRevertingERC721RecipientWithData(uint256 id, bytes calldata data) public { - token.mint(address(this), id); - - token.safeTransferFrom(address(this), address(new RevertingERC721Recipient()), id, data); - } - - function testFailSafeTransferFromToERC721RecipientWithWrongReturnData(uint256 id) public { - token.mint(address(this), id); - - token.safeTransferFrom(address(this), address(new WrongReturnDataERC721Recipient()), id); - } - - function testFailSafeTransferFromToERC721RecipientWithWrongReturnDataWithData(uint256 id, bytes calldata data) - public - { - token.mint(address(this), id); - - token.safeTransferFrom(address(this), address(new WrongReturnDataERC721Recipient()), id, data); - } - - function testFailSafeMintToNonERC721Recipient(uint256 id) public { - token.safeMint(address(new NonERC721Recipient()), id); - } - - function testFailSafeMintToNonERC721RecipientWithData(uint256 id, bytes calldata data) public { - token.safeMint(address(new NonERC721Recipient()), id, data); - } - - function testFailSafeMintToRevertingERC721Recipient(uint256 id) public { - token.safeMint(address(new RevertingERC721Recipient()), id); - } - - function testFailSafeMintToRevertingERC721RecipientWithData(uint256 id, bytes calldata data) public { - token.safeMint(address(new RevertingERC721Recipient()), id, data); - } - - function testFailSafeMintToERC721RecipientWithWrongReturnData(uint256 id) public { - token.safeMint(address(new WrongReturnDataERC721Recipient()), id); - } - - function testFailSafeMintToERC721RecipientWithWrongReturnDataWithData(uint256 id, bytes calldata data) public { - token.safeMint(address(new WrongReturnDataERC721Recipient()), id, data); - } - - function testFailOwnerOfUnminted(uint256 id) public view { - token.ownerOf(id); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/LICENSE b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/LICENSE deleted file mode 100644 index 0ad25db4bd..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/LICENSE +++ /dev/null @@ -1,661 +0,0 @@ - GNU AFFERO GENERAL PUBLIC LICENSE - Version 3, 19 November 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU Affero General Public License is a free, copyleft license for -software and other kinds of works, specifically designed to ensure -cooperation with the community in the case of network server software. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -our General Public Licenses are intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - Developers that use our General Public Licenses protect your rights -with two steps: (1) assert copyright on the software, and (2) offer -you this License which gives you legal permission to copy, distribute -and/or modify the software. - - A secondary benefit of defending all users' freedom is that -improvements made in alternate versions of the program, if they -receive widespread use, become available for other developers to -incorporate. Many developers of free software are heartened and -encouraged by the resulting cooperation. However, in the case of -software used on network servers, this result may fail to come about. -The GNU General Public License permits making a modified version and -letting the public access it on a server without ever releasing its -source code to the public. - - The GNU Affero General Public License is designed specifically to -ensure that, in such cases, the modified source code becomes available -to the community. It requires the operator of a network server to -provide the source code of the modified version running there to the -users of that server. Therefore, public use of a modified version, on -a publicly accessible server, gives the public access to the source -code of the modified version. - - An older license, called the Affero General Public License and -published by Affero, was designed to accomplish similar goals. This is -a different license, not a version of the Affero GPL, but Affero has -released a new version of the Affero GPL which permits relicensing under -this license. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU Affero General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Remote Network Interaction; Use with the GNU General Public License. - - Notwithstanding any other provision of this License, if you modify the -Program, your modified version must prominently offer all users -interacting with it remotely through a computer network (if your version -supports such interaction) an opportunity to receive the Corresponding -Source of your version by providing access to the Corresponding Source -from a network server at no charge, through some standard or customary -means of facilitating copying of software. This Corresponding Source -shall include the Corresponding Source for any work covered by version 3 -of the GNU General Public License that is incorporated pursuant to the -following paragraph. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the work with which it is combined will remain governed by version -3 of the GNU General Public License. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU Affero General Public License from time to time. Such new versions -will be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU Affero General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU Affero General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU Affero General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU Affero General Public License as published - by the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU Affero General Public License for more details. - - You should have received a copy of the GNU Affero General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If your software can interact with users remotely through a computer -network, you should also make sure that it provides a way for users to -get its source. For example, if your program is a web application, its -interface could display a "Source" link that leads users to an archive -of the code. There are many ways you could offer source, and different -solutions will be better for different programs; see section 13 for the -specific requirements. - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU AGPL, see -. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/README.md b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/README.md deleted file mode 100644 index 3b6912fc36..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/README.md +++ /dev/null @@ -1,100 +0,0 @@ -# Halmos Cheat Codes - -Halmos cheatcodes are abstract functions designed to facilitate writing symbolic tests, such as the creation of new symbolic values at runtime. While these cheatcodes are currently exclusive to [Halmos][halmos], they are not limited to it and could potentially be supported by other symbolic testing tools in the future. - -Please refer to [the list of currently available cheatcodes][list]. More cheatcodes will be added in the future. - -Join the [Halmos Telegram Group][chat] for any inquiries or further discussions. - -[halmos]: https://github.com/a16z/halmos -[list]: src/SVM.sol -[chat]: https://t.me/+4UhzHduai3MzZmUx - -## Installation - -To install using Foundry: - -``` -forge install a16z/halmos-cheatcodes -``` - -Alternatively, you can directly add it as a submodule: - -``` -git submodule add https://github.com/a16z/halmos-cheatcodes -``` - -## Example usage - -Below is an example of a symbolic test that checks for potential unauthorized access to others' tokens. The approach involves setting up an initial symbolic state of the token contract, executing an arbitrary function call to the token contract, and checking if there is an execution path that increases the caller's balance and/or decreases the balance of others. This example illustrates how to utilize cheatcodes to set up initial symbolic states and execute arbitrary function calls. - -```solidity -// import Halmos cheatcodes -import { SymTest } from 'halmos-cheatcodes/SymTest.sol'; - -import { Test } from 'forge-std/Test.sol'; - -import { Token } from '/path/to/Token.sol'; - -contract TokenTest is SymTest, Test { - Token token; - - function setUp() public { - token = new Token(); - - // set the balances of three arbitrary accounts to arbitrary symbolic values - for (uint256 i = 0; i < 3; i++) { - address receiver = svm.createAddress('receiver'); // create a new symbolic address - uint256 amount = svm.createUint256('amount'); // create a new symbolic uint256 value - token.transfer(receiver, amount); - } - } - - function checkBalanceUpdate() public { - // consider two arbitrary distinct accounts - address caller = svm.createAddress('caller'); // create a symbolic address - address others = svm.createAddress('others'); // create another symbolic address - vm.assume(others != caller); // assume the two addresses are different - - // record their current balances - uint256 oldBalanceCaller = token.balanceOf(caller); - uint256 oldBalanceOthers = token.balanceOf(others); - - // execute an arbitrary function call to the token from the caller - vm.prank(caller); - uint256 dataSize = 100; // the max calldata size for the public functions in the token - bytes memory data = svm.createBytes(dataSize, 'data'); // create a symbolic calldata - address(token).call(data); - - // ensure that the caller cannot spend others' tokens - assert(token.balanceOf(caller) <= oldBalanceCaller); // cannot increase their own balance - assert(token.balanceOf(others) >= oldBalanceOthers); // cannot decrease others' balance - } -} -``` - -When running the above test against the following buggy token contract, Halmos will provide a counterexample that may be overlooked during manual reviews. - -```solidity -/// @notice This is a buggy token contract. DO NOT use it in production. -contract Token { - mapping(address => uint) public balanceOf; - - constructor() public { - balanceOf[msg.sender] = 1e27; - } - - function transfer(address to, uint amount) public { - _transfer(msg.sender, to, amount); - } - - function _transfer(address from, address to, uint amount) public { - balanceOf[from] -= amount; - balanceOf[to] += amount; - } -} -``` - -## Disclaimer - -_These smart contracts and code are being provided as is. No guarantee, representation or warranty is being made, express or implied, as to the safety or correctness of the user interface or the smart contracts and code. They have not been audited and as such there can be no assurance they will work as intended, and users may experience delays, failures, errors, omissions or loss of transmitted information. THE SMART CONTRACTS AND CODE CONTAINED HEREIN ARE FURNISHED AS IS, WHERE IS, WITH ALL FAULTS AND WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING ANY WARRANTY OF MERCHANTABILITY, NON-INFRINGEMENT OR FITNESS FOR ANY PARTICULAR PURPOSE. Further, use of any of these smart contracts and code may be restricted or prohibited under applicable law, including securities laws, and it is therefore strongly advised for you to contact a reputable attorney in any jurisdiction where these smart contracts and code may be accessible for any questions or concerns with respect thereto. Further, no information provided in this repo should be construed as investment advice or legal advice for any particular facts or circumstances, and is not meant to replace competent counsel. a16z is not liable for any use of the foregoing, and users should proceed with caution and use at their own risk. See a16z.com/disclosures for more info._ diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/SVM.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/SVM.sol deleted file mode 100644 index e9ba3ea042..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/SVM.sol +++ /dev/null @@ -1,35 +0,0 @@ -// SPDX-License-Identifier: AGPL-3.0 -pragma solidity >=0.8.0 <0.9.0; - -/// @notice Symbolic Virtual Machine -interface SVM { - // Create a new symbolic uint value ranging over [0, 2**bitSize - 1] (inclusive) - function createUint(uint256 bitSize, string memory name) external pure returns (uint256 value); - - // Create a new symbolic uint256 value - function createUint256(string memory name) external pure returns (uint256 value); - - // Create a new symbolic signed int value - function createInt(uint256 bitSize, string memory name) external pure returns (int256 value); - - // Create a new symbolic int256 value - function createInt256(string memory name) external pure returns (int256 value); - - // Create a new symbolic byte array with the given byte size - function createBytes(uint256 byteSize, string memory name) external pure returns (bytes memory value); - - // Create a new symbolic string backed by a symbolic array with the given byte size - function createString(uint256 byteSize, string memory name) external pure returns (string memory value); - - // Create a new symbolic bytes32 value - function createBytes32(string memory name) external pure returns (bytes32 value); - - // Create a new symbolic bytes4 value - function createBytes4(string memory name) external pure returns (bytes4 value); - - // Create a new symbolic address value - function createAddress(string memory name) external pure returns (address value); - - // Create a new symbolic boolean value - function createBool(string memory name) external pure returns (bool value); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/SymTest.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/SymTest.sol deleted file mode 100644 index 96684ed87d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/SymTest.sol +++ /dev/null @@ -1,11 +0,0 @@ -// SPDX-License-Identifier: AGPL-3.0 -pragma solidity >=0.8.0 <0.9.0; - -import {SVM} from "./SVM.sol"; - -abstract contract SymTest { - // SVM cheat code address: 0xf3993a62377bcd56ae39d773740a5390411e8bc9 - address internal constant SVM_ADDRESS = address(uint160(uint256(keccak256("svm cheat code")))); - - SVM internal constant svm = SVM(SVM_ADDRESS); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/logo.svg b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/logo.svg deleted file mode 100644 index f1e14c2bb4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/logo.svg +++ /dev/null @@ -1,15 +0,0 @@ - - - - - - - - - - - - - - - diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/netlify.toml b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/netlify.toml deleted file mode 100644 index 0447f41ad4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/netlify.toml +++ /dev/null @@ -1,3 +0,0 @@ -[build] -command = "npm run docs" -publish = "build/site" diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/package-lock.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/package-lock.json deleted file mode 100644 index f27d006f87..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/package-lock.json +++ /dev/null @@ -1,11242 +0,0 @@ -{ - "name": "openzeppelin-solidity", - "version": "5.2.0", - "lockfileVersion": 3, - "requires": true, - "packages": { - "": { - "name": "openzeppelin-solidity", - "version": "5.2.0", - "license": "MIT", - "devDependencies": { - "@changesets/changelog-github": "^0.5.0", - "@changesets/cli": "^2.26.0", - "@changesets/pre": "^2.0.0", - "@changesets/read": "^0.6.0", - "@eslint/compat": "^1.2.1", - "@nomicfoundation/hardhat-chai-matchers": "^2.0.6", - "@nomicfoundation/hardhat-ethers": "^3.0.4", - "@nomicfoundation/hardhat-network-helpers": "^1.0.3", - "@openzeppelin/docs-utils": "^0.1.5", - "@openzeppelin/merkle-tree": "^1.0.7", - "@openzeppelin/upgrade-safe-transpiler": "^0.3.32", - "@openzeppelin/upgrades-core": "^1.20.6", - "chai": "^4.2.0", - "eslint": "^9.0.0", - "eslint-config-prettier": "^9.0.0", - "ethers": "^6.7.1", - "glob": "^11.0.0", - "globals": "^15.3.0", - "graphlib": "^2.1.8", - "hardhat": "^2.22.2", - "hardhat-exposed": "^0.3.15", - "hardhat-gas-reporter": "^2.0.0", - "hardhat-ignore-warnings": "^0.2.11", - "lodash.startcase": "^4.4.0", - "micromatch": "^4.0.2", - "p-limit": "^3.1.0", - "prettier": "^3.0.0", - "prettier-plugin-solidity": "^1.1.0", - "rimraf": "^6.0.0", - "semver": "^7.3.5", - "solhint": "^5.0.0", - "solhint-plugin-openzeppelin": "file:scripts/solhint-custom", - "solidity-ast": "^0.4.50", - "solidity-coverage": "^0.8.17", - "solidity-docgen": "^0.6.0-beta.29", - "undici": "^6.11.1", - "yargs": "^17.0.0" - } - }, - "node_modules/@aashutoshrathi/word-wrap": { - "version": "1.2.6", - "resolved": "https://registry.npmjs.org/@aashutoshrathi/word-wrap/-/word-wrap-1.2.6.tgz", - "integrity": "sha512-1Yjs2SvM8TflER/OD3cOjhWWOZb58A2t7wpE2S9XfBYTiIl+XFhQG2bjy4Pu1I+EAlCNUzRDYDdFwFYUKvXcIA==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/@adraffy/ens-normalize": { - "version": "1.9.2", - "resolved": "https://registry.npmjs.org/@adraffy/ens-normalize/-/ens-normalize-1.9.2.tgz", - "integrity": "sha512-0h+FrQDqe2Wn+IIGFkTCd4aAwTJ+7834Ek1COohCyV26AXhwQ7WQaz+4F/nLOeVl/3BtWHOHLPsq46V8YB46Eg==", - "dev": true - }, - "node_modules/@babel/code-frame": { - "version": "7.22.13", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.22.13.tgz", - "integrity": "sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==", - "dev": true, - "dependencies": { - "@babel/highlight": "^7.22.13", - "chalk": "^2.4.2" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/helper-validator-identifier": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz", - "integrity": "sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==", - "dev": true, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/highlight": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.22.20.tgz", - "integrity": "sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==", - "dev": true, - "dependencies": { - "@babel/helper-validator-identifier": "^7.22.20", - "chalk": "^2.4.2", - "js-tokens": "^4.0.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/runtime": { - "version": "7.22.15", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.22.15.tgz", - "integrity": "sha512-T0O+aa+4w0u06iNmapipJXMV4HoUir03hpx3/YqXXhu9xim3w+dVphjFWl1OH8NbZHw5Lbm9k45drDkgq2VNNA==", - "dev": true, - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@changesets/apply-release-plan": { - "version": "6.1.4", - "resolved": "https://registry.npmjs.org/@changesets/apply-release-plan/-/apply-release-plan-6.1.4.tgz", - "integrity": "sha512-FMpKF1fRlJyCZVYHr3CbinpZZ+6MwvOtWUuO8uo+svcATEoc1zRDcj23pAurJ2TZ/uVz1wFHH6K3NlACy0PLew==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/config": "^2.3.1", - "@changesets/get-version-range-type": "^0.3.2", - "@changesets/git": "^2.0.0", - "@changesets/types": "^5.2.1", - "@manypkg/get-packages": "^1.1.3", - "detect-indent": "^6.0.0", - "fs-extra": "^7.0.1", - "lodash.startcase": "^4.4.0", - "outdent": "^0.5.0", - "prettier": "^2.7.1", - "resolve-from": "^5.0.0", - "semver": "^7.5.3" - } - }, - "node_modules/@changesets/apply-release-plan/node_modules/prettier": { - "version": "2.8.8", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.8.tgz", - "integrity": "sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==", - "dev": true, - "bin": { - "prettier": "bin-prettier.js" - }, - "engines": { - "node": ">=10.13.0" - }, - "funding": { - "url": "https://github.com/prettier/prettier?sponsor=1" - } - }, - "node_modules/@changesets/assemble-release-plan": { - "version": "5.2.4", - "resolved": "https://registry.npmjs.org/@changesets/assemble-release-plan/-/assemble-release-plan-5.2.4.tgz", - "integrity": "sha512-xJkWX+1/CUaOUWTguXEbCDTyWJFECEhmdtbkjhn5GVBGxdP/JwaHBIU9sW3FR6gD07UwZ7ovpiPclQZs+j+mvg==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/errors": "^0.1.4", - "@changesets/get-dependents-graph": "^1.3.6", - "@changesets/types": "^5.2.1", - "@manypkg/get-packages": "^1.1.3", - "semver": "^7.5.3" - } - }, - "node_modules/@changesets/changelog-git": { - "version": "0.1.14", - "resolved": "https://registry.npmjs.org/@changesets/changelog-git/-/changelog-git-0.1.14.tgz", - "integrity": "sha512-+vRfnKtXVWsDDxGctOfzJsPhaCdXRYoe+KyWYoq5X/GqoISREiat0l3L8B0a453B2B4dfHGcZaGyowHbp9BSaA==", - "dev": true, - "dependencies": { - "@changesets/types": "^5.2.1" - } - }, - "node_modules/@changesets/changelog-github": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/@changesets/changelog-github/-/changelog-github-0.5.0.tgz", - "integrity": "sha512-zoeq2LJJVcPJcIotHRJEEA2qCqX0AQIeFE+L21L8sRLPVqDhSXY8ZWAt2sohtBpFZkBwu+LUwMSKRr2lMy3LJA==", - "dev": true, - "dependencies": { - "@changesets/get-github-info": "^0.6.0", - "@changesets/types": "^6.0.0", - "dotenv": "^8.1.0" - } - }, - "node_modules/@changesets/changelog-github/node_modules/@changesets/types": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/@changesets/types/-/types-6.0.0.tgz", - "integrity": "sha512-b1UkfNulgKoWfqyHtzKS5fOZYSJO+77adgL7DLRDr+/7jhChN+QcHnbjiQVOz/U+Ts3PGNySq7diAItzDgugfQ==", - "dev": true - }, - "node_modules/@changesets/cli": { - "version": "2.26.2", - "resolved": "https://registry.npmjs.org/@changesets/cli/-/cli-2.26.2.tgz", - "integrity": "sha512-dnWrJTmRR8bCHikJHl9b9HW3gXACCehz4OasrXpMp7sx97ECuBGGNjJhjPhdZNCvMy9mn4BWdplI323IbqsRig==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/apply-release-plan": "^6.1.4", - "@changesets/assemble-release-plan": "^5.2.4", - "@changesets/changelog-git": "^0.1.14", - "@changesets/config": "^2.3.1", - "@changesets/errors": "^0.1.4", - "@changesets/get-dependents-graph": "^1.3.6", - "@changesets/get-release-plan": "^3.0.17", - "@changesets/git": "^2.0.0", - "@changesets/logger": "^0.0.5", - "@changesets/pre": "^1.0.14", - "@changesets/read": "^0.5.9", - "@changesets/types": "^5.2.1", - "@changesets/write": "^0.2.3", - "@manypkg/get-packages": "^1.1.3", - "@types/is-ci": "^3.0.0", - "@types/semver": "^7.5.0", - "ansi-colors": "^4.1.3", - "chalk": "^2.1.0", - "enquirer": "^2.3.0", - "external-editor": "^3.1.0", - "fs-extra": "^7.0.1", - "human-id": "^1.0.2", - "is-ci": "^3.0.1", - "meow": "^6.0.0", - "outdent": "^0.5.0", - "p-limit": "^2.2.0", - "preferred-pm": "^3.0.0", - "resolve-from": "^5.0.0", - "semver": "^7.5.3", - "spawndamnit": "^2.0.0", - "term-size": "^2.1.0", - "tty-table": "^4.1.5" - }, - "bin": { - "changeset": "bin.js" - } - }, - "node_modules/@changesets/cli/node_modules/@changesets/pre": { - "version": "1.0.14", - "resolved": "https://registry.npmjs.org/@changesets/pre/-/pre-1.0.14.tgz", - "integrity": "sha512-dTsHmxQWEQekHYHbg+M1mDVYFvegDh9j/kySNuDKdylwfMEevTeDouR7IfHNyVodxZXu17sXoJuf2D0vi55FHQ==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/errors": "^0.1.4", - "@changesets/types": "^5.2.1", - "@manypkg/get-packages": "^1.1.3", - "fs-extra": "^7.0.1" - } - }, - "node_modules/@changesets/cli/node_modules/@changesets/read": { - "version": "0.5.9", - "resolved": "https://registry.npmjs.org/@changesets/read/-/read-0.5.9.tgz", - "integrity": "sha512-T8BJ6JS6j1gfO1HFq50kU3qawYxa4NTbI/ASNVVCBTsKquy2HYwM9r7ZnzkiMe8IEObAJtUVGSrePCOxAK2haQ==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/git": "^2.0.0", - "@changesets/logger": "^0.0.5", - "@changesets/parse": "^0.3.16", - "@changesets/types": "^5.2.1", - "chalk": "^2.1.0", - "fs-extra": "^7.0.1", - "p-filter": "^2.1.0" - } - }, - "node_modules/@changesets/cli/node_modules/p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", - "dev": true, - "dependencies": { - "p-try": "^2.0.0" - }, - "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/@changesets/config": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/@changesets/config/-/config-2.3.1.tgz", - "integrity": "sha512-PQXaJl82CfIXddUOppj4zWu+987GCw2M+eQcOepxN5s+kvnsZOwjEJO3DH9eVy+OP6Pg/KFEWdsECFEYTtbg6w==", - "dev": true, - "dependencies": { - "@changesets/errors": "^0.1.4", - "@changesets/get-dependents-graph": "^1.3.6", - "@changesets/logger": "^0.0.5", - "@changesets/types": "^5.2.1", - "@manypkg/get-packages": "^1.1.3", - "fs-extra": "^7.0.1", - "micromatch": "^4.0.2" - } - }, - "node_modules/@changesets/errors": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/@changesets/errors/-/errors-0.1.4.tgz", - "integrity": "sha512-HAcqPF7snsUJ/QzkWoKfRfXushHTu+K5KZLJWPb34s4eCZShIf8BFO3fwq6KU8+G7L5KdtN2BzQAXOSXEyiY9Q==", - "dev": true, - "dependencies": { - "extendable-error": "^0.1.5" - } - }, - "node_modules/@changesets/get-dependents-graph": { - "version": "1.3.6", - "resolved": "https://registry.npmjs.org/@changesets/get-dependents-graph/-/get-dependents-graph-1.3.6.tgz", - "integrity": "sha512-Q/sLgBANmkvUm09GgRsAvEtY3p1/5OCzgBE5vX3vgb5CvW0j7CEljocx5oPXeQSNph6FXulJlXV3Re/v3K3P3Q==", - "dev": true, - "dependencies": { - "@changesets/types": "^5.2.1", - "@manypkg/get-packages": "^1.1.3", - "chalk": "^2.1.0", - "fs-extra": "^7.0.1", - "semver": "^7.5.3" - } - }, - "node_modules/@changesets/get-github-info": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/@changesets/get-github-info/-/get-github-info-0.6.0.tgz", - "integrity": "sha512-v/TSnFVXI8vzX9/w3DU2Ol+UlTZcu3m0kXTjTT4KlAdwSvwutcByYwyYn9hwerPWfPkT2JfpoX0KgvCEi8Q/SA==", - "dev": true, - "dependencies": { - "dataloader": "^1.4.0", - "node-fetch": "^2.5.0" - } - }, - "node_modules/@changesets/get-release-plan": { - "version": "3.0.17", - "resolved": "https://registry.npmjs.org/@changesets/get-release-plan/-/get-release-plan-3.0.17.tgz", - "integrity": "sha512-6IwKTubNEgoOZwDontYc2x2cWXfr6IKxP3IhKeK+WjyD6y3M4Gl/jdQvBw+m/5zWILSOCAaGLu2ZF6Q+WiPniw==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/assemble-release-plan": "^5.2.4", - "@changesets/config": "^2.3.1", - "@changesets/pre": "^1.0.14", - "@changesets/read": "^0.5.9", - "@changesets/types": "^5.2.1", - "@manypkg/get-packages": "^1.1.3" - } - }, - "node_modules/@changesets/get-release-plan/node_modules/@changesets/pre": { - "version": "1.0.14", - "resolved": "https://registry.npmjs.org/@changesets/pre/-/pre-1.0.14.tgz", - "integrity": "sha512-dTsHmxQWEQekHYHbg+M1mDVYFvegDh9j/kySNuDKdylwfMEevTeDouR7IfHNyVodxZXu17sXoJuf2D0vi55FHQ==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/errors": "^0.1.4", - "@changesets/types": "^5.2.1", - "@manypkg/get-packages": "^1.1.3", - "fs-extra": "^7.0.1" - } - }, - "node_modules/@changesets/get-release-plan/node_modules/@changesets/read": { - "version": "0.5.9", - "resolved": "https://registry.npmjs.org/@changesets/read/-/read-0.5.9.tgz", - "integrity": "sha512-T8BJ6JS6j1gfO1HFq50kU3qawYxa4NTbI/ASNVVCBTsKquy2HYwM9r7ZnzkiMe8IEObAJtUVGSrePCOxAK2haQ==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/git": "^2.0.0", - "@changesets/logger": "^0.0.5", - "@changesets/parse": "^0.3.16", - "@changesets/types": "^5.2.1", - "chalk": "^2.1.0", - "fs-extra": "^7.0.1", - "p-filter": "^2.1.0" - } - }, - "node_modules/@changesets/get-version-range-type": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/@changesets/get-version-range-type/-/get-version-range-type-0.3.2.tgz", - "integrity": "sha512-SVqwYs5pULYjYT4op21F2pVbcrca4qA/bAA3FmFXKMN7Y+HcO8sbZUTx3TAy2VXulP2FACd1aC7f2nTuqSPbqg==", - "dev": true - }, - "node_modules/@changesets/git": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@changesets/git/-/git-2.0.0.tgz", - "integrity": "sha512-enUVEWbiqUTxqSnmesyJGWfzd51PY4H7mH9yUw0hPVpZBJ6tQZFMU3F3mT/t9OJ/GjyiM4770i+sehAn6ymx6A==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/errors": "^0.1.4", - "@changesets/types": "^5.2.1", - "@manypkg/get-packages": "^1.1.3", - "is-subdir": "^1.1.1", - "micromatch": "^4.0.2", - "spawndamnit": "^2.0.0" - } - }, - "node_modules/@changesets/logger": { - "version": "0.0.5", - "resolved": "https://registry.npmjs.org/@changesets/logger/-/logger-0.0.5.tgz", - "integrity": "sha512-gJyZHomu8nASHpaANzc6bkQMO9gU/ib20lqew1rVx753FOxffnCrJlGIeQVxNWCqM+o6OOleCo/ivL8UAO5iFw==", - "dev": true, - "dependencies": { - "chalk": "^2.1.0" - } - }, - "node_modules/@changesets/parse": { - "version": "0.3.16", - "resolved": "https://registry.npmjs.org/@changesets/parse/-/parse-0.3.16.tgz", - "integrity": "sha512-127JKNd167ayAuBjUggZBkmDS5fIKsthnr9jr6bdnuUljroiERW7FBTDNnNVyJ4l69PzR57pk6mXQdtJyBCJKg==", - "dev": true, - "dependencies": { - "@changesets/types": "^5.2.1", - "js-yaml": "^3.13.1" - } - }, - "node_modules/@changesets/pre": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@changesets/pre/-/pre-2.0.0.tgz", - "integrity": "sha512-HLTNYX/A4jZxc+Sq8D1AMBsv+1qD6rmmJtjsCJa/9MSRybdxh0mjbTvE6JYZQ/ZiQ0mMlDOlGPXTm9KLTU3jyw==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/errors": "^0.2.0", - "@changesets/types": "^6.0.0", - "@manypkg/get-packages": "^1.1.3", - "fs-extra": "^7.0.1" - } - }, - "node_modules/@changesets/pre/node_modules/@changesets/errors": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/@changesets/errors/-/errors-0.2.0.tgz", - "integrity": "sha512-6BLOQUscTpZeGljvyQXlWOItQyU71kCdGz7Pi8H8zdw6BI0g3m43iL4xKUVPWtG+qrrL9DTjpdn8eYuCQSRpow==", - "dev": true, - "dependencies": { - "extendable-error": "^0.1.5" - } - }, - "node_modules/@changesets/pre/node_modules/@changesets/types": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/@changesets/types/-/types-6.0.0.tgz", - "integrity": "sha512-b1UkfNulgKoWfqyHtzKS5fOZYSJO+77adgL7DLRDr+/7jhChN+QcHnbjiQVOz/U+Ts3PGNySq7diAItzDgugfQ==", - "dev": true - }, - "node_modules/@changesets/read": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/@changesets/read/-/read-0.6.0.tgz", - "integrity": "sha512-ZypqX8+/im1Fm98K4YcZtmLKgjs1kDQ5zHpc2U1qdtNBmZZfo/IBiG162RoP0CUF05tvp2y4IspH11PLnPxuuw==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/git": "^3.0.0", - "@changesets/logger": "^0.1.0", - "@changesets/parse": "^0.4.0", - "@changesets/types": "^6.0.0", - "chalk": "^2.1.0", - "fs-extra": "^7.0.1", - "p-filter": "^2.1.0" - } - }, - "node_modules/@changesets/read/node_modules/@changesets/errors": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/@changesets/errors/-/errors-0.2.0.tgz", - "integrity": "sha512-6BLOQUscTpZeGljvyQXlWOItQyU71kCdGz7Pi8H8zdw6BI0g3m43iL4xKUVPWtG+qrrL9DTjpdn8eYuCQSRpow==", - "dev": true, - "dependencies": { - "extendable-error": "^0.1.5" - } - }, - "node_modules/@changesets/read/node_modules/@changesets/git": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@changesets/git/-/git-3.0.0.tgz", - "integrity": "sha512-vvhnZDHe2eiBNRFHEgMiGd2CT+164dfYyrJDhwwxTVD/OW0FUD6G7+4DIx1dNwkwjHyzisxGAU96q0sVNBns0w==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/errors": "^0.2.0", - "@changesets/types": "^6.0.0", - "@manypkg/get-packages": "^1.1.3", - "is-subdir": "^1.1.1", - "micromatch": "^4.0.2", - "spawndamnit": "^2.0.0" - } - }, - "node_modules/@changesets/read/node_modules/@changesets/logger": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/@changesets/logger/-/logger-0.1.0.tgz", - "integrity": "sha512-pBrJm4CQm9VqFVwWnSqKEfsS2ESnwqwH+xR7jETxIErZcfd1u2zBSqrHbRHR7xjhSgep9x2PSKFKY//FAshA3g==", - "dev": true, - "dependencies": { - "chalk": "^2.1.0" - } - }, - "node_modules/@changesets/read/node_modules/@changesets/parse": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/@changesets/parse/-/parse-0.4.0.tgz", - "integrity": "sha512-TS/9KG2CdGXS27S+QxbZXgr8uPsP4yNJYb4BC2/NeFUj80Rni3TeD2qwWmabymxmrLo7JEsytXH1FbpKTbvivw==", - "dev": true, - "dependencies": { - "@changesets/types": "^6.0.0", - "js-yaml": "^3.13.1" - } - }, - "node_modules/@changesets/read/node_modules/@changesets/types": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/@changesets/types/-/types-6.0.0.tgz", - "integrity": "sha512-b1UkfNulgKoWfqyHtzKS5fOZYSJO+77adgL7DLRDr+/7jhChN+QcHnbjiQVOz/U+Ts3PGNySq7diAItzDgugfQ==", - "dev": true - }, - "node_modules/@changesets/types": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/@changesets/types/-/types-5.2.1.tgz", - "integrity": "sha512-myLfHbVOqaq9UtUKqR/nZA/OY7xFjQMdfgfqeZIBK4d0hA6pgxArvdv8M+6NUzzBsjWLOtvApv8YHr4qM+Kpfg==", - "dev": true - }, - "node_modules/@changesets/write": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/@changesets/write/-/write-0.2.3.tgz", - "integrity": "sha512-Dbamr7AIMvslKnNYsLFafaVORx4H0pvCA2MHqgtNCySMe1blImEyAEOzDmcgKAkgz4+uwoLz7demIrX+JBr/Xw==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.20.1", - "@changesets/types": "^5.2.1", - "fs-extra": "^7.0.1", - "human-id": "^1.0.2", - "prettier": "^2.7.1" - } - }, - "node_modules/@changesets/write/node_modules/prettier": { - "version": "2.8.8", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.8.tgz", - "integrity": "sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==", - "dev": true, - "bin": { - "prettier": "bin-prettier.js" - }, - "engines": { - "node": ">=10.13.0" - }, - "funding": { - "url": "https://github.com/prettier/prettier?sponsor=1" - } - }, - "node_modules/@colors/colors": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/@colors/colors/-/colors-1.5.0.tgz", - "integrity": "sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ==", - "dev": true, - "optional": true, - "engines": { - "node": ">=0.1.90" - } - }, - "node_modules/@eslint-community/eslint-utils": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", - "integrity": "sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==", - "dev": true, - "dependencies": { - "eslint-visitor-keys": "^3.3.0" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "peerDependencies": { - "eslint": "^6.0.0 || ^7.0.0 || >=8.0.0" - } - }, - "node_modules/@eslint-community/regexpp": { - "version": "4.11.1", - "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.11.1.tgz", - "integrity": "sha512-m4DVN9ZqskZoLU5GlWZadwDnYo3vAEydiUayB9widCl9ffWx2IvPnp6n3on5rJmziJSw9Bv+Z3ChDVdMwXCY8Q==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^12.0.0 || ^14.0.0 || >=16.0.0" - } - }, - "node_modules/@eslint/compat": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/@eslint/compat/-/compat-1.2.1.tgz", - "integrity": "sha512-JbHG2TWuCeNzh87fXo+/46Z1LEo9DBA9T188d0fZgGxAD+cNyS6sx9fdiyxjGPBMyQVRlCutTByZ6a5+YMkF7g==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "peerDependencies": { - "eslint": "^9.10.0" - }, - "peerDependenciesMeta": { - "eslint": { - "optional": true - } - } - }, - "node_modules/@eslint/config-array": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/@eslint/config-array/-/config-array-0.18.0.tgz", - "integrity": "sha512-fTxvnS1sRMu3+JjXwJG0j/i4RT9u4qJ+lqS/yCGap4lH4zZGzQ7tu+xZqQmcMZq5OBZDL4QRxQzRjkWcGt8IVw==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@eslint/object-schema": "^2.1.4", - "debug": "^4.3.1", - "minimatch": "^3.1.2" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@eslint/core": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.7.0.tgz", - "integrity": "sha512-xp5Jirz5DyPYlPiKat8jaq0EmYvDXKKpzTbxXMpT9eqlRJkRKIz9AGMdlvYjih+im+QlhWrpvVjl8IPC/lHlUw==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@eslint/eslintrc": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-3.1.0.tgz", - "integrity": "sha512-4Bfj15dVJdoy3RfZmmo86RK1Fwzn6SstsvK9JS+BaVKqC6QQQQyXekNaC+g+LKNgkQ+2VhGAzm6hO40AhMR3zQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "ajv": "^6.12.4", - "debug": "^4.3.2", - "espree": "^10.0.1", - "globals": "^14.0.0", - "ignore": "^5.2.0", - "import-fresh": "^3.2.1", - "js-yaml": "^4.1.0", - "minimatch": "^3.1.2", - "strip-json-comments": "^3.1.1" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/@eslint/eslintrc/node_modules/argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "dev": true - }, - "node_modules/@eslint/eslintrc/node_modules/globals": { - "version": "14.0.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-14.0.0.tgz", - "integrity": "sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==", - "dev": true, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/@eslint/eslintrc/node_modules/js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", - "dev": true, - "dependencies": { - "argparse": "^2.0.1" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, - "node_modules/@eslint/js": { - "version": "9.13.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.13.0.tgz", - "integrity": "sha512-IFLyoY4d72Z5y/6o/BazFBezupzI/taV8sGumxTAVw3lXG9A6md1Dc34T9s1FoD/an9pJH8RHbAxsaEbBed9lA==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@eslint/object-schema": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/@eslint/object-schema/-/object-schema-2.1.4.tgz", - "integrity": "sha512-BsWiH1yFGjXXS2yvrf5LyuoSIIbPrGUWob917o+BTKuZ7qJdxX8aJLRxs1fS9n6r7vESrq1OUqb68dANcFXuQQ==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@eslint/plugin-kit": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.2.1.tgz", - "integrity": "sha512-HFZ4Mp26nbWk9d/BpvP0YNL6W4UoZF0VFcTw/aPPA8RpOxeFQgK+ClABGgAUXs9Y/RGX/l1vOmrqz1MQt9MNuw==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "levn": "^0.4.1" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@ethereumjs/rlp": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz", - "integrity": "sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==", - "dev": true, - "bin": { - "rlp": "bin/rlp" - }, - "engines": { - "node": ">=14" - } - }, - "node_modules/@ethereumjs/util": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/@ethereumjs/util/-/util-8.1.0.tgz", - "integrity": "sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA==", - "dev": true, - "dependencies": { - "@ethereumjs/rlp": "^4.0.1", - "ethereum-cryptography": "^2.0.0", - "micro-ftch": "^0.3.1" - }, - "engines": { - "node": ">=14" - } - }, - "node_modules/@ethereumjs/util/node_modules/ethereum-cryptography": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-2.1.2.tgz", - "integrity": "sha512-Z5Ba0T0ImZ8fqXrJbpHcbpAvIswRte2wGNR/KePnu8GbbvgJ47lMxT/ZZPG6i9Jaht4azPDop4HaM00J0J59ug==", - "dev": true, - "dependencies": { - "@noble/curves": "1.1.0", - "@noble/hashes": "1.3.1", - "@scure/bip32": "1.3.1", - "@scure/bip39": "1.2.1" - } - }, - "node_modules/@ethersproject/abi": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz", - "integrity": "sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/address": "^5.7.0", - "@ethersproject/bignumber": "^5.7.0", - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/constants": "^5.7.0", - "@ethersproject/hash": "^5.7.0", - "@ethersproject/keccak256": "^5.7.0", - "@ethersproject/logger": "^5.7.0", - "@ethersproject/properties": "^5.7.0", - "@ethersproject/strings": "^5.7.0" - } - }, - "node_modules/@ethersproject/abstract-provider": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz", - "integrity": "sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/bignumber": "^5.7.0", - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/logger": "^5.7.0", - "@ethersproject/networks": "^5.7.0", - "@ethersproject/properties": "^5.7.0", - "@ethersproject/transactions": "^5.7.0", - "@ethersproject/web": "^5.7.0" - } - }, - "node_modules/@ethersproject/abstract-signer": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz", - "integrity": "sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/abstract-provider": "^5.7.0", - "@ethersproject/bignumber": "^5.7.0", - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/logger": "^5.7.0", - "@ethersproject/properties": "^5.7.0" - } - }, - "node_modules/@ethersproject/address": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz", - "integrity": "sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/bignumber": "^5.7.0", - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/keccak256": "^5.7.0", - "@ethersproject/logger": "^5.7.0", - "@ethersproject/rlp": "^5.7.0" - } - }, - "node_modules/@ethersproject/base64": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz", - "integrity": "sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/bytes": "^5.7.0" - } - }, - "node_modules/@ethersproject/bignumber": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz", - "integrity": "sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/logger": "^5.7.0", - "bn.js": "^5.2.1" - } - }, - "node_modules/@ethersproject/bignumber/node_modules/bn.js": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", - "dev": true - }, - "node_modules/@ethersproject/bytes": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz", - "integrity": "sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/logger": "^5.7.0" - } - }, - "node_modules/@ethersproject/constants": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz", - "integrity": "sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/bignumber": "^5.7.0" - } - }, - "node_modules/@ethersproject/hash": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz", - "integrity": "sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/abstract-signer": "^5.7.0", - "@ethersproject/address": "^5.7.0", - "@ethersproject/base64": "^5.7.0", - "@ethersproject/bignumber": "^5.7.0", - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/keccak256": "^5.7.0", - "@ethersproject/logger": "^5.7.0", - "@ethersproject/properties": "^5.7.0", - "@ethersproject/strings": "^5.7.0" - } - }, - "node_modules/@ethersproject/keccak256": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz", - "integrity": "sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/bytes": "^5.7.0", - "js-sha3": "0.8.0" - } - }, - "node_modules/@ethersproject/logger": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz", - "integrity": "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ] - }, - "node_modules/@ethersproject/networks": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz", - "integrity": "sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/logger": "^5.7.0" - } - }, - "node_modules/@ethersproject/properties": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz", - "integrity": "sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/logger": "^5.7.0" - } - }, - "node_modules/@ethersproject/rlp": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz", - "integrity": "sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/logger": "^5.7.0" - } - }, - "node_modules/@ethersproject/signing-key": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz", - "integrity": "sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/logger": "^5.7.0", - "@ethersproject/properties": "^5.7.0", - "bn.js": "^5.2.1", - "elliptic": "6.5.4", - "hash.js": "1.1.7" - } - }, - "node_modules/@ethersproject/signing-key/node_modules/bn.js": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", - "dev": true - }, - "node_modules/@ethersproject/strings": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz", - "integrity": "sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/constants": "^5.7.0", - "@ethersproject/logger": "^5.7.0" - } - }, - "node_modules/@ethersproject/transactions": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz", - "integrity": "sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/address": "^5.7.0", - "@ethersproject/bignumber": "^5.7.0", - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/constants": "^5.7.0", - "@ethersproject/keccak256": "^5.7.0", - "@ethersproject/logger": "^5.7.0", - "@ethersproject/properties": "^5.7.0", - "@ethersproject/rlp": "^5.7.0", - "@ethersproject/signing-key": "^5.7.0" - } - }, - "node_modules/@ethersproject/units": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@ethersproject/units/-/units-5.7.0.tgz", - "integrity": "sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/bignumber": "^5.7.0", - "@ethersproject/constants": "^5.7.0", - "@ethersproject/logger": "^5.7.0" - } - }, - "node_modules/@ethersproject/web": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz", - "integrity": "sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@ethersproject/base64": "^5.7.0", - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/logger": "^5.7.0", - "@ethersproject/properties": "^5.7.0", - "@ethersproject/strings": "^5.7.0" - } - }, - "node_modules/@fastify/busboy": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@fastify/busboy/-/busboy-2.0.0.tgz", - "integrity": "sha512-JUFJad5lv7jxj926GPgymrWQxxjPYuJNiNjNMzqT+HiuP6Vl3dk5xzG+8sTX96np0ZAluvaMzPsjhHZ5rNuNQQ==", - "dev": true, - "engines": { - "node": ">=14" - } - }, - "node_modules/@frangio/servbot": { - "version": "0.2.5", - "resolved": "https://registry.npmjs.org/@frangio/servbot/-/servbot-0.2.5.tgz", - "integrity": "sha512-ogja4iAPZ1VwM5MU3C1ZhB88358F0PGbmSTGOkIZwOyLaDoMHIqOVCnavHjR7DV5h+oAI4Z4KDqlam3myQUrmg==", - "dev": true, - "engines": { - "node": ">=12.x", - "pnpm": "7.5.1" - } - }, - "node_modules/@humanfs/core": { - "version": "0.19.0", - "resolved": "https://registry.npmjs.org/@humanfs/core/-/core-0.19.0.tgz", - "integrity": "sha512-2cbWIHbZVEweE853g8jymffCA+NCMiuqeECeBBLm8dg2oFdjuGJhgN4UAbI+6v0CKbbhvtXA4qV8YR5Ji86nmw==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=18.18.0" - } - }, - "node_modules/@humanfs/node": { - "version": "0.16.5", - "resolved": "https://registry.npmjs.org/@humanfs/node/-/node-0.16.5.tgz", - "integrity": "sha512-KSPA4umqSG4LHYRodq31VDwKAvaTF4xmVlzM8Aeh4PlU1JQ3IG0wiA8C25d3RQ9nJyM3mBHyI53K06VVL/oFFg==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@humanfs/core": "^0.19.0", - "@humanwhocodes/retry": "^0.3.0" - }, - "engines": { - "node": ">=18.18.0" - } - }, - "node_modules/@humanwhocodes/module-importer": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz", - "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==", - "dev": true, - "engines": { - "node": ">=12.22" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/nzakas" - } - }, - "node_modules/@humanwhocodes/retry": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/@humanwhocodes/retry/-/retry-0.3.1.tgz", - "integrity": "sha512-JBxkERygn7Bv/GbN5Rv8Ul6LVknS+5Bp6RgDC/O8gEBU/yeH5Ui5C/OlWrTb6qct7LjjfT6Re2NxB0ln0yYybA==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=18.18" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/nzakas" - } - }, - "node_modules/@isaacs/cliui": { - "version": "8.0.2", - "resolved": "https://registry.npmjs.org/@isaacs/cliui/-/cliui-8.0.2.tgz", - "integrity": "sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==", - "dev": true, - "dependencies": { - "string-width": "^5.1.2", - "string-width-cjs": "npm:string-width@^4.2.0", - "strip-ansi": "^7.0.1", - "strip-ansi-cjs": "npm:strip-ansi@^6.0.1", - "wrap-ansi": "^8.1.0", - "wrap-ansi-cjs": "npm:wrap-ansi@^7.0.0" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/@isaacs/cliui/node_modules/ansi-regex": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-6.0.1.tgz", - "integrity": "sha512-n5M855fKb2SsfMIiFFoVrABHJC8QtHwVx+mHWP3QcEqBHYienj5dHSgjbxtC0WEZXYt4wcD6zrQElDPhFuZgfA==", - "dev": true, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/chalk/ansi-regex?sponsor=1" - } - }, - "node_modules/@isaacs/cliui/node_modules/ansi-styles": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-6.2.1.tgz", - "integrity": "sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==", - "dev": true, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@isaacs/cliui/node_modules/emoji-regex": { - "version": "9.2.2", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", - "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", - "dev": true - }, - "node_modules/@isaacs/cliui/node_modules/string-width": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-5.1.2.tgz", - "integrity": "sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==", - "dev": true, - "dependencies": { - "eastasianwidth": "^0.2.0", - "emoji-regex": "^9.2.2", - "strip-ansi": "^7.0.1" - }, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/@isaacs/cliui/node_modules/strip-ansi": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.1.0.tgz", - "integrity": "sha512-iq6eVVI64nQQTRYq2KtEg2d2uU7LElhTJwsH4YzIHZshxlgZms/wIc4VoDQTlG/IvVIrBKG06CrZnp0qv7hkcQ==", - "dev": true, - "dependencies": { - "ansi-regex": "^6.0.1" - }, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/chalk/strip-ansi?sponsor=1" - } - }, - "node_modules/@isaacs/cliui/node_modules/wrap-ansi": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-8.1.0.tgz", - "integrity": "sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==", - "dev": true, - "dependencies": { - "ansi-styles": "^6.1.0", - "string-width": "^5.0.1", - "strip-ansi": "^7.0.1" - }, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, - "node_modules/@manypkg/find-root": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@manypkg/find-root/-/find-root-1.1.0.tgz", - "integrity": "sha512-mki5uBvhHzO8kYYix/WRy2WX8S3B5wdVSc9D6KcU5lQNglP2yt58/VfLuAK49glRXChosY8ap2oJ1qgma3GUVA==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.5.5", - "@types/node": "^12.7.1", - "find-up": "^4.1.0", - "fs-extra": "^8.1.0" - } - }, - "node_modules/@manypkg/find-root/node_modules/@types/node": { - "version": "12.20.55", - "resolved": "https://registry.npmjs.org/@types/node/-/node-12.20.55.tgz", - "integrity": "sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ==", - "dev": true - }, - "node_modules/@manypkg/find-root/node_modules/fs-extra": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz", - "integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==", - "dev": true, - "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^4.0.0", - "universalify": "^0.1.0" - }, - "engines": { - "node": ">=6 <7 || >=8" - } - }, - "node_modules/@manypkg/get-packages": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/@manypkg/get-packages/-/get-packages-1.1.3.tgz", - "integrity": "sha512-fo+QhuU3qE/2TQMQmbVMqaQ6EWbMhi4ABWP+O4AM1NqPBuy0OrApV5LO6BrrgnhtAHS2NH6RrVk9OL181tTi8A==", - "dev": true, - "dependencies": { - "@babel/runtime": "^7.5.5", - "@changesets/types": "^4.0.1", - "@manypkg/find-root": "^1.1.0", - "fs-extra": "^8.1.0", - "globby": "^11.0.0", - "read-yaml-file": "^1.1.0" - } - }, - "node_modules/@manypkg/get-packages/node_modules/@changesets/types": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/@changesets/types/-/types-4.1.0.tgz", - "integrity": "sha512-LDQvVDv5Kb50ny2s25Fhm3d9QSZimsoUGBsUioj6MC3qbMUCuC8GPIvk/M6IvXx3lYhAs0lwWUQLb+VIEUCECw==", - "dev": true - }, - "node_modules/@manypkg/get-packages/node_modules/fs-extra": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz", - "integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==", - "dev": true, - "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^4.0.0", - "universalify": "^0.1.0" - }, - "engines": { - "node": ">=6 <7 || >=8" - } - }, - "node_modules/@metamask/eth-sig-util": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-4.0.1.tgz", - "integrity": "sha512-tghyZKLHZjcdlDqCA3gNZmLeR0XvOE9U1qoQO9ohyAZT6Pya+H9vkBPcsyXytmYLNgVoin7CKCmweo/R43V+tQ==", - "dev": true, - "dependencies": { - "ethereumjs-abi": "^0.6.8", - "ethereumjs-util": "^6.2.1", - "ethjs-util": "^0.1.6", - "tweetnacl": "^1.0.3", - "tweetnacl-util": "^0.15.1" - }, - "engines": { - "node": ">=12.0.0" - } - }, - "node_modules/@metamask/eth-sig-util/node_modules/@types/bn.js": { - "version": "4.11.6", - "resolved": "https://registry.npmjs.org/@types/bn.js/-/bn.js-4.11.6.tgz", - "integrity": "sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==", - "dev": true, - "dependencies": { - "@types/node": "*" - } - }, - "node_modules/@metamask/eth-sig-util/node_modules/ethereumjs-util": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/ethereumjs-util/-/ethereumjs-util-6.2.1.tgz", - "integrity": "sha512-W2Ktez4L01Vexijrm5EB6w7dg4n/TgpoYU4avuT5T3Vmnw/eCRtiBrJfQYS/DCSvDIOLn2k57GcHdeBcgVxAqw==", - "dev": true, - "dependencies": { - "@types/bn.js": "^4.11.3", - "bn.js": "^4.11.0", - "create-hash": "^1.1.2", - "elliptic": "^6.5.2", - "ethereum-cryptography": "^0.1.3", - "ethjs-util": "0.1.6", - "rlp": "^2.2.3" - } - }, - "node_modules/@noble/curves": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.1.0.tgz", - "integrity": "sha512-091oBExgENk/kGj3AZmtBDMpxQPDtxQABR2B9lb1JbVTs6ytdzZNwvhxQ4MWasRNEzlbEH8jCWFCwhF/Obj5AA==", - "dev": true, - "dependencies": { - "@noble/hashes": "1.3.1" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/@noble/hashes": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.1.tgz", - "integrity": "sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA==", - "dev": true, - "engines": { - "node": ">= 16" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/@noble/secp256k1": { - "version": "1.7.1", - "resolved": "https://registry.npmjs.org/@noble/secp256k1/-/secp256k1-1.7.1.tgz", - "integrity": "sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw==", - "dev": true, - "funding": [ - { - "type": "individual", - "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", - "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", - "dev": true, - "dependencies": { - "@nodelib/fs.stat": "2.0.5", - "run-parallel": "^1.1.9" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/@nodelib/fs.stat": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", - "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", - "dev": true, - "engines": { - "node": ">= 8" - } - }, - "node_modules/@nodelib/fs.walk": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", - "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", - "dev": true, - "dependencies": { - "@nodelib/fs.scandir": "2.1.5", - "fastq": "^1.6.0" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/@nomicfoundation/edr": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@nomicfoundation/edr/-/edr-0.3.3.tgz", - "integrity": "sha512-zP+e+3B1nEUx6bW5BPnIzCQbkhmYfdMBJdiVggTqqTfAA82sOkdOG7wsOMcz5qF3fYfx/irNRM1kgc9HVFIbpQ==", - "dev": true, - "engines": { - "node": ">= 18" - }, - "optionalDependencies": { - "@nomicfoundation/edr-darwin-arm64": "0.3.3", - "@nomicfoundation/edr-darwin-x64": "0.3.3", - "@nomicfoundation/edr-linux-arm64-gnu": "0.3.3", - "@nomicfoundation/edr-linux-arm64-musl": "0.3.3", - "@nomicfoundation/edr-linux-x64-gnu": "0.3.3", - "@nomicfoundation/edr-linux-x64-musl": "0.3.3", - "@nomicfoundation/edr-win32-arm64-msvc": "0.3.3", - "@nomicfoundation/edr-win32-ia32-msvc": "0.3.3", - "@nomicfoundation/edr-win32-x64-msvc": "0.3.3" - } - }, - "node_modules/@nomicfoundation/edr-darwin-arm64": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@nomicfoundation/edr-darwin-arm64/-/edr-darwin-arm64-0.3.3.tgz", - "integrity": "sha512-E9VGsUD+1Ga4mn/5ooHsMi8JEfhZbKP6CXN/BhJ8kXbIC10NqTD1RuhCKGRtYq4vqH/3Nfq25Xg8E8RWOF4KBQ==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">= 18" - } - }, - "node_modules/@nomicfoundation/edr-darwin-x64": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@nomicfoundation/edr-darwin-x64/-/edr-darwin-x64-0.3.3.tgz", - "integrity": "sha512-vkZXZ1ydPg+Ijb2iyqENA+KCkxGTCUWG5itCSliiA0Li2YE7ujDMGhheEpFp1WVlZadviz0bfk1rZXbCqlirpg==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">= 18" - } - }, - "node_modules/@nomicfoundation/edr-linux-arm64-gnu": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@nomicfoundation/edr-linux-arm64-gnu/-/edr-linux-arm64-gnu-0.3.3.tgz", - "integrity": "sha512-gdIg0Yj1qqS9wVuywc5B/+DqKylfUGB6/CQn/shMqwAfsAVAVpchkhy66PR+REEx7fh/GkNctxLlENXPeLzDiA==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 18" - } - }, - "node_modules/@nomicfoundation/edr-linux-arm64-musl": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@nomicfoundation/edr-linux-arm64-musl/-/edr-linux-arm64-musl-0.3.3.tgz", - "integrity": "sha512-AXZ08MFvhNeBZbOBNmz1SJ/DMrMOE2mHEJtaNnsctlxIunjxfrWww4q+WXB34jbr9iaVYYlPsaWe5sueuw6s3Q==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 18" - } - }, - "node_modules/@nomicfoundation/edr-linux-x64-gnu": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@nomicfoundation/edr-linux-x64-gnu/-/edr-linux-x64-gnu-0.3.3.tgz", - "integrity": "sha512-xElOs1U+E6lBLtv1mnJ+E8nr2MxZgKiLo8bZAgBboy9odYtmkDVwhMjtsFKSuZbGxFtsSyGRT4cXw3JAbtUDeA==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 18" - } - }, - "node_modules/@nomicfoundation/edr-linux-x64-musl": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@nomicfoundation/edr-linux-x64-musl/-/edr-linux-x64-musl-0.3.3.tgz", - "integrity": "sha512-2Fe6gwm1RAGQ/PfMYiaSba2OrFp8zzYWh+am9lYObOFjV9D+A1zhIzfy0UC74glPks5eV8eY4pBPrVR042m2Nw==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 18" - } - }, - "node_modules/@nomicfoundation/edr-win32-arm64-msvc": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@nomicfoundation/edr-win32-arm64-msvc/-/edr-win32-arm64-msvc-0.3.3.tgz", - "integrity": "sha512-8NHyxIsFrl0ufSQ/ErqF2lKIa/gz1gaaa1a2vKkDEqvqCUcPhBTYhA5NHgTPhLETFTnCFr0z+YbctFCyjh4qrA==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@nomicfoundation/edr-win32-ia32-msvc": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@nomicfoundation/edr-win32-ia32-msvc/-/edr-win32-ia32-msvc-0.3.3.tgz", - "integrity": "sha512-0F6hM0kGia4dQVb/kauho9JcP1ozWisY2/She+ISR5ceuhzmAwQJluM0g+0TYDME0LtxBxiMPq/yPiZMQeq31w==", - "cpu": [ - "ia32" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 18" - } - }, - "node_modules/@nomicfoundation/edr-win32-x64-msvc": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@nomicfoundation/edr-win32-x64-msvc/-/edr-win32-x64-msvc-0.3.3.tgz", - "integrity": "sha512-d75q1uaMb6z9i+GQZoblbOfFBvlBnWc+5rB13UWRkCOJSnoYwyFWhGJx5GeM59gC7aIblc5VD9qOAhHuvM9N+w==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 18" - } - }, - "node_modules/@nomicfoundation/ethereumjs-common": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@nomicfoundation/ethereumjs-common/-/ethereumjs-common-4.0.4.tgz", - "integrity": "sha512-9Rgb658lcWsjiicr5GzNCjI1llow/7r0k50dLL95OJ+6iZJcVbi15r3Y0xh2cIO+zgX0WIHcbzIu6FeQf9KPrg==", - "dev": true, - "dependencies": { - "@nomicfoundation/ethereumjs-util": "9.0.4" - } - }, - "node_modules/@nomicfoundation/ethereumjs-rlp": { - "version": "5.0.4", - "resolved": "https://registry.npmjs.org/@nomicfoundation/ethereumjs-rlp/-/ethereumjs-rlp-5.0.4.tgz", - "integrity": "sha512-8H1S3s8F6QueOc/X92SdrA4RDenpiAEqMg5vJH99kcQaCy/a3Q6fgseo75mgWlbanGJXSlAPtnCeG9jvfTYXlw==", - "dev": true, - "bin": { - "rlp": "bin/rlp.cjs" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/@nomicfoundation/ethereumjs-tx": { - "version": "5.0.4", - "resolved": "https://registry.npmjs.org/@nomicfoundation/ethereumjs-tx/-/ethereumjs-tx-5.0.4.tgz", - "integrity": "sha512-Xjv8wAKJGMrP1f0n2PeyfFCCojHd7iS3s/Ab7qzF1S64kxZ8Z22LCMynArYsVqiFx6rzYy548HNVEyI+AYN/kw==", - "dev": true, - "dependencies": { - "@nomicfoundation/ethereumjs-common": "4.0.4", - "@nomicfoundation/ethereumjs-rlp": "5.0.4", - "@nomicfoundation/ethereumjs-util": "9.0.4", - "ethereum-cryptography": "0.1.3" - }, - "engines": { - "node": ">=18" - }, - "peerDependencies": { - "c-kzg": "^2.1.2" - }, - "peerDependenciesMeta": { - "c-kzg": { - "optional": true - } - } - }, - "node_modules/@nomicfoundation/ethereumjs-util": { - "version": "9.0.4", - "resolved": "https://registry.npmjs.org/@nomicfoundation/ethereumjs-util/-/ethereumjs-util-9.0.4.tgz", - "integrity": "sha512-sLOzjnSrlx9Bb9EFNtHzK/FJFsfg2re6bsGqinFinH1gCqVfz9YYlXiMWwDM4C/L4ywuHFCYwfKTVr/QHQcU0Q==", - "dev": true, - "dependencies": { - "@nomicfoundation/ethereumjs-rlp": "5.0.4", - "ethereum-cryptography": "0.1.3" - }, - "engines": { - "node": ">=18" - }, - "peerDependencies": { - "c-kzg": "^2.1.2" - }, - "peerDependenciesMeta": { - "c-kzg": { - "optional": true - } - } - }, - "node_modules/@nomicfoundation/hardhat-chai-matchers": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/@nomicfoundation/hardhat-chai-matchers/-/hardhat-chai-matchers-2.0.6.tgz", - "integrity": "sha512-Te1Uyo9oJcTCF0Jy9dztaLpshmlpjLf2yPtWXlXuLjMt3RRSmJLm/+rKVTW6gfadAEs12U/it6D0ZRnnRGiICQ==", - "dev": true, - "dependencies": { - "@types/chai-as-promised": "^7.1.3", - "chai-as-promised": "^7.1.1", - "deep-eql": "^4.0.1", - "ordinal": "^1.0.3" - }, - "peerDependencies": { - "@nomicfoundation/hardhat-ethers": "^3.0.0", - "chai": "^4.2.0", - "ethers": "^6.1.0", - "hardhat": "^2.9.4" - } - }, - "node_modules/@nomicfoundation/hardhat-ethers": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@nomicfoundation/hardhat-ethers/-/hardhat-ethers-3.0.4.tgz", - "integrity": "sha512-k9qbLoY7qn6C6Y1LI0gk2kyHXil2Tauj4kGzQ8pgxYXIGw8lWn8tuuL72E11CrlKaXRUvOgF0EXrv/msPI2SbA==", - "dev": true, - "dependencies": { - "debug": "^4.1.1", - "lodash.isequal": "^4.5.0" - }, - "peerDependencies": { - "ethers": "^6.1.0", - "hardhat": "^2.0.0" - } - }, - "node_modules/@nomicfoundation/hardhat-network-helpers": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/@nomicfoundation/hardhat-network-helpers/-/hardhat-network-helpers-1.0.9.tgz", - "integrity": "sha512-OXWCv0cHpwLUO2u7bFxBna6dQtCC2Gg/aN/KtJLO7gmuuA28vgmVKYFRCDUqrbjujzgfwQ2aKyZ9Y3vSmDqS7Q==", - "dev": true, - "dependencies": { - "ethereumjs-util": "^7.1.4" - }, - "peerDependencies": { - "hardhat": "^2.9.5" - } - }, - "node_modules/@nomicfoundation/solidity-analyzer": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@nomicfoundation/solidity-analyzer/-/solidity-analyzer-0.1.1.tgz", - "integrity": "sha512-1LMtXj1puAxyFusBgUIy5pZk3073cNXYnXUpuNKFghHbIit/xZgbk0AokpUADbNm3gyD6bFWl3LRFh3dhVdREg==", - "dev": true, - "engines": { - "node": ">= 12" - }, - "optionalDependencies": { - "@nomicfoundation/solidity-analyzer-darwin-arm64": "0.1.1", - "@nomicfoundation/solidity-analyzer-darwin-x64": "0.1.1", - "@nomicfoundation/solidity-analyzer-freebsd-x64": "0.1.1", - "@nomicfoundation/solidity-analyzer-linux-arm64-gnu": "0.1.1", - "@nomicfoundation/solidity-analyzer-linux-arm64-musl": "0.1.1", - "@nomicfoundation/solidity-analyzer-linux-x64-gnu": "0.1.1", - "@nomicfoundation/solidity-analyzer-linux-x64-musl": "0.1.1", - "@nomicfoundation/solidity-analyzer-win32-arm64-msvc": "0.1.1", - "@nomicfoundation/solidity-analyzer-win32-ia32-msvc": "0.1.1", - "@nomicfoundation/solidity-analyzer-win32-x64-msvc": "0.1.1" - } - }, - "node_modules/@nomicfoundation/solidity-analyzer-darwin-arm64": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@nomicfoundation/solidity-analyzer-darwin-arm64/-/solidity-analyzer-darwin-arm64-0.1.1.tgz", - "integrity": "sha512-KcTodaQw8ivDZyF+D76FokN/HdpgGpfjc/gFCImdLUyqB6eSWVaZPazMbeAjmfhx3R0zm/NYVzxwAokFKgrc0w==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@nomicfoundation/solidity-analyzer-darwin-x64": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@nomicfoundation/solidity-analyzer-darwin-x64/-/solidity-analyzer-darwin-x64-0.1.1.tgz", - "integrity": "sha512-XhQG4BaJE6cIbjAVtzGOGbK3sn1BO9W29uhk9J8y8fZF1DYz0Doj8QDMfpMu+A6TjPDs61lbsmeYodIDnfveSA==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@nomicfoundation/solidity-analyzer-freebsd-x64": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@nomicfoundation/solidity-analyzer-freebsd-x64/-/solidity-analyzer-freebsd-x64-0.1.1.tgz", - "integrity": "sha512-GHF1VKRdHW3G8CndkwdaeLkVBi5A9u2jwtlS7SLhBc8b5U/GcoL39Q+1CSO3hYqePNP+eV5YI7Zgm0ea6kMHoA==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "freebsd" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@nomicfoundation/solidity-analyzer-linux-arm64-gnu": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@nomicfoundation/solidity-analyzer-linux-arm64-gnu/-/solidity-analyzer-linux-arm64-gnu-0.1.1.tgz", - "integrity": "sha512-g4Cv2fO37ZsUENQ2vwPnZc2zRenHyAxHcyBjKcjaSmmkKrFr64yvzeNO8S3GBFCo90rfochLs99wFVGT/0owpg==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@nomicfoundation/solidity-analyzer-linux-arm64-musl": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@nomicfoundation/solidity-analyzer-linux-arm64-musl/-/solidity-analyzer-linux-arm64-musl-0.1.1.tgz", - "integrity": "sha512-WJ3CE5Oek25OGE3WwzK7oaopY8xMw9Lhb0mlYuJl/maZVo+WtP36XoQTb7bW/i8aAdHW5Z+BqrHMux23pvxG3w==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@nomicfoundation/solidity-analyzer-linux-x64-gnu": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@nomicfoundation/solidity-analyzer-linux-x64-gnu/-/solidity-analyzer-linux-x64-gnu-0.1.1.tgz", - "integrity": "sha512-5WN7leSr5fkUBBjE4f3wKENUy9HQStu7HmWqbtknfXkkil+eNWiBV275IOlpXku7v3uLsXTOKpnnGHJYI2qsdA==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@nomicfoundation/solidity-analyzer-linux-x64-musl": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@nomicfoundation/solidity-analyzer-linux-x64-musl/-/solidity-analyzer-linux-x64-musl-0.1.1.tgz", - "integrity": "sha512-KdYMkJOq0SYPQMmErv/63CwGwMm5XHenEna9X9aB8mQmhDBrYrlAOSsIPgFCUSL0hjxE3xHP65/EPXR/InD2+w==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@nomicfoundation/solidity-analyzer-win32-arm64-msvc": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@nomicfoundation/solidity-analyzer-win32-arm64-msvc/-/solidity-analyzer-win32-arm64-msvc-0.1.1.tgz", - "integrity": "sha512-VFZASBfl4qiBYwW5xeY20exWhmv6ww9sWu/krWSesv3q5hA0o1JuzmPHR4LPN6SUZj5vcqci0O6JOL8BPw+APg==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@nomicfoundation/solidity-analyzer-win32-ia32-msvc": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@nomicfoundation/solidity-analyzer-win32-ia32-msvc/-/solidity-analyzer-win32-ia32-msvc-0.1.1.tgz", - "integrity": "sha512-JnFkYuyCSA70j6Si6cS1A9Gh1aHTEb8kOTBApp/c7NRTFGNMH8eaInKlyuuiIbvYFhlXW4LicqyYuWNNq9hkpQ==", - "cpu": [ - "ia32" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@nomicfoundation/solidity-analyzer-win32-x64-msvc": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@nomicfoundation/solidity-analyzer-win32-x64-msvc/-/solidity-analyzer-win32-x64-msvc-0.1.1.tgz", - "integrity": "sha512-HrVJr6+WjIXGnw3Q9u6KQcbZCtk0caVWhCdFADySvRyUxJ8PnzlaP+MhwNE8oyT8OZ6ejHBRrrgjSqDCFXGirw==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@openzeppelin/docs-utils": { - "version": "0.1.5", - "resolved": "https://registry.npmjs.org/@openzeppelin/docs-utils/-/docs-utils-0.1.5.tgz", - "integrity": "sha512-GfqXArKmdq8rv+hsP+g8uS1VEkvMIzWs31dCONffzmqFwJ+MOsaNQNZNXQnLRgUkzk8i5mTNDjJuxDy+aBZImQ==", - "dev": true, - "dependencies": { - "@frangio/servbot": "^0.2.5", - "chalk": "^3.0.0", - "chokidar": "^3.5.3", - "env-paths": "^2.2.0", - "find-up": "^4.1.0", - "is-port-reachable": "^3.0.0", - "js-yaml": "^3.13.1", - "lodash.startcase": "^4.4.0", - "minimist": "^1.2.0" - }, - "bin": { - "oz-docs": "oz-docs.js" - } - }, - "node_modules/@openzeppelin/docs-utils/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@openzeppelin/docs-utils/node_modules/chalk": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", - "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/@openzeppelin/docs-utils/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@openzeppelin/docs-utils/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@openzeppelin/docs-utils/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@openzeppelin/docs-utils/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/@openzeppelin/merkle-tree": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/@openzeppelin/merkle-tree/-/merkle-tree-1.0.7.tgz", - "integrity": "sha512-i93t0YYv6ZxTCYU3CdO5Q+DXK0JH10A4dCBOMlzYbX+ujTXm+k1lXiEyVqmf94t3sqmv8sm/XT5zTa0+efnPgQ==", - "dev": true, - "dependencies": { - "@ethersproject/abi": "^5.7.0", - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/constants": "^5.7.0", - "@ethersproject/keccak256": "^5.7.0" - } - }, - "node_modules/@openzeppelin/upgrade-safe-transpiler": { - "version": "0.3.32", - "resolved": "https://registry.npmjs.org/@openzeppelin/upgrade-safe-transpiler/-/upgrade-safe-transpiler-0.3.32.tgz", - "integrity": "sha512-ypgj6MXXcDG0dOuMwENXt0H4atCtCsPgpDgWZYewb2egfUCMpj6d2GO4pcNZgdn1zYsmUHfm5ZA/Nga/8qkdKA==", - "dev": true, - "dependencies": { - "ajv": "^8.0.0", - "compare-versions": "^6.0.0", - "ethereum-cryptography": "^2.0.0", - "lodash": "^4.17.20", - "minimatch": "^9.0.0", - "minimist": "^1.2.5", - "solidity-ast": "^0.4.51" - }, - "bin": { - "upgrade-safe-transpiler": "dist/cli.js" - } - }, - "node_modules/@openzeppelin/upgrade-safe-transpiler/node_modules/ajv": { - "version": "8.12.0", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.12.0.tgz", - "integrity": "sha512-sRu1kpcO9yLtYxBKvqfTeh9KzZEwO3STyX1HT+4CaDzC6HpTGYhIhPIzj9XuKU7KYDwnaeh5hcOwjy1QuJzBPA==", - "dev": true, - "dependencies": { - "fast-deep-equal": "^3.1.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2", - "uri-js": "^4.2.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/@openzeppelin/upgrade-safe-transpiler/node_modules/brace-expansion": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.0.tgz", - "integrity": "sha512-TN1kCZAgdgweJhWWpgKYrQaMNHcDULHkWwQIspdtjV4Y5aurRdZpjAqn6yX3FPqTA9ngHCc4hJxMAMgGfve85w==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0" - } - }, - "node_modules/@openzeppelin/upgrade-safe-transpiler/node_modules/ethereum-cryptography": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-2.1.2.tgz", - "integrity": "sha512-Z5Ba0T0ImZ8fqXrJbpHcbpAvIswRte2wGNR/KePnu8GbbvgJ47lMxT/ZZPG6i9Jaht4azPDop4HaM00J0J59ug==", - "dev": true, - "dependencies": { - "@noble/curves": "1.1.0", - "@noble/hashes": "1.3.1", - "@scure/bip32": "1.3.1", - "@scure/bip39": "1.2.1" - } - }, - "node_modules/@openzeppelin/upgrade-safe-transpiler/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true - }, - "node_modules/@openzeppelin/upgrade-safe-transpiler/node_modules/minimatch": { - "version": "9.0.9", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.9.tgz", - "integrity": "sha512-OBwBN9AL4dqmETlpS2zasx+vTeWclWzkblfZk7KTA5j3jeOONz/tRCnZomUyvNg83wL5Zv9Ss6HMJXAgL8R2Yg==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^2.0.2" - }, - "engines": { - "node": ">=16 || 14 >=14.17" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/@openzeppelin/upgrade-safe-transpiler/node_modules/require-from-string": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", - "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/@openzeppelin/upgrades-core": { - "version": "1.29.0", - "resolved": "https://registry.npmjs.org/@openzeppelin/upgrades-core/-/upgrades-core-1.29.0.tgz", - "integrity": "sha512-csZvAMNqUJjMDNBPbaXcV9Nlo4oagMD/HkOBHTpYbBTpnmUhwPVHOMv+Rl0RatBdLHuGc6hw88h80k5PWkEeWw==", - "dev": true, - "dependencies": { - "cbor": "^9.0.0", - "chalk": "^4.1.0", - "compare-versions": "^6.0.0", - "debug": "^4.1.1", - "ethereumjs-util": "^7.0.3", - "minimist": "^1.2.7", - "proper-lockfile": "^4.1.1", - "solidity-ast": "^0.4.26" - }, - "bin": { - "openzeppelin-upgrades-core": "dist/cli/cli.js" - } - }, - "node_modules/@openzeppelin/upgrades-core/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@openzeppelin/upgrades-core/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@openzeppelin/upgrades-core/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@openzeppelin/upgrades-core/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@openzeppelin/upgrades-core/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@openzeppelin/upgrades-core/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/@pkgjs/parseargs": { - "version": "0.11.0", - "resolved": "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz", - "integrity": "sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==", - "dev": true, - "optional": true, - "engines": { - "node": ">=14" - } - }, - "node_modules/@pnpm/config.env-replace": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@pnpm/config.env-replace/-/config.env-replace-1.1.0.tgz", - "integrity": "sha512-htyl8TWnKL7K/ESFa1oW2UB5lVDxuF5DpM7tBi6Hu2LNL3mWkIzNLG6N4zoCUP1lCKNxWy/3iu8mS8MvToGd6w==", - "dev": true, - "engines": { - "node": ">=12.22.0" - } - }, - "node_modules/@pnpm/network.ca-file": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@pnpm/network.ca-file/-/network.ca-file-1.0.2.tgz", - "integrity": "sha512-YcPQ8a0jwYU9bTdJDpXjMi7Brhkr1mXsXrUJvjqM2mQDgkRiz8jFaQGOdaLxgjtUfQgZhKy/O3cG/YwmgKaxLA==", - "dev": true, - "dependencies": { - "graceful-fs": "4.2.10" - }, - "engines": { - "node": ">=12.22.0" - } - }, - "node_modules/@pnpm/network.ca-file/node_modules/graceful-fs": { - "version": "4.2.10", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", - "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==", - "dev": true - }, - "node_modules/@pnpm/npm-conf": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/@pnpm/npm-conf/-/npm-conf-2.2.2.tgz", - "integrity": "sha512-UA91GwWPhFExt3IizW6bOeY/pQ0BkuNwKjk9iQW9KqxluGCrg4VenZ0/L+2Y0+ZOtme72EVvg6v0zo3AMQRCeA==", - "dev": true, - "dependencies": { - "@pnpm/config.env-replace": "^1.1.0", - "@pnpm/network.ca-file": "^1.0.1", - "config-chain": "^1.1.11" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/@scure/base": { - "version": "1.1.6", - "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.1.6.tgz", - "integrity": "sha512-ok9AWwhcgYuGG3Zfhyqg+zwl+Wn5uE+dwC0NV/2qQkx4dABbb/bx96vWu8NSj+BNjjSjno+JRYRjle1jV08k3g==", - "dev": true, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/@scure/bip32": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/@scure/bip32/-/bip32-1.3.1.tgz", - "integrity": "sha512-osvveYtyzdEVbt3OfwwXFr4P2iVBL5u1Q3q4ONBfDY/UpOuXmOlbgwc1xECEboY8wIays8Yt6onaWMUdUbfl0A==", - "dev": true, - "dependencies": { - "@noble/curves": "~1.1.0", - "@noble/hashes": "~1.3.1", - "@scure/base": "~1.1.0" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/@scure/bip39": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/@scure/bip39/-/bip39-1.2.1.tgz", - "integrity": "sha512-Z3/Fsz1yr904dduJD0NpiyRHhRYHdcnyh73FZWiV+/qhWi83wNJ3NWolYqCEN+ZWsUz2TWwajJggcRE9r1zUYg==", - "dev": true, - "dependencies": { - "@noble/hashes": "~1.3.0", - "@scure/base": "~1.1.0" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/@sentry/core": { - "version": "5.30.0", - "resolved": "https://registry.npmjs.org/@sentry/core/-/core-5.30.0.tgz", - "integrity": "sha512-TmfrII8w1PQZSZgPpUESqjB+jC6MvZJZdLtE/0hZ+SrnKhW3x5WlYLvTXZpcWePYBku7rl2wn1RZu6uT0qCTeg==", - "dev": true, - "dependencies": { - "@sentry/hub": "5.30.0", - "@sentry/minimal": "5.30.0", - "@sentry/types": "5.30.0", - "@sentry/utils": "5.30.0", - "tslib": "^1.9.3" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/@sentry/hub": { - "version": "5.30.0", - "resolved": "https://registry.npmjs.org/@sentry/hub/-/hub-5.30.0.tgz", - "integrity": "sha512-2tYrGnzb1gKz2EkMDQcfLrDTvmGcQPuWxLnJKXJvYTQDGLlEvi2tWz1VIHjunmOvJrB5aIQLhm+dcMRwFZDCqQ==", - "dev": true, - "dependencies": { - "@sentry/types": "5.30.0", - "@sentry/utils": "5.30.0", - "tslib": "^1.9.3" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/@sentry/minimal": { - "version": "5.30.0", - "resolved": "https://registry.npmjs.org/@sentry/minimal/-/minimal-5.30.0.tgz", - "integrity": "sha512-BwWb/owZKtkDX+Sc4zCSTNcvZUq7YcH3uAVlmh/gtR9rmUvbzAA3ewLuB3myi4wWRAMEtny6+J/FN/x+2wn9Xw==", - "dev": true, - "dependencies": { - "@sentry/hub": "5.30.0", - "@sentry/types": "5.30.0", - "tslib": "^1.9.3" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/@sentry/node": { - "version": "5.30.0", - "resolved": "https://registry.npmjs.org/@sentry/node/-/node-5.30.0.tgz", - "integrity": "sha512-Br5oyVBF0fZo6ZS9bxbJZG4ApAjRqAnqFFurMVJJdunNb80brh7a5Qva2kjhm+U6r9NJAB5OmDyPkA1Qnt+QVg==", - "dev": true, - "dependencies": { - "@sentry/core": "5.30.0", - "@sentry/hub": "5.30.0", - "@sentry/tracing": "5.30.0", - "@sentry/types": "5.30.0", - "@sentry/utils": "5.30.0", - "cookie": "^0.4.1", - "https-proxy-agent": "^5.0.0", - "lru_map": "^0.3.3", - "tslib": "^1.9.3" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/@sentry/tracing": { - "version": "5.30.0", - "resolved": "https://registry.npmjs.org/@sentry/tracing/-/tracing-5.30.0.tgz", - "integrity": "sha512-dUFowCr0AIMwiLD7Fs314Mdzcug+gBVo/+NCMyDw8tFxJkwWAKl7Qa2OZxLQ0ZHjakcj1hNKfCQJ9rhyfOl4Aw==", - "dev": true, - "dependencies": { - "@sentry/hub": "5.30.0", - "@sentry/minimal": "5.30.0", - "@sentry/types": "5.30.0", - "@sentry/utils": "5.30.0", - "tslib": "^1.9.3" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/@sentry/types": { - "version": "5.30.0", - "resolved": "https://registry.npmjs.org/@sentry/types/-/types-5.30.0.tgz", - "integrity": "sha512-R8xOqlSTZ+htqrfteCWU5Nk0CDN5ApUTvrlvBuiH1DyP6czDZ4ktbZB0hAgBlVcK0U+qpD3ag3Tqqpa5Q67rPw==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/@sentry/utils": { - "version": "5.30.0", - "resolved": "https://registry.npmjs.org/@sentry/utils/-/utils-5.30.0.tgz", - "integrity": "sha512-zaYmoH0NWWtvnJjC9/CBseXMtKHm/tm40sz3YfJRxeQjyzRqNQPgivpd9R/oDJCYj999mzdW382p/qi2ypjLww==", - "dev": true, - "dependencies": { - "@sentry/types": "5.30.0", - "tslib": "^1.9.3" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/@sindresorhus/is": { - "version": "5.6.0", - "resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-5.6.0.tgz", - "integrity": "sha512-TV7t8GKYaJWsn00tFDqBw8+Uqmr8A0fRU1tvTQhyZzGv0sJCGRQL3JGMI3ucuKo3XIZdUP+Lx7/gh2t3lewy7g==", - "dev": true, - "engines": { - "node": ">=14.16" - }, - "funding": { - "url": "https://github.com/sindresorhus/is?sponsor=1" - } - }, - "node_modules/@solidity-parser/parser": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/@solidity-parser/parser/-/parser-0.18.0.tgz", - "integrity": "sha512-yfORGUIPgLck41qyN7nbwJRAx17/jAIXCTanHOJZhB6PJ1iAk/84b/xlsVKFSyNyLXIj0dhppoE0+CRws7wlzA==", - "dev": true - }, - "node_modules/@szmarczak/http-timer": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/@szmarczak/http-timer/-/http-timer-5.0.1.tgz", - "integrity": "sha512-+PmQX0PiAYPMeVYe237LJAYvOMYW1j2rH5YROyS3b4CTVJum34HfRvKvAzozHAQG0TnHNdUfY9nCeUyRAs//cw==", - "dev": true, - "dependencies": { - "defer-to-connect": "^2.0.1" - }, - "engines": { - "node": ">=14.16" - } - }, - "node_modules/@types/bn.js": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/@types/bn.js/-/bn.js-5.1.2.tgz", - "integrity": "sha512-dkpZu0szUtn9UXTmw+e0AJFd4D2XAxDnsCLdc05SfqpqzPEBft8eQr8uaFitfo/dUUOZERaLec2hHMG87A4Dxg==", - "dev": true, - "dependencies": { - "@types/node": "*" - } - }, - "node_modules/@types/chai": { - "version": "4.3.6", - "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.3.6.tgz", - "integrity": "sha512-VOVRLM1mBxIRxydiViqPcKn6MIxZytrbMpd6RJLIWKxUNr3zux8no0Oc7kJx0WAPIitgZ0gkrDS+btlqQpubpw==", - "dev": true - }, - "node_modules/@types/chai-as-promised": { - "version": "7.1.6", - "resolved": "https://registry.npmjs.org/@types/chai-as-promised/-/chai-as-promised-7.1.6.tgz", - "integrity": "sha512-cQLhk8fFarRVZAXUQV1xEnZgMoPxqKojBvRkqPCKPQCzEhpbbSKl1Uu75kDng7k5Ln6LQLUmNBjLlFthCgm1NA==", - "dev": true, - "dependencies": { - "@types/chai": "*" - } - }, - "node_modules/@types/estree": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.6.tgz", - "integrity": "sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw==", - "dev": true, - "license": "MIT" - }, - "node_modules/@types/glob": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/@types/glob/-/glob-7.2.0.tgz", - "integrity": "sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA==", - "dev": true, - "dependencies": { - "@types/minimatch": "*", - "@types/node": "*" - } - }, - "node_modules/@types/http-cache-semantics": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@types/http-cache-semantics/-/http-cache-semantics-4.0.4.tgz", - "integrity": "sha512-1m0bIFVc7eJWyve9S0RnuRgcQqF/Xd5QsUZAZeQFr1Q3/p9JWoQQEqmVy+DPTNpGXwhgIetAoYF8JSc33q29QA==", - "dev": true - }, - "node_modules/@types/is-ci": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@types/is-ci/-/is-ci-3.0.0.tgz", - "integrity": "sha512-Q0Op0hdWbYd1iahB+IFNQcWXFq4O0Q5MwQP7uN0souuQ4rPg1vEYcnIOfr1gY+M+6rc8FGoRaBO1mOOvL29sEQ==", - "dev": true, - "dependencies": { - "ci-info": "^3.1.0" - } - }, - "node_modules/@types/json-schema": { - "version": "7.0.15", - "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", - "integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==", - "dev": true, - "license": "MIT" - }, - "node_modules/@types/lru-cache": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/@types/lru-cache/-/lru-cache-5.1.1.tgz", - "integrity": "sha512-ssE3Vlrys7sdIzs5LOxCzTVMsU7i9oa/IaW92wF32JFb3CVczqOkru2xspuKczHEbG3nvmPY7IFqVmGGHdNbYw==", - "dev": true - }, - "node_modules/@types/minimatch": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/@types/minimatch/-/minimatch-5.1.2.tgz", - "integrity": "sha512-K0VQKziLUWkVKiRVrx4a40iPaxTUefQmjtkQofBkYRcoaaL/8rhwDWww9qWbrgicNOgnpIsMxyNIUM4+n6dUIA==", - "dev": true - }, - "node_modules/@types/minimist": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/@types/minimist/-/minimist-1.2.2.tgz", - "integrity": "sha512-jhuKLIRrhvCPLqwPcx6INqmKeiA5EWrsCOPhrlFSrbrmU4ZMPjj5Ul/oLCMDO98XRUIwVm78xICz4EPCektzeQ==", - "dev": true - }, - "node_modules/@types/node": { - "version": "20.9.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-20.9.0.tgz", - "integrity": "sha512-nekiGu2NDb1BcVofVcEKMIwzlx4NjHlcjhoxxKBNLtz15Y1z7MYf549DFvkHSId02Ax6kGwWntIBPC3l/JZcmw==", - "dev": true, - "dependencies": { - "undici-types": "~5.26.4" - } - }, - "node_modules/@types/normalize-package-data": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/@types/normalize-package-data/-/normalize-package-data-2.4.1.tgz", - "integrity": "sha512-Gj7cI7z+98M282Tqmp2K5EIsoouUEzbBJhQQzDE3jSIRk6r9gsz0oUokqIUR4u1R3dMHo0pDHM7sNOHyhulypw==", - "dev": true - }, - "node_modules/@types/pbkdf2": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/@types/pbkdf2/-/pbkdf2-3.1.0.tgz", - "integrity": "sha512-Cf63Rv7jCQ0LaL8tNXmEyqTHuIJxRdlS5vMh1mj5voN4+QFhVZnlZruezqpWYDiJ8UTzhP0VmeLXCmBk66YrMQ==", - "dev": true, - "dependencies": { - "@types/node": "*" - } - }, - "node_modules/@types/secp256k1": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/@types/secp256k1/-/secp256k1-4.0.3.tgz", - "integrity": "sha512-Da66lEIFeIz9ltsdMZcpQvmrmmoqrfju8pm1BH8WbYjZSwUgCwXLb9C+9XYogwBITnbsSaMdVPb2ekf7TV+03w==", - "dev": true, - "dependencies": { - "@types/node": "*" - } - }, - "node_modules/@types/semver": { - "version": "7.5.2", - "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.2.tgz", - "integrity": "sha512-7aqorHYgdNO4DM36stTiGO3DvKoex9TQRwsJU6vMaFGyqpBA1MNZkz+PG3gaNUPpTAOYhT1WR7M1JyA3fbS9Cw==", - "dev": true - }, - "node_modules/abbrev": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.9.tgz", - "integrity": "sha512-LEyx4aLEC3x6T0UguF6YILf+ntvmOaWsVfENmIW0E9H09vKlLDGelMjjSm0jkDHALj8A8quZ/HapKNigzwge+Q==", - "dev": true - }, - "node_modules/abitype": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/abitype/-/abitype-1.0.0.tgz", - "integrity": "sha512-NMeMah//6bJ56H5XRj8QCV4AwuW6hB6zqz2LnhhLdcWVQOsXki6/Pn3APeqxCma62nXIcmZWdu1DlHWS74umVQ==", - "dev": true, - "funding": { - "url": "https://github.com/sponsors/wevm" - }, - "peerDependencies": { - "typescript": ">=5.0.4", - "zod": "^3 >=3.22.0" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - }, - "zod": { - "optional": true - } - } - }, - "node_modules/acorn": { - "version": "8.13.0", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.13.0.tgz", - "integrity": "sha512-8zSiw54Oxrdym50NlZ9sUusyO1Z1ZchgRLWRaK6c86XJFClyCgFKetdowBg5bKxyp/u+CDBJG4Mpp0m3HLZl9w==", - "dev": true, - "license": "MIT", - "bin": { - "acorn": "bin/acorn" - }, - "engines": { - "node": ">=0.4.0" - } - }, - "node_modules/acorn-jsx": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", - "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", - "dev": true, - "license": "MIT", - "peerDependencies": { - "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" - } - }, - "node_modules/adm-zip": { - "version": "0.4.16", - "resolved": "https://registry.npmjs.org/adm-zip/-/adm-zip-0.4.16.tgz", - "integrity": "sha512-TFi4HBKSGfIKsK5YCkKaaFG2m4PEDyViZmEwof3MTIgzimHLto6muaHVpbrljdIvIrFZzEq/p4nafOeLcYegrg==", - "dev": true, - "engines": { - "node": ">=0.3.0" - } - }, - "node_modules/agent-base": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz", - "integrity": "sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==", - "dev": true, - "dependencies": { - "debug": "4" - }, - "engines": { - "node": ">= 6.0.0" - } - }, - "node_modules/aggregate-error": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.1.0.tgz", - "integrity": "sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==", - "dev": true, - "dependencies": { - "clean-stack": "^2.0.0", - "indent-string": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/ajv": { - "version": "6.12.6", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", - "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", - "dev": true, - "dependencies": { - "fast-deep-equal": "^3.1.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/amdefine": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/amdefine/-/amdefine-1.0.1.tgz", - "integrity": "sha512-S2Hw0TtNkMJhIabBwIojKL9YHO5T0n5eNqWJ7Lrlel/zDbftQpxpapi8tZs3X1HWa+u+QeydGmzzNU0m09+Rcg==", - "dev": true, - "optional": true, - "engines": { - "node": ">=0.4.2" - } - }, - "node_modules/ansi-align": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/ansi-align/-/ansi-align-3.0.1.tgz", - "integrity": "sha512-IOfwwBF5iczOjp/WeY4YxyjqAFMQoZufdQWDd19SEExbVLNXqvpzSJ/M7Za4/sCPmQ0+GRquoA7bGcINcxew6w==", - "dev": true, - "dependencies": { - "string-width": "^4.1.0" - } - }, - "node_modules/ansi-align/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/ansi-align/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/ansi-colors": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.3.tgz", - "integrity": "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/ansi-escapes": { - "version": "4.3.2", - "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", - "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", - "dev": true, - "dependencies": { - "type-fest": "^0.21.3" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/ansi-escapes/node_modules/type-fest": { - "version": "0.21.3", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", - "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "dev": true, - "dependencies": { - "color-convert": "^1.9.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/antlr4": { - "version": "4.13.1", - "resolved": "https://registry.npmjs.org/antlr4/-/antlr4-4.13.1.tgz", - "integrity": "sha512-kiXTspaRYvnIArgE97z5YVVf/cDVQABr3abFRR6mE7yesLMkgu4ujuyV/sgxafQ8wgve0DJQUJ38Z8tkgA2izA==", - "dev": true, - "engines": { - "node": ">=16" - } - }, - "node_modules/antlr4ts": { - "version": "0.5.0-alpha.4", - "resolved": "https://registry.npmjs.org/antlr4ts/-/antlr4ts-0.5.0-alpha.4.tgz", - "integrity": "sha512-WPQDt1B74OfPv/IMS2ekXAKkTZIHl88uMetg6q3OTqgFxZ/dxDXI0EWLyZid/1Pe6hTftyg5N7gel5wNAGxXyQ==", - "dev": true - }, - "node_modules/anymatch": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", - "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", - "dev": true, - "dependencies": { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/argparse": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", - "dev": true, - "dependencies": { - "sprintf-js": "~1.0.2" - } - }, - "node_modules/array-buffer-byte-length": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz", - "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "is-array-buffer": "^3.0.1" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array-union": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", - "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/array.prototype.findlast": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/array.prototype.findlast/-/array.prototype.findlast-1.2.3.tgz", - "integrity": "sha512-kcBubumjciBg4JKp5KTKtI7ec7tRefPk88yjkWJwaVKYd9QfTaxcsOxoMNKd7iBr447zCfDV0z1kOF47umv42g==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1", - "es-shim-unscopables": "^1.0.0", - "get-intrinsic": "^1.2.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array.prototype.flat": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.3.2.tgz", - "integrity": "sha512-djYB+Zx2vLewY8RWlNCUdHjDXs2XOgm602S9E7P/UpHgfeHL00cRiIF+IN/G/aUJ7kGPb6yO/ErDI5V2s8iycA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1", - "es-shim-unscopables": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/arraybuffer.prototype.slice": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.2.tgz", - "integrity": "sha512-yMBKppFur/fbHu9/6USUe03bZ4knMYiwFBcyiaXB8Go0qNehwX6inYPzK9U0NeQvGxKthcmHcaR8P5MStSRBAw==", - "dev": true, - "dependencies": { - "array-buffer-byte-length": "^1.0.0", - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1", - "get-intrinsic": "^1.2.1", - "is-array-buffer": "^3.0.2", - "is-shared-array-buffer": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/arrify": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/arrify/-/arrify-1.0.1.tgz", - "integrity": "sha512-3CYzex9M9FGQjCGMGyi6/31c8GJbgb0qGyrx5HWxPd0aCwh4cB2YjMb2Xf9UuoogrMrlO9cTqnB5rI5GHZTcUA==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/assertion-error": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", - "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==", - "dev": true, - "engines": { - "node": "*" - } - }, - "node_modules/ast-parents": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/ast-parents/-/ast-parents-0.0.1.tgz", - "integrity": "sha512-XHusKxKz3zoYk1ic8Un640joHbFMhbqneyoZfoKnEGtf2ey9Uh/IdpcQplODdO/kENaMIWsD0nJm4+wX3UNLHA==", - "dev": true - }, - "node_modules/astral-regex": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-2.0.0.tgz", - "integrity": "sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/async": { - "version": "1.5.2", - "resolved": "https://registry.npmjs.org/async/-/async-1.5.2.tgz", - "integrity": "sha512-nSVgobk4rv61R9PUSDtYt7mPVB2olxNR5RWJcAsH676/ef11bUZwvu7+RGYrYauVdDPcO519v68wRhXQtxsV9w==", - "dev": true - }, - "node_modules/asynckit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", - "dev": true, - "license": "MIT" - }, - "node_modules/available-typed-arrays": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", - "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==", - "dev": true, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/axios": { - "version": "1.15.2", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.15.2.tgz", - "integrity": "sha512-wLrXxPtcrPTsNlJmKjkPnNPK2Ihe0hn0wGSaTEiHRPxwjvJwT3hKmXF4dpqxmPO9SoNb2FsYXj/xEo0gHN+D5A==", - "dev": true, - "license": "MIT", - "dependencies": { - "follow-redirects": "^1.15.11", - "form-data": "^4.0.5", - "proxy-from-env": "^2.1.0" - } - }, - "node_modules/balanced-match": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", - "dev": true - }, - "node_modules/base-x": { - "version": "3.0.9", - "resolved": "https://registry.npmjs.org/base-x/-/base-x-3.0.9.tgz", - "integrity": "sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ==", - "dev": true, - "dependencies": { - "safe-buffer": "^5.0.1" - } - }, - "node_modules/better-path-resolve": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/better-path-resolve/-/better-path-resolve-1.0.0.tgz", - "integrity": "sha512-pbnl5XzGBdrFU/wT4jqmJVPn2B6UHPBOhzMQkY/SPUPB6QtUXtmBHBIwCbXJol93mOpGMnQyP/+BB19q04xj7g==", - "dev": true, - "dependencies": { - "is-windows": "^1.0.0" - }, - "engines": { - "node": ">=4" - } - }, - "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==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/blakejs": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/blakejs/-/blakejs-1.2.1.tgz", - "integrity": "sha512-QXUSXI3QVc/gJME0dBpXrag1kbzOqCjCX8/b54ntNyW6sjtoqxqRk3LTmXzaJoh71zMsDCjM+47jS7XiwN/+fQ==", - "dev": true - }, - "node_modules/bn.js": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", - "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==", - "dev": true - }, - "node_modules/boxen": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/boxen/-/boxen-5.1.2.tgz", - "integrity": "sha512-9gYgQKXx+1nP8mP7CzFyaUARhg7D3n1dF/FnErWmu9l6JvGpNUN278h0aSb+QjoiKSWG+iZ3uHrcqk0qrY9RQQ==", - "dev": true, - "dependencies": { - "ansi-align": "^3.0.0", - "camelcase": "^6.2.0", - "chalk": "^4.1.0", - "cli-boxes": "^2.2.1", - "string-width": "^4.2.2", - "type-fest": "^0.20.2", - "widest-line": "^3.1.0", - "wrap-ansi": "^7.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/boxen/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/boxen/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/boxen/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/boxen/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/boxen/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/boxen/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/boxen/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/boxen/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/brace-expansion": { - "version": "1.1.14", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.14.tgz", - "integrity": "sha512-MWPGfDxnyzKU7rNOW9SP/c50vi3xrmrua/+6hfPbCS2ABNWfx24vPidzvC7krjU/RTo235sV776ymlsMtGKj8g==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "node_modules/braces": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", - "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", - "dev": true, - "dependencies": { - "fill-range": "^7.1.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/breakword": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/breakword/-/breakword-1.0.6.tgz", - "integrity": "sha512-yjxDAYyK/pBvws9H4xKYpLDpYKEH6CzrBPAuXq3x18I+c/2MkVtT3qAr7Oloi6Dss9qNhPVueAAVU1CSeNDIXw==", - "dev": true, - "dependencies": { - "wcwidth": "^1.0.1" - } - }, - "node_modules/brorand": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", - "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==", - "dev": true - }, - "node_modules/brotli-wasm": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/brotli-wasm/-/brotli-wasm-2.0.1.tgz", - "integrity": "sha512-+3USgYsC7bzb5yU0/p2HnnynZl0ak0E6uoIm4UW4Aby/8s8HFCq6NCfrrf1E9c3O8OCSzq3oYO1tUVqIi61Nww==", - "dev": true - }, - "node_modules/browser-stdout": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", - "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==", - "dev": true - }, - "node_modules/browserify-aes": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/browserify-aes/-/browserify-aes-1.2.0.tgz", - "integrity": "sha512-+7CHXqGuspUn/Sl5aO7Ea0xWGAtETPXNSAjHo48JfLdPWcMng33Xe4znFvQweqc/uzk5zSOI3H52CYnjCfb5hA==", - "dev": true, - "dependencies": { - "buffer-xor": "^1.0.3", - "cipher-base": "^1.0.0", - "create-hash": "^1.1.0", - "evp_bytestokey": "^1.0.3", - "inherits": "^2.0.1", - "safe-buffer": "^5.0.1" - } - }, - "node_modules/bs58": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", - "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", - "dev": true, - "dependencies": { - "base-x": "^3.0.2" - } - }, - "node_modules/bs58check": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", - "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", - "dev": true, - "dependencies": { - "bs58": "^4.0.0", - "create-hash": "^1.1.0", - "safe-buffer": "^5.1.2" - } - }, - "node_modules/buffer-from": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", - "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", - "dev": true - }, - "node_modules/buffer-xor": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/buffer-xor/-/buffer-xor-1.0.3.tgz", - "integrity": "sha512-571s0T7nZWK6vB67HI5dyUF7wXiNcfaPPPTl6zYCNApANjIvYJTg7hlud/+cJpdAhS7dVzqMLmfhfHR3rAcOjQ==", - "dev": true - }, - "node_modules/bytes": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", - "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==", - "dev": true, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/cacheable-lookup": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/cacheable-lookup/-/cacheable-lookup-7.0.0.tgz", - "integrity": "sha512-+qJyx4xiKra8mZrcwhjMRMUhD5NR1R8esPkzIYxX96JiecFoxAXFuz/GpR3+ev4PE1WamHip78wV0vcmPQtp8w==", - "dev": true, - "engines": { - "node": ">=14.16" - } - }, - "node_modules/cacheable-request": { - "version": "10.2.14", - "resolved": "https://registry.npmjs.org/cacheable-request/-/cacheable-request-10.2.14.tgz", - "integrity": "sha512-zkDT5WAF4hSSoUgyfg5tFIxz8XQK+25W/TLVojJTMKBaxevLBBtLxgqguAuVQB8PVW79FVjHcU+GJ9tVbDZ9mQ==", - "dev": true, - "dependencies": { - "@types/http-cache-semantics": "^4.0.2", - "get-stream": "^6.0.1", - "http-cache-semantics": "^4.1.1", - "keyv": "^4.5.3", - "mimic-response": "^4.0.0", - "normalize-url": "^8.0.0", - "responselike": "^3.0.0" - }, - "engines": { - "node": ">=14.16" - } - }, - "node_modules/call-bind": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.7.tgz", - "integrity": "sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==", - "dev": true, - "dependencies": { - "es-define-property": "^1.0.0", - "es-errors": "^1.3.0", - "function-bind": "^1.1.2", - "get-intrinsic": "^1.2.4", - "set-function-length": "^1.2.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/call-bind-apply-helpers": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz", - "integrity": "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "function-bind": "^1.1.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/callsites": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", - "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/camelcase": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", - "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/camelcase-keys": { - "version": "6.2.2", - "resolved": "https://registry.npmjs.org/camelcase-keys/-/camelcase-keys-6.2.2.tgz", - "integrity": "sha512-YrwaA0vEKazPBkn0ipTiMpSajYDSe+KjQfrjhcBMxJt/znbvlHd8Pw/Vamaz5EB4Wfhs3SUR3Z9mwRu/P3s3Yg==", - "dev": true, - "dependencies": { - "camelcase": "^5.3.1", - "map-obj": "^4.0.0", - "quick-lru": "^4.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/camelcase-keys/node_modules/camelcase": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/cbor": { - "version": "9.0.1", - "resolved": "https://registry.npmjs.org/cbor/-/cbor-9.0.1.tgz", - "integrity": "sha512-/TQOWyamDxvVIv+DY9cOLNuABkoyz8K/F3QE56539pGVYohx0+MEA1f4lChFTX79dBTBS7R1PF6ovH7G+VtBfQ==", - "dev": true, - "dependencies": { - "nofilter": "^3.1.0" - }, - "engines": { - "node": ">=16" - } - }, - "node_modules/chai": { - "version": "4.3.8", - "resolved": "https://registry.npmjs.org/chai/-/chai-4.3.8.tgz", - "integrity": "sha512-vX4YvVVtxlfSZ2VecZgFUTU5qPCYsobVI2O9FmwEXBhDigYGQA6jRXCycIs1yJnnWbZ6/+a2zNIF5DfVCcJBFQ==", - "dev": true, - "dependencies": { - "assertion-error": "^1.1.0", - "check-error": "^1.0.2", - "deep-eql": "^4.1.2", - "get-func-name": "^2.0.0", - "loupe": "^2.3.1", - "pathval": "^1.1.1", - "type-detect": "^4.0.5" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/chai-as-promised": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/chai-as-promised/-/chai-as-promised-7.1.1.tgz", - "integrity": "sha512-azL6xMoi+uxu6z4rhWQ1jbdUhOMhis2PvscD/xjLqNMkv3BPPp2JyyuTHOrf9BOosGpNQ11v6BKv/g57RXbiaA==", - "dev": true, - "dependencies": { - "check-error": "^1.0.2" - }, - "peerDependencies": { - "chai": ">= 2.1.2 < 5" - } - }, - "node_modules/chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "dev": true, - "dependencies": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/chardet": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz", - "integrity": "sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==", - "dev": true - }, - "node_modules/charenc": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/charenc/-/charenc-0.0.2.tgz", - "integrity": "sha512-yrLQ/yVUFXkzg7EDQsPieE/53+0RlaWTs+wBrvW36cyilJ2SaDWfl4Yj7MtLTXleV9uEKefbAGUPv2/iWSooRA==", - "dev": true, - "engines": { - "node": "*" - } - }, - "node_modules/check-error": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", - "integrity": "sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA==", - "dev": true, - "engines": { - "node": "*" - } - }, - "node_modules/chokidar": { - "version": "3.5.3", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz", - "integrity": "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://paulmillr.com/funding/" - } - ], - "dependencies": { - "anymatch": "~3.1.2", - "braces": "~3.0.2", - "glob-parent": "~5.1.2", - "is-binary-path": "~2.1.0", - "is-glob": "~4.0.1", - "normalize-path": "~3.0.0", - "readdirp": "~3.6.0" - }, - "engines": { - "node": ">= 8.10.0" - }, - "optionalDependencies": { - "fsevents": "~2.3.2" - } - }, - "node_modules/ci-info": { - "version": "3.8.0", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.8.0.tgz", - "integrity": "sha512-eXTggHWSooYhq49F2opQhuHWgzucfF2YgODK4e1566GQs5BIfP30B0oenwBJHfWxAs2fyPB1s7Mg949zLf61Yw==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/sibiraj-s" - } - ], - "engines": { - "node": ">=8" - } - }, - "node_modules/cipher-base": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/cipher-base/-/cipher-base-1.0.4.tgz", - "integrity": "sha512-Kkht5ye6ZGmwv40uUDZztayT2ThLQGfnj/T71N/XzeZeo3nf8foyW7zGTsPYkEya3m5f3cAypH+qe7YOrM1U2Q==", - "dev": true, - "dependencies": { - "inherits": "^2.0.1", - "safe-buffer": "^5.0.1" - } - }, - "node_modules/clean-stack": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz", - "integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/cli-boxes": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/cli-boxes/-/cli-boxes-2.2.1.tgz", - "integrity": "sha512-y4coMcylgSCdVinjiDBuR8PCC2bLjyGTwEmPb9NHR/QaNU6EUOXcTY/s6VjGMD6ENSEaeQYHCY0GNGS5jfMwPw==", - "dev": true, - "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/cliui": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", - "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", - "dev": true, - "dependencies": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.1", - "wrap-ansi": "^7.0.0" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/cliui/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/cliui/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/clone": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", - "integrity": "sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg==", - "dev": true, - "engines": { - "node": ">=0.8" - } - }, - "node_modules/color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", - "dev": true, - "dependencies": { - "color-name": "1.1.3" - } - }, - "node_modules/color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", - "dev": true - }, - "node_modules/combined-stream": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", - "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", - "dev": true, - "license": "MIT", - "dependencies": { - "delayed-stream": "~1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/command-exists": { - "version": "1.2.9", - "resolved": "https://registry.npmjs.org/command-exists/-/command-exists-1.2.9.tgz", - "integrity": "sha512-LTQ/SGc+s0Xc0Fu5WaKnR0YiygZkm9eKFvyS+fRsU7/ZWFF8ykFM6Pc9aCVf1+xasOOZpO3BAVgVrKvsqKHV7w==", - "dev": true - }, - "node_modules/commander": { - "version": "10.0.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-10.0.1.tgz", - "integrity": "sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==", - "dev": true, - "engines": { - "node": ">=14" - } - }, - "node_modules/compare-versions": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/compare-versions/-/compare-versions-6.1.0.tgz", - "integrity": "sha512-LNZQXhqUvqUTotpZ00qLSaify3b4VFD588aRr8MKFw4CMUr98ytzCW5wDH5qx/DEY5kCDXcbcRuCqL0szEf2tg==", - "dev": true - }, - "node_modules/concat-map": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==", - "dev": true - }, - "node_modules/config-chain": { - "version": "1.1.13", - "resolved": "https://registry.npmjs.org/config-chain/-/config-chain-1.1.13.tgz", - "integrity": "sha512-qj+f8APARXHrM0hraqXYb2/bOVSV4PvJQlNZ/DVj0QrmNM2q2euizkeuVckQ57J+W0mRH6Hvi+k50M4Jul2VRQ==", - "dev": true, - "dependencies": { - "ini": "^1.3.4", - "proto-list": "~1.2.1" - } - }, - "node_modules/cookie": { - "version": "0.4.2", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.4.2.tgz", - "integrity": "sha512-aSWTXFzaKWkvHO1Ny/s+ePFpvKsPnjc551iI41v3ny/ow6tBG5Vd+FuqGNhh1LxOmVzOlGUriIlOaokOvhaStA==", - "dev": true, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/cosmiconfig": { - "version": "8.3.6", - "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-8.3.6.tgz", - "integrity": "sha512-kcZ6+W5QzcJ3P1Mt+83OUv/oHFqZHIx8DuxG6eZ5RGMERoLqp4BuGjhHLYGK+Kf5XVkQvqBSmAy/nGWN3qDgEA==", - "dev": true, - "dependencies": { - "import-fresh": "^3.3.0", - "js-yaml": "^4.1.0", - "parse-json": "^5.2.0", - "path-type": "^4.0.0" - }, - "engines": { - "node": ">=14" - }, - "funding": { - "url": "https://github.com/sponsors/d-fischer" - }, - "peerDependencies": { - "typescript": ">=4.9.5" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } - } - }, - "node_modules/cosmiconfig/node_modules/argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "dev": true - }, - "node_modules/cosmiconfig/node_modules/js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", - "dev": true, - "dependencies": { - "argparse": "^2.0.1" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, - "node_modules/create-hash": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/create-hash/-/create-hash-1.2.0.tgz", - "integrity": "sha512-z00bCGNHDG8mHAkP7CtT1qVu+bFQUPjYq/4Iv3C3kWjTFV10zIjfSoeqXo9Asws8gwSHDGj/hl2u4OGIjapeCg==", - "dev": true, - "dependencies": { - "cipher-base": "^1.0.1", - "inherits": "^2.0.1", - "md5.js": "^1.3.4", - "ripemd160": "^2.0.1", - "sha.js": "^2.4.0" - } - }, - "node_modules/create-hmac": { - "version": "1.1.7", - "resolved": "https://registry.npmjs.org/create-hmac/-/create-hmac-1.1.7.tgz", - "integrity": "sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg==", - "dev": true, - "dependencies": { - "cipher-base": "^1.0.3", - "create-hash": "^1.1.0", - "inherits": "^2.0.1", - "ripemd160": "^2.0.0", - "safe-buffer": "^5.0.1", - "sha.js": "^2.4.8" - } - }, - "node_modules/cross-spawn": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", - "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", - "dev": true, - "dependencies": { - "path-key": "^3.1.0", - "shebang-command": "^2.0.0", - "which": "^2.0.1" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/crypt": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/crypt/-/crypt-0.0.2.tgz", - "integrity": "sha512-mCxBlsHFYh9C+HVpiEacem8FEBnMXgU9gy4zmNC+SXAZNB/1idgp/aulFJ4FgCi7GPEVbfyng092GqL2k2rmow==", - "dev": true, - "engines": { - "node": "*" - } - }, - "node_modules/csv": { - "version": "5.5.3", - "resolved": "https://registry.npmjs.org/csv/-/csv-5.5.3.tgz", - "integrity": "sha512-QTaY0XjjhTQOdguARF0lGKm5/mEq9PD9/VhZZegHDIBq2tQwgNpHc3dneD4mGo2iJs+fTKv5Bp0fZ+BRuY3Z0g==", - "dev": true, - "dependencies": { - "csv-generate": "^3.4.3", - "csv-parse": "^4.16.3", - "csv-stringify": "^5.6.5", - "stream-transform": "^2.1.3" - }, - "engines": { - "node": ">= 0.1.90" - } - }, - "node_modules/csv-generate": { - "version": "3.4.3", - "resolved": "https://registry.npmjs.org/csv-generate/-/csv-generate-3.4.3.tgz", - "integrity": "sha512-w/T+rqR0vwvHqWs/1ZyMDWtHHSJaN06klRqJXBEpDJaM/+dZkso0OKh1VcuuYvK3XM53KysVNq8Ko/epCK8wOw==", - "dev": true - }, - "node_modules/csv-parse": { - "version": "4.16.3", - "resolved": "https://registry.npmjs.org/csv-parse/-/csv-parse-4.16.3.tgz", - "integrity": "sha512-cO1I/zmz4w2dcKHVvpCr7JVRu8/FymG5OEpmvsZYlccYolPBLoVGKUHgNoc4ZGkFeFlWGEDmMyBM+TTqRdW/wg==", - "dev": true - }, - "node_modules/csv-stringify": { - "version": "5.6.5", - "resolved": "https://registry.npmjs.org/csv-stringify/-/csv-stringify-5.6.5.tgz", - "integrity": "sha512-PjiQ659aQ+fUTQqSrd1XEDnOr52jh30RBurfzkscaE2tPaFsDH5wOAHJiw8XAHphRknCwMUE9KRayc4K/NbO8A==", - "dev": true - }, - "node_modules/dataloader": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/dataloader/-/dataloader-1.4.0.tgz", - "integrity": "sha512-68s5jYdlvasItOJnCuI2Q9s4q98g0pCyL3HrcKJu8KNugUl8ahgmZYg38ysLTgQjjXX3H8CJLkAvWrclWfcalw==", - "dev": true - }, - "node_modules/death": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/death/-/death-1.1.0.tgz", - "integrity": "sha512-vsV6S4KVHvTGxbEcij7hkWRv0It+sGGWVOM67dQde/o5Xjnr+KmLjxWJii2uEObIrt1CcM9w0Yaovx+iOlIL+w==", - "dev": true - }, - "node_modules/debug": { - "version": "4.4.3", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.3.tgz", - "integrity": "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==", - "dev": true, - "license": "MIT", - "dependencies": { - "ms": "^2.1.3" - }, - "engines": { - "node": ">=6.0" - }, - "peerDependenciesMeta": { - "supports-color": { - "optional": true - } - } - }, - "node_modules/decamelize": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", - "integrity": "sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/decamelize-keys": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/decamelize-keys/-/decamelize-keys-1.1.1.tgz", - "integrity": "sha512-WiPxgEirIV0/eIOMcnFBA3/IJZAZqKnwAwWyvvdi4lsr1WCN22nhdf/3db3DoZcUjTV2SqfzIwNyp6y2xs3nmg==", - "dev": true, - "dependencies": { - "decamelize": "^1.1.0", - "map-obj": "^1.0.0" - }, - "engines": { - "node": ">=0.10.0" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/decamelize-keys/node_modules/map-obj": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-1.0.1.tgz", - "integrity": "sha512-7N/q3lyZ+LVCp7PzuxrJr4KMbBE2hW7BT7YNia330OFxIf4d3r5zVpicP2650l7CPN6RM9zOJRl3NGpqSiw3Eg==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/decompress-response": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-6.0.0.tgz", - "integrity": "sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==", - "dev": true, - "dependencies": { - "mimic-response": "^3.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/decompress-response/node_modules/mimic-response": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-3.1.0.tgz", - "integrity": "sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/deep-eql": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-4.1.3.tgz", - "integrity": "sha512-WaEtAOpRA1MQ0eohqZjpGD8zdI0Ovsm8mmFhaDN8dvDZzyoUMcYDnf5Y6iu7HTXxf8JDS23qWa4a+hKCDyOPzw==", - "dev": true, - "dependencies": { - "type-detect": "^4.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/deep-extend": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", - "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", - "dev": true, - "engines": { - "node": ">=4.0.0" - } - }, - "node_modules/deep-is": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", - "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==", - "dev": true - }, - "node_modules/defaults": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/defaults/-/defaults-1.0.4.tgz", - "integrity": "sha512-eFuaLoy/Rxalv2kr+lqMlUnrDWV+3j4pljOIJgLIhI058IQfWJ7vXhyEIHu+HtC738klGALYxOKDO0bQP3tg8A==", - "dev": true, - "dependencies": { - "clone": "^1.0.2" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/defer-to-connect": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/defer-to-connect/-/defer-to-connect-2.0.1.tgz", - "integrity": "sha512-4tvttepXG1VaYGrRibk5EwJd1t4udunSOVMdLSAL6mId1ix438oPwPZMALY41FCijukO1L0twNcGsdzS7dHgDg==", - "dev": true, - "engines": { - "node": ">=10" - } - }, - "node_modules/define-data-property": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", - "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", - "dev": true, - "dependencies": { - "es-define-property": "^1.0.0", - "es-errors": "^1.3.0", - "gopd": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/define-properties": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", - "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", - "dev": true, - "dependencies": { - "define-data-property": "^1.0.1", - "has-property-descriptors": "^1.0.0", - "object-keys": "^1.1.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/delayed-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", - "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.4.0" - } - }, - "node_modules/depd": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", - "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", - "dev": true, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/detect-indent": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/detect-indent/-/detect-indent-6.1.0.tgz", - "integrity": "sha512-reYkTUJAZb9gUuZ2RvVCNhVHdg62RHnJ7WJl8ftMi4diZ6NWlciOzQN88pUhSELEwflJht4oQDv0F0BMlwaYtA==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/diff": { - "version": "5.2.2", - "resolved": "https://registry.npmjs.org/diff/-/diff-5.2.2.tgz", - "integrity": "sha512-vtcDfH3TOjP8UekytvnHH1o1P4FcUdt4eQ1Y+Abap1tk/OB2MWQvcwS2ClCd1zuIhc3JKOx6p3kod8Vfys3E+A==", - "dev": true, - "license": "BSD-3-Clause", - "engines": { - "node": ">=0.3.1" - } - }, - "node_modules/difflib": { - "version": "0.2.4", - "resolved": "https://registry.npmjs.org/difflib/-/difflib-0.2.4.tgz", - "integrity": "sha512-9YVwmMb0wQHQNr5J9m6BSj6fk4pfGITGQOOs+D9Fl+INODWFOfvhIU1hNv6GgR1RBoC/9NJcwu77zShxV0kT7w==", - "dev": true, - "dependencies": { - "heap": ">= 0.2.0" - }, - "engines": { - "node": "*" - } - }, - "node_modules/dir-glob": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", - "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==", - "dev": true, - "dependencies": { - "path-type": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/dotenv": { - "version": "8.6.0", - "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-8.6.0.tgz", - "integrity": "sha512-IrPdXQsk2BbzvCBGBOTmmSH5SodmqZNt4ERAZDmW4CT+tL8VtvinqywuANaFu4bOMWki16nqf0e4oC0QIaDr/g==", - "dev": true, - "engines": { - "node": ">=10" - } - }, - "node_modules/dunder-proto": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz", - "integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind-apply-helpers": "^1.0.1", - "es-errors": "^1.3.0", - "gopd": "^1.2.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/eastasianwidth": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/eastasianwidth/-/eastasianwidth-0.2.0.tgz", - "integrity": "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==", - "dev": true - }, - "node_modules/elliptic": { - "version": "6.5.4", - "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz", - "integrity": "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==", - "dev": true, - "dependencies": { - "bn.js": "^4.11.9", - "brorand": "^1.1.0", - "hash.js": "^1.0.0", - "hmac-drbg": "^1.0.1", - "inherits": "^2.0.4", - "minimalistic-assert": "^1.0.1", - "minimalistic-crypto-utils": "^1.0.1" - } - }, - "node_modules/emoji-regex": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", - "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", - "dev": true - }, - "node_modules/enquirer": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/enquirer/-/enquirer-2.4.1.tgz", - "integrity": "sha512-rRqJg/6gd538VHvR3PSrdRBb/1Vy2YfzHqzvbhGIQpDRKIa4FgV/54b5Q1xYSxOOwKvjXweS26E0Q+nAMwp2pQ==", - "dev": true, - "dependencies": { - "ansi-colors": "^4.1.1", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8.6" - } - }, - "node_modules/env-paths": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz", - "integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/error-ex": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", - "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", - "dev": true, - "dependencies": { - "is-arrayish": "^0.2.1" - } - }, - "node_modules/es-abstract": { - "version": "1.22.2", - "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.2.tgz", - "integrity": "sha512-YoxfFcDmhjOgWPWsV13+2RNjq1F6UQnfs+8TftwNqtzlmFzEXvlUwdrNrYeaizfjQzRMxkZ6ElWMOJIFKdVqwA==", - "dev": true, - "dependencies": { - "array-buffer-byte-length": "^1.0.0", - "arraybuffer.prototype.slice": "^1.0.2", - "available-typed-arrays": "^1.0.5", - "call-bind": "^1.0.2", - "es-set-tostringtag": "^2.0.1", - "es-to-primitive": "^1.2.1", - "function.prototype.name": "^1.1.6", - "get-intrinsic": "^1.2.1", - "get-symbol-description": "^1.0.0", - "globalthis": "^1.0.3", - "gopd": "^1.0.1", - "has": "^1.0.3", - "has-property-descriptors": "^1.0.0", - "has-proto": "^1.0.1", - "has-symbols": "^1.0.3", - "internal-slot": "^1.0.5", - "is-array-buffer": "^3.0.2", - "is-callable": "^1.2.7", - "is-negative-zero": "^2.0.2", - "is-regex": "^1.1.4", - "is-shared-array-buffer": "^1.0.2", - "is-string": "^1.0.7", - "is-typed-array": "^1.1.12", - "is-weakref": "^1.0.2", - "object-inspect": "^1.12.3", - "object-keys": "^1.1.1", - "object.assign": "^4.1.4", - "regexp.prototype.flags": "^1.5.1", - "safe-array-concat": "^1.0.1", - "safe-regex-test": "^1.0.0", - "string.prototype.trim": "^1.2.8", - "string.prototype.trimend": "^1.0.7", - "string.prototype.trimstart": "^1.0.7", - "typed-array-buffer": "^1.0.0", - "typed-array-byte-length": "^1.0.0", - "typed-array-byte-offset": "^1.0.0", - "typed-array-length": "^1.0.4", - "unbox-primitive": "^1.0.2", - "which-typed-array": "^1.1.11" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/es-define-property": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz", - "integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-errors": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", - "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", - "dev": true, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-object-atoms": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.1.tgz", - "integrity": "sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==", - "dev": true, - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-set-tostringtag": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.1.0.tgz", - "integrity": "sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA==", - "dev": true, - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.6", - "has-tostringtag": "^1.0.2", - "hasown": "^2.0.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-shim-unscopables": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/es-shim-unscopables/-/es-shim-unscopables-1.0.0.tgz", - "integrity": "sha512-Jm6GPcCdC30eMLbZ2x8z2WuRwAws3zTBBKuusffYVUrNj/GVSUAZ+xKMaUpfNDR5IbyNA5LJbaecoUVbmUcB1w==", - "dev": true, - "dependencies": { - "has": "^1.0.3" - } - }, - "node_modules/es-to-primitive": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", - "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", - "dev": true, - "dependencies": { - "is-callable": "^1.1.4", - "is-date-object": "^1.0.1", - "is-symbol": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/escalade": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", - "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", - "dev": true, - "engines": { - "node": ">=0.8.0" - } - }, - "node_modules/escodegen": { - "version": "1.8.1", - "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.8.1.tgz", - "integrity": "sha512-yhi5S+mNTOuRvyW4gWlg5W1byMaQGWWSYHXsuFZ7GBo7tpyOwi2EdzMP/QWxh9hwkD2m+wDVHJsxhRIj+v/b/A==", - "dev": true, - "dependencies": { - "esprima": "^2.7.1", - "estraverse": "^1.9.1", - "esutils": "^2.0.2", - "optionator": "^0.8.1" - }, - "bin": { - "escodegen": "bin/escodegen.js", - "esgenerate": "bin/esgenerate.js" - }, - "engines": { - "node": ">=0.12.0" - }, - "optionalDependencies": { - "source-map": "~0.2.0" - } - }, - "node_modules/escodegen/node_modules/esprima": { - "version": "2.7.3", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-2.7.3.tgz", - "integrity": "sha512-OarPfz0lFCiW4/AV2Oy1Rp9qu0iusTKqykwTspGCZtPxmF81JR4MmIebvF1F9+UOKth2ZubLQ4XGGaU+hSn99A==", - "dev": true, - "bin": { - "esparse": "bin/esparse.js", - "esvalidate": "bin/esvalidate.js" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/escodegen/node_modules/estraverse": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-1.9.3.tgz", - "integrity": "sha512-25w1fMXQrGdoquWnScXZGckOv+Wes+JDnuN/+7ex3SauFRS72r2lFDec0EKPt2YD1wUJ/IrfEex+9yp4hfSOJA==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "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==", - "dev": 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==", - "dev": 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==", - "dev": 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==", - "dev": true, - "dependencies": { - "prelude-ls": "~1.1.2" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/eslint": { - "version": "9.13.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.13.0.tgz", - "integrity": "sha512-EYZK6SX6zjFHST/HRytOdA/zE72Cq/bfw45LSyuwrdvcclb/gqV8RRQxywOBEWO2+WDpva6UZa4CcDeJKzUCFA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@eslint-community/eslint-utils": "^4.2.0", - "@eslint-community/regexpp": "^4.11.0", - "@eslint/config-array": "^0.18.0", - "@eslint/core": "^0.7.0", - "@eslint/eslintrc": "^3.1.0", - "@eslint/js": "9.13.0", - "@eslint/plugin-kit": "^0.2.0", - "@humanfs/node": "^0.16.5", - "@humanwhocodes/module-importer": "^1.0.1", - "@humanwhocodes/retry": "^0.3.1", - "@types/estree": "^1.0.6", - "@types/json-schema": "^7.0.15", - "ajv": "^6.12.4", - "chalk": "^4.0.0", - "cross-spawn": "^7.0.2", - "debug": "^4.3.2", - "escape-string-regexp": "^4.0.0", - "eslint-scope": "^8.1.0", - "eslint-visitor-keys": "^4.1.0", - "espree": "^10.2.0", - "esquery": "^1.5.0", - "esutils": "^2.0.2", - "fast-deep-equal": "^3.1.3", - "file-entry-cache": "^8.0.0", - "find-up": "^5.0.0", - "glob-parent": "^6.0.2", - "ignore": "^5.2.0", - "imurmurhash": "^0.1.4", - "is-glob": "^4.0.0", - "json-stable-stringify-without-jsonify": "^1.0.1", - "lodash.merge": "^4.6.2", - "minimatch": "^3.1.2", - "natural-compare": "^1.4.0", - "optionator": "^0.9.3", - "text-table": "^0.2.0" - }, - "bin": { - "eslint": "bin/eslint.js" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://eslint.org/donate" - }, - "peerDependencies": { - "jiti": "*" - }, - "peerDependenciesMeta": { - "jiti": { - "optional": true - } - } - }, - "node_modules/eslint-config-prettier": { - "version": "9.0.0", - "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-9.0.0.tgz", - "integrity": "sha512-IcJsTkJae2S35pRsRAwoCE+925rJJStOdkKnLVgtE+tEpqU0EVVM7OqrwxqgptKdX29NUwC82I5pXsGFIgSevw==", - "dev": true, - "bin": { - "eslint-config-prettier": "bin/cli.js" - }, - "peerDependencies": { - "eslint": ">=7.0.0" - } - }, - "node_modules/eslint-scope": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-8.1.0.tgz", - "integrity": "sha512-14dSvlhaVhKKsa9Fx1l8A17s7ah7Ef7wCakJ10LYk6+GYmP9yDti2oq2SEwcyndt6knfcZyhyxwY3i9yL78EQw==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "esrecurse": "^4.3.0", - "estraverse": "^5.2.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/eslint-visitor-keys": { - "version": "3.4.3", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz", - "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==", - "dev": true, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/eslint/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "license": "MIT", - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/eslint/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/eslint/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/eslint/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true, - "license": "MIT" - }, - "node_modules/eslint/node_modules/escape-string-regexp": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/eslint/node_modules/eslint-visitor-keys": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.1.0.tgz", - "integrity": "sha512-Q7lok0mqMUSf5a/AdAZkA5a/gHcO6snwQClVNNvFKCAVlxXucdU8pKydU5ZVZjBx5xr37vGbFFWtLQYreLzrZg==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/eslint/node_modules/find-up": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", - "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", - "dev": true, - "license": "MIT", - "dependencies": { - "locate-path": "^6.0.0", - "path-exists": "^4.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/eslint/node_modules/glob-parent": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", - "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", - "dev": true, - "license": "ISC", - "dependencies": { - "is-glob": "^4.0.3" - }, - "engines": { - "node": ">=10.13.0" - } - }, - "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, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/eslint/node_modules/locate-path": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", - "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", - "dev": true, - "license": "MIT", - "dependencies": { - "p-locate": "^5.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/eslint/node_modules/p-locate": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", - "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", - "dev": true, - "license": "MIT", - "dependencies": { - "p-limit": "^3.0.2" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/eslint/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "license": "MIT", - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/espree": { - "version": "10.2.0", - "resolved": "https://registry.npmjs.org/espree/-/espree-10.2.0.tgz", - "integrity": "sha512-upbkBJbckcCNBDBDXEbuhjbP68n+scUd3k/U2EkyM9nw+I/jPiL4cLF/Al06CF96wRltFda16sxDFrxsI1v0/g==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "acorn": "^8.12.0", - "acorn-jsx": "^5.3.2", - "eslint-visitor-keys": "^4.1.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/espree/node_modules/eslint-visitor-keys": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.1.0.tgz", - "integrity": "sha512-Q7lok0mqMUSf5a/AdAZkA5a/gHcO6snwQClVNNvFKCAVlxXucdU8pKydU5ZVZjBx5xr37vGbFFWtLQYreLzrZg==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/esprima": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", - "dev": true, - "bin": { - "esparse": "bin/esparse.js", - "esvalidate": "bin/esvalidate.js" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/esquery": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.5.0.tgz", - "integrity": "sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg==", - "dev": true, - "dependencies": { - "estraverse": "^5.1.0" - }, - "engines": { - "node": ">=0.10" - } - }, - "node_modules/esrecurse": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", - "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "estraverse": "^5.2.0" - }, - "engines": { - "node": ">=4.0" - } - }, - "node_modules/estraverse": { - "version": "5.3.0", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", - "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", - "dev": true, - "engines": { - "node": ">=4.0" - } - }, - "node_modules/esutils": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", - "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/ethereum-bloom-filters": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/ethereum-bloom-filters/-/ethereum-bloom-filters-1.0.10.tgz", - "integrity": "sha512-rxJ5OFN3RwjQxDcFP2Z5+Q9ho4eIdEmSc2ht0fCu8Se9nbXjZ7/031uXoUYJ87KHCOdVeiUuwSnoS7hmYAGVHA==", - "dev": true, - "dependencies": { - "js-sha3": "^0.8.0" - } - }, - "node_modules/ethereum-cryptography": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", - "integrity": "sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==", - "dev": true, - "dependencies": { - "@types/pbkdf2": "^3.0.0", - "@types/secp256k1": "^4.0.1", - "blakejs": "^1.1.0", - "browserify-aes": "^1.2.0", - "bs58check": "^2.1.2", - "create-hash": "^1.2.0", - "create-hmac": "^1.1.7", - "hash.js": "^1.1.7", - "keccak": "^3.0.0", - "pbkdf2": "^3.0.17", - "randombytes": "^2.1.0", - "safe-buffer": "^5.1.2", - "scrypt-js": "^3.0.0", - "secp256k1": "^4.0.1", - "setimmediate": "^1.0.5" - } - }, - "node_modules/ethereumjs-abi": { - "version": "0.6.8", - "resolved": "https://registry.npmjs.org/ethereumjs-abi/-/ethereumjs-abi-0.6.8.tgz", - "integrity": "sha512-Tx0r/iXI6r+lRsdvkFDlut0N08jWMnKRZ6Gkq+Nmw75lZe4e6o3EkSnkaBP5NF6+m5PTGAr9JP43N3LyeoglsA==", - "dev": true, - "dependencies": { - "bn.js": "^4.11.8", - "ethereumjs-util": "^6.0.0" - } - }, - "node_modules/ethereumjs-abi/node_modules/@types/bn.js": { - "version": "4.11.6", - "resolved": "https://registry.npmjs.org/@types/bn.js/-/bn.js-4.11.6.tgz", - "integrity": "sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==", - "dev": true, - "dependencies": { - "@types/node": "*" - } - }, - "node_modules/ethereumjs-abi/node_modules/ethereumjs-util": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/ethereumjs-util/-/ethereumjs-util-6.2.1.tgz", - "integrity": "sha512-W2Ktez4L01Vexijrm5EB6w7dg4n/TgpoYU4avuT5T3Vmnw/eCRtiBrJfQYS/DCSvDIOLn2k57GcHdeBcgVxAqw==", - "dev": true, - "dependencies": { - "@types/bn.js": "^4.11.3", - "bn.js": "^4.11.0", - "create-hash": "^1.1.2", - "elliptic": "^6.5.2", - "ethereum-cryptography": "^0.1.3", - "ethjs-util": "0.1.6", - "rlp": "^2.2.3" - } - }, - "node_modules/ethereumjs-util": { - "version": "7.1.5", - "resolved": "https://registry.npmjs.org/ethereumjs-util/-/ethereumjs-util-7.1.5.tgz", - "integrity": "sha512-SDl5kKrQAudFBUe5OJM9Ac6WmMyYmXX/6sTmLZ3ffG2eY6ZIGBes3pEDxNN6V72WyOw4CPD5RomKdsa8DAAwLg==", - "dev": true, - "dependencies": { - "@types/bn.js": "^5.1.0", - "bn.js": "^5.1.2", - "create-hash": "^1.1.2", - "ethereum-cryptography": "^0.1.3", - "rlp": "^2.2.4" - }, - "engines": { - "node": ">=10.0.0" - } - }, - "node_modules/ethereumjs-util/node_modules/bn.js": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", - "dev": true - }, - "node_modules/ethers": { - "version": "6.7.1", - "resolved": "https://registry.npmjs.org/ethers/-/ethers-6.7.1.tgz", - "integrity": "sha512-qX5kxIFMfg1i+epfgb0xF4WM7IqapIIu50pOJ17aebkxxa4BacW5jFrQRmCJpDEg2ZK2oNtR5QjrQ1WDBF29dA==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://github.com/sponsors/ethers-io/" - }, - { - "type": "individual", - "url": "https://www.buymeacoffee.com/ricmoo" - } - ], - "dependencies": { - "@adraffy/ens-normalize": "1.9.2", - "@noble/hashes": "1.1.2", - "@noble/secp256k1": "1.7.1", - "@types/node": "18.15.13", - "aes-js": "4.0.0-beta.5", - "tslib": "2.4.0", - "ws": "8.5.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/ethers/node_modules/@noble/hashes": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.1.2.tgz", - "integrity": "sha512-KYRCASVTv6aeUi1tsF8/vpyR7zpfs3FUzy2Jqm+MU+LmUKhQ0y2FpfwqkCcxSg2ua4GALJd8k2R76WxwZGbQpA==", - "dev": true, - "funding": [ - { - "type": "individual", - "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", - "integrity": "sha512-N+0kuo9KgrUQ1Sn/ifDXsvg0TTleP7rIy4zOBGECxAljqvqfqpTfzx0Q1NUedOixRMBfe2Whhb056a42cWs26Q==", - "dev": true - }, - "node_modules/ethers/node_modules/aes-js": { - "version": "4.0.0-beta.5", - "resolved": "https://registry.npmjs.org/aes-js/-/aes-js-4.0.0-beta.5.tgz", - "integrity": "sha512-G965FqalsNyrPqgEGON7nIx1e/OVENSgiEIzyC63haUMuvNnwIgIjMs52hlTCKhkBny7A2ORNlfY9Zu+jmGk1Q==", - "dev": true - }, - "node_modules/ethers/node_modules/tslib": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.0.tgz", - "integrity": "sha512-d6xOpEDfsi2CZVlPQzGeux8XMwLT9hssAsaPYExaQMuYskwb+x1x7J371tWlbBdWHroy99KnVB6qIkUbs5X3UQ==", - "dev": true - }, - "node_modules/ethers/node_modules/ws": { - "version": "8.5.0", - "resolved": "https://registry.npmjs.org/ws/-/ws-8.5.0.tgz", - "integrity": "sha512-BWX0SWVgLPzYwF8lTzEy1egjhS4S4OEAHfsO8o65WOVsrnSRGaSiUaa9e0ggGlkMTtBlmOpEXiie9RUcBO86qg==", - "dev": true, - "engines": { - "node": ">=10.0.0" - }, - "peerDependencies": { - "bufferutil": "^4.0.1", - "utf-8-validate": "^5.0.2" - }, - "peerDependenciesMeta": { - "bufferutil": { - "optional": true - }, - "utf-8-validate": { - "optional": true - } - } - }, - "node_modules/ethjs-unit": { - "version": "0.1.6", - "resolved": "https://registry.npmjs.org/ethjs-unit/-/ethjs-unit-0.1.6.tgz", - "integrity": "sha512-/Sn9Y0oKl0uqQuvgFk/zQgR7aw1g36qX/jzSQ5lSwlO0GigPymk4eGQfeNTD03w1dPOqfz8V77Cy43jH56pagw==", - "dev": true, - "dependencies": { - "bn.js": "4.11.6", - "number-to-bn": "1.7.0" - }, - "engines": { - "node": ">=6.5.0", - "npm": ">=3" - } - }, - "node_modules/ethjs-unit/node_modules/bn.js": { - "version": "4.11.6", - "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.11.6.tgz", - "integrity": "sha512-XWwnNNFCuuSQ0m3r3C4LE3EiORltHd9M05pq6FOlVeiophzRbMo50Sbz1ehl8K3Z+jw9+vmgnXefY1hz8X+2wA==", - "dev": true - }, - "node_modules/ethjs-util": { - "version": "0.1.6", - "resolved": "https://registry.npmjs.org/ethjs-util/-/ethjs-util-0.1.6.tgz", - "integrity": "sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==", - "dev": true, - "dependencies": { - "is-hex-prefixed": "1.0.0", - "strip-hex-prefix": "1.0.0" - }, - "engines": { - "node": ">=6.5.0", - "npm": ">=3" - } - }, - "node_modules/evp_bytestokey": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/evp_bytestokey/-/evp_bytestokey-1.0.3.tgz", - "integrity": "sha512-/f2Go4TognH/KvCISP7OUsHn85hT9nUkxxA9BEWxFn+Oj9o8ZNLm/40hdlgSLyuOimsrTKLUMEorQexp/aPQeA==", - "dev": true, - "dependencies": { - "md5.js": "^1.3.4", - "safe-buffer": "^5.1.1" - } - }, - "node_modules/extendable-error": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/extendable-error/-/extendable-error-0.1.7.tgz", - "integrity": "sha512-UOiS2in6/Q0FK0R0q6UY9vYpQ21mr/Qn1KOnte7vsACuNJf514WvCCUHSRCPcgjPT2bAhNIJdlE6bVap1GKmeg==", - "dev": true - }, - "node_modules/external-editor": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-3.1.0.tgz", - "integrity": "sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==", - "dev": true, - "dependencies": { - "chardet": "^0.7.0", - "iconv-lite": "^0.4.24", - "tmp": "^0.0.33" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/fast-deep-equal": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", - "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", - "dev": true - }, - "node_modules/fast-diff": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/fast-diff/-/fast-diff-1.3.0.tgz", - "integrity": "sha512-VxPP4NqbUjj6MaAOafWeUn2cXWLcCtljklUtZf0Ind4XQ+QPtmA0b18zZy0jIQx+ExRVCR/ZQpBmik5lXshNsw==", - "dev": true - }, - "node_modules/fast-glob": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.1.tgz", - "integrity": "sha512-kNFPyjhh5cKjrUltxs+wFx+ZkbRaxxmZ+X0ZU31SOsxCEtP9VPgtq2teZw1DebupL5GmDaNQ6yKMMVcM41iqDg==", - "dev": true, - "dependencies": { - "@nodelib/fs.stat": "^2.0.2", - "@nodelib/fs.walk": "^1.2.3", - "glob-parent": "^5.1.2", - "merge2": "^1.3.0", - "micromatch": "^4.0.4" - }, - "engines": { - "node": ">=8.6.0" - } - }, - "node_modules/fast-json-stable-stringify": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", - "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", - "dev": true - }, - "node_modules/fast-levenshtein": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", - "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==", - "dev": true - }, - "node_modules/fastq": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.15.0.tgz", - "integrity": "sha512-wBrocU2LCXXa+lWBt8RoIRD89Fi8OdABODa/kEnyeyjS5aZO5/GNvI5sEINADqP/h8M29UHTHUb53sUu5Ihqdw==", - "dev": true, - "dependencies": { - "reusify": "^1.0.4" - } - }, - "node_modules/file-entry-cache": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-8.0.0.tgz", - "integrity": "sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "flat-cache": "^4.0.0" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/fill-range": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", - "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", - "dev": true, - "dependencies": { - "to-regex-range": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/find-up": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", - "dev": true, - "dependencies": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/find-yarn-workspace-root2": { - "version": "1.2.16", - "resolved": "https://registry.npmjs.org/find-yarn-workspace-root2/-/find-yarn-workspace-root2-1.2.16.tgz", - "integrity": "sha512-hr6hb1w8ePMpPVUK39S4RlwJzi+xPLuVuG8XlwXU3KD5Yn3qgBWVfy3AzNlDhWvE1EORCE65/Qm26rFQt3VLVA==", - "dev": true, - "dependencies": { - "micromatch": "^4.0.2", - "pkg-dir": "^4.2.0" - } - }, - "node_modules/flat": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz", - "integrity": "sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==", - "dev": true, - "bin": { - "flat": "cli.js" - } - }, - "node_modules/flat-cache": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-4.0.1.tgz", - "integrity": "sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw==", - "dev": true, - "license": "MIT", - "dependencies": { - "flatted": "^3.2.9", - "keyv": "^4.5.4" - }, - "engines": { - "node": ">=16" - } - }, - "node_modules/flatted": { - "version": "3.4.2", - "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.4.2.tgz", - "integrity": "sha512-PjDse7RzhcPkIJwy5t7KPWQSZ9cAbzQXcafsetQoD7sOJRQlGikNbx7yZp2OotDnJyrDcbyRq3Ttb18iYOqkxA==", - "dev": true, - "license": "ISC" - }, - "node_modules/follow-redirects": { - "version": "1.16.0", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.16.0.tgz", - "integrity": "sha512-y5rN/uOsadFT/JfYwhxRS5R7Qce+g3zG97+JrtFZlC9klX/W5hD7iiLzScI4nZqUS7DNUdhPgw4xI8W2LuXlUw==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://github.com/sponsors/RubenVerborgh" - } - ], - "license": "MIT", - "engines": { - "node": ">=4.0" - }, - "peerDependenciesMeta": { - "debug": { - "optional": true - } - } - }, - "node_modules/for-each": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", - "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", - "dev": true, - "dependencies": { - "is-callable": "^1.1.3" - } - }, - "node_modules/foreground-child": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.1.1.tgz", - "integrity": "sha512-TMKDUnIte6bfb5nWv7V/caI169OHgvwjb7V4WkeUvbQQdjr5rWKqHFiKWb/fcOwB+CzBT+qbWjvj+DVwRskpIg==", - "dev": true, - "dependencies": { - "cross-spawn": "^7.0.0", - "signal-exit": "^4.0.1" - }, - "engines": { - "node": ">=14" - }, - "funding": { - "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/form-data": { - "version": "4.0.5", - "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.5.tgz", - "integrity": "sha512-8RipRLol37bNs2bhoV67fiTEvdTrbMUYcFTiy3+wuuOnUog2QBHCZWXDRijWQfAkhBj2Uf5UnVaiWwA5vdd82w==", - "dev": true, - "license": "MIT", - "dependencies": { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.8", - "es-set-tostringtag": "^2.1.0", - "hasown": "^2.0.2", - "mime-types": "^2.1.12" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/form-data-encoder": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/form-data-encoder/-/form-data-encoder-2.1.4.tgz", - "integrity": "sha512-yDYSgNMraqvnxiEXO4hi88+YZxaHC6QKzb5N84iRCTDeRO7ZALpir/lVmf/uXUhnwUr2O4HU8s/n6x+yNjQkHw==", - "dev": true, - "engines": { - "node": ">= 14.17" - } - }, - "node_modules/fp-ts": { - "version": "1.19.3", - "resolved": "https://registry.npmjs.org/fp-ts/-/fp-ts-1.19.3.tgz", - "integrity": "sha512-H5KQDspykdHuztLTg+ajGN0Z2qUjcEf3Ybxc6hLt0k7/zPkn29XnKnxlBPyW2XIddWrGaJBzBl4VLYOtk39yZg==", - "dev": true - }, - "node_modules/fs-extra": { - "version": "7.0.1", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-7.0.1.tgz", - "integrity": "sha512-YJDaCJZEnBmcbw13fvdAM9AwNOJwOzrE4pqMqBq5nFiEqXUqHwlK4B+3pUw6JNvfSPtX05xFHtYy/1ni01eGCw==", - "dev": true, - "dependencies": { - "graceful-fs": "^4.1.2", - "jsonfile": "^4.0.0", - "universalify": "^0.1.0" - }, - "engines": { - "node": ">=6 <7 || >=8" - } - }, - "node_modules/fs.realpath": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==", - "dev": true - }, - "node_modules/fsevents": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", - "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", - "dev": true, - "hasInstallScript": true, - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": "^8.16.0 || ^10.6.0 || >=11.0.0" - } - }, - "node_modules/function-bind": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", - "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", - "dev": true, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/function.prototype.name": { - "version": "1.1.6", - "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", - "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1", - "functions-have-names": "^1.2.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/functions-have-names": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", - "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", - "dev": true, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/get-caller-file": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", - "dev": true, - "engines": { - "node": "6.* || 8.* || >= 10.*" - } - }, - "node_modules/get-func-name": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.2.tgz", - "integrity": "sha512-8vXOvuE167CtIc3OyItco7N/dpRtBbYOsPsXCz7X/PMnlGjYjSGuZJgM1Y7mmew7BKf9BqvLX2tnOVy1BBUsxQ==", - "dev": true, - "engines": { - "node": "*" - } - }, - "node_modules/get-intrinsic": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.3.0.tgz", - "integrity": "sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind-apply-helpers": "^1.0.2", - "es-define-property": "^1.0.1", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.1.1", - "function-bind": "^1.1.2", - "get-proto": "^1.0.1", - "gopd": "^1.2.0", - "has-symbols": "^1.1.0", - "hasown": "^2.0.2", - "math-intrinsics": "^1.1.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/get-proto": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz", - "integrity": "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==", - "dev": true, - "license": "MIT", - "dependencies": { - "dunder-proto": "^1.0.1", - "es-object-atoms": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/get-stream": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", - "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/get-symbol-description": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", - "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "get-intrinsic": "^1.1.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/ghost-testrpc": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/ghost-testrpc/-/ghost-testrpc-0.0.2.tgz", - "integrity": "sha512-i08dAEgJ2g8z5buJIrCTduwPIhih3DP+hOCTyyryikfV8T0bNvHnGXO67i0DD1H4GBDETTclPy9njZbfluQYrQ==", - "dev": true, - "dependencies": { - "chalk": "^2.4.2", - "node-emoji": "^1.10.0" - }, - "bin": { - "testrpc-sc": "index.js" - } - }, - "node_modules/glob": { - "version": "11.0.0", - "resolved": "https://registry.npmjs.org/glob/-/glob-11.0.0.tgz", - "integrity": "sha512-9UiX/Bl6J2yaBbxKoEBRm4Cipxgok8kQYcOPEhScPwebu2I0HoQOuYdIO6S3hLuWoZgpDpwQZMzTFxgpkyT76g==", - "dev": true, - "license": "ISC", - "dependencies": { - "foreground-child": "^3.1.0", - "jackspeak": "^4.0.1", - "minimatch": "^10.0.0", - "minipass": "^7.1.2", - "package-json-from-dist": "^1.0.0", - "path-scurry": "^2.0.0" - }, - "bin": { - "glob": "dist/esm/bin.mjs" - }, - "engines": { - "node": "20 || >=22" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/glob-parent": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", - "dev": true, - "dependencies": { - "is-glob": "^4.0.1" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/glob/node_modules/balanced-match": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-4.0.4.tgz", - "integrity": "sha512-BLrgEcRTwX2o6gGxGOCNyMvGSp35YofuYzw9h1IMTRmKqttAZZVU67bdb9Pr2vUHA8+j3i2tJfjO6C6+4myGTA==", - "dev": true, - "license": "MIT", - "engines": { - "node": "18 || 20 || >=22" - } - }, - "node_modules/glob/node_modules/brace-expansion": { - "version": "5.0.5", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-5.0.5.tgz", - "integrity": "sha512-VZznLgtwhn+Mact9tfiwx64fA9erHH/MCXEUfB/0bX/6Fz6ny5EGTXYltMocqg4xFAQZtnO3DHWWXi8RiuN7cQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^4.0.2" - }, - "engines": { - "node": "18 || 20 || >=22" - } - }, - "node_modules/glob/node_modules/minimatch": { - "version": "10.2.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-10.2.4.tgz", - "integrity": "sha512-oRjTw/97aTBN0RHbYCdtF1MQfvusSIBQM0IZEgzl6426+8jSC0nF1a/GmnVLpfB9yyr6g6FTqWqiZVbxrtaCIg==", - "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "brace-expansion": "^5.0.2" - }, - "engines": { - "node": "18 || 20 || >=22" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/global-modules": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/global-modules/-/global-modules-2.0.0.tgz", - "integrity": "sha512-NGbfmJBp9x8IxyJSd1P+otYK8vonoJactOogrVfFRIAEY1ukil8RSKDz2Yo7wh1oihl51l/r6W4epkeKJHqL8A==", - "dev": true, - "dependencies": { - "global-prefix": "^3.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/global-prefix": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/global-prefix/-/global-prefix-3.0.0.tgz", - "integrity": "sha512-awConJSVCHVGND6x3tmMaKcQvwXLhjdkmomy2W+Goaui8YPgYgXJZewhg3fWC+DlfqqQuWg8AwqjGTD2nAPVWg==", - "dev": true, - "dependencies": { - "ini": "^1.3.5", - "kind-of": "^6.0.2", - "which": "^1.3.1" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/global-prefix/node_modules/which": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "dev": true, - "dependencies": { - "isexe": "^2.0.0" - }, - "bin": { - "which": "bin/which" - } - }, - "node_modules/globals": { - "version": "15.11.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-15.11.0.tgz", - "integrity": "sha512-yeyNSjdbyVaWurlwCpcA6XNBrHTMIeDdj0/hnvX/OLJ9ekOXYbLsLinH/MucQyGvNnXhidTdNhTtJaffL2sMfw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/globalthis": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz", - "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==", - "dev": true, - "dependencies": { - "define-properties": "^1.1.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/globby": { - "version": "11.1.0", - "resolved": "https://registry.npmjs.org/globby/-/globby-11.1.0.tgz", - "integrity": "sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==", - "dev": true, - "dependencies": { - "array-union": "^2.1.0", - "dir-glob": "^3.0.1", - "fast-glob": "^3.2.9", - "ignore": "^5.2.0", - "merge2": "^1.4.1", - "slash": "^3.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/gopd": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz", - "integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/got": { - "version": "12.6.1", - "resolved": "https://registry.npmjs.org/got/-/got-12.6.1.tgz", - "integrity": "sha512-mThBblvlAF1d4O5oqyvN+ZxLAYwIJK7bpMxgYqPD9okW0C3qm5FFn7k811QrcuEBwaogR3ngOFoCfs6mRv7teQ==", - "dev": true, - "dependencies": { - "@sindresorhus/is": "^5.2.0", - "@szmarczak/http-timer": "^5.0.1", - "cacheable-lookup": "^7.0.0", - "cacheable-request": "^10.2.8", - "decompress-response": "^6.0.0", - "form-data-encoder": "^2.1.2", - "get-stream": "^6.0.1", - "http2-wrapper": "^2.1.10", - "lowercase-keys": "^3.0.0", - "p-cancelable": "^3.0.0", - "responselike": "^3.0.0" - }, - "engines": { - "node": ">=14.16" - }, - "funding": { - "url": "https://github.com/sindresorhus/got?sponsor=1" - } - }, - "node_modules/graceful-fs": { - "version": "4.2.11", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", - "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", - "dev": true - }, - "node_modules/grapheme-splitter": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/grapheme-splitter/-/grapheme-splitter-1.0.4.tgz", - "integrity": "sha512-bzh50DW9kTPM00T8y4o8vQg89Di9oLJVLW/KaOGIXJWP/iqCN6WKYkbNOF04vFLJhwcpYUh9ydh/+5vpOqV4YQ==", - "dev": true - }, - "node_modules/graphlib": { - "version": "2.1.8", - "resolved": "https://registry.npmjs.org/graphlib/-/graphlib-2.1.8.tgz", - "integrity": "sha512-jcLLfkpoVGmH7/InMC/1hIvOPSUh38oJtGhvrOFGzioE1DZ+0YW16RgmOJhHiuWTvGiJQ9Z1Ik43JvkRPRvE+A==", - "dev": true, - "dependencies": { - "lodash": "^4.17.15" - } - }, - "node_modules/handlebars": { - "version": "4.7.9", - "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.7.9.tgz", - "integrity": "sha512-4E71E0rpOaQuJR2A3xDZ+GM1HyWYv1clR58tC8emQNeQe3RH7MAzSbat+V0wG78LQBo6m6bzSG/L4pBuCsgnUQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "minimist": "^1.2.5", - "neo-async": "^2.6.2", - "source-map": "^0.6.1", - "wordwrap": "^1.0.0" - }, - "bin": { - "handlebars": "bin/handlebars" - }, - "engines": { - "node": ">=0.4.7" - }, - "optionalDependencies": { - "uglify-js": "^3.1.4" - } - }, - "node_modules/handlebars/node_modules/source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/hard-rejection": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/hard-rejection/-/hard-rejection-2.1.0.tgz", - "integrity": "sha512-VIZB+ibDhx7ObhAe7OVtoEbuP4h/MuOTHJ+J8h/eBXotJYl0fBgR72xDFCKgIh22OJZIOVNxBMWuhAr10r8HdA==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/hardhat": { - "version": "2.22.2", - "resolved": "https://registry.npmjs.org/hardhat/-/hardhat-2.22.2.tgz", - "integrity": "sha512-0xZ7MdCZ5sJem4MrvpQWLR3R3zGDoHw5lsR+pBFimqwagimIOn3bWuZv69KA+veXClwI1s/zpqgwPwiFrd4Dxw==", - "dev": true, - "dependencies": { - "@ethersproject/abi": "^5.1.2", - "@metamask/eth-sig-util": "^4.0.0", - "@nomicfoundation/edr": "^0.3.1", - "@nomicfoundation/ethereumjs-common": "4.0.4", - "@nomicfoundation/ethereumjs-tx": "5.0.4", - "@nomicfoundation/ethereumjs-util": "9.0.4", - "@nomicfoundation/solidity-analyzer": "^0.1.0", - "@sentry/node": "^5.18.1", - "@types/bn.js": "^5.1.0", - "@types/lru-cache": "^5.1.0", - "adm-zip": "^0.4.16", - "aggregate-error": "^3.0.0", - "ansi-escapes": "^4.3.0", - "boxen": "^5.1.2", - "chalk": "^2.4.2", - "chokidar": "^3.4.0", - "ci-info": "^2.0.0", - "debug": "^4.1.1", - "enquirer": "^2.3.0", - "env-paths": "^2.2.0", - "ethereum-cryptography": "^1.0.3", - "ethereumjs-abi": "^0.6.8", - "find-up": "^2.1.0", - "fp-ts": "1.19.3", - "fs-extra": "^7.0.1", - "glob": "7.2.0", - "immutable": "^4.0.0-rc.12", - "io-ts": "1.10.4", - "keccak": "^3.0.2", - "lodash": "^4.17.11", - "mnemonist": "^0.38.0", - "mocha": "^10.0.0", - "p-map": "^4.0.0", - "raw-body": "^2.4.1", - "resolve": "1.17.0", - "semver": "^6.3.0", - "solc": "0.7.3", - "source-map-support": "^0.5.13", - "stacktrace-parser": "^0.1.10", - "tsort": "0.0.1", - "undici": "^5.14.0", - "uuid": "^8.3.2", - "ws": "^7.4.6" - }, - "bin": { - "hardhat": "internal/cli/bootstrap.js" - }, - "peerDependencies": { - "ts-node": "*", - "typescript": "*" - }, - "peerDependenciesMeta": { - "ts-node": { - "optional": true - }, - "typescript": { - "optional": true - } - } - }, - "node_modules/hardhat-exposed": { - "version": "0.3.15", - "resolved": "https://registry.npmjs.org/hardhat-exposed/-/hardhat-exposed-0.3.15.tgz", - "integrity": "sha512-jqxErCnSWGYf4vAkLmh3H3u+IuLuCLw/EVeV13z1JKJMJAd/iO+G283n8T124S/Q2BF/BoA2zgzYAlqXgNyKew==", - "dev": true, - "dependencies": { - "micromatch": "^4.0.4", - "solidity-ast": "^0.4.52" - }, - "peerDependencies": { - "hardhat": "^2.3.0" - } - }, - "node_modules/hardhat-gas-reporter": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/hardhat-gas-reporter/-/hardhat-gas-reporter-2.1.0.tgz", - "integrity": "sha512-d/WU/qHhBFnbweAm2fAAjcaaE0M7BKZ4r+/bqcFlfP6um28BXtlv2FrJ6oyQUGSFD0ttbmB7sH4ZFDzkYw5GzA==", - "dev": true, - "dependencies": { - "@ethersproject/abi": "^5.7.0", - "@ethersproject/bytes": "^5.7.0", - "@ethersproject/units": "^5.7.0", - "@solidity-parser/parser": "^0.18.0", - "axios": "^1.6.7", - "brotli-wasm": "^2.0.1", - "chalk": "4.1.2", - "cli-table3": "^0.6.3", - "ethereum-cryptography": "^2.1.3", - "glob": "^10.3.10", - "jsonschema": "^1.4.1", - "lodash": "^4.17.21", - "markdown-table": "2.0.0", - "sha1": "^1.1.1", - "viem": "2.7.14" - }, - "peerDependencies": { - "hardhat": "^2.16.0" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/@noble/curves": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.3.0.tgz", - "integrity": "sha512-t01iSXPuN+Eqzb4eBX0S5oubSqXbK/xXa1Ne18Hj8f9pStxztHCE2gfboSp/dZRLSqfuLpRK2nDXDK+W9puocA==", - "dev": true, - "dependencies": { - "@noble/hashes": "1.3.3" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/@noble/hashes": { - "version": "1.3.3", - "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.3.tgz", - "integrity": "sha512-V7/fPHgl+jsVPXqqeOzT8egNj2iBIVt+ECeMMG8TdcnTikP3oaBtUVqpT/gYCR68aEBJSF+XbYUxStjbFMqIIA==", - "dev": true, - "engines": { - "node": ">= 16" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/@scure/bip32": { - "version": "1.3.3", - "resolved": "https://registry.npmjs.org/@scure/bip32/-/bip32-1.3.3.tgz", - "integrity": "sha512-LJaN3HwRbfQK0X1xFSi0Q9amqOgzQnnDngIt+ZlsBC3Bm7/nE7K0kwshZHyaru79yIVRv/e1mQAjZyuZG6jOFQ==", - "dev": true, - "dependencies": { - "@noble/curves": "~1.3.0", - "@noble/hashes": "~1.3.2", - "@scure/base": "~1.1.4" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/@scure/bip39": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/@scure/bip39/-/bip39-1.2.2.tgz", - "integrity": "sha512-HYf9TUXG80beW+hGAt3TRM8wU6pQoYur9iNypTROm42dorCGmLnFe3eWjz3gOq6G62H2WRh0FCzAR1PI+29zIA==", - "dev": true, - "dependencies": { - "@noble/hashes": "~1.3.2", - "@scure/base": "~1.1.4" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/brace-expansion": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.0.tgz", - "integrity": "sha512-TN1kCZAgdgweJhWWpgKYrQaMNHcDULHkWwQIspdtjV4Y5aurRdZpjAqn6yX3FPqTA9ngHCc4hJxMAMgGfve85w==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/cli-table3": { - "version": "0.6.4", - "resolved": "https://registry.npmjs.org/cli-table3/-/cli-table3-0.6.4.tgz", - "integrity": "sha512-Lm3L0p+/npIQWNIiyF/nAn7T5dnOwR3xNTHXYEBFBFVPXzCVNZ5lqEC/1eo/EVfpDsQ1I+TX4ORPQgp+UI0CRw==", - "dev": true, - "dependencies": { - "string-width": "^4.2.0" - }, - "engines": { - "node": "10.* || >= 12.*" - }, - "optionalDependencies": { - "@colors/colors": "1.5.0" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/hardhat-gas-reporter/node_modules/ethereum-cryptography": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-2.1.3.tgz", - "integrity": "sha512-BlwbIL7/P45W8FGW2r7LGuvoEZ+7PWsniMvQ4p5s2xCyw9tmaDlpfsN9HjAucbF+t/qpVHwZUisgfK24TCW8aA==", - "dev": true, - "dependencies": { - "@noble/curves": "1.3.0", - "@noble/hashes": "1.3.3", - "@scure/bip32": "1.3.3", - "@scure/bip39": "1.2.2" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/glob": { - "version": "10.4.5", - "resolved": "https://registry.npmjs.org/glob/-/glob-10.4.5.tgz", - "integrity": "sha512-7Bv8RF0k6xjo7d4A/PxYLbUCfb6c+Vpd2/mB2yRDlew7Jb5hEXiCD9ibfO7wpk8i4sevK6DFny9h7EYbM3/sHg==", - "dev": true, - "license": "ISC", - "dependencies": { - "foreground-child": "^3.1.0", - "jackspeak": "^3.1.2", - "minimatch": "^9.0.4", - "minipass": "^7.1.2", - "package-json-from-dist": "^1.0.0", - "path-scurry": "^1.11.1" - }, - "bin": { - "glob": "dist/esm/bin.mjs" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/hardhat-gas-reporter/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/hardhat-gas-reporter/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/jackspeak": { - "version": "3.4.3", - "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-3.4.3.tgz", - "integrity": "sha512-OGlZQpz2yfahA/Rd1Y8Cd9SIEsqvXkLVoSw/cgwhnhFMDbsQFeZYoJJ7bIZBS9BcamUW96asq/npPWugM+RQBw==", - "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "@isaacs/cliui": "^8.0.2" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - }, - "optionalDependencies": { - "@pkgjs/parseargs": "^0.11.0" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/lru-cache": { - "version": "10.4.3", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", - "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", - "dev": true, - "license": "ISC" - }, - "node_modules/hardhat-gas-reporter/node_modules/markdown-table": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/markdown-table/-/markdown-table-2.0.0.tgz", - "integrity": "sha512-Ezda85ToJUBhM6WGaG6veasyym+Tbs3cMAw/ZhOPqXiYsr0jgocBV3j3nx+4lk47plLlIqjwuTm/ywVI+zjJ/A==", - "dev": true, - "dependencies": { - "repeat-string": "^1.0.0" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/minimatch": { - "version": "9.0.9", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.9.tgz", - "integrity": "sha512-OBwBN9AL4dqmETlpS2zasx+vTeWclWzkblfZk7KTA5j3jeOONz/tRCnZomUyvNg83wL5Zv9Ss6HMJXAgL8R2Yg==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^2.0.2" - }, - "engines": { - "node": ">=16 || 14 >=14.17" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/path-scurry": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.11.1.tgz", - "integrity": "sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==", - "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "lru-cache": "^10.2.0", - "minipass": "^5.0.0 || ^6.0.2 || ^7.0.0" - }, - "engines": { - "node": ">=16 || 14 >=14.18" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/hardhat-gas-reporter/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/hardhat-ignore-warnings": { - "version": "0.2.11", - "resolved": "https://registry.npmjs.org/hardhat-ignore-warnings/-/hardhat-ignore-warnings-0.2.11.tgz", - "integrity": "sha512-+nHnRbP6COFZaXE7HAY7TZNE3au5vHe5dkcnyq0XaP07ikT2fJ3NhFY0vn7Deh4Qbz0Z/9Xpnj2ki6Ktgk61pg==", - "dev": true, - "dependencies": { - "minimatch": "^5.1.0", - "node-interval-tree": "^2.0.1", - "solidity-comments": "^0.0.2" - } - }, - "node_modules/hardhat-ignore-warnings/node_modules/brace-expansion": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.0.tgz", - "integrity": "sha512-TN1kCZAgdgweJhWWpgKYrQaMNHcDULHkWwQIspdtjV4Y5aurRdZpjAqn6yX3FPqTA9ngHCc4hJxMAMgGfve85w==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0" - } - }, - "node_modules/hardhat-ignore-warnings/node_modules/minimatch": { - "version": "5.1.9", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.1.9.tgz", - "integrity": "sha512-7o1wEA2RyMP7Iu7GNba9vc0RWWGACJOCZBJX2GJWip0ikV+wcOsgVuY9uE8CPiyQhkGFSlhuSkZPavN7u1c2Fw==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^2.0.1" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/hardhat/node_modules/@noble/hashes": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.2.0.tgz", - "integrity": "sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://paulmillr.com/funding/" - } - ] - }, - "node_modules/hardhat/node_modules/@scure/bip32": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/@scure/bip32/-/bip32-1.1.5.tgz", - "integrity": "sha512-XyNh1rB0SkEqd3tXcXMi+Xe1fvg+kUIcoRIEujP1Jgv7DqW2r9lg3Ah0NkFaCs9sTkQAQA8kw7xiRXzENi9Rtw==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://paulmillr.com/funding/" - } - ], - "dependencies": { - "@noble/hashes": "~1.2.0", - "@noble/secp256k1": "~1.7.0", - "@scure/base": "~1.1.0" - } - }, - "node_modules/hardhat/node_modules/@scure/bip39": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@scure/bip39/-/bip39-1.1.1.tgz", - "integrity": "sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://paulmillr.com/funding/" - } - ], - "dependencies": { - "@noble/hashes": "~1.2.0", - "@scure/base": "~1.1.0" - } - }, - "node_modules/hardhat/node_modules/ci-info": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-2.0.0.tgz", - "integrity": "sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ==", - "dev": true - }, - "node_modules/hardhat/node_modules/commander": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/commander/-/commander-3.0.2.tgz", - "integrity": "sha512-Gar0ASD4BDyKC4hl4DwHqDrmvjoxWKZigVnAbn5H1owvm4CxCPdb0HQDehwNYMJpla5+M2tPmPARzhtYuwpHow==", - "dev": true - }, - "node_modules/hardhat/node_modules/ethereum-cryptography": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-1.2.0.tgz", - "integrity": "sha512-6yFQC9b5ug6/17CQpCyE3k9eKBMdhyVjzUy1WkiuY/E4vj/SXDBbCw8QEIaXqf0Mf2SnY6RmpDcwlUmBSS0EJw==", - "dev": true, - "dependencies": { - "@noble/hashes": "1.2.0", - "@noble/secp256k1": "1.7.1", - "@scure/bip32": "1.1.5", - "@scure/bip39": "1.1.1" - } - }, - "node_modules/hardhat/node_modules/find-up": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz", - "integrity": "sha512-NWzkk0jSJtTt08+FBFMvXoeZnOJD+jTtsRmBYbAIzJdX6l7dLgR7CTubCM5/eDdPUBvLCeVasP1brfVR/9/EZQ==", - "dev": true, - "dependencies": { - "locate-path": "^2.0.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/hardhat/node_modules/glob": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz", - "integrity": "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==", - "dev": true, - "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - }, - "engines": { - "node": "*" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/hardhat/node_modules/jsonfile": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-2.4.0.tgz", - "integrity": "sha512-PKllAqbgLgxHaj8TElYymKCAgrASebJrWpTnEkOaTowt23VKXXN0sUeriJ+eh7y6ufb/CC5ap11pz71/cM0hUw==", - "dev": true, - "optionalDependencies": { - "graceful-fs": "^4.1.6" - } - }, - "node_modules/hardhat/node_modules/locate-path": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz", - "integrity": "sha512-NCI2kiDkyR7VeEKm27Kda/iQHyKJe1Bu0FlTbYp3CqJu+9IFe9bLyAjMxf5ZDDbEg+iMPzB5zYyUTSm8wVTKmA==", - "dev": true, - "dependencies": { - "p-locate": "^2.0.0", - "path-exists": "^3.0.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/hardhat/node_modules/p-limit": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz", - "integrity": "sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==", - "dev": true, - "dependencies": { - "p-try": "^1.0.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/hardhat/node_modules/p-locate": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz", - "integrity": "sha512-nQja7m7gSKuewoVRen45CtVfODR3crN3goVQ0DDZ9N3yHxgpkuBhZqsaiotSQRrADUrne346peY7kT3TSACykg==", - "dev": true, - "dependencies": { - "p-limit": "^1.1.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/hardhat/node_modules/p-try": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz", - "integrity": "sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww==", - "dev": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/hardhat/node_modules/path-exists": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==", - "dev": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/hardhat/node_modules/require-from-string": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", - "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/hardhat/node_modules/rimraf": { - "version": "2.7.1", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", - "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", - "dev": true, - "dependencies": { - "glob": "^7.1.3" - }, - "bin": { - "rimraf": "bin.js" - } - }, - "node_modules/hardhat/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", - "dev": true, - "bin": { - "semver": "bin/semver.js" - } - }, - "node_modules/hardhat/node_modules/solc": { - "version": "0.7.3", - "resolved": "https://registry.npmjs.org/solc/-/solc-0.7.3.tgz", - "integrity": "sha512-GAsWNAjGzIDg7VxzP6mPjdurby3IkGCjQcM8GFYZT6RyaoUZKmMU6Y7YwG+tFGhv7dwZ8rmR4iwFDrrD99JwqA==", - "dev": true, - "dependencies": { - "command-exists": "^1.2.8", - "commander": "3.0.2", - "follow-redirects": "^1.12.1", - "fs-extra": "^0.30.0", - "js-sha3": "0.8.0", - "memorystream": "^0.3.1", - "require-from-string": "^2.0.0", - "semver": "^5.5.0", - "tmp": "0.0.33" - }, - "bin": { - "solcjs": "solcjs" - }, - "engines": { - "node": ">=8.0.0" - } - }, - "node_modules/hardhat/node_modules/solc/node_modules/fs-extra": { - "version": "0.30.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-0.30.0.tgz", - "integrity": "sha512-UvSPKyhMn6LEd/WpUaV9C9t3zATuqoqfWc3QdPhPLb58prN9tqYPlPWi8Krxi44loBoUzlobqZ3+8tGpxxSzwA==", - "dev": true, - "dependencies": { - "graceful-fs": "^4.1.2", - "jsonfile": "^2.1.0", - "klaw": "^1.0.0", - "path-is-absolute": "^1.0.0", - "rimraf": "^2.2.8" - } - }, - "node_modules/hardhat/node_modules/solc/node_modules/semver": { - "version": "5.7.2", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", - "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", - "dev": true, - "bin": { - "semver": "bin/semver" - } - }, - "node_modules/hardhat/node_modules/undici": { - "version": "5.28.4", - "resolved": "https://registry.npmjs.org/undici/-/undici-5.28.4.tgz", - "integrity": "sha512-72RFADWFqKmUb2hmmvNODKL3p9hcB6Gt2DOQMis1SEBaV6a4MH8soBvzg+95CYhCKPFedut2JY9bMfrDl9D23g==", - "dev": true, - "dependencies": { - "@fastify/busboy": "^2.0.0" - }, - "engines": { - "node": ">=14.0" - } - }, - "node_modules/has": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", - "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", - "dev": true, - "dependencies": { - "function-bind": "^1.1.1" - }, - "engines": { - "node": ">= 0.4.0" - } - }, - "node_modules/has-bigints": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", - "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==", - "dev": true, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "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/has-property-descriptors": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", - "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", - "dev": true, - "dependencies": { - "es-define-property": "^1.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/has-proto": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", - "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==", - "dev": true, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/has-symbols": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz", - "integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/has-tostringtag": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz", - "integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==", - "dev": true, - "license": "MIT", - "dependencies": { - "has-symbols": "^1.0.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/hash-base": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/hash-base/-/hash-base-3.1.0.tgz", - "integrity": "sha512-1nmYp/rhMDiE7AYkDw+lLwlAzz0AntGIe51F3RfFfEqyQ3feY2eI/NcwC6umIQVOASPMsWJLJScWKSSvzL9IVA==", - "dev": true, - "dependencies": { - "inherits": "^2.0.4", - "readable-stream": "^3.6.0", - "safe-buffer": "^5.2.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/hash.js": { - "version": "1.1.7", - "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz", - "integrity": "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==", - "dev": true, - "dependencies": { - "inherits": "^2.0.3", - "minimalistic-assert": "^1.0.1" - } - }, - "node_modules/hasown": { - "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" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/he": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", - "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", - "dev": true, - "bin": { - "he": "bin/he" - } - }, - "node_modules/heap": { - "version": "0.2.7", - "resolved": "https://registry.npmjs.org/heap/-/heap-0.2.7.tgz", - "integrity": "sha512-2bsegYkkHO+h/9MGbn6KWcE45cHZgPANo5LXF7EvWdT0yT2EguSVO1nDgU5c8+ZOPwp2vMNa7YFsJhVcDR9Sdg==", - "dev": true - }, - "node_modules/hmac-drbg": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", - "integrity": "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==", - "dev": true, - "dependencies": { - "hash.js": "^1.0.3", - "minimalistic-assert": "^1.0.0", - "minimalistic-crypto-utils": "^1.0.1" - } - }, - "node_modules/hosted-git-info": { - "version": "2.8.9", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.9.tgz", - "integrity": "sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==", - "dev": true - }, - "node_modules/http-cache-semantics": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.1.tgz", - "integrity": "sha512-er295DKPVsV82j5kw1Gjt+ADA/XYHsajl82cGNQG2eyoPkvgUhX+nDIyelzhIWbbsXP39EHcI6l5tYs2FYqYXQ==", - "dev": true - }, - "node_modules/http-errors": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.0.tgz", - "integrity": "sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ==", - "dev": true, - "dependencies": { - "depd": "2.0.0", - "inherits": "2.0.4", - "setprototypeof": "1.2.0", - "statuses": "2.0.1", - "toidentifier": "1.0.1" - }, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/http2-wrapper": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/http2-wrapper/-/http2-wrapper-2.2.1.tgz", - "integrity": "sha512-V5nVw1PAOgfI3Lmeaj2Exmeg7fenjhRUgz1lPSezy1CuhPYbgQtbQj4jZfEAEMlaL+vupsvhjqCyjzob0yxsmQ==", - "dev": true, - "dependencies": { - "quick-lru": "^5.1.1", - "resolve-alpn": "^1.2.0" - }, - "engines": { - "node": ">=10.19.0" - } - }, - "node_modules/http2-wrapper/node_modules/quick-lru": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-5.1.1.tgz", - "integrity": "sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/https-proxy-agent": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz", - "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==", - "dev": true, - "dependencies": { - "agent-base": "6", - "debug": "4" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/human-id": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/human-id/-/human-id-1.0.2.tgz", - "integrity": "sha512-UNopramDEhHJD+VR+ehk8rOslwSfByxPIZyJRfV739NDhN5LF1fa1MqnzKm2lGTQRjNrjK19Q5fhkgIfjlVUKw==", - "dev": true - }, - "node_modules/iconv-lite": { - "version": "0.4.24", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", - "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", - "dev": true, - "dependencies": { - "safer-buffer": ">= 2.1.2 < 3" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/ignore": { - "version": "5.2.4", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.2.4.tgz", - "integrity": "sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ==", - "dev": true, - "engines": { - "node": ">= 4" - } - }, - "node_modules/immutable": { - "version": "4.3.8", - "resolved": "https://registry.npmjs.org/immutable/-/immutable-4.3.8.tgz", - "integrity": "sha512-d/Ld9aLbKpNwyl0KiM2CT1WYvkitQ1TSvmRtkcV8FKStiDoA7Slzgjmb/1G2yhKM1p0XeNOieaTbFZmU1d3Xuw==", - "dev": true, - "license": "MIT" - }, - "node_modules/import-fresh": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", - "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==", - "dev": true, - "dependencies": { - "parent-module": "^1.0.0", - "resolve-from": "^4.0.0" - }, - "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/import-fresh/node_modules/resolve-from": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", - "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", - "dev": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/imurmurhash": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", - "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", - "dev": true, - "engines": { - "node": ">=0.8.19" - } - }, - "node_modules/indent-string": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz", - "integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/inflight": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", - "dev": true, - "dependencies": { - "once": "^1.3.0", - "wrappy": "1" - } - }, - "node_modules/inherits": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "dev": true - }, - "node_modules/ini": { - "version": "1.3.8", - "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", - "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", - "dev": true - }, - "node_modules/internal-slot": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz", - "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==", - "dev": true, - "dependencies": { - "get-intrinsic": "^1.2.0", - "has": "^1.0.3", - "side-channel": "^1.0.4" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/interpret": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/interpret/-/interpret-1.4.0.tgz", - "integrity": "sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA==", - "dev": true, - "engines": { - "node": ">= 0.10" - } - }, - "node_modules/io-ts": { - "version": "1.10.4", - "resolved": "https://registry.npmjs.org/io-ts/-/io-ts-1.10.4.tgz", - "integrity": "sha512-b23PteSnYXSONJ6JQXRAlvJhuw8KOtkqa87W4wDtvMrud/DTJd5X+NpOOI+O/zZwVq6v0VLAaJ+1EDViKEuN9g==", - "dev": true, - "dependencies": { - "fp-ts": "^1.0.0" - } - }, - "node_modules/is-array-buffer": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", - "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "get-intrinsic": "^1.2.0", - "is-typed-array": "^1.1.10" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-arrayish": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", - "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==", - "dev": true - }, - "node_modules/is-bigint": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", - "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", - "dev": true, - "dependencies": { - "has-bigints": "^1.0.1" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-binary-path": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", - "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", - "dev": true, - "dependencies": { - "binary-extensions": "^2.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/is-boolean-object": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", - "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-callable": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", - "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", - "dev": true, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-ci": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/is-ci/-/is-ci-3.0.1.tgz", - "integrity": "sha512-ZYvCgrefwqoQ6yTyYUbQu64HsITZ3NfKX1lzaEYdkTDcfKzzCI/wthRRYKkdjHKFVgNiXKAKm65Zo1pk2as/QQ==", - "dev": true, - "dependencies": { - "ci-info": "^3.2.0" - }, - "bin": { - "is-ci": "bin.js" - } - }, - "node_modules/is-date-object": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", - "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", - "dev": true, - "dependencies": { - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-extglob": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/is-glob": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", - "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", - "dev": true, - "dependencies": { - "is-extglob": "^2.1.1" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/is-hex-prefixed": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz", - "integrity": "sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==", - "dev": true, - "engines": { - "node": ">=6.5.0", - "npm": ">=3" - } - }, - "node_modules/is-negative-zero": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", - "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==", - "dev": true, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-number": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", - "dev": true, - "engines": { - "node": ">=0.12.0" - } - }, - "node_modules/is-number-object": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", - "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", - "dev": true, - "dependencies": { - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-plain-obj": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", - "integrity": "sha512-yvkRyxmFKEOQ4pNXCmJG5AEQNlXJS5LaONXo5/cLdTZdWvsZ1ioJEonLGAosKlMWE8lwUy/bJzMjcw8az73+Fg==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/is-port-reachable": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/is-port-reachable/-/is-port-reachable-3.1.0.tgz", - "integrity": "sha512-vjc0SSRNZ32s9SbZBzGaiP6YVB+xglLShhgZD/FHMZUXBvQWaV9CtzgeVhjccFJrI6RAMV+LX7NYxueW/A8W5A==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/is-regex": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", - "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-shared-array-buffer": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", - "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-string": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", - "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", - "dev": true, - "dependencies": { - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-subdir": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/is-subdir/-/is-subdir-1.2.0.tgz", - "integrity": "sha512-2AT6j+gXe/1ueqbW6fLZJiIw3F8iXGJtt0yDrZaBhAZEG1raiTxKWU+IPqMCzQAXOUCKdA4UDMgacKH25XG2Cw==", - "dev": true, - "dependencies": { - "better-path-resolve": "1.0.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/is-symbol": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", - "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", - "dev": true, - "dependencies": { - "has-symbols": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-typed-array": { - "version": "1.1.12", - "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz", - "integrity": "sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg==", - "dev": true, - "dependencies": { - "which-typed-array": "^1.1.11" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-unicode-supported": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz", - "integrity": "sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/is-weakref": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", - "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-windows": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz", - "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/isarray": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", - "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", - "dev": true - }, - "node_modules/isexe": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", - "dev": true - }, - "node_modules/isows": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/isows/-/isows-1.0.3.tgz", - "integrity": "sha512-2cKei4vlmg2cxEjm3wVSqn8pcoRF/LX/wpifuuNquFO4SQmPwarClT+SUCA2lt+l581tTeZIPIZuIDo2jWN1fg==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/wagmi-dev" - } - ], - "peerDependencies": { - "ws": "*" - } - }, - "node_modules/jackspeak": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-4.0.1.tgz", - "integrity": "sha512-cub8rahkh0Q/bw1+GxP7aeSe29hHHn2V4m29nnDlvCdlgU+3UGxkZp7Z53jLUdpX3jdTO0nJZUDl3xvbWc2Xog==", - "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "@isaacs/cliui": "^8.0.2" - }, - "engines": { - "node": "20 || >=22" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - }, - "optionalDependencies": { - "@pkgjs/parseargs": "^0.11.0" - } - }, - "node_modules/js-sha3": { - "version": "0.8.0", - "resolved": "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz", - "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==", - "dev": true - }, - "node_modules/js-tokens": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", - "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true - }, - "node_modules/js-yaml": { - "version": "3.14.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", - "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", - "dev": true, - "dependencies": { - "argparse": "^1.0.7", - "esprima": "^4.0.0" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, - "node_modules/json-buffer": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", - "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==", - "dev": true - }, - "node_modules/json-parse-even-better-errors": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", - "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", - "dev": true - }, - "node_modules/json-schema-traverse": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", - "dev": true - }, - "node_modules/json-stable-stringify-without-jsonify": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", - "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==", - "dev": true - }, - "node_modules/jsonfile": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz", - "integrity": "sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==", - "dev": true, - "optionalDependencies": { - "graceful-fs": "^4.1.6" - } - }, - "node_modules/jsonschema": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/jsonschema/-/jsonschema-1.4.1.tgz", - "integrity": "sha512-S6cATIPVv1z0IlxdN+zUk5EPjkGCdnhN4wVSBlvoUO1tOLJootbo9CquNJmbIh4yikWHiUedhRYrNPn1arpEmQ==", - "dev": true, - "engines": { - "node": "*" - } - }, - "node_modules/keccak": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/keccak/-/keccak-3.0.4.tgz", - "integrity": "sha512-3vKuW0jV8J3XNTzvfyicFR5qvxrSAGl7KIhvgOu5cmWwM7tZRj3fMbj/pfIf4be7aznbc+prBWGjywox/g2Y6Q==", - "dev": true, - "hasInstallScript": true, - "dependencies": { - "node-addon-api": "^2.0.0", - "node-gyp-build": "^4.2.0", - "readable-stream": "^3.6.0" - }, - "engines": { - "node": ">=10.0.0" - } - }, - "node_modules/keyv": { - "version": "4.5.4", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz", - "integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==", - "dev": true, - "license": "MIT", - "dependencies": { - "json-buffer": "3.0.1" - } - }, - "node_modules/kind-of": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", - "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/klaw": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/klaw/-/klaw-1.3.1.tgz", - "integrity": "sha512-TED5xi9gGQjGpNnvRWknrwAB1eL5GciPfVFOt3Vk1OJCVDQbzuSfrF3hkUQKlsgKrG1F+0t5W0m+Fje1jIt8rw==", - "dev": true, - "optionalDependencies": { - "graceful-fs": "^4.1.9" - } - }, - "node_modules/kleur": { - "version": "4.1.5", - "resolved": "https://registry.npmjs.org/kleur/-/kleur-4.1.5.tgz", - "integrity": "sha512-o+NO+8WrRiQEE4/7nwRJhN1HWpVmJm511pBHUxPLtp0BUISzlBplORYSmTclCnJvQq2tKu/sgl3xVpkc7ZWuQQ==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/latest-version": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/latest-version/-/latest-version-7.0.0.tgz", - "integrity": "sha512-KvNT4XqAMzdcL6ka6Tl3i2lYeFDgXNCuIX+xNx6ZMVR1dFq+idXd9FLKNMOIx0t9mJ9/HudyX4oZWXZQ0UJHeg==", - "dev": true, - "dependencies": { - "package-json": "^8.1.0" - }, - "engines": { - "node": ">=14.16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/levn": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", - "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", - "dev": true, - "dependencies": { - "prelude-ls": "^1.2.1", - "type-check": "~0.4.0" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/lines-and-columns": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", - "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==", - "dev": true - }, - "node_modules/load-yaml-file": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/load-yaml-file/-/load-yaml-file-0.2.0.tgz", - "integrity": "sha512-OfCBkGEw4nN6JLtgRidPX6QxjBQGQf72q3si2uvqyFEMbycSFFHwAZeXx6cJgFM9wmLrf9zBwCP3Ivqa+LLZPw==", - "dev": true, - "dependencies": { - "graceful-fs": "^4.1.5", - "js-yaml": "^3.13.0", - "pify": "^4.0.1", - "strip-bom": "^3.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", - "dev": true, - "dependencies": { - "p-locate": "^4.1.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/lodash": { - "version": "4.18.1", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.18.1.tgz", - "integrity": "sha512-dMInicTPVE8d1e5otfwmmjlxkZoUpiVLwyeTdUsi/Caj/gfzzblBcCE5sRHV/AsjuCmxWrte2TNGSYuCeCq+0Q==", - "dev": true, - "license": "MIT" - }, - "node_modules/lodash.isequal": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/lodash.isequal/-/lodash.isequal-4.5.0.tgz", - "integrity": "sha512-pDo3lu8Jhfjqls6GkMgpahsF9kCyayhgykjyLMNFTKWrpVdAQtYyB4muAMWozBB4ig/dtWAmsMxLEI8wuz+DYQ==", - "dev": true - }, - "node_modules/lodash.merge": { - "version": "4.6.2", - "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", - "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==", - "dev": true - }, - "node_modules/lodash.startcase": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/lodash.startcase/-/lodash.startcase-4.4.0.tgz", - "integrity": "sha512-+WKqsK294HMSc2jEbNgpHpd0JfIBhp7rEV4aqXWqFr6AlXov+SlcgB1Fv01y2kGe3Gc8nMW7VA0SrGuSkRfIEg==", - "dev": true - }, - "node_modules/lodash.truncate": { - "version": "4.4.2", - "resolved": "https://registry.npmjs.org/lodash.truncate/-/lodash.truncate-4.4.2.tgz", - "integrity": "sha512-jttmRe7bRse52OsWIMDLaXxWqRAmtIUccAQ3garviCqJjafXOfNMO0yMfNpdD6zbGaTU0P5Nz7e7gAT6cKmJRw==", - "dev": true - }, - "node_modules/log-symbols": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", - "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", - "dev": true, - "dependencies": { - "chalk": "^4.1.0", - "is-unicode-supported": "^0.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/log-symbols/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/log-symbols/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/log-symbols/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/log-symbols/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/log-symbols/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/log-symbols/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/loupe": { - "version": "2.3.6", - "resolved": "https://registry.npmjs.org/loupe/-/loupe-2.3.6.tgz", - "integrity": "sha512-RaPMZKiMy8/JruncMU5Bt6na1eftNoo++R4Y+N2FrxkDVTrGvcyzFTsaGif4QTeKESheMGegbhw6iUAq+5A8zA==", - "dev": true, - "dependencies": { - "get-func-name": "^2.0.0" - } - }, - "node_modules/lowercase-keys": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/lowercase-keys/-/lowercase-keys-3.0.0.tgz", - "integrity": "sha512-ozCC6gdQ+glXOQsveKD0YsDy8DSQFjDTz4zyzEHNV5+JP5D62LmfDZ6o1cycFx9ouG940M5dE8C8CTewdj2YWQ==", - "dev": true, - "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/lru_map": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/lru_map/-/lru_map-0.3.3.tgz", - "integrity": "sha512-Pn9cox5CsMYngeDbmChANltQl+5pi6XmTrraMSzhPmMBbmgcxmqWry0U3PGapCU1yB4/LqCcom7qhHZiF/jGfQ==", - "dev": true - }, - "node_modules/lru-cache": { - "version": "11.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-11.0.0.tgz", - "integrity": "sha512-Qv32eSV1RSCfhY3fpPE2GNZ8jgM9X7rdAfemLWqTUxwiyIC4jJ6Sy0fZ8H+oLWevO6i4/bizg7c8d8i6bxrzbA==", - "dev": true, - "license": "ISC", - "engines": { - "node": "20 || >=22" - } - }, - "node_modules/map-obj": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-4.3.0.tgz", - "integrity": "sha512-hdN1wVrZbb29eBGiGjJbeP8JbKjq1urkHJ/LIP/NY48MZ1QVXUsQBV1G1zvYFHn1XE06cwjBsOI2K3Ulnj1YXQ==", - "dev": true, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/math-intrinsics": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz", - "integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/md5.js": { - "version": "1.3.5", - "resolved": "https://registry.npmjs.org/md5.js/-/md5.js-1.3.5.tgz", - "integrity": "sha512-xitP+WxNPcTTOgnTJcrhM0xvdPepipPSf3I8EIpGKeFLjt3PlJLIDG3u8EX53ZIubkb+5U2+3rELYpEhHhzdkg==", - "dev": true, - "dependencies": { - "hash-base": "^3.0.0", - "inherits": "^2.0.1", - "safe-buffer": "^5.1.2" - } - }, - "node_modules/memorystream": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/memorystream/-/memorystream-0.3.1.tgz", - "integrity": "sha512-S3UwM3yj5mtUSEfP41UZmt/0SCoVYUcU1rkXv+BQ5Ig8ndL4sPoJNBUJERafdPb5jjHJGuMgytgKvKIf58XNBw==", - "dev": true, - "engines": { - "node": ">= 0.10.0" - } - }, - "node_modules/meow": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/meow/-/meow-6.1.1.tgz", - "integrity": "sha512-3YffViIt2QWgTy6Pale5QpopX/IvU3LPL03jOTqp6pGj3VjesdO/U8CuHMKpnQr4shCNCM5fd5XFFvIIl6JBHg==", - "dev": true, - "dependencies": { - "@types/minimist": "^1.2.0", - "camelcase-keys": "^6.2.2", - "decamelize-keys": "^1.1.0", - "hard-rejection": "^2.1.0", - "minimist-options": "^4.0.2", - "normalize-package-data": "^2.5.0", - "read-pkg-up": "^7.0.1", - "redent": "^3.0.0", - "trim-newlines": "^3.0.0", - "type-fest": "^0.13.1", - "yargs-parser": "^18.1.3" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/meow/node_modules/type-fest": { - "version": "0.13.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.13.1.tgz", - "integrity": "sha512-34R7HTnG0XIJcBSn5XhDd7nNFPRcXYRZrBB2O2jdKqYODldSzBAqzsWoZYYvduky73toYS/ESqxPvkDf/F0XMg==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/merge2": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", - "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", - "dev": true, - "engines": { - "node": ">= 8" - } - }, - "node_modules/micro-ftch": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/micro-ftch/-/micro-ftch-0.3.1.tgz", - "integrity": "sha512-/0LLxhzP0tfiR5hcQebtudP56gUurs2CLkGarnCiB/OqEyUFQ6U3paQi/tgLv0hBJYt2rnr9MNpxz4fiiugstg==", - "dev": true - }, - "node_modules/micromatch": { - "version": "4.0.5", - "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.5.tgz", - "integrity": "sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==", - "dev": true, - "dependencies": { - "braces": "^3.0.2", - "picomatch": "^2.3.1" - }, - "engines": { - "node": ">=8.6" - } - }, - "node_modules/mime-db": { - "version": "1.52.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", - "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/mime-types": { - "version": "2.1.35", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", - "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", - "dev": true, - "license": "MIT", - "dependencies": { - "mime-db": "1.52.0" - }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/mimic-response": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-4.0.0.tgz", - "integrity": "sha512-e5ISH9xMYU0DzrT+jl8q2ze9D6eWBto+I8CNpe+VI+K2J/F/k3PdkdTdz4wvGVH4NTpo+NRYTVIuMQEMMcsLqg==", - "dev": true, - "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/min-indent": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/min-indent/-/min-indent-1.0.1.tgz", - "integrity": "sha512-I9jwMn07Sy/IwOj3zVkVik2JTvgpaykDZEigL6Rx6N9LbMywwUSMtxET+7lVoDLLd3O3IXwJwvuuns8UB/HeAg==", - "dev": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/minimalistic-assert": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", - "integrity": "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==", - "dev": true - }, - "node_modules/minimalistic-crypto-utils": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", - "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==", - "dev": true - }, - "node_modules/minimatch": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.5.tgz", - "integrity": "sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^1.1.7" - }, - "engines": { - "node": "*" - } - }, - "node_modules/minimist": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", - "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", - "dev": true, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/minimist-options": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/minimist-options/-/minimist-options-4.1.0.tgz", - "integrity": "sha512-Q4r8ghd80yhO/0j1O3B2BjweX3fiHg9cdOwjJd2J76Q135c+NDxGCqdYKQ1SKBuFfgWbAUzBfvYjPUEeNgqN1A==", - "dev": true, - "dependencies": { - "arrify": "^1.0.1", - "is-plain-obj": "^1.1.0", - "kind-of": "^6.0.3" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/minipass": { - "version": "7.1.2", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.2.tgz", - "integrity": "sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">=16 || 14 >=14.17" - } - }, - "node_modules/mixme": { - "version": "0.5.9", - "resolved": "https://registry.npmjs.org/mixme/-/mixme-0.5.9.tgz", - "integrity": "sha512-VC5fg6ySUscaWUpI4gxCBTQMH2RdUpNrk+MsbpCYtIvf9SBJdiUey4qE7BXviJsJR4nDQxCZ+3yaYNW3guz/Pw==", - "dev": true, - "engines": { - "node": ">= 8.0.0" - } - }, - "node_modules/mkdirp": { - "version": "0.5.6", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.6.tgz", - "integrity": "sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==", - "dev": true, - "dependencies": { - "minimist": "^1.2.6" - }, - "bin": { - "mkdirp": "bin/cmd.js" - } - }, - "node_modules/mnemonist": { - "version": "0.38.5", - "resolved": "https://registry.npmjs.org/mnemonist/-/mnemonist-0.38.5.tgz", - "integrity": "sha512-bZTFT5rrPKtPJxj8KSV0WkPyNxl72vQepqqVUAW2ARUpUSF2qXMB6jZj7hW5/k7C1rtpzqbD/IIbJwLXUjCHeg==", - "dev": true, - "dependencies": { - "obliterator": "^2.0.0" - } - }, - "node_modules/mocha": { - "version": "10.8.2", - "resolved": "https://registry.npmjs.org/mocha/-/mocha-10.8.2.tgz", - "integrity": "sha512-VZlYo/WE8t1tstuRmqgeyBgCbJc/lEdopaa+axcKzTBJ+UIdlAB9XnmvTCAH4pwR4ElNInaedhEBmZD8iCSVEg==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-colors": "^4.1.3", - "browser-stdout": "^1.3.1", - "chokidar": "^3.5.3", - "debug": "^4.3.5", - "diff": "^5.2.0", - "escape-string-regexp": "^4.0.0", - "find-up": "^5.0.0", - "glob": "^8.1.0", - "he": "^1.2.0", - "js-yaml": "^4.1.0", - "log-symbols": "^4.1.0", - "minimatch": "^5.1.6", - "ms": "^2.1.3", - "serialize-javascript": "^6.0.2", - "strip-json-comments": "^3.1.1", - "supports-color": "^8.1.1", - "workerpool": "^6.5.1", - "yargs": "^16.2.0", - "yargs-parser": "^20.2.9", - "yargs-unparser": "^2.0.0" - }, - "bin": { - "_mocha": "bin/_mocha", - "mocha": "bin/mocha.js" - }, - "engines": { - "node": ">= 14.0.0" - } - }, - "node_modules/mocha/node_modules/argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "dev": true - }, - "node_modules/mocha/node_modules/brace-expansion": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.0.tgz", - "integrity": "sha512-TN1kCZAgdgweJhWWpgKYrQaMNHcDULHkWwQIspdtjV4Y5aurRdZpjAqn6yX3FPqTA9ngHCc4hJxMAMgGfve85w==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0" - } - }, - "node_modules/mocha/node_modules/cliui": { - "version": "7.0.4", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz", - "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==", - "dev": true, - "dependencies": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.0", - "wrap-ansi": "^7.0.0" - } - }, - "node_modules/mocha/node_modules/escape-string-regexp": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/mocha/node_modules/find-up": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", - "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", - "dev": true, - "dependencies": { - "locate-path": "^6.0.0", - "path-exists": "^4.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/mocha/node_modules/glob": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/glob/-/glob-8.1.0.tgz", - "integrity": "sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ==", - "deprecated": "Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me", - "dev": true, - "license": "ISC", - "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^5.0.1", - "once": "^1.3.0" - }, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "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/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "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", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", - "dev": true, - "dependencies": { - "argparse": "^2.0.1" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, - "node_modules/mocha/node_modules/locate-path": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", - "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", - "dev": true, - "dependencies": { - "p-locate": "^5.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/mocha/node_modules/minimatch": { - "version": "5.1.9", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.1.9.tgz", - "integrity": "sha512-7o1wEA2RyMP7Iu7GNba9vc0RWWGACJOCZBJX2GJWip0ikV+wcOsgVuY9uE8CPiyQhkGFSlhuSkZPavN7u1c2Fw==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^2.0.1" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/mocha/node_modules/p-locate": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", - "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", - "dev": true, - "dependencies": { - "p-limit": "^3.0.2" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/mocha/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "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/mocha/node_modules/yargs": { - "version": "16.2.0", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz", - "integrity": "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==", - "dev": true, - "dependencies": { - "cliui": "^7.0.2", - "escalade": "^3.1.1", - "get-caller-file": "^2.0.5", - "require-directory": "^2.1.1", - "string-width": "^4.2.0", - "y18n": "^5.0.5", - "yargs-parser": "^20.2.2" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/mocha/node_modules/yargs-parser": { - "version": "20.2.9", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz", - "integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">=10" - } - }, - "node_modules/ms": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", - "dev": true, - "license": "MIT" - }, - "node_modules/natural-compare": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", - "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", - "dev": true - }, - "node_modules/neo-async": { - "version": "2.6.2", - "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", - "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==", - "dev": true - }, - "node_modules/node-addon-api": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-2.0.2.tgz", - "integrity": "sha512-Ntyt4AIXyaLIuMHF6IOoTakB3K+RWxwtsHNRxllEoA6vPwP9o4866g6YWDLUdnucilZhmkxiHwHr11gAENw+QA==", - "dev": true - }, - "node_modules/node-emoji": { - "version": "1.11.0", - "resolved": "https://registry.npmjs.org/node-emoji/-/node-emoji-1.11.0.tgz", - "integrity": "sha512-wo2DpQkQp7Sjm2A0cq+sN7EHKO6Sl0ctXeBdFZrL9T9+UywORbufTcTZxom8YqpLQt/FqNMUkOpkZrJVYSKD3A==", - "dev": true, - "dependencies": { - "lodash": "^4.17.21" - } - }, - "node_modules/node-fetch": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", - "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", - "dev": true, - "dependencies": { - "whatwg-url": "^5.0.0" - }, - "engines": { - "node": "4.x || >=6.0.0" - }, - "peerDependencies": { - "encoding": "^0.1.0" - }, - "peerDependenciesMeta": { - "encoding": { - "optional": true - } - } - }, - "node_modules/node-gyp-build": { - "version": "4.6.1", - "resolved": "https://registry.npmjs.org/node-gyp-build/-/node-gyp-build-4.6.1.tgz", - "integrity": "sha512-24vnklJmyRS8ViBNI8KbtK/r/DmXQMRiOMXTNz2nrTnAYUwjmEEbnnpB/+kt+yWRv73bPsSPRFddrcIbAxSiMQ==", - "dev": true, - "bin": { - "node-gyp-build": "bin.js", - "node-gyp-build-optional": "optional.js", - "node-gyp-build-test": "build-test.js" - } - }, - "node_modules/node-interval-tree": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/node-interval-tree/-/node-interval-tree-2.1.2.tgz", - "integrity": "sha512-bJ9zMDuNGzVQg1xv0bCPzyEDxHgbrx7/xGj6CDokvizZZmastPsOh0JJLuY8wA5q2SfX1TLNMk7XNV8WxbGxzA==", - "dev": true, - "dependencies": { - "shallowequal": "^1.1.0" - }, - "engines": { - "node": ">= 14.0.0" - } - }, - "node_modules/nofilter": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/nofilter/-/nofilter-3.1.0.tgz", - "integrity": "sha512-l2NNj07e9afPnhAhvgVrCD/oy2Ai1yfLpuo3EpiO1jFTsB4sFz6oIfAfSZyQzVpkZQ9xS8ZS5g1jCBgq4Hwo0g==", - "dev": true, - "engines": { - "node": ">=12.19" - } - }, - "node_modules/nopt": { - "version": "3.0.6", - "resolved": "https://registry.npmjs.org/nopt/-/nopt-3.0.6.tgz", - "integrity": "sha512-4GUt3kSEYmk4ITxzB/b9vaIDfUVWN/Ml1Fwl11IlnIG2iaJ9O6WXZ9SrYM9NLI8OCBieN2Y8SWC2oJV0RQ7qYg==", - "dev": true, - "dependencies": { - "abbrev": "1" - }, - "bin": { - "nopt": "bin/nopt.js" - } - }, - "node_modules/normalize-package-data": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz", - "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==", - "dev": true, - "dependencies": { - "hosted-git-info": "^2.1.4", - "resolve": "^1.10.0", - "semver": "2 || 3 || 4 || 5", - "validate-npm-package-license": "^3.0.1" - } - }, - "node_modules/normalize-package-data/node_modules/semver": { - "version": "5.7.2", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", - "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", - "dev": true, - "bin": { - "semver": "bin/semver" - } - }, - "node_modules/normalize-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", - "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/normalize-url": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-8.0.1.tgz", - "integrity": "sha512-IO9QvjUMWxPQQhs60oOu10CRkWCiZzSUkzbXGGV9pviYl1fXYcvkzQ5jV9z8Y6un8ARoVRl4EtC6v6jNqbaJ/w==", - "dev": true, - "engines": { - "node": ">=14.16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/number-to-bn": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/number-to-bn/-/number-to-bn-1.7.0.tgz", - "integrity": "sha512-wsJ9gfSz1/s4ZsJN01lyonwuxA1tml6X1yBDnfpMglypcBRFZZkus26EdPSlqS5GJfYddVZa22p3VNb3z5m5Ig==", - "dev": true, - "dependencies": { - "bn.js": "4.11.6", - "strip-hex-prefix": "1.0.0" - }, - "engines": { - "node": ">=6.5.0", - "npm": ">=3" - } - }, - "node_modules/number-to-bn/node_modules/bn.js": { - "version": "4.11.6", - "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.11.6.tgz", - "integrity": "sha512-XWwnNNFCuuSQ0m3r3C4LE3EiORltHd9M05pq6FOlVeiophzRbMo50Sbz1ehl8K3Z+jw9+vmgnXefY1hz8X+2wA==", - "dev": true - }, - "node_modules/object-inspect": { - "version": "1.13.1", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.1.tgz", - "integrity": "sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==", - "dev": true, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/object-keys": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", - "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", - "dev": true, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/object.assign": { - "version": "4.1.4", - "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", - "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.1.4", - "has-symbols": "^1.0.3", - "object-keys": "^1.1.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/obliterator": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/obliterator/-/obliterator-2.0.4.tgz", - "integrity": "sha512-lgHwxlxV1qIg1Eap7LgIeoBWIMFibOjbrYPIPJZcI1mmGAI2m3lNYpK12Y+GBdPQ0U1hRwSord7GIaawz962qQ==", - "dev": true - }, - "node_modules/once": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", - "dev": true, - "dependencies": { - "wrappy": "1" - } - }, - "node_modules/optionator": { - "version": "0.9.3", - "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.3.tgz", - "integrity": "sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg==", - "dev": true, - "dependencies": { - "@aashutoshrathi/word-wrap": "^1.2.3", - "deep-is": "^0.1.3", - "fast-levenshtein": "^2.0.6", - "levn": "^0.4.1", - "prelude-ls": "^1.2.1", - "type-check": "^0.4.0" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/ordinal": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/ordinal/-/ordinal-1.0.3.tgz", - "integrity": "sha512-cMddMgb2QElm8G7vdaa02jhUNbTSrhsgAGUz1OokD83uJTwSUn+nKoNoKVVaRa08yF6sgfO7Maou1+bgLd9rdQ==", - "dev": true - }, - "node_modules/os-tmpdir": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", - "integrity": "sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/outdent": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/outdent/-/outdent-0.5.0.tgz", - "integrity": "sha512-/jHxFIzoMXdqPzTaCpFzAAWhpkSjZPF4Vsn6jAfNpmbH/ymsmd7Qc6VE9BGn0L6YMj6uwpQLxCECpus4ukKS9Q==", - "dev": true - }, - "node_modules/p-cancelable": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-cancelable/-/p-cancelable-3.0.0.tgz", - "integrity": "sha512-mlVgR3PGuzlo0MmTdk4cXqXWlwQDLnONTAg6sm62XkMJEiRxN3GL3SffkYvqwonbkJBcrI7Uvv5Zh9yjvn2iUw==", - "dev": true, - "engines": { - "node": ">=12.20" - } - }, - "node_modules/p-filter": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/p-filter/-/p-filter-2.1.0.tgz", - "integrity": "sha512-ZBxxZ5sL2HghephhpGAQdoskxplTwr7ICaehZwLIlfL6acuVgZPm8yBNuRAFBGEqtD/hmUeq9eqLg2ys9Xr/yw==", - "dev": true, - "dependencies": { - "p-map": "^2.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/p-filter/node_modules/p-map": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/p-map/-/p-map-2.1.0.tgz", - "integrity": "sha512-y3b8Kpd8OAN444hxfBbFfj1FY/RjtTd8tzYwhUqNYXx0fXx2iX4maP4Qr6qhIKbQXI02wTLAda4fYUbDagTUFw==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/p-limit": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", - "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", - "dev": true, - "dependencies": { - "yocto-queue": "^0.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/p-locate": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", - "dev": true, - "dependencies": { - "p-limit": "^2.2.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/p-locate/node_modules/p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", - "dev": true, - "dependencies": { - "p-try": "^2.0.0" - }, - "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/p-map": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/p-map/-/p-map-4.0.0.tgz", - "integrity": "sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==", - "dev": true, - "dependencies": { - "aggregate-error": "^3.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/package-json": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/package-json/-/package-json-8.1.1.tgz", - "integrity": "sha512-cbH9IAIJHNj9uXi196JVsRlt7cHKak6u/e6AkL/bkRelZ7rlL3X1YKxsZwa36xipOEKAsdtmaG6aAJoM1fx2zA==", - "dev": true, - "dependencies": { - "got": "^12.1.0", - "registry-auth-token": "^5.0.1", - "registry-url": "^6.0.0", - "semver": "^7.3.7" - }, - "engines": { - "node": ">=14.16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/package-json-from-dist": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/package-json-from-dist/-/package-json-from-dist-1.0.0.tgz", - "integrity": "sha512-dATvCeZN/8wQsGywez1mzHtTlP22H8OEfPrVMLNr4/eGa+ijtLn/6M5f0dY8UKNrC2O9UCU6SSoG3qRKnt7STw==", - "dev": true, - "license": "BlueOak-1.0.0" - }, - "node_modules/parent-module": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", - "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", - "dev": true, - "dependencies": { - "callsites": "^3.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/parse-json": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", - "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", - "dev": true, - "dependencies": { - "@babel/code-frame": "^7.0.0", - "error-ex": "^1.3.1", - "json-parse-even-better-errors": "^2.3.0", - "lines-and-columns": "^1.1.6" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/path-is-absolute": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/path-key": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", - "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/path-parse": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", - "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", - "dev": true - }, - "node_modules/path-scurry": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-2.0.0.tgz", - "integrity": "sha512-ypGJsmGtdXUOeM5u93TyeIEfEhM6s+ljAhrk5vAvSx8uyY/02OvrZnA0YNGUrPXfpJMgI1ODd3nwz8Npx4O4cg==", - "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "lru-cache": "^11.0.0", - "minipass": "^7.1.2" - }, - "engines": { - "node": "20 || >=22" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/path-type": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz", - "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/pathval": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.1.tgz", - "integrity": "sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ==", - "dev": true, - "engines": { - "node": "*" - } - }, - "node_modules/pbkdf2": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/pbkdf2/-/pbkdf2-3.1.2.tgz", - "integrity": "sha512-iuh7L6jA7JEGu2WxDwtQP1ddOpaJNC4KlDEFfdQajSGgGPNi4OyDc2R7QnbY2bR9QjBVGwgvTdNJZoE7RaxUMA==", - "dev": true, - "dependencies": { - "create-hash": "^1.1.2", - "create-hmac": "^1.1.4", - "ripemd160": "^2.0.1", - "safe-buffer": "^5.0.1", - "sha.js": "^2.4.8" - }, - "engines": { - "node": ">=0.12" - } - }, - "node_modules/picomatch": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.2.tgz", - "integrity": "sha512-V7+vQEJ06Z+c5tSye8S+nHUfI51xoXIXjHQ99cQtKUkQqqO1kO/KCJUfZXuB47h/YBlDhah2H3hdUGXn8ie0oA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8.6" - }, - "funding": { - "url": "https://github.com/sponsors/jonschlinkert" - } - }, - "node_modules/pify": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz", - "integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/pkg-dir": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-4.2.0.tgz", - "integrity": "sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==", - "dev": true, - "dependencies": { - "find-up": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/pluralize": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/pluralize/-/pluralize-8.0.0.tgz", - "integrity": "sha512-Nc3IT5yHzflTfbjgqWcCPpo7DaKy4FnpB0l/zCAW0Tc7jxAiuqSxHasntB3D7887LSrA93kDJ9IXovxJYxyLCA==", - "dev": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/preferred-pm": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/preferred-pm/-/preferred-pm-3.1.2.tgz", - "integrity": "sha512-nk7dKrcW8hfCZ4H6klWcdRknBOXWzNQByJ0oJyX97BOupsYD+FzLS4hflgEu/uPUEHZCuRfMxzCBsuWd7OzT8Q==", - "dev": true, - "dependencies": { - "find-up": "^5.0.0", - "find-yarn-workspace-root2": "1.2.16", - "path-exists": "^4.0.0", - "which-pm": "2.0.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/preferred-pm/node_modules/find-up": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", - "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", - "dev": true, - "dependencies": { - "locate-path": "^6.0.0", - "path-exists": "^4.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/preferred-pm/node_modules/locate-path": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", - "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", - "dev": true, - "dependencies": { - "p-locate": "^5.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/preferred-pm/node_modules/p-locate": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", - "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", - "dev": true, - "dependencies": { - "p-limit": "^3.0.2" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/prelude-ls": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", - "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==", - "dev": true, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/prettier": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.0.3.tgz", - "integrity": "sha512-L/4pUDMxcNa8R/EthV08Zt42WBO4h1rarVtK0K+QJG0X187OLo7l699jWw0GKuwzkPQ//jMFA/8Xm6Fh3J/DAg==", - "dev": true, - "bin": { - "prettier": "bin/prettier.cjs" - }, - "engines": { - "node": ">=14" - }, - "funding": { - "url": "https://github.com/prettier/prettier?sponsor=1" - } - }, - "node_modules/prettier-plugin-solidity": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/prettier-plugin-solidity/-/prettier-plugin-solidity-1.1.3.tgz", - "integrity": "sha512-fQ9yucPi2sBbA2U2Xjh6m4isUTJ7S7QLc/XDDsktqqxYfTwdYKJ0EnnywXHwCGAaYbQNK+HIYPL1OemxuMsgeg==", - "dev": true, - "dependencies": { - "@solidity-parser/parser": "^0.16.0", - "semver": "^7.3.8", - "solidity-comments-extractor": "^0.0.7" - }, - "engines": { - "node": ">=12" - }, - "peerDependencies": { - "prettier": ">=2.3.0 || >=3.0.0-alpha.0" - } - }, - "node_modules/prettier-plugin-solidity/node_modules/@solidity-parser/parser": { - "version": "0.16.1", - "resolved": "https://registry.npmjs.org/@solidity-parser/parser/-/parser-0.16.1.tgz", - "integrity": "sha512-PdhRFNhbTtu3x8Axm0uYpqOy/lODYQK+MlYSgqIsq2L8SFYEHJPHNUiOTAJbDGzNjjr1/n9AcIayxafR/fWmYw==", - "dev": true, - "dependencies": { - "antlr4ts": "^0.5.0-alpha.4" - } - }, - "node_modules/proper-lockfile": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", - "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", - "dev": true, - "dependencies": { - "graceful-fs": "^4.2.4", - "retry": "^0.12.0", - "signal-exit": "^3.0.2" - } - }, - "node_modules/proto-list": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/proto-list/-/proto-list-1.2.4.tgz", - "integrity": "sha512-vtK/94akxsTMhe0/cbfpR+syPuszcuwhqVjJq26CuNDgFGj682oRBXOP5MJpv2r7JtE8MsiepGIqvvOTBwn2vA==", - "dev": true - }, - "node_modules/proxy-from-env": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-2.1.0.tgz", - "integrity": "sha512-cJ+oHTW1VAEa8cJslgmUZrc+sjRKgAKl3Zyse6+PV38hZe/V6Z14TbCuXcan9F9ghlz4QrFr2c92TNF82UkYHA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - } - }, - "node_modules/pseudomap": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz", - "integrity": "sha512-b/YwNhb8lk1Zz2+bXXpS/LK9OisiZZ1SNsSLxN1x2OXVEhW2Ckr/7mWE5vrC1ZTiJlD9g19jWszTmJsB+oEpFQ==", - "dev": true - }, - "node_modules/punycode": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.0.tgz", - "integrity": "sha512-Yxz2kRwT90aPiWEMHVYnEf4+rhwF1tBmmZ4KepCP+Wkium9JxtWnUm1nqGwpiAHr/tnTSeHqr3wb++jgSkXjhA==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/queue-microtask": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", - "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ] - }, - "node_modules/quick-lru": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-4.0.1.tgz", - "integrity": "sha512-ARhCpm70fzdcvNQfPoy49IaanKkTlRWF2JMzqhcJbhSFRZv7nPTvZJdcY7301IPmvW+/p0RgIWnQDLJxifsQ7g==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/randombytes": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", - "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", - "dev": true, - "dependencies": { - "safe-buffer": "^5.1.0" - } - }, - "node_modules/raw-body": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", - "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/rc": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", - "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", - "dev": true, - "dependencies": { - "deep-extend": "^0.6.0", - "ini": "~1.3.0", - "minimist": "^1.2.0", - "strip-json-comments": "~2.0.1" - }, - "bin": { - "rc": "cli.js" - } - }, - "node_modules/rc/node_modules/strip-json-comments": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", - "integrity": "sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/read-pkg": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-5.2.0.tgz", - "integrity": "sha512-Ug69mNOpfvKDAc2Q8DRpMjjzdtrnv9HcSMX+4VsZxD1aZ6ZzrIE7rlzXBtWTyhULSMKg076AW6WR5iZpD0JiOg==", - "dev": true, - "dependencies": { - "@types/normalize-package-data": "^2.4.0", - "normalize-package-data": "^2.5.0", - "parse-json": "^5.0.0", - "type-fest": "^0.6.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/read-pkg-up": { - "version": "7.0.1", - "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-7.0.1.tgz", - "integrity": "sha512-zK0TB7Xd6JpCLmlLmufqykGE+/TlOePD6qKClNW7hHDKFh/J7/7gCWGR7joEQEW1bKq3a3yUZSObOoWLFQ4ohg==", - "dev": true, - "dependencies": { - "find-up": "^4.1.0", - "read-pkg": "^5.2.0", - "type-fest": "^0.8.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/read-pkg-up/node_modules/type-fest": { - "version": "0.8.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", - "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/read-pkg/node_modules/type-fest": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.6.0.tgz", - "integrity": "sha512-q+MB8nYR1KDLrgr4G5yemftpMC7/QLqVndBmEEdqzmNj5dcFOO4Oo8qlwZE3ULT3+Zim1F8Kq4cBnikNhlCMlg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/read-yaml-file": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/read-yaml-file/-/read-yaml-file-1.1.0.tgz", - "integrity": "sha512-VIMnQi/Z4HT2Fxuwg5KrY174U1VdUIASQVWXXyqtNRtxSr9IYkn1rsI6Tb6HsrHCmB7gVpNwX6JxPTHcH6IoTA==", - "dev": true, - "dependencies": { - "graceful-fs": "^4.1.5", - "js-yaml": "^3.6.1", - "pify": "^4.0.1", - "strip-bom": "^3.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/readable-stream": { - "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", - "dev": true, - "dependencies": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/readdirp": { - "version": "3.6.0", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", - "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", - "dev": true, - "dependencies": { - "picomatch": "^2.2.1" - }, - "engines": { - "node": ">=8.10.0" - } - }, - "node_modules/rechoir": { - "version": "0.6.2", - "resolved": "https://registry.npmjs.org/rechoir/-/rechoir-0.6.2.tgz", - "integrity": "sha512-HFM8rkZ+i3zrV+4LQjwQ0W+ez98pApMGM3HUrN04j3CqzPOzl9nmP15Y8YXNm8QHGv/eacOVEjqhmWpkRV0NAw==", - "dev": true, - "dependencies": { - "resolve": "^1.1.6" - }, - "engines": { - "node": ">= 0.10" - } - }, - "node_modules/recursive-readdir": { - "version": "2.2.3", - "resolved": "https://registry.npmjs.org/recursive-readdir/-/recursive-readdir-2.2.3.tgz", - "integrity": "sha512-8HrF5ZsXk5FAH9dgsx3BlUer73nIhuj+9OrQwEbLTPOBzGkL1lsFCR01am+v+0m2Cmbs1nP12hLDl5FA7EszKA==", - "dev": true, - "dependencies": { - "minimatch": "^3.0.5" - }, - "engines": { - "node": ">=6.0.0" - } - }, - "node_modules/redent": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/redent/-/redent-3.0.0.tgz", - "integrity": "sha512-6tDA8g98We0zd0GvVeMT9arEOnTw9qM03L9cJXaCjrip1OO764RDBLBfrB4cwzNGDj5OA5ioymC9GkizgWJDUg==", - "dev": true, - "dependencies": { - "indent-string": "^4.0.0", - "strip-indent": "^3.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/redent/node_modules/strip-indent": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/strip-indent/-/strip-indent-3.0.0.tgz", - "integrity": "sha512-laJTa3Jb+VQpaC6DseHhF7dXVqHTfJPCRDaEbid/drOhgitgYku/letMUqOXFoWV0zIIUbjpdH2t+tYj4bQMRQ==", - "dev": true, - "dependencies": { - "min-indent": "^1.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/regenerator-runtime": { - "version": "0.14.0", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.0.tgz", - "integrity": "sha512-srw17NI0TUWHuGa5CFGGmhfNIeja30WMBfbslPNhf6JrqQlLN5gcrvig1oqPxiVaXb0oW0XRKtH6Nngs5lKCIA==", - "dev": true - }, - "node_modules/regexp.prototype.flags": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.1.tgz", - "integrity": "sha512-sy6TXMN+hnP/wMy+ISxg3krXx7BAtWVO4UouuCN/ziM9UEne0euamVNafDfvC83bRNr95y0V5iijeDQFUNpvrg==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "set-function-name": "^2.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/registry-auth-token": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/registry-auth-token/-/registry-auth-token-5.0.2.tgz", - "integrity": "sha512-o/3ikDxtXaA59BmZuZrJZDJv8NMDGSj+6j6XaeBmHw8eY1i1qd9+6H+LjVvQXx3HN6aRCGa1cUdJ9RaJZUugnQ==", - "dev": true, - "dependencies": { - "@pnpm/npm-conf": "^2.1.0" - }, - "engines": { - "node": ">=14" - } - }, - "node_modules/registry-url": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/registry-url/-/registry-url-6.0.1.tgz", - "integrity": "sha512-+crtS5QjFRqFCoQmvGduwYWEBng99ZvmFvF+cUJkGYF1L1BfU8C6Zp9T7f5vPAwyLkUExpvK+ANVZmGU49qi4Q==", - "dev": true, - "dependencies": { - "rc": "1.2.8" - }, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/repeat-string": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", - "integrity": "sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==", - "dev": true, - "engines": { - "node": ">=0.10" - } - }, - "node_modules/require-directory": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/require-main-filename": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", - "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", - "dev": true - }, - "node_modules/resolve": { - "version": "1.17.0", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.17.0.tgz", - "integrity": "sha512-ic+7JYiV8Vi2yzQGFWOkiZD5Z9z7O2Zhm9XMaTxdJExKasieFCr+yXZ/WmXsckHiKl12ar0y6XiXDx3m4RHn1w==", - "dev": true, - "dependencies": { - "path-parse": "^1.0.6" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/resolve-alpn": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/resolve-alpn/-/resolve-alpn-1.2.1.tgz", - "integrity": "sha512-0a1F4l73/ZFZOakJnQ3FvkJ2+gSTQWz/r2KE5OdDY0TxPm5h4GkqkWWfM47T7HsbnOtcJVEF4epCVy6u7Q3K+g==", - "dev": true - }, - "node_modules/resolve-from": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", - "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/responselike": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/responselike/-/responselike-3.0.0.tgz", - "integrity": "sha512-40yHxbNcl2+rzXvZuVkrYohathsSJlMTXKryG5y8uciHv1+xDLHQpgjG64JUO9nrEq2jGLH6IZ8BcZyw3wrweg==", - "dev": true, - "dependencies": { - "lowercase-keys": "^3.0.0" - }, - "engines": { - "node": ">=14.16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/retry": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", - "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==", - "dev": true, - "engines": { - "node": ">= 4" - } - }, - "node_modules/reusify": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", - "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", - "dev": true, - "engines": { - "iojs": ">=1.0.0", - "node": ">=0.10.0" - } - }, - "node_modules/rimraf": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-6.0.0.tgz", - "integrity": "sha512-u+yqhM92LW+89cxUQK0SRyvXYQmyuKHx0jkx4W7KfwLGLqJnQM5031Uv1trE4gB9XEXBM/s6MxKlfW95IidqaA==", - "dev": true, - "license": "ISC", - "dependencies": { - "glob": "^11.0.0" - }, - "bin": { - "rimraf": "dist/esm/bin.mjs" - }, - "engines": { - "node": "20 || >=22" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/ripemd160": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/ripemd160/-/ripemd160-2.0.2.tgz", - "integrity": "sha512-ii4iagi25WusVoiC4B4lq7pbXfAp3D9v5CwfkY33vffw2+pkDjY1D8GaN7spsxvCSx8dkPqOZCEZyfxcmJG2IA==", - "dev": true, - "dependencies": { - "hash-base": "^3.0.0", - "inherits": "^2.0.1" - } - }, - "node_modules/rlp": { - "version": "2.2.7", - "resolved": "https://registry.npmjs.org/rlp/-/rlp-2.2.7.tgz", - "integrity": "sha512-d5gdPmgQ0Z+AklL2NVXr/IoSjNZFfTVvQWzL/AM2AOcSzYP2xjlb0AC8YyCLc41MSNf6P6QVtjgPdmVtzb+4lQ==", - "dev": true, - "dependencies": { - "bn.js": "^5.2.0" - }, - "bin": { - "rlp": "bin/rlp" - } - }, - "node_modules/rlp/node_modules/bn.js": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", - "dev": true - }, - "node_modules/run-parallel": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", - "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "dependencies": { - "queue-microtask": "^1.2.2" - } - }, - "node_modules/safe-array-concat": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.1.tgz", - "integrity": "sha512-6XbUAseYE2KtOuGueyeobCySj9L4+66Tn6KQMOPQJrAJEowYKW/YR/MGJZl7FdydUdaFu4LYyDZjxf4/Nmo23Q==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "get-intrinsic": "^1.2.1", - "has-symbols": "^1.0.3", - "isarray": "^2.0.5" - }, - "engines": { - "node": ">=0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/safe-buffer": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ] - }, - "node_modules/safe-regex-test": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", - "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "get-intrinsic": "^1.1.3", - "is-regex": "^1.1.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/safer-buffer": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", - "dev": true - }, - "node_modules/sc-istanbul": { - "version": "0.4.6", - "resolved": "https://registry.npmjs.org/sc-istanbul/-/sc-istanbul-0.4.6.tgz", - "integrity": "sha512-qJFF/8tW/zJsbyfh/iT/ZM5QNHE3CXxtLJbZsL+CzdJLBsPD7SedJZoUA4d8iAcN2IoMp/Dx80shOOd2x96X/g==", - "dev": true, - "dependencies": { - "abbrev": "1.0.x", - "async": "1.x", - "escodegen": "1.8.x", - "esprima": "2.7.x", - "glob": "^5.0.15", - "handlebars": "^4.0.1", - "js-yaml": "3.x", - "mkdirp": "0.5.x", - "nopt": "3.x", - "once": "1.x", - "resolve": "1.1.x", - "supports-color": "^3.1.0", - "which": "^1.1.1", - "wordwrap": "^1.0.0" - }, - "bin": { - "istanbul": "lib/cli.js" - } - }, - "node_modules/sc-istanbul/node_modules/esprima": { - "version": "2.7.3", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-2.7.3.tgz", - "integrity": "sha512-OarPfz0lFCiW4/AV2Oy1Rp9qu0iusTKqykwTspGCZtPxmF81JR4MmIebvF1F9+UOKth2ZubLQ4XGGaU+hSn99A==", - "dev": true, - "bin": { - "esparse": "bin/esparse.js", - "esvalidate": "bin/esvalidate.js" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/sc-istanbul/node_modules/glob": { - "version": "5.0.15", - "resolved": "https://registry.npmjs.org/glob/-/glob-5.0.15.tgz", - "integrity": "sha512-c9IPMazfRITpmAAKi22dK1VKxGDX9ehhqfABDriL/lzO92xcUKEJPQHrVA/2YHSNFB4iFlykVmWvwo48nr3OxA==", - "dev": true, - "dependencies": { - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "2 || 3", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - }, - "engines": { - "node": "*" - } - }, - "node_modules/sc-istanbul/node_modules/has-flag": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-1.0.0.tgz", - "integrity": "sha512-DyYHfIYwAJmjAjSSPKANxI8bFY9YtFrgkAfinBojQ8YJTOuOuav64tMUJv584SES4xl74PmuaevIyaLESHdTAA==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/sc-istanbul/node_modules/resolve": { - "version": "1.1.7", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.1.7.tgz", - "integrity": "sha512-9znBF0vBcaSN3W2j7wKvdERPwqTxSpCq+if5C0WoTCyV9n24rua28jeuQ2pL/HOf+yUe/Mef+H/5p60K0Id3bg==", - "dev": true - }, - "node_modules/sc-istanbul/node_modules/supports-color": { - "version": "3.2.3", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-3.2.3.tgz", - "integrity": "sha512-Jds2VIYDrlp5ui7t8abHN2bjAu4LV/q4N2KivFPpGH0lrka0BMq/33AmECUXlKPcHigkNaqfXRENFju+rlcy+A==", - "dev": true, - "dependencies": { - "has-flag": "^1.0.0" - }, - "engines": { - "node": ">=0.8.0" - } - }, - "node_modules/sc-istanbul/node_modules/which": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "dev": true, - "dependencies": { - "isexe": "^2.0.0" - }, - "bin": { - "which": "bin/which" - } - }, - "node_modules/scrypt-js": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/scrypt-js/-/scrypt-js-3.0.1.tgz", - "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==", - "dev": true - }, - "node_modules/secp256k1": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/secp256k1/-/secp256k1-4.0.4.tgz", - "integrity": "sha512-6JfvwvjUOn8F/jUoBY2Q1v5WY5XS+rj8qSe0v8Y4ezH4InLgTEeOOPQsRll9OV429Pvo6BCHGavIyJfr3TAhsw==", - "dev": true, - "hasInstallScript": true, - "dependencies": { - "elliptic": "^6.5.7", - "node-addon-api": "^5.0.0", - "node-gyp-build": "^4.2.0" - }, - "engines": { - "node": ">=18.0.0" - } - }, - "node_modules/secp256k1/node_modules/elliptic": { - "version": "6.5.7", - "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.7.tgz", - "integrity": "sha512-ESVCtTwiA+XhY3wyh24QqRGBoP3rEdDUl3EDUUo9tft074fi19IrdpH7hLCMMP3CIj7jb3W96rn8lt/BqIlt5Q==", - "dev": true, - "dependencies": { - "bn.js": "^4.11.9", - "brorand": "^1.1.0", - "hash.js": "^1.0.0", - "hmac-drbg": "^1.0.1", - "inherits": "^2.0.4", - "minimalistic-assert": "^1.0.1", - "minimalistic-crypto-utils": "^1.0.1" - } - }, - "node_modules/secp256k1/node_modules/node-addon-api": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-5.1.0.tgz", - "integrity": "sha512-eh0GgfEkpnoWDq+VY8OyvYhFEzBk6jIYbRKdIlyTiAXIVJ8PyBaKb0rp7oDtoddbdoHWhq8wwr+XZ81F1rpNdA==", - "dev": true - }, - "node_modules/semver": { - "version": "7.5.4", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", - "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", - "dev": true, - "dependencies": { - "lru-cache": "^6.0.0" - }, - "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/semver/node_modules/lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", - "dev": true, - "dependencies": { - "yallist": "^4.0.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/semver/node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true - }, - "node_modules/serialize-javascript": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz", - "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "randombytes": "^2.1.0" - } - }, - "node_modules/set-blocking": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==", - "dev": true - }, - "node_modules/set-function-length": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", - "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", - "dev": true, - "dependencies": { - "define-data-property": "^1.1.4", - "es-errors": "^1.3.0", - "function-bind": "^1.1.2", - "get-intrinsic": "^1.2.4", - "gopd": "^1.0.1", - "has-property-descriptors": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/set-function-name": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.1.tgz", - "integrity": "sha512-tMNCiqYVkXIZgc2Hnoy2IvC/f8ezc5koaRFkCjrpWzGpCd3qbZXPzVy9MAZzK1ch/X0jvSkojys3oqJN0qCmdA==", - "dev": true, - "dependencies": { - "define-data-property": "^1.0.1", - "functions-have-names": "^1.2.3", - "has-property-descriptors": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/setimmediate": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", - "integrity": "sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==", - "dev": true - }, - "node_modules/setprototypeof": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", - "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", - "dev": true - }, - "node_modules/sha.js": { - "version": "2.4.11", - "resolved": "https://registry.npmjs.org/sha.js/-/sha.js-2.4.11.tgz", - "integrity": "sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ==", - "dev": true, - "dependencies": { - "inherits": "^2.0.1", - "safe-buffer": "^5.0.1" - }, - "bin": { - "sha.js": "bin.js" - } - }, - "node_modules/sha1": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/sha1/-/sha1-1.1.1.tgz", - "integrity": "sha512-dZBS6OrMjtgVkopB1Gmo4RQCDKiZsqcpAQpkV/aaj+FCrCg8r4I4qMkDPQjBgLIxlmu9k4nUbWq6ohXahOneYA==", - "dev": true, - "dependencies": { - "charenc": ">= 0.0.1", - "crypt": ">= 0.0.1" - }, - "engines": { - "node": "*" - } - }, - "node_modules/shallowequal": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/shallowequal/-/shallowequal-1.1.0.tgz", - "integrity": "sha512-y0m1JoUZSlPAjXVtPPW70aZWfIL/dSP7AFkRnniLCrK/8MDKog3TySTBmckD+RObVxH0v4Tox67+F14PdED2oQ==", - "dev": true - }, - "node_modules/shebang-command": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", - "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", - "dev": true, - "dependencies": { - "shebang-regex": "^3.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/shebang-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", - "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/shelljs": { - "version": "0.8.5", - "resolved": "https://registry.npmjs.org/shelljs/-/shelljs-0.8.5.tgz", - "integrity": "sha512-TiwcRcrkhHvbrZbnRcFYMLl30Dfov3HKqzp5tO5b4pt6G/SezKcYhmDg15zXVBswHmctSAQKznqNW2LO5tTDow==", - "dev": true, - "dependencies": { - "glob": "^7.0.0", - "interpret": "^1.0.0", - "rechoir": "^0.6.2" - }, - "bin": { - "shjs": "bin/shjs" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/shelljs/node_modules/glob": { - "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", - "dev": true, - "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.1.1", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - }, - "engines": { - "node": "*" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/side-channel": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.6.tgz", - "integrity": "sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.7", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.4", - "object-inspect": "^1.13.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/signal-exit": { - "version": "3.0.7", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", - "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", - "dev": true - }, - "node_modules/slash": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", - "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/slice-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-4.0.0.tgz", - "integrity": "sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.0.0", - "astral-regex": "^2.0.0", - "is-fullwidth-code-point": "^3.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/slice-ansi?sponsor=1" - } - }, - "node_modules/slice-ansi/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/slice-ansi/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/slice-ansi/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/slice-ansi/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/smartwrap": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/smartwrap/-/smartwrap-2.0.2.tgz", - "integrity": "sha512-vCsKNQxb7PnCNd2wY1WClWifAc2lwqsG8OaswpJkVJsvMGcnEntdTCDajZCkk93Ay1U3t/9puJmb525Rg5MZBA==", - "dev": true, - "dependencies": { - "array.prototype.flat": "^1.2.3", - "breakword": "^1.0.5", - "grapheme-splitter": "^1.0.4", - "strip-ansi": "^6.0.0", - "wcwidth": "^1.0.1", - "yargs": "^15.1.0" - }, - "bin": { - "smartwrap": "src/terminal-adapter.js" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/smartwrap/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/smartwrap/node_modules/cliui": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-6.0.0.tgz", - "integrity": "sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ==", - "dev": true, - "dependencies": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.0", - "wrap-ansi": "^6.2.0" - } - }, - "node_modules/smartwrap/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/smartwrap/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/smartwrap/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/smartwrap/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/smartwrap/node_modules/wrap-ansi": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", - "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/smartwrap/node_modules/y18n": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.3.tgz", - "integrity": "sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ==", - "dev": true - }, - "node_modules/smartwrap/node_modules/yargs": { - "version": "15.4.1", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-15.4.1.tgz", - "integrity": "sha512-aePbxDmcYW++PaqBsJ+HYUFwCdv4LVvdnhBy78E57PIor8/OVvhMrADFFEDh8DHDFRv/O9i3lPhsENjO7QX0+A==", - "dev": true, - "dependencies": { - "cliui": "^6.0.0", - "decamelize": "^1.2.0", - "find-up": "^4.1.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^4.2.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^18.1.2" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/solhint": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/solhint/-/solhint-5.0.0.tgz", - "integrity": "sha512-pSRKkzRsruia6/xa9L5VSyd7dMZkiiTi/aYZcvUQo7KK+S16ojPwIbt2jfjbH5WEJ83grzIIE4WrYQfAxGWh/A==", - "dev": true, - "dependencies": { - "@solidity-parser/parser": "^0.18.0", - "ajv": "^6.12.6", - "antlr4": "^4.13.1-patch-1", - "ast-parents": "^0.0.1", - "chalk": "^4.1.2", - "commander": "^10.0.0", - "cosmiconfig": "^8.0.0", - "fast-diff": "^1.2.0", - "glob": "^8.0.3", - "ignore": "^5.2.4", - "js-yaml": "^4.1.0", - "latest-version": "^7.0.0", - "lodash": "^4.17.21", - "pluralize": "^8.0.0", - "semver": "^7.5.2", - "strip-ansi": "^6.0.1", - "table": "^6.8.1", - "text-table": "^0.2.0" - }, - "bin": { - "solhint": "solhint.js" - }, - "optionalDependencies": { - "prettier": "^2.8.3" - } - }, - "node_modules/solhint-plugin-openzeppelin": { - "resolved": "scripts/solhint-custom", - "link": true - }, - "node_modules/solhint/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/solhint/node_modules/argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "dev": true - }, - "node_modules/solhint/node_modules/brace-expansion": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.0.tgz", - "integrity": "sha512-TN1kCZAgdgweJhWWpgKYrQaMNHcDULHkWwQIspdtjV4Y5aurRdZpjAqn6yX3FPqTA9ngHCc4hJxMAMgGfve85w==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0" - } - }, - "node_modules/solhint/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/solhint/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/solhint/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/solhint/node_modules/glob": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/glob/-/glob-8.1.0.tgz", - "integrity": "sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ==", - "dev": true, - "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^5.0.1", - "once": "^1.3.0" - }, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/solhint/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/solhint/node_modules/js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", - "dev": true, - "dependencies": { - "argparse": "^2.0.1" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, - "node_modules/solhint/node_modules/minimatch": { - "version": "5.1.9", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.1.9.tgz", - "integrity": "sha512-7o1wEA2RyMP7Iu7GNba9vc0RWWGACJOCZBJX2GJWip0ikV+wcOsgVuY9uE8CPiyQhkGFSlhuSkZPavN7u1c2Fw==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^2.0.1" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/solhint/node_modules/prettier": { - "version": "2.8.8", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.8.tgz", - "integrity": "sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==", - "dev": true, - "optional": true, - "bin": { - "prettier": "bin-prettier.js" - }, - "engines": { - "node": ">=10.13.0" - }, - "funding": { - "url": "https://github.com/prettier/prettier?sponsor=1" - } - }, - "node_modules/solhint/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/solidity-ast": { - "version": "0.4.52", - "resolved": "https://registry.npmjs.org/solidity-ast/-/solidity-ast-0.4.52.tgz", - "integrity": "sha512-iOya9BSiB9jhM8Vf40n8lGELGzwrUc57rl5BhfNtJ5cvAaMvRcNlHeAMNvqJJyjoUnczqRbHqdivEqK89du3Cw==", - "dev": true, - "dependencies": { - "array.prototype.findlast": "^1.2.2" - } - }, - "node_modules/solidity-comments": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/solidity-comments/-/solidity-comments-0.0.2.tgz", - "integrity": "sha512-G+aK6qtyUfkn1guS8uzqUeua1dURwPlcOjoTYW/TwmXAcE7z/1+oGCfZUdMSe4ZMKklNbVZNiG5ibnF8gkkFfw==", - "dev": true, - "engines": { - "node": ">= 12" - }, - "optionalDependencies": { - "solidity-comments-darwin-arm64": "0.0.2", - "solidity-comments-darwin-x64": "0.0.2", - "solidity-comments-freebsd-x64": "0.0.2", - "solidity-comments-linux-arm64-gnu": "0.0.2", - "solidity-comments-linux-arm64-musl": "0.0.2", - "solidity-comments-linux-x64-gnu": "0.0.2", - "solidity-comments-linux-x64-musl": "0.0.2", - "solidity-comments-win32-arm64-msvc": "0.0.2", - "solidity-comments-win32-ia32-msvc": "0.0.2", - "solidity-comments-win32-x64-msvc": "0.0.2" - } - }, - "node_modules/solidity-comments-darwin-arm64": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/solidity-comments-darwin-arm64/-/solidity-comments-darwin-arm64-0.0.2.tgz", - "integrity": "sha512-HidWkVLSh7v+Vu0CA7oI21GWP/ZY7ro8g8OmIxE8oTqyMwgMbE8F1yc58Sj682Hj199HCZsjmtn1BE4PCbLiGA==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/solidity-comments-darwin-x64": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/solidity-comments-darwin-x64/-/solidity-comments-darwin-x64-0.0.2.tgz", - "integrity": "sha512-Zjs0Ruz6faBTPT6fBecUt6qh4CdloT8Bwoc0+qxRoTn9UhYscmbPQkUgQEbS0FQPysYqVzzxJB4h1Ofbf4wwtA==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/solidity-comments-extractor": { - "version": "0.0.7", - "resolved": "https://registry.npmjs.org/solidity-comments-extractor/-/solidity-comments-extractor-0.0.7.tgz", - "integrity": "sha512-wciNMLg/Irp8OKGrh3S2tfvZiZ0NEyILfcRCXCD4mp7SgK/i9gzLfhY2hY7VMCQJ3kH9UB9BzNdibIVMchzyYw==", - "dev": true - }, - "node_modules/solidity-comments-freebsd-x64": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/solidity-comments-freebsd-x64/-/solidity-comments-freebsd-x64-0.0.2.tgz", - "integrity": "sha512-8Qe4mpjuAxFSwZJVk7B8gAoLCdbtS412bQzBwk63L8dmlHogvE39iT70aAk3RHUddAppT5RMBunlPUCFYJ3ZTw==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "freebsd" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/solidity-comments-linux-arm64-gnu": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/solidity-comments-linux-arm64-gnu/-/solidity-comments-linux-arm64-gnu-0.0.2.tgz", - "integrity": "sha512-spkb0MZZnmrP+Wtq4UxP+nyPAVRe82idOjqndolcNR0S9Xvu4ebwq+LvF4HiUgjTDmeiqYiFZQ8T9KGdLSIoIg==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/solidity-comments-linux-arm64-musl": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/solidity-comments-linux-arm64-musl/-/solidity-comments-linux-arm64-musl-0.0.2.tgz", - "integrity": "sha512-guCDbHArcjE+JDXYkxx5RZzY1YF6OnAKCo+sTC5fstyW/KGKaQJNPyBNWuwYsQiaEHpvhW1ha537IvlGek8GqA==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/solidity-comments-linux-x64-gnu": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/solidity-comments-linux-x64-gnu/-/solidity-comments-linux-x64-gnu-0.0.2.tgz", - "integrity": "sha512-zIqLehBK/g7tvrFmQljrfZXfkEeLt2v6wbe+uFu6kH/qAHZa7ybt8Vc0wYcmjo2U0PeBm15d79ee3AkwbIjFdQ==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/solidity-comments-linux-x64-musl": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/solidity-comments-linux-x64-musl/-/solidity-comments-linux-x64-musl-0.0.2.tgz", - "integrity": "sha512-R9FeDloVlFGTaVkOlELDVC7+1Tjx5WBPI5L8r0AGOPHK3+jOcRh6sKYpI+VskSPDc3vOO46INkpDgUXrKydlIw==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/solidity-comments-win32-arm64-msvc": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/solidity-comments-win32-arm64-msvc/-/solidity-comments-win32-arm64-msvc-0.0.2.tgz", - "integrity": "sha512-QnWJoCQcJj+rnutULOihN9bixOtYWDdF5Rfz9fpHejL1BtNjdLW1om55XNVHGAHPqBxV4aeQQ6OirKnp9zKsug==", - "cpu": [ - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/solidity-comments-win32-ia32-msvc": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/solidity-comments-win32-ia32-msvc/-/solidity-comments-win32-ia32-msvc-0.0.2.tgz", - "integrity": "sha512-vUg4nADtm/NcOtlIymG23NWJUSuMsvX15nU7ynhGBsdKtt8xhdP3C/zA6vjDk8Jg+FXGQL6IHVQ++g/7rSQi0w==", - "cpu": [ - "ia32" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/solidity-comments-win32-x64-msvc": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/solidity-comments-win32-x64-msvc/-/solidity-comments-win32-x64-msvc-0.0.2.tgz", - "integrity": "sha512-36j+KUF4V/y0t3qatHm/LF5sCUCBx2UndxE1kq5bOzh/s+nQgatuyB+Pd5BfuPQHdWu2KaExYe20FlAa6NL7+Q==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/solidity-coverage": { - "version": "0.8.17", - "resolved": "https://registry.npmjs.org/solidity-coverage/-/solidity-coverage-0.8.17.tgz", - "integrity": "sha512-5P8vnB6qVX9tt1MfuONtCTEaEGO/O4WuEidPHIAJjx4sktHHKhO3rFvnE0q8L30nWJPTrcqGQMT7jpE29B2qow==", - "dev": true, - "license": "ISC", - "dependencies": { - "@ethersproject/abi": "^5.0.9", - "@solidity-parser/parser": "^0.20.1", - "chalk": "^2.4.2", - "death": "^1.1.0", - "difflib": "^0.2.4", - "fs-extra": "^8.1.0", - "ghost-testrpc": "^0.0.2", - "global-modules": "^2.0.0", - "globby": "^10.0.1", - "jsonschema": "^1.2.4", - "lodash": "^4.17.21", - "mocha": "^10.2.0", - "node-emoji": "^1.10.0", - "pify": "^4.0.1", - "recursive-readdir": "^2.2.2", - "sc-istanbul": "^0.4.5", - "semver": "^7.3.4", - "shelljs": "^0.8.3", - "web3-utils": "^1.3.6" - }, - "bin": { - "solidity-coverage": "plugins/bin.js" - }, - "peerDependencies": { - "hardhat": "^2.11.0" - } - }, - "node_modules/solidity-coverage/node_modules/@solidity-parser/parser": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/@solidity-parser/parser/-/parser-0.20.2.tgz", - "integrity": "sha512-rbu0bzwNvMcwAjH86hiEAcOeRI2EeK8zCkHDrFykh/Al8mvJeFmjy3UrE7GYQjNwOgbGUUtCn5/k8CB8zIu7QA==", - "dev": true, - "license": "MIT" - }, - "node_modules/solidity-coverage/node_modules/fs-extra": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz", - "integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==", - "dev": true, - "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^4.0.0", - "universalify": "^0.1.0" - }, - "engines": { - "node": ">=6 <7 || >=8" - } - }, - "node_modules/solidity-coverage/node_modules/glob": { - "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", - "dev": true, - "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.1.1", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - }, - "engines": { - "node": "*" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/solidity-coverage/node_modules/globby": { - "version": "10.0.2", - "resolved": "https://registry.npmjs.org/globby/-/globby-10.0.2.tgz", - "integrity": "sha512-7dUi7RvCoT/xast/o/dLN53oqND4yk0nsHkhRgn9w65C4PofCLOoJ39iSOg+qVDdWQPIEj+eszMHQ+aLVwwQSg==", - "dev": true, - "dependencies": { - "@types/glob": "^7.1.1", - "array-union": "^2.1.0", - "dir-glob": "^3.0.1", - "fast-glob": "^3.0.3", - "glob": "^7.1.3", - "ignore": "^5.1.1", - "merge2": "^1.2.3", - "slash": "^3.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/solidity-docgen": { - "version": "0.6.0-beta.36", - "resolved": "https://registry.npmjs.org/solidity-docgen/-/solidity-docgen-0.6.0-beta.36.tgz", - "integrity": "sha512-f/I5G2iJgU1h0XrrjRD0hHMr7C10u276vYvm//rw1TzFcYQ4xTOyAoi9oNAHRU0JU4mY9eTuxdVc2zahdMuhaQ==", - "dev": true, - "dependencies": { - "handlebars": "^4.7.7", - "solidity-ast": "^0.4.38" - }, - "peerDependencies": { - "hardhat": "^2.8.0" - } - }, - "node_modules/source-map": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.2.0.tgz", - "integrity": "sha512-CBdZ2oa/BHhS4xj5DlhjWNHcan57/5YuvfdLf17iVmIpd9KRm+DFLmC6nBNj+6Ua7Kt3TmOjDpQT1aTYOQtoUA==", - "dev": true, - "optional": true, - "dependencies": { - "amdefine": ">=0.0.4" - }, - "engines": { - "node": ">=0.8.0" - } - }, - "node_modules/source-map-support": { - "version": "0.5.21", - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.21.tgz", - "integrity": "sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==", - "dev": true, - "dependencies": { - "buffer-from": "^1.0.0", - "source-map": "^0.6.0" - } - }, - "node_modules/source-map-support/node_modules/source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/spawndamnit": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/spawndamnit/-/spawndamnit-2.0.0.tgz", - "integrity": "sha512-j4JKEcncSjFlqIwU5L/rp2N5SIPsdxaRsIv678+TZxZ0SRDJTm8JrxJMjE/XuiEZNEir3S8l0Fa3Ke339WI4qA==", - "dev": true, - "dependencies": { - "cross-spawn": "^5.1.0", - "signal-exit": "^3.0.2" - } - }, - "node_modules/spawndamnit/node_modules/cross-spawn": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-5.1.0.tgz", - "integrity": "sha512-pTgQJ5KC0d2hcY8eyL1IzlBPYjTkyH72XRZPnLyKus2mBfNjQs3klqbJU2VILqZryAZUt9JOb3h/mWMy23/f5A==", - "dev": true, - "dependencies": { - "lru-cache": "^4.0.1", - "shebang-command": "^1.2.0", - "which": "^1.2.9" - } - }, - "node_modules/spawndamnit/node_modules/lru-cache": { - "version": "4.1.5", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.5.tgz", - "integrity": "sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==", - "dev": true, - "dependencies": { - "pseudomap": "^1.0.2", - "yallist": "^2.1.2" - } - }, - "node_modules/spawndamnit/node_modules/shebang-command": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", - "integrity": "sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg==", - "dev": true, - "dependencies": { - "shebang-regex": "^1.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/spawndamnit/node_modules/shebang-regex": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", - "integrity": "sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/spawndamnit/node_modules/which": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "dev": true, - "dependencies": { - "isexe": "^2.0.0" - }, - "bin": { - "which": "bin/which" - } - }, - "node_modules/spawndamnit/node_modules/yallist": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz", - "integrity": "sha512-ncTzHV7NvsQZkYe1DW7cbDLm0YpzHmZF5r/iyP3ZnQtMiJ+pjzisCiMNI+Sj+xQF5pXhSHxSB3uDbsBTzY/c2A==", - "dev": true - }, - "node_modules/spdx-correct": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.2.0.tgz", - "integrity": "sha512-kN9dJbvnySHULIluDHy32WHRUu3Og7B9sbY7tsFLctQkIqnMh3hErYgdMjTYuqmcXX+lK5T1lnUt3G7zNswmZA==", - "dev": true, - "dependencies": { - "spdx-expression-parse": "^3.0.0", - "spdx-license-ids": "^3.0.0" - } - }, - "node_modules/spdx-exceptions": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz", - "integrity": "sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A==", - "dev": true - }, - "node_modules/spdx-expression-parse": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz", - "integrity": "sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==", - "dev": true, - "dependencies": { - "spdx-exceptions": "^2.1.0", - "spdx-license-ids": "^3.0.0" - } - }, - "node_modules/spdx-license-ids": { - "version": "3.0.15", - "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.15.tgz", - "integrity": "sha512-lpT8hSQp9jAKp9mhtBU4Xjon8LPGBvLIuBiSVhMEtmLecTh2mO0tlqrAMp47tBXzMr13NJMQ2lf7RpQGLJ3HsQ==", - "dev": true - }, - "node_modules/sprintf-js": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", - "dev": true - }, - "node_modules/stacktrace-parser": { - "version": "0.1.10", - "resolved": "https://registry.npmjs.org/stacktrace-parser/-/stacktrace-parser-0.1.10.tgz", - "integrity": "sha512-KJP1OCML99+8fhOHxwwzyWrlUuVX5GQ0ZpJTd1DFXhdkrvg1szxfHhawXUZ3g9TkXORQd4/WG68jMlQZ2p8wlg==", - "dev": true, - "dependencies": { - "type-fest": "^0.7.1" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/stacktrace-parser/node_modules/type-fest": { - "version": "0.7.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.7.1.tgz", - "integrity": "sha512-Ne2YiiGN8bmrmJJEuTWTLJR32nh/JdL1+PSicowtNb0WFpn59GK8/lfD61bVtzguz7b3PBt74nxpv/Pw5po5Rg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/statuses": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", - "integrity": "sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==", - "dev": true, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/stream-transform": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/stream-transform/-/stream-transform-2.1.3.tgz", - "integrity": "sha512-9GHUiM5hMiCi6Y03jD2ARC1ettBXkQBoQAe7nJsPknnI0ow10aXjTnew8QtYQmLjzn974BnmWEAJgCY6ZP1DeQ==", - "dev": true, - "dependencies": { - "mixme": "^0.5.1" - } - }, - "node_modules/string_decoder": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", - "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", - "dev": true, - "dependencies": { - "safe-buffer": "~5.2.0" - } - }, - "node_modules/string-width-cjs": { - "name": "string-width", - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/string-width-cjs/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/string.prototype.trim": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.8.tgz", - "integrity": "sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/string.prototype.trimend": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.7.tgz", - "integrity": "sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/string.prototype.trimstart": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.7.tgz", - "integrity": "sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/strip-ansi-cjs": { - "name": "strip-ansi", - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/strip-bom": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", - "integrity": "sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==", - "dev": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/strip-hex-prefix": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz", - "integrity": "sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==", - "dev": true, - "dependencies": { - "is-hex-prefixed": "1.0.0" - }, - "engines": { - "node": ">=6.5.0", - "npm": ">=3" - } - }, - "node_modules/strip-json-comments": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", - "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", - "dev": true, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "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/table": { - "version": "6.8.1", - "resolved": "https://registry.npmjs.org/table/-/table-6.8.1.tgz", - "integrity": "sha512-Y4X9zqrCftUhMeH2EptSSERdVKt/nEdijTOacGD/97EKjhQ/Qs8RTlEGABSJNNN8lac9kheH+af7yAkEWlgneA==", - "dev": true, - "dependencies": { - "ajv": "^8.0.1", - "lodash.truncate": "^4.4.2", - "slice-ansi": "^4.0.0", - "string-width": "^4.2.3", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=10.0.0" - } - }, - "node_modules/table/node_modules/ajv": { - "version": "8.12.0", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.12.0.tgz", - "integrity": "sha512-sRu1kpcO9yLtYxBKvqfTeh9KzZEwO3STyX1HT+4CaDzC6HpTGYhIhPIzj9XuKU7KYDwnaeh5hcOwjy1QuJzBPA==", - "dev": true, - "dependencies": { - "fast-deep-equal": "^3.1.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2", - "uri-js": "^4.2.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/table/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/table/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true - }, - "node_modules/table/node_modules/require-from-string": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", - "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/table/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/term-size": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/term-size/-/term-size-2.2.1.tgz", - "integrity": "sha512-wK0Ri4fOGjv/XPy8SBHZChl8CM7uMc5VML7SqiQ0zG7+J5Vr+RMQDoHa2CNT6KHUnTGIXH34UDMkPzAUyapBZg==", - "dev": true, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/text-table": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", - "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==", - "dev": true - }, - "node_modules/tmp": { - "version": "0.0.33", - "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz", - "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==", - "dev": true, - "dependencies": { - "os-tmpdir": "~1.0.2" - }, - "engines": { - "node": ">=0.6.0" - } - }, - "node_modules/to-regex-range": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", - "dev": true, - "dependencies": { - "is-number": "^7.0.0" - }, - "engines": { - "node": ">=8.0" - } - }, - "node_modules/toidentifier": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.1.tgz", - "integrity": "sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==", - "dev": true, - "engines": { - "node": ">=0.6" - } - }, - "node_modules/tr46": { - "version": "0.0.3", - "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", - "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==", - "dev": true - }, - "node_modules/trim-newlines": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/trim-newlines/-/trim-newlines-3.0.1.tgz", - "integrity": "sha512-c1PTsA3tYrIsLGkJkzHF+w9F2EyxfXGo4UyJc4pFL++FMjnq0HJS69T3M7d//gKrFKwy429bouPescbjecU+Zw==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/tslib": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", - "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==", - "dev": true - }, - "node_modules/tsort": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/tsort/-/tsort-0.0.1.tgz", - "integrity": "sha512-Tyrf5mxF8Ofs1tNoxA13lFeZ2Zrbd6cKbuH3V+MQ5sb6DtBj5FjrXVsRWT8YvNAQTqNoz66dz1WsbigI22aEnw==", - "dev": true - }, - "node_modules/tty-table": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/tty-table/-/tty-table-4.2.1.tgz", - "integrity": "sha512-xz0uKo+KakCQ+Dxj1D/tKn2FSyreSYWzdkL/BYhgN6oMW808g8QRMuh1atAV9fjTPbWBjfbkKQpI/5rEcnAc7g==", - "dev": true, - "dependencies": { - "chalk": "^4.1.2", - "csv": "^5.5.3", - "kleur": "^4.1.5", - "smartwrap": "^2.0.2", - "strip-ansi": "^6.0.1", - "wcwidth": "^1.0.1", - "yargs": "^17.7.1" - }, - "bin": { - "tty-table": "adapters/terminal-adapter.js" - }, - "engines": { - "node": ">=8.0.0" - } - }, - "node_modules/tty-table/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/tty-table/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/tty-table/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/tty-table/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/tty-table/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/tty-table/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/tweetnacl": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz", - "integrity": "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==", - "dev": true - }, - "node_modules/tweetnacl-util": { - "version": "0.15.1", - "resolved": "https://registry.npmjs.org/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz", - "integrity": "sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==", - "dev": true - }, - "node_modules/type-check": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", - "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==", - "dev": true, - "dependencies": { - "prelude-ls": "^1.2.1" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/type-detect": { - "version": "4.0.8", - "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", - "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", - "dev": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/type-fest": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/typed-array-buffer": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz", - "integrity": "sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "get-intrinsic": "^1.2.1", - "is-typed-array": "^1.1.10" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/typed-array-byte-length": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz", - "integrity": "sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "for-each": "^0.3.3", - "has-proto": "^1.0.1", - "is-typed-array": "^1.1.10" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/typed-array-byte-offset": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz", - "integrity": "sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg==", - "dev": true, - "dependencies": { - "available-typed-arrays": "^1.0.5", - "call-bind": "^1.0.2", - "for-each": "^0.3.3", - "has-proto": "^1.0.1", - "is-typed-array": "^1.1.10" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/typed-array-length": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz", - "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "for-each": "^0.3.3", - "is-typed-array": "^1.1.9" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/uglify-js": { - "version": "3.17.4", - "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.17.4.tgz", - "integrity": "sha512-T9q82TJI9e/C1TAxYvfb16xO120tMVFZrGA3f9/P4424DNu6ypK103y0GPFVa17yotwSyZW5iYXgjYHkGrJW/g==", - "dev": true, - "optional": true, - "bin": { - "uglifyjs": "bin/uglifyjs" - }, - "engines": { - "node": ">=0.8.0" - } - }, - "node_modules/unbox-primitive": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", - "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "has-bigints": "^1.0.2", - "has-symbols": "^1.0.3", - "which-boxed-primitive": "^1.0.2" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/undici": { - "version": "6.12.0", - "resolved": "https://registry.npmjs.org/undici/-/undici-6.12.0.tgz", - "integrity": "sha512-d87yk8lqSFUYtR5fTFe2frpkMIrUEz+lgoJmhcL+J3StVl+8fj8ytE4lLnJOTPCE12YbumNGzf4LYsQyusdV5g==", - "dev": true, - "engines": { - "node": ">=18.0" - } - }, - "node_modules/undici-types": { - "version": "5.26.5", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-5.26.5.tgz", - "integrity": "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==", - "dev": true - }, - "node_modules/universalify": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz", - "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==", - "dev": true, - "engines": { - "node": ">= 4.0.0" - } - }, - "node_modules/unpipe": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", - "integrity": "sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==", - "dev": true, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/uri-js": { - "version": "4.4.1", - "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", - "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", - "dev": true, - "dependencies": { - "punycode": "^2.1.0" - } - }, - "node_modules/utf8": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/utf8/-/utf8-3.0.0.tgz", - "integrity": "sha512-E8VjFIQ/TyQgp+TZfS6l8yp/xWppSAHzidGiRrqe4bK4XP9pTRyKFgGJpO3SN7zdX4DeomTrwaseCHovfpFcqQ==", - "dev": true - }, - "node_modules/util-deprecate": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", - "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", - "dev": true - }, - "node_modules/uuid": { - "version": "8.3.2", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", - "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==", - "dev": true, - "bin": { - "uuid": "dist/bin/uuid" - } - }, - "node_modules/validate-npm-package-license": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz", - "integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==", - "dev": true, - "dependencies": { - "spdx-correct": "^3.0.0", - "spdx-expression-parse": "^3.0.0" - } - }, - "node_modules/viem": { - "version": "2.7.14", - "resolved": "https://registry.npmjs.org/viem/-/viem-2.7.14.tgz", - "integrity": "sha512-5b1KB1gXli02GOQHZIUsRluNUwssl2t4hqdFAzyWPwJ744N83jAOBOjOkrGz7K3qMIv9b0GQt3DoZIErSQTPkQ==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/wevm" - } - ], - "dependencies": { - "@adraffy/ens-normalize": "1.10.0", - "@noble/curves": "1.2.0", - "@noble/hashes": "1.3.2", - "@scure/bip32": "1.3.2", - "@scure/bip39": "1.2.1", - "abitype": "1.0.0", - "isows": "1.0.3", - "ws": "8.13.0" - }, - "peerDependencies": { - "typescript": ">=5.0.4" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } - } - }, - "node_modules/viem/node_modules/@adraffy/ens-normalize": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/@adraffy/ens-normalize/-/ens-normalize-1.10.0.tgz", - "integrity": "sha512-nA9XHtlAkYfJxY7bce8DcN7eKxWWCWkU+1GR9d+U6MbNpfwQp8TI7vqOsBsMcHoT4mBu2kypKoSKnghEzOOq5Q==", - "dev": true - }, - "node_modules/viem/node_modules/@noble/curves": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.2.0.tgz", - "integrity": "sha512-oYclrNgRaM9SsBUBVbb8M6DTV7ZHRTKugureoYEncY5c65HOmRzvSiTE3y5CYaPYJA/GVkrhXEoF0M3Ya9PMnw==", - "dev": true, - "dependencies": { - "@noble/hashes": "1.3.2" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/viem/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==", - "dev": true, - "engines": { - "node": ">= 16" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/viem/node_modules/@scure/bip32": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/@scure/bip32/-/bip32-1.3.2.tgz", - "integrity": "sha512-N1ZhksgwD3OBlwTv3R6KFEcPojl/W4ElJOeCZdi+vuI5QmTFwLq3OFf2zd2ROpKvxFdgZ6hUpb0dx9bVNEwYCA==", - "dev": true, - "dependencies": { - "@noble/curves": "~1.2.0", - "@noble/hashes": "~1.3.2", - "@scure/base": "~1.1.2" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/viem/node_modules/ws": { - "version": "8.13.0", - "resolved": "https://registry.npmjs.org/ws/-/ws-8.13.0.tgz", - "integrity": "sha512-x9vcZYTrFPC7aSIbj7sRCYo7L/Xb8Iy+pW0ng0wt2vCJv7M9HOMy0UoN3rr+IFC7hb7vXoqS+P9ktyLLLhO+LA==", - "dev": true, - "engines": { - "node": ">=10.0.0" - }, - "peerDependencies": { - "bufferutil": "^4.0.1", - "utf-8-validate": ">=5.0.2" - }, - "peerDependenciesMeta": { - "bufferutil": { - "optional": true - }, - "utf-8-validate": { - "optional": true - } - } - }, - "node_modules/wcwidth": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/wcwidth/-/wcwidth-1.0.1.tgz", - "integrity": "sha512-XHPEwS0q6TaxcvG85+8EYkbiCux2XtWG2mkc47Ng2A77BQu9+DqIOJldST4HgPkuea7dvKSj5VgX3P1d4rW8Tg==", - "dev": true, - "dependencies": { - "defaults": "^1.0.3" - } - }, - "node_modules/web3-utils": { - "version": "1.10.2", - "resolved": "https://registry.npmjs.org/web3-utils/-/web3-utils-1.10.2.tgz", - "integrity": "sha512-TdApdzdse5YR+5GCX/b/vQnhhbj1KSAtfrDtRW7YS0kcWp1gkJsN62gw6GzCaNTeXookB7UrLtmDUuMv65qgow==", - "dev": true, - "dependencies": { - "@ethereumjs/util": "^8.1.0", - "bn.js": "^5.2.1", - "ethereum-bloom-filters": "^1.0.6", - "ethereum-cryptography": "^2.1.2", - "ethjs-unit": "0.1.6", - "number-to-bn": "1.7.0", - "randombytes": "^2.1.0", - "utf8": "3.0.0" - }, - "engines": { - "node": ">=8.0.0" - } - }, - "node_modules/web3-utils/node_modules/bn.js": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", - "dev": true - }, - "node_modules/web3-utils/node_modules/ethereum-cryptography": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-2.1.2.tgz", - "integrity": "sha512-Z5Ba0T0ImZ8fqXrJbpHcbpAvIswRte2wGNR/KePnu8GbbvgJ47lMxT/ZZPG6i9Jaht4azPDop4HaM00J0J59ug==", - "dev": true, - "dependencies": { - "@noble/curves": "1.1.0", - "@noble/hashes": "1.3.1", - "@scure/bip32": "1.3.1", - "@scure/bip39": "1.2.1" - } - }, - "node_modules/webidl-conversions": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", - "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==", - "dev": true - }, - "node_modules/whatwg-url": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", - "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", - "dev": true, - "dependencies": { - "tr46": "~0.0.3", - "webidl-conversions": "^3.0.0" - } - }, - "node_modules/which": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", - "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "dev": true, - "dependencies": { - "isexe": "^2.0.0" - }, - "bin": { - "node-which": "bin/node-which" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/which-boxed-primitive": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", - "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", - "dev": true, - "dependencies": { - "is-bigint": "^1.0.1", - "is-boolean-object": "^1.1.0", - "is-number-object": "^1.0.4", - "is-string": "^1.0.5", - "is-symbol": "^1.0.3" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/which-module": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.1.tgz", - "integrity": "sha512-iBdZ57RDvnOR9AGBhML2vFZf7h8vmBjhoaZqODJBFWHVtKkDmKuHai3cx5PgVMrX5YDNp27AofYbAwctSS+vhQ==", - "dev": true - }, - "node_modules/which-pm": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/which-pm/-/which-pm-2.0.0.tgz", - "integrity": "sha512-Lhs9Pmyph0p5n5Z3mVnN0yWcbQYUAD7rbQUiMsQxOJ3T57k7RFe35SUwWMf7dsbDZks1uOmw4AecB/JMDj3v/w==", - "dev": true, - "dependencies": { - "load-yaml-file": "^0.2.0", - "path-exists": "^4.0.0" - }, - "engines": { - "node": ">=8.15" - } - }, - "node_modules/which-typed-array": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz", - "integrity": "sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew==", - "dev": true, - "dependencies": { - "available-typed-arrays": "^1.0.5", - "call-bind": "^1.0.2", - "for-each": "^0.3.3", - "gopd": "^1.0.1", - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/widest-line": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/widest-line/-/widest-line-3.1.0.tgz", - "integrity": "sha512-NsmoXalsWVDMGupxZ5R08ka9flZjjiLvHVAWYOKtiKM8ujtZWr9cRffak+uSE48+Ob8ObalXpwyeUiyDD6QFgg==", - "dev": true, - "dependencies": { - "string-width": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/widest-line/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/widest-line/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/word-wrap": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.5.tgz", - "integrity": "sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/wordwrap": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz", - "integrity": "sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q==", - "dev": true - }, - "node_modules/workerpool": { - "version": "6.5.1", - "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.5.1.tgz", - "integrity": "sha512-Fs4dNYcsdpYSAfVxhnl1L5zTksjvOJxtC5hzMNl+1t9B8hTJTdKDyZ5ju7ztgPy+ft9tBFXoOlDNiOT9WUXZlA==", - "dev": true, - "license": "Apache-2.0" - }, - "node_modules/wrap-ansi": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", - "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, - "node_modules/wrap-ansi-cjs": { - "name": "wrap-ansi", - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", - "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, - "node_modules/wrap-ansi-cjs/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/wrap-ansi-cjs/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/wrap-ansi-cjs/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/wrap-ansi-cjs/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/wrap-ansi-cjs/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/wrap-ansi/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/wrap-ansi/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/wrap-ansi/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/wrap-ansi/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/wrap-ansi/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/wrappy": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", - "dev": true - }, - "node_modules/ws": { - "version": "7.5.9", - "resolved": "https://registry.npmjs.org/ws/-/ws-7.5.9.tgz", - "integrity": "sha512-F+P9Jil7UiSKSkppIiD94dN07AwvFixvLIj1Og1Rl9GGMuNipJnV9JzjD6XuqmAeiswGvUmNLjr5cFuXwNS77Q==", - "dev": true, - "engines": { - "node": ">=8.3.0" - }, - "peerDependencies": { - "bufferutil": "^4.0.1", - "utf-8-validate": "^5.0.2" - }, - "peerDependenciesMeta": { - "bufferutil": { - "optional": true - }, - "utf-8-validate": { - "optional": true - } - } - }, - "node_modules/y18n": { - "version": "5.0.8", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", - "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", - "dev": true, - "engines": { - "node": ">=10" - } - }, - "node_modules/yargs": { - "version": "17.7.2", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", - "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", - "dev": true, - "dependencies": { - "cliui": "^8.0.1", - "escalade": "^3.1.1", - "get-caller-file": "^2.0.5", - "require-directory": "^2.1.1", - "string-width": "^4.2.3", - "y18n": "^5.0.5", - "yargs-parser": "^21.1.1" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/yargs-parser": { - "version": "18.1.3", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-18.1.3.tgz", - "integrity": "sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==", - "dev": true, - "dependencies": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/yargs-parser/node_modules/camelcase": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/yargs-unparser": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-2.0.0.tgz", - "integrity": "sha512-7pRTIA9Qc1caZ0bZ6RYRGbHJthJWuakf+WmHK0rVeLkNrrGhfoabBNdue6kdINI6r4if7ocq9aD/n7xwKOdzOA==", - "dev": true, - "dependencies": { - "camelcase": "^6.0.0", - "decamelize": "^4.0.0", - "flat": "^5.0.2", - "is-plain-obj": "^2.1.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/yargs-unparser/node_modules/decamelize": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-4.0.0.tgz", - "integrity": "sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/yargs-unparser/node_modules/is-plain-obj": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz", - "integrity": "sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/yargs-parser": { - "version": "21.1.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", - "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", - "dev": true, - "engines": { - "node": ">=12" - } - }, - "node_modules/yocto-queue": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", - "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "scripts/solhint-custom": { - "name": "solhint-plugin-openzeppelin", - "version": "0.0.0", - "dev": true - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/package.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/package.json deleted file mode 100644 index efd3faafe2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/package.json +++ /dev/null @@ -1,92 +0,0 @@ -{ - "name": "openzeppelin-solidity", - "description": "Secure Smart Contract library for Solidity", - "version": "5.2.0", - "private": true, - "files": [ - "/contracts/**/*.sol", - "!/contracts/mocks/**/*" - ], - "scripts": { - "compile": "hardhat compile", - "compile:harnesses": "env SRC=./certora/harnesses hardhat compile", - "coverage": "scripts/checks/coverage.sh", - "docs": "npm run prepare-docs && oz-docs", - "docs:watch": "oz-docs watch contracts docs/templates docs/config.js", - "prepare": "scripts/prepare.sh", - "prepare-docs": "scripts/prepare-docs.sh", - "lint": "npm run lint:js && npm run lint:sol", - "lint:fix": "npm run lint:js:fix && npm run lint:sol:fix", - "lint:js": "prettier --log-level warn --ignore-path .gitignore '**/*.{js,ts}' --check && eslint .", - "lint:js:fix": "prettier --log-level warn --ignore-path .gitignore '**/*.{js,ts}' --write && eslint . --fix", - "lint:sol": "prettier --log-level warn --ignore-path .gitignore '{contracts,test}/**/*.sol' --check && solhint '{contracts,test}/**/*.sol'", - "lint:sol:fix": "prettier --log-level warn --ignore-path .gitignore '{contracts,test}/**/*.sol' --write", - "clean": "hardhat clean && rimraf build contracts/build", - "prepack": "scripts/prepack.sh", - "generate": "scripts/generate/run.js", - "version": "scripts/release/version.sh", - "test": "hardhat test", - "test:generation": "scripts/checks/generation.sh", - "test:inheritance": "scripts/checks/inheritance-ordering.js artifacts/build-info/*", - "test:pragma": "scripts/checks/pragma-consistency.js artifacts/build-info/*", - "gas-report": "env ENABLE_GAS_REPORT=true npm run test", - "slither": "npm run clean && slither ." - }, - "repository": { - "type": "git", - "url": "https://github.com/OpenZeppelin/openzeppelin-contracts.git" - }, - "keywords": [ - "solidity", - "ethereum", - "smart", - "contracts", - "security", - "zeppelin" - ], - "author": "OpenZeppelin Community ", - "license": "MIT", - "bugs": { - "url": "https://github.com/OpenZeppelin/openzeppelin-contracts/issues" - }, - "homepage": "https://openzeppelin.com/contracts/", - "devDependencies": { - "@changesets/changelog-github": "^0.5.0", - "@changesets/cli": "^2.26.0", - "@changesets/pre": "^2.0.0", - "@changesets/read": "^0.6.0", - "@eslint/compat": "^1.2.1", - "@nomicfoundation/hardhat-chai-matchers": "^2.0.6", - "@nomicfoundation/hardhat-ethers": "^3.0.4", - "@nomicfoundation/hardhat-network-helpers": "^1.0.3", - "@openzeppelin/docs-utils": "^0.1.5", - "@openzeppelin/merkle-tree": "^1.0.7", - "@openzeppelin/upgrade-safe-transpiler": "^0.3.32", - "@openzeppelin/upgrades-core": "^1.20.6", - "chai": "^4.2.0", - "eslint": "^9.0.0", - "eslint-config-prettier": "^9.0.0", - "ethers": "^6.7.1", - "globals": "^15.3.0", - "glob": "^11.0.0", - "graphlib": "^2.1.8", - "hardhat": "^2.22.2", - "hardhat-exposed": "^0.3.15", - "hardhat-gas-reporter": "^2.0.0", - "hardhat-ignore-warnings": "^0.2.11", - "lodash.startcase": "^4.4.0", - "micromatch": "^4.0.2", - "p-limit": "^3.1.0", - "prettier": "^3.0.0", - "prettier-plugin-solidity": "^1.1.0", - "rimraf": "^6.0.0", - "semver": "^7.3.5", - "solhint": "^5.0.0", - "solhint-plugin-openzeppelin": "file:scripts/solhint-custom", - "solidity-ast": "^0.4.50", - "solidity-coverage": "^0.8.17", - "solidity-docgen": "^0.6.0-beta.29", - "undici": "^6.11.1", - "yargs": "^17.0.0" - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/remappings.txt b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/remappings.txt deleted file mode 100644 index 304d1386a5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/remappings.txt +++ /dev/null @@ -1 +0,0 @@ -@openzeppelin/contracts/=contracts/ diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/renovate.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/renovate.json deleted file mode 100644 index c0b97d8d7a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/renovate.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "extends": ["github>OpenZeppelin/configs"], - "labels": ["ignore-changeset"] -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/compare-layout.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/compare-layout.js deleted file mode 100644 index 64ff4398d2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/compare-layout.js +++ /dev/null @@ -1,20 +0,0 @@ -const fs = require('fs'); -const { getStorageUpgradeReport } = require('@openzeppelin/upgrades-core/dist/storage'); - -const { ref, head } = require('yargs').argv; - -const oldLayout = JSON.parse(fs.readFileSync(ref)); -const newLayout = JSON.parse(fs.readFileSync(head)); - -for (const name in oldLayout) { - if (name in newLayout) { - const report = getStorageUpgradeReport(oldLayout[name], newLayout[name], {}); - if (!report.ok) { - console.log(`Storage layout incompatibility found in ${name}:`); - console.log(report.explain()); - process.exitCode = 1; - } - } else { - console.log(`WARNING: ${name} is missing from the current branch`); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/compareGasReports.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/compareGasReports.js deleted file mode 100644 index 2c7b4dc24d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/compareGasReports.js +++ /dev/null @@ -1,247 +0,0 @@ -#!/usr/bin/env node - -const fs = require('fs'); -const chalk = require('chalk'); -const { argv } = require('yargs') - .env() - .options({ - style: { - type: 'string', - choices: ['shell', 'markdown'], - default: 'shell', - }, - hideEqual: { - type: 'boolean', - default: true, - }, - strictTesting: { - type: 'boolean', - default: false, - }, - }); - -// Deduce base tx cost from the percentage denominator -const BASE_TX_COST = 21000; - -// Utilities -function sum(...args) { - return args.reduce((a, b) => a + b, 0); -} - -function average(...args) { - return sum(...args) / args.length; -} - -function variation(current, previous, offset = 0) { - return { - value: current, - delta: current - previous, - prcnt: (100 * (current - previous)) / (previous - offset), - }; -} - -// Report class -class Report { - // Read report file - static load(filepath) { - return JSON.parse(fs.readFileSync(filepath, 'utf8')); - } - - // Compare two reports - static compare(update, ref, opts = { hideEqual: true, strictTesting: false }) { - if (JSON.stringify(update.options?.solcInfo) !== JSON.stringify(ref.options?.solcInfo)) { - console.warn('WARNING: Reports produced with non matching metadata'); - } - - // gasReporter 1.0.0 uses ".info", but 2.0.0 uses ".data" - const updateInfo = update.info ?? update.data; - const refInfo = ref.info ?? ref.data; - - const deployments = updateInfo.deployments - .map(contract => - Object.assign(contract, { previousVersion: refInfo.deployments.find(({ name }) => name === contract.name) }), - ) - .filter(contract => contract.gasData?.length && contract.previousVersion?.gasData?.length) - .flatMap(contract => [ - { - contract: contract.name, - method: '[bytecode length]', - avg: variation(contract.bytecode.length / 2 - 1, contract.previousVersion.bytecode.length / 2 - 1), - }, - { - contract: contract.name, - method: '[construction cost]', - avg: variation( - ...[contract.gasData, contract.previousVersion.gasData].map(x => Math.round(average(...x))), - BASE_TX_COST, - ), - }, - ]) - .sort((a, b) => `${a.contract}:${a.method}`.localeCompare(`${b.contract}:${b.method}`)); - - const methods = Object.keys(updateInfo.methods) - .filter(key => refInfo.methods[key]) - .filter(key => updateInfo.methods[key].numberOfCalls > 0) - .filter( - key => !opts.strictTesting || updateInfo.methods[key].numberOfCalls === refInfo.methods[key].numberOfCalls, - ) - .map(key => ({ - contract: refInfo.methods[key].contract, - method: refInfo.methods[key].fnSig, - min: variation(...[updateInfo, refInfo].map(x => Math.min(...x.methods[key].gasData)), BASE_TX_COST), - max: variation(...[updateInfo, refInfo].map(x => Math.max(...x.methods[key].gasData)), BASE_TX_COST), - avg: variation(...[updateInfo, refInfo].map(x => Math.round(average(...x.methods[key].gasData))), BASE_TX_COST), - })) - .sort((a, b) => `${a.contract}:${a.method}`.localeCompare(`${b.contract}:${b.method}`)); - - return [] - .concat(deployments, methods) - .filter(row => !opts.hideEqual || row.min?.delta || row.max?.delta || row.avg?.delta); - } -} - -// Display -function center(text, length) { - return text.padStart((text.length + length) / 2).padEnd(length); -} - -function plusSign(num) { - return num > 0 ? '+' : ''; -} - -function formatCellShell(cell) { - const format = chalk[cell?.delta > 0 ? 'red' : cell?.delta < 0 ? 'green' : 'reset']; - return [ - format((!isFinite(cell?.value) ? '-' : cell.value.toString()).padStart(8)), - format((!isFinite(cell?.delta) ? '-' : plusSign(cell.delta) + cell.delta.toString()).padStart(8)), - format((!isFinite(cell?.prcnt) ? '-' : plusSign(cell.prcnt) + cell.prcnt.toFixed(2) + '%').padStart(8)), - ]; -} - -function formatCmpShell(rows) { - const contractLength = Math.max(8, ...rows.map(({ contract }) => contract.length)); - const methodLength = Math.max(7, ...rows.map(({ method }) => method.length)); - - const COLS = [ - { txt: '', length: 0 }, - { txt: 'Contract', length: contractLength }, - { txt: 'Method', length: methodLength }, - { txt: 'Min', length: 30 }, - { txt: 'Max', length: 30 }, - { txt: 'Avg', length: 30 }, - { txt: '', length: 0 }, - ]; - const HEADER = COLS.map(entry => chalk.bold(center(entry.txt, entry.length || 0))) - .join(' | ') - .trim(); - const SEPARATOR = COLS.map(({ length }) => (length > 0 ? '-'.repeat(length + 2) : '')) - .join('|') - .trim(); - - return [ - '', - HEADER, - ...rows.map(entry => - [ - '', - chalk.grey(entry.contract.padEnd(contractLength)), - entry.method.padEnd(methodLength), - ...formatCellShell(entry.min), - ...formatCellShell(entry.max), - ...formatCellShell(entry.avg), - '', - ] - .join(' | ') - .trim(), - ), - '', - ] - .join(`\n${SEPARATOR}\n`) - .trim(); -} - -function alignPattern(align) { - switch (align) { - case 'left': - case undefined: - return ':-'; - case 'right': - return '-:'; - case 'center': - return ':-:'; - } -} - -function trend(value) { - return value > 0 ? ':x:' : value < 0 ? ':heavy_check_mark:' : ':heavy_minus_sign:'; -} - -function formatCellMarkdown(cell) { - return [ - !isFinite(cell?.value) ? '-' : cell.value.toString(), - !isFinite(cell?.delta) ? '-' : plusSign(cell.delta) + cell.delta.toString(), - !isFinite(cell?.prcnt) ? '-' : plusSign(cell.prcnt) + cell.prcnt.toFixed(2) + '% ' + trend(cell.delta), - ]; -} - -function formatCmpMarkdown(rows) { - const COLS = [ - { txt: '' }, - { txt: 'Contract', align: 'left' }, - { txt: 'Method', align: 'left' }, - { txt: 'Min', align: 'right' }, - { txt: '(+/-)', align: 'right' }, - { txt: '%', align: 'right' }, - { txt: 'Max', align: 'right' }, - { txt: '(+/-)', align: 'right' }, - { txt: '%', align: 'right' }, - { txt: 'Avg', align: 'right' }, - { txt: '(+/-)', align: 'right' }, - { txt: '%', align: 'right' }, - { txt: '' }, - ]; - const HEADER = COLS.map(entry => entry.txt) - .join(' | ') - .trim(); - const SEPARATOR = COLS.map(entry => (entry.txt ? alignPattern(entry.align) : '')) - .join('|') - .trim(); - - return [ - '# Changes to gas costs', - '', - HEADER, - SEPARATOR, - rows - .map(entry => - [ - '', - entry.contract, - entry.method, - ...formatCellMarkdown(entry.min), - ...formatCellMarkdown(entry.max), - ...formatCellMarkdown(entry.avg), - '', - ] - .join(' | ') - .trim(), - ) - .join('\n'), - '', - ] - .join('\n') - .trim(); -} - -// MAIN -const report = Report.compare(Report.load(argv._[0]), Report.load(argv._[1]), argv); - -switch (argv.style) { - case 'markdown': - console.log(formatCmpMarkdown(report)); - break; - case 'shell': - default: - console.log(formatCmpShell(report)); - break; -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/coverage.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/coverage.sh deleted file mode 100644 index a591069c49..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/coverage.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -export COVERAGE=true -export FOUNDRY_FUZZ_RUNS=10 - -# Hardhat coverage -hardhat coverage - -if [ "${CI:-"false"}" == "true" ]; then - # Foundry coverage - forge coverage --report lcov --ir-minimum - # Remove zero hits - sed -i '/,0/d' lcov.info -fi - -# Reports are then uploaded to Codecov automatically by workflow, and merged. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/extract-layout.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/extract-layout.js deleted file mode 100644 index d0b99653ab..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/extract-layout.js +++ /dev/null @@ -1,38 +0,0 @@ -const fs = require('fs'); -const { findAll, astDereferencer, srcDecoder } = require('solidity-ast/utils'); -const { extractStorageLayout } = require('@openzeppelin/upgrades-core/dist/storage/extract'); - -const { _ } = require('yargs').argv; - -const skipPath = ['contracts/mocks/', 'contracts-exposed/']; -const skipKind = ['interface', 'library']; - -function extractLayouts(path) { - const layout = {}; - const { input, output } = JSON.parse(fs.readFileSync(path)); - - const decoder = srcDecoder(input, output); - const deref = astDereferencer(output); - - for (const src in output.contracts) { - if (skipPath.some(prefix => src.startsWith(prefix))) { - continue; - } - - for (const contractDef of findAll('ContractDefinition', output.sources[src].ast)) { - if (skipKind.includes(contractDef.contractKind)) { - continue; - } - - layout[contractDef.name] = extractStorageLayout( - contractDef, - decoder, - deref, - output.contracts[src][contractDef.name].storageLayout, - ); - } - } - return layout; -} - -console.log(JSON.stringify(Object.assign(..._.map(extractLayouts)))); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/generation.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/generation.sh deleted file mode 100644 index 00d609f948..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/generation.sh +++ /dev/null @@ -1,6 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -npm run generate -git diff -R --exit-code diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/inheritance-ordering.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/inheritance-ordering.js deleted file mode 100644 index 4ed2deec45..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/inheritance-ordering.js +++ /dev/null @@ -1,55 +0,0 @@ -#!/usr/bin/env node - -const path = require('path'); -const graphlib = require('graphlib'); -const match = require('micromatch'); -const { findAll } = require('solidity-ast/utils'); -const { _: artifacts } = require('yargs').argv; - -// files to skip -const skipPatterns = ['contracts-exposed/**', 'contracts/mocks/**']; - -for (const artifact of artifacts) { - const { output: solcOutput } = require(path.resolve(__dirname, '../..', artifact)); - - const graph = new graphlib.Graph({ directed: true }); - const names = {}; - const linearized = []; - - for (const source in solcOutput.contracts) { - if (match.any(source, skipPatterns)) continue; - for (const contractDef of findAll('ContractDefinition', solcOutput.sources[source].ast)) { - names[contractDef.id] = contractDef.name; - linearized.push(contractDef.linearizedBaseContracts); - - contractDef.linearizedBaseContracts.forEach((c1, i, contracts) => - contracts.slice(i + 1).forEach(c2 => { - graph.setEdge(c1, c2); - }), - ); - } - } - - /// graphlib.alg.findCycles will not find minimal cycles. - /// We are only interested int cycles of lengths 2 (needs proof) - graph.nodes().forEach((x, i, nodes) => - nodes - .slice(i + 1) - .filter(y => graph.hasEdge(x, y) && graph.hasEdge(y, x)) - .forEach(y => { - console.log(`Conflict between ${names[x]} and ${names[y]} detected in the following dependency chains:`); - linearized - .filter(chain => chain.includes(parseInt(x)) && chain.includes(parseInt(y))) - .forEach(chain => { - const comp = chain.indexOf(parseInt(x)) < chain.indexOf(parseInt(y)) ? '>' : '<'; - console.log(`- ${names[x]} ${comp} ${names[y]} in ${names[chain.find(Boolean)]}`); - // console.log(`- ${names[x]} ${comp} ${names[y]}: ${chain.reverse().map(id => names[id]).join(', ')}`); - }); - process.exitCode = 1; - }), - ); -} - -if (!process.exitCode) { - console.log('Contract ordering is consistent.'); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/pragma-consistency.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/pragma-consistency.js deleted file mode 100644 index f2f3c548f5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/checks/pragma-consistency.js +++ /dev/null @@ -1,49 +0,0 @@ -#!/usr/bin/env node - -const path = require('path'); -const semver = require('semver'); -const match = require('micromatch'); -const { findAll } = require('solidity-ast/utils'); -const { _: artifacts } = require('yargs').argv; - -// files to skip -const skipPatterns = ['contracts-exposed/**', 'contracts/mocks/WithInit.sol']; - -for (const artifact of artifacts) { - const { output: solcOutput } = require(path.resolve(__dirname, '../..', artifact)); - - const pragma = {}; - - // Extract pragma directive for all files - for (const source in solcOutput.contracts) { - if (match.any(source, skipPatterns)) continue; - for (const { literals } of findAll('PragmaDirective', solcOutput.sources[source].ast)) { - // There should only be one. - const [first, ...rest] = literals; - if (first === 'solidity') pragma[source] = rest.join(''); - } - } - - // Compare the pragma directive of the file, to that of the files it imports - for (const source in solcOutput.contracts) { - if (match.any(source, skipPatterns)) continue; - // minimum version of the compiler that matches source's pragma - const minVersion = semver.minVersion(pragma[source]); - // loop over all imports in source - for (const { absolutePath } of findAll('ImportDirective', solcOutput.sources[source].ast)) { - // So files that only import without declaring anything cause issues, because they don't shop in in "pragma" - if (!pragma[absolutePath]) continue; - // Check that the minVersion for source satisfies the requirements of the imported files - if (!semver.satisfies(minVersion, pragma[absolutePath])) { - console.log( - `- ${source} uses ${pragma[source]} but depends on ${absolutePath} that requires ${pragma[absolutePath]}`, - ); - process.exitCode = 1; - } - } - } -} - -if (!process.exitCode) { - console.log('Pragma directives are consistent.'); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/gen-nav.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/gen-nav.js deleted file mode 100644 index de3d0daba1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/gen-nav.js +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/bin/env node - -const path = require('path'); -const glob = require('glob'); -const startCase = require('lodash.startcase'); - -const baseDir = process.argv[2]; - -const files = glob.sync(baseDir + '/**/*.adoc').map(f => path.relative(baseDir, f)); - -console.log('.API'); - -function getPageTitle(directory) { - switch (directory) { - case 'metatx': - return 'Meta Transactions'; - case 'common': - return 'Common (Tokens)'; - default: - return startCase(directory); - } -} - -const links = files.map(file => { - const doc = file.replace(baseDir, ''); - const title = path.parse(file).name; - - return { - xref: `* xref:${doc}[${getPageTitle(title)}]`, - title, - }; -}); - -// Case-insensitive sort based on titles (so 'token/ERC20' gets sorted as 'erc20') -const sortedLinks = links.sort(function (a, b) { - return a.title.toLowerCase().localeCompare(b.title.toLowerCase(), undefined, { numeric: true }); -}); - -for (const link of sortedLinks) { - console.log(link.xref); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/format-lines.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/format-lines.js deleted file mode 100644 index fa3d6b120d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/format-lines.js +++ /dev/null @@ -1,16 +0,0 @@ -function formatLines(...lines) { - return [...indentEach(0, lines)].join('\n') + '\n'; -} - -function* indentEach(indent, lines) { - for (const line of lines) { - if (Array.isArray(line)) { - yield* indentEach(indent + 1, line); - } else { - const padding = ' '.repeat(indent); - yield* line.split('\n').map(subline => (subline === '' ? '' : padding + subline)); - } - } -} - -module.exports = formatLines; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/helpers/sanitize.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/helpers/sanitize.js deleted file mode 100644 index e680ec1bf4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/helpers/sanitize.js +++ /dev/null @@ -1,5 +0,0 @@ -module.exports = { - address: expr => `and(${expr}, shr(96, not(0)))`, - bool: expr => `iszero(iszero(${expr}))`, - bytes: (expr, size) => `and(${expr}, shl(${256 - 8 * size}, not(0)))`, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/run.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/run.js deleted file mode 100644 index 6779c93f44..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/run.js +++ /dev/null @@ -1,58 +0,0 @@ -#!/usr/bin/env node - -// const cp = require('child_process'); -const fs = require('fs'); -const path = require('path'); -const format = require('./format-lines'); - -function getVersion(path) { - try { - return fs.readFileSync(path, 'utf8').match(/\/\/ OpenZeppelin Contracts \(last updated v[^)]+\)/)[0]; - } catch { - return null; - } -} - -function generateFromTemplate(file, template, outputPrefix = '') { - const script = path.relative(path.join(__dirname, '../..'), __filename); - const input = path.join(path.dirname(script), template); - const output = path.join(outputPrefix, file); - const version = getVersion(output); - const content = format( - '// SPDX-License-Identifier: MIT', - ...(version ? [version + ` (${file})`] : []), - `// This file was procedurally generated from ${input}.`, - '', - require(template).trimEnd(), - ); - - fs.writeFileSync(output, content); - // cp.execFileSync('prettier', ['--write', output]); -} - -// Contracts -for (const [file, template] of Object.entries({ - 'utils/cryptography/MerkleProof.sol': './templates/MerkleProof.js', - 'utils/math/SafeCast.sol': './templates/SafeCast.js', - 'utils/structs/Checkpoints.sol': './templates/Checkpoints.js', - 'utils/structs/EnumerableSet.sol': './templates/EnumerableSet.js', - 'utils/structs/EnumerableMap.sol': './templates/EnumerableMap.js', - 'utils/SlotDerivation.sol': './templates/SlotDerivation.js', - 'utils/StorageSlot.sol': './templates/StorageSlot.js', - 'utils/TransientSlot.sol': './templates/TransientSlot.js', - 'utils/Arrays.sol': './templates/Arrays.js', - 'utils/Packing.sol': './templates/Packing.js', - 'mocks/StorageSlotMock.sol': './templates/StorageSlotMock.js', - 'mocks/TransientSlotMock.sol': './templates/TransientSlotMock.js', -})) { - generateFromTemplate(file, template, './contracts/'); -} - -// Tests -for (const [file, template] of Object.entries({ - 'utils/structs/Checkpoints.t.sol': './templates/Checkpoints.t.js', - 'utils/Packing.t.sol': './templates/Packing.t.js', - 'utils/SlotDerivation.t.sol': './templates/SlotDerivation.t.js', -})) { - generateFromTemplate(file, template, './test/'); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Arrays.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Arrays.js deleted file mode 100644 index 0d3676a727..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Arrays.js +++ /dev/null @@ -1,384 +0,0 @@ -const format = require('../format-lines'); -const { capitalize } = require('../../helpers'); -const { TYPES } = require('./Arrays.opts'); - -const header = `\ -pragma solidity ^0.8.20; - -import {Comparators} from "./Comparators.sol"; -import {SlotDerivation} from "./SlotDerivation.sol"; -import {StorageSlot} from "./StorageSlot.sol"; -import {Math} from "./math/Math.sol"; - -/** - * @dev Collection of functions related to array types. - */ -`; - -const sort = type => `\ -/** - * @dev Sort an array of ${type} (in memory) following the provided comparator function. - * - * This function does the sorting "in place", meaning that it overrides the input. The object is returned for - * convenience, but that returned value can be discarded safely if the caller has a memory pointer to the array. - * - * NOTE: this function's cost is \`O(n · log(n))\` in average and \`O(n²)\` in the worst case, with n the length of the - * array. Using it in view functions that are executed through \`eth_call\` is safe, but one should be very careful - * when executing this as part of a transaction. If the array being sorted is too large, the sort operation may - * consume more gas than is available in a block, leading to potential DoS. - * - * IMPORTANT: Consider memory side-effects when using custom comparator functions that access memory in an unsafe way. - */ -function sort( - ${type}[] memory array, - function(${type}, ${type}) pure returns (bool) comp -) internal pure returns (${type}[] memory) { - ${ - type === 'uint256' - ? '_quickSort(_begin(array), _end(array), comp);' - : 'sort(_castToUint256Array(array), _castToUint256Comp(comp));' - } - return array; -} - -/** - * @dev Variant of {sort} that sorts an array of ${type} in increasing order. - */ -function sort(${type}[] memory array) internal pure returns (${type}[] memory) { - ${type === 'uint256' ? 'sort(array, Comparators.lt);' : 'sort(_castToUint256Array(array), Comparators.lt);'} - return array; -} -`; - -const quickSort = `\ -/** - * @dev Performs a quick sort of a segment of memory. The segment sorted starts at \`begin\` (inclusive), and stops - * at end (exclusive). Sorting follows the \`comp\` comparator. - * - * Invariant: \`begin <= end\`. This is the case when initially called by {sort} and is preserved in subcalls. - * - * IMPORTANT: Memory locations between \`begin\` and \`end\` are not validated/zeroed. This function should - * be used only if the limits are within a memory array. - */ -function _quickSort(uint256 begin, uint256 end, function(uint256, uint256) pure returns (bool) comp) private pure { - unchecked { - if (end - begin < 0x40) return; - - // Use first element as pivot - uint256 pivot = _mload(begin); - // Position where the pivot should be at the end of the loop - uint256 pos = begin; - - for (uint256 it = begin + 0x20; it < end; it += 0x20) { - if (comp(_mload(it), pivot)) { - // If the value stored at the iterator's position comes before the pivot, we increment the - // position of the pivot and move the value there. - pos += 0x20; - _swap(pos, it); - } - } - - _swap(begin, pos); // Swap pivot into place - _quickSort(begin, pos, comp); // Sort the left side of the pivot - _quickSort(pos + 0x20, end, comp); // Sort the right side of the pivot - } -} - -/** - * @dev Pointer to the memory location of the first element of \`array\`. - */ -function _begin(uint256[] memory array) private pure returns (uint256 ptr) { - assembly ("memory-safe") { - ptr := add(array, 0x20) - } -} - -/** - * @dev Pointer to the memory location of the first memory word (32bytes) after \`array\`. This is the memory word - * that comes just after the last element of the array. - */ -function _end(uint256[] memory array) private pure returns (uint256 ptr) { - unchecked { - return _begin(array) + array.length * 0x20; - } -} - -/** - * @dev Load memory word (as a uint256) at location \`ptr\`. - */ -function _mload(uint256 ptr) private pure returns (uint256 value) { - assembly { - value := mload(ptr) - } -} - -/** - * @dev Swaps the elements memory location \`ptr1\` and \`ptr2\`. - */ -function _swap(uint256 ptr1, uint256 ptr2) private pure { - assembly { - let value1 := mload(ptr1) - let value2 := mload(ptr2) - mstore(ptr1, value2) - mstore(ptr2, value1) - } -} -`; - -const castArray = type => `\ -/// @dev Helper: low level cast ${type} memory array to uint256 memory array -function _castToUint256Array(${type}[] memory input) private pure returns (uint256[] memory output) { - assembly { - output := input - } -} -`; - -const castComparator = type => `\ -/// @dev Helper: low level cast ${type} comp function to uint256 comp function -function _castToUint256Comp( - function(${type}, ${type}) pure returns (bool) input -) private pure returns (function(uint256, uint256) pure returns (bool) output) { - assembly { - output := input - } -} -`; - -const search = `\ -/** - * @dev Searches a sorted \`array\` and returns the first index that contains - * a value greater or equal to \`element\`. If no such index exists (i.e. all - * values in the array are strictly less than \`element\`), the array length is - * returned. Time complexity O(log n). - * - * NOTE: The \`array\` is expected to be sorted in ascending order, and to - * contain no repeated elements. - * - * IMPORTANT: Deprecated. This implementation behaves as {lowerBound} but lacks - * support for repeated elements in the array. The {lowerBound} function should - * be used instead. - */ -function findUpperBound(uint256[] storage array, uint256 element) internal view returns (uint256) { - uint256 low = 0; - uint256 high = array.length; - - if (high == 0) { - return 0; - } - - while (low < high) { - uint256 mid = Math.average(low, high); - - // Note that mid will always be strictly less than high (i.e. it will be a valid array index) - // because Math.average rounds towards zero (it does integer division with truncation). - if (unsafeAccess(array, mid).value > element) { - high = mid; - } else { - low = mid + 1; - } - } - - // At this point \`low\` is the exclusive upper bound. We will return the inclusive upper bound. - if (low > 0 && unsafeAccess(array, low - 1).value == element) { - return low - 1; - } else { - return low; - } -} - -/** - * @dev Searches an \`array\` sorted in ascending order and returns the first - * index that contains a value greater or equal than \`element\`. If no such index - * exists (i.e. all values in the array are strictly less than \`element\`), the array - * length is returned. Time complexity O(log n). - * - * See C++'s https://en.cppreference.com/w/cpp/algorithm/lower_bound[lower_bound]. - */ -function lowerBound(uint256[] storage array, uint256 element) internal view returns (uint256) { - uint256 low = 0; - uint256 high = array.length; - - if (high == 0) { - return 0; - } - - while (low < high) { - uint256 mid = Math.average(low, high); - - // Note that mid will always be strictly less than high (i.e. it will be a valid array index) - // because Math.average rounds towards zero (it does integer division with truncation). - if (unsafeAccess(array, mid).value < element) { - // this cannot overflow because mid < high - unchecked { - low = mid + 1; - } - } else { - high = mid; - } - } - - return low; -} - -/** - * @dev Searches an \`array\` sorted in ascending order and returns the first - * index that contains a value strictly greater than \`element\`. If no such index - * exists (i.e. all values in the array are strictly less than \`element\`), the array - * length is returned. Time complexity O(log n). - * - * See C++'s https://en.cppreference.com/w/cpp/algorithm/upper_bound[upper_bound]. - */ -function upperBound(uint256[] storage array, uint256 element) internal view returns (uint256) { - uint256 low = 0; - uint256 high = array.length; - - if (high == 0) { - return 0; - } - - while (low < high) { - uint256 mid = Math.average(low, high); - - // Note that mid will always be strictly less than high (i.e. it will be a valid array index) - // because Math.average rounds towards zero (it does integer division with truncation). - if (unsafeAccess(array, mid).value > element) { - high = mid; - } else { - // this cannot overflow because mid < high - unchecked { - low = mid + 1; - } - } - } - - return low; -} - -/** - * @dev Same as {lowerBound}, but with an array in memory. - */ -function lowerBoundMemory(uint256[] memory array, uint256 element) internal pure returns (uint256) { - uint256 low = 0; - uint256 high = array.length; - - if (high == 0) { - return 0; - } - - while (low < high) { - uint256 mid = Math.average(low, high); - - // Note that mid will always be strictly less than high (i.e. it will be a valid array index) - // because Math.average rounds towards zero (it does integer division with truncation). - if (unsafeMemoryAccess(array, mid) < element) { - // this cannot overflow because mid < high - unchecked { - low = mid + 1; - } - } else { - high = mid; - } - } - - return low; -} - -/** - * @dev Same as {upperBound}, but with an array in memory. - */ -function upperBoundMemory(uint256[] memory array, uint256 element) internal pure returns (uint256) { - uint256 low = 0; - uint256 high = array.length; - - if (high == 0) { - return 0; - } - - while (low < high) { - uint256 mid = Math.average(low, high); - - // Note that mid will always be strictly less than high (i.e. it will be a valid array index) - // because Math.average rounds towards zero (it does integer division with truncation). - if (unsafeMemoryAccess(array, mid) > element) { - high = mid; - } else { - // this cannot overflow because mid < high - unchecked { - low = mid + 1; - } - } - } - - return low; -} -`; - -const unsafeAccessStorage = type => `\ -/** - * @dev Access an array in an "unsafe" way. Skips solidity "index-out-of-range" check. - * - * WARNING: Only use if you are certain \`pos\` is lower than the array length. - */ -function unsafeAccess(${type}[] storage arr, uint256 pos) internal pure returns (StorageSlot.${capitalize( - type, -)}Slot storage) { - bytes32 slot; - assembly ("memory-safe") { - slot := arr.slot - } - return slot.deriveArray().offset(pos).get${capitalize(type)}Slot(); -} -`; - -const unsafeAccessMemory = type => `\ -/** - * @dev Access an array in an "unsafe" way. Skips solidity "index-out-of-range" check. - * - * WARNING: Only use if you are certain \`pos\` is lower than the array length. - */ -function unsafeMemoryAccess(${type}[] memory arr, uint256 pos) internal pure returns (${type} res) { - assembly { - res := mload(add(add(arr, 0x20), mul(pos, 0x20))) - } -} -`; - -const unsafeSetLength = type => `\ -/** - * @dev Helper to set the length of an dynamic array. Directly writing to \`.length\` is forbidden. - * - * WARNING: this does not clear elements if length is reduced, of initialize elements if length is increased. - */ -function unsafeSetLength(${type}[] storage array, uint256 len) internal { - assembly ("memory-safe") { - sstore(array.slot, len) - } -} -`; - -// GENERATE -module.exports = format( - header.trimEnd(), - 'library Arrays {', - format( - [].concat( - 'using SlotDerivation for bytes32;', - 'using StorageSlot for bytes32;', - '', - // sorting, comparator, helpers and internal - sort('uint256'), - TYPES.filter(type => type !== 'uint256').map(sort), - quickSort, - TYPES.filter(type => type !== 'uint256').map(castArray), - TYPES.filter(type => type !== 'uint256').map(castComparator), - // lookup - search, - // unsafe (direct) storage and memory access - TYPES.map(unsafeAccessStorage), - TYPES.map(unsafeAccessMemory), - TYPES.map(unsafeSetLength), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Arrays.opts.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Arrays.opts.js deleted file mode 100644 index 67f3299721..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Arrays.opts.js +++ /dev/null @@ -1,3 +0,0 @@ -const TYPES = ['address', 'bytes32', 'uint256']; - -module.exports = { TYPES }; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Checkpoints.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Checkpoints.js deleted file mode 100644 index 7ec4a72532..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Checkpoints.js +++ /dev/null @@ -1,242 +0,0 @@ -const format = require('../format-lines'); -const { OPTS } = require('./Checkpoints.opts'); - -// TEMPLATE -const header = `\ -pragma solidity ^0.8.20; - -import {Math} from "../math/Math.sol"; - -/** - * @dev This library defines the \`Trace*\` struct, for checkpointing values as they change at different points in - * time, and later looking up past values by block number. See {Votes} as an example. - * - * To create a history of checkpoints define a variable type \`Checkpoints.Trace*\` in your contract, and store a new - * checkpoint for the current transaction block using the {push} function. - */ -`; - -const errors = `\ -/** - * @dev A value was attempted to be inserted on a past checkpoint. - */ -error CheckpointUnorderedInsertion(); -`; - -const template = opts => `\ -struct ${opts.historyTypeName} { - ${opts.checkpointTypeName}[] ${opts.checkpointFieldName}; -} - -struct ${opts.checkpointTypeName} { - ${opts.keyTypeName} ${opts.keyFieldName}; - ${opts.valueTypeName} ${opts.valueFieldName}; -} - -/** - * @dev Pushes a (\`key\`, \`value\`) pair into a ${opts.historyTypeName} so that it is stored as the checkpoint. - * - * Returns previous value and new value. - * - * IMPORTANT: Never accept \`key\` as a user input, since an arbitrary \`type(${opts.keyTypeName}).max\` key set will disable the - * library. - */ -function push( - ${opts.historyTypeName} storage self, - ${opts.keyTypeName} key, - ${opts.valueTypeName} value -) internal returns (${opts.valueTypeName} oldValue, ${opts.valueTypeName} newValue) { - return _insert(self.${opts.checkpointFieldName}, key, value); -} - -/** - * @dev Returns the value in the first (oldest) checkpoint with key greater or equal than the search key, or zero if - * there is none. - */ -function lowerLookup(${opts.historyTypeName} storage self, ${opts.keyTypeName} key) internal view returns (${opts.valueTypeName}) { - uint256 len = self.${opts.checkpointFieldName}.length; - uint256 pos = _lowerBinaryLookup(self.${opts.checkpointFieldName}, key, 0, len); - return pos == len ? 0 : _unsafeAccess(self.${opts.checkpointFieldName}, pos).${opts.valueFieldName}; -} - -/** - * @dev Returns the value in the last (most recent) checkpoint with key lower or equal than the search key, or zero - * if there is none. - */ -function upperLookup(${opts.historyTypeName} storage self, ${opts.keyTypeName} key) internal view returns (${opts.valueTypeName}) { - uint256 len = self.${opts.checkpointFieldName}.length; - uint256 pos = _upperBinaryLookup(self.${opts.checkpointFieldName}, key, 0, len); - return pos == 0 ? 0 : _unsafeAccess(self.${opts.checkpointFieldName}, pos - 1).${opts.valueFieldName}; -} - -/** - * @dev Returns the value in the last (most recent) checkpoint with key lower or equal than the search key, or zero - * if there is none. - * - * NOTE: This is a variant of {upperLookup} that is optimised to find "recent" checkpoint (checkpoints with high - * keys). - */ -function upperLookupRecent(${opts.historyTypeName} storage self, ${opts.keyTypeName} key) internal view returns (${opts.valueTypeName}) { - uint256 len = self.${opts.checkpointFieldName}.length; - - uint256 low = 0; - uint256 high = len; - - if (len > 5) { - uint256 mid = len - Math.sqrt(len); - if (key < _unsafeAccess(self.${opts.checkpointFieldName}, mid)._key) { - high = mid; - } else { - low = mid + 1; - } - } - - uint256 pos = _upperBinaryLookup(self.${opts.checkpointFieldName}, key, low, high); - - return pos == 0 ? 0 : _unsafeAccess(self.${opts.checkpointFieldName}, pos - 1).${opts.valueFieldName}; -} - -/** - * @dev Returns the value in the most recent checkpoint, or zero if there are no checkpoints. - */ -function latest(${opts.historyTypeName} storage self) internal view returns (${opts.valueTypeName}) { - uint256 pos = self.${opts.checkpointFieldName}.length; - return pos == 0 ? 0 : _unsafeAccess(self.${opts.checkpointFieldName}, pos - 1).${opts.valueFieldName}; -} - -/** - * @dev Returns whether there is a checkpoint in the structure (i.e. it is not empty), and if so the key and value - * in the most recent checkpoint. - */ -function latestCheckpoint(${opts.historyTypeName} storage self) internal view returns (bool exists, ${opts.keyTypeName} ${opts.keyFieldName}, ${opts.valueTypeName} ${opts.valueFieldName}) { - uint256 pos = self.${opts.checkpointFieldName}.length; - if (pos == 0) { - return (false, 0, 0); - } else { - ${opts.checkpointTypeName} storage ckpt = _unsafeAccess(self.${opts.checkpointFieldName}, pos - 1); - return (true, ckpt.${opts.keyFieldName}, ckpt.${opts.valueFieldName}); - } -} - -/** - * @dev Returns the number of checkpoint. - */ -function length(${opts.historyTypeName} storage self) internal view returns (uint256) { - return self.${opts.checkpointFieldName}.length; -} - -/** - * @dev Returns checkpoint at given position. - */ -function at(${opts.historyTypeName} storage self, uint32 pos) internal view returns (${opts.checkpointTypeName} memory) { - return self.${opts.checkpointFieldName}[pos]; -} - -/** - * @dev Pushes a (\`key\`, \`value\`) pair into an ordered list of checkpoints, either by inserting a new checkpoint, - * or by updating the last one. - */ -function _insert( - ${opts.checkpointTypeName}[] storage self, - ${opts.keyTypeName} key, - ${opts.valueTypeName} value -) private returns (${opts.valueTypeName} oldValue, ${opts.valueTypeName} newValue) { - uint256 pos = self.length; - - if (pos > 0) { - ${opts.checkpointTypeName} storage last = _unsafeAccess(self, pos - 1); - ${opts.keyTypeName} lastKey = last.${opts.keyFieldName}; - ${opts.valueTypeName} lastValue = last.${opts.valueFieldName}; - - // Checkpoint keys must be non-decreasing. - if (lastKey > key) { - revert CheckpointUnorderedInsertion(); - } - - // Update or push new checkpoint - if (lastKey == key) { - last.${opts.valueFieldName} = value; - } else { - self.push(${opts.checkpointTypeName}({${opts.keyFieldName}: key, ${opts.valueFieldName}: value})); - } - return (lastValue, value); - } else { - self.push(${opts.checkpointTypeName}({${opts.keyFieldName}: key, ${opts.valueFieldName}: value})); - return (0, value); - } -} - -/** - * @dev Return the index of the first (oldest) checkpoint with key strictly bigger than the search key, or \`high\` - * if there is none. \`low\` and \`high\` define a section where to do the search, with inclusive \`low\` and exclusive - * \`high\`. - * - * WARNING: \`high\` should not be greater than the array's length. - */ -function _upperBinaryLookup( - ${opts.checkpointTypeName}[] storage self, - ${opts.keyTypeName} key, - uint256 low, - uint256 high -) private view returns (uint256) { - while (low < high) { - uint256 mid = Math.average(low, high); - if (_unsafeAccess(self, mid).${opts.keyFieldName} > key) { - high = mid; - } else { - low = mid + 1; - } - } - return high; -} - -/** - * @dev Return the index of the first (oldest) checkpoint with key greater or equal than the search key, or \`high\` - * if there is none. \`low\` and \`high\` define a section where to do the search, with inclusive \`low\` and exclusive - * \`high\`. - * - * WARNING: \`high\` should not be greater than the array's length. - */ -function _lowerBinaryLookup( - ${opts.checkpointTypeName}[] storage self, - ${opts.keyTypeName} key, - uint256 low, - uint256 high -) private view returns (uint256) { - while (low < high) { - uint256 mid = Math.average(low, high); - if (_unsafeAccess(self, mid).${opts.keyFieldName} < key) { - low = mid + 1; - } else { - high = mid; - } - } - return high; -} - -/** - * @dev Access an element of the array without performing bounds check. The position is assumed to be within bounds. - */ -function _unsafeAccess( - ${opts.checkpointTypeName}[] storage self, - uint256 pos -) private pure returns (${opts.checkpointTypeName} storage result) { - assembly { - mstore(0, self.slot) - result.slot := add(keccak256(0, 0x20), pos) - } -} -`; - -// GENERATE -module.exports = format( - header.trimEnd(), - 'library Checkpoints {', - format( - [].concat( - errors, - OPTS.map(opts => template(opts)), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Checkpoints.opts.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Checkpoints.opts.js deleted file mode 100644 index 08b7b910b8..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Checkpoints.opts.js +++ /dev/null @@ -1,17 +0,0 @@ -// OPTIONS -const VALUE_SIZES = [224, 208, 160]; - -const defaultOpts = size => ({ - historyTypeName: `Trace${size}`, - checkpointTypeName: `Checkpoint${size}`, - checkpointFieldName: '_checkpoints', - keyTypeName: `uint${256 - size}`, - keyFieldName: '_key', - valueTypeName: `uint${size}`, - valueFieldName: '_value', -}); - -module.exports = { - VALUE_SIZES, - OPTS: VALUE_SIZES.map(size => defaultOpts(size)), -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Checkpoints.t.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Checkpoints.t.js deleted file mode 100644 index edd2e9f98a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Checkpoints.t.js +++ /dev/null @@ -1,137 +0,0 @@ -const format = require('../format-lines'); -const { capitalize } = require('../../helpers'); -const { OPTS } = require('./Checkpoints.opts.js'); - -// TEMPLATE -const header = `\ -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {SafeCast} from "@openzeppelin/contracts/utils/math/SafeCast.sol"; -import {Checkpoints} from "@openzeppelin/contracts/utils/structs/Checkpoints.sol"; -`; - -const template = opts => `\ -using Checkpoints for Checkpoints.${opts.historyTypeName}; - -// Maximum gap between keys used during the fuzzing tests: the \`_prepareKeys\` function with make sure that -// key#n+1 is in the [key#n, key#n + _KEY_MAX_GAP] range. -uint8 internal constant _KEY_MAX_GAP = 64; - -Checkpoints.${opts.historyTypeName} internal _ckpts; - -// helpers -function _bound${capitalize(opts.keyTypeName)}(${opts.keyTypeName} x, ${opts.keyTypeName} min, ${ - opts.keyTypeName -} max) internal pure returns (${opts.keyTypeName}) { - return SafeCast.to${capitalize(opts.keyTypeName)}(bound(uint256(x), uint256(min), uint256(max))); -} - -function _prepareKeys(${opts.keyTypeName}[] memory keys, ${opts.keyTypeName} maxSpread) internal pure { - ${opts.keyTypeName} lastKey = 0; - for (uint256 i = 0; i < keys.length; ++i) { - ${opts.keyTypeName} key = _bound${capitalize(opts.keyTypeName)}(keys[i], lastKey, lastKey + maxSpread); - keys[i] = key; - lastKey = key; - } -} - -function _assertLatestCheckpoint(bool exist, ${opts.keyTypeName} key, ${opts.valueTypeName} value) internal { - (bool _exist, ${opts.keyTypeName} _key, ${opts.valueTypeName} _value) = _ckpts.latestCheckpoint(); - assertEq(_exist, exist); - assertEq(_key, key); - assertEq(_value, value); -} - -// tests -function testPush(${opts.keyTypeName}[] memory keys, ${opts.valueTypeName}[] memory values, ${ - opts.keyTypeName -} pastKey) public { - vm.assume(values.length > 0 && values.length <= keys.length); - _prepareKeys(keys, _KEY_MAX_GAP); - - // initial state - assertEq(_ckpts.length(), 0); - assertEq(_ckpts.latest(), 0); - _assertLatestCheckpoint(false, 0, 0); - - uint256 duplicates = 0; - for (uint256 i = 0; i < keys.length; ++i) { - ${opts.keyTypeName} key = keys[i]; - ${opts.valueTypeName} value = values[i % values.length]; - if (i > 0 && key == keys[i - 1]) ++duplicates; - - // push - _ckpts.push(key, value); - - // check length & latest - assertEq(_ckpts.length(), i + 1 - duplicates); - assertEq(_ckpts.latest(), value); - _assertLatestCheckpoint(true, key, value); - } - - if (keys.length > 0) { - ${opts.keyTypeName} lastKey = keys[keys.length - 1]; - if (lastKey > 0) { - pastKey = _bound${capitalize(opts.keyTypeName)}(pastKey, 0, lastKey - 1); - - vm.expectRevert(); - this.push(pastKey, values[keys.length % values.length]); - } - } -} - -// used to test reverts -function push(${opts.keyTypeName} key, ${opts.valueTypeName} value) external { - _ckpts.push(key, value); -} - -function testLookup(${opts.keyTypeName}[] memory keys, ${opts.valueTypeName}[] memory values, ${ - opts.keyTypeName -} lookup) public { - vm.assume(values.length > 0 && values.length <= keys.length); - _prepareKeys(keys, _KEY_MAX_GAP); - - ${opts.keyTypeName} lastKey = keys.length == 0 ? 0 : keys[keys.length - 1]; - lookup = _bound${capitalize(opts.keyTypeName)}(lookup, 0, lastKey + _KEY_MAX_GAP); - - ${opts.valueTypeName} upper = 0; - ${opts.valueTypeName} lower = 0; - ${opts.keyTypeName} lowerKey = type(${opts.keyTypeName}).max; - for (uint256 i = 0; i < keys.length; ++i) { - ${opts.keyTypeName} key = keys[i]; - ${opts.valueTypeName} value = values[i % values.length]; - - // push - _ckpts.push(key, value); - - // track expected result of lookups - if (key <= lookup) { - upper = value; - } - // find the first key that is not smaller than the lookup key - if (key >= lookup && (i == 0 || keys[i - 1] < lookup)) { - lowerKey = key; - } - if (key == lowerKey) { - lower = value; - } - } - - // check lookup - assertEq(_ckpts.lowerLookup(lookup), lower); - assertEq(_ckpts.upperLookup(lookup), upper); - assertEq(_ckpts.upperLookupRecent(lookup), upper); -} -`; - -// GENERATE -module.exports = format( - header, - ...OPTS.flatMap(opts => [ - `contract Checkpoints${opts.historyTypeName}Test is Test {`, - [template(opts).trimEnd()], - '}', - '', - ]), -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/EnumerableMap.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/EnumerableMap.js deleted file mode 100644 index c9cad6c1bc..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/EnumerableMap.js +++ /dev/null @@ -1,272 +0,0 @@ -const format = require('../format-lines'); -const { fromBytes32, toBytes32 } = require('./conversion'); -const { TYPES } = require('./EnumerableMap.opts'); - -const header = `\ -pragma solidity ^0.8.20; - -import {EnumerableSet} from "./EnumerableSet.sol"; - -/** - * @dev Library for managing an enumerable variant of Solidity's - * https://solidity.readthedocs.io/en/latest/types.html#mapping-types[\`mapping\`] - * type. - * - * Maps have the following properties: - * - * - Entries are added, removed, and checked for existence in constant time - * (O(1)). - * - Entries are enumerated in O(n). No guarantees are made on the ordering. - * - * \`\`\`solidity - * contract Example { - * // Add the library methods - * using EnumerableMap for EnumerableMap.UintToAddressMap; - * - * // Declare a set state variable - * EnumerableMap.UintToAddressMap private myMap; - * } - * \`\`\` - * - * The following map types are supported: - * - * - \`uint256 -> address\` (\`UintToAddressMap\`) since v3.0.0 - * - \`address -> uint256\` (\`AddressToUintMap\`) since v4.6.0 - * - \`bytes32 -> bytes32\` (\`Bytes32ToBytes32Map\`) since v4.6.0 - * - \`uint256 -> uint256\` (\`UintToUintMap\`) since v4.7.0 - * - \`bytes32 -> uint256\` (\`Bytes32ToUintMap\`) since v4.7.0 - * - \`uint256 -> bytes32\` (\`UintToBytes32Map\`) since v5.1.0 - * - \`address -> address\` (\`AddressToAddressMap\`) since v5.1.0 - * - \`address -> bytes32\` (\`AddressToBytes32Map\`) since v5.1.0 - * - \`bytes32 -> address\` (\`Bytes32ToAddressMap\`) since v5.1.0 - * - * [WARNING] - * ==== - * Trying to delete such a structure from storage will likely result in data corruption, rendering the structure - * unusable. - * See https://github.com/ethereum/solidity/pull/11843[ethereum/solidity#11843] for more info. - * - * In order to clean an EnumerableMap, you can either remove all elements one by one or create a fresh instance using an - * array of EnumerableMap. - * ==== - */ -`; - -const defaultMap = `\ -// To implement this library for multiple types with as little code repetition as possible, we write it in -// terms of a generic Map type with bytes32 keys and values. The Map implementation uses private functions, -// and user-facing implementations such as \`UintToAddressMap\` are just wrappers around the underlying Map. -// This means that we can only create new EnumerableMaps for types that fit in bytes32. - -/** - * @dev Query for a nonexistent map key. - */ -error EnumerableMapNonexistentKey(bytes32 key); - -struct Bytes32ToBytes32Map { - // Storage of keys - EnumerableSet.Bytes32Set _keys; - mapping(bytes32 key => bytes32) _values; -} - -/** - * @dev Adds a key-value pair to a map, or updates the value for an existing - * key. O(1). - * - * Returns true if the key was added to the map, that is if it was not - * already present. - */ -function set(Bytes32ToBytes32Map storage map, bytes32 key, bytes32 value) internal returns (bool) { - map._values[key] = value; - return map._keys.add(key); -} - -/** - * @dev Removes a key-value pair from a map. O(1). - * - * Returns true if the key was removed from the map, that is if it was present. - */ -function remove(Bytes32ToBytes32Map storage map, bytes32 key) internal returns (bool) { - delete map._values[key]; - return map._keys.remove(key); -} - -/** - * @dev Returns true if the key is in the map. O(1). - */ -function contains(Bytes32ToBytes32Map storage map, bytes32 key) internal view returns (bool) { - return map._keys.contains(key); -} - -/** - * @dev Returns the number of key-value pairs in the map. O(1). - */ -function length(Bytes32ToBytes32Map storage map) internal view returns (uint256) { - return map._keys.length(); -} - -/** - * @dev Returns the key-value pair stored at position \`index\` in the map. O(1). - * - * Note that there are no guarantees on the ordering of entries inside the - * array, and it may change when more entries are added or removed. - * - * Requirements: - * - * - \`index\` must be strictly less than {length}. - */ -function at(Bytes32ToBytes32Map storage map, uint256 index) internal view returns (bytes32 key, bytes32 value) { - bytes32 atKey = map._keys.at(index); - return (atKey, map._values[atKey]); -} - -/** - * @dev Tries to returns the value associated with \`key\`. O(1). - * Does not revert if \`key\` is not in the map. - */ -function tryGet(Bytes32ToBytes32Map storage map, bytes32 key) internal view returns (bool exists, bytes32 value) { - bytes32 val = map._values[key]; - if (val == bytes32(0)) { - return (contains(map, key), bytes32(0)); - } else { - return (true, val); - } -} - -/** - * @dev Returns the value associated with \`key\`. O(1). - * - * Requirements: - * - * - \`key\` must be in the map. - */ -function get(Bytes32ToBytes32Map storage map, bytes32 key) internal view returns (bytes32) { - bytes32 value = map._values[key]; - if (value == 0 && !contains(map, key)) { - revert EnumerableMapNonexistentKey(key); - } - return value; -} - -/** - * @dev Return the an array containing all the keys - * - * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed - * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that - * this function has an unbounded cost, and using it as part of a state-changing function may render the function - * uncallable if the map grows to a point where copying to memory consumes too much gas to fit in a block. - */ -function keys(Bytes32ToBytes32Map storage map) internal view returns (bytes32[] memory) { - return map._keys.values(); -} -`; - -const customMap = ({ name, keyType, valueType }) => `\ -// ${name} - -struct ${name} { - Bytes32ToBytes32Map _inner; -} - -/** - * @dev Adds a key-value pair to a map, or updates the value for an existing - * key. O(1). - * - * Returns true if the key was added to the map, that is if it was not - * already present. - */ -function set(${name} storage map, ${keyType} key, ${valueType} value) internal returns (bool) { - return set(map._inner, ${toBytes32(keyType, 'key')}, ${toBytes32(valueType, 'value')}); -} - -/** - * @dev Removes a value from a map. O(1). - * - * Returns true if the key was removed from the map, that is if it was present. - */ -function remove(${name} storage map, ${keyType} key) internal returns (bool) { - return remove(map._inner, ${toBytes32(keyType, 'key')}); -} - -/** - * @dev Returns true if the key is in the map. O(1). - */ -function contains(${name} storage map, ${keyType} key) internal view returns (bool) { - return contains(map._inner, ${toBytes32(keyType, 'key')}); -} - -/** - * @dev Returns the number of elements in the map. O(1). - */ -function length(${name} storage map) internal view returns (uint256) { - return length(map._inner); -} - -/** - * @dev Returns the element stored at position \`index\` in the map. O(1). - * Note that there are no guarantees on the ordering of values inside the - * array, and it may change when more values are added or removed. - * - * Requirements: - * - * - \`index\` must be strictly less than {length}. - */ -function at(${name} storage map, uint256 index) internal view returns (${keyType} key, ${valueType} value) { - (bytes32 atKey, bytes32 val) = at(map._inner, index); - return (${fromBytes32(keyType, 'atKey')}, ${fromBytes32(valueType, 'val')}); -} - -/** - * @dev Tries to returns the value associated with \`key\`. O(1). - * Does not revert if \`key\` is not in the map. - */ -function tryGet(${name} storage map, ${keyType} key) internal view returns (bool exists, ${valueType} value) { - (bool success, bytes32 val) = tryGet(map._inner, ${toBytes32(keyType, 'key')}); - return (success, ${fromBytes32(valueType, 'val')}); -} - -/** - * @dev Returns the value associated with \`key\`. O(1). - * - * Requirements: - * - * - \`key\` must be in the map. - */ -function get(${name} storage map, ${keyType} key) internal view returns (${valueType}) { - return ${fromBytes32(valueType, `get(map._inner, ${toBytes32(keyType, 'key')})`)}; -} - -/** - * @dev Return the an array containing all the keys - * - * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed - * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that - * this function has an unbounded cost, and using it as part of a state-changing function may render the function - * uncallable if the map grows to a point where copying to memory consumes too much gas to fit in a block. - */ -function keys(${name} storage map) internal view returns (${keyType}[] memory) { - bytes32[] memory store = keys(map._inner); - ${keyType}[] memory result; - - assembly ("memory-safe") { - result := store - } - - return result; -} -`; - -// GENERATE -module.exports = format( - header.trimEnd(), - 'library EnumerableMap {', - format( - [].concat( - 'using EnumerableSet for EnumerableSet.Bytes32Set;', - '', - defaultMap, - TYPES.map(details => customMap(details)), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/EnumerableMap.opts.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/EnumerableMap.opts.js deleted file mode 100644 index d26ab05b2a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/EnumerableMap.opts.js +++ /dev/null @@ -1,19 +0,0 @@ -const { capitalize } = require('../../helpers'); - -const mapType = str => (str == 'uint256' ? 'Uint' : capitalize(str)); - -const formatType = (keyType, valueType) => ({ - name: `${mapType(keyType)}To${mapType(valueType)}Map`, - keyType, - valueType, -}); - -const TYPES = ['uint256', 'address', 'bytes32'] - .flatMap((key, _, array) => array.map(value => [key, value])) - .slice(0, -1) // remove bytes32 → byte32 (last one) that is already defined - .map(args => formatType(...args)); - -module.exports = { - TYPES, - formatType, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/EnumerableSet.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/EnumerableSet.js deleted file mode 100644 index 02eccd0df1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/EnumerableSet.js +++ /dev/null @@ -1,247 +0,0 @@ -const format = require('../format-lines'); -const { fromBytes32, toBytes32 } = require('./conversion'); -const { TYPES } = require('./EnumerableSet.opts'); - -const header = `\ -pragma solidity ^0.8.20; - -/** - * @dev Library for managing - * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive - * types. - * - * Sets have the following properties: - * - * - Elements are added, removed, and checked for existence in constant time - * (O(1)). - * - Elements are enumerated in O(n). No guarantees are made on the ordering. - * - * \`\`\`solidity - * contract Example { - * // Add the library methods - * using EnumerableSet for EnumerableSet.AddressSet; - * - * // Declare a set state variable - * EnumerableSet.AddressSet private mySet; - * } - * \`\`\` - * - * As of v3.3.0, sets of type \`bytes32\` (\`Bytes32Set\`), \`address\` (\`AddressSet\`) - * and \`uint256\` (\`UintSet\`) are supported. - * - * [WARNING] - * ==== - * Trying to delete such a structure from storage will likely result in data corruption, rendering the structure - * unusable. - * See https://github.com/ethereum/solidity/pull/11843[ethereum/solidity#11843] for more info. - * - * In order to clean an EnumerableSet, you can either remove all elements one by one or create a fresh instance using an - * array of EnumerableSet. - * ==== - */ -`; - -const defaultSet = `\ -// To implement this library for multiple types with as little code -// repetition as possible, we write it in terms of a generic Set type with -// bytes32 values. -// The Set implementation uses private functions, and user-facing -// implementations (such as AddressSet) are just wrappers around the -// underlying Set. -// This means that we can only create new EnumerableSets for types that fit -// in bytes32. - -struct Set { - // Storage of set values - bytes32[] _values; - // Position is the index of the value in the \`values\` array plus 1. - // Position 0 is used to mean a value is not in the set. - mapping(bytes32 value => uint256) _positions; -} - -/** - * @dev Add a value to a set. O(1). - * - * Returns true if the value was added to the set, that is if it was not - * already present. - */ -function _add(Set storage set, bytes32 value) private returns (bool) { - if (!_contains(set, value)) { - set._values.push(value); - // The value is stored at length-1, but we add 1 to all indexes - // and use 0 as a sentinel value - set._positions[value] = set._values.length; - return true; - } else { - return false; - } -} - -/** - * @dev Removes a value from a set. O(1). - * - * Returns true if the value was removed from the set, that is if it was - * present. - */ -function _remove(Set storage set, bytes32 value) private returns (bool) { - // We cache the value's position to prevent multiple reads from the same storage slot - uint256 position = set._positions[value]; - - if (position != 0) { - // Equivalent to contains(set, value) - // To delete an element from the _values array in O(1), we swap the element to delete with the last one in - // the array, and then remove the last element (sometimes called as 'swap and pop'). - // This modifies the order of the array, as noted in {at}. - - uint256 valueIndex = position - 1; - uint256 lastIndex = set._values.length - 1; - - if (valueIndex != lastIndex) { - bytes32 lastValue = set._values[lastIndex]; - - // Move the lastValue to the index where the value to delete is - set._values[valueIndex] = lastValue; - // Update the tracked position of the lastValue (that was just moved) - set._positions[lastValue] = position; - } - - // Delete the slot where the moved value was stored - set._values.pop(); - - // Delete the tracked position for the deleted slot - delete set._positions[value]; - - return true; - } else { - return false; - } -} - -/** - * @dev Returns true if the value is in the set. O(1). - */ -function _contains(Set storage set, bytes32 value) private view returns (bool) { - return set._positions[value] != 0; -} - -/** - * @dev Returns the number of values on the set. O(1). - */ -function _length(Set storage set) private view returns (uint256) { - return set._values.length; -} - -/** - * @dev Returns the value stored at position \`index\` in the set. O(1). - * - * Note that there are no guarantees on the ordering of values inside the - * array, and it may change when more values are added or removed. - * - * Requirements: - * - * - \`index\` must be strictly less than {length}. - */ -function _at(Set storage set, uint256 index) private view returns (bytes32) { - return set._values[index]; -} - -/** - * @dev Return the entire set in an array - * - * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed - * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that - * this function has an unbounded cost, and using it as part of a state-changing function may render the function - * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. - */ -function _values(Set storage set) private view returns (bytes32[] memory) { - return set._values; -} -`; - -const customSet = ({ name, type }) => `\ -// ${name} - -struct ${name} { - Set _inner; -} - -/** - * @dev Add a value to a set. O(1). - * - * Returns true if the value was added to the set, that is if it was not - * already present. - */ -function add(${name} storage set, ${type} value) internal returns (bool) { - return _add(set._inner, ${toBytes32(type, 'value')}); -} - -/** - * @dev Removes a value from a set. O(1). - * - * Returns true if the value was removed from the set, that is if it was - * present. - */ -function remove(${name} storage set, ${type} value) internal returns (bool) { - return _remove(set._inner, ${toBytes32(type, 'value')}); -} - -/** - * @dev Returns true if the value is in the set. O(1). - */ -function contains(${name} storage set, ${type} value) internal view returns (bool) { - return _contains(set._inner, ${toBytes32(type, 'value')}); -} - -/** - * @dev Returns the number of values in the set. O(1). - */ -function length(${name} storage set) internal view returns (uint256) { - return _length(set._inner); -} - -/** - * @dev Returns the value stored at position \`index\` in the set. O(1). - * - * Note that there are no guarantees on the ordering of values inside the - * array, and it may change when more values are added or removed. - * - * Requirements: - * - * - \`index\` must be strictly less than {length}. - */ -function at(${name} storage set, uint256 index) internal view returns (${type}) { - return ${fromBytes32(type, '_at(set._inner, index)')}; -} - -/** - * @dev Return the entire set in an array - * - * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed - * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that - * this function has an unbounded cost, and using it as part of a state-changing function may render the function - * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. - */ -function values(${name} storage set) internal view returns (${type}[] memory) { - bytes32[] memory store = _values(set._inner); - ${type}[] memory result; - - assembly ("memory-safe") { - result := store - } - - return result; -} -`; - -// GENERATE -module.exports = format( - header.trimEnd(), - 'library EnumerableSet {', - format( - [].concat( - defaultSet, - TYPES.map(details => customSet(details)), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/EnumerableSet.opts.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/EnumerableSet.opts.js deleted file mode 100644 index 739f0acdfe..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/EnumerableSet.opts.js +++ /dev/null @@ -1,12 +0,0 @@ -const { capitalize } = require('../../helpers'); - -const mapType = str => (str == 'uint256' ? 'Uint' : capitalize(str)); - -const formatType = type => ({ - name: `${mapType(type)}Set`, - type, -}); - -const TYPES = ['bytes32', 'address', 'uint256'].map(formatType); - -module.exports = { TYPES, formatType }; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/MerkleProof.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/MerkleProof.js deleted file mode 100644 index 890b2febac..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/MerkleProof.js +++ /dev/null @@ -1,187 +0,0 @@ -const format = require('../format-lines'); -const { OPTS } = require('./MerkleProof.opts'); - -const DEFAULT_HASH = 'Hashes.commutativeKeccak256'; - -const formatArgsSingleLine = (...args) => args.filter(Boolean).join(', '); -const formatArgsMultiline = (...args) => '\n' + format(args.filter(Boolean).join(',\0').split('\0')); - -// TEMPLATE -const header = `\ -pragma solidity ^0.8.20; - -import {Hashes} from "./Hashes.sol"; - -/** - * @dev These functions deal with verification of Merkle Tree proofs. - * - * The tree and the proofs can be generated using our - * https://github.com/OpenZeppelin/merkle-tree[JavaScript library]. - * You will find a quickstart guide in the readme. - * - * WARNING: You should avoid using leaf values that are 64 bytes long prior to - * hashing, or use a hash function other than keccak256 for hashing leaves. - * This is because the concatenation of a sorted pair of internal nodes in - * the Merkle tree could be reinterpreted as a leaf value. - * OpenZeppelin's JavaScript library generates Merkle trees that are safe - * against this attack out of the box. - * - * IMPORTANT: Consider memory side-effects when using custom hashing functions - * that access memory in an unsafe way. - * - * NOTE: This library supports proof verification for merkle trees built using - * custom _commutative_ hashing functions (i.e. \`H(a, b) == H(b, a)\`). Proving - * leaf inclusion in trees built using non-commutative hashing functions requires - * additional logic that is not supported by this library. - */ -`; - -const errors = `\ -/** - *@dev The multiproof provided is not valid. - */ -error MerkleProofInvalidMultiproof(); -`; - -const templateProof = ({ suffix, location, visibility, hash }) => `\ -/** - * @dev Returns true if a \`leaf\` can be proved to be a part of a Merkle tree - * defined by \`root\`. For this, a \`proof\` must be provided, containing - * sibling hashes on the branch from the leaf to the root of the tree. Each - * pair of leaves and each pair of pre-images are assumed to be sorted. - * - * This version handles proofs in ${location} with ${hash ? 'a custom' : 'the default'} hashing function. - */ -function verify${suffix}(${(hash ? formatArgsMultiline : formatArgsSingleLine)( - `bytes32[] ${location} proof`, - 'bytes32 root', - 'bytes32 leaf', - hash && `function(bytes32, bytes32) view returns (bytes32) ${hash}`, -)}) internal ${visibility} returns (bool) { - return processProof${suffix}(proof, leaf${hash ? `, ${hash}` : ''}) == root; -} - -/** - * @dev Returns the rebuilt hash obtained by traversing a Merkle tree up - * from \`leaf\` using \`proof\`. A \`proof\` is valid if and only if the rebuilt - * hash matches the root of the tree. When processing the proof, the pairs - * of leaves & pre-images are assumed to be sorted. - * - * This version handles proofs in ${location} with ${hash ? 'a custom' : 'the default'} hashing function. - */ -function processProof${suffix}(${(hash ? formatArgsMultiline : formatArgsSingleLine)( - `bytes32[] ${location} proof`, - 'bytes32 leaf', - hash && `function(bytes32, bytes32) view returns (bytes32) ${hash}`, -)}) internal ${visibility} returns (bytes32) { - bytes32 computedHash = leaf; - for (uint256 i = 0; i < proof.length; i++) { - computedHash = ${hash ?? DEFAULT_HASH}(computedHash, proof[i]); - } - return computedHash; -} -`; - -const templateMultiProof = ({ suffix, location, visibility, hash }) => `\ -/** - * @dev Returns true if the \`leaves\` can be simultaneously proven to be a part of a Merkle tree defined by - * \`root\`, according to \`proof\` and \`proofFlags\` as described in {processMultiProof}. - * - * This version handles multiproofs in ${location} with ${hash ? 'a custom' : 'the default'} hashing function. - * - * CAUTION: Not all Merkle trees admit multiproofs. See {processMultiProof} for details. - * - * NOTE: Consider the case where \`root == proof[0] && leaves.length == 0\` as it will return \`true\`. - * The \`leaves\` must be validated independently. See {processMultiProof${suffix}}. - */ -function multiProofVerify${suffix}(${formatArgsMultiline( - `bytes32[] ${location} proof`, - `bool[] ${location} proofFlags`, - 'bytes32 root', - `bytes32[] memory leaves`, - hash && `function(bytes32, bytes32) view returns (bytes32) ${hash}`, -)}) internal ${visibility} returns (bool) { - return processMultiProof${suffix}(proof, proofFlags, leaves${hash ? `, ${hash}` : ''}) == root; -} - -/** - * @dev Returns the root of a tree reconstructed from \`leaves\` and sibling nodes in \`proof\`. The reconstruction - * proceeds by incrementally reconstructing all inner nodes by combining a leaf/inner node with either another - * leaf/inner node or a proof sibling node, depending on whether each \`proofFlags\` item is true or false - * respectively. - * - * This version handles multiproofs in ${location} with ${hash ? 'a custom' : 'the default'} hashing function. - * - * CAUTION: Not all Merkle trees admit multiproofs. To use multiproofs, it is sufficient to ensure that: 1) the tree - * is complete (but not necessarily perfect), 2) the leaves to be proven are in the opposite order they are in the - * tree (i.e., as seen from right to left starting at the deepest layer and continuing at the next layer). - * - * NOTE: The _empty set_ (i.e. the case where \`proof.length == 1 && leaves.length == 0\`) is considered a no-op, - * and therefore a valid multiproof (i.e. it returns \`proof[0]\`). Consider disallowing this case if you're not - * validating the leaves elsewhere. - */ -function processMultiProof${suffix}(${formatArgsMultiline( - `bytes32[] ${location} proof`, - `bool[] ${location} proofFlags`, - `bytes32[] memory leaves`, - hash && `function(bytes32, bytes32) view returns (bytes32) ${hash}`, -)}) internal ${visibility} returns (bytes32 merkleRoot) { - // This function rebuilds the root hash by traversing the tree up from the leaves. The root is rebuilt by - // consuming and producing values on a queue. The queue starts with the \`leaves\` array, then goes onto the - // \`hashes\` array. At the end of the process, the last hash in the \`hashes\` array should contain the root of - // the Merkle tree. - uint256 leavesLen = leaves.length; - uint256 proofFlagsLen = proofFlags.length; - - // Check proof validity. - if (leavesLen + proof.length != proofFlagsLen + 1) { - revert MerkleProofInvalidMultiproof(); - } - - // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using - // \`xxx[xxxPos++]\`, which return the current value and increment the pointer, thus mimicking a queue's "pop". - bytes32[] memory hashes = new bytes32[](proofFlagsLen); - uint256 leafPos = 0; - uint256 hashPos = 0; - uint256 proofPos = 0; - // At each step, we compute the next hash using two values: - // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we - // get the next hash. - // - depending on the flag, either another value from the "main queue" (merging branches) or an element from the - // \`proof\` array. - for (uint256 i = 0; i < proofFlagsLen; i++) { - bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++]; - bytes32 b = proofFlags[i] - ? (leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++]) - : proof[proofPos++]; - hashes[i] = ${hash ?? DEFAULT_HASH}(a, b); - } - - if (proofFlagsLen > 0) { - if (proofPos != proof.length) { - revert MerkleProofInvalidMultiproof(); - } - unchecked { - return hashes[proofFlagsLen - 1]; - } - } else if (leavesLen > 0) { - return leaves[0]; - } else { - return proof[0]; - } -} -`; - -// GENERATE -module.exports = format( - header.trimEnd(), - 'library MerkleProof {', - format( - [].concat( - errors, - OPTS.flatMap(opts => templateProof(opts)), - OPTS.flatMap(opts => templateMultiProof(opts)), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/MerkleProof.opts.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/MerkleProof.opts.js deleted file mode 100644 index 911f239225..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/MerkleProof.opts.js +++ /dev/null @@ -1,11 +0,0 @@ -const { product } = require('../../helpers'); - -const OPTS = product( - [ - { suffix: '', location: 'memory' }, - { suffix: 'Calldata', location: 'calldata' }, - ], - [{ visibility: 'pure' }, { visibility: 'view', hash: 'hasher' }], -).map(objs => Object.assign({}, ...objs)); - -module.exports = { OPTS }; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Packing.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Packing.js deleted file mode 100644 index 9f3b7716a6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Packing.js +++ /dev/null @@ -1,92 +0,0 @@ -const format = require('../format-lines'); -const sanitize = require('../helpers/sanitize'); -const { product } = require('../../helpers'); -const { SIZES } = require('./Packing.opts'); - -// TEMPLATE -const header = `\ -pragma solidity ^0.8.20; - -/** - * @dev Helper library packing and unpacking multiple values into bytesXX. - * - * Example usage: - * - * \`\`\`solidity - * library MyPacker { - * type MyType is bytes32; - * - * function _pack(address account, bytes4 selector, uint64 period) external pure returns (MyType) { - * bytes12 subpack = Packing.pack_4_8(selector, bytes8(period)); - * bytes32 pack = Packing.pack_20_12(bytes20(account), subpack); - * return MyType.wrap(pack); - * } - * - * function _unpack(MyType self) external pure returns (address, bytes4, uint64) { - * bytes32 pack = MyType.unwrap(self); - * return ( - * address(Packing.extract_32_20(pack, 0)), - * Packing.extract_32_4(pack, 20), - * uint64(Packing.extract_32_8(pack, 24)) - * ); - * } - * } - * \`\`\` - * - * _Available since v5.1._ - */ -// solhint-disable func-name-mixedcase -`; - -const errors = `\ -error OutOfRangeAccess(); -`; - -const pack = (left, right) => `\ -function pack_${left}_${right}(bytes${left} left, bytes${right} right) internal pure returns (bytes${ - left + right -} result) { - assembly ("memory-safe") { - left := ${sanitize.bytes('left', left)} - right := ${sanitize.bytes('right', right)} - result := or(left, shr(${8 * left}, right)) - } -} -`; - -const extract = (outer, inner) => `\ -function extract_${outer}_${inner}(bytes${outer} self, uint8 offset) internal pure returns (bytes${inner} result) { - if (offset > ${outer - inner}) revert OutOfRangeAccess(); - assembly ("memory-safe") { - result := ${sanitize.bytes('shl(mul(8, offset), self)', inner)} - } -} -`; - -const replace = (outer, inner) => `\ -function replace_${outer}_${inner}(bytes${outer} self, bytes${inner} value, uint8 offset) internal pure returns (bytes${outer} result) { - bytes${inner} oldValue = extract_${outer}_${inner}(self, offset); - assembly ("memory-safe") { - value := ${sanitize.bytes('value', inner)} - result := xor(self, shr(mul(8, offset), xor(oldValue, value))) - } -} -`; - -// GENERATE -module.exports = format( - header.trimEnd(), - 'library Packing {', - format( - [].concat( - errors, - product(SIZES, SIZES) - .filter(([left, right]) => SIZES.includes(left + right)) - .map(([left, right]) => pack(left, right)), - product(SIZES, SIZES) - .filter(([outer, inner]) => outer > inner) - .flatMap(([outer, inner]) => [extract(outer, inner), replace(outer, inner)]), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Packing.opts.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Packing.opts.js deleted file mode 100644 index 893ad6297c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Packing.opts.js +++ /dev/null @@ -1,3 +0,0 @@ -module.exports = { - SIZES: [1, 2, 4, 6, 8, 10, 12, 16, 20, 22, 24, 28, 32], -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Packing.t.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Packing.t.js deleted file mode 100644 index 1feec28f5a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Packing.t.js +++ /dev/null @@ -1,48 +0,0 @@ -const format = require('../format-lines'); -const { product } = require('../../helpers'); -const { SIZES } = require('./Packing.opts'); - -// TEMPLATE -const header = `\ -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {Packing} from "@openzeppelin/contracts/utils/Packing.sol"; -`; - -const testPack = (left, right) => `\ -function testPack(bytes${left} left, bytes${right} right) external pure { - assertEq(left, Packing.pack_${left}_${right}(left, right).extract_${left + right}_${left}(0)); - assertEq(right, Packing.pack_${left}_${right}(left, right).extract_${left + right}_${right}(${left})); -} -`; - -const testReplace = (outer, inner) => `\ -function testReplace(bytes${outer} container, bytes${inner} newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, ${outer - inner})); - - bytes${inner} oldValue = container.extract_${outer}_${inner}(offset); - - assertEq(newValue, container.replace_${outer}_${inner}(newValue, offset).extract_${outer}_${inner}(offset)); - assertEq(container, container.replace_${outer}_${inner}(newValue, offset).replace_${outer}_${inner}(oldValue, offset)); -} -`; - -// GENERATE -module.exports = format( - header, - 'contract PackingTest is Test {', - format( - [].concat( - 'using Packing for *;', - '', - product(SIZES, SIZES) - .filter(([left, right]) => SIZES.includes(left + right)) - .map(([left, right]) => testPack(left, right)), - product(SIZES, SIZES) - .filter(([outer, inner]) => outer > inner) - .map(([outer, inner]) => testReplace(outer, inner)), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/SafeCast.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/SafeCast.js deleted file mode 100644 index 21000cf4a6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/SafeCast.js +++ /dev/null @@ -1,136 +0,0 @@ -const format = require('../format-lines'); -const { range } = require('../../helpers'); - -const LENGTHS = range(8, 256, 8).reverse(); // 248 → 8 (in steps of 8) - -const header = `\ -pragma solidity ^0.8.20; - -/** - * @dev Wrappers over Solidity's uintXX/intXX/bool casting operators with added overflow - * checks. - * - * Downcasting from uint256/int256 in Solidity does not revert on overflow. This can - * easily result in undesired exploitation or bugs, since developers usually - * assume that overflows raise errors. \`SafeCast\` restores this intuition by - * reverting the transaction when such an operation overflows. - * - * Using this library instead of the unchecked operations eliminates an entire - * class of bugs, so it's recommended to use it always. - */ -`; - -const errors = `\ -/** - * @dev Value doesn't fit in an uint of \`bits\` size. - */ -error SafeCastOverflowedUintDowncast(uint8 bits, uint256 value); - -/** - * @dev An int value doesn't fit in an uint of \`bits\` size. - */ -error SafeCastOverflowedIntToUint(int256 value); - -/** - * @dev Value doesn't fit in an int of \`bits\` size. - */ -error SafeCastOverflowedIntDowncast(uint8 bits, int256 value); - -/** - * @dev An uint value doesn't fit in an int of \`bits\` size. - */ -error SafeCastOverflowedUintToInt(uint256 value); -`; - -const toUintDownCast = length => `\ -/** - * @dev Returns the downcasted uint${length} from uint256, reverting on - * overflow (when the input is greater than largest uint${length}). - * - * Counterpart to Solidity's \`uint${length}\` operator. - * - * Requirements: - * - * - input must fit into ${length} bits - */ -function toUint${length}(uint256 value) internal pure returns (uint${length}) { - if (value > type(uint${length}).max) { - revert SafeCastOverflowedUintDowncast(${length}, value); - } - return uint${length}(value); -} -`; - -const toIntDownCast = length => `\ -/** - * @dev Returns the downcasted int${length} from int256, reverting on - * overflow (when the input is less than smallest int${length} or - * greater than largest int${length}). - * - * Counterpart to Solidity's \`int${length}\` operator. - * - * Requirements: - * - * - input must fit into ${length} bits - */ -function toInt${length}(int256 value) internal pure returns (int${length} downcasted) { - downcasted = int${length}(value); - if (downcasted != value) { - revert SafeCastOverflowedIntDowncast(${length}, value); - } -} -`; - -const toInt = length => `\ -/** - * @dev Converts an unsigned uint${length} into a signed int${length}. - * - * Requirements: - * - * - input must be less than or equal to maxInt${length}. - */ -function toInt${length}(uint${length} value) internal pure returns (int${length}) { - // Note: Unsafe cast below is okay because \`type(int${length}).max\` is guaranteed to be positive - if (value > uint${length}(type(int${length}).max)) { - revert SafeCastOverflowedUintToInt(value); - } - return int${length}(value); -} -`; - -const toUint = length => `\ -/** - * @dev Converts a signed int${length} into an unsigned uint${length}. - * - * Requirements: - * - * - input must be greater than or equal to 0. - */ -function toUint${length}(int${length} value) internal pure returns (uint${length}) { - if (value < 0) { - revert SafeCastOverflowedIntToUint(value); - } - return uint${length}(value); -} -`; - -const boolToUint = `\ -/** - * @dev Cast a boolean (false or true) to a uint256 (0 or 1) with no jump. - */ -function toUint(bool b) internal pure returns (uint256 u) { - assembly ("memory-safe") { - u := iszero(iszero(b)) - } -} -`; - -// GENERATE -module.exports = format( - header.trimEnd(), - 'library SafeCast {', - format( - [].concat(errors, LENGTHS.map(toUintDownCast), toUint(256), LENGTHS.map(toIntDownCast), toInt(256), boolToUint), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Slot.opts.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Slot.opts.js deleted file mode 100644 index 3eca2bcf08..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/Slot.opts.js +++ /dev/null @@ -1,15 +0,0 @@ -const { capitalize } = require('../../helpers'); - -const TYPES = [ - { type: 'address', isValueType: true }, - { type: 'bool', isValueType: true, name: 'Boolean' }, - { type: 'bytes32', isValueType: true, variants: ['bytes4'] }, - { type: 'uint256', isValueType: true, variants: ['uint32'] }, - { type: 'int256', isValueType: true, variants: ['int32'] }, - { type: 'string', isValueType: false }, - { type: 'bytes', isValueType: false }, -].map(type => Object.assign(type, { name: type.name ?? capitalize(type.type) })); - -Object.assign(TYPES, Object.fromEntries(TYPES.map(entry => [entry.type, entry]))); - -module.exports = { TYPES }; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/SlotDerivation.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/SlotDerivation.js deleted file mode 100644 index ec4d244b93..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/SlotDerivation.js +++ /dev/null @@ -1,119 +0,0 @@ -const format = require('../format-lines'); -const sanitize = require('../helpers/sanitize'); -const { TYPES } = require('./Slot.opts'); - -const header = `\ -pragma solidity ^0.8.20; - -/** - * @dev Library for computing storage (and transient storage) locations from namespaces and deriving slots - * corresponding to standard patterns. The derivation method for array and mapping matches the storage layout used by - * the solidity language / compiler. - * - * See https://docs.soliditylang.org/en/v0.8.20/internals/layout_in_storage.html#mappings-and-dynamic-arrays[Solidity docs for mappings and dynamic arrays.]. - * - * Example usage: - * \`\`\`solidity - * contract Example { - * // Add the library methods - * using StorageSlot for bytes32; - * using SlotDerivation for bytes32; - * - * // Declare a namespace - * string private constant _NAMESPACE = "" // eg. OpenZeppelin.Slot - * - * function setValueInNamespace(uint256 key, address newValue) internal { - * _NAMESPACE.erc7201Slot().deriveMapping(key).getAddressSlot().value = newValue; - * } - * - * function getValueInNamespace(uint256 key) internal view returns (address) { - * return _NAMESPACE.erc7201Slot().deriveMapping(key).getAddressSlot().value; - * } - * } - * \`\`\` - * - * TIP: Consider using this library along with {StorageSlot}. - * - * NOTE: This library provides a way to manipulate storage locations in a non-standard way. Tooling for checking - * upgrade safety will ignore the slots accessed through this library. - * - * _Available since v5.1._ - */ -`; - -const namespace = `\ -/** - * @dev Derive an ERC-7201 slot from a string (namespace). - */ -function erc7201Slot(string memory namespace) internal pure returns (bytes32 slot) { - assembly ("memory-safe") { - mstore(0x00, sub(keccak256(add(namespace, 0x20), mload(namespace)), 1)) - slot := and(keccak256(0x00, 0x20), not(0xff)) - } -} -`; - -const array = `\ -/** - * @dev Add an offset to a slot to get the n-th element of a structure or an array. - */ -function offset(bytes32 slot, uint256 pos) internal pure returns (bytes32 result) { - unchecked { - return bytes32(uint256(slot) + pos); - } -} - -/** - * @dev Derive the location of the first element in an array from the slot where the length is stored. - */ -function deriveArray(bytes32 slot) internal pure returns (bytes32 result) { - assembly ("memory-safe") { - mstore(0x00, slot) - result := keccak256(0x00, 0x20) - } -} -`; - -const mapping = ({ type }) => `\ -/** - * @dev Derive the location of a mapping element from the key. - */ -function deriveMapping(bytes32 slot, ${type} key) internal pure returns (bytes32 result) { - assembly ("memory-safe") { - mstore(0x00, ${(sanitize[type] ?? (x => x))('key')}) - mstore(0x20, slot) - result := keccak256(0x00, 0x40) - } -} -`; - -const mapping2 = ({ type }) => `\ -/** - * @dev Derive the location of a mapping element from the key. - */ -function deriveMapping(bytes32 slot, ${type} memory key) internal pure returns (bytes32 result) { - assembly ("memory-safe") { - let length := mload(key) - let begin := add(key, 0x20) - let end := add(begin, length) - let cache := mload(end) - mstore(end, slot) - result := keccak256(begin, add(length, 0x20)) - mstore(end, cache) - } -} -`; - -// GENERATE -module.exports = format( - header.trimEnd(), - 'library SlotDerivation {', - format( - [].concat( - namespace, - array, - TYPES.map(type => (type.isValueType ? mapping(type) : mapping2(type))), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/SlotDerivation.t.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/SlotDerivation.t.js deleted file mode 100644 index f03e1fc259..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/SlotDerivation.t.js +++ /dev/null @@ -1,127 +0,0 @@ -const format = require('../format-lines'); -const { capitalize } = require('../../helpers'); -const { TYPES } = require('./Slot.opts'); - -const header = `\ -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {SymTest} from "halmos-cheatcodes/SymTest.sol"; -import {SlotDerivation} from "@openzeppelin/contracts/utils/SlotDerivation.sol"; -`; - -const array = `\ -bytes[] private _array; - -function symbolicDeriveArray(uint256 length, uint256 offset) public { - vm.assume(length > 0); - vm.assume(offset < length); - _assertDeriveArray(length, offset); -} - -function testDeriveArray(uint256 length, uint256 offset) public { - length = bound(length, 1, type(uint256).max); - offset = bound(offset, 0, length - 1); - _assertDeriveArray(length, offset); -} - -function _assertDeriveArray(uint256 length, uint256 offset) public { - bytes32 baseSlot; - assembly { - baseSlot := _array.slot - sstore(baseSlot, length) // store length so solidity access does not revert - } - - bytes storage derived = _array[offset]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveArray().offset(offset), derivedSlot); -} -`; - -const mapping = ({ type, name }) => `\ -mapping(${type} => bytes) private _${type}Mapping; - -function testSymbolicDeriveMapping${name}(${type} key) public { - bytes32 baseSlot; - assembly { - baseSlot := _${type}Mapping.slot - } - - bytes storage derived = _${type}Mapping[key]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveMapping(key), derivedSlot); -} -`; - -const mappingDirty = ({ type, name }) => `\ -function testSymbolicDeriveMapping${name}Dirty(bytes32 dirtyKey) public { - ${type} key; - assembly { - key := dirtyKey - } - - // run the "normal" test using a potentially dirty value - testSymbolicDeriveMapping${name}(key); -} -`; - -const boundedMapping = ({ type, name }) => `\ -mapping(${type} => bytes) private _${type}Mapping; - -function testDeriveMapping${name}(${type} memory key) public { - _assertDeriveMapping${name}(key); -} - -function symbolicDeriveMapping${name}() public { - _assertDeriveMapping${name}(svm.create${name}(256, "DeriveMapping${name}Input")); -} - -function _assertDeriveMapping${name}(${type} memory key) internal { - bytes32 baseSlot; - assembly { - baseSlot := _${type}Mapping.slot - } - - bytes storage derived = _${type}Mapping[key]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveMapping(key), derivedSlot); -} -`; - -// GENERATE -module.exports = format( - header, - 'contract SlotDerivationTest is Test, SymTest {', - format( - [].concat( - 'using SlotDerivation for bytes32;', - '', - array, - TYPES.flatMap(type => - [].concat( - type, - (type.variants ?? []).map(variant => ({ - type: variant, - name: capitalize(variant), - isValueType: type.isValueType, - })), - ), - ).map(type => (type.isValueType ? mapping(type) : boundedMapping(type))), - mappingDirty(TYPES.bool), - mappingDirty(TYPES.address), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/StorageSlot.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/StorageSlot.js deleted file mode 100644 index 53287b81fd..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/StorageSlot.js +++ /dev/null @@ -1,77 +0,0 @@ -const format = require('../format-lines'); -const { TYPES } = require('./Slot.opts'); - -const header = `\ -pragma solidity ^0.8.20; - -/** - * @dev Library for reading and writing primitive types to specific storage slots. - * - * Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts. - * This library helps with reading and writing to such slots without the need for inline assembly. - * - * The functions in this library return Slot structs that contain a \`value\` member that can be used to read or write. - * - * Example usage to set ERC-1967 implementation slot: - * \`\`\`solidity - * contract ERC1967 { - * // Define the slot. Alternatively, use the SlotDerivation library to derive the slot. - * bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc; - * - * function _getImplementation() internal view returns (address) { - * return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value; - * } - * - * function _setImplementation(address newImplementation) internal { - * require(newImplementation.code.length > 0); - * StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation; - * } - * } - * \`\`\` - * - * TIP: Consider using this library along with {SlotDerivation}. - */ -`; - -const struct = ({ type, name }) => `\ -struct ${name}Slot { - ${type} value; -} -`; - -const get = ({ name }) => `\ -/** - * @dev Returns ${ - name.toLowerCase().startsWith('a') ? 'an' : 'a' - } \`${name}Slot\` with member \`value\` located at \`slot\`. - */ -function get${name}Slot(bytes32 slot) internal pure returns (${name}Slot storage r) { - assembly ("memory-safe") { - r.slot := slot - } -} -`; - -const getStorage = ({ type, name }) => `\ -/** - * @dev Returns an \`${name}Slot\` representation of the ${type} storage pointer \`store\`. - */ -function get${name}Slot(${type} storage store) internal pure returns (${name}Slot storage r) { - assembly ("memory-safe") { - r.slot := store.slot - } -} -`; - -// GENERATE -module.exports = format( - header.trimEnd(), - 'library StorageSlot {', - format( - [].concat( - TYPES.map(type => struct(type)), - TYPES.flatMap(type => [get(type), !type.isValueType && getStorage(type)].filter(Boolean)), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/StorageSlotMock.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/StorageSlotMock.js deleted file mode 100644 index c6d326a5e2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/StorageSlotMock.js +++ /dev/null @@ -1,57 +0,0 @@ -const format = require('../format-lines'); -const { TYPES } = require('./Slot.opts'); - -const header = `\ -pragma solidity ^0.8.20; - -import {Multicall} from "../utils/Multicall.sol"; -import {StorageSlot} from "../utils/StorageSlot.sol"; -`; - -const storageSetValueType = ({ type, name }) => `\ -function set${name}Slot(bytes32 slot, ${type} value) public { - slot.get${name}Slot().value = value; -} -`; - -const storageGetValueType = ({ type, name }) => `\ -function get${name}Slot(bytes32 slot) public view returns (${type}) { - return slot.get${name}Slot().value; -} -`; - -const storageSetNonValueType = ({ type, name }) => `\ -mapping(uint256 key => ${type}) public ${type}Map; - -function set${name}Slot(bytes32 slot, ${type} calldata value) public { - slot.get${name}Slot().value = value; -} - -function set${name}Storage(uint256 key, ${type} calldata value) public { - ${type}Map[key].get${name}Slot().value = value; -} - -function get${name}Slot(bytes32 slot) public view returns (${type} memory) { - return slot.get${name}Slot().value; -} - -function get${name}Storage(uint256 key) public view returns (${type} memory) { - return ${type}Map[key].get${name}Slot().value; -} -`; - -// GENERATE -module.exports = format( - header, - 'contract StorageSlotMock is Multicall {', - format( - [].concat( - 'using StorageSlot for *;', - '', - TYPES.filter(type => type.isValueType).map(type => storageSetValueType(type)), - TYPES.filter(type => type.isValueType).map(type => storageGetValueType(type)), - TYPES.filter(type => !type.isValueType).map(type => storageSetNonValueType(type)), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/TransientSlot.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/TransientSlot.js deleted file mode 100644 index 8e291bc13d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/TransientSlot.js +++ /dev/null @@ -1,80 +0,0 @@ -const format = require('../format-lines'); -const { TYPES } = require('./Slot.opts'); - -const header = `\ -pragma solidity ^0.8.24; - -/** - * @dev Library for reading and writing value-types to specific transient storage slots. - * - * Transient slots are often used to store temporary values that are removed after the current transaction. - * This library helps with reading and writing to such slots without the need for inline assembly. - * - * * Example reading and writing values using transient storage: - * \`\`\`solidity - * contract Lock { - * using TransientSlot for *; - * - * // Define the slot. Alternatively, use the SlotDerivation library to derive the slot. - * bytes32 internal constant _LOCK_SLOT = 0xf4678858b2b588224636b8522b729e7722d32fc491da849ed75b3fdf3c84f542; - * - * modifier locked() { - * require(!_LOCK_SLOT.asBoolean().tload()); - * - * _LOCK_SLOT.asBoolean().tstore(true); - * _; - * _LOCK_SLOT.asBoolean().tstore(false); - * } - * } - * \`\`\` - * - * TIP: Consider using this library along with {SlotDerivation}. - */ -`; - -const udvt = ({ type, name }) => `\ -/** - * @dev UDVT that represent a slot holding a ${type}. - */ -type ${name}Slot is bytes32; - -/** - * @dev Cast an arbitrary slot to a ${name}Slot. - */ -function as${name}(bytes32 slot) internal pure returns (${name}Slot) { - return ${name}Slot.wrap(slot); -} -`; - -const transient = ({ type, name }) => `\ -/** - * @dev Load the value held at location \`slot\` in transient storage. - */ -function tload(${name}Slot slot) internal view returns (${type} value) { - assembly ("memory-safe") { - value := tload(slot) - } -} - -/** - * @dev Store \`value\` at location \`slot\` in transient storage. - */ -function tstore(${name}Slot slot, ${type} value) internal { - assembly ("memory-safe") { - tstore(slot, value) - } -} -`; - -// GENERATE -module.exports = format( - header.trimEnd(), - 'library TransientSlot {', - format( - [].concat( - TYPES.filter(type => type.isValueType).map(type => udvt(type)), - TYPES.filter(type => type.isValueType).map(type => transient(type)), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/TransientSlotMock.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/TransientSlotMock.js deleted file mode 100644 index 4807b0cc1f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/TransientSlotMock.js +++ /dev/null @@ -1,35 +0,0 @@ -const format = require('../format-lines'); -const { TYPES } = require('./Slot.opts'); - -const header = `\ -pragma solidity ^0.8.24; - -import {Multicall} from "../utils/Multicall.sol"; -import {TransientSlot} from "../utils/TransientSlot.sol"; -`; - -const transient = ({ type, name }) => `\ -event ${name}Value(bytes32 slot, ${type} value); - -function tload${name}(bytes32 slot) public { - emit ${name}Value(slot, slot.as${name}().tload()); -} - -function tstore(bytes32 slot, ${type} value) public { - slot.as${name}().tstore(value); -} -`; - -// GENERATE -module.exports = format( - header, - 'contract TransientSlotMock is Multicall {', - format( - [].concat( - 'using TransientSlot for *;', - '', - TYPES.filter(type => type.isValueType).map(type => transient(type)), - ), - ).trimEnd(), - '}', -); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/conversion.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/conversion.js deleted file mode 100644 index 9221f7c21c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/generate/templates/conversion.js +++ /dev/null @@ -1,30 +0,0 @@ -function toBytes32(type, value) { - switch (type) { - case 'bytes32': - return value; - case 'uint256': - return `bytes32(${value})`; - case 'address': - return `bytes32(uint256(uint160(${value})))`; - default: - throw new Error(`Conversion from ${type} to bytes32 not supported`); - } -} - -function fromBytes32(type, value) { - switch (type) { - case 'bytes32': - return value; - case 'uint256': - return `uint256(${value})`; - case 'address': - return `address(uint160(uint256(${value})))`; - default: - throw new Error(`Conversion from bytes32 to ${type} not supported`); - } -} - -module.exports = { - toBytes32, - fromBytes32, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/git-user-config.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/git-user-config.sh deleted file mode 100644 index e7b81c3eb3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/git-user-config.sh +++ /dev/null @@ -1,6 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail -x - -git config user.name 'github-actions' -git config user.email '41898282+github-actions[bot]@users.noreply.github.com' diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/helpers.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/helpers.js deleted file mode 100644 index d28c0866d1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/helpers.js +++ /dev/null @@ -1,7 +0,0 @@ -const iterate = require('../test/helpers/iterate'); -const strings = require('../test/helpers/strings'); - -module.exports = { - ...iterate, - ...strings, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/prepack.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/prepack.sh deleted file mode 100644 index 6af10329f6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/prepack.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail -shopt -s globstar - -# cross platform `mkdir -p` -mkdirp() { - node -e "fs.mkdirSync('$1', { recursive: true })" -} - -# cd to the root of the repo -cd "$(git rev-parse --show-toplevel)" - -npm run clean - -env COMPILE_MODE=production npm run compile - -mkdirp contracts/build/contracts -cp artifacts/contracts/**/*.json contracts/build/contracts -rm contracts/build/contracts/*.dbg.json -node scripts/remove-ignored-artifacts.js - -cp README.md contracts/ diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/prepare-docs.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/prepare-docs.sh deleted file mode 100644 index d1317b0928..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/prepare-docs.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail -shopt -s globstar - -OUTDIR="$(node -p 'require("./docs/config.js").outputDir')" - -if [ ! -d node_modules ]; then - npm ci -fi - -rm -rf "$OUTDIR" - -hardhat docgen - -# copy examples and adjust imports -examples_source_dir="contracts/mocks/docs" -examples_target_dir="docs/modules/api/examples" - -for f in "$examples_source_dir"/**/*.sol; do - name="${f/#"$examples_source_dir/"/}" - mkdir -p "$examples_target_dir/$(dirname "$name")" - sed -Ee '/^import/s|"(\.\./)+|"@openzeppelin/contracts/|' "$f" > "$examples_target_dir/$name" -done - -node scripts/gen-nav.js "$OUTDIR" > "$OUTDIR/../nav.adoc" diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/prepare.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/prepare.sh deleted file mode 100644 index a7d74227d2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/prepare.sh +++ /dev/null @@ -1,5 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -if git status &>/dev/null; then git config core.hooksPath .githooks; fi diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/format-changelog.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/format-changelog.js deleted file mode 100644 index b8bcc8c711..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/format-changelog.js +++ /dev/null @@ -1,33 +0,0 @@ -#!/usr/bin/env node - -// Adjusts the format of the changelog that changesets generates. -// This is run automatically when npm version is run. - -const fs = require('fs'); -const changelog = fs.readFileSync('CHANGELOG.md', 'utf8'); - -// Groups: -// - 1: Pull Request Number and URL -// - 2: Changeset entry -const RELEASE_LINE_REGEX = /^- (\[#.*?\]\(.*?\))?.*?! - (.*)$/gm; - -// Captures vX.Y.Z or vX.Y.Z-rc.W -const VERSION_TITLE_REGEX = /^## (\d+\.\d+\.\d+(-rc\.\d+)?)$/gm; - -const isPrerelease = process.env.PRERELEASE === 'true'; - -const formatted = changelog - // Remove titles - .replace(/^### Major Changes\n\n/gm, '') - .replace(/^### Minor Changes\n\n/gm, '') - .replace(/^### Patch Changes\n\n/gm, '') - // Remove extra whitespace between items - .replace(/^(- \[.*\n)\n(?=-)/gm, '$1') - // Format each release line - .replace(RELEASE_LINE_REGEX, (_, pr, entry) => (pr ? `- ${entry} (${pr})` : `- ${entry}`)) - // Add date to new version - .replace(VERSION_TITLE_REGEX, `\n## $1 (${new Date().toISOString().split('T')[0]})`) - // Conditionally allow vX.Y.Z.rc-.W sections only in prerelease - .replace(/^## \d\.\d\.\d-rc\S+[^]+?(?=^#)/gm, section => (isPrerelease ? section : '')); - -fs.writeFileSync('CHANGELOG.md', formatted); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/synchronize-versions.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/synchronize-versions.js deleted file mode 100644 index 15aa259937..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/synchronize-versions.js +++ /dev/null @@ -1,15 +0,0 @@ -#!/usr/bin/env node - -// Synchronizes the version in contracts/package.json with the one in package.json. -// This is run automatically when npm version is run. - -const fs = require('fs'); - -setVersion('package.json', 'contracts/package.json'); - -function setVersion(from, to) { - const fromJson = JSON.parse(fs.readFileSync(from)); - const toJson = JSON.parse(fs.readFileSync(to)); - toJson.version = fromJson.version; - fs.writeFileSync(to, JSON.stringify(toJson, null, 2) + '\n'); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/update-comment.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/update-comment.js deleted file mode 100644 index 9d6df26945..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/update-comment.js +++ /dev/null @@ -1,34 +0,0 @@ -#!/usr/bin/env node -const fs = require('fs'); -const proc = require('child_process'); -const semver = require('semver'); -const run = (cmd, ...args) => proc.execFileSync(cmd, args, { encoding: 'utf8' }).trim(); - -const gitStatus = run('git', 'status', '--porcelain', '-uno', 'contracts/**/*.sol'); -if (gitStatus.length > 0) { - console.error('Contracts directory is not clean'); - process.exit(1); -} - -const { version } = require('../../package.json'); - -// Get latest tag according to semver. -const [tag] = run('git', 'tag') - .split(/\r?\n/) - .filter(semver.coerce) // check version can be processed - .filter(v => semver.satisfies(v, `< ${version}`)) // ignores prereleases unless currently a prerelease - .sort(semver.rcompare); - -// Ordering tag → HEAD is important here. -const files = run('git', 'diff', tag, 'HEAD', '--name-only', 'contracts/**/*.sol') - .split(/\r?\n/) - .filter(file => file && !file.match(/mock/i) && fs.existsSync(file)); - -for (const file of files) { - const current = fs.readFileSync(file, 'utf8'); - const updated = current.replace( - /(\/\/ SPDX-License-Identifier:.*)$(\n\/\/ OpenZeppelin Contracts .*$)?/m, - `$1\n// OpenZeppelin Contracts (last updated v${version}) (${file.replace('contracts/', '')})`, - ); - fs.writeFileSync(file, updated); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/version.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/version.sh deleted file mode 100644 index 7b0ddead3e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/version.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -changeset version - -scripts/release/format-changelog.js -scripts/release/synchronize-versions.js -scripts/release/update-comment.js - -oz-docs update-version diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/exit-prerelease.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/exit-prerelease.sh deleted file mode 100644 index bcf9b9ae9f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/exit-prerelease.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -npx changeset pre exit rc -git add . -git commit -m "Exit release candidate" -git push origin diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/github-release.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/github-release.js deleted file mode 100644 index f213106b8a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/github-release.js +++ /dev/null @@ -1,48 +0,0 @@ -const { readFileSync } = require('fs'); -const { join } = require('path'); -const { version } = require(join(__dirname, '../../../package.json')); - -module.exports = async ({ github, context }) => { - const changelog = readFileSync('CHANGELOG.md', 'utf8'); - - await github.rest.repos.createRelease({ - owner: context.repo.owner, - repo: context.repo.repo, - tag_name: `v${version}`, - target_commitish: github.ref_name, - body: extractSection(changelog, version), - prerelease: process.env.PRERELEASE === 'true', - }); -}; - -// From https://github.com/frangio/extract-changelog/blob/master/src/utils/word-regexp.ts -function makeWordRegExp(word) { - const start = word.length > 0 && /\b/.test(word[0]) ? '\\b' : ''; - const end = word.length > 0 && /\b/.test(word[word.length - 1]) ? '\\b' : ''; - return new RegExp(start + [...word].map(c => (/[a-z0-9]/i.test(c) ? c : '\\' + c)).join('') + end); -} - -// From https://github.com/frangio/extract-changelog/blob/master/src/core.ts -function extractSection(document, wantedHeading) { - // ATX Headings as defined in GitHub Flavored Markdown (https://github.github.com/gfm/#atx-headings) - const heading = /^ {0,3}(?#{1,6})(?: [ \t\v\f]*(?.*?)[ \t\v\f]*)?(?:[\n\r]+|$)/gm; - - const wantedHeadingRe = makeWordRegExp(wantedHeading); - - let start, end; - - for (const m of document.matchAll(heading)) { - if (!start) { - if (m.groups.text.search(wantedHeadingRe) === 0) { - start = m; - } - } else if (m.groups.lead.length <= start.groups.lead.length) { - end = m; - break; - } - } - - if (start) { - return document.slice(start.index + start[0].length, end?.index); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/integrity-check.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/integrity-check.sh deleted file mode 100644 index 86e99f9291..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/integrity-check.sh +++ /dev/null @@ -1,20 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -CHECKSUMS="$RUNNER_TEMP/checksums.txt" - -# Extract tarball content into a tmp directory -tar xf "$TARBALL" -C "$RUNNER_TEMP" - -# Move to extracted directory -cd "$RUNNER_TEMP/package" - -# Checksum all Solidity files -find . -type f -name "*.sol" | xargs shasum > "$CHECKSUMS" - -# Back to directory with git contents -cd "$GITHUB_WORKSPACE/contracts" - -# Check against tarball contents -shasum -c "$CHECKSUMS" diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/pack.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/pack.sh deleted file mode 100644 index ce30712f80..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/pack.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -dist_tag() { - PACKAGE_JSON_NAME="$(jq -r .name ./package.json)" - LATEST_NPM_VERSION="$(npm info "$PACKAGE_JSON_NAME" version)" - PACKAGE_JSON_VERSION="$(jq -r .version ./package.json)" - - if [ "$PRERELEASE" = "true" ]; then - echo "next" - elif npx semver -r ">$LATEST_NPM_VERSION" "$PACKAGE_JSON_VERSION" > /dev/null; then - echo "latest" - else - # This is a patch for an older version - # npm can't publish without a tag - echo "tmp" - fi -} - -cd contracts -TARBALL="$(npm pack | tee /dev/stderr | tail -1)" -echo "tarball_name=$TARBALL" >> $GITHUB_OUTPUT -echo "tarball=$(pwd)/$TARBALL" >> $GITHUB_OUTPUT -echo "tag=$(dist_tag)" >> $GITHUB_OUTPUT -cd .. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/publish.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/publish.sh deleted file mode 100644 index e490e5d007..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/publish.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -PACKAGE_JSON_NAME="$(tar xfO "$TARBALL" package/package.json | jq -r .name)" -PACKAGE_JSON_VERSION="$(tar xfO "$TARBALL" package/package.json | jq -r .version)" - -# Intentionally escape $ to avoid interpolation and writing the token to disk -echo "//registry.npmjs.org/:_authToken=\${NPM_TOKEN}" > .npmrc - -# Actual publish -npm publish "$TARBALL" --tag "$TAG" - -# Clean up tags -delete_tag() { - npm dist-tag rm "$PACKAGE_JSON_NAME" "$1" -} - -if [ "$TAG" = tmp ]; then - delete_tag "$TAG" -elif [ "$TAG" = latest ]; then - # Delete the next tag if it exists and is a prerelease for what is currently being published - if npm dist-tag ls "$PACKAGE_JSON_NAME" | grep -q "next: $PACKAGE_JSON_VERSION"; then - delete_tag next - fi -fi diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/rerun.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/rerun.js deleted file mode 100644 index f48ce6ea22..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/rerun.js +++ /dev/null @@ -1,7 +0,0 @@ -module.exports = ({ github, context }) => - github.rest.actions.createWorkflowDispatch({ - owner: context.repo.owner, - repo: context.repo.repo, - workflow_id: 'release-cycle.yml', - ref: process.env.REF || process.env.GITHUB_REF_NAME, - }); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/set-changesets-pr-title.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/set-changesets-pr-title.js deleted file mode 100644 index 59b03b22a8..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/set-changesets-pr-title.js +++ /dev/null @@ -1,17 +0,0 @@ -const { coerce, inc, rsort } = require('semver'); -const { join } = require('path'); -const { version } = require(join(__dirname, '../../../package.json')); - -module.exports = async ({ core }) => { - // Variables not in the context - const refName = process.env.GITHUB_REF_NAME; - - // Compare package.json version's next patch vs. first version patch - // A recently opened branch will give the next patch for the previous minor - // So, we get the max against the patch 0 of the release branch's version - const branchPatch0 = coerce(refName.replace('release-v', '')).version; - const packageJsonNextPatch = inc(version, 'patch'); - const [nextVersion] = rsort([branchPatch0, packageJsonNextPatch], false); - - core.exportVariable('TITLE', `Release v${nextVersion}`); -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/start.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/start.sh deleted file mode 100644 index 7683ec5bcf..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/start.sh +++ /dev/null @@ -1,35 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -# Set changeset status location -# This is needed because `changeset status --output` only works with relative routes -CHANGESETS_STATUS_JSON="$(realpath --relative-to=. "$RUNNER_TEMP/status.json")" - -# Save changeset status to temp file -npx changeset status --output="$CHANGESETS_STATUS_JSON" - -# Defensive assertion. SHOULD NOT BE REACHED -if [ "$(jq '.releases | length' "$CHANGESETS_STATUS_JSON")" != 1 ]; then - echo "::error file=$CHANGESETS_STATUS_JSON::The status doesn't contain only 1 release" - exit 1; -fi; - -# Create branch -BRANCH_SUFFIX="$(jq -r '.releases[0].newVersion | gsub("\\.\\d+$"; "")' $CHANGESETS_STATUS_JSON)" -RELEASE_BRANCH="release-v$BRANCH_SUFFIX" -git checkout -b "$RELEASE_BRANCH" - -# Output branch -echo "branch=$RELEASE_BRANCH" >> $GITHUB_OUTPUT - -# Enter in prerelease state -npx changeset pre enter rc -git add . -git commit -m "Start release candidate" - -# Push branch -if ! git push origin "$RELEASE_BRANCH"; then - echo "::error file=scripts/release/start.sh::Can't push $RELEASE_BRANCH. Did you forget to run this workflow from $RELEASE_BRANCH?" - exit 1 -fi diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/state.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/state.js deleted file mode 100644 index 002f7774d4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/release/workflow/state.js +++ /dev/null @@ -1,112 +0,0 @@ -const { readPreState } = require('@changesets/pre'); -const { default: readChangesets } = require('@changesets/read'); -const { join } = require('path'); -const { fetch } = require('undici'); -const { version, name: packageName } = require(join(__dirname, '../../../contracts/package.json')); - -module.exports = async ({ github, context, core }) => { - const state = await getState({ github, context, core }); - - function setOutput(key, value) { - core.info(`State ${key} = ${value}`); - core.setOutput(key, value); - } - - // Jobs to trigger - setOutput('start', shouldRunStart(state)); - setOutput('promote', shouldRunPromote(state)); - setOutput('changesets', shouldRunChangesets(state)); - setOutput('publish', shouldRunPublish(state)); - setOutput('merge', shouldRunMerge(state)); - - // Global Variables - setOutput('is_prerelease', state.prerelease); -}; - -function shouldRunStart({ isMaster, isWorkflowDispatch, botRun }) { - return isMaster && isWorkflowDispatch && !botRun; -} - -function shouldRunPromote({ isReleaseBranch, isWorkflowDispatch, botRun }) { - return isReleaseBranch && isWorkflowDispatch && !botRun; -} - -function shouldRunChangesets({ isReleaseBranch, isPush, isWorkflowDispatch, botRun }) { - return (isReleaseBranch && isPush) || (isReleaseBranch && isWorkflowDispatch && botRun); -} - -function shouldRunPublish({ isReleaseBranch, isPush, hasPendingChangesets, isPublishedOnNpm }) { - return isReleaseBranch && isPush && !hasPendingChangesets && !isPublishedOnNpm; -} - -function shouldRunMerge({ - isReleaseBranch, - isPush, - prerelease, - isCurrentFinalVersion, - hasPendingChangesets, - prBackExists, -}) { - return isReleaseBranch && isPush && !prerelease && isCurrentFinalVersion && !hasPendingChangesets && !prBackExists; -} - -async function getState({ github, context, core }) { - // Variables not in the context - const refName = process.env.GITHUB_REF_NAME; - const botRun = process.env.TRIGGERING_ACTOR === 'github-actions[bot]'; - - const { changesets, preState } = await readChangesetState(); - - // Static vars - const state = { - refName, - hasPendingChangesets: changesets.length > 0, - prerelease: preState?.mode === 'pre', - isMaster: refName === 'master', - isReleaseBranch: refName.startsWith('release-v'), - isWorkflowDispatch: context.eventName === 'workflow_dispatch', - isPush: context.eventName === 'push', - isCurrentFinalVersion: !version.includes('-rc.'), - botRun, - }; - - // Async vars - const { data: prs } = await github.rest.pulls.list({ - owner: context.repo.owner, - repo: context.repo.repo, - head: `${context.repo.owner}:merge/${state.refName}`, - base: 'master', - state: 'open', - }); - - state.prBackExists = prs.length !== 0; - - state.isPublishedOnNpm = await isPublishedOnNpm(packageName, version); - - // Log every state value in debug mode - if (core.isDebug()) for (const [key, value] of Object.entries(state)) core.debug(`${key}: ${value}`); - - return state; -} - -// From https://github.com/changesets/action/blob/v1.4.1/src/readChangesetState.ts -async function readChangesetState(cwd = process.cwd()) { - const preState = await readPreState(cwd); - const isInPreMode = preState !== undefined && preState.mode === 'pre'; - - let changesets = await readChangesets(cwd); - - if (isInPreMode) { - changesets = changesets.filter(x => !preState.changesets.includes(x.id)); - } - - return { - preState: isInPreMode ? preState : undefined, - changesets, - }; -} - -async function isPublishedOnNpm(packageName, version) { - const res = await fetch(`https://registry.npmjs.com/${packageName}/${version}`); - return res.ok; -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/remove-ignored-artifacts.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/remove-ignored-artifacts.js deleted file mode 100644 index e156032b17..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/remove-ignored-artifacts.js +++ /dev/null @@ -1,45 +0,0 @@ -#!/usr/bin/env node - -// This script removes the build artifacts of ignored contracts. - -const fs = require('fs'); -const path = require('path'); -const match = require('micromatch'); - -function readJSON(path) { - return JSON.parse(fs.readFileSync(path)); -} - -const pkgFiles = readJSON('package.json').files; - -// Get only negated patterns. -const ignorePatterns = pkgFiles - .filter(pat => pat.startsWith('!')) - // Remove the negation part. Makes micromatch usage more intuitive. - .map(pat => pat.slice(1)); - -const ignorePatternsSubtrees = ignorePatterns - // Add **/* to ignore all files contained in the directories. - .concat(ignorePatterns.map(pat => path.join(pat, '**/*'))) - .map(p => p.replace(/^\//, '')); - -const artifactsDir = 'contracts/build/contracts'; -const buildinfo = 'artifacts/build-info'; -const filenames = fs.readdirSync(buildinfo); - -let n = 0; - -for (const filename of filenames) { - const solcOutput = readJSON(path.join(buildinfo, filename)).output; - for (const sourcePath in solcOutput.contracts) { - const ignore = match.any(sourcePath, ignorePatternsSubtrees); - if (ignore) { - for (const contract in solcOutput.contracts[sourcePath]) { - fs.unlinkSync(path.join(artifactsDir, contract + '.json')); - n += 1; - } - } - } -} - -console.error(`Removed ${n} mock artifacts`); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/solhint-custom/index.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/solhint-custom/index.js deleted file mode 100644 index 9625027eef..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/solhint-custom/index.js +++ /dev/null @@ -1,84 +0,0 @@ -const path = require('path'); -const minimatch = require('minimatch'); - -// Files matching these patterns will be ignored unless a rule has `static global = true` -const ignore = ['contracts/mocks/**/*', 'test/**/*']; - -class Base { - constructor(reporter, config, source, fileName) { - this.reporter = reporter; - this.ignored = this.constructor.global || ignore.some(p => minimatch(path.normalize(fileName), p)); - this.ruleId = this.constructor.ruleId; - if (this.ruleId === undefined) { - throw Error('missing ruleId static property'); - } - } - - error(node, message) { - if (!this.ignored) { - this.reporter.error(node, this.ruleId, message); - } - } -} - -module.exports = [ - class extends Base { - static ruleId = 'interface-names'; - - ContractDefinition(node) { - if (node.kind === 'interface' && !/^I[A-Z]/.test(node.name)) { - this.error(node, 'Interface names should have a capital I prefix'); - } - } - }, - - class extends Base { - static ruleId = 'private-variables'; - - VariableDeclaration(node) { - const constantOrImmutable = node.isDeclaredConst || node.isImmutable; - if (node.isStateVar && !constantOrImmutable && node.visibility !== 'private') { - this.error(node, 'State variables must be private'); - } - } - }, - - class extends Base { - static ruleId = 'leading-underscore'; - - VariableDeclaration(node) { - if (node.isDeclaredConst) { - // TODO: expand visibility and fix - if (node.visibility === 'private' && /^_/.test(node.name)) { - this.error(node, 'Constant variables should not have leading underscore'); - } - } else if (node.visibility === 'private' && !/^_/.test(node.name)) { - this.error(node, 'Non-constant private variables must have leading underscore'); - } - } - - FunctionDefinition(node) { - if (node.visibility === 'private' || (node.visibility === 'internal' && node.parent.kind !== 'library')) { - if (!/^_/.test(node.name)) { - this.error(node, 'Private and internal functions must have leading underscore'); - } - } - if (node.visibility === 'internal' && node.parent.kind === 'library') { - if (/^_/.test(node.name)) { - this.error(node, 'Library internal functions should not have leading underscore'); - } - } - } - }, - - // TODO: re-enable and fix - // class extends Base { - // static ruleId = 'no-external-virtual'; - // - // FunctionDefinition(node) { - // if (node.visibility == 'external' && node.isVirtual) { - // this.error(node, 'Functions should not be external and virtual'); - // } - // } - // }, -]; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/solhint-custom/package.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/solhint-custom/package.json deleted file mode 100644 index 075eb929de..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/solhint-custom/package.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "name": "solhint-plugin-openzeppelin", - "version": "0.0.0", - "private": true -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/update-docs-branch.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/update-docs-branch.js deleted file mode 100644 index cf61daad83..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/update-docs-branch.js +++ /dev/null @@ -1,65 +0,0 @@ -const proc = require('child_process'); -const read = cmd => proc.execSync(cmd, { encoding: 'utf8' }).trim(); -const run = cmd => { - proc.execSync(cmd, { stdio: 'inherit' }); -}; -const tryRead = cmd => { - try { - return read(cmd); - } catch { - return undefined; - } -}; - -const releaseBranchRegex = /^release-v(?(?\d+)\.(?\d+)(?:\.(?\d+))?)$/; - -const currentBranch = read('git rev-parse --abbrev-ref HEAD'); -const match = currentBranch.match(releaseBranchRegex); - -if (!match) { - console.error('Not currently on a release branch'); - process.exit(1); -} - -const pkgVersion = require('../package.json').version; - -if (pkgVersion.includes('-') && !pkgVersion.includes('.0.0-')) { - console.error('Refusing to update docs: non-major prerelease detected'); - process.exit(0); -} - -const current = match.groups; -const docsBranch = `docs-v${current.major}.x`; - -// Fetch remotes and find the docs branch if it exists -run('git fetch --all --no-tags'); -const matchingDocsBranches = tryRead(`git rev-parse --glob='*/${docsBranch}'`); - -if (!matchingDocsBranches) { - // Create the branch - run(`git checkout --orphan ${docsBranch}`); -} else { - const [publishedRef, ...others] = new Set(matchingDocsBranches.split('\n')); - if (others.length > 0) { - console.error( - `Found conflicting ${docsBranch} branches.\n` + - 'Either local branch is outdated or there are multiple matching remote branches.', - ); - process.exit(1); - } - const publishedVersion = JSON.parse(read(`git show ${publishedRef}:package.json`)).version; - const publishedMinor = publishedVersion.match(/\d+\.(?\d+)\.\d+/).groups.minor; - if (current.minor < publishedMinor) { - console.error('Refusing to update docs: newer version is published'); - process.exit(0); - } - - run('git checkout --quiet --detach'); - run(`git reset --soft ${publishedRef}`); - run(`git checkout ${docsBranch}`); -} - -run('npm run prepare-docs'); -run('git add -f docs'); // --force needed because generated docs files are gitignored -run('git commit -m "Update docs"'); -run(`git checkout ${currentBranch}`); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/README.md b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/README.md deleted file mode 100644 index 2309f9e108..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/README.md +++ /dev/null @@ -1,21 +0,0 @@ -The upgradeable variant of OpenZeppelin Contracts is automatically generated from the original Solidity code. We call this process "transpilation" and it is implemented by our [Upgradeability Transpiler](https://github.com/OpenZeppelin/openzeppelin-transpiler/). - -When the `master` branch or `release-v*` branches are updated, the code is transpiled and pushed to [OpenZeppelin/openzeppelin-contracts-upgradeable](https://github.com/OpenZeppelin/openzeppelin-contracts-upgradeable) by the `upgradeable.yml` workflow. - -## `transpile.sh` - -Applies patches and invokes the transpiler with the command line flags we need for our requirements (for example, excluding certain files). - -## `transpile-onto.sh` - -``` -bash scripts/upgradeable/transpile-onto.sh [] -``` - -Transpiles the contents of the current git branch and commits the result as a new commit on branch ``. If branch `` doesn't exist, it will copy the commit history of `[]` (this is used in GitHub Actions, but is usually not necessary locally). - -## `patch-apply.sh` & `patch-save.sh` - -Some of the upgradeable contract variants require ad-hoc changes that are not implemented by the transpiler. These changes are implemented by patches stored in `upgradeable.patch` in this directory. `patch-apply.sh` applies these patches. - -If the patches fail to apply due to changes in the repo, the conflicts have to be resolved manually. Once fixed, `patch-save.sh` will take the changes staged in Git and update `upgradeable.patch` to match. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/patch-apply.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/patch-apply.sh deleted file mode 100644 index d9e17589b0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/patch-apply.sh +++ /dev/null @@ -1,19 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -DIRNAME="$(dirname -- "${BASH_SOURCE[0]}")" -PATCH="$DIRNAME/upgradeable.patch" - -error() { - echo Error: "$*" >&2 - exit 1 -} - -if ! git diff-files --quiet ":!$PATCH" || ! git diff-index --quiet HEAD ":!$PATCH"; then - error "Repository must have no staged or unstaged changes" -fi - -if ! git apply -3 "$PATCH"; then - error "Fix conflicts and run $DIRNAME/patch-save.sh" -fi diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/patch-save.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/patch-save.sh deleted file mode 100644 index 111e6f1572..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/patch-save.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -DIRNAME="$(dirname -- "${BASH_SOURCE[0]}")" -PATCH="$DIRNAME/upgradeable.patch" - -error() { - echo Error: "$*" >&2 - exit 1 -} - -if ! git diff-files --quiet ":!$PATCH"; then - error "Unstaged changes. Stage to include in patch or temporarily stash." -fi - -git diff-index --cached --patch --output="$PATCH" HEAD -git restore --staged --worktree ":!$PATCH" diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/transpile-onto.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/transpile-onto.sh deleted file mode 100644 index b8508f0c27..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/transpile-onto.sh +++ /dev/null @@ -1,54 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -if [ $# -lt 1 ]; then - echo "usage: bash $0 []" >&2 - exit 1 -fi - -set -x - -target="$1" -base="${2-}" - -bash scripts/upgradeable/transpile.sh - -commit="$(git rev-parse --short HEAD)" -start_branch="$(git rev-parse --abbrev-ref HEAD)" - -git add contracts - -# detach from the current branch to avoid making changes to it -git checkout --quiet --detach - -# switch to the target branch, creating it if necessary -if git rev-parse -q --verify "$target"; then - # if the branch exists, make it the current HEAD without checking out its contents - git reset --soft "$target" - git checkout "$target" -else - # if the branch doesn't exist, create it as an orphan and check it out - git checkout --orphan "$target" - if [ -n "$base" ] && git rev-parse -q --verify "$base"; then - # if base was specified and it exists, set it as the branch history - git reset --soft "$base" - fi -fi - -# abort if there are no changes to commit at this point -if git diff --quiet --cached; then - exit -fi - -if [[ -v SUBMODULE_REMOTE ]]; then - lib=lib/openzeppelin-contracts - git submodule add -b "${base#origin/}" "$SUBMODULE_REMOTE" "$lib" - git -C "$lib" checkout "$commit" - git add "$lib" -fi - -git commit -m "Transpile $commit" - -# return to original branch -git checkout "$start_branch" diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/transpile.sh b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/transpile.sh deleted file mode 100644 index f7c848c132..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/transpile.sh +++ /dev/null @@ -1,50 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail -x - -VERSION="$(jq -r .version contracts/package.json)" -DIRNAME="$(dirname -- "${BASH_SOURCE[0]}")" - -bash "$DIRNAME/patch-apply.sh" -sed -i'' -e "s//$VERSION/g" "contracts/package.json" -git add contracts/package.json - -npm run clean -npm run compile - -build_info=($(jq -r '.input.sources | keys | if any(test("^contracts/mocks/.*\\bunreachable\\b")) then empty else input_filename end' artifacts/build-info/*)) -build_info_num=${#build_info[@]} - -if [ $build_info_num -ne 1 ]; then - echo "found $build_info_num relevant build info files but expected just 1" - exit 1 -fi - -# -D: delete original and excluded files -# -b: use this build info file -# -i: use included Initializable -# -x: exclude proxy-related contracts with a few exceptions -# -p: emit public initializer -# -n: use namespaces -# -N: exclude from namespaces transformation -# -q: partial transpilation using @openzeppelin/contracts as peer project -npx @openzeppelin/upgrade-safe-transpiler -D \ - -b "$build_info" \ - -i contracts/proxy/utils/Initializable.sol \ - -x 'contracts-exposed/**/*' \ - -x 'contracts/proxy/**/*' \ - -x '!contracts/proxy/Clones.sol' \ - -x '!contracts/proxy/ERC1967/ERC1967Storage.sol' \ - -x '!contracts/proxy/ERC1967/ERC1967Utils.sol' \ - -x '!contracts/proxy/utils/UUPSUpgradeable.sol' \ - -x '!contracts/proxy/beacon/IBeacon.sol' \ - -p 'contracts/access/manager/AccessManager.sol' \ - -p 'contracts/finance/VestingWallet.sol' \ - -p 'contracts/governance/TimelockController.sol' \ - -p 'contracts/metatx/ERC2771Forwarder.sol' \ - -n \ - -N 'contracts/mocks/**/*' \ - -q '@openzeppelin/' - -# delete compilation artifacts of vanilla code -npm run clean diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/upgradeable.patch b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/upgradeable.patch deleted file mode 100644 index 458ecd4358..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/scripts/upgradeable/upgradeable.patch +++ /dev/null @@ -1,361 +0,0 @@ -diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md -deleted file mode 100644 -index 35ad097ff..000000000 ---- a/.github/ISSUE_TEMPLATE/bug_report.md -+++ /dev/null -@@ -1,21 +0,0 @@ ----- --name: Bug report --about: Report a bug in OpenZeppelin Contracts -- ----- -- -- -- -- -- --**💻 Environment** -- -- -- --**📝 Details** -- -- -- --**🔢 Code to reproduce bug** -- -- -diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml -index 4018cef29..d343a53d8 100644 ---- a/.github/ISSUE_TEMPLATE/config.yml -+++ b/.github/ISSUE_TEMPLATE/config.yml -@@ -1,4 +1,8 @@ -+blank_issues_enabled: false - contact_links: -+ - name: Bug Reports & Feature Requests -+ url: https://github.com/OpenZeppelin/openzeppelin-contracts/issues/new/choose -+ about: Visit the OpenZeppelin Contracts repository - - name: Questions & Support Requests - url: https://forum.openzeppelin.com/c/support/contracts/18 - about: Ask in the OpenZeppelin Forum -diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md -deleted file mode 100644 -index ff596b0c3..000000000 ---- a/.github/ISSUE_TEMPLATE/feature_request.md -+++ /dev/null -@@ -1,14 +0,0 @@ ----- --name: Feature request --about: Suggest an idea for OpenZeppelin Contracts -- ----- -- --**🧐 Motivation** -- -- --**📝 Details** -- -- -- -- -diff --git a/README.md b/README.md -index fa7b4e31e..4799b6376 100644 ---- a/README.md -+++ b/README.md -@@ -19,6 +19,9 @@ - > [!IMPORTANT] - > OpenZeppelin Contracts uses semantic versioning to communicate backwards compatibility of its API and storage layout. For upgradeable contracts, the storage layout of different major versions should be assumed incompatible, for example, it is unsafe to upgrade from 4.9.3 to 5.0.0. Learn more at [Backwards Compatibility](https://docs.openzeppelin.com/contracts/backwards-compatibility). - -++> [!NOTE] -++> You are looking at the upgradeable variant of OpenZeppelin Contracts. Be sure to review the documentation on [Using OpenZeppelin Contracts with Upgrades](https://docs.openzeppelin.com/contracts/upgradeable). -++ - ## Overview - - ### Installation -@@ -26,7 +29,7 @@ - #### Hardhat (npm) - - ``` --$ npm install @openzeppelin/contracts -+$ npm install @openzeppelin/contracts-upgradeable - ``` - - #### Foundry (git) -@@ -38,10 +41,10 @@ $ npm install @openzeppelin/contracts - > Foundry installs the latest version initially, but subsequent `forge update` commands will use the `master` branch. - - ``` --$ forge install OpenZeppelin/openzeppelin-contracts -+$ forge install OpenZeppelin/openzeppelin-contracts-upgradeable - ``` - --Add `@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/` in `remappings.txt.` -+Add `@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/` in `remappings.txt.` - - ### Usage - -@@ -50,10 +53,11 @@ Once installed, you can use the contracts in the library by importing them: - ```solidity - pragma solidity ^0.8.20; - --import {ERC721} from "@openzeppelin/contracts/token/ERC721/ERC721.sol"; -+import {ERC721Upgradeable} from "@openzeppelin/contracts-upgradeable/token/ERC721/ERC721Upgradeable.sol"; - --contract MyCollectible is ERC721 { -- constructor() ERC721("MyCollectible", "MCO") { -+contract MyCollectible is ERC721Upgradeable { -+ function initialize() initializer public { -+ __ERC721_init("MyCollectible", "MCO"); - } - } - ``` -diff --git a/contracts/package.json b/contracts/package.json -index 845e8c403..8dc181b91 100644 ---- a/contracts/package.json -+++ b/contracts/package.json -@@ -1,5 +1,5 @@ - { -- "name": "@openzeppelin/contracts", -+ "name": "@openzeppelin/contracts-upgradeable", - "description": "Secure Smart Contract library for Solidity", - "version": "5.0.2", - "files": [ -@@ -13,7 +13,7 @@ - }, - "repository": { - "type": "git", -- "url": "https://github.com/OpenZeppelin/openzeppelin-contracts.git" -+ "url": "https://github.com/OpenZeppelin/openzeppelin-contracts-upgradeable.git" - }, - "keywords": [ - "solidity", -@@ -28,5 +28,8 @@ - "bugs": { - "url": "https://github.com/OpenZeppelin/openzeppelin-contracts/issues" - }, -- "homepage": "https://openzeppelin.com/contracts/" -+ "homepage": "https://openzeppelin.com/contracts/", -+ "peerDependencies": { -+ "@openzeppelin/contracts": "" -+ } - } -diff --git a/contracts/utils/cryptography/EIP712.sol b/contracts/utils/cryptography/EIP712.sol -index 77c4c8990..602467f40 100644 ---- a/contracts/utils/cryptography/EIP712.sol -+++ b/contracts/utils/cryptography/EIP712.sol -@@ -4,7 +4,6 @@ - pragma solidity ^0.8.20; - - import {MessageHashUtils} from "./MessageHashUtils.sol"; --import {ShortStrings, ShortString} from "../ShortStrings.sol"; - import {IERC5267} from "../../interfaces/IERC5267.sol"; - - /** -@@ -28,28 +27,18 @@ import {IERC5267} from "../../interfaces/IERC5267.sol"; - * NOTE: In the upgradeable version of this contract, the cached values will correspond to the address, and the domain - * separator of the implementation contract. This will cause the {_domainSeparatorV4} function to always rebuild the - * separator from the immutable values, which is cheaper than accessing a cached version in cold storage. -- * -- * @custom:oz-upgrades-unsafe-allow state-variable-immutable - */ - abstract contract EIP712 is IERC5267 { -- using ShortStrings for *; -- - bytes32 private constant TYPE_HASH = - keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); - -- // Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to -- // invalidate the cached domain separator if the chain id changes. -- bytes32 private immutable _cachedDomainSeparator; -- uint256 private immutable _cachedChainId; -- address private immutable _cachedThis; -- -+ /// @custom:oz-renamed-from _HASHED_NAME - bytes32 private immutable _hashedName; -+ /// @custom:oz-renamed-from _HASHED_VERSION - bytes32 private immutable _hashedVersion; - -- ShortString private immutable _name; -- ShortString private immutable _version; -- string private _nameFallback; -- string private _versionFallback; -+ string private _name; -+ string private _version; - - /** - * @dev Initializes the domain separator and parameter caches. -@@ -64,29 +53,23 @@ abstract contract EIP712 is IERC5267 { - * contract upgrade]. - */ - constructor(string memory name, string memory version) { -- _name = name.toShortStringWithFallback(_nameFallback); -- _version = version.toShortStringWithFallback(_versionFallback); -- _hashedName = keccak256(bytes(name)); -- _hashedVersion = keccak256(bytes(version)); -- -- _cachedChainId = block.chainid; -- _cachedDomainSeparator = _buildDomainSeparator(); -- _cachedThis = address(this); -+ _name = name; -+ _version = version; -+ -+ // Reset prior values in storage if upgrading -+ _hashedName = 0; -+ _hashedVersion = 0; - } - - /** - * @dev Returns the domain separator for the current chain. - */ - function _domainSeparatorV4() internal view returns (bytes32) { -- if (address(this) == _cachedThis && block.chainid == _cachedChainId) { -- return _cachedDomainSeparator; -- } else { -- return _buildDomainSeparator(); -- } -+ return _buildDomainSeparator(); - } - - function _buildDomainSeparator() private view returns (bytes32) { -- return keccak256(abi.encode(TYPE_HASH, _hashedName, _hashedVersion, block.chainid, address(this))); -+ return keccak256(abi.encode(TYPE_HASH, _EIP712NameHash(), _EIP712VersionHash(), block.chainid, address(this))); - } - - /** -@@ -125,6 +108,10 @@ abstract contract EIP712 is IERC5267 { - uint256[] memory extensions - ) - { -+ // If the hashed name and version in storage are non-zero, the contract hasn't been properly initialized -+ // and the EIP712 domain is not reliable, as it will be missing name and version. -+ require(_hashedName == 0 && _hashedVersion == 0, "EIP712: Uninitialized"); -+ - return ( - hex"0f", // 01111 - _EIP712Name(), -@@ -139,22 +126,62 @@ abstract contract EIP712 is IERC5267 { - /** - * @dev The name parameter for the EIP712 domain. - * -- * NOTE: By default this function reads _name which is an immutable value. -- * It only reads from storage if necessary (in case the value is too large to fit in a ShortString). -+ * NOTE: This function reads from storage by default, but can be redefined to return a constant value if gas costs -+ * are a concern. - */ -- // solhint-disable-next-line func-name-mixedcase -- function _EIP712Name() internal view returns (string memory) { -- return _name.toStringWithFallback(_nameFallback); -+ function _EIP712Name() internal view virtual returns (string memory) { -+ return _name; - } - - /** - * @dev The version parameter for the EIP712 domain. - * -- * NOTE: By default this function reads _version which is an immutable value. -- * It only reads from storage if necessary (in case the value is too large to fit in a ShortString). -+ * NOTE: This function reads from storage by default, but can be redefined to return a constant value if gas costs -+ * are a concern. - */ -- // solhint-disable-next-line func-name-mixedcase -- function _EIP712Version() internal view returns (string memory) { -- return _version.toStringWithFallback(_versionFallback); -+ function _EIP712Version() internal view virtual returns (string memory) { -+ return _version; -+ } -+ -+ /** -+ * @dev The hash of the name parameter for the EIP712 domain. -+ * -+ * NOTE: In previous versions this function was virtual. In this version you should override `_EIP712Name` instead. -+ */ -+ function _EIP712NameHash() internal view returns (bytes32) { -+ string memory name = _EIP712Name(); -+ if (bytes(name).length > 0) { -+ return keccak256(bytes(name)); -+ } else { -+ // If the name is empty, the contract may have been upgraded without initializing the new storage. -+ // We return the name hash in storage if non-zero, otherwise we assume the name is empty by design. -+ bytes32 hashedName = _hashedName; -+ if (hashedName != 0) { -+ return hashedName; -+ } else { -+ return keccak256(""); -+ } -+ } -+ } -+ -+ /** -+ * @dev The hash of the version parameter for the EIP712 domain. -+ * -+ * NOTE: In previous versions this function was virtual. In this version you should override `_EIP712Version` instead. -+ */ -+ function _EIP712VersionHash() internal view returns (bytes32) { -+ string memory version = _EIP712Version(); -+ if (bytes(version).length > 0) { -+ return keccak256(bytes(version)); -+ } else { -+ // If the version is empty, the contract may have been upgraded without initializing the new storage. -+ // We return the version hash in storage if non-zero, otherwise we assume the version is empty by design. -+ bytes32 hashedVersion = _hashedVersion; -+ if (hashedVersion != 0) { -+ return hashedVersion; -+ } else { -+ return keccak256(""); -+ } -+ } - } - } -diff --git a/package.json b/package.json -index c4b358e10..96ab2559c 100644 ---- a/package.json -+++ b/package.json -@@ -32,7 +32,7 @@ - }, - "repository": { - "type": "git", -- "url": "https://github.com/OpenZeppelin/openzeppelin-contracts.git" -+ "url": "https://github.com/OpenZeppelin/openzeppelin-contracts-upgradeable.git" - }, - "keywords": [ - "solidity", -diff --git a/remappings.txt b/remappings.txt -index 304d1386a..a1cd63bee 100644 ---- a/remappings.txt -+++ b/remappings.txt -@@ -1 +1,2 @@ --@openzeppelin/contracts/=contracts/ -+@openzeppelin/contracts-upgradeable/=contracts/ -+@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/ -diff --git a/test/utils/cryptography/EIP712.test.js b/test/utils/cryptography/EIP712.test.js -index 2b6e7fa97..268e0d29d 100644 ---- a/test/utils/cryptography/EIP712.test.js -+++ b/test/utils/cryptography/EIP712.test.js -@@ -47,27 +47,6 @@ describe('EIP712', function () { - const rebuildDomain = await getDomain(this.eip712); - expect(rebuildDomain).to.be.deep.equal(this.domain); - }); -- -- if (shortOrLong === 'short') { -- // Long strings are in storage, and the proxy will not be properly initialized unless -- // the upgradeable contract variant is used and the initializer is invoked. -- -- it('adjusts when behind proxy', async function () { -- const factory = await ethers.deployContract('$Clones'); -- -- const clone = await factory -- .$clone(this.eip712) -- .then(tx => tx.wait()) -- .then(receipt => receipt.logs.find(ev => ev.fragment.name == 'return$clone_address').args.instance) -- .then(address => ethers.getContractAt('$EIP712Verifier', address)); -- -- const expectedDomain = { ...this.domain, verifyingContract: clone.target }; -- expect(await getDomain(clone)).to.be.deep.equal(expectedDomain); -- -- const expectedSeparator = await domainSeparator(expectedDomain); -- expect(await clone.$_domainSeparatorV4()).to.equal(expectedSeparator); -- }); -- } - }); - - it('hash digest', async function () { diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/slither.config.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/slither.config.json deleted file mode 100644 index fa52f4dd1d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/slither.config.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "detectors_to_run": "arbitrary-send-erc20,array-by-reference,incorrect-shift,name-reused,rtlo,suicidal,uninitialized-state,uninitialized-storage,arbitrary-send-erc20-permit,controlled-array-length,controlled-delegatecall,delegatecall-loop,msg-value-loop,reentrancy-eth,unchecked-transfer,weak-prng,domain-separator-collision,erc20-interface,erc721-interface,locked-ether,mapping-deletion,shadowing-abstract,tautology,write-after-write,boolean-cst,reentrancy-no-eth,reused-constructor,tx-origin,unchecked-lowlevel,unchecked-send,variable-scope,void-cst,events-access,events-maths,incorrect-unary,boolean-equal,cyclomatic-complexity,deprecated-standards,erc20-indexed,function-init-state,pragma,unused-state,reentrancy-unlimited-gas,constable-states,immutable-states,var-read-using-this", - "filter_paths": "contracts/mocks,contracts/vendor,contracts-exposed", - "compile_force_framework": "hardhat" -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/solhint.config.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/solhint.config.js deleted file mode 100644 index f0bd7994f9..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/solhint.config.js +++ /dev/null @@ -1,26 +0,0 @@ -const customRules = require('./scripts/solhint-custom'); - -const rules = [ - 'avoid-tx-origin', - 'const-name-snakecase', - 'contract-name-camelcase', - 'event-name-camelcase', - 'explicit-types', - 'func-name-mixedcase', - 'func-param-name-mixedcase', - 'imports-on-top', - 'modifier-name-mixedcase', - 'no-console', - 'no-global-import', - 'no-unused-vars', - 'quotes', - 'use-forbidden-name', - 'var-name-mixedcase', - 'visibility-modifier-order', - ...customRules.map(r => `openzeppelin/${r.ruleId}`), -]; - -module.exports = { - plugins: ['openzeppelin'], - rules: Object.fromEntries(rules.map(r => [r, 'error'])), -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/TESTING.md b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/TESTING.md deleted file mode 100644 index a5ee9323ff..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/TESTING.md +++ /dev/null @@ -1,3 +0,0 @@ -## Testing - -Unit test are critical to OpenZeppelin Contracts. They help ensure code quality and mitigate against security vulnerabilities. The directory structure within the `/test` directory corresponds to the `/contracts` directory. diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/AccessControl.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/AccessControl.behavior.js deleted file mode 100644 index b7ae2a9509..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/AccessControl.behavior.js +++ /dev/null @@ -1,874 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); - -const time = require('../helpers/time'); - -const { shouldSupportInterfaces } = require('../utils/introspection/SupportsInterface.behavior'); - -const DEFAULT_ADMIN_ROLE = ethers.ZeroHash; -const ROLE = ethers.id('ROLE'); -const OTHER_ROLE = ethers.id('OTHER_ROLE'); - -function shouldBehaveLikeAccessControl() { - beforeEach(async function () { - [this.authorized, this.other, this.otherAdmin] = this.accounts; - }); - - shouldSupportInterfaces(['AccessControl']); - - describe('default admin', function () { - it('deployer has default admin role', async function () { - expect(await this.mock.hasRole(DEFAULT_ADMIN_ROLE, this.defaultAdmin)).to.be.true; - }); - - it("other roles's admin is the default admin role", async function () { - expect(await this.mock.getRoleAdmin(ROLE)).to.equal(DEFAULT_ADMIN_ROLE); - }); - - it("default admin role's admin is itself", async function () { - expect(await this.mock.getRoleAdmin(DEFAULT_ADMIN_ROLE)).to.equal(DEFAULT_ADMIN_ROLE); - }); - }); - - describe('granting', function () { - beforeEach(async function () { - await this.mock.connect(this.defaultAdmin).grantRole(ROLE, this.authorized); - }); - - it('non-admin cannot grant role to other accounts', async function () { - await expect(this.mock.connect(this.other).grantRole(ROLE, this.authorized)) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.other, DEFAULT_ADMIN_ROLE); - }); - - it('accounts can be granted a role multiple times', async function () { - await this.mock.connect(this.defaultAdmin).grantRole(ROLE, this.authorized); - await expect(this.mock.connect(this.defaultAdmin).grantRole(ROLE, this.authorized)).to.not.emit( - this.mock, - 'RoleGranted', - ); - }); - }); - - describe('revoking', function () { - it('roles that are not had can be revoked', async function () { - expect(await this.mock.hasRole(ROLE, this.authorized)).to.be.false; - - await expect(this.mock.connect(this.defaultAdmin).revokeRole(ROLE, this.authorized)).to.not.emit( - this.mock, - 'RoleRevoked', - ); - }); - - describe('with granted role', function () { - beforeEach(async function () { - await this.mock.connect(this.defaultAdmin).grantRole(ROLE, this.authorized); - }); - - it('admin can revoke role', async function () { - await expect(this.mock.connect(this.defaultAdmin).revokeRole(ROLE, this.authorized)) - .to.emit(this.mock, 'RoleRevoked') - .withArgs(ROLE, this.authorized, this.defaultAdmin); - - expect(await this.mock.hasRole(ROLE, this.authorized)).to.be.false; - }); - - it('non-admin cannot revoke role', async function () { - await expect(this.mock.connect(this.other).revokeRole(ROLE, this.authorized)) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.other, DEFAULT_ADMIN_ROLE); - }); - - it('a role can be revoked multiple times', async function () { - await this.mock.connect(this.defaultAdmin).revokeRole(ROLE, this.authorized); - - await expect(this.mock.connect(this.defaultAdmin).revokeRole(ROLE, this.authorized)).to.not.emit( - this.mock, - 'RoleRevoked', - ); - }); - }); - }); - - describe('renouncing', function () { - it('roles that are not had can be renounced', async function () { - await expect(this.mock.connect(this.authorized).renounceRole(ROLE, this.authorized)).to.not.emit( - this.mock, - 'RoleRevoked', - ); - }); - - describe('with granted role', function () { - beforeEach(async function () { - await this.mock.connect(this.defaultAdmin).grantRole(ROLE, this.authorized); - }); - - it('bearer can renounce role', async function () { - await expect(this.mock.connect(this.authorized).renounceRole(ROLE, this.authorized)) - .to.emit(this.mock, 'RoleRevoked') - .withArgs(ROLE, this.authorized, this.authorized); - - expect(await this.mock.hasRole(ROLE, this.authorized)).to.be.false; - }); - - it('only the sender can renounce their roles', async function () { - await expect( - this.mock.connect(this.defaultAdmin).renounceRole(ROLE, this.authorized), - ).to.be.revertedWithCustomError(this.mock, 'AccessControlBadConfirmation'); - }); - - it('a role can be renounced multiple times', async function () { - await this.mock.connect(this.authorized).renounceRole(ROLE, this.authorized); - - await expect(this.mock.connect(this.authorized).renounceRole(ROLE, this.authorized)).not.to.emit( - this.mock, - 'RoleRevoked', - ); - }); - }); - }); - - describe('setting role admin', function () { - beforeEach(async function () { - await expect(this.mock.$_setRoleAdmin(ROLE, OTHER_ROLE)) - .to.emit(this.mock, 'RoleAdminChanged') - .withArgs(ROLE, DEFAULT_ADMIN_ROLE, OTHER_ROLE); - - await this.mock.connect(this.defaultAdmin).grantRole(OTHER_ROLE, this.otherAdmin); - }); - - it("a role's admin role can be changed", async function () { - expect(await this.mock.getRoleAdmin(ROLE)).to.equal(OTHER_ROLE); - }); - - it('the new admin can grant roles', async function () { - await expect(this.mock.connect(this.otherAdmin).grantRole(ROLE, this.authorized)) - .to.emit(this.mock, 'RoleGranted') - .withArgs(ROLE, this.authorized, this.otherAdmin); - }); - - it('the new admin can revoke roles', async function () { - await this.mock.connect(this.otherAdmin).grantRole(ROLE, this.authorized); - await expect(this.mock.connect(this.otherAdmin).revokeRole(ROLE, this.authorized)) - .to.emit(this.mock, 'RoleRevoked') - .withArgs(ROLE, this.authorized, this.otherAdmin); - }); - - it("a role's previous admins no longer grant roles", async function () { - await expect(this.mock.connect(this.defaultAdmin).grantRole(ROLE, this.authorized)) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.defaultAdmin, OTHER_ROLE); - }); - - it("a role's previous admins no longer revoke roles", async function () { - await expect(this.mock.connect(this.defaultAdmin).revokeRole(ROLE, this.authorized)) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.defaultAdmin, OTHER_ROLE); - }); - }); - - describe('onlyRole modifier', function () { - beforeEach(async function () { - await this.mock.connect(this.defaultAdmin).grantRole(ROLE, this.authorized); - }); - - it('do not revert if sender has role', async function () { - await this.mock.connect(this.authorized).$_checkRole(ROLE); - }); - - it("revert if sender doesn't have role #1", async function () { - await expect(this.mock.connect(this.other).$_checkRole(ROLE)) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.other, ROLE); - }); - - it("revert if sender doesn't have role #2", async function () { - await expect(this.mock.connect(this.authorized).$_checkRole(OTHER_ROLE)) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.authorized, OTHER_ROLE); - }); - }); - - describe('internal functions', function () { - describe('_grantRole', function () { - it('return true if the account does not have the role', async function () { - await expect(this.mock.$_grantRole(ROLE, this.authorized)) - .to.emit(this.mock, 'return$_grantRole') - .withArgs(true); - }); - - it('return false if the account has the role', async function () { - await this.mock.$_grantRole(ROLE, this.authorized); - - await expect(this.mock.$_grantRole(ROLE, this.authorized)) - .to.emit(this.mock, 'return$_grantRole') - .withArgs(false); - }); - }); - - describe('_revokeRole', function () { - it('return true if the account has the role', async function () { - await this.mock.$_grantRole(ROLE, this.authorized); - - await expect(this.mock.$_revokeRole(ROLE, this.authorized)) - .to.emit(this.mock, 'return$_revokeRole') - .withArgs(true); - }); - - it('return false if the account does not have the role', async function () { - await expect(this.mock.$_revokeRole(ROLE, this.authorized)) - .to.emit(this.mock, 'return$_revokeRole') - .withArgs(false); - }); - }); - }); -} - -function shouldBehaveLikeAccessControlEnumerable() { - beforeEach(async function () { - [this.authorized, this.other, this.otherAdmin, this.otherAuthorized] = this.accounts; - }); - - shouldSupportInterfaces(['AccessControlEnumerable']); - - describe('enumerating', function () { - it('role bearers can be enumerated', async function () { - await this.mock.connect(this.defaultAdmin).grantRole(ROLE, this.authorized); - await this.mock.connect(this.defaultAdmin).grantRole(ROLE, this.other); - await this.mock.connect(this.defaultAdmin).grantRole(ROLE, this.otherAuthorized); - await this.mock.connect(this.defaultAdmin).revokeRole(ROLE, this.other); - - const expectedMembers = [this.authorized.address, this.otherAuthorized.address]; - - const memberCount = await this.mock.getRoleMemberCount(ROLE); - const members = []; - for (let i = 0; i < memberCount; ++i) { - members.push(await this.mock.getRoleMember(ROLE, i)); - } - - expect(memberCount).to.equal(expectedMembers.length); - expect(members).to.deep.equal(expectedMembers); - expect(await this.mock.getRoleMembers(ROLE)).to.deep.equal(expectedMembers); - }); - - it('role enumeration should be in sync after renounceRole call', async function () { - expect(await this.mock.getRoleMemberCount(ROLE)).to.equal(0); - await this.mock.connect(this.defaultAdmin).grantRole(ROLE, this.defaultAdmin); - expect(await this.mock.getRoleMemberCount(ROLE)).to.equal(1); - await this.mock.connect(this.defaultAdmin).renounceRole(ROLE, this.defaultAdmin); - expect(await this.mock.getRoleMemberCount(ROLE)).to.equal(0); - }); - }); -} - -function shouldBehaveLikeAccessControlDefaultAdminRules() { - shouldSupportInterfaces(['AccessControlDefaultAdminRules']); - - beforeEach(async function () { - [this.newDefaultAdmin, this.other] = this.accounts; - }); - - for (const getter of ['owner', 'defaultAdmin']) { - describe(`${getter}()`, function () { - it('has a default set to the initial default admin', async function () { - const value = await this.mock[getter](); - expect(value).to.equal(this.defaultAdmin); - expect(await this.mock.hasRole(DEFAULT_ADMIN_ROLE, value)).to.be.true; - }); - - it('changes if the default admin changes', async function () { - // Starts an admin transfer - await this.mock.connect(this.defaultAdmin).beginDefaultAdminTransfer(this.newDefaultAdmin); - - // Wait for acceptance - await time.increaseBy.timestamp(this.delay + 1n, false); - await this.mock.connect(this.newDefaultAdmin).acceptDefaultAdminTransfer(); - - const value = await this.mock[getter](); - expect(value).to.equal(this.newDefaultAdmin); - }); - }); - } - - describe('pendingDefaultAdmin()', function () { - it('returns 0 if no pending default admin transfer', async function () { - const { newAdmin, schedule } = await this.mock.pendingDefaultAdmin(); - expect(newAdmin).to.equal(ethers.ZeroAddress); - expect(schedule).to.equal(0); - }); - - describe('when there is a scheduled default admin transfer', function () { - beforeEach('begins admin transfer', async function () { - await this.mock.connect(this.defaultAdmin).beginDefaultAdminTransfer(this.newDefaultAdmin); - }); - - for (const [fromSchedule, tag] of [ - [-1n, 'before'], - [0n, 'exactly when'], - [1n, 'after'], - ]) { - it(`returns pending admin and schedule ${tag} it passes if not accepted`, async function () { - // Wait until schedule + fromSchedule - const { schedule: firstSchedule } = await this.mock.pendingDefaultAdmin(); - await time.increaseTo.timestamp(firstSchedule + fromSchedule); - - const { newAdmin, schedule } = await this.mock.pendingDefaultAdmin(); - expect(newAdmin).to.equal(this.newDefaultAdmin); - expect(schedule).to.equal(firstSchedule); - }); - } - - it('returns 0 after schedule passes and the transfer was accepted', async function () { - // Wait after schedule - const { schedule: firstSchedule } = await this.mock.pendingDefaultAdmin(); - await time.increaseTo.timestamp(firstSchedule + 1n, false); - - // Accepts - await this.mock.connect(this.newDefaultAdmin).acceptDefaultAdminTransfer(); - - const { newAdmin, schedule } = await this.mock.pendingDefaultAdmin(); - expect(newAdmin).to.equal(ethers.ZeroAddress); - expect(schedule).to.equal(0); - }); - }); - }); - - describe('defaultAdminDelay()', function () { - it('returns the current delay', async function () { - expect(await this.mock.defaultAdminDelay()).to.equal(this.delay); - }); - - describe('when there is a scheduled delay change', function () { - const newDelay = 0x1337n; // Any change - - beforeEach('begins delay change', async function () { - await this.mock.connect(this.defaultAdmin).changeDefaultAdminDelay(newDelay); - }); - - for (const [fromSchedule, tag, expectNew, delayTag] of [ - [-1n, 'before', false, 'old'], - [0n, 'exactly when', false, 'old'], - [1n, 'after', true, 'new'], - ]) { - it(`returns ${delayTag} delay ${tag} delay schedule passes`, async function () { - // Wait until schedule + fromSchedule - const { schedule } = await this.mock.pendingDefaultAdminDelay(); - await time.increaseTo.timestamp(schedule + fromSchedule); - - const currentDelay = await this.mock.defaultAdminDelay(); - expect(currentDelay).to.equal(expectNew ? newDelay : this.delay); - }); - } - }); - }); - - describe('pendingDefaultAdminDelay()', function () { - it('returns 0 if not set', async function () { - const { newDelay, schedule } = await this.mock.pendingDefaultAdminDelay(); - expect(newDelay).to.equal(0); - expect(schedule).to.equal(0); - }); - - describe('when there is a scheduled delay change', function () { - const newDelay = 0x1337n; // Any change - - beforeEach('begins admin transfer', async function () { - await this.mock.connect(this.defaultAdmin).changeDefaultAdminDelay(newDelay); - }); - - for (const [fromSchedule, tag, expectedDelay, delayTag, expectZeroSchedule] of [ - [-1n, 'before', newDelay, 'new'], - [0n, 'exactly when', newDelay, 'new'], - [1n, 'after', 0, 'zero', true], - ]) { - it(`returns ${delayTag} delay ${tag} delay schedule passes`, async function () { - // Wait until schedule + fromSchedule - const { schedule: firstSchedule } = await this.mock.pendingDefaultAdminDelay(); - await time.increaseTo.timestamp(firstSchedule + fromSchedule); - - const { newDelay, schedule } = await this.mock.pendingDefaultAdminDelay(); - expect(newDelay).to.equal(expectedDelay); - expect(schedule).to.equal(expectZeroSchedule ? 0 : firstSchedule); - }); - } - }); - }); - - describe('defaultAdminDelayIncreaseWait()', function () { - it('should return 5 days (default)', async function () { - expect(await this.mock.defaultAdminDelayIncreaseWait()).to.equal(time.duration.days(5)); - }); - }); - - it('should revert if granting default admin role', async function () { - await expect( - this.mock.connect(this.defaultAdmin).grantRole(DEFAULT_ADMIN_ROLE, this.defaultAdmin), - ).to.be.revertedWithCustomError(this.mock, 'AccessControlEnforcedDefaultAdminRules'); - }); - - it('should revert if revoking default admin role', async function () { - await expect( - this.mock.connect(this.defaultAdmin).revokeRole(DEFAULT_ADMIN_ROLE, this.defaultAdmin), - ).to.be.revertedWithCustomError(this.mock, 'AccessControlEnforcedDefaultAdminRules'); - }); - - it("should revert if defaultAdmin's admin is changed", async function () { - await expect(this.mock.$_setRoleAdmin(DEFAULT_ADMIN_ROLE, OTHER_ROLE)).to.be.revertedWithCustomError( - this.mock, - 'AccessControlEnforcedDefaultAdminRules', - ); - }); - - it('should not grant the default admin role twice', async function () { - await expect(this.mock.$_grantRole(DEFAULT_ADMIN_ROLE, this.defaultAdmin)).to.be.revertedWithCustomError( - this.mock, - 'AccessControlEnforcedDefaultAdminRules', - ); - }); - - describe('begins a default admin transfer', function () { - it('reverts if called by non default admin accounts', async function () { - await expect(this.mock.connect(this.other).beginDefaultAdminTransfer(this.newDefaultAdmin)) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.other, DEFAULT_ADMIN_ROLE); - }); - - describe('when there is no pending delay nor pending admin transfer', function () { - it('should set pending default admin and schedule', async function () { - const nextBlockTimestamp = (await time.clock.timestamp()) + 1n; - const acceptSchedule = nextBlockTimestamp + this.delay; - - await time.increaseTo.timestamp(nextBlockTimestamp, false); // set timestamp but don't mine the block yet - await expect(this.mock.connect(this.defaultAdmin).beginDefaultAdminTransfer(this.newDefaultAdmin)) - .to.emit(this.mock, 'DefaultAdminTransferScheduled') - .withArgs(this.newDefaultAdmin, acceptSchedule); - - const { newAdmin, schedule } = await this.mock.pendingDefaultAdmin(); - expect(newAdmin).to.equal(this.newDefaultAdmin); - expect(schedule).to.equal(acceptSchedule); - }); - }); - - describe('when there is a pending admin transfer', function () { - beforeEach('sets a pending default admin transfer', async function () { - await this.mock.connect(this.defaultAdmin).beginDefaultAdminTransfer(this.newDefaultAdmin); - this.acceptSchedule = (await time.clock.timestamp()) + this.delay; - }); - - for (const [fromSchedule, tag] of [ - [-1n, 'before'], - [0n, 'exactly when'], - [1n, 'after'], - ]) { - it(`should be able to begin a transfer again ${tag} acceptSchedule passes`, async function () { - // Wait until schedule + fromSchedule - await time.increaseTo.timestamp(this.acceptSchedule + fromSchedule, false); - - // defaultAdmin changes its mind and begin again to another address - await expect(this.mock.connect(this.defaultAdmin).beginDefaultAdminTransfer(this.other)).to.emit( - this.mock, - 'DefaultAdminTransferCanceled', // Cancellation is always emitted since it was never accepted - ); - const newSchedule = (await time.clock.timestamp()) + this.delay; - const { newAdmin, schedule } = await this.mock.pendingDefaultAdmin(); - expect(newAdmin).to.equal(this.other); - expect(schedule).to.equal(newSchedule); - }); - } - - it('should not emit a cancellation event if the new default admin accepted', async function () { - // Wait until the acceptSchedule has passed - await time.increaseTo.timestamp(this.acceptSchedule + 1n, false); - - // Accept and restart - await this.mock.connect(this.newDefaultAdmin).acceptDefaultAdminTransfer(); - await expect(this.mock.connect(this.newDefaultAdmin).beginDefaultAdminTransfer(this.other)).to.not.emit( - this.mock, - 'DefaultAdminTransferCanceled', - ); - }); - }); - - describe('when there is a pending delay', function () { - const newDelay = time.duration.hours(3); - - beforeEach('schedule a delay change', async function () { - await this.mock.connect(this.defaultAdmin).changeDefaultAdminDelay(newDelay); - ({ schedule: this.effectSchedule } = await this.mock.pendingDefaultAdminDelay()); - }); - - for (const [fromSchedule, schedulePassed, expectNewDelay] of [ - [-1n, 'before', false], - [0n, 'exactly when', false], - [1n, 'after', true], - ]) { - it(`should set the ${ - expectNewDelay ? 'new' : 'old' - } delay and apply it to next default admin transfer schedule ${schedulePassed} effectSchedule passed`, async function () { - // Wait until the expected fromSchedule time - const nextBlockTimestamp = this.effectSchedule + fromSchedule; - await time.increaseTo.timestamp(nextBlockTimestamp, false); - - // Start the new default admin transfer and get its schedule - const expectedDelay = expectNewDelay ? newDelay : this.delay; - const expectedAcceptSchedule = nextBlockTimestamp + expectedDelay; - await expect(this.mock.connect(this.defaultAdmin).beginDefaultAdminTransfer(this.newDefaultAdmin)) - .to.emit(this.mock, 'DefaultAdminTransferScheduled') - .withArgs(this.newDefaultAdmin, expectedAcceptSchedule); - - // Check that the schedule corresponds with the new delay - const { newAdmin, schedule: transferSchedule } = await this.mock.pendingDefaultAdmin(); - expect(newAdmin).to.equal(this.newDefaultAdmin); - expect(transferSchedule).to.equal(expectedAcceptSchedule); - }); - } - }); - }); - - describe('accepts transfer admin', function () { - beforeEach(async function () { - await this.mock.connect(this.defaultAdmin).beginDefaultAdminTransfer(this.newDefaultAdmin); - this.acceptSchedule = (await time.clock.timestamp()) + this.delay; - }); - - it('should revert if caller is not pending default admin', async function () { - await time.increaseTo.timestamp(this.acceptSchedule + 1n, false); - await expect(this.mock.connect(this.other).acceptDefaultAdminTransfer()) - .to.be.revertedWithCustomError(this.mock, 'AccessControlInvalidDefaultAdmin') - .withArgs(this.other); - }); - - describe('when caller is pending default admin and delay has passed', function () { - beforeEach(async function () { - await time.increaseTo.timestamp(this.acceptSchedule + 1n, false); - }); - - it('accepts a transfer and changes default admin', async function () { - // Emit events - await expect(this.mock.connect(this.newDefaultAdmin).acceptDefaultAdminTransfer()) - .to.emit(this.mock, 'RoleRevoked') - .withArgs(DEFAULT_ADMIN_ROLE, this.defaultAdmin, this.newDefaultAdmin) - .to.emit(this.mock, 'RoleGranted') - .withArgs(DEFAULT_ADMIN_ROLE, this.newDefaultAdmin, this.newDefaultAdmin); - - // Storage changes - expect(await this.mock.hasRole(DEFAULT_ADMIN_ROLE, this.defaultAdmin)).to.be.false; - expect(await this.mock.hasRole(DEFAULT_ADMIN_ROLE, this.newDefaultAdmin)).to.be.true; - expect(await this.mock.owner()).to.equal(this.newDefaultAdmin); - - // Resets pending default admin and schedule - const { newAdmin, schedule } = await this.mock.pendingDefaultAdmin(); - expect(newAdmin).to.equal(ethers.ZeroAddress); - expect(schedule).to.equal(0); - }); - }); - - describe('schedule not passed', function () { - for (const [fromSchedule, tag] of [ - [-1n, 'less'], - [0n, 'equal'], - ]) { - it(`should revert if block.timestamp is ${tag} to schedule`, async function () { - await time.increaseTo.timestamp(this.acceptSchedule + fromSchedule, false); - await expect(this.mock.connect(this.newDefaultAdmin).acceptDefaultAdminTransfer()) - .to.be.revertedWithCustomError(this.mock, 'AccessControlEnforcedDefaultAdminDelay') - .withArgs(this.acceptSchedule); - }); - } - }); - }); - - describe('cancels a default admin transfer', function () { - it('reverts if called by non default admin accounts', async function () { - await expect(this.mock.connect(this.other).cancelDefaultAdminTransfer()) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.other, DEFAULT_ADMIN_ROLE); - }); - - describe('when there is a pending default admin transfer', function () { - beforeEach(async function () { - await this.mock.connect(this.defaultAdmin).beginDefaultAdminTransfer(this.newDefaultAdmin); - this.acceptSchedule = (await time.clock.timestamp()) + this.delay; - }); - - for (const [fromSchedule, tag] of [ - [-1n, 'before'], - [0n, 'exactly when'], - [1n, 'after'], - ]) { - it(`resets pending default admin and schedule ${tag} transfer schedule passes`, async function () { - // Advance until passed delay - await time.increaseTo.timestamp(this.acceptSchedule + fromSchedule, false); - - await expect(this.mock.connect(this.defaultAdmin).cancelDefaultAdminTransfer()).to.emit( - this.mock, - 'DefaultAdminTransferCanceled', - ); - - const { newAdmin, schedule } = await this.mock.pendingDefaultAdmin(); - expect(newAdmin).to.equal(ethers.ZeroAddress); - expect(schedule).to.equal(0); - }); - } - - it('should revert if the previous default admin tries to accept', async function () { - await this.mock.connect(this.defaultAdmin).cancelDefaultAdminTransfer(); - - // Advance until passed delay - await time.increaseTo.timestamp(this.acceptSchedule + 1n, false); - - // Previous pending default admin should not be able to accept after cancellation. - await expect(this.mock.connect(this.newDefaultAdmin).acceptDefaultAdminTransfer()) - .to.be.revertedWithCustomError(this.mock, 'AccessControlInvalidDefaultAdmin') - .withArgs(this.newDefaultAdmin); - }); - }); - - describe('when there is no pending default admin transfer', function () { - it('should succeed without changes', async function () { - await expect(this.mock.connect(this.defaultAdmin).cancelDefaultAdminTransfer()).to.not.emit( - this.mock, - 'DefaultAdminTransferCanceled', - ); - - const { newAdmin, schedule } = await this.mock.pendingDefaultAdmin(); - expect(newAdmin).to.equal(ethers.ZeroAddress); - expect(schedule).to.equal(0); - }); - }); - }); - - describe('renounces admin', function () { - beforeEach(async function () { - await this.mock.connect(this.defaultAdmin).beginDefaultAdminTransfer(ethers.ZeroAddress); - this.expectedSchedule = (await time.clock.timestamp()) + this.delay; - }); - - it('reverts if caller is not default admin', async function () { - await time.increaseBy.timestamp(this.delay + 1n, false); - await expect( - this.mock.connect(this.defaultAdmin).renounceRole(DEFAULT_ADMIN_ROLE, this.other), - ).to.be.revertedWithCustomError(this.mock, 'AccessControlBadConfirmation'); - }); - - it("renouncing the admin role when not an admin doesn't affect the schedule", async function () { - await time.increaseBy.timestamp(this.delay + 1n, false); - await this.mock.connect(this.other).renounceRole(DEFAULT_ADMIN_ROLE, this.other); - - const { newAdmin, schedule } = await this.mock.pendingDefaultAdmin(); - expect(newAdmin).to.equal(ethers.ZeroAddress); - expect(schedule).to.equal(this.expectedSchedule); - }); - - it('keeps defaultAdmin consistent with hasRole if another non-defaultAdmin user renounces the DEFAULT_ADMIN_ROLE', async function () { - await time.increaseBy.timestamp(this.delay + 1n, false); - - // This passes because it's a noop - await this.mock.connect(this.other).renounceRole(DEFAULT_ADMIN_ROLE, this.other); - - expect(await this.mock.hasRole(DEFAULT_ADMIN_ROLE, this.defaultAdmin)).to.be.true; - expect(await this.mock.defaultAdmin()).to.equal(this.defaultAdmin); - }); - - it('renounces role', async function () { - await time.increaseBy.timestamp(this.delay + 1n, false); - await expect(this.mock.connect(this.defaultAdmin).renounceRole(DEFAULT_ADMIN_ROLE, this.defaultAdmin)) - .to.emit(this.mock, 'RoleRevoked') - .withArgs(DEFAULT_ADMIN_ROLE, this.defaultAdmin, this.defaultAdmin); - - expect(await this.mock.hasRole(DEFAULT_ADMIN_ROLE, this.defaultAdmin)).to.be.false; - expect(await this.mock.defaultAdmin()).to.equal(ethers.ZeroAddress); - expect(await this.mock.owner()).to.equal(ethers.ZeroAddress); - - const { newAdmin, schedule } = await this.mock.pendingDefaultAdmin(); - expect(newAdmin).to.equal(ethers.ZeroAddress); - expect(schedule).to.equal(0); - }); - - it('allows to recover access using the internal _grantRole', async function () { - await time.increaseBy.timestamp(this.delay + 1n, false); - await this.mock.connect(this.defaultAdmin).renounceRole(DEFAULT_ADMIN_ROLE, this.defaultAdmin); - - await expect(this.mock.connect(this.defaultAdmin).$_grantRole(DEFAULT_ADMIN_ROLE, this.other)) - .to.emit(this.mock, 'RoleGranted') - .withArgs(DEFAULT_ADMIN_ROLE, this.other, this.defaultAdmin); - }); - - describe('schedule not passed', function () { - for (const [fromSchedule, tag] of [ - [-1n, 'less'], - [0n, 'equal'], - ]) { - it(`reverts if block.timestamp is ${tag} to schedule`, async function () { - await time.increaseBy.timestamp(this.delay + fromSchedule, false); - await expect(this.mock.connect(this.defaultAdmin).renounceRole(DEFAULT_ADMIN_ROLE, this.defaultAdmin)) - .to.be.revertedWithCustomError(this.mock, 'AccessControlEnforcedDefaultAdminDelay') - .withArgs(this.expectedSchedule); - }); - } - }); - }); - - describe('changes delay', function () { - it('reverts if called by non default admin accounts', async function () { - await expect(this.mock.connect(this.other).changeDefaultAdminDelay(time.duration.hours(4))) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.other, DEFAULT_ADMIN_ROLE); - }); - - for (const [delayDifference, delayChangeType] of [ - [time.duration.hours(-1), 'decreased'], - [time.duration.hours(1), 'increased'], - [time.duration.days(5), 'increased to more than 5 days'], - ]) { - describe(`when the delay is ${delayChangeType}`, function () { - beforeEach(function () { - this.newDefaultAdminDelay = this.delay + delayDifference; - }); - - it('begins the delay change to the new delay', async function () { - // Calculate expected values - const capWait = await this.mock.defaultAdminDelayIncreaseWait(); - const minWait = capWait < this.newDefaultAdminDelay ? capWait : this.newDefaultAdminDelay; - const changeDelay = - this.newDefaultAdminDelay <= this.delay ? this.delay - this.newDefaultAdminDelay : minWait; - const nextBlockTimestamp = (await time.clock.timestamp()) + 1n; - const effectSchedule = nextBlockTimestamp + changeDelay; - - await time.increaseTo.timestamp(nextBlockTimestamp, false); - - // Begins the change - await expect(this.mock.connect(this.defaultAdmin).changeDefaultAdminDelay(this.newDefaultAdminDelay)) - .to.emit(this.mock, 'DefaultAdminDelayChangeScheduled') - .withArgs(this.newDefaultAdminDelay, effectSchedule); - - // Assert - const { newDelay, schedule } = await this.mock.pendingDefaultAdminDelay(); - expect(newDelay).to.equal(this.newDefaultAdminDelay); - expect(schedule).to.equal(effectSchedule); - }); - - describe('scheduling again', function () { - beforeEach('schedule once', async function () { - await this.mock.connect(this.defaultAdmin).changeDefaultAdminDelay(this.newDefaultAdminDelay); - }); - - for (const [fromSchedule, tag] of [ - [-1n, 'before'], - [0n, 'exactly when'], - [1n, 'after'], - ]) { - const passed = fromSchedule > 0; - - it(`succeeds ${tag} the delay schedule passes`, async function () { - // Wait until schedule + fromSchedule - const { schedule: firstSchedule } = await this.mock.pendingDefaultAdminDelay(); - const nextBlockTimestamp = firstSchedule + fromSchedule; - await time.increaseTo.timestamp(nextBlockTimestamp, false); - - // Calculate expected values - const anotherNewDefaultAdminDelay = this.newDefaultAdminDelay + time.duration.hours(2); - const capWait = await this.mock.defaultAdminDelayIncreaseWait(); - const minWait = capWait < anotherNewDefaultAdminDelay ? capWait : anotherNewDefaultAdminDelay; - const effectSchedule = nextBlockTimestamp + minWait; - - // Default admin changes its mind and begins another delay change - await expect(this.mock.connect(this.defaultAdmin).changeDefaultAdminDelay(anotherNewDefaultAdminDelay)) - .to.emit(this.mock, 'DefaultAdminDelayChangeScheduled') - .withArgs(anotherNewDefaultAdminDelay, effectSchedule); - - // Assert - const { newDelay, schedule } = await this.mock.pendingDefaultAdminDelay(); - expect(newDelay).to.equal(anotherNewDefaultAdminDelay); - expect(schedule).to.equal(effectSchedule); - }); - - const emit = passed ? 'not emit' : 'emit'; - it(`should ${emit} a cancellation event ${tag} the delay schedule passes`, async function () { - // Wait until schedule + fromSchedule - const { schedule: firstSchedule } = await this.mock.pendingDefaultAdminDelay(); - await time.increaseTo.timestamp(firstSchedule + fromSchedule, false); - - // Default admin changes its mind and begins another delay change - const anotherNewDefaultAdminDelay = this.newDefaultAdminDelay + time.duration.hours(2); - - const expected = expect( - this.mock.connect(this.defaultAdmin).changeDefaultAdminDelay(anotherNewDefaultAdminDelay), - ); - if (passed) { - await expected.to.not.emit(this.mock, 'DefaultAdminDelayChangeCanceled'); - } else { - await expected.to.emit(this.mock, 'DefaultAdminDelayChangeCanceled'); - } - }); - } - }); - }); - } - }); - - describe('rollbacks a delay change', function () { - it('reverts if called by non default admin accounts', async function () { - await expect(this.mock.connect(this.other).rollbackDefaultAdminDelay()) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.other, DEFAULT_ADMIN_ROLE); - }); - - describe('when there is a pending delay', function () { - beforeEach('set pending delay', async function () { - await this.mock.connect(this.defaultAdmin).changeDefaultAdminDelay(time.duration.hours(12)); - }); - - for (const [fromSchedule, tag] of [ - [-1n, 'before'], - [0n, 'exactly when'], - [1n, 'after'], - ]) { - const passed = fromSchedule > 0; - - it(`resets pending delay and schedule ${tag} delay change schedule passes`, async function () { - // Wait until schedule + fromSchedule - const { schedule: firstSchedule } = await this.mock.pendingDefaultAdminDelay(); - await time.increaseTo.timestamp(firstSchedule + fromSchedule, false); - - await this.mock.connect(this.defaultAdmin).rollbackDefaultAdminDelay(); - - const { newDelay, schedule } = await this.mock.pendingDefaultAdminDelay(); - expect(newDelay).to.equal(0); - expect(schedule).to.equal(0); - }); - - const emit = passed ? 'not emit' : 'emit'; - it(`should ${emit} a cancellation event ${tag} the delay schedule passes`, async function () { - // Wait until schedule + fromSchedule - const { schedule: firstSchedule } = await this.mock.pendingDefaultAdminDelay(); - await time.increaseTo.timestamp(firstSchedule + fromSchedule, false); - - const expected = expect(this.mock.connect(this.defaultAdmin).rollbackDefaultAdminDelay()); - if (passed) { - await expected.to.not.emit(this.mock, 'DefaultAdminDelayChangeCanceled'); - } else { - await expected.to.emit(this.mock, 'DefaultAdminDelayChangeCanceled'); - } - }); - } - }); - - describe('when there is no pending delay', function () { - it('succeeds without changes', async function () { - await this.mock.connect(this.defaultAdmin).rollbackDefaultAdminDelay(); - - const { newDelay, schedule } = await this.mock.pendingDefaultAdminDelay(); - expect(newDelay).to.equal(0); - expect(schedule).to.equal(0); - }); - }); - }); -} - -module.exports = { - DEFAULT_ADMIN_ROLE, - shouldBehaveLikeAccessControl, - shouldBehaveLikeAccessControlEnumerable, - shouldBehaveLikeAccessControlDefaultAdminRules, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/AccessControl.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/AccessControl.test.js deleted file mode 100644 index 5c70cdc6d7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/AccessControl.test.js +++ /dev/null @@ -1,19 +0,0 @@ -const { ethers } = require('hardhat'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { DEFAULT_ADMIN_ROLE, shouldBehaveLikeAccessControl } = require('./AccessControl.behavior'); - -async function fixture() { - const [defaultAdmin, ...accounts] = await ethers.getSigners(); - const mock = await ethers.deployContract('$AccessControl'); - await mock.$_grantRole(DEFAULT_ADMIN_ROLE, defaultAdmin); - return { mock, defaultAdmin, accounts }; -} - -describe('AccessControl', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeAccessControl(); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/Ownable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/Ownable.test.js deleted file mode 100644 index 2d9b561a1d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/Ownable.test.js +++ /dev/null @@ -1,79 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -async function fixture() { - const [owner, other] = await ethers.getSigners(); - const ownable = await ethers.deployContract('$Ownable', [owner]); - return { owner, other, ownable }; -} - -describe('Ownable', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('emits ownership transfer events during construction', async function () { - await expect(this.ownable.deploymentTransaction()) - .to.emit(this.ownable, 'OwnershipTransferred') - .withArgs(ethers.ZeroAddress, this.owner); - }); - - it('rejects zero address for initialOwner', async function () { - await expect(ethers.deployContract('$Ownable', [ethers.ZeroAddress])) - .to.be.revertedWithCustomError({ interface: this.ownable.interface }, 'OwnableInvalidOwner') - .withArgs(ethers.ZeroAddress); - }); - - it('has an owner', async function () { - expect(await this.ownable.owner()).to.equal(this.owner); - }); - - describe('transfer ownership', function () { - it('changes owner after transfer', async function () { - await expect(this.ownable.connect(this.owner).transferOwnership(this.other)) - .to.emit(this.ownable, 'OwnershipTransferred') - .withArgs(this.owner, this.other); - - expect(await this.ownable.owner()).to.equal(this.other); - }); - - it('prevents non-owners from transferring', async function () { - await expect(this.ownable.connect(this.other).transferOwnership(this.other)) - .to.be.revertedWithCustomError(this.ownable, 'OwnableUnauthorizedAccount') - .withArgs(this.other); - }); - - it('guards ownership against stuck state', async function () { - await expect(this.ownable.connect(this.owner).transferOwnership(ethers.ZeroAddress)) - .to.be.revertedWithCustomError(this.ownable, 'OwnableInvalidOwner') - .withArgs(ethers.ZeroAddress); - }); - }); - - describe('renounce ownership', function () { - it('loses ownership after renouncement', async function () { - await expect(this.ownable.connect(this.owner).renounceOwnership()) - .to.emit(this.ownable, 'OwnershipTransferred') - .withArgs(this.owner, ethers.ZeroAddress); - - expect(await this.ownable.owner()).to.equal(ethers.ZeroAddress); - }); - - it('prevents non-owners from renouncement', async function () { - await expect(this.ownable.connect(this.other).renounceOwnership()) - .to.be.revertedWithCustomError(this.ownable, 'OwnableUnauthorizedAccount') - .withArgs(this.other); - }); - - it('allows to recover access using the internal _transferOwnership', async function () { - await this.ownable.connect(this.owner).renounceOwnership(); - - await expect(this.ownable.$_transferOwnership(this.other)) - .to.emit(this.ownable, 'OwnershipTransferred') - .withArgs(ethers.ZeroAddress, this.other); - - expect(await this.ownable.owner()).to.equal(this.other); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/Ownable2Step.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/Ownable2Step.test.js deleted file mode 100644 index 5620a24913..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/Ownable2Step.test.js +++ /dev/null @@ -1,102 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -async function fixture() { - const [owner, accountA, accountB] = await ethers.getSigners(); - const ownable2Step = await ethers.deployContract('$Ownable2Step', [owner]); - return { - ownable2Step, - owner, - accountA, - accountB, - }; -} - -describe('Ownable2Step', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('transfer ownership', function () { - it('starting a transfer does not change owner', async function () { - await expect(this.ownable2Step.connect(this.owner).transferOwnership(this.accountA)) - .to.emit(this.ownable2Step, 'OwnershipTransferStarted') - .withArgs(this.owner, this.accountA); - - expect(await this.ownable2Step.owner()).to.equal(this.owner); - expect(await this.ownable2Step.pendingOwner()).to.equal(this.accountA); - }); - - it('changes owner after transfer', async function () { - await this.ownable2Step.connect(this.owner).transferOwnership(this.accountA); - - await expect(this.ownable2Step.connect(this.accountA).acceptOwnership()) - .to.emit(this.ownable2Step, 'OwnershipTransferred') - .withArgs(this.owner, this.accountA); - - expect(await this.ownable2Step.owner()).to.equal(this.accountA); - expect(await this.ownable2Step.pendingOwner()).to.equal(ethers.ZeroAddress); - }); - - it('guards transfer against invalid user', async function () { - await this.ownable2Step.connect(this.owner).transferOwnership(this.accountA); - - await expect(this.ownable2Step.connect(this.accountB).acceptOwnership()) - .to.be.revertedWithCustomError(this.ownable2Step, 'OwnableUnauthorizedAccount') - .withArgs(this.accountB); - }); - }); - - describe('renouncing ownership', function () { - it('changes owner after renouncing ownership', async function () { - await expect(this.ownable2Step.connect(this.owner).renounceOwnership()) - .to.emit(this.ownable2Step, 'OwnershipTransferred') - .withArgs(this.owner, ethers.ZeroAddress); - - // If renounceOwnership is removed from parent an alternative is needed ... - // without it is difficult to cleanly renounce with the two step process - // see: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/3620#discussion_r957930388 - expect(await this.ownable2Step.owner()).to.equal(ethers.ZeroAddress); - }); - - it('pending owner resets after renouncing ownership', async function () { - await this.ownable2Step.connect(this.owner).transferOwnership(this.accountA); - expect(await this.ownable2Step.pendingOwner()).to.equal(this.accountA); - - await this.ownable2Step.connect(this.owner).renounceOwnership(); - expect(await this.ownable2Step.pendingOwner()).to.equal(ethers.ZeroAddress); - - await expect(this.ownable2Step.connect(this.accountA).acceptOwnership()) - .to.be.revertedWithCustomError(this.ownable2Step, 'OwnableUnauthorizedAccount') - .withArgs(this.accountA); - }); - - it('allows to recover access using the internal _transferOwnership', async function () { - await this.ownable2Step.connect(this.owner).renounceOwnership(); - - await expect(this.ownable2Step.$_transferOwnership(this.accountA)) - .to.emit(this.ownable2Step, 'OwnershipTransferred') - .withArgs(ethers.ZeroAddress, this.accountA); - - expect(await this.ownable2Step.owner()).to.equal(this.accountA); - }); - - it('allows the owner to cancel an initiated ownership transfer by setting newOwner to zero address', async function () { - // initiate ownership transfer to accountA - await this.ownable2Step.connect(this.owner).transferOwnership(this.accountA); - expect(await this.ownable2Step.pendingOwner()).to.equal(this.accountA); - - // cancel the ownership transfer by setting newOwner to zero address - await expect(this.ownable2Step.connect(this.owner).transferOwnership(ethers.ZeroAddress)) - .to.emit(this.ownable2Step, 'OwnershipTransferStarted') - .withArgs(this.owner, ethers.ZeroAddress); - expect(await this.ownable2Step.pendingOwner()).to.equal(ethers.ZeroAddress); - - // verify that accountA cannot accept ownership anymore - await expect(this.ownable2Step.connect(this.accountA).acceptOwnership()) - .to.be.revertedWithCustomError(this.ownable2Step, 'OwnableUnauthorizedAccount') - .withArgs(this.accountA); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/extensions/AccessControlDefaultAdminRules.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/extensions/AccessControlDefaultAdminRules.test.js deleted file mode 100644 index 48036fd9bc..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/extensions/AccessControlDefaultAdminRules.test.js +++ /dev/null @@ -1,32 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const time = require('../../helpers/time'); - -const { - shouldBehaveLikeAccessControl, - shouldBehaveLikeAccessControlDefaultAdminRules, -} = require('../AccessControl.behavior'); - -async function fixture() { - const delay = time.duration.hours(10); - const [defaultAdmin, ...accounts] = await ethers.getSigners(); - const mock = await ethers.deployContract('$AccessControlDefaultAdminRules', [delay, defaultAdmin]); - return { mock, defaultAdmin, delay, accounts }; -} - -describe('AccessControlDefaultAdminRules', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('initial admin not zero', async function () { - await expect(ethers.deployContract('$AccessControlDefaultAdminRules', [this.delay, ethers.ZeroAddress])) - .to.be.revertedWithCustomError(this.mock, 'AccessControlInvalidDefaultAdmin') - .withArgs(ethers.ZeroAddress); - }); - - shouldBehaveLikeAccessControl(); - shouldBehaveLikeAccessControlDefaultAdminRules(); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/extensions/AccessControlEnumerable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/extensions/AccessControlEnumerable.test.js deleted file mode 100644 index ea1a8c46f2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/extensions/AccessControlEnumerable.test.js +++ /dev/null @@ -1,24 +0,0 @@ -const { ethers } = require('hardhat'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { - DEFAULT_ADMIN_ROLE, - shouldBehaveLikeAccessControl, - shouldBehaveLikeAccessControlEnumerable, -} = require('../AccessControl.behavior'); - -async function fixture() { - const [defaultAdmin, ...accounts] = await ethers.getSigners(); - const mock = await ethers.deployContract('$AccessControlEnumerable'); - await mock.$_grantRole(DEFAULT_ADMIN_ROLE, defaultAdmin); - return { mock, defaultAdmin, accounts }; -} - -describe('AccessControlEnumerable', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeAccessControl(); - shouldBehaveLikeAccessControlEnumerable(); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AccessManaged.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AccessManaged.test.js deleted file mode 100644 index d666b5e6dc..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AccessManaged.test.js +++ /dev/null @@ -1,146 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { impersonate } = require('../../helpers/account'); -const time = require('../../helpers/time'); - -async function fixture() { - const [admin, roleMember, other] = await ethers.getSigners(); - - const authority = await ethers.deployContract('$AccessManager', [admin]); - const managed = await ethers.deployContract('$AccessManagedTarget', [authority]); - - const anotherAuthority = await ethers.deployContract('$AccessManager', [admin]); - const authorityObserveIsConsuming = await ethers.deployContract('$AuthorityObserveIsConsuming'); - - await impersonate(authority.target); - const authorityAsSigner = await ethers.getSigner(authority.target); - - return { - roleMember, - other, - authorityAsSigner, - authority, - managed, - authorityObserveIsConsuming, - anotherAuthority, - }; -} - -describe('AccessManaged', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('sets authority and emits AuthorityUpdated event during construction', async function () { - await expect(this.managed.deploymentTransaction()) - .to.emit(this.managed, 'AuthorityUpdated') - .withArgs(this.authority); - }); - - describe('restricted modifier', function () { - beforeEach(async function () { - this.selector = this.managed.fnRestricted.getFragment().selector; - this.role = 42n; - await this.authority.$_setTargetFunctionRole(this.managed, this.selector, this.role); - await this.authority.$_grantRole(this.role, this.roleMember, 0, 0); - }); - - it('succeeds when role is granted without execution delay', async function () { - await this.managed.connect(this.roleMember)[this.selector](); - }); - - it('reverts when role is not granted', async function () { - await expect(this.managed.connect(this.other)[this.selector]()) - .to.be.revertedWithCustomError(this.managed, 'AccessManagedUnauthorized') - .withArgs(this.other); - }); - - it('panics in short calldata', async function () { - // We avoid adding the `restricted` modifier to the fallback function because other tests may depend on it - // being accessible without restrictions. We check for the internal `_checkCanCall` instead. - await expect(this.managed.$_checkCanCall(this.roleMember, '0x1234')).to.be.reverted; - }); - - describe('when role is granted with execution delay', function () { - beforeEach(async function () { - const executionDelay = 911n; - await this.authority.$_grantRole(this.role, this.roleMember, 0, executionDelay); - }); - - it('reverts if the operation is not scheduled', async function () { - const fn = this.managed.interface.getFunction(this.selector); - const calldata = this.managed.interface.encodeFunctionData(fn, []); - const opId = await this.authority.hashOperation(this.roleMember, this.managed, calldata); - - await expect(this.managed.connect(this.roleMember)[this.selector]()) - .to.be.revertedWithCustomError(this.authority, 'AccessManagerNotScheduled') - .withArgs(opId); - }); - - it('succeeds if the operation is scheduled', async function () { - // Arguments - const delay = time.duration.hours(12); - const fn = this.managed.interface.getFunction(this.selector); - const calldata = this.managed.interface.encodeFunctionData(fn, []); - - // Schedule - const scheduledAt = (await time.clock.timestamp()) + 1n; - const when = scheduledAt + delay; - await time.increaseTo.timestamp(scheduledAt, false); - await this.authority.connect(this.roleMember).schedule(this.managed, calldata, when); - - // Set execution date - await time.increaseTo.timestamp(when, false); - - // Shouldn't revert - await this.managed.connect(this.roleMember)[this.selector](); - }); - }); - }); - - describe('setAuthority', function () { - it('reverts if the caller is not the authority', async function () { - await expect(this.managed.connect(this.other).setAuthority(this.other)) - .to.be.revertedWithCustomError(this.managed, 'AccessManagedUnauthorized') - .withArgs(this.other); - }); - - it('reverts if the new authority is not a valid authority', async function () { - await expect(this.managed.connect(this.authorityAsSigner).setAuthority(this.other)) - .to.be.revertedWithCustomError(this.managed, 'AccessManagedInvalidAuthority') - .withArgs(this.other); - }); - - it('sets authority and emits AuthorityUpdated event', async function () { - await expect(this.managed.connect(this.authorityAsSigner).setAuthority(this.anotherAuthority)) - .to.emit(this.managed, 'AuthorityUpdated') - .withArgs(this.anotherAuthority); - - expect(await this.managed.authority()).to.equal(this.anotherAuthority); - }); - }); - - describe('isConsumingScheduledOp', function () { - beforeEach(async function () { - await this.managed.connect(this.authorityAsSigner).setAuthority(this.authorityObserveIsConsuming); - }); - - it('returns bytes4(0) when not consuming operation', async function () { - expect(await this.managed.isConsumingScheduledOp()).to.equal('0x00000000'); - }); - - it('returns isConsumingScheduledOp selector when consuming operation', async function () { - const isConsumingScheduledOp = this.managed.interface.getFunction('isConsumingScheduledOp()'); - const fnRestricted = this.managed.fnRestricted.getFragment(); - await expect(this.managed.connect(this.other).fnRestricted()) - .to.emit(this.authorityObserveIsConsuming, 'ConsumeScheduledOpCalled') - .withArgs( - this.other, - this.managed.interface.encodeFunctionData(fnRestricted, []), - isConsumingScheduledOp.selector, - ); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AccessManager.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AccessManager.behavior.js deleted file mode 100644 index 385da578c0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AccessManager.behavior.js +++ /dev/null @@ -1,257 +0,0 @@ -const { expect } = require('chai'); - -const { - LIKE_COMMON_IS_EXECUTING, - LIKE_COMMON_GET_ACCESS, - LIKE_COMMON_SCHEDULABLE, - testAsSchedulableOperation, - testAsRestrictedOperation, - testAsDelayedOperation, - testAsCanCall, - testAsHasRole, -} = require('./AccessManager.predicate'); - -// ============ ADMIN OPERATION ============ - -/** - * @requires this.{manager,roles,calldata,role} - */ -function shouldBehaveLikeDelayedAdminOperation() { - const getAccessPath = LIKE_COMMON_GET_ACCESS; - testAsDelayedOperation.mineDelay = true; - getAccessPath.requiredRoleIsGranted.roleGrantingIsDelayed.callerHasAnExecutionDelay.afterGrantDelay = - testAsDelayedOperation; - getAccessPath.requiredRoleIsGranted.roleGrantingIsNotDelayed.callerHasAnExecutionDelay = function () { - beforeEach('set execution delay', async function () { - this.scheduleIn = this.executionDelay; // For testAsDelayedOperation - }); - testAsSchedulableOperation(LIKE_COMMON_SCHEDULABLE); - }; - - beforeEach('set target as manager', function () { - this.target = this.manager; - }); - - testAsRestrictedOperation({ - callerIsTheManager: LIKE_COMMON_IS_EXECUTING, - callerIsNotTheManager() { - testAsHasRole({ - publicRoleIsRequired() { - it('reverts as AccessManagerUnauthorizedAccount', async function () { - await expect(this.caller.sendTransaction({ to: this.target, data: this.calldata })) - .to.be.revertedWithCustomError(this.target, 'AccessManagerUnauthorizedAccount') - .withArgs( - this.caller, - this.roles.ADMIN.id, // Although PUBLIC is required, target function role doesn't apply to admin ops - ); - }); - }, - specificRoleIsRequired: getAccessPath, - }); - }, - }); -} - -/** - * @requires this.{manager,roles,calldata,role} - */ -function shouldBehaveLikeNotDelayedAdminOperation() { - const getAccessPath = LIKE_COMMON_GET_ACCESS; - - function testScheduleOperation(mineDelay) { - return function self() { - self.mineDelay = mineDelay; - beforeEach('set execution delay', async function () { - this.scheduleIn = this.executionDelay; // For testAsSchedulableOperation - }); - testAsSchedulableOperation(LIKE_COMMON_SCHEDULABLE); - }; - } - - getAccessPath.requiredRoleIsGranted.roleGrantingIsDelayed.callerHasAnExecutionDelay.afterGrantDelay = - testScheduleOperation(true); - getAccessPath.requiredRoleIsGranted.roleGrantingIsNotDelayed.callerHasAnExecutionDelay = testScheduleOperation(false); - - beforeEach('set target as manager', function () { - this.target = this.manager; - }); - - testAsRestrictedOperation({ - callerIsTheManager: LIKE_COMMON_IS_EXECUTING, - callerIsNotTheManager() { - testAsHasRole({ - publicRoleIsRequired() { - it('reverts as AccessManagerUnauthorizedAccount', async function () { - await expect(this.caller.sendTransaction({ to: this.target, data: this.calldata })) - .to.be.revertedWithCustomError(this.target, 'AccessManagerUnauthorizedAccount') - .withArgs( - this.caller, - this.roles.ADMIN.id, // Although PUBLIC_ROLE is required, admin ops are not subject to target function roles - ); - }); - }, - specificRoleIsRequired: getAccessPath, - }); - }, - }); -} - -/** - * @requires this.{manager,roles,calldata,role} - */ -function shouldBehaveLikeRoleAdminOperation(roleAdmin) { - const getAccessPath = LIKE_COMMON_GET_ACCESS; - - function afterGrantDelay() { - afterGrantDelay.mineDelay = true; - beforeEach('set execution delay', async function () { - this.scheduleIn = this.executionDelay; // For testAsSchedulableOperation - }); - testAsSchedulableOperation(LIKE_COMMON_SCHEDULABLE); - } - - getAccessPath.requiredRoleIsGranted.roleGrantingIsDelayed.callerHasAnExecutionDelay.afterGrantDelay = afterGrantDelay; - getAccessPath.requiredRoleIsGranted.roleGrantingIsNotDelayed.callerHasAnExecutionDelay = afterGrantDelay; - - beforeEach('set target as manager', function () { - this.target = this.manager; - }); - - testAsRestrictedOperation({ - callerIsTheManager: LIKE_COMMON_IS_EXECUTING, - callerIsNotTheManager() { - testAsHasRole({ - publicRoleIsRequired() { - it('reverts as AccessManagerUnauthorizedAccount', async function () { - await expect(this.caller.sendTransaction({ to: this.target, data: this.calldata })) - .to.be.revertedWithCustomError(this.target, 'AccessManagerUnauthorizedAccount') - .withArgs(this.caller, roleAdmin); - }); - }, - specificRoleIsRequired: getAccessPath, - }); - }, - }); -} - -// ============ RESTRICTED OPERATION ============ - -/** - * @requires this.{manager,roles,calldata,role} - */ -function shouldBehaveLikeAManagedRestrictedOperation() { - function revertUnauthorized() { - it('reverts as AccessManagedUnauthorized', async function () { - await expect(this.caller.sendTransaction({ to: this.target, data: this.calldata })) - .to.be.revertedWithCustomError(this.target, 'AccessManagedUnauthorized') - .withArgs(this.caller); - }); - } - - const getAccessPath = LIKE_COMMON_GET_ACCESS; - - getAccessPath.requiredRoleIsGranted.roleGrantingIsDelayed.callerHasAnExecutionDelay.beforeGrantDelay = - revertUnauthorized; - getAccessPath.requiredRoleIsGranted.roleGrantingIsDelayed.callerHasNoExecutionDelay.beforeGrantDelay = - revertUnauthorized; - getAccessPath.requiredRoleIsNotGranted = revertUnauthorized; - - function testScheduleOperation(mineDelay) { - return function self() { - self.mineDelay = mineDelay; - beforeEach('sets execution delay', async function () { - this.scheduleIn = this.executionDelay; // For testAsSchedulableOperation - }); - testAsSchedulableOperation(LIKE_COMMON_SCHEDULABLE); - }; - } - - getAccessPath.requiredRoleIsGranted.roleGrantingIsDelayed.callerHasAnExecutionDelay.afterGrantDelay = - testScheduleOperation(true); - getAccessPath.requiredRoleIsGranted.roleGrantingIsNotDelayed.callerHasAnExecutionDelay = testScheduleOperation(false); - - const isExecutingPath = LIKE_COMMON_IS_EXECUTING; - isExecutingPath.notExecuting = revertUnauthorized; - - testAsCanCall({ - closed: revertUnauthorized, - open: { - callerIsTheManager: isExecutingPath, - callerIsNotTheManager: { - publicRoleIsRequired() { - it('succeeds called directly', async function () { - await this.caller.sendTransaction({ to: this.target, data: this.calldata }); - }); - - it('succeeds via execute', async function () { - await this.manager.connect(this.caller).execute(this.target, this.calldata); - }); - }, - specificRoleIsRequired: getAccessPath, - }, - }, - }); -} - -/** - * @requires this.{target,manager,roles,calldata,role} - */ -function shouldBehaveLikeASelfRestrictedOperation() { - function revertUnauthorized() { - it('reverts as AccessManagerUnauthorizedAccount', async function () { - await expect(this.caller.sendTransaction({ to: this.target, data: this.calldata })) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedAccount') - .withArgs(this.caller, this.role?.id ?? 0n); - }); - } - - const getAccessPath = LIKE_COMMON_GET_ACCESS; - - function testScheduleOperation(mineDelay) { - return function self() { - self.mineDelay = mineDelay; - beforeEach('sets execution delay', async function () { - this.scheduleIn = this.executionDelay; // For testAsSchedulableOperation - }); - testAsSchedulableOperation(LIKE_COMMON_SCHEDULABLE); - }; - } - - getAccessPath.requiredRoleIsGranted.roleGrantingIsDelayed.callerHasAnExecutionDelay.afterGrantDelay = - testScheduleOperation(true); - getAccessPath.requiredRoleIsGranted.roleGrantingIsNotDelayed.callerHasAnExecutionDelay = testScheduleOperation(false); - - beforeEach('set target as manager', function () { - this.target = this.manager; - }); - - const isExecutingPath = LIKE_COMMON_IS_EXECUTING; - isExecutingPath.notExecuting = revertUnauthorized; - - testAsCanCall({ - closed: revertUnauthorized, - open: { - callerIsTheManager: isExecutingPath, - callerIsNotTheManager: { - publicRoleIsRequired() { - it('succeeds called directly', async function () { - await this.caller.sendTransaction({ to: this.target, data: this.calldata }); - }); - - it('succeeds via execute', async function () { - await this.manager.connect(this.caller).execute(this.target, this.calldata); - }); - }, - specificRoleIsRequired: getAccessPath, - }, - }, - }); -} - -module.exports = { - shouldBehaveLikeDelayedAdminOperation, - shouldBehaveLikeNotDelayedAdminOperation, - shouldBehaveLikeRoleAdminOperation, - shouldBehaveLikeAManagedRestrictedOperation, - shouldBehaveLikeASelfRestrictedOperation, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AccessManager.predicate.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AccessManager.predicate.js deleted file mode 100644 index 8b4c5f4b64..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AccessManager.predicate.js +++ /dev/null @@ -1,456 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { setStorageAt } = require('@nomicfoundation/hardhat-network-helpers'); - -const { EXECUTION_ID_STORAGE_SLOT, EXPIRATION, prepareOperation } = require('../../helpers/access-manager'); -const { impersonate } = require('../../helpers/account'); -const time = require('../../helpers/time'); - -// ============ COMMON PREDICATES ============ - -const LIKE_COMMON_IS_EXECUTING = { - executing() { - it('succeeds', async function () { - await this.caller.sendTransaction({ to: this.target, data: this.calldata }); - }); - }, - notExecuting() { - it('reverts as AccessManagerUnauthorizedAccount', async function () { - await expect(this.caller.sendTransaction({ to: this.target, data: this.calldata })) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedAccount') - .withArgs(this.caller, this.role.id); - }); - }, -}; - -const LIKE_COMMON_GET_ACCESS = { - requiredRoleIsGranted: { - roleGrantingIsDelayed: { - callerHasAnExecutionDelay: { - beforeGrantDelay() { - it('reverts as AccessManagerUnauthorizedAccount', async function () { - await expect(this.caller.sendTransaction({ to: this.target, data: this.calldata })) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedAccount') - .withArgs(this.caller, this.role.id); - }); - }, - afterGrantDelay: undefined, // Diverges if there's an operation delay or not - }, - callerHasNoExecutionDelay: { - beforeGrantDelay() { - it('reverts as AccessManagerUnauthorizedAccount', async function () { - await expect(this.caller.sendTransaction({ to: this.target, data: this.calldata })) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedAccount') - .withArgs(this.caller, this.role.id); - }); - }, - afterGrantDelay() { - it('succeeds called directly', async function () { - await this.caller.sendTransaction({ to: this.target, data: this.calldata }); - }); - - it('succeeds via execute', async function () { - await this.manager.connect(this.caller).execute(this.target, this.calldata); - }); - }, - }, - }, - roleGrantingIsNotDelayed: { - callerHasAnExecutionDelay: undefined, // Diverges if there's an operation to schedule or not - callerHasNoExecutionDelay() { - it('succeeds called directly', async function () { - await this.caller.sendTransaction({ to: this.target, data: this.calldata }); - }); - - it('succeeds via execute', async function () { - await this.manager.connect(this.caller).execute(this.target, this.calldata); - }); - }, - }, - }, - requiredRoleIsNotGranted() { - it('reverts as AccessManagerUnauthorizedAccount', async function () { - await expect(this.caller.sendTransaction({ to: this.target, data: this.calldata })) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedAccount') - .withArgs(this.caller, this.role.id); - }); - }, -}; - -const LIKE_COMMON_SCHEDULABLE = { - scheduled: { - before() { - it('reverts as AccessManagerNotReady', async function () { - await expect(this.caller.sendTransaction({ to: this.target, data: this.calldata })) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerNotReady') - .withArgs(this.operationId); - }); - }, - after() { - it('succeeds called directly', async function () { - await this.caller.sendTransaction({ to: this.target, data: this.calldata }); - }); - - it('succeeds via execute', async function () { - await this.manager.connect(this.caller).execute(this.target, this.calldata); - }); - }, - expired() { - it('reverts as AccessManagerExpired', async function () { - await expect(this.caller.sendTransaction({ to: this.target, data: this.calldata })) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerExpired') - .withArgs(this.operationId); - }); - }, - }, - notScheduled() { - it('reverts as AccessManagerNotScheduled', async function () { - await expect(this.caller.sendTransaction({ to: this.target, data: this.calldata })) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerNotScheduled') - .withArgs(this.operationId); - }); - }, -}; - -// ============ MODE ============ - -/** - * @requires this.{manager,target} - */ -function testAsClosable({ closed, open }) { - describe('when the manager is closed', function () { - beforeEach('close', async function () { - await this.manager.$_setTargetClosed(this.target, true); - }); - - closed(); - }); - - describe('when the manager is open', function () { - beforeEach('open', async function () { - await this.manager.$_setTargetClosed(this.target, false); - }); - - open(); - }); -} - -// ============ DELAY ============ - -/** - * @requires this.{delay} - */ -function testAsDelay(type, { before, after }) { - beforeEach('define timestamp when delay takes effect', async function () { - const timestamp = await time.clock.timestamp(); - this.delayEffect = timestamp + this.delay; - }); - - describe(`when ${type} delay has not taken effect yet`, function () { - beforeEach(`set next block timestamp before ${type} takes effect`, async function () { - await time.increaseTo.timestamp(this.delayEffect - 1n, !!before.mineDelay); - }); - - before(); - }); - - describe(`when ${type} delay has taken effect`, function () { - beforeEach(`set next block timestamp when ${type} takes effect`, async function () { - await time.increaseTo.timestamp(this.delayEffect, !!after.mineDelay); - }); - - after(); - }); -} - -// ============ OPERATION ============ - -/** - * @requires this.{manager,scheduleIn,caller,target,calldata} - */ -function testAsSchedulableOperation({ scheduled: { before, after, expired }, notScheduled }) { - describe('when operation is scheduled', function () { - beforeEach('schedule operation', async function () { - if (this.caller.target) { - await impersonate(this.caller.target); - this.caller = await ethers.getSigner(this.caller.target); - } - const { operationId, schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.scheduleIn, - }); - await schedule(); - this.operationId = operationId; - }); - - describe('when operation is not ready for execution', function () { - beforeEach('set next block time before operation is ready', async function () { - this.scheduledAt = await time.clock.timestamp(); - const schedule = await this.manager.getSchedule(this.operationId); - await time.increaseTo.timestamp(schedule - 1n, !!before.mineDelay); - }); - - before(); - }); - - describe('when operation is ready for execution', function () { - beforeEach('set next block time when operation is ready for execution', async function () { - this.scheduledAt = await time.clock.timestamp(); - const schedule = await this.manager.getSchedule(this.operationId); - await time.increaseTo.timestamp(schedule, !!after.mineDelay); - }); - - after(); - }); - - describe('when operation has expired', function () { - beforeEach('set next block time when operation expired', async function () { - this.scheduledAt = await time.clock.timestamp(); - const schedule = await this.manager.getSchedule(this.operationId); - await time.increaseTo.timestamp(schedule + EXPIRATION, !!expired.mineDelay); - }); - - expired(); - }); - }); - - describe('when operation is not scheduled', function () { - beforeEach('set expected operationId', async function () { - this.operationId = await this.manager.hashOperation(this.caller, this.target, this.calldata); - - // Assert operation is not scheduled - expect(await this.manager.getSchedule(this.operationId)).to.equal(0n); - }); - - notScheduled(); - }); -} - -/** - * @requires this.{manager,roles,target,calldata} - */ -function testAsRestrictedOperation({ callerIsTheManager: { executing, notExecuting }, callerIsNotTheManager }) { - describe('when the call comes from the manager (msg.sender == manager)', function () { - beforeEach('define caller as manager', async function () { - this.caller = this.manager; - if (this.caller.target) { - await impersonate(this.caller.target); - this.caller = await ethers.getSigner(this.caller.target); - } - }); - - describe('when _executionId is in storage for target and selector', function () { - beforeEach('set _executionId flag from calldata and target', async function () { - const executionId = ethers.keccak256( - ethers.AbiCoder.defaultAbiCoder().encode( - ['address', 'bytes4'], - [this.target.target, this.calldata.substring(0, 10)], - ), - ); - await setStorageAt(this.manager.target, EXECUTION_ID_STORAGE_SLOT, executionId); - }); - - executing(); - }); - - describe('when _executionId does not match target and selector', notExecuting); - }); - - describe('when the call does not come from the manager (msg.sender != manager)', function () { - beforeEach('define non manager caller', function () { - this.caller = this.roles.SOME.members[0]; - }); - - callerIsNotTheManager(); - }); -} - -/** - * @requires this.{manager,scheduleIn,caller,target,calldata,executionDelay} - */ -function testAsDelayedOperation() { - describe('with operation delay', function () { - describe('when operation delay is greater than execution delay', function () { - beforeEach('set operation delay', async function () { - this.operationDelay = this.executionDelay + time.duration.hours(1); - await this.manager.$_setTargetAdminDelay(this.target, this.operationDelay); - this.scheduleIn = this.operationDelay; // For testAsSchedulableOperation - }); - - testAsSchedulableOperation(LIKE_COMMON_SCHEDULABLE); - }); - - describe('when operation delay is shorter than execution delay', function () { - beforeEach('set operation delay', async function () { - this.operationDelay = this.executionDelay - time.duration.hours(1); - await this.manager.$_setTargetAdminDelay(this.target, this.operationDelay); - this.scheduleIn = this.executionDelay; // For testAsSchedulableOperation - }); - - testAsSchedulableOperation(LIKE_COMMON_SCHEDULABLE); - }); - }); - - describe('without operation delay', function () { - beforeEach('set operation delay', async function () { - this.operationDelay = 0n; - await this.manager.$_setTargetAdminDelay(this.target, this.operationDelay); - this.scheduleIn = this.executionDelay; // For testAsSchedulableOperation - }); - - testAsSchedulableOperation(LIKE_COMMON_SCHEDULABLE); - }); -} - -// ============ METHOD ============ - -/** - * @requires this.{manager,roles,role,target,calldata} - */ -function testAsCanCall({ - closed, - open: { - callerIsTheManager, - callerIsNotTheManager: { publicRoleIsRequired, specificRoleIsRequired }, - }, -}) { - testAsClosable({ - closed, - open() { - testAsRestrictedOperation({ - callerIsTheManager, - callerIsNotTheManager() { - testAsHasRole({ - publicRoleIsRequired, - specificRoleIsRequired, - }); - }, - }); - }, - }); -} - -/** - * @requires this.{target,calldata,roles,role} - */ -function testAsHasRole({ publicRoleIsRequired, specificRoleIsRequired }) { - describe('when the function requires the caller to be granted with the PUBLIC_ROLE', function () { - beforeEach('set target function role as PUBLIC_ROLE', async function () { - this.role = this.roles.PUBLIC; - await this.manager - .connect(this.roles.ADMIN.members[0]) - .$_setTargetFunctionRole(this.target, this.calldata.substring(0, 10), this.role.id); - }); - - publicRoleIsRequired(); - }); - - describe('when the function requires the caller to be granted with a role other than PUBLIC_ROLE', function () { - beforeEach('set target function role as PUBLIC_ROLE', async function () { - await this.manager - .connect(this.roles.ADMIN.members[0]) - .$_setTargetFunctionRole(this.target, this.calldata.substring(0, 10), this.role.id); - }); - - testAsGetAccess(specificRoleIsRequired); - }); -} - -/** - * @requires this.{manager,role,caller} - */ -function testAsGetAccess({ - requiredRoleIsGranted: { - roleGrantingIsDelayed: { - // Because both grant and execution delay are set within the same $_grantRole call - // it's not possible to create a set of tests that diverge between grant and execution delay. - // Therefore, the testAsDelay arguments are renamed for clarity: - // before => beforeGrantDelay - // after => afterGrantDelay - callerHasAnExecutionDelay: { beforeGrantDelay: case1, afterGrantDelay: case2 }, - callerHasNoExecutionDelay: { beforeGrantDelay: case3, afterGrantDelay: case4 }, - }, - roleGrantingIsNotDelayed: { callerHasAnExecutionDelay: case5, callerHasNoExecutionDelay: case6 }, - }, - requiredRoleIsNotGranted, -}) { - describe('when the required role is granted to the caller', function () { - describe('when role granting is delayed', function () { - beforeEach('define delay', function () { - this.grantDelay = time.duration.minutes(3); - this.delay = this.grantDelay; // For testAsDelay - }); - - describe('when caller has an execution delay', function () { - beforeEach('set role and delay', async function () { - this.executionDelay = time.duration.hours(10); - this.delay = this.grantDelay; - await this.manager.$_grantRole(this.role.id, this.caller, this.grantDelay, this.executionDelay); - }); - - testAsDelay('grant', { before: case1, after: case2 }); - }); - - describe('when caller has no execution delay', function () { - beforeEach('set role and delay', async function () { - this.executionDelay = 0n; - await this.manager.$_grantRole(this.role.id, this.caller, this.grantDelay, this.executionDelay); - }); - - testAsDelay('grant', { before: case3, after: case4 }); - }); - }); - - describe('when role granting is not delayed', function () { - beforeEach('define delay', function () { - this.grantDelay = 0n; - }); - - describe('when caller has an execution delay', function () { - beforeEach('set role and delay', async function () { - this.executionDelay = time.duration.hours(10); - await this.manager.$_grantRole(this.role.id, this.caller, this.grantDelay, this.executionDelay); - }); - - case5(); - }); - - describe('when caller has no execution delay', function () { - beforeEach('set role and delay', async function () { - this.executionDelay = 0n; - await this.manager.$_grantRole(this.role.id, this.caller, this.grantDelay, this.executionDelay); - }); - - case6(); - }); - }); - }); - - describe('when role is not granted', function () { - // Because this helper can be composed with other helpers, it's possible - // that role has been set already by another helper. - // Although this is highly unlikely, we check for it here to avoid false positives. - beforeEach('assert role is unset', async function () { - const { since } = await this.manager.getAccess(this.role.id, this.caller); - expect(since).to.equal(0n); - }); - - requiredRoleIsNotGranted(); - }); -} - -module.exports = { - LIKE_COMMON_IS_EXECUTING, - LIKE_COMMON_GET_ACCESS, - LIKE_COMMON_SCHEDULABLE, - testAsClosable, - testAsDelay, - testAsSchedulableOperation, - testAsRestrictedOperation, - testAsDelayedOperation, - testAsCanCall, - testAsHasRole, - testAsGetAccess, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AccessManager.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AccessManager.test.js deleted file mode 100644 index 7726831b26..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AccessManager.test.js +++ /dev/null @@ -1,2489 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { impersonate } = require('../../helpers/account'); -const { MAX_UINT48 } = require('../../helpers/constants'); -const { selector } = require('../../helpers/methods'); -const time = require('../../helpers/time'); - -const { - buildBaseRoles, - formatAccess, - EXPIRATION, - MINSETBACK, - EXECUTION_ID_STORAGE_SLOT, - CONSUMING_SCHEDULE_STORAGE_SLOT, - prepareOperation, - hashOperation, -} = require('../../helpers/access-manager'); - -const { - shouldBehaveLikeDelayedAdminOperation, - shouldBehaveLikeNotDelayedAdminOperation, - shouldBehaveLikeRoleAdminOperation, - shouldBehaveLikeAManagedRestrictedOperation, - shouldBehaveLikeASelfRestrictedOperation, -} = require('./AccessManager.behavior'); - -const { - LIKE_COMMON_SCHEDULABLE, - testAsClosable, - testAsDelay, - testAsSchedulableOperation, - testAsCanCall, - testAsHasRole, - testAsGetAccess, -} = require('./AccessManager.predicate'); - -async function fixture() { - const [admin, roleAdmin, roleGuardian, member, user, other] = await ethers.getSigners(); - - // Build roles - const roles = buildBaseRoles(); - - // Add members - roles.ADMIN.members = [admin]; - roles.SOME_ADMIN.members = [roleAdmin]; - roles.SOME_GUARDIAN.members = [roleGuardian]; - roles.SOME.members = [member]; - roles.PUBLIC.members = [admin, roleAdmin, roleGuardian, member, user, other]; - - const manager = await ethers.deployContract('$AccessManagerMock', [admin]); - const target = await ethers.deployContract('$AccessManagedTarget', [manager]); - - for (const { id: roleId, admin, guardian, members } of Object.values(roles)) { - if (roleId === roles.PUBLIC.id) continue; // Every address belong to public and is locked - if (roleId === roles.ADMIN.id) continue; // Admin set during construction and is locked - - // Set admin role avoiding default - if (admin.id !== roles.ADMIN.id) { - await manager.$_setRoleAdmin(roleId, admin.id); - } - - // Set guardian role avoiding default - if (guardian.id !== roles.ADMIN.id) { - await manager.$_setRoleGuardian(roleId, guardian.id); - } - - // Grant role to members - for (const member of members) { - await manager.$_grantRole(roleId, member, 0, 0); - } - } - - return { - admin, - roleAdmin, - user, - other, - roles, - manager, - target, - }; -} - -// This test suite is made using the following tools: -// -// * Predicates: Functions with common conditional setups without assertions. -// * Behaviors: Functions with common assertions. -// -// The behavioral tests are built by composing predicates and are used as templates -// for testing access to restricted functions. -// -// Similarly, unit tests in this suite will use predicates to test subsets of these -// behaviors and are helped by common assertions provided for some of the predicates. -// -// The predicates can be identified by the `testAs*` prefix while the behaviors -// are prefixed with `shouldBehave*`. The common assertions for predicates are -// defined as constants. -describe('AccessManager', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('during construction', function () { - it('grants admin role to initialAdmin', async function () { - const manager = await ethers.deployContract('$AccessManager', [this.other]); - expect(await manager.hasRole(this.roles.ADMIN.id, this.other).then(formatAccess)).to.be.deep.equal([true, '0']); - }); - - it('rejects zero address for initialAdmin', async function () { - await expect(ethers.deployContract('$AccessManager', [ethers.ZeroAddress])) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerInvalidInitialAdmin') - .withArgs(ethers.ZeroAddress); - }); - - it('initializes setup roles correctly', async function () { - for (const { id: roleId, admin, guardian, members } of Object.values(this.roles)) { - expect(await this.manager.getRoleAdmin(roleId)).to.equal(admin.id); - expect(await this.manager.getRoleGuardian(roleId)).to.equal(guardian.id); - - for (const user of this.roles.PUBLIC.members) { - expect(await this.manager.hasRole(roleId, user).then(formatAccess)).to.be.deep.equal([ - members.includes(user), - '0', - ]); - } - } - }); - }); - - describe('getters', function () { - describe('#canCall', function () { - beforeEach('set calldata', function () { - this.calldata = '0x12345678'; - this.role = { id: 379204n }; - }); - - testAsCanCall({ - closed() { - it('should return false and no delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.other, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.false; - expect(delay).to.equal(0n); - }); - }, - open: { - callerIsTheManager: { - executing() { - it('should return true and no delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.true; - expect(delay).to.equal(0n); - }); - }, - notExecuting() { - it('should return false and no delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.false; - expect(delay).to.equal(0n); - }); - }, - }, - callerIsNotTheManager: { - publicRoleIsRequired() { - it('should return true and no delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.true; - expect(delay).to.equal(0n); - }); - }, - specificRoleIsRequired: { - requiredRoleIsGranted: { - roleGrantingIsDelayed: { - callerHasAnExecutionDelay: { - beforeGrantDelay: function self() { - self.mineDelay = true; - - it('should return false and no execution delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.false; - expect(delay).to.equal(0n); - }); - }, - afterGrantDelay: function self() { - self.mineDelay = true; - - beforeEach('sets execution delay', function () { - this.scheduleIn = this.executionDelay; // For testAsSchedulableOperation - }); - - testAsSchedulableOperation({ - scheduled: { - before: function self() { - self.mineDelay = true; - - it('should return false and execution delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.false; - expect(delay).to.equal(this.executionDelay); - }); - }, - after: function self() { - self.mineDelay = true; - - it('should return false and execution delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.false; - expect(delay).to.equal(this.executionDelay); - }); - }, - expired: function self() { - self.mineDelay = true; - - it('should return false and execution delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.false; - expect(delay).to.equal(this.executionDelay); - }); - }, - }, - notScheduled() { - it('should return false and execution delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.false; - expect(delay).to.equal(this.executionDelay); - }); - }, - }); - }, - }, - callerHasNoExecutionDelay: { - beforeGrantDelay: function self() { - self.mineDelay = true; - - it('should return false and no execution delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.false; - expect(delay).to.equal(0n); - }); - }, - afterGrantDelay: function self() { - self.mineDelay = true; - - it('should return true and no execution delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.true; - expect(delay).to.equal(0n); - }); - }, - }, - }, - roleGrantingIsNotDelayed: { - callerHasAnExecutionDelay() { - it('should return false and execution delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.false; - expect(delay).to.equal(this.executionDelay); - }); - }, - callerHasNoExecutionDelay() { - it('should return true and no execution delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.true; - expect(delay).to.equal(0n); - }); - }, - }, - }, - requiredRoleIsNotGranted() { - it('should return false and no execution delay', async function () { - const { immediate, delay } = await this.manager.canCall( - this.caller, - this.target, - this.calldata.substring(0, 10), - ); - expect(immediate).to.be.false; - expect(delay).to.equal(0n); - }); - }, - }, - }, - }, - }); - }); - - describe('#expiration', function () { - it('has a 7 days default expiration', async function () { - expect(await this.manager.expiration()).to.equal(EXPIRATION); - }); - }); - - describe('#minSetback', function () { - it('has a 5 days default minimum setback', async function () { - expect(await this.manager.minSetback()).to.equal(MINSETBACK); - }); - }); - - describe('#isTargetClosed', function () { - testAsClosable({ - closed() { - it('returns true', async function () { - expect(await this.manager.isTargetClosed(this.target)).to.be.true; - }); - }, - open() { - it('returns false', async function () { - expect(await this.manager.isTargetClosed(this.target)).to.be.false; - }); - }, - }); - }); - - describe('#getTargetFunctionRole', function () { - const methodSelector = selector('something(address,bytes)'); - - it('returns the target function role', async function () { - const roleId = 21498n; - await this.manager.$_setTargetFunctionRole(this.target, methodSelector, roleId); - - expect(await this.manager.getTargetFunctionRole(this.target, methodSelector)).to.equal(roleId); - }); - - it('returns the ADMIN role if not set', async function () { - expect(await this.manager.getTargetFunctionRole(this.target, methodSelector)).to.equal(this.roles.ADMIN.id); - }); - }); - - describe('#getTargetAdminDelay', function () { - describe('when the target admin delay is setup', function () { - beforeEach('set target admin delay', async function () { - this.oldDelay = await this.manager.getTargetAdminDelay(this.target); - this.newDelay = time.duration.days(10); - - await this.manager.$_setTargetAdminDelay(this.target, this.newDelay); - this.delay = MINSETBACK; // For testAsDelay - }); - - testAsDelay('effect', { - before: function self() { - self.mineDelay = true; - - it('returns the old target admin delay', async function () { - expect(await this.manager.getTargetAdminDelay(this.target)).to.equal(this.oldDelay); - }); - }, - after: function self() { - self.mineDelay = true; - - it('returns the new target admin delay', async function () { - expect(await this.manager.getTargetAdminDelay(this.target)).to.equal(this.newDelay); - }); - }, - }); - }); - - it('returns the 0 if not set', async function () { - expect(await this.manager.getTargetAdminDelay(this.target)).to.equal(0n); - }); - }); - - describe('#getRoleAdmin', function () { - const roleId = 5234907n; - - it('returns the role admin', async function () { - const adminId = 789433n; - - await this.manager.$_setRoleAdmin(roleId, adminId); - - expect(await this.manager.getRoleAdmin(roleId)).to.equal(adminId); - }); - - it('returns the ADMIN role if not set', async function () { - expect(await this.manager.getRoleAdmin(roleId)).to.equal(this.roles.ADMIN.id); - }); - }); - - describe('#getRoleGuardian', function () { - const roleId = 5234907n; - - it('returns the role guardian', async function () { - const guardianId = 789433n; - - await this.manager.$_setRoleGuardian(roleId, guardianId); - - expect(await this.manager.getRoleGuardian(roleId)).to.equal(guardianId); - }); - - it('returns the ADMIN role if not set', async function () { - expect(await this.manager.getRoleGuardian(roleId)).to.equal(this.roles.ADMIN.id); - }); - }); - - describe('#getRoleGrantDelay', function () { - const roleId = 9248439n; - - describe('when the grant admin delay is setup', function () { - beforeEach('set grant admin delay', async function () { - this.oldDelay = await this.manager.getRoleGrantDelay(roleId); - this.newDelay = time.duration.days(11); - - await this.manager.$_setGrantDelay(roleId, this.newDelay); - this.delay = MINSETBACK; // For testAsDelay - }); - - testAsDelay('grant', { - before: function self() { - self.mineDelay = true; - - it('returns the old role grant delay', async function () { - expect(await this.manager.getRoleGrantDelay(roleId)).to.equal(this.oldDelay); - }); - }, - after: function self() { - self.mineDelay = true; - - it('returns the new role grant delay', async function () { - expect(await this.manager.getRoleGrantDelay(roleId)).to.equal(this.newDelay); - }); - }, - }); - }); - - it('returns 0 if delay is not set', async function () { - expect(await this.manager.getTargetAdminDelay(this.target)).to.equal(0n); - }); - }); - - describe('#getAccess', function () { - beforeEach('set role', function () { - this.role = { id: 9452n }; - this.caller = this.user; - }); - - testAsGetAccess({ - requiredRoleIsGranted: { - roleGrantingIsDelayed: { - callerHasAnExecutionDelay: { - beforeGrantDelay: function self() { - self.mineDelay = true; - - it('role is not in effect and execution delay is set', async function () { - const access = await this.manager.getAccess(this.role.id, this.caller); - expect(access[0]).to.equal(this.delayEffect); // inEffectSince - expect(access[1]).to.equal(this.executionDelay); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Not in effect yet - expect(await time.clock.timestamp()).to.lt(access[0]); - }); - }, - afterGrantDelay: function self() { - self.mineDelay = true; - - it('access has role in effect and execution delay is set', async function () { - const access = await this.manager.getAccess(this.role.id, this.caller); - - expect(access[0]).to.equal(this.delayEffect); // inEffectSince - expect(access[1]).to.equal(this.executionDelay); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Already in effect - expect(await time.clock.timestamp()).to.equal(access[0]); - }); - }, - }, - callerHasNoExecutionDelay: { - beforeGrantDelay: function self() { - self.mineDelay = true; - - it('access has role not in effect without execution delay', async function () { - const access = await this.manager.getAccess(this.role.id, this.caller); - expect(access[0]).to.equal(this.delayEffect); // inEffectSince - expect(access[1]).to.equal(0n); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Not in effect yet - expect(await time.clock.timestamp()).to.lt(access[0]); - }); - }, - afterGrantDelay: function self() { - self.mineDelay = true; - - it('role is in effect without execution delay', async function () { - const access = await this.manager.getAccess(this.role.id, this.caller); - expect(access[0]).to.equal(this.delayEffect); // inEffectSince - expect(access[1]).to.equal(0n); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Already in effect - expect(await time.clock.timestamp()).to.equal(access[0]); - }); - }, - }, - }, - roleGrantingIsNotDelayed: { - callerHasAnExecutionDelay() { - it('access has role in effect and execution delay is set', async function () { - const access = await this.manager.getAccess(this.role.id, this.caller); - expect(access[0]).to.equal(await time.clock.timestamp()); // inEffectSince - expect(access[1]).to.equal(this.executionDelay); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Already in effect - expect(await time.clock.timestamp()).to.equal(access[0]); - }); - }, - callerHasNoExecutionDelay() { - it('access has role in effect without execution delay', async function () { - const access = await this.manager.getAccess(this.role.id, this.caller); - expect(access[0]).to.equal(await time.clock.timestamp()); // inEffectSince - expect(access[1]).to.equal(0n); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Already in effect - expect(await time.clock.timestamp()).to.equal(access[0]); - }); - }, - }, - }, - requiredRoleIsNotGranted() { - it('has empty access', async function () { - const access = await this.manager.getAccess(this.role.id, this.caller); - expect(access[0]).to.equal(0n); // inEffectSince - expect(access[1]).to.equal(0n); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - }); - }, - }); - }); - - describe('#hasRole', function () { - beforeEach('setup testAsHasRole', function () { - this.role = { id: 49832n }; - this.calldata = '0x12345678'; - this.caller = this.user; - }); - - testAsHasRole({ - publicRoleIsRequired() { - it('has PUBLIC role', async function () { - const { isMember, executionDelay } = await this.manager.hasRole(this.role.id, this.caller); - expect(isMember).to.be.true; - expect(executionDelay).to.equal('0'); - }); - }, - specificRoleIsRequired: { - requiredRoleIsGranted: { - roleGrantingIsDelayed: { - callerHasAnExecutionDelay: { - beforeGrantDelay: function self() { - self.mineDelay = true; - - it('does not have role but execution delay', async function () { - const { isMember, executionDelay } = await this.manager.hasRole(this.role.id, this.caller); - expect(isMember).to.be.false; - expect(executionDelay).to.equal(this.executionDelay); - }); - }, - afterGrantDelay: function self() { - self.mineDelay = true; - - it('has role and execution delay', async function () { - const { isMember, executionDelay } = await this.manager.hasRole(this.role.id, this.caller); - expect(isMember).to.be.true; - expect(executionDelay).to.equal(this.executionDelay); - }); - }, - }, - callerHasNoExecutionDelay: { - beforeGrantDelay: function self() { - self.mineDelay = true; - - it('does not have role nor execution delay', async function () { - const { isMember, executionDelay } = await this.manager.hasRole(this.role.id, this.caller); - expect(isMember).to.be.false; - expect(executionDelay).to.equal('0'); - }); - }, - afterGrantDelay: function self() { - self.mineDelay = true; - - it('has role and no execution delay', async function () { - const { isMember, executionDelay } = await this.manager.hasRole(this.role.id, this.caller); - expect(isMember).to.be.true; - expect(executionDelay).to.equal('0'); - }); - }, - }, - }, - roleGrantingIsNotDelayed: { - callerHasAnExecutionDelay() { - it('has role and execution delay', async function () { - const { isMember, executionDelay } = await this.manager.hasRole(this.role.id, this.caller); - expect(isMember).to.be.true; - expect(executionDelay).to.equal(this.executionDelay); - }); - }, - callerHasNoExecutionDelay() { - it('has role and no execution delay', async function () { - const { isMember, executionDelay } = await this.manager.hasRole(this.role.id, this.caller); - expect(isMember).to.be.true; - expect(executionDelay).to.equal('0'); - }); - }, - }, - }, - requiredRoleIsNotGranted() { - it('has no role and no execution delay', async function () { - const { isMember, executionDelay } = await this.manager.hasRole(this.role.id, this.caller); - expect(isMember).to.be.false; - expect(executionDelay).to.equal('0'); - }); - }, - }, - }); - }); - - describe('#getSchedule', function () { - beforeEach('set role and calldata', async function () { - const fnRestricted = this.target.fnRestricted.getFragment().selector; - this.caller = this.user; - this.role = { id: 493590n }; - await this.manager.$_setTargetFunctionRole(this.target, fnRestricted, this.role.id); - await this.manager.$_grantRole(this.role.id, this.caller, 0, 1); // nonzero execution delay - - this.calldata = this.target.interface.encodeFunctionData(fnRestricted, []); - this.scheduleIn = time.duration.days(10); // For testAsSchedulableOperation - }); - - testAsSchedulableOperation({ - scheduled: { - before: function self() { - self.mineDelay = true; - - it('returns schedule in the future', async function () { - const schedule = await this.manager.getSchedule(this.operationId); - expect(schedule).to.equal(this.scheduledAt + this.scheduleIn); - expect(schedule).to.gt(await time.clock.timestamp()); - }); - }, - after: function self() { - self.mineDelay = true; - - it('returns schedule', async function () { - const schedule = await this.manager.getSchedule(this.operationId); - expect(schedule).to.equal(this.scheduledAt + this.scheduleIn); - expect(schedule).to.equal(await time.clock.timestamp()); - }); - }, - expired: function self() { - self.mineDelay = true; - - it('returns 0', async function () { - expect(await this.manager.getSchedule(this.operationId)).to.equal(0n); - }); - }, - }, - notScheduled() { - it('defaults to 0', async function () { - expect(await this.manager.getSchedule(this.operationId)).to.equal(0n); - }); - }, - }); - }); - - describe('#getNonce', function () { - describe('when operation is scheduled', function () { - beforeEach('schedule operation', async function () { - const fnRestricted = this.target.fnRestricted.getFragment().selector; - this.caller = this.user; - this.role = { id: 4209043n }; - await this.manager.$_setTargetFunctionRole(this.target, fnRestricted, this.role.id); - await this.manager.$_grantRole(this.role.id, this.caller, 0, 1); // nonzero execution delay - - this.calldata = this.target.interface.encodeFunctionData(fnRestricted, []); - this.delay = time.duration.days(10); - - const { operationId, schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.delay, - }); - await schedule(); - this.operationId = operationId; - }); - - it('returns nonce', async function () { - expect(await this.manager.getNonce(this.operationId)).to.equal(1n); - }); - }); - - describe('when is not scheduled', function () { - it('returns default 0', async function () { - expect(await this.manager.getNonce(ethers.id('operation'))).to.equal(0n); - }); - }); - }); - - describe('#hashOperation', function () { - it('returns an operationId', async function () { - const args = [this.user, this.other, '0x123543']; - expect(await this.manager.hashOperation(...args)).to.equal(hashOperation(...args)); - }); - }); - }); - - describe('admin operations', function () { - beforeEach('set required role', function () { - this.role = this.roles.ADMIN; - }); - - describe('subject to a delay', function () { - describe('#labelRole', function () { - describe('restrictions', function () { - beforeEach('set method and args', function () { - const args = [123443, 'TEST']; - const method = this.manager.interface.getFunction('labelRole(uint64,string)'); - this.calldata = this.manager.interface.encodeFunctionData(method, args); - }); - - shouldBehaveLikeDelayedAdminOperation(); - }); - - it('emits an event with the label', async function () { - await expect(this.manager.connect(this.admin).labelRole(this.roles.SOME.id, 'Some label')) - .to.emit(this.manager, 'RoleLabel') - .withArgs(this.roles.SOME.id, 'Some label'); - }); - - it('updates label on a second call', async function () { - await this.manager.connect(this.admin).labelRole(this.roles.SOME.id, 'Some label'); - - await expect(this.manager.connect(this.admin).labelRole(this.roles.SOME.id, 'Updated label')) - .to.emit(this.manager, 'RoleLabel') - .withArgs(this.roles.SOME.id, 'Updated label'); - }); - - it('reverts labeling PUBLIC_ROLE', async function () { - await expect(this.manager.connect(this.admin).labelRole(this.roles.PUBLIC.id, 'Some label')) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerLockedRole') - .withArgs(this.roles.PUBLIC.id); - }); - - it('reverts labeling ADMIN_ROLE', async function () { - await expect(this.manager.connect(this.admin).labelRole(this.roles.ADMIN.id, 'Some label')) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerLockedRole') - .withArgs(this.roles.ADMIN.id); - }); - }); - - describe('#setRoleAdmin', function () { - describe('restrictions', function () { - beforeEach('set method and args', function () { - const args = [93445, 84532]; - const method = this.manager.interface.getFunction('setRoleAdmin(uint64,uint64)'); - this.calldata = this.manager.interface.encodeFunctionData(method, args); - }); - - shouldBehaveLikeDelayedAdminOperation(); - }); - - it("sets any role's admin if called by an admin", async function () { - expect(await this.manager.getRoleAdmin(this.roles.SOME.id)).to.equal(this.roles.SOME_ADMIN.id); - - await expect(this.manager.connect(this.admin).setRoleAdmin(this.roles.SOME.id, this.roles.ADMIN.id)) - .to.emit(this.manager, 'RoleAdminChanged') - .withArgs(this.roles.SOME.id, this.roles.ADMIN.id); - - expect(await this.manager.getRoleAdmin(this.roles.SOME.id)).to.equal(this.roles.ADMIN.id); - }); - - it('reverts setting PUBLIC_ROLE admin', async function () { - await expect(this.manager.connect(this.admin).setRoleAdmin(this.roles.PUBLIC.id, this.roles.ADMIN.id)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerLockedRole') - .withArgs(this.roles.PUBLIC.id); - }); - - it('reverts setting ADMIN_ROLE admin', async function () { - await expect(this.manager.connect(this.admin).setRoleAdmin(this.roles.ADMIN.id, this.roles.ADMIN.id)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerLockedRole') - .withArgs(this.roles.ADMIN.id); - }); - }); - - describe('#setRoleGuardian', function () { - describe('restrictions', function () { - beforeEach('set method and args', function () { - const args = [93445, 84532]; - const method = this.manager.interface.getFunction('setRoleGuardian(uint64,uint64)'); - this.calldata = this.manager.interface.encodeFunctionData(method, args); - }); - - shouldBehaveLikeDelayedAdminOperation(); - }); - - it("sets any role's guardian if called by an admin", async function () { - expect(await this.manager.getRoleGuardian(this.roles.SOME.id)).to.equal(this.roles.SOME_GUARDIAN.id); - - await expect(this.manager.connect(this.admin).setRoleGuardian(this.roles.SOME.id, this.roles.ADMIN.id)) - .to.emit(this.manager, 'RoleGuardianChanged') - .withArgs(this.roles.SOME.id, this.roles.ADMIN.id); - - expect(await this.manager.getRoleGuardian(this.roles.SOME.id)).to.equal(this.roles.ADMIN.id); - }); - - it('reverts setting PUBLIC_ROLE admin', async function () { - await expect(this.manager.connect(this.admin).setRoleGuardian(this.roles.PUBLIC.id, this.roles.ADMIN.id)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerLockedRole') - .withArgs(this.roles.PUBLIC.id); - }); - - it('reverts setting ADMIN_ROLE admin', async function () { - await expect(this.manager.connect(this.admin).setRoleGuardian(this.roles.ADMIN.id, this.roles.ADMIN.id)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerLockedRole') - .withArgs(this.roles.ADMIN.id); - }); - }); - - describe('#setGrantDelay', function () { - describe('restrictions', function () { - beforeEach('set method and args', function () { - const args = [984910, time.duration.days(2)]; - const method = this.manager.interface.getFunction('setGrantDelay(uint64,uint32)'); - this.calldata = this.manager.interface.encodeFunctionData(method, args); - }); - - shouldBehaveLikeDelayedAdminOperation(); - }); - - it('reverts setting grant delay for the PUBLIC_ROLE', async function () { - await expect(this.manager.connect(this.admin).setGrantDelay(this.roles.PUBLIC.id, 69n)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerLockedRole') - .withArgs(this.roles.PUBLIC.id); - }); - - describe('when increasing the delay', function () { - const oldDelay = 10n; - const newDelay = 100n; - - beforeEach('sets old delay', async function () { - this.role = this.roles.SOME; - await this.manager.$_setGrantDelay(this.role.id, oldDelay); - await time.increaseBy.timestamp(MINSETBACK); - expect(await this.manager.getRoleGrantDelay(this.role.id)).to.equal(oldDelay); - }); - - it('increases the delay after minsetback', async function () { - const txResponse = await this.manager.connect(this.admin).setGrantDelay(this.role.id, newDelay); - const setGrantDelayAt = await time.clockFromReceipt.timestamp(txResponse); - await expect(txResponse) - .to.emit(this.manager, 'RoleGrantDelayChanged') - .withArgs(this.role.id, newDelay, setGrantDelayAt + MINSETBACK); - - expect(await this.manager.getRoleGrantDelay(this.role.id)).to.equal(oldDelay); - await time.increaseBy.timestamp(MINSETBACK); - expect(await this.manager.getRoleGrantDelay(this.role.id)).to.equal(newDelay); - }); - }); - - describe('when reducing the delay', function () { - const oldDelay = time.duration.days(10); - - beforeEach('sets old delay', async function () { - this.role = this.roles.SOME; - await this.manager.$_setGrantDelay(this.role.id, oldDelay); - await time.increaseBy.timestamp(MINSETBACK); - expect(await this.manager.getRoleGrantDelay(this.role.id)).to.equal(oldDelay); - }); - - describe('when the delay difference is shorter than minimum setback', function () { - const newDelay = oldDelay - 1n; - - it('increases the delay after minsetback', async function () { - const txResponse = await this.manager.connect(this.admin).setGrantDelay(this.role.id, newDelay); - const setGrantDelayAt = await time.clockFromReceipt.timestamp(txResponse); - await expect(txResponse) - .to.emit(this.manager, 'RoleGrantDelayChanged') - .withArgs(this.role.id, newDelay, setGrantDelayAt + MINSETBACK); - - expect(await this.manager.getRoleGrantDelay(this.role.id)).to.equal(oldDelay); - await time.increaseBy.timestamp(MINSETBACK); - expect(await this.manager.getRoleGrantDelay(this.role.id)).to.equal(newDelay); - }); - }); - - describe('when the delay difference is longer than minimum setback', function () { - const newDelay = 1n; - - beforeEach('assert delay difference is higher than minsetback', function () { - expect(oldDelay - newDelay).to.gt(MINSETBACK); - }); - - it('increases the delay after delay difference', async function () { - const setback = oldDelay - newDelay; - - const txResponse = await this.manager.connect(this.admin).setGrantDelay(this.role.id, newDelay); - const setGrantDelayAt = await time.clockFromReceipt.timestamp(txResponse); - - await expect(txResponse) - .to.emit(this.manager, 'RoleGrantDelayChanged') - .withArgs(this.role.id, newDelay, setGrantDelayAt + setback); - - expect(await this.manager.getRoleGrantDelay(this.role.id)).to.equal(oldDelay); - await time.increaseBy.timestamp(setback); - expect(await this.manager.getRoleGrantDelay(this.role.id)).to.equal(newDelay); - }); - }); - }); - }); - - describe('#setTargetAdminDelay', function () { - describe('restrictions', function () { - beforeEach('set method and args', function () { - const args = [this.other.address, time.duration.days(3)]; - const method = this.manager.interface.getFunction('setTargetAdminDelay(address,uint32)'); - this.calldata = this.manager.interface.encodeFunctionData(method, args); - }); - - shouldBehaveLikeDelayedAdminOperation(); - }); - - describe('when increasing the delay', function () { - const oldDelay = time.duration.days(10); - const newDelay = time.duration.days(11); - - beforeEach('sets old delay', async function () { - await this.manager.$_setTargetAdminDelay(this.other, oldDelay); - await time.increaseBy.timestamp(MINSETBACK); - expect(await this.manager.getTargetAdminDelay(this.other)).to.equal(oldDelay); - }); - - it('increases the delay after minsetback', async function () { - const txResponse = await this.manager.connect(this.admin).setTargetAdminDelay(this.other, newDelay); - const setTargetAdminDelayAt = await time.clockFromReceipt.timestamp(txResponse); - await expect(txResponse) - .to.emit(this.manager, 'TargetAdminDelayUpdated') - .withArgs(this.other, newDelay, setTargetAdminDelayAt + MINSETBACK); - - expect(await this.manager.getTargetAdminDelay(this.other)).to.equal(oldDelay); - await time.increaseBy.timestamp(MINSETBACK); - expect(await this.manager.getTargetAdminDelay(this.other)).to.equal(newDelay); - }); - }); - - describe('when reducing the delay', function () { - const oldDelay = time.duration.days(10); - - beforeEach('sets old delay', async function () { - await this.manager.$_setTargetAdminDelay(this.other, oldDelay); - await time.increaseBy.timestamp(MINSETBACK); - expect(await this.manager.getTargetAdminDelay(this.other)).to.equal(oldDelay); - }); - - describe('when the delay difference is shorter than minimum setback', function () { - const newDelay = oldDelay - 1n; - - it('increases the delay after minsetback', async function () { - const txResponse = await this.manager.connect(this.admin).setTargetAdminDelay(this.other, newDelay); - const setTargetAdminDelayAt = await time.clockFromReceipt.timestamp(txResponse); - await expect(txResponse) - .to.emit(this.manager, 'TargetAdminDelayUpdated') - .withArgs(this.other, newDelay, setTargetAdminDelayAt + MINSETBACK); - - expect(await this.manager.getTargetAdminDelay(this.other)).to.equal(oldDelay); - await time.increaseBy.timestamp(MINSETBACK); - expect(await this.manager.getTargetAdminDelay(this.other)).to.equal(newDelay); - }); - }); - - describe('when the delay difference is longer than minimum setback', function () { - const newDelay = 1n; - - beforeEach('assert delay difference is higher than minsetback', function () { - expect(oldDelay - newDelay).to.gt(MINSETBACK); - }); - - it('increases the delay after delay difference', async function () { - const setback = oldDelay - newDelay; - - const txResponse = await this.manager.connect(this.admin).setTargetAdminDelay(this.other, newDelay); - const setTargetAdminDelayAt = await time.clockFromReceipt.timestamp(txResponse); - - await expect(txResponse) - .to.emit(this.manager, 'TargetAdminDelayUpdated') - .withArgs(this.other, newDelay, setTargetAdminDelayAt + setback); - - expect(await this.manager.getTargetAdminDelay(this.other)).to.equal(oldDelay); - await time.increaseBy.timestamp(setback); - expect(await this.manager.getTargetAdminDelay(this.other)).to.equal(newDelay); - }); - }); - }); - }); - }); - - describe('not subject to a delay', function () { - describe('#updateAuthority', function () { - beforeEach('create a target and a new authority', async function () { - this.newAuthority = await ethers.deployContract('$AccessManager', [this.admin]); - this.newManagedTarget = await ethers.deployContract('$AccessManagedTarget', [this.manager]); - }); - - describe('restrictions', function () { - beforeEach('set method and args', function () { - this.calldata = this.manager.interface.encodeFunctionData('updateAuthority(address,address)', [ - this.newManagedTarget.target, - this.newAuthority.target, - ]); - }); - - shouldBehaveLikeNotDelayedAdminOperation(); - }); - - it('changes the authority', async function () { - expect(await this.newManagedTarget.authority()).to.equal(this.manager); - - await expect(this.manager.connect(this.admin).updateAuthority(this.newManagedTarget, this.newAuthority)) - .to.emit(this.newManagedTarget, 'AuthorityUpdated') // Managed contract is responsible of notifying the change through an event - .withArgs(this.newAuthority); - - expect(await this.newManagedTarget.authority()).to.equal(this.newAuthority); - }); - }); - - describe('#setTargetClosed', function () { - describe('restrictions', function () { - beforeEach('set method and args', function () { - const args = [this.other.address, true]; - const method = this.manager.interface.getFunction('setTargetClosed(address,bool)'); - this.calldata = this.manager.interface.encodeFunctionData(method, args); - }); - - shouldBehaveLikeNotDelayedAdminOperation(); - }); - - it('closes and opens a target', async function () { - await expect(this.manager.connect(this.admin).setTargetClosed(this.target, true)) - .to.emit(this.manager, 'TargetClosed') - .withArgs(this.target, true); - expect(await this.manager.isTargetClosed(this.target)).to.be.true; - - await expect(this.manager.connect(this.admin).setTargetClosed(this.target, false)) - .to.emit(this.manager, 'TargetClosed') - .withArgs(this.target, false); - expect(await this.manager.isTargetClosed(this.target)).to.be.false; - }); - - describe('when the target is the manager', async function () { - it('closes and opens the manager', async function () { - await expect(this.manager.connect(this.admin).setTargetClosed(this.manager, true)) - .to.emit(this.manager, 'TargetClosed') - .withArgs(this.manager, true); - expect(await this.manager.isTargetClosed(this.manager)).to.be.true; - - await expect(this.manager.connect(this.admin).setTargetClosed(this.manager, false)) - .to.emit(this.manager, 'TargetClosed') - .withArgs(this.manager, false); - expect(await this.manager.isTargetClosed(this.manager)).to.be.false; - }); - }); - }); - - describe('#setTargetFunctionRole', function () { - describe('restrictions', function () { - beforeEach('set method and args', function () { - const args = [this.other.address, ['0x12345678'], 443342]; - const method = this.manager.interface.getFunction('setTargetFunctionRole(address,bytes4[],uint64)'); - this.calldata = this.manager.interface.encodeFunctionData(method, args); - }); - - shouldBehaveLikeNotDelayedAdminOperation(); - }); - - const sigs = ['someFunction()', 'someOtherFunction(uint256)', 'oneMoreFunction(address,uint8)'].map(selector); - - it('sets function roles', async function () { - for (const sig of sigs) { - expect(await this.manager.getTargetFunctionRole(this.target, sig)).to.equal(this.roles.ADMIN.id); - } - - const allowRole = await this.manager - .connect(this.admin) - .setTargetFunctionRole(this.target, sigs, this.roles.SOME.id); - - for (const sig of sigs) { - await expect(allowRole) - .to.emit(this.manager, 'TargetFunctionRoleUpdated') - .withArgs(this.target, sig, this.roles.SOME.id); - expect(await this.manager.getTargetFunctionRole(this.target, sig)).to.equal(this.roles.SOME.id); - } - - await expect( - this.manager.connect(this.admin).setTargetFunctionRole(this.target, [sigs[1]], this.roles.SOME_ADMIN.id), - ) - .to.emit(this.manager, 'TargetFunctionRoleUpdated') - .withArgs(this.target, sigs[1], this.roles.SOME_ADMIN.id); - - for (const sig of sigs) { - expect(await this.manager.getTargetFunctionRole(this.target, sig)).to.equal( - sig == sigs[1] ? this.roles.SOME_ADMIN.id : this.roles.SOME.id, - ); - } - }); - }); - - describe('role admin operations', function () { - const ANOTHER_ADMIN = 0xdeadc0de1n; - const ANOTHER_ROLE = 0xdeadc0de2n; - - beforeEach('set required role', async function () { - // Make admin a member of ANOTHER_ADMIN - await this.manager.$_grantRole(ANOTHER_ADMIN, this.admin, 0, 0); - await this.manager.$_setRoleAdmin(ANOTHER_ROLE, ANOTHER_ADMIN); - - this.role = { id: ANOTHER_ADMIN }; - await this.manager.$_grantRole(this.role.id, this.user, 0, 0); - }); - - describe('#grantRole', function () { - describe('restrictions', function () { - beforeEach('set method and args', function () { - const args = [ANOTHER_ROLE, this.other.address, 0]; - const method = this.manager.interface.getFunction('grantRole(uint64,address,uint32)'); - this.calldata = this.manager.interface.encodeFunctionData(method, args); - }); - - shouldBehaveLikeRoleAdminOperation(ANOTHER_ADMIN); - }); - - it('reverts when granting PUBLIC_ROLE', async function () { - await expect(this.manager.connect(this.admin).grantRole(this.roles.PUBLIC.id, this.user, 0)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerLockedRole') - .withArgs(this.roles.PUBLIC.id); - }); - - describe('when the user is not a role member', function () { - describe('with grant delay', function () { - beforeEach('set grant delay and grant role', async function () { - // Delay granting - this.grantDelay = time.duration.weeks(2); - await this.manager.$_setGrantDelay(ANOTHER_ROLE, this.grantDelay); - await time.increaseBy.timestamp(MINSETBACK); - - // Grant role - this.executionDelay = time.duration.days(3); - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - false, - '0', - ]); - - this.txResponse = await this.manager - .connect(this.admin) - .grantRole(ANOTHER_ROLE, this.user, this.executionDelay); - this.delay = this.grantDelay; // For testAsDelay - }); - - testAsDelay('grant', { - before: function self() { - self.mineDelay = true; - - it('does not grant role to the user yet', async function () { - const timestamp = await time.clockFromReceipt.timestamp(this.txResponse); - await expect(this.txResponse) - .to.emit(this.manager, 'RoleGranted') - .withArgs(ANOTHER_ROLE, this.user, this.executionDelay, timestamp + this.grantDelay, true); - - // Access is correctly stored - const access = await this.manager.getAccess(ANOTHER_ROLE, this.user); - expect(access[0]).to.equal(timestamp + this.grantDelay); // inEffectSince - expect(access[1]).to.equal(this.executionDelay); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Not in effect yet - const currentTimestamp = await time.clock.timestamp(); - expect(currentTimestamp).to.be.lt(access[0]); - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - false, - this.executionDelay.toString(), - ]); - }); - }, - after: function self() { - self.mineDelay = true; - - it('grants role to the user', async function () { - const timestamp = await time.clockFromReceipt.timestamp(this.txResponse); - await expect(this.txResponse) - .to.emit(this.manager, 'RoleGranted') - .withArgs(ANOTHER_ROLE, this.user, this.executionDelay, timestamp + this.grantDelay, true); - - // Access is correctly stored - const access = await this.manager.getAccess(ANOTHER_ROLE, this.user); - expect(access[0]).to.equal(timestamp + this.grantDelay); // inEffectSince - expect(access[1]).to.equal(this.executionDelay); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Already in effect - const currentTimestamp = await time.clock.timestamp(); - expect(currentTimestamp).to.equal(access[0]); - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.executionDelay.toString(), - ]); - }); - }, - }); - }); - - describe('without grant delay', function () { - beforeEach('set granting delay', async function () { - // Delay granting - this.grantDelay = 0; - await this.manager.$_setGrantDelay(ANOTHER_ROLE, this.grantDelay); - await time.increaseBy.timestamp(MINSETBACK); - }); - - it('immediately grants the role to the user', async function () { - const executionDelay = time.duration.days(6); - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - false, - '0', - ]); - const txResponse = await this.manager - .connect(this.admin) - .grantRole(ANOTHER_ROLE, this.user, executionDelay); - const grantedAt = await time.clockFromReceipt.timestamp(txResponse); - await expect(txResponse) - .to.emit(this.manager, 'RoleGranted') - .withArgs(ANOTHER_ROLE, this.user, executionDelay, grantedAt, true); - - // Access is correctly stored - const access = await this.manager.getAccess(ANOTHER_ROLE, this.user); - expect(access[0]).to.equal(grantedAt); // inEffectSince - expect(access[1]).to.equal(executionDelay); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Already in effect - const currentTimestamp = await time.clock.timestamp(); - expect(currentTimestamp).to.equal(access[0]); - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - executionDelay.toString(), - ]); - }); - }); - }); - - describe('when the user is already a role member', function () { - beforeEach('make user role member', async function () { - this.previousExecutionDelay = time.duration.days(6); - await this.manager.$_grantRole(ANOTHER_ROLE, this.user, 0, this.previousExecutionDelay); - this.oldAccess = await this.manager.getAccess(ANOTHER_ROLE, this.user); - }); - - describe('with grant delay', function () { - beforeEach('set granting delay', async function () { - // Delay granting - const grantDelay = time.duration.weeks(2); - await this.manager.$_setGrantDelay(ANOTHER_ROLE, grantDelay); - await time.increaseBy.timestamp(MINSETBACK); - }); - - describe('when increasing the execution delay', function () { - beforeEach('set increased new execution delay', async function () { - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.previousExecutionDelay.toString(), - ]); - - this.newExecutionDelay = this.previousExecutionDelay + time.duration.days(4); - }); - - it('emits event and immediately changes the execution delay', async function () { - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.previousExecutionDelay.toString(), - ]); - const txResponse = await this.manager - .connect(this.admin) - .grantRole(ANOTHER_ROLE, this.user, this.newExecutionDelay); - const timestamp = await time.clockFromReceipt.timestamp(txResponse); - - await expect(txResponse) - .to.emit(this.manager, 'RoleGranted') - .withArgs(ANOTHER_ROLE, this.user, this.newExecutionDelay, timestamp, false); - - // Access is correctly stored - const access = await this.manager.getAccess(ANOTHER_ROLE, this.user); - expect(access[0]).to.equal(this.oldAccess[0]); // inEffectSince - expect(access[1]).to.equal(this.newExecutionDelay); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Already in effect - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.newExecutionDelay.toString(), - ]); - }); - }); - - describe('when decreasing the execution delay', function () { - beforeEach('decrease execution delay', async function () { - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.previousExecutionDelay.toString(), - ]); - - this.newExecutionDelay = this.previousExecutionDelay - time.duration.days(4); - this.txResponse = await this.manager - .connect(this.admin) - .grantRole(ANOTHER_ROLE, this.user, this.newExecutionDelay); - this.grantTimestamp = await time.clockFromReceipt.timestamp(this.txResponse); - - this.delay = this.previousExecutionDelay - this.newExecutionDelay; // For testAsDelay - }); - - it('emits event', async function () { - await expect(this.txResponse) - .to.emit(this.manager, 'RoleGranted') - .withArgs(ANOTHER_ROLE, this.user, this.newExecutionDelay, this.grantTimestamp + this.delay, false); - }); - - testAsDelay('execution delay effect', { - before: function self() { - self.mineDelay = true; - - it('does not change the execution delay yet', async function () { - // Access is correctly stored - const access = await this.manager.getAccess(ANOTHER_ROLE, this.user); - expect(access[0]).to.equal(this.oldAccess[0]); // inEffectSince - expect(access[1]).to.equal(this.previousExecutionDelay); // currentDelay - expect(access[2]).to.equal(this.newExecutionDelay); // pendingDelay - expect(access[3]).to.equal(this.grantTimestamp + this.delay); // pendingDelayEffect - - // Not in effect yet - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.previousExecutionDelay.toString(), - ]); - }); - }, - after: function self() { - self.mineDelay = true; - - it('changes the execution delay', async function () { - // Access is correctly stored - const access = await this.manager.getAccess(ANOTHER_ROLE, this.user); - - expect(access[0]).to.equal(this.oldAccess[0]); // inEffectSince - expect(access[1]).to.equal(this.newExecutionDelay); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Already in effect - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.newExecutionDelay.toString(), - ]); - }); - }, - }); - }); - }); - - describe('without grant delay', function () { - beforeEach('set granting delay', async function () { - // Delay granting - const grantDelay = 0; - await this.manager.$_setGrantDelay(ANOTHER_ROLE, grantDelay); - await time.increaseBy.timestamp(MINSETBACK); - }); - - describe('when increasing the execution delay', function () { - beforeEach('set increased new execution delay', async function () { - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.previousExecutionDelay.toString(), - ]); - - this.newExecutionDelay = this.previousExecutionDelay + time.duration.days(4); - }); - - it('emits event and immediately changes the execution delay', async function () { - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.previousExecutionDelay.toString(), - ]); - const txResponse = await this.manager - .connect(this.admin) - .grantRole(ANOTHER_ROLE, this.user, this.newExecutionDelay); - const timestamp = await time.clockFromReceipt.timestamp(txResponse); - - await expect(txResponse) - .to.emit(this.manager, 'RoleGranted') - .withArgs(ANOTHER_ROLE, this.user, this.newExecutionDelay, timestamp, false); - - // Access is correctly stored - const access = await this.manager.getAccess(ANOTHER_ROLE, this.user); - expect(access[0]).to.equal(this.oldAccess[0]); // inEffectSince - expect(access[1]).to.equal(this.newExecutionDelay); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Already in effect - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.newExecutionDelay.toString(), - ]); - }); - }); - - describe('when decreasing the execution delay', function () { - beforeEach('decrease execution delay', async function () { - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.previousExecutionDelay.toString(), - ]); - - this.newExecutionDelay = this.previousExecutionDelay - time.duration.days(4); - this.txResponse = await this.manager - .connect(this.admin) - .grantRole(ANOTHER_ROLE, this.user, this.newExecutionDelay); - this.grantTimestamp = await time.clockFromReceipt.timestamp(this.txResponse); - - this.delay = this.previousExecutionDelay - this.newExecutionDelay; // For testAsDelay - }); - - it('emits event', async function () { - await expect(this.txResponse) - .to.emit(this.manager, 'RoleGranted') - .withArgs(ANOTHER_ROLE, this.user, this.newExecutionDelay, this.grantTimestamp + this.delay, false); - }); - - testAsDelay('execution delay effect', { - before: function self() { - self.mineDelay = true; - - it('does not change the execution delay yet', async function () { - // Access is correctly stored - const access = await this.manager.getAccess(ANOTHER_ROLE, this.user); - expect(access[0]).to.equal(this.oldAccess[0]); // inEffectSince - expect(access[1]).to.equal(this.previousExecutionDelay); // currentDelay - expect(access[2]).to.equal(this.newExecutionDelay); // pendingDelay - expect(access[3]).to.equal(this.grantTimestamp + this.delay); // pendingDelayEffect - - // Not in effect yet - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.previousExecutionDelay.toString(), - ]); - }); - }, - after: function self() { - self.mineDelay = true; - - it('changes the execution delay', async function () { - // Access is correctly stored - const access = await this.manager.getAccess(ANOTHER_ROLE, this.user); - - expect(access[0]).to.equal(this.oldAccess[0]); // inEffectSince - expect(access[1]).to.equal(this.newExecutionDelay); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // pendingDelayEffect - - // Already in effect - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - this.newExecutionDelay.toString(), - ]); - }); - }, - }); - }); - }); - }); - }); - - describe('#revokeRole', function () { - describe('restrictions', function () { - beforeEach('set method and args', async function () { - const args = [ANOTHER_ROLE, this.other.address]; - const method = this.manager.interface.getFunction('revokeRole(uint64,address)'); - this.calldata = this.manager.interface.encodeFunctionData(method, args); - - // Need to be set before revoking - await this.manager.$_grantRole(...args, 0, 0); - }); - - shouldBehaveLikeRoleAdminOperation(ANOTHER_ADMIN); - }); - - describe('when role has been granted', function () { - beforeEach('grant role with grant delay', async function () { - this.grantDelay = time.duration.weeks(1); - await this.manager.$_grantRole(ANOTHER_ROLE, this.user, this.grantDelay, 0); - - this.delay = this.grantDelay; // For testAsDelay - }); - - testAsDelay('grant', { - before: function self() { - self.mineDelay = true; - - it('revokes a granted role that will take effect in the future', async function () { - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - false, - '0', - ]); - - await expect(this.manager.connect(this.admin).revokeRole(ANOTHER_ROLE, this.user)) - .to.emit(this.manager, 'RoleRevoked') - .withArgs(ANOTHER_ROLE, this.user); - - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - false, - '0', - ]); - - const access = await this.manager.getAccess(ANOTHER_ROLE, this.user); - expect(access[0]).to.equal(0n); // inRoleSince - expect(access[1]).to.equal(0n); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // effect - }); - }, - after: function self() { - self.mineDelay = true; - - it('revokes a granted role that already took effect', async function () { - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - true, - '0', - ]); - - await expect(this.manager.connect(this.admin).revokeRole(ANOTHER_ROLE, this.user)) - .to.emit(this.manager, 'RoleRevoked') - .withArgs(ANOTHER_ROLE, this.user); - - expect(await this.manager.hasRole(ANOTHER_ROLE, this.user).then(formatAccess)).to.be.deep.equal([ - false, - '0', - ]); - - const access = await this.manager.getAccess(ANOTHER_ROLE, this.user); - expect(access[0]).to.equal(0n); // inRoleSince - expect(access[1]).to.equal(0n); // currentDelay - expect(access[2]).to.equal(0n); // pendingDelay - expect(access[3]).to.equal(0n); // effect - }); - }, - }); - }); - - describe('when role has not been granted', function () { - it('has no effect', async function () { - expect(await this.manager.hasRole(this.roles.SOME.id, this.user).then(formatAccess)).to.be.deep.equal([ - false, - '0', - ]); - await expect(this.manager.connect(this.roleAdmin).revokeRole(this.roles.SOME.id, this.user)).to.not.emit( - this.manager, - 'RoleRevoked', - ); - expect(await this.manager.hasRole(this.roles.SOME.id, this.user).then(formatAccess)).to.be.deep.equal([ - false, - '0', - ]); - }); - }); - - it('reverts revoking PUBLIC_ROLE', async function () { - await expect(this.manager.connect(this.admin).revokeRole(this.roles.PUBLIC.id, this.user)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerLockedRole') - .withArgs(this.roles.PUBLIC.id); - }); - }); - }); - - describe('self role operations', function () { - describe('#renounceRole', function () { - beforeEach('grant role', async function () { - this.role = { id: 783164n }; - this.caller = this.user; - await this.manager.$_grantRole(this.role.id, this.caller, 0, 0); - }); - - it('renounces a role', async function () { - expect(await this.manager.hasRole(this.role.id, this.caller).then(formatAccess)).to.be.deep.equal([ - true, - '0', - ]); - await expect(this.manager.connect(this.caller).renounceRole(this.role.id, this.caller)) - .to.emit(this.manager, 'RoleRevoked') - .withArgs(this.role.id, this.caller); - expect(await this.manager.hasRole(this.role.id, this.caller).then(formatAccess)).to.be.deep.equal([ - false, - '0', - ]); - }); - - it('reverts if renouncing the PUBLIC_ROLE', async function () { - await expect(this.manager.connect(this.caller).renounceRole(this.roles.PUBLIC.id, this.caller)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerLockedRole') - .withArgs(this.roles.PUBLIC.id); - }); - - it('reverts if renouncing with bad caller confirmation', async function () { - await expect( - this.manager.connect(this.caller).renounceRole(this.role.id, this.other), - ).to.be.revertedWithCustomError(this.manager, 'AccessManagerBadConfirmation'); - }); - }); - }); - }); - }); - - describe('access managed self operations', function () { - describe('when calling a restricted target function', function () { - const method = 'fnRestricted()'; - - beforeEach('set required role', async function () { - this.role = { id: 785913n }; - await this.manager.$_setTargetFunctionRole( - this.manager, - this.manager[method].getFragment().selector, - this.role.id, - ); - }); - - describe('restrictions', function () { - beforeEach('set method and args', function () { - this.caller = this.user; - this.calldata = this.manager.interface.encodeFunctionData(method, []); - }); - - shouldBehaveLikeASelfRestrictedOperation(); - }); - - it('succeeds called by a role member', async function () { - await this.manager.$_grantRole(this.role.id, this.user, 0, 0); - - await expect(this.manager.connect(this.user)[method]()) - .to.emit(this.manager, 'CalledRestricted') - .withArgs(this.user); - }); - }); - - describe('when calling a non-restricted target function', function () { - const method = 'fnUnrestricted()'; - - beforeEach('set required role', async function () { - this.role = { id: 879435n }; - await this.manager.$_setTargetFunctionRole( - this.manager, - this.manager[method].getFragment().selector, - this.role.id, - ); - }); - - it('succeeds called by anyone', async function () { - await expect(this.manager.connect(this.user)[method]()) - .to.emit(this.manager, 'CalledUnrestricted') - .withArgs(this.user); - }); - }); - }); - - describe('access managed target operations', function () { - describe('when calling a restricted target function', function () { - const method = 'fnRestricted()'; - - beforeEach('set required role', async function () { - this.role = { id: 3597243n }; - await this.manager.$_setTargetFunctionRole( - this.target, - this.target[method].getFragment().selector, - this.role.id, - ); - }); - - describe('restrictions', function () { - beforeEach('set method and args', function () { - this.caller = this.user; - this.calldata = this.target.interface.encodeFunctionData(method, []); - }); - - shouldBehaveLikeAManagedRestrictedOperation(); - }); - - it('succeeds called by a role member', async function () { - await this.manager.$_grantRole(this.role.id, this.user, 0, 0); - - await expect(this.target.connect(this.user)[method]()) - .to.emit(this.target, 'CalledRestricted') - .withArgs(this.user); - }); - }); - - describe('when calling a non-restricted target function', function () { - const method = 'fnUnrestricted()'; - - beforeEach('set required role', async function () { - this.role = { id: 879435n }; - await this.manager.$_setTargetFunctionRole( - this.target, - this.target[method].getFragment().selector, - this.role.id, - ); - }); - - it('succeeds called by anyone', async function () { - await expect(this.target.connect(this.user)[method]()) - .to.emit(this.target, 'CalledUnrestricted') - .withArgs(this.user); - }); - }); - }); - - describe('#schedule', function () { - beforeEach('set target function role', async function () { - this.method = this.target.fnRestricted.getFragment(); - this.role = { id: 498305n }; - this.caller = this.user; - - await this.manager.$_setTargetFunctionRole(this.target, this.method.selector, this.role.id); - await this.manager.$_grantRole(this.role.id, this.caller, 0, 1); // nonzero execution delay - - this.calldata = this.target.interface.encodeFunctionData(this.method, []); - this.delay = time.duration.weeks(2); - }); - - describe('restrictions', function () { - testAsCanCall({ - closed() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - const { schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.delay, - }); - await expect(schedule()) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - open: { - callerIsTheManager: { - executing() { - it.skip('is not reachable because schedule is not restrictable'); - }, - notExecuting() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - const { schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.delay, - }); - await expect(schedule()) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - }, - callerIsNotTheManager: { - publicRoleIsRequired() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - // prepareOperation is not used here because it alters the next block timestamp - await expect(this.manager.connect(this.caller).schedule(this.target, this.calldata, MAX_UINT48)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - specificRoleIsRequired: { - requiredRoleIsGranted: { - roleGrantingIsDelayed: { - callerHasAnExecutionDelay: { - beforeGrantDelay() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - // prepareOperation is not used here because it alters the next block timestamp - await expect(this.manager.connect(this.caller).schedule(this.target, this.calldata, MAX_UINT48)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - afterGrantDelay() { - it('succeeds', async function () { - // prepareOperation is not used here because it alters the next block timestamp - await this.manager.connect(this.caller).schedule(this.target, this.calldata, MAX_UINT48); - }); - }, - }, - callerHasNoExecutionDelay: { - beforeGrantDelay() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - // prepareOperation is not used here because it alters the next block timestamp - await expect(this.manager.connect(this.caller).schedule(this.target, this.calldata, MAX_UINT48)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - afterGrantDelay() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - // prepareOperation is not used here because it alters the next block timestamp - await expect(this.manager.connect(this.caller).schedule(this.target, this.calldata, MAX_UINT48)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - }, - }, - roleGrantingIsNotDelayed: { - callerHasAnExecutionDelay() { - it('succeeds', async function () { - const { schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.delay, - }); - - await schedule(); - }); - }, - callerHasNoExecutionDelay() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - // prepareOperation is not used here because it alters the next block timestamp - await expect(this.manager.connect(this.caller).schedule(this.target, this.calldata, MAX_UINT48)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - }, - }, - requiredRoleIsNotGranted() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - const { schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.delay, - }); - await expect(schedule()) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - }, - }, - }, - }); - }); - - it('schedules an operation at the specified execution date if it is larger than caller execution delay', async function () { - const { operationId, scheduledAt, schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.delay, - }); - - const txResponse = await schedule(); - - expect(await this.manager.getSchedule(operationId)).to.equal(scheduledAt + this.delay); - await expect(txResponse) - .to.emit(this.manager, 'OperationScheduled') - .withArgs(operationId, '1', scheduledAt + this.delay, this.caller, this.target, this.calldata); - }); - - it('schedules an operation at the minimum execution date if no specified execution date (when == 0)', async function () { - const executionDelay = await time.duration.hours(72); - await this.manager.$_grantRole(this.role.id, this.caller, 0, executionDelay); - - const txResponse = await this.manager.connect(this.caller).schedule(this.target, this.calldata, 0); - const scheduledAt = await time.clockFromReceipt.timestamp(txResponse); - - const operationId = await this.manager.hashOperation(this.caller, this.target, this.calldata); - - expect(await this.manager.getSchedule(operationId)).to.equal(scheduledAt + executionDelay); - await expect(txResponse) - .to.emit(this.manager, 'OperationScheduled') - .withArgs(operationId, '1', scheduledAt + executionDelay, this.caller, this.target, this.calldata); - }); - - it('increases the nonce of an operation scheduled more than once', async function () { - // Setup and check initial nonce - const expectedOperationId = hashOperation(this.caller, this.target, this.calldata); - expect(await this.manager.getNonce(expectedOperationId)).to.equal('0'); - - // Schedule - const op1 = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.delay, - }); - await expect(op1.schedule()) - .to.emit(this.manager, 'OperationScheduled') - .withArgs(op1.operationId, 1n, op1.scheduledAt + this.delay, this.caller, this.target, this.calldata); - expect(expectedOperationId).to.equal(op1.operationId); - - // Consume - await time.increaseBy.timestamp(this.delay); - await this.manager.$_consumeScheduledOp(expectedOperationId); - - // Check nonce - expect(await this.manager.getNonce(expectedOperationId)).to.equal('1'); - - // Schedule again - const op2 = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.delay, - }); - await expect(op2.schedule()) - .to.emit(this.manager, 'OperationScheduled') - .withArgs(op2.operationId, 2n, op2.scheduledAt + this.delay, this.caller, this.target, this.calldata); - expect(expectedOperationId).to.equal(op2.operationId); - - // Check final nonce - expect(await this.manager.getNonce(expectedOperationId)).to.equal('2'); - }); - - it('reverts if the specified execution date is before the current timestamp + caller execution delay', async function () { - const executionDelay = time.duration.weeks(1) + this.delay; - await this.manager.$_grantRole(this.role.id, this.caller, 0, executionDelay); - - const { schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.delay, - }); - - await expect(schedule()) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - - it('reverts if an operation is already schedule', async function () { - const op1 = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.delay, - }); - - await op1.schedule(); - - const op2 = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.delay, - }); - - await expect(op2.schedule()) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerAlreadyScheduled') - .withArgs(op1.operationId); - }); - - it('panics scheduling calldata with less than 4 bytes', async function () { - const calldata = '0x1234'; // 2 bytes - - // Managed contract - const op1 = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: calldata, - delay: this.delay, - }); - await expect(op1.schedule()).to.be.revertedWithoutReason(); - - // Manager contract - const op2 = await prepareOperation(this.manager, { - caller: this.caller, - target: this.manager, - calldata: calldata, - delay: this.delay, - }); - await expect(op2.schedule()).to.be.revertedWithoutReason(); - }); - - it('reverts scheduling an unknown operation to the manager', async function () { - const calldata = '0x12345678'; - - const { schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.manager, - calldata, - delay: this.delay, - }); - - await expect(schedule()) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.manager, calldata); - }); - }); - - describe('#execute', function () { - beforeEach('set target function role', async function () { - this.method = this.target.fnRestricted.getFragment(); - this.role = { id: 9825430n }; - this.caller = this.user; - - await this.manager.$_setTargetFunctionRole(this.target, this.method.selector, this.role.id); - await this.manager.$_grantRole(this.role.id, this.caller, 0, 0); - - this.calldata = this.target.interface.encodeFunctionData(this.method, []); - }); - - describe('restrictions', function () { - testAsCanCall({ - closed() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - await expect(this.manager.connect(this.caller).execute(this.target, this.calldata)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - open: { - callerIsTheManager: { - executing() { - it('succeeds', async function () { - await this.manager.connect(this.caller).execute(this.target, this.calldata); - }); - }, - notExecuting() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - await expect(this.manager.connect(this.caller).execute(this.target, this.calldata)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - }, - callerIsNotTheManager: { - publicRoleIsRequired() { - it('succeeds', async function () { - await this.manager.connect(this.caller).execute(this.target, this.calldata); - }); - }, - specificRoleIsRequired: { - requiredRoleIsGranted: { - roleGrantingIsDelayed: { - callerHasAnExecutionDelay: { - beforeGrantDelay() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - await expect(this.manager.connect(this.caller).execute(this.target, this.calldata)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - afterGrantDelay: function self() { - self.mineDelay = true; - - beforeEach('define schedule delay', function () { - this.scheduleIn = time.duration.days(21); // For testAsSchedulableOperation - }); - - testAsSchedulableOperation(LIKE_COMMON_SCHEDULABLE); - }, - }, - callerHasNoExecutionDelay: { - beforeGrantDelay() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - await expect(this.manager.connect(this.caller).execute(this.target, this.calldata)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - afterGrantDelay: function self() { - self.mineDelay = true; - - it('succeeds', async function () { - await this.manager.connect(this.caller).execute(this.target, this.calldata); - }); - }, - }, - }, - roleGrantingIsNotDelayed: { - callerHasAnExecutionDelay() { - beforeEach('define schedule delay', function () { - this.scheduleIn = time.duration.days(15); // For testAsSchedulableOperation - }); - - testAsSchedulableOperation(LIKE_COMMON_SCHEDULABLE); - }, - callerHasNoExecutionDelay() { - it('succeeds', async function () { - await this.manager.connect(this.caller).execute(this.target, this.calldata); - }); - }, - }, - }, - requiredRoleIsNotGranted() { - it('reverts as AccessManagerUnauthorizedCall', async function () { - await expect(this.manager.connect(this.caller).execute(this.target, this.calldata)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.caller, this.target, this.calldata.substring(0, 10)); - }); - }, - }, - }, - }, - }); - }); - - it('executes with a delay consuming the scheduled operation', async function () { - const delay = time.duration.hours(4); - await this.manager.$_grantRole(this.role.id, this.caller, 0, 1); // Execution delay is needed so the operation is consumed - - const { operationId, schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay, - }); - await schedule(); - await time.increaseBy.timestamp(delay); - await expect(this.manager.connect(this.caller).execute(this.target, this.calldata)) - .to.emit(this.manager, 'OperationExecuted') - .withArgs(operationId, 1n); - - expect(await this.manager.getSchedule(operationId)).to.equal(0n); - }); - - it('executes with no delay consuming a scheduled operation', async function () { - const delay = time.duration.hours(4); - - // give caller an execution delay - await this.manager.$_grantRole(this.role.id, this.caller, 0, 1); - - const { operationId, schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay, - }); - await schedule(); - - // remove the execution delay - await this.manager.$_grantRole(this.role.id, this.caller, 0, 0); - - await time.increaseBy.timestamp(delay); - await expect(this.manager.connect(this.caller).execute(this.target, this.calldata)) - .to.emit(this.manager, 'OperationExecuted') - .withArgs(operationId, 1n); - - expect(await this.manager.getSchedule(operationId)).to.equal(0n); - }); - - it('keeps the original _executionId after finishing the call', async function () { - const executionIdBefore = await ethers.provider.getStorage(this.manager, EXECUTION_ID_STORAGE_SLOT); - await this.manager.connect(this.caller).execute(this.target, this.calldata); - const executionIdAfter = await ethers.provider.getStorage(this.manager, EXECUTION_ID_STORAGE_SLOT); - expect(executionIdBefore).to.equal(executionIdAfter); - }); - - it('reverts executing twice', async function () { - const delay = time.duration.hours(2); - await this.manager.$_grantRole(this.role.id, this.caller, 0, 1); // Execution delay is needed so the operation is consumed - - const { operationId, schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay, - }); - await schedule(); - await time.increaseBy.timestamp(delay); - await this.manager.connect(this.caller).execute(this.target, this.calldata); - await expect(this.manager.connect(this.caller).execute(this.target, this.calldata)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerNotScheduled') - .withArgs(operationId); - }); - }); - - describe('#consumeScheduledOp', function () { - beforeEach('define scheduling parameters', async function () { - const method = this.target.fnRestricted.getFragment(); - this.caller = await ethers.getSigner(this.target.target); - await impersonate(this.caller.address); - this.calldata = this.target.interface.encodeFunctionData(method, []); - this.role = { id: 9834983n }; - - await this.manager.$_setTargetFunctionRole(this.target, method.selector, this.role.id); - await this.manager.$_grantRole(this.role.id, this.caller, 0, 1); // nonzero execution delay - - this.scheduleIn = time.duration.hours(10); // For testAsSchedulableOperation - }); - - describe('when caller is not consuming scheduled operation', function () { - beforeEach('set consuming false', async function () { - await this.target.setIsConsumingScheduledOp(false, ethers.toBeHex(CONSUMING_SCHEDULE_STORAGE_SLOT, 32)); - }); - - it('reverts as AccessManagerUnauthorizedConsume', async function () { - await expect(this.manager.connect(this.caller).consumeScheduledOp(this.caller, this.calldata)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedConsume') - .withArgs(this.caller); - }); - }); - - describe('when caller is consuming scheduled operation', function () { - beforeEach('set consuming true', async function () { - await this.target.setIsConsumingScheduledOp(true, ethers.toBeHex(CONSUMING_SCHEDULE_STORAGE_SLOT, 32)); - }); - - testAsSchedulableOperation({ - scheduled: { - before() { - it('reverts as AccessManagerNotReady', async function () { - await expect(this.manager.connect(this.caller).consumeScheduledOp(this.caller, this.calldata)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerNotReady') - .withArgs(this.operationId); - }); - }, - after() { - it('consumes the scheduled operation and resets timepoint', async function () { - expect(await this.manager.getSchedule(this.operationId)).to.equal(this.scheduledAt + this.scheduleIn); - - await expect(this.manager.connect(this.caller).consumeScheduledOp(this.caller, this.calldata)) - .to.emit(this.manager, 'OperationExecuted') - .withArgs(this.operationId, 1n); - expect(await this.manager.getSchedule(this.operationId)).to.equal(0n); - }); - }, - expired() { - it('reverts as AccessManagerExpired', async function () { - await expect(this.manager.connect(this.caller).consumeScheduledOp(this.caller, this.calldata)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerExpired') - .withArgs(this.operationId); - }); - }, - }, - notScheduled() { - it('reverts as AccessManagerNotScheduled', async function () { - await expect(this.manager.connect(this.caller).consumeScheduledOp(this.caller, this.calldata)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerNotScheduled') - .withArgs(this.operationId); - }); - }, - }); - }); - }); - - describe('#cancelScheduledOp', function () { - beforeEach('setup scheduling', async function () { - this.method = this.target.fnRestricted.getFragment(); - this.caller = this.roles.SOME.members[0]; - await this.manager.$_setTargetFunctionRole(this.target, this.method.selector, this.roles.SOME.id); - await this.manager.$_grantRole(this.roles.SOME.id, this.caller, 0, 1); // nonzero execution delay - - this.calldata = this.target.interface.encodeFunctionData(this.method, []); - this.scheduleIn = time.duration.days(10); // For testAsSchedulableOperation - }); - - testAsSchedulableOperation({ - scheduled: { - before() { - describe('when caller is the scheduler', function () { - it('succeeds', async function () { - await this.manager.connect(this.caller).cancel(this.caller, this.target, this.calldata); - }); - }); - - describe('when caller is an admin', function () { - it('succeeds', async function () { - await this.manager.connect(this.roles.ADMIN.members[0]).cancel(this.caller, this.target, this.calldata); - }); - }); - - describe('when caller is the role guardian', function () { - it('succeeds', async function () { - await this.manager - .connect(this.roles.SOME_GUARDIAN.members[0]) - .cancel(this.caller, this.target, this.calldata); - }); - }); - - describe('when caller is any other account', function () { - it('reverts as AccessManagerUnauthorizedCancel', async function () { - await expect(this.manager.connect(this.other).cancel(this.caller, this.target, this.calldata)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCancel') - .withArgs(this.other, this.caller, this.target, this.method.selector); - }); - }); - }, - after() { - it('succeeds', async function () { - await this.manager.connect(this.caller).cancel(this.caller, this.target, this.calldata); - }); - }, - expired() { - it('succeeds', async function () { - await this.manager.connect(this.caller).cancel(this.caller, this.target, this.calldata); - }); - }, - }, - notScheduled() { - it('reverts as AccessManagerNotScheduled', async function () { - await expect(this.manager.cancel(this.caller, this.target, this.calldata)) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerNotScheduled') - .withArgs(this.operationId); - }); - }, - }); - - it('cancels an operation and resets schedule', async function () { - const { operationId, schedule } = await prepareOperation(this.manager, { - caller: this.caller, - target: this.target, - calldata: this.calldata, - delay: this.scheduleIn, - }); - await schedule(); - await expect(this.manager.connect(this.caller).cancel(this.caller, this.target, this.calldata)) - .to.emit(this.manager, 'OperationCanceled') - .withArgs(operationId, 1n); - expect(await this.manager.getSchedule(operationId)).to.equal('0'); - }); - }); - - describe('with Ownable target contract', function () { - const roleId = 1n; - - beforeEach(async function () { - this.ownable = await ethers.deployContract('$Ownable', [this.manager]); - - // add user to role - await this.manager.$_grantRole(roleId, this.user, 0, 0); - }); - - it('initial state', async function () { - expect(await this.ownable.owner()).to.equal(this.manager); - }); - - describe('Contract is closed', function () { - beforeEach(async function () { - await this.manager.$_setTargetClosed(this.ownable, true); - }); - - it('directly call: reverts', async function () { - await expect(this.ownable.connect(this.user).$_checkOwner()) - .to.be.revertedWithCustomError(this.ownable, 'OwnableUnauthorizedAccount') - .withArgs(this.user); - }); - - it('relayed call (with role): reverts', async function () { - await expect( - this.manager.connect(this.user).execute(this.ownable, this.ownable.$_checkOwner.getFragment().selector), - ) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.user, this.ownable, this.ownable.$_checkOwner.getFragment().selector); - }); - - it('relayed call (without role): reverts', async function () { - await expect( - this.manager.connect(this.other).execute(this.ownable, this.ownable.$_checkOwner.getFragment().selector), - ) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.other, this.ownable, this.ownable.$_checkOwner.getFragment().selector); - }); - }); - - describe('Contract is managed', function () { - describe('function is open to specific role', function () { - beforeEach(async function () { - await this.manager.$_setTargetFunctionRole( - this.ownable, - this.ownable.$_checkOwner.getFragment().selector, - roleId, - ); - }); - - it('directly call: reverts', async function () { - await expect(this.ownable.connect(this.user).$_checkOwner()) - .to.be.revertedWithCustomError(this.ownable, 'OwnableUnauthorizedAccount') - .withArgs(this.user); - }); - - it('relayed call (with role): success', async function () { - await this.manager.connect(this.user).execute(this.ownable, this.ownable.$_checkOwner.getFragment().selector); - }); - - it('relayed call (without role): reverts', async function () { - await expect( - this.manager.connect(this.other).execute(this.ownable, this.ownable.$_checkOwner.getFragment().selector), - ) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerUnauthorizedCall') - .withArgs(this.other, this.ownable, this.ownable.$_checkOwner.getFragment().selector); - }); - }); - - describe('function is open to public role', function () { - beforeEach(async function () { - await this.manager.$_setTargetFunctionRole( - this.ownable, - this.ownable.$_checkOwner.getFragment().selector, - this.roles.PUBLIC.id, - ); - }); - - it('directly call: reverts', async function () { - await expect(this.ownable.connect(this.user).$_checkOwner()) - .to.be.revertedWithCustomError(this.ownable, 'OwnableUnauthorizedAccount') - .withArgs(this.user); - }); - - it('relayed call (with role): success', async function () { - await this.manager.connect(this.user).execute(this.ownable, this.ownable.$_checkOwner.getFragment().selector); - }); - - it('relayed call (without role): success', async function () { - await this.manager - .connect(this.other) - .execute(this.ownable, this.ownable.$_checkOwner.getFragment().selector); - }); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AuthorityUtils.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AuthorityUtils.test.js deleted file mode 100644 index 905913f14c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/access/manager/AuthorityUtils.test.js +++ /dev/null @@ -1,102 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -async function fixture() { - const [user, other] = await ethers.getSigners(); - - const mock = await ethers.deployContract('$AuthorityUtils'); - const notAuthorityMock = await ethers.deployContract('NotAuthorityMock'); - const authorityNoDelayMock = await ethers.deployContract('AuthorityNoDelayMock'); - const authorityDelayMock = await ethers.deployContract('AuthorityDelayMock'); - const authorityNoResponse = await ethers.deployContract('AuthorityNoResponse'); - - return { - user, - other, - mock, - notAuthorityMock, - authorityNoDelayMock, - authorityDelayMock, - authorityNoResponse, - }; -} - -describe('AuthorityUtils', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('canCallWithDelay', function () { - describe('when authority does not have a canCall function', function () { - beforeEach(async function () { - this.authority = this.notAuthorityMock; - }); - - it('returns (immediate = 0, delay = 0)', async function () { - const { immediate, delay } = await this.mock.$canCallWithDelay( - this.authority, - this.user, - this.other, - '0x12345678', - ); - expect(immediate).to.be.false; - expect(delay).to.equal(0n); - }); - }); - - describe('when authority has no delay', function () { - beforeEach(async function () { - this.authority = this.authorityNoDelayMock; - this.immediate = true; - await this.authority._setImmediate(this.immediate); - }); - - it('returns (immediate, delay = 0)', async function () { - const { immediate, delay } = await this.mock.$canCallWithDelay( - this.authority, - this.user, - this.other, - '0x12345678', - ); - expect(immediate).to.equal(this.immediate); - expect(delay).to.equal(0n); - }); - }); - - describe('when authority replies with a delay', function () { - beforeEach(async function () { - this.authority = this.authorityDelayMock; - }); - - for (const immediate of [true, false]) { - for (const delay of [0n, 42n]) { - it(`returns (immediate=${immediate}, delay=${delay})`, async function () { - await this.authority._setImmediate(immediate); - await this.authority._setDelay(delay); - const result = await this.mock.$canCallWithDelay(this.authority, this.user, this.other, '0x12345678'); - expect(result.immediate).to.equal(immediate); - expect(result.delay).to.equal(delay); - }); - } - } - }); - - describe('when authority replies with empty data', function () { - beforeEach(async function () { - this.authority = this.authorityNoResponse; - }); - - it('returns (immediate = 0, delay = 0)', async function () { - const { immediate, delay } = await this.mock.$canCallWithDelay( - this.authority, - this.user, - this.other, - '0x12345678', - ); - expect(immediate).to.be.false; - expect(delay).to.equal(0n); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/account/utils/draft-ERC4337Utils.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/account/utils/draft-ERC4337Utils.test.js deleted file mode 100644 index 7c292910df..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/account/utils/draft-ERC4337Utils.test.js +++ /dev/null @@ -1,288 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { packValidationData, UserOperation } = require('../../helpers/erc4337'); -const { deployEntrypoint } = require('../../helpers/erc4337-entrypoint'); -const { MAX_UINT48 } = require('../../helpers/constants'); -const ADDRESS_ONE = '0x0000000000000000000000000000000000000001'; - -const fixture = async () => { - const { entrypoint } = await deployEntrypoint(); - const [authorizer, sender, factory, paymaster] = await ethers.getSigners(); - const utils = await ethers.deployContract('$ERC4337Utils'); - const SIG_VALIDATION_SUCCESS = await utils.$SIG_VALIDATION_SUCCESS(); - const SIG_VALIDATION_FAILED = await utils.$SIG_VALIDATION_FAILED(); - return { utils, authorizer, sender, entrypoint, factory, paymaster, SIG_VALIDATION_SUCCESS, SIG_VALIDATION_FAILED }; -}; - -describe('ERC4337Utils', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('parseValidationData', function () { - it('parses the validation data', async function () { - const authorizer = this.authorizer; - const validUntil = 0x12345678n; - const validAfter = 0x9abcdef0n; - const validationData = packValidationData(validAfter, validUntil, authorizer); - - expect(this.utils.$parseValidationData(validationData)).to.eventually.deep.equal([ - authorizer.address, - validAfter, - validUntil, - ]); - }); - - it('returns an type(uint48).max if until is 0', async function () { - const authorizer = this.authorizer; - const validAfter = 0x12345678n; - const validationData = packValidationData(validAfter, 0, authorizer); - - expect(this.utils.$parseValidationData(validationData)).to.eventually.deep.equal([ - authorizer.address, - validAfter, - MAX_UINT48, - ]); - }); - - it('parse canonical values', async function () { - expect(this.utils.$parseValidationData(this.SIG_VALIDATION_SUCCESS)).to.eventually.deep.equal([ - ethers.ZeroAddress, - 0n, - MAX_UINT48, - ]); - - expect(this.utils.$parseValidationData(this.SIG_VALIDATION_FAILED)).to.eventually.deep.equal([ - ADDRESS_ONE, - 0n, - MAX_UINT48, - ]); - }); - }); - - describe('packValidationData', function () { - it('packs the validation data', async function () { - const authorizer = this.authorizer; - const validUntil = 0x12345678n; - const validAfter = 0x9abcdef0n; - const validationData = packValidationData(validAfter, validUntil, authorizer); - - expect( - this.utils.$packValidationData(ethers.Typed.address(authorizer), validAfter, validUntil), - ).to.eventually.equal(validationData); - }); - - it('packs the validation data (bool)', async function () { - const success = false; - const validUntil = 0x12345678n; - const validAfter = 0x9abcdef0n; - const validationData = packValidationData(validAfter, validUntil, false); - - expect(this.utils.$packValidationData(ethers.Typed.bool(success), validAfter, validUntil)).to.eventually.equal( - validationData, - ); - }); - - it('packing reproduced canonical values', async function () { - expect(this.utils.$packValidationData(ethers.Typed.address(ethers.ZeroAddress), 0n, 0n)).to.eventually.equal( - this.SIG_VALIDATION_SUCCESS, - ); - expect(this.utils.$packValidationData(ethers.Typed.bool(true), 0n, 0n)).to.eventually.equal( - this.SIG_VALIDATION_SUCCESS, - ); - expect(this.utils.$packValidationData(ethers.Typed.address(ADDRESS_ONE), 0n, 0n)).to.eventually.equal( - this.SIG_VALIDATION_FAILED, - ); - expect(this.utils.$packValidationData(ethers.Typed.bool(false), 0n, 0n)).to.eventually.equal( - this.SIG_VALIDATION_FAILED, - ); - }); - }); - - describe('combineValidationData', function () { - const validUntil1 = 0x12345678n; - const validAfter1 = 0x9abcdef0n; - const validUntil2 = 0x87654321n; - const validAfter2 = 0xabcdef90n; - - it('combines the validation data', async function () { - const validationData1 = packValidationData(validAfter1, validUntil1, ethers.ZeroAddress); - const validationData2 = packValidationData(validAfter2, validUntil2, ethers.ZeroAddress); - const expected = packValidationData(validAfter2, validUntil1, true); - - // check symmetry - expect(this.utils.$combineValidationData(validationData1, validationData2)).to.eventually.equal(expected); - expect(this.utils.$combineValidationData(validationData2, validationData1)).to.eventually.equal(expected); - }); - - for (const [authorizer1, authorizer2] of [ - [ethers.ZeroAddress, '0xbf023313b891fd6000544b79e353323aa94a4f29'], - ['0xbf023313b891fd6000544b79e353323aa94a4f29', ethers.ZeroAddress], - ]) { - it('returns SIG_VALIDATION_FAILURE if one of the authorizers is not address(0)', async function () { - const validationData1 = packValidationData(validAfter1, validUntil1, authorizer1); - const validationData2 = packValidationData(validAfter2, validUntil2, authorizer2); - const expected = packValidationData(validAfter2, validUntil1, false); - - // check symmetry - expect(this.utils.$combineValidationData(validationData1, validationData2)).to.eventually.equal(expected); - expect(this.utils.$combineValidationData(validationData2, validationData1)).to.eventually.equal(expected); - }); - } - }); - - describe('getValidationData', function () { - it('returns the validation data with valid validity range', async function () { - const aggregator = this.authorizer; - const validAfter = 0; - const validUntil = MAX_UINT48; - const validationData = packValidationData(validAfter, validUntil, aggregator); - - expect(this.utils.$getValidationData(validationData)).to.eventually.deep.equal([aggregator.address, false]); - }); - - it('returns the validation data with invalid validity range (expired)', async function () { - const aggregator = this.authorizer; - const validAfter = 0; - const validUntil = 1; - const validationData = packValidationData(validAfter, validUntil, aggregator); - - expect(this.utils.$getValidationData(validationData)).to.eventually.deep.equal([aggregator.address, true]); - }); - - it('returns the validation data with invalid validity range (not yet valid)', async function () { - const aggregator = this.authorizer; - const validAfter = MAX_UINT48; - const validUntil = MAX_UINT48; - const validationData = packValidationData(validAfter, validUntil, aggregator); - - expect(this.utils.$getValidationData(validationData)).to.eventually.deep.equal([aggregator.address, true]); - }); - - it('returns address(0) and false for validationData = 0', function () { - expect(this.utils.$getValidationData(0n)).to.eventually.deep.equal([ethers.ZeroAddress, false]); - }); - }); - - describe('hash', function () { - it('returns the operation hash with specified entrypoint and chainId', async function () { - const userOp = new UserOperation({ sender: this.sender, nonce: 1 }); - const chainId = await ethers.provider.getNetwork().then(({ chainId }) => chainId); - const otherChainId = 0xdeadbeef; - - // check that helper matches entrypoint logic - expect(this.entrypoint.getUserOpHash(userOp.packed)).to.eventually.equal(userOp.hash(this.entrypoint, chainId)); - - // check library against helper - expect(this.utils.$hash(userOp.packed, this.entrypoint, chainId)).to.eventually.equal( - userOp.hash(this.entrypoint, chainId), - ); - expect(this.utils.$hash(userOp.packed, this.entrypoint, otherChainId)).to.eventually.equal( - userOp.hash(this.entrypoint, otherChainId), - ); - }); - }); - - describe('userOp values', function () { - describe('intiCode', function () { - beforeEach(async function () { - this.userOp = new UserOperation({ - sender: this.sender, - nonce: 1, - verificationGas: 0x12345678n, - factory: this.factory, - factoryData: '0x123456', - }); - - this.emptyUserOp = new UserOperation({ - sender: this.sender, - nonce: 1, - }); - }); - - it('returns factory', async function () { - expect(this.utils.$factory(this.userOp.packed)).to.eventually.equal(this.factory); - expect(this.utils.$factory(this.emptyUserOp.packed)).to.eventually.equal(ethers.ZeroAddress); - }); - - it('returns factoryData', async function () { - expect(this.utils.$factoryData(this.userOp.packed)).to.eventually.equal('0x123456'); - expect(this.utils.$factoryData(this.emptyUserOp.packed)).to.eventually.equal('0x'); - }); - }); - - it('returns verificationGasLimit', async function () { - const userOp = new UserOperation({ sender: this.sender, nonce: 1, verificationGas: 0x12345678n }); - expect(this.utils.$verificationGasLimit(userOp.packed)).to.eventually.equal(userOp.verificationGas); - }); - - it('returns callGasLimit', async function () { - const userOp = new UserOperation({ sender: this.sender, nonce: 1, callGas: 0x12345678n }); - expect(this.utils.$callGasLimit(userOp.packed)).to.eventually.equal(userOp.callGas); - }); - - it('returns maxPriorityFeePerGas', async function () { - const userOp = new UserOperation({ sender: this.sender, nonce: 1, maxPriorityFee: 0x12345678n }); - expect(this.utils.$maxPriorityFeePerGas(userOp.packed)).to.eventually.equal(userOp.maxPriorityFee); - }); - - it('returns maxFeePerGas', async function () { - const userOp = new UserOperation({ sender: this.sender, nonce: 1, maxFeePerGas: 0x12345678n }); - expect(this.utils.$maxFeePerGas(userOp.packed)).to.eventually.equal(userOp.maxFeePerGas); - }); - - it('returns gasPrice', async function () { - const userOp = new UserOperation({ - sender: this.sender, - nonce: 1, - maxPriorityFee: 0x12345678n, - maxFeePerGas: 0x87654321n, - }); - expect(this.utils.$gasPrice(userOp.packed)).to.eventually.equal(userOp.maxPriorityFee); - }); - - describe('paymasterAndData', function () { - beforeEach(async function () { - this.userOp = new UserOperation({ - sender: this.sender, - nonce: 1, - paymaster: this.paymaster, - paymasterVerificationGasLimit: 0x12345678n, - paymasterPostOpGasLimit: 0x87654321n, - paymasterData: '0xbeefcafe', - }); - - this.emptyUserOp = new UserOperation({ - sender: this.sender, - nonce: 1, - }); - }); - - it('returns paymaster', async function () { - expect(this.utils.$paymaster(this.userOp.packed)).to.eventually.equal(this.userOp.paymaster); - expect(this.utils.$paymaster(this.emptyUserOp.packed)).to.eventually.equal(ethers.ZeroAddress); - }); - - it('returns verificationGasLimit', async function () { - expect(this.utils.$paymasterVerificationGasLimit(this.userOp.packed)).to.eventually.equal( - this.userOp.paymasterVerificationGasLimit, - ); - expect(this.utils.$paymasterVerificationGasLimit(this.emptyUserOp.packed)).to.eventually.equal(0n); - }); - - it('returns postOpGasLimit', async function () { - expect(this.utils.$paymasterPostOpGasLimit(this.userOp.packed)).to.eventually.equal( - this.userOp.paymasterPostOpGasLimit, - ); - expect(this.utils.$paymasterPostOpGasLimit(this.emptyUserOp.packed)).to.eventually.equal(0n); - }); - - it('returns data', async function () { - expect(this.utils.$paymasterData(this.userOp.packed)).to.eventually.equal(this.userOp.paymasterData); - expect(this.utils.$paymasterData(this.emptyUserOp.packed)).to.eventually.equal('0x'); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/account/utils/draft-ERC7579Utils.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/account/utils/draft-ERC7579Utils.t.sol deleted file mode 100644 index fdd4edf595..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/account/utils/draft-ERC7579Utils.t.sol +++ /dev/null @@ -1,421 +0,0 @@ -// SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.24; - -// Parts of this test file are adapted from Adam Egyed (@adamegyed) proof of concept available at: -// https://github.com/adamegyed/erc7579-execute-vulnerability/tree/4589a30ff139e143d6c57183ac62b5c029217a90 -// -// solhint-disable no-console - -import {Ownable} from "@openzeppelin/contracts/access/Ownable.sol"; -import {ECDSA} from "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; -import {MessageHashUtils} from "@openzeppelin/contracts/utils/cryptography/MessageHashUtils.sol"; -import {PackedUserOperation, IAccount, IEntryPoint} from "@openzeppelin/contracts/interfaces/draft-IERC4337.sol"; -import {ERC4337Utils} from "@openzeppelin/contracts/account/utils/draft-ERC4337Utils.sol"; -import {ERC7579Utils, Mode, CallType, ExecType, ModeSelector, ModePayload, Execution} from "@openzeppelin/contracts/account/utils/draft-ERC7579Utils.sol"; -import {Test, Vm, console} from "forge-std/Test.sol"; - -contract SampleAccount is IAccount, Ownable { - using ECDSA for *; - using MessageHashUtils for *; - using ERC4337Utils for *; - using ERC7579Utils for *; - - IEntryPoint internal constant ENTRY_POINT = IEntryPoint(payable(0x0000000071727De22E5E9d8BAf0edAc6f37da032)); - - event Log(bool duringValidation, Execution[] calls); - - error UnsupportedCallType(CallType callType); - - constructor(address initialOwner) Ownable(initialOwner) {} - - function validateUserOp( - PackedUserOperation calldata userOp, - bytes32 userOpHash, - uint256 missingAccountFunds - ) external override returns (uint256 validationData) { - require(msg.sender == address(ENTRY_POINT), "only from EP"); - // Check signature - if (userOpHash.toEthSignedMessageHash().recover(userOp.signature) != owner()) { - revert OwnableUnauthorizedAccount(_msgSender()); - } - - // If this is an execute call with a batch operation, log the call details from the calldata - if (bytes4(userOp.callData[0x00:0x04]) == this.execute.selector) { - (CallType callType, , , ) = Mode.wrap(bytes32(userOp.callData[0x04:0x24])).decodeMode(); - - if (callType == ERC7579Utils.CALLTYPE_BATCH) { - // Remove the selector - bytes calldata params = userOp.callData[0x04:]; - - // Use the same vulnerable assignment technique here, but assert afterwards that the checks aren't - // broken here by comparing to the result of `abi.decode(...)`. - bytes calldata executionCalldata; - assembly ("memory-safe") { - let dataptr := add(params.offset, calldataload(add(params.offset, 0x20))) - executionCalldata.offset := add(dataptr, 32) - executionCalldata.length := calldataload(dataptr) - } - // Check that this decoding step is done correctly. - (, bytes memory executionCalldataMemory) = abi.decode(params, (bytes32, bytes)); - - require( - keccak256(executionCalldata) == keccak256(executionCalldataMemory), - "decoding during validation failed" - ); - // Now, we know that we have `bytes calldata executionCalldata` as would be decoded by the solidity - // builtin decoder for the `execute` function. - - // This is where the vulnerability from ExecutionLib results in a different result between validation - // andexecution. - - emit Log(true, executionCalldata.decodeBatch()); - } - } - - if (missingAccountFunds > 0) { - (bool success, ) = payable(msg.sender).call{value: missingAccountFunds}(""); - success; // Silence warning. The entrypoint should validate the result. - } - - return ERC4337Utils.SIG_VALIDATION_SUCCESS; - } - - function execute(Mode mode, bytes calldata executionCalldata) external payable { - require(msg.sender == address(this) || msg.sender == address(ENTRY_POINT), "not auth"); - - (CallType callType, ExecType execType, , ) = mode.decodeMode(); - - // check if calltype is batch or single - if (callType == ERC7579Utils.CALLTYPE_SINGLE) { - executionCalldata.execSingle(execType); - } else if (callType == ERC7579Utils.CALLTYPE_BATCH) { - executionCalldata.execBatch(execType); - - emit Log(false, executionCalldata.decodeBatch()); - } else if (callType == ERC7579Utils.CALLTYPE_DELEGATECALL) { - executionCalldata.execDelegateCall(execType); - } else { - revert UnsupportedCallType(callType); - } - } -} - -contract ERC7579UtilsTest is Test { - using MessageHashUtils for *; - using ERC4337Utils for *; - using ERC7579Utils for *; - - IEntryPoint private constant ENTRYPOINT = IEntryPoint(payable(0x0000000071727De22E5E9d8BAf0edAc6f37da032)); - address private _owner; - uint256 private _ownerKey; - address private _account; - address private _beneficiary; - address private _recipient1; - address private _recipient2; - - constructor() { - vm.etch(0x0000000071727De22E5E9d8BAf0edAc6f37da032, vm.readFileBinary("test/bin/EntryPoint070.bytecode")); - vm.etch(0xEFC2c1444eBCC4Db75e7613d20C6a62fF67A167C, vm.readFileBinary("test/bin/SenderCreator070.bytecode")); - - // signing key - (_owner, _ownerKey) = makeAddrAndKey("owner"); - - // ERC-4337 account - _account = address(new SampleAccount(_owner)); - vm.deal(_account, 1 ether); - - // other - _beneficiary = makeAddr("beneficiary"); - _recipient1 = makeAddr("recipient1"); - _recipient2 = makeAddr("recipient2"); - } - - function testExecuteBatchDecodeCorrectly() public { - Execution[] memory calls = new Execution[](2); - calls[0] = Execution({target: _recipient1, value: 1 wei, callData: ""}); - calls[1] = Execution({target: _recipient2, value: 1 wei, callData: ""}); - - PackedUserOperation[] memory userOps = new PackedUserOperation[](1); - userOps[0] = PackedUserOperation({ - sender: _account, - nonce: 0, - initCode: "", - callData: abi.encodeCall( - SampleAccount.execute, - ( - ERC7579Utils.encodeMode( - ERC7579Utils.CALLTYPE_BATCH, - ERC7579Utils.EXECTYPE_DEFAULT, - ModeSelector.wrap(0x00), - ModePayload.wrap(0x00) - ), - ERC7579Utils.encodeBatch(calls) - ) - ), - accountGasLimits: _packGas(500_000, 500_000), - preVerificationGas: 0, - gasFees: _packGas(1, 1), - paymasterAndData: "", - signature: "" - }); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - _ownerKey, - this.hashUserOperation(userOps[0]).toEthSignedMessageHash() - ); - userOps[0].signature = abi.encodePacked(r, s, v); - - vm.recordLogs(); - ENTRYPOINT.handleOps(userOps, payable(_beneficiary)); - - assertEq(_recipient1.balance, 1 wei); - assertEq(_recipient2.balance, 1 wei); - - _collectAndPrintLogs(false); - } - - function testExecuteBatchDecodeEmpty() public { - bytes memory fakeCalls = abi.encodePacked( - uint256(1), // Length of execution[] - uint256(0x20), // offset - uint256(uint160(_recipient1)), // target - uint256(1), // value: 1 wei - uint256(0x60), // offset of data - uint256(0) // length of - ); - - PackedUserOperation[] memory userOps = new PackedUserOperation[](1); - userOps[0] = PackedUserOperation({ - sender: _account, - nonce: 0, - initCode: "", - callData: abi.encodeCall( - SampleAccount.execute, - ( - ERC7579Utils.encodeMode( - ERC7579Utils.CALLTYPE_BATCH, - ERC7579Utils.EXECTYPE_DEFAULT, - ModeSelector.wrap(0x00), - ModePayload.wrap(0x00) - ), - abi.encodePacked( - uint256(0x70) // fake offset pointing to paymasterAndData - ) - ) - ), - accountGasLimits: _packGas(500_000, 500_000), - preVerificationGas: 0, - gasFees: _packGas(1, 1), - paymasterAndData: abi.encodePacked(address(0), fakeCalls), - signature: "" - }); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - _ownerKey, - this.hashUserOperation(userOps[0]).toEthSignedMessageHash() - ); - userOps[0].signature = abi.encodePacked(r, s, v); - - vm.expectRevert( - abi.encodeWithSelector( - IEntryPoint.FailedOpWithRevert.selector, - 0, - "AA23 reverted", - abi.encodeWithSelector(ERC7579Utils.ERC7579DecodingError.selector) - ) - ); - ENTRYPOINT.handleOps(userOps, payable(_beneficiary)); - - _collectAndPrintLogs(false); - } - - function testExecuteBatchDecodeDifferent() public { - bytes memory execCallData = abi.encodePacked( - uint256(0x20), // offset pointing to the next segment - uint256(5), // Length of execution[] - uint256(0), // offset of calls[0], and target (!!) - uint256(0x20), // offset of calls[1], and value (!!) - uint256(0), // offset of calls[2], and rel offset of data (!!) - uint256(0) // offset of calls[3]. - // There is one more to read by the array length, but it's not present here. This will be - // paymasterAndData.length during validation, pointing to an all-zero call. - // During execution, the offset will be 0, pointing to a call with value. - ); - - PackedUserOperation[] memory userOps = new PackedUserOperation[](1); - userOps[0] = PackedUserOperation({ - sender: _account, - nonce: 0, - initCode: "", - callData: abi.encodePacked( - SampleAccount.execute.selector, - ERC7579Utils.encodeMode( - ERC7579Utils.CALLTYPE_BATCH, - ERC7579Utils.EXECTYPE_DEFAULT, - ModeSelector.wrap(0x00), - ModePayload.wrap(0x00) - ), - uint256(0x5c), // offset pointing to the next segment - uint224(type(uint224).max), // Padding to align the `bytes` types - // type(uint256).max, // unknown padding - uint256(execCallData.length), // Length of the data - execCallData - ), - accountGasLimits: _packGas(500_000, 500_000), - preVerificationGas: 0, - gasFees: _packGas(1, 1), - paymasterAndData: abi.encodePacked(uint256(0), uint256(0)), // padding length to create an offset - signature: "" - }); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign( - _ownerKey, - this.hashUserOperation(userOps[0]).toEthSignedMessageHash() - ); - userOps[0].signature = abi.encodePacked(r, s, v); - - vm.expectRevert( - abi.encodeWithSelector( - IEntryPoint.FailedOpWithRevert.selector, - 0, - "AA23 reverted", - abi.encodeWithSelector(ERC7579Utils.ERC7579DecodingError.selector) - ) - ); - ENTRYPOINT.handleOps(userOps, payable(_beneficiary)); - - _collectAndPrintLogs(true); - } - - function testDecodeBatch() public { - // BAD: buffer empty - vm.expectRevert(ERC7579Utils.ERC7579DecodingError.selector); - this.callDecodeBatch(""); - - // BAD: buffer too short - vm.expectRevert(ERC7579Utils.ERC7579DecodingError.selector); - this.callDecodeBatch(abi.encodePacked(uint128(0))); - - // GOOD - this.callDecodeBatch(abi.encode(0)); - // Note: Solidity also supports this even though it's odd. Offset 0 means array is at the same location, which - // is interpreted as an array of length 0, which doesn't require any more data - // solhint-disable-next-line var-name-mixedcase - uint256[] memory _1 = abi.decode(abi.encode(0), (uint256[])); - _1; - - // BAD: offset is out of bounds - vm.expectRevert(ERC7579Utils.ERC7579DecodingError.selector); - this.callDecodeBatch(abi.encode(1)); - - // GOOD - this.callDecodeBatch(abi.encode(32, 0)); - - // BAD: reported array length extends beyond bounds - vm.expectRevert(ERC7579Utils.ERC7579DecodingError.selector); - this.callDecodeBatch(abi.encode(32, 1)); - - // GOOD - this.callDecodeBatch(abi.encode(32, 1, 0)); - - // GOOD - // - // 0000000000000000000000000000000000000000000000000000000000000020 (32) offset - // 0000000000000000000000000000000000000000000000000000000000000001 ( 1) array length - // 0000000000000000000000000000000000000000000000000000000000000020 (32) element 0 offset - // 000000000000000000000000xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx (recipient) target for element #0 - // 000000000000000000000000000000000000000000000000000000000000002a (42) value for element #0 - // 0000000000000000000000000000000000000000000000000000000000000060 (96) offset to calldata for element #0 - // 000000000000000000000000000000000000000000000000000000000000000c (12) length of the calldata for element #0 - // 48656c6c6f20576f726c64210000000000000000000000000000000000000000 (..) buffer for the calldata for element #0 - assertEq( - bytes("Hello World!"), - this.callDecodeBatchAndGetFirstBytes( - abi.encode(32, 1, 32, _recipient1, 42, 96, 12, bytes12("Hello World!")) - ) - ); - - // This is invalid, the first element of the array points is out of bounds - // but we allow it past initial validation, because solidity will validate later when the bytes field is accessed - // - // 0000000000000000000000000000000000000000000000000000000000000020 (32) offset - // 0000000000000000000000000000000000000000000000000000000000000001 ( 1) array length - // 0000000000000000000000000000000000000000000000000000000000000020 (32) element 0 offset - // - bytes memory invalid = abi.encode(32, 1, 32); - this.callDecodeBatch(invalid); - vm.expectRevert(); - this.callDecodeBatchAndGetFirst(invalid); - - // this is invalid: the bytes field of the first element of the array is out of bounds - // but we allow it past initial validation, because solidity will validate later when the bytes field is accessed - // - // 0000000000000000000000000000000000000000000000000000000000000020 (32) offset - // 0000000000000000000000000000000000000000000000000000000000000001 ( 1) array length - // 0000000000000000000000000000000000000000000000000000000000000020 (32) element 0 offset - // 000000000000000000000000xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx (recipient) target for element #0 - // 000000000000000000000000000000000000000000000000000000000000002a (42) value for element #0 - // 0000000000000000000000000000000000000000000000000000000000000060 (96) offset to calldata for element #0 - // - bytes memory invalidDeeply = abi.encode(32, 1, 32, _recipient1, 42, 96); - this.callDecodeBatch(invalidDeeply); - // Note that this is ok because we don't return the value. Returning it would introduce a check that would fails. - this.callDecodeBatchAndGetFirst(invalidDeeply); - vm.expectRevert(); - this.callDecodeBatchAndGetFirstBytes(invalidDeeply); - } - - function callDecodeBatch(bytes calldata executionCalldata) public pure { - ERC7579Utils.decodeBatch(executionCalldata); - } - - function callDecodeBatchAndGetFirst(bytes calldata executionCalldata) public pure { - ERC7579Utils.decodeBatch(executionCalldata)[0]; - } - - function callDecodeBatchAndGetFirstBytes(bytes calldata executionCalldata) public pure returns (bytes calldata) { - return ERC7579Utils.decodeBatch(executionCalldata)[0].callData; - } - - function hashUserOperation(PackedUserOperation calldata useroperation) public view returns (bytes32) { - return useroperation.hash(address(ENTRYPOINT), block.chainid); - } - - function _collectAndPrintLogs(bool includeTotalValue) internal { - Vm.Log[] memory logs = vm.getRecordedLogs(); - for (uint256 i = 0; i < logs.length; i++) { - if (logs[i].emitter == _account) { - _printDecodedCalls(logs[i].data, includeTotalValue); - } - } - } - - function _printDecodedCalls(bytes memory logData, bool includeTotalValue) internal pure { - (bool duringValidation, Execution[] memory calls) = abi.decode(logData, (bool, Execution[])); - - console.log( - string.concat( - "Batch execute contents, as read during ", - duringValidation ? "validation" : "execution", - ": " - ) - ); - console.log(" Execution[] length: %s", calls.length); - - uint256 totalValue = 0; - for (uint256 i = 0; i < calls.length; ++i) { - console.log(string.concat(" calls[", vm.toString(i), "].target = ", vm.toString(calls[i].target))); - console.log(string.concat(" calls[", vm.toString(i), "].value = ", vm.toString(calls[i].value))); - console.log(string.concat(" calls[", vm.toString(i), "].data = ", vm.toString(calls[i].callData))); - totalValue += calls[i].value; - } - - if (includeTotalValue) { - console.log(" Total value: %s", totalValue); - } - } - - function _packGas(uint256 upper, uint256 lower) internal pure returns (bytes32) { - return bytes32(uint256((upper << 128) | uint128(lower))); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/account/utils/draft-ERC7579Utils.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/account/utils/draft-ERC7579Utils.test.js deleted file mode 100644 index 7419c667b6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/account/utils/draft-ERC7579Utils.test.js +++ /dev/null @@ -1,353 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { - EXEC_TYPE_DEFAULT, - EXEC_TYPE_TRY, - encodeSingle, - encodeBatch, - encodeDelegate, - CALL_TYPE_CALL, - CALL_TYPE_BATCH, - encodeMode, -} = require('../../helpers/erc7579'); -const { selector } = require('../../helpers/methods'); - -const coder = ethers.AbiCoder.defaultAbiCoder(); - -const fixture = async () => { - const [sender] = await ethers.getSigners(); - const utils = await ethers.deployContract('$ERC7579Utils', { value: ethers.parseEther('1') }); - const utilsGlobal = await ethers.deployContract('$ERC7579UtilsGlobalMock'); - const target = await ethers.deployContract('CallReceiverMock'); - const anotherTarget = await ethers.deployContract('CallReceiverMock'); - return { utils, utilsGlobal, target, anotherTarget, sender }; -}; - -describe('ERC7579Utils', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('execSingle', function () { - it('calls the target with value', async function () { - const value = 0x012; - const data = encodeSingle(this.target, value, this.target.interface.encodeFunctionData('mockFunction')); - - await expect(this.utils.$execSingle(data, EXEC_TYPE_DEFAULT)).to.emit(this.target, 'MockFunctionCalled'); - - expect(ethers.provider.getBalance(this.target)).to.eventually.equal(value); - }); - - it('calls the target with value and args', async function () { - const value = 0x432; - const data = encodeSingle( - this.target, - value, - this.target.interface.encodeFunctionData('mockFunctionWithArgs', [42, '0x1234']), - ); - - await expect(this.utils.$execSingle(data, EXEC_TYPE_DEFAULT)) - .to.emit(this.target, 'MockFunctionCalledWithArgs') - .withArgs(42, '0x1234'); - - expect(ethers.provider.getBalance(this.target)).to.eventually.equal(value); - }); - - it('reverts when target reverts in default ExecType', async function () { - const value = 0x012; - const data = encodeSingle( - this.target, - value, - this.target.interface.encodeFunctionData('mockFunctionRevertsReason'), - ); - - await expect(this.utils.$execSingle(data, EXEC_TYPE_DEFAULT)).to.be.revertedWith('CallReceiverMock: reverting'); - }); - - it('emits ERC7579TryExecuteFail event when target reverts in try ExecType', async function () { - const value = 0x012; - const data = encodeSingle( - this.target, - value, - this.target.interface.encodeFunctionData('mockFunctionRevertsReason'), - ); - - await expect(this.utils.$execSingle(data, EXEC_TYPE_TRY)) - .to.emit(this.utils, 'ERC7579TryExecuteFail') - .withArgs( - CALL_TYPE_CALL, - ethers.solidityPacked( - ['bytes4', 'bytes'], - [selector('Error(string)'), coder.encode(['string'], ['CallReceiverMock: reverting'])], - ), - ); - }); - - it('reverts with an invalid exec type', async function () { - const value = 0x012; - const data = encodeSingle(this.target, value, this.target.interface.encodeFunctionData('mockFunction')); - - await expect(this.utils.$execSingle(data, '0x03')) - .to.be.revertedWithCustomError(this.utils, 'ERC7579UnsupportedExecType') - .withArgs('0x03'); - }); - }); - - describe('execBatch', function () { - it('calls the targets with value', async function () { - const value1 = 0x012; - const value2 = 0x234; - const data = encodeBatch( - [this.target, value1, this.target.interface.encodeFunctionData('mockFunction')], - [this.anotherTarget, value2, this.anotherTarget.interface.encodeFunctionData('mockFunction')], - ); - - await expect(this.utils.$execBatch(data, EXEC_TYPE_DEFAULT)) - .to.emit(this.target, 'MockFunctionCalled') - .to.emit(this.anotherTarget, 'MockFunctionCalled'); - - expect(ethers.provider.getBalance(this.target)).to.eventually.equal(value1); - expect(ethers.provider.getBalance(this.anotherTarget)).to.eventually.equal(value2); - }); - - it('calls the targets with value and args', async function () { - const value1 = 0x012; - const value2 = 0x234; - const data = encodeBatch( - [this.target, value1, this.target.interface.encodeFunctionData('mockFunctionWithArgs', [42, '0x1234'])], - [ - this.anotherTarget, - value2, - this.anotherTarget.interface.encodeFunctionData('mockFunctionWithArgs', [42, '0x1234']), - ], - ); - - await expect(this.utils.$execBatch(data, EXEC_TYPE_DEFAULT)) - .to.emit(this.target, 'MockFunctionCalledWithArgs') - .to.emit(this.anotherTarget, 'MockFunctionCalledWithArgs'); - - expect(ethers.provider.getBalance(this.target)).to.eventually.equal(value1); - expect(ethers.provider.getBalance(this.anotherTarget)).to.eventually.equal(value2); - }); - - it('reverts when any target reverts in default ExecType', async function () { - const value1 = 0x012; - const value2 = 0x234; - const data = encodeBatch( - [this.target, value1, this.target.interface.encodeFunctionData('mockFunction')], - [this.anotherTarget, value2, this.anotherTarget.interface.encodeFunctionData('mockFunctionRevertsReason')], - ); - - await expect(this.utils.$execBatch(data, EXEC_TYPE_DEFAULT)).to.be.revertedWith('CallReceiverMock: reverting'); - }); - - it('emits ERC7579TryExecuteFail event when any target reverts in try ExecType', async function () { - const value1 = 0x012; - const value2 = 0x234; - const data = encodeBatch( - [this.target, value1, this.target.interface.encodeFunctionData('mockFunction')], - [this.anotherTarget, value2, this.anotherTarget.interface.encodeFunctionData('mockFunctionRevertsReason')], - ); - - await expect(this.utils.$execBatch(data, EXEC_TYPE_TRY)) - .to.emit(this.utils, 'ERC7579TryExecuteFail') - .withArgs( - CALL_TYPE_BATCH, - ethers.solidityPacked( - ['bytes4', 'bytes'], - [selector('Error(string)'), coder.encode(['string'], ['CallReceiverMock: reverting'])], - ), - ); - - // Check balances - expect(ethers.provider.getBalance(this.target)).to.eventually.equal(value1); - expect(ethers.provider.getBalance(this.anotherTarget)).to.eventually.equal(0); - }); - - it('reverts with an invalid exec type', async function () { - const value1 = 0x012; - const value2 = 0x234; - const data = encodeBatch( - [this.target, value1, this.target.interface.encodeFunctionData('mockFunction')], - [this.anotherTarget, value2, this.anotherTarget.interface.encodeFunctionData('mockFunction')], - ); - - await expect(this.utils.$execBatch(data, '0x03')) - .to.be.revertedWithCustomError(this.utils, 'ERC7579UnsupportedExecType') - .withArgs('0x03'); - }); - }); - - describe('execDelegateCall', function () { - it('delegate calls the target', async function () { - const slot = ethers.hexlify(ethers.randomBytes(32)); - const value = ethers.hexlify(ethers.randomBytes(32)); - const data = encodeDelegate( - this.target, - this.target.interface.encodeFunctionData('mockFunctionWritesStorage', [slot, value]), - ); - - expect(ethers.provider.getStorage(this.utils.target, slot)).to.eventually.equal(ethers.ZeroHash); - await this.utils.$execDelegateCall(data, EXEC_TYPE_DEFAULT); - expect(ethers.provider.getStorage(this.utils.target, slot)).to.eventually.equal(value); - }); - - it('reverts when target reverts in default ExecType', async function () { - const data = encodeDelegate(this.target, this.target.interface.encodeFunctionData('mockFunctionRevertsReason')); - await expect(this.utils.$execDelegateCall(data, EXEC_TYPE_DEFAULT)).to.be.revertedWith( - 'CallReceiverMock: reverting', - ); - }); - - it('emits ERC7579TryExecuteFail event when target reverts in try ExecType', async function () { - const data = encodeDelegate(this.target, this.target.interface.encodeFunctionData('mockFunctionRevertsReason')); - await expect(this.utils.$execDelegateCall(data, EXEC_TYPE_TRY)) - .to.emit(this.utils, 'ERC7579TryExecuteFail') - .withArgs( - CALL_TYPE_CALL, - ethers.solidityPacked( - ['bytes4', 'bytes'], - [selector('Error(string)'), coder.encode(['string'], ['CallReceiverMock: reverting'])], - ), - ); - }); - - it('reverts with an invalid exec type', async function () { - const data = encodeDelegate(this.target, this.target.interface.encodeFunctionData('mockFunction')); - await expect(this.utils.$execDelegateCall(data, '0x03')) - .to.be.revertedWithCustomError(this.utils, 'ERC7579UnsupportedExecType') - .withArgs('0x03'); - }); - }); - - it('encodes Mode', async function () { - const callType = CALL_TYPE_BATCH; - const execType = EXEC_TYPE_TRY; - const selector = '0x12345678'; - const payload = ethers.toBeHex(0, 22); - - expect(this.utils.$encodeMode(callType, execType, selector, payload)).to.eventually.equal( - encodeMode({ - callType, - execType, - selector, - payload, - }), - ); - }); - - it('decodes Mode', async function () { - const callType = CALL_TYPE_BATCH; - const execType = EXEC_TYPE_TRY; - const selector = '0x12345678'; - const payload = ethers.toBeHex(0, 22); - - expect( - this.utils.$decodeMode( - encodeMode({ - callType, - execType, - selector, - payload, - }), - ), - ).to.eventually.deep.equal([callType, execType, selector, payload]); - }); - - it('encodes single', async function () { - const target = this.target; - const value = 0x123; - const data = '0x12345678'; - - expect(this.utils.$encodeSingle(target, value, data)).to.eventually.equal(encodeSingle(target, value, data)); - }); - - it('decodes single', async function () { - const target = this.target; - const value = 0x123; - const data = '0x12345678'; - - expect(this.utils.$decodeSingle(encodeSingle(target, value, data))).to.eventually.deep.equal([ - target.target, - value, - data, - ]); - }); - - it('encodes batch', async function () { - const entries = [ - [this.target, 0x123, '0x12345678'], - [this.anotherTarget, 0x456, '0x12345678'], - ]; - - expect(this.utils.$encodeBatch(entries)).to.eventually.equal(encodeBatch(...entries)); - }); - - it('decodes batch', async function () { - const entries = [ - [this.target.target, 0x123, '0x12345678'], - [this.anotherTarget.target, 0x456, '0x12345678'], - ]; - - expect(this.utils.$decodeBatch(encodeBatch(...entries))).to.eventually.deep.equal(entries); - }); - - it('encodes delegate', async function () { - const target = this.target; - const data = '0x12345678'; - - expect(this.utils.$encodeDelegate(target, data)).to.eventually.equal(encodeDelegate(target, data)); - }); - - it('decodes delegate', async function () { - const target = this.target; - const data = '0x12345678'; - - expect(this.utils.$decodeDelegate(encodeDelegate(target, data))).to.eventually.deep.equal([target.target, data]); - }); - - describe('global', function () { - describe('eqCallTypeGlobal', function () { - it('returns true if both call types are equal', async function () { - expect(this.utilsGlobal.$eqCallTypeGlobal(CALL_TYPE_BATCH, CALL_TYPE_BATCH)).to.eventually.be.true; - }); - - it('returns false if both call types are different', async function () { - expect(this.utilsGlobal.$eqCallTypeGlobal(CALL_TYPE_CALL, CALL_TYPE_BATCH)).to.eventually.be.false; - }); - }); - - describe('eqExecTypeGlobal', function () { - it('returns true if both exec types are equal', async function () { - expect(this.utilsGlobal.$eqExecTypeGlobal(EXEC_TYPE_TRY, EXEC_TYPE_TRY)).to.eventually.be.true; - }); - - it('returns false if both exec types are different', async function () { - expect(this.utilsGlobal.$eqExecTypeGlobal(EXEC_TYPE_DEFAULT, EXEC_TYPE_TRY)).to.eventually.be.false; - }); - }); - - describe('eqModeSelectorGlobal', function () { - it('returns true if both selectors are equal', async function () { - expect(this.utilsGlobal.$eqModeSelectorGlobal('0x12345678', '0x12345678')).to.eventually.be.true; - }); - - it('returns false if both selectors are different', async function () { - expect(this.utilsGlobal.$eqModeSelectorGlobal('0x12345678', '0x87654321')).to.eventually.be.false; - }); - }); - - describe('eqModePayloadGlobal', function () { - it('returns true if both payloads are equal', async function () { - expect(this.utilsGlobal.$eqModePayloadGlobal(ethers.toBeHex(0, 22), ethers.toBeHex(0, 22))).to.eventually.be - .true; - }); - - it('returns false if both payloads are different', async function () { - expect(this.utilsGlobal.$eqModePayloadGlobal(ethers.toBeHex(0, 22), ethers.toBeHex(1, 22))).to.eventually.be - .false; - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/bin/EntryPoint070.abi b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/bin/EntryPoint070.abi deleted file mode 100644 index 3f3b1d6e5f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/bin/EntryPoint070.abi +++ /dev/null @@ -1 +0,0 @@ -[{"inputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"bytes","name":"ret","type":"bytes"}],"name":"DelegateAndRevert","type":"error"},{"inputs":[{"internalType":"uint256","name":"opIndex","type":"uint256"},{"internalType":"string","name":"reason","type":"string"}],"name":"FailedOp","type":"error"},{"inputs":[{"internalType":"uint256","name":"opIndex","type":"uint256"},{"internalType":"string","name":"reason","type":"string"},{"internalType":"bytes","name":"inner","type":"bytes"}],"name":"FailedOpWithRevert","type":"error"},{"inputs":[{"internalType":"bytes","name":"returnData","type":"bytes"}],"name":"PostOpReverted","type":"error"},{"inputs":[],"name":"ReentrancyGuardReentrantCall","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"}],"name":"SenderAddressResult","type":"error"},{"inputs":[{"internalType":"address","name":"aggregator","type":"address"}],"name":"SignatureValidationFailed","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"userOpHash","type":"bytes32"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address","name":"factory","type":"address"},{"indexed":false,"internalType":"address","name":"paymaster","type":"address"}],"name":"AccountDeployed","type":"event"},{"anonymous":false,"inputs":[],"name":"BeforeExecution","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"totalDeposit","type":"uint256"}],"name":"Deposited","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"userOpHash","type":"bytes32"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"nonce","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"revertReason","type":"bytes"}],"name":"PostOpRevertReason","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"aggregator","type":"address"}],"name":"SignatureAggregatorChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"totalStaked","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"unstakeDelaySec","type":"uint256"}],"name":"StakeLocked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"withdrawTime","type":"uint256"}],"name":"StakeUnlocked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawAddress","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"StakeWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"userOpHash","type":"bytes32"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"paymaster","type":"address"},{"indexed":false,"internalType":"uint256","name":"nonce","type":"uint256"},{"indexed":false,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint256","name":"actualGasCost","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"actualGasUsed","type":"uint256"}],"name":"UserOperationEvent","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"userOpHash","type":"bytes32"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"nonce","type":"uint256"}],"name":"UserOperationPrefundTooLow","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"userOpHash","type":"bytes32"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"nonce","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"revertReason","type":"bytes"}],"name":"UserOperationRevertReason","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawAddress","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdrawn","type":"event"},{"inputs":[{"internalType":"uint32","name":"unstakeDelaySec","type":"uint32"}],"name":"addStake","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"delegateAndRevert","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"depositTo","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"deposits","outputs":[{"internalType":"uint256","name":"deposit","type":"uint256"},{"internalType":"bool","name":"staked","type":"bool"},{"internalType":"uint112","name":"stake","type":"uint112"},{"internalType":"uint32","name":"unstakeDelaySec","type":"uint32"},{"internalType":"uint48","name":"withdrawTime","type":"uint48"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getDepositInfo","outputs":[{"components":[{"internalType":"uint256","name":"deposit","type":"uint256"},{"internalType":"bool","name":"staked","type":"bool"},{"internalType":"uint112","name":"stake","type":"uint112"},{"internalType":"uint32","name":"unstakeDelaySec","type":"uint32"},{"internalType":"uint48","name":"withdrawTime","type":"uint48"}],"internalType":"struct IStakeManager.DepositInfo","name":"info","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint192","name":"key","type":"uint192"}],"name":"getNonce","outputs":[{"internalType":"uint256","name":"nonce","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes","name":"initCode","type":"bytes"}],"name":"getSenderAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"nonce","type":"uint256"},{"internalType":"bytes","name":"initCode","type":"bytes"},{"internalType":"bytes","name":"callData","type":"bytes"},{"internalType":"bytes32","name":"accountGasLimits","type":"bytes32"},{"internalType":"uint256","name":"preVerificationGas","type":"uint256"},{"internalType":"bytes32","name":"gasFees","type":"bytes32"},{"internalType":"bytes","name":"paymasterAndData","type":"bytes"},{"internalType":"bytes","name":"signature","type":"bytes"}],"internalType":"struct PackedUserOperation","name":"userOp","type":"tuple"}],"name":"getUserOpHash","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"components":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"nonce","type":"uint256"},{"internalType":"bytes","name":"initCode","type":"bytes"},{"internalType":"bytes","name":"callData","type":"bytes"},{"internalType":"bytes32","name":"accountGasLimits","type":"bytes32"},{"internalType":"uint256","name":"preVerificationGas","type":"uint256"},{"internalType":"bytes32","name":"gasFees","type":"bytes32"},{"internalType":"bytes","name":"paymasterAndData","type":"bytes"},{"internalType":"bytes","name":"signature","type":"bytes"}],"internalType":"struct PackedUserOperation[]","name":"userOps","type":"tuple[]"},{"internalType":"contract IAggregator","name":"aggregator","type":"address"},{"internalType":"bytes","name":"signature","type":"bytes"}],"internalType":"struct IEntryPoint.UserOpsPerAggregator[]","name":"opsPerAggregator","type":"tuple[]"},{"internalType":"address payable","name":"beneficiary","type":"address"}],"name":"handleAggregatedOps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"nonce","type":"uint256"},{"internalType":"bytes","name":"initCode","type":"bytes"},{"internalType":"bytes","name":"callData","type":"bytes"},{"internalType":"bytes32","name":"accountGasLimits","type":"bytes32"},{"internalType":"uint256","name":"preVerificationGas","type":"uint256"},{"internalType":"bytes32","name":"gasFees","type":"bytes32"},{"internalType":"bytes","name":"paymasterAndData","type":"bytes"},{"internalType":"bytes","name":"signature","type":"bytes"}],"internalType":"struct PackedUserOperation[]","name":"ops","type":"tuple[]"},{"internalType":"address payable","name":"beneficiary","type":"address"}],"name":"handleOps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint192","name":"key","type":"uint192"}],"name":"incrementNonce","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"callData","type":"bytes"},{"components":[{"components":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"nonce","type":"uint256"},{"internalType":"uint256","name":"verificationGasLimit","type":"uint256"},{"internalType":"uint256","name":"callGasLimit","type":"uint256"},{"internalType":"uint256","name":"paymasterVerificationGasLimit","type":"uint256"},{"internalType":"uint256","name":"paymasterPostOpGasLimit","type":"uint256"},{"internalType":"uint256","name":"preVerificationGas","type":"uint256"},{"internalType":"address","name":"paymaster","type":"address"},{"internalType":"uint256","name":"maxFeePerGas","type":"uint256"},{"internalType":"uint256","name":"maxPriorityFeePerGas","type":"uint256"}],"internalType":"struct EntryPoint.MemoryUserOp","name":"mUserOp","type":"tuple"},{"internalType":"bytes32","name":"userOpHash","type":"bytes32"},{"internalType":"uint256","name":"prefund","type":"uint256"},{"internalType":"uint256","name":"contextOffset","type":"uint256"},{"internalType":"uint256","name":"preOpGas","type":"uint256"}],"internalType":"struct EntryPoint.UserOpInfo","name":"opInfo","type":"tuple"},{"internalType":"bytes","name":"context","type":"bytes"}],"name":"innerHandleOp","outputs":[{"internalType":"uint256","name":"actualGasCost","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint192","name":"","type":"uint192"}],"name":"nonceSequenceNumber","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"unlockStake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable","name":"withdrawAddress","type":"address"}],"name":"withdrawStake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable","name":"withdrawAddress","type":"address"},{"internalType":"uint256","name":"withdrawAmount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}] \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/bin/EntryPoint070.bytecode b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/bin/EntryPoint070.bytecode deleted file mode 100644 index fce261af5d..0000000000 Binary files a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/bin/EntryPoint070.bytecode and /dev/null differ diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/bin/SenderCreator070.abi b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/bin/SenderCreator070.abi deleted file mode 100644 index 0a1f0e4fba..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/bin/SenderCreator070.abi +++ /dev/null @@ -1 +0,0 @@ -[{"inputs":[{"internalType":"bytes","name":"initCode","type":"bytes"}],"name":"createSender","outputs":[{"internalType":"address","name":"sender","type":"address"}],"stateMutability":"nonpayable","type":"function"}] \ No newline at end of file diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/bin/SenderCreator070.bytecode b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/bin/SenderCreator070.bytecode deleted file mode 100644 index 8344c20281..0000000000 Binary files a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/bin/SenderCreator070.bytecode and /dev/null differ diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/finance/VestingWallet.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/finance/VestingWallet.behavior.js deleted file mode 100644 index b45ffeecfd..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/finance/VestingWallet.behavior.js +++ /dev/null @@ -1,87 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const time = require('../helpers/time'); - -async function envSetup(mock, beneficiary, token) { - return { - eth: { - checkRelease: async (tx, amount) => { - await expect(tx).to.changeEtherBalances([mock, beneficiary], [-amount, amount]); - }, - setupFailure: async () => { - const beneficiaryMock = await ethers.deployContract('EtherReceiverMock'); - await beneficiaryMock.setAcceptEther(false); - await mock.connect(beneficiary).transferOwnership(beneficiaryMock); - return { args: [], error: [mock, 'FailedCall'] }; - }, - releasedEvent: 'EtherReleased', - args: [], - }, - token: { - checkRelease: async (tx, amount) => { - await expect(tx).to.emit(token, 'Transfer').withArgs(mock, beneficiary, amount); - await expect(tx).to.changeTokenBalances(token, [mock, beneficiary], [-amount, amount]); - }, - setupFailure: async () => { - const pausableToken = await ethers.deployContract('$ERC20Pausable', ['Name', 'Symbol']); - await pausableToken.$_pause(); - return { - args: [ethers.Typed.address(pausableToken)], - error: [pausableToken, 'EnforcedPause'], - }; - }, - releasedEvent: 'ERC20Released', - args: [ethers.Typed.address(token)], - }, - }; -} - -function shouldBehaveLikeVesting() { - it('check vesting schedule', async function () { - for (const timestamp of this.schedule) { - await time.increaseTo.timestamp(timestamp); - const vesting = this.vestingFn(timestamp); - - expect(await this.mock.vestedAmount(...this.args, timestamp)).to.equal(vesting); - expect(await this.mock.releasable(...this.args)).to.equal(vesting); - } - }); - - it('execute vesting schedule', async function () { - let released = 0n; - { - const tx = await this.mock.release(...this.args); - await expect(tx) - .to.emit(this.mock, this.releasedEvent) - .withArgs(...this.args, 0); - - await this.checkRelease(tx, 0n); - } - - for (const timestamp of this.schedule) { - await time.increaseTo.timestamp(timestamp, false); - const vested = this.vestingFn(timestamp); - - const tx = await this.mock.release(...this.args); - await expect(tx).to.emit(this.mock, this.releasedEvent); - - await this.checkRelease(tx, vested - released); - released = vested; - } - }); - - it('should revert on transaction failure', async function () { - const { args, error } = await this.setupFailure(); - - for (const timestamp of this.schedule) { - await time.increaseTo.timestamp(timestamp); - - await expect(this.mock.release(...args)).to.be.revertedWithCustomError(...error); - } - }); -} - -module.exports = { - envSetup, - shouldBehaveLikeVesting, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/finance/VestingWallet.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/finance/VestingWallet.test.js deleted file mode 100644 index b89258d65b..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/finance/VestingWallet.test.js +++ /dev/null @@ -1,65 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { min } = require('../helpers/math'); -const time = require('../helpers/time'); - -const { envSetup, shouldBehaveLikeVesting } = require('./VestingWallet.behavior'); - -async function fixture() { - const amount = ethers.parseEther('100'); - const duration = time.duration.years(4); - const start = (await time.clock.timestamp()) + time.duration.hours(1); - - const [sender, beneficiary] = await ethers.getSigners(); - const mock = await ethers.deployContract('VestingWallet', [beneficiary, start, duration]); - - const token = await ethers.deployContract('$ERC20', ['Name', 'Symbol']); - await token.$_mint(mock, amount); - await sender.sendTransaction({ to: mock, value: amount }); - - const env = await envSetup(mock, beneficiary, token); - - const schedule = Array.from({ length: 64 }, (_, i) => (BigInt(i) * duration) / 60n + start); - const vestingFn = timestamp => min(amount, (amount * (timestamp - start)) / duration); - - return { mock, duration, start, beneficiary, schedule, vestingFn, env }; -} - -describe('VestingWallet', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('rejects zero address for beneficiary', async function () { - await expect(ethers.deployContract('VestingWallet', [ethers.ZeroAddress, this.start, this.duration])) - .revertedWithCustomError(this.mock, 'OwnableInvalidOwner') - .withArgs(ethers.ZeroAddress); - }); - - it('check vesting contract', async function () { - expect(await this.mock.owner()).to.equal(this.beneficiary); - expect(await this.mock.start()).to.equal(this.start); - expect(await this.mock.duration()).to.equal(this.duration); - expect(await this.mock.end()).to.equal(this.start + this.duration); - }); - - describe('vesting schedule', function () { - describe('Eth vesting', function () { - beforeEach(async function () { - Object.assign(this, this.env.eth); - }); - - shouldBehaveLikeVesting(); - }); - - describe('ERC20 vesting', function () { - beforeEach(async function () { - Object.assign(this, this.env.token); - }); - - shouldBehaveLikeVesting(); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/finance/VestingWalletCliff.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/finance/VestingWalletCliff.test.js deleted file mode 100644 index 799b24c4b2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/finance/VestingWalletCliff.test.js +++ /dev/null @@ -1,70 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { min } = require('../helpers/math'); -const time = require('../helpers/time'); - -const { envSetup, shouldBehaveLikeVesting } = require('./VestingWallet.behavior'); - -async function fixture() { - const amount = ethers.parseEther('100'); - const duration = time.duration.years(4); - const start = (await time.clock.timestamp()) + time.duration.hours(1); - const cliffDuration = time.duration.years(1); - const cliff = start + cliffDuration; - - const [sender, beneficiary] = await ethers.getSigners(); - const mock = await ethers.deployContract('$VestingWalletCliff', [beneficiary, start, duration, cliffDuration]); - - const token = await ethers.deployContract('$ERC20', ['Name', 'Symbol']); - await token.$_mint(mock, amount); - await sender.sendTransaction({ to: mock, value: amount }); - - const env = await envSetup(mock, beneficiary, token); - - const schedule = Array.from({ length: 64 }, (_, i) => (BigInt(i) * duration) / 60n + start); - const vestingFn = timestamp => min(amount, timestamp < cliff ? 0n : (amount * (timestamp - start)) / duration); - - return { mock, duration, start, beneficiary, cliff, schedule, vestingFn, env }; -} - -describe('VestingWalletCliff', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('rejects a larger cliff than vesting duration', async function () { - await expect( - ethers.deployContract('$VestingWalletCliff', [this.beneficiary, this.start, this.duration, this.duration + 1n]), - ) - .revertedWithCustomError(this.mock, 'InvalidCliffDuration') - .withArgs(this.duration + 1n, this.duration); - }); - - it('check vesting contract', async function () { - expect(await this.mock.owner()).to.equal(this.beneficiary); - expect(await this.mock.start()).to.equal(this.start); - expect(await this.mock.duration()).to.equal(this.duration); - expect(await this.mock.end()).to.equal(this.start + this.duration); - expect(await this.mock.cliff()).to.equal(this.cliff); - }); - - describe('vesting schedule', function () { - describe('Eth vesting', function () { - beforeEach(async function () { - Object.assign(this, this.env.eth); - }); - - shouldBehaveLikeVesting(); - }); - - describe('ERC20 vesting', function () { - beforeEach(async function () { - Object.assign(this, this.env.token); - }); - - shouldBehaveLikeVesting(); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/Governor.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/Governor.t.sol deleted file mode 100644 index 958461abb9..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/Governor.t.sol +++ /dev/null @@ -1,55 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {Strings} from "@openzeppelin/contracts/utils/Strings.sol"; -import {Governor} from "@openzeppelin/contracts/governance/Governor.sol"; - -contract GovernorInternalTest is Test, Governor { - constructor() Governor("") {} - - function testValidDescriptionForProposer(string memory description, address proposer, bool includeProposer) public { - if (includeProposer) { - description = string.concat(description, "#proposer=", Strings.toHexString(proposer)); - } - assertTrue(_isValidDescriptionForProposer(proposer, description)); - } - - function testInvalidDescriptionForProposer( - string memory description, - address commitProposer, - address actualProposer - ) public { - vm.assume(commitProposer != actualProposer); - description = string.concat(description, "#proposer=", Strings.toHexString(commitProposer)); - assertFalse(_isValidDescriptionForProposer(actualProposer, description)); - } - - // We don't need to truly implement the missing functions because we are just testing - // internal helpers. - - function clock() public pure override returns (uint48) {} - - // solhint-disable-next-line func-name-mixedcase - function CLOCK_MODE() public pure override returns (string memory) {} - - // solhint-disable-next-line func-name-mixedcase - function COUNTING_MODE() public pure virtual override returns (string memory) {} - - function votingDelay() public pure virtual override returns (uint256) {} - - function votingPeriod() public pure virtual override returns (uint256) {} - - function quorum(uint256) public pure virtual override returns (uint256) {} - - function hasVoted(uint256, address) public pure virtual override returns (bool) {} - - function _quorumReached(uint256) internal pure virtual override returns (bool) {} - - function _voteSucceeded(uint256) internal pure virtual override returns (bool) {} - - function _getVotes(address, uint256, bytes memory) internal pure virtual override returns (uint256) {} - - function _countVote(uint256, address, uint8, uint256, bytes memory) internal virtual override returns (uint256) {} -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/Governor.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/Governor.test.js deleted file mode 100644 index 3e48ccfee7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/Governor.test.js +++ /dev/null @@ -1,992 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { GovernorHelper } = require('../helpers/governance'); -const { getDomain, Ballot } = require('../helpers/eip712'); -const { ProposalState, VoteType } = require('../helpers/enums'); -const time = require('../helpers/time'); - -const { shouldSupportInterfaces } = require('../utils/introspection/SupportsInterface.behavior'); -const { shouldBehaveLikeERC6372 } = require('./utils/ERC6372.behavior'); - -const TOKENS = [ - { Token: '$ERC20Votes', mode: 'blocknumber' }, - { Token: '$ERC20VotesTimestampMock', mode: 'timestamp' }, - { Token: '$ERC20VotesLegacyMock', mode: 'blocknumber' }, -]; - -const name = 'OZ-Governor'; -const version = '1'; -const tokenName = 'MockToken'; -const tokenSymbol = 'MTKN'; -const tokenSupply = ethers.parseEther('100'); -const votingDelay = 4n; -const votingPeriod = 16n; -const value = ethers.parseEther('1'); - -const signBallot = account => (contract, message) => - getDomain(contract).then(domain => account.signTypedData(domain, { Ballot }, message)); - -async function deployToken(contractName) { - try { - return await ethers.deployContract(contractName, [tokenName, tokenSymbol, tokenName, version]); - } catch (error) { - if (error.message == 'incorrect number of arguments to constructor') { - // ERC20VotesLegacyMock has a different construction that uses version='1' by default. - return ethers.deployContract(contractName, [tokenName, tokenSymbol, tokenName]); - } - throw error; - } -} - -describe('Governor', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - const [owner, proposer, voter1, voter2, voter3, voter4, userEOA] = await ethers.getSigners(); - const receiver = await ethers.deployContract('CallReceiverMock'); - - const token = await deployToken(Token, [tokenName, tokenSymbol, version]); - const mock = await ethers.deployContract('$GovernorMock', [ - name, // name - votingDelay, // initialVotingDelay - votingPeriod, // initialVotingPeriod - 0n, // initialProposalThreshold - token, // tokenAddress - 10n, // quorumNumeratorValue - ]); - - await owner.sendTransaction({ to: mock, value }); - await token.$_mint(owner, tokenSupply); - - const helper = new GovernorHelper(mock, mode); - await helper.connect(owner).delegate({ token: token, to: voter1, value: ethers.parseEther('10') }); - await helper.connect(owner).delegate({ token: token, to: voter2, value: ethers.parseEther('7') }); - await helper.connect(owner).delegate({ token: token, to: voter3, value: ethers.parseEther('5') }); - await helper.connect(owner).delegate({ token: token, to: voter4, value: ethers.parseEther('2') }); - - return { - owner, - proposer, - voter1, - voter2, - voter3, - voter4, - userEOA, - receiver, - token, - mock, - helper, - }; - }; - - describe(`using ${Token}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - // initiate fresh proposal - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - value, - }, - ], - '', - ); - }); - - shouldSupportInterfaces(['ERC1155Receiver', 'Governor']); - shouldBehaveLikeERC6372(mode); - - it('deployment check', async function () { - expect(await this.mock.name()).to.equal(name); - expect(await this.mock.token()).to.equal(this.token); - expect(await this.mock.votingDelay()).to.equal(votingDelay); - expect(await this.mock.votingPeriod()).to.equal(votingPeriod); - expect(await this.mock.quorum(0)).to.equal(0n); - expect(await this.mock.COUNTING_MODE()).to.equal('support=bravo&quorum=for,abstain'); - }); - - it('nominal workflow', async function () { - // Before - expect(await this.mock.proposalProposer(this.proposal.id)).to.equal(ethers.ZeroAddress); - expect(await this.mock.hasVoted(this.proposal.id, this.owner)).to.be.false; - expect(await this.mock.hasVoted(this.proposal.id, this.voter1)).to.be.false; - expect(await this.mock.hasVoted(this.proposal.id, this.voter2)).to.be.false; - expect(await ethers.provider.getBalance(this.mock)).to.equal(value); - expect(await ethers.provider.getBalance(this.receiver)).to.equal(0n); - - expect(await this.mock.proposalEta(this.proposal.id)).to.equal(0n); - expect(await this.mock.proposalNeedsQueuing(this.proposal.id)).to.be.false; - - // Run proposal - const txPropose = await this.helper.connect(this.proposer).propose(); - const timepoint = await time.clockFromReceipt[mode](txPropose); - - await expect(txPropose) - .to.emit(this.mock, 'ProposalCreated') - .withArgs( - this.proposal.id, - this.proposer, - this.proposal.targets, - this.proposal.values, - this.proposal.signatures, - this.proposal.data, - timepoint + votingDelay, - timepoint + votingDelay + votingPeriod, - this.proposal.description, - ); - - await this.helper.waitForSnapshot(); - - await expect(this.helper.connect(this.voter1).vote({ support: VoteType.For, reason: 'This is nice' })) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter1, this.proposal.id, VoteType.For, ethers.parseEther('10'), 'This is nice'); - - await expect(this.helper.connect(this.voter2).vote({ support: VoteType.For })) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter2, this.proposal.id, VoteType.For, ethers.parseEther('7'), ''); - - await expect(this.helper.connect(this.voter3).vote({ support: VoteType.Against })) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter3, this.proposal.id, VoteType.Against, ethers.parseEther('5'), ''); - - await expect(this.helper.connect(this.voter4).vote({ support: VoteType.Abstain })) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter4, this.proposal.id, VoteType.Abstain, ethers.parseEther('2'), ''); - - await this.helper.waitForDeadline(); - - const txExecute = await this.helper.execute(); - - await expect(txExecute).to.emit(this.mock, 'ProposalExecuted').withArgs(this.proposal.id); - - await expect(txExecute).to.emit(this.receiver, 'MockFunctionCalled'); - - // After - expect(await this.mock.proposalProposer(this.proposal.id)).to.equal(this.proposer); - expect(await this.mock.hasVoted(this.proposal.id, this.owner)).to.be.false; - expect(await this.mock.hasVoted(this.proposal.id, this.voter1)).to.be.true; - expect(await this.mock.hasVoted(this.proposal.id, this.voter2)).to.be.true; - expect(await ethers.provider.getBalance(this.mock)).to.equal(0n); - expect(await ethers.provider.getBalance(this.receiver)).to.equal(value); - - expect(await this.mock.proposalEta(this.proposal.id)).to.equal(0n); - expect(await this.mock.proposalNeedsQueuing(this.proposal.id)).to.be.false; - }); - - it('send ethers', async function () { - this.helper.setProposal( - [ - { - target: this.userEOA.address, - value, - }, - ], - '', - ); - - // Run proposal - await expect(async () => { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - return this.helper.execute(); - }).to.changeEtherBalances([this.mock, this.userEOA], [-value, value]); - }); - - describe('vote with signature', function () { - it('votes with an EOA signature', async function () { - await this.token.connect(this.voter1).delegate(this.userEOA); - - const nonce = await this.mock.nonces(this.userEOA); - - // Run proposal - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await expect( - this.helper.vote({ - support: VoteType.For, - voter: this.userEOA.address, - nonce, - signature: signBallot(this.userEOA), - }), - ) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.userEOA, this.proposal.id, VoteType.For, ethers.parseEther('10'), ''); - - await this.helper.waitForDeadline(); - await this.helper.execute(); - - // After - expect(await this.mock.hasVoted(this.proposal.id, this.userEOA)).to.be.true; - expect(await this.mock.nonces(this.userEOA)).to.equal(nonce + 1n); - }); - - it('votes with a valid EIP-1271 signature', async function () { - const wallet = await ethers.deployContract('ERC1271WalletMock', [this.userEOA]); - - await this.token.connect(this.voter1).delegate(wallet); - - const nonce = await this.mock.nonces(this.userEOA); - - // Run proposal - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await expect( - this.helper.vote({ - support: VoteType.For, - voter: wallet.target, - nonce, - signature: signBallot(this.userEOA), - }), - ) - .to.emit(this.mock, 'VoteCast') - .withArgs(wallet, this.proposal.id, VoteType.For, ethers.parseEther('10'), ''); - await this.helper.waitForDeadline(); - await this.helper.execute(); - - // After - expect(await this.mock.hasVoted(this.proposal.id, wallet)).to.be.true; - expect(await this.mock.nonces(wallet)).to.equal(nonce + 1n); - }); - - afterEach('no other votes are cast', async function () { - expect(await this.mock.hasVoted(this.proposal.id, this.owner)).to.be.false; - expect(await this.mock.hasVoted(this.proposal.id, this.voter1)).to.be.false; - expect(await this.mock.hasVoted(this.proposal.id, this.voter2)).to.be.false; - }); - }); - - describe('should revert', function () { - describe('on propose', function () { - it('if proposal already exists', async function () { - await this.helper.propose(); - await expect(this.helper.propose()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs(this.proposal.id, ProposalState.Pending, ethers.ZeroHash); - }); - - it('if proposer has below threshold votes', async function () { - const votes = ethers.parseEther('10'); - const threshold = ethers.parseEther('1000'); - await this.mock.$_setProposalThreshold(threshold); - await expect(this.helper.connect(this.voter1).propose()) - .to.be.revertedWithCustomError(this.mock, 'GovernorInsufficientProposerVotes') - .withArgs(this.voter1, votes, threshold); - }); - }); - - describe('on vote', function () { - it('if proposal does not exist', async function () { - await expect(this.helper.connect(this.voter1).vote({ support: VoteType.For })) - .to.be.revertedWithCustomError(this.mock, 'GovernorNonexistentProposal') - .withArgs(this.proposal.id); - }); - - it('if voting has not started', async function () { - await this.helper.propose(); - await expect(this.helper.connect(this.voter1).vote({ support: VoteType.For })) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Pending, - GovernorHelper.proposalStatesToBitMap([ProposalState.Active]), - ); - }); - - it('if support value is invalid', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await expect(this.helper.vote({ support: 255 })).to.be.revertedWithCustomError( - this.mock, - 'GovernorInvalidVoteType', - ); - }); - - it('if vote was already casted', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await expect(this.helper.connect(this.voter1).vote({ support: VoteType.For })) - .to.be.revertedWithCustomError(this.mock, 'GovernorAlreadyCastVote') - .withArgs(this.voter1); - }); - - it('if voting is over', async function () { - await this.helper.propose(); - await this.helper.waitForDeadline(); - await expect(this.helper.connect(this.voter1).vote({ support: VoteType.For })) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Defeated, - GovernorHelper.proposalStatesToBitMap([ProposalState.Active]), - ); - }); - }); - - describe('on vote by signature', function () { - beforeEach(async function () { - await this.token.connect(this.voter1).delegate(this.userEOA); - - // Run proposal - await this.helper.propose(); - await this.helper.waitForSnapshot(); - }); - - it('if signature does not match signer', async function () { - const nonce = await this.mock.nonces(this.userEOA); - - function tamper(str, index, mask) { - const arrayStr = ethers.getBytes(str); - arrayStr[index] ^= mask; - return ethers.hexlify(arrayStr); - } - - const voteParams = { - support: VoteType.For, - voter: this.userEOA.address, - nonce, - signature: (...args) => signBallot(this.userEOA)(...args).then(sig => tamper(sig, 42, 0xff)), - }; - - await expect(this.helper.vote(voteParams)) - .to.be.revertedWithCustomError(this.mock, 'GovernorInvalidSignature') - .withArgs(voteParams.voter); - }); - - it('if vote nonce is incorrect', async function () { - const nonce = await this.mock.nonces(this.userEOA); - - const voteParams = { - support: VoteType.For, - voter: this.userEOA.address, - nonce: nonce + 1n, - signature: signBallot(this.userEOA), - }; - - await expect(this.helper.vote(voteParams)) - .to.be.revertedWithCustomError(this.mock, 'GovernorInvalidSignature') - .withArgs(voteParams.voter); - }); - }); - - describe('on queue', function () { - it('always', async function () { - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await expect(this.helper.queue()).to.be.revertedWithCustomError(this.mock, 'GovernorQueueNotImplemented'); - }); - }); - - describe('on execute', function () { - it('if proposal does not exist', async function () { - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorNonexistentProposal') - .withArgs(this.proposal.id); - }); - - it('if quorum is not reached', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter3).vote({ support: VoteType.For }); - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Active, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - it('if score not reached', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.Against }); - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Active, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - it('if voting is not over', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Active, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - it('if receiver revert without reason', async function () { - this.helper.setProposal( - [ - { - target: this.receiver.target, - data: this.receiver.interface.encodeFunctionData('mockFunctionRevertsNoReason'), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await expect(this.helper.execute()).to.be.revertedWithCustomError(this.mock, 'FailedCall'); - }); - - it('if receiver revert with reason', async function () { - this.helper.setProposal( - [ - { - target: this.receiver.target, - data: this.receiver.interface.encodeFunctionData('mockFunctionRevertsReason'), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await expect(this.helper.execute()).to.be.revertedWith('CallReceiverMock: reverting'); - }); - - it('if proposal was already executed', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.execute(); - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Executed, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - }); - }); - - describe('state', function () { - it('Unset', async function () { - await expect(this.mock.state(this.proposal.id)) - .to.be.revertedWithCustomError(this.mock, 'GovernorNonexistentProposal') - .withArgs(this.proposal.id); - }); - - it('Pending & Active', async function () { - await this.helper.propose(); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Pending); - await this.helper.waitForSnapshot(); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Pending); - await this.helper.waitForSnapshot(1n); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Active); - }); - - it('Defeated', async function () { - await this.helper.propose(); - await this.helper.waitForDeadline(); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Active); - await this.helper.waitForDeadline(1n); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Defeated); - }); - - it('Succeeded', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Active); - await this.helper.waitForDeadline(1n); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Succeeded); - }); - - it('Executed', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.execute(); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Executed); - }); - }); - - describe('cancel', function () { - describe('internal', function () { - it('before proposal', async function () { - await expect(this.helper.cancel('internal')) - .to.be.revertedWithCustomError(this.mock, 'GovernorNonexistentProposal') - .withArgs(this.proposal.id); - }); - - it('after proposal', async function () { - await this.helper.propose(); - - await this.helper.cancel('internal'); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Canceled); - - await this.helper.waitForSnapshot(); - await expect(this.helper.connect(this.voter1).vote({ support: VoteType.For })) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Canceled, - GovernorHelper.proposalStatesToBitMap([ProposalState.Active]), - ); - }); - - it('after vote', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - - await this.helper.cancel('internal'); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Canceled); - - await this.helper.waitForDeadline(); - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Canceled, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - it('after deadline', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await this.helper.cancel('internal'); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Canceled); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Canceled, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - it('after execution', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.execute(); - - await expect(this.helper.cancel('internal')) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Executed, - GovernorHelper.proposalStatesToBitMap( - [ProposalState.Canceled, ProposalState.Expired, ProposalState.Executed], - { inverted: true }, - ), - ); - }); - }); - - describe('public', function () { - it('before proposal', async function () { - await expect(this.helper.cancel('external')) - .to.be.revertedWithCustomError(this.mock, 'GovernorNonexistentProposal') - .withArgs(this.proposal.id); - }); - - it('after proposal', async function () { - await this.helper.propose(); - - await this.helper.cancel('external'); - }); - - it('after proposal - restricted to proposer', async function () { - await this.helper.connect(this.proposer).propose(); - - await expect(this.helper.connect(this.owner).cancel('external')) - .to.be.revertedWithCustomError(this.mock, 'GovernorOnlyProposer') - .withArgs(this.owner); - }); - - it('after vote started', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(1n); // snapshot + 1 block - - await expect(this.helper.cancel('external')) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Active, - GovernorHelper.proposalStatesToBitMap([ProposalState.Pending]), - ); - }); - - it('after vote', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - - await expect(this.helper.cancel('external')) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Active, - GovernorHelper.proposalStatesToBitMap([ProposalState.Pending]), - ); - }); - - it('after deadline', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.cancel('external')) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Succeeded, - GovernorHelper.proposalStatesToBitMap([ProposalState.Pending]), - ); - }); - - it('after execution', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.execute(); - - await expect(this.helper.cancel('external')) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Executed, - GovernorHelper.proposalStatesToBitMap([ProposalState.Pending]), - ); - }); - }); - }); - - describe('proposal length', function () { - it('empty', async function () { - this.helper.setProposal([], ''); - - await expect(this.helper.propose()) - .to.be.revertedWithCustomError(this.mock, 'GovernorInvalidProposalLength') - .withArgs(0, 0, 0); - }); - - it('mismatch #1', async function () { - this.helper.setProposal( - { - targets: [], - values: [0n], - data: [this.receiver.interface.encodeFunctionData('mockFunction')], - }, - '', - ); - await expect(this.helper.propose()) - .to.be.revertedWithCustomError(this.mock, 'GovernorInvalidProposalLength') - .withArgs(0, 1, 1); - }); - - it('mismatch #2', async function () { - this.helper.setProposal( - { - targets: [this.receiver.target], - values: [], - data: [this.receiver.interface.encodeFunctionData('mockFunction')], - }, - '', - ); - await expect(this.helper.propose()) - .to.be.revertedWithCustomError(this.mock, 'GovernorInvalidProposalLength') - .withArgs(1, 1, 0); - }); - - it('mismatch #3', async function () { - this.helper.setProposal( - { - targets: [this.receiver.target], - values: [0n], - data: [], - }, - '', - ); - await expect(this.helper.propose()) - .to.be.revertedWithCustomError(this.mock, 'GovernorInvalidProposalLength') - .withArgs(1, 0, 1); - }); - }); - - describe('frontrun protection using description suffix', function () { - function shouldPropose() { - it('proposer can propose', async function () { - const txPropose = await this.helper.connect(this.proposer).propose(); - - await expect(txPropose) - .to.emit(this.mock, 'ProposalCreated') - .withArgs( - this.proposal.id, - this.proposer, - this.proposal.targets, - this.proposal.values, - this.proposal.signatures, - this.proposal.data, - (await time.clockFromReceipt[mode](txPropose)) + votingDelay, - (await time.clockFromReceipt[mode](txPropose)) + votingDelay + votingPeriod, - this.proposal.description, - ); - }); - - it('someone else can propose', async function () { - const txPropose = await this.helper.connect(this.voter1).propose(); - - await expect(txPropose) - .to.emit(this.mock, 'ProposalCreated') - .withArgs( - this.proposal.id, - this.voter1, - this.proposal.targets, - this.proposal.values, - this.proposal.signatures, - this.proposal.data, - (await time.clockFromReceipt[mode](txPropose)) + votingDelay, - (await time.clockFromReceipt[mode](txPropose)) + votingDelay + votingPeriod, - this.proposal.description, - ); - }); - } - - describe('without protection', function () { - describe('without suffix', function () { - shouldPropose(); - }); - - describe('with different suffix', function () { - beforeEach(function () { - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - value, - }, - ], - `#wrong-suffix=${this.proposer}`, - ); - }); - - shouldPropose(); - }); - - describe('with proposer suffix but bad address part', function () { - beforeEach(function () { - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - value, - }, - ], - `#proposer=0x3C44CdDdB6a900fa2b585dd299e03d12FA429XYZ`, // XYZ are not a valid hex char - ); - }); - - shouldPropose(); - }); - }); - - describe('with protection via proposer suffix', function () { - beforeEach(function () { - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - value, - }, - ], - `#proposer=${this.proposer}`, - ); - }); - - shouldPropose(); - }); - }); - - describe('onlyGovernance updates', function () { - it('setVotingDelay is protected', async function () { - await expect(this.mock.connect(this.owner).setVotingDelay(0n)) - .to.be.revertedWithCustomError(this.mock, 'GovernorOnlyExecutor') - .withArgs(this.owner); - }); - - it('setVotingPeriod is protected', async function () { - await expect(this.mock.connect(this.owner).setVotingPeriod(32n)) - .to.be.revertedWithCustomError(this.mock, 'GovernorOnlyExecutor') - .withArgs(this.owner); - }); - - it('setProposalThreshold is protected', async function () { - await expect(this.mock.connect(this.owner).setProposalThreshold(1_000_000_000_000_000_000n)) - .to.be.revertedWithCustomError(this.mock, 'GovernorOnlyExecutor') - .withArgs(this.owner); - }); - - it('can setVotingDelay through governance', async function () { - this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('setVotingDelay', [0n]), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.execute()).to.emit(this.mock, 'VotingDelaySet').withArgs(4n, 0n); - - expect(await this.mock.votingDelay()).to.equal(0n); - }); - - it('can setVotingPeriod through governance', async function () { - this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('setVotingPeriod', [32n]), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.execute()).to.emit(this.mock, 'VotingPeriodSet').withArgs(16n, 32n); - - expect(await this.mock.votingPeriod()).to.equal(32n); - }); - - it('cannot setVotingPeriod to 0 through governance', async function () { - const votingPeriod = 0n; - - this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('setVotingPeriod', [votingPeriod]), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorInvalidVotingPeriod') - .withArgs(votingPeriod); - }); - - it('can setProposalThreshold to 0 through governance', async function () { - this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('setProposalThreshold', [1_000_000_000_000_000_000n]), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.execute()) - .to.emit(this.mock, 'ProposalThresholdSet') - .withArgs(0n, 1_000_000_000_000_000_000n); - - expect(await this.mock.proposalThreshold()).to.equal(1_000_000_000_000_000_000n); - }); - }); - - describe('safe receive', function () { - describe('ERC721', function () { - const tokenId = 1n; - - beforeEach(async function () { - this.token = await ethers.deployContract('$ERC721', ['Non Fungible Token', 'NFT']); - await this.token.$_mint(this.owner, tokenId); - }); - - it('can receive an ERC721 safeTransfer', async function () { - await this.token.connect(this.owner).safeTransferFrom(this.owner, this.mock, tokenId); - }); - }); - - describe('ERC1155', function () { - const tokenIds = { - 1: 1000n, - 2: 2000n, - 3: 3000n, - }; - - beforeEach(async function () { - this.token = await ethers.deployContract('$ERC1155', ['https://token-cdn-domain/{id}.json']); - await this.token.$_mintBatch(this.owner, Object.keys(tokenIds), Object.values(tokenIds), '0x'); - }); - - it('can receive ERC1155 safeTransfer', async function () { - await this.token.connect(this.owner).safeTransferFrom( - this.owner, - this.mock, - ...Object.entries(tokenIds)[0], // id + amount - '0x', - ); - }); - - it('can receive ERC1155 safeBatchTransfer', async function () { - await this.token - .connect(this.owner) - .safeBatchTransferFrom(this.owner, this.mock, Object.keys(tokenIds), Object.values(tokenIds), '0x'); - }); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/TimelockController.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/TimelockController.test.js deleted file mode 100644 index 08410d4608..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/TimelockController.test.js +++ /dev/null @@ -1,1279 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -const { GovernorHelper } = require('../helpers/governance'); -const { OperationState } = require('../helpers/enums'); -const time = require('../helpers/time'); - -const { shouldSupportInterfaces } = require('../utils/introspection/SupportsInterface.behavior'); - -const salt = '0x025e7b0be353a74631ad648c667493c0e1cd31caa4cc2d3520fdc171ea0cc726'; // a random value - -const MINDELAY = time.duration.days(1); -const DEFAULT_ADMIN_ROLE = ethers.ZeroHash; -const PROPOSER_ROLE = ethers.id('PROPOSER_ROLE'); -const EXECUTOR_ROLE = ethers.id('EXECUTOR_ROLE'); -const CANCELLER_ROLE = ethers.id('CANCELLER_ROLE'); - -const getAddress = obj => obj.address ?? obj.target ?? obj; - -function genOperation(target, value, data, predecessor, salt) { - const id = ethers.keccak256( - ethers.AbiCoder.defaultAbiCoder().encode( - ['address', 'uint256', 'bytes', 'uint256', 'bytes32'], - [getAddress(target), value, data, predecessor, salt], - ), - ); - return { id, target, value, data, predecessor, salt }; -} - -function genOperationBatch(targets, values, payloads, predecessor, salt) { - const id = ethers.keccak256( - ethers.AbiCoder.defaultAbiCoder().encode( - ['address[]', 'uint256[]', 'bytes[]', 'uint256', 'bytes32'], - [targets.map(getAddress), values, payloads, predecessor, salt], - ), - ); - return { id, targets, values, payloads, predecessor, salt }; -} - -async function fixture() { - const [admin, proposer, canceller, executor, other] = await ethers.getSigners(); - - const mock = await ethers.deployContract('TimelockController', [MINDELAY, [proposer], [executor], admin]); - const callreceivermock = await ethers.deployContract('CallReceiverMock'); - const implementation2 = await ethers.deployContract('Implementation2'); - - expect(await mock.hasRole(CANCELLER_ROLE, proposer)).to.be.true; - await mock.connect(admin).revokeRole(CANCELLER_ROLE, proposer); - await mock.connect(admin).grantRole(CANCELLER_ROLE, canceller); - - return { - admin, - proposer, - canceller, - executor, - other, - mock, - callreceivermock, - implementation2, - }; -} - -describe('TimelockController', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldSupportInterfaces(['ERC1155Receiver']); - - it('initial state', async function () { - expect(await this.mock.getMinDelay()).to.equal(MINDELAY); - - expect(await this.mock.DEFAULT_ADMIN_ROLE()).to.equal(DEFAULT_ADMIN_ROLE); - expect(await this.mock.PROPOSER_ROLE()).to.equal(PROPOSER_ROLE); - expect(await this.mock.EXECUTOR_ROLE()).to.equal(EXECUTOR_ROLE); - expect(await this.mock.CANCELLER_ROLE()).to.equal(CANCELLER_ROLE); - - expect( - await Promise.all( - [PROPOSER_ROLE, CANCELLER_ROLE, EXECUTOR_ROLE].map(role => this.mock.hasRole(role, this.proposer)), - ), - ).to.deep.equal([true, false, false]); - - expect( - await Promise.all( - [PROPOSER_ROLE, CANCELLER_ROLE, EXECUTOR_ROLE].map(role => this.mock.hasRole(role, this.canceller)), - ), - ).to.deep.equal([false, true, false]); - - expect( - await Promise.all( - [PROPOSER_ROLE, CANCELLER_ROLE, EXECUTOR_ROLE].map(role => this.mock.hasRole(role, this.executor)), - ), - ).to.deep.equal([false, false, true]); - }); - - it('optional admin', async function () { - const mock = await ethers.deployContract('TimelockController', [ - MINDELAY, - [this.proposer], - [this.executor], - ethers.ZeroAddress, - ]); - expect(await mock.hasRole(DEFAULT_ADMIN_ROLE, this.admin)).to.be.false; - expect(await mock.hasRole(DEFAULT_ADMIN_ROLE, mock.target)).to.be.true; - }); - - describe('methods', function () { - describe('operation hashing', function () { - it('hashOperation', async function () { - this.operation = genOperation( - '0x29cebefe301c6ce1bb36b58654fea275e1cacc83', - '0xf94fdd6e21da21d2', - '0xa3bc5104', - '0xba41db3be0a9929145cfe480bd0f1f003689104d275ae912099f925df424ef94', - '0x60d9109846ab510ed75c15f979ae366a8a2ace11d34ba9788c13ac296db50e6e', - ); - expect( - await this.mock.hashOperation( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - ), - ).to.equal(this.operation.id); - }); - - it('hashOperationBatch', async function () { - this.operation = genOperationBatch( - Array(8).fill('0x2d5f21620e56531c1d59c2df9b8e95d129571f71'), - Array(8).fill('0x2b993cfce932ccee'), - Array(8).fill('0xcf51966b'), - '0xce8f45069cc71d25f71ba05062de1a3974f9849b004de64a70998bca9d29c2e7', - '0x8952d74c110f72bfe5accdf828c74d53a7dfb71235dfa8a1e8c75d8576b372ff', - ); - expect( - await this.mock.hashOperationBatch( - this.operation.targets, - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - ), - ).to.equal(this.operation.id); - }); - }); - describe('simple', function () { - describe('schedule', function () { - beforeEach(async function () { - this.operation = genOperation( - '0x31754f590B97fD975Eb86938f18Cc304E264D2F2', - 0n, - '0x3bf92ccc', - ethers.ZeroHash, - salt, - ); - }); - - it('proposer can schedule', async function () { - const tx = await this.mock - .connect(this.proposer) - .schedule( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ); - - await expect(tx) - .to.emit(this.mock, 'CallScheduled') - .withArgs( - this.operation.id, - 0n, - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - MINDELAY, - ) - .to.emit(this.mock, 'CallSalt') - .withArgs(this.operation.id, this.operation.salt); - - expect(await this.mock.getTimestamp(this.operation.id)).to.equal( - (await time.clockFromReceipt.timestamp(tx)) + MINDELAY, - ); - }); - - it('prevent overwriting active operation', async function () { - await this.mock - .connect(this.proposer) - .schedule( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ); - - await expect( - this.mock - .connect(this.proposer) - .schedule( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnexpectedOperationState') - .withArgs(this.operation.id, GovernorHelper.proposalStatesToBitMap(OperationState.Unset)); - }); - - it('prevent non-proposer from committing', async function () { - await expect( - this.mock - .connect(this.other) - .schedule( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.other, PROPOSER_ROLE); - }); - - it('enforce minimum delay', async function () { - await expect( - this.mock - .connect(this.proposer) - .schedule( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - MINDELAY - 1n, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockInsufficientDelay') - .withArgs(MINDELAY - 1n, MINDELAY); - }); - - it('schedule operation with salt zero', async function () { - await expect( - this.mock - .connect(this.proposer) - .schedule( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - ethers.ZeroHash, - MINDELAY, - ), - ).to.not.emit(this.mock, 'CallSalt'); - }); - }); - - describe('execute', function () { - beforeEach(async function () { - this.operation = genOperation( - '0xAe22104DCD970750610E6FE15E623468A98b15f7', - 0n, - '0x13e414de', - ethers.ZeroHash, - '0xc1059ed2dc130227aa1d1d539ac94c641306905c020436c636e19e3fab56fc7f', - ); - }); - - it('revert if operation is not scheduled', async function () { - await expect( - this.mock - .connect(this.executor) - .execute( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnexpectedOperationState') - .withArgs(this.operation.id, GovernorHelper.proposalStatesToBitMap(OperationState.Ready)); - }); - - describe('with scheduled operation', function () { - beforeEach(async function () { - await this.mock - .connect(this.proposer) - .schedule( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ); - }); - - it('revert if execution comes too early 1/2', async function () { - await expect( - this.mock - .connect(this.executor) - .execute( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnexpectedOperationState') - .withArgs(this.operation.id, GovernorHelper.proposalStatesToBitMap(OperationState.Ready)); - }); - - it('revert if execution comes too early 2/2', async function () { - // -1 is too tight, test sometime fails - await this.mock.getTimestamp(this.operation.id).then(clock => time.increaseTo.timestamp(clock - 5n)); - - await expect( - this.mock - .connect(this.executor) - .execute( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnexpectedOperationState') - .withArgs(this.operation.id, GovernorHelper.proposalStatesToBitMap(OperationState.Ready)); - }); - - describe('on time', function () { - beforeEach(async function () { - await this.mock.getTimestamp(this.operation.id).then(time.increaseTo.timestamp); - }); - - it('executor can reveal', async function () { - await expect( - this.mock - .connect(this.executor) - .execute( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - ), - ) - .to.emit(this.mock, 'CallExecuted') - .withArgs(this.operation.id, 0n, this.operation.target, this.operation.value, this.operation.data); - }); - - it('prevent non-executor from revealing', async function () { - await expect( - this.mock - .connect(this.other) - .execute( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.other, EXECUTOR_ROLE); - }); - - it('prevents reentrancy execution', async function () { - // Create operation - const reentrant = await ethers.deployContract('$TimelockReentrant'); - const reentrantOperation = genOperation( - reentrant, - 0n, - reentrant.interface.encodeFunctionData('reenter'), - ethers.ZeroHash, - salt, - ); - - // Schedule so it can be executed - await this.mock - .connect(this.proposer) - .schedule( - reentrantOperation.target, - reentrantOperation.value, - reentrantOperation.data, - reentrantOperation.predecessor, - reentrantOperation.salt, - MINDELAY, - ); - - // Advance on time to make the operation executable - await this.mock.getTimestamp(reentrantOperation.id).then(time.increaseTo.timestamp); - - // Grant executor role to the reentrant contract - await this.mock.connect(this.admin).grantRole(EXECUTOR_ROLE, reentrant); - - // Prepare reenter - const data = this.mock.interface.encodeFunctionData('execute', [ - getAddress(reentrantOperation.target), - reentrantOperation.value, - reentrantOperation.data, - reentrantOperation.predecessor, - reentrantOperation.salt, - ]); - await reentrant.enableRentrancy(this.mock, data); - - // Expect to fail - await expect( - this.mock - .connect(this.executor) - .execute( - reentrantOperation.target, - reentrantOperation.value, - reentrantOperation.data, - reentrantOperation.predecessor, - reentrantOperation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnexpectedOperationState') - .withArgs(reentrantOperation.id, GovernorHelper.proposalStatesToBitMap(OperationState.Ready)); - - // Disable reentrancy - await reentrant.disableReentrancy(); - const nonReentrantOperation = reentrantOperation; // Not anymore - - // Try again successfully - await expect( - this.mock - .connect(this.executor) - .execute( - nonReentrantOperation.target, - nonReentrantOperation.value, - nonReentrantOperation.data, - nonReentrantOperation.predecessor, - nonReentrantOperation.salt, - ), - ) - .to.emit(this.mock, 'CallExecuted') - .withArgs( - nonReentrantOperation.id, - 0n, - getAddress(nonReentrantOperation), - nonReentrantOperation.value, - nonReentrantOperation.data, - ); - }); - }); - }); - }); - }); - - describe('batch', function () { - describe('schedule', function () { - beforeEach(async function () { - this.operation = genOperationBatch( - Array(8).fill('0xEd912250835c812D4516BBD80BdaEA1bB63a293C'), - Array(8).fill(0n), - Array(8).fill('0x2fcb7a88'), - ethers.ZeroHash, - '0x6cf9d042ade5de78bed9ffd075eb4b2a4f6b1736932c2dc8af517d6e066f51f5', - ); - }); - - it('proposer can schedule', async function () { - const tx = this.mock - .connect(this.proposer) - .scheduleBatch( - this.operation.targets, - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ); - for (const i in this.operation.targets) { - await expect(tx) - .to.emit(this.mock, 'CallScheduled') - .withArgs( - this.operation.id, - i, - getAddress(this.operation.targets[i]), - this.operation.values[i], - this.operation.payloads[i], - this.operation.predecessor, - MINDELAY, - ) - .to.emit(this.mock, 'CallSalt') - .withArgs(this.operation.id, this.operation.salt); - } - - expect(await this.mock.getTimestamp(this.operation.id)).to.equal( - (await time.clockFromReceipt.timestamp(tx)) + MINDELAY, - ); - }); - - it('prevent overwriting active operation', async function () { - await this.mock - .connect(this.proposer) - .scheduleBatch( - this.operation.targets, - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ); - - await expect( - this.mock - .connect(this.proposer) - .scheduleBatch( - this.operation.targets, - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnexpectedOperationState') - .withArgs(this.operation.id, GovernorHelper.proposalStatesToBitMap(OperationState.Unset)); - }); - - it('length of batch parameter must match #1', async function () { - await expect( - this.mock - .connect(this.proposer) - .scheduleBatch( - this.operation.targets, - [], - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockInvalidOperationLength') - .withArgs(this.operation.targets.length, this.operation.payloads.length, 0n); - }); - - it('length of batch parameter must match #1', async function () { - await expect( - this.mock - .connect(this.proposer) - .scheduleBatch( - this.operation.targets, - this.operation.values, - [], - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockInvalidOperationLength') - .withArgs(this.operation.targets.length, 0n, this.operation.payloads.length); - }); - - it('prevent non-proposer from committing', async function () { - await expect( - this.mock - .connect(this.other) - .scheduleBatch( - this.operation.targets, - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.other, PROPOSER_ROLE); - }); - - it('enforce minimum delay', async function () { - await expect( - this.mock - .connect(this.proposer) - .scheduleBatch( - this.operation.targets, - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - MINDELAY - 1n, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockInsufficientDelay') - .withArgs(MINDELAY - 1n, MINDELAY); - }); - }); - - describe('execute', function () { - beforeEach(async function () { - this.operation = genOperationBatch( - Array(8).fill('0x76E53CcEb05131Ef5248553bEBDb8F70536830b1'), - Array(8).fill(0n), - Array(8).fill('0x58a60f63'), - ethers.ZeroHash, - '0x9545eeabc7a7586689191f78a5532443698538e54211b5bd4d7dc0fc0102b5c7', - ); - }); - - it('revert if operation is not scheduled', async function () { - await expect( - this.mock - .connect(this.executor) - .executeBatch( - this.operation.targets, - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnexpectedOperationState') - .withArgs(this.operation.id, GovernorHelper.proposalStatesToBitMap(OperationState.Ready)); - }); - - describe('with scheduled operation', function () { - beforeEach(async function () { - await this.mock - .connect(this.proposer) - .scheduleBatch( - this.operation.targets, - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ); - }); - - it('revert if execution comes too early 1/2', async function () { - await expect( - this.mock - .connect(this.executor) - .executeBatch( - this.operation.targets, - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnexpectedOperationState') - .withArgs(this.operation.id, GovernorHelper.proposalStatesToBitMap(OperationState.Ready)); - }); - - it('revert if execution comes too early 2/2', async function () { - // -1 is to tight, test sometime fails - await this.mock.getTimestamp(this.operation.id).then(clock => time.increaseTo.timestamp(clock - 5n)); - - await expect( - this.mock - .connect(this.executor) - .executeBatch( - this.operation.targets, - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnexpectedOperationState') - .withArgs(this.operation.id, GovernorHelper.proposalStatesToBitMap(OperationState.Ready)); - }); - - describe('on time', function () { - beforeEach(async function () { - await this.mock.getTimestamp(this.operation.id).then(time.increaseTo.timestamp); - }); - - it('executor can reveal', async function () { - const tx = this.mock - .connect(this.executor) - .executeBatch( - this.operation.targets, - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - ); - for (const i in this.operation.targets) { - await expect(tx) - .to.emit(this.mock, 'CallExecuted') - .withArgs( - this.operation.id, - i, - this.operation.targets[i], - this.operation.values[i], - this.operation.payloads[i], - ); - } - }); - - it('prevent non-executor from revealing', async function () { - await expect( - this.mock - .connect(this.other) - .executeBatch( - this.operation.targets, - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.other, EXECUTOR_ROLE); - }); - - it('length mismatch #1', async function () { - await expect( - this.mock - .connect(this.executor) - .executeBatch( - [], - this.operation.values, - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockInvalidOperationLength') - .withArgs(0, this.operation.payloads.length, this.operation.values.length); - }); - - it('length mismatch #2', async function () { - await expect( - this.mock - .connect(this.executor) - .executeBatch( - this.operation.targets, - [], - this.operation.payloads, - this.operation.predecessor, - this.operation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockInvalidOperationLength') - .withArgs(this.operation.targets.length, this.operation.payloads.length, 0n); - }); - - it('length mismatch #3', async function () { - await expect( - this.mock - .connect(this.executor) - .executeBatch( - this.operation.targets, - this.operation.values, - [], - this.operation.predecessor, - this.operation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockInvalidOperationLength') - .withArgs(this.operation.targets.length, 0n, this.operation.values.length); - }); - - it('prevents reentrancy execution', async function () { - // Create operation - const reentrant = await ethers.deployContract('$TimelockReentrant'); - const reentrantBatchOperation = genOperationBatch( - [reentrant], - [0n], - [reentrant.interface.encodeFunctionData('reenter')], - ethers.ZeroHash, - salt, - ); - - // Schedule so it can be executed - await this.mock - .connect(this.proposer) - .scheduleBatch( - reentrantBatchOperation.targets, - reentrantBatchOperation.values, - reentrantBatchOperation.payloads, - reentrantBatchOperation.predecessor, - reentrantBatchOperation.salt, - MINDELAY, - ); - - // Advance on time to make the operation executable - await this.mock.getTimestamp(reentrantBatchOperation.id).then(time.increaseTo.timestamp); - - // Grant executor role to the reentrant contract - await this.mock.connect(this.admin).grantRole(EXECUTOR_ROLE, reentrant); - - // Prepare reenter - const data = this.mock.interface.encodeFunctionData('executeBatch', [ - reentrantBatchOperation.targets.map(getAddress), - reentrantBatchOperation.values, - reentrantBatchOperation.payloads, - reentrantBatchOperation.predecessor, - reentrantBatchOperation.salt, - ]); - await reentrant.enableRentrancy(this.mock, data); - - // Expect to fail - await expect( - this.mock - .connect(this.executor) - .executeBatch( - reentrantBatchOperation.targets, - reentrantBatchOperation.values, - reentrantBatchOperation.payloads, - reentrantBatchOperation.predecessor, - reentrantBatchOperation.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnexpectedOperationState') - .withArgs(reentrantBatchOperation.id, GovernorHelper.proposalStatesToBitMap(OperationState.Ready)); - - // Disable reentrancy - await reentrant.disableReentrancy(); - const nonReentrantBatchOperation = reentrantBatchOperation; // Not anymore - - // Try again successfully - const tx = this.mock - .connect(this.executor) - .executeBatch( - nonReentrantBatchOperation.targets, - nonReentrantBatchOperation.values, - nonReentrantBatchOperation.payloads, - nonReentrantBatchOperation.predecessor, - nonReentrantBatchOperation.salt, - ); - for (const i in nonReentrantBatchOperation.targets) { - await expect(tx) - .to.emit(this.mock, 'CallExecuted') - .withArgs( - nonReentrantBatchOperation.id, - i, - nonReentrantBatchOperation.targets[i], - nonReentrantBatchOperation.values[i], - nonReentrantBatchOperation.payloads[i], - ); - } - }); - }); - }); - - it('partial execution', async function () { - const operation = genOperationBatch( - [this.callreceivermock, this.callreceivermock, this.callreceivermock], - [0n, 0n, 0n], - [ - this.callreceivermock.interface.encodeFunctionData('mockFunction'), - this.callreceivermock.interface.encodeFunctionData('mockFunctionRevertsNoReason'), - this.callreceivermock.interface.encodeFunctionData('mockFunction'), - ], - ethers.ZeroHash, - '0x8ac04aa0d6d66b8812fb41d39638d37af0a9ab11da507afd65c509f8ed079d3e', - ); - - await this.mock - .connect(this.proposer) - .scheduleBatch( - operation.targets, - operation.values, - operation.payloads, - operation.predecessor, - operation.salt, - MINDELAY, - ); - - await this.mock.getTimestamp(operation.id).then(time.increaseTo.timestamp); - - await expect( - this.mock - .connect(this.executor) - .executeBatch( - operation.targets, - operation.values, - operation.payloads, - operation.predecessor, - operation.salt, - ), - ).to.be.revertedWithCustomError(this.mock, 'FailedCall'); - }); - }); - }); - - describe('cancel', function () { - beforeEach(async function () { - this.operation = genOperation( - '0xC6837c44AA376dbe1d2709F13879E040CAb653ca', - 0n, - '0x296e58dd', - ethers.ZeroHash, - '0xa2485763600634800df9fc9646fb2c112cf98649c55f63dd1d9c7d13a64399d9', - ); - await this.mock - .connect(this.proposer) - .schedule( - this.operation.target, - this.operation.value, - this.operation.data, - this.operation.predecessor, - this.operation.salt, - MINDELAY, - ); - }); - - it('canceller can cancel', async function () { - await expect(this.mock.connect(this.canceller).cancel(this.operation.id)) - .to.emit(this.mock, 'Cancelled') - .withArgs(this.operation.id); - }); - - it('cannot cancel invalid operation', async function () { - await expect(this.mock.connect(this.canceller).cancel(ethers.ZeroHash)) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnexpectedOperationState') - .withArgs( - ethers.ZeroHash, - GovernorHelper.proposalStatesToBitMap([OperationState.Waiting, OperationState.Ready]), - ); - }); - - it('prevent non-canceller from canceling', async function () { - await expect(this.mock.connect(this.other).cancel(this.operation.id)) - .to.be.revertedWithCustomError(this.mock, 'AccessControlUnauthorizedAccount') - .withArgs(this.other, CANCELLER_ROLE); - }); - }); - }); - - describe('maintenance', function () { - it('prevent unauthorized maintenance', async function () { - await expect(this.mock.connect(this.other).updateDelay(0n)) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnauthorizedCaller') - .withArgs(this.other); - }); - - it('timelock scheduled maintenance', async function () { - const newDelay = time.duration.hours(6); - const operation = genOperation( - this.mock, - 0n, - this.mock.interface.encodeFunctionData('updateDelay', [newDelay]), - ethers.ZeroHash, - '0xf8e775b2c5f4d66fb5c7fa800f35ef518c262b6014b3c0aee6ea21bff157f108', - ); - - await this.mock - .connect(this.proposer) - .schedule(operation.target, operation.value, operation.data, operation.predecessor, operation.salt, MINDELAY); - - await this.mock.getTimestamp(operation.id).then(time.increaseTo.timestamp); - - await expect( - this.mock - .connect(this.executor) - .execute(operation.target, operation.value, operation.data, operation.predecessor, operation.salt), - ) - .to.emit(this.mock, 'MinDelayChange') - .withArgs(MINDELAY, newDelay); - - expect(await this.mock.getMinDelay()).to.equal(newDelay); - }); - }); - - describe('dependency', function () { - beforeEach(async function () { - this.operation1 = genOperation( - '0xdE66bD4c97304200A95aE0AadA32d6d01A867E39', - 0n, - '0x01dc731a', - ethers.ZeroHash, - '0x64e932133c7677402ead2926f86205e2ca4686aebecf5a8077627092b9bb2feb', - ); - this.operation2 = genOperation( - '0x3c7944a3F1ee7fc8c5A5134ba7c79D11c3A1FCa3', - 0n, - '0x8f531849', - this.operation1.id, - '0x036e1311cac523f9548e6461e29fb1f8f9196b91910a41711ea22f5de48df07d', - ); - await this.mock - .connect(this.proposer) - .schedule( - this.operation1.target, - this.operation1.value, - this.operation1.data, - this.operation1.predecessor, - this.operation1.salt, - MINDELAY, - ); - await this.mock - .connect(this.proposer) - .schedule( - this.operation2.target, - this.operation2.value, - this.operation2.data, - this.operation2.predecessor, - this.operation2.salt, - MINDELAY, - ); - - await this.mock.getTimestamp(this.operation2.id).then(time.increaseTo.timestamp); - }); - - it('cannot execute before dependency', async function () { - await expect( - this.mock - .connect(this.executor) - .execute( - this.operation2.target, - this.operation2.value, - this.operation2.data, - this.operation2.predecessor, - this.operation2.salt, - ), - ) - .to.be.revertedWithCustomError(this.mock, 'TimelockUnexecutedPredecessor') - .withArgs(this.operation1.id); - }); - - it('can execute after dependency', async function () { - await this.mock - .connect(this.executor) - .execute( - this.operation1.target, - this.operation1.value, - this.operation1.data, - this.operation1.predecessor, - this.operation1.salt, - ); - await this.mock - .connect(this.executor) - .execute( - this.operation2.target, - this.operation2.value, - this.operation2.data, - this.operation2.predecessor, - this.operation2.salt, - ); - }); - }); - - describe('usage scenario', function () { - this.timeout(10000); - - it('call', async function () { - const operation = genOperation( - this.implementation2, - 0n, - this.implementation2.interface.encodeFunctionData('setValue', [42n]), - ethers.ZeroHash, - '0x8043596363daefc89977b25f9d9b4d06c3910959ef0c4d213557a903e1b555e2', - ); - - await this.mock - .connect(this.proposer) - .schedule(operation.target, operation.value, operation.data, operation.predecessor, operation.salt, MINDELAY); - - await this.mock.getTimestamp(operation.id).then(time.increaseTo.timestamp); - - await this.mock - .connect(this.executor) - .execute(operation.target, operation.value, operation.data, operation.predecessor, operation.salt); - - expect(await this.implementation2.getValue()).to.equal(42n); - }); - - it('call reverting', async function () { - const operation = genOperation( - this.callreceivermock, - 0n, - this.callreceivermock.interface.encodeFunctionData('mockFunctionRevertsNoReason'), - ethers.ZeroHash, - '0xb1b1b276fdf1a28d1e00537ea73b04d56639128b08063c1a2f70a52e38cba693', - ); - - await this.mock - .connect(this.proposer) - .schedule(operation.target, operation.value, operation.data, operation.predecessor, operation.salt, MINDELAY); - - await this.mock.getTimestamp(operation.id).then(time.increaseTo.timestamp); - - await expect( - this.mock - .connect(this.executor) - .execute(operation.target, operation.value, operation.data, operation.predecessor, operation.salt), - ).to.be.revertedWithCustomError(this.mock, 'FailedCall'); - }); - - it('call throw', async function () { - const operation = genOperation( - this.callreceivermock, - 0n, - this.callreceivermock.interface.encodeFunctionData('mockFunctionThrows'), - ethers.ZeroHash, - '0xe5ca79f295fc8327ee8a765fe19afb58f4a0cbc5053642bfdd7e73bc68e0fc67', - ); - - await this.mock - .connect(this.proposer) - .schedule(operation.target, operation.value, operation.data, operation.predecessor, operation.salt, MINDELAY); - - await this.mock.getTimestamp(operation.id).then(time.increaseTo.timestamp); - - // Targeted function reverts with a panic code (0x1) + the timelock bubble the panic code - await expect( - this.mock - .connect(this.executor) - .execute(operation.target, operation.value, operation.data, operation.predecessor, operation.salt), - ).to.be.revertedWithPanic(PANIC_CODES.ASSERTION_ERROR); - }); - - it('call out of gas', async function () { - const operation = genOperation( - this.callreceivermock, - 0n, - this.callreceivermock.interface.encodeFunctionData('mockFunctionOutOfGas'), - ethers.ZeroHash, - '0xf3274ce7c394c5b629d5215723563a744b817e1730cca5587c567099a14578fd', - ); - - await this.mock - .connect(this.proposer) - .schedule(operation.target, operation.value, operation.data, operation.predecessor, operation.salt, MINDELAY); - - await this.mock.getTimestamp(operation.id).then(time.increaseTo.timestamp); - - await expect( - this.mock - .connect(this.executor) - .execute(operation.target, operation.value, operation.data, operation.predecessor, operation.salt, { - gasLimit: '100000', - }), - ).to.be.revertedWithCustomError(this.mock, 'FailedCall'); - }); - - it('call payable with eth', async function () { - const operation = genOperation( - this.callreceivermock, - 1, - this.callreceivermock.interface.encodeFunctionData('mockFunction'), - ethers.ZeroHash, - '0x5ab73cd33477dcd36c1e05e28362719d0ed59a7b9ff14939de63a43073dc1f44', - ); - - await this.mock - .connect(this.proposer) - .schedule(operation.target, operation.value, operation.data, operation.predecessor, operation.salt, MINDELAY); - - await this.mock.getTimestamp(operation.id).then(time.increaseTo.timestamp); - - expect(await ethers.provider.getBalance(this.mock)).to.equal(0n); - expect(await ethers.provider.getBalance(this.callreceivermock)).to.equal(0n); - - await this.mock - .connect(this.executor) - .execute(operation.target, operation.value, operation.data, operation.predecessor, operation.salt, { - value: 1, - }); - - expect(await ethers.provider.getBalance(this.mock)).to.equal(0n); - expect(await ethers.provider.getBalance(this.callreceivermock)).to.equal(1n); - }); - - it('call nonpayable with eth', async function () { - const operation = genOperation( - this.callreceivermock, - 1, - this.callreceivermock.interface.encodeFunctionData('mockFunctionNonPayable'), - ethers.ZeroHash, - '0xb78edbd920c7867f187e5aa6294ae5a656cfbf0dea1ccdca3751b740d0f2bdf8', - ); - - await this.mock - .connect(this.proposer) - .schedule(operation.target, operation.value, operation.data, operation.predecessor, operation.salt, MINDELAY); - - await this.mock.getTimestamp(operation.id).then(time.increaseTo.timestamp); - - expect(await ethers.provider.getBalance(this.mock)).to.equal(0n); - expect(await ethers.provider.getBalance(this.callreceivermock)).to.equal(0n); - - await expect( - this.mock - .connect(this.executor) - .execute(operation.target, operation.value, operation.data, operation.predecessor, operation.salt), - ).to.be.revertedWithCustomError(this.mock, 'FailedCall'); - - expect(await ethers.provider.getBalance(this.mock)).to.equal(0n); - expect(await ethers.provider.getBalance(this.callreceivermock)).to.equal(0n); - }); - - it('call reverting with eth', async function () { - const operation = genOperation( - this.callreceivermock, - 1, - this.callreceivermock.interface.encodeFunctionData('mockFunctionRevertsNoReason'), - ethers.ZeroHash, - '0xdedb4563ef0095db01d81d3f2decf57cf83e4a72aa792af14c43a792b56f4de6', - ); - - await this.mock - .connect(this.proposer) - .schedule(operation.target, operation.value, operation.data, operation.predecessor, operation.salt, MINDELAY); - - await this.mock.getTimestamp(operation.id).then(time.increaseTo.timestamp); - - expect(await ethers.provider.getBalance(this.mock)).to.equal(0n); - expect(await ethers.provider.getBalance(this.callreceivermock)).to.equal(0n); - - await expect( - this.mock - .connect(this.executor) - .execute(operation.target, operation.value, operation.data, operation.predecessor, operation.salt), - ).to.be.revertedWithCustomError(this.mock, 'FailedCall'); - - expect(await ethers.provider.getBalance(this.mock)).to.equal(0n); - expect(await ethers.provider.getBalance(this.callreceivermock)).to.equal(0n); - }); - }); - - describe('safe receive', function () { - describe('ERC721', function () { - const tokenId = 1n; - - beforeEach(async function () { - this.token = await ethers.deployContract('$ERC721', ['Non Fungible Token', 'NFT']); - await this.token.$_mint(this.other, tokenId); - }); - - it('can receive an ERC721 safeTransfer', async function () { - await this.token.connect(this.other).safeTransferFrom(this.other, this.mock, tokenId); - }); - }); - - describe('ERC1155', function () { - const tokenIds = { - 1: 1000n, - 2: 2000n, - 3: 3000n, - }; - - beforeEach(async function () { - this.token = await ethers.deployContract('$ERC1155', ['https://token-cdn-domain/{id}.json']); - await this.token.$_mintBatch(this.other, Object.keys(tokenIds), Object.values(tokenIds), '0x'); - }); - - it('can receive ERC1155 safeTransfer', async function () { - await this.token.connect(this.other).safeTransferFrom( - this.other, - this.mock, - ...Object.entries(tokenIds)[0n], // id + amount - '0x', - ); - }); - - it('can receive ERC1155 safeBatchTransfer', async function () { - await this.token - .connect(this.other) - .safeBatchTransferFrom(this.other, this.mock, Object.keys(tokenIds), Object.values(tokenIds), '0x'); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorCountingFractional.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorCountingFractional.test.js deleted file mode 100644 index 393dbad79d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorCountingFractional.test.js +++ /dev/null @@ -1,248 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { GovernorHelper } = require('../../helpers/governance'); -const { VoteType } = require('../../helpers/enums'); -const { zip } = require('../../helpers/iterate'); -const { sum } = require('../../helpers/math'); - -const TOKENS = [ - { Token: '$ERC20Votes', mode: 'blocknumber' }, - { Token: '$ERC20VotesTimestampMock', mode: 'timestamp' }, -]; - -const name = 'OZ-Governor'; -const version = '1'; -const tokenName = 'MockToken'; -const tokenSymbol = 'MTKN'; -const tokenSupply = ethers.parseEther('100'); -const votingDelay = 4n; -const votingPeriod = 16n; -const value = ethers.parseEther('1'); - -describe('GovernorCountingFractional', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - const [owner, proposer, voter1, voter2, voter3, voter4, other] = await ethers.getSigners(); - const receiver = await ethers.deployContract('CallReceiverMock'); - - const token = await ethers.deployContract(Token, [tokenName, tokenSymbol, version]); - const mock = await ethers.deployContract('$GovernorFractionalMock', [ - name, // name - votingDelay, // initialVotingDelay - votingPeriod, // initialVotingPeriod - 0n, // initialProposalThreshold - token, // tokenAddress - 10n, // quorumNumeratorValue - ]); - - await owner.sendTransaction({ to: mock, value }); - await token.$_mint(owner, tokenSupply); - - const helper = new GovernorHelper(mock, mode); - await helper.connect(owner).delegate({ token, to: voter1, value: ethers.parseEther('10') }); - await helper.connect(owner).delegate({ token, to: voter2, value: ethers.parseEther('7') }); - await helper.connect(owner).delegate({ token, to: voter3, value: ethers.parseEther('5') }); - await helper.connect(owner).delegate({ token, to: voter4, value: ethers.parseEther('2') }); - - return { owner, proposer, voter1, voter2, voter3, voter4, other, receiver, token, mock, helper }; - }; - - describe(`using ${Token}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - - // default proposal - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - value, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - }, - ], - '', - ); - }); - - it('deployment check', async function () { - expect(await this.mock.name()).to.equal(name); - expect(await this.mock.token()).to.equal(this.token); - expect(await this.mock.votingDelay()).to.equal(votingDelay); - expect(await this.mock.votingPeriod()).to.equal(votingPeriod); - expect(await this.mock.COUNTING_MODE()).to.equal( - 'support=bravo,fractional&quorum=for,abstain¶ms=fractional', - ); - }); - - it('nominal is unaffected', async function () { - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For, reason: 'This is nice' }); - await this.helper.connect(this.voter2).vote({ support: VoteType.For }); - await this.helper.connect(this.voter3).vote({ support: VoteType.Against }); - await this.helper.connect(this.voter4).vote({ support: VoteType.Abstain }); - await this.helper.waitForDeadline(); - await this.helper.execute(); - - expect(await this.mock.hasVoted(this.proposal.id, this.owner)).to.be.false; - expect(await this.mock.hasVoted(this.proposal.id, this.voter1)).to.be.true; - expect(await this.mock.hasVoted(this.proposal.id, this.voter2)).to.be.true; - expect(await ethers.provider.getBalance(this.mock)).to.equal(0n); - expect(await ethers.provider.getBalance(this.receiver)).to.equal(value); - }); - - describe('voting with a fraction of the weight', function () { - it('twice', async function () { - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - - expect(await this.mock.proposalVotes(this.proposal.id)).to.deep.equal([0n, 0n, 0n]); - expect(await this.mock.hasVoted(this.proposal.id, this.voter2)).to.equal(false); - expect(await this.mock.usedVotes(this.proposal.id, this.voter2)).to.equal(0n); - - const steps = [ - ['0', '2', '1'], - ['1', '0', '1'], - ].map(votes => votes.map(vote => ethers.parseEther(vote))); - - for (const votes of steps) { - const params = ethers.solidityPacked(['uint128', 'uint128', 'uint128'], votes); - await expect( - this.helper.connect(this.voter2).vote({ - support: VoteType.Parameters, - reason: 'no particular reason', - params, - }), - ) - .to.emit(this.mock, 'VoteCastWithParams') - .withArgs( - this.voter2, - this.proposal.id, - VoteType.Parameters, - sum(...votes), - 'no particular reason', - params, - ); - } - - expect(await this.mock.proposalVotes(this.proposal.id)).to.deep.equal(zip(...steps).map(v => sum(...v))); - expect(await this.mock.hasVoted(this.proposal.id, this.voter2)).to.equal(true); - expect(await this.mock.usedVotes(this.proposal.id, this.voter2)).to.equal(sum(...[].concat(...steps))); - }); - - it('fractional then nominal', async function () { - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - - expect(await this.mock.proposalVotes(this.proposal.id)).to.deep.equal([0n, 0n, 0n]); - expect(await this.mock.hasVoted(this.proposal.id, this.voter2)).to.equal(false); - expect(await this.mock.usedVotes(this.proposal.id, this.voter2)).to.equal(0n); - - const weight = ethers.parseEther('7'); - const fractional = ['1', '2', '1'].map(ethers.parseEther); - - const params = ethers.solidityPacked(['uint128', 'uint128', 'uint128'], fractional); - await expect( - this.helper.connect(this.voter2).vote({ - support: VoteType.Parameters, - reason: 'no particular reason', - params, - }), - ) - .to.emit(this.mock, 'VoteCastWithParams') - .withArgs( - this.voter2, - this.proposal.id, - VoteType.Parameters, - sum(...fractional), - 'no particular reason', - params, - ); - - await expect(this.helper.connect(this.voter2).vote({ support: VoteType.Against })) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter2, this.proposal.id, VoteType.Against, weight - sum(...fractional), ''); - - expect(await this.mock.proposalVotes(this.proposal.id)).to.deep.equal([ - weight - sum(...fractional.slice(1)), - ...fractional.slice(1), - ]); - expect(await this.mock.hasVoted(this.proposal.id, this.voter2)).to.equal(true); - expect(await this.mock.usedVotes(this.proposal.id, this.voter2)).to.equal(weight); - }); - - it('revert if params spend more than available', async function () { - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - - const weight = ethers.parseEther('7'); - const fractional = ['0', '1000', '0'].map(ethers.parseEther); - - await expect( - this.helper.connect(this.voter2).vote({ - support: VoteType.Parameters, - reason: 'no particular reason', - params: ethers.solidityPacked(['uint128', 'uint128', 'uint128'], fractional), - }), - ) - .to.be.revertedWithCustomError(this.mock, 'GovernorExceedRemainingWeight') - .withArgs(this.voter2, sum(...fractional), weight); - }); - - it('revert if no weight remaining', async function () { - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter2).vote({ support: VoteType.For }); - - await expect( - this.helper.connect(this.voter2).vote({ - support: VoteType.Parameters, - reason: 'no particular reason', - params: ethers.solidityPacked(['uint128', 'uint128', 'uint128'], [0n, 1n, 0n]), - }), - ) - .to.be.revertedWithCustomError(this.mock, 'GovernorAlreadyCastVote') - .withArgs(this.voter2); - }); - - it('revert if params are not properly formatted #1', async function () { - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - - await expect( - this.helper.connect(this.voter2).vote({ - support: VoteType.Parameters, - reason: 'no particular reason', - params: ethers.solidityPacked(['uint128', 'uint128'], [0n, 1n]), - }), - ).to.be.revertedWithCustomError(this.mock, 'GovernorInvalidVoteParams'); - }); - - it('revert if params are not properly formatted #2', async function () { - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - - await expect( - this.helper.connect(this.voter2).vote({ - support: VoteType.Against, - reason: 'no particular reason', - params: ethers.solidityPacked(['uint128', 'uint128', 'uint128'], [0n, 1n, 0n]), - }), - ).to.be.revertedWithCustomError(this.mock, 'GovernorInvalidVoteParams'); - }); - - it('revert if vote type is invalid', async function () { - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - - await expect(this.helper.connect(this.voter2).vote({ support: 128n })).to.be.revertedWithCustomError( - this.mock, - 'GovernorInvalidVoteType', - ); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorCountingOverridable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorCountingOverridable.test.js deleted file mode 100644 index 32ee47439f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorCountingOverridable.test.js +++ /dev/null @@ -1,346 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture, mine } = require('@nomicfoundation/hardhat-network-helpers'); - -const { GovernorHelper } = require('../../helpers/governance'); -const { getDomain, OverrideBallot } = require('../../helpers/eip712'); -const { VoteType } = require('../../helpers/enums'); - -const TOKENS = [ - { Token: '$ERC20VotesExtendedMock', mode: 'blocknumber' }, - { Token: '$ERC20VotesExtendedTimestampMock', mode: 'timestamp' }, -]; - -const name = 'Override Governor'; -const version = '1'; -const tokenName = 'MockToken'; -const tokenSymbol = 'MTKN'; -const tokenSupply = ethers.parseEther('100'); -const votingDelay = 4n; -const votingPeriod = 16n; -const value = ethers.parseEther('1'); - -const signBallot = account => (contract, message) => - getDomain(contract).then(domain => account.signTypedData(domain, { OverrideBallot }, message)); - -describe('GovernorCountingOverridable', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - const [owner, proposer, voter1, voter2, voter3, voter4, other] = await ethers.getSigners(); - const receiver = await ethers.deployContract('CallReceiverMock'); - - const token = await ethers.deployContract(Token, [tokenName, tokenSymbol, tokenName, version]); - const mock = await ethers.deployContract('$GovernorCountingOverridableMock', [ - name, // name - votingDelay, // initialVotingDelay - votingPeriod, // initialVotingPeriod - 0n, // initialProposalThreshold - token, // tokenAddress - 10n, // quorumNumeratorValue - ]); - - await owner.sendTransaction({ to: mock, value }); - await token.$_mint(owner, tokenSupply); - - const helper = new GovernorHelper(mock, mode); - await helper.connect(owner).delegate({ token, to: voter1, value: ethers.parseEther('10') }); - await helper.connect(owner).delegate({ token, to: voter2, value: ethers.parseEther('7') }); - await helper.connect(owner).delegate({ token, to: voter3, value: ethers.parseEther('5') }); - await helper.connect(owner).delegate({ token, to: voter4, value: ethers.parseEther('2') }); - - return { owner, proposer, voter1, voter2, voter3, voter4, other, receiver, token, mock, helper }; - }; - - describe(`using ${Token}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - - // default proposal - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - value, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - }, - ], - '', - ); - }); - - it('deployment check', async function () { - expect(await this.mock.name()).to.equal(name); - expect(await this.mock.token()).to.equal(this.token); - expect(await this.mock.votingDelay()).to.equal(votingDelay); - expect(await this.mock.votingPeriod()).to.equal(votingPeriod); - expect(await this.mock.COUNTING_MODE()).to.equal('support=bravo,override&quorum=for,abstain&overridable=true'); - }); - - it('nominal is unaffected', async function () { - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For, reason: 'This is nice' }); - await this.helper.connect(this.voter2).vote({ support: VoteType.For }); - await this.helper.connect(this.voter3).vote({ support: VoteType.Against }); - await this.helper.connect(this.voter4).vote({ support: VoteType.Abstain }); - await this.helper.waitForDeadline(); - await this.helper.execute(); - - expect(await this.mock.hasVoted(this.proposal.id, this.owner)).to.be.false; - expect(await this.mock.hasVoted(this.proposal.id, this.voter1)).to.be.true; - expect(await this.mock.hasVoted(this.proposal.id, this.voter2)).to.be.true; - expect(await ethers.provider.getBalance(this.mock)).to.equal(0n); - expect(await ethers.provider.getBalance(this.receiver)).to.equal(value); - }); - - describe('cast override vote', async function () { - beforeEach(async function () { - // user 1 -(delegate 10 tokens)-> user 2 - // user 2 -(delegate 7 tokens)-> user 2 - // user 3 -(delegate 5 tokens)-> user 1 - // user 4 -(delegate 2 tokens)-> user 2 - await this.token.connect(this.voter1).delegate(this.voter2); - await this.token.connect(this.voter3).delegate(this.voter1); - await this.token.connect(this.voter4).delegate(this.voter2); - await mine(); - - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - }); - - it('override after delegate vote', async function () { - expect(await this.mock.hasVoted(this.helper.id, this.voter1)).to.be.false; - expect(await this.mock.hasVoted(this.helper.id, this.voter2)).to.be.false; - expect(await this.mock.hasVoted(this.helper.id, this.voter3)).to.be.false; - expect(await this.mock.hasVoted(this.helper.id, this.voter4)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter1)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter2)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter3)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter4)).to.be.false; - - // user 2 votes - - await expect(this.helper.connect(this.voter2).vote({ support: VoteType.For })) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter2, this.helper.id, VoteType.For, ethers.parseEther('19'), ''); // 10 + 7 + 2 - - expect(await this.mock.proposalVotes(this.helper.id)).to.deep.eq( - [0, 19, 0].map(x => ethers.parseEther(x.toString())), - ); - expect(await this.mock.hasVoted(this.helper.id, this.voter2)).to.be.true; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter2)).to.be.false; - - // user 1 overrides after user 2 votes - - const reason = "disagree with user 2's decision"; - await expect(this.mock.connect(this.voter1).castOverrideVote(this.helper.id, VoteType.Against, reason)) - .to.emit(this.mock, 'OverrideVoteCast') - .withArgs(this.voter1, this.helper.id, VoteType.Against, ethers.parseEther('10'), reason) - .to.emit(this.mock, 'VoteReduced') - .withArgs(this.voter2, this.helper.id, VoteType.For, ethers.parseEther('10')); - - expect(await this.mock.proposalVotes(this.helper.id)).to.deep.eq( - [10, 9, 0].map(x => ethers.parseEther(x.toString())), - ); - expect(await this.mock.hasVoted(this.helper.id, this.voter1)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter1)).to.be.true; - }); - - it('override before delegate vote', async function () { - expect(await this.mock.hasVoted(this.helper.id, this.voter1)).to.be.false; - expect(await this.mock.hasVoted(this.helper.id, this.voter2)).to.be.false; - expect(await this.mock.hasVoted(this.helper.id, this.voter3)).to.be.false; - expect(await this.mock.hasVoted(this.helper.id, this.voter4)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter1)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter2)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter3)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter4)).to.be.false; - - // user 1 overrides before user 2 votes - - const reason = 'voter 2 is not voting'; - await expect(this.mock.connect(this.voter1).castOverrideVote(this.helper.id, VoteType.Against, reason)) - .to.emit(this.mock, 'OverrideVoteCast') - .withArgs(this.voter1, this.helper.id, VoteType.Against, ethers.parseEther('10'), reason) - .to.not.emit(this.mock, 'VoteReduced'); - - expect(await this.mock.proposalVotes(this.helper.id)).to.deep.eq( - [10, 0, 0].map(x => ethers.parseEther(x.toString())), - ); - expect(await this.mock.hasVoted(this.helper.id, this.voter1)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter1)).to.be.true; - - // user 2 votes - - await expect(this.helper.connect(this.voter2).vote({ support: VoteType.For })) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter2, this.helper.id, VoteType.For, ethers.parseEther('9'), ''); // 7 + 2 - - expect(await this.mock.proposalVotes(this.helper.id)).to.deep.eq( - [10, 9, 0].map(x => ethers.parseEther(x.toString())), - ); - expect(await this.mock.hasVoted(this.helper.id, this.voter2)).to.be.true; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter2)).to.be.false; - }); - - it('override before and after delegate vote', async function () { - expect(await this.mock.hasVoted(this.helper.id, this.voter1)).to.be.false; - expect(await this.mock.hasVoted(this.helper.id, this.voter2)).to.be.false; - expect(await this.mock.hasVoted(this.helper.id, this.voter3)).to.be.false; - expect(await this.mock.hasVoted(this.helper.id, this.voter4)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter1)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter2)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter3)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter4)).to.be.false; - - // user 1 overrides before user 2 votes - - const reason = 'voter 2 is not voting'; - await expect(this.mock.connect(this.voter1).castOverrideVote(this.helper.id, VoteType.Against, reason)) - .to.emit(this.mock, 'OverrideVoteCast') - .withArgs(this.voter1, this.helper.id, VoteType.Against, ethers.parseEther('10'), reason) - .to.not.emit(this.mock, 'VoteReduced'); - - expect(await this.mock.proposalVotes(this.helper.id)).to.deep.eq( - [10, 0, 0].map(x => ethers.parseEther(x.toString())), - ); - expect(await this.mock.hasVoted(this.helper.id, this.voter1)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter1)).to.be.true; - - // user 2 votes - - await expect(this.helper.connect(this.voter2).vote({ support: VoteType.For })) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter2, this.helper.id, VoteType.For, ethers.parseEther('9'), ''); // 7 + 2 - - expect(await this.mock.proposalVotes(this.helper.id)).to.deep.eq( - [10, 9, 0].map(x => ethers.parseEther(x.toString())), - ); - expect(await this.mock.hasVoted(this.helper.id, this.voter2)).to.be.true; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter2)).to.be.false; - - // User 4 overrides after user 2 votes - - const reason2 = "disagree with user 2's decision"; - await expect(this.mock.connect(this.voter4).castOverrideVote(this.helper.id, VoteType.Abstain, reason2)) - .to.emit(this.mock, 'OverrideVoteCast') - .withArgs(this.voter4, this.helper.id, VoteType.Abstain, ethers.parseEther('2'), reason2) - .to.emit(this.mock, 'VoteReduced') - .withArgs(this.voter2, this.helper.id, VoteType.For, ethers.parseEther('2')); - - expect(await this.mock.proposalVotes(this.helper.id)).to.deep.eq( - [10, 7, 2].map(x => ethers.parseEther(x.toString())), - ); - expect(await this.mock.hasVoted(this.helper.id, this.voter4)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter4)).to.be.true; - }); - - it('vote (with delegated balance) and override (with self balance) are independent', async function () { - expect(await this.mock.proposalVotes(this.helper.id)).to.deep.eq( - [0, 0, 0].map(x => ethers.parseEther(x.toString())), - ); - expect(await this.mock.hasVoted(this.helper.id, this.voter1)).to.be.false; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter1)).to.be.false; - - // user 1 votes with delegated weight from user 3 - await expect(this.mock.connect(this.voter1).castVote(this.helper.id, VoteType.For)) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter1, this.helper.id, VoteType.For, ethers.parseEther('5'), ''); - - // user 1 cast an override vote with its own balance (delegated to user 2) - await expect(this.mock.connect(this.voter1).castOverrideVote(this.helper.id, VoteType.Against, '')) - .to.emit(this.mock, 'OverrideVoteCast') - .withArgs(this.voter1, this.helper.id, VoteType.Against, ethers.parseEther('10'), ''); - - expect(await this.mock.proposalVotes(this.helper.id)).to.deep.eq( - [10, 5, 0].map(x => ethers.parseEther(x.toString())), - ); - expect(await this.mock.hasVoted(this.helper.id, this.voter1)).to.be.true; - expect(await this.mock.hasVotedOverride(this.helper.id, this.voter1)).to.be.true; - }); - - it('can not override vote twice', async function () { - await expect(this.mock.connect(this.voter1).castOverrideVote(this.helper.id, VoteType.Against, '')) - .to.emit(this.mock, 'OverrideVoteCast') - .withArgs(this.voter1, this.helper.id, VoteType.Against, ethers.parseEther('10'), ''); - await expect(this.mock.connect(this.voter1).castOverrideVote(this.helper.id, VoteType.Abstain, '')) - .to.be.revertedWithCustomError(this.mock, 'GovernorAlreadyOverridenVote') - .withArgs(this.voter1.address); - }); - - it('can not vote twice', async function () { - await expect(this.mock.connect(this.voter1).castVote(this.helper.id, VoteType.Against)) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter1, this.helper.id, VoteType.Against, ethers.parseEther('5'), ''); - await expect(this.mock.connect(this.voter1).castVote(this.helper.id, VoteType.Abstain)) - .to.be.revertedWithCustomError(this.mock, 'GovernorAlreadyCastVote') - .withArgs(this.voter1.address); - }); - - describe('invalid vote type', function () { - it('override vote', async function () { - await expect( - this.mock.connect(this.voter1).castOverrideVote(this.helper.id, 3, ''), - ).to.be.revertedWithCustomError(this.mock, 'GovernorInvalidVoteType'); - }); - - it('traditional vote', async function () { - await expect(this.mock.connect(this.voter1).castVote(this.helper.id, 3)).to.be.revertedWithCustomError( - this.mock, - 'GovernorInvalidVoteType', - ); - }); - }); - - describe('by signature', function () { - it('EOA signature', async function () { - const nonce = await this.mock.nonces(this.voter1); - - await expect( - this.helper.overrideVote({ - support: VoteType.For, - voter: this.voter1.address, - nonce, - signature: signBallot(this.voter1), - }), - ) - .to.emit(this.mock, 'OverrideVoteCast') - .withArgs(this.voter1, this.helper.id, VoteType.For, ethers.parseEther('10'), ''); - - expect(await this.mock.hasVotedOverride(this.proposal.id, this.voter1)).to.be.true; - }); - - it('revert if signature does not match signer', async function () { - const nonce = await this.mock.nonces(this.voter1); - - const voteParams = { - support: VoteType.For, - voter: this.voter2.address, - nonce, - signature: signBallot(this.voter1), - }; - - await expect(this.helper.overrideVote(voteParams)) - .to.be.revertedWithCustomError(this.mock, 'GovernorInvalidSignature') - .withArgs(voteParams.voter); - }); - - it('revert if vote nonce is incorrect', async function () { - const nonce = await this.mock.nonces(this.voter1); - - const voteParams = { - support: VoteType.For, - voter: this.voter1.address, - nonce: nonce + 1n, - signature: signBallot(this.voter1), - }; - - await expect(this.helper.overrideVote(voteParams)) - .to.be.revertedWithCustomError(this.mock, 'GovernorInvalidSignature') - .withArgs(voteParams.voter); - }); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorERC721.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorERC721.test.js deleted file mode 100644 index 1ae5508d7d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorERC721.test.js +++ /dev/null @@ -1,131 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { GovernorHelper } = require('../../helpers/governance'); -const { VoteType } = require('../../helpers/enums'); - -const TOKENS = [ - { Token: '$ERC721Votes', mode: 'blocknumber' }, - { Token: '$ERC721VotesTimestampMock', mode: 'timestamp' }, -]; - -const name = 'OZ-Governor'; -const version = '1'; -const tokenName = 'MockNFToken'; -const tokenSymbol = 'MTKN'; -const NFT0 = 0n; -const NFT1 = 1n; -const NFT2 = 2n; -const NFT3 = 3n; -const NFT4 = 4n; -const votingDelay = 4n; -const votingPeriod = 16n; -const value = ethers.parseEther('1'); - -describe('GovernorERC721', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - const [owner, voter1, voter2, voter3, voter4] = await ethers.getSigners(); - const receiver = await ethers.deployContract('CallReceiverMock'); - - const token = await ethers.deployContract(Token, [tokenName, tokenSymbol, version]); - const mock = await ethers.deployContract('$GovernorMock', [ - name, // name - votingDelay, // initialVotingDelay - votingPeriod, // initialVotingPeriod - 0n, // initialProposalThreshold - token, // tokenAddress - 10n, // quorumNumeratorValue - ]); - - await owner.sendTransaction({ to: mock, value }); - await Promise.all([NFT0, NFT1, NFT2, NFT3, NFT4].map(tokenId => token.$_mint(owner, tokenId))); - - const helper = new GovernorHelper(mock, mode); - await helper.connect(owner).delegate({ token, to: voter1, tokenId: NFT0 }); - await helper.connect(owner).delegate({ token, to: voter2, tokenId: NFT1 }); - await helper.connect(owner).delegate({ token, to: voter2, tokenId: NFT2 }); - await helper.connect(owner).delegate({ token, to: voter3, tokenId: NFT3 }); - await helper.connect(owner).delegate({ token, to: voter4, tokenId: NFT4 }); - - return { - owner, - voter1, - voter2, - voter3, - voter4, - receiver, - token, - mock, - helper, - }; - }; - - describe(`using ${Token}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - // initiate fresh proposal - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - value, - }, - ], - '', - ); - }); - - it('deployment check', async function () { - expect(await this.mock.name()).to.equal(name); - expect(await this.mock.token()).to.equal(this.token); - expect(await this.mock.votingDelay()).to.equal(votingDelay); - expect(await this.mock.votingPeriod()).to.equal(votingPeriod); - expect(await this.mock.quorum(0n)).to.equal(0n); - - expect(await this.token.getVotes(this.voter1)).to.equal(1n); // NFT0 - expect(await this.token.getVotes(this.voter2)).to.equal(2n); // NFT1 & NFT2 - expect(await this.token.getVotes(this.voter3)).to.equal(1n); // NFT3 - expect(await this.token.getVotes(this.voter4)).to.equal(1n); // NFT4 - }); - - it('voting with ERC721 token', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - - await expect(this.helper.connect(this.voter1).vote({ support: VoteType.For })) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter1, this.proposal.id, VoteType.For, 1n, ''); - - await expect(this.helper.connect(this.voter2).vote({ support: VoteType.For })) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter2, this.proposal.id, VoteType.For, 2n, ''); - - await expect(this.helper.connect(this.voter3).vote({ support: VoteType.Against })) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter3, this.proposal.id, VoteType.Against, 1n, ''); - - await expect(this.helper.connect(this.voter4).vote({ support: VoteType.Abstain })) - .to.emit(this.mock, 'VoteCast') - .withArgs(this.voter4, this.proposal.id, VoteType.Abstain, 1n, ''); - - await this.helper.waitForDeadline(); - await this.helper.execute(); - - expect(await this.mock.hasVoted(this.proposal.id, this.owner)).to.be.false; - expect(await this.mock.hasVoted(this.proposal.id, this.voter1)).to.be.true; - expect(await this.mock.hasVoted(this.proposal.id, this.voter2)).to.be.true; - expect(await this.mock.hasVoted(this.proposal.id, this.voter3)).to.be.true; - expect(await this.mock.hasVoted(this.proposal.id, this.voter4)).to.be.true; - - expect(await this.mock.proposalVotes(this.proposal.id)).to.deep.equal([ - 1n, // againstVotes - 3n, // forVotes - 1n, // abstainVotes - ]); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorPreventLateQuorum.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorPreventLateQuorum.test.js deleted file mode 100644 index aac0e68981..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorPreventLateQuorum.test.js +++ /dev/null @@ -1,185 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { GovernorHelper } = require('../../helpers/governance'); -const { ProposalState, VoteType } = require('../../helpers/enums'); -const time = require('../../helpers/time'); - -const TOKENS = [ - { Token: '$ERC20Votes', mode: 'blocknumber' }, - { Token: '$ERC20VotesTimestampMock', mode: 'timestamp' }, -]; - -const name = 'OZ-Governor'; -const version = '1'; -const tokenName = 'MockToken'; -const tokenSymbol = 'MTKN'; -const tokenSupply = ethers.parseEther('100'); -const votingDelay = 4n; -const votingPeriod = 16n; -const lateQuorumVoteExtension = 8n; -const quorum = ethers.parseEther('1'); -const value = ethers.parseEther('1'); - -describe('GovernorPreventLateQuorum', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - const [owner, proposer, voter1, voter2, voter3, voter4] = await ethers.getSigners(); - const receiver = await ethers.deployContract('CallReceiverMock'); - - const token = await ethers.deployContract(Token, [tokenName, tokenSymbol, version]); - const mock = await ethers.deployContract('$GovernorPreventLateQuorumMock', [ - name, // name - votingDelay, // initialVotingDelay - votingPeriod, // initialVotingPeriod - 0n, // initialProposalThreshold - token, // tokenAddress - lateQuorumVoteExtension, - quorum, - ]); - - await owner.sendTransaction({ to: mock, value }); - await token.$_mint(owner, tokenSupply); - - const helper = new GovernorHelper(mock, mode); - await helper.connect(owner).delegate({ token, to: voter1, value: ethers.parseEther('10') }); - await helper.connect(owner).delegate({ token, to: voter2, value: ethers.parseEther('7') }); - await helper.connect(owner).delegate({ token, to: voter3, value: ethers.parseEther('5') }); - await helper.connect(owner).delegate({ token, to: voter4, value: ethers.parseEther('2') }); - - return { owner, proposer, voter1, voter2, voter3, voter4, receiver, token, mock, helper }; - }; - - describe(`using ${Token}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - // initiate fresh proposal - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - value, - }, - ], - '', - ); - }); - - it('deployment check', async function () { - expect(await this.mock.name()).to.equal(name); - expect(await this.mock.token()).to.equal(this.token); - expect(await this.mock.votingDelay()).to.equal(votingDelay); - expect(await this.mock.votingPeriod()).to.equal(votingPeriod); - expect(await this.mock.quorum(0)).to.equal(quorum); - expect(await this.mock.lateQuorumVoteExtension()).to.equal(lateQuorumVoteExtension); - }); - - it('nominal workflow unaffected', async function () { - const txPropose = await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.connect(this.voter2).vote({ support: VoteType.For }); - await this.helper.connect(this.voter3).vote({ support: VoteType.Against }); - await this.helper.connect(this.voter4).vote({ support: VoteType.Abstain }); - await this.helper.waitForDeadline(); - await this.helper.execute(); - - expect(await this.mock.hasVoted(this.proposal.id, this.owner)).to.be.false; - expect(await this.mock.hasVoted(this.proposal.id, this.voter1)).to.be.true; - expect(await this.mock.hasVoted(this.proposal.id, this.voter2)).to.be.true; - expect(await this.mock.hasVoted(this.proposal.id, this.voter3)).to.be.true; - expect(await this.mock.hasVoted(this.proposal.id, this.voter4)).to.be.true; - - expect(await this.mock.proposalVotes(this.proposal.id)).to.deep.equal([ - ethers.parseEther('5'), // againstVotes - ethers.parseEther('17'), // forVotes - ethers.parseEther('2'), // abstainVotes - ]); - - const voteStart = (await time.clockFromReceipt[mode](txPropose)) + votingDelay; - const voteEnd = (await time.clockFromReceipt[mode](txPropose)) + votingDelay + votingPeriod; - expect(await this.mock.proposalSnapshot(this.proposal.id)).to.equal(voteStart); - expect(await this.mock.proposalDeadline(this.proposal.id)).to.equal(voteEnd); - - await expect(txPropose) - .to.emit(this.mock, 'ProposalCreated') - .withArgs( - this.proposal.id, - this.proposer, - this.proposal.targets, - this.proposal.values, - this.proposal.signatures, - this.proposal.data, - voteStart, - voteEnd, - this.proposal.description, - ); - }); - - it('Delay is extended to prevent last minute take-over', async function () { - const txPropose = await this.helper.connect(this.proposer).propose(); - - // compute original schedule - const snapshotTimepoint = (await time.clockFromReceipt[mode](txPropose)) + votingDelay; - const deadlineTimepoint = (await time.clockFromReceipt[mode](txPropose)) + votingDelay + votingPeriod; - expect(await this.mock.proposalSnapshot(this.proposal.id)).to.equal(snapshotTimepoint); - expect(await this.mock.proposalDeadline(this.proposal.id)).to.equal(deadlineTimepoint); - // wait for the last minute to vote - await this.helper.waitForDeadline(-1n); - const txVote = await this.helper.connect(this.voter2).vote({ support: VoteType.For }); - - // cannot execute yet - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Active); - - // compute new extended schedule - const extendedDeadline = (await time.clockFromReceipt[mode](txVote)) + lateQuorumVoteExtension; - expect(await this.mock.proposalSnapshot(this.proposal.id)).to.equal(snapshotTimepoint); - expect(await this.mock.proposalDeadline(this.proposal.id)).to.equal(extendedDeadline); - - // still possible to vote - await this.helper.connect(this.voter1).vote({ support: VoteType.Against }); - - await this.helper.waitForDeadline(); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Active); - await this.helper.waitForDeadline(1n); - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Defeated); - - // check extension event - await expect(txVote).to.emit(this.mock, 'ProposalExtended').withArgs(this.proposal.id, extendedDeadline); - }); - - describe('onlyGovernance updates', function () { - it('setLateQuorumVoteExtension is protected', async function () { - await expect(this.mock.connect(this.owner).setLateQuorumVoteExtension(0n)) - .to.be.revertedWithCustomError(this.mock, 'GovernorOnlyExecutor') - .withArgs(this.owner); - }); - - it('can setLateQuorumVoteExtension through governance', async function () { - this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('setLateQuorumVoteExtension', [0n]), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.execute()) - .to.emit(this.mock, 'LateQuorumVoteExtensionSet') - .withArgs(lateQuorumVoteExtension, 0n); - - expect(await this.mock.lateQuorumVoteExtension()).to.equal(0n); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorStorage.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorStorage.test.js deleted file mode 100644 index ef56fa53e4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorStorage.test.js +++ /dev/null @@ -1,155 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { anyValue } = require('@nomicfoundation/hardhat-chai-matchers/withArgs'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -const { GovernorHelper, timelockSalt } = require('../../helpers/governance'); -const { VoteType } = require('../../helpers/enums'); - -const TOKENS = [ - { Token: '$ERC20Votes', mode: 'blocknumber' }, - { Token: '$ERC20VotesTimestampMock', mode: 'timestamp' }, -]; - -const DEFAULT_ADMIN_ROLE = ethers.ZeroHash; -const PROPOSER_ROLE = ethers.id('PROPOSER_ROLE'); -const EXECUTOR_ROLE = ethers.id('EXECUTOR_ROLE'); -const CANCELLER_ROLE = ethers.id('CANCELLER_ROLE'); - -const name = 'OZ-Governor'; -const version = '1'; -const tokenName = 'MockToken'; -const tokenSymbol = 'MTKN'; -const tokenSupply = ethers.parseEther('100'); -const votingDelay = 4n; -const votingPeriod = 16n; -const value = ethers.parseEther('1'); -const delay = 3600n; - -describe('GovernorStorage', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - const [deployer, owner, proposer, voter1, voter2, voter3, voter4] = await ethers.getSigners(); - const receiver = await ethers.deployContract('CallReceiverMock'); - - const token = await ethers.deployContract(Token, [tokenName, tokenSymbol, version]); - const timelock = await ethers.deployContract('TimelockController', [delay, [], [], deployer]); - const mock = await ethers.deployContract('$GovernorStorageMock', [ - name, - votingDelay, - votingPeriod, - 0n, - timelock, - token, - 0n, - ]); - - await owner.sendTransaction({ to: timelock, value }); - await token.$_mint(owner, tokenSupply); - await timelock.grantRole(PROPOSER_ROLE, mock); - await timelock.grantRole(PROPOSER_ROLE, owner); - await timelock.grantRole(CANCELLER_ROLE, mock); - await timelock.grantRole(CANCELLER_ROLE, owner); - await timelock.grantRole(EXECUTOR_ROLE, ethers.ZeroAddress); - await timelock.revokeRole(DEFAULT_ADMIN_ROLE, deployer); - - const helper = new GovernorHelper(mock, mode); - await helper.connect(owner).delegate({ token, to: voter1, value: ethers.parseEther('10') }); - await helper.connect(owner).delegate({ token, to: voter2, value: ethers.parseEther('7') }); - await helper.connect(owner).delegate({ token, to: voter3, value: ethers.parseEther('5') }); - await helper.connect(owner).delegate({ token, to: voter4, value: ethers.parseEther('2') }); - - return { deployer, owner, proposer, voter1, voter2, voter3, voter4, receiver, token, timelock, mock, helper }; - }; - - describe(`using ${Token}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - // initiate fresh proposal - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - value, - }, - ], - '', - ); - this.proposal.timelockid = await this.timelock.hashOperationBatch( - ...this.proposal.shortProposal.slice(0, 3), - ethers.ZeroHash, - timelockSalt(this.mock.target, this.proposal.shortProposal[3]), - ); - }); - - describe('proposal indexing', function () { - it('before propose', async function () { - expect(await this.mock.proposalCount()).to.equal(0n); - - await expect(this.mock.proposalDetailsAt(0n)).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - - await expect(this.mock.proposalDetails(this.proposal.id)) - .to.be.revertedWithCustomError(this.mock, 'GovernorNonexistentProposal') - .withArgs(this.proposal.id); - }); - - it('after propose', async function () { - await this.helper.propose(); - - expect(await this.mock.proposalCount()).to.equal(1n); - - expect(await this.mock.proposalDetailsAt(0n)).to.deep.equal([ - this.proposal.id, - this.proposal.targets, - this.proposal.values, - this.proposal.data, - this.proposal.descriptionHash, - ]); - - expect(await this.mock.proposalDetails(this.proposal.id)).to.deep.equal([ - this.proposal.targets, - this.proposal.values, - this.proposal.data, - this.proposal.descriptionHash, - ]); - }); - }); - - it('queue and execute by id', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.connect(this.voter2).vote({ support: VoteType.For }); - await this.helper.connect(this.voter3).vote({ support: VoteType.Against }); - await this.helper.connect(this.voter4).vote({ support: VoteType.Abstain }); - await this.helper.waitForDeadline(); - - await expect(this.mock.queue(this.proposal.id)) - .to.emit(this.mock, 'ProposalQueued') - .withArgs(this.proposal.id, anyValue) - .to.emit(this.timelock, 'CallScheduled') - .withArgs(this.proposal.timelockid, ...Array(6).fill(anyValue)) - .to.emit(this.timelock, 'CallSalt') - .withArgs(this.proposal.timelockid, anyValue); - - await this.helper.waitForEta(); - - await expect(this.mock.execute(this.proposal.id)) - .to.emit(this.mock, 'ProposalExecuted') - .withArgs(this.proposal.id) - .to.emit(this.timelock, 'CallExecuted') - .withArgs(this.proposal.timelockid, ...Array(4).fill(anyValue)) - .to.emit(this.receiver, 'MockFunctionCalled'); - }); - - it('cancel by id', async function () { - await this.helper.connect(this.proposer).propose(); - await expect(this.mock.connect(this.proposer).cancel(this.proposal.id)) - .to.emit(this.mock, 'ProposalCanceled') - .withArgs(this.proposal.id); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorTimelockAccess.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorTimelockAccess.test.js deleted file mode 100644 index c3d3b32684..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorTimelockAccess.test.js +++ /dev/null @@ -1,864 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { anyValue } = require('@nomicfoundation/hardhat-chai-matchers/withArgs'); - -const { GovernorHelper } = require('../../helpers/governance'); -const { hashOperation } = require('../../helpers/access-manager'); -const { max } = require('../../helpers/math'); -const { selector } = require('../../helpers/methods'); -const { ProposalState, VoteType } = require('../../helpers/enums'); -const time = require('../../helpers/time'); - -function prepareOperation({ sender, target, value = 0n, data = '0x' }) { - return { - id: hashOperation(sender, target, data), - operation: { target, value, data }, - selector: data.slice(0, 10).padEnd(10, '0'), - }; -} - -const TOKENS = [ - { Token: '$ERC20Votes', mode: 'blocknumber' }, - { Token: '$ERC20VotesTimestampMock', mode: 'timestamp' }, -]; - -const name = 'OZ-Governor'; -const version = '1'; -const tokenName = 'MockToken'; -const tokenSymbol = 'MTKN'; -const tokenSupply = ethers.parseEther('100'); -const votingDelay = 4n; -const votingPeriod = 16n; -const value = ethers.parseEther('1'); - -describe('GovernorTimelockAccess', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - const [admin, voter1, voter2, voter3, voter4, other] = await ethers.getSigners(); - - const manager = await ethers.deployContract('$AccessManager', [admin]); - const receiver = await ethers.deployContract('$AccessManagedTarget', [manager]); - - const token = await ethers.deployContract(Token, [tokenName, tokenSymbol, version]); - const mock = await ethers.deployContract('$GovernorTimelockAccessMock', [ - name, - votingDelay, - votingPeriod, - 0n, - manager, - 0n, - token, - 0n, - ]); - - await admin.sendTransaction({ to: mock, value }); - await token.$_mint(admin, tokenSupply); - - const helper = new GovernorHelper(mock, mode); - await helper.connect(admin).delegate({ token, to: voter1, value: ethers.parseEther('10') }); - await helper.connect(admin).delegate({ token, to: voter2, value: ethers.parseEther('7') }); - await helper.connect(admin).delegate({ token, to: voter3, value: ethers.parseEther('5') }); - await helper.connect(admin).delegate({ token, to: voter4, value: ethers.parseEther('2') }); - - return { admin, voter1, voter2, voter3, voter4, other, manager, receiver, token, mock, helper }; - }; - - describe(`using ${Token}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - - // restricted proposal - this.restricted = prepareOperation({ - sender: this.mock.target, - target: this.receiver.target, - data: this.receiver.interface.encodeFunctionData('fnRestricted'), - }); - - this.unrestricted = prepareOperation({ - sender: this.mock.target, - target: this.receiver.target, - data: this.receiver.interface.encodeFunctionData('fnUnrestricted'), - }); - - this.fallback = prepareOperation({ - sender: this.mock.target, - target: this.receiver.target, - data: '0x1234', - }); - }); - - it('accepts ether transfers', async function () { - await this.admin.sendTransaction({ to: this.mock, value: 1n }); - }); - - it('post deployment check', async function () { - expect(await this.mock.name()).to.equal(name); - expect(await this.mock.token()).to.equal(this.token); - expect(await this.mock.votingDelay()).to.equal(votingDelay); - expect(await this.mock.votingPeriod()).to.equal(votingPeriod); - expect(await this.mock.quorum(0n)).to.equal(0n); - - expect(await this.mock.accessManager()).to.equal(this.manager); - }); - - it('sets base delay (seconds)', async function () { - const baseDelay = time.duration.hours(10n); - - // Only through governance - await expect(this.mock.connect(this.voter1).setBaseDelaySeconds(baseDelay)) - .to.be.revertedWithCustomError(this.mock, 'GovernorOnlyExecutor') - .withArgs(this.voter1); - - this.proposal = await this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('setBaseDelaySeconds', [baseDelay]), - }, - ], - 'descr', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.execute()).to.emit(this.mock, 'BaseDelaySet').withArgs(0n, baseDelay); - - expect(await this.mock.baseDelaySeconds()).to.equal(baseDelay); - }); - - it('sets access manager ignored', async function () { - const selectors = ['0x12345678', '0x87654321', '0xabcdef01']; - - // Only through governance - await expect(this.mock.connect(this.voter1).setAccessManagerIgnored(this.other, selectors, true)) - .to.be.revertedWithCustomError(this.mock, 'GovernorOnlyExecutor') - .withArgs(this.voter1); - - // Ignore - await this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('setAccessManagerIgnored', [ - this.other.address, - selectors, - true, - ]), - }, - ], - 'descr', - ); - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - const ignoreReceipt = this.helper.execute(); - for (const selector of selectors) { - await expect(ignoreReceipt) - .to.emit(this.mock, 'AccessManagerIgnoredSet') - .withArgs(this.other, selector, true); - expect(await this.mock.isAccessManagerIgnored(this.other, selector)).to.be.true; - } - - // Unignore - await this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('setAccessManagerIgnored', [ - this.other.address, - selectors, - false, - ]), - }, - ], - 'descr', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - const unignoreReceipt = this.helper.execute(); - for (const selector of selectors) { - await expect(unignoreReceipt) - .to.emit(this.mock, 'AccessManagerIgnoredSet') - .withArgs(this.other, selector, false); - expect(await this.mock.isAccessManagerIgnored(this.other, selector)).to.be.false; - } - }); - - it('sets access manager ignored when target is the governor', async function () { - const selectors = ['0x12345678', '0x87654321', '0xabcdef01']; - - await this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('setAccessManagerIgnored', [ - this.mock.target, - selectors, - true, - ]), - }, - ], - 'descr', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - const tx = this.helper.execute(); - for (const selector of selectors) { - await expect(tx).to.emit(this.mock, 'AccessManagerIgnoredSet').withArgs(this.mock, selector, true); - expect(await this.mock.isAccessManagerIgnored(this.mock, selector)).to.be.true; - } - }); - - it('does not need to queue proposals with no delay', async function () { - const roleId = 1n; - const executionDelay = 0n; - const baseDelay = 0n; - - // Set execution delay - await this.manager.connect(this.admin).setTargetFunctionRole(this.receiver, [this.restricted.selector], roleId); - await this.manager.connect(this.admin).grantRole(roleId, this.mock, executionDelay); - - // Set base delay - await this.mock.$_setBaseDelaySeconds(baseDelay); - - await this.helper.setProposal([this.restricted.operation], 'descr'); - await this.helper.propose(); - expect(await this.mock.proposalNeedsQueuing(this.helper.currentProposal.id)).to.be.false; - }); - - it('needs to queue proposals with any delay', async function () { - const roleId = 1n; - const delays = [ - [time.duration.hours(1n), time.duration.hours(2n)], - [time.duration.hours(2n), time.duration.hours(1n)], - ]; - - for (const [executionDelay, baseDelay] of delays) { - // Set execution delay - await this.manager - .connect(this.admin) - .setTargetFunctionRole(this.receiver, [this.restricted.selector], roleId); - await this.manager.connect(this.admin).grantRole(roleId, this.mock, executionDelay); - - // Set base delay - await this.mock.$_setBaseDelaySeconds(baseDelay); - - await this.helper.setProposal( - [this.restricted.operation], - `executionDelay=${executionDelay.toString()}}baseDelay=${baseDelay.toString()}}`, - ); - await this.helper.propose(); - expect(await this.mock.proposalNeedsQueuing(this.helper.currentProposal.id)).to.be.true; - } - }); - - describe('execution plan', function () { - it('returns plan for delayed operations', async function () { - const roleId = 1n; - const delays = [ - [time.duration.hours(1n), time.duration.hours(2n)], - [time.duration.hours(2n), time.duration.hours(1n)], - ]; - - for (const [executionDelay, baseDelay] of delays) { - // Set execution delay - await this.manager - .connect(this.admin) - .setTargetFunctionRole(this.receiver, [this.restricted.selector], roleId); - await this.manager.connect(this.admin).grantRole(roleId, this.mock, executionDelay); - - // Set base delay - await this.mock.$_setBaseDelaySeconds(baseDelay); - - this.proposal = await this.helper.setProposal( - [this.restricted.operation], - `executionDelay=${executionDelay.toString()}}baseDelay=${baseDelay.toString()}}`, - ); - await this.helper.propose(); - - expect(await this.mock.proposalExecutionPlan(this.proposal.id)).to.deep.equal([ - max(baseDelay, executionDelay), - [true], - [true], - ]); - } - }); - - it('returns plan for not delayed operations', async function () { - const roleId = 1n; - const executionDelay = 0n; - const baseDelay = 0n; - - // Set execution delay - await this.manager - .connect(this.admin) - .setTargetFunctionRole(this.receiver, [this.restricted.selector], roleId); - await this.manager.connect(this.admin).grantRole(roleId, this.mock, executionDelay); - - // Set base delay - await this.mock.$_setBaseDelaySeconds(baseDelay); - - this.proposal = await this.helper.setProposal([this.restricted.operation], `descr`); - await this.helper.propose(); - - expect(await this.mock.proposalExecutionPlan(this.proposal.id)).to.deep.equal([0n, [true], [false]]); - }); - - it('returns plan for an operation ignoring the manager', async function () { - await this.mock.$_setAccessManagerIgnored(this.receiver, this.restricted.selector, true); - - const roleId = 1n; - const delays = [ - [time.duration.hours(1n), time.duration.hours(2n)], - [time.duration.hours(2n), time.duration.hours(1n)], - ]; - - for (const [executionDelay, baseDelay] of delays) { - // Set execution delay - await this.manager - .connect(this.admin) - .setTargetFunctionRole(this.receiver, [this.restricted.selector], roleId); - await this.manager.connect(this.admin).grantRole(roleId, this.mock, executionDelay); - - // Set base delay - await this.mock.$_setBaseDelaySeconds(baseDelay); - - this.proposal = await this.helper.setProposal( - [this.restricted.operation], - `executionDelay=${executionDelay.toString()}}baseDelay=${baseDelay.toString()}}`, - ); - await this.helper.propose(); - - expect(await this.mock.proposalExecutionPlan(this.proposal.id)).to.deep.equal([ - baseDelay, - [false], - [false], - ]); - } - }); - }); - - describe('base delay only', function () { - for (const [delay, queue] of [ - [0, true], - [0, false], - [1000, true], - ]) { - it(`delay ${delay}, ${queue ? 'with' : 'without'} queuing`, async function () { - await this.mock.$_setBaseDelaySeconds(delay); - - this.proposal = await this.helper.setProposal([this.unrestricted.operation], 'descr'); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - if (await this.mock.proposalNeedsQueuing(this.proposal.id)) { - expect(await this.helper.queue()) - .to.emit(this.mock, 'ProposalQueued') - .withArgs(this.proposal.id, anyValue); - } - if (delay > 0) { - await this.helper.waitForEta(); - } - await expect(this.helper.execute()) - .to.emit(this.mock, 'ProposalExecuted') - .withArgs(this.proposal.id) - .to.emit(this.receiver, 'CalledUnrestricted'); - }); - } - }); - - it('reverts when an operation is executed before eta', async function () { - const delay = time.duration.hours(2n); - await this.mock.$_setBaseDelaySeconds(delay); - - this.proposal = await this.helper.setProposal([this.unrestricted.operation], 'descr'); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnmetDelay') - .withArgs(this.proposal.id, await this.mock.proposalEta(this.proposal.id)); - }); - - it('reverts with a proposal including multiple operations but one of those was cancelled in the manager', async function () { - const delay = time.duration.hours(2n); - const roleId = 1n; - - await this.manager.connect(this.admin).setTargetFunctionRole(this.receiver, [this.restricted.selector], roleId); - await this.manager.connect(this.admin).grantRole(roleId, this.mock, delay); - - // Set proposals - const original = new GovernorHelper(this.mock, mode); - await original.setProposal([this.restricted.operation, this.unrestricted.operation], 'descr'); - - // Go through all the governance process - await original.propose(); - await original.waitForSnapshot(); - await original.connect(this.voter1).vote({ support: VoteType.For }); - await original.waitForDeadline(); - await original.queue(); - await original.waitForEta(); - - // Suddenly cancel one of the proposed operations in the manager - await this.manager - .connect(this.admin) - .cancel(this.mock, this.restricted.operation.target, this.restricted.operation.data); - - // Reschedule the same operation in a different proposal to avoid "AccessManagerNotScheduled" error - const rescheduled = new GovernorHelper(this.mock, mode); - await rescheduled.setProposal([this.restricted.operation], 'descr'); - await rescheduled.propose(); - await rescheduled.waitForSnapshot(); - await rescheduled.connect(this.voter1).vote({ support: VoteType.For }); - await rescheduled.waitForDeadline(); - await rescheduled.queue(); // This will schedule it again in the manager - await rescheduled.waitForEta(); - - // Attempt to execute - await expect(original.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorMismatchedNonce') - .withArgs(original.currentProposal.id, 1, 2); - }); - - it('single operation with access manager delay', async function () { - const delay = 1000n; - const roleId = 1n; - - await this.manager.connect(this.admin).setTargetFunctionRole(this.receiver, [this.restricted.selector], roleId); - await this.manager.connect(this.admin).grantRole(roleId, this.mock, delay); - - this.proposal = await this.helper.setProposal([this.restricted.operation], 'descr'); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - const txQueue = await this.helper.queue(); - await this.helper.waitForEta(); - const txExecute = await this.helper.execute(); - - await expect(txQueue) - .to.emit(this.mock, 'ProposalQueued') - .withArgs(this.proposal.id, anyValue) - .to.emit(this.manager, 'OperationScheduled') - .withArgs( - this.restricted.id, - 1n, - (await time.clockFromReceipt.timestamp(txQueue)) + delay, - this.mock.target, - this.restricted.operation.target, - this.restricted.operation.data, - ); - - await expect(txExecute) - .to.emit(this.mock, 'ProposalExecuted') - .withArgs(this.proposal.id) - .to.emit(this.manager, 'OperationExecuted') - .withArgs(this.restricted.id, 1n) - .to.emit(this.receiver, 'CalledRestricted'); - }); - - it('bundle of varied operations', async function () { - const managerDelay = 1000n; - const roleId = 1n; - const baseDelay = managerDelay * 2n; - - await this.mock.$_setBaseDelaySeconds(baseDelay); - - await this.manager.connect(this.admin).setTargetFunctionRole(this.receiver, [this.restricted.selector], roleId); - await this.manager.connect(this.admin).grantRole(roleId, this.mock, managerDelay); - - this.proposal = await this.helper.setProposal( - [this.restricted.operation, this.unrestricted.operation, this.fallback.operation], - 'descr', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - const txQueue = await this.helper.queue(); - await this.helper.waitForEta(); - const txExecute = await this.helper.execute(); - - await expect(txQueue) - .to.emit(this.mock, 'ProposalQueued') - .withArgs(this.proposal.id, anyValue) - .to.emit(this.manager, 'OperationScheduled') - .withArgs( - this.restricted.id, - 1n, - (await time.clockFromReceipt.timestamp(txQueue)) + baseDelay, - this.mock.target, - this.restricted.operation.target, - this.restricted.operation.data, - ); - - await expect(txExecute) - .to.emit(this.mock, 'ProposalExecuted') - .withArgs(this.proposal.id) - .to.emit(this.manager, 'OperationExecuted') - .withArgs(this.restricted.id, 1n) - .to.emit(this.receiver, 'CalledRestricted') - .to.emit(this.receiver, 'CalledUnrestricted') - .to.emit(this.receiver, 'CalledFallback'); - }); - - describe('cancel', function () { - const delay = 1000n; - const roleId = 1n; - - beforeEach(async function () { - await this.manager - .connect(this.admin) - .setTargetFunctionRole(this.receiver, [this.restricted.selector], roleId); - await this.manager.connect(this.admin).grantRole(roleId, this.mock, delay); - }); - - it('cancels restricted with delay after queue (internal)', async function () { - this.proposal = await this.helper.setProposal([this.restricted.operation], 'descr'); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - - await expect(this.helper.cancel('internal')) - .to.emit(this.mock, 'ProposalCanceled') - .withArgs(this.proposal.id) - .to.emit(this.manager, 'OperationCanceled') - .withArgs(this.restricted.id, 1n); - - await this.helper.waitForEta(); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Canceled, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - it('cancels restricted with queueing if the same operation is part of a more recent proposal (internal)', async function () { - // Set proposals - const original = new GovernorHelper(this.mock, mode); - await original.setProposal([this.restricted.operation], 'descr'); - - // Go through all the governance process - await original.propose(); - await original.waitForSnapshot(); - await original.connect(this.voter1).vote({ support: VoteType.For }); - await original.waitForDeadline(); - await original.queue(); - - // Cancel the operation in the manager - await this.manager - .connect(this.admin) - .cancel(this.mock, this.restricted.operation.target, this.restricted.operation.data); - - // Another proposal is added with the same operation - const rescheduled = new GovernorHelper(this.mock, mode); - await rescheduled.setProposal([this.restricted.operation], 'another descr'); - - // Queue the new proposal - await rescheduled.propose(); - await rescheduled.waitForSnapshot(); - await rescheduled.connect(this.voter1).vote({ support: VoteType.For }); - await rescheduled.waitForDeadline(); - await rescheduled.queue(); // This will schedule it again in the manager - - // Cancel - const eta = await this.mock.proposalEta(rescheduled.currentProposal.id); - - await expect(original.cancel('internal')) - .to.emit(this.mock, 'ProposalCanceled') - .withArgs(original.currentProposal.id); - - await time.clock.timestamp().then(clock => time.increaseTo.timestamp(max(clock + 1n, eta))); - - await expect(original.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - original.currentProposal.id, - ProposalState.Canceled, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - it('cancels unrestricted with queueing (internal)', async function () { - this.proposal = await this.helper.setProposal([this.unrestricted.operation], 'descr'); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - - const eta = await this.mock.proposalEta(this.proposal.id); - - await expect(this.helper.cancel('internal')) - .to.emit(this.mock, 'ProposalCanceled') - .withArgs(this.proposal.id); - - await time.clock.timestamp().then(clock => time.increaseTo.timestamp(max(clock + 1n, eta))); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Canceled, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - it('cancels unrestricted without queueing (internal)', async function () { - this.proposal = await this.helper.setProposal([this.unrestricted.operation], 'descr'); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.cancel('internal')) - .to.emit(this.mock, 'ProposalCanceled') - .withArgs(this.proposal.id); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Canceled, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - it('cancels calls already canceled by guardian', async function () { - const operationA = { target: this.receiver.target, data: this.restricted.selector + '00' }; - const operationB = { target: this.receiver.target, data: this.restricted.selector + '01' }; - const operationC = { target: this.receiver.target, data: this.restricted.selector + '02' }; - const operationAId = hashOperation(this.mock.target, operationA.target, operationA.data); - const operationBId = hashOperation(this.mock.target, operationB.target, operationB.data); - - const proposal1 = new GovernorHelper(this.mock, mode); - const proposal2 = new GovernorHelper(this.mock, mode); - proposal1.setProposal([operationA, operationB], 'proposal A+B'); - proposal2.setProposal([operationA, operationC], 'proposal A+C'); - - for (const p of [proposal1, proposal2]) { - await p.propose(); - await p.waitForSnapshot(); - await p.connect(this.voter1).vote({ support: VoteType.For }); - await p.waitForDeadline(); - } - - // Can queue the first proposal - await proposal1.queue(); - - // Cannot queue the second proposal: operation A already scheduled with delay - await expect(proposal2.queue()) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerAlreadyScheduled') - .withArgs(operationAId); - - // Admin cancels operation B on the manager - await this.manager.connect(this.admin).cancel(this.mock, operationB.target, operationB.data); - - // Still cannot queue the second proposal: operation A already scheduled with delay - await expect(proposal2.queue()) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerAlreadyScheduled') - .withArgs(operationAId); - - await proposal1.waitForEta(); - - // Cannot execute first proposal: operation B has been canceled - await expect(proposal1.execute()) - .to.be.revertedWithCustomError(this.manager, 'AccessManagerNotScheduled') - .withArgs(operationBId); - - // Cancel the first proposal to release operation A - await proposal1.cancel('internal'); - - // can finally queue the second proposal - await proposal2.queue(); - - await proposal2.waitForEta(); - - // Can execute second proposal - await proposal2.execute(); - }); - }); - - describe('ignore AccessManager', function () { - it('defaults', async function () { - expect(await this.mock.isAccessManagerIgnored(this.receiver, this.restricted.selector)).to.be.false; - expect(await this.mock.isAccessManagerIgnored(this.mock, '0x12341234')).to.be.true; - }); - - it('internal setter', async function () { - await expect(this.mock.$_setAccessManagerIgnored(this.receiver, this.restricted.selector, true)) - .to.emit(this.mock, 'AccessManagerIgnoredSet') - .withArgs(this.receiver, this.restricted.selector, true); - - expect(await this.mock.isAccessManagerIgnored(this.receiver, this.restricted.selector)).to.be.true; - - await expect(this.mock.$_setAccessManagerIgnored(this.mock, '0x12341234', false)) - .to.emit(this.mock, 'AccessManagerIgnoredSet') - .withArgs(this.mock, '0x12341234', false); - - expect(await this.mock.isAccessManagerIgnored(this.mock, '0x12341234')).to.be.false; - }); - - it('external setter', async function () { - const setAccessManagerIgnored = (...args) => - this.mock.interface.encodeFunctionData('setAccessManagerIgnored', args); - - await this.helper.setProposal( - [ - { - target: this.mock.target, - data: setAccessManagerIgnored( - this.receiver.target, - [this.restricted.selector, this.unrestricted.selector], - true, - ), - }, - { - target: this.mock.target, - data: setAccessManagerIgnored(this.mock.target, ['0x12341234', '0x67896789'], false), - }, - ], - 'descr', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.execute()).to.emit(this.mock, 'AccessManagerIgnoredSet'); - - expect(await this.mock.isAccessManagerIgnored(this.receiver, this.restricted.selector)).to.be.true; - expect(await this.mock.isAccessManagerIgnored(this.receiver, this.unrestricted.selector)).to.be.true; - expect(await this.mock.isAccessManagerIgnored(this.mock, '0x12341234')).to.be.false; - expect(await this.mock.isAccessManagerIgnored(this.mock, '0x67896789')).to.be.false; - }); - - it('locked function', async function () { - const setAccessManagerIgnored = selector('setAccessManagerIgnored(address,bytes4[],bool)'); - - await expect( - this.mock.$_setAccessManagerIgnored(this.mock, setAccessManagerIgnored, true), - ).to.be.revertedWithCustomError(this.mock, 'GovernorLockedIgnore'); - - await this.mock.$_setAccessManagerIgnored(this.receiver, setAccessManagerIgnored, true); - }); - - it('ignores access manager', async function () { - const amount = 100n; - const target = this.token.target; - const data = this.token.interface.encodeFunctionData('transfer', [this.voter4.address, amount]); - const selector = data.slice(0, 10); - await this.token.$_mint(this.mock, amount); - - const roleId = 1n; - await this.manager.connect(this.admin).setTargetFunctionRole(target, [selector], roleId); - await this.manager.connect(this.admin).grantRole(roleId, this.mock, 0); - - await this.helper.setProposal([{ target, data }], 'descr #1'); - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.token, 'ERC20InsufficientBalance') - .withArgs(this.manager, 0n, amount); - - await this.mock.$_setAccessManagerIgnored(target, selector, true); - - await this.helper.setProposal([{ target, data }], 'descr #2'); - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.execute()).to.emit(this.token, 'Transfer').withArgs(this.mock, this.voter4, amount); - }); - }); - - describe('operating on an Ownable contract', function () { - const method = selector('$_checkOwner()'); - - beforeEach(async function () { - this.ownable = await ethers.deployContract('$Ownable', [this.manager]); - this.operation = { - target: this.ownable.target, - data: this.ownable.interface.encodeFunctionData('$_checkOwner'), - }; - }); - - it('succeeds with delay', async function () { - const roleId = 1n; - const executionDelay = time.duration.hours(2n); - const baseDelay = time.duration.hours(1n); - - // Set execution delay - await this.manager.connect(this.admin).setTargetFunctionRole(this.ownable, [method], roleId); - await this.manager.connect(this.admin).grantRole(roleId, this.mock, executionDelay); - - // Set base delay - await this.mock.$_setBaseDelaySeconds(baseDelay); - - await this.helper.setProposal([this.operation], `descr`); - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await this.helper.waitForEta(); - await this.helper.execute(); // Don't revert - }); - - it('succeeds without delay', async function () { - const roleId = 1n; - const executionDelay = 0n; - const baseDelay = 0n; - - // Set execution delay - await this.manager.connect(this.admin).setTargetFunctionRole(this.ownable, [method], roleId); - await this.manager.connect(this.admin).grantRole(roleId, this.mock, executionDelay); - - // Set base delay - await this.mock.$_setBaseDelaySeconds(baseDelay); - - await this.helper.setProposal([this.operation], `descr`); - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.execute(); // Don't revert - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorTimelockCompound.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorTimelockCompound.test.js deleted file mode 100644 index 545bf359d3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorTimelockCompound.test.js +++ /dev/null @@ -1,448 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { anyValue } = require('@nomicfoundation/hardhat-chai-matchers/withArgs'); - -const { GovernorHelper } = require('../../helpers/governance'); -const { ProposalState, VoteType } = require('../../helpers/enums'); -const time = require('../../helpers/time'); - -const TOKENS = [ - { Token: '$ERC20Votes', mode: 'blocknumber' }, - { Token: '$ERC20VotesTimestampMock', mode: 'timestamp' }, -]; - -const name = 'OZ-Governor'; -const version = '1'; -const tokenName = 'MockToken'; -const tokenSymbol = 'MTKN'; -const tokenSupply = ethers.parseEther('100'); -const votingDelay = 4n; -const votingPeriod = 16n; -const value = ethers.parseEther('1'); -const defaultDelay = time.duration.days(2n); - -describe('GovernorTimelockCompound', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - const [deployer, owner, voter1, voter2, voter3, voter4, other] = await ethers.getSigners(); - const receiver = await ethers.deployContract('CallReceiverMock'); - - const token = await ethers.deployContract(Token, [tokenName, tokenSymbol, version]); - const predictGovernor = await deployer - .getNonce() - .then(nonce => ethers.getCreateAddress({ from: deployer.address, nonce: nonce + 1 })); - const timelock = await ethers.deployContract('CompTimelock', [predictGovernor, defaultDelay]); - const mock = await ethers.deployContract('$GovernorTimelockCompoundMock', [ - name, - votingDelay, - votingPeriod, - 0n, - timelock, - token, - 0n, - ]); - - await owner.sendTransaction({ to: timelock, value }); - await token.$_mint(owner, tokenSupply); - - const helper = new GovernorHelper(mock, mode); - await helper.connect(owner).delegate({ token, to: voter1, value: ethers.parseEther('10') }); - await helper.connect(owner).delegate({ token, to: voter2, value: ethers.parseEther('7') }); - await helper.connect(owner).delegate({ token, to: voter3, value: ethers.parseEther('5') }); - await helper.connect(owner).delegate({ token, to: voter4, value: ethers.parseEther('2') }); - - return { deployer, owner, voter1, voter2, voter3, voter4, other, receiver, token, mock, timelock, helper }; - }; - - describe(`using ${Token}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - - // default proposal - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - value, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - }, - ], - '', - ); - }); - - it("doesn't accept ether transfers", async function () { - await expect(this.owner.sendTransaction({ to: this.mock, value: 1n })).to.be.revertedWithCustomError( - this.mock, - 'GovernorDisabledDeposit', - ); - }); - - it('post deployment check', async function () { - expect(await this.mock.name()).to.equal(name); - expect(await this.mock.token()).to.equal(this.token); - expect(await this.mock.votingDelay()).to.equal(votingDelay); - expect(await this.mock.votingPeriod()).to.equal(votingPeriod); - expect(await this.mock.quorum(0n)).to.equal(0n); - - expect(await this.mock.timelock()).to.equal(this.timelock); - expect(await this.timelock.admin()).to.equal(this.mock); - }); - - it('nominal', async function () { - expect(await this.mock.proposalEta(this.proposal.id)).to.equal(0n); - expect(await this.mock.proposalNeedsQueuing(this.proposal.id)).to.be.true; - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.connect(this.voter2).vote({ support: VoteType.For }); - await this.helper.connect(this.voter3).vote({ support: VoteType.Against }); - await this.helper.connect(this.voter4).vote({ support: VoteType.Abstain }); - await this.helper.waitForDeadline(); - const txQueue = await this.helper.queue(); - - const eta = (await time.clockFromReceipt.timestamp(txQueue)) + defaultDelay; - expect(await this.mock.proposalEta(this.proposal.id)).to.equal(eta); - expect(await this.mock.proposalNeedsQueuing(this.proposal.id)).to.be.true; - - await this.helper.waitForEta(); - const txExecute = await this.helper.execute(); - - await expect(txQueue) - .to.emit(this.mock, 'ProposalQueued') - .withArgs(this.proposal.id, eta) - .to.emit(this.timelock, 'QueueTransaction') - .withArgs(...Array(5).fill(anyValue), eta); - - await expect(txExecute) - .to.emit(this.mock, 'ProposalExecuted') - .withArgs(this.proposal.id) - .to.emit(this.timelock, 'ExecuteTransaction') - .withArgs(...Array(5).fill(anyValue), eta) - .to.emit(this.receiver, 'MockFunctionCalled'); - }); - - describe('should revert', function () { - describe('on queue', function () { - it('if already queued', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await expect(this.helper.queue()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Queued, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded]), - ); - }); - - it('if proposal contains duplicate calls', async function () { - const action = { - target: this.token.target, - data: this.token.interface.encodeFunctionData('approve', [this.receiver.target, ethers.MaxUint256]), - }; - const { id } = this.helper.setProposal([action, action], ''); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await expect(this.helper.queue()) - .to.be.revertedWithCustomError(this.mock, 'GovernorAlreadyQueuedProposal') - .withArgs(id); - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorNotQueuedProposal') - .withArgs(id); - }); - }); - - describe('on execute', function () { - it('if not queued', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(1n); - - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Succeeded); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorNotQueuedProposal') - .withArgs(this.proposal.id); - }); - - it('if too early', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Queued); - - await expect(this.helper.execute()).to.be.rejectedWith( - "Timelock::executeTransaction: Transaction hasn't surpassed time lock", - ); - }); - - it('if too late', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await this.helper.waitForEta(time.duration.days(30)); - - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Expired); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Expired, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - it('if already executed', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await this.helper.waitForEta(); - await this.helper.execute(); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Executed, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - }); - - describe('on safe receive', function () { - describe('ERC721', function () { - const tokenId = 1n; - - beforeEach(async function () { - this.token = await ethers.deployContract('$ERC721', ['Non Fungible Token', 'NFT']); - await this.token.$_mint(this.owner, tokenId); - }); - - it("can't receive an ERC721 safeTransfer", async function () { - await expect( - this.token.connect(this.owner).safeTransferFrom(this.owner, this.mock, tokenId), - ).to.be.revertedWithCustomError(this.mock, 'GovernorDisabledDeposit'); - }); - }); - - describe('ERC1155', function () { - const tokenIds = { - 1: 1000n, - 2: 2000n, - 3: 3000n, - }; - - beforeEach(async function () { - this.token = await ethers.deployContract('$ERC1155', ['https://token-cdn-domain/{id}.json']); - await this.token.$_mintBatch(this.owner, Object.keys(tokenIds), Object.values(tokenIds), '0x'); - }); - - it("can't receive ERC1155 safeTransfer", async function () { - await expect( - this.token.connect(this.owner).safeTransferFrom( - this.owner, - this.mock, - ...Object.entries(tokenIds)[0], // id + amount - '0x', - ), - ).to.be.revertedWithCustomError(this.mock, 'GovernorDisabledDeposit'); - }); - - it("can't receive ERC1155 safeBatchTransfer", async function () { - await expect( - this.token - .connect(this.owner) - .safeBatchTransferFrom(this.owner, this.mock, Object.keys(tokenIds), Object.values(tokenIds), '0x'), - ).to.be.revertedWithCustomError(this.mock, 'GovernorDisabledDeposit'); - }); - }); - }); - }); - - describe('cancel', function () { - it('cancel before queue prevents scheduling', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.cancel('internal')) - .to.emit(this.mock, 'ProposalCanceled') - .withArgs(this.proposal.id); - - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Canceled); - - await expect(this.helper.queue()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Canceled, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded]), - ); - }); - - it('cancel after queue prevents executing', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - - await expect(this.helper.cancel('internal')) - .to.emit(this.mock, 'ProposalCanceled') - .withArgs(this.proposal.id); - - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Canceled); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Canceled, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - }); - - describe('onlyGovernance', function () { - describe('relay', function () { - beforeEach(async function () { - await this.token.$_mint(this.mock, 1); - }); - - it('is protected', async function () { - await expect( - this.mock - .connect(this.owner) - .relay(this.token, 0, this.token.interface.encodeFunctionData('transfer', [this.other.address, 1n])), - ) - .to.be.revertedWithCustomError(this.mock, 'GovernorOnlyExecutor') - .withArgs(this.owner); - }); - - it('can be executed through governance', async function () { - this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('relay', [ - this.token.target, - 0n, - this.token.interface.encodeFunctionData('transfer', [this.other.address, 1n]), - ]), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await this.helper.waitForEta(); - - const txExecute = this.helper.execute(); - - await expect(txExecute).to.changeTokenBalances(this.token, [this.mock, this.other], [-1n, 1n]); - - await expect(txExecute).to.emit(this.token, 'Transfer').withArgs(this.mock, this.other, 1n); - }); - }); - - describe('updateTimelock', function () { - beforeEach(async function () { - this.newTimelock = await ethers.deployContract('CompTimelock', [this.mock, time.duration.days(7n)]); - }); - - it('is protected', async function () { - await expect(this.mock.connect(this.owner).updateTimelock(this.newTimelock)) - .to.be.revertedWithCustomError(this.mock, 'GovernorOnlyExecutor') - .withArgs(this.owner); - }); - - it('can be executed through governance to', async function () { - this.helper.setProposal( - [ - { - target: this.timelock.target, - data: this.timelock.interface.encodeFunctionData('setPendingAdmin', [this.owner.address]), - }, - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('updateTimelock', [this.newTimelock.target]), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await this.helper.waitForEta(); - - await expect(this.helper.execute()) - .to.emit(this.mock, 'TimelockChange') - .withArgs(this.timelock, this.newTimelock); - - expect(await this.mock.timelock()).to.equal(this.newTimelock); - }); - }); - - it('can transfer timelock to new governor', async function () { - const newGovernor = await ethers.deployContract('$GovernorTimelockCompoundMock', [ - name, - 8n, - 32n, - 0n, - this.timelock, - this.token, - 0n, - ]); - - this.helper.setProposal( - [ - { - target: this.timelock.target, - data: this.timelock.interface.encodeFunctionData('setPendingAdmin', [newGovernor.target]), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await this.helper.waitForEta(); - - await expect(this.helper.execute()).to.emit(this.timelock, 'NewPendingAdmin').withArgs(newGovernor); - - await newGovernor.__acceptAdmin(); - expect(await this.timelock.admin()).to.equal(newGovernor); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorTimelockControl.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorTimelockControl.test.js deleted file mode 100644 index c1156a5099..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorTimelockControl.test.js +++ /dev/null @@ -1,504 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { anyValue } = require('@nomicfoundation/hardhat-chai-matchers/withArgs'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -const { GovernorHelper, timelockSalt } = require('../../helpers/governance'); -const { OperationState, ProposalState, VoteType } = require('../../helpers/enums'); -const time = require('../../helpers/time'); - -const TOKENS = [ - { Token: '$ERC20Votes', mode: 'blocknumber' }, - { Token: '$ERC20VotesTimestampMock', mode: 'timestamp' }, -]; - -const DEFAULT_ADMIN_ROLE = ethers.ZeroHash; -const PROPOSER_ROLE = ethers.id('PROPOSER_ROLE'); -const EXECUTOR_ROLE = ethers.id('EXECUTOR_ROLE'); -const CANCELLER_ROLE = ethers.id('CANCELLER_ROLE'); - -const name = 'OZ-Governor'; -const version = '1'; -const tokenName = 'MockToken'; -const tokenSymbol = 'MTKN'; -const tokenSupply = ethers.parseEther('100'); -const votingDelay = 4n; -const votingPeriod = 16n; -const value = ethers.parseEther('1'); -const delay = time.duration.hours(1n); - -describe('GovernorTimelockControl', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - const [deployer, owner, voter1, voter2, voter3, voter4, other] = await ethers.getSigners(); - const receiver = await ethers.deployContract('CallReceiverMock'); - - const token = await ethers.deployContract(Token, [tokenName, tokenSymbol, version]); - const timelock = await ethers.deployContract('TimelockController', [delay, [], [], deployer]); - const mock = await ethers.deployContract('$GovernorTimelockControlMock', [ - name, - votingDelay, - votingPeriod, - 0n, - timelock, - token, - 0n, - ]); - - await owner.sendTransaction({ to: timelock, value }); - await token.$_mint(owner, tokenSupply); - await timelock.grantRole(PROPOSER_ROLE, mock); - await timelock.grantRole(PROPOSER_ROLE, owner); - await timelock.grantRole(CANCELLER_ROLE, mock); - await timelock.grantRole(CANCELLER_ROLE, owner); - await timelock.grantRole(EXECUTOR_ROLE, ethers.ZeroAddress); - await timelock.revokeRole(DEFAULT_ADMIN_ROLE, deployer); - - const helper = new GovernorHelper(mock, mode); - await helper.connect(owner).delegate({ token, to: voter1, value: ethers.parseEther('10') }); - await helper.connect(owner).delegate({ token, to: voter2, value: ethers.parseEther('7') }); - await helper.connect(owner).delegate({ token, to: voter3, value: ethers.parseEther('5') }); - await helper.connect(owner).delegate({ token, to: voter4, value: ethers.parseEther('2') }); - - return { deployer, owner, voter1, voter2, voter3, voter4, other, receiver, token, mock, timelock, helper }; - }; - - describe(`using ${Token}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - - // default proposal - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - value, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - }, - ], - '', - ); - - this.proposal.timelockid = await this.timelock.hashOperationBatch( - ...this.proposal.shortProposal.slice(0, 3), - ethers.ZeroHash, - timelockSalt(this.mock.target, this.proposal.shortProposal[3]), - ); - }); - - it("doesn't accept ether transfers", async function () { - await expect(this.owner.sendTransaction({ to: this.mock, value: 1n })).to.be.revertedWithCustomError( - this.mock, - 'GovernorDisabledDeposit', - ); - }); - - it('post deployment check', async function () { - expect(await this.mock.name()).to.equal(name); - expect(await this.mock.token()).to.equal(this.token); - expect(await this.mock.votingDelay()).to.equal(votingDelay); - expect(await this.mock.votingPeriod()).to.equal(votingPeriod); - expect(await this.mock.quorum(0n)).to.equal(0n); - - expect(await this.mock.timelock()).to.equal(this.timelock); - }); - - it('nominal', async function () { - expect(await this.mock.proposalEta(this.proposal.id)).to.equal(0n); - expect(await this.mock.proposalNeedsQueuing(this.proposal.id)).to.be.true; - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.connect(this.voter2).vote({ support: VoteType.For }); - await this.helper.connect(this.voter3).vote({ support: VoteType.Against }); - await this.helper.connect(this.voter4).vote({ support: VoteType.Abstain }); - await this.helper.waitForDeadline(); - - expect(await this.mock.proposalNeedsQueuing(this.proposal.id)).to.be.true; - const txQueue = await this.helper.queue(); - - const eta = (await time.clockFromReceipt.timestamp(txQueue)) + delay; - expect(await this.mock.proposalEta(this.proposal.id)).to.equal(eta); - await this.helper.waitForEta(); - - const txExecute = this.helper.execute(); - - await expect(txQueue) - .to.emit(this.mock, 'ProposalQueued') - .withArgs(this.proposal.id, anyValue) - .to.emit(this.timelock, 'CallScheduled') - .withArgs(this.proposal.timelockid, ...Array(6).fill(anyValue)) - .to.emit(this.timelock, 'CallSalt') - .withArgs(this.proposal.timelockid, anyValue); - - await expect(txExecute) - .to.emit(this.mock, 'ProposalExecuted') - .withArgs(this.proposal.id) - .to.emit(this.timelock, 'CallExecuted') - .withArgs(this.proposal.timelockid, ...Array(4).fill(anyValue)) - .to.emit(this.receiver, 'MockFunctionCalled'); - }); - - describe('should revert', function () { - describe('on queue', function () { - it('if already queued', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await expect(this.helper.queue()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Queued, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded]), - ); - }); - }); - - describe('on execute', function () { - it('if not queued', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(1n); - - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Succeeded); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.timelock, 'TimelockUnexpectedOperationState') - .withArgs(this.proposal.timelockid, GovernorHelper.proposalStatesToBitMap(OperationState.Ready)); - }); - - it('if too early', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Queued); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.timelock, 'TimelockUnexpectedOperationState') - .withArgs(this.proposal.timelockid, GovernorHelper.proposalStatesToBitMap(OperationState.Ready)); - }); - - it('if already executed', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await this.helper.waitForEta(); - await this.helper.execute(); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Executed, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - it('if already executed by another proposer', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await this.helper.waitForEta(); - - await this.timelock.executeBatch( - ...this.proposal.shortProposal.slice(0, 3), - ethers.ZeroHash, - timelockSalt(this.mock.target, this.proposal.shortProposal[3]), - ); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Executed, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - }); - }); - - describe('cancel', function () { - it('cancel before queue prevents scheduling', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.cancel('internal')) - .to.emit(this.mock, 'ProposalCanceled') - .withArgs(this.proposal.id); - - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Canceled); - - await expect(this.helper.queue()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Canceled, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded]), - ); - }); - - it('cancel after queue prevents executing', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - - await expect(this.helper.cancel('internal')) - .to.emit(this.mock, 'ProposalCanceled') - .withArgs(this.proposal.id); - - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Canceled); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Canceled, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - it('cancel on timelock is reflected on governor', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Queued); - - await expect(this.timelock.connect(this.owner).cancel(this.proposal.timelockid)) - .to.emit(this.timelock, 'Cancelled') - .withArgs(this.proposal.timelockid); - - expect(await this.mock.state(this.proposal.id)).to.equal(ProposalState.Canceled); - }); - }); - - describe('onlyGovernance', function () { - describe('relay', function () { - beforeEach(async function () { - await this.token.$_mint(this.mock, 1); - }); - - it('is protected', async function () { - await expect( - this.mock - .connect(this.owner) - .relay(this.token, 0n, this.token.interface.encodeFunctionData('transfer', [this.other.address, 1n])), - ) - .to.be.revertedWithCustomError(this.mock, 'GovernorOnlyExecutor') - .withArgs(this.owner); - }); - - it('can be executed through governance', async function () { - this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('relay', [ - this.token.target, - 0n, - this.token.interface.encodeFunctionData('transfer', [this.other.address, 1n]), - ]), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await this.helper.waitForEta(); - - const txExecute = await this.helper.execute(); - - await expect(txExecute).to.changeTokenBalances(this.token, [this.mock, this.other], [-1n, 1n]); - - await expect(txExecute).to.emit(this.token, 'Transfer').withArgs(this.mock, this.other, 1n); - }); - - it('is payable and can transfer eth to EOA', async function () { - const t2g = 128n; // timelock to governor - const g2o = 100n; // governor to eoa (other) - - this.helper.setProposal( - [ - { - target: this.mock.target, - value: t2g, - data: this.mock.interface.encodeFunctionData('relay', [this.other.address, g2o, '0x']), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await this.helper.waitForEta(); - - await expect(this.helper.execute()).to.changeEtherBalances( - [this.timelock, this.mock, this.other], - [-t2g, t2g - g2o, g2o], - ); - }); - - it('protected against other proposers', async function () { - const call = [ - this.mock, - 0n, - this.mock.interface.encodeFunctionData('relay', [ethers.ZeroAddress, 0n, '0x']), - ethers.ZeroHash, - ethers.ZeroHash, - ]; - - await this.timelock.connect(this.owner).schedule(...call, delay); - - await time.increaseBy.timestamp(delay); - - // Error bubbled up from Governor - await expect(this.timelock.connect(this.owner).execute(...call)).to.be.revertedWithPanic( - PANIC_CODES.POP_ON_EMPTY_ARRAY, - ); - }); - }); - - describe('updateTimelock', function () { - beforeEach(async function () { - this.newTimelock = await ethers.deployContract('TimelockController', [ - delay, - [this.mock], - [this.mock], - ethers.ZeroAddress, - ]); - }); - - it('is protected', async function () { - await expect(this.mock.connect(this.owner).updateTimelock(this.newTimelock)) - .to.be.revertedWithCustomError(this.mock, 'GovernorOnlyExecutor') - .withArgs(this.owner); - }); - - it('can be executed through governance to', async function () { - this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('updateTimelock', [this.newTimelock.target]), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await this.helper.waitForEta(); - - await expect(this.helper.execute()) - .to.emit(this.mock, 'TimelockChange') - .withArgs(this.timelock, this.newTimelock); - - expect(await this.mock.timelock()).to.equal(this.newTimelock); - }); - }); - - describe('on safe receive', function () { - describe('ERC721', function () { - const tokenId = 1n; - - beforeEach(async function () { - this.token = await ethers.deployContract('$ERC721', ['Non Fungible Token', 'NFT']); - await this.token.$_mint(this.owner, tokenId); - }); - - it("can't receive an ERC721 safeTransfer", async function () { - await expect( - this.token.connect(this.owner).safeTransferFrom(this.owner, this.mock, tokenId), - ).to.be.revertedWithCustomError(this.mock, 'GovernorDisabledDeposit'); - }); - }); - - describe('ERC1155', function () { - const tokenIds = { - 1: 1000n, - 2: 2000n, - 3: 3000n, - }; - - beforeEach(async function () { - this.token = await ethers.deployContract('$ERC1155', ['https://token-cdn-domain/{id}.json']); - await this.token.$_mintBatch(this.owner, Object.keys(tokenIds), Object.values(tokenIds), '0x'); - }); - - it("can't receive ERC1155 safeTransfer", async function () { - await expect( - this.token.connect(this.owner).safeTransferFrom( - this.owner, - this.mock, - ...Object.entries(tokenIds)[0], // id + amount - '0x', - ), - ).to.be.revertedWithCustomError(this.mock, 'GovernorDisabledDeposit'); - }); - - it("can't receive ERC1155 safeBatchTransfer", async function () { - await expect( - this.token - .connect(this.owner) - .safeBatchTransferFrom(this.owner, this.mock, Object.keys(tokenIds), Object.values(tokenIds), '0x'), - ).to.be.revertedWithCustomError(this.mock, 'GovernorDisabledDeposit'); - }); - }); - }); - }); - - it('clear queue of pending governor calls', async function () { - this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('nonGovernanceFunction'), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.queue(); - await this.helper.waitForEta(); - await this.helper.execute(); - - // This path clears _governanceCall as part of the afterExecute call, - // but we have not way to check that the cleanup actually happened other - // then coverage reports. - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorVotesQuorumFraction.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorVotesQuorumFraction.test.js deleted file mode 100644 index 368e396f92..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorVotesQuorumFraction.test.js +++ /dev/null @@ -1,165 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture, mine } = require('@nomicfoundation/hardhat-network-helpers'); - -const { GovernorHelper } = require('../../helpers/governance'); -const { ProposalState, VoteType } = require('../../helpers/enums'); -const time = require('../../helpers/time'); - -const TOKENS = [ - { Token: '$ERC20Votes', mode: 'blocknumber' }, - { Token: '$ERC20VotesTimestampMock', mode: 'timestamp' }, -]; - -const name = 'OZ-Governor'; -const version = '1'; -const tokenName = 'MockToken'; -const tokenSymbol = 'MTKN'; -const tokenSupply = ethers.parseEther('100'); -const ratio = 8n; // percents -const newRatio = 6n; // percents -const votingDelay = 4n; -const votingPeriod = 16n; -const value = ethers.parseEther('1'); - -describe('GovernorVotesQuorumFraction', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - const [owner, voter1, voter2, voter3, voter4] = await ethers.getSigners(); - - const receiver = await ethers.deployContract('CallReceiverMock'); - - const token = await ethers.deployContract(Token, [tokenName, tokenSymbol, version]); - const mock = await ethers.deployContract('$GovernorMock', [name, votingDelay, votingPeriod, 0n, token, ratio]); - - await owner.sendTransaction({ to: mock, value }); - await token.$_mint(owner, tokenSupply); - - const helper = new GovernorHelper(mock, mode); - await helper.connect(owner).delegate({ token, to: voter1, value: ethers.parseEther('10') }); - await helper.connect(owner).delegate({ token, to: voter2, value: ethers.parseEther('7') }); - await helper.connect(owner).delegate({ token, to: voter3, value: ethers.parseEther('5') }); - await helper.connect(owner).delegate({ token, to: voter4, value: ethers.parseEther('2') }); - - return { owner, voter1, voter2, voter3, voter4, receiver, token, mock, helper }; - }; - - describe(`using ${Token}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - - // default proposal - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - value, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - }, - ], - '', - ); - }); - - it('deployment check', async function () { - expect(await this.mock.name()).to.equal(name); - expect(await this.mock.token()).to.equal(this.token); - expect(await this.mock.votingDelay()).to.equal(votingDelay); - expect(await this.mock.votingPeriod()).to.equal(votingPeriod); - expect(await this.mock.quorum(0)).to.equal(0n); - expect(await this.mock.quorumNumerator()).to.equal(ratio); - expect(await this.mock.quorumDenominator()).to.equal(100n); - expect(await time.clock[mode]().then(clock => this.mock.quorum(clock - 1n))).to.equal( - (tokenSupply * ratio) / 100n, - ); - }); - - it('quorum reached', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await this.helper.execute(); - }); - - it('quorum not reached', async function () { - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter2).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorUnexpectedProposalState') - .withArgs( - this.proposal.id, - ProposalState.Defeated, - GovernorHelper.proposalStatesToBitMap([ProposalState.Succeeded, ProposalState.Queued]), - ); - }); - - describe('onlyGovernance updates', function () { - it('updateQuorumNumerator is protected', async function () { - await expect(this.mock.connect(this.owner).updateQuorumNumerator(newRatio)) - .to.be.revertedWithCustomError(this.mock, 'GovernorOnlyExecutor') - .withArgs(this.owner); - }); - - it('can updateQuorumNumerator through governance', async function () { - this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('updateQuorumNumerator', [newRatio]), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - await expect(this.helper.execute()).to.emit(this.mock, 'QuorumNumeratorUpdated').withArgs(ratio, newRatio); - - expect(await this.mock.quorumNumerator()).to.equal(newRatio); - expect(await this.mock.quorumDenominator()).to.equal(100n); - - // it takes one block for the new quorum to take effect - expect(await time.clock[mode]().then(blockNumber => this.mock.quorum(blockNumber - 1n))).to.equal( - (tokenSupply * ratio) / 100n, - ); - - await mine(); - - expect(await time.clock[mode]().then(blockNumber => this.mock.quorum(blockNumber - 1n))).to.equal( - (tokenSupply * newRatio) / 100n, - ); - }); - - it('cannot updateQuorumNumerator over the maximum', async function () { - const quorumNumerator = 101n; - this.helper.setProposal( - [ - { - target: this.mock.target, - data: this.mock.interface.encodeFunctionData('updateQuorumNumerator', [quorumNumerator]), - }, - ], - '', - ); - - await this.helper.propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For }); - await this.helper.waitForDeadline(); - - const quorumDenominator = await this.mock.quorumDenominator(); - - await expect(this.helper.execute()) - .to.be.revertedWithCustomError(this.mock, 'GovernorInvalidQuorumFraction') - .withArgs(quorumNumerator, quorumDenominator); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorWithParams.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorWithParams.test.js deleted file mode 100644 index 37e15f5c2d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/extensions/GovernorWithParams.test.js +++ /dev/null @@ -1,245 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { GovernorHelper } = require('../../helpers/governance'); -const { VoteType } = require('../../helpers/enums'); -const { getDomain, ExtendedBallot } = require('../../helpers/eip712'); - -const TOKENS = [ - { Token: '$ERC20Votes', mode: 'blocknumber' }, - { Token: '$ERC20VotesTimestampMock', mode: 'timestamp' }, -]; - -const name = 'OZ-Governor'; -const version = '1'; -const tokenName = 'MockToken'; -const tokenSymbol = 'MTKN'; -const tokenSupply = ethers.parseEther('100'); -const votingDelay = 4n; -const votingPeriod = 16n; -const value = ethers.parseEther('1'); - -const params = { - decoded: [42n, 'These are my params'], - encoded: ethers.AbiCoder.defaultAbiCoder().encode(['uint256', 'string'], [42n, 'These are my params']), -}; - -describe('GovernorWithParams', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - const [owner, proposer, voter1, voter2, voter3, voter4, other] = await ethers.getSigners(); - const receiver = await ethers.deployContract('CallReceiverMock'); - - const token = await ethers.deployContract(Token, [tokenName, tokenSymbol, version]); - const mock = await ethers.deployContract('$GovernorWithParamsMock', [name, token]); - - await owner.sendTransaction({ to: mock, value }); - await token.$_mint(owner, tokenSupply); - - const helper = new GovernorHelper(mock, mode); - await helper.connect(owner).delegate({ token, to: voter1, value: ethers.parseEther('10') }); - await helper.connect(owner).delegate({ token, to: voter2, value: ethers.parseEther('7') }); - await helper.connect(owner).delegate({ token, to: voter3, value: ethers.parseEther('5') }); - await helper.connect(owner).delegate({ token, to: voter4, value: ethers.parseEther('2') }); - - return { owner, proposer, voter1, voter2, voter3, voter4, other, receiver, token, mock, helper }; - }; - - describe(`using ${Token}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - - // default proposal - this.proposal = this.helper.setProposal( - [ - { - target: this.receiver.target, - value, - data: this.receiver.interface.encodeFunctionData('mockFunction'), - }, - ], - '', - ); - }); - - it('deployment check', async function () { - expect(await this.mock.name()).to.equal(name); - expect(await this.mock.token()).to.equal(this.token); - expect(await this.mock.votingDelay()).to.equal(votingDelay); - expect(await this.mock.votingPeriod()).to.equal(votingPeriod); - }); - - it('nominal is unaffected', async function () { - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - await this.helper.connect(this.voter1).vote({ support: VoteType.For, reason: 'This is nice' }); - await this.helper.connect(this.voter2).vote({ support: VoteType.For }); - await this.helper.connect(this.voter3).vote({ support: VoteType.Against }); - await this.helper.connect(this.voter4).vote({ support: VoteType.Abstain }); - await this.helper.waitForDeadline(); - await this.helper.execute(); - - expect(await this.mock.hasVoted(this.proposal.id, this.owner)).to.be.false; - expect(await this.mock.hasVoted(this.proposal.id, this.voter1)).to.be.true; - expect(await this.mock.hasVoted(this.proposal.id, this.voter2)).to.be.true; - expect(await ethers.provider.getBalance(this.mock)).to.equal(0n); - expect(await ethers.provider.getBalance(this.receiver)).to.equal(value); - }); - - it('Voting with params is properly supported', async function () { - await this.helper.connect(this.proposer).propose(); - await this.helper.waitForSnapshot(); - - const weight = ethers.parseEther('7') - params.decoded[0]; - - await expect( - this.helper.connect(this.voter2).vote({ - support: VoteType.For, - reason: 'no particular reason', - params: params.encoded, - }), - ) - .to.emit(this.mock, 'CountParams') - .withArgs(...params.decoded) - .to.emit(this.mock, 'VoteCastWithParams') - .withArgs( - this.voter2.address, - this.proposal.id, - VoteType.For, - weight, - 'no particular reason', - params.encoded, - ); - - expect(await this.mock.proposalVotes(this.proposal.id)).to.deep.equal([0n, weight, 0n]); - }); - - describe('voting by signature', function () { - it('supports EOA signatures', async function () { - await this.token.connect(this.voter2).delegate(this.other); - - // Run proposal - await this.helper.propose(); - await this.helper.waitForSnapshot(); - - // Prepare vote - const weight = ethers.parseEther('7') - params.decoded[0]; - const nonce = await this.mock.nonces(this.other); - const data = { - proposalId: this.proposal.id, - support: VoteType.For, - voter: this.other.address, - nonce, - reason: 'no particular reason', - params: params.encoded, - signature: (contract, message) => - getDomain(contract).then(domain => this.other.signTypedData(domain, { ExtendedBallot }, message)), - }; - - // Vote - await expect(this.helper.vote(data)) - .to.emit(this.mock, 'CountParams') - .withArgs(...params.decoded) - .to.emit(this.mock, 'VoteCastWithParams') - .withArgs(data.voter, data.proposalId, data.support, weight, data.reason, data.params); - - expect(await this.mock.proposalVotes(this.proposal.id)).to.deep.equal([0n, weight, 0n]); - expect(await this.mock.nonces(this.other)).to.equal(nonce + 1n); - }); - - it('supports EIP-1271 signature signatures', async function () { - const wallet = await ethers.deployContract('ERC1271WalletMock', [this.other]); - await this.token.connect(this.voter2).delegate(wallet); - - // Run proposal - await this.helper.propose(); - await this.helper.waitForSnapshot(); - - // Prepare vote - const weight = ethers.parseEther('7') - params.decoded[0]; - const nonce = await this.mock.nonces(this.other); - const data = { - proposalId: this.proposal.id, - support: VoteType.For, - voter: wallet.target, - nonce, - reason: 'no particular reason', - params: params.encoded, - signature: (contract, message) => - getDomain(contract).then(domain => this.other.signTypedData(domain, { ExtendedBallot }, message)), - }; - - // Vote - await expect(this.helper.vote(data)) - .to.emit(this.mock, 'CountParams') - .withArgs(...params.decoded) - .to.emit(this.mock, 'VoteCastWithParams') - .withArgs(data.voter, data.proposalId, data.support, weight, data.reason, data.params); - - expect(await this.mock.proposalVotes(this.proposal.id)).to.deep.equal([0n, weight, 0n]); - expect(await this.mock.nonces(wallet)).to.equal(nonce + 1n); - }); - - it('reverts if signature does not match signer', async function () { - await this.token.connect(this.voter2).delegate(this.other); - - // Run proposal - await this.helper.propose(); - await this.helper.waitForSnapshot(); - - // Prepare vote - const nonce = await this.mock.nonces(this.other); - const data = { - proposalId: this.proposal.id, - support: VoteType.For, - voter: this.other.address, - nonce, - reason: 'no particular reason', - params: params.encoded, - // tampered signature - signature: (contract, message) => - getDomain(contract) - .then(domain => this.other.signTypedData(domain, { ExtendedBallot }, message)) - .then(signature => { - const tamperedSig = ethers.toBeArray(signature); - tamperedSig[42] ^= 0xff; - return ethers.hexlify(tamperedSig); - }), - }; - - // Vote - await expect(this.helper.vote(data)) - .to.be.revertedWithCustomError(this.mock, 'GovernorInvalidSignature') - .withArgs(data.voter); - }); - - it('reverts if vote nonce is incorrect', async function () { - await this.token.connect(this.voter2).delegate(this.other); - - // Run proposal - await this.helper.propose(); - await this.helper.waitForSnapshot(); - - // Prepare vote - const nonce = await this.mock.nonces(this.other); - const data = { - proposalId: this.proposal.id, - support: VoteType.For, - voter: this.other.address, - nonce: nonce + 1n, - reason: 'no particular reason', - params: params.encoded, - signature: (contract, message) => - getDomain(contract).then(domain => this.other.signTypedData(domain, { ExtendedBallot }, message)), - }; - - // Vote - await expect(this.helper.vote(data)) - .to.be.revertedWithCustomError(this.mock, 'GovernorInvalidSignature') - .withArgs(data.voter); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/utils/ERC6372.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/utils/ERC6372.behavior.js deleted file mode 100644 index 32f27b59a7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/utils/ERC6372.behavior.js +++ /dev/null @@ -1,28 +0,0 @@ -const { expect } = require('chai'); -const time = require('../../helpers/time'); - -function shouldBehaveLikeERC6372(mode = 'blocknumber') { - describe(`ERC-6372 behavior in ${mode} mode`, function () { - beforeEach(async function () { - this.mock = this.mock ?? this.token ?? this.votes; - }); - - it('should have a correct clock value', async function () { - const currentClock = await this.mock.clock(); - const expectedClock = await time.clock[mode](); - expect(currentClock).to.equal(expectedClock, `Clock mismatch in ${mode} mode`); - }); - - it('should have the correct CLOCK_MODE parameters', async function () { - const clockModeParams = new URLSearchParams(await this.mock.CLOCK_MODE()); - const expectedFromValue = mode === 'blocknumber' ? 'default' : null; - - expect(clockModeParams.get('mode')).to.equal(mode, `Expected mode to be ${mode}`); - expect(clockModeParams.get('from')).to.equal(expectedFromValue, `Expected 'from' to be ${expectedFromValue}`); - }); - }); -} - -module.exports = { - shouldBehaveLikeERC6372, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/utils/Votes.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/utils/Votes.behavior.js deleted file mode 100644 index 099770132d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/utils/Votes.behavior.js +++ /dev/null @@ -1,325 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { mine } = require('@nomicfoundation/hardhat-network-helpers'); - -const { getDomain, Delegation } = require('../../helpers/eip712'); -const time = require('../../helpers/time'); - -const { shouldBehaveLikeERC6372 } = require('./ERC6372.behavior'); - -function shouldBehaveLikeVotes(tokens, { mode = 'blocknumber', fungible = true }) { - beforeEach(async function () { - [this.delegator, this.delegatee, this.alice, this.bob, this.other] = this.accounts; - this.domain = await getDomain(this.votes); - }); - - shouldBehaveLikeERC6372(mode); - - const getWeight = token => (fungible ? token : 1n); - - describe('run votes workflow', function () { - it('initial nonce is 0', async function () { - expect(await this.votes.nonces(this.alice)).to.equal(0n); - }); - - describe('delegation with signature', function () { - const token = tokens[0]; - - it('delegation without tokens', async function () { - expect(await this.votes.delegates(this.alice)).to.equal(ethers.ZeroAddress); - - await expect(this.votes.connect(this.alice).delegate(this.alice)) - .to.emit(this.votes, 'DelegateChanged') - .withArgs(this.alice, ethers.ZeroAddress, this.alice) - .to.not.emit(this.votes, 'DelegateVotesChanged'); - - expect(await this.votes.delegates(this.alice)).to.equal(this.alice); - }); - - it('delegation with tokens', async function () { - await this.votes.$_mint(this.alice, token); - const weight = getWeight(token); - - expect(await this.votes.delegates(this.alice)).to.equal(ethers.ZeroAddress); - - const tx = await this.votes.connect(this.alice).delegate(this.alice); - const timepoint = await time.clockFromReceipt[mode](tx); - - await expect(tx) - .to.emit(this.votes, 'DelegateChanged') - .withArgs(this.alice, ethers.ZeroAddress, this.alice) - .to.emit(this.votes, 'DelegateVotesChanged') - .withArgs(this.alice, 0n, weight); - - expect(await this.votes.delegates(this.alice)).to.equal(this.alice); - expect(await this.votes.getVotes(this.alice)).to.equal(weight); - expect(await this.votes.getPastVotes(this.alice, timepoint - 1n)).to.equal(0n); - await mine(); - expect(await this.votes.getPastVotes(this.alice, timepoint)).to.equal(weight); - }); - - it('delegation update', async function () { - await this.votes.connect(this.alice).delegate(this.alice); - await this.votes.$_mint(this.alice, token); - const weight = getWeight(token); - - expect(await this.votes.delegates(this.alice)).to.equal(this.alice); - expect(await this.votes.getVotes(this.alice)).to.equal(weight); - expect(await this.votes.getVotes(this.bob)).to.equal(0); - - const tx = await this.votes.connect(this.alice).delegate(this.bob); - const timepoint = await time.clockFromReceipt[mode](tx); - - await expect(tx) - .to.emit(this.votes, 'DelegateChanged') - .withArgs(this.alice, this.alice, this.bob) - .to.emit(this.votes, 'DelegateVotesChanged') - .withArgs(this.alice, weight, 0) - .to.emit(this.votes, 'DelegateVotesChanged') - .withArgs(this.bob, 0, weight); - - expect(await this.votes.delegates(this.alice)).to.equal(this.bob); - expect(await this.votes.getVotes(this.alice)).to.equal(0n); - expect(await this.votes.getVotes(this.bob)).to.equal(weight); - - expect(await this.votes.getPastVotes(this.alice, timepoint - 1n)).to.equal(weight); - expect(await this.votes.getPastVotes(this.bob, timepoint - 1n)).to.equal(0n); - await mine(); - expect(await this.votes.getPastVotes(this.alice, timepoint)).to.equal(0n); - expect(await this.votes.getPastVotes(this.bob, timepoint)).to.equal(weight); - }); - - describe('with signature', function () { - const nonce = 0n; - - it('accept signed delegation', async function () { - await this.votes.$_mint(this.delegator, token); - const weight = getWeight(token); - - const { r, s, v } = await this.delegator - .signTypedData( - this.domain, - { Delegation }, - { - delegatee: this.delegatee.address, - nonce, - expiry: ethers.MaxUint256, - }, - ) - .then(ethers.Signature.from); - - expect(await this.votes.delegates(this.delegator)).to.equal(ethers.ZeroAddress); - - const tx = await this.votes.delegateBySig(this.delegatee, nonce, ethers.MaxUint256, v, r, s); - const timepoint = await time.clockFromReceipt[mode](tx); - - await expect(tx) - .to.emit(this.votes, 'DelegateChanged') - .withArgs(this.delegator, ethers.ZeroAddress, this.delegatee) - .to.emit(this.votes, 'DelegateVotesChanged') - .withArgs(this.delegatee, 0, weight); - - expect(await this.votes.delegates(this.delegator.address)).to.equal(this.delegatee); - expect(await this.votes.getVotes(this.delegator.address)).to.equal(0n); - expect(await this.votes.getVotes(this.delegatee)).to.equal(weight); - expect(await this.votes.getPastVotes(this.delegatee, timepoint - 1n)).to.equal(0n); - await mine(); - expect(await this.votes.getPastVotes(this.delegatee, timepoint)).to.equal(weight); - }); - - it('rejects reused signature', async function () { - const { r, s, v } = await this.delegator - .signTypedData( - this.domain, - { Delegation }, - { - delegatee: this.delegatee.address, - nonce, - expiry: ethers.MaxUint256, - }, - ) - .then(ethers.Signature.from); - - await this.votes.delegateBySig(this.delegatee, nonce, ethers.MaxUint256, v, r, s); - - await expect(this.votes.delegateBySig(this.delegatee, nonce, ethers.MaxUint256, v, r, s)) - .to.be.revertedWithCustomError(this.votes, 'InvalidAccountNonce') - .withArgs(this.delegator, nonce + 1n); - }); - - it('rejects bad delegatee', async function () { - const { r, s, v } = await this.delegator - .signTypedData( - this.domain, - { Delegation }, - { - delegatee: this.delegatee.address, - nonce, - expiry: ethers.MaxUint256, - }, - ) - .then(ethers.Signature.from); - - const tx = await this.votes.delegateBySig(this.other, nonce, ethers.MaxUint256, v, r, s); - const receipt = await tx.wait(); - - const [delegateChanged] = receipt.logs.filter( - log => this.votes.interface.parseLog(log)?.name === 'DelegateChanged', - ); - const { args } = this.votes.interface.parseLog(delegateChanged); - expect(args.delegator).to.not.be.equal(this.delegator); - expect(args.fromDelegate).to.equal(ethers.ZeroAddress); - expect(args.toDelegate).to.equal(this.other); - }); - - it('rejects bad nonce', async function () { - const { r, s, v } = await this.delegator - .signTypedData( - this.domain, - { Delegation }, - { - delegatee: this.delegatee.address, - nonce: nonce + 1n, - expiry: ethers.MaxUint256, - }, - ) - .then(ethers.Signature.from); - - await expect(this.votes.delegateBySig(this.delegatee, nonce + 1n, ethers.MaxUint256, v, r, s)) - .to.be.revertedWithCustomError(this.votes, 'InvalidAccountNonce') - .withArgs(this.delegator, 0); - }); - - it('rejects expired permit', async function () { - const expiry = (await time.clock.timestamp()) - 1n; - const { r, s, v } = await this.delegator - .signTypedData( - this.domain, - { Delegation }, - { - delegatee: this.delegatee.address, - nonce, - expiry, - }, - ) - .then(ethers.Signature.from); - - await expect(this.votes.delegateBySig(this.delegatee, nonce, expiry, v, r, s)) - .to.be.revertedWithCustomError(this.votes, 'VotesExpiredSignature') - .withArgs(expiry); - }); - }); - }); - - describe('getPastTotalSupply', function () { - beforeEach(async function () { - await this.votes.connect(this.alice).delegate(this.alice); - }); - - it('reverts if block number >= current block', async function () { - const timepoint = 5e10; - const clock = await this.votes.clock(); - await expect(this.votes.getPastTotalSupply(timepoint)) - .to.be.revertedWithCustomError(this.votes, 'ERC5805FutureLookup') - .withArgs(timepoint, clock); - }); - - it('returns 0 if there are no checkpoints', async function () { - expect(await this.votes.getPastTotalSupply(0n)).to.equal(0n); - }); - - it('returns the correct checkpointed total supply', async function () { - const weight = tokens.map(token => getWeight(token)); - - // t0 = mint #0 - const t0 = await this.votes.$_mint(this.alice, tokens[0]); - await mine(); - // t1 = mint #1 - const t1 = await this.votes.$_mint(this.alice, tokens[1]); - await mine(); - // t2 = burn #1 - const t2 = await this.votes.$_burn(...(fungible ? [this.alice] : []), tokens[1]); - await mine(); - // t3 = mint #2 - const t3 = await this.votes.$_mint(this.alice, tokens[2]); - await mine(); - // t4 = burn #0 - const t4 = await this.votes.$_burn(...(fungible ? [this.alice] : []), tokens[0]); - await mine(); - // t5 = burn #2 - const t5 = await this.votes.$_burn(...(fungible ? [this.alice] : []), tokens[2]); - await mine(); - - t0.timepoint = await time.clockFromReceipt[mode](t0); - t1.timepoint = await time.clockFromReceipt[mode](t1); - t2.timepoint = await time.clockFromReceipt[mode](t2); - t3.timepoint = await time.clockFromReceipt[mode](t3); - t4.timepoint = await time.clockFromReceipt[mode](t4); - t5.timepoint = await time.clockFromReceipt[mode](t5); - - expect(await this.votes.getPastTotalSupply(t0.timepoint - 1n)).to.equal(0); - expect(await this.votes.getPastTotalSupply(t0.timepoint)).to.equal(weight[0]); - expect(await this.votes.getPastTotalSupply(t0.timepoint + 1n)).to.equal(weight[0]); - expect(await this.votes.getPastTotalSupply(t1.timepoint)).to.equal(weight[0] + weight[1]); - expect(await this.votes.getPastTotalSupply(t1.timepoint + 1n)).to.equal(weight[0] + weight[1]); - expect(await this.votes.getPastTotalSupply(t2.timepoint)).to.equal(weight[0]); - expect(await this.votes.getPastTotalSupply(t2.timepoint + 1n)).to.equal(weight[0]); - expect(await this.votes.getPastTotalSupply(t3.timepoint)).to.equal(weight[0] + weight[2]); - expect(await this.votes.getPastTotalSupply(t3.timepoint + 1n)).to.equal(weight[0] + weight[2]); - expect(await this.votes.getPastTotalSupply(t4.timepoint)).to.equal(weight[2]); - expect(await this.votes.getPastTotalSupply(t4.timepoint + 1n)).to.equal(weight[2]); - expect(await this.votes.getPastTotalSupply(t5.timepoint)).to.equal(0); - await expect(this.votes.getPastTotalSupply(t5.timepoint + 1n)) - .to.be.revertedWithCustomError(this.votes, 'ERC5805FutureLookup') - .withArgs(t5.timepoint + 1n, t5.timepoint + 1n); - }); - }); - - // The following tests are an adaptation of - // https://github.com/compound-finance/compound-protocol/blob/master/tests/Governance/CompTest.js. - describe('Compound test suite', function () { - beforeEach(async function () { - await this.votes.$_mint(this.alice, tokens[0]); - await this.votes.$_mint(this.alice, tokens[1]); - await this.votes.$_mint(this.alice, tokens[2]); - }); - - describe('getPastVotes', function () { - it('reverts if block number >= current block', async function () { - const clock = await this.votes.clock(); - const timepoint = 5e10; // far in the future - await expect(this.votes.getPastVotes(this.bob, timepoint)) - .to.be.revertedWithCustomError(this.votes, 'ERC5805FutureLookup') - .withArgs(timepoint, clock); - }); - - it('returns 0 if there are no checkpoints', async function () { - expect(await this.votes.getPastVotes(this.bob, 0n)).to.equal(0n); - }); - - it('returns the latest block if >= last checkpoint block', async function () { - const delegate = await this.votes.connect(this.alice).delegate(this.bob); - const timepoint = await time.clockFromReceipt[mode](delegate); - await mine(2); - - const latest = await this.votes.getVotes(this.bob); - expect(await this.votes.getPastVotes(this.bob, timepoint)).to.equal(latest); - expect(await this.votes.getPastVotes(this.bob, timepoint + 1n)).to.equal(latest); - }); - - it('returns zero if < first checkpoint block', async function () { - await mine(); - const delegate = await this.votes.connect(this.alice).delegate(this.bob); - const timepoint = await time.clockFromReceipt[mode](delegate); - await mine(2); - - expect(await this.votes.getPastVotes(this.bob, timepoint - 1n)).to.equal(0n); - }); - }); - }); - }); -} - -module.exports = { - shouldBehaveLikeVotes, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/utils/Votes.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/utils/Votes.test.js deleted file mode 100644 index 7acacfc666..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/utils/Votes.test.js +++ /dev/null @@ -1,102 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { sum } = require('../../helpers/math'); -const { zip } = require('../../helpers/iterate'); -const time = require('../../helpers/time'); - -const { shouldBehaveLikeVotes } = require('./Votes.behavior'); - -const MODES = { - blocknumber: '$VotesMock', - timestamp: '$VotesTimestampMock', -}; - -const AMOUNTS = [ethers.parseEther('10000000'), 10n, 20n]; - -describe('Votes', function () { - for (const [mode, artifact] of Object.entries(MODES)) { - const fixture = async () => { - const accounts = await ethers.getSigners(); - - const amounts = Object.fromEntries( - zip( - accounts.slice(0, AMOUNTS.length).map(({ address }) => address), - AMOUNTS, - ), - ); - - const name = 'My Vote'; - const version = '1'; - const votes = await ethers.deployContract(artifact, [name, version]); - - return { accounts, amounts, votes, name, version }; - }; - - describe(`vote with ${mode}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeVotes(AMOUNTS, { mode, fungible: true }); - - it('starts with zero votes', async function () { - expect(await this.votes.getTotalSupply()).to.equal(0n); - }); - - describe('performs voting operations', function () { - beforeEach(async function () { - this.txs = []; - for (const [account, amount] of Object.entries(this.amounts)) { - this.txs.push(await this.votes.$_mint(account, amount)); - } - }); - - it('reverts if block number >= current block', async function () { - const lastTxTimepoint = await time.clockFromReceipt[mode](this.txs.at(-1)); - const clock = await this.votes.clock(); - await expect(this.votes.getPastTotalSupply(lastTxTimepoint)) - .to.be.revertedWithCustomError(this.votes, 'ERC5805FutureLookup') - .withArgs(lastTxTimepoint, clock); - }); - - it('delegates', async function () { - expect(await this.votes.getVotes(this.accounts[0])).to.equal(0n); - expect(await this.votes.getVotes(this.accounts[1])).to.equal(0n); - expect(await this.votes.delegates(this.accounts[0])).to.equal(ethers.ZeroAddress); - expect(await this.votes.delegates(this.accounts[1])).to.equal(ethers.ZeroAddress); - - await this.votes.delegate(this.accounts[0], ethers.Typed.address(this.accounts[0])); - - expect(await this.votes.getVotes(this.accounts[0])).to.equal(this.amounts[this.accounts[0].address]); - expect(await this.votes.getVotes(this.accounts[1])).to.equal(0n); - expect(await this.votes.delegates(this.accounts[0])).to.equal(this.accounts[0]); - expect(await this.votes.delegates(this.accounts[1])).to.equal(ethers.ZeroAddress); - - await this.votes.delegate(this.accounts[1], ethers.Typed.address(this.accounts[0])); - - expect(await this.votes.getVotes(this.accounts[0])).to.equal( - this.amounts[this.accounts[0].address] + this.amounts[this.accounts[1].address], - ); - expect(await this.votes.getVotes(this.accounts[1])).to.equal(0n); - expect(await this.votes.delegates(this.accounts[0])).to.equal(this.accounts[0]); - expect(await this.votes.delegates(this.accounts[1])).to.equal(this.accounts[0]); - }); - - it('cross delegates', async function () { - await this.votes.delegate(this.accounts[0], ethers.Typed.address(this.accounts[1])); - await this.votes.delegate(this.accounts[1], ethers.Typed.address(this.accounts[0])); - - expect(await this.votes.getVotes(this.accounts[0])).to.equal(this.amounts[this.accounts[1].address]); - expect(await this.votes.getVotes(this.accounts[1])).to.equal(this.amounts[this.accounts[0].address]); - }); - - it('returns total amount of votes', async function () { - const totalSupply = sum(...Object.values(this.amounts)); - expect(await this.votes.getTotalSupply()).to.equal(totalSupply); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/utils/VotesExtended.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/utils/VotesExtended.test.js deleted file mode 100644 index 4a66ef2748..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/governance/utils/VotesExtended.test.js +++ /dev/null @@ -1,152 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture, mine } = require('@nomicfoundation/hardhat-network-helpers'); - -const { sum } = require('../../helpers/math'); -const { zip } = require('../../helpers/iterate'); -const time = require('../../helpers/time'); - -const { shouldBehaveLikeVotes } = require('./Votes.behavior'); - -const MODES = { - blocknumber: '$VotesExtendedMock', - timestamp: '$VotesExtendedTimestampMock', -}; - -const AMOUNTS = [ethers.parseEther('10000000'), 10n, 20n]; - -describe('VotesExtended', function () { - for (const [mode, artifact] of Object.entries(MODES)) { - const fixture = async () => { - const accounts = await ethers.getSigners(); - - const amounts = Object.fromEntries( - zip( - accounts.slice(0, AMOUNTS.length).map(({ address }) => address), - AMOUNTS, - ), - ); - - const name = 'Override Votes'; - const version = '1'; - const votes = await ethers.deployContract(artifact, [name, version]); - - return { accounts, amounts, votes, name, version }; - }; - - describe(`vote with ${mode}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeVotes(AMOUNTS, { mode, fungible: true }); - - it('starts with zero votes', async function () { - expect(await this.votes.getTotalSupply()).to.equal(0n); - }); - - describe('performs voting operations', function () { - beforeEach(async function () { - this.txs = []; - for (const [account, amount] of Object.entries(this.amounts)) { - this.txs.push(await this.votes.$_mint(account, amount)); - } - }); - - it('reverts if block number >= current block', async function () { - const lastTxTimepoint = await time.clockFromReceipt[mode](this.txs.at(-1)); - const clock = await this.votes.clock(); - await expect(this.votes.getPastTotalSupply(lastTxTimepoint)) - .to.be.revertedWithCustomError(this.votes, 'ERC5805FutureLookup') - .withArgs(lastTxTimepoint, clock); - }); - - it('delegates', async function () { - expect(await this.votes.getVotes(this.accounts[0])).to.equal(0n); - expect(await this.votes.getVotes(this.accounts[1])).to.equal(0n); - expect(await this.votes.delegates(this.accounts[0])).to.equal(ethers.ZeroAddress); - expect(await this.votes.delegates(this.accounts[1])).to.equal(ethers.ZeroAddress); - - await this.votes.delegate(this.accounts[0], ethers.Typed.address(this.accounts[0])); - - expect(await this.votes.getVotes(this.accounts[0])).to.equal(this.amounts[this.accounts[0].address]); - expect(await this.votes.getVotes(this.accounts[1])).to.equal(0n); - expect(await this.votes.delegates(this.accounts[0])).to.equal(this.accounts[0]); - expect(await this.votes.delegates(this.accounts[1])).to.equal(ethers.ZeroAddress); - - await this.votes.delegate(this.accounts[1], ethers.Typed.address(this.accounts[0])); - - expect(await this.votes.getVotes(this.accounts[0])).to.equal( - this.amounts[this.accounts[0].address] + this.amounts[this.accounts[1].address], - ); - expect(await this.votes.getVotes(this.accounts[1])).to.equal(0n); - expect(await this.votes.delegates(this.accounts[0])).to.equal(this.accounts[0]); - expect(await this.votes.delegates(this.accounts[1])).to.equal(this.accounts[0]); - }); - - it('cross delegates', async function () { - await this.votes.delegate(this.accounts[0], ethers.Typed.address(this.accounts[1])); - await this.votes.delegate(this.accounts[1], ethers.Typed.address(this.accounts[0])); - - expect(await this.votes.getVotes(this.accounts[0])).to.equal(this.amounts[this.accounts[1].address]); - expect(await this.votes.getVotes(this.accounts[1])).to.equal(this.amounts[this.accounts[0].address]); - }); - - it('returns total amount of votes', async function () { - const totalSupply = sum(...Object.values(this.amounts)); - expect(await this.votes.getTotalSupply()).to.equal(totalSupply); - }); - }); - }); - - describe(`checkpoint delegates with ${mode}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('checkpoint delegates', async function () { - const tx = await this.votes.delegate(this.accounts[0], ethers.Typed.address(this.accounts[1])); - const timepoint = await time.clockFromReceipt[mode](tx); - await mine(2); - - expect(await this.votes.getPastDelegate(this.accounts[0], timepoint - 1n)).to.equal(ethers.ZeroAddress); - expect(await this.votes.getPastDelegate(this.accounts[0], timepoint)).to.equal(this.accounts[1].address); - expect(await this.votes.getPastDelegate(this.accounts[0], timepoint + 1n)).to.equal(this.accounts[1].address); - }); - - it('reverts if current timepoint <= timepoint', async function () { - const tx = await this.votes.delegate(this.accounts[0], ethers.Typed.address(this.accounts[1])); - const timepoint = await time.clockFromReceipt[mode](tx); - - await expect(this.votes.getPastDelegate(this.accounts[0], timepoint + 1n)) - .to.be.revertedWithCustomError(this.votes, 'ERC5805FutureLookup') - .withArgs(timepoint + 1n, timepoint); - }); - }); - - describe(`checkpoint balances with ${mode}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('checkpoint balances', async function () { - const tx = await this.votes.$_mint(this.accounts[0].address, 100n); - const timepoint = await time.clockFromReceipt[mode](tx); - await mine(2); - - expect(await this.votes.getPastBalanceOf(this.accounts[0].address, timepoint - 1n)).to.equal(0n); - expect(await this.votes.getPastBalanceOf(this.accounts[0].address, timepoint)).to.equal(100n); - expect(await this.votes.getPastBalanceOf(this.accounts[0].address, timepoint + 1n)).to.equal(100n); - }); - - it('reverts if current timepoint <= timepoint', async function () { - const tx = await this.votes.$_mint(this.accounts[0].address, 100n); - const timepoint = await time.clockFromReceipt[mode](tx); - - await expect(this.votes.getPastBalanceOf(this.accounts[0], timepoint + 1n)) - .to.be.revertedWithCustomError(this.votes, 'ERC5805FutureLookup') - .withArgs(timepoint + 1n, timepoint); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/access-manager.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/access-manager.js deleted file mode 100644 index 3b8343059c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/access-manager.js +++ /dev/null @@ -1,85 +0,0 @@ -const { ethers } = require('hardhat'); - -const { MAX_UINT64 } = require('./constants'); -const time = require('./time'); -const { upgradeableSlot } = require('./storage'); - -function buildBaseRoles() { - const roles = { - ADMIN: { - id: 0n, - }, - SOME_ADMIN: { - id: 17n, - }, - SOME_GUARDIAN: { - id: 35n, - }, - SOME: { - id: 42n, - }, - PUBLIC: { - id: MAX_UINT64, - }, - }; - - // Names - Object.entries(roles).forEach(([name, role]) => (role.name = name)); - - // Defaults - for (const role of Object.keys(roles)) { - roles[role].admin = roles.ADMIN; - roles[role].guardian = roles.ADMIN; - } - - // Admins - roles.SOME.admin = roles.SOME_ADMIN; - - // Guardians - roles.SOME.guardian = roles.SOME_GUARDIAN; - - return roles; -} - -const formatAccess = access => [access[0], access[1].toString()]; - -const MINSETBACK = time.duration.days(5); -const EXPIRATION = time.duration.weeks(1); - -const EXECUTION_ID_STORAGE_SLOT = upgradeableSlot('AccessManager', 3n); -const CONSUMING_SCHEDULE_STORAGE_SLOT = upgradeableSlot('AccessManaged', 0n); - -/** - * @requires this.{manager, caller, target, calldata} - */ -async function prepareOperation(manager, { caller, target, calldata, delay }) { - const scheduledAt = (await time.clock.timestamp()) + 1n; - await time.increaseTo.timestamp(scheduledAt, false); // Fix next block timestamp for predictability - - return { - schedule: () => manager.connect(caller).schedule(target, calldata, scheduledAt + delay), - scheduledAt, - operationId: hashOperation(caller, target, calldata), - }; -} - -const lazyGetAddress = addressable => addressable.address ?? addressable.target ?? addressable; - -const hashOperation = (caller, target, data) => - ethers.keccak256( - ethers.AbiCoder.defaultAbiCoder().encode( - ['address', 'address', 'bytes'], - [lazyGetAddress(caller), lazyGetAddress(target), data], - ), - ); - -module.exports = { - buildBaseRoles, - formatAccess, - MINSETBACK, - EXPIRATION, - EXECUTION_ID_STORAGE_SLOT, - CONSUMING_SCHEDULE_STORAGE_SLOT, - prepareOperation, - hashOperation, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/account.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/account.js deleted file mode 100644 index 96874b16b7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/account.js +++ /dev/null @@ -1,14 +0,0 @@ -const { ethers } = require('hardhat'); -const { impersonateAccount, setBalance } = require('@nomicfoundation/hardhat-network-helpers'); - -// Hardhat default balance -const DEFAULT_BALANCE = 10000n * ethers.WeiPerEther; - -const impersonate = (account, balance = DEFAULT_BALANCE) => - impersonateAccount(account) - .then(() => setBalance(account, balance)) - .then(() => ethers.getSigner(account)); - -module.exports = { - impersonate, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/chains.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/chains.js deleted file mode 100644 index 3711a81258..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/chains.js +++ /dev/null @@ -1,109 +0,0 @@ -// NOTE: this file defines some examples of CAIP-2 and CAIP-10 identifiers. -// The following listing does not pretend to be exhaustive or even accurate. It SHOULD NOT be used in production. - -const { ethers } = require('hardhat'); -const { mapValues } = require('./iterate'); - -// EVM (https://axelarscan.io/resources/chains?type=evm) -const ethereum = { - Ethereum: '1', - optimism: '10', - binance: '56', - Polygon: '137', - Fantom: '250', - fraxtal: '252', - filecoin: '314', - Moonbeam: '1284', - centrifuge: '2031', - kava: '2222', - mantle: '5000', - base: '8453', - immutable: '13371', - arbitrum: '42161', - celo: '42220', - Avalanche: '43114', - linea: '59144', - blast: '81457', - scroll: '534352', - aurora: '1313161554', -}; - -// Cosmos (https://axelarscan.io/resources/chains?type=cosmos) -const cosmos = { - Axelarnet: 'axelar-dojo-1', - osmosis: 'osmosis-1', - cosmoshub: 'cosmoshub-4', - juno: 'juno-1', - 'e-money': 'emoney-3', - injective: 'injective-1', - crescent: 'crescent-1', - kujira: 'kaiyo-1', - 'secret-snip': 'secret-4', - secret: 'secret-4', - sei: 'pacific-1', - stargaze: 'stargaze-1', - assetmantle: 'mantle-1', - fetch: 'fetchhub-4', - ki: 'kichain-2', - evmos: 'evmos_9001-2', - aura: 'xstaxy-1', - comdex: 'comdex-1', - persistence: 'core-1', - regen: 'regen-1', - umee: 'umee-1', - agoric: 'agoric-3', - xpla: 'dimension_37-1', - acre: 'acre_9052-1', - stride: 'stride-1', - carbon: 'carbon-1', - sommelier: 'sommelier-3', - neutron: 'neutron-1', - rebus: 'reb_1111-1', - archway: 'archway-1', - provenance: 'pio-mainnet-1', - ixo: 'ixo-5', - migaloo: 'migaloo-1', - teritori: 'teritori-1', - haqq: 'haqq_11235-1', - celestia: 'celestia', - ojo: 'agamotto', - chihuahua: 'chihuahua-1', - saga: 'ssc-1', - dymension: 'dymension_1100-1', - fxcore: 'fxcore', - c4e: 'perun-1', - bitsong: 'bitsong-2b', - nolus: 'pirin-1', - lava: 'lava-mainnet-1', - 'terra-2': 'phoenix-1', - terra: 'columbus-5', -}; - -const makeCAIP = ({ namespace, reference, account }) => ({ - namespace, - reference, - account, - caip2: `${namespace}:${reference}`, - caip10: `${namespace}:${reference}:${account}`, - toCaip10: other => `${namespace}:${reference}:${ethers.getAddress(other.target ?? other.address ?? other)}`, -}); - -module.exports = { - CHAINS: mapValues( - Object.assign( - mapValues(ethereum, reference => ({ - namespace: 'eip155', - reference, - account: ethers.Wallet.createRandom().address, - })), - mapValues(cosmos, reference => ({ - namespace: 'cosmos', - reference, - account: ethers.encodeBase58(ethers.randomBytes(32)), - })), - ), - makeCAIP, - ), - getLocalCAIP: account => - ethers.provider.getNetwork().then(({ chainId }) => makeCAIP({ namespace: 'eip155', reference: chainId, account })), -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/constants.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/constants.js deleted file mode 100644 index 4dfda5eaba..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/constants.js +++ /dev/null @@ -1,4 +0,0 @@ -module.exports = { - MAX_UINT48: 2n ** 48n - 1n, - MAX_UINT64: 2n ** 64n - 1n, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/deploy.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/deploy.js deleted file mode 100644 index 0d4b9563bc..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/deploy.js +++ /dev/null @@ -1,14 +0,0 @@ -const { artifacts, ethers } = require('hardhat'); -const { setCode } = require('@nomicfoundation/hardhat-network-helpers'); -const { generators } = require('./random'); - -const forceDeployCode = (name, address = generators.address(), runner = ethers.provider) => - artifacts - .readArtifact(name) - .then(({ abi, deployedBytecode }) => - setCode(address, deployedBytecode).then(() => new ethers.Contract(address, abi, runner)), - ); - -module.exports = { - forceDeployCode, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/eip712-types.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/eip712-types.js deleted file mode 100644 index d04969e442..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/eip712-types.js +++ /dev/null @@ -1,59 +0,0 @@ -const { mapValues } = require('./iterate'); - -const formatType = schema => Object.entries(schema).map(([name, type]) => ({ name, type })); - -module.exports = mapValues( - { - EIP712Domain: { - name: 'string', - version: 'string', - chainId: 'uint256', - verifyingContract: 'address', - salt: 'bytes32', - }, - Permit: { - owner: 'address', - spender: 'address', - value: 'uint256', - nonce: 'uint256', - deadline: 'uint256', - }, - Ballot: { - proposalId: 'uint256', - support: 'uint8', - voter: 'address', - nonce: 'uint256', - }, - ExtendedBallot: { - proposalId: 'uint256', - support: 'uint8', - voter: 'address', - nonce: 'uint256', - reason: 'string', - params: 'bytes', - }, - OverrideBallot: { - proposalId: 'uint256', - support: 'uint8', - voter: 'address', - nonce: 'uint256', - reason: 'string', - }, - Delegation: { - delegatee: 'address', - nonce: 'uint256', - expiry: 'uint256', - }, - ForwardRequest: { - from: 'address', - to: 'address', - value: 'uint256', - gas: 'uint256', - nonce: 'uint256', - deadline: 'uint48', - data: 'bytes', - }, - }, - formatType, -); -module.exports.formatType = formatType; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/eip712.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/eip712.js deleted file mode 100644 index 3843ac0269..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/eip712.js +++ /dev/null @@ -1,45 +0,0 @@ -const { ethers } = require('hardhat'); -const types = require('./eip712-types'); - -async function getDomain(contract) { - const { fields, name, version, chainId, verifyingContract, salt, extensions } = await contract.eip712Domain(); - - if (extensions.length > 0) { - throw Error('Extensions not implemented'); - } - - const domain = { - name, - version, - chainId, - verifyingContract, - salt, - }; - - for (const [i, { name }] of types.EIP712Domain.entries()) { - if (!(fields & (1 << i))) { - delete domain[name]; - } - } - - return domain; -} - -function domainType(domain) { - return types.EIP712Domain.filter(({ name }) => domain[name] !== undefined); -} - -function hashTypedData(domain, structHash) { - return ethers.solidityPackedKeccak256( - ['bytes', 'bytes32', 'bytes32'], - ['0x1901', ethers.TypedDataEncoder.hashDomain(domain), structHash], - ); -} - -module.exports = { - getDomain, - domainType, - domainSeparator: ethers.TypedDataEncoder.hashDomain, - hashTypedData, - ...types, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/enums.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/enums.js deleted file mode 100644 index f95767ab7e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/enums.js +++ /dev/null @@ -1,12 +0,0 @@ -function Enum(...options) { - return Object.fromEntries(options.map((key, i) => [key, BigInt(i)])); -} - -module.exports = { - Enum, - ProposalState: Enum('Pending', 'Active', 'Canceled', 'Defeated', 'Succeeded', 'Queued', 'Expired', 'Executed'), - VoteType: Object.assign(Enum('Against', 'For', 'Abstain'), { Parameters: 255n }), - Rounding: Enum('Floor', 'Ceil', 'Trunc', 'Expand'), - OperationState: Enum('Unset', 'Waiting', 'Ready', 'Done'), - RevertType: Enum('None', 'RevertWithoutMessage', 'RevertWithMessage', 'RevertWithCustomError', 'Panic'), -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/erc4337-entrypoint.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/erc4337-entrypoint.js deleted file mode 100644 index aba49f4c45..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/erc4337-entrypoint.js +++ /dev/null @@ -1,31 +0,0 @@ -const { ethers } = require('hardhat'); -const { setCode } = require('@nomicfoundation/hardhat-network-helpers'); -const fs = require('fs'); -const path = require('path'); - -const INSTANCES = { - entrypoint: { - address: '0x0000000071727De22E5E9d8BAf0edAc6f37da032', - abi: JSON.parse(fs.readFileSync(path.resolve(__dirname, '../bin/EntryPoint070.abi'), 'utf-8')), - bytecode: fs.readFileSync(path.resolve(__dirname, '../bin/EntryPoint070.bytecode'), 'hex'), - }, - sendercreator: { - address: '0xEFC2c1444eBCC4Db75e7613d20C6a62fF67A167C', - abi: JSON.parse(fs.readFileSync(path.resolve(__dirname, '../bin/SenderCreator070.abi'), 'utf-8')), - bytecode: fs.readFileSync(path.resolve(__dirname, '../bin/SenderCreator070.bytecode'), 'hex'), - }, -}; - -function deployEntrypoint() { - return Promise.all( - Object.entries(INSTANCES).map(([name, { address, abi, bytecode }]) => - setCode(address, '0x' + bytecode.replace(/0x/, '')) - .then(() => ethers.getContractAt(abi, address)) - .then(instance => ({ [name]: instance })), - ), - ).then(namedInstances => Object.assign(...namedInstances)); -} - -module.exports = { - deployEntrypoint, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/erc4337.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/erc4337.js deleted file mode 100644 index 50a3b4a043..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/erc4337.js +++ /dev/null @@ -1,111 +0,0 @@ -const { ethers } = require('hardhat'); - -const SIG_VALIDATION_SUCCESS = '0x0000000000000000000000000000000000000000'; -const SIG_VALIDATION_FAILURE = '0x0000000000000000000000000000000000000001'; - -function getAddress(account) { - return account.target ?? account.address ?? account; -} - -function pack(left, right) { - return ethers.solidityPacked(['uint128', 'uint128'], [left, right]); -} - -function packValidationData(validAfter, validUntil, authorizer) { - return ethers.solidityPacked( - ['uint48', 'uint48', 'address'], - [ - validAfter, - validUntil, - typeof authorizer == 'boolean' - ? authorizer - ? SIG_VALIDATION_SUCCESS - : SIG_VALIDATION_FAILURE - : getAddress(authorizer), - ], - ); -} - -function packInitCode(factory, factoryData) { - return ethers.solidityPacked(['address', 'bytes'], [getAddress(factory), factoryData]); -} - -function packPaymasterAndData(paymaster, paymasterVerificationGasLimit, paymasterPostOpGasLimit, paymasterData) { - return ethers.solidityPacked( - ['address', 'uint128', 'uint128', 'bytes'], - [getAddress(paymaster), paymasterVerificationGasLimit, paymasterPostOpGasLimit, paymasterData], - ); -} - -/// Represent one user operation -class UserOperation { - constructor(params) { - this.sender = getAddress(params.sender); - this.nonce = params.nonce; - this.factory = params.factory ?? undefined; - this.factoryData = params.factoryData ?? '0x'; - this.callData = params.callData ?? '0x'; - this.verificationGas = params.verificationGas ?? 10_000_000n; - this.callGas = params.callGas ?? 100_000n; - this.preVerificationGas = params.preVerificationGas ?? 100_000n; - this.maxPriorityFee = params.maxPriorityFee ?? 100_000n; - this.maxFeePerGas = params.maxFeePerGas ?? 100_000n; - this.paymaster = params.paymaster ?? undefined; - this.paymasterVerificationGasLimit = params.paymasterVerificationGasLimit ?? 0n; - this.paymasterPostOpGasLimit = params.paymasterPostOpGasLimit ?? 0n; - this.paymasterData = params.paymasterData ?? '0x'; - this.signature = params.signature ?? '0x'; - } - - get packed() { - return { - sender: this.sender, - nonce: this.nonce, - initCode: this.factory ? packInitCode(this.factory, this.factoryData) : '0x', - callData: this.callData, - accountGasLimits: pack(this.verificationGas, this.callGas), - preVerificationGas: this.preVerificationGas, - gasFees: pack(this.maxPriorityFee, this.maxFeePerGas), - paymasterAndData: this.paymaster - ? packPaymasterAndData( - this.paymaster, - this.paymasterVerificationGasLimit, - this.paymasterPostOpGasLimit, - this.paymasterData, - ) - : '0x', - signature: this.signature, - }; - } - - hash(entrypoint, chainId) { - const p = this.packed; - const h = ethers.keccak256( - ethers.AbiCoder.defaultAbiCoder().encode( - ['address', 'uint256', 'bytes32', 'bytes32', 'uint256', 'uint256', 'uint256', 'uint256'], - [ - p.sender, - p.nonce, - ethers.keccak256(p.initCode), - ethers.keccak256(p.callData), - p.accountGasLimits, - p.preVerificationGas, - p.gasFees, - ethers.keccak256(p.paymasterAndData), - ], - ), - ); - return ethers.keccak256( - ethers.AbiCoder.defaultAbiCoder().encode(['bytes32', 'address', 'uint256'], [h, getAddress(entrypoint), chainId]), - ); - } -} - -module.exports = { - SIG_VALIDATION_SUCCESS, - SIG_VALIDATION_FAILURE, - packValidationData, - packInitCode, - packPaymasterAndData, - UserOperation, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/erc7579.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/erc7579.js deleted file mode 100644 index 6c3b4759b7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/erc7579.js +++ /dev/null @@ -1,58 +0,0 @@ -const { ethers } = require('hardhat'); - -const MODULE_TYPE_VALIDATOR = 1; -const MODULE_TYPE_EXECUTOR = 2; -const MODULE_TYPE_FALLBACK = 3; -const MODULE_TYPE_HOOK = 4; - -const EXEC_TYPE_DEFAULT = '0x00'; -const EXEC_TYPE_TRY = '0x01'; - -const CALL_TYPE_CALL = '0x00'; -const CALL_TYPE_BATCH = '0x01'; -const CALL_TYPE_DELEGATE = '0xff'; - -const encodeMode = ({ - callType = '0x00', - execType = '0x00', - selector = '0x00000000', - payload = '0x00000000000000000000000000000000000000000000', -} = {}) => - ethers.solidityPacked( - ['bytes1', 'bytes1', 'bytes4', 'bytes4', 'bytes22'], - [callType, execType, '0x00000000', selector, payload], - ); - -const encodeSingle = (target, value = 0n, data = '0x') => - ethers.solidityPacked(['address', 'uint256', 'bytes'], [target.target ?? target.address ?? target, value, data]); - -const encodeBatch = (...entries) => - ethers.AbiCoder.defaultAbiCoder().encode( - ['(address,uint256,bytes)[]'], - [ - entries.map(entry => - Array.isArray(entry) - ? [entry[0].target ?? entry[0].address ?? entry[0], entry[1] ?? 0n, entry[2] ?? '0x'] - : [entry.target.target ?? entry.target.address ?? entry.target, entry.value ?? 0n, entry.data ?? '0x'], - ), - ], - ); - -const encodeDelegate = (target, data = '0x') => - ethers.solidityPacked(['address', 'bytes'], [target.target ?? target.address ?? target, data]); - -module.exports = { - MODULE_TYPE_VALIDATOR, - MODULE_TYPE_EXECUTOR, - MODULE_TYPE_FALLBACK, - MODULE_TYPE_HOOK, - EXEC_TYPE_DEFAULT, - EXEC_TYPE_TRY, - CALL_TYPE_CALL, - CALL_TYPE_BATCH, - CALL_TYPE_DELEGATE, - encodeMode, - encodeSingle, - encodeBatch, - encodeDelegate, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/governance.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/governance.js deleted file mode 100644 index 540967af49..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/governance.js +++ /dev/null @@ -1,215 +0,0 @@ -const { ethers } = require('hardhat'); -const { ProposalState } = require('./enums'); -const { unique } = require('./iterate'); -const time = require('./time'); - -const timelockSalt = (address, descriptionHash) => - ethers.toBeHex((ethers.toBigInt(address) << 96n) ^ ethers.toBigInt(descriptionHash), 32); - -class GovernorHelper { - constructor(governor, mode = 'blocknumber') { - this.governor = governor; - this.mode = mode; - } - - connect(account) { - this.governor = this.governor.connect(account); - return this; - } - - /// Setter and getters - /** - * Specify a proposal either as - * 1) an array of objects [{ target, value, data }] - * 2) an object of arrays { targets: [], values: [], data: [] } - */ - setProposal(actions, description) { - if (Array.isArray(actions)) { - this.targets = actions.map(a => a.target); - this.values = actions.map(a => a.value || 0n); - this.data = actions.map(a => a.data || '0x'); - } else { - ({ targets: this.targets, values: this.values, data: this.data } = actions); - } - this.description = description; - return this; - } - - get id() { - return ethers.keccak256( - ethers.AbiCoder.defaultAbiCoder().encode(['address[]', 'uint256[]', 'bytes[]', 'bytes32'], this.shortProposal), - ); - } - - // used for checking events - get signatures() { - return this.data.map(() => ''); - } - - get descriptionHash() { - return ethers.id(this.description); - } - - // condensed version for queueing end executing - get shortProposal() { - return [this.targets, this.values, this.data, this.descriptionHash]; - } - - // full version for proposing - get fullProposal() { - return [this.targets, this.values, this.data, this.description]; - } - - get currentProposal() { - return this; - } - - /// Proposal lifecycle - delegate(delegation) { - return Promise.all([ - delegation.token.connect(delegation.to).delegate(delegation.to), - delegation.value === undefined || - delegation.token.connect(this.governor.runner).transfer(delegation.to, delegation.value), - delegation.tokenId === undefined || - delegation.token - .ownerOf(delegation.tokenId) - .then(owner => - delegation.token.connect(this.governor.runner).transferFrom(owner, delegation.to, delegation.tokenId), - ), - ]); - } - - propose() { - return this.governor.propose(...this.fullProposal); - } - - queue() { - return this.governor.queue(...this.shortProposal); - } - - execute() { - return this.governor.execute(...this.shortProposal); - } - - cancel(visibility = 'external') { - switch (visibility) { - case 'external': - return this.governor.cancel(...this.shortProposal); - - case 'internal': - return this.governor.$_cancel(...this.shortProposal); - - default: - throw new Error(`unsupported visibility "${visibility}"`); - } - } - - async vote(vote = {}) { - let method = 'castVote'; // default - let args = [this.id, vote.support]; // base - - if (vote.signature) { - const sign = await vote.signature(this.governor, this.forgeMessage(vote)); - if (vote.params || vote.reason) { - method = 'castVoteWithReasonAndParamsBySig'; - args.push(vote.voter, vote.reason ?? '', vote.params ?? '0x', sign); - } else { - method = 'castVoteBySig'; - args.push(vote.voter, sign); - } - } else if (vote.params) { - method = 'castVoteWithReasonAndParams'; - args.push(vote.reason ?? '', vote.params); - } else if (vote.reason) { - method = 'castVoteWithReason'; - args.push(vote.reason); - } - - return await this.governor[method](...args); - } - - async overrideVote(vote = {}) { - let method = 'castOverrideVote'; - let args = [this.id, vote.support]; - - vote.reason = vote.reason ?? ''; - - if (vote.signature) { - let message = this.forgeMessage(vote); - message.reason = message.reason ?? ''; - const sign = await vote.signature(this.governor, message); - method = 'castOverrideVoteBySig'; - args.push(vote.voter, vote.reason ?? '', sign); - } - - return await this.governor[method](...args); - } - - /// Clock helpers - async waitForSnapshot(offset = 0n) { - const timepoint = await this.governor.proposalSnapshot(this.id); - return time.increaseTo[this.mode](timepoint + offset); - } - - async waitForDeadline(offset = 0n) { - const timepoint = await this.governor.proposalDeadline(this.id); - return time.increaseTo[this.mode](timepoint + offset); - } - - async waitForEta(offset = 0n) { - const timestamp = await this.governor.proposalEta(this.id); - return time.increaseTo.timestamp(timestamp + offset); - } - - /// Other helpers - forgeMessage(vote = {}) { - const message = { proposalId: this.id, support: vote.support, voter: vote.voter, nonce: vote.nonce }; - - if (vote.params || vote.reason) { - message.reason = vote.reason ?? ''; - message.params = vote.params ?? '0x'; - } - - return message; - } - - /** - * Encodes a list ProposalStates into a bytes32 representation where each bit enabled corresponds to - * the underlying position in the `ProposalState` enum. For example: - * - * 0x000...10000 - * ^^^^^^------ ... - * ^----- Succeeded - * ^---- Defeated - * ^--- Canceled - * ^-- Active - * ^- Pending - */ - static proposalStatesToBitMap(proposalStates, options = {}) { - if (!Array.isArray(proposalStates)) { - proposalStates = [proposalStates]; - } - const statesCount = ethers.toBigInt(Object.keys(ProposalState).length); - let result = 0n; - - for (const state of unique(proposalStates)) { - if (state < 0n || state >= statesCount) { - expect.fail(`ProposalState ${state} out of possible states (0...${statesCount}-1)`); - } else { - result |= 1n << state; - } - } - - if (options.inverted) { - const mask = 2n ** statesCount - 1n; - result = result ^ mask; - } - - return ethers.toBeHex(result, 32); - } -} - -module.exports = { - GovernorHelper, - timelockSalt, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/iterate.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/iterate.js deleted file mode 100644 index c7403d5238..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/iterate.js +++ /dev/null @@ -1,36 +0,0 @@ -module.exports = { - // ================================================= Array helpers ================================================= - - // Cut an array into an array of sized-length arrays - // Example: chunk([1,2,3,4,5,6,7,8], 3) → [[1,2,3],[4,5,6],[7,8]] - chunk: (array, size = 1) => - Array.from({ length: Math.ceil(array.length / size) }, (_, i) => array.slice(i * size, i * size + size)), - - // Cartesian cross product of an array of arrays - // Example: product([1,2],[a,b,c],[true]) → [[1,a,true],[1,b,true],[1,c,true],[2,a,true],[2,b,true],[2,c,true]] - product: (...arrays) => arrays.reduce((a, b) => a.flatMap(ai => b.map(bi => [...ai, bi])), [[]]), - - // Range from start to end in increment - // Example: range(17,42,7) → [17,24,31,38] - range: (start, stop = undefined, step = 1) => { - if (stop == undefined) { - stop = start; - start = 0; - } - return start < stop ? Array.from({ length: (stop - start + step - 1) / step }, (_, i) => start + i * step) : []; - }, - - // Unique elements, with an optional getter function - // Example: unique([1,1,2,3,4,8,1,3,8,13,42]) → [1,2,3,4,8,13,42] - unique: (array, op = x => x) => array.filter((obj, i) => array.findIndex(entry => op(obj) === op(entry)) === i), - - // Zip arrays together. If some arrays are smaller, undefined is used as a filler. - // Example: zip([1,2],[a,b,c],[true]) → [[1,a,true],[2,b,undefined],[undefined,c,undefined]] - zip: (...args) => Array.from({ length: Math.max(...args.map(arg => arg.length)) }, (_, i) => args.map(arg => arg[i])), - - // ================================================ Object helpers ================================================= - - // Create a new object by mapping the values through a function, keeping the keys - // Example: mapValues({a:1,b:2,c:3}, x => x**2) → {a:1,b:4,c:9} - mapValues: (obj, fn) => Object.fromEntries(Object.entries(obj).map(([k, v]) => [k, fn(v)])), -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/math.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/math.js deleted file mode 100644 index 133254aecc..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/math.js +++ /dev/null @@ -1,33 +0,0 @@ -// Array of number or bigint -const max = (...values) => values.slice(1).reduce((x, y) => (x > y ? x : y), values.at(0)); -const min = (...values) => values.slice(1).reduce((x, y) => (x < y ? x : y), values.at(0)); -const sum = (...values) => values.slice(1).reduce((x, y) => x + y, values.at(0)); - -// Computes modexp without BigInt overflow for large numbers -function modExp(b, e, m) { - let result = 1n; - - // If e is a power of two, modexp can be calculated as: - // for (let result = b, i = 0; i < log2(e); i++) result = modexp(result, 2, m) - // - // Given any natural number can be written in terms of powers of 2 (i.e. binary) - // then modexp can be calculated for any e, by multiplying b**i for all i where - // binary(e)[i] is 1 (i.e. a power of two). - for (let base = b % m; e > 0n; base = base ** 2n % m) { - // Least significant bit is 1 - if (e % 2n == 1n) { - result = (result * base) % m; - } - - e /= 2n; // Binary pop - } - - return result; -} - -module.exports = { - min, - max, - sum, - modExp, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/methods.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/methods.js deleted file mode 100644 index a491897201..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/methods.js +++ /dev/null @@ -1,14 +0,0 @@ -const { ethers } = require('hardhat'); - -const selector = signature => ethers.FunctionFragment.from(signature).selector; - -const interfaceId = signatures => - ethers.toBeHex( - signatures.reduce((acc, signature) => acc ^ ethers.toBigInt(selector(signature)), 0n), - 4, - ); - -module.exports = { - selector, - interfaceId, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/random.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/random.js deleted file mode 100644 index 3adeed0a44..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/random.js +++ /dev/null @@ -1,19 +0,0 @@ -const { ethers } = require('hardhat'); - -const generators = { - address: () => ethers.Wallet.createRandom().address, - bytes32: () => ethers.hexlify(ethers.randomBytes(32)), - uint256: () => ethers.toBigInt(ethers.randomBytes(32)), - int256: () => ethers.toBigInt(ethers.randomBytes(32)) + ethers.MinInt256, - hexBytes: length => ethers.hexlify(ethers.randomBytes(length)), -}; - -generators.address.zero = ethers.ZeroAddress; -generators.bytes32.zero = ethers.ZeroHash; -generators.uint256.zero = 0n; -generators.int256.zero = 0n; -generators.hexBytes.zero = '0x'; - -module.exports = { - generators, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/storage.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/storage.js deleted file mode 100644 index 466cbb10c5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/storage.js +++ /dev/null @@ -1,48 +0,0 @@ -const { ethers } = require('hardhat'); -const { setStorageAt } = require('@nomicfoundation/hardhat-network-helpers'); - -const ImplementationLabel = 'eip1967.proxy.implementation'; -const AdminLabel = 'eip1967.proxy.admin'; -const BeaconLabel = 'eip1967.proxy.beacon'; - -const erc1967Slot = label => ethers.toBeHex(ethers.toBigInt(ethers.id(label)) - 1n); -const erc7201Slot = label => ethers.toBeHex(ethers.toBigInt(ethers.keccak256(erc1967Slot(label))) & ~0xffn); -const erc7201format = contractName => `openzeppelin.storage.${contractName}`; - -const getSlot = (address, slot) => - ethers.provider.getStorage(address, ethers.isBytesLike(slot) ? slot : erc1967Slot(slot)); - -const setSlot = (address, slot, value) => - Promise.all([ - ethers.isAddressable(address) ? address.getAddress() : Promise.resolve(address), - ethers.isAddressable(value) ? value.getAddress() : Promise.resolve(value), - ]).then(([address, value]) => setStorageAt(address, ethers.isBytesLike(slot) ? slot : erc1967Slot(slot), value)); - -const getAddressInSlot = (address, slot) => - getSlot(address, slot).then(slotValue => ethers.AbiCoder.defaultAbiCoder().decode(['address'], slotValue)[0]); - -const upgradeableSlot = (contractName, offset) => { - try { - // Try to get the artifact paths, will throw if it doesn't exist - artifacts._getArtifactPathSync(`${contractName}Upgradeable`); - return offset + ethers.toBigInt(erc7201Slot(erc7201format(contractName))); - } catch { - return offset; - } -}; - -module.exports = { - ImplementationLabel, - AdminLabel, - BeaconLabel, - ImplementationSlot: erc1967Slot(ImplementationLabel), - AdminSlot: erc1967Slot(AdminLabel), - BeaconSlot: erc1967Slot(BeaconLabel), - erc1967Slot, - erc7201Slot, - erc7201format, - setSlot, - getSlot, - getAddressInSlot, - upgradeableSlot, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/strings.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/strings.js deleted file mode 100644 index 4f34099d7d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/strings.js +++ /dev/null @@ -1,5 +0,0 @@ -module.exports = { - // Capitalize the first char of a string - // Example: capitalize('uint256') → 'Uint256' - capitalize: str => str.charAt(0).toUpperCase() + str.slice(1), -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/time.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/time.js deleted file mode 100644 index f6ccc3caba..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/time.js +++ /dev/null @@ -1,30 +0,0 @@ -const { ethers } = require('hardhat'); -const { time, mine, mineUpTo } = require('@nomicfoundation/hardhat-network-helpers'); -const { mapValues } = require('./iterate'); - -const clock = { - blocknumber: () => time.latestBlock().then(ethers.toBigInt), - timestamp: () => time.latest().then(ethers.toBigInt), -}; -const clockFromReceipt = { - blocknumber: receipt => Promise.resolve(ethers.toBigInt(receipt.blockNumber)), - timestamp: receipt => ethers.provider.getBlock(receipt.blockNumber).then(block => ethers.toBigInt(block.timestamp)), -}; -const increaseBy = { - blockNumber: mine, - timestamp: (delay, mine = true) => - time.latest().then(clock => increaseTo.timestamp(clock + ethers.toNumber(delay), mine)), -}; -const increaseTo = { - blocknumber: mineUpTo, - timestamp: (to, mine = true) => (mine ? time.increaseTo(to) : time.setNextBlockTimestamp(to)), -}; -const duration = mapValues(time.duration, fn => n => ethers.toBigInt(fn(ethers.toNumber(n)))); - -module.exports = { - clock, - clockFromReceipt, - increaseBy, - increaseTo, - duration, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/txpool.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/txpool.js deleted file mode 100644 index f01327b223..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/helpers/txpool.js +++ /dev/null @@ -1,29 +0,0 @@ -const { network } = require('hardhat'); -const { expect } = require('chai'); -const { mine } = require('@nomicfoundation/hardhat-network-helpers'); - -const { unique } = require('./iterate'); - -async function batchInBlock(txs) { - try { - // disable auto-mining - await network.provider.send('evm_setAutomine', [false]); - // send all transactions - const responses = await Promise.all(txs.map(fn => fn())); - // mine one block - await mine(); - // fetch receipts - const receipts = await Promise.all(responses.map(response => response.wait())); - // Sanity check, all tx should be in the same block - expect(unique(receipts.map(receipt => receipt.blockNumber))).to.have.lengthOf(1); - // return responses - return receipts; - } finally { - // enable auto-mining - await network.provider.send('evm_setAutomine', [true]); - } -} - -module.exports = { - batchInBlock, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/metatx/ERC2771Context.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/metatx/ERC2771Context.test.js deleted file mode 100644 index 15da61dad1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/metatx/ERC2771Context.test.js +++ /dev/null @@ -1,133 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { impersonate } = require('../helpers/account'); -const { getDomain, ForwardRequest } = require('../helpers/eip712'); -const { MAX_UINT48 } = require('../helpers/constants'); - -const { shouldBehaveLikeRegularContext } = require('../utils/Context.behavior'); - -async function fixture() { - const [sender, other] = await ethers.getSigners(); - - const forwarder = await ethers.deployContract('ERC2771Forwarder', []); - const forwarderAsSigner = await impersonate(forwarder.target); - const context = await ethers.deployContract('ERC2771ContextMock', [forwarder]); - const domain = await getDomain(forwarder); - const types = { ForwardRequest }; - - return { sender, other, forwarder, forwarderAsSigner, context, domain, types }; -} - -describe('ERC2771Context', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('recognize trusted forwarder', async function () { - expect(await this.context.isTrustedForwarder(this.forwarder)).to.be.true; - }); - - it('returns the trusted forwarder', async function () { - expect(await this.context.trustedForwarder()).to.equal(this.forwarder); - }); - - describe('when called directly', function () { - shouldBehaveLikeRegularContext(); - }); - - describe('when receiving a relayed call', function () { - describe('msgSender', function () { - it('returns the relayed transaction original sender', async function () { - const nonce = await this.forwarder.nonces(this.sender); - const data = this.context.interface.encodeFunctionData('msgSender'); - - const req = { - from: await this.sender.getAddress(), - to: await this.context.getAddress(), - value: 0n, - data, - gas: 100000n, - nonce, - deadline: MAX_UINT48, - }; - - req.signature = await this.sender.signTypedData(this.domain, this.types, req); - - expect(await this.forwarder.verify(req)).to.be.true; - - await expect(this.forwarder.execute(req)).to.emit(this.context, 'Sender').withArgs(this.sender); - }); - - it('returns the original sender when calldata length is less than 20 bytes (address length)', async function () { - // The forwarder doesn't produce calls with calldata length less than 20 bytes so `this.forwarderAsSigner` is used instead. - await expect(this.context.connect(this.forwarderAsSigner).msgSender()) - .to.emit(this.context, 'Sender') - .withArgs(this.forwarder); - }); - }); - - describe('msgData', function () { - it('returns the relayed transaction original data', async function () { - const args = [42n, 'OpenZeppelin']; - - const nonce = await this.forwarder.nonces(this.sender); - const data = this.context.interface.encodeFunctionData('msgData', args); - - const req = { - from: await this.sender.getAddress(), - to: await this.context.getAddress(), - value: 0n, - data, - gas: 100000n, - nonce, - deadline: MAX_UINT48, - }; - - req.signature = this.sender.signTypedData(this.domain, this.types, req); - - expect(await this.forwarder.verify(req)).to.be.true; - - await expect(this.forwarder.execute(req)) - .to.emit(this.context, 'Data') - .withArgs(data, ...args); - }); - }); - - it('returns the full original data when calldata length is less than 20 bytes (address length)', async function () { - const data = this.context.interface.encodeFunctionData('msgDataShort'); - - // The forwarder doesn't produce calls with calldata length less than 20 bytes so `this.forwarderAsSigner` is used instead. - await expect(await this.context.connect(this.forwarderAsSigner).msgDataShort()) - .to.emit(this.context, 'DataShort') - .withArgs(data); - }); - }); - - it('multicall poison attack', async function () { - const nonce = await this.forwarder.nonces(this.sender); - const data = this.context.interface.encodeFunctionData('multicall', [ - [ - // poisonned call to 'msgSender()' - ethers.concat([this.context.interface.encodeFunctionData('msgSender'), this.other.address]), - ], - ]); - - const req = { - from: await this.sender.getAddress(), - to: await this.context.getAddress(), - value: 0n, - data, - gas: 100000n, - nonce, - deadline: MAX_UINT48, - }; - - req.signature = await this.sender.signTypedData(this.domain, this.types, req); - - expect(await this.forwarder.verify(req)).to.be.true; - - await expect(this.forwarder.execute(req)).to.emit(this.context, 'Sender').withArgs(this.sender); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/metatx/ERC2771Forwarder.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/metatx/ERC2771Forwarder.t.sol deleted file mode 100644 index e6baac6f03..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/metatx/ERC2771Forwarder.t.sol +++ /dev/null @@ -1,279 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {ERC2771Forwarder} from "@openzeppelin/contracts/metatx/ERC2771Forwarder.sol"; -import {CallReceiverMockTrustingForwarder, CallReceiverMock} from "@openzeppelin/contracts/mocks/CallReceiverMock.sol"; -import {ECDSA} from "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; -import {SafeCast} from "@openzeppelin/contracts/utils/math/SafeCast.sol"; - -enum TamperType { - FROM, - TO, - VALUE, - DATA, - SIGNATURE -} - -contract ERC2771ForwarderMock is ERC2771Forwarder { - constructor(string memory name) ERC2771Forwarder(name) {} - - function forwardRequestStructHash( - ERC2771Forwarder.ForwardRequestData calldata request, - uint256 nonce - ) external view returns (bytes32) { - return - _hashTypedDataV4( - keccak256( - abi.encode( - _FORWARD_REQUEST_TYPEHASH, - request.from, - request.to, - request.value, - request.gas, - nonce, - request.deadline, - keccak256(request.data) - ) - ) - ); - } -} - -contract ERC2771ForwarderTest is Test { - using ECDSA for bytes32; - - ERC2771ForwarderMock internal _erc2771Forwarder; - CallReceiverMockTrustingForwarder internal _receiver; - - uint256 internal _signerPrivateKey = 0xA11CE; - address internal _signer = vm.addr(_signerPrivateKey); - - uint256 internal constant _MAX_ETHER = 10_000_000; // To avoid overflow - - function setUp() public { - _erc2771Forwarder = new ERC2771ForwarderMock("ERC2771Forwarder"); - _receiver = new CallReceiverMockTrustingForwarder(address(_erc2771Forwarder)); - } - - // Forge a new ForwardRequestData - function _forgeRequestData() private view returns (ERC2771Forwarder.ForwardRequestData memory) { - return - _forgeRequestData({ - value: 0, - deadline: uint48(block.timestamp + 1), - data: abi.encodeCall(CallReceiverMock.mockFunction, ()) - }); - } - - function _forgeRequestData( - uint256 value, - uint48 deadline, - bytes memory data - ) private view returns (ERC2771Forwarder.ForwardRequestData memory) { - return - ERC2771Forwarder.ForwardRequestData({ - from: _signer, - to: address(_receiver), - value: value, - gas: 30000, - deadline: deadline, - data: data, - signature: "" - }); - } - - // Sign a ForwardRequestData (in place) for a given nonce. Also returns it for convenience. - function _signRequestData( - ERC2771Forwarder.ForwardRequestData memory request, - uint256 nonce - ) private view returns (ERC2771Forwarder.ForwardRequestData memory) { - bytes32 digest = _erc2771Forwarder.forwardRequestStructHash(request, nonce); - (uint8 v, bytes32 r, bytes32 s) = vm.sign(_signerPrivateKey, digest); - request.signature = abi.encodePacked(r, s, v); - return request; - } - - // Tamper a ForwardRequestData (in place). Also returns it for convenience. - function _tamperRequestData( - ERC2771Forwarder.ForwardRequestData memory request, - TamperType tamper - ) private returns (ERC2771Forwarder.ForwardRequestData memory) { - if (tamper == TamperType.FROM) request.from = vm.randomAddress(); - else if (tamper == TamperType.TO) request.to = vm.randomAddress(); - else if (tamper == TamperType.VALUE) request.value = vm.randomUint(); - else if (tamper == TamperType.DATA) request.data = vm.randomBytes(4); - else if (tamper == TamperType.SIGNATURE) request.signature = vm.randomBytes(65); - - return request; - } - - // Predict the revert error for a tampered request, and expect it is emitted. - function _tamperedExpectRevert( - ERC2771Forwarder.ForwardRequestData memory request, - TamperType tamper, - uint256 nonce - ) private returns (ERC2771Forwarder.ForwardRequestData memory) { - if (tamper == TamperType.FROM) nonce = _erc2771Forwarder.nonces(request.from); - - // predict revert - if (tamper == TamperType.TO) { - vm.expectRevert( - abi.encodeWithSelector( - ERC2771Forwarder.ERC2771UntrustfulTarget.selector, - request.to, - address(_erc2771Forwarder) - ) - ); - } else { - (address recovered, , ) = _erc2771Forwarder.forwardRequestStructHash(request, nonce).tryRecover( - request.signature - ); - vm.expectRevert( - abi.encodeWithSelector(ERC2771Forwarder.ERC2771ForwarderInvalidSigner.selector, recovered, request.from) - ); - } - return request; - } - - function testExecuteAvoidsETHStuck(uint256 initialBalance, uint256 value, bool targetReverts) public { - initialBalance = bound(initialBalance, 0, _MAX_ETHER); - value = bound(value, 0, _MAX_ETHER); - - // create and sign request - ERC2771Forwarder.ForwardRequestData memory request = _forgeRequestData({ - value: value, - deadline: uint48(block.timestamp + 1), - data: targetReverts - ? abi.encodeCall(CallReceiverMock.mockFunctionRevertsNoReason, ()) - : abi.encodeCall(CallReceiverMock.mockFunction, ()) - }); - _signRequestData(request, _erc2771Forwarder.nonces(_signer)); - - vm.deal(address(_erc2771Forwarder), initialBalance); - vm.deal(address(this), request.value); - - if (targetReverts) vm.expectRevert(); - _erc2771Forwarder.execute{value: value}(request); - - assertEq(address(_erc2771Forwarder).balance, initialBalance); - } - - function testExecuteBatchAvoidsETHStuck(uint256 initialBalance, uint256 batchSize, uint256 value) public { - uint256 seed = uint256(keccak256(abi.encodePacked(initialBalance, batchSize, value))); - - batchSize = bound(batchSize, 1, 10); - initialBalance = bound(initialBalance, 0, _MAX_ETHER); - value = bound(value, 0, _MAX_ETHER); - - address refundReceiver = address(0xebe); - uint256 refundExpected = 0; - uint256 nonce = _erc2771Forwarder.nonces(_signer); - - // create an sign array or requests (that may fail) - ERC2771Forwarder.ForwardRequestData[] memory requests = new ERC2771Forwarder.ForwardRequestData[](batchSize); - for (uint256 i = 0; i < batchSize; ++i) { - bool failure = (seed >> i) & 0x1 == 0x1; - - requests[i] = _forgeRequestData({ - value: value, - deadline: uint48(block.timestamp + 1), - data: failure - ? abi.encodeCall(CallReceiverMock.mockFunctionRevertsNoReason, ()) - : abi.encodeCall(CallReceiverMock.mockFunction, ()) - }); - _signRequestData(requests[i], nonce + i); - - refundExpected += SafeCast.toUint(failure) * value; - } - - // distribute ether - vm.deal(address(_erc2771Forwarder), initialBalance); - vm.deal(address(this), value * batchSize); - - // execute batch - _erc2771Forwarder.executeBatch{value: value * batchSize}(requests, payable(refundReceiver)); - - // check balances - assertEq(address(_erc2771Forwarder).balance, initialBalance); - assertEq(refundReceiver.balance, refundExpected); - } - - function testVerifyTamperedValues(uint8 _tamper) public { - TamperType tamper = _asTamper(_tamper); - - // create request, sign, tamper - ERC2771Forwarder.ForwardRequestData memory request = _forgeRequestData(); - _signRequestData(request, 0); - _tamperRequestData(request, tamper); - - // should not pass verification - assertFalse(_erc2771Forwarder.verify(request)); - } - - function testExecuteTamperedValues(uint8 _tamper) public { - TamperType tamper = _asTamper(_tamper); - - // create request, sign, tamper, expect execution revert - ERC2771Forwarder.ForwardRequestData memory request = _forgeRequestData(); - _signRequestData(request, 0); - _tamperRequestData(request, tamper); - _tamperedExpectRevert(request, tamper, 0); - - vm.deal(address(this), request.value); - _erc2771Forwarder.execute{value: request.value}(request); - } - - function testExecuteBatchTamperedValuesZeroReceiver(uint8 _tamper) public { - TamperType tamper = _asTamper(_tamper); - uint256 nonce = _erc2771Forwarder.nonces(_signer); - - // create an sign array or requests - ERC2771Forwarder.ForwardRequestData[] memory requests = new ERC2771Forwarder.ForwardRequestData[](3); - for (uint256 i = 0; i < requests.length; ++i) { - requests[i] = _forgeRequestData({ - value: 0, - deadline: uint48(block.timestamp + 1), - data: abi.encodeCall(CallReceiverMock.mockFunction, ()) - }); - _signRequestData(requests[i], nonce + i); - } - - // tamper with request[1] and expect execution revert - _tamperRequestData(requests[1], tamper); - _tamperedExpectRevert(requests[1], tamper, nonce + 1); - - vm.deal(address(this), requests[1].value); - _erc2771Forwarder.executeBatch{value: requests[1].value}(requests, payable(address(0))); - } - - function testExecuteBatchTamperedValues(uint8 _tamper) public { - TamperType tamper = _asTamper(_tamper); - uint256 nonce = _erc2771Forwarder.nonces(_signer); - - // create an sign array or requests - ERC2771Forwarder.ForwardRequestData[] memory requests = new ERC2771Forwarder.ForwardRequestData[](3); - for (uint256 i = 0; i < requests.length; ++i) { - requests[i] = _forgeRequestData({ - value: 0, - deadline: uint48(block.timestamp + 1), - data: abi.encodeCall(CallReceiverMock.mockFunction, ()) - }); - _signRequestData(requests[i], nonce + i); - } - - // tamper with request[1] - _tamperRequestData(requests[1], tamper); - - // should not revert - vm.expectCall(address(_receiver), abi.encodeCall(CallReceiverMock.mockFunction, ()), 1); - - vm.deal(address(this), requests[1].value); - _erc2771Forwarder.executeBatch{value: requests[1].value}(requests, payable(address(0xebe))); - } - - function _asTamper(uint8 _tamper) private pure returns (TamperType) { - return TamperType(bound(_tamper, uint8(TamperType.FROM), uint8(TamperType.SIGNATURE))); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/metatx/ERC2771Forwarder.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/metatx/ERC2771Forwarder.test.js deleted file mode 100644 index bf6cfd10c4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/metatx/ERC2771Forwarder.test.js +++ /dev/null @@ -1,384 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { getDomain, ForwardRequest } = require('../helpers/eip712'); -const { sum } = require('../helpers/math'); -const time = require('../helpers/time'); - -async function fixture() { - const [sender, refundReceiver, another, ...accounts] = await ethers.getSigners(); - - const forwarder = await ethers.deployContract('ERC2771Forwarder', ['ERC2771Forwarder']); - const receiver = await ethers.deployContract('CallReceiverMockTrustingForwarder', [forwarder]); - const domain = await getDomain(forwarder); - const types = { ForwardRequest }; - - const forgeRequest = async (override = {}, signer = sender) => { - const req = { - from: await signer.getAddress(), - to: await receiver.getAddress(), - value: 0n, - data: receiver.interface.encodeFunctionData('mockFunction'), - gas: 100000n, - deadline: (await time.clock.timestamp()) + 60n, - nonce: await forwarder.nonces(sender), - ...override, - }; - req.signature = await signer.signTypedData(domain, types, req); - return req; - }; - - const estimateRequest = request => - ethers.provider.estimateGas({ - from: forwarder, - to: request.to, - data: ethers.solidityPacked(['bytes', 'address'], [request.data, request.from]), - value: request.value, - gasLimit: request.gas, - }); - - return { - sender, - refundReceiver, - another, - accounts, - forwarder, - receiver, - forgeRequest, - estimateRequest, - domain, - types, - }; -} - -describe('ERC2771Forwarder', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('verify', function () { - describe('with valid signature', function () { - it('returns true without altering the nonce', async function () { - const request = await this.forgeRequest(); - expect(await this.forwarder.nonces(request.from)).to.equal(request.nonce); - expect(await this.forwarder.verify(request)).to.be.true; - expect(await this.forwarder.nonces(request.from)).to.equal(request.nonce); - }); - }); - - describe('with tampered values', function () { - it('returns false with valid signature for non-current nonce', async function () { - const request = await this.forgeRequest({ nonce: 1337n }); - expect(await this.forwarder.verify(request)).to.be.false; - }); - - it('returns false with valid signature for expired deadline', async function () { - const request = await this.forgeRequest({ deadline: (await time.clock.timestamp()) - 1n }); - expect(await this.forwarder.verify(request)).to.be.false; - }); - }); - }); - - describe('execute', function () { - describe('with valid requests', function () { - it('emits an event and consumes nonce for a successful request', async function () { - const request = await this.forgeRequest(); - - expect(await this.forwarder.nonces(request.from)).to.equal(request.nonce); - - await expect(this.forwarder.execute(request)) - .to.emit(this.receiver, 'MockFunctionCalled') - .to.emit(this.forwarder, 'ExecutedForwardRequest') - .withArgs(request.from, request.nonce, true); - - expect(await this.forwarder.nonces(request.from)).to.equal(request.nonce + 1n); - }); - - it('reverts with an unsuccessful request', async function () { - const request = await this.forgeRequest({ - data: this.receiver.interface.encodeFunctionData('mockFunctionRevertsNoReason'), - }); - - await expect(this.forwarder.execute(request)).to.be.revertedWithCustomError(this.forwarder, 'FailedCall'); - }); - }); - - describe('with tampered request', function () { - it('reverts with valid signature for non-current nonce', async function () { - const request = await this.forgeRequest(); - - // consume nonce - await this.forwarder.execute(request); - - // nonce has changed - await expect(this.forwarder.execute(request)) - .to.be.revertedWithCustomError(this.forwarder, 'ERC2771ForwarderInvalidSigner') - .withArgs( - ethers.verifyTypedData( - this.domain, - this.types, - { ...request, nonce: request.nonce + 1n }, - request.signature, - ), - request.from, - ); - }); - - it('reverts with valid signature for expired deadline', async function () { - const request = await this.forgeRequest({ deadline: (await time.clock.timestamp()) - 1n }); - - await expect(this.forwarder.execute(request)) - .to.be.revertedWithCustomError(this.forwarder, 'ERC2771ForwarderExpiredRequest') - .withArgs(request.deadline); - }); - - it('reverts with valid signature but mismatched value', async function () { - const request = await this.forgeRequest({ value: 100n }); - - await expect(this.forwarder.execute(request)) - .to.be.revertedWithCustomError(this.forwarder, 'ERC2771ForwarderMismatchedValue') - .withArgs(request.value, 0n); - }); - }); - - it('bubbles out of gas', async function () { - const request = await this.forgeRequest({ - data: this.receiver.interface.encodeFunctionData('mockFunctionOutOfGas'), - gas: 1_000_000n, - }); - - const gasLimit = 100_000n; - await expect(this.forwarder.execute(request, { gasLimit })).to.be.revertedWithoutReason(); - - const { gasUsed } = await ethers.provider - .getBlock('latest') - .then(block => block.getTransaction(0)) - .then(tx => ethers.provider.getTransactionReceipt(tx.hash)); - - expect(gasUsed).to.equal(gasLimit); - }); - - it('bubbles out of gas forced by the relayer', async function () { - const request = await this.forgeRequest(); - - // If there's an incentive behind executing requests, a malicious relayer could grief - // the forwarder by executing requests and providing a top-level call gas limit that - // is too low to successfully finish the request after the 63/64 rule. - - // We set the baseline to the gas limit consumed by a successful request if it was executed - // normally. Note this includes the 21000 buffer that also the relayer will be charged to - // start a request execution. - const estimate = await this.estimateRequest(request); - - // Because the relayer call consumes gas until the `CALL` opcode, the gas left after failing - // the subcall won't enough to finish the top level call (after testing), so we add a - // moderated buffer. - const gasLimit = estimate + 2_000n; - - // The subcall out of gas should be caught by the contract and then bubbled up consuming - // the available gas with an `invalid` opcode. - await expect(this.forwarder.execute(request, { gasLimit })).to.be.revertedWithoutReason(); - - const { gasUsed } = await ethers.provider - .getBlock('latest') - .then(block => block.getTransaction(0)) - .then(tx => ethers.provider.getTransactionReceipt(tx.hash)); - - // We assert that indeed the gas was totally consumed. - expect(gasUsed).to.equal(gasLimit); - }); - }); - - describe('executeBatch', function () { - const requestsValue = requests => sum(...requests.map(request => request.value)); - const requestCount = 3; - const idx = 1; // index that will be tampered with - - beforeEach(async function () { - this.forgeRequests = override => - Promise.all(this.accounts.slice(0, requestCount).map(signer => this.forgeRequest(override, signer))); - this.requests = await this.forgeRequests({ value: 10n }); - this.value = requestsValue(this.requests); - }); - - describe('with valid requests', function () { - it('sanity', async function () { - for (const request of this.requests) { - expect(await this.forwarder.verify(request)).to.be.true; - } - }); - - it('emits events', async function () { - const receipt = this.forwarder.executeBatch(this.requests, this.another, { value: this.value }); - - for (const request of this.requests) { - await expect(receipt) - .to.emit(this.receiver, 'MockFunctionCalled') - .to.emit(this.forwarder, 'ExecutedForwardRequest') - .withArgs(request.from, request.nonce, true); - } - }); - - it('increase nonces', async function () { - await this.forwarder.executeBatch(this.requests, this.another, { value: this.value }); - - for (const request of this.requests) { - expect(await this.forwarder.nonces(request.from)).to.equal(request.nonce + 1n); - } - }); - }); - - describe('with tampered requests', function () { - it('reverts with mismatched value', async function () { - // tamper value of one of the request + resign - this.requests[idx] = await this.forgeRequest({ value: 100n }, this.accounts[1]); - - await expect(this.forwarder.executeBatch(this.requests, this.another, { value: this.value })) - .to.be.revertedWithCustomError(this.forwarder, 'ERC2771ForwarderMismatchedValue') - .withArgs(requestsValue(this.requests), this.value); - }); - - describe('when the refund receiver is the zero address', function () { - beforeEach(function () { - this.refundReceiver = ethers.ZeroAddress; - }); - - it('reverts with at least one valid signature for non-current nonce', async function () { - // Execute first a request - await this.forwarder.execute(this.requests[idx], { value: this.requests[idx].value }); - - // And then fail due to an already used nonce - await expect(this.forwarder.executeBatch(this.requests, this.refundReceiver, { value: this.value })) - .to.be.revertedWithCustomError(this.forwarder, 'ERC2771ForwarderInvalidSigner') - .withArgs( - ethers.verifyTypedData( - this.domain, - this.types, - { ...this.requests[idx], nonce: this.requests[idx].nonce + 1n }, - this.requests[idx].signature, - ), - this.requests[idx].from, - ); - }); - - it('reverts with at least one valid signature for expired deadline', async function () { - this.requests[idx] = await this.forgeRequest( - { ...this.requests[idx], deadline: (await time.clock.timestamp()) - 1n }, - this.accounts[1], - ); - - await expect(this.forwarder.executeBatch(this.requests, this.refundReceiver, { value: this.amount })) - .to.be.revertedWithCustomError(this.forwarder, 'ERC2771ForwarderExpiredRequest') - .withArgs(this.requests[idx].deadline); - }); - }); - - describe('when the refund receiver is a known address', function () { - beforeEach(async function () { - this.initialRefundReceiverBalance = await ethers.provider.getBalance(this.refundReceiver); - this.initialTamperedRequestNonce = await this.forwarder.nonces(this.requests[idx].from); - }); - - it('ignores a request with a valid signature for non-current nonce', async function () { - // Execute first a request - await this.forwarder.execute(this.requests[idx], { value: this.requests[idx].value }); - this.initialTamperedRequestNonce++; // Should be already incremented by the individual `execute` - - // And then ignore the same request in a batch due to an already used nonce - const events = await this.forwarder - .executeBatch(this.requests, this.refundReceiver, { value: this.value }) - .then(tx => tx.wait()) - .then(receipt => - receipt.logs.filter( - log => log?.fragment?.type == 'event' && log?.fragment?.name == 'ExecutedForwardRequest', - ), - ); - - expect(events).to.have.lengthOf(this.requests.length - 1); - }); - - it('ignores a request with a valid signature for expired deadline', async function () { - this.requests[idx] = await this.forgeRequest( - { ...this.requests[idx], deadline: (await time.clock.timestamp()) - 1n }, - this.accounts[1], - ); - - const events = await this.forwarder - .executeBatch(this.requests, this.refundReceiver, { value: this.value }) - .then(tx => tx.wait()) - .then(receipt => - receipt.logs.filter( - log => log?.fragment?.type == 'event' && log?.fragment?.name == 'ExecutedForwardRequest', - ), - ); - - expect(events).to.have.lengthOf(this.requests.length - 1); - }); - - afterEach(async function () { - // The invalid request value was refunded - expect(await ethers.provider.getBalance(this.refundReceiver)).to.equal( - this.initialRefundReceiverBalance + this.requests[idx].value, - ); - - // The invalid request from's nonce was not incremented - expect(await this.forwarder.nonces(this.requests[idx].from)).to.equal(this.initialTamperedRequestNonce); - }); - }); - - it('bubbles out of gas', async function () { - this.requests[idx] = await this.forgeRequest({ - data: this.receiver.interface.encodeFunctionData('mockFunctionOutOfGas'), - gas: 1_000_000n, - }); - - const gasLimit = 300_000n; - await expect( - this.forwarder.executeBatch(this.requests, ethers.ZeroAddress, { - gasLimit, - value: requestsValue(this.requests), - }), - ).to.be.revertedWithoutReason(); - - const { gasUsed } = await ethers.provider - .getBlock('latest') - .then(block => block.getTransaction(0)) - .then(tx => ethers.provider.getTransactionReceipt(tx.hash)); - - expect(gasUsed).to.equal(gasLimit); - }); - - it('bubbles out of gas forced by the relayer', async function () { - // Similarly to the single execute, a malicious relayer could grief requests. - - // We estimate until the selected request as if they were executed normally - const estimate = await Promise.all(this.requests.slice(0, idx + 1).map(this.estimateRequest)).then(gas => - sum(...gas), - ); - - // We add a Buffer to account for all the gas that's used before the selected call. - // Note is slightly bigger because the selected request is not the index 0 and it affects - // the buffer needed. - const gasLimit = estimate + 10_000n; - - // The subcall out of gas should be caught by the contract and then bubbled up consuming - // the available gas with an `invalid` opcode. - await expect( - this.forwarder.executeBatch(this.requests, ethers.ZeroAddress, { - gasLimit, - value: requestsValue(this.requests), - }), - ).to.be.revertedWithoutReason(); - - const { gasUsed } = await ethers.provider - .getBlock('latest') - .then(block => block.getTransaction(0)) - .then(tx => ethers.provider.getTransactionReceipt(tx.hash)); - - // We assert that indeed the gas was totally consumed. - expect(gasUsed).to.equal(gasLimit); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/Clones.behaviour.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/Clones.behaviour.js deleted file mode 100644 index dcc6206653..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/Clones.behaviour.js +++ /dev/null @@ -1,160 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); - -module.exports = function shouldBehaveLikeClone() { - const assertProxyInitialization = function ({ value, balance }) { - it('initializes the proxy', async function () { - const dummy = await ethers.getContractAt('DummyImplementation', this.proxy); - expect(await dummy.value()).to.equal(value); - }); - - it('has expected balance', async function () { - expect(await ethers.provider.getBalance(this.proxy)).to.equal(balance); - }); - }; - - describe('construct with value', function () { - const value = 10n; - - it('factory has enough balance', async function () { - await this.deployer.sendTransaction({ to: this.factory, value }); - - const instance = await this.createClone({ deployValue: value }); - await expect(instance.deploymentTransaction()).to.changeEtherBalances([this.factory, instance], [-value, value]); - - expect(await ethers.provider.getBalance(instance)).to.equal(value); - }); - - it('factory does not have enough balance', async function () { - await expect(this.createClone({ deployValue: value })) - .to.be.revertedWithCustomError(this.factory, 'InsufficientBalance') - .withArgs(0n, value); - }); - }); - - describe('initialization without parameters', function () { - describe('non payable', function () { - const expectedInitializedValue = 10n; - - beforeEach(async function () { - this.initializeData = await this.implementation.interface.encodeFunctionData('initializeNonPayable'); - }); - - describe('when not sending balance', function () { - beforeEach('creating proxy', async function () { - this.proxy = await this.createClone({ initData: this.initializeData }); - }); - - assertProxyInitialization({ - value: expectedInitializedValue, - balance: 0, - }); - }); - - describe('when sending some balance', function () { - const value = 10n ** 6n; - - it('reverts', async function () { - await expect(this.createClone({ initData: this.initializeData, initValue: value })).to.be.reverted; - }); - }); - }); - - describe('payable', function () { - const expectedInitializedValue = 100n; - - beforeEach(async function () { - this.initializeData = await this.implementation.interface.encodeFunctionData('initializePayable'); - }); - - describe('when not sending balance', function () { - beforeEach('creating proxy', async function () { - this.proxy = await this.createClone({ initData: this.initializeData }); - }); - - assertProxyInitialization({ - value: expectedInitializedValue, - balance: 0, - }); - }); - - describe('when sending some balance', function () { - const value = 10n ** 6n; - - beforeEach('creating proxy', async function () { - this.proxy = await this.createClone({ initData: this.initializeData, initValue: value }); - }); - - assertProxyInitialization({ - value: expectedInitializedValue, - balance: value, - }); - }); - }); - }); - - describe('initialization with parameters', function () { - describe('non payable', function () { - const expectedInitializedValue = 10n; - - beforeEach(async function () { - this.initializeData = await this.implementation.interface.encodeFunctionData('initializeNonPayableWithValue', [ - expectedInitializedValue, - ]); - }); - - describe('when not sending balance', function () { - beforeEach('creating proxy', async function () { - this.proxy = await this.createClone({ initData: this.initializeData }); - }); - - assertProxyInitialization({ - value: expectedInitializedValue, - balance: 0, - }); - }); - - describe('when sending some balance', function () { - const value = 10n ** 6n; - - it('reverts', async function () { - await expect(this.createClone({ initData: this.initializeData, initValue: value })).to.be.reverted; - }); - }); - }); - - describe('payable', function () { - const expectedInitializedValue = 42n; - - beforeEach(function () { - this.initializeData = this.implementation.interface.encodeFunctionData('initializePayableWithValue', [ - expectedInitializedValue, - ]); - }); - - describe('when not sending balance', function () { - beforeEach('creating proxy', async function () { - this.proxy = await this.createClone({ initData: this.initializeData }); - }); - - assertProxyInitialization({ - value: expectedInitializedValue, - balance: 0, - }); - }); - - describe('when sending some balance', function () { - const value = 10n ** 6n; - - beforeEach('creating proxy', async function () { - this.proxy = await this.createClone({ initData: this.initializeData, initValue: value }); - }); - - assertProxyInitialization({ - value: expectedInitializedValue, - balance: value, - }); - }); - }); - }); -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/Clones.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/Clones.t.sol deleted file mode 100644 index e589ba9067..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/Clones.t.sol +++ /dev/null @@ -1,91 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {Clones} from "@openzeppelin/contracts/proxy/Clones.sol"; - -contract ClonesTest is Test { - function getNumber() external pure returns (uint256) { - return 42; - } - - function testSymbolicPredictDeterministicAddressSpillage(address implementation, bytes32 salt) public { - address predicted = Clones.predictDeterministicAddress(implementation, salt); - bytes32 spillage; - assembly ("memory-safe") { - spillage := and(predicted, 0xffffffffffffffffffffffff0000000000000000000000000000000000000000) - } - assertEq(spillage, bytes32(0)); - } - - function testSymbolicPredictDeterministicAddressWithImmutableArgsSpillage( - address implementation, - bytes32 salt, - bytes memory args - ) public { - vm.assume(args.length < 0xbfd3); - - address predicted = Clones.predictDeterministicAddressWithImmutableArgs(implementation, args, salt); - bytes32 spillage; - /// @solidity memory-safe-assembly - assembly { - spillage := and(predicted, 0xffffffffffffffffffffffff0000000000000000000000000000000000000000) - } - assertEq(spillage, bytes32(0)); - } - - function testCloneDirty() external { - address cloneClean = Clones.clone(address(this)); - address cloneDirty = Clones.clone(_dirty(address(this))); - - // both clones have the same code - assertEq(cloneClean.code, cloneDirty.code); - - // both clones behave as expected - assertEq(ClonesTest(cloneClean).getNumber(), this.getNumber()); - assertEq(ClonesTest(cloneDirty).getNumber(), this.getNumber()); - } - - function testCloneDeterministicDirty(bytes32 salt) external { - address cloneClean = Clones.cloneDeterministic(address(this), salt); - address cloneDirty = Clones.cloneDeterministic(_dirty(address(this)), ~salt); - - // both clones have the same code - assertEq(cloneClean.code, cloneDirty.code); - - // both clones behave as expected - assertEq(ClonesTest(cloneClean).getNumber(), this.getNumber()); - assertEq(ClonesTest(cloneDirty).getNumber(), this.getNumber()); - } - - function testPredictDeterministicAddressDirty(bytes32 salt) external { - address predictClean = Clones.predictDeterministicAddress(address(this), salt); - address predictDirty = Clones.predictDeterministicAddress(_dirty(address(this)), salt); - - //prediction should be similar - assertEq(predictClean, predictDirty); - } - - function testFetchCloneArgs(bytes memory args, bytes32 salt) external { - vm.assume(args.length < 0xbfd3); - - address instance1 = Clones.cloneWithImmutableArgs(address(this), args); - address instance2 = Clones.cloneDeterministicWithImmutableArgs(address(this), args, salt); - - // both clones have the same code - assertEq(instance1.code, instance2.code); - - // both clones behave as expected and args can be fetched - assertEq(ClonesTest(instance1).getNumber(), this.getNumber()); - assertEq(ClonesTest(instance2).getNumber(), this.getNumber()); - assertEq(Clones.fetchCloneArgs(instance1), args); - assertEq(Clones.fetchCloneArgs(instance2), args); - } - - function _dirty(address input) private pure returns (address output) { - assembly ("memory-safe") { - output := or(input, shl(160, not(0))) - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/Clones.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/Clones.test.js deleted file mode 100644 index 0706c6f834..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/Clones.test.js +++ /dev/null @@ -1,175 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { generators } = require('../helpers/random'); - -const shouldBehaveLikeClone = require('./Clones.behaviour'); - -const cloneInitCode = (instance, args = undefined) => - args - ? ethers.concat([ - '0x61', - ethers.toBeHex(0x2d + ethers.getBytes(args).length, 2), - '0x3d81600a3d39f3363d3d373d3d3d363d73', - instance.target ?? instance.address ?? instance, - '0x5af43d82803e903d91602b57fd5bf3', - args, - ]) - : ethers.concat([ - '0x3d602d80600a3d3981f3363d3d373d3d3d363d73', - instance.target ?? instance.address ?? instance, - '0x5af43d82803e903d91602b57fd5bf3', - ]); - -async function fixture() { - const [deployer] = await ethers.getSigners(); - - const factory = await ethers.deployContract('$Clones'); - const implementation = await ethers.deployContract('DummyImplementation'); - - const newClone = - args => - async (opts = {}) => { - const clone = await (args - ? factory.$cloneWithImmutableArgs.staticCall(implementation, args) - : factory.$clone.staticCall(implementation) - ).then(address => implementation.attach(address)); - const tx = await (args - ? opts.deployValue - ? factory.$cloneWithImmutableArgs(implementation, args, ethers.Typed.uint256(opts.deployValue)) - : factory.$cloneWithImmutableArgs(implementation, args) - : opts.deployValue - ? factory.$clone(implementation, ethers.Typed.uint256(opts.deployValue)) - : factory.$clone(implementation)); - if (opts.initData || opts.initValue) { - await deployer.sendTransaction({ to: clone, value: opts.initValue ?? 0n, data: opts.initData ?? '0x' }); - } - return Object.assign(clone, { deploymentTransaction: () => tx }); - }; - - const newCloneDeterministic = - args => - async (opts = {}) => { - const salt = opts.salt ?? ethers.randomBytes(32); - const clone = await (args - ? factory.$cloneDeterministicWithImmutableArgs.staticCall(implementation, args, salt) - : factory.$cloneDeterministic.staticCall(implementation, salt) - ).then(address => implementation.attach(address)); - const tx = await (args - ? opts.deployValue - ? factory.$cloneDeterministicWithImmutableArgs( - implementation, - args, - salt, - ethers.Typed.uint256(opts.deployValue), - ) - : factory.$cloneDeterministicWithImmutableArgs(implementation, args, salt) - : opts.deployValue - ? factory.$cloneDeterministic(implementation, salt, ethers.Typed.uint256(opts.deployValue)) - : factory.$cloneDeterministic(implementation, salt)); - if (opts.initData || opts.initValue) { - await deployer.sendTransaction({ to: clone, value: opts.initValue ?? 0n, data: opts.initData ?? '0x' }); - } - return Object.assign(clone, { deploymentTransaction: () => tx }); - }; - - return { deployer, factory, implementation, newClone, newCloneDeterministic }; -} - -describe('Clones', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - for (const args of [undefined, '0x', '0x11223344']) { - describe(args ? `with immutable args: ${args}` : 'without immutable args', function () { - describe('clone', function () { - beforeEach(async function () { - this.createClone = this.newClone(args); - }); - - shouldBehaveLikeClone(); - - it('get immutable arguments', async function () { - const instance = await this.createClone(); - expect(await this.factory.$fetchCloneArgs(instance)).to.equal(args ?? '0x'); - }); - }); - - describe('cloneDeterministic', function () { - beforeEach(async function () { - this.createClone = this.newCloneDeterministic(args); - }); - - shouldBehaveLikeClone(); - - it('get immutable arguments', async function () { - const instance = await this.createClone(); - expect(await this.factory.$fetchCloneArgs(instance)).to.equal(args ?? '0x'); - }); - - it('revert if address already used', async function () { - const salt = ethers.randomBytes(32); - - const deployClone = () => - args - ? this.factory.$cloneDeterministicWithImmutableArgs(this.implementation, args, salt) - : this.factory.$cloneDeterministic(this.implementation, salt); - - // deploy once - await expect(deployClone()).to.not.be.reverted; - - // deploy twice - await expect(deployClone()).to.be.revertedWithCustomError(this.factory, 'FailedDeployment'); - }); - - it('address prediction', async function () { - const salt = ethers.randomBytes(32); - - const expected = ethers.getCreate2Address( - this.factory.target, - salt, - ethers.keccak256(cloneInitCode(this.implementation, args)), - ); - - if (args) { - const predicted = await this.factory.$predictDeterministicAddressWithImmutableArgs( - this.implementation, - args, - salt, - ); - expect(predicted).to.equal(expected); - - await expect(this.factory.$cloneDeterministicWithImmutableArgs(this.implementation, args, salt)) - .to.emit(this.factory, 'return$cloneDeterministicWithImmutableArgs_address_bytes_bytes32') - .withArgs(predicted); - } else { - const predicted = await this.factory.$predictDeterministicAddress(this.implementation, salt); - expect(predicted).to.equal(expected); - - await expect(this.factory.$cloneDeterministic(this.implementation, salt)) - .to.emit(this.factory, 'return$cloneDeterministic_address_bytes32') - .withArgs(predicted); - } - }); - }); - }); - } - - it('EIP-170 limit on immutable args', async function () { - // EIP-170 limits the contract code size to 0x6000 - // This limits the length of immutable args to 0x5fd3 - const args = generators.hexBytes(0x5fd4); - const salt = ethers.randomBytes(32); - - await expect( - this.factory.$predictDeterministicAddressWithImmutableArgs(this.implementation, args, salt), - ).to.be.revertedWithCustomError(this.factory, 'CloneArgumentsTooLong'); - - await expect(this.factory.$cloneWithImmutableArgs(this.implementation, args)).to.be.revertedWithCustomError( - this.factory, - 'CloneArgumentsTooLong', - ); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/ERC1967/ERC1967Proxy.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/ERC1967/ERC1967Proxy.test.js deleted file mode 100644 index b22280046e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/ERC1967/ERC1967Proxy.test.js +++ /dev/null @@ -1,23 +0,0 @@ -const { ethers } = require('hardhat'); - -const shouldBehaveLikeProxy = require('../Proxy.behaviour'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const fixture = async () => { - const [nonContractAddress] = await ethers.getSigners(); - - const implementation = await ethers.deployContract('DummyImplementation'); - - const createProxy = (implementation, initData, opts) => - ethers.deployContract('ERC1967Proxy', [implementation, initData], opts); - - return { nonContractAddress, implementation, createProxy }; -}; - -describe('ERC1967Proxy', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeProxy(); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/ERC1967/ERC1967Utils.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/ERC1967/ERC1967Utils.test.js deleted file mode 100644 index 089032498e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/ERC1967/ERC1967Utils.test.js +++ /dev/null @@ -1,162 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { getAddressInSlot, setSlot, ImplementationSlot, AdminSlot, BeaconSlot } = require('../../helpers/storage'); - -async function fixture() { - const [, admin, anotherAccount] = await ethers.getSigners(); - - const utils = await ethers.deployContract('$ERC1967Utils'); - const v1 = await ethers.deployContract('DummyImplementation'); - const v2 = await ethers.deployContract('CallReceiverMock'); - - return { admin, anotherAccount, utils, v1, v2 }; -} - -describe('ERC1967Utils', function () { - beforeEach('setup', async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('IMPLEMENTATION_SLOT', function () { - beforeEach('set v1 implementation', async function () { - await setSlot(this.utils, ImplementationSlot, this.v1); - }); - - describe('getImplementation', function () { - it('returns current implementation and matches implementation slot value', async function () { - expect(await this.utils.$getImplementation()).to.equal(this.v1); - expect(await getAddressInSlot(this.utils, ImplementationSlot)).to.equal(this.v1); - }); - }); - - describe('upgradeToAndCall', function () { - it('sets implementation in storage and emits event', async function () { - const newImplementation = this.v2; - const tx = await this.utils.$upgradeToAndCall(newImplementation, '0x'); - - expect(await getAddressInSlot(this.utils, ImplementationSlot)).to.equal(newImplementation); - await expect(tx).to.emit(this.utils, 'Upgraded').withArgs(newImplementation); - }); - - it('reverts when implementation does not contain code', async function () { - await expect(this.utils.$upgradeToAndCall(this.anotherAccount, '0x')) - .to.be.revertedWithCustomError(this.utils, 'ERC1967InvalidImplementation') - .withArgs(this.anotherAccount); - }); - - describe('when data is empty', function () { - it('reverts when value is sent', async function () { - await expect(this.utils.$upgradeToAndCall(this.v2, '0x', { value: 1 })).to.be.revertedWithCustomError( - this.utils, - 'ERC1967NonPayable', - ); - }); - }); - - describe('when data is not empty', function () { - it('delegates a call to the new implementation', async function () { - const initializeData = this.v2.interface.encodeFunctionData('mockFunction'); - const tx = await this.utils.$upgradeToAndCall(this.v2, initializeData); - await expect(tx).to.emit(await ethers.getContractAt('CallReceiverMock', this.utils), 'MockFunctionCalled'); - }); - }); - }); - }); - - describe('ADMIN_SLOT', function () { - beforeEach('set admin', async function () { - await setSlot(this.utils, AdminSlot, this.admin); - }); - - describe('getAdmin', function () { - it('returns current admin and matches admin slot value', async function () { - expect(await this.utils.$getAdmin()).to.equal(this.admin); - expect(await getAddressInSlot(this.utils, AdminSlot)).to.equal(this.admin); - }); - }); - - describe('changeAdmin', function () { - it('sets admin in storage and emits event', async function () { - const newAdmin = this.anotherAccount; - const tx = await this.utils.$changeAdmin(newAdmin); - - expect(await getAddressInSlot(this.utils, AdminSlot)).to.equal(newAdmin); - await expect(tx).to.emit(this.utils, 'AdminChanged').withArgs(this.admin, newAdmin); - }); - - it('reverts when setting the address zero as admin', async function () { - await expect(this.utils.$changeAdmin(ethers.ZeroAddress)) - .to.be.revertedWithCustomError(this.utils, 'ERC1967InvalidAdmin') - .withArgs(ethers.ZeroAddress); - }); - }); - }); - - describe('BEACON_SLOT', function () { - beforeEach('set beacon', async function () { - this.beacon = await ethers.deployContract('UpgradeableBeaconMock', [this.v1]); - await setSlot(this.utils, BeaconSlot, this.beacon); - }); - - describe('getBeacon', function () { - it('returns current beacon and matches beacon slot value', async function () { - expect(await this.utils.$getBeacon()).to.equal(this.beacon); - expect(await getAddressInSlot(this.utils, BeaconSlot)).to.equal(this.beacon); - }); - }); - - describe('upgradeBeaconToAndCall', function () { - it('sets beacon in storage and emits event', async function () { - const newBeacon = await ethers.deployContract('UpgradeableBeaconMock', [this.v2]); - const tx = await this.utils.$upgradeBeaconToAndCall(newBeacon, '0x'); - - expect(await getAddressInSlot(this.utils, BeaconSlot)).to.equal(newBeacon); - await expect(tx).to.emit(this.utils, 'BeaconUpgraded').withArgs(newBeacon); - }); - - it('reverts when beacon does not contain code', async function () { - await expect(this.utils.$upgradeBeaconToAndCall(this.anotherAccount, '0x')) - .to.be.revertedWithCustomError(this.utils, 'ERC1967InvalidBeacon') - .withArgs(this.anotherAccount); - }); - - it("reverts when beacon's implementation does not contain code", async function () { - const newBeacon = await ethers.deployContract('UpgradeableBeaconMock', [this.anotherAccount]); - - await expect(this.utils.$upgradeBeaconToAndCall(newBeacon, '0x')) - .to.be.revertedWithCustomError(this.utils, 'ERC1967InvalidImplementation') - .withArgs(this.anotherAccount); - }); - - describe('when data is empty', function () { - it('reverts when value is sent', async function () { - const newBeacon = await ethers.deployContract('UpgradeableBeaconMock', [this.v2]); - await expect(this.utils.$upgradeBeaconToAndCall(newBeacon, '0x', { value: 1 })).to.be.revertedWithCustomError( - this.utils, - 'ERC1967NonPayable', - ); - }); - }); - - describe('when data is not empty', function () { - it('delegates a call to the new implementation', async function () { - const initializeData = this.v2.interface.encodeFunctionData('mockFunction'); - const newBeacon = await ethers.deployContract('UpgradeableBeaconMock', [this.v2]); - const tx = await this.utils.$upgradeBeaconToAndCall(newBeacon, initializeData); - await expect(tx).to.emit(await ethers.getContractAt('CallReceiverMock', this.utils), 'MockFunctionCalled'); - }); - }); - - describe('reentrant beacon implementation() call', function () { - it('sees the new beacon implementation', async function () { - const newBeacon = await ethers.deployContract('UpgradeableBeaconReentrantMock'); - await expect(this.utils.$upgradeBeaconToAndCall(newBeacon, '0x')) - .to.be.revertedWithCustomError(newBeacon, 'BeaconProxyBeaconSlotAddress') - .withArgs(newBeacon); - }); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/Proxy.behaviour.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/Proxy.behaviour.js deleted file mode 100644 index f459c09262..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/Proxy.behaviour.js +++ /dev/null @@ -1,185 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); - -const { getAddressInSlot, ImplementationSlot } = require('../helpers/storage'); - -module.exports = function shouldBehaveLikeProxy() { - it('cannot be initialized with a non-contract address', async function () { - const initializeData = '0x'; - const contractFactory = await ethers.getContractFactory('ERC1967Proxy'); - await expect(this.createProxy(this.nonContractAddress, initializeData)) - .to.be.revertedWithCustomError(contractFactory, 'ERC1967InvalidImplementation') - .withArgs(this.nonContractAddress); - }); - - const assertProxyInitialization = function ({ value, balance }) { - it('sets the implementation address', async function () { - expect(await getAddressInSlot(this.proxy, ImplementationSlot)).to.equal(this.implementation); - }); - - it('initializes the proxy', async function () { - const dummy = this.implementation.attach(this.proxy); - expect(await dummy.value()).to.equal(value); - }); - - it('has expected balance', async function () { - expect(await ethers.provider.getBalance(this.proxy)).to.equal(balance); - }); - }; - - describe('without initialization', function () { - const initializeData = '0x'; - - describe('when not sending balance', function () { - beforeEach('creating proxy', async function () { - this.proxy = await this.createProxy(this.implementation, initializeData); - }); - - assertProxyInitialization({ value: 0n, balance: 0n }); - }); - - describe('when sending some balance', function () { - const value = 10n ** 5n; - - it('reverts', async function () { - await expect(this.createProxy(this.implementation, initializeData, { value })).to.be.reverted; - }); - }); - }); - - describe('initialization without parameters', function () { - describe('non payable', function () { - const expectedInitializedValue = 10n; - - beforeEach(function () { - this.initializeData = this.implementation.interface.encodeFunctionData('initializeNonPayable'); - }); - - describe('when not sending balance', function () { - beforeEach('creating proxy', async function () { - this.proxy = await this.createProxy(this.implementation, this.initializeData); - }); - - assertProxyInitialization({ - value: expectedInitializedValue, - balance: 0n, - }); - }); - - describe('when sending some balance', function () { - const value = 10n ** 5n; - - it('reverts', async function () { - await expect(this.createProxy(this.implementation, this.initializeData, { value })).to.be.reverted; - }); - }); - }); - - describe('payable', function () { - const expectedInitializedValue = 100n; - - beforeEach(function () { - this.initializeData = this.implementation.interface.encodeFunctionData('initializePayable'); - }); - - describe('when not sending balance', function () { - beforeEach('creating proxy', async function () { - this.proxy = await this.createProxy(this.implementation, this.initializeData); - }); - - assertProxyInitialization({ - value: expectedInitializedValue, - balance: 0n, - }); - }); - - describe('when sending some balance', function () { - const value = 10e5; - - beforeEach('creating proxy', async function () { - this.proxy = await this.createProxy(this.implementation, this.initializeData, { value }); - }); - - assertProxyInitialization({ - value: expectedInitializedValue, - balance: value, - }); - }); - }); - }); - - describe('initialization with parameters', function () { - describe('non payable', function () { - const expectedInitializedValue = 10n; - - beforeEach(function () { - this.initializeData = this.implementation.interface.encodeFunctionData('initializeNonPayableWithValue', [ - expectedInitializedValue, - ]); - }); - - describe('when not sending balance', function () { - beforeEach('creating proxy', async function () { - this.proxy = await this.createProxy(this.implementation, this.initializeData); - }); - - assertProxyInitialization({ - value: expectedInitializedValue, - balance: 0, - }); - }); - - describe('when sending some balance', function () { - const value = 10e5; - - it('reverts', async function () { - await expect(this.createProxy(this.implementation, this.initializeData, { value })).to.be.reverted; - }); - }); - }); - - describe('payable', function () { - const expectedInitializedValue = 42n; - - beforeEach(function () { - this.initializeData = this.implementation.interface.encodeFunctionData('initializePayableWithValue', [ - expectedInitializedValue, - ]); - }); - - describe('when not sending balance', function () { - beforeEach('creating proxy', async function () { - this.proxy = await this.createProxy(this.implementation, this.initializeData); - }); - - assertProxyInitialization({ - value: expectedInitializedValue, - balance: 0n, - }); - }); - - describe('when sending some balance', function () { - const value = 10n ** 5n; - - beforeEach('creating proxy', async function () { - this.proxy = await this.createProxy(this.implementation, this.initializeData, { value }); - }); - - assertProxyInitialization({ - value: expectedInitializedValue, - balance: value, - }); - }); - }); - - describe('reverting initialization', function () { - beforeEach(function () { - this.initializeData = this.implementation.interface.encodeFunctionData('reverts'); - }); - - it('reverts', async function () { - await expect(this.createProxy(this.implementation, this.initializeData)).to.be.reverted; - }); - }); - }); -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/beacon/BeaconProxy.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/beacon/BeaconProxy.test.js deleted file mode 100644 index 0a0878446a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/beacon/BeaconProxy.test.js +++ /dev/null @@ -1,141 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { getAddressInSlot, BeaconSlot } = require('../../helpers/storage'); - -async function fixture() { - const [admin, other] = await ethers.getSigners(); - - const v1 = await ethers.deployContract('DummyImplementation'); - const v2 = await ethers.deployContract('DummyImplementationV2'); - const factory = await ethers.getContractFactory('BeaconProxy'); - const beacon = await ethers.deployContract('UpgradeableBeacon', [v1, admin]); - - const newBeaconProxy = (beacon, data, opts = {}) => factory.deploy(beacon, data, opts); - - return { admin, other, factory, beacon, v1, v2, newBeaconProxy }; -} - -describe('BeaconProxy', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('bad beacon is not accepted', function () { - it('non-contract beacon', async function () { - const notBeacon = this.other; - - await expect(this.newBeaconProxy(notBeacon, '0x')) - .to.be.revertedWithCustomError(this.factory, 'ERC1967InvalidBeacon') - .withArgs(notBeacon); - }); - - it('non-compliant beacon', async function () { - const badBeacon = await ethers.deployContract('BadBeaconNoImpl'); - - // BadBeaconNoImpl does not provide `implementation()` has no fallback. - // This causes ERC1967Utils._setBeacon to revert. - await expect(this.newBeaconProxy(badBeacon, '0x')).to.be.revertedWithoutReason(); - }); - - it('non-contract implementation', async function () { - const badBeacon = await ethers.deployContract('BadBeaconNotContract'); - - await expect(this.newBeaconProxy(badBeacon, '0x')) - .to.be.revertedWithCustomError(this.factory, 'ERC1967InvalidImplementation') - .withArgs(await badBeacon.implementation()); - }); - }); - - describe('initialization', function () { - async function assertInitialized({ value, balance }) { - const beaconAddress = await getAddressInSlot(this.proxy, BeaconSlot); - expect(beaconAddress).to.equal(this.beacon); - - const dummy = this.v1.attach(this.proxy); - expect(await dummy.value()).to.equal(value); - - expect(await ethers.provider.getBalance(this.proxy)).to.equal(balance); - } - - it('no initialization', async function () { - this.proxy = await this.newBeaconProxy(this.beacon, '0x'); - await assertInitialized.bind(this)({ value: 0n, balance: 0n }); - }); - - it('non-payable initialization', async function () { - const value = 55n; - const data = this.v1.interface.encodeFunctionData('initializeNonPayableWithValue', [value]); - - this.proxy = await this.newBeaconProxy(this.beacon, data); - await assertInitialized.bind(this)({ value, balance: 0n }); - }); - - it('payable initialization', async function () { - const value = 55n; - const data = this.v1.interface.encodeFunctionData('initializePayableWithValue', [value]); - const balance = 100n; - - this.proxy = await this.newBeaconProxy(this.beacon, data, { value: balance }); - await assertInitialized.bind(this)({ value, balance }); - }); - - it('reverting initialization due to value', async function () { - await expect(this.newBeaconProxy(this.beacon, '0x', { value: 1n })).to.be.revertedWithCustomError( - this.factory, - 'ERC1967NonPayable', - ); - }); - - it('reverting initialization function', async function () { - const data = this.v1.interface.encodeFunctionData('reverts'); - await expect(this.newBeaconProxy(this.beacon, data)).to.be.revertedWith('DummyImplementation reverted'); - }); - }); - - describe('upgrade', function () { - it('upgrade a proxy by upgrading its beacon', async function () { - const value = 10n; - const data = this.v1.interface.encodeFunctionData('initializeNonPayableWithValue', [value]); - const proxy = await this.newBeaconProxy(this.beacon, data).then(instance => this.v1.attach(instance)); - - // test initial values - expect(await proxy.value()).to.equal(value); - - // test initial version - expect(await proxy.version()).to.equal('V1'); - - // upgrade beacon - await this.beacon.connect(this.admin).upgradeTo(this.v2); - - // test upgraded version - expect(await proxy.version()).to.equal('V2'); - }); - - it('upgrade 2 proxies by upgrading shared beacon', async function () { - const value1 = 10n; - const data1 = this.v1.interface.encodeFunctionData('initializeNonPayableWithValue', [value1]); - const proxy1 = await this.newBeaconProxy(this.beacon, data1).then(instance => this.v1.attach(instance)); - - const value2 = 42n; - const data2 = this.v1.interface.encodeFunctionData('initializeNonPayableWithValue', [value2]); - const proxy2 = await this.newBeaconProxy(this.beacon, data2).then(instance => this.v1.attach(instance)); - - // test initial values - expect(await proxy1.value()).to.equal(value1); - expect(await proxy2.value()).to.equal(value2); - - // test initial version - expect(await proxy1.version()).to.equal('V1'); - expect(await proxy2.version()).to.equal('V1'); - - // upgrade beacon - await this.beacon.connect(this.admin).upgradeTo(this.v2); - - // test upgraded version - expect(await proxy1.version()).to.equal('V2'); - expect(await proxy2.version()).to.equal('V2'); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/beacon/UpgradeableBeacon.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/beacon/UpgradeableBeacon.test.js deleted file mode 100644 index 2da7d0a273..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/beacon/UpgradeableBeacon.test.js +++ /dev/null @@ -1,55 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -async function fixture() { - const [admin, other] = await ethers.getSigners(); - - const v1 = await ethers.deployContract('Implementation1'); - const v2 = await ethers.deployContract('Implementation2'); - const beacon = await ethers.deployContract('UpgradeableBeacon', [v1, admin]); - - return { admin, other, beacon, v1, v2 }; -} - -describe('UpgradeableBeacon', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('cannot be created with non-contract implementation', async function () { - await expect(ethers.deployContract('UpgradeableBeacon', [this.other, this.admin])) - .to.be.revertedWithCustomError(this.beacon, 'BeaconInvalidImplementation') - .withArgs(this.other); - }); - - describe('once deployed', function () { - it('emits Upgraded event to the first implementation', async function () { - await expect(this.beacon.deploymentTransaction()).to.emit(this.beacon, 'Upgraded').withArgs(this.v1); - }); - - it('returns implementation', async function () { - expect(await this.beacon.implementation()).to.equal(this.v1); - }); - - it('can be upgraded by the admin', async function () { - await expect(this.beacon.connect(this.admin).upgradeTo(this.v2)) - .to.emit(this.beacon, 'Upgraded') - .withArgs(this.v2); - - expect(await this.beacon.implementation()).to.equal(this.v2); - }); - - it('cannot be upgraded to a non-contract', async function () { - await expect(this.beacon.connect(this.admin).upgradeTo(this.other)) - .to.be.revertedWithCustomError(this.beacon, 'BeaconInvalidImplementation') - .withArgs(this.other); - }); - - it('cannot be upgraded by other account', async function () { - await expect(this.beacon.connect(this.other).upgradeTo(this.v2)) - .to.be.revertedWithCustomError(this.beacon, 'OwnableUnauthorizedAccount') - .withArgs(this.other); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/transparent/ProxyAdmin.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/transparent/ProxyAdmin.test.js deleted file mode 100644 index df430d46ae..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/transparent/ProxyAdmin.test.js +++ /dev/null @@ -1,82 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { getAddressInSlot, ImplementationSlot } = require('../../helpers/storage'); - -async function fixture() { - const [admin, other] = await ethers.getSigners(); - - const v1 = await ethers.deployContract('DummyImplementation'); - const v2 = await ethers.deployContract('DummyImplementationV2'); - - const proxy = await ethers - .deployContract('TransparentUpgradeableProxy', [v1, admin, '0x']) - .then(instance => ethers.getContractAt('ITransparentUpgradeableProxy', instance)); - - const proxyAdmin = await ethers.getContractAt( - 'ProxyAdmin', - ethers.getCreateAddress({ from: proxy.target, nonce: 1n }), - ); - - return { admin, other, v1, v2, proxy, proxyAdmin }; -} - -describe('ProxyAdmin', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('has an owner', async function () { - expect(await this.proxyAdmin.owner()).to.equal(this.admin); - }); - - it('has an interface version', async function () { - expect(await this.proxyAdmin.UPGRADE_INTERFACE_VERSION()).to.equal('5.0.0'); - }); - - describe('without data', function () { - describe('with unauthorized account', function () { - it('fails to upgrade', async function () { - await expect(this.proxyAdmin.connect(this.other).upgradeAndCall(this.proxy, this.v2, '0x')) - .to.be.revertedWithCustomError(this.proxyAdmin, 'OwnableUnauthorizedAccount') - .withArgs(this.other); - }); - }); - - describe('with authorized account', function () { - it('upgrades implementation', async function () { - await this.proxyAdmin.connect(this.admin).upgradeAndCall(this.proxy, this.v2, '0x'); - expect(await getAddressInSlot(this.proxy, ImplementationSlot)).to.equal(this.v2); - }); - }); - }); - - describe('with data', function () { - describe('with unauthorized account', function () { - it('fails to upgrade', async function () { - const data = this.v1.interface.encodeFunctionData('initializeNonPayableWithValue', [1337n]); - await expect(this.proxyAdmin.connect(this.other).upgradeAndCall(this.proxy, this.v2, data)) - .to.be.revertedWithCustomError(this.proxyAdmin, 'OwnableUnauthorizedAccount') - .withArgs(this.other); - }); - }); - - describe('with authorized account', function () { - describe('with invalid callData', function () { - it('fails to upgrade', async function () { - const data = '0x12345678'; - await expect(this.proxyAdmin.connect(this.admin).upgradeAndCall(this.proxy, this.v2, data)).to.be.reverted; - }); - }); - - describe('with valid callData', function () { - it('upgrades implementation', async function () { - const data = this.v2.interface.encodeFunctionData('initializeNonPayableWithValue', [1337n]); - await this.proxyAdmin.connect(this.admin).upgradeAndCall(this.proxy, this.v2, data); - expect(await getAddressInSlot(this.proxy, ImplementationSlot)).to.equal(this.v2); - }); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/transparent/TransparentUpgradeableProxy.behaviour.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/transparent/TransparentUpgradeableProxy.behaviour.js deleted file mode 100644 index 8e1d62eaad..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/transparent/TransparentUpgradeableProxy.behaviour.js +++ /dev/null @@ -1,357 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); - -const { impersonate } = require('../../helpers/account'); -const { getAddressInSlot, ImplementationSlot, AdminSlot } = require('../../helpers/storage'); - -// createProxy, initialOwner, accounts -module.exports = function shouldBehaveLikeTransparentUpgradeableProxy() { - before(async function () { - const implementationV0 = await ethers.deployContract('DummyImplementation'); - const implementationV1 = await ethers.deployContract('DummyImplementation'); - - const createProxyWithImpersonatedProxyAdmin = async (logic, initData, opts = undefined) => { - const [proxy, tx] = await this.createProxy(logic, initData, opts).then(instance => - Promise.all([ethers.getContractAt('ITransparentUpgradeableProxy', instance), instance.deploymentTransaction()]), - ); - - const proxyAdmin = await ethers.getContractAt( - 'ProxyAdmin', - ethers.getCreateAddress({ from: proxy.target, nonce: 1n }), - ); - const proxyAdminAsSigner = await proxyAdmin.getAddress().then(impersonate); - - return { - instance: logic.attach(proxy.target), // attaching proxy directly works well for everything except for event resolution - proxy, - proxyAdmin, - proxyAdminAsSigner, - tx, - }; - }; - - Object.assign(this, { - implementationV0, - implementationV1, - createProxyWithImpersonatedProxyAdmin, - }); - }); - - beforeEach(async function () { - Object.assign(this, await this.createProxyWithImpersonatedProxyAdmin(this.implementationV0, '0x')); - }); - - describe('implementation', function () { - it('returns the current implementation address', async function () { - expect(await getAddressInSlot(this.proxy, ImplementationSlot)).to.equal(this.implementationV0); - }); - - it('delegates to the implementation', async function () { - expect(await this.instance.get()).to.be.true; - }); - }); - - describe('proxy admin', function () { - it('emits AdminChanged event during construction', async function () { - await expect(this.tx).to.emit(this.proxy, 'AdminChanged').withArgs(ethers.ZeroAddress, this.proxyAdmin); - }); - - it('sets the proxy admin in storage with the correct initial owner', async function () { - expect(await getAddressInSlot(this.proxy, AdminSlot)).to.equal(this.proxyAdmin); - - expect(await this.proxyAdmin.owner()).to.equal(this.owner); - }); - - it('can overwrite the admin by the implementation', async function () { - await this.instance.unsafeOverrideAdmin(this.other); - - const ERC1967AdminSlotValue = await getAddressInSlot(this.proxy, AdminSlot); - expect(ERC1967AdminSlotValue).to.equal(this.other); - expect(ERC1967AdminSlotValue).to.not.equal(this.proxyAdmin); - - // Still allows previous admin to execute admin operations - await expect(this.proxy.connect(this.proxyAdminAsSigner).upgradeToAndCall(this.implementationV1, '0x')) - .to.emit(this.proxy, 'Upgraded') - .withArgs(this.implementationV1); - }); - }); - - describe('upgradeToAndCall', function () { - describe('without migrations', function () { - beforeEach(async function () { - this.behavior = await ethers.deployContract('InitializableMock'); - }); - - describe('when the call does not fail', function () { - beforeEach(function () { - this.initializeData = this.behavior.interface.encodeFunctionData('initializeWithX', [42n]); - }); - - describe('when the sender is the admin', function () { - const value = 10n ** 5n; - - beforeEach(async function () { - this.tx = await this.proxy - .connect(this.proxyAdminAsSigner) - .upgradeToAndCall(this.behavior, this.initializeData, { - value, - }); - }); - - it('upgrades to the requested implementation', async function () { - expect(await getAddressInSlot(this.proxy, ImplementationSlot)).to.equal(this.behavior); - }); - - it('emits an event', async function () { - await expect(this.tx).to.emit(this.proxy, 'Upgraded').withArgs(this.behavior); - }); - - it('calls the initializer function', async function () { - expect(await this.behavior.attach(this.proxy).x()).to.equal(42n); - }); - - it('sends given value to the proxy', async function () { - expect(await ethers.provider.getBalance(this.proxy)).to.equal(value); - }); - - it('uses the storage of the proxy', async function () { - // storage layout should look as follows: - // - 0: Initializable storage ++ initializerRan ++ onlyInitializingRan - // - 1: x - expect(await ethers.provider.getStorage(this.proxy, 1n)).to.equal(42n); - }); - }); - - describe('when the sender is not the admin', function () { - it('reverts', async function () { - await expect(this.proxy.connect(this.other).upgradeToAndCall(this.behavior, this.initializeData)).to.be - .reverted; - }); - }); - }); - - describe('when the call does fail', function () { - beforeEach(function () { - this.initializeData = this.behavior.interface.encodeFunctionData('fail'); - }); - - it('reverts', async function () { - await expect(this.proxy.connect(this.proxyAdminAsSigner).upgradeToAndCall(this.behavior, this.initializeData)) - .to.be.reverted; - }); - }); - }); - - describe('with migrations', function () { - describe('when the sender is the admin', function () { - const value = 10n ** 5n; - - describe('when upgrading to V1', function () { - beforeEach(async function () { - this.behaviorV1 = await ethers.deployContract('MigratableMockV1'); - const v1MigrationData = this.behaviorV1.interface.encodeFunctionData('initialize', [42n]); - - this.balancePreviousV1 = await ethers.provider.getBalance(this.proxy); - this.tx = await this.proxy - .connect(this.proxyAdminAsSigner) - .upgradeToAndCall(this.behaviorV1, v1MigrationData, { - value, - }); - }); - - it('upgrades to the requested version and emits an event', async function () { - expect(await getAddressInSlot(this.proxy, ImplementationSlot)).to.equal(this.behaviorV1); - - await expect(this.tx).to.emit(this.proxy, 'Upgraded').withArgs(this.behaviorV1); - }); - - it("calls the 'initialize' function and sends given value to the proxy", async function () { - expect(await this.behaviorV1.attach(this.proxy).x()).to.equal(42n); - expect(await ethers.provider.getBalance(this.proxy)).to.equal(this.balancePreviousV1 + value); - }); - - describe('when upgrading to V2', function () { - beforeEach(async function () { - this.behaviorV2 = await ethers.deployContract('MigratableMockV2'); - const v2MigrationData = this.behaviorV2.interface.encodeFunctionData('migrate', [10n, 42n]); - - this.balancePreviousV2 = await ethers.provider.getBalance(this.proxy); - this.tx = await this.proxy - .connect(this.proxyAdminAsSigner) - .upgradeToAndCall(this.behaviorV2, v2MigrationData, { - value, - }); - }); - - it('upgrades to the requested version and emits an event', async function () { - expect(await getAddressInSlot(this.proxy, ImplementationSlot)).to.equal(this.behaviorV2); - - await expect(this.tx).to.emit(this.proxy, 'Upgraded').withArgs(this.behaviorV2); - }); - - it("calls the 'migrate' function and sends given value to the proxy", async function () { - expect(await this.behaviorV2.attach(this.proxy).x()).to.equal(10n); - expect(await this.behaviorV2.attach(this.proxy).y()).to.equal(42n); - expect(await ethers.provider.getBalance(this.proxy)).to.equal(this.balancePreviousV2 + value); - }); - - describe('when upgrading to V3', function () { - beforeEach(async function () { - this.behaviorV3 = await ethers.deployContract('MigratableMockV3'); - const v3MigrationData = this.behaviorV3.interface.encodeFunctionData('migrate()'); - - this.balancePreviousV3 = await ethers.provider.getBalance(this.proxy); - this.tx = await this.proxy - .connect(this.proxyAdminAsSigner) - .upgradeToAndCall(this.behaviorV3, v3MigrationData, { - value, - }); - }); - - it('upgrades to the requested version and emits an event', async function () { - expect(await getAddressInSlot(this.proxy, ImplementationSlot)).to.equal(this.behaviorV3); - - await expect(this.tx).to.emit(this.proxy, 'Upgraded').withArgs(this.behaviorV3); - }); - - it("calls the 'migrate' function and sends given value to the proxy", async function () { - expect(await this.behaviorV3.attach(this.proxy).x()).to.equal(42n); - expect(await this.behaviorV3.attach(this.proxy).y()).to.equal(10n); - expect(await ethers.provider.getBalance(this.proxy)).to.equal(this.balancePreviousV3 + value); - }); - }); - }); - }); - }); - - describe('when the sender is not the admin', function () { - it('reverts', async function () { - const behaviorV1 = await ethers.deployContract('MigratableMockV1'); - const v1MigrationData = behaviorV1.interface.encodeFunctionData('initialize', [42n]); - await expect(this.proxy.connect(this.other).upgradeToAndCall(behaviorV1, v1MigrationData)).to.be.reverted; - }); - }); - }); - }); - - describe('transparent proxy', function () { - beforeEach('creating proxy', async function () { - this.clashingImplV0 = await ethers.deployContract('ClashingImplementation'); - this.clashingImplV1 = await ethers.deployContract('ClashingImplementation'); - - Object.assign(this, await this.createProxyWithImpersonatedProxyAdmin(this.clashingImplV0, '0x')); - }); - - it('proxy admin cannot call delegated functions', async function () { - const factory = await ethers.getContractFactory('TransparentUpgradeableProxy'); - - await expect(this.instance.connect(this.proxyAdminAsSigner).delegatedFunction()).to.be.revertedWithCustomError( - factory, - 'ProxyDeniedAdminAccess', - ); - }); - - describe('when function names clash', function () { - it('executes the proxy function if the sender is the admin', async function () { - await expect(this.proxy.connect(this.proxyAdminAsSigner).upgradeToAndCall(this.clashingImplV1, '0x')) - .to.emit(this.proxy, 'Upgraded') - .withArgs(this.clashingImplV1); - }); - - it('delegates the call to implementation when sender is not the admin', async function () { - await expect(this.proxy.connect(this.other).upgradeToAndCall(this.clashingImplV1, '0x')) - .to.emit(this.instance, 'ClashingImplementationCall') - .to.not.emit(this.proxy, 'Upgraded'); - }); - }); - }); - - describe('regression', function () { - const initializeData = '0x'; - - it('should add new function', async function () { - const impl1 = await ethers.deployContract('Implementation1'); - const impl2 = await ethers.deployContract('Implementation2'); - const { instance, proxy, proxyAdminAsSigner } = await this.createProxyWithImpersonatedProxyAdmin( - impl1, - initializeData, - ); - - await instance.setValue(42n); - - // `getValue` is not available in impl1 - await expect(impl2.attach(instance).getValue()).to.be.reverted; - - // do upgrade - await proxy.connect(proxyAdminAsSigner).upgradeToAndCall(impl2, '0x'); - - // `getValue` is available in impl2 - expect(await impl2.attach(instance).getValue()).to.equal(42n); - }); - - it('should remove function', async function () { - const impl1 = await ethers.deployContract('Implementation1'); - const impl2 = await ethers.deployContract('Implementation2'); - const { instance, proxy, proxyAdminAsSigner } = await this.createProxyWithImpersonatedProxyAdmin( - impl2, - initializeData, - ); - - await instance.setValue(42n); - - // `getValue` is available in impl2 - expect(await impl2.attach(instance).getValue()).to.equal(42n); - - // do downgrade - await proxy.connect(proxyAdminAsSigner).upgradeToAndCall(impl1, '0x'); - - // `getValue` is not available in impl1 - await expect(impl2.attach(instance).getValue()).to.be.reverted; - }); - - it('should change function signature', async function () { - const impl1 = await ethers.deployContract('Implementation1'); - const impl3 = await ethers.deployContract('Implementation3'); - const { instance, proxy, proxyAdminAsSigner } = await this.createProxyWithImpersonatedProxyAdmin( - impl1, - initializeData, - ); - - await instance.setValue(42n); - - await proxy.connect(proxyAdminAsSigner).upgradeToAndCall(impl3, '0x'); - - expect(await impl3.attach(instance).getValue(8n)).to.equal(50n); - }); - - it('should add fallback function', async function () { - const impl1 = await ethers.deployContract('Implementation1'); - const impl4 = await ethers.deployContract('Implementation4'); - const { instance, proxy, proxyAdminAsSigner } = await this.createProxyWithImpersonatedProxyAdmin( - impl1, - initializeData, - ); - - await proxy.connect(proxyAdminAsSigner).upgradeToAndCall(impl4, '0x'); - - await this.other.sendTransaction({ to: proxy }); - - expect(await impl4.attach(instance).getValue()).to.equal(1n); - }); - - it('should remove fallback function', async function () { - const impl2 = await ethers.deployContract('Implementation2'); - const impl4 = await ethers.deployContract('Implementation4'); - const { instance, proxy, proxyAdminAsSigner } = await this.createProxyWithImpersonatedProxyAdmin( - impl4, - initializeData, - ); - - await proxy.connect(proxyAdminAsSigner).upgradeToAndCall(impl2, '0x'); - - await expect(this.other.sendTransaction({ to: proxy })).to.be.reverted; - - expect(await impl2.attach(instance).getValue()).to.equal(0n); - }); - }); -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/transparent/TransparentUpgradeableProxy.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/transparent/TransparentUpgradeableProxy.test.js deleted file mode 100644 index 61e18014e5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/transparent/TransparentUpgradeableProxy.test.js +++ /dev/null @@ -1,28 +0,0 @@ -const { ethers } = require('hardhat'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const shouldBehaveLikeProxy = require('../Proxy.behaviour'); -const shouldBehaveLikeTransparentUpgradeableProxy = require('./TransparentUpgradeableProxy.behaviour'); - -async function fixture() { - const [owner, other, ...accounts] = await ethers.getSigners(); - - const implementation = await ethers.deployContract('DummyImplementation'); - - const createProxy = function (logic, initData, opts = undefined) { - return ethers.deployContract('TransparentUpgradeableProxy', [logic, owner, initData], opts); - }; - - return { nonContractAddress: owner, owner, other, accounts, implementation, createProxy }; -} - -describe('TransparentUpgradeableProxy', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeProxy(); - - // createProxy, owner, otherAccounts - shouldBehaveLikeTransparentUpgradeableProxy(); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/utils/Initializable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/utils/Initializable.test.js deleted file mode 100644 index 6bf213f0d9..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/utils/Initializable.test.js +++ /dev/null @@ -1,216 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { MAX_UINT64 } = require('../../helpers/constants'); - -describe('Initializable', function () { - describe('basic testing without inheritance', function () { - beforeEach('deploying', async function () { - this.mock = await ethers.deployContract('InitializableMock'); - }); - - describe('before initialize', function () { - it('initializer has not run', async function () { - expect(await this.mock.initializerRan()).to.be.false; - }); - - it('_initializing returns false before initialization', async function () { - expect(await this.mock.isInitializing()).to.be.false; - }); - }); - - describe('after initialize', function () { - beforeEach('initializing', async function () { - await this.mock.initialize(); - }); - - it('initializer has run', async function () { - expect(await this.mock.initializerRan()).to.be.true; - }); - - it('_initializing returns false after initialization', async function () { - expect(await this.mock.isInitializing()).to.be.false; - }); - - it('initializer does not run again', async function () { - await expect(this.mock.initialize()).to.be.revertedWithCustomError(this.mock, 'InvalidInitialization'); - }); - }); - - describe('nested under an initializer', function () { - it('initializer modifier reverts', async function () { - await expect(this.mock.initializerNested()).to.be.revertedWithCustomError(this.mock, 'InvalidInitialization'); - }); - - it('onlyInitializing modifier succeeds', async function () { - await this.mock.onlyInitializingNested(); - expect(await this.mock.onlyInitializingRan()).to.be.true; - }); - }); - - it('cannot call onlyInitializable function outside the scope of an initializable function', async function () { - await expect(this.mock.initializeOnlyInitializing()).to.be.revertedWithCustomError(this.mock, 'NotInitializing'); - }); - }); - - it('nested initializer can run during construction', async function () { - const mock = await ethers.deployContract('ConstructorInitializableMock'); - expect(await mock.initializerRan()).to.be.true; - expect(await mock.onlyInitializingRan()).to.be.true; - }); - - it('multiple constructor levels can be initializers', async function () { - const mock = await ethers.deployContract('ChildConstructorInitializableMock'); - expect(await mock.initializerRan()).to.be.true; - expect(await mock.childInitializerRan()).to.be.true; - expect(await mock.onlyInitializingRan()).to.be.true; - }); - - describe('reinitialization', function () { - beforeEach('deploying', async function () { - this.mock = await ethers.deployContract('ReinitializerMock'); - }); - - it('can reinitialize', async function () { - expect(await this.mock.counter()).to.equal(0n); - await this.mock.initialize(); - expect(await this.mock.counter()).to.equal(1n); - await this.mock.reinitialize(2); - expect(await this.mock.counter()).to.equal(2n); - await this.mock.reinitialize(3); - expect(await this.mock.counter()).to.equal(3n); - }); - - it('can jump multiple steps', async function () { - expect(await this.mock.counter()).to.equal(0n); - await this.mock.initialize(); - expect(await this.mock.counter()).to.equal(1n); - await this.mock.reinitialize(128); - expect(await this.mock.counter()).to.equal(2n); - }); - - it('cannot nest reinitializers', async function () { - expect(await this.mock.counter()).to.equal(0n); - await expect(this.mock.nestedReinitialize(2, 2)).to.be.revertedWithCustomError( - this.mock, - 'InvalidInitialization', - ); - await expect(this.mock.nestedReinitialize(2, 3)).to.be.revertedWithCustomError( - this.mock, - 'InvalidInitialization', - ); - await expect(this.mock.nestedReinitialize(3, 2)).to.be.revertedWithCustomError( - this.mock, - 'InvalidInitialization', - ); - }); - - it('can chain reinitializers', async function () { - expect(await this.mock.counter()).to.equal(0n); - await this.mock.chainReinitialize(2, 3); - expect(await this.mock.counter()).to.equal(2n); - }); - - it('_getInitializedVersion returns right version', async function () { - await this.mock.initialize(); - expect(await this.mock.getInitializedVersion()).to.equal(1n); - await this.mock.reinitialize(12); - expect(await this.mock.getInitializedVersion()).to.equal(12n); - }); - - describe('contract locking', function () { - it('prevents initialization', async function () { - await this.mock.disableInitializers(); - await expect(this.mock.initialize()).to.be.revertedWithCustomError(this.mock, 'InvalidInitialization'); - }); - - it('prevents re-initialization', async function () { - await this.mock.disableInitializers(); - await expect(this.mock.reinitialize(255n)).to.be.revertedWithCustomError(this.mock, 'InvalidInitialization'); - }); - - it('can lock contract after initialization', async function () { - await this.mock.initialize(); - await this.mock.disableInitializers(); - await expect(this.mock.reinitialize(255n)).to.be.revertedWithCustomError(this.mock, 'InvalidInitialization'); - }); - }); - }); - - describe('events', function () { - it('constructor initialization emits event', async function () { - const mock = await ethers.deployContract('ConstructorInitializableMock'); - await expect(mock.deploymentTransaction()).to.emit(mock, 'Initialized').withArgs(1n); - }); - - it('initialization emits event', async function () { - const mock = await ethers.deployContract('ReinitializerMock'); - await expect(mock.initialize()).to.emit(mock, 'Initialized').withArgs(1n); - }); - - it('reinitialization emits event', async function () { - const mock = await ethers.deployContract('ReinitializerMock'); - await expect(mock.reinitialize(128)).to.emit(mock, 'Initialized').withArgs(128n); - }); - - it('chained reinitialization emits multiple events', async function () { - const mock = await ethers.deployContract('ReinitializerMock'); - - await expect(mock.chainReinitialize(2, 3)) - .to.emit(mock, 'Initialized') - .withArgs(2n) - .to.emit(mock, 'Initialized') - .withArgs(3n); - }); - }); - - describe('complex testing with inheritance', function () { - const mother = 12n; - const gramps = '56'; - const father = 34n; - const child = 78n; - - beforeEach('deploying', async function () { - this.mock = await ethers.deployContract('SampleChild'); - await this.mock.initialize(mother, gramps, father, child); - }); - - it('initializes human', async function () { - expect(await this.mock.isHuman()).to.be.true; - }); - - it('initializes mother', async function () { - expect(await this.mock.mother()).to.equal(mother); - }); - - it('initializes gramps', async function () { - expect(await this.mock.gramps()).to.equal(gramps); - }); - - it('initializes father', async function () { - expect(await this.mock.father()).to.equal(father); - }); - - it('initializes child', async function () { - expect(await this.mock.child()).to.equal(child); - }); - }); - - describe('disabling initialization', function () { - it('old and new patterns in bad sequence', async function () { - const DisableBad1 = await ethers.getContractFactory('DisableBad1'); - await expect(DisableBad1.deploy()).to.be.revertedWithCustomError(DisableBad1, 'InvalidInitialization'); - - const DisableBad2 = await ethers.getContractFactory('DisableBad2'); - await expect(DisableBad2.deploy()).to.be.revertedWithCustomError(DisableBad2, 'InvalidInitialization'); - }); - - it('old and new patterns in good sequence', async function () { - const ok = await ethers.deployContract('DisableOk'); - await expect(ok.deploymentTransaction()) - .to.emit(ok, 'Initialized') - .withArgs(1n) - .to.emit(ok, 'Initialized') - .withArgs(MAX_UINT64); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/utils/UUPSUpgradeable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/utils/UUPSUpgradeable.test.js deleted file mode 100644 index 17f8657616..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/proxy/utils/UUPSUpgradeable.test.js +++ /dev/null @@ -1,120 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { getAddressInSlot, ImplementationSlot } = require('../../helpers/storage'); - -async function fixture() { - const implInitial = await ethers.deployContract('UUPSUpgradeableMock'); - const implUpgradeOk = await ethers.deployContract('UUPSUpgradeableMock'); - const implUpgradeUnsafe = await ethers.deployContract('UUPSUpgradeableUnsafeMock'); - const implUpgradeNonUUPS = await ethers.deployContract('NonUpgradeableMock'); - const implUnsupportedUUID = await ethers.deployContract('UUPSUnsupportedProxiableUUID'); - // Used for testing non ERC1967 compliant proxies (clones are proxies that don't use the ERC1967 implementation slot) - const cloneFactory = await ethers.deployContract('$Clones'); - - const instance = await ethers - .deployContract('ERC1967Proxy', [implInitial, '0x']) - .then(proxy => implInitial.attach(proxy.target)); - - return { - implInitial, - implUpgradeOk, - implUpgradeUnsafe, - implUpgradeNonUUPS, - implUnsupportedUUID, - cloneFactory, - instance, - }; -} - -describe('UUPSUpgradeable', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('has an interface version', async function () { - expect(await this.instance.UPGRADE_INTERFACE_VERSION()).to.equal('5.0.0'); - }); - - it('upgrade to upgradeable implementation', async function () { - await expect(this.instance.upgradeToAndCall(this.implUpgradeOk, '0x')) - .to.emit(this.instance, 'Upgraded') - .withArgs(this.implUpgradeOk); - - expect(await getAddressInSlot(this.instance, ImplementationSlot)).to.equal(this.implUpgradeOk); - }); - - it('upgrade to upgradeable implementation with call', async function () { - expect(await this.instance.current()).to.equal(0n); - - await expect( - this.instance.upgradeToAndCall(this.implUpgradeOk, this.implUpgradeOk.interface.encodeFunctionData('increment')), - ) - .to.emit(this.instance, 'Upgraded') - .withArgs(this.implUpgradeOk); - - expect(await getAddressInSlot(this.instance, ImplementationSlot)).to.equal(this.implUpgradeOk); - - expect(await this.instance.current()).to.equal(1n); - }); - - it('calling upgradeTo on the implementation reverts', async function () { - await expect(this.implInitial.upgradeToAndCall(this.implUpgradeOk, '0x')).to.be.revertedWithCustomError( - this.implInitial, - 'UUPSUnauthorizedCallContext', - ); - }); - - it('calling upgradeToAndCall on the implementation reverts', async function () { - await expect( - this.implInitial.upgradeToAndCall( - this.implUpgradeOk, - this.implUpgradeOk.interface.encodeFunctionData('increment'), - ), - ).to.be.revertedWithCustomError(this.implUpgradeOk, 'UUPSUnauthorizedCallContext'); - }); - - it('calling upgradeToAndCall from a contract that is not an ERC1967 proxy (with the right implementation) reverts', async function () { - const instance = await this.cloneFactory.$clone - .staticCall(this.implUpgradeOk) - .then(address => this.implInitial.attach(address)); - await this.cloneFactory.$clone(this.implUpgradeOk); - - await expect(instance.upgradeToAndCall(this.implUpgradeUnsafe, '0x')).to.be.revertedWithCustomError( - instance, - 'UUPSUnauthorizedCallContext', - ); - }); - - it('rejects upgrading to an unsupported UUID', async function () { - await expect(this.instance.upgradeToAndCall(this.implUnsupportedUUID, '0x')) - .to.be.revertedWithCustomError(this.instance, 'UUPSUnsupportedProxiableUUID') - .withArgs(ethers.id('invalid UUID')); - }); - - it('upgrade to and unsafe upgradeable implementation', async function () { - await expect(this.instance.upgradeToAndCall(this.implUpgradeUnsafe, '0x')) - .to.emit(this.instance, 'Upgraded') - .withArgs(this.implUpgradeUnsafe); - - expect(await getAddressInSlot(this.instance, ImplementationSlot)).to.equal(this.implUpgradeUnsafe); - }); - - // delegate to a non existing upgradeTo function causes a low level revert - it('reject upgrade to non uups implementation', async function () { - await expect(this.instance.upgradeToAndCall(this.implUpgradeNonUUPS, '0x')) - .to.be.revertedWithCustomError(this.instance, 'ERC1967InvalidImplementation') - .withArgs(this.implUpgradeNonUUPS); - }); - - it('reject proxy address as implementation', async function () { - const otherInstance = await ethers - .deployContract('ERC1967Proxy', [this.implInitial, '0x']) - .then(proxy => this.implInitial.attach(proxy.target)); - - await expect(this.instance.upgradeToAndCall(otherInstance, '0x')) - .to.be.revertedWithCustomError(this.instance, 'ERC1967InvalidImplementation') - .withArgs(otherInstance); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/sanity.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/sanity.test.js deleted file mode 100644 index ea0175c48c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/sanity.test.js +++ /dev/null @@ -1,27 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture, mine } = require('@nomicfoundation/hardhat-network-helpers'); - -async function fixture() { - return {}; -} - -describe('Environment sanity', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('snapshot', function () { - let blockNumberBefore; - - it('cache and mine', async function () { - blockNumberBefore = await ethers.provider.getBlockNumber(); - await mine(); - expect(await ethers.provider.getBlockNumber()).to.equal(blockNumberBefore + 1); - }); - - it('check snapshot', async function () { - expect(await ethers.provider.getBlockNumber()).to.equal(blockNumberBefore); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/ERC1155.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/ERC1155.behavior.js deleted file mode 100644 index d19b73251a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/ERC1155.behavior.js +++ /dev/null @@ -1,763 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { anyValue } = require('@nomicfoundation/hardhat-chai-matchers/withArgs'); - -const { RevertType } = require('../../helpers/enums'); -const { shouldSupportInterfaces } = require('../../utils/introspection/SupportsInterface.behavior'); - -function shouldBehaveLikeERC1155() { - const firstTokenId = 1n; - const secondTokenId = 2n; - const unknownTokenId = 3n; - - const firstTokenValue = 1000n; - const secondTokenValue = 2000n; - - const RECEIVER_SINGLE_MAGIC_VALUE = '0xf23a6e61'; - const RECEIVER_BATCH_MAGIC_VALUE = '0xbc197c81'; - - beforeEach(async function () { - [this.recipient, this.proxy, this.alice, this.bruce] = this.otherAccounts; - }); - - describe('like an ERC1155', function () { - describe('balanceOf', function () { - it('should return 0 when queried about the zero address', async function () { - expect(await this.token.balanceOf(ethers.ZeroAddress, firstTokenId)).to.equal(0n); - }); - - describe("when accounts don't own tokens", function () { - it('returns zero for given addresses', async function () { - expect(await this.token.balanceOf(this.alice, firstTokenId)).to.equal(0n); - expect(await this.token.balanceOf(this.bruce, secondTokenId)).to.equal(0n); - expect(await this.token.balanceOf(this.alice, unknownTokenId)).to.equal(0n); - }); - }); - - describe('when accounts own some tokens', function () { - beforeEach(async function () { - await this.token.$_mint(this.alice, firstTokenId, firstTokenValue, '0x'); - await this.token.$_mint(this.bruce, secondTokenId, secondTokenValue, '0x'); - }); - - it('returns the amount of tokens owned by the given addresses', async function () { - expect(await this.token.balanceOf(this.alice, firstTokenId)).to.equal(firstTokenValue); - expect(await this.token.balanceOf(this.bruce, secondTokenId)).to.equal(secondTokenValue); - expect(await this.token.balanceOf(this.alice, unknownTokenId)).to.equal(0n); - }); - }); - }); - - describe('balanceOfBatch', function () { - it("reverts when input arrays don't match up", async function () { - const accounts1 = [this.alice, this.bruce, this.alice, this.bruce]; - const ids1 = [firstTokenId, secondTokenId, unknownTokenId]; - - await expect(this.token.balanceOfBatch(accounts1, ids1)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidArrayLength') - .withArgs(ids1.length, accounts1.length); - - const accounts2 = [this.alice, this.bruce]; - const ids2 = [firstTokenId, secondTokenId, unknownTokenId]; - await expect(this.token.balanceOfBatch(accounts2, ids2)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidArrayLength') - .withArgs(ids2.length, accounts2.length); - }); - - it('should return 0 as the balance when one of the addresses is the zero address', async function () { - const result = await this.token.balanceOfBatch( - [this.alice, this.bruce, ethers.ZeroAddress], - [firstTokenId, secondTokenId, unknownTokenId], - ); - expect(result).to.deep.equal([0n, 0n, 0n]); - }); - - describe("when accounts don't own tokens", function () { - it('returns zeros for each account', async function () { - const result = await this.token.balanceOfBatch( - [this.alice, this.bruce, this.alice], - [firstTokenId, secondTokenId, unknownTokenId], - ); - expect(result).to.deep.equal([0n, 0n, 0n]); - }); - }); - - describe('when accounts own some tokens', function () { - beforeEach(async function () { - await this.token.$_mint(this.alice, firstTokenId, firstTokenValue, '0x'); - await this.token.$_mint(this.bruce, secondTokenId, secondTokenValue, '0x'); - }); - - it('returns amounts owned by each account in order passed', async function () { - const result = await this.token.balanceOfBatch( - [this.bruce, this.alice, this.alice], - [secondTokenId, firstTokenId, unknownTokenId], - ); - expect(result).to.deep.equal([secondTokenValue, firstTokenValue, 0n]); - }); - - it('returns multiple times the balance of the same address when asked', async function () { - const result = await this.token.balanceOfBatch( - [this.alice, this.bruce, this.alice], - [firstTokenId, secondTokenId, firstTokenId], - ); - expect(result).to.deep.equal([firstTokenValue, secondTokenValue, firstTokenValue]); - }); - }); - }); - - describe('setApprovalForAll', function () { - beforeEach(async function () { - this.tx = await this.token.connect(this.holder).setApprovalForAll(this.proxy, true); - }); - - it('sets approval status which can be queried via isApprovedForAll', async function () { - expect(await this.token.isApprovedForAll(this.holder, this.proxy)).to.be.true; - }); - - it('emits an ApprovalForAll log', async function () { - await expect(this.tx).to.emit(this.token, 'ApprovalForAll').withArgs(this.holder, this.proxy, true); - }); - - it('can unset approval for an operator', async function () { - await this.token.connect(this.holder).setApprovalForAll(this.proxy, false); - expect(await this.token.isApprovedForAll(this.holder, this.proxy)).to.be.false; - }); - - it('reverts if attempting to approve zero address as an operator', async function () { - await expect(this.token.connect(this.holder).setApprovalForAll(ethers.ZeroAddress, true)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidOperator') - .withArgs(ethers.ZeroAddress); - }); - }); - - describe('safeTransferFrom', function () { - beforeEach(async function () { - await this.token.$_mint(this.holder, firstTokenId, firstTokenValue, '0x'); - await this.token.$_mint(this.holder, secondTokenId, secondTokenValue, '0x'); - }); - - it('reverts when transferring more than balance', async function () { - await expect( - this.token - .connect(this.holder) - .safeTransferFrom(this.holder, this.recipient, firstTokenId, firstTokenValue + 1n, '0x'), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InsufficientBalance') - .withArgs(this.holder, firstTokenValue, firstTokenValue + 1n, firstTokenId); - }); - - it('reverts when transferring to zero address', async function () { - await expect( - this.token - .connect(this.holder) - .safeTransferFrom(this.holder, ethers.ZeroAddress, firstTokenId, firstTokenValue, '0x'), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidReceiver') - .withArgs(ethers.ZeroAddress); - }); - - function transferWasSuccessful() { - it('debits transferred balance from sender', async function () { - expect(await this.token.balanceOf(this.args.from, this.args.id)).to.equal(0n); - }); - - it('credits transferred balance to receiver', async function () { - expect(await this.token.balanceOf(this.args.to, this.args.id)).to.equal(this.args.value); - }); - - it('emits a TransferSingle log', async function () { - await expect(this.tx) - .to.emit(this.token, 'TransferSingle') - .withArgs(this.args.operator, this.args.from, this.args.to, this.args.id, this.args.value); - }); - } - - describe('when called by the holder', function () { - beforeEach(async function () { - this.args = { - operator: this.holder, - from: this.holder, - to: this.recipient, - id: firstTokenId, - value: firstTokenValue, - data: '0x', - }; - this.tx = await this.token - .connect(this.args.operator) - .safeTransferFrom(this.args.from, this.args.to, this.args.id, this.args.value, this.args.data); - }); - - transferWasSuccessful(); - - it('preserves existing balances which are not transferred by holder', async function () { - expect(await this.token.balanceOf(this.holder, secondTokenId)).to.equal(secondTokenValue); - expect(await this.token.balanceOf(this.recipient, secondTokenId)).to.equal(0n); - }); - }); - - describe('when called by an operator on behalf of the holder', function () { - describe('when operator is not approved by holder', function () { - beforeEach(async function () { - await this.token.connect(this.holder).setApprovalForAll(this.proxy, false); - }); - - it('reverts', async function () { - await expect( - this.token - .connect(this.proxy) - .safeTransferFrom(this.holder, this.recipient, firstTokenId, firstTokenValue, '0x'), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155MissingApprovalForAll') - .withArgs(this.proxy, this.holder); - }); - }); - - describe('when operator is approved by holder', function () { - beforeEach(async function () { - await this.token.connect(this.holder).setApprovalForAll(this.proxy, true); - - this.args = { - operator: this.proxy, - from: this.holder, - to: this.recipient, - id: firstTokenId, - value: firstTokenValue, - data: '0x', - }; - this.tx = await this.token - .connect(this.args.operator) - .safeTransferFrom(this.args.from, this.args.to, this.args.id, this.args.value, this.args.data); - }); - - transferWasSuccessful(); - - it("preserves operator's balances not involved in the transfer", async function () { - expect(await this.token.balanceOf(this.proxy, firstTokenId)).to.equal(0n); - expect(await this.token.balanceOf(this.proxy, secondTokenId)).to.equal(0n); - }); - }); - }); - - describe('when sending to a valid receiver', function () { - beforeEach(async function () { - this.receiver = await ethers.deployContract('$ERC1155ReceiverMock', [ - RECEIVER_SINGLE_MAGIC_VALUE, - RECEIVER_BATCH_MAGIC_VALUE, - RevertType.None, - ]); - }); - - describe('without data', function () { - beforeEach(async function () { - this.args = { - operator: this.holder, - from: this.holder, - to: this.receiver, - id: firstTokenId, - value: firstTokenValue, - data: '0x', - }; - this.tx = await this.token - .connect(this.args.operator) - .safeTransferFrom(this.args.from, this.args.to, this.args.id, this.args.value, this.args.data); - }); - - transferWasSuccessful(); - - it('calls onERC1155Received', async function () { - await expect(this.tx) - .to.emit(this.receiver, 'Received') - .withArgs(this.args.operator, this.args.from, this.args.id, this.args.value, this.args.data, anyValue); - }); - }); - - describe('with data', function () { - beforeEach(async function () { - this.args = { - operator: this.holder, - from: this.holder, - to: this.receiver, - id: firstTokenId, - value: firstTokenValue, - data: '0xf00dd00d', - }; - this.tx = await this.token - .connect(this.args.operator) - .safeTransferFrom(this.args.from, this.args.to, this.args.id, this.args.value, this.args.data); - }); - - transferWasSuccessful(); - - it('calls onERC1155Received', async function () { - await expect(this.tx) - .to.emit(this.receiver, 'Received') - .withArgs(this.args.operator, this.args.from, this.args.id, this.args.value, this.args.data, anyValue); - }); - }); - }); - - describe('to a receiver contract returning unexpected value', function () { - it('reverts', async function () { - const receiver = await ethers.deployContract('$ERC1155ReceiverMock', [ - '0x00c0ffee', - RECEIVER_BATCH_MAGIC_VALUE, - RevertType.None, - ]); - - await expect( - this.token - .connect(this.holder) - .safeTransferFrom(this.holder, receiver, firstTokenId, firstTokenValue, '0x'), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidReceiver') - .withArgs(receiver); - }); - }); - - describe('to a receiver contract that reverts', function () { - describe('with a revert string', function () { - it('reverts', async function () { - const receiver = await ethers.deployContract('$ERC1155ReceiverMock', [ - RECEIVER_SINGLE_MAGIC_VALUE, - RECEIVER_BATCH_MAGIC_VALUE, - RevertType.RevertWithMessage, - ]); - - await expect( - this.token - .connect(this.holder) - .safeTransferFrom(this.holder, receiver, firstTokenId, firstTokenValue, '0x'), - ).to.be.revertedWith('ERC1155ReceiverMock: reverting on receive'); - }); - }); - - describe('without a revert string', function () { - it('reverts', async function () { - const receiver = await ethers.deployContract('$ERC1155ReceiverMock', [ - RECEIVER_SINGLE_MAGIC_VALUE, - RECEIVER_BATCH_MAGIC_VALUE, - RevertType.RevertWithoutMessage, - ]); - - await expect( - this.token - .connect(this.holder) - .safeTransferFrom(this.holder, receiver, firstTokenId, firstTokenValue, '0x'), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidReceiver') - .withArgs(receiver); - }); - }); - - describe('with a custom error', function () { - it('reverts', async function () { - const receiver = await ethers.deployContract('$ERC1155ReceiverMock', [ - RECEIVER_SINGLE_MAGIC_VALUE, - RECEIVER_BATCH_MAGIC_VALUE, - RevertType.RevertWithCustomError, - ]); - - await expect( - this.token - .connect(this.holder) - .safeTransferFrom(this.holder, receiver, firstTokenId, firstTokenValue, '0x'), - ) - .to.be.revertedWithCustomError(receiver, 'CustomError') - .withArgs(RECEIVER_SINGLE_MAGIC_VALUE); - }); - }); - - describe('with a panic', function () { - it('reverts', async function () { - const receiver = await ethers.deployContract('$ERC1155ReceiverMock', [ - RECEIVER_SINGLE_MAGIC_VALUE, - RECEIVER_BATCH_MAGIC_VALUE, - RevertType.Panic, - ]); - - await expect( - this.token - .connect(this.holder) - .safeTransferFrom(this.holder, receiver, firstTokenId, firstTokenValue, '0x'), - ).to.be.revertedWithPanic(); - }); - }); - }); - - describe('to a contract that does not implement the required function', function () { - it('reverts', async function () { - const invalidReceiver = this.token; - - await expect( - this.token - .connect(this.holder) - .safeTransferFrom(this.holder, invalidReceiver, firstTokenId, firstTokenValue, '0x'), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidReceiver') - .withArgs(invalidReceiver); - }); - }); - }); - - describe('safeBatchTransferFrom', function () { - beforeEach(async function () { - await this.token.$_mint(this.holder, firstTokenId, firstTokenValue, '0x'); - await this.token.$_mint(this.holder, secondTokenId, secondTokenValue, '0x'); - }); - - it('reverts when transferring value more than any of balances', async function () { - await expect( - this.token - .connect(this.holder) - .safeBatchTransferFrom( - this.holder, - this.recipient, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue + 1n], - '0x', - ), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InsufficientBalance') - .withArgs(this.holder, secondTokenValue, secondTokenValue + 1n, secondTokenId); - }); - - it("reverts when ids array length doesn't match values array length", async function () { - const ids1 = [firstTokenId]; - const tokenValues1 = [firstTokenValue, secondTokenValue]; - - await expect( - this.token.connect(this.holder).safeBatchTransferFrom(this.holder, this.recipient, ids1, tokenValues1, '0x'), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidArrayLength') - .withArgs(ids1.length, tokenValues1.length); - - const ids2 = [firstTokenId, secondTokenId]; - const tokenValues2 = [firstTokenValue]; - - await expect( - this.token.connect(this.holder).safeBatchTransferFrom(this.holder, this.recipient, ids2, tokenValues2, '0x'), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidArrayLength') - .withArgs(ids2.length, tokenValues2.length); - }); - - it('reverts when transferring to zero address', async function () { - await expect( - this.token - .connect(this.holder) - .safeBatchTransferFrom( - this.holder, - ethers.ZeroAddress, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidReceiver') - .withArgs(ethers.ZeroAddress); - }); - - it('reverts when transferring from zero address', async function () { - await expect( - this.token.$_safeBatchTransferFrom(ethers.ZeroAddress, this.holder, [firstTokenId], [firstTokenValue], '0x'), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidSender') - .withArgs(ethers.ZeroAddress); - }); - - function batchTransferWasSuccessful() { - it('debits transferred balances from sender', async function () { - const newBalances = await this.token.balanceOfBatch( - this.args.ids.map(() => this.args.from), - this.args.ids, - ); - expect(newBalances).to.deep.equal(this.args.ids.map(() => 0n)); - }); - - it('credits transferred balances to receiver', async function () { - const newBalances = await this.token.balanceOfBatch( - this.args.ids.map(() => this.args.to), - this.args.ids, - ); - expect(newBalances).to.deep.equal(this.args.values); - }); - - it('emits a TransferBatch log', async function () { - await expect(this.tx) - .to.emit(this.token, 'TransferBatch') - .withArgs(this.args.operator, this.args.from, this.args.to, this.args.ids, this.args.values); - }); - } - - describe('when called by the holder', function () { - beforeEach(async function () { - this.args = { - operator: this.holder, - from: this.holder, - to: this.recipient, - ids: [firstTokenId, secondTokenId], - values: [firstTokenValue, secondTokenValue], - data: '0x', - }; - this.tx = await this.token - .connect(this.args.operator) - .safeBatchTransferFrom(this.args.from, this.args.to, this.args.ids, this.args.values, this.args.data); - }); - - batchTransferWasSuccessful(); - }); - - describe('when called by an operator on behalf of the holder', function () { - describe('when operator is not approved by holder', function () { - beforeEach(async function () { - await this.token.connect(this.holder).setApprovalForAll(this.proxy, false); - }); - - it('reverts', async function () { - await expect( - this.token - .connect(this.proxy) - .safeBatchTransferFrom( - this.holder, - this.recipient, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155MissingApprovalForAll') - .withArgs(this.proxy, this.holder); - }); - }); - - describe('when operator is approved by holder', function () { - beforeEach(async function () { - await this.token.connect(this.holder).setApprovalForAll(this.proxy, true); - - this.args = { - operator: this.proxy, - from: this.holder, - to: this.recipient, - ids: [firstTokenId, secondTokenId], - values: [firstTokenValue, secondTokenValue], - data: '0x', - }; - this.tx = await this.token - .connect(this.args.operator) - .safeBatchTransferFrom(this.args.from, this.args.to, this.args.ids, this.args.values, this.args.data); - }); - - batchTransferWasSuccessful(); - - it("preserves operator's balances not involved in the transfer", async function () { - expect(await this.token.balanceOf(this.proxy, firstTokenId)).to.equal(0n); - expect(await this.token.balanceOf(this.proxy, secondTokenId)).to.equal(0n); - }); - }); - }); - - describe('when sending to a valid receiver', function () { - beforeEach(async function () { - this.receiver = await ethers.deployContract('$ERC1155ReceiverMock', [ - RECEIVER_SINGLE_MAGIC_VALUE, - RECEIVER_BATCH_MAGIC_VALUE, - RevertType.None, - ]); - }); - - describe('without data', function () { - beforeEach(async function () { - this.args = { - operator: this.holder, - from: this.holder, - to: this.receiver, - ids: [firstTokenId, secondTokenId], - values: [firstTokenValue, secondTokenValue], - data: '0x', - }; - this.tx = await this.token - .connect(this.args.operator) - .safeBatchTransferFrom(this.args.from, this.args.to, this.args.ids, this.args.values, this.args.data); - }); - - batchTransferWasSuccessful(); - - it('calls onERC1155BatchReceived', async function () { - await expect(this.tx) - .to.emit(this.receiver, 'BatchReceived') - .withArgs(this.holder, this.holder, this.args.ids, this.args.values, this.args.data, anyValue); - }); - }); - - describe('with data', function () { - beforeEach(async function () { - this.args = { - operator: this.holder, - from: this.holder, - to: this.receiver, - ids: [firstTokenId, secondTokenId], - values: [firstTokenValue, secondTokenValue], - data: '0xf00dd00d', - }; - this.tx = await this.token - .connect(this.args.operator) - .safeBatchTransferFrom(this.args.from, this.args.to, this.args.ids, this.args.values, this.args.data); - }); - - batchTransferWasSuccessful(); - - it('calls onERC1155Received', async function () { - await expect(this.tx) - .to.emit(this.receiver, 'BatchReceived') - .withArgs(this.holder, this.holder, this.args.ids, this.args.values, this.args.data, anyValue); - }); - }); - }); - - describe('to a receiver contract returning unexpected value', function () { - it('reverts', async function () { - const receiver = await ethers.deployContract('$ERC1155ReceiverMock', [ - RECEIVER_SINGLE_MAGIC_VALUE, - RECEIVER_SINGLE_MAGIC_VALUE, - RevertType.None, - ]); - - await expect( - this.token - .connect(this.holder) - .safeBatchTransferFrom( - this.holder, - receiver, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidReceiver') - .withArgs(receiver); - }); - }); - - describe('to a receiver contract that reverts', function () { - describe('with a revert string', function () { - it('reverts', async function () { - const receiver = await ethers.deployContract('$ERC1155ReceiverMock', [ - RECEIVER_SINGLE_MAGIC_VALUE, - RECEIVER_BATCH_MAGIC_VALUE, - RevertType.RevertWithMessage, - ]); - - await expect( - this.token - .connect(this.holder) - .safeBatchTransferFrom( - this.holder, - receiver, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ).to.be.revertedWith('ERC1155ReceiverMock: reverting on batch receive'); - }); - }); - - describe('without a revert string', function () { - it('reverts', async function () { - const receiver = await ethers.deployContract('$ERC1155ReceiverMock', [ - RECEIVER_SINGLE_MAGIC_VALUE, - RECEIVER_BATCH_MAGIC_VALUE, - RevertType.RevertWithoutMessage, - ]); - - await expect( - this.token - .connect(this.holder) - .safeBatchTransferFrom( - this.holder, - receiver, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidReceiver') - .withArgs(receiver); - }); - }); - - describe('with a custom error', function () { - it('reverts', async function () { - const receiver = await ethers.deployContract('$ERC1155ReceiverMock', [ - RECEIVER_SINGLE_MAGIC_VALUE, - RECEIVER_BATCH_MAGIC_VALUE, - RevertType.RevertWithCustomError, - ]); - - await expect( - this.token - .connect(this.holder) - .safeBatchTransferFrom( - this.holder, - receiver, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ) - .to.be.revertedWithCustomError(receiver, 'CustomError') - .withArgs(RECEIVER_SINGLE_MAGIC_VALUE); - }); - }); - - describe('with a panic', function () { - it('reverts', async function () { - const receiver = await ethers.deployContract('$ERC1155ReceiverMock', [ - RECEIVER_SINGLE_MAGIC_VALUE, - RECEIVER_BATCH_MAGIC_VALUE, - RevertType.Panic, - ]); - - await expect( - this.token - .connect(this.holder) - .safeBatchTransferFrom( - this.holder, - receiver, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ).to.be.revertedWithPanic(); - }); - }); - }); - - describe('to a contract that does not implement the required function', function () { - it('reverts', async function () { - const invalidReceiver = this.token; - - await expect( - this.token - .connect(this.holder) - .safeBatchTransferFrom( - this.holder, - invalidReceiver, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidReceiver') - .withArgs(invalidReceiver); - }); - }); - }); - - shouldSupportInterfaces(['ERC1155', 'ERC1155MetadataURI']); - }); -} - -module.exports = { - shouldBehaveLikeERC1155, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/ERC1155.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/ERC1155.test.js deleted file mode 100644 index 8b0a672b2e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/ERC1155.test.js +++ /dev/null @@ -1,213 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { zip } = require('../../helpers/iterate'); -const { shouldBehaveLikeERC1155 } = require('./ERC1155.behavior'); - -const initialURI = 'https://token-cdn-domain/{id}.json'; - -async function fixture() { - const [operator, holder, ...otherAccounts] = await ethers.getSigners(); - const token = await ethers.deployContract('$ERC1155', [initialURI]); - return { token, operator, holder, otherAccounts }; -} - -describe('ERC1155', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeERC1155(); - - describe('internal functions', function () { - const tokenId = 1990n; - const mintValue = 9001n; - const burnValue = 3000n; - - const tokenBatchIds = [2000n, 2010n, 2020n]; - const mintValues = [5000n, 10000n, 42195n]; - const burnValues = [5000n, 9001n, 195n]; - - const data = '0x12345678'; - - describe('_mint', function () { - it('reverts with a zero destination address', async function () { - await expect(this.token.$_mint(ethers.ZeroAddress, tokenId, mintValue, data)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidReceiver') - .withArgs(ethers.ZeroAddress); - }); - - describe('with minted tokens', function () { - beforeEach(async function () { - this.tx = await this.token.connect(this.operator).$_mint(this.holder, tokenId, mintValue, data); - }); - - it('emits a TransferSingle event', async function () { - await expect(this.tx) - .to.emit(this.token, 'TransferSingle') - .withArgs(this.operator, ethers.ZeroAddress, this.holder, tokenId, mintValue); - }); - - it('credits the minted token value', async function () { - expect(await this.token.balanceOf(this.holder, tokenId)).to.equal(mintValue); - }); - }); - }); - - describe('_mintBatch', function () { - it('reverts with a zero destination address', async function () { - await expect(this.token.$_mintBatch(ethers.ZeroAddress, tokenBatchIds, mintValues, data)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidReceiver') - .withArgs(ethers.ZeroAddress); - }); - - it('reverts if length of inputs do not match', async function () { - await expect(this.token.$_mintBatch(this.holder, tokenBatchIds, mintValues.slice(1), data)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidArrayLength') - .withArgs(tokenBatchIds.length, mintValues.length - 1); - - await expect(this.token.$_mintBatch(this.holder, tokenBatchIds.slice(1), mintValues, data)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidArrayLength') - .withArgs(tokenBatchIds.length - 1, mintValues.length); - }); - - describe('with minted batch of tokens', function () { - beforeEach(async function () { - this.tx = await this.token.connect(this.operator).$_mintBatch(this.holder, tokenBatchIds, mintValues, data); - }); - - it('emits a TransferBatch event', async function () { - await expect(this.tx) - .to.emit(this.token, 'TransferBatch') - .withArgs(this.operator, ethers.ZeroAddress, this.holder, tokenBatchIds, mintValues); - }); - - it('credits the minted batch of tokens', async function () { - const holderBatchBalances = await this.token.balanceOfBatch( - tokenBatchIds.map(() => this.holder), - tokenBatchIds, - ); - - expect(holderBatchBalances).to.deep.equal(mintValues); - }); - }); - }); - - describe('_burn', function () { - it("reverts when burning the zero account's tokens", async function () { - await expect(this.token.$_burn(ethers.ZeroAddress, tokenId, mintValue)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidSender') - .withArgs(ethers.ZeroAddress); - }); - - it('reverts when burning a non-existent token id', async function () { - await expect(this.token.$_burn(this.holder, tokenId, mintValue)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InsufficientBalance') - .withArgs(this.holder, 0, mintValue, tokenId); - }); - - it('reverts when burning more than available tokens', async function () { - await this.token.connect(this.operator).$_mint(this.holder, tokenId, mintValue, data); - - await expect(this.token.$_burn(this.holder, tokenId, mintValue + 1n)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InsufficientBalance') - .withArgs(this.holder, mintValue, mintValue + 1n, tokenId); - }); - - describe('with minted-then-burnt tokens', function () { - beforeEach(async function () { - await this.token.$_mint(this.holder, tokenId, mintValue, data); - this.tx = await this.token.connect(this.operator).$_burn(this.holder, tokenId, burnValue); - }); - - it('emits a TransferSingle event', async function () { - await expect(this.tx) - .to.emit(this.token, 'TransferSingle') - .withArgs(this.operator, this.holder, ethers.ZeroAddress, tokenId, burnValue); - }); - - it('accounts for both minting and burning', async function () { - expect(await this.token.balanceOf(this.holder, tokenId)).to.equal(mintValue - burnValue); - }); - }); - }); - - describe('_burnBatch', function () { - it("reverts when burning the zero account's tokens", async function () { - await expect(this.token.$_burnBatch(ethers.ZeroAddress, tokenBatchIds, burnValues)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidSender') - .withArgs(ethers.ZeroAddress); - }); - - it('reverts if length of inputs do not match', async function () { - await expect(this.token.$_burnBatch(this.holder, tokenBatchIds, burnValues.slice(1))) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidArrayLength') - .withArgs(tokenBatchIds.length, burnValues.length - 1); - - await expect(this.token.$_burnBatch(this.holder, tokenBatchIds.slice(1), burnValues)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InvalidArrayLength') - .withArgs(tokenBatchIds.length - 1, burnValues.length); - }); - - it('reverts when burning a non-existent token id', async function () { - await expect(this.token.$_burnBatch(this.holder, tokenBatchIds, burnValues)) - .to.be.revertedWithCustomError(this.token, 'ERC1155InsufficientBalance') - .withArgs(this.holder, 0, burnValues[0], tokenBatchIds[0]); - }); - - describe('with minted-then-burnt tokens', function () { - beforeEach(async function () { - await this.token.$_mintBatch(this.holder, tokenBatchIds, mintValues, data); - this.tx = await this.token.connect(this.operator).$_burnBatch(this.holder, tokenBatchIds, burnValues); - }); - - it('emits a TransferBatch event', async function () { - await expect(this.tx) - .to.emit(this.token, 'TransferBatch') - .withArgs(this.operator, this.holder, ethers.ZeroAddress, tokenBatchIds, burnValues); - }); - - it('accounts for both minting and burning', async function () { - const holderBatchBalances = await this.token.balanceOfBatch( - tokenBatchIds.map(() => this.holder), - tokenBatchIds, - ); - - expect(holderBatchBalances).to.deep.equal( - zip(mintValues, burnValues).map(([mintValue, burnValue]) => mintValue - burnValue), - ); - }); - }); - }); - }); - - describe('ERC1155MetadataURI', function () { - const firstTokenID = 42n; - const secondTokenID = 1337n; - - it('emits no URI event in constructor', async function () { - await expect(this.token.deploymentTransaction()).to.not.emit(this.token, 'URI'); - }); - - it('sets the initial URI for all token types', async function () { - expect(await this.token.uri(firstTokenID)).to.equal(initialURI); - expect(await this.token.uri(secondTokenID)).to.equal(initialURI); - }); - - describe('_setURI', function () { - const newURI = 'https://token-cdn-domain/{locale}/{id}.json'; - - it('emits no URI event', async function () { - await expect(this.token.$_setURI(newURI)).to.not.emit(this.token, 'URI'); - }); - - it('sets the new URI for all token types', async function () { - await this.token.$_setURI(newURI); - - expect(await this.token.uri(firstTokenID)).to.equal(newURI); - expect(await this.token.uri(secondTokenID)).to.equal(newURI); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/extensions/ERC1155Burnable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/extensions/ERC1155Burnable.test.js deleted file mode 100644 index 01e7ee2edb..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/extensions/ERC1155Burnable.test.js +++ /dev/null @@ -1,66 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const ids = [42n, 1137n]; -const values = [3000n, 9902n]; - -async function fixture() { - const [holder, operator, other] = await ethers.getSigners(); - - const token = await ethers.deployContract('$ERC1155Burnable', ['https://token-cdn-domain/{id}.json']); - await token.$_mint(holder, ids[0], values[0], '0x'); - await token.$_mint(holder, ids[1], values[1], '0x'); - - return { token, holder, operator, other }; -} - -describe('ERC1155Burnable', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('burn', function () { - it('holder can burn their tokens', async function () { - await this.token.connect(this.holder).burn(this.holder, ids[0], values[0] - 1n); - - expect(await this.token.balanceOf(this.holder, ids[0])).to.equal(1n); - }); - - it("approved operators can burn the holder's tokens", async function () { - await this.token.connect(this.holder).setApprovalForAll(this.operator, true); - await this.token.connect(this.operator).burn(this.holder, ids[0], values[0] - 1n); - - expect(await this.token.balanceOf(this.holder, ids[0])).to.equal(1n); - }); - - it("unapproved accounts cannot burn the holder's tokens", async function () { - await expect(this.token.connect(this.other).burn(this.holder, ids[0], values[0] - 1n)) - .to.be.revertedWithCustomError(this.token, 'ERC1155MissingApprovalForAll') - .withArgs(this.other, this.holder); - }); - }); - - describe('burnBatch', function () { - it('holder can burn their tokens', async function () { - await this.token.connect(this.holder).burnBatch(this.holder, ids, [values[0] - 1n, values[1] - 2n]); - - expect(await this.token.balanceOf(this.holder, ids[0])).to.equal(1n); - expect(await this.token.balanceOf(this.holder, ids[1])).to.equal(2n); - }); - - it("approved operators can burn the holder's tokens", async function () { - await this.token.connect(this.holder).setApprovalForAll(this.operator, true); - await this.token.connect(this.operator).burnBatch(this.holder, ids, [values[0] - 1n, values[1] - 2n]); - - expect(await this.token.balanceOf(this.holder, ids[0])).to.equal(1n); - expect(await this.token.balanceOf(this.holder, ids[1])).to.equal(2n); - }); - - it("unapproved accounts cannot burn the holder's tokens", async function () { - await expect(this.token.connect(this.other).burnBatch(this.holder, ids, [values[0] - 1n, values[1] - 2n])) - .to.be.revertedWithCustomError(this.token, 'ERC1155MissingApprovalForAll') - .withArgs(this.other, this.holder); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/extensions/ERC1155Pausable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/extensions/ERC1155Pausable.test.js deleted file mode 100644 index 81c4f69bc4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/extensions/ERC1155Pausable.test.js +++ /dev/null @@ -1,105 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -async function fixture() { - const [holder, operator, receiver, other] = await ethers.getSigners(); - const token = await ethers.deployContract('$ERC1155Pausable', ['https://token-cdn-domain/{id}.json']); - return { token, holder, operator, receiver, other }; -} - -describe('ERC1155Pausable', function () { - const firstTokenId = 37n; - const firstTokenValue = 42n; - const secondTokenId = 19842n; - const secondTokenValue = 23n; - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('when token is paused', function () { - beforeEach(async function () { - await this.token.connect(this.holder).setApprovalForAll(this.operator, true); - await this.token.$_mint(this.holder, firstTokenId, firstTokenValue, '0x'); - await this.token.$_pause(); - }); - - it('reverts when trying to safeTransferFrom from holder', async function () { - await expect( - this.token - .connect(this.holder) - .safeTransferFrom(this.holder, this.receiver, firstTokenId, firstTokenValue, '0x'), - ).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - - it('reverts when trying to safeTransferFrom from operator', async function () { - await expect( - this.token - .connect(this.operator) - .safeTransferFrom(this.holder, this.receiver, firstTokenId, firstTokenValue, '0x'), - ).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - - it('reverts when trying to safeBatchTransferFrom from holder', async function () { - await expect( - this.token - .connect(this.holder) - .safeBatchTransferFrom(this.holder, this.receiver, [firstTokenId], [firstTokenValue], '0x'), - ).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - - it('reverts when trying to safeBatchTransferFrom from operator', async function () { - await expect( - this.token - .connect(this.operator) - .safeBatchTransferFrom(this.holder, this.receiver, [firstTokenId], [firstTokenValue], '0x'), - ).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - - it('reverts when trying to mint', async function () { - await expect(this.token.$_mint(this.holder, secondTokenId, secondTokenValue, '0x')).to.be.revertedWithCustomError( - this.token, - 'EnforcedPause', - ); - }); - - it('reverts when trying to mintBatch', async function () { - await expect( - this.token.$_mintBatch(this.holder, [secondTokenId], [secondTokenValue], '0x'), - ).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - - it('reverts when trying to burn', async function () { - await expect(this.token.$_burn(this.holder, firstTokenId, firstTokenValue)).to.be.revertedWithCustomError( - this.token, - 'EnforcedPause', - ); - }); - - it('reverts when trying to burnBatch', async function () { - await expect( - this.token.$_burnBatch(this.holder, [firstTokenId], [firstTokenValue]), - ).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - - describe('setApprovalForAll', function () { - it('approves an operator', async function () { - await this.token.connect(this.holder).setApprovalForAll(this.other, true); - expect(await this.token.isApprovedForAll(this.holder, this.other)).to.be.true; - }); - }); - - describe('balanceOf', function () { - it('returns the token value owned by the given address', async function () { - expect(await this.token.balanceOf(this.holder, firstTokenId)).to.equal(firstTokenValue); - }); - }); - - describe('isApprovedForAll', function () { - it('returns the approval of the operator', async function () { - expect(await this.token.isApprovedForAll(this.holder, this.operator)).to.be.true; - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/extensions/ERC1155Supply.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/extensions/ERC1155Supply.test.js deleted file mode 100644 index cca36a0dfe..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/extensions/ERC1155Supply.test.js +++ /dev/null @@ -1,119 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -async function fixture() { - const [holder] = await ethers.getSigners(); - const token = await ethers.deployContract('$ERC1155Supply', ['https://token-cdn-domain/{id}.json']); - return { token, holder }; -} - -describe('ERC1155Supply', function () { - const firstTokenId = 37n; - const firstTokenValue = 42n; - const secondTokenId = 19842n; - const secondTokenValue = 23n; - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('before mint', function () { - it('exist', async function () { - expect(await this.token.exists(firstTokenId)).to.be.false; - }); - - it('totalSupply', async function () { - expect(await this.token.totalSupply(ethers.Typed.uint256(firstTokenId))).to.equal(0n); - expect(await this.token.totalSupply()).to.equal(0n); - }); - }); - - describe('after mint', function () { - describe('single', function () { - beforeEach(async function () { - await this.token.$_mint(this.holder, firstTokenId, firstTokenValue, '0x'); - }); - - it('exist', async function () { - expect(await this.token.exists(firstTokenId)).to.be.true; - }); - - it('totalSupply', async function () { - expect(await this.token.totalSupply(ethers.Typed.uint256(firstTokenId))).to.equal(firstTokenValue); - expect(await this.token.totalSupply()).to.equal(firstTokenValue); - }); - }); - - describe('batch', function () { - beforeEach(async function () { - await this.token.$_mintBatch( - this.holder, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ); - }); - - it('exist', async function () { - expect(await this.token.exists(firstTokenId)).to.be.true; - expect(await this.token.exists(secondTokenId)).to.be.true; - }); - - it('totalSupply', async function () { - expect(await this.token.totalSupply(ethers.Typed.uint256(firstTokenId))).to.equal(firstTokenValue); - expect(await this.token.totalSupply(ethers.Typed.uint256(secondTokenId))).to.equal(secondTokenValue); - expect(await this.token.totalSupply()).to.equal(firstTokenValue + secondTokenValue); - }); - }); - }); - - describe('after burn', function () { - describe('single', function () { - beforeEach(async function () { - await this.token.$_mint(this.holder, firstTokenId, firstTokenValue, '0x'); - await this.token.$_burn(this.holder, firstTokenId, firstTokenValue); - }); - - it('exist', async function () { - expect(await this.token.exists(firstTokenId)).to.be.false; - }); - - it('totalSupply', async function () { - expect(await this.token.totalSupply(ethers.Typed.uint256(firstTokenId))).to.equal(0n); - expect(await this.token.totalSupply()).to.equal(0n); - }); - }); - - describe('batch', function () { - beforeEach(async function () { - await this.token.$_mintBatch( - this.holder, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ); - await this.token.$_burnBatch(this.holder, [firstTokenId, secondTokenId], [firstTokenValue, secondTokenValue]); - }); - - it('exist', async function () { - expect(await this.token.exists(firstTokenId)).to.be.false; - expect(await this.token.exists(secondTokenId)).to.be.false; - }); - - it('totalSupply', async function () { - expect(await this.token.totalSupply(ethers.Typed.uint256(firstTokenId))).to.equal(0n); - expect(await this.token.totalSupply(ethers.Typed.uint256(secondTokenId))).to.equal(0n); - expect(await this.token.totalSupply()).to.equal(0n); - }); - }); - }); - - describe('other', function () { - it('supply unaffected by no-op', async function () { - await this.token.$_update(ethers.ZeroAddress, ethers.ZeroAddress, [firstTokenId], [firstTokenValue]); - expect(await this.token.totalSupply(ethers.Typed.uint256(firstTokenId))).to.equal(0n); - expect(await this.token.totalSupply()).to.equal(0n); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/extensions/ERC1155URIStorage.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/extensions/ERC1155URIStorage.test.js deleted file mode 100644 index a0d9b57048..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/extensions/ERC1155URIStorage.test.js +++ /dev/null @@ -1,70 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const erc1155Uri = 'https://token.com/nfts/'; -const baseUri = 'https://token.com/'; -const tokenId = 1n; -const value = 3000n; - -describe('ERC1155URIStorage', function () { - describe('with base uri set', function () { - async function fixture() { - const [holder] = await ethers.getSigners(); - - const token = await ethers.deployContract('$ERC1155URIStorage', [erc1155Uri]); - await token.$_setBaseURI(baseUri); - await token.$_mint(holder, tokenId, value, '0x'); - - return { token, holder }; - } - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('can request the token uri, returning the erc1155 uri if no token uri was set', async function () { - expect(await this.token.uri(tokenId)).to.equal(erc1155Uri); - }); - - it('can request the token uri, returning the concatenated uri if a token uri was set', async function () { - const tokenUri = '1234/'; - const expectedUri = `${baseUri}${tokenUri}`; - - await expect(this.token.$_setURI(ethers.Typed.uint256(tokenId), tokenUri)) - .to.emit(this.token, 'URI') - .withArgs(expectedUri, tokenId); - - expect(await this.token.uri(tokenId)).to.equal(expectedUri); - }); - }); - - describe('with base uri set to the empty string', function () { - async function fixture() { - const [holder] = await ethers.getSigners(); - - const token = await ethers.deployContract('$ERC1155URIStorage', ['']); - await token.$_mint(holder, tokenId, value, '0x'); - - return { token, holder }; - } - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('can request the token uri, returning an empty string if no token uri was set', async function () { - expect(await this.token.uri(tokenId)).to.equal(''); - }); - - it('can request the token uri, returning the token uri if a token uri was set', async function () { - const tokenUri = 'ipfs://1234/'; - - await expect(this.token.$_setURI(ethers.Typed.uint256(tokenId), tokenUri)) - .to.emit(this.token, 'URI') - .withArgs(tokenUri, tokenId); - - expect(await this.token.uri(tokenId)).to.equal(tokenUri); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/utils/ERC1155Holder.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/utils/ERC1155Holder.test.js deleted file mode 100644 index 9bff487ada..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/utils/ERC1155Holder.test.js +++ /dev/null @@ -1,56 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { shouldSupportInterfaces } = require('../../../utils/introspection/SupportsInterface.behavior'); - -const ids = [1n, 2n, 3n]; -const values = [1000n, 2000n, 3000n]; -const data = '0x12345678'; - -async function fixture() { - const [owner] = await ethers.getSigners(); - - const token = await ethers.deployContract('$ERC1155', ['https://token-cdn-domain/{id}.json']); - const mock = await ethers.deployContract('$ERC1155Holder'); - - await token.$_mintBatch(owner, ids, values, '0x'); - - return { owner, token, mock }; -} - -describe('ERC1155Holder', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldSupportInterfaces(['ERC1155Receiver']); - - it('receives ERC1155 tokens from a single ID', async function () { - await this.token.connect(this.owner).safeTransferFrom(this.owner, this.mock, ids[0], values[0], data); - - expect(await this.token.balanceOf(this.mock, ids[0])).to.equal(values[0]); - - for (let i = 1; i < ids.length; i++) { - expect(await this.token.balanceOf(this.mock, ids[i])).to.equal(0n); - } - }); - - it('receives ERC1155 tokens from a multiple IDs', async function () { - expect( - await this.token.balanceOfBatch( - ids.map(() => this.mock), - ids, - ), - ).to.deep.equal(ids.map(() => 0n)); - - await this.token.connect(this.owner).safeBatchTransferFrom(this.owner, this.mock, ids, values, data); - - expect( - await this.token.balanceOfBatch( - ids.map(() => this.mock), - ids, - ), - ).to.deep.equal(values); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/utils/ERC1155Utils.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/utils/ERC1155Utils.test.js deleted file mode 100644 index 5687568d34..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC1155/utils/ERC1155Utils.test.js +++ /dev/null @@ -1,299 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { RevertType } = require('../../../helpers/enums'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -const firstTokenId = 1n; -const secondTokenId = 2n; -const firstTokenValue = 1000n; -const secondTokenValue = 1000n; - -const RECEIVER_SINGLE_MAGIC_VALUE = '0xf23a6e61'; -const RECEIVER_BATCH_MAGIC_VALUE = '0xbc197c81'; - -const deployReceiver = ( - revertType, - returnValueSingle = RECEIVER_SINGLE_MAGIC_VALUE, - returnValueBatched = RECEIVER_BATCH_MAGIC_VALUE, -) => ethers.deployContract('$ERC1155ReceiverMock', [returnValueSingle, returnValueBatched, revertType]); - -const fixture = async () => { - const [eoa, operator, owner] = await ethers.getSigners(); - const utils = await ethers.deployContract('$ERC1155Utils'); - - const receivers = { - correct: await deployReceiver(RevertType.None), - invalid: await deployReceiver(RevertType.None, '0xdeadbeef', '0xdeadbeef'), - message: await deployReceiver(RevertType.RevertWithMessage), - empty: await deployReceiver(RevertType.RevertWithoutMessage), - customError: await deployReceiver(RevertType.RevertWithCustomError), - panic: await deployReceiver(RevertType.Panic), - nonReceiver: await ethers.deployContract('CallReceiverMock'), - eoa, - }; - - return { operator, owner, utils, receivers }; -}; - -describe('ERC1155Utils', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('onERC1155Received', function () { - it('succeeds when called by an EOA', async function () { - await expect( - this.utils.$checkOnERC1155Received( - this.operator, - this.owner, - this.receivers.eoa, - firstTokenId, - firstTokenValue, - '0x', - ), - ).to.not.be.reverted; - }); - - it('succeeds when data is passed', async function () { - const data = '0x12345678'; - await expect( - this.utils.$checkOnERC1155Received( - this.operator, - this.owner, - this.receivers.correct, - firstTokenId, - firstTokenValue, - data, - ), - ).to.not.be.reverted; - }); - - it('succeeds when data is empty', async function () { - await expect( - this.utils.$checkOnERC1155Received( - this.operator, - this.owner, - this.receivers.correct, - firstTokenId, - firstTokenValue, - '0x', - ), - ).to.not.be.reverted; - }); - - it('reverts when receiver returns invalid value', async function () { - await expect( - this.utils.$checkOnERC1155Received( - this.operator, - this.owner, - this.receivers.invalid, - firstTokenId, - firstTokenValue, - '0x', - ), - ) - .to.be.revertedWithCustomError(this.utils, 'ERC1155InvalidReceiver') - .withArgs(this.receivers.invalid); - }); - - it('reverts when receiver reverts with message', async function () { - await expect( - this.utils.$checkOnERC1155Received( - this.operator, - this.owner, - this.receivers.message, - firstTokenId, - firstTokenValue, - '0x', - ), - ).to.be.revertedWith('ERC1155ReceiverMock: reverting on receive'); - }); - - it('reverts when receiver reverts without message', async function () { - await expect( - this.utils.$checkOnERC1155Received( - this.operator, - this.owner, - this.receivers.empty, - firstTokenId, - firstTokenValue, - '0x', - ), - ) - .to.be.revertedWithCustomError(this.utils, 'ERC1155InvalidReceiver') - .withArgs(this.receivers.empty); - }); - - it('reverts when receiver reverts with custom error', async function () { - await expect( - this.utils.$checkOnERC1155Received( - this.operator, - this.owner, - this.receivers.customError, - firstTokenId, - firstTokenValue, - '0x', - ), - ) - .to.be.revertedWithCustomError(this.receivers.customError, 'CustomError') - .withArgs(RECEIVER_SINGLE_MAGIC_VALUE); - }); - - it('reverts when receiver panics', async function () { - await expect( - this.utils.$checkOnERC1155Received( - this.operator, - this.owner, - this.receivers.panic, - firstTokenId, - firstTokenValue, - '0x', - ), - ).to.be.revertedWithPanic(PANIC_CODES.DIVISION_BY_ZERO); - }); - - it('reverts when receiver does not implement onERC1155Received', async function () { - await expect( - this.utils.$checkOnERC1155Received( - this.operator, - this.owner, - this.receivers.nonReceiver, - firstTokenId, - firstTokenValue, - '0x', - ), - ) - .to.be.revertedWithCustomError(this.utils, 'ERC1155InvalidReceiver') - .withArgs(this.receivers.nonReceiver); - }); - }); - - describe('onERC1155BatchReceived', function () { - it('succeeds when called by an EOA', async function () { - await expect( - this.utils.$checkOnERC1155BatchReceived( - this.operator, - this.owner, - this.receivers.eoa, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ).to.not.be.reverted; - }); - - it('succeeds when data is passed', async function () { - const data = '0x12345678'; - await expect( - this.utils.$checkOnERC1155BatchReceived( - this.operator, - this.owner, - this.receivers.correct, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - data, - ), - ).to.not.be.reverted; - }); - - it('succeeds when data is empty', async function () { - await expect( - this.utils.$checkOnERC1155BatchReceived( - this.operator, - this.owner, - this.receivers.correct, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ).to.not.be.reverted; - }); - - it('reverts when receiver returns invalid value', async function () { - await expect( - this.utils.$checkOnERC1155BatchReceived( - this.operator, - this.owner, - this.receivers.invalid, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ) - .to.be.revertedWithCustomError(this.utils, 'ERC1155InvalidReceiver') - .withArgs(this.receivers.invalid); - }); - - it('reverts when receiver reverts with message', async function () { - await expect( - this.utils.$checkOnERC1155BatchReceived( - this.operator, - this.owner, - this.receivers.message, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ).to.be.revertedWith('ERC1155ReceiverMock: reverting on batch receive'); - }); - - it('reverts when receiver reverts without message', async function () { - await expect( - this.utils.$checkOnERC1155BatchReceived( - this.operator, - this.owner, - this.receivers.empty, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ) - .to.be.revertedWithCustomError(this.utils, 'ERC1155InvalidReceiver') - .withArgs(this.receivers.empty); - }); - - it('reverts when receiver reverts with custom error', async function () { - await expect( - this.utils.$checkOnERC1155BatchReceived( - this.operator, - this.owner, - this.receivers.customError, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ) - .to.be.revertedWithCustomError(this.receivers.customError, 'CustomError') - .withArgs(RECEIVER_SINGLE_MAGIC_VALUE); - }); - - it('reverts when receiver panics', async function () { - await expect( - this.utils.$checkOnERC1155BatchReceived( - this.operator, - this.owner, - this.receivers.panic, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ).to.be.revertedWithPanic(PANIC_CODES.DIVISION_BY_ZERO); - }); - - it('reverts when receiver does not implement onERC1155BatchReceived', async function () { - await expect( - this.utils.$checkOnERC1155BatchReceived( - this.operator, - this.owner, - this.receivers.nonReceiver, - [firstTokenId, secondTokenId], - [firstTokenValue, secondTokenValue], - '0x', - ), - ) - .to.be.revertedWithCustomError(this.utils, 'ERC1155InvalidReceiver') - .withArgs(this.receivers.nonReceiver); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/ERC20.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/ERC20.behavior.js deleted file mode 100644 index 748df4b85a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/ERC20.behavior.js +++ /dev/null @@ -1,269 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); - -function shouldBehaveLikeERC20(initialSupply, opts = {}) { - const { forcedApproval } = opts; - - beforeEach(async function () { - [this.holder, this.recipient, this.other] = this.accounts; - }); - - it('total supply: returns the total token value', async function () { - expect(await this.token.totalSupply()).to.equal(initialSupply); - }); - - describe('balanceOf', function () { - it('returns zero when the requested account has no tokens', async function () { - expect(await this.token.balanceOf(this.other)).to.equal(0n); - }); - - it('returns the total token value when the requested account has some tokens', async function () { - expect(await this.token.balanceOf(this.holder)).to.equal(initialSupply); - }); - }); - - describe('transfer', function () { - beforeEach(function () { - this.transfer = (from, to, value) => this.token.connect(from).transfer(to, value); - }); - - shouldBehaveLikeERC20Transfer(initialSupply); - }); - - describe('transfer from', function () { - describe('when the token owner is not the zero address', function () { - describe('when the recipient is not the zero address', function () { - describe('when the spender has enough allowance', function () { - beforeEach(async function () { - await this.token.connect(this.holder).approve(this.recipient, initialSupply); - }); - - describe('when the token owner has enough balance', function () { - const value = initialSupply; - - beforeEach(async function () { - this.tx = await this.token.connect(this.recipient).transferFrom(this.holder, this.other, value); - }); - - it('transfers the requested value', async function () { - await expect(this.tx).to.changeTokenBalances(this.token, [this.holder, this.other], [-value, value]); - }); - - it('decreases the spender allowance', async function () { - expect(await this.token.allowance(this.holder, this.recipient)).to.equal(0n); - }); - - it('emits a transfer event', async function () { - await expect(this.tx).to.emit(this.token, 'Transfer').withArgs(this.holder, this.other, value); - }); - - if (forcedApproval) { - it('emits an approval event', async function () { - await expect(this.tx) - .to.emit(this.token, 'Approval') - .withArgs( - this.holder.address, - this.recipient.address, - await this.token.allowance(this.holder, this.recipient), - ); - }); - } else { - it('does not emit an approval event', async function () { - await expect(this.tx).to.not.emit(this.token, 'Approval'); - }); - } - }); - - it('reverts when the token owner does not have enough balance', async function () { - const value = initialSupply; - await this.token.connect(this.holder).transfer(this.other, 1n); - await expect(this.token.connect(this.recipient).transferFrom(this.holder, this.other, value)) - .to.revertedWithCustomError(this.token, 'ERC20InsufficientBalance') - .withArgs(this.holder, value - 1n, value); - }); - }); - - describe('when the spender does not have enough allowance', function () { - const allowance = initialSupply - 1n; - - beforeEach(async function () { - await this.token.connect(this.holder).approve(this.recipient, allowance); - }); - - it('reverts when the token owner has enough balance', async function () { - const value = initialSupply; - await expect(this.token.connect(this.recipient).transferFrom(this.holder, this.other, value)) - .to.be.revertedWithCustomError(this.token, 'ERC20InsufficientAllowance') - .withArgs(this.recipient, allowance, value); - }); - - it('reverts when the token owner does not have enough balance', async function () { - const value = allowance; - await this.token.connect(this.holder).transfer(this.other, 2); - await expect(this.token.connect(this.recipient).transferFrom(this.holder, this.other, value)) - .to.be.revertedWithCustomError(this.token, 'ERC20InsufficientBalance') - .withArgs(this.holder, value - 1n, value); - }); - }); - - describe('when the spender has unlimited allowance', function () { - beforeEach(async function () { - await this.token.connect(this.holder).approve(this.recipient, ethers.MaxUint256); - this.tx = await this.token.connect(this.recipient).transferFrom(this.holder, this.other, 1n); - }); - - it('does not decrease the spender allowance', async function () { - expect(await this.token.allowance(this.holder, this.recipient)).to.equal(ethers.MaxUint256); - }); - - it('does not emit an approval event', async function () { - await expect(this.tx).to.not.emit(this.token, 'Approval'); - }); - }); - }); - - it('reverts when the recipient is the zero address', async function () { - const value = initialSupply; - await this.token.connect(this.holder).approve(this.recipient, value); - await expect(this.token.connect(this.recipient).transferFrom(this.holder, ethers.ZeroAddress, value)) - .to.be.revertedWithCustomError(this.token, 'ERC20InvalidReceiver') - .withArgs(ethers.ZeroAddress); - }); - }); - - it('reverts when the token owner is the zero address', async function () { - // transferFrom does a spendAllowance before moving the assets - // - default behavior (ERC20) is to always update the approval using `_approve`. This will fail because the - // approver (owner) is address(0). This happens even if the amount transferred is zero, and the approval update - // is not actually necessary. - // - in ERC20TemporaryAllowance, transfer of 0 value will not update allowance (temporary or persistent) - // therefore the spendAllowance does not revert. However, the transfer of asset will revert because the sender - // is address(0) - const errorName = this.token.temporaryApprove ? 'ERC20InvalidSender' : 'ERC20InvalidApprover'; - - const value = 0n; - await expect(this.token.connect(this.recipient).transferFrom(ethers.ZeroAddress, this.recipient, value)) - .to.be.revertedWithCustomError(this.token, errorName) - .withArgs(ethers.ZeroAddress); - }); - }); - - describe('approve', function () { - beforeEach(function () { - this.approve = (owner, spender, value) => this.token.connect(owner).approve(spender, value); - }); - - shouldBehaveLikeERC20Approve(initialSupply); - }); -} - -function shouldBehaveLikeERC20Transfer(balance) { - describe('when the recipient is not the zero address', function () { - it('reverts when the sender does not have enough balance', async function () { - const value = balance + 1n; - await expect(this.transfer(this.holder, this.recipient, value)) - .to.be.revertedWithCustomError(this.token, 'ERC20InsufficientBalance') - .withArgs(this.holder, balance, value); - }); - - describe('when the sender transfers all balance', function () { - const value = balance; - - beforeEach(async function () { - this.tx = await this.transfer(this.holder, this.recipient, value); - }); - - it('transfers the requested value', async function () { - await expect(this.tx).to.changeTokenBalances(this.token, [this.holder, this.recipient], [-value, value]); - }); - - it('emits a transfer event', async function () { - await expect(this.tx).to.emit(this.token, 'Transfer').withArgs(this.holder, this.recipient, value); - }); - }); - - describe('when the sender transfers zero tokens', function () { - const value = 0n; - - beforeEach(async function () { - this.tx = await this.transfer(this.holder, this.recipient, value); - }); - - it('transfers the requested value', async function () { - await expect(this.tx).to.changeTokenBalances(this.token, [this.holder, this.recipient], [0n, 0n]); - }); - - it('emits a transfer event', async function () { - await expect(this.tx).to.emit(this.token, 'Transfer').withArgs(this.holder, this.recipient, value); - }); - }); - }); - - it('reverts when the recipient is the zero address', async function () { - await expect(this.transfer(this.holder, ethers.ZeroAddress, balance)) - .to.be.revertedWithCustomError(this.token, 'ERC20InvalidReceiver') - .withArgs(ethers.ZeroAddress); - }); -} - -function shouldBehaveLikeERC20Approve(supply) { - describe('when the spender is not the zero address', function () { - describe('when the sender has enough balance', function () { - const value = supply; - - it('emits an approval event', async function () { - await expect(this.approve(this.holder, this.recipient, value)) - .to.emit(this.token, 'Approval') - .withArgs(this.holder, this.recipient, value); - }); - - it('approves the requested value when there was no approved value before', async function () { - await this.approve(this.holder, this.recipient, value); - - expect(await this.token.allowance(this.holder, this.recipient)).to.equal(value); - }); - - it('approves the requested value and replaces the previous one when the spender had an approved value', async function () { - await this.approve(this.holder, this.recipient, 1n); - await this.approve(this.holder, this.recipient, value); - - expect(await this.token.allowance(this.holder, this.recipient)).to.equal(value); - }); - }); - - describe('when the sender does not have enough balance', function () { - const value = supply + 1n; - - it('emits an approval event', async function () { - await expect(this.approve(this.holder, this.recipient, value)) - .to.emit(this.token, 'Approval') - .withArgs(this.holder, this.recipient, value); - }); - - it('approves the requested value when there was no approved value before', async function () { - await this.approve(this.holder, this.recipient, value); - - expect(await this.token.allowance(this.holder, this.recipient)).to.equal(value); - }); - - it('approves the requested value and replaces the previous one when the spender had an approved value', async function () { - await this.approve(this.holder, this.recipient, 1n); - await this.approve(this.holder, this.recipient, value); - - expect(await this.token.allowance(this.holder, this.recipient)).to.equal(value); - }); - }); - }); - - it('reverts when the spender is the zero address', async function () { - await expect(this.approve(this.holder, ethers.ZeroAddress, supply)) - .to.be.revertedWithCustomError(this.token, `ERC20InvalidSpender`) - .withArgs(ethers.ZeroAddress); - }); -} - -module.exports = { - shouldBehaveLikeERC20, - shouldBehaveLikeERC20Transfer, - shouldBehaveLikeERC20Approve, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/ERC20.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/ERC20.test.js deleted file mode 100644 index 2d9eefe1c8..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/ERC20.test.js +++ /dev/null @@ -1,199 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -const { - shouldBehaveLikeERC20, - shouldBehaveLikeERC20Transfer, - shouldBehaveLikeERC20Approve, -} = require('./ERC20.behavior'); - -const TOKENS = [{ Token: '$ERC20' }, { Token: '$ERC20ApprovalMock', forcedApproval: true }]; - -const name = 'My Token'; -const symbol = 'MTKN'; -const initialSupply = 100n; - -describe('ERC20', function () { - for (const { Token, forcedApproval } of TOKENS) { - describe(Token, function () { - const fixture = async () => { - // this.accounts is used by shouldBehaveLikeERC20 - const accounts = await ethers.getSigners(); - const [holder, recipient] = accounts; - - const token = await ethers.deployContract(Token, [name, symbol]); - await token.$_mint(holder, initialSupply); - - return { accounts, holder, recipient, token }; - }; - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeERC20(initialSupply, { forcedApproval }); - - it('has a name', async function () { - expect(await this.token.name()).to.equal(name); - }); - - it('has a symbol', async function () { - expect(await this.token.symbol()).to.equal(symbol); - }); - - it('has 18 decimals', async function () { - expect(await this.token.decimals()).to.equal(18n); - }); - - describe('_mint', function () { - const value = 50n; - it('rejects a null account', async function () { - await expect(this.token.$_mint(ethers.ZeroAddress, value)) - .to.be.revertedWithCustomError(this.token, 'ERC20InvalidReceiver') - .withArgs(ethers.ZeroAddress); - }); - - it('rejects overflow', async function () { - await expect(this.token.$_mint(this.recipient, ethers.MaxUint256)).to.be.revertedWithPanic( - PANIC_CODES.ARITHMETIC_UNDER_OR_OVERFLOW, - ); - }); - - describe('for a non zero account', function () { - beforeEach('minting', async function () { - this.tx = await this.token.$_mint(this.recipient, value); - }); - - it('increments totalSupply', async function () { - await expect(await this.token.totalSupply()).to.equal(initialSupply + value); - }); - - it('increments recipient balance', async function () { - await expect(this.tx).to.changeTokenBalance(this.token, this.recipient, value); - }); - - it('emits Transfer event', async function () { - await expect(this.tx).to.emit(this.token, 'Transfer').withArgs(ethers.ZeroAddress, this.recipient, value); - }); - }); - }); - - describe('_burn', function () { - it('rejects a null account', async function () { - await expect(this.token.$_burn(ethers.ZeroAddress, 1n)) - .to.be.revertedWithCustomError(this.token, 'ERC20InvalidSender') - .withArgs(ethers.ZeroAddress); - }); - - describe('for a non zero account', function () { - it('rejects burning more than balance', async function () { - await expect(this.token.$_burn(this.holder, initialSupply + 1n)) - .to.be.revertedWithCustomError(this.token, 'ERC20InsufficientBalance') - .withArgs(this.holder, initialSupply, initialSupply + 1n); - }); - - const describeBurn = function (description, value) { - describe(description, function () { - beforeEach('burning', async function () { - this.tx = await this.token.$_burn(this.holder, value); - }); - - it('decrements totalSupply', async function () { - expect(await this.token.totalSupply()).to.equal(initialSupply - value); - }); - - it('decrements holder balance', async function () { - await expect(this.tx).to.changeTokenBalance(this.token, this.holder, -value); - }); - - it('emits Transfer event', async function () { - await expect(this.tx).to.emit(this.token, 'Transfer').withArgs(this.holder, ethers.ZeroAddress, value); - }); - }); - }; - - describeBurn('for entire balance', initialSupply); - describeBurn('for less value than balance', initialSupply - 1n); - }); - }); - - describe('_update', function () { - const value = 1n; - - beforeEach(async function () { - this.totalSupply = await this.token.totalSupply(); - }); - - it('from is the zero address', async function () { - const tx = await this.token.$_update(ethers.ZeroAddress, this.holder, value); - await expect(tx).to.emit(this.token, 'Transfer').withArgs(ethers.ZeroAddress, this.holder, value); - - expect(await this.token.totalSupply()).to.equal(this.totalSupply + value); - await expect(tx).to.changeTokenBalance(this.token, this.holder, value); - }); - - it('to is the zero address', async function () { - const tx = await this.token.$_update(this.holder, ethers.ZeroAddress, value); - await expect(tx).to.emit(this.token, 'Transfer').withArgs(this.holder, ethers.ZeroAddress, value); - - expect(await this.token.totalSupply()).to.equal(this.totalSupply - value); - await expect(tx).to.changeTokenBalance(this.token, this.holder, -value); - }); - - describe('from and to are the same address', function () { - it('zero address', async function () { - const tx = await this.token.$_update(ethers.ZeroAddress, ethers.ZeroAddress, value); - await expect(tx).to.emit(this.token, 'Transfer').withArgs(ethers.ZeroAddress, ethers.ZeroAddress, value); - - expect(await this.token.totalSupply()).to.equal(this.totalSupply); - await expect(tx).to.changeTokenBalance(this.token, ethers.ZeroAddress, 0n); - }); - - describe('non zero address', function () { - it('reverts without balance', async function () { - await expect(this.token.$_update(this.recipient, this.recipient, value)) - .to.be.revertedWithCustomError(this.token, 'ERC20InsufficientBalance') - .withArgs(this.recipient, 0n, value); - }); - - it('executes with balance', async function () { - const tx = await this.token.$_update(this.holder, this.holder, value); - await expect(tx).to.changeTokenBalance(this.token, this.holder, 0n); - await expect(tx).to.emit(this.token, 'Transfer').withArgs(this.holder, this.holder, value); - }); - }); - }); - }); - - describe('_transfer', function () { - beforeEach(function () { - this.transfer = this.token.$_transfer; - }); - - shouldBehaveLikeERC20Transfer(initialSupply); - - it('reverts when the sender is the zero address', async function () { - await expect(this.token.$_transfer(ethers.ZeroAddress, this.recipient, initialSupply)) - .to.be.revertedWithCustomError(this.token, 'ERC20InvalidSender') - .withArgs(ethers.ZeroAddress); - }); - }); - - describe('_approve', function () { - beforeEach(function () { - this.approve = this.token.$_approve; - }); - - shouldBehaveLikeERC20Approve(initialSupply); - - it('reverts when the owner is the zero address', async function () { - await expect(this.token.$_approve(ethers.ZeroAddress, this.recipient, initialSupply)) - .to.be.revertedWithCustomError(this.token, 'ERC20InvalidApprover') - .withArgs(ethers.ZeroAddress); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC1363.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC1363.test.js deleted file mode 100644 index 3d1f4e58f8..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC1363.test.js +++ /dev/null @@ -1,370 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { - shouldBehaveLikeERC20, - shouldBehaveLikeERC20Transfer, - shouldBehaveLikeERC20Approve, -} = require('../ERC20.behavior.js'); -const { shouldSupportInterfaces } = require('../../../utils/introspection/SupportsInterface.behavior'); -const { RevertType } = require('../../../helpers/enums.js'); - -const name = 'My Token'; -const symbol = 'MTKN'; -const value = 1000n; -const data = '0x123456'; - -async function fixture() { - // this.accounts is used by shouldBehaveLikeERC20 - const accounts = await ethers.getSigners(); - const [holder, other] = accounts; - - const receiver = await ethers.deployContract('ERC1363ReceiverMock'); - const spender = await ethers.deployContract('ERC1363SpenderMock'); - const token = await ethers.deployContract('$ERC1363', [name, symbol]); - - await token.$_mint(holder, value); - - return { - accounts, - holder, - other, - token, - receiver, - spender, - selectors: { - onTransferReceived: receiver.interface.getFunction('onTransferReceived(address,address,uint256,bytes)').selector, - onApprovalReceived: spender.interface.getFunction('onApprovalReceived(address,uint256,bytes)').selector, - }, - }; -} - -describe('ERC1363', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldSupportInterfaces(['ERC165', 'ERC1363']); - shouldBehaveLikeERC20(value); - - describe('transferAndCall', function () { - describe('as a transfer', function () { - beforeEach(async function () { - this.recipient = this.receiver; - this.transfer = (holder, ...rest) => - this.token.connect(holder).getFunction('transferAndCall(address,uint256)')(...rest); - }); - - shouldBehaveLikeERC20Transfer(value); - }); - - it('reverts transferring to an EOA', async function () { - await expect(this.token.connect(this.holder).getFunction('transferAndCall(address,uint256)')(this.other, value)) - .to.be.revertedWithCustomError(this.token, 'ERC1363InvalidReceiver') - .withArgs(this.other.address); - }); - - it('succeeds without data', async function () { - await expect( - this.token.connect(this.holder).getFunction('transferAndCall(address,uint256)')(this.receiver, value), - ) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder.address, this.receiver.target, value) - .to.emit(this.receiver, 'Received') - .withArgs(this.holder.address, this.holder.address, value, '0x'); - }); - - it('succeeds with data', async function () { - await expect( - this.token.connect(this.holder).getFunction('transferAndCall(address,uint256,bytes)')( - this.receiver, - value, - data, - ), - ) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder.address, this.receiver.target, value) - .to.emit(this.receiver, 'Received') - .withArgs(this.holder.address, this.holder.address, value, data); - }); - - it('reverts with reverting hook (without reason)', async function () { - await this.receiver.setUp(this.selectors.onTransferReceived, RevertType.RevertWithoutMessage); - - await expect( - this.token.connect(this.holder).getFunction('transferAndCall(address,uint256,bytes)')( - this.receiver, - value, - data, - ), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1363InvalidReceiver') - .withArgs(this.receiver.target); - }); - - it('reverts with reverting hook (with reason)', async function () { - await this.receiver.setUp(this.selectors.onTransferReceived, RevertType.RevertWithMessage); - - await expect( - this.token.connect(this.holder).getFunction('transferAndCall(address,uint256,bytes)')( - this.receiver, - value, - data, - ), - ).to.be.revertedWith('ERC1363ReceiverMock: reverting'); - }); - - it('reverts with reverting hook (with custom error)', async function () { - const reason = '0x12345678'; - await this.receiver.setUp(reason, RevertType.RevertWithCustomError); - - await expect( - this.token.connect(this.holder).getFunction('transferAndCall(address,uint256,bytes)')( - this.receiver, - value, - data, - ), - ) - .to.be.revertedWithCustomError(this.receiver, 'CustomError') - .withArgs(reason); - }); - - it('panics with reverting hook (with panic)', async function () { - await this.receiver.setUp(this.selectors.onTransferReceived, RevertType.Panic); - - await expect( - this.token.connect(this.holder).getFunction('transferAndCall(address,uint256,bytes)')( - this.receiver, - value, - data, - ), - ).to.be.revertedWithPanic(); - }); - - it('reverts with bad return value', async function () { - await this.receiver.setUp('0x12345678', RevertType.None); - - await expect( - this.token.connect(this.holder).getFunction('transferAndCall(address,uint256,bytes)')( - this.receiver, - value, - data, - ), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1363InvalidReceiver') - .withArgs(this.receiver.target); - }); - }); - - describe('transferFromAndCall', function () { - beforeEach(async function () { - await this.token.connect(this.holder).approve(this.other, ethers.MaxUint256); - }); - - describe('as a transfer', function () { - beforeEach(async function () { - this.recipient = this.receiver; - this.transfer = this.token.connect(this.other).getFunction('transferFromAndCall(address,address,uint256)'); - }); - - shouldBehaveLikeERC20Transfer(value); - }); - - it('reverts transferring to an EOA', async function () { - await expect( - this.token.connect(this.other).getFunction('transferFromAndCall(address,address,uint256)')( - this.holder, - this.other, - value, - ), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1363InvalidReceiver') - .withArgs(this.other.address); - }); - - it('succeeds without data', async function () { - await expect( - this.token.connect(this.other).getFunction('transferFromAndCall(address,address,uint256)')( - this.holder, - this.receiver, - value, - ), - ) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder.address, this.receiver.target, value) - .to.emit(this.receiver, 'Received') - .withArgs(this.other.address, this.holder.address, value, '0x'); - }); - - it('succeeds with data', async function () { - await expect( - this.token.connect(this.other).getFunction('transferFromAndCall(address,address,uint256,bytes)')( - this.holder, - this.receiver, - value, - data, - ), - ) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder.address, this.receiver.target, value) - .to.emit(this.receiver, 'Received') - .withArgs(this.other.address, this.holder.address, value, data); - }); - - it('reverts with reverting hook (without reason)', async function () { - await this.receiver.setUp(this.selectors.onTransferReceived, RevertType.RevertWithoutMessage); - - await expect( - this.token.connect(this.other).getFunction('transferFromAndCall(address,address,uint256,bytes)')( - this.holder, - this.receiver, - value, - data, - ), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1363InvalidReceiver') - .withArgs(this.receiver.target); - }); - - it('reverts with reverting hook (with reason)', async function () { - await this.receiver.setUp(this.selectors.onTransferReceived, RevertType.RevertWithMessage); - - await expect( - this.token.connect(this.other).getFunction('transferFromAndCall(address,address,uint256,bytes)')( - this.holder, - this.receiver, - value, - data, - ), - ).to.be.revertedWith('ERC1363ReceiverMock: reverting'); - }); - - it('reverts with reverting hook (with custom error)', async function () { - const reason = '0x12345678'; - await this.receiver.setUp(reason, RevertType.RevertWithCustomError); - - await expect( - this.token.connect(this.other).getFunction('transferFromAndCall(address,address,uint256,bytes)')( - this.holder, - this.receiver, - value, - data, - ), - ) - .to.be.revertedWithCustomError(this.receiver, 'CustomError') - .withArgs(reason); - }); - - it('panics with reverting hook (with panic)', async function () { - await this.receiver.setUp(this.selectors.onTransferReceived, RevertType.Panic); - - await expect( - this.token.connect(this.other).getFunction('transferFromAndCall(address,address,uint256,bytes)')( - this.holder, - this.receiver, - value, - data, - ), - ).to.be.revertedWithPanic(); - }); - - it('reverts with bad return value', async function () { - await this.receiver.setUp('0x12345678', RevertType.None); - - await expect( - this.token.connect(this.other).getFunction('transferFromAndCall(address,address,uint256,bytes)')( - this.holder, - this.receiver, - value, - data, - ), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1363InvalidReceiver') - .withArgs(this.receiver.target); - }); - }); - - describe('approveAndCall', function () { - describe('as an approval', function () { - beforeEach(async function () { - this.recipient = this.spender; - this.approve = (holder, ...rest) => - this.token.connect(holder).getFunction('approveAndCall(address,uint256)')(...rest); - }); - - shouldBehaveLikeERC20Approve(value); - }); - - it('reverts approving an EOA', async function () { - await expect(this.token.connect(this.holder).getFunction('approveAndCall(address,uint256)')(this.other, value)) - .to.be.revertedWithCustomError(this.token, 'ERC1363InvalidSpender') - .withArgs(this.other.address); - }); - - it('succeeds without data', async function () { - await expect(this.token.connect(this.holder).getFunction('approveAndCall(address,uint256)')(this.spender, value)) - .to.emit(this.token, 'Approval') - .withArgs(this.holder.address, this.spender.target, value) - .to.emit(this.spender, 'Approved') - .withArgs(this.holder.address, value, '0x'); - }); - - it('succeeds with data', async function () { - await expect( - this.token.connect(this.holder).getFunction('approveAndCall(address,uint256,bytes)')(this.spender, value, data), - ) - .to.emit(this.token, 'Approval') - .withArgs(this.holder.address, this.spender.target, value) - .to.emit(this.spender, 'Approved') - .withArgs(this.holder.address, value, data); - }); - - it('with reverting hook (without reason)', async function () { - await this.spender.setUp(this.selectors.onApprovalReceived, RevertType.RevertWithoutMessage); - - await expect( - this.token.connect(this.holder).getFunction('approveAndCall(address,uint256,bytes)')(this.spender, value, data), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1363InvalidSpender') - .withArgs(this.spender.target); - }); - - it('reverts with reverting hook (with reason)', async function () { - await this.spender.setUp(this.selectors.onApprovalReceived, RevertType.RevertWithMessage); - - await expect( - this.token.connect(this.holder).getFunction('approveAndCall(address,uint256,bytes)')(this.spender, value, data), - ).to.be.revertedWith('ERC1363SpenderMock: reverting'); - }); - - it('reverts with reverting hook (with custom error)', async function () { - const reason = '0x12345678'; - await this.spender.setUp(reason, RevertType.RevertWithCustomError); - - await expect( - this.token.connect(this.holder).getFunction('approveAndCall(address,uint256,bytes)')(this.spender, value, data), - ) - .to.be.revertedWithCustomError(this.spender, 'CustomError') - .withArgs(reason); - }); - - it('panics with reverting hook (with panic)', async function () { - await this.spender.setUp(this.selectors.onApprovalReceived, RevertType.Panic); - - await expect( - this.token.connect(this.holder).getFunction('approveAndCall(address,uint256,bytes)')(this.spender, value, data), - ).to.be.revertedWithPanic(); - }); - - it('reverts with bad return value', async function () { - await this.spender.setUp('0x12345678', RevertType.None); - - await expect( - this.token.connect(this.holder).getFunction('approveAndCall(address,uint256,bytes)')(this.spender, value, data), - ) - .to.be.revertedWithCustomError(this.token, 'ERC1363InvalidSpender') - .withArgs(this.spender.target); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Burnable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Burnable.test.js deleted file mode 100644 index dc40c79177..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Burnable.test.js +++ /dev/null @@ -1,105 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const name = 'My Token'; -const symbol = 'MTKN'; -const initialBalance = 1000n; - -async function fixture() { - const [owner, burner] = await ethers.getSigners(); - - const token = await ethers.deployContract('$ERC20Burnable', [name, symbol], owner); - await token.$_mint(owner, initialBalance); - - return { owner, burner, token, initialBalance }; -} - -describe('ERC20Burnable', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('burn', function () { - it('reverts if not enough balance', async function () { - const value = this.initialBalance + 1n; - - await expect(this.token.connect(this.owner).burn(value)) - .to.be.revertedWithCustomError(this.token, 'ERC20InsufficientBalance') - .withArgs(this.owner, this.initialBalance, value); - }); - - describe('on success', function () { - for (const { title, value } of [ - { title: 'for a zero value', value: 0n }, - { title: 'for a non-zero value', value: 100n }, - ]) { - describe(title, function () { - beforeEach(async function () { - this.tx = await this.token.connect(this.owner).burn(value); - }); - - it('burns the requested value', async function () { - await expect(this.tx).to.changeTokenBalance(this.token, this.owner, -value); - }); - - it('emits a transfer event', async function () { - await expect(this.tx).to.emit(this.token, 'Transfer').withArgs(this.owner, ethers.ZeroAddress, value); - }); - }); - } - }); - }); - - describe('burnFrom', function () { - describe('reverts', function () { - it('if not enough balance', async function () { - const value = this.initialBalance + 1n; - - await this.token.connect(this.owner).approve(this.burner, value); - - await expect(this.token.connect(this.burner).burnFrom(this.owner, value)) - .to.be.revertedWithCustomError(this.token, 'ERC20InsufficientBalance') - .withArgs(this.owner, this.initialBalance, value); - }); - - it('if not enough allowance', async function () { - const allowance = 100n; - - await this.token.connect(this.owner).approve(this.burner, allowance); - - await expect(this.token.connect(this.burner).burnFrom(this.owner, allowance + 1n)) - .to.be.revertedWithCustomError(this.token, 'ERC20InsufficientAllowance') - .withArgs(this.burner, allowance, allowance + 1n); - }); - }); - - describe('on success', function () { - for (const { title, value } of [ - { title: 'for a zero value', value: 0n }, - { title: 'for a non-zero value', value: 100n }, - ]) { - describe(title, function () { - const originalAllowance = value * 3n; - - beforeEach(async function () { - await this.token.connect(this.owner).approve(this.burner, originalAllowance); - this.tx = await this.token.connect(this.burner).burnFrom(this.owner, value); - }); - - it('burns the requested value', async function () { - await expect(this.tx).to.changeTokenBalance(this.token, this.owner, -value); - }); - - it('decrements allowance', async function () { - expect(await this.token.allowance(this.owner, this.burner)).to.equal(originalAllowance - value); - }); - - it('emits a transfer event', async function () { - await expect(this.tx).to.emit(this.token, 'Transfer').withArgs(this.owner, ethers.ZeroAddress, value); - }); - }); - } - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Capped.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Capped.test.js deleted file mode 100644 index a32ec43a8e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Capped.test.js +++ /dev/null @@ -1,55 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const name = 'My Token'; -const symbol = 'MTKN'; -const cap = 1000n; - -async function fixture() { - const [user] = await ethers.getSigners(); - - const token = await ethers.deployContract('$ERC20Capped', [name, symbol, cap]); - - return { user, token, cap }; -} - -describe('ERC20Capped', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('requires a non-zero cap', async function () { - const ERC20Capped = await ethers.getContractFactory('$ERC20Capped'); - - await expect(ERC20Capped.deploy(name, symbol, 0)) - .to.be.revertedWithCustomError(ERC20Capped, 'ERC20InvalidCap') - .withArgs(0); - }); - - describe('capped token', function () { - it('starts with the correct cap', async function () { - expect(await this.token.cap()).to.equal(this.cap); - }); - - it('mints when value is less than cap', async function () { - const value = this.cap - 1n; - await this.token.$_mint(this.user, value); - expect(await this.token.totalSupply()).to.equal(value); - }); - - it('fails to mint if the value exceeds the cap', async function () { - await this.token.$_mint(this.user, this.cap - 1n); - await expect(this.token.$_mint(this.user, 2)) - .to.be.revertedWithCustomError(this.token, 'ERC20ExceededCap') - .withArgs(this.cap + 1n, this.cap); - }); - - it('fails to mint after cap is reached', async function () { - await this.token.$_mint(this.user, this.cap); - await expect(this.token.$_mint(this.user, 1)) - .to.be.revertedWithCustomError(this.token, 'ERC20ExceededCap') - .withArgs(this.cap + 1n, this.cap); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20FlashMint.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20FlashMint.test.js deleted file mode 100644 index 1c751f74ce..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20FlashMint.test.js +++ /dev/null @@ -1,164 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const name = 'My Token'; -const symbol = 'MTKN'; -const initialSupply = 100n; -const loanValue = 10_000_000_000_000n; - -async function fixture() { - const [holder, other] = await ethers.getSigners(); - - const token = await ethers.deployContract('$ERC20FlashMintMock', [name, symbol]); - await token.$_mint(holder, initialSupply); - - return { holder, other, token }; -} - -describe('ERC20FlashMint', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('maxFlashLoan', function () { - it('token match', async function () { - expect(await this.token.maxFlashLoan(this.token)).to.equal(ethers.MaxUint256 - initialSupply); - }); - - it('token mismatch', async function () { - expect(await this.token.maxFlashLoan(ethers.ZeroAddress)).to.equal(0n); - }); - }); - - describe('flashFee', function () { - it('token match', async function () { - expect(await this.token.flashFee(this.token, loanValue)).to.equal(0n); - }); - - it('token mismatch', async function () { - await expect(this.token.flashFee(ethers.ZeroAddress, loanValue)) - .to.be.revertedWithCustomError(this.token, 'ERC3156UnsupportedToken') - .withArgs(ethers.ZeroAddress); - }); - }); - - describe('flashFeeReceiver', function () { - it('default receiver', async function () { - expect(await this.token.$_flashFeeReceiver()).to.equal(ethers.ZeroAddress); - }); - }); - - describe('flashLoan', function () { - it('success', async function () { - const receiver = await ethers.deployContract('ERC3156FlashBorrowerMock', [true, true]); - - const tx = await this.token.flashLoan(receiver, this.token, loanValue, '0x'); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, receiver, loanValue) - .to.emit(this.token, 'Transfer') - .withArgs(receiver, ethers.ZeroAddress, loanValue) - .to.emit(receiver, 'BalanceOf') - .withArgs(this.token, receiver, loanValue) - .to.emit(receiver, 'TotalSupply') - .withArgs(this.token, initialSupply + loanValue); - await expect(tx).to.changeTokenBalance(this.token, receiver, 0); - - expect(await this.token.totalSupply()).to.equal(initialSupply); - expect(await this.token.allowance(receiver, this.token)).to.equal(0n); - }); - - it('missing return value', async function () { - const receiver = await ethers.deployContract('ERC3156FlashBorrowerMock', [false, true]); - await expect(this.token.flashLoan(receiver, this.token, loanValue, '0x')) - .to.be.revertedWithCustomError(this.token, 'ERC3156InvalidReceiver') - .withArgs(receiver); - }); - - it('missing approval', async function () { - const receiver = await ethers.deployContract('ERC3156FlashBorrowerMock', [true, false]); - await expect(this.token.flashLoan(receiver, this.token, loanValue, '0x')) - .to.be.revertedWithCustomError(this.token, 'ERC20InsufficientAllowance') - .withArgs(this.token, 0, loanValue); - }); - - it('unavailable funds', async function () { - const receiver = await ethers.deployContract('ERC3156FlashBorrowerMock', [true, true]); - const data = this.token.interface.encodeFunctionData('transfer', [this.other.address, 10]); - await expect(this.token.flashLoan(receiver, this.token, loanValue, data)) - .to.be.revertedWithCustomError(this.token, 'ERC20InsufficientBalance') - .withArgs(receiver, loanValue - 10n, loanValue); - }); - - it('more than maxFlashLoan', async function () { - const receiver = await ethers.deployContract('ERC3156FlashBorrowerMock', [true, true]); - const data = this.token.interface.encodeFunctionData('transfer', [this.other.address, 10]); - await expect(this.token.flashLoan(receiver, this.token, ethers.MaxUint256, data)) - .to.be.revertedWithCustomError(this.token, 'ERC3156ExceededMaxLoan') - .withArgs(ethers.MaxUint256 - initialSupply); - }); - - describe('custom flash fee & custom fee receiver', function () { - const receiverInitialBalance = 200_000n; - const flashFee = 5_000n; - - beforeEach('init receiver balance & set flash fee', async function () { - this.receiver = await ethers.deployContract('ERC3156FlashBorrowerMock', [true, true]); - - const tx = await this.token.$_mint(this.receiver, receiverInitialBalance); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.receiver, receiverInitialBalance); - await expect(tx).to.changeTokenBalance(this.token, this.receiver, receiverInitialBalance); - - await this.token.setFlashFee(flashFee); - expect(await this.token.flashFee(this.token, loanValue)).to.equal(flashFee); - }); - - it('default flash fee receiver', async function () { - const tx = await this.token.flashLoan(this.receiver, this.token, loanValue, '0x'); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.receiver, loanValue) - .to.emit(this.token, 'Transfer') - .withArgs(this.receiver, ethers.ZeroAddress, loanValue + flashFee) - .to.emit(this.receiver, 'BalanceOf') - .withArgs(this.token, this.receiver, receiverInitialBalance + loanValue) - .to.emit(this.receiver, 'TotalSupply') - .withArgs(this.token, initialSupply + receiverInitialBalance + loanValue); - await expect(tx).to.changeTokenBalances(this.token, [this.receiver, ethers.ZeroAddress], [-flashFee, 0]); - - expect(await this.token.totalSupply()).to.equal(initialSupply + receiverInitialBalance - flashFee); - expect(await this.token.allowance(this.receiver, this.token)).to.equal(0n); - }); - - it('custom flash fee receiver', async function () { - const flashFeeReceiverAddress = this.other; - await this.token.setFlashFeeReceiver(flashFeeReceiverAddress); - expect(await this.token.$_flashFeeReceiver()).to.equal(flashFeeReceiverAddress); - - const tx = await this.token.flashLoan(this.receiver, this.token, loanValue, '0x'); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.receiver, loanValue) - .to.emit(this.token, 'Transfer') - .withArgs(this.receiver, ethers.ZeroAddress, loanValue) - .to.emit(this.token, 'Transfer') - .withArgs(this.receiver, flashFeeReceiverAddress, flashFee) - .to.emit(this.receiver, 'BalanceOf') - .withArgs(this.token, this.receiver, receiverInitialBalance + loanValue) - .to.emit(this.receiver, 'TotalSupply') - .withArgs(this.token, initialSupply + receiverInitialBalance + loanValue); - await expect(tx).to.changeTokenBalances( - this.token, - [this.receiver, flashFeeReceiverAddress], - [-flashFee, flashFee], - ); - - expect(await this.token.totalSupply()).to.equal(initialSupply + receiverInitialBalance); - expect(await this.token.allowance(this.receiver, flashFeeReceiverAddress)).to.equal(0n); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Pausable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Pausable.test.js deleted file mode 100644 index 1f1157c19e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Pausable.test.js +++ /dev/null @@ -1,129 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const name = 'My Token'; -const symbol = 'MTKN'; -const initialSupply = 100n; - -async function fixture() { - const [holder, recipient, approved] = await ethers.getSigners(); - - const token = await ethers.deployContract('$ERC20Pausable', [name, symbol]); - await token.$_mint(holder, initialSupply); - - return { holder, recipient, approved, token }; -} - -describe('ERC20Pausable', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('pausable token', function () { - describe('transfer', function () { - it('allows to transfer when unpaused', async function () { - await expect(this.token.connect(this.holder).transfer(this.recipient, initialSupply)).to.changeTokenBalances( - this.token, - [this.holder, this.recipient], - [-initialSupply, initialSupply], - ); - }); - - it('allows to transfer when paused and then unpaused', async function () { - await this.token.$_pause(); - await this.token.$_unpause(); - - await expect(this.token.connect(this.holder).transfer(this.recipient, initialSupply)).to.changeTokenBalances( - this.token, - [this.holder, this.recipient], - [-initialSupply, initialSupply], - ); - }); - - it('reverts when trying to transfer when paused', async function () { - await this.token.$_pause(); - - await expect( - this.token.connect(this.holder).transfer(this.recipient, initialSupply), - ).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - }); - - describe('transfer from', function () { - const allowance = 40n; - - beforeEach(async function () { - await this.token.connect(this.holder).approve(this.approved, allowance); - }); - - it('allows to transfer from when unpaused', async function () { - await expect( - this.token.connect(this.approved).transferFrom(this.holder, this.recipient, allowance), - ).to.changeTokenBalances(this.token, [this.holder, this.recipient], [-allowance, allowance]); - }); - - it('allows to transfer when paused and then unpaused', async function () { - await this.token.$_pause(); - await this.token.$_unpause(); - - await expect( - this.token.connect(this.approved).transferFrom(this.holder, this.recipient, allowance), - ).to.changeTokenBalances(this.token, [this.holder, this.recipient], [-allowance, allowance]); - }); - - it('reverts when trying to transfer from when paused', async function () { - await this.token.$_pause(); - - await expect( - this.token.connect(this.approved).transferFrom(this.holder, this.recipient, allowance), - ).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - }); - - describe('mint', function () { - const value = 42n; - - it('allows to mint when unpaused', async function () { - await expect(this.token.$_mint(this.recipient, value)).to.changeTokenBalance(this.token, this.recipient, value); - }); - - it('allows to mint when paused and then unpaused', async function () { - await this.token.$_pause(); - await this.token.$_unpause(); - - await expect(this.token.$_mint(this.recipient, value)).to.changeTokenBalance(this.token, this.recipient, value); - }); - - it('reverts when trying to mint when paused', async function () { - await this.token.$_pause(); - - await expect(this.token.$_mint(this.recipient, value)).to.be.revertedWithCustomError( - this.token, - 'EnforcedPause', - ); - }); - }); - - describe('burn', function () { - const value = 42n; - - it('allows to burn when unpaused', async function () { - await expect(this.token.$_burn(this.holder, value)).to.changeTokenBalance(this.token, this.holder, -value); - }); - - it('allows to burn when paused and then unpaused', async function () { - await this.token.$_pause(); - await this.token.$_unpause(); - - await expect(this.token.$_burn(this.holder, value)).to.changeTokenBalance(this.token, this.holder, -value); - }); - - it('reverts when trying to burn when paused', async function () { - await this.token.$_pause(); - - await expect(this.token.$_burn(this.holder, value)).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Permit.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Permit.test.js deleted file mode 100644 index c3c80d7bbe..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Permit.test.js +++ /dev/null @@ -1,109 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { getDomain, domainSeparator, Permit } = require('../../../helpers/eip712'); -const time = require('../../../helpers/time'); - -const name = 'My Token'; -const symbol = 'MTKN'; -const initialSupply = 100n; - -async function fixture() { - const [holder, spender, owner, other] = await ethers.getSigners(); - - const token = await ethers.deployContract('$ERC20Permit', [name, symbol, name]); - await token.$_mint(holder, initialSupply); - - return { - holder, - spender, - owner, - other, - token, - }; -} - -describe('ERC20Permit', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('initial nonce is 0', async function () { - expect(await this.token.nonces(this.holder)).to.equal(0n); - }); - - it('domain separator', async function () { - expect(await this.token.DOMAIN_SEPARATOR()).to.equal(await getDomain(this.token).then(domainSeparator)); - }); - - describe('permit', function () { - const value = 42n; - const nonce = 0n; - const maxDeadline = ethers.MaxUint256; - - beforeEach(function () { - this.buildData = (contract, deadline = maxDeadline) => - getDomain(contract).then(domain => ({ - domain, - types: { Permit }, - message: { - owner: this.owner.address, - spender: this.spender.address, - value, - nonce, - deadline, - }, - })); - }); - - it('accepts owner signature', async function () { - const { v, r, s } = await this.buildData(this.token) - .then(({ domain, types, message }) => this.owner.signTypedData(domain, types, message)) - .then(ethers.Signature.from); - - await this.token.permit(this.owner, this.spender, value, maxDeadline, v, r, s); - - expect(await this.token.nonces(this.owner)).to.equal(1n); - expect(await this.token.allowance(this.owner, this.spender)).to.equal(value); - }); - - it('rejects reused signature', async function () { - const { v, r, s, serialized } = await this.buildData(this.token) - .then(({ domain, types, message }) => this.owner.signTypedData(domain, types, message)) - .then(ethers.Signature.from); - - await this.token.permit(this.owner, this.spender, value, maxDeadline, v, r, s); - - const recovered = await this.buildData(this.token).then(({ domain, types, message }) => - ethers.verifyTypedData(domain, types, { ...message, nonce: nonce + 1n, deadline: maxDeadline }, serialized), - ); - - await expect(this.token.permit(this.owner, this.spender, value, maxDeadline, v, r, s)) - .to.be.revertedWithCustomError(this.token, 'ERC2612InvalidSigner') - .withArgs(recovered, this.owner); - }); - - it('rejects other signature', async function () { - const { v, r, s } = await this.buildData(this.token) - .then(({ domain, types, message }) => this.other.signTypedData(domain, types, message)) - .then(ethers.Signature.from); - - await expect(this.token.permit(this.owner, this.spender, value, maxDeadline, v, r, s)) - .to.be.revertedWithCustomError(this.token, 'ERC2612InvalidSigner') - .withArgs(this.other, this.owner); - }); - - it('rejects expired permit', async function () { - const deadline = (await time.clock.timestamp()) - time.duration.weeks(1); - - const { v, r, s } = await this.buildData(this.token, deadline) - .then(({ domain, types, message }) => this.owner.signTypedData(domain, types, message)) - .then(ethers.Signature.from); - - await expect(this.token.permit(this.owner, this.spender, value, deadline, v, r, s)) - .to.be.revertedWithCustomError(this.token, 'ERC2612ExpiredSignature') - .withArgs(deadline); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Votes.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Votes.test.js deleted file mode 100644 index 3c595c9191..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Votes.test.js +++ /dev/null @@ -1,546 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture, mine } = require('@nomicfoundation/hardhat-network-helpers'); - -const { getDomain, Delegation } = require('../../../helpers/eip712'); -const { batchInBlock } = require('../../../helpers/txpool'); -const time = require('../../../helpers/time'); - -const { shouldBehaveLikeVotes } = require('../../../governance/utils/Votes.behavior'); - -const TOKENS = [ - { Token: '$ERC20Votes', mode: 'blocknumber' }, - { Token: '$ERC20VotesTimestampMock', mode: 'timestamp' }, -]; - -const name = 'My Token'; -const symbol = 'MTKN'; -const version = '1'; -const supply = ethers.parseEther('10000000'); - -describe('ERC20Votes', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - // accounts is required by shouldBehaveLikeVotes - const accounts = await ethers.getSigners(); - const [holder, recipient, delegatee, other1, other2] = accounts; - - const token = await ethers.deployContract(Token, [name, symbol, name, version]); - const domain = await getDomain(token); - - return { accounts, holder, recipient, delegatee, other1, other2, token, domain }; - }; - - describe(`vote with ${mode}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - this.votes = this.token; - }); - - // includes ERC6372 behavior check - shouldBehaveLikeVotes([1, 17, 42], { mode, fungible: true }); - - it('initial nonce is 0', async function () { - expect(await this.token.nonces(this.holder)).to.equal(0n); - }); - - it('minting restriction', async function () { - const value = 2n ** 208n; - await expect(this.token.$_mint(this.holder, value)) - .to.be.revertedWithCustomError(this.token, 'ERC20ExceededSafeSupply') - .withArgs(value, value - 1n); - }); - - it('recent checkpoints', async function () { - await this.token.connect(this.holder).delegate(this.holder); - for (let i = 0; i < 6; i++) { - await this.token.$_mint(this.holder, 1n); - } - const timepoint = await time.clock[mode](); - expect(await this.token.numCheckpoints(this.holder)).to.equal(6n); - // recent - expect(await this.token.getPastVotes(this.holder, timepoint - 1n)).to.equal(5n); - // non-recent - expect(await this.token.getPastVotes(this.holder, timepoint - 6n)).to.equal(0n); - }); - - describe('set delegation', function () { - describe('call', function () { - it('delegation with balance', async function () { - await this.token.$_mint(this.holder, supply); - expect(await this.token.delegates(this.holder)).to.equal(ethers.ZeroAddress); - - const tx = await this.token.connect(this.holder).delegate(this.holder); - const timepoint = await time.clockFromReceipt[mode](tx); - - await expect(tx) - .to.emit(this.token, 'DelegateChanged') - .withArgs(this.holder, ethers.ZeroAddress, this.holder) - .to.emit(this.token, 'DelegateVotesChanged') - .withArgs(this.holder, 0n, supply); - - expect(await this.token.delegates(this.holder)).to.equal(this.holder); - expect(await this.token.getVotes(this.holder)).to.equal(supply); - expect(await this.token.getPastVotes(this.holder, timepoint - 1n)).to.equal(0n); - await mine(); - expect(await this.token.getPastVotes(this.holder, timepoint)).to.equal(supply); - }); - - it('delegation without balance', async function () { - expect(await this.token.delegates(this.holder)).to.equal(ethers.ZeroAddress); - - await expect(this.token.connect(this.holder).delegate(this.holder)) - .to.emit(this.token, 'DelegateChanged') - .withArgs(this.holder, ethers.ZeroAddress, this.holder) - .to.not.emit(this.token, 'DelegateVotesChanged'); - - expect(await this.token.delegates(this.holder)).to.equal(this.holder); - }); - }); - - describe('with signature', function () { - const nonce = 0n; - - beforeEach(async function () { - await this.token.$_mint(this.holder, supply); - }); - - it('accept signed delegation', async function () { - const { r, s, v } = await this.holder - .signTypedData( - this.domain, - { Delegation }, - { - delegatee: this.holder.address, - nonce, - expiry: ethers.MaxUint256, - }, - ) - .then(ethers.Signature.from); - - expect(await this.token.delegates(this.holder)).to.equal(ethers.ZeroAddress); - - const tx = await this.token.delegateBySig(this.holder, nonce, ethers.MaxUint256, v, r, s); - const timepoint = await time.clockFromReceipt[mode](tx); - - await expect(tx) - .to.emit(this.token, 'DelegateChanged') - .withArgs(this.holder, ethers.ZeroAddress, this.holder) - .to.emit(this.token, 'DelegateVotesChanged') - .withArgs(this.holder, 0n, supply); - - expect(await this.token.delegates(this.holder)).to.equal(this.holder); - - expect(await this.token.getVotes(this.holder)).to.equal(supply); - expect(await this.token.getPastVotes(this.holder, timepoint - 1n)).to.equal(0n); - await mine(); - expect(await this.token.getPastVotes(this.holder, timepoint)).to.equal(supply); - }); - - it('rejects reused signature', async function () { - const { r, s, v } = await this.holder - .signTypedData( - this.domain, - { Delegation }, - { - delegatee: this.holder.address, - nonce, - expiry: ethers.MaxUint256, - }, - ) - .then(ethers.Signature.from); - - await this.token.delegateBySig(this.holder, nonce, ethers.MaxUint256, v, r, s); - - await expect(this.token.delegateBySig(this.holder, nonce, ethers.MaxUint256, v, r, s)) - .to.be.revertedWithCustomError(this.token, 'InvalidAccountNonce') - .withArgs(this.holder, nonce + 1n); - }); - - it('rejects bad delegatee', async function () { - const { r, s, v } = await this.holder - .signTypedData( - this.domain, - { Delegation }, - { - delegatee: this.holder.address, - nonce, - expiry: ethers.MaxUint256, - }, - ) - .then(ethers.Signature.from); - - const tx = await this.token.delegateBySig(this.delegatee, nonce, ethers.MaxUint256, v, r, s); - - const { args } = await tx - .wait() - .then(receipt => receipt.logs.find(event => event.fragment.name == 'DelegateChanged')); - expect(args[0]).to.not.equal(this.holder); - expect(args[1]).to.equal(ethers.ZeroAddress); - expect(args[2]).to.equal(this.delegatee); - }); - - it('rejects bad nonce', async function () { - const { r, s, v, serialized } = await this.holder - .signTypedData( - this.domain, - { Delegation }, - { - delegatee: this.holder.address, - nonce, - expiry: ethers.MaxUint256, - }, - ) - .then(ethers.Signature.from); - - const recovered = ethers.verifyTypedData( - this.domain, - { Delegation }, - { - delegatee: this.holder.address, - nonce: nonce + 1n, - expiry: ethers.MaxUint256, - }, - serialized, - ); - - await expect(this.token.delegateBySig(this.holder, nonce + 1n, ethers.MaxUint256, v, r, s)) - .to.be.revertedWithCustomError(this.token, 'InvalidAccountNonce') - .withArgs(recovered, nonce); - }); - - it('rejects expired permit', async function () { - const expiry = (await time.clock.timestamp()) - time.duration.weeks(1); - - const { r, s, v } = await this.holder - .signTypedData( - this.domain, - { Delegation }, - { - delegatee: this.holder.address, - nonce, - expiry, - }, - ) - .then(ethers.Signature.from); - - await expect(this.token.delegateBySig(this.holder, nonce, expiry, v, r, s)) - .to.be.revertedWithCustomError(this.token, 'VotesExpiredSignature') - .withArgs(expiry); - }); - }); - }); - - describe('change delegation', function () { - beforeEach(async function () { - await this.token.$_mint(this.holder, supply); - await this.token.connect(this.holder).delegate(this.holder); - }); - - it('call', async function () { - expect(await this.token.delegates(this.holder)).to.equal(this.holder); - - const tx = await this.token.connect(this.holder).delegate(this.delegatee); - const timepoint = await time.clockFromReceipt[mode](tx); - - await expect(tx) - .to.emit(this.token, 'DelegateChanged') - .withArgs(this.holder, this.holder, this.delegatee) - .to.emit(this.token, 'DelegateVotesChanged') - .withArgs(this.holder, supply, 0n) - .to.emit(this.token, 'DelegateVotesChanged') - .withArgs(this.delegatee, 0n, supply); - - expect(await this.token.delegates(this.holder)).to.equal(this.delegatee); - - expect(await this.token.getVotes(this.holder)).to.equal(0n); - expect(await this.token.getVotes(this.delegatee)).to.equal(supply); - expect(await this.token.getPastVotes(this.holder, timepoint - 1n)).to.equal(supply); - expect(await this.token.getPastVotes(this.delegatee, timepoint - 1n)).to.equal(0n); - await mine(); - expect(await this.token.getPastVotes(this.holder, timepoint)).to.equal(0n); - expect(await this.token.getPastVotes(this.delegatee, timepoint)).to.equal(supply); - }); - }); - - describe('transfers', function () { - beforeEach(async function () { - await this.token.$_mint(this.holder, supply); - }); - - it('no delegation', async function () { - await expect(this.token.connect(this.holder).transfer(this.recipient, 1n)) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.recipient, 1n) - .to.not.emit(this.token, 'DelegateVotesChanged'); - - this.holderVotes = 0n; - this.recipientVotes = 0n; - }); - - it('sender delegation', async function () { - await this.token.connect(this.holder).delegate(this.holder); - - const tx = await this.token.connect(this.holder).transfer(this.recipient, 1n); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.recipient, 1n) - .to.emit(this.token, 'DelegateVotesChanged') - .withArgs(this.holder, supply, supply - 1n); - - const { logs } = await tx.wait(); - const { index } = logs.find(event => event.fragment.name == 'DelegateVotesChanged'); - for (const event of logs.filter(event => event.fragment.name == 'Transfer')) { - expect(event.index).to.lt(index); - } - - this.holderVotes = supply - 1n; - this.recipientVotes = 0n; - }); - - it('receiver delegation', async function () { - await this.token.connect(this.recipient).delegate(this.recipient); - - const tx = await this.token.connect(this.holder).transfer(this.recipient, 1n); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.recipient, 1n) - .to.emit(this.token, 'DelegateVotesChanged') - .withArgs(this.recipient, 0n, 1n); - - const { logs } = await tx.wait(); - const { index } = logs.find(event => event.fragment.name == 'DelegateVotesChanged'); - for (const event of logs.filter(event => event.fragment.name == 'Transfer')) { - expect(event.index).to.lt(index); - } - - this.holderVotes = 0n; - this.recipientVotes = 1n; - }); - - it('full delegation', async function () { - await this.token.connect(this.holder).delegate(this.holder); - await this.token.connect(this.recipient).delegate(this.recipient); - - const tx = await this.token.connect(this.holder).transfer(this.recipient, 1n); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.recipient, 1n) - .to.emit(this.token, 'DelegateVotesChanged') - .withArgs(this.holder, supply, supply - 1n) - .to.emit(this.token, 'DelegateVotesChanged') - .withArgs(this.recipient, 0n, 1n); - - const { logs } = await tx.wait(); - const { index } = logs.find(event => event.fragment.name == 'DelegateVotesChanged'); - for (const event of logs.filter(event => event.fragment.name == 'Transfer')) { - expect(event.index).to.lt(index); - } - - this.holderVotes = supply - 1n; - this.recipientVotes = 1n; - }); - - afterEach(async function () { - expect(await this.token.getVotes(this.holder)).to.equal(this.holderVotes); - expect(await this.token.getVotes(this.recipient)).to.equal(this.recipientVotes); - - // need to advance 2 blocks to see the effect of a transfer on "getPastVotes" - const timepoint = await time.clock[mode](); - await mine(); - expect(await this.token.getPastVotes(this.holder, timepoint)).to.equal(this.holderVotes); - expect(await this.token.getPastVotes(this.recipient, timepoint)).to.equal(this.recipientVotes); - }); - }); - - // The following tests are a adaptation of https://github.com/compound-finance/compound-protocol/blob/master/tests/Governance/CompTest.js. - describe('Compound test suite', function () { - beforeEach(async function () { - await this.token.$_mint(this.holder, supply); - }); - - describe('balanceOf', function () { - it('grants to initial account', async function () { - expect(await this.token.balanceOf(this.holder)).to.equal(supply); - }); - }); - - describe('numCheckpoints', function () { - it('returns the number of checkpoints for a delegate', async function () { - await this.token.connect(this.holder).transfer(this.recipient, 100n); //give an account a few tokens for readability - expect(await this.token.numCheckpoints(this.other1)).to.equal(0n); - - const t1 = await this.token.connect(this.recipient).delegate(this.other1); - t1.timepoint = await time.clockFromReceipt[mode](t1); - expect(await this.token.numCheckpoints(this.other1)).to.equal(1n); - - const t2 = await this.token.connect(this.recipient).transfer(this.other2, 10); - t2.timepoint = await time.clockFromReceipt[mode](t2); - expect(await this.token.numCheckpoints(this.other1)).to.equal(2n); - - const t3 = await this.token.connect(this.recipient).transfer(this.other2, 10); - t3.timepoint = await time.clockFromReceipt[mode](t3); - expect(await this.token.numCheckpoints(this.other1)).to.equal(3n); - - const t4 = await this.token.connect(this.holder).transfer(this.recipient, 20); - t4.timepoint = await time.clockFromReceipt[mode](t4); - expect(await this.token.numCheckpoints(this.other1)).to.equal(4n); - - expect(await this.token.checkpoints(this.other1, 0n)).to.deep.equal([t1.timepoint, 100n]); - expect(await this.token.checkpoints(this.other1, 1n)).to.deep.equal([t2.timepoint, 90n]); - expect(await this.token.checkpoints(this.other1, 2n)).to.deep.equal([t3.timepoint, 80n]); - expect(await this.token.checkpoints(this.other1, 3n)).to.deep.equal([t4.timepoint, 100n]); - await mine(); - expect(await this.token.getPastVotes(this.other1, t1.timepoint)).to.equal(100n); - expect(await this.token.getPastVotes(this.other1, t2.timepoint)).to.equal(90n); - expect(await this.token.getPastVotes(this.other1, t3.timepoint)).to.equal(80n); - expect(await this.token.getPastVotes(this.other1, t4.timepoint)).to.equal(100n); - }); - - it('does not add more than one checkpoint in a block', async function () { - await this.token.connect(this.holder).transfer(this.recipient, 100n); - expect(await this.token.numCheckpoints(this.other1)).to.equal(0n); - - const [t1, t2, t3] = await batchInBlock([ - () => this.token.connect(this.recipient).delegate(this.other1, { gasLimit: 200000 }), - () => this.token.connect(this.recipient).transfer(this.other2, 10n, { gasLimit: 200000 }), - () => this.token.connect(this.recipient).transfer(this.other2, 10n, { gasLimit: 200000 }), - ]); - t1.timepoint = await time.clockFromReceipt[mode](t1); - t2.timepoint = await time.clockFromReceipt[mode](t2); - t3.timepoint = await time.clockFromReceipt[mode](t3); - - expect(await this.token.numCheckpoints(this.other1)).to.equal(1); - expect(await this.token.checkpoints(this.other1, 0n)).to.be.deep.equal([t1.timepoint, 80n]); - - const t4 = await this.token.connect(this.holder).transfer(this.recipient, 20n); - t4.timepoint = await time.clockFromReceipt[mode](t4); - - expect(await this.token.numCheckpoints(this.other1)).to.equal(2n); - expect(await this.token.checkpoints(this.other1, 1n)).to.be.deep.equal([t4.timepoint, 100n]); - }); - }); - - describe('getPastVotes', function () { - it('reverts if block number >= current block', async function () { - const clock = await this.token.clock(); - await expect(this.token.getPastVotes(this.other1, 50_000_000_000n)) - .to.be.revertedWithCustomError(this.token, 'ERC5805FutureLookup') - .withArgs(50_000_000_000n, clock); - }); - - it('returns 0 if there are no checkpoints', async function () { - expect(await this.token.getPastVotes(this.other1, 0n)).to.equal(0n); - }); - - it('returns the latest block if >= last checkpoint block', async function () { - const tx = await this.token.connect(this.holder).delegate(this.other1); - const timepoint = await time.clockFromReceipt[mode](tx); - await mine(2); - - expect(await this.token.getPastVotes(this.other1, timepoint)).to.equal(supply); - expect(await this.token.getPastVotes(this.other1, timepoint + 1n)).to.equal(supply); - }); - - it('returns zero if < first checkpoint block', async function () { - await mine(); - const tx = await this.token.connect(this.holder).delegate(this.other1); - const timepoint = await time.clockFromReceipt[mode](tx); - await mine(2); - - expect(await this.token.getPastVotes(this.other1, timepoint - 1n)).to.equal(0n); - expect(await this.token.getPastVotes(this.other1, timepoint + 1n)).to.equal(supply); - }); - - it('generally returns the voting balance at the appropriate checkpoint', async function () { - const t1 = await this.token.connect(this.holder).delegate(this.other1); - await mine(2); - const t2 = await this.token.connect(this.holder).transfer(this.other2, 10); - await mine(2); - const t3 = await this.token.connect(this.holder).transfer(this.other2, 10); - await mine(2); - const t4 = await this.token.connect(this.other2).transfer(this.holder, 20); - await mine(2); - - t1.timepoint = await time.clockFromReceipt[mode](t1); - t2.timepoint = await time.clockFromReceipt[mode](t2); - t3.timepoint = await time.clockFromReceipt[mode](t3); - t4.timepoint = await time.clockFromReceipt[mode](t4); - - expect(await this.token.getPastVotes(this.other1, t1.timepoint - 1n)).to.equal(0n); - expect(await this.token.getPastVotes(this.other1, t1.timepoint)).to.equal(supply); - expect(await this.token.getPastVotes(this.other1, t1.timepoint + 1n)).to.equal(supply); - expect(await this.token.getPastVotes(this.other1, t2.timepoint)).to.equal(supply - 10n); - expect(await this.token.getPastVotes(this.other1, t2.timepoint + 1n)).to.equal(supply - 10n); - expect(await this.token.getPastVotes(this.other1, t3.timepoint)).to.equal(supply - 20n); - expect(await this.token.getPastVotes(this.other1, t3.timepoint + 1n)).to.equal(supply - 20n); - expect(await this.token.getPastVotes(this.other1, t4.timepoint)).to.equal(supply); - expect(await this.token.getPastVotes(this.other1, t4.timepoint + 1n)).to.equal(supply); - }); - }); - }); - - describe('getPastTotalSupply', function () { - beforeEach(async function () { - await this.token.connect(this.holder).delegate(this.holder); - }); - - it('reverts if block number >= current block', async function () { - const clock = await this.token.clock(); - await expect(this.token.getPastTotalSupply(50_000_000_000n)) - .to.be.revertedWithCustomError(this.token, 'ERC5805FutureLookup') - .withArgs(50_000_000_000n, clock); - }); - - it('returns 0 if there are no checkpoints', async function () { - expect(await this.token.getPastTotalSupply(0n)).to.equal(0n); - }); - - it('returns the latest block if >= last checkpoint block', async function () { - const tx = await this.token.$_mint(this.holder, supply); - const timepoint = await time.clockFromReceipt[mode](tx); - await mine(2); - - expect(await this.token.getPastTotalSupply(timepoint)).to.equal(supply); - expect(await this.token.getPastTotalSupply(timepoint + 1n)).to.equal(supply); - }); - - it('returns zero if < first checkpoint block', async function () { - await mine(); - const tx = await this.token.$_mint(this.holder, supply); - const timepoint = await time.clockFromReceipt[mode](tx); - await mine(2); - - expect(await this.token.getPastTotalSupply(timepoint - 1n)).to.equal(0n); - expect(await this.token.getPastTotalSupply(timepoint + 1n)).to.equal(supply); - }); - - it('generally returns the voting balance at the appropriate checkpoint', async function () { - const t1 = await this.token.$_mint(this.holder, supply); - await mine(2); - const t2 = await this.token.$_burn(this.holder, 10n); - await mine(2); - const t3 = await this.token.$_burn(this.holder, 10n); - await mine(2); - const t4 = await this.token.$_mint(this.holder, 20n); - await mine(2); - - t1.timepoint = await time.clockFromReceipt[mode](t1); - t2.timepoint = await time.clockFromReceipt[mode](t2); - t3.timepoint = await time.clockFromReceipt[mode](t3); - t4.timepoint = await time.clockFromReceipt[mode](t4); - - expect(await this.token.getPastTotalSupply(t1.timepoint - 1n)).to.equal(0n); - expect(await this.token.getPastTotalSupply(t1.timepoint)).to.equal(supply); - expect(await this.token.getPastTotalSupply(t1.timepoint + 1n)).to.equal(supply); - expect(await this.token.getPastTotalSupply(t2.timepoint)).to.equal(supply - 10n); - expect(await this.token.getPastTotalSupply(t2.timepoint + 1n)).to.equal(supply - 10n); - expect(await this.token.getPastTotalSupply(t3.timepoint)).to.equal(supply - 20n); - expect(await this.token.getPastTotalSupply(t3.timepoint + 1n)).to.equal(supply - 20n); - expect(await this.token.getPastTotalSupply(t4.timepoint)).to.equal(supply); - expect(await this.token.getPastTotalSupply(t4.timepoint + 1n)).to.equal(supply); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Wrapper.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Wrapper.test.js deleted file mode 100644 index 9e72e1a928..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC20Wrapper.test.js +++ /dev/null @@ -1,203 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { shouldBehaveLikeERC20 } = require('../ERC20.behavior'); - -const name = 'My Token'; -const symbol = 'MTKN'; -const decimals = 9n; -const initialSupply = 100n; - -async function fixture() { - // this.accounts is used by shouldBehaveLikeERC20 - const accounts = await ethers.getSigners(); - const [holder, recipient, other] = accounts; - - const underlying = await ethers.deployContract('$ERC20DecimalsMock', [name, symbol, decimals]); - await underlying.$_mint(holder, initialSupply); - - const token = await ethers.deployContract('$ERC20Wrapper', [`Wrapped ${name}`, `W${symbol}`, underlying]); - - return { accounts, holder, recipient, other, underlying, token }; -} - -describe('ERC20Wrapper', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - afterEach('Underlying balance', async function () { - expect(await this.underlying.balanceOf(this.token)).to.equal(await this.token.totalSupply()); - }); - - it('has a name', async function () { - expect(await this.token.name()).to.equal(`Wrapped ${name}`); - }); - - it('has a symbol', async function () { - expect(await this.token.symbol()).to.equal(`W${symbol}`); - }); - - it('has the same decimals as the underlying token', async function () { - expect(await this.token.decimals()).to.equal(decimals); - }); - - it('decimals default back to 18 if token has no metadata', async function () { - const noDecimals = await ethers.deployContract('CallReceiverMock'); - const token = await ethers.deployContract('$ERC20Wrapper', [`Wrapped ${name}`, `W${symbol}`, noDecimals]); - expect(await token.decimals()).to.equal(18n); - }); - - it('has underlying', async function () { - expect(await this.token.underlying()).to.equal(this.underlying); - }); - - describe('deposit', function () { - it('executes with approval', async function () { - await this.underlying.connect(this.holder).approve(this.token, initialSupply); - - const tx = await this.token.connect(this.holder).depositFor(this.holder, initialSupply); - await expect(tx) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.holder, this.token, initialSupply) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.holder, initialSupply); - await expect(tx).to.changeTokenBalances( - this.underlying, - [this.holder, this.token], - [-initialSupply, initialSupply], - ); - await expect(tx).to.changeTokenBalance(this.token, this.holder, initialSupply); - }); - - it('reverts when missing approval', async function () { - await expect(this.token.connect(this.holder).depositFor(this.holder, initialSupply)) - .to.be.revertedWithCustomError(this.underlying, 'ERC20InsufficientAllowance') - .withArgs(this.token, 0, initialSupply); - }); - - it('reverts when inssuficient balance', async function () { - await this.underlying.connect(this.holder).approve(this.token, ethers.MaxUint256); - - await expect(this.token.connect(this.holder).depositFor(this.holder, ethers.MaxUint256)) - .to.be.revertedWithCustomError(this.underlying, 'ERC20InsufficientBalance') - .withArgs(this.holder, initialSupply, ethers.MaxUint256); - }); - - it('deposits to other account', async function () { - await this.underlying.connect(this.holder).approve(this.token, initialSupply); - - const tx = await this.token.connect(this.holder).depositFor(this.recipient, initialSupply); - await expect(tx) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.holder, this.token.target, initialSupply) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.recipient, initialSupply); - await expect(tx).to.changeTokenBalances( - this.underlying, - [this.holder, this.token], - [-initialSupply, initialSupply], - ); - await expect(tx).to.changeTokenBalances(this.token, [this.holder, this.recipient], [0, initialSupply]); - }); - - it('reverts minting to the wrapper contract', async function () { - await this.underlying.connect(this.holder).approve(this.token, ethers.MaxUint256); - - await expect(this.token.connect(this.holder).depositFor(this.token, ethers.MaxUint256)) - .to.be.revertedWithCustomError(this.token, 'ERC20InvalidReceiver') - .withArgs(this.token); - }); - }); - - describe('withdraw', function () { - beforeEach(async function () { - await this.underlying.connect(this.holder).approve(this.token, initialSupply); - await this.token.connect(this.holder).depositFor(this.holder, initialSupply); - }); - - it('reverts when inssuficient balance', async function () { - await expect(this.token.connect(this.holder).withdrawTo(this.holder, ethers.MaxInt256)) - .to.be.revertedWithCustomError(this.token, 'ERC20InsufficientBalance') - .withArgs(this.holder, initialSupply, ethers.MaxInt256); - }); - - it('executes when operation is valid', async function () { - const value = 42n; - - const tx = await this.token.connect(this.holder).withdrawTo(this.holder, value); - await expect(tx) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.token.target, this.holder, value) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, ethers.ZeroAddress, value); - await expect(tx).to.changeTokenBalances(this.underlying, [this.token, this.holder], [-value, value]); - await expect(tx).to.changeTokenBalance(this.token, this.holder, -value); - }); - - it('entire balance', async function () { - const tx = await this.token.connect(this.holder).withdrawTo(this.holder, initialSupply); - await expect(tx) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.token.target, this.holder, initialSupply) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, ethers.ZeroAddress, initialSupply); - await expect(tx).to.changeTokenBalances( - this.underlying, - [this.token, this.holder], - [-initialSupply, initialSupply], - ); - await expect(tx).to.changeTokenBalance(this.token, this.holder, -initialSupply); - }); - - it('to other account', async function () { - const tx = await this.token.connect(this.holder).withdrawTo(this.recipient, initialSupply); - await expect(tx) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.token, this.recipient, initialSupply) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, ethers.ZeroAddress, initialSupply); - await expect(tx).to.changeTokenBalances( - this.underlying, - [this.token, this.holder, this.recipient], - [-initialSupply, 0, initialSupply], - ); - await expect(tx).to.changeTokenBalance(this.token, this.holder, -initialSupply); - }); - - it('reverts withdrawing to the wrapper contract', async function () { - await expect(this.token.connect(this.holder).withdrawTo(this.token, initialSupply)) - .to.be.revertedWithCustomError(this.token, 'ERC20InvalidReceiver') - .withArgs(this.token); - }); - }); - - describe('recover', function () { - it('nothing to recover', async function () { - await this.underlying.connect(this.holder).approve(this.token, initialSupply); - await this.token.connect(this.holder).depositFor(this.holder, initialSupply); - - const tx = await this.token.$_recover(this.recipient); - await expect(tx).to.emit(this.token, 'Transfer').withArgs(ethers.ZeroAddress, this.recipient, 0n); - await expect(tx).to.changeTokenBalance(this.token, this.recipient, 0); - }); - - it('something to recover', async function () { - await this.underlying.connect(this.holder).transfer(this.token, initialSupply); - - const tx = await this.token.$_recover(this.recipient); - await expect(tx).to.emit(this.token, 'Transfer').withArgs(ethers.ZeroAddress, this.recipient, initialSupply); - await expect(tx).to.changeTokenBalance(this.token, this.recipient, initialSupply); - }); - }); - - describe('erc20 behaviour', function () { - beforeEach(async function () { - await this.underlying.connect(this.holder).approve(this.token, initialSupply); - await this.token.connect(this.holder).depositFor(this.holder, initialSupply); - }); - - shouldBehaveLikeERC20(initialSupply); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC4626.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC4626.t.sol deleted file mode 100644 index 72b0daca1c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC4626.t.sol +++ /dev/null @@ -1,41 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.20; - -import {ERC4626Test} from "erc4626-tests/ERC4626.test.sol"; - -import {ERC20} from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; -import {ERC4626} from "@openzeppelin/contracts/token/ERC20/extensions/ERC4626.sol"; - -import {ERC20Mock} from "@openzeppelin/contracts/mocks/token/ERC20Mock.sol"; -import {ERC4626Mock} from "@openzeppelin/contracts/mocks/token/ERC4626Mock.sol"; -import {ERC4626OffsetMock} from "@openzeppelin/contracts/mocks/token/ERC4626OffsetMock.sol"; - -contract ERC4626VaultOffsetMock is ERC4626OffsetMock { - constructor( - ERC20 underlying_, - uint8 offset_ - ) ERC20("My Token Vault", "MTKNV") ERC4626(underlying_) ERC4626OffsetMock(offset_) {} -} - -contract ERC4626StdTest is ERC4626Test { - ERC20 private _underlying = new ERC20Mock(); - - function setUp() public override { - _underlying_ = address(_underlying); - _vault_ = address(new ERC4626Mock(_underlying_)); - _delta_ = 0; - _vaultMayBeEmpty = true; - _unlimitedAmount = true; - } - - /** - * @dev Check the case where calculated `decimals` value overflows the `uint8` type. - */ - function testFuzzDecimalsOverflow(uint8 offset) public { - /// @dev Remember that the `_underlying` exhibits a `decimals` value of 18. - offset = uint8(bound(uint256(offset), 238, uint256(type(uint8).max))); - ERC4626VaultOffsetMock erc4626VaultOffsetMock = new ERC4626VaultOffsetMock(_underlying, offset); - vm.expectRevert(); - erc4626VaultOffsetMock.decimals(); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC4626.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC4626.test.js deleted file mode 100644 index 71c7cbaafb..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/ERC4626.test.js +++ /dev/null @@ -1,888 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -const { Enum } = require('../../../helpers/enums'); - -const name = 'My Token'; -const symbol = 'MTKN'; -const decimals = 18n; - -async function fixture() { - const [holder, recipient, spender, other, ...accounts] = await ethers.getSigners(); - return { holder, recipient, spender, other, accounts }; -} - -describe('ERC4626', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('inherit decimals if from asset', async function () { - for (const decimals of [0n, 9n, 12n, 18n, 36n]) { - const token = await ethers.deployContract('$ERC20DecimalsMock', ['', '', decimals]); - const vault = await ethers.deployContract('$ERC4626', ['', '', token]); - expect(await vault.decimals()).to.equal(decimals); - } - }); - - it('asset has not yet been created', async function () { - const vault = await ethers.deployContract('$ERC4626', ['', '', this.other.address]); - expect(await vault.decimals()).to.equal(decimals); - }); - - it('underlying excess decimals', async function () { - const token = await ethers.deployContract('$ERC20ExcessDecimalsMock'); - const vault = await ethers.deployContract('$ERC4626', ['', '', token]); - expect(await vault.decimals()).to.equal(decimals); - }); - - it('decimals overflow', async function () { - for (const offset of [243n, 250n, 255n]) { - const token = await ethers.deployContract('$ERC20DecimalsMock', ['', '', decimals]); - const vault = await ethers.deployContract('$ERC4626OffsetMock', ['', '', token, offset]); - await expect(vault.decimals()).to.be.revertedWithPanic(PANIC_CODES.ARITHMETIC_UNDER_OR_OVERFLOW); - } - }); - - describe('reentrancy', function () { - const reenterType = Enum('No', 'Before', 'After'); - - const value = 1_000_000_000_000_000_000n; - const reenterValue = 1_000_000_000n; - - beforeEach(async function () { - // Use offset 1 so the rate is not 1:1 and we can't possibly confuse assets and shares - const token = await ethers.deployContract('$ERC20Reentrant'); - const vault = await ethers.deployContract('$ERC4626OffsetMock', ['', '', token, 1n]); - // Funds and approval for tests - await token.$_mint(this.holder, value); - await token.$_mint(this.other, value); - await token.$_approve(this.holder, vault, ethers.MaxUint256); - await token.$_approve(this.other, vault, ethers.MaxUint256); - await token.$_approve(token, vault, ethers.MaxUint256); - - Object.assign(this, { token, vault }); - }); - - // During a `_deposit`, the vault does `transferFrom(depositor, vault, assets)` -> `_mint(receiver, shares)` - // such that a reentrancy BEFORE the transfer guarantees the price is kept the same. - // If the order of transfer -> mint is changed to mint -> transfer, the reentrancy could be triggered on an - // intermediate state in which the ratio of assets/shares has been decreased (more shares than assets). - it('correct share price is observed during reentrancy before deposit', async function () { - // mint token for deposit - await this.token.$_mint(this.token, reenterValue); - - // Schedules a reentrancy from the token contract - await this.token.scheduleReenter( - reenterType.Before, - this.vault, - this.vault.interface.encodeFunctionData('deposit', [reenterValue, this.holder.address]), - ); - - // Initial share price - const sharesForDeposit = await this.vault.previewDeposit(value); - const sharesForReenter = await this.vault.previewDeposit(reenterValue); - - await expect(this.vault.connect(this.holder).deposit(value, this.holder)) - // Deposit normally, reentering before the internal `_update` - .to.emit(this.vault, 'Deposit') - .withArgs(this.holder, this.holder, value, sharesForDeposit) - // Reentrant deposit event → uses the same price - .to.emit(this.vault, 'Deposit') - .withArgs(this.token, this.holder, reenterValue, sharesForReenter); - - // Assert prices is kept - expect(await this.vault.previewDeposit(value)).to.equal(sharesForDeposit); - }); - - // During a `_withdraw`, the vault does `_burn(owner, shares)` -> `transfer(receiver, assets)` - // such that a reentrancy AFTER the transfer guarantees the price is kept the same. - // If the order of burn -> transfer is changed to transfer -> burn, the reentrancy could be triggered on an - // intermediate state in which the ratio of shares/assets has been decreased (more assets than shares). - it('correct share price is observed during reentrancy after withdraw', async function () { - // Deposit into the vault: holder gets `value` share, token.address gets `reenterValue` shares - await this.vault.connect(this.holder).deposit(value, this.holder); - await this.vault.connect(this.other).deposit(reenterValue, this.token); - - // Schedules a reentrancy from the token contract - await this.token.scheduleReenter( - reenterType.After, - this.vault, - this.vault.interface.encodeFunctionData('withdraw', [reenterValue, this.holder.address, this.token.target]), - ); - - // Initial share price - const sharesForWithdraw = await this.vault.previewWithdraw(value); - const sharesForReenter = await this.vault.previewWithdraw(reenterValue); - - // Do withdraw normally, triggering the _afterTokenTransfer hook - await expect(this.vault.connect(this.holder).withdraw(value, this.holder, this.holder)) - // Main withdraw event - .to.emit(this.vault, 'Withdraw') - .withArgs(this.holder, this.holder, this.holder, value, sharesForWithdraw) - // Reentrant withdraw event → uses the same price - .to.emit(this.vault, 'Withdraw') - .withArgs(this.token, this.holder, this.token, reenterValue, sharesForReenter); - - // Assert price is kept - expect(await this.vault.previewWithdraw(value)).to.equal(sharesForWithdraw); - }); - - // Donate newly minted tokens to the vault during the reentracy causes the share price to increase. - // Still, the deposit that trigger the reentracy is not affected and get the previewed price. - // Further deposits will get a different price (getting fewer shares for the same value of assets) - it('share price change during reentracy does not affect deposit', async function () { - // Schedules a reentrancy from the token contract that mess up the share price - await this.token.scheduleReenter( - reenterType.Before, - this.token, - this.token.interface.encodeFunctionData('$_mint', [this.vault.target, reenterValue]), - ); - - // Price before - const sharesBefore = await this.vault.previewDeposit(value); - - // Deposit, reentering before the internal `_update` - await expect(this.vault.connect(this.holder).deposit(value, this.holder)) - // Price is as previewed - .to.emit(this.vault, 'Deposit') - .withArgs(this.holder, this.holder, value, sharesBefore); - - // Price was modified during reentrancy - expect(await this.vault.previewDeposit(value)).to.lt(sharesBefore); - }); - - // Burn some tokens from the vault during the reentracy causes the share price to drop. - // Still, the withdraw that trigger the reentracy is not affected and get the previewed price. - // Further withdraw will get a different price (needing more shares for the same value of assets) - it('share price change during reentracy does not affect withdraw', async function () { - await this.vault.connect(this.holder).deposit(value, this.holder); - await this.vault.connect(this.other).deposit(value, this.other); - - // Schedules a reentrancy from the token contract that mess up the share price - await this.token.scheduleReenter( - reenterType.After, - this.token, - this.token.interface.encodeFunctionData('$_burn', [this.vault.target, reenterValue]), - ); - - // Price before - const sharesBefore = await this.vault.previewWithdraw(value); - - // Withdraw, triggering the _afterTokenTransfer hook - await expect(this.vault.connect(this.holder).withdraw(value, this.holder, this.holder)) - // Price is as previewed - .to.emit(this.vault, 'Withdraw') - .withArgs(this.holder, this.holder, this.holder, value, sharesBefore); - - // Price was modified during reentrancy - expect(await this.vault.previewWithdraw(value)).to.gt(sharesBefore); - }); - }); - - describe('limits', function () { - beforeEach(async function () { - const token = await ethers.deployContract('$ERC20DecimalsMock', [name, symbol, decimals]); - const vault = await ethers.deployContract('$ERC4626LimitsMock', ['', '', token]); - - Object.assign(this, { token, vault }); - }); - - it('reverts on deposit() above max deposit', async function () { - const maxDeposit = await this.vault.maxDeposit(this.holder); - await expect(this.vault.connect(this.holder).deposit(maxDeposit + 1n, this.recipient)) - .to.be.revertedWithCustomError(this.vault, 'ERC4626ExceededMaxDeposit') - .withArgs(this.recipient, maxDeposit + 1n, maxDeposit); - }); - - it('reverts on mint() above max mint', async function () { - const maxMint = await this.vault.maxMint(this.holder); - - await expect(this.vault.connect(this.holder).mint(maxMint + 1n, this.recipient)) - .to.be.revertedWithCustomError(this.vault, 'ERC4626ExceededMaxMint') - .withArgs(this.recipient, maxMint + 1n, maxMint); - }); - - it('reverts on withdraw() above max withdraw', async function () { - const maxWithdraw = await this.vault.maxWithdraw(this.holder); - - await expect(this.vault.connect(this.holder).withdraw(maxWithdraw + 1n, this.recipient, this.holder)) - .to.be.revertedWithCustomError(this.vault, 'ERC4626ExceededMaxWithdraw') - .withArgs(this.holder, maxWithdraw + 1n, maxWithdraw); - }); - - it('reverts on redeem() above max redeem', async function () { - const maxRedeem = await this.vault.maxRedeem(this.holder); - - await expect(this.vault.connect(this.holder).redeem(maxRedeem + 1n, this.recipient, this.holder)) - .to.be.revertedWithCustomError(this.vault, 'ERC4626ExceededMaxRedeem') - .withArgs(this.holder, maxRedeem + 1n, maxRedeem); - }); - }); - - for (const offset of [0n, 6n, 18n]) { - const parseToken = token => token * 10n ** decimals; - const parseShare = share => share * 10n ** (decimals + offset); - - const virtualAssets = 1n; - const virtualShares = 10n ** offset; - - describe(`offset: ${offset}`, function () { - beforeEach(async function () { - const token = await ethers.deployContract('$ERC20DecimalsMock', [name, symbol, decimals]); - const vault = await ethers.deployContract('$ERC4626OffsetMock', [name + ' Vault', symbol + 'V', token, offset]); - - await token.$_mint(this.holder, ethers.MaxUint256 / 2n); // 50% of maximum - await token.$_approve(this.holder, vault, ethers.MaxUint256); - await vault.$_approve(this.holder, this.spender, ethers.MaxUint256); - - Object.assign(this, { token, vault }); - }); - - it('metadata', async function () { - expect(await this.vault.name()).to.equal(name + ' Vault'); - expect(await this.vault.symbol()).to.equal(symbol + 'V'); - expect(await this.vault.decimals()).to.equal(decimals + offset); - expect(await this.vault.asset()).to.equal(this.token); - }); - - describe('empty vault: no assets & no shares', function () { - it('status', async function () { - expect(await this.vault.totalAssets()).to.equal(0n); - }); - - it('deposit', async function () { - expect(await this.vault.maxDeposit(this.holder)).to.equal(ethers.MaxUint256); - expect(await this.vault.previewDeposit(parseToken(1n))).to.equal(parseShare(1n)); - - const tx = this.vault.connect(this.holder).deposit(parseToken(1n), this.recipient); - - await expect(tx).to.changeTokenBalances( - this.token, - [this.holder, this.vault], - [-parseToken(1n), parseToken(1n)], - ); - await expect(tx).to.changeTokenBalance(this.vault, this.recipient, parseShare(1n)); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.vault, parseToken(1n)) - .to.emit(this.vault, 'Transfer') - .withArgs(ethers.ZeroAddress, this.recipient, parseShare(1n)) - .to.emit(this.vault, 'Deposit') - .withArgs(this.holder, this.recipient, parseToken(1n), parseShare(1n)); - }); - - it('mint', async function () { - expect(await this.vault.maxMint(this.holder)).to.equal(ethers.MaxUint256); - expect(await this.vault.previewMint(parseShare(1n))).to.equal(parseToken(1n)); - - const tx = this.vault.connect(this.holder).mint(parseShare(1n), this.recipient); - - await expect(tx).to.changeTokenBalances( - this.token, - [this.holder, this.vault], - [-parseToken(1n), parseToken(1n)], - ); - await expect(tx).to.changeTokenBalance(this.vault, this.recipient, parseShare(1n)); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.vault, parseToken(1n)) - .to.emit(this.vault, 'Transfer') - .withArgs(ethers.ZeroAddress, this.recipient, parseShare(1n)) - .to.emit(this.vault, 'Deposit') - .withArgs(this.holder, this.recipient, parseToken(1n), parseShare(1n)); - }); - - it('withdraw', async function () { - expect(await this.vault.maxWithdraw(this.holder)).to.equal(0n); - expect(await this.vault.previewWithdraw(0n)).to.equal(0n); - - const tx = this.vault.connect(this.holder).withdraw(0n, this.recipient, this.holder); - - await expect(tx).to.changeTokenBalances(this.token, [this.vault, this.recipient], [0n, 0n]); - await expect(tx).to.changeTokenBalance(this.vault, this.holder, 0n); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.vault, this.recipient, 0n) - .to.emit(this.vault, 'Transfer') - .withArgs(this.holder, ethers.ZeroAddress, 0n) - .to.emit(this.vault, 'Withdraw') - .withArgs(this.holder, this.recipient, this.holder, 0n, 0n); - }); - - it('redeem', async function () { - expect(await this.vault.maxRedeem(this.holder)).to.equal(0n); - expect(await this.vault.previewRedeem(0n)).to.equal(0n); - - const tx = this.vault.connect(this.holder).redeem(0n, this.recipient, this.holder); - - await expect(tx).to.changeTokenBalances(this.token, [this.vault, this.recipient], [0n, 0n]); - await expect(tx).to.changeTokenBalance(this.vault, this.holder, 0n); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.vault, this.recipient, 0n) - .to.emit(this.vault, 'Transfer') - .withArgs(this.holder, ethers.ZeroAddress, 0n) - .to.emit(this.vault, 'Withdraw') - .withArgs(this.holder, this.recipient, this.holder, 0n, 0n); - }); - }); - - describe('inflation attack: offset price by direct deposit of assets', function () { - beforeEach(async function () { - // Donate 1 token to the vault to offset the price - await this.token.$_mint(this.vault, parseToken(1n)); - }); - - it('status', async function () { - expect(await this.vault.totalSupply()).to.equal(0n); - expect(await this.vault.totalAssets()).to.equal(parseToken(1n)); - }); - - /** - * | offset | deposited assets | redeemable assets | - * |--------|----------------------|----------------------| - * | 0 | 1.000000000000000000 | 0. | - * | 6 | 1.000000000000000000 | 0.999999000000000000 | - * | 18 | 1.000000000000000000 | 0.999999999999999999 | - * - * Attack is possible, but made difficult by the offset. For the attack to be successful - * the attacker needs to frontrun a deposit 10**offset times bigger than what the victim - * was trying to deposit - */ - it('deposit', async function () { - const effectiveAssets = (await this.vault.totalAssets()) + virtualAssets; - const effectiveShares = (await this.vault.totalSupply()) + virtualShares; - - const depositAssets = parseToken(1n); - const expectedShares = (depositAssets * effectiveShares) / effectiveAssets; - - expect(await this.vault.maxDeposit(this.holder)).to.equal(ethers.MaxUint256); - expect(await this.vault.previewDeposit(depositAssets)).to.equal(expectedShares); - - const tx = this.vault.connect(this.holder).deposit(depositAssets, this.recipient); - - await expect(tx).to.changeTokenBalances( - this.token, - [this.holder, this.vault], - [-depositAssets, depositAssets], - ); - await expect(tx).to.changeTokenBalance(this.vault, this.recipient, expectedShares); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.vault, depositAssets) - .to.emit(this.vault, 'Transfer') - .withArgs(ethers.ZeroAddress, this.recipient, expectedShares) - .to.emit(this.vault, 'Deposit') - .withArgs(this.holder, this.recipient, depositAssets, expectedShares); - }); - - /** - * | offset | deposited assets | redeemable assets | - * |--------|----------------------|----------------------| - * | 0 | 1000000000000000001. | 1000000000000000001. | - * | 6 | 1000000000000000001. | 1000000000000000001. | - * | 18 | 1000000000000000001. | 1000000000000000001. | - * - * Using mint protects against inflation attack, but makes minting shares very expensive. - * The ER20 allowance for the underlying asset is needed to protect the user from (too) - * large deposits. - */ - it('mint', async function () { - const effectiveAssets = (await this.vault.totalAssets()) + virtualAssets; - const effectiveShares = (await this.vault.totalSupply()) + virtualShares; - - const mintShares = parseShare(1n); - const expectedAssets = (mintShares * effectiveAssets) / effectiveShares; - - expect(await this.vault.maxMint(this.holder)).to.equal(ethers.MaxUint256); - expect(await this.vault.previewMint(mintShares)).to.equal(expectedAssets); - - const tx = this.vault.connect(this.holder).mint(mintShares, this.recipient); - - await expect(tx).to.changeTokenBalances( - this.token, - [this.holder, this.vault], - [-expectedAssets, expectedAssets], - ); - await expect(tx).to.changeTokenBalance(this.vault, this.recipient, mintShares); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.vault, expectedAssets) - .to.emit(this.vault, 'Transfer') - .withArgs(ethers.ZeroAddress, this.recipient, mintShares) - .to.emit(this.vault, 'Deposit') - .withArgs(this.holder, this.recipient, expectedAssets, mintShares); - }); - - it('withdraw', async function () { - expect(await this.vault.maxWithdraw(this.holder)).to.equal(0n); - expect(await this.vault.previewWithdraw(0n)).to.equal(0n); - - const tx = this.vault.connect(this.holder).withdraw(0n, this.recipient, this.holder); - - await expect(tx).to.changeTokenBalances(this.token, [this.vault, this.recipient], [0n, 0n]); - await expect(tx).to.changeTokenBalance(this.vault, this.holder, 0n); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.vault, this.recipient, 0n) - .to.emit(this.vault, 'Transfer') - .withArgs(this.holder, ethers.ZeroAddress, 0n) - .to.emit(this.vault, 'Withdraw') - .withArgs(this.holder, this.recipient, this.holder, 0n, 0n); - }); - - it('redeem', async function () { - expect(await this.vault.maxRedeem(this.holder)).to.equal(0n); - expect(await this.vault.previewRedeem(0n)).to.equal(0n); - - const tx = this.vault.connect(this.holder).redeem(0n, this.recipient, this.holder); - - await expect(tx).to.changeTokenBalances(this.token, [this.vault, this.recipient], [0n, 0n]); - await expect(tx).to.changeTokenBalance(this.vault, this.holder, 0n); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.vault, this.recipient, 0n) - .to.emit(this.vault, 'Transfer') - .withArgs(this.holder, ethers.ZeroAddress, 0n) - .to.emit(this.vault, 'Withdraw') - .withArgs(this.holder, this.recipient, this.holder, 0n, 0n); - }); - }); - - describe('full vault: assets & shares', function () { - beforeEach(async function () { - // Add 1 token of underlying asset and 100 shares to the vault - await this.token.$_mint(this.vault, parseToken(1n)); - await this.vault.$_mint(this.holder, parseShare(100n)); - }); - - it('status', async function () { - expect(await this.vault.totalSupply()).to.equal(parseShare(100n)); - expect(await this.vault.totalAssets()).to.equal(parseToken(1n)); - }); - - /** - * | offset | deposited assets | redeemable assets | - * |--------|--------------------- |----------------------| - * | 0 | 1.000000000000000000 | 0.999999999999999999 | - * | 6 | 1.000000000000000000 | 0.999999999999999999 | - * | 18 | 1.000000000000000000 | 0.999999999999999999 | - * - * Virtual shares & assets captures part of the value - */ - it('deposit', async function () { - const effectiveAssets = (await this.vault.totalAssets()) + virtualAssets; - const effectiveShares = (await this.vault.totalSupply()) + virtualShares; - - const depositAssets = parseToken(1n); - const expectedShares = (depositAssets * effectiveShares) / effectiveAssets; - - expect(await this.vault.maxDeposit(this.holder)).to.equal(ethers.MaxUint256); - expect(await this.vault.previewDeposit(depositAssets)).to.equal(expectedShares); - - const tx = this.vault.connect(this.holder).deposit(depositAssets, this.recipient); - - await expect(tx).to.changeTokenBalances( - this.token, - [this.holder, this.vault], - [-depositAssets, depositAssets], - ); - await expect(tx).to.changeTokenBalance(this.vault, this.recipient, expectedShares); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.vault, depositAssets) - .to.emit(this.vault, 'Transfer') - .withArgs(ethers.ZeroAddress, this.recipient, expectedShares) - .to.emit(this.vault, 'Deposit') - .withArgs(this.holder, this.recipient, depositAssets, expectedShares); - }); - - /** - * | offset | deposited assets | redeemable assets | - * |--------|--------------------- |----------------------| - * | 0 | 0.010000000000000001 | 0.010000000000000000 | - * | 6 | 0.010000000000000001 | 0.010000000000000000 | - * | 18 | 0.010000000000000001 | 0.010000000000000000 | - * - * Virtual shares & assets captures part of the value - */ - it('mint', async function () { - const effectiveAssets = (await this.vault.totalAssets()) + virtualAssets; - const effectiveShares = (await this.vault.totalSupply()) + virtualShares; - - const mintShares = parseShare(1n); - const expectedAssets = (mintShares * effectiveAssets) / effectiveShares + 1n; // add for the rounding - - expect(await this.vault.maxMint(this.holder)).to.equal(ethers.MaxUint256); - expect(await this.vault.previewMint(mintShares)).to.equal(expectedAssets); - - const tx = this.vault.connect(this.holder).mint(mintShares, this.recipient); - - await expect(tx).to.changeTokenBalances( - this.token, - [this.holder, this.vault], - [-expectedAssets, expectedAssets], - ); - await expect(tx).to.changeTokenBalance(this.vault, this.recipient, mintShares); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.vault, expectedAssets) - .to.emit(this.vault, 'Transfer') - .withArgs(ethers.ZeroAddress, this.recipient, mintShares) - .to.emit(this.vault, 'Deposit') - .withArgs(this.holder, this.recipient, expectedAssets, mintShares); - }); - - it('withdraw', async function () { - const effectiveAssets = (await this.vault.totalAssets()) + virtualAssets; - const effectiveShares = (await this.vault.totalSupply()) + virtualShares; - - const withdrawAssets = parseToken(1n); - const expectedShares = (withdrawAssets * effectiveShares) / effectiveAssets + 1n; // add for the rounding - - expect(await this.vault.maxWithdraw(this.holder)).to.equal(withdrawAssets); - expect(await this.vault.previewWithdraw(withdrawAssets)).to.equal(expectedShares); - - const tx = this.vault.connect(this.holder).withdraw(withdrawAssets, this.recipient, this.holder); - - await expect(tx).to.changeTokenBalances( - this.token, - [this.vault, this.recipient], - [-withdrawAssets, withdrawAssets], - ); - await expect(tx).to.changeTokenBalance(this.vault, this.holder, -expectedShares); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.vault, this.recipient, withdrawAssets) - .to.emit(this.vault, 'Transfer') - .withArgs(this.holder, ethers.ZeroAddress, expectedShares) - .to.emit(this.vault, 'Withdraw') - .withArgs(this.holder, this.recipient, this.holder, withdrawAssets, expectedShares); - }); - - it('withdraw with approval', async function () { - const assets = await this.vault.previewWithdraw(parseToken(1n)); - - await expect(this.vault.connect(this.other).withdraw(parseToken(1n), this.recipient, this.holder)) - .to.be.revertedWithCustomError(this.vault, 'ERC20InsufficientAllowance') - .withArgs(this.other, 0n, assets); - - await expect(this.vault.connect(this.spender).withdraw(parseToken(1n), this.recipient, this.holder)).to.not.be - .reverted; - }); - - it('redeem', async function () { - const effectiveAssets = (await this.vault.totalAssets()) + virtualAssets; - const effectiveShares = (await this.vault.totalSupply()) + virtualShares; - - const redeemShares = parseShare(100n); - const expectedAssets = (redeemShares * effectiveAssets) / effectiveShares; - - expect(await this.vault.maxRedeem(this.holder)).to.equal(redeemShares); - expect(await this.vault.previewRedeem(redeemShares)).to.equal(expectedAssets); - - const tx = this.vault.connect(this.holder).redeem(redeemShares, this.recipient, this.holder); - - await expect(tx).to.changeTokenBalances( - this.token, - [this.vault, this.recipient], - [-expectedAssets, expectedAssets], - ); - await expect(tx).to.changeTokenBalance(this.vault, this.holder, -redeemShares); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.vault, this.recipient, expectedAssets) - .to.emit(this.vault, 'Transfer') - .withArgs(this.holder, ethers.ZeroAddress, redeemShares) - .to.emit(this.vault, 'Withdraw') - .withArgs(this.holder, this.recipient, this.holder, expectedAssets, redeemShares); - }); - - it('redeem with approval', async function () { - await expect(this.vault.connect(this.other).redeem(parseShare(100n), this.recipient, this.holder)) - .to.be.revertedWithCustomError(this.vault, 'ERC20InsufficientAllowance') - .withArgs(this.other, 0n, parseShare(100n)); - - await expect(this.vault.connect(this.spender).redeem(parseShare(100n), this.recipient, this.holder)).to.not.be - .reverted; - }); - }); - }); - } - - describe('ERC4626Fees', function () { - const feeBasisPoints = 500n; // 5% - const valueWithoutFees = 10_000n; - const fees = (valueWithoutFees * feeBasisPoints) / 10_000n; - const valueWithFees = valueWithoutFees + fees; - - describe('input fees', function () { - beforeEach(async function () { - const token = await ethers.deployContract('$ERC20DecimalsMock', [name, symbol, 18n]); - const vault = await ethers.deployContract('$ERC4626FeesMock', [ - '', - '', - token, - feeBasisPoints, - this.other, - 0n, - ethers.ZeroAddress, - ]); - - await token.$_mint(this.holder, ethers.MaxUint256 / 2n); - await token.$_approve(this.holder, vault, ethers.MaxUint256 / 2n); - - Object.assign(this, { token, vault }); - }); - - it('deposit', async function () { - expect(await this.vault.previewDeposit(valueWithFees)).to.equal(valueWithoutFees); - this.tx = this.vault.connect(this.holder).deposit(valueWithFees, this.recipient); - }); - - it('mint', async function () { - expect(await this.vault.previewMint(valueWithoutFees)).to.equal(valueWithFees); - this.tx = this.vault.connect(this.holder).mint(valueWithoutFees, this.recipient); - }); - - afterEach(async function () { - await expect(this.tx).to.changeTokenBalances( - this.token, - [this.holder, this.vault, this.other], - [-valueWithFees, valueWithoutFees, fees], - ); - await expect(this.tx).to.changeTokenBalance(this.vault, this.recipient, valueWithoutFees); - await expect(this.tx) - // get total - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.vault, valueWithFees) - // redirect fees - .to.emit(this.token, 'Transfer') - .withArgs(this.vault, this.other, fees) - // mint shares - .to.emit(this.vault, 'Transfer') - .withArgs(ethers.ZeroAddress, this.recipient, valueWithoutFees) - // deposit event - .to.emit(this.vault, 'Deposit') - .withArgs(this.holder, this.recipient, valueWithFees, valueWithoutFees); - }); - }); - - describe('output fees', function () { - beforeEach(async function () { - const token = await ethers.deployContract('$ERC20DecimalsMock', [name, symbol, 18n]); - const vault = await ethers.deployContract('$ERC4626FeesMock', [ - '', - '', - token, - 0n, - ethers.ZeroAddress, - feeBasisPoints, - this.other, - ]); - - await token.$_mint(vault, ethers.MaxUint256 / 2n); - await vault.$_mint(this.holder, ethers.MaxUint256 / 2n); - - Object.assign(this, { token, vault }); - }); - - it('redeem', async function () { - expect(await this.vault.previewRedeem(valueWithFees)).to.equal(valueWithoutFees); - this.tx = this.vault.connect(this.holder).redeem(valueWithFees, this.recipient, this.holder); - }); - - it('withdraw', async function () { - expect(await this.vault.previewWithdraw(valueWithoutFees)).to.equal(valueWithFees); - this.tx = this.vault.connect(this.holder).withdraw(valueWithoutFees, this.recipient, this.holder); - }); - - afterEach(async function () { - await expect(this.tx).to.changeTokenBalances( - this.token, - [this.vault, this.recipient, this.other], - [-valueWithFees, valueWithoutFees, fees], - ); - await expect(this.tx).to.changeTokenBalance(this.vault, this.holder, -valueWithFees); - await expect(this.tx) - // withdraw principal - .to.emit(this.token, 'Transfer') - .withArgs(this.vault, this.recipient, valueWithoutFees) - // redirect fees - .to.emit(this.token, 'Transfer') - .withArgs(this.vault, this.other, fees) - // mint shares - .to.emit(this.vault, 'Transfer') - .withArgs(this.holder, ethers.ZeroAddress, valueWithFees) - // withdraw event - .to.emit(this.vault, 'Withdraw') - .withArgs(this.holder, this.recipient, this.holder, valueWithoutFees, valueWithFees); - }); - }); - }); - - /// Scenario inspired by solmate ERC4626 tests: - /// https://github.com/transmissions11/solmate/blob/main/src/test/ERC4626.t.sol - it('multiple mint, deposit, redeem & withdrawal', async function () { - // test designed with both asset using similar decimals - const [alice, bruce] = this.accounts; - const token = await ethers.deployContract('$ERC20DecimalsMock', [name, symbol, 18n]); - const vault = await ethers.deployContract('$ERC4626', ['', '', token]); - - await token.$_mint(alice, 4000n); - await token.$_mint(bruce, 7001n); - await token.connect(alice).approve(vault, 4000n); - await token.connect(bruce).approve(vault, 7001n); - - // 1. Alice mints 2000 shares (costs 2000 tokens) - await expect(vault.connect(alice).mint(2000n, alice)) - .to.emit(token, 'Transfer') - .withArgs(alice, vault, 2000n) - .to.emit(vault, 'Transfer') - .withArgs(ethers.ZeroAddress, alice, 2000n); - - expect(await vault.previewDeposit(2000n)).to.equal(2000n); - expect(await vault.balanceOf(alice)).to.equal(2000n); - expect(await vault.balanceOf(bruce)).to.equal(0n); - expect(await vault.convertToAssets(await vault.balanceOf(alice))).to.equal(2000n); - expect(await vault.convertToAssets(await vault.balanceOf(bruce))).to.equal(0n); - expect(await vault.convertToShares(await token.balanceOf(vault))).to.equal(2000n); - expect(await vault.totalSupply()).to.equal(2000n); - expect(await vault.totalAssets()).to.equal(2000n); - - // 2. Bruce deposits 4000 tokens (mints 4000 shares) - await expect(vault.connect(bruce).mint(4000n, bruce)) - .to.emit(token, 'Transfer') - .withArgs(bruce, vault, 4000n) - .to.emit(vault, 'Transfer') - .withArgs(ethers.ZeroAddress, bruce, 4000n); - - expect(await vault.previewDeposit(4000n)).to.equal(4000n); - expect(await vault.balanceOf(alice)).to.equal(2000n); - expect(await vault.balanceOf(bruce)).to.equal(4000n); - expect(await vault.convertToAssets(await vault.balanceOf(alice))).to.equal(2000n); - expect(await vault.convertToAssets(await vault.balanceOf(bruce))).to.equal(4000n); - expect(await vault.convertToShares(await token.balanceOf(vault))).to.equal(6000n); - expect(await vault.totalSupply()).to.equal(6000n); - expect(await vault.totalAssets()).to.equal(6000n); - - // 3. Vault mutates by +3000 tokens (simulated yield returned from strategy) - await token.$_mint(vault, 3000n); - - expect(await vault.balanceOf(alice)).to.equal(2000n); - expect(await vault.balanceOf(bruce)).to.equal(4000n); - expect(await vault.convertToAssets(await vault.balanceOf(alice))).to.equal(2999n); // used to be 3000, but virtual assets/shares captures part of the yield - expect(await vault.convertToAssets(await vault.balanceOf(bruce))).to.equal(5999n); // used to be 6000, but virtual assets/shares captures part of the yield - expect(await vault.convertToShares(await token.balanceOf(vault))).to.equal(6000n); - expect(await vault.totalSupply()).to.equal(6000n); - expect(await vault.totalAssets()).to.equal(9000n); - - // 4. Alice deposits 2000 tokens (mints 1333 shares) - await expect(vault.connect(alice).deposit(2000n, alice)) - .to.emit(token, 'Transfer') - .withArgs(alice, vault, 2000n) - .to.emit(vault, 'Transfer') - .withArgs(ethers.ZeroAddress, alice, 1333n); - - expect(await vault.balanceOf(alice)).to.equal(3333n); - expect(await vault.balanceOf(bruce)).to.equal(4000n); - expect(await vault.convertToAssets(await vault.balanceOf(alice))).to.equal(4999n); - expect(await vault.convertToAssets(await vault.balanceOf(bruce))).to.equal(6000n); - expect(await vault.convertToShares(await token.balanceOf(vault))).to.equal(7333n); - expect(await vault.totalSupply()).to.equal(7333n); - expect(await vault.totalAssets()).to.equal(11000n); - - // 5. Bruce mints 2000 shares (costs 3001 assets) - // NOTE: Bruce's assets spent got rounded towards infinity - // NOTE: Alices's vault assets got rounded towards infinity - await expect(vault.connect(bruce).mint(2000n, bruce)) - .to.emit(token, 'Transfer') - .withArgs(bruce, vault, 3000n) - .to.emit(vault, 'Transfer') - .withArgs(ethers.ZeroAddress, bruce, 2000n); - - expect(await vault.balanceOf(alice)).to.equal(3333n); - expect(await vault.balanceOf(bruce)).to.equal(6000n); - expect(await vault.convertToAssets(await vault.balanceOf(alice))).to.equal(4999n); // used to be 5000 - expect(await vault.convertToAssets(await vault.balanceOf(bruce))).to.equal(9000n); - expect(await vault.convertToShares(await token.balanceOf(vault))).to.equal(9333n); - expect(await vault.totalSupply()).to.equal(9333n); - expect(await vault.totalAssets()).to.equal(14000n); // used to be 14001 - - // 6. Vault mutates by +3000 tokens - // NOTE: Vault holds 17001 tokens, but sum of assetsOf() is 17000. - await token.$_mint(vault, 3000n); - - expect(await vault.balanceOf(alice)).to.equal(3333n); - expect(await vault.balanceOf(bruce)).to.equal(6000n); - expect(await vault.convertToAssets(await vault.balanceOf(alice))).to.equal(6070n); // used to be 6071 - expect(await vault.convertToAssets(await vault.balanceOf(bruce))).to.equal(10928n); // used to be 10929 - expect(await vault.convertToShares(await token.balanceOf(vault))).to.equal(9333n); - expect(await vault.totalSupply()).to.equal(9333n); - expect(await vault.totalAssets()).to.equal(17000n); // used to be 17001 - - // 7. Alice redeem 1333 shares (2428 assets) - await expect(vault.connect(alice).redeem(1333n, alice, alice)) - .to.emit(vault, 'Transfer') - .withArgs(alice, ethers.ZeroAddress, 1333n) - .to.emit(token, 'Transfer') - .withArgs(vault, alice, 2427n); // used to be 2428 - - expect(await vault.balanceOf(alice)).to.equal(2000n); - expect(await vault.balanceOf(bruce)).to.equal(6000n); - expect(await vault.convertToAssets(await vault.balanceOf(alice))).to.equal(3643n); - expect(await vault.convertToAssets(await vault.balanceOf(bruce))).to.equal(10929n); - expect(await vault.convertToShares(await token.balanceOf(vault))).to.equal(8000n); - expect(await vault.totalSupply()).to.equal(8000n); - expect(await vault.totalAssets()).to.equal(14573n); - - // 8. Bruce withdraws 2929 assets (1608 shares) - await expect(vault.connect(bruce).withdraw(2929n, bruce, bruce)) - .to.emit(vault, 'Transfer') - .withArgs(bruce, ethers.ZeroAddress, 1608n) - .to.emit(token, 'Transfer') - .withArgs(vault, bruce, 2929n); - - expect(await vault.balanceOf(alice)).to.equal(2000n); - expect(await vault.balanceOf(bruce)).to.equal(4392n); - expect(await vault.convertToAssets(await vault.balanceOf(alice))).to.equal(3643n); - expect(await vault.convertToAssets(await vault.balanceOf(bruce))).to.equal(8000n); - expect(await vault.convertToShares(await token.balanceOf(vault))).to.equal(6392n); - expect(await vault.totalSupply()).to.equal(6392n); - expect(await vault.totalAssets()).to.equal(11644n); - - // 9. Alice withdraws 3643 assets (2000 shares) - // NOTE: Bruce's assets have been rounded back towards infinity - await expect(vault.connect(alice).withdraw(3643n, alice, alice)) - .to.emit(vault, 'Transfer') - .withArgs(alice, ethers.ZeroAddress, 2000n) - .to.emit(token, 'Transfer') - .withArgs(vault, alice, 3643n); - - expect(await vault.balanceOf(alice)).to.equal(0n); - expect(await vault.balanceOf(bruce)).to.equal(4392n); - expect(await vault.convertToAssets(await vault.balanceOf(alice))).to.equal(0n); - expect(await vault.convertToAssets(await vault.balanceOf(bruce))).to.equal(8000n); // used to be 8001 - expect(await vault.convertToShares(await token.balanceOf(vault))).to.equal(4392n); - expect(await vault.totalSupply()).to.equal(4392n); - expect(await vault.totalAssets()).to.equal(8001n); - - // 10. Bruce redeem 4392 shares (8001 tokens) - await expect(vault.connect(bruce).redeem(4392n, bruce, bruce)) - .to.emit(vault, 'Transfer') - .withArgs(bruce, ethers.ZeroAddress, 4392n) - .to.emit(token, 'Transfer') - .withArgs(vault, bruce, 8000n); // used to be 8001 - - expect(await vault.balanceOf(alice)).to.equal(0n); - expect(await vault.balanceOf(bruce)).to.equal(0n); - expect(await vault.convertToAssets(await vault.balanceOf(alice))).to.equal(0n); - expect(await vault.convertToAssets(await vault.balanceOf(bruce))).to.equal(0n); - expect(await vault.convertToShares(await token.balanceOf(vault))).to.equal(0n); - expect(await vault.totalSupply()).to.equal(0n); - expect(await vault.totalAssets()).to.equal(1n); // used to be 0 - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/draft-ERC20TemporaryApproval.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/draft-ERC20TemporaryApproval.test.js deleted file mode 100644 index a1f6362add..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/extensions/draft-ERC20TemporaryApproval.test.js +++ /dev/null @@ -1,142 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { max, min } = require('../../../helpers/math.js'); - -const { shouldBehaveLikeERC20 } = require('../ERC20.behavior.js'); - -const name = 'My Token'; -const symbol = 'MTKN'; -const initialSupply = 100n; - -async function fixture() { - // this.accounts is used by shouldBehaveLikeERC20 - const accounts = await ethers.getSigners(); - const [holder, recipient, other] = accounts; - - const token = await ethers.deployContract('$ERC20TemporaryApproval', [name, symbol]); - await token.$_mint(holder, initialSupply); - - const spender = await ethers.deployContract('$Address'); - const batch = await ethers.deployContract('BatchCaller'); - const getter = await ethers.deployContract('ERC20GetterHelper'); - - return { accounts, holder, recipient, other, token, spender, batch, getter }; -} - -describe('ERC20TemporaryApproval', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeERC20(initialSupply); - - describe('setting and spending temporary allowance', function () { - beforeEach(async function () { - await this.token.connect(this.holder).transfer(this.batch, initialSupply); - }); - - for (let { - description, - persistentAllowance, - temporaryAllowance, - amount, - temporaryExpected, - persistentExpected, - } of [ - { description: 'can set temporary allowance', temporaryAllowance: 42n }, - { - description: 'can set temporary allowance on top of persistent allowance', - temporaryAllowance: 42n, - persistentAllowance: 17n, - }, - { description: 'support allowance overflow', temporaryAllowance: ethers.MaxUint256, persistentAllowance: 17n }, - { description: 'consuming temporary allowance alone', temporaryAllowance: 42n, amount: 2n }, - { - description: 'fallback to persistent allowance if temporary allowance is not sufficient', - temporaryAllowance: 42n, - persistentAllowance: 17n, - amount: 50n, - }, - { - description: 'do not reduce infinite temporary allowance #1', - temporaryAllowance: ethers.MaxUint256, - amount: 50n, - temporaryExpected: ethers.MaxUint256, - }, - { - description: 'do not reduce infinite temporary allowance #2', - temporaryAllowance: 17n, - persistentAllowance: ethers.MaxUint256, - amount: 50n, - temporaryExpected: ethers.MaxUint256, - persistentExpected: ethers.MaxUint256, - }, - ]) { - persistentAllowance ??= 0n; - temporaryAllowance ??= 0n; - amount ??= 0n; - temporaryExpected ??= min(persistentAllowance + temporaryAllowance - amount, ethers.MaxUint256); - persistentExpected ??= persistentAllowance - max(amount - temporaryAllowance, 0n); - - it(description, async function () { - await expect( - this.batch.execute( - [ - persistentAllowance && { - target: this.token, - value: 0n, - data: this.token.interface.encodeFunctionData('approve', [this.spender.target, persistentAllowance]), - }, - temporaryAllowance && { - target: this.token, - value: 0n, - data: this.token.interface.encodeFunctionData('temporaryApprove', [ - this.spender.target, - temporaryAllowance, - ]), - }, - amount && { - target: this.spender, - value: 0n, - data: this.spender.interface.encodeFunctionData('$functionCall', [ - this.token.target, - this.token.interface.encodeFunctionData('transferFrom', [ - this.batch.target, - this.recipient.address, - amount, - ]), - ]), - }, - { - target: this.getter, - value: 0n, - data: this.getter.interface.encodeFunctionData('allowance', [ - this.token.target, - this.batch.target, - this.spender.target, - ]), - }, - ].filter(Boolean), - ), - ) - .to.emit(this.getter, 'ERC20Allowance') - .withArgs(this.token, this.batch, this.spender, temporaryExpected); - - expect(await this.token.allowance(this.batch, this.spender)).to.equal(persistentExpected); - }); - } - - it('reverts when the recipient is the zero address', async function () { - await expect(this.token.connect(this.holder).temporaryApprove(ethers.ZeroAddress, 1n)) - .to.be.revertedWithCustomError(this.token, 'ERC20InvalidSpender') - .withArgs(ethers.ZeroAddress); - }); - - it('reverts when the token owner is the zero address', async function () { - await expect(this.token.$_temporaryApprove(ethers.ZeroAddress, this.recipient, 1n)) - .to.be.revertedWithCustomError(this.token, 'ERC20InvalidApprover') - .withArgs(ethers.ZeroAddress); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/utils/SafeERC20.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/utils/SafeERC20.test.js deleted file mode 100644 index 16b72bd6b1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC20/utils/SafeERC20.test.js +++ /dev/null @@ -1,427 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const name = 'ERC20Mock'; -const symbol = 'ERC20Mock'; -const value = 100n; -const data = '0x12345678'; - -async function fixture() { - const [hasNoCode, owner, receiver, spender, other] = await ethers.getSigners(); - - const mock = await ethers.deployContract('$SafeERC20'); - const erc20ReturnFalseMock = await ethers.deployContract('$ERC20ReturnFalseMock', [name, symbol]); - const erc20ReturnTrueMock = await ethers.deployContract('$ERC20', [name, symbol]); // default implementation returns true - const erc20NoReturnMock = await ethers.deployContract('$ERC20NoReturnMock', [name, symbol]); - const erc20ForceApproveMock = await ethers.deployContract('$ERC20ForceApproveMock', [name, symbol]); - const erc1363Mock = await ethers.deployContract('$ERC1363', [name, symbol]); - const erc1363ReturnFalseOnErc20Mock = await ethers.deployContract('$ERC1363ReturnFalseOnERC20Mock', [name, symbol]); - const erc1363ReturnFalseMock = await ethers.deployContract('$ERC1363ReturnFalseMock', [name, symbol]); - const erc1363NoReturnMock = await ethers.deployContract('$ERC1363NoReturnMock', [name, symbol]); - const erc1363ForceApproveMock = await ethers.deployContract('$ERC1363ForceApproveMock', [name, symbol]); - const erc1363Receiver = await ethers.deployContract('$ERC1363ReceiverMock'); - const erc1363Spender = await ethers.deployContract('$ERC1363SpenderMock'); - - return { - hasNoCode, - owner, - receiver, - spender, - other, - mock, - erc20ReturnFalseMock, - erc20ReturnTrueMock, - erc20NoReturnMock, - erc20ForceApproveMock, - erc1363Mock, - erc1363ReturnFalseOnErc20Mock, - erc1363ReturnFalseMock, - erc1363NoReturnMock, - erc1363ForceApproveMock, - erc1363Receiver, - erc1363Spender, - }; -} - -describe('SafeERC20', function () { - before(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('with address that has no contract code', function () { - beforeEach(async function () { - this.token = this.hasNoCode; - }); - - it('reverts on transfer', async function () { - await expect(this.mock.$safeTransfer(this.token, this.receiver, 0n)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedOperation') - .withArgs(this.token); - }); - - it('reverts on transferFrom', async function () { - await expect(this.mock.$safeTransferFrom(this.token, this.mock, this.receiver, 0n)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedOperation') - .withArgs(this.token); - }); - - it('reverts on increaseAllowance', async function () { - // Call to 'token.allowance' does not return any data, resulting in a decoding error (revert without reason) - await expect(this.mock.$safeIncreaseAllowance(this.token, this.spender, 0n)).to.be.revertedWithoutReason(); - }); - - it('reverts on decreaseAllowance', async function () { - // Call to 'token.allowance' does not return any data, resulting in a decoding error (revert without reason) - await expect(this.mock.$safeDecreaseAllowance(this.token, this.spender, 0n)).to.be.revertedWithoutReason(); - }); - - it('reverts on forceApprove', async function () { - await expect(this.mock.$forceApprove(this.token, this.spender, 0n)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedOperation') - .withArgs(this.token); - }); - }); - - describe('with token that returns false on all calls', function () { - beforeEach(async function () { - this.token = this.erc20ReturnFalseMock; - }); - - it('reverts on transfer', async function () { - await expect(this.mock.$safeTransfer(this.token, this.receiver, 0n)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedOperation') - .withArgs(this.token); - }); - - it('reverts on transferFrom', async function () { - await expect(this.mock.$safeTransferFrom(this.token, this.mock, this.receiver, 0n)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedOperation') - .withArgs(this.token); - }); - - it('reverts on increaseAllowance', async function () { - await expect(this.mock.$safeIncreaseAllowance(this.token, this.spender, 0n)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedOperation') - .withArgs(this.token); - }); - - it('reverts on decreaseAllowance', async function () { - await expect(this.mock.$safeDecreaseAllowance(this.token, this.spender, 0n)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedOperation') - .withArgs(this.token); - }); - - it('reverts on forceApprove', async function () { - await expect(this.mock.$forceApprove(this.token, this.spender, 0n)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedOperation') - .withArgs(this.token); - }); - }); - - describe('with token that returns true on all calls', function () { - beforeEach(async function () { - this.token = this.erc20ReturnTrueMock; - }); - - shouldOnlyRevertOnErrors(); - }); - - describe('with token that returns no boolean values', function () { - beforeEach(async function () { - this.token = this.erc20NoReturnMock; - }); - - shouldOnlyRevertOnErrors(); - }); - - describe('with usdt approval behaviour', function () { - beforeEach(async function () { - this.token = this.erc20ForceApproveMock; - }); - - describe('with initial approval', function () { - beforeEach(async function () { - await this.token.$_approve(this.mock, this.spender, 100n); - }); - - it('safeIncreaseAllowance works', async function () { - await this.mock.$safeIncreaseAllowance(this.token, this.spender, 10n); - expect(await this.token.allowance(this.mock, this.spender)).to.equal(110n); - }); - - it('safeDecreaseAllowance works', async function () { - await this.mock.$safeDecreaseAllowance(this.token, this.spender, 10n); - expect(await this.token.allowance(this.mock, this.spender)).to.equal(90n); - }); - - it('forceApprove works', async function () { - await this.mock.$forceApprove(this.token, this.spender, 200n); - expect(await this.token.allowance(this.mock, this.spender)).to.equal(200n); - }); - }); - }); - - describe('with standard ERC1363', function () { - beforeEach(async function () { - this.token = this.erc1363Mock; - }); - - shouldOnlyRevertOnErrors(); - - describe('transferAndCall', function () { - it('cannot transferAndCall to an EOA directly', async function () { - await this.token.$_mint(this.owner, 100n); - - await expect(this.token.connect(this.owner).transferAndCall(this.receiver, value, ethers.Typed.bytes(data))) - .to.be.revertedWithCustomError(this.token, 'ERC1363InvalidReceiver') - .withArgs(this.receiver); - }); - - it('can transferAndCall to an EOA using helper', async function () { - await this.token.$_mint(this.mock, value); - - await expect(this.mock.$transferAndCallRelaxed(this.token, this.receiver, value, data)) - .to.emit(this.token, 'Transfer') - .withArgs(this.mock, this.receiver, value); - }); - - it('can transferAndCall to an ERC1363Receiver using helper', async function () { - await this.token.$_mint(this.mock, value); - - await expect(this.mock.$transferAndCallRelaxed(this.token, this.erc1363Receiver, value, data)) - .to.emit(this.token, 'Transfer') - .withArgs(this.mock, this.erc1363Receiver, value) - .to.emit(this.erc1363Receiver, 'Received') - .withArgs(this.mock, this.mock, value, data); - }); - }); - - describe('transferFromAndCall', function () { - it('can transferFromAndCall to an EOA using helper', async function () { - await this.token.$_mint(this.owner, value); - await this.token.$_approve(this.owner, this.mock, ethers.MaxUint256); - - await expect(this.mock.$transferFromAndCallRelaxed(this.token, this.owner, this.receiver, value, data)) - .to.emit(this.token, 'Transfer') - .withArgs(this.owner, this.receiver, value); - }); - - it('can transferFromAndCall to an ERC1363Receiver using helper', async function () { - await this.token.$_mint(this.owner, value); - await this.token.$_approve(this.owner, this.mock, ethers.MaxUint256); - - await expect(this.mock.$transferFromAndCallRelaxed(this.token, this.owner, this.erc1363Receiver, value, data)) - .to.emit(this.token, 'Transfer') - .withArgs(this.owner, this.erc1363Receiver, value) - .to.emit(this.erc1363Receiver, 'Received') - .withArgs(this.mock, this.owner, value, data); - }); - }); - - describe('approveAndCall', function () { - it('can approveAndCall to an EOA using helper', async function () { - await expect(this.mock.$approveAndCallRelaxed(this.token, this.receiver, value, data)) - .to.emit(this.token, 'Approval') - .withArgs(this.mock, this.receiver, value); - }); - - it('can approveAndCall to an ERC1363Spender using helper', async function () { - await expect(this.mock.$approveAndCallRelaxed(this.token, this.erc1363Spender, value, data)) - .to.emit(this.token, 'Approval') - .withArgs(this.mock, this.erc1363Spender, value) - .to.emit(this.erc1363Spender, 'Approved') - .withArgs(this.mock, value, data); - }); - }); - }); - - describe('with ERC1363 that returns false on all ERC20 calls', function () { - beforeEach(async function () { - this.token = this.erc1363ReturnFalseOnErc20Mock; - }); - - it('reverts on transferAndCallRelaxed', async function () { - await expect(this.mock.$transferAndCallRelaxed(this.token, this.erc1363Receiver, 0n, data)) - .to.be.revertedWithCustomError(this.token, 'ERC1363TransferFailed') - .withArgs(this.erc1363Receiver, 0n); - }); - - it('reverts on transferFromAndCallRelaxed', async function () { - await expect(this.mock.$transferFromAndCallRelaxed(this.token, this.mock, this.erc1363Receiver, 0n, data)) - .to.be.revertedWithCustomError(this.token, 'ERC1363TransferFromFailed') - .withArgs(this.mock, this.erc1363Receiver, 0n); - }); - - it('reverts on approveAndCallRelaxed', async function () { - await expect(this.mock.$approveAndCallRelaxed(this.token, this.erc1363Spender, 0n, data)) - .to.be.revertedWithCustomError(this.token, 'ERC1363ApproveFailed') - .withArgs(this.erc1363Spender, 0n); - }); - }); - - describe('with ERC1363 that returns false on all ERC1363 calls', function () { - beforeEach(async function () { - this.token = this.erc1363ReturnFalseMock; - }); - - it('reverts on transferAndCallRelaxed', async function () { - await expect(this.mock.$transferAndCallRelaxed(this.token, this.erc1363Receiver, 0n, data)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedOperation') - .withArgs(this.token); - }); - - it('reverts on transferFromAndCallRelaxed', async function () { - await expect(this.mock.$transferFromAndCallRelaxed(this.token, this.mock, this.erc1363Receiver, 0n, data)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedOperation') - .withArgs(this.token); - }); - - it('reverts on approveAndCallRelaxed', async function () { - await expect(this.mock.$approveAndCallRelaxed(this.token, this.erc1363Spender, 0n, data)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedOperation') - .withArgs(this.token); - }); - }); - - describe('with ERC1363 that returns no boolean values', function () { - beforeEach(async function () { - this.token = this.erc1363NoReturnMock; - }); - - it('reverts on transferAndCallRelaxed', async function () { - await expect( - this.mock.$transferAndCallRelaxed(this.token, this.erc1363Receiver, 0n, data), - ).to.be.revertedWithoutReason(); - }); - - it('reverts on transferFromAndCallRelaxed', async function () { - await expect( - this.mock.$transferFromAndCallRelaxed(this.token, this.mock, this.erc1363Receiver, 0n, data), - ).to.be.revertedWithoutReason(); - }); - - it('reverts on approveAndCallRelaxed', async function () { - await expect( - this.mock.$approveAndCallRelaxed(this.token, this.erc1363Spender, 0n, data), - ).to.be.revertedWithoutReason(); - }); - }); - - describe('with ERC1363 with usdt approval behaviour', function () { - beforeEach(async function () { - this.token = this.erc1363ForceApproveMock; - }); - - describe('without initial approval', function () { - it('approveAndCallRelaxed works when recipient is an EOA', async function () { - await this.mock.$approveAndCallRelaxed(this.token, this.spender, 10n, data); - expect(await this.token.allowance(this.mock, this.spender)).to.equal(10n); - }); - - it('approveAndCallRelaxed works when recipient is a contract', async function () { - await this.mock.$approveAndCallRelaxed(this.token, this.erc1363Spender, 10n, data); - expect(await this.token.allowance(this.mock, this.erc1363Spender)).to.equal(10n); - }); - }); - - describe('with initial approval', function () { - it('approveAndCallRelaxed works when recipient is an EOA', async function () { - await this.token.$_approve(this.mock, this.spender, 100n); - - await this.mock.$approveAndCallRelaxed(this.token, this.spender, 10n, data); - expect(await this.token.allowance(this.mock, this.spender)).to.equal(10n); - }); - - it('approveAndCallRelaxed reverts when recipient is a contract', async function () { - await this.token.$_approve(this.mock, this.erc1363Spender, 100n); - await expect(this.mock.$approveAndCallRelaxed(this.token, this.erc1363Spender, 10n, data)).to.be.revertedWith( - 'USDT approval failure', - ); - }); - }); - }); -}); - -function shouldOnlyRevertOnErrors() { - describe('transfers', function () { - beforeEach(async function () { - await this.token.$_mint(this.owner, 100n); - await this.token.$_mint(this.mock, 100n); - await this.token.$_approve(this.owner, this.mock, ethers.MaxUint256); - }); - - it("doesn't revert on transfer", async function () { - await expect(this.mock.$safeTransfer(this.token, this.receiver, 10n)) - .to.emit(this.token, 'Transfer') - .withArgs(this.mock, this.receiver, 10n); - }); - - it("doesn't revert on transferFrom", async function () { - await expect(this.mock.$safeTransferFrom(this.token, this.owner, this.receiver, 10n)) - .to.emit(this.token, 'Transfer') - .withArgs(this.owner, this.receiver, 10n); - }); - }); - - describe('approvals', function () { - describe('with zero allowance', function () { - beforeEach(async function () { - await this.token.$_approve(this.mock, this.spender, 0n); - }); - - it("doesn't revert when force approving a non-zero allowance", async function () { - await this.mock.$forceApprove(this.token, this.spender, 100n); - expect(await this.token.allowance(this.mock, this.spender)).to.equal(100n); - }); - - it("doesn't revert when force approving a zero allowance", async function () { - await this.mock.$forceApprove(this.token, this.spender, 0n); - expect(await this.token.allowance(this.mock, this.spender)).to.equal(0n); - }); - - it("doesn't revert when increasing the allowance", async function () { - await this.mock.$safeIncreaseAllowance(this.token, this.spender, 10n); - expect(await this.token.allowance(this.mock, this.spender)).to.equal(10n); - }); - - it('reverts when decreasing the allowance', async function () { - await expect(this.mock.$safeDecreaseAllowance(this.token, this.spender, 10n)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedDecreaseAllowance') - .withArgs(this.spender, 0n, 10n); - }); - }); - - describe('with non-zero allowance', function () { - beforeEach(async function () { - await this.token.$_approve(this.mock, this.spender, 100n); - }); - - it("doesn't revert when force approving a non-zero allowance", async function () { - await this.mock.$forceApprove(this.token, this.spender, 20n); - expect(await this.token.allowance(this.mock, this.spender)).to.equal(20n); - }); - - it("doesn't revert when force approving a zero allowance", async function () { - await this.mock.$forceApprove(this.token, this.spender, 0n); - expect(await this.token.allowance(this.mock, this.spender)).to.equal(0n); - }); - - it("doesn't revert when increasing the allowance", async function () { - await this.mock.$safeIncreaseAllowance(this.token, this.spender, 10n); - expect(await this.token.allowance(this.mock, this.spender)).to.equal(110n); - }); - - it("doesn't revert when decreasing the allowance to a positive value", async function () { - await this.mock.$safeDecreaseAllowance(this.token, this.spender, 50n); - expect(await this.token.allowance(this.mock, this.spender)).to.equal(50n); - }); - - it('reverts when decreasing the allowance to a negative value', async function () { - await expect(this.mock.$safeDecreaseAllowance(this.token, this.spender, 200n)) - .to.be.revertedWithCustomError(this.mock, 'SafeERC20FailedDecreaseAllowance') - .withArgs(this.spender, 100n, 200n); - }); - }); - }); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/ERC721.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/ERC721.behavior.js deleted file mode 100644 index b9dd80d6d1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/ERC721.behavior.js +++ /dev/null @@ -1,972 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); -const { anyValue } = require('@nomicfoundation/hardhat-chai-matchers/withArgs'); - -const { shouldSupportInterfaces } = require('../../utils/introspection/SupportsInterface.behavior'); -const { RevertType } = require('../../helpers/enums'); - -const firstTokenId = 5042n; -const secondTokenId = 79217n; -const nonExistentTokenId = 13n; -const fourthTokenId = 4n; -const baseURI = 'https://api.example.com/v1/'; - -const RECEIVER_MAGIC_VALUE = '0x150b7a02'; - -function shouldBehaveLikeERC721() { - beforeEach(async function () { - const [owner, newOwner, approved, operator, other] = this.accounts; - Object.assign(this, { owner, newOwner, approved, operator, other }); - }); - - shouldSupportInterfaces(['ERC721']); - - describe('with minted tokens', function () { - beforeEach(async function () { - await this.token.$_mint(this.owner, firstTokenId); - await this.token.$_mint(this.owner, secondTokenId); - this.to = this.other; - }); - - describe('balanceOf', function () { - describe('when the given address owns some tokens', function () { - it('returns the amount of tokens owned by the given address', async function () { - expect(await this.token.balanceOf(this.owner)).to.equal(2n); - }); - }); - - describe('when the given address does not own any tokens', function () { - it('returns 0', async function () { - expect(await this.token.balanceOf(this.other)).to.equal(0n); - }); - }); - - describe('when querying the zero address', function () { - it('throws', async function () { - await expect(this.token.balanceOf(ethers.ZeroAddress)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidOwner') - .withArgs(ethers.ZeroAddress); - }); - }); - }); - - describe('ownerOf', function () { - describe('when the given token ID was tracked by this token', function () { - const tokenId = firstTokenId; - - it('returns the owner of the given token ID', async function () { - expect(await this.token.ownerOf(tokenId)).to.equal(this.owner); - }); - }); - - describe('when the given token ID was not tracked by this token', function () { - const tokenId = nonExistentTokenId; - - it('reverts', async function () { - await expect(this.token.ownerOf(tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(tokenId); - }); - }); - }); - - describe('transfers', function () { - const tokenId = firstTokenId; - const data = '0x42'; - - beforeEach(async function () { - await this.token.connect(this.owner).approve(this.approved, tokenId); - await this.token.connect(this.owner).setApprovalForAll(this.operator, true); - }); - - const transferWasSuccessful = () => { - it('transfers the ownership of the given token ID to the given address', async function () { - await this.tx(); - expect(await this.token.ownerOf(tokenId)).to.equal(this.to); - }); - - it('emits a Transfer event', async function () { - await expect(this.tx()).to.emit(this.token, 'Transfer').withArgs(this.owner, this.to, tokenId); - }); - - it('clears the approval for the token ID with no event', async function () { - await expect(this.tx()).to.not.emit(this.token, 'Approval'); - - expect(await this.token.getApproved(tokenId)).to.equal(ethers.ZeroAddress); - }); - - it('adjusts owners balances', async function () { - const balanceBefore = await this.token.balanceOf(this.owner); - await this.tx(); - expect(await this.token.balanceOf(this.owner)).to.equal(balanceBefore - 1n); - }); - - it('adjusts owners tokens by index', async function () { - if (!this.token.tokenOfOwnerByIndex) return; - - await this.tx(); - expect(await this.token.tokenOfOwnerByIndex(this.to, 0n)).to.equal(tokenId); - expect(await this.token.tokenOfOwnerByIndex(this.owner, 0n)).to.not.equal(tokenId); - }); - }; - - const shouldTransferTokensByUsers = function (fragment, opts = {}) { - describe('when called by the owner', function () { - beforeEach(async function () { - this.tx = () => - this.token.connect(this.owner)[fragment](this.owner, this.to, tokenId, ...(opts.extra ?? [])); - }); - transferWasSuccessful(); - }); - - describe('when called by the approved individual', function () { - beforeEach(async function () { - this.tx = () => - this.token.connect(this.approved)[fragment](this.owner, this.to, tokenId, ...(opts.extra ?? [])); - }); - transferWasSuccessful(); - }); - - describe('when called by the operator', function () { - beforeEach(async function () { - this.tx = () => - this.token.connect(this.operator)[fragment](this.owner, this.to, tokenId, ...(opts.extra ?? [])); - }); - transferWasSuccessful(); - }); - - describe('when called by the owner without an approved user', function () { - beforeEach(async function () { - await this.token.connect(this.owner).approve(ethers.ZeroAddress, tokenId); - this.tx = () => - this.token.connect(this.operator)[fragment](this.owner, this.to, tokenId, ...(opts.extra ?? [])); - }); - transferWasSuccessful(); - }); - - describe('when sent to the owner', function () { - beforeEach(async function () { - this.tx = () => - this.token.connect(this.owner)[fragment](this.owner, this.owner, tokenId, ...(opts.extra ?? [])); - }); - - it('keeps ownership of the token', async function () { - await this.tx(); - expect(await this.token.ownerOf(tokenId)).to.equal(this.owner); - }); - - it('clears the approval for the token ID', async function () { - await this.tx(); - expect(await this.token.getApproved(tokenId)).to.equal(ethers.ZeroAddress); - }); - - it('emits only a transfer event', async function () { - await expect(this.tx()).to.emit(this.token, 'Transfer').withArgs(this.owner, this.owner, tokenId); - }); - - it('keeps the owner balance', async function () { - const balanceBefore = await this.token.balanceOf(this.owner); - await this.tx(); - expect(await this.token.balanceOf(this.owner)).to.equal(balanceBefore); - }); - - it('keeps same tokens by index', async function () { - if (!this.token.tokenOfOwnerByIndex) return; - - expect(await Promise.all([0n, 1n].map(i => this.token.tokenOfOwnerByIndex(this.owner, i)))).to.have.members( - [firstTokenId, secondTokenId], - ); - }); - }); - - describe('when the address of the previous owner is incorrect', function () { - it('reverts', async function () { - await expect( - this.token.connect(this.owner)[fragment](this.other, this.other, tokenId, ...(opts.extra ?? [])), - ) - .to.be.revertedWithCustomError(this.token, 'ERC721IncorrectOwner') - .withArgs(this.other, tokenId, this.owner); - }); - }); - - describe('when the sender is not authorized for the token id', function () { - if (opts.unrestricted) { - it('does not revert', async function () { - await this.token.connect(this.other)[fragment](this.owner, this.other, tokenId, ...(opts.extra ?? [])); - }); - } else { - it('reverts', async function () { - await expect( - this.token.connect(this.other)[fragment](this.owner, this.other, tokenId, ...(opts.extra ?? [])), - ) - .to.be.revertedWithCustomError(this.token, 'ERC721InsufficientApproval') - .withArgs(this.other, tokenId); - }); - } - }); - - describe('when the given token ID does not exist', function () { - it('reverts', async function () { - await expect( - this.token - .connect(this.owner) - [fragment](this.owner, this.other, nonExistentTokenId, ...(opts.extra ?? [])), - ) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(nonExistentTokenId); - }); - }); - - describe('when the address to transfer the token to is the zero address', function () { - it('reverts', async function () { - await expect( - this.token.connect(this.owner)[fragment](this.owner, ethers.ZeroAddress, tokenId, ...(opts.extra ?? [])), - ) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidReceiver') - .withArgs(ethers.ZeroAddress); - }); - }); - }; - - const shouldTransferSafely = function (fragment, data, opts = {}) { - // sanity - it('function exists', async function () { - expect(this.token.interface.hasFunction(fragment)).to.be.true; - }); - - describe('to a user account', function () { - shouldTransferTokensByUsers(fragment, opts); - }); - - describe('to a valid receiver contract', function () { - beforeEach(async function () { - this.to = await ethers.deployContract('ERC721ReceiverMock', [RECEIVER_MAGIC_VALUE, RevertType.None]); - }); - - shouldTransferTokensByUsers(fragment, opts); - - it('calls onERC721Received', async function () { - await expect(this.token.connect(this.owner)[fragment](this.owner, this.to, tokenId, ...(opts.extra ?? []))) - .to.emit(this.to, 'Received') - .withArgs(this.owner, this.owner, tokenId, data, anyValue); - }); - - it('calls onERC721Received from approved', async function () { - await expect( - this.token.connect(this.approved)[fragment](this.owner, this.to, tokenId, ...(opts.extra ?? [])), - ) - .to.emit(this.to, 'Received') - .withArgs(this.approved, this.owner, tokenId, data, anyValue); - }); - - describe('with an invalid token id', function () { - it('reverts', async function () { - await expect( - this.token - .connect(this.approved) - [fragment](this.owner, this.to, nonExistentTokenId, ...(opts.extra ?? [])), - ) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(nonExistentTokenId); - }); - }); - }); - }; - - for (const { fnName, opts } of [ - { fnName: 'transferFrom', opts: {} }, - { fnName: '$_transfer', opts: { unrestricted: true } }, - ]) { - describe(`via ${fnName}`, function () { - shouldTransferTokensByUsers(fnName, opts); - }); - } - - for (const { fnName, opts } of [ - { fnName: 'safeTransferFrom', opts: {} }, - { fnName: '$_safeTransfer', opts: { unrestricted: true } }, - ]) { - describe(`via ${fnName}`, function () { - describe('with data', function () { - shouldTransferSafely(fnName, data, { ...opts, extra: [ethers.Typed.bytes(data)] }); - }); - - describe('without data', function () { - shouldTransferSafely(fnName, '0x', opts); - }); - - describe('to a receiver contract returning unexpected value', function () { - it('reverts', async function () { - const invalidReceiver = await ethers.deployContract('ERC721ReceiverMock', [ - '0xdeadbeef', - RevertType.None, - ]); - - await expect(this.token.connect(this.owner)[fnName](this.owner, invalidReceiver, tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidReceiver') - .withArgs(invalidReceiver); - }); - }); - - describe('to a receiver contract that reverts with message', function () { - it('reverts', async function () { - const revertingReceiver = await ethers.deployContract('ERC721ReceiverMock', [ - RECEIVER_MAGIC_VALUE, - RevertType.RevertWithMessage, - ]); - - await expect( - this.token.connect(this.owner)[fnName](this.owner, revertingReceiver, tokenId), - ).to.be.revertedWith('ERC721ReceiverMock: reverting'); - }); - }); - - describe('to a receiver contract that reverts without message', function () { - it('reverts', async function () { - const revertingReceiver = await ethers.deployContract('ERC721ReceiverMock', [ - RECEIVER_MAGIC_VALUE, - RevertType.RevertWithoutMessage, - ]); - - await expect(this.token.connect(this.owner)[fnName](this.owner, revertingReceiver, tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidReceiver') - .withArgs(revertingReceiver); - }); - }); - - describe('to a receiver contract that reverts with custom error', function () { - it('reverts', async function () { - const revertingReceiver = await ethers.deployContract('ERC721ReceiverMock', [ - RECEIVER_MAGIC_VALUE, - RevertType.RevertWithCustomError, - ]); - - await expect(this.token.connect(this.owner)[fnName](this.owner, revertingReceiver, tokenId)) - .to.be.revertedWithCustomError(revertingReceiver, 'CustomError') - .withArgs(RECEIVER_MAGIC_VALUE); - }); - }); - - describe('to a receiver contract that panics', function () { - it('reverts', async function () { - const revertingReceiver = await ethers.deployContract('ERC721ReceiverMock', [ - RECEIVER_MAGIC_VALUE, - RevertType.Panic, - ]); - - await expect( - this.token.connect(this.owner)[fnName](this.owner, revertingReceiver, tokenId), - ).to.be.revertedWithPanic(PANIC_CODES.DIVISION_BY_ZERO); - }); - }); - - describe('to a contract that does not implement the required function', function () { - it('reverts', async function () { - const nonReceiver = await ethers.deployContract('CallReceiverMock'); - - await expect(this.token.connect(this.owner)[fnName](this.owner, nonReceiver, tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidReceiver') - .withArgs(nonReceiver); - }); - }); - }); - } - }); - - describe('safe mint', function () { - const tokenId = fourthTokenId; - const data = '0x42'; - - describe('via safeMint', function () { - // regular minting is tested in ERC721Mintable.test.js and others - it('calls onERC721Received — with data', async function () { - const receiver = await ethers.deployContract('ERC721ReceiverMock', [RECEIVER_MAGIC_VALUE, RevertType.None]); - - await expect(await this.token.$_safeMint(receiver, tokenId, ethers.Typed.bytes(data))) - .to.emit(receiver, 'Received') - .withArgs(anyValue, ethers.ZeroAddress, tokenId, data, anyValue); - }); - - it('calls onERC721Received — without data', async function () { - const receiver = await ethers.deployContract('ERC721ReceiverMock', [RECEIVER_MAGIC_VALUE, RevertType.None]); - - await expect(await this.token.$_safeMint(receiver, tokenId)) - .to.emit(receiver, 'Received') - .withArgs(anyValue, ethers.ZeroAddress, tokenId, '0x', anyValue); - }); - - describe('to a receiver contract returning unexpected value', function () { - it('reverts', async function () { - const invalidReceiver = await ethers.deployContract('ERC721ReceiverMock', ['0xdeadbeef', RevertType.None]); - - await expect(this.token.$_safeMint(invalidReceiver, tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidReceiver') - .withArgs(invalidReceiver); - }); - }); - - describe('to a receiver contract that reverts with message', function () { - it('reverts', async function () { - const revertingReceiver = await ethers.deployContract('ERC721ReceiverMock', [ - RECEIVER_MAGIC_VALUE, - RevertType.RevertWithMessage, - ]); - - await expect(this.token.$_safeMint(revertingReceiver, tokenId)).to.be.revertedWith( - 'ERC721ReceiverMock: reverting', - ); - }); - }); - - describe('to a receiver contract that reverts without message', function () { - it('reverts', async function () { - const revertingReceiver = await ethers.deployContract('ERC721ReceiverMock', [ - RECEIVER_MAGIC_VALUE, - RevertType.RevertWithoutMessage, - ]); - - await expect(this.token.$_safeMint(revertingReceiver, tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidReceiver') - .withArgs(revertingReceiver); - }); - }); - - describe('to a receiver contract that reverts with custom error', function () { - it('reverts', async function () { - const revertingReceiver = await ethers.deployContract('ERC721ReceiverMock', [ - RECEIVER_MAGIC_VALUE, - RevertType.RevertWithCustomError, - ]); - - await expect(this.token.$_safeMint(revertingReceiver, tokenId)) - .to.be.revertedWithCustomError(revertingReceiver, 'CustomError') - .withArgs(RECEIVER_MAGIC_VALUE); - }); - }); - - describe('to a receiver contract that panics', function () { - it('reverts', async function () { - const revertingReceiver = await ethers.deployContract('ERC721ReceiverMock', [ - RECEIVER_MAGIC_VALUE, - RevertType.Panic, - ]); - - await expect(this.token.$_safeMint(revertingReceiver, tokenId)).to.be.revertedWithPanic( - PANIC_CODES.DIVISION_BY_ZERO, - ); - }); - }); - - describe('to a contract that does not implement the required function', function () { - it('reverts', async function () { - const nonReceiver = await ethers.deployContract('CallReceiverMock'); - - await expect(this.token.$_safeMint(nonReceiver, tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidReceiver') - .withArgs(nonReceiver); - }); - }); - }); - }); - - describe('approve', function () { - const tokenId = firstTokenId; - - const itClearsApproval = function () { - it('clears approval for the token', async function () { - expect(await this.token.getApproved(tokenId)).to.equal(ethers.ZeroAddress); - }); - }; - - const itApproves = function () { - it('sets the approval for the target address', async function () { - expect(await this.token.getApproved(tokenId)).to.equal(this.approved ?? this.approved); - }); - }; - - const itEmitsApprovalEvent = function () { - it('emits an approval event', async function () { - await expect(this.tx) - .to.emit(this.token, 'Approval') - .withArgs(this.owner, this.approved ?? this.approved, tokenId); - }); - }; - - describe('when clearing approval', function () { - describe('when there was no prior approval', function () { - beforeEach(async function () { - this.approved = ethers.ZeroAddress; - this.tx = await this.token.connect(this.owner).approve(this.approved, tokenId); - }); - - itClearsApproval(); - itEmitsApprovalEvent(); - }); - - describe('when there was a prior approval', function () { - beforeEach(async function () { - await this.token.connect(this.owner).approve(this.other, tokenId); - this.approved = ethers.ZeroAddress; - this.tx = await this.token.connect(this.owner).approve(this.approved, tokenId); - }); - - itClearsApproval(); - itEmitsApprovalEvent(); - }); - }); - - describe('when approving a non-zero address', function () { - describe('when there was no prior approval', function () { - beforeEach(async function () { - this.tx = await this.token.connect(this.owner).approve(this.approved, tokenId); - }); - - itApproves(); - itEmitsApprovalEvent(); - }); - - describe('when there was a prior approval to the same address', function () { - beforeEach(async function () { - await this.token.connect(this.owner).approve(this.approved, tokenId); - this.tx = await this.token.connect(this.owner).approve(this.approved, tokenId); - }); - - itApproves(); - itEmitsApprovalEvent(); - }); - - describe('when there was a prior approval to a different address', function () { - beforeEach(async function () { - await this.token.connect(this.owner).approve(this.other, tokenId); - this.tx = await this.token.connect(this.owner).approve(this.approved, tokenId); - }); - - itApproves(); - itEmitsApprovalEvent(); - }); - }); - - describe('when the sender does not own the given token ID', function () { - it('reverts', async function () { - await expect(this.token.connect(this.other).approve(this.approved, tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidApprover') - .withArgs(this.other); - }); - }); - - describe('when the sender is approved for the given token ID', function () { - it('reverts', async function () { - await this.token.connect(this.owner).approve(this.approved, tokenId); - - await expect(this.token.connect(this.approved).approve(this.other, tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidApprover') - .withArgs(this.approved); - }); - }); - - describe('when the sender is an operator', function () { - beforeEach(async function () { - await this.token.connect(this.owner).setApprovalForAll(this.operator, true); - - this.tx = await this.token.connect(this.operator).approve(this.approved, tokenId); - }); - - itApproves(); - itEmitsApprovalEvent(); - }); - - describe('when the given token ID does not exist', function () { - it('reverts', async function () { - await expect(this.token.connect(this.operator).approve(this.approved, nonExistentTokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(nonExistentTokenId); - }); - }); - }); - - describe('setApprovalForAll', function () { - describe('when the operator willing to approve is not the owner', function () { - describe('when there is no operator approval set by the sender', function () { - it('approves the operator', async function () { - await this.token.connect(this.owner).setApprovalForAll(this.operator, true); - - expect(await this.token.isApprovedForAll(this.owner, this.operator)).to.be.true; - }); - - it('emits an approval event', async function () { - await expect(this.token.connect(this.owner).setApprovalForAll(this.operator, true)) - .to.emit(this.token, 'ApprovalForAll') - .withArgs(this.owner, this.operator, true); - }); - }); - - describe('when the operator was set as not approved', function () { - beforeEach(async function () { - await this.token.connect(this.owner).setApprovalForAll(this.operator, false); - }); - - it('approves the operator', async function () { - await this.token.connect(this.owner).setApprovalForAll(this.operator, true); - - expect(await this.token.isApprovedForAll(this.owner, this.operator)).to.be.true; - }); - - it('emits an approval event', async function () { - await expect(this.token.connect(this.owner).setApprovalForAll(this.operator, true)) - .to.emit(this.token, 'ApprovalForAll') - .withArgs(this.owner, this.operator, true); - }); - - it('can unset the operator approval', async function () { - await this.token.connect(this.owner).setApprovalForAll(this.operator, false); - - expect(await this.token.isApprovedForAll(this.owner, this.operator)).to.be.false; - }); - }); - - describe('when the operator was already approved', function () { - beforeEach(async function () { - await this.token.connect(this.owner).setApprovalForAll(this.operator, true); - }); - - it('keeps the approval to the given address', async function () { - await this.token.connect(this.owner).setApprovalForAll(this.operator, true); - - expect(await this.token.isApprovedForAll(this.owner, this.operator)).to.be.true; - }); - - it('emits an approval event', async function () { - await expect(this.token.connect(this.owner).setApprovalForAll(this.operator, true)) - .to.emit(this.token, 'ApprovalForAll') - .withArgs(this.owner, this.operator, true); - }); - }); - }); - - describe('when the operator is address zero', function () { - it('reverts', async function () { - await expect(this.token.connect(this.owner).setApprovalForAll(ethers.ZeroAddress, true)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidOperator') - .withArgs(ethers.ZeroAddress); - }); - }); - }); - - describe('getApproved', function () { - describe('when token is not minted', function () { - it('reverts', async function () { - await expect(this.token.getApproved(nonExistentTokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(nonExistentTokenId); - }); - }); - - describe('when token has been minted ', function () { - it('should return the zero address', async function () { - expect(await this.token.getApproved(firstTokenId)).to.equal(ethers.ZeroAddress); - }); - - describe('when account has been approved', function () { - beforeEach(async function () { - await this.token.connect(this.owner).approve(this.approved, firstTokenId); - }); - - it('returns approved account', async function () { - expect(await this.token.getApproved(firstTokenId)).to.equal(this.approved); - }); - }); - }); - }); - }); - - describe('_mint(address, uint256)', function () { - it('reverts with a null destination address', async function () { - await expect(this.token.$_mint(ethers.ZeroAddress, firstTokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidReceiver') - .withArgs(ethers.ZeroAddress); - }); - - describe('with minted token', function () { - beforeEach(async function () { - this.tx = await this.token.$_mint(this.owner, firstTokenId); - }); - - it('emits a Transfer event', async function () { - await expect(this.tx).to.emit(this.token, 'Transfer').withArgs(ethers.ZeroAddress, this.owner, firstTokenId); - }); - - it('creates the token', async function () { - expect(await this.token.balanceOf(this.owner)).to.equal(1n); - expect(await this.token.ownerOf(firstTokenId)).to.equal(this.owner); - }); - - it('reverts when adding a token id that already exists', async function () { - await expect(this.token.$_mint(this.owner, firstTokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidSender') - .withArgs(ethers.ZeroAddress); - }); - }); - }); - - describe('_burn', function () { - it('reverts when burning a non-existent token id', async function () { - await expect(this.token.$_burn(nonExistentTokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(nonExistentTokenId); - }); - - describe('with minted tokens', function () { - beforeEach(async function () { - await this.token.$_mint(this.owner, firstTokenId); - await this.token.$_mint(this.owner, secondTokenId); - }); - - describe('with burnt token', function () { - beforeEach(async function () { - this.tx = await this.token.$_burn(firstTokenId); - }); - - it('emits a Transfer event', async function () { - await expect(this.tx).to.emit(this.token, 'Transfer').withArgs(this.owner, ethers.ZeroAddress, firstTokenId); - }); - - it('deletes the token', async function () { - expect(await this.token.balanceOf(this.owner)).to.equal(1n); - await expect(this.token.ownerOf(firstTokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(firstTokenId); - }); - - it('reverts when burning a token id that has been deleted', async function () { - await expect(this.token.$_burn(firstTokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(firstTokenId); - }); - }); - }); - }); -} - -function shouldBehaveLikeERC721Enumerable() { - beforeEach(async function () { - const [owner, newOwner, approved, operator, other] = this.accounts; - Object.assign(this, { owner, newOwner, approved, operator, other }); - }); - - shouldSupportInterfaces(['ERC721Enumerable']); - - describe('with minted tokens', function () { - beforeEach(async function () { - await this.token.$_mint(this.owner, firstTokenId); - await this.token.$_mint(this.owner, secondTokenId); - this.to = this.other; - }); - - describe('totalSupply', function () { - it('returns total token supply', async function () { - expect(await this.token.totalSupply()).to.equal(2n); - }); - }); - - describe('tokenOfOwnerByIndex', function () { - describe('when the given index is lower than the amount of tokens owned by the given address', function () { - it('returns the token ID placed at the given index', async function () { - expect(await this.token.tokenOfOwnerByIndex(this.owner, 0n)).to.equal(firstTokenId); - }); - }); - - describe('when the index is greater than or equal to the total tokens owned by the given address', function () { - it('reverts', async function () { - await expect(this.token.tokenOfOwnerByIndex(this.owner, 2n)) - .to.be.revertedWithCustomError(this.token, 'ERC721OutOfBoundsIndex') - .withArgs(this.owner, 2n); - }); - }); - - describe('when the given address does not own any token', function () { - it('reverts', async function () { - await expect(this.token.tokenOfOwnerByIndex(this.other, 0n)) - .to.be.revertedWithCustomError(this.token, 'ERC721OutOfBoundsIndex') - .withArgs(this.other, 0n); - }); - }); - - describe('after transferring all tokens to another user', function () { - beforeEach(async function () { - await this.token.connect(this.owner).transferFrom(this.owner, this.other, firstTokenId); - await this.token.connect(this.owner).transferFrom(this.owner, this.other, secondTokenId); - }); - - it('returns correct token IDs for target', async function () { - expect(await this.token.balanceOf(this.other)).to.equal(2n); - - expect(await Promise.all([0n, 1n].map(i => this.token.tokenOfOwnerByIndex(this.other, i)))).to.have.members([ - firstTokenId, - secondTokenId, - ]); - }); - - it('returns empty collection for original owner', async function () { - expect(await this.token.balanceOf(this.owner)).to.equal(0n); - await expect(this.token.tokenOfOwnerByIndex(this.owner, 0n)) - .to.be.revertedWithCustomError(this.token, 'ERC721OutOfBoundsIndex') - .withArgs(this.owner, 0n); - }); - }); - }); - - describe('tokenByIndex', function () { - it('returns all tokens', async function () { - expect(await Promise.all([0n, 1n].map(i => this.token.tokenByIndex(i)))).to.have.members([ - firstTokenId, - secondTokenId, - ]); - }); - - it('reverts if index is greater than supply', async function () { - await expect(this.token.tokenByIndex(2n)) - .to.be.revertedWithCustomError(this.token, 'ERC721OutOfBoundsIndex') - .withArgs(ethers.ZeroAddress, 2n); - }); - - for (const tokenId of [firstTokenId, secondTokenId]) { - it(`returns all tokens after burning token ${tokenId} and minting new tokens`, async function () { - const newTokenId = 300n; - const anotherNewTokenId = 400n; - - await this.token.$_burn(tokenId); - await this.token.$_mint(this.newOwner, newTokenId); - await this.token.$_mint(this.newOwner, anotherNewTokenId); - - expect(await this.token.totalSupply()).to.equal(3n); - - expect(await Promise.all([0n, 1n, 2n].map(i => this.token.tokenByIndex(i)))) - .to.have.members([firstTokenId, secondTokenId, newTokenId, anotherNewTokenId].filter(x => x !== tokenId)) - .to.not.include(tokenId); - }); - } - }); - }); - - describe('_mint(address, uint256)', function () { - it('reverts with a null destination address', async function () { - await expect(this.token.$_mint(ethers.ZeroAddress, firstTokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidReceiver') - .withArgs(ethers.ZeroAddress); - }); - - describe('with minted token', function () { - beforeEach(async function () { - await this.token.$_mint(this.owner, firstTokenId); - }); - - it('adjusts owner tokens by index', async function () { - expect(await this.token.tokenOfOwnerByIndex(this.owner, 0n)).to.equal(firstTokenId); - }); - - it('adjusts all tokens list', async function () { - expect(await this.token.tokenByIndex(0n)).to.equal(firstTokenId); - }); - }); - }); - - describe('_burn', function () { - it('reverts when burning a non-existent token id', async function () { - await expect(this.token.$_burn(firstTokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(firstTokenId); - }); - - describe('with minted tokens', function () { - beforeEach(async function () { - await this.token.$_mint(this.owner, firstTokenId); - await this.token.$_mint(this.owner, secondTokenId); - }); - - describe('with burnt token', function () { - beforeEach(async function () { - await this.token.$_burn(firstTokenId); - }); - - it('removes that token from the token list of the owner', async function () { - expect(await this.token.tokenOfOwnerByIndex(this.owner, 0n)).to.equal(secondTokenId); - }); - - it('adjusts all tokens list', async function () { - expect(await this.token.tokenByIndex(0n)).to.equal(secondTokenId); - }); - - it('burns all tokens', async function () { - await this.token.$_burn(secondTokenId); - expect(await this.token.totalSupply()).to.equal(0n); - - await expect(this.token.tokenByIndex(0n)) - .to.be.revertedWithCustomError(this.token, 'ERC721OutOfBoundsIndex') - .withArgs(ethers.ZeroAddress, 0n); - }); - }); - }); - }); -} - -function shouldBehaveLikeERC721Metadata(name, symbol) { - shouldSupportInterfaces(['ERC721Metadata']); - - describe('metadata', function () { - it('has a name', async function () { - expect(await this.token.name()).to.equal(name); - }); - - it('has a symbol', async function () { - expect(await this.token.symbol()).to.equal(symbol); - }); - - describe('token URI', function () { - beforeEach(async function () { - await this.token.$_mint(this.owner, firstTokenId); - }); - - it('return empty string by default', async function () { - expect(await this.token.tokenURI(firstTokenId)).to.equal(''); - }); - - it('reverts when queried for non existent token id', async function () { - await expect(this.token.tokenURI(nonExistentTokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(nonExistentTokenId); - }); - - describe('base URI', function () { - beforeEach(function () { - if (!this.token.interface.hasFunction('setBaseURI')) { - this.skip(); - } - }); - - it('base URI can be set', async function () { - await this.token.setBaseURI(baseURI); - expect(await this.token.baseURI()).to.equal(baseURI); - }); - - it('base URI is added as a prefix to the token URI', async function () { - await this.token.setBaseURI(baseURI); - expect(await this.token.tokenURI(firstTokenId)).to.equal(baseURI + firstTokenId.toString()); - }); - - it('token URI can be changed by changing the base URI', async function () { - await this.token.setBaseURI(baseURI); - const newBaseURI = 'https://api.example.com/v2/'; - await this.token.setBaseURI(newBaseURI); - expect(await this.token.tokenURI(firstTokenId)).to.equal(newBaseURI + firstTokenId.toString()); - }); - }); - }); - }); -} - -module.exports = { - shouldBehaveLikeERC721, - shouldBehaveLikeERC721Enumerable, - shouldBehaveLikeERC721Metadata, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/ERC721.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/ERC721.test.js deleted file mode 100644 index 1454cb057c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/ERC721.test.js +++ /dev/null @@ -1,23 +0,0 @@ -const { ethers } = require('hardhat'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { shouldBehaveLikeERC721, shouldBehaveLikeERC721Metadata } = require('./ERC721.behavior'); - -const name = 'Non Fungible Token'; -const symbol = 'NFT'; - -async function fixture() { - return { - accounts: await ethers.getSigners(), - token: await ethers.deployContract('$ERC721', [name, symbol]), - }; -} - -describe('ERC721', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeERC721(); - shouldBehaveLikeERC721Metadata(name, symbol); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/ERC721Enumerable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/ERC721Enumerable.test.js deleted file mode 100644 index a3bdea73f5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/ERC721Enumerable.test.js +++ /dev/null @@ -1,28 +0,0 @@ -const { ethers } = require('hardhat'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { - shouldBehaveLikeERC721, - shouldBehaveLikeERC721Metadata, - shouldBehaveLikeERC721Enumerable, -} = require('./ERC721.behavior'); - -const name = 'Non Fungible Token'; -const symbol = 'NFT'; - -async function fixture() { - return { - accounts: await ethers.getSigners(), - token: await ethers.deployContract('$ERC721Enumerable', [name, symbol]), - }; -} - -describe('ERC721', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeERC721(); - shouldBehaveLikeERC721Metadata(name, symbol); - shouldBehaveLikeERC721Enumerable(); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Burnable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Burnable.test.js deleted file mode 100644 index d6f0b80c4f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Burnable.test.js +++ /dev/null @@ -1,77 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const name = 'Non Fungible Token'; -const symbol = 'NFT'; -const tokenId = 1n; -const otherTokenId = 2n; -const unknownTokenId = 3n; - -async function fixture() { - const [owner, approved, another] = await ethers.getSigners(); - const token = await ethers.deployContract('$ERC721Burnable', [name, symbol]); - return { owner, approved, another, token }; -} - -describe('ERC721Burnable', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('like a burnable ERC721', function () { - beforeEach(async function () { - await this.token.$_mint(this.owner, tokenId); - await this.token.$_mint(this.owner, otherTokenId); - }); - - describe('burn', function () { - describe('when successful', function () { - it('emits a burn event, burns the given token ID and adjusts the balance of the owner', async function () { - const balanceBefore = await this.token.balanceOf(this.owner); - - await expect(this.token.connect(this.owner).burn(tokenId)) - .to.emit(this.token, 'Transfer') - .withArgs(this.owner, ethers.ZeroAddress, tokenId); - - await expect(this.token.ownerOf(tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(tokenId); - - expect(await this.token.balanceOf(this.owner)).to.equal(balanceBefore - 1n); - }); - }); - - describe('when there is a previous approval burned', function () { - beforeEach(async function () { - await this.token.connect(this.owner).approve(this.approved, tokenId); - await this.token.connect(this.owner).burn(tokenId); - }); - - describe('getApproved', function () { - it('reverts', async function () { - await expect(this.token.getApproved(tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(tokenId); - }); - }); - }); - - describe('when there is no previous approval burned', function () { - it('reverts', async function () { - await expect(this.token.connect(this.another).burn(tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InsufficientApproval') - .withArgs(this.another, tokenId); - }); - }); - - describe('when the given token ID was not tracked by this contract', function () { - it('reverts', async function () { - await expect(this.token.connect(this.owner).burn(unknownTokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(unknownTokenId); - }); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Consecutive.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Consecutive.t.sol deleted file mode 100644 index eca15e717e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Consecutive.t.sol +++ /dev/null @@ -1,181 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -// solhint-disable func-name-mixedcase - -import {ERC721} from "@openzeppelin/contracts/token/ERC721/ERC721.sol"; -import {ERC721Consecutive} from "@openzeppelin/contracts/token/ERC721/extensions/ERC721Consecutive.sol"; -import {Test, StdUtils} from "forge-std/Test.sol"; - -function toSingleton(address account) pure returns (address[] memory) { - address[] memory accounts = new address[](1); - accounts[0] = account; - return accounts; -} - -contract ERC721ConsecutiveTarget is StdUtils, ERC721Consecutive { - uint96 private immutable _offset; - uint256 public totalMinted = 0; - - constructor(address[] memory receivers, uint256[] memory batches, uint256 startingId) ERC721("", "") { - _offset = uint96(startingId); - for (uint256 i = 0; i < batches.length; i++) { - address receiver = receivers[i % receivers.length]; - uint96 batchSize = uint96(bound(batches[i], 0, _maxBatchSize())); - _mintConsecutive(receiver, batchSize); - totalMinted += batchSize; - } - } - - function burn(uint256 tokenId) public { - _burn(tokenId); - } - - function _firstConsecutiveId() internal view virtual override returns (uint96) { - return _offset; - } -} - -contract ERC721ConsecutiveTest is Test { - function test_balance(address receiver, uint256[] calldata batches, uint96 startingId) public { - vm.assume(receiver != address(0)); - - uint256 startingTokenId = bound(startingId, 0, 5000); - - ERC721ConsecutiveTarget token = new ERC721ConsecutiveTarget(toSingleton(receiver), batches, startingTokenId); - - assertEq(token.balanceOf(receiver), token.totalMinted()); - } - - function test_ownership( - address receiver, - uint256[] calldata batches, - uint256[2] calldata unboundedTokenId, - uint96 startingId - ) public { - vm.assume(receiver != address(0)); - - uint256 startingTokenId = bound(startingId, 0, 5000); - - ERC721ConsecutiveTarget token = new ERC721ConsecutiveTarget(toSingleton(receiver), batches, startingTokenId); - - if (token.totalMinted() > 0) { - uint256 validTokenId = bound( - unboundedTokenId[0], - startingTokenId, - startingTokenId + token.totalMinted() - 1 - ); - assertEq(token.ownerOf(validTokenId), receiver); - } - - uint256 invalidTokenId = bound( - unboundedTokenId[1], - startingTokenId + token.totalMinted(), - startingTokenId + token.totalMinted() + 1 - ); - vm.expectRevert(); - token.ownerOf(invalidTokenId); - } - - function test_burn( - address receiver, - uint256[] calldata batches, - uint256 unboundedTokenId, - uint96 startingId - ) public { - vm.assume(receiver != address(0)); - - uint256 startingTokenId = bound(startingId, 0, 5000); - - ERC721ConsecutiveTarget token = new ERC721ConsecutiveTarget(toSingleton(receiver), batches, startingTokenId); - - // only test if we minted at least one token - uint256 supply = token.totalMinted(); - vm.assume(supply > 0); - - // burn a token in [0; supply[ - uint256 tokenId = bound(unboundedTokenId, startingTokenId, startingTokenId + supply - 1); - token.burn(tokenId); - - // balance should have decreased - assertEq(token.balanceOf(receiver), supply - 1); - - // token should be burnt - vm.expectRevert(); - token.ownerOf(tokenId); - } - - function test_transfer( - address[2] calldata accounts, - uint256[2] calldata unboundedBatches, - uint256[2] calldata unboundedTokenId, - uint96 startingId - ) public { - vm.assume(accounts[0] != address(0)); - vm.assume(accounts[1] != address(0)); - vm.assume(accounts[0] != accounts[1]); - - uint256 startingTokenId = bound(startingId, 1, 5000); - - address[] memory receivers = new address[](2); - receivers[0] = accounts[0]; - receivers[1] = accounts[1]; - - // We assume _maxBatchSize is 5000 (the default). This test will break otherwise. - uint256[] memory batches = new uint256[](2); - batches[0] = bound(unboundedBatches[0], startingTokenId, 5000); - batches[1] = bound(unboundedBatches[1], startingTokenId, 5000); - - ERC721ConsecutiveTarget token = new ERC721ConsecutiveTarget(receivers, batches, startingTokenId); - - uint256 tokenId0 = bound(unboundedTokenId[0], startingTokenId, batches[0]); - uint256 tokenId1 = bound(unboundedTokenId[1], startingTokenId, batches[1]) + batches[0]; - - assertEq(token.ownerOf(tokenId0), accounts[0]); - assertEq(token.ownerOf(tokenId1), accounts[1]); - assertEq(token.balanceOf(accounts[0]), batches[0]); - assertEq(token.balanceOf(accounts[1]), batches[1]); - - vm.prank(accounts[0]); - token.transferFrom(accounts[0], accounts[1], tokenId0); - - assertEq(token.ownerOf(tokenId0), accounts[1]); - assertEq(token.ownerOf(tokenId1), accounts[1]); - assertEq(token.balanceOf(accounts[0]), batches[0] - 1); - assertEq(token.balanceOf(accounts[1]), batches[1] + 1); - - vm.prank(accounts[1]); - token.transferFrom(accounts[1], accounts[0], tokenId1); - - assertEq(token.ownerOf(tokenId0), accounts[1]); - assertEq(token.ownerOf(tokenId1), accounts[0]); - assertEq(token.balanceOf(accounts[0]), batches[0]); - assertEq(token.balanceOf(accounts[1]), batches[1]); - } - - function test_start_consecutive_id( - address receiver, - uint256[2] calldata unboundedBatches, - uint256[2] calldata unboundedTokenId, - uint96 startingId - ) public { - vm.assume(receiver != address(0)); - - uint256 startingTokenId = bound(startingId, 1, 5000); - - // We assume _maxBatchSize is 5000 (the default). This test will break otherwise. - uint256[] memory batches = new uint256[](2); - batches[0] = bound(unboundedBatches[0], startingTokenId, 5000); - batches[1] = bound(unboundedBatches[1], startingTokenId, 5000); - - ERC721ConsecutiveTarget token = new ERC721ConsecutiveTarget(toSingleton(receiver), batches, startingTokenId); - - uint256 tokenId0 = bound(unboundedTokenId[0], startingTokenId, batches[0]); - uint256 tokenId1 = bound(unboundedTokenId[1], startingTokenId, batches[1]); - - assertEq(token.ownerOf(tokenId0), receiver); - assertEq(token.ownerOf(tokenId1), receiver); - assertEq(token.balanceOf(receiver), batches[0] + batches[1]); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Consecutive.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Consecutive.test.js deleted file mode 100644 index f62d6dc5b1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Consecutive.test.js +++ /dev/null @@ -1,236 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { sum } = require('../../../helpers/math'); - -const name = 'Non Fungible Token'; -const symbol = 'NFT'; - -describe('ERC721Consecutive', function () { - for (const offset of [0n, 1n, 42n]) { - describe(`with offset ${offset}`, function () { - async function fixture() { - const accounts = await ethers.getSigners(); - const [alice, bruce, chris, receiver] = accounts; - - const batches = [ - { receiver: alice, amount: 0n }, - { receiver: alice, amount: 1n }, - { receiver: alice, amount: 2n }, - { receiver: bruce, amount: 5n }, - { receiver: chris, amount: 0n }, - { receiver: alice, amount: 7n }, - ]; - const delegates = [alice, chris]; - - const token = await ethers.deployContract('$ERC721ConsecutiveMock', [ - name, - symbol, - offset, - delegates, - batches.map(({ receiver }) => receiver), - batches.map(({ amount }) => amount), - ]); - - return { accounts, alice, bruce, chris, receiver, batches, delegates, token }; - } - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('minting during construction', function () { - it('events are emitted at construction', async function () { - let first = offset; - for (const batch of this.batches) { - if (batch.amount > 0) { - await expect(this.token.deploymentTransaction()) - .to.emit(this.token, 'ConsecutiveTransfer') - .withArgs( - first /* fromTokenId */, - first + batch.amount - 1n /* toTokenId */, - ethers.ZeroAddress /* fromAddress */, - batch.receiver /* toAddress */, - ); - } else { - // ".to.not.emit" only looks at event name, and doesn't check the parameters - } - first += batch.amount; - } - }); - - it('ownership is set', async function () { - const owners = [ - ...Array(Number(offset)).fill(ethers.ZeroAddress), - ...this.batches.flatMap(({ receiver, amount }) => Array(Number(amount)).fill(receiver.address)), - ]; - - for (const tokenId in owners) { - if (owners[tokenId] != ethers.ZeroAddress) { - expect(await this.token.ownerOf(tokenId)).to.equal(owners[tokenId]); - } - } - }); - - it('balance & voting power are set', async function () { - for (const account of this.accounts) { - const balance = - sum(...this.batches.filter(({ receiver }) => receiver === account).map(({ amount }) => amount)) ?? 0n; - - expect(await this.token.balanceOf(account)).to.equal(balance); - - // If not delegated at construction, check before + do delegation - if (!this.delegates.includes(account)) { - expect(await this.token.getVotes(account)).to.equal(0n); - - await this.token.connect(account).delegate(account); - } - - // At this point all accounts should have delegated - expect(await this.token.getVotes(account)).to.equal(balance); - } - }); - - it('reverts on consecutive minting to the zero address', async function () { - await expect( - ethers.deployContract('$ERC721ConsecutiveMock', [ - name, - symbol, - offset, - this.delegates, - [ethers.ZeroAddress], - [10], - ]), - ) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidReceiver') - .withArgs(ethers.ZeroAddress); - }); - }); - - describe('minting after construction', function () { - it('consecutive minting is not possible after construction', async function () { - await expect(this.token.$_mintConsecutive(this.alice, 10)).to.be.revertedWithCustomError( - this.token, - 'ERC721ForbiddenBatchMint', - ); - }); - - it('simple minting is possible after construction', async function () { - const tokenId = sum(...this.batches.map(b => b.amount)) + offset; - - await expect(this.token.ownerOf(tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(tokenId); - - await expect(this.token.$_mint(this.alice, tokenId)) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.alice, tokenId); - }); - - it('cannot mint a token that has been batched minted', async function () { - const tokenId = sum(...this.batches.map(b => b.amount)) + offset - 1n; - - expect(await this.token.ownerOf(tokenId)).to.not.equal(ethers.ZeroAddress); - - await expect(this.token.$_mint(this.alice, tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721InvalidSender') - .withArgs(ethers.ZeroAddress); - }); - }); - - describe('ERC721 behavior', function () { - const tokenId = offset + 1n; - - it('core takes over ownership on transfer', async function () { - await this.token.connect(this.alice).transferFrom(this.alice, this.receiver, tokenId); - - expect(await this.token.ownerOf(tokenId)).to.equal(this.receiver); - }); - - it('tokens can be burned and re-minted #1', async function () { - await expect(this.token.connect(this.alice).$_burn(tokenId)) - .to.emit(this.token, 'Transfer') - .withArgs(this.alice, ethers.ZeroAddress, tokenId); - - await expect(this.token.ownerOf(tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(tokenId); - - await expect(this.token.$_mint(this.bruce, tokenId)) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.bruce, tokenId); - - expect(await this.token.ownerOf(tokenId)).to.equal(this.bruce); - }); - - it('tokens can be burned and re-minted #2', async function () { - const tokenId = sum(...this.batches.map(({ amount }) => amount)) + offset; - - await expect(this.token.ownerOf(tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(tokenId); - - // mint - await expect(this.token.$_mint(this.alice, tokenId)) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.alice, tokenId); - - expect(await this.token.ownerOf(tokenId)).to.equal(this.alice); - - // burn - await expect(await this.token.$_burn(tokenId)) - .to.emit(this.token, 'Transfer') - .withArgs(this.alice, ethers.ZeroAddress, tokenId); - - await expect(this.token.ownerOf(tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(tokenId); - - // re-mint - await expect(this.token.$_mint(this.bruce, tokenId)) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.bruce, tokenId); - - expect(await this.token.ownerOf(tokenId)).to.equal(this.bruce); - }); - }); - }); - } - - describe('invalid use', function () { - const receiver = ethers.Wallet.createRandom(); - - it('cannot mint a batch larger than 5000', async function () { - const factory = await ethers.getContractFactory('$ERC721ConsecutiveMock'); - - await expect(ethers.deployContract('$ERC721ConsecutiveMock', [name, symbol, 0, [], [receiver], [5001n]])) - .to.be.revertedWithCustomError(factory, 'ERC721ExceededMaxBatchMint') - .withArgs(5001n, 5000n); - }); - - it('cannot use single minting during construction', async function () { - const factory = await ethers.getContractFactory('$ERC721ConsecutiveNoConstructorMintMock'); - - await expect( - ethers.deployContract('$ERC721ConsecutiveNoConstructorMintMock', [name, symbol]), - ).to.be.revertedWithCustomError(factory, 'ERC721ForbiddenMint'); - }); - - it('cannot use single minting during construction', async function () { - const factory = await ethers.getContractFactory('$ERC721ConsecutiveNoConstructorMintMock'); - - await expect( - ethers.deployContract('$ERC721ConsecutiveNoConstructorMintMock', [name, symbol]), - ).to.be.revertedWithCustomError(factory, 'ERC721ForbiddenMint'); - }); - - it('consecutive mint not compatible with enumerability', async function () { - const factory = await ethers.getContractFactory('$ERC721ConsecutiveEnumerableMock'); - - await expect( - ethers.deployContract('$ERC721ConsecutiveEnumerableMock', [name, symbol, [receiver], [100n]]), - ).to.be.revertedWithCustomError(factory, 'ERC721EnumerableForbiddenBatchMint'); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Pausable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Pausable.test.js deleted file mode 100644 index acf731a456..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Pausable.test.js +++ /dev/null @@ -1,81 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const name = 'Non Fungible Token'; -const symbol = 'NFT'; -const tokenId = 1n; -const otherTokenId = 2n; -const data = ethers.Typed.bytes('0x42'); - -async function fixture() { - const [owner, receiver, operator] = await ethers.getSigners(); - const token = await ethers.deployContract('$ERC721Pausable', [name, symbol]); - return { owner, receiver, operator, token }; -} - -describe('ERC721Pausable', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('when token is paused', function () { - beforeEach(async function () { - await this.token.$_mint(this.owner, tokenId); - await this.token.$_pause(); - }); - - it('reverts when trying to transferFrom', async function () { - await expect( - this.token.connect(this.owner).transferFrom(this.owner, this.receiver, tokenId), - ).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - - it('reverts when trying to safeTransferFrom', async function () { - await expect( - this.token.connect(this.owner).safeTransferFrom(this.owner, this.receiver, tokenId), - ).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - - it('reverts when trying to safeTransferFrom with data', async function () { - await expect( - this.token.connect(this.owner).safeTransferFrom(this.owner, this.receiver, tokenId, data), - ).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - - it('reverts when trying to mint', async function () { - await expect(this.token.$_mint(this.receiver, otherTokenId)).to.be.revertedWithCustomError( - this.token, - 'EnforcedPause', - ); - }); - - it('reverts when trying to burn', async function () { - await expect(this.token.$_burn(tokenId)).to.be.revertedWithCustomError(this.token, 'EnforcedPause'); - }); - - describe('getApproved', function () { - it('returns approved address', async function () { - expect(await this.token.getApproved(tokenId)).to.equal(ethers.ZeroAddress); - }); - }); - - describe('balanceOf', function () { - it('returns the amount of tokens owned by the given address', async function () { - expect(await this.token.balanceOf(this.owner)).to.equal(1n); - }); - }); - - describe('ownerOf', function () { - it('returns the amount of tokens owned by the given address', async function () { - expect(await this.token.ownerOf(tokenId)).to.equal(this.owner); - }); - }); - - describe('isApprovedForAll', function () { - it('returns the approval of the operator', async function () { - expect(await this.token.isApprovedForAll(this.owner, this.operator)).to.be.false; - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Royalty.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Royalty.test.js deleted file mode 100644 index e11954ae7a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Royalty.test.js +++ /dev/null @@ -1,57 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { shouldBehaveLikeERC2981 } = require('../../common/ERC2981.behavior'); - -const name = 'Non Fungible Token'; -const symbol = 'NFT'; - -const tokenId1 = 1n; -const tokenId2 = 2n; -const royalty = 200n; -const salePrice = 1000n; - -async function fixture() { - const [account1, account2, recipient] = await ethers.getSigners(); - - const token = await ethers.deployContract('$ERC721Royalty', [name, symbol]); - await token.$_mint(account1, tokenId1); - await token.$_mint(account1, tokenId2); - - return { account1, account2, recipient, token }; -} - -describe('ERC721Royalty', function () { - beforeEach(async function () { - Object.assign( - this, - await loadFixture(fixture), - { tokenId1, tokenId2, royalty, salePrice }, // set for behavior tests - ); - }); - - describe('token specific functions', function () { - beforeEach(async function () { - await this.token.$_setTokenRoyalty(tokenId1, this.recipient, royalty); - }); - - it('royalty information are kept during burn and re-mint', async function () { - await this.token.$_burn(tokenId1); - - expect(await this.token.royaltyInfo(tokenId1, salePrice)).to.deep.equal([ - this.recipient.address, - (salePrice * royalty) / 10000n, - ]); - - await this.token.$_mint(this.account2, tokenId1); - - expect(await this.token.royaltyInfo(tokenId1, salePrice)).to.deep.equal([ - this.recipient.address, - (salePrice * royalty) / 10000n, - ]); - }); - }); - - shouldBehaveLikeERC2981(); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721URIStorage.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721URIStorage.test.js deleted file mode 100644 index 830c13a735..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721URIStorage.test.js +++ /dev/null @@ -1,121 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { shouldSupportInterfaces } = require('../../../utils/introspection/SupportsInterface.behavior'); - -const name = 'Non Fungible Token'; -const symbol = 'NFT'; -const baseURI = 'https://api.example.com/v1/'; -const otherBaseURI = 'https://api.example.com/v2/'; -const sampleUri = 'mock://mytoken'; -const tokenId = 1n; -const nonExistentTokenId = 2n; - -async function fixture() { - const [owner] = await ethers.getSigners(); - const token = await ethers.deployContract('$ERC721URIStorageMock', [name, symbol]); - return { owner, token }; -} - -describe('ERC721URIStorage', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldSupportInterfaces(['0x49064906']); - - describe('token URI', function () { - beforeEach(async function () { - await this.token.$_mint(this.owner, tokenId); - }); - - it('it is empty by default', async function () { - expect(await this.token.tokenURI(tokenId)).to.equal(''); - }); - - it('reverts when queried for non existent token id', async function () { - await expect(this.token.tokenURI(nonExistentTokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(nonExistentTokenId); - }); - - it('can be set for a token id', async function () { - await this.token.$_setTokenURI(tokenId, sampleUri); - expect(await this.token.tokenURI(tokenId)).to.equal(sampleUri); - }); - - it('setting the uri emits an event', async function () { - await expect(this.token.$_setTokenURI(tokenId, sampleUri)) - .to.emit(this.token, 'MetadataUpdate') - .withArgs(tokenId); - }); - - it('setting the uri for non existent token id is allowed', async function () { - await expect(await this.token.$_setTokenURI(nonExistentTokenId, sampleUri)) - .to.emit(this.token, 'MetadataUpdate') - .withArgs(nonExistentTokenId); - - // value will be accessible after mint - await this.token.$_mint(this.owner, nonExistentTokenId); - expect(await this.token.tokenURI(nonExistentTokenId)).to.equal(sampleUri); - }); - - it('base URI can be set', async function () { - await this.token.setBaseURI(baseURI); - expect(await this.token.$_baseURI()).to.equal(baseURI); - }); - - it('base URI is added as a prefix to the token URI', async function () { - await this.token.setBaseURI(baseURI); - await this.token.$_setTokenURI(tokenId, sampleUri); - - expect(await this.token.tokenURI(tokenId)).to.equal(baseURI + sampleUri); - }); - - it('token URI can be changed by changing the base URI', async function () { - await this.token.setBaseURI(baseURI); - await this.token.$_setTokenURI(tokenId, sampleUri); - - await this.token.setBaseURI(otherBaseURI); - expect(await this.token.tokenURI(tokenId)).to.equal(otherBaseURI + sampleUri); - }); - - it('tokenId is appended to base URI for tokens with no URI', async function () { - await this.token.setBaseURI(baseURI); - - expect(await this.token.tokenURI(tokenId)).to.equal(baseURI + tokenId); - }); - - it('tokens without URI can be burnt ', async function () { - await this.token.$_burn(tokenId); - - await expect(this.token.tokenURI(tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(tokenId); - }); - - it('tokens with URI can be burnt ', async function () { - await this.token.$_setTokenURI(tokenId, sampleUri); - - await this.token.$_burn(tokenId); - - await expect(this.token.tokenURI(tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(tokenId); - }); - - it('tokens URI is kept if token is burnt and reminted ', async function () { - await this.token.$_setTokenURI(tokenId, sampleUri); - - await this.token.$_burn(tokenId); - - await expect(this.token.tokenURI(tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721NonexistentToken') - .withArgs(tokenId); - - await this.token.$_mint(this.owner, tokenId); - expect(await this.token.tokenURI(tokenId)).to.equal(sampleUri); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Votes.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Votes.test.js deleted file mode 100644 index dcae1b8d2d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Votes.test.js +++ /dev/null @@ -1,194 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture, mine } = require('@nomicfoundation/hardhat-network-helpers'); - -const time = require('../../../helpers/time'); - -const { shouldBehaveLikeVotes } = require('../../../governance/utils/Votes.behavior'); - -const TOKENS = [ - { Token: '$ERC721Votes', mode: 'blocknumber' }, - // no timestamp mode for ERC721Votes yet -]; - -const name = 'My Vote'; -const symbol = 'MTKN'; -const version = '1'; -const tokens = [ethers.parseEther('10000000'), 10n, 20n, 30n]; - -describe('ERC721Votes', function () { - for (const { Token, mode } of TOKENS) { - const fixture = async () => { - // accounts is required by shouldBehaveLikeVotes - const accounts = await ethers.getSigners(); - const [holder, recipient, other1, other2] = accounts; - - const token = await ethers.deployContract(Token, [name, symbol, name, version]); - - return { accounts, holder, recipient, other1, other2, token }; - }; - - describe(`vote with ${mode}`, function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - this.votes = this.token; - }); - - // includes ERC6372 behavior check - shouldBehaveLikeVotes(tokens, { mode, fungible: false }); - - describe('balanceOf', function () { - beforeEach(async function () { - await this.votes.$_mint(this.holder, tokens[0]); - await this.votes.$_mint(this.holder, tokens[1]); - await this.votes.$_mint(this.holder, tokens[2]); - await this.votes.$_mint(this.holder, tokens[3]); - }); - - it('grants to initial account', async function () { - expect(await this.votes.balanceOf(this.holder)).to.equal(4n); - }); - }); - - describe('transfers', function () { - beforeEach(async function () { - await this.votes.$_mint(this.holder, tokens[0]); - }); - - it('no delegation', async function () { - await expect(this.votes.connect(this.holder).transferFrom(this.holder, this.recipient, tokens[0])) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.recipient, tokens[0]) - .to.not.emit(this.token, 'DelegateVotesChanged'); - - this.holderVotes = 0n; - this.recipientVotes = 0n; - }); - - it('sender delegation', async function () { - await this.votes.connect(this.holder).delegate(this.holder); - - const tx = await this.votes.connect(this.holder).transferFrom(this.holder, this.recipient, tokens[0]); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.recipient, tokens[0]) - .to.emit(this.token, 'DelegateVotesChanged') - .withArgs(this.holder, 1n, 0n); - - const { logs } = await tx.wait(); - const { index } = logs.find(event => event.fragment.name == 'DelegateVotesChanged'); - for (const event of logs.filter(event => event.fragment.name == 'Transfer')) { - expect(event.index).to.lt(index); - } - - this.holderVotes = 0n; - this.recipientVotes = 0n; - }); - - it('receiver delegation', async function () { - await this.votes.connect(this.recipient).delegate(this.recipient); - - const tx = await this.votes.connect(this.holder).transferFrom(this.holder, this.recipient, tokens[0]); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.recipient, tokens[0]) - .to.emit(this.token, 'DelegateVotesChanged') - .withArgs(this.recipient, 0n, 1n); - - const { logs } = await tx.wait(); - const { index } = logs.find(event => event.fragment.name == 'DelegateVotesChanged'); - for (const event of logs.filter(event => event.fragment.name == 'Transfer')) { - expect(event.index).to.lt(index); - } - - this.holderVotes = 0n; - this.recipientVotes = 1n; - }); - - it('full delegation', async function () { - await this.votes.connect(this.holder).delegate(this.holder); - await this.votes.connect(this.recipient).delegate(this.recipient); - - const tx = await this.votes.connect(this.holder).transferFrom(this.holder, this.recipient, tokens[0]); - await expect(tx) - .to.emit(this.token, 'Transfer') - .withArgs(this.holder, this.recipient, tokens[0]) - .to.emit(this.token, 'DelegateVotesChanged') - .withArgs(this.holder, 1n, 0n) - .to.emit(this.token, 'DelegateVotesChanged') - .withArgs(this.recipient, 0n, 1n); - - const { logs } = await tx.wait(); - const { index } = logs.find(event => event.fragment.name == 'DelegateVotesChanged'); - for (const event of logs.filter(event => event.fragment.name == 'Transfer')) { - expect(event.index).to.lt(index); - } - - this.holderVotes = 0; - this.recipientVotes = 1n; - }); - - it('returns the same total supply on transfers', async function () { - await this.votes.connect(this.holder).delegate(this.holder); - - const tx = await this.votes.connect(this.holder).transferFrom(this.holder, this.recipient, tokens[0]); - const timepoint = await time.clockFromReceipt[mode](tx); - - await mine(2); - - expect(await this.votes.getPastTotalSupply(timepoint - 1n)).to.equal(1n); - expect(await this.votes.getPastTotalSupply(timepoint + 1n)).to.equal(1n); - - this.holderVotes = 0n; - this.recipientVotes = 0n; - }); - - it('generally returns the voting balance at the appropriate checkpoint', async function () { - await this.votes.$_mint(this.holder, tokens[1]); - await this.votes.$_mint(this.holder, tokens[2]); - await this.votes.$_mint(this.holder, tokens[3]); - - const total = await this.votes.balanceOf(this.holder); - - const t1 = await this.votes.connect(this.holder).delegate(this.other1); - await mine(2); - const t2 = await this.votes.connect(this.holder).transferFrom(this.holder, this.other2, tokens[0]); - await mine(2); - const t3 = await this.votes.connect(this.holder).transferFrom(this.holder, this.other2, tokens[2]); - await mine(2); - const t4 = await this.votes.connect(this.other2).transferFrom(this.other2, this.holder, tokens[2]); - await mine(2); - - t1.timepoint = await time.clockFromReceipt[mode](t1); - t2.timepoint = await time.clockFromReceipt[mode](t2); - t3.timepoint = await time.clockFromReceipt[mode](t3); - t4.timepoint = await time.clockFromReceipt[mode](t4); - - expect(await this.votes.getPastVotes(this.other1, t1.timepoint - 1n)).to.equal(0n); - expect(await this.votes.getPastVotes(this.other1, t1.timepoint)).to.equal(total); - expect(await this.votes.getPastVotes(this.other1, t1.timepoint + 1n)).to.equal(total); - expect(await this.votes.getPastVotes(this.other1, t2.timepoint)).to.equal(3n); - expect(await this.votes.getPastVotes(this.other1, t2.timepoint + 1n)).to.equal(3n); - expect(await this.votes.getPastVotes(this.other1, t3.timepoint)).to.equal(2n); - expect(await this.votes.getPastVotes(this.other1, t3.timepoint + 1n)).to.equal(2n); - expect(await this.votes.getPastVotes(this.other1, t4.timepoint)).to.equal('3'); - expect(await this.votes.getPastVotes(this.other1, t4.timepoint + 1n)).to.equal(3n); - - this.holderVotes = 0n; - this.recipientVotes = 0n; - }); - - afterEach(async function () { - expect(await this.votes.getVotes(this.holder)).to.equal(this.holderVotes); - expect(await this.votes.getVotes(this.recipient)).to.equal(this.recipientVotes); - - // need to advance 2 blocks to see the effect of a transfer on "getPastVotes" - const timepoint = await time.clock[mode](); - await mine(); - expect(await this.votes.getPastVotes(this.holder, timepoint)).to.equal(this.holderVotes); - expect(await this.votes.getPastVotes(this.recipient, timepoint)).to.equal(this.recipientVotes); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Wrapper.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Wrapper.test.js deleted file mode 100644 index eeead4c1f1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/extensions/ERC721Wrapper.test.js +++ /dev/null @@ -1,201 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { shouldBehaveLikeERC721 } = require('../ERC721.behavior'); - -const name = 'Non Fungible Token'; -const symbol = 'NFT'; -const tokenId = 1n; -const otherTokenId = 2n; - -async function fixture() { - const accounts = await ethers.getSigners(); - const [owner, approved, other] = accounts; - - const underlying = await ethers.deployContract('$ERC721', [name, symbol]); - await underlying.$_safeMint(owner, tokenId); - await underlying.$_safeMint(owner, otherTokenId); - const token = await ethers.deployContract('$ERC721Wrapper', [`Wrapped ${name}`, `W${symbol}`, underlying]); - - return { accounts, owner, approved, other, underlying, token }; -} - -describe('ERC721Wrapper', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('has a name', async function () { - expect(await this.token.name()).to.equal(`Wrapped ${name}`); - }); - - it('has a symbol', async function () { - expect(await this.token.symbol()).to.equal(`W${symbol}`); - }); - - it('has underlying', async function () { - expect(await this.token.underlying()).to.equal(this.underlying); - }); - - describe('depositFor', function () { - it('works with token approval', async function () { - await this.underlying.connect(this.owner).approve(this.token, tokenId); - - await expect(this.token.connect(this.owner).depositFor(this.owner, [tokenId])) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.owner, this.token, tokenId) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.owner, tokenId); - }); - - it('works with approval for all', async function () { - await this.underlying.connect(this.owner).setApprovalForAll(this.token, true); - - await expect(this.token.connect(this.owner).depositFor(this.owner, [tokenId])) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.owner, this.token, tokenId) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.owner, tokenId); - }); - - it('works sending to another account', async function () { - await this.underlying.connect(this.owner).approve(this.token, tokenId); - - await expect(this.token.connect(this.owner).depositFor(this.other, [tokenId])) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.owner, this.token, tokenId) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.other, tokenId); - }); - - it('works with multiple tokens', async function () { - await this.underlying.connect(this.owner).approve(this.token, tokenId); - await this.underlying.connect(this.owner).approve(this.token, otherTokenId); - - await expect(this.token.connect(this.owner).depositFor(this.owner, [tokenId, otherTokenId])) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.owner, this.token, tokenId) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.owner, tokenId) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.owner, this.token, otherTokenId) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.owner, otherTokenId); - }); - - it('reverts with missing approval', async function () { - await expect(this.token.connect(this.owner).depositFor(this.owner, [tokenId])) - .to.be.revertedWithCustomError(this.token, 'ERC721InsufficientApproval') - .withArgs(this.token, tokenId); - }); - }); - - describe('withdrawTo', function () { - beforeEach(async function () { - await this.underlying.connect(this.owner).approve(this.token, tokenId); - await this.token.connect(this.owner).depositFor(this.owner, [tokenId]); - }); - - it('works for an owner', async function () { - await expect(this.token.connect(this.owner).withdrawTo(this.owner, [tokenId])) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.token, this.owner, tokenId) - .to.emit(this.token, 'Transfer') - .withArgs(this.owner, ethers.ZeroAddress, tokenId); - }); - - it('works for an approved', async function () { - await this.token.connect(this.owner).approve(this.approved, tokenId); - - await expect(this.token.connect(this.approved).withdrawTo(this.owner, [tokenId])) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.token, this.owner, tokenId) - .to.emit(this.token, 'Transfer') - .withArgs(this.owner, ethers.ZeroAddress, tokenId); - }); - - it('works for an approved for all', async function () { - await this.token.connect(this.owner).setApprovalForAll(this.approved, true); - - await expect(this.token.connect(this.approved).withdrawTo(this.owner, [tokenId])) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.token, this.owner, tokenId) - .to.emit(this.token, 'Transfer') - .withArgs(this.owner, ethers.ZeroAddress, tokenId); - }); - - it("doesn't work for a non-owner nor approved", async function () { - await expect(this.token.connect(this.other).withdrawTo(this.owner, [tokenId])) - .to.be.revertedWithCustomError(this.token, 'ERC721InsufficientApproval') - .withArgs(this.other, tokenId); - }); - - it('works with multiple tokens', async function () { - await this.underlying.connect(this.owner).approve(this.token, otherTokenId); - await this.token.connect(this.owner).depositFor(this.owner, [otherTokenId]); - - await expect(this.token.connect(this.owner).withdrawTo(this.owner, [tokenId, otherTokenId])) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.token, this.owner, tokenId) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.token, this.owner, tokenId) - .to.emit(this.token, 'Transfer') - .withArgs(this.owner, ethers.ZeroAddress, tokenId) - .to.emit(this.token, 'Transfer') - .withArgs(this.owner, ethers.ZeroAddress, tokenId); - }); - - it('works to another account', async function () { - await expect(this.token.connect(this.owner).withdrawTo(this.other, [tokenId])) - .to.emit(this.underlying, 'Transfer') - .withArgs(this.token, this.other, tokenId) - .to.emit(this.token, 'Transfer') - .withArgs(this.owner, ethers.ZeroAddress, tokenId); - }); - }); - - describe('onERC721Received', function () { - it('only allows calls from underlying', async function () { - await expect( - this.token.connect(this.other).onERC721Received( - this.owner, - this.token, - tokenId, - this.other.address, // Correct data - ), - ) - .to.be.revertedWithCustomError(this.token, 'ERC721UnsupportedToken') - .withArgs(this.other); - }); - - it('mints a token to from', async function () { - await expect(this.underlying.connect(this.owner).safeTransferFrom(this.owner, this.token, tokenId)) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.owner, tokenId); - }); - }); - - describe('_recover', function () { - it('works if there is something to recover', async function () { - // Should use `transferFrom` to avoid `onERC721Received` minting - await this.underlying.connect(this.owner).transferFrom(this.owner, this.token, tokenId); - - await expect(this.token.$_recover(this.other, tokenId)) - .to.emit(this.token, 'Transfer') - .withArgs(ethers.ZeroAddress, this.other, tokenId); - }); - - it('reverts if there is nothing to recover', async function () { - const holder = await this.underlying.ownerOf(tokenId); - - await expect(this.token.$_recover(holder, tokenId)) - .to.be.revertedWithCustomError(this.token, 'ERC721IncorrectOwner') - .withArgs(this.token, tokenId, holder); - }); - }); - - describe('ERC712 behavior', function () { - shouldBehaveLikeERC721(); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/utils/ERC721Holder.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/utils/ERC721Holder.test.js deleted file mode 100644 index 31dd2fd20d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/utils/ERC721Holder.test.js +++ /dev/null @@ -1,20 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); - -const name = 'Non Fungible Token'; -const symbol = 'NFT'; -const tokenId = 1n; - -describe('ERC721Holder', function () { - it('receives an ERC721 token', async function () { - const [owner] = await ethers.getSigners(); - - const token = await ethers.deployContract('$ERC721', [name, symbol]); - await token.$_mint(owner, tokenId); - - const receiver = await ethers.deployContract('$ERC721Holder'); - await token.connect(owner).safeTransferFrom(owner, receiver, tokenId); - - expect(await token.ownerOf(tokenId)).to.equal(receiver); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/utils/ERC721Utils.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/utils/ERC721Utils.test.js deleted file mode 100644 index 2327d1ac7d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/ERC721/utils/ERC721Utils.test.js +++ /dev/null @@ -1,94 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { RevertType } = require('../../../helpers/enums'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -const tokenId = 1n; - -const RECEIVER_MAGIC_VALUE = '0x150b7a02'; - -const deployReceiver = (revertType, returnValue = RECEIVER_MAGIC_VALUE) => - ethers.deployContract('$ERC721ReceiverMock', [returnValue, revertType]); - -const fixture = async () => { - const [eoa, operator, owner] = await ethers.getSigners(); - const utils = await ethers.deployContract('$ERC721Utils'); - - const receivers = { - correct: await deployReceiver(RevertType.None), - invalid: await deployReceiver(RevertType.None, '0xdeadbeef'), - message: await deployReceiver(RevertType.RevertWithMessage), - empty: await deployReceiver(RevertType.RevertWithoutMessage), - customError: await deployReceiver(RevertType.RevertWithCustomError), - panic: await deployReceiver(RevertType.Panic), - nonReceiver: await ethers.deployContract('CallReceiverMock'), - eoa, - }; - - return { operator, owner, utils, receivers }; -}; - -describe('ERC721Utils', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('onERC721Received', function () { - it('succeeds when called by an EOA', async function () { - await expect(this.utils.$checkOnERC721Received(this.operator, this.owner, this.receivers.eoa, tokenId, '0x')).to - .not.be.reverted; - }); - - it('succeeds when data is passed', async function () { - const data = '0x12345678'; - await expect(this.utils.$checkOnERC721Received(this.operator, this.owner, this.receivers.correct, tokenId, data)) - .to.not.be.reverted; - }); - - it('succeeds when data is empty', async function () { - await expect(this.utils.$checkOnERC721Received(this.operator, this.owner, this.receivers.correct, tokenId, '0x')) - .to.not.be.reverted; - }); - - it('reverts when receiver returns invalid value', async function () { - await expect(this.utils.$checkOnERC721Received(this.operator, this.owner, this.receivers.invalid, tokenId, '0x')) - .to.be.revertedWithCustomError(this.utils, 'ERC721InvalidReceiver') - .withArgs(this.receivers.invalid); - }); - - it('reverts when receiver reverts with message', async function () { - await expect( - this.utils.$checkOnERC721Received(this.operator, this.owner, this.receivers.message, tokenId, '0x'), - ).to.be.revertedWith('ERC721ReceiverMock: reverting'); - }); - - it('reverts when receiver reverts without message', async function () { - await expect(this.utils.$checkOnERC721Received(this.operator, this.owner, this.receivers.empty, tokenId, '0x')) - .to.be.revertedWithCustomError(this.utils, 'ERC721InvalidReceiver') - .withArgs(this.receivers.empty); - }); - - it('reverts when receiver reverts with custom error', async function () { - await expect( - this.utils.$checkOnERC721Received(this.operator, this.owner, this.receivers.customError, tokenId, '0x'), - ) - .to.be.revertedWithCustomError(this.receivers.customError, 'CustomError') - .withArgs(RECEIVER_MAGIC_VALUE); - }); - - it('reverts when receiver panics', async function () { - await expect( - this.utils.$checkOnERC721Received(this.operator, this.owner, this.receivers.panic, tokenId, '0x'), - ).to.be.revertedWithPanic(PANIC_CODES.DIVISION_BY_ZERO); - }); - - it('reverts when receiver does not implement onERC721Received', async function () { - await expect( - this.utils.$checkOnERC721Received(this.operator, this.owner, this.receivers.nonReceiver, tokenId, '0x'), - ) - .to.be.revertedWithCustomError(this.utils, 'ERC721InvalidReceiver') - .withArgs(this.receivers.nonReceiver); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/common/ERC2981.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/common/ERC2981.behavior.js deleted file mode 100644 index ae6abccaed..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/token/common/ERC2981.behavior.js +++ /dev/null @@ -1,152 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); - -const { shouldSupportInterfaces } = require('../../utils/introspection/SupportsInterface.behavior'); - -function shouldBehaveLikeERC2981() { - const royaltyFraction = 10n; - - shouldSupportInterfaces(['ERC2981']); - - describe('default royalty', function () { - beforeEach(async function () { - await this.token.$_setDefaultRoyalty(this.account1, royaltyFraction); - }); - - it('checks royalty is set', async function () { - expect(await this.token.royaltyInfo(this.tokenId1, this.salePrice)).to.deep.equal([ - this.account1.address, - (this.salePrice * royaltyFraction) / 10_000n, - ]); - }); - - it('updates royalty amount', async function () { - const newFraction = 25n; - - await this.token.$_setDefaultRoyalty(this.account1, newFraction); - - expect(await this.token.royaltyInfo(this.tokenId1, this.salePrice)).to.deep.equal([ - this.account1.address, - (this.salePrice * newFraction) / 10_000n, - ]); - }); - - it('holds same royalty value for different tokens', async function () { - const newFraction = 20n; - - await this.token.$_setDefaultRoyalty(this.account1, newFraction); - - expect(await this.token.royaltyInfo(this.tokenId1, this.salePrice)).to.deep.equal( - await this.token.royaltyInfo(this.tokenId2, this.salePrice), - ); - }); - - it('Remove royalty information', async function () { - const newValue = 0n; - await this.token.$_deleteDefaultRoyalty(); - - expect(await this.token.royaltyInfo(this.tokenId1, this.salePrice)).to.deep.equal([ethers.ZeroAddress, newValue]); - - expect(await this.token.royaltyInfo(this.tokenId2, this.salePrice)).to.deep.equal([ethers.ZeroAddress, newValue]); - }); - - it('reverts if invalid parameters', async function () { - const royaltyDenominator = await this.token.$_feeDenominator(); - - await expect(this.token.$_setDefaultRoyalty(ethers.ZeroAddress, royaltyFraction)) - .to.be.revertedWithCustomError(this.token, 'ERC2981InvalidDefaultRoyaltyReceiver') - .withArgs(ethers.ZeroAddress); - - const anotherRoyaltyFraction = 11000n; - - await expect(this.token.$_setDefaultRoyalty(this.account1, anotherRoyaltyFraction)) - .to.be.revertedWithCustomError(this.token, 'ERC2981InvalidDefaultRoyalty') - .withArgs(anotherRoyaltyFraction, royaltyDenominator); - }); - }); - - describe('token based royalty', function () { - beforeEach(async function () { - await this.token.$_setTokenRoyalty(this.tokenId1, this.account1, royaltyFraction); - }); - - it('updates royalty amount', async function () { - const newFraction = 25n; - - expect(await this.token.royaltyInfo(this.tokenId1, this.salePrice)).to.deep.equal([ - this.account1.address, - (this.salePrice * royaltyFraction) / 10_000n, - ]); - - await this.token.$_setTokenRoyalty(this.tokenId1, this.account1, newFraction); - - expect(await this.token.royaltyInfo(this.tokenId1, this.salePrice)).to.deep.equal([ - this.account1.address, - (this.salePrice * newFraction) / 10_000n, - ]); - }); - - it('holds different values for different tokens', async function () { - const newFraction = 20n; - - await this.token.$_setTokenRoyalty(this.tokenId2, this.account1, newFraction); - - expect(await this.token.royaltyInfo(this.tokenId1, this.salePrice)).to.not.deep.equal( - await this.token.royaltyInfo(this.tokenId2, this.salePrice), - ); - }); - - it('reverts if invalid parameters', async function () { - const royaltyDenominator = await this.token.$_feeDenominator(); - - await expect(this.token.$_setTokenRoyalty(this.tokenId1, ethers.ZeroAddress, royaltyFraction)) - .to.be.revertedWithCustomError(this.token, 'ERC2981InvalidTokenRoyaltyReceiver') - .withArgs(this.tokenId1, ethers.ZeroAddress); - - const anotherRoyaltyFraction = 11000n; - - await expect(this.token.$_setTokenRoyalty(this.tokenId1, this.account1, anotherRoyaltyFraction)) - .to.be.revertedWithCustomError(this.token, 'ERC2981InvalidTokenRoyalty') - .withArgs(this.tokenId1, anotherRoyaltyFraction, royaltyDenominator); - }); - - it('can reset token after setting royalty', async function () { - const newFraction = 30n; - - await this.token.$_setTokenRoyalty(this.tokenId1, this.account2, newFraction); - - // Tokens must have own information - expect(await this.token.royaltyInfo(this.tokenId1, this.salePrice)).to.deep.equal([ - this.account2.address, - (this.salePrice * newFraction) / 10_000n, - ]); - - await this.token.$_setTokenRoyalty(this.tokenId2, this.account1, 0n); - - // Token must not share default information - expect(await this.token.royaltyInfo(this.tokenId2, this.salePrice)).to.deep.equal([this.account1.address, 0n]); - }); - - it('can hold default and token royalty information', async function () { - const newFraction = 30n; - - await this.token.$_setTokenRoyalty(this.tokenId2, this.account2, newFraction); - - // Tokens must not have same values - expect(await this.token.royaltyInfo(this.tokenId1, this.salePrice)).to.not.deep.equal([ - this.account2.address, - (this.salePrice * newFraction) / 10_000n, - ]); - - // Updated token must have new values - expect(await this.token.royaltyInfo(this.tokenId2, this.salePrice)).to.deep.equal([ - this.account2.address, - (this.salePrice * newFraction) / 10_000n, - ]); - }); - }); -} - -module.exports = { - shouldBehaveLikeERC2981, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Address.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Address.test.js deleted file mode 100644 index 8307a923e6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Address.test.js +++ /dev/null @@ -1,281 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -const coder = ethers.AbiCoder.defaultAbiCoder(); - -async function fixture() { - const [recipient, other] = await ethers.getSigners(); - - const mock = await ethers.deployContract('$Address'); - const target = await ethers.deployContract('CallReceiverMock'); - const targetEther = await ethers.deployContract('EtherReceiverMock'); - - return { recipient, other, mock, target, targetEther }; -} - -describe('Address', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('sendValue', function () { - describe('when sender contract has no funds', function () { - it('sends 0 wei', async function () { - await expect(this.mock.$sendValue(this.other, 0n)).to.changeEtherBalance(this.recipient, 0n); - }); - - it('reverts when sending non-zero amounts', async function () { - await expect(this.mock.$sendValue(this.other, 1n)) - .to.be.revertedWithCustomError(this.mock, 'InsufficientBalance') - .withArgs(0n, 1n); - }); - }); - - describe('when sender contract has funds', function () { - const funds = ethers.parseEther('1'); - - beforeEach(async function () { - await this.other.sendTransaction({ to: this.mock, value: funds }); - }); - - describe('with EOA recipient', function () { - it('sends 0 wei', async function () { - await expect(this.mock.$sendValue(this.recipient, 0n)).to.changeEtherBalance(this.recipient, 0n); - }); - - it('sends non-zero amounts', async function () { - await expect(this.mock.$sendValue(this.recipient, funds - 1n)).to.changeEtherBalance( - this.recipient, - funds - 1n, - ); - }); - - it('sends the whole balance', async function () { - await expect(this.mock.$sendValue(this.recipient, funds)).to.changeEtherBalance(this.recipient, funds); - expect(await ethers.provider.getBalance(this.mock)).to.equal(0n); - }); - - it('reverts when sending more than the balance', async function () { - await expect(this.mock.$sendValue(this.recipient, funds + 1n)) - .to.be.revertedWithCustomError(this.mock, 'InsufficientBalance') - .withArgs(funds, funds + 1n); - }); - }); - - describe('with contract recipient', function () { - it('sends funds', async function () { - await this.targetEther.setAcceptEther(true); - await expect(this.mock.$sendValue(this.targetEther, funds)).to.changeEtherBalance(this.targetEther, funds); - }); - - it('reverts on recipient revert', async function () { - await this.targetEther.setAcceptEther(false); - await expect(this.mock.$sendValue(this.targetEther, funds)).to.be.revertedWithCustomError( - this.mock, - 'FailedCall', - ); - }); - }); - }); - }); - - describe('functionCall', function () { - describe('with valid contract receiver', function () { - it('calls the requested function', async function () { - const call = this.target.interface.encodeFunctionData('mockFunction'); - - await expect(this.mock.$functionCall(this.target, call)) - .to.emit(this.target, 'MockFunctionCalled') - .to.emit(this.mock, 'return$functionCall') - .withArgs(coder.encode(['string'], ['0x1234'])); - }); - - it('calls the requested empty return function', async function () { - const call = this.target.interface.encodeFunctionData('mockFunctionEmptyReturn'); - - await expect(this.mock.$functionCall(this.target, call)).to.emit(this.target, 'MockFunctionCalled'); - }); - - it('reverts when the called function reverts with no reason', async function () { - const call = this.target.interface.encodeFunctionData('mockFunctionRevertsNoReason'); - - await expect(this.mock.$functionCall(this.target, call)).to.be.revertedWithCustomError(this.mock, 'FailedCall'); - }); - - it('reverts when the called function reverts, bubbling up the revert reason', async function () { - const call = this.target.interface.encodeFunctionData('mockFunctionRevertsReason'); - - await expect(this.mock.$functionCall(this.target, call)).to.be.revertedWith('CallReceiverMock: reverting'); - }); - - it('reverts when the called function runs out of gas', async function () { - const call = this.target.interface.encodeFunctionData('mockFunctionOutOfGas'); - - await expect(this.mock.$functionCall(this.target, call, { gasLimit: 120_000n })).to.be.revertedWithCustomError( - this.mock, - 'FailedCall', - ); - }); - - it('reverts when the called function throws', async function () { - const call = this.target.interface.encodeFunctionData('mockFunctionThrows'); - - await expect(this.mock.$functionCall(this.target, call)).to.be.revertedWithPanic(PANIC_CODES.ASSERTION_ERROR); - }); - - it('reverts when function does not exist', async function () { - const call = new ethers.Interface(['function mockFunctionDoesNotExist()']).encodeFunctionData( - 'mockFunctionDoesNotExist', - ); - - await expect(this.mock.$functionCall(this.target, call)).to.be.revertedWithCustomError(this.mock, 'FailedCall'); - }); - }); - - describe('with non-contract receiver', function () { - it('reverts when address is not a contract', async function () { - const call = this.target.interface.encodeFunctionData('mockFunction'); - - await expect(this.mock.$functionCall(this.recipient, call)) - .to.be.revertedWithCustomError(this.mock, 'AddressEmptyCode') - .withArgs(this.recipient); - }); - }); - }); - - describe('functionCallWithValue', function () { - describe('with zero value', function () { - it('calls the requested function', async function () { - const call = this.target.interface.encodeFunctionData('mockFunction'); - - await expect(this.mock.$functionCallWithValue(this.target, call, 0n)) - .to.emit(this.target, 'MockFunctionCalled') - .to.emit(this.mock, 'return$functionCallWithValue') - .withArgs(coder.encode(['string'], ['0x1234'])); - }); - }); - - describe('with non-zero value', function () { - const value = ethers.parseEther('1.2'); - - it('reverts if insufficient sender balance', async function () { - const call = this.target.interface.encodeFunctionData('mockFunction'); - - await expect(this.mock.$functionCallWithValue(this.target, call, value)) - .to.be.revertedWithCustomError(this.mock, 'InsufficientBalance') - .withArgs(0n, value); - }); - - it('calls the requested function with existing value', async function () { - await this.other.sendTransaction({ to: this.mock, value }); - - const call = this.target.interface.encodeFunctionData('mockFunction'); - const tx = await this.mock.$functionCallWithValue(this.target, call, value); - - await expect(tx).to.changeEtherBalance(this.target, value); - - await expect(tx) - .to.emit(this.target, 'MockFunctionCalled') - .to.emit(this.mock, 'return$functionCallWithValue') - .withArgs(coder.encode(['string'], ['0x1234'])); - }); - - it('calls the requested function with transaction funds', async function () { - expect(await ethers.provider.getBalance(this.mock)).to.equal(0n); - - const call = this.target.interface.encodeFunctionData('mockFunction'); - const tx = await this.mock.connect(this.other).$functionCallWithValue(this.target, call, value, { value }); - - await expect(tx).to.changeEtherBalance(this.target, value); - await expect(tx) - .to.emit(this.target, 'MockFunctionCalled') - .to.emit(this.mock, 'return$functionCallWithValue') - .withArgs(coder.encode(['string'], ['0x1234'])); - }); - - it('reverts when calling non-payable functions', async function () { - await this.other.sendTransaction({ to: this.mock, value }); - - const call = this.target.interface.encodeFunctionData('mockFunctionNonPayable'); - - await expect(this.mock.$functionCallWithValue(this.target, call, value)).to.be.revertedWithCustomError( - this.mock, - 'FailedCall', - ); - }); - }); - }); - - describe('functionStaticCall', function () { - it('calls the requested function', async function () { - const call = this.target.interface.encodeFunctionData('mockStaticFunction'); - - expect(await this.mock.$functionStaticCall(this.target, call)).to.equal(coder.encode(['string'], ['0x1234'])); - }); - - it('reverts on a non-static function', async function () { - const call = this.target.interface.encodeFunctionData('mockFunction'); - - await expect(this.mock.$functionStaticCall(this.target, call)).to.be.revertedWithCustomError( - this.mock, - 'FailedCall', - ); - }); - - it('bubbles up revert reason', async function () { - const call = this.target.interface.encodeFunctionData('mockFunctionRevertsReason'); - - await expect(this.mock.$functionStaticCall(this.target, call)).to.be.revertedWith('CallReceiverMock: reverting'); - }); - - it('reverts when address is not a contract', async function () { - const call = this.target.interface.encodeFunctionData('mockFunction'); - - await expect(this.mock.$functionStaticCall(this.recipient, call)) - .to.be.revertedWithCustomError(this.mock, 'AddressEmptyCode') - .withArgs(this.recipient); - }); - }); - - describe('functionDelegateCall', function () { - it('delegate calls the requested function', async function () { - const slot = ethers.hexlify(ethers.randomBytes(32)); - const value = ethers.hexlify(ethers.randomBytes(32)); - - const call = this.target.interface.encodeFunctionData('mockFunctionWritesStorage', [slot, value]); - - expect(await ethers.provider.getStorage(this.mock, slot)).to.equal(ethers.ZeroHash); - - await expect(await this.mock.$functionDelegateCall(this.target, call)) - .to.emit(this.mock, 'return$functionDelegateCall') - .withArgs(coder.encode(['string'], ['0x1234'])); - - expect(await ethers.provider.getStorage(this.mock, slot)).to.equal(value); - }); - - it('bubbles up revert reason', async function () { - const call = this.target.interface.encodeFunctionData('mockFunctionRevertsReason'); - - await expect(this.mock.$functionDelegateCall(this.target, call)).to.be.revertedWith( - 'CallReceiverMock: reverting', - ); - }); - - it('reverts when address is not a contract', async function () { - const call = this.target.interface.encodeFunctionData('mockFunction'); - - await expect(this.mock.$functionDelegateCall(this.recipient, call)) - .to.be.revertedWithCustomError(this.mock, 'AddressEmptyCode') - .withArgs(this.recipient); - }); - }); - - describe('verifyCallResult', function () { - it('returns returndata on success', async function () { - const returndata = '0x123abc'; - expect(await this.mock.$verifyCallResult(true, returndata)).to.equal(returndata); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Arrays.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Arrays.t.sol deleted file mode 100644 index 09c7b66b6d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Arrays.t.sol +++ /dev/null @@ -1,31 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {SymTest} from "halmos-cheatcodes/SymTest.sol"; -import {Arrays} from "@openzeppelin/contracts/utils/Arrays.sol"; - -contract ArraysTest is Test, SymTest { - function testSort(uint256[] memory values) public { - Arrays.sort(values); - _assertSort(values); - } - - function symbolicSort() public { - uint256[] memory values = new uint256[](3); - for (uint256 i = 0; i < 3; i++) { - values[i] = svm.createUint256("arrayElement"); - } - Arrays.sort(values); - _assertSort(values); - } - - /// Asserts - - function _assertSort(uint256[] memory values) internal { - for (uint256 i = 1; i < values.length; ++i) { - assertLe(values[i - 1], values[i]); - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Arrays.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Arrays.test.js deleted file mode 100644 index bcb385897d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Arrays.test.js +++ /dev/null @@ -1,223 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { generators } = require('../helpers/random'); -const { capitalize } = require('../../scripts/helpers'); -const { TYPES } = require('../../scripts/generate/templates/Arrays.opts'); - -// See https://en.cppreference.com/w/cpp/algorithm/lower_bound -const lowerBound = (array, value) => { - const i = array.findIndex(element => value <= element); - return i == -1 ? array.length : i; -}; - -// See https://en.cppreference.com/w/cpp/algorithm/upper_bound -const upperBound = (array, value) => { - const i = array.findIndex(element => value < element); - return i == -1 ? array.length : i; -}; - -const bigintSign = x => (x > 0n ? 1 : x < 0n ? -1 : 0); -const comparator = (a, b) => bigintSign(ethers.toBigInt(a) - ethers.toBigInt(b)); -const hasDuplicates = array => array.some((v, i) => array.indexOf(v) != i); - -describe('Arrays', function () { - const fixture = async () => { - return { mock: await ethers.deployContract('$Arrays') }; - }; - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('search', function () { - for (const [title, { array, tests }] of Object.entries({ - 'Even number of elements': { - array: [11n, 12n, 13n, 14n, 15n, 16n, 17n, 18n, 19n, 20n], - tests: { - 'basic case': 16n, - 'first element': 11n, - 'last element': 20n, - 'searched value is over the upper boundary': 32n, - 'searched value is under the lower boundary': 2n, - }, - }, - 'Odd number of elements': { - array: [11n, 12n, 13n, 14n, 15n, 16n, 17n, 18n, 19n, 20n, 21n], - tests: { - 'basic case': 16n, - 'first element': 11n, - 'last element': 21n, - 'searched value is over the upper boundary': 32n, - 'searched value is under the lower boundary': 2n, - }, - }, - 'Array with gap': { - array: [11n, 12n, 13n, 14n, 15n, 20n, 21n, 22n, 23n, 24n], - tests: { - 'search value in gap': 17n, - }, - }, - 'Array with duplicated elements': { - array: [0n, 10n, 10n, 10n, 10n, 10n, 10n, 10n, 20n], - tests: { - 'search value is duplicated': 10n, - }, - }, - 'Array with duplicated first element': { - array: [10n, 10n, 10n, 10n, 10n, 10n, 10n, 20n], - tests: { - 'search value is duplicated first element': 10n, - }, - }, - 'Array with duplicated last element': { - array: [0n, 10n, 10n, 10n, 10n, 10n, 10n, 10n], - tests: { - 'search value is duplicated last element': 10n, - }, - }, - 'Empty array': { - array: [], - tests: { - 'always returns 0 for empty array': 10n, - }, - }, - })) { - describe(title, function () { - const fixture = async () => { - return { instance: await ethers.deployContract('Uint256ArraysMock', [array]) }; - }; - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - for (const [name, input] of Object.entries(tests)) { - describe(name, function () { - it('[deprecated] findUpperBound', async function () { - // findUpperBound does not support duplicated - if (hasDuplicates(array)) { - expect(await this.instance.findUpperBound(input)).to.equal(upperBound(array, input) - 1); - } else { - expect(await this.instance.findUpperBound(input)).to.equal(lowerBound(array, input)); - } - }); - - it('lowerBound', async function () { - expect(await this.instance.lowerBound(input)).to.equal(lowerBound(array, input)); - expect(await this.instance.lowerBoundMemory(array, input)).to.equal(lowerBound(array, input)); - }); - - it('upperBound', async function () { - expect(await this.instance.upperBound(input)).to.equal(upperBound(array, input)); - expect(await this.instance.upperBoundMemory(array, input)).to.equal(upperBound(array, input)); - }); - }); - } - }); - } - }); - - for (const type of TYPES) { - const elements = Array.from({ length: 10 }, generators[type]); - - describe(type, function () { - const fixture = async () => { - return { instance: await ethers.deployContract(`${capitalize(type)}ArraysMock`, [elements]) }; - }; - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('sort', function () { - for (const length of [0, 1, 2, 8, 32, 128]) { - describe(`${type}[] of length ${length}`, function () { - beforeEach(async function () { - this.array = Array.from({ length }, generators[type]); - }); - - afterEach(async function () { - const expected = Array.from(this.array).sort(comparator); - const reversed = Array.from(expected).reverse(); - expect(await this.instance.sort(this.array)).to.deep.equal(expected); - expect(await this.instance.sortReverse(this.array)).to.deep.equal(reversed); - }); - - it('sort array', async function () { - // nothing to do here, beforeEach and afterEach already take care of everything. - }); - - if (length > 1) { - it('sort array for identical elements', async function () { - // duplicate the first value to all elements - this.array.fill(this.array.at(0)); - }); - - it('sort already sorted array', async function () { - // pre-sort the elements - this.array.sort(comparator); - }); - - it('sort reversed array', async function () { - // pre-sort in reverse order - this.array.sort(comparator).reverse(); - }); - - it('sort almost sorted array', async function () { - // pre-sort + rotate (move the last element to the front) for an almost sorted effect - this.array.sort(comparator); - this.array.unshift(this.array.pop()); - }); - } - }); - } - }); - - describe('unsafeAccess', function () { - describe('storage', function () { - for (const i in elements) { - it(`unsafeAccess within bounds #${i}`, async function () { - expect(await this.instance.unsafeAccess(i)).to.equal(elements[i]); - }); - } - - it('unsafeAccess outside bounds', async function () { - await expect(this.instance.unsafeAccess(elements.length)).to.not.be.rejected; - }); - - it('unsafeSetLength changes the length or the array', async function () { - const newLength = generators.uint256(); - - expect(await this.instance.length()).to.equal(elements.length); - await expect(this.instance.unsafeSetLength(newLength)).to.not.be.rejected; - expect(await this.instance.length()).to.equal(newLength); - }); - }); - - describe('memory', function () { - const fragment = `$unsafeMemoryAccess(${type}[] arr, uint256 pos)`; - - for (const i in elements) { - it(`unsafeMemoryAccess within bounds #${i}`, async function () { - expect(await this.mock[fragment](elements, i)).to.equal(elements[i]); - }); - } - - it('unsafeMemoryAccess outside bounds', async function () { - await expect(this.mock[fragment](elements, elements.length)).to.not.be.rejected; - }); - - it('unsafeMemoryAccess loop around', async function () { - for (let i = 251n; i < 256n; ++i) { - expect(await this.mock[fragment](elements, 2n ** i - 1n)).to.equal(BigInt(elements.length)); - expect(await this.mock[fragment](elements, 2n ** i + 0n)).to.equal(elements[0]); - expect(await this.mock[fragment](elements, 2n ** i + 1n)).to.equal(elements[1]); - } - }); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Base64.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Base64.t.sol deleted file mode 100644 index 021ae03af0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Base64.t.sol +++ /dev/null @@ -1,34 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {Base64} from "@openzeppelin/contracts/utils/Base64.sol"; - -contract Base64Test is Test { - function testEncode(bytes memory input) external { - assertEq(Base64.encode(input), vm.toBase64(input)); - } - - function testEncodeURL(bytes memory input) external { - assertEq(Base64.encodeURL(input), _removePadding(vm.toBase64URL(input))); - } - - function _removePadding(string memory inputStr) internal pure returns (string memory) { - bytes memory input = bytes(inputStr); - bytes memory output; - - for (uint256 i = 0; i < input.length; ++i) { - if (input[input.length - i - 1] != 0x3d) { - output = new bytes(input.length - i); - break; - } - } - - for (uint256 i = 0; i < output.length; ++i) { - output[i] = input[i]; - } - - return string(output); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Base64.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Base64.test.js deleted file mode 100644 index 5c42746667..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Base64.test.js +++ /dev/null @@ -1,59 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -// Replace "+/" with "-_" in the char table, and remove the padding -// see https://datatracker.ietf.org/doc/html/rfc4648#section-5 -const base64toBase64Url = str => str.replaceAll('+', '-').replaceAll('/', '_').replaceAll('=', ''); - -async function fixture() { - const mock = await ethers.deployContract('$Base64'); - return { mock }; -} - -describe('Strings', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('base64', function () { - for (const { title, input, expected } of [ - { title: 'converts to base64 encoded string with double padding', input: 'test', expected: 'dGVzdA==' }, - { title: 'converts to base64 encoded string with single padding', input: 'test1', expected: 'dGVzdDE=' }, - { title: 'converts to base64 encoded string without padding', input: 'test12', expected: 'dGVzdDEy' }, - { title: 'converts to base64 encoded string (/ case)', input: 'où', expected: 'b/k=' }, - { title: 'converts to base64 encoded string (+ case)', input: 'zs~1t8', expected: 'enN+MXQ4' }, - { title: 'empty bytes', input: '', expected: '' }, - ]) - it(title, async function () { - const buffer = Buffer.from(input, 'ascii'); - expect(await this.mock.$encode(buffer)).to.equal(ethers.encodeBase64(buffer)); - expect(await this.mock.$encode(buffer)).to.equal(expected); - }); - }); - - describe('base64url', function () { - for (const { title, input, expected } of [ - { title: 'converts to base64url encoded string with double padding', input: 'test', expected: 'dGVzdA' }, - { title: 'converts to base64url encoded string with single padding', input: 'test1', expected: 'dGVzdDE' }, - { title: 'converts to base64url encoded string without padding', input: 'test12', expected: 'dGVzdDEy' }, - { title: 'converts to base64url encoded string (_ case)', input: 'où', expected: 'b_k' }, - { title: 'converts to base64url encoded string (- case)', input: 'zs~1t8', expected: 'enN-MXQ4' }, - { title: 'empty bytes', input: '', expected: '' }, - ]) - it(title, async function () { - const buffer = Buffer.from(input, 'ascii'); - expect(await this.mock.$encodeURL(buffer)).to.equal(base64toBase64Url(ethers.encodeBase64(buffer))); - expect(await this.mock.$encodeURL(buffer)).to.equal(expected); - }); - }); - - it('Encode reads beyond the input buffer into dirty memory', async function () { - const mock = await ethers.deployContract('Base64Dirty'); - const buffer32 = ethers.id('example'); - const buffer31 = buffer32.slice(0, -2); - - expect(await mock.encode(buffer31)).to.equal(ethers.encodeBase64(buffer31)); - expect(await mock.encode(buffer32)).to.equal(ethers.encodeBase64(buffer32)); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Bytes.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Bytes.test.js deleted file mode 100644 index 52a1ae95e7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Bytes.test.js +++ /dev/null @@ -1,88 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -async function fixture() { - const mock = await ethers.deployContract('$Bytes'); - return { mock }; -} - -const lorem = ethers.toUtf8Bytes( - 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.', -); -const present = lorem.at(1); -const absent = 255; - -describe('Bytes', function () { - before(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('indexOf', function () { - it('first', async function () { - expect(await this.mock.$indexOf(lorem, ethers.toBeHex(present))).to.equal(lorem.indexOf(present)); - }); - - it('from index', async function () { - for (const start in Array(lorem.length + 10).fill()) { - const index = lorem.indexOf(present, start); - const result = index === -1 ? ethers.MaxUint256 : index; - expect(await this.mock.$indexOf(lorem, ethers.toBeHex(present), ethers.Typed.uint256(start))).to.equal(result); - } - }); - - it('absent', async function () { - expect(await this.mock.$indexOf(lorem, ethers.toBeHex(absent))).to.equal(ethers.MaxUint256); - }); - }); - - describe('lastIndexOf', function () { - it('first', async function () { - expect(await this.mock.$lastIndexOf(lorem, ethers.toBeHex(present))).to.equal(lorem.lastIndexOf(present)); - }); - - it('from index', async function () { - for (const start in Array(lorem.length + 10).fill()) { - const index = lorem.lastIndexOf(present, start); - const result = index === -1 ? ethers.MaxUint256 : index; - expect(await this.mock.$lastIndexOf(lorem, ethers.toBeHex(present), ethers.Typed.uint256(start))).to.equal( - result, - ); - } - }); - - it('absent', async function () { - expect(await this.mock.$lastIndexOf(lorem, ethers.toBeHex(absent))).to.equal(ethers.MaxUint256); - }); - }); - - describe('slice', function () { - describe('slice(bytes, uint256)', function () { - for (const [descr, start] of Object.entries({ - 'start = 0': 0, - 'start within bound': 10, - 'start out of bound': 1000, - })) { - it(descr, async function () { - const result = ethers.hexlify(lorem.slice(start)); - expect(await this.mock.$slice(lorem, start)).to.equal(result); - }); - } - }); - - describe('slice(bytes, uint256, uint256)', function () { - for (const [descr, [start, end]] of Object.entries({ - 'start = 0': [0, 42], - 'start and end within bound': [17, 42], - 'end out of bound': [42, 1000], - 'start = end': [17, 17], - 'start > end': [42, 17], - })) { - it(descr, async function () { - const result = ethers.hexlify(lorem.slice(start, end)); - expect(await this.mock.$slice(lorem, start, ethers.Typed.uint256(end))).to.equal(result); - }); - } - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/CAIP.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/CAIP.test.js deleted file mode 100644 index cd5995cade..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/CAIP.test.js +++ /dev/null @@ -1,53 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { CHAINS, getLocalCAIP } = require('../helpers/chains'); - -async function fixture() { - const caip2 = await ethers.deployContract('$CAIP2'); - const caip10 = await ethers.deployContract('$CAIP10'); - return { caip2, caip10 }; -} - -describe('CAIP utilities', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('CAIP-2', function () { - it('local()', async function () { - const { caip2 } = await getLocalCAIP(); - expect(await this.caip2.$local()).to.equal(caip2); - }); - - for (const { namespace, reference, caip2 } of Object.values(CHAINS)) - it(`format(${namespace}, ${reference})`, async function () { - expect(await this.caip2.$format(namespace, reference)).to.equal(caip2); - }); - - for (const { namespace, reference, caip2 } of Object.values(CHAINS)) - it(`parse(${caip2})`, async function () { - expect(await this.caip2.$parse(caip2)).to.deep.equal([namespace, reference]); - }); - }); - - describe('CAIP-10', function () { - const { address: account } = ethers.Wallet.createRandom(); - - it(`local(${account})`, async function () { - const { caip10 } = await getLocalCAIP(account); - expect(await this.caip10.$local(ethers.Typed.address(account))).to.equal(caip10); - }); - - for (const { account, caip2, caip10 } of Object.values(CHAINS)) - it(`format(${caip2}, ${account})`, async function () { - expect(await this.caip10.$format(ethers.Typed.string(caip2), ethers.Typed.string(account))).to.equal(caip10); - }); - - for (const { account, caip2, caip10 } of Object.values(CHAINS)) - it(`parse(${caip10})`, async function () { - expect(await this.caip10.$parse(caip10)).to.deep.equal([caip2, account]); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Context.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Context.behavior.js deleted file mode 100644 index adb140fc15..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Context.behavior.js +++ /dev/null @@ -1,48 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -async function fixture() { - return { contextHelper: await ethers.deployContract('ContextMockCaller', []) }; -} -function shouldBehaveLikeRegularContext() { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('msgSender', function () { - it('returns the transaction sender when called from an EOA', async function () { - await expect(this.context.connect(this.sender).msgSender()).to.emit(this.context, 'Sender').withArgs(this.sender); - }); - - it('returns the transaction sender when called from another contract', async function () { - await expect(this.contextHelper.connect(this.sender).callSender(this.context)) - .to.emit(this.context, 'Sender') - .withArgs(this.contextHelper); - }); - }); - - describe('msgData', function () { - const args = [42n, 'OpenZeppelin']; - - it('returns the transaction data when called from an EOA', async function () { - const callData = this.context.interface.encodeFunctionData('msgData', args); - - await expect(this.context.msgData(...args)) - .to.emit(this.context, 'Data') - .withArgs(callData, ...args); - }); - - it('returns the transaction sender when from another contract', async function () { - const callData = this.context.interface.encodeFunctionData('msgData', args); - - await expect(this.contextHelper.callData(this.context, ...args)) - .to.emit(this.context, 'Data') - .withArgs(callData, ...args); - }); - }); -} - -module.exports = { - shouldBehaveLikeRegularContext, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Context.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Context.test.js deleted file mode 100644 index b766729e2f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Context.test.js +++ /dev/null @@ -1,18 +0,0 @@ -const { ethers } = require('hardhat'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { shouldBehaveLikeRegularContext } = require('./Context.behavior'); - -async function fixture() { - const [sender] = await ethers.getSigners(); - const context = await ethers.deployContract('ContextMock', []); - return { sender, context }; -} - -describe('Context', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeRegularContext(); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Create2.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Create2.t.sol deleted file mode 100644 index 6cc037a3b3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Create2.t.sol +++ /dev/null @@ -1,17 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {Create2} from "@openzeppelin/contracts/utils/Create2.sol"; - -contract Create2Test is Test { - function testSymbolicComputeAddressSpillage(bytes32 salt, bytes32 bytecodeHash, address deployer) public { - address predicted = Create2.computeAddress(salt, bytecodeHash, deployer); - bytes32 spillage; - assembly ("memory-safe") { - spillage := and(predicted, 0xffffffffffffffffffffffff0000000000000000000000000000000000000000) - } - assertEq(spillage, bytes32(0)); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Create2.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Create2.test.js deleted file mode 100644 index 99c47a0e34..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Create2.test.js +++ /dev/null @@ -1,190 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -const { RevertType } = require('../helpers/enums'); - -async function fixture() { - const [deployer, other] = await ethers.getSigners(); - - const factory = await ethers.deployContract('$Create2'); - - // Bytecode for deploying a contract that includes a constructor. - // We use a vesting wallet, with 3 constructor arguments. - const constructorByteCode = await ethers - .getContractFactory('VestingWallet') - .then(factory => ethers.concat([factory.bytecode, factory.interface.encodeDeploy([other.address, 0n, 0n])])); - - // Bytecode for deploying a contract that has no constructor log. - // Here we use the Create2 helper factory. - const constructorLessBytecode = await ethers - .getContractFactory('$Create2') - .then(factory => ethers.concat([factory.bytecode, factory.interface.encodeDeploy([])])); - - const mockFactory = await ethers.getContractFactory('ConstructorMock'); - - return { deployer, other, factory, constructorByteCode, constructorLessBytecode, mockFactory }; -} - -describe('Create2', function () { - const salt = 'salt message'; - const saltHex = ethers.id(salt); - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('computeAddress', function () { - it('computes the correct contract address', async function () { - const onChainComputed = await this.factory.$computeAddress(saltHex, ethers.keccak256(this.constructorByteCode)); - const offChainComputed = ethers.getCreate2Address( - this.factory.target, - saltHex, - ethers.keccak256(this.constructorByteCode), - ); - expect(onChainComputed).to.equal(offChainComputed); - }); - - it('computes the correct contract address with deployer', async function () { - const onChainComputed = await this.factory.$computeAddress( - saltHex, - ethers.keccak256(this.constructorByteCode), - ethers.Typed.address(this.deployer), - ); - const offChainComputed = ethers.getCreate2Address( - this.deployer.address, - saltHex, - ethers.keccak256(this.constructorByteCode), - ); - expect(onChainComputed).to.equal(offChainComputed); - }); - }); - - describe('deploy', function () { - it('deploys a contract without constructor', async function () { - const offChainComputed = ethers.getCreate2Address( - this.factory.target, - saltHex, - ethers.keccak256(this.constructorLessBytecode), - ); - - await expect(this.factory.$deploy(0n, saltHex, this.constructorLessBytecode)) - .to.emit(this.factory, 'return$deploy') - .withArgs(offChainComputed); - - expect(this.constructorLessBytecode).to.include((await ethers.provider.getCode(offChainComputed)).slice(2)); - }); - - it('deploys a contract with constructor arguments', async function () { - const offChainComputed = ethers.getCreate2Address( - this.factory.target, - saltHex, - ethers.keccak256(this.constructorByteCode), - ); - - await expect(this.factory.$deploy(0n, saltHex, this.constructorByteCode)) - .to.emit(this.factory, 'return$deploy') - .withArgs(offChainComputed); - - const instance = await ethers.getContractAt('VestingWallet', offChainComputed); - - expect(await instance.owner()).to.equal(this.other); - }); - - it('deploys a contract with funds deposited in the factory', async function () { - const value = 10n; - - await this.deployer.sendTransaction({ to: this.factory, value }); - - const offChainComputed = ethers.getCreate2Address( - this.factory.target, - saltHex, - ethers.keccak256(this.constructorByteCode), - ); - - expect(await ethers.provider.getBalance(this.factory)).to.equal(value); - expect(await ethers.provider.getBalance(offChainComputed)).to.equal(0n); - - await expect(this.factory.$deploy(value, saltHex, this.constructorByteCode)) - .to.emit(this.factory, 'return$deploy') - .withArgs(offChainComputed); - - expect(await ethers.provider.getBalance(this.factory)).to.equal(0n); - expect(await ethers.provider.getBalance(offChainComputed)).to.equal(value); - }); - - it('fails deploying a contract in an existent address', async function () { - await expect(this.factory.$deploy(0n, saltHex, this.constructorByteCode)).to.emit(this.factory, 'return$deploy'); - - await expect(this.factory.$deploy(0n, saltHex, this.constructorByteCode)).to.be.revertedWithCustomError( - this.factory, - 'FailedDeployment', - ); - }); - - it('fails deploying a contract if the bytecode length is zero', async function () { - await expect(this.factory.$deploy(0n, saltHex, '0x')).to.be.revertedWithCustomError( - this.factory, - 'Create2EmptyBytecode', - ); - }); - - it('fails deploying a contract if factory contract does not have sufficient balance', async function () { - await expect(this.factory.$deploy(1n, saltHex, this.constructorByteCode)) - .to.be.revertedWithCustomError(this.factory, 'InsufficientBalance') - .withArgs(0n, 1n); - }); - - describe('reverts error thrown during contract creation', function () { - it('bubbles up without message', async function () { - await expect( - this.factory.$deploy( - 0n, - saltHex, - ethers.concat([ - this.mockFactory.bytecode, - this.mockFactory.interface.encodeDeploy([RevertType.RevertWithoutMessage]), - ]), - ), - ).to.be.revertedWithCustomError(this.factory, 'FailedDeployment'); - }); - - it('bubbles up message', async function () { - await expect( - this.factory.$deploy( - 0n, - saltHex, - ethers.concat([ - this.mockFactory.bytecode, - this.mockFactory.interface.encodeDeploy([RevertType.RevertWithMessage]), - ]), - ), - ).to.be.revertedWith('ConstructorMock: reverting'); - }); - - it('bubbles up custom error', async function () { - await expect( - this.factory.$deploy( - 0n, - saltHex, - ethers.concat([ - this.mockFactory.bytecode, - this.mockFactory.interface.encodeDeploy([RevertType.RevertWithCustomError]), - ]), - ), - ).to.be.revertedWithCustomError({ interface: this.mockFactory.interface }, 'CustomError'); - }); - - it('bubbles up panic', async function () { - await expect( - this.factory.$deploy( - 0n, - saltHex, - ethers.concat([this.mockFactory.bytecode, this.mockFactory.interface.encodeDeploy([RevertType.Panic])]), - ), - ).to.be.revertedWithPanic(PANIC_CODES.DIVISION_BY_ZERO); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Multicall.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Multicall.test.js deleted file mode 100644 index 9c84e443a4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Multicall.test.js +++ /dev/null @@ -1,72 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -async function fixture() { - const [holder, alice, bruce] = await ethers.getSigners(); - - const amount = 12_000n; - const helper = await ethers.deployContract('MulticallHelper'); - const mock = await ethers.deployContract('$ERC20MulticallMock', ['name', 'symbol']); - await mock.$_mint(holder, amount); - - return { holder, alice, bruce, amount, mock, helper }; -} - -describe('Multicall', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('batches function calls', async function () { - expect(await this.mock.balanceOf(this.alice)).to.equal(0n); - expect(await this.mock.balanceOf(this.bruce)).to.equal(0n); - - await expect( - this.mock.multicall([ - this.mock.interface.encodeFunctionData('transfer', [this.alice.address, this.amount / 2n]), - this.mock.interface.encodeFunctionData('transfer', [this.bruce.address, this.amount / 3n]), - ]), - ) - .to.emit(this.mock, 'Transfer') - .withArgs(this.holder, this.alice, this.amount / 2n) - .to.emit(this.mock, 'Transfer') - .withArgs(this.holder, this.bruce, this.amount / 3n); - - expect(await this.mock.balanceOf(this.alice)).to.equal(this.amount / 2n); - expect(await this.mock.balanceOf(this.bruce)).to.equal(this.amount / 3n); - }); - - it('returns an array with the result of each call', async function () { - await this.mock.transfer(this.helper, this.amount); - expect(await this.mock.balanceOf(this.helper)).to.equal(this.amount); - - await this.helper.checkReturnValues(this.mock, [this.alice, this.bruce], [this.amount / 2n, this.amount / 3n]); - }); - - it('reverts previous calls', async function () { - expect(await this.mock.balanceOf(this.alice)).to.equal(0n); - - await expect( - this.mock.multicall([ - this.mock.interface.encodeFunctionData('transfer', [this.alice.address, this.amount]), - this.mock.interface.encodeFunctionData('transfer', [this.bruce.address, this.amount]), - ]), - ) - .to.be.revertedWithCustomError(this.mock, 'ERC20InsufficientBalance') - .withArgs(this.holder, 0, this.amount); - - expect(await this.mock.balanceOf(this.alice)).to.equal(0n); - }); - - it('bubbles up revert reasons', async function () { - await expect( - this.mock.multicall([ - this.mock.interface.encodeFunctionData('transfer', [this.alice.address, this.amount]), - this.mock.interface.encodeFunctionData('transfer', [this.bruce.address, this.amount]), - ]), - ) - .to.be.revertedWithCustomError(this.mock, 'ERC20InsufficientBalance') - .withArgs(this.holder, 0, this.amount); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Nonces.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Nonces.behavior.js deleted file mode 100644 index 32201f690d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Nonces.behavior.js +++ /dev/null @@ -1,189 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); - -function shouldBehaveLikeNonces() { - describe('should behave like Nonces', function () { - const sender = ethers.Wallet.createRandom(); - const other = ethers.Wallet.createRandom(); - - it('gets a nonce', async function () { - expect(this.mock.nonces(sender)).to.eventually.equal(0n); - }); - - describe('_useNonce', function () { - it('increments a nonce', async function () { - expect(this.mock.nonces(sender)).to.eventually.equal(0n); - - const eventName = ['return$_useNonce', 'return$_useNonce_address'].find(name => - this.mock.interface.getEvent(name), - ); - - await expect(this.mock.$_useNonce(sender)).to.emit(this.mock, eventName).withArgs(0n); - - expect(this.mock.nonces(sender)).to.eventually.equal(1n); - }); - - it("increments only sender's nonce", async function () { - expect(this.mock.nonces(sender)).to.eventually.equal(0n); - expect(this.mock.nonces(other)).to.eventually.equal(0n); - - await this.mock.$_useNonce(sender); - - expect(this.mock.nonces(sender)).to.eventually.equal(1n); - expect(this.mock.nonces(other)).to.eventually.equal(0n); - }); - }); - - describe('_useCheckedNonce', function () { - it('increments a nonce', async function () { - // current nonce is 0n - expect(this.mock.nonces(sender)).to.eventually.equal(0n); - - await this.mock.$_useCheckedNonce(sender, 0n); - - expect(this.mock.nonces(sender)).to.eventually.equal(1n); - }); - - it("increments only sender's nonce", async function () { - // current nonce is 0n - expect(this.mock.nonces(sender)).to.eventually.equal(0n); - expect(this.mock.nonces(other)).to.eventually.equal(0n); - - await this.mock.$_useCheckedNonce(sender, 0n); - - expect(this.mock.nonces(sender)).to.eventually.equal(1n); - expect(this.mock.nonces(other)).to.eventually.equal(0n); - }); - - it('reverts when nonce is not the expected', async function () { - const currentNonce = await this.mock.nonces(sender); - - await expect(this.mock.$_useCheckedNonce(sender, currentNonce + 1n)) - .to.be.revertedWithCustomError(this.mock, 'InvalidAccountNonce') - .withArgs(sender, currentNonce); - }); - }); - }); -} - -function shouldBehaveLikeNoncesKeyed() { - describe('should support nonces with keys', function () { - const sender = ethers.Wallet.createRandom(); - - const keyOffset = key => key << 64n; - - it('gets a nonce', async function () { - expect(this.mock.nonces(sender, ethers.Typed.uint192(0n))).to.eventually.equal(keyOffset(0n) + 0n); - expect(this.mock.nonces(sender, ethers.Typed.uint192(17n))).to.eventually.equal(keyOffset(17n) + 0n); - }); - - describe('_useNonce', function () { - it('default variant uses key 0', async function () { - expect(this.mock.nonces(sender, ethers.Typed.uint192(0n))).to.eventually.equal(keyOffset(0n) + 0n); - expect(this.mock.nonces(sender, ethers.Typed.uint192(17n))).to.eventually.equal(keyOffset(17n) + 0n); - - await expect(this.mock.$_useNonce(sender)).to.emit(this.mock, 'return$_useNonce_address').withArgs(0n); - - await expect(this.mock.$_useNonce(sender, ethers.Typed.uint192(0n))) - .to.emit(this.mock, 'return$_useNonce_address_uint192') - .withArgs(keyOffset(0n) + 1n); - - expect(this.mock.nonces(sender, ethers.Typed.uint192(0n))).to.eventually.equal(keyOffset(0n) + 2n); - expect(this.mock.nonces(sender, ethers.Typed.uint192(17n))).to.eventually.equal(keyOffset(17n) + 0n); - }); - - it('use nonce at another key', async function () { - expect(this.mock.nonces(sender, ethers.Typed.uint192(0n))).to.eventually.equal(keyOffset(0n) + 0n); - expect(this.mock.nonces(sender, ethers.Typed.uint192(17n))).to.eventually.equal(keyOffset(17n) + 0n); - - await expect(this.mock.$_useNonce(sender, ethers.Typed.uint192(17n))) - .to.emit(this.mock, 'return$_useNonce_address_uint192') - .withArgs(keyOffset(17n) + 0n); - - await expect(this.mock.$_useNonce(sender, ethers.Typed.uint192(17n))) - .to.emit(this.mock, 'return$_useNonce_address_uint192') - .withArgs(keyOffset(17n) + 1n); - - expect(this.mock.nonces(sender, ethers.Typed.uint192(0n))).to.eventually.equal(keyOffset(0n) + 0n); - expect(this.mock.nonces(sender, ethers.Typed.uint192(17n))).to.eventually.equal(keyOffset(17n) + 2n); - }); - }); - - describe('_useCheckedNonce(address, uint256)', function () { - it('default variant uses key 0', async function () { - const currentNonce = await this.mock.nonces(sender, ethers.Typed.uint192(0n)); - - await this.mock.$_useCheckedNonce(sender, currentNonce); - - expect(this.mock.nonces(sender, ethers.Typed.uint192(0n))).to.eventually.equal(currentNonce + 1n); - }); - - it('use nonce at another key', async function () { - const currentNonce = await this.mock.nonces(sender, ethers.Typed.uint192(17n)); - - await this.mock.$_useCheckedNonce(sender, currentNonce); - - expect(this.mock.nonces(sender, ethers.Typed.uint192(17n))).to.eventually.equal(currentNonce + 1n); - }); - - it('reverts when nonce is not the expected', async function () { - const currentNonce = await this.mock.nonces(sender, ethers.Typed.uint192(42n)); - - // use and increment - await this.mock.$_useCheckedNonce(sender, currentNonce); - - // reuse same nonce - await expect(this.mock.$_useCheckedNonce(sender, currentNonce)) - .to.be.revertedWithCustomError(this.mock, 'InvalidAccountNonce') - .withArgs(sender, currentNonce + 1n); - - // use "future" nonce too early - await expect(this.mock.$_useCheckedNonce(sender, currentNonce + 10n)) - .to.be.revertedWithCustomError(this.mock, 'InvalidAccountNonce') - .withArgs(sender, currentNonce + 1n); - }); - }); - - describe('_useCheckedNonce(address, uint192, uint64)', function () { - const MASK = 0xffffffffffffffffn; - - it('default variant uses key 0', async function () { - const currentNonce = await this.mock.nonces(sender, ethers.Typed.uint192(0n)); - - await this.mock.$_useCheckedNonce(sender, ethers.Typed.uint192(0n), currentNonce); - - expect(this.mock.nonces(sender, ethers.Typed.uint192(0n))).to.eventually.equal(currentNonce + 1n); - }); - - it('use nonce at another key', async function () { - const currentNonce = await this.mock.nonces(sender, ethers.Typed.uint192(17n)); - - await this.mock.$_useCheckedNonce(sender, ethers.Typed.uint192(17n), currentNonce & MASK); - - expect(this.mock.nonces(sender, ethers.Typed.uint192(17n))).to.eventually.equal(currentNonce + 1n); - }); - - it('reverts when nonce is not the expected', async function () { - const currentNonce = await this.mock.nonces(sender, ethers.Typed.uint192(42n)); - - // use and increment - await this.mock.$_useCheckedNonce(sender, ethers.Typed.uint192(42n), currentNonce & MASK); - - // reuse same nonce - await expect(this.mock.$_useCheckedNonce(sender, ethers.Typed.uint192(42n), currentNonce & MASK)) - .to.be.revertedWithCustomError(this.mock, 'InvalidAccountNonce') - .withArgs(sender, currentNonce + 1n); - - // use "future" nonce too early - await expect(this.mock.$_useCheckedNonce(sender, ethers.Typed.uint192(42n), (currentNonce & MASK) + 10n)) - .to.be.revertedWithCustomError(this.mock, 'InvalidAccountNonce') - .withArgs(sender, currentNonce + 1n); - }); - }); - }); -} - -module.exports = { - shouldBehaveLikeNonces, - shouldBehaveLikeNoncesKeyed, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Nonces.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Nonces.test.js deleted file mode 100644 index 85aa7358a0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Nonces.test.js +++ /dev/null @@ -1,16 +0,0 @@ -const { ethers } = require('hardhat'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { shouldBehaveLikeNonces } = require('./Nonces.behavior'); - -async function fixture() { - const mock = await ethers.deployContract('$Nonces'); - return { mock }; -} - -describe('Nonces', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeNonces(); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/NoncesKeyed.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/NoncesKeyed.test.js deleted file mode 100644 index c46948ee40..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/NoncesKeyed.test.js +++ /dev/null @@ -1,17 +0,0 @@ -const { ethers } = require('hardhat'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { shouldBehaveLikeNonces, shouldBehaveLikeNoncesKeyed } = require('./Nonces.behavior'); - -async function fixture() { - const mock = await ethers.deployContract('$NoncesKeyed'); - return { mock }; -} - -describe('NoncesKeyed', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldBehaveLikeNonces(); - shouldBehaveLikeNoncesKeyed(); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Packing.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Packing.t.sol deleted file mode 100644 index 40f052c80f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Packing.t.sol +++ /dev/null @@ -1,993 +0,0 @@ -// SPDX-License-Identifier: MIT -// This file was procedurally generated from scripts/generate/templates/Packing.t.js. - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {Packing} from "@openzeppelin/contracts/utils/Packing.sol"; - -contract PackingTest is Test { - using Packing for *; - - function testPack(bytes1 left, bytes1 right) external pure { - assertEq(left, Packing.pack_1_1(left, right).extract_2_1(0)); - assertEq(right, Packing.pack_1_1(left, right).extract_2_1(1)); - } - - function testPack(bytes2 left, bytes2 right) external pure { - assertEq(left, Packing.pack_2_2(left, right).extract_4_2(0)); - assertEq(right, Packing.pack_2_2(left, right).extract_4_2(2)); - } - - function testPack(bytes2 left, bytes4 right) external pure { - assertEq(left, Packing.pack_2_4(left, right).extract_6_2(0)); - assertEq(right, Packing.pack_2_4(left, right).extract_6_4(2)); - } - - function testPack(bytes2 left, bytes6 right) external pure { - assertEq(left, Packing.pack_2_6(left, right).extract_8_2(0)); - assertEq(right, Packing.pack_2_6(left, right).extract_8_6(2)); - } - - function testPack(bytes2 left, bytes8 right) external pure { - assertEq(left, Packing.pack_2_8(left, right).extract_10_2(0)); - assertEq(right, Packing.pack_2_8(left, right).extract_10_8(2)); - } - - function testPack(bytes2 left, bytes10 right) external pure { - assertEq(left, Packing.pack_2_10(left, right).extract_12_2(0)); - assertEq(right, Packing.pack_2_10(left, right).extract_12_10(2)); - } - - function testPack(bytes2 left, bytes20 right) external pure { - assertEq(left, Packing.pack_2_20(left, right).extract_22_2(0)); - assertEq(right, Packing.pack_2_20(left, right).extract_22_20(2)); - } - - function testPack(bytes2 left, bytes22 right) external pure { - assertEq(left, Packing.pack_2_22(left, right).extract_24_2(0)); - assertEq(right, Packing.pack_2_22(left, right).extract_24_22(2)); - } - - function testPack(bytes4 left, bytes2 right) external pure { - assertEq(left, Packing.pack_4_2(left, right).extract_6_4(0)); - assertEq(right, Packing.pack_4_2(left, right).extract_6_2(4)); - } - - function testPack(bytes4 left, bytes4 right) external pure { - assertEq(left, Packing.pack_4_4(left, right).extract_8_4(0)); - assertEq(right, Packing.pack_4_4(left, right).extract_8_4(4)); - } - - function testPack(bytes4 left, bytes6 right) external pure { - assertEq(left, Packing.pack_4_6(left, right).extract_10_4(0)); - assertEq(right, Packing.pack_4_6(left, right).extract_10_6(4)); - } - - function testPack(bytes4 left, bytes8 right) external pure { - assertEq(left, Packing.pack_4_8(left, right).extract_12_4(0)); - assertEq(right, Packing.pack_4_8(left, right).extract_12_8(4)); - } - - function testPack(bytes4 left, bytes12 right) external pure { - assertEq(left, Packing.pack_4_12(left, right).extract_16_4(0)); - assertEq(right, Packing.pack_4_12(left, right).extract_16_12(4)); - } - - function testPack(bytes4 left, bytes16 right) external pure { - assertEq(left, Packing.pack_4_16(left, right).extract_20_4(0)); - assertEq(right, Packing.pack_4_16(left, right).extract_20_16(4)); - } - - function testPack(bytes4 left, bytes20 right) external pure { - assertEq(left, Packing.pack_4_20(left, right).extract_24_4(0)); - assertEq(right, Packing.pack_4_20(left, right).extract_24_20(4)); - } - - function testPack(bytes4 left, bytes24 right) external pure { - assertEq(left, Packing.pack_4_24(left, right).extract_28_4(0)); - assertEq(right, Packing.pack_4_24(left, right).extract_28_24(4)); - } - - function testPack(bytes4 left, bytes28 right) external pure { - assertEq(left, Packing.pack_4_28(left, right).extract_32_4(0)); - assertEq(right, Packing.pack_4_28(left, right).extract_32_28(4)); - } - - function testPack(bytes6 left, bytes2 right) external pure { - assertEq(left, Packing.pack_6_2(left, right).extract_8_6(0)); - assertEq(right, Packing.pack_6_2(left, right).extract_8_2(6)); - } - - function testPack(bytes6 left, bytes4 right) external pure { - assertEq(left, Packing.pack_6_4(left, right).extract_10_6(0)); - assertEq(right, Packing.pack_6_4(left, right).extract_10_4(6)); - } - - function testPack(bytes6 left, bytes6 right) external pure { - assertEq(left, Packing.pack_6_6(left, right).extract_12_6(0)); - assertEq(right, Packing.pack_6_6(left, right).extract_12_6(6)); - } - - function testPack(bytes6 left, bytes10 right) external pure { - assertEq(left, Packing.pack_6_10(left, right).extract_16_6(0)); - assertEq(right, Packing.pack_6_10(left, right).extract_16_10(6)); - } - - function testPack(bytes6 left, bytes16 right) external pure { - assertEq(left, Packing.pack_6_16(left, right).extract_22_6(0)); - assertEq(right, Packing.pack_6_16(left, right).extract_22_16(6)); - } - - function testPack(bytes6 left, bytes22 right) external pure { - assertEq(left, Packing.pack_6_22(left, right).extract_28_6(0)); - assertEq(right, Packing.pack_6_22(left, right).extract_28_22(6)); - } - - function testPack(bytes8 left, bytes2 right) external pure { - assertEq(left, Packing.pack_8_2(left, right).extract_10_8(0)); - assertEq(right, Packing.pack_8_2(left, right).extract_10_2(8)); - } - - function testPack(bytes8 left, bytes4 right) external pure { - assertEq(left, Packing.pack_8_4(left, right).extract_12_8(0)); - assertEq(right, Packing.pack_8_4(left, right).extract_12_4(8)); - } - - function testPack(bytes8 left, bytes8 right) external pure { - assertEq(left, Packing.pack_8_8(left, right).extract_16_8(0)); - assertEq(right, Packing.pack_8_8(left, right).extract_16_8(8)); - } - - function testPack(bytes8 left, bytes12 right) external pure { - assertEq(left, Packing.pack_8_12(left, right).extract_20_8(0)); - assertEq(right, Packing.pack_8_12(left, right).extract_20_12(8)); - } - - function testPack(bytes8 left, bytes16 right) external pure { - assertEq(left, Packing.pack_8_16(left, right).extract_24_8(0)); - assertEq(right, Packing.pack_8_16(left, right).extract_24_16(8)); - } - - function testPack(bytes8 left, bytes20 right) external pure { - assertEq(left, Packing.pack_8_20(left, right).extract_28_8(0)); - assertEq(right, Packing.pack_8_20(left, right).extract_28_20(8)); - } - - function testPack(bytes8 left, bytes24 right) external pure { - assertEq(left, Packing.pack_8_24(left, right).extract_32_8(0)); - assertEq(right, Packing.pack_8_24(left, right).extract_32_24(8)); - } - - function testPack(bytes10 left, bytes2 right) external pure { - assertEq(left, Packing.pack_10_2(left, right).extract_12_10(0)); - assertEq(right, Packing.pack_10_2(left, right).extract_12_2(10)); - } - - function testPack(bytes10 left, bytes6 right) external pure { - assertEq(left, Packing.pack_10_6(left, right).extract_16_10(0)); - assertEq(right, Packing.pack_10_6(left, right).extract_16_6(10)); - } - - function testPack(bytes10 left, bytes10 right) external pure { - assertEq(left, Packing.pack_10_10(left, right).extract_20_10(0)); - assertEq(right, Packing.pack_10_10(left, right).extract_20_10(10)); - } - - function testPack(bytes10 left, bytes12 right) external pure { - assertEq(left, Packing.pack_10_12(left, right).extract_22_10(0)); - assertEq(right, Packing.pack_10_12(left, right).extract_22_12(10)); - } - - function testPack(bytes10 left, bytes22 right) external pure { - assertEq(left, Packing.pack_10_22(left, right).extract_32_10(0)); - assertEq(right, Packing.pack_10_22(left, right).extract_32_22(10)); - } - - function testPack(bytes12 left, bytes4 right) external pure { - assertEq(left, Packing.pack_12_4(left, right).extract_16_12(0)); - assertEq(right, Packing.pack_12_4(left, right).extract_16_4(12)); - } - - function testPack(bytes12 left, bytes8 right) external pure { - assertEq(left, Packing.pack_12_8(left, right).extract_20_12(0)); - assertEq(right, Packing.pack_12_8(left, right).extract_20_8(12)); - } - - function testPack(bytes12 left, bytes10 right) external pure { - assertEq(left, Packing.pack_12_10(left, right).extract_22_12(0)); - assertEq(right, Packing.pack_12_10(left, right).extract_22_10(12)); - } - - function testPack(bytes12 left, bytes12 right) external pure { - assertEq(left, Packing.pack_12_12(left, right).extract_24_12(0)); - assertEq(right, Packing.pack_12_12(left, right).extract_24_12(12)); - } - - function testPack(bytes12 left, bytes16 right) external pure { - assertEq(left, Packing.pack_12_16(left, right).extract_28_12(0)); - assertEq(right, Packing.pack_12_16(left, right).extract_28_16(12)); - } - - function testPack(bytes12 left, bytes20 right) external pure { - assertEq(left, Packing.pack_12_20(left, right).extract_32_12(0)); - assertEq(right, Packing.pack_12_20(left, right).extract_32_20(12)); - } - - function testPack(bytes16 left, bytes4 right) external pure { - assertEq(left, Packing.pack_16_4(left, right).extract_20_16(0)); - assertEq(right, Packing.pack_16_4(left, right).extract_20_4(16)); - } - - function testPack(bytes16 left, bytes6 right) external pure { - assertEq(left, Packing.pack_16_6(left, right).extract_22_16(0)); - assertEq(right, Packing.pack_16_6(left, right).extract_22_6(16)); - } - - function testPack(bytes16 left, bytes8 right) external pure { - assertEq(left, Packing.pack_16_8(left, right).extract_24_16(0)); - assertEq(right, Packing.pack_16_8(left, right).extract_24_8(16)); - } - - function testPack(bytes16 left, bytes12 right) external pure { - assertEq(left, Packing.pack_16_12(left, right).extract_28_16(0)); - assertEq(right, Packing.pack_16_12(left, right).extract_28_12(16)); - } - - function testPack(bytes16 left, bytes16 right) external pure { - assertEq(left, Packing.pack_16_16(left, right).extract_32_16(0)); - assertEq(right, Packing.pack_16_16(left, right).extract_32_16(16)); - } - - function testPack(bytes20 left, bytes2 right) external pure { - assertEq(left, Packing.pack_20_2(left, right).extract_22_20(0)); - assertEq(right, Packing.pack_20_2(left, right).extract_22_2(20)); - } - - function testPack(bytes20 left, bytes4 right) external pure { - assertEq(left, Packing.pack_20_4(left, right).extract_24_20(0)); - assertEq(right, Packing.pack_20_4(left, right).extract_24_4(20)); - } - - function testPack(bytes20 left, bytes8 right) external pure { - assertEq(left, Packing.pack_20_8(left, right).extract_28_20(0)); - assertEq(right, Packing.pack_20_8(left, right).extract_28_8(20)); - } - - function testPack(bytes20 left, bytes12 right) external pure { - assertEq(left, Packing.pack_20_12(left, right).extract_32_20(0)); - assertEq(right, Packing.pack_20_12(left, right).extract_32_12(20)); - } - - function testPack(bytes22 left, bytes2 right) external pure { - assertEq(left, Packing.pack_22_2(left, right).extract_24_22(0)); - assertEq(right, Packing.pack_22_2(left, right).extract_24_2(22)); - } - - function testPack(bytes22 left, bytes6 right) external pure { - assertEq(left, Packing.pack_22_6(left, right).extract_28_22(0)); - assertEq(right, Packing.pack_22_6(left, right).extract_28_6(22)); - } - - function testPack(bytes22 left, bytes10 right) external pure { - assertEq(left, Packing.pack_22_10(left, right).extract_32_22(0)); - assertEq(right, Packing.pack_22_10(left, right).extract_32_10(22)); - } - - function testPack(bytes24 left, bytes4 right) external pure { - assertEq(left, Packing.pack_24_4(left, right).extract_28_24(0)); - assertEq(right, Packing.pack_24_4(left, right).extract_28_4(24)); - } - - function testPack(bytes24 left, bytes8 right) external pure { - assertEq(left, Packing.pack_24_8(left, right).extract_32_24(0)); - assertEq(right, Packing.pack_24_8(left, right).extract_32_8(24)); - } - - function testPack(bytes28 left, bytes4 right) external pure { - assertEq(left, Packing.pack_28_4(left, right).extract_32_28(0)); - assertEq(right, Packing.pack_28_4(left, right).extract_32_4(28)); - } - - function testReplace(bytes2 container, bytes1 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 1)); - - bytes1 oldValue = container.extract_2_1(offset); - - assertEq(newValue, container.replace_2_1(newValue, offset).extract_2_1(offset)); - assertEq(container, container.replace_2_1(newValue, offset).replace_2_1(oldValue, offset)); - } - - function testReplace(bytes4 container, bytes1 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 3)); - - bytes1 oldValue = container.extract_4_1(offset); - - assertEq(newValue, container.replace_4_1(newValue, offset).extract_4_1(offset)); - assertEq(container, container.replace_4_1(newValue, offset).replace_4_1(oldValue, offset)); - } - - function testReplace(bytes4 container, bytes2 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 2)); - - bytes2 oldValue = container.extract_4_2(offset); - - assertEq(newValue, container.replace_4_2(newValue, offset).extract_4_2(offset)); - assertEq(container, container.replace_4_2(newValue, offset).replace_4_2(oldValue, offset)); - } - - function testReplace(bytes6 container, bytes1 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 5)); - - bytes1 oldValue = container.extract_6_1(offset); - - assertEq(newValue, container.replace_6_1(newValue, offset).extract_6_1(offset)); - assertEq(container, container.replace_6_1(newValue, offset).replace_6_1(oldValue, offset)); - } - - function testReplace(bytes6 container, bytes2 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 4)); - - bytes2 oldValue = container.extract_6_2(offset); - - assertEq(newValue, container.replace_6_2(newValue, offset).extract_6_2(offset)); - assertEq(container, container.replace_6_2(newValue, offset).replace_6_2(oldValue, offset)); - } - - function testReplace(bytes6 container, bytes4 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 2)); - - bytes4 oldValue = container.extract_6_4(offset); - - assertEq(newValue, container.replace_6_4(newValue, offset).extract_6_4(offset)); - assertEq(container, container.replace_6_4(newValue, offset).replace_6_4(oldValue, offset)); - } - - function testReplace(bytes8 container, bytes1 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 7)); - - bytes1 oldValue = container.extract_8_1(offset); - - assertEq(newValue, container.replace_8_1(newValue, offset).extract_8_1(offset)); - assertEq(container, container.replace_8_1(newValue, offset).replace_8_1(oldValue, offset)); - } - - function testReplace(bytes8 container, bytes2 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 6)); - - bytes2 oldValue = container.extract_8_2(offset); - - assertEq(newValue, container.replace_8_2(newValue, offset).extract_8_2(offset)); - assertEq(container, container.replace_8_2(newValue, offset).replace_8_2(oldValue, offset)); - } - - function testReplace(bytes8 container, bytes4 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 4)); - - bytes4 oldValue = container.extract_8_4(offset); - - assertEq(newValue, container.replace_8_4(newValue, offset).extract_8_4(offset)); - assertEq(container, container.replace_8_4(newValue, offset).replace_8_4(oldValue, offset)); - } - - function testReplace(bytes8 container, bytes6 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 2)); - - bytes6 oldValue = container.extract_8_6(offset); - - assertEq(newValue, container.replace_8_6(newValue, offset).extract_8_6(offset)); - assertEq(container, container.replace_8_6(newValue, offset).replace_8_6(oldValue, offset)); - } - - function testReplace(bytes10 container, bytes1 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 9)); - - bytes1 oldValue = container.extract_10_1(offset); - - assertEq(newValue, container.replace_10_1(newValue, offset).extract_10_1(offset)); - assertEq(container, container.replace_10_1(newValue, offset).replace_10_1(oldValue, offset)); - } - - function testReplace(bytes10 container, bytes2 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 8)); - - bytes2 oldValue = container.extract_10_2(offset); - - assertEq(newValue, container.replace_10_2(newValue, offset).extract_10_2(offset)); - assertEq(container, container.replace_10_2(newValue, offset).replace_10_2(oldValue, offset)); - } - - function testReplace(bytes10 container, bytes4 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 6)); - - bytes4 oldValue = container.extract_10_4(offset); - - assertEq(newValue, container.replace_10_4(newValue, offset).extract_10_4(offset)); - assertEq(container, container.replace_10_4(newValue, offset).replace_10_4(oldValue, offset)); - } - - function testReplace(bytes10 container, bytes6 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 4)); - - bytes6 oldValue = container.extract_10_6(offset); - - assertEq(newValue, container.replace_10_6(newValue, offset).extract_10_6(offset)); - assertEq(container, container.replace_10_6(newValue, offset).replace_10_6(oldValue, offset)); - } - - function testReplace(bytes10 container, bytes8 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 2)); - - bytes8 oldValue = container.extract_10_8(offset); - - assertEq(newValue, container.replace_10_8(newValue, offset).extract_10_8(offset)); - assertEq(container, container.replace_10_8(newValue, offset).replace_10_8(oldValue, offset)); - } - - function testReplace(bytes12 container, bytes1 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 11)); - - bytes1 oldValue = container.extract_12_1(offset); - - assertEq(newValue, container.replace_12_1(newValue, offset).extract_12_1(offset)); - assertEq(container, container.replace_12_1(newValue, offset).replace_12_1(oldValue, offset)); - } - - function testReplace(bytes12 container, bytes2 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 10)); - - bytes2 oldValue = container.extract_12_2(offset); - - assertEq(newValue, container.replace_12_2(newValue, offset).extract_12_2(offset)); - assertEq(container, container.replace_12_2(newValue, offset).replace_12_2(oldValue, offset)); - } - - function testReplace(bytes12 container, bytes4 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 8)); - - bytes4 oldValue = container.extract_12_4(offset); - - assertEq(newValue, container.replace_12_4(newValue, offset).extract_12_4(offset)); - assertEq(container, container.replace_12_4(newValue, offset).replace_12_4(oldValue, offset)); - } - - function testReplace(bytes12 container, bytes6 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 6)); - - bytes6 oldValue = container.extract_12_6(offset); - - assertEq(newValue, container.replace_12_6(newValue, offset).extract_12_6(offset)); - assertEq(container, container.replace_12_6(newValue, offset).replace_12_6(oldValue, offset)); - } - - function testReplace(bytes12 container, bytes8 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 4)); - - bytes8 oldValue = container.extract_12_8(offset); - - assertEq(newValue, container.replace_12_8(newValue, offset).extract_12_8(offset)); - assertEq(container, container.replace_12_8(newValue, offset).replace_12_8(oldValue, offset)); - } - - function testReplace(bytes12 container, bytes10 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 2)); - - bytes10 oldValue = container.extract_12_10(offset); - - assertEq(newValue, container.replace_12_10(newValue, offset).extract_12_10(offset)); - assertEq(container, container.replace_12_10(newValue, offset).replace_12_10(oldValue, offset)); - } - - function testReplace(bytes16 container, bytes1 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 15)); - - bytes1 oldValue = container.extract_16_1(offset); - - assertEq(newValue, container.replace_16_1(newValue, offset).extract_16_1(offset)); - assertEq(container, container.replace_16_1(newValue, offset).replace_16_1(oldValue, offset)); - } - - function testReplace(bytes16 container, bytes2 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 14)); - - bytes2 oldValue = container.extract_16_2(offset); - - assertEq(newValue, container.replace_16_2(newValue, offset).extract_16_2(offset)); - assertEq(container, container.replace_16_2(newValue, offset).replace_16_2(oldValue, offset)); - } - - function testReplace(bytes16 container, bytes4 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 12)); - - bytes4 oldValue = container.extract_16_4(offset); - - assertEq(newValue, container.replace_16_4(newValue, offset).extract_16_4(offset)); - assertEq(container, container.replace_16_4(newValue, offset).replace_16_4(oldValue, offset)); - } - - function testReplace(bytes16 container, bytes6 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 10)); - - bytes6 oldValue = container.extract_16_6(offset); - - assertEq(newValue, container.replace_16_6(newValue, offset).extract_16_6(offset)); - assertEq(container, container.replace_16_6(newValue, offset).replace_16_6(oldValue, offset)); - } - - function testReplace(bytes16 container, bytes8 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 8)); - - bytes8 oldValue = container.extract_16_8(offset); - - assertEq(newValue, container.replace_16_8(newValue, offset).extract_16_8(offset)); - assertEq(container, container.replace_16_8(newValue, offset).replace_16_8(oldValue, offset)); - } - - function testReplace(bytes16 container, bytes10 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 6)); - - bytes10 oldValue = container.extract_16_10(offset); - - assertEq(newValue, container.replace_16_10(newValue, offset).extract_16_10(offset)); - assertEq(container, container.replace_16_10(newValue, offset).replace_16_10(oldValue, offset)); - } - - function testReplace(bytes16 container, bytes12 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 4)); - - bytes12 oldValue = container.extract_16_12(offset); - - assertEq(newValue, container.replace_16_12(newValue, offset).extract_16_12(offset)); - assertEq(container, container.replace_16_12(newValue, offset).replace_16_12(oldValue, offset)); - } - - function testReplace(bytes20 container, bytes1 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 19)); - - bytes1 oldValue = container.extract_20_1(offset); - - assertEq(newValue, container.replace_20_1(newValue, offset).extract_20_1(offset)); - assertEq(container, container.replace_20_1(newValue, offset).replace_20_1(oldValue, offset)); - } - - function testReplace(bytes20 container, bytes2 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 18)); - - bytes2 oldValue = container.extract_20_2(offset); - - assertEq(newValue, container.replace_20_2(newValue, offset).extract_20_2(offset)); - assertEq(container, container.replace_20_2(newValue, offset).replace_20_2(oldValue, offset)); - } - - function testReplace(bytes20 container, bytes4 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 16)); - - bytes4 oldValue = container.extract_20_4(offset); - - assertEq(newValue, container.replace_20_4(newValue, offset).extract_20_4(offset)); - assertEq(container, container.replace_20_4(newValue, offset).replace_20_4(oldValue, offset)); - } - - function testReplace(bytes20 container, bytes6 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 14)); - - bytes6 oldValue = container.extract_20_6(offset); - - assertEq(newValue, container.replace_20_6(newValue, offset).extract_20_6(offset)); - assertEq(container, container.replace_20_6(newValue, offset).replace_20_6(oldValue, offset)); - } - - function testReplace(bytes20 container, bytes8 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 12)); - - bytes8 oldValue = container.extract_20_8(offset); - - assertEq(newValue, container.replace_20_8(newValue, offset).extract_20_8(offset)); - assertEq(container, container.replace_20_8(newValue, offset).replace_20_8(oldValue, offset)); - } - - function testReplace(bytes20 container, bytes10 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 10)); - - bytes10 oldValue = container.extract_20_10(offset); - - assertEq(newValue, container.replace_20_10(newValue, offset).extract_20_10(offset)); - assertEq(container, container.replace_20_10(newValue, offset).replace_20_10(oldValue, offset)); - } - - function testReplace(bytes20 container, bytes12 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 8)); - - bytes12 oldValue = container.extract_20_12(offset); - - assertEq(newValue, container.replace_20_12(newValue, offset).extract_20_12(offset)); - assertEq(container, container.replace_20_12(newValue, offset).replace_20_12(oldValue, offset)); - } - - function testReplace(bytes20 container, bytes16 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 4)); - - bytes16 oldValue = container.extract_20_16(offset); - - assertEq(newValue, container.replace_20_16(newValue, offset).extract_20_16(offset)); - assertEq(container, container.replace_20_16(newValue, offset).replace_20_16(oldValue, offset)); - } - - function testReplace(bytes22 container, bytes1 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 21)); - - bytes1 oldValue = container.extract_22_1(offset); - - assertEq(newValue, container.replace_22_1(newValue, offset).extract_22_1(offset)); - assertEq(container, container.replace_22_1(newValue, offset).replace_22_1(oldValue, offset)); - } - - function testReplace(bytes22 container, bytes2 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 20)); - - bytes2 oldValue = container.extract_22_2(offset); - - assertEq(newValue, container.replace_22_2(newValue, offset).extract_22_2(offset)); - assertEq(container, container.replace_22_2(newValue, offset).replace_22_2(oldValue, offset)); - } - - function testReplace(bytes22 container, bytes4 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 18)); - - bytes4 oldValue = container.extract_22_4(offset); - - assertEq(newValue, container.replace_22_4(newValue, offset).extract_22_4(offset)); - assertEq(container, container.replace_22_4(newValue, offset).replace_22_4(oldValue, offset)); - } - - function testReplace(bytes22 container, bytes6 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 16)); - - bytes6 oldValue = container.extract_22_6(offset); - - assertEq(newValue, container.replace_22_6(newValue, offset).extract_22_6(offset)); - assertEq(container, container.replace_22_6(newValue, offset).replace_22_6(oldValue, offset)); - } - - function testReplace(bytes22 container, bytes8 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 14)); - - bytes8 oldValue = container.extract_22_8(offset); - - assertEq(newValue, container.replace_22_8(newValue, offset).extract_22_8(offset)); - assertEq(container, container.replace_22_8(newValue, offset).replace_22_8(oldValue, offset)); - } - - function testReplace(bytes22 container, bytes10 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 12)); - - bytes10 oldValue = container.extract_22_10(offset); - - assertEq(newValue, container.replace_22_10(newValue, offset).extract_22_10(offset)); - assertEq(container, container.replace_22_10(newValue, offset).replace_22_10(oldValue, offset)); - } - - function testReplace(bytes22 container, bytes12 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 10)); - - bytes12 oldValue = container.extract_22_12(offset); - - assertEq(newValue, container.replace_22_12(newValue, offset).extract_22_12(offset)); - assertEq(container, container.replace_22_12(newValue, offset).replace_22_12(oldValue, offset)); - } - - function testReplace(bytes22 container, bytes16 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 6)); - - bytes16 oldValue = container.extract_22_16(offset); - - assertEq(newValue, container.replace_22_16(newValue, offset).extract_22_16(offset)); - assertEq(container, container.replace_22_16(newValue, offset).replace_22_16(oldValue, offset)); - } - - function testReplace(bytes22 container, bytes20 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 2)); - - bytes20 oldValue = container.extract_22_20(offset); - - assertEq(newValue, container.replace_22_20(newValue, offset).extract_22_20(offset)); - assertEq(container, container.replace_22_20(newValue, offset).replace_22_20(oldValue, offset)); - } - - function testReplace(bytes24 container, bytes1 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 23)); - - bytes1 oldValue = container.extract_24_1(offset); - - assertEq(newValue, container.replace_24_1(newValue, offset).extract_24_1(offset)); - assertEq(container, container.replace_24_1(newValue, offset).replace_24_1(oldValue, offset)); - } - - function testReplace(bytes24 container, bytes2 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 22)); - - bytes2 oldValue = container.extract_24_2(offset); - - assertEq(newValue, container.replace_24_2(newValue, offset).extract_24_2(offset)); - assertEq(container, container.replace_24_2(newValue, offset).replace_24_2(oldValue, offset)); - } - - function testReplace(bytes24 container, bytes4 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 20)); - - bytes4 oldValue = container.extract_24_4(offset); - - assertEq(newValue, container.replace_24_4(newValue, offset).extract_24_4(offset)); - assertEq(container, container.replace_24_4(newValue, offset).replace_24_4(oldValue, offset)); - } - - function testReplace(bytes24 container, bytes6 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 18)); - - bytes6 oldValue = container.extract_24_6(offset); - - assertEq(newValue, container.replace_24_6(newValue, offset).extract_24_6(offset)); - assertEq(container, container.replace_24_6(newValue, offset).replace_24_6(oldValue, offset)); - } - - function testReplace(bytes24 container, bytes8 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 16)); - - bytes8 oldValue = container.extract_24_8(offset); - - assertEq(newValue, container.replace_24_8(newValue, offset).extract_24_8(offset)); - assertEq(container, container.replace_24_8(newValue, offset).replace_24_8(oldValue, offset)); - } - - function testReplace(bytes24 container, bytes10 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 14)); - - bytes10 oldValue = container.extract_24_10(offset); - - assertEq(newValue, container.replace_24_10(newValue, offset).extract_24_10(offset)); - assertEq(container, container.replace_24_10(newValue, offset).replace_24_10(oldValue, offset)); - } - - function testReplace(bytes24 container, bytes12 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 12)); - - bytes12 oldValue = container.extract_24_12(offset); - - assertEq(newValue, container.replace_24_12(newValue, offset).extract_24_12(offset)); - assertEq(container, container.replace_24_12(newValue, offset).replace_24_12(oldValue, offset)); - } - - function testReplace(bytes24 container, bytes16 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 8)); - - bytes16 oldValue = container.extract_24_16(offset); - - assertEq(newValue, container.replace_24_16(newValue, offset).extract_24_16(offset)); - assertEq(container, container.replace_24_16(newValue, offset).replace_24_16(oldValue, offset)); - } - - function testReplace(bytes24 container, bytes20 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 4)); - - bytes20 oldValue = container.extract_24_20(offset); - - assertEq(newValue, container.replace_24_20(newValue, offset).extract_24_20(offset)); - assertEq(container, container.replace_24_20(newValue, offset).replace_24_20(oldValue, offset)); - } - - function testReplace(bytes24 container, bytes22 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 2)); - - bytes22 oldValue = container.extract_24_22(offset); - - assertEq(newValue, container.replace_24_22(newValue, offset).extract_24_22(offset)); - assertEq(container, container.replace_24_22(newValue, offset).replace_24_22(oldValue, offset)); - } - - function testReplace(bytes28 container, bytes1 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 27)); - - bytes1 oldValue = container.extract_28_1(offset); - - assertEq(newValue, container.replace_28_1(newValue, offset).extract_28_1(offset)); - assertEq(container, container.replace_28_1(newValue, offset).replace_28_1(oldValue, offset)); - } - - function testReplace(bytes28 container, bytes2 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 26)); - - bytes2 oldValue = container.extract_28_2(offset); - - assertEq(newValue, container.replace_28_2(newValue, offset).extract_28_2(offset)); - assertEq(container, container.replace_28_2(newValue, offset).replace_28_2(oldValue, offset)); - } - - function testReplace(bytes28 container, bytes4 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 24)); - - bytes4 oldValue = container.extract_28_4(offset); - - assertEq(newValue, container.replace_28_4(newValue, offset).extract_28_4(offset)); - assertEq(container, container.replace_28_4(newValue, offset).replace_28_4(oldValue, offset)); - } - - function testReplace(bytes28 container, bytes6 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 22)); - - bytes6 oldValue = container.extract_28_6(offset); - - assertEq(newValue, container.replace_28_6(newValue, offset).extract_28_6(offset)); - assertEq(container, container.replace_28_6(newValue, offset).replace_28_6(oldValue, offset)); - } - - function testReplace(bytes28 container, bytes8 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 20)); - - bytes8 oldValue = container.extract_28_8(offset); - - assertEq(newValue, container.replace_28_8(newValue, offset).extract_28_8(offset)); - assertEq(container, container.replace_28_8(newValue, offset).replace_28_8(oldValue, offset)); - } - - function testReplace(bytes28 container, bytes10 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 18)); - - bytes10 oldValue = container.extract_28_10(offset); - - assertEq(newValue, container.replace_28_10(newValue, offset).extract_28_10(offset)); - assertEq(container, container.replace_28_10(newValue, offset).replace_28_10(oldValue, offset)); - } - - function testReplace(bytes28 container, bytes12 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 16)); - - bytes12 oldValue = container.extract_28_12(offset); - - assertEq(newValue, container.replace_28_12(newValue, offset).extract_28_12(offset)); - assertEq(container, container.replace_28_12(newValue, offset).replace_28_12(oldValue, offset)); - } - - function testReplace(bytes28 container, bytes16 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 12)); - - bytes16 oldValue = container.extract_28_16(offset); - - assertEq(newValue, container.replace_28_16(newValue, offset).extract_28_16(offset)); - assertEq(container, container.replace_28_16(newValue, offset).replace_28_16(oldValue, offset)); - } - - function testReplace(bytes28 container, bytes20 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 8)); - - bytes20 oldValue = container.extract_28_20(offset); - - assertEq(newValue, container.replace_28_20(newValue, offset).extract_28_20(offset)); - assertEq(container, container.replace_28_20(newValue, offset).replace_28_20(oldValue, offset)); - } - - function testReplace(bytes28 container, bytes22 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 6)); - - bytes22 oldValue = container.extract_28_22(offset); - - assertEq(newValue, container.replace_28_22(newValue, offset).extract_28_22(offset)); - assertEq(container, container.replace_28_22(newValue, offset).replace_28_22(oldValue, offset)); - } - - function testReplace(bytes28 container, bytes24 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 4)); - - bytes24 oldValue = container.extract_28_24(offset); - - assertEq(newValue, container.replace_28_24(newValue, offset).extract_28_24(offset)); - assertEq(container, container.replace_28_24(newValue, offset).replace_28_24(oldValue, offset)); - } - - function testReplace(bytes32 container, bytes1 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 31)); - - bytes1 oldValue = container.extract_32_1(offset); - - assertEq(newValue, container.replace_32_1(newValue, offset).extract_32_1(offset)); - assertEq(container, container.replace_32_1(newValue, offset).replace_32_1(oldValue, offset)); - } - - function testReplace(bytes32 container, bytes2 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 30)); - - bytes2 oldValue = container.extract_32_2(offset); - - assertEq(newValue, container.replace_32_2(newValue, offset).extract_32_2(offset)); - assertEq(container, container.replace_32_2(newValue, offset).replace_32_2(oldValue, offset)); - } - - function testReplace(bytes32 container, bytes4 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 28)); - - bytes4 oldValue = container.extract_32_4(offset); - - assertEq(newValue, container.replace_32_4(newValue, offset).extract_32_4(offset)); - assertEq(container, container.replace_32_4(newValue, offset).replace_32_4(oldValue, offset)); - } - - function testReplace(bytes32 container, bytes6 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 26)); - - bytes6 oldValue = container.extract_32_6(offset); - - assertEq(newValue, container.replace_32_6(newValue, offset).extract_32_6(offset)); - assertEq(container, container.replace_32_6(newValue, offset).replace_32_6(oldValue, offset)); - } - - function testReplace(bytes32 container, bytes8 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 24)); - - bytes8 oldValue = container.extract_32_8(offset); - - assertEq(newValue, container.replace_32_8(newValue, offset).extract_32_8(offset)); - assertEq(container, container.replace_32_8(newValue, offset).replace_32_8(oldValue, offset)); - } - - function testReplace(bytes32 container, bytes10 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 22)); - - bytes10 oldValue = container.extract_32_10(offset); - - assertEq(newValue, container.replace_32_10(newValue, offset).extract_32_10(offset)); - assertEq(container, container.replace_32_10(newValue, offset).replace_32_10(oldValue, offset)); - } - - function testReplace(bytes32 container, bytes12 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 20)); - - bytes12 oldValue = container.extract_32_12(offset); - - assertEq(newValue, container.replace_32_12(newValue, offset).extract_32_12(offset)); - assertEq(container, container.replace_32_12(newValue, offset).replace_32_12(oldValue, offset)); - } - - function testReplace(bytes32 container, bytes16 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 16)); - - bytes16 oldValue = container.extract_32_16(offset); - - assertEq(newValue, container.replace_32_16(newValue, offset).extract_32_16(offset)); - assertEq(container, container.replace_32_16(newValue, offset).replace_32_16(oldValue, offset)); - } - - function testReplace(bytes32 container, bytes20 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 12)); - - bytes20 oldValue = container.extract_32_20(offset); - - assertEq(newValue, container.replace_32_20(newValue, offset).extract_32_20(offset)); - assertEq(container, container.replace_32_20(newValue, offset).replace_32_20(oldValue, offset)); - } - - function testReplace(bytes32 container, bytes22 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 10)); - - bytes22 oldValue = container.extract_32_22(offset); - - assertEq(newValue, container.replace_32_22(newValue, offset).extract_32_22(offset)); - assertEq(container, container.replace_32_22(newValue, offset).replace_32_22(oldValue, offset)); - } - - function testReplace(bytes32 container, bytes24 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 8)); - - bytes24 oldValue = container.extract_32_24(offset); - - assertEq(newValue, container.replace_32_24(newValue, offset).extract_32_24(offset)); - assertEq(container, container.replace_32_24(newValue, offset).replace_32_24(oldValue, offset)); - } - - function testReplace(bytes32 container, bytes28 newValue, uint8 offset) external pure { - offset = uint8(bound(offset, 0, 4)); - - bytes28 oldValue = container.extract_32_28(offset); - - assertEq(newValue, container.replace_32_28(newValue, offset).extract_32_28(offset)); - assertEq(container, container.replace_32_28(newValue, offset).replace_32_28(oldValue, offset)); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Packing.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Packing.test.js deleted file mode 100644 index dd36f45d77..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Packing.test.js +++ /dev/null @@ -1,70 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { forceDeployCode } = require('../helpers/deploy'); -const { product } = require('../helpers/iterate'); -const { SIZES } = require('../../scripts/generate/templates/Packing.opts'); - -async function fixture() { - return { mock: await forceDeployCode('$Packing') }; -} - -describe('Packing', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('pack', function () { - for (const [size1, size2] of product(SIZES, SIZES).filter(([size1, size2]) => SIZES.includes(size1 + size2))) { - const value1 = ethers.hexlify(ethers.randomBytes(size1)); - const value2 = ethers.hexlify(ethers.randomBytes(size2)); - const packed = ethers.concat([value1, value2]); - - it(`pack bytes${size1} + bytes${size2} => bytes${size1 + size2}`, async function () { - expect(await this.mock[`$pack_${size1}_${size2}`](value1, value2)).to.equal(packed); - expect(await this.mock[`$extract_${size1 + size2}_${size1}`](packed, 0)).to.equal(value1); - expect(await this.mock[`$extract_${size1 + size2}_${size2}`](packed, size1)).to.equal(value2); - }); - } - }); - - describe('extract / replace', function () { - for (const [size1, size2] of product(SIZES, SIZES).filter(([size1, size2]) => size1 > size2)) { - const MAX_OFFSET = size1 - size2; - const offset = ethers.toNumber(ethers.randomBytes(1)) % (MAX_OFFSET + 1); - const outer = ethers.randomBytes(size1); - const value = ethers.randomBytes(size2); - - it(`extract bytes${size2} from bytes${size1}`, async function () { - expect(await this.mock[`$extract_${size1}_${size2}`](outer, offset)).to.equal( - ethers.hexlify(outer.slice(offset, offset + size2)), - ); - - await expect(this.mock[`$extract_${size1}_${size2}`](outer, MAX_OFFSET)).to.not.be.revertedWithCustomError( - this.mock, - 'OutOfRangeAccess', - ); - - await expect(this.mock[`$extract_${size1}_${size2}`](outer, MAX_OFFSET + 1)).to.be.revertedWithCustomError( - this.mock, - 'OutOfRangeAccess', - ); - }); - - it(`replace bytes${size2} from bytes${size1}`, async function () { - expect(await this.mock[`$replace_${size1}_${size2}`](outer, value, offset)).to.equal( - ethers.concat([outer.slice(0, offset), value, outer.slice(offset + size2)]), - ); - - await expect( - this.mock[`$replace_${size1}_${size2}`](outer, value, MAX_OFFSET), - ).to.not.be.revertedWithCustomError(this.mock, 'OutOfRangeAccess'); - - await expect( - this.mock[`$replace_${size1}_${size2}`](outer, value, MAX_OFFSET + 1), - ).to.be.revertedWithCustomError(this.mock, 'OutOfRangeAccess'); - }); - } - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Panic.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Panic.test.js deleted file mode 100644 index 49673c751c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Panic.test.js +++ /dev/null @@ -1,37 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -async function fixture() { - return { mock: await ethers.deployContract('$Panic') }; -} - -describe('Panic', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - for (const [name, code] of Object.entries({ - GENERIC: 0x0, - ASSERT: PANIC_CODES.ASSERTION_ERROR, - UNDER_OVERFLOW: PANIC_CODES.ARITHMETIC_OVERFLOW, - DIVISION_BY_ZERO: PANIC_CODES.DIVISION_BY_ZERO, - ENUM_CONVERSION_ERROR: PANIC_CODES.ENUM_CONVERSION_OUT_OF_BOUNDS, - STORAGE_ENCODING_ERROR: PANIC_CODES.INCORRECTLY_ENCODED_STORAGE_BYTE_ARRAY, - EMPTY_ARRAY_POP: PANIC_CODES.POP_ON_EMPTY_ARRAY, - ARRAY_OUT_OF_BOUNDS: PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS, - RESOURCE_ERROR: PANIC_CODES.TOO_MUCH_MEMORY_ALLOCATED, - INVALID_INTERNAL_FUNCTION: PANIC_CODES.ZERO_INITIALIZED_VARIABLE, - })) { - describe(`${name} (${ethers.toBeHex(code)})`, function () { - it('exposes panic code as constant', async function () { - expect(await this.mock.getFunction(`$${name}`)()).to.equal(code); - }); - - it('reverts with panic when called', async function () { - await expect(this.mock.$panic(code)).to.be.revertedWithPanic(code); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Pausable.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Pausable.test.js deleted file mode 100644 index 67d74a0d88..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Pausable.test.js +++ /dev/null @@ -1,90 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -async function fixture() { - const [pauser] = await ethers.getSigners(); - - const mock = await ethers.deployContract('PausableMock'); - - return { pauser, mock }; -} - -describe('Pausable', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('when unpaused', function () { - beforeEach(async function () { - expect(await this.mock.paused()).to.be.false; - }); - - it('can perform normal process in non-pause', async function () { - expect(await this.mock.count()).to.equal(0n); - - await this.mock.normalProcess(); - expect(await this.mock.count()).to.equal(1n); - }); - - it('cannot take drastic measure in non-pause', async function () { - await expect(this.mock.drasticMeasure()).to.be.revertedWithCustomError(this.mock, 'ExpectedPause'); - - expect(await this.mock.drasticMeasureTaken()).to.be.false; - }); - - describe('when paused', function () { - beforeEach(async function () { - this.tx = await this.mock.pause(); - }); - - it('emits a Paused event', async function () { - await expect(this.tx).to.emit(this.mock, 'Paused').withArgs(this.pauser); - }); - - it('cannot perform normal process in pause', async function () { - await expect(this.mock.normalProcess()).to.be.revertedWithCustomError(this.mock, 'EnforcedPause'); - }); - - it('can take a drastic measure in a pause', async function () { - await this.mock.drasticMeasure(); - expect(await this.mock.drasticMeasureTaken()).to.be.true; - }); - - it('reverts when re-pausing', async function () { - await expect(this.mock.pause()).to.be.revertedWithCustomError(this.mock, 'EnforcedPause'); - }); - - describe('unpausing', function () { - it('is unpausable by the pauser', async function () { - await this.mock.unpause(); - expect(await this.mock.paused()).to.be.false; - }); - - describe('when unpaused', function () { - beforeEach(async function () { - this.tx = await this.mock.unpause(); - }); - - it('emits an Unpaused event', async function () { - await expect(this.tx).to.emit(this.mock, 'Unpaused').withArgs(this.pauser); - }); - - it('should resume allowing normal process', async function () { - expect(await this.mock.count()).to.equal(0n); - await this.mock.normalProcess(); - expect(await this.mock.count()).to.equal(1n); - }); - - it('should prevent drastic measure', async function () { - await expect(this.mock.drasticMeasure()).to.be.revertedWithCustomError(this.mock, 'ExpectedPause'); - }); - - it('reverts when re-unpausing', async function () { - await expect(this.mock.unpause()).to.be.revertedWithCustomError(this.mock, 'ExpectedPause'); - }); - }); - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/ReentrancyGuard.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/ReentrancyGuard.test.js deleted file mode 100644 index c4418563eb..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/ReentrancyGuard.test.js +++ /dev/null @@ -1,50 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -for (const variant of ['', 'Transient']) { - describe(`Reentrancy${variant}Guard`, function () { - async function fixture() { - const name = `Reentrancy${variant}Mock`; - const mock = await ethers.deployContract(name); - return { name, mock }; - } - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('nonReentrant function can be called', async function () { - expect(await this.mock.counter()).to.equal(0n); - await this.mock.callback(); - expect(await this.mock.counter()).to.equal(1n); - }); - - it('does not allow remote callback', async function () { - const attacker = await ethers.deployContract('ReentrancyAttack'); - await expect(this.mock.countAndCall(attacker)).to.be.revertedWith('ReentrancyAttack: failed call'); - }); - - it('_reentrancyGuardEntered should be true when guarded', async function () { - await this.mock.guardedCheckEntered(); - }); - - it('_reentrancyGuardEntered should be false when unguarded', async function () { - await this.mock.unguardedCheckNotEntered(); - }); - - // The following are more side-effects than intended behavior: - // I put them here as documentation, and to monitor any changes - // in the side-effects. - it('does not allow local recursion', async function () { - await expect(this.mock.countLocalRecursive(10n)).to.be.revertedWithCustomError( - this.mock, - 'ReentrancyGuardReentrantCall', - ); - }); - - it('does not allow indirect local recursion', async function () { - await expect(this.mock.countThisRecursive(10n)).to.be.revertedWith(`${this.name}: failed call`); - }); - }); -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/ShortStrings.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/ShortStrings.t.sol deleted file mode 100644 index 4aeafd721a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/ShortStrings.t.sol +++ /dev/null @@ -1,109 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {SymTest} from "halmos-cheatcodes/SymTest.sol"; - -import {ShortStrings, ShortString} from "@openzeppelin/contracts/utils/ShortStrings.sol"; - -contract ShortStringsTest is Test, SymTest { - string _fallback; - - function testRoundtripShort(string memory input) external { - vm.assume(_isShort(input)); - _assertRoundtripShort(input); - } - - function symbolicRoundtripShort() external { - string memory input = svm.createString(31, "RoundtripShortInput"); - _assertRoundtripShort(input); - } - - function testRoundtripWithFallback(string memory input, string memory fallbackInitial) external { - _assertRoundtripWithFallback(input, fallbackInitial); - } - - function symbolicRoundtripWithFallbackLong() external { - string memory input = svm.createString(256, "RoundtripWithFallbackInput"); - string memory fallbackInitial = svm.createString(256, "RoundtripWithFallbackFallbackInitial"); - _assertRoundtripWithFallback(input, fallbackInitial); - } - - function symbolicRoundtripWithFallbackShort() external { - string memory input = svm.createString(31, "RoundtripWithFallbackInput"); - string memory fallbackInitial = svm.createString(31, "RoundtripWithFallbackFallbackInitial"); - _assertRoundtripWithFallback(input, fallbackInitial); - } - - function testRevertLong(string memory input) external { - vm.assume(!_isShort(input)); - _assertRevertLong(input); - } - - function testLengthShort(string memory input) external { - vm.assume(_isShort(input)); - _assertLengthShort(input); - } - - function symbolicLengthShort() external { - string memory input = svm.createString(31, "LengthShortInput"); - _assertLengthShort(input); - } - - function testLengthWithFallback(string memory input, string memory fallbackInitial) external { - _fallback = fallbackInitial; - _assertLengthWithFallback(input); - } - - function symbolicLengthWithFallback() external { - uint256 length = 256; - string memory input = svm.createString(length, "LengthWithFallbackInput"); - string memory fallbackInitial = svm.createString(length, "LengthWithFallbackFallbackInitial"); - _fallback = fallbackInitial; - _assertLengthWithFallback(input); - } - - /// Assertions - - function _assertRoundtripShort(string memory input) internal { - ShortString short = ShortStrings.toShortString(input); - string memory output = ShortStrings.toString(short); - assertEq(input, output); - } - - function _assertRoundtripWithFallback(string memory input, string memory fallbackInitial) internal { - _fallback = fallbackInitial; // Make sure that the initial value has no effect - ShortString short = ShortStrings.toShortStringWithFallback(input, _fallback); - string memory output = ShortStrings.toStringWithFallback(short, _fallback); - assertEq(input, output); - } - - function _assertRevertLong(string memory input) internal { - vm.expectRevert(abi.encodeWithSelector(ShortStrings.StringTooLong.selector, input)); - this.toShortString(input); - } - - function _assertLengthShort(string memory input) internal { - ShortString short = ShortStrings.toShortString(input); - uint256 shortLength = ShortStrings.byteLength(short); - uint256 inputLength = bytes(input).length; - assertEq(inputLength, shortLength); - } - - function _assertLengthWithFallback(string memory input) internal { - uint256 inputLength = bytes(input).length; - ShortString short = ShortStrings.toShortStringWithFallback(input, _fallback); - uint256 shortLength = ShortStrings.byteLengthWithFallback(short, _fallback); - assertEq(inputLength, shortLength); - } - - /// Helpers - function toShortString(string memory input) external pure returns (ShortString) { - return ShortStrings.toShortString(input); - } - - function _isShort(string memory input) internal pure returns (bool) { - return bytes(input).length < 32; - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/ShortStrings.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/ShortStrings.test.js deleted file mode 100644 index cb1a06aa5c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/ShortStrings.test.js +++ /dev/null @@ -1,64 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const FALLBACK_SENTINEL = ethers.zeroPadValue('0xFF', 32); - -const length = sstr => parseInt(sstr.slice(64), 16); -const decode = sstr => ethers.toUtf8String(sstr).slice(0, length(sstr)); -const encode = str => - str.length < 32 - ? ethers.concat([ - ethers.encodeBytes32String(str).slice(0, -2), - ethers.zeroPadValue(ethers.toBeArray(str.length), 1), - ]) - : FALLBACK_SENTINEL; - -async function fixture() { - const mock = await ethers.deployContract('$ShortStrings'); - return { mock }; -} - -describe('ShortStrings', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - for (const str of [0, 1, 16, 31, 32, 64, 1024].map(length => 'a'.repeat(length))) { - describe(`with string length ${str.length}`, function () { - it('encode / decode', async function () { - if (str.length < 32) { - const encoded = await this.mock.$toShortString(str); - expect(encoded).to.equal(encode(str)); - expect(decode(encoded)).to.equal(str); - - expect(await this.mock.$byteLength(encoded)).to.equal(str.length); - expect(await this.mock.$toString(encoded)).to.equal(str); - } else { - await expect(this.mock.$toShortString(str)) - .to.be.revertedWithCustomError(this.mock, 'StringTooLong') - .withArgs(str); - } - }); - - it('set / get with fallback', async function () { - const short = await this.mock - .$toShortStringWithFallback(str, 0) - .then(tx => tx.wait()) - .then(receipt => receipt.logs.find(ev => ev.fragment.name == 'return$toShortStringWithFallback').args[0]); - - expect(short).to.equal(encode(str)); - - const promise = this.mock.$toString(short); - if (str.length < 32) { - expect(await promise).to.equal(str); - } else { - await expect(promise).to.be.revertedWithCustomError(this.mock, 'InvalidShortString'); - } - - expect(await this.mock.$byteLengthWithFallback(short, 0)).to.equal(str.length); - expect(await this.mock.$toStringWithFallback(short, 0)).to.equal(str); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/SlotDerivation.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/SlotDerivation.t.sol deleted file mode 100644 index 4021f0f879..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/SlotDerivation.t.sol +++ /dev/null @@ -1,248 +0,0 @@ -// SPDX-License-Identifier: MIT -// This file was procedurally generated from scripts/generate/templates/SlotDerivation.t.js. - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {SymTest} from "halmos-cheatcodes/SymTest.sol"; -import {SlotDerivation} from "@openzeppelin/contracts/utils/SlotDerivation.sol"; - -contract SlotDerivationTest is Test, SymTest { - using SlotDerivation for bytes32; - - bytes[] private _array; - - function symbolicDeriveArray(uint256 length, uint256 offset) public { - vm.assume(length > 0); - vm.assume(offset < length); - _assertDeriveArray(length, offset); - } - - function testDeriveArray(uint256 length, uint256 offset) public { - length = bound(length, 1, type(uint256).max); - offset = bound(offset, 0, length - 1); - _assertDeriveArray(length, offset); - } - - function _assertDeriveArray(uint256 length, uint256 offset) public { - bytes32 baseSlot; - assembly { - baseSlot := _array.slot - sstore(baseSlot, length) // store length so solidity access does not revert - } - - bytes storage derived = _array[offset]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveArray().offset(offset), derivedSlot); - } - - mapping(address => bytes) private _addressMapping; - - function testSymbolicDeriveMappingAddress(address key) public { - bytes32 baseSlot; - assembly { - baseSlot := _addressMapping.slot - } - - bytes storage derived = _addressMapping[key]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveMapping(key), derivedSlot); - } - - mapping(bool => bytes) private _boolMapping; - - function testSymbolicDeriveMappingBoolean(bool key) public { - bytes32 baseSlot; - assembly { - baseSlot := _boolMapping.slot - } - - bytes storage derived = _boolMapping[key]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveMapping(key), derivedSlot); - } - - mapping(bytes32 => bytes) private _bytes32Mapping; - - function testSymbolicDeriveMappingBytes32(bytes32 key) public { - bytes32 baseSlot; - assembly { - baseSlot := _bytes32Mapping.slot - } - - bytes storage derived = _bytes32Mapping[key]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveMapping(key), derivedSlot); - } - - mapping(bytes4 => bytes) private _bytes4Mapping; - - function testSymbolicDeriveMappingBytes4(bytes4 key) public { - bytes32 baseSlot; - assembly { - baseSlot := _bytes4Mapping.slot - } - - bytes storage derived = _bytes4Mapping[key]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveMapping(key), derivedSlot); - } - - mapping(uint256 => bytes) private _uint256Mapping; - - function testSymbolicDeriveMappingUint256(uint256 key) public { - bytes32 baseSlot; - assembly { - baseSlot := _uint256Mapping.slot - } - - bytes storage derived = _uint256Mapping[key]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveMapping(key), derivedSlot); - } - - mapping(uint32 => bytes) private _uint32Mapping; - - function testSymbolicDeriveMappingUint32(uint32 key) public { - bytes32 baseSlot; - assembly { - baseSlot := _uint32Mapping.slot - } - - bytes storage derived = _uint32Mapping[key]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveMapping(key), derivedSlot); - } - - mapping(int256 => bytes) private _int256Mapping; - - function testSymbolicDeriveMappingInt256(int256 key) public { - bytes32 baseSlot; - assembly { - baseSlot := _int256Mapping.slot - } - - bytes storage derived = _int256Mapping[key]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveMapping(key), derivedSlot); - } - - mapping(int32 => bytes) private _int32Mapping; - - function testSymbolicDeriveMappingInt32(int32 key) public { - bytes32 baseSlot; - assembly { - baseSlot := _int32Mapping.slot - } - - bytes storage derived = _int32Mapping[key]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveMapping(key), derivedSlot); - } - - mapping(string => bytes) private _stringMapping; - - function testDeriveMappingString(string memory key) public { - _assertDeriveMappingString(key); - } - - function symbolicDeriveMappingString() public { - _assertDeriveMappingString(svm.createString(256, "DeriveMappingStringInput")); - } - - function _assertDeriveMappingString(string memory key) internal { - bytes32 baseSlot; - assembly { - baseSlot := _stringMapping.slot - } - - bytes storage derived = _stringMapping[key]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveMapping(key), derivedSlot); - } - - mapping(bytes => bytes) private _bytesMapping; - - function testDeriveMappingBytes(bytes memory key) public { - _assertDeriveMappingBytes(key); - } - - function symbolicDeriveMappingBytes() public { - _assertDeriveMappingBytes(svm.createBytes(256, "DeriveMappingBytesInput")); - } - - function _assertDeriveMappingBytes(bytes memory key) internal { - bytes32 baseSlot; - assembly { - baseSlot := _bytesMapping.slot - } - - bytes storage derived = _bytesMapping[key]; - bytes32 derivedSlot; - assembly { - derivedSlot := derived.slot - } - - assertEq(baseSlot.deriveMapping(key), derivedSlot); - } - - function testSymbolicDeriveMappingBooleanDirty(bytes32 dirtyKey) public { - bool key; - assembly { - key := dirtyKey - } - - // run the "normal" test using a potentially dirty value - testSymbolicDeriveMappingBoolean(key); - } - - function testSymbolicDeriveMappingAddressDirty(bytes32 dirtyKey) public { - address key; - assembly { - key := dirtyKey - } - - // run the "normal" test using a potentially dirty value - testSymbolicDeriveMappingAddress(key); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/SlotDerivation.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/SlotDerivation.test.js deleted file mode 100644 index 22582b3757..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/SlotDerivation.test.js +++ /dev/null @@ -1,58 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { erc7201Slot } = require('../helpers/storage'); -const { generators } = require('../helpers/random'); - -async function fixture() { - const [account] = await ethers.getSigners(); - const mock = await ethers.deployContract('$SlotDerivation'); - return { mock, account }; -} - -describe('SlotDerivation', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('namespaces', function () { - const namespace = 'example.main'; - - it('erc-7201', async function () { - expect(await this.mock.$erc7201Slot(namespace)).to.equal(erc7201Slot(namespace)); - }); - }); - - describe('derivation', function () { - it('offset', async function () { - const base = generators.bytes32(); - const offset = generators.uint256(); - expect(await this.mock.$offset(base, offset)).to.equal((ethers.toBigInt(base) + offset) & ethers.MaxUint256); - }); - - it('array', async function () { - const base = generators.bytes32(); - expect(await this.mock.$deriveArray(base)).to.equal(ethers.keccak256(base)); - }); - - describe('mapping', function () { - for (const { type, key, isValueType } of [ - { type: 'bool', key: true, isValueType: true }, - { type: 'address', key: generators.address(), isValueType: true }, - { type: 'bytes32', key: generators.bytes32(), isValueType: true }, - { type: 'uint256', key: generators.uint256(), isValueType: true }, - { type: 'int256', key: generators.int256(), isValueType: true }, - { type: 'bytes', key: generators.hexBytes(128), isValueType: false }, - { type: 'string', key: 'lorem ipsum', isValueType: false }, - ]) { - it(type, async function () { - const base = generators.bytes32(); - const expected = isValueType - ? ethers.keccak256(ethers.AbiCoder.defaultAbiCoder().encode([type, 'bytes32'], [key, base])) - : ethers.solidityPackedKeccak256([type, 'bytes32'], [key, base]); - expect(await this.mock[`$deriveMapping(bytes32,${type})`](base, key)).to.equal(expected); - }); - } - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/StorageSlot.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/StorageSlot.test.js deleted file mode 100644 index ddcf305d1a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/StorageSlot.test.js +++ /dev/null @@ -1,73 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { generators } = require('../helpers/random'); - -const slot = ethers.id('some.storage.slot'); -const otherSlot = ethers.id('some.other.storage.slot'); - -const TYPES = [ - { name: 'Boolean', type: 'bool', value: true, isValueType: true, zero: false }, - { name: 'Address', type: 'address', value: generators.address(), isValueType: true, zero: generators.address.zero }, - { name: 'Bytes32', type: 'bytes32', value: generators.bytes32(), isValueType: true, zero: generators.bytes32.zero }, - { name: 'Uint256', type: 'uint256', value: generators.uint256(), isValueType: true, zero: generators.uint256.zero }, - { name: 'Int256', type: 'int256', value: generators.int256(), isValueType: true, zero: generators.int256.zero }, - { name: 'Bytes', type: 'bytes', value: generators.hexBytes(128), isValueType: false, zero: generators.hexBytes.zero }, - { name: 'String', type: 'string', value: 'lorem ipsum', isValueType: false, zero: '' }, -]; - -async function fixture() { - return { mock: await ethers.deployContract('StorageSlotMock') }; -} - -describe('StorageSlot', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - for (const { name, type, value, zero } of TYPES) { - describe(`${type} storage slot`, function () { - it('set', async function () { - await this.mock.getFunction(`set${name}Slot`)(slot, value); - }); - - describe('get', function () { - beforeEach(async function () { - await this.mock.getFunction(`set${name}Slot`)(slot, value); - }); - - it('from right slot', async function () { - expect(await this.mock.getFunction(`get${name}Slot`)(slot)).to.equal(value); - }); - - it('from other slot', async function () { - expect(await this.mock.getFunction(`get${name}Slot`)(otherSlot)).to.equal(zero); - }); - }); - }); - } - - for (const { name, type, value, zero } of TYPES.filter(type => !type.isValueType)) { - describe(`${type} storage pointer`, function () { - it('set', async function () { - await this.mock.getFunction(`set${name}Storage`)(slot, value); - }); - - describe('get', function () { - beforeEach(async function () { - await this.mock.getFunction(`set${name}Storage`)(slot, value); - }); - - it('from right slot', async function () { - expect(await this.mock.getFunction(`${type}Map`)(slot)).to.equal(value); - expect(await this.mock.getFunction(`get${name}Storage`)(slot)).to.equal(value); - }); - - it('from other slot', async function () { - expect(await this.mock.getFunction(`${type}Map`)(otherSlot)).to.equal(zero); - expect(await this.mock.getFunction(`get${name}Storage`)(otherSlot)).to.equal(zero); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Strings.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Strings.t.sol deleted file mode 100644 index f59e675cd3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Strings.t.sol +++ /dev/null @@ -1,50 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; - -import {Strings} from "@openzeppelin/contracts/utils/Strings.sol"; - -contract StringsTest is Test { - using Strings for *; - - function testParse(uint256 value) external { - assertEq(value, value.toString().parseUint()); - } - - function testParseSigned(int256 value) external { - assertEq(value, value.toStringSigned().parseInt()); - } - - function testParseHex(uint256 value) external { - assertEq(value, value.toHexString().parseHexUint()); - } - - function testParseChecksumHex(address value) external { - assertEq(value, value.toChecksumHexString().parseAddress()); - } - - function testTryParseHexUintExtendedEnd(string memory random) external pure { - uint256 length = bytes(random).length; - assembly ("memory-safe") { - mstore(add(add(random, 0x20), length), 0x3030303030303030303030303030303030303030303030303030303030303030) - } - - (bool success, ) = random.tryParseHexUint(1, length + 1); - assertFalse(success); - } - - function testTryParseAddressExtendedEnd(address random, uint256 begin) external pure { - begin = bound(begin, 3, 43); - string memory input = random.toHexString(); - uint256 length = bytes(input).length; - - assembly ("memory-safe") { - mstore(add(add(input, 0x20), length), 0x3030303030303030303030303030303030303030303030303030303030303030) - } - - (bool success, ) = input.tryParseAddress(begin, begin + 40); - assertFalse(success); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Strings.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Strings.test.js deleted file mode 100644 index 0b2d87190d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/Strings.test.js +++ /dev/null @@ -1,342 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -async function fixture() { - const mock = await ethers.deployContract('$Strings'); - return { mock }; -} - -describe('Strings', function () { - before(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('toString', function () { - const values = [ - 0n, - 7n, - 10n, - 99n, - 100n, - 101n, - 123n, - 4132n, - 12345n, - 1234567n, - 1234567890n, - 123456789012345n, - 12345678901234567890n, - 123456789012345678901234567890n, - 1234567890123456789012345678901234567890n, - 12345678901234567890123456789012345678901234567890n, - 123456789012345678901234567890123456789012345678901234567890n, - 1234567890123456789012345678901234567890123456789012345678901234567890n, - ]; - - describe('uint256', function () { - it('converts MAX_UINT256', async function () { - const value = ethers.MaxUint256; - expect(await this.mock.$toString(value)).to.equal(value.toString(10)); - expect(await this.mock.$parseUint(value.toString(10))).to.equal(value); - expect(await this.mock.$tryParseUint(value.toString(10))).to.deep.equal([true, value]); - }); - - for (const value of values) { - it(`converts ${value}`, async function () { - expect(await this.mock.$toString(value)).to.equal(value.toString(10)); - expect(await this.mock.$parseUint(value.toString(10))).to.equal(value); - expect(await this.mock.$tryParseUint(value.toString(10))).to.deep.equal([true, value]); - }); - } - }); - - describe('int256', function () { - it('converts MAX_INT256', async function () { - const value = ethers.MaxInt256; - expect(await this.mock.$toStringSigned(value)).to.equal(value.toString(10)); - expect(await this.mock.$parseInt(value.toString(10))).to.equal(value); - expect(await this.mock.$tryParseInt(value.toString(10))).to.deep.equal([true, value]); - }); - - it('converts MIN_INT256', async function () { - const value = ethers.MinInt256; - expect(await this.mock.$toStringSigned(value)).to.equal(value.toString(10)); - expect(await this.mock.$parseInt(value.toString(10))).to.equal(value); - expect(await this.mock.$tryParseInt(value.toString(10))).to.deep.equal([true, value]); - }); - - for (const value of values) { - it(`convert ${value}`, async function () { - expect(await this.mock.$toStringSigned(value)).to.equal(value.toString(10)); - expect(await this.mock.$parseInt(value.toString(10))).to.equal(value); - expect(await this.mock.$tryParseInt(value.toString(10))).to.deep.equal([true, value]); - }); - - it(`convert negative ${value}`, async function () { - const negated = -value; - expect(await this.mock.$toStringSigned(negated)).to.equal(negated.toString(10)); - expect(await this.mock.$parseInt(negated.toString(10))).to.equal(negated); - expect(await this.mock.$tryParseInt(negated.toString(10))).to.deep.equal([true, negated]); - }); - } - }); - }); - - describe('toHexString', function () { - it('converts 0', async function () { - const value = 0n; - const string = ethers.toBeHex(value); // 0x00 - - expect(await this.mock.getFunction('$toHexString(uint256)')(value)).to.equal(string); - expect(await this.mock.$parseHexUint(string)).to.equal(value); - expect(await this.mock.$parseHexUint(string.replace(/0x/, ''))).to.equal(value); - expect(await this.mock.$tryParseHexUint(string)).to.deep.equal([true, value]); - expect(await this.mock.$tryParseHexUint(string.replace(/0x/, ''))).to.deep.equal([true, value]); - }); - - it('converts a positive number', async function () { - const value = 0x4132n; - const string = ethers.toBeHex(value); - - expect(await this.mock.getFunction('$toHexString(uint256)')(value)).to.equal(string); - expect(await this.mock.$parseHexUint(string)).to.equal(value); - expect(await this.mock.$parseHexUint(string.replace(/0x/, ''))).to.equal(value); - expect(await this.mock.$tryParseHexUint(string)).to.deep.equal([true, value]); - expect(await this.mock.$tryParseHexUint(string.replace(/0x/, ''))).to.deep.equal([true, value]); - }); - - it('converts MAX_UINT256', async function () { - const value = ethers.MaxUint256; - const string = ethers.toBeHex(value); - - expect(await this.mock.getFunction('$toHexString(uint256)')(value)).to.equal(string); - expect(await this.mock.$parseHexUint(string)).to.equal(value); - expect(await this.mock.$parseHexUint(string.replace(/0x/, ''))).to.equal(value); - expect(await this.mock.$tryParseHexUint(string)).to.deep.equal([true, value]); - expect(await this.mock.$tryParseHexUint(string.replace(/0x/, ''))).to.deep.equal([true, value]); - }); - }); - - describe('toHexString fixed', function () { - it('converts a positive number (long)', async function () { - expect(await this.mock.getFunction('$toHexString(uint256,uint256)')(0x4132n, 32n)).to.equal( - '0x0000000000000000000000000000000000000000000000000000000000004132', - ); - }); - - it('converts a positive number (short)', async function () { - const length = 1n; - await expect(this.mock.getFunction('$toHexString(uint256,uint256)')(0x4132n, length)) - .to.be.revertedWithCustomError(this.mock, 'StringsInsufficientHexLength') - .withArgs(0x4132, length); - }); - - it('converts MAX_UINT256', async function () { - expect(await this.mock.getFunction('$toHexString(uint256,uint256)')(ethers.MaxUint256, 32n)).to.equal( - ethers.toBeHex(ethers.MaxUint256), - ); - }); - }); - - describe('addresses', function () { - const addresses = [ - '0xa9036907dccae6a1e0033479b12e837e5cf5a02f', // Random address - '0x0000e0ca771e21bd00057f54a68c30d400000000', // Leading and trailing zeros - // EIP-55 reference - '0x5aAeb6053F3E94C9b9A09f33669435E7Ef1BeAed', - '0xfB6916095ca1df60bB79Ce92cE3Ea74c37c5d359', - '0xdbF03B407c01E7cD3CBea99509d93f8DDDC8C6FB', - '0xD1220A0cf47c7B9Be7A2E6BA89F429762e7b9aDb', - '0xfb6916095ca1df60bb79ce92ce3ea74c37c5d359', - '0x52908400098527886E0F7030069857D2E4169EE7', - '0x8617E340B3D01FA5F11F306F4090FD50E238070D', - '0xde709f2102306220921060314715629080e2fb77', - '0x27b1fdb04752bbc536007a920d24acb045561c26', - '0x5aaeb6053f3e94c9b9a09f33669435e7ef1beaed', - '0xfB6916095ca1df60bB79Ce92cE3Ea74c37c5d359', - '0xdbF03B407c01E7cD3CBea99509d93f8DDDC8C6FB', - '0xD1220A0cf47c7B9Be7A2E6BA89F429762e7b9aDb', - ]; - - describe('toHexString', function () { - for (const addr of addresses) { - it(`converts ${addr}`, async function () { - expect(await this.mock.getFunction('$toHexString(address)')(addr)).to.equal(addr.toLowerCase()); - }); - } - }); - - describe('toChecksumHexString', function () { - for (const addr of addresses) { - it(`converts ${addr}`, async function () { - expect(await this.mock.$toChecksumHexString(addr)).to.equal(ethers.getAddress(addr)); - }); - } - }); - - describe('parseAddress', function () { - for (const addr of addresses) { - it(`converts ${addr}`, async function () { - expect(await this.mock.$parseAddress(addr)).to.equal(ethers.getAddress(addr)); - expect(await this.mock.$tryParseAddress(addr)).to.deep.equal([true, ethers.getAddress(addr)]); - }); - } - }); - }); - - describe('equal', function () { - it('compares two empty strings', async function () { - expect(await this.mock.$equal('', '')).to.be.true; - }); - - it('compares two equal strings', async function () { - expect(await this.mock.$equal('a', 'a')).to.be.true; - }); - - it('compares two different strings', async function () { - expect(await this.mock.$equal('a', 'b')).to.be.false; - }); - - it('compares two different strings of different lengths', async function () { - expect(await this.mock.$equal('a', 'aa')).to.be.false; - expect(await this.mock.$equal('aa', 'a')).to.be.false; - }); - - it('compares two different large strings', async function () { - const str1 = 'a'.repeat(201); - const str2 = 'a'.repeat(200) + 'b'; - expect(await this.mock.$equal(str1, str2)).to.be.false; - }); - - it('compares two equal large strings', async function () { - const str1 = 'a'.repeat(201); - const str2 = 'a'.repeat(201); - expect(await this.mock.$equal(str1, str2)).to.be.true; - }); - }); - - describe('Edge cases: invalid parsing', function () { - it('parseUint overflow', async function () { - await expect(this.mock.$parseUint((ethers.MaxUint256 + 1n).toString(10))).to.be.revertedWithPanic( - PANIC_CODES.ARITHMETIC_OVERFLOW, - ); - await expect(this.mock.$tryParseUint((ethers.MaxUint256 + 1n).toString(10))).to.be.revertedWithPanic( - PANIC_CODES.ARITHMETIC_OVERFLOW, - ); - }); - - it('parseUint invalid character', async function () { - await expect(this.mock.$parseUint('0x1')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - await expect(this.mock.$parseUint('1f')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - await expect(this.mock.$parseUint('-10')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - await expect(this.mock.$parseUint('1.0')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - await expect(this.mock.$parseUint('1 000')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - expect(await this.mock.$tryParseUint('0x1')).to.deep.equal([false, 0n]); - expect(await this.mock.$tryParseUint('1f')).to.deep.equal([false, 0n]); - expect(await this.mock.$tryParseUint('-10')).to.deep.equal([false, 0n]); - expect(await this.mock.$tryParseUint('1.0')).deep.equal([false, 0n]); - expect(await this.mock.$tryParseUint('1 000')).deep.equal([false, 0n]); - }); - - it('parseUint invalid range', async function () { - expect(this.mock.$parseUint('12', 3, 2)).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - expect(await this.mock.$tryParseUint('12', 3, 2)).to.deep.equal([false, 0n]); - }); - - it('parseInt overflow', async function () { - await expect(this.mock.$parseInt((ethers.MaxUint256 + 1n).toString(10))).to.be.revertedWithPanic( - PANIC_CODES.ARITHMETIC_OVERFLOW, - ); - await expect(this.mock.$parseInt((-ethers.MaxUint256 - 1n).toString(10))).to.be.revertedWithPanic( - PANIC_CODES.ARITHMETIC_OVERFLOW, - ); - await expect(this.mock.$tryParseInt((ethers.MaxUint256 + 1n).toString(10))).to.be.revertedWithPanic( - PANIC_CODES.ARITHMETIC_OVERFLOW, - ); - await expect(this.mock.$tryParseInt((-ethers.MaxUint256 - 1n).toString(10))).to.be.revertedWithPanic( - PANIC_CODES.ARITHMETIC_OVERFLOW, - ); - await expect(this.mock.$parseInt((ethers.MaxInt256 + 1n).toString(10))).to.be.revertedWithCustomError( - this.mock, - 'StringsInvalidChar', - ); - await expect(this.mock.$parseInt((ethers.MinInt256 - 1n).toString(10))).to.be.revertedWithCustomError( - this.mock, - 'StringsInvalidChar', - ); - expect(await this.mock.$tryParseInt((ethers.MaxInt256 + 1n).toString(10))).to.deep.equal([false, 0n]); - expect(await this.mock.$tryParseInt((ethers.MinInt256 - 1n).toString(10))).to.deep.equal([false, 0n]); - }); - - it('parseInt invalid character', async function () { - await expect(this.mock.$parseInt('0x1')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - await expect(this.mock.$parseInt('1f')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - await expect(this.mock.$parseInt('1.0')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - await expect(this.mock.$parseInt('1 000')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - expect(await this.mock.$tryParseInt('0x1')).to.deep.equal([false, 0n]); - expect(await this.mock.$tryParseInt('1f')).to.deep.equal([false, 0n]); - expect(await this.mock.$tryParseInt('1.0')).to.deep.equal([false, 0n]); - expect(await this.mock.$tryParseInt('1 000')).to.deep.equal([false, 0n]); - }); - - it('parseInt invalid range', async function () { - expect(this.mock.$parseInt('-12', 3, 2)).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - expect(await this.mock.$tryParseInt('-12', 3, 2)).to.deep.equal([false, 0n]); - }); - - it('parseHexUint overflow', async function () { - await expect(this.mock.$parseHexUint((ethers.MaxUint256 + 1n).toString(16))).to.be.revertedWithPanic( - PANIC_CODES.ARITHMETIC_OVERFLOW, - ); - await expect(this.mock.$tryParseHexUint((ethers.MaxUint256 + 1n).toString(16))).to.be.revertedWithPanic( - PANIC_CODES.ARITHMETIC_OVERFLOW, - ); - }); - - it('parseHexUint invalid character', async function () { - await expect(this.mock.$parseHexUint('0123456789abcdefg')).to.be.revertedWithCustomError( - this.mock, - 'StringsInvalidChar', - ); - await expect(this.mock.$parseHexUint('-1')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - await expect(this.mock.$parseHexUint('-f')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - await expect(this.mock.$parseHexUint('-0xf')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - await expect(this.mock.$parseHexUint('1.0')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - await expect(this.mock.$parseHexUint('1 000')).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - expect(await this.mock.$tryParseHexUint('0123456789abcdefg')).to.deep.equal([false, 0n]); - expect(await this.mock.$tryParseHexUint('-1')).to.deep.equal([false, 0n]); - expect(await this.mock.$tryParseHexUint('-f')).to.deep.equal([false, 0n]); - expect(await this.mock.$tryParseHexUint('-0xf')).to.deep.equal([false, 0n]); - expect(await this.mock.$tryParseHexUint('1.0')).to.deep.equal([false, 0n]); - expect(await this.mock.$tryParseHexUint('1 000')).to.deep.equal([false, 0n]); - }); - - it('parseHexUint invalid begin and end', async function () { - expect(this.mock.$parseHexUint('0x', 3, 2)).to.be.revertedWithCustomError(this.mock, 'StringsInvalidChar'); - expect(await this.mock.$tryParseHexUint('0x', 3, 2)).to.deep.equal([false, 0n]); - }); - - it('parseAddress invalid format', async function () { - for (const addr of [ - '0x736a507fB2881d6bB62dcA54673CF5295dC07833', // valid - '0x736a507fB2881d6-B62dcA54673CF5295dC07833', // invalid char - '0x0736a507fB2881d6bB62dcA54673CF5295dC07833', // tooLong - '0x36a507fB2881d6bB62dcA54673CF5295dC07833', // tooShort - '736a507fB2881d6bB62dcA54673CF5295dC07833', // missingPrefix - supported - ]) { - if (ethers.isAddress(addr)) { - expect(await this.mock.$parseAddress(addr)).to.equal(ethers.getAddress(addr)); - expect(await this.mock.$tryParseAddress(addr)).to.deep.equal([true, ethers.getAddress(addr)]); - } else { - await expect(this.mock.$parseAddress(addr)).to.be.revertedWithCustomError( - this.mock, - 'StringsInvalidAddressFormat', - ); - expect(await this.mock.$tryParseAddress(addr)).to.deep.equal([false, ethers.ZeroAddress]); - } - } - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/TransientSlot.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/TransientSlot.test.js deleted file mode 100644 index 7b70be375d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/TransientSlot.test.js +++ /dev/null @@ -1,59 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { generators } = require('../helpers/random'); - -const slot = ethers.id('some.storage.slot'); -const otherSlot = ethers.id('some.other.storage.slot'); - -// Non-value types are not supported by the `TransientSlot` library. -const TYPES = [ - { name: 'Boolean', type: 'bool', value: true, zero: false }, - { name: 'Address', type: 'address', value: generators.address(), zero: generators.address.zero }, - { name: 'Bytes32', type: 'bytes32', value: generators.bytes32(), zero: generators.bytes32.zero }, - { name: 'Uint256', type: 'uint256', value: generators.uint256(), zero: generators.uint256.zero }, - { name: 'Int256', type: 'int256', value: generators.int256(), zero: generators.int256.zero }, -]; - -async function fixture() { - return { mock: await ethers.deployContract('TransientSlotMock') }; -} - -describe('TransientSlot', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - for (const { name, type, value, zero } of TYPES) { - describe(`${type} transient slot`, function () { - const load = `tload${name}(bytes32)`; - const store = `tstore(bytes32,${type})`; - const event = `${name}Value`; - - it('load', async function () { - await expect(this.mock[load](slot)).to.emit(this.mock, event).withArgs(slot, zero); - }); - - it('store and load (2 txs)', async function () { - await this.mock[store](slot, value); - await expect(this.mock[load](slot)).to.emit(this.mock, event).withArgs(slot, zero); - }); - - it('store and load (batched)', async function () { - await expect( - this.mock.multicall([ - this.mock.interface.encodeFunctionData(store, [slot, value]), - this.mock.interface.encodeFunctionData(load, [slot]), - this.mock.interface.encodeFunctionData(load, [otherSlot]), - ]), - ) - .to.emit(this.mock, event) - .withArgs(slot, value) - .to.emit(this.mock, event) - .withArgs(otherSlot, zero); - - await expect(this.mock[load](slot)).to.emit(this.mock, event).withArgs(slot, zero); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/ECDSA.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/ECDSA.test.js deleted file mode 100644 index 0f2879a86c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/ECDSA.test.js +++ /dev/null @@ -1,211 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const TEST_MESSAGE = ethers.id('OpenZeppelin'); -const WRONG_MESSAGE = ethers.id('Nope'); -const NON_HASH_MESSAGE = '0xabcd'; - -async function fixture() { - const [signer] = await ethers.getSigners(); - const mock = await ethers.deployContract('$ECDSA'); - return { signer, mock }; -} - -describe('ECDSA', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('recover with invalid signature', function () { - it('with short signature', async function () { - await expect(this.mock.$recover(TEST_MESSAGE, '0x1234')) - .to.be.revertedWithCustomError(this.mock, 'ECDSAInvalidSignatureLength') - .withArgs(2); - }); - - it('with long signature', async function () { - await expect( - this.mock.$recover( - TEST_MESSAGE, - '0x01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789', - ), - ) - .to.be.revertedWithCustomError(this.mock, 'ECDSAInvalidSignatureLength') - .withArgs(85); - }); - }); - - describe('recover with valid signature', function () { - describe('using .sign', function () { - it('returns signer address with correct signature', async function () { - // Create the signature - const signature = await this.signer.signMessage(TEST_MESSAGE); - - // Recover the signer address from the generated message and signature. - expect(await this.mock.$recover(ethers.hashMessage(TEST_MESSAGE), signature)).to.equal(this.signer); - }); - - it('returns signer address with correct signature for arbitrary length message', async function () { - // Create the signature - const signature = await this.signer.signMessage(NON_HASH_MESSAGE); - - // Recover the signer address from the generated message and signature. - expect(await this.mock.$recover(ethers.hashMessage(NON_HASH_MESSAGE), signature)).to.equal(this.signer); - }); - - it('returns a different address', async function () { - const signature = await this.signer.signMessage(TEST_MESSAGE); - expect(await this.mock.$recover(WRONG_MESSAGE, signature)).to.not.be.equal(this.signer); - }); - - it('reverts with invalid signature', async function () { - const signature = - '0x332ce75a821c982f9127538858900d87d3ec1f9f737338ad67cad133fa48feff48e6fa0c18abc62e42820f05943e47af3e9fbe306ce74d64094bdf1691ee53e01c'; - await expect(this.mock.$recover(TEST_MESSAGE, signature)).to.be.revertedWithCustomError( - this.mock, - 'ECDSAInvalidSignature', - ); - }); - }); - - describe('with v=27 signature', function () { - const signer = '0x2cc1166f6212628A0deEf2B33BEFB2187D35b86c'; - - const signatureWithoutV = - '0x5d99b6f7f6d1f73d1a26497f2b1c89b24c0993913f86e9a2d02cd69887d9c94f3c880358579d811b21dd1b7fd9bb01c1d81d10e69f0384e675c32b39643be892'; - - it('works with correct v value', async function () { - const v = '0x1b'; // 27 = 1b. - const signature = ethers.concat([signatureWithoutV, v]); - expect(await this.mock.$recover(TEST_MESSAGE, signature)).to.equal(signer); - - const { r, s, yParityAndS: vs } = ethers.Signature.from(signature); - expect(await this.mock.getFunction('$recover(bytes32,uint8,bytes32,bytes32)')(TEST_MESSAGE, v, r, s)).to.equal( - signer, - ); - - expect(await this.mock.getFunction('$recover(bytes32,bytes32,bytes32)')(TEST_MESSAGE, r, vs)).to.equal(signer); - }); - - it('rejects incorrect v value', async function () { - const v = '0x1c'; // 28 = 1c. - const signature = ethers.concat([signatureWithoutV, v]); - expect(await this.mock.$recover(TEST_MESSAGE, signature)).to.not.equal(signer); - - const { r, s, yParityAndS: vs } = ethers.Signature.from(signature); - expect( - await this.mock.getFunction('$recover(bytes32,uint8,bytes32,bytes32)')(TEST_MESSAGE, v, r, s), - ).to.not.equal(signer); - - expect(await this.mock.getFunction('$recover(bytes32,bytes32,bytes32)')(TEST_MESSAGE, r, vs)).to.not.equal( - signer, - ); - }); - - it('reverts wrong v values', async function () { - for (const v of ['0x00', '0x01']) { - const signature = ethers.concat([signatureWithoutV, v]); - await expect(this.mock.$recover(TEST_MESSAGE, signature)).to.be.revertedWithCustomError( - this.mock, - 'ECDSAInvalidSignature', - ); - - const { r, s } = ethers.Signature.from(signature); - await expect( - this.mock.getFunction('$recover(bytes32,uint8,bytes32,bytes32)')(TEST_MESSAGE, v, r, s), - ).to.be.revertedWithCustomError(this.mock, 'ECDSAInvalidSignature'); - } - }); - - it('rejects short EIP2098 format', async function () { - const v = '0x1b'; // 27 = 1b. - const signature = ethers.concat([signatureWithoutV, v]); - - const { compactSerialized } = ethers.Signature.from(signature); - await expect(this.mock.$recover(TEST_MESSAGE, compactSerialized)) - .to.be.revertedWithCustomError(this.mock, 'ECDSAInvalidSignatureLength') - .withArgs(64); - }); - }); - - describe('with v=28 signature', function () { - const signer = '0x1E318623aB09Fe6de3C9b8672098464Aeda9100E'; - - const signatureWithoutV = - '0x331fe75a821c982f9127538858900d87d3ec1f9f737338ad67cad133fa48feff48e6fa0c18abc62e42820f05943e47af3e9fbe306ce74d64094bdf1691ee53e0'; - - it('works with correct v value', async function () { - const v = '0x1c'; // 28 = 1c. - const signature = ethers.concat([signatureWithoutV, v]); - expect(await this.mock.$recover(TEST_MESSAGE, signature)).to.equal(signer); - - const { r, s, yParityAndS: vs } = ethers.Signature.from(signature); - expect(await this.mock.getFunction('$recover(bytes32,uint8,bytes32,bytes32)')(TEST_MESSAGE, v, r, s)).to.equal( - signer, - ); - - expect(await this.mock.getFunction('$recover(bytes32,bytes32,bytes32)')(TEST_MESSAGE, r, vs)).to.equal(signer); - }); - - it('rejects incorrect v value', async function () { - const v = '0x1b'; // 27 = 1b. - const signature = ethers.concat([signatureWithoutV, v]); - expect(await this.mock.$recover(TEST_MESSAGE, signature)).to.not.equal(signer); - - const { r, s, yParityAndS: vs } = ethers.Signature.from(signature); - expect( - await this.mock.getFunction('$recover(bytes32,uint8,bytes32,bytes32)')(TEST_MESSAGE, v, r, s), - ).to.not.equal(signer); - - expect(await this.mock.getFunction('$recover(bytes32,bytes32,bytes32)')(TEST_MESSAGE, r, vs)).to.not.equal( - signer, - ); - }); - - it('reverts invalid v values', async function () { - for (const v of ['0x00', '0x01']) { - const signature = ethers.concat([signatureWithoutV, v]); - await expect(this.mock.$recover(TEST_MESSAGE, signature)).to.be.revertedWithCustomError( - this.mock, - 'ECDSAInvalidSignature', - ); - - const { r, s } = ethers.Signature.from(signature); - await expect( - this.mock.getFunction('$recover(bytes32,uint8,bytes32,bytes32)')(TEST_MESSAGE, v, r, s), - ).to.be.revertedWithCustomError(this.mock, 'ECDSAInvalidSignature'); - } - }); - - it('rejects short EIP2098 format', async function () { - const v = '0x1b'; // 28 = 1b. - const signature = ethers.concat([signatureWithoutV, v]); - - const { compactSerialized } = ethers.Signature.from(signature); - await expect(this.mock.$recover(TEST_MESSAGE, compactSerialized)) - .to.be.revertedWithCustomError(this.mock, 'ECDSAInvalidSignatureLength') - .withArgs(64); - }); - }); - - it('reverts with high-s value signature', async function () { - const message = '0xb94d27b9934d3e08a52e52d7da7dabfac484efe37a5380ee9088f7ace2efcde9'; - - const highSSignature = - '0xe742ff452d41413616a5bf43fe15dd88294e983d3d36206c2712f39083d638bde0a0fc89be718fbc1033e1d30d78be1c68081562ed2e97af876f286f3453231d1b'; - - const r = ethers.dataSlice(highSSignature, 0, 32); - const s = ethers.dataSlice(highSSignature, 32, 64); - const v = ethers.dataSlice(highSSignature, 64, 65); - - await expect(this.mock.$recover(message, highSSignature)) - .to.be.revertedWithCustomError(this.mock, 'ECDSAInvalidSignatureS') - .withArgs(s); - await expect(this.mock.getFunction('$recover(bytes32,uint8,bytes32,bytes32)')(TEST_MESSAGE, v, r, s)) - .to.be.revertedWithCustomError(this.mock, 'ECDSAInvalidSignatureS') - .withArgs(s); - expect(() => ethers.Signature.from(highSSignature)).to.throw('non-canonical s'); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/EIP712.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/EIP712.test.js deleted file mode 100644 index 2b6e7fa978..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/EIP712.test.js +++ /dev/null @@ -1,105 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { getDomain, domainSeparator, hashTypedData } = require('../../helpers/eip712'); -const { formatType } = require('../../helpers/eip712-types'); - -const LENGTHS = { - short: ['A Name', '1'], - long: ['A'.repeat(40), 'B'.repeat(40)], -}; - -const fixture = async () => { - const [from, to] = await ethers.getSigners(); - - const lengths = {}; - for (const [shortOrLong, [name, version]] of Object.entries(LENGTHS)) { - lengths[shortOrLong] = { name, version }; - lengths[shortOrLong].eip712 = await ethers.deployContract('$EIP712Verifier', [name, version]); - lengths[shortOrLong].domain = { - name, - version, - chainId: await ethers.provider.getNetwork().then(({ chainId }) => chainId), - verifyingContract: lengths[shortOrLong].eip712.target, - }; - } - - return { from, to, lengths }; -}; - -describe('EIP712', function () { - for (const [shortOrLong, [name, version]] of Object.entries(LENGTHS)) { - describe(`with ${shortOrLong} name and version`, function () { - beforeEach('deploying', async function () { - Object.assign(this, await loadFixture(fixture)); - Object.assign(this, this.lengths[shortOrLong]); - }); - - describe('domain separator', function () { - it('is internally available', async function () { - const expected = await domainSeparator(this.domain); - - expect(await this.eip712.$_domainSeparatorV4()).to.equal(expected); - }); - - it("can be rebuilt using EIP-5267's eip712Domain", async function () { - const rebuildDomain = await getDomain(this.eip712); - expect(rebuildDomain).to.be.deep.equal(this.domain); - }); - - if (shortOrLong === 'short') { - // Long strings are in storage, and the proxy will not be properly initialized unless - // the upgradeable contract variant is used and the initializer is invoked. - - it('adjusts when behind proxy', async function () { - const factory = await ethers.deployContract('$Clones'); - - const clone = await factory - .$clone(this.eip712) - .then(tx => tx.wait()) - .then(receipt => receipt.logs.find(ev => ev.fragment.name == 'return$clone_address').args.instance) - .then(address => ethers.getContractAt('$EIP712Verifier', address)); - - const expectedDomain = { ...this.domain, verifyingContract: clone.target }; - expect(await getDomain(clone)).to.be.deep.equal(expectedDomain); - - const expectedSeparator = await domainSeparator(expectedDomain); - expect(await clone.$_domainSeparatorV4()).to.equal(expectedSeparator); - }); - } - }); - - it('hash digest', async function () { - const structhash = ethers.hexlify(ethers.randomBytes(32)); - expect(await this.eip712.$_hashTypedDataV4(structhash)).to.equal(hashTypedData(this.domain, structhash)); - }); - - it('digest', async function () { - const types = { - Mail: formatType({ - to: 'address', - contents: 'string', - }), - }; - - const message = { - to: this.to.address, - contents: 'very interesting', - }; - - const signature = await this.from.signTypedData(this.domain, types, message); - - await expect(this.eip712.verify(signature, this.from.address, message.to, message.contents)).to.not.be.reverted; - }); - - it('name', async function () { - expect(await this.eip712.$_EIP712Name()).to.equal(name); - }); - - it('version', async function () { - expect(await this.eip712.$_EIP712Version()).to.equal(version); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/MerkleProof.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/MerkleProof.test.js deleted file mode 100644 index 93ee964a86..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/MerkleProof.test.js +++ /dev/null @@ -1,213 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); -const { SimpleMerkleTree } = require('@openzeppelin/merkle-tree'); - -// generate bytes32 leaves from a string -const toLeaves = (str, separator = '') => str.split(separator).map(e => ethers.keccak256(ethers.toUtf8Bytes(e))); -// internal node hashes -const concatSorted = (...elements) => Buffer.concat(elements.map(ethers.getBytes).sort(Buffer.compare)); -const defaultHash = (a, b) => ethers.keccak256(concatSorted(a, b)); -const customHash = (a, b) => ethers.sha256(concatSorted(a, b)); - -describe('MerkleProof', function () { - for (const { title, contractName, nodeHash } of [ - { title: 'default hash', contractName: '$MerkleProof', nodeHash: defaultHash }, - { title: 'custom hash', contractName: '$MerkleProofCustomHashMock', nodeHash: customHash }, - ]) { - describe(title, function () { - // stateless: no need for a fixture, just use before - before(async function () { - this.mock = await ethers.deployContract(contractName); - this.makeTree = str => SimpleMerkleTree.of(toLeaves(str), { nodeHash }); - }); - - describe('verify', function () { - it('returns true for a valid Merkle proof', async function () { - const merkleTree = this.makeTree('ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/='); - - const root = merkleTree.root; - const hash = merkleTree.at(0); - const proof = merkleTree.getProof(0); - - expect(await this.mock.$processProof(proof, hash)).to.equal(root); - expect(await this.mock.$processProofCalldata(proof, hash)).to.equal(root); - expect(await this.mock.$verify(proof, root, hash)).to.be.true; - expect(await this.mock.$verifyCalldata(proof, root, hash)).to.be.true; - - // For demonstration, it is also possible to create valid proofs for certain 64-byte values *not* in elements: - const noSuchLeaf = nodeHash(hash, proof.at(0)); - - expect(await this.mock.$processProof(proof.slice(1), noSuchLeaf)).to.equal(root); - expect(await this.mock.$processProofCalldata(proof.slice(1), noSuchLeaf)).to.equal(root); - expect(await this.mock.$verify(proof.slice(1), root, noSuchLeaf)).to.be.true; - expect(await this.mock.$verifyCalldata(proof.slice(1), root, noSuchLeaf)).to.be.true; - }); - - it('returns false for an invalid Merkle proof', async function () { - const correctMerkleTree = this.makeTree('abc'); - const otherMerkleTree = this.makeTree('def'); - - const root = correctMerkleTree.root; - const hash = correctMerkleTree.at(0); - const proof = otherMerkleTree.getProof(0); - - expect(await this.mock.$processProof(proof, hash)).to.not.equal(root); - expect(await this.mock.$processProofCalldata(proof, hash)).to.not.equal(root); - expect(await this.mock.$verify(proof, root, hash)).to.be.false; - expect(await this.mock.$verifyCalldata(proof, root, hash)).to.be.false; - }); - - it('returns false for a Merkle proof of invalid length', async function () { - const merkleTree = this.makeTree('abc'); - - const root = merkleTree.root; - const hash = merkleTree.at(0); - const proof = merkleTree.getProof(0); - const badProof = proof.slice(0, -1); - - expect(await this.mock.$processProof(badProof, hash)).to.not.equal(root); - expect(await this.mock.$processProofCalldata(badProof, hash)).to.not.equal(root); - expect(await this.mock.$verify(badProof, root, hash)).to.be.false; - expect(await this.mock.$verifyCalldata(badProof, root, hash)).to.be.false; - }); - }); - - describe('multiProofVerify', function () { - it('returns true for a valid Merkle multi proof', async function () { - const merkleTree = this.makeTree('abcdef'); - - const root = merkleTree.root; - const { proof, proofFlags, leaves } = merkleTree.getMultiProof(toLeaves('bdf')); - const hashes = leaves.map(e => merkleTree.leafHash(e)); - - expect(await this.mock.$processMultiProof(proof, proofFlags, hashes)).to.equal(root); - expect(await this.mock.$processMultiProofCalldata(proof, proofFlags, hashes)).to.equal(root); - expect(await this.mock.$multiProofVerify(proof, proofFlags, root, hashes)).to.be.true; - expect(await this.mock.$multiProofVerifyCalldata(proof, proofFlags, root, hashes)).to.be.true; - }); - - it('returns false for an invalid Merkle multi proof', async function () { - const merkleTree = this.makeTree('abcdef'); - const otherMerkleTree = this.makeTree('ghi'); - - const root = merkleTree.root; - const { proof, proofFlags, leaves } = otherMerkleTree.getMultiProof(toLeaves('ghi')); - const hashes = leaves.map(e => merkleTree.leafHash(e)); - - expect(await this.mock.$processMultiProof(proof, proofFlags, hashes)).to.not.equal(root); - expect(await this.mock.$processMultiProofCalldata(proof, proofFlags, hashes)).to.not.equal(root); - expect(await this.mock.$multiProofVerify(proof, proofFlags, root, hashes)).to.be.false; - expect(await this.mock.$multiProofVerifyCalldata(proof, proofFlags, root, hashes)).to.be.false; - }); - - it('revert with invalid multi proof #1', async function () { - const merkleTree = this.makeTree('abcd'); - - const root = merkleTree.root; - const hashA = merkleTree.at(0); - const hashB = merkleTree.at(1); - const hashCD = nodeHash(merkleTree.at(2), merkleTree.at(3)); - const hashE = ethers.randomBytes(32); // incorrect (not part of the tree) - const fill = ethers.randomBytes(32); - - await expect( - this.mock.$processMultiProof([hashB, fill, hashCD], [false, false, false], [hashA, hashE]), - ).to.be.revertedWithCustomError(this.mock, 'MerkleProofInvalidMultiproof'); - - await expect( - this.mock.$processMultiProofCalldata([hashB, fill, hashCD], [false, false, false], [hashA, hashE]), - ).to.be.revertedWithCustomError(this.mock, 'MerkleProofInvalidMultiproof'); - - await expect( - this.mock.$multiProofVerify([hashB, fill, hashCD], [false, false, false], root, [hashA, hashE]), - ).to.be.revertedWithCustomError(this.mock, 'MerkleProofInvalidMultiproof'); - - await expect( - this.mock.$multiProofVerifyCalldata([hashB, fill, hashCD], [false, false, false], root, [hashA, hashE]), - ).to.be.revertedWithCustomError(this.mock, 'MerkleProofInvalidMultiproof'); - }); - - it('revert with invalid multi proof #2', async function () { - const merkleTree = this.makeTree('abcd'); - - const root = merkleTree.root; - const hashA = merkleTree.at(0); - const hashB = merkleTree.at(1); - const hashCD = nodeHash(merkleTree.at(2), merkleTree.at(3)); - const hashE = ethers.randomBytes(32); // incorrect (not part of the tree) - const fill = ethers.randomBytes(32); - - await expect( - this.mock.$processMultiProof([hashB, fill, hashCD], [false, false, false, false], [hashE, hashA]), - ).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - - await expect( - this.mock.$processMultiProofCalldata([hashB, fill, hashCD], [false, false, false, false], [hashE, hashA]), - ).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - - await expect( - this.mock.$multiProofVerify([hashB, fill, hashCD], [false, false, false, false], root, [hashE, hashA]), - ).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - - await expect( - this.mock.$multiProofVerifyCalldata([hashB, fill, hashCD], [false, false, false, false], root, [ - hashE, - hashA, - ]), - ).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - }); - - it('limit case: works for tree containing a single leaf', async function () { - const merkleTree = this.makeTree('a'); - - const root = merkleTree.root; - const { proof, proofFlags, leaves } = merkleTree.getMultiProof(toLeaves('a')); - const hashes = leaves.map(e => merkleTree.leafHash(e)); - - expect(await this.mock.$processMultiProof(proof, proofFlags, hashes)).to.equal(root); - expect(await this.mock.$processMultiProofCalldata(proof, proofFlags, hashes)).to.equal(root); - expect(await this.mock.$multiProofVerify(proof, proofFlags, root, hashes)).to.be.true; - expect(await this.mock.$multiProofVerifyCalldata(proof, proofFlags, root, hashes)).to.be.true; - }); - - it('limit case: can prove empty leaves', async function () { - const merkleTree = this.makeTree('abcd'); - - const root = merkleTree.root; - expect(await this.mock.$processMultiProof([root], [], [])).to.equal(root); - expect(await this.mock.$processMultiProofCalldata([root], [], [])).to.equal(root); - expect(await this.mock.$multiProofVerify([root], [], root, [])).to.be.true; - expect(await this.mock.$multiProofVerifyCalldata([root], [], root, [])).to.be.true; - }); - - it('reverts processing manipulated proofs with a zero-value node at depth 1', async function () { - // Create a merkle tree that contains a zero leaf at depth 1 - const leave = ethers.id('real leaf'); - const root = nodeHash(leave, ethers.ZeroHash); - - // Now we can pass any **malicious** fake leaves as valid! - const maliciousLeaves = ['malicious', 'leaves'].map(ethers.id).map(ethers.toBeArray).sort(Buffer.compare); - const maliciousProof = [leave, leave]; - const maliciousProofFlags = [true, true, false]; - - await expect( - this.mock.$processMultiProof(maliciousProof, maliciousProofFlags, maliciousLeaves), - ).to.be.revertedWithCustomError(this.mock, 'MerkleProofInvalidMultiproof'); - - await expect( - this.mock.$processMultiProofCalldata(maliciousProof, maliciousProofFlags, maliciousLeaves), - ).to.be.revertedWithCustomError(this.mock, 'MerkleProofInvalidMultiproof'); - - await expect( - this.mock.$multiProofVerify(maliciousProof, maliciousProofFlags, root, maliciousLeaves), - ).to.be.revertedWithCustomError(this.mock, 'MerkleProofInvalidMultiproof'); - - await expect( - this.mock.$multiProofVerifyCalldata(maliciousProof, maliciousProofFlags, root, maliciousLeaves), - ).to.be.revertedWithCustomError(this.mock, 'MerkleProofInvalidMultiproof'); - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/MessageHashUtils.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/MessageHashUtils.test.js deleted file mode 100644 index f20f5a3cae..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/MessageHashUtils.test.js +++ /dev/null @@ -1,68 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { domainSeparator, hashTypedData } = require('../../helpers/eip712'); - -async function fixture() { - const mock = await ethers.deployContract('$MessageHashUtils'); - return { mock }; -} - -describe('MessageHashUtils', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('toEthSignedMessageHash', function () { - it('prefixes bytes32 data correctly', async function () { - const message = ethers.randomBytes(32); - const expectedHash = ethers.hashMessage(message); - - expect(await this.mock.getFunction('$toEthSignedMessageHash(bytes32)')(message)).to.equal(expectedHash); - }); - - it('prefixes dynamic length data correctly', async function () { - const message = ethers.randomBytes(128); - const expectedHash = ethers.hashMessage(message); - - expect(await this.mock.getFunction('$toEthSignedMessageHash(bytes)')(message)).to.equal(expectedHash); - }); - - it('version match for bytes32', async function () { - const message = ethers.randomBytes(32); - const fixed = await this.mock.getFunction('$toEthSignedMessageHash(bytes32)')(message); - const dynamic = await this.mock.getFunction('$toEthSignedMessageHash(bytes)')(message); - - expect(fixed).to.equal(dynamic); - }); - }); - - describe('toDataWithIntendedValidatorHash', function () { - it('returns the digest correctly', async function () { - const verifier = ethers.Wallet.createRandom().address; - const message = ethers.randomBytes(128); - const expectedHash = ethers.solidityPackedKeccak256( - ['string', 'address', 'bytes'], - ['\x19\x00', verifier, message], - ); - - expect(await this.mock.$toDataWithIntendedValidatorHash(verifier, message)).to.equal(expectedHash); - }); - }); - - describe('toTypedDataHash', function () { - it('returns the digest correctly', async function () { - const domain = { - name: 'Test', - version: '1', - chainId: 1n, - verifyingContract: ethers.Wallet.createRandom().address, - }; - const structhash = ethers.randomBytes(32); - const expectedHash = hashTypedData(domain, structhash); - - expect(await this.mock.$toTypedDataHash(domainSeparator(domain), structhash)).to.equal(expectedHash); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/P256.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/P256.t.sol deleted file mode 100644 index 0c9b2c78a0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/P256.t.sol +++ /dev/null @@ -1,44 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; - -import {P256} from "@openzeppelin/contracts/utils/cryptography/P256.sol"; -import {Math} from "@openzeppelin/contracts/utils/math/Math.sol"; - -contract P256Test is Test { - /// forge-config: default.fuzz.runs = 512 - function testVerify(bytes32 digest, uint256 seed) public { - uint256 privateKey = _asPrivateKey(seed); - - (uint256 x, uint256 y) = vm.publicKeyP256(privateKey); - (bytes32 r, bytes32 s) = vm.signP256(privateKey, digest); - s = _ensureLowerS(s); - assertTrue(P256.verify(digest, r, s, bytes32(x), bytes32(y))); - assertTrue(P256.verifySolidity(digest, r, s, bytes32(x), bytes32(y))); - } - - /// forge-config: default.fuzz.runs = 512 - function testRecover(bytes32 digest, uint256 seed) public { - uint256 privateKey = _asPrivateKey(seed); - - (uint256 x, uint256 y) = vm.publicKeyP256(privateKey); - (bytes32 r, bytes32 s) = vm.signP256(privateKey, digest); - s = _ensureLowerS(s); - (bytes32 qx0, bytes32 qy0) = P256.recovery(digest, 0, r, s); - (bytes32 qx1, bytes32 qy1) = P256.recovery(digest, 1, r, s); - assertTrue((qx0 == bytes32(x) && qy0 == bytes32(y)) || (qx1 == bytes32(x) && qy1 == bytes32(y))); - } - - function _asPrivateKey(uint256 seed) private pure returns (uint256) { - return bound(seed, 1, P256.N - 1); - } - - function _ensureLowerS(bytes32 s) private pure returns (bytes32) { - uint256 _s = uint256(s); - unchecked { - return _s > P256.N / 2 ? bytes32(P256.N - _s) : s; - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/P256.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/P256.test.js deleted file mode 100644 index b9655cad3f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/P256.test.js +++ /dev/null @@ -1,156 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { secp256r1 } = require('@noble/curves/p256'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const N = 0xffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551n; - -// As in ECDSA, signatures are malleable and the tooling produce both high and low S values. -// We need to ensure that the s value is in the lower half of the order of the curve. -const ensureLowerOrderS = ({ s, recovery, ...rest }) => { - if (s > N / 2n) { - s = N - s; - recovery = 1 - recovery; - } - return { s, recovery, ...rest }; -}; - -const prepareSignature = ( - privateKey = secp256r1.utils.randomPrivateKey(), - messageHash = ethers.hexlify(ethers.randomBytes(0x20)), -) => { - const publicKey = [ - secp256r1.getPublicKey(privateKey, false).slice(0x01, 0x21), - secp256r1.getPublicKey(privateKey, false).slice(0x21, 0x41), - ].map(ethers.hexlify); - const { r, s, recovery } = ensureLowerOrderS(secp256r1.sign(messageHash.replace(/0x/, ''), privateKey)); - const signature = [r, s].map(v => ethers.toBeHex(v, 0x20)); - - return { privateKey, publicKey, signature, recovery, messageHash }; -}; - -describe('P256', function () { - async function fixture() { - return { mock: await ethers.deployContract('$P256') }; - } - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('with signature', function () { - beforeEach(async function () { - Object.assign(this, prepareSignature()); - }); - - it('verify valid signature', async function () { - expect(await this.mock.$verify(this.messageHash, ...this.signature, ...this.publicKey)).to.be.true; - expect(await this.mock.$verifySolidity(this.messageHash, ...this.signature, ...this.publicKey)).to.be.true; - await expect(this.mock.$verifyNative(this.messageHash, ...this.signature, ...this.publicKey)) - .to.be.revertedWithCustomError(this.mock, 'MissingPrecompile') - .withArgs('0x0000000000000000000000000000000000000100'); - }); - - it('recover public key', async function () { - expect(await this.mock.$recovery(this.messageHash, this.recovery, ...this.signature)).to.deep.equal( - this.publicKey, - ); - }); - - it('reject signature with flipped public key coordinates ([x,y] >> [y,x])', async function () { - // flip public key - this.publicKey.reverse(); - - expect(await this.mock.$verify(this.messageHash, ...this.signature, ...this.publicKey)).to.be.false; - expect(await this.mock.$verifySolidity(this.messageHash, ...this.signature, ...this.publicKey)).to.be.false; - expect(await this.mock.$verifyNative(this.messageHash, ...this.signature, ...this.publicKey)).to.be.false; // Flipped public key is not in the curve - }); - - it('reject signature with flipped signature values ([r,s] >> [s,r])', async function () { - // Preselected signature where `r < N/2` and `s < N/2` - this.signature = [ - '0x45350225bad31e89db662fcc4fb2f79f349adbb952b3f652eed1f2aa72fb0356', - '0x513eb68424c42630012309eee4a3b43e0bdc019d179ef0e0c461800845e237ee', - ]; - - // Corresponding hash and public key - this.messageHash = '0x2ad1f900fe63745deeaedfdf396cb6f0f991c4338a9edf114d52f7d1812040a0'; - this.publicKey = [ - '0x9e30de165e521257996425d9bf12a7d366925614bf204eabbb78172b48e52e59', - '0x94bf0fe72f99654d7beae4780a520848e306d46a1275b965c4f4c2b8e9a2c08d', - ]; - - // Make sure it works - expect(await this.mock.$verify(this.messageHash, ...this.signature, ...this.publicKey)).to.be.true; - - // Flip signature - this.signature.reverse(); - - expect(await this.mock.$verify(this.messageHash, ...this.signature, ...this.publicKey)).to.be.false; - expect(await this.mock.$verifySolidity(this.messageHash, ...this.signature, ...this.publicKey)).to.be.false; - await expect(this.mock.$verifyNative(this.messageHash, ...this.signature, ...this.publicKey)) - .to.be.revertedWithCustomError(this.mock, 'MissingPrecompile') - .withArgs('0x0000000000000000000000000000000000000100'); - expect(await this.mock.$recovery(this.messageHash, this.recovery, ...this.signature)).to.not.deep.equal( - this.publicKey, - ); - }); - - it('reject signature with invalid message hash', async function () { - // random message hash - this.messageHash = ethers.hexlify(ethers.randomBytes(32)); - - expect(await this.mock.$verify(this.messageHash, ...this.signature, ...this.publicKey)).to.be.false; - expect(await this.mock.$verifySolidity(this.messageHash, ...this.signature, ...this.publicKey)).to.be.false; - await expect(this.mock.$verifyNative(this.messageHash, ...this.signature, ...this.publicKey)) - .to.be.revertedWithCustomError(this.mock, 'MissingPrecompile') - .withArgs('0x0000000000000000000000000000000000000100'); - expect(await this.mock.$recovery(this.messageHash, this.recovery, ...this.signature)).to.not.deep.equal( - this.publicKey, - ); - }); - - it('fail to recover signature with invalid recovery bit', async function () { - // flip recovery bit - this.recovery = 1 - this.recovery; - - expect(await this.mock.$recovery(this.messageHash, this.recovery, ...this.signature)).to.not.deep.equal( - this.publicKey, - ); - }); - }); - - // test cases for https://github.com/C2SP/wycheproof/blob/4672ff74d68766e7785c2cac4c597effccef2c5c/testvectors/ecdsa_secp256r1_sha256_p1363_test.json - describe('wycheproof tests', function () { - for (const { key, tests } of require('./ecdsa_secp256r1_sha256_p1363_test.json').testGroups) { - // parse public key - let [x, y] = [key.wx, key.wy].map(v => ethers.stripZerosLeft('0x' + v, 32)); - if (x.length > 66 || y.length > 66) continue; - x = ethers.zeroPadValue(x, 32); - y = ethers.zeroPadValue(y, 32); - - // run all tests for this key - for (const { tcId, comment, msg, sig, result } of tests) { - // only keep properly formatted signatures - if (sig.length != 128) continue; - - it(`${tcId}: ${comment}`, async function () { - // split signature, and reduce modulo N - let [r, s] = Array(2) - .fill() - .map((_, i) => ethers.toBigInt('0x' + sig.substring(64 * i, 64 * (i + 1)))); - // move s to lower part of the curve if needed - if (s <= N && s > N / 2n) s = N - s; - // prepare signature - r = ethers.toBeHex(r, 32); - s = ethers.toBeHex(s, 32); - // hash - const messageHash = ethers.sha256('0x' + msg); - - // check verify - expect(await this.mock.$verify(messageHash, r, s, x, y)).to.equal(result == 'valid'); - }); - } - } - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/RSA.helper.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/RSA.helper.js deleted file mode 100644 index 48c8ee43cb..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/RSA.helper.js +++ /dev/null @@ -1,17 +0,0 @@ -const path = require('path'); -const fs = require('fs'); - -module.exports = function* parse(file) { - const cache = {}; - const data = fs.readFileSync(path.resolve(__dirname, file), 'utf8'); - for (const line of data.split('\r\n')) { - const groups = line.match(/^(?\w+) = (?\w+)(?.*)$/)?.groups; - if (groups) { - const { key, value, extra } = groups; - cache[key] = value; - if (groups.key === 'Result') { - yield Object.assign({ extra: extra.trim() }, cache); - } - } - } -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/RSA.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/RSA.test.js deleted file mode 100644 index bdf33911fe..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/RSA.test.js +++ /dev/null @@ -1,102 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { bytes, bytes32 } = ethers.Typed; - -const parse = require('./RSA.helper'); - -async function fixture() { - return { mock: await ethers.deployContract('$RSA') }; -} - -describe('RSA', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - // Load test cases from file SigVer15_186-3.rsp from: - // https://csrc.nist.gov/CSRC/media/Projects/Cryptographic-Algorithm-Validation-Program/documents/dss/186-2rsatestvectors.zip - describe('SigVer15_186-3.rsp tests', function () { - for (const test of parse('SigVer15_186-3.rsp')) { - const { length } = Buffer.from(test.S, 'hex'); - - /// For now, RSA only supports digest that are 32bytes long. If we ever extend that, we can use these hashing functions for @noble: - // const { sha1 } = require('@noble/hashes/sha1'); - // const { sha224, sha256 } = require('@noble/hashes/sha256'); - // const { sha384, sha512 } = require('@noble/hashes/sha512'); - - if (test.SHAAlg === 'SHA256' && length >= 0x100) { - const result = test.Result === 'P'; - - it(`signature length ${length} ${test.extra} ${result ? 'works' : 'fails'}`, async function () { - const data = '0x' + test.Msg; - const sig = '0x' + test.S; - const exp = '0x' + test.e; - const mod = '0x' + test.n; - - expect(await this.mock.$pkcs1Sha256(bytes32(ethers.sha256(data)), sig, exp, mod)).to.equal(result); - expect(await this.mock.$pkcs1Sha256(bytes(data), sig, exp, mod)).to.equal(result); - }); - } - } - }); - - describe('others tests', function () { - // > openssl genrsa -out private.pem 2048 - // > openssl rsa -in private.pem -outform der -pubout -out public.pem - // > openssl asn1parse -in public.pem -inform DER -strparse 19 - // > echo -n 'hello world!' | openssl dgst -sha256 -sign private.pem | xxd -p | tr -d \\n - const openssl = { - descr: 'openssl', - data: ethers.toUtf8Bytes('hello world!'), - sig: '0x2ff4349940bf0db9bce422e316ac47e3d24b0a869acb05c9c46f74e17491177698b150f2a5996a6bf7d7c73e05af91ad78632115a7d95b823c462596486e56e8473b75a270ca4760cd83f244d5d3af81d2c7d188879abbc2992b22d51e22ffb725f0828c852ee44f81def383e0f92ebfa3c6d97ca5e52a4254f9a886680e3fb394c2a8a955849313dce2cb416f8a67974effd9a17d229146ce10a98684fb3d46a1e53ddaf831cdd2beed895532533c554ae087b2738a5c4cf0802e8062b2a599fd76d67b92eabffa8a92b24e08fbc866217502a4a3d9f6157e491bede3c1048fa8f2d804f66128e8a883018b0ec33a59e1086bf71ae5dc193d9815ca82892dbc', - exp: '0x010001', - mod: '0xDC1CE5F7B202464CD320B4F9E44FEE0A358BE7022AB155A5BDEE45B1AED3C5A19645D898E294CBA96EAD6929FD8FB4B23E9ADB4D3143A736232C32A8617A77B89F7D8399B9BE37F8349D111067F71D2F20237B9F1A7C1CF44819F9FA5AA030F563DCFB1CC59FFAA86BA2ABEE28D949FED0DF34071B7558950079E28CD9BBA4CAC2F0F86D7BBFB13363C792B5A70C9B279F0B43A264A7CB1A7C7C41FC6EC1D1C1125A6BECE3207AE582F74CE896B9AC18DB00C8985B70145217B831CC313FC06581E186BF70A2EEE2C3C065B5C91A89B2C099B4924CDBF5707D161BD83AC8D9FCA309AC75D63EACF21027C2C9C9F05994331CBDFDD24F9BC6C8B58D8F1824540B', - result: true, - }; - - // According to RFC4055, pg.5 and RFC8017, pg. 64, for SHA-1, and the SHA-2 family, - // the algorithm parameter has to be NULL and both explicit NULL parameter and implicit - // NULL parameter (ie, absent NULL parameter) are considered to be legal and equivalent. - const rfc4055 = { - descr: 'rfc8017 implicit null parameter', - data: ethers.toUtf8Bytes('hello world!'), - sig: '0xa0073057133ff3758e7e111b4d7441f1d8cbe4b2dd5ee4316a14264290dee5ed7f175716639bd9bb43a14e4f9fcb9e84dedd35e2205caac04828b2c053f68176d971ea88534dd2eeec903043c3469fc69c206b2a8694fd262488441ed8852280c3d4994e9d42bd1d575c7024095f1a20665925c2175e089c0d731471f6cc145404edf5559fd2276e45e448086f71c78d0cc6628fad394a34e51e8c10bc39bfe09ed2f5f742cc68bee899d0a41e4c75b7b80afd1c321d89ccd9fe8197c44624d91cc935dfa48de3c201099b5b417be748aef29248527e8bbb173cab76b48478d4177b338fe1f1244e64d7d23f07add560d5ad50b68d6649a49d7bc3db686daaa7', - exp: '0x03', - mod: '0xe932ac92252f585b3a80a4dd76a897c8b7652952fe788f6ec8dd640587a1ee5647670a8ad4c2be0f9fa6e49c605adf77b5174230af7bd50e5d6d6d6d28ccf0a886a514cc72e51d209cc772a52ef419f6a953f3135929588ebe9b351fca61ced78f346fe00dbb6306e5c2a4c6dfc3779af85ab417371cf34d8387b9b30ae46d7a5ff5a655b8d8455f1b94ae736989d60a6f2fd5cadbffbd504c5a756a2e6bb5cecc13bca7503f6df8b52ace5c410997e98809db4dc30d943de4e812a47553dce54844a78e36401d13f77dc650619fed88d8b3926e3d8e319c80c744779ac5d6abe252896950917476ece5e8fc27d5f053d6018d91b502c4787558a002b9283da7', - result: true, - }; - - const shortN = { - descr: 'returns false for a very short n', - data: ethers.toUtf8Bytes('hello world!'), - sig: '0x0102', - exp: '0x03', - mod: '0x0405', - result: false, - }; - - const differentLength = { - descr: 'returns false for a signature with different length to n', - data: ethers.toUtf8Bytes('hello world!'), - sig: '0x00112233', - exp: '0x03', - mod: '0xe932ac92252f585b3a80a4dd76a897c8b7652952fe788f6ec8dd640587a1ee5647670a8ad4c2be0f9fa6e49c605adf77b5174230af7bd50e5d6d6d6d28ccf0a886a514cc72e51d209cc772a52ef419f6a953f3135929588ebe9b351fca61ced78f346fe00dbb6306e5c2a4c6dfc3779af85ab417371cf34d8387b9b30ae46d7a5ff5a655b8d8455f1b94ae736989d60a6f2fd5cadbffbd504c5a756a2e6bb5cecc13bca7503f6df8b52ace5c410997e98809db4dc30d943de4e812a47553dce54844a78e36401d13f77dc650619fed88d8b3926e3d8e319c80c744779ac5d6abe252896950917476ece5e8fc27d5f053d6018d91b502c4787558a002b9283da7', - result: false, - }; - - // this is the openssl example where sig has been replaced by sig + mod - const sTooLarge = { - ...openssl, - descr: 'returns false if s >= n', - sig: ethers.toBeHex(ethers.toBigInt(openssl.sig) + ethers.toBigInt(openssl.mod)), - result: false, - }; - - for (const { descr, data, sig, exp, mod, result } of [openssl, rfc4055, shortN, differentLength, sTooLarge]) { - it(descr, async function () { - expect(await this.mock.$pkcs1Sha256(bytes(data), sig, exp, mod)).to.equal(result); - }); - } - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/SigVer15_186-3.rsp b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/SigVer15_186-3.rsp deleted file mode 100644 index 68e1fdea4a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/SigVer15_186-3.rsp +++ /dev/null @@ -1,3850 +0,0 @@ -# CAVS 11.0 -# "SigVer PKCS#1 Ver 1.5" information -# Mod sizes selected: 1024 1536 2048 3072 4096 -# SHA Algorithm selected:SHA1 SHA224 SHA256 SHA384 SHA512 -# Generated on Wed Mar 02 00:13:02 2011 - -[mod = 1024] - -n = a8d68acd413c5e195d5ef04e1b4faaf242365cb450196755e92e1215ba59802aafbadbf2564dd550956abb54f8b1c917844e5f36195d1088c600e07cada5c080ede679f50b3de32cf4026e514542495c54b1903768791aae9e36f082cd38e941ada89baecada61ab0dd37ad536bcb0a0946271594836e92ab5517301d45176b5 - -p = c107a2fe924b76e206cb9bc4af2ab7008547c00846bf6d0680b3eac3ebcbd0c7fd7a54c2b9899b08f80cde1d3691eaaa2816b1eb11822d6be7beaf4e30977c49 -q = dfea984ce4307eafc0d140c2bb82861e5dbac4f8567cbc981d70440dd639492079031486315e305eb83e591c4a2e96064966f7c894c3ca351925b5ce82d8ef0d - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = ff23e00f819bae424e41d6b762ea6b88801e651c831c964af31de0c1d6dda4a7c8587d804ed12f526819da06650e7412fb627555979ed442f2663341e5fe57527e0ddaf453a124451674976a6a6e0a31f56a79f5b73dfac39af4f3ba4a5e8bb846cb5e333812756482d975ab1910162f96bfd7c58a02f113125189f5ac05291f -S = a3877b854832d6a6dec749a908e8bd3a73b24372e80321ed01c19ce066117d8efe78ef7168af8acd139e47dd262c0c92ed1701cf6c07e0c1140f82040167f55bb5180c18ad9e66a18dacf0742c1f05173129ed5ac523faeeb2119639cd30ae5a435884b55043d4fb7fa9af0dd92c365386044c2e8bcd196b3787bfede47fff37 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = a6ce108ff3100b953781496c3d081fe32b8cedaf6d14aab2ef2dc37d8f8d2613d2f599efd55c51498749c0961681ae4ea7e28bf14a8f044c2d4dd4f9102ddd25f86c7795289708eb4df2d526f91b176952eb52fd0c9de2989432d6e08e13022b82f95089d20a5704f0452f26cd1f83bc956ee7da99876c1f8da3723af388bead -S = a5aa479d792448cc3e2ddfbe444017eea54efca7101651f4616f0260c7a48a364fe459abf98352e86b0b3d1478208687dffde1380d4462fce68cd61895401c3791186f17f159b91c02b5c0a30e894e142657b7537e84d2574837256da6940aa14cded7fbcba24b9e12ed2bb7e3f6db69b5a02807b57c9aa10ad9c0e1bde9443a -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = 9edf5246ae1d8fe800bc2ed422e6441cedde94c85a870277972a4b4a5a74f4fd76be8057ac92e6c5c36a4242dabacb79fe31052ef83c38da68cd2095185ae6398a284fc5d3c934fface4325ec734a2265fd3cbd513b957bef47f04f4dd699c6903a42757cccc5fdfe5b264f18f5bb16b394c4f855404486c63cb5f2d51aafed5 -S = 9a2e5b3ce63cb8df79f3cb25cce6964527e38592c58ba8b7b9312da25c62940985e93e62689f34b60cd019d3d472c0b72fcf2666bfcf8c13407e2150a138caaabaa409e6fd1ea55faf9180f7b41ed53d47c4dcdc3c669928d8a1c161f91918593dc3be3892c8df763d1a5ee6bcd5801866683005d89a2fd6ed3bef581833d922 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = d73829497cddbe41b705faac50e7899fdb5a38bf3a459e536357029e64f8796ba47f4fe96ba5a8b9a4396746e2164f55a25368ddd0b9a5188c7ac3da2d1f742286c3bdee697f9d546a25efcfe53191d743fcc6b47833d993d08804daeca78fb9076c3c017f53e33a90305af06220974d46bf19ed3c9b84edbae98b45a8771258 -S = 175015bda50abe0fa7d39a8353885ca01be3a7e7fcc55045744111362ee1914473a48dc537d956294b9e20a1ef661d58537acdc8de908fa050630fcc272e6d001045e6fdeed2d10531c8603334c2e8db39e73e6d9665ee1343f9e4198302d2201b44e8e8d06b3ef49cee6197582163a8490089ca654c0012fce1ba6511089750 -SaltVal = 00 -Result = P - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = a4397d9ab677aaa13a68a09de9ae0ed4045d479aa0ff3a7242dca477ab7884faf55cd06ddf19667f668b4589955bfd299dc7642c28a68bb2eba6f08c7ad9f5e96170913270c6463256a0537a72b32a04e5662416ecda74696d275a8bcfe999820ffc2ab210833201332f323828be7dac04c1f01f93a3dde1efe7483a51b1560d -S = 417aa0531b1da975066a1311a9bf2fa73f5daf90f0473a8937a27a9c6378c53012e0b4db3dcb5309b85a3e7f9db161848465f2e8102f75d171b4dc5371c3dca0bd70626dff5fad68549477fea84db9ac1b405440e178f5d9f74f3935e78a6aaf774b86d509fb25bd1a93aac9a2cdbce6a897842ea3ae07d3c8b4c43f97e0bf75 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a05000414dd1e335f65b2f5e31562a2c74ea6eab09892febcefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = e4690fb08396a8bf07377778a447dbd14c771024bd2353cbbd8446eda42795971c9eda0f2575be655c68614a7cd2fd252569c664dc291410548ec3a5eb06da2078a66c59441cbc9356e5a452f4c0386d6662a663fd6b61f254997ee6d63b5e3080e98d37e873ea737f17083713f7d5ce98ca79ca27d18199470c3d596caf66ed -S = 56b25cc46a9ef9607f4f0f553265996e22a4552fc6cb2752d0595e887afad29f7f9a390c17dc427c7d9f83f19f6986c60ec6d8f8017c3419cc2a838fe2425c7c80ceebfa1a0a3de507b5601609fe54b871efde685d23e546d69fbd14a30ebc2e67ac99446ae4978f1b3c120103294318b253aa9fcee638907b84ac72b25e18fa -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a050004148031ffbcbd668626dcc49e40128d8abdab1e8172 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = ff23e00f819bae424e41d6b762ea6b88801e651c831c964af31de0c1d6dda4a7c8587d804ed12f526819da06650e7412fb627555979ed442f2663341e5fe57527e0ddaf453a124451674976a6a6e0a31f56a79f5b73dfac39af4f3ba4a5e8bb846cb5e333812756482d975ab1910162f96bfd7c58a02f113125189f5ac05291f -S = 30db68c610b9086e9c6273da708ff8a89d73dfba6e2564aec908292af3a52b84ddd28bbb7c4a39df02f6e992be0d9aa8edb320a6e5a0a001ad097e7b8d09a87f50d55e1d68f47d2215a892221e7e33ddfe181b58fb12c8703e60cf0248c62af8a99111befd96b45ed4cf441a0623b013b94d3dd0976f6b5db7ae595069f21ea5 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = a6ce108ff3100b953781496c3d081fe32b8cedaf6d14aab2ef2dc37d8f8d2613d2f599efd55c51498749c0961681ae4ea7e28bf14a8f044c2d4dd4f9102ddd25f86c7795289708eb4df2d526f91b176952eb52fd0c9de2989432d6e08e13022b82f95089d20a5704f0452f26cd1f83bc956ee7da99876c1f8da3723af388bead -S = 8ed880d91764fdadb04470e04509c6b800fe2bdb1cdb17071f855b8e38b3075c3b8a6991a34ab869127f47a753d7610c79e86a7a288b653326e31d90f4d043f52b7656b6831f6806119df6309a7846b05cb2630c28f7464a7b96e4e8ce76e9cd45502bd5e928f268763fea50271d29b7527097c51ebc2b2a3a83cf22e6b7e3fa -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = 9edf5246ae1d8fe800bc2ed422e6441cedde94c85a870277972a4b4a5a74f4fd76be8057ac92e6c5c36a4242dabacb79fe31052ef83c38da68cd2095185ae6398a284fc5d3c934fface4325ec734a2265fd3cbd513b957bef47f04f4dd699c6903a42757cccc5fdfe5b264f18f5bb16b394c4f855404486c63cb5f2d51aafed5 -S = 4a1716c989580f11bad633a8566b0f44ea689d8bc27c489bbf1a01d76bfa08ce87cace576ade53a5399addee803666fa1d99fa3739c556ae513baa10415e3db820e45f7518e15c7b1875f18f3835792e7ffaed1e7cf9c592afd660d2dda77e00f8f6cf298978929ca017cfce2675afaceca959810a4a33666be9a9a1b2f6523e -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = d73829497cddbe41b705faac50e7899fdb5a38bf3a459e536357029e64f8796ba47f4fe96ba5a8b9a4396746e2164f55a25368ddd0b9a5188c7ac3da2d1f742286c3bdee697f9d546a25efcfe53191d743fcc6b47833d993d08804daeca78fb9076c3c017f53e33a90305af06220974d46bf19ed3c9b84edbae98b45a8771258 -S = 57677b089e205486df4f56755972e3af88cabbc23efe29439b8d1e60ac226e990da487857392856d12cdcea387a269d1bbbc128549a1135ab062201cab8ac08886a313af8554506d7a93855b843086a1bf3dfbcb004ccde779c084ffa1724b41d17e10c8dd67dc0df26200376550eda14455d9b0b31f1d8c5e8bb1d3d963d0d5 -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = a4397d9ab677aaa13a68a09de9ae0ed4045d479aa0ff3a7242dca477ab7884faf55cd06ddf19667f668b4589955bfd299dc7642c28a68bb2eba6f08c7ad9f5e96170913270c6463256a0537a72b32a04e5662416ecda74696d275a8bcfe999820ffc2ab210833201332f323828be7dac04c1f01f93a3dde1efe7483a51b1560d -S = 9b2222986b3f97dbdfd7aafd35fba51df5a7b76c88237e7454f2561b542289b424c76ba934e30b00e7726116ddadc359d6ad8b7ed7c16533c5661f2a61c45ec2e590e058663a740c0842e036d59f223d3c87a8127d40024ae205e46e3cd0fa323e01668da8bd723cc17e539a028a5ea69cb1fd9150db571a451ada2d81e05377 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041c472fcfddd47f6ba3bb9eb166c248320d9b39fb4b2f70b65a85615244efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = e4690fb08396a8bf07377778a447dbd14c771024bd2353cbbd8446eda42795971c9eda0f2575be655c68614a7cd2fd252569c664dc291410548ec3a5eb06da2078a66c59441cbc9356e5a452f4c0386d6662a663fd6b61f254997ee6d63b5e3080e98d37e873ea737f17083713f7d5ce98ca79ca27d18199470c3d596caf66ed -S = 7016e23d4fc070a479f4a9c173de8f1dc3a54183ab44af9e3cfda7a229bed269712f5697fdd485f03ea21183f563ee0b5a91d3478c5cc94cf6fb56c0102a7098cbe06a8a5ae6a0eef7722ef9514c80e5944c8b1412b1411d56c7b674650eafca7433ac8b9266363a049f3be30885e30fee049e50ddd76816db309ed59f9b469b -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041ca73d80b7f5f188724498120a21df3683351f77de5eb916058f9769d8 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = ff23e00f819bae424e41d6b762ea6b88801e651c831c964af31de0c1d6dda4a7c8587d804ed12f526819da06650e7412fb627555979ed442f2663341e5fe57527e0ddaf453a124451674976a6a6e0a31f56a79f5b73dfac39af4f3ba4a5e8bb846cb5e333812756482d975ab1910162f96bfd7c58a02f113125189f5ac05291f -S = 10ecd0085694f8db6ea62dab2f239d8a93fcf449102f1368c67de329d79692b677500f55994c9722e2633063fc7d8c2c50ae8857d45c08bfaba9448dda0689c2a08605d47a7694beaacbdad1a954458a87fd78b6519393013b20996d636b755323b4b2b2b6d06a46c9221cd200462428ab5bef0f9743e144191f6928562627a7 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = a6ce108ff3100b953781496c3d081fe32b8cedaf6d14aab2ef2dc37d8f8d2613d2f599efd55c51498749c0961681ae4ea7e28bf14a8f044c2d4dd4f9102ddd25f86c7795289708eb4df2d526f91b176952eb52fd0c9de2989432d6e08e13022b82f95089d20a5704f0452f26cd1f83bc956ee7da99876c1f8da3723af388bead -S = 488d328861653ab0a769a11a158ec7b479b62db5b253eda899beae580afb9a7c762030262b8a066f085185475e17870700504d3f78fcc4bcb95a3c1648796a323613a7b706cb64b048c68c06b396aac20b52f22f3fdce40992fb9a5ef68b5725134d83035a6f091d01aa5947175885822b2d4618c3f3fdbfd8819847fe40112b -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = 9edf5246ae1d8fe800bc2ed422e6441cedde94c85a870277972a4b4a5a74f4fd76be8057ac92e6c5c36a4242dabacb79fe31052ef83c38da68cd2095185ae6398a284fc5d3c934fface4325ec734a2265fd3cbd513b957bef47f04f4dd699c6903a42757cccc5fdfe5b264f18f5bb16b394c4f855404486c63cb5f2d51aafed5 -S = 7c547b350710337c783e7406935fb8ac7bcd1cdd4a7bcaeb63422067d1239f9f59fc29b51993a29d6ac8dcc7980871bbba1be8f0b6ce951a9e0cad64b37d7d0c3734e038efcd4e3499c8855f7c52ea3323ba4876ba9d78a98e7e5cf72b4b7444228dd0d81283e59055873450b8bc411d1cb970efda5cf5947a1d1f17e92a4639 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = d73829497cddbe41b705faac50e7899fdb5a38bf3a459e536357029e64f8796ba47f4fe96ba5a8b9a4396746e2164f55a25368ddd0b9a5188c7ac3da2d1f742286c3bdee697f9d546a25efcfe53191d743fcc6b47833d993d08804daeca78fb9076c3c017f53e33a90305af06220974d46bf19ed3c9b84edbae98b45a8771258 -S = 0b20e5093c2a926233108afbdd851b88eeb554f4beaa7b18e51519f7d0ec53b181a3b03e8484ba8de2aa7864a402e2208e84ec9914af9d776ed13c48bdeb6484254de169318a87c40f2265ff16714eae8aee2bc9c3cb4dee045e4f5d9d625210121bfcf2bed8d3ffa602ce27fff4e61cf9bb650e71a6921ae6ffa296cb11bdbb -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = a4397d9ab677aaa13a68a09de9ae0ed4045d479aa0ff3a7242dca477ab7884faf55cd06ddf19667f668b4589955bfd299dc7642c28a68bb2eba6f08c7ad9f5e96170913270c6463256a0537a72b32a04e5662416ecda74696d275a8bcfe999820ffc2ab210833201332f323828be7dac04c1f01f93a3dde1efe7483a51b1560d -S = 9313380722659eeccf8be943fbf514e90fb19657dfb410a50bdfc0cfb058a58e56bbae71ea1a30ecee08ca5d31a2d0bcd3f5a967a3794259c03635ee24cf2a15303ddb5962ae9747d72e83f630580600ba64d24bc4014c5d44640b2369b45fb09c2ba20721e0ae27d1a32546afa1bd023aa61079cea65389f55c31cfedb460b3 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d060960864801650304020105000420fa98b3853b928263002bcb39b454ea21f3f62bcaf6bc2b616490b7a7160120d7efefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = e4690fb08396a8bf07377778a447dbd14c771024bd2353cbbd8446eda42795971c9eda0f2575be655c68614a7cd2fd252569c664dc291410548ec3a5eb06da2078a66c59441cbc9356e5a452f4c0386d6662a663fd6b61f254997ee6d63b5e3080e98d37e873ea737f17083713f7d5ce98ca79ca27d18199470c3d596caf66ed -S = 477a7d6ff281bee7d56ac9cdc7f041b7497483f07a3cea5667ff178233219f75da7b88d9fc854a22ef541af3a5be8fb30b4e50bcb6d130e11f6c18eadec5d10f9895d654c0947aad152ba395c1039d7a8ff41b829179984a513f1abeb5a748bf248af1ea0152093d9fafb5d18e4cf91bd3b57ddd18b6984d976e6bef58cb30ec -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d06096086480165030402010500042034c9d0b0b487446c903244e640affe835096c7ada2e4295090bd9386884df006 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = ff23e00f819bae424e41d6b762ea6b88801e651c831c964af31de0c1d6dda4a7c8587d804ed12f526819da06650e7412fb627555979ed442f2663341e5fe57527e0ddaf453a124451674976a6a6e0a31f56a79f5b73dfac39af4f3ba4a5e8bb846cb5e333812756482d975ab1910162f96bfd7c58a02f113125189f5ac05291f -S = 5ad712eea6e12cf093b8aaa41bd972bd92ea43442dfae0671b27b80d821fdf8a83b032b870e2aa618430ab207ccb1c86bc5e74ea44a0f1ba2cfa2fca003e8547eedc4fd748e7718a9dc39c032b9bb997b4c01f49e441ddcb134d9b2c28a3dcbf126de439f07cb58aece617573797d939957083e51fe5eec00deaae17c41f59ed -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = a6ce108ff3100b953781496c3d081fe32b8cedaf6d14aab2ef2dc37d8f8d2613d2f599efd55c51498749c0961681ae4ea7e28bf14a8f044c2d4dd4f9102ddd25f86c7795289708eb4df2d526f91b176952eb52fd0c9de2989432d6e08e13022b82f95089d20a5704f0452f26cd1f83bc956ee7da99876c1f8da3723af388bead -S = 1f00ccb2e22d0355b20b79b3d3c2416c03d281673fa3314aeec0cb41373e9a8ad5441e93545b6ceb9d3b8d660709cc2b8cff61924768fcf5b0d0ac771a395c02797123f503866d2aee5bb03c651091388486f63793bd714485ead5e03b92c9d80668c2088866b14361d2eb5eb838f903994d84471d5a352366eff2c5cbdf1ab6 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = 9edf5246ae1d8fe800bc2ed422e6441cedde94c85a870277972a4b4a5a74f4fd76be8057ac92e6c5c36a4242dabacb79fe31052ef83c38da68cd2095185ae6398a284fc5d3c934fface4325ec734a2265fd3cbd513b957bef47f04f4dd699c6903a42757cccc5fdfe5b264f18f5bb16b394c4f855404486c63cb5f2d51aafed5 -S = 52edcc1c2bd6eecfda613f0ed8cc8ed5d0f0b881b5a05eca36d9fbb3d04a9f36f0fa916008d13ae8b17b8f6d97ac4450d892b2731f14a477032cd353b8c054d53a3b2932124fd8d1bac88b44e4fd6f37b8ec3575b290fad24a262011b45f7e9b96b09324901f1d153921e13f7246ffdce405018c20975dcd28a7fe55689bdd9f -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = d73829497cddbe41b705faac50e7899fdb5a38bf3a459e536357029e64f8796ba47f4fe96ba5a8b9a4396746e2164f55a25368ddd0b9a5188c7ac3da2d1f742286c3bdee697f9d546a25efcfe53191d743fcc6b47833d993d08804daeca78fb9076c3c017f53e33a90305af06220974d46bf19ed3c9b84edbae98b45a8771258 -S = 7e3ccb6ab03b419a3e54f81337a3c3f72e8c65bbd19ddd50246a36f51f58741ec245d2d0f07677a4f88aa3b1caeecdffe5fd6edcf8b8bcfb569637ad02eb154d17b87a8f00d0e618a7f4a70ce407f20359153e5f4a4d9744f3f3ff44120c08a460500f030fd3398e97fcaef9d0a7e2acef19a81f706805be5fc003d78e5b29c0 -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = a4397d9ab677aaa13a68a09de9ae0ed4045d479aa0ff3a7242dca477ab7884faf55cd06ddf19667f668b4589955bfd299dc7642c28a68bb2eba6f08c7ad9f5e96170913270c6463256a0537a72b32a04e5662416ecda74696d275a8bcfe999820ffc2ab210833201332f323828be7dac04c1f01f93a3dde1efe7483a51b1560d -S = 1077cf5852f21c7986f30bc2bb382138e93c0670315a83799047e122b7804cb8cdc892f23c8297b8315c16c351f0c6138cecb630a51b8a0980eeb59d575b3d86c52ae9270c6f444143d22ad6a1eea05a886281c9d7c93f0d3ab2528bb72e99b2afbf74f04038c3e17743e286a409304e4c19d441a68142b0d7b3c0a6da5532bd -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003041300d0609608648016503040202050004301cdb4de69f4d84845bef51cd666020a895fbea98f2f61c9554ebdcffa525877093cbc9a4b1b8efeb77980d73ca54de17efef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = e4690fb08396a8bf07377778a447dbd14c771024bd2353cbbd8446eda42795971c9eda0f2575be655c68614a7cd2fd252569c664dc291410548ec3a5eb06da2078a66c59441cbc9356e5a452f4c0386d6662a663fd6b61f254997ee6d63b5e3080e98d37e873ea737f17083713f7d5ce98ca79ca27d18199470c3d596caf66ed -S = 63c488bdf2f7de4cd048c535b481a4cc2898e3810eda0038b2283bfe9b3f2beba2a74268639ecfc05170d1af534ced5d3b4941d1aad317875e05d6a19f734625721ed1f262faf995feb1acb44ba76beaec957aa8023429865717d0abfc553cb67474034344ceb8c5d4bddff7fa230ac620e5e665006dffb1c4cc7995c73841f9 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d060960864801650304020205000430cf563bb8f42149df04c9bf20652986e8888907d2ff11f086bb1b6152abd4e945ad82dda241cfbf511a88b36a5a450dcc -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = ff23e00f819bae424e41d6b762ea6b88801e651c831c964af31de0c1d6dda4a7c8587d804ed12f526819da06650e7412fb627555979ed442f2663341e5fe57527e0ddaf453a124451674976a6a6e0a31f56a79f5b73dfac39af4f3ba4a5e8bb846cb5e333812756482d975ab1910162f96bfd7c58a02f113125189f5ac05291f -S = 48db9934d51e8c2e234d70ff665bf2de4fef620e23f27550254a0b4b18338e299c024c4ffc5a502945e9f2e091a86ff6e7f44059f1ca58b4a18bc15931ae1176a9775247039e57d4e322f3d77fed6c6e9bec26b066fe565384c42d2ac79dd8312c8e09d3a2bf85fba0648a02f0e958d4711396e42362c5558eb7227b12aa94d7 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = a6ce108ff3100b953781496c3d081fe32b8cedaf6d14aab2ef2dc37d8f8d2613d2f599efd55c51498749c0961681ae4ea7e28bf14a8f044c2d4dd4f9102ddd25f86c7795289708eb4df2d526f91b176952eb52fd0c9de2989432d6e08e13022b82f95089d20a5704f0452f26cd1f83bc956ee7da99876c1f8da3723af388bead -S = 125b4dddf5e18c8de2f7b72faa76f1d03dd88aac3c76ebc037b4b1aa1435eda6bef2c948e2ba51e763b8572f4ecef228ca38c10299add6f3f67c171a8fd56e33a1c287c49f844e4e98b20f0fe727b58515e5e7d3846c029afe08d25a9edf0dda6677b1cb2ca6be67763171f114932c43f53af126d0aab6dcb52d5b320b385c6d -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = 9edf5246ae1d8fe800bc2ed422e6441cedde94c85a870277972a4b4a5a74f4fd76be8057ac92e6c5c36a4242dabacb79fe31052ef83c38da68cd2095185ae6398a284fc5d3c934fface4325ec734a2265fd3cbd513b957bef47f04f4dd699c6903a42757cccc5fdfe5b264f18f5bb16b394c4f855404486c63cb5f2d51aafed5 -S = 70a4fc2afc2524ec159aaaac0cf5242e276057c3ebaee9c3c430aa862ac5758aa3a55f6f6ebbb25bc5229e51c976949314244efb35d89d4516845e41f9cb9c4db78d381eb35f257d3b9981eac9e27cd9d18a56a6dceceebb77523255684ad6ff58622889e08a616acafca687e2742074d0f7431ff5ca4324c4d25b44af9fd2aa -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = d73829497cddbe41b705faac50e7899fdb5a38bf3a459e536357029e64f8796ba47f4fe96ba5a8b9a4396746e2164f55a25368ddd0b9a5188c7ac3da2d1f742286c3bdee697f9d546a25efcfe53191d743fcc6b47833d993d08804daeca78fb9076c3c017f53e33a90305af06220974d46bf19ed3c9b84edbae98b45a8771258 -S = 8b57a6f91606ba4813b83536581eb15d72875dcbb0a514b4c03b6df8f202fa8556e4002122bedaf26eaa107ece4860752379ec8baa64f40098be92a4214b69e98b24ae1cc4d2f457cff4f405a82ef94c5f8dfaadd3078d7a9224887db86c3218bf53c9779ed09895b2cfb84f1fad2e5b1f8e4b209c5785b9ce332cd41356c171 -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = a4397d9ab677aaa13a68a09de9ae0ed4045d479aa0ff3a7242dca477ab7884faf55cd06ddf19667f668b4589955bfd299dc7642c28a68bb2eba6f08c7ad9f5e96170913270c6463256a0537a72b32a04e5662416ecda74696d275a8bcfe999820ffc2ab210833201332f323828be7dac04c1f01f93a3dde1efe7483a51b1560d -S = 8e0fecaaf7911ccadb8ca5b6ae3bb89580cbda49d3181d5aab4f03431c62aedb4affc58b87c4b3c4ee09f7908f34f52e2901891382b57cd78d3a824fe446eef4ef46b2afb0d34e6cd9a263c21db8c9c2cdcd5e60eaac571d67410c7136180ddd6195ff2a0691746e457da69bd1667a56b1980a22d5f0b3595af0e8c3bf97c2d6 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003051300d0609608648016503040203050004406bb51b0f43cc58788c9d60f71e06fc473949ae313b3354033526cdfac71690c584f916b1a8eeb47f17f339b6cccc3fb3a53786d418295c1e454db8cb17cb7de6efefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1c23c1cce034ba598f8fd2b7af37f1d30b090f7362aee68e5187adae49b9955c729f24a863b7a38d6e3c748e2972f6d940b7ba89043a2d6c2100256a1cf0f56a8cd35fc6ee205244876642f6f9c3820a3d9d2c8921df7d82aaadcaf2d7334d398931ddbba553190b3a416099f3aa07fd5b26214645a828419e122cfb857ad73b -Msg = e4690fb08396a8bf07377778a447dbd14c771024bd2353cbbd8446eda42795971c9eda0f2575be655c68614a7cd2fd252569c664dc291410548ec3a5eb06da2078a66c59441cbc9356e5a452f4c0386d6662a663fd6b61f254997ee6d63b5e3080e98d37e873ea737f17083713f7d5ce98ca79ca27d18199470c3d596caf66ed -S = 9572ebe453e2f17dd72921b38a27c28c68f4605aedf6b4a7d54079e3ceb2811ccaa6dbc0d71d47d93cd1f18cfb028744fe3d8971b0e9712f29ccab4152e2635dff3b9a1e9cb8f462b138b00c4c0a1163739286b50ac232da5075a9ba3c02a3f604d4629a7df516b39c8d01cb5019f9630436c70415c6b16d79bb29f3a46b72d6 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d060960864801650304020305000440605b7b97abce7dee5f9b9ebf2ebe35d7e474e62b3a6e86b108cbfe3c3a8300bd11deb0210048f502b7af1c9dcb1805f1d61e8df038359729a4bb33774b9d13aa -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -n = a8d68acd413c5e195d5ef04e1b4faaf242365cb450196755e92e1215ba59802aafbadbf2564dd550956abb54f8b1c917844e5f36195d1088c600e07cada5c080ede679f50b3de32cf4026e514542495c54b1903768791aae9e36f082cd38e941ada89baecada61ab0dd37ad536bcb0a0946271594836e92ab5517301d45176b5 - -p = c107a2fe924b76e206cb9bc4af2ab7008547c00846bf6d0680b3eac3ebcbd0c7fd7a54c2b9899b08f80cde1d3691eaaa2816b1eb11822d6be7beaf4e30977c49 - -q = dfea984ce4307eafc0d140c2bb82861e5dbac4f8567cbc981d70440dd639492079031486315e305eb83e591c4a2e96064966f7c894c3ca351925b5ce82d8ef0d - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = ff23e00f819bae424e41d6b762ea6b88801e651c831c964af31de0c1d6dda4a7c8587d804ed12f526819da06650e7412fb627555979ed442f2663341e5fe57527e0ddaf453a124451674976a6a6e0a31f56a79f5b73dfac39af4f3ba4a5e8bb846cb5e333812756482d975ab1910162f96bfd7c58a02f113125189f5ac05291f -S = 3c9db203bbb31c7a3498b3b35ec2ea818614f3a17cad8308f834c6945305e3b94f9886c00098640cb56cefbf06a9ebb7a8c28af610c49896dae53303fb716bc3d2ebf95205944f845658732e8a7ee032472942292f82ba24a66094c7c3b417f5e678a19c04e3b54ba5f0f03610c56d31b9726ee0e39cb1708d89fa61ba9a039b -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = a6ce108ff3100b953781496c3d081fe32b8cedaf6d14aab2ef2dc37d8f8d2613d2f599efd55c51498749c0961681ae4ea7e28bf14a8f044c2d4dd4f9102ddd25f86c7795289708eb4df2d526f91b176952eb52fd0c9de2989432d6e08e13022b82f95089d20a5704f0452f26cd1f83bc956ee7da99876c1f8da3723af388bead -S = 6592c64db5ce133e1c7d499bf7ea4d0203897186b4319fc5e29522d97b9af212fd5a10a8c15246a46d0382cc61c9bfe2b211871d7dfa4eff9a6fa15426309844fa72b1de7aba231c66076185014b9f9e9fadbc2a739ee95c48da75fbfc7d05c22e7896db47407e8d78f0d28519c7fcb6c868b05016bcf73075477a92e97625bc -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 9edf5246ae1d8fe800bc2ed422e6441cedde94c85a870277972a4b4a5a74f4fd76be8057ac92e6c5c36a4242dabacb79fe31052ef83c38da68cd2095185ae6398a284fc5d3c934fface4325ec734a2265fd3cbd513b957bef47f04f4dd699c6903a42757cccc5fdfe5b264f18f5bb16b394c4f855404486c63cb5f2d51aafed5 -S = 6c80cc0f17783b39712a994f16a461830c26ba3f3afd1a277cda564c8a8b41c4ab444bb6f79df1d109f781de3e6e81d2a0aa2b6ff566e065b3125a6bebd36039aaab46e38a3fb36f66e665372f0cbe15a696d00cd79922bce7e6771ac59fa0c4576f28eeffca9177bdfb0804d2f883b929f58d4ea948df8bb3c283fa337d5665 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 4ff6c9e7f9f03abd3e114a788fd51318feda52b6509c1b685483cb6574213f6a8ab4435cf5f34d2eeb076c0510d77b9a48889ae0ca44dfe8773b480169e8f423ce96938ef7221caeac02be42c38618bdf15eacecdf5d91da807d69f1a3229361c4a3a2c628060d05290b2776ce6d52499e647022b66e9b071a4f167c495683ec -S = 6466b9759635fbb2a3e8cb7d2a6192ea7da6033b76dd578b76ca468fcb9215f8138966f9aaa3e82246d15bb271a269eda087e63812406407ca12cb085ae82ceebcf28eb44f6608549fbf6383882c864688665a1b5a2d748496b36f8b935f676339fc61e9bc0c3a5a58141226f300cf29c4371047d530a4776809f572b88ecdfe -SaltVal = 00 -Result = P - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 85624c37ee13b3d8cb80a5961a39c5953caf10f1b4e9c00a2c78701fb8ac821f5f08bebbd8f43bc091b283a4f693f25eef6b5f7baa42ff6f9c4c8529c21c8eea2d143d56bd2022cc2da461f34fb210959981e0b1e11a00cb65553e870e047076f66e123027ff30a3a63d87aab0fee7e243d8dbb9e0da8cc79079e36225cdee6c -S = 705a07d366f2326ced17374d5f599d483ccf184d5fbbc288face464b64c058e6583b8ba664f979f3a6c1b0755b1e2cfe8154c39176d432f59af5714bcf9b0af8da122af77f0393385613393d43db7902eb1b81fc9dc6604692e0f85d30ec59fdc521cd35e5aeef006a6b919bdf47bc9a468daf3e86b3e4956ff736bbc25c9ed1 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a050004143dee53379c3e2d8c26a41c9f63be60b1993097d7efefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 263da806fe0a7a242843f295893fd891cd13c0ecc1648c90fc79322bc594bf2531839cd58c7210f4fa0307525ea112c77b11ae6d5a49c90ceb8682d6ee9931551481a7a1623fb7d6d7e6f5c54ef2bdeaa6da779f1fe91a8e0749ef6c976198e5186150d2491a74b20514435821dae2e19499a2e9dae986ff9aeb00558694fcbc -S = 727d32d7faa37ab2dac96e9f822be4dfe60459ab7aa18a26cecf6c84bfa7fac7261c86f89ca84356ee20fa9e8a8a9a2b5f5e624cc4269aa8583fb148777091ecab8929e3f8a628c8f6e1b3a48ff1f60ce1b40f279439bf8eadc6c1b977b51e8ec3c65cb8db9fdb956b514d28381260b9f6b02b2d065ef57770952d968bed65b8 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a05000414eaf16b6fc483cd5d255ffe76f761420c4df301e6 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = ff23e00f819bae424e41d6b762ea6b88801e651c831c964af31de0c1d6dda4a7c8587d804ed12f526819da06650e7412fb627555979ed442f2663341e5fe57527e0ddaf453a124451674976a6a6e0a31f56a79f5b73dfac39af4f3ba4a5e8bb846cb5e333812756482d975ab1910162f96bfd7c58a02f113125189f5ac05291f -S = 64c3e9ef2af3501ed929ec204d43848d42f3393e437b4267c70d87fc5296ebd752739088529c16e2f6f0aa87e1bc6843779dac3af54f90d3334d4b65b6b0adaf91b6fa8a75826a30f50177f887e705fb64a9258f131dc958bff8134bd68206b9d3a6fa70b2c7de5308269a6c33716916c37810aa69ce3e81db88674a07fe55e1 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = a6ce108ff3100b953781496c3d081fe32b8cedaf6d14aab2ef2dc37d8f8d2613d2f599efd55c51498749c0961681ae4ea7e28bf14a8f044c2d4dd4f9102ddd25f86c7795289708eb4df2d526f91b176952eb52fd0c9de2989432d6e08e13022b82f95089d20a5704f0452f26cd1f83bc956ee7da99876c1f8da3723af388bead -S = 6c9e4455899b0ede371ddb6fe074217d330fe0e27537b0f06ea2e24c75ed6017594ead552296da15f11e6e6923639d95fb73e98d5160e80754ec12f4a06660c6e27eb4de4fbcfbeb37176ef5281a190249e34276a2d736e622c8151f3d5b838e450383edc986cee6b00a1d4cd5a7de8fc8629b6557a3becad84cff5c6c51f2a8 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 9edf5246ae1d8fe800bc2ed422e6441cedde94c85a870277972a4b4a5a74f4fd76be8057ac92e6c5c36a4242dabacb79fe31052ef83c38da68cd2095185ae6398a284fc5d3c934fface4325ec734a2265fd3cbd513b957bef47f04f4dd699c6903a42757cccc5fdfe5b264f18f5bb16b394c4f855404486c63cb5f2d51aafed5 -S = 9b689f488edb16d4aa3192af3760977401dd066d319d4c5dacff4dbe8aab9aa5790f39bc2378d0c8f52f286fc1cabb743bf6aabffacf5ffe4186054d0b121a2e6559806886759398e7d30781380aead8af992485e2bd582208dcf69ae8e7124b1571cdfb7db87cd565f293cb8d26a8d005508a3332d4ec27d44a1423402e6d8c -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 4ff6c9e7f9f03abd3e114a788fd51318feda52b6509c1b685483cb6574213f6a8ab4435cf5f34d2eeb076c0510d77b9a48889ae0ca44dfe8773b480169e8f423ce96938ef7221caeac02be42c38618bdf15eacecdf5d91da807d69f1a3229361c4a3a2c628060d05290b2776ce6d52499e647022b66e9b071a4f167c495683ec -S = 86ff99daaee2a3c866a71f7f6fb391b9b31a3cbcf525321087a6b253e42a7b5fa386ba3907751933cd153431507b78486d5d43dd35779962fbc9babc487afc696b0140ade1456fc5b23ce5c7c97019247e827cc7032c7e101b68eb4bfb003ba107f042b92ff697789fe43018d28794c7aa8a70a5386e891e3456a5e52990853b -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 85624c37ee13b3d8cb80a5961a39c5953caf10f1b4e9c00a2c78701fb8ac821f5f08bebbd8f43bc091b283a4f693f25eef6b5f7baa42ff6f9c4c8529c21c8eea2d143d56bd2022cc2da461f34fb210959981e0b1e11a00cb65553e870e047076f66e123027ff30a3a63d87aab0fee7e243d8dbb9e0da8cc79079e36225cdee6c -S = 1f4e56f13d4167951a716dc8340c006715a4b9340a1bbcfcbb7befd70e15723d81ee5152c42967ac479b3a4ceaf1527b9379daeb245c423a21bf35826dc0f6b90a4caa579d962023e12e2eda516484ddc9483b91c7853d03a1854536d1e6fdfb9217223d2d9132a56d411183fc30de2463c4d5bea4429e7599dc9c4dd2b96b89 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041cc53cbccde35eed66e504f5ae6ecf78ba8f83abd4b67822b40e121f99efefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 263da806fe0a7a242843f295893fd891cd13c0ecc1648c90fc79322bc594bf2531839cd58c7210f4fa0307525ea112c77b11ae6d5a49c90ceb8682d6ee9931551481a7a1623fb7d6d7e6f5c54ef2bdeaa6da779f1fe91a8e0749ef6c976198e5186150d2491a74b20514435821dae2e19499a2e9dae986ff9aeb00558694fcbc -S = 002e26f1d72dcaaf2935f4177601e7b55da3ba0769372a2326d4e621449deecf84c2b3b2998da662907d167a6e7dd0b63116acd7c98d3e086da986ce126568aa31ffa136efaab815ccb9e8059a1e2bf1393dfe8567b73c8191d5acb8560a69514495a33362e05b94c3e260e181603a5d5d9a589c21c5b18effbbf016cd493276 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041cd8eee327931d42ecd0654f1da8d551ebc5ca117b9a9bee9d28049ac5 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = ff23e00f819bae424e41d6b762ea6b88801e651c831c964af31de0c1d6dda4a7c8587d804ed12f526819da06650e7412fb627555979ed442f2663341e5fe57527e0ddaf453a124451674976a6a6e0a31f56a79f5b73dfac39af4f3ba4a5e8bb846cb5e333812756482d975ab1910162f96bfd7c58a02f113125189f5ac05291f -S = 8b5a3675f397841c53a9021dad71a1efab91451c71ad7060ce85d75b306d6403ba23d3370b0695be87485cf6680204c68424bc7e442ef90ac01c4df420ef574294823250a000d56a5d00947800dcb2f4947f5b4eb18fa1dbdc6ab16be4b7131102d4dff98ddeac38554473964d29cdc521ee690cde5a8cd16889aa090c32c53e -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = a6ce108ff3100b953781496c3d081fe32b8cedaf6d14aab2ef2dc37d8f8d2613d2f599efd55c51498749c0961681ae4ea7e28bf14a8f044c2d4dd4f9102ddd25f86c7795289708eb4df2d526f91b176952eb52fd0c9de2989432d6e08e13022b82f95089d20a5704f0452f26cd1f83bc956ee7da99876c1f8da3723af388bead -S = 750e59f29d2dfeedab2a3a09034904715957149126c63e6a2dc7a633a32c4c0561d54eeb1479cb65274bac37cac4751f4dffdfb7530171599b61d94862845f6cd12a5e0bd6adabc36f06d216a00b1942349710540555106aeb87f5cf3f78df918f36cf63291ef2a7064e31b84075d1c8b551225a25f59c721a3d77046078557f -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 9be28a4763c6665880c1c2a8a74494622be46de3c20e5b118cf70fee51d33b6d0b473e84a4200382004526a33eea59e13b07070e580937207ec7b2cc5fb76856fe6210a771150fa0e5da9baee4a6209ed3d4e2b3bfd2e5f6591b0ace3e657ad07c1b47d8520d5159386767f11fdfaf41fa3348fb7dd32d3c25da5d1d78433985 -S = 0ac6e41252383ee5d07f4fb08a22204f56440a8f3c8568d6e6bae46cfc9d39b65b2eae827164d716e9e465301d08fca7356ef447e0699feabbfac16ed19dc9233b457fe64d6fab38aca4464e5cd3eae3f43bab17856cdcc942e2cc848b7bf390fc53b3ed2e6f63c5d961bc83475ac200708f6e1d5be30cbe24fe4d3dad754269 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = f56379c42e3ba856585ca28f7fb768f65d273a5fc546156142857b0afb7c72d2d97ecfceec71b4260bdc58c9bb42065f53af69805d9006233ec70a591aff463bf23d78200fb8cc14a4eba286afe8924120efad9e3d3f06f7452c725e53728b8f86c9fb245fbaf7086ab0092e215213830d1091212efc1ec59ddc3a83707d4ab8 -S = 5f49d8dc4519d9520d6542eca08cafb2d99cdb97c5a8685df2476b40505a2f9e8d63d76516b83481e2d961a7e8dc5f9f46887e394776711b0f85e4303065c06d362456bc219fc6eb343ede6733f779f75853533bc9ab876188da8ad98f9ea2f335d2ceec34ef9cb2782bb0f79cad309608ddc222e00ebcff9d14f6e6ed39638b -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 399b54f756514628f32ce8f1cf391d77047af55f3d43804923e5e09a188aa27f28604f2f3cfa3d7091f3ab5c69d40d650137a597c22d531dbbdeae074f6f534a2b297e087cd7d7125e6f8eac97f5a990859d9d3555301c5076b02f9c4d3f84d62b3d090c7cb1ba1841eab668c066990079f206c15d1383eb3ba58ae17bc2dc2c -S = a62e4b688bb3c4c2e11a3a0b1ef81ff4bbaa110c9b830d02bda2d364dadb2345a8c5dca58c611515f0c09732ee6a6642d5c5c339460a9d15022f48c36e9bc2fb8b2b0ff99005273287b8c3bed87993baf52f0e9d079281bc25a8694ed9692446127c26c34f21e610a84f3617247ecfb3b5337fe59d1239dfb7fdac8694dbef0b -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d060960864801650304020105000420be1f73a059cec568dcdfddf1daff4201e79273653f88ef8f16be7e9ee660335aefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = b8518b80a55b365eb1850e18f88da2941c99543c2f865df3d37d114d9fc764ffc5e2ae94f2d4ab6276bfc6bda5b6976a7dcfaa56897982880410dd5542af3ad34c469990cbec828327764842ef488f767c6b0c8cd1e08caec63438f2665517d195a4d4daf64bc2a70bd11d119eec93a060960245d162844c5f11a98cd26003e1 -S = 06317d3df0fa7ae350729ae2096b050dcec8909d36681ccca09a7a527b90767f8c2318c49e09483b48df77ddb632d6ca721155165389f7795d3ede70465678649399242aed6d984ca74fc6c2eb4dd4bb2cd7bf2125ec853f2bf757d665b29487bc5b63df0d0b03b18608d3d9a7576ea0954aef3d3303f7d8fd7e7f9725c114e2 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d060960864801650304020105000420a51c139e5ff91509eb0bd542bebfb9a4baa9399a5535d9168942298ce69c4f5b -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = d3787e2cd5eddc154a3b29c8a5161cb0ef6fa97d6b90c9d579677d46ba22108075fd9dc13958d290c40df3ae2400224a1cf8dd74c9adc8d48522ad9c0c34c1bbde732954e432bc6e55da0beddb849ec1f2c6815d91cc006a0dabaebd3af3ac87d38327cc1ca22317c54b776b12c7197c39829c1f0c17f700d7ad88938c86594d -S = 678507d9ebb2c5254ff371d3e41b435deb1118bf0b0121c1bb8a46575df101d12d771471b956f8c229b8021a9f08faa61e0577c6a715108874bf655576954a85fb63817b58298fe3d3643a748dcc635210d2b202e3b2e663c4a212ecbc7fdf5e34e8d499a20034d98732c09be015ea728d1cc831c61965f3e32a8aae958d43d7 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 31f8dd3024b0487ae1e3a7af9032ef7c76d5420d617771814747c09b2a4ce9ba3ef8630b4e01e3fd5c6c24f588ebe44433682f5663e2df2b6978640bc2c3c1763c69d75b59efe68af8cf516a32cba1ef8380cdc72a3eb9d4d217fcdf7136e68b7173c2870e245808ff35b677587b3066af45a6c97d340563c84d107eff4d61df -S = 8d26faa1cc87606514e47b7ab3d82768868a61d237cf18e75f935e20fc5925e2c667b05cbd09da878fd623430f71ecd1f632fff4d1d049ae704004c89012008e8856f61a03001b423f4f06eadb4a72eb946a7a4dc4469e995609801498bb7471a533ee0f422adc5d41b744301efd836e5cfcc496cfc6ee646ae2218e924f76f9 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = be9b41883cfadec3960d866fe8514f9821c6c7e65af6e5c167343fb8ac227e2432760f08fbfd1c3c92e0bbcbe5266599577aa949122e215d9a81a69fa81dc0c035e46040d5ecd28d46c8ed6f490a8da3b00543c7b9d84a769aa8bdb35d2c088bee6f9df673d1e8ffdb4f8424ba05af0054f1fb27f7fa47528f31eebc74563ecb -S = 735c47985ee75db358eb0d05624be43778a37d40ad1df88cfc5b4669906e290704265fb3a133df781dfdfaa082d21d0c431b54c0c6c239fb0c0b47e675c0def6d94a726ff8267c449f1300b21a7c7f171c76e869851f9be39546e274f60924ddeedd4f69b70d97293a10ebbb3df8f9c1fec31f7d3562150a357150fbc8ae5237 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = f8a2f38109c9b6d868c5b3481cd3478c8e0845fc3e36479cb50f4158bb8d5c8ec99101cdc1ca33ddddd823ffe5b1fe75a6440a459f5df13bfdc95d2dcabac482616d86f52509359772cb3313d46083367792d9afdf27f313d9062c24b29c4f52a67ea9829b50620f10e50d0e50a77dd7eb3adac1665cf52c3210d9c5dbfba305 -S = 9ebce94bb79d82fcd236874df4c2c3d1b56481ba15fc17a345f6d45297b6adb9e07c1b582e22ce0b1830763758827a77ca675c708163cbe7a5db72d2a95939b3cef60c632a19849e6d95bf6a867604eea7f69b506bcee7d04678d4252c715edf0a928ef4c1181177bff20c3a95215782cd6b70564cf1ec2ea25e6318ef1f96b5 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d060960864801650304020205000430940085d291d91da907231dd6d6e10d71011dc3e0944671e632bb0d87c0b8fa1bc2f1019caa64a8f6844a8db073b0743b -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 7e3c652fb2786a379614fc8f9f01555cf029cf61cf0af6c455a4e2156996c48cef84be923cbbf883cd18f0b3392611af658688c5f79453c60d479a0a2e5943b581a8c1393cdd2c1c604b97fca41a9ed0aea43e70891fea58547ddaa83790a7709c72152b9b242f89b5759a72c6252347354b9a6b6ef4e302920d4af86c831745 -S = 995e2522f280d28f9719663178429d6ffb26cfcfbcc15812e83821db1a5e2a31a8160574e4fe4f1f09ce67690c67fe89c11015ffbf5dd5ec669561f0a2b13c416992de570a532b805b00b8003f6c70d56925ff2bb5555daf3edef1da6bcb1c94d29bbb243119da64ef352d36ddd6ac472a99a1a22da809aa235b51afc8379619 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003041300d060960864801650304020205000430cfd23d0f765da0ba39f284a77f62552300460944a69e6fddf7aaa731f62c6d822f5eb581075a23fd540aa7a920f7c3bbefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 2bd0f6349c6f8198a10ce8e761feb6d4d72bc71addcefc628a773367be537758fbad737e77b52d1e6f80f1a1bd518af2ad17b9280d36df65838afdfd24a9dedb4169932184a3200f3c367526f64ea08d4de640b3038b3d365063b604796f3bc0a50d3d67edc1c233b2345dbf337d5e6d5ea04605e7547e9e980a48c2e82af5cd -S = 38103ad73f8bb3a9c3e01e95b8cc45e982a64f17a318026e185d523dec851ef9fbd1b9c2694a4688925580bb50709ea624417a685b39b36e988d9b7b41282cb969379c3e739c0a98151db9181dfa58c5e6ffbaaa6971dd5171d9ebcf18ce346364f7601856aa68584ee3303e8a69d0dad778e4a4ba3ed4f8a009d561652d134e -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = d3787e2cd5eddc154a3b29c8a5161cb0ef6fa97d6b90c9d579677d46ba22108075fd9dc13958d290c40df3ae2400224a1cf8dd74c9adc8d48522ad9c0c34c1bbde732954e432bc6e55da0beddb849ec1f2c6815d91cc006a0dabaebd3af3ac87d38327cc1ca22317c54b776b12c7197c39829c1f0c17f700d7ad88938c86594d -S = 22754363656ce107c1beea8999cb4a95d267d6c6d3a06b42c939f51254f822cf49bd6d51e27af51afa0d260fb4bf6fcb8b4926270851d64f2fae6f4c6562c532e3fd72db5188c51eb57b01a871004b38d6a1bb4856fdd93573735a480b4c3e444262d198d54de6db409db7432dd45beabc34991cb6868e1e1dc62f8ef509f36e -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 31f8dd3024b0487ae1e3a7af9032ef7c76d5420d617771814747c09b2a4ce9ba3ef8630b4e01e3fd5c6c24f588ebe44433682f5663e2df2b6978640bc2c3c1763c69d75b59efe68af8cf516a32cba1ef8380cdc72a3eb9d4d217fcdf7136e68b7173c2870e245808ff35b677587b3066af45a6c97d340563c84d107eff4d61df -S = 92cd8a854b4b9842c12c7f9ec2dcfad57d1f403ce8276d355f436c1d9aaa720867dc5a96b91debceedf55eea2a33d99e586a0a59d68e9289ce6f001be3d9ae9887d9f169ecd77600ef60b97851bc8ad6c5566c830a25690a13a92bd082fdc0b356a6443fcae3d29c5e9818b06c69748149a3f34793a6c7b04da345caa01d6f20 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = be9b41883cfadec3960d866fe8514f9821c6c7e65af6e5c167343fb8ac227e2432760f08fbfd1c3c92e0bbcbe5266599577aa949122e215d9a81a69fa81dc0c035e46040d5ecd28d46c8ed6f490a8da3b00543c7b9d84a769aa8bdb35d2c088bee6f9df673d1e8ffdb4f8424ba05af0054f1fb27f7fa47528f31eebc74563ecb -S = 5d8ce84e9473178a2ab5373d3154e7d649b40a144040d4a612e9ae43666d681458b5d985f5bb1bd5709455f5421dcff12307e074714b6592f0095c0a67f66f950ac8e2cc7b8ffa5d8f89d407292ac659a4e479ee2cba19d6f31673edbecb3535b85b11edfcea4df17799418fdfda145711f5f9c0540f811ac92e05bea4460c87 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = f8a2f38109c9b6d868c5b3481cd3478c8e0845fc3e36479cb50f4158bb8d5c8ec99101cdc1ca33ddddd823ffe5b1fe75a6440a459f5df13bfdc95d2dcabac482616d86f52509359772cb3313d46083367792d9afdf27f313d9062c24b29c4f52a67ea9829b50620f10e50d0e50a77dd7eb3adac1665cf52c3210d9c5dbfba305 -S = 3c42cf56c04c1ddd18a5ec523df036428d09bb44a7b12be5bf6fdb3866a122a5cd0edb2cc81930c126a9244afcf6a27c8820369f474a06f8b7022ac8b95e35791a49d71a40ecd145e8d2e334b15f6ed698b7a646248ee73f567739469960c0da5112916a12f212d198a6f6c518b4745a578d265ab1c04438d7a38263a5a8c254 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d060960864801650304020305000440174762fdf1f011f716417beb00598a33aae32c141c664908178740f19833d9109154e89f80a1ff369930cb2dbeeba511433122236e0cf6df2d7b7202de550c6a -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 7e3c652fb2786a379614fc8f9f01555cf029cf61cf0af6c455a4e2156996c48cef84be923cbbf883cd18f0b3392611af658688c5f79453c60d479a0a2e5943b581a8c1393cdd2c1c604b97fca41a9ed0aea43e70891fea58547ddaa83790a7709c72152b9b242f89b5759a72c6252347354b9a6b6ef4e302920d4af86c831745 -S = a6825908039d9165b1f1d7e85de390819b3e13fb914521bde6370db313e0c37444bc1bca1d798a73e9602b3c61a67b6c3531c25a0528f4945ac7f27ed5848b782668cad8533000a42a0435de4436e4ee7fe0f9a347750543d921a313c6872cbcf5466ae41a69f32d03acff357cf3e4f1a3e7ed4575dc61bf4fb77a04b9d3cb32 -SaltVal = 00 -EM with hash moved = 0001ffffffffffff003051300d06096086480165030402030500044062eeafda47b660f230159a79e8b20ffc84752ef5ddc420ac6478511cc199f983ea3cb8cbeb9955c175ba5afce719ae601c6303a1f6cd5e0c241b5cfb8577deb6efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 252c4956ac328ba04789bfdc5e90819981a100f3b540069ba8719b8b3ba27980cc7c96710a75ec0da83c1ddf353b45845f3db7224cdecbe5653cebb01fb66305d42e617e8a51514c6d2fb6b3cbe3ad9478ab7acb575f854ec9c9576a70c63934921c39662b32b8c93fb660f64f50e5481892a8ef4b92a64774995f2a0fbd64b9 -Msg = 2bd0f6349c6f8198a10ce8e761feb6d4d72bc71addcefc628a773367be537758fbad737e77b52d1e6f80f1a1bd518af2ad17b9280d36df65838afdfd24a9dedb4169932184a3200f3c367526f64ea08d4de640b3038b3d365063b604796f3bc0a50d3d67edc1c233b2345dbf337d5e6d5ea04605e7547e9e980a48c2e82af5cd -S = a5c713d065e204f5a3d87e4752b235fa79a703931065aaf7ae4a29d641763d7ea4350d8d9a29b29b4fc770169ba7adf1cf7ba872769265cab2d41ee7e227e7682c749fbc5836debc02485eaca9637391c3793b3f05701f80a90cfcc04c091fa37628e4eebbefe5ceec0b4dee1b41241fb883252fe18ca65ab01e4a4e3f31ba36 -SaltVal = 00 -Result = P - -n = a8d68acd413c5e195d5ef04e1b4faaf242365cb450196755e92e1215ba59802aafbadbf2564dd550956abb54f8b1c917844e5f36195d1088c600e07cada5c080ede679f50b3de32cf4026e514542495c54b1903768791aae9e36f082cd38e941ada89baecada61ab0dd37ad536bcb0a0946271594836e92ab5517301d45176b5 - -p = c107a2fe924b76e206cb9bc4af2ab7008547c00846bf6d0680b3eac3ebcbd0c7fd7a54c2b9899b08f80cde1d3691eaaa2816b1eb11822d6be7beaf4e30977c49 - -q = dfea984ce4307eafc0d140c2bb82861e5dbac4f8567cbc981d70440dd639492079031486315e305eb83e591c4a2e96064966f7c894c3ca351925b5ce82d8ef0d - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = d3787e2cd5eddc154a3b29c8a5161cb0ef6fa97d6b90c9d579677d46ba22108075fd9dc13958d290c40df3ae2400224a1cf8dd74c9adc8d48522ad9c0c34c1bbde732954e432bc6e55da0beddb849ec1f2c6815d91cc006a0dabaebd3af3ac87d38327cc1ca22317c54b776b12c7197c39829c1f0c17f700d7ad88938c86594d -S = 4bae63c2b4ed42b92d95293ba755c0f3dbae5a13369b298147e3d7d9cf8629b7df9df22f13370239ef86c91a6b15efc5611057b375e948d554a95a7119f5663b0ba6c373121f2d4f6f9a8703a78153be3472f296254db218a22925546340dd0495ec68f354ed17ed4f9d85d4b9eb1b9d1816cc1422c852410841f166e69cc212 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = 31f8dd3024b0487ae1e3a7af9032ef7c76d5420d617771814747c09b2a4ce9ba3ef8630b4e01e3fd5c6c24f588ebe44433682f5663e2df2b6978640bc2c3c1763c69d75b59efe68af8cf516a32cba1ef8380cdc72a3eb9d4d217fcdf7136e68b7173c2870e245808ff35b677587b3066af45a6c97d340563c84d107eff4d61df -S = 8a8b25a74adf17dbc6ee3dba1982f94c17ecae57a75835cc4cd476a1afb23d01c964e8532a6d0afe71ebd8d26a2e5514906caae8b18ddd860ae16303723cbd0a155cca1a4a7be32c2396b1d09544057e7f7fdf6bf1bb2861ecc0f90223269add410dd66ea54a507a31b75528bb277ee9d3d3096d2e2f0f33b0509f27bd990b9c -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = eb2a75ef219b2bec0987c2623a76a8d3c292754519c47f8d541aa8cd9b6c7b3cdd3f7825c2e9ab33e2f684eb34cbe27ac98971b1ba34364e5f15687dc15c829e520a9649dc0ee48fb8aeab8340293ffa869b5c8e4720bae91a3ce140ed7b3f1db25478625653fd8bf378e03346dae7d9638fdfe5a7d032e6ef59bc1e070fdb40 -S = 0fd7069ca1e24f81f3c67b0bcba5fa72764655739d549a59288e6eaebf4d2f52c52eaa17e495ec2b2fcb52a4673aac2e48e2078688b8e5d8a91d7c8c4bae725070425a183e95b352999ab2b49adce63b6c9d48dc29e0649d91b73fb04c45786239b0022231e5e173e2f0d94fee7905706f39ec88fce30d107e4151d010be719b -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = f1cf2ba2463023a1d329957cf3fdc044ffecf8ce0a11f9b6ce8b7ba5e5db07d03d8d08c1c61b255a6d0ece174e661593253cc04e06a69cad4fdb1442da97014e77c1c484994c93104f5b10d876a820022e26fab68ae57e258c36c9ca501106ef87b38674278b14cc61578248d48b889800f2cf8ffd9748266ce6c2c4af0fbcbc -S = 2e305057388fc454647e2c20b71c3cc3383af683126b1b802b6e74096b46655df2715e18bbd1f9f7f4484dc63ea58bd7461c58d6e7ed63e885a2524b01eeea2b9d0cbe25e6f0f780fed9fc9610ea5b7de468b0cc409da4607a367b2815d346facdb6375a7723d013f2d8726e7b40a680b82c112324ab161aab860a943d4fc84d -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a050004141bd3d18838d09a61c2b0ba9865a146b958c0ec0b -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = 8b61c39efa507e17cf4d575bd600286d56a40e84f35d6c06d3cc33b400e161220df1c86bfd0911226081008cbfd4fa0c3aafc4de70478d089ff02f8e0cecb2e6a68011abe64d4196f9de70a9217e8bad594c02df3891cfe71750b509761fc59f9c3627c77ec61759e28c2e1cc4a5e339f9a451ef12e23b8983154d8d0524a437 -S = 72c3377e5a389a176383ffb832de6eaf3b7ee9dfb38f504031af6f3d059cd9c1027e22233d1ed0908bc08ae5edb9aa491aa189610b353b31ec92eb8186c0d2bbe8fb1364c3df8393b5917f69243ccc7cf95edd413cc175793c964efc3eed10b6c2c4de4d7b75f419a68e6cf8eb1a09b0ff29c40b713ed63c4fcc08fb59ddfcf4 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a050004141c6c02fb4af79739cab2f59451c9ec6ff577051befefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = a6cc1c55dd9b8da73acc6716344503690a9db27bb439518719b41da28284c9894fdbce9de9cc032cf7af6df2d5c658e04121a61c58be6848c2f5ab07291394bdef46b09720b985cca5ff6d22bbb5a4b3a4639ff19ca49fe80f8787c30934ea92eed3694a6ba93c0dac840eacd05a0e6b9a2d430469311fee6a3158de0c2ff38f -S = 7fc3737dfc4bf283bb8f8aa2918af4fb7156703b4870f679bb76e079e561d0adb7a21bfae94e21b83edf20bd28d6c06505109bcdd000c7533a8ff9118be14cd8beeda9cdae6f0735d75fb80953bf28587fae51e024d5b415664b3ab9c26abbbb7f2461d9bf7f2520ba08a09421939fd661d5e3dd83f3e4c41f760291e1c081e8 -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = d3787e2cd5eddc154a3b29c8a5161cb0ef6fa97d6b90c9d579677d46ba22108075fd9dc13958d290c40df3ae2400224a1cf8dd74c9adc8d48522ad9c0c34c1bbde732954e432bc6e55da0beddb849ec1f2c6815d91cc006a0dabaebd3af3ac87d38327cc1ca22317c54b776b12c7197c39829c1f0c17f700d7ad88938c86594d -S = 7948b018e9d0772d84bdda094957387e91179fd7ed4483091f764a2077d37b87a54f4d10069584e50314e1d866c01f1c22de215c0cd1ffff3e23b321378c1b53d0d517aa29ac262ce86dee0ba752958fab5ab69a3a0fb6824ffa8554d4b212f532611b10a28faca706391ac2bbe04a9603e4f15021ddbb1d47505bee6ba83c28 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = 31f8dd3024b0487ae1e3a7af9032ef7c76d5420d617771814747c09b2a4ce9ba3ef8630b4e01e3fd5c6c24f588ebe44433682f5663e2df2b6978640bc2c3c1763c69d75b59efe68af8cf516a32cba1ef8380cdc72a3eb9d4d217fcdf7136e68b7173c2870e245808ff35b677587b3066af45a6c97d340563c84d107eff4d61df -S = 2146e1bf9d75336d7bd76091527567c9326df14a810cf39d22eb91589584caaecd89ddc1b3ef0782e79e535b0bdce8eba2d7f40aa05720278e6c3ed8fe58974fc1ba6cde3fdb79284b64eeb5d08fb312eab503fbdcd85c240414b8a9fb726f38e2780d2506381d90eccbad3c075c7fee67e8a1da037f14fc4a6d8f06c301742b -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = eb2a75ef219b2bec0987c2623a76a8d3c292754519c47f8d541aa8cd9b6c7b3cdd3f7825c2e9ab33e2f684eb34cbe27ac98971b1ba34364e5f15687dc15c829e520a9649dc0ee48fb8aeab8340293ffa869b5c8e4720bae91a3ce140ed7b3f1db25478625653fd8bf378e03346dae7d9638fdfe5a7d032e6ef59bc1e070fdb40 -S = 885c184cf7e40453f8dcd49e1336c91adfc070ae886b23b561cf444092017a86594dbc09c484d6307201633b4476c480994c4bf0a38195d9e9065dee62f5510cb0d9b16a5a9e0ad86eee516a090809e599b4b7022333bdc1c2f9b0cd181a897108c8db6e2abec0c9c6acc426e55ceb9cb4dd565af9d0eadc24ad33bc6a0f2f9d -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = f1cf2ba2463023a1d329957cf3fdc044ffecf8ce0a11f9b6ce8b7ba5e5db07d03d8d08c1c61b255a6d0ece174e661593253cc04e06a69cad4fdb1442da97014e77c1c484994c93104f5b10d876a820022e26fab68ae57e258c36c9ca501106ef87b38674278b14cc61578248d48b889800f2cf8ffd9748266ce6c2c4af0fbcbc -S = 56c800772a63baea87e02adecbe6e7a1cbf352ec6c40d68d02035a8ef54e3c5d4e4c8d23a686d186ab783dc0115ff56138f05cd0a88a28df8304a7fe8c1f944acff2c51ba447d333e97a053aaf222bb6371c35d37a3c7345f7ba81ce99baaf2f165c3a5f0d9a1200da7017de8ab65c35cd7d082800fd13fb87c37ceff83e3dd0 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041c084f86c411436b0111c733c5642186a98d5a8dd8cceb2746ccb8342c -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = 8b61c39efa507e17cf4d575bd600286d56a40e84f35d6c06d3cc33b400e161220df1c86bfd0911226081008cbfd4fa0c3aafc4de70478d089ff02f8e0cecb2e6a68011abe64d4196f9de70a9217e8bad594c02df3891cfe71750b509761fc59f9c3627c77ec61759e28c2e1cc4a5e339f9a451ef12e23b8983154d8d0524a437 -S = 1daeb428f8dcb93c16b0b96a23708a4a0b2e70ab7fcc2fb16075f901f94fc9bde149b26c83738e58dc598bf4e1c53b34adb69d93f30726a174ac87c1a1b67bf70fd83fb9b89f476fcb13cfed84c2f6d6a92294e0eae0bfdf91119cb692b096c9bc3d242a31f8a979f965fb983031b8f33f18b1713cab83c1391005a94b79ab31 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041c6c72c171d3d71a0bc8488c39813a0b20e2e937a13d9484f6c5de23d1efefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = a6cc1c55dd9b8da73acc6716344503690a9db27bb439518719b41da28284c9894fdbce9de9cc032cf7af6df2d5c658e04121a61c58be6848c2f5ab07291394bdef46b09720b985cca5ff6d22bbb5a4b3a4639ff19ca49fe80f8787c30934ea92eed3694a6ba93c0dac840eacd05a0e6b9a2d430469311fee6a3158de0c2ff38f -S = 7d914ae58407a2b981e58ca575a81796a5d3d7073f6cc3b2641338fff4b963c35125e99360b8bebbd12add1919ae46f84c67b642b43d48360785d7d990bd6b23a24feb54925575a46c2e49d5ce16204ef0c921a25c31fe0b5ed623b2a35be5069b7a7fa57322a9fdcee5b391451d49e624fad211494ac3230efbad44cc5f739a -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = d3787e2cd5eddc154a3b29c8a5161cb0ef6fa97d6b90c9d579677d46ba22108075fd9dc13958d290c40df3ae2400224a1cf8dd74c9adc8d48522ad9c0c34c1bbde732954e432bc6e55da0beddb849ec1f2c6815d91cc006a0dabaebd3af3ac87d38327cc1ca22317c54b776b12c7197c39829c1f0c17f700d7ad88938c86594d -S = 73b08114f6256d434c5cdc278a9ca697ea2447895884ce05170dd41d5073ae0b6e346ae64fe886287151e0c6aab0aca3638e5b82d63aaaafc50f8070b592cd052ce7bec9306ddc4760a6f6f2166e40800715103f938698a68a10c73ddf524c6c6e55f76f7a0ab7058cace263af7061fe70fd93ca62884d232195a91acc38af2e -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = 31f8dd3024b0487ae1e3a7af9032ef7c76d5420d617771814747c09b2a4ce9ba3ef8630b4e01e3fd5c6c24f588ebe44433682f5663e2df2b6978640bc2c3c1763c69d75b59efe68af8cf516a32cba1ef8380cdc72a3eb9d4d217fcdf7136e68b7173c2870e245808ff35b677587b3066af45a6c97d340563c84d107eff4d61df -S = 6707ff06f4e6fe6cab612b8deb099ac9995511ff0f43fd42f9f1822105e6c78cf6e7bdb117f5a8d554000aeb22c69cd0beb7cf1eddaff92161117f08befcb01605e3300826c87f2fb10f6e34bde865db2c5b7124d3273a997b115f3d0022d0cded54daed0b4ddabfb9b39abec2f9b1e052a89c4d64f38a7649729ccb14f72650 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = eb2a75ef219b2bec0987c2623a76a8d3c292754519c47f8d541aa8cd9b6c7b3cdd3f7825c2e9ab33e2f684eb34cbe27ac98971b1ba34364e5f15687dc15c829e520a9649dc0ee48fb8aeab8340293ffa869b5c8e4720bae91a3ce140ed7b3f1db25478625653fd8bf378e03346dae7d9638fdfe5a7d032e6ef59bc1e070fdb40 -S = 43a9b4ac08716a3fa5e6ea8fc5957492d093b3a4293df69efae3501e938dc25f551bffc491abbc1059543280c8f48e5c97ae0fe602c911eb894804ee585f2d3b9de882856ba2bb4c86c6a14b8126cb02be2ec6303c228dfb892d3786ebd2a9eb3247581ff7f01a2d0f6d4c75a96dcb4e98fddd204eb8d191f0896506fb72d2ea -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = f1cf2ba2463023a1d329957cf3fdc044ffecf8ce0a11f9b6ce8b7ba5e5db07d03d8d08c1c61b255a6d0ece174e661593253cc04e06a69cad4fdb1442da97014e77c1c484994c93104f5b10d876a820022e26fab68ae57e258c36c9ca501106ef87b38674278b14cc61578248d48b889800f2cf8ffd9748266ce6c2c4af0fbcbc -S = 6db3e5bbdfe86efac37bc19abbd07d9209f67876d0ed8f8859b1826d98eb22fa093e161274e4a38675cb76224a70346730314f08475db6ce6fd77d840b9de3063c88e987fb244ac823e962b31ec648ca8942e378a2f7ccf7400b036aea7c5a11e694d85c3c929e43613178eaade378d3c2f6805a14d94029f4a5ce89a87651d7 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d060960864801650304020105000420659241b16b3fb30e5012378eac6d83b927e7fc9d0eb5a5ea9d1b75d48441a6a9 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = 8b61c39efa507e17cf4d575bd600286d56a40e84f35d6c06d3cc33b400e161220df1c86bfd0911226081008cbfd4fa0c3aafc4de70478d089ff02f8e0cecb2e6a68011abe64d4196f9de70a9217e8bad594c02df3891cfe71750b509761fc59f9c3627c77ec61759e28c2e1cc4a5e339f9a451ef12e23b8983154d8d0524a437 -S = 87ee0da9c96d9a17f63d3e9e142181c0979c381ceb769a370545b535abc6eb8981d3fd4029f529909f620d2a00f209b6ad7c8f709fca13118e00a2f21086fb3a4eb4e416a0b2a121e4f7be5b172a8ed12185948cdb75575fe53d883a354f17baae73fe464d85ca0519b980a4b6f565bc0e76060f86b4cb3e90b6c4b9902f5bc0 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffff003031300d0609608648016503040201050004200d04ea209c27fd97098f416a6410afea38ead35d43b7a1f93d7ae04f7d62d502efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = a6cc1c55dd9b8da73acc6716344503690a9db27bb439518719b41da28284c9894fdbce9de9cc032cf7af6df2d5c658e04121a61c58be6848c2f5ab07291394bdef46b09720b985cca5ff6d22bbb5a4b3a4639ff19ca49fe80f8787c30934ea92eed3694a6ba93c0dac840eacd05a0e6b9a2d430469311fee6a3158de0c2ff38f -S = 8be4adcf1f21261f16ed5b4ce29284399e2a6b7f6339ebb94fcd8c412827911eb5e626d6c83315a59db85bea8010ccded74991f98488fc48989b1854619acccb63fff3d1e4e9a350440744e8bd16631f39ef2a1426b8ffc33418dc7a2a0bdd3330b0bbebba1f0b9fcad2347a875dd89feb43506c0d8e1476e36c9fc6a2798ec9 -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = d3787e2cd5eddc154a3b29c8a5161cb0ef6fa97d6b90c9d579677d46ba22108075fd9dc13958d290c40df3ae2400224a1cf8dd74c9adc8d48522ad9c0c34c1bbde732954e432bc6e55da0beddb849ec1f2c6815d91cc006a0dabaebd3af3ac87d38327cc1ca22317c54b776b12c7197c39829c1f0c17f700d7ad88938c86594d -S = 70fa48adbbe7f5cfcc61dd844ec0948d8c20ca5bca62cafb0d7014413350c5fbbbaeff1d445a7367420b1237dd316db6c8298d5ba13a3b26cbc48a84081bb12848cd8acbd198a7250d0411ed8d0e56d0163c39853b3893655037f6b4774be21d62c604522904202d6aa0f11aa1f7f56612e85139ac0d577593586d6229422289 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = 31f8dd3024b0487ae1e3a7af9032ef7c76d5420d617771814747c09b2a4ce9ba3ef8630b4e01e3fd5c6c24f588ebe44433682f5663e2df2b6978640bc2c3c1763c69d75b59efe68af8cf516a32cba1ef8380cdc72a3eb9d4d217fcdf7136e68b7173c2870e245808ff35b677587b3066af45a6c97d340563c84d107eff4d61df -S = 1a7aa3bb07684cb72a23a570dd06eec11f1ac1e5cc02108b6bcd7145c413c743da8706a44db575b7053573e975ea2bc111821612f14aa001dea6551863e34af0e68d6f9281cccf590d1b2528085cb8e878a427d320c73806a3af8b498b7d3789b66dda4ba9d6c26d15500c71a6b663d9612076792513776921503435d6578b6b -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = eb2a75ef219b2bec0987c2623a76a8d3c292754519c47f8d541aa8cd9b6c7b3cdd3f7825c2e9ab33e2f684eb34cbe27ac98971b1ba34364e5f15687dc15c829e520a9649dc0ee48fb8aeab8340293ffa869b5c8e4720bae91a3ce140ed7b3f1db25478625653fd8bf378e03346dae7d9638fdfe5a7d032e6ef59bc1e070fdb40 -S = 706c8a70281ab07dca9ce73757279e70621358f1a5bad91bb8d0f34a4519c625ad000df75709b7fc805ee64e1a0e8b2f5c637a833b682c707eb21ad79f99d9f82aa91ca1f3ceb6da9c117c96391f547297cc8f507cc4363f9f2ff84fd9c8f430e84740f3d3d9f385e73d90c8769da2615e46552566f456f6a675d613b8a97678 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = f1cf2ba2463023a1d329957cf3fdc044ffecf8ce0a11f9b6ce8b7ba5e5db07d03d8d08c1c61b255a6d0ece174e661593253cc04e06a69cad4fdb1442da97014e77c1c484994c93104f5b10d876a820022e26fab68ae57e258c36c9ca501106ef87b38674278b14cc61578248d48b889800f2cf8ffd9748266ce6c2c4af0fbcbc -S = 5b3567d2742f596b42cd2e3951f75b8058a98d822961f5deed17ce86355fef06ce8f1b1e83da9f27ac4203d2b6a406ae2657993624344fc760a0ade6106028e2dd68646f1c6a735547aa7e4d4e6ae1d3f14610d5eebc88dfeeccf979d93f1721554c67bdbae99dcc2efcf3a98eeb6bf713dd3c5fbfa44e3b9467838744d226bd -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d060960864801650304020205000430582a092df1f38834b32c013209c529a91289d7e595d648c1a633680988e5c8f8153c37c9caf89c37578d4a5cccedf712 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = 8b61c39efa507e17cf4d575bd600286d56a40e84f35d6c06d3cc33b400e161220df1c86bfd0911226081008cbfd4fa0c3aafc4de70478d089ff02f8e0cecb2e6a68011abe64d4196f9de70a9217e8bad594c02df3891cfe71750b509761fc59f9c3627c77ec61759e28c2e1cc4a5e339f9a451ef12e23b8983154d8d0524a437 -S = 0a23fdb9060b70ffeb690d0e4be5201499f3623663c4a3c5b8ccd937c20523fcdf526db4279d7d7f1067e241b0d7f00de2841934691747976f3c63e68048702b69db8981d8efba63f0fabab14abf2f517b0d5caab537f187af9f46414f070fa5c1fb9d2eb6858476a5af8bc82b7c38aed298f169f1b962aa452e5f6cfbfe766d -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffff003041300d06096086480165030402020500043061ec010a79fc79f61a9051dae86a56fd57b311f7d5043f4519aae525d02bbe46a433dcc6aad89016c6298dd09ea7ffecefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = a6cc1c55dd9b8da73acc6716344503690a9db27bb439518719b41da28284c9894fdbce9de9cc032cf7af6df2d5c658e04121a61c58be6848c2f5ab07291394bdef46b09720b985cca5ff6d22bbb5a4b3a4639ff19ca49fe80f8787c30934ea92eed3694a6ba93c0dac840eacd05a0e6b9a2d430469311fee6a3158de0c2ff38f -S = 9bda2d9a6a3570737eef2c75f5fd4891d9e8acc102654decc8321b2e114ae8c2f615a1173d855e5d4261a99dc7f825fccef11199e57ba30d98502c237761217261dc31cd14de68201278ccfb46459323d192fdce1577a1a9098e5c7117bc0e52ece3403e0b35fc64969342a72ad74e0330a10a50b67536b088372514a8436de3 -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = d3787e2cd5eddc154a3b29c8a5161cb0ef6fa97d6b90c9d579677d46ba22108075fd9dc13958d290c40df3ae2400224a1cf8dd74c9adc8d48522ad9c0c34c1bbde732954e432bc6e55da0beddb849ec1f2c6815d91cc006a0dabaebd3af3ac87d38327cc1ca22317c54b776b12c7197c39829c1f0c17f700d7ad88938c86594d -S = 3892627dc93f65857a6e773202ee6d8bfed806ec2580f1f63fc7bb547d6ca2d2459efa5aa6cdc9513153ef2dc2f9acc0a3f878c4b3a149b674f246842610ec9d4f8d2038bf1126632b588b7c8376066d1b18d85e51ec221efcb5f58e6f3f4fab1fb6b232d443cb16484670b1adec3a450f9f926ceee02c6ffedebc4664a9c5bf -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = 31f8dd3024b0487ae1e3a7af9032ef7c76d5420d617771814747c09b2a4ce9ba3ef8630b4e01e3fd5c6c24f588ebe44433682f5663e2df2b6978640bc2c3c1763c69d75b59efe68af8cf516a32cba1ef8380cdc72a3eb9d4d217fcdf7136e68b7173c2870e245808ff35b677587b3066af45a6c97d340563c84d107eff4d61df -S = 6015144a01c388c92bd4913907fe075a42afea023989156b840a493f074d55164405e50a4105d5ba9810a9c761f4626e6e05bf7ec4b47b07ad459ff404db6931f4a994a1911fc65448163d369eaa61674ce2112f79a7a9f541f26a111a605b9a3aeda1db6627c59bf723d34153769d18d9ca724570484583b37ffbb11bf7d4be -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = eb2a75ef219b2bec0987c2623a76a8d3c292754519c47f8d541aa8cd9b6c7b3cdd3f7825c2e9ab33e2f684eb34cbe27ac98971b1ba34364e5f15687dc15c829e520a9649dc0ee48fb8aeab8340293ffa869b5c8e4720bae91a3ce140ed7b3f1db25478625653fd8bf378e03346dae7d9638fdfe5a7d032e6ef59bc1e070fdb40 -S = 45d7f419feda3099092973f1d61994225fec873a0467b1348776a3a6578a10b24be941000311519cf426aa8bdf45a300d7eb31766e0516988cefb14f076c0502a9f7421ff4965875bae992930322d34555cd32ec47d8e6b1ddf95cf1eb193ef3accea5db5343a80d0d36d4325361c7180de57dcd80929bcb9fa166ecf930113c -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = f1cf2ba2463023a1d329957cf3fdc044ffecf8ce0a11f9b6ce8b7ba5e5db07d03d8d08c1c61b255a6d0ece174e661593253cc04e06a69cad4fdb1442da97014e77c1c484994c93104f5b10d876a820022e26fab68ae57e258c36c9ca501106ef87b38674278b14cc61578248d48b889800f2cf8ffd9748266ce6c2c4af0fbcbc -S = 22a5c4a08adf1a8d1dc26d0a3f02af5f12062b82e10743fbc2ae74b0bb533de279bb57bb6f0a44f9b79c2621c426e9e6b5f50a5a8a2df9d46ce9fdbdd0bf6e74cbe2e55682046145a7e40622bc81ec945e8b87a8a9b9ad711e7626109772b64be7a7ad7d5f3b3aad20c03eb164716b62e0851f1041930d4e5ef4b50bff82f425 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d0609608648016503040203050004406aa75a3539ad3822952b91897813389ae2946b072578bea95a64f583bb5eb9a27a8e44c2405a9681d9a290e2cd55fbd59c381039de0e21ff120d2a3ed8889277 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = 8b61c39efa507e17cf4d575bd600286d56a40e84f35d6c06d3cc33b400e161220df1c86bfd0911226081008cbfd4fa0c3aafc4de70478d089ff02f8e0cecb2e6a68011abe64d4196f9de70a9217e8bad594c02df3891cfe71750b509761fc59f9c3627c77ec61759e28c2e1cc4a5e339f9a451ef12e23b8983154d8d0524a437 -S = 088942923512cc272b5cd0b40d4aac42ea3165c74c90970ebdc46b5fa8c0b0e153f85c446b0a2d3886c7fd468a47efeba91550c7f01167ce009a4d6a3069bb280b6755eb9716c03f64cd2788555b9f8a0e85d74879dfa9c48ba3ff2002a8b0de02cc8479ca2a59966994d36c6622f4297e2a26cfaa824e447a6badb92331829c -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffff003051300d0609608648016503040203050004409bf5087cc76d346579861f84faef10011e190ef00bfd9b708719d5b672952c0a5f5a8fea8c12b2d738e0b420d785e6a02d7352b6a0e3d20ea2c2140094278b52efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04f7405154be02c482bf07115b27fd7f988920d8207937bec317f1791c11b0f2325851c35ce42bebc828c946438cc22656b702cce2a0dad6d8a5ac3fe6fd587c36f81ff5edc977edf9c6c085efd73510ddb2532742367f8f878814c1714549dcfa17dbd5d1e17ce3dd1a9893a3785bc34c5205df3978071aa36c9e86bd33cba1 -Msg = a6cc1c55dd9b8da73acc6716344503690a9db27bb439518719b41da28284c9894fdbce9de9cc032cf7af6df2d5c658e04121a61c58be6848c2f5ab07291394bdef46b09720b985cca5ff6d22bbb5a4b3a4639ff19ca49fe80f8787c30934ea92eed3694a6ba93c0dac840eacd05a0e6b9a2d430469311fee6a3158de0c2ff38f -S = 82f547779204eefa0d857ae077b2e02e61dc76ee75e709388ce33b3f227dc96c5a98148a816a4c954516a7e44b00b080cd8b05cfa4ae9ff82d64b811f62e6752904b88c2e4a9d54088a49d2d480c267b96974c46f75a4fd9cf09acca14290d6515defc75e0807334cba3f492d42a17dec01396e39d7d8335bb4d11a1c19db3d2 -SaltVal = 00 -Result = P - -[mod = 1536] - -n = d2b6c8fd44e7eb621fa6685fb62371872b5e8408af51bd1b44c6473823402418a26963b98e6fb191cf74175e64132ae6cd101133fc002a89c10bf7739eb930b9c067b52570842395657f927434aa3acbf3369dcdc3990f77cbf22939ddd5877f09c8aab818b80aa20544b6928fe62c78795a4160aecde6ab454db0dcdf1d6c13522526c5ccf82d429791059306f02cdc18c4e580ec6c2da19b3c6de63933ebeac79010c73df95748d987e96a0f8ad523b5014b33423f55922aec2ec23b9aa22f - -p = f260d143cff1e8e0931765da8cb335c0206bf7fd19aaf8ff41e762992f2bb0a660cd65f08a80fe502c9125166a6927aa1859a874159796fada835b48522f5795ed1f8d23f05016358ff908b0dd638bb7ed12c8b80b46aa858d52c77bb7fc0ed1 -q = de8e674fac0b7ea32d518a22030fd10d4298a77974db8febe195a4240dc5373e8161baf8ce47dc4fd076f64e307ea6262c35b9819bac4f142b613973eeb6a62a15a2ff09fba9ce4db7186969af925ee3acb7d3be7a1f9c85358216640fc1e0ff - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 95e319c0df793cf1c1b424a8949b9529d6c1a0cece5f6db573a538b68b529a9810830a84d7c8a3b9747d2882585845653c3e179ec35befcc5a7153e96370467f9448ca1999fba2f801f65c0857a18f138f356233a5ce4d8d80c1243c1c2f518ce8da60696d38c21731c6ca23db9ffc99974d8777bcdf1062ad3bb198fdb64226 -S = 1b5d13124f4a0ba3b4e8f102a7044d8a633ea025729f55ac75e4a8544612f229d4f43c45574983b51efc83ab611a60b009949dd032c97358bb7ae5d3b2ce417fe11a9f6435b84bf7113b23403b010fd749838823450ec954f6e3f54c13db12606ead2eadbf209d5d31efaaa0924f256d3f64692db8a2b7fd8197df13c33b160b2f8fef0d4f2ccdd1e1a5b269b25e4efb462c000573b8584d45c2cafd248348f19cf1f7422abaa402ba54274b7611c4c9db3a7dac61ce51c396cc3c59ecbe5594 -SaltVal = 00 -Result = P - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 7271bcb91b18288e874f4c04c10a21bd35150b1813ef61a7f4dc29e4c036231fcf040abb4ece169ae5afc5d696abdbb2e943a7d0464789a4a2ecb1285e1e29d16b1716c2b3313b41b4f8be676e842f1b8006c6418ea0ec2ee57afd5f62124d6b90d3693710ea9f693e55c01f113c24e04385efd3b2a3932e07ae96f295b996d6 -S = 6b9212d017ad9f4bb7ebfa3975b514bdd22240d753fef5631e1c216bc750336349255d53b857bc944d3eee3bc82805620d770e41dcba45869f47d36343ef067cae99a941ab94948bf0c02d2a3ee403c7eab0f9d6f9423c166e62c2dd61198046944b5082db4a17843229489c46baab712416e3d0a685d2353abe010c94ddf7b47f5edf1fdfc9a5e0de27d65ab5dfc9f2e660d20d169cde3e2642393edd79fe7316ec4ebe61fb88223f6711e138d09ec3d76781e73d93e7dba9830c53cdb5b0fb -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a050004147c3d3d4d94e5e297419551f26b517d0046a98d9c -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 1484f58f6b8cff56ab4b81d17967dee7ef1eabeae57c11706fd2735ea6655145ac636df2ea1b2c409c6c3e31907e813d2ab123eaacd3089db4966bb00741c7c48ca5f8599c539d9c790cc27f1b79bc0f331c53036a872790e9cc4c851f343893be34dfec079c1c11481253e4a3bf55051048835ba50037f1165c5f0478a76b5a -S = 57b3646aae17304bcfab8b6477bbcf791ccfb4b20001b2c3cd4e6dafe129934f2c401b07eada6a4b2db9393ffed36a8ae8af85b1d433a398399fc0c2956959e99c12053ac3346710ea5d9119fa4757032fd1739b426e879214afe364a9d274d383e4d1fa64b0b07c6f6014dcbeed59ee0dbcbec90cb5f3133daeb829855d61b88777d806b5717227a8016a965f1bd2080b44ef80bdbd0bf0c494ea7baf09295aacf161c433320fa81cfca5ba44a71264a1d1db1d2f5baeb58eb9d623710ed1ba -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 957018ebbf4bc279aff3a28f87510c01666122399490a4c300680910ed6ece73e84b0e70fd2b53362a63ac6a1456ff26f999a142e65524d22aed70ef0ae115bbb6f3e09f7c88add73c507b311c29c6117c4111b92d7bc2c7dd1532ffd687054be9aeb700a4297863cc043a6c079308cad8a19926d0cb25ac032677c8ba28442d -S = 7d9edeb96e2eb21b32fc3707c42fc26cc2ddaf5283ed2853206e51594027fddbc82260dfb3e2da03dbec1069f0bdc63a7583f0ffc194ba158860fb0bd13dbe22ed34f7f77821b58ff1b6d9a6721f91914d3529d5e605b813f7de832afbc57d7ba570a4af8f9ad2b7ea8d2c1656c669e1df7d3c112bdbe212d37d61ff62d03d8b19426437a48977ea5aaf5eccdb7d90d1e8a1c652cb2333984cfac0c1432e42fb16168a3760328039d1a836a52baa9be92050e96dc86d37c8e0b0684d445be018 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = af0272c90402a9c27f9cf6c9de652cb7a3a402b4695a0c58777fea11958fc0c51f45e6b857a6e0afff42905628b7aadf457669ec83ca80af5d16544f6a5e688e7a0818aae2e48b80146be3f77344b69c650dc28aa957dc8debf22a87956c9212e9d472664dc3927ee59e5776671539382bef7657820a083b499dd57fbec12797 -S = 3cb0d524151a8e3210123ac13086c6299074f5b5a4276059cc2e741944eda31a80aada9427d0a7e49823632075093e4f779f9b84ec4f159227e650c267cf7126047f7d257dc6e41ec6113570bc231681667735d41085ea92a2b9197fac8e4ec9bfff1d2b16f65ceeed22741a872a05afd641b1444a928a948d15248b119f28b3d35e28a337096cb7bb97e7e3d73bf1cf8abdad9cbfb84481a3e124b8c345a2d1065b1713de71e0ef6b8beddb6d88e82379960bdc1cda7ebc4c4c4ea9bd1d81dd -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 3797ad7bd2b5c611a7b1a15b8337058a1e2c15cc42418d7b2fc949943fc8076cc64c6d9e3c004e489efe297711e5f2dfc92b15d029b5b9652ba541ff037419f1ff40af7db267bf005154d4695d990cef823e1b04c0599284c8df6233a9ba9b66ab1c7a007b12a3a0895cab19af7cd923130d2e504e56a241ce1fb11978c31632 -S = 0a34ff5dd8d7ef76bfd56bd4218ad50c22cee0af0532674427c7e13f8b99b86e7128316bf2084c6477180283a7b3f4f4aefe5e0dd4aa136a2920ea70eb23b0e8b8b2c2a2c530f4efa1b6bc59d2a83547cd5c4043ce497639f609f05f3d4d2099b07d9bdc0a15690b7bf2da73def963eeebe118e59ead6dd89f0fa271645fca4d9bf220080a850649f48709bcbcc1cea3fce9618bf167e2fdb13a1ed50eea093d1070c5bfb162b054317f2e41bb3099c39d8e2c7b0b771da05cb7b7bd1abfbfa8 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a0500041486d9512b229032778b2d54e07bd553ebe7f36713efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 95e319c0df793cf1c1b424a8949b9529d6c1a0cece5f6db573a538b68b529a9810830a84d7c8a3b9747d2882585845653c3e179ec35befcc5a7153e96370467f9448ca1999fba2f801f65c0857a18f138f356233a5ce4d8d80c1243c1c2f518ce8da60696d38c21731c6ca23db9ffc99974d8777bcdf1062ad3bb198fdb64226 -S = 19ca086cb98c4770fbd6b70206c3896f966c968c1e5600a2348f3457fa823f053b45b75f0da759994d5d047922efa5184fd0499f57be607a9ac63a1926f8317e6845934a37cd58c07831a970d9599dcc15fb50c629caff451c96e2e2d7f9e3842e8dcdb8011adc8f5cb1c01392218d62285442d9b651b2a0369af3f99343dc8e24fe4f93fdd490636e78ca1b7ae73af5ee2bc0ab6a0fb42ef612c3260f62a1577c3b41bcc25e8feaed1f53e0d85c8155c9c38cf72385ae28e96831f891e03ad3 -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 7271bcb91b18288e874f4c04c10a21bd35150b1813ef61a7f4dc29e4c036231fcf040abb4ece169ae5afc5d696abdbb2e943a7d0464789a4a2ecb1285e1e29d16b1716c2b3313b41b4f8be676e842f1b8006c6418ea0ec2ee57afd5f62124d6b90d3693710ea9f693e55c01f113c24e04385efd3b2a3932e07ae96f295b996d6 -S = 843e9f1f0a472be4a3bdf456281eda82aaaa08a0fab173f2086bc03f8b88c0517f457bc276ad144c1b53084d736f2077b0c05f451ed6544a36bd26e902592b384c6d33587a79f2023226fc7c52b1384bc6dc83360769014fb5110245b2395baeec2b3087f6b6eb5de706d08fa7eb069c749a56b91d43d1ccc8f1631a597beaa6486a618b85a2982eb32fb5039584c65f7f07e7c31663a06f48941878f1ef4cbb657f18cc85db6e9d1c87ff81fa7b1e63c74abda333de6242a21a43789749bdbc -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041cd6266f6d4d47969031bf6bd3800efb1332f5c75ba7d91394de470bb6 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 1484f58f6b8cff56ab4b81d17967dee7ef1eabeae57c11706fd2735ea6655145ac636df2ea1b2c409c6c3e31907e813d2ab123eaacd3089db4966bb00741c7c48ca5f8599c539d9c790cc27f1b79bc0f331c53036a872790e9cc4c851f343893be34dfec079c1c11481253e4a3bf55051048835ba50037f1165c5f0478a76b5a -S = d140b01f9d0d67a4b869fa67c115919268657f97d846886f07174fe6a30be909a74f1dfc4590ea356e349bce40547539e76bc9011ea133356c6f01b7739126c8af29e307966bfe39999625ef989faf817d0ad6378fe5dfcd5974089349d977c7fec62289b760b4c7679d41e463be7e3f996cf1f66e48cc004f5823b1f7a94524abd06ff35fc4f51fe6bd16dc4b43eb360ca18b4c4e5a33440d748dc7fb1ec3a8344f4e175f52479f4d93275e03890664fb3a2941187bd023a3a277fa840986c3 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 957018ebbf4bc279aff3a28f87510c01666122399490a4c300680910ed6ece73e84b0e70fd2b53362a63ac6a1456ff26f999a142e65524d22aed70ef0ae115bbb6f3e09f7c88add73c507b311c29c6117c4111b92d7bc2c7dd1532ffd687054be9aeb700a4297863cc043a6c079308cad8a19926d0cb25ac032677c8ba28442d -S = 10699cef91c348ab96ec062c0a98bacec04aed2bc2a806d8553258ebdc999abd59651e8aa7236e50eaf0a183e278a956de7ad6c3eacf7e5a2dc1e46a5fc1ff58d09db56580d924de5c3ea9863c006cd9f1556555b024a670c316d2de697976a3ce5d3994a758220cc83cffce43f7ce42942c3caad5a477c494d9581185c4e5a69f056778c77784a7fcb246f3edb1cf93bd416057d0c2ebeb36647ba8796b50ea569930132d189cb43be8405ea210b8e2266807620487791839d0e6ee4dcf9d63 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = af0272c90402a9c27f9cf6c9de652cb7a3a402b4695a0c58777fea11958fc0c51f45e6b857a6e0afff42905628b7aadf457669ec83ca80af5d16544f6a5e688e7a0818aae2e48b80146be3f77344b69c650dc28aa957dc8debf22a87956c9212e9d472664dc3927ee59e5776671539382bef7657820a083b499dd57fbec12797 -S = 90277451b160d24cd2df6e5e84e2f90a8fb6208f3395a305e299d5005656a153d27801084f7cb76fd0e4b8d118f84214416bc65446cf41fdbb6532c07b718ed82e34a8b5b52575e39de48e65eddeced22e5556d89103960a228df0efb047ae0e1569e579b477b38198045bc3f4cfe021dc9bccc33f10d3ea30a01c7c567ab22bd2d0bbec9c57dc990bf0ef19fb5942f116ed33510ff76405ea1cd99c0b47ac687d8c66f9540685d831302c272de04b4459951ff480f99dccbe3b0c01f3330560 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 2da2547df2b14d5f28bd5cd71250f55cd840a11e7bd799470e30938124e4dcb985e7a72325aca57f5690d59a3c759e1781ad1b6f4b1bb6376b94f8a2d88b9f465beef1238b4b51e1fc371059b4f08557de41609ec3a63b2df5b172c1cdac359b1880db830ed6790d847bb41b6209d3a356c419b3cac251b2144faae8ed8fc541 -S = 8866a8d6767eb3a88cbbf6075ce1ff085e541e3dd305915cfa2ebc94ce8d6ae9b7a76d5770bd4e96b913fc41824b59f3066471b054f744efe0fda0f12fd1413b755f0c1d93fa3bfd00dbac16cd6c83a947d71645aa3828b7452aef6b68a92f83dbb48a041ccf1905e10665e186d5aa85e502b36dacfec5b1d17ce9500caef5e8eb8b51cff080368b75baaee54886e602e722d2b9d04dbf05026624ec6fa772830090c570c5b8ac7594abe3ab312d46fa3294dd96ed9c2642672154240e66b197 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041c9d529ed5fc99f3b9f2d3c3abce14aa723e6ee9397db13c35a355fb87efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = df8494995c51a92e651ecc6229ec4c5ffc54b2975876ea582233a3a02f9cf73207a94fe9e92f814d0f0c3c6432a4a6cb51924304af9719121bd612437344a14e6b5aa89d8b0d9aec77ffdd1373f77220268fd7a99e2c2c61953396e8f37ae1e894fd695d4ad33a3426607618f3cbf78904b2362e301d6b6c1ab1f637b627fe28 -S = 8474bb2649667bea417d1a51fcf6cf891c29d838c7002d7189b945b53436cc0b67175e910e2cdbd3e1855326f7c0c823a8b76d06b2ae1e0bc6a835a524401b5a280d07f09acd94ee745e1a789919128c617a683d1b145b3adcc494aa701c2fc5895d14ba6a7798c3fa51a04497e78413200b284a4b50bd82f0b7a1a4b3b5b3cae15e345844b0b7f155e48bc52fddc2a83648b2714daeafbd0c8c36de1165cdaa75bc8442b681b9ecc1cae114e629b13956734aef0ad11c421ebcc27202df5899 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d060960864801650304020105000420351b72799b9cfe54802309d2be3fd5ffc3377302cb171d35af0d486d4e664516 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 73a012bce858e0ae42fa2893a0fb1439a73a9c101841b28ca8c8bdcb0c7b497853fefdef782dcda238a871bb218f1503ec8a52020c0d5d6887da7eab05c7c4f226c1f8321911cf966bde63251cf3e49ff8c38ba724aad027f876ddf10c2642a296f2eaccf38b4e5483a3e818bab0ebd574ed314989a27594a2a6c2e44b222b51 -S = bd0512605f506b906f012de9f50ca56881c61edc331d8b36996b4eefe75b4751b6ff980194b52e19b82dc85fb3428c86905aea1e59e9db90018ad5471e29ec170f18b9668725a562caf850ef41c7ab871448a6f428db6b2ddf85fddf029dfbbff5677bd92aceaa9372f9a579a2f7fbfa8872f8de3f7b15c5095598d39b3808f99cc672d89171302a7e7c3430a1ae675cf3d1b3341f432b4c57a372f9be3a06970f2c4ee3f557b98a8e767db450ff29a491163330bb3438432c5dad3dd8dffbd1 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = af51ab7e521b64502702bd561e40dbb41e2f80afa95bd562bcdc67b3f6e36f86fd9256311e11782f33de2918ca64f5d083d02cffba209fc2667ca4a141ca60c02a7d4559c7add9696e6db9aa4659dec2a96e20bacd1ff8b1a4a48ad20096e383fbb97fdf96190e67a05877f4da461ef158b263c62a806b973cfc222f7b6e8037 -S = 6ed6b46b522f09d6c1007dc32e593a2dec403c5f318e9ce0edbbb2ca6b9b05803ba43c1828ce2fc0e2fe8feb4f80db80e1673e111f204a6a009c115f0a797006bdfc5b5258404e259aa0f9d72957d01f92b756daa9981952dddb0bd1b1aff6caf46ccaaab62a15f52c79fd663ff64b94ab8428c04780efe11ce1a210acd89e63a26f4a48b9e4acf7c327521a9654ffcdfe03c6baec5cc8bc32731d6a9254302a69f56bf43ae8b82738e8073f073dfc8c386d9adb0f1acf16e59710e4e519cb42 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = ae4dbe3079ef09f963a3da04099f596a6eed3c979d798eff8f69af0d4eac9d5c5bd6712a4d2b2d0abcf9b4d85d2c1af26e1c1ea555a9f5e6848a4a439fe28219e1144406bcd939a1bf901069bdd5c6fc2c54248acbdf898888bfe9a9a048160a08b13eac0c22b528360df59e71c2e4ef6e3e552c4744d04e62b096279907e098 -S = c7ad03de788a43496f2ebed7df3179788360095e880785bc5f9135be256cbd7693ff1c47d7dc74e1e3f318a533ad50850336d64cecaf1b6b6a317332810d433362eff2b03b6730df4a04ac3c69e18e752577cf8ba9bb0981a2c6cfc2178fcaa3bee1957cf10a74e87541a3311e40206457a11efcf76893f59dc78cde650b0571072a9af5500dc76cfad2bce35057768b97046adb84a67efce9d9f569839e3f36541cf0b24862f8311796edb735476eed85d8290619b56237a89028c92b3eab48 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d0609608648016503040201050004208aeae1f557c4b574127603b7da392e75ad6df1b94d840cff18ca38033d5cd0f4efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 9245f9e8a7b4e2c8744d5bd42ebe68ca32426a5cf7c5ab78414938cc9888ef8af9dad868cb5ab9ec1444e4e6eda2543e3428f8ef805c4f545afa35a3aa96fdb76f83bf12b3f4f322bf613fc38b2c8e0678856230418b6b062fb358488d6eed7c5c0656ec48c9bbf2da6a1473eea43faa68204f27239928172a3e49c52b58e861 -S = c9e9152887b5111f721aced7cdb0e7368b0eecafaa1506ccdf35c378b633937d08544493a1e8aa84b5b7f892d89976f2ebfd55ae85189f61fb280ebfff5a01fc2c90fa4896ebdc3725ec472631e69d35fc9d5a03447941e7befe21a36ce5cad72088177d7e54cffb60dadfaf3800ca38e9751df2d4fab7738f31d82a944e0f3bf652197121c4e74ce5f170fed950f7a03906e75b7fe12469fa4d44fe8348d5459bc5f5f13aa694c12ac64912a20d694230ed95b75f3de4eb0c3c60169695e94c -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = bf15e4f37e28f61a35be4539f17d70c75d3591c19368b84c320a999cb1858114f3008faf1be1209ea1908b33a67e0ffd84670935aad46a58a7e36916844a756b579a6e0c15c11404a8d3c09f410a5287f00b6a2d726adb6a4a715c67131d81ba146aead115d0bb94710e4b466d2621acc8a91c729334f1ca433bdb5605058d48 -S = 897dd26e35a3833b069c14e173d8f90443d51f3c8867457980f0c20420568290a2e239642fd21e93778dfea2bdf3ccf72c3ee8f4334394238d52fe577d1d050dd69838626922ed9af276f888356349fd1ca8e9c17d615b9d3cdf86e86d01eebbe52dbd26c034e8a93fffe7cbca27edb1d03b13643ed4ad122400d4f980ff7b8a9864d39e9fbd5781ea4d21a06136b70a90fe2bea2ce142334403bb078095f1257df2162e9998a7268d1f05f4c483f726b9b0cfc132023c643b1b0b04b6d88745 -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = df8494995c51a92e651ecc6229ec4c5ffc54b2975876ea582233a3a02f9cf73207a94fe9e92f814d0f0c3c6432a4a6cb51924304af9719121bd612437344a14e6b5aa89d8b0d9aec77ffdd1373f77220268fd7a99e2c2c61953396e8f37ae1e894fd695d4ad33a3426607618f3cbf78904b2362e301d6b6c1ab1f637b627fe28 -S = c7fab5c4083fd43b67dcc56c10b5f9a4793ae49411b828512e4930765f496e313995b506e6b2ed4ceb29eb2b9a649e18a1c9f22fa5c89f7349bd7d8e967c3169fdd120517834c0aa355b5bb85b13b0c1fbc2e915c9ac8d7801c37cfdcc45376d8915ab57a67cb39fbe3c976e49e3a47e2312dce0b27ebb2baab9214a7af25482ca1f7d9baaca22ab73deca082b271044048505257c968b131f5dea33c1d02bd4ced74b6c0cf71cba31d989c685e9291789d2a5e906c52268a270ec8206e3bddb -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d060960864801650304020205000430ee9e3e985b715474d343f9823ce7f3fd430e13cd9dc4d9117c1a7f1c87f40e16a1012f103c90db1b979cc17934b20756 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 73a012bce858e0ae42fa2893a0fb1439a73a9c101841b28ca8c8bdcb0c7b497853fefdef782dcda238a871bb218f1503ec8a52020c0d5d6887da7eab05c7c4f226c1f8321911cf966bde63251cf3e49ff8c38ba724aad027f876ddf10c2642a296f2eaccf38b4e5483a3e818bab0ebd574ed314989a27594a2a6c2e44b222b51 -S = 28e465b1d7e5e227ca3af797f7f4606a4d78fa8037190e52819b184bb42237b64854c317e08bf3e6ac2e544eb58e0e318682224623f8912682c9afe0e81e7d9f027105c0da1c2b5f27fb24089af422f559ba97839749bcf9e968dca0e58213a0ba53547934804a1e10db9da4464ce7800e5613c89586277beaf69edc62a3e8ca2a8935ac4d0b4d65e7ebff4358be37102a70f327245475bd6673c7d092505f321cb600f6df917c6873625e5d3539d95b94be06d39f90eccb424a9e5acb27f0d3 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = af51ab7e521b64502702bd561e40dbb41e2f80afa95bd562bcdc67b3f6e36f86fd9256311e11782f33de2918ca64f5d083d02cffba209fc2667ca4a141ca60c02a7d4559c7add9696e6db9aa4659dec2a96e20bacd1ff8b1a4a48ad20096e383fbb97fdf96190e67a05877f4da461ef158b263c62a806b973cfc222f7b6e8037 -S = 198f72795be3be9f70828fcfa6fd2eb286f4d996153953730f8195669840b685b1854ebd54f8d1ae8db487802f8c6978197822157eb45c8085ae91f11390e0d8910f2bb51d1efbd743e2e7d7e16c4757a67a666c1e6bbb90fae924550847b68e41bb9d8b58b376c70c075cbedb2875bd7789971d2281ac3a591c7361030dd46afa79ef20a32f68764d40f4f5d689f3686967e57f1b718522a61ebf35e194219f9b044aadccdf0fab455be9f86a651bd9eebab4e8c798c9156880b06f12ca6b7f -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = ae4dbe3079ef09f963a3da04099f596a6eed3c979d798eff8f69af0d4eac9d5c5bd6712a4d2b2d0abcf9b4d85d2c1af26e1c1ea555a9f5e6848a4a439fe28219e1144406bcd939a1bf901069bdd5c6fc2c54248acbdf898888bfe9a9a048160a08b13eac0c22b528360df59e71c2e4ef6e3e552c4744d04e62b096279907e098 -S = 14f03b08b6e55a8aac770701ae964a627e2c35a6e5b0a086cad74eb7cfd5f30c2b481b9a23a03e61f9a73ea131ee9e0d44ae896fd815595adc40a7f719e37d453c6c2ac99f5e76665894fbba102102e31a4fbcc172d523a0feddf5f0098949041cf5c6dd729882db4a3104062f37fd0b51f990d180fd58c2894d9c306e001878aceab5ff4376b98c65864e2216702b6afe97686498732b6259a85e60e56e184515d8326d7ea98508566fb6ff79e771a08904918f19562d28d6ae334b9f15104a -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003041300d060960864801650304020205000430d641c0a68fa8724ce04f866e4c8d232b9643ff63669e3ba6b030d0ab734710b9d6ae8c7703bf964d4b827d2098fcb79cefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 9245f9e8a7b4e2c8744d5bd42ebe68ca32426a5cf7c5ab78414938cc9888ef8af9dad868cb5ab9ec1444e4e6eda2543e3428f8ef805c4f545afa35a3aa96fdb76f83bf12b3f4f322bf613fc38b2c8e0678856230418b6b062fb358488d6eed7c5c0656ec48c9bbf2da6a1473eea43faa68204f27239928172a3e49c52b58e861 -S = 7ea67611c9dec51c441cd3b5980e566f13e1191ab9acc5885d12e04c231b8ab7ab1bd388cdfbcbcd6a8c175d50296483edd4415ff4220b6af620e3ab5d2561c0db009e2ed7b094c8ead105d9067ce25c555cd306f52f183efe0bf3a618c5d52b9517ea948cc1a3dc43cbab21dfa74a44db4a34f8ef6aeb9e7fade424122a96f587a5ea94dc9b7399485d2bcf255826389209a89d5695891bae7bcfb22e430a3f5324fbfe79adc7f7fc5b143b86518022a96902fbba5a39275650d8028d3bf144 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = bf15e4f37e28f61a35be4539f17d70c75d3591c19368b84c320a999cb1858114f3008faf1be1209ea1908b33a67e0ffd84670935aad46a58a7e36916844a756b579a6e0c15c11404a8d3c09f410a5287f00b6a2d726adb6a4a715c67131d81ba146aead115d0bb94710e4b466d2621acc8a91c729334f1ca433bdb5605058d48 -S = a7395ce62131a5eac115ea950fe60953fc334cc244b13b159720a502b7194c9e65eb665e6475e1e19e462b735496d65fa8a5c16162d97b11656a85b43fdd4a819ae918d79e50e51ea1e9f5fa92f467410c61d50ce2e3b61f59be2c88cfadea890b71edb70fa87e38df81c38d315b33fe4ca4fdbd5779052c16eed21468a03b15fa7a235e8f6831ff55fe2eaf79eaf466a2280eccb8139dc16c8f296f0e79a1bc4784f37e6550264d7e26a8507b97b1e279f644a29c166be2c761e1ddd7cb6611 -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = df8494995c51a92e651ecc6229ec4c5ffc54b2975876ea582233a3a02f9cf73207a94fe9e92f814d0f0c3c6432a4a6cb51924304af9719121bd612437344a14e6b5aa89d8b0d9aec77ffdd1373f77220268fd7a99e2c2c61953396e8f37ae1e894fd695d4ad33a3426607618f3cbf78904b2362e301d6b6c1ab1f637b627fe28 -S = d1d6a615340ccb1504625ab056d09a95f42836bbee98bbc1ebeeef5296adc55eb8159a5dccf5fbd9bab8854bdae4f9c73379881adfaeab1bed26a544f4b56067d1c29f473ad84486a4e48c51354e4b1a9c9ba1aa019d1c75c277a2dc5df6ec4e112312c93e5652dbe107270f02805250dc77e833637c65f2248e2834b7cb62135b43730a54e0782822fbceb33073912728dbe0da834342ff7d519404c1171b347b96a4df6bf794634247e4b15b93d7929a0e1852dd20b6c88b4f30e0a18be8da -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d06096086480165030402030500044027c454d298019b1b6718f4ebbb3e2d115f3ea8a214cc95367bbe80783dbc781438847c4b1508b6010de44f47ab6e213f32e7348b8e6d6b4f85fbfbd3b4c6e05f -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 73a012bce858e0ae42fa2893a0fb1439a73a9c101841b28ca8c8bdcb0c7b497853fefdef782dcda238a871bb218f1503ec8a52020c0d5d6887da7eab05c7c4f226c1f8321911cf966bde63251cf3e49ff8c38ba724aad027f876ddf10c2642a296f2eaccf38b4e5483a3e818bab0ebd574ed314989a27594a2a6c2e44b222b51 -S = 3a24d99406cb5a02ba7a403dc0b5b2bb87984a3feec115dfd4e5531993c391294aa226761a02affab891886acc356160bc9543f2b722412392dd5dfef65688d8084268278eb04482eee60f72a34b30376a8395f5f3fd27dd56e7a8431f2093a8ae93c02674409c492b52a1b0c53923672db546c85ce5e2e160c94e78a5d66dba5c398b97585a20f3b32ac35a4216e4b93fd85c3fc5693fff06eab4b9e0495c5ab0d93bbce6b3e16bcd9bb458b2d7b4e30f9f4a52f48311a26e3c0e9ae30e4872 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = af51ab7e521b64502702bd561e40dbb41e2f80afa95bd562bcdc67b3f6e36f86fd9256311e11782f33de2918ca64f5d083d02cffba209fc2667ca4a141ca60c02a7d4559c7add9696e6db9aa4659dec2a96e20bacd1ff8b1a4a48ad20096e383fbb97fdf96190e67a05877f4da461ef158b263c62a806b973cfc222f7b6e8037 -S = ac7598c1f1f9245d59b443cf44e1eaa00f9a213ba24fffe3b6051dd0d9f430669edeab9157371eeda529bace4e66f31f272b210b5b9308d0dda403385238d758de9d2099c516e39cba18a1552059d9eba6deca27db71e766ad67b9db321011b727619bb303df82bdbf029649300b03e0ebc3208b2ea8e290b670b2796b4ea12de9f07e6185fe508548d2516ee1f8997394079cabdb6bbda455983169fee7cca71eb4c5841c27c37762b985824134fea46bd2c95d7d82abb66894c6671ddc45d4 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = ab50f6312f99e068e4a76ed88efda9b0acf416b30500e798843673b1450be4ccf05f2f5746ba4ac7f9d5993ac15ca95aacf22085b676f42c9984dc79e63f0435554e05e859251442f88679b9da474474a0553b6877f916c1ec5aef830244f47181275f2e9263a8a289c2f89f0246e2c42f264ea27013b51e24bf9416c0a01a48 -S = 6c0b09fd6b371212279378f8e3d91a4861c63c7353e5480643774821ac72cb3519cfd77e46c6edcce92b796fdd5a511199e9b870087fd9d815e7d8c8deccfc7c229b93a038e202e60df022d0a966e6616c67a447cee59b0b3ca206e9e503e928dcb33160b9b21897e24d860c7327e83f15ca41449f7aea16a3e7d83faa458dd0f27117e68bc279367925a42ec8cef69cc1bae1df16408ca60b8f1b9fe9f837a1227153b59ab2b3707c1e5cffd79d7c11a31a81f41317f012b497e34d4b3bb962 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003051300d060960864801650304020305000440c4765be0d27a4bdb86ec440bb5259aff46c9bd89a6870bf5b87c3755ce45d780c63282898f959c929d9f144143a038c36d4d0448ef8c4663cedf5cab3d59bf0aefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = d3d03ff14b9e72bef1c6e7d29a5bb8f0ce554cf3cc867a63cdd0f1468d94d738086db0be811f82d8c9ca36d5be64426b126585074ec4726216237155ae4782eebdca24c35114758624879ada1efa61651a692527edeaf30aa4e3eaba0e7be8b67b4e63a8c26594f28965db89c0065f066fc7f5fab2e143820179251cb5194fb9 -S = 81664625093bdfe332db62e3c1f5ba000062576d95f1a82dbc5043eaa267d7602c25cb45759ae8ceb360c017f9a0c4847763e25206699792af187294514bb214a453730350673bbf2feb73033a567d4d11a6a4a13d2d1d79850bd71e4ee9b8b404d2114f505ca695a760be6b1a784be63a208edeadbd1a22c86d8ba614210d9b01b89f70243749f5be9b43385ba94ba0797219323bb1817e5e3bfbae02e2e360383e333b27c32b6685e6b9545a3a6c7742a7e0612f20bfff18907c58f3fe671e -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 076fdcedd54168af223f18c42188c7c5860c5f03517b5b00f66159dad4115297752adf60e6e8d614347f9466b83ce96b88be4ee9bd999b19f1bb26d9ea7f01b84003a907584cf232730480a6bc9692a3cf5c47d40ff051dd133ec2353e0a8c4fb6b65b5ea82aba7686f2aca7edef2b7e824b4dff3a5cdf2aec1c726d8a3dce741605abe0a0b66047ff6e3e7a1be8338af56b4cecd1e650d4fc3c52f56f29e746c7b2ec95f9dbd6dfd1f822541fb6f331faefdc00a346e86b2dd6a88076894b91 -Msg = 4ff4d6aee37bbccf415b68228612f69eddea178398c0c13d7f0a258b6719e2e0079b780a0863ff115b6d1962cf1c252ce3c7b50bd87442e40be31f1082cfacbcc570cc8fef44998e040f563d8521a40742d7f9e070644f29fbd119d41e437bc8307dba87c1a5f20ee54b07fdd0a7ddf7a322cc4c86194ed5f7ddfb2061feb8cd -S = 303e5f73eb2125488fed92692fe597994b86e4189ef71152bbe277501866f64df9de78f3d11d74c6aa48a916ce2759012ea86a862966a3cb78d8ac12d0d99d059e8cd56e83c0f5198ef7248059510687e3943fd41defcd58ad501976ec17fd1c252c13a177cb99d2ed831279d6cba8ca63ad0929eef4fcc85c985bc449030a76aff7a2b389d23b89471e21907043eb6c973ed375d85871bcc9203d6c615fa78a066e7fc5ac9f8f7099ac22d5a8b26d0608df22ae0cdbabeb81bc6f750a61f5ee -SaltVal = 00 -Result = P - -n = d2b6c8fd44e7eb621fa6685fb62371872b5e8408af51bd1b44c6473823402418a26963b98e6fb191cf74175e64132ae6cd101133fc002a89c10bf7739eb930b9c067b52570842395657f927434aa3acbf3369dcdc3990f77cbf22939ddd5877f09c8aab818b80aa20544b6928fe62c78795a4160aecde6ab454db0dcdf1d6c13522526c5ccf82d429791059306f02cdc18c4e580ec6c2da19b3c6de63933ebeac79010c73df95748d987e96a0f8ad523b5014b33423f55922aec2ec23b9aa22f - -p = f260d143cff1e8e0931765da8cb335c0206bf7fd19aaf8ff41e762992f2bb0a660cd65f08a80fe502c9125166a6927aa1859a874159796fada835b48522f5795ed1f8d23f05016358ff908b0dd638bb7ed12c8b80b46aa858d52c77bb7fc0ed1 - -q = de8e674fac0b7ea32d518a22030fd10d4298a77974db8febe195a4240dc5373e8161baf8ce47dc4fd076f64e307ea6262c35b9819bac4f142b613973eeb6a62a15a2ff09fba9ce4db7186969af925ee3acb7d3be7a1f9c85358216640fc1e0ff - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 5d7f76ed239a1a5d00c3a4f4da964ae0bc409c43ce9b147b859aeea617e8396532cc2fe1ed50c20cffa2772a2eba778f0b3de4aadda26942db9315009e96692ed5ecafbe3bb98e8ec666dcea2144b3535d72c77ee400f6a0ae5421e9b7cd3b4eb0a79f8cf41fa76abfd77a3e9a7b25b21aa5eec8cafee41c66a7bb6a4ad7d74f -S = 810510f7e41b63d4d1db17ccd919547d021c0148047ae92fa3278a1fc7d2bcea796f6ad6b927df033302d5df46b3d33af70560c01bceb46502552a8b6b67e0c754ab1bf58f5ca9f96397aebd5d852c66865c399032bac358e7a990ed6dab9aec27e664a08c505fce3dca4bae2cefd8e1b35f6d4b4216cd6572f139e4b520188e8199c9e3809938ad642123c466e0d59b172217ad290dbf74e2ada78c0b7dfe639ee88caf44535a734794406fe909922442b1bcee8fa3a8e31bfd665dd219c46d -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a05000414fe4eed9d60746feb5599bdcf486716a6a04a0e69 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 044138280eb07cf03ec9747c7e9b89e0a37850b2fc40ba6b2ae38b1132210d13d194057510f1e62c178b45cc46188d6082b8f499cd33ad2c1a825f755f92d760eb44fa89fab8fda287cbd81661def7eb81da33ed9b700209f3a6eaf7728f3c1cf959feaef58e2919349315a1f775314948e4f7f48d801fcb5e5413de94a0a40e -S = 6af0c3b45ee0b0f5182b692d5703921e779bcc5ec5e5f71fef5c480a491acd10e61166ac2b40e4246fcb28aeb5b8feb870be4a4efa13695ec211e5f603d86d33b228a41069003d18841f48aee2f4802f1dfe95caa9a3d89e5425ce06fa4d17ac2e5fe4af0e5a2f86e5ccfa21c5d1520290b2d4d4ca5096486b6012e302b2eb3cd9f906d36719f3a19e3c124969eaad2a43c2e30bea835dcad93ed550dc3137e59fd891694274cfd6a2522600c661dc496f4e4de5a58aa51afc15834de5c97e96 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 8f662067a26e81165e23ed70b145725faf2c591491ba4d9ffe8fbfbc8a7b88f07d39d0d5d55a2fb28e7f134f20cb62084a98601f0e69d257fd2064beb47248caa79720a71d461ed07ce069ddc7ecc39b65c36a62248c3ba37d6b1dc11af69d2295e9d685831a9496b1afb9bfad8edf4288153e85db0cd0ac08d7b46dc2f0d120 -S = af16b7a53f57ef673aeaf9a17727836d00e883352e7e2109911dd839ab23d46400f140af84d4cb4a5864165c682aa85eeaf4300e74b94b4f8fdbadbec540e07056b55fffc96a627939928ce5fb61e119c94f14719a93fd5f3a3dd4a8754a8bcaba64afd5e63bea1a793d420a2b6975603f2d4597b26799da0240fdb7d8b0e6e2896f63bbb46526a2f651ed17deda3ab3b43622e749bb608c6d30d41d7346f9338bbd768209e531a17e2a92b815efd222049451785565117f39812de4c6ecc65e -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = f93d6cdebcf190ea6ab2358636af5cfe4b3a9bdc1bce160bf350aa3cd3956b897e255158cd3e2e83481ce3b6f778d418764f992d48e4f7fb6d080e6b3799d3f35949c17241a0cc5ba84597166779e6a38ce45681ad944cce7c432baf9cd8caf2b33125f2c12052bbb0b3b76f2cb97be9b4813a9ff1e5fdcd478769d0ab5b36cf -S = 1e076b3feeb281e5ded58a886f653c59a31789050df263bf06401eabf4eb79b4b516350fa63b06c4ea8339190ee9ec30c3972f0009a892bc5938e17c0ad3502f5b6ebfc6e90281cdd94ee5758a2747e05d2523ba337301d392bfc6fe57890234bb1e485ecb0c2eff55c6861100b2911fe594e6db29ed773da026bea1875f334a2de2214e656f6bb25b6f84ef5cfd4158d27642f84579c1f5e185bfbe2948c2ef26e6610355e190b4c06143f487a68ff15da2f7acc9e28bbae89e9ef0c362d63a -SaltVal = 00 -Result = P - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 6f856225ba8dd27718b7c684764f2a18c19df4dc4bb9accd71a12bec7b89a337c372dfd91afecc9e678339a9915edb699f8a94c91e71f4a7c30101885203338abea8c39a926526e68f01d49597ed4db6cad35e77ee71a09814a8431f78d0094caa4f95cfeb6ae639da5b1fb150a389e888a1da4f8364b887aabe7918b6992d67 -S = 2491418adaa343b655e7a3e762737b02ee904d6d79fb6ddb9cf2043b671de59e5165f2898bace269f0e65f3e754aee71a5fa596a5a89574afa49818c7a962c38e1577f2302b75ddf53fff93ef035be0dfe14a086a27ab5a2e64808c9abc9007cfc748fac383c9c89fad72d89044c49cca11cf761d7d8e506920aeba7e7e8f187aa287c6c8878a90fbded8489789e2742a8386d8cb21f9d0b51123a5f78de74656107e562ebf50ace92da2437ed325629e66e14b573668ed6462a8ea21e54a543 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a05000414753938c49eb8f7bc120354dd8ff2177dbe9bb916efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 9fc80458af5f2489a910779f7b9d078b249a68a276219af01ac830d0d4d0b2ba089f415b7e7079eb624a9cbb8f2eec0d0d955829d71a5bade27322255ca5eddb3178b7f1d42919ac3c606c132d612eb9b886a6d705edcb9d506e63ca32d0687b223caf403bf1cc75403a30d0dd9d94362f569bd38704b2696ba13be8deb7ec40 -S = b23c38a05b861aabb41227c23af9d3b6e1767605cdcaf1627875a7ce09f99cc4b7397a4f010a3bb2d8a9c9765b9877f936369d761a13dc3c22c0db84a3364661b5c7fd39e6965e43a728069daf89612dd8dec3dc9142d6987b8345579d9be7891d315247955f70ba789d3650947de9e92948e049696a00d0e0f6d256cfa24128be180ead9af648436c1cd21d0b396d70c27c94ad8c8625b6b3dffbb3ff78c475732203c8d08a3f99e7dcc86f1c233131571210e8135a29565761dc94e77bf484 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 5d7f76ed239a1a5d00c3a4f4da964ae0bc409c43ce9b147b859aeea617e8396532cc2fe1ed50c20cffa2772a2eba778f0b3de4aadda26942db9315009e96692ed5ecafbe3bb98e8ec666dcea2144b3535d72c77ee400f6a0ae5421e9b7cd3b4eb0a79f8cf41fa76abfd77a3e9a7b25b21aa5eec8cafee41c66a7bb6a4ad7d74f -S = d1b5a7c9880f3b076d635ce4f881de6c715d0e2ac85fd08ad5d4ca93f2b04870f7264bad5c7dc9f38046b7ce0bbb4fb4e6279571533f61cde6d540c6e6bf69e4869ab76a563f30cc6718cdef849f76c75aea4c9a3068bc579b1104474d9a4849d9c3db49fee17afa5281fa7ffb848e9b33835e942e89c04e291d123f5d2bc5869f076b550dd8c04d2c2f29ad290ae294ab3d34ef54f5148b256f50c54f14dbe4f02e2aef97e39a90431b774142b3dbaae385615323badf58f309e70a1084ee59 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041c7c8aa165fbd14e4361a3bdf3f9b6bbfcbc8e14153c901f8e2104975b -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 044138280eb07cf03ec9747c7e9b89e0a37850b2fc40ba6b2ae38b1132210d13d194057510f1e62c178b45cc46188d6082b8f499cd33ad2c1a825f755f92d760eb44fa89fab8fda287cbd81661def7eb81da33ed9b700209f3a6eaf7728f3c1cf959feaef58e2919349315a1f775314948e4f7f48d801fcb5e5413de94a0a40e -S = 6883e11e659c46bbbe5a9b3470adfcfeb546bf008d1f2f272e2b3b957ffb52f6d25e0a1aa4facdde72c103566cb6b898a9f059f17b895ccca14aff8a658591998e8f106dc8624a48158e932034f9f3fd4f2692e37ab8a31d02831641d0518d4557f2588f394eac4a54510b4d4397cca2f55e7b8e08f7fbcee8a9f1c60e4f6a8fbe30b3b29bd7492aea116701187d6bcc9c91979de68b52e7c6d57e4fb9d5fd6526497be575ee861bb83e05f5b51b9cd60276d93e6fe987f4240c610d94aedb49 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 8f662067a26e81165e23ed70b145725faf2c591491ba4d9ffe8fbfbc8a7b88f07d39d0d5d55a2fb28e7f134f20cb62084a98601f0e69d257fd2064beb47248caa79720a71d461ed07ce069ddc7ecc39b65c36a62248c3ba37d6b1dc11af69d2295e9d685831a9496b1afb9bfad8edf4288153e85db0cd0ac08d7b46dc2f0d120 -S = 0e53008d7626ce138c6aff6c40eb86dece247e192bd5013880e759f96142d22d18abb6f1701b88aa28d53b0c5c13b91a316e79373a37ecfcd61df7d3c34b59ea36eebe0c6864ef63514e504a8c796780be8c2586f1a2eca3a45d45b15c4c38f94420ef563efd9fe2d8c194d01c7c34cdbd7f89923bb39bec9e8ddbb1a282e1ee18bc9cc93ab42c2dbe58ff0927036d2a66e364d88354571b75fd11f131076d6fc9c75b810b522d2c18faa4a6332cf82122dfdd17f5efa030fbb50177f97c9bf9 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = f93d6cdebcf190ea6ab2358636af5cfe4b3a9bdc1bce160bf350aa3cd3956b897e255158cd3e2e83481ce3b6f778d418764f992d48e4f7fb6d080e6b3799d3f35949c17241a0cc5ba84597166779e6a38ce45681ad944cce7c432baf9cd8caf2b33125f2c12052bbb0b3b76f2cb97be9b4813a9ff1e5fdcd478769d0ab5b36cf -S = ca58ea0da7afc7dd4a1d32ff168a03b478f296dc0f6edb2a0e859d85476f1af70d21b42f0af6fed26cf82604f8a2c5d87b50e5a5babed6d585a6a84861ae56dd2654c4884af6672ef57c63d8b03e5d7cb8ea49e6e8b53051cc64b366dab0b93fe29dfbcd7b9a0b8885711bd103844532f08ddc2edea7076e36e7ee25eb592bda6a4f862af008344117f5c51073407a8d230f2ab5aad9c981ad10842706b502f4c984f2f969dfb5090678b602b4748004984fec3a39779c2f5ee1b02c6eb77dcc -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 6f856225ba8dd27718b7c684764f2a18c19df4dc4bb9accd71a12bec7b89a337c372dfd91afecc9e678339a9915edb699f8a94c91e71f4a7c30101885203338abea8c39a926526e68f01d49597ed4db6cad35e77ee71a09814a8431f78d0094caa4f95cfeb6ae639da5b1fb150a389e888a1da4f8364b887aabe7918b6992d67 -S = 1a524bd769380e63ba31ebc0adf908a5c2b657b03a534da42eae48f044ecd2bb643f2ab320b34df4ad0938e17044d9e8a40c0b50d696024e0f717f19102f82854c626642da58c430ac865d3a25299f5d8864b418a172b331734db2efec8e44d082556d7d37731e4d4a317a22a076caf9f9e9854c1eafbdd57fae1822ab268076126f55c3ca52873885f9be15c0308210465b78e34335d6fcc569c8e4ae0f65034c0d8ffc1f078983e15e4b2bd7f46a0bf41c8ad7fbae341037c2bc87c2248060 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041c3634827aefd0d0bef3df495c39e6d596907496b91679e2bd96be6542efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 95d3ac5ad05aabd72a1c331b0bb6f75ddeaef4f4b0b6a6bdf92f7bbdb9ed8807c73a7ae0661dd0221adc48debabf9745c5175dc9f97f587f2262d8c831bd73308d26f996ae0eab8ee743a70383b8a7211489eb71083a74467d40735957c201b08fa010c4cdb5a2e23a5939d28f2a8eb7730d8536036f61dab2d134b753839a4e -S = 15893719e5cd0ceaac13914028cbc46bcfa00171d18041371ee945c546f10a0f212231090f4ab7f490ac852bec6ba820997d71467b797ff9a09af565794a85c15e3c10aac19b91f6a540afcfeca49f1660a788c2ae040a907146b4f6179d808f96da06f15daa18cb3be6b2ca0913fa91e966652a29360dc41e50c6c43ea5d633532d264b0ca09987ff3b0cd1542b4a6a48332d434ee3f02f9e0ee353d2acf260a3ac278de0ba65677b44911ec76071f74a5ebfeb33107a01fdfecbbc4645baf6 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 0b9c18c93a8b1b8fbbd036c2d5a6869c2c326e80e613df300d3ad74034fc28cb5e657b641bd0944ff4b4d8f209c10c86f92c5f120247ab9a6a54f8931d9b429b97ba7c67043dd4fda66e3923786e1a1711857180cab701a52398dbdd636127467f4221ba3dfa62ff99a6613e68d639b73be6adb2868c69b902ad8a044f756135 -S = 29dff9f009373438341a72589399904fab9b900a2bc65c371c989dd60e9c825dc222d982d773cea97be3a3c378956a91240b23eb59a4cd5b78d44fb948bc402db68a8efc3d9d7c48b55a826bab47ef4b605c0ff33a7019d8f1e71a17b43a6a72a57889157c15d10d65152a7581b8ccc0c09b1dd284d9da78786853bb8b88f4458bf178e05247713ed13a6bb7080827a1f4cc85de9a8b094f9c6edb71e8e3166d4907b786fc64d97359907661b6e63e6c1e415e9d31aff0e43a47e5830fcbd26e -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 5c27ae4e00a9253b8e43c744e235654a6ff72a1cd37acfe0aeb10fb5b5505b9602d4ce81aec363d9a235660aaa93286bcc9ff768d7b44de03e4f48cc27cf5a22c07942f9d2bf3bed98c273c5d115be5314c48c9c64951939048de3fd8cb661d83d20f2fb9226143d17f2d6be7e4490caf06ed100a1a499b3a772c8900c8ed781 -S = 36b438a2420cd0683b040001f926e499992d21be6d6315302123efc80d63d9182f014fc8e8cbbaa70c5875f2e7e7127e5925eb267948101ecca130bf0846f2c4aec394faedba13ec6cc19e476cb31c2cb025bb188127fe70d240fed47d674f2d5b2c3b4660b08242ebb5c005bd1e836c908121f0e73dd80a18668b79d05783c521d9913768296b057cdad7f408394d080e46b74e72c6d337b54c6ff976af2eacd7ce51f3d2432f3ccf7b55b074cc2817272816525b91264c96325f3145324cea -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d060960864801650304020105000420cb6adea7aa43ed6220f5f0c4dce57facddc4f77cd4e9072b0468da9bf104c1bbefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 8bbcc23dd3ea4ba9c1d1c8e052be5d49e1f358c657050a3b9e83d64a59d88761d273e6f733258d12facaf60da72bd798b723b200d601a7b1512e8ef9ca10420e2f2d3f53ed9470d76079421e8e1ffd2516fb54a063163b8625b3f8cf02327d7d8834f5d967009dffdd25d59c716177f7e4c2672e650b6bc204593d566906dfb4 -S = 3e116c20ca4dba97fd0804d5ac89cf75bf53a71c77af12c2301a1c093aa269a9074f467c57727a5c0b17f18968842f98bb11d8b4afa9a9ba193c0e8f2d2853a19293c310ad2a5e792ceafdf307959a50fc48aba8dd911b367614b26b1a19ef13e37a4e3eedd4229174d7e6184f6bdc4c5d24397545709170a72fe202bfac3695373da28abf90aa1dec9ce1ecf4afa22016c2b6b65e65a5ffe38925ebebe49e4def0133916b4c22d2225122e1d77703a716da7cacdb85d9863d53c039da1a1c44 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 676a410de221dc39a833bd94dffc5b06dc4ae2613b1ce1452ea9434115a4813a4fbf1611506e3280f4edb24513845083560a176549a81b04b1df668b1fcc3599c5ab65e6899b282a58a0fc3abdeede74b265ba5eb658278a1f9251bdb29b364f713716d5b43024fe7b5582bb03c36ca39763b495a9b46e9f21cbec1ef598ed27 -S = 34f5337351298d299f64828163e2c8edca0bbb1e80d8da4141c3aadd5827d815f32ec5ec6696679580f92d1e97ea7cb85485566f061a4eca830c22f01f9d952d33c2aea8cf7d1b49d426cfe029f2c52a2789e9031e015ad74c7105d43b9fa603869e850c6be898830ce1a921430cede5f1312de7bdd4edcde835f32102ec28628ca49b5009fdb5ac03c6ad077c77f66fae2779eace6908c4fb5051d82255e7e50920afd1692f1c08d61d233f47e8a7a1e342d39fbc8ac527d96a622a2812f177 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = ad82f5bc35d0995edf617b3b05f4ebabb0444cdb678980734541a1754f30f26804a615b735007e54167127a09603858fecd8bc0772b60f8ab7c39a15cf8c4348ee4ceec6366cf0dfcc46c66d312e08fbd0b3982dd3221f5c3b4cba803089f05395fde8b3e01ad8482966c168807f5a37845c491332d5992ffa66697d1830e1d2 -S = 8dfd4ce88f22ca5c7faee59e9c0c319ce22581108d1f333a4f53c239a840db6cbd9a18d1be3d211bb2a7dc69d1750aed173a50cce78d4b8ae804525f5e3dee05c98d9e1debef27ac43dbd8faf87607affdd97589995cf062c7f3b5c1ce7dad7c200c3124fdfce5f05e0044ea952e54ab642c47e0bff3f80cf96f0dcd08baabd11152b8741d8e700c27d805ee6edff11f95b441a24d65bccdc6949b91baebfaf249762f61593974813bec018929b51cdaa89df092b38422e2a82aa7cc8a22f971 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 75025b7ff7978e537b49fdbc59a54ce3e8313c96885ecce3e6b8a5e67b60b4df56bc19871c6d40a54d814ddcc8eabec7922f4b48d362111c2152f0b30101323fab596d0c0e1aaa0f1417c6c127a2192ef44556486fb3b28217fd499a7b09bdb6fd4120b3d68814ba5a7230147db4a63f97d923416437f73c4f227643f05f9e6c -S = 1f435cd0b2835f4a895c2a53c4a9cf8561197c90548881f3150b7f2247ce7c1f0fba20dc1b3a265566b2cacd6ac66f087ccbe11776168f382ca2cf79cf97420ea665c5cc547e250a3582febaebf9b4ec97a1cf7c8f1f75e75e67454bb2179d6fe1a66a1ca01091134871f8886eda7e72536eb05b3ab352f8e775f94a0c1c3060d3932200cc10aa07a282a2c540ead4be9c3b664da3adbc4a513e5363b41e8e867d2c348eaf50c37cab0a1ad9f7e32dc48f1ed90d2c4fd88c7588f3250e9b582a -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d0609608648016503040201050004201652a7df9a92d3bca639e5b379b1bad5728d06fe2ef755fa734a1f09be6e782c -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 0b9c18c93a8b1b8fbbd036c2d5a6869c2c326e80e613df300d3ad74034fc28cb5e657b641bd0944ff4b4d8f209c10c86f92c5f120247ab9a6a54f8931d9b429b97ba7c67043dd4fda66e3923786e1a1711857180cab701a52398dbdd636127467f4221ba3dfa62ff99a6613e68d639b73be6adb2868c69b902ad8a044f756135 -S = 49eac9a68c0786ced77b437b01a3a562a5d6e6fbc9728dd513814cbe611f3d1d4aeb4540a61853595964d370406f3a18fc6973387c99821c8e966c47bb6e636543ba7940b1c0f23a8fcf46ee4e3173dd39980088b0fb2479ee4a08b41b2dff7b3ec1d2989bae39f7abd1bffc8d33155518ea6968b6b471c90e6773c76c6fe8cbb1fcc138dbd48e9eda1090ab245dc2b98fd7c553a7bf11321ef7c77fb14f36e5b7c969abd5e8c049d2ee4fc3f08caa6d996ee0580af6cbe27c2fb1e0bf3d79fd -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 5c27ae4e00a9253b8e43c744e235654a6ff72a1cd37acfe0aeb10fb5b5505b9602d4ce81aec363d9a235660aaa93286bcc9ff768d7b44de03e4f48cc27cf5a22c07942f9d2bf3bed98c273c5d115be5314c48c9c64951939048de3fd8cb661d83d20f2fb9226143d17f2d6be7e4490caf06ed100a1a499b3a772c8900c8ed781 -S = 2a7d47940bef4582f4edaaaab4b0181c76c091179465ec3c007edef88775986ac07f85b4fbbd68450ba9dc346f590cee4ec1e828978d82c5e0bbb87df6f8c548ebbe64fb4f101bb8cce618d88dfb96f3d8d5efb0d6f7dd67c8f75eb068005f47db66d87c33b833dabf7dbd02b3b327988164f436a0e313efa3cd124f87730b463962b21b5a4e3a9530db7ea0ad8d3ebaa23414aecd343ceb58e324a1deb1653e792ec5a9eae709d77b2e55b6e8b5f653a8044882d020f5fa8520afa588416d67 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003041300d060960864801650304020205000430e1d3f55e005049c7d99593b81a02de751db47deb6bbd6cebef963164123fce991214c8be6828cd6caa14964f293e1245efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 8bbcc23dd3ea4ba9c1d1c8e052be5d49e1f358c657050a3b9e83d64a59d88761d273e6f733258d12facaf60da72bd798b723b200d601a7b1512e8ef9ca10420e2f2d3f53ed9470d76079421e8e1ffd2516fb54a063163b8625b3f8cf02327d7d8834f5d967009dffdd25d59c716177f7e4c2672e650b6bc204593d566906dfb4 -S = cc5bb97aff280fed4499d2fb96d5acdee24406fd1d80217a0b6a27f7324f4728db0a4a6f996addb55ee8fd2fff1aa109d7293f5a7954a08857e53941d1ba0a86e1c38ec61cf9d54c2ed40c281475fd68dfa1aaf0c246a05959465c89bef974df66fb1f3228e07fe03eb7b9546c6f09dabecc6f2b8f2f6be058186578d87a097aa6a0a15f98061d4d1a1ccb67a9a6ae6b35e264e591a8115b459dd392d3c1f6a6785ed3c97d319d19b562da148e7361ee261c2991ca09ea924d69d5dc59f7beae -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 676a410de221dc39a833bd94dffc5b06dc4ae2613b1ce1452ea9434115a4813a4fbf1611506e3280f4edb24513845083560a176549a81b04b1df668b1fcc3599c5ab65e6899b282a58a0fc3abdeede74b265ba5eb658278a1f9251bdb29b364f713716d5b43024fe7b5582bb03c36ca39763b495a9b46e9f21cbec1ef598ed27 -S = 4f43d98e1a988f7b64d37fb9db79b1759e1b971f90fccd542d636f04c4f8e35c3f07d941c906f8fb788cfdef25b4438a5c9322ca2230e62b17e618dcd7a4669a187506dbd2087cd25da81f351cb87430163208dd06bc3e5b7a36559969ebbde2200f8933c45cb327f5e56e1c36bd15d11ebc7bd0034cc2fec3a9382dacd61a715c1f2f5babbd549faf752d4515e4375df0aae487327b765b45e82a868dc7985e03bbf1e6c80d022562c7e4455db4463f42fca3f2bfbe9f6cabeb3bb61fe0c073 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = ad82f5bc35d0995edf617b3b05f4ebabb0444cdb678980734541a1754f30f26804a615b735007e54167127a09603858fecd8bc0772b60f8ab7c39a15cf8c4348ee4ceec6366cf0dfcc46c66d312e08fbd0b3982dd3221f5c3b4cba803089f05395fde8b3e01ad8482966c168807f5a37845c491332d5992ffa66697d1830e1d2 -S = 5028c5c1d6558214048ab00458a5b0308053d91b312c671a15a47ebc32dc85b9760202b7f1d81549fe4c76d48318655b376e7d2398be7693f530bc28611cd48a7825759641c24fef6af1376d0d7bbbf23b9753dccb810a95e4d988be0c3c694f445f47e46e2aed98223c0583fac02cd9330e5652a697b07338193efe9afe1a514786c31edea49654d90d87d7caf26978accd08aa2272e12dcb058296c032fae8c63c736bcf4837c1d0bd2deb0a9539eea5f376aa5d1593afd8a0bb48d44bd5a3 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 75025b7ff7978e537b49fdbc59a54ce3e8313c96885ecce3e6b8a5e67b60b4df56bc19871c6d40a54d814ddcc8eabec7922f4b48d362111c2152f0b30101323fab596d0c0e1aaa0f1417c6c127a2192ef44556486fb3b28217fd499a7b09bdb6fd4120b3d68814ba5a7230147db4a63f97d923416437f73c4f227643f05f9e6c -S = 068559fc0164a646aa07337ac8d98cba1da106d4fa951f408315284f4b2138037687b87c33b38d0e180ccd62bfe1baf2c42f72b9750d133502092c42a3faec6e42f3059ccb5cf1b3db1ec2c714e12aa0c5ab612a4d0c913ada82c98015ec761e7237087e2da676cc92e3340b2f31b13b157bb128b2a6afbd183dd67d5e1bf8bd041e580ac6a3fb8b4ab280d182ef906fb247c0d174076da4770eb10b13163c2e53f0a5b8a0b2352de761677a424fd5d71a4efb54b49ba6e2a96b9aa740453157 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d060960864801650304020205000430d7d7bfdf4dd5cfd15b04f924d4be54564e72e6a2ec5cd83b24866b42a01970acc7686ba35e3f9fc29f0fd53fc5254104 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 0b9c18c93a8b1b8fbbd036c2d5a6869c2c326e80e613df300d3ad74034fc28cb5e657b641bd0944ff4b4d8f209c10c86f92c5f120247ab9a6a54f8931d9b429b97ba7c67043dd4fda66e3923786e1a1711857180cab701a52398dbdd636127467f4221ba3dfa62ff99a6613e68d639b73be6adb2868c69b902ad8a044f756135 -S = 3583422f69bf11bb8c8c9e18c40cf2fe3d6930b174a4d8efcca214550b525f7d460077d280e714b8297378a9d228226c719f790961999f0532d7068ac8d51dacfae64819e8b7eaf618ddbc33557cd8f9a3a1e65efe8a4d02654bc725b1aa779ba54b1b9445488a084b9614d8e2c9a0d559a217c6427cb62a6cd8a255512bbdb006427db49b1a3698b643a21d65cfea8e624aefd38f0a3700687bd035028bc161f5eb005cb66aed2fe59110108140b15d6b97567b72b1c712d6fd030872d50ae4 -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 5c27ae4e00a9253b8e43c744e235654a6ff72a1cd37acfe0aeb10fb5b5505b9602d4ce81aec363d9a235660aaa93286bcc9ff768d7b44de03e4f48cc27cf5a22c07942f9d2bf3bed98c273c5d115be5314c48c9c64951939048de3fd8cb661d83d20f2fb9226143d17f2d6be7e4490caf06ed100a1a499b3a772c8900c8ed781 -S = ac97f3f6ebcaeb77a23ca3b9226f7167c7315e5687391b700f21e45a00b23d7ad5834ef313eb3163b2390ccc63f9d76274120c1f0380747b33c1c77edb3e06923482e39b5c964f8499c20e28ed3fb064990190cffd033ce3ae384c275298367baafafc5e66bb0cdbad6e2cf9b16a393610f0088c129b75b88da6207bfb8570425e38b9f2a30d24f4753184e36ce0dde7e9026fcee5cb88f70c1bfd3b9a3f0a0c6bb80a04266c2edb3ca9c06a37cbbf77c1b50c01443c9282d023309a1668fccc -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003051300d06096086480165030402030500044068ac2dc5d380018cb50e8316dea0bd72d31a9c354b9185b1d227c6540be123d48d79581880a02e2cbb7166289ab6798fd3215b272fd171bf16f74af65de4a360efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 8bbcc23dd3ea4ba9c1d1c8e052be5d49e1f358c657050a3b9e83d64a59d88761d273e6f733258d12facaf60da72bd798b723b200d601a7b1512e8ef9ca10420e2f2d3f53ed9470d76079421e8e1ffd2516fb54a063163b8625b3f8cf02327d7d8834f5d967009dffdd25d59c716177f7e4c2672e650b6bc204593d566906dfb4 -S = 5b591910bacd2f0bb6b2052f81445397d2056d114924a306a2b24c4fac2b7698d9ad725cec3010d57b11795f7654969a86f528709655d07a336a68fd4cbbe6ffc95fbf1a6e6c17c2d627c6011e4209f406ae7f2c670ecf4081053c2283845e2c855938da5530a146a1ce4bc203d0179a19398177534c7bb37cd9837911e8b1e7988b800e8046864fbf95e8c584a3c4209f3ea5fd535ba58859ff128fed9d0fc5be8e8c2890a71e38f3acf2a1fb537cdc87f53e3376276c8cd501d21069e453c6 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 676a410de221dc39a833bd94dffc5b06dc4ae2613b1ce1452ea9434115a4813a4fbf1611506e3280f4edb24513845083560a176549a81b04b1df668b1fcc3599c5ab65e6899b282a58a0fc3abdeede74b265ba5eb658278a1f9251bdb29b364f713716d5b43024fe7b5582bb03c36ca39763b495a9b46e9f21cbec1ef598ed27 -S = 5f6b11ef4b5b0a1bcd9cdb2086c60db19544dd33aac813ff6ec628d9de0ab882bab6496b79477cd445f71686f666b9e041e2ac40959ad94d3df00b1ef8c7ac3ab68b1d2e07294b3aa54bbcc1039b90dda11bce3aaf66646d19a7224028dbe7b48dbb67dece2812a5bf82e89db0908cb26043b78ca5ba455ab680d3d6aa4bd1682b39b5ff744a65dd5cfa909d1b71218a48d88e4e112a8b959b1886d956610d915ef41b30031eb3f2acf7d42387db245d84ada17b5995711ab2e12b8ffca81905 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = b17ebdbb8027c2ef5e5de76780979c65723d73c0ff0227d95074ded158d1abf96f1d578a3c716197d996433f32d3f727ae02ba2812e91044a2c808df892fc12b7a122de5981f153f934f5d1d14bc8a835cb2814e28089123d7b1b4a6ce8e12ec1c86c7325ad9e6cfd5b1be67f0fb5c62c374519c0807b55e38566b8ef197a722 -S = 1e80b47f34629c79b612fa8d25483056d1475f5f51c50ac60e8f5eade21469dce676d13b32140760d828dece21cd9aa2381b40f42e8e20a77392713f5372d1e87fc131eb7367b98d92a76e5276bfd073d6e44f8e9cf81e175d531e6ad50dbf84bcbb636b378c3342ddf6b2d85c3d27b2afe449c40f2915515c4c417a633b4de6c30e86f49f8f5dc44427642aa0c98e499e321aebda279a7321836a3cb24ee90c08c9e88f7745c19deb0e1de72b4da5734bb137414f1d4b1c78a9c2e58f148105 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0e0c2f8859ed53f57993a08eea025ce6e0c208cd61057301d1628d4802599c01a46d6d0c5ed43f09b87f34c206abf1cb1ebccdf2662224f81defbb29d761adea4006e9f16de6ad09f5b32be59d1c6a51dd03a41ec8c5eff6eb768b481fdb0908591f902492fb603537ca6292888ae060bd38e8a9355a175113522d7993584d142998ef52f6add24f1b5e76031844d322ec03914d8c7a26e7a38e63cf99164313eafca2709f1107a6c57f5d49913d20b3bd8c2dc850db453c3a23b00f18ca724b -Msg = 212bd005a8e8e13b0bf4620ce2d3d6bbf18b3d195b05e90412b78d2e92809720cfd3bf7e6b18e08c2d4f07f1aff7cabb562edca48719de931886776605d0a6ef6503573c9c41351cd165c0dea3e59f5c17fd3739d50a7c66953407ebd44f6ae4cb03c0c9a12b88f3e07cb35c2667fba71d407760ac9f6c846f07674465c58806 -S = 6db765c50f9ac9da75eafad6652ddb99e62234397fb2c96769af84da59cd408c12b7562104d9ce9e7455e06abd53af83da43406c64bf15d37ead519d6b3a12cd5e02803c92eeeff2312cc681d53b22caafe9ed5541db754772fcfff3ae53cf67d07b8eda85202a36db8cc01fad12dc3b455bbe123f9ed7c3873c0ebf25bcd55dac7002c7ad1d00eee91c58c357276cce875ba1719b2356ad821d278e9a62ae1a6e22b145ce2c072a1faaaaa8ad2ca4ca807eba3d420af2f3d915993d1327c940 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d0609608648016503040203050004404be226f7beb9c592f2429b00af0b7dd3de42b17313c58ab7ff24fb441e6e47280fa6f5ebf3bc14dc60f8754db42c984e4bc5077fa7b559d727938c3043453166 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -n = d2b6c8fd44e7eb621fa6685fb62371872b5e8408af51bd1b44c6473823402418a26963b98e6fb191cf74175e64132ae6cd101133fc002a89c10bf7739eb930b9c067b52570842395657f927434aa3acbf3369dcdc3990f77cbf22939ddd5877f09c8aab818b80aa20544b6928fe62c78795a4160aecde6ab454db0dcdf1d6c13522526c5ccf82d429791059306f02cdc18c4e580ec6c2da19b3c6de63933ebeac79010c73df95748d987e96a0f8ad523b5014b33423f55922aec2ec23b9aa22f - -p = f260d143cff1e8e0931765da8cb335c0206bf7fd19aaf8ff41e762992f2bb0a660cd65f08a80fe502c9125166a6927aa1859a874159796fada835b48522f5795ed1f8d23f05016358ff908b0dd638bb7ed12c8b80b46aa858d52c77bb7fc0ed1 - -q = de8e674fac0b7ea32d518a22030fd10d4298a77974db8febe195a4240dc5373e8161baf8ce47dc4fd076f64e307ea6262c35b9819bac4f142b613973eeb6a62a15a2ff09fba9ce4db7186969af925ee3acb7d3be7a1f9c85358216640fc1e0ff - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 34d9afccc659c8f438830b2fbe8b6600dfabc007cb22e826ee7dcbe2c515eb0cf1d90ca08a4d30edb5d3c6f6792a1f19ce3421eef7fc3f7212f7a965ee8abff01ccdcc8b498ff11ecb9a5f667937c99bc0f51a50f3a7639ae3ac1774b0737a62de3d5755ab25f1cfa05e3d4767bd4ecfdc7711f4662b3ae688237ed9b3d703aa -S = 38fae4b9233682065387c11829b0a9747217bd7d49acbb5957b8e7d231235f4f7ec316b5a3e5f4f8f45c8b9a161f9b8d3bed9aec0a7b0d4484474150c8bdf392172592c1d0b8ee2724d08aa73a32afad3dad1a0cac3a9f21811f53c69809239c26e36c7b6f4b3a90dceab045413dc3e89fa1927cc7a622e55044a3417b44ff93b2faa3c864c6fe519fa1a8189121a4881e178979096f17519203f0d2c9313a70b2a5b670b675319ad0971a0728f0db729fb5d50280a33fa201271715b256515f -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 95e2657996a4fa69f824ca49ab5a7e6ebaf498a0dc9eaa7f4981c51fcc0935f619ec6bf862683b0025cc48724839bc1e67aa3c686d321ba66185cdca83ba9f41984fa61b826ef56b136e13f1239dadf6e03d877866ccb887908917ef0d33f117b614fd291e3e91736b15150e650db9bdcdb56317f0f5ebe97c938bd691fc9140 -S = 3ae81b95c93a702dada5637e1c4113e5c37a8a24021bb2371c788a90ce8fab1c063c7e17f7f570a25baa9adfc78035d8ecc87219df1bd30c6b8b593682f354db71902ce23faa18f4af6fb9cf925ef7916c168f7298d56c49b6c68da954b56e2164ca37bb7c06498d6ee96aa502011356fc48733b937f299616ecba6699fb8d3d64e332c0fe3f9c58c18f033f92f237940afe9101702af51d3cc220547028eeca8e2d4f46ccb400f0620339b4da7d415ea288bbd7552eef2e68e4ca7c4ea6d011 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 24b78a630dd8cde2fa183956b3edff7e0ea5bdcdc0f1f51172a3bf5218b7bafd7e9048422385fbba4b9c4a4d50958953392b18f98d96dae66a54e81fd12987284465586d9365cfe0f35ce6e250541367e46f77550973582e4b85d1efc235c8389fbb21ac0480319b19e176df5c2f850338fa43abda8f582f40bfe18a92e26573 -S = af9d6db0d610643147996ceb4e3cd539603b068b02eb31a70dd83d40d45f88ba25edda65873271099965fe67758104c2e40b93a8aa3eaf1277fe0d0db1c08de0b96b82c9b48f9a2cac852124de8ff81a7d9742365c8e7f68e94b5d3fbd3aca0e42528b0693f4c61aad95cd912a53545a785e08464b2f675a4b1a5a3c53a8acfebcb25875f7afd802f6f5d6342b1bef4c848504b40a475e56ce9b967175dd9288761599946838617dcc57ee43e1b99eb47be11773cd326029cebed368f821fd4d -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a05000414a651b5b5a63ddcb4142c5f673fff0619b853c194 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 165c3a41385c453b38d0ce2eef3a1fd2863535b993080c84847b1d5641ea24890d9726a0ad44b37dcd0269d59f44b9e0c537ee5571566a95cb39332693adaf64070aac7307c1a37877353e09e5cc17e26b45c3d9d74c0f140a4b89799e844366cc5dd3a28cfa9e94fd1157b308fac23e4006be2d0d1282670a5c2735ab9567f7 -S = 56965ebb90a59710f86a5868573132bc39e3be28d7b5c1e588bc2c80799a0c89c17dff65d281b7aad6c0c4dedc4c134d022512b3821e057f51e27105858b2ae063f3cd0b4204b326ef8ba52310a3187a2effb3295a848de5d06d73504f71c6a91c2edfa5b6bffc5b140b031957b7bb26055f1cb2a79b89df8b1c31d9a54d96d546fa1f77e3678efcd9aa875627419d1dd38c1fe743785739c8bd0655b996f5bba23604983385ccb75640fb0c6b128c2e117e9a5fbb7b25ab1d9e7a2db644113b -SaltVal = 00 -Result = P - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = e2c50870d442d577b5fcd43778e9ac0e13f62ae7d506325ffa38fc267d697da72dfb22eb03d4c4bab3a9d904817ce78056633f93138ce773257ed88c5aa16923f2010c39fa4f38b2d529a6b61c9ac058a8e55775ec7e94df885a31bb1c68e8285a602c2260bb18a54402a515f04c1fdd3003da5709e621ec4d546f7c6cc7e2ff -S = 11875488140cf57011ffff2c42926d00a8f2cae3367360ab338c96aebdcf9cd95c091840c416039f58c8a5fc0cee32432a673714f67baa42d4ba6150054dc88644d5c133903fcf02ed83e196078041bc96f2ce785e0759f0a7ca80f41c2c2a97196d0e4763330b74355d8de3a102538e1b4174de2ae8ac71ac14f8e0a9d9d9a71a34b953c0977758c43fe96a3cbd9ba00b52a72fe464b485d306979685db3bfcdfbec66425dbd20fd59e0985458dd4afbed8dc4a0756f38c54624d86ea71e9b1 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a05000414cb9ea455374c24f698ff1b23b65a9a0e1980c32fefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 2a5853c37f9428e1879034feb2d07a5c454e9970f4c1ff43b21f5918c8614d4f24866c89f4da620d7478706b040e1d5f7ee028f7c610c0f8a31cf77fcda875e4477e69e3eed3c6fe53ccab1dc6402278b3c00eb632d45f56d988884fd42733f3384733199505ba7bcb92cc5d1eeff3708cf435f55d974325fd6bf3d10767f046 -S = 616e467f569c1af563d7775df9c11116856febba4a4b7f801945b702621bad8cd599fe43ba381e02a67714244c0961c9cc65b6f842c2391a439ffab1d262ab0896e200493526f9047e3bd77e1b88ec854f8075bb54d7ebaa1143b4adf05fcd1f7873e036f464e73b4761505f7e96d6e80553260a95449dabc1e45f6e5079ea6fbfb8281c693005d3214e175ed18a9f5e70d7a59e87381611aff9cc82964bc6e68735bc11277f5c2e00be2d089511b12a32bebcb96ed91f4e158989b3869eab4c -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 34d9afccc659c8f438830b2fbe8b6600dfabc007cb22e826ee7dcbe2c515eb0cf1d90ca08a4d30edb5d3c6f6792a1f19ce3421eef7fc3f7212f7a965ee8abff01ccdcc8b498ff11ecb9a5f667937c99bc0f51a50f3a7639ae3ac1774b0737a62de3d5755ab25f1cfa05e3d4767bd4ecfdc7711f4662b3ae688237ed9b3d703aa -S = 238a420dff7b0b18fcb6684933c38a9401fb2a6f8fdbb42b786cf5acb08948a46e42197fa690a613c8c0ba530d57d4f3fcdb410edaadcf995377a4512d09e5dea6de8e8f553d7694705929b012e7de002c95cd670f47890fb2077ee5a4c819ba2438d0757d8dfd1d0a83e4203672c269ac7a0c1e9769cb86eb3c9f5d7cd81058bcce66f1e3e7f47e1e15f000a02a7c98794f383c9b8650cf512b3040d1b6ccd638f5c8aa891228ea870177add8a9e754fe1a5c97f01f945dacf851eb6eaa0219 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 95e2657996a4fa69f824ca49ab5a7e6ebaf498a0dc9eaa7f4981c51fcc0935f619ec6bf862683b0025cc48724839bc1e67aa3c686d321ba66185cdca83ba9f41984fa61b826ef56b136e13f1239dadf6e03d877866ccb887908917ef0d33f117b614fd291e3e91736b15150e650db9bdcdb56317f0f5ebe97c938bd691fc9140 -S = 5ae8f7c7b9f7002e048f47d7471f83265860a70e7da64a9ec5053f07e9d92f2af5d738c79bbc9924eae62eb723edca05a965f48946573323132b482c04810d521277676145e505b515cb4fbf2f783e3f71124300bcc96963536ce8ca83086a004e4963b8fa52c4101073d252bbc242fd6e0648b61edb394d84b01f1d7bb28f24b65e89f5acc881b6d30612105f143c0bb871193f70d4217a1e283285518cba57ee85a3bc77fc9f481ddcbd5a78144685de81a6828b0a253f17929ce14c4cdf12 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 24b78a630dd8cde2fa183956b3edff7e0ea5bdcdc0f1f51172a3bf5218b7bafd7e9048422385fbba4b9c4a4d50958953392b18f98d96dae66a54e81fd12987284465586d9365cfe0f35ce6e250541367e46f77550973582e4b85d1efc235c8389fbb21ac0480319b19e176df5c2f850338fa43abda8f582f40bfe18a92e26573 -S = 6fafddafe9df19c45011ae4914adda6bbdbb20b43106d6d81faf1121c6300f9f9f2f87991b27a79d7ab8df8466539d4974d5cd379413ff1f2ab1f826ef5a6b128966fba4000593ce924132c26e3cc2734c38536178d34d90bb141576b80fe2ef1c4be81fde648d1aa3a4f537bcf815edab3cd3b44f7db09e7d5f73a17a9af84500c87d33b9d1ec7854852400c389473c8a13f70bc37bac6f75ce407996a3fdb9489fbcfb860a8b4c7280d3795841cc325fa0c9ce025ecb3f0c2d6c18a44c8ed8 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041cdc59d2d30fcd76a4ee2fee88ea165458725b7796e06af5a9bd13f257 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 165c3a41385c453b38d0ce2eef3a1fd2863535b993080c84847b1d5641ea24890d9726a0ad44b37dcd0269d59f44b9e0c537ee5571566a95cb39332693adaf64070aac7307c1a37877353e09e5cc17e26b45c3d9d74c0f140a4b89799e844366cc5dd3a28cfa9e94fd1157b308fac23e4006be2d0d1282670a5c2735ab9567f7 -S = 00f76baa258f67d94294939b305b41eba86c36b5ec68a155281a692b0be33d01d0b4c2aee3bb503a4f26ec4688b459bdd550dfdd029bae58f744c14b2768d184f6cdb9bf1e6da750cf10883f14d49ee5d836ba34b84eee98e7feafab7ed239b4154666eb0ebf0f3be6f44926656a0b9c5f649fbe5638d563fccdeaca8665a6a7868061a7a544b69b92abae588c8461e01e47f2d83f00978a99caaa2b4478a72c83806d24ba5e41447ed7fb6f22b1750223a9b18c8a2a08f00eb58ee20559dec8 -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = e2c50870d442d577b5fcd43778e9ac0e13f62ae7d506325ffa38fc267d697da72dfb22eb03d4c4bab3a9d904817ce78056633f93138ce773257ed88c5aa16923f2010c39fa4f38b2d529a6b61c9ac058a8e55775ec7e94df885a31bb1c68e8285a602c2260bb18a54402a515f04c1fdd3003da5709e621ec4d546f7c6cc7e2ff -S = 6dfff6e5d6e75fa6b9f012a13c4e62a469d915c7382f20c8b961084ab41cfbc04dbb150d5f50c7c1cc75e6e891b0950a95df3171decab5cd48dd02a62b51f50358248b1c47f1cf7949d78bf236bcf1f6803e27e37725b60a37ede16f951587290f4eb5b4af07b7a6c06bd520adfd29e56ae61efc3ca7d436a8af7c2da47bf201ba602896bcebb44adcbb54083a26b91ef32657ee52b7c69a98f985dcb37328fd703c26303c4863ee3efda288bd9565258b93298dbce897003c760168cc17a734 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041caf4c1d01bf7efc97ce8b761e6fb40139563ffeb393b5ebec6f015885efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 2a5853c37f9428e1879034feb2d07a5c454e9970f4c1ff43b21f5918c8614d4f24866c89f4da620d7478706b040e1d5f7ee028f7c610c0f8a31cf77fcda875e4477e69e3eed3c6fe53ccab1dc6402278b3c00eb632d45f56d988884fd42733f3384733199505ba7bcb92cc5d1eeff3708cf435f55d974325fd6bf3d10767f046 -S = bd10583413878f8c71938b58927ef67e7e46a56f56756ccd099e3df80dc44126566525c666f009b0bcd35ab1ed54d55a34b5e7e0c1efc1b8a54199a5d4605fd464111a40ce3c93523f6ab771d8c8b03939daf3593a020284815357958c7b69e8500d360138ab64a94237faf280a33fb257f4191b5ef385a7b9ed40e6fe77b6e85e471c3c7fa922a2044600285e2c71f5b76edfb8ac76c5b9ee0fa1856c632c9c3531763cefd999fd2f497efc4520029c6c08a8b8b2ae0cee0bc81b222dcffff4 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = e1ba864ce9f41cf4ee2ddcbeb7a05afb1f48fb88610b5da39233f3fc6f1df00f593567b29e22b0eafa3d0d035e488de0ef5d318f52244e20274932b8d32d0ae183dc04246e40b0da5a94ac3f611a80c8f511c7b722e290ec139a03fed89c488a6698a4cbdfb7e56b141801994980fa5c384d042758aceaad5e0caef604d370b3 -S = 5596571f16dbd20f8c64ee7c1fe8750910bf640837c9de5c8cf02bf1b36a4ed8e41e95e10be3038334c7ed93b80ef660b1061d3595c647a603d203d2bd9a357236679944325572748f54fb84f382a7d369899a82fdc5da17cb5a24e2811ca881fc748a6ffc4a6610a6f3ca5db07241f7bdae1d6ecfd7eea37b276d8667a536cd45c8841c5197471ea8959c253eff1588cd99355beab1bfbbcdad5c19aa507be24e826479058197313a94902d36df02770cc67a1c3f7adc1d467640ade84237c0 -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 3730776bea4bbd16ab03e8dfb6ec4b962cf4312ec6432cc1c466aad327adc9db20d16d00c8da8f201140d816fd516e3d0ed20e30fde95bd4af3b75996451cefc32403951b28944bff93ec88cc966be9a09a35432731241018d735560da8a54d951c404e60e1e85fb4843e1c783f4e4b806ad2ebd9086864f475771b2f11f0378 -S = a9a3fac88d8fa6478302de5589304fcd201792e51e7f5e2f10305311fe804dc70728623b20dcccbc996bbc7dfc2ef283521480910df1bbdf72a51151353a791319181e586868f37f17499dc31684ea8632595ecccb553f9bbd499ad291dbbac1813de8fa06a53021bb674b198c79f5c8f2f28c84c09863951501a52bc7d8076e02adb656cafb940587beb815397a9bedd3129c2beb5cef8e3771e985b4a81be0cf6d50b53af7723a0ac0973fc053004831cc3954b2356e4aaff9aafd13ead212 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = a9ba6a22549b61aca519cfec89c316889f0404eb354b5f8d7268c174d43aa6fbde87c4d20a2b9b4605754cc21bceae96f09b9ff8726598480b3785991b48d36ca5dacabe49621d4672e9bff8d0b2f9cd091dbac6abcb2e2f660391217855464a687d23f0f78a1034543fd0948fb91eb45052fc5ec9c648c7e9949014d2a7271c -S = c71119e288acfcaeca10f632f20ca3d9aab35d62f4d8ea66acb955d83c0bf0b9eeac6bb3f776efcb4bae51e47c3cd29ec5d9c8f25bb6f52956ba4ceca9e189a5dd24f1a5f314cc65c2d77b9c1450931765bca3ba701434cc9ce3c4dca806f1f1b7e11da83ce253a1c68bd306770f3d3e8be5ad242b480fab2ba73c20d3922ecfd5d3e4c66ab7a220ce1e175d19740caafc76005056a67326be67f413233810c8fabeefd00b3a3ec19178f48178c8df23a0d08e38179447e3c1f7ead1ac186298 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d060960864801650304020105000420669cf26386b9f299c4b53a9cc5bc93fde922383716b1bad573ef605208ad4741 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = c68bfecaa74019105206ace85d710f160907bdffbce96268b2b63680efac8a217810a053c2d0c0126b6888512802843effe1ffc8b6ff185e8bf518fa251c025fcbf26c9fd4bf8edf5e78995e43e34ab449fcbe58999888657348019e1f80dfaf27f809b6c353aa0195ff8419965c88005120a3b84ffada04d2759973c6204899 -S = b7873d5e394de2c8d17f988135da4563f12d449858e5b26e630596c325046e30f0a66ff38b97e8bd3c7b8cfeed4021ed08b025d7c8919c9c7eb29c980290faa100d4b56c1837bea27dfb862cfb216a0965a1c6a923a65e654569164ac93a3b39bc7f533a4b64e4e8a3b88d0fad6eda12e11b181c9abca3b776fc409a8f069ad40478c3f2f02b0634d5d095316813415ceaaf8ff069d85649b8f4b6ce82ba55a2a3b0e53274f10a8cc0c7863032a38ac5bbefdc735523a683bf92196be7120845 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 17c6696009d0ea40825e93872261234db051c06cb17230e339574b7802a4b0a2bb18b8a5a2caa8ff55b22b03e56cffc42d39ee346247008deb32eff072cadb4c3b173f82b49a24c74ed694498c0f52155952c8389fb5412415e0585659ccb0363ecbe63f67c9c45f15d1b8a13dd38409dea436bf91465b71626a70f2de339927 -S = 181e3c1d3f6f6ceb7465b6d232f0fbe3270bdd3e6fe05a8dbc3ca9611280b141c11b903c8c34e7a09b1124874d2ac93af9b3d8ff495d7eaf763edf281235066ac6c7c1dcc257049c732ab2288b918f1b7c43bc36f40f5fd070d362322109b51b85574b30987bbd2d460a53ddd694a972fea606ba2b3a4192dcb30490370454e147013d6c7ec15ddc72d81dd7d0601c49a00e61b57ce3cce8ce89b8048359a450a42ed1d7a424e725d75ed0ba5818b377ef809b3c32564562315f21c8d031ec0b -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d0609608648016503040201050004201b3650ae9361fac5158b27993f4f51b62133f7172673d0cdedc1820e3d127314efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 063c070dbba386b97c50ea8c475cb9817fb00be490184906d19a3535ae052aeb06cca546d21505b8080e8f00bf80b55993a698f14b3fcb9cb9e25acae2920bb75f92e3e1037aecbfbe8b36b0c1401c32e325c85444ecfa6e30be040f46cf1a37d935c8c696fac4356770e68498c4757339d6a4f5c3485ce2fed63cec21e5dfd4 -S = 97c48f987ae22938db183cd761956e3dde0cad8a865b70f2392b77f876c63520a12d3bd80850fa6cc20e9bf94d058f2d0a7ebc83186d0defb0ae256237a9fae92b2653284086d49b04ed9ffc3e10f6bb3f9de76396cb4fad3fcbda87bbb1df8c26e2d70f3d5dd0ae4c159ef3aca0fea506887666cd923435b0d40ae434a816b71d72b91a92b107721761adbc7b678d89ae5c8ecb0ab9078f8805dfa033e00a25b30c3c1c4ca8bb3bbdc36b7846267c2a8e5c6ccd97a454fe813c93f50eecabf8 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = e1ba864ce9f41cf4ee2ddcbeb7a05afb1f48fb88610b5da39233f3fc6f1df00f593567b29e22b0eafa3d0d035e488de0ef5d318f52244e20274932b8d32d0ae183dc04246e40b0da5a94ac3f611a80c8f511c7b722e290ec139a03fed89c488a6698a4cbdfb7e56b141801994980fa5c384d042758aceaad5e0caef604d370b3 -S = 1f01900a2786e048f388a061f173adf5247b68076effd95b5c174661b6fc3589981bbc03cbe75534af40ffe0e60c741745cd143f23c2d073e70856ea88442e56f6ebc26e8609b72a955f9377eae375913c032819afcf60cae66d893525ce0bb83e0184ff7dd85893443e10d7be59466c6b7276452501e105bd3e0a8f7553c58ed8700d8e43aad9efd827fafc1948288c12e380b82a9ba22340919a52a9453f2b14e6b7795215720cb6c2a89fa8bbeb46a416267f3126456cb6fdc9fad183059b -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 3730776bea4bbd16ab03e8dfb6ec4b962cf4312ec6432cc1c466aad327adc9db20d16d00c8da8f201140d816fd516e3d0ed20e30fde95bd4af3b75996451cefc32403951b28944bff93ec88cc966be9a09a35432731241018d735560da8a54d951c404e60e1e85fb4843e1c783f4e4b806ad2ebd9086864f475771b2f11f0378 -S = c5670f7a66b167b3369df23e847a68022be3f2acf2c54b1f9c8b4559466587e80f73b6b668921af9902b72a2cbcec0f92771cfdef7bcb12d3db6032b434b8aa2e2bb2a29f16756916887a79e78552254b702cf2a14c9b9c6c7dcb84745fe27c90f0eb7760aa4f98ed241bbe65a8597aa6d26fad59874b38fb48c2a69e4a77d7414b66552dc7a9b15646acbaac71aeb4c4fe69be40137e79a05ba512d40f86af2d7ad5a1893fb589ec9aa25854083f8535da0acccd0c497dd8ae3a16d3a8b3973 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = a9ba6a22549b61aca519cfec89c316889f0404eb354b5f8d7268c174d43aa6fbde87c4d20a2b9b4605754cc21bceae96f09b9ff8726598480b3785991b48d36ca5dacabe49621d4672e9bff8d0b2f9cd091dbac6abcb2e2f660391217855464a687d23f0f78a1034543fd0948fb91eb45052fc5ec9c648c7e9949014d2a7271c -S = 29bef7b04835e0020a2cba2b9f6db73583493c3702678cc624ee60dca13ef99f58bd2466b3cc3515e3ac52cc01e53aa0b1ca13871ae90317ed90d5dc810a49b0f569cdf78cd4ac2b554f272f3aa541875478901c26d82835bf482451812460da6392f801293ce370b1dc1ca420cde9af65f191dbbb57e0868971451be9030f414c24cada0d759767b93526e39cee99933f4eccee7eabf0353fef6061ee271558144cbc8c4aaf2d2b6e9bc9dcf2fe3f1902f1ef1cbd4617b04281ffae8925fa09 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d060960864801650304020205000430ec65d014978f49b770a449d588ef99f8c92263e18690c237b1c0edaa8da55716adc29d56621402e375c606e7399c9a83 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = c68bfecaa74019105206ace85d710f160907bdffbce96268b2b63680efac8a217810a053c2d0c0126b6888512802843effe1ffc8b6ff185e8bf518fa251c025fcbf26c9fd4bf8edf5e78995e43e34ab449fcbe58999888657348019e1f80dfaf27f809b6c353aa0195ff8419965c88005120a3b84ffada04d2759973c6204899 -S = 80fe5722ecf6c505989f017b63fa71b2723acd378ef8c4b4de5aa611d99196584eed2b46160f4739906533fe54034db7264a19366f7719ef576d3765907f49792fdccde4b94db4b42c95a9c54b2fa67f513039329f3b3fccba4d44f69ed2c9cf3b0469556ef88d90391af612a273ada316756c36d447b4c1b36edf516e8fd0569cdc4fe2254d3165a9250a9163c9b0c629bc64fc7cf9bf96c3b51d78e378678f2309658bbb363ff462f51d145b82fcef1a0282278453b48cd8715d32dd8a2214 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 17c6696009d0ea40825e93872261234db051c06cb17230e339574b7802a4b0a2bb18b8a5a2caa8ff55b22b03e56cffc42d39ee346247008deb32eff072cadb4c3b173f82b49a24c74ed694498c0f52155952c8389fb5412415e0585659ccb0363ecbe63f67c9c45f15d1b8a13dd38409dea436bf91465b71626a70f2de339927 -S = 82af137868d165dd09c47c95c960e636513305030879d7c4e1f0b58c65fcbc10842f7794e0b80b019b4b384b3473fb452b9e04380f84232e986dddb79957845c0f69f880a51a73cd4bdd041d98576be7220992982ffbe30fe53adfd524dc5da9d8d21a2140056faef2e059a1b282914db1b83494026696601026ac038bed35ac5bc7fa317cf2302f4f211dd8bfcfa3866d8fadb498709bba9aa823c617f8c339d17d0094f31b945c1c8138c944e6ac6a601a705e47b25e9e290faa0550549989 -SaltVal = 00 -EM with hash moved = 0001ff003041300d0609608648016503040202050004305b2dc15a4a45f199a414077ae9da96fc71a00f9ecdb0c40e214da9b370763b672571e471a8d0328d5ac83d2ea45ad2a7efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 063c070dbba386b97c50ea8c475cb9817fb00be490184906d19a3535ae052aeb06cca546d21505b8080e8f00bf80b55993a698f14b3fcb9cb9e25acae2920bb75f92e3e1037aecbfbe8b36b0c1401c32e325c85444ecfa6e30be040f46cf1a37d935c8c696fac4356770e68498c4757339d6a4f5c3485ce2fed63cec21e5dfd4 -S = d216d9776d8ce35cbfa62808888f67d9a154c87184be9000322148237b8bb64bb75aa5a1773ca9d5b375ae4f643846d07dbc3cfc8246d8ff2f774ff42b184df3495cbadb81a8fad00c00f61fb59602c087d570db0ee1312a2747be0fcd9d563aa1cf14522ace1e202c76ce7849b818b04e4bf489fd723c977f1a2594d65d8595917ad0b575cea228d95d6e3a9ba6f6ca604b8650d5d4e7c182a487a20af05c15139bd46b2f2e48e5db0f184bfad5119a9c256ab601820b7671b6cc48394de6f6 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = e1ba864ce9f41cf4ee2ddcbeb7a05afb1f48fb88610b5da39233f3fc6f1df00f593567b29e22b0eafa3d0d035e488de0ef5d318f52244e20274932b8d32d0ae183dc04246e40b0da5a94ac3f611a80c8f511c7b722e290ec139a03fed89c488a6698a4cbdfb7e56b141801994980fa5c384d042758aceaad5e0caef604d370b3 -S = b4be3c1b7b85f8eff79c890661621f6f3e997ec0b957d540e12b51461fd711b1f7ef026e7f4ecd1298b2f179fd90a55cdaa8c67eeb592dc077d8157b8a04611c904808a6e8a88e83d0965b6f8673253ffaedb437e01e771fa652cbccc976bac41d5be23c5a11bc4027f38d7442e999dc4ecd4af036c201332f7bb1177ca523becf8bc98575d2c4cc4f69bfd9383e540a8eb70dae384f3f07e190f72b856139d5232c3b9037b7e05dbe596af51751da4fa33a03c1d3e847e5339f2fdbf4601272 -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 3730776bea4bbd16ab03e8dfb6ec4b962cf4312ec6432cc1c466aad327adc9db20d16d00c8da8f201140d816fd516e3d0ed20e30fde95bd4af3b75996451cefc32403951b28944bff93ec88cc966be9a09a35432731241018d735560da8a54d951c404e60e1e85fb4843e1c783f4e4b806ad2ebd9086864f475771b2f11f0378 -S = 204d6b33a90f2ce261f413b54563f97b04021d081789d8b20bae89ce2ea0de539a264a7aa47e4e4cfb9864fa271f097fe1ef632363e3ad3996e7d7d4412138419d5e17c245ded83329bf6805880397b5d9c724e4185b86fe55c88b4e8f01056747ce712b10eeed8081b928c805c4b89b6955219d9441289fd800588012b4a19a415f96096144d88c9a9de4ecaa817e36e6aa1123bcceeeaa6c779fb7fb67a61773fd1c8e9dda482be5882b4f81217bf9019753919c0c98f3d56bd60ab4e8ad9d -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = a9ba6a22549b61aca519cfec89c316889f0404eb354b5f8d7268c174d43aa6fbde87c4d20a2b9b4605754cc21bceae96f09b9ff8726598480b3785991b48d36ca5dacabe49621d4672e9bff8d0b2f9cd091dbac6abcb2e2f660391217855464a687d23f0f78a1034543fd0948fb91eb45052fc5ec9c648c7e9949014d2a7271c -S = 380e96b29f08c307d6894255bf104751d5c12892caec1f449311dea1eba85d63829c4f6f8e4c48bae11e6ce246635ffabe1f921de533867a738de08974c2685e7cb981c94ba95d50f2c663a90c281cf676655d542c5fb91818fa83b273cb7f55d88555068e9827de54abeeb597a7f66b20bcf542d9423826363716ad63fe29ef6a093f723d3a0f8926b678402fed69645b0fdebd943546fb0e0316e925eda23c755a321e23df6910e7b6c908b35dcd0b2e0e4c9dbaf51d050ad6d9d16f67891c -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d06096086480165030402030500044068a22ec35ac1e035665d558ea68f2d2867cae3935aede53c6940477d181f9630c3c8d24a06be07e006049c545aaa830a3ab849ff91d935df4edcf4e46868abc4 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = c68bfecaa74019105206ace85d710f160907bdffbce96268b2b63680efac8a217810a053c2d0c0126b6888512802843effe1ffc8b6ff185e8bf518fa251c025fcbf26c9fd4bf8edf5e78995e43e34ab449fcbe58999888657348019e1f80dfaf27f809b6c353aa0195ff8419965c88005120a3b84ffada04d2759973c6204899 -S = 7264f99a15645f551eb08662418097e48da66f7c3d5a953d7296330bfa24d02f87f554e19c20f98a848daa9de39a22b848f514826acfaebdd93db456394713547ca172439f18473f36243eb0ce85cb7357d04f011e34c139d72fc540afe0e7a5927c8466bf28a76e572c851493f23569ccb73132a650ba5af14ff2cdb20a3dca7fcc465e6ac6998fdb2df6f3d88044b4354cec5f7f6ce7f02d3dad61e764058f9a69a6c4e63d4e0ac89567fe23cd1eaa5726d567d7a647fc2ff4ab299a05a896 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 17c6696009d0ea40825e93872261234db051c06cb17230e339574b7802a4b0a2bb18b8a5a2caa8ff55b22b03e56cffc42d39ee346247008deb32eff072cadb4c3b173f82b49a24c74ed694498c0f52155952c8389fb5412415e0585659ccb0363ecbe63f67c9c45f15d1b8a13dd38409dea436bf91465b71626a70f2de339927 -S = 5d90ac2736979a5a789b927b6b142bf08cdf50a5018e9e75cb03363f255d4bf10e0873e39c7cfe7f0faaa2594b856ebaea0b3a83c6c1fbbd1201e533b2ce14e726ba43aff51445e976f9158d6b369fd121e17e34e529a9f7935f3583943fb82eb0e551e7a183254cd1d442ec87d3b853613ced92c28ad87c7884b8e57729fa36b25767be0b77108d2f1da7122c3c44f71ef1fae6399400190863764d2d28076953e579bd5380058cbc06671b76d6cc2bed1bfb1eb0a22e72308c5c294bc4d339 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffff003051300d0609608648016503040203050004409e1ae481b6e7360c34c33703717c48bf5c84b980c112931713bb8563dbbc3542dbc309570342b078e7955ded523fc9b8e992724b26452984214d8f3d04a7f0efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 0b86f0524108c0868477219f6462fffcec9e0c3f0bc83ef154f23be0c51ce72969d5e94fe758df4988bdc97b15a26ecd30b1d985794db76c6a9457cf23d021b84145eb1e94026027f6184a83268334b36c5b1a87b054cc6ea0152c81c8b2221d5994cee154433655352cbbea66651f6e0297fa432f66780fad7d1797d5d2f59cffed6125810a6db340502922acfd7d0c0103846e5041c43efc3551adfe7f08180611bcf21175160441b81bc2cc8d8e922f8e21db688e25a820453ca986bc4941 -Msg = 03403f0e704c5e28fc547e60cdba09c7bdb7e4fff89fa2a0c667f8d9a564715b9b556372caa4227545e9736122b044c1d17c9ad1ac0ccae2cedcec0029ef8dd3d3cca4c3a1c7c75ff7819f00deb29aa95726df32f00687a694590ae9a7caf79e53ace9471c3bb6aebb25e98529497349fabe9d6cec1741b2c0e53adc487e1984 -S = 5959dba95cc8fe826428883acbc57294a10e8e8ffda441b07f8fb2ad17f52589774c27c2f1cb54e96614bf7b7a89c4227168ccbea47a941540d2d71157844ae0210c6fb7abdb58db349ce1515b63303f85a6bdb38bd6ea0f9a340fe70d3aba17f4b5f2a36dcb37f354eb86533e4424c7ccd8377775a28f9beb6921c8b4d9e89811ff748bc1b026e9214c9c16227a36f803cabbd738025bd9f7cfa1c33ed4c00b5d8035389c8d6a02051576d33c8e83f2f72fdc1b35a0dde73fea1e2a93dae015 -SaltVal = 00 -Result = F (3 - Signature changed ) - -[mod = 2048] - -n = a911245a2cfb33d8ee375df9439f74e669c03a8d9acad25bd27acf3cd8bea7eb9dbe470155c7c72782c94861f7b573cd325639fb070e9ba6e621991aefa45106182e4d264be7068035595d7549052989b3e7fd04cabc94012c1278a0ef8672b1a51dd1a9e276816ba497dea24b4febe3dd8e977707bcd230ca6fb6f8a8bff9e6ba24fbadcd93f00126b19b396a38e6ef86d18fef945b9154c1963fb488c7025953511f86d05638bfe056493730bc6778446e59cd3c5c3acf07a0a3a64943793652f10e3292aa7a6d25a03181cc6f6ba0658d909e59ce2a02bacc9766fd8c4fbd4ed9c23a866844b8a794d49e505f9f944870a71aadbe5338039825c2dff81af3 - -p = bf96de108963b5113399b664765efe046e2dafdb70d6e5e29dc6ec89b789b059348d74d89129c7ade9ddb404c6dc3a3437c7fc9f23bc38dadc8ffd0ff757999f5c2d510b993056147ccdf421e03d0be2c74ec333a9677c430cc604f5550d0d86defdde71488e3db889c699a5cacb44dcdae2f3cca38695e783e6f6250827efb1 -q = e1e7e33618d1b64d6862c132e4b1cd5fabad20ce62bd97bce2a3f5ad2da67bb0a7f0b9e48335a33b7b95e77ec4c47e91416881f9f7c23f9bc1918cc644335c74260e90cd7b2e0fed802f19e78c5ed80a431b38630d82f982c74a0381b8ecf943c60810fae90574e216357b2535002316d9529cb56420f3cc82dea37cb624e1e3 - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 04d5d202ade6be1df96d263021141bd6e4e68a14c5b413df73b817df8979137377ee2df5c0e60d3f67a8ee6ea3d6f5e6da97c196cdf4437d1183d06cbe43740e6bc88a2759988919eed421ac651b870ec5ab0d190fc9f5d5bc64873e66f56147c6a90f1edec2dbb2773ae673ceaa78588b6b9527f2fbd1f15da265dbea558125 -S = 6b2703ff1a8d96808bf97eb6d297a8b8d11f479e22b8471e03d2713d124f7c8bf46225e8de2b9db432c39209c242420bc9a17196a38c1b2daa096a73e33912b353a6adf9d198d15eadb6f287c5d2379fe8c07d9e5735bc4c474c2ff9bc7ee6d3684335f7f825664d6272426b2fa20bae585f7bb306b352d916679c68c77ce0d2032cee4909fd02f4f4711ff4e771251c3a9e284f37fb1bd417d8842d030500d84bf7a774b5bbf089e2829c7e7dc27f4d88408e5b549522339e6eb98d51718a219c0fdc20e26bb32d85ef877a5fae812ece7bb04a1ac5a0dd71ae4e8d4c25aaccf8c1f5b9c0de7e0491cd754a675ab6eb8c630b8afc49e0597ea6cacc6c37fe9f -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a050004143d68a61abc2403258d48c94be567caa29e315c8befefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 3efa6c9938d6bc37f0373d0baba3697acc3bed498f9dfea7fa0af06e11c405a64aba834b4067094fabf822e390ad1bf3b58112ef580d50d120aad95c54d640a14bd9c0c824a8890db7095809caf84a338949f2a63090a9250b3e255ca00c4e682b9d4c9a4a5ee578fab20605c24c9f432edbb4f57fedb2a9a10dfff65d2fd403 -S = 343014b8db6ba664af3dc07530e444976bac0a7fd3505218500b0342c0c861d508f55383c18ee70cf47516acabd50dbc2ec18a8cc2054ab87496b9cf22e4f576d5f208d0cd3be114f65f69e0ae744e46edbe0a378942e24eb51fbe25a0caeb654b20ce9a8feda1bd02981a24ed35fd139d107611cbdecc7b1a960ec57a19eef79bac1ed277b746772b405c7c29cf8e32c1c7a49557928ec792944bbc87183fe828a3469214fd35c8ca16df57a985d610ef80db9728f3d31529a7c39da03d39a6735117dc99225921d26fcee7779d7ae191934452207bddaa60c0aadef72c1ea09d5a1d7cac615a8a5b08c5e429d801f868683a72263d80db270a413a8fd9c4d8 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 0017191f1c6b5bdf895837a17e05ca6119ea3606aedb978c5f423962ecac0811cc87471f7c2985331715cd79277a1e48bafd1a03b9b8023d7683e2208472090fcb9fbc8adb292c52817ca5ce98d307ae22fc7ace985b5e5d7e32813e392095ae25e7e128e3723685f01625687c186fd9796fbd30f2cc91359ed87d85b5bc9338 -S = 1d2db922b68b7e89cdef4a238e033500962d61cd39bcad53494663921ae6b0f7710728d9dfb8d52d7725d4f11ca058b1195b1c3c4614c32dce6a2b1b9ad1db261bfde9cc8258787fa7ac9884ffb5e69775ee76ae8af3a15254898e8497b77d7cdb161415a1615eec8ae7ba4ffb352ba459a1d84e43a04b616a13cac644b38c528047841e249ff2795ef2fd066615828545d04c82e92a027bc110c5de6a52355e02bd7888c97dfd48a925528e48890323c6a4f44e5d04ea05cf3009e838a6bf438fad103ea8ffe8d0f7d770c0034de693c7bbad16e8c6a923cc8976bda5bc08b15897075162068b39b362699149e0cd4eda9ff1bade4fb540dc27c17e4119708a -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 1577757d0f460af152dc68b6ab25deadfebba5f68351bb6e2e51ee766fc437f71c734aa3ac4b6b7da506839b5708732acb87a8b4f7eff09e33858cf5f14a866aa822459a11355e939696ad940823a51590ace407e8570a5dca42cccba96b44cea0cd8beca8cc8a3d0dd30d2a233c19753570807abe4fb2b4dbd2d68201ee1a2b -S = 5322e332949c0f15fe63f09927e2ef90a0f1eb2262fc8a7dc602facf8b5cf74dd0eaa2638a6d4393c0167be176e8e68d3b1a6dd4c7f043dc81e702b3b2620df5a4032e6319ff88e19c9cf57fc03f3ec5ca75db70b6b22a38f40a3dc214b477da2e1400eba49c35323c8d83e5159eb4ca6701b4fdb99f18505f266ccdcedbeae59b36fec2616b04da979376403a435d3aae0113d4605b9ffda0afe72923ed2644069a408c148b4e781387fe49f3103841eff840f0b39b298ab4893ba2c292af33b57f6f6f69cf5464be470f678ec07f0ae97c9ff292d896a7daec48cf9e48ecd006acbc2c8567368be62f2178d469ae958ac0b5bd66917944c4b53d1f42ea2f20 -SaltVal = 00 -Result = P - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = b72914feec0e16233c24031390fe31942537dfc03d58810915fb597b163147414f22e26b23f3c7ee3fed32ecd0dbcb36f2b3c2106b791d3499615119a93410740af4630021c3f87a3f01bdf0d0b5ae3cd52eeacc94ea0da48db6baa5b117770fcfe9be454f4650d022a9cda7f95382adb5ee827c1f71f861da43bba796a32319 -S = 2c2a5042129ef97c6235195df1da7b3d80e08176900daa562ea660258269e1a55c73bf226fb54d21f28b8cc02aab8f453405f2c0ee6682ec8ff2d1d8540aec1ed953f53847bc43f0c89608164532da10188400e9e7850114ece817aa854024e696fed5ff74a3747de548fe431d4a95c789bb377a8add64a8583dc7fb203fd66ec9e476232c25b9d454aa9ea7332672cde4ef7540b12ee28524b6c399be32805ac0f7f0db08eb07b93cd24a23baabccdbf5c8437fe2c3330586757a897242c8f2673ab8295ee88e5ec2222fd6519fc49cb1eea3d21d63f07d32bf0874dfdd5e74f511b2e06750ceafaef4238824f92c5da128042dbf64557cd6e4d7ee35d479b3 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 25d08c937abe386aa08b54cb9d7537829c478e53e67df73b0da9cbf76a153acbcaaa9e7c6510099e10172016b3562dd7fc126fef5561b5c7148e2ba6f2c07378bfd7f7ce54977e25c808fe6be71cb1bfdf936b793d1c2b6a18bdf0658c74cefd6b1f40912e99c086322695d42111edc4ad932bf885f782ab81fcc33a207b73e3 -S = 93a032b6e997c0f9ed6261cc4617d98afb80cbd6450a3d9ea2f63999dd68194c9451538975d7626d77a34734d99b5992f98ed18c7f9dc0026fe34cf6583a6a36eb6baadb8316e3aa48d9da4244544da430cb8a19953d84ad4575733d887ed3bbcb4f25389cd36b1c565bf661b1c918a14e5e00e0f0857900ed4c98beab9fe6d1f66a0df588b61afae9fa31e94464d85bc743193303259e9806231cf5cdd4d4c9da5691c08156aa72f4da7607d598d450a5c852a8b3f577194afece74e59fd4ba8c5bfa583c2fa9a6f6aca7c51f772d02fe8e0bcaf5e4c2c7cdd6a38f7264d717aa2b30daa6968a4e7e7e2dcc1de9e34604f0b80c8b793f882d35497d81ade352 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a0500041461ba8219a8f4252ba5e715540544ffde89da3072 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 04b9dc9e05391605d1101e84d4cbe1a08bc3e12a97e7e21e10bbe6cb1ba15c34bf5895b7f4c277ecfdea75d0f845bf23b438b50ec2dba209cffda7fc3168f5a4bf653f39e683704ef99599f8c9fa2d3276217080844b2dd33193a7ad062cd385adebc46d020567f26c1970446e7194977985f9c805c0eb44e087d026c5785e9f -S = 39b142d1b8340384b8eea14f948125101c3c54bb339fc06a5dfb652ff28df204b05561e7ff8e1e6630d7ee9dc7a6147f6f24ddd703bc753cd3226e35812a821e68b7a77cae8429202a74dd1361e8e568f99ee2799a92500a21c73f98024d091c5e29e9531bfde05a7959a3d8f390eb17a6292d11d361a0caa7a5cd2900df5fd2f09679c9a1e58e525721fd068061e5bf5c95d1f491da063532ef620d537a45dc74cbf249c97493bc8985cd0fafdba295fcb65b5ce134cb30d504c93a999909e0cee5aba1d6a6e1f3a3d25403d09bff303d6b89f6a81d8c570c735ffac0d0d415c7b6cb7a10f68d94cca2f1de7975a5073411529b48b2a148a9353c536369df48 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041c330514ff465a496206061832aa09d4d549aec683133b10ea884bf3f9 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = ad12e61576bc1b15d5bff13ab66a496bb5f643dc8461bc858d7a15d3d938369d314fd3598305ee9087429e8fa1e70e600a61c8f82b7e34b2497f5bfc676ef15068b2936775e04da99ed45fe7c401414cb605e4919a803b718f27fa5d90149e709b60ada513f43f48649cbdaae55ee91902091e0f9a10d9aaa699795c1cd243e4 -S = 3009202b1060f77de9e25bc5bf80062a16fd8c8a7e27c4f8fa2d069c6b706bb981f0e2561d8dafd42c647c844ff30b0a226704bb85a3a58dbd5baaa8e19ebfb7635d4f502677b6575b31ca37ba4a51e747fd97ed2a1fc330f2ddfd10669aa9ea4f13c990b4cfa7e15e983459df317ff83506803db89d9f15f3b93ca0acb22d800d9a2c36770718b62a78998fd13471107afb36b700aedde93fb9019ae9aaa9ae4f33d7a18cbbd8474ffcd38a6b4dd95de015786e50811bf3de5dc7de6c3eeb721e8197a8cc537e1d076a887634cb7af055305218680b605055d7e999b90a348745d277bc36dfb38c431c9edb329d3c5c750afcca77ccf159276ff70b6e8f949a -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 3ede763590291420c8da355f5e5930447317445e61d0cee6970dbf59a4ec4e679123ea0c744373fd423aa945e51ce5308e2307684df4af5edf23b0ebc7fac138a07676dbb1936f42c2c9d0552ed7f0573abf560da512e123806d46cb4044c0a712de02e96ea171b9ef9090d76212bb811df5199792b2ccfd23f36a413852b17d -S = a3dfa3b5ce640d92f95260d559bb5c40710a2d3cb38b816fd3b790c78ede96bdc213e7e6e76f35d5e24cf1a6dc54d856be83e352f55b3caf98b6dffcc952023978a5a6900cc9b0201b99c90795c38ecf0a3dd5cfd9579378c57c0083b2584a3bf859c69a553ce7cf8c1ecb98376b4ce90e1a0271c4043654f175e90477440f7108b960d1e3e2d00743e0a2db96d179999709722b046070c4ecb6f3f3650365119004b016e62272fe9e7c06999c8b1f8e0ac56f46c668103cd23f1457f37e376b8aa5c4235db08ceb577945f3276b931f5933bda713f0c8643aac2b0ad92f7c8021da0072444ebffe55d0cf183f002ffe1e8c221508e7f65b73c05f9362214440 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041c6622f8e46c8c838679d4e8af043ccdd2f9bf3a6820a5dc64a446fe67efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 250f95cfabab5de46ab2bda3cdeb3228cf7330aa1b5764ad75623c795634a9cad69424c9cf08ef3b40a29df9ef1cd4a053285289b0012efc844660a0220884369d22db87e7c8939b3a63482cb79cca5a4eb721a1dd23ce079c4f549ab8bff7193e5ec4f23b16d16c229ec6266d939cc087cba5d8eae6cd3884251f4d60808bdc -S = 580511902d07b267c4daa41b6660db0d20795afe0320a961a36b384fe3537f7a88e31e09c5e3f660d2ec4e176c2ebf7e45be1b579831c0c75509380684e5936b79097d6c3b7262583e4c2f81ba09e78e542e823e855ee97260e8fc9d53fac6d452d601d07526583d078e293c0f183d716a0f7b37de31b000ca7bb095303d4eca67393886e43ac271c119244d4c45d98212924402b37660c0f7dfcd34e4672011d1aa721337b1025bdfbce502f017a573a18850cbbe108bc9fa978078906a4c1d4023f8158cb5224b46f43f70c8029793981011d77c816749f6ca9a71c2749e0e151fc69c7f4b39fad8e96cf4dc6ae451bfb506d9faef8b377b7c5b47e19a3a59 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 8db3a4d5a7b2fa1c3cf85a9e07df0aa00eeacfe1defc527218c7c8c82c86d21065efa2c2266360797369cc02b25a24b2b35e48fdef961c450d9b2ef0ab2899bd5a132958ea82bf2ce95bf77866fc09a5fa2dedd70a52c3c246e671bf75248e1e75077fbe7d75dfdca6b72529aa2d801feb400694b7970e90ca8eda5c14e47adb -S = 9724b7c6909ae1499a06410557882d9fe49a804c68c172cd5945e40132d750d47a454f155c075c0e57003f20cef4a1edc84d427b6bd9f61617ab502ba6dc5c6b1d032a380898bacb80d5484d39783dbfac37c4f001fd8d4e1bb2310d459637be04cd5fb2cf6b32dbfd214b8f7cc0dada942cc41c9f476bf6ffa502bf7928dc8610ac0097dab03f79171046af23887c2d530463714bf7fe59933cad26266a117cd355d0402a4490472b0006f6e915c56e204eb480ab48fe9ef0dcde5660cb9ad235890713f77b5333c1314dcc741c2c8d0fed546d23696275a8d578a0d39d4f1dece330d73ff1c20c72ea82e4b714db309a0063edd35b22f12ea68f5c5723c8a2 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = d6fd570826eb30d7f3173089ffcdc2f791c60cb4bc5760e6e3e9d3557da92bc21681ff7a9646192bc6331ff5109673c487c957de276455b85db1de0eca603132447c7ea51d9e4be4a8611884fa153e81eeb81dd46c227643ea7f167d3202b56666d81db0425b8faba289625e44b4edd6ce7aa7be13f88d30923bc4cb3ff78006 -S = 4c142307690bf57792293509295ebe275716356260e0fee39e72b64fd6210f547bbc8eb84ee2fffe5bca0121735f934d1832079031d9813902269cb6a814a71a09012f08f6f8ae10907ca0755fae622328feedd8da1ca666d2b713ca0d5b6de85b9b1cbbd6874dd980f304a313ca07e6c70a44e9dda1bed3d9a2cce521473661f33b7fa96c496b8f7a9c77e9bd0ae0dd47bec92c2a4dc9f75af9280402a04014523957efa5f52985eff48e4f1bd54858a956743dd2badf858d00c83213908baf95c527afcf0e32f7c97d4dde5dbb936ffb09500a2bc0bf71839d55489a21d642ee455dfa8b525a4d4890b2283eb043b3bf77d2ed7e2885c32b004fbc89693380 -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 8457c53956849cdb39bc8e7657d62a2cda9e13e1a5c3574142f1fd041c3add70efbab5207c7b78058196e9aae89b69bc3f330dc96804f44892d5d8da68f3e2cf87d3c3ec36f8006b51178d44877a9eabc6a2badaf2301110dd060fda74a9319136e91824ebc5dc179289a2cc9b3971025632419bac0f55a20dcacb8ca92372be -S = a2a2c0264dbb8b8810aae0b9ec7408553803dd02be6247358ce39f98f0c0f0339915347ff3c4dfee0e0a49b675ba69e376f3dbba56aae846cf7f986a0a5f37fc9971a58e3217cca26dffee8655f3025bd61776683feecdde546fa88fb881d619a8ec2daf092079a850340f6af41b2dd11d9935bb06c2253bdbd32a6fb8bd5317d3c9c3be5b683e7fd6366e1816895664d8ee312eca47ecf862be009d9df699a7d2f515c69e3093fd50a3babe9ebaeab6267086a3185a908ea29af8eecf81e2be7c9c2ae33cb2380c73af264d24961b5c7711b0289e1a095f2966656ead1fed95b6c33d7082c3868f1f7b706f9442ddb76e3582f73e4839a0a110dbb78e9cfcc5 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 6918d6328ca0a8b64bbe81d91cdea519911b59fc2dbd53af76006fec4b18a320787135ce883b2b2edb26041bf86aa52c230b9620335b6e7f9ec08c7ed6b70823d819e9ab019e9929249f966fdb2069311a0ddc680ac468f514d4ed873b04a6beb0985b91a0cfd8ed51b09f9e6d06da739eaa939d5a00275901c4f8cf25076339 -S = 794d0a45bc9fc6febb586e319dfa6924c888594802b9deb9668963fdb309bf02817960a7457106fc474f91601436e8954cbb6815350b2c51b53c968d2c48cc1799550d5d03b41f6e5a8c3c264d2e2fe0b5b8ff53fdcb9dd111c985cb488d7086e6548b4077ec00721c9cb500fe07a031c2030e8ad1dd0112c34ffd9091d77a187aac8661b298eee39eb615f9715c4c48a6762ede55a466ec7f3cdb6a937cfc80188a85d8f8d3a2a80b199ce5e6375af8f02f06d706a34d9cf38318903965db54aaa7d3fa7a7ee58034cd58c8435739c8906366e2ddba293f2fb2c15f07fa4951014471e7f677d3bdacffc4c68a906e08d68b39f9010746cbacd22980cee73e8d -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 4ce993829f7b8112277cedbf8b4ec59244cd7ef79a7bad09cfdbd1109a1a7348d7f472e57cd69853cf4070c2d66e5ce20f37e2eb623547e154265f167d92a3f03caf84eca981ffe3cb45728d0c10ae43e9b44d09eee346cbe297bee73fb021ece5df72a10ec4df4a85539926137ce23c3a0b685826cdd150e1f4978bc6bc16c4 -S = 29865f133c69122e1b309b299270b5d693db89c5192eca5c829c795db460cb1dad3d1f27d200790fab035c90c00b238384bb30ee30752425f2b7f424d71bea79993046100760f3fa3c6e019d025338c13940a97778ea67e6d6138d8e8ff601d2309f02762add479d85d25fa31bd1c89af97927dac2ddf818cfe2179548db4da69c163d8cbf5f9c98ea33957022a52d6f33b19bbd3d05f40f2dfd49d999184cf5f9bc69fc1b21359c3c85ddebb6936c4f49015026539e8c4aad2dd3a3b4ba309021fb317348d12b560ec608b74f812e3b74e4c8407765f30d6d03a5c20db821adc4c844018d57fb5364d0e7c3d55816782200ddf92b13dc2e0d4665b4cf3e1059 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = c801a9270165955fa4d85fd502c0e6be0c91e1c453ef734f331300034a6f3e8a2f958f9361558e1a7e25e7eab6c76d617e256674898029f2f4c9ec0dc14fd716869b5d886698cb4841f8212b28d222b91490a731d70838cd52e9dd46e959329b34dcba0ff77875705517b59f402c2d4d34994b0325d1c865b6397db7abd578a0 -S = 290d0d444ee458777b5fdc3207d37054407c0dfa6806296869d3ec402a18209a3d06eb63d995293697e8c0a0e72489bfc9132857d6c7a17f4852e4e573a48d2a2a127fdd270092f5029d976b060a570c90d685bd2325d80c9867a3b245455545bfae8cf87cff314f4d0a968229446dbf24adcd2a52ef9abd30b4746c2e04c0fdf52655427eb03bf63fdb208c6a776a3852052ac225eb33d7246f7ba624723f9c22abaf6d2f9219181ca62e44bb53a9ce8b45e7c6d742586a234e5de66df4ffbf7bc9e7f815a7d5aadb2f727f3151afa6ff48f6090d9fe08c8b0f1505598ca4a4ccbde6ab0f87b43059065097c737e53dc17f200c3a54b00d709a5b8bdce80f2e -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d060960864801650304020105000420af8893e585e7d2dbf3b8d3dec0802db4ee1ae86e8bbe369d8e1eb3aa634eb2cfefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 2466a246feda6fa5cee22c2f33ed9d643c1f6824d9f327719225bc7678cfe4c85cd210ed4077701b0b5650418177a74c71b8eda3306e2ef3474f5d326990eadea84a9686e822878c932997298e01f2b16c42e019e21bdfb67b3df5478df444366c97df1bdd23dc82ce23abee44d3a61e9484e88ed642634197b52dbece451b59 -S = 79c3b93019bdb8a6d6a79e813e4d96928f730afc010657b1eb870f2891219de5fbd464fce97b2bda12a9d84a3d5c120c660ed0f70457e223809b26a996afab7c23143b411a1aae566d7e9d19d278044567b5064bc918bb101cadc7a521c31c5e1962a7437d8f799ee6a76fc2f0a6733cfcb63246b1a864bb14ae70daf848824da565892d750af7c5da6e02e4889143a746e7e58b562d19cd3cf3d97795e50e1dcfa26d43f00357c92f01b327718d6cd292498dd29d0d830408b568b2c91541a76b21b5d4efea46bc128d9c4aea4e9f60a4a601c876736bf9312a00a2bd81b4ca5d8e37ab2c79dacbe7d8e6abcc4691db64649cdff212f467a9d805b2c38cd031 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = ecb6731a006eb273f6c5404a2e2d1faa5232f7afdff5b69be1dc7927fe88af17b5077b11e84b5baf98db08d3f1c99d3b86e4fa55dd2e6b542e91858368cd51d975b5adcebf9bee6ef309caac05b276f874a70b14cfce2e237891f003a8d3f3dcb328cff98d45b3d78db5507c72cef20aa4e4f094bcbc47304543824ec480dd48 -S = 8831265bcd54bf33d8c46cbd48052e9357c31afee92276b1b744e2521da9b83968e9ca90446064d8f174b248f64e792f91f4fae15252688e0f8ad38b28a532ddc7dc59e77d81b7a51dda2df2f2cbd5195c87b66db297b74296d4058fd00a060377dc1ec286c21e4f84c17ef315d443e89912e6b5d5f7d4ade31cc2b1aaaebcf09aaca20041b5f9b799b5b532391f85fd236ff3fa794baf4b25a2a188b0746728f1cfe0816b37d8dd648c53d76b81ee42ce27bf07baa27016b82c9ef3e1f5523ded7d35622d4986a6699b261f483e9b68b9c99e17e4aeb1c7baa84be1177264894ed5aab8592dfaaa652898b37aec28c19d154df27956f604bb6a30d0964d4e97 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d060960864801650304020105000420e45bf84dc5abc5c28a27625b0c96d7399fa1bba8fdaf1d5b5354970b2ff9dec3 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = daf4399ffab3de496e3ec347b4ee6f4ebdbd83cf434ea81e5d2dc6d351577771a9fdbb458985ed913fd2f5ea1cc5c0df8203eddb3ff9c94d191e7e05aa7887e16f6267aa1b8c9b393143cdded1f34a02d2eab60a125eff7f0ab28f6ca6f5c60853aca79559d1d1886b1bb1ea7c80f7fed5f94624658530fd587061d0ebd51a2d -S = 38aba878044ffa4572749376a12fa96b3b8cf778e68baa7ae05b4cf0457242f3a1eb8451678e79ad73741e169efbabdb0469a53dafb627ca3d14fbe392fe311e792b8f274e0d8439de0d9a82c14082abcc4253a5a7292f846ab816419b34c57587f2fda5c6be4f4a3c4130acef535dab4f0e05f5c8b18993f57b167298ba24b0d238964e0fa87114079fec872c673cb7d961ccf7ceff7fd5ada8a6f309de2d96a40224b12b921ad987b20e0ccafad43d0220e24b82aef90151befdbaaddfcb5b35e505912438668b4f61745734879c54c1105983c83a569560f35265be0d3ebcacedbce139c489f4be3c3befba6dbd6c5c92e0441a4a789ea383516be0f4540c -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 6cd8ccf65bb3833c81961801ec68a9735fefb8a5f7e3e63c0e47fd6b60f934216c87af801e444692aa9b8737bba4fe62cdf5b485d7bbf54a2e095684a66ff765facf06f16e6c84b2b2444cae0aa05196ace9274069bdc5579042895210ba7ca2dc58d8309452c70661386e4c21842a77c47219bdf512ddccfd9b9cbbe5024b41 -S = 12eede9247a5fd5579fd51f172ce798d20f8d932326f21ab0dc698711899c68357158ba1eebe07bfc1a78a08aad655da3a26556896267afdcd5e55d2ec91fdbf79960321ad13788e33eddd06b2f25347af73db9cdf628e8ac7a57b2a03555aacfd4af01afbd049dec0be8e279ad369a3c606fb1663e4b0f95be5416c5ecfeccf73c5d829ab5041e21ad0d1792b4536033f518b411c3c82ea162cef14dd704d23a278c0d71ddc9adc4014379c920e54ef8487ab3f5f6e991e50450c609fa769b60e057e6afb511df74ba7cc6458fe493a7a23e8267a742d20600f3c9261efd554b4c0b366ec0562c94c4180f34ba40780a24e8c36e110c40b6bb28b22394177a4 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 5fa43f0df5b0d9486b1e5f80a604230cb1159cddc9681462b47ca1aa547856c97bb7ba7c0183791014215a7fd00f71dd0f8996f28351162902b0a8a920b8a2c103cd6c89736435c63109e60f8aa7542e2b04bac9378b6642974eb2db924b361e9dee3c7c74d8743469dfea76fc5634c8ad8ef0aa0e9c6e751c5da989cfb87ca7 -S = 268bf5a0977722b24a174d83dc7dbec6ca1c392ad4a48d68af1b1ce30034e471dc8ccff5e5da865f677eb85c1e3022cadc89ec82624bc8ce5c632d1863a4946f364718f3566d38dda330ed68deb56130d10126fc9dc4f501f36e6e94507d5a556c8de76efd8149276eac52d16af495679cdd4361f66b7d963b9faa5ca0f8920227071c519f3f1ddcc7c03870a9639e78ce5f1e61b5291c190a4f9ef237116ebca742a513efe5fe39b1dd8914e71b60128b0e180685008ae206a64cc51c218f45db765c1af655457af34f94789ae5527dfa840a1cc9dbaef8003d81d3f59b7a3c440a9497da1be98182cbe368f0c984710f9ec986428f5c7a38313d43bcf680df -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 40bf49cb5825523aa5aea4c0e6b08b7f857f5e8a1ae01af731c14a364d272aa12d670b534d99f93eb04a9c78dd715cd628a4c8bc328c3933b397b23c77ec0b65a7a44f994a37623c0b34e7783d3660d11c13970056563efecaf0d25f8f2ac5e138dedb4556e7d55d3fd64d670ee6e199eb3393fd8d26707ffc3470459cc89e3e -S = 825731d01b0c197e2b27c4314b256ea5bc09ce9f012ca120695ba38c0ebdfa8c8802ca5137ef675f76a17038780f94f753b1234d0531be8fbe82e557d9357b18bea2a5c1cb83dd129e31e9c2aba44640145d2ed36470ee57a9486fe04ae13d1be2ea4047ef405a53a2d4f5bbcd21c9598de98046191bb605ce7004e3250b128a0d7d075ea7bab16a30f165fda23318547481b8b6c9bea0843876934bf7c89e013c9f19a8e661ec2e78013b89aa6beed57d88cb27ac34cc18f231c6e6dfcb8cc1580fd5ea8185b927147b564d31f724466d64692a17dda68e0b8fbc1a7cfec4bfa9c9f96f73bde2d0ab8948d09e1e739d5277a4d3d4e70236e9a3dec388986684 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003041300d060960864801650304020205000430e57e40b2774ca1517efc987400aad5a59ffe873f0532d8a092db7b4f7be006eb591eba4082d41eda449a261187bf3804efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 752fbf49ae63c7853b3ef6f52ed324e53867925bd5d4c49dc42b93f3ba9d7eae579c4169593da98f10e1a61e1214a2aa2fb511a4a75849dc9be89445c29184f85ddc877c6d1cbb45230a047a98ac5bfcbe7b69a397c454cba44fd90fa13f9b546f39ba0a52c8a8ae5c0038932962f8e3cd00c1e00be28c70c8a787d9be6f69c9 -S = 80d7286710e5f165eeb63d2936e8e313ac5999bd297d35590c2b6ffaa4b7b7ed30003f0b83c1d1996c8593a37bc5d7b501a3d126ac6124779a23718497002d9dd2ce891b83d185e333af05460c6deb65a509640f775a0d3c70e55112c2e4af19f4ccec7af9ebb34226164f1b47d50b8ecc1dc3e0fc09aa15abfce5aa3998b5c2b1fde261c35eb43220f0d64529f723801d7faff841faba8709f6ea7751f30428dfc58045c84995107ee013ca4a84f65b99adde1abdefb5428f834ac8da04dafb9beaf1813f73a4bff2ec94120e3a702aed1184c387ebda2abf1959970724299b9a05f4ad313d91beb5344fe1fe13b3fc3386c279f031c77d74bdc9bc97e22455 -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 18e158ea033c33dddfc57c8d6c8f132d9b129aa64416cd971bd3119ae1564fcad726028278288f6767c0d6a8a73906840a67b50dec8a302c20760fe62bf10dddb05d171a2c97a309e41e43c51b787a9687d1ceb906e61e5f8e2136f76205a1b08ccdbe3a875017cd3c28ed6d3013186cfb990e30fcf041374b1cae57ef5ab24b -S = 3491d346ada87f5585e13c5e3ed29c35f7f8536d16b99a57e3519c6c0fff826e6e314ffab85c3d5918473cf49dfb066cf107db8398840c53a1582a2bfc792c7cc1b72d3ea0a0ee0bd9c5aba576a9c1a41836caeb61da3b019fd553ec455b5b2c66da6682595e1d2731135ea8681e3d0b262316763f0840f030e6e26c67f11c1bf93dbe71b82d593bbe869ebf8bebf831e62ef31d2851469145a1f618734baf114716c0949a28a27a83521b5c68bc5b11081f6877562ed33ad603b436b7a9f98dc0f2968350810e24477d87df566a77f6197796a835b1945418667596171868a6b14d0617a2d76fb85130d8f5fc397326ea5f43587ce1812eb86e1aa584bb936b -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d060960864801650304020205000430cc8f60696cd0d4217858fd042c6caa3350dca7c9e36ad539e96052393204ff21a692e6349566d013a30f59c2d6bab449 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = daf4399ffab3de496e3ec347b4ee6f4ebdbd83cf434ea81e5d2dc6d351577771a9fdbb458985ed913fd2f5ea1cc5c0df8203eddb3ff9c94d191e7e05aa7887e16f6267aa1b8c9b393143cdded1f34a02d2eab60a125eff7f0ab28f6ca6f5c60853aca79559d1d1886b1bb1ea7c80f7fed5f94624658530fd587061d0ebd51a2d -S = 091d2c61d369410e236653b2b1b068cab3fa6632220f72737520838b7febc00bfbec8e993c3c969d7d4825ebf03a5ef7f087926ef7316f97e57e515f9aaa76b3a7bb10e64d983e6c443906882028dfb7e5fd4558a3f24b2c3b863174b011e8587995eb425d52e95bb27f98413cf2a1f5999990df7f5d3835aa19b93fae1b1734ddfd2be99b9a5a071d062b707543b47aa650faf640afa43a51c4013e27d278557d4429584bdebfe5fbef4c9bce178a496c0124aadc24d9ee8af3e0e83ea72ea93751eb687875902c7348a212819097860041a9773d810dae6d3c9eb6049ffe38e2a09d976cfcd3dededb7f374577458b25124669a85de7465b8ece756633c1ad -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 6cd8ccf65bb3833c81961801ec68a9735fefb8a5f7e3e63c0e47fd6b60f934216c87af801e444692aa9b8737bba4fe62cdf5b485d7bbf54a2e095684a66ff765facf06f16e6c84b2b2444cae0aa05196ace9274069bdc5579042895210ba7ca2dc58d8309452c70661386e4c21842a77c47219bdf512ddccfd9b9cbbe5024b41 -S = 0f8e07afaddf2b88cd2ccc2f720228e612ac00459aef46f9605cc609539097e60b10c6507ffd3fc27a15d348398c573bc8d385edb18fe0246af4c0ab32165f05a0b641d2e016f562397d3080d602d9c734b4d00b27f8a016f58aff098be7d09498b8e1775f0d7a3f69c383dc1abb2f177fa53ae8c5425a82a1a9ef0b428b70e48b7bd99df60ee016c4bd02f428a19225d3cba5e640d297cd28bf96a45cfa8e4e222e245b55a5528301d71e12b70246338ae0f4754b74a45fb670477aa1b1794ca1067aa1289819290ac7fa23bcea04442fd2c5ec835bb4a2d007fc2f9530995409f1e707220ed5b845feef66537889c85a89592d2df941cb61254b7d69ade808 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 5ba7760eab59b0b7eb22f2542c627352ef1c75f931f06dfca949644e4bd79d38104078a9f91296cd52fd3ee0343f00454d5f98d2e31e156f17ab3adf671624dd77072d6b11b011676a004f5fa719d2a69f05d1a7e3a4f47afce9b8b5f346148517655dfdfa1967adbd94ed778dda329e6e76e920376b5246de6da779f651b657 -S = 8385a5fe194a10ad210c8dc069899df18ba80008a47f0f8479aa690eae5588c04401b96afa0d8bd6512b98a46d137b32b48cde633f04604f8f08f63daf4f35b836374750d08cd20d4553752d3eb5d27da8b8d12e86cb81c592d39b66ac38c04f0d5140039f165ed670b3757282816f6b607e2708e66fc699dff5e81cf2861b64a98b572a5c417056fee1335e909f3f7b9d6930f399c29a92750b486263081e6ecc2a2da06dc1883f687a9fd480f4366c3099c7fe0d56c5c7a70b5a710ba021c075b9ad46e741189bbccc4f4ac936e71121a3c62c577f8157b1919df586569e6bb52158fd0f8d08ac1114981f904b5f8b267a12e1098b2f77918ee9189dbf29b6 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = e703433ae230a79291405dfaf58386e63fb5028088dbcda5c26e8f30efbb6e7c918a272461fe5d0d43bc31a77a4f126f18ccd6b9b9b10aac7113878e03f946425403760e1f4fcba2e99c185638b020b400f8aa365e6fd35088c0a8b105aff4c719b5578184ea98586c293c90976e58bbdd82a380dddbcf9af0bd1a235ba62013 -S = 25181c5f1450e2179d3b6ee166178c674fc572507cdbb0aafca5da9b54f10a3f223670db1122140887e68b9fe8365f316981b3d611157e2d579873a2292daab5e8ec6844ec58021cd814040cefda9f7cc3bed4eb0edd3098e3d9e5546060f19df911f1f89b92e82dd7aa118623e1c707ce43a2877ad085527ccfb5d5aa2775e089e606192f785f3edcc02c59e28dc9a9eae82647e1644aaacf05c91628b1f9cc55c683ca5e349946799f456bf8f2e943a0d93966521e2c35e294ca610dd93f4d871cc80b15bf4990a0999ab392659cd81af705ef0a3d84968f85393dd6a53579c3e463ff2c08b9f68efd4a0cce43c8118fcb61fa2fc47aa9ccb6ec0453b7ba51 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003051300d060960864801650304020305000440df5bda9e56bdbe752f0af28644291a8d0fd9925f8794a485f27fdd5b3c603ebd68742e334ece1969a14dfd84e782e5ee8c8836b93aad629c63c826c84cba848defefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 5cb7a0a74095a6f284a13d4392aac30a73a9211df0520bf2f7e9831240579fca2f7d8d24fdc8d4161306dcf8b678b13be92804598f7c7308d10c0ab3bfb1092a3adee799113498b76a500c3f64e8f8a4fa16d8012bf3354e576823daed410ff54383b7edc5007a3d5228d200e3221fac6e1ca6fc0adfd92e53a6d96f10303994 -S = 25b408187418c512e7d36eac17edc64999e94011b4d5088ab926d29e433a69e24ebac43146a1371635fc78c3d215a66ea46d0a734b1607fdb9c3848a1404545ff60582abd579d978902ed399eb5dcdfacde0ca02145480246e1a22af5ddca7080aec216895d3528a8756e0c1a2059d392f87576fe896e411ddf02bd6be81ae2a654e0a15542a6b533b776703e2057b01ad02f5430d97c691f80219e46319de527541f0bfcf0b4e1b510059fa20779eb44b1ef293b7a8318447ed25793037ddfd1877cd98514c81575613f36d946670f632779eaf629a593fe99110e781cb38101a3cbd54d7871983dbf868a00cfcb17bd330309d43b8df8d4f05eb4c43649cdf -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 290d117f97d672f3647c2b24402832b153d22a25820567688645ed95ffa6e38d116347486ab4b485c27aef4962653bb60257ef82256785a1d3d52aa0e0b94c37279dee7bb308688aaee98108de6f1373ed2c12429c9b8770756c12c03908b346b129f963bfaa38a8937190cc656f057ef1a812dd0312f51285c4f46f9241f3028ea6a61db0e9255976469f5d5542ced55ee2d6f4afe766c0a70f49871d369dd8f3a82a7141639efd4a1f4a4009821c3c2b9f5c5f5eef99a5f00fbd8bc8191a3654e8f8d8ce12d90e5ff2a4c530b76306c8c56e0549a6f277ab2af3a60cccbf4bb4b2cb47f04f211f8b86aa653bf6913f3b5ed190c51b5958e40597a2dfd30061 -Msg = 1d9589c9227a3ebe444b5fdda538adf0ae8f8fd69b30b58e3a41fb91ef229065fca3576fff758d09bcdfadd41db2904f777fd9a90f0790d4ddf30ddb90c61875d20f4edacce3c7d5ed8af51be779cfdbfb802f96774579317df17e490529a0c6254036b391ab324d5eb501590b74b2bbc1fb5b45dad1b8cda1a2168258356f80 -S = 6eaf91209e0a5f7d985231c7226732f64e2592e6be2886081f830119018ee427b3293ca3ab4156a41684824f26227401f1b10f7d993b000f3bd5d82d831bcdf772137a2982af4f1fa2b57b49833b97f448aba20458f3bd8417872f7d6b6156300d87aa87f2aee301ff53b6c367dd6907b61b6336d1ac97c4aae90e7919d94b1cb0d919a33003f05f941339f5c7de72ca94d9b65d42176deb086ec259df9e29675c087ca0d42f51be4324f8e1bff094a517083e51794dbb68aa229f7c1560945142c4e66264cf8d8fbd43dad4de21b96522f4ad7d1d121fb320204b008ccef86a22427b59b8e58d7e44fad62921b44301249fe1139ff656fedd466ffd46c27703 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d060960864801650304020305000440b1601c43923bb80b35c45d083bd748d75a3fcaff22044525ab82d705d5465863cb373e069fa40c9b8e5aa4d5ff7ad45700c7a8da342bf0b16686db87fba0abaf -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -n = a911245a2cfb33d8ee375df9439f74e669c03a8d9acad25bd27acf3cd8bea7eb9dbe470155c7c72782c94861f7b573cd325639fb070e9ba6e621991aefa45106182e4d264be7068035595d7549052989b3e7fd04cabc94012c1278a0ef8672b1a51dd1a9e276816ba497dea24b4febe3dd8e977707bcd230ca6fb6f8a8bff9e6ba24fbadcd93f00126b19b396a38e6ef86d18fef945b9154c1963fb488c7025953511f86d05638bfe056493730bc6778446e59cd3c5c3acf07a0a3a64943793652f10e3292aa7a6d25a03181cc6f6ba0658d909e59ce2a02bacc9766fd8c4fbd4ed9c23a866844b8a794d49e505f9f944870a71aadbe5338039825c2dff81af3 - -p = bf96de108963b5113399b664765efe046e2dafdb70d6e5e29dc6ec89b789b059348d74d89129c7ade9ddb404c6dc3a3437c7fc9f23bc38dadc8ffd0ff757999f5c2d510b993056147ccdf421e03d0be2c74ec333a9677c430cc604f5550d0d86defdde71488e3db889c699a5cacb44dcdae2f3cca38695e783e6f6250827efb1 - -q = e1e7e33618d1b64d6862c132e4b1cd5fabad20ce62bd97bce2a3f5ad2da67bb0a7f0b9e48335a33b7b95e77ec4c47e91416881f9f7c23f9bc1918cc644335c74260e90cd7b2e0fed802f19e78c5ed80a431b38630d82f982c74a0381b8ecf943c60810fae90574e216357b2535002316d9529cb56420f3cc82dea37cb624e1e3 - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = b756bc9af8682c9473fe98082ecb72f33f6199099baece582cc6672924e3472790a90dc330af8cd6863c7c882d4e6e726ce106ff0b6d641865b1e300bfaf067cd8f8af38c1299266efb6eaa88fe66a30191f772528649449891c1eda921539b6b5c80ac255df278bd7f44b2efd9c4f766fa455459b9a4735bf8f807e441cc81b -S = 20aad3d29d4bdf75f18d3617771723419920e688928a0c742af8b11bd2e05767afa0256c868c3538111359b7bb91dbf1b8bfc383a1573cec0bf0c62837b13fb5df21e7e07bb5d758ba8d58171d22b46147d6f7bd3b8751e97ecf13a5bc8c9b5ef7f00702c3ca400b6adacc6de96779a48881fd7c3f544f95f99ac1037f6b9f49c308aed1f6634afcbd46dd6fcecc015fccc24716cc590687fb2492c96812c9ac037f743e3b47d60420ee271331031d290fa6179178444256acb5697fbcbfbbb4fd3c6227566de99b246a8914721d5dbe58c2411df01348b63bce4e3659ae7ad09579be43acadad01ba02eb4c118b23ef64b318c7424920c5da7176ab2cdadb84 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 196c5dfa45aa9b9d8c8f0459ae650aeb45f1b05e06a6ecda44194fbdb5b5e7ec79b0656c583d7b2c4c0488253fcf77a51586e4e8ed5d81e9a44cb9779bc0938bbb90d8d9b63278a58f2f2ad85cd453534b2a2983e32918368c2965ad529911f2e6f3006ce5ef5ab05df8329a8edc659dedc7c5576f72776803989a8560aa29c8 -S = 4bfeb7f6d376548f1ada66742eb2320689db85eaca0f75845aff7cbc91faeb1efe96ddaeabf8f9bf2b3031aff3711ebf9e4bbfd46861a8bb5107aea784a78205e067779e98be0a74458c0c850903f58dd3541636c2160a8854914798310324f852c3806f0a0e59ac6b5d3ccfd2580443d09752640e27f41b1e692b3ffec67c39868f4605230b341a2b56ac68bd2fa3450df2ebf4867ac0156be6513e03bab686f435c931532632adc177e95971bfad056424230943e5757d0c5384671592b7b0bd4a454d4d73bf312f4f46f2f310e897bb657be3165d040ff0d8bf72315ae313fda1052c37307a31c2f8d4edce4644b5bfeb5ac37fdf0e2a393692dfb72bb4ea -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a0500041476e8a26a34cb08f8f58253d073c53dd76a749c5fefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = c0b251836d180dbcb995b4ae6e18856be5e8bf067841b753394226efe507c7801312223eb1efa2b3b117eebe001676deb8e94cad96aa36abae6f013d5d6f18f680665514e33b164efde094cdda7b707858c38f7496ac28ebaa461b0d92e285556d78910eec45911503b84de0e48f9abf2d3e2f626090b59c95901d666baa3627 -S = 0cc0b5e4251083e72898e6d239dae55489a42675123fceb8abf34886846e5af39d109fb65d55fb019c43c3fe91b891262d8ec0aa721acd97848f455f049d6af58b5e579b92208fa48f7afcb403dd99870bb25a15b33a67b5a1ad10ccf3df04fbf5fc42a2a0dea7b6c689d18da14757b2b5ebeafc39f62b5fdbe58f44f03e148d4e5ae6ce1bdce9f316daf7722ba6622ea6eb964fc3d0d9ab54ac226a3371ef96300d9d737767cbd04963015781d14d9f0f640b1981219d391ae1d94eab184d68f1764e7dc2aa2890b08c16ac277aab85e2912975702ca0834ff7026be694f805fb2692a605635a020018342dd89b8a53f8b5fc7b5fa8b13fbd9f8b5deebbc199 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a05000414f40c85085852eab21192fc3cd95f0ae92a42c3cd -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 9df2b3e0f8035d92193f0c980e8ce31aaf7218078171f907da982db246533dff2a8553ffa7d641cbc14fc4bbc1240ad8d7d07394046795b9372882a0b7524da3c03acad4719996f0e62a578ea175459c2ee5ea0c062125cbb59975f3385f7441a939a2c91ef464e8cefb4d7b75289b4efad905d84f47b4259a138f139222bbc1 -S = a82261947dd0f5b3f34197bb91401278dca36b759a7402ae65d8db6b6a12fb2bcf67e564d16030fd1b7e4e4df9bf0577c5dd5d6a5d8766009277003d0e7929675ccdfa04285e74ecfa1a937db117a130fe4662da0a869d7d34832165f86ad8c345cd6aa027036d818af45fcc8fb7bf55975c948af26ca363ff796c752afafc8e5afc5ce5208bacdaa98601046e69e648975a87ea34b011237bfe5f734d9470bfe71cd5053e2831d321fdb13e2a4221f992670782b7c584634761b7b96a28e33b69eba97ceb45aa1adffb29fd4705e4532e0fe1890d1575b5e43d4aa294c27936999b413a3086b000050330178b0f71248a0a92af444d8fcdaa0237b7952602a5 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 3f3544b53b09a91b7f1a27d5fed879788432e604a8b6d121fcf98ba886396b657441211c0b8d47c9e1af392c4cf127851a3c689d823811055bb5c7a28c4ad16ac43b71686ba07506d8c4098bc4cccfe3fe99329f61eff73c04d614a8b040c60297eddea1428c5b59cc233ef94eb09a189a11eb122c21a84d5d241cc1da6571b7 -S = 8caf5231442d5352259da89fbf54888cd32774b7851232b21defd3ae6d780a5387ec021f0260cd299ced9fd814208d1102620cee37b2d48b5c9ad90c061f0c2a527bbd1eabd7aa76a5f4e083483eff1a9b5d62dfe57c751d9bc49991485569142c65656a67213c37907db465dc7225c7fcdd7b9a37e3d6b887b07c3dd07dfcbdde86baccbdf6fd13676e062f9f875f912058536fbd31d4dafd9c051bb79236e6e0f90db221acfae0690b6fcba1cd7716145afabd39866e393dad2ae99b24f9d97682e6c1163f5f442c4e49c7422923625b63e82fb1a3186fcf0bb81ba38d6761156b1f723c0de7fdbb0c678effc49c128e655f36ea465d41e704ad1b449294ef -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 2726543e530ab04b06a11cbae1da53aa966dc51642d390fcfe95acbfb0ca65cb28db0f77688af52f423392d2295104594143bdbab8517c0b59ea7beb5e2fea1e86b69d77688702fb076b5543a6671722de83bc88edcfa4a651a84c539638c6af6c3c6606fc0abff77cd2cdd50124744d95b229498a58f0150e5986c0ffecdfc6 -S = 51d57b3e66fd6e271241215438be99969c40d0ea4a5b7c4918143f68f58e5cd9d52d90159e7bdc9b73ac3d3d908cdda5e402f0fd352931f9bca9dd886fed30c791efd2466dfc7c6483aa32c2865cef82a40dcf5c5bc3aad547b8e1dc9d973c8b90f529ef272a24645a6b76887925b6e19970d9f2d7d68a513f2e1638b184aa8cd20967618d06662bfe1450f03b72d19790fd1a591694043b310d982077285deafc28f95b3c6218edf59649b38e9170fb3f18483fb3788a14b161648beb4ce471c0ba4c041b87e6b38067fb934f50908b755bd126d2904b75ad7ce75a8a5d0c3540e1d9c7ad52242f2e5a5511d46ad8099f9386299f369e69e53107c6f51fb985 -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = b756bc9af8682c9473fe98082ecb72f33f6199099baece582cc6672924e3472790a90dc330af8cd6863c7c882d4e6e726ce106ff0b6d641865b1e300bfaf067cd8f8af38c1299266efb6eaa88fe66a30191f772528649449891c1eda921539b6b5c80ac255df278bd7f44b2efd9c4f766fa455459b9a4735bf8f807e441cc81b -S = 3840e121a02c4d4dead5197cabbfffd00005c9474df11252853dde2cb83ef772e2a533d7e51cf524af80d1a541994018abe93fb5835989e870ec3400f171ac786678fadd6e478ddd2d6f95719c559d737dcf2e5fa0b875827ad8558c70f6b8ab725d7344ac5197270e494ceb03b89680b8bf99ee9260cf91f0611060d7ada8d2c7eb672a2957fe4eb1d3b027c4062f2d2d840304e4a7faa243b816b10bc893b2ad48e7ada998eabd1e9fca72c0820b9b4feedc3733d20087da09c26e352fd7a4962c707a7ba9e1f66b18ea89d96d0059ebd13d177bccbf2d80a502a7362e198d7bbe1199d5587c06e1192ff539ff5276ee5ee8ffe25df0a1998e5c8ab05d3097 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 196c5dfa45aa9b9d8c8f0459ae650aeb45f1b05e06a6ecda44194fbdb5b5e7ec79b0656c583d7b2c4c0488253fcf77a51586e4e8ed5d81e9a44cb9779bc0938bbb90d8d9b63278a58f2f2ad85cd453534b2a2983e32918368c2965ad529911f2e6f3006ce5ef5ab05df8329a8edc659dedc7c5576f72776803989a8560aa29c8 -S = 411e75af44716f884c084569a3500b74017141ec3f1c2768e0720d3df6cf221a155812756068bfdc74d998743647757d80e15752b0df1ed038ac316aa202a5eec1d0363e773a372d9f60c4d5c585f1111ed44b02c241280d2b6980b2cbb09128ce9b6ed38d50dd0ce10b73961b82996bc82a48f0d5a574910a691e55048136ce8f3668cec4cebe5c791d6b66b6c54617bc70d0d578080f22d9ed09030887bbeb5408155187a03657b55680c614e57c2e28e2c837eb7bdbec6985af6b596fcba378084d5f1a4fb80ec426966d9a9f914431811a06133c4e6df7a48577e16a8b6cc5af6873b70dbb5ef191ac9214866e73f0c99f33da2d21d313a6bb62cf03ea01 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041cc28faf02c47ebeac647f99f7cffeaad70df6513830d41a12b1d05b62efefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = d699ca7f777828b13679a9e2ca89568233b8cf479d90462186a5ce71236ed6760053f007e807d8880418b11746c59106090f408ef1133dc1199602c16de2893054d10fe7932718eb6e24b39c0f5aff302cbdee60e5f94961eb08f516e70374841a38ae86407ef2c2bbc538dbedf1a9e9e6e961263fea73e945222dd95b7a9e5a -S = 01818ab2f8883d5b580b7d7fdd6bd15cc59f59842dd14649b27aa0aac3666562e4ee8a716d8f9a6fe19bcb5f505956457fbf200b8f0121a070788a546b86f8149f0aa98f2c6439412ed4a00114259b348d1f9e583eaa54fbc384c52c518159e460582051afee2d4163350bdba58112bf0fd9ada18346891ac14888765a68d3475f8f8f92ac9e5f4b02480859f239405d8fd14a05ef95fe9b726affaef8c8d54e6cc3a01a1399b2c2b2eba18b7e3dd7ee337c0f108dd53c460112a58f7e6b09db540ebb72fe8e3d1afa5224705f0159aed4d94d4ec0711e58873682199c90e9aa0046f81c3faa3fb21a0a05991f0752ec7e1c04d9009fcdf69d68098f9eaaea6d -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041cd8a970b5e7e41f37017b8160a04e42a8bcf502522a1ffaa739d6cee0 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = b1d87e6e67cf95799888c51383d6e6cb4fd8eecb4d2959ac7e58ce8f5598ff69bdb8d19e5e55bdd21c4e75fbe178cbbb9d93cfee8b7d387fb5a6067fbac46578cfc8d3fe04108588c9de077eb009249374f205553bba9d0218b2449ed413a142eef0ceb7e068b744a420c3c377f1b7faddddd729e5484ee0ae64cf132aee7d70 -S = 3dfbf8cf23053223500b1cc0a4e43e7754f3490f33648064bb9a806d17b8412075997148a76a152e7becbcc26783fb0519df481711648b35ead7fccb9937baf37e4b86133c15ec2ba0311ed6cbfb742daccd68bbe8f1b49766366da644302a04ec1952db9fb8e50641e3b0cf9c04066f5d49cff593581beedda78e50615c5f42f31444462f59e1e3a8331c1494867361073e5ebb8d6ecbc5b356454a4d24d87ff4dae556442384aeb0cbfadb3437074a76969b8f213a4e8a0a0538114888c95436582ecdae288c4f142612e5ca9e273da165cade52674f7668dd170cde6d7f8e6c02cd1cb013c87ab4a5c71f9f04c20a0fee617968f4862a101726368a96f3ef -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 51a9457af4abc1b75f3bdd4a383b7ad79f1bdcea045b15953b4bc15ad216f44aa2fe716fa4e91d68061db3537e48b8f0dfc3b202ea1795f966c17ecf7332a3301b1a8add2ae67a523f8730a72476d2b45bf52978f9970abcb80215f347f4a365e484f98c2dabc2be3302bc0dd1cdb16c3c39a913dae25e245898f08ef763da31 -S = 9c7b10642d88022ee6cd2816c95178a5b163ab887a3b663c0236228b72a6a92eb18d3a0fae84526f1e17442a2dbb199402693f166d31d30105b7929046db4b1812cea8d7a1c5d5d53f785130cae9816b8254de0aaaeecac2992a1df4796dd423641d685e65478850a59436aff0f0ce36f1d3111719255dd376d8315905f4b3db7439ff2b0fda6226ba64df947dec832db48905a3f2d0d9a2b46f92d91794ab98734e0a7acfa0b60216f728a0a4f6c3e188978cf745e620cb3a0fa836c1a548e1b1bd2c03926473ef6b145d6fd99eb5d512632334a2588fd7b2640e0d893e6fff31350a467543ec4a18f51853bd4566674bbc2867a18de04953b1cca246a558d7 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = ad32c2e66fa67fa97cbbc8736e36a04dfa8aff5f734c75098fe711306e9181d6d87e7aeec7535b6e25dd0da5d6032dcff9f96de76bb737bc8daa944748a94d3c4e2a50dfa2b654195a9ac0cba4e0c962077ddbacebcc3bea5c3bea260b45ccc695a0096208b7b4d3a45aab8cdeb4be2eab7e1356fa73c8b98204db74bf4c479d -S = 1c0ee89d483230cfe29503591c7d002e1930128999e06dab41d60e55ed7fb191b068b2b7c606e0b684dfbcd7b43045f10cffd72e96fdb10af7062d1e3af334b2db7d79f3ca478ba4d21f4e2d9aad635c47c15d26eb86643ff15d5366074d009bb4e213902f8c4ed53f5f3c2e1ae0771f0441f68257aa9705a4044d6846103c75f83c96f3d23a450681394e0f6f816fdc5545d96321e90a4c0a90899eac77751933f502c4b6fe72177ac1e9d3f3a67b9db66b96b78361ea7c47317b742d6f6a941a55c496cf7fcdd73ffa79274898081490049612f580a8d1e7edc95c10902dfc0826be1066e489912bbdfa2c8d6142ce9e1d3dbd8c9a9b9400f39579589f003f -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 585e2aa15bbe0f218e5119f95a252b57ce65d9474d35c1c284de1ee79f2b9a88bd1364e8a19783c3aaee6a8f05e0cc022170b1d463bdcac61c2a01e3b8bd550638c5e59ce2c04aab367b2a14257b0a157e9c6411a9f8fa94970a6992f91401efb0bdd44485ff0de11b40840e21bf8f97cc321a8785aefa33dfc67e7acbf7474c -S = 2e02460ece0246277d4517b9c00d40ee669251ce1be2d8c13bcb67b7e90635d6a68f8cf7373bb5962ff1d182f3fe706ae3e216446527cafe5e763432141f92995002f6c6c208e85ca3203de5d6602db70c2302c804abcb7b3a22edbc120a3b59b1febfc485bd787ff0053cba05d27800ab41bb431d9b7d7ccf0f1a5f52eda8432fc70d1bbc5fc766b08280124df71d7432542d5caee7d88db6654510ee81c3cd23b1501679a2fc2b050acfaf9218d7c6d4b260f9e8b986e9dd9c158820379609f11626d6b35eda024aa545286e884b6e135ac3e18d52c9be687004f0a81fabcef972cd2e82d954a43ace6f1971d7311ba9f267b262303cb51121fde66e073e10 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d0609608648016503040201050004206510c46f56c48ac0b28992c5bd0fe4047d3baf1fc7e528f67b15f3b9188af1a1 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 790ba59678e1eca8ce7e7723488b181ff1fccb3e339df4df3eede794ae30add767c006f8c4a4aa5af263d4df961a01a1b6cdf5e3d6fb004761757f414b70a5cbf5d87c5a51e7261146f7693556946be27ed6b9fc5ded8e6799fe537b7f2e62b2e9fc0fa465d3e93693df3d0ecf21dc4a10be1e71109d27a9ae30692b90926af5 -S = 91a2efacfa4e8642b683ff7c17b08743f8bd03950a35ba44372ef1814fbdec087c033d6eceeee431efdc6a3fac97f85b8248a92b601dc4ea9e02a23fb921655f084a4035b42c0e491ddee05c4d3d4024b6446caf77e917d28453640c0af50d937b5d74b535acbb3ef9b2dc87bd3cfc80f24d2aa9b1feeae7b549c197cca6888fdb617c8a5a1c91a23c6299cdd1b7d292b0227634bdfd415cb6f12723fca2edcfd1176a485b2a2cea075765785077c84de1c50da27daf89407becac9fd9664f2547c5a9f66c9ae3c14ce318317c58d4c3d3b07f07d2f8a58fc10b854b583a628054cdcb9f7729e5707d151a4ba82b1d99f339d4f8a0674f260a8a6b8665169fa0 -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 4cec86b6da42bda1aa66d9f6ee0ec6c30f4f575ca2bcdca198d2f67fb494aaba4372b5e9076f1fc2748313971f3eee2173af967da5840d74eb7246ffe9d8370a6c9f2f795b646a69ebd9e3b8116869c73d1af57e45b83b919f307f02d439aae8313a9d6ec068c51e772fef60aed45e3dd7581b69699f8d811dd249915d012bd9 -S = 89a014c41636b64663cf381dcc399355e2974e1db624e36d5fda7d3967417a3810910948813ea58caab8f7cf2dec7309d26d5cf7db0dd60a0ff42982b91f64f17cae9195f2955395e9ddc7335c441de9b65a0e252f98db17a805ffd0d0b9a68dd6be098107f1a6f7cd1292b2d6a9c23cd631c62709b72eecfb9fcaca2a3ff036984bafa785722c3fdc8398479ab77a3e1678c7af85f75f7a2f4f54a13ecddbbd4aeec7a96445c885d12aaf236a9c4058e3e669335f5fde34d6905bed45cd741d9a08f8501706d03c7f98b2c7214eecbf4759d661a32eb9c302a9c0057ab734b46dc3575ab42951298b59d3d8429339fb58bf035173a84dea90cc6354dbf68d31 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 13f936517eac73d6776695c1ff3051850e32fab734cc46c280e355dca079ef3949810e7edaf19c783c187d0e0c32d074fc3a72a276ffc405837aaf74ec5fe5659ff26961531c51b56fbecb6b28455e78ea7f7237faad131659d9f290eb69ac5bd8f54fe233561bf5daff85bf9d9182f9a2a9015e07fcb95fcaa72617e6c0ce81 -S = 2eed7fbbf583693f63e22bf78eb4d389064c21c37b66667c1b1994934bf9ace14c30279253e9195d176535e28aced6719292b064f2cf99124d55b347a14c960af52e912afb53356168d1f19727d19b65c5090c4db0e4fa9ea0ee3d3f28ce0a956f7011765bb5e58a14b8854e58e04723bc73de96278c78efbed70ebc8052d3359ba967dc91b1f982932baf770d2d2f252f37d274b9131e8c5d4607b67115bb18200a2ead70c6882ff721284d0d0876ee85e68dbefd4e3a9d5d898aa9ee6d2195c822fa02d74ec85d7a93d9688fdc5fc0c93d9c7df6c1519ce1384174e2aa5fcca3bf92e260274f2e0430ba4f008928d6ece05f0ac5a26683ce956fb7ed43f7b5 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = c81e98ab21239d9d887553bca6ecbc55a1e4593036f8e670080d44ba3793b79935075121d5bcaed3a5dce2c17ea9b0f35909fd08644283205602cafaffa2545a23ab18ae889a33f04ee0d9ce7f2d9109e7eea21b2615c81c03182ce6033c93783b13d698624392bd2a8a202bd0ffc860f29b31afa2f71c2bb85752c66ce8dbba -S = 36403d0116aa5bad635f855b1aba7ccbe7787bac4d2d0678fad33163c6a19e88fa53acd13646466ba5e11668752f52ffa3333c59d9e00bdb9cbbb9e549a47c700b1d8be5e1a778056bbb0f4d0a3266cf5b78b2c8a224f460a20b31963105236decdb49f4bd3adad75b6ef5331cf0d54c91fc0337a5ea3d1dc94e6182b11d7eb6690096242d84c174a0c01869c81b193156a730ed08acb516da3a2b1646da3fc8742191e3620d813fab2f4288768388b5c2892ebe6a42b7047401437b625b7d87368991020aa1f4831088343c51af5217334f852c49b474fdee6676cbf8d78018061bf3c398a75a73503e868468136afc187ec1deec0e2a852b454befc60d9873 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 796a46d728d7d9d6418710970f311d92f5362862f71df0d47b3fb63e51c35712f2cdb8b205f3668628f17e4dec9dcbb0211d2f1d555744d297a9423881da2473755106372685d2dd5ab51bb6efd9499f1cd8f7d5fafb990b43a262ba593665b98a5efa0d92766302613daf7b1fcddf866ed14833eff238a70792dc6ce3bd610b -S = 94c00c47cfb2eabed6ce3b04f88e797b1b2eaea162dac2e51fcfc8b9f9242c0f48f664f0b65ad4305867758811fd1cebc244f026684835b451e97e6806ad2427700f2d9c12f681b2d601fb6ead7953209a0c47db678ce0075f34705e4b1cc414f74574b4028bce76a69e160ae8180710b31d42950b66f70c6c28b15dbe38915e8c36d7df03ff5494a1265041a801c5916ff73e08bceb792c536608262d60ec34f4d3ffedd74127e9d5b237af1d300ec58bd4475f05c568978860804818fecea2781c96752821cf22164b1b917f3032c58cd47996e3ff5284004723d0c27a3d6439da0cfb725b991601a801c89a77f2ba174e3980d7d3f1b342c4b6cd16121656 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d060960864801650304020105000420e6689fb887124d3316d9609e412b959be86b7b02a1be76f300ebcfc82701a77cefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = ac481c957d422abb5ce8a73366bba51b4b718d83ed3c59d22a4f0464f59f3f78ace6664aa5eeb27c0b0cb0bae8eaf29e828a04d1eb88a174d4a027bea26f49e6c47e0443437cd4b29acb2738c93f12e8a5224307727b376fb38fad3141a95a7e9b17dec87d75f724b42ef4f3303f6dc15b3e326da99b818a70277c06fbd2d909 -S = 3da89b974fb03b26a5617a391b68413d62d03b7cf27daa0024e7b0085c1f542bd82adc66102c16c57c7765b1bee5ceae98ed54fd5fbddc1dc37a3a75f5695c49dc6f026213f79cbab37093a9549465370b7663f363a232c81ecb71074166bdaed7a558c5bdab0a20aa7f5c1eff0258eea42374ac3d4b386586fda7913305a602c33b6ef6dca0718fc330530e65f44d8824b4d1e137bcd3aaa9fbf0e4079cbb02a541971ce5a25d8aa91918576bdfb774ba70848db5b78331c71c26c0682b812d03197970e481689c39c56bf1bfb2d7f4c0d5c8bbbf5b3b6537f48572d5f79788362a0a7172f20308cbdc64f0dd9d0416bf09c608e915c070f4bb444e3b7ea492 -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 8603abf63e1dc6a957770c225394c0223874b3ccf069c315ee26a2761519d9e3d5fb0c0197a57f945b25d9369f11284f831b26412ce6bbe36618c2318db11042ad9bb27ae881770018e5af72b66d31d8fb7ea3d7440cf528bbb12f4834fc6d70550b27c7fa5cb6d7d7e0143d6051e4a5e5c6b2f602857bca36187021d2a3f756 -S = 27d202a060e759b168e451c6bda8a290ce96aa70eaad61e65a37962a766b851ad506cd68755341f4ce2858c24c27953fc8f85788fe77f90d17e7427f6e487ee4e41bf64773c79fc1472e89ef66f6cd532a1f485adb2cc3952a15e5b93eac7cb2585f03206733a142b8ba9465653e02843eb5c70ce8d7b59fb3b8cc2ae8d0405a714fd55638aca05b0bb3b5dca25dc7230eecac2c8fac049a0891e1b986308814486dc9d076b780b30f1c2a9b8292d2e3c56ab2980c3b3cf87292a300924c30bf2633f272deb8ada1149d3e347f930cb5a4c7db035352915b031f524ff07889e1abd54ab5ce572c63d0ed3ecbb522e7a4d087763cbb712eb44ff81ced4a9ccc3e -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 44935b571d8e202a7c257defda42c57a4cf3deeefa104f7fd31e9b7c7f73ce8c959b55380ffb12a9fbb4b0b373ca3413ce86d5f518180ebac081f1f791b0bec1e3ebb42813712701305ed3e9f7ce7086024587103c4f831098630b68030d8f94974d212f113a87b985ea8e975096a15b4ffa99464efbd70bc38c90d6bdd2698d -S = 64cfae08fc369c5dac6c08609300ad79ecc260f52cd9ab810d536f776aeb9158e8745474c76ee9119ad1d3780f0175bb48e239998e0580272417f9129fc778f5679d277102551387e23ea1b0602b6617bd323deffb2c894e24d6ff5de645efc49e9165a8cb3752dc59f81e0e205eda79da7dd64baa300743919969a1a3313c2e5b211d9bb3627cf6cca4f406481b95bceca64c733ba51a04bba15c7977bfab4a776009b82d152279bca00699c91d9bff0e1f78e3a81e52e2367c982a421cdddd7dacf0b888c36d7b9ffb3254f8140fb6aca60138f196b1c65690b40476a371ac2f62899d253e730d60bf62559fd4aa3196098a0ad53c98eed2a0476a4b51f264 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003041300d060960864801650304020205000430bbbab81643e08d7a9d84d488c6845a98389c05737c2c54103cbb497d3291a181a2ab6b4e5c376b90bae7af4405e178ddefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 69ec7262fa272d2512fe9281a0aeb2ceeb77a0692fad31618b0cff731a4cb43961f5859ee975fc952c6ffb0bb657fe19843ca07fb0e4614e501ea6e49b54011d4d60b3c84da06f588d4d61dc32086f32f6b6bf77ca8e79c1bf70ce1126793983f6d404c86fd30fd6fd3ecdde5feb8f7f088e0539c6d30124a1aa7fe206e2e3d2 -S = 3ea196268020d94c900f39ee2eca7e735e0cb478de58836b575628ef46c5e78898c2d76c7627fe36baf3eedf4d89c2572aa3afa8cb8c5ee3433e4c2ab7abe8369047d21cdcb00e1467ccd60cd2bbddbbccff5a7e0f1ed9d2d5fc4fb587d41ac538e66d9b559793e0fa8e44ea72e9c603d236f1c82c4ccf665a5337fb797b001ac0f4acfd90e54d147cb196f4169dfa0f72744bad275a748f4b402bb2cb2ca9adefb057a6400855483bb12c8e51909a7241f413ce7d84f42f8e4032acbb4a97848a0f2a3c473af3f6e218100b4d446616d55d55571c0fa9e178f502370008317456318115f8276aa1e569cf364efd5c7de9734eaa575802b0db421de6309c175f -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = ab5e706303ef34f4f855722eb521454bd886ea281c677ff935b40b3cfcf7bfebcc2a7cf62ccc95f0ae34d5081724c43cbfa126c93b02c5e63a4870b1adad446a2b802adf932fa127f3a6be93a8d770e2c79a09b4bcb8fa423142de4b3228bb528e0684068041e2028e5333b6b263d4a5b8199bd2e7b0a874e34d5ef1d28fac0a -S = 94c98efaf358dc0ac76b26f7f52b6a9c35bd8b63f9517a5b679af3cf3c48fc4ec99e5c75e7b1ef27a4dcd5443f6f4286d798cd96f746c63c290e501938196421d691faf84a5009e410545c407d920b14174e66da700b457b8a8e2e59c094e33ab1f0b3a5a954cf814da7587c95681d990ef86c4f67ef97f2ebfefa600c190a49ac88cf1c6bcc8423781117fc1686da1ed0032baa42d00fa62c38f5d3d27c355eca2f4b79b57b54b7f97c43df57b546f2391f5328ad295a16b1fb6d5eab36dcded973a7f34a0c600bf8008b96b70a3e8ce0d706d16dc2c1f298978c95d4823e406f433a48c6c98e41341704abb7860120db033591eab0674e1b2f998e58926111 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d0609608648016503040202050004306234baf47b7e2a2b38f44db0a1103dcea4fe9e2f3c6b951228d1b7bad3672f8bf772a915bc9bfc52d1e5c51165c50adc -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = d2c5b7edd8611a62e537db9331f5023e16d6ec150cc6e706d7c7fcbfff930c7281831fd5c4aff86ece57ed0db882f59a5fe403105d0592ca38a081fed84922873f538ee774f13b8cc09bd0521db4374aec69f4bae6dcb66455822c0b84c91a3474ffac2ad06f0a4423cd2c6a49d4f0d6242d6a1890937b5d9835a5f0ea5b1d01 -S = a524f38bc8b2104d55275efdcd8f1bf9d529d9565a757df8b3f8bfa067d5278721006eba463365945b81ab4a504122021f8234051847938ab3eca24f95e4aded34f9e57a7b377aa16fd9379d0b703accee4aa78a015d0986e20c4fdc950a579494c56eaef8b812e2bb0182b74da9f1c0e1e3b56142481d18e64fa797293fdbf7d8d54c44524fe6b957a06ccd292edf0e0353b96e047813662a7326c42c8bcd1d231c6a486699b756fd1c301b1891da6d51a3e5722cfa46592798e91d8df31cd98a3dd0b725391a4f9c6fa1ba312471f8d1d85519f8df7ba66244c5dc679a1348d2d415b8aa22b02a9322fd2469f9da475a8d832862e6a0cf24eee957eafc488d -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 302093a4a99ea31b8a693aac1743663b725aea8e19c1e35fb01dabb001a1fe5f413c5bfa9410add4d4272b598e617d9e4eb1203d1d890b5f4793931a62a28cfe8be8b1eaf36946249baffba95bc014c2294dc7d8982ce5899f09bdfc9c583e71988d5b1ccd90b433656b7246854672cf8a96a70a9391b9063fe5f2fcb8a95be1 -S = 2efe346135008623c56353482a684924e55455e5e75746707de371b9b14ffbaaf5b5f2ed85bd7e28ce4e1700af5014bbd315c32b872d567ea214af56e8c3276cebdb0f597a6bf2b0758ae2e5d1e2e9334a53f838c668bc9a1503010bc5cb97f6215847802827ce9f88cee4233cc80a1afca84cfcf7368e4518e157f05447586cfdb3ad9b2d79bba5a6c4f7494375472fb9075d61ff42c7816e23550f1643b758fa26f4377dff2034f5e68c5889665341d482bd4175a286022f8346ca925e925f574cc961146c4e2c3e8ba12e083a0ad31394357d099c973a9ccdd4a7a6649085fc1d4a377911be767bc9f96df50f991a9a589c5d5d19c3b3e8fcf7127b7e32ad -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 634de10919c2ebf47f5520cccd2aa37f484201b015fdab5c4ddeaabd548f8e6e6625a7d172a478ae2cc6691c5ef8bca57ea6c2a586b84ff3005d6bc360074acb97b77fa5e57a6c75ef33fdcb119c96cbf588498b656b4dbc5d1bab8d65d83bcc1d8bcf4e1a4bae92f02544a1901d1738d570fd29591c8dff8da2d3e1090b48b9 -S = 8e11eaac64a60172d6bde00aff7d654c61661c4e3213bd64b6141294b3d2491bfba0040ba09eb060a14a9c754b1b3dc74dd5e6de8185eb1cb71eae7464b1511d0b302864b34c08b041528807301c01b33a4630c74b1e6fe829518962c380de8b9094f4f90178313a7d2229a0fec1a798056b871a25778813cd70b35e713cc83816549f11717e3dd4a1412251c1082df1c03c0def3ddfdf3d7cf1b7654e5af94866392ad32330f45b7e9491a4d1cc2ad64a3b7ebaac075cb26d5115bf9a846dbc29faa8302a5f6337fa2ba07f9987ce1bc729e67fe2e8172bd44cc79ea15ced0cb49039ebc4749713343f136b7c32f5760d403568a4a6bee7fd697b82d9d44983 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = e532de1004ff3af1c5cfd5459c14e3c07acef7fd9f0d731fb0b143b90975cbeb542c1dce5a4a70121aa5cee6187d0c18f8baff7e4b76ed94a9bb4266008e84b12b2c8945c793e8ad4244ad123448515df371e99c62e29da709d15c036b8cce0693ba8a3cf1e48a0a6434db91987c99d592791b1f895a6ba0f87cf956f1789034 -S = 522fbeb9dda25bc573f9112a9f91c17edc93e2768e3500b4e2a4686c9548624900f28c878fa71336798cbe95dad6c3905ac04e4709defb972c13b6a532b0f827b86a8c809699ebcce39f38d71612ecfbd030d320d709edf5a0b7ac3f3ea49ccf8429066a679d4a9f42cf2e21bfb2616918fd80fbb7507bd301a6c650efa802cd4b139f02f65408090dde62bd825e04afc720ff8850461d5f1444bc49ef8f6f4f06e7aae64bc0f9ef3beba8298603aad62547ab8e94374cc45f7165e08c612408fe29ec242b2db649475dc2b76debb660433a2d2af7c4f82fac4b858f0b715e1048933d54bf2830f6373e6aa1ec2f460889c33b3ff78a2344f33929dac1c728b0 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003051300d060960864801650304020305000440ed1dda6011a1309b31409ff9a5f57605f8a6d33d91249b0c1e37bdeb6a580d334c89f5332a598379bb1f37127bc39366b275962c3bb9b888d6d576fe89f6ed37efefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = fcd993a231000dacf06ffd5d90ad238d5f67c86a9f61ea10ceb2995a2b31a1f7752b69c0f6571b48c00b05b537af40cfcf738f57173d899af7e5fb4635a5887b3ecb922524b15e8ae3ef721fe8cf42a0d4020c5f7d9101dd3516a597502b7822e023d67ac3f81c98e0850c42adf57327f57c082bd845980013ab60f681abbb14 -S = a05058b41fa7d48c6be9420c6372d559d466a85e174c272f7394cf3896e1b945ab8941462cde4042d1da2a8b4ef11b5de2c720595855190bd113d566d420b31d51cc87365a2b8d7be99e2ca792b94ecc5364cf63be7a16aaed3a723754d7491480829c0cc9fdc1791998f30ef80291aa756fcab57ff5f3e7fa2d6ab001c52e76efc8dc18f5d5fa2cc762ff863e9d6d1fd921376a8f20d4dfa61f0a4c389e42db2adb07d168d438d1ecaf8e4d62006a29d944b1b5e5172d99579bf03addced9aad16038997d2721f365629cc5b065f656bd306cd76a01cba35c806a476f47c7f9b50d211b90d882201bebac5204fcff51a28d7b95c12eafde637bc50a10a0312a -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 55268a860d34f9ac8071c4048c4d6b9e5475b9a89da448e178bc475122157b3828158444ce016206b21237a7adcc4ed7fa8b5d079a5f07d8f619a5d3c7a6465a339cf4de38133a534eb6e3e1481a03dd7c4e3cf723b33ab5030d80204bdb67bdbee463be1313897a9c844e1b27df929622e5dde10248e860e5c05fa0755be547 -S = 7150a5c72d046e51f58b5d2bc60886be8b5d95edd49ee011986915138b53dc6f1c20913513418fb9a5edfcf4a3a9e4c6302c5bff2227c81d447334c3faeafda5ab5ccf2f25da8217cb3acfc8778c22bcd1559180260a8d9a3df3b2e1c7f1696bde815b4ada1e44b50b500a0aa4b880ba68176aeefcf96db028383b124f5bc7b587c6c6a726e2af4cad35b85d25fc158fc44d34a5bba69fded3b37af8cab2c53233a6e363e153966e10d6c7606a23a51b9358bb964f49ea3f19af1c038c5a1dba87b68b5802fc75f8c68a5486479391e54e743ffb64c185286140db15fdaf51aa2c6173fcb3d60f736a460623dc351f035d546f75fa07aa496f65bd8e4a66913e -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 3babb27a2dfe4e88cc8c030cae74839c9dcb5ff5be29776bb3b2dfbb1f52596237ac9188002864684c470a7cee03ce84a85aab0d4dc8eba4513908dc549458d4f979c0e057063e879a5bc6a1dd8959f45d9d2c1fcf156169d351d038cd0246990d19954b04a24bcba380e52a38b2cbb9d5b9db1af3ac0df31a458bdf4a9e1bf6812b9c2469a8e384a96d1ba29bf009b8bd0bcb098f55523ff8e220ff2aadb50cfcc2eb927e9357b51c5001123a46016c47bb7a8ade6c62b5cae190a3c89b7993d130e279f0571643f039940c5e0e6c212f39bc20d014217ee8065090eb249237873bb3d05a2ce846d58134a4ef435eed617e4435e044471f86686db1572d6531 -Msg = 587e0c53dc96138e7a0d05f8bb10e6d7d8cac64a87e538e7154e06a2b53923f01866e12d3da2643b8b90576d1da9dda35d82cbb6d44d141640a385b1e781b2172c9030dc60a9043eda985c084a207db74a40fdda36b532bf3ec0ea4bb9295c2abc845f29ecb3dadf90ac7c93eb7dad5ac88dc48056247a29362d9e38d33b0b70 -S = 40f0315cfa6e8180e68c9f409917bf35f6feee875faaca6f63d41caf57ba81f1994e4781bea5476f58feae8681229546e0b0ad4f6965e08b8c4b5915a7ae72430c18e556c9ccabf9b2adc9f4a188bed3b70982ff3561290e90cee779fe0c0a98da503f700815b9720126b1c6764103df4e05aeb81adcd11792e38ff4f072b5f403e458459e2e40e453bafe96773c489a3b55ce8f3a2dac7b5fcfbcbae53d6b27fa9acce6c3d9da72c355e11e8f56290f75fb53bd41bd0fb822662d218c6e6b8148c5a058bc2a8855e00d7d432db7ec3207be1f106cd1497a55c46607989fc295426b2f06bd7bc4da7ed40604efff01f037450abc3a1e0a657793e782f8a2389d -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d060960864801650304020305000440f7868e28e7d36a3691e196c831ce747400ae162cc2850af22ee47105eda53fe7b8826b1599e66035a13e247406b04b27b4336859fa666279991b18ae997466c0 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -n = 93397894e668653afab24bf55c15071960a81157e680444891c42ac0cebf9ff99e3739e12d0223d62ea048e77ee284582a707050fd11258f27fb6a4e2b583ab37ed0799708e3379e41b191092b2f4631c974dfe81993c740f21bbd0d828ad398893aa33101f445e5ff02ca498b8a851100e8d50aa2fe4c88ee38be966222657f943f9bed73f018a4fd371d208c362cb2aa4d1cec9c68f8416ef00ded34f4a1ee4d59a8ff4c5b3deb33c504542dfbd772ac649c8313644a32205a602cb5581819e4f4a2b8150e63e20669690429a4b5cc77577295183ff6b760a1b5fb989f158107860751c7808c54c1c511d3057b5e9537e009576b723dc9073c0b03f28955e7 - -p = cd819c9501262da3cf149709f0f56e59c2783263e399819dff248ac9e674c5d1e281e2f6471aff294b6e1db918d1d52f20bd4777b1175440c9b40da42b1c6a0cb28e404ee6446d19cdf7559304a693400d94e826eb90772fec7835cec7009be5e6b09ee7052d0b8ed413eec628d4ba9ea2dba3e53fb6fb7491eb3ce3bb16e88d - -q = b765ec141594c3a8503df7bd3e31264a88bf76ada5d529ef0969724a991787e8630cf8ee8c223fb9894c98679235139a5424e778e72309f7ff60fd5766d3edf0aa21f82d13c1ccd9d75d7799917b7abaf05c1f2dac240dd0bf3c1af0d1f5600bf46e93da91bb36a7031436e305b427af5a090b484a2c0a397d89f92c5d9c9d43 - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 16ae604b3a4e9c7f1d616e2deab96b6207705b9a8f87468503cdd20a3c02cc8da43d046da68b5ed163d926a5a714a4df1b8ef007bca408f68b9e20de86d6398ad81df5e74d5aaac40874b5d6787211ff88e128cf1676e84ca7f51aee5951efee1915dcc11502a8df74fac4c8451dda49b631a8fb87470f0ebe9b67449bbd1640 -S = 3a0751f873595e6c75cfe668304ce23e37da8f2412bef538256db7333562cd7b7457506912e176b8af543d5e01eb9742c8a42d356453a9d2ea9b78d6774144e3237e8fb3c0822c16a5550cc8dfb52af497df73d30643b4a8abe07c8e04cb165909e030faffa2429089ab6ca3d88584a0669e4955334ad5c7d41bc5efcb901f7cafe0e31552da57833d595fcf955247545cd057781d58f27c9c1a835f19f40deed90628de42de3b3efa4ad1a7311e67ee3354f6234e7aace3d39751a84611ff53d3ba70a552a78c74094c84cd401eab240aa33bf9c1492d1e173750f7505966ce83fcaae886102cd139f827386ff3898e7a1fcdde095cd96165a11b47ad5a43ca -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a050004140010617ed97007b337d2736ef686b8bc4f438f2c -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = b3d09ef22d893ef3cc09eaa9b2777e982a84341ceaa00d45956f73e484761ce6c61b31e165ccb0edeb7e0fb5255922ce27b13e4790399f8110730740276ba8032fa544919c5493d583cce5eb593a087bfe936c46f9ca85fe0646715bce93db6bf5581f2a5989ae5299ddb574d583f948b5110542adbd88657fcff95c01567cc7 -S = 859c4b66e9843f82baf341875b80215e16acedea013b10511a993b8407d72bd5dd00589d4016dde5b082f8cb0fee5f339d3e4167ba2399269e215afca6ec2c1ec3d572e214f9513086d281a4ccb5890d75bab00eb4bccc44074de6fef0e8c21237f7630557374da6779889016709aec7fe8c2999d14cfdd9a617bf858c941674737cf0723f146759e4aa691f4bad8af3296027f92fbb81476587f76759592cdc389a34d06d2bdab0bc87742e0013a11b571b58cc4990828d374268995b34d7eb8c09928efe0204cc349c83f575ff70ff3d4ffc9026561ce0601f17c8cdc945a59b44d8323a8c3dcded6158e880c7e1a214c2d3554e814a0b9c64f35724261452 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a0500041486b684bc197e2f935d2cbe5ddcc6f94830a4ce21efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = f41491a2448f0abab25b9f4958b6eb93343282e62dae1d2e5485f7c369057685a1230e2ba66c63d8e03fadeff33a612989f20ee551e784bf48b73c633791f4a47ced9ac80e7a6b26bc585cf4b588b95a4da10ccafec44094add106b52fdb78f00cdafc2183a06ccdce0f74fda7883b4d0aa645403d2d98d60e3d1d615ccc4a94 -S = 81007a0eaaab1b6205fb5579a55d50a7d7b4bb077eb0cdad18756b4bddc447cc6f1a427cfa32100cf5c0c00db6d28c371059e6341d947d843722ae8fcd0c81a4650fb96857ca5d09a270cbec62a2fcbf997b67fbae0763a5cc28f526c452b416f25fdca7bbaa82c966e7be2a5b0866da58b05e024439f15428b0815117efb9c08310e193e7e7a5f2371f7c2c2edd17616a7fb991c2e173b7fd80ae4537d38ed647c32dd16129e56600d32418575c608f360368b750faac157a3a43ff665a5ed5c545e07f413e9475e7d79d542356358f0c554cc206c3880406447308d1e0d1871d90a84ee4a43152488acbbeb7bf55fadaf3e8b32e01a363ca8e3935efda1e43 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 7cf8f94a517da2e5f856e8ddec29ab25a1a3b1faaf0eeb193326f92e7228ef8fc02d5a2aa1b67ebd2d88e245b9ba0fb8b30c94f6ce7a4dfd5f11e55d07029aed93f540bb209f8949839783f6e86562bab8dc8016c1aba24b912e7dcb228a79edbdf8b4e418614af2c22cd4d9c0542e9379bd7e42cfc8716a8f25c85e0be814f8 -S = 636d180a954780e947e916eabfcd4cfce80dc0cba1cae58342e142207fee42f3f6655ffb6c78f89fe1d2f31ed54e991d14b814583e8c84723263a22734acadfb5bf00dcd6df8bda4ebb3927a36b13bca2991094f1f92610dcaf953b33a4d1cf571085e297e3cca697e4aec953ab2134e23e62d176ade623e3e2efa562e7e0a87fb7ddc3a169325cd01fee10b2f6ed2012b9c9db99089521d2d15a15da86fcb165501eaf454bb36c8798e0476f59bf2a7d5eb395228744e266198032de0afe58cb10f81dadf57dfad47f764721e54f1248c00f98d7fd2fbbc5aa0998b8a480a73df7c2eff9940bbf644cc821ffa9bf570f2b24c43570b81c103cb4d0c39deb507 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 7ff7ba5d5e8aa7de3ffc560672a9c1b0f2eee1c39a8d7fb89553475617f81ec04a46b5b28c7d5e08d7f71f80800805c02528bb9be1545b90c1b184937c73ad115efdb92e8649cb51518b5be216118a52146eb25ca8d7428bc4cdc9fd9cfd5066a264ed57b5b695c1950132b59b8df56da708ee9059dfdab284ef3c1adf5dafc9 -S = 55fd6153dfbdd9850218c3b48a4f5e74e9aea999b7e0bf0514481f29b9491d62a4a4dbae2fbaea27cd4dea5ddfc17052d3598bc329eb3ec437d1001387510d7d0288cfe298cc5fd9f7b91c887d41d81d6685853285d67e874467c036d52be31ee49bfcaaee129a3cda168b59ffe523ef64f7e972cbda2afedf1a0fe7c6d457d79d9a73b7424fe6ec4290988dd81daa58e1fed69ddec52f8482a27da34b70114cd07f04591c5d2a38eefba0abd33d4c1f500a4073eafc5199548d7b96c772cac71cc02e18fa998f143132bcfa5e44f2dd62692c90e9a96b243ee20310fa9fff790b04a2d8811b46c5c97e66dbd5e36b03aa290cb9ae27ba94018e61430eac223f -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA1 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 3b9ffc79b59b069fb97124a6c13d51ad413638c1e8e09dab2383f90be4db64aba111b80d9feaf446703fde0fbbaded1a3b8d65a20a26c44620225d17163f43f0304768069b4206bff3ea3ec8095f0062e21c2afc032af407eb938b06e21afce4f129548b320b05b24a5b8cf633bd512d3fcccff75953f4958ebfcbffcdd45830 -S = 7f2efdaf79621804a71b9fda74328b00a65d949b26f739e1b9755ac860c5ad7bf63453a572fc54d6ec790230ac91a150ec428c252f2f8e222625b3e3e65e5abe5155b55da30fc2a89e22101f15a841058ccadfcaddb5405738d86fbbc85d82062dc988a945fb2afb9a9c4d52494f0cfad39f120577931632c31a63f06a370d1150aa4a45441bb31ccab8f7f742f5419a14a302ee0c558de496c66002a02266154ddf2b5808e33b920493e5db1719c9e6f7f43a069455024364988ad622d8d61a5b798a5f9849cf29a0d59eff8459ca65dfd0ea1a9381e8f595ff72d59bd86eb04afe1c4b61c239a746eb102effa940c011321dec7675d99ec4d03261ac254602 -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 16ae604b3a4e9c7f1d616e2deab96b6207705b9a8f87468503cdd20a3c02cc8da43d046da68b5ed163d926a5a714a4df1b8ef007bca408f68b9e20de86d6398ad81df5e74d5aaac40874b5d6787211ff88e128cf1676e84ca7f51aee5951efee1915dcc11502a8df74fac4c8451dda49b631a8fb87470f0ebe9b67449bbd1640 -S = 13c5d85a48e10871542ca7b6c7f7fcc0f86da6e9cca9fb9b8f36f30fdf2f320b61b73ca1ef0b9c07af8e675f32b7a648ca109885c006971e821f09a489d1f8b79dd2d03a20b5d9c02f0117bba86ce8b419c67b90093d89f2631dbd38387a847b9490ebbfd7b6818f70e09c3ac25223ce2199030df51bb5da8242d1dd2396c72062a60f481c73a830c109e74b9fad92d7a9a414643ccb2e392afd13a8deab2b4433b0ff5eb3c01892c71a00a3e2d1173506b6340f57ad27e54a4bc5e16d50de2ed519f300f2afff9bc2a39e42c70a0fb02123db01500bb79dceda3a33b915ba095fc1269542832386a19b3ef65f56d8bf64ee4c83d5411bd0b6f097a749556917 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041c35674247cb0e952ef2d28bf3e3c63c34d0ea8b3f194941d3678440aa -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = a9db46f44d85c4414d15a62541906e6ae498c06e2336191174d6bdd16993f13485b56b674e780724a310bbd850e9cd06e03343e6b39e9c535062bde4fb832e588b538637763824b62eaf20dbb09181e35996b1e1fc172ea7331881e9f28574a062bc80adec4c85bf93fcbe768810f3c9f8c7f0a5292837d6c5fef22b76222bd5 -S = 0ac7106eefb290dc2681c447fae564aad0e73028927907b323a7e1c340efa53638349d3ff6f9bd393431f085c84bd5a447a82ac98cbe6100eca7becaefb20fcbdf3c13cf883538e39a7c47c92e0a0da716bf520835156c02ad30d357115e467f9fa1b869ed1e6e1736402c2df62276cc766a0916ccebd7854f0b6f14e88de01164491ca82ed831e6e2f45b636b4ac73a3a0e0522cb47ba1758dce66ffe9e6afcd09ee6820bea67ff7351a157aade87d7243e68d3a14824b07c0a831260fd4b21020ad943ab0aceabf2fd259a038d30f786ce3a60c6fa68a5d7b1901380b19912a7eb61da8a224b9f0d2109bd161de1d3892d1001cdda4fec492bfd1fb0050039 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041c062e999e48e75ccabd60ec5e67bdede1b8beb5c89c5b8455d638b0f5efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 659bd5f2edf90ba229a140bceb69036750477ef4f4ba4a646565882ad8fd2d321b669d21cb197cdfc7c9c053e4460b6de3a1396aa09134538b1510c75c5b54fb03e195ffdeda4a432fd3db59cd96fbfc1a4f385234edd06e70cbc719049036d20354e6138f041dd64a07b8580d217a1ddd98a4341a96c6bcfacfd4a736637cbe -S = 8742d7f61cd01a1cda403f08a9f367dd2f62895531634920eba3de112e3e5dc30752533851ffdba2bb48905d3532e2a55572ddeeade4dea7f80664b243f951282ca678194d6b91a9fdbaee763b01823ca4037d77cb3aef976a90bcaf195431b3856c3b598bd2c0e9000970e49d0938b3492b6c710ee898fc719b40d0b5cd98a54de06cea29584361317f4d8adcb23b982479513289c4729ad5b39fedb2ba6a6cb83fff0c2dc35d8997b9bc0d8bbe45857ffe3da67655cffac7c89e33257bb08ce3d10610b53cde7d8b31d721ea34fde8f798cf91a866bc0a52a9aa03e24454e0ab27f7cc00219072b3cebd9883ed1fe5dd02d4b59536488931d5c6059794da49 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 25c6f8cff7a49f5c0b7c1f02e3d4b8935c26cd768f33e79dfa9bfdb6dbabf3a6dd766033f62794009095dabfe718faa2b29c021205f346a47670a6497fb10fc523bc4562d44edfe5956f93c15c4ab38bba3cf8aebd2b7f60161911d477f8a7b13fc02dc459c087f16131d2700911ec36bc2f36b0818298b721bec6c18c29c254 -S = 44e33dc3011088c96cf066e4a3b93487d86779cc770c43e7a7b5d6b722cd582ce8988a28605a4961645d9bfcf60b68a83d8a5f2a85dd07f358715fdcabcea43c2816ac12771e76e54c14fe3073e1eb43312cd0e2fa0c93f07b0c215220c59379121aba72fc7e13702d9152386f6554b12b0323cb42d09ac5ad5f065fe6b045e37812a55cc6132a6a9dce1a7928a974e3e35213719b3175f96ef87dfb1cb84a67bcdd5f5b15fe2508bb6815809404e0e6b1d88da4d7202feffbfbd76010279fcd4f6fc233b27a934601c4e3701fd00eab581fde1d2aee3e27ae9b7b627e208d013fd0590c3718731c19f105258acdfd10fc8c542982e6d86b7c275372b8112fc4 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = cdb5d9071fa3a040095d41253a6a8081200ed6f4aa095b455181eaf9593c7f255412e380e9a28cbcd345be172c40f72dec3e8a10adfd8a9ab147e9022524e1aea74e934807e5ef144a64d381f5d477fe883f080e4868939f41b925988c7d31b1ce4f318701d290f077a3c88b1b8cc89cfbfb981703b23ffb0bbfe5e115af35d5 -S = 1dd48357b45763f1bea1c5a7b0f346ca8aa1ab19b163e05c78128e5f9625a22a7b3b1d8c18763349089725fe41f7431bcd42b965ae6f7dd00ae046f7fd2161d344b471dee5ff1d9fd4d5c520a6facc3bfbd8650598b34ea6c94d684b0187a2437c529e4d6408852662fe70c807c1270427b02db59f04b8df01a087f3ea9e3c80894763de195fe7f92dea8c70a3bb85864e410a4e8313a836e47fcf5050090742fbb1eb64703d5d599fab43930bf4b8a916c134f4984993e2723c4a5814265c500da5caf709143899c5a5d8eb199479aa0cf68366b7e80ff21d1352bd2bac2bb2c63a8235a379b3fb3baaa416243eed20c2c861e4924b71de1a74bfc96a85ad74 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 14690026e93115e009238306861b8968408c9f320614b61afe54c1de47fe74eedc2f4c65bc00cf3e485815c5ec04874b0109e71ef23891b99e040037fe91930e080d91f9d3436c36fb6d42f2474aa9028971acd3c6e511a497e9def2cf161b345eaad8c97623722fec0d1375e01878f3a06df738ca42c044b1ac63f802b592ca -S = 0356405c184af63e2f550081e8dd7dc7138bdcbc44d22e6225bb4babec42983f0556989ebb8bd6df4fda3b1a3d4abf2659a584ec0790379c74c7bf156d14531939aaf920fb9959d5e7cd0d2fa4f86c8029e6271522faf29499d50bfdf1b20e68de2fe4a52a84db86a39491e0e599935c3b726f6b7b876e8bbc633d05ccbb3aecbb9d1e419bd2bde528f6a7ca6ab4c9f8638a67d9aeef1491af6c5fb1c29f76a68e981bccad09d3eccdbb2fe5d44a9bb23a10f9a0fd594173b126fcf145ac2a3420e78b6b195ca4630aa2a48fd62192f21c34e8885187489eef8c79a67aa079fd8d2811a5d41b73a1cf78133424943b3414dd183d8ad242158e3c3c956185a153 -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 266a05f02ee6137da278d709b7504bf55978e432c215c5aa4cea34db831d4ac57f3eee07718504457b5be1ccc51c0279cd1cfed7fee8ba8785cedce5609f82e8b7b3334a702e16e9fe82616e7935152cf4e5e94b0b898325bbf9eef077b1499e77d1bc015469b133d2f44035fc22ead677db8bd610808a4c97745345f0db07ae -S = 598ea4dc537da91b6e9593fcb39d89f28fbda380f1b42858666b6569d40688929ced67f6df07eb58bd984fcf51a72b863649603b6e3be9f99cae28015959ba7d64fa4c0f188f849774760074d46131a5b78b712d50266feb110ab034b62bd67b38bff88eb5f04cc174c8c9e2d8f8daf6c33038a1a10088698fa09b6c397db2da169468fbe2eed851ae1265cfc05f19642d8d6ada114f4ff065e6b7b132d3cc498ed23ed4317a3d0f5c5462c9afd7dd196faede84f5f8e40b3bc8913797f1e23ebb3aebcfb23749207c95685ecf0e3f164291c1fc9087a49c88fca0b4736c7c86fe1a159b6b34dfd30cc626ef4c458f712f4a879a730e8fd6b2e075cd02b96011 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 58718b3ba6a4ddcaa7d3f7bd46cbca5591f95d87741fb852c74b004f8c0ae38a71d937909ddcddc9a8d3ec08eb490b61fb0e1f3b70e827a5eb8663ee57b5bc6f6ed760ac7f90ad9c6fc25044ffbcae8b4cae83499c60c8a15724db91540adac756524fb6d72713ea048a6c98088c797a8dc0d0d980f065ec150fae600c6f0438 -S = 29c5a0ab72d0219034ce32ed330a4b388573eb804713d98029fbc1da87a474eca1f1814dd61e26c7bed630f3a4f980734321d56fb3309c751953a4dd9110c293730829bfdc83cabf619b220818e30151c38e6bb9d304eb7204029f8af86209275b1b5fb84bdb12aeaf3013db78d6dc1bcbc23fbe3dd7eb3c3bec332c8453de3ddd2e39cadf7e062f00a682bf18ab68ed3c6bddaa9dada51c99117eceaf6f8179eb9a59e6143a56d5f26d4138a5c31e49104c5982cb1b202253a292786cdb94a2b383c9d96afaf83d52160eccbc42cf2568744999a662097b315ded7fb417a823e3e9b6c5f7a822bd58a4e5542fbdfba63f60266c0b86a363153ae0444e0ee1a5 -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 35524c5781983f729374b6342099239157485a64b9cffd112b50386849c3afcdfe3eb5965174bfb5827d189756d5d64cafa60ce75f4a41283e0b21587b2e73752f314b8f38508172444e61852c71a4f284cfa00770c8bbddb8d425371f7fc7acf1b17609dc336df1006ffac6497777cdfd497c8c91525377c130accce0bc92bc -S = 77fa540194591f2d49a7740936cc5c909e73e970fc833bd8031dbcfcf78599095bc8d185cdf681c4855c4e4527a75c5552ab3611fa7788c424c3b051d1236fb1bc3e7b65421cbb1982ae623fbd65210035c78032476df3d64c8e8136c74c47b694a881479608568368fae8d7374d32173240e55e074e4a064f6309df823269f2a2477a5bd06c819b67d9c5f0a8720af431c3edcc85a1b2cac7d2288d90b446b62cb070d1cbb87234ec41c55b89318bd852aeb60779246ffd84532d08ea27e27347c7997e7007da4680f4b7872ab89499a1b0381c4837893fd0ca055bf1f0fc4b1682044190d40e7cd4b6c077faa077d27cf5a9966e95d6acd89f1dd1a61a8a4a -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d060960864801650304020105000420b7cc7185c6cff2f0237380831075de8079252edb588ab3a492e600abe24dbb7eefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 31dce7cc7c03a063b9879e0343e9b6461db1992333a941bfe34a8f86bc74327b8662cacc82dc4daaf3aeaa57dc5aad810c0a23ce58c83eb828f13b9b35e7410c90078d6de7dbccbe0490c8b696aa471334f6302e9fc0f0d247471c4e116e58c958b477d63266e449f4144048f8414ca59d5e0a6b90fa1fb64a337cc8da703d5a -S = 8be14c18fba2b95cd0d0fed4b171462b07db0b5e5edf5803b595182e97ac814eb929be28d18a8f45f837ce537475fab819244788681676ef73930ac28062082b6a593072b2218862a80439a1b9e2c637ef9806463c7c3120a01473ffd9df2152d871b83d782baf6512af6979ba3a9b8d68828716539c771161b81bdd056f7535e2cc654489c90ee5c1366609c775c760cac8d084ee6d618d25a70ef64fa631c0c4caea75296d97237da8c977e711374620f232e71163d2a2515d71e30985f84a3d4839f4367a2d273f0477bc677dc830302ac423364f4628d7cba5b92d5c9f37de4268f8d957905072f2cbb7249dad4f55909e41e4edce618535c7cf62001f52 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d0609608648016503040201050004207f3ac72d5591ed16096abd35813dc29dfaa0b834e2b57e45315b3731b4d7292f -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 2656ef08c07fc1ec469aa9c73b677af225a9f5f6f8d0e150d1d65e71e6677609bd44f5859de97ad6436ecf75d5ab76a41c9f84f6ed13b311e87ab2b3661cbff3ac7378ca65d5eed14f54fc4c34e3d7681cbae5c1c1fbd3274395e2a21d6881b358ab21ddfe8b4564d215d8553e56c4c68dc1c05f5ad1691a48ef9546f495e4d2 -S = 849d23a7f9dfd0956315dc9a60c04dac1d7db660c67d2ea57db40098a84d258b111457686821134dcde66990015e769311aa53e1920bacbf59d214beb3fb79cd6482601f5ac3848f90ebe864428d0854a245c1a51f40b10899cc08fc4dcaa6b322fbedaa7b56db804009a0829fea827065ff655c1f82497c5d59998c8a577bd5e170b4734b7a24f574db4ac56fd7cf96039c594e9a109c10185e69102e27105533d826d50b5c39bd964d88ccd2e0a467a668ce15a84014c958723ce6c09230bcfdded9839ef40bb5f80ec2073081e5e6565454270937b8cff537c0b065a923d173ad04a31592fe699e2424d8bf6bb0b947ff161a33b9b03fd69892a0d9a8c711 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 1c58bd7408d1d2ecbab294bd48408178d4a95be7ca3c89e963d8bb7c6ea5cd1c4f03ee4c48c00172f78e43e720b42e4fad039e26f30c339c3790f6a371383f464f86d63c7d0c58bd24dcdc94b13fd776d7aa3d92d7ede969ffae3fe07016109325cabd6d311da0764884a7eb814a42945a848052fd4875f8c21ade5bf4a708ad -S = 60dfbc77059709311bfa31a69dc9db4703d0fc44d715598afc39331e2620d73423f2cb8026c3dd9a133a7c0a62174448128934c776616f1f9bf12c3936f52340d4f034725a759cda95a743602805f0fd7bb03a8d6fba9947d1692f6e7615ae3b89f4251542f5c902f41661f443101da8a666654c86d3cd8aa93733d677d6c4e83b527def0db12bdad93feb76e9bf986a1624834de5febd2b0a970db189c878bd99d3ae86decfd0842735361bfb1fb0cf548a9bd43411b4be4b8db8db1a585555d9fc5066bbdc081ade816777cbd29723062ca7709429331bb52a2e5967948d1d6aafe979a9e12cbd20a30937bd6965d1a04e3060f72a46fd3af1127dac637a24 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 47611125ef346ddab85ba9493e92eb1566bad85e9d17f99664bb63900b4297dabcc0a74dbcf89ae2eecf12c899002cb36a10a876bd854ad418537f93f89744d3d187449e50a940c0e344b4d97b15b8b0914224ca6794f73c90e0fabdb2c6a0ff8b9e314032b0271c9fa3d9a56e3956b5e039948323acca75d34b1a35c0397307 -S = 2fa1aed1f8b9656c8216c2ea8ba98c67a6d52cc143816c7f83b5f72e572d6953c28249593bb01332ede6b991ada2ea1004e594966f1aeb2fff14db6ae311bdcf439c8c949de248d7870b0f9f3edfa11705de95b552d3a0bd86fb52476981df2cde1df65de3ad7b957fd82b7f98d8c6bbd4b7e2b65e143c627f5e4d2cb871326ced2f904947ec2250c5ff9d330a74a480afd38277909d4d040781947302ebfa6ecd229d93b5261eeb237dc99b9060749bfeb189f99e0164ce36cb0b64935e52870fdc8cef93a0e198465f48d7ffd87c9bd1b40a127f0fca14d559ceecade77d30486cab930ba50a3358269f641ca11ccb30d3fd21becdb50efb778eb10d424b76 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = af84a31d1c08faade967cbb5a016837fb2d1c0bc5eea5b75d4e2a6449b36f2c3307b5545f0adaac437c5d81bca89587572a8f106ea06c6f9fb5593a9e6e5341302bd678ca6ead2af4917489ae85e485aa95ec6a3bd8e2ec48ad0a7db0a4a95456e71615908667c566786a199c43d5b149d1ac8fb9f299cc0c97d6842cf0c1d42 -S = 014773de1e3486a2d54c7a0a0a1a70caf61ce94868902314462c2bfd9c640de7b499578230a41734a1822cd0fde610c487c1dad10e35d70136cb162d79c403c7408cba33b72fcafbee2dffad251ecb6bd4b082aa5350b194c587b8bb1ededc902df1e2e6eb03a5744c87ee49e087759237ea133c8484d62cf142344b56cf3c5e1f72998c531129f66e0458bfd4e8b1de1866e76e3912f680bbf8a96ee4f2971e6fcf029788e0dd586db744a7f9a0010a2a27d98b3b04884cf269f19f1937e8612cfc5b144b7aaf9b2fb0464a26f4013de9fd12851c3f8c9bf1fe6926fe512e0543114cbf9bd86336d7d2aa6c2a696a3fd071467784c2cd8f64e8bcb00fcbc792 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d0609608648016503040202050004300c4887ee786dff1356756432824889c71e522ca5d478d9cba311b11a51dae49696d1f1f454ce4017e74d9f45cb17b797 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 5c95cabba94825969c306fef29fdeb104955f9e7fdc63aa29000f57d1d41b9d85210448d732ea480a2ca9c785df4492d485405a22d1c8cb4413b5ef3a9d464b23ceed55a8b6d5b041e41724601dd114c80ea8d2b2e3dba732c075303a74c9c22a39745cbf7eb924799fcb9021c9f8c977780572d08130c06d9cd9d552193aa50 -S = 019962ad704a78fce2306273ff3a649fe973dcf2dcd6d0e692a592f357c9ac459a15b0bb0ff986f104f99301c87579a321b0d4ab9e947a9de47b56c0094e4ffa6a8949594348e342f8eda30e68f5005bbf72cef70c522a124eeab1d7441cd65dff7e1ad36bca0534c09c284e8e931766406b43b62db89472c2514c3d1a6911a92e19a0dc923919daeaeec53746f487e06afedfcb679b531ede784d9d6072dad50348e1d8f01094f29cf5cc96f6c1f40ab455be6c98788e9d7615ddb6a66b893913ad0cc63a72b9dd357ce086b2df7c8a106c0c363e3e2317e37815df69b22a9d52d6e5e47d8be17ba61b2b2019a0f85fae30e1d4f2622be50086848cb405d578 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 7f88a5d6178889bcf09ab7407a01bad132cfa7456ca0fc294f88ce56214a24c5c5cb9ea581c65aaa05c017a7a93f9b5ff737539969c53a72731ffbf7c4cc5af3ca10d00674ab75f73bc3244b631ed9177e945d1233c426ee3d0778e9b6a2d19f96408422779fa44c9b8923542f063ba0d1d00dda51078946b4268d537f365170 -S = 91584aee68fc0d4e7d24afcf4eade5fea0ffedc4d49d1d75e673029bb998ad170ee5d1d28a2779c846e617b8c9783119f4af4602461434a24c1351f737ae315868a78f615019234606a12e3fdc3cbb05d2f0cfc877b344fbecec5f71f0202b507df23e4a3917cdfbd1691fc69c509598e2bd7c71ac39a71a295ae0ed1531b97dbc6666ecdb830917f04cae848f8b18b8abf191091b07632e1632ff611432b7a50c0a7654d59506ac3b4c058eb16bb66174a39f933a4c389cc86c9c124a3246402928a3e3fcc8d35a817027c2c2448b792f2009548516642d75839b61c6e2d5b63c4ee4c0cd72e559be3cf0e466a4a566681b66b71089f67c1044157d78215e0f -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 97e7bb62b6d35c8e423a4c98de8264c14eacb2b12f36cc76e54064cad6ef1d94d60f9db2e1fce4f610c2dc6ec68331e92a1962b6dbfd19afdf67b877dcb734ff8a14264f68531f83ae1a3c138345fb5871884d4c1656ed921c02efb66b259cb59c3f7dc0b1a1b63d048a960f7e906b1709419bfa480bf0258559340febfffebe -S = 6010444309201677f71890ce09e31f671208b2804c309a85a401b275eeb5d234ffe5fc6dad17fd9781cb00ccccd1d1260c2d7090652add1b635633170ef5e9eec6ab240c382a3850fe0947892870d0424bfbedd434db4084ba29cbe7c8a27b4aa858b648fb0c7096db4dfbaed09fbd7483a2e9d8c409f87c9a2a26984137000cbe451140da9bc56c4382a091bcb171c3da5f9833fd224a429353439469a39033f2e1ea20283c643eec651952ac9853ac15a8a8751ce72a443b41e17e41fb86e69ec0620660f65361035441700652619c9248b2ebe5cd83c00bd2b232c13b544b470334d7314704dde6c81150e54e9ce132a5aaa3ac03a931113160e93814e968 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003041300d0609608648016503040202050004307c1b2374e40835303155d969bca1d02f901e2569823d83b1b8ef0221cf4af285fb3535d60dcafc85b0b856d7bb9229a5efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = f167b1c5e4e480c6d96035630415b83c9b2d137a2ecd6efa37523eaff2dbb9416e078dfae400d1e349b83c2a1f7295c790856a5fbd5c056954c29c8f605cc85766773802ad05a7b5dde10bd6cc5b10b994f0c47ce959942fa9c87738b56e69f600401ba5e5fbe982be650c2fb2d61158cef8899757cb03955fec377397168468 -S = 6e2cef82eca498f7f1bb521fca7f11b31f1e80f5d1face48609d78b2ba79b8e82c6800e92d419c4c48b7bdbc6c41cc2b9fcbd05627c1f4c567629929022baa4ea1b431f361b08afedec6eff545b682b8d9a6b18bf62f34a1596048f5455f51d5496c89eec6e7f8431ee271ae84658347df2d1a52a5acc37b0b5eb1438342da02f2dfe44e50877221a8623b1d1602339223748df48cea785f94c5ee719e95ebb2ab7d795dbf53d4055be0591e203c6ef69d6b08aff07be7e546f501e42c3192115b5f2c259c4ab2dc585cf37dd3ff54e89f0607c5e3a2f198e2875a7550bdffd0eaecb44adad438b3d0ea810668eabb123baa66843d1a136b0369332bf74d91ba -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = e946af251dd8b043a9c866cb4f5e4b65e5a983b4587203e4f16ef982d7b76891d67d13da5ef99d83cfa3eee3f3a5d995cc8ffbcb914ce6e5f3557f43a424a4571aec12fe918786104fb023352b7214fb50e072263f07684813219591090cb1e73ffa7439bc69b311b156cd69fead45c0f805b06d6a8ad232da3a04140d55d86a -S = 839d586ce12b7c22bc2e0d921d11756a9a65e8275f61307b1bf1d6e350ac126a50c52363f561e2d2f8edf3f92b9fd88af138178ee34fdc3f4d288bb142dae2e5378c50754da25eb541dd80e83f63a356c760e8efa03f07efc420109bae6c701fad5b8dc8fb266e2ce1cfa7b71f04f63c692e4b0aece6b970baa77914791e8a25e5100a2205811da238a451f5a100355b28abd39964d43dc0e2b51a8e2ddba0e94d02ef11a5cb2058acf3f98dfeb34cf939b5bb0525eebb17bb25e517fe3eb3e04e04afa892f318618cb66de38503bcf994c9d2ec20effa04d68a0df7c76dddf30e88e1fdf5afdcb2dca0e124946e7f39248633b03166027611deb276bcf2c0ed -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = c41b35fc1669b8663a14b3c37c87f27c2d1b7a539b3b1da341c74be93ab52b84fcfeeab942b854fa4a7fa168411a9196fc5cbb90e847211c4478093f8dbf08033a0d6078aa938cf95b2818b05cebb65d052a8f52e583d7c2fc49a43c2a2a0073e80e3c40364188ead4d5c1a4b5428a57b1509ea27a376520d104c5e9fa3e3a5b -S = 2ce448ee7ebf21be380247cc3f8472e440f3911128025fef0adaac37d4dc977bc5f81224dde9df193907c17fbd624ddb51c2b54c214af57520d3f69d12885e3b47cb2c005c18eac82b86d5d514cefc99794badd609cd5cb8775cf685ec1ddf6acc0272a4a58311c348381bc24c4b85626993a601ae292b13c3e8a9c0262fb8deac28320810e776c196454be73d5ad08f780ef45dfaf7704435f2b3141ef32c2d7ecb1f26398a0dd8c01c39367987f22600b07979627b391276d1c444ec87e430769fe22ec3e1d5cd4df358314282d10e2a4098b6658ffa44c4135142c2661f2a80d4d380b5ad3d2727d0ce12f1e6d67af797c3480100ea50a0fdb0bd1cb2a78e -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = c069fe30bbe18aed9d39d26f4ebcbd89a9f18f07982822e5795372bfc7176089f623af809ec15360dcaaebd8f61f8c3b3d35c0783871ce4cfe943cb6e4b893ac589c620c0d3d85d559a6a797db080628600d7699076aa968a4b4adf76374b63dae7d1ebc507daab3dad30f9445a0b5b8da21ba524f3c3aa23358ce6b8c7252a6 -S = 5e67fa94c7e19b66548220ef4e07769ff75d4e76917004492334f0fa15ffb8b14271301c170e3d325811bdfc1dc53f1b4369a2c0a99d261d9de59a73efd4ecedade05da9faccaf35d462057bb8bbbe29e3f5d4c383908c0b25006f779399064889441a84e0ce569eb474ddfb83cda6be253743693bbd551f6ac0b8cfad225d5635972d4e508ae5f7846ee3adb61958ef53146af42d0c6ce32559f661a3c3a14068b8b488f85d7e5641e250bfd9975653ad86f93ba5e5f57f5799ec135d9af7c529e6447ac43b114475060150e98ce86df3f69cabfd5a59158f0f8c4043935e0fee317901baf27aab76a2cc1561d969bb3d69de65885bfec00a522c5010fd2ae1 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = d99885b2fd968ed1385f0245a8ec086dbf33cd903c4a1c205ad0303b4789c677d74876df7a1242396c80708b2b6595dd2eb1f33fd495040e9be8577492ca9b2e1187fa92a7bea8d054c2bb78f8403d3c0c227ff890b4b1ef4405b0571b911f19ed1cb9d26ce1e51d59ec8b14f8c52714c14e1cc158ee4a4abfefe2efcb2579c0 -S = 0efe5b7647f3b6bdc7e9d161afe8591fd21c818276311c4a04a3922e7da47c9ca87bdb8d2d8b8eb267a335ada64db1f19cc35c6b9bdb06589233a834f106db34b75284f943e7426edf57b63d3c23032fcef1cc871530ed003b3a62d994caf8c4c10a90528af67824f5e5267b2eb284c4310706aefe248d3a2d98e922c859be49b71c0278f537fea1586ad9658da5c59ba11b6abaf2433500be32c862796de6aa58fe7955fa51845fb4e304adec80941f70e27ec24f1c6bafe0f2746fa102040f2483ba7e3043469c6138adaf8fe50b4274d9548b30ad0bb048af103454afad3e536c2d95ae24fb2feb08ac0f469551edcb3fa36ca078a469c001d5637cbb1bd4 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003051300d06096086480165030402030500044065183a0ec842001ad183a8b55e9118f29757c477ffd30f57dce02a218238e0a400d6a509c69a74dd64b400c809026e9e3ad8930f550b594be664491b5732f3afefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = ae898f661a8614a533fbbae90eb5e9810ca4a205b9327845f4d3dc7f51de9ed5bb9bb1fd5e9d2f3bc4529c8c3dd86f248512ce1ba1fc9a640a3babfe0df95d6e72ef4b6c5cc35add7095fa0139d5a8eecb57b73da7a95103dfa4b9037b41d2211aaee51adda19f7380ed59afca539dc5289ae5d195e1a50abc358cf4615f07d7 -S = 0ffd86aabb2861142ad2833b1b74cbffd660755d58081f816f28639bd6cd70b6d312d6722f14e4d608b154891eee96ffab837e472286c528086fb323ade633cf1b778427b504701bca01c1a8cb18547cdc3af6afd180a65042c072c741525346be008dd2dddb53d63dc7b33458bc59fd50b35bdc291a2760ac545c4fd21a37b710050fcff970271ab9ef51fc5953fad7bbd28e9d4f84d27c36711afb3ef2e21d55a3f5cb028667c10b23a334ed7e7275b6830588f4938f2c3b9ff795029c5c9eb3965bcd784ed3bb5a119d165db4ed808d388423059ffb091fcdbb1e6e5c65291b1e5fea5bd17e2c5f16be05c3d13bc8249b7f98720b300479b0a25d680cf3f0 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d0609608648016503040203050004406c4c610edabaa9eebb437d9c62286c4f159bb471247b77f443153bea722f2a86de52a83f4c9561ae581f8b3568bf9977ad8696ca8f310ccecd598238b3edf845 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 18899418d11166347f1db7538f58d6843ac6ad8ea66ab60c184b5c7577ca9aa99a5e89a587805b4e5d1ab6d13fd06b640712bd62d4d830ed315491b7b1e409c89522beee817b33efb59d982c31dd365da1937aa6aeedf68ad3049f82406c78996c3470882afe0ba6552b21b6ec97162d8026ce2c707fb76c27b41fc3bb05bb95028eade0ba33868ecfa617b98f829957ba83934f2dd4621e111058241e3c0e08abf7222f142faa81652c625deb28d2718940679869dc51fee3e0e38830914aaf6c0b670a04815c5265836f4e9895c6a2e99111e0156c92f3c8d23b89fff18442876678c2b2c40c5a7c6f7cb1a3d314b689d48f06faed34047ea1237df9a3a2af -Msg = 0c84d0c19e69926823ae89727d7dc8f27e2dd6a8fe0c60dd2b5c2a8f219b4bcebb089a66a86264bec1f3600099cde47a56545845c0fcec24985486ae2b44feb027928ecdacab8467a6a13ac35b7048674085f8c71181fb21203a5aa6ee02afdaf82d943dd3cd5c2b7bc00101e9ed5e81e3ca9e781822f59d6c158ebd9160c415 -S = 5af917efcb50475ef7d9b555885d07cb1f38149cd8f0102760298131cb6737f5d085f2762682f98c5e5e9918d9ab5ee4eb6e94989bff59af8ea042d0225d71690bbb770ffebc0610afccadb9726c9fba0ad7c716a0712fc4ac4e14ae7c21adca56d7349e68440b3244ac4afae225e7d70b68b4bc80fa9ca6a0b5665ffd831acd05403d8050c35d95caee2d6ad1eb53523a531e87efcae11cd225a102578f8ba6fb4b907f22b9515eba4449e145b9301619d5445723537c16b8543f524f37301989026d0b4829dbc5386fff11b74e54be9f8203f2a2cb16a2181f1a8767f1f161f650f7559da91578b999a34a2eab985aa96231b7200ccc6f38c2a621ab6b190d -SaltVal = 00 -Result = F (3 - Signature changed ) - -[mod = 3072] - -n = f33d3234f13272c3b2b6821ce4805663ff2e8b0d2a47de363d97fc9cc879cc6b40f9e53aea695dc538a0d2b558498829aac327eacbcd889e172b34f90745c5d528b7e82605f1a58fd228ec7fd4b6f476f393864f48dc47097c8a780a2ecc02f748138dbd7df99c52d822a2e5154c6047fb0eeb4f49da38edcae3c32d3fde435f291f96cad1e09e1030ad7efb4944b69e074d0d7964becb3cb86238d8d293bef3030d141d14868bc21fa133e9de1115f749991cf86ef506e663ac162b2c8567ff131a6b467a6f564d6c588860becbd88970354198ecdd4f1f4baee8f8bdaf7255835385f5673625f113550b123628a0be3994d91c3a19a82e5d73448dabf684ee6794fba7a2b1afbee0287e5a11180c29ce0896795d52ac7f408fe28e8e9116fe0b61a1083f95c5227d62d5537b5040b79e21b3a8e83c225bf3efebb2f808541e97d28a2468359fc60f588e74faad611262064628a25d8d61f9d03d8b21cca515595aaf2343a759b74a6a8afeffca139a389aa281995cd18e16a9cf7b7ff0dddb - -p = f3fcc6aae575312778d9e896acfd7c1aa4c5524f20453e8bab255363164afa7124b2425587a077fa0bfaf61b12ef3f0540dc4c9e777122a60610a53d1d75b0a5859c654a8ddfc2ff4860758bf5a6f264bf8bc2baa7551eb7be23bc06978be992fc81d890e07a3abf95d20eee3f6bbbc089985cac96395b473b2741c66bd2ccbef228432f66b906c15b19694dd786c29f06cbc17b2e6400dde4e3db85819382b3d05a4c3009f092d40d05ed5b2e0428a214e15a7aca09b47120b9ea6cb4084fcd -q = ff36fcdc519fe10c69aa0dde2cf3bc72cf2ce9a54ac063d809b523f4e5d7ddaa5413d500dc21f409ce661bf33018b748fba3966d874bf96f4313eafea9decfba71d540ae0508161a3658c4762d94ebb3a4e228c45661315db30c20fbd9e20e24c044e4f0b49e6ec80949b16e0ab07f3d32b248b39f48332cc3686df05d29c170a7276acdd129259aaf018ae3afb49b6e0ddb9e404a492863daee7be71dfb11279047794e45f399a9665796d32d5e65956a13a6fbe992b36bf4c842f5f519ac47 - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 9d1f17aab0ce96c4d83405d1e3baba1dffa86ecccee7f1c1b80b1bbf859106ce2b647ae1e4a6a9b584ae1dfc0a4deebb755638f1d95dcc79b1be263177e2a05c72bde545d09ba726f41d9547117e876af81bfc672e33c71442eb05675d9552df1b313d1f9934f9ddd08955fa21d6edf23000a277f6f149591299a0a96032861e -S = cbb358cb77cb2f130b7ad636fe7ab00d1964ebd5da22bef0139a6265a15c6638b17ef3d84a588710adc06d0242085f155bf5349064dac7481ed79d62b3ed60121f010729b61bee45554bfd5d494afc55405fcc1ab8eedc9c6251d2d0512ccf2e4f370dfc523215a09553ed2b7a46e8bb0e63d1ef0b09664b42c35e303e2fc3e2142e53a0a11569f8dcd56d47542618e3f3aae3790e1f531240b52b0a89f2a24f018116e513e876c8079f3ea61210da71e481ab89934385319de3275c0d9fc9ab33ed8bed5f704ad40ceb364f21855a5f5cb1e1d2b580ee4724fdf61f308d7136160127247d4db3486170cd2183047f15c8cb54368085f595f6bcff02675d6945a1d9741768820bed442fb03d5087e793b62d3d0d37567020475268c8786a5e5385970728cebd6c027aac15240ace0f0beb6c29f656f6b3f3d458d20005e41aef294de9823722893021d9cb621b29c2730cda7b6703e3a66edac57019b8404eaf8483edf91478f294f88907e277bcff47fdce9ab7f772ec256122530ed8bc3b48 -SaltVal = 00 -Result = P - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = b33acd11fefde3f71597af02e49e821354a0bed0080b31a44a4aa1064531a8ff749bc3e65a51a56f742ed1e46c8167b18fb33e26812a34792f6cc20a0688d4eb63b2d7a04a2d13235a6e3b2c007e42aeeca071a5c134b70f11db403888dc483b67c632c63457d41db09d16620a5bbb1352ae7ed430f0616fd6dd421933f4aff7 -S = b1f3ee7bf9b57da11da3a557d311e0d00e474578d3d798ade0626105191f6db1d8d66da0a35259e40ff746d9c512478d8972cde6bf271f679ba2f8e49444002ba7f94b65ba9250bb5710587c9ea0ebf31802abb7508a785405f8ba7e0753ae1b95675d4a89227a93a96f3f273fdc3aa7fe48b94e48dec9ab2fefbbbec394a84305b0237232394c21cf31ae14e5b938e825be9ef35605d0200b9c085cab040833623e72fac9f59a2297e17cca08d3a0e11cecb5b35b3b86238a48be38c6c03f7e45d7c5495d55aab57bdf8edd871aa9caef624466b09721ac7d27a74f5ccb3645bf0690d0396fb56e424b716df6bd9e10becf9b7b10210266d0ebac4cded6510b02528ba2d3b5318b7e8f43462dda97b523b6f7355896cfd8989f8d9dac98e1f98f125d60a5d382513426565f3b1d1f305c59b2b7f659c41fb796aa6936e4e845c4ebfb14bb62b2883edb1580e68d52d62e0143410f5a5d2e8f7a2d82107b2ffcaa64dbdd32bff2d3228ae115cd86a27a3292ff43d165b174e7d77f6dd73402c6 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 7020d49c0b19cb515b193fdd410abfa3638fb66e2cf29208145e2608214e4debad45d1666bc08bfba568cbcbc78dfaab21d07d79e91fddb17fe7253bf5848c87cffd54dc07eef2ed55c56faead310e6508d82f04674973b6153121b82dd1c96a5daf27a6e98c4950f397f42ef9e045fa9f0f94b6af569d405ea4e226d11c4bbb -S = e4ce05162810343296c8c774a21000f647973dd43615237b9f753c522d32aa6ce6742fa8c9b702b0a074ef8adbd17008226e7718c4c94255b01d7870cd5cfa3aadcb309612a7b0661ce1af202f7df92885a0f70886b8edec606b1923534c75f3cda19b156a2c90f6c412d33e2e0045b6a78aaa2fa991bf61417ce8f2c74a50aff9cdbcbeabab3e404799a8091e5ae1637933272b082d8abe7305173b0ebb619e4dc1dfc77015861c073e24de4dfc28e0fd95edf45cf540d7ecca1bd30cef47fb5e398c16e7f7e41ab35c932235464a91b3eafaecb1de97708a35c39730e58a39a2af7ac71959ece442e00d42e7c1f2885c49e5b799bec3d9735e1cdc85a4c3ea58b50524a51552f230525c834c705c1f1252f85433e42043d10bd5ceb42f8213d8e9db29924cdcd127f97778e75c1626b9fb68d6f0baac56d4cc30d0c03d80ac2f92b8ce2e15a7500b0710ffadc94c54a67a9b27c5531880a60491bfec5c78a7febed2c9b3e5c45474e156ad09e966e18f9f74ad2d60710c63e6ef36ffd478b8 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a05000414a695cf2db3cc4089154364865e1f75073a39e420 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 856d1fe7642047ed19e96d364e5a2efa2c85a1041fb33b09dd59f038a4479b12c223a07c5b16d01367c58dbffa832e8bc8c4a5b4e8d55effd8cb6b50c2badf79fd277750d7bf80049249f4b1acd9e7316446213679df0d95355ad2e5aa0dbf493c61ec8a5f831e69a25cec33edc4209506f260b25a370e73fbed6c1ee5aa042b -S = 24b57099a2e8840bdcdb4461260aecd17534f76d074c765b9944bcddf9b31572c1494b586d0da7f93e7d25fcae44804562dd13ad676b61e70d19fec98cf6dd2eb917faff448e29b951a77b1017a8650d0061bd77742e04a44c79bec6ce141bd264824b6e553a3f761bf583e231f2152cac58f71dc7198e675e364103012aae9b45a3d1a7d61cc25cadcf7d061bf36a10599a812ec279a996a486d46984ff3c10bdd6a465b93eb1796639e499d865f38b4de2b14301d01a359f36017ace359ad1e3c8c223ed74b00c6a113288e64a9c610f5f06d537edb11f520bb4eeefd055cb3560fd8b4d56311c5546b07ba1f3fd0d3e105f3da24f3bae8ed44fbeb6512fb66cf155e3e61475436b95f196f452e612aa9890cdb48938b29b624094e36f651bd305700b39176273b54ec9abb996e644be39496d8b88aa26dc5d4bafc343b9850c0201e44fac6c1ac69c4e408ad5769bf58fae1b8a88c160c0d193a2c807375a4550c4cf56c947a9afd9498fc220a469affedecda22bf44a8f6f9bafcd913948 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 590c04975accb7dda8c07afb60a7dec74d2ab36751b787c1068c6933a412f384266d871ba851d86f1417acbffd10e103cb19ae22196f2c655bc5152cc494cbe067b39c289c274460a53cb34791d511f76100001b6acd215cfa61d91c3e4655676305cb26fcf70396a45817f9e49d778c57072fb80b796d8c2b873d6bdbcf9802 -S = 8913d37eb20039be9bf34df63a3824f13f20324a3c2c2e7adc705f418c77d9be7f127e406d765501663b551e4482a177f58273483b51b3bb4614054ccca4a157eb6f4224b6c0b6e4e2b92d11b87fffb26237544c959125d2047165fc8dcc2d5766b6dd7d79abc37b79ea7bef2169e80e74237f5574494eff54b15f4ec7a5eed2e982a3b8d76b64801a37d888b079ac680b0833b51c2bb8a168c63cfb0a96a8817d8512fa4812eb457c1ed8ce0d563ea021a34e644e70689595a078ef469dea58a334207c6930a5ccd82307311ec25cc56807f2a9160b5d738acb42925acfbd4206bd92a24946e2a3fd8e04a1226e472be33eaaa5eed4c13eabca68ecef4d9c005b2f132eb827872235217622284833e339303162d866133a007e27e88af86b23c451a846eb393e05af713a59a929edd2943e6cff60aa906459c667595154747156c52c39bd369751a7a7f926bfb7e42bda447faa314a7593dfa4a06bc334ad9e52339917fc65598f06ff61ee6d7854325d40284e12505af8c57b857887f15d29 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = bbadf4bac5fa0abe2abf1e9993d33b798c5f7476dae4d6bb0e809be75a6da0b3a4ca1ad4d99e8423841adcfb9f1e0ee2a8ffb16cf888f15d513ecc0eb6e882127f4f4618ac433a137ade9a99340d37894c4b28f1aab0bc2f442bb356ef0cadd374c5e250e7f114d83495c23cfba69fb69ecc42cd98661f7810ceb686adde0a3d -S = 257d8b3a2fb7ca6d0a78adf2b6e11dc4865c63888422d0795773249865d18519033508be2811d797d564687827eed35cc4c24bddc548e7be68a14cea7e8e0a3a6ef801df2d41519dbc056fdf5cb23dc60a9b8e94581a8beda4f4e660f699ba5a649bd5724a1d48f88552c3129bd08e2ac8b0ef60ecb938d4039a2fdc648b6afadd04683b40f144e474b8a99b3a81fdc623391eaba2111dc5aa812e3fc6b9c8f8711e9986c0c2f012cc1a0120c79004eae424dc4c90f24c8f52d536dbb50a101ff04498887eab4d2bc76902c2587a3b32ef3a8a58c3cbd11a9dd14055da56e7ba011bae74875fa631a0dfa524fe396b6a5ba1b92730adf17b2e9bed78cde226ffbbbfe29d3add1c61262c0ac9624f1feec48aa73de41627514bebaf76997b0350ea4d590c6cb59252c9d693020e7887bebd7a25f1769433d39fcd3dd46625208be410d50ae16b4d8fa6554be3d94a848ffc3211a915453b45a3328b001a5b605d686129a4cf4862b5e3453ebc42c2a11fe180adf5c12d50d361128abb1555aba5 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a050004149a135a3d21fc0556fdd6fa7ab0a3b1e4ff330f9fefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = cb4029c463e243b9f901855447fa2af302441ee117a3622a359fb3ae8b356675d3cc97428f6b826b922831e7c3e458a91e357d2cfba45b5093198964c0935784041cf925cdfde7eef72e83ca9310fc3be75e73f1b5615d9bc16429fd8d68224267199694a50038eb30f9c3223fe8e05065a84a55ce4430b3c66adba07a1c9059 -S = 3f5e4b911aa319cfc15e4d6f7ee82b12a7bf827dfd244a5e57a52bfeb04bdb9e29a1cebdc4ebb2139906c42a5ea92a6737495d35d43ddeea1786420e57d994d880625f0c4f56594f80a732b549c65132355d56c8e7acc857344fc736a7b3168e8e892921c12c0cf8ae7a5d66a9d95d4180b1684ce3866024eeed217fe3d386380aab1530513aba18703fed501984820d8bb050229daf0467fdf13020094be24d8fa8cafb8a6774861b4a2a0e32373989fba555141d7113804b635c0ce480818ab755c87be02aecbd69754f68c3fea89dc854996a05fbd3d5f10cc7083f893297c63dc384a6376fcffc8cfb170ac7e0363489832e0c3e9b0400d928e05411408b7b12b653a1e4aaee79ee46fe892cc64fa21afa202c763b161b7d4f1c32e7bfc75442f1a3c31aede44374939b64c264f9b1833fe04172ccf818108f74634384bcf0208492fd81a77282a27987a9001754fc74690a021880b7f2324e65a084d88c3f4486fd974d50edf6c206ed616ed9376f1855a13b51c914c48b3bb0cce759de -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 58a1db581148b3b2a3f3c967d69d3feae7df5a327e122103dfb4276e640ca59b2b11cbc60c895888ce6e69589a958e51af92233658d6deb31b1aa4e53401a11d42f897e13f617634b5f22e182f57c150ee1f9c6aded527fdc96d9b30c9e3147b031ee7b2921a353fc246c0ae7f2bfe700d4f6cd8f959256a4f75b3550dfa253e -S = 3b93e9611a492f19acd725d92cddbe696e97f29c5612d7a1c57b7cfeb7c70bae57cb9c75b6c611bb1ba39e48dc99ba9ebc091d7ecb5124bee1596541ee337746c86c6280a2db0f434e13735148d39db23e594ceaacb36bc29fe005ba204bca2d90cdb083e9972b227aecc588f601427c8977ace25580481db532f580cfcd54f56169fc2f31cd00f22834cd4ee3c6d9c5f708a9d26e10e341771ce65ee4233184506a17f891cbb633fc4571d7dfcacb949523f692fd44f08cadfce02b6fc54bc156a684c9a706742d5b2d33f45b01001e777ff13f3b485c5da6778526e1f80bae0a812d80cb2bbe2fcab984754b3ae9532e24e9c930ecedf50cb554ad345655e25ad118f40e9c729efc53c67f8c9e533ed434d57c92ee71fa809aadc3c6c82aa4bfde5df4b1a32d43981b9019c04ab9b32129158d302f780c22cb47249a1f767861730c4702b8f599b594aafa691d423bab81e8de32ce7a6e988839a55a94c198c8b10e432ba10567e8a01d264a9f2964016ba1f070592abf8f1eaf25f5c06f39 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = ad65063815129120fbc5875461c916131cf2d47084800e5270475cbe620d7959fe345228c1995d9befbb2ccacd2042fe11f4257397f4b55c558abb289139c504513c32a1146a8937bf5d0fcadad398acfc549d4384168f0c8a1d6be016a68f768fc6cc2a764fbcfc54f355dcf0acbf25c65b6367b5af4569f848936e571c7eb8 -S = 2f264e0f5c24603eda9315230f23de193fe6ccece8de2d6b0ec8ead9803798b7c66b9ef0ba801b029c86bbb35a743031f5ceaf19881948cf8e2dfb52a4c7353de5844863a8a6ce407a0c88dde7f76f76b8a548930f902c974462299a9065a2a9c90b639bf017f77cb699b2c255bd18999757ab616b39cca6cdbdcf176a0057620c88bf0727133b3c5607ea13a454b45ed8d29178ea182f54329921677f7ad9b01ec3b0dac78dd82319f5b04d9e64da052fa5b193c32806a3dc6182d2bd2cfbd7741130b5d6d32ccebf48183d8b552186bbc8f6f6ddbcfeb3ac86579794bbdd51d9b231d4520b7aca40379570861f09338185e120850e989b9f708fecdae37c95507a46eef059bf7cec22a8728d03cdc7a758e85ed2c7d78b61caca723a4daa85bc6acb5e72c59fe1ab459e9d181aa2c3b0a8019f510156d76b0712678019980f2377d1ad7f126fb81762090a394a172513de39d388bc52903725f20d476724774ab0debb48e33fd03c7b48765cf91270245b42416b504c97c335400e36367c06 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041c1600b15747d006f8765132be06c17817a701f2b805bf6476a1dd5582efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 0484eae59ee761e0cd361909a014b9bc1260356bdeb74440933a1503e9913d3f5630f5a0ddd882a02761f462d4b813de1324973f70cd9789ee7e447f56aad7c4ceadc840ad5541c58ea1d2f3a4c866594d7d76dce9727c5dec1bab9632b4dd459385cd8db86586992c7d1b82b64e9973e7f63a0befaedb02b598b01026b8370a -S = 74e96c2236f61bffc5830647a50f32a09b5170c586d38b83506c91f6337bed6aee942710a9288e17f8e9fa3e48ca99c23c8dec0f963f8a28c0a55db3d05fac86a67039a6c0be46d28207be9ec12e389bcea525386d4a0500d64a3d2b846cac4c5f9db7fe8a226e54e28e6524145680e8aec1b5d5f531e7cc5595e3f9973bf1b682574ba48bd42d55b240d2c9b6929b4a8fe8eb6493a2a7aea700c81dd8126c4f5cf2676adebfaf8641257d4281945ec771cdb4e45601ca20a19083e0844b8ecaba048ecfd2d76c24324f368f7c20563524271cbf5aa4239ac6259a3eef2c80e5f78ad3c7bddf786a090d7ac2f0b7e0fb5851c5017f9bb84001261038f79cad754d183662cef7676caa122fd0fb763944dd89de28f06fd40ad4721a02618b1a0e20056e265c8a2629fb57df29646df0ba56e94682bf3eba253a08fac1925d39561090d8f36c3b5068b26484e134cefaa7613898fb12c4a93122b7224771745ff115d4f70eef1e47c0a656ccec2d0afc46ed9d0fd5b29d151d23f59723d3818f1b -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 469ce940f2675abe473f931292c7fb141eb1d11ab62fcb1065aafdcb80b7fd9ae647451e871dd85c2386291154443845cfcbfe23e7b00b08535e6eda300bd59b4aeaf53e97a22cb90400655b74e83d60069264c397f345538978e909c2fa1899f7efc2472add9efc71151199fa9d518b4c6ecaa0cfdfc1188f6237003d6e10bb -S = bb0257ed939f61ba105b2381a70acae35915a625a5728e29287bf0b1928e7c8a82d6b7ca4c1d35c6dc22b2c44895202f147390da4a1d3e64f416c03ced1f2523d586cf3b36046fb221efe1375fcc2d2ec9f1c0ed979e901573b2184385098a0fe27d9263ed6054410a3230f02b6258af4f183e82a4fe13597b5c805ad22536552b222c065627d4bdb929718bbfbc21cbd8e7d688a350ca2d36ed325c737af93df4993a9cc3be1d718cb092f48efcfdf21eb419de0666e3bad14abb09ec86890dd925c54b228b8efd5f491a5d52bbf508f15bd83e912569aeebdf9b570485df348e2cbc42395674aa69f3aeaf0c9573a27098253fb36f913b332f90466b18e2e78d8c504cf0eb835b5373e2113969f935b710013ba340292be2be396256d6c6559621fe96c1fab4b92e0908f71396b8dd2096ff1f2edf1ac6a31cb3b405e0ffd7c41b8edd1de01910cce15461176e4d2706665fab3cc1c9fa4e810e15b59d64e9a46588e0629d8cb16d60bebefdcfe58cd87c37c0e8497004bc42e29f024db067 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 207fe949bf4eb76dec39e361e5153fc593b59d2d10607c306681e8bc9aa19bace993689d51eedafd53c11864f8810b281246c32cc43717f844438c0fe013797c3f3c68afeab8be870a979fb074f20c2fe2214e3b832d984fb788e87d13fc2e05ace2b0269294ad349a2540eb614f88038dac06045629465c46b9c2af3c46036e -S = 7fb366be277c3653fec8f65d741808e0e1676da31ea5388d2a87ff65d7e9dc032086be8b0f64642b937a8e0e563ab44b91e79003bd92713768b6caba087c973b351a340f3cafef865c6631da91e2eb55d9ebebd5d71c094ee8be88c43caa7c1f6a698070594d76d5b036ecdfbf0f7a9f680b56e6012230b1b91171d9fad3b8dc3c4ab88949acf036968169b9efd622cb52f485a2ed1bb6f65ed848761a67da1f67278a04891f663ce4bbab7f691b0ad1b8b4873e9bb4875d5627d581c262882f16d2c5f56e8614346934311408954b77f407272badffd3c2fadcb8a8a43441d612f6ba1d4ffbc00fdbf7fcc5ca0c9002c43f47f145ff0ffabb8c5760d4abdb6eaa01487555ff1ae4ffc632473a25831815f8e37b60cde1c85a537de9a75b5189fd5cdca65284165ee8d03082924feeea8cbeb72a1d5480fd2be13c4732f2f98ab7ffbb085c8f6c796993dc10b4c1187f32ecf2bb8bf592c3ae117be68a30e8c92d094e674a514fe9665643befd8e2c545a14e1b9f565eab37c3d913e18da9652 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041c49c8f2542bf9c2bfd41d90d2ec3c717718ba9a1636f5ad048011cea9 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = dbbd09ff7b1c707c2bd52014adbb773ceb146aa72637c8724f5ac39fb5a5acc4e18bfe04be599e3ffe0f6186b870cfd2565527f5ae46a3d06f4bfcc7bf00317222e885959e03c6531da3d59e127b63f25ff9f94377d63b34bfeb6d893b4636df667da49a61427120503885450205bb05d0a9e879c70e1a0409df1dce709e4473 -S = 2e4d98c10e126e544d2b74bbcf0a4f03f081d4725a6661c0683d3612b01ddb2dd6f0391ef3679f39dc0785b37ac275f0d6841ed3a44ff7f6a407a085129a164faf63ff2aaed18ec6a5f7d27b48d017a50b24c8c4859ad2bb680ace5f3af57f2eac2d7337c0dd7403ffb2e8bac69dfdc98e62a07354b2fc93d03e499ee2d126647edaba094196b693e98cb98ad2817ba3f7f522c8f786b6ef82632ef5a00d5d4f42db6d26709909ca751aa8174037c924628852ce78e2829493d6c741d3558adcf713734697754e55e7b3bea0d8717da8aba2b2874527a0b3a8d2e1433344dd6bbaee1ebc7fa352539d94c6b45f915c6979b8e18be8934d28d770806c6ff893660dffd0e948a8cce11ac870507f88c1f86caa875ad721326dcb4f0d5ecc2d2538c4fabcc6c756ce4a59bcdafc44568787cf2bd9650486da8c85fd0b87794547e179e498cb6a5b26f71f9987d703f2d53418411c1f9a3a2e6705637b7bbda9660641c0eb037eb432b2d7515d1ffa99175cfdb8a2a4eed013b947faa4bf1c3cbd59 -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 4255d5da3223d2f6e33c43abecea1ea7926f7052eb96a203438efb73bef867723f3f77d88928a8bfa4aae8ef83ff569ae3fb4a4a769d951741e40a1d42e33d2d57188ac35bfa593892d1a13947caab78b34b19a12184269050472fc11919730851891782f1c06dcb745a75718174a4a9ca06e5413474ded6385f744789c19169 -S = 6fb009ed4d66f18ae694d6e383196b02f4d82a1c7a755ec4989af1e2f7381355a5cb0bd7b51e48de878c74c9a2b359deecc55ffe4e67c8de5666f7a23144a7a67cdfb0a62d0135d4f58c07fe467f044c1ed33afee03eec57f8a0f83b451f145f1eb598d3997b67d98b5d05a6b28d74eca249af0129ee680b9055704d803f32ce93d77fdd0455f5002fab33b30bdc0c8bccfc6834c9a260168b366ffa6f0421324b673d7e697cb266a09e03afb0ac6fe89495852a6e90d6e132b54eb0b899bfd3d9b4b84bd4ef4b4566beaf2884acd26a27c0241f820d6612fc8fe9c5f4810c6a6a32c924a7b532b63bea39c535aea33d50eb388d5efb7bdaab3864830c225c642353228cdf3e0edafe39bb7d9d9bf8143285b18ad2c941ffaa67bf4d91f94ee1abdc9e5ec6f141ea0df5a27490c51d0b75e5ba470c9e02f071063f89f7bc221170f8b67203ee6997029d53848868b8ed144651071b14eb96da6e2cdb9b9f6183f548d500270a20bb1cb2e12c4a43c5bdb3fb97b36ec02617248242e5a59dd7e7 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 3a463bbff446f2b5057c50da18fcebff0f2c5be7e91e4144e91d88e2f486ea233cdab6ab1b10d15c4130fb85121d54564ab21f98e311c59b38381d6f6ad6ea56035ca67ad9567edc36fc9d8d3504ad206fbb9b5fd7549b3de3806d0ced3fdef0d8f59194f6c0ff1b2909bd5a4959fe44c66e58a58f8fcb14321cff224469cdd8 -S = 26502431034a0f2baeaf1cb7d8fa138b32d53f808d6183270dbcb24267c71564377a6d470ec42a02a7e88711c8c1e46a8b3868d15ac81146ad6c9ce9c40a1b09c8bada5020cc52d3ac2452a1b81c4ed0052a79c6e5cc275a032a816698e5f39004a340c13e52e9d672abaf2f5e230dd9f5a40eb250e8743a46414961d347a8828d5c1eb290fbad7eff81c7204bf377b9d9f4f8a2067cba6a6b7a088491cf42eaa8b201b5d8b37033d6db81454faea89417d52dc4b50ed920ad1e863f083e1f6dba595661adfea362d0e7c8b10a55fc58a1202fd222b4354c320dfa1e466e49625bc0c80dd620ba3cc2027ada7177ce44483f5dc8caadb3ff7d812524835f402e0d691e0be9bbac2bdd0dc6881e85b0ef46962b8441c89f7eb2a2d14bde8d2ff933dcc0db390f225f2322544bb95b34c2c2e59e6823f56c048508be7a3011a3130983185b47305477b19f3c701ff3009342c19dc22bea62b4bd2ed221ae9c2213b3026a576f8e25d72f9c72468e61b6cfd9530ccc1c183e101df9aa3228e8ce3a -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d060960864801650304020105000420d65f865a519cd429cc9d221cdce15d51363697e694b2cd6c09987f0310b5e8d8efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 631b9db77357d87e004b61ebda972db826db2b9f03c913136d7f5e2f601395ec406fcf96785f768162e849f867dca77667ab0a195a7cd253387c44e31776d20393a59ce373c638578a70aeccdaa8c78100b188f4cc21f99a2f3a2bd25a76781c24640d86acb3a668408c99517e261641b994ad199fe1104f185e1be6713b119e -S = b3fc32b58ff28bdb60d7080dbd90e369d5b6ac8567f9953a3155e42ad86f671134b77d5f00cf1b686708da2dbcafd637b0e1c9dca59ee74b1bbdc339aac119661a2a1f3f837271a67c5788bf309f77752c4d62ddddbec71bf7b066acfd08b96d840cf4aec4c52eff42bb85038d78d668466458dc7d69621206ee831726f28e49a8a389789d39733abd67fa334c4ea1a39081bd1c086dea0a091e8eecb06d413799f88711084310c30cc824fc8f48d0a3ebdf481123a30a5535ef0c8649ff42746441bcdf3a7ffc23cc13c5aa75b2fd8a413b0cfe1388cf724cc105c182615902f91caacdc7617e349a553738d5a329445c710787cb08b87332a91ef8fa1ecc4f86a7c56d6ddbeb3397d2f92d2f325d29fefce33954a6620e3bee73411f11a152418c5cb6f37e0305530bf510589f2918204584a9126a3372fd7f915070bdba48e54c596d8693a9d18f848bd5a53982e8c8c33fcb3959ccf4a56d3b942917673aaa9246a5baff5f5aeca056287cebd950968308d535b1a62a5aed92d95d9d6c2c -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 50af2bdc908dfa76ea44c19958ba61f2deaf29e663434a30bfb98acc157a3c14635d6f2a57256695654c482f16ff193ea369e9e1c2344baec04d0999d0e81617a3c5c48438b137c2f64f1a24f818908aa8a16ecd8f1ca75d6b22082882b025be376f93b3db385745c5d79f3fa50fb01e15df207171044586e9bfed42d4d84f51 -S = 6b3f7aa014e45d369cf4cbfa86fd284af19ceaa355a00f55bf242f02094135e899529b0c64538ec409b60b6c9666f8dcc61fd6060c990954f8200cf6a477e8a114633fd8c9a62c0e8d1d171ccb5e09d360d42d868edc0bc0750338da5ab69f53ebd8f9ee99c55d9e1cf6bc9e9a8d10db7cc267adf5e525af09568c7d6ce2f59ce8c5be5562f2ba88d561f1d46dc3aa765b3a3a2f5f156177d5de5e959f2beaeacc2b265fe5f7f3638db14a97d673489faf35be8579071a09e46f48967d46e251a7bbf460fde2528e36709b5b4e13a51ee53423bd4059f38a1e3dd2720dd9c037fb6ee048ecded10e5d7c199fc3b2ea4404110e5a283b4feab8048487984c6972ced45ea31b1d262f0b071ddc146f4db71cf43b56ff887679ce39e9a6a3e449b04f3d6bab80ac393abb472dbab9ad52eea3b936ff414b9eda99d710e7c836c86a60755b65cbc0135b71f87fa96897c708cdb69d6c6d6d4ca5fa850fb6ad9b2c0eb5483b3641f211b2bee68ef6e1b32188099e7752d6776168adf7f0667f7b2017 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d060960864801650304020105000420e4a129a7ddccb2047e91b87062a92c5672bd3bf6238b5d2ba1175f37f458790d -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 5c78db3e64375eb7325e70272bd431c10a71e34acb58f215c987313123ac67e1633a0a4c62bd4a76666b526f8efbcacb70baa05100db08f8b40ec10fe5559abb791336a6bf660cf69ab7b17ce2905a2e07ad9dd8f755770e42eb93657cc0c9e3e42be6b342dcab1d166d18b6ee3aead418736245796f4841bd43309cb194fc40 -S = d3bf9e41c55375a032394a403ebe35dc800541f87ef67f9de42b9a386b7ed0f78403eadca167e2f49c5332cef85c2bd821511c721ff4b3bc3fcece51bb10921838384da4af0c40c1031617067656cba8eb2d2b7f1744ecdfab6874038163a97cd08439aad0b8f959364a0cb0154a9606289909a1a6a486030abd1dcbbfc113ac34bace0b84f1b7f9cccba5dbecdd1932f7993966f5ced9187692d03b8dfd99f87c2903d72bd7c0acbb942c6f1f321d43a357a21f6fb6b78f91b92346ec2e577cb8aaf9e7affd12ee3d27ec9dafe50b5cc874c374d2e2c1bdcb22f1b6105035c393e4f8f23660e2d54795757a0d1729ac12e053aeb239b7368eb991278f3a0c2f72c551cb90b96cd86905389582641d6c029c6622b2f7db133191966901d83dabdc5e634f6c8ae59aa54e6c0c2db7a1f573b825102777fc8961be82a624e5ce01244ae8279794fa5ab2fd62590ad8a00c5d0b0ad11a0154d9bbc2cf129514bf193c715e49cc75bcf8343ea017906dcab061658083ae11fe7247ec95ba18cca761 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 275a91aa97dae189c61fd1b7854d49899d9406d958a8401143718a853103f90683d088b3a71cbb13dfb2836144d662270a7acf0f05b5dcf56c701640de63ad73a240d5ff332d6b5cfc78dc57608643aefd0dd1da3283722cded7ad1b6b5eccdd0c103e3442f4398ba5d9a441e1473345ffb5d4e3e6fc4add210c17bee2dea06b -S = 270c4cf3272ae89db2b9b2be30ef1167d1b8b67307e40f97c81c3c9ced0924ac971d669e6c0b35ece58b5d4d4fcb4fda5776f81e99db9f8ea4ec5d65ec960f2feb0a4166019e5bf856246952a9a68567703e505dcee51df9827c51dfe6b13eb6038eba7cc3f3443f0ef6f28ed06fcf272255ccfb31f3a956a36744b878af8eee1eaf0e3ff1277ae602f6b3c1940697d41a5acfbe1bed9abdf73f7882c36647f2f8566d3d5eb24ff8758ca4ee72405c4f9645a2b176ee0dceeed37e8decfe2a3894d6d2118cdb7295593837e2ef96335066dc899a44dccc93ae1aa1a6d2548d074be21170e3cd6c73555bfc3a95897ac9a4766573008ea7559a08c3ad3c21bcdc32e4dbc7c5982f279b036bf790ad0beb6b129d22d834bbd74a204d5d60bf39a3fb4ae819b772dba0ada94a45a5fd7ecc79cafa31dba6762b5b51ee95c0651b63309004923b77c010d4b6b3df457aa0b0e5507c3d804fae26b0c384c1a34d1bdc998005226e81f2b9fae100776f5e3e410f53da6898e20cebdbcdbde9efa1acbb -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003041300d0609608648016503040202050004307f87c39e3367aae5759a4d5de9ef2ce5f95692c59fe337dc4087aa11be86c01655406490b00224111fab085cb688bac2efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 88af470625e6b5be3358cf6a8698a5655ef321838f044746df83bc55b05e8529df0b120aeb1c7b3a5a1409705879f887a22a7b78a2f30186db5fb7b888cd4e8c80c6feea5d8ecb57ddf9076b8980188594947bbd0533091a19b87906e2f727fe3589138ec3652d7d86b0d0455fd78cc5fdda283a00ebe76c5e370b25060498e7 -S = 879c4df9b66227ce30e6403b620a488c72329b400ec67667a600bcfe3d0ea893f3051c8076eee81e0fece30c4153552ae2b2c774888657adb5300bedaf4940d6d6ce9310a476093b3590fca889e8ead464809be4da3370c21784e4740453df999bb9f7c290ea16e4b0e4ca666ddf23c757474fa9b0dbef769b1876e1eb553ee3a1c14c201c101164d5d1e5f628a7ebaf65c0f0f27f239ff67a4fe659d347cf50921b5859d79d86f8bfd2a25eabfcf76eb606b4151516c482c74ca3e54ede03e99086e61c0708e8ad9c94c1fe3640bf811f4e2c0e62d17d593f2e86adfd0798f04616adf9367b0f77f40de77135301debb490bfc76ba710878ddf91651a5fa025c348b6066a49853d6ece7bc79cdcd8ae709a77b96701c1ba9c4a91663e3790bad5c5c48017fcfd005a1b03d47d07dd3c511aefeb4c766dd19e377d2d82329a222b18ee0899e166cfb37c0b1b3226123f80a33c096fa4ba784719c4d9e52e60ccddb6da8575e705a36dbee7d97093f830283c71abbbb85c06daa913f96dede4ce -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 78c938a5628ba2973c2b793348ae3857f599e83bb26c930c026cfcd7d3a58da90c3091f565b2a3357b2566d424db774cffbfa08c50df4f9c0b2746832f6f936955b9c3f989b353095884677d2ac4be68d3cce6756431ac86478bd79a8b7b16f47cec367a7798985bfccee3f40573f6f5964821bf966a9411dd1f17e48ecffc93 -S = 4009022b370d46f9b15af306f177d7aacf5949bb58b68c05680eed83ef5b35b29c53f781ec1910006c4a7756d1c0e67ae52e7599f691352ad5c052dd6fa7f33121841869f1df1884489b18f4fcaf4b790f6818549b26f2c764acdea5113427c0aa6f0d0c3c688f10e572adb610240ca1397a96964861a562625f1a55c2d369017585136aa6f473c368d64f8ee85eb21aea3de696e3a258890c458b1434936f48c5725b6c81de0d2f9019a4ab27724526f64f6ed1e1dc09f1d828c1d6a1cb4c593d4e554e714bf55ef5fa2915eed46497215957abfe3c92fc06dfd73add5c2046a97b50c4d2366a4ff6c03ec4ea2e916f58240744456cf57df158a7a4c3c0bfa9cee2fe72ebc2d792a99aedfcb7070841a691abaed83bd55df0408a8555e8c58c0023d2000dd7589f9e3b5e5fc9f6448f47e870ca13755408fae7eaa16e2dfd4d41b4de4099b5e224222a520b87784b2679dcd66cfa94077b9c5756190bd25d13fb40015f1bdbb73526ab6467d0eb1aaa458f38adfd539a109eed0fc253af8e8c -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = b82dc25af8993613cd5f5e6e851dad20d155f1d2831f3278971addde70a82283655b9aab7caa2db075e933990b78d9ed763ac6ca3448ff3109e708a445b84df3452fc0533c46c2b0347347444fd7356953b80eab6531cf22152818ff9b818c6460917b79c1d6bfbc0fe5e398daa38b3a6fb80fa09f416af2c2c55316fc6ba97f -S = 03ebbcc4ce14c87345290d77a652ddb0a27143e11278b4083cc33a70e4395dab1dcc8468f483e6b8fc461e31e1d5331fda53e5ea595950888d05203b06316f7e5bbec3a2a3ba3d8917e56a657d04c0a8a8aa123119facdd323114f9a1ae78ff5d9295b4bb244443a4e3ada7c00985e74de8b295dc898ecd6c891331cd458a040edf8e8d2d9aafbfbad55f111265723bf9b04636f211d853be40c9119850c2905bf665cae93968363e82794faabcb02a2f1ea1414ff05c63c3f32832e7d786809603b41776554c973560e69c3d37eb295be53c5b9a9769dad97f4a99d15e11c5268e10387b1ba13b198165f78423b61e2c203de534f9e331c004bdf85d1413896d4deb83a8bcf8a09c26f43725ae9a1f0f6ebbba092803e498a9fa5e3d15042964596817ba275fcfc89cace5b0b566afa19fc3897223b2eedb48d1d5259aa576f3248ef1647e6c3bcd5d3f88f5894be8006147a4595d416404f2de4724080bfbdc5dd58262ca15f1987b09a80a2a38c8594e1d2307fb99c1336f85e7c0cbc8ce0 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 18201d59ba48bd77abd33ec87a68c1bf5ab93b471aab100857b7e4e6f08fadcbba050da77529e0b5ffb211ffc8a0b124861f4a592aad70ae127f9a938021309a4b5ee57ed45f47653c179462d4ded03ed55b147852a8298a6ab1566ec2dd756133f14ce7bf311b0fcac872f886694594b03742ac7ae26224c813bf819e0ba5a8 -S = a07673ffcd2d28c4dc9ee2f91ab9b1f7f59aba09779102f5832409a3ce9d9193ebb54fc122018602ecf9d52a0e29c137e7a4430253faf49ce6a5f25b7eb7245e2dc01aa870f0061cd7857a6f58e765fccd06ca7f35cd796aa016bc0198583f86ab714a044e68c4827f5ecde03f9c9843f3fd5c8448bd039b5ac70a6bec0048155a11e55f60edd315a560c5410210be96baab0056f0ef9404333d068af9a814b5e8be1ebcbb1cc746080fa7b3a09e200426188b14488cfcb564a8327eea01c0c1a1681552fc23cf516f600e596ff6bf44489f07db4167c02028eb6295c769fcab30df726aec31af2cef6a26deb01a918e6dcbe6bc16fbd21092a28418598e958b99d7db0157674ac564e03ec10bd6a59d5a87435259b5d74ecafa3c0209a6c20edb7e874f6db5fb83019dfa7820584aebbf93740849b5e63985b707e891ffcebf0c45f827933808d2a7374cee25694ce9a714f433017540c996c0b169a284a5b1b2d31c954ababb6f75d7dd060408e74bb09cb9be1288a9b52127fabdc2de942f -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 6c49d5bc93d861ac46788e3c93d6e815966b90248f46ec89370c9db0553db1bd8cb81a2e77825fbbf8c39281cc11826063f131a2ef9b89ddbcfe4a1abf0447367117d289dee475c6f85fe32232072db94a6b392d66ed719063c6b8846a4aa2a0c46de416ef870993f1546767ec3f52e6f3e08f0e1cc30b6ad66bcd357d962ac3 -S = c35cc19c52d8727b0e9945942208234a2c4ba3f4d4accaf9b54fe161b5b92537838d74a94c0aed70e58e99cdafbab8d6b968f57d3af6b7a49d8592a4b381635f7ceeb25c4efa0cf8d6cd6c2e8b751143f11ec50956db690802fa0ee40640badc70ded68345255b54a97dae73b340e10af6f546dfd395d3434b775c6dfe29058d6c3b9531e968091f8e80f9f4a82439890f7435622b3fda11eda964dbc5c94f2eb7b66ac1e17b6e4bbb5a77870e8f03af62920e64ec059e6fd037574f31636800f53e506570f5352c99f04985337819cf47e8cc54ac38667e3406597f66025d05e2269a77b347f02129b510f38f898a7a79a71dc6126d3db62dc3dfe5faf7e917cff2fd6aaccec49eaa0e8a35b4bee78ca043ab2f860155ac2ecf3cb7564d8fcfc913653f6392fc03a675884062217f23543d1030704a733d077969d9181ec555c0f3808ec7d6bb7873787c296782a8c3d374039ed636037e2aea56cd230baccb692fe46cb84efcebeec031801ec10ea4fece8940ca6e4228bf5aa40206efddb8 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d0609608648016503040202050004300ba6737418933139584032033536d357a432e5e4b816eea001f2b4d47dc04550e24f47ea3060631bca744f42b3cf9675 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 08845a6647884ae71378c1ea0ebb9cac11159eb121cc08089e0a6ad0be83b8fb3a57a052473a1bb9c8d243b5c260642b10a3556b58fa096c3dc86159d61c444d5f92f25c2f7495d2ea251abff8c03eb336fcecc6eb53c6dbfd630226659477ece0fbf78ae77ee0b9e239ee10992153cbebe70acac22068dd46a2f43e5131785f -S = 06771fb5a09539491074d33f227cda5a26e630075870b00e84c0fbf47c98e60a986d5441ec0ed557c7b02db2394951b61d3ac76a94fc87b21ae77c082bfc0271c321a77ea020900fbcb7ce8ed40016279b7462df2da6e32ce0975c3a5d05cb03dd0e97b533f3bbaa352d579a2bf2d47fb72568f2a0e06a514bd1b3475db260f0fd040626fd8681914a28d49e6566855f02ee2eaa5e1e3e277e00e677c60c87083fa88785d48f7970fbf5e835e0b2bdecc61df27ea9fc7cf3f510cb234d25405c4f9078139bc85b92bd0e8905be80380188d61d699a7c7db0e087932c2cadcc6991a34dc2a6f9c2e9b659dd1527c51d6c41fdf23b5a14f5d8f0c3ed2f28c08223ce4450ca5e896a2ffd0f490cf2495956eb0257246afeece291b8ba7c373caff9eb52ab90462069d20e3b09f1e874dadeb2cbb599d2be0eea434f70f2d26ada7812f58b7edf20ca299ec53762943c628ee31891c26f69eab3242cf0d90ef1607ed56c19ff5af4d4be35334cc013b47aa087935a855dc1ff62ac5be945978d8913 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003051300d0609608648016503040203050004404cfedf114d5b9205c1c8fa9a8d73b55d82c17feaeadcf7da87eb11bc021a4b55a0c0e4e232dbafcccc1423db05e8a917b5d86dd9854d2f9081c5cf7744d882e2efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = b2f46df8613ade16f5efaf19cd04d7ab3a99c804e0cdf66160d493b1344a9d91dac61b7a34b3a4392f5b20a0a345d37c7ac197c715c1681eebea267573eb9709450eac967c0c05ca5e26b6fa3f714c15a2720bd6a2ea7a3d90f3223fde4c92bd3bf2a6b300f009b2cb77f99069314a5efad3ae9a4ff233a697170d793b159695 -S = a411a40f0b95e8a447e09914a31ab52842583a1a90479435bea0bd20104c6423ec3ca53a42e8803d172996237e35e59952d32ad3484fcec66fb8ace07034928ed162d287125963099eec4b1f59dc835a1ca02a658771a64e20a5d4e2c83770a11438b1956bca7c586595f8cdd28f90a033b22a27f10dfd6a3de68ae283b0af9b9fb3fae6963b9177ab6bd03b7ccef9e482c3c6cfb50434212c341afadcbb8c62ec4b63758c2ff5c4ea4e6625f8ebe1b51dadfc902c572d7786ff0acc39b82a3b3dd14ecaece9db85dde3d4f13cf7cfcfecbc5de471316585541a19270c3ac94aed43087b5c03e8da4f5ce3ab7cb10567d57fc2564e2df03143cad78a797bbdbe86e9d5d64f9cc9f9e46a288bafcca13edfabd4c1914884d6984447873d033a8164346b34405c8c0c84e1ee88d480d3bfda3aa075007d7647ee8581bfdf91912df7572bb8ebc9ae22f8dfb308e983788fdf835e415e883a401cf23a426da1b21de4d904b5d52bafa91b969f36811e829d8bafe39ed4d78e2f30c2e60038d96a95 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d0609608648016503040203050004409f24b226f1c31a5ced2822ae473ff80616c976eeaf6ca63f2ffdcf92238baaf570822977f1c37aa3b53a03a0ae95c82b8de631b9bbbd0a6bb6623d9b8ef18d0e -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 68f05fb0d353897bd65d75d3b54f34199bb8e5803b8f78c5b87fb71ac282866303b169a4b95b48baa4546f4a228fd9f899efaed9155b0a2a321100423d3cdfc596c8b31b58750f203c2a0a1dbb8d88f873d0bba7cccde9eadb566f3a87c606fceadc45fbfaca671568884f35c86ec981f30213d4a90f9c6e7bf70beae8498371 -S = e7c726b4bc65c98e0468e9e20bd38fde581f0975031c56bc8a1b149724bc313442436f6b0742aa96fef392f24f4c6e78c6afcb17a9a70a686c3091a0a746f6e427023877c5080ec23d50c2c8ed063b5d435ba3cadfb0786cc0fbec7d4b834e45ba3d4ba19101beb4cd0851cd66dac7dbe6028a5a27873b81580ef817c0cec52dcc99e5d0a48400109525813c9c087b403fff944c08febb645d36d0635c817d543d319cb0625fdc8e098cbd64b67c1981da87a4550d6bbc49d074fadff82f56332679baf1861b9f09ceeb8d18351dc7565af1e4729dbfb265056baf28ddd980dbdf512e9d86faa6acaeea1744f6437e30a9ea6faafffd6a813e255215bc1ef3e3a6d2879c763dacba1af4e657a7aa19e11143da902ee567fcf6ed9bad15f952e7087d1befe7bcef6a9f14fb7d7cbe9e06ff583ea888b27a0781c1e1c46dbabd14d5688f25cab383b05c79dd4f500bd2be7c647cab0b12c123a0257cda1f0dab31d42f70b53adc07765e583a146ecde0f37fde7c0f93e72cdc56e734577be3cd1a -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 98ccc6f8347973189f124ecceb360f429f1aa6f850ce712175c2b24a7688403d06db7d26b3e187f4bbadb302220837f7017126eb2162a2cbc8d54dfed3070048057cc0ef9f43ed1d317bbd86af16e94ac7dda61d72b4d7a5ca2081231b067f563cb6779d20270c5ba884559fbbe88e0599670ed76c4d797821aa3703750e252f -S = 039f309c9e084736e33c0be61eda376c5ab9759a0ef9e47f9fe17ae52cc6bf878cc2bc6bc3dbd9986f9f1b971a5eea3377a919922aeca340d63fc414376aea9670aba138a831f75b4bc63ff3b1964a6d732988e6d801f4bffde8b36fe629e57ff3f6d6ca425a8b7d23f6f66d647aad60e60819cf00afea8003bc56ae59de98a4f0e87ce92f4a12e3641a7b4c9dc53027659f0257c3ec7e013e8396b5a006ea8b1fea2eb25132618f75f5903640bcafba9f511338fc234e1f000cfccee896194d0182347e979afa5b03402690f959329ec567bad325172c913b4575c1c46722828a99e9a304f016eb615664a43ad1bdb26e99e429c2cda4926c9005af24de69861850b6a0908347b2e72474df05c775b7cfb2360df99dfafbed216844931117462497b51e40b6b634863eb5043f001b6d3b15e61f00de1d9f012fb774933f502089a213ad2eb89cd150b46895405f087c5c93d7a9fb55bce4a2d93505d81f2966ecc6e0386c1957451d014892087d978422c612d226c9dbdad48a3aafe50bec47 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 112b7aa9fec5c7ac703a49c298c4e29586083296f79b099e6ec422d586840ed486d36e06362d6554f14d4d01fc39a9d2167e5b7350bd18161f66185db0c4127a7b3a67951bcc9e6d5de010439746e4f43b773e65ab1ab4234fcd024be621fea819e6ce1c56aa5841db7cfa4f11f67b411c7a4233b0bbc60f267f4668cfa4baa6 -S = aa3ee99d39ad0332ca48deeb68b5966962018906f1e2e97d0d711df66e600fc875faf8da141212ea9bc49b2934f19bcb26f819b3633381b23f74f0c1d486c8fed6f6c17cacaac222e55c8c534ca2cb3921ca6f0cc19d045fa5456b4ffbc496d0d3079f19d93bba5600048b783a905abc3f30fe4b33b057a203b5f9d01254bdeb02896cc11b713fdca55e3ecc67e243fddf19130e2f3c79bd984558feef0fe877e071b0a13323e700de83244e2bcc09a602eaa06bb39d832d58e30450dcd96b30052778c07d4b209d5929bb6cc80800c95963a24bea449189301b50b5f26a899739dd0a4af6eba05e7e625c96cabda3beb2e4b0d11ccf72252b2d524d76a104a6dcef635517d78f248c78837422ac900557e1671958116500c673e2fc9a08e40d4eff8d44146f43fcc5f4086d276ba026e9953425a11b7be0036ddba0648f12424c3359cd8db8a0490b1bab3b35d3550840b4937ad1986aadedab74fcab27fec7561ae2bbcbb16d28d173efdf049fa8a1daae66db51f4c03fc91d1cda85d2cddc -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 078ad6bde08572c73c5e94bdf0f1efd12da3a8fe7c035027236acd3e4ea86edd1bddd92ca601d012b7aa4e4e543caccdb49f54e35ecac7ee8b03b522a1b09957fe3ebc4d42dd96dcd4f9f2e215dba47749c9ec7369ec21571b21af638ac6f05d45980c4af0c1e6db2f70dcd738a803cb9cee7dffc3e7a735ec6c2541b270cc6b0225ef71939220f9ef35cf5c5b0dc291e237bd456333d803d12883e0694b2e891a3248ca36b838a8de27e154624fea5149857214b15ac4b4d67e0ab944ff5000552c66f833239f3d4c27a76cb14dd181d3f52a12cb4f3f9518dcb68c9db923e677d6f733febc93152c311880205a5b73ef323c07b87cd55549156b0452656f0f11a2c430924f426a22117c04dea477588fe092bbad1a4bf2a0a7b6befcffa3f91f4d308ff24515dae15897e9ab00bf755f9a366057b66f095573a9f881bc48e3711de800b3c0155c976957c40eab8834c7b7911d426fd7484e895fc8d8bb5ef7b562da7a846fd6bd013cef55ff3b11de43fe6da0c90b59dba4bb060ce4caf3cd -Msg = 7f1b83830b4da729242205b0e519b5243d32442d45f5a933d1b57bc54616613cabcdc99b02a7ddbad8cdb2a41b46c33d2cbd9f283585dee7bdda5944796a9bf06514926b14ef8a23448e5de0b682e35f3d21b03d1486ff1874d9e9f066d1dbd3d77646b9ea2c98ad92ed6c2d5fd6fdd498e5e1368b01f40c213a9291b553092b -S = c8e55b1b1ace23e606465dc81f6a349ad61d2b8a1afed31215ee6a0c8214c5366a2ce18cb649c4bcccde5ef2bf4af51f093049d1ecfa5f5b639f7ec62d5a4cbc505d0f11bae2c16d8d6a61a4f1f9613be25d66fcba03a7c405204cc816414a296787e5a1462d12fab51a829bf13dec500da689520ddddc305152021337a86b676545f8202c5f936d9cadeda41a111b65d9174488419dd19da5d3960b6f59281bb2e90b4c12891a1d5800d0b0a932bbc95639b130dc7d03402322f7cc7e06020d5124023b049c61cc6e88b345d0a395c80f1f04b7760f0c526537f4d4c515696253361a0eb03c3c5bf567cee736f63572c85db1c7e5d016ff19c0e1d38caf0f7569dc00e3c4301be9baed19d45aaa90ab7204c2c70191926ebac319caa27f55e5e68b57ba4a70dc153d750e318099c85359f1ebe70686f4bbaf9b9f6de3459cd8c4a7bcf8e559eb7c68790a67b0951554d9fed9b5c396f44860ec61cf0446cfa8061b19c72a34b62be8f34736fbf14fe556ad57aea605c60adbdee4d3fafc5af8 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -n = f33d3234f13272c3b2b6821ce4805663ff2e8b0d2a47de363d97fc9cc879cc6b40f9e53aea695dc538a0d2b558498829aac327eacbcd889e172b34f90745c5d528b7e82605f1a58fd228ec7fd4b6f476f393864f48dc47097c8a780a2ecc02f748138dbd7df99c52d822a2e5154c6047fb0eeb4f49da38edcae3c32d3fde435f291f96cad1e09e1030ad7efb4944b69e074d0d7964becb3cb86238d8d293bef3030d141d14868bc21fa133e9de1115f749991cf86ef506e663ac162b2c8567ff131a6b467a6f564d6c588860becbd88970354198ecdd4f1f4baee8f8bdaf7255835385f5673625f113550b123628a0be3994d91c3a19a82e5d73448dabf684ee6794fba7a2b1afbee0287e5a11180c29ce0896795d52ac7f408fe28e8e9116fe0b61a1083f95c5227d62d5537b5040b79e21b3a8e83c225bf3efebb2f808541e97d28a2468359fc60f588e74faad611262064628a25d8d61f9d03d8b21cca515595aaf2343a759b74a6a8afeffca139a389aa281995cd18e16a9cf7b7ff0dddb - -p = f3fcc6aae575312778d9e896acfd7c1aa4c5524f20453e8bab255363164afa7124b2425587a077fa0bfaf61b12ef3f0540dc4c9e777122a60610a53d1d75b0a5859c654a8ddfc2ff4860758bf5a6f264bf8bc2baa7551eb7be23bc06978be992fc81d890e07a3abf95d20eee3f6bbbc089985cac96395b473b2741c66bd2ccbef228432f66b906c15b19694dd786c29f06cbc17b2e6400dde4e3db85819382b3d05a4c3009f092d40d05ed5b2e0428a214e15a7aca09b47120b9ea6cb4084fcd - -q = ff36fcdc519fe10c69aa0dde2cf3bc72cf2ce9a54ac063d809b523f4e5d7ddaa5413d500dc21f409ce661bf33018b748fba3966d874bf96f4313eafea9decfba71d540ae0508161a3658c4762d94ebb3a4e228c45661315db30c20fbd9e20e24c044e4f0b49e6ec80949b16e0ab07f3d32b248b39f48332cc3686df05d29c170a7276acdd129259aaf018ae3afb49b6e0ddb9e404a492863daee7be71dfb11279047794e45f399a9665796d32d5e65956a13a6fbe992b36bf4c842f5f519ac47 - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 3330bc3d3eda995522e8849c7e8bb5f3f6e895b3d7238156febdca74f62100f26079707698c6eb1d9530c971119a2e95ea7a8cc3c9e869f901f563eeba3d714b4ec06b18f3edcd749b00b88a188e39c0845ece31e07b265efb872920955238e2c5acb60c9877c7c2fb0057cfdb8f5fdc8a3c63e6650540efb41e24f3d188de1d -S = 5949a5007545d28832b13c6c0a453447eff95e2dcff9e403db83bba0379abed6d503394befaedefe578be085622fa73ab8f63af52eb91dded8a0456df41651cabccfd34250b813b57dcc4535edbe0901196724c0842b951ebf3ab469faaa51fb22e5574696dbb57614892d21a889224f6bb0da4b81b8fce60499b8802b36f1576780e298d87b71dd5496128b0c8fbd3f1994385c8029b720cde1317db984e02c0ee77cafca705d4be54fbca18c4f5ddf85eaeab784002c8d1fdf5e3794d94c5c6c781e9c05eee22e4c1556d9f8f6215b23d5c687ddb79af29a280a4cd6be95542709f423d918d9147c2c501d3f6121e942fbeedbe70dafaf76819842d651df018959e586e8ac4325a5e616c3e6474e1640d259c55474366761156aabd0d144a6437e7584bf33089ead0610f9ce10dbe39fa93ecc7665082d64aac474432689758cdb092757a53ee5b9b4eb3f6ec3589074248ee547c6fd203fe5bbf217974f1e2e398dd4d1909e85146d7e1dcf74ed9478ebd414268bef406228ef21c80ed1e4 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = cb67ebf8f8adde0c2b0640db1f4668ef866c27606577504abb7b777e63f3f8783b593c9286f437778ff235d990b6d767d17358f914fa150e31d04d79fe842557713fef44099dabcf69bbce2b479243278483b05f9c32fab441980bfb4354d3f2b3428c78484f43fd018c94370c81b516e7c3b6fbc5c9062533fb3a6bfb0c0a31 -S = 5e8e0eda2fd7477143e33826c1f37f1091e766874f8d9717ada2754610aee94c5bdbcf939e710a2d5bdce1329aaab8eee0a33ea8d93ac243e80a61f09fe31dad8eb291525dfda5110148a9041551c4673db5edb4d3e457e2ac8834bfe600ad9e210a9dbd238f8811552a5a6de7ac23e7ead2746cce7358e7b0fe27af32e204bf292e7be24536a1df8e10712bce78d0d94331de7095e9f56760d7e9e3534b0a8bb30357e2948e2e649c489e916abb399541067f778a21505e0ce4e43e3a64c30fcb8a22c575b2f63868b151e7c0865a52884008477d78aedec9b950bca5ffa93dee9c7b8234a054b61d2898a4fdafb1cd2008635ff56744d0419cee15477f544caf2b264dff93c2ef060fbc7e062ea29d80bec0e74287d9e2c0adba92b5592c4339776bef5cda132c83f296810833cc99119aaa31849ddcf62bf16c45f7654f04ac4eac75102e9c5b79738e7d405caa63dd917f3f199d132169192397198c67551ea78339ae376502e7e4ab23e5626c766fba9916ecd20d15fd63c75e4a927ec8 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = fc57235b4d597f5a5380a07aaf7ac6074b17d75ee4b504ffc6fcaae4d7cb7611d771cd6de6216bd047a04a5d6341c5121113fd9d14597c71e53a181ab4ba1acda9e9a0446f5a40c9f3d7ee9069532049912030f6386301fa01c4e573656abecaf9266489efee476ce08e56bac99a1fd553a7371057badcc2a101d999f4c1aa30 -S = 5b53b1a1fbbb8a28bc715cd607a699caa795fcff045e660e102b6c51e0daf25a9cc0d0639c1bbcbb9805904cf16ea3bc26c18f58a3702f39a3c1cbc5e6dac954d65d102e0c44345704844af1b8e3f15b7dad532192e35e27a335bb67dd3367c828b7eac524e1fa3a1db556c0c3180487ce197cef59ef05025d0e0c7dfb87fd9da457d15688434f5165f16205a8400849118de58b6380b807a6600c698b2553979c7e0b83ca200433c5b5a6155eb6b37ccd8d584f695a93e2b1a3f933e3a0997c18ec63c6e90c54f87bc48b8057be5eea9131d8acd848843fb3aea56882c414258478548a7806de7db039d97c5c440d8a99923cfd7c3718046fb16bfe53dfd157be94edc1ce944fd5770c38247d78927947c06d113759f4134c841323b3679b0e1b4537335d4a16aa2ddb01fb1735b8f8d0b0107ae714fbf727ac74572d355da37b997b9a424735f535232ddacd026814799d86b91b7701753fe1952651e991a1b8357f43ea06c043ca1cd57fdec28ddbe011554bc04dbbf3cecd03710d454bfd -SaltVal = 00 -Result = P - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 6449afe8eb08b35e4411a1bdf1eab7d7cf0d5813f83b1063e714d376dde5852e84c1c054d2d3d18b31f20382dd76216e8d4a36b8554397f2cbb023106933cad532cf4c8b984143f79e94648c3af002dffdb3d35bf5c2f736d32236a349c28a4ab69bddf505fb138cd21e4b43cfff6212676db966a1613916468f9498463bcd75 -S = aa36dfbe785a437cd2c92b11941827bb4884157fdcae8331de98ab8d3294ce8425e719b3b0e54eb27d7a46e9729ce18044880a18261d28d6c10641818d7dd47c421d748c984597cfcfca821f8c3294da53d16c1af99135f750294709b92755a3f5051e033ce3f6df055a77c628ca952511a33b2a1e6ebdae047d9c7589c8689e9ab16747dd4788d023315e6c98f2f060f3bcb655d487afccef512d929da03e0e4d7ecc2b7715ca61cbad3f8fd8f4383391014f14fb414cf49347ac60c01b713b6dad9e09e60b927b261aa5877a1d5b0e76906d40bc77cfb41405b93a3c93fc2ac12aa08e44b577980e2ffdbce606aee14533c8161c85ce8e4493a8c1aa03f708c6a4f84d44f9d147082c1d6d0c8498e109d4e26406ddaeaafb9409cb2cf249a6308d3d8d7bedbb8133d542513d9c4424a3609e81066dece42a7a115279af0155e3596058a4e22f6876cd931f1e4e5ae5800ca96eca88a3c04b789ca1c843fa9730b4c050e269f9f101a48c5c1df7e5770f5a823e1e29dcb47367153a17bff1ec -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a05000414c2f234adf6d0986f254e79e3e89264f7681cdb65efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 6d16916bed6c4e35c76fcf5ba043724e7404bb147d12534057ac512261c1b93b660242f37d3c5d8f2de5725dd5f56d314bf77915c45f0b3df41e23397674cf6e6d05f0c76c3040a8939c9424fb135f6f55947896cda31d6d35e437c95fe8dff0ca47224e81ef016a41bbbc18da4851efd7043ffd61878fba6127153be5c6f4a8 -S = b08db35d788332d2bdeb8e89c371858710b0664e464f9b726c92ffa837387e7ff14a885cc776b1ec4763da1c7120c5da133c3dc01de44c93fae6a9e13c3542f5ac6ea44f3ac9892a5b775a535b4723777a43240af123ef78bb1c1d6788098fd148a764290a559ff2637af485d280bed6e1b289e518aee6cbe842b3feedd158c409d13a5f117c8db853bab5b564e43a06a83f4d2748cd718bdb8fe41f5fcdf9f0104dd8125fddb401e8b5ddcad388007c3c86c0e4502c94e67b0d194002f5464d22ca2ec65af465abbd44bf90e3b578a9884b86728fe22705a9ab24549d4c168eb7b3f1c6f6b07a55c3a8347b392e0eb50ae985a7e3eef4cbfe060692b45c6671597c59947d056b9452b2030529705a6793547d75d67298182087193f608163f3599464ab3ffe82539e202679b84df75ad7effd5985b9e08a88d3977dc978b748a9bece9e08b42b88ec6a766989aa03c1ff73445706035cb50fbf01f89c9855784912dc7b911cadacb0fac987e7f5bab76d9658ff84755c70225a4e42bdc84feb -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 724265b54dd8716ecca57175e3182d40c4ef7a1f0d9e0fc240f095fc75f0fdc64b0a1687246e5f9392b51af10cc7a161e6fcfd9d8081b5e0bdfee4a5b6758eb1b06e34534c51a6ebfe1319a9c0147997084801daf7960835d37d1eceb7fd573589b5e7a22d49ef7ef806972568c95deb121cad5ddba3b1c96bb76a00df50005a -S = b2f503ef1d4b84ee0abdcf78640f1f82de00b2f5fefd803e1322a3e09e617750884b4d6d7e8aa741c93e9b36dae70647c3fae398161729f2f8962f9985157ff7fd7de42d8ae7579602fec0f91d0350a8bb38fb54234d806f3251eb6ee2a3806e3fa846a7add80f0d2dd2fe9977265f5ada5012f739bd3f06925d7b8ce869851bbd5897b819c71effe7a611b1105e68a3edc5b70cede299548e9116841ff1ee624ce0d8d477a18c723ac05c756084f4e7cbfe851db1e044ea175c8603f90a4ea87421e79565b8ad247c9885a41af0a2d1032f2807b731f574d54b6c82af900b0a1815b4e30513c7033e67a1c78329dff1a4542bf28aa5ea78de037bcbd7a9e0740693f71586d2dde6df39a979dc55335854d656a8a4f123b4414504b1a3f3f0f5e7d12ab700d24b9f34df58eccf2371d9e8429f5f206122b3663f99ba02929e8f46aaf061845f793ba8bc7e4de8621bf2d1df9a1ae2fc130a478437c10d2bbd51207dc07af35c88c5807c92b739d3b5a689250ecf86bf1bcc8e3b5238d2884073 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a050004143ea74de96d5511a9072c9cb0dab7868fc0c87e3d -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = a6185cf668fe6bcd1a872da768424d95f6d52792a0342c580617887948aa03aa0e862562cce09ea44400e5184cf51e61d18841ab1c6e798354c2caec44b2f7af5f78a3f2018cb60cf817029843ab27c81932b3fd2e258e9431ff960299f08623a1d51ccf91687baf40b4ce4ed7cd2e73d7bdc6af5ec13432a6b633e2cece77af -S = a31dc7740083a5c5b17c2b4549d4ff97405b2de7a5d878ba927fe7cba62de764685a23f65cdfbe9d0ae2060434443f8b18d8032e7d7b952428dab81cd158ea3946d17c28d1bb160e6e8da0be12489206cc1c57670da9277e53ffd10a3a4883796d9389e2a361e335efe34e91d6d12e78f606a7e79fa3afc7640396d72cf34cf39150e7784110ba4c703d34747ce050c0d679ef7b1e72cc9e049e4ec583b9aae258d08560e74ba41d4917d8f41c1d4a3b8f04bb76c99b36f738619e6c3b977f716f1229da7d54287c0209403ceb35e98e77cc37499b7c2127254ddec1826d8ed6fb83ffa13e4727ad2329d6c85df002025b0639399a050bc2ee13ef43d4b5cf25a36cc0c9fa27c2e2523093dc48a2b1f66aab351965866459f6c4bb59827cdef8058311a81713c011f8f77f819c906be90fc9e09b6c5cd8ded0da32a30e756ac1fc26282af539dba2398ab21a254067fa338479714fa3b37fd7d7e6032e6b9e5cd31f23972b1aedc53778ceb8a39d3b2b3337e694be843e35dcfc310b09f560f0 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = f5df0f6986dd3e9cf4c243af92a6a69fba85406eb7944318e2d47ac80ce7d24c1c231ac6f9e507a5ab277bd4bd550631e55dae41e706eb22b682f6c1dc46434d1d194ceb576b91abade9ddbae44ecada0d7c871065cbd99c79a1602e8e431c573fea303e681ae594432ff1cad139fa817c095642fa8c156f74584179e8856454 -S = aa1f614775143e046d4ab4d317f2a69a319e82f91dd4e9e3cde226c5ff87bca2093afefa76890fd8a2cefe38c96aa94dfe9efe7e3975425f77bc6b4b13f2c84e8ee80aa7ebd95683a95ae0255f0923faecce58b02c6dc9ac9336801fd0a768d6df0a0b705d8e1402fb8f769ed32f8cb890be42b86a1035d73f01ff6757bd02a7e99449a5849f0f2d0003ef53773a0b13cc07e53a81a7914892238ef798faad7660f9caea94abc282870714d1e9bf7d29840f0beea5cf4addb6bda8b441db30dd43e207249577db9af55c674cc58ba2cefaf1a4fb03ee766f45dc46aacd12c7cc5508371db63f2b971e6842819a33b3535a1592787bdb0544317f88cfd63e43dcc987472cfbafdaa5923b3737165f979ebfb647d86f6d2a8dd5137484225164b19f063fca9cc72f516b2402983f7e5a643f8cb299870166b04177daeb90ea978e957d5f7a918063253d7144f589019c7691c6198f830b86d9c8a97af6d530d0c1126b377d5f450ee9eebe33a9b135774624f575caa08871c549f2d074552ca2b6 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = e3fc380f53d94344f864766b7f1ca420e59f430ff31d120a080bff5a181c4753f56ddf2ccdff130df46b6d68e4d1d88d83120579a43f0eefcf5159cb451ac0923f7bee4d77d80c98e9c99ef6db12a7671bd6143d8807572bd321539f87187851478e2f1c574a780e5fe6d1bb6bc75bd635533802a75d37e59ce4b37ee7feb8b9 -S = 6556cf98dad966f1c91e0fc492d74f52a7896d1901409047bc630f4b4e97044cb9f142e6560467aab4d65a302d856f72c15332873e0a8b646b3c70bfa8d522c50906c240289741e5e9d11f77a640b7d96707c959d130355fb2a2fd65af4bef7f05ef9496f630f79139d90556a970e1110d12ef10a1b7e74e6dcf7a39ae299ef8649c06d745104ca65b82b52eaa0f00f936525065221a690a65afd7699d93c70405403cc13a72d944dcc0efcd431604aa638515033cfb499207de58a798a22c047d18dc825abead4848c7f521eb1ddb2a10af5fd7bbdf9eca83fea139f6a015b614d7126652a302786850f400c05c2945de31cdbf0ae83c3e39c80a1860d233f17e5925a211b1a35e1e7bd72cc1785f9674f858b43759542809a3d9e241d29a62519424c8215815e0e85bd1374ef99ec64f08b3e84e3a6c04918462098329c97d8522aae23e3d5511d6489a1155774916946e7e0e10979905c5cb603561fb6004dcfc30ad2b6817272be904e928c4951eded095e75a5f7726f255b01a85211bf4 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 167c1cf3b93548a9248cba2d5024da528f9a23bbcdb883a915ec051157f8adf268eaa3e54a4f95f6aea456b2b70dcb81014a0736e2e6b5e5efb1b6f4c2710c75fbd5f7b385aa5d0b1b516ffe0a718a8438e95ba26509473eb1010a335e999ea1d8235e86f2ae6b93737d4f38d1b8e0023c606726de88025e62c347f3b3d92a1b -S = 674ee4315853c10823b2d0da2e4b13b6125b9ab7ec5458fa09139ae74dd16b83f88a75bbff1b7d70a3d099d12c6a84661dc4097ddf5b569a5f3d1ff4de4b595dfc0a6726d1e6d1962af78a94ed73fd2104fcedafb61097f8753b5e8420e17e284179e7fbd16d3ca50ed0a66c5c2ea1e412f3f758ec18f6fc07e69164f71a8a1d779365a5042f5ab514005937da2b92b5120b62590134888134176f5cafbbb4a98f08c4e2d581e0ad9deb2caa666f36d4ee13e3be6a31861e4609479dcd4796b9064e7164aa7569230baba4fdcda388bff7d2c52645e9d4331c76cd2726eaa7039078fc0f74a47882bc0a47ffbb43e284d6dc4532e94f4bafa5e17d8dd2f108cb2f3b206e06eacd8a901a6e1f7c82ea45959c3de898560678aaa052ea9d9217e97b2a30de1cf6649fccac679f15317423078edf88af05080b679a581be29a76d8cc20ea7d33ec576ae8aef7d58c1b3126f6efa0941434b6dea5c0ffe8f404f1d37cacc3c5e853ad269a18bbc19720cd214eccc813d95ec62a0f083d2d0e66224e -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041c20f660487ee230a6692b24f4eab6705e71f3b31197c1b445b5986def -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 2524a5d692240e9c82d0d620a0b7a08c3f71ee679bd78a676174268672363f57e469479b4ae6021036883189fce06e43b82a5777927fee2c404c404fcd024505990f0840a20e0791013add3db8291e92aab7837beb4047533a12d0f7cc21921f4cfd31ee1f02e5c7ecce23635cf97a201e00bb9c2f815c8358ae1ea5f8fcee4c -S = b7ef6a53edc10ca9d6a16678c2cc38ee3859dfec0ed0012c788c5981fe2a1d04103acb6179c176d9f9003eb86db354fd504107c7921608e131cb3d4642ea87c0be3e91e7e85943e7ba650db959eeee710b0cec5817990de252244e95aafae943b9828f11da0e490d11b5990ca2d3254095f3ffc0defc38e5d9d87e3088a84d002844b8fb7231cc7d69539bcefa4eb345168529a12cbf866a76bc1f46c112b25099f91290222b839ba7167e8bb99a001d139e18a231c6fd5c7ddde5a0799b2885f8d32b77b620fa555d43bcfa1cdb897e53d8786f7fa2a734cf881994fd8b71148a3b96791c18d28fb6e39e9acea7e61a03b3367a1eed28c15ffed710389c6b047ac5cecc30cf4a9b0ac2648204c72ba48a7957e7190e4d34bd8a55e3e488e61cc64f1130d81f5a182d480fe032aa7f7302ab386eac8666c2213b103872564c11ac0e63f1b9a2946f3e185a0815e4ee2aab57a592344afb8568d70979e62077d5256fed2aa02d800ebadd4d9b26d7ec7ef0b3edf89d2fadbeed40f35b54897f49 -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 93af2807782787ccbdda1f2d60e56c455c5ef40f152fcfd7f62466ee59427ba2a75b6a6dc0dfae6d9df5a61434ca99219b29f9cf714de44c7af3f06c89b3289fa38f522161cd7470960296033270c8396691679009f49d173b48272648b75b4ccf7569892398e1bdf12a7561237c017505bec8b9a6cd0020824c92825df61b91 -S = c0aff8cf59e543109654e1bd05a2fac0a13782cf26cff6978a07e72b6aa64ab84dba40836ec1504a83a51374e32f09dee79845cda7aa9fb6c75a9bde61616addd9bef949f55d5a638615e3947c64fe8d8a85bb54ef6e71090b7c84812da8d4af8929c1964f27820435a587318c148f9221fdb4b63ce7f43c22a0e840bdfc56ec1205fbc5735158a1a6624869e4ca791d95b2fa01b1e1434709014549f4c0998a0574c6711d1a4295b653317db362f151b371a851535601de3d66d03c24fcce8116c1242e523a074754231f3c70e9e2985a5228021fd6389823a48b5aa2a70febcd61aec23fe98f6a9f305d588289c6e3f2522b6c28a94bdb27bc81b44a39a0b826572ea40a9772b9e3aff50106bd77b2a5ccaa1b901eee1d8ea6e037f7815110fefaf2cba69c55f7035d2771b095ce38d13553798c400e2f7d407fd0b3dcdb38d8592c4edfc5e5cece6aff1be8de3769a3269fc2a99d1ecc98c0ffae39313c1827b81d361074f9d1919829e23e20d0f2e361417b35da1eee8849899ed2f199fe -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041c9cf324cc0a040165d93508d7218c029560c75dc71785fa64343930ecefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 38f06d35930bdafb5aa674262c796b395036f3a54103e9e26a2ebabd2e1c81f42b836f00c0d97032cc0d0b01b9748aa3ba065cda50cab711138f82a7afdd718b2d2b7209745248e30f4275a430f45e31f5a0aaa1eb2feb4ed1f3802c9e96ba5ac5503df7b75da937a9af7ab698e02d0c8b6aa5a1191accc32ac27df5022fa28a -S = 0ea93bb8e9b4639bc999e044c328e9991b5986dec71937465695d5ede0a28d5f152cd19cee3794ce1391a2cef186a92a789e46f70d7ab5e38d0d02ada5a9bcb558ab77fc06ab08db51d159cd9648a49cdd7239748ca02eea81e3e08758cc4054e279e1a98d77a2cb9ff77649c84e843f02d61b98ab73788da32b8fbd9e7d0338089ff2697341e4fee7cc72b73093e098b361a76eb0d56072b9bd04aeb05eae4c918027dc6f3c12607c504031d54e456af36be5c711b544bcba137fe415e96c25d5931a4524bff801bcd5f771370d42157ab1304c201ab6654dfa4f5f933aef840b74feedf08a3c8d74ca4de6fe562950bb7e5c3d901a3eebe1bfb2c6b6ec24b44535bd0f89b6ba7ff65378a65781ccc5243a9578f74f90f894447c49d240d6e118e92ebfcd8079326174b55291ecf57bf39813df3651f690eb1c5d8056b8bd50cbac145e909138c37a6844a5b624da4be9d13a988a5c43e2b49d11f035a92a098a59071b26231b024c1f6fad1920c2059cb53838215c6be939b2db31ba595ad3 -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 49da6ae32f9149781533adb07e035a916ad270052b7ee57f74b931e1b30b4b9ea01ad51b162a935c23e022dc5b4be7bc71254520085513d7c6b94d3aaa230956a0a1ad4d530260f94395bed31734d01334813b198e70b70cbe06c3c1566098de71f65b3f8e2196989edbe95c5bc6fddedc71bab766d6ba678627fd3f5ccade7e -S = 1273aec2765d853e0dbc6819df05d3c008cf12a14078d0398ad1c833340e8aa656e463f170324879d99e14a10f67e29b5b09b9dbe71e93b298c61db9c47426064dc5a95d250cb06fdd9d3258a6112180a390df3a82aefabbe5c3083e0978725da87104c50d9e831d24ad9545f3c11eade633638589e04685f671e68a6ece18c856521d91d4d74fda95879ee39a45ac139416472c3a5ba6fa17d744745da2a7a5ca1b2d38e813d2058f7fa54a2787e464a9764b11f7421f6fcabbf982f4046b4d4ef7f0e86caf038265c0f1711b2ce4ddcc5a70b8f77337fa219c1068f15f8533d99e9773313159f04f746d629129f03e517280d3c41f304e531cb8ab3e6c5a097700e9f890026274cf9deb9e80836636b3dfb2133d24cbd7c5174e89ac5e28dc2523b13b4e1031913e172eca410c3ac3cac74734b45f8448a531aca430f0d00d3bfbaede84d9c4220ea88017edea356d19e30678ea5f82ea7537192f10489ff50e40eed9f4f78075a37613df24d5da59fd075f1a45cc9d7a61a2ef8274c0e7ff -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = a455b7d1b3b32ef7daa94505fe97b16726745409dfadbfc9df30f52ce7c3714fee9b6b217b2a58d05338b0815435f344a1ceee47ffbe3b4a7fe707525ea117a229520de7243fe8b3eda1cb2c5dfcff06afac3aaee4c022c8650c0ddceb7a0b4c9ca1268a7799e887f10d1e6fe091dc939936c1a7555c7c2ddac88f3157f75337 -S = b92a17bc07f74204ac547672fd12d01df6888ed332d1453aa423e504c11c4828e500edb7ccf8071f1f98c4b68a7fdbe665a3b82fec5acbde24a0be40bace89bcb59d4f9b83323e6f3cd0656cf9334974b02d437155d6d37a02de832a8356a88f83cce253b4bce850d9c5e00e89a6bfe1ef7215d64b68a259b8f25fab901f5e6f9f0a8b508c554f2b1162ba358fa5270c6ded1e36af3f47c3558523eb1c3c7d6373e4679324481300e8af1737ee62b840001659678987017d2212c4387dd16105dd81f77b40357f607a7d5bd6ce07f7ee5d7ac4cd6d0df5136751d438000b26e4d36585ccb743102fadb674251a870396a3c0c91f6df33af415c196f7de0746d2060b28b456bad9b0c81d22a58f2e9ce06371b5d40a8eb1d0fb98a1610fb734e9fdd48fc553b08dc13dab29328cc3ba552557e2bc4c245c247cc7549a03bd2b616c01e98b04ea835d0f02c6d13939f62264d28aeadce370df07e722057254aa312f0abcfd306431d880330fed7d76337f58eca8a24bf3860a8c758a6df39d95e9 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = d262295e4f40d1ddaecf5fcd56af7b80625a4cd83c64a3ad6d02766fb3ca910d54b98815b37af01c21e5ce60f5c750acdfe1bb7c7933a5621f7a64a801f7c637767203b7947feff8fd007491fbeb40c7d04dbbb0478f3c988ff87ca349744bb4e094818e19d53839eb2538a890a3b398dca733bbce02d0166587a6a7b4ca864c -S = b27d86aba157581c706913aefc77e7ac3c9d4946c646a6f7ff78d4c1c19d0488637c010dff274cedf37014fe1c89d29018daab58b5aada55fbc35cc973290d3f4a7e7c61f78fb3216793d087adbcda38d963fea102b4240a09cdd433086248173f201171ae10014b0c785b5c374c0fc2a38e021f98d78954aefe53244d01cff67b7991ba28dbb1127f21ebba54440d31f5ab3bfa6be1b7d6696445e47f071232be25b08da70ac8ec00603910f9706d6f3692de55d1e646cc7c34a4887cd692e69db28e00a5de8c8d2a618e351f7714c59ebc419231e36d6debba2d3a054ecfb9bf6268e6507aa96823acd635f6d31b6d716ae10425c9661a0a8b7b8797d2d90d27336faa572a13b33dffb81918b42c70c28f0ae88ffc923120cc50ee8f5d9025f71936b606bf44b8d1f26dce76b1b13f2b6c3c5903407e846fce2dc7e3d7fbfd00693e4c25dd96ede4e29473d8edb7532b729010df0aa73d81386c470af3326fb3bdbae500965c0bcc7697e92f8cffc14ea29e5021b56d4f78a668c72a57bf86 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = c9e861253ff04d978781a7a45099445db4fbacba1c821e905eb6d4bd299d87a5a3d436e350dd243836bb20c73fbc0885de9790ebf5b640eef7d5bc304acc4878efa98b606402934dc98a1aa443e1083b9eb1390e36f67f34179deb11635148ccf492e9034307a5be88151fa223b04b683b712d8da5e9e44a0736e8c63dd3908b -S = af1a58738c5900de8d3be297fcd89458a2c11b90532dbf31acb6a4bb1ef2141e866637bd59e7af286f396bffa1fb46e13c2ddf0591df51a8ec29691c03d734ba37727421806cca1650cf172cbca3c60876992af88037e6e43902eca5c2c91ba7cf8a408adcb5545bb4151f05a31db4bfb17978aaba5b5bc626c07880f52c47f2f53d60b5197f4374695ded18f18dea635940740a3c5aee8caa9f01ce9fb02ee9bb66743fab75e63e2233089302044085c5e0ddb723aa142e0ba9f30abeb47782655d980dd7869caf0ca65b25958395dbff5fbac082141bc6cec4f032c60e973e0a6b1421f5126b5ecaf92f4873077dcca2d90b492ecfecb1fd76512ad2726f9c036206bc34deab19dd39182b8616eda9f97745f2e09432ae55ddd6ec683bd366e45668dffad941e7458e01afda6e3a232fb715799975cd9d81130d73f834300f2657112d57d661ea7705e912854676e50c43ace1093ba5bf579627e97e2539d6b0fe53741541487f89c2fac52fc97dd4dfe0b58c9637cbbd84011a80adeb3789 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d060960864801650304020105000420bd0a68c45ca3504eff3fd99a411e4930d50450c1dfaf869af04bbec14d10a9c0 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = b44a3b7de7c8b57126fa95ae13853b28a221ce78d84d2330d242e06b0825e1a8d380dad82df33eb5b82760560304d90008242940f987a1363c888034b40f5c884209c3958b152329fc80e70a0c74e3d2c16cf2fd76ebdd41db6e7f1e3d9f27b508cb3edd8a962a74f9ee71f3b83d2245d6e371dad8e3a1f7b8dc27502d3c0cd8 -S = 7f0b8969669053c26cb0051e0c182fa688375ed6afdd39f7982d88bdf8d422e9c9ce4ab5d1f63a18db785031d17a3286d7cc1349d1ebfd764522cab0962fcb1e071394d00b4595231e8fb7db6d10e659ce8158ebe78e7ea60818d0276a2645cf2dea02d12e9447652259dd12a93936cf2cc0259d03fac70ccf47c99dd8e0b5cc9f90916a961e9b16f9e80b51dfdb38a6efefdb5e2dbd7359a292b89d8aed8868b7e9fc444a262a04a331894a57ef0eb2be8ecf79c6481fa8bee709bbfe6cdcebf04325e98ea156e82a4cb87afd1d69eca37f4dca02c319c3f83f65cb12aad441f8cb92e48ae789626b3662158148a61d8bad4b265df2fdb03730b947f5e542d9ef319e271fa27e598d39c9e6b645b610f96836ddc5523263a98f901f9b47e3046fe324702732a62206fcaf7373df7d987d236574b8b66bff55518ee403ed9e9763e366c26bf3ae47c8f1be461bcc6dedf549b3ea7d5649b5d7bbcbcbbbbeeda04218b861044f3115b684cd82a71be509345ffef5d5326071c4c63d119e86ff38 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d060960864801650304020105000420e3b41f283a3ef951ad52a3dd58c46db1518442328f512485699894018fa1ab54efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 0d0547eee5ac01f37f29f03aadcfa560adbd5b02b5182d23cf9787cde745dbfb228295b7724b508068bc4aee49d3159963779036a1b916035e59f566778c22d0a4fc2be808116ce6066f863c57c00d7c59b38176aa4480a0f63f39bc0dff24b4397cf1c9ce85beec02498c6cff1cf4d23778160af842d3c3404f3c17d227496f -S = 8b3380702deaf0e22ef08ca6c3c9e68616de1359a1cfd5f03968148a837f11f15474046c6434aa2a69005855ca945556c04ec3b57daccb2605683474eeae4fffeb19c221ee5c61b54b0914dc0ae7253d72e6d73b669f52651ff2d25e513e565d3648e6d5eeee63891ace75b924a2143dda487d8076174784165b105663719273ea6b42209ec456bf1f433b117e02e6a5bb35e285618cabebf49a8fbdf046b05bbd37020dece2afd1f6c9bd2fc804ba09bdb0d8aa7af0de45b7ff616d051106f6727415a460a62983817e373474666dcc8260a3ebfd59341f01990e6d8b7d15092c3d7dedc2d4190d75374d138bb414610834d48c9bc23c43d1ea96c7e9294a2d803c26a427e4a2b5f86f19bc7d10da9aaee219291c94d7a3052211f6c5b739168e544747b8090705a63671df1ba7a82d8cc5e76b5475acae66455fe377cf52156549d7431191573f60ffdd24d6640610f4515e3801a526d49fefc2d1b59456e3337485cab9955afada0ad5e33deba6944d98b24c24731acc54b78ea1cd2808fa -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 9802b7acc01de6de29215e2878ea1ddec20fefe95963e56ce5c203a7b60a391b586795ee68d4b692a7de84a24dab1e0ca03c1475c4efd7d9d5486d7233f069dc1dfe1b768276040b130f8cb29d3af8f2965f962af66a3a304886ee390028e6f90f50b20bb50cb792963de021119d91d8cd01ddd094dcf8ba6505efc2c4ba96ba -S = 99e39af2014f011fbb413ec25a428af8ee4bf6f2adb3fd20964d551ad8355c46cdfe35c955cff611d299f533852288ad20b901d80e048ca80eb3cacd83e638e15953413e3018076e91b1064b2c0d615c8bd6b9098f7e3b6da919470636135b926c97124e943e987355c6d71d683136c8fa9698f15c0ed3abf9ab7f03f5e565f1f1b1b056d7d1ecbbd1d7afc5a45bce19984c8ff9a92437d832f89f0cfc5700d18482c4d63376fdbb851ba2a1f272df06718faaba2e9e1c8ee1bd3a3aca58a02aad3437f89fbfbea5f12b8ebc336b8dc942058c80e099c60ed6ca6ce128faec8343aede16c44ea97e1ac1073e24f5499772b8abdad9c8c33922bcdac1068715c74f4822b4e9109a8020270997db56299052f14132a1d7b19820e380ea74a68236de72be5d33f4e89c5fed4ca643f6ed7a3f505aad27a22b6ff694597c883896fffba2ef4fe81cf44cfe342ed6fa127cf31c58a16a5a35919cf2cc3adb47c6c84f660bd9e2dcc4b8b29beaef329affd4b5cff2c59cebaf3648624485c4cf94e9ec -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003041300d060960864801650304020205000430825058944465183ce7f88365fe96cbadd70cebade9f1469771f0a1bb5ef6e86c4e3e35d2a34393aad10183ead0436783efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = b438d4fd3a46058f4eecae06d9bf1d43c54eb5ebb504446bf350903aa902335e55f9a93277fba8668ce4af474003e241e0c115a20e8327a0b8d2919e4bba3eab236f9e4c4737f67b5383faefb55f9d9e1c0d28812eed89977aa1ee2cad6d935b08e4d8d211c197d58913b4869f9df663637c15107d0a14571f03d06d38e6da76 -S = efe705f492c2f05595143b7d2fede01de8d4ed8aa6730d5db7540d9353bdce15cad57eef7e66e98a0fc3d34e223be094c5f60dedb8c89f5c3e4f6b10f5d41415e098741bcd4324558655b215217582daebfd44d2154748a707d2219f68a1e9d97a75900329dfc0d7a28b1929775bd37fb66524945b6b86635dba4f2e7a95da17301a1522effe0728edf148e7007810ad509d8d541e6520b83247052e9e79a84746f11f469eb4db1446f5dce3519f09d8b4f154b0f3c403d23a37e89aa68683027b76fcbdf373496216aeda698b2fb8785e364bf2bd2449277c0d8420ceb2c157f8663a35c02f1c4a4aa86c7753ed755e60c022a4bb3106da295f3a2a72f2c861c619b8726f1749b9bae639589b72e9e34eb9176608f2a38daee1329de2f28291216b8c77a7409eb5c1d7e351e906f1f25a26c6df4abf3038658f7cdcfa3e1fd611efb4cc6c5167c4f76e2100d02612e12d2e696c80ce977e7a150e477ae0b67af577a62a6b57e6bfb9ce19f56979008076c73f018e5479de5c69bf1ebf5aca53 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = fc06f66ce9cb46deaf65f79666dcfa90b09d1e2fecd7e2caac268767696f6ac6760b91a233278433836a5ef780d923b26df854b4eb32c15a707b9fd7f634da34f04fad9682b36fc0f1e2b0d859d9846e9e381fbaa4a2a225c367350c756056c0521b70d13f38b08ce21314c259a4c5cb2ba3a6cb7eef2d348b30728c50bb8571 -S = 6106401f71a67b9b68fedb23595f45492fc7eec4557a00a5638aae54d3854dbd87d2f66eb94cea8c02f466a85983a37fd202ccad8892eee14e3301fc132c530b36b31383739ed7a51433e90cb7ccf1c17a0a512d249e70a3d51b7dda16680946872856e5901c726d3bf2af49fc264c3c6a373d9135e802a8ca37ba891c9e13c21dea83ddd6c55c25867872e18c0a726d5fe6dd3d6ddddfa0cff7246a63dd38cbd738945afbb3be72c55cc2ef38f56d596619970312d93a9322098601193d1dd537e1041b46e8ab5d67b40a069b4153d365742a32ff81defb4fd00782695b81b124959d33c29e88a1d911c4da17dc32d41c1b5f1836ae1654d56feb9a55a488a2a97a92ddfd9c754713309f661739cb2baef671bf41a3e74452690e0131bd3a3675316d296d696b0f07a50516897043a5b2f090bbb618d822245f5fa5aa7125551aa988ffb289e8804bd5149cc8ff372496a5071ae7f8583a8755effea0c6599116ae5b8a3f94ef2f4e6d440c9304d6a091ebf14fcd8700ad5367a21e6e8105ed -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = c2fd970b5b17cd1a58dc8423f1354f7feb5fc86a609c7b59c229ff8e1d6f66e99c7dd8014fb67a732bc7947a53ddf4c096148d743832649df595adae436a305ad820f2a96c1c124cc0aff12edf45954ba3df50c57cc39c346d714a3e57dadc697acd2f2c39b25d4c1d7ae1661dd6fcc71da75884b4b6ecc832a61f68e22730bd -S = 861383c21c18f931fc4fb352d846e725e39cc117c4324952344cd007b6a00ccf08fc79048545fab5c30fb356460d5af25a63f83871dea84d464ce4179cbe5e6fd09a384c45ad046101a9460238eb3f445e8911970cb9c43d096f70b78f3434cca05cbf8ee861f6bb6cee9e123a24cbf6ebc5021d3a9a55c7ff08c6bb274a7736f34fa7c04029c246f2c70751e51a4607484ec87e816a3a5c92c06a10f512709fc4365a7c80941109b1cba4dd7ee79d4c3f851a32763807425e5b7583d49e97f337f270e6387f99dd21d62c9db52406d3376a5e549782625813634a8fd237e7ac477355f4be7e05e2a9c3cde9ede554026ffe1ac3e8f545a4d49ad39c2aee4b52c45440983f25c276ed58ea5fac719c5332655113dd768d93311cb6dbff54357f40c23b4bb9c20c7bf0525150e71e17e486eaec90d2263c9758447bc02739a14cb7c3e60cf376b9326a861951d6d38ee291e59219757a9de264cfdbd4b4601b8413161b927daff25504e0361f6669af8cea75f35969c910c3c5e1890597931164 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = cf28960fc5ef7fd91e051ca12516ba961ce953d48492fb3598e97a6a1b3a3b4b533e656c564a47f184c7f9a355e240435584b31e6c851ce1631d21afa49b24714159676d38ef741bf6a7bc3319317e0b7a98ea206b7587f23d63d21606b22886a060e53bf544cefe7a8dac7bfa6b3a97950c410308ca02112fa3d4c7c8e90e33 -S = defe54ece1df4a9e2f9b2ec712b2047be979113674458c3e1409777a8c568bf43b4455fd4197ab42fc514e3595cec0d46f3302cf556889820e1c9cfd38c642ea09adefa815727b6c06b2a194e095f2696e35f3611c19129a86bf60b11799b6587bef89082a631cbea67fc4d77c7dc998afb8caae59e7a63a5792cbaddfad6e3bf8a0d0fee650b7a9cd502211dac3743642075a2a563ee20c05393992c776869a6eb4a206de21e72ec27be193537a32dfa65831bd13c66f6aeb2bcb6239ef31b2d7e8deb309be4f639c7ef9d3e6147e15a8a9dbace13315a3267bc4ad07ce02575a8b279b37646b871b33ddce57a8170c422474c2aa5bfd5323288753628562f0afc715576c027f7f125793dbbfce3fbaf79fc032bcd9214983fddf1d3a083819399c107e2913de535dfbfb267cd0e0602d6836a902c6589bd1f35dc07146c166d26592d8d52fca9a82340c0da7303602531f8144aa1f704e66380e07fe3c54e13b1361a427531a399616b4ce74ee9633347dd29112e180c5ed263c0153f3500a -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d0609608648016503040202050004307d7ca11cef0aa9200c55b78df8c91c41266ce955d1fb2622cd36ec797f3ddf70eff54c77a2904cfcb282cce545a31094 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 835eab9bf266d49ac4c672c5765511461a3261dd04ab8bddc75ec577609e253ab019b2db30b7c132e0c57f868052ca0a03d945a74121abfcec6263a4c5a955b70f7dfd9344c3bddc08df78c15b1c5c81124eff2e88b6aeb29125020faf64b3eb89d4b14b9852719f245d85ff6f7b70b430d8b8fa42313d049ef0c8418799e7de -S = 7f96dcefcdd212f01c585dc3bdb38f3168eed84c77eba3d9c5e052cf84fb059974ea282c5d5a4773e13f4d23206c3ef731dbada06ccb827a75c4002a267554f2d2290e2cc23791f8db52aaffc7e2af981f9ea55d8eeb9abcaf379cc47dfa54d28b59686e737e2e4c3a4c9039ddfe637dff0f1ae77ad9fbab078ab9a81259785880890fbb32c70301877b6f53591862f45463bc7c25da257b8fc798f7d3d115d6a7b2228543b81e768516d8f29f645165c1378623c3e32dc6ca08c452665038db2ef5ee432857e60eec20c6ba75981833cb78c8cbd18bc3243d4959ed8ea4e5cc3102e1180530fde85e837188e029717a6c9444265d5bf297b44bcce7367e3579f09928e97257f48f935a869b72c53be1d3eab08dd10cbff54bb099d2e9a2d3ea9acaadd2c2e7c0ab89f58d265941eae9b1bd31d544c4baa8132859869284154b7f9b99fc98cecf104473437cd6960a768f044a655034403896cafa00fd89b9968097d2cfc90215fb1b6e068c0cd6224aa5f73013e1cddedfa80d3dbdc0bde0b7 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d06096086480165030402030500044092c353394e0845afea273cc4747df99a1d7a0474ab8902f073a0c432a27adbc8398de33e7d5b73c3cb4df25e6067981f237b11f009d9c1e547af65322d32905d -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 62440e53c9081680b721630cf3071ed102fe0ccef99906c98f7ca93876654e62ec6e3cc28d8c1dac6b5caf33601fbc49a3024c289aa419f1efd24393e69545efee6e283a76e0f7a2012f72347d6806fdd0a1fd6fb582f307c604892dd9795d5c90cd39822c0b8aaaa22214d8f1eae534b262876bf13c7a533b9be1cef81b7cf0 -S = 646d7a66aea8b4a22f75881e6647ba0f207bd5cd15e019468138fd126e1c7f660a97aa55634646cd8e5e584b6bc29a4cd213cf222657ff6526b7e0ecfaf56c0a90ec4f17a297b0f8523bdf39cc612757867272409c65e8b2eb463cb134560d021f60a81ff4eb08aa97cbd6c07cc3b32422442724029be186995c2694ee4def6009a7a1a8b3c9eea48d634ab3b84c0c9566ede4eddcc5e59338ba5aa304502c637f9ecd0b707e841d0b7befddef4fe0875809fe386122882ab02e9d06af3b9953d8416cee296decddc3b2e36329434f567d57330c418624c5a70cf7611552fc2fb420af0ab0ea2c6ca4b19a0854e6db10662a7fdaea3c015e53524617cc29afb9cfa9065e1065d95d288f395402667caf80d7b4a3a91f5b681ff10518e5c01ddf0f20c359ebcce526091164d5718cb49b9a42bbb57361865384e8e2e162abd7629b1fd242892d5164c012dc07650c70cee79a2ccd13f424b574eb1f6cef662cde18302038bad6e100a4e7b949b9f1a87de5a2d6352ab830be1138d9b83c4f8992 -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = 7c38bdb32ddcea204a99b5f953ff3d6e0adbefcdd40804f661884a0f8fd328798c6fdc023bc1085cda236dcee137f6292d7af8fe5d1cb80e7d0f2e02e25e085c54c0f2ae736d15095330ddb96abd002fac46bc3ff449608ca6ac0d40920bbe001c51861f9a851911fee78e23b53c636acf66c2f95f370257258771316a84514b -S = 0d07f7c0cbe4a84df3fc088750c9c503ecdba6c37a72ffb15a2da05b5c99740c894427cbcd6cb2c8ee70f35175e70f226c466761356e07009ca88752ae2cff5d7b2e7f2da77a36b68de59db7f5182abe88cb95b52d766d721b5fec504f6aa7b9ceaa9dca1241a5819d4d48ede38c045d625442b27b8384dab964616885cbfca944a747f024032da7b3a3fce0b02254e08c8b9e48646407e69aa317df5706888fc13f091602e1affc23f17cd50ef4275e321a102c2b066975ee8a0dd3111cb0e88037ba98ba477ec67737024ae92edcd7d944bfe2863336a59026052bbf2280d542db1cc70f06a9509805db6651f795b0b4d74f94fbb06d2d4149321f9334f5fdba395cd852e46ff2ffecd063a96ce5d2d5b15cc075c243b30be7a260fcd6891ee3063fe3898037c79309fa043fe210974a1ed96c14bd0f0db1055f710367e55d702ef3a9bdb9215368407312dd415f420bf0a90f67c53c9474219f36adee08220b0798d14c455e57ee8ee47f2b8c7eaf8d5f8474a9d2f51d49a785ed4626407c -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffff003051300d060960864801650304020305000440a780cdcf06d5af7e658c9a0afab551db2fe1c5d86b54dfab86d5c10acffe37c4c8ef7b65dc13a26c2330ad19d34f1065d99ce4376e6b9886cf30792e9430de25efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = df8787cd9718e6bde708b9998cad4e91c7d58afc60b719efeb2ac80f4a152ea3732792ee74c809bbb44fdf397b753809b409f796f2e6dfa5b223f82de08935689c4a532a3def047296934d3e794f2da47af57f1ff501212753cc5604880369e3e058942afc771f09173ccc518f23738aa000ea4072f0279d568fa93d4c6b143d -S = 8407b86a4d3715092fcb38c7d55a528182cd6cd94186a86cc654bec9be3d472ba908d5288c1393619f1a4ea1322ae01d47f321a414d0cb1e00fa37c71364319b2e3f6935f00f0b5518806e8c21504b2784f14c739d186df08091139a911d7c8612b4ec15f17ea9f069898f4f820c9b8aeb5ea34aad293637c532c47b9a258d633614afb0cacc5ca475fd4d3e24fd25809df22f14c20289a7808806cacce46eba40d33f3392e72ce6316ce02866955ffe0558510b26c303c37c773f387d93739b77e053d896f078d0487cc4085712e2e5b42a6031e3d01808e94b8219304a6756233dbab0a2f133d088e67a2cd4392f4d688bf4f4ac4ee9a3a099f7389c5d8ac5f09f55cd831cee52306727581792455ff2fba50592a7b2b686fe4e7444866a2ff69cdd68895f84a1f9864b7f36c6ae89853adc517fe8b9a8fdfdc78ba03f91dc582dea4fd387858ff90dbcf9cf3878632b5b8448e19a797485ad4bb9d2c28b1e7ac717ffd4639617d4d4ebd44a556561fbef00e66b99c5ada41bfccab314aa06 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = a24b2fc765c9953c545043a7ee2edf6c1887925c6f5301d9dba67f3a67348071501451ea5bc407b76c6eb6eb5569e343ec033b0c607e8540cd58d5f30dd002edd2a55b99f121961e015609cb25a81db8268bffaac58e98384f99c02c7172ae2c4e86b39acfe729b83a91a61007f17513efa84600458c240789efa8af3b256c75 -S = 960d6a156414272675d2c09a340d9e053e96e8ba3737ebb8a11d4829ec9287e6997594549cfe6e7f60018074a90d1e89272672f4a464d969ddf7b634a34c36d15b16c542911ddc2805bde86b5716b8c8e9e2dd81133ae4d70469803dda409e8e8f6c0ae0785652528c02f49732c4d2dd6a33bdf93c17ce851e8d3d7ded4636d63f34f4fb2e43531bc61d2dce3f60cf2e521cd5cd7a5f19c35fb0bad328975676fd7958bdc7a957d0c1ea3a30f9141a39b67e101c9e9832cfa63b4b09568d5d13f50ad24af42d4fa9b6a0c3fd95be4a4d7efbe2a89fb7d675054fd5630c120e48af7b7caee23fe5ba2dfeeadb31aca63fcc729e4cb352315cd06f8e62e9b727b9a8b8ee179c69afd09b4d5cf5a8ddb281607374a526d462d40ed43e9197d871485fe84f8b07ae7ff7bb411d128b9a63cde123945201873f5f257ebee48b0bd68c3486352530819f0b01330217e4acf76e43f676e33bc803cd11cca82d7d0cc0e7c14b58c65300a877b443bef4e75d3ae079e13b4719d2993dcd3f90d234956b99 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 04c4f6f1fab0aceabd3acb55e65cde8e827e671e60339af201352d1c2c1677758dd2b42e54e8f7cca6c1e6038e47b7603086561db3aeb25d73e7bfc8a5ca27042df99119d7f5ade9b8d3a03ebde5783e915334d460cd1a7dad1bd0285b454150248ceeb366dcbcca68a14e7cf660dec0280f59f27ef0334ff4eb5e2e104fa6f7d3a13f312740a3ba0afe61dcc5338b1c3256d81b7a722c2453edd8f5314e30ebaab9fb5ff157f8b37e1c4245d72d82f0c53532c39dc891b4342682f1c9a8434b3cdc5da460b174c948fa20fa960e53735f4c9bb7ee77ae0db7a9d0082bf3b2b5d80ccff914256809abc88c697d3ce0346455be8cde06d5920f74fe841d94bed59dce7f2b96e5d708432a56ac6409563c93a3a8ffe3c1cf9daebb9bb77405b551b13a40b253a819a3aa0164cda1979bb859c2f63da926cbaf3701e30efbe721ffaaa3317e4233d51628427679cb0c46556ff2cd4d6f3fb1a647695edd7601378daf8b27b7f0b3836586b9fb1d30666c06f494d0f62ca96b7bf0f6bce76395a009 -Msg = d8b0d39a21a7b7d11541c35ba83329b6320896e86f165a13cab1c94adb9ee1a32eca2d8d463ce864e14966437e07b01a1d046f0046370bca4c3613dcd3aae03f900075f45062aa883ce68ae95b05f978584e9a5f865bef252105c280d7d4c46a86b9757648004365ad80f6f447154bf96c50dfae376c4f4dd0849edded04d74b -S = 2b5652f5be8741b03959eb713e46299a62ed69bc11c1e774c3683af9494e7bb8e51bc4e4d8de1e65fabcf1b4995ff065612fb5cd1812ac7a2c1a0aca8d76c66a3dbea40f426d55a6d60572ae28d3444f059ac714b79e9cb1b9bf443315b85e872a4e20fc69ea1b89c01398b1dd528de6410b48c141b1f7e70ac888393b81b20a8fd6add6ce8a423f4f8e57c6860cdac522349b9215e0c1b25c78a7d94852cdadd5e3f0a4baf2975b60a17cb0e3b9c79060b4ea0eaa153e1500cc05c283ac300e3da7b91aecbb10a50e86a1ed74120a0770d0608893fe6eadee193a20d920291c71df799e620aae96b263f4567962fcfaab4caaa4f06d9d0052a5e2ed8c2f62328a973e2f39568507f6445c7e883e81858df862804c419e3ee5c6bab1832521e841da32bac64a4d89400a2f7d447796f441d3784df53187305fab96ea4faef0cb1229cabdb8cf07c9177b8ebd977c4ed6f260a9b9e97d5d4918cb0370e71ca008db73913f2d519b99b376575a808761dd144d74fd8a7b68f38d5021f8b0533e41 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -n = cf92efc93d89c560e4cff3e81fb72672bf010ae82335c342ed80c0eace8fd0333470dfe2d327f9ebe0ede4f39b0260144d1ec783dffda1f883c0a41cd21e9244d1ab2e4869d765c7e1506e5c1be03db067be54e887daaa13e0d5122e872373891a0480c56d8ced157d316a8ec314bb9f15fa49c0ffc0d78f913ec2dcf354bcfdae2bc031febc69c4fe9c51c05dcec9c1d3004dc8a9c62234d91e4dbd5f9455d94814bd6feef8697efdd9c93af4a9b1ca2e9023109905242eb82977bb4866a81220f8232558af67296b34a19b818e5c07ba53b6e4b270ccf67cc7149c79bf875fff248f4f6f86fa4e9a10dfc162b4c4accbd5f76e4afc89c5339a35f960c7e5d156058bde8c9a49aceb5fea67a09325348a8d573e304e9d133f77913c785e5725d615432d6a258dd4038011a7e19369de19878e945e9d4191148550bdbe5bc22aab57703dc880c3bc08c2df1327ebbf5bb9c2e75082e998dc48685511958c4e7b895dd6be533ffe84d5aee6511480e6547b89144136b8aa41c6942c00f5ed42b7 - -p = ea7777733c9695e5bfc71a4de384aa8d9556b620f13d50a4b3523d95efab4c5c037fe788c98ae85b11b3ae884eed6f3b8f5bcf5ab1b7b20ad3f44f760b2287cc57937487d73c44f4395d48ef746548eeb9101a42a6d27299be78fcc6160da8c550fa46f9cd7252b91f0d110bbdb3ddaffbbcbc60395538565a266b0f78325a4fd5fe846615f5bab1ab0b306392a1d5853da8e03cd00aab4b9045c5d898594373cfe55654169f1c7eb22dc87c7497db4a729b27ab95cccbc4f44bb8a51c0bbba7 - -q = e2a332843df5531bcd8a06e30e3cd414e9a201b2e27b610f944f6d915a5396b5508eda547a3a9425426d988428f87f71b58f40dcb02b012095ad2ccd43c4c4aaf510fafa7388fbff8a190dbdb98fda002db90ba0f0c819045df960e5d7747654ba73baff92a630b08bd78c1629ca8cc839678b87081a54c3d27b34617d2a53bc87fd43ea3e5eda402fee3d18e06f3ed1c2e0e81861e95766de7aceca9fb003e945f8bd43de9f1edc154241f926e5c761109fa4e9cb359ac778f0c6f748fae271 - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = b04cbe36549d4a58dd6ecf23afa174b2c45b9f664d14b8939cea3178403bc3757272fa78b021f3b9a75165a75616de2171664fea032acb5758968c4b1ab63765ba4a607811d4513c48ef0743f5e27e2e86752f20e304d6734fd178aa8f9ea5a74f7cfb1fc1deeb4a87f1c0dfd330dc3fcd3345f035c7614e4944fe7de91b95a2 -S = a4d1579f4732ce97ffaf6852183ec36900945fd9283be8bc50a1dcf81e8c4f277d5aacec934a5fb6951f97efb5636986e06ba302e964d118cedb83fb6a308772dff6d77080ad390ea8e8f401f5e2ab4feffa25559e699e49ce08004b15c49a7915f28099aeebfcbb3d22426a51caa71097fc5fbccf0cef1610c17cfe76587cea2f6a04cb7893394a736fe2d9b4b72093c5109b086b6f2301b7dc7bbab0cde72828407175946cc275d17da0fc63da6159492d70a341613971926be6623b262df63f1b9c9e9917622f365ecae401123baf3e33c2dc04555804e2b6b3dc14ca263121a510ee44c9a4602c005956f1d41e0b6c68ad78200fef0ccaf8ed668239e196c55e11fa57ce96bf8457baa139db776a43b98951b500850170bb57ec17cf796bfa73799d48b24da7fc85f828a6c1287459735b34148ccf84de1379bd2c13b8cff140ce6f8140b8cb8326374def23122b1fe8f015d6b62be5d99a04e62c88e3f611414ccca66193fa31a51cbe9c88d85c9b3bf6802ae24f4f4263a7b92251a82c -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = feb972fee487cdd8d18f8a681042624f51dfa8639f96dcf693ee7e5cc76420a78e54bfb5e21d536d9e81a545ee4a610703336cd60b05776c6001d5a5ff7e89413dd3a4e5b577ce648567223dbac83f6508ce9b46bfdc1b07faede10e193266c372fcc89744dd6546ec0aa8585c0423eec878debba263ef51c9794b9efec8dcb6 -S = 879feb8b92579291f651e8b476d5414e46ebfba0c85b4907a7479d5327c6f582356ac2fd6dd59414b9df5a465a24cefdc39f19c6e814545745710c9098d15385c7823996cb6509c20e359dba1fa6bfd5e22b41aae1a8de26aff1c26427033f6b3d7f4f8c28a3e398c52c8e5221785f4926b9230eefa264b1684d598310a6e09919409e34a693f3c508aae0d861867fa680f0712a1b7019c850b00216ad194e80357a06a995c9da2bbd9f2189f939b228e5487ac83318def7dbe3752c656653517e475764b375f54a26f848e697aece0acba9cc3b722d37fbcfecb40b5a2b7adde54f02f9fa0cf3b2769ed2d4f81879822e01a289cb9b632e15a9ea45e09e962ee27964992f3a406ac9c72d3d0f97563e8296df97d7ca6383e6643d0b499896768846023f901ee0397b229ccdb706701ad048a7d7f17c52b46fd9288c4a6f5d47c0fd6fb55ff74299ef8b3e1b4c2d72af4c24876b6f68bf7ec74359ffff8461f9a9893c9157e0f022e0453dbb87515d71d64178044048c6e161e6730e23e79973 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a05000414da0d47de632ee4adb50d8031bed0027c846d752b -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 08511714a11c3770946e03091a2826e5efaec9a10f9870c0bdab1e42ca07c07814a1c8184df4198dfef42390cb444ffcf8a89dde2cbd8bcc75e83a798d8ccc865c80109abdc061b48562cbc0c2cc706940252a2f520972b9ce81816c5a32b43ce6d435c27ae6d88f32a043c1872a52d4cf0bbaba07e4ec2dd15e3c44b9614244 -S = 136b4e04197fdc938eff67044168e7dc31ff57b7885d9b41df0d3efd5251a5f91e641b73cfc7732ed326519773c6cc77648f2db4ccd056d52f7314e3f3009eed7f2120155a3566a307cf268adb6c004d435957370dfe06570d626c75db422915e34aa53707ab99998c6d8c0978c0dff28585f628a5077873465b6372bc24a9374fc6edbfbb8cf8833e51cd0cd9df4d3edf0a59a531811599666a2617cea298476300de1fe3e12e45a861f28e66982ef0dd41674276779a92ff9307eeae1159e2526641cd18eab80b43a83deacb075e60864804d9da39eb1cedab591906d4b428af9ae9451c06e6a3b90fb3999808a93c883ac59f80b4d1e3a32a824d1affbfe6332c7527745bf8272ca22bdd508822a655e0e4346343233e1068bdbb866eb512bc47abdd8ac777a2b93e12809e8576b898f97a341621a1fed89db77449b590344e8147d0e81beaad44f74abfef11181c6ec161e96045ee3d0f7dc96c53c6baf7dbc385dbce0d6a054970987b392db1f237778dfb667ae9a4f7133c3d49e78e30 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 5f474c3407a08ec87ce50ba52183d2b605d61768ace41d03134c593aee79d401341bd19eddd8b003eb3e125ba7fd3ee32d53c3fb2ac75f7de51a204d7c7bc93170fa77e3643f8465227cac95dfa06e01c0ceb5fc9d0db8f204411ff8815a67a71ccb872b243dd4972b85227b52d42cb9c72e36948b1ef00a79a79e64847d760b -S = 65e8cec81b96a92cabcd2acf178afd01ea7ac429634804dab05faca839e1dead2387a4a4c702863bd0522c3a6847960f604bceaa5b56cc78f1ccc535e9c387c70f929bdfb564da2c4f8653b74065affa5c754ad6ffb1be0e02918b1e066f14e5abf499b75d176106ac67b6d2ea954eee902afc8816e5c9b143a6820c4ee4c8ab76fc20442bde40a0dcca8f64de6955df646e3790074ae0d11501242d6499022eb9597eb39ae68f52152f71e5b1500ccdf46dc8909dbae8ac5869d21ef30029b0bb3881df988161b7dd3f80d9f0a9631ec6e95a33e02f2e3e736c086ba17d7f803ce670ea9186be3da26e552d656aa915b5f0aa0fd80e32f318670ee05d0a52a8ddf56bdfdcf1f413b66f4d3173b8f6dfbf8e2434c467f6c340b93e597c1cb2f114e103d7c03973c6d10fb357b5ec91e47f03cb6a794f8b4c3eaa6b2be6ea9a3fd34417373aadddcd9dccdb95fc71a639ea99e0641d5aeb63d59477b8b8629a4012e35a3e167ef445b085403018f7a2c731b88dbb843c3cfca5c367d29dae8346 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a050004140221cce979dddc3f07b69ad9575641e343384e9defefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 23adfc8012add4adaac91852a169e42d92552d70b56ca413ed98dd6e0901b1074381e1a90d59fbb60e2282bd6706494f3a2f200f6d80b209ab83ae45aca3259bb79c34c8652fe2c2a71a4b490a47ffbf3a44a539c5f3e4d622838350f29eced085e43c07a099507a7e9abd1d1496cd249a7a0316462d00235b7ea3b7625b744f -S = c789f344e0f4e0c291bee6336b3d7d2314b0fa847970df318ea8ebba2de399914ccdd085ca5c48913ebe9851a29e40545db646d958b9370e0c59b249119b67efb26cd864e226b289c62edda506560ae976f764d575515483bd13093b28ee85d4ea62fde932d0a77dbd81c971e7f4386fb79c7f4fde362df166255e05bac5289d8f74562be2daf26513472f472b68828b402c4570a5cb8fb027518a29c3c78a35a9fae810aa6aa2bf0333850d6f71eef951c4c7f315f00be29682121e471cb8fd05b556e995d96e51d4d56f0369abacf234d19e43e737467c14e82e05732d521276b81d8a75eae5a096692ded6f5b56fdd22b719a3541ff98dca661778c25f6188c756543bca8b8ef5a29bd801826fa613b349cc24e69ff4017805e181fcfbd8e947a3d38400fea81a18cb8c151a304e6e39c0e86b57ee0d0b1acd7c052ed94818cad2a6e75de2bc7c46fa9ffd9d37b9ce05ca53cdce91ae58bddafd5fc626ae71073b1efa0015cc9df589ae73cda5563f60774fd559e565250af8b9f2834d2d2 -SaltVal = 00 -Result = P - -SHAAlg = SHA1 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 94f581408cfaecd499c20c50ce61b30fb294b95bf1a84c79529788e7e97547e18e0a3b298ec13a08a0c1d8901a593b2564a12b3cad5e6961de27427fccc6635cb2e1ef63dedacfa6aaf34a23aeb6d54634942cb0eccca137e28eb42eac60e5e6e8c2c674e60d54b5a1a18790f43f287b0ab4e34117b89d024515087bf20c7487 -S = 2e43df8eca870c60a75965eccf79952b6251f216e8ab745226963ba9200b8ba9a99f9093a5b3df5f64e496b73b8ce077b76f4badae288c3e979796f88049ff2ff7cc0401b0f31c48487d01b4ce4854c4f5afb9cdf7b10ca196b665efefe4be742b2db236a379660170c3f684ab76b69de13a3053c403e8e14394379a0e1a6b6ea6ec501e95c17d6c7c728e08315777d29cbafa972d483d7e7ff5d9b97a8c7606300a03e57b92cf727cbcb6f14ae3c22ff2d417481ffc180a378e4fb1a72efeca8231b5fcba6b1561659d8ad96dde28a2f4360ddfce2c598428012abb2ea530b3dcfebab4e3b550cea5894deff740ace9ef4bfd42337cb2d186d2cd05a27e35d37e04093ffc0751f80ca4ac2c3b197c9cc60756029ee0febdbff2c9cd69cd0423a37fe4560a1f8805ce591455dbe56bef0cf8616901f682bfcc1b58049fc8e3ba40f28611822413b1a04d5ead7bf3cf0ecd94ef6bfd4716f1b1c4d82f70ba8e71de91f84b804512dc037bc17a3de87a74e8c37ee921e2c1a03e7cc9768e3059dc -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 2456ef08c07fc1ec469aa9c73b677af225a9f5f6f8d0e150d1d65e71e6677609bd44f5859de97ad6436ecf75d5ab76a41c9f84f6ed13b311e87ab2b3661cbff3ac7378ca65d5eed14f54fc4c34e3d7681cbae5c1c1fbd3274395e2a21d6881b358ab21ddfe8b4564d215d8553e56c4c68dc1c05f5ad1691a48ef9546f495e4d2 -S = 0631ccf756acdd39dcf45947556f56418b598b25512f9851ecc826e8e15ef8312b12896c5046736df8c36c1e80d43abf9dadfdecdaf48b6a79a09200008695e2c7469c837edce5bcc6c86506908be7942dc6e498f9806a921180cd0b997211afa495d1de016a1b98ba5aad0ef0b0b1f1ac7c8dd5feaa44ae69f8edd6fbe7a4b196ff96077090d2bcc05a675bccec3ab7d3b6b63adbd97626494e57d03ccec82a4ebeb2641b07228de82ce892e24df312f2df624235b00495b444232c205a5001c0db68c06ef7112c8427ae0d563b53b16f9fb1bef64e59cac4694884204f3cf3022ee2471c158e70ffd552ccd582f92eaacbcda5a43d4e4d4b2e72b2193e34b03b9ffbd47da3c0482593440910dfc334d74fc1d0dc11e74210fd31fcdccb7ca2d01931ea6c75faf1f7a32c8115b0661ee1e3457090b97cd35ae36d34b06da17c047e785a5da9d23c048dea4c766849792ae07ec95ffea56686fffd71fba54d44fe8e3d2dbe742a97acdbd7d54fe3a78d08bee547664a0f1dd1544b509b5d12fb -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 29fd9ed0a8ca9609d8e67edcffcbf733f15581633c2449b1a2414115cc04763e3c359fd58471f106b5cf3b3d1bc42e2d2744fc17ad2a264950da8ee53a25d4e3106ddf592409bafaedeaa2ddb57f5d8192d7cd0d9706c4dc4bc91a385a6dfd668bec89e4f25a98ee677fdc4637c62b35195619cd637ecc727d560c9996a39ace -S = 71265c24f74301a5c2cb797274c15af942ff4b98aad737596c4195fb698a69396cfb5e967359faa0f091931fd0ead53859ae16c1fb18b071b20dc0e8936b58a6dc8eadc773ab583525b1b9c01112c75acec69221d5a214eb2295a26ecd476ec37d8f2ff62f7dbb7452f306d3c4851b67a57fe3e6d7ff98489e47ec0768e3d701f13719f0d8f11281ca4fd6bc1dabed86c9d51fe187ba5a1d3187465e2181e4fc76cbc0ac42f287e9e4013dab1926e19d02bc5d7b84605111f5d2fd63229cc27d8a0e3378646d90a44726aa6f0a528e86a9b9ae709aec1a924400b67da5fc4d2cf307b810e66bca0120b659659882699994764d3eb992ea3521f40e8fde04af2f84e73e33ae5172f969b05e11f55872db50c1d0287bd331850025e3a62c25c26deec2605a4012c0c7ae8454e3c27ba299858930f3b384188c41b5302c83f9032e45bc9995f3ec5b3e5de246eb0bb791afa31523277c26a590fa67bbec78b7934d876f8a8ade9e12190411829625a845f0cfa48bfbcc0af544a8952d52eaedeafd -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 092a5bc0943f3cf6a6295b47ebfa4c872f57f1a10c8a4040c6d246cf73fd6ca45f39fa78ae28d91b43329d65e11fc37090e5360443be1853b77ec0e79e24ffd8fdafa842d3334ff6fb2b50705311140a1e2c8f6fa7aa0d5128ee2f5fe92b3071ac326d06498825f196bc7d4f89f7c7bca1d503c78173a6a3dfca9b1f9c3b88d7 -S = 31e1288d0923e5de3feb553eff8781fcc91fd118f13e2c931e2ec8d3a102344e9f2069bcd3e9b863911013ce2e6e58948123435fdbaefa122e8393cd84abc653559b2958d643ed93431639123aac801ec52578b8e8250d21d32a7edcba7d639f890c3675f664db36fa859ee340d9c90d560b6e1b07a82811a0ac875e0061ac86ac352d33c1760c3ecaa86977efa971f415e3c4d878e5c4d6cedf865b048d78359c1b063713bc20f89a77962998f253920855f80cdfa21f54cbdafac23e259f6de785f8b298aa9e0363a4f098ac1136b036f40c8ccb87de2751ebe4bd4791be851537352b5e813fd1f82d3042853c44fdf645d47dccf149288ebd41b4a583a8887fb01ed1dc7cea237a53649f62a94e3e1724cd409eda8194d39c047b58c43b3210050ebfa39551a4d1128ae519ba23b20456f0d5ed259342f71e1a40d3b84a27afa1d26a1e4d3e365975e9e92c52802dbde13a239748b1644b528cd824c503e6dd4cb1d146cbf1d5a96e20c388bac4bea7b484c337c7b733ab6715bd92dcbc12 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041c87593553a6906097c51fe2ef6f4de291844e6c083f4abcf7f2d581fb -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 729c6a3b890e20387db4ebdeaef7e1036a7e59af6da5952ba72ba55a402a874cda4d9311163d17cb595c3e07d0b6364eb13591f6c414ec3e2395cf9b3ef7d54c21a20d34faa69fe9d563b309ab898ecd9b44fee077b0f97182938187784bca94cf059f4e3d3002ba7a321389475933a8af1468138d6303ea4e8c81c6f810b04d -S = 31a04b5bb1588d4410472beaf2d6ff86d514c30456ef16df2e0b92dd9f26b7782aa0d363d1e3035546d7c91c6cfd05a21190f597103f3900ca12b51922eabbba0f9df47010efcd5394263987c7b79bf8df94ae0318aba4a14caaf791f4a0807bead368a129e201d466e9e70868471e2cad83324e1f70650a2e1d11d9aa539c98e29f1991226357e3585eaac9c856027aa3ac418fa72f00ab71738dd6baa3e8e8af0f30fb58c02f50c50bbd64b6dc1d693fd5d548ce2e0e0dad0ac2936cd3bd1c16ea2ffcd1d2fdc683aa5a0461158aa5e621ceebe36a705d4a2813e5a1b8adeb44718d1af3124849bbb3859db3f8114374c6680cc80222b214ee737744eaf1b7bd400345782fb4df6fdd9e4116714028886e250847e7455ec466465bddd55bc4f67e5ca6048e95653592c9d0bd689dc1ec88aa642f253568d3cc00d3bd719b90e8227c3a1a924f58a8ba5fa68e0b932bf3be5441e601a8466111c8ea6eca21039d8605244aa07952e6918291a2a58ed90f111ea075954cedb1967d4d80bd208f -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 1399504353d5ebc7064355b017edfefe97729cdd100720cb16bce8fd200136ff9668e19c2bac4afd6df392159a500a3cb68ceb19da2648c6cf98402fdcdc78bbdb2fc92f921535cf419d20c678e6bcc72be2c6f5085a700008329e9145ef54e90b766fc531169484aac9678b57b7fde91ffc933742ab80c2ea1368ed0441b3d0 -S = 19e0165b14491e2f84f6eb55f7d0e3bfa5ce45d20067a7809def939408a90b0cb60b3733081960a0917981a89c8907ba50622411958982b37554b40235c28bd478a06d0cfc3aa628c6685fb739a4f72cbd3fa6b6fca3b2e927a7a79fe2d6513ad8e04317ded8873e446eacc8e600380d450cfaddf32523ed7bd339f3f61638bdbbf80ea2cbaffc51b2e14aef079a491eaf55c7da79189327070e0c66daa906646095b2c0062850d9269a456bb13e632e5954208fa9d9a576bf14c958741f7e30372709c20a209d0fdfb0e18608a65f049565b25a77afb4a3d79a49e9fced249f6045d95c83f0ea4b8595288eb022620a1a6e6768239fc95867c575338514bb8d16f4595b6463a0bc576f1edb72c2cc4344b1000f43447207f2ca9049c86c6ec92f1f74b6811b65534808ef659af5e3f283a39b9921ab906a51a9043bc34dd023c54f2a682f0867bf543ac02b55a13920f8c5295b0aae650af71083f7562c84bad2bb0685b0d6101978ab5d789b88c3785d82a01f154795084b6e363235b10fec -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = c783252ef5e96363cb48e544342f0b82a98334cfa425d5a158cfc8339f3fe6cd3498d746220529c77c9fa0d14f91cd82d579e214eb12c5a6c511633fe14c471039216bf9bd164e4f00bd46dd32db18284ec8c6f89419a8133a7dbe4c5fe545bc40e88850ae65f984c06a806dc55413fd7c3887838882a6711edc81620152085b -S = 516e3483482b42a740c475678c4954ddeddca4f5d3cbb9474aa7fe7ade371f4ec09d497ad8f4bcc33f60dfefdbe3bb66268f5bf25eff3a6f4d58b2295c82dd977933e237fbb140f9c095bb31b091e0d8ce862a588a827a3ed7a0a6b407c534c37fe6e89b047042de8119db826edb202cbbd6188820371d7aaea860f08e23cf927fafcea8f398c3e189cdacbe458f3804131b6cb8f32bdea4c8e88dbab79b5493928a794aa125a102c2af675e8a1654489651214793bd7b8e86bb237f5fd19ba5c902986687e18390604a5fbe531cef3d1cda48c7dfefe053bb3142ba153256b1aacabee463dc63e7d74179e83101aed8e9c140f51ea45c94c9114f22d9ba63aef338b87c975f3453fccb06ded002477a073f40a4e3a42df7bb588a5aa830fbefa8c7f2bf363bfe43e236d25f8c0d0adab69e3b3b1ccc756a5e8edf180cc5ef3d18eaea6ae4d09e407a1783ee6a4a5505a90df31d310dd150e6aedb20bb97b2551e6e96223aac0b3484a6179498d1b4c2412090ad5a4d3dbc0fec1d11d8d0a813 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041caca1cfaac92548bc1743c2fbf38354db0247dc19de0004601b8c68cbefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 5c0231e10a12e268e08dbd3b86845a1907e6bf853552e12e482a68afc7e9b378acb61c0cc3397d6e53adf3d50036e1a7f07538a52d5af6634a3aedfc4a22c603bd6a45bd2c8dcf8db73829affda082293c19b4ffb9e5c7a76349b6bcb3e676f7d647355a0eb7e0ae5655e730456a448834f9bafaa3985ae0d97f4c58cbdfcc3a -S = 1d7b0e1ea89523699cb8ca51a9086043c1d3c4e2d0d0dc5e1a6f3688d318f7db0d2a5272f71915ee2439db175714b2c38e8c0b27264c8ee01bd1b292b66197e023f6b49dea082b469cd30289aa5b2079e6342789b1cbace05ce265e5fb1716947989e5ccbdf4779a37bd4b748ffc91c2944259ae2de9582334b6df1c839160e4e704cc8a771d371507a68c61f3a06c46a41e3aef02162e9f20c85ef51b3f15562d2b9a512ef0e81ad60f9934be2a2cf7e5f54813244d360148334c40fc8a2e65335bacac5b9a607d70d4296f56803de8c0840653ae2837a7e826dd4569896555395bc0d4262d9fc025f400859421bfa8cd5841a3375e22efc9c1538e78795e28b6eea359da14ca3c44ee30d16e7359b7d83d47b6744099c345ec60bf2fde687d0f81db3718d3a79e4ae86a0c3bb47ef0618342f103d6e6f7ba89d4a4a520b1a61b2d8d3c5f178a46166631b58921b7e0aeed15c175e85f76575b746359ea831f87c261695896125032d7ad4ad26014abfd7742d5396dc1516f46dd273cee88bc -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 70125f4abfb1179f8c2b4f4cc30386a6fbce13786050b848f0e27adbeb16b0fb849e5b77dd6ab56c32110dc35572d1fb5a9bed2893ea533cbf71db867e9f4e78081dbdad1ff7182b42fcfce52467cb845cbf02665efbc7e7aaeac2e043d22e6e635830f56d9f676423b4c4ba192a9cc96901fb39a9cd3cd11a13d6f222f77964 -S = a06c4d12aba140f9db9ae4dad7a507c241cfc073fe16cccb8e99c0793a0a605097a0538bb4849089473050ae1873fd369c2295dc98b5561f975a66d32caa6ebbf887428b163a9a0515a0f614f636e8e8a87993c11fb334195de25c3cc9103a9e01f5bf2b6b6bba1786b0ef02e17c9256aa8fc714fe5bd7c905e240c2dd120662ff4ed31c229df92e0c819ca384735235e5f817c9a844b733c4c125498ad5493d1651ef8833886d98b409b41709fd0d0c20b0c91c666cdd4443dc0aec4e3d9a844d28b40b36be972a99ceebe68b955fa699229bb393bb65f32f139cbc42b20be0481aca045f965ed2caca3d4f7802bac775fd0032967570d826361620b32a2f230600aabddaf976b1998c9a5ec545fec80522f16876c4fc77e0867867bfab4b167fbee839b83b7f5d647a902e3118a167b0a7c7fbbc31f23c8b9606429c66c46a3cd7498e14a94fb315360a1668025ee35bb49fa614250fefd9236b8d3be9bdb271f865b460910149449e7d22df7dee27db29aa123bc31915cded3def0249d2a3 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 29d9cfca7319f6e6ae00ba6de43e9f20e140ec7b45f76095d7dc21491c31f5932989b43cb58afeba72f229529ed87d7fd435a49729a25cac74636fb0eda5e5ddfa047854455048051291d0ced04819e7edf82d7defe5cf9dc11c69544ab346154452015a4cf33e8e35e5972ba217da20d4937175c0492131650ef87c5ce48001 -S = ac2b892951ec306c6fc6c0550d633819a2d4f073001665cbaa7eceb96972e7b0358fd49f1fddfefbe16cfdb78fa15e4174b5d3e398268da9eb23e6b7cd8bcb679079106f583390462850e44b23aaf0a59dc9780d0f3b15bb93368da8fdefb979b2220241af3e60e5c1e2bcf23e2e8657438cabc2ba22e4081889d94f2abcafca0dee1e81ef1c29d3164d86fb50d28ebcf89e362f9eda07cd85206b9351c6092d37f0cbd1765aa81c4e0e18bb01d204a3073e1b60fe67c6233862f1739f223cf79160154c138f01d4428e76980e0dd9c21e1a701d05a6e67acf7f257275b383e506bcdcd54a80fafe266e87eb36b3c076589d1696916ccc88e4af50d8f3766e6dde0e530cf747d814a591e5da6bc977eb25b43df723e28e3ff226253d07043abf1b8f5a013b2651de9dfa34b7ffd94baf8fb1459b9fe305bd58064138a0ede6af36298f3444086f1a7d0c723ecfcd6404fd267bb20ad48f6655a9a0886868a83a214957b40af02064692661c1b191aa828339495b3de0c789856f80e5b2d569fd -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d06096086480165030402010500042038dfa46ebe6244537c96b22aaa7542f8cf5a10069d87d81b37f93a2ff7323cb2 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = adb245d4c5c72ee661b657c6efc444f8b1bce6b8c0e1bf905028472935a48d62a742219f42b6326350b5f4224b6544509e128fbeac22f026134b9805320373a8e938098a9f42a2dd8a16ad672abc628f1703a7b8fd7330cde583eb1db60c9b6afbfec23ce652c57b953f4b3d95b1e6dda5f7f54dbcbbc9ad4d38061cc9a74cce -S = 7f25b51b4d94f2220ff257205e640272376993e698cce9fc5a9b429ecf8a3d6d4150341df129b74030afd5d092858153cdd01a38a586c05871632525ad7b9d433dd9f8b1436d3d62efe46501665e075e918c39f775ad6e1e3e4883a529024193891d9463b0d1424a42890d5c05058d8925fb4c446510f12afd6457b50cb611eb0ca641b8f2f2c0afa4f03e98d154447497a4640405676e003f8a2cae21458d56c59785e34f54000b6105e85e25e4c380db43c71b990d3653ac344e2bc72bff987d6c5249205f2770998725e88125309a7c49dc28f9e6fc8a1340f9dab47fc6507d3d99fa876c330ee8183827db1cfa6c05179bd49d5e4bd6b467d559731417c9b19d0d265bd7cce858178e15cda9eda4b1ace1f6a492251c4e591945d2749d7ce65e8c03d57277e6bcb0f097c13504f006405e879616d95b5b75005118830beaab13538943044da67867877da87f29183fc05ca754df6c5bff810b6e5dc64b9e50ad29da9fc74a2fd20ccac5a300928ced1c3eb719e44e3b21071746fc559b1f -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = bbaa076712216e08ed954528d8309ee685afcd901d6865c4d48b63d5c0a8a870eb71ad80a7c2724e21deb7ed39fc6fd5910272cee49072109a4030a8992cef1d5db129544b7382b142a1fa7f747b66927411212a8f4dff1b6033822b9f6851bc3af1e5aba73e8677786776a630b56c645564436ec6a7f42e4fedc2277b63b494 -S = 477b191f2d027ad6621e38d56aad700749444fd895238f9dae3633176505d798d670ab5e85df8fc42906949ba36090a14577e9b179e6704be20f1d3ec2ff00b9f038a71956ee353f358f608d1728164fdd3b90213152049f2b3588237a8c1530f5333f0b89f07443fadaf09e80122ecf2af6c2dbadd5e189f35f9c2cd680118a2793190d0d63f83e13edbabfbd01031b6875d9c7fcd38bff3587021ef04f1ea0777ac67e76aa1b0773109b869075ae2c4c1f0121782ad767a7d0e78f3170c3e3243309ad36378a698f39fc6591463dbe9c84292bc4a44b4874320f9c5cc3cdca879f2a015362dcacc5c74cccc2bfe05f0773f3a836e1ec511c72d9fc7317deb4b2af5976bdfd1fabbe15b3f99b498647d92f818f658f8398c031cf2f364ffc106e75ece8f1cb87af2592fc4661f80c45e76fec99545c54dda470a019ba9a26068f05517defdba0d423029580ffce95b3ae1e5c8a882806f40ffc3b78640d6b311c2de8b0d51bf82a1ccf304975bc413d5f7e2222d91e5d650ba601594283aa49 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 7e5a48ece8abf0637665d2cc4df0476da66a82006aefc2100018cca662c1992577104c739db3675984683d2d43c3abaea52c032fc42749f8dad8a2e953c6096027df445d66bc16e41527b7a338da81d5308aec664724bc588a577965d75220e636cf18f36c5067cccea8267754be32abee8e25ed1b7085f9b79d3b6314ef467e -S = 8b08c4fadf5a33065be2fe7b2487190aaa863d150c819bedd2de321ec34b9f397e5ceba241c998d1138080867a2931660f6d720099698a473b10fab8c6c1ac99bba21ec964db0e9de0424d12565bf20978a6041b8c72019f910c286781c7979a98047abe06850d282644f6b7f375c6bd6af8509727b0d64d851902baade451f6af0c21967e4d545a535ada7f59f23d90992ab1268dab4797907527b9929cef18ea468e4803ddd69f44627577e9cec0ed8219a659db94d46f560cc1c32fc36537f9fbd568e26d22d070c82805cd17cdf80ef8ff1129f5254984ea7e13f3b1d40f7d9c304f49b504b634807f77dfe73cab854d3b98878dac4d33d13289d1fbe9e1b2f3c75f6ef5e4deb2bbd8e56ee6353f2a5d9c28d4640b01777b3bf743e4acd53e2e413dee01bba20d1811c62c3ffb27fa6a6a522dca12cba25c0b5c2f02d3f6b4593789741aa8d2e111b81e34fbed7ea544405dc0edf263283fd28249665001488c67f9ca067569f82c52587ec438b54516d1d84acff50719049e64edd562ad -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d060960864801650304020105000420c46cd19378dbc903c60d48ba8ef26b1ff32f64f6612a2fc01dd770c878eceb8befefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 2bc088c8b2a4af1e90a9023b3216fdbf89aab7710e8b0bd6037ff503fb5e3eaf9cc85c8ca41394d82a87612e27ce19a334a6ce0e95d972a7776f3fd47622563f6212a72c43ba100a9a23c947ea57ff697719bf5b4ed3160485d0771ec4ab5c460508304f97816ddc69e4022e859bf73adb6b53ff40623e16b60a638beee398eb -S = c42b0d458924349b4510e4805a6f199b29defe24c7220c54d1ddc44117bc05c5b25858939708333c8fcae96efc75e1df6c6b429b2f0e3f9ac21a59e15c1a976fa91294c11e255139725d5b9ceffce0bffc93166057d191be06435d68a64e0d790731f00fdd868dd2881546f467b52d3fd240cea6b6e3883db18facbb67ff858918de576f275d6a0fef13fa135665928a043390607b964a8d395117f886c661d9a9f8d3a2d863292bb2d82c987487180dc2fe859fc20fc5ba849399fbc2a5bbc414fb244003b1887d945580d2bae524d24de03fc14e5595e7471f14cb212cff64d561de03d5a85304a51883a10c259ab729e750f8a424f769eb8ce2f12c2ce2b3835b0ac9b219a22b5725149d65681c525eaa55ddea7f674ebc833f74464302597cf603d95fba141b8ddbaf3a540df6ef9bda7146f4d104a9287a4a55bcc5f7cb4dafde9c437d2172cebab2278ce97441cd1e091e3d18429fae503e1cc23319ca6abcdef6f8562a11fe7fa1b283f4c81a3025668bfe995dac330bd0a3ac869985 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003041300d06096086480165030402020500043034a99a927444c010c6a1e59848fda5efa3d6f47f1dc62aa4a8c085308632d72f89e37e9f74f5947755a2dec1ddcdcdf2efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 52e616af9542cd632f93bc2f3d510bef3dd341572014ffdaa0b6eecbd447f6c302c4b142b45b1f990e759b075ef40d22f5b96278366a3977ec72df8ae1497e85acf59143cad19b8df08d193ea076b5a5fbf7bc2bd660d2360fe7e54d21ed5f7cf782a0fafe2aab097ee11f1e2a5e6a42f69539b8287f32e0b21de65bbfbb0170 -S = cb647fd846c24b61bf5bd7893de079147a8fb4d447bdf26aa871d7ef83de578a383d932b152bc28ba4baa5ccb15e499e338b2a5e3606533c62915a26ebd8351212c226265bf097af9e30f113566921dda511c72fe0fb114eba47bfcdd052032abed1f69e144ee7c347f62f730b96aa42b75e23773d2a65f0d5f63e01c395ffe6c9a87c2364c05983e4c676af4b57a2190a2bb7f5f1b96574663a13540f51da353be8876879a1ac90b10a5acd42a69b6ab45ca194fed641acdb89fcc2d93325028f01a3149795a2d95887e29e161902da1708410d37cab1987d4f3265b9ade7c1bff7b385ec9ea1221fe00a285a77b5ad37f1e8519326d7baab48fcd70aa52dc2e6f8e7270e2c9c99f21b30d217a62969bfb584ddcac60959f71d0ae16cce6a41126c9c597970a79da11e7302ec710df8890afd0b133306b8f8a2e1c67a6f0103cef6b13fe4c1b19415759291267b3fb0dfd552d83ac856f85859589c69d911c9e498160906833664437456739116626d03f6f2028d869218b418b6b9360d536e -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 11a710487cbb1b9392d6f6c305b105f68df8d5d6384e0cc10292a028a5604835b2db30b1e1aaf124a541c03e0462e575a6e370f02cb127a4c315c2bdf8365b3fcee020ed0d834b6ade7f549e959e645bcee20e40bb823adebc2f611a309b00d28c3c46c4aa4e10ab631718aa5f6e69ee2c7e17908ec82cb81667e508f6981f38 -S = 378ea4183be0744a9b81e57577e197b4b20f3e9cb7fc455def83eecac3f470e758557b741796439947eb6b97b46b3e67c12f30452c04ccc3801496db5e3df3b5f6442b7086eaaf36ee1a43746926e78cb43317259970b71dcc9127fb41668845f0bc7a938addcbefc7ff19025f4c35da5efdb74884a98872119983bd0c1db06489b7530caefcc81822e74fa635ed4aa441a48b8b7d6d64f1a489d50fea892b2296c6b1c24829e7f7a23c186dee29d88bed157386e4090caee36fe5984aa09cc222db2f5985dff56fa97da47202fe49efac993ecedba74132e144e3ca1a5702127dda6ad91e133aa6e53d3d5cb8c81b1397b8c8ea2b55714f6559f198d8ffa7aecbb12b2d4bd99eb697a3d26ca55694f2f1e99e543d6be90e4a21214ce3082d0848f3c141c98becd7f986d5684e67a8cc5b783d90aaa7e0e2f30616f59f38ee150ca41101c4f20ade865add34fed3727b745db406e91dbdeffc40875dfdf2ff0dc62a8d392b4272630d3b17ccdfe39313e7f8f265b2770942f500396d2e2d97f9 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d060960864801650304020205000430eb5d1d6ac4370fbf37da65a4a43e31015aaba587ed2b1720edc90282ab022f9581f3fd35e174a5be58edd5f9a9aaddf3 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 979982a68d0d60a1200990ebf8a49a7b7db3d1e83f9ad9d9946267bc830c48bbe025a5ebb99b85c7f1cf93de2beb22c8e9766e5ef526242b01f5251d8a768780026add2d2d8fb9ffccb86f8779221b01d206e586d96b83839b3e006910a4bca6438fb5d5b2900431f8ecab50a9f18d0e7e8abec7b212fdc9ab667f08dd3eef14 -S = ac48451dfee18a468ebfebb7300d03efd9231ee21d9a3e3bdb5db9f5ce8d3e1ccb9af7284d5a98a00c39cf62d9c4a46c0374808b0dc01bc57ac8a61682a7784279d090d5d57c5b4f36cb468fc9200e3c28818f5e8cb14bbec20dc460f2721cddb09233f64b0fcf7fa00c165395a681ebe52fc8673d7b18003c4387ca6c9487f02912cc15e525531e1d40aa79881e2c6b2038c5938476d4649f20957cb0405c6f1dfb14c1986235b7f8f18ebe3c47600ab80f841c100ebba3e042d865d0fb8de4708da33493fadc509683bfdd16c00c5cec1fdd7d3017f4a0718a615dc7122202a54ea7429966e6f818a4096db8f0ef3e530780f09eab5d96bff59869fb8c85ed059a3ad8dc3d5613f3300a8ed17754228ab4e38dc24dd8127ac8d4cb7a68af8aefc87e94344c46868c1562942e188c9618be86bfa09d12a16aa0b52a7ab493fec12eb8f4898bd000ace4c2520d6713772b524dfaa86655fc5dd140d1d7ed49db225c93845b41ecd10b8dfea26adf2761733cf0d330feb9cd024bc4b906fa14ff -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 7fa4945a374691fad437ab261e2c9068c7221fb14ea96f4a2483130d0e6d9cd5ca3d6033f52d7a632c77127e7222dff0d11be92d448794a0d558dae4031ed83766208c2c96acdda048abdbeeba78496752f359fc82d1b63eee36c789d185337b9c77a0abe16ac19870fc8fe0c0d9d6b390d1f486cd2edd0cb74463624049b58a -S = 9e8ed5b7a3863ca22b2c2fdcd28ad09e69346c8d14262c7800e85ddf71b845bf31d2101fcb91fbce1f227ee1c72210f29d995404ea2e4b31b41a71173884570c2fa0753facadaae01038e6b897940e386b601e972d84095cd7e51345348d45a653c1ce707210b017c1b32ff4904eadcd34097af48a430a0147499a9d9ee8a765258b94fa56b0185bb0789cd222941eeaa8356964d2b1b12c81c0ad0440725ee6360c9e2f2885047c5b6f2069590c0f85352f5936e183d78e5a152f6337e1643bb37de221291191fa4226973f9fde3c688fd214c49ba3ca6df5a09bbf4523ead8682835944b1f7175ae038f84955dab509e0d68b5d9da75eba60e11e4e9ebb4d0f2dee448694f952eb3ad39e740516f129d12874e29ceb895dc87dfbb2ce4f208d1e646c347f9682dce4b71ac53ebca2a499ce64112279ac439f5942c8d04f2bf5e699000efde4909e6b6b62cfb52ee384e31beb22b1799731c543c4a95303f8fd32a14d7c0fcc4b449c9782af392800d2f7bc37369293f49c1cb94b2921dd407 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 831c38ca5421eab1edb3600fce5acce059ff4c5b38b56d69fcdaee5c045fc6dea164672777084574277f92b42b654c8401517a5d8baeb30cb6c6df635a20422f610cb66a2c7c37b13215a5f8ea86c67cec198bf95387941d6511f53d76cc3b48093daaf93925c950579e2142d56741b0627d059657eb188552e2b853200cb911 -S = 5c95df8ef637f77033e66934588956aabf334f0f5ca5efa1bb0e5b1c58fd313cdacb4d9f3163305e048d2f33a9d101fd6c0670f96d67b466d11f03d3aba60bdc04869e3a17aae7c80080e146c114413bb6f6016653baf26d3516fc05fef13149dd552bf5149cddaa46b783e625d5a3a0b859563e9f467d9a2723e5efd041a92a9837d4b652219d4a9799b35cb3df6c80b8467338b0e7c325e0dc1ee22387af8877e66c6f6a9b0d12a83db08dd4a843dc0e7d0aef5f0ca9cff1db415f2dfdeeb3a0525b2cd32c07dbf39eb9a3a132b9f764b66ec0ac6cbe0e770e1afb063cd1cbcfd8e8b39e10c290ab4a8500b0729a1240c772ef5adb065965ba3a4536e2ee0058cb11ea58834a5ff267fb11e90160c7a433bc1af9a044e208265e4c62b5940fde0e168a8863bb398305acc367cdb1c3b70f39ef051ce9614a125c3241bdaf42d8416d4efbc003f698878829dc2cdb1dc1f7c0ffb1af30b8d807b459403336a2eae1a6a497e95a0667a2f547b5d40bd97f9d76259c3ce91f1209a00e8da48fec -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 939cc087cba5d8eae6cd3884251f4d60808bdc82f2e6f013183217befa20cd5929d339c80ae7171e71b2f60671c9a36273c6e53186496ab6f63d02d7205d0bc384f62cd71cee47c3ed05a8e8db5b8305c1339d13c1f6496dd97b9634b785c7f2cf8d037daac24e1f814fb8f30adcd49292576cef4cf47380e9723b9f68a1e92f -S = c80363c21f7f20d91361e148b0a76c33ab2109b8c8e34609f567b49ec9675f1c04452715371913685f9a2f88effc90f3ac16665a2dbc81ccbdb4cdf677b66752fe07577c9a2986e48bc03e12126bb5212d7e821adb66c4eb96c267eb898db16f0fdc52f8f98797281d8411aaa4949d41815133a79a7f6f8cb3893fa1e28a37ee6c550e17772d5be34cf4b2cb16f119fbf9d5f41c411e1d2561d33aecfd9fcc425e287a650b127d11ddb2fe49a82ad3e7cfa84a4da75615ae23d0cbc45d58b7cd4123105ce3444a52412bbf09c08036f10d03d79ee735741858017181262fb5e2f817e0c53d3def1fe84c53807933bfdbb2ac2eec4fd96d638255364033e38ae5f9cdab1241938c1f6dcb14067bd236cb69809d95349d9c1723b39b71192cfe0c8a204c142a2a72d67f124ad6b8804d3b5ea149c7a1e884025fe56bc7ebf925d34ca62c285d3b290eb38fb24e59ad7c47914b98d55cf8d1685f1d08d1e919f314994a348499a68d3c669872a113bc119fdede411f4318dfffc8082e442784b68b -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 118a21ca36aa54b42804f7fb07874ba74e14bf3906dfc4343a19dddcaaccf53ec306f670cf39971a6ae2763535696613ce480aa0ff70a3e735e826d834b892480a058039417dfb5c59f693d47651ad3d55a51ded849af779d312a17b060f2d93ccd1e6acf53e2981df87775f3109c72ccc7121a8ff2468f3fade785086987128 -S = 5d1fbfceec266986ee94603ef2f57ff87959bcb7f1677fc871f97b5e73bbafb6885957eb04616a3a9bd010fa46c8a5c40831944a7f506d165ef3cfa4d3a7bf0768360e8dc0444c2b7a2e05106cdbd6e3ab029c11ebd701fcee53bc46acd269582ecd7635178b850ebf2522d16bb4e6671ee7dd1d417cf0d23baa26237e03fc0650462c1d113dd450e4465ff18d3a9871fe5fbcaf554d14c0bad78752b4c048356ffed2f80ec319ba816c60d06e270c656c8687be145df46baafb686a9b74df7347c8712dfe671b33aad8b3b7eeaf6322a8e770891c8e03526e1c6ea4fb9dd03413d646b3ac78a3f6b28ff87612616dcf87efbe12ebcb6933bfeb714961e8e153f96ffdbf7777f6109be52a936a13986e4e8229535f51a679f7d7aad4acf1824bf0616517785b864f5f19d275406ec53089a04a4f1b820d167b5ad3ba36910a9730722dfc58fad54f1e0d7f761f5d4ed3bff3037f79361fcefe723647c65811f4ac66dd6dc4e3f5b4bb1cd0f3d2aaf000251b69b9464a35bb7f7540b1249dd39d -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003051300d06096086480165030402030500044022b0603ccde4538899af30bbe52e2e4d6e62ca5f5e69a0e7cfe914a193af2e5788f6bf85199a7098078438b5d2a3b694b926526033922915953e113bc4b56d3eefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = 465c2bbd78a5f3bcb387d0db7910e9b2d0b827948d949a67d2cc19b2d64f29f8e4c52145a7c68b06a449cc1d085f0835a421405336e6bdaeeabab2c1200c1d9e70a7ee85ebe46bb5a41dd382706441a8e975d4dfb9ea0db015ae788687b48f08f1e9dba6cf675c72bceb2b3238895eb3a89e2c609e0752125b90b42a92af48de -S = 902cd4cb495e446e0b4d4cc1944fd9cddb126dcb60543dc32c4ed0eb4e72182b1a13459746e4ae37805e23808cec5974083911f1c3f155e09a3223b03aa145128c9a2ead1c7010dbf43231b6ba5fce2ca77734e543139118475f5f3eb9db6c0dd00b01b7a48a1b4c65cabf9260d22776bd4168a7f7b8b81099ffb60d6ee00356cc16cfee9026fd318ef4f0e71288daf10e06b6789fe0c590ccb7c448b7426dca0329453633d98fd3917562a2df5c2a1ffb07f82354b8e3b1a508908314245767542b856938e019ff4ee00c46ced5b8b836b57b9d0999742b2e23dcb15e66c49401495dfa7267360eb0493722abe6c89cb92d47aeac5218a4a949b4d7c4ea23c7448995294424995ef6b873959fa8f670e764a59cae39e998459f9eb03f3f640a6c4a6c39a9532c48db61b5d6031e7098bbd836f5ef887c20f00e6f8d3e82a7cf3f3fd027cc315b85e93205b78e29b9307d25f6c38498bbfeb08a0aca6975f241df0bb9e27e99dca0b555ed294a23071664a7fc9039838a892bd4cf9696763637 -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = cc848fc93ced6a3252fe844053b56f8b8df90ac8ebdbb035c81baf3801eefc424efe25fad2b38698f0b1c08e61a2676e8335fb08f4661ad26001f38e9761fe26e37eebdb9827d89eec8bc6be09fe4ec461fa909c42646df5aa11f6e95c8923e1330bc9b3b7d1c60eee947e1875538c55ce51b1cbfc5d10644d559e9378edd43a -S = a2771501c8d96b8f29f456930f1551f648abc58e214854d44c1bc32de90c2a8d269ebb1c30456e710fe411483b4c931d40a7c300e731ab0897f976e5c5aced427bb462acb998ddc23031c84efe0d187930254e0e0e1f20c9155ba23f7d2a02f1b390db18c71d37f175d13f44e421279ed5d803ef7946ceb364dfb42114b2943b446ae2eab8932f19a87eb449adcae98223f333a47eb028dcdbb9a8fea2018b3e9bae3420d99d288daf1c13f9eb9932814d530d1f8cd0f496ab21aa984f5f2df5fc5f56a6e7431542864f2ee78108eb4ffdf98d50b8bbfff626da4f166881d8126442331ab8d4d30492473a6af9c1fbb08fbbfb6bdc828d2c2419a302800d21e91aaeb39a453858f6f2a3675afe000de678e5095b9b885d1b02c153dfc48b33470fe8521afa1d36a18e2ebb81d58e1cfed3c0125bc8c5635cb88ac78e03aa6d661dfac9bd2844aaf98b6ac7c753543865c70a34c9f49b33fa63bc7b4f0b4a38279fc413482f2757b287c31f83c786d5a55438c00d1f3bff8479ed3992cce425a0 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d0609608648016503040203050004403c1940aad46377052b5ca5f32e427fc60524134f6b125784071ecd029233a6b878b85b7f3c9a7ccd4838fb9352a468d02f64a6e19ffcf2e2158aef7f09033d5d -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = b493cdbc8bf23247fcb00bc4ad61ee808ccdcfaecde823ff2f04467382451a6e6655f20e555aaebce425270145accd9b11bb8ed144e6fa038ac2a585b955cdae9eca3d2bfc697199d2c7fb54dd3a26895e90d8931d01bd84ae61a101f39b1e54e25a78bc8809c5074efe51637cf24072fbb5759c5f1fb3a9254a028f38fe5588 -S = 301c7cfbd1d8fe0d725cc8854a9ba1c7b16a3e4c0e357373a57cf22386bc562615cea5e5359d90eac51e558a15580622585f4144905b4dcdecca2e42f68010aaf8be6a17cf2fd4a5ec77871c2229912dd6318f365214939e785d2e9d23c75eaf8cb3c9ec8a21d15cf7186aa3e92e1c1209f054c335fbd61ac9c48244ecb4d607e3bed905a930f9605855e9b220129ecff5239eab8260fe7cca7d07af495a134dcd63dbd71c72205d11613ba89925f7bbe36c2909e9dfd40596f2b6956e749c3710587d4f1c304acbadf83c29caacd3a1b3f0dd332560fb8802be3af45e6e09aaae57d8b8c75441f310ddd927a3279243817943719451b94cd6d3cd62c8e1c15070c2fda9baa2534018279d36ccc15fac086cae7d430c44276517d1e32082a6de8d0cd7d88900f9cf4a5e7012074834b9783734dd1524e191a63e0c6eeaa5632f6ff2c92f3d05589791d8e717f4833cb5640d2444074e881419cd521fb7f5f847fc1852c8e17ee7c7eb3d808c9870b1f81ea69a54b361b65c535e0dff70278c61 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 22987d4c34ec4b902622a8a6aff3dbbdca802c7c05de4b35d2402027226d4d5dde12cffb23315451fad250d344806558b7852140a554f05415f570af785a6db622f1dd0c11a3e64bfae2bd0f59fab4f2bbf50e26c14f1c58a578d85d1685e896d9ab6acb9242278394dd91c275d8c9efd8ff0c4ad54ace97ed8a75cf7de374d4f25ca008551f66f62a6f62f564f7cc4af8800cf6c6f65b08ceda624a3a98b8f98c0374e7fd2966ea7fa44c347e1c484c5d1805d81980db5d1eb193f48c111c02b8a4e987a505ea5bfa50956717f77a3b89e47fd8251eaf35b3863c3e32a01b6271d8f793074aea4d0ba7eec8d1cd23aa967c7bde7c2ef919a1a9744902fac439ac3ada0f604e2c1edbfc4349bdc50060f0a0b2e46ec8ad9385d63342c1cf5eaca1c68ade01acd711b96f3e165458d53ba6108bc784dcf36926a5f2e2217fd8afb78f46a7935cb27707a192ee7379c72b74342fd48d7e43b1a446a01264eb2bda68954b310faaf5dc57b524a4942b35f17eb7b69ca39e609e398e9cbb6d7bc61b -Msg = a97ba5b9773d187153d602d121ec843f36ccc618105046af44067093b78e6e11114441fa6f2011a759dac139f351c725772d3bf1e2c32d38ee3a3cf441ec64fde40f18ccf6959185a25065354e5a5b5715b47e9e782d70ee508601ab07d30037082452b6746540151783154a9ad1e9ddfaa9b8a73956b7da5331e741730beac9 -S = 2f2c9aea6942c5a24b4e5e04875eb5c6f44e83d89ccf1f13455890e2d61f2b7ab464355c5cd0e7e9aecf004a0b85d0cee852a9681f4792899731f984e2c06e47b8dfc4424e4cef5b9f15def45d528a3a275fb4fe7a194ee7b10a6f9694e8e1659d95a6f915fd79e3406e05136b244213ccf67c5e2055adbffa85896591d7abff96f6e68494dcfc48440bf66cae21d1752544933bd22154756ad15a3c664188cca88b5f23a6acdc151e62f7d0bfa9cd60429031736d7df76bf2c12f37c338a1174eb42cb740c5d38c1cf1b682aab8d49443016cbe397cc0c44374f29502d997bde22a45efd0e7c801ffdcf1b3e42e93b955ecc0eac9f5b71c349504e8b2973d894f0d33edfcd07f9fb6b3cbee593448bef9590391d13b661e2dd18f70b43b59f2e79d65905f9ffd8ce0117e06e610f34fcc8dfc72d6f0440e2e6f882747c5416bb8c3ef6ec702164b51309d3df33a3846237a2f0ea8dd39ffbe0a8d549cdddd063d7d5a65fa27acb62f46ea9f467dc0defd426cecda8afcccadd1fa3e483d5fd2 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -[mod = 4096] - -n = b10935650754c1a27e54f9ee525c77045d1a056baedc8c1ba05a3d66322c8e2e41689ca02b8e6ec55d3331cd714e161b35c774311540c6410cc3b130e65cec325377ccf18a5d77054afaa737e65b68662327627f5d1092df98c08b60a3ba67599b1406986f441528d2f1f5d6fe5ec6b8aa797dbdb3162876b08298237af81c7004863576af572ddd66c487cf32a82d0f9fe260f8f2681613208aec55723622f50d3cb3bd33b1226d5b5b9ea2c97a2c59054e31536849ec2f0f2597c077e621ddea0a22ddfb1df925c9f1941cd431afce0398d28e736cfeab3dd7f062a65a2a4c1ddca1f32afa03b4ddfd8b7ca40cc0ce2ed42229d753f03cc6d8bcdca76ab7c2703c5ddad08aa9bf9a27740a8b23168c6b55917bd3d5c1c057c34d1efb1411da51ab745519bd92b9432fea8fadcb9a70e5dc3adcd3081d3333507b7b998886e988296628dd7265e64eab557712556cc492377f15a078dcb620a6e7f051a1fb8754efdca3de253dd0aad4205b032659e4a4fb307f074fbde340702b5911acb34737d7834600cf2ac77f62f83ccc9ba78ff911021b9f8ad1bf421430ae0d64916944b504542c0f6263c48e5e233ef1869df1efc2ccf6f4a95e4db2de7b4cb1a992bef6573511bab4bf2cd58e72a0c235f56dfc182df4dfffb69433a5677415f35d84f5125f5200eb57868cce6b74c5833417990e318372c9239a36dca1a0b28809 - -p = bd4e8bb7fd7ef1e39d71de06b0001bdadcc81b0edf2226e0d056b7eea70b2249000279cc1c04b1ac2919014fc3fb8b62baca3e261601fb0a58a9f67f03cd60085b2d43906d36ad014f321012a9bde9617478a0c10201afd53f2207de3648afd1d737afadf7fd2c0b9824d4f66b2c7dfe93390888ac088c680c27b1b2486659ccfa8986c8c23f78f18b5815a410328e629e7440221bffd8ec4722bba3420da5234f898f8cd7e6d7dcb1349bc4a0b665b41d930e3957cfdc88797aee5b2b27dafb5ba0949e3dd892f490212dfd249f4b1d99fd3b72695ee0652997127f0b9b417fa8365ba9fd103b978309d9baa9d401902cc107cb8d2af7ce04660900e3707ab3 -q = ef67f69838735c055145d21fccb42298642177fe3fadc39070a95e4fc04ff058aeaf9070b4eb2de1cca72d8533bc55206d2ce9f2895b148da67c89e5b6496ba682f76bcaef69306a7fa4fbd41a838bdf0fab3e7b56c27a8c18dc4bf970364dff7427cdcc6f532b49712282370a718b7d5287bfc02c4abc35ccb2eab3777f5e0d8a27ff9ebe13e725aa0a0cd48aee1fa33ea6b4ea965ba42fcce7af3c528a6675cedf4969640f2ca73345dfd322620df9dcf16520195df8232061e2bc89c12de24838f255e7b1c17713ba435d5a351e263350198b3fb881b8ce0acb5aa58b7afaff184489d167c9af21e40e2ba9fa69b44a3854329385c97df0de24dc283a4053 - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 200ee1828829d9fd27576e253ea700245c38c5ae78fc76e33dbc4877a55d1e10c961fdeff8b1c0d306990d1ae614872a7b4a450fac578465b74e9879c77d29abc8f39b177a40ce74c47c083b4c8b2f0c449e3c4f87fdec17e405b84bb96c0807c4cda44037606ba70a0847d0959460945e3e90b4307818be6de99135a4b225ec -S = 33d2c45a355afbb8eb5f64fbdc4bd3719afbcba36d5d4bbc697887ecb7e7ecaf99bb31798977e3385544fd4c44efe1b05f2a34119bafcd6377c24f57c030498f6d96148677079ffa05a253e9499d6b13d3c02d5347dd3263045919f1a7169f4297cb4ead2340e6706269a8607b1575044e75adcb94cc7db8ed80a776ff1e56d1ac13ed7d82439750d51904337c63bea9a059a056f30bbb8c1c721a0d666cb843b1a8223b197a9f48e3941a9f6d8cf022dc4edca612d057b2548986698f2a53266f49e7995640eebe929fceda0d33eb24437113edaea93e8d7892ab14b25e851b88808b470a90bdcff021e798ffbed003b3b9c8d53e4a1cf77aa7b5016a2ca41d4da22ebe498c73bb3d0239cf41ef7f404fd609d390c8c1a0d2f0a6817cd3ef966196d64c89524032b6ddfdc6f9d6876d6b9e1c55010969238af5f2ab616bbc9234445d07f2462aa907b31a08677fcb9236206187e00888b53e925c334f4993d3f18ad6db81ced54b666fc6513da7a4e8a8f1c0eaeb6819cce7cbd27de9f9c9718d900297247e41a704b7613221fa114cf145a1cdabf4217eee25678a24420c4a75f8d444069c976ef95d61e5abed512c01cff4b864038ec8e4aa877ac501664d48be5aba39a35df9b3b1ef01a25ebede122b1797494442420e0f0d0d4b7c49d85f9ffdb102a7a1e0ce6e4a99d9690a80958ed548e5beadec583c192316fc7311 -SaltVal = 00 -Result = P - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = e0dd55521da6bd181813a02ed22eb20e2f5d9070573846be5d9814c91ff072ba6de1514b6d08a4373d1b1feedb343e8e426c8a0fd6ac18bd02c052ec20adf9e799456b294df822d035ed7e4e4652c46299f06647ca02852b9e47b4e2e856ffdcad322c54861e40cb46b245b5dd2f4b727c10ad7ffae195ee7754c2133f928981 -S = 2c89c5c5b481ae5b632c628ac42501f9df48347c2ffdc7d06526d2884bd5dfa01591a0a197bc87c0c3e2b9fbd6934a29fe5039fcf5b5fc89c1731fda7e274e706826740dc352d95c470ec799bf4123e7d673060de89d217acc23ae544ef70e4bcff3af691123216582b4fb6bc277a1c364acd0bc7a689de95e2a90d762ef4ce7284ae0a9d42f0ff37a2f6a40da956cb08ef0520df1e5c9462ebb5694d93ab5ea7ab7cb3f1812eb06ffda74f651d15439797ee0597fd00c5c08ff08ceff35a44875afd485126a9044c0635c4ec60992dbeb9cb9be19541b019a270c85e2c7a31a687f96f13b75a11e1cccc0257a7a9baf665553ffd34802aa23f0db466ec35d8d5a0d6a560c75b0ed1f434ce06e23ea582e53851c59824e476686d027810f7b46f31e88969b8274bb3116277ec1a3982f26d6918d4919b2fbbd161af81786842b57c9dd7f388323dc377aa64dac6782abbac9ab3558cfa8c989b8df8ac5be897c848cfe00407ffc9de8f3dc94a263182523c31efac84120c3262158d9190908479fcf24343192b86991a15a2fbea0ed8ba12d7644af798be3205538ce4e45a437e116a1faaf527614e57a4fe2299c383fa2383a57b7e950eee956dfaad4dec984a239fa4e09586113659126658581b62de9eedda4a921589b02d2f24c57f2827b4044b8709bd688a8a114fc9c875973ef145ca1211698bde58ad273c67b6a5c44 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 22b5d51cc4048a5a3188dff7caabe8c2f2d8b59fcd3032da477f4cbb596e555b88faaab5ae249300fcea6a3d4077000c64973cc3376d05c171686200f173e0ea486c356e7bd8225205d59ecb1c4f304b35779d9aca71c3285b4dc5a2b33968c36cf5bd6db58701f8532fc1cae69d41276e621f4b0da534b60f17bbc82729b58d -S = 297bb0df8a838904aab3f7a517cc87b6f5f4e53e314a2f6d0270fc34ec94da9341cf86aa8f7de3220485f0598a5907ac559e89bbbb1e6ce4fa2f1a17cb5c8696bbce34480ca4f7b2bfa2d446e028359fdeb265af0e3e1bf3232712cd06ae681d7c5e8107fd9b088931ec27893a0f2ec6b1b9a1e53e0da9a3e19a2bc840366acb9452099fe221f28a6a8913f2d866d3d0d4127ec3a96c71099e5ec63be473390c4aeb9cfec8a651e812807bf8b3dcf75fad8372382f86556924ab57dcfd59a02b9f3b2da272c1c738fa6f1fc3a78cdeaa91120cce66b9b3287037c1858645e418fa74a5ad75196e0d10d38052cd4ab8e5aba58805b4bd58daae20a801491d042180019cd41b70559fd9dbd1cb505c7f7feac497405697866753a8d3e2a92f854a988a50f3554ea0aab86e79d5516db5f729cfd4e2d1c7bc754d00d75de863dbc5c254748e805da04492ff230aaa89ecee80b5501128bc37646fee92c3714e26fda4a120f684dfc043bc26cba3347a3defceedf425e729ebc0f7199a348f29e500a0cf50bbc71375b0c7324f41db18f7e3091c9435f3238ca879e61684ec7c5e05ceb3835d4a3efa4d07ab918a4c0b10f01fc8207e15aeab15d21fdf032960fe5235447bd5c6eddda747e8d9e11c3d05612ca1491cc5d1314946e45e3aa1c6b1756dc906168684685133375a7d7cb69ab04eab56cbba728e70ae8d4deccf4139a7 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 709fa24119653806778374d1d9574c92fef4959886c61958a97ae96a2918f5d48572d98b70c2fa37818fd2372cd088e5f154c41bd361c1f60c9ca4d9ff280cb56e12ea88eded932497b91332ff0ac4766a6620553beed494ae401562c99d379990477c41792d2a561fcae0ca3a4b29cecff0524ea4b479baf730e70c6fbda007 -S = 0b7c22e20bb685bcd1d871bd2466cbf02994e50238895ac17cb51bc630b646f3ccf7d1c572478d762648e958e8fe1cc1d6a3b5eb6ce85bef9a01945cfe9755cf2d55875ed9cc0b1980e54d9d11a64a4855fccfaa3c3f4973bea94717b18bc4960734bce689a6581061a85e6a6e316540d209e6044c5bee56fbde7319716094ebf240133b1c2dab38565846f0603efc68ba43c36f439f49f8ad9110833156a72435948c3581c2d5bc1dd40441a5d63200252cc9e8af7bad81f5513313ac3c3665a03cf2d89c98b736d3ae566a175a979885d4d1bc87913eb1c755de17d2c80bf91baa108027af75e55ef8c5f13d26b4ff88ba3fc4b9aabfb36f90927678a2838e374eb764a3773d769ecfe9fbee806b30d3b1828fa1aa8a082563ce38279f26c09b898ee863e5eaa868d9a52a35612cbc5e87e5202d5f1fe6608e0d20ffa9641588a8e60cd0f06b8455f72378ec5e75015b4e3933c3a8d8c72e204db29e3327f8d3c30f8b9150760673b572c0a1af15b0344ffc3e5d405a208fb96b2f8f03c63806351ae34108dd8f9018a6220c67d962c76fb09579bea1c43121d467e05684f267d7633caa14cec7c81fce053aa121922c190f042bbcb08e37dffc6b7f7e022fe9c937882c27fd8b4e8002a53efd9e7c32cdbee30b373bd40d547c07696b3e854e4fa66b4fd7b9ef41b8f6ca5e6e7acea19e6e624d61e24494bd93ae7226d686 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 6b9b00a0420a1869f6fe4de18f707dfa850983b626efba9737dfbd56de7c71d8c0e6465d668fb9fbe54a1e4bbea59c6203797902bbbf971288a53f4c87e21e3678468d531f95169ae9953327d36658318812343cc965358f12ff4ae97ba7ec70dce25fea34c4352f4c0715de975aba505dfb3eca188899f71f1365958174e46e -S = 7b08a6191987f3def583b16c365017b9a9f4baa76826ef12593e448fd5d7cc49d441fe7ac0edee5dbd1685a7295a724bc0b1137e8860930f12bdda8527b60c3ab08546d887f77e74315d4a6be9d4531413914645d51c05008a7e145257af7e7a1e41d949f284be7a7f1ac71885275da46ad75b45d6f19785f0a7a4f18124eb8b2d3692ca9d7c3b2cd05fe1df60ebebeff90cdb7b18b20a704acf64407de123a553cbf21c2468a25595fe2e2f6c0516221efb0f5057d92d0e64e0d95c1e5500467fe7c1742561fd0ed03fdbe4795a9a7457c3eba1033e11af6ae64e59bb9c84412fe89551d52435bb0b717cfb8b029413ea796f6b69212649c97e5a7f2e2ac50eff7b1485a251154c6da8609765e3e3b5cc155f0316c0f8a3f6630177a881e3546ba1dfa404430a0910f71531b892c6964abe8cfddadf60a301427d9d43bd8bfffcc68ddbb1df8b718f07ef794d95f47650b0608c5e5beef2edd339021152c5cd33d6737ff3c5f5aff14ef447274a7cd727e4f9530e40470989e60e0849eb3eec1a124feac7b452dcb5ff002225bbacb420a60afeb10781e7784140aad0f76b01b00343835caff44983b0e681154478b951845cd26b852f279ea45f4f6887ba29976c48fc618a7eee9b7b110fc00f495f015264ac6e0e88ae0129748da755264ee4b1289882a1cbff971d6e87545cd670875c0ebf2464f1133ba5ef764d49cb98 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a0500041427b561ce228f7d5f0f8a9b1a35af930ab5a9cfa6efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = dbee53378324652b696ae9daee6d6ceb27bbd30533cb49efcc3e7cf51b64098ed102343d7352ddb5f54cb0408b249b61bc1485b8b85b3d27eb86b033d2ee60ad0e821191b7c6c52ef21ceb87c643d4fa2b1d661f64b514f38f800e367be3b411b9f651fcf68806df8863047746d0fefc9d5edf01e0e0b89be0b5fcc5bd4cef03 -S = 24d07b55df196ab4f27c5c1008b49b54d726af278fad7408c8006262756037498841b35db44ea4ef7514a1edb148da8ef08fef64ee14c3059e6983526acfa9e6e64af6e056e0e6a602c9656253829adf8bdd43950885e3a6a8f202d90a728e0377242fa09cd3de5108b8b06b44d968f10e3652cd8840daac895b08923b981ad4ae2bf4ecbd230afb18c1fbd645eb993b40ba4e0aecee894d76bb414e33c1ed752abc8c8d950b4a16868337b40dbcd9707b3c28b5d59dfbfbce57dbcb54238f86fc7ce2c6a5386388a73da4e65c5b2a48d620819760a6f64b34cea861fa0703bbcb80524c63ff64c673250e1cd922cc3fdce9849e9c57fdbf3312c2f5517abd501ee26bb06e7ee25e58b3051944e0e47e6074a9af1f6e6ab3879057eb82519521856dc94e70e4b8663d8e2af2064b75847cf02d814a77a64bd395cc1f3357ae466f4d9ffb5f0b808d770b854ea44295984a938337729d301f28bbc5e332e27dc023c96db9bef26664d4a3d10993fd6942372254ec5639ed69905eee6b6afb2bda04685d34e3d1e7e1b8fabf9fc1a0418623c014e27b9acf277097108cbccec1be5527e7baa2ab100d8ad16ad1046f84e728ad3daa98a681c7cbd520d1ef131dd5d588325b390ff12e7b565c04de481c03dbb16f24f96a9241437ad31aefeb336ff3a1669aecf15302b26528f90b0ccb1853881d89318edbf3929ec5bc45ad5cc8 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a050004149f14ee6f6cd3ed793d7fa5a7dceafe71ee86f6c6 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 1d9f5b7a9786d2d493b4277ed95816559e6521ea07fa308deb217baadbbda9595fbe39308397225b92f2b6ef22a2cc7c50d91ee24d9bf0651a72f3038f646804a22288d4e682240e522f89d9449fa677c546711b0f0a86fb4df611a7a132ef996b33100dc92f20135ad466e24839ec6f8515e03e542f3a780c159f3f1811853e -S = 287a3784de71ed88e4621273a477d5570a0db6dd00d528ae7378858a01e7412a6ed335f30e0b4672d61a6f248ddfcf40ac8d827f847355fb0751e4ba40ecfcb9373a0439200778ce27391480c21938515d174db382e27d57148fd235b7663b9d4bd4b1f8bf1134900bccc5a0dd53bbac5336363d8976e01804b9cd089700fbe7ac7bf61f511e8fc3d0cd28f6e6207ef9d5757b762ee96facb746d7c514526b5c6afc71879e359130bbbde3110b9fd1d35c2c4be5a0246a53b164b3c6b5ebc96f10657d2faa629bbff44cdab4fb9aef359251f3b7e33d96bc96caa65a4ce7ca31ce65be880560469712de61585c59c3513bbe87dca0076670b142fb8e6e65b18f21ed0d931a1712a4c6d62cdb6411626d70593e97716b22d10d3bfb6420f8471e6c75509f6495bc1505a8bf8172512cc20dc76875d3adec3a29dd7fe79e258344e8cd8094520d1e4e07e20092e5a4dfdecc30625e9547b23c6a27abc6dc058a2e51f769f6a232fbd09577da3a137401cd1c6e4c7ae959a52fdcf1f7aa4856db6e58fff070e20becbb735dcc3c7a2208ad7cef837891d20281e2045d47a37ab9e7eef5234de2d0e9e5c33b48bf8d9475f96fa368a87cd3bb82b0ef167f5533ed365e73b8e64657dc9c616794d4508042bf5b727d60cfdbc4999e8429d02ef91156cc74942fc08e85a9e08630887dfa4d820bc90c96eaea99af4b6c90beca889fe2 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = a96a3d33f00d283002fe250940244a11048a4bbd3c6d3d5858939ff767de9ab07c2088075731b4a9413f605d38660d374c80f60e493fde3196790b565dc293d3ec40d6115cbb4c3d70f48140bf385df21634a98a180bcf5a27a6e1b9884cdd40c172303946d4785455c48e9c1fc2c4aa284e6b18f0fa9939d3c329072ea1025d -S = 553b659961b3c76e6ae1f2cc56928e90488c5a6c8c8f6be7885824cd69730b356a57a42f7da21ee061bbdf8354a6ffb3b4c96948a7547c77e6786afd77bd6507aa159919d0eb56384610a18a971c396f994cb6f2b426fcb0b96a12836ae99f6f1e91de39a90c6df4e88af34dd59ece75f1d841466eb72634ae73fb66b952e4a7f071f09777033faf0bfae8fe80d7b45c3e46b063c06adaa71ea66e8bace380d35fc8dc3d61cc4687655b89f2a74a41f29f8ea4b77a806a0239bff08c596392e5a78472af3cbba23bcf8145ab3cabc66d04bab15a8330cbd6f626673fd16c8a30a6c4eb110690e2d5bcddb327619887a12475e0d598866123b2604e3d14750e5593276e3830f11cbaa30f7ee61479ee05788f1f7616053b98599bb5246261de3e90df969d0f84dc41066305ca493e5c814cd199590e6ee20317ad9acea9ec22b57185d334c17855485edcc3d2d7e939800c12d02b4bf818c72bc03d9d06c228aebbe9dc7d018349fc9ed8ad34249e05a99cecf3dfff0e2061af2e6357518758b1ce23db5bb2d69fe5fbe64b3e08b193c30c647233a60372e64cb550f90a923321cec4ec692b3d2caadab37b6fb3826d591449ae2ca3a6a754df669f3a5beda1b191a8a2107c649d69234d83ceab0a1c0f65bbb9d7f518a0106c655b86b3a280dfc8c75548612b01bad47e7b1c232a0af34e7de7291eb9e747292e78b61fa0c174 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = cb9fd0e59bc6d0c1b1ca328db6bd9205ca50ab8526e81dc000f46eb5af7d4edf10fe1fac2877b4310bbd591cfc1414ead5ff2b5aaa57e621a99b96df4487d65293e811c9f3ae45dcf443065b721bc584018d52798fe1a0f144aac92dad56512e1a03af254494092b330440325ffb2c3b169f29ca1dadd2979ac80c87311147da -S = 7a0a3a76ee0fd8be7ab380c909d18702fb0ee2730c61bdb7fe5623fe62137145bd555dd1945ace3c46888afa725359bfa21028dbcec113d14948a95a3ef8fde2a454d56627de249a7548306ca4c042037ec8ded524926237d69bd4099383e0fe68cbfa1d13542955aeca3fb27e1c21dbec1f6b763c0e5df2efb9e3b0a5a5ee439c91832361f27237f7570e0fbe93ccaba416a2495daa38a7adc15c5f39ceaeeb9240ef19e6e58a07567fa3d8fe5cc375ba28d15395a8afe98b71162609a06ae34035f6e92e7e58c6e814aa9714880fc8403bef091396ea465bdede70706e514431ece1a30b6b0e640456a3c353a790b5e9fcd1a75177aaa092af6cb07221df11b9dfd9f9e7be02b2433841cb7e3db33a5e4010b0c411e7c823af510c80c5930279b7f655c52d7abe24050561c5ea2f290a8e59d17ed8f7873446ac329095814b47d2710648090aa52b4e969298968e313f7f7e49599bb01fe361e1d16ff10d25eab366ea47aed18c98fb87c1ff915bf040db4a46458e12173823e541a47f7fa92377db3070cca6ffb9b78e36fb90fd662f47605b8872b8556c886b84a774dce72f92f8f673f55f8bf24153c9f18753ebae13d999ddb8caa25fc75ec58f29adff866dd5ea68aaee641d9e34c3783187c3383f57a88ef1b72e90ff9f512a6061ba922954f63cbc0726b2935adee477a14e6b38e7115be26b314e456c65d56b3a07 -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 0bdae31979864502cc9e0cc38b9d97ccb0aa40a0076de142d72197e9c4eac5fbf4695c39718e5a37ceae91100ed6aa57c15e695170c133613baccdc3c154667d400dd893fd192b7be7bd5ad0779a5a4bda3b59ee52eb4482dac98b44091e28dc38edde8ee7ccbeb45df3f06c8f93b08e436997e175921c8efaa15ad463ef14fe -S = 34a41f46718ae045c386405e56268514a7baa1fe63c6a4e1c963b1a43010720caee088df14f3ae4681a5a63f89966ba2ec3243fdb80514a977004680770bc8e7069acc7aab3130532064a74f14e86356708f32829ca06e0749af4c6fd8210e2137bfacd11087630828afc4a15d01f8bc1c1a59eee3b6815e4168017dd572136af46860d0ec0d8b24d342d8502c09528fe02ca39c78daa7eb6c6ab0d9f063d92338f68aa7b165b05d044e7f9cb9ba1f059058c15b088a3087d6797658523b3f3950ff37c7fe135886b0b309b5e3d259993e1373e7c86626497c573264d928ec0c3d653cbee9403f12de12c7790c54e0bed9cbbe70aa78094972bd921cd0dfed81ea6e91df914e83e75dbc714eb89e7dcf3dd4d71450424898133a9bc67bd4e103422cbea4adac473efb16c6b10ebe089ee60034e0c599f66f836574f7207180cd6de83e3708128d867439a90748676fee209dec01acd90d5003fcf7dd1e919bbb3ace60cad0964081a8eaed261c5eddc7384297731cf9cf892730b938e8aeeedd60b06617fe7639c2f3493bf96cff12df30b19ae86c8edb0867f5476b6c381301ba9cd3ccd39b12ba11222068878550cda07e217185eea14f75bc44512490d1aefa18ed11729867e4e16eab49770747cdca5d4c39b451d50ac9432c42bf3122da7472fd58d95ce0937d33818449ece98b64ab39d1d0e0ed5e6ac11f5b119dec8f -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041c0b8e0726c9d9bb66179c5fbffb9b336ce88a54e819789583af5fface -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 0f46bac55d9e2d3bcf07f70ffccc050fc35fd35232a87629a69de0533413607048d368b88cf193ed0c59e68e97ab574e68498bc506aee4646801bbae5de9eaa52ba48e8376530bab649850dfff635cb3db090042f897e71fe965d58f36ee2cf500deb48de36d9b5d21ecbb69fc9d1c2763c8ba32d10b884273f2b45c89c82d46 -S = 5ac96146da56064477b2994f953f31906fb9f546553551c4c76b4811074194dd0a4622e3a53e6c9d13404dae87e4f13b7142bea20336ee033295f2ed94405d7ec0351d880c78d753ca18dcb6b39735c588e656aceae827c273068097b39d1567f921a4f2305f7543fe2efeb0ec47a0dba7849ba4e919c388cf05de325c2399cf84f1a167a0895a783e167732020826d5735e8b0b7cba4ee338ff586cde712eaf638e7163ba45ef94818f73e7b7160243ac366dce1730b9ac0937532607f9d5f24f9fdb1e227150d0df91a8ebd951e7aacb371c0ed053c204b22735ed7688d587cba4a23f7857d05fdf97cce9f363389832c35ad291757c0ff8ff1e5a5075aa97856cff7838d3ecda3450a7c9d27f0617ec80c94a2e2a09028fca6e613f902399ef4f783e768f8f62e097a2dc52dbe096bab99cc4d01ca7020d72d0566cd6b8b0df6c1a1123247097b8ecd978925a540e05c2acd9d65d3e64a6b05702824380c1a24bd67d66f2b623f962e89087f08c5695b3f9655fdf24856a9f6561f4191ac338d67e90bc0c747ef7cd5a115d47aaa9d048ebc84c098383260fee49bdb446d1a153e51b0041a5e34bf71ef2d9b579067138a492e6ac8a693da58d5ff37743de28411d56090ee31f9e08cfb8566c7067635a30ed65cc24d40e1084d6c4164740d0770a88a287897b34fc4490a7f565827d8139577c0052f4760ef17c5f5978a3 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041ce07ae5bb44ac73b9490d62cb7f02d236e95b023c7aba070143c6243cefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = ec287cdb5ee54e8441dcc0662f98420233406c61c6bd9255fd1f9701003d069bbe9c5e71df93ae2afaac624f094c5d0a1a97482d478e2975e77a3711068eed5e13c85df5d918c7e7b1c46a47f50b9ae9b709136ab3da8d7083029033120c8a3d53721f6e33bdc042cced7f57db1b2129745d7520f4eae5ce387f4b710c0106c0 -S = 30a67f084b071c9e0d5c5f3f797cd89441932da1e5cf9b7788855d03f6f2a52d6519ae67ea7616d76f2a73016dec5663f6e337c9c26ab3a4e0bb6d3f8ea18d0ebb1693ca5419b9cd19fe747f486f8bdc40164da9d7024d7fc675b7f87b702615ba523b59a747550a26bdb8a80a57dd14698a17b6ed4c4f04fbcb3ad98a2190f02f508b681a517663a3c0a4516f92f87cd9077b674e716099e36dc50ad24f98bb74a6afd0f85318a67abdab02fa2853d206acf49f941706cdb0e632244f2be99ca1aa9cf36f2383c1092371031a99b7342714fffffbbac48ebe8fc7a1f31c40834090d7dd9d905047ec08aa0c73d1b2a3cdf6c10d3930db3f8675a97ec1cb175142725bdce1d73dc97f656ac1441c967475e46b7a94ed38d067def9a54bfaeca15a49780f5caf2e42ad3b5df0787c1c06844b28b68dfb0d675e235a4114920e327e870e2346572c3b04aa29ec476933470a0e56fdf3ec0f5e1baa35265637cad3b24de388eb4b68403b4b6652ac1c258cc56bc4cd9d3d804632da9eb23445154fbf26d2eefa30ec2916a54b052ce58baddf426680477aabbee34fc6d98e57af4342b2942c77dd8695103487203a77d4f8e4ee066bf003f45cdcabe7b57b46b34084bf22eb5c905ac76df823a0e9343fbe4a868a6e0adb58bb5725b8da3c03933d95b4012498557bb78d096b810be5f403b9063243bbec780de51ce927d7294ff4 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = c9228bd9823d98cc91944bd362aba13e16f6cfc78d9fea74c383e8be607ec7f28ae80cd8fe5f6f935fc7d5c8cd907e02ba378055f910744218426fdbf01334277a66a7c8e58185dbe51453204d77945be0343ffa64c570f7f99f5e00a96f8dd640a345f35e2c426fca82ad2409e94b1130f4f5fcf647485b0da09d75b3193bc5 -S = 7ddff91ff1168c9bf0843a1da3c141e1856e312c0d83c4052b9c134d3b0fa82a53e4e1923b051be39fb6245d6acda63026161feed4e2d56d83677ebb347b1849d479b3da628b02a3a411f86c443e7807f6b5239950bf2b060da1c6905dc75ec2e4236b8cdd77419361abd4720267ce447c104f437afab32af9e1b4c0104989ebefbaa7ec0c18a065a0c38a79ccd9e40eac3554d78f3dafdce7acf06e19e7e2792cd7c70bf1f0eb15e32c7d6c41331ad8c8a1bd70d4bf74e64548175d913999aa673c995bbe8ae3e68c362e3427c116290a9680d6d7b4be07de3cdeac0a0723699be8ad032f794610510ec4f61eaf355e56e15d053007b1d228a91b1f576597c1c78636c2202ff55c070eb3242b48eada77b90777001067fe61907ebccce40bb6b6361add71717c3a429267147b341bfa8bf0400512c538948a9171f2d0aa278aef5b950b5b7722b372ed5c2ba1e18562f0fd7b7da7566f61f5adf1f8ed1023605f360872cd963286bb5685cfda4968f412922df0b9b7cd0ffd8dbd16a2382b6893b4d075bd0965f4f7e4e2c09b0bd00217fa6bcf9e0ac71309e071c4ca0077bcca9c60ee5226ef058ff8b7a076d68cf161b13dc90d51f65babe1f4727396f070af6b3dce92586e0d31028e6adcfcbc32c71551c7d688cf9c32fbb26d03c5fabd455fc716d9a9cb82a740a6a46627d80c75035b0bf02dac08ed6f45539f035885 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 91e945fbaa97924f3e6d9ad222bb01e935b7b41df0c2207a3eeca2348eb93e9127269302bce70e9341f35f86fd42293bdfd5fe5415f88a16dbc40e1191e7110311a852fa3f2500b9e2df2d5db2798140b1bd2b1ebfe01d76690779330309468cf67768295adacf87c83bee9d69e96fc0537625c41603426491bdcae30ba847f4 -S = 34dd79f3254da1471173aff6aaf54ec5a8633b468af99d925ec258438f3bade74fd1f23c631f94e6db57b3fec9b05ffb18013cc090bcb1f871e011241b352549e9dc72349681c10bdeb1ef00f99d4a70c48488d812bb621d0e3b926876b91da56541176dcea55152d31915f9e633620886f6264c70c2875019afd51eea4ac8cafc17842e2e035233d4679cb22d329a671b061a2da194d00dfe6a3d6ea3c3b10369e0558b68456b241e7c368e2492bd0d5cbbdab42a8526acc04cf2ed43944708e99980b31bdac37e754850c0370da4ac8b71b5147ddc91dcb7509df44b3fad89c2cb4e147255b064ffa9ff758a55c045f27bdb4b12107e1820530431a28baa16da02925ffc8e84cbc7ecf70c2dab46e246ac51888a198d85dbbdf4be40e674e562533667240e043a6e8a7d1a026af2ecf6a1cd24934f6469e28b14bea0f46cd333b1043d837b5b21022c9f7dd7713f8576152431746b54c9cb9a7ed3bb5c7d027281cbdf9377187fd584b8761f5f6972ef357cf8c54c9009d9e650aeb4c9d718919706d48ac76c404875e95d60b5cfc06588e1bef0ae95c31d13a27edb86dfb643d9d2f08373d7af39783804123202f796b1a01da28932a103a817c368f9e8bc8764cb949e351e0cfeac9087eca02e097662020927940b84dce30f22eb053c02f6345f6de59c2428a0c462020650db4e93c515304bd6fdfbf882d29034fe218c -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d060960864801650304020105000420a20a34a9c3d9d0e915b9f010007a3c625bf71d96211c68cee82075ad2dfd21e7efefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = c63bd2db43b2e094aeeb020514d2439f6d8d04d0c40b403398e0140481507ed617a965880fd7d975a7329deb459ae2df5ac656de8dd95d4716369eb86796c2c6125878f1e718bdd65c825aa73368aed95613ad1c06d7299034ea51362f7777a580ed16fe129d13219784432126652ef6291c1272762e2b77bca43266211a24da -S = 18fe9f7495370f1b1a8318e33ef759e72fd463d358de45d4aa412b1c149607681d12d7da6b7640ff21b53745387e6a5c9effca633c0c6d1e7c150ac6b622981167fad90fdef6b0bc71bf87cf7aaff12afeb60c823d95b32e29f84fe500248207d792d27965f915cd9527a666985223b4b2e7d72b1819cea49c825c304eec56632188b0907b54e2fd9d805a53e58acd08b291532d9500c64ff406d54c0f43e16c5a6f40499d20383e6537bda582b5081d0db95bead3b436c7d12d5c9ac695d4b660c79feafaee8b79f4fd9147cb5a14f5c8700c868d24bf0bd086397deee79284b3a79e9b68560ed6e863da75da37d324edf13243556f66982745b2ae931e3f2348fd8c3f206b183cd8768183c92ce6a0daccaface91f3ad6dda20d5c604b5c474918fb124c494f76d68ca7192ef25bca03648eae43008f9c3482bdb7b086ea92d41ba3a243bba037f7f08dfc6912218dca0fb97a11acd0ec3432d1fa4fd73f4d810843606374c780b8fef34ec13fa6e26ca05124d8029cf7ee6f9cc90ddc1196e29c4a6ec9feaca4c2050053a212838ab901bb9df01e31b6519a9d4f019ae5bebe1bcafc92f79ec70bb1e1f1db62cd964b8a15171edc72081daf239b0f9306921444032295b4c7428873e142fd20ed2f2e598fa346f2a76579045c727de99294e2245db6d62061d1a2cae226f0aade7da4bc32fc6e750483cc20fb2f017178be -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = d34ec8c4045b0433954c81096a09dc82a0c6c799157bac1d2a949407c7ea480ba0f3b56db735951622014ce70f5d104d05424d166d084883501e029e62fe5fcd406087a8f6ae8d08c4b94f6022aa9d51013b9d7854276d8bcfde0ba4ee7e72dc3aff061cc8ad323002dc501da9d7c9b51b197d68d2c0655d2e3e76c27452c960 -S = 4082a6bb4453970119c7f4cd61253f441fba30c004ddda4ef25f6b9f30edfd3d2db0f207e8b7c34f2d9ee23d692c850a29e70906a98fabdfebb5fac91722dbab0f19ea0b3952041cc448fa9e3eb8b54965e068a2a0df68b44f2839b9d10ed07f9d92039772bf6fe6a6d4db2531a03d7eebc15a125b87ec9899cf7b14911dcc4f0880b2196e165c1e45edc0de4abf859f30d87e3bfc3cbd69ed066aeef26869ec70012f0c1d1e13ba1bed0a6260d0c412c8e4aa6fd0f8b716ce33fc5bbf3562e98c307b1b8e617b26aa3f55e3dc063f7ffe4d03844b0da97411f3996fd94416648724148bffc5900f1f9b908f2c6ff5ad20c90d3f5ebd76e3aadab7b9e9e55ef50ecf4d923249a83cc59167e65bf6593aeeccd750ef0c3f1029dae3fe1ee23678ea70406a4e4f9f1165a48c16659d367e2f1748e104ed1f898db701336c680400818cebb47529fcd1f9da787a025c316a2baf2c1d32eba2eab393830eee7a2465d0e43c19362e64266883be22d85a0efa83f3f837d206bfc96993d16199712f6947b39cf0875b3744d96705ea19c8a173aeba23c6a049aa668a66f2c6559cba601c4a8737fe512509e90eb5751abe5c45f22e9fe31dc936b7e80544daa4e26cb9d088a623ad6a7e70902196a0973b8bae0866513360a05265ba92e96fd8e7a09e35a239a0d2499713ca0e7b5dabb06d162fac90a75e9b6483b3513787b66b9f85 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d0609608648016503040201050004206befb2ccaf4b531cf9ffc53f938035025cfdb7eeae29da84ebec94e716c003f8 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 8f937d50d24a1a6ed858d2e3de56e5c23b917d5a936c87b84effc06d48041391caf42207ba6d23030ed7edca864752b99ba3b089b308c3d19668bdcc2578995d4ac9ac502b347de3a37cd685f22f1bddb3cddb0e0f2ca53a311b1d45f9464edbf55a42b48d69d0167d8fb69c89d6e8376b57277211a2d4fa0560075d2d37dc12 -S = 2df1e58e7491739bb027c6315a70eebbcf37b8e5958df07578a589a47cbaf1edb23ff2e676f2f273a1cc0babd22e0bff874529cfd6479ae5c7250f06579eb212dd3f4058c476abae8e94c89afe05746c3aea93155cf03195ce5f4eced399d2b61aab7f4060b69844cbff6303d264c4755be78af001d125af461fececad8f46a9c4b07420ca63c4212f80a751fcca6a4737684543fcf07b39089baa9995394766f69239479e7c9778c644e022dd4ec7e07a769aa75db2571e58a5e0ba1e4377e9677092bc9dee9d9dbb448441da8f4385b4d4f8ccff4b3dc3c3c3ac8ba11a6ce8caafa930108ba3603c5b0ef65a02a7afebebf605aa88511513a69b3086fdfc25c588c4d61a06219d0d5643410d3ae4d78b2f695efe4e0b82161c53bb9d4b8a83692bb16de8da18b4a6c2abbd0f6b0e24229077fd6c3bca918bc9d9f4518598238df0c925f8587fff0852c44e8107ccbc1ce6a9be3b0941c3b28bb03c87eeb959d719dba9a64a338c7b9931cdf6bb169686de1f8de0e1fa74d03419d164f2c8bd2030562705d1470415e48144181dfd31cdd4219b5d22f9a4c659923cf5c4edbde18e8277dae11264c11423c5481402e80af223f0c4faea0c2c7aefacbf513962c2f16af353ffae1414b408f726eeb946d7c4c8577e72d8f1d49ae2301cf70abee46d286a6fac1b888c334538abb3b830fae595bbb19ea9dce46a343da031117c -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = ef737d90f65532a2693ef41fe916a2b970c411409d3801c54caf50ff6a326eee086011bdad6e2aedf16c17b047ca1a931b1a0a601d174843dce7f52b969d62734e02c8c220953a30d2d0d7aaabad449788695abb2c881b5cd819eba41b3bfd47ece00b66f6d14ab233f39dd4bcc8080de03868197392625a68ce9a32a31525b1 -S = 6d2d3c16eed39f5b46ffc45a8476c0778bda78d2dfd246ebcfbc74f88c5ab742cab942de2da36e1ec2cf65a43b4ff04927021211b35d6b6b2136ef1d69671aa8b95f6b55be4751a54b8df1bd87518e4a736bff9ef849cf7bc212734b77a7fcfd3ba99327884685a146294ba0a45233b03e97a27af2f615952261cbfdb1b5bac0f5fadbb8decbc4b16ac96606242a9489f20fa74f726d3c45e0e0c515382288a8ac19ccd3eec7ac94d30019dcbfbf77f9dd592531eb1ef4eacf9c38ccc0414317a3d7eecbac02a130b8bfda18f4e0fa6a5bcab44d35e020afdfda351afa1f9feab93579861d2ac39e6c8499b8b5777a6be5ac77b3ecdb12fe8189b0bfc00a4a3e4e6041e2d52a5112e8af45e5d0a45f0b88ef66ca29076738ed07129be4493916bd885e128359e860ad8f0c0d8fb649710cc76a0d3ea701a2ba1d7e77ff9b037c51f93e9b9e162f71da900c07b42ce0f02fa633e8e987cd063b8659f25d190f3d35105f70edb65201dd67d9565cf4e718f4db2f57569c8c88f20ec11aae3ba3bc1bc78c29b2364acf2f964fd2165fe82d8721f1b16b668804468f0697643d1bd0efc5d45f8c27b7804b4931e210a1eb789c8422d7795a9b156fd9762a56fa27b7d5adb2357797ba50dea7ffd217025876ade111d504799ef8fec084e061ca0b884899701a9265969a9a027c5337cb0e1e86d3d5d1b8a0a80eda33c8936b436c83 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 5e59add32c339dd10f33de88b32b8cfc1dd8fe7684693e27633bbc0dcce7431bff7e2b943b13d1b8d47a44a286504171093b62a6e57392cd8882c4609648e5e880410e65580bfff0e422c99ff1efcaa9e901decaa89ad4e98c6d1ff9cba6ce1d0a2bbf0f2b210fc266b3d4469b0e0fede6b0dcac75e3ecc3968435a01409e801 -S = 5d7f2def0ab2f104974b66e6a7ed79a4cbe4d9c6ab4bed75f442703fdaecf0e76eef5fa5c13163b4fa661137c877e4416a3fbb4a15a2dd534267ab860ae73bb97abb5e48bd5ac60108baf4aa28eaa5b3aed8f84adf06063e575b39c932a565ac9689a6ea93359f5e5c384bd41af7627df06169ad4728e9b17f5cc7855b5e2a88d4417142bce9b45ffd82e785c6cc8774e3c78fa637ac69c90a2198909fb1b611ba28ec978b1813bfcedc2a4ab6f8a2f457a146be5a6ef6ef90a91caa3553f96a743ef0f3c2a057ffee3ea2b4a3a2c7e9b26ee2e531f8b17216080096527df06b83bc11ecb977053e5d81f6c3e30e0fc5d4353bcb7bd97906ae7eb4bb1670fe28a8bd674c836e395953d3c3e64503818e3c563284c7d21545e7038d3dffa0182b5e6a7ca50e07d7dbd3614c4b2006a4f1a14b77c3dabf98459cd33ec5b325118f9e65b851a155b3f73267950c92078c70fc5dff3e9f07a9c5ef42fc210b5d2b24a9dec7db05c12e492decaf4b448c9545ee492dc0c2a4a5bff2ed32a8a0ca0a41b7f7455e622763319054e1212c0297bb604452f82393a3a96f54b1a141da0edeef052d2f0382375e501d67b1a83d0b02bdd9c99fd68063b908da1738e88b2da99979abbf73e60a4a295d24fda59db64486bfd7eb5b8dab06dd22202d58422bd450f1f698d7ba51f71ef556c5bad3d1461481677e501dde5b613fb2ccf85fb40f -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 655d108236ed81085d937f81dd9056d691a1dd531f2507f32a81b5dec9c4ce30388792fcce182b912fd785fbc3df60cd67e9a41e626ef4d29a0c851b082b313e69e0c79b3612a6e8d7db8abd1430a555ccc5f293e92bc643933ba8a3a4b862215c30586757231995bb6834cdb6cb4df528fb6fb89ca4a4ce7dd8c37e87b38a61 -S = 3363dc1b2f8be1f660baf2b61348786a7305f4bc3e7f030318a743893e41feb40636f768a286c0e82f0638eece2d7f53f8b5c8c5052e6a942e9a99fef85e8d5f2d83e6768515ca14c8e8dce14717af8fd5a2ef209c9b8bd314e5297eb48aabdb7875d1c33efbe9d18ef9021ec41cb54926bd3542243db8c576d8bcfc61b5dc6bc8f37b91e3d631bfed66d97e9a39aa815a8c138932d4b6087b5413c888e97caa07b54541f22cda57a9d06b92047276bd21bc5ed946650ce7f9b07cc2e150bf14233e8571a8f09259dc1620e6f55609b2f2a257dfe250649de5e7dc42fd7503809d0ca8344cc92571a91ca99abe1d22bb6f56e84ab0ccbbca0d8267fadf08017fe98ec57088234e81546386ea48725e0edffff0738ccc99aeff1f3977be58761373749175e7adb270ca322f15f866a668b3473f5587ca80fb61200acb3c09bbc087419a5d4a3408131571d06f09607f8d0b07a285b79d041842e5cbb682e11db41b0c36784c4c4895d007f076d3e3ed2a13d9f0601cd4e95ed492dd57505f76f119eb3fe56c899c20aa745335fa2df73552e95ae596b1ceb67e3a533b2df1ea1ed661fe5b46e1e31b753211eb44fe683e26fa1faee65adede0c86c788a067cd1c885ccbfc0066fa94070a310cdcd19003b6b7fc836c79f19e7e402a549850719c3cc3fb4cea67de4332680c3b891e0aa42693bf113fb7210e6b0d470d30335a69 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = ab8fbba0e6a56a02b0b42f139cd656416b9bb654da952b09bf1a46fd544542cdd33e3a7c43bb9a1591c7d491e2c354fa28aab5d1f39935ae8b8e66263b6f27f1ef4fd34c02eeb89d517ecb5694ad991beedf8127c2bb21ecc9ea0ef9611bc821284beddaca43ace317627d2a599c0fece4c3821eee05d70ca1b7a5406f510da5 -S = 87615e72a27b387de06e4e8bc3f2e70d24d061abb00a8a006456ff0b8bee03924307420517eccb0eee44c1f8a7458e13c0694c1bf7855d5ab1202807339bc82cb5cb3974b83d4000751fdced787295387acb814c2ffb4f636704de4595bf281d544f72d676bf59768389d92bbb08ad9662481129af3ea0ff2a0faadad65c93ab0029ee0ddff3ecd02e0bae13c4597de92cbddd6fcd9ba4d83688db7c278ca55e5c15b061993a1a53984efffc0ed72f55f79f3d11581ade9b651a6ddb5ad4863e3b9798d2bdd7c346174b114778f49ebde94c53c406ecc6812fec601995236ee09a8df5d0663ec4cb49fc47599b2b884cde458d6cba31abac1d3900fba8d9a053f02ceec3dc9f372b285634a3b21d4c7182c891523fc75bb8e49494d5f5eb4dd001c40fc549f9f586e60fd2f9b3b3dff4c8d33978193599de8471d2db11a4586f2be00c2f03d818ccee82f183f784c88a5d04e14ec99ef808e3e68333fefdaa414be5d7e817de3472ab212c40de7f172b3e62d203d7da871573f4f1fcd0f01f49258413e726cd91a79f465dc0ab69962436dcf52162c09fdbc151853327fe69a51ea91a339138742d555b40be06df4ddd594cc51baeac5738c96d0218363461bae49da0418fc3330adfd9ec008e89e2342a9084800893b2eb86e40e27da0500a171e234098079b91e08780d5d4e3308e5158bf7b4de557662311c533c9daf553a -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 450171e919ecc10bbf1d05f41eee02eab8eede088a31263433eb1652593d14b7494f7de1dd9fa465a39918283b6726d2010a9f80edaadcbab72afea43e007a782a44d633d006ad8f57e5f93219dd92254c61f187e2aa3a83ad4e7a7fc7142c9631070349bac9e371232a307880f94cc9e11b5b8532d94a78607e0f4bbe2232fb -S = 0471456bd38ff2a5adeb19b73c35de60f07d7907479f9e6d5735dca75ebd3ef499194917287ae0c3334a5b97f2be41598917a5d880b3d021c61a7acfe9083441661f56fb984ec6717986c558a10d108fac9e00bbd5adbd817a7684edd424e612c8a7f60ff1c8056067f0eee1c6ce3a4ceb6c27c735f0fdc93cfb521b529e1002659e6fe9cddcc79c218a84ee59b7355a43b47b5c4ece8535e0874cca866e3981dec3d1996d4dd05afab27bb5dae9d6ac9dc39e957329eb273254c4e7784a29db26696bd0ff872eede9fff869c35487643755d9cd5bae01c7858b123e4f9688b1d2607f349d52c828dd6d76ff41514565564d39038814841a0441c232411c8afcb15073739f5d5c537138b9bbda60bfd2cfea2847678ffbab73eb02fcaba9e4cabd7768bc0c3a6009dd78f02a8d791f5e1e30d7358b5a642cf0a1a838b954b76a15386109926595b2862de80ddfea98e6218efb925cf5d6434b93045cad5bfd1af36e63a98c14b8f5c6974f04e5e52243bf7cffdc8cb9c0a35fc3250943d07037b319cafef02a2fd21c39aaa3da9f171f1e9c9613ff97d3a6770e7639ecbfa7e47804d8833e8212064d091e02801869bcb2bbbfc2be5d21b2da790ddd7973b6f5b9d6c763cfa503c6243851461490dfab31cccc6621fd91fc1ae28b4b1d393cb1e41d397852acd98fa35b93b6b4dd92e2d5fac7665d8c0b3f7d03ad3048b6854b -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 105048a958c92670205618120e4f1f5f40af63b03d2dc8272ba8c13743c8696683e3d051a21d92f149d4af1e803b9651674483ae26c40b4226d2f689826f4c33b86db227a589f7c9b0dbeb784570705b8535d35e3b165c771268232e0684265c19b5993347557d7ebb32742a4337d4060248fac7656de14f5833f32fb94f1e6a -S = 82bd70e07ba8994dae47a4f8d639168e5e9aa2cf70cc3c011482d170efcaa8aae5d2c8e46d63a583c20d9b7ee21e39b86429aa4550c9f2df8a955a43e2ebd3ff99e1ff3625285de3d506a95e183c664374eaccf0ecfe6d1fdbdbd33f61696064815a21e43600fe7bd45830208970bd63eaff3d2d796740fe1917196bcdffa4107f6b143a7283dff052c1b732fbb545d2772fc725cb0f1f69689b57ea25a8e54c6d68bd10026b911134f034c9f9499f001c71e67a1668dcf11e3974c6ca2658a4dae79a103b1bc3e01195b8ca7da0a09923eabb8f7d035598383404fd7145946931cf2f577c3d2356aff6e2b37f4b084c00943de3c90b9f944f42af472a7eab05cb33d144ad0b36c2d3343f67af4c78bd1fa86b5dd66c9edbba788278dc063c2a6754c114ecbf5e12ce76ea97b9b83431f215f2670a5f23e27b1614330671d3f4b5701ac57bb8fc8a4eb33d2203d3a4faaa1513471d94446a6bf170a78389738567da8206f8e2a6d906a428253e7a2bd95b26ede968d6781b5247bdaa067988f671f9049da2fd3e81a9a0e419cf077d54d524fa561a395af3d443ef4e56f217fa5e981dd693999caa88da4a58bb7cf5bd0136ba939f507fca7ba93fb95c8e33837576230a28f2e66ae1c566f480b16f7f3c770128ffac3b2fa8dc33f1455f8178b1c4dde3d2df25c49d9d2458fcbc1c1c5c33dccda3987f50455f898609622063 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d0609608648016503040202050004303bcaa2105477a151f58e5854c43aea16ba8a3f7aec859c767b4c972f6516065230af636d2de691db4bf4eca0591d5df8 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = c74267ab7b27fc613890220c1b77f9205b8a8b4a7c8aa4f8c5f1e41bf5d7122b3216b36c42addb71fd6244de02ac9d72aacf24443a49774c5d6da726d14e8f1360de644112578d4ca1dab4042d561d7131ac3614b6117070c6b34ec9249fbb2c3ae2a1af53eeb7fa0a409b0602402025d869e94356a9376bea0bff8d5693407e -S = 5daace94b6042b542d3ad0dbfd6987222d598febc1e612c89c008c8ae828767cb3248235febf65a100367753aa8c75445b08aca203a83d471b090c4b40eccf1a375e15e6db3cb49eab5db7bd30dd0ad2750ec9eeb09f1ca646f2cd7941cc53c1a5bd982032dad6c022f4958785fa37caed46c67fdb8fd0b8571494a255a0d8e093b79811b013e8bdd0636345c59fb31d1daef1ff7c8d777721cca8b5997cea173c2044ca0b0c552136ef57d5dbdc9383f034daaa20a61d6db7ba504d0ca67d9d3cc8df5c52603a870010d7024d7fc67ff2b719551ce5b1dcb3228c7c17b0772e3160ff940789935c563b72ad97302fbd276a7d17c8d6ac70866d945be4a19b3ed1256339c005a03c1bb0be9549d25a94daa4459ae2f6d3b2b4ebfddc545f76c3fd761016d3a4a79301c6d94d4f84ee9da965f1c9ef2239c6a7cdd28f4badb57580177b395fee7c684b70c43d92b5f5718e3353dda2ca34e10f0a1595474b3f0cfd90ffcd10c3ce987ed72da95aff0d967b582f9c7ba4067b77f728986bfa3fec94cca5104d361c185caaaa1daf8ae9a54553190d54e16c86604172cd53ff7b37060152d1fbc61e54817580aaa6a99ac1e577161c718c6810a735abf2cad04c51c901b26540e0546fe218be87b12929f2aacd48d9768c51d690820876b1a73bf3d8c86fbf3d37a0f2f8aa9f39dc8b86e3990001cb3ce8fe75d41ad863fa54acfb -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003041300d06096086480165030402020500043041bc09c6fe8e745e4fbb2fa6312743e27bb5e82870600e0f80b1147e6ea9f392710548d938b910d106960f7d1989f8d0efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = c0af5d4f3251d02d37abc8770b5884391a66e7a1700087bc714a0280ca8d910fa794df3a27561b440cd54be9b845e49f5571981c535b701817221a54f12984db4f76aa883158acc8dd4d23a1d422b5f4045ce7ff3fd73325ecad5bf2fd59fc5a211d66413aa1ab4111dcf6a748371ebe91f07b511ebdf96b59b36a61d4652112 -S = 326963d3bb01390b62b4dc1326248ba0c0bc44b240e7b01fd5b05bb138777b31cec22ac0b0d53279ddeb14d86ef2acec7b0c3ba1c8e587513279ecfd6b912717d316ec7bb6aecd56004f9a110e3dafaf3f3f9997549e8b65751d1c4574dcf16a0df08ab705289a9b53930f2bf90c0a6a8f461c69d659929cc2b8514f6c08e07c0c542ec8bb2ab42512f48d8c866f4db4a309af0114e6b9ba1c382f48580a9befad7dbc1d9611de97fede893243fadd94dd78e99f43199d76ea3707d6c8a2e1339b534238bf1bcdf5c2b7144b616872c7a08d4d6399228d508d01c81e7dc345527ef087ccd983f94fccc1f5f8db9a34eee662484881f38eca79426ad87f4ad7ec35dc46c835ae5b38b8bdad63515d710eea32b8024558dc1929e704225debd4e9a770706c78057678199e4d006d185556f27bdfcf5330bbe9cde8271316f460efa53840dfaa30cc1f230395c4f12d7e0a0ae57d71297dcce3834a27b4f29a2c8381eeec3ef4e71a2b54ff1ee09147385f5e41fedb3c3df398cb53e1d19c97fc0f5f85f2fdd0b42cf2065fb68b7a2850e065016e9c3b88e4a0d17370cc63f771de00536c57739625372ec08d8241672ce3aac63dc843d17a227a7f6c68b85eb39e4074bd7ed49682242b213ceedada0db1f2ad978620c43aa88325284588a5244f82083c4420572e30486bd40902b71319c9b246ae9bd7d994f9396ff2bbe844ef -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 42c5ea617a25f019329ee172e4932485518dabd01983249189597473b4a6616cc5ba8ee693e0ad1d76e0f0c85ac8c0fb11ecb24cee2cb7358f7593b9fa8b904aec0573eb6d99af92a899d9d0fabe5cb349256eec9797422dd60d7fd5fe73f2cf5ead7fb72fd85e3f6fd284d2edfc5e77a03ec5f73c4c2f420728220fe9e9efc3 -S = 6836dff1bea541916b9ccce2695e921ff27a737ac54f4a5c3b2facee80a8dd3bbfe86c93a1af8da5c6b3a92c445dfac7e215fa9f3d67c9589dba858a223f326afeb8f5d0f92f28ac4e3671c22b5b4e0b4266f776aca928bb0309929f2c452b62d462675cef09388e5720cf0cb99351d44059790720db82ce014d7e795826833284bd4205c64e1330e30e09ff6220f62c013c117ace4f4286cd46e52694c4925aba12a5278e47de910dcdd820396febe5179bbc6ccecdac1883bd408530bde92e93c49db2c6fbb42e9705f29703763b21a8172489d2831889bb060505040940e60f7c5cb9f58327c3d3f7cf7e18ad60e877edb65222a699d4acdcb358fbc87e1e461468cfdc82a8cd7fb1f82e05378737f4aa741a63ddf6039b23e1aa19d94e7087915899685add8a8da8f64a93707be0b6354c8e9a8aefc7484bb45cd0beca493a4a0aef0b6aaae801866b905683c582bf39f9cc0768d880c6e4b331da86506b298c180cf95fa45e532483c55544371468088b4e378f37976c397e09f89081f0f0b6f4ba3be6929957f55f14a88f6beb456b70e6fbc6227e98c1e8a4a6f734c9080c13ed58bcfb3456cbbc217653835000f54956d839d4073571d8a42fa2294df1a747e88af53a16df1834203009cccd6d61304739872ab92be79a4462125ebc8bba909ca2b4d91b9e520d6c681c2f92070f156e31a6875122993e1d94fc3568 -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 3ad62d183432746cfbdac6d9c87148bf13df52e906f67c573156fc407f8d2f576983754e69164298b20172741e02dd27683c2c889bdaebc2caf5df5602b7995f7dc14b1a18cbdba5078a3607c8d7e771550de8c49eb3b752365bade94dc98c0ede585786299a661b643fb99cae388d26441c2da2f7ca0b8fde500f02480b2fea -S = 817ef0cbd8bbe2c93d49bbc09c5d5fdb0c36ad983f0e1f45b41026d3efabad67c69aeb07a0bcffd57c4c6ce95857ab1dd6e786f83d2bc7460366cf051019168bfc56edee99aca9b3862a77c8a9c22787b35004624a7baf963b6e1be2530b0ee43fe44bf21f52e23b2ea0dd7a9cbd77c960d9269bc9efe867f10bab0d27eee85fe95fa90ada2171e9c0acd17ccc6132983276d0c6f1260b8e20ab84ab4eaabb5db220ae7becb26f05e32df93d2a759a9d2d94fa6cfb2a54ef20ea8f486cf587eb2977fdf17e4b65bfd66497aab225254d53cba4b18c9b4c8e30e6f5010eae0d19d53b17c9ba8ba0afb5109dc45f7e39e604f57d1bdfe3a2354346f462036599815578c497a9829be3fd73b4d7fca27385cbe44faabefbc25fd599c3e817a606dc53544e6e10cf3182fdb806441d470f16168237685e2a384391c3b15663cfe9a00f938fb7f9362752e4377217c06c7419a2426bfbf76b503be486a2b90146e9c75718b208c8fc492f47d17e4e8f3ec9b1dd5a067cf1e4ced4617243217518653ee3f30ab3a2c3f95ad15e6939f88e169c643ed2056d594fba35c8e8fcda9f7a5fbf17ffc42ccefac0aeb95cada9b48fc4a9456626ec017b8dd995cab7720cdb7c093ffbd3b2c149cacd7a2328b6ec825376d19ff693a8c8beddb9cf2c67cc22bec90f1d4e0a310d7d7f81582b56fd2127fd7a9c1d3b8d1050ebbbf06be49da1f1 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d0609608648016503040203050004404f6c763ce96f5274b8ea00e1e795e0afcc8a1d1fec8879a033437d0c153b2ef5ed766002b39b50a10f9cc919f57cd0679b82940ad47bc8b5961061fe1575eaac -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 96c824575d1e537b1f8d27dda15040ab262f9416f0f61260032786362becbd41404fe9f8a9ad46b81f68fe16b3dd4b741396dbd209c078e744dfe8705bc012c90faf63bad1eb70938457dd7b83727d05e689ba04012c38a12edeb5aacd10342d88515a46dcbf1835d4c18ab318f81f872772fb54e12199b5488cb58b87c56996 -S = 336a1580b52f2b15e7fe7eefe6d4503fe0985bfcca17e5379d17d210be01e44394adce8d1c482db58ff71b6ba418b069fe15153ffac74b3f7190df14791f8532adf655721a5d113df77d164226b941cabc035853b795db3dbfe64a0a89fa8728071cec0bc1264cd9c7d43b429cbf868cd7e2ce9f5f71c6b1c9705ff2d99f99fffc6bd964e4aa85ae127e074a95e396551418acc46fd22d61711cc4dfd51428130b0036c54120723bccc8268d9f1739488e4874c7fd77a207a28b97f463fa0667adfddb34adeb6f11bbc1ea2e057120ccbae92c3504d14fa4d87768e435b1479237b61178e48232c6884c94f0f287cbd135ddb9629678d7097f8c966d1b74f288a8d307764cc34e3690be4e790c57627ff1e6ee2572afaef68dccaf441575dd5112341f91c0f20efc8a75047672c190403e8d5aeb1005e2040502d7cce97cc8977315aaef7fcc9c5b0029246839134dc72f72dc2e80e1d3d5e48881dd71f6b2accf21635252d82adedcf86f58dbfda3ea1c0624fcfbef191a89a43d5fbd62cf6142cb26c4cdf9cfc0d8c993b3e80d551ec56b29734ba77dcdb03cc20912ad85efc48d314c42b15120ecfcc03d85a43f2ae733fd2decde46e535aa84415bcc7de4203869ff945176b9e7047c5953bf241e3b537a93e62b412cd81591d658e7f55c4bce859bfc56683abea7e6e1f87f807ae05c52ab504f0341d301ad06429fd964 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = d44ccfb041a426cbcea27f0d5e2a77b21074beb5c175bfe5d39a833b2cbcd26b81519cb9d4df980e3bb72b4be4df8bdd56502492f9613baad984d132a730ca8d011e4e54f2b87060bdcf0d24d68cf74032a95354c0e0401238a4ba981310bdfcda1dad28a417f5e8db52ef413e1904052ce714a41fda1745776405157944f4df -S = 5272ca5de6f01c255f59460bf1789ad5fef5cd25345d701c045c3623933f6d44389c5cb6eb3746b0aa75ad49cd5900223ff998d5752ca0c164dffa90cd4a3857de3f4c66e9d3c19bdebc842babc4b0fa60bdf53b76efd35de73230e283a590f4f4a9b7658ab1e1e0e5631534710ae18c7b866e79be08cbf3c30bbe6c0daec86237c439a7f63e57640263a75ed980f5180dea5874e2af8348bb15b833055936abdd01f8e5d913499382496691b6c60b5b2aae76b8c51794dbf9d9e852e62c410e9981b5663c59a0e5ba5c1545643de0fc9397150518d7e6122334246e277570ae2bdc4e84e916096000a44ec2e68943589d62b24f45594f35a2b7197ec665d45c3d9d403e7510f536a0e214cc6e3391c0494c5d52508e777b851157ff091995f4e0d2131f9e40fa4e81091e46cc40c0459a4f2d5c198222f0c7b39a5e2fe86a6f964a966d1e66ea550627d4b21c90cf3beeb8c4901a2ca47ed8b3581f37852f582382922ddf0fe0e322ef9409ae860b251699220efbd41f09968d2787d4b7a79ec4828b9ba1702b5da7751546ef626f2c7507ca4201e1845f39af9d813a45eff6ec0c234ff31eb9c8c2f78a0d70952ddf010ed03279390e13d6ea464171831ef86855816f9eb25c44e94ea5a40a6f134a55197415c7b621c7ae5cb29ed27e9bab16c1b6e7747e1462e64b99f5b8d07aed6c92ebdda2802269cfa3827d3e65c8ee -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003051300d060960864801650304020305000440b6f769c5eb51469bed21e0e25d8eb3b9f5909a58eaee7435ba9dfcc3bddd272f82d00c6c7992f5caacb7814315f1f58aece9fda52a15a6a80a179c02bc194614efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 25e0b881e32da938611b4156525ce24216c168837fa84479ecb72207e9984adb6eb7393bb3d607b1469d9b7c3f4fdbbefaa4b0218850919a7d66a954b315129c39eb99f7dc08df5c4c8c90968f3ce37b66ee184ef3d485f83d308521aa2649d28c319eafa2aec87031a1ff5d7e933ca56a2410593425fb865981b7976fca021b9d7c3198312fcfea5d0093a62b4a7c49a985c005c3a7ad816e270b25c507fc36be1c4cc0a07cb7c6fa130240062793b18047189aa5e79b16fe80a6955191f5910b701bc1aee6dcd5cefd57194bf54d8e208ae41202744190d5ec8bcc2f977f11461a5cb4306fc9b73afff2863a7b580d454bb1fb8dccb1cbef27945109a8f5a3d2b1a32566aa4e8c01a62a1d735117ff5a6a3cc7e70756e7df10e97ee75c5f8ef89fb0a97d7a35698069f59a9f365d4396ab9a764c2fbefb840faf5f57737801b73ac6f9f524167b4f3a567aff999a0db10d55d82155720a5ddc63c35b6a632a3da59c16bd0c143c437661dcd339652ae42f54f8b2d8e52672613772abfe8cf0d6ebbbccc764b51b3eda2ae28d4ba8747a430ccc32c73baea63d050b86210c485ac9554606070764cd06b423efdda4059fc45ffd7193f7123d14014d5bbe5b542476e7bfdc4905731a0d9987fe4a68cf6077c3df63778af08a1f4eb8f00a4a8e03aa8726f43fa829d87c2d0a32e16b47a3f0472a6368ec50a144234c802e6919 -Msg = 1fa4b8433fa5d5d2228abd92b49e6147f7ed6c79a557102517e406b26557d026cf06429a5be840ecc0f0c9b38399357860c3ba23ebbd35b377a3273237eafee8a33997d01d7a0048d532820cea0ddf65d2bed89efb05f2b8b2117a5f4509c71c64e6bfcbcd839d5029f7f1863022e7781486cdd41d58d09c90d7061fd6ddb228 -S = a65d94748b11294edf430b91e649a7fcbce5d47ab1084c0dac64033e582360f7cc18c1b7e71f8cfa3c0677505fba6769af39bbadeddf6b3ea1031b103f3fd72f3c4d56ff6a75fc2e16c4eeee8a1d4be05e001fe210d07c1df1e62d17b9d9def6d981df183c97b4bfba226cf88dab793eef75fc99b028100ed522e98de4dd5c26fd954a928619ad6024ae454f11f1b56c0c7f04442bbdf4ca282bc76f7f054d5195a5ca398d06e8f149b0044d310b74eac7a14c2dd9999ea248f9a332b62ef97867a4e4e312305860a8797c5f9bb66ca4fe13c054e55948b1e54dfbad12015854fd4ee347bb19bc2b59930056a712f090fccd9b31c96b3426ddbb16c4cfe130b0f8327fd61e1df46e093f6232cddc3f9b43d8b5a7b8edab6937d869353cc3fbf8d050879b8fd8793912f06a603a1936476247ea140212530397e3ca5a593899198e9d3ca1eff1ba302a0713183c7e2d60a5492fcd8b1df4e787dee2d305153ea690d81b194205a54425c1e1df4364a20082868f09b5d11b5e5ebb77e41b5eb91d4ac73a75d29f7bfba2e056dc8d19a483c4256f68a3f4e80e2f8a801cc1401286dbe15636c653a80dcbc73f249fcbaf4b446e21e9cabca231615d44578e2f8466f22e9b2b03d21e2f4e19623d15361336763a28dd989bd5a912fba53bc4d5ea1c790ba81f5fa21ac1a0fb43fe5a550108a27041c7e854e7aef824a29ce7ffeb62 -SaltVal = 00 -Result = F (3 - Signature changed ) - -n = b10935650754c1a27e54f9ee525c77045d1a056baedc8c1ba05a3d66322c8e2e41689ca02b8e6ec55d3331cd714e161b35c774311540c6410cc3b130e65cec325377ccf18a5d77054afaa737e65b68662327627f5d1092df98c08b60a3ba67599b1406986f441528d2f1f5d6fe5ec6b8aa797dbdb3162876b08298237af81c7004863576af572ddd66c487cf32a82d0f9fe260f8f2681613208aec55723622f50d3cb3bd33b1226d5b5b9ea2c97a2c59054e31536849ec2f0f2597c077e621ddea0a22ddfb1df925c9f1941cd431afce0398d28e736cfeab3dd7f062a65a2a4c1ddca1f32afa03b4ddfd8b7ca40cc0ce2ed42229d753f03cc6d8bcdca76ab7c2703c5ddad08aa9bf9a27740a8b23168c6b55917bd3d5c1c057c34d1efb1411da51ab745519bd92b9432fea8fadcb9a70e5dc3adcd3081d3333507b7b998886e988296628dd7265e64eab557712556cc492377f15a078dcb620a6e7f051a1fb8754efdca3de253dd0aad4205b032659e4a4fb307f074fbde340702b5911acb34737d7834600cf2ac77f62f83ccc9ba78ff911021b9f8ad1bf421430ae0d64916944b504542c0f6263c48e5e233ef1869df1efc2ccf6f4a95e4db2de7b4cb1a992bef6573511bab4bf2cd58e72a0c235f56dfc182df4dfffb69433a5677415f35d84f5125f5200eb57868cce6b74c5833417990e318372c9239a36dca1a0b28809 - -p = bd4e8bb7fd7ef1e39d71de06b0001bdadcc81b0edf2226e0d056b7eea70b2249000279cc1c04b1ac2919014fc3fb8b62baca3e261601fb0a58a9f67f03cd60085b2d43906d36ad014f321012a9bde9617478a0c10201afd53f2207de3648afd1d737afadf7fd2c0b9824d4f66b2c7dfe93390888ac088c680c27b1b2486659ccfa8986c8c23f78f18b5815a410328e629e7440221bffd8ec4722bba3420da5234f898f8cd7e6d7dcb1349bc4a0b665b41d930e3957cfdc88797aee5b2b27dafb5ba0949e3dd892f490212dfd249f4b1d99fd3b72695ee0652997127f0b9b417fa8365ba9fd103b978309d9baa9d401902cc107cb8d2af7ce04660900e3707ab3 - -q = ef67f69838735c055145d21fccb42298642177fe3fadc39070a95e4fc04ff058aeaf9070b4eb2de1cca72d8533bc55206d2ce9f2895b148da67c89e5b6496ba682f76bcaef69306a7fa4fbd41a838bdf0fab3e7b56c27a8c18dc4bf970364dff7427cdcc6f532b49712282370a718b7d5287bfc02c4abc35ccb2eab3777f5e0d8a27ff9ebe13e725aa0a0cd48aee1fa33ea6b4ea965ba42fcce7af3c528a6675cedf4969640f2ca73345dfd322620df9dcf16520195df8232061e2bc89c12de24838f255e7b1c17713ba435d5a351e263350198b3fb881b8ce0acb5aa58b7afaff184489d167c9af21e40e2ba9fa69b44a3854329385c97df0de24dc283a4053 - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = d65a050fc06c9f176a6be7a7bcb0a9f074112ea5c7fb03b04bc2fb25143477741d74e5e2ea06873a6c2676bf255ee6668d57ab42b3f0fd40278d781418b16673bad04183ea5e7490152c620056f4a989de33a8a199363f360f78d5a0882ba0d4731520da089ded812d26b351969b7bc1314b2caac1f851fcc82a1cb0abc9abfd -S = 77e7756da33c3918b94a1faae80f2081606e9646ccf2be6aa16f2b4fbfdb8ba57fdcf61e892cf9b77d60df62c07e56fa34177df466710c7f3b4c5084647bc9c9a52d66d080b3a1d6fac9d439cb6f207a72f70337ca9c357e16278f6f846f7028345dc0ea8139359ad62a103c43a922293afd300436d76daa5a92f940df6f21f1c442ee3d4aa8488defebf29127e11413cddf4471fc5324ac14ffc97403505867105ccaee26c742082472f6dee0d985f05777d6faacb166f34da96057be40530df9b1076b645272d154614fad693d4d5270670a20b71103c0e740114f3585c2ae02a4865e0277a76eb173bc2ad65db5e0a9aabc5d47f903643a1cff148703991ddc4e05ba766712a93d3243bcd714d067c8fb54eea3c3b5e69cef976c8794471b5afbcf7e327f14258410394d388ce095e5a623a406d33238d2c37a29eb1d099a2730185da1b2e295a55f74b555a6d6beec7fa7b9b76d916e9f487547d06356ed9e3ba818e31825e97b465174a7fb8404b7da84020f555247c2f03a407ce5afe07d3d9df9c94147697d0591ed2ff6776ee778cd74c07e071bd8b2260cab2e0eabb4c97af8d5ebdbac9323b0a73a9d93d27a635d8d5af1651de596afd4c9012f9f8840d05e80a2afe47399cefebb70450fc4b501fd69f67867123e95a6ba653f69cfe3cb5a38e3ffd92d2a37fda91c06e59eef42c836b50050f8b9fa808a4a114b -SaltVal = 00 -Result = P - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 7228696b438ee71ee4be5fe548af7423508c3de7e370f6cd416ff61f94d5e140c9b21f4b9d968df7fb9972be859eb43e71d94cdf968ff7b6c61d2ea95f3c59d41d83402c322ec262991dc90ba7207dfde371b8fc1782ba96a7f91f4b22f90ef117a4b2572adeee2966534c13d5bb37294e5d6b878fd1a9348c0baf4d0695675f -S = 34d3fb114d6871eeb6a9cc9960d655df44d2a5c8f1d8bbf1b3b03896f5ba8178c2e92f8c420d537bf9f8e23866c11d0e02e67431a1506b35f97a85ef220635a28eaa76659fc8fe07d0d4f06fc43c2c4ff96f8e27965078c67abcab78faa4299d345ed81a442698ca99d1c0e4f0baed8095dce5d30add437c1f06f79c215cab5ff88eb280de1b75c3f19f8a9c8810143be9e127b04fc0316d65e7cb4af7786886663062d88ffcd0e64c5e359874db6bb63f91e92c14a4f3893d6beb209d4e009d646d14d01dd3a84f445ad2f54877e0b529356d561665e7be8332c33dbce60d0b2075cd88af0bdc6a0d8edc2efdfdacdc5bdb4bd3537f28ee523c1a355cbf94c04329fef5c75726c047caa8119ccc4e9d60f203b0fa48400e07e9270758b99b0fafa65c0cbaf40cd3408716e257c539cb6aee3e171830e70db3a5110ef5a2561f87bf9b56ca69a61f7abb1b0be64d2627d7d78055f4ecec34c9f9768cf2c21f5ce656d069799476ba6c2b223a17dfaa6e958b046658e545ec4a28e2b6565bc320296ea2a8360b6f980d8e81567a7c40a32c82e2576ebe9e2ca68c46239e2638737075c3a0c0dc68795331700cdf2ed1c81b44b69afbbc7776e08ba794be48f16dbbd8d21505d8749deaa470aca86c27314675553afe88a96b80a67e4257c95a57bb3e9262977588717b54814250cce8bcf8e260ec58c6866903bb3f635148bfa9 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a05000414e3a0e0ee761eba5ffabbc08ba0f2fd689e143a3a -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 92e658a7f7bef5990043c260671864572e070d373345af8304f76923f4f4464e6fcd26ae8a0bfcbfdeb73a7997208a2ec8d8bfb502000bc824c572ab742b7e0eef0a3535de554856aaa28d43f1e7af48d9822557a57d6062860f4909b366ea75bba36b841a2741260b0da2079ef73c6e0a0e26654444171ad1ddd685d82df14b -S = 4496155562e965348a09e9a67ab0009c2b74275a209729eba350db82e066527d9294cea63a56ba53718250b86c64d29b327cae24be1d1b6e3eb996e539e213af4739a5fb52970e89d6ffb0e4f7074603ae6bc2afe88379fe8685fed5c2e30183199702b2028ce39192b35ce3a7111573b148ccc6b7bb15c6aacc4a72819b860f3704a0660241a5339ce3ac7eabb8eba25370d690a0c478b3be35f3613e6be74fd9904d32bc51762d9c921276159e4bb5930aee4ac654b51c5c77b84af7f71c4b88714b1c1bf23ba28d3ddf32906a1497bcd86fe2d8a6f369d145439119028c82d0cc2eab42a4775193d7c3db38c1b86c4a4c697d726e924120852dd747da3bbc77a906f367cc5f9303b6a4cd076bfd4237975ec9cef8ed1d637f25ac0ee20d1bfd918db031102913f8258de26d3319268d97983d29899b8a394db559a95f0fa46ec4fdd77ca0d901aebf952c321bf38c2e6e7943af071a7492b5220e4ee1a376c9c254cd958a743d47b458a93d993b3f011d81afcb5421ffd4305bf6385084ab3fd2159aaa76510a0bc20abf5bcb36beabf9e1dce3472961998e6aad1a68935283e62d49334fd1a3e56cac2681a9a172686022e1ccb5a215333da9dff877ee2b38484e4824f28eaab90d2f10973cb67f0b0ff7b32733464d1553f18306eda6cb50155a4047e0e39dff11524f97819f73bc3482df0e7d65bcbcbd4dd23f845dd0 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = d51a8b58c08bd2f5d5cdcb0dc596e5a2999e86d6ffa6fc09e5b9b64246b2b4d044fe3c3178a3cf3286815b58f4d8b27f3c0b3bc11fa4e7993d976748e3cb9d7824d650202b0923a7cfacc84c688a71c5e1b187260f739f0541b0aadc19586bae9a2b2fee81c3b89cd9d57ab1cab40abdb216d3cf771b0b951b8be5c4905f08ba -S = 068f422fa9bb79c8f18de3cc684be48ed59521ad0ea3a36326f0e4f96db1f2380b4e6a8d67f15a13b68ab0aee7a7b4d0166d94ccc1ac522de51052ee303c56ffad6d72912443ac8433c4e10229d9b9b605977bcf9ef69e33006c50e6077f6f0ac5d56cb9ef36c3de96653748a9d720841c9e4993fdde385ef8d5197b8da2c9c9b029e58d5d28c8a4d017556f31d45ec3dafd5f92a99c5342f31207b7ca9574ed043279f0cf6b5ecb4927425e149609009b5fd0295faa4a189d093f9635de49c8caf34200ccaace04c42c2f57136618932556a20ed057d60dfd87c8343d3a1a3b8d7b760453877ec67a535676c97ea65fc5623b9b7eeb5419840a27d872b199686381093aef3e968af7c4faee2e88fe7904212e6733c6571102cddb6d222e51aa19eaa59afb7799b0590fa6114c0d0ad5a4b09b104c3b0d1f31c8e90d8abf26516b72c7d0b1533bc66ce4d0e25d08454fa766522a4278080a42eb51d064101c1d845361d4ba69809d1340ab354f907986f759ca18d62861370fc4a5fe147aa6504387f1a5285629e3fc92b53abaf66d9bc135818748f59902752359f074f831a87fe7fee433a8b564e61b07500bc0610f8f17a172f92117edaa9b9e6f5858326590328cc9f12ef630f14b1459f3e6db8f665cc9be64285ad681f5728bf1b1507a72769f1db7ac1231d123b6cbe57f647adf4956b5237e7f754ff910278de89a7c -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = ce5ccd9b81d0103e99c4bdd8216b4cd75f4063174ea2eda94fc16cd31bbe9057fc0e08f83d20983bde3f6c6b8db9acdfd24150808a92368596557181d445e5a04e91112db2812b58035d72378d8bc00a1ef75ec373b81dc6f1f0a2ed96f302cf2eac8f42ca3df11e6ee678440a28b0dfab2a36eaf35bcbf3c759a71e47120f6c -S = adb58e2ca61b110bcc5697d845e3f035fa8ee93203f12475ae3a81ca0a9820d799724b3323aeee7d3d6e978f324c84738d6b56c37dbd15b71bdac3a4102576886978db6d78a0c0291886e3eea01f1e95565789d3998a2613557202cb598d560c1e158e3c30d89a4add63fbebd361a17f332c5c69857b648813cd90c2ba48b720601e9b0533c6baa740223dbd8682fe0ddce8a6d9bac06931ce4d0516ca1cfd9cb06cad6fdfc1faededca19480c247a39c5e4815e79dfcabe5f4fbb0ed9ba17b4f7e25f1c55ed71c31a5e559c60158bd66ba199bba3e091e20393377b3a4561b9f07aaed7c0dd77d41984cf47bf34359b3a513618c4595be045750d47788b22cdf102d7d10726605706b772d2e773215f52b9c073855018022848ad75d7483aea8a34af5a900025f71f0b46c587a550dcbfa011902bdc870d6cea895640e4c775c954e11a3423fc9e0d6ea4421408816ca066586a37210c7ac8aedf032413bdadb41c0e6ff5c57d4a77f71067274d43ad9960b895734aae6a1176ded2883303e24100398a4cca23dae13d018391a8756adaaba709354b799f22f27d4a5517967acbf694e066056c49da87df46829c1e4062c535c17b72989d7eb045903665576e6144478e8938b0b2fb4a916f9f2f65990b683c49adeb6e6d6ab7a7c29c530217626d1429025b7cf627f72c4c588ae86ac1a1aec4120bd4108943675e53bb837e -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffff003021300906052b0e03021a05000414970d2e4e51ca9f81fe2e46fe8ee73b728122b0eaefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = d8807c9c2e144010d462ddeb70445182165168be1a5f33c22346b6cd81e7e162c16dc2a77ed3f80c7aa76b2ced0d3af81c06f5122ef20d773b548861a7d6f96cae8db0f73f7d2ecd0e60dc05e5a3fc263ab2df8f07755816d61a72f01b165ed1c766af531a1bca9cb915973b000f7d5499dc8efd4eeffee71b21da4188aff6d9 -S = 9e7c462e899885020d173f427cd4e15994749339dce4f39a1916635010d984b6d627da831d4264ae8f929eb66b8b14938ae12ea74e4a51877facfd402d0b6945a299ac6b63ac800dee3c2d5e64c4feea4ded7b3523f4fbd950e8647c32fe9b2eab6c64d74fc90d8318d52e482e811f74c1990b80d07622a35d7ee430c5beca1997f942117e48146413a3d07cb42ab16657176edfea16f5ac4cef9870689ac51edda514099ed6665b289e0ad9071b35c9ebcf06b0517260e47a516ff852f278fdd7b3f54db18bc5491a44dc87dcdb92a3e9282f7de19db80424703af856a361a9c9f685c3b16efb5474cbe23c8f04e3d5c5fdd0ae9dc5d73f9f04e267bb4aff348c55e2139fe554dabdf99e90b0ad20a01c1e02af92fee0d8a22136f8953bf999500a6d1a5478c9c6ecfe123b068085928354efadd5a9e41e66a15d73dd5966eead4d39491ee2d74bb6ee5608089ece479e53d599f9c19392ca064761688317d0d178a627b7a9059093107f727f754fd538e223cc6f01ad991c4c35164394f4a60da9de6b1b2dcedd892eafe4e3b04b99ea2f6459a2dda8eb7ac7020bb12656207470362c0a10ea79cf3d5512353aa87cefadd601f25ae15068049d2dc158c04a3a8e00ee4b8af3a430890b572c414b28abf2aa14c5403a1fd918baacc4f6b4f80446dec87ef2c808697f0fdb8f142876d8b7d8d90536e3119bba38fb4e1672ec -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = aefe857b2bd74d6bbc3d1376cac4aa6df362be9d5d77c5f54a0c336bed58ed9b7d8901b187c1948a885e1c16bb7ecf0130c25a921e53d7d37a23f9f2c8768ae732a01857d710ebb8658d3ab7eac09ed6e7f3c65aa7186d64ce0d895e351ec598f5cc3233c2cc393f7b53d520fe91ff36417b69bd9fce6ef16f514976db5a86f8 -S = 30de099e81b7207862eaee842f7bbca8db96c4348cfc148da9ab9bd6479ca79f09d9cfbeab93c20f58351d18f7b88cba4c1ddafb46ae5331b75d216cbf6fac92cca17f2cf7142cd42007be50a24a1c53ddd69890673ebcf6d476854fd0a5f76e7c53b40890855ac801ff2088e0d427ad02d8e43d499a06670ab6e8b43f661c16295f7c6b04ac5494ccf27bc49b5c65233af02d6c15cbcccf40aca45929fc413c566bd07616748b9e5cc8562879c2782c1345973f7777f56ad0dc290458b6f3b5a88f160a8eaf8ad0fc394b283c1acdf9bcf2eccf88164f1b868d07a05b7239e4858c2f3d076a299a1ce032ee4967f7da07198d3ca26912e9ad2db79ea8f49f21544e82f6e231651805e934524899ef854255998c1cc59de1ae49e482ac801e3c678626b3b79bb6be296af03c863f89c73a87bed864636eed84c0a5ff05cdec57a3ec76071137fdb3cdde2c4f03c3bbcffeef28f298dd13fe669396e8fcc3a478f4f3793693e8183d96425ebb92f41ae373aeed30182f8a6bbe6b3440ab2a22ad0199bc59fd631e221223abd2358ee6b8e879b2aac64fb41257fc5983ac3e2de5386819042832a8bf53313c0d77767d53a148bddc46638acfd626b908b056c71292c0f9d1b1ced4f2d2ae70e70de9b3dfe6b150314225f21c03b8b53baac3432a72767c09f360393feb18854ea884e8326b94c225d871cbb003bb94d91a74b358 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 4793168aa3ac854a7e0bd652b8a57666d96ddc389aca257da748fc46a38ebd8e6c90da0fa1057d5b621c6f27576a38eaf42788a7fb9bd50642d346aab698d0bfa0a29fd22708b7e616fbdbc4e0b4ad92e2ab18a7e70aeb9ef161c6a9379b3a286a312c7b3c9d7a142312e2d05a6a1f872a6054e267ffae6c3d5a45ec2d7e44f3 -S = 9d2457bf29a45871f04f476eb7a43238d3ddfc7c61fc2ad160335cd1c42ae0da5eeb2ee10f2528ba1e645d27b306f9e833b86ab62b1c4785d9249be1ea9e83e80a5b3a774f2af61d6b536d7670833bca21406cf5dbdcbd2a9e17b2679dd33b026351943e841a7ba4fa3f18e2e278a9db180757021fad06befdbe75f6c77a36518a2c3b88b6329849fbb1007c7ddb7e278b64e319f93b4713717282e5845a168b7825b47f23223793a7a93adf68d5b83c6ed2b6cfd850a8c81589032047fdac6fe091e0369a07919329845612a797dc7f9adfab30255e672d8fa8639a597e556b215e83115fe2268f1c9870b1ba0caee15a26c45acac368baff4018eea4414eddd86678e30d2a46ed879ed6795641af64cdae0f94686c134e1f05dd4f59936e1450a26f2927de6c44247bdfceba2b14cbafcded775da0fb0b81baeeb35e52fbd44d7a4668fb4c832ac0a9c622dce6889a1df6d15ab6c956dc4249127eb7f1b45379e56ca7caaf89617491f5ff38daaa5f0d58bf8eb0138919e3e9bbfce08861b92df0124647bc175bb000d8d0661c71d27294dbdf1112d1461081a931c036d5b2e204e94bb3a31502d055cd74869fe7ef5ef78657a194b9b4900f8882c25668d5e1abf37b038a716a2735bbfbed06b2b55b514f24dbae2e570b9b6164707fd4307b7730a48d3395f372be552402c7c1afb94516294c7823e4e295cff2f2e866ed -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00302d300d06096086480165030402040500041cd79527d7b3e43885192c0577d81561869ffcca8d1a7ebf268ef448d2efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 8a64b6cc5b6a7947d76c4f7392be0e56cab7831b4a04710a8e42d7b828cd727b63d2832125acd2e21a6df3920ebac81c9bdd472b05157d2a6230d36ffe5c91b3fd3ba0c6423594809012eafbefc88dff52919fbe764177c20dd7e6231c52bffda2c696217aaec70b8284bb15fd8f66ea36fd143c673166bad85e973c4b550441 -S = 9d579f90d7339f303ac17951057363d529d1b448daa7d7025d93b111aeaa5a1087a7063515b01f30d245a6d27dc2074a51f33273405f6db2ffc466d96b822b1224f07aa8075b9abf044ad120eeb39b2e48d5f4c9f7aa1657ccc639873eae8b9218f3e800eb560d5a04e2797fb8ff3f7c320f7122eaf227febf6ae3a8e2042074b7d22222be95ede069af032315fc264ea1a85af5de920f1ee1ee3696850b581f2eb4c342d5df7aff1ad5b8164f9ec08f77e60c0afc256de6ef1a18e1e113a60e7b5ba8a0c665c0cbedb4a56a146a1662c8ec88d5796e9352c36f73a5f5845659a0711c818b0b4f7a20abc52a31474f8a51678aea7a13cd3d361ebdc758fbf90af9764bd757c7505b834105f0ba803f444f4e17310fbd76d4ae2205ab134a6134819ab329e1a58a7382624ddc2bb3f54ef41b6549cfd1158a3c363e4c0a5b3474dc75baeb43baf99df031210be3a9ec4c4e910768715b4763b4f3ccf60af91984e17495f4064cdeb4d7b280c8c5565a6c774960bf2c71a917b955f258eaca5b0bb9f48de529b258828c138d606b4531b7f621b9b9c1753db014e8202e94e8ad10c18925ae170ec08d0a38fd493f022a618bbadffabe015ee21414d893cdf20226330b94970d2d9ce45bf63a664febba1cbc3d6fc20ef8f2283265d1fad429bc4c0c010022113fc81bafe06afbd7b6af26f369fe526936d233f5616dc5ddc7eaa1 -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 9186fc389b58e4aa051fc5a96912c940f4c0159780a5062300fcba1a1fd5d32a2467776a19a79b912c1a826655e780773930040e4fa2d661414b9c0995aca3b58c10dc204a1c254038a6cac1a7cb4cb1b63b617d75d83b1c4a800d8a9426cc788f28334278dc0921f16ca6a2a6e5b456318a33cb3b6ebfbce4421685656bd5d9 -S = 2e7a8b6a247395fc2c4aa4f0fbb4073fc25923bd456da34955a1fbdc66049fa20d093818d0f65611dee0ce14d15cabf313096d629866bc3b12ac8805b9c0487c92cd5500bb5f1258c8769bcb0bb0ac0024d611f317896c472cb9fbe100a40ee6910331e77120bdb6d31603774a49ec63fa0d5a66bcc1d21caacc647e4942efaf53f28bf4c8685b536615ce951ef1f9b790fb1e5e423aa581b54d3ea30b8cebd8bd939f17d0bcf551bf36d3d0080d808291cd60240aa8a6ce963c5688da23fbb992d45a4075feb1263310cea1148ff2ef382b2fc2f96eef811b338be205a0791adb7c07895dec70d75ea4f6a3d94b7a9b072be6b5d72f964e74decce749f3d7ec84e929a1db42e7451e50d50a79631a44ae1dc38eb4e541640b421ac93d33917680888288e063011d80fbce554bec874b0a4d4670210a9fb9f73858e1c0ac7c98d01b1065f2e8dfae52ece1a4d3fdd46d48b1dd0d77bff7fbdf899672c9306cffb4c070f83551002dc564307730448b34258e7ab7a0db18250950752636e34484b7e9063479b2266e639a4a6d3bcb3c9471f1e466c5339e10007751e7392b8591194ab85e00760debf22dcaf83774d1ebf59af46859c264bba1387b6cee391b131b9f633bded7f1dddf7a370742f40a3ed1ef7f5a312e5e26077109ea298c8932d4abd003bc407cab7612db67a94840a381ea7cd084e4d1825eca83ab84ea7043 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 9c8697689a09da7917bd79af7bc026c32837849ff5f03a1ede464513fa45928cad0fcc581e7e73c6eb0b2eb01cef62b8568803d251fdaa038c25e86840a5db799259fe8f0cf645a44eed6a5a0192813f0d7dd3500c30e9bcfefbe7ea3e1d1cbcb52cd6164db77b9aa829d5b613f0aee1b5df9d210cd11fd19b90e9a1dcf57dde -S = 5cccfe2cb4098226ce3988f1fdde318bd67a4488d48c8dd57b678d4808f0627010ccda741f0420ff14324c67489fe4b55356b5fa14219a6484331cb32df6c649e449d077d35276e2508dff31a421357befdcd05049fe9f3a19fc2b65f7b336e89e953414c708533bdd4c256f6541c87be7c32c2d6a34da805c63ba836dc3ae5ff01f4669185cdb2a57054f2d5645b4010075567374fa60d06dcee10595d35c961e350604d7423e5beb754ae5f34d3c144526ae2cb9583eca938da7c7b26765d5d2816a30bc390be5f1325f2eb9a934cbf9311911127b91aae4aa4c418192954bd89ebef8c54d575248e3827a38ef50486d0fc2ce1080c0d8d750c1bb3dacda49cbb95706fd4af5a915418131f429f50b55de551ec23516200bd5cfc31410d74e1ca7bbf79180f3de84ffa56de13e7f6651928065abd8d3bac5d18ae6e3e3801f102ebc7d08c20f9e9f591351e03c9ca3f6d12ef6bbe356916467154c30306e0519b853b4d073f10f0808a7e2dc22e55d4894c100ee5ca7209e4eeab9a346defe83d0ac34699c4776e1c63ad4807746cd1c05f4fd0f32c2183145eee8ad6df8c16aa00c33ccb871cbe373ff04bfb064bfdf30b8b096123e2e137952194765dbde4d12fb846e9baad76f1eb00ac0ec2c44945095eba3aa812a3d33b96d1a966829cf4ba7a98e8c794abeb2152237e8a261f014a19c2b110d1c6444f8fd8d69d733 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 4eab894093e01b38e38a8fc8b4d6ada3bc337ad1b30615035a9fdf24bc6cde30b46d6449afe8eb08b35e4411a1bdf1eab7d7cf0d5813f83b1063e714d376dde5852e84c1c054d2d3d18b31f20382dd76216e8d4a36b8554397f2cbb023106933cad532cf4c8b984143f79e94648c3af002dffdb3d35bf5c2f736d32236a349c2 -S = 96d24cb0170440b5a493d313a500c9d095952899b669494cc182f0616d0da2918f4644961a6480e127459f63551bfff6e72f3ba3cc5bd8f529c8bf9e2bb90c9c12e2e70448e4ee1923ae1e3561fb6b5bbefccdd9634903bea982d9be5521914e8d70a51606cfc1ab9806f68487998ddf94e00af91f64b7dc739a62d98dfca35ddf4ef4f2c318b3b5dbb58d0b892fe0932d48d4d8ce0f88eeffc9dc5b8f4ddd9f493a3b03c62679bf261ba8a3e9c98e478e9cc74296714a0e8d16f0246a1e77c48c6ecc43b4c0aaff9a04e6594ce508d4185ac5e189d2c0a124cde1d65e832981dc49a699f9c6f978f0949078be9fcc545d33568b632bee58999fe83a2670d24c03b8f306385674fe3120be26e12325abb051514c95a60b3369d04ad92b85423d7da9a06bfde71265fcf8c9fed0b320909a1f4c66f4b5b6259a4938983c8f547fdfb630a64779a5c835d82c5435f60ef8887ca47fca7767a27c267c9d1efc09018e86340f4ba3961ddcefdd2bab540fd9c038d16ec723b31da7b54f0138cb54aa979d726c96ed2de5b4cd238cbc54ea0440217c87667eeced158009580a66e7432062c5cc108648cd6e52e2aef481891cf7963efffd5f2c5d9d468ea32748b9295bd6d64ecd8744b4a5d44baa2346b2e23a88639b3e6de22d58b201b896bc58c916d748563d0f68d90819cd749f9218f715a012d0e7388dae82363815e389033e -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041c25980db8b2660bb031224d824ac443d7f673a16ff6f4ca64774cd52c -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = b49b676c4b56eeedca153f915c23079f3e9b87a7d02b4565ec1702e77681edf234e716a3e0ed25527c5d4cbbe66c7a60ac3fd22921ad5b4eb147f97671959c21faa3b74378bcf431fe7626c11def7eadb455033909ac3c1619cb2f852da890c0aed632953a4cc154f768b3eb28347c50fee7011fb0af5085cead8e5cd2413097 -S = 410a01190f07def9bbe6b2834634d4f84c4f626e9e286d504c9393dcc751b76327443ab10e9e9da673e668831c231050b8c37c6fd0a92b814924ee73f0b6a2838c7c6bb39f02918ce05a701f92e38680e8c43c75a57ec2fc818316e0e32b85a5126b2ffaf9340338121379a57ea00b1529ca11cd5b6f444654ebf079bc44e3bb487943580f768b2a2ef9a31b0cca4c0c811124e1492b32f4c2a393bd67335a310ec1cb4cf908613c552a9dc68a99f2e633475e5f24c9140a813ca1539f63c7e241b700f202edbeb1133a043d61e93baef9f3a4c0f8e6cd14f9c2a8aaede1486e0f8da8c19b5a2147357f6059da419078e631e48f6a9cf888d22aaaa22073a896bff816ac5dc940b2383397f76255ae9559ec0812444d47f5b3205595c9db1a74b7dd40c704fdfdbe786713a3b79dc52b0c882bbb8a62aa01d8569966ebc00ea4fe5df212ee4a875afc85f48464cacd874b7a63f705cba529b43a14c483032d616f7b965f9784ec1fda02b05a5d310b11b4df17ec35c828b129218d4158dcc58753f5e208ad8a97e32451da1fd591101ad2f93fcd1e6f5d6fb7b468da1937fab4ccc8e9f3e95a4160b2055e8634bbd0798bf0fdeb658a435a21028fa7cd4be555767573e09d5053941aa0814ab314c45bb94a36997e576a026d017ec7a519237d82297f15c1906fc5866c1a3f6096ddb33576fc68e39c6bcd8f087355a12fd94d -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffff003031300d0609608648016503040201050004203a75e4efbd95ceba73b7671c870d5cd4613bae5fdfabf22e8b5b18fab56f620fefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = b31156951f5d041c1a01991b23102d5bb4acad22c777804d994a6a9fae2ab15915777f0bed6788a928b3ece18f905fac06e1872412aba59598c978d6e8e15fdaf996bd82f6ffa1b5fa58a7b319f819a69f835a7b9c6185efa06f51edc3f43817e8d6d8a3430e996819599038c730a37106fbeecf6d82668438a4bc8b474b8539 -S = 9bd1789015404f8537c89ccb750e04b5fdf82b0daa5d56f40ae64459aa23931ee5d8812cfd01102e3749024a881d3e7a13269b8ce17cbe725cab71c53e218d4b97d4f1274247b112a4376fef4686ff0ddede255e8b085d763eedb7f17eddfded5bbfb0121a3f4b6d47f1bcef7aa871817fcffde3f7ebd75c00c5ab1f6d5b2a6f5a4ecf92a9aecf902711572123eac011bf9a406bf4da6ee6411fef5b82aea8038396052e3801381061e5ac04b8f1d0ddfb678f28920fb5ac471a7046383204d5add6bbe78b9a7c9ab1b3f9b4b5984bfc8a03794075cb101bba0aa2fc170cf6da9401850ddd86357b962582f9bf0e174ed42ce101692008e2ecb51fc1185be19017a43e6bb08e2df7082cc9221895f159eefefaff9d8f3290c9f76934d34882c97989d4afd6a42f3815f7d474a7d020c797c13a9b4786d68ca8a700fe3e0abd1df9563344f0a7bba30d043fc5fc1d3d585f54efaa45cddba963383a0a1f979d48e8ae4fd633ec6698ea4f1e14c6fa2a7f6024524e6db1b0b66160398919c4faccd105d82c54fc98335b531baa9a7c96582ae05be7d93b0fa3e92fcb7a2f30950e3f31fa21270882d7a0e75cafc87fbb387bff937d45be79e95d973684a9f2b486f6649436ceb8deda18aac63c0103c705361ac5b318647aa632d98edf09c3ebba86afcc00f3ebd27505b926a59f67dc8b436d75c5a449e13808aef13e805c35dc -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = bafd723d8ef5602cd03f8cc4f54c398a7a6ff4277a2cc9c77fb2b6bf98a66072ab2205750dfeb2f1504eb6495c2b56fdc1b7c2cf4c5b4824d953c8ac676d6845720d881d7d75f917ee4369711e3b22a3b147f58a23bc70c5a4df586026a853afb4c6e47d05e29c6751288f8263040644f02973a127d8aa74895f4d21fbe08878 -S = 4b5029ded3d15dcb29534fc7f46330bf5fb64ebbb4602874e26364aa52614fd05218973224b1936af01aae5990bccbd92c2a6d20d170acdf782020b2a4ee8ccf5fb9402838cf0017af1bb0e2b5cd69c08b2f4ef222f1340972d21e3218fdde4ba3af10c3baf88883698897c52c7b34d84659468400d4d403355d59f1e21812d8304510dd8bb2963c47d91099dc36d7f0e19f69cba4a83b40f49e332d543c7489c62fb3513dba94e9e98fbcdb2e8d71ff544b774b9303b5e8ab1102e4bb34cd6a4839fc007a5031d87b778e858f20127bb09ce92b96c149915a87a2829532c3608d77425ce38f2697df9fa992baa90900e85bf6eb7100ccb6667e093b376b45230c6ab901de3541fc5dafd0cfd9abaabf7d88908261d36f1146757189f51d167a7294abe9be9a16028718ca3dbbab7e5d43ecb428c2956cf1d44c3e8a875e0b9e3c978fb489988b72f04a9cbd06488162d27498b52298b7efa3aee0937cb0a03740d82d43e9b108b0fd5e80ea34336fc5f711c8d62f74011b893d41742449ba91fce88522cc76208bf901fbcaf84e9662ab9ef109b63d03a45b7e1d4075b2ba5323417f675f61c915dfaed6810f663bffcae467bc6bd7772103a0a1e445f2dab341025ba4c2bfc93ece19c64dde97ab7be7c00f9064bdf2a1fe7c4af045a2362d371dc30e26b8e25bfb258c4b479e5109baa194dfa4382669b0734f1b6ab63c7e -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 65d1c1c5f2aede8f6ef03b53d0ffac64ae6b9666b18a000e4763ec2997cae7e0bacddf3a284f35e270f3132b2d3c005135f2b10213c7221cb83ae6b96dbcbc690c1162be70faae0e2a11da7475f420186da586b07b31fc471490a43da3cd7190c367f359b2f6719a0211393692703441bd4ebd7ad111b316c32dcdc021462edd -S = 7dcd0def685ce0d0dc10cf783ff7e71f69c18d7edf9e32dd583d46201d961cdc1f8381b5dea980ef331ccf27b2db4f7bca619b29c92e04284b14c6c2ed9bb62c323ad22130641834a4fd703dfb714d8d17939b34b9bda15a018b24bb596de618208c65feb7c262b8dbd4f6b10fac674855b5bd1fc15fd1faee28e39bc495867df3847af4c2b8b40bf3e5694c84ec4fca9deec321ae730ef0b10329318e34331e21ae5bc21bffb025821881d54d9a3f7adbb96fab78f1aa6392fa4fd8db78bd3e2bfdef787054c9c85cc2e07fdff85c48341d587b7ff55f9c96e32ef06aef9df62d5f9ab837f3538d822f862120d2e4cf6abb43c620a7cf08a8a72d3d9dc0f7d02d4c6fe620d3d43891696d7ee9731fe448a12070f573043378f3a2acb470fa7eaf01873af3deaa0906f28fbba9fd4b5b05dd806711427a36fbf9d82f627f1620f9d48fc10c2d1f32c88826faa6f49ea6918daab391079c37a76ff76a6a8696567b319c3adbdd0ee5c2dff7ea8411c52f719ece66297797d3ccc99de851f14cd061dfee6288766149dbf4df8ef4554848f22e3d461f3b9eda7d7cfbd2e5b60b434d86507ad1e7718064b030d470307c22ff18439b2ed3e1f757eede270f4ef8b6e75ce824d0e65f02631ec87782e7b4b39bcbb152230c93087676707206fd4966a4d7953931ce284eb7ff9d5b9bb7a86ad7dd561d334b0052a6a23b25ae9a05dd -SaltVal = 00 -Result = P - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 01fdd22335a45577e5cc758f73df444818c364cb28096c6197678e88bd687746566277bdcda9e200ba02b625a95a7d9b1db875bed471efa94d9bf54b88c32fbe0de308d32f8e0cf2926e9421ebf0a662073e17420f6ef2af0af81e0aa36e3a7d2c67cc8fe4bd9bf575f859abc1098544de3c907f5f683f1ad66850eb97cf602c -S = 2369b3beff47a12b51b8ca1d8fca20136ba94bfc7c16ebe84d322bd65d569af515521c1ab131ea2afeb2620c823b1753a28d0207c7b9e97eacb303a62da587a7a0417b75b8979f492dd16d5f8cf9cf181777f25954b91acb34c7e688d60fc78054d496ad8d6082678aeb7ddd87b02c07c3fbc627ff44bd89d7a151a4ef01e0a9066e19a2fb6271f0a47d7409fc08ad9990e5fc9fb297ee72c50a39bb1302273cf7a042a85e44d48548d859790cd126fa64bb72cf40beda6b651c7e957b8cbeaa7248de8fed106ccc3106ecc1fd0f91584dac294e0747032c854e60dcfb6ff82b6f7df1ef478a69978a558df0b1021fab6d84cf9f76ce0b574768ce12f5d3d44cd54f21339f7189532f7e960f3544a53c70a7027b782089904ef763bfd8d538654076c822fc0df2b1f7cfe297c9f260371023011ef3bb191c0772cc0edf5aae1897e2314988b1a10ba503907fc1b49cd675d766c65a12bd60bb7da104d7fdf9f2987dfcefcd9a27caeb56d2a564b64d1e86d95fca84e6413d1fdf716595ce476fb8e3c3e71c3e574c5222e706177da384a3c21c4f1a418a799513ab32a0c315916ddec5fb80139a7fe05624538be2130cc26101604504714ea0258672049f0f432bda7c4fcde9337423203e1d6323c090e11668470bfd4a2f910ac5c2c15739f3433e6d38fa8685d4ecb2f837a9282ad8c110ee083daf05b0ed7ec04f4711cb1d -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = e880d3f9d8365b9f6e1bf535b95344a882d374417ec91227c73821268de36aae096d131fb3be7343b5a9251c9fcb5be15cb67543654fd3f43474e76afce28ee19756a09fc0f3c57b82e48ba0f042b68f1738d863316521591c81778f0a44c90c7983a101669df94ebd1550481580fdba9aa2c22a4ad4a45d65a8fa1d1ed0c539 -S = 486292eec1aff1481ee618d78c8f28d59aba6cccd74d1d0e82502d1b27df2871f55348713ac01f9ea9dd6dbb8150a3df926326dc136957f91dad72104f2327b19d3890155cd5f018464c7c2c4c3509b2f47426b119fb124046180b2ec409c4a59da8098baa59a97a100c7539785d893932b9efaf2fe5197220d1706b96ce89911883cf50d96e1f8290bd320f47ed916f9254b9cd4be55f85dccbcd0c5731b2432810182ddbd37ecbda7229e9e3bf46c7af5878c8ff4c96f55bc0c46b57a88f8d5e756a682bb279b1672d43edb783b8a4eb4c25b42702dae46db934af12b7fd3852a5a2dbd307e4730aa1c993f5054152547a8a76ec07d47e296fd55b6d405481b9283d4fa2d262a38772b10da63286f009208d6a98f4174c2ee64f790dbd47c2508224d0a96d3eace8938d719ea730f026b6e7deb0eddc967a68d78b34eb8fb3138bff69d484203c5b7c00bfa230a01957911f5589226228d16080003fc1f7b6d544e7b2a46f97b70d111ee1d846535a84dfd43c2b42a90bfe373d9319846bc069cfe2ce7a23f41e0934c97b3964c2b892dc2f66231f8b6185ef6570d4ca31841cf9b562daa5914d185aba76ba58d66592f3237954424b103dfa20268f049c9749330084d007f7c2cd5405b1b1da06a75662f4f7c280430dfcb9bc37bdba64200273d13c319ad247ad7e20ae26920767ba43b2b1a02ab22b188fa5a12108d170 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d0609608648016503040201050004205ea6db376f12859c355a917d06abfb3f5f97736f5bbb23f71ec1de277ba047f2 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 1179b364278cc399916b066e7ea2adda5701135fe737fd3cbfa320e3d966e3ad7bbd67cd5e8ec4831040969297d0b9f3572150cb36940c9bfdd9abb60105bef904e4b0b6569004f13f42decfa269c54bdaf9a72be8061d32d091f19840a2deb77397960755bb0a4ce81ae50ee694594aa8311f6746b4b96b0073fb6fdc65c951 -S = 96c8373de5bb82b7da57e144e219250dbba46fccb74e1c325e3bf19c16fd38e2a71e642fcbb6f0fc8ef77739ce1b8aff04a967573b1bc71c894dd5bb29f3de66736608f4f4383c0d5329a2a7fb127a243544acf40d245e2068bb21a8dce0b4d7e81e165086afa43929b44e45f3a5d77d57505a86651da1dd4fbe0fb6f83b37423e670e06c810db19cdfb2d1d36c441903affe00f12078b229cb368ee5e63c451ce391f1eb1161076fcfb9dc2f499de5a6b948dd2b3dad0e6cc1ded8b27129197fa0998d6fcd117c37cd4745d844d6443d0e32a7d6cb34510d1270f31b25f7f2b4f5deb8bb94b7638f058a59eedd80837beac603775c67edf03957a6ffcf7c18c8a376a02bbb9eacc175904c0b5c09d29ecceca5ddb3d8143a6afbd89a1a3b372e2c7eebff1223b1bb4f1a26c4fcb6605f1326c6e4a25c9ca7eea8441b0495f53b7c6015fda720e62e1023fb039f1e3cf1ae9490f46ff75e0b5bfcd354f91e0aca5a4ce22e64876002e304bb7eb1212171225de212e0ac5304907bc803b61066cf68083832033f4902cda8e6ef109c638346f0598fb27f38f2ef130c81f78d5721b89b949d364f0336e3b4b982b7213aa7afc9aa35f5fbad2286f4a4639cd981c7908012b4787ab506d3bb745c9a8232253d59c24bcd60f95ae74debd5967491ad8b5ae564a09a79de6438090bea658b232d0dd620e548e020e9971ed4bcae5aa -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 7a143960d5a8c615dd58a10ba92eb257888befe939812d105f7d36412f291b146c90cc8f9584e5a75d3ccb045b42f805038d9304d5e944dbd4a046a63a53becb6a294b38262cdeec02efccb918742148fe4e385df503885c63b4c10d8400189c5c25dee4f06858ecb5b8cbb2498ed6286117047d0395a29df503cefb75f7d18e -S = 5d5f734d2700f3dcdf27489b57adb3b488de71bad11e6146dada53b80e4b5bcba10695996a7b52f89aab2f3ff43c17355deea644c2ac94fd760dc45aacb4471137a93ae4d9c4fccef44742682f0f985f26da2bc70bbacb95550f99b9003851b7a998bb1535218f7e47d41c52b79736f3005ebe8f46c5d4fcda4c7ae36bf68ac8c527d8589bb841abcb6d0cf12a797622c4275548abfd2c46d35132e5cd631da7f16c05129fbd1647a470f73c7417ac85ff85e71c433c849f5123353e49ce5d6bfbada544e4aee9887262a8c51b5cf6ddcfa15aff2315ad910d74e92245945309f71815dfc23d4b830536f68ad444637a808077650590407e25923247aaf53df43fa90d465ee06d9a9a5a7ae86d8a2180d70430e4916e7005ffb4858712edab095f8a691e2260c3fd56a4311dc25b4ed8c4ea0e43e4bb44ca26ca8ef674019218af0559de44bc0cc5f9463575ec28f3fc9d7a4d0e9b00972044b01187ca06d0dc7f0c5ea336c0e2290e1367d12101f293dab4139124c217cde848e7e4a0f15b3d3805767f88aeec07bda40dd23826afcdca5caebdf54c32021113d711b6bf07300a2ec7dde75d550c93562a30e93810c9ab3ed830a719e02df7dbcd62c4316692b69ae722a01c462e5cbd31ebef67602fdcc9580e6e326d77a4f2a0ad079acf2c2592748f9dd7c7ca7560e4cb3e7b60e9906b8bf02fde02c9c5e0645caed699d1 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d060960864801650304020205000430fd72258dc3162b6f2eb1784384443649d457af90d1c6bd30c443b7e3ce562e7d7e660afd677d87d01695dba2597a886f -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 8b48c7483bab7109f4d05b8cee9338be36640bb068fbffeab94892013ba9f96c5d60c093b144b229f3b6f8bc46d7858ac0f9b197295323fc00f8f582bf0a136f612ae4a020342dd883293258986d1eb07e33a4d42735e7725ca89783026f5d219b8f7a9810e3abbfad114f896dbccbd778fb2e90ea0a11f4d640c22d8b41a127 -S = 5ec4ad5490edb3c268798a03c1fd36d43cd64e6665ede2dc2cd77d833f15edb7b836fb7c31a9a6135b4ea1c84f8ea7513883d8d38037d7f086d50d69fd730fe300b5c0090f4c7cba382fe27f7ecd56a0df98f6b9e656f11169c717fe8636fb2cc6ecbd4a44ea73f91b9189b640bcf51870ff97b23a4dcaac6e4852a8862c73f80f89e25daeeab317dcc570fd7503421989334ed729d453e2b372a58ef37fc773b25d6911aa52a11d516d1011b052c0f9f33306965525c4605884980a2ba24deece8271d65c1623cee181dba8f953a577d989e1d7f6d5393920cfdb9361ec22c10bc85926cd37f3289b1efa6ceeb78e7a1d1b54be2865aeeaa9dddd4aaa2c72353338c247411463af28004fe154b3e41fc88f137c6ab9c240e98f0441237111f9fea9709f41b45cb601d91ee24725a62e0f04a72aaada19b8a25da14b86fa2a5c7f4a359fde437d7a2b9b6553b6dda023e03d3996dffeb8511eb67959c2c647e28f8e9c0c17e412308105a10c0bc4d2820c7d6acd718c1ff38fd1e27db4dc07d2f12f45f2eb8f414861bbace017c6bc4ac46f815269f68212e1c0a3fca93622fda40102194efc58c816146048d49af8717faa6e58251db269f1fd075816da19ff5a5fb0a9ecebacb276b3bca5f6050b33cf50e065320fd703ec4779b3488f1cacdc6a8d469e9f0b5a97f7632efc417bc9efd2ea18d768b27b8863e753588dc3a5 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 9e1d1d96ec18b95c118a04d5d8dc554d705565e87ae1048961110af3ea62912e0cc2612d0150acad9d64fc60dfcf694bc6640f6c65b7bfa13a24f5c5bc130a1c337babf1cca58a7ded33530bc660e25a2989b3439bed9a9babb1b45b82279dfebc4fe32b769ebb94a8fff31eb618284241ce39b3430bfb415bbe2ffd6524b19e -S = 728ea547f16aac9bc1449a5614fc3612292831c3596d2897ee8426c04c353f4fc19590bfd790660833fce2152b026327eebe9c934aa8db566bf63938486bf8699bbb6f2cc7882ed6e9e9cb2d3b0647a5355616604576b12d26123bd60732b2e240e9015a7c4044a0ace6f18d522ba55bc9bed1cf88f94680150d05d6a8bc58e74862f7588993892859f88c92e6516f02d57fb4475a4c4872a211ee03d5152b2111ac0f46e9d826f1dfca27a1ded9888b8a573e6702f116475a93cb2d7e6301ac8742f3dc2c48403e4205082b7e4f8fb21b814c6f94634a50e83e4a3c0900906b162621360d506eea63954581771c72b2abf6bd5bf0505e3a8329ca8e1af6b497ddd7695237fe454b8a06498e4308c0b7f79102ef07977932a57927e2c4dbb3b1199ffeb33e244f536a19375fb5ee25279b425eda4693cef0a4904f8ace80e7a1916740563e4fcc18ec4356dfd8f351fb3969b704233e6c877ce339e7e38e98e0dcfebcb0668dab057171e643b6669dc187f9ea8dda2eaa295b8f88a8ba8f4cfb579d5d33681f0a306f2f20821b67613e18545059b2f6e8049770fe4b280ba849ba38dc6e70949cf6ca160910653a7e3a2c36af5fa1eac778216ee33a60e67dac7ceb7a35cf6bd926e1a16160e303e46afdfa28b018a872f205309035da90752c179f8d4de48f671c08a6a43f7bebd4c49391514783e6989897fabbfdcd87f196 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 45036afedca29e7386c707f029cd67ba4740e7eddd38146d8be5271ef46c895868f19695c1f5a26d8ae339c567e5ab43b0fcc8056050e9922ec53010f9ce10b869860f88d4fdca375ecf3a6e65fc37351cf33aac75f067fb4588cb8ba383e27790e95c3dde5f20ba4ab49255ecb8117ad14dc44ae6c09790175980f7b930077b -S = 634e95db19d75fdb681e468e2e9f991ea38bebcd5e44717148be6c79625136182c8c3b136f09529d3f95e42d4da796a4b9010fdf3d3a483e5c78ccea3ae200a382f1c690a01e2f450dc1128c014f533bae31237d48890a5bcfb3996aecf790d18e6601d9b12022d7f134b1243965727a8ebc1479dfab096298a116440818aaf961ed9aa730e3df72f7d115f57e1294ff53549161b66d6f15f3219323fb067bcc492e9320c7b706613cca0ef030aeae3fe14d04dbc2416ea6d0ef89ac48e0ba83c90e33df7dbe215da1c7c70bfba0cf1ba2ceef1900c76c9216d9c5db17c9d3e2401814609defd932c47b864a65e9c30f75e63f2609ec2416405ef072240092dd23f835fd415d190eefe2afb80f5c02ab433946062d3bcb5c18f009677e43f5e02fcd4a330eaebac40dc788e4fc6890c1c75e22cc2e801153018b316d0bdb0adaf9b2fd98e4ba7b3507ce1f1627c006a49ed81177cbbb5a37cb952ca93655ef2fc4dc34532f9f5ce35906682a295230a0824934dc9ade9ae445d4f5342395badae4371c23635bfc03effc650595381a352cbb8c9c8a353bf795799b3d41520a966f48b7fbb28389f6eeb02c62ae21f7776e8a65b7b0fe6b10f0a498ba9d2ab503cd7e8b79fed5c1a9239766f577266a868db7b74e274b82107cb2b6e8dd04149d556258bfb92b5fa0ae4f05f407191bc28774159066857383d64d5b567e44e706 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003041300d060960864801650304020205000430cb91c002dfd7118dbc156c9b6c6faaebf14d2d79a0d28a084b2fef838a9fbab5fd2e5f9d6ee8b032d4f6588e5219fb02efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 4d72aa3953630bbc1c51a7fb6c7e0375938e8afbeef430c1b0ab56b6e226ed11a989df2cc819aa9665f14e6410f86ac7010fa2e4a18f43df4df22a3956d0e25d4c0e0c757c520482b7b9c1ac55cdfdd67ab19676989f35a435952d71ef4aa679bd67fabc77f45fa99910c77c44e604ca85dc305ada0d4c37f2fa2703b57c818e -S = 13e21486fe238e70f645edfb21dc32ea0f415e5e260483799870d947151362a7249f700818014c1707016d71a83c389ee6f17354e20b55402f4c6036dff827d237fc7b24cfb2b5398fb34beb35d2d61b5c4d089ef832c219162484d453587869f1139d7fd3497ff4189517ecbb2d314c049d4e86dafc418c716c3e4c2803ea03c66b90b93c620aafac05e4252212200dd1448e34914da304148d1466e5e32edaf6743fa43c307f24ec1a0d46b4bb941945a2ed7c02da826476522cf7fe329268774052310d4b817a4058d9ae6084b4f1428ea1fa5a5dc0e666ff9466480b9f1d6142890010fc2ca3ee46db1ab084a524bea1c27b89adc87ceaea0a1d9e8d83358cfc20997b8c94204c80871c0e9da89b224ba42181743b285157d3eae18f19f8a38a102e53d2378aa241b5300a20592bc487651264dcf9084c3b1f0095e848f1af5a940a25ce3d0ae660ebe9ea09858bb366451fe8f4d1dfcf018938db14bc4efb1c4a2a7f5b08facbf81256ffc0453e4ba14744d1611e85cba35baa9302bbe959dfc2c0b96c932063fe40991c2ee47bc1ed97999f8e5f747f8138691db117784a5800ad4d210caebdbc3ba84e8fceee3bf59ff163c7ec9c0eaa468813a1fa8215464f390fc62d45993db71a7e56c4a022fd4ee377a725e87a2415877a6365b086c76bd2702abb265ec3b37b198eb84e9ce6e1037848c10bc132aa2f8e1af165 -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 709abcd4c8297d89f8e4a5446dd32ee612838200c5a990950b091e21029661d997dbcb35f89924ac4db2dcbea345a038281b2bb49e425f5f0af794ffacca303434fc77fd332ca57fd0323a02bc4c963d6878c5d375209c1d6cfc052aaf359704afc66a356028298aea2e6817a22e387b3861f966318c705898e01aabf11fbfd3 -S = 95fbadad59d07287451d54b9645279f6fc62ea2c6dcdea2d49548a992844d46b559be0328662c2be146e3812aa9bfb073ef21f2c73dafdce8297d70a04ab3bae8e0237f6da726621da82066ec76afca2340e3ec256ab5f3e0bb53833c78770ba95e39a7f844e9e483a6cb7f98d496e4eea095f08d809b422dada7dc779303939e5dcc644bbd0b22a339bbee4a9203005aa34a276ca5c1135418c705b8d70284ef279f49421304b28d1ef8606ccb2c9591ef36b418ff3f52933ce1b059d9a3d04e483c2baafb719131f29f1fbfabb85c7bf0b979ae3377a35fb877eab9dcc630759d18b3974a999bfab9704953d661ca6449cacbace130869c2b0751d205c5c6ffbeaf3017e9bce964b2d4b6af2ee8bc9897b6df0d53b061e89918eabc9ed4f46da59748576e816c5bdd0c847a411948d43509e994ba816d6391b041f23c9d70d004e9d3c09fa717c4531af5b8dca8393d28dbfe3b07d6a88da2383181050bb033b8f21546432f62caf52cfb364e87ae5fea1c6e2948e39aeeaba89797163fb2b3bd35d8bb8832218a5d931d351e9cee457504ae70c09b51004c826c913cbf61f570504951e02b1e47e9ab3dc47b44559e77d79b734790a1faedef901d267129139c66c992f039ab42d15635ca1ced47ab12ba87e12fec8bb574c9dcd94e7c6ef54a75fd568755042e8d928f344c65497b3183eda9534db97a90b24927d77e2e3 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 2be1649aab8e12b337a5d974ebe354a0ce3e74f4fc76c45a05edf16090b889e844f60321e86000b6c822d0455bea3812243e72fdd61276b1bb9a781f565db22b488b63a47090187a56e92a2bca36887fc891b6759f1f167d52e467e73fdc8b9cfe478d0c8c44e267a9a1ef107ef2cc4f83e04846a0c42d269375c5a2915d9ca4 -S = 11a6268f9ab602dca7444e9e821e9e9dbf2ff6f875f255d8dc202f953d91d6bd13c74697c70412131091a062f7511b06264d083ed49b24ad429d35e9fb02326fbb2b206dada13f5aab60b5b3db5df6b83e80eb946e199206dc2fc7246ffc6f663217fb5ff2ca14eed28a58ba010b5ce47993b4b66ff00bcd20720a4a6df35a81aba6d277b2ac3fe65dd7089b6fb918831c54165aa833fd84fddc5350bedd1517bbb180dc63016a10668add62ce782292af053a1419970cce6c6740d9654b62d836b7446db56267e08aa204fbc3d3352c196c6b757cb08f137b0653bf362249dc7a7162eb3d82764b51b8f7676401e89c3437ea3fef7b727a096143033d2dff653107e6bf20f9586b2ab75a164d5ab84cd0bc6e04749ad4599c80e4edff189c472b02c91b31955284c42aa5390d83defd8c4c24f14e2aa9668fcfb0b683fd7702da5330e73cba32b77a1c197c4385b5ba5e0ce2e5a3732838fe136020b870c238ddf5900b662dbed59e9664754b63cc4b8fa3766797b2120924d712935f4a591e61d292782bd6029b3eb434e33c06dc53d1152471c000dd8e9eec094ba6b3dd5d5e71e23039480df29c2b00fffb5358bb5628adf89260445ce4ea3cc4a701af52d382ed2e9c1db9837c29e211332f9b6c176630f307c5b0d0e28a1a09fd285ce2c12d1f18269cb1a04e5c1c1740fbe8af04edd32abffd09ca5641806520eab220 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d060960864801650304020305000440a6e9bd72eb12cb01af08cd796b9a5d7f70e34e1c142af67f862971169f7110687017d74eac1c5d45f013743c20ae189d7c9c61802770a915b37a0ffba5ee490d -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = 1dce67cb88490ddb92b9528b478d3cd681c51ddeb0a76f3cd7b40394d7da5b6cf0eb543e854e07cb1ff5f2b3b58e53432bfed58e180b6ebfcc5888ad92975fb032faaab4baea7d8b7efc6e885e21f749471d1bd4fd3a4ce6173d8d874b99d4e2ebe3b254b08635c3b7b80e31c9acef90df0937d8e59cd158bf4959498a4881a9 -S = a73f90dd956d119b2364f15b1772eb3398cc0dfa717bef2d0180ffb42c5a6a9f6240e56297fffc3ec10b8527678e37c126a033cce08451a5052575ad1e471801df563e447e57626a09a5b218aa5d1b3ae3dafa8a43e0f5b187f9d11333cd07a52a9b0844bf61f37f9107fb9770ecc17f1858767475e9e63945bebf12c54a25f9759cfa4b11c605d41cc2b7aadb786a03fc41146ab249d984f6b78c89af37a6d788c67f0575faba520cda93288479f02c83e78122ae5b88ceb6ecdc429f5e8cffc9e1fc78d8c4e638c74fc905a2ecf6fb2e797a1d8b86d458d0d594836f66b801445e743d33a5f936138a1c18dcd08f6a826fdbe71bac84dea0884e5310316d9a28b50d5f40d441d5385db88f4934b4fb85538e9838ae64f9055da047f8d49d432feee879301bed3cb7c2774179fd4f76813284a492d1c89df758ad141eab289c504bddf9934753d94588c2c9fafd69b6b261ce320c103bbba0842e9e2e14fd88d17319f9a7596a55701c22226e255d06f5dbcd432a930758725ae73adce8be417d7a94a712d5c5b3809441557b348720a35da7de59923e59c92df63de405fd913fd7fbf3407c72455d3be934e3d7a878bdaf88498842fe533a03387ac4a6271f0c3621c33424f610eaaaf6878fc99660b2f8833935b6eba90636eeb9b9f52fc0f3244183e59caf31d890b22cca748c80abf9837808b4a1fbb9cd5c9a9b84a2dd -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = f0b048e510fd9d75f3d7bf3f460ece324aaa452f6e2c2d6a23179114ecaf3137b4017ae16523b684b6bd819d45c87c94e59645e33913a67b824a0c63b52b3ba3d18b41606f6ca8489a7ff031e2e73dfcac404cc0cce0ab25565c2a0db04e8d7aec5683ac555fdc894824f64246f2783446af430c501ba62f4756d15907a38d83 -S = 05eb7a32c9cefdabc9208a080b7542bdd0e1e2e4a8529c29a7529527207a0b5105464d0cc445e7e64fe2a9be5cfe6635d4fc1ae7bb7ee36b86fb2ac72ac7d53af6b1dc6df2c85d9aa3513ecbce8ecfb1926332f3119a4bfae1b01b2565376be9872cbc7bbfed88a4d2e67a78587ca53e09863bf21ac1350bb38e009c3c458d2df736b1212e7980d0a3735925cabf39ad4da1b98e9e7a6e4f73aa048d8d686297fc6885e5a939e3195908e17d32f7e78d22e9eaf3e9373ed923f0b2d6b45497351cdbc9fb8ba0aa912223121a24b2b44b291743bc3ece0d3911c4d54ce82f883493805273b0fbcc964ae9529b83e6f22d0aedc8b6f8b2a410abbce970cfa44e30c9b97ffb312d5a53d904d5e99a86745a70c6c9f8f3303c31b39dd587211cc49c973837d89117583ce5be56ce263976d9c19303b7d8971bd1bc0a7bfed7af8ac90329a628a85cee99a3c5e9bddaf857467a8fd3b015345e983946a1a22c4bd2c18e3af937555a08dcdaa055a8fed0e06ebf19f5890ed0dcae6e031e9150810d654925a9347add44fafab80d3bc8342e9f41e60ab742d17d368e02e82d56418c22ef10021431c00af4e21b7436aaca8b67dd7c5b1519ecf0c414491c1bd8a1ab3fcb1bee7d202673c0a080f56ae2966605132998c79ea59bc6aeab631bc0064187f11ef3273d5c6459ba6ebef569b99ac751ec0edc37492c7c563991a0dbeb2710 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = aaf54244327c90f0aec7add583fb42cfae696074fefd5c9a80d9dd1a3b3d33d31eaaeaf137479f6f268313dad0fc7e5858a026ea4b112fee1a4eb5e8ce911881f77397d0e55621d91b046753019436afd98e0455f44fc93126ae106e77df4d811b98716aa573bc367794d2c97d8b12da1b7b233f637ccf6b8c3f15359ff179db -S = 0524037b884cfc8ed0047ca0cce7f7cfda9893c065ea6a1ebf673398e23a56aa4b0a179f1b776a3bb716ea83f0f9f863661aaefe7f50da0d714d9cdea2408a09708d50aa4c6bc6ab31240341098a1d8951c82e4708a5cba44d0d0b98b09dc8f8781ea59d9d6dc168bf80d50e67fb53763aebc6dc12b19ee6ef47b838d58f1bee5f6f3a263a430b22f633195ed0d32a92c08b2a4e75807f1b56edac08a6a87720c611ed497dc184974ad7d3fc17dac4c409a44c3fd29a35259fac0ac2395f81be0fcfedacc8044397f4fbc858640af552b2cab5f85a042d41050470f7fa485ed38a0fee6f9e935611e33b50264ca04f8fc1c6e15d20d10b023ae7768b0b87f99fd298e7663fdaf5dda0f61c019ce0516daa8db07f46dede1ad63f8839e58e3c33e69df238c3481b7ebcbeaf448b986ccfb09b3cb62249ecea2315be42cc6876b7ad17a79a10d8bb4cb83b7e33fd28218b58690daf5de8da3824bae1bc9d84a8c9c09b5f4d67497d2d5b215bd530d41decf24d32d1c73beae4e6edd3d2859f11c7d8ae60673c94f1a233e285aa2bf8be8de7c5791bb6bc624ed74bc1de32796bf656c744dfa9ebc3958b71f2f26a9d28de16927aa2923e6b897c3c3c1f719b3239d1e59a136890b21efe97081cdcdc69a39668791fc4089fccb694a77a88101358ffb961792ca3c41b15bb81e1edd7fe403ebce86ff17c5534d441d946b7763806 -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 1d8188e62be3759b150e29a7b864be80ba2f00e747cf6caf45645f91085cc25d0ae6c4c55c97bd20e4dddda23d8d03af33a13e082e3576602ccb4832d10f7cb30de94cd2ec64e92b8c7f1bdea66491665b313b153a2d6dcfeecac1e5709f113999d8abc4128b58dc232853a3d50fcbc971beea4a4883b1691d6b195b3f295a12ab6bb393c7e3dcfa3bcb6bf7ddc6b22d4550657ed311590330172763930905d38234c89f889d85bce48f451b21945cb980e25d8de6b6fcb2828643f5695105a4fc5705cfa9da5430f6fd98af78b2f2a255eecdc268922a71dfa3fd65c6645c6204fa1afddc7f009e24ff973f70accacd07ce05b1a3e352b4cbceca24c691c94acb40f9ec6f1964a3c73d4b50ad1279598711ffbd1e2ba3e283cb33d0189ed5341b2991aeb6ccf331e23d49f473adf4524a50d876089c824488b1a9d9253d9f3471ab73cceacdc169bff8b6ed6258a940ad03454ee148c86376c6c35971db2a4901980fdc3e78d1149aeccc32424162bc1fdf115e5d2a138b914397d3384bd4921ddbaa251569f71d61aace4b5d947eec59fe57827cdd38c5dd01a0f7beccc0f80662073a52aee4faa558a5c1e9f98327fe91e29340f678c8734e5790994c1ac8d9da22b57cb2bab896d45a2eb0524cc8457275dd61f6c4eec4c2f697a07d33d07a46685c95ec2658259a7bc0dad3d9529ac5485de5cb014e9b7dc7cb6e2bf781 -Msg = aaf63b5ed0e0aeb7ef3da4f134dbc2e8942acc27029e7366e5556f51c9face8b54e98cf37c936326f824e445f464c7f809db80b26c39133766f5285c0433620e0febed963e48561bab4ea06984c094f103415810a0b9439485faf07c42a491ffc24586d07dc52fa1f002fee64ab7d0db69a27dc804e6ad832aaeee37eb130465 -S = 28cf265ebfccf2400d6129058b7168cdd9fd44f44a74630d8df79d306b41a82d9ff0e7e08ba01d31514ddc3ef87dff19321346aab5c67959c551695cfdf04bfbb0ab74affb9edc69b9aa6eebef1d4fb7b1ecf7fa30ad5834136de2510fa774a24799b6f5e6410f4f14354c010f7f9e4976d7772ccfdeab7eeff704e9531ec3db509c1f0913144a444dff8e36f9f50e6c2c7a693c5ed440d95b721664aff953a18f033df5ce2fbc2902d9fe4644f10d50f69abbc7d2f58a80e6b6b4c94d75fa53bdec788315e87c103e81dff4c5cf7c5f1fb14a3019cc89a871328969ba9d12fb14326458ef1df1dce42b02ad17db4bbc75161e66aecbdba7ebbf1709fb208642e3e1a3c12738440502cd235d6a43a08d24f6a397b0a5b86d0a8456e939d4422934917905b3772e2c5736ffc0b3cc8b8bbc1c9629ac37d54def02ec83a106a6537adcb6559ea3cb2024a1007384e604fc64ee9fde2aedd129348c7fc34b240dc841fc45b2fd2c9ec16264b067f139bba8f3c31bcb4291b71e590bc953fd63d1ee44a901d47fcba0d12150ebde6f50209646831e10cf3fa7e129e5504fbcdf4832f5589f191925dd85ea7d11031cfcefa5ed4f9bde552c4270930204d37c37faa8dedcbc2838a36fd425d2bbad87660fbf8df20610e666a9c382b81b27b0cb172a188c46bed70dfca37563129376b2d6e78d4be92b81978031a84eee45f9731a2a -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003051300d0609608648016503040203050004400ab1a89aa9fb0c29b4163f44d7662e24023b152d820dc90168548295c7e1b5836d3de20a9fae39be49bcc40d0c54e271a4f6fbf4050c315553dcb6a3db8b5eabefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -n = a74f2eeb83f4f87768ad1068802b453e7b9808db9d1758ce52ccc70c3cbc4cef2afccf66b1116896fa27acc8cd779b4df59757e24bcc0e69f409b638cba8adbad885f95680dc4a7423d576c448cc38b00ec0292ea3323bd1eabe2bcb6d9e9c94665eda88dae5bcfdac2a3ca71b6d3bfd31cddda0f41f14dc5ddef946a9f779398b05e46678d2e490ac28c8807e9991bdc00ecc28d1b7cf63b6f3f47961080fc45e43729013366c654e1189888cfdb7458fbd56ba3b29756087ad1a0f86bc5e1637f7c6f881343033bec98c22e5c22d91ec2576c66214aa895d08c29707e0c181c666727767f5cb99835eb35a75d44033e5fbf947f7ca249861d5fa5b5d1cd4845d4d241048bfe2b06ffec934665ce371c826a2bb4c2de1dbd115a1e220465c6eb9d26297e2f9187726926e33f6ac7154ed73148aab86813b11b7fc043a969c8b9477aeb6305a73e10cd9db0cd5dd323a9c7ddc08accc214b4a555da9cde05f3a351948e56848d543ea504071f6251e035af576e04e55725516e215ce5b40c13f4029caeee38e4183c834127c857e1a0ce52e2db2faca43542eed0fc2331980be2e70ed938e007d1ef56f103f800dac041bae43d2117fc7030da4f4a87b1161c7cdd46de4098d10167e028fae2eea05da82c687ad82817efa65e973845b5a103424d17234fa78da06984549569443fb9c8755c4627a5b04992e15c0823b45a855 - -p = d86293ff70f21a0aaf50f3e91a38fbd29c3e84a034b5a9d5ead0dfdf0707cd9a85bc5e17c51f149c804f9feb00c2aec790e605b53108cf008e7636ff32e0329af9049e0bc48b91e2712deb4c0b1c2e943da090ea0dfe4e64c79f4242366eb8761a827e64d7fd3ae66b340093a21024418db44dc8305fcb097b942b2f7c790835d27e24a9653eb7af54aa06482f6438d4676965d602f3f1f8939e184f6ac9c9df083fb862d617af4516d824f419e11157b208009cec826538f80331286925a47da40e6317914dcab19706831ec84f58d158d945a354d3d2d1900ba044e25741168d334c5100ad408591212f26481759d46a735fa5f14b650bc5ee0e4f059538cf - -q = c5f08c5456b320360fa4338f92b57a8c6715fb6ddcb07c2d0ff93b6549e7df6e8d3dafc5710f02b42d82f62ff2d365fd7d9b1518eb512f55cf10f347829aa961ba9edb5c5e36c1d899b4fd462e9e89050bf7edcb20c0b54771bf22056a7f2091739878dfc53047ea7cc2af9ced1fccee39b2e9502307f44b1e8f3065aa9d2a45e1b5ee174d067a32fd3573f8d85c17fe3153736e9b2ed6a9fe068530eafdb0c42c7ca5cc9fbf44f84594b324965f537f1862f2ec303b42a838ae892dd1a59b577b7506c663638c837b67d6e6d03066b71967ce938b381f91f50fa526089fd146f62977cc41111597481d9c3af2c099279be8e6cc9fe7c64d394f9298b44a4d9b - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = e5f707f500cc4d0d36ebec7b49ded4c1c1d8fd4186f5a1a5aec2a97e9400652b2aa57ffd90243299e5eeb79d5d3900869300a9d1214b2c606fb05420c81af4e9b3c9d8a5809afcb52189fc903b74ccad7d22a9a431834f9010396db75b58566d276af935f9b7132a92c3a39d0c179f002644e502dd2674fc3c66dc8c7442f37f -S = 84108250f5183b7a1957f5ce9c10b762fa7cf3444f76485c0b5033e1f922d45ca86feb96407efcefabd35bafa24b1f3e5d86ffdced1c3757e23017bc2a816e940391eaec9c2b1e01c1f29119b4064c60a2f5ed91162b308e21f70374815e916f134f7e8907a8fc120dea9cc15c53741ae1d1146942a06d0e1d297ec0fcd1e7024bacf58b0b64ab63f95ee3e3f3893a6a892c8c949ce1ad5664196bc7370411d6c18ac7b3998e5d9d35e6c649f9205f0453ebdbc9eb6da6b4aa549b2af507deb7ac776a89b43b87e01be516e4ba36cecea8fa598321beeb7eff47e7561b52be6ca99fe8114b9be68b0f77c5d8769c35fa04d5c4894d331e7a1d65f25b44ca95e8074931bda83dbb36ee622582112fd918a732afe4040280395fa87dd566e69b3668b295a53aeb3ade6835b32dc8bde3e59f6b6ee36322b39d50c14cc98f7af082468be675b73548f5194dd4c907d99db54f785097cb9ed28c812bee694ec4ee85a8d41501d0a70d82cd8316c2b63d06e2e502be79b5a1f7c06735eb5b850cb0562a117972f171e04870caa751064db6fc4b2d64a2ddbdcf1d17f6952b630b86d6124bf6a7449cc57ed4cafa192756571fcaea3e0a52a92baf4d18f7b61ac404876b1f7e6a53498bb9eccbfe94992a1f326017cdf91039266d9a3deed3dcb124ae6aa96402f80372881a207dd833b4ae38d9d9f5ea2f30a4fa45e566e33e1e1388 -SaltVal = 00 -Result = P - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 5eaae0a318af7626f80e9c31a4e7bc127d24e823c80b1efc0c13cbe7baf78d95130a3d0f47ca2deedab7aecf4c66d602f9d180823ef1932add8f8825a35726a7482e90da96c5821ccd6ed867472f5010581590b578cb6b71a46b60510194630cc3bde1ee4dc9fe1699db21e1db6bb2a6619a22a4bec22c3827525b541dd9cd2c -S = 0d5434fa33a83f13477d6ebecc596e1847218ed9dc99e9d75a175a85d3bebf47ac7fa9b537d48f49cafc12ad3b239a7407f56a27b9dc4ce222ac838a6bdffe594fab2c6d0bc15365a3e90f6765e837ad864105decfa723101affc6c87dbfa0cc0234b9f1fe033d34bd9a5c4fca3a5e228b3ee3c75bbf000a6ab654c2448a43a6b4d2439ee84bd125fb44688a942e847dba0ccf781840a0341516080bf7dc1ed725b566c07e846840d02ab8fca219127ba0f7fec701c79a1a8c7e1a3db32985eac37a2d15b8e22ba159a78bfaab05f00934c95c1aa8d9b350af9ee17de47a69ec25a05572fa57ae33d9ef1d7f1f6d149870c96b2c3f266df32e1e9ff28c718bd03d1b1a7ae7b63fe22a82c2b7879c117c7d16a805efda0925c02aa5759653dc6cae6f1d5ab02d718c78403e40ca30a9f5473777927980d142845178535dcef705d3ffc0f650ce17e8e984da4bf98a78c0436dcb00f96c8aa5f893ce4c2f5088d87d6ce2c90b09a107e3431c0cf855f641d964866b56f409e9bc7bc6147ea3838c1d78c833c973f2f3040872cae6d226aa77e95ac907dd514bfc3534f76621c4b663a0886fcf34e5f741a2dcad200943da40b38da72d6d60eb3ea0489ba6ebc1d0a5b19c966cfa87d72ff8ced17ac770f4ac20c88ccb2e3feae775bcd9747a5c87ac38c7294c7a99c04e1a421b14fbea33dac05f7efa2c0fdf6988cd8f15ac6751 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = f11684d68056464935458c80bb76ecc5ffb35a4c35ef4cc51d7c1c32847fadf60da0512f3106ea46858250c53b0af368ec6ac27695364b51df03234ca3d688beaddd4555c05dd6acdbeccd1fbbe074dea107b4405599355a6b6ac7d1c56401ec593527ed344551a2bfebca3742e0b74ea6f4f9517fff54074a1bd066f2105fa9 -S = 61caa531f63359df1779d5765223207864a01b218fca9a8ca97c125987b1aeca6e0f667276421e708f4f6943df074c48b58384cec8e773e60b4d2c2ecd9db62afd9ddaaba4398d98618ee89c6ea170ff53ad6bc0c08fbb3ec07954fdcf980df778b36c823f42844be7793e78d70248139fd8f6b8cef38d2f5a93e8c5c0b5f5f879f3f929da5b7d9d9727c808ece9290570051238b75dc13decda4e619800acff51f99538f97db8dbeeadf8f54bcc58c06433a3e018dc9bf8ffa876534cd4d2f3b5e88021e8141f0356d01f5198704ac9ebf3d4433f92e12afd6dd6ce5a734800fc874a0f1a4281f7120380db8f27d2cc54fc51291d68c2b031a046426243d2e1c34cae5302685e1eea7aee04d01a1cd4326297fc605af8a6ca1943dc43d9cacf9e713b9cf427628b54ef0da3bb13eb64b9dfdb9e173176c693453ebbcfeeb9b637bc9bfa401fd63f1edcd6fdba3504f73c7f2305683c8a58ab77250813cfe94fda23da973d3db920e3134e94efa3ecb5f43211b3d12c2ac67d7d43fc7237cb629bc8b2bcfe8593945feb32d3a9d2828a2e16efa56111c3d1e6406e8a738313b615a9ee30edb4d03028b7ea0545efaaddcb2a941129530f67e1d9d870a529c6c649ba7db4bf2878e268f7794943a19a0b9d230250491a870cdcecf971bd7e66bbab6a6e9ffaf5f8b727f00532a609975c78820b48b0af715ecaf6867bebfbd708 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443021300906052b0e03021a05000414f3c22813bf0da5f5ce5244a03ccc74c41a51caea -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 6b7c63bb3b14afdc085c08805123108fef29976a4c856c74d34473d1a553f86d8e9f4340377a6dd19d4172f9c13b86eaa2c5ad6f68ac8676e2db67cb3236af26c7c558688c15cc225fdbfa57c5dba883dc080bdb91ed95d7124b0eee8704e6a0fd37cabaa2ad75d63874c921c4c91e61863cda362e0e419f4dde8fc10a8444e4 -S = 2980e019c0c7e460c720ca8e45e8742a14a5c712db17cf51e8a5fc7ccd6b2878c4c609b1ccc6258493a965a444bcddb6a21dc129119f4425d1a707555a6b50bdbbe0cdbdf0abcdfaf8cff67c2056e2e9df573f425dd0f56fb1ce3e8171e12ef6e9b0062d5b393fd61b723801a9f57bd8dcdf01d0965641607e3c952715a729e71622a3695e16e92b7f8028c3ac25edaf3ebc34bde80113fa8d4d4f7a56b6aa0100cfea550a220a22ed7b24d35f2e89ab0709ab7e3478fc1a61f94b6726d5c3120e2de4cd8ea7f5c5651f425d4435c1de0696babe95094397324711e4e7892e287fe8131f976f263c0ef209bd78a248b1c72813c963ebfd52162ea9a6065aa32b0a97bb33eb39e3bcca888e6f92afb8f3891317bba4fbaaa27f638bd7900801683ab6a4f66d0101246c1aede70ddd6367d255f21e86ee48734df39549501ecd4367f6b59e386a9a42874cf0db6af11c998d29a62392d1bcc40f2feaaff847aee8bce8a93af3f1c0280966f9836af3098c10260dc6db8372939d020e863919e228f0df85ac23f67a5cd84e7a564bfae74a307140e636f10681514383d0b270d03cdd969b5e2eb5fec36af874b1d7f387b7ba69daba036527474fcc803f823cb17734e8faa073cf470ce65e480bb137332422a55d3bbc72a148758ee0a222f8febe8f8d99c1051df894132dea5b0387b5753719253ff3dcf94b006f2c83e06b4fa3 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 3be0bbfc2f5d6da14c29e7dddaf4630f902fe246117bce54b661dd248e43384da392dde67f42419def7b3a0307921d2a66372372bcf012a089c61930273dfbed0a8a70be4701c8c353cdd1a00de3fb19ff39bae0e1322caa5f5dfc881d608675f72f3b2b8d82473cff85725df5d14405e39b6d378b2b649bc3904dd47893200e -S = 632af5e0d55d9eb7d4230c6818d1a178df225d91919423df4168a3e1fe2142f1f26f00c5666dfe6817b2a27f3c2fe6546ca747d74467f85ac0b73b8e34639e8448e0a560b1bc3ec827819db0df2d22874106205f93dd0d903926ec0478a5361e7a9878c6974a8c095d1b5779d783823d4355ebe24762045229ea839d05a177ffabd39738488ff449111238397da1266eb97ce6e3c63c7cb9ab2950140ac4a94dd148520dd67527c48d086e20bb6e18a26fba04a81008e35e0cf04388eb4ae9a1193d4806bd2b771117dd2ee2f349b01805dc056e5f0f3ca4df9c15562d6e1c9fb611059136fa581125c383f6cdf2ca7f7bdfa6cc8d7a2aeb1e2ef7799941f2c6c8a34021be8c771ce3e37aaf31157f91c37ea9ee02e6ecd3001ec30bcd6a45258ec7761d967798402ad5976f22542e5604d58627fafba14bc5bf3145861eed0165484286a2bfa0e17a37710b3a17bf9090f3493c81ccac46078084dd2eb43456cbeac804224083b5a9bbac414a57332086b8e8b0881707d41d4089066e36469b0085da76c6fc16d2486b3f7fe31964f928d3d902c3d5598df2f72d1a2d5436779985bc9e7264d07448f792a7f394aa36c9534be9ca7f431e90729481d0397ad8e4db9f4a429f238f7e1cea5c03795d82beea3ccdec38ee4b727272a9eb520e943ef2a1ffb10cb9e8147e1ea0b1d3208810b891b37f9ed8722a93328468b9fbcd -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003021300906052b0e03021a05000414a42c6b6337793e971d69173bb994a17471dc3642efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA1 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 25627026d11f380f939eac2156adb1bdc2e9c087bb318c782b5ae52f0224dc887b6d2870a0a5c8f81082eaa800f50c15805c61b5fff976f312a3157f71bb6ae84262646c9be95e0f4289ffeab7555ec6746c6ae973738a30f143805e72de93b405a8edc2c9d4427cb01cb29083b5f1f72682a5ca1e880f5850a2ee750b75a015 -S = 3c76bc9dfff017dbc6ce8cddfb1066ab8e669761c9a3ba229229eda74f05d7790c0993883aab90d16c2fc358a7117f8118c9147c69810f2fe1d7cd4220c5df5bc67ce3d2abbff139083bb6d6c48f6122f71b30f20e37e39f760f9c3b317bb26d6a14fd864d97d13c9a1dd7480c03727a6b6fb2b1b74340678a68c0efbcd36a39d42bc8dff44eb78d1ab4131b80eb4cbcbb6687f0cda506320882dcd70c1839c653a026179a0615175660fe557f45867fe6d883cb808db01ab41efcc0cd2137355fd2ebed412516c8003213a523068e47ed03e58f529af079a5f86bada203793808d0454e8170c666b2638c248df1e6b9a0cad05a94f9710d7912d833e3a474a58b450e10a22188444b18dce363b1bb3cfba548206fe448e84a608694f060e71bc17e50c1c777b6fe8f0d2f480f154b90ac5c6ec274a62d23d72a263cf0fe797c5a1b226d612c2007b502b42c9cebe5fe27b5e2b731852ab7db8eaa8fdc005072c96ed55284cc59985aad5528100062ee96c482e9539cc0b5a5e30954ab4a386beef0dae13c681ad8729a4b3dad39739892f2789f18c5b517ec2ccdb2b9d539ee51546783e633efe4d22363858090a0f501ce4acb8231e2515bb06f02ff6b42ffc62b30056f71ef4ab1952b614c32711bf8211f99a97bd3d3c5780142f3730e7763a476584efe9d8bb8839d27c405f52306f3d4db3168a094316c699e9190479e -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = d40724deeeb76472778ad98431d2e2061239d0178df747d81349e77cda1e2c9fdd1393d924a1ff9245955a182bc17fee16f25868e32243748eeebbbbf54a34e9de7346483c250e94ae0fd20b4984e3c39773c840df999846a7f5a8ec787c66f2e10f8554beaa5b1fbbde87841381d62b9ea468ca0ac50ef56846f738eb1e8c63 -S = 258f159cb8bb860c3c3db9d6b59a44600190f0076d1f2ac163b52081e01fe2e7423861ed9bb5df8b40d4d1354dd74219c71247bbdec4be0e90910f827da0565b6d13c5f60db49e0932220c1861dfb3f0b13a5fa74477aa329ab24913ca918ba7cd4e72fa532e044910f6a72cb525853f926b752adc76d39bbb9a265206c9820c3e331670103fb82a9a0071dcc48ccc1a650ea1c95341a48476af0a9b0e4286d96f0a976d3884ba97e5aa78909748947996f233ba02d6586a375dbaa81f3f00f880352f7e1842dad59733a40bd0c9393276c47b8baa99e8404b1f539d09cd6958007b297ac8c82f66fe2768fcf572766522a104d2de11435a19d2d1ad77221ed22d045a227f437752f3029f6cc55a99511f1febecbd45d529e216803b335cc206810d19804874760f66872c8575022f7eabfe437924b931d18e8156f33e6eac5d5f1540476359c130781a436b17f3bc23eac0f9fdc06e9123109bfba7d9a7eccbafe6ffa87f6c872d952e7fb3f6f2f73455d0f4f7fc63a744e7713219425e746d7d2f9564c4cd1a6301cdd78b0945debc122d85adb52b3cce920b22e77f0c835a87da3a2c9ec3c0938551f76f229b7c734242c6b78eb7ede1424368834e94d9f7df0070dd4d5c7503b5b023508483c4977b0a69e4183e83b88fcd924df78387b916ba475d9cc922deabef2dd07a3920870ef1a8105d6a6aaafb3210a7b1848b81 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff44302d300d06096086480165030402040500041c560c52ba7c3dc1e996063b94d4238054241198d156f307d890406f06 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 662e6fd267dd8f2e5f0fe89034e4b0a6e8241a256dc8cd6bbbbd966421e459aad85d4ef0de0569a0013d1ac33aee37223dca37aa4ed4a0155622c2c736e1a6f65b9b420e93b5ee541f3c1cc909e14351b8411c14c16a1125009bf362e84ceb9b176eb3f62df40591df92546a47c5bb7c7e13332b6d9408e2e0b18efbdc2c10df -S = 76070d1cc628d84353c5535dfd3dc19573a91911217d3f9382de19b3d51f3f5607c7f88d82bdca4871b5361f39b8316b45a9bdb3775a69714bdaaded31dedd9716a8ae202c0237732b935c469ba22adb7dd67f67f5717787a6bc33e303af0f341cf202f8696c72f54772bd619c7929afb2785912701e91d96f9005942e6d11fbd757239a5cafbc93ca098c5632424f7b930e69457cc8810cc9ac3b5a1d1e17009ee45887a632cab31c9d9dab6e843481a09e5a7ca77be9d3d5b0d668689bdb82e4e2e43310fbddd5774d482b43cfc1499196ca521fc58bed44971eb15d216ee55b125ea8f65439425dfe1007d0be5418113484e1ee9b1fe3ab25625ac624eecbd03ff9e1b7dc66503afb625ff659917635098442af02696feb0b2d9559c19505cfde72470d34dd1719655874c8d4c23a94d5f91da9aedfc38e96e271ecbeaf924d7a9313cdcf6f485cfb1f3107c3ce8e0fa06a326ed75732738d52a094e9babf6e14f3f67ed48a09797020c9ad48a31aebcf4fe0e0b4d1c128a0f90f2bfdd520c566559747802367e95d45cc8202a479fead34c90c4663f313f3db337cc244a85eb595a904ac9c8c213fa6e762a251a4b84e733b7990aaa92a358ef369732f2224b5d37692f48f8cf6589034755347eff0c34725236d3d55ec27ae919e6d255025e4d2636b6c07807c66751942d9362143de6133a90f3d3503d9b50f91d549a7 -SaltVal = 00 -EM with hash moved = 0001ffffffffff00302d300d06096086480165030402040500041c58df3479e243f7dbe552ec444cc92a91f478808b02c5c6b5c28d44d0efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = c65baead3c9c432956e7da3ecd9f9b81b220c054b3f6f9b79a4e0f6116a9c810bed80c1d5324455345cd0c0179b6014e4a5efacdce1261515a61d70348d11db1f7d0356914edc4471848bb8b124736eea78ba5375723290902ff41ffaaa7a5fb7a2d72ba075f88acd742300320bc030ad19107b9d6911a86980f947dc4942893 -S = 6676debdc5c1d257b6bf532f1f61981e769e3bf0676b5050a8dbc65ed78ed3b88c687d0213ab1c0ad73b8606e2e2e9ffe7ee8f9b20a532a3fd59945b9f371d13807e36da1aed420d4390c26980cf70465e3dedc22368b09117e4606257677132a7c92e73c0633718290535915c512d629bd3db35306f264c5681e4b48e3f5e63f46289e41d74ab29a099c637132d2b8a04bf7649e4fbb0a6b3f37873d2c001d7833c9bb1f4de8043858223dd005ef43c6ea6e0806d2958ead96fa89af9119b2ac16b6302e9f23c5a2d79a2d6c4bf5b576ab07de117857ad4766606e52de3b1cfd368746425c74154cd814e63ee05d419c9f05038683970019b24961de26f0312203358cf5a69fc3a8c34376774d93a07e8ee8cb4e49d3c8061cd988ea9a96973b07dc8a8b96db165a0f287df5a538304a9b05e2ee294c155e17bef1df251297213904b56fbd3770d6587e0f610b291d0be288bd744315aebacdd71d00316f9d169d542108747a10aa65c36398eee21d7c580d088871e9c7be4b590f78b8f315f92e6970ba9fb9f929af324d02a281972cf2841155de6a76b54c1316c818f9c21c52eb8ad063b53aab1b22e72054ecfcd833efbd3d0da69c3730e81d48f54cd9c22da891fc589b3b61b5a226bf54d401e576f2ce86c9b651cba2d93d63e2e3181a97baa20a15f6e584dc30e1dfcf1a3d2b69803eb84d3ed4f1e153b76f14def51 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 953446b04306756e65d0cd8bdc3960a0713b59fdc73c90ea8d7b5b33f8aea6e371ea464f8bc28a5637b313e83bc0e6c5e059c087eb81aae3cf30cc2c21f686184ce2bdc786a2730103eb9bc0681c2bee821e726f388eac62be1ed4a40c38b9968fe554211eee59f72f410c1b4b9556a3bf5118bd95aabff0c20c19a4a1bc67e5 -S = 179296ecacedd93047d4442e8dd5a0de7e2799f45ceaf381cde74f3dfb96d5afaac92bae3df1a572c24757eb2cf91b970cd038278623d6cda864d2db12a763b94198dcb47e6041100ad6308403ad35859d19ff3608dd6dda433c4a30f53dae2d615e612cdb0c0fd4543243b02e873a3ad6a7315b0144a9c1ecd18c446781d7a8cfea621f646a219d6d108b5679520158c3d51287425cc920e65c94eeb01f9b92bb16d167e60906e30e9d2dc8a3fb8d509bfc406994e3d0a39e27d13b3ed5015c61c624e1f3425793c6b0a96a4982997715163ea2ffbcf38680edc6f03a9981d0283053bb3b84061e5c5ec886ff6cbed8041980a49af1ab383f349ea01be6bb0fac45be52a853770e9b0e8f1ddf69a18edbd858eed11c0c8739379de177074aab7c9e20d1783ee7dc46c186eb3966abd35ab08df3574db45b674858b3baddac03fa27d818eac14d3edf5f53852a6e42b052aca9b1ec392d70d53ed10af5b8b5e0df1a6318c558ca47740dee0e5293319a398f01e92743a425a8d4940b65bd16ad266c0db2eb5d53dc3532c98edbad8faf955d65811003a2d887374218bc4504b82b710dc828d838638ff3e8a25cc898c8d210626388132b9e023900d4867350c72ae8c3bd6f0c4d2732294403c1b6b2ef03670e44b2e33e05c5a00299e070a237186b85271a196908609a996cb386d20e285ed3446bd0f03a184aa47998625cc5 -SaltVal = 00 -Result = P - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 4a51133aae088367ed396b7e7c5115f017ee32fc10e9cbd2e8947af91c40d9ee41033b0e53b89ab54b46d1a8ef260bb0ee1f7c882c544ff95b81df44cb8229c0831582c490e085c79db650c6c416f0e7a4f4195bb4bc1a88d695116830e35b2c370f4f260c8a2ce50c0f4fa2a329aadb60f6713d4f2a16c78356782df26b587a -S = 0eb8a7a48915663d4feb5c00c37b1862c248e9305c2644f40b32654b1899e0469554dee6495c6142588d25c7b04d9e498422902307bb8a861ffe02bd3e15eb521241f69afc928325c85508e698dfb5f2ecbdb555829a6c0a1ed7f97a711ade294107101bcae30d469734e7344ab29b03d7bcfb364d219d3d984c1f5915bee9fb6e2255cdcb0e8500bf69d9c8751dacad6e966438eddbe6325141fbdddb4d9c45554e467df872a0dcf5fe9e12b7bf610117bd0662cf2d97c33988c2244283dbd3cf8657c69a94bc48ccb22fff87308eebf175874dca3d5baad98adcfcad551b8f397f76a96f02f398f7e1a5c5d49ad6490d2476b03eca81e806089b5f88c368cc63421f20f54e6b3eff6c020fb3f7a6df34c2592dfa3f45327541ebfdc7f6f37e6ae0609fdd6aae6add86b9a793023bcb0bdcdb051e17ff51ccfde476a87c04a5b2f5ce11e014360dd9547996dffa7c075f7eb4d2d779443ba313af95670a33ecf0db05c7fea3760e53d08707441d7ce6f068d45c746d047ce7fca96106b100d704363bcf82e0b384f789284b8e472581a52004a7632fb6c8d4bce4e325a321d0ed7873aa62b9098c73ba4cd185a5ad2e99850c57167dc75561d630fa9e9b2094c2f327f6f3d097121be3d1444d941002861feddc38ddde941a223d9f525bf5acfe4e5ca39bf39e5f37b5db29bae077d451198f1e0d99fc93185c2810f602cd1d -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA224 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = d9b8ac36d3fe6d7e9c008affd1752d4b928c1f1787dae8da249738972b0b85f67243f69ae60880afd0124fc2577867d6466b8bb410245d82121bc897177a9b8e21d17699670bea189aa1dc6b6c0d2a04538292c08adacf775ad004d2976f5e5c6dcaf5dc5deef4e38215faa1191cc0fc4037fbe4fee484e0841db6edb2d21789 -S = 14ba242af3387b7b0489a0012f787986254b084dfb24cd31d7aa143756886345462f6d98ee33e8477cf0606c60c99b585b52dd301975f7400e73d5cbdf7d91ddc5b7262b615d39f2d0ae48bd5695a61630b082ec78cde6d91dc4b3fd518c413bea61a966b1d5b316cd3878a91d80a64d52f5ef24da2378c43e528b4b912d823bce8987a9b908ac884fba7a03a2129996a60859761d8498e5b9e0c9afd9aaa901c8abfcd80a940ddd9731351deb918cc6177ce0c12cbb27695487e9de6fa23203dad7137e9eadc5259a3c850530c2283e1178c0b2395eedf183c3cf78ea4f3c20b3e80017f669ffc97649f439bd6476ab484b04e0de8e96b596b1994b6a99d732e54886daf9ec82d22e2bccab9ca64db92e1299302eeb031c667aebb0509f6a39e22f2bae56e7cbc06c9a1ab76c16ce0fe5ad92155b330f31830a1df7af51f1178e8aece7bf595152b2530199193eae8c4586af91eb1f713c45b08a87b75d825dee919881ccd9a6448dd2bd0767fadb16415c305825d7db8e01d89ca97821f0293acfb1e85b08d83349f37e99131d3766636d6c7f61afc77c059035cc090e95e987687f3d764264d2c82c1ae4c4766365977365f30b26ba23755dcb6b1545433284a4129dc39625156057f23c44103ba0f02706b16f630ccea0fe204d43d9ef162f0bf17fbf83a10816b66365cfd5b9c4aaa08ec8e1260540e9fdc19fcfd2dd91 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 9b1f5c7d045d72035019a18dac59247ac99cd251dfc74557f2623b6054043ce56b0c7e57b49205b3089e0e571e97ae1452feb784a45cdb9d04781487cdce43ab8f3d170d110030db96df844660a6029073d776669b9cad71b0ffd928195d36e88f18ee46238d3ba48346cb0279706817b48fd8a0cb7002f97f5f53ea419b60c3 -S = 3a9992cd8247ecf8ee650608b4520bbab5fa1774b8381c702930216b0dc6b9040b0dcae567c552ff5870a438d478c805edb56f396e9dfa422464b9559091aa231cc83ba676029936c204e58e473d93a8bb598135463614df6a54dc050f8db86bcfbc942979c3f011b8db0cea0b6bb0695ea1fb8c2f5872e4d89d9ae066b62b062156bba2ccf2be26ee1dce469219f387ec865f16d5b6babde6d0eca2efe1c9a51ec9f1f44a3cefe4eb054d33b80cf945c8bf530b9f8f924952d02fa75c410f3a57dbc2307f03a2cb9455f8a02e1b36b75f0f64087dcae1e639cd360da5d6a7394dcb7c1baeb4b323783cd3fbd207d8faaa5cc3b93867be4d47d934260129f0e51fd1dfb78b3c7c59f02b71be439722ed22654db5c1dc24b83785490ced8d0b97e11f85ee42f95582802446a38d812d59efbc6012a5dadf162aa0979a5de4fb7e4a19b4531c1b11231cb509f3dc05c74d90a1e2a8d9e6168da9fd226d5e53e0cd5ef93fc7ed638287207932f2b1451bab5c4bcabedf244585fa27e1a526cd9c7535768078c2b447cb30b6687d373295d6983ffa31083fd5230eb3574c4b65cb4bce0059d8e77e240d6be41f63fe98e94e76ea9969d8874f92c971a98d184ad6f78c33d5a1051a33b99c2d481ca3c06372f639d78e9601c20f93368ce8a1830d0c5b67aced9f2af6d3e8770321b209e271645e6909e251d31be1156d99f1204ab3 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 82f869cafa1e8bec3d9891bf59cf8f15a0581b41f223afe13ff64efb471a6a4ca45506dc0b1818d6cff83197a6625f05b08b5322b5a7bfe1af5b02388874077624d96ad7a2bedd55df1bcbc23c5d3b14a25bf600c38beccaa276d45b55691394096edfe2487aa41277e8a667a326e9ea7daf4e02a239fe44202f0b8c3661554d -S = 94d64e8a8f8ff9fb1fc76207b8be1a45f76f09bd0287baec04cc53e08639542dbaeeeaff537b0de30d63ffd961080d3b94708d60b364990c6db0c8ad673e6670f2c476ad7d7a957bf3c46e09fcca93812daf509ed7b88b182ce6f8315ec4787da0b4a0a09f6f48f2cd4a2cb3257abbb1b5c921a0db8c9de8bc64b98f4c347e27d5d063e232e4cfbaae6cb78effedf18ee5f7af1765cb95a3a8db21cf94166de19a0180f7c152f6b25ea2a68703d5d4443c27523baaa08cbedd2e489b0235f2203165f13169e7df9d930fbd7556fd594571a38f4eeb5b428694ac5b9858d233cc2bfe0d21e2fd6f599479024369b7f102b1624ba4160c48028017aae2fa815f7fa439b1545dec9b9e372f7cd8323c8bbf7e182b064deef2b65731d18d2241899f4f573fd9421a4b9a809e9876188db404cb262485761fd9bb315fd69db37601da5805e8e3fa7a64f654a11259c0764b28e53bffcf03d71683ece0fb9571aac451c085c1190353ed1c7a07bc03bd4abd0ce68c6a848a17720dcbb03231e1f505f1a6275d422dd89de55c0d70ada23f5240626c42e64bf33b668c69b6aad7b16534bb10d1aef16ee155df6b0ed2d3768e48171c62838a84c982713aaa5e982370fe10625687a5a960bfb205f85531dc093ba443abf4d22abf519b7db2afc36bae0c10283a551e5aa41c942c9a28fe199522da96b4bc2d640453c6bb495c258578fe -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443031300d060960864801650304020105000420b2b9f428aca658a676034a1382b07d422f560f637c9fd49e258e742e065a852c -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = ee7d5046460f07173172b1dfc3382667b6080522b99da7580a115183475caefa82187ccc938785efb2d6d19a45a31aeff6be80dd092c7e45ec721d5b10106750f84b1f2e902faf03bfd562413fe2d365ad50a6d7dc7175116f300d04a79bdbb7799ea132e4116d9a81f6cc9d5cfb3b110247ded7db727506bad58b45b305f079 -S = 0642e1315d86676ff3f00490d4a2b8285333c7f7a14a152543d85a9f15fb2d54d60519d1896697b1ca9469c382469725455a7124191bc438b3566ed434bf318097e396c049aba9fc85a293ed4187d16bffeef55229cb52b950b504621cf13d683ccd6a0fb53e00d358551a8989c7afc09e34ec90f8286e7413de3decad04496b5a749a081c0e82ff71f6838780808270d72265e9abcf87f0e1f4439f0f7b3ab95729d4041a502573f94aa8fb1989dde4c2287335818f0fd03a72b4e6811249f665b0d05acff32069d80f570782f568bc851c434d82cc94fa168b6f2619a57a97284789bc41d9bbb29749bbbc3470c774079af80eba8287a2d53f4e14df1e619cc8b5e7709d5c54cd4b0cdcc8693c3d04b460c382531e749638736226a9ac2605f82eca3e3df3dae4f2e7cc70e0d39fd2772f193a4df10a25b58bfbc5497a0ee98e8f60cccedb1152741e52e53bbf3ec1a23bfa44b73753c60d69c1615c58739f2f093fbfd6c9ab25799cdd9e8b65bcac94af0ebab3f66780c3fdb486cb20427db12a97fd0257f1b7c956733304c4d30e3faa78c27bba260d697be1ef36eaae6c87d49f36112d7964ed7683fa47597fe58b212f19f4cc1d88805cad324fdf4ee05687421e827266d452a851401cc02c4af7a61fb1bd40f772bc1cca4e5955710f2e9ea23bec04ed7e3054fe8f1170c70935ee22384a43e82e1e855be59d428f8f -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 27331a2203df81efd7f4d19278bcbd4050c32f8fb6df3a93786e5147b6dfb62ff774343c764511f0bd893fc27511d2c47d15b7833933a22f2db548fcca13cfc787b882fd3409cab98ba4592c09e5a942fcafa582dc69a637de46a0cdc7ca9e7dfe8a6b2de63392916acd8997da412a02f519625447882df2b5aac283560c0a99 -S = 4bd55acc43b26d2e69cdee990682e40580642fcaa9c0057c2f3c6e3cff14234f8e7304ef16cd79ef50c6e52ea8b02a46915ec21371556d217da4f3820eff0dfbc1a3dfe8bb43756e2e829d4bb240742e604e1d6b1e3dcaf69f346839e0351cad7b10c165f34603864c47e6a01420e677a421352f4a20a18814b1fc0db029825ba182732ae1480cb1e18fd1ecfc6d0fb6b6bb32944580aad72dc7e9f0f9dd41c114f8a5e77a1a07da0b51ea830a5877ba964460d45ac122829976d459dd7e49b74130c201d413ac78525f75463f69bd2c9da63c848be84a240368b7dc004e4c26273e5ee4a0bbe2903bb59cc2200fafd222fa59a5cbce12ce1a375ad512284043aa4d44abf3846d9d21b3a27c28b03d5cac655f91fd17a9d0a15f450db44a09aee6deb337ff3837bd85045c2f716ea147f098ec2560655492427291a1619404c77985c860643e85e01a767a8367ea387f930686becd9cf51e6da3a5183ac306d30b42d7b41646355f77192939af92a248d9243144d6ed0c440c60e656d535d5e656d8d22df272daeb01336ed4f57f5dee8f8514d7a100e996ce32d06c1bdcfa8d490a53d0f4329052491e5f3173f0430f07f18869f866f8403a389b2be6b68efb44dcad6537a2e305500acda845b5f50e91433ad84a094c12c0a38682bdc3a54fd3f6b322cc72fbd2ec805748f7e82ee3e5fc4603140e3b0813cf81e1861fb2e4 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = c8ef4787dbd28656118a8cf26f182c77f48ffab67b6b522be3239c306c02cf6f6432349d041a6d6695eab5a3d67369d3a23dc8c9ced3f7a2516247faa782bb607754c50673cd51bd7f5104211684c611ea5d7e63cb7c1cd5cabddd469e0dca26477c832bf1943a451ae902d5f7f24a1a1417a4eb3c0bccac985ce57b1a4905aa -S = 578c8c3166a0199da16eb3f93eebe5d2bfc3ee668432bcd26d8c87ab349137f5392f60b66578eaaf47c3fc7ed0101ee650b51fd522f8d06474345eaa73e253f8b1c133a9a874c6234381ba4b8dc0494d1ff5d65167b0c46adb12538cfbc75ce1042e4d69cfaa4ef5083c08f91f03b295e0433597e0aea94dc596fd015b4770db71592b9f41e3b587313148a4a2784f1bde2755034bd99b15ae982e0e4ad4c9dc8f8d8ab06d692251520c813b540f5b514f88827ab94b879cf61bfbadff5277239079b90d023826f2a8f330c37bb3279d0ebf0659196cedbd91a347e8e0235a009d7f39fdad4faaffca75f6343fea2ec8c588776b64ec1371c90046ba5b6bb148a75c7748e11649442a77ed80e76a23b1c761b9e3636e3147ac6fe408fede1f4c7c7b8ca651abbbbd20d131218e2e43bcd2252b1b180678d9196c6067a0473c8c73f0610973807746b44c2bde619a5e4f4cb3371e260c47eaf31e935c025b523c39b659098369fff0215e17edda2985247c90b3d84676110e1344d538aa34dced5f97c71921406adca7bc1ec54ca66c43b7321497a71310f70184aa3691451f5207f455ad947e33c9f22f7a96fdc970c325a286848413fb092271a295bc0de317c0b76a2617fb0fdf2c792bcce16b9c3f5c4f03dddd7ca4b1adaa6f4dee058b1b3a2326086e5140ad8618c0c7517b148f1054b897548f881961d54bcea391f7a8 -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003031300d06096086480165030402010500042077cab6a7538318a9ab5fb2c9399130c8fdd3064629374b4a49b2b88bee0e6463efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA256 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 5d5e9a1c2ab1b7c859c7cdbb21caf3fe77ace0bfdfb05af6832df249828fef2c8a9e884ca903562e60070813fa9f59201ba63fbb9c6965389668dcb5bd5b0e42f074f3460ee4871e0aa07b0642652a3d0cf9d06492b5f627e14031203c9d0cf8b66843d0005c32df7f198c5ca124509e7230f9826a9cf60d893c5952a75cd396 -S = 5b460ece8562655899aa4ffa98650e7043766b0b2735662ceaf6958df776efbb60c92330790a57cc26093db03f6dd9a02f0046de5f71397d496ffe41d70f4a0b2e98c0c080dbb546726cc4808e70cdb31d84c23c021c45b617c7778d102bad94ba0f98980211eff7ccdd43ea61c17d08f9e319bf6b36b56ca3dcd8b12a240d81cee2b7a7eb234dc822f610e2bc712eb1d9562d826f8fa902107487949fba4538ddbf5d41d161c55fb3fedd6d2c6f90ec177d672e136f1352f4d07d5c21f0173928292e310fbf40ea6d9e974ee5db68501069310b6255e0a541bcb335934e15f6e504807884cd46c91efa9e224f8402fcaef986da5f159a35a40ea221afcb9e00aaf968cacb7d720c2aa1c5025cbd2ae9e3857e857e9bb82981e43f3f197c1286ca0819a7caff78e3621807f2682fa10a49e7091419d99ff0f42ccd22c5b455ca8214117aaad92e46cfd8598dbb533b38d8a4d5f8cafe6caab99468a7bf540f5a7f15414c76b5b404a6cb855af8ad7d62c60959e489a40ded9898a3ee04fdd3de2f8ef95a207b226daa9e4ddcc688e7636fbaeddafc0282f5924f7ffca4f9cdd8115bb17c36ac2b8804c3afaccc1ed4057b97b59d01705cbeea65cac20c6623cdd66cccede7f1db9d98d567e5c48116159b8113f8247a879e0990c2a3ac8c817bf6c98902f8b497621a53ddbccb07d01b7f8694a45ee68d2d04a33cb3535db2e6 -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 0a5d9e0c5ffd0d0eab672509388aa606fb5063e26d23aef59ab011f274eb3f0e6e5349654677159922b90dbcdf521470a696be4cc079c082ab53a5bf6de0c353288b6e92efec6b7ad88fa79652f72921b9e2466f28cf14898fbe2118053764845f8d735c0164f7f9f4715d5e3981cf635dbd63134e2c92526d79ebc3e4f708e8 -S = 31af3922e01de9d2ad34e11b89c1ec21ad76c2913375137206c779459c2db5fa9f180c1a061393f1106c7bd7c0c19e316f37f47f462e1fd870d05332ebaa582579f15e48729e5f8380c947f563244d08aa2104570334c60fa0a01a9f0bf9aae07e2e7c3e5de6acc71f8b3aabb9fe6036674d8eefee4fe7c0e5d3d9323e3fa92931c1a19689e53f4fa53381c4b73f8d91577ca7ce8128b88e8340b63f2e89a4618138c68ee53fb05ca95c94ecfc2526eebc9a38930c12c6f4416db316c507dbee0fe64a3bc66041aaf95f67d9a0294d97b4a4579e0f946fbf7309f042307fd3611f5ff2aab4a738410b62327d2b57cbfd05c5af3e6d61c794732fdf160e61b8bc6a4d3511668d2340bf6d2d1d46bd960e9be045d83bb71a93f1d9f72c67d8e318dc9c78da55758b660e2b1feb7ced2e8ff0a4a29e5febcb40078c92b8019db63551ab866959732aeba71a94df7c35d753e5a831da820d45f09a530176ed964387dda6e7e047302428583c16ace2f4a90f86539c756c0b7baf80a1475851920107fb9f742db3086067fa0c8a6a326f14ba69f8dee961e5cd7407dd5e6d74e81730492d03f825cceb96f2261f2d6b3bb48df1ccc07b9830df23aa26aac452d99d61bab38735b9daae68caa8a36ac7b57e01d181e6ad3321851bf42cfe627c0e2526af37abe7a8f454d754adbd24fccae6778547651d281354e2b167a21cb2e58a86 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = c265cc1668d494b6dbbf477f187eed2a862a49392b00b180200a1de342fc7d612b5c505261e572eccc2e350c6e87b4344e2364cfb57decbd9df4370b67b8c702ccea4c6416ff75f2906606313b6a2b6ec2590b00b0e6a1cde1ccc71036b494598d59e8d5f1ea45cf0db0e177e7f0f9e2cb136753840477b9d3daf77819b78d6c -S = 7b6e5c6672b76a49b637135878e9738da6b1ad1710a1f8c557c5de7c3a5364d4927f3497d6b7daedb931a65e3433dbfde8791af39c97e90437155a3eb3fc96c37d2b0a51126faee5706b0b73c63413f9082d6f0a3d2ad7fcc69e935c016a4abbb2295135bcef8c078e11e262c0c1038f4311926823cb1b148dd8e63942a927e806a84260e51341ff99eb02fa053dc9258b4113da1d76d0734f81234a51a196139171a90c60c9a6f6baadd3e3b99769bd1890984b3e434f94e9f27c7086d86ee86d45ddbd7130bde845b6c47b6dca29edcd6f7898a42e499555700683732feb4c2e200c0fb1e11c0f314682ead943aca08e276eacc1d67e02018690d159a7d50561bec7087c5e21b32bcf2b27c0245f410df9c137696f014befa4a0c13fe7302b44393bfe6e3747cd88ec2dff0c639bbca4e7ecb77f7989a35c2acdb6a9dbb70092a9b7f4f4c8c8d9f7286d9666b24393c95e2cc256c03645944fc7b194a73be5a6acca491c0a98e551aadf5b002a1c42d57149f6788697eda81d1735a85442b6b313ba798c92ec0464a4f02ec3cd5059694428e0961c93e75155d1e5f965e5956a82d7f9ebc51fae9ed151710768ff1c172ae2b68c81da2190575a35cbb5f9eb52f56ba5f838d05d40c35b9fe901a75d5d96e09b85841d68d055bca786514fc6249b136a22870379dbd54576a91b646406ed12445521b67c694e94626ed15f09 -SaltVal = 00 -EM with hash moved = 0001ffffffffff003041300d060960864801650304020205000430c0d206b5a6126ec9a86519315cb38f2484d00f36f2065d3a0dfe6f34657ad926ff281b90d8187ae2c2eb45c68643c352efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010001 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = f1fb8e6cfdfc5dd3931e8fb5c92b974650224e935787f170acfe69b22418d09f3e6d30a303eb8e45306d2758978ff976c3c185aadb9bd46dc871b8d49a2654072845def5f74da4465e4d4d91e7b162d0f75c0d11b2f7206e1988583e7546e48df9ac21caa3cca8c063e68ac87f39da3c36196c2ea442dd5ae56cd35a7d1f8619 -S = 2c0ce9b108db78aebb905e421bd0a993b38d9e6b66bba9cf5a9ad72fea11f0ea2a8eec30e7947fbd552c63535f2097e4d6ccf07024e833967a119abb869327d880ca2c21c3f32dd559eb8fb6090107832aa884eea6c9284231a6869013cb0654b3cf17cc87b39a9b7612e2c91f77ccbc1736d1c7e5816694632fed14bb764c4c4f5f80193b6fb9247026a3e754805f00cb8a73b62f01b6ca9206890aa3008e63a2ca87a0eb54affe1e94f2a676060921620ef8bfc8563abfc9006b8ed0f7c71cb8a987daa6d96c0b819e4d1cf279417998e8d9f7f4334186923a10d3ea888e0b8d8699494c9e5a0468345f1a93a79b436b864a4f84c74f77d95ac7095156d96d4b83000177cc33c8ff9f555bf5afd2968708eee4b10a397ab76c3ff22766caf8d3836b5d5fa7a580bceb6245063bfa74fa9d79cf2c61b8ab92a92ffd93eabeae820ddd5f4c94301bd7210b18142126267a1b2ef3f8725110ad570a7d46ef5a18fd32b031ebf23d0c4f56e134f76b667217d486845f93e965bca006934ef68d5e11f8edb1adcffaaa51b5b0f42959473c53348709ffea3963436dd7794aadee13aa24e1872152b9bbd031e71700a8924556b703c7be70d33e523d9ddddacf0641756468872c7ad17b71208c78fa993561d54aa6255b6abc5d1b9ea7c58f28554a76acc9f662e186a1aff26e6f7ce8c9ac20fb64cadfec72a08ece04b51bda01a7 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 879645d6b8014a368de5b3f59c0f6d61d05150fd6978461c447db0af5d00055c92f1bcd0aa916d55959933a7f5b85403de432482da2926a5312575316737623d05545f899d5d1c11084eefe2f2b8792d9971879ad18936de4c815b9018b821386926f4aa994c9e926d6bb04f9af52405874140ed5582bef01dfa2975786b8a77 -S = 2287114cfb12bbdf370c453bb39e68bea8c24afa1db85239b54f7ced68798dce71ccc3a283859cb67717b7d0299f28238cf05c9016e867203afc345498a98cc933165d1d2103263f0556ad6b89a408227b3d68909f1c31460f818da5a389033004e5d89909661995a6c98fa3a59a56869cefe67d06a7e5580e288a1d69eeffb1aed49e77adfa674123690d42f83411d807ee7fd5a2b21c055ebf9d393733c1fe96d9a9678814fbed5cf5478a54edb8e432524d0c05022a5b477c4fe901ae8b4a8e8d00b1519075fe5e160eb5b1c090a7b1deb970c7f900dd47c47bebcb3fb5334be683dadaf023660d0d82ac0de747f0982cc31428ebcabb03ab4eb46750331fa88db48c15b40dd18a83dce93e7e769db6dd32cb99a78243233d509528b03825ddd5eaf2f29b68396e23293607e8bd5455c23843f63304d5d3865943434b61f471e2b3464f37fadd3d29dd104b36c9f6f859f4d84446364fb56af34e9eb15882519b072b890d682b254d6461f997e056b42452a2346ac6f0653845d456b20c3a273a7d421295ff91871fb525c7274471ecdfa93c9358067dd4911a3010b629d0c2b3a2db23af2a4510d6230522b170b61e804ebf561c7ecf45c5b741c37141ee407809901d557e2c8f88e7a719f2d3b5952928722e96311b9a1ba5106cd5ae9d8d101d583d321fd42c68cf4c28d944ab9433153831e3884556d485c927970f25 -SaltVal = 00 -Result = P - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 92b5088f66c761117eefe5d57d490b0a2d8f735adaed7065f910c46f0e81aa55cc311ac67d5548afa4736ef7e1bdcb6d169febffc8942a2cc83d74bc12b44eaef51e1a72747f9658edd3a749f85a55b5923316cc7b2c4ff1dcd9186b2de3405e56a390fa14ef54f39f3418318ac5b0c8ea737b2aba5ee89c7e0b38e627b6864f -S = 50758bef01ca5623082d4fb6888e9c27598bdefd63abd5168c8a122d4bc26e45d50736136f9f28848b082f18ae69cc2c3cba98f3458cbe71167a6629ea604a606b7a10fba68edd1576367ef0551b1c0dac9ab830ba41d7c9825ddab0a4cf01c62669d3c7f434e18c6bba0c6b931f6317f66f0aa6694441bbb9cfb74220920d9d861a857cd984c0e35666eded9d6d67fead62231f2cef40fe4252d02aaa3b12418d26cb646128fa69e13c57f90a85a7606859f84da62feace94bfb607cbb8fce4c23006b1a3f0aa6724072ade5c1cc2c664556edb9d40ff63d0de44b35a68e81aea98e98d52883c4fe41cca6f1f09398251f28d30165f34b74b008af8742b93c8fb7586cef90efa60e0542f3f5f85dbee12b3008c834a13c587dbda2e570dd12149390fb7e8788b46502046e0e158c3aede9c789895af2508663d7d1b9ede251321800db59575bd7971bb9a93a2c0ad2ec377f0268e7b6eb404c0cc02055d0e69726176f39b8826b1bcf8f4df7a7ede44a5ebe2d862825d6b1c11e9a30ab838789bee11344aa1d88e8495792c68344fa889ee8c2dfa418b5fcd18ba7cce65018fb6ea8d00dee814084eac349f5a233f34b2921cc0f09b5f6b6aa4cdaf90196f14ea66dcc9ab1ccc4acc1ca2d097bff923252db6d19db50e877f6848e3a14dc8d799fd8a8722aa6e98b5b4e53225af9d2c40811c6967e525db1993ed1539fcecde -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443041300d060960864801650304020205000430d6b9bb354aa8acf8326afd721b8bbb21603ef5d2f897c52cc0f27f9169f5bb894168a77ee4a65079fd68e9b38a7a4ea9 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA384 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 9a5592fd0be381aad74258865cab802a5f161df848a2e3a38e382af2706b45c0e6a31048d77bc99f8c672182659a9252ca27f25d6566495f8e99e04907cf9a40ea0987e9df9cb7e492d64c9665e4d32c62f3d5dc7396a86ed5688bfccaf2f3f68ecf1f688d0df280d3d7024bc451edbf0dc4ecfedafbaad94aed56931f9cf6e8 -S = 6b95909cfb0edba3177083097f74edac27b652bfd73575efac3db0971290bd7718b5a5491724c095a25c1a75b67a24a9e7caea4e2319637abe40efc0c5ce640a879978aac6ec898a4cce02b87cffb59f0c27c1c01759d7f698adf77003e033e70895e64a1f50f8cc471f61cb8e4c37a6a32e0875551b558314442fd7880c1fc74046b960f6fb4938ca6a7b1fc709cb046cb51c5fcf32c5d8e63324c88cd3ba6ff43406688771d1fd5ace55ccd8c90a96f403461f65c1cafd3068c4be660ccd740f34edcc1b4c57ee0e5ea5a3c2b9d76e583a9d1c70f480f508d589e72dfb0e5a6355bd70a2f90bddc1847d582d426f37b1060e475bfc62ca3133f4431407b948cbbf8ef4ec6488d773c5a840ffe2bf2cdd8a9aa753d0e66733daa5837f26eee99be7ac230fe0437898b6f9cf8e92419f0ee112d0475dfed75f8a8dfa4fe2f1e7d54da8fed8bd883f7326890f74a61beb22ad9822536bd3780f8a18573d16376f4f393e8e2305decfea889933b92d673569b4038d49547cde3c11e4f1331ded794c6fdb266c02048ce0be47b829e9be709ceaea89c3acfb12741332d147d8fe981b146955a29186f1b44f69ea276e78448d5752117eae565cfa54e6dda92387f330542dd30bb9426e1965a76a5a438f55ce22d252fd8e62df04c4e8c7a719385d4d56f37194f7e03368d17fe8165ed176d636b3b55fb99c483d707d160543561a -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = e0e52ff4aaaab424199c5cf2a172d1ebe64f7b6e2096fe19c400048161ec3c26c7f6a3a66fca0230173bb73cad8fb9796e1dd7074f1b40e79cb148b0df516983034b8840b99c7afa1b07c7a98f68ae1fef44693ee7a4b2679e2485359847286cdb0d692c50c8276b6d2b13a211a4b8c5afecb979afdc5a821182427a547480c9 -S = 8c61782fa17abd9424bd4df6333f775a1a36cb913fc3324d4a860c4619ab778ec699e88cbf7d55d8b9e7c9a4bf760ff1238c1b65f3d3afb50702c844706e855187ca2fbc92c18f5ac9558b8b719f7e985d791caf719721c66673026c393fd6fe4aaad8829188e5978ed401256ab8ece9d6713b55a0b8cce1c33b9dc333ed48d83bbbab4290471866d1d4d3e239daa5f315e18a19f78d7679ea1ba028032dfbca40ab0ac436f948a129c7d182911d0452548755a90dffa2294a4089c2a46352b1e76e06c203e230a0229989ddab4171deeef125af7ad0be3f28dd2d3cdaf25ef500d8d7134546bc79806ad7bc8dbdfd882f6924148b2480cffdd9d4ef0235385c76687fe669822ae14238736c4e8fa48d494ea578a6a940f07be7284274dbe9aabba9b6077d253eeaecd483f60763f8baee3d5e27a7c820c103160df87f875b10ffad7d810283fe118fd040b0e64b8b007aaa049a5ea739f85ad8245e0223f3bb3c66904bb89bb58eed61324ceb4b49b951de42d1ffff7ed9905050d05c73f34946562d5d39acf768f7be5292f20448bc5b61795fe077631587abc5465e67fff8118dbefda942bdbbe673eab46142f047d0359f112f64ba92eb54ee45b349bcb3befb89e31080d48303c90acafa4aa09466348b50f2923d29c1f9bf34dad7b3246653c7fd20f480b33ef3d9e116ddda73b7791f2fc5fc4c31bcac2bde5b79691f -SaltVal = 00 -Result = P - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 2fd1aa7be544c3206a9d43464b3fcd90f3f8cf48d08ec099b59ba6fe7d9bdcfaf244120aed1695d8be32d1b1cd6f143982ab945d635fb48a7c76831c0460851a3d62b7209c30cd9c2abdbe3d2a5282a9fcde1a6f418dd23c409bc351896b9b34d7d3a1a63bbaf3d677e612d4a80fa14829386a64b33fa217c9b26e8453e4a6b2 -S = 560a204f8a24adc61ac4d3c8de48304d9c59f6faf1bf1059bf1edb7e786ad81d95d6e17acfc30d84a151ff5496507da3094b7464839443d5530e22d6316076fadb5ffa013319230b14115e0905a997f4019dad2abde8d415a2b040bc6413c172a620a878d3695f70ffceb14fbeeb4538bf3c9b905e5907cba8ed8fc4a6ef9eeb863c99251abfaa9c483198618f2858a0c2d04a3f7e1e51128c9309303e01182cbfa20ea398c02354247fb30d32e977e6ea2dcc97be8921149257d13e31dde63b4992b167dd87f53116114a6344a3913ee313b4361d9258a2b10e9cefb19d0455466574bd58c0f284f99362737d0ad83d3ed0d587084f4e677a6748d68c1e3fee364600905873bb10de67b02e0aca45273ddb2f667aa22e885231b2bede0b541b79d2adf5e251be56e43b2577bba5244838471ed6899871016372771f88ebde49a776bb11697f15e50d490be4e52f95868f01bbd8ca549a60c50f1e99ddfe399f76fea48567e6abc0a845ddac6e963964624e38e1fb56565f99f3cdd7ddb7aebc3c53c7d82c6e3eeb058d128b4bacaca5f5fc8b037818d34c732fd15aeb70b0d688a233b5f91b65ff1f68cfa6f3a55b144840a9979996dfcfdf84cd9b02d385a842b27121cbe645155521e2c53ba3f1747af5609950b0cc808f33402dbb94fd1128fe9b309850b9ef11e82ec0498d595ff6436aab76a4df49047d76e5342c14b1 -SaltVal = 00 -Result = F (1 - Message changed) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 6ed981437f350723c4f1677f7bacdb78d12a22a19b3ed30646edf16d11d0bfdb79bad65af59b74fae4a41716c4ac4bd8a4d3c0ffdc659fe0fb011eab01fa53f0cffd4562dbf449da282b8c9f76b1ece4b6020c92c0e2a748488c24a00e0c6bb556eaf8e298082dcc78cdeda2f88366a3edfe2ee1b07f924515d82bd4a1d0b230 -S = 4684f8bc41880feaebaf54fc8cbb1d85c378db4bb916a7e162fa6683667b2f6df1e41e722f57e027486dd2c89ec035e2fe88ec082bbc105422b9116362bb00fac7f687297a858a08bea678d8489ce7cc27133c4f0acba0c7aee1daa55938ba2fc8957e6dca7493c0f054cc8a61d96b1d2689b1af69b491f58aeb6b3011827ad0d60bf1385402d4c7e7dac0f6f1259e7069a788816cce8db301639007ed1224bbdcbef9447df741cdb6a1f03796398372eb86ed8c995d281326a834688010becd7c737096de2573eb210035f14b937cf614cab6d1717711685e029b7b23d922bf2d6d63e354af5cf1b8609d021196e04a4e1baab203b1adce2b9c4bdf5a9a989157d2832867abc5173e5944ff070c9f7b06a14373fac3bfd76a73129e4cd0420c4696da9ef6f672f4cc9973434bcd2f0e351fe4509138d20a55bf73e42365da8d7ba3dd74b86055a785d346546de0f9837ecbcf52d6658e16e657b20428a8003a9b31d9f69e8206da1068fea98ea282a8731d96fe5e5be7d0b68c9eaf16090eea1f424e4cc5a509f8d6efb97f846d8ff1bd739288deeeecee6d0122eff6efbba9541ee1b2387f2092022df8584521d556bdc7ff9c8914d35a7b44075382fa3f03a3d4ec1ad11539cdf3b92eb37da08949c7ddbc2108e228c4548f41224b4da41098ae67a048be0fd22254a49186360bd0cea7877621130af6b8abfb490a108ab0 -SaltVal = 00 -Result = F (2 - Public Key e changed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 3a33da20cfb3e3ac722e7df7865330b8f62a73d9119a1f21992e240f16197b0970775cb6bdd5b0a858f4c93e33ca51c86eca80ed2865924a95d1795c5009cfa0f3150ef8e68b03517456808324b6527846887291ccc880455b546c0ca2f2777beb955ab0efdcc4f0efdc0a8f001f1a10a7ecb28ea5c9cf5b143f67e6b3dd5ae2 -S = 2fd9e8beeb55cf3640f615951e25b1731e1c51b4a1a2f251ff2761c3de6393c00f1ee2876e103a38c3149eafb804efa687b953eaf86b270d6cef192869aacc206f2018067df43db0ad8de6687ecd0535ed299180521066553ae2e6ed21604193eac012986767e48aea294fa3769482bcd2c167723707284dbcc7849d8320220319f7087baae33e7d05cab1e1430d3b2ba0e9ec5c5620f097c13b5a5a7c286ec9061f1963d27aafd79e2a217da1cb99389a5335ceb7690db3ce5cac022a542c14be25cb3e090400653a46863f443bd40807c546916b8090098fc5416744aa8d167bbcd48d718f5fee47339ec5446bbcb53ff6270f761e57589c399b558a24da5a5b3121a4a296e1ee1e01395f20b967c6cfaf2dd92e6e9fbc7c866b910570808e8dc87b66a8d9518dd9829f71f6a5e7e544e86551d907fcf2da2f4707e19586c19598a063ec1bfb252d91449f22ca90f2f88bbc6266ede3c19912a2481f70795a0a6ab6c1644a9458f9dce7a6459587135f5e3f20944a00d0874ff3b748a12a81e54a33da1a65df5dd932dbd979c79116e7d1138d35abf18b2a82c364490975c118c194c102a7c0eae6c629ec8043f9c55b63e55eacb3b352250ef5fa489ace55ec6b0771711aefd26f35483dacabe89fd15e248f669b5b2c343ba9de80b523432b9a0e4b05486c0132c4e1608f49efd481aed7b6da2ddd78fd5bafefcef2f074 -SaltVal = 00 -EM with trailer wrong =0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff443051300d060960864801650304020305000440ece68078ae14353fad83f9da0bc52f954e4f83bdc06abda384df386e15c66759f7a78859e7627c41d5c146cb5f8a46a147f1bb3ce2fbccd6d7efaa3d098c0a64 -Result = F (5 - Format of the EM is incorrect - 00 on end of pad removed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 244581a2b06130d1af01b83ab281dc252d97481cd92819575660a0781501637975fb65e22c3ea83fe9ccefd13812c884a578ca2124371cc5b06a37923369eca4a652a84679e8f76635a1474760faef76a10e6fff2467f9e0401431be57fb32d7fe71d1385e082530daa84704f3e256e46880be1ea161ba924d8418664b623dfb -S = 45b532bc216a9e6c0b58ef1e500e0cfc11cb85614faa4301e5c373acbb46f1fa655975b8fe4d50098f5b1ffff7e45db3e339b27b2d6d3349fa952922b876dd333c862bacf6cf4d3b1b98fca4adc2a4674b0397326ebad63a553f97cbf763d5549e982b999eaa77dfa074311d236936056a2f097385136ea5d82f76190e4a896bd5c2ef3580eb98340b136dae2215c3ec324ad44fa1920213fc6985faa58fab2a5ab4f1c268dc1489c4f257e54c573247a6e32640780f7345dcd7c371de12696a2fff5d94ab9677914d3d21fd0b436405b8122f410a3374ed67c8b414120a1c50c18b6a8acaff5bb68b2ced8036d30045378402e4cd193cfab277e9808045b30c65f947f39c4b3b25af8130a46d03fef6ab01c8d3a5807ff6a96628523fcd8447f24d11cbad36b5553f5d4c8051739a700d6113d48e3c28bee871fc00c46b013e887ba957ab45911f056d4b98c00b4e6b5b02b1d674918b90b40ca688e096ad0705d6f72e4999b0cbe9ed94cb297df6872e02fbd3ed2a8be758d4e6af7fa416b14d6785852b2a06d001e1b10e9829e3c6ad27bb2f1ce05104115decac07ff9c4e3cbb0bc0d264e9f27e9dcb48a9d8ce44b5e6cb37defc81e282071eb0ea06285c5afed12fa5b509a54449dbcd19431ad4522348ab0aed336c351709d3aa717d1e453362bc65d041af2fa7c1328231420741b433373e78d98f23940d6e59c132e7 -SaltVal = 00 -Result = F (3 - Signature changed ) - -SHAAlg = SHA512 -e = 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011 -d = 09d77b3b07c31dacabcdf1e8078a1321cb08f1765488e71b320c0bb56cfc04868a0edf060a6a6f90691164844852546dff634167aa1b0fe81d69fba8fcebcdfbee9e781425b29af7c5df6156d71b1264b592d53efa8a7bfd4a0b2fc0ac1863904241d09ea376ecffdcf36cfac560c74b210c1c1886d4a6dfc94959f5190e8ea9082d85e7e8fd58bd374db170f86362ed0b4c2a2084ce93ba924a95e905b52e1a9c2215cc3d5d8de7d76a718080c3a15e71ddf60af46bd9ba62557a00e9ced85ba8f0751dad3f4e212957265c67de3eea774d7f7514d40a0814880b724bc1ed43de7e7f34334ab19f9e50dd5fac9403c6d14b0ea9e1663e63510c96419c10c134de0eb4ecf88918f782e272ececca42a6c04898a0c738eceea3319e81c0e6fb4236fdaaa191b196a7e8fc39e35a88d844b2c2f0929f029e49b03f1b65804ced3594c1304fe2ae987ab4d24a7faed4da097d58c94125884d095b59d26f2fd207e4dca58c54c0a74115d2f635a97e86e484ea8fe5a25a0dfb787fcefbe53f4dcc299ed23802b79ae2cd433227128eed0bd640bb5f51c93707379fd715c7a39b69c559fb8ff6d43eadb2eae2034d93c0c7f39b5e50044aa201d4d0c3036e4004201d558c4b87e31bfbd10654032808d9133200f8ca8e8206ea26fe2a3ef27005d2b245bb91c528fbe9a45687e94aaae83cbe25b452b3c26bc17c3efda7818f24201d -Msg = 24c8f1e99508bd234cf1161e94b439ac41e6392994d4ff685e178fee68688e5e13b501353c7458b76237ab2a0b80434163d75cdb271b29eec11619bdb55359523b349a282d3f142824b9cbd6df7611cde4ef4c696995f9c37465f1e242bdeb2fe66e432a3212fa5cdaa0fd8cd73daa360a55903922eb76d0bf2d9fc3d74c4ddf -S = 3941bb2afeacc1962b51ffecb000ed9406ba6e0935006203eac5aab1e35b980e6b3bbacf6d79f249e2c0fcd4259298d659870fbfa7e5c78d0e72aec15768e9e9d7353369ef2c91240645dfe40d85f68026bc4aff204798ad20cdf05a66640f6885ab633597636cd5af965ef1d2bdcc5dd0922f23e150ba67cdf148421d6ed43349b2ab426af2c9609eda45b980c842c2817513f8d0ec7c1b404fe07a7269088e359948fa05a6d63d3002f88ccd3167dc30242a42a07b17940a4f5763013800fefced30d42daef920e15d167e6bef092d440be42624e6f855ab7842a8871140dc17458f479933e082f1794a4c56cb338d31ca4f5bc6983dc2ec124e6785b16a0530b4c7e33488da83a184aff5448277a61c32cf6a8a4995a939552e0cad8d37da113b7806510577af56f9abfc7a37c566405be6d0b3271d8dd9071a0e83c51467f2fd3d22c805bc9ea025d1b1033a99235acb145729df2b6dcd761196c74b02f8aec2b53d19c20be6b3f7e46c21690737c675d46d240d6774278c0dc7db0a817b570cd493530d2acc0685bb1d51a81992ba45a3acbb690467fcd2524deef1b2efd643cac753d86a760c9428427a7b5cfe2624efdcca0f4c2c02ae67c3e3df01c4a19c3172377b425834c1c376366eab600693f63ece2d6ff94412f768a9dba4d202d70a9324f76b2f58295015164213c71d3bae7b90edd800ada1d972353f320c -SaltVal = 00 -EM with hash moved = 0001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff003051300d060960864801650304020305000440f8b77aee7f4480f3de4575717e774c7735f9d46cfbc3706fcc2cbfed078b75fa59223ba0cda570d5bdf5ba1bd9d087f37e36b22b65552b85cfcc01a7b30c7f78efefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefefef -Result = F (4 - Format of the EM is incorrect - hash moved to left ) diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/SignatureChecker.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/SignatureChecker.test.js deleted file mode 100644 index e6a08491a5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/SignatureChecker.test.js +++ /dev/null @@ -1,61 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const TEST_MESSAGE = ethers.id('OpenZeppelin'); -const TEST_MESSAGE_HASH = ethers.hashMessage(TEST_MESSAGE); - -const WRONG_MESSAGE = ethers.id('Nope'); -const WRONG_MESSAGE_HASH = ethers.hashMessage(WRONG_MESSAGE); - -async function fixture() { - const [signer, other] = await ethers.getSigners(); - const mock = await ethers.deployContract('$SignatureChecker'); - const wallet = await ethers.deployContract('ERC1271WalletMock', [signer]); - const malicious = await ethers.deployContract('ERC1271MaliciousMock'); - const signature = await signer.signMessage(TEST_MESSAGE); - - return { signer, other, mock, wallet, malicious, signature }; -} - -describe('SignatureChecker (ERC1271)', function () { - before('deploying', async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('EOA account', function () { - it('with matching signer and signature', async function () { - expect(await this.mock.$isValidSignatureNow(this.signer, TEST_MESSAGE_HASH, this.signature)).to.be.true; - }); - - it('with invalid signer', async function () { - expect(await this.mock.$isValidSignatureNow(this.other, TEST_MESSAGE_HASH, this.signature)).to.be.false; - }); - - it('with invalid signature', async function () { - expect(await this.mock.$isValidSignatureNow(this.signer, WRONG_MESSAGE_HASH, this.signature)).to.be.false; - }); - }); - - describe('ERC1271 wallet', function () { - for (const fn of ['isValidERC1271SignatureNow', 'isValidSignatureNow']) { - describe(fn, function () { - it('with matching signer and signature', async function () { - expect(await this.mock.getFunction(`$${fn}`)(this.wallet, TEST_MESSAGE_HASH, this.signature)).to.be.true; - }); - - it('with invalid signer', async function () { - expect(await this.mock.getFunction(`$${fn}`)(this.mock, TEST_MESSAGE_HASH, this.signature)).to.be.false; - }); - - it('with invalid signature', async function () { - expect(await this.mock.getFunction(`$${fn}`)(this.wallet, WRONG_MESSAGE_HASH, this.signature)).to.be.false; - }); - - it('with malicious wallet', async function () { - expect(await this.mock.getFunction(`$${fn}`)(this.malicious, TEST_MESSAGE_HASH, this.signature)).to.be.false; - }); - }); - } - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/ecdsa_secp256r1_sha256_p1363_test.json b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/ecdsa_secp256r1_sha256_p1363_test.json deleted file mode 100644 index 9cd94cf8b4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/cryptography/ecdsa_secp256r1_sha256_p1363_test.json +++ /dev/null @@ -1,3719 +0,0 @@ -{ - "algorithm" : "ECDSA", - "generatorVersion" : "0.8r12", - "numberOfTests" : 219, - "header" : [ - "Test vectors of type EcdsaVerify are meant for the verification", - "of IEEE P1363 encoded ECDSA signatures." - ], - "notes" : { - "EdgeCase" : "Edge case values such as r=1 and s=0 can lead to forgeries if the ECDSA implementation does not check boundaries and computes s^(-1)==0.", - "PointDuplication" : "Some implementations of ECDSA do not handle duplication and points at infinity correctly. This is a test vector that has been specially crafted to check for such an omission.", - "SigSize" : "The size of the signature should always be twice the number of bytes of the size of the order. But some libraries accept signatures with less bytes." - }, - "schema" : "ecdsa_p1363_verify_schema.json", - "testGroups" : [ - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "KSexBRK64-3c_kZ4KBKLrSkDJpkZ9whgacjE32xzKDg", - "y" : "x3h5ZOqsAOWSH7FJimD0YGdms9loUAFVjRqXTnNBUT4" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "042927b10512bae3eddcfe467828128bad2903269919f7086069c8c4df6c732838c7787964eaac00e5921fb1498a60f4606766b3d9685001558d1a974e7341513e", - "wx" : "2927b10512bae3eddcfe467828128bad2903269919f7086069c8c4df6c732838", - "wy" : "00c7787964eaac00e5921fb1498a60f4606766b3d9685001558d1a974e7341513e" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200042927b10512bae3eddcfe467828128bad2903269919f7086069c8c4df6c732838c7787964eaac00e5921fb1498a60f4606766b3d9685001558d1a974e7341513e", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEKSexBRK64+3c/kZ4KBKLrSkDJpkZ\n9whgacjE32xzKDjHeHlk6qwA5ZIfsUmKYPRgZ2az2WhQAVWNGpdOc0FRPg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 1, - "comment" : "signature malleability", - "msg" : "313233343030", - "sig" : "2ba3a8be6b94d5ec80a6d9d1190a436effe50d85a1eee859b8cc6af9bd5c2e184cd60b855d442f5b3c7b11eb6c4e0ae7525fe710fab9aa7c77a67f79e6fadd76", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 2, - "comment" : "Modified r or s, e.g. by adding or subtracting the order of the group", - "msg" : "313233343030", - "sig" : "012ba3a8bd6b94d5ed80a6d9d1190a436ebccc0833490686deac8635bcb9bf536900b329f479a2bbd0a5c384ee1493b1f5186a87139cac5df4087c134b49156847db", - "result" : "invalid", - "flags" : [] - }, - { - "tcId" : 3, - "comment" : "Modified r or s, e.g. by adding or subtracting the order of the group", - "msg" : "313233343030", - "sig" : "d45c5740946b2a147f59262ee6f5bc90bd01ed280528b62b3aed5fc93f06f739b329f479a2bbd0a5c384ee1493b1f5186a87139cac5df4087c134b49156847db", - "result" : "invalid", - "flags" : [] - }, - { - "tcId" : 4, - "comment" : "Modified r or s, e.g. by adding or subtracting the order of the group", - "msg" : "313233343030", - "sig" : "012ba3a8be6b94d5ec80a6d9d1190a436effe50d85a1eee859b8cc6af9bd5c2e1800b329f479a2bbd0a5c384ee1493b1f5186a87139cac5df4087c134b49156847db", - "result" : "invalid", - "flags" : [] - }, - { - "tcId" : 5, - "comment" : "Modified r or s, e.g. by adding or subtracting the order of the group", - "msg" : "313233343030", - "sig" : "d45c5741946b2a137f59262ee6f5bc91001af27a5e1117a64733950642a3d1e8b329f479a2bbd0a5c384ee1493b1f5186a87139cac5df4087c134b49156847db", - "result" : "invalid", - "flags" : [] - }, - { - "tcId" : 6, - "comment" : "Modified r or s, e.g. by adding or subtracting the order of the group", - "msg" : "313233343030", - "sig" : "002ba3a8be6b94d5ec80a6d9d1190a436effe50d85a1eee859b8cc6af9bd5c2e1801b329f478a2bbd0a6c384ee1493b1f518276e0e4a5375928d6fcd160c11cb6d2c", - "result" : "invalid", - "flags" : [] - }, - { - "tcId" : 7, - "comment" : "Modified r or s, e.g. by adding or subtracting the order of the group", - "msg" : "313233343030", - "sig" : "002ba3a8be6b94d5ec80a6d9d1190a436effe50d85a1eee859b8cc6af9bd5c2e1801b329f479a2bbd0a5c384ee1493b1f5186a87139cac5df4087c134b49156847db", - "result" : "invalid", - "flags" : [] - }, - { - "tcId" : 8, - "comment" : "Modified r or s, e.g. by adding or subtracting the order of the group", - "msg" : "313233343030", - "sig" : "2ba3a8be6b94d5ec80a6d9d1190a436effe50d85a1eee859b8cc6af9bd5c2e184cd60b865d442f5a3c7b11eb6c4e0ae79578ec6353a20bf783ecb4b6ea97b825", - "result" : "invalid", - "flags" : [] - }, - { - "tcId" : 9, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 10, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 11, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000000ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 12, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000000ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 13, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000000ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632552", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 14, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000000ffffffff00000001000000000000000000000000ffffffffffffffffffffffff", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 15, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000000ffffffff00000001000000000000000000000001000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 16, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "00000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 17, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "00000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000001", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 18, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000001ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 19, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000001ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 20, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000001ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632552", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 21, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000001ffffffff00000001000000000000000000000000ffffffffffffffffffffffff", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 22, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000001ffffffff00000001000000000000000000000001000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 23, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc6325510000000000000000000000000000000000000000000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 24, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc6325510000000000000000000000000000000000000000000000000000000000000001", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 25, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 26, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 27, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632552", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 28, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551ffffffff00000001000000000000000000000000ffffffffffffffffffffffff", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 29, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551ffffffff00000001000000000000000000000001000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 30, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc6325500000000000000000000000000000000000000000000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 31, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc6325500000000000000000000000000000000000000000000000000000000000000001", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 32, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 33, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 34, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632552", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 35, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550ffffffff00000001000000000000000000000000ffffffffffffffffffffffff", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 36, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550ffffffff00000001000000000000000000000001000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 37, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc6325520000000000000000000000000000000000000000000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 38, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc6325520000000000000000000000000000000000000000000000000000000000000001", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 39, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632552ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 40, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632552ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 41, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632552ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632552", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 42, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632552ffffffff00000001000000000000000000000000ffffffffffffffffffffffff", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 43, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632552ffffffff00000001000000000000000000000001000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 44, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000000ffffffffffffffffffffffff0000000000000000000000000000000000000000000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 45, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000000ffffffffffffffffffffffff0000000000000000000000000000000000000000000000000000000000000001", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 46, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000000ffffffffffffffffffffffffffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 47, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000000ffffffffffffffffffffffffffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 48, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000000ffffffffffffffffffffffffffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632552", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 49, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000000ffffffffffffffffffffffffffffffff00000001000000000000000000000000ffffffffffffffffffffffff", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 50, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000000ffffffffffffffffffffffffffffffff00000001000000000000000000000001000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 51, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff000000010000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 52, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff000000010000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000001", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 53, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000001000000000000000000000000ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 54, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000001000000000000000000000000ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 55, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000001000000000000000000000000ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632552", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 56, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000001000000000000000000000000ffffffff00000001000000000000000000000000ffffffffffffffffffffffff", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 57, - "comment" : "Signature with special case values for r and s", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000001000000000000000000000000ffffffff00000001000000000000000000000001000000000000000000000000", - "result" : "invalid", - "flags" : [ - "EdgeCase" - ] - }, - { - "tcId" : 58, - "comment" : "Edge case for Shamir multiplication", - "msg" : "3639383139", - "sig" : "64a1aab5000d0e804f3e2fc02bdee9be8ff312334e2ba16d11547c97711c898e6af015971cc30be6d1a206d4e013e0997772a2f91d73286ffd683b9bb2cf4f1b", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 59, - "comment" : "special case hash", - "msg" : "343236343739373234", - "sig" : "16aea964a2f6506d6f78c81c91fc7e8bded7d397738448de1e19a0ec580bf266252cd762130c6667cfe8b7bc47d27d78391e8e80c578d1cd38c3ff033be928e9", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 60, - "comment" : "special case hash", - "msg" : "37313338363834383931", - "sig" : "9cc98be2347d469bf476dfc26b9b733df2d26d6ef524af917c665baccb23c882093496459effe2d8d70727b82462f61d0ec1b7847929d10ea631dacb16b56c32", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 61, - "comment" : "special case hash", - "msg" : "3130333539333331363638", - "sig" : "73b3c90ecd390028058164524dde892703dce3dea0d53fa8093999f07ab8aa432f67b0b8e20636695bb7d8bf0a651c802ed25a395387b5f4188c0c4075c88634", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 62, - "comment" : "special case hash", - "msg" : "33393439343031323135", - "sig" : "bfab3098252847b328fadf2f89b95c851a7f0eb390763378f37e90119d5ba3ddbdd64e234e832b1067c2d058ccb44d978195ccebb65c2aaf1e2da9b8b4987e3b", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 63, - "comment" : "special case hash", - "msg" : "31333434323933303739", - "sig" : "204a9784074b246d8bf8bf04a4ceb1c1f1c9aaab168b1596d17093c5cd21d2cd51cce41670636783dc06a759c8847868a406c2506fe17975582fe648d1d88b52", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 64, - "comment" : "special case hash", - "msg" : "33373036323131373132", - "sig" : "ed66dc34f551ac82f63d4aa4f81fe2cb0031a91d1314f835027bca0f1ceeaa0399ca123aa09b13cd194a422e18d5fda167623c3f6e5d4d6abb8953d67c0c48c7", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 65, - "comment" : "special case hash", - "msg" : "333433363838373132", - "sig" : "060b700bef665c68899d44f2356a578d126b062023ccc3c056bf0f60a237012b8d186c027832965f4fcc78a3366ca95dedbb410cbef3f26d6be5d581c11d3610", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 66, - "comment" : "special case hash", - "msg" : "31333531353330333730", - "sig" : "9f6adfe8d5eb5b2c24d7aa7934b6cf29c93ea76cd313c9132bb0c8e38c96831db26a9c9e40e55ee0890c944cf271756c906a33e66b5bd15e051593883b5e9902", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 67, - "comment" : "special case hash", - "msg" : "36353533323033313236", - "sig" : "a1af03ca91677b673ad2f33615e56174a1abf6da168cebfa8868f4ba273f16b720aa73ffe48afa6435cd258b173d0c2377d69022e7d098d75caf24c8c5e06b1c", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 68, - "comment" : "special case hash", - "msg" : "31353634333436363033", - "sig" : "fdc70602766f8eed11a6c99a71c973d5659355507b843da6e327a28c11893db93df5349688a085b137b1eacf456a9e9e0f6d15ec0078ca60a7f83f2b10d21350", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 69, - "comment" : "special case hash", - "msg" : "34343239353339313137", - "sig" : "b516a314f2fce530d6537f6a6c49966c23456f63c643cf8e0dc738f7b876e675d39ffd033c92b6d717dd536fbc5efdf1967c4bd80954479ba66b0120cd16fff2", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 70, - "comment" : "special case hash", - "msg" : "3130393533323631333531", - "sig" : "3b2cbf046eac45842ecb7984d475831582717bebb6492fd0a485c101e29ff0a84c9b7b47a98b0f82de512bc9313aaf51701099cac5f76e68c8595fc1c1d99258", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 71, - "comment" : "special case hash", - "msg" : "35393837333530303431", - "sig" : "30c87d35e636f540841f14af54e2f9edd79d0312cfa1ab656c3fb15bfde48dcf47c15a5a82d24b75c85a692bd6ecafeb71409ede23efd08e0db9abf6340677ed", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 72, - "comment" : "special case hash", - "msg" : "33343633303036383738", - "sig" : "38686ff0fda2cef6bc43b58cfe6647b9e2e8176d168dec3c68ff262113760f52067ec3b651f422669601662167fa8717e976e2db5e6a4cf7c2ddabb3fde9d67d", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 73, - "comment" : "special case hash", - "msg" : "39383137333230323837", - "sig" : "44a3e23bf314f2b344fc25c7f2de8b6af3e17d27f5ee844b225985ab6e2775cf2d48e223205e98041ddc87be532abed584f0411f5729500493c9cc3f4dd15e86", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 74, - "comment" : "special case hash", - "msg" : "33323232303431303436", - "sig" : "2ded5b7ec8e90e7bf11f967a3d95110c41b99db3b5aa8d330eb9d638781688e97d5792c53628155e1bfc46fb1a67e3088de049c328ae1f44ec69238a009808f9", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 75, - "comment" : "special case hash", - "msg" : "36363636333037313034", - "sig" : "bdae7bcb580bf335efd3bc3d31870f923eaccafcd40ec2f605976f15137d8b8ff6dfa12f19e525270b0106eecfe257499f373a4fb318994f24838122ce7ec3c7", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 76, - "comment" : "special case hash", - "msg" : "31303335393531383938", - "sig" : "50f9c4f0cd6940e162720957ffff513799209b78596956d21ece251c2401f1c6d7033a0a787d338e889defaaabb106b95a4355e411a59c32aa5167dfab244726", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 77, - "comment" : "special case hash", - "msg" : "31383436353937313935", - "sig" : "f612820687604fa01906066a378d67540982e29575d019aabe90924ead5c860d3f9367702dd7dd4f75ea98afd20e328a1a99f4857b316525328230ce294b0fef", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 78, - "comment" : "special case hash", - "msg" : "33313336303436313839", - "sig" : "9505e407657d6e8bc93db5da7aa6f5081f61980c1949f56b0f2f507da5782a7ac60d31904e3669738ffbeccab6c3656c08e0ed5cb92b3cfa5e7f71784f9c5021", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 79, - "comment" : "special case hash", - "msg" : "32363633373834323534", - "sig" : "bbd16fbbb656b6d0d83e6a7787cd691b08735aed371732723e1c68a40404517d9d8e35dba96028b7787d91315be675877d2d097be5e8ee34560e3e7fd25c0f00", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 80, - "comment" : "special case hash", - "msg" : "31363532313030353234", - "sig" : "2ec9760122db98fd06ea76848d35a6da442d2ceef7559a30cf57c61e92df327e7ab271da90859479701fccf86e462ee3393fb6814c27b760c4963625c0a19878", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 81, - "comment" : "special case hash", - "msg" : "35373438303831363936", - "sig" : "54e76b7683b6650baa6a7fc49b1c51eed9ba9dd463221f7a4f1005a89fe00c592ea076886c773eb937ec1cc8374b7915cfd11b1c1ae1166152f2f7806a31c8fd", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 82, - "comment" : "special case hash", - "msg" : "36333433393133343638", - "sig" : "5291deaf24659ffbbce6e3c26f6021097a74abdbb69be4fb10419c0c496c946665d6fcf336d27cc7cdb982bb4e4ecef5827f84742f29f10abf83469270a03dc3", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 83, - "comment" : "special case hash", - "msg" : "31353431313033353938", - "sig" : "207a3241812d75d947419dc58efb05e8003b33fc17eb50f9d15166a88479f107cdee749f2e492b213ce80b32d0574f62f1c5d70793cf55e382d5caadf7592767", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 84, - "comment" : "special case hash", - "msg" : "3130343738353830313238", - "sig" : "6554e49f82a855204328ac94913bf01bbe84437a355a0a37c0dee3cf81aa7728aea00de2507ddaf5c94e1e126980d3df16250a2eaebc8be486effe7f22b4f929", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 85, - "comment" : "special case hash", - "msg" : "3130353336323835353638", - "sig" : "a54c5062648339d2bff06f71c88216c26c6e19b4d80a8c602990ac82707efdfce99bbe7fcfafae3e69fd016777517aa01056317f467ad09aff09be73c9731b0d", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 86, - "comment" : "special case hash", - "msg" : "393533393034313035", - "sig" : "975bd7157a8d363b309f1f444012b1a1d23096593133e71b4ca8b059cff37eaf7faa7a28b1c822baa241793f2abc930bd4c69840fe090f2aacc46786bf919622", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 87, - "comment" : "special case hash", - "msg" : "393738383438303339", - "sig" : "5694a6f84b8f875c276afd2ebcfe4d61de9ec90305afb1357b95b3e0da43885e0dffad9ffd0b757d8051dec02ebdf70d8ee2dc5c7870c0823b6ccc7c679cbaa4", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 88, - "comment" : "special case hash", - "msg" : "33363130363732343432", - "sig" : "a0c30e8026fdb2b4b4968a27d16a6d08f7098f1a98d21620d7454ba9790f1ba65e470453a8a399f15baf463f9deceb53acc5ca64459149688bd2760c65424339", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 89, - "comment" : "special case hash", - "msg" : "31303534323430373035", - "sig" : "614ea84acf736527dd73602cd4bb4eea1dfebebd5ad8aca52aa0228cf7b99a88737cc85f5f2d2f60d1b8183f3ed490e4de14368e96a9482c2a4dd193195c902f", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 90, - "comment" : "special case hash", - "msg" : "35313734343438313937", - "sig" : "bead6734ebe44b810d3fb2ea00b1732945377338febfd439a8d74dfbd0f942fa6bb18eae36616a7d3cad35919fd21a8af4bbe7a10f73b3e036a46b103ef56e2a", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 91, - "comment" : "special case hash", - "msg" : "31393637353631323531", - "sig" : "499625479e161dacd4db9d9ce64854c98d922cbf212703e9654fae182df9bad242c177cf37b8193a0131108d97819edd9439936028864ac195b64fca76d9d693", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 92, - "comment" : "special case hash", - "msg" : "33343437323533333433", - "sig" : "08f16b8093a8fb4d66a2c8065b541b3d31e3bfe694f6b89c50fb1aaa6ff6c9b29d6455e2d5d1779748573b611cb95d4a21f967410399b39b535ba3e5af81ca2e", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 93, - "comment" : "special case hash", - "msg" : "333638323634333138", - "sig" : "be26231b6191658a19dd72ddb99ed8f8c579b6938d19bce8eed8dc2b338cb5f8e1d9a32ee56cffed37f0f22b2dcb57d5c943c14f79694a03b9c5e96952575c89", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 94, - "comment" : "special case hash", - "msg" : "33323631313938363038", - "sig" : "15e76880898316b16204ac920a02d58045f36a229d4aa4f812638c455abe0443e74d357d3fcb5c8c5337bd6aba4178b455ca10e226e13f9638196506a1939123", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 95, - "comment" : "special case hash", - "msg" : "39363738373831303934", - "sig" : "352ecb53f8df2c503a45f9846fc28d1d31e6307d3ddbffc1132315cc07f16dad1348dfa9c482c558e1d05c5242ca1c39436726ecd28258b1899792887dd0a3c6", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 96, - "comment" : "special case hash", - "msg" : "34393538383233383233", - "sig" : "4a40801a7e606ba78a0da9882ab23c7677b8642349ed3d652c5bfa5f2a9558fb3a49b64848d682ef7f605f2832f7384bdc24ed2925825bf8ea77dc5981725782", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 97, - "comment" : "special case hash", - "msg" : "383234363337383337", - "sig" : "eacc5e1a8304a74d2be412b078924b3bb3511bac855c05c9e5e9e44df3d61e967451cd8e18d6ed1885dd827714847f96ec4bb0ed4c36ce9808db8f714204f6d1", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 98, - "comment" : "special case hash", - "msg" : "3131303230383333373736", - "sig" : "2f7a5e9e5771d424f30f67fdab61e8ce4f8cd1214882adb65f7de94c31577052ac4e69808345809b44acb0b2bd889175fb75dd050c5a449ab9528f8f78daa10c", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 99, - "comment" : "special case hash", - "msg" : "313333383731363438", - "sig" : "ffcda40f792ce4d93e7e0f0e95e1a2147dddd7f6487621c30a03d710b330021979938b55f8a17f7ed7ba9ade8f2065a1fa77618f0b67add8d58c422c2453a49a", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 100, - "comment" : "special case hash", - "msg" : "333232313434313632", - "sig" : "81f2359c4faba6b53d3e8c8c3fcc16a948350f7ab3a588b28c17603a431e39a8cd6f6a5cc3b55ead0ff695d06c6860b509e46d99fccefb9f7f9e101857f74300", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 101, - "comment" : "special case hash", - "msg" : "3130363836363535353436", - "sig" : "dfc8bf520445cbb8ee1596fb073ea283ea130251a6fdffa5c3f5f2aaf75ca808048e33efce147c9dd92823640e338e68bfd7d0dc7a4905b3a7ac711e577e90e7", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 102, - "comment" : "special case hash", - "msg" : "3632313535323436", - "sig" : "ad019f74c6941d20efda70b46c53db166503a0e393e932f688227688ba6a576293320eb7ca0710255346bdbb3102cdcf7964ef2e0988e712bc05efe16c199345", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 103, - "comment" : "special case hash", - "msg" : "37303330383138373734", - "sig" : "ac8096842e8add68c34e78ce11dd71e4b54316bd3ebf7fffdeb7bd5a3ebc1883f5ca2f4f23d674502d4caf85d187215d36e3ce9f0ce219709f21a3aac003b7a8", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 104, - "comment" : "special case hash", - "msg" : "35393234353233373434", - "sig" : "677b2d3a59b18a5ff939b70ea002250889ddcd7b7b9d776854b4943693fb92f76b4ba856ade7677bf30307b21f3ccda35d2f63aee81efd0bab6972cc0795db55", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 105, - "comment" : "special case hash", - "msg" : "31343935353836363231", - "sig" : "479e1ded14bcaed0379ba8e1b73d3115d84d31d4b7c30e1f05e1fc0d5957cfb0918f79e35b3d89487cf634a4f05b2e0c30857ca879f97c771e877027355b2443", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 106, - "comment" : "special case hash", - "msg" : "34303035333134343036", - "sig" : "43dfccd0edb9e280d9a58f01164d55c3d711e14b12ac5cf3b64840ead512a0a31dbe33fa8ba84533cd5c4934365b3442ca1174899b78ef9a3199f49584389772", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 107, - "comment" : "special case hash", - "msg" : "33303936343537353132", - "sig" : "5b09ab637bd4caf0f4c7c7e4bca592fea20e9087c259d26a38bb4085f0bbff1145b7eb467b6748af618e9d80d6fdcd6aa24964e5a13f885bca8101de08eb0d75", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 108, - "comment" : "special case hash", - "msg" : "32373834303235363230", - "sig" : "5e9b1c5a028070df5728c5c8af9b74e0667afa570a6cfa0114a5039ed15ee06fb1360907e2d9785ead362bb8d7bd661b6c29eeffd3c5037744edaeb9ad990c20", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 109, - "comment" : "special case hash", - "msg" : "32363138373837343138", - "sig" : "0671a0a85c2b72d54a2fb0990e34538b4890050f5a5712f6d1a7a5fb8578f32edb1846bab6b7361479ab9c3285ca41291808f27fd5bd4fdac720e5854713694c", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 110, - "comment" : "special case hash", - "msg" : "31363432363235323632", - "sig" : "7673f8526748446477dbbb0590a45492c5d7d69859d301abbaedb35b2095103a3dc70ddf9c6b524d886bed9e6af02e0e4dec0d417a414fed3807ef4422913d7c", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 111, - "comment" : "special case hash", - "msg" : "36383234313839343336", - "sig" : "7f085441070ecd2bb21285089ebb1aa6450d1a06c36d3ff39dfd657a796d12b5249712012029870a2459d18d47da9aa492a5e6cb4b2d8dafa9e4c5c54a2b9a8b", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 112, - "comment" : "special case hash", - "msg" : "343834323435343235", - "sig" : "914c67fb61dd1e27c867398ea7322d5ab76df04bc5aa6683a8e0f30a5d287348fa07474031481dda4953e3ac1959ee8cea7e66ec412b38d6c96d28f6d37304ea", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "CtmVACiNRmlAAx1yqfVEWk1DeEZAhVvwpph00t5f4QM", - "y" : "xQEebvLELc1Q1dPSn5mubrosgMkkT0xUIvCXn_DDul4" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "040ad99500288d466940031d72a9f5445a4d43784640855bf0a69874d2de5fe103c5011e6ef2c42dcd50d5d3d29f99ae6eba2c80c9244f4c5422f0979ff0c3ba5e", - "wx" : "0ad99500288d466940031d72a9f5445a4d43784640855bf0a69874d2de5fe103", - "wy" : "00c5011e6ef2c42dcd50d5d3d29f99ae6eba2c80c9244f4c5422f0979ff0c3ba5e" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200040ad99500288d466940031d72a9f5445a4d43784640855bf0a69874d2de5fe103c5011e6ef2c42dcd50d5d3d29f99ae6eba2c80c9244f4c5422f0979ff0c3ba5e", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAECtmVACiNRmlAAx1yqfVEWk1DeEZA\nhVvwpph00t5f4QPFAR5u8sQtzVDV09Kfma5uuiyAySRPTFQi8Jef8MO6Xg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 113, - "comment" : "k*G has a large x-coordinate", - "msg" : "313233343030", - "sig" : "000000000000000000000000000000004319055358e8617b0c46353d039cdaabffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc63254e", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 114, - "comment" : "r too large", - "msg" : "313233343030", - "sig" : "ffffffff00000001000000000000000000000000fffffffffffffffffffffffcffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc63254e", - "result" : "invalid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "qwX9nQ3ia5zm9IGWUtn8aRk9CqOY8PuoAT4JxYIgRVQ", - "y" : "GSNScSKMeGdZCV0St1rwaS3UED8Z9qjDL0lDWh6bjUU" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04ab05fd9d0de26b9ce6f4819652d9fc69193d0aa398f0fba8013e09c58220455419235271228c786759095d12b75af0692dd4103f19f6a8c32f49435a1e9b8d45", - "wx" : "00ab05fd9d0de26b9ce6f4819652d9fc69193d0aa398f0fba8013e09c582204554", - "wy" : "19235271228c786759095d12b75af0692dd4103f19f6a8c32f49435a1e9b8d45" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004ab05fd9d0de26b9ce6f4819652d9fc69193d0aa398f0fba8013e09c58220455419235271228c786759095d12b75af0692dd4103f19f6a8c32f49435a1e9b8d45", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEqwX9nQ3ia5zm9IGWUtn8aRk9CqOY\n8PuoAT4JxYIgRVQZI1JxIox4Z1kJXRK3WvBpLdQQPxn2qMMvSUNaHpuNRQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 115, - "comment" : "r,s are large", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc63254fffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc63254e", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "gJhPOaH_OKhqaKpCAba-Xfv-z4diGXELB7rfb91MbFY", - "y" : "Ef65c5DZgm56Bt-0GHHJQNdEFe08rCCJ8URQGbtV7ZU" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "0480984f39a1ff38a86a68aa4201b6be5dfbfecf876219710b07badf6fdd4c6c5611feb97390d9826e7a06dfb41871c940d74415ed3cac2089f1445019bb55ed95", - "wx" : "0080984f39a1ff38a86a68aa4201b6be5dfbfecf876219710b07badf6fdd4c6c56", - "wy" : "11feb97390d9826e7a06dfb41871c940d74415ed3cac2089f1445019bb55ed95" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d0301070342000480984f39a1ff38a86a68aa4201b6be5dfbfecf876219710b07badf6fdd4c6c5611feb97390d9826e7a06dfb41871c940d74415ed3cac2089f1445019bb55ed95", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEgJhPOaH/OKhqaKpCAba+Xfv+z4di\nGXELB7rfb91MbFYR/rlzkNmCbnoG37QYcclA10QV7TysIInxRFAZu1XtlQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 116, - "comment" : "r and s^-1 have a large Hamming weight", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd909135bdb6799286170f5ead2de4f6511453fe50914f3df2de54a36383df8dd4", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "QgG0JylEIBwylPW6qaMjK23Wh0lfzBmnCpW8YCtPfAU", - "y" : "lcN-up7oFxwbtaxv6vdTvDb0Y-Ou8WYpVywMCo-wgA4" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "044201b4272944201c3294f5baa9a3232b6dd687495fcc19a70a95bc602b4f7c0595c37eba9ee8171c1bb5ac6feaf753bc36f463e3aef16629572c0c0a8fb0800e", - "wx" : "4201b4272944201c3294f5baa9a3232b6dd687495fcc19a70a95bc602b4f7c05", - "wy" : "0095c37eba9ee8171c1bb5ac6feaf753bc36f463e3aef16629572c0c0a8fb0800e" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200044201b4272944201c3294f5baa9a3232b6dd687495fcc19a70a95bc602b4f7c0595c37eba9ee8171c1bb5ac6feaf753bc36f463e3aef16629572c0c0a8fb0800e", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEQgG0JylEIBwylPW6qaMjK23Wh0lf\nzBmnCpW8YCtPfAWVw366nugXHBu1rG/q91O8NvRj467xZilXLAwKj7CADg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 117, - "comment" : "r and s^-1 have a large Hamming weight", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd27b4577ca009376f71303fd5dd227dcef5deb773ad5f5a84360644669ca249a5", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "pxr2TeUSakpOAreSLWbOlBXOiKTJ0lUU2RCCyHJayVc", - "y" : "XUdyPI--WAuzaf7JwmZdjjCkNbmTJkVILnyfEehyKWs" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04a71af64de5126a4a4e02b7922d66ce9415ce88a4c9d25514d91082c8725ac9575d47723c8fbe580bb369fec9c2665d8e30a435b9932645482e7c9f11e872296b", - "wx" : "00a71af64de5126a4a4e02b7922d66ce9415ce88a4c9d25514d91082c8725ac957", - "wy" : "5d47723c8fbe580bb369fec9c2665d8e30a435b9932645482e7c9f11e872296b" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004a71af64de5126a4a4e02b7922d66ce9415ce88a4c9d25514d91082c8725ac9575d47723c8fbe580bb369fec9c2665d8e30a435b9932645482e7c9f11e872296b", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEpxr2TeUSakpOAreSLWbOlBXOiKTJ\n0lUU2RCCyHJayVddR3I8j75YC7Np/snCZl2OMKQ1uZMmRUgufJ8R6HIpaw==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 118, - "comment" : "small r and s", - "msg" : "313233343030", - "sig" : "00000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000001", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 119, - "comment" : "incorrect size of signature", - "msg" : "313233343030", - "sig" : "0501", - "result" : "acceptable", - "flags" : [ - "SigSize" - ] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "ZifOxPBzHqI_wpMfkOvlt1cvWX0g3wj8KzHujvFrFXI", - "y" : "YXDtd9jQoU_FycPEyb5_DT7hj3CbsnXq8gc-JY_mlKU" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "046627cec4f0731ea23fc2931f90ebe5b7572f597d20df08fc2b31ee8ef16b15726170ed77d8d0a14fc5c9c3c4c9be7f0d3ee18f709bb275eaf2073e258fe694a5", - "wx" : "6627cec4f0731ea23fc2931f90ebe5b7572f597d20df08fc2b31ee8ef16b1572", - "wy" : "6170ed77d8d0a14fc5c9c3c4c9be7f0d3ee18f709bb275eaf2073e258fe694a5" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200046627cec4f0731ea23fc2931f90ebe5b7572f597d20df08fc2b31ee8ef16b15726170ed77d8d0a14fc5c9c3c4c9be7f0d3ee18f709bb275eaf2073e258fe694a5", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEZifOxPBzHqI/wpMfkOvlt1cvWX0g\n3wj8KzHujvFrFXJhcO132NChT8XJw8TJvn8NPuGPcJuyderyBz4lj+aUpQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 120, - "comment" : "small r and s", - "msg" : "313233343030", - "sig" : "00000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000003", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 121, - "comment" : "incorrect size of signature", - "msg" : "313233343030", - "sig" : "0503", - "result" : "acceptable", - "flags" : [ - "SigSize" - ] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "WnyIJehWkczh9edUTFTnPxSvwBDLcxNDJiyn7Fp39b8", - "y" : "727fYqRJfBvXsUf7bD0irzw5v86V8w4ToW09eygS-BM" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "045a7c8825e85691cce1f5e7544c54e73f14afc010cb731343262ca7ec5a77f5bfef6edf62a4497c1bd7b147fb6c3d22af3c39bfce95f30e13a16d3d7b2812f813", - "wx" : "5a7c8825e85691cce1f5e7544c54e73f14afc010cb731343262ca7ec5a77f5bf", - "wy" : "00ef6edf62a4497c1bd7b147fb6c3d22af3c39bfce95f30e13a16d3d7b2812f813" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200045a7c8825e85691cce1f5e7544c54e73f14afc010cb731343262ca7ec5a77f5bfef6edf62a4497c1bd7b147fb6c3d22af3c39bfce95f30e13a16d3d7b2812f813", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEWnyIJehWkczh9edUTFTnPxSvwBDL\ncxNDJiyn7Fp39b/vbt9ipEl8G9exR/tsPSKvPDm/zpXzDhOhbT17KBL4Ew==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 122, - "comment" : "small r and s", - "msg" : "313233343030", - "sig" : "00000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000005", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 123, - "comment" : "incorrect size of signature", - "msg" : "313233343030", - "sig" : "0505", - "result" : "acceptable", - "flags" : [ - "SigSize" - ] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "y-DCkTLNc4Nk_t1gMVKZDASOXi__mW2IP6bKynl4xzc", - "y" : "cK9qjORMtBIksmA2BvTATRiOgL_3zDGtUYnUqw1w6ME" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04cbe0c29132cd738364fedd603152990c048e5e2fff996d883fa6caca7978c73770af6a8ce44cb41224b2603606f4c04d188e80bff7cc31ad5189d4ab0d70e8c1", - "wx" : "00cbe0c29132cd738364fedd603152990c048e5e2fff996d883fa6caca7978c737", - "wy" : "70af6a8ce44cb41224b2603606f4c04d188e80bff7cc31ad5189d4ab0d70e8c1" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004cbe0c29132cd738364fedd603152990c048e5e2fff996d883fa6caca7978c73770af6a8ce44cb41224b2603606f4c04d188e80bff7cc31ad5189d4ab0d70e8c1", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEy+DCkTLNc4Nk/t1gMVKZDASOXi//\nmW2IP6bKynl4xzdwr2qM5Ey0EiSyYDYG9MBNGI6Av/fMMa1RidSrDXDowQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 124, - "comment" : "small r and s", - "msg" : "313233343030", - "sig" : "00000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000006", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 125, - "comment" : "incorrect size of signature", - "msg" : "313233343030", - "sig" : "0506", - "result" : "acceptable", - "flags" : [ - "SigSize" - ] - }, - { - "tcId" : 126, - "comment" : "r is larger than n", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc6325560000000000000000000000000000000000000000000000000000000000000006", - "result" : "invalid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "S-QXgJcALw3qto8NmhMODtM6Z5XQKiB5bbg0RLA34Tk", - "y" : "IPEwUeDuzc_OTazqD1DR8kfKpmnxk8G0B1tRriltLVY" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "044be4178097002f0deab68f0d9a130e0ed33a6795d02a20796db83444b037e13920f13051e0eecdcfce4dacea0f50d1f247caa669f193c1b4075b51ae296d2d56", - "wx" : "4be4178097002f0deab68f0d9a130e0ed33a6795d02a20796db83444b037e139", - "wy" : "20f13051e0eecdcfce4dacea0f50d1f247caa669f193c1b4075b51ae296d2d56" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200044be4178097002f0deab68f0d9a130e0ed33a6795d02a20796db83444b037e13920f13051e0eecdcfce4dacea0f50d1f247caa669f193c1b4075b51ae296d2d56", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAES+QXgJcALw3qto8NmhMODtM6Z5XQ\nKiB5bbg0RLA34Tkg8TBR4O7Nz85NrOoPUNHyR8qmafGTwbQHW1GuKW0tVg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 127, - "comment" : "s is larger than n", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000005ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc75fbd8", - "result" : "invalid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "0Pc3kiA3Fq_UvkMp-qSNJp8VMT67ujedd4PJe_PokNk", - "y" : "lx9KMgZgW-wheCv14nXHFEF-j1ZlSea8aGkNI2PInME" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04d0f73792203716afd4be4329faa48d269f15313ebbba379d7783c97bf3e890d9971f4a3206605bec21782bf5e275c714417e8f566549e6bc68690d2363c89cc1", - "wx" : "00d0f73792203716afd4be4329faa48d269f15313ebbba379d7783c97bf3e890d9", - "wy" : "00971f4a3206605bec21782bf5e275c714417e8f566549e6bc68690d2363c89cc1" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004d0f73792203716afd4be4329faa48d269f15313ebbba379d7783c97bf3e890d9971f4a3206605bec21782bf5e275c714417e8f566549e6bc68690d2363c89cc1", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE0Pc3kiA3Fq/UvkMp+qSNJp8VMT67\nujedd4PJe/PokNmXH0oyBmBb7CF4K/XidccUQX6PVmVJ5rxoaQ0jY8icwQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 128, - "comment" : "small r and s^-1", - "msg" : "313233343030", - "sig" : "00000000000000000000000000000000000000000000000000000000000001008f1e3c7862c58b16bb76eddbb76eddbb516af4f63f2d74d76e0d28c9bb75ea88", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "SDiyvjWmJ2qA754igUD52bls6Dt6JU9xzN67uAVM4F8", - "y" : "-py8EjyRmxngAjgZjQQGkEO9ZgqCiBQFH8uKrHOKbGs" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "044838b2be35a6276a80ef9e228140f9d9b96ce83b7a254f71ccdebbb8054ce05ffa9cbc123c919b19e00238198d04069043bd660a828814051fcb8aac738a6c6b", - "wx" : "4838b2be35a6276a80ef9e228140f9d9b96ce83b7a254f71ccdebbb8054ce05f", - "wy" : "00fa9cbc123c919b19e00238198d04069043bd660a828814051fcb8aac738a6c6b" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200044838b2be35a6276a80ef9e228140f9d9b96ce83b7a254f71ccdebbb8054ce05ffa9cbc123c919b19e00238198d04069043bd660a828814051fcb8aac738a6c6b", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAESDiyvjWmJ2qA754igUD52bls6Dt6\nJU9xzN67uAVM4F/6nLwSPJGbGeACOBmNBAaQQ71mCoKIFAUfy4qsc4psaw==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 129, - "comment" : "smallish r and s^-1", - "msg" : "313233343030", - "sig" : "000000000000000000000000000000000000000000000000002d9b4d347952d6ef3043e7329581dbb3974497710ab11505ee1c87ff907beebadd195a0ffe6d7a", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "c5OYPKMKUgu8R4PcmWB0aqtETvUgwKjncRGapOdLD2Q", - "y" : "6de-GrAaC_Ym5wmGPmpIbbrzJ5OvzPd04sbNJ7GFdSY" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "047393983ca30a520bbc4783dc9960746aab444ef520c0a8e771119aa4e74b0f64e9d7be1ab01a0bf626e709863e6a486dbaf32793afccf774e2c6cd27b1857526", - "wx" : "7393983ca30a520bbc4783dc9960746aab444ef520c0a8e771119aa4e74b0f64", - "wy" : "00e9d7be1ab01a0bf626e709863e6a486dbaf32793afccf774e2c6cd27b1857526" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200047393983ca30a520bbc4783dc9960746aab444ef520c0a8e771119aa4e74b0f64e9d7be1ab01a0bf626e709863e6a486dbaf32793afccf774e2c6cd27b1857526", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEc5OYPKMKUgu8R4PcmWB0aqtETvUg\nwKjncRGapOdLD2Tp174asBoL9ibnCYY+akhtuvMnk6/M93Tixs0nsYV1Jg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 130, - "comment" : "100-bit r and small s^-1", - "msg" : "313233343030", - "sig" : "000000000000000000000000000000000000001033e67e37b32b445580bf4eff8b748b74000000008b748b748b748b7466e769ad4a16d3dcd87129b8e91d1b4d", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "WsMxoRA_6WZpc3nzVqk381BYigVHfjCIUbilAtXfzcU", - "y" : "_pmT30tXk5srjaCVv215QmUgTP4DvplaAuZdQIyHHAs" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "045ac331a1103fe966697379f356a937f350588a05477e308851b8a502d5dfcdc5fe9993df4b57939b2b8da095bf6d794265204cfe03be995a02e65d408c871c0b", - "wx" : "5ac331a1103fe966697379f356a937f350588a05477e308851b8a502d5dfcdc5", - "wy" : "00fe9993df4b57939b2b8da095bf6d794265204cfe03be995a02e65d408c871c0b" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200045ac331a1103fe966697379f356a937f350588a05477e308851b8a502d5dfcdc5fe9993df4b57939b2b8da095bf6d794265204cfe03be995a02e65d408c871c0b", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEWsMxoRA/6WZpc3nzVqk381BYigVH\nfjCIUbilAtXfzcX+mZPfS1eTmyuNoJW/bXlCZSBM/gO+mVoC5l1AjIccCw==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 131, - "comment" : "small r and 100 bit s^-1", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000100ef9f6ba4d97c09d03178fa20b4aaad83be3cf9cb824a879fec3270fc4b81ef5b", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "HSCb6N4t6HcJWjmdOQTHTMRY2Sbie7jljl6uV2fEFQk", - "y" : "3VngTCFPexjc41H8KlSYk6aGDoAWPzjMYKTyydBA2Mk" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "041d209be8de2de877095a399d3904c74cc458d926e27bb8e58e5eae5767c41509dd59e04c214f7b18dce351fc2a549893a6860e80163f38cc60a4f2c9d040d8c9", - "wx" : "1d209be8de2de877095a399d3904c74cc458d926e27bb8e58e5eae5767c41509", - "wy" : "00dd59e04c214f7b18dce351fc2a549893a6860e80163f38cc60a4f2c9d040d8c9" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200041d209be8de2de877095a399d3904c74cc458d926e27bb8e58e5eae5767c41509dd59e04c214f7b18dce351fc2a549893a6860e80163f38cc60a4f2c9d040d8c9", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEHSCb6N4t6HcJWjmdOQTHTMRY2Sbi\ne7jljl6uV2fEFQndWeBMIU97GNzjUfwqVJiTpoYOgBY/OMxgpPLJ0EDYyQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 132, - "comment" : "100-bit r and s^-1", - "msg" : "313233343030", - "sig" : "00000000000000000000000000000000000000062522bbd3ecbe7c39e93e7c25ef9f6ba4d97c09d03178fa20b4aaad83be3cf9cb824a879fec3270fc4b81ef5b", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "CDU5--5EYl46yq-i_LQTSTks7wYzobj6vs7gwTOxDpk", - "y" : "kVwevnvwDfhTUZZ3ClgEeuKkAvJjJrt9QdTXYWM3kR4" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04083539fbee44625e3acaafa2fcb41349392cef0633a1b8fabecee0c133b10e99915c1ebe7bf00df8535196770a58047ae2a402f26326bb7d41d4d7616337911e", - "wx" : "083539fbee44625e3acaafa2fcb41349392cef0633a1b8fabecee0c133b10e99", - "wy" : "00915c1ebe7bf00df8535196770a58047ae2a402f26326bb7d41d4d7616337911e" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004083539fbee44625e3acaafa2fcb41349392cef0633a1b8fabecee0c133b10e99915c1ebe7bf00df8535196770a58047ae2a402f26326bb7d41d4d7616337911e", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAECDU5++5EYl46yq+i/LQTSTks7wYz\nobj6vs7gwTOxDpmRXB6+e/AN+FNRlncKWAR64qQC8mMmu31B1NdhYzeRHg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 133, - "comment" : "r and s^-1 are close to n", - "msg" : "313233343030", - "sig" : "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc6324d5555555550000000055555555555555553ef7a8e48d07df81a693439654210c70", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "ius2inAnpNZKveo3OQwMHWom85ni2XNN4es9Dhk3OHQ", - "y" : "Bb0Tg0cV4duum4dc8HvVXhtmkcf3U2rvOxm_ekrfV20" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "048aeb368a7027a4d64abdea37390c0c1d6a26f399e2d9734de1eb3d0e1937387405bd13834715e1dbae9b875cf07bd55e1b6691c7f7536aef3b19bf7a4adf576d", - "wx" : "008aeb368a7027a4d64abdea37390c0c1d6a26f399e2d9734de1eb3d0e19373874", - "wy" : "05bd13834715e1dbae9b875cf07bd55e1b6691c7f7536aef3b19bf7a4adf576d" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200048aeb368a7027a4d64abdea37390c0c1d6a26f399e2d9734de1eb3d0e1937387405bd13834715e1dbae9b875cf07bd55e1b6691c7f7536aef3b19bf7a4adf576d", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEius2inAnpNZKveo3OQwMHWom85ni\n2XNN4es9Dhk3OHQFvRODRxXh266bh1zwe9VeG2aRx/dTau87Gb96St9XbQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 134, - "comment" : "s == 1", - "msg" : "313233343030", - "sig" : "555555550000000055555555555555553ef7a8e48d07df81a693439654210c700000000000000000000000000000000000000000000000000000000000000001", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 135, - "comment" : "s == 0", - "msg" : "313233343030", - "sig" : "555555550000000055555555555555553ef7a8e48d07df81a693439654210c700000000000000000000000000000000000000000000000000000000000000000", - "result" : "invalid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "tTPUaV3VuMXgd1flXm5Rb34siPoCOeI_YOjsB91w8oc", - "y" : "GxNO5YzFgyeEVoY_M8OoXYgffUo5hQFD4p1OrwCa_kc" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04b533d4695dd5b8c5e07757e55e6e516f7e2c88fa0239e23f60e8ec07dd70f2871b134ee58cc583278456863f33c3a85d881f7d4a39850143e29d4eaf009afe47", - "wx" : "00b533d4695dd5b8c5e07757e55e6e516f7e2c88fa0239e23f60e8ec07dd70f287", - "wy" : "1b134ee58cc583278456863f33c3a85d881f7d4a39850143e29d4eaf009afe47" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004b533d4695dd5b8c5e07757e55e6e516f7e2c88fa0239e23f60e8ec07dd70f2871b134ee58cc583278456863f33c3a85d881f7d4a39850143e29d4eaf009afe47", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEtTPUaV3VuMXgd1flXm5Rb34siPoC\nOeI/YOjsB91w8ocbE07ljMWDJ4RWhj8zw6hdiB99SjmFAUPinU6vAJr+Rw==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 136, - "comment" : "point at infinity during verify", - "msg" : "313233343030", - "sig" : "7fffffff800000007fffffffffffffffde737d56d38bcf4279dce5617e3192a8555555550000000055555555555555553ef7a8e48d07df81a693439654210c70", - "result" : "invalid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "9Q03G5G_sdfRThMjUjvDqoy_LFf54oTeYoyLRTZ4e4Y", - "y" : "-UrYh6yU1SckfNLn0MixKRxVPJcwQFOAsUy7IJ9fot0" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04f50d371b91bfb1d7d14e1323523bc3aa8cbf2c57f9e284de628c8b4536787b86f94ad887ac94d527247cd2e7d0c8b1291c553c9730405380b14cbb209f5fa2dd", - "wx" : "00f50d371b91bfb1d7d14e1323523bc3aa8cbf2c57f9e284de628c8b4536787b86", - "wy" : "00f94ad887ac94d527247cd2e7d0c8b1291c553c9730405380b14cbb209f5fa2dd" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004f50d371b91bfb1d7d14e1323523bc3aa8cbf2c57f9e284de628c8b4536787b86f94ad887ac94d527247cd2e7d0c8b1291c553c9730405380b14cbb209f5fa2dd", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE9Q03G5G/sdfRThMjUjvDqoy/LFf5\n4oTeYoyLRTZ4e4b5StiHrJTVJyR80ufQyLEpHFU8lzBAU4CxTLsgn1+i3Q==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 137, - "comment" : "edge case for signature malleability", - "msg" : "313233343030", - "sig" : "7fffffff800000007fffffffffffffffde737d56d38bcf4279dce5617e3192a97fffffff800000007fffffffffffffffde737d56d38bcf4279dce5617e3192a8", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "aOxuKY6v4WU5FWzlehSwSnBHwiG6_DpYLq6w2FfE2UY", - "y" : "l77RrxeFARf9s5sjJPIgpWmO0WxCaiczW7OFrIym-zA" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "0468ec6e298eafe16539156ce57a14b04a7047c221bafc3a582eaeb0d857c4d94697bed1af17850117fdb39b2324f220a5698ed16c426a27335bb385ac8ca6fb30", - "wx" : "68ec6e298eafe16539156ce57a14b04a7047c221bafc3a582eaeb0d857c4d946", - "wy" : "0097bed1af17850117fdb39b2324f220a5698ed16c426a27335bb385ac8ca6fb30" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d0301070342000468ec6e298eafe16539156ce57a14b04a7047c221bafc3a582eaeb0d857c4d94697bed1af17850117fdb39b2324f220a5698ed16c426a27335bb385ac8ca6fb30", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEaOxuKY6v4WU5FWzlehSwSnBHwiG6\n/DpYLq6w2FfE2UaXvtGvF4UBF/2zmyMk8iClaY7RbEJqJzNbs4WsjKb7MA==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 138, - "comment" : "edge case for signature malleability", - "msg" : "313233343030", - "sig" : "7fffffff800000007fffffffffffffffde737d56d38bcf4279dce5617e3192a97fffffff800000007fffffffffffffffde737d56d38bcf4279dce5617e3192a9", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "adoDZHNNLlMP7OlAGSZf77eBoPGwj2yIl732VXknyLg", - "y" : "ZtLTx9zVGLI9cmlg8Gmtcakz2G74q7zOiyD3HiqEcAI" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "0469da0364734d2e530fece94019265fefb781a0f1b08f6c8897bdf6557927c8b866d2d3c7dcd518b23d726960f069ad71a933d86ef8abbcce8b20f71e2a847002", - "wx" : "69da0364734d2e530fece94019265fefb781a0f1b08f6c8897bdf6557927c8b8", - "wy" : "66d2d3c7dcd518b23d726960f069ad71a933d86ef8abbcce8b20f71e2a847002" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d0301070342000469da0364734d2e530fece94019265fefb781a0f1b08f6c8897bdf6557927c8b866d2d3c7dcd518b23d726960f069ad71a933d86ef8abbcce8b20f71e2a847002", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEadoDZHNNLlMP7OlAGSZf77eBoPGw\nj2yIl732VXknyLhm0tPH3NUYsj1yaWDwaa1xqTPYbvirvM6LIPceKoRwAg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 139, - "comment" : "u1 == 1", - "msg" : "313233343030", - "sig" : "555555550000000055555555555555553ef7a8e48d07df81a693439654210c70bb5a52f42f9c9261ed4361f59422a1e30036e7c32b270c8807a419feca605023", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "2K3AACOo7cAlduK2Pj4wYhpHHisjIGIBh78GehrB_zI", - "y" : "M-K1DsCYB6zLNhMf_5XtEqCahrTqlpCqMoYVdrojYuE" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04d8adc00023a8edc02576e2b63e3e30621a471e2b2320620187bf067a1ac1ff3233e2b50ec09807accb36131fff95ed12a09a86b4ea9690aa32861576ba2362e1", - "wx" : "00d8adc00023a8edc02576e2b63e3e30621a471e2b2320620187bf067a1ac1ff32", - "wy" : "33e2b50ec09807accb36131fff95ed12a09a86b4ea9690aa32861576ba2362e1" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004d8adc00023a8edc02576e2b63e3e30621a471e2b2320620187bf067a1ac1ff3233e2b50ec09807accb36131fff95ed12a09a86b4ea9690aa32861576ba2362e1", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE2K3AACOo7cAlduK2Pj4wYhpHHisj\nIGIBh78GehrB/zIz4rUOwJgHrMs2Ex//le0SoJqGtOqWkKoyhhV2uiNi4Q==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 140, - "comment" : "u1 == n - 1", - "msg" : "313233343030", - "sig" : "555555550000000055555555555555553ef7a8e48d07df81a693439654210c7044a5ad0ad0636d9f12bc9e0a6bdd5e1cbcb012ea7bf091fcec15b0c43202d52e", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "NiOslzztClb6bYgvA6fVx-3KAs_HskAfqzaQ2-dat4U", - "y" : "jbBpCOZLKGE9pyV-c385eT2o5xO6BkO5LpuzJSvn-P4" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "043623ac973ced0a56fa6d882f03a7d5c7edca02cfc7b2401fab3690dbe75ab7858db06908e64b28613da7257e737f39793da8e713ba0643b92e9bb3252be7f8fe", - "wx" : "3623ac973ced0a56fa6d882f03a7d5c7edca02cfc7b2401fab3690dbe75ab785", - "wy" : "008db06908e64b28613da7257e737f39793da8e713ba0643b92e9bb3252be7f8fe" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200043623ac973ced0a56fa6d882f03a7d5c7edca02cfc7b2401fab3690dbe75ab7858db06908e64b28613da7257e737f39793da8e713ba0643b92e9bb3252be7f8fe", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAENiOslzztClb6bYgvA6fVx+3KAs/H\nskAfqzaQ2+dat4WNsGkI5ksoYT2nJX5zfzl5PajnE7oGQ7kum7MlK+f4/g==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 141, - "comment" : "u2 == 1", - "msg" : "313233343030", - "sig" : "555555550000000055555555555555553ef7a8e48d07df81a693439654210c70555555550000000055555555555555553ef7a8e48d07df81a693439654210c70", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "zwTqd-liJSPYlLk_9S3DAnsxlZUDtvo4kOXgQmP5IvE", - "y" : "6FKPt8AGs5g8i4QA5XtO1xdAwvOXVDiCEZm-3q7Ksuk" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04cf04ea77e9622523d894b93ff52dc3027b31959503b6fa3890e5e04263f922f1e8528fb7c006b3983c8b8400e57b4ed71740c2f3975438821199bedeaecab2e9", - "wx" : "00cf04ea77e9622523d894b93ff52dc3027b31959503b6fa3890e5e04263f922f1", - "wy" : "00e8528fb7c006b3983c8b8400e57b4ed71740c2f3975438821199bedeaecab2e9" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004cf04ea77e9622523d894b93ff52dc3027b31959503b6fa3890e5e04263f922f1e8528fb7c006b3983c8b8400e57b4ed71740c2f3975438821199bedeaecab2e9", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEzwTqd+liJSPYlLk/9S3DAnsxlZUD\ntvo4kOXgQmP5IvHoUo+3wAazmDyLhADle07XF0DC85dUOIIRmb7ersqy6Q==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 142, - "comment" : "u2 == n - 1", - "msg" : "313233343030", - "sig" : "555555550000000055555555555555553ef7a8e48d07df81a693439654210c70aaaaaaaa00000000aaaaaaaaaaaaaaaa7def51c91a0fbf034d26872ca84218e1", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "23osihq1c-WSncJAd7UI1-aD1JInmWvaPp942-_3c1A", - "y" : "T0F_O8mogHXC4KrdWhMxFzDPfMdqgvEaNurwimyZogY" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04db7a2c8a1ab573e5929dc24077b508d7e683d49227996bda3e9f78dbeff773504f417f3bc9a88075c2e0aadd5a13311730cf7cc76a82f11a36eaf08a6c99a206", - "wx" : "00db7a2c8a1ab573e5929dc24077b508d7e683d49227996bda3e9f78dbeff77350", - "wy" : "4f417f3bc9a88075c2e0aadd5a13311730cf7cc76a82f11a36eaf08a6c99a206" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004db7a2c8a1ab573e5929dc24077b508d7e683d49227996bda3e9f78dbeff773504f417f3bc9a88075c2e0aadd5a13311730cf7cc76a82f11a36eaf08a6c99a206", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE23osihq1c+WSncJAd7UI1+aD1JIn\nmWvaPp942+/3c1BPQX87yaiAdcLgqt1aEzEXMM98x2qC8Ro26vCKbJmiBg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 143, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffde91e1ba60fdedb76a46bcb51dc0b8b4b7e019f0a28721885fa5d3a8196623397", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "3q0Rx6WzloYvIZdNxHUvre_5lO_pu9BatBN2XqgLbh8", - "y" : "HePwZA6Kxu3Pic_1PEDiZbuUB4o0NzbfB6oDGPx_4f8" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04dead11c7a5b396862f21974dc4752fadeff994efe9bbd05ab413765ea80b6e1f1de3f0640e8ac6edcf89cff53c40e265bb94078a343736df07aa0318fc7fe1ff", - "wx" : "00dead11c7a5b396862f21974dc4752fadeff994efe9bbd05ab413765ea80b6e1f", - "wy" : "1de3f0640e8ac6edcf89cff53c40e265bb94078a343736df07aa0318fc7fe1ff" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004dead11c7a5b396862f21974dc4752fadeff994efe9bbd05ab413765ea80b6e1f1de3f0640e8ac6edcf89cff53c40e265bb94078a343736df07aa0318fc7fe1ff", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE3q0Rx6WzloYvIZdNxHUvre/5lO/p\nu9BatBN2XqgLbh8d4/BkDorG7c+Jz/U8QOJlu5QHijQ3Nt8HqgMY/H/h/w==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 144, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdfdea5843ffeb73af94313ba4831b53fe24f799e525b1e8e8c87b59b95b430ad9", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "0LxHLg18geuu06bvlsGGE7sf6m-ZQyb76A4A395nx-k", - "y" : "mGxyPqSEPUg4m5RvZK1WyDrXD_F7qFM1Zn0bufphnv0" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04d0bc472e0d7c81ebaed3a6ef96c18613bb1fea6f994326fbe80e00dfde67c7e9986c723ea4843d48389b946f64ad56c83ad70ff17ba85335667d1bb9fa619efd", - "wx" : "00d0bc472e0d7c81ebaed3a6ef96c18613bb1fea6f994326fbe80e00dfde67c7e9", - "wy" : "00986c723ea4843d48389b946f64ad56c83ad70ff17ba85335667d1bb9fa619efd" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004d0bc472e0d7c81ebaed3a6ef96c18613bb1fea6f994326fbe80e00dfde67c7e9986c723ea4843d48389b946f64ad56c83ad70ff17ba85335667d1bb9fa619efd", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE0LxHLg18geuu06bvlsGGE7sf6m+Z\nQyb76A4A395nx+mYbHI+pIQ9SDiblG9krVbIOtcP8XuoUzVmfRu5+mGe/Q==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 145, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd03ffcabf2f1b4d2a65190db1680d62bb994e41c5251cd73b3c3dfc5e5bafc035", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "oKRMqUfWairLc2AIucCNGrKtA3duAmQPeEldRY3VHDI", - "y" : "Yzf-XPjEYEsfHECdwthy1ClKR2JCDfQ6MKI5LkBCat0" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04a0a44ca947d66a2acb736008b9c08d1ab2ad03776e02640f78495d458dd51c326337fe5cf8c4604b1f1c409dc2d872d4294a4762420df43a30a2392e40426add", - "wx" : "00a0a44ca947d66a2acb736008b9c08d1ab2ad03776e02640f78495d458dd51c32", - "wy" : "6337fe5cf8c4604b1f1c409dc2d872d4294a4762420df43a30a2392e40426add" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004a0a44ca947d66a2acb736008b9c08d1ab2ad03776e02640f78495d458dd51c326337fe5cf8c4604b1f1c409dc2d872d4294a4762420df43a30a2392e40426add", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEoKRMqUfWairLc2AIucCNGrKtA3du\nAmQPeEldRY3VHDJjN/5c+MRgSx8cQJ3C2HLUKUpHYkIN9DowojkuQEJq3Q==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 146, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd4dfbc401f971cd304b33dfdb17d0fed0fe4c1a88ae648e0d2847f74977534989", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "ycIRUpDQCLRftl-tD2AjiSmMJUILd1AZ1Ctiw86Klrc", - "y" : "OHfSWoCA3ALZh8pzDwQFwsnb76xG-eYBzD8G6XE5c_0" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04c9c2115290d008b45fb65fad0f602389298c25420b775019d42b62c3ce8a96b73877d25a8080dc02d987ca730f0405c2c9dbefac46f9e601cc3f06e9713973fd", - "wx" : "00c9c2115290d008b45fb65fad0f602389298c25420b775019d42b62c3ce8a96b7", - "wy" : "3877d25a8080dc02d987ca730f0405c2c9dbefac46f9e601cc3f06e9713973fd" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004c9c2115290d008b45fb65fad0f602389298c25420b775019d42b62c3ce8a96b73877d25a8080dc02d987ca730f0405c2c9dbefac46f9e601cc3f06e9713973fd", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEycIRUpDQCLRftl+tD2AjiSmMJUIL\nd1AZ1Ctiw86Klrc4d9JagIDcAtmHynMPBAXCydvvrEb55gHMPwbpcTlz/Q==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 147, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdbc4024761cd2ffd43dfdb17d0fed112b988977055cd3a8e54971eba9cda5ca71", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "Xsoe9MKH3dxmuLzPG4jookwAGJYvPF5--oO8Gl_2Az4", - "y" : "XnnEyywkW4xFq9zoqOTadY2SpgfDLNQH7K7yLxyTSnE" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "045eca1ef4c287dddc66b8bccf1b88e8a24c0018962f3c5e7efa83bc1a5ff6033e5e79c4cb2c245b8c45abdce8a8e4da758d92a607c32cd407ecaef22f1c934a71", - "wx" : "5eca1ef4c287dddc66b8bccf1b88e8a24c0018962f3c5e7efa83bc1a5ff6033e", - "wy" : "5e79c4cb2c245b8c45abdce8a8e4da758d92a607c32cd407ecaef22f1c934a71" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200045eca1ef4c287dddc66b8bccf1b88e8a24c0018962f3c5e7efa83bc1a5ff6033e5e79c4cb2c245b8c45abdce8a8e4da758d92a607c32cd407ecaef22f1c934a71", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEXsoe9MKH3dxmuLzPG4jookwAGJYv\nPF5++oO8Gl/2Az5eecTLLCRbjEWr3Oio5Np1jZKmB8Ms1AfsrvIvHJNKcQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 148, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd788048ed39a5ffa77bfb62fa1fda2257742bf35d128fb3459f2a0c909ee86f91", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "XKqgMOf98OSTa8erWpY1PgoB5BMMP4vyLUc-MXAppHo", - "y" : "3ratxGL3BY8qINNx6XAiVOmyAWQgBbPO2pJrQrF4vvk" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "045caaa030e7fdf0e4936bc7ab5a96353e0a01e4130c3f8bf22d473e317029a47adeb6adc462f7058f2a20d371e9702254e9b201642005b3ceda926b42b178bef9", - "wx" : "5caaa030e7fdf0e4936bc7ab5a96353e0a01e4130c3f8bf22d473e317029a47a", - "wy" : "00deb6adc462f7058f2a20d371e9702254e9b201642005b3ceda926b42b178bef9" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200045caaa030e7fdf0e4936bc7ab5a96353e0a01e4130c3f8bf22d473e317029a47adeb6adc462f7058f2a20d371e9702254e9b201642005b3ceda926b42b178bef9", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEXKqgMOf98OSTa8erWpY1PgoB5BMM\nP4vyLUc+MXAppHretq3EYvcFjyog03HpcCJU6bIBZCAFs87akmtCsXi++Q==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 149, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd476d9131fd381bd917d0fed112bc9e0a5924b5ed5b11167edd8b23582b3cb15e", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "wv0gusBuVVu4rAzmnrHqIPg6H8NQHIpmRpsaMfYZsJg", - "y" : "YjcFB3n1K2Fb17jXaiX8lcou0yUlx18n_8h6w5fmy68" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04c2fd20bac06e555bb8ac0ce69eb1ea20f83a1fc3501c8a66469b1a31f619b0986237050779f52b615bd7b8d76a25fc95ca2ed32525c75f27ffc87ac397e6cbaf", - "wx" : "00c2fd20bac06e555bb8ac0ce69eb1ea20f83a1fc3501c8a66469b1a31f619b098", - "wy" : "6237050779f52b615bd7b8d76a25fc95ca2ed32525c75f27ffc87ac397e6cbaf" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004c2fd20bac06e555bb8ac0ce69eb1ea20f83a1fc3501c8a66469b1a31f619b0986237050779f52b615bd7b8d76a25fc95ca2ed32525c75f27ffc87ac397e6cbaf", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEwv0gusBuVVu4rAzmnrHqIPg6H8NQ\nHIpmRpsaMfYZsJhiNwUHefUrYVvXuNdqJfyVyi7TJSXHXyf/yHrDl+bLrw==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 150, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd8374253e3e21bd154448d0a8f640fe46fafa8b19ce78d538f6cc0a19662d3601", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "P9ahyn93-zsLvnJsNyAQBoQm4R6mrnjOF77a5LuobO0", - "y" : "A85VFkBr-M-quHRerBzWkBitb1C1Rhhy3fxW4Ns8j_Q" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "043fd6a1ca7f77fb3b0bbe726c372010068426e11ea6ae78ce17bedae4bba86ced03ce5516406bf8cfaab8745eac1cd69018ad6f50b5461872ddfc56e0db3c8ff4", - "wx" : "3fd6a1ca7f77fb3b0bbe726c372010068426e11ea6ae78ce17bedae4bba86ced", - "wy" : "03ce5516406bf8cfaab8745eac1cd69018ad6f50b5461872ddfc56e0db3c8ff4" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200043fd6a1ca7f77fb3b0bbe726c372010068426e11ea6ae78ce17bedae4bba86ced03ce5516406bf8cfaab8745eac1cd69018ad6f50b5461872ddfc56e0db3c8ff4", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEP9ahyn93+zsLvnJsNyAQBoQm4R6m\nrnjOF77a5LuobO0DzlUWQGv4z6q4dF6sHNaQGK1vULVGGHLd/Fbg2zyP9A==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 151, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd357cfd3be4d01d413c5b9ede36cba5452c11ee7fe14879e749ae6a2d897a52d6", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "nLjlHielrjtiSmDW3DJzTkmJ2yDpvKPt4e33sIaRERQ", - "y" : "tMEEqzxnfks21lVuitX1I0EKGfLid6qJX8VzIrRCdUQ" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "049cb8e51e27a5ae3b624a60d6dc32734e4989db20e9bca3ede1edf7b086911114b4c104ab3c677e4b36d6556e8ad5f523410a19f2e277aa895fc57322b4427544", - "wx" : "009cb8e51e27a5ae3b624a60d6dc32734e4989db20e9bca3ede1edf7b086911114", - "wy" : "00b4c104ab3c677e4b36d6556e8ad5f523410a19f2e277aa895fc57322b4427544" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200049cb8e51e27a5ae3b624a60d6dc32734e4989db20e9bca3ede1edf7b086911114b4c104ab3c677e4b36d6556e8ad5f523410a19f2e277aa895fc57322b4427544", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEnLjlHielrjtiSmDW3DJzTkmJ2yDp\nvKPt4e33sIaRERS0wQSrPGd+SzbWVW6K1fUjQQoZ8uJ3qolfxXMitEJ1RA==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 152, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd29798c5c0ee287d4a5e8e6b799fd86b8df5225298e6ffc807cd2f2bc27a0a6d8", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "o-UsFW3K8QUCYgt5VbwrQLx47z1WnhIjwmJRLY9JYCo", - "y" : "SiA58xwQlwJK08yG5XMh3gMjVUY0hhZM8ZKUSXffFH8" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04a3e52c156dcaf10502620b7955bc2b40bc78ef3d569e1223c262512d8f49602a4a2039f31c1097024ad3cc86e57321de032355463486164cf192944977df147f", - "wx" : "00a3e52c156dcaf10502620b7955bc2b40bc78ef3d569e1223c262512d8f49602a", - "wy" : "4a2039f31c1097024ad3cc86e57321de032355463486164cf192944977df147f" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004a3e52c156dcaf10502620b7955bc2b40bc78ef3d569e1223c262512d8f49602a4a2039f31c1097024ad3cc86e57321de032355463486164cf192944977df147f", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEo+UsFW3K8QUCYgt5VbwrQLx47z1W\nnhIjwmJRLY9JYCpKIDnzHBCXAkrTzIblcyHeAyNVRjSGFkzxkpRJd98Ufw==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 153, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd0b70f22c781092452dca1a5711fa3a5a1f72add1bf52c2ff7cae4820b30078dd", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "8Zt4kocg1b7o5nD7kAEPsVw3v5G1ilFXw_PAWbJlXog", - "y" : "z3AeyWL7ShHc8nP13DV-WEaFYMfP65QtB0q9QykmBQk" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04f19b78928720d5bee8e670fb90010fb15c37bf91b58a5157c3f3c059b2655e88cf701ec962fb4a11dcf273f5dc357e58468560c7cfeb942d074abd4329260509", - "wx" : "00f19b78928720d5bee8e670fb90010fb15c37bf91b58a5157c3f3c059b2655e88", - "wy" : "00cf701ec962fb4a11dcf273f5dc357e58468560c7cfeb942d074abd4329260509" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004f19b78928720d5bee8e670fb90010fb15c37bf91b58a5157c3f3c059b2655e88cf701ec962fb4a11dcf273f5dc357e58468560c7cfeb942d074abd4329260509", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE8Zt4kocg1b7o5nD7kAEPsVw3v5G1\nilFXw/PAWbJlXojPcB7JYvtKEdzyc/XcNX5YRoVgx8/rlC0HSr1DKSYFCQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 154, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd16e1e458f021248a5b9434ae23f474b43ee55ba37ea585fef95c90416600f1ba", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "g6dERZ7N-wGlz1KyegW7czdILSQvI117TLiTRVRckKg", - "y" : "wF1JM3uWSYEyh96f_pA1X9kF3188MpRYKBIfN8xQ3m4" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "0483a744459ecdfb01a5cf52b27a05bb7337482d242f235d7b4cb89345545c90a8c05d49337b9649813287de9ffe90355fd905df5f3c32945828121f37cc50de6e", - "wx" : "0083a744459ecdfb01a5cf52b27a05bb7337482d242f235d7b4cb89345545c90a8", - "wy" : "00c05d49337b9649813287de9ffe90355fd905df5f3c32945828121f37cc50de6e" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d0301070342000483a744459ecdfb01a5cf52b27a05bb7337482d242f235d7b4cb89345545c90a8c05d49337b9649813287de9ffe90355fd905df5f3c32945828121f37cc50de6e", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEg6dERZ7N+wGlz1KyegW7czdILSQv\nI117TLiTRVRckKjAXUkze5ZJgTKH3p/+kDVf2QXfXzwylFgoEh83zFDebg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 155, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd2252d6856831b6cf895e4f0535eeaf0e5e5809753df848fe760ad86219016a97", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "3RPGs0xWmC3a4STwOd_SP0sZu-iM7o5SiuUeXW86Idc", - "y" : "v61MLm8mP-XrWcqXTQOfwOTDNFaS-1Mgva5L07QqRf8" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04dd13c6b34c56982ddae124f039dfd23f4b19bbe88cee8e528ae51e5d6f3a21d7bfad4c2e6f263fe5eb59ca974d039fc0e4c3345692fb5320bdae4bd3b42a45ff", - "wx" : "00dd13c6b34c56982ddae124f039dfd23f4b19bbe88cee8e528ae51e5d6f3a21d7", - "wy" : "00bfad4c2e6f263fe5eb59ca974d039fc0e4c3345692fb5320bdae4bd3b42a45ff" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004dd13c6b34c56982ddae124f039dfd23f4b19bbe88cee8e528ae51e5d6f3a21d7bfad4c2e6f263fe5eb59ca974d039fc0e4c3345692fb5320bdae4bd3b42a45ff", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE3RPGs0xWmC3a4STwOd/SP0sZu+iM\n7o5SiuUeXW86Ide/rUwubyY/5etZypdNA5/A5MM0VpL7UyC9rkvTtCpF/w==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 156, - "comment" : "edge case for u1", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd81ffe55f178da695b28c86d8b406b15dab1a9e39661a3ae017fbe390ac0972c3", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "Z-b2Wc3ehpovZfCU6U5bTfrWNrv5UZL-7tAbDz3rdGA", - "y" : "o34KUfJYt661Hf5ZL1z9VoW75YcSyNkjPGKIZDfDi6A" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "0467e6f659cdde869a2f65f094e94e5b4dfad636bbf95192feeed01b0f3deb7460a37e0a51f258b7aeb51dfe592f5cfd5685bbe58712c8d9233c62886437c38ba0", - "wx" : "67e6f659cdde869a2f65f094e94e5b4dfad636bbf95192feeed01b0f3deb7460", - "wy" : "00a37e0a51f258b7aeb51dfe592f5cfd5685bbe58712c8d9233c62886437c38ba0" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d0301070342000467e6f659cdde869a2f65f094e94e5b4dfad636bbf95192feeed01b0f3deb7460a37e0a51f258b7aeb51dfe592f5cfd5685bbe58712c8d9233c62886437c38ba0", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEZ+b2Wc3ehpovZfCU6U5bTfrWNrv5\nUZL+7tAbDz3rdGCjfgpR8li3rrUd/lkvXP1WhbvlhxLI2SM8YohkN8OLoA==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 157, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd7fffffffaaaaaaaaffffffffffffffffe9a2538f37b28a2c513dee40fecbb71a", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "LrZBJQWuwFxlRfApkyCH5JDQVRHo7B9Zlhe7Nn-eyq8", - "y" : "gF9R78xIA0A_mxrgEkiQ8GpD_tzdsxgw9maa8pKJXLA" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "042eb6412505aec05c6545f029932087e490d05511e8ec1f599617bb367f9ecaaf805f51efcc4803403f9b1ae0124890f06a43fedcddb31830f6669af292895cb0", - "wx" : "2eb6412505aec05c6545f029932087e490d05511e8ec1f599617bb367f9ecaaf", - "wy" : "00805f51efcc4803403f9b1ae0124890f06a43fedcddb31830f6669af292895cb0" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200042eb6412505aec05c6545f029932087e490d05511e8ec1f599617bb367f9ecaaf805f51efcc4803403f9b1ae0124890f06a43fedcddb31830f6669af292895cb0", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAELrZBJQWuwFxlRfApkyCH5JDQVRHo\n7B9Zlhe7Nn+eyq+AX1HvzEgDQD+bGuASSJDwakP+3N2zGDD2ZprykolcsA==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 158, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdb62f26b5f2a2b26f6de86d42ad8a13da3ab3cccd0459b201de009e526adf21f2", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "hNtkWGjqs146n9gOBW4uhVQ146a2jXWlCoVGJf4NfzU", - "y" : "bSWJrGVe3JoR7z4HXt3amr-S5yFxVw73v0Oi7jkzjP4" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "0484db645868eab35e3a9fd80e056e2e855435e3a6b68d75a50a854625fe0d7f356d2589ac655edc9a11ef3e075eddda9abf92e72171570ef7bf43a2ee39338cfe", - "wx" : "0084db645868eab35e3a9fd80e056e2e855435e3a6b68d75a50a854625fe0d7f35", - "wy" : "6d2589ac655edc9a11ef3e075eddda9abf92e72171570ef7bf43a2ee39338cfe" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d0301070342000484db645868eab35e3a9fd80e056e2e855435e3a6b68d75a50a854625fe0d7f356d2589ac655edc9a11ef3e075eddda9abf92e72171570ef7bf43a2ee39338cfe", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEhNtkWGjqs146n9gOBW4uhVQ146a2\njXWlCoVGJf4NfzVtJYmsZV7cmhHvPgde3dqav5LnIXFXDve/Q6LuOTOM/g==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 159, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdbb1d9ac949dd748cd02bbbe749bd351cd57b38bb61403d700686aa7b4c90851e", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "kbnkfFYnhmLXXAmDsiyo6mqlBZt6L_djfrKXXjhq1mM", - "y" : "SaqP8oPQ93wY1tEdwGIWX9E8PAMQZ5wUCDAqFoVOz70" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "0491b9e47c56278662d75c0983b22ca8ea6aa5059b7a2ff7637eb2975e386ad66349aa8ff283d0f77c18d6d11dc062165fd13c3c0310679c1408302a16854ecfbd", - "wx" : "0091b9e47c56278662d75c0983b22ca8ea6aa5059b7a2ff7637eb2975e386ad663", - "wy" : "49aa8ff283d0f77c18d6d11dc062165fd13c3c0310679c1408302a16854ecfbd" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d0301070342000491b9e47c56278662d75c0983b22ca8ea6aa5059b7a2ff7637eb2975e386ad66349aa8ff283d0f77c18d6d11dc062165fd13c3c0310679c1408302a16854ecfbd", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEkbnkfFYnhmLXXAmDsiyo6mqlBZt6\nL/djfrKXXjhq1mNJqo/yg9D3fBjW0R3AYhZf0Tw8AxBnnBQIMCoWhU7PvQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 160, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd66755a00638cdaec1c732513ca0234ece52545dac11f816e818f725b4f60aaf2", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "8-wvE8rwTQGStH-0xTEfttTcawqegC5TJ_fsXujkg00", - "y" : "-X4-Rot9Dbhn1uz-geKw-VMd-H79tHwTOKwyH-_lpDI" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04f3ec2f13caf04d0192b47fb4c5311fb6d4dc6b0a9e802e5327f7ec5ee8e4834df97e3e468b7d0db867d6ecfe81e2b0f9531df87efdb47c1338ac321fefe5a432", - "wx" : "00f3ec2f13caf04d0192b47fb4c5311fb6d4dc6b0a9e802e5327f7ec5ee8e4834d", - "wy" : "00f97e3e468b7d0db867d6ecfe81e2b0f9531df87efdb47c1338ac321fefe5a432" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004f3ec2f13caf04d0192b47fb4c5311fb6d4dc6b0a9e802e5327f7ec5ee8e4834df97e3e468b7d0db867d6ecfe81e2b0f9531df87efdb47c1338ac321fefe5a432", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE8+wvE8rwTQGStH+0xTEfttTcawqe\ngC5TJ/fsXujkg035fj5Gi30NuGfW7P6B4rD5Ux34fv20fBM4rDIf7+WkMg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 161, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd55a00c9fcdaebb6032513ca0234ecfffe98ebe492fdf02e48ca48e982beb3669", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "2SsgCu_Ktqx9r9msry-hCzGAI1uPRrRQPkaTxnD8zIg", - "y" : "XvLzrr9bMXR1M2JWdo98Ge-3NS0n5MzK3IW2uKuSLHI" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04d92b200aefcab6ac7dafd9acaf2fa10b3180235b8f46b4503e4693c670fccc885ef2f3aebf5b317475336256768f7c19efb7352d27e4cccadc85b6b8ab922c72", - "wx" : "00d92b200aefcab6ac7dafd9acaf2fa10b3180235b8f46b4503e4693c670fccc88", - "wy" : "5ef2f3aebf5b317475336256768f7c19efb7352d27e4cccadc85b6b8ab922c72" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004d92b200aefcab6ac7dafd9acaf2fa10b3180235b8f46b4503e4693c670fccc885ef2f3aebf5b317475336256768f7c19efb7352d27e4cccadc85b6b8ab922c72", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE2SsgCu/Ktqx9r9msry+hCzGAI1uP\nRrRQPkaTxnD8zIhe8vOuv1sxdHUzYlZ2j3wZ77c1LSfkzMrchba4q5Iscg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 162, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdab40193f9b5d76c064a27940469d9fffd31d7c925fbe05c919491d3057d66cd2", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "Cog2HrkuzKJiWzjl-Yu6u5a_F5s9dvxIFAo7zYgVI80", - "y" : "5r31YDP4SlBUA1WXN12QhmqiyWuGpBzPbt6_RymK1Ik" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "040a88361eb92ecca2625b38e5f98bbabb96bf179b3d76fc48140a3bcd881523cde6bdf56033f84a5054035597375d90866aa2c96b86a41ccf6edebf47298ad489", - "wx" : "0a88361eb92ecca2625b38e5f98bbabb96bf179b3d76fc48140a3bcd881523cd", - "wy" : "00e6bdf56033f84a5054035597375d90866aa2c96b86a41ccf6edebf47298ad489" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200040a88361eb92ecca2625b38e5f98bbabb96bf179b3d76fc48140a3bcd881523cde6bdf56033f84a5054035597375d90866aa2c96b86a41ccf6edebf47298ad489", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAECog2HrkuzKJiWzjl+Yu6u5a/F5s9\ndvxIFAo7zYgVI83mvfVgM/hKUFQDVZc3XZCGaqLJa4akHM9u3r9HKYrUiQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 163, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdca0234ebb5fdcb13ca0234ecffffffffcb0dadbbc7f549f8a26b4408d0dc8600", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "0PsXzNj6_oJ-DBr8XY2ANm4rIOfxSlY6K6UEadhDdeg", - "y" : "aGEladOeK7n1VDVVZGRt6ZrGAsxjSc-MHiNqfedjfZM" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04d0fb17ccd8fafe827e0c1afc5d8d80366e2b20e7f14a563a2ba50469d84375e868612569d39e2bb9f554355564646de99ac602cc6349cf8c1e236a7de7637d93", - "wx" : "00d0fb17ccd8fafe827e0c1afc5d8d80366e2b20e7f14a563a2ba50469d84375e8", - "wy" : "68612569d39e2bb9f554355564646de99ac602cc6349cf8c1e236a7de7637d93" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004d0fb17ccd8fafe827e0c1afc5d8d80366e2b20e7f14a563a2ba50469d84375e868612569d39e2bb9f554355564646de99ac602cc6349cf8c1e236a7de7637d93", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE0PsXzNj6/oJ+DBr8XY2ANm4rIOfx\nSlY6K6UEadhDdehoYSVp054rufVUNVVkZG3pmsYCzGNJz4weI2p952N9kw==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 164, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdbfffffff3ea3677e082b9310572620ae19933a9e65b285598711c77298815ad3", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "g28zu8HcDT06u87w2R8R4qxBgQdsmvCiKx5DCdPtsnY", - "y" : "mrRD_2-QHjDHc4Z1gpl8K-wrDLgSDXYCNvOpW76IH3U" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04836f33bbc1dc0d3d3abbcef0d91f11e2ac4181076c9af0a22b1e4309d3edb2769ab443ff6f901e30c773867582997c2bec2b0cb8120d760236f3a95bbe881f75", - "wx" : "00836f33bbc1dc0d3d3abbcef0d91f11e2ac4181076c9af0a22b1e4309d3edb276", - "wy" : "009ab443ff6f901e30c773867582997c2bec2b0cb8120d760236f3a95bbe881f75" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004836f33bbc1dc0d3d3abbcef0d91f11e2ac4181076c9af0a22b1e4309d3edb2769ab443ff6f901e30c773867582997c2bec2b0cb8120d760236f3a95bbe881f75", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEg28zu8HcDT06u87w2R8R4qxBgQds\nmvCiKx5DCdPtsnaatEP/b5AeMMdzhnWCmXwr7CsMuBINdgI286lbvogfdQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 165, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd266666663bbbbbbbe6666666666666665b37902e023fab7c8f055d86e5cc41f4", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "kvmfvpc-1KKZcZuu5LQydBI3A03sjXK6UQPLM-Vf7rg", - "y" : "Az3Q6RE0xzQXSInz688behrAV2cokoDuenlM69bmlpc" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "0492f99fbe973ed4a299719baee4b432741237034dec8d72ba5103cb33e55feeb8033dd0e91134c734174889f3ebcf1b7a1ac05767289280ee7a794cebd6e69697", - "wx" : "0092f99fbe973ed4a299719baee4b432741237034dec8d72ba5103cb33e55feeb8", - "wy" : "033dd0e91134c734174889f3ebcf1b7a1ac05767289280ee7a794cebd6e69697" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d0301070342000492f99fbe973ed4a299719baee4b432741237034dec8d72ba5103cb33e55feeb8033dd0e91134c734174889f3ebcf1b7a1ac05767289280ee7a794cebd6e69697", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEkvmfvpc+1KKZcZuu5LQydBI3A03s\njXK6UQPLM+Vf7rgDPdDpETTHNBdIifPrzxt6GsBXZyiSgO56eUzr1uaWlw==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 166, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdbfffffff36db6db7a492492492492492146c573f4c6dfc8d08a443e258970b09", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "01uljaMBl9N45hjsD6fi4tEs_9c-u7IEnRMLukNK8J4", - "y" : "_4OYbmh15B6kMrdYWkmzpsd8uzxHkZ-OgodMeUY1wdI" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04d35ba58da30197d378e618ec0fa7e2e2d12cffd73ebbb2049d130bba434af09eff83986e6875e41ea432b7585a49b3a6c77cbb3c47919f8e82874c794635c1d2", - "wx" : "00d35ba58da30197d378e618ec0fa7e2e2d12cffd73ebbb2049d130bba434af09e", - "wy" : "00ff83986e6875e41ea432b7585a49b3a6c77cbb3c47919f8e82874c794635c1d2" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004d35ba58da30197d378e618ec0fa7e2e2d12cffd73ebbb2049d130bba434af09eff83986e6875e41ea432b7585a49b3a6c77cbb3c47919f8e82874c794635c1d2", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE01uljaMBl9N45hjsD6fi4tEs/9c+\nu7IEnRMLukNK8J7/g5huaHXkHqQyt1haSbOmx3y7PEeRn46Ch0x5RjXB0g==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 167, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdbfffffff2aaaaaab7fffffffffffffffc815d0e60b3e596ecb1ad3a27cfd49c4", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "hlHOSQ8bRtc_P_R1FJvikTZpczSlGdfdqwclyNB5MiQ", - "y" : "4RxlvYypLci8mugpEfC1J1HOId2QA65gkAvYJfWQzCg" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "048651ce490f1b46d73f3ff475149be29136697334a519d7ddab0725c8d0793224e11c65bd8ca92dc8bc9ae82911f0b52751ce21dd9003ae60900bd825f590cc28", - "wx" : "008651ce490f1b46d73f3ff475149be29136697334a519d7ddab0725c8d0793224", - "wy" : "00e11c65bd8ca92dc8bc9ae82911f0b52751ce21dd9003ae60900bd825f590cc28" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200048651ce490f1b46d73f3ff475149be29136697334a519d7ddab0725c8d0793224e11c65bd8ca92dc8bc9ae82911f0b52751ce21dd9003ae60900bd825f590cc28", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEhlHOSQ8bRtc/P/R1FJvikTZpczSl\nGdfdqwclyNB5MiThHGW9jKktyLya6CkR8LUnUc4h3ZADrmCQC9gl9ZDMKA==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 168, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd7fffffff55555555ffffffffffffffffd344a71e6f651458a27bdc81fd976e37", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "bY4bEsgxoNqHlWUP-V8QHtkh2eL3KxWxzaypgmuc_G0", - "y" : "721j4rxcCJVwOUpLyfiS1ebHpqY3sgRppYwQatSGvzc" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "046d8e1b12c831a0da8795650ff95f101ed921d9e2f72b15b1cdaca9826b9cfc6def6d63e2bc5c089570394a4bc9f892d5e6c7a6a637b20469a58c106ad486bf37", - "wx" : "6d8e1b12c831a0da8795650ff95f101ed921d9e2f72b15b1cdaca9826b9cfc6d", - "wy" : "00ef6d63e2bc5c089570394a4bc9f892d5e6c7a6a637b20469a58c106ad486bf37" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200046d8e1b12c831a0da8795650ff95f101ed921d9e2f72b15b1cdaca9826b9cfc6def6d63e2bc5c089570394a4bc9f892d5e6c7a6a637b20469a58c106ad486bf37", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEbY4bEsgxoNqHlWUP+V8QHtkh2eL3\nKxWxzaypgmuc/G3vbWPivFwIlXA5SkvJ+JLV5sempjeyBGmljBBq1Ia/Nw==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 169, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd3fffffff800000007fffffffffffffffde737d56d38bcf4279dce5617e3192aa", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "CuWAuukztO8pl8vbsJIjKMqaQQ9ieg99_yTLTZIOFUI", - "y" : "iRHn-Mw2WoqI64FCGjYczCuZ4wnY3Nmpi6g8OUnYk-M" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "040ae580bae933b4ef2997cbdbb0922328ca9a410f627a0f7dff24cb4d920e15428911e7f8cc365a8a88eb81421a361ccc2b99e309d8dcd9a98ba83c3949d893e3", - "wx" : "0ae580bae933b4ef2997cbdbb0922328ca9a410f627a0f7dff24cb4d920e1542", - "wy" : "008911e7f8cc365a8a88eb81421a361ccc2b99e309d8dcd9a98ba83c3949d893e3" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200040ae580bae933b4ef2997cbdbb0922328ca9a410f627a0f7dff24cb4d920e15428911e7f8cc365a8a88eb81421a361ccc2b99e309d8dcd9a98ba83c3949d893e3", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAECuWAuukztO8pl8vbsJIjKMqaQQ9i\neg99/yTLTZIOFUKJEef4zDZaiojrgUIaNhzMK5njCdjc2amLqDw5SdiT4w==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 170, - "comment" : "edge case for u2", - "msg" : "313233343030", - "sig" : "7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd5d8ecd64a4eeba466815ddf3a4de9a8e6abd9c5db0a01eb80343553da648428f", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "W4Ev1SGq-mmDWoSczm-962mDtELSRE_nDhNMAn_EaWM", - "y" : "g4pA8qNgkukATpLY2UDPVjhVDOZyzouNThXrpUmSSek" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "045b812fd521aafa69835a849cce6fbdeb6983b442d2444fe70e134c027fc46963838a40f2a36092e9004e92d8d940cf5638550ce672ce8b8d4e15eba5499249e9", - "wx" : "5b812fd521aafa69835a849cce6fbdeb6983b442d2444fe70e134c027fc46963", - "wy" : "00838a40f2a36092e9004e92d8d940cf5638550ce672ce8b8d4e15eba5499249e9" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200045b812fd521aafa69835a849cce6fbdeb6983b442d2444fe70e134c027fc46963838a40f2a36092e9004e92d8d940cf5638550ce672ce8b8d4e15eba5499249e9", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEW4Ev1SGq+mmDWoSczm+962mDtELS\nRE/nDhNMAn/EaWODikDyo2CS6QBOktjZQM9WOFUM5nLOi41OFeulSZJJ6Q==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 171, - "comment" : "point duplication during verification", - "msg" : "313233343030", - "sig" : "6f2347cab7dd76858fe0555ac3bc99048c4aacafdfb6bcbe05ea6c42c4934569bb726660235793aa9957a61e76e00c2c435109cf9a15dd624d53f4301047856b", - "result" : "valid", - "flags" : [ - "PointDuplication" - ] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "W4Ev1SGq-mmDWoSczm-962mDtELSRE_nDhNMAn_EaWM", - "y" : "fHW_DFyfbRf_sW0nJr8wqceq8xqNMXRyseoUWrZtthY" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "045b812fd521aafa69835a849cce6fbdeb6983b442d2444fe70e134c027fc469637c75bf0c5c9f6d17ffb16d2726bf30a9c7aaf31a8d317472b1ea145ab66db616", - "wx" : "5b812fd521aafa69835a849cce6fbdeb6983b442d2444fe70e134c027fc46963", - "wy" : "7c75bf0c5c9f6d17ffb16d2726bf30a9c7aaf31a8d317472b1ea145ab66db616" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200045b812fd521aafa69835a849cce6fbdeb6983b442d2444fe70e134c027fc469637c75bf0c5c9f6d17ffb16d2726bf30a9c7aaf31a8d317472b1ea145ab66db616", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEW4Ev1SGq+mmDWoSczm+962mDtELS\nRE/nDhNMAn/EaWN8db8MXJ9tF/+xbScmvzCpx6rzGo0xdHKx6hRatm22Fg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 172, - "comment" : "duplication bug", - "msg" : "313233343030", - "sig" : "6f2347cab7dd76858fe0555ac3bc99048c4aacafdfb6bcbe05ea6c42c4934569bb726660235793aa9957a61e76e00c2c435109cf9a15dd624d53f4301047856b", - "result" : "invalid", - "flags" : [ - "PointDuplication" - ] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "at2oK5AmGw8xn6oNh4ZlprbaSX8JyQMXYiLDSs_vcqY", - "y" : "R-b1DcxArV2bWfdgK7Ii-tcaQb9eH530lZo2TGLkiNk" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "046adda82b90261b0f319faa0d878665a6b6da497f09c903176222c34acfef72a647e6f50dcc40ad5d9b59f7602bb222fad71a41bf5e1f9df4959a364c62e488d9", - "wx" : "6adda82b90261b0f319faa0d878665a6b6da497f09c903176222c34acfef72a6", - "wy" : "47e6f50dcc40ad5d9b59f7602bb222fad71a41bf5e1f9df4959a364c62e488d9" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200046adda82b90261b0f319faa0d878665a6b6da497f09c903176222c34acfef72a647e6f50dcc40ad5d9b59f7602bb222fad71a41bf5e1f9df4959a364c62e488d9", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEat2oK5AmGw8xn6oNh4ZlprbaSX8J\nyQMXYiLDSs/vcqZH5vUNzECtXZtZ92ArsiL61xpBv14fnfSVmjZMYuSI2Q==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 173, - "comment" : "point with x-coordinate 0", - "msg" : "313233343030", - "sig" : "0000000000000000000000000000000000000000000000000000000000000001555555550000000055555555555555553ef7a8e48d07df81a693439654210c70", - "result" : "invalid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "L8oNCkeRTed-1W5-zMMnamARIMbfAGnIJcj2oByfOCA", - "y" : "ZfNFCh0XxrJJiaOb6xx97PyoOE-9wpRBjl2Aezxu194" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "042fca0d0a47914de77ed56e7eccc3276a601120c6df0069c825c8f6a01c9f382065f3450a1d17c6b24989a39beb1c7decfca8384fbdc294418e5d807b3c6ed7de", - "wx" : "2fca0d0a47914de77ed56e7eccc3276a601120c6df0069c825c8f6a01c9f3820", - "wy" : "65f3450a1d17c6b24989a39beb1c7decfca8384fbdc294418e5d807b3c6ed7de" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200042fca0d0a47914de77ed56e7eccc3276a601120c6df0069c825c8f6a01c9f382065f3450a1d17c6b24989a39beb1c7decfca8384fbdc294418e5d807b3c6ed7de", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEL8oNCkeRTed+1W5+zMMnamARIMbf\nAGnIJcj2oByfOCBl80UKHRfGskmJo5vrHH3s/Kg4T73ClEGOXYB7PG7X3g==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 174, - "comment" : "point with x-coordinate 0", - "msg" : "313233343030", - "sig" : "010000000000000000000000000000000000000000000000000000000000000000003333333300000000333333333333333325c7cbbc549e52e763f1f55a327a3aa9", - "result" : "invalid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "3YbTtfShPoURCDt4ACCBxT_0Z_EevZilGmM9t2Zl0lA", - "y" : "RdXIIAyJ8voQ2Ek0kibSHY367W_41cs-G34XR068GPc" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04dd86d3b5f4a13e8511083b78002081c53ff467f11ebd98a51a633db76665d25045d5c8200c89f2fa10d849349226d21d8dfaed6ff8d5cb3e1b7e17474ebc18f7", - "wx" : "00dd86d3b5f4a13e8511083b78002081c53ff467f11ebd98a51a633db76665d250", - "wy" : "45d5c8200c89f2fa10d849349226d21d8dfaed6ff8d5cb3e1b7e17474ebc18f7" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004dd86d3b5f4a13e8511083b78002081c53ff467f11ebd98a51a633db76665d25045d5c8200c89f2fa10d849349226d21d8dfaed6ff8d5cb3e1b7e17474ebc18f7", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE3YbTtfShPoURCDt4ACCBxT/0Z/Ee\nvZilGmM9t2Zl0lBF1cggDIny+hDYSTSSJtIdjfrtb/jVyz4bfhdHTrwY9w==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 175, - "comment" : "comparison with point at infinity ", - "msg" : "313233343030", - "sig" : "555555550000000055555555555555553ef7a8e48d07df81a693439654210c703333333300000000333333333333333325c7cbbc549e52e763f1f55a327a3aa9", - "result" : "invalid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "T-pVsyyzKsoMEsTNCr-05ksPWlFuV4wBZZGpP1oPvMU", - "y" : "19P9ELK-ZoxUeyEva7FMiPD-zTiopLLHhe075izksoA" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "044fea55b32cb32aca0c12c4cd0abfb4e64b0f5a516e578c016591a93f5a0fbcc5d7d3fd10b2be668c547b212f6bb14c88f0fecd38a8a4b2c785ed3be62ce4b280", - "wx" : "4fea55b32cb32aca0c12c4cd0abfb4e64b0f5a516e578c016591a93f5a0fbcc5", - "wy" : "00d7d3fd10b2be668c547b212f6bb14c88f0fecd38a8a4b2c785ed3be62ce4b280" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200044fea55b32cb32aca0c12c4cd0abfb4e64b0f5a516e578c016591a93f5a0fbcc5d7d3fd10b2be668c547b212f6bb14c88f0fecd38a8a4b2c785ed3be62ce4b280", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAET+pVsyyzKsoMEsTNCr+05ksPWlFu\nV4wBZZGpP1oPvMXX0/0Qsr5mjFR7IS9rsUyI8P7NOKiksseF7TvmLOSygA==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 176, - "comment" : "extreme value for k and edgecase s", - "msg" : "313233343030", - "sig" : "7cf27b188d034f7e8a52380304b51ac3c08969e277f21b35a60b48fc47669978555555550000000055555555555555553ef7a8e48d07df81a693439654210c70", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "xqdxUnAkIneSFwpvju5zW_Mrf5ivZp6tKZgC4y18MQc", - "y" : "vDtLXmWriHu9NDVys-VhkmH-Ogc-L_14QS9yaGfbWJ4" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04c6a771527024227792170a6f8eee735bf32b7f98af669ead299802e32d7c3107bc3b4b5e65ab887bbd343572b3e5619261fe3a073e2ffd78412f726867db589e", - "wx" : "00c6a771527024227792170a6f8eee735bf32b7f98af669ead299802e32d7c3107", - "wy" : "00bc3b4b5e65ab887bbd343572b3e5619261fe3a073e2ffd78412f726867db589e" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004c6a771527024227792170a6f8eee735bf32b7f98af669ead299802e32d7c3107bc3b4b5e65ab887bbd343572b3e5619261fe3a073e2ffd78412f726867db589e", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAExqdxUnAkIneSFwpvju5zW/Mrf5iv\nZp6tKZgC4y18MQe8O0teZauIe700NXKz5WGSYf46Bz4v/XhBL3JoZ9tYng==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 177, - "comment" : "extreme value for k and s^-1", - "msg" : "313233343030", - "sig" : "7cf27b188d034f7e8a52380304b51ac3c08969e277f21b35a60b48fc47669978b6db6db6249249254924924924924924625bd7a09bec4ca81bcdd9f8fd6b63cc", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "hRwrutCOVOx6mvmfSfA2RNbsbVmyB_7JjehafRW5Vu8", - "y" : "zumWAoMEUHVoS0EL6ND3SUuRqiN59gcnMZ8Q3esP6dY" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04851c2bbad08e54ec7a9af99f49f03644d6ec6d59b207fec98de85a7d15b956efcee9960283045075684b410be8d0f7494b91aa2379f60727319f10ddeb0fe9d6", - "wx" : "00851c2bbad08e54ec7a9af99f49f03644d6ec6d59b207fec98de85a7d15b956ef", - "wy" : "00cee9960283045075684b410be8d0f7494b91aa2379f60727319f10ddeb0fe9d6" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004851c2bbad08e54ec7a9af99f49f03644d6ec6d59b207fec98de85a7d15b956efcee9960283045075684b410be8d0f7494b91aa2379f60727319f10ddeb0fe9d6", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEhRwrutCOVOx6mvmfSfA2RNbsbVmy\nB/7JjehafRW5Vu/O6ZYCgwRQdWhLQQvo0PdJS5GqI3n2BycxnxDd6w/p1g==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 178, - "comment" : "extreme value for k and s^-1", - "msg" : "313233343030", - "sig" : "7cf27b188d034f7e8a52380304b51ac3c08969e277f21b35a60b48fc47669978cccccccc00000000cccccccccccccccc971f2ef152794b9d8fc7d568c9e8eaa7", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "9kF8imcFhOOIZ2lJ5T2n_FWRH_aDGNG_MGEgWssZxI8", - "y" : "jyt0PfNK0PcmdKy3UFkpeEd5zZrJFsNmnq1DAmq21D8" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04f6417c8a670584e388676949e53da7fc55911ff68318d1bf3061205acb19c48f8f2b743df34ad0f72674acb7505929784779cd9ac916c3669ead43026ab6d43f", - "wx" : "00f6417c8a670584e388676949e53da7fc55911ff68318d1bf3061205acb19c48f", - "wy" : "008f2b743df34ad0f72674acb7505929784779cd9ac916c3669ead43026ab6d43f" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004f6417c8a670584e388676949e53da7fc55911ff68318d1bf3061205acb19c48f8f2b743df34ad0f72674acb7505929784779cd9ac916c3669ead43026ab6d43f", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE9kF8imcFhOOIZ2lJ5T2n/FWRH/aD\nGNG/MGEgWssZxI+PK3Q980rQ9yZ0rLdQWSl4R3nNmskWw2aerUMCarbUPw==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 179, - "comment" : "extreme value for k and s^-1", - "msg" : "313233343030", - "sig" : "7cf27b188d034f7e8a52380304b51ac3c08969e277f21b35a60b48fc476699783333333300000000333333333333333325c7cbbc549e52e763f1f55a327a3aaa", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "UBQhJ3vkWl7v7GxjmTDWNgMlZa9CDPM3P1V_qn-KBkM", - "y" : "hnPWy2B24c_Nx9_nOEyOXKwI10UB8q5uicrRldCqE3E" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04501421277be45a5eefec6c639930d636032565af420cf3373f557faa7f8a06438673d6cb6076e1cfcdc7dfe7384c8e5cac08d74501f2ae6e89cad195d0aa1371", - "wx" : "501421277be45a5eefec6c639930d636032565af420cf3373f557faa7f8a0643", - "wy" : "008673d6cb6076e1cfcdc7dfe7384c8e5cac08d74501f2ae6e89cad195d0aa1371" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004501421277be45a5eefec6c639930d636032565af420cf3373f557faa7f8a06438673d6cb6076e1cfcdc7dfe7384c8e5cac08d74501f2ae6e89cad195d0aa1371", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEUBQhJ3vkWl7v7GxjmTDWNgMlZa9C\nDPM3P1V/qn+KBkOGc9bLYHbhz83H3+c4TI5crAjXRQHyrm6JytGV0KoTcQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 180, - "comment" : "extreme value for k and s^-1", - "msg" : "313233343030", - "sig" : "7cf27b188d034f7e8a52380304b51ac3c08969e277f21b35a60b48fc4766997849249248db6db6dbb6db6db6db6db6db5a8b230d0b2b51dcd7ebf0c9fef7c185", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "DZNb-f_BFaUnc19ynKikyiPuAaSJSt8ONBWshOgIuzQ", - "y" : "MZWjdi_qKe04kSvZ6mxP3nDDBQiTpDdYUM5h2C66M8U" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "040d935bf9ffc115a527735f729ca8a4ca23ee01a4894adf0e3415ac84e808bb343195a3762fea29ed38912bd9ea6c4fde70c3050893a4375850ce61d82eba33c5", - "wx" : "0d935bf9ffc115a527735f729ca8a4ca23ee01a4894adf0e3415ac84e808bb34", - "wy" : "3195a3762fea29ed38912bd9ea6c4fde70c3050893a4375850ce61d82eba33c5" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200040d935bf9ffc115a527735f729ca8a4ca23ee01a4894adf0e3415ac84e808bb343195a3762fea29ed38912bd9ea6c4fde70c3050893a4375850ce61d82eba33c5", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEDZNb+f/BFaUnc19ynKikyiPuAaSJ\nSt8ONBWshOgIuzQxlaN2L+op7TiRK9nqbE/ecMMFCJOkN1hQzmHYLrozxQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 181, - "comment" : "extreme value for k", - "msg" : "313233343030", - "sig" : "7cf27b188d034f7e8a52380304b51ac3c08969e277f21b35a60b48fc4766997816a4502e2781e11ac82cbc9d1edd8c981584d13e18411e2f6e0478c34416e3bb", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "Xln1Bwhka-iliTVQFDCOYLZo-2cBliBsQedI5k5NyiE", - "y" : "XeN_7lyXvK9xRNW0WZgvUu7q-98Dqsuv7zjiE2JKAd4" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "045e59f50708646be8a589355014308e60b668fb670196206c41e748e64e4dca215de37fee5c97bcaf7144d5b459982f52eeeafbdf03aacbafef38e213624a01de", - "wx" : "5e59f50708646be8a589355014308e60b668fb670196206c41e748e64e4dca21", - "wy" : "5de37fee5c97bcaf7144d5b459982f52eeeafbdf03aacbafef38e213624a01de" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200045e59f50708646be8a589355014308e60b668fb670196206c41e748e64e4dca215de37fee5c97bcaf7144d5b459982f52eeeafbdf03aacbafef38e213624a01de", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEXln1Bwhka+iliTVQFDCOYLZo+2cB\nliBsQedI5k5NyiFd43/uXJe8r3FE1bRZmC9S7ur73wOqy6/vOOITYkoB3g==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 182, - "comment" : "extreme value for k and edgecase s", - "msg" : "313233343030", - "sig" : "6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296555555550000000055555555555555553ef7a8e48d07df81a693439654210c70", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "Fp-3lzJYQ_r_L3pbVEXani_WIm9--Q7wv-kkEEsC244", - "y" : "e7uN5mLHubHPmyL3ouWCvUbVgdaIeO-yuGGxMdih1mc" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04169fb797325843faff2f7a5b5445da9e2fd6226f7ef90ef0bfe924104b02db8e7bbb8de662c7b9b1cf9b22f7a2e582bd46d581d68878efb2b861b131d8a1d667", - "wx" : "169fb797325843faff2f7a5b5445da9e2fd6226f7ef90ef0bfe924104b02db8e", - "wy" : "7bbb8de662c7b9b1cf9b22f7a2e582bd46d581d68878efb2b861b131d8a1d667" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004169fb797325843faff2f7a5b5445da9e2fd6226f7ef90ef0bfe924104b02db8e7bbb8de662c7b9b1cf9b22f7a2e582bd46d581d68878efb2b861b131d8a1d667", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEFp+3lzJYQ/r/L3pbVEXani/WIm9+\n+Q7wv+kkEEsC2457u43mYse5sc+bIvei5YK9RtWB1oh477K4YbEx2KHWZw==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 183, - "comment" : "extreme value for k and s^-1", - "msg" : "313233343030", - "sig" : "6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296b6db6db6249249254924924924924924625bd7a09bec4ca81bcdd9f8fd6b63cc", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "JxzYnAABQwlrYtTp5MqIWu8vcCPRiv_a-Le1SJgUh1Q", - "y" : "ChxulU4yEIQ1tV-jhbD3ZIGmCbkUnMtLArLKR_6OTaU" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04271cd89c000143096b62d4e9e4ca885aef2f7023d18affdaf8b7b548981487540a1c6e954e32108435b55fa385b0f76481a609b9149ccb4b02b2ca47fe8e4da5", - "wx" : "271cd89c000143096b62d4e9e4ca885aef2f7023d18affdaf8b7b54898148754", - "wy" : "0a1c6e954e32108435b55fa385b0f76481a609b9149ccb4b02b2ca47fe8e4da5" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004271cd89c000143096b62d4e9e4ca885aef2f7023d18affdaf8b7b548981487540a1c6e954e32108435b55fa385b0f76481a609b9149ccb4b02b2ca47fe8e4da5", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEJxzYnAABQwlrYtTp5MqIWu8vcCPR\niv/a+Le1SJgUh1QKHG6VTjIQhDW1X6OFsPdkgaYJuRScy0sCsspH/o5NpQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 184, - "comment" : "extreme value for k and s^-1", - "msg" : "313233343030", - "sig" : "6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296cccccccc00000000cccccccccccccccc971f2ef152794b9d8fc7d568c9e8eaa7", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "PQvH7Y8J0st920brwe15mrFWOpq4S_UkWHoiCv5JnBI", - "y" : "4i3Ds8EDgkpPN42WrbCkCKvxnOfWiqYkT3jLIW-j-N8" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "043d0bc7ed8f09d2cb7ddb46ebc1ed799ab1563a9ab84bf524587a220afe499c12e22dc3b3c103824a4f378d96adb0a408abf19ce7d68aa6244f78cb216fa3f8df", - "wx" : "3d0bc7ed8f09d2cb7ddb46ebc1ed799ab1563a9ab84bf524587a220afe499c12", - "wy" : "00e22dc3b3c103824a4f378d96adb0a408abf19ce7d68aa6244f78cb216fa3f8df" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200043d0bc7ed8f09d2cb7ddb46ebc1ed799ab1563a9ab84bf524587a220afe499c12e22dc3b3c103824a4f378d96adb0a408abf19ce7d68aa6244f78cb216fa3f8df", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEPQvH7Y8J0st920brwe15mrFWOpq4\nS/UkWHoiCv5JnBLiLcOzwQOCSk83jZatsKQIq/Gc59aKpiRPeMshb6P43w==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 185, - "comment" : "extreme value for k and s^-1", - "msg" : "313233343030", - "sig" : "6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c2963333333300000000333333333333333325c7cbbc549e52e763f1f55a327a3aaa", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "psiFreGkxWb5uwENBml0q7KBeX-nASiMchvL0jZjqbc", - "y" : "LkJLaQlXFo0ZOmCW_HeisASpx9Rn4Afh8gWEWPmK8xY" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04a6c885ade1a4c566f9bb010d066974abb281797fa701288c721bcbd23663a9b72e424b690957168d193a6096fc77a2b004a9c7d467e007e1f2058458f98af316", - "wx" : "00a6c885ade1a4c566f9bb010d066974abb281797fa701288c721bcbd23663a9b7", - "wy" : "2e424b690957168d193a6096fc77a2b004a9c7d467e007e1f2058458f98af316" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004a6c885ade1a4c566f9bb010d066974abb281797fa701288c721bcbd23663a9b72e424b690957168d193a6096fc77a2b004a9c7d467e007e1f2058458f98af316", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEpsiFreGkxWb5uwENBml0q7KBeX+n\nASiMchvL0jZjqbcuQktpCVcWjRk6YJb8d6KwBKnH1GfgB+HyBYRY+YrzFg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 186, - "comment" : "extreme value for k and s^-1", - "msg" : "313233343030", - "sig" : "6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c29649249248db6db6dbb6db6db6db6db6db5a8b230d0b2b51dcd7ebf0c9fef7c185", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "jTwsLDt2W6gonmrDgSVyolv3XfYth6tzMMO9utnr-lw", - "y" : "TGhFRC1mk1sjhXjUOuxU98qhYh0a8kHUYy4LeAxCP10" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "048d3c2c2c3b765ba8289e6ac3812572a25bf75df62d87ab7330c3bdbad9ebfa5c4c6845442d66935b238578d43aec54f7caa1621d1af241d4632e0b780c423f5d", - "wx" : "008d3c2c2c3b765ba8289e6ac3812572a25bf75df62d87ab7330c3bdbad9ebfa5c", - "wy" : "4c6845442d66935b238578d43aec54f7caa1621d1af241d4632e0b780c423f5d" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200048d3c2c2c3b765ba8289e6ac3812572a25bf75df62d87ab7330c3bdbad9ebfa5c4c6845442d66935b238578d43aec54f7caa1621d1af241d4632e0b780c423f5d", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEjTwsLDt2W6gonmrDgSVyolv3XfYt\nh6tzMMO9utnr+lxMaEVELWaTWyOFeNQ67FT3yqFiHRryQdRjLgt4DEI/XQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 187, - "comment" : "extreme value for k", - "msg" : "313233343030", - "sig" : "6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c29616a4502e2781e11ac82cbc9d1edd8c981584d13e18411e2f6e0478c34416e3bb", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "axfR8uEsQkf4vOblY6RA8ncDfYEt6zOg9KE5RdiYwpY", - "y" : "T-NC4v4af5uO5-tKfA-eFivOM1drMV7Oy7ZAaDe_UfU" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "046b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c2964fe342e2fe1a7f9b8ee7eb4a7c0f9e162bce33576b315ececbb6406837bf51f5", - "wx" : "6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296", - "wy" : "4fe342e2fe1a7f9b8ee7eb4a7c0f9e162bce33576b315ececbb6406837bf51f5" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200046b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c2964fe342e2fe1a7f9b8ee7eb4a7c0f9e162bce33576b315ececbb6406837bf51f5", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEaxfR8uEsQkf4vOblY6RA8ncDfYEt\n6zOg9KE5RdiYwpZP40Li/hp/m47n60p8D54WK84zV2sxXs7LtkBoN79R9Q==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 188, - "comment" : "testing point duplication", - "msg" : "313233343030", - "sig" : "bb5a52f42f9c9261ed4361f59422a1e30036e7c32b270c8807a419feca605023249249246db6db6ddb6db6db6db6db6dad4591868595a8ee6bf5f864ff7be0c2", - "result" : "invalid", - "flags" : [] - }, - { - "tcId" : 189, - "comment" : "testing point duplication", - "msg" : "313233343030", - "sig" : "44a5ad0ad0636d9f12bc9e0a6bdd5e1cbcb012ea7bf091fcec15b0c43202d52e249249246db6db6ddb6db6db6db6db6dad4591868595a8ee6bf5f864ff7be0c2", - "result" : "invalid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "axfR8uEsQkf4vOblY6RA8ncDfYEt6zOg9KE5RdiYwpY", - "y" : "sBy9HAHlgGVxGBS1g_Bh6dQxzKmUzqExNEm_l8hArgo" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "046b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296b01cbd1c01e58065711814b583f061e9d431cca994cea1313449bf97c840ae0a", - "wx" : "6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296", - "wy" : "00b01cbd1c01e58065711814b583f061e9d431cca994cea1313449bf97c840ae0a" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200046b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296b01cbd1c01e58065711814b583f061e9d431cca994cea1313449bf97c840ae0a", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEaxfR8uEsQkf4vOblY6RA8ncDfYEt\n6zOg9KE5RdiYwpawHL0cAeWAZXEYFLWD8GHp1DHMqZTOoTE0Sb+XyECuCg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 190, - "comment" : "testing point duplication", - "msg" : "313233343030", - "sig" : "bb5a52f42f9c9261ed4361f59422a1e30036e7c32b270c8807a419feca605023249249246db6db6ddb6db6db6db6db6dad4591868595a8ee6bf5f864ff7be0c2", - "result" : "invalid", - "flags" : [] - }, - { - "tcId" : 191, - "comment" : "testing point duplication", - "msg" : "313233343030", - "sig" : "44a5ad0ad0636d9f12bc9e0a6bdd5e1cbcb012ea7bf091fcec15b0c43202d52e249249246db6db6ddb6db6db6db6db6dad4591868595a8ee6bf5f864ff7be0c2", - "result" : "invalid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "BKrsc2NXJvIT-4qeZNo7hjLkFJWpRNAEW1IuunJA-tU", - "y" : "h9kxV5iqo6W6AXdXh87QXqr3tOCfyB1tGqVG6DZdUl0" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "0404aaec73635726f213fb8a9e64da3b8632e41495a944d0045b522eba7240fad587d9315798aaa3a5ba01775787ced05eaaf7b4e09fc81d6d1aa546e8365d525d", - "wx" : "04aaec73635726f213fb8a9e64da3b8632e41495a944d0045b522eba7240fad5", - "wy" : "0087d9315798aaa3a5ba01775787ced05eaaf7b4e09fc81d6d1aa546e8365d525d" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d0301070342000404aaec73635726f213fb8a9e64da3b8632e41495a944d0045b522eba7240fad587d9315798aaa3a5ba01775787ced05eaaf7b4e09fc81d6d1aa546e8365d525d", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEBKrsc2NXJvIT+4qeZNo7hjLkFJWp\nRNAEW1IuunJA+tWH2TFXmKqjpboBd1eHztBeqve04J/IHW0apUboNl1SXQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 192, - "comment" : "pseudorandom signature", - "msg" : "", - "sig" : "b292a619339f6e567a305c951c0dcbcc42d16e47f219f9e98e76e09d8770b34a0177e60492c5a8242f76f07bfe3661bde59ec2a17ce5bd2dab2abebdf89a62e2", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 193, - "comment" : "pseudorandom signature", - "msg" : "4d7367", - "sig" : "530bd6b0c9af2d69ba897f6b5fb59695cfbf33afe66dbadcf5b8d2a2a6538e23d85e489cb7a161fd55ededcedbf4cc0c0987e3e3f0f242cae934c72caa3f43e9", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 194, - "comment" : "pseudorandom signature", - "msg" : "313233343030", - "sig" : "a8ea150cb80125d7381c4c1f1da8e9de2711f9917060406a73d7904519e51388f3ab9fa68bd47973a73b2d40480c2ba50c22c9d76ec217257288293285449b86", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 195, - "comment" : "pseudorandom signature", - "msg" : "0000000000000000000000000000000000000000", - "sig" : "986e65933ef2ed4ee5aada139f52b70539aaf63f00a91f29c69178490d57fb713dafedfb8da6189d372308cbf1489bbbdabf0c0217d1c0ff0f701aaa7a694b9c", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "TzN8z9Z3JqgF5PFgCuKEnfOAfsoRc4Ajn72BaQAAAAA", - "y" : "7Z3qEkzIw5ZBZBHpiMMPQn61BK9DoxRs1d9-pgZm1oU" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "044f337ccfd67726a805e4f1600ae2849df3807eca117380239fbd816900000000ed9dea124cc8c396416411e988c30f427eb504af43a3146cd5df7ea60666d685", - "wx" : "4f337ccfd67726a805e4f1600ae2849df3807eca117380239fbd816900000000", - "wy" : "00ed9dea124cc8c396416411e988c30f427eb504af43a3146cd5df7ea60666d685" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200044f337ccfd67726a805e4f1600ae2849df3807eca117380239fbd816900000000ed9dea124cc8c396416411e988c30f427eb504af43a3146cd5df7ea60666d685", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAETzN8z9Z3JqgF5PFgCuKEnfOAfsoR\nc4Ajn72BaQAAAADtneoSTMjDlkFkEemIww9CfrUEr0OjFGzV336mBmbWhQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 196, - "comment" : "x-coordinate of the public key has many trailing 0's", - "msg" : "4d657373616765", - "sig" : "d434e262a49eab7781e353a3565e482550dd0fd5defa013c7f29745eff3569f19b0c0a93f267fb6052fd8077be769c2b98953195d7bc10de844218305c6ba17a", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 197, - "comment" : "x-coordinate of the public key has many trailing 0's", - "msg" : "4d657373616765", - "sig" : "0fe774355c04d060f76d79fd7a772e421463489221bf0a33add0be9b1979110b500dcba1c69a8fbd43fa4f57f743ce124ca8b91a1f325f3fac6181175df55737", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 198, - "comment" : "x-coordinate of the public key has many trailing 0's", - "msg" : "4d657373616765", - "sig" : "bb40bf217bed3fb3950c7d39f03d36dc8e3b2cd79693f125bfd06595ee1135e3541bf3532351ebb032710bdb6a1bf1bfc89a1e291ac692b3fa4780745bb55677", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "PPA9YU2JOc_UmaB4c_rCgWGPBrj_h-gBXD9JcmUASTU", - "y" : "hPoXTXkccr8s44gKiWDdKnx6EzioL4Wp5Zzb3oAAAAA" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "043cf03d614d8939cfd499a07873fac281618f06b8ff87e8015c3f49726500493584fa174d791c72bf2ce3880a8960dd2a7c7a1338a82f85a9e59cdbde80000000", - "wx" : "3cf03d614d8939cfd499a07873fac281618f06b8ff87e8015c3f497265004935", - "wy" : "0084fa174d791c72bf2ce3880a8960dd2a7c7a1338a82f85a9e59cdbde80000000" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200043cf03d614d8939cfd499a07873fac281618f06b8ff87e8015c3f49726500493584fa174d791c72bf2ce3880a8960dd2a7c7a1338a82f85a9e59cdbde80000000", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEPPA9YU2JOc/UmaB4c/rCgWGPBrj/\nh+gBXD9JcmUASTWE+hdNeRxyvyzjiAqJYN0qfHoTOKgvhanlnNvegAAAAA==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 199, - "comment" : "y-coordinate of the public key has many trailing 0's", - "msg" : "4d657373616765", - "sig" : "664eb7ee6db84a34df3c86ea31389a5405badd5ca99231ff556d3e75a233e73a59f3c752e52eca46137642490a51560ce0badc678754b8f72e51a2901426a1bd", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 200, - "comment" : "y-coordinate of the public key has many trailing 0's", - "msg" : "4d657373616765", - "sig" : "4cd0429bbabd2827009d6fcd843d4ce39c3e42e2d1631fd001985a79d1fd8b439638bf12dd682f60be7ef1d0e0d98f08b7bca77a1a2b869ae466189d2acdabe3", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 201, - "comment" : "y-coordinate of the public key has many trailing 0's", - "msg" : "4d657373616765", - "sig" : "e56c6ea2d1b017091c44d8b6cb62b9f460e3ce9aed5e5fd41e8added97c56c04a308ec31f281e955be20b457e463440b4fcf2b80258078207fc1378180f89b55", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "PPA9YU2JOc_UmaB4c_rCgWGPBrj_h-gBXD9JcmUASTU", - "y" : "ewXosYbjjUHTHHf1dp8i1YOF7MhX0HpWGmMkIX____8" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "043cf03d614d8939cfd499a07873fac281618f06b8ff87e8015c3f4972650049357b05e8b186e38d41d31c77f5769f22d58385ecc857d07a561a6324217fffffff", - "wx" : "3cf03d614d8939cfd499a07873fac281618f06b8ff87e8015c3f497265004935", - "wy" : "7b05e8b186e38d41d31c77f5769f22d58385ecc857d07a561a6324217fffffff" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200043cf03d614d8939cfd499a07873fac281618f06b8ff87e8015c3f4972650049357b05e8b186e38d41d31c77f5769f22d58385ecc857d07a561a6324217fffffff", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEPPA9YU2JOc/UmaB4c/rCgWGPBrj/\nh+gBXD9JcmUASTV7BeixhuONQdMcd/V2nyLVg4XsyFfQelYaYyQhf////w==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 202, - "comment" : "y-coordinate of the public key has many trailing 1's", - "msg" : "4d657373616765", - "sig" : "1158a08d291500b4cabed3346d891eee57c176356a2624fb011f8fbbf3466830228a8c486a736006e082325b85290c5bc91f378b75d487dda46798c18f285519", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 203, - "comment" : "y-coordinate of the public key has many trailing 1's", - "msg" : "4d657373616765", - "sig" : "b1db9289649f59410ea36b0c0fc8d6aa2687b29176939dd23e0dde56d309fa9d3e1535e4280559015b0dbd987366dcf43a6d1af5c23c7d584e1c3f48a1251336", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 204, - "comment" : "y-coordinate of the public key has many trailing 1's", - "msg" : "4d657373616765", - "sig" : "b7b16e762286cb96446aa8d4e6e7578b0a341a79f2dd1a220ac6f0ca4e24ed86ddc60a700a139b04661c547d07bbb0721780146df799ccf55e55234ecb8f12bc", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "KCnDH6ouQA40TtlLyj_NBUWVbrz-itD236X_jv____8", - "y" : "oBqvrwAOUlhYVa-nZ2reKEETCZBS31fn6zvTfr65Ii4" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "042829c31faa2e400e344ed94bca3fcd0545956ebcfe8ad0f6dfa5ff8effffffffa01aafaf000e52585855afa7676ade284113099052df57e7eb3bd37ebeb9222e", - "wx" : "2829c31faa2e400e344ed94bca3fcd0545956ebcfe8ad0f6dfa5ff8effffffff", - "wy" : "00a01aafaf000e52585855afa7676ade284113099052df57e7eb3bd37ebeb9222e" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d030107034200042829c31faa2e400e344ed94bca3fcd0545956ebcfe8ad0f6dfa5ff8effffffffa01aafaf000e52585855afa7676ade284113099052df57e7eb3bd37ebeb9222e", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEKCnDH6ouQA40TtlLyj/NBUWVbrz+\nitD236X/jv////+gGq+vAA5SWFhVr6dnat4oQRMJkFLfV+frO9N+vrkiLg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 205, - "comment" : "x-coordinate of the public key has many trailing 1's", - "msg" : "4d657373616765", - "sig" : "d82a7c2717261187c8e00d8df963ff35d796edad36bc6e6bd1c91c670d9105b43dcabddaf8fcaa61f4603e7cbac0f3c0351ecd5988efb23f680d07debd139929", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 206, - "comment" : "x-coordinate of the public key has many trailing 1's", - "msg" : "4d657373616765", - "sig" : "5eb9c8845de68eb13d5befe719f462d77787802baff30ce96a5cba063254af782c026ae9be2e2a5e7ca0ff9bbd92fb6e44972186228ee9a62b87ddbe2ef66fb5", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 207, - "comment" : "x-coordinate of the public key has many trailing 1's", - "msg" : "4d657373616765", - "sig" : "96843dd03c22abd2f3b782b170239f90f277921becc117d0404a8e4e36230c28f2be378f526f74a543f67165976de9ed9a31214eb4d7e6db19e1ede123dd991d", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "____-UgIHmoEWN2PnnOPJmX_kFmtaqwHCDGMTKmnpPU", - "y" : "Woq8ui3ahHQxHuVBSblzyuDA-4lVetC_eOZSmhZjvXM" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04fffffff948081e6a0458dd8f9e738f2665ff9059ad6aac0708318c4ca9a7a4f55a8abcba2dda8474311ee54149b973cae0c0fb89557ad0bf78e6529a1663bd73", - "wx" : "00fffffff948081e6a0458dd8f9e738f2665ff9059ad6aac0708318c4ca9a7a4f5", - "wy" : "5a8abcba2dda8474311ee54149b973cae0c0fb89557ad0bf78e6529a1663bd73" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004fffffff948081e6a0458dd8f9e738f2665ff9059ad6aac0708318c4ca9a7a4f55a8abcba2dda8474311ee54149b973cae0c0fb89557ad0bf78e6529a1663bd73", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE////+UgIHmoEWN2PnnOPJmX/kFmt\naqwHCDGMTKmnpPVairy6LdqEdDEe5UFJuXPK4MD7iVV60L945lKaFmO9cw==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 208, - "comment" : "x-coordinate of the public key is large", - "msg" : "4d657373616765", - "sig" : "766456dce1857c906f9996af729339464d27e9d98edc2d0e3b760297067421f6402385ecadae0d8081dccaf5d19037ec4e55376eced699e93646bfbbf19d0b41", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 209, - "comment" : "x-coordinate of the public key is large", - "msg" : "4d657373616765", - "sig" : "c605c4b2edeab20419e6518a11b2dbc2b97ed8b07cced0b19c34f777de7b9fd9edf0f612c5f46e03c719647bc8af1b29b2cde2eda700fb1cff5e159d47326dba", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 210, - "comment" : "x-coordinate of the public key is large", - "msg" : "4d657373616765", - "sig" : "d48b68e6cabfe03cf6141c9ac54141f210e64485d9929ad7b732bfe3b7eb8a84feedae50c61bd00e19dc26f9b7e2265e4508c389109ad2f208f0772315b6c941", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "AAAAA_oV-WOUnV8DpvXH-G-eABXusjrrv_EXOTe6dI4", - "y" : "EJmHIHDo6HxVX6E2Wcyl1_rc_LACPqiJVIykivK6fnE" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "0400000003fa15f963949d5f03a6f5c7f86f9e0015eeb23aebbff1173937ba748e1099872070e8e87c555fa13659cca5d7fadcfcb0023ea889548ca48af2ba7e71", - "wx" : "03fa15f963949d5f03a6f5c7f86f9e0015eeb23aebbff1173937ba748e", - "wy" : "1099872070e8e87c555fa13659cca5d7fadcfcb0023ea889548ca48af2ba7e71" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d0301070342000400000003fa15f963949d5f03a6f5c7f86f9e0015eeb23aebbff1173937ba748e1099872070e8e87c555fa13659cca5d7fadcfcb0023ea889548ca48af2ba7e71", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEAAAAA/oV+WOUnV8DpvXH+G+eABXu\nsjrrv/EXOTe6dI4QmYcgcOjofFVfoTZZzKXX+tz8sAI+qIlUjKSK8rp+cQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 211, - "comment" : "x-coordinate of the public key is small", - "msg" : "4d657373616765", - "sig" : "b7c81457d4aeb6aa65957098569f0479710ad7f6595d5874c35a93d12a5dd4c7b7961a0b652878c2d568069a432ca18a1a9199f2ca574dad4b9e3a05c0a1cdb3", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 212, - "comment" : "x-coordinate of the public key is small", - "msg" : "4d657373616765", - "sig" : "6b01332ddb6edfa9a30a1321d5858e1ee3cf97e263e669f8de5e9652e76ff3f75939545fced457309a6a04ace2bd0f70139c8f7d86b02cb1cc58f9e69e96cd5a", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 213, - "comment" : "x-coordinate of the public key is small", - "msg" : "4d657373616765", - "sig" : "efdb884720eaeadc349f9fc356b6c0344101cd2fd8436b7d0e6a4fb93f106361f24bee6ad5dc05f7613975473aadf3aacba9e77de7d69b6ce48cb60d8113385d", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "vLspFMefBF6qbsu8YSgWs75dLWeWcH2BJen4UcGK8BU", - "y" : "AAAAABNSu0oPoupMzrmrY91oSt5aESe88wCmmKcZO8I" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04bcbb2914c79f045eaa6ecbbc612816b3be5d2d6796707d8125e9f851c18af015000000001352bb4a0fa2ea4cceb9ab63dd684ade5a1127bcf300a698a7193bc2", - "wx" : "00bcbb2914c79f045eaa6ecbbc612816b3be5d2d6796707d8125e9f851c18af015", - "wy" : "1352bb4a0fa2ea4cceb9ab63dd684ade5a1127bcf300a698a7193bc2" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004bcbb2914c79f045eaa6ecbbc612816b3be5d2d6796707d8125e9f851c18af015000000001352bb4a0fa2ea4cceb9ab63dd684ade5a1127bcf300a698a7193bc2", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEvLspFMefBF6qbsu8YSgWs75dLWeW\ncH2BJen4UcGK8BUAAAAAE1K7Sg+i6kzOuatj3WhK3loRJ7zzAKaYpxk7wg==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 214, - "comment" : "y-coordinate of the public key is small", - "msg" : "4d657373616765", - "sig" : "31230428405560dcb88fb5a646836aea9b23a23dd973dcbe8014c87b8b20eb070f9344d6e812ce166646747694a41b0aaf97374e19f3c5fb8bd7ae3d9bd0beff", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 215, - "comment" : "y-coordinate of the public key is small", - "msg" : "4d657373616765", - "sig" : "caa797da65b320ab0d5c470cda0b36b294359c7db9841d679174db34c4855743cf543a62f23e212745391aaf7505f345123d2685ee3b941d3de6d9b36242e5a0", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 216, - "comment" : "y-coordinate of the public key is small", - "msg" : "4d657373616765", - "sig" : "7e5f0ab5d900d3d3d7867657e5d6d36519bc54084536e7d21c336ed8001859459450c07f201faec94b82dfb322e5ac676688294aad35aa72e727ff0b19b646aa", - "result" : "valid", - "flags" : [] - } - ] - }, - { - "jwk" : { - "crv" : "P-256", - "kid" : "none", - "kty" : "EC", - "x" : "vLspFMefBF6qbsu8YSgWs75dLWeWcH2BJen4UcGK8BU", - "y" : "_____uytRLbwXRWzMUZUnCKXtSKl7thDDP9ZZ1jmxD0" - }, - "key" : { - "curve" : "secp256r1", - "keySize" : 256, - "type" : "EcPublicKey", - "uncompressed" : "04bcbb2914c79f045eaa6ecbbc612816b3be5d2d6796707d8125e9f851c18af015fffffffeecad44b6f05d15b33146549c2297b522a5eed8430cff596758e6c43d", - "wx" : "00bcbb2914c79f045eaa6ecbbc612816b3be5d2d6796707d8125e9f851c18af015", - "wy" : "00fffffffeecad44b6f05d15b33146549c2297b522a5eed8430cff596758e6c43d" - }, - "keyDer" : "3059301306072a8648ce3d020106082a8648ce3d03010703420004bcbb2914c79f045eaa6ecbbc612816b3be5d2d6796707d8125e9f851c18af015fffffffeecad44b6f05d15b33146549c2297b522a5eed8430cff596758e6c43d", - "keyPem" : "-----BEGIN PUBLIC KEY-----\nMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEvLspFMefBF6qbsu8YSgWs75dLWeW\ncH2BJen4UcGK8BX////+7K1EtvBdFbMxRlScIpe1IqXu2EMM/1lnWObEPQ==\n-----END PUBLIC KEY-----", - "sha" : "SHA-256", - "type" : "EcdsaP1363Verify", - "tests" : [ - { - "tcId" : 217, - "comment" : "y-coordinate of the public key is large", - "msg" : "4d657373616765", - "sig" : "d7d70c581ae9e3f66dc6a480bf037ae23f8a1e4a2136fe4b03aa69f0ca25b35689c460f8a5a5c2bbba962c8a3ee833a413e85658e62a59e2af41d9127cc47224", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 218, - "comment" : "y-coordinate of the public key is large", - "msg" : "4d657373616765", - "sig" : "341c1b9ff3c83dd5e0dfa0bf68bcdf4bb7aa20c625975e5eeee34bb396266b3472b69f061b750fd5121b22b11366fad549c634e77765a017902a67099e0a4469", - "result" : "valid", - "flags" : [] - }, - { - "tcId" : 219, - "comment" : "y-coordinate of the public key is large", - "msg" : "4d657373616765", - "sig" : "70bebe684cdcb5ca72a42f0d873879359bd1781a591809947628d313a3814f67aec03aca8f5587a4d535fa31027bbe9cc0e464b1c3577f4c2dcde6b2094798a9", - "result" : "valid", - "flags" : [] - } - ] - } - ] -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/introspection/ERC165.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/introspection/ERC165.test.js deleted file mode 100644 index 8117c695eb..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/introspection/ERC165.test.js +++ /dev/null @@ -1,18 +0,0 @@ -const { ethers } = require('hardhat'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { shouldSupportInterfaces } = require('./SupportsInterface.behavior'); - -async function fixture() { - return { - mock: await ethers.deployContract('$ERC165'), - }; -} - -describe('ERC165', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - shouldSupportInterfaces(); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/introspection/ERC165Checker.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/introspection/ERC165Checker.test.js deleted file mode 100644 index 1bbe8a5713..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/introspection/ERC165Checker.test.js +++ /dev/null @@ -1,245 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const DUMMY_ID = '0xdeadbeef'; -const DUMMY_ID_2 = '0xcafebabe'; -const DUMMY_ID_3 = '0xdecafbad'; -const DUMMY_UNSUPPORTED_ID = '0xbaddcafe'; -const DUMMY_UNSUPPORTED_ID_2 = '0xbaadcafe'; -const DUMMY_ACCOUNT = '0x1111111111111111111111111111111111111111'; - -async function fixture() { - return { mock: await ethers.deployContract('$ERC165Checker') }; -} - -describe('ERC165Checker', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('ERC165 missing return data', function () { - before(async function () { - this.target = await ethers.deployContract('ERC165MissingData'); - }); - - it('does not support ERC165', async function () { - expect(await this.mock.$supportsERC165(this.target)).to.be.false; - }); - - it('does not support mock interface via supportsInterface', async function () { - expect(await this.mock.$supportsInterface(this.target, DUMMY_ID)).to.be.false; - }); - - it('does not support mock interface via supportsAllInterfaces', async function () { - expect(await this.mock.$supportsAllInterfaces(this.target, [DUMMY_ID])).to.be.false; - }); - - it('does not support mock interface via getSupportedInterfaces', async function () { - expect(await this.mock.$getSupportedInterfaces(this.target, [DUMMY_ID])).to.deep.equal([false]); - }); - - it('does not support mock interface via supportsERC165InterfaceUnchecked', async function () { - expect(await this.mock.$supportsERC165InterfaceUnchecked(this.target, DUMMY_ID)).to.be.false; - }); - }); - - describe('ERC165 malicious return data', function () { - beforeEach(async function () { - this.target = await ethers.deployContract('ERC165MaliciousData'); - }); - - it('does not support ERC165', async function () { - expect(await this.mock.$supportsERC165(this.target)).to.be.false; - }); - - it('does not support mock interface via supportsInterface', async function () { - expect(await this.mock.$supportsInterface(this.target, DUMMY_ID)).to.be.false; - }); - - it('does not support mock interface via supportsAllInterfaces', async function () { - expect(await this.mock.$supportsAllInterfaces(this.target, [DUMMY_ID])).to.be.false; - }); - - it('does not support mock interface via getSupportedInterfaces', async function () { - expect(await this.mock.$getSupportedInterfaces(this.target, [DUMMY_ID])).to.deep.equal([false]); - }); - - it('does not support mock interface via supportsERC165InterfaceUnchecked', async function () { - expect(await this.mock.$supportsERC165InterfaceUnchecked(this.target, DUMMY_ID)).to.be.true; - }); - }); - - describe('ERC165 not supported', function () { - beforeEach(async function () { - this.target = await ethers.deployContract('ERC165NotSupported'); - }); - - it('does not support ERC165', async function () { - expect(await this.mock.$supportsERC165(this.target)).to.be.false; - }); - - it('does not support mock interface via supportsInterface', async function () { - expect(await this.mock.$supportsInterface(this.target, DUMMY_ID)).to.be.false; - }); - - it('does not support mock interface via supportsAllInterfaces', async function () { - expect(await this.mock.$supportsAllInterfaces(this.target, [DUMMY_ID])).to.be.false; - }); - - it('does not support mock interface via getSupportedInterfaces', async function () { - expect(await this.mock.$getSupportedInterfaces(this.target, [DUMMY_ID])).to.deep.equal([false]); - }); - - it('does not support mock interface via supportsERC165InterfaceUnchecked', async function () { - expect(await this.mock.$supportsERC165InterfaceUnchecked(this.target, DUMMY_ID)).to.be.false; - }); - }); - - describe('ERC165 supported', function () { - beforeEach(async function () { - this.target = await ethers.deployContract('ERC165InterfacesSupported', [[]]); - }); - - it('supports ERC165', async function () { - expect(await this.mock.$supportsERC165(this.target)).to.be.true; - }); - - it('does not support mock interface via supportsInterface', async function () { - expect(await this.mock.$supportsInterface(this.target, DUMMY_ID)).to.be.false; - }); - - it('does not support mock interface via supportsAllInterfaces', async function () { - expect(await this.mock.$supportsAllInterfaces(this.target, [DUMMY_ID])).to.be.false; - }); - - it('does not support mock interface via getSupportedInterfaces', async function () { - expect(await this.mock.$getSupportedInterfaces(this.target, [DUMMY_ID])).to.deep.equal([false]); - }); - - it('does not support mock interface via supportsERC165InterfaceUnchecked', async function () { - expect(await this.mock.$supportsERC165InterfaceUnchecked(this.target, DUMMY_ID)).to.be.false; - }); - }); - - describe('ERC165 and single interface supported', function () { - beforeEach(async function () { - this.target = await ethers.deployContract('ERC165InterfacesSupported', [[DUMMY_ID]]); - }); - - it('supports ERC165', async function () { - expect(await this.mock.$supportsERC165(this.target)).to.be.true; - }); - - it('supports mock interface via supportsInterface', async function () { - expect(await this.mock.$supportsInterface(this.target, DUMMY_ID)).to.be.true; - }); - - it('supports mock interface via supportsAllInterfaces', async function () { - expect(await this.mock.$supportsAllInterfaces(this.target, [DUMMY_ID])).to.be.true; - }); - - it('supports mock interface via getSupportedInterfaces', async function () { - expect(await this.mock.$getSupportedInterfaces(this.target, [DUMMY_ID])).to.deep.equal([true]); - }); - - it('supports mock interface via supportsERC165InterfaceUnchecked', async function () { - expect(await this.mock.$supportsERC165InterfaceUnchecked(this.target, DUMMY_ID)).to.be.true; - }); - }); - - describe('ERC165 and many interfaces supported', function () { - const supportedInterfaces = [DUMMY_ID, DUMMY_ID_2, DUMMY_ID_3]; - beforeEach(async function () { - this.target = await ethers.deployContract('ERC165InterfacesSupported', [supportedInterfaces]); - }); - - it('supports ERC165', async function () { - expect(await this.mock.$supportsERC165(this.target)).to.be.true; - }); - - it('supports each interfaceId via supportsInterface', async function () { - for (const interfaceId of supportedInterfaces) { - expect(await this.mock.$supportsInterface(this.target, interfaceId)).to.be.true; - } - }); - - it('supports all interfaceIds via supportsAllInterfaces', async function () { - expect(await this.mock.$supportsAllInterfaces(this.target, supportedInterfaces)).to.be.true; - }); - - it('supports none of the interfaces queried via supportsAllInterfaces', async function () { - const interfaceIdsToTest = [DUMMY_UNSUPPORTED_ID, DUMMY_UNSUPPORTED_ID_2]; - - expect(await this.mock.$supportsAllInterfaces(this.target, interfaceIdsToTest)).to.be.false; - }); - - it('supports not all of the interfaces queried via supportsAllInterfaces', async function () { - const interfaceIdsToTest = [...supportedInterfaces, DUMMY_UNSUPPORTED_ID]; - expect(await this.mock.$supportsAllInterfaces(this.target, interfaceIdsToTest)).to.be.false; - }); - - it('supports all interfaceIds via getSupportedInterfaces', async function () { - expect(await this.mock.$getSupportedInterfaces(this.target, supportedInterfaces)).to.deep.equal( - supportedInterfaces.map(i => supportedInterfaces.includes(i)), - ); - }); - - it('supports none of the interfaces queried via getSupportedInterfaces', async function () { - const interfaceIdsToTest = [DUMMY_UNSUPPORTED_ID, DUMMY_UNSUPPORTED_ID_2]; - - expect(await this.mock.$getSupportedInterfaces(this.target, interfaceIdsToTest)).to.deep.equal( - interfaceIdsToTest.map(i => supportedInterfaces.includes(i)), - ); - }); - - it('supports not all of the interfaces queried via getSupportedInterfaces', async function () { - const interfaceIdsToTest = [...supportedInterfaces, DUMMY_UNSUPPORTED_ID]; - - expect(await this.mock.$getSupportedInterfaces(this.target, interfaceIdsToTest)).to.deep.equal( - interfaceIdsToTest.map(i => supportedInterfaces.includes(i)), - ); - }); - - it('supports each interfaceId via supportsERC165InterfaceUnchecked', async function () { - for (const interfaceId of supportedInterfaces) { - expect(await this.mock.$supportsERC165InterfaceUnchecked(this.target, interfaceId)).to.be.true; - } - }); - }); - - describe('account address does not support ERC165', function () { - it('does not support ERC165', async function () { - expect(await this.mock.$supportsERC165(DUMMY_ACCOUNT)).to.be.false; - }); - - it('does not support mock interface via supportsInterface', async function () { - expect(await this.mock.$supportsInterface(DUMMY_ACCOUNT, DUMMY_ID)).to.be.false; - }); - - it('does not support mock interface via supportsAllInterfaces', async function () { - expect(await this.mock.$supportsAllInterfaces(DUMMY_ACCOUNT, [DUMMY_ID])).to.be.false; - }); - - it('does not support mock interface via getSupportedInterfaces', async function () { - expect(await this.mock.$getSupportedInterfaces(DUMMY_ACCOUNT, [DUMMY_ID])).to.deep.equal([false]); - }); - - it('does not support mock interface via supportsERC165InterfaceUnchecked', async function () { - expect(await this.mock.$supportsERC165InterfaceUnchecked(DUMMY_ACCOUNT, DUMMY_ID)).to.be.false; - }); - }); - - it('Return bomb resistance', async function () { - this.target = await ethers.deployContract('ERC165ReturnBombMock'); - - const { gasUsed: gasUsed1 } = await this.mock.$supportsInterface.send(this.target, DUMMY_ID).then(tx => tx.wait()); - expect(gasUsed1).to.be.lessThan(120_000n); // 3*30k + 21k + some margin - - const { gasUsed: gasUsed2 } = await this.mock.$getSupportedInterfaces - .send(this.target, [DUMMY_ID, DUMMY_ID_2, DUMMY_ID_3, DUMMY_UNSUPPORTED_ID, DUMMY_UNSUPPORTED_ID_2]) - .then(tx => tx.wait()); - - expect(gasUsed2).to.be.lessThan(250_000n); // (2+5)*30k + 21k + some margin - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/introspection/SupportsInterface.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/introspection/SupportsInterface.behavior.js deleted file mode 100644 index 8a7bc4b5e2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/introspection/SupportsInterface.behavior.js +++ /dev/null @@ -1,145 +0,0 @@ -const { expect } = require('chai'); -const { interfaceId } = require('../../helpers/methods'); -const { mapValues } = require('../../helpers/iterate'); - -const INVALID_ID = '0xffffffff'; -const SIGNATURES = { - ERC165: ['supportsInterface(bytes4)'], - ERC721: [ - 'balanceOf(address)', - 'ownerOf(uint256)', - 'approve(address,uint256)', - 'getApproved(uint256)', - 'setApprovalForAll(address,bool)', - 'isApprovedForAll(address,address)', - 'transferFrom(address,address,uint256)', - 'safeTransferFrom(address,address,uint256)', - 'safeTransferFrom(address,address,uint256,bytes)', - ], - ERC721Enumerable: ['totalSupply()', 'tokenOfOwnerByIndex(address,uint256)', 'tokenByIndex(uint256)'], - ERC721Metadata: ['name()', 'symbol()', 'tokenURI(uint256)'], - ERC1155: [ - 'balanceOf(address,uint256)', - 'balanceOfBatch(address[],uint256[])', - 'setApprovalForAll(address,bool)', - 'isApprovedForAll(address,address)', - 'safeTransferFrom(address,address,uint256,uint256,bytes)', - 'safeBatchTransferFrom(address,address,uint256[],uint256[],bytes)', - ], - ERC1155MetadataURI: ['uri(uint256)'], - ERC1155Receiver: [ - 'onERC1155Received(address,address,uint256,uint256,bytes)', - 'onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)', - ], - ERC1363: [ - 'transferAndCall(address,uint256)', - 'transferAndCall(address,uint256,bytes)', - 'transferFromAndCall(address,address,uint256)', - 'transferFromAndCall(address,address,uint256,bytes)', - 'approveAndCall(address,uint256)', - 'approveAndCall(address,uint256,bytes)', - ], - AccessControl: [ - 'hasRole(bytes32,address)', - 'getRoleAdmin(bytes32)', - 'grantRole(bytes32,address)', - 'revokeRole(bytes32,address)', - 'renounceRole(bytes32,address)', - ], - AccessControlEnumerable: ['getRoleMember(bytes32,uint256)', 'getRoleMemberCount(bytes32)'], - AccessControlDefaultAdminRules: [ - 'defaultAdminDelay()', - 'pendingDefaultAdminDelay()', - 'defaultAdmin()', - 'pendingDefaultAdmin()', - 'defaultAdminDelayIncreaseWait()', - 'changeDefaultAdminDelay(uint48)', - 'rollbackDefaultAdminDelay()', - 'beginDefaultAdminTransfer(address)', - 'acceptDefaultAdminTransfer()', - 'cancelDefaultAdminTransfer()', - ], - Governor: [ - 'name()', - 'version()', - 'COUNTING_MODE()', - 'hashProposal(address[],uint256[],bytes[],bytes32)', - 'state(uint256)', - 'proposalThreshold()', - 'proposalSnapshot(uint256)', - 'proposalDeadline(uint256)', - 'proposalProposer(uint256)', - 'proposalEta(uint256)', - 'proposalNeedsQueuing(uint256)', - 'votingDelay()', - 'votingPeriod()', - 'quorum(uint256)', - 'getVotes(address,uint256)', - 'getVotesWithParams(address,uint256,bytes)', - 'hasVoted(uint256,address)', - 'propose(address[],uint256[],bytes[],string)', - 'queue(address[],uint256[],bytes[],bytes32)', - 'execute(address[],uint256[],bytes[],bytes32)', - 'cancel(address[],uint256[],bytes[],bytes32)', - 'castVote(uint256,uint8)', - 'castVoteWithReason(uint256,uint8,string)', - 'castVoteWithReasonAndParams(uint256,uint8,string,bytes)', - 'castVoteBySig(uint256,uint8,address,bytes)', - 'castVoteWithReasonAndParamsBySig(uint256,uint8,address,string,bytes,bytes)', - ], - ERC2981: ['royaltyInfo(uint256,uint256)'], -}; - -const INTERFACE_IDS = mapValues(SIGNATURES, interfaceId); - -function shouldSupportInterfaces(interfaces = []) { - interfaces.unshift('ERC165'); - - describe('ERC165', function () { - beforeEach(function () { - this.contractUnderTest = this.mock || this.token; - }); - - describe('when the interfaceId is supported', function () { - it('uses less than 30k gas', async function () { - for (const k of interfaces) { - const interfaceId = INTERFACE_IDS[k] ?? k; - expect(await this.contractUnderTest.supportsInterface.estimateGas(interfaceId)).to.lte(30_000n); - } - }); - - it('returns true', async function () { - for (const k of interfaces) { - const interfaceId = INTERFACE_IDS[k] ?? k; - expect(await this.contractUnderTest.supportsInterface(interfaceId), `does not support ${k}`).to.be.true; - } - }); - }); - - describe('when the interfaceId is not supported', function () { - it('uses less than 30k', async function () { - expect(await this.contractUnderTest.supportsInterface.estimateGas(INVALID_ID)).to.lte(30_000n); - }); - - it('returns false', async function () { - expect(await this.contractUnderTest.supportsInterface(INVALID_ID), `supports ${INVALID_ID}`).to.be.false; - }); - }); - - it('all interface functions are in ABI', async function () { - for (const k of interfaces) { - // skip interfaces for which we don't have a function list - if (SIGNATURES[k] === undefined) continue; - - // Check the presence of each function in the contract's interface - for (const fnSig of SIGNATURES[k]) { - expect(this.contractUnderTest.interface.hasFunction(fnSig), `did not find ${fnSig}`).to.be.true; - } - } - }); - }); -} - -module.exports = { - shouldSupportInterfaces, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/Math.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/Math.t.sol deleted file mode 100644 index 3d4932eea7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/Math.t.sol +++ /dev/null @@ -1,311 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -import {Test, stdError} from "forge-std/Test.sol"; - -import {Math} from "@openzeppelin/contracts/utils/math/Math.sol"; - -contract MathTest is Test { - function testSymbolicTernary(bool f, uint256 a, uint256 b) public { - assertEq(Math.ternary(f, a, b), f ? a : b); - } - - // MIN & MAX - function testSymbolicMinMax(uint256 a, uint256 b) public { - assertEq(Math.min(a, b), a < b ? a : b); - assertEq(Math.max(a, b), a > b ? a : b); - } - - // CEILDIV - function testCeilDiv(uint256 a, uint256 b) public { - vm.assume(b > 0); - - uint256 result = Math.ceilDiv(a, b); - - if (result == 0) { - assertEq(a, 0); - } else { - uint256 expect = a / b; - if (expect * b < a) { - expect += 1; - } - assertEq(result, expect); - } - } - - // SQRT - function testSqrt(uint256 input, uint8 r) public { - Math.Rounding rounding = _asRounding(r); - - uint256 result = Math.sqrt(input, rounding); - - // square of result is bigger than input - if (_squareBigger(result, input)) { - assertTrue(Math.unsignedRoundsUp(rounding)); - assertTrue(_squareSmaller(result - 1, input)); - } - // square of result is smaller than input - else if (_squareSmaller(result, input)) { - assertFalse(Math.unsignedRoundsUp(rounding)); - assertTrue(_squareBigger(result + 1, input)); - } - // input is perfect square - else { - assertEq(result * result, input); - } - } - - function _squareBigger(uint256 value, uint256 ref) private pure returns (bool) { - (bool noOverflow, uint256 square) = Math.tryMul(value, value); - return !noOverflow || square > ref; - } - - function _squareSmaller(uint256 value, uint256 ref) private pure returns (bool) { - return value * value < ref; - } - - // INV - function testInvMod(uint256 value, uint256 p) public { - _testInvMod(value, p, true); - } - - function testInvMod2(uint256 seed) public { - uint256 p = 2; // prime - _testInvMod(bound(seed, 1, p - 1), p, false); - } - - function testInvMod17(uint256 seed) public { - uint256 p = 17; // prime - _testInvMod(bound(seed, 1, p - 1), p, false); - } - - function testInvMod65537(uint256 seed) public { - uint256 p = 65537; // prime - _testInvMod(bound(seed, 1, p - 1), p, false); - } - - function testInvModP256(uint256 seed) public { - uint256 p = 0xffffffff00000001000000000000000000000000ffffffffffffffffffffffff; // prime - _testInvMod(bound(seed, 1, p - 1), p, false); - } - - function _testInvMod(uint256 value, uint256 p, bool allowZero) private { - uint256 inverse = Math.invMod(value, p); - if (inverse != 0) { - assertEq(mulmod(value, inverse, p), 1); - assertLt(inverse, p); - } else { - assertTrue(allowZero); - } - } - - // LOG2 - function testLog2(uint256 input, uint8 r) public { - Math.Rounding rounding = _asRounding(r); - - uint256 result = Math.log2(input, rounding); - - if (input == 0) { - assertEq(result, 0); - } else if (_powerOf2Bigger(result, input)) { - assertTrue(Math.unsignedRoundsUp(rounding)); - assertTrue(_powerOf2Smaller(result - 1, input)); - } else if (_powerOf2Smaller(result, input)) { - assertFalse(Math.unsignedRoundsUp(rounding)); - assertTrue(_powerOf2Bigger(result + 1, input)); - } else { - assertEq(2 ** result, input); - } - } - - function _powerOf2Bigger(uint256 value, uint256 ref) private pure returns (bool) { - return value >= 256 || 2 ** value > ref; // 2**256 overflows uint256 - } - - function _powerOf2Smaller(uint256 value, uint256 ref) private pure returns (bool) { - return 2 ** value < ref; - } - - // LOG10 - function testLog10(uint256 input, uint8 r) public { - Math.Rounding rounding = _asRounding(r); - - uint256 result = Math.log10(input, rounding); - - if (input == 0) { - assertEq(result, 0); - } else if (_powerOf10Bigger(result, input)) { - assertTrue(Math.unsignedRoundsUp(rounding)); - assertTrue(_powerOf10Smaller(result - 1, input)); - } else if (_powerOf10Smaller(result, input)) { - assertFalse(Math.unsignedRoundsUp(rounding)); - assertTrue(_powerOf10Bigger(result + 1, input)); - } else { - assertEq(10 ** result, input); - } - } - - function _powerOf10Bigger(uint256 value, uint256 ref) private pure returns (bool) { - return value >= 78 || 10 ** value > ref; // 10**78 overflows uint256 - } - - function _powerOf10Smaller(uint256 value, uint256 ref) private pure returns (bool) { - return 10 ** value < ref; - } - - // LOG256 - function testLog256(uint256 input, uint8 r) public { - Math.Rounding rounding = _asRounding(r); - - uint256 result = Math.log256(input, rounding); - - if (input == 0) { - assertEq(result, 0); - } else if (_powerOf256Bigger(result, input)) { - assertTrue(Math.unsignedRoundsUp(rounding)); - assertTrue(_powerOf256Smaller(result - 1, input)); - } else if (_powerOf256Smaller(result, input)) { - assertFalse(Math.unsignedRoundsUp(rounding)); - assertTrue(_powerOf256Bigger(result + 1, input)); - } else { - assertEq(256 ** result, input); - } - } - - function _powerOf256Bigger(uint256 value, uint256 ref) private pure returns (bool) { - return value >= 32 || 256 ** value > ref; // 256**32 overflows uint256 - } - - function _powerOf256Smaller(uint256 value, uint256 ref) private pure returns (bool) { - return 256 ** value < ref; - } - - // MULDIV - function testMulDiv(uint256 x, uint256 y, uint256 d) public { - // Full precision for x * y - (uint256 xyHi, uint256 xyLo) = _mulHighLow(x, y); - - // Assume result won't overflow (see {testMulDivDomain}) - // This also checks that `d` is positive - vm.assume(xyHi < d); - - // Perform muldiv - uint256 q = Math.mulDiv(x, y, d); - - // Full precision for q * d - (uint256 qdHi, uint256 qdLo) = _mulHighLow(q, d); - // Add remainder of x * y / d (computed as rem = (x * y % d)) - (uint256 qdRemLo, uint256 c) = _addCarry(qdLo, mulmod(x, y, d)); - uint256 qdRemHi = qdHi + c; - - // Full precision check that x * y = q * d + rem - assertEq(xyHi, qdRemHi); - assertEq(xyLo, qdRemLo); - } - - function testMulDivDomain(uint256 x, uint256 y, uint256 d) public { - (uint256 xyHi, ) = _mulHighLow(x, y); - - // Violate {testMulDiv} assumption (covers d is 0 and result overflow) - vm.assume(xyHi >= d); - - // we are outside the scope of {testMulDiv}, we expect muldiv to revert - vm.expectRevert(d == 0 ? stdError.divisionError : stdError.arithmeticError); - Math.mulDiv(x, y, d); - } - - // MOD EXP - function testModExp(uint256 b, uint256 e, uint256 m) public { - if (m == 0) { - vm.expectRevert(stdError.divisionError); - } - uint256 result = Math.modExp(b, e, m); - assertLt(result, m); - assertEq(result, _nativeModExp(b, e, m)); - } - - function testTryModExp(uint256 b, uint256 e, uint256 m) public { - (bool success, uint256 result) = Math.tryModExp(b, e, m); - assertEq(success, m != 0); - if (success) { - assertLt(result, m); - assertEq(result, _nativeModExp(b, e, m)); - } else { - assertEq(result, 0); - } - } - - function testModExpMemory(uint256 b, uint256 e, uint256 m) public { - if (m == 0) { - vm.expectRevert(stdError.divisionError); - } - bytes memory result = Math.modExp(abi.encodePacked(b), abi.encodePacked(e), abi.encodePacked(m)); - assertEq(result.length, 0x20); - uint256 res = abi.decode(result, (uint256)); - assertLt(res, m); - assertEq(res, _nativeModExp(b, e, m)); - } - - function testTryModExpMemory(uint256 b, uint256 e, uint256 m) public { - (bool success, bytes memory result) = Math.tryModExp( - abi.encodePacked(b), - abi.encodePacked(e), - abi.encodePacked(m) - ); - if (success) { - assertEq(result.length, 0x20); // m is a uint256, so abi.encodePacked(m).length is 0x20 - uint256 res = abi.decode(result, (uint256)); - assertLt(res, m); - assertEq(res, _nativeModExp(b, e, m)); - } else { - assertEq(result.length, 0); - } - } - - function _nativeModExp(uint256 b, uint256 e, uint256 m) private pure returns (uint256) { - if (m == 1) return 0; - uint256 r = 1; - while (e > 0) { - if (e % 2 > 0) { - r = mulmod(r, b, m); - } - b = mulmod(b, b, m); - e >>= 1; - } - return r; - } - - // Helpers - function _asRounding(uint8 r) private pure returns (Math.Rounding) { - vm.assume(r < uint8(type(Math.Rounding).max)); - return Math.Rounding(r); - } - - function _mulHighLow(uint256 x, uint256 y) private pure returns (uint256 high, uint256 low) { - (uint256 x0, uint256 x1) = (x & type(uint128).max, x >> 128); - (uint256 y0, uint256 y1) = (y & type(uint128).max, y >> 128); - - // Karatsuba algorithm - // https://en.wikipedia.org/wiki/Karatsuba_algorithm - uint256 z2 = x1 * y1; - uint256 z1a = x1 * y0; - uint256 z1b = x0 * y1; - uint256 z0 = x0 * y0; - - uint256 carry = ((z1a & type(uint128).max) + (z1b & type(uint128).max) + (z0 >> 128)) >> 128; - - high = z2 + (z1a >> 128) + (z1b >> 128) + carry; - - unchecked { - low = x * y; - } - } - - function _addCarry(uint256 x, uint256 y) private pure returns (uint256 res, uint256 carry) { - unchecked { - res = x + y; - } - carry = res < x ? 1 : 0; - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/Math.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/Math.test.js deleted file mode 100644 index f38f2f3184..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/Math.test.js +++ /dev/null @@ -1,562 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -const { Rounding } = require('../../helpers/enums'); -const { min, max, modExp } = require('../../helpers/math'); -const { generators } = require('../../helpers/random'); -const { product, range } = require('../../helpers/iterate'); - -const RoundingDown = [Rounding.Floor, Rounding.Trunc]; -const RoundingUp = [Rounding.Ceil, Rounding.Expand]; - -const bytes = (value, width = undefined) => ethers.Typed.bytes(ethers.toBeHex(value, width)); -const uint256 = value => ethers.Typed.uint256(value); -bytes.zero = '0x'; -uint256.zero = 0n; - -async function testCommutative(fn, lhs, rhs, expected, ...extra) { - expect(await fn(lhs, rhs, ...extra)).to.deep.equal(expected); - expect(await fn(rhs, lhs, ...extra)).to.deep.equal(expected); -} - -async function fixture() { - const mock = await ethers.deployContract('$Math'); - - // disambiguation, we use the version with explicit rounding - mock.$mulDiv = mock['$mulDiv(uint256,uint256,uint256,uint8)']; - mock.$sqrt = mock['$sqrt(uint256,uint8)']; - mock.$log2 = mock['$log2(uint256,uint8)']; - mock.$log10 = mock['$log10(uint256,uint8)']; - mock.$log256 = mock['$log256(uint256,uint8)']; - - return { mock }; -} - -describe('Math', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('tryAdd', function () { - it('adds correctly', async function () { - const a = 5678n; - const b = 1234n; - await testCommutative(this.mock.$tryAdd, a, b, [true, a + b]); - }); - - it('reverts on addition overflow', async function () { - const a = ethers.MaxUint256; - const b = 1n; - await testCommutative(this.mock.$tryAdd, a, b, [false, 0n]); - }); - }); - - describe('trySub', function () { - it('subtracts correctly', async function () { - const a = 5678n; - const b = 1234n; - expect(await this.mock.$trySub(a, b)).to.deep.equal([true, a - b]); - }); - - it('reverts if subtraction result would be negative', async function () { - const a = 1234n; - const b = 5678n; - expect(await this.mock.$trySub(a, b)).to.deep.equal([false, 0n]); - }); - }); - - describe('tryMul', function () { - it('multiplies correctly', async function () { - const a = 1234n; - const b = 5678n; - await testCommutative(this.mock.$tryMul, a, b, [true, a * b]); - }); - - it('multiplies by zero correctly', async function () { - const a = 0n; - const b = 5678n; - await testCommutative(this.mock.$tryMul, a, b, [true, a * b]); - }); - - it('reverts on multiplication overflow', async function () { - const a = ethers.MaxUint256; - const b = 2n; - await testCommutative(this.mock.$tryMul, a, b, [false, 0n]); - }); - }); - - describe('tryDiv', function () { - it('divides correctly', async function () { - const a = 5678n; - const b = 5678n; - expect(await this.mock.$tryDiv(a, b)).to.deep.equal([true, a / b]); - }); - - it('divides zero correctly', async function () { - const a = 0n; - const b = 5678n; - expect(await this.mock.$tryDiv(a, b)).to.deep.equal([true, a / b]); - }); - - it('returns complete number result on non-even division', async function () { - const a = 7000n; - const b = 5678n; - expect(await this.mock.$tryDiv(a, b)).to.deep.equal([true, a / b]); - }); - - it('reverts on division by zero', async function () { - const a = 5678n; - const b = 0n; - expect(await this.mock.$tryDiv(a, b)).to.deep.equal([false, 0n]); - }); - }); - - describe('tryMod', function () { - describe('modulos correctly', function () { - it('when the dividend is smaller than the divisor', async function () { - const a = 284n; - const b = 5678n; - expect(await this.mock.$tryMod(a, b)).to.deep.equal([true, a % b]); - }); - - it('when the dividend is equal to the divisor', async function () { - const a = 5678n; - const b = 5678n; - expect(await this.mock.$tryMod(a, b)).to.deep.equal([true, a % b]); - }); - - it('when the dividend is larger than the divisor', async function () { - const a = 7000n; - const b = 5678n; - expect(await this.mock.$tryMod(a, b)).to.deep.equal([true, a % b]); - }); - - it('when the dividend is a multiple of the divisor', async function () { - const a = 17034n; // 17034 == 5678 * 3 - const b = 5678n; - expect(await this.mock.$tryMod(a, b)).to.deep.equal([true, a % b]); - }); - }); - - it('reverts with a 0 divisor', async function () { - const a = 5678n; - const b = 0n; - expect(await this.mock.$tryMod(a, b)).to.deep.equal([false, 0n]); - }); - }); - - describe('max', function () { - it('is correctly detected in both position', async function () { - await testCommutative(this.mock.$max, 1234n, 5678n, max(1234n, 5678n)); - }); - }); - - describe('min', function () { - it('is correctly detected in both position', async function () { - await testCommutative(this.mock.$min, 1234n, 5678n, min(1234n, 5678n)); - }); - }); - - describe('average', function () { - it('is correctly calculated with two odd numbers', async function () { - const a = 57417n; - const b = 95431n; - expect(await this.mock.$average(a, b)).to.equal((a + b) / 2n); - }); - - it('is correctly calculated with two even numbers', async function () { - const a = 42304n; - const b = 84346n; - expect(await this.mock.$average(a, b)).to.equal((a + b) / 2n); - }); - - it('is correctly calculated with one even and one odd number', async function () { - const a = 57417n; - const b = 84346n; - expect(await this.mock.$average(a, b)).to.equal((a + b) / 2n); - }); - - it('is correctly calculated with two max uint256 numbers', async function () { - const a = ethers.MaxUint256; - expect(await this.mock.$average(a, a)).to.equal(a); - }); - }); - - describe('ceilDiv', function () { - it('reverts on zero division', async function () { - const a = 2n; - const b = 0n; - // It's unspecified because it's a low level 0 division error - await expect(this.mock.$ceilDiv(a, b)).to.be.revertedWithPanic(PANIC_CODES.DIVISION_BY_ZERO); - }); - - it('does not round up a zero result', async function () { - const a = 0n; - const b = 2n; - const r = 0n; - expect(await this.mock.$ceilDiv(a, b)).to.equal(r); - }); - - it('does not round up on exact division', async function () { - const a = 10n; - const b = 5n; - const r = 2n; - expect(await this.mock.$ceilDiv(a, b)).to.equal(r); - }); - - it('rounds up on division with remainders', async function () { - const a = 42n; - const b = 13n; - const r = 4n; - expect(await this.mock.$ceilDiv(a, b)).to.equal(r); - }); - - it('does not overflow', async function () { - const a = ethers.MaxUint256; - const b = 2n; - const r = 1n << 255n; - expect(await this.mock.$ceilDiv(a, b)).to.equal(r); - }); - - it('correctly computes max uint256 divided by 1', async function () { - const a = ethers.MaxUint256; - const b = 1n; - const r = ethers.MaxUint256; - expect(await this.mock.$ceilDiv(a, b)).to.equal(r); - }); - }); - - describe('mulDiv', function () { - it('divide by 0', async function () { - const a = 1n; - const b = 1n; - const c = 0n; - await expect(this.mock.$mulDiv(a, b, c, Rounding.Floor)).to.be.revertedWithPanic(PANIC_CODES.DIVISION_BY_ZERO); - }); - - it('reverts with result higher than 2 ^ 256', async function () { - const a = 5n; - const b = ethers.MaxUint256; - const c = 2n; - await expect(this.mock.$mulDiv(a, b, c, Rounding.Floor)).to.be.revertedWithPanic( - PANIC_CODES.ARITHMETIC_UNDER_OR_OVERFLOW, - ); - }); - - describe('does round down', function () { - it('small values', async function () { - for (const rounding of RoundingDown) { - expect(await this.mock.$mulDiv(3n, 4n, 5n, rounding)).to.equal(2n); - expect(await this.mock.$mulDiv(3n, 5n, 5n, rounding)).to.equal(3n); - } - }); - - it('large values', async function () { - for (const rounding of RoundingDown) { - expect(await this.mock.$mulDiv(42n, ethers.MaxUint256 - 1n, ethers.MaxUint256, rounding)).to.equal(41n); - - expect(await this.mock.$mulDiv(17n, ethers.MaxUint256, ethers.MaxUint256, rounding)).to.equal(17n); - - expect( - await this.mock.$mulDiv(ethers.MaxUint256 - 1n, ethers.MaxUint256 - 1n, ethers.MaxUint256, rounding), - ).to.equal(ethers.MaxUint256 - 2n); - - expect( - await this.mock.$mulDiv(ethers.MaxUint256, ethers.MaxUint256 - 1n, ethers.MaxUint256, rounding), - ).to.equal(ethers.MaxUint256 - 1n); - - expect(await this.mock.$mulDiv(ethers.MaxUint256, ethers.MaxUint256, ethers.MaxUint256, rounding)).to.equal( - ethers.MaxUint256, - ); - } - }); - }); - - describe('does round up', function () { - it('small values', async function () { - for (const rounding of RoundingUp) { - expect(await this.mock.$mulDiv(3n, 4n, 5n, rounding)).to.equal(3n); - expect(await this.mock.$mulDiv(3n, 5n, 5n, rounding)).to.equal(3n); - } - }); - - it('large values', async function () { - for (const rounding of RoundingUp) { - expect(await this.mock.$mulDiv(42n, ethers.MaxUint256 - 1n, ethers.MaxUint256, rounding)).to.equal(42n); - - expect(await this.mock.$mulDiv(17n, ethers.MaxUint256, ethers.MaxUint256, rounding)).to.equal(17n); - - expect( - await this.mock.$mulDiv(ethers.MaxUint256 - 1n, ethers.MaxUint256 - 1n, ethers.MaxUint256, rounding), - ).to.equal(ethers.MaxUint256 - 1n); - - expect( - await this.mock.$mulDiv(ethers.MaxUint256, ethers.MaxUint256 - 1n, ethers.MaxUint256, rounding), - ).to.equal(ethers.MaxUint256 - 1n); - - expect(await this.mock.$mulDiv(ethers.MaxUint256, ethers.MaxUint256, ethers.MaxUint256, rounding)).to.equal( - ethers.MaxUint256, - ); - } - }); - }); - }); - - describe('invMod', function () { - for (const factors of [ - [0n], - [1n], - [2n], - [17n], - [65537n], - [0xffffffff00000001000000000000000000000000ffffffffffffffffffffffffn], - [3n, 5n], - [3n, 7n], - [47n, 53n], - ]) { - const p = factors.reduce((acc, f) => acc * f, 1n); - - describe(`using p=${p} which is ${p > 1 && factors.length > 1 ? 'not ' : ''}a prime`, function () { - it('trying to inverse 0 returns 0', async function () { - expect(await this.mock.$invMod(0, p)).to.equal(0n); - expect(await this.mock.$invMod(p, p)).to.equal(0n); // p is 0 mod p - }); - - if (p != 0) { - for (const value of Array.from({ length: 16 }, generators.uint256)) { - const isInversible = factors.every(f => value % f); - it(`trying to inverse ${value}`, async function () { - const result = await this.mock.$invMod(value, p); - if (isInversible) { - expect((value * result) % p).to.equal(1n); - } else { - expect(result).to.equal(0n); - } - }); - } - } - }); - } - }); - - describe('modExp', function () { - for (const [name, type] of Object.entries({ uint256, bytes })) { - describe(`with ${name} inputs`, function () { - it('is correctly calculating modulus', async function () { - const b = 3n; - const e = 200n; - const m = 50n; - - expect(await this.mock.$modExp(type(b), type(e), type(m))).to.equal(type(b ** e % m).value); - }); - - it('is correctly reverting when modulus is zero', async function () { - const b = 3n; - const e = 200n; - const m = 0n; - - await expect(this.mock.$modExp(type(b), type(e), type(m))).to.be.revertedWithPanic( - PANIC_CODES.DIVISION_BY_ZERO, - ); - }); - }); - } - - describe('with large bytes inputs', function () { - for (const [[b, log2b], [e, log2e], [m, log2m]] of product( - range(320, 512, 64).map(e => [2n ** BigInt(e) + 1n, e]), - range(320, 512, 64).map(e => [2n ** BigInt(e) + 1n, e]), - range(320, 512, 64).map(e => [2n ** BigInt(e) + 1n, e]), - )) { - it(`calculates b ** e % m (b=2**${log2b}+1) (e=2**${log2e}+1) (m=2**${log2m}+1)`, async function () { - const mLength = ethers.dataLength(ethers.toBeHex(m)); - - expect(await this.mock.$modExp(bytes(b), bytes(e), bytes(m))).to.equal(bytes(modExp(b, e, m), mLength).value); - }); - } - }); - }); - - describe('tryModExp', function () { - for (const [name, type] of Object.entries({ uint256, bytes })) { - describe(`with ${name} inputs`, function () { - it('is correctly calculating modulus', async function () { - const b = 3n; - const e = 200n; - const m = 50n; - - expect(await this.mock.$tryModExp(type(b), type(e), type(m))).to.deep.equal([true, type(b ** e % m).value]); - }); - - it('is correctly reverting when modulus is zero', async function () { - const b = 3n; - const e = 200n; - const m = 0n; - - expect(await this.mock.$tryModExp(type(b), type(e), type(m))).to.deep.equal([false, type.zero]); - }); - }); - } - - describe('with large bytes inputs', function () { - for (const [[b, log2b], [e, log2e], [m, log2m]] of product( - range(320, 513, 64).map(e => [2n ** BigInt(e) + 1n, e]), - range(320, 513, 64).map(e => [2n ** BigInt(e) + 1n, e]), - range(320, 513, 64).map(e => [2n ** BigInt(e) + 1n, e]), - )) { - it(`calculates b ** e % m (b=2**${log2b}+1) (e=2**${log2e}+1) (m=2**${log2m}+1)`, async function () { - const mLength = ethers.dataLength(ethers.toBeHex(m)); - - expect(await this.mock.$tryModExp(bytes(b), bytes(e), bytes(m))).to.deep.equal([ - true, - bytes(modExp(b, e, m), mLength).value, - ]); - }); - } - }); - }); - - describe('sqrt', function () { - it('rounds down', async function () { - for (const rounding of RoundingDown) { - expect(await this.mock.$sqrt(0n, rounding)).to.equal(0n); - expect(await this.mock.$sqrt(1n, rounding)).to.equal(1n); - expect(await this.mock.$sqrt(2n, rounding)).to.equal(1n); - expect(await this.mock.$sqrt(3n, rounding)).to.equal(1n); - expect(await this.mock.$sqrt(4n, rounding)).to.equal(2n); - expect(await this.mock.$sqrt(144n, rounding)).to.equal(12n); - expect(await this.mock.$sqrt(999999n, rounding)).to.equal(999n); - expect(await this.mock.$sqrt(1000000n, rounding)).to.equal(1000n); - expect(await this.mock.$sqrt(1000001n, rounding)).to.equal(1000n); - expect(await this.mock.$sqrt(1002000n, rounding)).to.equal(1000n); - expect(await this.mock.$sqrt(1002001n, rounding)).to.equal(1001n); - expect(await this.mock.$sqrt(ethers.MaxUint256, rounding)).to.equal(340282366920938463463374607431768211455n); - } - }); - - it('rounds up', async function () { - for (const rounding of RoundingUp) { - expect(await this.mock.$sqrt(0n, rounding)).to.equal(0n); - expect(await this.mock.$sqrt(1n, rounding)).to.equal(1n); - expect(await this.mock.$sqrt(2n, rounding)).to.equal(2n); - expect(await this.mock.$sqrt(3n, rounding)).to.equal(2n); - expect(await this.mock.$sqrt(4n, rounding)).to.equal(2n); - expect(await this.mock.$sqrt(144n, rounding)).to.equal(12n); - expect(await this.mock.$sqrt(999999n, rounding)).to.equal(1000n); - expect(await this.mock.$sqrt(1000000n, rounding)).to.equal(1000n); - expect(await this.mock.$sqrt(1000001n, rounding)).to.equal(1001n); - expect(await this.mock.$sqrt(1002000n, rounding)).to.equal(1001n); - expect(await this.mock.$sqrt(1002001n, rounding)).to.equal(1001n); - expect(await this.mock.$sqrt(ethers.MaxUint256, rounding)).to.equal(340282366920938463463374607431768211456n); - } - }); - }); - - describe('log', function () { - describe('log2', function () { - it('rounds down', async function () { - for (const rounding of RoundingDown) { - expect(await this.mock.$log2(0n, rounding)).to.equal(0n); - expect(await this.mock.$log2(1n, rounding)).to.equal(0n); - expect(await this.mock.$log2(2n, rounding)).to.equal(1n); - expect(await this.mock.$log2(3n, rounding)).to.equal(1n); - expect(await this.mock.$log2(4n, rounding)).to.equal(2n); - expect(await this.mock.$log2(5n, rounding)).to.equal(2n); - expect(await this.mock.$log2(6n, rounding)).to.equal(2n); - expect(await this.mock.$log2(7n, rounding)).to.equal(2n); - expect(await this.mock.$log2(8n, rounding)).to.equal(3n); - expect(await this.mock.$log2(9n, rounding)).to.equal(3n); - expect(await this.mock.$log2(ethers.MaxUint256, rounding)).to.equal(255n); - } - }); - - it('rounds up', async function () { - for (const rounding of RoundingUp) { - expect(await this.mock.$log2(0n, rounding)).to.equal(0n); - expect(await this.mock.$log2(1n, rounding)).to.equal(0n); - expect(await this.mock.$log2(2n, rounding)).to.equal(1n); - expect(await this.mock.$log2(3n, rounding)).to.equal(2n); - expect(await this.mock.$log2(4n, rounding)).to.equal(2n); - expect(await this.mock.$log2(5n, rounding)).to.equal(3n); - expect(await this.mock.$log2(6n, rounding)).to.equal(3n); - expect(await this.mock.$log2(7n, rounding)).to.equal(3n); - expect(await this.mock.$log2(8n, rounding)).to.equal(3n); - expect(await this.mock.$log2(9n, rounding)).to.equal(4n); - expect(await this.mock.$log2(ethers.MaxUint256, rounding)).to.equal(256n); - } - }); - }); - - describe('log10', function () { - it('rounds down', async function () { - for (const rounding of RoundingDown) { - expect(await this.mock.$log10(0n, rounding)).to.equal(0n); - expect(await this.mock.$log10(1n, rounding)).to.equal(0n); - expect(await this.mock.$log10(2n, rounding)).to.equal(0n); - expect(await this.mock.$log10(9n, rounding)).to.equal(0n); - expect(await this.mock.$log10(10n, rounding)).to.equal(1n); - expect(await this.mock.$log10(11n, rounding)).to.equal(1n); - expect(await this.mock.$log10(99n, rounding)).to.equal(1n); - expect(await this.mock.$log10(100n, rounding)).to.equal(2n); - expect(await this.mock.$log10(101n, rounding)).to.equal(2n); - expect(await this.mock.$log10(999n, rounding)).to.equal(2n); - expect(await this.mock.$log10(1000n, rounding)).to.equal(3n); - expect(await this.mock.$log10(1001n, rounding)).to.equal(3n); - expect(await this.mock.$log10(ethers.MaxUint256, rounding)).to.equal(77n); - } - }); - - it('rounds up', async function () { - for (const rounding of RoundingUp) { - expect(await this.mock.$log10(0n, rounding)).to.equal(0n); - expect(await this.mock.$log10(1n, rounding)).to.equal(0n); - expect(await this.mock.$log10(2n, rounding)).to.equal(1n); - expect(await this.mock.$log10(9n, rounding)).to.equal(1n); - expect(await this.mock.$log10(10n, rounding)).to.equal(1n); - expect(await this.mock.$log10(11n, rounding)).to.equal(2n); - expect(await this.mock.$log10(99n, rounding)).to.equal(2n); - expect(await this.mock.$log10(100n, rounding)).to.equal(2n); - expect(await this.mock.$log10(101n, rounding)).to.equal(3n); - expect(await this.mock.$log10(999n, rounding)).to.equal(3n); - expect(await this.mock.$log10(1000n, rounding)).to.equal(3n); - expect(await this.mock.$log10(1001n, rounding)).to.equal(4n); - expect(await this.mock.$log10(ethers.MaxUint256, rounding)).to.equal(78n); - } - }); - }); - - describe('log256', function () { - it('rounds down', async function () { - for (const rounding of RoundingDown) { - expect(await this.mock.$log256(0n, rounding)).to.equal(0n); - expect(await this.mock.$log256(1n, rounding)).to.equal(0n); - expect(await this.mock.$log256(2n, rounding)).to.equal(0n); - expect(await this.mock.$log256(255n, rounding)).to.equal(0n); - expect(await this.mock.$log256(256n, rounding)).to.equal(1n); - expect(await this.mock.$log256(257n, rounding)).to.equal(1n); - expect(await this.mock.$log256(65535n, rounding)).to.equal(1n); - expect(await this.mock.$log256(65536n, rounding)).to.equal(2n); - expect(await this.mock.$log256(65537n, rounding)).to.equal(2n); - expect(await this.mock.$log256(ethers.MaxUint256, rounding)).to.equal(31n); - } - }); - - it('rounds up', async function () { - for (const rounding of RoundingUp) { - expect(await this.mock.$log256(0n, rounding)).to.equal(0n); - expect(await this.mock.$log256(1n, rounding)).to.equal(0n); - expect(await this.mock.$log256(2n, rounding)).to.equal(1n); - expect(await this.mock.$log256(255n, rounding)).to.equal(1n); - expect(await this.mock.$log256(256n, rounding)).to.equal(1n); - expect(await this.mock.$log256(257n, rounding)).to.equal(2n); - expect(await this.mock.$log256(65535n, rounding)).to.equal(2n); - expect(await this.mock.$log256(65536n, rounding)).to.equal(2n); - expect(await this.mock.$log256(65537n, rounding)).to.equal(3n); - expect(await this.mock.$log256(ethers.MaxUint256, rounding)).to.equal(32n); - } - }); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/SafeCast.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/SafeCast.test.js deleted file mode 100644 index ab62406ce4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/SafeCast.test.js +++ /dev/null @@ -1,159 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { range } = require('../../helpers/iterate'); - -async function fixture() { - const mock = await ethers.deployContract('$SafeCast'); - return { mock }; -} - -describe('SafeCast', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - for (const bits of range(8, 256, 8).map(ethers.toBigInt)) { - const maxValue = 2n ** bits - 1n; - - describe(`toUint${bits}`, () => { - it('downcasts 0', async function () { - expect(await this.mock[`$toUint${bits}`](0n)).is.equal(0n); - }); - - it('downcasts 1', async function () { - expect(await this.mock[`$toUint${bits}`](1n)).is.equal(1n); - }); - - it(`downcasts 2^${bits} - 1 (${maxValue})`, async function () { - expect(await this.mock[`$toUint${bits}`](maxValue)).is.equal(maxValue); - }); - - it(`reverts when downcasting 2^${bits} (${maxValue + 1n})`, async function () { - await expect(this.mock[`$toUint${bits}`](maxValue + 1n)) - .to.be.revertedWithCustomError(this.mock, 'SafeCastOverflowedUintDowncast') - .withArgs(bits, maxValue + 1n); - }); - - it(`reverts when downcasting 2^${bits} + 1 (${maxValue + 2n})`, async function () { - await expect(this.mock[`$toUint${bits}`](maxValue + 2n)) - .to.be.revertedWithCustomError(this.mock, 'SafeCastOverflowedUintDowncast') - .withArgs(bits, maxValue + 2n); - }); - }); - } - - describe('toUint256', () => { - it('casts 0', async function () { - expect(await this.mock.$toUint256(0n)).is.equal(0n); - }); - - it('casts 1', async function () { - expect(await this.mock.$toUint256(1n)).is.equal(1n); - }); - - it(`casts INT256_MAX (${ethers.MaxInt256})`, async function () { - expect(await this.mock.$toUint256(ethers.MaxInt256)).is.equal(ethers.MaxInt256); - }); - - it('reverts when casting -1', async function () { - await expect(this.mock.$toUint256(-1n)) - .to.be.revertedWithCustomError(this.mock, 'SafeCastOverflowedIntToUint') - .withArgs(-1n); - }); - - it(`reverts when casting INT256_MIN (${ethers.MinInt256})`, async function () { - await expect(this.mock.$toUint256(ethers.MinInt256)) - .to.be.revertedWithCustomError(this.mock, 'SafeCastOverflowedIntToUint') - .withArgs(ethers.MinInt256); - }); - }); - - for (const bits of range(8, 256, 8).map(ethers.toBigInt)) { - const minValue = -(2n ** (bits - 1n)); - const maxValue = 2n ** (bits - 1n) - 1n; - - describe(`toInt${bits}`, () => { - it('downcasts 0', async function () { - expect(await this.mock[`$toInt${bits}`](0n)).is.equal(0n); - }); - - it('downcasts 1', async function () { - expect(await this.mock[`$toInt${bits}`](1n)).is.equal(1n); - }); - - it('downcasts -1', async function () { - expect(await this.mock[`$toInt${bits}`](-1n)).is.equal(-1n); - }); - - it(`downcasts -2^${bits - 1n} (${minValue})`, async function () { - expect(await this.mock[`$toInt${bits}`](minValue)).is.equal(minValue); - }); - - it(`downcasts 2^${bits - 1n} - 1 (${maxValue})`, async function () { - expect(await this.mock[`$toInt${bits}`](maxValue)).is.equal(maxValue); - }); - - it(`reverts when downcasting -2^${bits - 1n} - 1 (${minValue - 1n})`, async function () { - await expect(this.mock[`$toInt${bits}`](minValue - 1n)) - .to.be.revertedWithCustomError(this.mock, 'SafeCastOverflowedIntDowncast') - .withArgs(bits, minValue - 1n); - }); - - it(`reverts when downcasting -2^${bits - 1n} - 2 (${minValue - 2n})`, async function () { - await expect(this.mock[`$toInt${bits}`](minValue - 2n)) - .to.be.revertedWithCustomError(this.mock, 'SafeCastOverflowedIntDowncast') - .withArgs(bits, minValue - 2n); - }); - - it(`reverts when downcasting 2^${bits - 1n} (${maxValue + 1n})`, async function () { - await expect(this.mock[`$toInt${bits}`](maxValue + 1n)) - .to.be.revertedWithCustomError(this.mock, 'SafeCastOverflowedIntDowncast') - .withArgs(bits, maxValue + 1n); - }); - - it(`reverts when downcasting 2^${bits - 1n} + 1 (${maxValue + 2n})`, async function () { - await expect(this.mock[`$toInt${bits}`](maxValue + 2n)) - .to.be.revertedWithCustomError(this.mock, 'SafeCastOverflowedIntDowncast') - .withArgs(bits, maxValue + 2n); - }); - }); - } - - describe('toInt256', () => { - it('casts 0', async function () { - expect(await this.mock.$toInt256(0)).is.equal(0n); - }); - - it('casts 1', async function () { - expect(await this.mock.$toInt256(1)).is.equal(1n); - }); - - it(`casts INT256_MAX (${ethers.MaxInt256})`, async function () { - expect(await this.mock.$toInt256(ethers.MaxInt256)).is.equal(ethers.MaxInt256); - }); - - it(`reverts when casting INT256_MAX + 1 (${ethers.MaxInt256 + 1n})`, async function () { - await expect(this.mock.$toInt256(ethers.MaxInt256 + 1n)) - .to.be.revertedWithCustomError(this.mock, 'SafeCastOverflowedUintToInt') - .withArgs(ethers.MaxInt256 + 1n); - }); - - it(`reverts when casting UINT256_MAX (${ethers.MaxUint256})`, async function () { - await expect(this.mock.$toInt256(ethers.MaxUint256)) - .to.be.revertedWithCustomError(this.mock, 'SafeCastOverflowedUintToInt') - .withArgs(ethers.MaxUint256); - }); - }); - - describe('toUint (bool)', function () { - it('toUint(false) should be 0', async function () { - expect(await this.mock.$toUint(false)).to.equal(0n); - }); - - it('toUint(true) should be 1', async function () { - expect(await this.mock.$toUint(true)).to.equal(1n); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/SignedMath.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/SignedMath.t.sol deleted file mode 100644 index bbad109b71..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/SignedMath.t.sol +++ /dev/null @@ -1,80 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; - -import {Math} from "../../../contracts/utils/math/Math.sol"; -import {SignedMath} from "../../../contracts/utils/math/SignedMath.sol"; - -contract SignedMathTest is Test { - function testSymbolicTernary(bool f, int256 a, int256 b) public { - assertEq(SignedMath.ternary(f, a, b), f ? a : b); - } - - // MIN & MAX - function testSymbolicMinMax(int256 a, int256 b) public { - assertEq(SignedMath.min(a, b), a < b ? a : b); - assertEq(SignedMath.max(a, b), a > b ? a : b); - } - - // MIN - function testSymbolicMin(int256 a, int256 b) public { - int256 result = SignedMath.min(a, b); - - assertLe(result, a); - assertLe(result, b); - assertTrue(result == a || result == b); - } - - // MAX - function testSymbolicMax(int256 a, int256 b) public { - int256 result = SignedMath.max(a, b); - - assertGe(result, a); - assertGe(result, b); - assertTrue(result == a || result == b); - } - - // AVERAGE - // 1. simple test, not full int256 range - function testAverage1(int256 a, int256 b) public { - a = bound(a, type(int256).min / 2, type(int256).max / 2); - b = bound(b, type(int256).min / 2, type(int256).max / 2); - - int256 result = SignedMath.average(a, b); - - assertEq(result, (a + b) / 2); - } - - // 2. more complex test, full int256 range - function testAverage2(int256 a, int256 b) public { - (int256 result, int256 min, int256 max) = ( - SignedMath.average(a, b), - SignedMath.min(a, b), - SignedMath.max(a, b) - ); - - // average must be between `a` and `b` - assertGe(result, min); - assertLe(result, max); - - unchecked { - // must be unchecked in order to support `a = type(int256).min, b = type(int256).max` - uint256 deltaLower = uint256(result - min); - uint256 deltaUpper = uint256(max - result); - uint256 remainder = uint256((a & 1) ^ (b & 1)); - assertEq(remainder, Math.max(deltaLower, deltaUpper) - Math.min(deltaLower, deltaUpper)); - } - } - - // ABS - function testSymbolicAbs(int256 a) public { - uint256 result = SignedMath.abs(a); - - unchecked { - // must be unchecked in order to support `n = type(int256).min` - assertEq(result, a < 0 ? uint256(-a) : uint256(a)); - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/SignedMath.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/SignedMath.test.js deleted file mode 100644 index 877f3b480c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/math/SignedMath.test.js +++ /dev/null @@ -1,53 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { min, max } = require('../../helpers/math'); - -async function testCommutative(fn, lhs, rhs, expected, ...extra) { - expect(await fn(lhs, rhs, ...extra)).to.deep.equal(expected); - expect(await fn(rhs, lhs, ...extra)).to.deep.equal(expected); -} - -async function fixture() { - const mock = await ethers.deployContract('$SignedMath'); - return { mock }; -} - -describe('SignedMath', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('max', function () { - it('is correctly detected in both position', async function () { - await testCommutative(this.mock.$max, -1234n, 5678n, max(-1234n, 5678n)); - }); - }); - - describe('min', function () { - it('is correctly detected in both position', async function () { - await testCommutative(this.mock.$min, -1234n, 5678n, min(-1234n, 5678n)); - }); - }); - - describe('average', function () { - it('is correctly calculated with various input', async function () { - for (const x of [ethers.MinInt256, -57417n, -42304n, -4n, -3n, 0n, 3n, 4n, 42304n, 57417n, ethers.MaxInt256]) { - for (const y of [ethers.MinInt256, -57417n, -42304n, -5n, -2n, 0n, 2n, 5n, 42304n, 57417n, ethers.MaxInt256]) { - expect(await this.mock.$average(x, y)).to.equal((x + y) / 2n); - } - } - }); - }); - - describe('abs', function () { - const abs = x => (x < 0n ? -x : x); - - for (const n of [ethers.MinInt256, ethers.MinInt256 + 1n, -1n, 0n, 1n, ethers.MaxInt256 - 1n, ethers.MaxInt256]) { - it(`correctly computes the absolute value of ${n}`, async function () { - expect(await this.mock.$abs(n)).to.equal(abs(n)); - }); - } - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/BitMap.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/BitMap.test.js deleted file mode 100644 index 5662ab13f8..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/BitMap.test.js +++ /dev/null @@ -1,149 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -async function fixture() { - const bitmap = await ethers.deployContract('$BitMaps'); - return { bitmap }; -} - -describe('BitMap', function () { - const keyA = 7891n; - const keyB = 451n; - const keyC = 9592328n; - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('starts empty', async function () { - expect(await this.bitmap.$get(0, keyA)).to.be.false; - expect(await this.bitmap.$get(0, keyB)).to.be.false; - expect(await this.bitmap.$get(0, keyC)).to.be.false; - }); - - describe('setTo', function () { - it('set a key to true', async function () { - await this.bitmap.$setTo(0, keyA, true); - expect(await this.bitmap.$get(0, keyA)).to.be.true; - expect(await this.bitmap.$get(0, keyB)).to.be.false; - expect(await this.bitmap.$get(0, keyC)).to.be.false; - }); - - it('set a key to false', async function () { - await this.bitmap.$setTo(0, keyA, true); - await this.bitmap.$setTo(0, keyA, false); - expect(await this.bitmap.$get(0, keyA)).to.be.false; - expect(await this.bitmap.$get(0, keyB)).to.be.false; - expect(await this.bitmap.$get(0, keyC)).to.be.false; - }); - - it('set several consecutive keys', async function () { - await this.bitmap.$setTo(0, keyA + 0n, true); - await this.bitmap.$setTo(0, keyA + 1n, true); - await this.bitmap.$setTo(0, keyA + 2n, true); - await this.bitmap.$setTo(0, keyA + 3n, true); - await this.bitmap.$setTo(0, keyA + 4n, true); - await this.bitmap.$setTo(0, keyA + 2n, false); - await this.bitmap.$setTo(0, keyA + 4n, false); - expect(await this.bitmap.$get(0, keyA + 0n)).to.be.true; - expect(await this.bitmap.$get(0, keyA + 1n)).to.be.true; - expect(await this.bitmap.$get(0, keyA + 2n)).to.be.false; - expect(await this.bitmap.$get(0, keyA + 3n)).to.be.true; - expect(await this.bitmap.$get(0, keyA + 4n)).to.be.false; - }); - }); - - describe('set', function () { - it('adds a key', async function () { - await this.bitmap.$set(0, keyA); - expect(await this.bitmap.$get(0, keyA)).to.be.true; - expect(await this.bitmap.$get(0, keyB)).to.be.false; - expect(await this.bitmap.$get(0, keyC)).to.be.false; - }); - - it('adds several keys', async function () { - await this.bitmap.$set(0, keyA); - await this.bitmap.$set(0, keyB); - expect(await this.bitmap.$get(0, keyA)).to.be.true; - expect(await this.bitmap.$get(0, keyB)).to.be.true; - expect(await this.bitmap.$get(0, keyC)).to.be.false; - }); - - it('adds several consecutive keys', async function () { - await this.bitmap.$set(0, keyA + 0n); - await this.bitmap.$set(0, keyA + 1n); - await this.bitmap.$set(0, keyA + 3n); - expect(await this.bitmap.$get(0, keyA + 0n)).to.be.true; - expect(await this.bitmap.$get(0, keyA + 1n)).to.be.true; - expect(await this.bitmap.$get(0, keyA + 2n)).to.be.false; - expect(await this.bitmap.$get(0, keyA + 3n)).to.be.true; - expect(await this.bitmap.$get(0, keyA + 4n)).to.be.false; - }); - }); - - describe('unset', function () { - it('removes added keys', async function () { - await this.bitmap.$set(0, keyA); - await this.bitmap.$set(0, keyB); - await this.bitmap.$unset(0, keyA); - expect(await this.bitmap.$get(0, keyA)).to.be.false; - expect(await this.bitmap.$get(0, keyB)).to.be.true; - expect(await this.bitmap.$get(0, keyC)).to.be.false; - }); - - it('removes consecutive added keys', async function () { - await this.bitmap.$set(0, keyA + 0n); - await this.bitmap.$set(0, keyA + 1n); - await this.bitmap.$set(0, keyA + 3n); - await this.bitmap.$unset(0, keyA + 1n); - expect(await this.bitmap.$get(0, keyA + 0n)).to.be.true; - expect(await this.bitmap.$get(0, keyA + 1n)).to.be.false; - expect(await this.bitmap.$get(0, keyA + 2n)).to.be.false; - expect(await this.bitmap.$get(0, keyA + 3n)).to.be.true; - expect(await this.bitmap.$get(0, keyA + 4n)).to.be.false; - }); - - it('adds and removes multiple keys', async function () { - // [] - - await this.bitmap.$set(0, keyA); - await this.bitmap.$set(0, keyC); - - // [A, C] - - await this.bitmap.$unset(0, keyA); - await this.bitmap.$unset(0, keyB); - - // [C] - - await this.bitmap.$set(0, keyB); - - // [C, B] - - await this.bitmap.$set(0, keyA); - await this.bitmap.$unset(0, keyC); - - // [A, B] - - await this.bitmap.$set(0, keyA); - await this.bitmap.$set(0, keyB); - - // [A, B] - - await this.bitmap.$set(0, keyC); - await this.bitmap.$unset(0, keyA); - - // [B, C] - - await this.bitmap.$set(0, keyA); - await this.bitmap.$unset(0, keyB); - - // [A, C] - - expect(await this.bitmap.$get(0, keyA)).to.be.true; - expect(await this.bitmap.$get(0, keyB)).to.be.false; - expect(await this.bitmap.$get(0, keyC)).to.be.true; - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/Checkpoints.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/Checkpoints.t.sol deleted file mode 100644 index 1f4b344c57..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/Checkpoints.t.sol +++ /dev/null @@ -1,332 +0,0 @@ -// SPDX-License-Identifier: MIT -// This file was procedurally generated from scripts/generate/templates/Checkpoints.t.js. - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {SafeCast} from "@openzeppelin/contracts/utils/math/SafeCast.sol"; -import {Checkpoints} from "@openzeppelin/contracts/utils/structs/Checkpoints.sol"; - -contract CheckpointsTrace224Test is Test { - using Checkpoints for Checkpoints.Trace224; - - // Maximum gap between keys used during the fuzzing tests: the `_prepareKeys` function with make sure that - // key#n+1 is in the [key#n, key#n + _KEY_MAX_GAP] range. - uint8 internal constant _KEY_MAX_GAP = 64; - - Checkpoints.Trace224 internal _ckpts; - - // helpers - function _boundUint32(uint32 x, uint32 min, uint32 max) internal pure returns (uint32) { - return SafeCast.toUint32(bound(uint256(x), uint256(min), uint256(max))); - } - - function _prepareKeys(uint32[] memory keys, uint32 maxSpread) internal pure { - uint32 lastKey = 0; - for (uint256 i = 0; i < keys.length; ++i) { - uint32 key = _boundUint32(keys[i], lastKey, lastKey + maxSpread); - keys[i] = key; - lastKey = key; - } - } - - function _assertLatestCheckpoint(bool exist, uint32 key, uint224 value) internal { - (bool _exist, uint32 _key, uint224 _value) = _ckpts.latestCheckpoint(); - assertEq(_exist, exist); - assertEq(_key, key); - assertEq(_value, value); - } - - // tests - function testPush(uint32[] memory keys, uint224[] memory values, uint32 pastKey) public { - vm.assume(values.length > 0 && values.length <= keys.length); - _prepareKeys(keys, _KEY_MAX_GAP); - - // initial state - assertEq(_ckpts.length(), 0); - assertEq(_ckpts.latest(), 0); - _assertLatestCheckpoint(false, 0, 0); - - uint256 duplicates = 0; - for (uint256 i = 0; i < keys.length; ++i) { - uint32 key = keys[i]; - uint224 value = values[i % values.length]; - if (i > 0 && key == keys[i - 1]) ++duplicates; - - // push - _ckpts.push(key, value); - - // check length & latest - assertEq(_ckpts.length(), i + 1 - duplicates); - assertEq(_ckpts.latest(), value); - _assertLatestCheckpoint(true, key, value); - } - - if (keys.length > 0) { - uint32 lastKey = keys[keys.length - 1]; - if (lastKey > 0) { - pastKey = _boundUint32(pastKey, 0, lastKey - 1); - - vm.expectRevert(); - this.push(pastKey, values[keys.length % values.length]); - } - } - } - - // used to test reverts - function push(uint32 key, uint224 value) external { - _ckpts.push(key, value); - } - - function testLookup(uint32[] memory keys, uint224[] memory values, uint32 lookup) public { - vm.assume(values.length > 0 && values.length <= keys.length); - _prepareKeys(keys, _KEY_MAX_GAP); - - uint32 lastKey = keys.length == 0 ? 0 : keys[keys.length - 1]; - lookup = _boundUint32(lookup, 0, lastKey + _KEY_MAX_GAP); - - uint224 upper = 0; - uint224 lower = 0; - uint32 lowerKey = type(uint32).max; - for (uint256 i = 0; i < keys.length; ++i) { - uint32 key = keys[i]; - uint224 value = values[i % values.length]; - - // push - _ckpts.push(key, value); - - // track expected result of lookups - if (key <= lookup) { - upper = value; - } - // find the first key that is not smaller than the lookup key - if (key >= lookup && (i == 0 || keys[i - 1] < lookup)) { - lowerKey = key; - } - if (key == lowerKey) { - lower = value; - } - } - - // check lookup - assertEq(_ckpts.lowerLookup(lookup), lower); - assertEq(_ckpts.upperLookup(lookup), upper); - assertEq(_ckpts.upperLookupRecent(lookup), upper); - } -} - -contract CheckpointsTrace208Test is Test { - using Checkpoints for Checkpoints.Trace208; - - // Maximum gap between keys used during the fuzzing tests: the `_prepareKeys` function with make sure that - // key#n+1 is in the [key#n, key#n + _KEY_MAX_GAP] range. - uint8 internal constant _KEY_MAX_GAP = 64; - - Checkpoints.Trace208 internal _ckpts; - - // helpers - function _boundUint48(uint48 x, uint48 min, uint48 max) internal pure returns (uint48) { - return SafeCast.toUint48(bound(uint256(x), uint256(min), uint256(max))); - } - - function _prepareKeys(uint48[] memory keys, uint48 maxSpread) internal pure { - uint48 lastKey = 0; - for (uint256 i = 0; i < keys.length; ++i) { - uint48 key = _boundUint48(keys[i], lastKey, lastKey + maxSpread); - keys[i] = key; - lastKey = key; - } - } - - function _assertLatestCheckpoint(bool exist, uint48 key, uint208 value) internal { - (bool _exist, uint48 _key, uint208 _value) = _ckpts.latestCheckpoint(); - assertEq(_exist, exist); - assertEq(_key, key); - assertEq(_value, value); - } - - // tests - function testPush(uint48[] memory keys, uint208[] memory values, uint48 pastKey) public { - vm.assume(values.length > 0 && values.length <= keys.length); - _prepareKeys(keys, _KEY_MAX_GAP); - - // initial state - assertEq(_ckpts.length(), 0); - assertEq(_ckpts.latest(), 0); - _assertLatestCheckpoint(false, 0, 0); - - uint256 duplicates = 0; - for (uint256 i = 0; i < keys.length; ++i) { - uint48 key = keys[i]; - uint208 value = values[i % values.length]; - if (i > 0 && key == keys[i - 1]) ++duplicates; - - // push - _ckpts.push(key, value); - - // check length & latest - assertEq(_ckpts.length(), i + 1 - duplicates); - assertEq(_ckpts.latest(), value); - _assertLatestCheckpoint(true, key, value); - } - - if (keys.length > 0) { - uint48 lastKey = keys[keys.length - 1]; - if (lastKey > 0) { - pastKey = _boundUint48(pastKey, 0, lastKey - 1); - - vm.expectRevert(); - this.push(pastKey, values[keys.length % values.length]); - } - } - } - - // used to test reverts - function push(uint48 key, uint208 value) external { - _ckpts.push(key, value); - } - - function testLookup(uint48[] memory keys, uint208[] memory values, uint48 lookup) public { - vm.assume(values.length > 0 && values.length <= keys.length); - _prepareKeys(keys, _KEY_MAX_GAP); - - uint48 lastKey = keys.length == 0 ? 0 : keys[keys.length - 1]; - lookup = _boundUint48(lookup, 0, lastKey + _KEY_MAX_GAP); - - uint208 upper = 0; - uint208 lower = 0; - uint48 lowerKey = type(uint48).max; - for (uint256 i = 0; i < keys.length; ++i) { - uint48 key = keys[i]; - uint208 value = values[i % values.length]; - - // push - _ckpts.push(key, value); - - // track expected result of lookups - if (key <= lookup) { - upper = value; - } - // find the first key that is not smaller than the lookup key - if (key >= lookup && (i == 0 || keys[i - 1] < lookup)) { - lowerKey = key; - } - if (key == lowerKey) { - lower = value; - } - } - - // check lookup - assertEq(_ckpts.lowerLookup(lookup), lower); - assertEq(_ckpts.upperLookup(lookup), upper); - assertEq(_ckpts.upperLookupRecent(lookup), upper); - } -} - -contract CheckpointsTrace160Test is Test { - using Checkpoints for Checkpoints.Trace160; - - // Maximum gap between keys used during the fuzzing tests: the `_prepareKeys` function with make sure that - // key#n+1 is in the [key#n, key#n + _KEY_MAX_GAP] range. - uint8 internal constant _KEY_MAX_GAP = 64; - - Checkpoints.Trace160 internal _ckpts; - - // helpers - function _boundUint96(uint96 x, uint96 min, uint96 max) internal pure returns (uint96) { - return SafeCast.toUint96(bound(uint256(x), uint256(min), uint256(max))); - } - - function _prepareKeys(uint96[] memory keys, uint96 maxSpread) internal pure { - uint96 lastKey = 0; - for (uint256 i = 0; i < keys.length; ++i) { - uint96 key = _boundUint96(keys[i], lastKey, lastKey + maxSpread); - keys[i] = key; - lastKey = key; - } - } - - function _assertLatestCheckpoint(bool exist, uint96 key, uint160 value) internal { - (bool _exist, uint96 _key, uint160 _value) = _ckpts.latestCheckpoint(); - assertEq(_exist, exist); - assertEq(_key, key); - assertEq(_value, value); - } - - // tests - function testPush(uint96[] memory keys, uint160[] memory values, uint96 pastKey) public { - vm.assume(values.length > 0 && values.length <= keys.length); - _prepareKeys(keys, _KEY_MAX_GAP); - - // initial state - assertEq(_ckpts.length(), 0); - assertEq(_ckpts.latest(), 0); - _assertLatestCheckpoint(false, 0, 0); - - uint256 duplicates = 0; - for (uint256 i = 0; i < keys.length; ++i) { - uint96 key = keys[i]; - uint160 value = values[i % values.length]; - if (i > 0 && key == keys[i - 1]) ++duplicates; - - // push - _ckpts.push(key, value); - - // check length & latest - assertEq(_ckpts.length(), i + 1 - duplicates); - assertEq(_ckpts.latest(), value); - _assertLatestCheckpoint(true, key, value); - } - - if (keys.length > 0) { - uint96 lastKey = keys[keys.length - 1]; - if (lastKey > 0) { - pastKey = _boundUint96(pastKey, 0, lastKey - 1); - - vm.expectRevert(); - this.push(pastKey, values[keys.length % values.length]); - } - } - } - - // used to test reverts - function push(uint96 key, uint160 value) external { - _ckpts.push(key, value); - } - - function testLookup(uint96[] memory keys, uint160[] memory values, uint96 lookup) public { - vm.assume(values.length > 0 && values.length <= keys.length); - _prepareKeys(keys, _KEY_MAX_GAP); - - uint96 lastKey = keys.length == 0 ? 0 : keys[keys.length - 1]; - lookup = _boundUint96(lookup, 0, lastKey + _KEY_MAX_GAP); - - uint160 upper = 0; - uint160 lower = 0; - uint96 lowerKey = type(uint96).max; - for (uint256 i = 0; i < keys.length; ++i) { - uint96 key = keys[i]; - uint160 value = values[i % values.length]; - - // push - _ckpts.push(key, value); - - // track expected result of lookups - if (key <= lookup) { - upper = value; - } - // find the first key that is not smaller than the lookup key - if (key >= lookup && (i == 0 || keys[i - 1] < lookup)) { - lowerKey = key; - } - if (key == lowerKey) { - lower = value; - } - } - - // check lookup - assertEq(_ckpts.lowerLookup(lookup), lower); - assertEq(_ckpts.upperLookup(lookup), upper); - assertEq(_ckpts.upperLookupRecent(lookup), upper); - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/Checkpoints.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/Checkpoints.test.js deleted file mode 100644 index fd22544b95..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/Checkpoints.test.js +++ /dev/null @@ -1,146 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { VALUE_SIZES } = require('../../../scripts/generate/templates/Checkpoints.opts'); - -describe('Checkpoints', function () { - for (const length of VALUE_SIZES) { - describe(`Trace${length}`, function () { - const fixture = async () => { - const mock = await ethers.deployContract('$Checkpoints'); - const methods = { - at: (...args) => mock.getFunction(`$at_Checkpoints_Trace${length}`)(0, ...args), - latest: (...args) => mock.getFunction(`$latest_Checkpoints_Trace${length}`)(0, ...args), - latestCheckpoint: (...args) => mock.getFunction(`$latestCheckpoint_Checkpoints_Trace${length}`)(0, ...args), - length: (...args) => mock.getFunction(`$length_Checkpoints_Trace${length}`)(0, ...args), - push: (...args) => mock.getFunction(`$push(uint256,uint${256 - length},uint${length})`)(0, ...args), - lowerLookup: (...args) => mock.getFunction(`$lowerLookup(uint256,uint${256 - length})`)(0, ...args), - upperLookup: (...args) => mock.getFunction(`$upperLookup(uint256,uint${256 - length})`)(0, ...args), - upperLookupRecent: (...args) => - mock.getFunction(`$upperLookupRecent(uint256,uint${256 - length})`)(0, ...args), - }; - - return { mock, methods }; - }; - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('without checkpoints', function () { - it('at zero reverts', async function () { - // Reverts with array out of bound access, which is unspecified - await expect(this.methods.at(0)).to.be.reverted; - }); - - it('returns zero as latest value', async function () { - expect(await this.methods.latest()).to.equal(0n); - - const ckpt = await this.methods.latestCheckpoint(); - expect(ckpt[0]).to.be.false; - expect(ckpt[1]).to.equal(0n); - expect(ckpt[2]).to.equal(0n); - }); - - it('lookup returns 0', async function () { - expect(await this.methods.lowerLookup(0)).to.equal(0n); - expect(await this.methods.upperLookup(0)).to.equal(0n); - expect(await this.methods.upperLookupRecent(0)).to.equal(0n); - }); - }); - - describe('with checkpoints', function () { - beforeEach('pushing checkpoints', async function () { - this.checkpoints = [ - { key: 2n, value: 17n }, - { key: 3n, value: 42n }, - { key: 5n, value: 101n }, - { key: 7n, value: 23n }, - { key: 11n, value: 99n }, - ]; - for (const { key, value } of this.checkpoints) { - await this.methods.push(key, value); - } - }); - - it('at keys', async function () { - for (const [index, { key, value }] of this.checkpoints.entries()) { - const at = await this.methods.at(index); - expect(at._value).to.equal(value); - expect(at._key).to.equal(key); - } - }); - - it('length', async function () { - expect(await this.methods.length()).to.equal(this.checkpoints.length); - }); - - it('returns latest value', async function () { - const latest = this.checkpoints.at(-1); - expect(await this.methods.latest()).to.equal(latest.value); - expect(await this.methods.latestCheckpoint()).to.deep.equal([true, latest.key, latest.value]); - }); - - it('cannot push values in the past', async function () { - await expect(this.methods.push(this.checkpoints.at(-1).key - 1n, 0n)).to.be.revertedWithCustomError( - this.mock, - 'CheckpointUnorderedInsertion', - ); - }); - - it('can update last value', async function () { - const newValue = 42n; - - // check length before the update - expect(await this.methods.length()).to.equal(this.checkpoints.length); - - // update last key - await this.methods.push(this.checkpoints.at(-1).key, newValue); - expect(await this.methods.latest()).to.equal(newValue); - - // check that length did not change - expect(await this.methods.length()).to.equal(this.checkpoints.length); - }); - - it('lower lookup', async function () { - for (let i = 0; i < 14; ++i) { - const value = this.checkpoints.find(x => i <= x.key)?.value || 0n; - - expect(await this.methods.lowerLookup(i)).to.equal(value); - } - }); - - it('upper lookup & upperLookupRecent', async function () { - for (let i = 0; i < 14; ++i) { - const value = this.checkpoints.findLast(x => i >= x.key)?.value || 0n; - - expect(await this.methods.upperLookup(i)).to.equal(value); - expect(await this.methods.upperLookupRecent(i)).to.equal(value); - } - }); - - it('upperLookupRecent with more than 5 checkpoints', async function () { - const moreCheckpoints = [ - { key: 12n, value: 22n }, - { key: 13n, value: 131n }, - { key: 17n, value: 45n }, - { key: 19n, value: 31452n }, - { key: 21n, value: 0n }, - ]; - const allCheckpoints = [].concat(this.checkpoints, moreCheckpoints); - - for (const { key, value } of moreCheckpoints) { - await this.methods.push(key, value); - } - - for (let i = 0; i < 25; ++i) { - const value = allCheckpoints.findLast(x => i >= x.key)?.value || 0n; - expect(await this.methods.upperLookup(i)).to.equal(value); - expect(await this.methods.upperLookupRecent(i)).to.equal(value); - } - }); - }); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/CircularBuffer.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/CircularBuffer.test.js deleted file mode 100644 index e79ba6923b..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/CircularBuffer.test.js +++ /dev/null @@ -1,83 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -const { generators } = require('../../helpers/random'); - -const LENGTH = 4; - -async function fixture() { - const mock = await ethers.deployContract('$CircularBuffer'); - await mock.$setup(0, LENGTH); - return { mock }; -} - -describe('CircularBuffer', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('reverts on invalid setup', async function () { - await expect(this.mock.$setup(0, 0)).to.be.revertedWithCustomError(this.mock, 'InvalidBufferSize'); - }); - - it('starts empty', async function () { - expect(await this.mock.$count(0)).to.equal(0n); - expect(await this.mock.$length(0)).to.equal(LENGTH); - expect(await this.mock.$includes(0, ethers.ZeroHash)).to.be.false; - await expect(this.mock.$last(0, 0)).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - }); - - it('push', async function () { - const values = Array.from({ length: LENGTH + 3 }, generators.bytes32); - - for (const [i, value] of values.map((v, i) => [i, v])) { - // push value - await this.mock.$push(0, value); - - // view of the values - const pushed = values.slice(0, i + 1); - const stored = pushed.slice(-LENGTH); - const dropped = pushed.slice(0, -LENGTH); - - // check count - expect(await this.mock.$length(0)).to.equal(LENGTH); - expect(await this.mock.$count(0)).to.equal(stored.length); - - // check last - for (const j in stored) { - expect(await this.mock.$last(0, j)).to.equal(stored.at(-j - 1)); - } - await expect(this.mock.$last(0, stored.length + 1)).to.be.revertedWithPanic( - PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS, - ); - - // check included and non-included values - for (const v of stored) { - expect(await this.mock.$includes(0, v)).to.be.true; - } - for (const v of dropped) { - expect(await this.mock.$includes(0, v)).to.be.false; - } - expect(await this.mock.$includes(0, ethers.ZeroHash)).to.be.false; - } - }); - - it('clear', async function () { - const value = generators.bytes32(); - await this.mock.$push(0, value); - - expect(await this.mock.$count(0)).to.equal(1n); - expect(await this.mock.$length(0)).to.equal(LENGTH); - expect(await this.mock.$includes(0, value)).to.be.true; - await this.mock.$last(0, 0); // not revert - - await this.mock.$clear(0); - - expect(await this.mock.$count(0)).to.equal(0n); - expect(await this.mock.$length(0)).to.equal(LENGTH); - expect(await this.mock.$includes(0, value)).to.be.false; - await expect(this.mock.$last(0, 0)).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/DoubleEndedQueue.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/DoubleEndedQueue.test.js deleted file mode 100644 index 3615dfbf48..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/DoubleEndedQueue.test.js +++ /dev/null @@ -1,102 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -async function fixture() { - const mock = await ethers.deployContract('$DoubleEndedQueue'); - - /** Rebuild the content of the deque as a JS array. */ - const getContent = () => - mock.$length(0).then(length => Promise.all(Array.from({ length: Number(length) }, (_, i) => mock.$at(0, i)))); - - return { mock, getContent }; -} - -describe('DoubleEndedQueue', function () { - const coder = ethers.AbiCoder.defaultAbiCoder(); - const bytesA = coder.encode(['uint256'], [0xdeadbeef]); - const bytesB = coder.encode(['uint256'], [0x0123456789]); - const bytesC = coder.encode(['uint256'], [0x42424242]); - const bytesD = coder.encode(['uint256'], [0x171717]); - - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('when empty', function () { - it('getters', async function () { - expect(await this.mock.$empty(0)).to.be.true; - expect(await this.getContent()).to.have.ordered.members([]); - }); - - it('reverts on accesses', async function () { - await expect(this.mock.$popBack(0)).to.be.revertedWithPanic(PANIC_CODES.POP_ON_EMPTY_ARRAY); - await expect(this.mock.$popFront(0)).to.be.revertedWithPanic(PANIC_CODES.POP_ON_EMPTY_ARRAY); - await expect(this.mock.$back(0)).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - await expect(this.mock.$front(0)).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - }); - }); - - describe('when not empty', function () { - beforeEach(async function () { - await this.mock.$pushBack(0, bytesB); - await this.mock.$pushFront(0, bytesA); - await this.mock.$pushBack(0, bytesC); - this.content = [bytesA, bytesB, bytesC]; - }); - - it('getters', async function () { - expect(await this.mock.$empty(0)).to.be.false; - expect(await this.mock.$length(0)).to.equal(this.content.length); - expect(await this.mock.$front(0)).to.equal(this.content[0]); - expect(await this.mock.$back(0)).to.equal(this.content[this.content.length - 1]); - expect(await this.getContent()).to.have.ordered.members(this.content); - }); - - it('out of bounds access', async function () { - await expect(this.mock.$at(0, this.content.length)).to.be.revertedWithPanic( - PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS, - ); - }); - - describe('push', function () { - it('front', async function () { - await this.mock.$pushFront(0, bytesD); - this.content.unshift(bytesD); // add element at the beginning - - expect(await this.getContent()).to.have.ordered.members(this.content); - }); - - it('back', async function () { - await this.mock.$pushBack(0, bytesD); - this.content.push(bytesD); // add element at the end - - expect(await this.getContent()).to.have.ordered.members(this.content); - }); - }); - - describe('pop', function () { - it('front', async function () { - const value = this.content.shift(); // remove first element - await expect(this.mock.$popFront(0)).to.emit(this.mock, 'return$popFront').withArgs(value); - - expect(await this.getContent()).to.have.ordered.members(this.content); - }); - - it('back', async function () { - const value = this.content.pop(); // remove last element - await expect(this.mock.$popBack(0)).to.emit(this.mock, 'return$popBack').withArgs(value); - - expect(await this.getContent()).to.have.ordered.members(this.content); - }); - }); - - it('clear', async function () { - await this.mock.$clear(0); - - expect(await this.mock.$empty(0)).to.be.true; - expect(await this.getContent()).to.have.ordered.members([]); - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/EnumerableMap.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/EnumerableMap.behavior.js deleted file mode 100644 index 37da41795d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/EnumerableMap.behavior.js +++ /dev/null @@ -1,151 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); - -const zip = (array1, array2) => array1.map((item, index) => [item, array2[index]]); - -function shouldBehaveLikeMap() { - async function expectMembersMatch(methods, keys, values) { - expect(keys.length).to.equal(values.length); - expect(await methods.length()).to.equal(keys.length); - expect([...(await methods.keys())]).to.have.members(keys); - - for (const [key, value] of zip(keys, values)) { - expect(await methods.contains(key)).to.be.true; - expect(await methods.get(key)).to.equal(value); - } - - expect(await Promise.all(keys.map((_, index) => methods.at(index)))).to.have.deep.members(zip(keys, values)); - } - - it('starts empty', async function () { - expect(await this.methods.contains(this.keyA)).to.be.false; - - await expectMembersMatch(this.methods, [], []); - }); - - describe('set', function () { - it('adds a key', async function () { - await expect(this.methods.set(this.keyA, this.valueA)).to.emit(this.mock, this.events.setReturn).withArgs(true); - - await expectMembersMatch(this.methods, [this.keyA], [this.valueA]); - }); - - it('adds several keys', async function () { - await this.methods.set(this.keyA, this.valueA); - await this.methods.set(this.keyB, this.valueB); - - await expectMembersMatch(this.methods, [this.keyA, this.keyB], [this.valueA, this.valueB]); - expect(await this.methods.contains(this.keyC)).to.be.false; - }); - - it('returns false when adding keys already in the set', async function () { - await this.methods.set(this.keyA, this.valueA); - - await expect(this.methods.set(this.keyA, this.valueA)).to.emit(this.mock, this.events.setReturn).withArgs(false); - - await expectMembersMatch(this.methods, [this.keyA], [this.valueA]); - }); - - it('updates values for keys already in the set', async function () { - await this.methods.set(this.keyA, this.valueA); - await this.methods.set(this.keyA, this.valueB); - - await expectMembersMatch(this.methods, [this.keyA], [this.valueB]); - }); - }); - - describe('remove', function () { - it('removes added keys', async function () { - await this.methods.set(this.keyA, this.valueA); - - await expect(this.methods.remove(this.keyA)).to.emit(this.mock, this.events.removeReturn).withArgs(true); - - expect(await this.methods.contains(this.keyA)).to.be.false; - await expectMembersMatch(this.methods, [], []); - }); - - it('returns false when removing keys not in the set', async function () { - await expect(await this.methods.remove(this.keyA)) - .to.emit(this.mock, this.events.removeReturn) - .withArgs(false); - - expect(await this.methods.contains(this.keyA)).to.be.false; - }); - - it('adds and removes multiple keys', async function () { - // [] - - await this.methods.set(this.keyA, this.valueA); - await this.methods.set(this.keyC, this.valueC); - - // [A, C] - - await this.methods.remove(this.keyA); - await this.methods.remove(this.keyB); - - // [C] - - await this.methods.set(this.keyB, this.valueB); - - // [C, B] - - await this.methods.set(this.keyA, this.valueA); - await this.methods.remove(this.keyC); - - // [A, B] - - await this.methods.set(this.keyA, this.valueA); - await this.methods.set(this.keyB, this.valueB); - - // [A, B] - - await this.methods.set(this.keyC, this.valueC); - await this.methods.remove(this.keyA); - - // [B, C] - - await this.methods.set(this.keyA, this.valueA); - await this.methods.remove(this.keyB); - - // [A, C] - - await expectMembersMatch(this.methods, [this.keyA, this.keyC], [this.valueA, this.valueC]); - - expect(await this.methods.contains(this.keyA)).to.be.true; - expect(await this.methods.contains(this.keyB)).to.be.false; - expect(await this.methods.contains(this.keyC)).to.be.true; - }); - }); - - describe('read', function () { - beforeEach(async function () { - await this.methods.set(this.keyA, this.valueA); - }); - - describe('get', function () { - it('existing value', async function () { - expect(await this.methods.get(this.keyA)).to.equal(this.valueA); - }); - - it('missing value', async function () { - await expect(this.methods.get(this.keyB)) - .to.be.revertedWithCustomError(this.mock, 'EnumerableMapNonexistentKey') - .withArgs(ethers.AbiCoder.defaultAbiCoder().encode([this.keyType], [this.keyB])); - }); - }); - - describe('tryGet', function () { - it('existing value', async function () { - expect(await this.methods.tryGet(this.keyA)).to.have.ordered.members([true, this.valueA]); - }); - - it('missing value', async function () { - expect(await this.methods.tryGet(this.keyB)).to.have.ordered.members([false, this.zeroValue]); - }); - }); - }); -} - -module.exports = { - shouldBehaveLikeMap, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/EnumerableMap.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/EnumerableMap.test.js deleted file mode 100644 index 5362e873aa..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/EnumerableMap.test.js +++ /dev/null @@ -1,65 +0,0 @@ -const { ethers } = require('hardhat'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { mapValues } = require('../../helpers/iterate'); -const { generators } = require('../../helpers/random'); -const { TYPES, formatType } = require('../../../scripts/generate/templates/EnumerableMap.opts'); - -const { shouldBehaveLikeMap } = require('./EnumerableMap.behavior'); - -// Add Bytes32ToBytes32Map that must be tested but is not part of the generated types. -TYPES.unshift(formatType('bytes32', 'bytes32')); - -async function fixture() { - const mock = await ethers.deployContract('$EnumerableMap'); - const env = Object.fromEntries( - TYPES.map(({ name, keyType, valueType }) => [ - name, - { - keyType, - keys: Array.from({ length: 3 }, generators[keyType]), - values: Array.from({ length: 3 }, generators[valueType]), - zeroValue: generators[valueType].zero, - methods: mapValues( - { - set: `$set(uint256,${keyType},${valueType})`, - get: `$get_EnumerableMap_${name}(uint256,${keyType})`, - tryGet: `$tryGet_EnumerableMap_${name}(uint256,${keyType})`, - remove: `$remove_EnumerableMap_${name}(uint256,${keyType})`, - length: `$length_EnumerableMap_${name}(uint256)`, - at: `$at_EnumerableMap_${name}(uint256,uint256)`, - contains: `$contains_EnumerableMap_${name}(uint256,${keyType})`, - keys: `$keys_EnumerableMap_${name}(uint256)`, - }, - fnSig => - (...args) => - mock.getFunction(fnSig)(0, ...args), - ), - events: { - setReturn: `return$set_EnumerableMap_${name}_${keyType}_${valueType}`, - removeReturn: `return$remove_EnumerableMap_${name}_${keyType}`, - }, - }, - ]), - ); - - return { mock, env }; -} - -describe('EnumerableMap', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - for (const { name } of TYPES) { - describe(name, function () { - beforeEach(async function () { - Object.assign(this, this.env[name]); - [this.keyA, this.keyB, this.keyC] = this.keys; - [this.valueA, this.valueB, this.valueC] = this.values; - }); - - shouldBehaveLikeMap(); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/EnumerableSet.behavior.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/EnumerableSet.behavior.js deleted file mode 100644 index d3d4f26d58..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/EnumerableSet.behavior.js +++ /dev/null @@ -1,116 +0,0 @@ -const { expect } = require('chai'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -function shouldBehaveLikeSet() { - async function expectMembersMatch(methods, values) { - expect(await methods.length()).to.equal(values.length); - for (const value of values) expect(await methods.contains(value)).to.be.true; - - expect(await Promise.all(values.map((_, index) => methods.at(index)))).to.have.deep.members(values); - expect([...(await methods.values())]).to.have.deep.members(values); - } - - it('starts empty', async function () { - expect(await this.methods.contains(this.valueA)).to.be.false; - - await expectMembersMatch(this.methods, []); - }); - - describe('add', function () { - it('adds a value', async function () { - await expect(this.methods.add(this.valueA)).to.emit(this.mock, this.events.addReturn).withArgs(true); - - await expectMembersMatch(this.methods, [this.valueA]); - }); - - it('adds several values', async function () { - await this.methods.add(this.valueA); - await this.methods.add(this.valueB); - - await expectMembersMatch(this.methods, [this.valueA, this.valueB]); - expect(await this.methods.contains(this.valueC)).to.be.false; - }); - - it('returns false when adding values already in the set', async function () { - await this.methods.add(this.valueA); - - await expect(this.methods.add(this.valueA)).to.emit(this.mock, this.events.addReturn).withArgs(false); - - await expectMembersMatch(this.methods, [this.valueA]); - }); - }); - - describe('at', function () { - it('reverts when retrieving non-existent elements', async function () { - await expect(this.methods.at(0)).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - }); - - it('retrieves existing element', async function () { - await this.methods.add(this.valueA); - expect(await this.methods.at(0)).to.equal(this.valueA); - }); - }); - - describe('remove', function () { - it('removes added values', async function () { - await this.methods.add(this.valueA); - - await expect(this.methods.remove(this.valueA)).to.emit(this.mock, this.events.removeReturn).withArgs(true); - - expect(await this.methods.contains(this.valueA)).to.be.false; - await expectMembersMatch(this.methods, []); - }); - - it('returns false when removing values not in the set', async function () { - await expect(this.methods.remove(this.valueA)).to.emit(this.mock, this.events.removeReturn).withArgs(false); - - expect(await this.methods.contains(this.valueA)).to.be.false; - }); - - it('adds and removes multiple values', async function () { - // [] - - await this.methods.add(this.valueA); - await this.methods.add(this.valueC); - - // [A, C] - - await this.methods.remove(this.valueA); - await this.methods.remove(this.valueB); - - // [C] - - await this.methods.add(this.valueB); - - // [C, B] - - await this.methods.add(this.valueA); - await this.methods.remove(this.valueC); - - // [A, B] - - await this.methods.add(this.valueA); - await this.methods.add(this.valueB); - - // [A, B] - - await this.methods.add(this.valueC); - await this.methods.remove(this.valueA); - - // [B, C] - - await this.methods.add(this.valueA); - await this.methods.remove(this.valueB); - - // [A, C] - - await expectMembersMatch(this.methods, [this.valueA, this.valueC]); - - expect(await this.methods.contains(this.valueB)).to.be.false; - }); - }); -} - -module.exports = { - shouldBehaveLikeSet, -}; diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/EnumerableSet.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/EnumerableSet.test.js deleted file mode 100644 index 66d666058e..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/EnumerableSet.test.js +++ /dev/null @@ -1,61 +0,0 @@ -const { ethers } = require('hardhat'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { mapValues } = require('../../helpers/iterate'); -const { generators } = require('../../helpers/random'); -const { TYPES } = require('../../../scripts/generate/templates/EnumerableSet.opts'); - -const { shouldBehaveLikeSet } = require('./EnumerableSet.behavior'); - -const getMethods = (mock, fnSigs) => { - return mapValues( - fnSigs, - fnSig => - (...args) => - mock.getFunction(fnSig)(0, ...args), - ); -}; - -async function fixture() { - const mock = await ethers.deployContract('$EnumerableSet'); - - const env = Object.fromEntries( - TYPES.map(({ name, type }) => [ - type, - { - values: Array.from({ length: 3 }, generators[type]), - methods: getMethods(mock, { - add: `$add(uint256,${type})`, - remove: `$remove(uint256,${type})`, - contains: `$contains(uint256,${type})`, - length: `$length_EnumerableSet_${name}(uint256)`, - at: `$at_EnumerableSet_${name}(uint256,uint256)`, - values: `$values_EnumerableSet_${name}(uint256)`, - }), - events: { - addReturn: `return$add_EnumerableSet_${name}_${type}`, - removeReturn: `return$remove_EnumerableSet_${name}_${type}`, - }, - }, - ]), - ); - - return { mock, env }; -} - -describe('EnumerableSet', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - for (const { type } of TYPES) { - describe(type, function () { - beforeEach(function () { - Object.assign(this, this.env[type]); - [this.valueA, this.valueB, this.valueC] = this.values; - }); - - shouldBehaveLikeSet(); - }); - } -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/Heap.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/Heap.t.sol deleted file mode 100644 index 434f37f669..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/Heap.t.sol +++ /dev/null @@ -1,74 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.20; - -import {Test} from "forge-std/Test.sol"; -import {Math} from "@openzeppelin/contracts/utils/math/Math.sol"; -import {Heap} from "@openzeppelin/contracts/utils/structs/Heap.sol"; -import {Comparators} from "@openzeppelin/contracts/utils/Comparators.sol"; - -contract Uint256HeapTest is Test { - using Heap for Heap.Uint256Heap; - - Heap.Uint256Heap internal heap; - - function _validateHeap(function(uint256, uint256) view returns (bool) comp) internal { - for (uint32 i = 1; i < heap.length(); ++i) { - assertFalse(comp(heap.tree[i], heap.tree[(i - 1) / 2])); - } - } - - function testFuzz(uint256[] calldata input) public { - vm.assume(input.length < 0x20); - assertEq(heap.length(), 0); - - uint256 min = type(uint256).max; - for (uint256 i = 0; i < input.length; ++i) { - heap.insert(input[i]); - assertEq(heap.length(), i + 1); - _validateHeap(Comparators.lt); - - min = Math.min(min, input[i]); - assertEq(heap.peek(), min); - } - - uint256 max = 0; - for (uint256 i = 0; i < input.length; ++i) { - uint256 top = heap.peek(); - uint256 pop = heap.pop(); - assertEq(heap.length(), input.length - i - 1); - _validateHeap(Comparators.lt); - - assertEq(pop, top); - assertGe(pop, max); - max = pop; - } - } - - function testFuzzGt(uint256[] calldata input) public { - vm.assume(input.length < 0x20); - assertEq(heap.length(), 0); - - uint256 max = 0; - for (uint256 i = 0; i < input.length; ++i) { - heap.insert(input[i], Comparators.gt); - assertEq(heap.length(), i + 1); - _validateHeap(Comparators.gt); - - max = Math.max(max, input[i]); - assertEq(heap.peek(), max); - } - - uint256 min = type(uint256).max; - for (uint256 i = 0; i < input.length; ++i) { - uint256 top = heap.peek(); - uint256 pop = heap.pop(Comparators.gt); - assertEq(heap.length(), input.length - i - 1); - _validateHeap(Comparators.gt); - - assertEq(pop, top); - assertLe(pop, min); - min = pop; - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/Heap.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/Heap.test.js deleted file mode 100644 index 6d751205c7..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/Heap.test.js +++ /dev/null @@ -1,113 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); - -async function fixture() { - const mock = await ethers.deployContract('$Heap'); - return { mock }; -} - -describe('Heap', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('Uint256Heap', function () { - it('starts empty', async function () { - expect(await this.mock.$length(0)).to.equal(0n); - }); - - it('peek, pop and replace from empty', async function () { - await expect(this.mock.$peek(0)).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - await expect(this.mock.$pop(0)).to.be.revertedWithPanic(PANIC_CODES.POP_ON_EMPTY_ARRAY); - await expect(this.mock.$replace(0, 0n)).to.be.revertedWithPanic(PANIC_CODES.POP_ON_EMPTY_ARRAY); - }); - - it('clear', async function () { - await this.mock.$insert(0, 42n); - - expect(await this.mock.$length(0)).to.equal(1n); - expect(await this.mock.$peek(0)).to.equal(42n); - - await this.mock.$clear(0); - - expect(await this.mock.$length(0)).to.equal(0n); - await expect(this.mock.$peek(0)).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - }); - - it('support duplicated items', async function () { - expect(await this.mock.$length(0)).to.equal(0n); - - // insert 5 times - await this.mock.$insert(0, 42n); - await this.mock.$insert(0, 42n); - await this.mock.$insert(0, 42n); - await this.mock.$insert(0, 42n); - await this.mock.$insert(0, 42n); - - // pop 5 times - await expect(this.mock.$pop(0)).to.emit(this.mock, 'return$pop').withArgs(42n); - await expect(this.mock.$pop(0)).to.emit(this.mock, 'return$pop').withArgs(42n); - await expect(this.mock.$pop(0)).to.emit(this.mock, 'return$pop').withArgs(42n); - await expect(this.mock.$pop(0)).to.emit(this.mock, 'return$pop').withArgs(42n); - await expect(this.mock.$pop(0)).to.emit(this.mock, 'return$pop').withArgs(42n); - - // popping a 6th time panics - await expect(this.mock.$pop(0)).to.be.revertedWithPanic(PANIC_CODES.POP_ON_EMPTY_ARRAY); - }); - - it('insert, pop and replace', async function () { - const heap = []; - for (const { op, value } of [ - { op: 'insert', value: 712 }, // [712] - { op: 'insert', value: 20 }, // [20, 712] - { op: 'insert', value: 4337 }, // [20, 712, 4437] - { op: 'pop' }, // 20, [712, 4437] - { op: 'insert', value: 1559 }, // [712, 1559, 4437] - { op: 'insert', value: 165 }, // [165, 712, 1559, 4437] - { op: 'insert', value: 155 }, // [155, 165, 712, 1559, 4437] - { op: 'insert', value: 7702 }, // [155, 165, 712, 1559, 4437, 7702] - { op: 'pop' }, // 155, [165, 712, 1559, 4437, 7702] - { op: 'replace', value: 721 }, // 165, [712, 721, 1559, 4437, 7702] - { op: 'pop' }, // 712, [721, 1559, 4437, 7702] - { op: 'pop' }, // 721, [1559, 4437, 7702] - { op: 'pop' }, // 1559, [4437, 7702] - { op: 'pop' }, // 4437, [7702] - { op: 'pop' }, // 7702, [] - { op: 'pop' }, // panic - { op: 'replace', value: '1363' }, // panic - ]) { - switch (op) { - case 'insert': - await this.mock.$insert(0, value); - heap.push(value); - heap.sort((a, b) => a - b); - break; - case 'pop': - if (heap.length == 0) { - await expect(this.mock.$pop(0)).to.be.revertedWithPanic(PANIC_CODES.POP_ON_EMPTY_ARRAY); - } else { - await expect(this.mock.$pop(0)).to.emit(this.mock, 'return$pop').withArgs(heap.shift()); - } - break; - case 'replace': - if (heap.length == 0) { - await expect(this.mock.$replace(0, value)).to.be.revertedWithPanic(PANIC_CODES.POP_ON_EMPTY_ARRAY); - } else { - await expect(this.mock.$replace(0, value)).to.emit(this.mock, 'return$replace').withArgs(heap.shift()); - heap.push(value); - heap.sort((a, b) => a - b); - } - break; - } - expect(await this.mock.$length(0)).to.equal(heap.length); - if (heap.length == 0) { - await expect(this.mock.$peek(0)).to.be.revertedWithPanic(PANIC_CODES.ARRAY_ACCESS_OUT_OF_BOUNDS); - } else { - expect(await this.mock.$peek(0)).to.equal(heap[0]); - } - } - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/MerkleTree.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/MerkleTree.test.js deleted file mode 100644 index bec39ceead..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/structs/MerkleTree.test.js +++ /dev/null @@ -1,100 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); -const { PANIC_CODES } = require('@nomicfoundation/hardhat-chai-matchers/panic'); -const { StandardMerkleTree } = require('@openzeppelin/merkle-tree'); - -const { generators } = require('../../helpers/random'); - -const makeTree = (leaves = [ethers.ZeroHash]) => - StandardMerkleTree.of( - leaves.map(leaf => [leaf]), - ['bytes32'], - { sortLeaves: false }, - ); - -const hashLeaf = leaf => makeTree().leafHash([leaf]); - -const DEPTH = 4n; // 16 slots -const ZERO = hashLeaf(ethers.ZeroHash); - -async function fixture() { - const mock = await ethers.deployContract('MerkleTreeMock'); - await mock.setup(DEPTH, ZERO); - return { mock }; -} - -describe('MerkleTree', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - it('sets initial values at setup', async function () { - const merkleTree = makeTree(Array.from({ length: 2 ** Number(DEPTH) }, () => ethers.ZeroHash)); - - expect(await this.mock.root()).to.equal(merkleTree.root); - expect(await this.mock.depth()).to.equal(DEPTH); - expect(await this.mock.nextLeafIndex()).to.equal(0n); - }); - - describe('push', function () { - it('tree is correctly updated', async function () { - const leaves = Array.from({ length: 2 ** Number(DEPTH) }, () => ethers.ZeroHash); - - // for each leaf slot - for (const i in leaves) { - // generate random leaf and hash it - const hashedLeaf = hashLeaf((leaves[i] = generators.bytes32())); - - // update leaf list and rebuild tree. - const tree = makeTree(leaves); - - // push value to tree - await expect(this.mock.push(hashedLeaf)).to.emit(this.mock, 'LeafInserted').withArgs(hashedLeaf, i, tree.root); - - // check tree - expect(await this.mock.root()).to.equal(tree.root); - expect(await this.mock.nextLeafIndex()).to.equal(BigInt(i) + 1n); - } - }); - - it('revert when tree is full', async function () { - await Promise.all(Array.from({ length: 2 ** Number(DEPTH) }).map(() => this.mock.push(ethers.ZeroHash))); - - await expect(this.mock.push(ethers.ZeroHash)).to.be.revertedWithPanic(PANIC_CODES.TOO_MUCH_MEMORY_ALLOCATED); - }); - }); - - it('reset', async function () { - // empty tree - const zeroLeaves = Array.from({ length: 2 ** Number(DEPTH) }, () => ethers.ZeroHash); - const zeroTree = makeTree(zeroLeaves); - - // tree with one element - const leaves = Array.from({ length: 2 ** Number(DEPTH) }, () => ethers.ZeroHash); - const hashedLeaf = hashLeaf((leaves[0] = generators.bytes32())); // fill first leaf and hash it - const tree = makeTree(leaves); - - // root should be that of a zero tree - expect(await this.mock.root()).to.equal(zeroTree.root); - expect(await this.mock.nextLeafIndex()).to.equal(0n); - - // push leaf and check root - await expect(this.mock.push(hashedLeaf)).to.emit(this.mock, 'LeafInserted').withArgs(hashedLeaf, 0, tree.root); - - expect(await this.mock.root()).to.equal(tree.root); - expect(await this.mock.nextLeafIndex()).to.equal(1n); - - // reset tree - await this.mock.setup(DEPTH, ZERO); - - expect(await this.mock.root()).to.equal(zeroTree.root); - expect(await this.mock.nextLeafIndex()).to.equal(0n); - - // re-push leaf and check root - await expect(this.mock.push(hashedLeaf)).to.emit(this.mock, 'LeafInserted').withArgs(hashedLeaf, 0, tree.root); - - expect(await this.mock.root()).to.equal(tree.root); - expect(await this.mock.nextLeafIndex()).to.equal(1n); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/types/Time.test.js b/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/types/Time.test.js deleted file mode 100644 index 3ab6fefa8d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/lib/openzeppelin-contracts/test/utils/types/Time.test.js +++ /dev/null @@ -1,135 +0,0 @@ -const { ethers } = require('hardhat'); -const { expect } = require('chai'); -const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers'); - -const { product } = require('../../helpers/iterate'); -const { max } = require('../../helpers/math'); -const time = require('../../helpers/time'); - -const MAX_UINT32 = 1n << (32n - 1n); -const MAX_UINT48 = 1n << (48n - 1n); -const SOME_VALUES = [0n, 1n, 2n, 15n, 16n, 17n, 42n]; - -const asUint = (value, size) => { - value = ethers.toBigInt(value); - size = ethers.toBigInt(size); - expect(value).to.be.greaterThanOrEqual(0n, `value is not a valid uint${size}`); - expect(value).to.be.lessThan(1n << size, `value is not a valid uint${size}`); - return value; -}; - -const unpackDelay = delay => ({ - valueBefore: (asUint(delay, 112) >> 32n) % (1n << 32n), - valueAfter: (asUint(delay, 112) >> 0n) % (1n << 32n), - effect: (asUint(delay, 112) >> 64n) % (1n << 48n), -}); - -const packDelay = ({ valueBefore, valueAfter = 0n, effect = 0n }) => - (asUint(valueAfter, 32) << 0n) + (asUint(valueBefore, 32) << 32n) + (asUint(effect, 48) << 64n); - -const effectSamplesForTimepoint = timepoint => [ - 0n, - timepoint, - ...product([-1n, 1n], [1n, 2n, 17n, 42n]) - .map(([sign, shift]) => timepoint + sign * shift) - .filter(effect => effect > 0n && effect <= MAX_UINT48), - MAX_UINT48, -]; - -async function fixture() { - const mock = await ethers.deployContract('$Time'); - return { mock }; -} - -describe('Time', function () { - beforeEach(async function () { - Object.assign(this, await loadFixture(fixture)); - }); - - describe('clocks', function () { - it('timestamp', async function () { - expect(await this.mock.$timestamp()).to.equal(await time.clock.timestamp()); - }); - - it('block number', async function () { - expect(await this.mock.$blockNumber()).to.equal(await time.clock.blocknumber()); - }); - }); - - describe('Delay', function () { - describe('packing and unpacking', function () { - const valueBefore = 17n; - const valueAfter = 42n; - const effect = 69n; - const delay = 1272825341158973505578n; - - it('pack', async function () { - expect(await this.mock.$pack(valueBefore, valueAfter, effect)).to.equal(delay); - expect(packDelay({ valueBefore, valueAfter, effect })).to.equal(delay); - }); - - it('unpack', async function () { - expect(await this.mock.$unpack(delay)).to.deep.equal([valueBefore, valueAfter, effect]); - - expect(unpackDelay(delay)).to.deep.equal({ - valueBefore, - valueAfter, - effect, - }); - }); - }); - - it('toDelay', async function () { - for (const value of [...SOME_VALUES, MAX_UINT32]) { - expect(await this.mock.$toDelay(value).then(unpackDelay)).to.deep.equal({ - valueBefore: 0n, - valueAfter: value, - effect: 0n, - }); - } - }); - - it('get & getFull', async function () { - const timepoint = await time.clock.timestamp(); - const valueBefore = 24194n; - const valueAfter = 4214143n; - - for (const effect of effectSamplesForTimepoint(timepoint)) { - const isPast = effect <= timepoint; - const delay = packDelay({ valueBefore, valueAfter, effect }); - - expect(await this.mock.$get(delay)).to.equal(isPast ? valueAfter : valueBefore); - expect(await this.mock.$getFull(delay)).to.deep.equal([ - isPast ? valueAfter : valueBefore, - isPast ? 0n : valueAfter, - isPast ? 0n : effect, - ]); - } - }); - - it('withUpdate', async function () { - const timepoint = await time.clock.timestamp(); - const valueBefore = 24194n; - const valueAfter = 4214143n; - const newvalueAfter = 94716n; - - for (const effect of effectSamplesForTimepoint(timepoint)) - for (const minSetback of [...SOME_VALUES, MAX_UINT32]) { - const isPast = effect <= timepoint; - const expectedvalueBefore = isPast ? valueAfter : valueBefore; - const expectedSetback = max(minSetback, expectedvalueBefore - newvalueAfter, 0n); - - expect( - await this.mock.$withUpdate(packDelay({ valueBefore, valueAfter, effect }), newvalueAfter, minSetback), - ).to.deep.equal([ - packDelay({ - valueBefore: expectedvalueBefore, - valueAfter: newvalueAfter, - effect: timepoint + expectedSetback, - }), - timepoint + expectedSetback, - ]); - } - }); - }); -}); diff --git a/lib/signals-implicit-mode/lib/sequence-v3/package.json b/lib/signals-implicit-mode/lib/sequence-v3/package.json deleted file mode 100644 index eae9d3ef8a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/package.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "devDependencies": { - "lefthook": "^1.6.1", - "prettier": "^3.2.5" - }, - "scripts": { - "postinstall": "lefthook install", - "format:prettier": "prettier --write \"**/*.{js,jsx,ts,tsx,json,md,yml,yaml}\"", - "format:forge": "forge fmt", - "test": "forge test", - "coverage": "forge coverage --no-match-coverage \"(script|test)\"" - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/pnpm-lock.yaml b/lib/signals-implicit-mode/lib/sequence-v3/pnpm-lock.yaml deleted file mode 100644 index caff6c479a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/pnpm-lock.yaml +++ /dev/null @@ -1,157 +0,0 @@ -lockfileVersion: '9.0' - -settings: - autoInstallPeers: true - excludeLinksFromLockfile: false - -importers: - .: - devDependencies: - lefthook: - specifier: ^1.6.1 - version: 1.10.8 - prettier: - specifier: ^3.2.5 - version: 3.4.2 - -packages: - lefthook-darwin-arm64@1.10.8: - resolution: - { - integrity: sha512-uE5oLjWuANaAyv6KQoWWGacZgKq5zGd3UmkWLE2OSSrZbgSdTz1R6Uios2yMXrGDptBX9PDWp9SNcHPhEoQlNw==, - } - cpu: [arm64] - os: [darwin] - - lefthook-darwin-x64@1.10.8: - resolution: - { - integrity: sha512-502vfNdfJIDxLQKtlS3TbnM54PrV5wcssVvbDEnkLLjyrEImOZ3lVz3cqrT42KvFYFqgarrhII9jigqUxnLuSQ==, - } - cpu: [x64] - os: [darwin] - - lefthook-freebsd-arm64@1.10.8: - resolution: - { - integrity: sha512-xkqxIxEnFK9zyN3F3Lc11/byuYAR5z7FJBH5UTb2Wnxob7BwYfB0gXBcw3gKEYZiwHFNlyJQimndc7QWZ7y4kw==, - } - cpu: [arm64] - os: [freebsd] - - lefthook-freebsd-x64@1.10.8: - resolution: - { - integrity: sha512-hCErafcyykVCIMb/6hzredNQ1ogDcz07lphf0k0eGUbr94XK7IUOkQwD++XOAijOHknkzS1V9WvjV1lrhGYtUA==, - } - cpu: [x64] - os: [freebsd] - - lefthook-linux-arm64@1.10.8: - resolution: - { - integrity: sha512-YFqT/hj+nzTTwzaDSdmYGKvpZI6/Wt3Id6+6gEU8VMAojXOe9rWAXitfoiDXW1TNPzpHqwyGnjOCcjquF1umkw==, - } - cpu: [arm64] - os: [linux] - - lefthook-linux-x64@1.10.8: - resolution: - { - integrity: sha512-nOARm1gE0EeMSEHaulpFDPnIqlQFPsFnaSkmCK2gWXG5jBbRtMr4BcJLDPzsekDKxskr5mZwlPQ2fFW3B/jiCA==, - } - cpu: [x64] - os: [linux] - - lefthook-openbsd-arm64@1.10.8: - resolution: - { - integrity: sha512-6cUokm4Dd5OMNewVWIV9bM+nebBOrImCAOjbdfCEW4hhtIRvr6XZirHu0BVJM/I5Ed0MjiAme+L6yV7LW68HAA==, - } - cpu: [arm64] - os: [openbsd] - - lefthook-openbsd-x64@1.10.8: - resolution: - { - integrity: sha512-659TblZOM7pV9ImSRjpMQSynA5L1DTcoS37TJN7Y/84O3pXhKYAN1Lm5EJFZQ1dBMEJDeAD/L1V98RWqnFx/gw==, - } - cpu: [x64] - os: [openbsd] - - lefthook-windows-arm64@1.10.8: - resolution: - { - integrity: sha512-g5O44F+Mo0n2RzXL7A9g0TM5VA60OWWw7CPNLi42qOniv1t6/43glxB7bmKalrLAznFR5UbyiLMmO6ospDXctg==, - } - cpu: [arm64] - os: [win32] - - lefthook-windows-x64@1.10.8: - resolution: - { - integrity: sha512-PZ72IXi29MdOCNZZvqRrBONMfe4DZU3GVowotLfHo4U/1oTTd2LImJitm0qbFjf9kCtRHLkD4K/l7ZgV4gsxtA==, - } - cpu: [x64] - os: [win32] - - lefthook@1.10.8: - resolution: - { - integrity: sha512-yJM97cNPH7zYbLUJ8G2LGhJbSRd66mv5BVeryLiEsmXER3vz4wGtiLJEYRwveSEZetOMBgAlVBIZEfuxJGsjIA==, - } - hasBin: true - - prettier@3.4.2: - resolution: - { - integrity: sha512-e9MewbtFo+Fevyuxn/4rrcDAaq0IYxPGLvObpQjiZBMAzB9IGmzlnG9RZy3FFas+eBMu2vA0CszMeduow5dIuQ==, - } - engines: { node: '>=14' } - hasBin: true - -snapshots: - lefthook-darwin-arm64@1.10.8: - optional: true - - lefthook-darwin-x64@1.10.8: - optional: true - - lefthook-freebsd-arm64@1.10.8: - optional: true - - lefthook-freebsd-x64@1.10.8: - optional: true - - lefthook-linux-arm64@1.10.8: - optional: true - - lefthook-linux-x64@1.10.8: - optional: true - - lefthook-openbsd-arm64@1.10.8: - optional: true - - lefthook-openbsd-x64@1.10.8: - optional: true - - lefthook-windows-arm64@1.10.8: - optional: true - - lefthook-windows-x64@1.10.8: - optional: true - - lefthook@1.10.8: - optionalDependencies: - lefthook-darwin-arm64: 1.10.8 - lefthook-darwin-x64: 1.10.8 - lefthook-freebsd-arm64: 1.10.8 - lefthook-freebsd-x64: 1.10.8 - lefthook-linux-arm64: 1.10.8 - lefthook-linux-x64: 1.10.8 - lefthook-openbsd-arm64: 1.10.8 - lefthook-openbsd-x64: 1.10.8 - lefthook-windows-arm64: 1.10.8 - lefthook-windows-x64: 1.10.8 - - prettier@3.4.2: {} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/pnpm-workspace.yaml b/lib/signals-implicit-mode/lib/sequence-v3/pnpm-workspace.yaml deleted file mode 100644 index e7a00fbdc4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/pnpm-workspace.yaml +++ /dev/null @@ -1,2 +0,0 @@ -packages: - - 'sdk/*' diff --git a/lib/signals-implicit-mode/lib/sequence-v3/script/Deploy.s.sol b/lib/signals-implicit-mode/lib/sequence-v3/script/Deploy.s.sol deleted file mode 100644 index 2b3bec19f1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/script/Deploy.s.sol +++ /dev/null @@ -1,36 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { SingletonDeployer, console } from "lib/erc2470-libs/script/SingletonDeployer.s.sol"; -import { Factory } from "src/Factory.sol"; -import { Guest } from "src/Guest.sol"; -import { Stage1Module } from "src/Stage1Module.sol"; -import { SessionManager } from "src/extensions/sessions/SessionManager.sol"; - -contract Deploy is SingletonDeployer { - - function run() external { - uint256 pk = vm.envUint("PRIVATE_KEY"); - address entryPoint = vm.envAddress("ERC4337_ENTRY_POINT_V7"); - if (entryPoint == address(0)) { - entryPoint = 0x0000000071727De22E5E9d8BAf0edAc6f37da032; - } - - bytes32 salt = bytes32(0); - - bytes memory initCode = abi.encodePacked(type(Factory).creationCode); - address factory = _deployIfNotAlready("Factory", initCode, salt, pk); - - initCode = abi.encodePacked(type(Stage1Module).creationCode, abi.encode(factory, entryPoint)); - address stage1Module = _deployIfNotAlready("Stage1Module", initCode, salt, pk); - - console.log("Stage2Module for Stage1Module is", Stage1Module(payable(stage1Module)).STAGE_2_IMPLEMENTATION()); - - initCode = abi.encodePacked(type(Guest).creationCode); - _deployIfNotAlready("Guest", initCode, salt, pk); - - initCode = abi.encodePacked(type(SessionManager).creationCode); - _deployIfNotAlready("SessionManager", initCode, salt, pk); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/script/DeployMocks.s.sol b/lib/signals-implicit-mode/lib/sequence-v3/script/DeployMocks.s.sol deleted file mode 100644 index a3486687c3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/script/DeployMocks.s.sol +++ /dev/null @@ -1,19 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { SingletonDeployer, console } from "lib/erc2470-libs/script/SingletonDeployer.s.sol"; - -import { Emitter } from "test/mocks/Emitter.sol"; - -contract DeployMocks is SingletonDeployer { - - function run() external { - uint256 pk = vm.envUint("PRIVATE_KEY"); - - bytes32 salt = bytes32(0); - - bytes memory initCode = abi.encodePacked(type(Emitter).creationCode); - _deployIfNotAlready("Emitter", initCode, salt, pk); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/Estimator.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/Estimator.sol deleted file mode 100644 index a67b8b5889..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/Estimator.sol +++ /dev/null @@ -1,111 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Stage2Module } from "./Stage2Module.sol"; - -import { Payload } from "./modules/Payload.sol"; -import { IDelegatedExtension } from "./modules/interfaces/IDelegatedExtension.sol"; -import { LibOptim } from "./utils/LibOptim.sol"; - -/// @title Estimator -/// @author William Hua -/// @notice Helper for estimating the gas used for payload validation and execution -contract Estimator is Stage2Module { - - constructor( - address _entryPoint - ) Stage2Module(_entryPoint) { } - - function _isValidImage( - bytes32 _imageHash - ) internal view virtual override returns (bool) { - super._isValidImage(_imageHash); - return true; - } - - /// @notice Estimate the gas used for payload validation and execution - /// @param _payload The payload to estimate the gas used for - /// @param _signature The signature to validate the payload with - /// @return gasUsed The gas used for payload validation and execution - function estimate( - bytes calldata _payload, - bytes calldata _signature - ) external payable virtual returns (uint256 gasUsed) { - uint256 startingGas = gasleft(); - Payload.Decoded memory decoded = Payload.fromPackedCalls(_payload); - - _consumeNonce(decoded.space, readNonce(decoded.space)); - (bool isValid, bytes32 opHash) = signatureValidation(decoded, _signature); - - if (!isValid) { - revert InvalidSignature(decoded, _signature); - } - - _estimate(startingGas, opHash, decoded); - - return startingGas - gasleft(); - } - - function _estimate(uint256 _startingGas, bytes32 _opHash, Payload.Decoded memory _decoded) private { - bool errorFlag = false; - - uint256 numCalls = _decoded.calls.length; - for (uint256 i = 0; i < numCalls; i++) { - Payload.Call memory call = _decoded.calls[i]; - - // Skip onlyFallback calls if no error occurred - if (call.onlyFallback && !errorFlag) { - emit CallSkipped(_opHash, i); - continue; - } - - // Reset the error flag - // onlyFallback calls only apply when the immediately preceding transaction fails - errorFlag = false; - - uint256 gasLimit = call.gasLimit; - if (gasLimit != 0 && gasleft() < gasLimit) { - revert NotEnoughGas(_decoded, i, gasleft()); - } - - bool success; - if (call.delegateCall) { - (success) = LibOptim.delegatecall( - call.to, - gasLimit == 0 ? gasleft() : gasLimit, - abi.encodeWithSelector( - IDelegatedExtension.handleSequenceDelegateCall.selector, - _opHash, - _startingGas, - i, - numCalls, - _decoded.space, - call.data - ) - ); - } else { - (success) = LibOptim.call(call.to, call.value, gasLimit == 0 ? gasleft() : gasLimit, call.data); - } - - if (!success) { - if (call.behaviorOnError == Payload.BEHAVIOR_IGNORE_ERROR) { - errorFlag = true; - emit CallFailed(_opHash, i, LibOptim.returnData()); - continue; - } - - if (call.behaviorOnError == Payload.BEHAVIOR_REVERT_ON_ERROR) { - revert Reverted(_decoded, i, LibOptim.returnData()); - } - - if (call.behaviorOnError == Payload.BEHAVIOR_ABORT_ON_ERROR) { - emit CallAborted(_opHash, i, LibOptim.returnData()); - break; - } - } - - emit CallSucceeded(_opHash, i); - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/Factory.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/Factory.sol deleted file mode 100644 index 04a2277fa0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/Factory.sol +++ /dev/null @@ -1,28 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import "./Wallet.sol"; - -/// @title Factory -/// @author Agustin Aguilar, Michael Standen -/// @notice Factory for deploying wallets -contract Factory { - - /// @notice Error thrown when the deployment fails - error DeployFailed(address _mainModule, bytes32 _salt); - - /// @notice Deploy a new wallet instance - /// @param _mainModule Address of the main module to be used by the wallet - /// @param _salt Salt used to generate the wallet, which is the imageHash of the wallet's configuration. - /// @dev It is recommended to not have more than 200 signers as opcode repricing could make transactions impossible to execute as all the signers must be passed for each transaction. - function deploy(address _mainModule, bytes32 _salt) public payable returns (address _contract) { - bytes memory code = abi.encodePacked(Wallet.creationCode, uint256(uint160(_mainModule))); - assembly { - _contract := create2(callvalue(), add(code, 32), mload(code), _salt) - } - if (_contract == address(0)) { - revert DeployFailed(_mainModule, _salt); - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/Guest.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/Guest.sol deleted file mode 100644 index 0f157b1df8..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/Guest.sol +++ /dev/null @@ -1,76 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Calls } from "./modules/Calls.sol"; -import { Payload } from "./modules/Payload.sol"; - -import { LibBytes } from "./utils/LibBytes.sol"; -import { LibOptim } from "./utils/LibOptim.sol"; - -/// @title Guest -/// @author Agustin Aguilar, William Hua, Michael Standen -/// @notice Guest for dispatching calls -contract Guest { - - using LibBytes for bytes; - - /// @notice Error thrown when a delegate call is not allowed - error DelegateCallNotAllowed(uint256 index); - - /// @notice Fallback function - /// @dev Dispatches the guest call - fallback() external payable { - Payload.Decoded memory decoded = Payload.fromPackedCalls(msg.data); - bytes32 opHash = Payload.hash(decoded); - _dispatchGuest(decoded, opHash); - } - - function _dispatchGuest(Payload.Decoded memory _decoded, bytes32 _opHash) internal { - bool errorFlag = false; - - uint256 numCalls = _decoded.calls.length; - for (uint256 i = 0; i < numCalls; i++) { - Payload.Call memory call = _decoded.calls[i]; - - // Skip onlyFallback calls if no error occurred - if (call.onlyFallback && !errorFlag) { - emit Calls.CallSkipped(_opHash, i); - continue; - } - - // Reset the error flag - // onlyFallback calls only apply when the immediately preceding transaction fails - errorFlag = false; - - uint256 gasLimit = call.gasLimit; - if (gasLimit != 0 && gasleft() < gasLimit) { - revert Calls.NotEnoughGas(_decoded, i, gasleft()); - } - - if (call.delegateCall) { - revert DelegateCallNotAllowed(i); - } - - bool success = LibOptim.call(call.to, call.value, gasLimit == 0 ? gasleft() : gasLimit, call.data); - if (!success) { - if (call.behaviorOnError == Payload.BEHAVIOR_IGNORE_ERROR) { - errorFlag = true; - emit Calls.CallFailed(_opHash, i, LibOptim.returnData()); - continue; - } - - if (call.behaviorOnError == Payload.BEHAVIOR_REVERT_ON_ERROR) { - revert Calls.Reverted(_decoded, i, LibOptim.returnData()); - } - - if (call.behaviorOnError == Payload.BEHAVIOR_ABORT_ON_ERROR) { - emit Calls.CallAborted(_opHash, i, LibOptim.returnData()); - break; - } - } - - emit Calls.CallSucceeded(_opHash, i); - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/Simulator.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/Simulator.sol deleted file mode 100644 index 8bc4b7ece8..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/Simulator.sol +++ /dev/null @@ -1,109 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Stage2Module } from "./Stage2Module.sol"; - -import { Payload } from "./modules/Payload.sol"; -import { IDelegatedExtension } from "./modules/interfaces/IDelegatedExtension.sol"; -import { LibOptim } from "./utils/LibOptim.sol"; - -/// @title Simulator -/// @author William Hua -/// @notice Helper for simulating the execution of a payload -contract Simulator is Stage2Module { - - constructor( - address _entryPoint - ) Stage2Module(_entryPoint) { } - - /// @notice Status of the call - enum Status { - Skipped, - Succeeded, - Failed, - Aborted, - Reverted, - NotEnoughGas - } - - /// @notice Result of the call - struct Result { - Status status; - bytes result; - uint256 gasUsed; - } - - /// @notice Simulate the execution of a payload - /// @param _calls The calls to simulate - /// @return results The results of the calls - function simulate( - Payload.Call[] calldata _calls - ) external returns (Result[] memory results) { - uint256 startingGas = gasleft(); - bool errorFlag = false; - - uint256 numCalls = _calls.length; - results = new Result[](numCalls); - for (uint256 i = 0; i < numCalls; i++) { - Payload.Call memory call = _calls[i]; - - // Skip onlyFallback calls if no error occurred - if (call.onlyFallback && !errorFlag) { - continue; - } - - // Reset the error flag - // onlyFallback calls only apply when the immediately preceding transaction fails - errorFlag = false; - - uint256 gasLimit = call.gasLimit; - if (gasLimit != 0 && gasleft() < gasLimit) { - results[i].status = Status.NotEnoughGas; - results[i].result = abi.encode(gasleft()); - return results; - } - - bool success; - if (call.delegateCall) { - uint256 initial = gasleft(); - (success) = LibOptim.delegatecall( - call.to, - gasLimit == 0 ? gasleft() : gasLimit, - abi.encodeWithSelector( - IDelegatedExtension.handleSequenceDelegateCall.selector, 0, startingGas, i, numCalls, 0, call.data - ) - ); - results[i].gasUsed = initial - gasleft(); - } else { - uint256 initial = gasleft(); - (success) = LibOptim.call(call.to, call.value, gasLimit == 0 ? gasleft() : gasLimit, call.data); - results[i].gasUsed = initial - gasleft(); - } - - if (!success) { - if (call.behaviorOnError == Payload.BEHAVIOR_IGNORE_ERROR) { - errorFlag = true; - results[i].status = Status.Failed; - results[i].result = LibOptim.returnData(); - continue; - } - - if (call.behaviorOnError == Payload.BEHAVIOR_REVERT_ON_ERROR) { - results[i].status = Status.Reverted; - results[i].result = LibOptim.returnData(); - return results; - } - - if (call.behaviorOnError == Payload.BEHAVIOR_ABORT_ON_ERROR) { - results[i].status = Status.Aborted; - results[i].result = LibOptim.returnData(); - break; - } - } - - results[i].status = Status.Succeeded; - results[i].result = LibOptim.returnData(); - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/Stage1Module.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/Stage1Module.sol deleted file mode 100644 index bbd8b2df88..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/Stage1Module.sol +++ /dev/null @@ -1,29 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Stage2Module } from "./Stage2Module.sol"; -import { Calls } from "./modules/Calls.sol"; - -import { ERC4337v07 } from "./modules/ERC4337v07.sol"; -import { Hooks } from "./modules/Hooks.sol"; -import { Stage1Auth } from "./modules/auth/Stage1Auth.sol"; -import { IAuth } from "./modules/interfaces/IAuth.sol"; - -/// @title Stage1Module -/// @author Agustin Aguilar -/// @notice The initial stage of the wallet -contract Stage1Module is Calls, Stage1Auth, Hooks, ERC4337v07 { - - constructor( - address _factory, - address _entryPoint - ) Stage1Auth(_factory, address(new Stage2Module(_entryPoint))) ERC4337v07(_entryPoint) { } - - /// @inheritdoc IAuth - function _isValidImage( - bytes32 _imageHash - ) internal view virtual override(IAuth, Stage1Auth) returns (bool) { - return super._isValidImage(_imageHash); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/Stage2Module.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/Stage2Module.sol deleted file mode 100644 index d38d1a4b02..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/Stage2Module.sol +++ /dev/null @@ -1,27 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Calls } from "./modules/Calls.sol"; - -import { ERC4337v07 } from "./modules/ERC4337v07.sol"; -import { Hooks } from "./modules/Hooks.sol"; -import { Stage2Auth } from "./modules/auth/Stage2Auth.sol"; -import { IAuth } from "./modules/interfaces/IAuth.sol"; - -/// @title Stage2Module -/// @author Agustin Aguilar -/// @notice The second stage of the wallet -contract Stage2Module is Calls, Stage2Auth, Hooks, ERC4337v07 { - - constructor( - address _entryPoint - ) ERC4337v07(_entryPoint) { } - - /// @inheritdoc IAuth - function _isValidImage( - bytes32 _imageHash - ) internal view virtual override(IAuth, Stage2Auth) returns (bool) { - return super._isValidImage(_imageHash); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/Wallet.huff b/lib/signals-implicit-mode/lib/sequence-v3/src/Wallet.huff deleted file mode 100644 index 8e8e7908d5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/Wallet.huff +++ /dev/null @@ -1,55 +0,0 @@ -// Delegate Proxy in Huff -// @title Delegate Proxy -// @notice Implements a proxy using the contract's own address to store the delegate target. -// Calls with calldata (with or without ETH value) are forwarded to the stored target. -// Calls sending only ETH without calldata do nothing and return immediately without forwarding. -// @author Agusx1211 -#define macro CONSTRUCTOR() = takes (0) returns (0) { - 0x41 // [code + arg size] (code_size + 32) - __codeoffset(MAIN) // [code_start, code + arg size] - returndatasize // [0, code_start, code + arg size] - codecopy // [] - - __codesize(MAIN) // [code_size] - dup1 // [code_size, code_size] - mload // [arg1, code_size] - address // [address, arg1, code_size] - sstore // [code_size] - - returndatasize // [0, code_size] - return -} - -#define macro MAIN() = takes(0) returns(0) { - returndatasize // [0] - returndatasize // [0, 0] - calldatasize // [cs, 0, 0] - iszero // [cs == 0, 0, 0] - callvalue // [cv, cs == 0, 0, 0] - mul // [cv * cs == 0, 0, 0] - success // [nr, cv * cs == 0, 0, 0] - jumpi - calldatasize // [cds, 0, 0] - returndatasize // [0, cds, 0, 0] - returndatasize // [0, 0, cds, 0, 0] - calldatacopy // [0, 0] - returndatasize // [0, 0, 0] - calldatasize // [cds, 0, 0, 0] - returndatasize // [0, cds, 0, 0, 0] - address // [addr, 0, cds, 0, 0, 0] - sload // [imp, 0, cds, 0, 0, 0] - gas // [gas, imp, 0, cds, 0, 0, 0] - delegatecall // [suc, 0] - returndatasize // [rds, suc, 0] - dup3 // [0, rds, suc, 0] - dup1 // [0, 0, rds, suc, 0] - returndatacopy // [suc, 0] - swap1 // [0, suc] - returndatasize // [rds, 0, suc] - swap2 // [suc, 0, rds] - success // [nr, suc, 0, rds] - jumpi - revert - success: - return -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/Wallet.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/Wallet.sol deleted file mode 100644 index 4f38220924..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/Wallet.sol +++ /dev/null @@ -1,67 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.0; - -/* -// Delegate Proxy in Huff -// @title Delegate Proxy -// @notice Implements a proxy using the contract's own address to store the delegate target. -// Calls with calldata (with or without ETH value) are forwarded to the stored target. -// Calls sending only ETH without calldata do nothing and return immediately without forwarding. -// @author Agusx1211 -#define macro CONSTRUCTOR() = takes (0) returns (0) { - 0x41 // [code + arg size] (code_size + 32) - __codeoffset(MAIN) // [code_start, code + arg size] - returndatasize // [0, code_start, code + arg size] - codecopy // [] - - __codesize(MAIN) // [code_size] - dup1 // [code_size, code_size] - mload // [arg1, code_size] - address // [address, arg1, code_size] - sstore // [code_size] - - returndatasize // [0, code_size] - return -} - -#define macro MAIN() = takes(0) returns(0) { - returndatasize // [0] - returndatasize // [0, 0] - calldatasize // [cs, 0, 0] - iszero // [cs == 0, 0, 0] - callvalue // [cv, cs == 0, 0, 0] - mul // [cv * cs == 0, 0, 0] - success // [nr, cv * cs == 0, 0, 0] - jumpi - calldatasize // [cds, 0, 0] - returndatasize // [0, cds, 0, 0] - returndatasize // [0, 0, cds, 0, 0] - calldatacopy // [0, 0] - returndatasize // [0, 0, 0] - calldatasize // [cds, 0, 0, 0] - returndatasize // [0, cds, 0, 0, 0] - address // [addr, 0, cds, 0, 0, 0] - sload // [imp, 0, cds, 0, 0, 0] - gas // [gas, imp, 0, cds, 0, 0, 0] - delegatecall // [suc, 0] - returndatasize // [rds, suc, 0] - dup3 // [0, rds, suc, 0] - dup1 // [0, 0, rds, suc, 0] - returndatacopy // [suc, 0] - swap1 // [0, suc] - returndatasize // [rds, 0, suc] - swap2 // [suc, 0, rds] - success // [nr, suc, 0, rds] - jumpi - revert - success: - return -} -*/ - -library Wallet { - - bytes internal constant creationCode = - hex"6041600e3d396021805130553df33d3d36153402601f57363d3d373d363d30545af43d82803e903d91601f57fd5bf3"; - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/passkeys/Passkeys.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/passkeys/Passkeys.sol deleted file mode 100644 index 47a7b9842f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/passkeys/Passkeys.sol +++ /dev/null @@ -1,123 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { ISapientCompact } from "../../modules/interfaces/ISapient.sol"; - -import { LibBytes } from "../../utils/LibBytes.sol"; -import { LibOptim } from "../../utils/LibOptim.sol"; -import { WebAuthn } from "../../utils/WebAuthn.sol"; - -/// @title Passkeys -/// @author Agustin Aguilar, Michael Standen -/// @notice A sapient signer for passkeys -contract Passkeys is ISapientCompact { - - /// @notice Error thrown when the passkey signature is invalid - error InvalidPasskeySignature( - WebAuthn.WebAuthnAuth _webAuthnAuth, bool _requireUserVerification, bytes32 _x, bytes32 _y - ); - - function _rootForPasskey( - bool _requireUserVerification, - bytes32 _x, - bytes32 _y, - bytes32 _metadata - ) internal pure returns (bytes32) { - bytes32 a = LibOptim.fkeccak256(_x, _y); - - bytes32 ruv; - assembly { - ruv := _requireUserVerification - } - - bytes32 b = LibOptim.fkeccak256(ruv, _metadata); - return LibOptim.fkeccak256(a, b); - } - - function _decodeSignature( - bytes calldata _signature - ) - internal - pure - returns ( - WebAuthn.WebAuthnAuth memory _webAuthnAuth, - bool _requireUserVerification, - bytes32 _x, - bytes32 _y, - bytes32 _metadata - ) - { - unchecked { - // Global flag encoding: - // 0000 000X : requireUserVerification - // 0000 00X0 : 1 if 16 bits for authenticatorData size, 0 if 8 bits - // 0000 0X00 : 1 if 16 bits for clientDataJSON size, 0 if 8 bits - // 0000 X000 : 1 if 16 bits for challengeIndex, 0 if 8 bits - // 000X 0000 : 1 if 16 bits for typeIndex, 0 if 8 bits - // 00X0 0000 : 1 if fallback to abi decode data - // 0X00 0000 : 1 if signature has metadata node - // X000 0000 : unused - - bytes1 flags = _signature[0]; - if ((flags & 0x20) == 0) { - _requireUserVerification = (flags & 0x01) != 0; - uint256 bytesAuthDataSize = ((uint8(flags & 0x02)) >> 1) + 1; - uint256 bytesClientDataJSONSize = ((uint8(flags & 0x04)) >> 2) + 1; - uint256 bytesChallengeIndex = ((uint8(flags & 0x08)) >> 3) + 1; - uint256 bytesTypeIndex = ((uint8(flags & 0x10)) >> 4) + 1; - - uint256 pointer = 1; - - if ((flags & 0x40) != 0) { - (_metadata, pointer) = LibBytes.readBytes32(_signature, pointer); - } - - { - uint256 authDataSize; - (authDataSize, pointer) = LibBytes.readUintX(_signature, pointer, bytesAuthDataSize); - uint256 nextPointer = pointer + authDataSize; - _webAuthnAuth.authenticatorData = _signature[pointer:nextPointer]; - pointer = nextPointer; - } - - { - uint256 clientDataJSONSize; - (clientDataJSONSize, pointer) = LibBytes.readUintX(_signature, pointer, bytesClientDataJSONSize); - uint256 nextPointer = pointer + clientDataJSONSize; - _webAuthnAuth.clientDataJSON = string(_signature[pointer:nextPointer]); - pointer = nextPointer; - } - - (_webAuthnAuth.challengeIndex, pointer) = LibBytes.readUintX(_signature, pointer, bytesChallengeIndex); - (_webAuthnAuth.typeIndex, pointer) = LibBytes.readUintX(_signature, pointer, bytesTypeIndex); - - (_webAuthnAuth.r, pointer) = LibBytes.readBytes32(_signature, pointer); - (_webAuthnAuth.s, pointer) = LibBytes.readBytes32(_signature, pointer); - - (_x, pointer) = LibBytes.readBytes32(_signature, pointer); - (_y, pointer) = LibBytes.readBytes32(_signature, pointer); - } else { - (_webAuthnAuth, _requireUserVerification, _x, _y, _metadata) = - abi.decode(_signature[1:], (WebAuthn.WebAuthnAuth, bool, bytes32, bytes32, bytes32)); - } - } - } - - /// @inheritdoc ISapientCompact - function recoverSapientSignatureCompact(bytes32 _digest, bytes calldata _signature) external view returns (bytes32) { - ( - WebAuthn.WebAuthnAuth memory _webAuthnAuth, - bool _requireUserVerification, - bytes32 _x, - bytes32 _y, - bytes32 _metadata - ) = _decodeSignature(_signature); - - if (!WebAuthn.verify(abi.encodePacked(_digest), _requireUserVerification, _webAuthnAuth, _x, _y)) { - revert InvalidPasskeySignature(_webAuthnAuth, _requireUserVerification, _x, _y); - } - - return _rootForPasskey(_requireUserVerification, _x, _y, _metadata); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/recovery/Recovery.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/recovery/Recovery.sol deleted file mode 100644 index 76a461d20b..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/recovery/Recovery.sol +++ /dev/null @@ -1,217 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../../modules/Payload.sol"; -import { IERC1271, IERC1271_MAGIC_VALUE_HASH } from "../../modules/interfaces/IERC1271.sol"; -import { ISapientCompact } from "../../modules/interfaces/ISapient.sol"; -import { LibBytes } from "../../utils/LibBytes.sol"; -import { LibOptim } from "../../utils/LibOptim.sol"; - -using LibBytes for bytes; - -/// @title Recovery -/// @author Agustin Aguilar, William Hua, Michael Standen -/// @notice A recovery mode sapient signer -contract Recovery is ISapientCompact { - - bytes32 private constant EIP712_DOMAIN_TYPEHASH = - keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); - - bytes32 private constant EIP712_DOMAIN_NAME_SEQUENCE = keccak256("Sequence Wallet - Recovery Mode"); - bytes32 private constant EIP712_DOMAIN_VERSION_SEQUENCE = keccak256("1"); - - // Make them similar to the flags in BaseSig.sol - uint256 internal constant FLAG_RECOVERY_LEAF = 1; - uint256 internal constant FLAG_NODE = 3; - uint256 internal constant FLAG_BRANCH = 4; - - /// @notice Emitted when a new payload is queued - event NewQueuedPayload(address _wallet, address _signer, bytes32 _payloadHash, uint256 _timestamp); - - /// @notice Error thrown when the signature is invalid - error InvalidSignature(address _wallet, address _signer, Payload.Decoded _payload, bytes _signature); - /// @notice Error thrown when the payload is already queued - error AlreadyQueued(address _wallet, address _signer, bytes32 _payloadHash); - /// @notice Error thrown when the queue is not ready - error QueueNotReady(address _wallet, bytes32 _payloadHash); - /// @notice Error thrown when the signature flag is invalid - error InvalidSignatureFlag(uint256 _flag); - - function domainSeparator(bool _noChainId, address _wallet) internal view returns (bytes32 _domainSeparator) { - return keccak256( - abi.encode( - EIP712_DOMAIN_TYPEHASH, - EIP712_DOMAIN_NAME_SEQUENCE, - EIP712_DOMAIN_VERSION_SEQUENCE, - _noChainId ? uint256(0) : uint256(block.chainid), - _wallet - ) - ); - } - - /// @notice Mapping of queued timestamps - /// @dev wallet -> signer -> payloadHash -> timestamp - mapping(address => mapping(address => mapping(bytes32 => uint256))) public timestampForQueuedPayload; - - /// @notice Mapping of queued payload hashes - /// @dev wallet -> signer -> payloadHash[] - mapping(address => mapping(address => bytes32[])) public queuedPayloadHashes; - - /// @notice Get the total number of queued payloads - /// @param _wallet The wallet to get the total number of queued payloads for - /// @param _signer The signer to get the total number of queued payloads for - /// @return The total number of queued payloads - function totalQueuedPayloads(address _wallet, address _signer) public view returns (uint256) { - return queuedPayloadHashes[_wallet][_signer].length; - } - - function _leafForRecoveryLeaf( - address _signer, - uint256 _requiredDeltaTime, - uint256 _minTimestamp - ) internal pure returns (bytes32) { - return keccak256(abi.encodePacked("Sequence recovery leaf:\n", _signer, _requiredDeltaTime, _minTimestamp)); - } - - function _recoverBranch( - address _wallet, - bytes32 _payloadHash, - bytes calldata _signature - ) internal view returns (bool verified, bytes32 root) { - uint256 rindex; - - while (rindex < _signature.length) { - // The first byte is the flag, it determines if we are reading - uint256 flag; - (flag, rindex) = _signature.readUint8(rindex); - - if (flag == FLAG_RECOVERY_LEAF) { - // Read the signer and requiredDeltaTime - address signer; - uint256 requiredDeltaTime; - uint256 minTimestamp; - - (signer, rindex) = _signature.readAddress(rindex); - (requiredDeltaTime, rindex) = _signature.readUint24(rindex); - (minTimestamp, rindex) = _signature.readUint64(rindex); - - // Check if we have a queued payload for this signer - uint256 queuedAt = timestampForQueuedPayload[_wallet][signer][_payloadHash]; - if (queuedAt != 0 && queuedAt >= minTimestamp && block.timestamp - queuedAt >= requiredDeltaTime) { - verified = true; - } - - bytes32 node = _leafForRecoveryLeaf(signer, requiredDeltaTime, minTimestamp); - root = root != bytes32(0) ? LibOptim.fkeccak256(root, node) : node; - continue; - } - - if (flag == FLAG_NODE) { - // Read node hash - bytes32 node; - (node, rindex) = _signature.readBytes32(rindex); - root = root != bytes32(0) ? LibOptim.fkeccak256(root, node) : node; - continue; - } - - if (flag == FLAG_BRANCH) { - // Read size - uint256 size; - (size, rindex) = _signature.readUint24(rindex); - - // Enter a branch of the signature merkle tree - uint256 nrindex = rindex + size; - - (bool nverified, bytes32 nroot) = _recoverBranch(_wallet, _payloadHash, _signature[rindex:nrindex]); - rindex = nrindex; - - verified = verified || nverified; - root = LibOptim.fkeccak256(root, nroot); - continue; - } - - revert InvalidSignatureFlag(flag); - } - - return (verified, root); - } - - /// @notice Get the recovery payload hash - /// @param _wallet The wallet to get the recovery payload hash for - /// @param _payload The payload to get the recovery payload hash for - /// @return The recovery payload hash - function recoveryPayloadHash(address _wallet, Payload.Decoded calldata _payload) public view returns (bytes32) { - bytes32 domain = domainSeparator(_payload.noChainId, _wallet); - bytes32 structHash = Payload.toEIP712(_payload); - return keccak256(abi.encodePacked("\x19\x01", domain, structHash)); - } - - /// @inheritdoc ISapientCompact - function recoverSapientSignatureCompact( - bytes32 _payloadHash, - bytes calldata _signature - ) external view returns (bytes32) { - (bool verified, bytes32 root) = _recoverBranch(msg.sender, _payloadHash, _signature); - if (!verified) { - revert QueueNotReady(msg.sender, _payloadHash); - } - - return root; - } - - /// @notice Queue a payload for recovery - /// @param _wallet The wallet to queue the payload for - /// @param _signer The signer to queue the payload for - /// @param _payload The payload to queue - /// @param _signature The signature to queue the payload for - function queuePayload( - address _wallet, - address _signer, - Payload.Decoded calldata _payload, - bytes calldata _signature - ) external { - if (!isValidSignature(_wallet, _signer, _payload, _signature)) { - revert InvalidSignature(_wallet, _signer, _payload, _signature); - } - - bytes32 payloadHash = Payload.hashFor(_payload, _wallet); - if (timestampForQueuedPayload[_wallet][_signer][payloadHash] != 0) { - revert AlreadyQueued(_wallet, _signer, payloadHash); - } - - timestampForQueuedPayload[_wallet][_signer][payloadHash] = block.timestamp; - queuedPayloadHashes[_wallet][_signer].push(payloadHash); - - emit NewQueuedPayload(_wallet, _signer, payloadHash, block.timestamp); - } - - function isValidSignature( - address _wallet, - address _signer, - Payload.Decoded calldata _payload, - bytes calldata _signature - ) internal view returns (bool) { - bytes32 rPayloadHash = recoveryPayloadHash(_wallet, _payload); - - if (_signature.length == 64) { - // Try an ECDSA signature - bytes32 r; - bytes32 s; - uint8 v; - (r, s, v,) = _signature.readRSVCompact(0); - - address addr = ecrecover(rPayloadHash, v, r, s); - if (addr == _signer) { - return true; - } - } - - if (_signer.code.length != 0) { - // ERC1271 - return IERC1271(_signer).isValidSignature(rPayloadHash, _signature) == IERC1271_MAGIC_VALUE_HASH; - } - - return false; - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/SessionErrors.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/SessionErrors.sol deleted file mode 100644 index 8db69d3e8f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/SessionErrors.sol +++ /dev/null @@ -1,56 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -/// @title SessionErrors -/// @author Michael Standen -/// @notice Errors for the session manager -library SessionErrors { - - /// @notice Invalid session signer - error InvalidSessionSigner(address invalidSigner); - /// @notice Invalid chainId - error InvalidChainId(uint256 invalidChainId); - /// @notice Invalid self call - error InvalidSelfCall(); - /// @notice Invalid delegate call - error InvalidDelegateCall(); - /// @notice Invalid call behavior - error InvalidBehavior(); - /// @notice Invalid value - error InvalidValue(); - /// @notice Invalid node type in session configuration - error InvalidNodeType(uint256 flag); - /// @notice Error thrown when the payload kind is invalid - error InvalidPayloadKind(); - /// @notice Error thrown when the calls length is invalid - error InvalidCallsLength(); - /// @notice Error thrown when the payload space is invalid - error InvalidSpace(uint256 space); - - // ---- Explicit session errors ---- - - /// @notice Missing permission for explicit session - error MissingPermission(); - /// @notice Invalid permission for explicit session - error InvalidPermission(); - /// @notice Session expired - error SessionExpired(uint256 deadline); - /// @notice Invalid limit usage increment - error InvalidLimitUsageIncrement(); - - // ---- Implicit session errors ---- - - /// @notice Blacklisted address - error BlacklistedAddress(address target); - /// @notice Invalid implicit result - error InvalidImplicitResult(); - /// @notice Invalid identity signer - error InvalidIdentitySigner(); - /// @notice Invalid blacklist - error InvalidBlacklist(); - /// @notice Invalid attestation - error InvalidAttestation(); - /// @notice The blacklist was not sorted - error InvalidBlacklistUnsorted(); - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/SessionManager.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/SessionManager.sol deleted file mode 100644 index dee2094137..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/SessionManager.sol +++ /dev/null @@ -1,133 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../../modules/Payload.sol"; -import { ISapient } from "../../modules/interfaces/ISapient.sol"; -import { LibBytes } from "../../utils/LibBytes.sol"; - -import { SessionErrors } from "./SessionErrors.sol"; -import { SessionSig } from "./SessionSig.sol"; -import { - ExplicitSessionManager, - IExplicitSessionManager, - SessionPermissions, - SessionUsageLimits -} from "./explicit/ExplicitSessionManager.sol"; -import { Permission, UsageLimit } from "./explicit/Permission.sol"; -import { ImplicitSessionManager } from "./implicit/ImplicitSessionManager.sol"; - -using LibBytes for bytes; - -/// @title SessionManager -/// @author Michael Standen, Agustin Aguilar -/// @notice Manager for smart sessions -contract SessionManager is ISapient, ImplicitSessionManager, ExplicitSessionManager { - - /// @notice Maximum nonce space allowed for sessions use. - /// @dev This excludes half the possible bits (uint160 vs uint80) - uint256 public constant MAX_SPACE = type(uint80).max - 1; - - /// @inheritdoc ISapient - function recoverSapientSignature( - Payload.Decoded calldata payload, - bytes calldata encodedSignature - ) external view returns (bytes32) { - // Validate outer Payload - if (payload.kind != Payload.KIND_TRANSACTIONS) { - revert SessionErrors.InvalidPayloadKind(); - } - if (payload.space > MAX_SPACE) { - revert SessionErrors.InvalidSpace(payload.space); - } - if (payload.calls.length == 0) { - revert SessionErrors.InvalidCallsLength(); - } - - // Decode signature - SessionSig.DecodedSignature memory sig = SessionSig.recoverSignature(payload, encodedSignature); - - address wallet = msg.sender; - - // Initialize session usage limits for explicit session - SessionUsageLimits[] memory sessionUsageLimits = new SessionUsageLimits[](payload.calls.length); - - for (uint256 i = 0; i < payload.calls.length; i++) { - Payload.Call calldata call = payload.calls[i]; - - // Ban delegate calls - if (call.delegateCall) { - revert SessionErrors.InvalidDelegateCall(); - } - // Ban self calls to the wallet - if (call.to == wallet) { - revert SessionErrors.InvalidSelfCall(); - } - - // Check if this call could cause usage limits to be skipped - if (call.behaviorOnError == Payload.BEHAVIOR_ABORT_ON_ERROR) { - revert SessionErrors.InvalidBehavior(); - } - - // Validate call signature - SessionSig.CallSignature memory callSignature = sig.callSignatures[i]; - if (callSignature.isImplicit) { - // Validate implicit calls - _validateImplicitCall( - call, wallet, callSignature.sessionSigner, callSignature.attestation, sig.implicitBlacklist - ); - } else { - // Find the session usage limits for the current call - SessionUsageLimits memory limits; - uint256 limitsIdx; - for (limitsIdx = 0; limitsIdx < sessionUsageLimits.length; limitsIdx++) { - if (sessionUsageLimits[limitsIdx].signer == address(0)) { - // Initialize new session usage limits - limits.signer = callSignature.sessionSigner; - limits.limits = new UsageLimit[](0); - bytes32 usageHash = keccak256(abi.encode(callSignature.sessionSigner, VALUE_TRACKING_ADDRESS)); - limits.totalValueUsed = getLimitUsage(wallet, usageHash); - break; - } - if (sessionUsageLimits[limitsIdx].signer == callSignature.sessionSigner) { - limits = sessionUsageLimits[limitsIdx]; - break; - } - } - // Validate explicit calls. Obtain usage limits for increment validation. - (limits) = _validateExplicitCall( - payload, - i, - wallet, - callSignature.sessionSigner, - sig.sessionPermissions, - callSignature.sessionPermission, - limits - ); - sessionUsageLimits[limitsIdx] = limits; - } - } - - { - // Reduce the size of the sessionUsageLimits array - SessionUsageLimits[] memory actualSessionUsageLimits = new SessionUsageLimits[](sessionUsageLimits.length); - uint256 actualSize; - for (uint256 i = 0; i < sessionUsageLimits.length; i++) { - if (sessionUsageLimits[i].limits.length > 0 || sessionUsageLimits[i].totalValueUsed > 0) { - actualSessionUsageLimits[actualSize] = sessionUsageLimits[i]; - actualSize++; - } - } - assembly { - mstore(actualSessionUsageLimits, actualSize) - } - - // Bulk validate the updated usage limits - Payload.Call calldata firstCall = payload.calls[0]; - _validateLimitUsageIncrement(firstCall, actualSessionUsageLimits); - } - - // Return the image hash - return sig.imageHash; - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/SessionSig.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/SessionSig.sol deleted file mode 100644 index 493b522fb1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/SessionSig.sol +++ /dev/null @@ -1,421 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../../modules/Payload.sol"; -import { LibBytes } from "../../utils/LibBytes.sol"; -import { LibOptim } from "../../utils/LibOptim.sol"; -import { SessionErrors } from "./SessionErrors.sol"; -import { SessionPermissions } from "./explicit/IExplicitSessionManager.sol"; -import { LibPermission, Permission } from "./explicit/Permission.sol"; -import { Attestation, LibAttestation } from "./implicit/Attestation.sol"; - -using LibBytes for bytes; -using LibAttestation for Attestation; - -/// @title SessionSig -/// @author Michael Standen, Agustin Aguilar -/// @notice Library for session signatures -library SessionSig { - - uint256 internal constant FLAG_PERMISSIONS = 0; - uint256 internal constant FLAG_NODE = 1; - uint256 internal constant FLAG_BRANCH = 2; - uint256 internal constant FLAG_BLACKLIST = 3; - uint256 internal constant FLAG_IDENTITY_SIGNER = 4; - - uint256 internal constant MIN_ENCODED_PERMISSION_SIZE = 94; - - /// @notice Call signature for a specific session - /// @param isImplicit If the call is implicit - /// @param sessionSigner Address of the session signer - /// @param sessionPermission Session permission for explicit calls - /// @param attestation Attestation for implicit calls - struct CallSignature { - bool isImplicit; - address sessionSigner; - uint8 sessionPermission; - Attestation attestation; - } - - /// @notice Decoded signature for a specific session - /// @param imageHash Derived configuration image hash - /// @param identitySigner Identity signer address - /// @param implicitBlacklist Implicit blacklist addresses - /// @param sessionPermissions Session permissions for each explicit signer - /// @param callSignatures Call signatures for each call in the payload - struct DecodedSignature { - bytes32 imageHash; - address identitySigner; - address[] implicitBlacklist; - SessionPermissions[] sessionPermissions; - CallSignature[] callSignatures; - } - - /// @notice Recovers the decoded signature from the encodedSignature bytes. - /// @dev The encoded layout is conceptually separated into three parts: - /// 1) Session Configuration - /// 2) A reusable list of Attestations + their identity signatures (if any implicit calls exist) - /// 3) Call Signatures (one per call in the payload) - /// - /// High-level layout: - /// - session_configuration: [uint24 size, ] - /// - attestation_list: [uint8 attestationCount, (Attestation + identitySig) * attestationCount] - /// (new section to allow reusing the same Attestation across multiple calls) - /// - call_signatures: [] - Size is payload.calls.length - /// - call_signature: [uint8 call_flags, ] - /// - call_flags: [bool is_implicit (MSB), 7 bits encoded] - /// - if call_flags.is_implicit.MSB == 1: - /// - attestation_index: [uint8 index into the attestation list (7 bits of the call_flags)] - /// - session_signature: [r, s, v (compact)] - /// - if call_flags.is_implicit.MSB == 0: - /// - session_permission: [uint8 (7 bits of the call_flags)] - /// - session_signature: [r, s, v (compact)] - function recoverSignature( - Payload.Decoded calldata payload, - bytes calldata encodedSignature - ) internal view returns (DecodedSignature memory sig) { - uint256 pointer = 0; - bool hasBlacklistInConfig; - - // ----- Session Configuration ----- - { - // First read the length of the session configuration bytes (uint24) - uint256 dataSize; - (dataSize, pointer) = encodedSignature.readUint24(pointer); - - // Recover the session configuration - (sig, hasBlacklistInConfig) = recoverConfiguration(encodedSignature[pointer:pointer + dataSize]); - pointer += dataSize; - - // Identity signer must be set - if (sig.identitySigner == address(0)) { - revert SessionErrors.InvalidIdentitySigner(); - } - } - - // ----- Attestations for implicit calls ----- - Attestation[] memory attestationList; - { - uint8 attestationCount; - (attestationCount, pointer) = encodedSignature.readUint8(pointer); - attestationList = new Attestation[](attestationCount); - // Parse each attestation and its identity signature, store in memory - for (uint256 i = 0; i < attestationCount; i++) { - Attestation memory att; - (att, pointer) = LibAttestation.fromPacked(encodedSignature, pointer); - - // Read the identity signature that approves this attestation - { - bytes32 r; - bytes32 s; - uint8 v; - (r, s, v, pointer) = encodedSignature.readRSVCompact(pointer); - - // Recover the identity signer from the attestation identity signature - bytes32 attestationHash = att.toHash(); - address recoveredIdentitySigner = ecrecover(attestationHash, v, r, s); - if (recoveredIdentitySigner != sig.identitySigner) { - revert SessionErrors.InvalidIdentitySigner(); - } - } - - attestationList[i] = att; - } - - // If we have any implicit calls, we must have a blacklist in the configuration - if (attestationCount > 0 && !hasBlacklistInConfig) { - revert SessionErrors.InvalidBlacklist(); - } - } - - // ----- Call Signatures ----- - { - uint256 callsCount = payload.calls.length; - sig.callSignatures = new CallSignature[](callsCount); - - for (uint256 i = 0; i < callsCount; i++) { - CallSignature memory callSignature; - - // Determine signature type - { - uint8 flag; - (flag, pointer) = encodedSignature.readUint8(pointer); - callSignature.isImplicit = (flag & 0x80) != 0; - - if (callSignature.isImplicit) { - // Read attestation index from the call_flags - uint8 attestationIndex = uint8(flag & 0x7f); - - // Check if the attestation index is out of range - if (attestationIndex >= attestationList.length) { - revert SessionErrors.InvalidAttestation(); - } - - // Set the attestation - callSignature.attestation = attestationList[attestationIndex]; - } else { - // Session permission index is the entire byte, top bit is 0 => no conflict - callSignature.sessionPermission = flag; - } - } - - // Read session signature and recover the signer - { - bytes32 r; - bytes32 s; - uint8 v; - (r, s, v, pointer) = encodedSignature.readRSVCompact(pointer); - - bytes32 callHash = hashCallWithReplayProtection(payload, i); - callSignature.sessionSigner = ecrecover(callHash, v, r, s); - if (callSignature.sessionSigner == address(0)) { - revert SessionErrors.InvalidSessionSigner(address(0)); - } - } - - sig.callSignatures[i] = callSignature; - } - } - - return sig; - } - - /// @notice Recovers the session configuration from the encoded data. - /// The encoded layout is: - /// - permissions_count: [uint8] - /// - permissions_tree_element: [flag, ] - /// - flag: [uint8] - /// - data: [data] - /// - if flag == FLAG_PERMISSIONS: [SessionPermissions encoded] - /// - if flag == FLAG_NODE: [bytes32 node] - /// - if flag == FLAG_BRANCH: [uint256 size, nested encoding...] - /// - if flag == FLAG_BLACKLIST: [uint24 blacklist_count, blacklist_addresses...] - /// - if flag == FLAG_IDENTITY_SIGNER: [address identity_signer] - /// @dev A valid configuration must have exactly one identity signer and at most one blacklist. - function recoverConfiguration( - bytes calldata encoded - ) internal pure returns (DecodedSignature memory sig, bool hasBlacklist) { - uint256 pointer; - uint256 permissionsCount; - - // Guess maximum permissions size by bytes length - { - uint256 maxPermissionsSize = encoded.length / MIN_ENCODED_PERMISSION_SIZE; - sig.sessionPermissions = new SessionPermissions[](maxPermissionsSize); - } - - while (pointer < encoded.length) { - // First byte is the flag (top 4 bits) and additional data (bottom 4 bits) - uint256 firstByte; - (firstByte, pointer) = encoded.readUint8(pointer); - // The top 4 bits are the flag - uint256 flag = (firstByte & 0xf0) >> 4; - - // Permissions configuration (0x00) - if (flag == FLAG_PERMISSIONS) { - SessionPermissions memory nodePermissions; - uint256 pointerStart = pointer; - - // Read signer - (nodePermissions.signer, pointer) = encoded.readAddress(pointer); - - // Read chainId - (nodePermissions.chainId, pointer) = encoded.readUint256(pointer); - - // Read value limit - (nodePermissions.valueLimit, pointer) = encoded.readUint256(pointer); - - // Read deadline - (nodePermissions.deadline, pointer) = encoded.readUint64(pointer); - - // Read permissions array - (nodePermissions.permissions, pointer) = _decodePermissions(encoded, pointer); - - // Update root - { - bytes32 permissionHash = _leafHashForPermissions(encoded[pointerStart:pointer]); - sig.imageHash = - sig.imageHash != bytes32(0) ? LibOptim.fkeccak256(sig.imageHash, permissionHash) : permissionHash; - } - - // Push node permissions to the permissions array - sig.sessionPermissions[permissionsCount++] = nodePermissions; - continue; - } - - // Node (0x01) - if (flag == FLAG_NODE) { - // Read pre-hashed node - bytes32 node; - (node, pointer) = encoded.readBytes32(pointer); - - // Update root - sig.imageHash = sig.imageHash != bytes32(0) ? LibOptim.fkeccak256(sig.imageHash, node) : node; - - continue; - } - - // Branch (0x02) - if (flag == FLAG_BRANCH) { - // Read branch size - uint256 size; - { - uint256 sizeSize = uint8(firstByte & 0x0f); - (size, pointer) = encoded.readUintX(pointer, sizeSize); - } - // Process branch - uint256 nrindex = pointer + size; - (DecodedSignature memory branchSig, bool branchHasBlacklist) = recoverConfiguration(encoded[pointer:nrindex]); - pointer = nrindex; - - // Store the branch blacklist - if (branchHasBlacklist) { - if (hasBlacklist) { - // Blacklist already set - revert SessionErrors.InvalidBlacklist(); - } - hasBlacklist = true; - sig.implicitBlacklist = branchSig.implicitBlacklist; - } - - // Store the branch identity signer - if (branchSig.identitySigner != address(0)) { - if (sig.identitySigner != address(0)) { - // Identity signer already set - revert SessionErrors.InvalidIdentitySigner(); - } - sig.identitySigner = branchSig.identitySigner; - } - - // Push all branch permissions to the permissions array - for (uint256 i = 0; i < branchSig.sessionPermissions.length; i++) { - sig.sessionPermissions[permissionsCount++] = branchSig.sessionPermissions[i]; - } - - // Update root - sig.imageHash = - sig.imageHash != bytes32(0) ? LibOptim.fkeccak256(sig.imageHash, branchSig.imageHash) : branchSig.imageHash; - - continue; - } - - // Blacklist (0x03) - if (flag == FLAG_BLACKLIST) { - if (hasBlacklist) { - // Blacklist already set - revert SessionErrors.InvalidBlacklist(); - } - hasBlacklist = true; - - // Read the blacklist count from the first byte's lower 4 bits - uint256 blacklistCount = uint256(firstByte & 0x0f); - if (blacklistCount == 0x0f) { - // If it's max nibble, read the next 2 bytes for the actual size - (blacklistCount, pointer) = encoded.readUint16(pointer); - } - uint256 pointerStart = pointer; - - // Read the blacklist addresses - sig.implicitBlacklist = new address[](blacklistCount); - address previousAddress; - for (uint256 i = 0; i < blacklistCount; i++) { - (sig.implicitBlacklist[i], pointer) = encoded.readAddress(pointer); - if (sig.implicitBlacklist[i] < previousAddress) { - revert SessionErrors.InvalidBlacklistUnsorted(); - } - previousAddress = sig.implicitBlacklist[i]; - } - - // Update the root - bytes32 blacklistHash = _leafHashForBlacklist(encoded[pointerStart:pointer]); - sig.imageHash = sig.imageHash != bytes32(0) ? LibOptim.fkeccak256(sig.imageHash, blacklistHash) : blacklistHash; - - continue; - } - - // Identity signer (0x04) - if (flag == FLAG_IDENTITY_SIGNER) { - if (sig.identitySigner != address(0)) { - // Identity signer already set - revert SessionErrors.InvalidIdentitySigner(); - } - (sig.identitySigner, pointer) = encoded.readAddress(pointer); - - // Update the root - bytes32 identitySignerHash = _leafHashForIdentitySigner(sig.identitySigner); - sig.imageHash = - sig.imageHash != bytes32(0) ? LibOptim.fkeccak256(sig.imageHash, identitySignerHash) : identitySignerHash; - - continue; - } - - revert SessionErrors.InvalidNodeType(flag); - } - - { - // Update the permissions array length to the actual count - SessionPermissions[] memory permissions = sig.sessionPermissions; - assembly { - mstore(permissions, permissionsCount) - } - } - - return (sig, hasBlacklist); - } - - /// @notice Decodes an array of Permission objects from the encoded data. - function _decodePermissions( - bytes calldata encoded, - uint256 pointer - ) internal pure returns (Permission[] memory permissions, uint256 newPointer) { - uint256 length; - (length, pointer) = encoded.readUint8(pointer); - permissions = new Permission[](length); - for (uint256 i = 0; i < length; i++) { - (permissions[i], pointer) = LibPermission.readPermission(encoded, pointer); - } - return (permissions, pointer); - } - - /// @notice Hashes the encoded session permissions into a leaf node. - function _leafHashForPermissions( - bytes calldata encodedPermissions - ) internal pure returns (bytes32) { - return keccak256(abi.encodePacked(uint8(FLAG_PERMISSIONS), encodedPermissions)); - } - - /// @notice Hashes the encoded blacklist into a leaf node. - function _leafHashForBlacklist( - bytes calldata encodedBlacklist - ) internal pure returns (bytes32) { - return keccak256(abi.encodePacked(uint8(FLAG_BLACKLIST), encodedBlacklist)); - } - - /// @notice Hashes the identity signer into a leaf node. - function _leafHashForIdentitySigner( - address identitySigner - ) internal pure returns (bytes32) { - return keccak256(abi.encodePacked(uint8(FLAG_IDENTITY_SIGNER), identitySigner)); - } - - /// @notice Hashes a call with replay protection. - /// @dev The replay protection is based on the chainId, space, nonce and index in the payload. - /// @param payload The payload to hash - /// @param callIdx The index of the call to hash - /// @return callHash The hash of the call with replay protection - function hashCallWithReplayProtection( - Payload.Decoded calldata payload, - uint256 callIdx - ) public view returns (bytes32 callHash) { - return keccak256( - abi.encodePacked( - payload.noChainId ? 0 : block.chainid, - payload.space, - payload.nonce, - callIdx, - Payload.hashCall(payload.calls[callIdx]) - ) - ); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/explicit/ExplicitSessionManager.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/explicit/ExplicitSessionManager.sol deleted file mode 100644 index 042ce1afb3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/explicit/ExplicitSessionManager.sol +++ /dev/null @@ -1,171 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../../../modules/Payload.sol"; -import { LibBytes } from "../../../utils/LibBytes.sol"; - -import { SessionErrors } from "../SessionErrors.sol"; -import { IExplicitSessionManager, SessionPermissions, SessionUsageLimits } from "./IExplicitSessionManager.sol"; -import { Permission, UsageLimit } from "./Permission.sol"; -import { PermissionValidator } from "./PermissionValidator.sol"; - -abstract contract ExplicitSessionManager is IExplicitSessionManager, PermissionValidator { - - using LibBytes for bytes; - - /// @notice Special address used for tracking native token value limits - address public constant VALUE_TRACKING_ADDRESS = address(0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE); - - /// @inheritdoc IExplicitSessionManager - function incrementUsageLimit( - UsageLimit[] calldata limits - ) external { - address wallet = msg.sender; - for (uint256 i = 0; i < limits.length; i++) { - if (limits[i].usageAmount < getLimitUsage(wallet, limits[i].usageHash)) { - // Cannot decrement usage limit - revert SessionErrors.InvalidLimitUsageIncrement(); - } - setLimitUsage(wallet, limits[i].usageHash, limits[i].usageAmount); - } - } - - /// @notice Validates an explicit call - /// @param payload The decoded payload containing calls - /// @param callIdx The index of the call to validate - /// @param wallet The wallet's address - /// @param sessionSigner The session signer's address - /// @param allSessionPermissions All sessions' permissions - /// @param permissionIdx The index of the permission to validate - /// @param sessionUsageLimits The session usage limits - /// @return newSessionUsageLimits The updated session usage limits - function _validateExplicitCall( - Payload.Decoded calldata payload, - uint256 callIdx, - address wallet, - address sessionSigner, - SessionPermissions[] memory allSessionPermissions, - uint8 permissionIdx, - SessionUsageLimits memory sessionUsageLimits - ) internal view returns (SessionUsageLimits memory newSessionUsageLimits) { - // Find the permissions for the given session signer - SessionPermissions memory sessionPermissions; - for (uint256 i = 0; i < allSessionPermissions.length; i++) { - if (allSessionPermissions[i].signer == sessionSigner) { - sessionPermissions = allSessionPermissions[i]; - break; - } - } - if (sessionPermissions.signer == address(0)) { - revert SessionErrors.InvalidSessionSigner(sessionSigner); - } - - // Check if session chainId is valid - if (sessionPermissions.chainId != 0 && sessionPermissions.chainId != block.chainid) { - revert SessionErrors.InvalidChainId(sessionPermissions.chainId); - } - - // Check if session has expired. - if (sessionPermissions.deadline != 0 && block.timestamp > sessionPermissions.deadline) { - revert SessionErrors.SessionExpired(sessionPermissions.deadline); - } - - // Delegate calls are not allowed - Payload.Call calldata call = payload.calls[callIdx]; - if (call.delegateCall) { - revert SessionErrors.InvalidDelegateCall(); - } - - // Calls to incrementUsageLimit are the only allowed calls to this contract - if (call.to == address(this)) { - if (callIdx != 0) { - // IncrementUsageLimit call is only allowed as the first call - revert SessionErrors.InvalidLimitUsageIncrement(); - } - if (call.value > 0) { - revert SessionErrors.InvalidValue(); - } - // No permissions required for the increment call - return sessionUsageLimits; - } - - // Get the permission for the current call - if (permissionIdx >= sessionPermissions.permissions.length) { - revert SessionErrors.MissingPermission(); - } - Permission memory permission = sessionPermissions.permissions[permissionIdx]; - - // Validate the permission for the current call - (bool isValid, UsageLimit[] memory limits) = - validatePermission(permission, call, wallet, sessionSigner, sessionUsageLimits.limits); - if (!isValid) { - revert SessionErrors.InvalidPermission(); - } - sessionUsageLimits.limits = limits; - - // Increment the total value used - if (call.value > 0) { - sessionUsageLimits.totalValueUsed += call.value; - } - if (sessionUsageLimits.totalValueUsed > sessionPermissions.valueLimit) { - // Value limit exceeded - revert SessionErrors.InvalidValue(); - } - - return sessionUsageLimits; - } - - /// @notice Verifies the limit usage increment - /// @param call The first call in the payload, which is expected to be the increment call - /// @param sessionUsageLimits The session usage limits - /// @dev Reverts if the required increment call is missing or invalid - /// @dev If no usage limits are used, this function does nothing - function _validateLimitUsageIncrement( - Payload.Call calldata call, - SessionUsageLimits[] memory sessionUsageLimits - ) internal view { - // Limits call is only required if there are usage limits used - if (sessionUsageLimits.length > 0) { - // Verify the first call is the increment call and cannot be skipped - if (call.to != address(this) || call.behaviorOnError != Payload.BEHAVIOR_REVERT_ON_ERROR || call.onlyFallback) { - revert SessionErrors.InvalidLimitUsageIncrement(); - } - - // Construct expected limit increments - uint256 totalLimitsLength = 0; - for (uint256 i = 0; i < sessionUsageLimits.length; i++) { - totalLimitsLength += sessionUsageLimits[i].limits.length; - if (sessionUsageLimits[i].totalValueUsed > 0) { - totalLimitsLength++; - } - } - UsageLimit[] memory limits = new UsageLimit[](totalLimitsLength); - uint256 limitIndex = 0; - for (uint256 i = 0; i < sessionUsageLimits.length; i++) { - for (uint256 j = 0; j < sessionUsageLimits[i].limits.length; j++) { - limits[limitIndex++] = sessionUsageLimits[i].limits[j]; - } - if (sessionUsageLimits[i].totalValueUsed > 0) { - limits[limitIndex++] = UsageLimit({ - usageHash: keccak256(abi.encode(sessionUsageLimits[i].signer, VALUE_TRACKING_ADDRESS)), - usageAmount: sessionUsageLimits[i].totalValueUsed - }); - } - } - - // Verify the increment call data - bytes memory expectedData = abi.encodeWithSelector(this.incrementUsageLimit.selector, limits); - bytes32 expectedDataHash = keccak256(expectedData); - bytes32 actualDataHash = keccak256(call.data); - if (actualDataHash != expectedDataHash) { - revert SessionErrors.InvalidLimitUsageIncrement(); - } - } else { - // Do not allow self calls if there are no usage limits - if (call.to == address(this)) { - revert SessionErrors.InvalidLimitUsageIncrement(); - } - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/explicit/IExplicitSessionManager.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/explicit/IExplicitSessionManager.sol deleted file mode 100644 index 051391211c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/explicit/IExplicitSessionManager.sol +++ /dev/null @@ -1,41 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Permission, UsageLimit } from "./Permission.sol"; - -/// @notice Permissions configuration for a specific session signer -/// @param signer Address of the session signer these permissions apply to -/// @param chainId Chain ID of the session (0 = any chain) -/// @param valueLimit Maximum native token value this signer can send -/// @param deadline Deadline for the session. (0 = no deadline) -/// @param permissions Array of encoded permissions granted to this signer -struct SessionPermissions { - address signer; - uint256 chainId; - uint256 valueLimit; - uint64 deadline; - Permission[] permissions; -} - -/// @notice Usage limits configuration for a specific session signer -/// @param signer Address of the session signer these limits apply to -/// @param limits Array of usage limits -/// @param totalValueUsed Total native token value used -struct SessionUsageLimits { - address signer; - UsageLimit[] limits; - uint256 totalValueUsed; -} - -/// @title IExplicitSessionManager -/// @author Agustin Aguilar, Michael Standen -/// @notice Interface for the explicit session manager -interface IExplicitSessionManager { - - /// @notice Increment usage for a caller's given session and target - /// @param limits Array of limit/session/target combinations - function incrementUsageLimit( - UsageLimit[] calldata limits - ) external; - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/explicit/Permission.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/explicit/Permission.sol deleted file mode 100644 index e9ec7452f9..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/explicit/Permission.sol +++ /dev/null @@ -1,112 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { LibBytes } from "../../../utils/LibBytes.sol"; - -/// @notice Permission for a specific session signer -/// @param target Address of the target contract this permission applies to -/// @param rules Array of parameter rules -struct Permission { - address target; - ParameterRule[] rules; -} - -/// @notice Parameter operation for a specific session signer -enum ParameterOperation { - EQUAL, - NOT_EQUAL, - GREATER_THAN_OR_EQUAL, - LESS_THAN_OR_EQUAL -} - -/// @notice Parameter rule for a specific session signer -/// @param cumulative If the value should accumulate over multiple calls -/// @param operation Operation to apply to the parameter -/// @param value Value to compare against the masked parameter -/// @param offset Offset in calldata to read the parameter -/// @param mask Mask to apply to the parameter -struct ParameterRule { - bool cumulative; - ParameterOperation operation; - bytes32 value; - uint256 offset; - bytes32 mask; -} - -/// @notice Usage limit for a specific session signer -/// @param usageHash Usage identifier -/// @param usageAmount Amount of usage -struct UsageLimit { - bytes32 usageHash; - uint256 usageAmount; -} - -using LibBytes for bytes; - -/// @title LibPermission -/// @author Michael Standen -/// @notice Library for permission management -library LibPermission { - - /// @notice Error thrown when the rules length exceeds the maximum - error RulesLengthExceedsMax(); - - /// @notice Reads a permission from a packed bytes array - /// @param encoded The packed bytes array - /// @param pointer The pointer to the start of the permission - /// @return permission The decoded permission - /// @return newPointer The new pointer to the end of the permission - function readPermission( - bytes calldata encoded, - uint256 pointer - ) internal pure returns (Permission memory permission, uint256 newPointer) { - // Target - (permission.target, pointer) = encoded.readAddress(pointer); - // Rules - uint256 rulesLength; - (rulesLength, pointer) = encoded.readUint8(pointer); - permission.rules = new ParameterRule[](rulesLength); - for (uint256 i = 0; i < rulesLength; i++) { - uint8 operationCumulative; - (operationCumulative, pointer) = encoded.readUint8(pointer); - // 000X: cumulative - permission.rules[i].cumulative = operationCumulative & 1 != 0; - // XXX0: operation - permission.rules[i].operation = ParameterOperation(operationCumulative >> 1); - - (permission.rules[i].value, pointer) = encoded.readBytes32(pointer); - (permission.rules[i].offset, pointer) = encoded.readUint256(pointer); - (permission.rules[i].mask, pointer) = encoded.readBytes32(pointer); - } - return (permission, pointer); - } - - /// @notice Encodes a permission into a packed bytes array - /// @param permission The permission to encode - /// @return packed The packed bytes array - function toPacked( - Permission calldata permission - ) internal pure returns (bytes memory packed) { - if (permission.rules.length > type(uint8).max) { - revert RulesLengthExceedsMax(); - } - packed = abi.encodePacked(permission.target, uint8(permission.rules.length)); - for (uint256 i = 0; i < permission.rules.length; i++) { - packed = abi.encodePacked(packed, ruleToPacked(permission.rules[i])); - } - } - - /// @notice Encodes a rule into a packed bytes array - /// @param rule The rule to encode - /// @return packed The packed bytes array - function ruleToPacked( - ParameterRule calldata rule - ) internal pure returns (bytes memory packed) { - // Combine operation and cumulative flag into a single byte - // 0x[operationx3][cumulative] - uint8 operationCumulative = (uint8(rule.operation) << 1) | (rule.cumulative ? 1 : 0); - - return abi.encodePacked(operationCumulative, rule.value, rule.offset, rule.mask); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/explicit/PermissionValidator.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/explicit/PermissionValidator.sol deleted file mode 100644 index 03bae46ef0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/explicit/PermissionValidator.sol +++ /dev/null @@ -1,135 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../../../modules/Payload.sol"; -import { LibBytes } from "../../../utils/LibBytes.sol"; -import { ParameterOperation, ParameterRule, Permission, UsageLimit } from "./Permission.sol"; - -/// @title PermissionValidator -/// @author Michael Standen, Agustin Aguilar -/// @notice Validates permissions for a given call -abstract contract PermissionValidator { - - using LibBytes for bytes; - - /// @notice Emitted when the usage amount for a given wallet and usage hash is updated - event LimitUsageUpdated(address wallet, bytes32 usageHash, uint256 usageAmount); - - /// @notice Mapping of usage limit hashes to their usage amounts - mapping(address => mapping(bytes32 => uint256)) private limitUsage; - - /// @notice Get the usage amount for a given usage hash and wallet - /// @param wallet The wallet address - /// @param usageHash The usage hash - /// @return The usage amount - function getLimitUsage(address wallet, bytes32 usageHash) public view returns (uint256) { - return limitUsage[wallet][usageHash]; - } - - /// @notice Set the usage amount for a given usage hash and wallet - /// @param wallet The wallet address - /// @param usageHash The usage hash - /// @param usageAmount The usage amount - function setLimitUsage(address wallet, bytes32 usageHash, uint256 usageAmount) internal { - limitUsage[wallet][usageHash] = usageAmount; - emit LimitUsageUpdated(wallet, usageHash, usageAmount); - } - - /// @notice Validates a rules permission - /// @param permission The rules permission to validate - /// @param call The call to validate against - /// @param wallet The wallet address - /// @param signer The signer address - /// @param usageLimits Array of current usage limits - /// @return True if the permission is valid, false otherwise - /// @return newUsageLimits New array of usage limits - function validatePermission( - Permission memory permission, - Payload.Call calldata call, - address wallet, - address signer, - UsageLimit[] memory usageLimits - ) public view returns (bool, UsageLimit[] memory newUsageLimits) { - if (permission.target != call.to) { - return (false, usageLimits); - } - - // Copy usage limits into array with space for new rules - newUsageLimits = new UsageLimit[](usageLimits.length + permission.rules.length); - for (uint256 i = 0; i < usageLimits.length; i++) { - newUsageLimits[i] = usageLimits[i]; - } - uint256 actualLimitsCount = usageLimits.length; - - // Check each rule - for (uint256 i = 0; i < permission.rules.length; i++) { - ParameterRule memory rule = permission.rules[i]; - - // Extract value from calldata at offset - (bytes32 value,) = call.data.readBytes32(rule.offset); - - // Apply mask - value = value & rule.mask; - - if (rule.cumulative) { - // Calculate cumulative usage - uint256 value256 = uint256(value); - // Find the usage limit for the current rule - bytes32 usageHash = keccak256(abi.encode(signer, permission, i)); - uint256 previousUsage; - UsageLimit memory usageLimit; - for (uint256 j = 0; j < newUsageLimits.length; j++) { - if (newUsageLimits[j].usageHash == bytes32(0)) { - // Initialize new usage limit - usageLimit = UsageLimit({ usageHash: usageHash, usageAmount: 0 }); - newUsageLimits[j] = usageLimit; - actualLimitsCount = j + 1; - break; - } - if (newUsageLimits[j].usageHash == usageHash) { - // Value exists, use it - usageLimit = newUsageLimits[j]; - previousUsage = usageLimit.usageAmount; - break; - } - } - if (previousUsage == 0) { - // Not in current payload, use storage - previousUsage = getLimitUsage(wallet, usageHash); - } - // Cumulate usage - value256 += previousUsage; - usageLimit.usageAmount = value256; - // Use the cumulative value for comparison - value = bytes32(value256); - } - - // Compare based on operation - if (rule.operation == ParameterOperation.EQUAL) { - if (value != rule.value) { - return (false, usageLimits); - } - } else if (rule.operation == ParameterOperation.LESS_THAN_OR_EQUAL) { - if (uint256(value) > uint256(rule.value)) { - return (false, usageLimits); - } - } else if (rule.operation == ParameterOperation.NOT_EQUAL) { - if (value == rule.value) { - return (false, usageLimits); - } - } else if (rule.operation == ParameterOperation.GREATER_THAN_OR_EQUAL) { - if (uint256(value) < uint256(rule.value)) { - return (false, usageLimits); - } - } - } - - // Fix array length - assembly { - mstore(newUsageLimits, actualLimitsCount) - } - - return (true, newUsageLimits); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol deleted file mode 100644 index 657d9169c4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol +++ /dev/null @@ -1,122 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { LibBytes } from "../../../utils/LibBytes.sol"; -import { ACCEPT_IMPLICIT_REQUEST_MAGIC_PREFIX } from "./ISignalsImplicitMode.sol"; - -using LibBytes for bytes; - -/// @notice Attestation for a specific session -/// @param approvedSigner Address of the approved signer -/// @param identityType Identity type -/// @param issuerHash Hash of the issuer -/// @param audienceHash Hash of the audience -/// @param applicationData Unspecified application data -/// @param authData Auth data -struct Attestation { - address approvedSigner; - bytes4 identityType; - bytes32 issuerHash; - bytes32 audienceHash; - bytes applicationData; - AuthData authData; -} - -/// @notice Auth data for an attestation -/// @param redirectUrl Authorization redirect URL -/// @param issuedAt Timestamp of the attestation issuance -struct AuthData { - string redirectUrl; - uint64 issuedAt; -} - -/// @title LibAttestation -/// @author Michael Standen -/// @notice Library for attestation management -library LibAttestation { - - /// @notice Hashes an attestation - function toHash( - Attestation memory attestation - ) internal pure returns (bytes32) { - return keccak256(toPacked(attestation)); - } - - /// @notice Decodes an attestation from a packed bytes array - /// @param encoded The packed bytes array - /// @param pointer The pointer to the start of the attestation - /// @return attestation The decoded attestation - /// @return newPointer The new pointer to the end of the attestation - function fromPacked( - bytes calldata encoded, - uint256 pointer - ) internal pure returns (Attestation memory attestation, uint256 newPointer) { - newPointer = pointer; - (attestation.approvedSigner, newPointer) = encoded.readAddress(newPointer); - (attestation.identityType, newPointer) = encoded.readBytes4(newPointer); - (attestation.issuerHash, newPointer) = encoded.readBytes32(newPointer); - (attestation.audienceHash, newPointer) = encoded.readBytes32(newPointer); - // Application data (arbitrary bytes) - uint256 dataSize; - (dataSize, newPointer) = encoded.readUint24(newPointer); - attestation.applicationData = encoded[newPointer:newPointer + dataSize]; - newPointer += dataSize; - // Auth data - (attestation.authData, newPointer) = fromPackedAuthData(encoded, newPointer); - return (attestation, newPointer); - } - - /// @notice Decodes the auth data from a packed bytes - /// @param encoded The packed bytes containing the auth data - /// @param pointer The pointer to the start of the auth data within the encoded data - /// @return authData The decoded auth data - /// @return newPointer The pointer to the end of the auth data within the encoded data - function fromPackedAuthData( - bytes calldata encoded, - uint256 pointer - ) internal pure returns (AuthData memory authData, uint256 newPointer) { - uint24 redirectUrlLength; - (redirectUrlLength, pointer) = encoded.readUint24(pointer); - authData.redirectUrl = string(encoded[pointer:pointer + redirectUrlLength]); - pointer += redirectUrlLength; - (authData.issuedAt, pointer) = encoded.readUint64(pointer); - return (authData, pointer); - } - - /// @notice Encodes an attestation into a packed bytes array - /// @param attestation The attestation to encode - /// @return encoded The packed bytes array - function toPacked( - Attestation memory attestation - ) internal pure returns (bytes memory encoded) { - return abi.encodePacked( - attestation.approvedSigner, - attestation.identityType, - attestation.issuerHash, - attestation.audienceHash, - uint24(attestation.applicationData.length), - attestation.applicationData, - toPackAuthData(attestation.authData) - ); - } - - /// @notice Encodes the auth data into a packed bytes array - /// @param authData The auth data to encode - /// @return encoded The packed bytes array - function toPackAuthData( - AuthData memory authData - ) internal pure returns (bytes memory encoded) { - return abi.encodePacked(uint24(bytes(authData.redirectUrl).length), bytes(authData.redirectUrl), authData.issuedAt); - } - - /// @notice Generates the implicit request magic return value - /// @param attestation The attestation - /// @param wallet The wallet - /// @return magic The expected implicit request magic - function generateImplicitRequestMagic(Attestation memory attestation, address wallet) internal pure returns (bytes32) { - return keccak256( - abi.encodePacked(ACCEPT_IMPLICIT_REQUEST_MAGIC_PREFIX, wallet, attestation.audienceHash, attestation.issuerHash) - ); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol deleted file mode 100644 index 5ebfc4f506..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol +++ /dev/null @@ -1,26 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../../../modules/Payload.sol"; -import { Attestation } from "./Attestation.sol"; - -/// @dev Magic prefix for the implicit request -bytes32 constant ACCEPT_IMPLICIT_REQUEST_MAGIC_PREFIX = keccak256(abi.encodePacked("acceptImplicitRequest")); - -/// @title ISignalsImplicitMode -/// @author Agustin Aguilar, Michael Standen -/// @notice Interface for the contracts that support implicit mode validation -interface ISignalsImplicitMode { - - /// @notice Determines if an implicit request is valid - /// @param wallet The wallet's address - /// @param attestation The attestation data - /// @param call The call to validate - /// @return magic The hash of the implicit request if valid - function acceptImplicitRequest( - address wallet, - Attestation calldata attestation, - Payload.Call calldata call - ) external view returns (bytes32 magic); - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/implicit/ImplicitSessionManager.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/implicit/ImplicitSessionManager.sol deleted file mode 100644 index 0f3ca88a06..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/extensions/sessions/implicit/ImplicitSessionManager.sol +++ /dev/null @@ -1,83 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../../../modules/Payload.sol"; - -import { SessionErrors } from "../SessionErrors.sol"; -import { Attestation, LibAttestation } from "./Attestation.sol"; -import { ISignalsImplicitMode } from "./ISignalsImplicitMode.sol"; - -using LibAttestation for Attestation; - -/// @title ImplicitSessionManager -/// @author Agustin Aguilar, Michael Standen -/// @notice Manager for implicit sessions -abstract contract ImplicitSessionManager { - - /// @notice Validates a call in implicit mode - /// @param call The call to validate - /// @param wallet The wallet's address - /// @param sessionSigner The session signer's address - /// @param attestation The session attestation - function _validateImplicitCall( - Payload.Call calldata call, - address wallet, - address sessionSigner, - Attestation memory attestation, - address[] memory blacklist - ) internal view { - // Validate the session signer is attested - if (sessionSigner != attestation.approvedSigner) { - revert SessionErrors.InvalidSessionSigner(sessionSigner); - } - - // Delegate calls are not allowed - if (call.delegateCall) { - revert SessionErrors.InvalidDelegateCall(); - } - // Check if the signer is blacklisted - if (_isAddressBlacklisted(sessionSigner, blacklist)) { - revert SessionErrors.BlacklistedAddress(sessionSigner); - } - // Check if the target address is blacklisted - if (_isAddressBlacklisted(call.to, blacklist)) { - revert SessionErrors.BlacklistedAddress(call.to); - } - // No value - if (call.value > 0) { - revert SessionErrors.InvalidValue(); - } - - // Validate the implicit request - bytes32 result = ISignalsImplicitMode(call.to).acceptImplicitRequest(wallet, attestation, call); - bytes32 attestationMagic = attestation.generateImplicitRequestMagic(wallet); - if (result != attestationMagic) { - revert SessionErrors.InvalidImplicitResult(); - } - } - - /// @notice Checks if an address is in the blacklist using binary search - /// @param target The address to check - /// @param blacklist The sorted array of blacklisted addresses - /// @return bool True if the address is blacklisted, false otherwise - function _isAddressBlacklisted(address target, address[] memory blacklist) internal pure returns (bool) { - int256 left = 0; - int256 right = int256(blacklist.length) - 1; - - while (left <= right) { - int256 mid = left + (right - left) / 2; - address currentAddress = blacklist[uint256(mid)]; - - if (currentAddress == target) { - return true; - } else if (currentAddress < target) { - left = mid + 1; - } else { - right = mid - 1; - } - } - - return false; - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Calls.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Calls.sol deleted file mode 100644 index cd3f009a34..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Calls.sol +++ /dev/null @@ -1,124 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { LibOptim } from "../utils/LibOptim.sol"; -import { Nonce } from "./Nonce.sol"; -import { Payload } from "./Payload.sol"; - -import { ReentrancyGuard } from "./ReentrancyGuard.sol"; -import { BaseAuth } from "./auth/BaseAuth.sol"; -import { IDelegatedExtension } from "./interfaces/IDelegatedExtension.sol"; - -/// @title Calls -/// @author Agustin Aguilar, Michael Standen, William Hua -/// @notice Contract for executing calls -abstract contract Calls is ReentrancyGuard, BaseAuth, Nonce { - - /// @notice Emitted when a call succeeds - event CallSucceeded(bytes32 _opHash, uint256 _index); - /// @notice Emitted when a call fails - event CallFailed(bytes32 _opHash, uint256 _index, bytes _returnData); - /// @notice Emitted when a call is aborted - event CallAborted(bytes32 _opHash, uint256 _index, bytes _returnData); - /// @notice Emitted when a call is skipped - event CallSkipped(bytes32 _opHash, uint256 _index); - - /// @notice Error thrown when a call reverts - error Reverted(Payload.Decoded _payload, uint256 _index, bytes _returnData); - /// @notice Error thrown when a signature is invalid - error InvalidSignature(Payload.Decoded _payload, bytes _signature); - /// @notice Error thrown when there is not enough gas - error NotEnoughGas(Payload.Decoded _payload, uint256 _index, uint256 _gasLeft); - - /// @notice Execute a call - /// @param _payload The payload - /// @param _signature The signature - function execute(bytes calldata _payload, bytes calldata _signature) external payable virtual nonReentrant { - uint256 startingGas = gasleft(); - Payload.Decoded memory decoded = Payload.fromPackedCalls(_payload); - - _consumeNonce(decoded.space, decoded.nonce); - (bool isValid, bytes32 opHash) = signatureValidation(decoded, _signature); - - if (!isValid) { - revert InvalidSignature(decoded, _signature); - } - - _execute(startingGas, opHash, decoded); - } - - /// @notice Execute a call - /// @dev Callable only by the contract itself - /// @param _payload The payload - function selfExecute( - bytes calldata _payload - ) external payable virtual onlySelf { - uint256 startingGas = gasleft(); - Payload.Decoded memory decoded = Payload.fromPackedCalls(_payload); - bytes32 opHash = Payload.hash(decoded); - _execute(startingGas, opHash, decoded); - } - - function _execute(uint256 _startingGas, bytes32 _opHash, Payload.Decoded memory _decoded) private { - bool errorFlag = false; - - uint256 numCalls = _decoded.calls.length; - for (uint256 i = 0; i < numCalls; i++) { - Payload.Call memory call = _decoded.calls[i]; - - // Skip onlyFallback calls if no error occurred - if (call.onlyFallback && !errorFlag) { - emit CallSkipped(_opHash, i); - continue; - } - - // Reset the error flag - // onlyFallback calls only apply when the immediately preceding transaction fails - errorFlag = false; - - uint256 gasLimit = call.gasLimit; - if (gasLimit != 0 && gasleft() < gasLimit) { - revert NotEnoughGas(_decoded, i, gasleft()); - } - - bool success; - if (call.delegateCall) { - (success) = LibOptim.delegatecall( - call.to, - gasLimit == 0 ? gasleft() : gasLimit, - abi.encodeWithSelector( - IDelegatedExtension.handleSequenceDelegateCall.selector, - _opHash, - _startingGas, - i, - numCalls, - _decoded.space, - call.data - ) - ); - } else { - (success) = LibOptim.call(call.to, call.value, gasLimit == 0 ? gasleft() : gasLimit, call.data); - } - - if (!success) { - if (call.behaviorOnError == Payload.BEHAVIOR_IGNORE_ERROR) { - errorFlag = true; - emit CallFailed(_opHash, i, LibOptim.returnData()); - continue; - } - - if (call.behaviorOnError == Payload.BEHAVIOR_REVERT_ON_ERROR) { - revert Reverted(_decoded, i, LibOptim.returnData()); - } - - if (call.behaviorOnError == Payload.BEHAVIOR_ABORT_ON_ERROR) { - emit CallAborted(_opHash, i, LibOptim.returnData()); - break; - } - } - - emit CallSucceeded(_opHash, i); - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/ERC4337v07.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/ERC4337v07.sol deleted file mode 100644 index d8c100968d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/ERC4337v07.sol +++ /dev/null @@ -1,73 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.18; - -import { Calls } from "./Calls.sol"; - -import { ReentrancyGuard } from "./ReentrancyGuard.sol"; -import { IAccount, PackedUserOperation } from "./interfaces/IAccount.sol"; -import { IERC1271_MAGIC_VALUE_HASH } from "./interfaces/IERC1271.sol"; -import { IEntryPoint } from "./interfaces/IEntryPoint.sol"; - -/// @title ERC4337v07 -/// @author Agustin Aguilar, Michael Standen -/// @notice ERC4337 v7 support -abstract contract ERC4337v07 is ReentrancyGuard, IAccount, Calls { - - uint256 internal constant SIG_VALIDATION_FAILED = 1; - - address public immutable entrypoint; - - error InvalidEntryPoint(address _entrypoint); - error ERC4337Disabled(); - - constructor( - address _entrypoint - ) { - entrypoint = _entrypoint; - } - - /// @inheritdoc IAccount - function validateUserOp( - PackedUserOperation calldata userOp, - bytes32 userOpHash, - uint256 missingAccountFunds - ) external returns (uint256 validationData) { - if (entrypoint == address(0)) { - revert ERC4337Disabled(); - } - - if (msg.sender != entrypoint) { - revert InvalidEntryPoint(msg.sender); - } - - // userOp.nonce is validated by the entrypoint - - if (missingAccountFunds != 0) { - IEntryPoint(entrypoint).depositTo{ value: missingAccountFunds }(address(this)); - } - - if (this.isValidSignature(userOpHash, userOp.signature) != IERC1271_MAGIC_VALUE_HASH) { - return SIG_VALIDATION_FAILED; - } - - return 0; - } - - /// @notice Execute a user operation - /// @param _payload The packed payload - /// @dev This is the execute function for the EntryPoint to call. - function executeUserOp( - bytes calldata _payload - ) external nonReentrant { - if (entrypoint == address(0)) { - revert ERC4337Disabled(); - } - - if (msg.sender != entrypoint) { - revert InvalidEntryPoint(msg.sender); - } - - this.selfExecute(_payload); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Hooks.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Hooks.sol deleted file mode 100644 index ca0e1fabcb..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Hooks.sol +++ /dev/null @@ -1,124 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Storage } from "./Storage.sol"; -import { SelfAuth } from "./auth/SelfAuth.sol"; -import { IERC1155Receiver } from "./interfaces/IERC1155Receiver.sol"; -import { IERC223Receiver } from "./interfaces/IERC223Receiver.sol"; -import { IERC721Receiver } from "./interfaces/IERC721Receiver.sol"; -import { IERC777Receiver } from "./interfaces/IERC777Receiver.sol"; - -/// @title Hooks -/// @author Agustin Aguilar, Michael Standen -/// @notice Enables extension of the wallet by adding hooks -contract Hooks is SelfAuth, IERC1155Receiver, IERC777Receiver, IERC721Receiver, IERC223Receiver { - - /// @dev keccak256("org.arcadeum.module.hooks.hooks") - bytes32 private constant HOOKS_KEY = bytes32(0xbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a120); - - /// @notice Emitted when a hook is defined - event DefinedHook(bytes4 selector, address implementation); - - /// @notice Error thrown when a hook already exists - error HookAlreadyExists(bytes4 selector); - /// @notice Error thrown when a hook does not exist - error HookDoesNotExist(bytes4 selector); - - /// @notice Read a hook - /// @param selector The selector of the hook - /// @return implementation The implementation address of the hook - function readHook( - bytes4 selector - ) external view returns (address) { - return _readHook(selector); - } - - /// @notice Add a hook - /// @param selector The selector of the hook - /// @param implementation The implementation address of the hook - /// @dev Callable only by the contract itself - function addHook(bytes4 selector, address implementation) external payable onlySelf { - if (_readHook(selector) != address(0)) { - revert HookAlreadyExists(selector); - } - _writeHook(selector, implementation); - } - - /// @notice Remove a hook - /// @param selector The selector of the hook - /// @dev Callable only by the contract itself - function removeHook( - bytes4 selector - ) external payable onlySelf { - if (_readHook(selector) == address(0)) { - revert HookDoesNotExist(selector); - } - _writeHook(selector, address(0)); - } - - function _readHook( - bytes4 selector - ) private view returns (address) { - return address(uint160(uint256(Storage.readBytes32Map(HOOKS_KEY, bytes32(selector))))); - } - - function _writeHook(bytes4 selector, address implementation) private { - Storage.writeBytes32Map(HOOKS_KEY, bytes32(selector), bytes32(uint256(uint160(implementation)))); - emit DefinedHook(selector, implementation); - } - - /// @inheritdoc IERC1155Receiver - function onERC1155Received(address, address, uint256, uint256, bytes calldata) external pure returns (bytes4) { - return Hooks.onERC1155Received.selector; - } - - /// @inheritdoc IERC1155Receiver - function onERC1155BatchReceived( - address, - address, - uint256[] calldata, - uint256[] calldata, - bytes calldata - ) external pure returns (bytes4) { - return Hooks.onERC1155BatchReceived.selector; - } - - /// @inheritdoc IERC777Receiver - function tokensReceived( - address operator, - address from, - address to, - uint256 amount, - bytes calldata data, - bytes calldata operatorData - ) external { } - - /// @inheritdoc IERC721Receiver - function onERC721Received(address, address, uint256, bytes calldata) external pure returns (bytes4) { - return Hooks.onERC721Received.selector; - } - - /// @inheritdoc IERC223Receiver - function tokenReceived(address, uint256, bytes calldata) external pure returns (bytes4) { - return Hooks.tokenReceived.selector; - } - - /// @notice Fallback function - /// @dev Handles delegate calls to hooks - fallback() external payable { - if (msg.data.length >= 4) { - address target = _readHook(bytes4(msg.data)); - if (target != address(0)) { - (bool success, bytes memory result) = target.delegatecall(msg.data); - assembly { - if iszero(success) { revert(add(result, 32), mload(result)) } - return(add(result, 32), mload(result)) - } - } - } - } - - /// @notice Receive native tokens - receive() external payable { } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Implementation.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Implementation.sol deleted file mode 100644 index 99f7a94425..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Implementation.sol +++ /dev/null @@ -1,50 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { SelfAuth } from "./auth/SelfAuth.sol"; - -/// @title Implementation -/// @author Agustin Aguilar -/// @notice Manages the implementation address of the proxy contract -contract Implementation is SelfAuth { - - /// @notice Emitted when the implementation is updated - event ImplementationUpdated(address newImplementation); - - /// @notice Update the implementation - /// @param _implementation The new implementation - /// @dev Callable only by the contract itself - function updateImplementation( - address _implementation - ) external payable virtual onlySelf { - _updateImplementation(_implementation); - } - - /// @notice Get the implementation - /// @return implementation The implementation - function getImplementation() external view virtual returns (address) { - return _getImplementation(); - } - - function _updateImplementation( - address _implementation - ) internal virtual { - _setImplementation(_implementation); - emit ImplementationUpdated(_implementation); - } - - function _setImplementation( - address _imp - ) internal { - assembly { - sstore(address(), _imp) - } - } - - function _getImplementation() internal view returns (address _imp) { - assembly { - _imp := sload(address()) - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Nonce.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Nonce.sol deleted file mode 100644 index 2fbf587a4c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Nonce.sol +++ /dev/null @@ -1,48 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Storage } from "./Storage.sol"; - -/// @title Nonce -/// @author Agustin Aguilar -/// @notice Manages the nonce of the wallet -contract Nonce { - - /// @notice Emitted when the nonce is changed - event NonceChange(uint256 _space, uint256 _newNonce); - - /// @notice Error thrown when the nonce is bad - error BadNonce(uint256 _space, uint256 _provided, uint256 _current); - - /// @dev keccak256("org.arcadeum.module.calls.nonce") - bytes32 private constant NONCE_KEY = bytes32(0x8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e); - - /// @notice Read the nonce - /// @param _space The space - /// @return nonce The nonce - function readNonce( - uint256 _space - ) public view virtual returns (uint256) { - return uint256(Storage.readBytes32Map(NONCE_KEY, bytes32(_space))); - } - - function _writeNonce(uint256 _space, uint256 _nonce) internal { - Storage.writeBytes32Map(NONCE_KEY, bytes32(_space), bytes32(_nonce)); - } - - function _consumeNonce(uint256 _space, uint256 _nonce) internal { - uint256 currentNonce = readNonce(_space); - if (currentNonce != _nonce) { - revert BadNonce(_space, _nonce, currentNonce); - } - - unchecked { - uint256 newNonce = _nonce + 1; - - _writeNonce(_space, newNonce); - emit NonceChange(_space, newNonce); - return; - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Payload.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Payload.sol deleted file mode 100644 index 18e6110385..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Payload.sol +++ /dev/null @@ -1,278 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { LibBytes } from "../utils/LibBytes.sol"; - -using LibBytes for bytes; - -/// @title Payload -/// @author Agustin Aguilar, Michael Standen, William Hua -/// @notice Library for encoding and decoding payloads -library Payload { - - /// @notice Error thrown when the kind is invalid - error InvalidKind(uint8 kind); - - /// @dev keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)") - bytes32 private constant EIP712_DOMAIN_TYPEHASH = 0x8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f; - - /// @dev keccak256("Sequence Wallet") - bytes32 private constant EIP712_DOMAIN_NAME_SEQUENCE = - 0x4aa45ca7ad825ceb1bf35643f0a58c295239df563b1b565c2485f96477c56318; - - /// @dev keccak256("3") - bytes32 private constant EIP712_DOMAIN_VERSION_SEQUENCE = - 0x2a80e1ef1d7842f27f2e6be0972bb708b9a135c38860dbe73c27c3486c34f4de; - - function domainSeparator(bool _noChainId, address _wallet) internal view returns (bytes32 _domainSeparator) { - return keccak256( - abi.encode( - EIP712_DOMAIN_TYPEHASH, - EIP712_DOMAIN_NAME_SEQUENCE, - EIP712_DOMAIN_VERSION_SEQUENCE, - _noChainId ? uint256(0) : uint256(block.chainid), - _wallet - ) - ); - } - - /// @dev keccak256("Call(address to,uint256 value,bytes data,uint256 gasLimit,bool delegateCall,bool onlyFallback,uint256 behaviorOnError)") - bytes32 private constant CALL_TYPEHASH = 0x0603985259a953da1f65a522f589c17bd1d0117ec1d3abb7c0788aef251ef437; - - /// @dev keccak256("Calls(Call[] calls,uint256 space,uint256 nonce,address[] wallets)Call(address to,uint256 value,bytes data,uint256 gasLimit,bool delegateCall,bool onlyFallback,uint256 behaviorOnError)") - bytes32 private constant CALLS_TYPEHASH = 0x11e1e4079a79a66e4ade50033cfe2678cdd5341d2dfe5ef9513edb1a0be147a2; - - /// @dev keccak256("Message(bytes message,address[] wallets)") - bytes32 private constant MESSAGE_TYPEHASH = 0xe19a3b94fc3c7ece3f890d98a99bc422615537a08dea0603fa8425867d87d466; - - /// @dev keccak256("ConfigUpdate(bytes32 imageHash,address[] wallets)") - bytes32 private constant CONFIG_UPDATE_TYPEHASH = 0x11fdeb7e8373a1aa96bfac8d0ea91526b2c5d15e5cee20e0543e780258f3e8e4; - - /// @notice Kind of transaction - uint8 public constant KIND_TRANSACTIONS = 0x00; - /// @notice Kind of digest - uint8 public constant KIND_MESSAGE = 0x01; - /// @notice Kind of config update - uint8 public constant KIND_CONFIG_UPDATE = 0x02; - /// @notice Kind of message - uint8 public constant KIND_DIGEST = 0x03; - - /// @notice Behavior on error: ignore error - uint8 public constant BEHAVIOR_IGNORE_ERROR = 0x00; - /// @notice Behavior on error: revert on error - uint8 public constant BEHAVIOR_REVERT_ON_ERROR = 0x01; - /// @notice Behavior on error: abort on error - uint8 public constant BEHAVIOR_ABORT_ON_ERROR = 0x02; - - /// @notice Payload call information - /// @param to Address of the target contract - /// @param value Value to send with the call - /// @param data Data to send with the call - /// @param gasLimit Gas limit for the call - /// @param delegateCall If the call is a delegate call - /// @param onlyFallback If the call should only be executed in an error scenario - /// @param behaviorOnError Behavior on error - struct Call { - address to; - uint256 value; - bytes data; - uint256 gasLimit; - bool delegateCall; - bool onlyFallback; - uint256 behaviorOnError; - } - - /// @notice Decoded payload - /// @param kind Kind of payload - /// @param noChainId If the chain ID should be omitted - /// @param calls Array of calls (transaction kind) - /// @param space Nonce space for the calls (transaction kind) - /// @param nonce Nonce value for the calls (transaction kind) - /// @param message Message to validate (message kind) - /// @param imageHash Image hash to update to (config update kind) - /// @param digest Digest to validate (digest kind) - /// @param parentWallets Parent wallets - struct Decoded { - uint8 kind; - bool noChainId; - // Transaction kind - Call[] calls; - uint256 space; - uint256 nonce; - // Message kind - bytes message; - // Config update kind - bytes32 imageHash; - // Digest kind for 1271 - bytes32 digest; - // Parent wallets - address[] parentWallets; - } - - function fromMessage( - bytes memory message - ) internal pure returns (Decoded memory _decoded) { - _decoded.kind = KIND_MESSAGE; - _decoded.message = message; - } - - function fromConfigUpdate( - bytes32 imageHash - ) internal pure returns (Decoded memory _decoded) { - _decoded.kind = KIND_CONFIG_UPDATE; - _decoded.imageHash = imageHash; - } - - function fromDigest( - bytes32 digest - ) internal pure returns (Decoded memory _decoded) { - _decoded.kind = KIND_DIGEST; - _decoded.digest = digest; - } - - function fromPackedCalls( - bytes calldata packed - ) internal view returns (Decoded memory _decoded) { - _decoded.kind = KIND_TRANSACTIONS; - - // Read the global flag - (uint256 globalFlag, uint256 pointer) = packed.readFirstUint8(); - - // First bit determines if space is zero or not - if (globalFlag & 0x01 == 0x01) { - _decoded.space = 0; - } else { - (_decoded.space, pointer) = packed.readUint160(pointer); - } - - // Next 3 bits determine the size of the nonce - uint256 nonceSize = (globalFlag >> 1) & 0x07; - - if (nonceSize > 0) { - // Read the nonce - (_decoded.nonce, pointer) = packed.readUintX(pointer, nonceSize); - } - - uint256 numCalls; - - // Bit 5 determines if the batch contains a single call - if (globalFlag & 0x10 == 0x10) { - numCalls = 1; - } else { - // Bit 6 determines if the number of calls uses 1 byte or 2 bytes - if (globalFlag & 0x20 == 0x20) { - (numCalls, pointer) = packed.readUint16(pointer); - } else { - (numCalls, pointer) = packed.readUint8(pointer); - } - } - - // Read the calls - _decoded.calls = new Call[](numCalls); - - for (uint256 i = 0; i < numCalls; i++) { - uint8 flags; - (flags, pointer) = packed.readUint8(pointer); - - // First bit determines if this is a call to self - // or a call to another address - if (flags & 0x01 == 0x01) { - // Call to self - _decoded.calls[i].to = address(this); - } else { - // Call to another address - (_decoded.calls[i].to, pointer) = packed.readAddress(pointer); - } - - // Second bit determines if the call has value or not - if (flags & 0x02 == 0x02) { - (_decoded.calls[i].value, pointer) = packed.readUint256(pointer); - } - - // Third bit determines if the call has data or not - if (flags & 0x04 == 0x04) { - // 3 bytes determine the size of the calldata - uint256 calldataSize; - (calldataSize, pointer) = packed.readUint24(pointer); - _decoded.calls[i].data = packed[pointer:pointer + calldataSize]; - pointer += calldataSize; - } - - // Fourth bit determines if the call has a gas limit or not - if (flags & 0x08 == 0x08) { - (_decoded.calls[i].gasLimit, pointer) = packed.readUint256(pointer); - } - - // Fifth bit determines if the call is a delegate call or not - _decoded.calls[i].delegateCall = (flags & 0x10 == 0x10); - - // Sixth bit determines if the call is fallback only - _decoded.calls[i].onlyFallback = (flags & 0x20 == 0x20); - - // Last 2 bits are directly mapped to the behavior on error - _decoded.calls[i].behaviorOnError = (flags & 0xC0) >> 6; - } - } - - function hashCall( - Call memory c - ) internal pure returns (bytes32) { - return keccak256( - abi.encode( - CALL_TYPEHASH, c.to, c.value, keccak256(c.data), c.gasLimit, c.delegateCall, c.onlyFallback, c.behaviorOnError - ) - ); - } - - function hashCalls( - Call[] memory calls - ) internal pure returns (bytes32) { - // In EIP712, an array is often hashed as the keccak256 of the concatenated - // hashes of each item. So we hash each Call, pack them, and hash again. - bytes32[] memory callHashes = new bytes32[](calls.length); - for (uint256 i = 0; i < calls.length; i++) { - callHashes[i] = hashCall(calls[i]); - } - return keccak256(abi.encodePacked(callHashes)); - } - - function toEIP712( - Decoded memory _decoded - ) internal pure returns (bytes32) { - bytes32 walletsHash = keccak256(abi.encodePacked(_decoded.parentWallets)); - - if (_decoded.kind == KIND_TRANSACTIONS) { - bytes32 callsHash = hashCalls(_decoded.calls); - // The top-level struct for Calls might be something like: - // Calls(bytes32 callsHash,uint256 space,uint256 nonce,bytes32 walletsHash) - return keccak256(abi.encode(CALLS_TYPEHASH, callsHash, _decoded.space, _decoded.nonce, walletsHash)); - } else if (_decoded.kind == KIND_MESSAGE) { - // If you define your top-level as: Message(bytes32 messageHash,bytes32 walletsHash) - return keccak256(abi.encode(MESSAGE_TYPEHASH, keccak256(_decoded.message), walletsHash)); - } else if (_decoded.kind == KIND_CONFIG_UPDATE) { - // Top-level: ConfigUpdate(bytes32 imageHash,bytes32 walletsHash) - return keccak256(abi.encode(CONFIG_UPDATE_TYPEHASH, _decoded.imageHash, walletsHash)); - } else if (_decoded.kind == KIND_DIGEST) { - // Top-level: Use MESSAGE_TYPEHASH but assume the digest is already the hashed message - return keccak256(abi.encode(MESSAGE_TYPEHASH, _decoded.digest, walletsHash)); - } else { - // Unknown kind - revert InvalidKind(_decoded.kind); - } - } - - function hash( - Decoded memory _decoded - ) internal view returns (bytes32) { - bytes32 domain = domainSeparator(_decoded.noChainId, address(this)); - bytes32 structHash = toEIP712(_decoded); - return keccak256(abi.encodePacked("\x19\x01", domain, structHash)); - } - - function hashFor(Decoded memory _decoded, address _wallet) internal view returns (bytes32) { - bytes32 domain = domainSeparator(_decoded.noChainId, _wallet); - bytes32 structHash = toEIP712(_decoded); - return keccak256(abi.encodePacked("\x19\x01", domain, structHash)); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/ReentrancyGuard.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/ReentrancyGuard.sol deleted file mode 100644 index 2397605def..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/ReentrancyGuard.sol +++ /dev/null @@ -1,38 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.0; - -import { Storage } from "./Storage.sol"; - -abstract contract ReentrancyGuard { - - bytes32 private constant _INITIAL_VALUE = bytes32(0); - bytes32 private constant _NOT_ENTERED = bytes32(uint256(1)); - bytes32 private constant _ENTERED = bytes32(uint256(2)); - - /// @dev keccak256("org.sequence.module.reentrancyguard.status") - bytes32 private constant STATUS_KEY = bytes32(0xfc6e07e3992c7c3694a921dc9e412b6cfe475380556756a19805a9e3ddfe2fde); - - /// @notice Error thrown when a reentrant call is detected - error ReentrantCall(); - - /// @notice Prevents a contract from calling itself, directly or indirectly - modifier nonReentrant() { - // On the first call to nonReentrant - // _status will be _NOT_ENTERED or _INITIAL_VALUE - if (Storage.readBytes32(STATUS_KEY) == _ENTERED) { - revert ReentrantCall(); - } - - // Any calls to nonReentrant after this point will fail - Storage.writeBytes32(STATUS_KEY, _ENTERED); - - _; - - // By storing the original value once again, a refund is triggered (see - // https://eips.ethereum.org/EIPS/eip-2200) - // Notice that because constructors are not available - // we always start with _INITIAL_VALUE, not _NOT_ENTERED - Storage.writeBytes32(STATUS_KEY, _NOT_ENTERED); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Storage.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Storage.sol deleted file mode 100644 index f340afbbea..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/Storage.sol +++ /dev/null @@ -1,37 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -/// @title Storage -/// @author Agustin Aguilar -/// @notice Library for storing data at certain storage slots -library Storage { - - function writeBytes32(bytes32 _key, bytes32 _val) internal { - assembly { - sstore(_key, _val) - } - } - - function readBytes32( - bytes32 _key - ) internal view returns (bytes32 val) { - assembly { - val := sload(_key) - } - } - - function writeBytes32Map(bytes32 _key, bytes32 _subKey, bytes32 _val) internal { - bytes32 key = keccak256(abi.encode(_key, _subKey)); - assembly { - sstore(key, _val) - } - } - - function readBytes32Map(bytes32 _key, bytes32 _subKey) internal view returns (bytes32 val) { - bytes32 key = keccak256(abi.encode(_key, _subKey)); - assembly { - val := sload(key) - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/BaseAuth.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/BaseAuth.sol deleted file mode 100644 index b3b2bf0e8d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/BaseAuth.sol +++ /dev/null @@ -1,174 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../Payload.sol"; - -import { Storage } from "../Storage.sol"; -import { IAuth } from "../interfaces/IAuth.sol"; -import { IERC1271, IERC1271_MAGIC_VALUE_HASH } from "../interfaces/IERC1271.sol"; - -import { IPartialAuth } from "../interfaces/IPartialAuth.sol"; -import { ISapient } from "../interfaces/ISapient.sol"; -import { BaseSig } from "./BaseSig.sol"; - -import { SelfAuth } from "./SelfAuth.sol"; - -using Payload for Payload.Decoded; - -/// @title BaseAuth -/// @author Agustin Aguilar, Michael Standen -/// @notice Base contract for the auth module -abstract contract BaseAuth is IAuth, IPartialAuth, ISapient, IERC1271, SelfAuth { - - /// @dev keccak256("org.sequence.module.auth.static") - bytes32 private constant STATIC_SIGNATURE_KEY = - bytes32(0xc852adf5e97c2fc3b38f405671e91b7af1697ef0287577f227ef10494c2a8e86); - - /// @notice Error thrown when the sapient signature is invalid - error InvalidSapientSignature(Payload.Decoded _payload, bytes _signature); - /// @notice Error thrown when the signature weight is invalid - error InvalidSignatureWeight(uint256 _threshold, uint256 _weight); - /// @notice Error thrown when the static signature has expired - error InvalidStaticSignatureExpired(bytes32 _opHash, uint256 _expires); - /// @notice Error thrown when the static signature has the wrong caller - error InvalidStaticSignatureWrongCaller(bytes32 _opHash, address _caller, address _expectedCaller); - - /// @notice Event emitted when a static signature is set - event StaticSignatureSet(bytes32 _hash, address _address, uint96 _timestamp); - - function _getStaticSignature( - bytes32 _hash - ) internal view returns (address, uint256) { - uint256 word = uint256(Storage.readBytes32Map(STATIC_SIGNATURE_KEY, _hash)); - return (address(uint160(word >> 96)), uint256(uint96(word))); - } - - function _setStaticSignature(bytes32 _hash, address _address, uint256 _timestamp) internal { - Storage.writeBytes32Map( - STATIC_SIGNATURE_KEY, _hash, bytes32(uint256(uint160(_address)) << 96 | (_timestamp & 0xffffffffffffffffffffffff)) - ); - } - - /// @notice Get the static signature for a specific hash - /// @param _hash The hash to get the static signature for - /// @return address The address associated with the static signature - /// @return timestamp The timestamp of the static signature - function getStaticSignature( - bytes32 _hash - ) external view returns (address, uint256) { - return _getStaticSignature(_hash); - } - - /// @notice Set the static signature for a specific hash - /// @param _hash The hash to set the static signature for - /// @param _address The address to associate with the static signature - /// @param _timestamp The timestamp of the static signature - /// @dev Only callable by the wallet itself - function setStaticSignature(bytes32 _hash, address _address, uint96 _timestamp) external onlySelf { - _setStaticSignature(_hash, _address, _timestamp); - emit StaticSignatureSet(_hash, _address, _timestamp); - } - - /// @notice Update the image hash - /// @param _imageHash The new image hash - /// @dev Only callable by the wallet itself - function updateImageHash( - bytes32 _imageHash - ) external virtual onlySelf { - _updateImageHash(_imageHash); - } - - function signatureValidation( - Payload.Decoded memory _payload, - bytes calldata _signature - ) internal view virtual returns (bool isValid, bytes32 opHash) { - // Read first bit to determine if static signature is used - bytes1 signatureFlag = _signature[0]; - - if (signatureFlag & 0x80 == 0x80) { - opHash = _payload.hash(); - - (address addr, uint256 timestamp) = _getStaticSignature(opHash); - if (timestamp <= block.timestamp) { - revert InvalidStaticSignatureExpired(opHash, timestamp); - } - - if (addr != address(0) && addr != msg.sender) { - revert InvalidStaticSignatureWrongCaller(opHash, msg.sender, addr); - } - - return (true, opHash); - } - - // Static signature is not used, recover and validate imageHash - - uint256 threshold; - uint256 weight; - bytes32 imageHash; - - (threshold, weight, imageHash,, opHash) = BaseSig.recover(_payload, _signature, false, address(0)); - - // Validate the weight - if (weight < threshold) { - revert InvalidSignatureWeight(threshold, weight); - } - - isValid = _isValidImage(imageHash); - } - - /// @inheritdoc ISapient - function recoverSapientSignature( - Payload.Decoded memory _payload, - bytes calldata _signature - ) external view returns (bytes32) { - // Copy parent wallets + add caller at the end - address[] memory parentWallets = new address[](_payload.parentWallets.length + 1); - - for (uint256 i = 0; i < _payload.parentWallets.length; i++) { - parentWallets[i] = _payload.parentWallets[i]; - } - - parentWallets[_payload.parentWallets.length] = msg.sender; - _payload.parentWallets = parentWallets; - - (bool isValid,) = signatureValidation(_payload, _signature); - if (!isValid) { - revert InvalidSapientSignature(_payload, _signature); - } - - return bytes32(uint256(1)); - } - - /// @inheritdoc IERC1271 - function isValidSignature(bytes32 _hash, bytes calldata _signature) external view returns (bytes4) { - Payload.Decoded memory payload = Payload.fromDigest(_hash); - - (bool isValid,) = signatureValidation(payload, _signature); - if (!isValid) { - return bytes4(0); - } - - return IERC1271_MAGIC_VALUE_HASH; - } - - /// @inheritdoc IPartialAuth - function recoverPartialSignature( - Payload.Decoded memory _payload, - bytes calldata _signature - ) - external - view - returns ( - uint256 threshold, - uint256 weight, - bool isValidImage, - bytes32 imageHash, - uint256 checkpoint, - bytes32 opHash - ) - { - (threshold, weight, imageHash, checkpoint, opHash) = BaseSig.recover(_payload, _signature, false, address(0)); - isValidImage = _isValidImage(imageHash); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/BaseSig.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/BaseSig.sol deleted file mode 100644 index a43340ac5b..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/BaseSig.sol +++ /dev/null @@ -1,500 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { LibBytes } from "../../utils/LibBytes.sol"; -import { LibOptim } from "../../utils/LibOptim.sol"; -import { Payload } from "../Payload.sol"; - -import { ICheckpointer, Snapshot } from "../interfaces/ICheckpointer.sol"; -import { IERC1271, IERC1271_MAGIC_VALUE_HASH } from "../interfaces/IERC1271.sol"; -import { ISapient, ISapientCompact } from "../interfaces/ISapient.sol"; - -using LibBytes for bytes; -using Payload for Payload.Decoded; - -/// @title BaseSig -/// @author Agustin Aguilar, Michael Standen, William Hua, Shun Kakinoki -/// @notice Library for recovering signatures from the base-auth payload -library BaseSig { - - uint256 internal constant FLAG_SIGNATURE_HASH = 0; - uint256 internal constant FLAG_ADDRESS = 1; - uint256 internal constant FLAG_SIGNATURE_ERC1271 = 2; - uint256 internal constant FLAG_NODE = 3; - uint256 internal constant FLAG_BRANCH = 4; - uint256 internal constant FLAG_SUBDIGEST = 5; - uint256 internal constant FLAG_NESTED = 6; - uint256 internal constant FLAG_SIGNATURE_ETH_SIGN = 7; - uint256 internal constant FLAG_SIGNATURE_ANY_ADDRESS_SUBDIGEST = 8; - uint256 internal constant FLAG_SIGNATURE_SAPIENT = 9; - uint256 internal constant FLAG_SIGNATURE_SAPIENT_COMPACT = 10; - - /// @notice Error thrown when the weight is too low for a chained signature - error LowWeightChainedSignature(bytes _signature, uint256 _threshold, uint256 _weight); - /// @notice Error thrown when the ERC1271 signature is invalid - error InvalidERC1271Signature(bytes32 _opHash, address _signer, bytes _signature); - /// @notice Error thrown when the checkpoint order is wrong - error WrongChainedCheckpointOrder(uint256 _nextCheckpoint, uint256 _checkpoint); - /// @notice Error thrown when the snapshot is unused - error UnusedSnapshot(Snapshot _snapshot); - /// @notice Error thrown when the signature flag is invalid - error InvalidSignatureFlag(uint256 _flag); - - function _leafForAddressAndWeight(address _addr, uint256 _weight) internal pure returns (bytes32) { - return keccak256(abi.encodePacked("Sequence signer:\n", _addr, _weight)); - } - - function _leafForNested(bytes32 _node, uint256 _threshold, uint256 _weight) internal pure returns (bytes32) { - return keccak256(abi.encodePacked("Sequence nested config:\n", _node, _threshold, _weight)); - } - - function _leafForSapient(address _addr, uint256 _weight, bytes32 _imageHash) internal pure returns (bytes32) { - return keccak256(abi.encodePacked("Sequence sapient config:\n", _addr, _weight, _imageHash)); - } - - function _leafForHardcodedSubdigest( - bytes32 _subdigest - ) internal pure returns (bytes32) { - return keccak256(abi.encodePacked("Sequence static digest:\n", _subdigest)); - } - - function _leafForAnyAddressSubdigest( - bytes32 _anyAddressSubdigest - ) internal pure returns (bytes32) { - return keccak256(abi.encodePacked("Sequence any address subdigest:\n", _anyAddressSubdigest)); - } - - function recover( - Payload.Decoded memory _payload, - bytes calldata _signature, - bool _ignoreCheckpointer, - address _checkpointer - ) internal view returns (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) { - // First byte is the signature flag - (uint256 signatureFlag, uint256 rindex) = _signature.readFirstUint8(); - - // The possible flags are: - // - 0000 00XX (bits [1..0]): signature type (00 = normal, 01/11 = chained, 10 = no chain id) - // - 000X XX00 (bits [4..2]): checkpoint size (00 = 0 bytes, 001 = 1 byte, 010 = 2 bytes...) - // - 00X0 0000 (bit [5]): threshold size (0 = 1 byte, 1 = 2 bytes) - // - 0X00 0000 (bit [6]): set if imageHash checkpointer is used - // - X000 0000 (bit [7]): reserved by base-auth - - Snapshot memory snapshot; - - // Recover the imageHash checkpointer if any - // but checkpointer passed as argument takes precedence - // since it can be defined by the chained signatures - if (signatureFlag & 0x40 == 0x40 && _checkpointer == address(0)) { - // Override the checkpointer - // not ideal, but we don't have much room in the stack - (_checkpointer, rindex) = _signature.readAddress(rindex); - - if (!_ignoreCheckpointer) { - // Next 3 bytes determine the checkpointer data size - uint256 checkpointerDataSize; - (checkpointerDataSize, rindex) = _signature.readUint24(rindex); - - // Read the checkpointer data - bytes memory checkpointerData = _signature[rindex:rindex + checkpointerDataSize]; - - // Call the middleware - snapshot = ICheckpointer(_checkpointer).snapshotFor(address(this), checkpointerData); - - rindex += checkpointerDataSize; - } - } - - // If signature type is 01 or 11 we do a chained signature - if (signatureFlag & 0x01 == 0x01) { - return recoverChained(_payload, _checkpointer, snapshot, _signature[rindex:]); - } - - // If the signature type is 10 we do a no chain id signature - _payload.noChainId = signatureFlag & 0x02 == 0x02; - - { - // Recover the checkpoint using the size defined by the flag - uint256 checkpointSize = (signatureFlag & 0x1c) >> 2; - (checkpoint, rindex) = _signature.readUintX(rindex, checkpointSize); - } - - // Recover the threshold, using the flag for the size - { - uint256 thresholdSize = ((signatureFlag & 0x20) >> 5) + 1; - (threshold, rindex) = _signature.readUintX(rindex, thresholdSize); - } - - // Recover the tree - opHash = _payload.hash(); - (weight, imageHash) = recoverBranch(_payload, opHash, _signature[rindex:]); - - imageHash = LibOptim.fkeccak256(imageHash, bytes32(threshold)); - imageHash = LibOptim.fkeccak256(imageHash, bytes32(checkpoint)); - imageHash = LibOptim.fkeccak256(imageHash, bytes32(uint256(uint160(_checkpointer)))); - - // If the snapshot is used, either the imageHash must match - // or the checkpoint must be greater than the snapshot checkpoint - if (snapshot.imageHash != bytes32(0) && snapshot.imageHash != imageHash && checkpoint <= snapshot.checkpoint) { - revert UnusedSnapshot(snapshot); - } - } - - function recoverChained( - Payload.Decoded memory _payload, - address _checkpointer, - Snapshot memory _snapshot, - bytes calldata _signature - ) internal view returns (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) { - Payload.Decoded memory linkedPayload; - linkedPayload.kind = Payload.KIND_CONFIG_UPDATE; - - uint256 rindex; - uint256 prevCheckpoint = type(uint256).max; - - while (rindex < _signature.length) { - uint256 nrindex; - - { - uint256 sigSize; - (sigSize, rindex) = _signature.readUint24(rindex); - nrindex = sigSize + rindex; - } - - address checkpointer = nrindex == _signature.length ? _checkpointer : address(0); - - if (prevCheckpoint == type(uint256).max) { - (threshold, weight, imageHash, checkpoint, opHash) = - recover(_payload, _signature[rindex:nrindex], true, checkpointer); - } else { - (threshold, weight, imageHash, checkpoint,) = - recover(linkedPayload, _signature[rindex:nrindex], true, checkpointer); - } - - if (weight < threshold) { - revert LowWeightChainedSignature(_signature[rindex:nrindex], threshold, weight); - } - rindex = nrindex; - - if (_snapshot.imageHash == imageHash) { - _snapshot.imageHash = bytes32(0); - } - - if (checkpoint >= prevCheckpoint) { - revert WrongChainedCheckpointOrder(checkpoint, prevCheckpoint); - } - - linkedPayload.imageHash = imageHash; - prevCheckpoint = checkpoint; - } - - if (_snapshot.imageHash != bytes32(0) && checkpoint <= _snapshot.checkpoint) { - revert UnusedSnapshot(_snapshot); - } - } - - function recoverBranch( - Payload.Decoded memory _payload, - bytes32 _opHash, - bytes calldata _signature - ) internal view returns (uint256 weight, bytes32 root) { - unchecked { - uint256 rindex; - - // Iterate until the image is completed - while (rindex < _signature.length) { - // The first byte is half flag (the top nibble) - // and the second set of 4 bits can freely be used by the part - - // Read next item type - uint256 firstByte; - (firstByte, rindex) = _signature.readUint8(rindex); - - // The top 4 bits are the flag - uint256 flag = (firstByte & 0xf0) >> 4; - - // Signature hash (0x00) - if (flag == FLAG_SIGNATURE_HASH) { - // Free bits layout: - // - bits [3..0]: Weight (0000 = dynamic, 0001 = 1, ..., 1111 = 15) - // We read 64 bytes for an ERC-2098 compact signature (r, yParityAndS). - // The top bit of yParityAndS is yParity, the remaining 255 bits are s. - - uint8 addrWeight = uint8(firstByte & 0x0f); - if (addrWeight == 0) { - (addrWeight, rindex) = _signature.readUint8(rindex); - } - - bytes32 r; - bytes32 s; - uint8 v; - (r, s, v, rindex) = _signature.readRSVCompact(rindex); - - address addr = ecrecover(_opHash, v, r, s); - - weight += addrWeight; - bytes32 node = _leafForAddressAndWeight(addr, addrWeight); - root = root != bytes32(0) ? LibOptim.fkeccak256(root, node) : node; - continue; - } - - // Address (0x01) (without signature) - if (flag == FLAG_ADDRESS) { - // Free bits layout: - // - bits [3..0]: Weight (0000 = dynamic, 0001 = 1, 0010 = 2, ...) - - // Read weight - uint8 addrWeight = uint8(firstByte & 0x0f); - if (addrWeight == 0) { - (addrWeight, rindex) = _signature.readUint8(rindex); - } - - // Read address - address addr; - (addr, rindex) = _signature.readAddress(rindex); - - // Compute the merkle root WITHOUT adding the weight - bytes32 node = _leafForAddressAndWeight(addr, addrWeight); - root = root != bytes32(0) ? LibOptim.fkeccak256(root, node) : node; - continue; - } - - // Signature ERC1271 (0x02) - if (flag == FLAG_SIGNATURE_ERC1271) { - // Free bits layout: - // - XX00 : Signature size size (00 = 0 byte, 01 = 1 byte, 10 = 2 bytes, 11 = 3 bytes) - // - 00XX : Weight (00 = dynamic, 01 = 1, 10 = 2, 11 = 3) - - // Read weight - uint8 addrWeight = uint8(firstByte & 0x03); - if (addrWeight == 0) { - (addrWeight, rindex) = _signature.readUint8(rindex); - } - - // Read signer - address addr; - (addr, rindex) = _signature.readAddress(rindex); - - // Read signature size - uint256 sizeSize = uint8(firstByte & 0x0c) >> 2; - uint256 size; - (size, rindex) = _signature.readUintX(rindex, sizeSize); - - // Read dynamic size signature - uint256 nrindex = rindex + size; - - // Call the ERC1271 contract to check if the signature is valid - if (IERC1271(addr).isValidSignature(_opHash, _signature[rindex:nrindex]) != IERC1271_MAGIC_VALUE_HASH) { - revert InvalidERC1271Signature(_opHash, addr, _signature[rindex:nrindex]); - } - rindex = nrindex; - // Add the weight and compute the merkle root - weight += addrWeight; - bytes32 node = _leafForAddressAndWeight(addr, addrWeight); - root = root != bytes32(0) ? LibOptim.fkeccak256(root, node) : node; - continue; - } - - // Node (0x03) - if (flag == FLAG_NODE) { - // Free bits left unused - - // Read node hash - bytes32 node; - (node, rindex) = _signature.readBytes32(rindex); - root = root != bytes32(0) ? LibOptim.fkeccak256(root, node) : node; - continue; - } - - // Branch (0x04) - if (flag == FLAG_BRANCH) { - // Free bits layout: - // - XXXX : Size size (0000 = 0 byte, 0001 = 1 byte, 0010 = 2 bytes, ...) - - // Read size - uint256 sizeSize = uint8(firstByte & 0x0f); - uint256 size; - (size, rindex) = _signature.readUintX(rindex, sizeSize); - - // Enter a branch of the signature merkle tree - uint256 nrindex = rindex + size; - - (uint256 nweight, bytes32 node) = recoverBranch(_payload, _opHash, _signature[rindex:nrindex]); - rindex = nrindex; - - weight += nweight; - root = LibOptim.fkeccak256(root, node); - continue; - } - - // Nested (0x06) - if (flag == FLAG_NESTED) { - // Unused free bits: - // - XX00 : Weight (00 = dynamic, 01 = 1, 10 = 2, 11 = 3) - // - 00XX : Threshold (00 = dynamic, 01 = 1, 10 = 2, 11 = 3) - - // Enter a branch of the signature merkle tree - // but with an internal threshold and an external fixed weight - uint256 externalWeight = uint8(firstByte & 0x0c) >> 2; - if (externalWeight == 0) { - (externalWeight, rindex) = _signature.readUint8(rindex); - } - - uint256 internalThreshold = uint8(firstByte & 0x03); - if (internalThreshold == 0) { - (internalThreshold, rindex) = _signature.readUint16(rindex); - } - - uint256 size; - (size, rindex) = _signature.readUint24(rindex); - uint256 nrindex = rindex + size; - - (uint256 internalWeight, bytes32 internalRoot) = recoverBranch(_payload, _opHash, _signature[rindex:nrindex]); - rindex = nrindex; - - if (internalWeight >= internalThreshold) { - weight += externalWeight; - } - - bytes32 node = _leafForNested(internalRoot, internalThreshold, externalWeight); - root = root != bytes32(0) ? LibOptim.fkeccak256(root, node) : node; - continue; - } - - // Subdigest (0x05) - if (flag == FLAG_SUBDIGEST) { - // Free bits left unused - - // A hardcoded always accepted digest - // it pushes the weight to the maximum - bytes32 hardcoded; - (hardcoded, rindex) = _signature.readBytes32(rindex); - if (hardcoded == _opHash) { - weight = type(uint256).max; - } - - bytes32 node = _leafForHardcodedSubdigest(hardcoded); - root = root != bytes32(0) ? LibOptim.fkeccak256(root, node) : node; - continue; - } - - // Signature ETH Sign (0x07) - if (flag == FLAG_SIGNATURE_ETH_SIGN) { - // Free bits layout: - // - bits [3..0]: Weight (0000 = dynamic, 0001 = 1, ..., 1111 = 15) - // We read 64 bytes for an ERC-2098 compact signature (r, yParityAndS). - // The top bit of yParityAndS is yParity, the remaining 255 bits are s. - - uint8 addrWeight = uint8(firstByte & 0x0f); - if (addrWeight == 0) { - (addrWeight, rindex) = _signature.readUint8(rindex); - } - - bytes32 r; - bytes32 s; - uint8 v; - (r, s, v, rindex) = _signature.readRSVCompact(rindex); - - address addr = ecrecover(keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", _opHash)), v, r, s); - - weight += addrWeight; - bytes32 node = _leafForAddressAndWeight(addr, addrWeight); - root = root != bytes32(0) ? LibOptim.fkeccak256(root, node) : node; - continue; - } - - // Signature Any address subdigest (0x08) - // similar to subdigest, but allows for counter-factual payloads - if (flag == FLAG_SIGNATURE_ANY_ADDRESS_SUBDIGEST) { - // Free bits left unused - - // A hardcoded always accepted digest - // it pushes the weight to the maximum - bytes32 hardcoded; - (hardcoded, rindex) = _signature.readBytes32(rindex); - bytes32 anyAddressOpHash = _payload.hashFor(address(0)); - if (hardcoded == anyAddressOpHash) { - weight = type(uint256).max; - } - - bytes32 node = _leafForAnyAddressSubdigest(hardcoded); - root = root != bytes32(0) ? LibOptim.fkeccak256(root, node) : node; - continue; - } - - // Signature Sapient (0x09) - if (flag == FLAG_SIGNATURE_SAPIENT) { - // Free bits layout: - // - XX00 : Signature size size (00 = 0 byte, 01 = 1 byte, 10 = 2 bytes, 11 = 3 bytes) - // - 00XX : Weight (00 = dynamic, 01 = 1, 10 = 2, 11 = 3) - - // Read signer and weight - uint8 addrWeight = uint8(firstByte & 0x03); - if (addrWeight == 0) { - (addrWeight, rindex) = _signature.readUint8(rindex); - } - - address addr; - (addr, rindex) = _signature.readAddress(rindex); - - // Read signature size - uint256 size; - { - uint256 sizeSize = uint8(firstByte & 0x0c) >> 2; - (size, rindex) = _signature.readUintX(rindex, sizeSize); - } - - // Read dynamic size signature - uint256 nrindex = rindex + size; - - // Call the ERC1271 contract to check if the signature is valid - bytes32 sapientImageHash = ISapient(addr).recoverSapientSignature(_payload, _signature[rindex:nrindex]); - rindex = nrindex; - - // Add the weight and compute the merkle root - weight += addrWeight; - bytes32 node = _leafForSapient(addr, addrWeight, sapientImageHash); - root = root != bytes32(0) ? LibOptim.fkeccak256(root, node) : node; - continue; - } - - // Signature Sapient Compact (0x0A) - if (flag == FLAG_SIGNATURE_SAPIENT_COMPACT) { - // Free bits layout: - // - XX00 : Signature size size (00 = 0 byte, 01 = 1 byte, 10 = 2 bytes, 11 = 3 bytes) - // - 00XX : Weight (00 = dynamic, 01 = 1, 10 = 2, 11 = 3) - - // Read signer and weight - uint8 addrWeight = uint8(firstByte & 0x03); - if (addrWeight == 0) { - (addrWeight, rindex) = _signature.readUint8(rindex); - } - - address addr; - (addr, rindex) = _signature.readAddress(rindex); - - // Read signature size - uint256 sizeSize = uint8(firstByte & 0x0c) >> 2; - uint256 size; - (size, rindex) = _signature.readUintX(rindex, sizeSize); - - // Read dynamic size signature - uint256 nrindex = rindex + size; - - // Call the Sapient contract to check if the signature is valid - bytes32 sapientImageHash = - ISapientCompact(addr).recoverSapientSignatureCompact(_opHash, _signature[rindex:nrindex]); - rindex = nrindex; - // Add the weight and compute the merkle root - weight += addrWeight; - bytes32 node = _leafForSapient(addr, addrWeight, sapientImageHash); - root = root != bytes32(0) ? LibOptim.fkeccak256(root, node) : node; - continue; - } - - revert InvalidSignatureFlag(flag); - } - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/SelfAuth.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/SelfAuth.sol deleted file mode 100644 index e583d4dfc5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/SelfAuth.sol +++ /dev/null @@ -1,19 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -/// @title SelfAuth -/// @author Agustin Aguilar, Michael Standen -/// @notice Modifier for checking if the caller is the same as the contract -abstract contract SelfAuth { - - /// @notice Error thrown when the caller is not the same as the contract - error OnlySelf(address _sender); - - modifier onlySelf() { - if (msg.sender != address(this)) { - revert OnlySelf(msg.sender); - } - _; - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/Stage1Auth.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/Stage1Auth.sol deleted file mode 100644 index 5f5d457a4c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/Stage1Auth.sol +++ /dev/null @@ -1,62 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Wallet } from "../../Wallet.sol"; -import { Implementation } from "../Implementation.sol"; -import { Storage } from "../Storage.sol"; -import { BaseAuth } from "./BaseAuth.sol"; - -/// @title Stage1Auth -/// @author Agustin Aguilar -/// @notice Stage 1 auth contract -contract Stage1Auth is BaseAuth, Implementation { - - /// @notice Error thrown when the image hash is zero - error ImageHashIsZero(); - /// @notice Error thrown when the signature type is invalid - error InvalidSignatureType(bytes1 _type); - - /// @notice Initialization code hash - bytes32 public immutable INIT_CODE_HASH; - /// @notice Factory address - address public immutable FACTORY; - /// @notice Stage 2 implementation address - address public immutable STAGE_2_IMPLEMENTATION; - - /// @dev keccak256("org.arcadeum.module.auth.upgradable.image.hash") - bytes32 internal constant IMAGE_HASH_KEY = bytes32(0xea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf8); - - /// @notice Emitted when the image hash is updated - event ImageHashUpdated(bytes32 newImageHash); - - constructor(address _factory, address _stage2) { - // Build init code hash of the deployed wallets using that module - bytes32 initCodeHash = keccak256(abi.encodePacked(Wallet.creationCode, uint256(uint160(address(this))))); - - INIT_CODE_HASH = initCodeHash; - FACTORY = _factory; - STAGE_2_IMPLEMENTATION = _stage2; - } - - function _updateImageHash( - bytes32 _imageHash - ) internal virtual override { - // Update imageHash in storage - if (_imageHash == bytes32(0)) { - revert ImageHashIsZero(); - } - Storage.writeBytes32(IMAGE_HASH_KEY, _imageHash); - emit ImageHashUpdated(_imageHash); - - // Update wallet implementation to stage2 version - _updateImplementation(STAGE_2_IMPLEMENTATION); - } - - function _isValidImage( - bytes32 _imageHash - ) internal view virtual override returns (bool) { - return address(uint160(uint256(keccak256(abi.encodePacked(hex"ff", FACTORY, _imageHash, INIT_CODE_HASH))))) - == address(this); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/Stage2Auth.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/Stage2Auth.sol deleted file mode 100644 index 6242b28715..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/auth/Stage2Auth.sol +++ /dev/null @@ -1,45 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Wallet } from "../../Wallet.sol"; -import { Implementation } from "../Implementation.sol"; -import { Storage } from "../Storage.sol"; -import { BaseAuth } from "./BaseAuth.sol"; - -/// @title Stage2Auth -/// @author Agustin Aguilar -/// @notice Stage 2 auth contract -contract Stage2Auth is BaseAuth, Implementation { - - /// @dev keccak256("org.arcadeum.module.auth.upgradable.image.hash") - bytes32 internal constant IMAGE_HASH_KEY = bytes32(0xea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf8); - - /// @notice Emitted when the image hash is updated - event ImageHashUpdated(bytes32 newImageHash); - - /// @notice Error thrown when the image hash is zero - error ImageHashIsZero(); - - /// @notice Get the image hash - /// @return imageHash The image hash - function imageHash() external view virtual returns (bytes32) { - return Storage.readBytes32(IMAGE_HASH_KEY); - } - - function _isValidImage( - bytes32 _imageHash - ) internal view virtual override returns (bool) { - return _imageHash != bytes32(0) && _imageHash == Storage.readBytes32(IMAGE_HASH_KEY); - } - - function _updateImageHash( - bytes32 _imageHash - ) internal virtual override { - if (_imageHash == bytes32(0)) { - revert ImageHashIsZero(); - } - Storage.writeBytes32(IMAGE_HASH_KEY, _imageHash); - emit ImageHashUpdated(_imageHash); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IAccount.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IAccount.sol deleted file mode 100644 index 8b617b95ba..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IAccount.sol +++ /dev/null @@ -1,65 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.28; - -/** - * User Operation struct - * @param sender - The sender account of this request. - * @param nonce - Unique value the sender uses to verify it is not a replay. - * @param initCode - If set, the account contract will be created by this constructor - * @param callData - The method call to execute on this account. - * @param accountGasLimits - Packed gas limits for validateUserOp and gas limit passed to the callData method call. - * @param preVerificationGas - Gas not calculated by the handleOps method, but added to the gas paid. - * Covers batch overhead. - * @param gasFees - packed gas fields maxPriorityFeePerGas and maxFeePerGas - Same as EIP-1559 gas parameters. - * @param paymasterAndData - If set, this field holds the paymaster address, verification gas limit, postOp gas limit and paymaster-specific extra data - * The paymaster will pay for the transaction instead of the sender. - * @param signature - Sender-verified signature over the entire request, the EntryPoint address and the chain ID. - */ -struct PackedUserOperation { - address sender; - uint256 nonce; - bytes initCode; - bytes callData; - bytes32 accountGasLimits; - uint256 preVerificationGas; - bytes32 gasFees; - bytes paymasterAndData; - bytes signature; -} - -interface IAccount { - - /** - * Validate user's signature and nonce - * the entryPoint will make the call to the recipient only if this validation call returns successfully. - * signature failure should be reported by returning SIG_VALIDATION_FAILED (1). - * This allows making a "simulation call" without a valid signature - * Other failures (e.g. nonce mismatch, or invalid signature format) should still revert to signal failure. - * - * @dev Must validate caller is the entryPoint. - * Must validate the signature and nonce - * @param userOp - The operation that is about to be executed. - * @param userOpHash - Hash of the user's request data. can be used as the basis for signature. - * @param missingAccountFunds - Missing funds on the account's deposit in the entrypoint. - * This is the minimum amount to transfer to the sender(entryPoint) to be - * able to make the call. The excess is left as a deposit in the entrypoint - * for future calls. Can be withdrawn anytime using "entryPoint.withdrawTo()". - * In case there is a paymaster in the request (or the current deposit is high - * enough), this value will be zero. - * @return validationData - Packaged ValidationData structure. use `_packValidationData` and - * `_unpackValidationData` to encode and decode. - * <20-byte> aggregatorOrSigFail - 0 for valid signature, 1 to mark signature failure, - * otherwise, an address of an "aggregator" contract. - * <6-byte> validUntil - Last timestamp this operation is valid at, or 0 for "indefinitely" - * <6-byte> validAfter - First timestamp this operation is valid - * If an account doesn't use time-range, it is enough to - * return SIG_VALIDATION_FAILED value (1) for signature failure. - * Note that the validation code cannot use block.timestamp (or block.number) directly. - */ - function validateUserOp( - PackedUserOperation calldata userOp, - bytes32 userOpHash, - uint256 missingAccountFunds - ) external returns (uint256 validationData); - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IAuth.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IAuth.sol deleted file mode 100644 index 6d8df782db..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IAuth.sol +++ /dev/null @@ -1,17 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -/// @title IAuth -/// @author Agustin Aguilar, Michael Standen, William Hua -/// @notice Internal interface for the auth modules -abstract contract IAuth { - - function _isValidImage( - bytes32 imageHash - ) internal view virtual returns (bool isValid); - - function _updateImageHash( - bytes32 imageHash - ) internal virtual; - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/ICheckpointer.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/ICheckpointer.sol deleted file mode 100644 index 99064d20d5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/ICheckpointer.sol +++ /dev/null @@ -1,25 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../Payload.sol"; - -/// @notice Snapshot for a specific wallet -/// @param imageHash Image hash of the wallet -/// @param checkpoint Checkpoint identifier -struct Snapshot { - bytes32 imageHash; - uint256 checkpoint; -} - -/// @title ICheckpointer -/// @author Agustin Aguilar -/// @notice Interface for the checkpointer module -interface ICheckpointer { - - /// @notice Get the snapshot for a specific wallet - /// @param _wallet The wallet address - /// @param _proof The proof - /// @return snapshot The snapshot - function snapshotFor(address _wallet, bytes calldata _proof) external view returns (Snapshot memory snapshot); - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IDelegatedExtension.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IDelegatedExtension.sol deleted file mode 100644 index 7d958ce555..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IDelegatedExtension.sol +++ /dev/null @@ -1,25 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -/// @title IDelegatedExtension -/// @author Agustin Aguilar -/// @notice Interface for the delegated extension module -interface IDelegatedExtension { - - /// @notice Handle a sequence delegate call - /// @param _opHash The operation hash - /// @param _startingGas The starting gas - /// @param _index The index - /// @param _numCalls The number of calls - /// @param _space The space - /// @param _data The data - function handleSequenceDelegateCall( - bytes32 _opHash, - uint256 _startingGas, - uint256 _index, - uint256 _numCalls, - uint256 _space, - bytes calldata _data - ) external; - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC1155Receiver.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC1155Receiver.sol deleted file mode 100644 index 3a95246bd5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC1155Receiver.sol +++ /dev/null @@ -1,38 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.18; - -/// @title IERC1155Receiver -/// @notice Interface for the ERC1155 receiver module -interface IERC1155Receiver { - - /// @notice Called when a single ERC1155 token is transferred to this contract - /// @param operator The address which initiated the transfer - /// @param from The address which previously owned the token - /// @param tokenId The ID of the token being transferred - /// @param value The amount of token being transferred - /// @param data Additional data with no specified format - /// @return magicValue On a success, the selector of the function that was called - function onERC1155Received( - address operator, - address from, - uint256 tokenId, - uint256 value, - bytes calldata data - ) external returns (bytes4 magicValue); - - /// @notice Called when multiple ERC1155 tokens are transferred to this contract - /// @param operator The address which initiated the transfer - /// @param from The address which previously owned the token - /// @param ids The list of token IDs being transferred - /// @param values The amounts of each token being transferred - /// @param data Additional data with no specified format - /// @return magicValue On a success, the selector of the function that was called - function onERC1155BatchReceived( - address operator, - address from, - uint256[] calldata ids, - uint256[] calldata values, - bytes calldata data - ) external returns (bytes4 magicValue); - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC1271.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC1271.sol deleted file mode 100644 index 854f8c5fa1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC1271.sol +++ /dev/null @@ -1,35 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.18; - -bytes4 constant IERC1271_MAGIC_VALUE_HASH = 0x1626ba7e; -bytes4 constant IERC1271_MAGIC_VALUE_BYTES = 0x20c13b0b; - -/// @title IERC1271 -/// @notice Interface for ERC1271 -interface IERC1271 { - - /// @notice Verifies whether the provided signature is valid with respect to the provided hash - /// @dev MUST return the correct magic value if the signature provided is valid for the provided hash - /// > The bytes4 magic value to return when signature is valid is 0x1626ba7e : bytes4(keccak256("isValidSignature(bytes32,bytes)") - /// > This function MAY modify Ethereum's state - /// @param _hash keccak256 hash that was signed - /// @param _signature Signature byte array associated with _data - /// @return magicValue Magic value 0x1626ba7e if the signature is valid and 0x0 otherwise - function isValidSignature(bytes32 _hash, bytes calldata _signature) external view returns (bytes4 magicValue); - -} - -/// @title IERC1271Data -/// @notice Deprecated interface for ERC1271 using bytes instead of bytes32 -interface IERC1271Data { - - /// @notice Verifies whether the provided signature is valid with respect to the provided hash - /// @dev MUST return the correct magic value if the signature provided is valid for the provided hash - /// > The bytes4 magic value to return when signature is valid is 0x20c13b0b : bytes4(keccak256("isValidSignature(bytes,bytes)") - /// > This function MAY modify Ethereum's state - /// @param _data Data that was signed - /// @param _signature Signature byte array associated with _data - /// @return magicValue Magic value 0x20c13b0b if the signature is valid and 0x0 otherwise - function isValidSignature(bytes calldata _data, bytes calldata _signature) external view returns (bytes4 magicValue); - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC223Receiver.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC223Receiver.sol deleted file mode 100644 index 4db7a04c51..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC223Receiver.sol +++ /dev/null @@ -1,15 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.18; - -/// @title IERC223Receiver -/// @notice Interface for the ERC223 receiver module -interface IERC223Receiver { - - /// @notice Called when ERC223 tokens are received by this contract - /// @param from The address which previously owned the tokens - /// @param value The amount of tokens being transferred - /// @param data Transaction metadata - /// @return signature The signature of the function to be called - function tokenReceived(address from, uint256 value, bytes calldata data) external returns (bytes4 signature); - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC721Receiver.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC721Receiver.sol deleted file mode 100644 index 77b3bcfd78..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC721Receiver.sol +++ /dev/null @@ -1,21 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.18; - -/// @title IERC721Receiver -/// @notice Interface for the ERC721 receiver module -interface IERC721Receiver { - - /// @notice Called when a single ERC721 token is transferred to this contract - /// @param operator The address which initiated the transfer - /// @param from The address which previously owned the token - /// @param tokenId The ID of the token being transferred - /// @param data Additional data with no specified format - /// @return magicValue On a success, the selector of the function that was called - function onERC721Received( - address operator, - address from, - uint256 tokenId, - bytes calldata data - ) external returns (bytes4 magicValue); - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC777Receiver.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC777Receiver.sol deleted file mode 100644 index d32ea85a1f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IERC777Receiver.sol +++ /dev/null @@ -1,24 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.18; - -/// @title IERC777Receiver -/// @notice Interface for the ERC777 receiver module -interface IERC777Receiver { - - /// @notice Called when tokens are received by this contract - /// @param operator The address which initiated the transfer - /// @param from The address which previously owned the tokens - /// @param to The address which is receiving the tokens - /// @param amount The amount of tokens being transferred - /// @param data Additional data with no specified format - /// @param operatorData Additional data with no specified format - function tokensReceived( - address operator, - address from, - address to, - uint256 amount, - bytes calldata data, - bytes calldata operatorData - ) external; - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IEntryPoint.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IEntryPoint.sol deleted file mode 100644 index 31c1f14929..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IEntryPoint.sol +++ /dev/null @@ -1,10 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.28; - -interface IEntryPoint { - - function depositTo( - address account - ) external payable; - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IPartialAuth.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IPartialAuth.sol deleted file mode 100644 index d66f747ea3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/IPartialAuth.sol +++ /dev/null @@ -1,35 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../Payload.sol"; - -/// @title IPartialAuth -/// @author Agustin Aguilar -/// @notice Interface for the partial auth module -interface IPartialAuth { - - /// @notice Recover the partial signature - /// @param _payload The payload - /// @param _signature The signature to recover - /// @return threshold The signature threshold - /// @return weight The derived weight - /// @return isValidImage Whether the image hash is valid - /// @return imageHash The derived image hash - /// @return checkpoint The checkpoint identifier - /// @return opHash The hash of the payload - function recoverPartialSignature( - Payload.Decoded calldata _payload, - bytes calldata _signature - ) - external - view - returns ( - uint256 threshold, - uint256 weight, - bool isValidImage, - bytes32 imageHash, - uint256 checkpoint, - bytes32 opHash - ); - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/ISapient.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/ISapient.sol deleted file mode 100644 index e600ffd9e6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/modules/interfaces/ISapient.sol +++ /dev/null @@ -1,38 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../Payload.sol"; - -/// @title ISapient -/// @author Agustin Aguilar, Michael Standen -/// @notice Sapient signers take an explicit payload and return their own "imageHash" as result -/// @dev The consumer of this signer must validate if the imageHash is valid or not, for the desired configuration -interface ISapient { - - /// @notice Recovers the image hash of a given signature - /// @param payload The payload to recover the signature from - /// @param signature The signature to recover the image hash from - /// @return imageHash The recovered image hash - function recoverSapientSignature( - Payload.Decoded calldata payload, - bytes calldata signature - ) external view returns (bytes32 imageHash); - -} - -/// @title ISapientCompact -/// @author Agustin Aguilar, Michael Standen -/// @notice Sapient signers take a compacted payload and return their own "imageHash" as result -/// @dev The consumer of this signer must validate if the imageHash is valid or not, for the desired configuration -interface ISapientCompact { - - /// @notice Recovers the image hash of a given signature, using a hashed payload - /// @param digest The digest of the payload - /// @param signature The signature to recover the image hash from - /// @return imageHash The recovered image hash - function recoverSapientSignatureCompact( - bytes32 digest, - bytes calldata signature - ) external view returns (bytes32 imageHash); - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/utils/Base64.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/utils/Base64.sol deleted file mode 100644 index af97c9d2a5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/utils/Base64.sol +++ /dev/null @@ -1,169 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.4; - -/// @notice Library to encode strings in Base64. -/// @author Solady (https://github.com/vectorized/solady/blob/main/src/utils/Base64.sol) -/// @author Modified from Solmate (https://github.com/transmissions11/solmate/blob/main/src/utils/Base64.sol) -/// @author Modified from (https://github.com/Brechtpd/base64/blob/main/base64.sol) by Brecht Devos - . -library Base64 { - - /// @dev Encodes `data` using the base64 encoding described in RFC 4648. - /// See: https://datatracker.ietf.org/doc/html/rfc4648 - /// @param fileSafe Whether to replace '+' with '-' and '/' with '_'. - /// @param noPadding Whether to strip away the padding. - function encode(bytes memory data, bool fileSafe, bool noPadding) internal pure returns (string memory result) { - /// @solidity memory-safe-assembly - assembly { - let dataLength := mload(data) - - if dataLength { - // Multiply by 4/3 rounded up. - // The `shl(2, ...)` is equivalent to multiplying by 4. - let encodedLength := shl(2, div(add(dataLength, 2), 3)) - - // Set `result` to point to the start of the free memory. - result := mload(0x40) - - // Store the table into the scratch space. - // Offsetted by -1 byte so that the `mload` will load the character. - // We will rewrite the free memory pointer at `0x40` later with - // the allocated size. - // The magic constant 0x0670 will turn "-_" into "+/". - mstore(0x1f, "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdef") - mstore(0x3f, xor("ghijklmnopqrstuvwxyz0123456789-_", mul(iszero(fileSafe), 0x0670))) - - // Skip the first slot, which stores the length. - let ptr := add(result, 0x20) - let end := add(ptr, encodedLength) - - let dataEnd := add(add(0x20, data), dataLength) - let dataEndValue := mload(dataEnd) // Cache the value at the `dataEnd` slot. - mstore(dataEnd, 0x00) // Zeroize the `dataEnd` slot to clear dirty bits. - - // Run over the input, 3 bytes at a time. - for { } 1 { } { - data := add(data, 3) // Advance 3 bytes. - let input := mload(data) - - // Write 4 bytes. Optimized for fewer stack operations. - mstore8(0, mload(and(shr(18, input), 0x3F))) - mstore8(1, mload(and(shr(12, input), 0x3F))) - mstore8(2, mload(and(shr(6, input), 0x3F))) - mstore8(3, mload(and(input, 0x3F))) - mstore(ptr, mload(0x00)) - - ptr := add(ptr, 4) // Advance 4 bytes. - if iszero(lt(ptr, end)) { break } - } - mstore(dataEnd, dataEndValue) // Restore the cached value at `dataEnd`. - mstore(0x40, add(end, 0x20)) // Allocate the memory. - // Equivalent to `o = [0, 2, 1][dataLength % 3]`. - let o := div(2, mod(dataLength, 3)) - // Offset `ptr` and pad with '='. We can simply write over the end. - mstore(sub(ptr, o), shl(240, 0x3d3d)) - // Set `o` to zero if there is padding. - o := mul(iszero(iszero(noPadding)), o) - mstore(sub(ptr, o), 0) // Zeroize the slot after the string. - mstore(result, sub(encodedLength, o)) // Store the length. - } - } - } - - /// @dev Encodes `data` using the base64 encoding described in RFC 4648. - /// Equivalent to `encode(data, false, false)`. - function encode( - bytes memory data - ) internal pure returns (string memory result) { - result = encode(data, false, false); - } - - /// @dev Encodes `data` using the base64 encoding described in RFC 4648. - /// Equivalent to `encode(data, fileSafe, false)`. - function encode(bytes memory data, bool fileSafe) internal pure returns (string memory result) { - result = encode(data, fileSafe, false); - } - - /// @dev Decodes base64 encoded `data`. - /// - /// Supports: - /// - RFC 4648 (both standard and file-safe mode). - /// - RFC 3501 (63: ','). - /// - /// Does not support: - /// - Line breaks. - /// - /// Note: For performance reasons, - /// this function will NOT revert on invalid `data` inputs. - /// Outputs for invalid inputs will simply be undefined behaviour. - /// It is the user's responsibility to ensure that the `data` - /// is a valid base64 encoded string. - function decode( - string memory data - ) internal pure returns (bytes memory result) { - /// @solidity memory-safe-assembly - assembly { - let dataLength := mload(data) - - if dataLength { - let decodedLength := mul(shr(2, dataLength), 3) - - for { } 1 { } { - // If padded. - if iszero(and(dataLength, 3)) { - let t := xor(mload(add(data, dataLength)), 0x3d3d) - // forgefmt: disable-next-item - decodedLength := sub( - decodedLength, - add(iszero(byte(30, t)), iszero(byte(31, t))) - ) - break - } - // If non-padded. - decodedLength := add(decodedLength, sub(and(dataLength, 3), 1)) - break - } - result := mload(0x40) - - // Write the length of the bytes. - mstore(result, decodedLength) - - // Skip the first slot, which stores the length. - let ptr := add(result, 0x20) - let end := add(ptr, decodedLength) - - // Load the table into the scratch space. - // Constants are optimized for smaller bytecode with zero gas overhead. - // `m` also doubles as the mask of the upper 6 bits. - let m := 0xfc000000fc00686c7074787c8084888c9094989ca0a4a8acb0b4b8bcc0c4c8cc - mstore(0x5b, m) - mstore(0x3b, 0x04080c1014181c2024282c3034383c4044484c5054585c6064) - mstore(0x1a, 0xf8fcf800fcd0d4d8dce0e4e8ecf0f4) - - for { } 1 { } { - // Read 4 bytes. - data := add(data, 4) - let input := mload(data) - - // Write 3 bytes. - // forgefmt: disable-next-item - mstore(ptr, or( - and(m, mload(byte(28, input))), - shr(6, or( - and(m, mload(byte(29, input))), - shr(6, or( - and(m, mload(byte(30, input))), - shr(6, mload(byte(31, input))) - )) - )) - )) - ptr := add(ptr, 3) - if iszero(lt(ptr, end)) { break } - } - mstore(0x40, add(end, 0x20)) // Allocate the memory. - mstore(end, 0) // Zeroize the slot after the bytes. - mstore(0x60, 0) // Restore the zero slot. - } - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/utils/LibBytes.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/utils/LibBytes.sol deleted file mode 100644 index 0dd0bacbb4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/utils/LibBytes.sol +++ /dev/null @@ -1,120 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.18; - -/// @title Library for reading data from bytes arrays -/// @author Agustin Aguilar (aa@horizon.io), Michael Standen (mstan@horizon.io) -/// @notice This library contains functions for reading data from bytes arrays. -/// @dev These functions do not check if the input index is within the bounds of the data array. -/// @dev Reading out of bounds may return dirty values. -library LibBytes { - - function readFirstUint8( - bytes calldata _data - ) internal pure returns (uint8 a, uint256 newPointer) { - assembly { - let word := calldataload(_data.offset) - a := shr(248, word) - newPointer := 1 - } - } - - function readUint8(bytes calldata _data, uint256 _index) internal pure returns (uint8 a, uint256 newPointer) { - assembly { - let word := calldataload(add(_index, _data.offset)) - a := shr(248, word) - newPointer := add(_index, 1) - } - } - - function readUint16(bytes calldata _data, uint256 _index) internal pure returns (uint16 a, uint256 newPointer) { - assembly { - let word := calldataload(add(_index, _data.offset)) - a := shr(240, word) - newPointer := add(_index, 2) - } - } - - function readUint24(bytes calldata _data, uint256 _index) internal pure returns (uint24 a, uint256 newPointer) { - assembly { - let word := calldataload(add(_index, _data.offset)) - a := shr(232, word) - newPointer := add(_index, 3) - } - } - - function readUint64(bytes calldata _data, uint256 _index) internal pure returns (uint64 a, uint256 newPointer) { - assembly { - let word := calldataload(add(_index, _data.offset)) - a := shr(192, word) - newPointer := add(_index, 8) - } - } - - function readUint160(bytes calldata _data, uint256 _index) internal pure returns (uint160 a, uint256 newPointer) { - assembly { - let word := calldataload(add(_index, _data.offset)) - a := shr(96, word) - newPointer := add(_index, 20) - } - } - - function readUint256(bytes calldata _data, uint256 _index) internal pure returns (uint256 a, uint256 newPointer) { - assembly { - a := calldataload(add(_index, _data.offset)) - newPointer := add(_index, 32) - } - } - - function readUintX( - bytes calldata _data, - uint256 _index, - uint256 _length - ) internal pure returns (uint256 a, uint256 newPointer) { - assembly { - let word := calldataload(add(_index, _data.offset)) - let shift := sub(256, mul(_length, 8)) - a := and(shr(shift, word), sub(shl(mul(8, _length), 1), 1)) - newPointer := add(_index, _length) - } - } - - function readBytes4(bytes calldata _data, uint256 _pointer) internal pure returns (bytes4 a, uint256 newPointer) { - assembly { - let word := calldataload(add(_pointer, _data.offset)) - a := and(word, 0xffffffff00000000000000000000000000000000000000000000000000000000) - newPointer := add(_pointer, 4) - } - } - - function readBytes32(bytes calldata _data, uint256 _pointer) internal pure returns (bytes32 a, uint256 newPointer) { - assembly { - a := calldataload(add(_pointer, _data.offset)) - newPointer := add(_pointer, 32) - } - } - - function readAddress(bytes calldata _data, uint256 _index) internal pure returns (address a, uint256 newPointer) { - assembly { - let word := calldataload(add(_index, _data.offset)) - a := and(shr(96, word), 0xffffffffffffffffffffffffffffffffffffffff) - newPointer := add(_index, 20) - } - } - - /// @dev ERC-2098 Compact Signature - function readRSVCompact( - bytes calldata _data, - uint256 _index - ) internal pure returns (bytes32 r, bytes32 s, uint8 v, uint256 newPointer) { - uint256 yParityAndS; - assembly { - r := calldataload(add(_index, _data.offset)) - yParityAndS := calldataload(add(_index, add(_data.offset, 32))) - newPointer := add(_index, 64) - } - uint256 yParity = uint256(yParityAndS >> 255); - s = bytes32(uint256(yParityAndS) & ((1 << 255) - 1)); - v = uint8(yParity) + 27; - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/utils/LibOptim.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/utils/LibOptim.sol deleted file mode 100644 index e43a2cd87a..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/utils/LibOptim.sol +++ /dev/null @@ -1,68 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.18; - -/// @title LibOptim -/// @author Agustin Aguilar -/// @notice Library for optimized EVM operations -library LibOptim { - - /** - * @notice Computes the keccak256 hash of two 32-byte inputs. - * @dev It uses only scratch memory space. - * @param _a The first 32 bytes of the hash. - * @param _b The second 32 bytes of the hash. - * @return c The keccak256 hash of the two 32-byte inputs. - */ - function fkeccak256(bytes32 _a, bytes32 _b) internal pure returns (bytes32 c) { - assembly { - mstore(0, _a) - mstore(32, _b) - c := keccak256(0, 64) - } - } - - /** - * @notice Returns the return data from the last call. - * @return r The return data from the last call. - */ - function returnData() internal pure returns (bytes memory r) { - assembly { - let size := returndatasize() - r := mload(0x40) - let start := add(r, 32) - mstore(0x40, add(start, size)) - mstore(r, size) - returndatacopy(start, 0, size) - } - } - - /** - * @notice Calls another contract with the given parameters. - * @dev This method doesn't increase the memory pointer. - * @param _to The address of the contract to call. - * @param _val The value to send to the contract. - * @param _gas The amount of gas to provide for the call. - * @param _data The data to send to the contract. - * @return r The success status of the call. - */ - function call(address _to, uint256 _val, uint256 _gas, bytes memory _data) internal returns (bool r) { - assembly { - r := call(_gas, _to, _val, add(_data, 32), mload(_data), 0, 0) - } - } - - /** - * @notice Calls another contract with the given parameters, using delegatecall. - * @dev This method doesn't increase the memory pointer. - * @param _to The address of the contract to call. - * @param _gas The amount of gas to provide for the call. - * @param _data The data to send to the contract. - * @return r The success status of the call. - */ - function delegatecall(address _to, uint256 _gas, bytes memory _data) internal returns (bool r) { - assembly { - r := delegatecall(_gas, _to, add(_data, 32), mload(_data), 0, 0) - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/utils/P256.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/utils/P256.sol deleted file mode 100644 index 3446aa54b0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/utils/P256.sol +++ /dev/null @@ -1,153 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.4; - -/// @notice Gas optimized P256 wrapper. -/// @author Solady (https://github.com/vectorized/solady/blob/main/src/utils/P256.sol) -/// @author Modified from Daimo P256 Verifier (https://github.com/daimo-eth/p256-verifier/blob/master/src/P256.sol) -/// @author Modified from OpenZeppelin (https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/utils/cryptography/P256.sol) -library P256 { - - /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/ - /* CUSTOM ERRORS */ - /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ - - /// @dev Unable to verify the P256 signature, due to missing - /// RIP-7212 P256 verifier precompile and missing Solidity P256 verifier. - error P256VerificationFailed(); - - /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/ - /* CONSTANTS */ - /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ - - /// @dev Address of the Solidity P256 verifier. - /// Please make sure the contract is deployed onto the chain you are working on. - /// See: https://gist.github.com/Vectorized/599b0d8a94d21bc74700eb1354e2f55c - /// Unlike RIP-7212, this verifier returns `uint256(0)` on failure, to - /// facilitate easier existence check. This verifier will also never revert. - address internal constant VERIFIER = 0x000000000000D01eA45F9eFD5c54f037Fa57Ea1a; - - /// @dev Address of the RIP-7212 P256 verifier precompile. - /// Currently, we don't support EIP-7212's precompile at 0x0b as it has not been finalized. - /// See: https://github.com/ethereum/RIPs/blob/master/RIPS/rip-7212.md - address internal constant RIP_PRECOMPILE = 0x0000000000000000000000000000000000000100; - - /// @dev The order of the secp256r1 elliptic curve. - uint256 internal constant N = 0xFFFFFFFF00000000FFFFFFFFFFFFFFFFBCE6FAADA7179E84F3B9CAC2FC632551; - - /// @dev `N/2`. Used for checking the malleability of the signature. - uint256 private constant _HALF_N = 0x7fffffff800000007fffffffffffffffde737d56d38bcf4279dce5617e3192a8; - - /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/ - /* P256 VERIFICATION OPERATIONS */ - /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ - - /// @dev Returns if the signature (`r`, `s`) is valid for `hash` and public key (`x`, `y`). - /// Does NOT include the malleability check. - function verifySignatureAllowMalleability( - bytes32 hash, - bytes32 r, - bytes32 s, - bytes32 x, - bytes32 y - ) internal view returns (bool isValid) { - /// @solidity memory-safe-assembly - assembly { - let m := mload(0x40) - mstore(m, hash) - mstore(add(m, 0x20), r) - mstore(add(m, 0x40), s) - mstore(add(m, 0x60), x) - mstore(add(m, 0x80), y) - mstore(0x00, 0) // Zeroize the return slot before the staticcalls. - pop(staticcall(gas(), RIP_PRECOMPILE, m, 0xa0, 0x00, 0x20)) - // RIP-7212 dictates that success returns `uint256(1)`. - // But failure returns zero returndata, which is ambiguous. - if iszero(returndatasize()) { - pop(staticcall(gas(), VERIFIER, m, 0xa0, returndatasize(), 0x20)) - // Unlike RIP-7212, the verifier returns `uint256(0)` on failure, - // allowing us to use the returndatasize to determine existence. - if iszero(returndatasize()) { - mstore(returndatasize(), 0xd0d5039b) // `P256VerificationFailed()`. - revert(0x1c, 0x04) - } - } - isValid := eq(1, mload(0x00)) - } - } - - /// @dev Returns if the signature (`r`, `s`) is valid for `hash` and public key (`x`, `y`). - /// Includes the malleability check. - function verifySignature( - bytes32 hash, - bytes32 r, - bytes32 s, - bytes32 x, - bytes32 y - ) internal view returns (bool isValid) { - /// @solidity memory-safe-assembly - assembly { - let m := mload(0x40) - mstore(m, hash) - mstore(add(m, 0x20), r) - mstore(add(m, 0x40), s) - mstore(add(m, 0x60), x) - mstore(add(m, 0x80), y) - mstore(0x00, 0) // Zeroize the return slot before the staticcalls. - pop(staticcall(gas(), RIP_PRECOMPILE, m, 0xa0, 0x00, 0x20)) - // RIP-7212 dictates that success returns `uint256(1)`. - // But failure returns zero returndata, which is ambiguous. - if iszero(returndatasize()) { - pop(staticcall(gas(), VERIFIER, m, 0xa0, returndatasize(), 0x20)) - // Unlike RIP-7212, the verifier returns `uint256(0)` on failure, - // allowing us to use the returndatasize to determine existence. - if iszero(returndatasize()) { - mstore(returndatasize(), 0xd0d5039b) // `P256VerificationFailed()`. - revert(0x1c, 0x04) - } - } - // Optimize for happy path. Users are unlikely to pass in malleable signatures. - isValid := lt(gt(s, _HALF_N), eq(1, mload(0x00))) - } - } - - /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/ - /* OTHER OPERATIONS */ - /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ - - /// @dev Returns `s` normalized to the lower half of the curve. - function normalized( - bytes32 s - ) internal pure returns (bytes32 result) { - /// @solidity memory-safe-assembly - assembly { - result := xor(s, mul(xor(sub(N, s), s), gt(s, _HALF_N))) - } - } - - /// @dev Helper function for `abi.decode(encoded, (bytes32, bytes32))`. - /// If `encoded.length < 64`, `(x, y)` will be `(0, 0)`, which is an invalid point. - function tryDecodePoint( - bytes memory encoded - ) internal pure returns (bytes32 x, bytes32 y) { - /// @solidity memory-safe-assembly - assembly { - let t := gt(mload(encoded), 0x3f) - x := mul(mload(add(encoded, 0x20)), t) - y := mul(mload(add(encoded, 0x40)), t) - } - } - - /// @dev Helper function for `abi.decode(encoded, (bytes32, bytes32))`. - /// If `encoded.length < 64`, `(x, y)` will be `(0, 0)`, which is an invalid point. - function tryDecodePointCalldata( - bytes calldata encoded - ) internal pure returns (bytes32 x, bytes32 y) { - /// @solidity memory-safe-assembly - assembly { - let t := gt(encoded.length, 0x3f) - x := mul(calldataload(encoded.offset), t) - y := mul(calldataload(add(encoded.offset, 0x20)), t) - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/src/utils/WebAuthn.sol b/lib/signals-implicit-mode/lib/sequence-v3/src/utils/WebAuthn.sol deleted file mode 100644 index 754809dfdf..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/src/utils/WebAuthn.sol +++ /dev/null @@ -1,333 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.4; - -import { Base64 } from "./Base64.sol"; -import { P256 } from "./P256.sol"; - -/// @notice WebAuthn helper. -/// @author Solady (https://github.com/vectorized/solady/blob/main/src/utils/WebAuthn.sol) -/// @author Modified from Daimo WebAuthn (https://github.com/daimo-eth/p256-verifier/blob/master/src/WebAuthn.sol) -/// @author Modified from Coinbase WebAuthn (https://github.com/base-org/webauthn-sol/blob/main/src/WebAuthn.sol) -library WebAuthn { - - /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/ - /* STRUCTS */ - /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ - - /// @dev Helps make encoding and decoding easier, alleviates stack-too-deep. - struct WebAuthnAuth { - // The WebAuthn authenticator data. - // See: https://www.w3.org/TR/webauthn-2/#dom-authenticatorassertionresponse-authenticatordata. - bytes authenticatorData; - // The WebAuthn client data JSON. - // See: https://www.w3.org/TR/webauthn-2/#dom-authenticatorresponse-clientdatajson. - string clientDataJSON; - // Start index of "challenge":"..." in `clientDataJSON`. - uint256 challengeIndex; - // Start index of "type":"..." in `clientDataJSON`. - uint256 typeIndex; - // The r value of secp256r1 signature. - bytes32 r; - // The s value of secp256r1 signature. - bytes32 s; - } - - /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/ - /* WEBAUTHN VERIFICATION OPERATIONS */ - /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ - - /// @dev Verifies a Webauthn Authentication Assertion. - /// See: https://www.w3.org/TR/webauthn-2/#sctn-verifying-assertion. - /// - /// We do not verify all the steps as described in the specification, only ones - /// relevant to our context. Please carefully read through this list before usage. - /// - /// Specifically, we do verify the following: - /// - Verify that `authenticatorData` (which comes from the authenticator, - /// such as iCloud Keychain) indicates a well-formed assertion with the - /// "User Present" bit set. If `requireUserVerification` is set, checks that the - /// authenticator enforced user verification. User verification should be required - /// if, and only if, `options.userVerification` is set to required in the request. - /// - Verifies that the client JSON is of type "webauthn.get", - /// i.e. the client was responding to a request to assert authentication. - /// - Verifies that the client JSON contains the requested challenge. - /// - Verifies that (r, s) constitute a valid signature over both the - /// `authData` and client JSON, for public key (x, y). - /// - /// We make some assumptions about the particular use case of this verifier, - /// so we do NOT verify the following: - /// - Does NOT verify that the origin in the `clientDataJSON` matches the - /// Relying Party's origin: it is considered the authenticator's responsibility to - /// ensure that the user is interacting with the correct RP. This is enforced by - /// most high quality authenticators properly, particularly the iCloud Keychain - /// and Google Password Manager were tested. - /// - Does NOT verify That `topOrigin` in `clientDataJSON` is well-formed: - /// We assume it would never be present, i.e. the credentials are never used in a - /// cross-origin/iframe context. The website/app set up should disallow cross-origin - /// usage of the credentials. This is the default behavior for created credentials - /// in common settings. - /// - Does NOT verify that the `rpIdHash` in `authenticatorData` is the SHA-256 hash - /// of the RP ID expected by the Relying Party: - /// this means that we rely on the authenticator to properly enforce - /// credentials to be used only by the correct RP. - /// This is generally enforced with features like Apple App Site Association - /// and Google Asset Links. To protect from edge cases in which a previously-linked - /// RP ID is removed from the authorized RP IDs, we recommend that messages - /// signed by the authenticator include some expiry mechanism. - /// - Does NOT verify the credential backup state: this assumes the credential backup - /// state is NOT used as part of Relying Party business logic or policy. - /// - Does NOT verify the values of the client extension outputs: - /// this assumes that the Relying Party does not use client extension outputs. - /// - Does NOT verify the signature counter: signature counters are intended to enable - /// risk scoring for the Relying Party. This assumes risk scoring is not used as part - /// of Relying Party business logic or policy. - /// - Does NOT verify the attestation object: this assumes that - /// response.attestationObject is NOT present in the response, - /// i.e. the RP does not intend to verify an attestation. - function verify( - bytes memory challenge, - bool requireUserVerification, - WebAuthnAuth memory auth, - bytes32 x, - bytes32 y - ) internal view returns (bool result) { - bytes32 messageHash; - string memory encoded = Base64.encode(challenge, true, true); - /// @solidity memory-safe-assembly - assembly { - let clientDataJSON := mload(add(auth, 0x20)) - let n := mload(clientDataJSON) // `clientDataJSON`'s length. - let o := add(clientDataJSON, 0x20) // Start of `clientData`'s bytes. - { - let c := mload(add(auth, 0x40)) // Challenge index in `clientDataJSON`. - let t := mload(add(auth, 0x60)) // Type index in `clientDataJSON`. - let l := mload(encoded) // Cache `encoded`'s length. - let q := add(l, 0x0d) // Length of `encoded` prefixed with '"challenge":"'. - mstore(encoded, shr(152, '"challenge":"')) // Temp prefix with '"challenge":"'. - result := - and( - // 11. Verify JSON's type. Also checks for possible addition overflows. - and( - eq(shr(88, mload(add(o, t))), shr(88, '"type":"webauthn.get"')), lt(shr(128, or(t, c)), lt(add(0x14, t), n)) - ), - // 12. Verify JSON's challenge. Includes a check for the closing '"'. - and( - eq(keccak256(add(o, c), q), keccak256(add(encoded, 0x13), q)), - and(eq(byte(0, mload(add(add(o, c), q))), 34), lt(add(q, c), n)) - ) - ) - mstore(encoded, l) // Restore `encoded`'s length, in case of string interning. - } - // Skip 13., 14., 15. - let l := mload(mload(auth)) // Length of `authenticatorData`. - // 16. Verify that the "User Present" flag is set (bit 0). - // 17. Verify that the "User Verified" flag is set (bit 2), if required. - // See: https://www.w3.org/TR/webauthn-2/#flags. - let u := or(1, shl(2, iszero(iszero(requireUserVerification)))) - result := and(and(result, gt(l, 0x20)), eq(and(mload(add(mload(auth), 0x21)), u), u)) - if result { - let p := add(mload(auth), 0x20) // Start of `authenticatorData`'s bytes. - let e := add(p, l) // Location of the word after `authenticatorData`. - let w := mload(e) // Cache the word after `authenticatorData`. - // 19. Compute `sha256(clientDataJSON)`. - // 20. Compute `sha256(authenticatorData ‖ sha256(clientDataJSON))`. - // forgefmt: disable-next-item - messageHash := mload(staticcall(gas(), - shl(1, staticcall(gas(), 2, o, n, e, 0x20)), p, add(l, 0x20), 0x01, 0x20)) - mstore(e, w) // Restore the word after `authenticatorData`, in case of reuse. - // `returndatasize()` is `0x20` on `sha256` success, and `0x00` otherwise. - if iszero(returndatasize()) { invalid() } - } - } - // `P256.verifySignature` returns false if `s > N/2` due to the malleability check. - if (result) { - result = P256.verifySignature(messageHash, auth.r, auth.s, x, y); - } - } - - /// @dev Plain variant of verify. - function verify( - bytes memory challenge, - bool requireUserVerification, - bytes memory authenticatorData, - string memory clientDataJSON, - uint256 challengeIndex, - uint256 typeIndex, - bytes32 r, - bytes32 s, - bytes32 x, - bytes32 y - ) internal view returns (bool) { - return verify( - challenge, - requireUserVerification, - WebAuthnAuth(authenticatorData, clientDataJSON, challengeIndex, typeIndex, r, s), - x, - y - ); - } - - /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/ - /* ENCODING / DECODING HELPERS */ - /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ - - /// @dev Returns `abi.encode(auth)`. - function encodeAuth( - WebAuthnAuth memory auth - ) internal pure returns (bytes memory) { - return abi.encode(auth); - } - - /// @dev Performs a best-effort attempt to `abi.decode(auth)`. Won't revert. - /// If any fields cannot be successfully extracted, `decoded` will not be populated, - /// which will cause `verify` to return false (as `clientDataJSON` is empty). - function tryDecodeAuth( - bytes memory encodedAuth - ) internal pure returns (WebAuthnAuth memory decoded) { - /// @solidity memory-safe-assembly - assembly { - for { let n := mload(encodedAuth) } iszero(lt(n, 0xc0)) { } { - let o := add(encodedAuth, 0x20) // Start of `encodedAuth`'s bytes. - let e := add(o, n) // End of `encodedAuth` in memory. - let p := add(mload(o), o) // Start of `encodedAuth`. - if or(gt(add(p, 0xc0), e), lt(p, o)) { break } - let authenticatorData := add(mload(p), p) - let clientDataJSON := add(mload(add(p, 0x20)), p) - if or(or(gt(authenticatorData, e), lt(authenticatorData, p)), or(gt(clientDataJSON, e), lt(clientDataJSON, p))) - { - break - } - if or( - gt(add(add(authenticatorData, 0x20), mload(authenticatorData)), e), - gt(add(add(clientDataJSON, 0x20), mload(clientDataJSON)), e) - ) { break } - mstore(decoded, authenticatorData) // `authenticatorData`. - mstore(add(decoded, 0x20), clientDataJSON) // `clientDataJSON`. - mstore(add(decoded, 0x40), mload(add(p, 0x40))) // `challengeIndex`. - mstore(add(decoded, 0x60), mload(add(p, 0x60))) // `typeIndex`. - mstore(add(decoded, 0x80), mload(add(p, 0x80))) // `r`. - mstore(add(decoded, 0xa0), mload(add(p, 0xa0))) // `s`. - break - } - } - } - - /// @dev Returns the compact encoding of `auth`: - /// ``` - /// abi.encodePacked( - /// uint16(auth.authenticatorData.length), - /// bytes(auth.authenticatorData), - /// bytes(auth.clientDataJSON), - /// uint16(auth.challengeIndex), - /// uint16(auth.typeIndex), - /// bytes32(auth.r), - /// bytes32(auth.s) - /// ) - /// ``` - /// Returns the empty string if any length or index exceeds 16 bits. - function tryEncodeAuthCompact( - WebAuthnAuth memory auth - ) internal pure returns (bytes memory result) { - /// @solidity memory-safe-assembly - assembly { - function copyBytes(o_, s_, c_) -> _e { - mstore(o_, shl(240, mload(s_))) - o_ := add(o_, c_) - _e := add(o_, mload(s_)) // The end of the bytes. - for { let d_ := sub(add(0x20, s_), o_) } 1 { } { - mstore(o_, mload(add(d_, o_))) - o_ := add(o_, 0x20) - if iszero(lt(o_, _e)) { break } - } - } - let clientDataJSON := mload(add(0x20, auth)) - let c := mload(add(0x40, auth)) // `challengeIndex`. - let t := mload(add(0x60, auth)) // `typeIndex`. - // If none of the lengths are more than `0xffff`. - if iszero(shr(16, or(or(t, c), or(mload(mload(auth)), mload(clientDataJSON))))) { - result := mload(0x40) - // `authenticatorData`, `clientDataJSON`. - let o := copyBytes(copyBytes(add(result, 0x20), mload(auth), 2), clientDataJSON, 0) - mstore(o, or(shl(240, c), shl(224, t))) // `challengeIndex`, `typeIndex`. - mstore(add(o, 0x04), mload(add(0x80, auth))) // `r`. - mstore(add(o, 0x24), mload(add(0xa0, auth))) // `s`. - mstore(result, sub(add(o, 0x24), result)) // Store the length. - mstore(add(o, 0x44), 0) // Zeroize the slot after the string. - mstore(0x40, add(o, 0x64)) // Allocate memory . - } - } - } - - /// @dev Approximately the same gas as `tryDecodeAuth`, but helps save on calldata. - /// If any fields cannot be successfully extracted, `decoded` will not be populated, - /// which will cause `verify` to return false (as `clientDataJSON` is empty). - function tryDecodeAuthCompact( - bytes memory encodedAuth - ) internal pure returns (WebAuthnAuth memory decoded) { - /// @solidity memory-safe-assembly - assembly { - function extractBytes(o_, l_) -> _m { - _m := mload(0x40) // Grab the free memory pointer. - let s_ := add(_m, 0x20) - for { let i_ := 0 } 1 { } { - mstore(add(s_, i_), mload(add(o_, i_))) - i_ := add(i_, 0x20) - if iszero(lt(i_, l_)) { break } - } - mstore(_m, l_) // Store the length. - mstore(add(l_, s_), 0) // Zeroize the slot after the string. - mstore(0x40, add(0x20, add(l_, s_))) // Allocate memory. - } - let n := mload(encodedAuth) - if iszero(lt(n, 0x46)) { - let o := add(encodedAuth, 0x20) // Start of `encodedAuth`'s bytes. - let e := add(o, n) // End of `encodedAuth` in memory. - n := shr(240, mload(o)) // Length of `authenticatorData`. - let a := add(o, 0x02) // Start of `authenticatorData`. - let c := add(a, n) // Start of `clientDataJSON`. - let j := sub(e, 0x44) // Start of `challengeIndex`. - if iszero(gt(c, j)) { - mstore(decoded, extractBytes(a, n)) // `authenticatorData`. - mstore(add(decoded, 0x20), extractBytes(c, sub(j, c))) // `clientDataJSON`. - mstore(add(decoded, 0x40), shr(240, mload(j))) // `challengeIndex`. - mstore(add(decoded, 0x60), shr(240, mload(add(j, 0x02)))) // `typeIndex`. - mstore(add(decoded, 0x80), mload(add(j, 0x04))) // `r`. - mstore(add(decoded, 0xa0), mload(add(j, 0x24))) // `s`. - } - } - } - } - - /// @dev Calldata variant of `tryDecodeAuthCompact`. - function tryDecodeAuthCompactCalldata( - bytes calldata encodedAuth - ) internal pure returns (WebAuthnAuth memory decoded) { - /// @solidity memory-safe-assembly - assembly { - function extractBytes(o_, l_) -> _m { - _m := mload(0x40) // Grab the free memory pointer. - let s_ := add(_m, 0x20) - calldatacopy(s_, o_, l_) - mstore(_m, l_) // Store the length. - mstore(add(l_, s_), 0) // Zeroize the slot after the string. - mstore(0x40, add(0x20, add(l_, s_))) // Allocate memory. - } - if iszero(lt(encodedAuth.length, 0x46)) { - let e := add(encodedAuth.offset, encodedAuth.length) // End of `encodedAuth`. - let n := shr(240, calldataload(encodedAuth.offset)) // Length of `authenticatorData`. - let a := add(encodedAuth.offset, 0x02) // Start of `authenticatorData`. - let c := add(a, n) // Start of `clientDataJSON`. - let j := sub(e, 0x44) // Start of `challengeIndex`. - if iszero(gt(c, j)) { - mstore(decoded, extractBytes(a, n)) // `authenticatorData`. - mstore(add(decoded, 0x20), extractBytes(c, sub(j, c))) // `clientDataJSON`. - mstore(add(decoded, 0x40), shr(240, calldataload(j))) // `challengeIndex`. - mstore(add(decoded, 0x60), shr(240, calldataload(add(j, 0x02)))) // `typeIndex`. - mstore(add(decoded, 0x80), calldataload(add(j, 0x04))) // `r`. - mstore(add(decoded, 0xa0), calldataload(add(j, 0x24))) // `s`. - } - } - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/Factory.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/Factory.t.sol deleted file mode 100644 index b9577de082..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/Factory.t.sol +++ /dev/null @@ -1,32 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Factory } from "../src/Factory.sol"; -import { AdvTest } from "./utils/TestUtils.sol"; - -contract FactoryTest is AdvTest { - - Factory factory; - - function setUp() external { - factory = new Factory(); - } - - function test_deploy(address _mainModule, bytes32 _salt) external { - address result = factory.deploy(_mainModule, _salt); - assertNotEq(result.code.length, 0); - } - - function test_deployTwice(address _mainModule, bytes32 _salt) external { - factory.deploy(_mainModule, _salt); - vm.expectRevert(abi.encodeWithSelector(Factory.DeployFailed.selector, _mainModule, _salt)); - factory.deploy(_mainModule, _salt); - } - - function test_deployForwardValue(address _mainModule, bytes32 _salt, uint256 _value) external { - vm.deal(address(this), _value); - address result = factory.deploy{ value: _value }(_mainModule, _salt); - assertEq(result.balance, _value); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/Guest.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/Guest.t.sol deleted file mode 100644 index 5ad438bd80..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/Guest.t.sol +++ /dev/null @@ -1,287 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Guest } from "../src/Guest.sol"; - -import { Calls } from "../src/modules/Calls.sol"; -import { Payload } from "../src/modules/Payload.sol"; -import { PrimitivesRPC } from "./utils/PrimitivesRPC.sol"; -import { AdvTest } from "./utils/TestUtils.sol"; - -struct GuestPayload { - bool noChainId; - Payload.Call[] calls; - uint160 space; - uint56 nonce; -} - -function toDecodedGuestPayload( - GuestPayload memory p -) pure returns (Payload.Decoded memory d) { - d.kind = Payload.KIND_TRANSACTIONS; - d.calls = p.calls; - d.space = p.space; - d.nonce = p.nonce; -} - -contract GuestTest is AdvTest { - - Guest public guest; - - event CallSucceeded(bytes32 _opHash, uint256 _index); - event CallFailed(bytes32 _opHash, uint256 _index, bytes _returnData); - event CallAborted(bytes32 _opHash, uint256 _index, bytes _returnData); - event CallSkipped(bytes32 _opHash, uint256 _index); - - function setUp() external { - guest = new Guest(); - } - - function test_fallback( - GuestPayload memory p - ) external { - vm.assume(p.calls.length < 5 && p.calls.length > 0); - Payload.Decoded memory decoded = toDecodedGuestPayload(p); - boundToLegalPayload(decoded); - for (uint256 i = 0; i < decoded.calls.length; i++) { - decoded.calls[i].to = boundNoPrecompile(decoded.calls[i].to); - decoded.calls[i].value = 0; // No ETH transfers allowed - decoded.calls[i].delegateCall = false; // No delegate calls allowed - decoded.calls[i].behaviorOnError = bound(decoded.calls[i].behaviorOnError, 0, 2); - decoded.calls[i].gasLimit = bound(decoded.calls[i].gasLimit, 0, 1_000_000_000); - } - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - - bytes32 opHash = Payload.hashFor(decoded, address(guest)); - for (uint256 i = 0; i < decoded.calls.length; i++) { - if (decoded.calls[i].onlyFallback) { - vm.expectEmit(true, true, true, true); - emit CallSkipped(opHash, i); - } else { - vm.expectCall(decoded.calls[i].to, decoded.calls[i].data); - // vm.expectEmit(true, true, true, true); - // emit CallSucceeded(opHash, i); - } - } - (bool ok,) = address(guest).call(packed); - assertTrue(ok); - } - - function test_notEnoughGas(GuestPayload memory p, uint256 callIndex) external { - vm.assume(p.calls.length > 0); - callIndex = bound(callIndex, 0, p.calls.length - 1); - - Payload.Decoded memory decoded = toDecodedGuestPayload(p); - boundToLegalPayload(decoded); - - for (uint256 i = 0; i < decoded.calls.length; i++) { - decoded.calls[i].to = boundNoPrecompile(decoded.calls[i].to); - decoded.calls[i].value = 0; - decoded.calls[i].delegateCall = false; - - if (i == callIndex) { - // Only set high gas limit for the specified call - uint256 gasLimit = bound(decoded.calls[i].gasLimit, gasleft() + 1, type(uint256).max); - decoded.calls[i].gasLimit = gasLimit; - decoded.calls[i].onlyFallback = false; - } else { - // Set normal gas limits for other calls - decoded.calls[i].gasLimit = bound(decoded.calls[i].gasLimit, 0, 1_000_000_000); - } - } - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - - vm.expectRevert(); - (bool ok,) = address(guest).call(packed); - assertTrue(ok); - } - - function test_delegateCallNotAllowed(GuestPayload memory p, uint256 callIndex) external { - vm.assume(p.calls.length > 0); - callIndex = bound(callIndex, 0, p.calls.length - 1); - - Payload.Decoded memory decoded = toDecodedGuestPayload(p); - boundToLegalPayload(decoded); - - for (uint256 i = 0; i < decoded.calls.length; i++) { - decoded.calls[i].to = boundNoPrecompile(decoded.calls[i].to); - decoded.calls[i].value = 0; - decoded.calls[i].gasLimit = bound(decoded.calls[i].gasLimit, 0, 1_000_000_000); - - if (i == callIndex) { - // Set delegateCall to true for the specified call - decoded.calls[i].delegateCall = true; - decoded.calls[i].onlyFallback = false; - } else { - decoded.calls[i].delegateCall = false; - } - } - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - - vm.expectRevert(abi.encodeWithSelector(Guest.DelegateCallNotAllowed.selector, callIndex)); - (bool ok,) = address(guest).call(packed); - assertTrue(ok); - } - - function test_callFailsWithIgnoreBehavior(GuestPayload memory p, uint256 callIndex) external { - vm.assume(p.calls.length > 0); - callIndex = bound(callIndex, 0, p.calls.length - 1); - - Payload.Decoded memory decoded = toDecodedGuestPayload(p); - boundToLegalPayload(decoded); - - decoded.calls[callIndex].to = boundNoPrecompile(decoded.calls[callIndex].to); - address failureAddress = decoded.calls[callIndex].to; - bytes32 failureDataHash = keccak256(decoded.calls[callIndex].data); - - for (uint256 i = 0; i < decoded.calls.length; i++) { - decoded.calls[i].to = boundNoPrecompile(decoded.calls[i].to); - decoded.calls[i].value = 0; - decoded.calls[i].delegateCall = false; - decoded.calls[i].gasLimit = bound(decoded.calls[i].gasLimit, 0, 1_000_000_000); - - if (i == callIndex) { - decoded.calls[i].behaviorOnError = Payload.BEHAVIOR_IGNORE_ERROR; - decoded.calls[i].onlyFallback = false; - } else if (decoded.calls[i].to == failureAddress) { - decoded.calls[i].behaviorOnError = Payload.BEHAVIOR_IGNORE_ERROR; - } - } - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - bytes32 opHash = Payload.hashFor(decoded, address(guest)); - - // Mock the call to fail with some revert data - bytes memory revertData = abi.encodeWithSignature("Error(string)", "Test error"); - vm.mockCallRevert(decoded.calls[callIndex].to, decoded.calls[callIndex].data, revertData); - - bool errorFlag = false; - for (uint256 i = 0; i < decoded.calls.length; i++) { - vm.expectEmit(true, true, true, true); - - if (!errorFlag && decoded.calls[i].onlyFallback) { - emit CallSkipped(opHash, i); - } else if (decoded.calls[i].to == failureAddress && keccak256(decoded.calls[i].data) == failureDataHash) { - emit CallFailed(opHash, i, revertData); - errorFlag = true; - } else { - emit CallSucceeded(opHash, i); - vm.expectCall(decoded.calls[i].to, decoded.calls[i].data); - errorFlag = false; - } - } - - (bool ok,) = address(guest).call(packed); - assertTrue(ok); - } - - function test_callFailsWithRevertBehavior(GuestPayload memory p, uint256 callIndex) external { - vm.assume(p.calls.length > 0); - callIndex = bound(callIndex, 0, p.calls.length - 1); - - Payload.Decoded memory decoded = toDecodedGuestPayload(p); - boundToLegalPayload(decoded); - - decoded.calls[callIndex].to = boundNoPrecompile(decoded.calls[callIndex].to); - - for (uint256 i = 0; i < decoded.calls.length; i++) { - decoded.calls[i].to = boundNoPrecompile(decoded.calls[i].to); - decoded.calls[i].value = 0; - decoded.calls[i].delegateCall = false; - decoded.calls[i].gasLimit = bound(decoded.calls[i].gasLimit, 0, 1_000_000_000); - - if (decoded.calls[i].to == decoded.calls[callIndex].to && i != callIndex) { - decoded.calls[i].behaviorOnError = Payload.BEHAVIOR_IGNORE_ERROR; - } - - if (i == callIndex) { - decoded.calls[i].behaviorOnError = Payload.BEHAVIOR_REVERT_ON_ERROR; - decoded.calls[i].onlyFallback = false; - } - } - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - - // Mock the call to fail with some revert data - bytes memory revertData = abi.encodeWithSignature("Error(string)", "Test error"); - vm.mockCallRevert(decoded.calls[callIndex].to, decoded.calls[callIndex].data, revertData); - - // Expect the revert - vm.expectRevert(abi.encodeWithSelector(Calls.Reverted.selector, decoded, callIndex, revertData)); - - (bool ok,) = address(guest).call(packed); - assertTrue(ok); - } - - function test_callFailsWithAbortBehavior(GuestPayload memory p, uint256 callIndex) external { - vm.assume(p.calls.length > 0); - callIndex = bound(callIndex, 0, p.calls.length - 1); - - Payload.Decoded memory decoded = toDecodedGuestPayload(p); - boundToLegalPayload(decoded); - - decoded.calls[callIndex].to = boundNoPrecompile(decoded.calls[callIndex].to); - - for (uint256 i = 0; i < decoded.calls.length; i++) { - decoded.calls[i].to = boundNoPrecompile(decoded.calls[i].to); - decoded.calls[i].value = 0; - decoded.calls[i].delegateCall = false; - decoded.calls[i].gasLimit = bound(decoded.calls[i].gasLimit, 0, 1_000_000_000); - - if (decoded.calls[i].to == decoded.calls[callIndex].to && i != callIndex) { - decoded.calls[i].behaviorOnError = Payload.BEHAVIOR_IGNORE_ERROR; - } - - if (i == callIndex) { - decoded.calls[i].behaviorOnError = Payload.BEHAVIOR_ABORT_ON_ERROR; - decoded.calls[i].onlyFallback = false; - } - } - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - bytes32 opHash = Payload.hashFor(decoded, address(guest)); - - // Mock the call to fail with some revert data - bytes memory revertData = abi.encodeWithSignature("Error(string)", "Test error"); - vm.mockCallRevert(decoded.calls[callIndex].to, decoded.calls[callIndex].data, revertData); - - // Expect the abort event - vm.expectEmit(true, true, true, true); - emit CallAborted(opHash, callIndex, revertData); - - (bool ok,) = address(guest).call(packed); - assertTrue(ok); - } - - function test_forwardPayment(uint256 _value1, uint256 _value2) external { - address to1 = address(0x100001); - address to2 = address(0x100002); - - _value1 = bound(_value1, 0, type(uint128).max); - _value2 = bound(_value2, 0, type(uint128).max); - - Payload.Decoded memory payload; - payload.kind = Payload.KIND_TRANSACTIONS; - payload.calls = new Payload.Call[](2); - payload.calls[0].to = to1; - payload.calls[0].value = _value1; - payload.calls[1].to = to2; - payload.calls[1].value = _value2; - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, payload); - - uint256 total = _value1 + _value2; - vm.deal(address(this), total); - (bool ok,) = address(guest).call{ value: total }(packed); - assertTrue(ok); - - assertEq(address(this).balance, 0); - - assertEq(address(to1).balance, _value1); - assertEq(address(to2).balance, _value2); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/Stage1Module.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/Stage1Module.t.sol deleted file mode 100644 index cf99dbb5e2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/Stage1Module.t.sol +++ /dev/null @@ -1,1305 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Factory } from "../src/Factory.sol"; -import { Stage1Module } from "../src/Stage1Module.sol"; -import { Stage2Module } from "../src/Stage2Module.sol"; - -import { Payload } from "../src/modules/Payload.sol"; - -import { BaseAuth } from "../src/modules/auth/BaseAuth.sol"; - -import { SelfAuth } from "../src/modules/auth/SelfAuth.sol"; - -import { Calls } from "../src/modules/Calls.sol"; -import { Stage1Auth } from "../src/modules/auth/Stage1Auth.sol"; -import { IPartialAuth } from "../src/modules/interfaces/IPartialAuth.sol"; - -import { ISapient } from "../src/modules/interfaces/ISapient.sol"; -import { PrimitivesRPC } from "./utils/PrimitivesRPC.sol"; -import { AdvTest } from "./utils/TestUtils.sol"; - -import { CanReenter } from "test/mocks/CanReenter.sol"; - -contract TestStage1Module is AdvTest { - - event ImageHashUpdated(bytes32 newImageHash); - - Factory public factory = new Factory(); - Stage1Module public stage1Module = new Stage1Module(address(factory), address(0)); - - event StaticSignatureSet(bytes32 _hash, address _address, uint96 _timestamp); - - function test_fails_on_low_weight( - uint16 _threshold, - uint56 _checkpoint, - uint8 _weight, - uint256 _pk, - bytes32 _digest, - bool _noChainId - ) external { - _weight = uint8(bound(_weight, 1, type(uint8).max)); - _threshold = uint16(bound(_threshold, 1, _weight)); - _pk = boundPk(_pk); - - address signer = vm.addr(_pk); - - string memory config; - - { - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(signer), ":", vm.toString(_weight))); - config = PrimitivesRPC.newConfig(vm, _threshold, _checkpoint, ce); - } - - bytes32 configHash = PrimitivesRPC.getImageHash(vm, config); - - // Deploy wallet for that config - address payable wallet = payable(factory.deploy(address(stage1Module), configHash)); - - Payload.Decoded memory payload; - payload.kind = Payload.KIND_DIGEST; - payload.digest = _digest; - payload.noChainId = _noChainId; - - // Create a signature with only nodes - bytes memory signature = PrimitivesRPC.toEncodedSignature(vm, config, "", !_noChainId); - - // Call isValidSignature and expect it to fail - vm.expectRevert(abi.encodeWithSelector(BaseAuth.InvalidSignatureWeight.selector, _threshold, 0)); - Stage1Module(wallet).isValidSignature(_digest, signature); - } - - function test_1271_single_signer( - uint16 _threshold, - uint56 _checkpoint, - uint8 _weight, - uint256 _pk, - bytes32 _digest, - bool _noChainId - ) external { - _threshold = uint16(bound(_threshold, 0, _weight)); - _pk = boundPk(_pk); - - address signer = vm.addr(_pk); - - string memory config; - - { - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(signer), ":", vm.toString(_weight))); - config = PrimitivesRPC.newConfig(vm, _threshold, _checkpoint, ce); - } - - bytes32 configHash = PrimitivesRPC.getImageHash(vm, config); - - // Deploy wallet for that config - address payable wallet = payable(factory.deploy(address(stage1Module), configHash)); - - // Should predict the address of the wallet using the SDK - address predictedWallet = PrimitivesRPC.getAddress(vm, configHash, address(factory), address(stage1Module)); - assertEq(wallet, predictedWallet); - - Payload.Decoded memory payload; - payload.kind = Payload.KIND_DIGEST; - payload.digest = _digest; - payload.noChainId = _noChainId; - - // Sign the config - (uint256 v, bytes32 r, bytes32 s) = vm.sign(_pk, Payload.hashFor(payload, wallet)); - - bytes memory signature = PrimitivesRPC.toEncodedSignature( - vm, - config, - string(abi.encodePacked(vm.toString(signer), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v))), - !_noChainId - ); - - // Call isValidSignature - bytes4 result = Stage1Module(wallet).isValidSignature(_digest, signature); - assertEq(result, bytes4(0x1626ba7e)); - } - - struct test_update_config_params { - uint16 threshold; - uint56 checkpoint; - uint8 weight; - uint256 pk; - bool noChainId; - // Next config parameters - uint16 nextThreshold; - uint56 nextCheckpoint; - uint8 nextWeight; - uint256 nextPk; - // Test transaction parameters - bytes32 digest; - } - - struct test_update_config_vars { - address ogSigner; - address nextSigner; - string ogConfig; - string nextConfig; - bytes32 ogConfigHash; - bytes32 nextConfigHash; - Payload.Decoded updateConfigPayload; - bytes updateConfigSignature; - bytes updateConfigPackedPayload; - Payload.Decoded useNewImageHashPayload; - bytes useNewImageHashSignature; - } - - function test_update_config( - test_update_config_params memory params - ) external { - params.pk = boundPk(params.pk); - params.nextPk = boundPk(params.nextPk); - params.threshold = uint16(bound(params.threshold, 0, params.weight)); - params.nextThreshold = uint16(bound(params.nextThreshold, 0, params.nextWeight)); - - test_update_config_vars memory vars; - - vars.ogSigner = vm.addr(params.pk); - - { - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(vars.ogSigner), ":", vm.toString(params.weight))); - vars.ogConfig = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - } - - vars.ogConfigHash = PrimitivesRPC.getImageHash(vm, vars.ogConfig); - - // Deploy wallet for that config - address payable wallet = payable(factory.deploy(address(stage1Module), vars.ogConfigHash)); - - vars.nextSigner = vm.addr(params.nextPk); - - { - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(vars.nextSigner), ":", vm.toString(params.nextWeight))); - vars.nextConfig = PrimitivesRPC.newConfig(vm, params.nextThreshold, params.nextCheckpoint, ce); - } - - vars.nextConfigHash = PrimitivesRPC.getImageHash(vm, vars.nextConfig); - - // Update configuration to the next config - vars.updateConfigPayload.kind = Payload.KIND_TRANSACTIONS; - vars.updateConfigPayload.calls = new Payload.Call[](1); - vars.updateConfigPayload.calls[0] = Payload.Call({ - to: address(wallet), - value: 0, - data: abi.encodeWithSelector(BaseAuth.updateImageHash.selector, vars.nextConfigHash), - gasLimit: 100000, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - vars.updateConfigPayload.noChainId = params.noChainId; - - { - // Sign the payload - (uint256 v, bytes32 r, bytes32 s) = vm.sign(params.pk, Payload.hashFor(vars.updateConfigPayload, wallet)); - - // Call updateConfig - vars.updateConfigSignature = PrimitivesRPC.toEncodedSignature( - vm, - vars.ogConfig, - string( - abi.encodePacked( - vm.toString(vars.ogSigner), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v) - ) - ), - !params.noChainId - ); - } - - // Pack payload - vars.updateConfigPackedPayload = PrimitivesRPC.toPackedPayload(vm, vars.updateConfigPayload); - - // Perform updateConfig - vm.expectEmit(true, true, false, true, wallet); - emit ImageHashUpdated(vars.nextConfigHash); - Stage1Module(wallet).execute(vars.updateConfigPackedPayload, vars.updateConfigSignature); - - // Now the wallet should be at stage 2 - // and its imageHash should be updated - assertEq(Stage1Module(wallet).getImplementation(), stage1Module.STAGE_2_IMPLEMENTATION()); - assertEq(Stage2Module(wallet).imageHash(), vars.nextConfigHash); - - // Now try to use the new imageHash - vars.useNewImageHashPayload.kind = Payload.KIND_DIGEST; - vars.useNewImageHashPayload.digest = params.digest; - - // Sign the payload - { - (uint256 v, bytes32 r, bytes32 s) = vm.sign(params.nextPk, Payload.hashFor(vars.useNewImageHashPayload, wallet)); - - vars.useNewImageHashSignature = PrimitivesRPC.toEncodedSignature( - vm, - vars.nextConfig, - string( - abi.encodePacked( - vm.toString(vars.nextSigner), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v) - ) - ), - true - ); - } - - bytes4 result = Stage2Module(wallet).isValidSignature(params.digest, vars.useNewImageHashSignature); - assertEq(result, bytes4(0x1626ba7e)); - } - - function test_receiveETH_stage1() external { - address payable wallet = payable(factory.deploy(address(stage1Module), bytes32(0))); - vm.deal(address(this), 1 ether); - wallet.transfer(1 ether); - assertEq(address(wallet).balance, 1 ether); - } - - struct test_receiveETH_stage2_params { - uint256 pk; - uint256 nextPk; - uint16 threshold; - uint16 nextThreshold; - uint56 checkpoint; - } - - struct test_receiveETH_stage2_vars { - address signer; - address payable wallet; - bytes updateConfigSignature; - bytes updateConfigPackedPayload; - string ogCe; - string ogConfig; - string nextCe; - string nextConfig; - bytes32 ogConfigHash; - bytes32 nextConfigHash; - } - - function test_receiveETH_stage2( - test_receiveETH_stage2_params memory params - ) external { - params.pk = boundPk(params.pk); - - test_receiveETH_stage2_vars memory vars; - vars.signer = vm.addr(params.pk); - - // Original config (stage1) - vars.ogCe = string(abi.encodePacked("signer:", vm.toString(vars.signer), ":1")); - vars.ogConfig = PrimitivesRPC.newConfig(vm, 1, 0, vars.ogCe); - vars.ogConfigHash = PrimitivesRPC.getImageHash(vm, vars.ogConfig); - - // Deploy wallet in stage1 - vars.wallet = payable(factory.deploy(address(stage1Module), vars.ogConfigHash)); - - // Next config (what we'll update to) - vars.nextCe = string(abi.encodePacked("signer:", vm.toString(vars.signer), ":1")); - vars.nextConfig = PrimitivesRPC.newConfig(vm, 1, 1, vars.nextCe); - vars.nextConfigHash = PrimitivesRPC.getImageHash(vm, vars.nextConfig); - - // Construct the payload to update the imageHash (which transitions us to stage2) - Payload.Decoded memory updateConfigPayload; - updateConfigPayload.kind = Payload.KIND_TRANSACTIONS; - updateConfigPayload.calls = new Payload.Call[](1); - updateConfigPayload.calls[0] = Payload.Call({ - to: address(vars.wallet), - value: 0, - data: abi.encodeWithSelector(BaseAuth.updateImageHash.selector, vars.nextConfigHash), - gasLimit: 100000, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Sign the payload using the original config - (uint256 v, bytes32 r, bytes32 s) = vm.sign(params.pk, Payload.hashFor(updateConfigPayload, vars.wallet)); - vars.updateConfigSignature = PrimitivesRPC.toEncodedSignature( - vm, - vars.ogConfig, - string( - abi.encodePacked(vm.toString(vars.signer), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v)) - ), - true - ); - - // Pack the payload and execute - vars.updateConfigPackedPayload = PrimitivesRPC.toPackedPayload(vm, updateConfigPayload); - vm.expectEmit(true, true, false, true, vars.wallet); - emit ImageHashUpdated(vars.nextConfigHash); - Stage1Module(vars.wallet).execute(vars.updateConfigPackedPayload, vars.updateConfigSignature); - - // Confirm that the wallet is now running stage2 - assertEq(Stage1Module(vars.wallet).getImplementation(), stage1Module.STAGE_2_IMPLEMENTATION()); - - // Send 1 ether to the newly upgraded wallet - vm.deal(address(this), 1 ether); - vars.wallet.transfer(1 ether); - - // Check that the wallet received the ether - assertEq(address(vars.wallet).balance, 1 ether); - } - - function test_static_signature_any_address( - bytes32 _digest, - bytes32 _imageHash, - uint256 _timestamp, - uint256 _validUntil, - address _otherCaller - ) external { - Payload.Decoded memory payload; - payload.kind = Payload.KIND_DIGEST; - payload.digest = _digest; - - _timestamp = bound(_timestamp, 0, type(uint64).max); - _validUntil = bound(_validUntil, _timestamp + 1, type(uint96).max); - - vm.warp(_timestamp); - - // Create a new wallet using imageHash - address payable wallet = payable(factory.deploy(address(stage1Module), _imageHash)); - - // Set the static signature - vm.prank(wallet); - vm.expectEmit(true, true, false, true, wallet); - emit StaticSignatureSet(Payload.hashFor(payload, wallet), address(0), uint96(_validUntil)); - Stage1Module(wallet).setStaticSignature(Payload.hashFor(payload, wallet), address(0), uint96(_validUntil)); - - (address addr, uint256 timestamp) = Stage1Module(wallet).getStaticSignature(Payload.hashFor(payload, wallet)); - assertEq(addr, address(0)); - assertEq(timestamp, _validUntil); - - // Call isValidSignature and expect it to succeed - bytes4 result = Stage1Module(wallet).isValidSignature(_digest, hex"80"); - assertEq(result, bytes4(0x1626ba7e)); - - // Even if called from other caller - vm.prank(_otherCaller); - result = Stage1Module(wallet).isValidSignature(_digest, hex"80"); - assertEq(result, bytes4(0x1626ba7e)); - } - - function test_static_signature_specific_address( - bytes32 _digest, - bytes32 _imageHash, - uint256 _timestamp, - uint256 _validUntil, - address _onlyAddress, - address _otherCaller - ) external { - vm.assume(_onlyAddress != address(0) && _onlyAddress != _otherCaller); - - Payload.Decoded memory payload; - payload.kind = Payload.KIND_DIGEST; - payload.digest = _digest; - - _timestamp = bound(_timestamp, 0, type(uint64).max); - _validUntil = bound(_validUntil, _timestamp + 1, type(uint96).max); - - vm.warp(_timestamp); - - // Create a new wallet using imageHash - address payable wallet = payable(factory.deploy(address(stage1Module), _imageHash)); - - // Set the static signature - vm.prank(wallet); - vm.expectEmit(true, true, false, true, wallet); - emit StaticSignatureSet(Payload.hashFor(payload, wallet), _onlyAddress, uint96(_validUntil)); - Stage1Module(wallet).setStaticSignature(Payload.hashFor(payload, wallet), _onlyAddress, uint96(_validUntil)); - - (address addr, uint256 timestamp) = Stage1Module(wallet).getStaticSignature(Payload.hashFor(payload, wallet)); - assertEq(addr, _onlyAddress); - assertEq(timestamp, _validUntil); - - // Call isValidSignature from _onlyAddress should succeed - vm.prank(_onlyAddress); - bytes4 result = Stage1Module(wallet).isValidSignature(_digest, hex"80"); - assertEq(result, bytes4(0x1626ba7e)); - - // Call isValidSignature from _otherCaller should fail - vm.prank(_otherCaller); - vm.expectRevert( - abi.encodeWithSelector( - BaseAuth.InvalidStaticSignatureWrongCaller.selector, - Payload.hashFor(payload, wallet), - _otherCaller, - _onlyAddress - ) - ); - Stage1Module(wallet).isValidSignature(_digest, hex"80"); - } - - function test_reverts_invalid_static_signature_expired( - bytes32 _digest, - bytes32 _imageHash, - uint256 _startTime, - uint256 _validUntil - ) external { - // Ensure validUntil is strictly after startTime and within uint96 range - _startTime = bound(_startTime, 0, type(uint96).max - 1); - _validUntil = bound(_validUntil, _startTime + 1, type(uint96).max); - - // Set the current time to _startTime - vm.warp(_startTime); - - // Create a new wallet - address payable wallet = payable(factory.deploy(address(stage1Module), _imageHash)); - - // Prepare the payload and calculate its hash - Payload.Decoded memory payload; - payload.kind = Payload.KIND_DIGEST; - payload.digest = _digest; - bytes32 opHash = Payload.hashFor(payload, wallet); - - // Set the static signature from the wallet itself, valid until _validUntil - // Use address(0) to allow any caller before expiration - vm.prank(wallet); - vm.expectEmit(true, true, false, true, wallet); - emit StaticSignatureSet(opHash, address(0), uint96(_validUntil)); - Stage1Module(wallet).setStaticSignature(opHash, address(0), uint96(_validUntil)); - - // Verify it was set correctly - (address addr, uint256 timestamp) = Stage1Module(wallet).getStaticSignature(opHash); - assertEq(addr, address(0)); - assertEq(timestamp, _validUntil); - - // --- Test Case 1: Use signature just before expiry (should work) --- - vm.warp(_validUntil - 1); // Set time to just before expiration - bytes4 result = Stage1Module(wallet).isValidSignature(_digest, hex"80"); - assertEq(result, bytes4(0x1626ba7e), "Signature should be valid before expiry"); - - // --- Test Case 2: Use signature exactly at expiry (should fail) --- - vm.warp(_validUntil); // Set time exactly to expiration - vm.expectRevert(abi.encodeWithSelector(BaseAuth.InvalidStaticSignatureExpired.selector, opHash, _validUntil)); - Stage1Module(wallet).isValidSignature(_digest, hex"80"); - - // --- Test Case 3: Use signature after expiry (should fail) --- - vm.warp(_validUntil + 1); // Set time after expiration - vm.expectRevert(abi.encodeWithSelector(BaseAuth.InvalidStaticSignatureExpired.selector, opHash, _validUntil)); - Stage1Module(wallet).isValidSignature(_digest, hex"80"); - } - - function test_reverts_set_static_signature_not_self( - bytes32 _hash, - bytes32 _imageHash, - address _sigAddress, - uint96 _timestamp, - address _caller // The address attempting the call (not the wallet) - ) external { - // Create a new wallet - address payable wallet = payable(factory.deploy(address(stage1Module), _imageHash)); - - // Ensure the caller is not the wallet itself - vm.assume(_caller != wallet); - - // Attempt to call setStaticSignature from _caller - vm.prank(_caller); - vm.expectRevert(abi.encodeWithSelector(SelfAuth.OnlySelf.selector, _caller)); - Stage1Module(wallet).setStaticSignature(_hash, _sigAddress, _timestamp); - - // Verify that the signature was NOT set (should still be default values) - (address addr, uint256 ts) = Stage1Module(wallet).getStaticSignature(_hash); - assertEq(addr, address(0), "Static signature address should not be set"); - assertEq(ts, 0, "Static signature timestamp should not be set"); - } - - struct test_recover_partial_signature_params { - Payload.Decoded payload; - uint16 threshold; - uint56 checkpoint; - uint8 signerWeight; - uint256 pk; - bool signPayload; - bool useEthSign; - bool noChainId; - } - - struct test_recover_partial_signature_vars { - address signer; - string config; - bytes32 configHash; - bytes encodedSignature; - uint8 v; - bytes32 r; - bytes32 s; - bytes32 payloadHash; - address wallet; - uint256 expectedWeight; - } - - function test_recover_partial_signature( - test_recover_partial_signature_params memory params - ) external { - boundToLegalPayload(params.payload); - params.pk = boundPk(params.pk); - params.payload.noChainId = params.noChainId; - if (params.signPayload) { - params.threshold = uint16(bound(params.threshold, 1, type(uint16).max)); - params.signerWeight = uint8(bound(params.signerWeight, 0, type(uint8).max)); - } else { - params.threshold = uint16(bound(params.threshold, 0, type(uint16).max)); - params.signerWeight = uint8(bound(params.signerWeight, 0, type(uint8).max)); - } - - test_recover_partial_signature_vars memory vars; - vars.signer = vm.addr(params.pk); - - string memory ce = - string(abi.encodePacked("signer:", vm.toString(vars.signer), ":", vm.toString(params.signerWeight))); - vars.config = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - vars.configHash = PrimitivesRPC.getImageHash(vm, vars.config); - - vars.wallet = factory.deploy(address(stage1Module), vars.configHash); - - vars.payloadHash = Payload.hashFor(params.payload, vars.wallet); - string memory signatures = ""; - vars.expectedWeight = 0; - - if (params.signPayload) { - bytes32 hashToSign = vars.payloadHash; - if (params.useEthSign) { - hashToSign = keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", vars.payloadHash)); - } - (vars.v, vars.r, vars.s) = vm.sign(params.pk, hashToSign); - - string memory signatureType = params.useEthSign ? ":eth_sign:" : ":hash:"; - signatures = string( - abi.encodePacked( - vm.toString(vars.signer), - signatureType, - vm.toString(vars.r), - ":", - vm.toString(vars.s), - ":", - vm.toString(vars.v) - ) - ); - vars.expectedWeight = params.signerWeight; - } - - vars.encodedSignature = PrimitivesRPC.toEncodedSignature(vm, vars.config, signatures, !params.noChainId); - - ( - uint256 recoveredThreshold, - uint256 recoveredWeight, - bool recoveredIsValidImage, - bytes32 recoveredImageHash, - uint256 recoveredCheckpoint, - bytes32 recoveredOpHash - ) = IPartialAuth(vars.wallet).recoverPartialSignature(params.payload, vars.encodedSignature); - - assertEq(recoveredThreshold, params.threshold, "Threshold mismatch"); - assertEq(recoveredWeight, vars.expectedWeight, "Weight mismatch"); - bool expectedIsValidImage = address( - uint160(uint256(keccak256(abi.encodePacked(hex"ff", factory, recoveredImageHash, stage1Module.INIT_CODE_HASH())))) - ) == vars.wallet; - assertEq(recoveredIsValidImage, expectedIsValidImage, "isValidImage mismatch"); - assertEq(recoveredImageHash, vars.configHash, "ImageHash mismatch"); - assertEq(recoveredCheckpoint, params.checkpoint, "Checkpoint mismatch"); - assertEq(recoveredOpHash, vars.payloadHash, "OpHash mismatch"); - } - - struct test_invalid_is_valid_signature_params { - bytes32 digest; - uint16 threshold; - uint56 checkpoint; - uint8 weight; - uint256 intendedPk; - uint256 actualPk; - bool noChainId; - } - - struct test_invalid_is_valid_signature_vars { - address intendedSigner; - address actualSigner; - string config; - string badConfig; - bytes32 configHash; - address payable wallet; - Payload.Decoded payload; - bytes32 payloadHash; - uint8 v; - bytes32 r; - bytes32 s; - bytes encodedSignature; - } - - function test_invalid_is_valid_signature( - test_invalid_is_valid_signature_params memory params - ) external { - params.intendedPk = boundPk(params.intendedPk); - params.actualPk = boundPk(params.actualPk); - vm.assume(params.intendedPk != params.actualPk); - params.threshold = uint16(bound(params.threshold, 0, type(uint8).max)); - params.weight = uint8(bound(params.weight, params.threshold, type(uint8).max)); - - test_invalid_is_valid_signature_vars memory vars; - vars.intendedSigner = vm.addr(params.intendedPk); - vars.actualSigner = vm.addr(params.actualPk); - - string memory ce = - string(abi.encodePacked("signer:", vm.toString(vars.intendedSigner), ":", vm.toString(params.weight))); - vars.config = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - vars.configHash = PrimitivesRPC.getImageHash(vm, vars.config); - - string memory badCe = - string(abi.encodePacked("signer:", vm.toString(vars.actualSigner), ":", vm.toString(params.weight))); - vars.badConfig = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, badCe); - - vars.wallet = payable(factory.deploy(address(stage1Module), vars.configHash)); - - vars.payload.kind = Payload.KIND_DIGEST; - vars.payload.digest = params.digest; - vars.payload.noChainId = params.noChainId; - - vars.payloadHash = Payload.hashFor(vars.payload, vars.wallet); - - (vars.v, vars.r, vars.s) = vm.sign(params.actualPk, vars.payloadHash); - - string memory signatures = string( - abi.encodePacked( - vm.toString(vars.actualSigner), - ":hash:", - vm.toString(vars.r), - ":", - vm.toString(vars.s), - ":", - vm.toString(vars.v) - ) - ); - vars.encodedSignature = PrimitivesRPC.toEncodedSignature(vm, vars.badConfig, signatures, !params.noChainId); - - bytes4 result = Stage1Module(vars.wallet).isValidSignature(params.digest, vars.encodedSignature); - assertEq( - result, - bytes4(0), - "isValidSignature should return 0x00000000 for invalid signature (wrong signer -> imageHash mismatch)" - ); - } - - function test_reverts_update_to_zero_image_hash( - uint16 _threshold, - uint56 _checkpoint, - uint8 _weight, - uint256 _pk, - bool _noChainId - ) external { - _threshold = uint16(bound(_threshold, 0, _weight)); - _pk = boundPk(_pk); - - address signer = vm.addr(_pk); - - string memory config; - - { - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(signer), ":", vm.toString(_weight))); - config = PrimitivesRPC.newConfig(vm, _threshold, _checkpoint, ce); - } - - bytes32 configHash = PrimitivesRPC.getImageHash(vm, config); - - // Deploy wallet for that config - address payable wallet = payable(factory.deploy(address(stage1Module), configHash)); - - // Update configuration to zero imageHash - Payload.Decoded memory updateConfigPayload; - updateConfigPayload.kind = Payload.KIND_TRANSACTIONS; - updateConfigPayload.calls = new Payload.Call[](1); - updateConfigPayload.calls[0] = Payload.Call({ - to: address(wallet), - value: 0, - data: abi.encodeWithSelector(BaseAuth.updateImageHash.selector, bytes32(0)), - gasLimit: 100000, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - updateConfigPayload.noChainId = _noChainId; - - // Sign the payload - (uint256 v, bytes32 r, bytes32 s) = vm.sign(_pk, Payload.hashFor(updateConfigPayload, wallet)); - - // Call updateConfig - bytes memory updateConfigSignature = PrimitivesRPC.toEncodedSignature( - vm, - config, - string(abi.encodePacked(vm.toString(signer), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v))), - !_noChainId - ); - - // Pack payload - bytes memory updateConfigPackedPayload = PrimitivesRPC.toPackedPayload(vm, updateConfigPayload); - - bytes memory innerRevert = abi.encodeWithSelector(Stage1Auth.ImageHashIsZero.selector); - - // Attempt to update to zero imageHash and expect revert - vm.expectRevert(abi.encodeWithSelector(Calls.Reverted.selector, updateConfigPayload, 0, innerRevert)); - Stage1Module(wallet).execute(updateConfigPackedPayload, updateConfigSignature); - } - - struct test_update_image_hash_twice_params { - uint16 threshold1; - uint56 checkpoint1; - uint8 weight1; - uint256 pk1; - uint16 threshold2; - uint56 checkpoint2; - uint8 weight2; - uint256 pk2; - bool noChainId; - } - - struct test_update_image_hash_twice_vars { - address signer1; - address signer2; - string config1; - string config2; - string config3; - bytes32 configHash1; - bytes32 configHash2; - bytes32 configHash3; - address payable wallet; - Payload.Decoded updateConfigPayload1; - Payload.Decoded updateConfigPayload2; - bytes updateConfigSignature1; - bytes updateConfigSignature2; - bytes updateConfigPackedPayload1; - bytes updateConfigPackedPayload2; - } - - function test_update_image_hash_twice( - test_update_image_hash_twice_params memory params - ) external { - params.threshold1 = uint16(bound(params.threshold1, 0, params.weight1)); - params.threshold2 = uint16(bound(params.threshold2, 0, params.weight2)); - params.pk1 = boundPk(params.pk1); - params.pk2 = boundPk(params.pk2); - - test_update_image_hash_twice_vars memory vars; - vars.signer1 = vm.addr(params.pk1); - vars.signer2 = vm.addr(params.pk2); - - // First config - { - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(vars.signer1), ":", vm.toString(params.weight1))); - vars.config1 = PrimitivesRPC.newConfig(vm, params.threshold1, params.checkpoint1, ce); - } - vars.configHash1 = PrimitivesRPC.getImageHash(vm, vars.config1); - - // Deploy wallet with first config - vars.wallet = payable(factory.deploy(address(stage1Module), vars.configHash1)); - - // Second config - { - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(vars.signer2), ":", vm.toString(params.weight2))); - vars.config2 = PrimitivesRPC.newConfig(vm, params.threshold2, params.checkpoint2, ce); - } - vars.configHash2 = PrimitivesRPC.getImageHash(vm, vars.config2); - - // First update - vars.updateConfigPayload1.kind = Payload.KIND_TRANSACTIONS; - vars.updateConfigPayload1.calls = new Payload.Call[](1); - vars.updateConfigPayload1.calls[0] = Payload.Call({ - to: address(vars.wallet), - value: 0, - data: abi.encodeWithSelector(BaseAuth.updateImageHash.selector, vars.configHash2), - gasLimit: 100000, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - vars.updateConfigPayload1.noChainId = params.noChainId; - - // Sign the first payload - (uint256 v1, bytes32 r1, bytes32 s1) = vm.sign(params.pk1, Payload.hashFor(vars.updateConfigPayload1, vars.wallet)); - - // Call first update - vars.updateConfigSignature1 = PrimitivesRPC.toEncodedSignature( - vm, - vars.config1, - string( - abi.encodePacked( - vm.toString(vars.signer1), ":hash:", vm.toString(r1), ":", vm.toString(s1), ":", vm.toString(v1) - ) - ), - !params.noChainId - ); - - // Pack first payload - vars.updateConfigPackedPayload1 = PrimitivesRPC.toPackedPayload(vm, vars.updateConfigPayload1); - - // Execute first update - vm.expectEmit(true, true, false, true, vars.wallet); - emit ImageHashUpdated(vars.configHash2); - Stage1Module(vars.wallet).execute(vars.updateConfigPackedPayload1, vars.updateConfigSignature1); - - // Verify first update worked - assertEq(Stage1Module(vars.wallet).getImplementation(), stage1Module.STAGE_2_IMPLEMENTATION()); - assertEq(Stage2Module(vars.wallet).imageHash(), vars.configHash2); - - // Third config - { - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(vars.signer1), ":", vm.toString(params.weight1))); - vars.config3 = PrimitivesRPC.newConfig(vm, params.threshold1, params.checkpoint1, ce); - } - vars.configHash3 = PrimitivesRPC.getImageHash(vm, vars.config3); - - // Second update - vars.updateConfigPayload2.kind = Payload.KIND_TRANSACTIONS; - vars.updateConfigPayload2.calls = new Payload.Call[](1); - vars.updateConfigPayload2.calls[0] = Payload.Call({ - to: address(vars.wallet), - value: 0, - data: abi.encodeWithSelector(BaseAuth.updateImageHash.selector, vars.configHash3), - gasLimit: 100000, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - vars.updateConfigPayload2.noChainId = params.noChainId; - vars.updateConfigPayload2.nonce = 1; - - // Sign the second payload - (uint256 v2, bytes32 r2, bytes32 s2) = vm.sign(params.pk2, Payload.hashFor(vars.updateConfigPayload2, vars.wallet)); - - // Call second update - vars.updateConfigSignature2 = PrimitivesRPC.toEncodedSignature( - vm, - vars.config2, - string( - abi.encodePacked( - vm.toString(vars.signer2), ":hash:", vm.toString(r2), ":", vm.toString(s2), ":", vm.toString(v2) - ) - ), - !params.noChainId - ); - - // Pack second payload - vars.updateConfigPackedPayload2 = PrimitivesRPC.toPackedPayload(vm, vars.updateConfigPayload2); - - // Execute second update - vm.expectEmit(true, true, false, true, vars.wallet); - emit ImageHashUpdated(vars.configHash3); - Stage1Module(vars.wallet).execute(vars.updateConfigPackedPayload2, vars.updateConfigSignature2); - - // Verify second update worked - assertEq(Stage2Module(vars.wallet).imageHash(), vars.configHash3); - } - - struct test_update_image_hash_then_zero_params { - uint16 threshold1; - uint56 checkpoint1; - uint8 weight1; - uint256 pk1; - uint16 threshold2; - uint56 checkpoint2; - uint8 weight2; - uint256 pk2; - bool noChainId; - } - - struct test_update_image_hash_then_zero_vars { - address signer1; - address signer2; - string config1; - string config2; - bytes32 configHash1; - bytes32 configHash2; - address payable wallet; - Payload.Decoded updateConfigPayload1; - Payload.Decoded updateConfigPayload2; - bytes updateConfigSignature1; - bytes updateConfigSignature2; - bytes updateConfigPackedPayload1; - bytes updateConfigPackedPayload2; - } - - function test_update_image_hash_then_zero( - test_update_image_hash_then_zero_params memory params - ) external { - params.threshold1 = uint16(bound(params.threshold1, 0, params.weight1)); - params.threshold2 = uint16(bound(params.threshold2, 0, params.weight2)); - params.pk1 = boundPk(params.pk1); - params.pk2 = boundPk(params.pk2); - - test_update_image_hash_then_zero_vars memory vars; - vars.signer1 = vm.addr(params.pk1); - vars.signer2 = vm.addr(params.pk2); - - // First config - { - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(vars.signer1), ":", vm.toString(params.weight1))); - vars.config1 = PrimitivesRPC.newConfig(vm, params.threshold1, params.checkpoint1, ce); - } - vars.configHash1 = PrimitivesRPC.getImageHash(vm, vars.config1); - - // Deploy wallet with first config - vars.wallet = payable(factory.deploy(address(stage1Module), vars.configHash1)); - - // Second config - { - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(vars.signer2), ":", vm.toString(params.weight2))); - vars.config2 = PrimitivesRPC.newConfig(vm, params.threshold2, params.checkpoint2, ce); - } - vars.configHash2 = PrimitivesRPC.getImageHash(vm, vars.config2); - - // First update - vars.updateConfigPayload1.kind = Payload.KIND_TRANSACTIONS; - vars.updateConfigPayload1.calls = new Payload.Call[](1); - vars.updateConfigPayload1.calls[0] = Payload.Call({ - to: address(vars.wallet), - value: 0, - data: abi.encodeWithSelector(BaseAuth.updateImageHash.selector, vars.configHash2), - gasLimit: 100000, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - vars.updateConfigPayload1.noChainId = params.noChainId; - - // Sign the first payload - (uint256 v1, bytes32 r1, bytes32 s1) = vm.sign(params.pk1, Payload.hashFor(vars.updateConfigPayload1, vars.wallet)); - - // Call first update - vars.updateConfigSignature1 = PrimitivesRPC.toEncodedSignature( - vm, - vars.config1, - string( - abi.encodePacked( - vm.toString(vars.signer1), ":hash:", vm.toString(r1), ":", vm.toString(s1), ":", vm.toString(v1) - ) - ), - !params.noChainId - ); - - // Pack first payload - vars.updateConfigPackedPayload1 = PrimitivesRPC.toPackedPayload(vm, vars.updateConfigPayload1); - - // Execute first update - vm.expectEmit(true, true, false, true, vars.wallet); - emit ImageHashUpdated(vars.configHash2); - Stage1Module(vars.wallet).execute(vars.updateConfigPackedPayload1, vars.updateConfigSignature1); - - // Verify first update worked - assertEq(Stage1Module(vars.wallet).getImplementation(), stage1Module.STAGE_2_IMPLEMENTATION()); - assertEq(Stage2Module(vars.wallet).imageHash(), vars.configHash2); - - // Second update (attempting to set to zero) - vars.updateConfigPayload2.kind = Payload.KIND_TRANSACTIONS; - vars.updateConfigPayload2.calls = new Payload.Call[](1); - vars.updateConfigPayload2.calls[0] = Payload.Call({ - to: address(vars.wallet), - value: 0, - data: abi.encodeWithSelector(BaseAuth.updateImageHash.selector, bytes32(0)), - gasLimit: 100000, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - vars.updateConfigPayload2.noChainId = params.noChainId; - vars.updateConfigPayload2.nonce = 1; - - // Sign the second payload - (uint256 v2, bytes32 r2, bytes32 s2) = vm.sign(params.pk2, Payload.hashFor(vars.updateConfigPayload2, vars.wallet)); - - // Call second update - vars.updateConfigSignature2 = PrimitivesRPC.toEncodedSignature( - vm, - vars.config2, - string( - abi.encodePacked( - vm.toString(vars.signer2), ":hash:", vm.toString(r2), ":", vm.toString(s2), ":", vm.toString(v2) - ) - ), - !params.noChainId - ); - - // Pack second payload - vars.updateConfigPackedPayload2 = PrimitivesRPC.toPackedPayload(vm, vars.updateConfigPayload2); - - // Attempt second update and expect revert - bytes memory innerRevert = abi.encodeWithSelector(Stage1Auth.ImageHashIsZero.selector); - vm.expectRevert(abi.encodeWithSelector(Calls.Reverted.selector, vars.updateConfigPayload2, 0, innerRevert)); - Stage1Module(vars.wallet).execute(vars.updateConfigPackedPayload2, vars.updateConfigSignature2); - - // Verify imageHash is still configHash2 - assertEq(Stage2Module(vars.wallet).imageHash(), vars.configHash2); - } - - struct nested_sapient_test_params { - Payload.Decoded payload; - uint16 threshold; - uint56 checkpoint; - uint8 weight; - uint256 pk; - address parentWallet; - } - - struct nested_sapient_test_vars { - address signer; - string config; - bytes32 configHash; - address wallet; - bytes parentedSignature; - } - - function test_recover_sapient_as_if_nested( - nested_sapient_test_params memory params - ) public { - boundToLegalPayload(params.payload); - params.threshold = uint16(bound(params.threshold, 0, params.weight)); - params.pk = boundPk(params.pk); - - nested_sapient_test_vars memory vars; - - vars.signer = vm.addr(params.pk); - - { - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(vars.signer), ":", vm.toString(params.weight))); - vars.config = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - } - vars.configHash = PrimitivesRPC.getImageHash(vm, vars.config); - - vars.wallet = payable(factory.deploy(address(stage1Module), vars.configHash)); - - address[] memory nextParentWallets = new address[](params.payload.parentWallets.length + 1); - for (uint256 i = 0; i < params.payload.parentWallets.length; i++) { - nextParentWallets[i] = params.payload.parentWallets[i]; - } - nextParentWallets[params.payload.parentWallets.length] = params.parentWallet; - - address[] memory prevParentWallets = params.payload.parentWallets; - params.payload.parentWallets = nextParentWallets; - - // Sign the parented payload - (uint256 v, bytes32 r, bytes32 s) = vm.sign(params.pk, Payload.hashFor(params.payload, vars.wallet)); - vars.parentedSignature = PrimitivesRPC.toEncodedSignature( - vm, - vars.config, - string( - abi.encodePacked(vm.toString(vars.signer), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v)) - ), - !params.payload.noChainId - ); - - // Restore the original parentWallets - params.payload.parentWallets = prevParentWallets; - - // Recover the parented payload - vm.prank(params.parentWallet); - bytes32 recovered = Stage1Auth(vars.wallet).recoverSapientSignature(params.payload, vars.parentedSignature); - assertEq(recovered, bytes32(uint256(1))); - } - - function test_recover_sapient_as_if_nested_wrong_signature_fail( - nested_sapient_test_params memory params, - uint56 _differentCheckpoint - ) public { - vm.assume(_differentCheckpoint != params.checkpoint); - boundToLegalPayload(params.payload); - params.threshold = uint16(bound(params.threshold, 0, params.weight)); - params.pk = boundPk(params.pk); - - nested_sapient_test_vars memory vars; - - vars.signer = vm.addr(params.pk); - - string memory differentCheckpointConfig; - { - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(vars.signer), ":", vm.toString(params.weight))); - vars.config = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - differentCheckpointConfig = PrimitivesRPC.newConfig(vm, params.threshold, _differentCheckpoint, ce); - } - vars.configHash = PrimitivesRPC.getImageHash(vm, vars.config); - - vars.wallet = payable(factory.deploy(address(stage1Module), vars.configHash)); - - address[] memory nextParentWallets = new address[](params.payload.parentWallets.length + 1); - for (uint256 i = 0; i < params.payload.parentWallets.length; i++) { - nextParentWallets[i] = params.payload.parentWallets[i]; - } - nextParentWallets[params.payload.parentWallets.length] = params.parentWallet; - - address[] memory prevParentWallets = params.payload.parentWallets; - params.payload.parentWallets = nextParentWallets; - - // Sign the parented payload - (uint256 v, bytes32 r, bytes32 s) = vm.sign(params.pk, Payload.hashFor(params.payload, vars.wallet)); - vars.parentedSignature = PrimitivesRPC.toEncodedSignature( - vm, - differentCheckpointConfig, - string( - abi.encodePacked(vm.toString(vars.signer), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v)) - ), - !params.payload.noChainId - ); - - vm.expectRevert( - abi.encodeWithSelector(BaseAuth.InvalidSapientSignature.selector, params.payload, vars.parentedSignature) - ); - - // Restore the original parentWallets - params.payload.parentWallets = prevParentWallets; - - // Recover the parented payload - vm.prank(params.parentWallet); - Stage1Auth(vars.wallet).recoverSapientSignature(params.payload, vars.parentedSignature); - } - - function test_forbid_reentrancy( - uint16 _threshold, - uint56 _checkpoint, - uint8 _weight, - uint256 _signerPk, - Payload.Decoded memory _innerPayload, - bool _outerNoChainId, - bool _innerNoChainId - ) external { - CanReenter canReenter = new CanReenter(); - _weight = uint8(bound(_weight, 0, 255)); - _threshold = uint16(bound(_threshold, 0, _weight)); - _checkpoint = uint56(bound(_checkpoint, 0, type(uint56).max)); - _signerPk = boundPk(_signerPk); - - address signer = vm.addr(_signerPk); - - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(signer), ":", vm.toString(_weight))); - string memory config = PrimitivesRPC.newConfig(vm, _threshold, _checkpoint, ce); - - address payable wallet = payable(factory.deploy(address(stage1Module), PrimitivesRPC.getImageHash(vm, config))); - - // Build the inner payload - _innerPayload.noChainId = _innerNoChainId; - _innerPayload.kind = Payload.KIND_TRANSACTIONS; - boundToLegalPayload(_innerPayload); - - // Sign the inner payload - (uint256 v, bytes32 r, bytes32 s) = vm.sign(_signerPk, Payload.hashFor(_innerPayload, address(wallet))); - bytes memory innerSignature = PrimitivesRPC.toEncodedSignature( - vm, - config, - string(abi.encodePacked(vm.toString(signer), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v))), - !_innerNoChainId - ); - - // Pack the inner payload - bytes memory innerPackedPayload = PrimitivesRPC.toPackedPayload(vm, _innerPayload); - - // Build the outer payload - Payload.Decoded memory outerPayload; - outerPayload.kind = Payload.KIND_TRANSACTIONS; - outerPayload.calls = new Payload.Call[](1); - outerPayload.calls[0] = Payload.Call({ - to: address(canReenter), - value: 0, - data: abi.encodeWithSelector( - CanReenter.doAnotherCall.selector, - address(wallet), - abi.encodeWithSelector(Stage1Module(wallet).execute.selector, innerPackedPayload, innerSignature) - ), - gasLimit: 1000000, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - outerPayload.noChainId = _outerNoChainId; - - // Sign the outer payload - (v, r, s) = vm.sign(_signerPk, Payload.hashFor(outerPayload, address(wallet))); - bytes memory outerSignature = PrimitivesRPC.toEncodedSignature( - vm, - config, - string(abi.encodePacked(vm.toString(signer), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v))), - !_outerNoChainId - ); - - // Pack the outer payload - bytes memory outerPackedPayload = PrimitivesRPC.toPackedPayload(vm, outerPayload); - - // Execute the outer payload - vm.expectRevert(); - Stage1Module(wallet).execute(outerPackedPayload, outerSignature); - } - - function test_send_many_transactions( - uint256 _pk, - uint8 _weight, - uint16 _threshold, - uint256 _checkpoint, - uint256 _transactionCount, - bool _noChainId - ) external { - _pk = boundPk(_pk); - _weight = uint8(bound(_weight, 0, 255)); - _threshold = uint16(bound(_threshold, 0, _weight)); - _checkpoint = uint56(bound(_checkpoint, 0, type(uint56).max)); - _transactionCount = uint256(bound(_transactionCount, 2, 10)); - - address signer = vm.addr(_pk); - - string memory ce; - ce = string(abi.encodePacked(ce, "signer:", vm.toString(signer), ":", vm.toString(_weight))); - string memory config = PrimitivesRPC.newConfig(vm, _threshold, _checkpoint, ce); - - address payable wallet = payable(factory.deploy(address(stage1Module), PrimitivesRPC.getImageHash(vm, config))); - - // Send (i + 1) wei amount of ETH to address(100 + i) - vm.deal(wallet, 1 ether); - - for (uint256 i = 0; i < _transactionCount; i++) { - // Construct the payload - Payload.Decoded memory payload; - payload.kind = Payload.KIND_TRANSACTIONS; - payload.calls = new Payload.Call[](1); - payload.calls[0] = Payload.Call({ - to: address(uint160(100 + i)), - value: i + 1, - data: bytes(""), - gasLimit: 100000, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - payload.noChainId = _noChainId; - payload.nonce = i; - - // Sign the payload - (uint256 v, bytes32 r, bytes32 s) = vm.sign(_pk, Payload.hashFor(payload, address(wallet))); - bytes memory signature = PrimitivesRPC.toEncodedSignature( - vm, - config, - string( - abi.encodePacked(vm.toString(signer), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v)) - ), - !_noChainId - ); - - // Pack the payload - bytes memory packedPayload = PrimitivesRPC.toPackedPayload(vm, payload); - - // Execute the payload - (bool success,) = wallet.call{ value: i + 1 }( - abi.encodeWithSelector(Stage1Module(wallet).execute.selector, packedPayload, signature) - ); - assertTrue(success); - - // Verify the balance of address(100 + i) - assertEq(address(uint160(100 + i)).balance, i + 1); - } - } - - receive() external payable { } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/Wallet.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/Wallet.t.sol deleted file mode 100644 index 5af650ab02..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/Wallet.t.sol +++ /dev/null @@ -1,110 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Factory } from "../src/Factory.sol"; -import { AdvTest } from "./utils/TestUtils.sol"; - -contract VariableDataStore { - - bytes public data; - - constructor( - bytes memory _data - ) { - data = _data; - } - -} - -contract ModuleImp { - - VariableDataStore public immutable expectedDataPointer; - VariableDataStore public immutable willReturnPointer; - uint256 public immutable expectedValue; - bool public immutable alwaysReverts; - - constructor(bytes memory _expectedData, bytes memory _willReturn, uint256 _expectedValue, bool _alwaysReverts) { - expectedDataPointer = new VariableDataStore(_expectedData); - willReturnPointer = new VariableDataStore(_willReturn); - expectedValue = _expectedValue; - alwaysReverts = _alwaysReverts; - } - - receive() external payable { - _verifyAndReturn(); - } - - fallback() external payable { - _verifyAndReturn(); - } - - function _verifyAndReturn() internal { - if (alwaysReverts) { - revert("Always reverts"); - } - - bytes memory expectedData = expectedDataPointer.data(); - bytes memory willReturn = willReturnPointer.data(); - - if (keccak256(expectedData) != keccak256(msg.data)) { - revert("Invalid data"); - } - - if (msg.value != expectedValue) { - revert("Invalid value"); - } - - assembly { - return(add(willReturn, 32), mload(willReturn)) - } - } - -} - -contract WalletTest is AdvTest { - - Factory public factory; - - function setUp() public { - factory = new Factory(); - } - - function test_forward(bytes32 _salt, bytes calldata _data, bytes calldata _return) external { - ModuleImp module = new ModuleImp(_data, _return, 0, false); - address wallet = factory.deploy(address(module), _salt); - - (bool success, bytes memory returnData) = wallet.call(_data); - assertEq(success, true); - assertEq(returnData, _return); - } - - function test_doNotForwardWithValue(bytes32 _salt, uint256 _value) external { - vm.assume(_value > 0); - - vm.deal(address(this), _value); - ModuleImp module = new ModuleImp(bytes(""), bytes(""), 0, true); - address wallet = factory.deploy(address(module), _salt); - - (bool success, bytes memory returnData) = wallet.call{ value: _value }(bytes("")); - assertEq(success, true); - assertEq(returnData, bytes("")); - } - - function test_forwardValueWithData( - bytes32 _salt, - bytes calldata _data, - bytes calldata _return, - uint256 _value - ) external { - vm.assume(_data.length > 0); - - vm.deal(address(this), _value); - ModuleImp module = new ModuleImp(_data, _return, _value, false); - address wallet = factory.deploy(address(module), _salt); - - (bool success, bytes memory returnData) = wallet.call{ value: _value }(_data); - assertEq(success, true); - assertEq(returnData, _return); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/passkeys/Passkeys.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/passkeys/Passkeys.t.sol deleted file mode 100644 index 8e0199d977..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/passkeys/Passkeys.t.sol +++ /dev/null @@ -1,540 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Test, Vm } from "forge-std/Test.sol"; -import { console } from "forge-std/console.sol"; - -import { Passkeys } from "../../../src/extensions/passkeys/Passkeys.sol"; -import { WebAuthn } from "../../../src/utils/WebAuthn.sol"; -import { PrimitivesRPC } from "../../utils/PrimitivesRPC.sol"; -import { AdvTest } from "../../utils/TestUtils.sol"; - -// Harness contract to expose internal functions for testing -contract PasskeysImp is Passkeys { - - function rootForPasskeyPub( - bool _requireUserVerification, - bytes32 _x, - bytes32 _y, - bytes32 _metadata - ) external pure returns (bytes32) { - return _rootForPasskey(_requireUserVerification, _x, _y, _metadata); - } - - function decodeSignaturePub( - bytes calldata _signature - ) - external - pure - returns ( - WebAuthn.WebAuthnAuth memory _webAuthnAuth, - bool _requireUserVerification, - bytes32 _x, - bytes32 _y, - bytes32 _metadata - ) - { - return _decodeSignature(_signature); - } - -} - -address constant P256_VERIFIER = 0x000000000000D01eA45F9eFD5c54f037Fa57Ea1a; -bytes constant P256_VERIFIER_RUNTIME_CODE = - hex"3d604052610216565b60008060006ffffffffeffffffffffffffffffffffff60601b19808687098188890982838389096004098384858485093d510985868b8c096003090891508384828308850385848509089650838485858609600809850385868a880385088509089550505050808188880960020991505093509350939050565b81513d83015160408401516ffffffffeffffffffffffffffffffffff60601b19808384098183840982838388096004098384858485093d510985868a8b096003090896508384828308850385898a09089150610102848587890960020985868787880960080987038788878a0387088c0908848b523d8b015260408a0152565b505050505050505050565b81513d830151604084015185513d87015160408801518361013d578287523d870182905260408701819052610102565b80610157578587523d870185905260408701849052610102565b6ffffffffeffffffffffffffffffffffff60601b19808586098183840982818a099850828385830989099750508188830383838809089450818783038384898509870908935050826101be57836101be576101b28a89610082565b50505050505050505050565b808485098181860982828a09985082838a8b0884038483860386898a09080891506102088384868a0988098485848c09860386878789038f088a0908848d523d8d015260408c0152565b505050505050505050505050565b6020357fffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc6325513d6040357f7fffffff800000007fffffffffffffffde737d56d38bcf4279dce5617e3192a88111156102695782035b60206108005260206108205260206108405280610860526002830361088052826108a0526ffffffffeffffffffffffffffffffffff60601b198060031860205260603560803560203d60c061080060055afa60203d1416837f5ac635d8aa3a93e7b3ebbd55769886bc651d06b0cc53b0f63bce3c3e27d2604b8585873d5189898a09080908848384091484831085851016888710871510898b108b151016609f3611161616166103195760206080f35b60809182523d820152600160c08190527f6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c2966102009081527f4fe342e2fe1a7f9b8ee7eb4a7c0f9e162bce33576b315ececbb6406837bf51f53d909101526102405261038992509050610100610082565b610397610200610400610082565b6103a7610100608061018061010d565b6103b7610200608061028061010d565b6103c861020061010061030061010d565b6103d961020061018061038061010d565b6103e9610400608061048061010d565b6103fa61040061010061050061010d565b61040b61040061018061058061010d565b61041c61040061020061060061010d565b61042c610600608061068061010d565b61043d61060061010061070061010d565b61044e61060061018061078061010d565b81815182350982825185098283846ffffffffeffffffffffffffffffffffff60601b193d515b82156105245781858609828485098384838809600409848586848509860986878a8b096003090885868384088703878384090886878887880960080988038889848b03870885090887888a8d096002098882830996508881820995508889888509600409945088898a8889098a098a8b86870960030908935088898687088a038a868709089a5088898284096002099950505050858687868709600809870387888b8a0386088409089850505050505b61018086891b60f71c16610600888a1b60f51c16176040810151801585151715610564578061055357506105fe565b81513d8301519750955093506105fe565b83858609848283098581890986878584098b0991508681880388858851090887838903898a8c88093d8a015109089350836105b957806105b9576105a9898c8c610008565b9a509b50995050505050506105fe565b8781820988818309898285099350898a8586088b038b838d038d8a8b0908089b50898a8287098b038b8c8f8e0388088909089c5050508788868b098209985050505050505b5082156106af5781858609828485098384838809600409848586848509860986878a8b096003090885868384088703878384090886878887880960080988038889848b03870885090887888a8d096002098882830996508881820995508889888509600409945088898a8889098a098a8b86870960030908935088898687088a038a868709089a5088898284096002099950505050858687868709600809870387888b8a0386088409089850505050505b61018086891b60f51c16610600888a1b60f31c161760408101518015851517156106ef57806106de5750610789565b81513d830151975095509350610789565b83858609848283098581890986878584098b0991508681880388858851090887838903898a8c88093d8a01510908935083610744578061074457610734898c8c610008565b9a509b5099505050505050610789565b8781820988818309898285099350898a8586088b038b838d038d8a8b0908089b50898a8287098b038b8c8f8e0388088909089c5050508788868b098209985050505050505b50600488019760fb19016104745750816107a2573d6040f35b81610860526002810361088052806108a0523d3d60c061080060055afa898983843d513d510987090614163d525050505050505050503d3df3fea264697066735822122063ce32ec0e56e7893a1f6101795ce2e38aca14dd12adb703c71fe3bee27da71e64736f6c634300081a0033"; - -contract PasskeysTest is AdvTest { - - PasskeysImp public passkeysImp; - - function setUp() public { - passkeysImp = new PasskeysImp(); - } - - // --- _rootForPasskey Tests --- - - // Fuzz test for _rootForPasskey using metadataHash - function test_rootForPasskey_metadataHash( - bool requireUserVerification, - bytes32 x, - bytes32 y, - bytes32 metadataHash - ) public { - bytes32 contractRoot = passkeysImp.rootForPasskeyPub(requireUserVerification, x, y, metadataHash); - - PrimitivesRPC.PasskeyPublicKey memory pkParams; - pkParams.x = x; - pkParams.y = y; - pkParams.requireUserVerification = requireUserVerification; - pkParams.metadataHash = metadataHash; - - bytes32 rpcRoot = PrimitivesRPC.passkeysComputeRoot(vm, pkParams); - - assertEq(contractRoot, rpcRoot, "Contract root hash should match RPC root hash using metadataHash"); - } - - // Fuzz test for _rootForPasskey using credentialId - function test_rootForPasskey_credentialId( - bool requireUserVerification, - bytes32 x, - bytes32 y, - uint256 credentialIdSeed - ) public { - string memory credentialId = generateRandomString(credentialIdSeed); - vm.assume(bytes(credentialId).length > 0); - bytes32 expectedMetadataNodeHash = keccak256(bytes(credentialId)); - bytes32 contractRoot = passkeysImp.rootForPasskeyPub(requireUserVerification, x, y, expectedMetadataNodeHash); - - PrimitivesRPC.PasskeyPublicKey memory pkParams; - pkParams.x = x; - pkParams.y = y; - pkParams.requireUserVerification = requireUserVerification; - pkParams.credentialId = credentialId; - - bytes32 rpcRoot = PrimitivesRPC.passkeysComputeRoot(vm, pkParams); - - assertEq(contractRoot, rpcRoot, "Contract root hash should match RPC root hash using credentialId"); - } - - // Fuzz test for _rootForPasskey without metadata - function test_rootForPasskey_noMetadata(bool requireUserVerification, bytes32 x, bytes32 y) public { - bytes32 noMetadataHash = bytes32(0); - bytes32 contractRoot = passkeysImp.rootForPasskeyPub(requireUserVerification, x, y, noMetadataHash); - - PrimitivesRPC.PasskeyPublicKey memory pkParams; - pkParams.x = x; - pkParams.y = y; - pkParams.requireUserVerification = requireUserVerification; - - bytes32 rpcRoot = PrimitivesRPC.passkeysComputeRoot(vm, pkParams); - - assertEq(contractRoot, rpcRoot, "Contract root hash should match RPC root hash without metadata"); - } - - struct test_decodeSignature_packed_params { - bool requireUserVerification; - bytes32 x; - bytes32 y; - bytes32 r; - bytes32 s; - bytes authenticatorData; - bytes challengeBytes; - bytes32 metadataHash; - bool embedMetadata; - uint256 typeValueSeed; - uint256 originValueSeed; - } - - struct test_decodeSignature_packed_vars { - string clientDataJSON; - uint256 challengeIndex; - uint256 typeIndex; - PrimitivesRPC.PasskeyPublicKey pkParams; - PrimitivesRPC.PasskeySignatureComponents sigParams; - bytes encodedSignature; - WebAuthn.WebAuthnAuth decodedAuth; - bool decodedRUV; - bytes32 decodedX; - bytes32 decodedY; - bytes32 decodedMetadata; - string typeValue; - string originValue; - } - - function test_decodeSignature_packed( - test_decodeSignature_packed_params memory params - ) public { - vm.assume(params.authenticatorData.length > 0 && params.authenticatorData.length <= 65535); - vm.assume(params.challengeBytes.length > 0 && params.challengeBytes.length < 100); - vm.assume(params.r != bytes32(0)); - vm.assume(params.s != bytes32(0)); - - if (params.embedMetadata) { - vm.assume(params.metadataHash != bytes32(0)); - } else { - params.metadataHash = bytes32(0); - } - - test_decodeSignature_packed_vars memory vars; - - string memory base64UrlChallenge = vm.toBase64URL(params.challengeBytes); - - vars.typeValue = generateRandomString(params.typeValueSeed); - vars.originValue = generateRandomString(params.originValueSeed); - - vars.clientDataJSON = string.concat( - '{"type":"', vars.typeValue, '","challenge":"', base64UrlChallenge, '","origin":"', vars.originValue, '"}' - ); - - vars.typeIndex = 1; - vars.challengeIndex = 11 + bytes(vars.typeValue).length; - - vars.pkParams.x = params.x; - vars.pkParams.y = params.y; - vars.pkParams.requireUserVerification = params.requireUserVerification; - if (params.embedMetadata || params.metadataHash != bytes32(0)) { - vars.pkParams.metadataHash = params.metadataHash; - } - - vars.sigParams.r = params.r; - vars.sigParams.s = params.s; - vars.sigParams.authenticatorData = params.authenticatorData; - vars.sigParams.clientDataJson = vars.clientDataJSON; - - vars.encodedSignature = - PrimitivesRPC.passkeysEncodeSignature(vm, vars.pkParams, vars.sigParams, params.embedMetadata); - - (vars.decodedAuth, vars.decodedRUV, vars.decodedX, vars.decodedY, vars.decodedMetadata) = - passkeysImp.decodeSignaturePub(vars.encodedSignature); - - assertEq(vars.decodedRUV, params.requireUserVerification, "Packed Decoded RUV mismatch"); - assertEq(vars.decodedY, params.y, "Packed Decoded Y mismatch"); - assertEq(vars.decodedX, params.x, "Packed Decoded X mismatch"); - assertEq( - keccak256(vars.decodedAuth.authenticatorData), - keccak256(params.authenticatorData), - "Packed Decoded authenticatorData mismatch" - ); - assertEq( - keccak256(bytes(vars.decodedAuth.clientDataJSON)), - keccak256(bytes(vars.clientDataJSON)), - "Packed Decoded clientDataJSON mismatch" - ); - assertEq(vars.decodedAuth.r, params.r, "Packed Decoded R mismatch"); - assertEq(vars.decodedAuth.s, params.s, "Packed Decoded S mismatch"); - assertEq(vars.decodedAuth.challengeIndex, vars.challengeIndex, "Packed Decoded challengeIndex mismatch"); - assertEq(vars.decodedAuth.typeIndex, vars.typeIndex, "Packed Decoded typeIndex mismatch"); - assertEq(vars.decodedMetadata, params.metadataHash, "Packed Decoded metadata mismatch"); - } - - struct test_decodeSignature_abi_params { - bool requireUserVerification; - bytes32 x; - bytes32 y; - bytes32 r; - bytes32 s; - bytes authenticatorData; - bytes challengeBytes; - bytes32 metadataHash; - bool includeMetadata; - uint256 typeValueSeed; - uint256 originValueSeed; - } - - struct test_decodeSignature_abi_vars { - string clientDataJSON; - uint256 challengeIndex; - uint256 typeIndex; - WebAuthn.WebAuthnAuth authInput; - bytes encodedTuple; - bytes1 flagByte; - bytes encodedSignatureWithFlag; - WebAuthn.WebAuthnAuth decodedAuth; - bool decodedRUV; - bytes32 decodedX; - bytes32 decodedY; - bytes32 decodedMetadata; - string typeValue; - string originValue; - } - - // Fuzz test for _decodeSignature using the ABI encoded fallback format - function test_decodeSignature_abi( - test_decodeSignature_abi_params memory params - ) public view { - // --- Setup & Assumptions --- - vm.assume(params.authenticatorData.length > 0 && params.authenticatorData.length <= 65535); - vm.assume(params.challengeBytes.length > 0 && params.challengeBytes.length < 100); - vm.assume(params.r != bytes32(0)); - vm.assume(params.s != bytes32(0)); - - if (params.includeMetadata) { - vm.assume(params.metadataHash != bytes32(0)); - } else { - params.metadataHash = bytes32(0); - } - - test_decodeSignature_abi_vars memory vars; - - string memory base64UrlChallenge = vm.toBase64URL(params.challengeBytes); - vars.typeValue = generateRandomString(params.typeValueSeed); - vars.originValue = generateRandomString(params.originValueSeed); - - vars.clientDataJSON = string.concat( - '{"type":"', vars.typeValue, '","challenge":"', base64UrlChallenge, '","origin":"', vars.originValue, '"}' - ); - vars.challengeIndex = 11 + bytes(vars.typeValue).length; - vars.typeIndex = 1; - - // --- ABI Encoding --- - vars.authInput = WebAuthn.WebAuthnAuth({ - authenticatorData: params.authenticatorData, - clientDataJSON: vars.clientDataJSON, - challengeIndex: vars.challengeIndex, - typeIndex: vars.typeIndex, - r: params.r, - s: params.s - }); - - vars.encodedTuple = - abi.encode(vars.authInput, params.requireUserVerification, params.x, params.y, params.metadataHash); - vars.flagByte = bytes1(uint8(0x20) | (params.includeMetadata ? uint8(0x40) : uint8(0x00))); - vars.encodedSignatureWithFlag = abi.encodePacked(vars.flagByte, vars.encodedTuple); - - // --- Contract Decoding --- - (vars.decodedAuth, vars.decodedRUV, vars.decodedX, vars.decodedY, vars.decodedMetadata) = - passkeysImp.decodeSignaturePub(vars.encodedSignatureWithFlag); - - // --- Assertions --- - assertEq(vars.decodedRUV, params.requireUserVerification, "ABI Decoded RUV mismatch"); - assertEq(vars.decodedX, params.x, "ABI Decoded X mismatch"); - assertEq(vars.decodedY, params.y, "ABI Decoded Y mismatch"); - assertEq( - keccak256(vars.decodedAuth.authenticatorData), - keccak256(params.authenticatorData), - "ABI Decoded authenticatorData mismatch" - ); - assertEq( - keccak256(bytes(vars.decodedAuth.clientDataJSON)), - keccak256(bytes(vars.clientDataJSON)), - "ABI Decoded clientDataJSON mismatch" - ); - assertEq(vars.decodedAuth.r, params.r, "ABI Decoded R mismatch"); - assertEq(vars.decodedAuth.s, params.s, "ABI Decoded S mismatch"); - assertEq(vars.decodedAuth.challengeIndex, vars.challengeIndex, "ABI Decoded challengeIndex mismatch"); - assertEq(vars.decodedAuth.typeIndex, vars.typeIndex, "ABI Decoded typeIndex mismatch"); - assertEq(vars.decodedMetadata, params.metadataHash, "ABI Decoded metadata mismatch"); - } - - struct RecoverParams { - uint256 pkSeed; - bytes32 digest; - bool requireUserVerification; - bytes32 metadataHash; - bool embedMetadata; - uint256 originValueSeed; - bytes32 rpIdHash; - uint32 signCount; - } - - struct recoverSapientSignatureCompact_valid_vars { - Vm.Wallet wallet; - uint256 pubX; - uint256 pubY; - PrimitivesRPC.PasskeyPublicKey pkParams; - string base64UrlChallenge; - string typeValue; - string originValue; - string clientDataJSON; - PrimitivesRPC.PasskeySignatureComponents sigParams; - bytes32 clientDataJSONHash; - bytes32 messageHash; - bytes encodedSignature; - bytes32 expectedRoot; - bytes32 recoveredRoot; - bytes generatedAuthenticatorData; - } - - function test_recoverSapientSignatureCompact_valid( - RecoverParams memory params - ) public { - vm.etch(P256_VERIFIER, P256_VERIFIER_RUNTIME_CODE); - - recoverSapientSignatureCompact_valid_vars memory vars; - - params.pkSeed = boundP256Pk(params.pkSeed); - vars.wallet = vm.createWallet(params.pkSeed); - - if (params.embedMetadata) { - vm.assume(params.metadataHash != bytes32(0)); - } else { - params.metadataHash = bytes32(0); - } - - (vars.pubX, vars.pubY) = vm.publicKeyP256(vars.wallet.privateKey); - vars.pkParams.x = bytes32(vars.pubX); - vars.pkParams.y = bytes32(vars.pubY); - vars.pkParams.requireUserVerification = params.requireUserVerification; - vars.pkParams.metadataHash = params.metadataHash; - vars.pkParams.credentialId = ""; - - uint8 flags = 0x01; - if (params.requireUserVerification) { - flags |= 0x04; - } - - vars.generatedAuthenticatorData = abi.encodePacked(params.rpIdHash, flags, params.signCount); - - string memory raw = vm.toBase64URL(abi.encodePacked(params.digest)); - if (bytes(raw)[bytes(raw).length - 1] == "=") { - assembly { - mstore(raw, sub(mload(raw), 1)) - } - } - vars.base64UrlChallenge = raw; - vars.typeValue = "webauthn.get"; - vars.originValue = generateRandomString(params.originValueSeed); - vm.assume(bytes(vars.originValue).length > 0); - - vars.clientDataJSON = string.concat( - '{"type":"', vars.typeValue, '","challenge":"', vars.base64UrlChallenge, '","origin":"', vars.originValue, '"}' - ); - vars.sigParams.clientDataJson = vars.clientDataJSON; - vars.sigParams.authenticatorData = vars.generatedAuthenticatorData; - - vars.clientDataJSONHash = sha256(bytes(vars.clientDataJSON)); - vars.messageHash = sha256(abi.encodePacked(vars.generatedAuthenticatorData, vars.clientDataJSONHash)); - (bytes32 rVal, bytes32 sVal) = vm.signP256(vars.wallet.privateKey, vars.messageHash); - - bytes32 halfN = bytes32(0x7fffffff800000007fffffffffffffffde737d56d38bcf4279dce5617e3192a8); - if (sVal > halfN) { - sVal = bytes32(0xffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551 - uint256(sVal)); - } - - vars.sigParams.r = bytes32(rVal); - vars.sigParams.s = bytes32(sVal); - vars.encodedSignature = - PrimitivesRPC.passkeysEncodeSignature(vm, vars.pkParams, vars.sigParams, params.embedMetadata); - - vars.expectedRoot = PrimitivesRPC.passkeysComputeRoot(vm, vars.pkParams); - - vars.recoveredRoot = passkeysImp.recoverSapientSignatureCompact(params.digest, vars.encodedSignature); - assertEq(vars.recoveredRoot, vars.expectedRoot, "Recovered root should match expected root"); - } - - struct recoverSapientSignatureCompact_invalidSignature_vars { - Vm.Wallet wallet; - Vm.Wallet wrongWallet; - uint256 pubX; - uint256 pubY; - PrimitivesRPC.PasskeyPublicKey pkParams; - string base64UrlChallenge; - string typeValue; - string originValue; - string clientDataJSON; - PrimitivesRPC.PasskeySignatureComponents sigParams; - bytes32 clientDataJSONHash; - bytes32 messageHash; - bytes encodedSignature; - uint256 challengeIndex; - uint256 typeIndex; - WebAuthn.WebAuthnAuth expectedAuthStruct; - bytes generatedAuthenticatorData; - } - - function test_recoverSapientSignatureCompact_invalidSignature(RecoverParams memory params, uint256 wrongSeed) public { - vm.etch(P256_VERIFIER, P256_VERIFIER_RUNTIME_CODE); - - recoverSapientSignatureCompact_invalidSignature_vars memory vars; - - params.pkSeed = boundP256Pk(params.pkSeed); - wrongSeed = boundP256Pk(wrongSeed); - vm.assume(wrongSeed != params.pkSeed); - - vars.wallet = vm.createWallet(params.pkSeed); - vars.wrongWallet = vm.createWallet(wrongSeed); - - if (params.embedMetadata) { - vm.assume(params.metadataHash != bytes32(0)); - } else { - params.metadataHash = bytes32(0); - } - - (vars.pubX, vars.pubY) = vm.publicKeyP256(vars.wallet.privateKey); - vars.pkParams.x = bytes32(vars.pubX); - vars.pkParams.y = bytes32(vars.pubY); - vars.pkParams.requireUserVerification = params.requireUserVerification; - vars.pkParams.metadataHash = params.metadataHash; - vars.pkParams.credentialId = ""; - - uint8 flags = 0x01; - if (params.requireUserVerification) { - flags |= 0x04; - } - vars.generatedAuthenticatorData = abi.encodePacked(params.rpIdHash, flags, params.signCount); - - string memory raw = vm.toBase64URL(abi.encodePacked(params.digest)); - if (bytes(raw)[bytes(raw).length - 1] == "=") { - assembly { - mstore(raw, sub(mload(raw), 1)) - } - } - vars.base64UrlChallenge = raw; - vars.typeValue = "webauthn.get"; - vars.originValue = generateRandomString(params.originValueSeed); - vm.assume(bytes(vars.originValue).length > 0); - - vars.clientDataJSON = string.concat( - '{"type":"', vars.typeValue, '","challenge":"', vars.base64UrlChallenge, '","origin":"', vars.originValue, '"}' - ); - vars.sigParams.clientDataJson = vars.clientDataJSON; - vars.sigParams.authenticatorData = vars.generatedAuthenticatorData; - - vars.clientDataJSONHash = sha256(bytes(vars.clientDataJSON)); - vars.messageHash = sha256(abi.encodePacked(vars.generatedAuthenticatorData, vars.clientDataJSONHash)); - (vars.sigParams.r, vars.sigParams.s) = vm.signP256(vars.wrongWallet.privateKey, vars.messageHash); - - vars.encodedSignature = - PrimitivesRPC.passkeysEncodeSignature(vm, vars.pkParams, vars.sigParams, params.embedMetadata); - - vars.challengeIndex = LibString.indexOf(vars.clientDataJSON, '"challenge":"'); - vars.typeIndex = LibString.indexOf(vars.clientDataJSON, '"type":"'); - - vars.expectedAuthStruct = WebAuthn.WebAuthnAuth({ - authenticatorData: vars.generatedAuthenticatorData, - clientDataJSON: vars.clientDataJSON, - challengeIndex: vars.challengeIndex, - typeIndex: vars.typeIndex, - r: vars.sigParams.r, - s: vars.sigParams.s - }); - - vm.expectRevert( - abi.encodeWithSelector( - Passkeys.InvalidPasskeySignature.selector, - vars.expectedAuthStruct, - params.requireUserVerification, - vars.pkParams.x, - vars.pkParams.y - ) - ); - passkeysImp.recoverSapientSignatureCompact(params.digest, vars.encodedSignature); - } - - function boundP256Pk( - uint256 _a - ) internal pure returns (uint256) { - _a = bound(_a, 1, 0xffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632550); - return _a; - } - -} - -library LibString { - - function indexOf(string memory haystack, string memory needle) internal pure returns (uint256) { - bytes memory h = bytes(haystack); - bytes memory n = bytes(needle); - if (n.length == 0) { - return 0; - } - if (n.length > h.length) { - return type(uint256).max; - } - - for (uint256 i = 0; i <= h.length - n.length; i++) { - bool m = true; - for (uint256 j = 0; j < n.length; j++) { - if (h[i + j] != n[j]) { - m = false; - break; - } - } - if (m) { - return i; - } - } - return type(uint256).max; - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/recovery/Recovery.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/recovery/Recovery.t.sol deleted file mode 100644 index 77037dfb99..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/recovery/Recovery.t.sol +++ /dev/null @@ -1,595 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Recovery } from "../../../src/extensions/recovery/Recovery.sol"; - -import { Payload } from "../../../src/modules/Payload.sol"; -import { IERC1271 } from "../../../src/modules/interfaces/IERC1271.sol"; -import { PrimitivesRPC } from "../../utils/PrimitivesRPC.sol"; -import { AdvTest } from "../../utils/TestUtils.sol"; -import { console } from "forge-std/console.sol"; - -contract RecoveryImp is Recovery { - - function recoverBranch( - address _wallet, - bytes32 _payloadHash, - bytes calldata _signature - ) external view returns (bool verified, bytes32 root) { - return _recoverBranch(_wallet, _payloadHash, _signature); - } - -} - -contract RecoveryTest is AdvTest { - - RecoveryImp public recovery; - - function setUp() public { - recovery = new RecoveryImp(); - } - - struct Signer { - address signer; - uint24 requiredDeltaTime; - uint64 minTimestamp; - } - - function test_recoverBranch(Signer[] calldata signers, address wallet, bytes32 payloadHash) public { - vm.assume(signers.length > 0); - - string memory leaves; - - for (uint256 i = 0; i < signers.length; i++) { - if (i > 0) { - leaves = string.concat(leaves, " "); - } - leaves = string.concat( - leaves, - "signer:", - vm.toString(signers[i].signer), - ":", - vm.toString(signers[i].requiredDeltaTime), - ":", - vm.toString(signers[i].minTimestamp) - ); - } - - bytes32 rpcRoot = PrimitivesRPC.recoveryHashFromLeaves(vm, leaves); - vm.assume(rpcRoot != bytes32(0)); - - bytes memory encoded = PrimitivesRPC.recoveryEncode(vm, leaves); - bytes32 rpcRootEncoded = PrimitivesRPC.recoveryHashEncoded(vm, encoded); - assertEq(rpcRoot, rpcRootEncoded); - - (bool verified, bytes32 root) = recovery.recoverBranch(wallet, payloadHash, encoded); - assertEq(verified, false); - assertEq(root, rpcRoot); - } - - function test_queue_payload( - uint256 _signerPk, - address _wallet, - Payload.Decoded memory _payload, - uint64 _randomTime - ) external { - boundToLegalPayload(_payload); - - vm.warp(_randomTime); - - _signerPk = boundPk(_signerPk); - bytes32 recoveryPayloadHash = recovery.recoveryPayloadHash(_wallet, _payload); - bytes32 payloadHash = Payload.hashFor(_payload, _wallet); - (uint8 v, bytes32 r, bytes32 s) = vm.sign(_signerPk, recoveryPayloadHash); - - bytes32 yParityAndS = bytes32((uint256(v - 27) << 255) | uint256(s)); - bytes memory signature = abi.encodePacked(r, yParityAndS); - - address signerAddr = vm.addr(_signerPk); - - vm.expectEmit(true, true, true, true, address(recovery)); - emit Recovery.NewQueuedPayload(_wallet, signerAddr, payloadHash, block.timestamp); - recovery.queuePayload(_wallet, signerAddr, _payload, signature); - - assertEq(recovery.totalQueuedPayloads(_wallet, signerAddr), 1); - assertEq(recovery.queuedPayloadHashes(_wallet, signerAddr, 0), payloadHash); - assertEq(recovery.timestampForQueuedPayload(_wallet, signerAddr, payloadHash), block.timestamp); - } - - function test_queue_payload_ecdsa_with_code( - uint256 _signerPk, - address _wallet, - Payload.Decoded memory _payload, - uint64 _randomTime, - bytes memory _randomCode - ) external { - _randomCode = abi.encodePacked(bytes1(0x00), _randomCode); - boundToLegalPayload(_payload); - - vm.warp(_randomTime); - - _signerPk = boundPk(_signerPk); - bytes32 recoveryPayloadHash = recovery.recoveryPayloadHash(_wallet, _payload); - bytes32 payloadHash = Payload.hashFor(_payload, _wallet); - (uint8 v, bytes32 r, bytes32 s) = vm.sign(_signerPk, recoveryPayloadHash); - - bytes32 yParityAndS = bytes32((uint256(v - 27) << 255) | uint256(s)); - bytes memory signature = abi.encodePacked(r, yParityAndS); - - address signerAddr = vm.addr(_signerPk); - vm.etch(signerAddr, _randomCode); - - vm.expectEmit(true, true, true, true, address(recovery)); - emit Recovery.NewQueuedPayload(_wallet, signerAddr, payloadHash, block.timestamp); - recovery.queuePayload(_wallet, signerAddr, _payload, signature); - - assertEq(recovery.totalQueuedPayloads(_wallet, signerAddr), 1); - assertEq(recovery.queuedPayloadHashes(_wallet, signerAddr, 0), payloadHash); - assertEq(recovery.timestampForQueuedPayload(_wallet, signerAddr, payloadHash), block.timestamp); - } - - function test_queue_payload_invalid_signature_fail_no_code( - uint256 _signerPk, - address _wallet, - Payload.Decoded memory _payload, - uint64 _randomTime, - address _wrongSigner - ) external { - assumeNotPrecompile(_wrongSigner); - vm.assume(_wrongSigner.code.length == 0); - - boundToLegalPayload(_payload); - _signerPk = boundPk(_signerPk); - - address signerAddr = vm.addr(_signerPk); - vm.assume(signerAddr != _wrongSigner); - vm.label(signerAddr, "signer"); - vm.label(_wrongSigner, "wrongSigner"); - - vm.warp(_randomTime); - - bytes32 recoveryPayloadHash = recovery.recoveryPayloadHash(_wallet, _payload); - (uint8 v, bytes32 r, bytes32 s) = vm.sign(_signerPk, recoveryPayloadHash); - - bytes32 yParityAndS = bytes32((uint256(v - 27) << 255) | uint256(s)); - bytes memory signature = abi.encodePacked(r, yParityAndS); - - vm.expectRevert( - abi.encodeWithSelector(Recovery.InvalidSignature.selector, _wallet, _wrongSigner, _payload, signature) - ); - recovery.queuePayload(_wallet, _wrongSigner, _payload, signature); - } - - function test_queue_payload_invalid_signature_fail_has_code( - uint256 _signerPk, - address _wallet, - Payload.Decoded memory _payload, - uint64 _randomTime, - address _wrongSigner, - bytes memory _randomCode - ) external { - _wrongSigner = boundNoPrecompile(_wrongSigner); - assumeNotPrecompile2(_wrongSigner); - // Ensure there is code without 0xef prefix - _randomCode = abi.encodePacked(bytes1(0x00), _randomCode); - - vm.etch(_wrongSigner, _randomCode); - - boundToLegalPayload(_payload); - _signerPk = boundPk(_signerPk); - - { - address signerAddr = vm.addr(_signerPk); - vm.assume(signerAddr != _wrongSigner); - vm.label(signerAddr, "signer"); - vm.label(_wrongSigner, "wrongSigner"); - } - - vm.warp(_randomTime); - - bytes memory signature; - { - bytes32 recoveryPayloadHash = recovery.recoveryPayloadHash(_wallet, _payload); - (uint8 v, bytes32 r, bytes32 s) = vm.sign(_signerPk, recoveryPayloadHash); - - bytes32 yParityAndS = bytes32((uint256(v - 27) << 255) | uint256(s)); - signature = abi.encodePacked(r, yParityAndS); - - vm.mockCall( - _wrongSigner, - abi.encodeWithSelector(IERC1271.isValidSignature.selector, recoveryPayloadHash, signature), - abi.encode(bytes4(0x00000000)) - ); - } - - vm.expectRevert( - abi.encodeWithSelector(Recovery.InvalidSignature.selector, _wallet, _wrongSigner, _payload, signature) - ); - recovery.queuePayload(_wallet, _wrongSigner, _payload, signature); - } - - function test_queue_payload_already_queued_fail( - uint256 _signerPk, - address _wallet, - Payload.Decoded memory _payload, - uint256 _randomTime, - uint256 _waitBetweenQueues - ) external { - boundToLegalPayload(_payload); - _signerPk = boundPk(_signerPk); - - _randomTime = bound(_randomTime, 1, type(uint64).max); - _waitBetweenQueues = bound(_waitBetweenQueues, 0, type(uint64).max - _randomTime); - - address signerAddr = vm.addr(_signerPk); - vm.warp(_randomTime); - - _signerPk = boundPk(_signerPk); - bytes32 recoveryPayloadHash = recovery.recoveryPayloadHash(_wallet, _payload); - bytes32 payloadHash = Payload.hashFor(_payload, _wallet); - (uint8 v, bytes32 r, bytes32 s) = vm.sign(_signerPk, recoveryPayloadHash); - - bytes32 yParityAndS = bytes32((uint256(v - 27) << 255) | uint256(s)); - bytes memory signature = abi.encodePacked(r, yParityAndS); - - recovery.queuePayload(_wallet, signerAddr, _payload, signature); - vm.warp(block.timestamp + _waitBetweenQueues); - - vm.expectRevert(abi.encodeWithSelector(Recovery.AlreadyQueued.selector, _wallet, signerAddr, payloadHash)); - recovery.queuePayload(_wallet, signerAddr, _payload, signature); - } - - function test_queue_payload_erc1271( - address _signer, - bytes calldata _signature, - address _wallet, - Payload.Decoded memory _payload, - uint64 _randomTime, - bytes memory _signerCode - ) external { - boundToLegalPayload(_payload); - _signer = boundNoPrecompile(_signer); - assumeNotPrecompile2(_signer); - - _signerCode = abi.encodePacked(bytes1(0x00), _signerCode); - vm.warp(_randomTime); - - bytes32 payloadHash = Payload.hashFor(_payload, _wallet); - bytes32 recoveryPayloadHash = recovery.recoveryPayloadHash(_wallet, _payload); - - vm.mockCall( - _signer, - abi.encodeWithSelector(IERC1271.isValidSignature.selector, recoveryPayloadHash, _signature), - abi.encode(bytes4(0x1626ba7e)) - ); - vm.etch(_signer, _signerCode); - - vm.expectEmit(true, true, true, true, address(recovery)); - emit Recovery.NewQueuedPayload(_wallet, _signer, payloadHash, block.timestamp); - recovery.queuePayload(_wallet, _signer, _payload, _signature); - - assertEq(recovery.totalQueuedPayloads(_wallet, _signer), 1); - assertEq(recovery.queuedPayloadHashes(_wallet, _signer, 0), payloadHash); - assertEq(recovery.timestampForQueuedPayload(_wallet, _signer, payloadHash), block.timestamp); - } - - function test_queue_payload_erc1271_invalid_signature_fail( - address _signer, - bytes calldata _signature, - address _wallet, - Payload.Decoded memory _payload, - uint64 _randomTime, - bytes memory _signerCode, - bytes4 _badMagicValue - ) external { - boundToLegalPayload(_payload); - _signer = boundNoPrecompile(_signer); - assumeNotPrecompile2(_signer); - - _signerCode = abi.encodePacked(bytes1(0x00), _signerCode); - vm.warp(_randomTime); - if (_badMagicValue == bytes4(0x1626ba7e)) { - _badMagicValue = bytes4(0); - } - - bytes32 recoveryPayloadHash = recovery.recoveryPayloadHash(_wallet, _payload); - - vm.mockCall( - _signer, - abi.encodeWithSelector(IERC1271.isValidSignature.selector, recoveryPayloadHash, _signature), - abi.encode(_badMagicValue) - ); - vm.etch(_signer, _signerCode); - - vm.expectRevert(abi.encodeWithSelector(Recovery.InvalidSignature.selector, _wallet, _signer, _payload, _signature)); - recovery.queuePayload(_wallet, _signer, _payload, _signature); - } - - function test_queue_payload_erc1271_revert_fail( - address _signer, - bytes calldata _signature, - address _wallet, - Payload.Decoded memory _payload, - uint64 _randomTime, - bytes memory _signerCode, - bytes calldata _revertData - ) external { - boundToLegalPayload(_payload); - _signer = boundNoPrecompile(_signer); - assumeNotPrecompile2(_signer); - - _signerCode = abi.encodePacked(bytes1(0x00), _signerCode); - vm.warp(_randomTime); - - bytes32 recoveryPayloadHash = recovery.recoveryPayloadHash(_wallet, _payload); - - vm.mockCallRevert( - _signer, abi.encodeWithSelector(IERC1271.isValidSignature.selector, recoveryPayloadHash, _signature), _revertData - ); - vm.etch(_signer, _signerCode); - - vm.expectRevert(_revertData); - recovery.queuePayload(_wallet, _signer, _payload, _signature); - } - - struct other_leaf { - address signer; - uint24 requiredDeltaTime; - uint64 minTimestamp; - } - - struct test_recover_sapient_signature_compact_params { - uint256 signerPk; - address wallet; - Payload.Decoded payload; - uint256 startTime; - uint256 passedTime; - uint256 minTimestamp; - uint256 requiredDeltaTime; - other_leaf[] suffixes; - other_leaf[] prefixes; - } - - struct test_recover_sapient_signature_compact_vars { - bytes32 recoveryPayloadHash; - bytes32 payloadHash; - uint8 v; - bytes32 r; - bytes32 s; - bytes32 yParityAndS; - bytes signature; - address signerAddr; - string parts; - bytes32 rpcRoot; - bytes encoded; - bytes32 recoveredRoot; - } - - function test_recover_sapient_signature_compact( - test_recover_sapient_signature_compact_params memory params - ) external { - boundToLegalPayload(params.payload); - params.startTime = bound(params.startTime, 1, type(uint64).max / 2); // Safer upper bound perhaps - params.requiredDeltaTime = bound(params.requiredDeltaTime, 0, type(uint24).max); - params.minTimestamp = bound(params.minTimestamp, 0, params.startTime); - uint256 minPassedTime = params.requiredDeltaTime == type(uint64).max ? type(uint64).max : params.requiredDeltaTime; - - params.passedTime = bound(params.passedTime, minPassedTime, type(uint64).max); - vm.warp(params.startTime); - - params.signerPk = boundPk(params.signerPk); - - test_recover_sapient_signature_compact_vars memory vars; - vars.recoveryPayloadHash = recovery.recoveryPayloadHash(params.wallet, params.payload); - vars.payloadHash = Payload.hashFor(params.payload, params.wallet); - (vars.v, vars.r, vars.s) = vm.sign(params.signerPk, vars.recoveryPayloadHash); - - vars.yParityAndS = bytes32((uint256(vars.v - 27) << 255) | uint256(vars.s)); - vars.signature = abi.encodePacked(vars.r, vars.yParityAndS); - - vars.signerAddr = vm.addr(params.signerPk); - - recovery.queuePayload(params.wallet, vars.signerAddr, params.payload, vars.signature); - - vm.warp(block.timestamp + params.passedTime); - - vars.parts = ""; - for (uint256 i = 0; i < params.suffixes.length; i++) { - vars.parts = string.concat( - vars.parts, - "signer:", - vm.toString(params.suffixes[i].signer), - ":", - vm.toString(params.suffixes[i].requiredDeltaTime), - ":", - vm.toString(params.suffixes[i].minTimestamp), - " " - ); - } - - vars.parts = string.concat( - vars.parts, - "signer:", - vm.toString(vars.signerAddr), - ":", - vm.toString(params.requiredDeltaTime), - ":", - vm.toString(params.minTimestamp) - ); - - for (uint256 i = 0; i < params.prefixes.length; i++) { - vars.parts = string.concat( - vars.parts, - " signer:", - vm.toString(params.prefixes[i].signer), - ":", - vm.toString(params.prefixes[i].requiredDeltaTime), - ":", - vm.toString(params.prefixes[i].minTimestamp) - ); - } - - vars.rpcRoot = PrimitivesRPC.recoveryHashFromLeaves(vm, vars.parts); - - vars.encoded = PrimitivesRPC.recoveryTrim(vm, vars.parts, vars.signerAddr); - vm.prank(params.wallet); - vars.recoveredRoot = recovery.recoverSapientSignatureCompact(vars.payloadHash, vars.encoded); - assertEq(vars.recoveredRoot, vars.rpcRoot); - } - - function test_recover_sapient_signature_compact_fail_minTimestamp( - test_recover_sapient_signature_compact_params memory params - ) external { - boundToLegalPayload(params.payload); - params.startTime = uint64(bound(params.startTime, 1, type(uint64).max - 1000)); - params.minTimestamp = uint64(bound(params.minTimestamp, params.startTime + 1, type(uint64).max)); - params.requiredDeltaTime = uint24(bound(params.requiredDeltaTime, 0, type(uint24).max)); - params.passedTime = uint64(bound(params.passedTime, 0, type(uint64).max - params.startTime)); - - vm.warp(params.startTime); - - params.signerPk = boundPk(params.signerPk); - - test_recover_sapient_signature_compact_vars memory vars; - vars.recoveryPayloadHash = recovery.recoveryPayloadHash(params.wallet, params.payload); - vars.payloadHash = Payload.hashFor(params.payload, params.wallet); - (vars.v, vars.r, vars.s) = vm.sign(params.signerPk, vars.recoveryPayloadHash); - - vars.yParityAndS = bytes32((uint256(vars.v - 27) << 255) | uint256(vars.s)); - vars.signature = abi.encodePacked(vars.r, vars.yParityAndS); - - vars.signerAddr = vm.addr(params.signerPk); - - recovery.queuePayload(params.wallet, vars.signerAddr, params.payload, vars.signature); - assertEq(recovery.timestampForQueuedPayload(params.wallet, vars.signerAddr, vars.payloadHash), params.startTime); - - vm.warp(params.startTime + params.passedTime); - - vars.parts = ""; - for (uint256 i = 0; i < params.suffixes.length; i++) { - vars.parts = string.concat( - vars.parts, - "signer:", - vm.toString(params.suffixes[i].signer), - ":", - vm.toString(params.suffixes[i].requiredDeltaTime), - ":", - vm.toString(params.suffixes[i].minTimestamp), - " " - ); - } - vars.parts = string.concat( - vars.parts, - "signer:", - vm.toString(vars.signerAddr), - ":", - vm.toString(params.requiredDeltaTime), - ":", - vm.toString(params.minTimestamp) - ); - for (uint256 i = 0; i < params.prefixes.length; i++) { - vars.parts = string.concat( - vars.parts, - " signer:", - vm.toString(params.prefixes[i].signer), - ":", - vm.toString(params.prefixes[i].requiredDeltaTime), - ":", - vm.toString(params.prefixes[i].minTimestamp) - ); - } - vars.encoded = PrimitivesRPC.recoveryTrim(vm, vars.parts, vars.signerAddr); - - vm.prank(params.wallet); - vm.expectRevert(abi.encodeWithSelector(Recovery.QueueNotReady.selector, params.wallet, vars.payloadHash)); - recovery.recoverSapientSignatureCompact(vars.payloadHash, vars.encoded); - } - - function test_recover_sapient_signature_compact_fail_deltaTime( - test_recover_sapient_signature_compact_params memory params - ) external { - boundToLegalPayload(params.payload); - params.startTime = uint64(bound(params.startTime, 1, type(uint64).max - type(uint24).max - 1)); - params.minTimestamp = uint64(bound(params.minTimestamp, 0, params.startTime)); - params.requiredDeltaTime = uint24(bound(params.requiredDeltaTime, 1, type(uint24).max)); - params.passedTime = uint64(bound(params.passedTime, 0, params.requiredDeltaTime - 1)); - - vm.warp(params.startTime); - - params.signerPk = boundPk(params.signerPk); - - test_recover_sapient_signature_compact_vars memory vars; - vars.recoveryPayloadHash = recovery.recoveryPayloadHash(params.wallet, params.payload); - vars.payloadHash = Payload.hashFor(params.payload, params.wallet); - (vars.v, vars.r, vars.s) = vm.sign(params.signerPk, vars.recoveryPayloadHash); - - vars.yParityAndS = bytes32((uint256(vars.v - 27) << 255) | uint256(vars.s)); - vars.signature = abi.encodePacked(vars.r, vars.yParityAndS); - - vars.signerAddr = vm.addr(params.signerPk); - - recovery.queuePayload(params.wallet, vars.signerAddr, params.payload, vars.signature); - assertEq(recovery.timestampForQueuedPayload(params.wallet, vars.signerAddr, vars.payloadHash), params.startTime); - - vm.warp(params.startTime + params.passedTime); - - vars.parts = ""; - for (uint256 i = 0; i < params.suffixes.length; i++) { - vars.parts = string.concat( - vars.parts, - "signer:", - vm.toString(params.suffixes[i].signer), - ":", - vm.toString(params.suffixes[i].requiredDeltaTime), - ":", - vm.toString(params.suffixes[i].minTimestamp), - " " - ); - } - vars.parts = string.concat( - vars.parts, - "signer:", - vm.toString(vars.signerAddr), - ":", - vm.toString(params.requiredDeltaTime), - ":", - vm.toString(params.minTimestamp) - ); - for (uint256 i = 0; i < params.prefixes.length; i++) { - vars.parts = string.concat( - vars.parts, - " signer:", - vm.toString(params.prefixes[i].signer), - ":", - vm.toString(params.prefixes[i].requiredDeltaTime), - ":", - vm.toString(params.prefixes[i].minTimestamp) - ); - } - vars.encoded = PrimitivesRPC.recoveryTrim(vm, vars.parts, vars.signerAddr); - - vm.prank(params.wallet); - vm.expectRevert(abi.encodeWithSelector(Recovery.QueueNotReady.selector, params.wallet, vars.payloadHash)); - recovery.recoverSapientSignatureCompact(vars.payloadHash, vars.encoded); - } - - function test_recover_fail_invalid_signature_flag( - address _wallet, - bytes32 _payloadHash, - uint8 _invalidSignatureFlag, - bytes calldata _suffix - ) external { - if ( - _invalidSignatureFlag == 1 // Recovery.FLAG_RECOVERY_LEAF - || _invalidSignatureFlag == 3 // Recovery.FLAG_NODE - || _invalidSignatureFlag == 4 // Recovery.FLAG_BRANCH - ) { - _invalidSignatureFlag = uint8(0); - } - - vm.prank(_wallet); - vm.expectRevert(abi.encodeWithSelector(Recovery.InvalidSignatureFlag.selector, _invalidSignatureFlag)); - recovery.recoverSapientSignatureCompact(_payloadHash, abi.encodePacked(_invalidSignatureFlag, _suffix)); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/Attestation.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/Attestation.t.sol deleted file mode 100644 index 1ff90a83c9..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/Attestation.t.sol +++ /dev/null @@ -1,51 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Attestation, LibAttestation } from "src/extensions/sessions/implicit/Attestation.sol"; - -import { AdvTest } from "../../utils/TestUtils.sol"; -import { Vm } from "forge-std/Test.sol"; - -contract AttestationImp { - - function toPacked( - Attestation memory attestation - ) external pure returns (bytes memory encoded) { - return LibAttestation.toPacked(attestation); - } - - function fromPacked( - bytes calldata encoded, - uint256 pointer - ) external pure returns (Attestation memory attestation, uint256 newPointer) { - return LibAttestation.fromPacked(encoded, pointer); - } - -} - -contract AttestationTest is AdvTest { - - AttestationImp public attestationImp; - - function setUp() public { - attestationImp = new AttestationImp(); - } - - function test_packAndUnpackAttestation( - Attestation memory attestation - ) external view { - bytes memory packed = attestationImp.toPacked(attestation); - (Attestation memory unpacked, uint256 pointer) = attestationImp.fromPacked(packed, 0); - - assertEq(pointer, packed.length, "pointer"); - - assertEq(attestation.approvedSigner, unpacked.approvedSigner, "approvedSigner"); - assertEq(attestation.identityType, unpacked.identityType, "identityType"); - assertEq(attestation.issuerHash, unpacked.issuerHash, "issuerHash"); - assertEq(attestation.audienceHash, unpacked.audienceHash, "audienceHash"); - assertEq(attestation.applicationData, unpacked.applicationData, "applicationData"); - assertEq(attestation.authData.redirectUrl, unpacked.authData.redirectUrl, "authData.redirectUrl"); - assertEq(attestation.authData.issuedAt, unpacked.authData.issuedAt, "authData.issuedAt"); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/Permission.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/Permission.t.sol deleted file mode 100644 index 6dd40dc71c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/Permission.t.sol +++ /dev/null @@ -1,157 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Test } from "forge-std/Test.sol"; - -import { - LibPermission, ParameterOperation, ParameterRule, Permission -} from "src/extensions/sessions/explicit/Permission.sol"; - -contract LibPermissionHarness { - - function readPermission(bytes calldata encoded, uint256 pointer) public pure returns (Permission memory, uint256) { - return LibPermission.readPermission(encoded, pointer); - } - - function toPacked( - Permission calldata permission - ) public pure returns (bytes memory) { - return LibPermission.toPacked(permission); - } - -} - -contract PermissionTest is Test { - - LibPermissionHarness harness; - - function setUp() public { - harness = new LibPermissionHarness(); - } - - // Forge can't handle inputting enums so we declare the structs here - struct PermissionTestInput { - address target; - ParameterRuleTestInput[] rules; - } - - struct ParameterRuleTestInput { - bool cumulative; - uint8 operation; - bytes32 value; - uint256 offset; - bytes32 mask; - } - - function test_fail_packRulesLengthExceedsMax( - PermissionTestInput memory input - ) public { - vm.assume(input.rules.length > 0); - Permission memory permission = _toPermission(input); - uint256 maxRulesLength = type(uint8).max; - if (permission.rules.length <= maxRulesLength) { - ParameterRule[] memory rules = new ParameterRule[](maxRulesLength + 1); - for (uint256 i = 0; i < permission.rules.length; i++) { - rules[i] = permission.rules[i]; - } - // Add more rules - for (uint256 i = permission.rules.length; i < maxRulesLength + 1; i++) { - rules[i] = permission.rules[i % permission.rules.length]; - } - permission.rules = rules; - } - vm.expectRevert(LibPermission.RulesLengthExceedsMax.selector); - harness.toPacked(permission); - } - - function test_packAndRead( - PermissionTestInput memory input - ) public view { - Permission memory permission = _toPermission(input); - uint256 maxRulesLength = type(uint8).max; - if (permission.rules.length > maxRulesLength) { - ParameterRule[] memory rules = permission.rules; - uint256 rulesLength = bound(rules.length, 0, maxRulesLength); // Re randomize length - assembly { - mstore(rules, rulesLength) - } - permission.rules = rules; - } - - bytes memory encoded = harness.toPacked(permission); - Permission memory decoded; - uint256 pointer; - (decoded, pointer) = harness.readPermission(encoded, pointer); - assertEq(pointer, encoded.length); - assertEq(decoded.target, permission.target); - assertEq(decoded.rules.length, permission.rules.length); - for (uint256 i = 0; i < permission.rules.length; i++) { - assertEq(decoded.rules[i].cumulative, permission.rules[i].cumulative); - assertEq(uint8(decoded.rules[i].operation), uint8(permission.rules[i].operation)); - assertEq(decoded.rules[i].value, permission.rules[i].value); - assertEq(decoded.rules[i].offset, permission.rules[i].offset); - assertEq(decoded.rules[i].mask, permission.rules[i].mask); - } - } - - function test_packAndReadAtPointer( - PermissionTestInput memory input, - bytes memory prepend, - bytes memory append - ) public view { - Permission memory permission = _toPermission(input); - uint256 maxRulesLength = type(uint8).max; - if (permission.rules.length > maxRulesLength) { - ParameterRule[] memory rules = permission.rules; - uint256 rulesLength = bound(rules.length, 0, maxRulesLength); // Re randomize length - assembly { - mstore(rules, rulesLength) - } - permission.rules = rules; - } - - bytes memory encoded = harness.toPacked(permission); - bytes memory encodedSurrounded = abi.encodePacked(prepend, encoded, append); - Permission memory decoded; - uint256 pointer = prepend.length; - (decoded, pointer) = harness.readPermission(encodedSurrounded, pointer); - assertEq(pointer, prepend.length + encoded.length); - assertEq(decoded.target, permission.target); - assertEq(decoded.rules.length, permission.rules.length); - for (uint256 i = 0; i < permission.rules.length; i++) { - assertEq(decoded.rules[i].cumulative, permission.rules[i].cumulative); - assertEq(uint8(decoded.rules[i].operation), uint8(permission.rules[i].operation)); - assertEq(decoded.rules[i].value, permission.rules[i].value); - assertEq(decoded.rules[i].offset, permission.rules[i].offset); - assertEq(decoded.rules[i].mask, permission.rules[i].mask); - } - } - - function _toPermission( - PermissionTestInput memory input - ) internal pure returns (Permission memory) { - ParameterRule[] memory rules = new ParameterRule[](input.rules.length); - for (uint256 i = 0; i < input.rules.length; i++) { - uint256 operation = bound(input.rules[i].operation, 0, 3); - ParameterOperation parameterOperation; - if (operation == 0) { - parameterOperation = ParameterOperation.EQUAL; - } else if (operation == 1) { - parameterOperation = ParameterOperation.NOT_EQUAL; - } else if (operation == 2) { - parameterOperation = ParameterOperation.GREATER_THAN_OR_EQUAL; - } else if (operation == 3) { - parameterOperation = ParameterOperation.LESS_THAN_OR_EQUAL; - } - rules[i] = ParameterRule({ - cumulative: input.rules[i].cumulative, - operation: parameterOperation, - value: input.rules[i].value, - offset: input.rules[i].offset, - mask: input.rules[i].mask - }); - } - return Permission({ target: input.target, rules: rules }); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/SessionCalls.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/SessionCalls.t.sol deleted file mode 100644 index 2162b71578..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/SessionCalls.t.sol +++ /dev/null @@ -1,299 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Vm, console } from "forge-std/Test.sol"; -import { SessionTestBase } from "test/extensions/sessions/SessionTestBase.sol"; - -import { Emitter } from "test/mocks/Emitter.sol"; -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; - -import { Factory } from "src/Factory.sol"; -import { Stage1Module } from "src/Stage1Module.sol"; -import { SessionErrors } from "src/extensions/sessions/SessionErrors.sol"; -import { SessionManager } from "src/extensions/sessions/SessionManager.sol"; -import { SessionSig } from "src/extensions/sessions/SessionSig.sol"; -import { SessionPermissions } from "src/extensions/sessions/explicit/IExplicitSessionManager.sol"; -import { - ParameterOperation, ParameterRule, Permission, UsageLimit -} from "src/extensions/sessions/explicit/Permission.sol"; -import { Attestation, LibAttestation } from "src/extensions/sessions/implicit/Attestation.sol"; -import { Calls } from "src/modules/Calls.sol"; -import { ERC4337v07 } from "src/modules/ERC4337v07.sol"; -import { Payload } from "src/modules/Payload.sol"; -import { ISapient } from "src/modules/interfaces/ISapient.sol"; - -/// @notice Explicit session integration tests. -contract SessionCallsTest is SessionTestBase { - - Factory public factory; - Stage1Module public module; - SessionManager public sessionManager; - Vm.Wallet public sessionWallet; - Vm.Wallet public identityWallet; - MockContract public target; - - function setUp() public { - sessionWallet = vm.createWallet("session"); - identityWallet = vm.createWallet("identity"); - sessionManager = new SessionManager(); - factory = new Factory(); - module = new Stage1Module(address(factory), address(0)); - target = new MockContract(); - } - - function _validCall(Payload.Call memory call, bool callRevert) internal view returns (Payload.Call memory) { - call.to = address(target); - call.behaviorOnError = bound(call.behaviorOnError, 0, 2); - call.value = bound(call.value, 0, 1 ether); - call.data = abi.encodeWithSelector(MockContract.willRevert.selector, callRevert); - call.gasLimit = bound(call.gasLimit, 0, 1); // Pass or fail due to gas limit - - // FIXME Remove. This is here to make it pass - // call.behaviorOnError = Payload.BEHAVIOR_REVERT_ON_ERROR; - // call.onlyFallback = false; - // call.data = abi.encodeWithSelector(MockContract.willRevert.selector, false); - - return call; - } - - function test_fuzzForSkippingIncrementCall( - Payload.Call memory call1, - Payload.Call memory call2, - bool call1Revert, - bool call2Revert - ) public { - Payload.Decoded memory payload = _buildPayload(3); - // Fuzzes: Behavior, value, onlyFallback, gasLimit, contract call reverts - payload.calls[1] = _validCall(call1, call1Revert); - payload.calls[2] = _validCall(call2, call2Revert); - - // totalValue is calculated from calls[1] and calls[2] - uint256 totalValue = payload.calls[1].value + payload.calls[2].value; - vm.assume(totalValue > 0); // Required to use an increment permission - - // Create the increment call and place it at index 0 - UsageLimit[] memory usageLimits = new UsageLimit[](1); - usageLimits[0] = UsageLimit({ - usageHash: keccak256(abi.encode(sessionWallet.addr, sessionManager.VALUE_TRACKING_ADDRESS())), - usageAmount: totalValue - }); - - // Manually construct the increment call to ensure it's valid, not fuzzed. - // The original test fuzzed this call, but now it must be valid for the test setup. - payload.calls[0] = Payload.Call({ - to: address(sessionManager), - data: abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, usageLimits), - value: 0, // Increment calls should not have value - gasLimit: 0, // No gas limit - delegateCall: false, - onlyFallback: false, // Must not be a fallback - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR // Must revert on error - }); - - // Create the valid explicit session - string memory topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: 0, - valueLimit: totalValue, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: address(target), rules: new ParameterRule[](0) }); - string memory sessionPermsJson = _sessionPermissionsToJSON(sessionPerms); - topology = PrimitivesRPC.sessionExplicitAdd(vm, sessionPermsJson, topology); - bytes32 sessionImageHash = PrimitivesRPC.sessionImageHash(vm, topology); - - // Create the wallet config - string memory config; - { - string memory ce = string( - abi.encodePacked("sapient:", vm.toString(sessionImageHash), ":", vm.toString(address(sessionManager)), ":1") - ); - config = PrimitivesRPC.newConfig(vm, 1, 0, ce); - } - bytes32 imageHash = PrimitivesRPC.getImageHash(vm, config); - Stage1Module wallet = Stage1Module(payable(factory.deploy(address(module), imageHash))); - - // Fund the wallet - vm.deal(address(wallet), totalValue + 1); - - // Sign the payload - string[] memory callSignatures = new string[](3); - for (uint256 i = 0; i < 3; i++) { - string memory sessionSignature = - _signAndEncodeRSV(SessionSig.hashCallWithReplayProtection(payload, i), sessionWallet); - callSignatures[i] = _explicitCallSignatureToJSON(0, sessionSignature); - } - address[] memory explicitSigners = new address[](1); - explicitSigners[0] = sessionWallet.addr; - address[] memory implicitSigners = new address[](0); - bytes memory sessionSignatures = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - string memory signatures = - string(abi.encodePacked(vm.toString(address(sessionManager)), ":sapient:", vm.toString(sessionSignatures))); - bytes memory encodedSignature = PrimitivesRPC.toEncodedSignature(vm, config, signatures, false); - - // Execute the payload - bytes memory packedPayload = PrimitivesRPC.toPackedPayload(vm, payload); - try wallet.execute(packedPayload, encodedSignature) { - // If execution succeeds, check the increment is updated - uint256 usageAmount = sessionManager.getLimitUsage(address(wallet), usageLimits[0].usageHash); - assertEq(usageAmount, totalValue, "Usage should increment on successful execution"); - // It doesn't matter if the wallet spends funds or not - // (error and IGNORE, error and IGNORE, increment) is ok - } catch (bytes memory reason) { - // If the execution reverts, check the wallet balance is unaffected - bytes4 errorSelector = bytes4(reason); - if ( - errorSelector == SessionErrors.InvalidBehavior.selector - || errorSelector == SessionErrors.InvalidDelegateCall.selector - || errorSelector == SessionErrors.InvalidValue.selector || errorSelector == Calls.NotEnoughGas.selector - || errorSelector == Calls.Reverted.selector || errorSelector == MockContract.MockError.selector - ) { - // Should not spend funds or update usage limits - assertEq(address(wallet).balance, totalValue + 1, "Wallet balance should not change"); - uint256 usageAmount = sessionManager.getLimitUsage(address(wallet), usageLimits[0].usageHash); - assertEq(usageAmount, 0, "Usage should not increment"); - } else if (errorSelector == SessionErrors.InvalidLimitUsageIncrement.selector) { - // This case is now more complex. A failure here could be because the fuzzer made call1 or call2 - // have an invalid behavior that would cause the increment to be skipped. - // The simplest way to handle this is to accept that an InvalidLimitUsageIncrement revert - // means the wallet balance and usage should not change. - assertEq( - address(wallet).balance, totalValue + 1, "Wallet balance should not change on InvalidLimitUsageIncrement" - ); - uint256 usageAmount = sessionManager.getLimitUsage(address(wallet), usageLimits[0].usageHash); - assertEq(usageAmount, 0, "Usage should not increment on InvalidLimitUsageIncrement"); - } else { - revert("Got an unexpected error. Update tests to handle this error."); - } - } - } - - function test_fuzzForSkippingIncrementCall2( - Payload.Call memory callIncrement, - Payload.Call memory call1, - Payload.Call memory call2, - Payload.Call memory call3, - bool call1Revert, - bool call2Revert, - bool call3Revert - ) public { - Payload.Decoded memory payload = _buildPayload(4); - // Fuzzes: Behavior, value, onlyFallback, gasLimit, contract call reverts - payload.calls[1] = _validCall(call1, call1Revert); - payload.calls[2] = _validCall(call2, call2Revert); - payload.calls[3] = _validCall(call3, call3Revert); - - // totalValue is calculated from calls[1] through calls[3] - uint256 totalValue = payload.calls[1].value + payload.calls[2].value + payload.calls[3].value; - vm.assume(totalValue > 0); // Required to use an increment permission - - // Create the increment call and place it at index 0 - UsageLimit[] memory usageLimits = new UsageLimit[](1); - usageLimits[0] = UsageLimit({ - usageHash: keccak256(abi.encode(sessionWallet.addr, sessionManager.VALUE_TRACKING_ADDRESS())), - usageAmount: totalValue - }); - - callIncrement = _validCall(callIncrement, false); - callIncrement.to = address(sessionManager); - callIncrement.data = abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, usageLimits); - payload.calls[0] = callIncrement; - - // Create the valid explicit session - string memory topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: 0, - valueLimit: totalValue, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: address(target), rules: new ParameterRule[](0) }); - string memory sessionPermsJson = _sessionPermissionsToJSON(sessionPerms); - topology = PrimitivesRPC.sessionExplicitAdd(vm, sessionPermsJson, topology); - bytes32 sessionImageHash = PrimitivesRPC.sessionImageHash(vm, topology); - - // Create the wallet config - string memory config; - { - string memory ce = string( - abi.encodePacked("sapient:", vm.toString(sessionImageHash), ":", vm.toString(address(sessionManager)), ":1") - ); - config = PrimitivesRPC.newConfig(vm, 1, 0, ce); - } - bytes32 imageHash = PrimitivesRPC.getImageHash(vm, config); - Stage1Module wallet = Stage1Module(payable(factory.deploy(address(module), imageHash))); - - // Fund the wallet - vm.deal(address(wallet), totalValue + 1); - - // Sign the payload - string[] memory callSignatures = new string[](4); - for (uint256 i; i < 4; i++) { - string memory sessionSignature = - _signAndEncodeRSV(SessionSig.hashCallWithReplayProtection(payload, i), sessionWallet); - callSignatures[i] = _explicitCallSignatureToJSON(0, sessionSignature); - } - address[] memory explicitSigners = new address[](1); - explicitSigners[0] = sessionWallet.addr; - address[] memory implicitSigners = new address[](0); - bytes memory sessionSignatures = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - string memory signatures = - string(abi.encodePacked(vm.toString(address(sessionManager)), ":sapient:", vm.toString(sessionSignatures))); - bytes memory encodedSignature = PrimitivesRPC.toEncodedSignature(vm, config, signatures, false); - - // Execute the payload - bytes memory packedPayload = PrimitivesRPC.toPackedPayload(vm, payload); - try wallet.execute(packedPayload, encodedSignature) { - // If execution succeeds, check the increment is updated - uint256 usageAmount = sessionManager.getLimitUsage(address(wallet), usageLimits[0].usageHash); - assertEq(usageAmount, totalValue, "Usage should increment on successful execution"); - // It doesn't matter if the wallet spends funds or not - // (error and IGNORE, error and IGNORE, increment) is ok - } catch (bytes memory reason) { - // If the execution reverts, check the wallet balance is unaffected - bytes4 errorSelector = bytes4(reason); - if ( - errorSelector == SessionErrors.InvalidBehavior.selector - || errorSelector == SessionErrors.InvalidDelegateCall.selector - || errorSelector == SessionErrors.InvalidValue.selector || errorSelector == Calls.NotEnoughGas.selector - || errorSelector == Calls.Reverted.selector || errorSelector == MockContract.MockError.selector - ) { - // Should not spend funds or update usage limits - assertEq(address(wallet).balance, totalValue + 1, "Wallet balance should not change"); - uint256 usageAmount = sessionManager.getLimitUsage(address(wallet), usageLimits[0].usageHash); - assertEq(usageAmount, 0, "Usage should not increment"); - } else if (errorSelector == SessionErrors.InvalidLimitUsageIncrement.selector) { - if (callIncrement.behaviorOnError != Payload.BEHAVIOR_REVERT_ON_ERROR || callIncrement.onlyFallback) { - // Expected. Should not spend funds or update usage limits - assertEq(address(wallet).balance, totalValue + 1, "Wallet balance should not change"); - uint256 usageAmount = sessionManager.getLimitUsage(address(wallet), usageLimits[0].usageHash); - assertEq(usageAmount, 0, "Usage should not increment"); - } else { - revert("Test not correctly fuzzed. This should always pass."); - } - } else { - revert("Got an unexpected error. Update tests to handle this error."); - } - } - } - -} - -contract MockContract { - - error MockError(); - - function willRevert( - bool doRevert - ) public payable { - if (doRevert) { - revert MockError(); - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/SessionManager.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/SessionManager.t.sol deleted file mode 100644 index 812eb6381f..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/SessionManager.t.sol +++ /dev/null @@ -1,855 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Vm } from "forge-std/Vm.sol"; -import { SessionTestBase } from "test/extensions/sessions/SessionTestBase.sol"; - -import { Emitter } from "test/mocks/Emitter.sol"; -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; - -import { Factory } from "src/Factory.sol"; -import { Stage1Module } from "src/Stage1Module.sol"; -import { SessionErrors } from "src/extensions/sessions/SessionErrors.sol"; -import { SessionManager } from "src/extensions/sessions/SessionManager.sol"; -import { SessionSig } from "src/extensions/sessions/SessionSig.sol"; -import { SessionPermissions } from "src/extensions/sessions/explicit/IExplicitSessionManager.sol"; -import { - ParameterOperation, ParameterRule, Permission, UsageLimit -} from "src/extensions/sessions/explicit/Permission.sol"; -import { Attestation, LibAttestation } from "src/extensions/sessions/implicit/Attestation.sol"; -import { Payload } from "src/modules/Payload.sol"; -import { ISapient } from "src/modules/interfaces/ISapient.sol"; - -import { CanReenter } from "test/mocks/CanReenter.sol"; -import { MockERC20 } from "test/mocks/MockERC20.sol"; - -contract SessionManagerTest is SessionTestBase { - - SessionManager public sessionManager; - Vm.Wallet public sessionWallet; - Vm.Wallet public identityWallet; - Emitter public emitter; - - function setUp() public { - sessionManager = new SessionManager(); - sessionWallet = vm.createWallet("session"); - identityWallet = vm.createWallet("identity"); - emitter = new Emitter(); - } - - /// @notice Valid explicit session test. - function testValidExplicitSessionSignature( - bytes4 selector, - uint256 param, - uint256 value, - address explicitTarget, - address explicitTarget2, - bool useChainId - ) public { - vm.assume(explicitTarget != explicitTarget2); - vm.assume(value > 0); - vm.assume(param > 0); - vm.assume(explicitTarget != address(sessionManager)); - vm.assume(explicitTarget2 != address(sessionManager)); - bytes memory callData = abi.encodeWithSelector(selector, param); - - // --- Session Permissions --- - // Create a SessionPermissions struct granting permission for calls to explicitTarget. - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: useChainId ? block.chainid : 0, - valueLimit: value, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](2) - }); - // Permission with an empty rules set allows all calls to the target. - ParameterRule[] memory rules = new ParameterRule[](2); - // Rules for explicitTarget in call 0. - rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(uint256(uint32(selector)) << 224), - offset: 0, - mask: bytes32(uint256(uint32(0xffffffff)) << 224) - }); - rules[1] = ParameterRule({ - cumulative: true, - operation: ParameterOperation.LESS_THAN_OR_EQUAL, - value: bytes32(param), - offset: 4, // offset the param (selector is 4 bytes) - mask: bytes32(0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff) - }); - sessionPerms.permissions[0] = Permission({ target: explicitTarget, rules: rules }); - sessionPerms.permissions[1] = Permission({ target: explicitTarget2, rules: new ParameterRule[](0) }); // Unlimited access - - // Build a payload with two calls: - // Call 0: call not requiring incrementUsageLimit - // Call 1: call requiring incrementUsageLimit - // Call 2: the required incrementUsageLimit call (self–call) - Payload.Decoded memory payload = _buildPayload(3); - - // --- Explicit Call 1 --- - payload.calls[1] = Payload.Call({ - to: explicitTarget, - value: value, - data: callData, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // --- Explicit Call 2 --- - payload.calls[2] = Payload.Call({ - to: explicitTarget2, - value: 0, - data: callData, // Reuse this because permission for this target is open - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // --- Increment Usage Limit --- - { - UsageLimit[] memory limits = new UsageLimit[](2); - limits[0] = UsageLimit({ - usageHash: keccak256(abi.encode(sessionWallet.addr, sessionPerms.permissions[0], uint256(1))), - usageAmount: param - }); - limits[1] = - UsageLimit({ usageHash: keccak256(abi.encode(sessionWallet.addr, VALUE_TRACKING_ADDRESS)), usageAmount: value }); - payload.calls[0] = Payload.Call({ - to: address(sessionManager), - value: 0, - data: abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, limits), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - } - - uint8[] memory permissionIdxs = new uint8[](3); - permissionIdxs[0] = 0; // Call 0 - permissionIdxs[1] = 0; // Call 1 - permissionIdxs[2] = 1; // Call 2 - - (bytes32 imageHash, bytes memory encodedSig) = _validExplicitSessionSignature(payload, sessionPerms, permissionIdxs); - - vm.prank(sessionWallet.addr); - bytes32 actualImageHash = sessionManager.recoverSapientSignature(payload, encodedSig); - assertEq(imageHash, actualImageHash); - } - - function testIncrementReentrancy() external { - MockERC20 token = new MockERC20(); - CanReenter canReenter = new CanReenter(); - Factory factory = new Factory(); - Stage1Module stage1Module = new Stage1Module(address(factory), address(0)); - Vm.Wallet memory badGuy = vm.createWallet("badGuy"); - - // --- Session Permissions --- - // Create a SessionPermissions struct granting permission for calls to explicitTarget. - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: 0, - valueLimit: 0, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](2) - }); - // Permission with an empty rules set allows all calls to the target. - ParameterRule[] memory rules = new ParameterRule[](2); - rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(uint256(uint32(MockERC20.transfer.selector)) << 224), - offset: 0, - mask: bytes32(uint256(uint32(0xffffffff)) << 224) - }); - rules[1] = ParameterRule({ - cumulative: true, - operation: ParameterOperation.LESS_THAN_OR_EQUAL, - value: bytes32(uint256(1 ether)), - offset: 4 + 32, // offset the param (selector is 4 bytes) - mask: bytes32(0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff) - }); - sessionPerms.permissions[0] = Permission({ target: address(token), rules: rules }); - sessionPerms.permissions[1] = Permission({ target: address(canReenter), rules: new ParameterRule[](0) }); // Unlimited access - - // Build the session topology using PrimitiveRPC. - string memory topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - string memory sessionPermsJson = _sessionPermissionsToJSON(sessionPerms); - topology = PrimitivesRPC.sessionExplicitAdd(vm, sessionPermsJson, topology); - - // Topology hash - bytes32 topologyHash = PrimitivesRPC.sessionImageHash(vm, topology); - - // Create wallet for this topology - string memory config = PrimitivesRPC.newConfig( - vm, - 1, - 0, - string( - abi.encodePacked( - "sapient:", vm.toString(topologyHash), ":", vm.toString(address(sessionManager)), ":", vm.toString(uint256(1)) - ) - ) - ); - bytes32 configHash = PrimitivesRPC.getImageHash(vm, config); - address payable wallet = payable(factory.deploy(address(stage1Module), configHash)); - - // Transfer tokens to the wallet (2 ether) - token.transfer(wallet, 2 ether); - - // Build the reentrant payload - // Call 0: update the usage limit - // Call 1: transfer 0.5 ether to the bad guy - Payload.Decoded memory reentrantPayload = _buildPayload(2); - reentrantPayload.nonce = 1; - - UsageLimit[] memory reentrantLimits = new UsageLimit[](1); - reentrantLimits[0] = UsageLimit({ - usageHash: keccak256(abi.encode(sessionWallet.addr, sessionPerms.permissions[0], uint256(1))), - usageAmount: 1 ether - }); - - // Call 0: update the usage limit - reentrantPayload.calls[0] = Payload.Call({ - to: address(sessionManager), - value: 0, - data: abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, reentrantLimits), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - reentrantPayload.calls[1] = Payload.Call({ - to: address(token), - value: 0, - data: abi.encodeWithSelector(token.transfer.selector, badGuy.addr, 1 ether), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Encode the call signatures for the reentrant payload - string[] memory reentrantCallSignatures = new string[](2); - string memory sessionSignature = - _signAndEncodeRSV(SessionSig.hashCallWithReplayProtection(reentrantPayload, 0), sessionWallet); - reentrantCallSignatures[0] = _explicitCallSignatureToJSON(0, sessionSignature); - sessionSignature = _signAndEncodeRSV(SessionSig.hashCallWithReplayProtection(reentrantPayload, 1), sessionWallet); - reentrantCallSignatures[1] = _explicitCallSignatureToJSON(0, sessionSignature); - address[] memory reentrantExplicitSigners = new address[](1); - reentrantExplicitSigners[0] = sessionWallet.addr; - address[] memory reentrantImplicitSigners = new address[](0); - bytes memory reentrantEncodedSig = PrimitivesRPC.sessionEncodeCallSignatures( - vm, topology, reentrantCallSignatures, reentrantExplicitSigners, reentrantImplicitSigners - ); - - // Encode the main signature for the reentrant payload - bytes memory reentrantMainSignature = PrimitivesRPC.toEncodedSignature( - vm, - config, - string(abi.encodePacked(vm.toString(address(sessionManager)), ":sapient:", vm.toString(reentrantEncodedSig))), - false - ); - - // Pack reentrant payload - bytes memory reentrantPackedPayload = PrimitivesRPC.toPackedPayload(vm, reentrantPayload); - - // Encode the execute function call - bytes memory reentrantExecuteData = abi.encodeWithSelector( - canReenter.doAnotherCall.selector, - address(wallet), - abi.encodeWithSelector(Stage1Module(wallet).execute.selector, reentrantPackedPayload, reentrantMainSignature) - ); - - // Build a payload with two calls: - // Call 1: transfer tokens to the bad guy - // Call 2: re-enter and transfer more tokens to the bad guy - // Call 3: the required incrementUsageLimit call (self–call) - Payload.Decoded memory payload = _buildPayload(3); - - // --- Explicit Call 0 --- - UsageLimit[] memory limits = new UsageLimit[](1); - limits[0] = UsageLimit({ - usageHash: keccak256(abi.encode(sessionWallet.addr, sessionPerms.permissions[0], uint256(0.5 ether))), - usageAmount: 0.5 ether - }); - - payload.calls[0] = Payload.Call({ - to: address(sessionManager), - value: 0, - data: abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, limits), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // --- Explicit Call 1 --- - payload.calls[1] = Payload.Call({ - to: address(token), - value: 0, - data: abi.encodeWithSelector(token.transfer.selector, badGuy.addr, 1 ether), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // --- Explicit Call 2 --- - payload.calls[2] = Payload.Call({ - to: address(canReenter), - value: 0, - data: reentrantExecuteData, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // --- Call Signatures --- - string[] memory callSignatures = new string[](3); - { - // Sign the explicit call (call 0) using the session key. - sessionSignature = _signAndEncodeRSV(SessionSig.hashCallWithReplayProtection(payload, 0), sessionWallet); - callSignatures[0] = _explicitCallSignatureToJSON(0, sessionSignature); - // Sign the explicit call (call 1) using the session key. - sessionSignature = _signAndEncodeRSV(SessionSig.hashCallWithReplayProtection(payload, 1), sessionWallet); - callSignatures[1] = _explicitCallSignatureToJSON(0, sessionSignature); - // Sign the self call (call 2) using the session key. - sessionSignature = _signAndEncodeRSV(SessionSig.hashCallWithReplayProtection(payload, 2), sessionWallet); - callSignatures[2] = _explicitCallSignatureToJSON(1, sessionSignature); - } - - // Encode the full signature. - address[] memory explicitSigners = new address[](1); - explicitSigners[0] = sessionWallet.addr; - address[] memory implicitSigners = new address[](0); - bytes memory encodedSig = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - - // Encode the main signature - bytes memory mainSignature = PrimitivesRPC.toEncodedSignature( - vm, - config, - string(abi.encodePacked(vm.toString(address(sessionManager)), ":sapient:", vm.toString(encodedSig))), - false - ); - - // Execute the payload - bytes memory packedPayload = PrimitivesRPC.toPackedPayload(vm, payload); - vm.expectRevert(); - Stage1Module(wallet).execute(packedPayload, mainSignature); - - // Bad guy should have 0 funds - assertEq(token.balanceOf(badGuy.addr), 0); - } - - function _prepareIncrementOverMultipleCalls( - address wallet, - address target, - uint256 startIncrement, - uint256 value1, - uint256 value2, - uint256 ruleValue - ) internal returns (Payload.Decoded memory payload, bytes32 imageHash, bytes memory encodedSig) { - vm.assume(target.code.length == 0); - - // Session permissions - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: 0, - valueLimit: 0, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: target, rules: new ParameterRule[](1) }); - sessionPerms.permissions[0].rules[0] = ParameterRule({ - cumulative: true, - operation: ParameterOperation.LESS_THAN_OR_EQUAL, - value: bytes32(uint256(ruleValue)), - offset: 0, - mask: bytes32(0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff) - }); - - // Set the initial limit usage - UsageLimit[] memory limits = new UsageLimit[](1); - limits[0] = UsageLimit({ - usageHash: keccak256(abi.encode(sessionWallet.addr, sessionPerms.permissions[0], uint256(0))), - usageAmount: startIncrement - }); - vm.prank(wallet); - sessionManager.incrementUsageLimit(limits); - assertEq(sessionManager.getLimitUsage(wallet, limits[0].usageHash), startIncrement); - - // Call 0: increment the usage limit - payload = _buildPayload(3); - limits[0].usageAmount = startIncrement + value1 + value2; - payload.calls[0] = Payload.Call({ - to: address(sessionManager), - value: 0, - data: abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, limits), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Use limit - payload.calls[1] = Payload.Call({ - to: target, - value: 0, - data: abi.encodePacked(uint256(value1)), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - payload.calls[2] = Payload.Call({ - to: target, - value: 0, - data: abi.encodePacked(uint256(value2)), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - uint8[] memory permissionIdxs = new uint8[](3); - - (imageHash, encodedSig) = _validExplicitSessionSignature(payload, sessionPerms, permissionIdxs); - - return (payload, imageHash, encodedSig); - } - - function testIncrementOverMultipleCalls_Invalid( - address wallet, - address target, - uint256 startIncrement, - uint256 value1, - uint256 value2, - uint256 ruleValue - ) public { - startIncrement = bound(startIncrement, 0, 1 ether); - value1 = bound(value1, 1, 1 ether); - value2 = bound(value2, 1, 1 ether); - - ruleValue = bound(ruleValue, 0, startIncrement + value1 + value2 - 1); - - Payload.Decoded memory payload; - bytes memory encodedSig; - (payload,, encodedSig) = - _prepareIncrementOverMultipleCalls(wallet, target, startIncrement, value1, value2, ruleValue); - - vm.prank(wallet); - vm.expectRevert(SessionErrors.InvalidPermission.selector); - sessionManager.recoverSapientSignature(payload, encodedSig); - } - - function testIncrementOverMultipleCalls_Valid( - address wallet, - address target, - uint256 startIncrement, - uint256 value1, - uint256 value2, - uint256 ruleValue - ) public { - vm.assume(target != wallet); - startIncrement = bound(startIncrement, 0, 1 ether); - value1 = bound(value1, 1, 1 ether); - value2 = bound(value2, 1, 1 ether); - - ruleValue = bound(ruleValue, startIncrement + value1 + value2, 100 ether); - - (Payload.Decoded memory payload, bytes32 imageHash, bytes memory encodedSig) = - _prepareIncrementOverMultipleCalls(wallet, target, startIncrement, value1, value2, ruleValue); - - vm.prank(wallet); - bytes32 actualImageHash = sessionManager.recoverSapientSignature(payload, encodedSig); - assertEq(imageHash, actualImageHash); - } - - function testInvalidPayloadKindReverts() public { - Payload.Decoded memory payload; - bytes memory encodedSig; - - payload.kind = Payload.KIND_MESSAGE; - vm.expectRevert(SessionErrors.InvalidPayloadKind.selector); - sessionManager.recoverSapientSignature(payload, encodedSig); - - payload.kind = Payload.KIND_CONFIG_UPDATE; - vm.expectRevert(SessionErrors.InvalidPayloadKind.selector); - sessionManager.recoverSapientSignature(payload, encodedSig); - - payload.kind = Payload.KIND_DIGEST; - vm.expectRevert(SessionErrors.InvalidPayloadKind.selector); - sessionManager.recoverSapientSignature(payload, encodedSig); - } - - function testInvalidCallsLengthReverts( - bytes memory sig - ) public { - Payload.Decoded memory payload; - payload.kind = Payload.KIND_TRANSACTIONS; - - vm.expectRevert(SessionErrors.InvalidCallsLength.selector); - sessionManager.recoverSapientSignature(payload, sig); - } - - function testInvalidSpaceReverts(uint160 space, bytes memory sig) public { - space = uint160(bound(space, sessionManager.MAX_SPACE() + 1, type(uint160).max)); - - Payload.Decoded memory payload; - - vm.expectRevert(SessionErrors.InvalidCallsLength.selector); - sessionManager.recoverSapientSignature(payload, sig); - } - - /// @notice Test that a call using delegateCall reverts. - function testInvalidDelegateCallReverts(Attestation memory attestation, bytes memory data, address target) public { - vm.assume(target != address(sessionManager)); - attestation.approvedSigner = sessionWallet.addr; - attestation.authData.redirectUrl = "https://example.com"; // Normalise for safe JSONify - attestation.authData.issuedAt = uint64(bound(attestation.authData.issuedAt, 0, block.timestamp)); - - // Build a payload with one call that erroneously uses delegateCall. - uint256 callCount = 1; - Payload.Decoded memory payload = _buildPayload(callCount); - payload.calls[0] = Payload.Call({ - to: target, - value: 0, - data: data, - gasLimit: 0, - delegateCall: true, // invalid - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - (, bytes memory encodedSig) = _validImplicitSessionSignature(payload); - - vm.expectRevert(SessionErrors.InvalidDelegateCall.selector); - sessionManager.recoverSapientSignature(payload, encodedSig); - } - - /// @notice Valid implicit session test. - function testValidImplicitSessionSignature( - Attestation memory attestation - ) public { - attestation.approvedSigner = sessionWallet.addr; - attestation.authData.redirectUrl = "https://example.com"; // Normalise for safe JSONify - attestation.authData.issuedAt = uint64(bound(attestation.authData.issuedAt, 0, block.timestamp)); - - // Build a payload with one call for implicit session. - uint256 callCount = 1; - Payload.Decoded memory payload = _buildPayload(callCount); - payload.calls[0] = Payload.Call({ - to: address(emitter), - value: 0, - data: abi.encodeWithSelector(Emitter.implicitEmit.selector), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - (bytes32 imageHash, bytes memory encodedSig) = _validImplicitSessionSignature(payload); - - vm.prank(sessionWallet.addr); - bytes32 actualImageHash = sessionManager.recoverSapientSignature(payload, encodedSig); - assertEq(imageHash, actualImageHash); - } - - /// @notice Test that calls with onlyFallback = true are allowed - function testOnlyFallbackCallsAllowed() public { - // Build a payload with one call that has onlyFallback = true - Payload.Decoded memory payload = _buildPayload(1); - payload.calls[0] = Payload.Call({ - to: address(emitter), // Use emitter instead of explicitTarget for implicit sessions - value: 0, - data: abi.encodeWithSelector(Emitter.implicitEmit.selector), - gasLimit: 0, - delegateCall: false, - onlyFallback: true, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - (bytes32 imageHash, bytes memory encodedSig) = _validImplicitSessionSignature(payload); - - vm.prank(sessionWallet.addr); - bytes32 actualImageHash = sessionManager.recoverSapientSignature(payload, encodedSig); - assertEq(imageHash, actualImageHash); - } - - /// @notice Test that calls with BEHAVIOR_ABORT_ON_ERROR will revert with InvalidBehavior - function testBehaviorAbortOnErrorCallsRevert(address target, bytes memory data) public { - vm.assume(target != address(sessionManager)); - // Build a payload with one call that has BEHAVIOR_ABORT_ON_ERROR - uint256 callCount = 1; - Payload.Decoded memory payload = _buildPayload(callCount); - payload.calls[0] = Payload.Call({ - to: target, - value: 0, - data: data, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_ABORT_ON_ERROR // This should revert - }); - - (, bytes memory encodedSig) = _validImplicitSessionSignature(payload); - - vm.expectRevert(SessionErrors.InvalidBehavior.selector); - sessionManager.recoverSapientSignature(payload, encodedSig); - } - - /// @notice Test that calls with onlyFallback = true in explicit sessions are allowed - function testExplicitSessionOnlyFallbackAllowed(address target, bytes memory data) public { - vm.assume(target != address(sessionManager)); - // Build a payload with one call: explicit call - Payload.Decoded memory payload = _buildPayload(1); - - // First call with onlyFallback = true (should be allowed) - // increment call is not allowed since there is no consumption of the usage limit - payload.calls[0] = Payload.Call({ - to: target, - value: 0, - data: data, - gasLimit: 0, - delegateCall: false, - onlyFallback: true, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Session permissions - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: 0, - valueLimit: 0, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: target, rules: new ParameterRule[](0) }); - - uint8[] memory permissionIdxs = new uint8[](1); - permissionIdxs[0] = 0; // Call 0 - - (bytes32 imageHash, bytes memory encodedSig) = _validExplicitSessionSignature(payload, sessionPerms, permissionIdxs); - - vm.prank(sessionWallet.addr); - bytes32 actualImageHash = sessionManager.recoverSapientSignature(payload, encodedSig); - assertEq(imageHash, actualImageHash); - } - - /// @notice Test that the increment call cannot have onlyFallback = true - function testIncrementCallOnlyFallbackReverts(address target, bytes memory data) public { - vm.assume(target != address(sessionManager)); - // Build a payload with two calls: explicit call + increment call with onlyFallback - uint256 callCount = 2; - Payload.Decoded memory payload = _buildPayload(callCount); - - // First call (valid explicit call that will use usage limits) - payload.calls[0] = Payload.Call({ - to: target, - value: 1, // Use some value to trigger usage tracking - data: data, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Second call (increment call with onlyFallback = true - should revert) - payload.calls[1] = Payload.Call({ - to: address(sessionManager), - value: 0, - data: abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, new UsageLimit[](1)), - gasLimit: 0, - delegateCall: false, - onlyFallback: true, // This should cause the increment call to be skipped - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Session permissions with value limit to trigger usage tracking - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: 0, - valueLimit: 1, // Set value limit to trigger usage tracking - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: target, rules: new ParameterRule[](0) }); - - uint8[] memory permissionIdxs = new uint8[](2); - permissionIdxs[0] = 0; // Call 0 - permissionIdxs[1] = 0; // Call 1 - - (, bytes memory encodedSig) = _validExplicitSessionSignature(payload, sessionPerms, permissionIdxs); - - vm.expectRevert(SessionErrors.InvalidLimitUsageIncrement.selector); - sessionManager.recoverSapientSignature(payload, encodedSig); - } - - /// @notice Test that calls with BEHAVIOR_IGNORE_ERROR in explicit sessions are allowed - function testExplicitSessionBehaviorIgnoreErrorAllowed(address target, bytes memory data) public { - vm.assume(target != address(sessionManager)); - Payload.Decoded memory payload = _buildPayload(1); - - // First call with BEHAVIOR_IGNORE_ERROR (should be allowed) - payload.calls[0] = Payload.Call({ - to: target, - value: 0, - data: data, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_IGNORE_ERROR - }); - - // Session permissions - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: 0, - valueLimit: 0, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: target, rules: new ParameterRule[](0) }); - - (bytes32 imageHash, bytes memory encodedSig) = _validExplicitSessionSignature(payload, sessionPerms, new uint8[](1)); - - bytes32 actualImageHash = sessionManager.recoverSapientSignature(payload, encodedSig); - assertEq(imageHash, actualImageHash); - } - - /// @notice Test that calls with BEHAVIOR_ABORT_ON_ERROR in explicit sessions revert - function testExplicitSessionBehaviorAbortOnErrorReverts(address target, bytes memory data) public { - vm.assume(target != address(sessionManager)); - Payload.Decoded memory payload = _buildPayload(1); - - // First call with BEHAVIOR_ABORT_ON_ERROR (should revert) - payload.calls[0] = Payload.Call({ - to: target, - value: 0, - data: data, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_ABORT_ON_ERROR // This should revert - }); - - // Session permissions - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: 0, - valueLimit: 0, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: target, rules: new ParameterRule[](0) }); - - (, bytes memory encodedSig) = _validExplicitSessionSignature(payload, sessionPerms, new uint8[](1)); - - vm.expectRevert(SessionErrors.InvalidBehavior.selector); - sessionManager.recoverSapientSignature(payload, encodedSig); - } - - /// @notice Test that valid linear execution still works - function testValidLinearExecution(address target, bytes memory data) public { - vm.assume(target != address(sessionManager)); - Payload.Decoded memory payload = _buildPayload(1); - - // First call (normal explicit call) - payload.calls[0] = Payload.Call({ - to: target, - value: 0, - data: data, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR // Valid behavior - }); - - // Session permissions - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: 0, - valueLimit: 0, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: target, rules: new ParameterRule[](0) }); - - (bytes32 imageHash, bytes memory encodedSig) = _validExplicitSessionSignature(payload, sessionPerms, new uint8[](1)); - - // This should succeed since all flags are valid for linear execution - bytes32 actualImageHash = sessionManager.recoverSapientSignature(payload, encodedSig); - assertEq(imageHash, actualImageHash); - } - - // ============================================================================ - // HELPER FUNCTIONS - // ============================================================================ - - /// @notice Create a valid attestation for testing - function _createValidAttestation() internal view returns (Attestation memory) { - Attestation memory attestation; - attestation.approvedSigner = sessionWallet.addr; - attestation.authData.redirectUrl = "https://example.com"; - attestation.authData.issuedAt = uint64(block.timestamp); - return attestation; - } - - function _validImplicitSessionSignature( - Payload.Decoded memory payload - ) internal returns (bytes32 imageHash, bytes memory encodedSig) { - string memory topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - imageHash = PrimitivesRPC.sessionImageHash(vm, topology); - - uint256 callCount = payload.calls.length; - string[] memory callSignatures = new string[](callCount); - Attestation memory attestation = _createValidAttestation(); - for (uint256 i; i < callCount; i++) { - callSignatures[i] = _createImplicitCallSignature(payload, i, sessionWallet, identityWallet, attestation); - } - - address[] memory explicitSigners = new address[](0); - address[] memory implicitSigners = new address[](1); - implicitSigners[0] = sessionWallet.addr; - encodedSig = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - return (imageHash, encodedSig); - } - - function _validExplicitSessionSignature( - Payload.Decoded memory payload, - SessionPermissions memory sessionPerms, - uint8[] memory permissionIdxs - ) internal returns (bytes32 imageHash, bytes memory encodedSig) { - string memory topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - string memory sessionPermsJson = _sessionPermissionsToJSON(sessionPerms); - topology = PrimitivesRPC.sessionExplicitAdd(vm, sessionPermsJson, topology); - imageHash = PrimitivesRPC.sessionImageHash(vm, topology); - - uint256 callCount = payload.calls.length; - string[] memory callSignatures = new string[](callCount); - for (uint256 i; i < callCount; i++) { - string memory sessionSignature = - _signAndEncodeRSV(SessionSig.hashCallWithReplayProtection(payload, i), sessionWallet); - callSignatures[i] = _explicitCallSignatureToJSON(permissionIdxs[i], sessionSignature); - } - - address[] memory explicitSigners = new address[](1); - explicitSigners[0] = sessionWallet.addr; - address[] memory implicitSigners = new address[](0); - encodedSig = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - - return (imageHash, encodedSig); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/SessionSig.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/SessionSig.t.sol deleted file mode 100644 index adf77dc5c1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/SessionSig.t.sol +++ /dev/null @@ -1,1020 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Vm } from "forge-std/Test.sol"; -import { SessionTestBase } from "test/extensions/sessions/SessionTestBase.sol"; -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; - -import { SessionErrors } from "src/extensions/sessions/SessionErrors.sol"; -import { SessionSig } from "src/extensions/sessions/SessionSig.sol"; -import { SessionPermissions } from "src/extensions/sessions/explicit/IExplicitSessionManager.sol"; -import { ParameterOperation, ParameterRule, Permission } from "src/extensions/sessions/explicit/Permission.sol"; - -import { Attestation, AuthData, LibAttestation } from "src/extensions/sessions/implicit/Attestation.sol"; -import { Payload } from "src/modules/Payload.sol"; - - -using LibAttestation for Attestation; - -contract SessionSigHarness { - - function recover( - Payload.Decoded calldata payload, - bytes calldata signature - ) external view returns (SessionSig.DecodedSignature memory) { - return SessionSig.recoverSignature(payload, signature); - } - - function recoverConfiguration( - bytes calldata encoded - ) external pure returns (SessionSig.DecodedSignature memory, bool hasBlacklist) { - return SessionSig.recoverConfiguration(encoded); - } - -} - -contract SessionSigTest is SessionTestBase { - - SessionSigHarness internal harness; - Vm.Wallet internal sessionWallet; - Vm.Wallet internal identityWallet; - - function setUp() public { - harness = new SessionSigHarness(); - sessionWallet = vm.createWallet("session"); - identityWallet = vm.createWallet("identity"); - } - - function testHashCallCollision( - uint256 chainId, - Payload.Decoded memory payload1, - Payload.Decoded memory payload2 - ) public { - vm.assume(payload1.calls.length > 0); - vm.assume(payload2.calls.length > 0); - chainId = bound(chainId, 1, 2 ** 26 - 1); - vm.chainId(chainId); - - uint256 maxCalls = 10; - - if (payload1.calls.length > maxCalls) { - Payload.Call[] memory payload1Calls = payload1.calls; - assembly { - mstore(payload1Calls, maxCalls) - } - payload1.calls = payload1Calls; - } - - if (payload2.calls.length > maxCalls) { - Payload.Call[] memory payload2Calls = payload2.calls; - assembly { - mstore(payload2Calls, maxCalls) - } - payload2.calls = payload2Calls; - } - - for (uint256 i = 0; i < payload1.calls.length; i++) { - Payload.Call memory call1 = payload1.calls[i]; - for (uint256 j = 0; j < payload2.calls.length; j++) { - Payload.Call memory call2 = payload2.calls[j]; - - if ( - i == j && call1.to == call2.to && keccak256(call1.data) == keccak256(call2.data) - && call1.gasLimit == call2.gasLimit && call1.delegateCall == call2.delegateCall - && call1.onlyFallback == call2.onlyFallback && call1.behaviorOnError == call2.behaviorOnError - && payload1.space == payload2.space && payload1.nonce == payload2.nonce - && payload1.noChainId == payload2.noChainId - ) { - // The allowed collision case - continue; - } - - bytes32 callHash1 = SessionSig.hashCallWithReplayProtection(payload1, i); - bytes32 callHash2 = SessionSig.hashCallWithReplayProtection(payload2, j); - assertNotEq(callHash1, callHash2, "Call hashes should be different"); - } - } - } - - function testSingleExplicitSignature( - bool useChainId - ) public { - Payload.Decoded memory payload = _buildPayload(1); - { - payload.calls[0] = Payload.Call({ - to: address(0xBEEF), - value: 123, - data: "test", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - } - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: useChainId ? block.chainid : 0, - valueLimit: 1000, - deadline: 2000, - permissions: new Permission[](1) - }); - { - sessionPerms.permissions[0] = Permission({ target: address(0xBEEF), rules: new ParameterRule[](1) }); - sessionPerms.permissions[0].rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(0), - offset: 0, - mask: bytes32(0) - }); - } - - // Create the topology from the CLI. - string memory topology; - { - topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - string memory sessionPermsJson = _sessionPermissionsToJSON(sessionPerms); - topology = PrimitivesRPC.sessionExplicitAdd(vm, sessionPermsJson, topology); - } - - // Sign the payload. - string memory callSignature; - { - uint8 permissionIdx = 0; - bytes32 callHash = SessionSig.hashCallWithReplayProtection(payload, 0); - string memory sessionSignature = _signAndEncodeRSV(callHash, sessionWallet); - callSignature = _explicitCallSignatureToJSON(permissionIdx, sessionSignature); - } - - // Construct the encoded signature. - bytes memory encoded; - { - string[] memory callSignatures = new string[](1); - callSignatures[0] = callSignature; - address[] memory explicitSigners = new address[](1); - explicitSigners[0] = sessionWallet.addr; - address[] memory implicitSigners = new address[](0); - encoded = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - } - - // Recover and validate. - { - SessionSig.DecodedSignature memory sig = harness.recover(payload, encoded); - assertEq(sig.callSignatures.length, 1, "Call signatures length"); - SessionSig.CallSignature memory callSig = sig.callSignatures[0]; - assertFalse(callSig.isImplicit, "Call should be explicit"); - assertEq(callSig.sessionSigner, sessionWallet.addr, "Recovered session signer"); - assertEq(sig.implicitBlacklist.length, 0, "Blacklist should be empty"); - assertEq(sig.sessionPermissions.length, 1, "Session permissions length"); - assertEq(sig.sessionPermissions[0].signer, sessionWallet.addr, "Session permission signer"); - - bytes32 imageHash = PrimitivesRPC.sessionImageHash(vm, topology); - assertEq(sig.imageHash, imageHash, "Image hash"); - } - } - - function testSingleImplicitSignature( - Attestation memory attestation - ) public { - attestation.approvedSigner = sessionWallet.addr; - attestation.authData.redirectUrl = "https://example.com"; // Normalise for safe JSONify - attestation.authData.issuedAt = uint64(bound(attestation.authData.issuedAt, 0, block.timestamp)); - - Payload.Decoded memory payload = _buildPayload(1); - { - payload.calls[0] = Payload.Call({ - to: address(0xBEEF), - value: 123, - data: "test", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - } - - // Sign the payload. - string memory callSignature = _createImplicitCallSignature(payload, 0, sessionWallet, identityWallet, attestation); - - // Create the topology from the CLI. - string memory topology; - { - topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - } - - // Create the encoded signature. - bytes memory encoded; - { - string[] memory callSignatures = new string[](1); - callSignatures[0] = callSignature; - address[] memory explicitSigners = new address[](0); - address[] memory implicitSigners = new address[](1); - implicitSigners[0] = sessionWallet.addr; - encoded = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - } - - // Recover and validate. - { - SessionSig.DecodedSignature memory sig = harness.recover(payload, encoded); - assertEq(sig.callSignatures.length, 1, "Call signatures length"); - SessionSig.CallSignature memory callSig = sig.callSignatures[0]; - assertTrue(callSig.isImplicit, "Call should be implicit"); - assertEq(callSig.attestation.approvedSigner, sessionWallet.addr, "Recovered attestation signer"); - assertEq(sig.implicitBlacklist.length, 0, "Blacklist should be empty"); - assertEq(sig.sessionPermissions.length, 0, "Session permissions should be empty"); - - bytes32 imageHash = PrimitivesRPC.sessionImageHash(vm, topology); - assertEq(sig.imageHash, imageHash, "Image hash"); - } - } - - function testMultipleImplicitSignatures( - Attestation memory attestation - ) public { - attestation.approvedSigner = sessionWallet.addr; - attestation.authData.redirectUrl = "https://example.com"; // Normalise for safe JSONify - attestation.authData.issuedAt = uint64(bound(attestation.authData.issuedAt, 0, block.timestamp)); - - Payload.Decoded memory payload = _buildPayload(2); - { - payload.calls[0] = Payload.Call({ - to: address(0xBEEF), - value: 123, - data: "test1", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - payload.calls[1] = Payload.Call({ - to: address(0xCAFE), - value: 456, - data: "test2", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - } - - // Create attestations and signatures for both calls - string[] memory callSignatures = new string[](2); - { - callSignatures[0] = _createImplicitCallSignature(payload, 0, sessionWallet, identityWallet, attestation); - callSignatures[1] = _createImplicitCallSignature(payload, 1, sessionWallet, identityWallet, attestation); - } - - // Create the topology - string memory topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - - // Create the encoded signature - bytes memory encoded; - { - address[] memory explicitSigners = new address[](0); - address[] memory implicitSigners = new address[](1); - implicitSigners[0] = sessionWallet.addr; - encoded = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - } - - // Recover and validate - { - SessionSig.DecodedSignature memory sig = harness.recover(payload, encoded); - assertEq(sig.callSignatures.length, 2, "Call signatures length"); - - for (uint256 i = 0; i < sig.callSignatures.length; i++) { - SessionSig.CallSignature memory callSig = sig.callSignatures[i]; - assertTrue(callSig.isImplicit, "Call should be implicit"); - assertEq(callSig.attestation.approvedSigner, sessionWallet.addr, "Recovered attestation signer"); - } - - assertEq(sig.implicitBlacklist.length, 0, "Blacklist should be empty"); - assertEq(sig.sessionPermissions.length, 0, "Session permissions should be empty"); - - bytes32 imageHash = PrimitivesRPC.sessionImageHash(vm, topology); - assertEq(sig.imageHash, imageHash, "Image hash"); - } - } - - function testMultipleExplicitSignatures( - bool useChainId - ) public { - // Create a second session wallet - Vm.Wallet memory sessionWallet2 = vm.createWallet("session2"); - - Payload.Decoded memory payload = _buildPayload(2); - { - payload.calls[0] = Payload.Call({ - to: address(0xBEEF), - value: 123, - data: "test1", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - payload.calls[1] = Payload.Call({ - to: address(0xCAFE), - value: 456, - data: "test2", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - } - - // Create session permissions for both calls with different signers - SessionPermissions[] memory sessionPermsArray = new SessionPermissions[](2); - { - sessionPermsArray[0] = - _createSessionPermissions(address(0xBEEF), useChainId ? block.chainid : 0, 1000, 2000, sessionWallet.addr); - sessionPermsArray[1] = - _createSessionPermissions(address(0xCAFE), useChainId ? block.chainid : 0, 1000, 2000, sessionWallet2.addr); - } - - // Create the topology from the CLI - string memory topology; - { - topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - for (uint256 i = 0; i < sessionPermsArray.length; i++) { - string memory sessionPermsJson = _sessionPermissionsToJSON(sessionPermsArray[i]); - topology = PrimitivesRPC.sessionExplicitAdd(vm, sessionPermsJson, topology); - } - } - - // Sign the payloads and create call signatures with different signers - string[] memory callSignatures = new string[](2); - { - // First call signed by sessionWallet - bytes32 callHash = SessionSig.hashCallWithReplayProtection(payload, 0); - string memory sessionSignature1 = _signAndEncodeRSV(callHash, sessionWallet); - callSignatures[0] = _explicitCallSignatureToJSON(0, sessionSignature1); - - // Second call signed by sessionWallet2 - callHash = SessionSig.hashCallWithReplayProtection(payload, 1); - string memory sessionSignature2 = _signAndEncodeRSV(callHash, sessionWallet2); - callSignatures[1] = _explicitCallSignatureToJSON(1, sessionSignature2); - } - - // Construct the encoded signature - bytes memory encoded; - { - address[] memory explicitSigners = new address[](2); - explicitSigners[0] = sessionWallet.addr; - explicitSigners[1] = sessionWallet2.addr; - address[] memory implicitSigners = new address[](0); - encoded = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - } - - // Recover and validate - { - SessionSig.DecodedSignature memory sig = harness.recover(payload, encoded); - assertEq(sig.callSignatures.length, 2, "Call signatures length"); - - // Verify first signature - assertFalse(sig.callSignatures[0].isImplicit, "First call should be explicit"); - assertEq(sig.callSignatures[0].sessionSigner, sessionWallet.addr, "First session signer"); - - // Verify second signature - assertFalse(sig.callSignatures[1].isImplicit, "Second call should be explicit"); - assertEq(sig.callSignatures[1].sessionSigner, sessionWallet2.addr, "Second session signer"); - - assertEq(sig.implicitBlacklist.length, 0, "Blacklist should be empty"); - assertEq(sig.sessionPermissions.length, 2, "Session permissions length"); - bool found0 = false; - bool found1 = false; - for (uint256 i = 0; i < sig.sessionPermissions.length; i++) { - if (sig.sessionPermissions[i].signer == sessionWallet.addr) { - found0 = true; - } - if (sig.sessionPermissions[i].signer == sessionWallet2.addr) { - found1 = true; - } - } - assertTrue(found0, "Session permission signer 0 not found"); - assertTrue(found1, "Session permission signer 1 not found"); - - bytes32 imageHash = PrimitivesRPC.sessionImageHash(vm, topology); - assertEq(sig.imageHash, imageHash, "Image hash"); - } - } - - function testRecover_invalidSessionSigner( - bool useChainId - ) public { - Payload.Decoded memory payload = _buildPayload(1); - { - payload.calls[0] = Payload.Call({ - to: address(0xBEEF), - value: 123, - data: "test", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - } - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: useChainId ? block.chainid : 0, - valueLimit: 1000, - deadline: 2000, - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: address(0xBEEF), rules: new ParameterRule[](0) }); - - // Create the topology from the CLI. - string memory topology; - { - topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - string memory sessionPermsJson = _sessionPermissionsToJSON(sessionPerms); - topology = PrimitivesRPC.sessionExplicitAdd(vm, sessionPermsJson, topology); - } - - // Generate an invalid session signature - string memory sessionSignature = - "0x0000000000000000000000000000000000000000000000000000000000000000:0x0000000000000000000000000000000000000000000000000000000000000000:0"; - string memory callSignature = _explicitCallSignatureToJSON(0, sessionSignature); - - // Construct the encoded signature. - bytes memory encoded; - { - string[] memory callSignatures = new string[](1); - callSignatures[0] = callSignature; - address[] memory explicitSigners = new address[](1); - explicitSigners[0] = sessionWallet.addr; - address[] memory implicitSigners = new address[](0); - encoded = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - } - - // Recover and validate. - vm.expectRevert(abi.encodeWithSelector(SessionErrors.InvalidSessionSigner.selector, address(0))); - harness.recover(payload, encoded); - } - - function testRecover_invalidIdentitySigner_unset() public { - // Create a topology with an invalid identity signer - string memory topology = PrimitivesRPC.sessionEmpty(vm, address(0)); - Payload.Decoded memory payload = _buildPayload(1); - payload.calls[0] = Payload.Call({ - to: address(0xBEEF), - value: 123, - data: "test", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Create a call signature - bytes memory encoded = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, new string[](0), new address[](0), new address[](0)); - - // Recover the signature - vm.expectRevert(SessionErrors.InvalidIdentitySigner.selector); - harness.recover(payload, encoded); - } - - function testRecover_invalidIdentitySigner_noMatchAttestationSigner( - Attestation memory attestation - ) public { - attestation.approvedSigner = sessionWallet.addr; - attestation.authData.redirectUrl = "https://example.com"; // Normalise for safe JSONify - attestation.authData.issuedAt = uint64(bound(attestation.authData.issuedAt, 0, block.timestamp)); - - // Create a topology with an invalid identity signer - string memory topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - Payload.Decoded memory payload = _buildPayload(1); - payload.calls[0] = Payload.Call({ - to: address(0xBEEF), - value: 123, - data: "test", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - Vm.Wallet memory attestationWallet = vm.createWallet("attestation"); - - // Sign the payload. - string memory callSignature = - _createImplicitCallSignature(payload, 0, sessionWallet, attestationWallet, attestation); - - // Create a call signature - string[] memory callSignatures = new string[](1); - callSignatures[0] = callSignature; - address[] memory implicitSigners = new address[](1); - implicitSigners[0] = sessionWallet.addr; - bytes memory encoded = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, new address[](0), implicitSigners); - - // Recover the signature - vm.expectRevert(SessionErrors.InvalidIdentitySigner.selector); - harness.recover(payload, encoded); - } - - function testRecover_invalidIdentitySigner_noSignersEncoded( - Attestation memory attestation - ) public { - attestation.approvedSigner = sessionWallet.addr; - attestation.authData.redirectUrl = "https://example.com"; // Normalise for safe JSONify - attestation.authData.issuedAt = uint64(bound(attestation.authData.issuedAt, 0, block.timestamp)); - - // Create a topology with an invalid identity signer - string memory topology = PrimitivesRPC.sessionEmpty(vm, address(0)); - Payload.Decoded memory payload = _buildPayload(1); - payload.calls[0] = Payload.Call({ - to: address(0xBEEF), - value: 123, - data: "test", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - Vm.Wallet memory attestationWallet = vm.createWallet("attestation"); - - // Sign the payload. - string memory callSignature = - _createImplicitCallSignature(payload, 0, sessionWallet, attestationWallet, attestation); - - // Create a call signature - string[] memory callSignatures = new string[](1); - callSignatures[0] = callSignature; - bytes memory encoded = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, new address[](0), new address[](0)); - - // Recover the signature - vm.expectRevert(SessionErrors.InvalidIdentitySigner.selector); - harness.recover(payload, encoded); - } - - function testRecover_invalidBlacklist_requiredForImplicitSigner( - Attestation memory attestation - ) public { - attestation.approvedSigner = sessionWallet.addr; - attestation.authData.redirectUrl = "https://example.com"; // Normalise for safe JSONify - attestation.authData.issuedAt = uint64(bound(attestation.authData.issuedAt, 0, block.timestamp)); - - string memory topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - Payload.Decoded memory payload = _buildPayload(1); - payload.calls[0] = Payload.Call({ - to: address(0xBEEF), - value: 123, - data: "test", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Call encodeCallSignatures with empty call signatures to encode the topology - bytes memory encodedTopologyWithSize = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, new string[](0), new address[](0), new address[](0)); - assertGt(encodedTopologyWithSize.length, 4, "Encoded signature should not be empty"); - - // Strip the last byte (attestation count) - bytes memory encoded = new bytes(encodedTopologyWithSize.length - 1); - for (uint256 i = 0; i < encoded.length; i++) { - encoded[i] = encodedTopologyWithSize[i]; - } - - // Encode the attestation and signature - bytes32 attestationHash = attestation.toHash(); - bytes memory compactSignature = signRSVCompact(attestationHash, identityWallet); - encoded = abi.encodePacked(encoded, uint8(1), LibAttestation.toPacked(attestation), compactSignature); - - // We don't bother encoding the call signatures as will fail before then - - // Recover the signature - vm.expectRevert(SessionErrors.InvalidBlacklist.selector); - harness.recover(payload, encoded); - } - - function testRecover_invalidAttestationIndex(Attestation memory attestation, uint256 count, uint256 index) public { - attestation.approvedSigner = sessionWallet.addr; - attestation.authData.redirectUrl = "https://example.com"; // Normalise for safe JSONify - count = bound(count, 1, 10); - index = bound(index, count + 1, type(uint8).max / 2); // /2 as top bit used in flag - - string memory topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - Payload.Decoded memory payload = _buildPayload(1); - payload.calls[0] = Payload.Call({ - to: address(0xBEEF), - value: 123, - data: "test", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Call encodeCallSignatures with empty call signatures to encode the topology - address[] memory implicitSigners = new address[](1); - implicitSigners[0] = sessionWallet.addr; - bytes memory encodedTopologyWithSize = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, new string[](0), new address[](0), implicitSigners); - assertGt(encodedTopologyWithSize.length, 4, "Encoded signature should not be empty"); - - // Strip the last byte (attestation count) - bytes memory encoded = new bytes(encodedTopologyWithSize.length - 1); - for (uint256 i = 0; i < encoded.length; i++) { - encoded[i] = encodedTopologyWithSize[i]; - } - - // Encode the attestations and signatures - bytes32 attestationHash = attestation.toHash(); - bytes memory compactSignature = signRSVCompact(attestationHash, identityWallet); - encoded = abi.encodePacked(encoded, uint8(count)); - for (uint256 i = 0; i < count; i++) { - encoded = abi.encodePacked(encoded, LibAttestation.toPacked(attestation), compactSignature); - } - - // Encode the call signature with invalid index - uint8 implicitFlag = uint8(index | 0x80); - encoded = abi.encodePacked(encoded, implicitFlag); - // Ignore encoding the signature as will fail before then - - // Recover the signature - vm.expectRevert(SessionErrors.InvalidAttestation.selector); - harness.recover(payload, encoded); - } - - function testConfiguration_largeBlacklist( - address[] memory blacklist - ) public { - vm.assume(blacklist.length > 0); - if (blacklist.length < 0x0f) { - address[] memory largerBlacklist = new address[](0x0f); - for (uint256 i = 0; i < largerBlacklist.length; i++) { - largerBlacklist[i] = blacklist[i % blacklist.length]; - } - blacklist = largerBlacklist; - } else if (blacklist.length > 0xff) { - // Truncate size to max 0xff - assembly { - mstore(blacklist, 0xff) - } - } - - // Remove duplicates - { - address[] memory uniqueBlacklist = new address[](blacklist.length); - uint256 uniqueBlacklistIndex = 0; - for (uint256 i = 0; i < blacklist.length; i++) { - bool found = false; - for (uint256 j = 0; j < uniqueBlacklistIndex; j++) { - if (blacklist[i] == uniqueBlacklist[j]) { - found = true; - break; - } - } - if (!found) { - uniqueBlacklist[uniqueBlacklistIndex++] = blacklist[i]; - } - } - blacklist = uniqueBlacklist; - assembly { - mstore(blacklist, uniqueBlacklistIndex) - } - } - - // Create a topology - string memory topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - for (uint256 i = 0; i < blacklist.length; i++) { - topology = PrimitivesRPC.sessionImplicitAddBlacklistAddress(vm, topology, blacklist[i]); - } - - // Call encodeCallSignatures with empty call signatures to encode the topology - address[] memory implicitSigners = new address[](1); - implicitSigners[0] = sessionWallet.addr; - bytes memory encoded = PrimitivesRPC.sessionEncodeTopology(vm, topology); - - // Recover the configuration - (SessionSig.DecodedSignature memory sig, bool hasBlacklist) = harness.recoverConfiguration(encoded); - assertEq(sig.implicitBlacklist.length, blacklist.length, "Implicit blacklist length"); - assertEq(hasBlacklist, true, "Blacklist should be present"); - } - - function testConfiguration_duplicateBlacklistNodes( - address[5] memory fiveBlacklists, - uint8 size - ) public { - size = uint8(bound(size, 0, 5)); - address[] memory blacklist = new address[](size); - for (uint256 i = 0; i < size; i++) { - blacklist[i] = fiveBlacklists[i]; - } - - _sortAddressesMemory(blacklist); - - bytes memory encoded = new bytes(0); - for (uint256 i = 0; i < 2; i++) { - // Flag is top 4 bits 0x03, lower 4 bits are blacklist count - uint8 blacklistFlag = uint8(0x30) | uint8(blacklist.length); - encoded = abi.encodePacked(encoded, blacklistFlag); - for (uint256 j = 0; j < blacklist.length; j++) { - encoded = abi.encodePacked(encoded, blacklist[j]); - } - } - - // Recover the configuration - vm.expectRevert(SessionErrors.InvalidBlacklist.selector); - harness.recoverConfiguration(encoded); - } - - function testConfiguration_duplicateBlacklistNodes_inBranch( - address[5] memory fiveBlacklists, - uint8 size - ) public { - size = uint8(bound(size, 0, 5)); - address[] memory blacklist = new address[](size); - for (uint256 i = 0; i < size; i++) { - blacklist[i] = fiveBlacklists[i]; - } - - _sortAddressesMemory(blacklist); - - bytes memory encoded = new bytes(0); - // Blacklist encoding - bytes memory blacklistEncoded = new bytes(0); - uint8 blacklistFlag = uint8(0x30) | uint8(blacklist.length); - blacklistEncoded = abi.encodePacked(blacklistEncoded, blacklistFlag); - for (uint256 j = 0; j < blacklist.length; j++) { - blacklistEncoded = abi.encodePacked(blacklistEncoded, blacklist[j]); - } - - // Branch encoding - uint8 branchSize = uint8(blacklistEncoded.length); - uint8 branchFlag = uint8(0x21); - encoded = abi.encodePacked(encoded, branchFlag, branchSize, blacklistEncoded); - - // Two of these branches - encoded = abi.encodePacked(encoded, encoded); - - // Recover the configuration - vm.expectRevert(SessionErrors.InvalidBlacklist.selector); - harness.recoverConfiguration(encoded); - } - - function testConfiguration_duplicateIdentityNodes(address identitySigner1, address identitySigner2) public { - vm.assume(identitySigner1 != address(0)); - vm.assume(identitySigner2 != address(0)); - - bytes memory encoded = abi.encodePacked(uint8(0x40), identitySigner1); - encoded = abi.encodePacked(encoded, uint8(0x40), identitySigner2); - - // Recover the configuration - vm.expectRevert(SessionErrors.InvalidIdentitySigner.selector); - harness.recoverConfiguration(encoded); - } - - function testConfiguration_duplicateIdentityNodes_inBranch( - address identitySigner - ) public { - vm.assume(identitySigner != address(0)); - - // Identity signer encoding - bytes memory identityEncoded = abi.encodePacked(uint8(0x40), identitySigner); - - // Branch encoding - uint8 branchSize = uint8(identityEncoded.length); - uint8 branchFlag = uint8(0x21); - bytes memory encoded = abi.encodePacked(branchFlag, branchSize, identityEncoded); - - // Two of these branches - encoded = abi.encodePacked(encoded, encoded); - - // Recover the configuration - vm.expectRevert(SessionErrors.InvalidIdentitySigner.selector); - harness.recoverConfiguration(encoded); - } - - function testConfiguration_invalidNode( - uint8 invalidNodeFlag - ) public { - invalidNodeFlag = uint8(bound(invalidNodeFlag, 0x05, 0x0f)); - - bytes memory encoded = abi.encodePacked(invalidNodeFlag << 4); - - // Recover the configuration - vm.expectRevert(abi.encodeWithSelector(SessionErrors.InvalidNodeType.selector, invalidNodeFlag)); - harness.recoverConfiguration(encoded); - } - - function testLargeTopology( - address[] memory explicitSigners, - uint256 signersIncludeCount, - bool includeImplicitSigner, - address[] memory implicitBlacklist - ) public { - _sortAddressesMemory(implicitBlacklist); - - // Reduce size to max 20 - if (explicitSigners.length > 20) { - assembly { - mstore(explicitSigners, 20) - } - } - for (uint256 i = 0; i < explicitSigners.length; i++) { - vm.assume(explicitSigners[i] != address(0)); - // Ensure there are no duplicates. - for (uint256 j = 0; j < explicitSigners.length; j++) { - if (i != j) { - vm.assume(explicitSigners[i] != explicitSigners[j]); - } - } - } - if (implicitBlacklist.length > 5) { - assembly { - mstore(implicitBlacklist, 5) - } - } - // Ensure no duplicates for the implicit blacklist - for (uint256 i = 0; i < implicitBlacklist.length; i++) { - for (uint256 j = 0; j < implicitBlacklist.length; j++) { - if (i != j) { - vm.assume(implicitBlacklist[i] != implicitBlacklist[j]); - } - } - } - signersIncludeCount = bound(signersIncludeCount, 0, explicitSigners.length); - - // Add session permissions and blacklist to the topology - SessionPermissions memory sessionPerms; - string memory topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - for (uint256 i = 0; i < explicitSigners.length; i++) { - sessionPerms.signer = explicitSigners[i]; - string memory sessionPermsJson = _sessionPermissionsToJSON(sessionPerms); - topology = PrimitivesRPC.sessionExplicitAdd(vm, sessionPermsJson, topology); - } - for (uint256 i = 0; i < implicitBlacklist.length; i++) { - topology = PrimitivesRPC.sessionImplicitAddBlacklistAddress(vm, topology, implicitBlacklist[i]); - } - - // Set signers to include in the configuration - assembly { - mstore(explicitSigners, signersIncludeCount) - } - address[] memory implicitSigners = new address[](includeImplicitSigner ? 1 : 0); - if (includeImplicitSigner) { - implicitSigners[0] = sessionWallet.addr; - } - // Call encodeCallSignatures with empty call signatures to encode the topology (minimised) - bytes memory encoded = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, new string[](0), explicitSigners, implicitSigners); - assertGt(encoded.length, 4, "Encoded signature should not be empty"); - - // Strip the first 3 bytes (size), and last byte (attestation count) - bytes memory encodedWithoutSize = new bytes(encoded.length - 4); - for (uint256 i = 0; i < encodedWithoutSize.length; i++) { - encodedWithoutSize[i] = encoded[i + 3]; - } - - // Recover the configuration - (SessionSig.DecodedSignature memory sig, bool hasBlacklist) = harness.recoverConfiguration(encodedWithoutSize); - assertEq(sig.identitySigner, identityWallet.addr, "Identity signer"); - assertEq(sig.sessionPermissions.length, explicitSigners.length, "Session permissions length"); // Truncated list - for (uint256 i = 0; i < explicitSigners.length; i++) { - bool found = false; - for (uint256 j = 0; j < sig.sessionPermissions.length; j++) { - if (sig.sessionPermissions[j].signer == explicitSigners[i]) { - found = true; - break; - } - } - assertTrue(found, "Session permission signer not found"); - } - if (includeImplicitSigner) { - assertEq(hasBlacklist, includeImplicitSigner, "Blacklist not included with implicit signer"); - assertEq(sig.implicitBlacklist.length, implicitBlacklist.length, "Implicit blacklist length"); - for (uint256 i = 0; i < implicitBlacklist.length; i++) { - bool found = false; - for (uint256 j = 0; j < sig.implicitBlacklist.length; j++) { - if (sig.implicitBlacklist[j] == implicitBlacklist[i]) { - found = true; - break; - } - } - assertTrue(found, "Implicit blacklist address not found"); - } - } - } - - function testAttestationOptimisation(Attestation memory attestation1, Attestation memory attestation2) public { - // Create a second session wallet - Vm.Wallet memory sessionWallet2 = vm.createWallet("session2"); - - attestation1.approvedSigner = sessionWallet.addr; - attestation2.approvedSigner = sessionWallet2.addr; - attestation1.authData.redirectUrl = "https://example.com"; // Normalise for safe JSONify - attestation2.authData.redirectUrl = "https://example.com"; // Normalise for safe JSONify - - // Create a payload with 2 calls - Payload.Decoded memory payload = _buildPayload(2); - { - payload.calls[0] = Payload.Call({ - to: address(0xBEEF), - value: 123, - data: "test1", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - payload.calls[1] = Payload.Call({ - to: address(0xCAFE), - value: 456, - data: "test2", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - } - - // Create 2 call signatures for the same session wallet and attestation - string memory callSignatureA = _createImplicitCallSignature(payload, 0, sessionWallet, identityWallet, attestation1); - string memory callSignatureB = _createImplicitCallSignature(payload, 1, sessionWallet, identityWallet, attestation1); - - // Create the second call signature for the second session wallet and attestation - string memory callSignatureC = - _createImplicitCallSignature(payload, 1, sessionWallet2, identityWallet, attestation2); - - // Create a topology - string memory topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - - // Encode the call signatures for single session wallet - address[] memory implicitSigners = new address[](1); - implicitSigners[0] = sessionWallet.addr; - string[] memory callSignatures = new string[](2); - callSignatures[0] = callSignatureA; - callSignatures[1] = callSignatureB; - bytes memory encoded = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, new address[](0), implicitSigners); - - // Encode the call signatures for both session wallets - implicitSigners = new address[](2); - implicitSigners[0] = sessionWallet.addr; - implicitSigners[1] = sessionWallet2.addr; - callSignatures = new string[](2); - callSignatures[0] = callSignatureA; - callSignatures[1] = callSignatureC; - bytes memory encoded2 = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, new address[](0), implicitSigners); - - // Ensure the length of the calldata has been optimised when reusing the same attestation - assertLt( - encoded.length, encoded2.length, "Encoded call signatures should be shorter when reusing the same attestation" - ); - } - - function testEmptyPermissionsStructSize_direct( - address signer, - uint256 chainId, - uint256 valueLimit, - uint64 deadline - ) public view { - // Create an empty permissions struct - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: signer, - chainId: chainId, - valueLimit: valueLimit, - deadline: deadline, - permissions: new Permission[](0) - }); - - // Directly encode the permissions struct - bytes memory encoded = abi.encodePacked( - uint8(SessionSig.FLAG_PERMISSIONS), - sessionPerms.signer, - sessionPerms.chainId, - sessionPerms.valueLimit, - sessionPerms.deadline, - uint8(0) // empty permissions array length - ); - - // Verify the size is the minimum size - assertEq(encoded.length, SessionSig.MIN_ENCODED_PERMISSION_SIZE, "Incorrect size for empty permissions struct"); - - // Verify we can decode it back - (SessionSig.DecodedSignature memory sig,) = harness.recoverConfiguration(encoded); - assertEq(sig.sessionPermissions.length, 1, "Should have one permissions struct"); - assertEq(sig.sessionPermissions[0].signer, signer, "Signer should match"); - assertEq(sig.sessionPermissions[0].chainId, chainId, "Chain ID should match"); - assertEq(sig.sessionPermissions[0].valueLimit, valueLimit, "Value limit should match"); - assertEq(sig.sessionPermissions[0].deadline, deadline, "Deadline should match"); - assertEq(sig.sessionPermissions[0].permissions.length, 0, "Should have no permissions"); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/SessionTestBase.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/SessionTestBase.sol deleted file mode 100644 index 8a1ecb7035..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/SessionTestBase.sol +++ /dev/null @@ -1,209 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Test, Vm } from "forge-std/Test.sol"; - -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; -import { AdvTest } from "test/utils/TestUtils.sol"; - -import { SessionManager } from "src/extensions/sessions/SessionManager.sol"; -import { SessionSig } from "src/extensions/sessions/SessionSig.sol"; -import { SessionPermissions } from "src/extensions/sessions/explicit/IExplicitSessionManager.sol"; -import { ParameterOperation, ParameterRule, Permission } from "src/extensions/sessions/explicit/Permission.sol"; - -import { Attestation, LibAttestation } from "src/extensions/sessions/implicit/Attestation.sol"; -import { Payload } from "src/modules/Payload.sol"; - -abstract contract SessionTestBase is AdvTest { - - using LibAttestation for Attestation; - - address internal constant VALUE_TRACKING_ADDRESS = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE; - - function _signAndEncodeRSV(bytes32 hash, Vm.Wallet memory wallet) internal pure returns (string memory) { - (uint8 v, bytes32 r, bytes32 s) = vm.sign(wallet.privateKey, hash); - return string(abi.encodePacked(vm.toString(r), ":", vm.toString(s), ":", vm.toString(v))); - } - - /// @dev Helper to build a Payload.Decoded with a given number of calls. - function _buildPayload( - uint256 callCount - ) internal pure returns (Payload.Decoded memory payload) { - payload.kind = Payload.KIND_TRANSACTIONS; - payload.noChainId = true; - payload.space = 0; - payload.nonce = 0; - payload.parentWallets = new address[](0); - payload.calls = new Payload.Call[](callCount); - } - - function _sessionPermissionsToJSON( - SessionPermissions memory sessionPerms - ) internal pure returns (string memory) { - string memory json = '{"signer":"'; - json = string.concat(json, vm.toString(sessionPerms.signer)); - json = string.concat(json, '","chainId":"'); - json = string.concat(json, vm.toString(sessionPerms.chainId)); - json = string.concat(json, '","valueLimit":"'); - json = string.concat(json, vm.toString(sessionPerms.valueLimit)); - json = string.concat(json, '","deadline":"'); - json = string.concat(json, vm.toString(sessionPerms.deadline)); - json = string.concat(json, '","permissions":['); - for (uint256 i = 0; i < sessionPerms.permissions.length; i++) { - if (i > 0) { - json = string.concat(json, ","); - } - json = string.concat(json, _permissionToJSON(sessionPerms.permissions[i])); - } - json = string.concat(json, "]}"); - return json; - } - - function _permissionToJSON( - Permission memory permission - ) internal pure returns (string memory) { - string memory json = '{"target":"'; - json = string.concat(json, vm.toString(permission.target)); - json = string.concat(json, '","rules":['); - for (uint256 i = 0; i < permission.rules.length; i++) { - if (i > 0) { - json = string.concat(json, ","); - } - json = string.concat(json, _ruleToJSON(permission.rules[i])); - } - json = string.concat(json, "]}"); - return json; - } - - function _ruleToJSON( - ParameterRule memory rule - ) internal pure returns (string memory) { - string memory json = '{"cumulative":'; - json = string.concat(json, vm.toString(rule.cumulative)); - json = string.concat(json, ',"operation":'); - json = string.concat(json, vm.toString(uint8(rule.operation))); - json = string.concat(json, ',"value":"'); - json = string.concat(json, vm.toString(rule.value)); - json = string.concat(json, '","offset":"'); - json = string.concat(json, vm.toString(rule.offset)); - json = string.concat(json, '","mask":"'); - json = string.concat(json, vm.toString(rule.mask)); - json = string.concat(json, '"}'); - return json; - } - - function _attestationToJSON( - Attestation memory attestation - ) internal pure returns (string memory) { - string memory json = '{"approvedSigner":"'; - json = string.concat(json, vm.toString(attestation.approvedSigner)); - json = string.concat(json, '","identityType":"'); - json = string.concat(json, vm.toString(attestation.identityType)); - json = string.concat(json, '","issuerHash":"'); - json = string.concat(json, vm.toString(attestation.issuerHash)); - json = string.concat(json, '","audienceHash":"'); - json = string.concat(json, vm.toString(attestation.audienceHash)); - json = string.concat(json, '","authData":{"redirectUrl":"'); - json = string.concat(json, attestation.authData.redirectUrl); - json = string.concat(json, '","issuedAt":"'); - json = string.concat(json, vm.toString(attestation.authData.issuedAt)); - json = string.concat(json, '"},"applicationData":"'); - json = string.concat(json, vm.toString(attestation.applicationData)); - json = string.concat(json, '"}'); - return json; - } - - function _createImplicitCallSignature( - Payload.Decoded memory payload, - uint256 callIdx, - Vm.Wallet memory signer, - Vm.Wallet memory identitySigner, - Attestation memory attestation - ) internal view returns (string memory) { - bytes32 attestationHash = attestation.toHash(); - string memory identitySignature = _signAndEncodeRSV(attestationHash, identitySigner); - bytes32 callHash = SessionSig.hashCallWithReplayProtection(payload, callIdx); - string memory sessionSignature = _signAndEncodeRSV(callHash, signer); - return _implicitCallSignatureToJSON(attestation, sessionSignature, identitySignature); - } - - function _implicitCallSignatureToJSON( - Attestation memory attestation, - string memory sessionSignature, - string memory identitySignature - ) internal pure returns (string memory) { - string memory json = '{"attestation":'; - json = string.concat(json, _attestationToJSON(attestation)); - json = string.concat(json, ',"sessionSignature":"'); - json = string.concat(json, sessionSignature); - json = string.concat(json, '","identitySignature":"'); - json = string.concat(json, identitySignature); - json = string.concat(json, '"}'); - return json; - } - - function _explicitCallSignatureToJSON( - uint8 permissionIndex, - string memory sessionSignature - ) internal pure returns (string memory) { - string memory json = '{"permissionIndex":"'; - json = string.concat(json, vm.toString(permissionIndex)); - json = string.concat(json, '","sessionSignature":"'); - json = string.concat(json, sessionSignature); - json = string.concat(json, '"}'); - return json; - } - - function _createSessionPermissions( - address target, - uint256 chainId, - uint256 valueLimit, - uint64 deadline, - address signer - ) internal pure returns (SessionPermissions memory) { - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: signer, - chainId: chainId, - valueLimit: valueLimit, - deadline: deadline, - permissions: new Permission[](1) - }); - - sessionPerms.permissions[0] = Permission({ target: target, rules: new ParameterRule[](1) }); - sessionPerms.permissions[0].rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(0), - offset: 0, - mask: bytes32(0) - }); - - return sessionPerms; - } - - // Convert a single SessionPermissions struct into an array. - function _toArray( - SessionPermissions memory perm - ) internal pure returns (SessionPermissions[] memory) { - SessionPermissions[] memory arr = new SessionPermissions[](1); - arr[0] = perm; - return arr; - } - - /// @notice Sorts an array of addresses in memory. - /// @param addresses The array of addresses to sort. - function _sortAddressesMemory( - address[] memory addresses - ) internal pure { - // Sort the addresses using bubble sort. - for (uint256 i = 0; i < addresses.length; i++) { - for (uint256 j = 0; j < addresses.length - i - 1; j++) { - if (addresses[j] > addresses[j + 1]) { - address temp = addresses[j]; - addresses[j] = addresses[j + 1]; - addresses[j + 1] = temp; - } - } - } - } -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/explicit/ExplicitSessionManager.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/explicit/ExplicitSessionManager.t.sol deleted file mode 100644 index c1e8784fa8..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/explicit/ExplicitSessionManager.t.sol +++ /dev/null @@ -1,866 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Vm } from "forge-std/Test.sol"; -import { SessionTestBase } from "test/extensions/sessions/SessionTestBase.sol"; - -import { SessionErrors } from "src/extensions/sessions/SessionErrors.sol"; -import { ExplicitSessionManager } from "src/extensions/sessions/explicit/ExplicitSessionManager.sol"; -import { IExplicitSessionManager } from "src/extensions/sessions/explicit/IExplicitSessionManager.sol"; -import { SessionPermissions, SessionUsageLimits } from "src/extensions/sessions/explicit/IExplicitSessionManager.sol"; -import { - ParameterOperation, ParameterRule, Permission, UsageLimit -} from "src/extensions/sessions/explicit/Permission.sol"; -import { Payload } from "src/modules/Payload.sol"; - -contract ExplicitSessionManagerTest is SessionTestBase { - - ExplicitSessionManagerHarness harness; - address wallet; - Vm.Wallet sessionWallet; - bytes32 constant SELECTOR_MASK = bytes32(bytes4(0xffffffff)); - - modifier supportChainId( - uint64 chainId - ) { - if (chainId != 0) { - vm.chainId(chainId); - } - _; - } - - function setUp() public { - harness = new ExplicitSessionManagerHarness(); - wallet = vm.createWallet("wallet").addr; - sessionWallet = vm.createWallet("session"); - } - - function test_validateExplicitCall( - uint64 chainId, - address target, - bytes4 selector, - bytes memory callData - ) public supportChainId(chainId) { - vm.assume(target != address(harness)); - // Build a payload with one call. - Payload.Decoded memory payload = _buildPayload(1); - // Prepend the selector to the call data. - callData = abi.encodePacked(selector, callData); - payload.calls[0] = Payload.Call({ - to: target, - value: 0, - data: callData, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Create SessionPermissions with one Permission. - SessionPermissions memory perms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: chainId, - valueLimit: 0, // no native token usage for this test - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - // Allow calls to the target if the selector matches.. - perms.permissions[0] = Permission({ target: target, rules: new ParameterRule[](1) }); - perms.permissions[0].rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(selector), - offset: 0, - mask: SELECTOR_MASK - }); - - // Prepare initial session usage limits. - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 0; - - // Convert our single SessionPermissions into an array. - SessionPermissions[] memory permsArr = _toArray(perms); - - // Call the internal explicit call validator. - SessionUsageLimits memory newUsage = harness.validateExplicitCall( - payload, - 0, // call index - wallet, - sessionWallet.addr, - permsArr, - 0, // permission index - usage - ); - - // Since the call value is 0, expect totalValueUsed to remain 0. - assertEq(newUsage.totalValueUsed, 0, "totalValueUsed should be 0"); - } - - function test_validateExplicitCall_invalidChainId( - uint64 chainId, - uint256 invalidChainId, - address target, - bytes4 selector, - bytes memory callData - ) public supportChainId(chainId) { - invalidChainId = bound(invalidChainId, 1, type(uint256).max); - vm.assume(invalidChainId != chainId); - vm.assume(target != address(harness)); - // Build a payload with one call. - Payload.Decoded memory payload = _buildPayload(1); - // Prepend the selector to the call data. - callData = abi.encodePacked(selector, callData); - payload.calls[0] = Payload.Call({ - to: target, - value: 0, - data: callData, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Create SessionPermissions with one Permission. - SessionPermissions memory perms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: invalidChainId, - valueLimit: 0, // no native token usage for this test - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - // Allow calls to the target if the selector matches.. - perms.permissions[0] = Permission({ target: target, rules: new ParameterRule[](1) }); - perms.permissions[0].rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(selector), - offset: 0, - mask: SELECTOR_MASK - }); - - // Prepare initial session usage limits. - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 0; - - // Convert our single SessionPermissions into an array. - SessionPermissions[] memory permsArr = _toArray(perms); - - // Call the internal explicit call validator. - vm.expectRevert(abi.encodeWithSelector(SessionErrors.InvalidChainId.selector, invalidChainId)); - harness.validateExplicitCall(payload, 0, wallet, sessionWallet.addr, permsArr, 0, usage); - } - - function test_validateExplicitCall_InvalidSessionSigner( - address invalidSigner, - uint64 chainId - ) public supportChainId(chainId) { - vm.assume(invalidSigner != sessionWallet.addr); - // Build a payload with one call. - Payload.Decoded memory payload = _buildPayload(1); - bytes memory callData = hex"deadbeef"; - payload.calls[0] = Payload.Call({ - to: address(0x1234), - value: 0, - data: callData, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Create SessionPermissions with a signer that does NOT match the session signer. - SessionPermissions memory perms = SessionPermissions({ - signer: invalidSigner, // different signer - chainId: chainId, - valueLimit: 100, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - perms.permissions[0] = Permission({ target: address(0x1234), rules: new ParameterRule[](0) }); - - // Create session usage limits. - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 0; - - SessionPermissions[] memory permsArr = _toArray(perms); - - // Expect revert with the correct error selector - vm.expectRevert(abi.encodeWithSelector(SessionErrors.InvalidSessionSigner.selector, sessionWallet.addr)); - harness.validateExplicitCall(payload, 0, wallet, sessionWallet.addr, permsArr, 0, usage); - } - - function test_validateExplicitCall_SessionExpired( - uint64 chainId, - uint64 currentTimestamp, - uint64 expiredTimestamp - ) public supportChainId(chainId) { - currentTimestamp = uint64(bound(currentTimestamp, 2, type(uint256).max)); - expiredTimestamp = uint64(bound(expiredTimestamp, 1, currentTimestamp - 1)); - vm.warp(currentTimestamp); - - Payload.Decoded memory payload = _buildPayload(1); - bytes memory callData = hex"12345678"; - payload.calls[0] = Payload.Call({ - to: address(0x1234), - value: 0, - data: abi.encodePacked(bytes4(0x12345678), callData), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Create SessionPermissions with a deadline in the past. - SessionPermissions memory perms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: chainId, - valueLimit: 100, - deadline: expiredTimestamp, // expired - permissions: new Permission[](1) - }); - perms.permissions[0] = Permission({ target: address(0x1234), rules: new ParameterRule[](1) }); - perms.permissions[0].rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(bytes4(0x12345678)), - offset: 0, - mask: SELECTOR_MASK - }); - - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 0; - - SessionPermissions[] memory permsArr = _toArray(perms); - - // Expect revert due to session expiration with the correct deadline - vm.expectRevert(abi.encodeWithSelector(SessionErrors.SessionExpired.selector, expiredTimestamp)); - harness.validateExplicitCall(payload, 0, wallet, sessionWallet.addr, permsArr, 0, usage); - } - - function test_validateExplicitCall_DelegateCall( - uint64 chainId - ) public supportChainId(chainId) { - Payload.Decoded memory payload = _buildPayload(1); - bytes memory callData = hex"12345678"; - // Set delegateCall to true which is not allowed. - payload.calls[0] = Payload.Call({ - to: address(0x1234), - value: 0, - data: abi.encodePacked(bytes4(0x12345678), callData), - gasLimit: 0, - delegateCall: true, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Create valid SessionPermissions (won't reach permission check). - SessionPermissions memory perms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: chainId, - valueLimit: 100, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - perms.permissions[0] = Permission({ target: address(0x1234), rules: new ParameterRule[](1) }); - perms.permissions[0].rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(bytes4(0x12345678)), - offset: 0, - mask: SELECTOR_MASK - }); - - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 0; - - SessionPermissions[] memory permsArr = _toArray(perms); - - vm.expectRevert(SessionErrors.InvalidDelegateCall.selector); - harness.validateExplicitCall(payload, 0, wallet, sessionWallet.addr, permsArr, 0, usage); - } - - function test_validateExplicitCall_InvalidSelfCall_Value( - uint64 chainId - ) public supportChainId(chainId) { - // Self-call with nonzero value should revert. - bytes memory callData = abi.encodeWithSelector(harness.incrementUsageLimit.selector, new UsageLimit[](0)); - Payload.Decoded memory payload = _buildPayload(1); - payload.calls[0] = Payload.Call({ - to: address(harness), // self-call - value: 1, // nonzero value - data: callData, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Need valid session permissions for the test to reach self-call validation - SessionPermissions memory perms = SessionPermissions({ - signer: sessionWallet.addr, // Match the session signer - chainId: chainId, - valueLimit: 100, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - perms.permissions[0] = Permission({ target: address(harness), rules: new ParameterRule[](0) }); - - SessionPermissions[] memory permsArr = _toArray(perms); - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 0; - - vm.expectRevert(SessionErrors.InvalidValue.selector); - harness.validateExplicitCall(payload, 0, wallet, sessionWallet.addr, permsArr, 0, usage); - } - - function test_validateExplicitCall_MissingPermission( - uint64 chainId - ) public supportChainId(chainId) { - // Build a valid payload call. - bytes memory callData = hex"12345678"; - Payload.Decoded memory payload = _buildPayload(1); - payload.calls[0] = Payload.Call({ - to: address(0x1234), - value: 0, - data: abi.encodePacked(bytes4(0x12345678), callData), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Create SessionPermissions with an empty permissions array. - SessionPermissions memory perms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: chainId, - valueLimit: 100, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](0) - }); - - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 0; - - SessionPermissions[] memory permsArr = _toArray(perms); - - vm.expectRevert(SessionErrors.MissingPermission.selector); - // permissionIdx is 0, but there are no permissions. - harness.validateExplicitCall(payload, 0, wallet, sessionWallet.addr, permsArr, 0, usage); - } - - function test_validateExplicitCall_ValueLimitExceeded( - uint64 chainId - ) public supportChainId(chainId) { - // Build a payload call with a nonzero value. - bytes memory callData = hex"12345678"; - Payload.Decoded memory payload = _buildPayload(1); - payload.calls[0] = Payload.Call({ - to: address(0x1234), - value: 20, // call value that will exceed the valueLimit - data: abi.encodePacked(bytes4(0x12345678), callData), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Set valueLimit lower than the call value. - SessionPermissions memory perms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: chainId, - valueLimit: 10, // limit too low - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - perms.permissions[0] = Permission({ target: address(0x1234), rules: new ParameterRule[](1) }); - perms.permissions[0].rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(bytes4(0x12345678)), - offset: 0, - mask: SELECTOR_MASK - }); - - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 0; - - SessionPermissions[] memory permsArr = _toArray(perms); - - vm.expectRevert(SessionErrors.InvalidValue.selector); - harness.validateExplicitCall(payload, 0, wallet, sessionWallet.addr, permsArr, 0, usage); - } - - function test_validateExplicitCall_InvalidPermission( - uint64 chainId - ) public supportChainId(chainId) { - Payload.Decoded memory payload = _buildPayload(1); - // Use call data that does not match the expected selector. - bytes memory callData = hex"deadbeef"; - payload.calls[0] = Payload.Call({ - to: address(0xDEAD), - value: 0, - data: callData, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Create SessionPermissions expecting selector 0x12345678. - SessionPermissions memory perms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: chainId, - valueLimit: 0, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - perms.permissions[0] = Permission({ target: payload.calls[0].to, rules: new ParameterRule[](1) }); - perms.permissions[0].rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(bytes4(0x12345678)), - offset: 0, - mask: SELECTOR_MASK - }); - - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 0; - - SessionPermissions[] memory permsArr = _toArray(perms); - - // Expect a revert with the InvalidPermission error. - vm.expectRevert(SessionErrors.InvalidPermission.selector); - harness.validateExplicitCall(payload, 0, wallet, sessionWallet.addr, permsArr, 0, usage); - } - - function test_validateLimitUsageIncrement_rule( - UsageLimit memory limit - ) public { - limit.usageAmount = bound(limit.usageAmount, 1, type(uint256).max); - - // Prepare a call that is intended to be the increment call. - Payload.Call memory incCall = Payload.Call({ - to: address(harness), // must equal the harness address (the contract itself) - value: 0, - data: "", // will be filled with expected encoding - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Prepare session usage limits with a nonzero totalValueUsed. - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](1); - usage.limits[0] = limit; - - SessionUsageLimits[] memory usageArr = new SessionUsageLimits[](1); - usageArr[0] = usage; - - // Construct the expected usage increment. - UsageLimit[] memory limitsArr = new UsageLimit[](1); - limitsArr[0] = limit; - - // Encode the expected increment call data. - bytes memory expectedData = abi.encodeWithSelector(harness.incrementUsageLimit.selector, limitsArr); - incCall.data = expectedData; - - // This call should pass without revert. - vm.prank(wallet); - harness.validateLimitUsageIncrement(incCall, usageArr); - } - - function test_validateLimitUsageIncrement_value( - uint256 value - ) public view { - value = bound(value, 1, type(uint256).max); - - // Prepare a call that is intended to be the increment call. - Payload.Call memory incCall = Payload.Call({ - to: address(harness), // must equal the harness address (the contract itself) - value: 0, - data: "", // will be filled with expected encoding - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Prepare session usage limits with a nonzero totalValueUsed. - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); // no extra limits for simplicity - usage.totalValueUsed = value; - - SessionUsageLimits[] memory usageArr = new SessionUsageLimits[](1); - usageArr[0] = usage; - - // Construct the expected usage increment. - UsageLimit memory expectedLimit = - UsageLimit({ usageHash: keccak256(abi.encode(sessionWallet.addr, VALUE_TRACKING_ADDRESS)), usageAmount: value }); - UsageLimit[] memory limitsArr = new UsageLimit[](1); - limitsArr[0] = expectedLimit; - - // Encode the expected increment call data. - bytes memory expectedData = abi.encodeWithSelector(harness.incrementUsageLimit.selector, limitsArr); - incCall.data = expectedData; - - // This call should pass without revert. - harness.validateLimitUsageIncrement(incCall, usageArr); - } - - function test_validateLimitUsageIncrement_RuleAndValue(UsageLimit memory limit, uint256 value) public view { - limit.usageAmount = bound(limit.usageAmount, 1, type(uint256).max); - value = bound(value, 1, type(uint256).max); - - // Prepare a call that is intended to be the increment call. - Payload.Call memory incCall = Payload.Call({ - to: address(harness), - value: 0, - data: "", // will be filled with expected encoding - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Prepare session usage limits with a nonzero totalValueUsed. - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](1); - usage.limits[0] = limit; - usage.totalValueUsed = value; - - SessionUsageLimits[] memory usageArr = new SessionUsageLimits[](1); - usageArr[0] = usage; - // Construct the expected usage increment. - UsageLimit[] memory limitsArr = new UsageLimit[](2); - limitsArr[0] = limit; - limitsArr[1] = - UsageLimit({ usageHash: keccak256(abi.encode(sessionWallet.addr, VALUE_TRACKING_ADDRESS)), usageAmount: value }); - - // Encode the expected increment call data. - bytes memory expectedData = abi.encodeWithSelector(harness.incrementUsageLimit.selector, limitsArr); - incCall.data = expectedData; - - // This call should pass without revert. - harness.validateLimitUsageIncrement(incCall, usageArr); - } - - function test_validateLimitUsageIncrement_InvalidBehaviorOnError() public { - // Prepare a call with correct target but incorrect behaviorOnError. - Payload.Call memory incCall = Payload.Call({ - to: address(harness), - value: 0, - data: "invalid", // data is not checked because behaviorOnError is wrong - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: 0 // not the expected Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 100; - SessionUsageLimits[] memory usageArr = new SessionUsageLimits[](1); - usageArr[0] = usage; - - vm.expectRevert(SessionErrors.InvalidLimitUsageIncrement.selector); - vm.prank(wallet); - harness.validateLimitUsageIncrement(incCall, usageArr); - } - - function test_validateLimitUsageIncrement_OnlyFallbackAllowed() public { - // Prepare a call with correct target and behaviorOnError but onlyFallback = true - // This should revert because increment calls cannot be skippable - Payload.Call memory incCall = Payload.Call({ - to: address(harness), - value: 0, - data: "invalid", // data is not checked because onlyFallback is wrong - gasLimit: 0, - delegateCall: false, - onlyFallback: true, // This should cause the increment call to be skipped - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 100; - SessionUsageLimits[] memory usageArr = new SessionUsageLimits[](1); - usageArr[0] = usage; - - // This should revert because increment calls cannot have onlyFallback = true - vm.expectRevert(SessionErrors.InvalidLimitUsageIncrement.selector); - vm.prank(wallet); - harness.validateLimitUsageIncrement(incCall, usageArr); - } - - function test_validateLimitUsageIncrement_InvalidCallData() public { - // Prepare session usage limits with nonzero totalValueUsed. - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 100; - SessionUsageLimits[] memory usageArr = new SessionUsageLimits[](1); - usageArr[0] = usage; - - // Create a call with the correct target and behaviorOnError but invalid call data. - Payload.Call memory incCall = Payload.Call({ - to: address(harness), - value: 0, - data: hex"deadbeef", // incorrect encoding - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - vm.expectRevert(SessionErrors.InvalidLimitUsageIncrement.selector); - vm.prank(wallet); - harness.validateLimitUsageIncrement(incCall, usageArr); - } - - function test_validateLimitUsageIncrement_InvalidCall() public { - // Prepare a call with an incorrect target. - Payload.Call memory incCall = Payload.Call({ - to: address(0xDEAD), // wrong target - value: 0, - data: "invalid", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 50; - - SessionUsageLimits[] memory usageArr = new SessionUsageLimits[](1); - usageArr[0] = usage; - - vm.expectRevert(SessionErrors.InvalidLimitUsageIncrement.selector); - vm.prank(wallet); - harness.validateLimitUsageIncrement(incCall, usageArr); - } - - function test_incrementUsageLimit( - UsageLimit[] memory limits - ) public { - vm.assume(limits.length > 0); - // Limit to 5 - if (limits.length > 5) { - assembly { - mstore(limits, 5) - } - } - - // Ensure not duplicates - for (uint256 i = 0; i < limits.length; i++) { - for (uint256 j = i + 1; j < limits.length; j++) { - vm.assume(limits[i].usageHash != limits[j].usageHash); - } - } - - // Increment the usage limit - vm.prank(wallet); - harness.incrementUsageLimit(limits); - - // Check totals - for (uint256 i = 0; i < limits.length; i++) { - assertEq(harness.getLimitUsage(wallet, limits[i].usageHash), limits[i].usageAmount); - } - } - - function test_incrementUsageLimit_twice( - UsageLimit[] memory limits - ) public { - // Limit to 5 - if (limits.length > 5) { - assembly { - mstore(limits, 5) - } - } - // First increment - test_incrementUsageLimit(limits); - // Bound amount to be larger than the first increment - for (uint256 i = 0; i < limits.length; i++) { - limits[i].usageAmount = bound(limits[i].usageAmount, limits[i].usageAmount, type(uint256).max); - } - // Second increment (without checks or tests) - vm.prank(wallet); - harness.incrementUsageLimit(limits); - - // Check totals - for (uint256 i = 0; i < limits.length; i++) { - assertEq(harness.getLimitUsage(wallet, limits[i].usageHash), limits[i].usageAmount); - } - } - - function test_incrementUsageLimit_decrement( - UsageLimit memory limit - ) public { - vm.assume(limit.usageAmount > 0); - UsageLimit[] memory limits = new UsageLimit[](2); - limits[0] = limit; - limits[1] = UsageLimit({ usageHash: limit.usageHash, usageAmount: limit.usageAmount - 1 }); - - vm.expectRevert(SessionErrors.InvalidLimitUsageIncrement.selector); - vm.prank(wallet); - harness.incrementUsageLimit(limits); - } - - function test_validateExplicitCall_MultipleValues( - uint64 chainId, - uint256 firstValue, - uint256 secondValue, - uint256 thirdValue, - uint256 valueLimit - ) public supportChainId(chainId) { - // Bound values to reasonable ranges - firstValue = bound(firstValue, 1, type(uint256).max / 3); - secondValue = bound(secondValue, 1, type(uint256).max / 3); - thirdValue = bound(thirdValue, 1, type(uint256).max / 3); - valueLimit = bound(valueLimit, firstValue + secondValue, firstValue + secondValue + thirdValue - 1); - - // Build a payload with three calls - Payload.Decoded memory payload = _buildPayload(3); - - // First call - payload.calls[0] = Payload.Call({ - to: address(0x1234), - value: firstValue, - data: abi.encodeWithSelector(bytes4(0x12345678)), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Second call - payload.calls[1] = Payload.Call({ - to: address(0x5678), - value: secondValue, - data: abi.encodeWithSelector(bytes4(0x12345678)), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Third call - payload.calls[2] = Payload.Call({ - to: address(0x9ABC), - value: thirdValue, - data: abi.encodeWithSelector(bytes4(0x12345678)), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Set valueLimit to allow first two calls but not the third - SessionPermissions memory perms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: chainId, - valueLimit: valueLimit, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](3) - }); - - // Add permissions for all three targets - for (uint256 i = 0; i < 3; i++) { - perms.permissions[i] = Permission({ target: payload.calls[i].to, rules: new ParameterRule[](1) }); - perms.permissions[i].rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(bytes4(0x12345678)), - offset: 0, - mask: SELECTOR_MASK - }); - } - - SessionPermissions[] memory permsArr = _toArray(perms); - SessionUsageLimits memory usage; - usage.signer = sessionWallet.addr; - usage.limits = new UsageLimit[](0); - usage.totalValueUsed = 0; - - // First transaction: Validate first call - SessionUsageLimits memory newUsage = - harness.validateExplicitCall(payload, 0, wallet, sessionWallet.addr, permsArr, 0, usage); - assertEq(newUsage.totalValueUsed, firstValue, "First call should add firstValue to total value"); - - // Increment usage limit after first call - UsageLimit[] memory limits = new UsageLimit[](1); - limits[0] = UsageLimit({ - usageHash: keccak256(abi.encode(sessionWallet.addr, VALUE_TRACKING_ADDRESS)), - usageAmount: firstValue - }); - vm.prank(wallet); - harness.incrementUsageLimit(limits); - - // Second transaction: Validate second call - newUsage = harness.validateExplicitCall(payload, 1, wallet, sessionWallet.addr, permsArr, 1, newUsage); - assertEq(newUsage.totalValueUsed, firstValue + secondValue, "Second call should add secondValue to total value"); - - // Increment usage limit after second call - limits[0].usageAmount = firstValue + secondValue; - vm.prank(wallet); - harness.incrementUsageLimit(limits); - - // Third transaction: Try to make third call which should fail - vm.expectRevert(SessionErrors.InvalidValue.selector); - harness.validateExplicitCall(payload, 2, wallet, sessionWallet.addr, permsArr, 2, newUsage); - } - -} - -contract ExplicitSessionManagerHarness is ExplicitSessionManager { - - /// @notice Exposes the internal _validateExplicitCall function. - function validateExplicitCall( - Payload.Decoded calldata payload, - uint256 callIdx, - address wallet, - address sessionWallet, - SessionPermissions[] memory allSessionPermissions, - uint8 permissionIdx, - SessionUsageLimits memory sessionUsageLimits - ) public view returns (SessionUsageLimits memory) { - return _validateExplicitCall( - payload, callIdx, wallet, sessionWallet, allSessionPermissions, permissionIdx, sessionUsageLimits - ); - } - - /// @notice Exposes the internal _validateLimitUsageIncrement function. - function validateLimitUsageIncrement( - Payload.Call calldata call, - SessionUsageLimits[] memory sessionUsageLimits - ) public view { - _validateLimitUsageIncrement(call, sessionUsageLimits); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/explicit/PermissionValidator.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/explicit/PermissionValidator.t.sol deleted file mode 100644 index f7d2019641..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/explicit/PermissionValidator.t.sol +++ /dev/null @@ -1,323 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Test } from "forge-std/Test.sol"; - -import { - ParameterOperation, ParameterRule, Permission, UsageLimit -} from "src/extensions/sessions/explicit/Permission.sol"; -import { PermissionValidator } from "src/extensions/sessions/explicit/PermissionValidator.sol"; -import { Payload } from "src/modules/Payload.sol"; - -contract PermissionValidatorHarness is PermissionValidator { - - function incrementUsageLimit(address wallet, UsageLimit[] calldata limits) external { - for (uint256 i = 0; i < limits.length; i++) { - uint256 current = getLimitUsage(wallet, limits[i].usageHash); - setLimitUsage(wallet, limits[i].usageHash, current + limits[i].usageAmount); - } - } - - function callSetLimitUsage(address wallet, bytes32 usageHash, uint256 usageAmount) public { - setLimitUsage(wallet, usageHash, usageAmount); - } - -} - -contract PermissionValidatorTest is Test { - - PermissionValidatorHarness validator; - address constant TARGET = address(0xDEAD); - bytes4 constant DUMMY_SELECTOR = bytes4(0x12345678); - bytes32 constant SELECTOR_MASK = bytes32(bytes4(0xffffffff)); - address constant TEST_WALLET = address(0xBEEF); - address constant TEST_SIGNER = address(0xCAFE); - - function setUp() public { - validator = new PermissionValidatorHarness(); - } - - function test_LimitUsageUpdated(address wallet, bytes32 usageHash, uint256 usageAmount) public { - vm.expectEmit(true, true, true, true); - emit PermissionValidator.LimitUsageUpdated(wallet, usageHash, usageAmount); - validator.callSetLimitUsage(wallet, usageHash, usageAmount); - assertEq(validator.getLimitUsage(wallet, usageHash), usageAmount); - } - - function test_validatePermission_Equal( - bytes4 selector - ) public view { - Permission memory permission = Permission({ target: TARGET, rules: new ParameterRule[](1) }); - permission.rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(selector), - offset: 0, - mask: SELECTOR_MASK - }); - - // Create a matching call - Payload.Call memory call = Payload.Call({ - to: TARGET, - value: 0, - data: abi.encodePacked(selector, bytes28(0)), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - UsageLimit[] memory emptyLimits = new UsageLimit[](0); - (bool success,) = validator.validatePermission(permission, call, TEST_WALLET, TEST_SIGNER, emptyLimits); - assertTrue(success, "Permission validation should succeed with matching selector"); - - // Test with non-matching call (flip all bits of selector) - bytes4 nonMatchingSelector = ~selector; - call.data = abi.encodePacked(nonMatchingSelector, bytes28(0)); - (success,) = validator.validatePermission(permission, call, TEST_WALLET, TEST_SIGNER, emptyLimits); - assertFalse(success, "Permission validation should fail with non-matching selector"); - } - - function test_validatePermission_Cumulative(uint256 value, uint256 limit) public { - limit = bound(limit, 0, type(uint256).max - 1); - value = bound(value, 0, limit); - - Permission memory permission = Permission({ target: TARGET, rules: new ParameterRule[](1) }); - permission.rules[0] = ParameterRule({ - cumulative: true, - operation: ParameterOperation.LESS_THAN_OR_EQUAL, - value: bytes32(limit), - offset: 4, // Offset the selector - mask: bytes32(type(uint256).max) - }); - - Payload.Call memory call = Payload.Call({ - to: TARGET, - value: 0, - data: abi.encodeWithSelector(DUMMY_SELECTOR, value), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Initialize usage limits array with space for one limit - UsageLimit[] memory emptyLimits = new UsageLimit[](1); - emptyLimits[0].usageHash = bytes32(0); - emptyLimits[0].usageAmount = 0; - - (bool success, UsageLimit[] memory newLimits) = - validator.validatePermission(permission, call, TEST_WALLET, TEST_SIGNER, emptyLimits); - assertTrue(success, "First call should succeed"); - assertEq(newLimits.length, 1, "Should have one usage limit"); - assertEq(newLimits[0].usageAmount, value, "Usage amount should be value"); - - // Increment the limit - validator.incrementUsageLimit(TEST_WALLET, newLimits); - - // Create a second call that would exceed the limit - value = bound(value, limit - value + 1, type(uint256).max - value); - call.data = abi.encodeWithSelector(DUMMY_SELECTOR, value); - (success,) = validator.validatePermission(permission, call, TEST_WALLET, TEST_SIGNER, newLimits); - assertFalse(success, "Second call should fail as it would exceed limit"); - } - - function test_validatePermission_GreaterThanOrEqual(uint256 threshold, uint256 testValue) public view { - Permission memory permission = Permission({ target: TARGET, rules: new ParameterRule[](1) }); - permission.rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.GREATER_THAN_OR_EQUAL, - value: bytes32(threshold), - offset: 0, - mask: bytes32(type(uint256).max) - }); - - Payload.Call memory call = Payload.Call({ - to: TARGET, - value: 0, - data: abi.encode(testValue), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - UsageLimit[] memory emptyLimits = new UsageLimit[](0); - (bool success,) = validator.validatePermission(permission, call, TEST_WALLET, TEST_SIGNER, emptyLimits); - - if (testValue >= threshold) { - assertTrue(success, "Should succeed with value >= threshold"); - } else { - assertFalse(success, "Should fail with value < threshold"); - } - } - - function test_validatePermission_NotEqual(uint256 testValue, uint256 compareValue) public view { - vm.assume(testValue != compareValue); - - Permission memory permission = Permission({ target: TARGET, rules: new ParameterRule[](1) }); - permission.rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.NOT_EQUAL, - value: bytes32(compareValue), - offset: 0, - mask: bytes32(type(uint256).max) - }); - - Payload.Call memory call = Payload.Call({ - to: TARGET, - value: 0, - data: abi.encode(testValue), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - UsageLimit[] memory emptyLimits = new UsageLimit[](0); - (bool success,) = validator.validatePermission(permission, call, TEST_WALLET, TEST_SIGNER, emptyLimits); - - assertTrue(success, "Should pass when values are not equal"); - } - - function test_validatePermission_NotEqual_fail( - uint256 testValue - ) public view { - Permission memory permission = Permission({ target: TARGET, rules: new ParameterRule[](1) }); - permission.rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.NOT_EQUAL, - value: bytes32(testValue), - offset: 0, - mask: bytes32(type(uint256).max) - }); - - Payload.Call memory call = Payload.Call({ - to: TARGET, - value: 0, - data: abi.encode(testValue), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - UsageLimit[] memory emptyLimits = new UsageLimit[](0); - (bool success,) = validator.validatePermission(permission, call, TEST_WALLET, TEST_SIGNER, emptyLimits); - - assertFalse(success, "Should fail when values are equal"); - } - - function test_validatePermission_WithMaskAndOffset( - bytes calldata callData, - bytes32 mask, - uint256 offset, - bytes calldata secondCallData - ) public view { - vm.assume(callData.length >= 32); - offset = bound(offset, 0, callData.length - 32); - - // Extract value from calldata at offset - bytes32 value; - assembly { - value := calldataload(add(callData.offset, offset)) - } - - bytes32 maskedValue = value & mask; - Permission memory permission = Permission({ target: TARGET, rules: new ParameterRule[](1) }); - permission.rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: maskedValue, - offset: offset, - mask: mask - }); - - Payload.Call memory call = Payload.Call({ - to: TARGET, - value: 0, - data: callData, - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - UsageLimit[] memory emptyLimits = new UsageLimit[](0); - (bool success,) = validator.validatePermission(permission, call, TEST_WALLET, TEST_SIGNER, emptyLimits); - assertTrue(success, "Should succeed when masked value matches with offset"); - - // Second test - bytes32 secondValue; - assembly { - secondValue := calldataload(add(secondCallData.offset, offset)) - } - bytes32 maskedSecondValue = secondValue & mask; - call.data = secondCallData; - (success,) = validator.validatePermission(permission, call, TEST_WALLET, TEST_SIGNER, emptyLimits); - if (maskedValue == maskedSecondValue) { - // Expect success when values match - assertTrue(success, "Should succeed when masked value matches with offset"); - } else { - // Expect failure when values do not match - assertFalse(success, "Should fail when masked value does not match with offset"); - } - } - - function test_validatePermission_WrongTarget( - address wrongTarget, - Payload.Call calldata call, - UsageLimit[] calldata usageLimits - ) public view { - vm.assume(wrongTarget != call.to); - Permission memory permission = Permission({ target: TARGET, rules: new ParameterRule[](1) }); - permission.rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: bytes32(uint256(uint160(TARGET))), - offset: 0, - mask: bytes32(type(uint256).max) - }); - - (bool success,) = validator.validatePermission(permission, call, TEST_WALLET, TEST_SIGNER, usageLimits); - assertFalse(success, "Should fail when target does not match"); - } - - /// @notice This test passes however in practice memory accessed outside the calldata should be zeroed out using the mask. - /// @notice A permission should not be constructed assuming the overflow bytes use the length of the usage limits array... - function test_validatePermission_OverflowCalldata_Zeroed( - Payload.Call calldata call, - uint256 offset, - UsageLimit[] calldata usageLimits - ) public view { - // Ensure there is some overlap with the call data when available - uint256 maxOffset = call.data.length > 0 ? call.data.length - 1 : 0; - offset = bound(offset, 0, maxOffset); - - bytes32 value; - if (offset < call.data.length) { - // Get the value from the call data ensuring no overflow accessed - value = bytes32(call.data[offset:call.data.length]); - } - // Get the remaining bytes from the uhh usageLimits size? - // Because that's the order the calldata for validatePermission is encoded in here... - // This may overflow differently throughout the call stack... - bytes32 usageLimitsBytes = bytes32(usageLimits.length); - // Right shift the gas limit bytes to the correct position - usageLimitsBytes = usageLimitsBytes >> ((call.data.length - offset) * 8); - value = value | usageLimitsBytes; - - Permission memory permission = Permission({ target: call.to, rules: new ParameterRule[](1) }); - permission.rules[0] = ParameterRule({ - cumulative: false, - operation: ParameterOperation.EQUAL, - value: value, - offset: offset, - mask: bytes32(type(uint256).max) // All bits mapped - }); - - (bool success,) = validator.validatePermission(permission, call, TEST_WALLET, TEST_SIGNER, usageLimits); - assertTrue(success, "Should succeed as overflowed calldata is treated as 0"); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/implicit/ImplicitSessionManager.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/implicit/ImplicitSessionManager.t.sol deleted file mode 100644 index 086cb0959c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/extensions/sessions/implicit/ImplicitSessionManager.t.sol +++ /dev/null @@ -1,221 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Vm } from "forge-std/Test.sol"; - -import { SessionErrors } from "src/extensions/sessions/SessionErrors.sol"; -import { SessionPermissions } from "src/extensions/sessions/explicit/IExplicitSessionManager.sol"; -import { Attestation, LibAttestation } from "src/extensions/sessions/implicit/Attestation.sol"; -import { ISignalsImplicitMode } from "src/extensions/sessions/implicit/ISignalsImplicitMode.sol"; -import { ImplicitSessionManager } from "src/extensions/sessions/implicit/ImplicitSessionManager.sol"; -import { ISapient, Payload } from "src/modules/interfaces/ISapient.sol"; - -import { SessionTestBase } from "test/extensions/sessions/SessionTestBase.sol"; -import { Emitter } from "test/mocks/Emitter.sol"; -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; - -contract ImplicitSessionManagerTest is SessionTestBase { - - using LibAttestation for Attestation; - - ImplicitSessionManagerHarness public sessionManager; - Emitter public emitter; - address public wallet; - Vm.Wallet public sessionWallet; - Vm.Wallet public identityWallet; - - function setUp() public { - sessionManager = new ImplicitSessionManagerHarness(); - emitter = new Emitter(); - wallet = vm.createWallet("wallet").addr; - sessionWallet = vm.createWallet("session"); - identityWallet = vm.createWallet("identity"); - } - - /// @dev Helper to create a Payload.Call. - function _createCall( - address to, - bool delegateCall, - uint256 value, - bytes memory data - ) internal pure returns (Payload.Call memory call) { - call = Payload.Call({ - to: to, - value: value, - data: data, - gasLimit: 0, - delegateCall: delegateCall, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_IGNORE_ERROR - }); - } - - function test_validImplicitCall(Attestation memory attestation, address[] memory blacklist) public view { - // Ensure the blacklist doesn't contain the signer or call target - for (uint256 i = 0; i < blacklist.length; i++) { - vm.assume(blacklist[i] != sessionWallet.addr); - vm.assume(blacklist[i] != address(emitter)); - } - - attestation.approvedSigner = sessionWallet.addr; - Payload.Call memory call = - _createCall(address(emitter), false, 0, abi.encodeWithSelector(Emitter.implicitEmit.selector)); - - // Validate the call - sessionManager.validateImplicitCall(call, wallet, sessionWallet.addr, attestation, blacklist); - } - - function test_validImplicitCall_invalidSessionSigner( - Attestation memory attestation - ) public { - vm.assume(attestation.approvedSigner != sessionWallet.addr); - address[] memory blacklist = new address[](0); - Payload.Call memory call = - _createCall(address(emitter), false, 0, abi.encodeWithSelector(Emitter.implicitEmit.selector)); - - // Validate the call - vm.expectRevert(abi.encodeWithSelector(SessionErrors.InvalidSessionSigner.selector, sessionWallet.addr)); - sessionManager.validateImplicitCall(call, wallet, sessionWallet.addr, attestation, blacklist); - } - - function test_blacklistedSessionSignerNotAllowed( - uint256 randomIdx, - Attestation memory attestation, - address[] memory blacklist - ) public { - // Blacklist the session signer - vm.assume(blacklist.length > 0); - // Ensure blacklist doesn't contain the emitter - for (uint256 i = 0; i < blacklist.length; i++) { - vm.assume(blacklist[i] != address(emitter)); - } - // Blacklist the session signer - randomIdx = bound(randomIdx, 0, blacklist.length - 1); - blacklist[randomIdx] = sessionWallet.addr; - // Sort the blacklist - _sortAddressesMemory(blacklist); - - attestation.approvedSigner = sessionWallet.addr; - Payload.Call memory call = - _createCall(address(emitter), false, 0, abi.encodeWithSelector(Emitter.implicitEmit.selector)); - - vm.expectRevert(abi.encodeWithSelector(SessionErrors.BlacklistedAddress.selector, sessionWallet.addr)); - sessionManager.validateImplicitCall(call, wallet, sessionWallet.addr, attestation, blacklist); - } - - /// @notice Test for an unsorted blacklist skipping the binary search. - function test_blacklist_unsortedSkipsBinarySearch( - address[] memory blacklist - ) public view { - // Ensure not sorted - bool isSorted = true; - for (uint256 i = 0; i < blacklist.length; i++) { - for (uint256 j = 0; j < blacklist.length - i - 1; j++) { - if (blacklist[j] > blacklist[j + 1]) { - isSorted = false; - break; - } - } - } - vm.assume(!isSorted); - - bool missedBlacklist = false; - for (uint256 i = 0; i < blacklist.length; i++) { - if (sessionManager.isAddressBlacklisted(blacklist[i], blacklist)) { - missedBlacklist = true; - break; - } - } - // Any unsorted blacklist WILL result in missed detection of a blacklisted address in the list - assertEq(missedBlacklist, true); - - // Sorting the blacklist will result in all blacklisted addresses being detected - _sortAddressesMemory(blacklist); - for (uint256 i = 0; i < blacklist.length; i++) { - assertEq(sessionManager.isAddressBlacklisted(blacklist[i], blacklist), true); - } - } - - /// @notice Test for delegateCall not allowed. - function test_delegateCallNotAllowed( - Attestation memory attestation - ) public { - attestation.approvedSigner = sessionWallet.addr; - Payload.Call memory call = - _createCall(address(emitter), true, 0, abi.encodeWithSelector(Emitter.implicitEmit.selector)); - address[] memory emptyBlacklist = new address[](0); - - vm.expectRevert(abi.encodeWithSelector(SessionErrors.InvalidDelegateCall.selector)); - sessionManager.validateImplicitCall(call, wallet, sessionWallet.addr, attestation, emptyBlacklist); - } - - function test_nonZeroValueNotAllowed(Attestation memory attestation, uint256 nonZeroValue) public { - vm.assume(nonZeroValue > 0); - attestation.approvedSigner = sessionWallet.addr; - Payload.Call memory call = - _createCall(address(emitter), false, nonZeroValue, abi.encodeWithSelector(Emitter.implicitEmit.selector)); - address[] memory emptyBlacklist = new address[](0); - - vm.expectRevert(abi.encodeWithSelector(SessionErrors.InvalidValue.selector)); - sessionManager.validateImplicitCall(call, wallet, sessionWallet.addr, attestation, emptyBlacklist); - } - - function test_blacklistedAddressNotAllowed( - uint256 randomIdx, - Attestation memory attestation, - address[] memory blacklist - ) public { - // Force the blacklist to contain the call target. - vm.assume(blacklist.length > 0); - randomIdx = bound(randomIdx, 0, blacklist.length - 1); - blacklist[randomIdx] = address(emitter); - // Ensure the signer isn't blacklisted - for (uint256 i = 0; i < blacklist.length; i++) { - vm.assume(blacklist[i] != sessionWallet.addr); - } - // Sort the blacklist so that binary search in the contract works correctly. - _sortAddressesMemory(blacklist); - - attestation.approvedSigner = sessionWallet.addr; - Payload.Call memory call = - _createCall(address(emitter), false, 0, abi.encodeWithSelector(Emitter.implicitEmit.selector)); - - vm.expectRevert(abi.encodeWithSelector(SessionErrors.BlacklistedAddress.selector, address(emitter))); - sessionManager.validateImplicitCall(call, wallet, sessionWallet.addr, attestation, blacklist); - } - - function test_invalidImplicitResult( - Attestation memory attestation - ) public { - attestation.approvedSigner = sessionWallet.addr; - - // Explicit emit is not approved - Payload.Call memory call = - _createCall(address(emitter), false, 0, abi.encodeWithSelector(Emitter.explicitEmit.selector)); - address[] memory emptyBlacklist = new address[](0); - - vm.expectRevert(abi.encodeWithSelector(SessionErrors.InvalidImplicitResult.selector)); - sessionManager.validateImplicitCall(call, wallet, sessionWallet.addr, attestation, emptyBlacklist); - } - -} - -contract ImplicitSessionManagerHarness is ImplicitSessionManager { - - /// @notice Exposes the internal _validateImplicitCall function. - function validateImplicitCall( - Payload.Call calldata call, - address wallet, - address sessionSigner, - Attestation memory attestation, - address[] memory blacklist - ) public view { - _validateImplicitCall(call, wallet, sessionSigner, attestation, blacklist); - } - - /// @notice Exposes the internal _isAddressBlacklisted function. - function isAddressBlacklisted(address target, address[] memory blacklist) public pure returns (bool) { - return _isAddressBlacklisted(target, blacklist); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/recovery/RecoveryDenialOfService.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/recovery/RecoveryDenialOfService.t.sol deleted file mode 100644 index 4fb36fb85b..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/recovery/RecoveryDenialOfService.t.sol +++ /dev/null @@ -1,199 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Test, Vm } from "forge-std/Test.sol"; - -import { AcceptAll } from "test/mocks/AcceptAll.sol"; -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; -import { AdvTest } from "test/utils/TestUtils.sol"; - -import { Factory } from "src/Factory.sol"; -import { Stage1Module } from "src/Stage1Module.sol"; -import { Recovery } from "src/extensions/recovery/Recovery.sol"; - -import { Nonce } from "src/modules/Nonce.sol"; -import { Payload } from "src/modules/Payload.sol"; - -contract IntegrationRecoveryDenialOfService is AdvTest { - - Factory public factory; - Stage1Module public module; - Recovery public recovery; - Vm.Wallet public eoaWallet; - Vm.Wallet public recoveryWallet; - AcceptAll public mockTarget; - - function setUp() public virtual { - eoaWallet = vm.createWallet("eoa"); - recoveryWallet = vm.createWallet("recovery"); - recovery = new Recovery(); - factory = new Factory(); - module = new Stage1Module(address(factory), address(0)); - mockTarget = new AcceptAll(); - } - - struct Signer { - address signer; - uint24 requiredDeltaTime; - uint64 minTimestamp; - } - - function _createWalletWithSigner( - Signer memory signer - ) internal returns (Stage1Module wallet, string memory walletConfig, bytes memory recoveryConfig) { - string memory leaves = string.concat( - "signer:", - vm.toString(signer.signer), - ":", - vm.toString(signer.requiredDeltaTime), - ":", - vm.toString(signer.minTimestamp) - ); - recoveryConfig = PrimitivesRPC.recoveryEncode(vm, leaves); - bytes32 recoveryImageHash = PrimitivesRPC.recoveryHashFromLeaves(vm, leaves); - string memory ce = - string(abi.encodePacked("sapient:", vm.toString(recoveryImageHash), ":", vm.toString(address(recovery)), ":1")); - ce = string(abi.encodePacked(ce, " signer:", vm.toString(eoaWallet.addr), ":1")); - walletConfig = PrimitivesRPC.newConfig(vm, 1, 0, ce); - bytes32 imageHash = PrimitivesRPC.getImageHash(vm, walletConfig); - wallet = Stage1Module(payable(factory.deploy(address(module), imageHash))); - - return (wallet, walletConfig, recoveryConfig); - } - - function _validRecoverySignature( - Stage1Module wallet, - Payload.Decoded memory payload - ) internal view returns (bytes memory signature) { - bytes32 recoveryPayloadHash = recovery.recoveryPayloadHash(address(wallet), payload); - (uint8 v, bytes32 r, bytes32 s) = vm.sign(recoveryWallet.privateKey, recoveryPayloadHash); - bytes32 yParityAndS = bytes32((uint256(v - 27) << 255) | uint256(s)); - signature = abi.encodePacked(r, yParityAndS); - } - - function _validWalletSignature( - Payload.Decoded memory payload, - string memory walletConfig, - bytes memory recoveryConfig - ) internal returns (bytes memory signature) { - string memory signatures = - string(abi.encodePacked(vm.toString(address(recovery)), ":sapient_compact:", vm.toString(recoveryConfig))); - signature = PrimitivesRPC.toEncodedSignature(vm, walletConfig, signatures, !payload.noChainId); - } - - function test_Recovery_Reexecution(uint160 space, uint64 minTimestamp, uint24 requiredDeltaTime) public { - minTimestamp = uint64(bound(minTimestamp, 1, type(uint64).max - requiredDeltaTime)); - vm.warp(minTimestamp); - - Signer memory signer = - Signer({ signer: recoveryWallet.addr, requiredDeltaTime: requiredDeltaTime, minTimestamp: minTimestamp }); - (Stage1Module wallet, string memory walletConfig, bytes memory recoveryConfig) = _createWalletWithSigner(signer); - - // Prepare recovery payload - Payload.Decoded memory recoveryPayload; - recoveryPayload.kind = Payload.KIND_TRANSACTIONS; - recoveryPayload.calls = new Payload.Call[](1); - recoveryPayload.calls[0].to = address(mockTarget); - recoveryPayload.space = space; - - // Queue recovery payload - bytes memory recoverySignature = _validRecoverySignature(wallet, recoveryPayload); - recovery.queuePayload(address(wallet), signer.signer, recoveryPayload, recoverySignature); - - // Wait the required time - vm.warp(minTimestamp + requiredDeltaTime); - - // Execute the payload - bytes memory walletSignature = _validWalletSignature(recoveryPayload, walletConfig, recoveryConfig); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, recoveryPayload), walletSignature); - - // Resubmission fails - vm.expectRevert(abi.encodeWithSelector(Nonce.BadNonce.selector, recoveryPayload.space, recoveryPayload.nonce, 1)); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, recoveryPayload), walletSignature); - } - - function test_Recovery_DenialOfService(uint160 space, uint64 minTimestamp, uint24 requiredDeltaTime) public { - minTimestamp = uint64(bound(minTimestamp, 1, type(uint64).max - requiredDeltaTime)); - vm.warp(minTimestamp); - - Signer memory signer = - Signer({ signer: recoveryWallet.addr, requiredDeltaTime: requiredDeltaTime, minTimestamp: minTimestamp }); - (Stage1Module wallet, string memory walletConfig, bytes memory recoveryConfig) = _createWalletWithSigner(signer); - - // Prepare recovery payload - Payload.Decoded memory recoveryPayload; - recoveryPayload.kind = Payload.KIND_TRANSACTIONS; - recoveryPayload.calls = new Payload.Call[](1); - recoveryPayload.calls[0].to = address(mockTarget); - recoveryPayload.calls[0].data = "0x23456789"; - recoveryPayload.space = space; - - // Queue recovery payload - bytes memory recoverySignature = _validRecoverySignature(wallet, recoveryPayload); - recovery.queuePayload(address(wallet), signer.signer, recoveryPayload, recoverySignature); - - // Wait the required time - vm.warp(minTimestamp + requiredDeltaTime); - - // Block it by having the EOA submit a payload - Payload.Decoded memory eoaPayload; - eoaPayload.kind = Payload.KIND_TRANSACTIONS; - eoaPayload.calls = new Payload.Call[](1); - eoaPayload.calls[0].to = address(mockTarget); - eoaPayload.calls[0].data = "0x12345678"; - eoaPayload.space = space; - - // EOA sign - bytes32 payloadHash = Payload.hashFor(eoaPayload, address(wallet)); - (uint8 v, bytes32 r, bytes32 s) = vm.sign(eoaWallet, payloadHash); - string memory eoaSignatureStr = string( - abi.encodePacked(vm.toString(eoaWallet.addr), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v)) - ); - bytes memory eoaSignature = - PrimitivesRPC.toEncodedSignature(vm, walletConfig, eoaSignatureStr, !eoaPayload.noChainId); - - // Execute with EOA - wallet.execute(PrimitivesRPC.toPackedPayload(vm, eoaPayload), eoaSignature); - - // Recovery fails - bytes memory walletSignature = _validWalletSignature(recoveryPayload, walletConfig, recoveryConfig); - vm.expectRevert(abi.encodeWithSelector(Nonce.BadNonce.selector, recoveryPayload.space, recoveryPayload.nonce, 1)); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, recoveryPayload), walletSignature); - } - - function test_Recovery_CallableByAnyone( - uint160 space, - uint64 minTimestamp, - uint24 requiredDeltaTime, - address queuer, - address executor - ) public { - minTimestamp = uint64(bound(minTimestamp, 1, type(uint64).max - requiredDeltaTime)); - vm.warp(minTimestamp); - - Signer memory signer = - Signer({ signer: recoveryWallet.addr, requiredDeltaTime: requiredDeltaTime, minTimestamp: minTimestamp }); - (Stage1Module wallet, string memory walletConfig, bytes memory recoveryConfig) = _createWalletWithSigner(signer); - - // Prepare recovery payload - Payload.Decoded memory recoveryPayload; - recoveryPayload.kind = Payload.KIND_TRANSACTIONS; - recoveryPayload.calls = new Payload.Call[](1); - recoveryPayload.calls[0].to = address(mockTarget); - recoveryPayload.space = space; - - // Queue recovery payload - bytes memory recoverySignature = _validRecoverySignature(wallet, recoveryPayload); - vm.prank(queuer); - recovery.queuePayload(address(wallet), signer.signer, recoveryPayload, recoverySignature); - - // Wait the required time - vm.warp(minTimestamp + requiredDeltaTime); - - // Execute the payload - bytes memory walletSignature = _validWalletSignature(recoveryPayload, walletConfig, recoveryConfig); - vm.prank(executor); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, recoveryPayload), walletSignature); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/ExtendedSessionTestBase.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/ExtendedSessionTestBase.sol deleted file mode 100644 index dfa823f52c..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/ExtendedSessionTestBase.sol +++ /dev/null @@ -1,175 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Vm, console } from "forge-std/Test.sol"; - -import { SessionTestBase } from "test/extensions/sessions/SessionTestBase.sol"; - -import { AcceptAll } from "test/mocks/AcceptAll.sol"; -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; - -import { EntryPoint } from "account-abstraction/core/EntryPoint.sol"; -import { Factory } from "src/Factory.sol"; -import { Stage1Module } from "src/Stage1Module.sol"; -import { SessionManager, SessionPermissions, SessionSig } from "src/extensions/sessions/SessionManager.sol"; -import { ParameterOperation, ParameterRule, Permission } from "src/extensions/sessions/explicit/Permission.sol"; -import { Attestation } from "src/extensions/sessions/implicit/Attestation.sol"; -import { Payload } from "src/modules/Payload.sol"; - -/// @notice Session signature abuse tests. -contract ExtendedSessionTestBase is SessionTestBase { - - Factory public factory; - Stage1Module public module; - SessionManager public sessionManager; - Vm.Wallet public sessionWallet; - Vm.Wallet public identityWallet; - AcceptAll public mockTarget; - EntryPoint public entryPoint; - - function setUp() public virtual { - sessionWallet = vm.createWallet("session"); - identityWallet = vm.createWallet("identity"); - sessionManager = new SessionManager(); - factory = new Factory(); - entryPoint = new EntryPoint(); - module = new Stage1Module(address(factory), address(entryPoint)); - } - - function _createDefaultTopology() internal returns (string memory topology) { - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: 0, - valueLimit: 0, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: address(mockTarget), rules: new ParameterRule[](0) }); - return _createTopology(sessionPerms); - } - - function _createTopology( - SessionPermissions memory sessionPerms - ) internal returns (string memory topology) { - topology = PrimitivesRPC.sessionEmpty(vm, identityWallet.addr); - string memory sessionPermsJson = _sessionPermissionsToJSON(sessionPerms); - topology = PrimitivesRPC.sessionExplicitAdd(vm, sessionPermsJson, topology); - return topology; - } - - function _createWallet( - string memory topology - ) internal returns (Stage1Module wallet, string memory config, bytes32 imageHash) { - bytes32 sessionImageHash = PrimitivesRPC.sessionImageHash(vm, topology); - - string memory ce = string( - abi.encodePacked("sapient:", vm.toString(sessionImageHash), ":", vm.toString(address(sessionManager)), ":1") - ); - config = PrimitivesRPC.newConfig(vm, 1, 0, ce); - imageHash = PrimitivesRPC.getImageHash(vm, config); - wallet = Stage1Module(payable(factory.deploy(address(module), imageHash))); - - return (wallet, config, imageHash); - } - - function _validExplicitSignature( - Payload.Decoded memory payload, - Vm.Wallet memory signer, - string memory config, - string memory topology, - uint8[] memory permissionIdxs - ) internal returns (bytes memory signature) { - string[] memory callSignatures = new string[](payload.calls.length); - for (uint256 i = 0; i < payload.calls.length; i++) { - bytes32 callHash = SessionSig.hashCallWithReplayProtection(payload, i); - string memory sessionSignature = _signAndEncodeRSV(callHash, signer); - callSignatures[i] = _explicitCallSignatureToJSON(permissionIdxs[i], sessionSignature); - } - address[] memory explicitSigners = new address[](1); - explicitSigners[0] = signer.addr; - address[] memory implicitSigners = new address[](0); - bytes memory sessionSignatures = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - string memory signatures = - string(abi.encodePacked(vm.toString(address(sessionManager)), ":sapient:", vm.toString(sessionSignatures))); - signature = PrimitivesRPC.toEncodedSignature(vm, config, signatures, !payload.noChainId); - } - - function _createValidAttestation( - Vm.Wallet memory signer - ) internal view returns (Attestation memory) { - Attestation memory attestation; - attestation.approvedSigner = signer.addr; - attestation.authData.redirectUrl = "https://example.com"; - attestation.authData.issuedAt = uint64(block.timestamp); - return attestation; - } - - function _validImplicitSignature( - Payload.Decoded memory payload, - Vm.Wallet memory signer, - string memory config, - string memory topology - ) internal returns (bytes memory signature) { - uint256 callCount = payload.calls.length; - string[] memory callSignatures = new string[](callCount); - Attestation memory attestation = _createValidAttestation(signer); - for (uint256 i; i < callCount; i++) { - callSignatures[i] = _createImplicitCallSignature(payload, i, signer, identityWallet, attestation); - } - - address[] memory explicitSigners = new address[](0); - address[] memory implicitSigners = new address[](1); - implicitSigners[0] = signer.addr; - bytes memory sessionSignatures = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - string memory signatures = - string(abi.encodePacked(vm.toString(address(sessionManager)), ":sapient:", vm.toString(sessionSignatures))); - signature = PrimitivesRPC.toEncodedSignature(vm, config, signatures, !payload.noChainId); - } - - struct FuzzPermission { - address target; - FuzzParameterRule[] rules; - } - - struct FuzzParameterRule { - bool cumulative; - uint8 operation; - bytes32 value; - uint256 offset; - bytes32 mask; - } - - function _fuzzToPermission( - FuzzPermission memory fuzzPermission, - uint256 maxRules - ) internal pure returns (Permission memory permission) { - uint256 rulesLength = fuzzPermission.rules.length > maxRules ? maxRules : fuzzPermission.rules.length; - permission = Permission({ target: fuzzPermission.target, rules: new ParameterRule[](rulesLength) }); - for (uint256 i = 0; i < rulesLength; i++) { - permission.rules[i] = ParameterRule({ - cumulative: fuzzPermission.rules[i].cumulative, - operation: ParameterOperation(fuzzPermission.rules[i].operation % 4), - value: fuzzPermission.rules[i].value, - offset: fuzzPermission.rules[i].offset, - mask: fuzzPermission.rules[i].mask - }); - } - return permission; - } - - function _fuzzToPermissions( - FuzzPermission[] memory fuzzPermissions, - uint256 maxPermissions, - uint256 maxRules - ) internal pure returns (Permission[] memory permissions) { - uint256 permissionsLength = fuzzPermissions.length > maxPermissions ? maxPermissions : fuzzPermissions.length; - permissions = new Permission[](permissionsLength); - for (uint256 i = 0; i < permissionsLength; i++) { - permissions[i] = _fuzzToPermission(fuzzPermissions[i], maxRules); - } - return permissions; - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionDenialOfService.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionDenialOfService.t.sol deleted file mode 100644 index c497d7ab97..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionDenialOfService.t.sol +++ /dev/null @@ -1,191 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { ExtendedSessionTestBase } from "./ExtendedSessionTestBase.sol"; -import { Vm, console } from "forge-std/Test.sol"; - -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; - -import { Factory } from "src/Factory.sol"; -import { Stage1Module } from "src/Stage1Module.sol"; -import { - SessionErrors, SessionManager, SessionPermissions, SessionSig -} from "src/extensions/sessions/SessionManager.sol"; -import { - ParameterOperation, ParameterRule, Permission, UsageLimit -} from "src/extensions/sessions/explicit/Permission.sol"; -import { Attestation } from "src/extensions/sessions/implicit/Attestation.sol"; -import { Calls } from "src/modules/Calls.sol"; -import { Nonce } from "src/modules/Nonce.sol"; -import { Payload } from "src/modules/Payload.sol"; - -/// @notice Checks for denial of service attacks on or by sessions. -contract IntegrationSessionDenialOfServiceTest is ExtendedSessionTestBase { - - using Payload for Payload.Decoded; - - function test_DOS_Wallet_SignerRace( - uint160 space - ) public { - space = uint160(bound(space, 0, sessionManager.MAX_SPACE())); - - // Create wallet with sessions and EOA. - Vm.Wallet memory eoa = vm.createWallet("eoa"); - string memory topology = _createDefaultTopology(); - bytes32 sessionImageHash = PrimitivesRPC.sessionImageHash(vm, topology); - string memory ce = string( - abi.encodePacked("sapient:", vm.toString(sessionImageHash), ":", vm.toString(address(sessionManager)), ":1") - ); - ce = string(abi.encodePacked(ce, " signer:", vm.toString(eoa.addr), ":1")); - string memory config = PrimitivesRPC.newConfig(vm, 1, 0, ce); - bytes32 imageHash = PrimitivesRPC.getImageHash(vm, config); - Stage1Module wallet = Stage1Module(payable(factory.deploy(address(module), imageHash))); - - // Build payload for EOA to sign - Payload.Decoded memory payload1 = _buildPayload(1); - payload1.calls = new Payload.Call[](1); - payload1.calls[0].to = address(mockTarget); - payload1.calls[0].data = "0x12345678"; - payload1.noChainId = false; - payload1.space = space; - - // Sign it with the EOA - bytes32 payloadHash = Payload.hashFor(payload1, address(wallet)); - (uint8 v, bytes32 r, bytes32 s) = vm.sign(eoa, payloadHash); - string memory eoaSignatureStr = string( - abi.encodePacked(vm.toString(eoa.addr), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v)) - ); - bytes memory eoaSignature = PrimitivesRPC.toEncodedSignature(vm, config, eoaSignatureStr, !payload1.noChainId); - - //FIXME Check it is approved without running it - // wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload1), eoaSignature); - - // Sign a payload with the same nonce to race execution - Payload.Decoded memory payload2 = _buildPayload(1); - payload2.calls = new Payload.Call[](1); - payload2.calls[0].to = address(mockTarget); - payload2.calls[0].data = "0x87654321"; - payload2.space = payload1.space; - payload2.nonce = payload1.nonce; - - string[] memory callSignatures = new string[](1); - bytes32 callHash = SessionSig.hashCallWithReplayProtection(payload2, 0); - string memory callSignature = _signAndEncodeRSV(callHash, sessionWallet); - callSignatures[0] = _explicitCallSignatureToJSON(0, callSignature); - - address[] memory explicitSigners = new address[](1); - explicitSigners[0] = sessionWallet.addr; - address[] memory implicitSigners = new address[](0); - - // Construct signature - bytes memory sessionSignatures = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - string memory signatures = - string(abi.encodePacked(vm.toString(address(sessionManager)), ":sapient:", vm.toString(sessionSignatures))); - bytes memory sessionSignature = PrimitivesRPC.toEncodedSignature(vm, config, signatures, !payload2.noChainId); - - // Execute - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload2), sessionSignature); - - // Check the EOA signature is not valid anymore - vm.expectRevert(abi.encodeWithSelector(Nonce.BadNonce.selector, payload1.space, payload1.nonce, payload1.nonce + 1)); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload1), eoaSignature); - } - - function test_DOS_Wallet_StaticSignatureRace( - uint160 space - ) public { - space = uint160(bound(space, 0, sessionManager.MAX_SPACE())); - - // Create wallet with sessions. - string memory topology = _createDefaultTopology(); - (Stage1Module wallet, string memory config,) = _createWallet(topology); - - // Build payload for wallet to approve via static signature - Payload.Decoded memory payload1 = _buildPayload(1); - payload1.calls = new Payload.Call[](1); - payload1.calls[0].to = address(mockTarget); - payload1.calls[0].data = "0x12345678"; - payload1.noChainId = false; - payload1.space = space; - - // Approve it - vm.prank(address(wallet)); - wallet.setStaticSignature(payload1.hashFor(address(wallet)), identityWallet.addr, uint96(block.timestamp + 1 days)); - bytes memory staticSignature = bytes(abi.encodePacked(bytes1(0x80))); - - //FIXME Check it is approved without running it - // vm.prank(identityWallet.addr); - // wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload1), staticSignature); - - // Sign a payload with the same nonce to race execution - Payload.Decoded memory payload2 = _buildPayload(1); - payload2.calls = new Payload.Call[](1); - payload2.calls[0].to = address(mockTarget); - payload2.calls[0].data = "0x87654321"; - payload2.space = payload1.space; - payload2.nonce = payload1.nonce; - - string[] memory callSignatures = new string[](1); - bytes32 callHash = SessionSig.hashCallWithReplayProtection(payload2, 0); - string memory callSignature = _signAndEncodeRSV(callHash, sessionWallet); - callSignatures[0] = _explicitCallSignatureToJSON(0, callSignature); - - address[] memory explicitSigners = new address[](1); - explicitSigners[0] = sessionWallet.addr; - address[] memory implicitSigners = new address[](0); - - // Construct signature - bytes memory sessionSignatures = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - string memory signatures = - string(abi.encodePacked(vm.toString(address(sessionManager)), ":sapient:", vm.toString(sessionSignatures))); - bytes memory sessionSignature = PrimitivesRPC.toEncodedSignature(vm, config, signatures, !payload2.noChainId); - - // Execute - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload2), sessionSignature); - - // Check the static signature is not valid anymore - vm.expectRevert(abi.encodeWithSelector(Nonce.BadNonce.selector, payload1.space, payload1.nonce, payload1.nonce + 1)); - vm.prank(identityWallet.addr); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload1), staticSignature); - } - - function test_DOS_Wallet_SpaceBlockedHighRange( - uint160 space - ) public { - space = uint160(bound(space, sessionManager.MAX_SPACE() + 1, type(uint160).max)); - - // Create wallet with sessions. - string memory topology = _createDefaultTopology(); - (Stage1Module wallet, string memory config,) = _createWallet(topology); - - // Sign a payload with the same nonce to race execution - Payload.Decoded memory payload = _buildPayload(1); - payload.calls = new Payload.Call[](1); - payload.calls[0].to = address(mockTarget); - payload.calls[0].data = "0x87654321"; - payload.space = space; - - string[] memory callSignatures = new string[](1); - bytes32 callHash = SessionSig.hashCallWithReplayProtection(payload, 0); - string memory callSignature = _signAndEncodeRSV(callHash, sessionWallet); - callSignatures[0] = _explicitCallSignatureToJSON(0, callSignature); - - address[] memory explicitSigners = new address[](1); - explicitSigners[0] = sessionWallet.addr; - address[] memory implicitSigners = new address[](0); - - // Construct signature - bytes memory sessionSignatures = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - string memory signatures = - string(abi.encodePacked(vm.toString(address(sessionManager)), ":sapient:", vm.toString(sessionSignatures))); - bytes memory sessionSignature = PrimitivesRPC.toEncodedSignature(vm, config, signatures, !payload.noChainId); - - // Execute blocked - vm.expectRevert(abi.encodeWithSelector(SessionErrors.InvalidSpace.selector, space)); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload), sessionSignature); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionLimitIncrementTest.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionLimitIncrementTest.t.sol deleted file mode 100644 index 7ddc7f6e1b..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionLimitIncrementTest.t.sol +++ /dev/null @@ -1,76 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { ExtendedSessionTestBase } from "./ExtendedSessionTestBase.sol"; -import { Vm, console } from "forge-std/Test.sol"; - -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; - -import { Factory } from "src/Factory.sol"; -import { Stage1Module } from "src/Stage1Module.sol"; -import { - SessionErrors, SessionManager, SessionPermissions, SessionSig -} from "src/extensions/sessions/SessionManager.sol"; -import { - ParameterOperation, ParameterRule, Permission, UsageLimit -} from "src/extensions/sessions/explicit/Permission.sol"; -import { Attestation } from "src/extensions/sessions/implicit/Attestation.sol"; -import { Calls } from "src/modules/Calls.sol"; -import { Payload } from "src/modules/Payload.sol"; - -/// @notice Session limit increment tests. -contract IntegrationSessionLimitIncrementTest is ExtendedSessionTestBase { - - function test_SessionLimitIncrement_DoSSigner( - string memory signer2Name - ) public { - Vm.Wallet memory signer2 = vm.createWallet(signer2Name); - vm.assume(signer2.addr != sessionWallet.addr); - - // Create a topology with the session signer - string memory topology = _createDefaultTopology(); - // Add session signer 2 to the topology - SessionPermissions memory signer2Perms = SessionPermissions({ - signer: signer2.addr, - chainId: 0, - valueLimit: 0, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - signer2Perms.permissions[0] = Permission({ target: address(mockTarget), rules: new ParameterRule[](1) }); - signer2Perms.permissions[0].rules[0] = ParameterRule({ - cumulative: true, - operation: ParameterOperation.EQUAL, - value: bytes32(uint256(1)), - offset: 0, - mask: bytes32(0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff) - }); - string memory signer2PermsJson = _sessionPermissionsToJSON(signer2Perms); - topology = PrimitivesRPC.sessionExplicitAdd(vm, signer2PermsJson, topology); - // Create the wallet - (Stage1Module wallet, string memory config,) = _createWallet(topology); - - // Create a valid payload - UsageLimit[] memory usageLimits = new UsageLimit[](1); - usageLimits[0] = UsageLimit({ - usageHash: keccak256(abi.encode(signer2.addr, signer2Perms.permissions[0], uint256(0))), - usageAmount: uint256(1) - }); - - // Make the increment call with signer1 - Payload.Decoded memory signer1Payload = _buildPayload(1); - signer1Payload.calls[0].to = address(sessionManager); - signer1Payload.calls[0].data = abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, usageLimits); - signer1Payload.calls[0].behaviorOnError = Payload.BEHAVIOR_REVERT_ON_ERROR; - - // Sign it - bytes memory signer1Signature = - _validExplicitSignature(signer1Payload, sessionWallet, config, topology, new uint8[](1)); - - // Validate we can't DoS it - bytes memory packedSigner1Payload = PrimitivesRPC.toPackedPayload(vm, signer1Payload); - vm.expectRevert(abi.encodeWithSelector(SessionErrors.InvalidLimitUsageIncrement.selector)); - wallet.execute(packedSigner1Payload, signer1Signature); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionSelfCall.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionSelfCall.t.sol deleted file mode 100644 index 39fc666c85..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionSelfCall.t.sol +++ /dev/null @@ -1,72 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { ExtendedSessionTestBase, Vm } from "./ExtendedSessionTestBase.sol"; -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; - -import { Stage1Module } from "src/Stage1Module.sol"; -import { SessionErrors, SessionPermissions } from "src/extensions/sessions/SessionManager.sol"; -import { ParameterRule, Permission } from "src/extensions/sessions/explicit/Permission.sol"; - -import { Payload } from "src/modules/Payload.sol"; - -/// @notice Tests for sessions self-calling. -contract IntegrationSessionSelfCall is ExtendedSessionTestBase { - - using Payload for Payload.Decoded; - - function setUp() public override { - super.setUp(); - } - - function test_ExplicitSession_SelfCall( - bytes32 initImageHash - ) external { - // Deploy the wallet with an EOA signer - Stage1Module wallet = Stage1Module(payable(factory.deploy(address(module), initImageHash))); - - // Update the topology to include a session with self-call permissions - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: 0, - valueLimit: 0, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: address(wallet), rules: new ParameterRule[](0) }); - string memory topology = _createTopology(sessionPerms); - bytes32 sessionImageHash = PrimitivesRPC.sessionImageHash(vm, topology); - string memory ce = string( - abi.encodePacked("sapient:", vm.toString(sessionImageHash), ":", vm.toString(address(sessionManager)), ":1") - ); - string memory updatedConfig = PrimitivesRPC.newConfig(vm, 1, 0, ce); - bytes32 updatedImageHash = PrimitivesRPC.getImageHash(vm, updatedConfig); - - // Update the wallet to use the session image hash - vm.prank(address(wallet)); - wallet.updateImageHash(updatedImageHash); - - // Construct a self call payload - Payload.Decoded memory payload; - payload.kind = Payload.KIND_TRANSACTIONS; - payload.calls = new Payload.Call[](1); - payload.calls[0] = Payload.Call({ - to: address(wallet), - value: 0, - data: hex"12345678", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - // Sign with the session wallet - bytes memory signature = _validExplicitSignature(payload, sessionWallet, updatedConfig, topology, new uint8[](1)); - - // Execute the self call payload - bytes memory packedPayload = PrimitivesRPC.toPackedPayload(vm, payload); - vm.expectRevert(abi.encodeWithSelector(SessionErrors.InvalidSelfCall.selector)); - wallet.execute(packedPayload, signature); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionSignatureAbuse.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionSignatureAbuse.t.sol deleted file mode 100644 index 99bfc876d0..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionSignatureAbuse.t.sol +++ /dev/null @@ -1,143 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { ExtendedSessionTestBase } from "./ExtendedSessionTestBase.sol"; -import { Vm, console } from "forge-std/Test.sol"; - -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; - -import { Factory } from "src/Factory.sol"; -import { Stage1Module } from "src/Stage1Module.sol"; -import { - SessionErrors, SessionManager, SessionPermissions, SessionSig -} from "src/extensions/sessions/SessionManager.sol"; -import { - ParameterOperation, ParameterRule, Permission, UsageLimit -} from "src/extensions/sessions/explicit/Permission.sol"; -import { Attestation } from "src/extensions/sessions/implicit/Attestation.sol"; -import { Calls } from "src/modules/Calls.sol"; -import { Payload } from "src/modules/Payload.sol"; - -/// @notice Session signature abuse tests. -contract IntegrationSessionSignatureAbuseTest is ExtendedSessionTestBase { - - function test_SessionSigner_ZeroAddress_reverts_InvalidSessionSigner(uint8 v, bytes32 s) public { - // Create a topology with the session signer - string memory topology = _createDefaultTopology(); - - // Create a wallet with the topology - (Stage1Module wallet, string memory config,) = _createWallet(topology); - - // Build the payload - Payload.Decoded memory payload = _buildPayload(1); - payload.calls[0].to = address(mockTarget); - - // Build the signature - string[] memory callSignatures = new string[](1); - bytes32 payloadHash = SessionSig.hashCallWithReplayProtection(payload, 0); - bytes32 r = bytes32(0); // Force the signature to return address(0) - assertEq(ecrecover(payloadHash, v, r, s), address(0)); - callSignatures[0] = _explicitCallSignatureToJSON( - 0, string(abi.encodePacked(vm.toString(r), ":", vm.toString(s), ":", vm.toString(v))) - ); - address[] memory explicitSigners = new address[](1); - explicitSigners[0] = sessionWallet.addr; - address[] memory implicitSigners = new address[](0); - bytes memory sessionSignatures = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures, explicitSigners, implicitSigners); - string memory signatures = - string(abi.encodePacked(vm.toString(address(sessionManager)), ":sapient:", vm.toString(sessionSignatures))); - bytes memory encodedSignature = PrimitivesRPC.toEncodedSignature(vm, config, signatures, false); - - bytes memory packedPayload = PrimitivesRPC.toPackedPayload(vm, payload); - - // Execute - vm.expectRevert(abi.encodeWithSelector(SessionErrors.InvalidSessionSigner.selector, address(0))); - wallet.execute(packedPayload, encodedSignature); - } - - function test_PermissionIndex_OutOfRange_reverts_MissingPermission( - FuzzPermission[] memory fuzzPermissions, - uint8 permissionIndex - ) public { - // Create permissions for test - Permission[] memory permissions = _fuzzToPermissions(fuzzPermissions, 3, 3); - - permissionIndex = uint8(bound(permissionIndex, permissions.length, 2 ** 7 - 1)); - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: block.chainid, - valueLimit: 0, - deadline: uint64(block.timestamp + 1 days), - permissions: permissions - }); - - // Create a topology with the session signer - string memory topology = _createTopology(sessionPerms); - - // Create a wallet with the topology - (Stage1Module wallet, string memory config,) = _createWallet(topology); - - // Build the payload - Payload.Decoded memory payload = _buildPayload(1); - payload.calls[0].to = address(mockTarget); - - // Build the signature - uint8[] memory permissionIdxs = new uint8[](1); - permissionIdxs[0] = permissionIndex; - bytes memory signature = _validExplicitSignature(payload, sessionWallet, config, topology, permissionIdxs); - - // Execute - vm.expectRevert(abi.encodeWithSelector(SessionErrors.MissingPermission.selector, permissionIndex)); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload), signature); - } - - function test_CrossChain_ReplayProtection_RepeatableCall() public { - // Create default wallet - string memory topology = _createDefaultTopology(); - (Stage1Module wallet, string memory config,) = _createWallet(topology); - - // Build cross chain supported payload - Payload.Decoded memory payload1 = _buildPayload(1); - payload1.noChainId = true; - payload1.calls[0].to = address(mockTarget); - - // Sign - string[] memory callSignatures1 = new string[](1); - bytes32 callHash = SessionSig.hashCallWithReplayProtection(payload1, 0); - string memory sessionSignature = _signAndEncodeRSV(callHash, sessionWallet); - callSignatures1[0] = _explicitCallSignatureToJSON(0, sessionSignature); - - address[] memory explicitSigners = new address[](1); - explicitSigners[0] = sessionWallet.addr; - address[] memory implicitSigners = new address[](0); - - // Assume the signature is submitted on chain 1. Attacker reads signature and crafts replay attack, duplicating call for chain 2. - Payload.Decoded memory payload2 = _buildPayload(2); - payload2.noChainId = true; - payload2.calls[0] = payload1.calls[0]; - payload2.calls[1] = payload1.calls[0]; - - // Sign - string[] memory callSignatures2 = new string[](2); - callSignatures2[0] = callSignatures1[0]; - callSignatures2[1] = callSignatures1[0]; - - // Construct signature - bytes memory sessionSignatures2 = - PrimitivesRPC.sessionEncodeCallSignatures(vm, topology, callSignatures2, explicitSigners, implicitSigners); - string memory signatures2 = - string(abi.encodePacked(vm.toString(address(sessionManager)), ":sapient:", vm.toString(sessionSignatures2))); - bytes memory signature2 = PrimitivesRPC.toEncodedSignature(vm, config, signatures2, !payload2.noChainId); - - // Execute - try wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload2), signature2) { - revert("Execution should fail"); - } catch (bytes memory reason) { - // We don't validate the address in the error - bytes4 errorSelector = bytes4(reason); - assertEq(errorSelector, SessionErrors.InvalidSessionSigner.selector); - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionUsingERC4337.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionUsingERC4337.t.sol deleted file mode 100644 index f6d8ec6d3d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionUsingERC4337.t.sol +++ /dev/null @@ -1,142 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { ExtendedSessionTestBase } from "./ExtendedSessionTestBase.sol"; - -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; - -import { IEntryPoint } from "account-abstraction/core/EntryPoint.sol"; -import { PackedUserOperation } from "account-abstraction/core/UserOperationLib.sol"; -import { Stage1Module } from "src/Stage1Module.sol"; -import { SessionErrors } from "src/extensions/sessions/SessionManager.sol"; -import { ERC4337v07 } from "src/modules/ERC4337v07.sol"; -import { Payload } from "src/modules/Payload.sol"; - -/// @notice Tests for sessions using ERC4337. -contract IntegrationSessionUsing4337 is ExtendedSessionTestBase { - - using Payload for Payload.Decoded; - - function setUp() public override { - super.setUp(); - } - - function _prepareUserOp( - address sender - ) internal returns (PackedUserOperation memory) { - // Create a payload to call the mock target contract. - Payload.Decoded memory decodedPayload; - decodedPayload.kind = Payload.KIND_TRANSACTIONS; - decodedPayload.calls = new Payload.Call[](1); - decodedPayload.calls[0] = Payload.Call({ - to: address(mockTarget), - value: 0, - data: hex"12345678", - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - bytes memory packedPayload = PrimitivesRPC.toPackedPayload(vm, decodedPayload); - - // Gas stuff - uint256 verificationGasLimit = 1_000_000; - uint256 callGasLimit = 100_000; - uint256 preVerificationGas = 100_000; - uint256 maxFeePerGas = block.basefee; - uint256 maxPriorityFeePerGas = block.basefee; - uint256 totalGasLimit = verificationGasLimit + callGasLimit + preVerificationGas; - vm.deal(sender, totalGasLimit * (maxFeePerGas + maxPriorityFeePerGas)); - - // Construct the UserOp. - PackedUserOperation memory userOp; - userOp.callData = abi.encodeWithSelector(ERC4337v07.executeUserOp.selector, packedPayload); - userOp.sender = sender; - userOp.nonce = 0; - userOp.initCode = ""; - userOp.accountGasLimits = bytes32(abi.encodePacked(uint128(verificationGasLimit), uint128(callGasLimit))); - userOp.preVerificationGas = preVerificationGas; - userOp.gasFees = bytes32(abi.encodePacked(uint128(maxPriorityFeePerGas), uint128(maxFeePerGas))); - userOp.paymasterAndData = ""; - - return userOp; - } - - function test_ExplicitSession_ERC4337_InvalidPayloadKind( - address beneficiary - ) external { - vm.assume(beneficiary != address(0)); - beneficiary = boundNoPrecompile(beneficiary); - vm.assume(beneficiary.code.length == 0); - - // Deploy the wallet - string memory topology = _createDefaultTopology(); - (Stage1Module wallet, string memory config,) = _createWallet(topology); - - // Get the userOpHash that the EntryPoint will use by calling its getUserOpHash function - PackedUserOperation memory userOp = _prepareUserOp(address(wallet)); - bytes32 userOpHash = entryPoint.getUserOpHash(userOp); - - // Create a signature for the userOpHash using the session wallet. - Payload.Decoded memory payload; - payload.kind = Payload.KIND_DIGEST; - payload.digest = userOpHash; - - bytes memory signature = _validExplicitSignature(payload, sessionWallet, config, topology, new uint8[](1)); - userOp.signature = signature; - - PackedUserOperation[] memory ops = new PackedUserOperation[](1); - ops[0] = userOp; - - // Check execution fails with the expected error. - vm.expectRevert( - abi.encodeWithSelector( - IEntryPoint.FailedOpWithRevert.selector, - 0, - "AA23 reverted", - abi.encodePacked(SessionErrors.InvalidPayloadKind.selector) - ) - ); - entryPoint.handleOps(ops, payable(beneficiary)); - } - - function test_ImplicitSession_ERC4337_InvalidPayloadKind( - address beneficiary - ) external { - vm.assume(beneficiary != address(0)); - beneficiary = boundNoPrecompile(beneficiary); - vm.assume(beneficiary.code.length == 0); - - // Deploy the wallet - string memory topology = _createDefaultTopology(); - (Stage1Module wallet, string memory config,) = _createWallet(topology); - - // Get the userOpHash that the EntryPoint will use by calling its getUserOpHash function - PackedUserOperation memory userOp = _prepareUserOp(address(wallet)); - bytes32 userOpHash = entryPoint.getUserOpHash(userOp); - - // Create a signature for the userOpHash using the session wallet. - Payload.Decoded memory payload; - payload.kind = Payload.KIND_DIGEST; - payload.digest = userOpHash; - - bytes memory signature = _validImplicitSignature(payload, sessionWallet, config, topology); - userOp.signature = signature; - - PackedUserOperation[] memory ops = new PackedUserOperation[](1); - ops[0] = userOp; - - // Check execution fails with the expected error. - vm.expectRevert( - abi.encodeWithSelector( - IEntryPoint.FailedOpWithRevert.selector, - 0, - "AA23 reverted", - abi.encodePacked(SessionErrors.InvalidPayloadKind.selector) - ) - ); - entryPoint.handleOps(ops, payable(beneficiary)); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionValueForwarding.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionValueForwarding.t.sol deleted file mode 100644 index 95b82db5f3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/extensions/sessions/SessionValueForwarding.t.sol +++ /dev/null @@ -1,295 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { ExtendedSessionTestBase } from "./ExtendedSessionTestBase.sol"; -import { Vm, console } from "forge-std/Test.sol"; - -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; - -import { Factory } from "src/Factory.sol"; -import { Stage1Module } from "src/Stage1Module.sol"; -import { - SessionErrors, SessionManager, SessionPermissions, SessionSig -} from "src/extensions/sessions/SessionManager.sol"; -import { - ParameterOperation, ParameterRule, Permission, UsageLimit -} from "src/extensions/sessions/explicit/Permission.sol"; -import { Attestation } from "src/extensions/sessions/implicit/Attestation.sol"; -import { Calls } from "src/modules/Calls.sol"; -import { Nonce } from "src/modules/Nonce.sol"; -import { Payload } from "src/modules/Payload.sol"; -import { ValueForwarder } from "test/mocks/ValueForwarder.sol"; - -/// @notice Checks for value forwarding by sessions. -contract IntegrationSessionValueForwardingTest is ExtendedSessionTestBase { - - using Payload for Payload.Decoded; - - ValueForwarder public valueForwarder; - - function setUp() public override { - super.setUp(); - valueForwarder = new ValueForwarder(); - } - - function test_ValueForwarding_Explicit_Limited( - uint256 chainId, - uint160 space, - address recipient, - uint256 valueSent, - uint256 valueCap - ) public { - vm.assume(recipient.code.length == 0); - chainId = bound(chainId, 0, 2 ** 26 - 1); - if (chainId != 0) { - vm.chainId(chainId); - } - space = uint160(bound(space, 0, sessionManager.MAX_SPACE())); - valueSent = bound(valueSent, 2, 100 ether); - valueCap = bound(valueCap, 1, valueSent - 1); // Under value sent - - // Create wallet with sessions - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: chainId, - valueLimit: valueCap, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: address(valueForwarder), rules: new ParameterRule[](0) }); - string memory topology = _createTopology(sessionPerms); - (Stage1Module wallet, string memory config,) = _createWallet(topology); - vm.assume(address(wallet) != recipient); - - // Give enough ETH for transfer - vm.deal(address(wallet), valueSent); - - // Build payload for transfer - Payload.Decoded memory payload = _buildPayload(2); - payload.noChainId = chainId == 0; - payload.space = space; - // Increment - UsageLimit[] memory limits = new UsageLimit[](1); - limits[0].usageHash = keccak256(abi.encode(sessionWallet.addr, VALUE_TRACKING_ADDRESS)); - limits[0].usageAmount = valueSent; - payload.calls[0].to = address(sessionManager); - payload.calls[0].data = abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, limits); - payload.calls[0].behaviorOnError = Payload.BEHAVIOR_REVERT_ON_ERROR; - // Send value - payload.calls[1].to = address(valueForwarder); - payload.calls[1].data = abi.encodeWithSelector(valueForwarder.forwardValue.selector, recipient, valueSent); - payload.calls[1].value = valueSent; - payload.calls[1].behaviorOnError = Payload.BEHAVIOR_REVERT_ON_ERROR; - - // Sign it with the session - bytes memory signature = _validExplicitSignature(payload, sessionWallet, config, topology, new uint8[](2)); - - // Execute should fail due to limit exceeded - vm.expectRevert(SessionErrors.InvalidValue.selector); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload), signature); - - // Drop the usage below the limit - valueSent = bound(valueSent, 1, valueCap); - limits[0].usageAmount = valueSent; - payload.calls[0].data = abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, limits); - payload.calls[1].data = abi.encodeWithSelector(valueForwarder.forwardValue.selector, recipient, valueSent); - payload.calls[1].value = valueSent; - - // Sign and execute successfully - signature = _validExplicitSignature(payload, sessionWallet, config, topology, new uint8[](2)); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload), signature); - - // Check the balance of the recipient - assertEq(address(recipient).balance, valueSent); - - // Try to spend above the limit with new payload - payload.nonce++; - valueSent = bound(valueSent, valueCap - valueSent + 1, 100 ether); - limits[0].usageAmount += valueSent; - payload.calls[0].data = abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, limits); - payload.calls[1].data = abi.encodeWithSelector(valueForwarder.forwardValue.selector, recipient, valueSent); - payload.calls[1].value = valueSent; - // Ensure the wallet has enough ETH - vm.deal(address(wallet), valueSent); - - // Sign and fail sending - signature = _validExplicitSignature(payload, sessionWallet, config, topology, new uint8[](2)); - vm.expectRevert(SessionErrors.InvalidValue.selector); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload), signature); - } - - function test_ValueForwarding_Explicit_OverMultipleCalls( - uint256 chainId, - uint160 space, - address recipient, - uint256 valueSent, - uint256 valueCap - ) public { - vm.assume(recipient.code.length == 0); - chainId = bound(chainId, 0, 2 ** 26 - 1); - if (chainId != 0) { - vm.chainId(chainId); - } - space = uint160(bound(space, 0, sessionManager.MAX_SPACE())); - valueCap = bound(valueCap, 1 ether, 100 ether); - // We will send 3 tx in a batch and want this to overflow - valueSent = bound(valueSent, valueCap / 2, 100 ether); - - // Create wallet with sessions - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: chainId, - valueLimit: valueCap, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](1) - }); - sessionPerms.permissions[0] = Permission({ target: address(valueForwarder), rules: new ParameterRule[](0) }); - string memory topology = _createTopology(sessionPerms); - (Stage1Module wallet, string memory config,) = _createWallet(topology); - vm.assume(address(wallet) != recipient); - - // Give enough ETH for transfer - vm.deal(address(wallet), valueCap); - - // Build payload for transfer - Payload.Decoded memory payload = _buildPayload(4); - payload.noChainId = chainId == 0; - payload.space = space; - // Increment - UsageLimit[] memory limits = new UsageLimit[](1); - limits[0].usageHash = keccak256(abi.encode(sessionWallet.addr, VALUE_TRACKING_ADDRESS)); - limits[0].usageAmount = valueSent * 3; - payload.calls[0].to = address(sessionManager); - payload.calls[0].data = abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, limits); - payload.calls[0].behaviorOnError = Payload.BEHAVIOR_REVERT_ON_ERROR; - // Send value - payload.calls[1].to = address(valueForwarder); - payload.calls[1].data = abi.encodeWithSelector(valueForwarder.forwardValue.selector, recipient, valueSent); - payload.calls[1].value = valueSent; - payload.calls[1].behaviorOnError = Payload.BEHAVIOR_REVERT_ON_ERROR; - payload.calls[2] = payload.calls[1]; - payload.calls[3] = payload.calls[1]; - - // Sign it with the session - bytes memory signature = _validExplicitSignature(payload, sessionWallet, config, topology, new uint8[](4)); - - // Execute should fail due to limit exceeded - vm.expectRevert(SessionErrors.InvalidValue.selector); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload), signature); - - // Drop the usage below the limit - valueSent = bound(valueSent, 1, valueCap / 3); - limits[0].usageAmount = valueSent * 3; - payload.calls[0].data = abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, limits); - payload.calls[1].data = abi.encodeWithSelector(valueForwarder.forwardValue.selector, recipient, valueSent); - payload.calls[1].value = valueSent; - payload.calls[2] = payload.calls[1]; - payload.calls[3] = payload.calls[1]; - - // Sign and execute successfully - signature = _validExplicitSignature(payload, sessionWallet, config, topology, new uint8[](4)); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload), signature); - - // Check the balance of the recipient - assertEq(address(recipient).balance, valueSent * 3); - - // Try to spend above the limit with new payload - payload.nonce++; - valueSent = bound(valueSent, ((valueCap - valueSent * 3) / 3) + 1, 100 ether); - limits[0].usageAmount += valueSent * 3; // Should be an increment - payload.calls[0].data = abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, limits); - payload.calls[1].data = abi.encodeWithSelector(valueForwarder.forwardValue.selector, recipient, valueSent); - payload.calls[1].value = valueSent; - payload.calls[2] = payload.calls[1]; - payload.calls[3] = payload.calls[1]; - // Ensure the wallet has enough ETH - vm.deal(address(wallet), valueSent * 3); - - // Sign and fail sending - signature = _validExplicitSignature(payload, sessionWallet, config, topology, new uint8[](4)); - vm.expectRevert(SessionErrors.InvalidValue.selector); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload), signature); - } - - function test_ValueForwarding_NoRequiredIncrementAfterIncrement( - uint256 chainId, - uint160 space, - address recipient, - uint256 valueSent, - uint256 valueCap - ) public { - vm.assume(recipient.code.length == 0); - chainId = bound(chainId, 0, 2 ** 26 - 1); - if (chainId != 0) { - vm.chainId(chainId); - } - space = uint160(bound(space, 0, sessionManager.MAX_SPACE())); - valueCap = bound(valueCap, 1 ether, 100 ether); - valueSent = bound(valueSent, 1, valueCap); - - // Create wallet with sessions - SessionPermissions memory sessionPerms = SessionPermissions({ - signer: sessionWallet.addr, - chainId: chainId, - valueLimit: valueCap, - deadline: uint64(block.timestamp + 1 days), - permissions: new Permission[](2) - }); - sessionPerms.permissions[0] = Permission({ target: address(valueForwarder), rules: new ParameterRule[](0) }); - sessionPerms.permissions[1] = Permission({ target: address(mockTarget), rules: new ParameterRule[](0) }); - string memory topology = _createTopology(sessionPerms); - (Stage1Module wallet, string memory config,) = _createWallet(topology); - vm.assume(address(wallet) != recipient); - - // Give enough ETH for transfer - vm.deal(address(wallet), valueCap); - - // Build payload for transfer - Payload.Decoded memory payload = _buildPayload(2); - payload.noChainId = chainId == 0; - payload.space = space; - // Increment - UsageLimit[] memory limits = new UsageLimit[](1); - limits[0].usageHash = keccak256(abi.encode(sessionWallet.addr, VALUE_TRACKING_ADDRESS)); - limits[0].usageAmount = valueSent; - payload.calls[0].to = address(sessionManager); - payload.calls[0].data = abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, limits); - payload.calls[0].behaviorOnError = Payload.BEHAVIOR_REVERT_ON_ERROR; - // Send value - payload.calls[1].to = address(valueForwarder); - payload.calls[1].data = abi.encodeWithSelector(valueForwarder.forwardValue.selector, recipient, valueSent); - payload.calls[1].value = valueSent; - payload.calls[1].behaviorOnError = Payload.BEHAVIOR_REVERT_ON_ERROR; - - // Sign it with the session - bytes memory signature = _validExplicitSignature(payload, sessionWallet, config, topology, new uint8[](2)); - - uint256 recipientBalance = address(recipient).balance; - // Sign and execute successfully - signature = _validExplicitSignature(payload, sessionWallet, config, topology, new uint8[](4)); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload), signature); - - // Check the balance of the recipient - assertEq(address(recipient).balance, recipientBalance + valueSent); - - // Try another payload that doesn't use an increment permission - payload = _buildPayload(2); - payload.noChainId = chainId == 0; - payload.space = space; - payload.nonce = 1; - // Note: It still needs an increment call, even though there is no increment usage... - payload.calls[0].to = address(sessionManager); - payload.calls[0].data = abi.encodeWithSelector(sessionManager.incrementUsageLimit.selector, limits); - payload.calls[0].behaviorOnError = Payload.BEHAVIOR_REVERT_ON_ERROR; - // Call mock target - payload.calls[1].to = address(mockTarget); - payload.calls[1].data = "0x12345678"; - - // Sign and send success - uint8[] memory permsUsed = new uint8[](2); - permsUsed[1] = 1; // Uses mockTarget permission - signature = _validExplicitSignature(payload, sessionWallet, config, topology, permsUsed); - wallet.execute(PrimitivesRPC.toPackedPayload(vm, payload), signature); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/modules/ERC4337v07/ERC4337Entrypoint.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/modules/ERC4337v07/ERC4337Entrypoint.t.sol deleted file mode 100644 index 881a200424..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/integrations/modules/ERC4337v07/ERC4337Entrypoint.t.sol +++ /dev/null @@ -1,179 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Factory, Wallet } from "src/Factory.sol"; -import { Stage1Module } from "src/Stage1Module.sol"; -import { ERC4337v07 } from "src/modules/ERC4337v07.sol"; -import { Payload } from "src/modules/Payload.sol"; - -import { Emitter } from "test/mocks/Emitter.sol"; -import { PrimitivesRPC } from "test/utils/PrimitivesRPC.sol"; -import { AdvTest, Vm } from "test/utils/TestUtils.sol"; - -import { EntryPoint } from "account-abstraction/core/EntryPoint.sol"; -import { PackedUserOperation, UserOperationLib } from "account-abstraction/core/UserOperationLib.sol"; - -contract IntegrationERC4337v07Test is AdvTest { - - Factory public factory; - EntryPoint public entryPoint; - Stage1Module public stage1Module; - address payable public wallet; - string public walletConfig; - bytes32 public walletImageHash; - Vm.Wallet public signer; - Emitter public emitter; - - function setUp() public { - factory = new Factory(); - entryPoint = new EntryPoint(); - stage1Module = new Stage1Module(address(factory), address(entryPoint)); - - // Basic wallet setup for most tests. - signer = vm.createWallet("signer"); - walletConfig = - PrimitivesRPC.newConfig(vm, 1, 0, string(abi.encodePacked("signer:", vm.toString(signer.addr), ":1"))); - walletImageHash = PrimitivesRPC.getImageHash(vm, walletConfig); - - // Setup a mock contract to call. - emitter = new Emitter(); - } - - // --- Helper Functions --- - - function hashRealUserOp( - PackedUserOperation calldata userOp - ) public pure returns (bytes32) { - return UserOperationLib.hash(userOp); - } - - function predictWalletAddress( - bytes32 imageHash - ) public view returns (address) { - bytes memory code = abi.encodePacked(Wallet.creationCode, uint256(uint160(address(stage1Module)))); - bytes32 initCodeHash = keccak256(code); - - return address(uint160(uint256(keccak256(abi.encodePacked(hex"ff", address(factory), imageHash, initCodeHash))))); - } - - // --- tests --- - - function _prepareUserOp( - address sender - ) internal returns (PackedUserOperation memory) { - // Create a payload to call the emitter contract. - Payload.Decoded memory decodedPayload; - decodedPayload.kind = Payload.KIND_TRANSACTIONS; - decodedPayload.calls = new Payload.Call[](1); - decodedPayload.calls[0] = Payload.Call({ - to: address(emitter), - value: 0, - data: abi.encodeWithSelector(Emitter.explicitEmit.selector), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - bytes memory packedPayload = PrimitivesRPC.toPackedPayload(vm, decodedPayload); - - // Gas stuff - uint256 verificationGasLimit = 1_000_000; - uint256 callGasLimit = 100_000; - uint256 preVerificationGas = 100_000; - uint256 maxFeePerGas = block.basefee; - uint256 maxPriorityFeePerGas = block.basefee; - uint256 totalGasLimit = verificationGasLimit + callGasLimit + preVerificationGas; - vm.deal(wallet, totalGasLimit * (maxFeePerGas + maxPriorityFeePerGas)); - - // Construct the UserOp. - PackedUserOperation memory userOp; - userOp.callData = abi.encodeWithSelector(ERC4337v07.executeUserOp.selector, packedPayload); - userOp.sender = sender; - userOp.nonce = 0; - userOp.initCode = ""; - userOp.accountGasLimits = bytes32(abi.encodePacked(uint128(verificationGasLimit), uint128(callGasLimit))); - userOp.preVerificationGas = preVerificationGas; - userOp.gasFees = bytes32(abi.encodePacked(uint128(maxPriorityFeePerGas), uint128(maxFeePerGas))); - userOp.paymasterAndData = ""; - - return userOp; - } - - function test_Entrypoint_happypath( - address beneficiary - ) external { - vm.assume(beneficiary != address(0)); - beneficiary = boundNoPrecompile(beneficiary); - vm.assume(beneficiary.code.length == 0); - - // Deploy the wallet - wallet = payable(factory.deploy(address(stage1Module), walletImageHash)); - - // Get the userOpHash that the EntryPoint will use by calling its getUserOpHash function - PackedUserOperation memory userOp = _prepareUserOp(wallet); - bytes32 userOpHash = entryPoint.getUserOpHash(userOp); - - // Create a signature for the userOpHash using the wallet's signer config. - Payload.Decoded memory payload; - payload.kind = Payload.KIND_DIGEST; - payload.digest = userOpHash; - bytes32 payloadDigest = Payload.hashFor(payload, wallet); - - // Create a signature for the userOpHash using the wallet's signer config. - (uint8 v, bytes32 r, bytes32 s) = vm.sign(signer, payloadDigest); - string memory signatures = string( - abi.encodePacked(vm.toString(signer.addr), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v)) - ); - userOp.signature = PrimitivesRPC.toEncodedSignature(vm, walletConfig, signatures, true); - - PackedUserOperation[] memory ops = new PackedUserOperation[](1); - ops[0] = userOp; - - // Call the entrypoint. - vm.expectEmit(true, false, false, true, address(emitter)); - emit Emitter.Explicit(wallet); - entryPoint.handleOps(ops, payable(beneficiary)); - } - - function test_Entrypoint_initcode( - address beneficiary - ) external { - vm.assume(beneficiary != address(0)); - beneficiary = boundNoPrecompile(beneficiary); - vm.assume(beneficiary.code.length == 0); - - address predictedWallet = predictWalletAddress(walletImageHash); - - // Prepare the userOp with initcode. - PackedUserOperation memory userOp = _prepareUserOp(predictedWallet); - userOp.initCode = abi.encodePacked( - address(factory), abi.encodeWithSelector(Factory.deploy.selector, address(stage1Module), walletImageHash) - ); - - // Get the userOpHash that the EntryPoint will use by calling its getUserOpHash function - bytes32 userOpHash = entryPoint.getUserOpHash(userOp); - - // Create a signature for the userOpHash using the wallet's signer config. - Payload.Decoded memory payload; - payload.kind = Payload.KIND_DIGEST; - payload.digest = userOpHash; - bytes32 payloadDigest = Payload.hashFor(payload, predictedWallet); - - // Create a signature for the userOpHash using the wallet's signer config. - (uint8 v, bytes32 r, bytes32 s) = vm.sign(signer, payloadDigest); - string memory signatures = string( - abi.encodePacked(vm.toString(signer.addr), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v)) - ); - userOp.signature = PrimitivesRPC.toEncodedSignature(vm, walletConfig, signatures, true); - - PackedUserOperation[] memory ops = new PackedUserOperation[](1); - ops[0] = userOp; - - // Call the entrypoint. - vm.expectEmit(true, false, false, true, address(emitter)); - emit Emitter.Explicit(predictedWallet); - entryPoint.handleOps(ops, payable(beneficiary)); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/AcceptAll.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/AcceptAll.sol deleted file mode 100644 index 2baa0ba5d3..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/AcceptAll.sol +++ /dev/null @@ -1,10 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -contract AcceptAll { - - fallback() external payable { } - - receive() external payable { } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/CanReenter.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/CanReenter.sol deleted file mode 100644 index 99e241b23d..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/CanReenter.sol +++ /dev/null @@ -1,11 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -contract CanReenter { - - function doAnotherCall(address target, bytes calldata data) external { - (bool success,) = target.call(data); - require(success, "Call failed"); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/Emitter.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/Emitter.sol deleted file mode 100644 index 84d0726a99..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/Emitter.sol +++ /dev/null @@ -1,39 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Attestation, LibAttestation } from "src/extensions/sessions/implicit/Attestation.sol"; - -import { ISignalsImplicitMode } from "src/extensions/sessions/implicit/ISignalsImplicitMode.sol"; -import { Payload } from "src/modules/interfaces/ISapient.sol"; - -contract Emitter is ISignalsImplicitMode { - - using LibAttestation for Attestation; - - event Implicit(address sender); - event Explicit(address sender); - - error InvalidCall(string reason); - - function implicitEmit() external { - emit Implicit(msg.sender); - } - - function explicitEmit() external { - emit Explicit(msg.sender); - } - - function acceptImplicitRequest( - address wallet, - Attestation calldata attestation, - Payload.Call calldata call - ) external pure returns (bytes32) { - if (call.data.length != 4 || bytes4(call.data[:4]) != this.implicitEmit.selector) { - return bytes32(0); - } - // WARNING: This contract does not validate the redirect URL. - // All implicit requests are accepted from any project. - return attestation.generateImplicitRequestMagic(wallet); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/MockERC20.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/MockERC20.sol deleted file mode 100644 index 157976f858..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/MockERC20.sol +++ /dev/null @@ -1,46 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -contract MockERC20 { - - mapping(address => uint256) public balanceOf; - mapping(address => mapping(address => uint256)) public allowance; - - uint256 public totalSupply; - string public name = "Mock Token"; - string public symbol = "MOCK"; - uint8 public decimals = 18; - - event Transfer(address indexed from, address indexed to, uint256 value); - event Approval(address indexed owner, address indexed spender, uint256 value); - - constructor() { - totalSupply = 1000000 * 10 ** decimals; - balanceOf[msg.sender] = totalSupply; - } - - function transfer(address to, uint256 amount) external returns (bool) { - require(balanceOf[msg.sender] >= amount, "Insufficient balance"); - balanceOf[msg.sender] -= amount; - balanceOf[to] += amount; - emit Transfer(msg.sender, to, amount); - return true; - } - - function approve(address spender, uint256 amount) external returns (bool) { - allowance[msg.sender][spender] = amount; - emit Approval(msg.sender, spender, amount); - return true; - } - - function transferFrom(address from, address to, uint256 amount) external returns (bool) { - require(balanceOf[from] >= amount, "Insufficient balance"); - require(allowance[from][msg.sender] >= amount, "Insufficient allowance"); - balanceOf[from] -= amount; - balanceOf[to] += amount; - allowance[from][msg.sender] -= amount; - emit Transfer(from, to, amount); - return true; - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/MockPayableReceiver.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/MockPayableReceiver.sol deleted file mode 100644 index f4cf5408ab..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/MockPayableReceiver.sol +++ /dev/null @@ -1,8 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -contract MockPayableReceiver { - - function receiveValue() external payable { } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/ValueForwarder.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/ValueForwarder.sol deleted file mode 100644 index d00b1930f2..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/mocks/ValueForwarder.sol +++ /dev/null @@ -1,14 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -/// @title ValueForwarder -/// @author Michael Standen -/// @notice Forwarder for value -contract ValueForwarder { - - function forwardValue(address to, uint256 value) external payable { - (bool success,) = to.call{ value: value }(""); - require(success, "ValueForwarder: Failed to forward value"); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/BaseSig.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/modules/BaseSig.t.sol deleted file mode 100644 index 9cf7ccffd1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/BaseSig.t.sol +++ /dev/null @@ -1,2550 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../../src/modules/Payload.sol"; -import { BaseSig } from "../../src/modules/auth/BaseSig.sol"; - -import { ICheckpointer, Snapshot } from "../../src/modules/interfaces/ICheckpointer.sol"; -import { ISapient, ISapientCompact } from "../../src/modules/interfaces/ISapient.sol"; -import { PrimitivesRPC } from "../utils/PrimitivesRPC.sol"; -import { AdvTest } from "../utils/TestUtils.sol"; -import { Vm } from "forge-std/Test.sol"; - -contract BaseSigImp { - - function recoverPub( - Payload.Decoded memory _payload, - bytes calldata _signature, - bool _ignoreCheckpointer, - address _checkpointer - ) external view returns (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) { - return BaseSig.recover(_payload, _signature, _ignoreCheckpointer, _checkpointer); - } - -} - -contract BaseSigTest is AdvTest { - - BaseSigImp public baseSigImp; - - function setUp() public { - baseSigImp = new BaseSigImp(); - } - - function test_recover_random_config_unsigned(uint256 _maxDepth, uint256 _seed) external { - _maxDepth = bound(_maxDepth, 1, 6); - - Payload.Decoded memory payload; - payload.noChainId = true; - - string memory config = PrimitivesRPC.randomConfig(vm, _maxDepth, _seed, 1, "none"); - bytes memory encodedConfig = PrimitivesRPC.toEncodedConfig(vm, config); - - (, uint256 weight, bytes32 imageHash,, bytes32 opHash) = - baseSigImp.recoverPub(payload, encodedConfig, true, address(0)); - - assertEq(weight, 0); - assertEq(imageHash, PrimitivesRPC.getImageHash(vm, config)); - assertEq(opHash, Payload.hashFor(payload, address(baseSigImp))); - } - - function test_recover_random_config_unsigned_skewed_left( - uint256 _seed - ) external { - uint256 _maxDepth = 54; - - Payload.Decoded memory payload; - payload.noChainId = true; - - string memory config = PrimitivesRPC.randomConfig(vm, _maxDepth, _seed, 1, "left"); - bytes memory encodedConfig = PrimitivesRPC.toEncodedConfig(vm, config); - - (, uint256 weight, bytes32 imageHash,, bytes32 opHash) = - baseSigImp.recoverPub(payload, encodedConfig, true, address(0)); - - assertEq(weight, 0); - assertEq(imageHash, PrimitivesRPC.getImageHash(vm, config)); - assertEq(opHash, Payload.hashFor(payload, address(baseSigImp))); - } - - function test_recover_random_config_unsigned_skewed_right( - uint256 _seed - ) external { - uint256 _maxDepth = 54; - - Payload.Decoded memory payload; - payload.noChainId = true; - - string memory config = PrimitivesRPC.randomConfig(vm, _maxDepth, _seed, 1, "right"); - bytes memory encodedConfig = PrimitivesRPC.toEncodedConfig(vm, config); - - (, uint256 weight, bytes32 imageHash,, bytes32 opHash) = - baseSigImp.recoverPub(payload, encodedConfig, true, address(0)); - - assertEq(weight, 0); - assertEq(imageHash, PrimitivesRPC.getImageHash(vm, config)); - assertEq(opHash, Payload.hashFor(payload, address(baseSigImp))); - } - - struct AddressWeightPair { - address addr; - uint8 weight; - } - - struct test_recover_one_signer_params { - AddressWeightPair[] prefix; - AddressWeightPair[] suffix; - Payload.Decoded payload; - uint16 threshold; - uint56 checkpoint; - uint8 weight; - uint256 pk; - bool useEthSign; - } - - function test_recover_one_signer( - test_recover_one_signer_params memory params - ) external { - vm.assume(params.prefix.length + params.suffix.length < 600); - - boundToLegalPayload(params.payload); - params.pk = boundPk(params.pk); - - address signer = vm.addr(params.pk); - - // The signer should not be in the prefix or suffix - // or we may end up with more weight than expected - for (uint256 i = 0; i < params.prefix.length; i++) { - vm.assume(params.prefix[i].addr != signer); - } - for (uint256 i = 0; i < params.suffix.length; i++) { - vm.assume(params.suffix[i].addr != signer); - } - - string memory config; - - { - string memory ce; - for (uint256 i = 0; i < params.prefix.length; i++) { - ce = string( - abi.encodePacked( - ce, "signer:", vm.toString(params.prefix[i].addr), ":", vm.toString(params.prefix[i].weight), " " - ) - ); - } - - ce = string(abi.encodePacked(ce, "signer:", vm.toString(signer), ":", vm.toString(params.weight))); - - for (uint256 i = 0; i < params.suffix.length; i++) { - ce = string( - abi.encodePacked( - ce, " signer:", vm.toString(params.suffix[i].addr), ":", vm.toString(params.suffix[i].weight) - ) - ); - } - - config = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - } - - bytes memory encodedSignature; - { - bytes32 payloadHash = Payload.hashFor(params.payload, address(baseSigImp)); - - if (params.useEthSign) { - payloadHash = keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", payloadHash)); - } - - (uint8 v, bytes32 r, bytes32 s) = vm.sign(params.pk, payloadHash); - - string memory signatureType; - if (params.useEthSign) { - signatureType = ":eth_sign:"; - } else { - signatureType = ":hash:"; - } - - string memory signatures = string( - abi.encodePacked(vm.toString(signer), signatureType, vm.toString(r), ":", vm.toString(s), ":", vm.toString(v)) - ); - - encodedSignature = PrimitivesRPC.toEncodedSignature(vm, config, signatures, !params.payload.noChainId); - } - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, encodedSignature, true, address(0)); - - assertEq(threshold, params.threshold); - assertEq(imageHash, PrimitivesRPC.getImageHash(vm, config)); - assertEq(checkpoint, params.checkpoint); - assertEq(weight, params.weight); - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_recover_one_1271_signer_params { - AddressWeightPair[] prefix; - AddressWeightPair[] suffix; - Payload.Decoded payload; - uint16 threshold; - uint56 checkpoint; - uint8 weight; - address signer; - bytes signature; - } - - function test_recover_one_1271_signer( - test_recover_one_1271_signer_params memory params - ) external { - assumeNotPrecompile2(params.signer); - vm.assume(params.prefix.length + params.suffix.length < 600); - - // The signer should not be in the prefix or suffix - // or we may end up with more weight than expected - for (uint256 i = 0; i < params.prefix.length; i++) { - vm.assume(params.prefix[i].addr != params.signer); - } - for (uint256 i = 0; i < params.suffix.length; i++) { - vm.assume(params.suffix[i].addr != params.signer); - } - - boundToLegalPayload(params.payload); - - string memory config; - - { - string memory ce; - for (uint256 i = 0; i < params.prefix.length; i++) { - ce = string( - abi.encodePacked( - ce, "signer:", vm.toString(params.prefix[i].addr), ":", vm.toString(params.prefix[i].weight), " " - ) - ); - } - - ce = string(abi.encodePacked(ce, "signer:", vm.toString(params.signer), ":", vm.toString(params.weight))); - - for (uint256 i = 0; i < params.suffix.length; i++) { - ce = string( - abi.encodePacked( - ce, " signer:", vm.toString(params.suffix[i].addr), ":", vm.toString(params.suffix[i].weight) - ) - ); - } - - config = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - } - - bytes memory encodedSignature; - { - bytes32 payloadHash = Payload.hashFor(params.payload, address(baseSigImp)); - - vm.mockCall( - address(params.signer), - abi.encodeWithSignature("isValidSignature(bytes32,bytes)", payloadHash, params.signature), - abi.encode(bytes4(0x1626ba7e)) - ); - - vm.expectCall( - address(params.signer), - abi.encodeWithSignature("isValidSignature(bytes32,bytes)", payloadHash, params.signature) - ); - - string memory se = - string(abi.encodePacked(vm.toString(params.signer), ":erc1271:", vm.toString(params.signature))); - - encodedSignature = PrimitivesRPC.toEncodedSignature(vm, config, se, !params.payload.noChainId); - } - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, encodedSignature, true, address(0)); - - assertEq(threshold, params.threshold); - assertEq(imageHash, PrimitivesRPC.getImageHash(vm, config)); - assertEq(checkpoint, params.checkpoint); - assertEq(weight, params.weight); - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_recover_one_1271_invalid_signature_fail_params { - AddressWeightPair[] prefix; - AddressWeightPair[] suffix; - Payload.Decoded payload; - uint16 threshold; - uint56 checkpoint; - uint8 weight; - address signer; - bytes signature; - bytes revertFromSigner; - } - - function test_recover_one_1271_invalid_signature_revert_fail( - test_recover_one_1271_invalid_signature_fail_params memory params - ) external { - assumeNotPrecompile2(params.signer); - vm.assume(params.prefix.length + params.suffix.length < 600); - - // The signer should not be in the prefix or suffix - // or we may end up with more weight than expected - for (uint256 i = 0; i < params.prefix.length; i++) { - vm.assume(params.prefix[i].addr != params.signer); - } - for (uint256 i = 0; i < params.suffix.length; i++) { - vm.assume(params.suffix[i].addr != params.signer); - } - - boundToLegalPayload(params.payload); - - string memory config; - - { - string memory ce; - for (uint256 i = 0; i < params.prefix.length; i++) { - ce = string( - abi.encodePacked( - ce, "signer:", vm.toString(params.prefix[i].addr), ":", vm.toString(params.prefix[i].weight), " " - ) - ); - } - - ce = string(abi.encodePacked(ce, "signer:", vm.toString(params.signer), ":", vm.toString(params.weight))); - - for (uint256 i = 0; i < params.suffix.length; i++) { - ce = string( - abi.encodePacked( - ce, " signer:", vm.toString(params.suffix[i].addr), ":", vm.toString(params.suffix[i].weight) - ) - ); - } - - config = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - } - - bytes memory encodedSignature; - { - bytes32 payloadHash = Payload.hashFor(params.payload, address(baseSigImp)); - - vm.mockCallRevert( - address(params.signer), - abi.encodeWithSignature("isValidSignature(bytes32,bytes)", payloadHash, params.signature), - params.revertFromSigner - ); - - string memory se = - string(abi.encodePacked(vm.toString(params.signer), ":erc1271:", vm.toString(params.signature))); - - encodedSignature = PrimitivesRPC.toEncodedSignature(vm, config, se, !params.payload.noChainId); - } - - vm.expectRevert(params.revertFromSigner); - baseSigImp.recoverPub(params.payload, encodedSignature, true, address(0)); - } - - struct test_recover_one_1271_invalid_signature_bad_return_fail_params { - AddressWeightPair[] prefix; - AddressWeightPair[] suffix; - Payload.Decoded payload; - uint16 threshold; - uint56 checkpoint; - uint8 weight; - address signer; - bytes signature; - bytes4 bad4Bytes; - } - - function test_recover_one_1271_invalid_signature_bad_return_fail( - test_recover_one_1271_invalid_signature_bad_return_fail_params memory params - ) external { - assumeNotPrecompile2(params.signer); - vm.assume(params.prefix.length + params.suffix.length < 600); - - if (params.bad4Bytes == bytes4(0x1626ba7e)) { - params.bad4Bytes = bytes4(0x00000000); - } - - // The signer should not be in the prefix or suffix - // or we may end up with more weight than expected - for (uint256 i = 0; i < params.prefix.length; i++) { - vm.assume(params.prefix[i].addr != params.signer); - } - for (uint256 i = 0; i < params.suffix.length; i++) { - vm.assume(params.suffix[i].addr != params.signer); - } - - boundToLegalPayload(params.payload); - - string memory config; - - { - string memory ce; - for (uint256 i = 0; i < params.prefix.length; i++) { - ce = string( - abi.encodePacked( - ce, "signer:", vm.toString(params.prefix[i].addr), ":", vm.toString(params.prefix[i].weight), " " - ) - ); - } - - ce = string(abi.encodePacked(ce, "signer:", vm.toString(params.signer), ":", vm.toString(params.weight))); - - for (uint256 i = 0; i < params.suffix.length; i++) { - ce = string( - abi.encodePacked( - ce, " signer:", vm.toString(params.suffix[i].addr), ":", vm.toString(params.suffix[i].weight) - ) - ); - } - - config = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - } - - bytes memory encodedSignature; - bytes32 payloadHash = Payload.hashFor(params.payload, address(baseSigImp)); - - { - vm.mockCall( - address(params.signer), - abi.encodeWithSignature("isValidSignature(bytes32,bytes)", payloadHash, params.signature), - abi.encode(params.bad4Bytes) - ); - - string memory se = - string(abi.encodePacked(vm.toString(params.signer), ":erc1271:", vm.toString(params.signature))); - - encodedSignature = PrimitivesRPC.toEncodedSignature(vm, config, se, !params.payload.noChainId); - } - - vm.expectRevert( - abi.encodeWithSelector(BaseSig.InvalidERC1271Signature.selector, payloadHash, params.signer, params.signature) - ); - baseSigImp.recoverPub(params.payload, encodedSignature, true, address(0)); - } - - struct test_recover_one_sapient_signer_params { - AddressWeightPair[] prefix; - AddressWeightPair[] suffix; - Payload.Decoded payload; - uint16 threshold; - uint56 checkpoint; - uint8 weight; - address signer; - bytes signature; - bytes32 sapientImageHash; - bool isCompact; - } - - function test_recover_one_sapient_signer( - test_recover_one_sapient_signer_params memory params - ) external { - assumeNotPrecompile2(params.signer); - vm.assume(params.prefix.length + params.suffix.length < 600); - - // The signer should not be in the prefix or suffix - // or we may end up with more weight than expected - for (uint256 i = 0; i < params.prefix.length; i++) { - vm.assume(params.prefix[i].addr != params.signer); - } - for (uint256 i = 0; i < params.suffix.length; i++) { - vm.assume(params.suffix[i].addr != params.signer); - } - - boundToLegalPayload(params.payload); - - string memory config; - - { - string memory ce; - for (uint256 i = 0; i < params.prefix.length; i++) { - ce = string( - abi.encodePacked( - ce, "signer:", vm.toString(params.prefix[i].addr), ":", vm.toString(params.prefix[i].weight), " " - ) - ); - } - - ce = string( - abi.encodePacked( - ce, - "sapient:", - vm.toString(params.sapientImageHash), - ":", - vm.toString(params.signer), - ":", - vm.toString(params.weight) - ) - ); - - for (uint256 i = 0; i < params.suffix.length; i++) { - ce = string( - abi.encodePacked( - ce, " signer:", vm.toString(params.suffix[i].addr), ":", vm.toString(params.suffix[i].weight) - ) - ); - } - - config = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - } - - bytes memory encodedSignature; - { - string memory st; - - if (params.isCompact) { - st = ":sapient_compact:"; - bytes32 payloadHash = Payload.hashFor(params.payload, address(baseSigImp)); - - vm.mockCall( - address(params.signer), - abi.encodeWithSelector(ISapientCompact.recoverSapientSignatureCompact.selector, payloadHash, params.signature), - abi.encode(params.sapientImageHash) - ); - - vm.expectCall( - address(params.signer), - abi.encodeWithSelector(ISapientCompact.recoverSapientSignatureCompact.selector, payloadHash, params.signature) - ); - } else { - st = ":sapient:"; - vm.mockCall( - address(params.signer), - abi.encodeWithSelector(ISapient.recoverSapientSignature.selector, params.payload, params.signature), - abi.encode(params.sapientImageHash) - ); - - vm.expectCall( - address(params.signer), - abi.encodeWithSelector(ISapient.recoverSapientSignature.selector, params.payload, params.signature) - ); - } - - string memory se = string(abi.encodePacked(vm.toString(params.signer), st, vm.toString(params.signature))); - - encodedSignature = PrimitivesRPC.toEncodedSignature(vm, config, se, !params.payload.noChainId); - } - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, encodedSignature, true, address(0)); - - assertEq(threshold, params.threshold); - assertEq(imageHash, PrimitivesRPC.getImageHash(vm, config)); - assertEq(checkpoint, params.checkpoint); - assertEq(weight, params.weight); - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_recover_nested_config_params { - AddressWeightPair[] prefix; - AddressWeightPair[] suffix; - AddressWeightPair[] nestedPrefix; - AddressWeightPair[] nestedSuffix; - Payload.Decoded payload; - uint16 threshold; - uint56 checkpoint; - uint16 internalThreshold; - uint8 externalWeight; - uint8 weight; - uint256 pk; - bool useEthSign; - } - - function test_recover_nested_config( - test_recover_nested_config_params memory params - ) external { - vm.assume( - params.prefix.length + params.suffix.length + params.nestedPrefix.length + params.nestedSuffix.length < 600 - ); - - boundToLegalPayload(params.payload); - params.pk = boundPk(params.pk); - - address signer = vm.addr(params.pk); - - // The signer should not be in the prefix or suffix - // or we may end up with more weight than expected - for (uint256 i = 0; i < params.prefix.length; i++) { - vm.assume(params.prefix[i].addr != signer); - } - for (uint256 i = 0; i < params.suffix.length; i++) { - vm.assume(params.suffix[i].addr != signer); - } - - for (uint256 i = 0; i < params.nestedPrefix.length; i++) { - vm.assume(params.nestedPrefix[i].addr != signer); - } - for (uint256 i = 0; i < params.nestedSuffix.length; i++) { - vm.assume(params.nestedSuffix[i].addr != signer); - } - - string memory config; - - { - string memory ce; - for (uint256 i = 0; i < params.prefix.length; i++) { - ce = string( - abi.encodePacked( - ce, "signer:", vm.toString(params.prefix[i].addr), ":", vm.toString(params.prefix[i].weight), " " - ) - ); - } - - string memory nestedContent; - for (uint256 i = 0; i < params.nestedPrefix.length; i++) { - nestedContent = string( - abi.encodePacked( - nestedContent, - "signer:", - vm.toString(params.nestedPrefix[i].addr), - ":", - vm.toString(params.nestedPrefix[i].weight), - " " - ) - ); - } - - nestedContent = - string(abi.encodePacked(nestedContent, "signer:", vm.toString(signer), ":", vm.toString(params.weight))); - - for (uint256 i = 0; i < params.nestedSuffix.length; i++) { - nestedContent = string( - abi.encodePacked( - nestedContent, - " signer:", - vm.toString(params.nestedSuffix[i].addr), - ":", - vm.toString(params.nestedSuffix[i].weight) - ) - ); - } - - ce = string( - abi.encodePacked( - ce, - "nested:", - vm.toString(params.internalThreshold), - ":", - vm.toString(params.externalWeight), - ":(", - nestedContent, - ")" - ) - ); - - for (uint256 i = 0; i < params.suffix.length; i++) { - ce = string( - abi.encodePacked( - ce, " signer:", vm.toString(params.suffix[i].addr), ":", vm.toString(params.suffix[i].weight) - ) - ); - } - - config = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - } - - bytes memory encodedSignature; - { - bytes32 payloadHash = Payload.hashFor(params.payload, address(baseSigImp)); - - if (params.useEthSign) { - payloadHash = keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", payloadHash)); - } - - (uint8 v, bytes32 r, bytes32 s) = vm.sign(params.pk, payloadHash); - - string memory signatureType; - if (params.useEthSign) { - signatureType = ":eth_sign:"; - } else { - signatureType = ":hash:"; - } - - string memory se = string( - abi.encodePacked(vm.toString(signer), signatureType, vm.toString(r), ":", vm.toString(s), ":", vm.toString(v)) - ); - - encodedSignature = PrimitivesRPC.toEncodedSignature(vm, config, se, !params.payload.noChainId); - } - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, encodedSignature, true, address(0)); - - assertEq(threshold, params.threshold); - assertEq(imageHash, PrimitivesRPC.getImageHash(vm, config)); - assertEq(checkpoint, params.checkpoint); - assertEq(weight, params.weight >= params.internalThreshold ? params.externalWeight : 0); - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_recover_chained_signature_single_case_vars { - address signer1addr; - address signer2addr; - address signer3addr; - uint256 signer1pk; - uint256 signer2pk; - uint256 signer3pk; - string config1; - string config2; - string config3; - bytes32 config1Hash; - bytes32 config2Hash; - bytes32 config3Hash; - Payload.Decoded payloadApprove2; - Payload.Decoded payloadApprove3; - bytes signatureForFinalPayload; - bytes signature1to2; - bytes signature2to3; - uint8 v2; - bytes32 r2; - bytes32 s2; - uint8 v3; - bytes32 r3; - bytes32 s3; - uint8 fv; - bytes32 fr; - bytes32 fs; - } - - function test_recover_chained_signature_single_case( - Payload.Decoded memory _finalPayload - ) external { - boundToLegalPayload(_finalPayload); - - test_recover_chained_signature_single_case_vars memory vars; - - vars.signer1pk = 1; - vars.signer2pk = 2; - vars.signer3pk = 3; - - vars.signer1addr = vm.addr(vars.signer1pk); - vars.signer2addr = vm.addr(vars.signer2pk); - vars.signer3addr = vm.addr(vars.signer3pk); - - vars.config1 = - PrimitivesRPC.newConfig(vm, 1, 1, string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":1"))); - - vars.config2 = PrimitivesRPC.newConfig( - vm, - 1, - 2, - string( - abi.encodePacked( - "signer:", vm.toString(vars.signer2addr), ":3 ", "signer:", vm.toString(vars.signer1addr), ":2" - ) - ) - ); - - vars.config3 = PrimitivesRPC.newConfig( - vm, - 1, - 3, - string( - abi.encodePacked( - "signer:", vm.toString(vars.signer3addr), ":2 ", "signer:", vm.toString(vars.signer2addr), ":2" - ) - ) - ); - - vars.config1Hash = PrimitivesRPC.getImageHash(vm, vars.config1); - vars.config2Hash = PrimitivesRPC.getImageHash(vm, vars.config2); - vars.config3Hash = PrimitivesRPC.getImageHash(vm, vars.config3); - - vars.payloadApprove2.kind = Payload.KIND_CONFIG_UPDATE; - vars.payloadApprove3.kind = Payload.KIND_CONFIG_UPDATE; - - vars.payloadApprove2.imageHash = vars.config2Hash; - vars.payloadApprove3.imageHash = vars.config3Hash; - - { - (vars.v2, vars.r2, vars.s2) = vm.sign(vars.signer1pk, Payload.hashFor(vars.payloadApprove2, address(baseSigImp))); - (vars.v3, vars.r3, vars.s3) = vm.sign(vars.signer2pk, Payload.hashFor(vars.payloadApprove3, address(baseSigImp))); - (vars.fv, vars.fr, vars.fs) = vm.sign(vars.signer3pk, Payload.hashFor(_finalPayload, address(baseSigImp))); - - // Signature for final payload - vars.signatureForFinalPayload = PrimitivesRPC.toEncodedSignature( - vm, - vars.config3, - string( - abi.encodePacked( - vm.toString(vars.signer3addr), - ":hash:", - vm.toString(vars.fr), - ":", - vm.toString(vars.fs), - ":", - vm.toString(vars.fv) - ) - ), - !_finalPayload.noChainId - ); - - // Signatures for links, config3 -> config2 -> config1 - vars.signature1to2 = PrimitivesRPC.toEncodedSignature( - vm, - vars.config1, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), - ":hash:", - vm.toString(vars.r2), - ":", - vm.toString(vars.s2), - ":", - vm.toString(vars.v2) - ) - ), - true - ); - vars.signature2to3 = PrimitivesRPC.toEncodedSignature( - vm, - vars.config2, - string( - abi.encodePacked( - vm.toString(vars.signer2addr), - ":hash:", - vm.toString(vars.r3), - ":", - vm.toString(vars.s3), - ":", - vm.toString(vars.v3) - ) - ), - true - ); - } - - bytes[] memory signatures = new bytes[](3); - signatures[0] = vars.signatureForFinalPayload; - signatures[1] = vars.signature2to3; - signatures[2] = vars.signature1to2; - - bytes memory chainedSignature = PrimitivesRPC.concatSignatures(vm, signatures); - - // Recover chained signature - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(_finalPayload, chainedSignature, true, address(0)); - - assertEq(threshold, 1); - assertEq(weight, 1); - assertEq(imageHash, vars.config1Hash); - assertEq(checkpoint, 1); - assertEq(opHash, Payload.hashFor(_finalPayload, address(baseSigImp))); - } - - struct test_recover_subdigest_params { - Payload.Decoded payload; - AddressWeightPair[] prefix; - AddressWeightPair[] suffix; - uint16 threshold; - uint56 checkpoint; - } - - function test_recover_subdigest( - test_recover_subdigest_params memory params - ) public { - boundToLegalPayload(params.payload); - - bytes32 opHash = Payload.hashFor(params.payload, address(baseSigImp)); - - string memory ce; - - for (uint256 i = 0; i < params.prefix.length; i++) { - ce = - string.concat(ce, "signer:", vm.toString(params.prefix[i].addr), ":", vm.toString(params.prefix[i].weight), " "); - } - - ce = string.concat(ce, "subdigest:", vm.toString(opHash)); - - for (uint256 i = 0; i < params.suffix.length; i++) { - ce = - string.concat(ce, " ", "signer:", vm.toString(params.suffix[i].addr), ":", vm.toString(params.suffix[i].weight)); - } - - string memory config = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - - bytes memory encodedSig = PrimitivesRPC.toEncodedSignature(vm, config, "", !params.payload.noChainId); - bytes32 expectedImageHash = PrimitivesRPC.getImageHash(vm, config); - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 recoveredOpHash) = - baseSigImp.recoverPub(params.payload, encodedSig, true, address(0)); - - assertEq(threshold, params.threshold); - assertEq(checkpoint, params.checkpoint); - assertEq(weight, type(uint256).max); - assertEq(recoveredOpHash, opHash); - assertEq(imageHash, expectedImageHash); - } - - struct test_recover_anyAddressSubdigest_params { - Payload.Decoded payload; - AddressWeightPair[] prefix; - AddressWeightPair[] suffix; - uint16 threshold; - uint56 checkpoint; - } - - function test_recover_anyAddressSubdigest( - test_recover_anyAddressSubdigest_params memory params - ) public { - vm.assume(params.payload.calls.length < 5); - boundToLegalPayload(params.payload); - - bytes32 expectedAnyAddressDigest = Payload.hashFor(params.payload, address(0)); - bytes32 opHash = Payload.hashFor(params.payload, address(baseSigImp)); - - string memory ce; - - for (uint256 i = 0; i < params.prefix.length; i++) { - ce = - string.concat(ce, "signer:", vm.toString(params.prefix[i].addr), ":", vm.toString(params.prefix[i].weight), " "); - } - - ce = string.concat(ce, "any-address-subdigest:", vm.toString(expectedAnyAddressDigest)); - - for (uint256 i = 0; i < params.suffix.length; i++) { - ce = - string.concat(ce, " ", "signer:", vm.toString(params.suffix[i].addr), ":", vm.toString(params.suffix[i].weight)); - } - - string memory config = PrimitivesRPC.newConfig(vm, params.threshold, params.checkpoint, ce); - - bytes memory encodedSig = PrimitivesRPC.toEncodedSignature(vm, config, "", !params.payload.noChainId); - bytes32 expectedImageHash = PrimitivesRPC.getImageHash(vm, config); - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 recoveredOpHash) = - baseSigImp.recoverPub(params.payload, encodedSig, true, address(0)); - - assertEq(threshold, params.threshold); - assertEq(checkpoint, params.checkpoint); - assertEq(weight, type(uint256).max); - assertEq(recoveredOpHash, opHash); - assertEq(imageHash, expectedImageHash); - } - - function test_recover_invalid_signature_flag( - Payload.Decoded memory _payload, - uint8 checkpointSize, - uint8 thresholdSize, - uint8 invalidFlag - ) external { - boundToLegalPayload(_payload); - - invalidFlag = uint8(bound(invalidFlag, BaseSig.FLAG_SIGNATURE_SAPIENT_COMPACT + 1, 15)); - checkpointSize = uint8(bound(checkpointSize, 0, 7)); - thresholdSize = uint8(bound(thresholdSize, 0, 1)); - - uint8 signatureFlag = uint8((checkpointSize << 2) | (thresholdSize << 5)); - uint256 thresholdLen = thresholdSize + 1; - - bytes memory signature = new bytes(1 + checkpointSize + thresholdLen + 1); - signature[0] = bytes1(signatureFlag); - - signature[1 + checkpointSize + thresholdLen] = bytes1((invalidFlag << 4)); - - vm.expectRevert(abi.encodeWithSelector(BaseSig.InvalidSignatureFlag.selector, invalidFlag)); - baseSigImp.recoverPub(_payload, signature, false, address(0)); - } - - struct test_recover_chained_low_weight_fail_params { - Payload.Decoded payload; - uint256 threshold; - uint256 weight; - uint256 signer1pk; - uint256 signer2pk; - uint256 signer3pk; - } - - struct test_recover_chained_low_weight_fail_vars { - address signer1addr; - address signer2addr; - address signer3addr; - string config1; - string config2; - string config3; - bytes32 config1Hash; - bytes32 config2Hash; - bytes32 config3Hash; - Payload.Decoded payloadApprove2; - Payload.Decoded payloadApprove3; - bytes signatureForFinalPayload; - bytes signature1to2; - bytes signature2to3; - uint8 v2; - bytes32 r2; - bytes32 s2; - uint8 v3; - bytes32 r3; - bytes32 s3; - uint8 fv; - bytes32 fr; - bytes32 fs; - } - - function test_recover_chained_low_weight_fail( - test_recover_chained_low_weight_fail_params memory params - ) external { - boundToLegalPayload(params.payload); - params.weight = bound(params.weight, 0, type(uint8).max); - params.threshold = bound(params.threshold, params.weight + 1, type(uint16).max); - - test_recover_chained_low_weight_fail_vars memory vars; - - params.signer1pk = boundPk(params.signer1pk); - params.signer2pk = boundPk(params.signer2pk); - params.signer3pk = boundPk(params.signer3pk); - - vars.signer1addr = vm.addr(params.signer1pk); - vars.signer2addr = vm.addr(params.signer2pk); - vars.signer3addr = vm.addr(params.signer3pk); - - vars.config1 = - PrimitivesRPC.newConfig(vm, 1, 1, string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":1"))); - vars.config2 = PrimitivesRPC.newConfig( - vm, - uint16(params.threshold), - 2, - string(abi.encodePacked("signer:", vm.toString(vars.signer2addr), ":", vm.toString(params.weight))) - ); - vars.config3 = - PrimitivesRPC.newConfig(vm, 1, 3, string(abi.encodePacked("signer:", vm.toString(vars.signer3addr), ":3"))); - - vars.payloadApprove2.kind = Payload.KIND_CONFIG_UPDATE; - vars.payloadApprove3.kind = Payload.KIND_CONFIG_UPDATE; - - vars.payloadApprove2.imageHash = vars.config2Hash; - vars.payloadApprove3.imageHash = vars.config3Hash; - - { - (vars.v2, vars.r2, vars.s2) = - vm.sign(params.signer1pk, Payload.hashFor(vars.payloadApprove2, address(baseSigImp))); - (vars.v3, vars.r3, vars.s3) = - vm.sign(params.signer2pk, Payload.hashFor(vars.payloadApprove3, address(baseSigImp))); - (vars.fv, vars.fr, vars.fs) = vm.sign(params.signer3pk, Payload.hashFor(params.payload, address(baseSigImp))); - - vars.signatureForFinalPayload = PrimitivesRPC.toEncodedSignature( - vm, - vars.config3, - string( - abi.encodePacked( - vm.toString(vars.signer3addr), - ":hash:", - vm.toString(vars.fr), - ":", - vm.toString(vars.fs), - ":", - vm.toString(vars.fv) - ) - ), - !params.payload.noChainId - ); - - vars.signature1to2 = PrimitivesRPC.toEncodedSignature( - vm, - vars.config1, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), - ":hash:", - vm.toString(vars.r2), - ":", - vm.toString(vars.s2), - ":", - vm.toString(vars.v2) - ) - ), - true - ); - - vars.signature2to3 = PrimitivesRPC.toEncodedSignature( - vm, - vars.config2, - string( - abi.encodePacked( - vm.toString(vars.signer2addr), - ":hash:", - vm.toString(vars.r3), - ":", - vm.toString(vars.s3), - ":", - vm.toString(vars.v3) - ) - ), - true - ); - } - - bytes[] memory signatures = new bytes[](3); - signatures[0] = vars.signatureForFinalPayload; - signatures[1] = vars.signature2to3; - signatures[2] = vars.signature1to2; - - bytes memory chainedSignature = PrimitivesRPC.concatSignatures(vm, signatures); - - vm.expectRevert( - abi.encodeWithSelector(BaseSig.LowWeightChainedSignature.selector, signatures[1], params.threshold, params.weight) - ); - baseSigImp.recoverPub(params.payload, chainedSignature, true, address(0)); - } - - struct test_recover_chained_wrong_checkpoint_order_fail_params { - Payload.Decoded payload; - uint256 signer1pk; - uint256 signer2pk; - uint256 signer3pk; - uint256 checkpoint1; - uint256 checkpoint2; - uint256 checkpoint3; - } - - struct test_recover_chained_wrong_checkpoint_order_fail_vars { - address signer1addr; - address signer2addr; - address signer3addr; - string config1; - string config2; - string config3; - bytes32 config1Hash; - bytes32 config2Hash; - bytes32 config3Hash; - Payload.Decoded payloadApprove2; - Payload.Decoded payloadApprove3; - bytes signatureForFinalPayload; - bytes signature1to2; - bytes signature2to3; - uint8 v2; - bytes32 r2; - bytes32 s2; - uint8 v3; - bytes32 r3; - bytes32 s3; - uint8 fv; - bytes32 fr; - bytes32 fs; - } - - function test_recover_chained_wrong_checkpoint_order_fail( - test_recover_chained_wrong_checkpoint_order_fail_params memory params - ) external { - boundToLegalPayload(params.payload); - - params.checkpoint1 = bound(params.checkpoint1, 0, type(uint56).max); - params.checkpoint2 = bound(params.checkpoint2, 0, type(uint56).max); - params.checkpoint3 = bound(params.checkpoint3, 0, type(uint56).max); - - // Ensure that either checkpoint2 <= checkpoint1 or checkpoint3 <= checkpoint2 - if (params.checkpoint2 > params.checkpoint1) { - params.checkpoint1 = params.checkpoint2; - } - if (params.checkpoint3 > params.checkpoint2) { - params.checkpoint2 = params.checkpoint3; - } - - test_recover_chained_wrong_checkpoint_order_fail_vars memory vars; - - params.signer1pk = boundPk(params.signer1pk); - params.signer2pk = boundPk(params.signer2pk); - params.signer3pk = boundPk(params.signer3pk); - - vars.signer1addr = vm.addr(params.signer1pk); - vars.signer2addr = vm.addr(params.signer2pk); - vars.signer3addr = vm.addr(params.signer3pk); - - vars.config1 = PrimitivesRPC.newConfig( - vm, 1, params.checkpoint1, string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":1")) - ); - vars.config2 = PrimitivesRPC.newConfig( - vm, 2, params.checkpoint2, string(abi.encodePacked("signer:", vm.toString(vars.signer2addr), ":2")) - ); - vars.config3 = PrimitivesRPC.newConfig( - vm, 1, params.checkpoint3, string(abi.encodePacked("signer:", vm.toString(vars.signer3addr), ":3")) - ); - - vars.payloadApprove2.kind = Payload.KIND_CONFIG_UPDATE; - vars.payloadApprove3.kind = Payload.KIND_CONFIG_UPDATE; - - vars.payloadApprove2.imageHash = vars.config2Hash; - vars.payloadApprove3.imageHash = vars.config3Hash; - - { - (vars.v2, vars.r2, vars.s2) = - vm.sign(params.signer1pk, Payload.hashFor(vars.payloadApprove2, address(baseSigImp))); - (vars.v3, vars.r3, vars.s3) = - vm.sign(params.signer2pk, Payload.hashFor(vars.payloadApprove3, address(baseSigImp))); - (vars.fv, vars.fr, vars.fs) = vm.sign(params.signer3pk, Payload.hashFor(params.payload, address(baseSigImp))); - - vars.signatureForFinalPayload = PrimitivesRPC.toEncodedSignature( - vm, - vars.config3, - string( - abi.encodePacked( - vm.toString(vars.signer3addr), - ":hash:", - vm.toString(vars.fr), - ":", - vm.toString(vars.fs), - ":", - vm.toString(vars.fv) - ) - ), - !params.payload.noChainId - ); - - vars.signature1to2 = PrimitivesRPC.toEncodedSignature( - vm, - vars.config1, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), - ":hash:", - vm.toString(vars.r2), - ":", - vm.toString(vars.s2), - ":", - vm.toString(vars.v2) - ) - ), - true - ); - - vars.signature2to3 = PrimitivesRPC.toEncodedSignature( - vm, - vars.config2, - string( - abi.encodePacked( - vm.toString(vars.signer2addr), - ":hash:", - vm.toString(vars.r3), - ":", - vm.toString(vars.s3), - ":", - vm.toString(vars.v3) - ) - ), - true - ); - } - - bytes[] memory signatures = new bytes[](3); - signatures[0] = vars.signatureForFinalPayload; - signatures[1] = vars.signature2to3; - signatures[2] = vars.signature1to2; - - bytes memory chainedSignature = PrimitivesRPC.concatSignatures(vm, signatures); - - if (params.checkpoint3 > params.checkpoint2) { - vm.expectRevert( - abi.encodeWithSelector(BaseSig.WrongChainedCheckpointOrder.selector, params.checkpoint1, params.checkpoint2) - ); - } else { - vm.expectRevert( - abi.encodeWithSelector(BaseSig.WrongChainedCheckpointOrder.selector, params.checkpoint2, params.checkpoint3) - ); - } - baseSigImp.recoverPub(params.payload, chainedSignature, true, address(0)); - } - - // Checkpointer tests - - struct test_checkpointer_current_snapshot_params { - Payload.Decoded payload; - address checkpointer; - uint56 checkpoint; - uint256 signer1pk; - uint8 threshold; - uint8 weight; - bytes checkpointerData; - } - - struct test_checkpointer_current_snapshot_vars { - address signer1addr; - string configJson; - bytes32 expectedImageHash; - bytes signature; - Snapshot snapshot; - } - - function test_checkpointer_current_snapshot( - test_checkpointer_current_snapshot_params memory params - ) external { - vm.assume(params.payload.calls.length < 3); - test_checkpointer_current_snapshot_vars memory vars; - boundToLegalPayload(params.payload); - - params.checkpointer = boundNoPrecompile(params.checkpointer); - params.signer1pk = boundPk(params.signer1pk); - vars.signer1addr = vm.addr(params.signer1pk); - - params.weight = uint8(bound(params.weight, params.threshold, type(uint8).max)); - - vars.configJson = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - params.threshold, - params.checkpoint, - string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":", vm.toString(params.weight))) - ); - vars.expectedImageHash = PrimitivesRPC.getImageHash(vm, vars.configJson); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign(params.signer1pk, Payload.hashFor(params.payload, address(baseSigImp))); - - vars.signature = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.configJson, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v) - ) - ), - !params.payload.noChainId, - params.checkpointerData - ); - - vars.snapshot.imageHash = vars.expectedImageHash; - vars.snapshot.checkpoint = params.checkpoint; - - vm.mockCall( - params.checkpointer, abi.encodeWithSelector(ICheckpointer.snapshotFor.selector), abi.encode(vars.snapshot) - ); - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, vars.signature, false, address(0)); - assertEq(threshold, params.threshold); - assertEq(weight, params.weight); - assertEq(imageHash, vars.snapshot.imageHash); - assertEq(checkpoint, vars.snapshot.checkpoint); - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_checkpointer_migrate_from_no_checkpointer_params { - Payload.Decoded payload; - address checkpointer; - uint56 checkpoint1; - uint56 checkpoint2; - uint256 signer1pk; - uint256 signer2pk; - uint8 threshold; - uint8 weight; - bytes checkpointerData; - } - - struct test_checkpointer_migrate_from_no_checkpointer_vars { - address signer1addr; - address signer2addr; - string config1Json; - string config2Json; - bytes32 config1ImageHash; - bytes32 config2ImageHash; - bytes signature1to2; - bytes signature2toPayload; - bytes32 r1; - bytes32 r2; - bytes32 s1; - bytes32 s2; - uint8 v1; - uint8 v2; - Payload.Decoded payloadApprove2; - bytes chainedSignature; - Snapshot snapshot; - } - - function test_checkpointer_migrate_from_no_checkpointer( - test_checkpointer_migrate_from_no_checkpointer_params memory params - ) external { - vm.assume(params.payload.calls.length < 3); - test_checkpointer_migrate_from_no_checkpointer_vars memory vars; - boundToLegalPayload(params.payload); - - params.checkpointer = boundNoPrecompile(params.checkpointer); - params.signer1pk = boundPk(params.signer1pk); - params.signer2pk = boundPk(params.signer2pk); - vars.signer1addr = vm.addr(params.signer1pk); - vars.signer2addr = vm.addr(params.signer2pk); - - params.weight = uint8(bound(params.weight, params.threshold, type(uint8).max)); - - // Ensure checkpoint2 > checkpoint1 for proper ordering - params.checkpoint1 = uint56(bound(params.checkpoint1, 0, type(uint56).max - 1)); - params.checkpoint2 = uint56(bound(params.checkpoint2, params.checkpoint1 + 1, type(uint56).max)); - - // Create config1 (old config without checkpointer) - vars.config1Json = PrimitivesRPC.newConfig( - vm, - params.threshold, - params.checkpoint1, - string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":", vm.toString(params.weight))) - ); - vars.config1ImageHash = PrimitivesRPC.getImageHash(vm, vars.config1Json); - - // Create config2 (new config with checkpointer) - vars.config2Json = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - params.threshold, - params.checkpoint2, - string(abi.encodePacked("signer:", vm.toString(vars.signer2addr), ":", vm.toString(params.weight))) - ); - vars.config2ImageHash = PrimitivesRPC.getImageHash(vm, vars.config2Json); - - // Create config update payload from config1 to config2 - vars.payloadApprove2.kind = Payload.KIND_CONFIG_UPDATE; - vars.payloadApprove2.imageHash = vars.config2ImageHash; - vars.payloadApprove2.noChainId = true; - - // Sign the config update payload with config1 (no checkpointer) - (vars.v1, vars.r1, vars.s1) = vm.sign(params.signer1pk, Payload.hashFor(vars.payloadApprove2, address(baseSigImp))); - vars.signature1to2 = PrimitivesRPC.toEncodedSignature( - vm, - vars.config1Json, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), - ":hash:", - vm.toString(vars.r1), - ":", - vm.toString(vars.s1), - ":", - vm.toString(vars.v1) - ) - ), - false - ); - - // Sign the main payload with config2 (with checkpointer) - (vars.v2, vars.r2, vars.s2) = vm.sign(params.signer2pk, Payload.hashFor(params.payload, address(baseSigImp))); - vars.signature2toPayload = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.config2Json, - string( - abi.encodePacked( - vm.toString(vars.signer2addr), - ":hash:", - vm.toString(vars.r2), - ":", - vm.toString(vars.s2), - ":", - vm.toString(vars.v2) - ) - ), - !params.payload.noChainId, - params.checkpointerData - ); - - // Mock the checkpointer to return the new config's snapshot - vars.snapshot.imageHash = vars.config2ImageHash; - vars.snapshot.checkpoint = params.checkpoint2; - - vm.mockCall( - params.checkpointer, abi.encodeWithSelector(ICheckpointer.snapshotFor.selector), abi.encode(vars.snapshot) - ); - - // Create chained signature (reverse order: final signature first, then intermediate) - bytes[] memory signatures = new bytes[](2); - signatures[0] = vars.signature2toPayload; - signatures[1] = vars.signature1to2; - vars.chainedSignature = PrimitivesRPC.concatSignatures(vm, signatures); - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, vars.chainedSignature, false, address(0)); - assertEq(threshold, params.threshold); - assertEq(weight, params.weight); - assertEq(imageHash, vars.config1ImageHash); // Should recover to the first config in the chain - assertEq(checkpoint, params.checkpoint1); // Should use checkpoint from the first config - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_checkpointer_migrate_to_no_checkpointer_params { - Payload.Decoded payload; - address checkpointer; - uint56 checkpoint1; - uint56 checkpoint2; - uint256 signer1pk; - uint256 signer2pk; - uint8 threshold; - uint8 weight; - bytes checkpointerData; - } - - struct test_checkpointer_migrate_to_no_checkpointer_vars { - address signer1addr; - address signer2addr; - string config1Json; - string config2Json; - bytes32 config1ImageHash; - bytes32 config2ImageHash; - bytes signature1to2; - bytes signature2toPayload; - bytes32 r1; - bytes32 r2; - bytes32 s1; - bytes32 s2; - uint8 v1; - uint8 v2; - Payload.Decoded payloadApprove2; - bytes chainedSignature; - Snapshot snapshot; - } - - function test_checkpointer_migrate_to_no_checkpointer( - test_checkpointer_migrate_to_no_checkpointer_params memory params - ) external { - vm.assume(params.payload.calls.length < 3); - test_checkpointer_migrate_to_no_checkpointer_vars memory vars; - boundToLegalPayload(params.payload); - - params.checkpointer = boundNoPrecompile(params.checkpointer); - params.signer1pk = boundPk(params.signer1pk); - params.signer2pk = boundPk(params.signer2pk); - vars.signer1addr = vm.addr(params.signer1pk); - vars.signer2addr = vm.addr(params.signer2pk); - - params.weight = uint8(bound(params.weight, params.threshold, type(uint8).max)); - - // Ensure checkpoint2 > checkpoint1 for proper ordering - params.checkpoint1 = uint56(bound(params.checkpoint1, 0, type(uint56).max - 1)); - params.checkpoint2 = uint56(bound(params.checkpoint2, params.checkpoint1 + 1, type(uint56).max)); - - // Create config1 (old config with checkpointer) - vars.config1Json = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - params.threshold, - params.checkpoint1, - string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":", vm.toString(params.weight))) - ); - vars.config1ImageHash = PrimitivesRPC.getImageHash(vm, vars.config1Json); - - // Create config2 (new config without checkpointer) - vars.config2Json = PrimitivesRPC.newConfig( - vm, - params.threshold, - params.checkpoint2, - string(abi.encodePacked("signer:", vm.toString(vars.signer2addr), ":", vm.toString(params.weight))) - ); - vars.config2ImageHash = PrimitivesRPC.getImageHash(vm, vars.config2Json); - - // Create config update payload from config1 to config2 - vars.payloadApprove2.kind = Payload.KIND_CONFIG_UPDATE; - vars.payloadApprove2.imageHash = vars.config2ImageHash; - vars.payloadApprove2.noChainId = true; - - // Sign the config update payload with config1 (with checkpointer) - (vars.v1, vars.r1, vars.s1) = vm.sign(params.signer1pk, Payload.hashFor(vars.payloadApprove2, address(baseSigImp))); - vars.signature1to2 = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.config1Json, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), - ":hash:", - vm.toString(vars.r1), - ":", - vm.toString(vars.s1), - ":", - vm.toString(vars.v1) - ) - ), - false, - params.checkpointerData - ); - - // Sign the main payload with config2 (without checkpointer) - (vars.v2, vars.r2, vars.s2) = vm.sign(params.signer2pk, Payload.hashFor(params.payload, address(baseSigImp))); - vars.signature2toPayload = PrimitivesRPC.toEncodedSignature( - vm, - vars.config2Json, - string( - abi.encodePacked( - vm.toString(vars.signer2addr), - ":hash:", - vm.toString(vars.r2), - ":", - vm.toString(vars.s2), - ":", - vm.toString(vars.v2) - ) - ), - !params.payload.noChainId - ); - - // Mock the checkpointer to return the old config's snapshot - vars.snapshot.imageHash = vars.config1ImageHash; - vars.snapshot.checkpoint = params.checkpoint1; - - vm.mockCall( - params.checkpointer, abi.encodeWithSelector(ICheckpointer.snapshotFor.selector), abi.encode(vars.snapshot) - ); - - // Create chained signature (reverse order: final signature first, then intermediate) - bytes[] memory signatures = new bytes[](2); - signatures[0] = vars.signature2toPayload; - signatures[1] = vars.signature1to2; - vars.chainedSignature = PrimitivesRPC.concatSignatures(vm, signatures); - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, vars.chainedSignature, false, address(0)); - assertEq(threshold, params.threshold); - assertEq(weight, params.weight); - assertEq(imageHash, vars.config1ImageHash); // Should recover to the first config in the chain - assertEq(checkpoint, params.checkpoint1); // Should use checkpoint from the first config - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_checkpointer_migrate_from_snapshot_to_snapshot_params { - Payload.Decoded payload; - address checkpointerA; - address checkpointerB; - uint56 checkpoint1; - uint56 checkpoint2; - uint256 signerpk; - uint8 threshold; - uint8 weight; - bytes checkpointerAData; - } - - struct test_checkpointer_migrate_from_snapshot_to_snapshot_vars { - address signeraddr; - string config1Json; - string config2Json; - bytes32 config1ImageHash; - bytes32 config2ImageHash; - bytes signature1to2; - bytes signature2toPayload; - bytes32 r1; - bytes32 r2; - bytes32 s1; - bytes32 s2; - uint8 v1; - uint8 v2; - Payload.Decoded payloadApprove2; - bytes chainedSignature; - Snapshot snapshotA; - } - - function test_checkpointer_migrate_from_snapshot_to_snapshot( - test_checkpointer_migrate_from_snapshot_to_snapshot_params memory params - ) external { - vm.assume(params.payload.calls.length < 3); - test_checkpointer_migrate_from_snapshot_to_snapshot_vars memory vars; - boundToLegalPayload(params.payload); - - params.checkpointerA = boundNoPrecompile(params.checkpointerA); - params.checkpointerB = boundNoPrecompile(params.checkpointerB); - // Ensure checkpointerA != checkpointerB - vm.assume(params.checkpointerA != params.checkpointerB); - - params.signerpk = boundPk(params.signerpk); - vars.signeraddr = vm.addr(params.signerpk); - - params.weight = uint8(bound(params.weight, params.threshold, type(uint8).max)); - - // Ensure checkpoint2 > checkpoint1 for proper ordering - params.checkpoint1 = uint56(bound(params.checkpoint1, 0, type(uint56).max - 1)); - params.checkpoint2 = uint56(bound(params.checkpoint2, params.checkpoint1 + 1, type(uint56).max)); - - // Create config1 (old config with checkpointer A) - vars.config1Json = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointerA, - params.threshold, - params.checkpoint1, - string(abi.encodePacked("signer:", vm.toString(vars.signeraddr), ":", vm.toString(params.weight))) - ); - vars.config1ImageHash = PrimitivesRPC.getImageHash(vm, vars.config1Json); - - // Create config2 (new config with checkpointer B) - vars.config2Json = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointerB, - params.threshold, - params.checkpoint2, - string(abi.encodePacked("signer:", vm.toString(vars.signeraddr), ":", vm.toString(params.weight))) - ); - vars.config2ImageHash = PrimitivesRPC.getImageHash(vm, vars.config2Json); - - // Create config update payload from config1 to config2 - vars.payloadApprove2.kind = Payload.KIND_CONFIG_UPDATE; - vars.payloadApprove2.imageHash = vars.config2ImageHash; - vars.payloadApprove2.noChainId = true; - - // Sign the config update payload with config1 (with checkpointer A) - (vars.v1, vars.r1, vars.s1) = vm.sign(params.signerpk, Payload.hashFor(vars.payloadApprove2, address(baseSigImp))); - vars.signature1to2 = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.config1Json, - string( - abi.encodePacked( - vm.toString(vars.signeraddr), - ":hash:", - vm.toString(vars.r1), - ":", - vm.toString(vars.s1), - ":", - vm.toString(vars.v1) - ) - ), - false, - params.checkpointerAData - ); - - // Sign the main payload with config2 (with checkpointer B) - (vars.v2, vars.r2, vars.s2) = vm.sign(params.signerpk, Payload.hashFor(params.payload, address(baseSigImp))); - vars.signature2toPayload = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.config2Json, - string( - abi.encodePacked( - vm.toString(vars.signeraddr), - ":hash:", - vm.toString(vars.r2), - ":", - vm.toString(vars.s2), - ":", - vm.toString(vars.v2) - ) - ), - !params.payload.noChainId, - "" - ); - - // Mock checkpointer A to return the old config's snapshot - vars.snapshotA.imageHash = vars.config1ImageHash; - vars.snapshotA.checkpoint = params.checkpoint1; - - // Only checkpointer A is called - vm.mockCall( - params.checkpointerA, abi.encodeWithSelector(ICheckpointer.snapshotFor.selector), abi.encode(vars.snapshotA) - ); - - // Create chained signature (reverse order: final signature first, then intermediate) - bytes[] memory signatures = new bytes[](2); - signatures[0] = vars.signature2toPayload; - signatures[1] = vars.signature1to2; - vars.chainedSignature = PrimitivesRPC.concatSignatures(vm, signatures); - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, vars.chainedSignature, false, address(0)); - assertEq(threshold, params.threshold); - assertEq(weight, params.weight); - assertEq(imageHash, vars.config1ImageHash); // Should recover to the first config in the chain - assertEq(checkpoint, params.checkpoint1); // Should use checkpoint from the first config - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_checkpointer_higher_checkpoint_fail_params { - Payload.Decoded payload; - address checkpointer; - bytes checkpointerData; - uint56 checkpointerCheckpoint; - uint56 checkpoint; - uint256 signer1pk; - uint8 threshold; - uint8 weight; - } - - struct test_checkpointer_higher_checkpoint_fail_vars { - address signer1addr; - string configJson; - bytes32 expectedImageHash; - bytes signature; - Snapshot snapshot; - } - - function test_checkpointer_higher_checkpoint_fail( - test_checkpointer_higher_checkpoint_fail_params memory params - ) external { - boundToLegalPayload(params.payload); - - params.checkpointerCheckpoint = uint56(bound(params.checkpointerCheckpoint, 1, type(uint56).max)); - params.checkpoint = uint56(bound(params.checkpoint, 0, params.checkpointerCheckpoint - 1)); - - params.checkpointer = boundNoPrecompile(params.checkpointer); - params.signer1pk = boundPk(params.signer1pk); - - params.weight = uint8(bound(params.weight, params.threshold, type(uint8).max)); - - test_checkpointer_higher_checkpoint_fail_vars memory vars; - - vars.configJson = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - params.threshold, - params.checkpointerCheckpoint, - string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":", vm.toString(params.weight))) - ); - vars.expectedImageHash = PrimitivesRPC.getImageHash(vm, vars.configJson); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign(params.signer1pk, Payload.hashFor(params.payload, address(baseSigImp))); - - vars.signature = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.configJson, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v) - ) - ), - !params.payload.noChainId, - params.checkpointerData - ); - - vars.snapshot.imageHash = vars.expectedImageHash; - vars.snapshot.checkpoint = params.checkpointerCheckpoint; - - vm.mockCall( - params.checkpointer, abi.encodeWithSelector(ICheckpointer.snapshotFor.selector), abi.encode(vars.snapshot) - ); - - vm.expectRevert(abi.encodeWithSelector(BaseSig.UnusedSnapshot.selector, vars.snapshot)); - baseSigImp.recoverPub(params.payload, vars.signature, false, address(0)); - } - - struct test_checkpointer_different_image_hash_fail_params { - Payload.Decoded payload; - address checkpointer; - bytes checkpointerData; - uint56 checkpoint; - uint256 signer1pk; - uint8 threshold; - uint8 weight; - bytes32 differentImageHash; - } - - struct test_checkpointer_different_image_hash_fail_vars { - address signer1addr; - string configJson; - bytes32 expectedImageHash; - bytes signature; - Snapshot snapshot; - } - - function test_checkpointer_different_image_hash_fail( - test_checkpointer_different_image_hash_fail_params memory params - ) external { - vm.assume(params.differentImageHash != bytes32(0)); - - boundToLegalPayload(params.payload); - - params.checkpoint = uint56(bound(params.checkpoint, 0, type(uint56).max)); - params.checkpointer = boundNoPrecompile(params.checkpointer); - params.signer1pk = boundPk(params.signer1pk); - params.weight = uint8(bound(params.weight, params.threshold, type(uint8).max)); - - test_checkpointer_different_image_hash_fail_vars memory vars; - - vars.signer1addr = vm.addr(params.signer1pk); - vars.configJson = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - params.threshold, - params.checkpoint, - string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":", vm.toString(params.weight))) - ); - vars.expectedImageHash = PrimitivesRPC.getImageHash(vm, vars.configJson); - - // Ensure the different imageHash is actually different from the expected one and not zero - vm.assume(params.differentImageHash != vars.expectedImageHash); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign(params.signer1pk, Payload.hashFor(params.payload, address(baseSigImp))); - - vars.signature = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.configJson, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v) - ) - ), - !params.payload.noChainId, - params.checkpointerData - ); - - // Use the provided different imageHash - vars.snapshot.imageHash = params.differentImageHash; - vars.snapshot.checkpoint = params.checkpoint; - - vm.mockCall( - params.checkpointer, abi.encodeWithSelector(ICheckpointer.snapshotFor.selector), abi.encode(vars.snapshot) - ); - - vm.expectRevert(abi.encodeWithSelector(BaseSig.UnusedSnapshot.selector, vars.snapshot)); - baseSigImp.recoverPub(params.payload, vars.signature, false, address(0)); - } - - struct test_checkpointer_disabled_params { - Payload.Decoded payload; - address checkpointer; - uint56 checkpoint; - uint56 snapshotCheckpoint; - uint256 signer1pk; - uint8 threshold; - uint8 weight; - bytes checkpointerData; - } - - struct test_checkpointer_disabled_vars { - address signer1addr; - string configJson; - bytes32 expectedImageHash; - bytes signature; - Snapshot snapshot; - } - - function test_checkpointer_disabled( - test_checkpointer_disabled_params memory params - ) external { - vm.assume(params.payload.calls.length < 3); - test_checkpointer_disabled_vars memory vars; - boundToLegalPayload(params.payload); - - params.checkpointer = boundNoPrecompile(params.checkpointer); - params.signer1pk = boundPk(params.signer1pk); - vars.signer1addr = vm.addr(params.signer1pk); - - params.weight = uint8(bound(params.weight, params.threshold, type(uint8).max)); - - vars.configJson = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - params.threshold, - params.checkpoint, - string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":", vm.toString(params.weight))) - ); - vars.expectedImageHash = PrimitivesRPC.getImageHash(vm, vars.configJson); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign(params.signer1pk, Payload.hashFor(params.payload, address(baseSigImp))); - - vars.signature = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.configJson, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v) - ) - ), - !params.payload.noChainId, - params.checkpointerData - ); - - // Set imageHash to 0 to indicate checkpointer is disabled - vars.snapshot.imageHash = bytes32(0); - vars.snapshot.checkpoint = params.snapshotCheckpoint; - - vm.mockCall( - params.checkpointer, abi.encodeWithSelector(ICheckpointer.snapshotFor.selector), abi.encode(vars.snapshot) - ); - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, vars.signature, false, address(0)); - assertEq(threshold, params.threshold); - assertEq(weight, params.weight); - assertEq(imageHash, vars.expectedImageHash); - assertEq(checkpoint, params.checkpoint); // Should use checkpoint from config, not snapshot - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_checkpointer_disabled_old_checkpoint_params { - Payload.Decoded payload; - address checkpointer; - uint56 checkpoint; - uint56 snapshotCheckpoint; - uint256 signer1pk; - uint8 threshold; - uint8 weight; - bytes checkpointerData; - bytes32 ignoredImageHash; - uint56 oldCheckpoint; - } - - struct test_checkpointer_disabled_old_checkpoint_vars { - address signer1addr; - string configJson; - bytes32 expectedImageHash; - bytes signature; - Snapshot snapshot; - } - - function test_checkpointer_disabled_old_checkpoint( - test_checkpointer_disabled_old_checkpoint_params memory params - ) external { - vm.assume(params.payload.calls.length < 3); - test_checkpointer_disabled_old_checkpoint_vars memory vars; - boundToLegalPayload(params.payload); - - params.checkpoint = uint56(bound(params.checkpoint, 1, type(uint56).max)); - params.oldCheckpoint = uint56(bound(params.oldCheckpoint, 0, params.checkpoint - 1)); - - params.checkpointer = boundNoPrecompile(params.checkpointer); - params.signer1pk = boundPk(params.signer1pk); - vars.signer1addr = vm.addr(params.signer1pk); - - params.weight = uint8(bound(params.weight, params.threshold, type(uint8).max)); - - vars.configJson = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - params.threshold, - params.checkpoint, - string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":", vm.toString(params.weight))) - ); - vars.expectedImageHash = PrimitivesRPC.getImageHash(vm, vars.configJson); - - (uint8 v, bytes32 r, bytes32 s) = vm.sign(params.signer1pk, Payload.hashFor(params.payload, address(baseSigImp))); - - vars.signature = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.configJson, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v) - ) - ), - !params.payload.noChainId, - params.checkpointerData - ); - - // Set imageHash to 0 to indicate checkpointer is disabled - vars.snapshot.imageHash = params.ignoredImageHash; - vars.snapshot.checkpoint = params.oldCheckpoint; - - vm.mockCall( - params.checkpointer, abi.encodeWithSelector(ICheckpointer.snapshotFor.selector), abi.encode(vars.snapshot) - ); - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, vars.signature, false, address(0)); - assertEq(threshold, params.threshold); - assertEq(weight, params.weight); - assertEq(imageHash, vars.expectedImageHash); - assertEq(checkpoint, params.checkpoint); // Should use checkpoint from config, not snapshot - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_checkpointer_past_with_chain_params { - Payload.Decoded payload; - address checkpointer; - bytes checkpointerData; - uint256 signerPk1; - uint256 signerPk2; - uint56 checkpoint1; - uint56 checkpoint2; - } - - struct test_checkpointer_past_with_chain_vars { - address signer1addr; - address signer2addr; - string config1Json; - string config2Json; - bytes32 config1ImageHash; - bytes32 config2ImageHash; - bytes signature1to2; - bytes signature2toPayload; - Snapshot snapshot; - bytes32 r1; - bytes32 r2; - bytes32 s1; - bytes32 s2; - uint8 v1; - uint8 v2; - Payload.Decoded payloadApprove2; - bytes chainedSignature; - } - - function test_checkpointer_past_with_chain( - test_checkpointer_past_with_chain_params memory params - ) external { - vm.assume(params.payload.calls.length < 3); - boundToLegalPayload(params.payload); - - params.checkpointer = boundNoPrecompile(params.checkpointer); - params.signerPk1 = boundPk(params.signerPk1); - params.signerPk2 = boundPk(params.signerPk2); - - params.checkpoint1 = uint56(bound(params.checkpoint1, 0, type(uint56).max - 1)); - params.checkpoint2 = uint56(bound(params.checkpoint2, params.checkpoint1 + 1, type(uint56).max)); - - test_checkpointer_past_with_chain_vars memory vars; - - vars.signer1addr = vm.addr(params.signerPk1); - vars.signer2addr = vm.addr(params.signerPk2); - - vars.config1Json = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - 1, - params.checkpoint1, - string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":1")) - ); - vars.config1ImageHash = PrimitivesRPC.getImageHash(vm, vars.config1Json); - - vars.config2Json = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - 2, - params.checkpoint2, - string(abi.encodePacked("signer:", vm.toString(vars.signer2addr), ":2")) - ); - vars.config2ImageHash = PrimitivesRPC.getImageHash(vm, vars.config2Json); - - vars.payloadApprove2.kind = Payload.KIND_CONFIG_UPDATE; - vars.payloadApprove2.imageHash = vars.config2ImageHash; - vars.payloadApprove2.noChainId = true; - - (vars.v1, vars.r1, vars.s1) = vm.sign(params.signerPk1, Payload.hashFor(vars.payloadApprove2, address(baseSigImp))); - vars.signature1to2 = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.config1Json, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), - ":hash:", - vm.toString(vars.r1), - ":", - vm.toString(vars.s1), - ":", - vm.toString(vars.v1) - ) - ), - false, - params.checkpointerData - ); - - (vars.v2, vars.r2, vars.s2) = vm.sign(params.signerPk2, Payload.hashFor(params.payload, address(baseSigImp))); - vars.signature2toPayload = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.config2Json, - string( - abi.encodePacked( - vm.toString(vars.signer2addr), - ":hash:", - vm.toString(vars.r2), - ":", - vm.toString(vars.s2), - ":", - vm.toString(vars.v2) - ) - ), - !params.payload.noChainId, - params.checkpointerData - ); - - vars.snapshot.imageHash = vars.config2ImageHash; - vars.snapshot.checkpoint = params.checkpoint2; - - vm.mockCall( - params.checkpointer, abi.encodeWithSelector(ICheckpointer.snapshotFor.selector), abi.encode(vars.snapshot) - ); - - bytes[] memory signatures = new bytes[](2); - signatures[0] = vars.signature2toPayload; - signatures[1] = vars.signature1to2; - vars.chainedSignature = PrimitivesRPC.concatSignatures(vm, signatures); - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, vars.chainedSignature, false, address(0)); - assertEq(threshold, 1); - assertEq(weight, 1); - assertEq(imageHash, vars.config1ImageHash); - assertEq(checkpoint, params.checkpoint1); - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_checkpointer_disabled_with_chain_params { - Payload.Decoded payload; - address checkpointer; - bytes checkpointerData; - uint256 signerPk1; - uint256 signerPk2; - uint56 checkpoint1; - uint56 checkpoint2; - uint56 ignoredSnapshotCheckpoint; - } - - struct test_checkpointer_disabled_with_chain_vars { - address signer1addr; - address signer2addr; - string config1Json; - string config2Json; - bytes32 config1ImageHash; - bytes32 config2ImageHash; - bytes signature1to2; - bytes signature2toPayload; - bytes32 r1; - bytes32 r2; - bytes32 s1; - bytes32 s2; - uint8 v1; - uint8 v2; - Payload.Decoded payloadApprove2; - bytes chainedSignature; - Snapshot snapshot; - } - - function test_checkpointer_disabled_with_chain( - test_checkpointer_disabled_with_chain_params memory params - ) external { - vm.assume(params.payload.calls.length < 3); - boundToLegalPayload(params.payload); - - params.checkpointer = boundNoPrecompile(params.checkpointer); - params.signerPk1 = boundPk(params.signerPk1); - params.signerPk2 = boundPk(params.signerPk2); - - params.checkpoint1 = uint56(bound(params.checkpoint1, 0, type(uint56).max - 1)); - params.checkpoint2 = uint56(bound(params.checkpoint2, params.checkpoint1 + 1, type(uint56).max)); - - test_checkpointer_disabled_with_chain_vars memory vars; - - vars.signer1addr = vm.addr(params.signerPk1); - vars.signer2addr = vm.addr(params.signerPk2); - - vars.config1Json = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - 1, - params.checkpoint1, - string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":1")) - ); - vars.config1ImageHash = PrimitivesRPC.getImageHash(vm, vars.config1Json); - - vars.config2Json = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - 2, - params.checkpoint2, - string(abi.encodePacked("signer:", vm.toString(vars.signer2addr), ":2")) - ); - vars.config2ImageHash = PrimitivesRPC.getImageHash(vm, vars.config2Json); - - vars.payloadApprove2.kind = Payload.KIND_CONFIG_UPDATE; - vars.payloadApprove2.imageHash = vars.config2ImageHash; - vars.payloadApprove2.noChainId = true; - - (vars.v1, vars.r1, vars.s1) = vm.sign(params.signerPk1, Payload.hashFor(vars.payloadApprove2, address(baseSigImp))); - vars.signature1to2 = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.config1Json, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), - ":hash:", - vm.toString(vars.r1), - ":", - vm.toString(vars.s1), - ":", - vm.toString(vars.v1) - ) - ), - false, - params.checkpointerData - ); - - (vars.v2, vars.r2, vars.s2) = vm.sign(params.signerPk2, Payload.hashFor(params.payload, address(baseSigImp))); - vars.signature2toPayload = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.config2Json, - string( - abi.encodePacked( - vm.toString(vars.signer2addr), - ":hash:", - vm.toString(vars.r2), - ":", - vm.toString(vars.s2), - ":", - vm.toString(vars.v2) - ) - ), - !params.payload.noChainId, - params.checkpointerData - ); - - vars.snapshot.imageHash = bytes32(0); - vars.snapshot.checkpoint = params.ignoredSnapshotCheckpoint; - - vm.mockCall( - params.checkpointer, abi.encodeWithSelector(ICheckpointer.snapshotFor.selector), abi.encode(vars.snapshot) - ); - - bytes[] memory signatures = new bytes[](2); - signatures[0] = vars.signature2toPayload; - signatures[1] = vars.signature1to2; - vars.chainedSignature = PrimitivesRPC.concatSignatures(vm, signatures); - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, vars.chainedSignature, false, address(0)); - assertEq(threshold, 1); - assertEq(weight, 1); - assertEq(imageHash, vars.config1ImageHash); - assertEq(checkpoint, params.checkpoint1); - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_checkpointer_old_checkpoint_with_chain_params { - Payload.Decoded payload; - address checkpointer; - bytes checkpointerData; - uint256 signerPk1; - uint256 signerPk2; - uint56 checkpoint1; - uint56 checkpoint2; - uint56 oldCheckpoint; - bytes32 ignoredImageHash; - } - - struct test_checkpointer_old_checkpoint_with_chain_vars { - address signer1addr; - address signer2addr; - string config1Json; - string config2Json; - bytes32 config1ImageHash; - bytes32 config2ImageHash; - bytes signature1to2; - bytes signature2toPayload; - bytes32 r1; - bytes32 r2; - bytes32 s1; - bytes32 s2; - uint8 v1; - uint8 v2; - Payload.Decoded payloadApprove2; - bytes chainedSignature; - Snapshot snapshot; - } - - function test_checkpointer_old_checkpoint_with_chain( - test_checkpointer_old_checkpoint_with_chain_params memory params - ) external { - vm.assume(params.payload.calls.length < 3); - boundToLegalPayload(params.payload); - - params.checkpointer = boundNoPrecompile(params.checkpointer); - params.signerPk1 = boundPk(params.signerPk1); - params.signerPk2 = boundPk(params.signerPk2); - - params.checkpoint1 = uint56(bound(params.checkpoint1, 1, type(uint56).max - 1)); - params.checkpoint2 = uint56(bound(params.checkpoint2, params.checkpoint1 + 1, type(uint56).max)); - params.oldCheckpoint = uint56(bound(params.oldCheckpoint, 0, params.checkpoint1 - 1)); - - test_checkpointer_old_checkpoint_with_chain_vars memory vars; - - vars.signer1addr = vm.addr(params.signerPk1); - vars.signer2addr = vm.addr(params.signerPk2); - - vars.config1Json = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - 1, - params.checkpoint1, - string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":1")) - ); - vars.config1ImageHash = PrimitivesRPC.getImageHash(vm, vars.config1Json); - - vars.config2Json = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - 2, - params.checkpoint2, - string(abi.encodePacked("signer:", vm.toString(vars.signer2addr), ":2")) - ); - vars.config2ImageHash = PrimitivesRPC.getImageHash(vm, vars.config2Json); - - vars.payloadApprove2.kind = Payload.KIND_CONFIG_UPDATE; - vars.payloadApprove2.imageHash = vars.config2ImageHash; - vars.payloadApprove2.noChainId = true; - - (vars.v1, vars.r1, vars.s1) = vm.sign(params.signerPk1, Payload.hashFor(vars.payloadApprove2, address(baseSigImp))); - vars.signature1to2 = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.config1Json, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), - ":hash:", - vm.toString(vars.r1), - ":", - vm.toString(vars.s1), - ":", - vm.toString(vars.v1) - ) - ), - false, - params.checkpointerData - ); - - (vars.v2, vars.r2, vars.s2) = vm.sign(params.signerPk2, Payload.hashFor(params.payload, address(baseSigImp))); - vars.signature2toPayload = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.config2Json, - string( - abi.encodePacked( - vm.toString(vars.signer2addr), - ":hash:", - vm.toString(vars.r2), - ":", - vm.toString(vars.s2), - ":", - vm.toString(vars.v2) - ) - ), - !params.payload.noChainId, - params.checkpointerData - ); - - vars.snapshot.imageHash = params.ignoredImageHash; - vars.snapshot.checkpoint = params.oldCheckpoint; - - vm.mockCall( - params.checkpointer, abi.encodeWithSelector(ICheckpointer.snapshotFor.selector), abi.encode(vars.snapshot) - ); - - bytes[] memory signatures = new bytes[](2); - signatures[0] = vars.signature2toPayload; - signatures[1] = vars.signature1to2; - vars.chainedSignature = PrimitivesRPC.concatSignatures(vm, signatures); - - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint, bytes32 opHash) = - baseSigImp.recoverPub(params.payload, vars.chainedSignature, false, address(0)); - assertEq(threshold, 1); - assertEq(weight, 1); - assertEq(imageHash, vars.config1ImageHash); - assertEq(checkpoint, params.checkpoint1); - assertEq(opHash, Payload.hashFor(params.payload, address(baseSigImp))); - } - - struct test_checkpointer_unused_snapshot_chain_params_fail { - Payload.Decoded payload; - address checkpointer; - bytes checkpointerData; - uint256 signerPk1; - uint256 signerPk2; - uint56 checkpoint1; - uint56 checkpoint2; - uint56 snapshotCheckpoint; - bytes32 snapshotImageHash; - } - - struct test_checkpointer_unused_snapshot_chain_vars_fail { - address signer1addr; - address signer2addr; - string config1Json; - string config2Json; - bytes32 config1ImageHash; - bytes32 config2ImageHash; - bytes signature1to2; - bytes signature2toPayload; - bytes32 r1; - bytes32 r2; - bytes32 s1; - bytes32 s2; - uint8 v1; - uint8 v2; - Payload.Decoded payloadApprove2; - bytes chainedSignature; - Snapshot snapshot; - } - - function test_checkpointer_unused_snapshot_chain_fail( - test_checkpointer_unused_snapshot_chain_params_fail memory params - ) external { - vm.assume(params.payload.calls.length < 3); - boundToLegalPayload(params.payload); - - params.checkpointer = boundNoPrecompile(params.checkpointer); - params.signerPk1 = boundPk(params.signerPk1); - params.signerPk2 = boundPk(params.signerPk2); - - params.checkpoint1 = uint56(bound(params.checkpoint1, 0, type(uint56).max - 1)); - params.checkpoint2 = uint56(bound(params.checkpoint2, params.checkpoint1 + 1, type(uint56).max)); - params.snapshotCheckpoint = uint56(bound(params.snapshotCheckpoint, params.checkpoint1, type(uint56).max)); - - test_checkpointer_unused_snapshot_chain_vars_fail memory vars; - - vars.signer1addr = vm.addr(params.signerPk1); - vars.signer2addr = vm.addr(params.signerPk2); - - vars.config1Json = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - 1, - params.checkpoint1, - string(abi.encodePacked("signer:", vm.toString(vars.signer1addr), ":1")) - ); - vars.config1ImageHash = PrimitivesRPC.getImageHash(vm, vars.config1Json); - - vars.config2Json = PrimitivesRPC.newConfigWithCheckpointer( - vm, - params.checkpointer, - 2, - params.checkpoint2, - string(abi.encodePacked("signer:", vm.toString(vars.signer2addr), ":2")) - ); - vars.config2ImageHash = PrimitivesRPC.getImageHash(vm, vars.config2Json); - - vm.assume(params.snapshotImageHash != bytes32(0)); - vm.assume(params.snapshotImageHash != vars.config1ImageHash); - vm.assume(params.snapshotImageHash != vars.config2ImageHash); - - vars.payloadApprove2.kind = Payload.KIND_CONFIG_UPDATE; - vars.payloadApprove2.imageHash = vars.config2ImageHash; - vars.payloadApprove2.noChainId = true; - - (vars.v1, vars.r1, vars.s1) = vm.sign(params.signerPk1, Payload.hashFor(vars.payloadApprove2, address(baseSigImp))); - vars.signature1to2 = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.config1Json, - string( - abi.encodePacked( - vm.toString(vars.signer1addr), - ":hash:", - vm.toString(vars.r1), - ":", - vm.toString(vars.s1), - ":", - vm.toString(vars.v1) - ) - ), - false, - params.checkpointerData - ); - - (vars.v2, vars.r2, vars.s2) = vm.sign(params.signerPk2, Payload.hashFor(params.payload, address(baseSigImp))); - vars.signature2toPayload = PrimitivesRPC.toEncodedSignatureWithCheckpointerData( - vm, - vars.config2Json, - string( - abi.encodePacked( - vm.toString(vars.signer2addr), - ":hash:", - vm.toString(vars.r2), - ":", - vm.toString(vars.s2), - ":", - vm.toString(vars.v2) - ) - ), - !params.payload.noChainId, - params.checkpointerData - ); - - vars.snapshot.imageHash = params.snapshotImageHash; - vars.snapshot.checkpoint = params.snapshotCheckpoint; - - vm.mockCall( - params.checkpointer, abi.encodeWithSelector(ICheckpointer.snapshotFor.selector), abi.encode(vars.snapshot) - ); - - bytes[] memory signatures = new bytes[](2); - signatures[0] = vars.signature2toPayload; - signatures[1] = vars.signature1to2; - vars.chainedSignature = PrimitivesRPC.concatSignatures(vm, signatures); - - if (params.snapshotImageHash == bytes32(0)) { - // Snapshot imageHash is 0, checkpointer is considered disabled - (uint256 threshold, uint256 weight, bytes32 imageHash, uint256 checkpoint,) = - baseSigImp.recoverPub(params.payload, vars.chainedSignature, false, address(0)); - assertEq(threshold, 1); - assertEq(weight, 1); - assertEq(imageHash, vars.config1ImageHash); - assertEq(checkpoint, params.checkpoint1); - } else { - vm.expectRevert(abi.encodeWithSelector(BaseSig.UnusedSnapshot.selector, vars.snapshot)); - baseSigImp.recoverPub(params.payload, vars.chainedSignature, false, address(0)); - } - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Calls.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Calls.t.sol deleted file mode 100644 index b4f57987ec..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Calls.t.sol +++ /dev/null @@ -1,457 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Calls } from "../../src/modules/Calls.sol"; - -import { Payload } from "../../src/modules/Payload.sol"; -import { AdvTest } from "../utils/TestUtils.sol"; - -import { Payload } from "../../src/modules/Payload.sol"; - -import { PrimitivesRPC } from "../utils/PrimitivesRPC.sol"; - -contract CallsImp is Calls { - - bytes public expectedSignature; - bytes32 public expectedOpHash; - - function setExpectedSignature( - bytes calldata _signature - ) external { - expectedSignature = _signature; - } - - function setExpectedOpHash( - bytes32 _opHash - ) external { - expectedOpHash = _opHash; - } - - function writeNonce(uint256 _space, uint256 _nonce) external { - _writeNonce(_space, _nonce); - } - - function signatureValidation( - Payload.Decoded memory, - bytes calldata _signature - ) internal view override returns (bool isValid, bytes32 opHash) { - return (keccak256(_signature) == keccak256(expectedSignature), expectedOpHash); - } - - function _isValidImage( - bytes32 - ) internal pure override returns (bool) { - revert("Not used"); - } - - function _updateImageHash( - bytes32 - ) internal pure override { - revert("Not used"); - } - -} - -contract MockDelegatecall { // extends IDelegatedExtension (but we make it payable for the test) - - event OpHash(bytes32 _opHash); - event StartingGas(uint256 _startingGas); - event Index(uint256 _index); - event NumCalls(uint256 _numCalls); - event Space(uint256 _space); - event Data(bytes _data); - - function handleSequenceDelegateCall( - bytes32 _opHash, - uint256 _startingGas, - uint256 _index, - uint256 _numCalls, - uint256 _space, - bytes calldata _data - ) external payable { - emit OpHash(_opHash); - emit StartingGas(_startingGas); - emit Index(_index); - emit NumCalls(_numCalls); - emit Space(_space); - emit Data(_data); - } - - receive() external payable { } - fallback() external payable { } - -} - -struct CallsPayload { - bool noChainId; - Payload.Call[] calls; - uint160 space; - uint56 nonce; -} - -function toDecodedPayload( - CallsPayload memory _payload -) pure returns (Payload.Decoded memory _decoded) { - _decoded.kind = Payload.KIND_TRANSACTIONS; - _decoded.calls = _payload.calls; - _decoded.space = _payload.space; - _decoded.nonce = _payload.nonce; -} - -contract CallsTest is AdvTest { - - CallsImp public calls = new CallsImp(); - - event CallSucceeded(bytes32 _opHash, uint256 _index); - event CallSkipped(bytes32 _opHash, uint256 _index); - event CallFailed(bytes32 _opHash, uint256 _index, bytes _returnData); - event CallAborted(bytes32 _opHash, uint256 _index, bytes _returnData); - - function preparePayload( - Payload.Decoded memory decoded - ) internal { - uint256 totalEther; - - for (uint256 i = 0; i < decoded.calls.length; i++) { - decoded.calls[i].to = boundNoPrecompile(decoded.calls[i].to); - decoded.calls[i].value = bound(decoded.calls[i].value, 0, 100_000_000_000_000 ether); - decoded.calls[i].gasLimit = bound(decoded.calls[i].gasLimit, 0, 1_000_000_000); - - if (!decoded.calls[i].delegateCall && !decoded.calls[i].onlyFallback) { - totalEther += decoded.calls[i].value; - } - - if (decoded.calls[i].delegateCall && decoded.calls[i].gasLimit != 0) { - decoded.calls[i].gasLimit = bound(decoded.calls[i].gasLimit, 100_000, 1_000_000_000); - } - - vm.assume(decoded.calls[i].to != address(calls)); - } - - vm.deal(address(calls), totalEther); - } - - function test_execute(bytes32 _opHash, CallsPayload memory _payload, bytes calldata _signature) external { - vm.assume(_payload.calls.length < 3); - address mockDelegatecall = address(new MockDelegatecall()); - Payload.Decoded memory decoded = toDecodedPayload(_payload); - - preparePayload(decoded); - boundToLegalPayload(decoded); - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - calls.setExpectedSignature(_signature); - calls.setExpectedOpHash(_opHash); - calls.writeNonce(decoded.space, decoded.nonce); - - for (uint256 i = 0; i < decoded.calls.length; i++) { - if (decoded.calls[i].onlyFallback) { - vm.expectEmit(true, true, true, true, address(calls)); - emit CallSkipped(_opHash, i); - } else { - vm.deal(decoded.calls[i].to, 0); - - if (decoded.calls[i].delegateCall) { - vm.etch(decoded.calls[i].to, mockDelegatecall.code); - vm.expectEmit(true, true, true, true, address(calls)); - emit MockDelegatecall.OpHash(_opHash); - // Can't test gasleft() because memory expansion makes it not so reliable - // emit MockDelegatecall.StartingGas(gasleft()); - vm.expectEmit(true, true, true, true, address(calls)); - emit MockDelegatecall.Index(i); - vm.expectEmit(true, true, true, true, address(calls)); - emit MockDelegatecall.NumCalls(decoded.calls.length); - vm.expectEmit(true, true, true, true, address(calls)); - emit MockDelegatecall.Space(decoded.space); - vm.expectEmit(true, true, true, true, address(calls)); - emit MockDelegatecall.Data(decoded.calls[i].data); - } else { - vm.expectCall(decoded.calls[i].to, decoded.calls[i].data); - } - - emit CallSucceeded(_opHash, i); - } - } - - calls.execute(packed, _signature); - - assertEq(address(calls).balance, 0); - - // Assert balance of each destination contract - for (uint256 i = 0; i < decoded.calls.length; i++) { - if ( - !decoded.calls[i].delegateCall && decoded.calls[i].to.balance != decoded.calls[i].value - && !decoded.calls[i].onlyFallback - ) { - // We need to do a full recount because maybe the contract is duplicated so multiple transfers are done - uint256 totalTransferred = 0; - for (uint256 j = 0; j < decoded.calls.length; j++) { - if ( - !decoded.calls[j].delegateCall && decoded.calls[j].to == decoded.calls[i].to - && !decoded.calls[j].onlyFallback - ) { - totalTransferred += decoded.calls[j].value; - } - } - assertEq(totalTransferred, decoded.calls[i].to.balance); - } - } - } - - function test_self_execute( - CallsPayload memory _payload - ) external { - vm.assume(_payload.calls.length < 3); - address mockDelegatecall = address(new MockDelegatecall()); - - Payload.Decoded memory decoded = toDecodedPayload(_payload); - - preparePayload(decoded); - boundToLegalPayload(decoded); - - bytes32 opHash = Payload.hashFor(decoded, address(calls)); - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - - for (uint256 i = 0; i < decoded.calls.length; i++) { - if (decoded.calls[i].onlyFallback) { - vm.expectEmit(true, true, true, true, address(calls)); - emit CallSkipped(opHash, i); - } else { - vm.deal(decoded.calls[i].to, 0); - if (decoded.calls[i].delegateCall) { - vm.etch(decoded.calls[i].to, mockDelegatecall.code); - vm.expectEmit(true, true, true, true, address(calls)); - emit MockDelegatecall.OpHash(opHash); - // Can't reliably test gasleft() due to memory expansion changes - vm.expectEmit(true, true, true, true, address(calls)); - emit MockDelegatecall.Index(i); - vm.expectEmit(true, true, true, true, address(calls)); - emit MockDelegatecall.NumCalls(decoded.calls.length); - vm.expectEmit(true, true, true, true, address(calls)); - emit MockDelegatecall.Space(decoded.space); - vm.expectEmit(true, true, true, true, address(calls)); - emit MockDelegatecall.Data(decoded.calls[i].data); - } else { - vm.expectCall(decoded.calls[i].to, decoded.calls[i].data); - } - vm.expectEmit(true, true, true, true, address(calls)); - emit CallSucceeded(opHash, i); - } - } - - vm.prank(address(calls)); - calls.selfExecute(packed); - - assertEq(address(calls).balance, 0); - - for (uint256 i = 0; i < decoded.calls.length; i++) { - if ( - !decoded.calls[i].delegateCall && decoded.calls[i].to.balance != decoded.calls[i].value - && !decoded.calls[i].onlyFallback - ) { - uint256 totalTransferred = 0; - for (uint256 j = 0; j < decoded.calls.length; j++) { - if ( - !decoded.calls[j].delegateCall && decoded.calls[j].to == decoded.calls[i].to - && !decoded.calls[j].onlyFallback - ) { - totalTransferred += decoded.calls[j].value; - } - } - assertEq(totalTransferred, decoded.calls[i].to.balance); - } - } - } - - function test_invalid_signature( - CallsPayload memory _payload, - bytes calldata _signature, - bytes calldata _wrongSignature - ) external { - vm.assume(_signature.length > 0 && _wrongSignature.length > 0); - vm.assume(keccak256(_signature) != keccak256(_wrongSignature)); - - Payload.Decoded memory decoded = toDecodedPayload(_payload); - boundToLegalPayload(decoded); - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - bytes32 opHash = Payload.hashFor(decoded, address(calls)); - - calls.setExpectedSignature(_signature); - calls.setExpectedOpHash(opHash); - calls.writeNonce(decoded.space, decoded.nonce); - - vm.expectRevert(abi.encodeWithSelector(Calls.InvalidSignature.selector, decoded, _wrongSignature)); - calls.execute(packed, _wrongSignature); - } - - function test_error_flag_behavior( - Payload.Call calldata call1, - Payload.Call calldata call2, - bytes calldata _signature - ) external { - CallsPayload memory _payload; - _payload.calls = new Payload.Call[](2); - - // Set up the first call to fail - _payload.calls[0] = call1; - _payload.calls[0].onlyFallback = false; - _payload.calls[0].delegateCall = false; - _payload.calls[0].behaviorOnError = Payload.BEHAVIOR_IGNORE_ERROR; - - // Set up the second call to be a fallback call - _payload.calls[1] = call2; - _payload.calls[1].onlyFallback = true; - - Payload.Decoded memory decoded = toDecodedPayload(_payload); - preparePayload(decoded); - boundToLegalPayload(decoded); - - // Ensure we have enough ether for both calls, even though the second one will be skipped - uint256 totalEther = decoded.calls[0].value + decoded.calls[1].value; - vm.deal(address(calls), totalEther); - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - bytes32 opHash = Payload.hashFor(decoded, address(calls)); - - calls.setExpectedSignature(_signature); - calls.setExpectedOpHash(opHash); - calls.writeNonce(decoded.space, decoded.nonce); - - bytes memory revertData = abi.encodeWithSelector(bytes4(keccak256("revert()"))); - - // Force the first call to fail by making it revert - vm.mockCallRevert(_payload.calls[0].to, _payload.calls[0].value, _payload.calls[0].data, revertData); - - // First call should fail and emit CallFailed - vm.expectEmit(true, true, true, true, address(calls)); - emit CallFailed(opHash, 0, revertData); - - // Second call should succeed as the previous error makes the fallback execute - vm.expectEmit(true, true, true, true, address(calls)); - emit CallSucceeded(opHash, 1); - - calls.execute(packed, _signature); - } - - function test_revert_on_error(Payload.Call calldata call, bytes calldata _signature) external { - CallsPayload memory _payload; - _payload.calls = new Payload.Call[](1); - - // Set up the call to fail - _payload.calls[0] = call; - _payload.calls[0].onlyFallback = false; - _payload.calls[0].delegateCall = false; - _payload.calls[0].behaviorOnError = Payload.BEHAVIOR_REVERT_ON_ERROR; - - Payload.Decoded memory decoded = toDecodedPayload(_payload); - preparePayload(decoded); - boundToLegalPayload(decoded); - - // Ensure we have enough ether - vm.deal(address(calls), decoded.calls[0].value); - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - bytes32 opHash = Payload.hashFor(decoded, address(calls)); - - calls.setExpectedSignature(_signature); - calls.setExpectedOpHash(opHash); - calls.writeNonce(decoded.space, decoded.nonce); - - bytes memory revertData = abi.encodeWithSelector(bytes4(keccak256("revert()"))); - - // Force the call to fail by making it revert - vm.mockCallRevert(_payload.calls[0].to, _payload.calls[0].value, _payload.calls[0].data, revertData); - - // Expect the call to revert with Reverted error - vm.expectRevert(abi.encodeWithSelector(Calls.Reverted.selector, decoded, 0, revertData)); - - calls.execute(packed, _signature); - } - - function test_abort_on_error(Payload.Call calldata call, bytes calldata _signature) external { - CallsPayload memory _payload; - _payload.calls = new Payload.Call[](1); - - // Set up the call to fail - _payload.calls[0] = call; - _payload.calls[0].onlyFallback = false; - _payload.calls[0].delegateCall = false; - _payload.calls[0].behaviorOnError = Payload.BEHAVIOR_ABORT_ON_ERROR; - - Payload.Decoded memory decoded = toDecodedPayload(_payload); - preparePayload(decoded); - boundToLegalPayload(decoded); - - // Ensure we have enough ether - vm.deal(address(calls), decoded.calls[0].value); - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - bytes32 opHash = Payload.hashFor(decoded, address(calls)); - - calls.setExpectedSignature(_signature); - calls.setExpectedOpHash(opHash); - calls.writeNonce(decoded.space, decoded.nonce); - - bytes memory revertData = abi.encodeWithSelector(bytes4(keccak256("revert()"))); - - // Force the call to fail by making it revert - vm.mockCallRevert(_payload.calls[0].to, _payload.calls[0].value, _payload.calls[0].data, revertData); - - // Call should fail and emit CallAborted - vm.expectEmit(true, true, true, true, address(calls)); - emit CallAborted(opHash, 0, revertData); - - calls.execute(packed, _signature); - } - - function test_not_enough_gas(Payload.Call calldata call, uint256 txGasLimit, bytes calldata _signature) external { - CallsPayload memory _payload; - _payload.calls = new Payload.Call[](1); - - txGasLimit = bound(txGasLimit, 1_000_000, 999_999_999); - - // Set up the call with a high gas limit - _payload.calls[0] = call; - _payload.calls[0].onlyFallback = false; - _payload.calls[0].delegateCall = false; - _payload.calls[0].gasLimit = bound(call.gasLimit, txGasLimit, 1_000_000_000); - - Payload.Decoded memory decoded = toDecodedPayload(_payload); - preparePayload(decoded); - boundToLegalPayload(decoded); - - // Ensure we have enough ether - vm.deal(address(calls), decoded.calls[0].value); - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - bytes32 opHash = Payload.hashFor(decoded, address(calls)); - - calls.setExpectedSignature(_signature); - calls.setExpectedOpHash(opHash); - calls.writeNonce(decoded.space, decoded.nonce); - - // Expect the call to revert with NotEnoughGas error. We do not expect the exact gas left - vm.expectPartialRevert(Calls.NotEnoughGas.selector); - - calls.execute{ gas: txGasLimit }(packed, _signature); - } - - function test_empty_payload_consumes_nonce(uint256 space, uint256 nonce, bytes calldata signature) external { - Payload.Decoded memory decoded; - decoded.kind = Payload.KIND_TRANSACTIONS; - decoded.space = space; - decoded.nonce = nonce; - boundToLegalPayload(decoded); - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, decoded); - calls.writeNonce(decoded.space, decoded.nonce); - - calls.setExpectedSignature(signature); - calls.setExpectedOpHash(keccak256(packed)); - - calls.execute(packed, signature); - assertEq(calls.readNonce(decoded.space), decoded.nonce + 1); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/ERC4337v07.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/modules/ERC4337v07.t.sol deleted file mode 100644 index c011187cd5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/ERC4337v07.t.sol +++ /dev/null @@ -1,246 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Factory } from "../../src/Factory.sol"; -import { Stage1Module } from "../../src/Stage1Module.sol"; -import { Calls } from "../../src/modules/Calls.sol"; - -import { ERC4337v07 } from "../../src/modules/ERC4337v07.sol"; -import { Payload } from "../../src/modules/Payload.sol"; -import { PackedUserOperation } from "../../src/modules/interfaces/IAccount.sol"; - -import { CanReenter } from "../mocks/CanReenter.sol"; -import { Emitter } from "../mocks/Emitter.sol"; -import { PrimitivesRPC } from "../utils/PrimitivesRPC.sol"; -import { AdvTest } from "../utils/TestUtils.sol"; -import { EntryPoint, IStakeManager } from "account-abstraction/core/EntryPoint.sol"; - -contract ERC4337v07Test is AdvTest { - - Factory public factory; - EntryPoint public entryPoint; - Stage1Module public stage1Module; - address payable public wallet; - string public walletConfig; - bytes32 public walletImageHash; - uint256 public signerPk; - address public signer; - - function setUp() public { - factory = new Factory(); - entryPoint = new EntryPoint(); - stage1Module = new Stage1Module(address(factory), address(entryPoint)); - - // Basic wallet setup for most tests. - signerPk = boundPk(123); - signer = vm.addr(signerPk); - walletConfig = PrimitivesRPC.newConfig(vm, 1, 0, string(abi.encodePacked("signer:", vm.toString(signer), ":1"))); - walletImageHash = PrimitivesRPC.getImageHash(vm, walletConfig); - wallet = payable(factory.deploy(address(stage1Module), walletImageHash)); - } - - // --- Helper Functions --- - - function _createUserOp( - bytes memory _callData, - bytes memory _signature - ) internal view returns (PackedUserOperation memory) { - return PackedUserOperation({ - sender: wallet, - nonce: 0, // Nonce is validated by the real entrypoint, not the account. - initCode: "", - callData: _callData, - accountGasLimits: bytes32(0), - preVerificationGas: 21000, - gasFees: bytes32(0), - paymasterAndData: "", - signature: _signature - }); - } - - // --- validateUserOp Tests --- - - function test_validateUserOp_reverts_if_disabled( - PackedUserOperation calldata userOp, - bytes32 userOpHash, - uint256 missingFunds - ) public { - // Deploy a new wallet with 4337 disabled (entrypoint is address(0)). - Stage1Module moduleDisabled = new Stage1Module(address(factory), address(0)); - address payable walletDisabled = payable(factory.deploy(address(moduleDisabled), walletImageHash)); - - vm.prank(address(entryPoint)); - vm.expectRevert(ERC4337v07.ERC4337Disabled.selector); - Stage1Module(walletDisabled).validateUserOp(userOp, userOpHash, missingFunds); - } - - function test_validateUserOp_reverts_invalidEntryPoint( - PackedUserOperation calldata userOp, - bytes32 userOpHash, - uint256 missingFunds, - address randomCaller - ) public { - vm.assume(randomCaller != address(entryPoint)); - - vm.prank(randomCaller); - vm.expectRevert(abi.encodeWithSelector(ERC4337v07.InvalidEntryPoint.selector, randomCaller)); - Stage1Module(wallet).validateUserOp(userOp, userOpHash, missingFunds); - } - - function test_validateUserOp_depositsMissingFunds(bytes32 userOpHash, uint256 missingFunds) public { - vm.assume(missingFunds > 0); - // Signature doesn't need to be valid for this test. - PackedUserOperation memory userOp = _createUserOp(bytes(""), hex"000010000000000000000000000000000000000000000000"); - - // The wallet needs the funds *before* the call to be able to deposit them, - // as validateUserOp is not payable. - vm.deal(wallet, missingFunds); - - vm.prank(address(entryPoint)); - - vm.expectEmit(true, true, false, true, address(entryPoint)); - emit IStakeManager.Deposited(wallet, missingFunds); - - // Call validateUserOp without sending value. The wallet will use its own balance to deposit. - uint256 validationData = Stage1Module(wallet).validateUserOp(userOp, userOpHash, missingFunds); - - assertEq(validationData, 1, "Should return 1 for signature failure"); - assertEq(entryPoint.balanceOf(wallet), missingFunds, "Missing funds were not deposited correctly"); - assertEq(address(wallet).balance, 0, "Wallet should have used its balance for the deposit"); - } - - function test_validateUserOp_returns_zero_on_validSignature( - bytes32 userOpHash - ) public { - // Create a signature for the userOpHash using the wallet's signer config. - Payload.Decoded memory payload; - payload.kind = Payload.KIND_DIGEST; - payload.digest = userOpHash; - - (uint8 v, bytes32 r, bytes32 s) = vm.sign(signerPk, Payload.hashFor(payload, wallet)); - string memory signatures = - string(abi.encodePacked(vm.toString(signer), ":hash:", vm.toString(r), ":", vm.toString(s), ":", vm.toString(v))); - bytes memory encodedSignature = PrimitivesRPC.toEncodedSignature(vm, walletConfig, signatures, true); - - PackedUserOperation memory userOp = _createUserOp(bytes(""), encodedSignature); - - vm.prank(address(entryPoint)); - uint256 validationData = Stage1Module(wallet).validateUserOp(userOp, userOpHash, 0); - - assertEq(validationData, 0, "Should return 0 for a valid signature"); - } - - function test_validateUserOp_returns_one_on_invalidSignature( - bytes32 userOpHash - ) public { - // Use a random, invalid signature provided by the fuzzer. - PackedUserOperation memory userOp = _createUserOp(bytes(""), hex"000010000000000000000000000000000000000000000000"); - - vm.prank(address(entryPoint)); - uint256 validationData = Stage1Module(wallet).validateUserOp(userOp, userOpHash, 0); - - assertEq(validationData, 1, "Should return 1 (SIG_VALIDATION_FAILED) for an invalid signature"); - } - - // --- executeUserOp Tests --- - - function test_executeUserOp_reverts_if_disabled( - bytes calldata payload - ) public { - // Deploy a new wallet with 4337 disabled. - Stage1Module moduleDisabled = new Stage1Module(address(factory), address(0)); - address payable walletDisabled = payable(factory.deploy(address(moduleDisabled), walletImageHash)); - - vm.prank(address(entryPoint)); - vm.expectRevert(ERC4337v07.ERC4337Disabled.selector); - Stage1Module(walletDisabled).executeUserOp(payload); - } - - function test_executeUserOp_reverts_invalidEntryPoint(bytes calldata payload, address randomCaller) public { - vm.assume(randomCaller != address(entryPoint)); - - vm.prank(randomCaller); - vm.expectRevert(abi.encodeWithSelector(ERC4337v07.InvalidEntryPoint.selector, randomCaller)); - Stage1Module(wallet).executeUserOp(payload); - } - - function test_executeUserOp_executes_payload() external { - // Setup a mock contract to call. - Emitter emitter = new Emitter(); - - // Create a payload to call the emitter contract. - Payload.Decoded memory decodedPayload; - decodedPayload.kind = Payload.KIND_TRANSACTIONS; - decodedPayload.calls = new Payload.Call[](1); - decodedPayload.calls[0] = Payload.Call({ - to: address(emitter), - value: 0, - data: abi.encodeWithSelector(Emitter.explicitEmit.selector), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_REVERT_ON_ERROR - }); - - bytes memory packedPayload = PrimitivesRPC.toPackedPayload(vm, decodedPayload); - - // Expect the call to succeed and the event to be emitted from the Emitter contract. - vm.expectEmit(true, false, false, true, address(emitter)); - emit Emitter.Explicit(wallet); - - // Execute the userOp via the entrypoint. - vm.prank(address(entryPoint)); - Stage1Module(wallet).executeUserOp(packedPayload); - } - - function test_executeUserOp_protected_from_reentry() external { - // Setup a mock contract that can attempt reentry - CanReenter canReenter = new CanReenter(); - - // Create an inner payload that will be called during reentry - Payload.Decoded memory innerPayload; - innerPayload.kind = Payload.KIND_TRANSACTIONS; - innerPayload.calls = new Payload.Call[](1); - innerPayload.calls[0] = Payload.Call({ - to: address(0x123), // Some target - value: 0, - data: bytes(""), - gasLimit: 0, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_IGNORE_ERROR - }); - - // Pack the inner payload - bytes memory innerPackedPayload = PrimitivesRPC.toPackedPayload(vm, innerPayload); - - // Create an outer payload that calls the canReenter contract - Payload.Decoded memory outerPayload; - outerPayload.kind = Payload.KIND_TRANSACTIONS; - outerPayload.calls = new Payload.Call[](1); - outerPayload.calls[0] = Payload.Call({ - to: address(canReenter), - value: 0, - data: abi.encodeWithSelector( - CanReenter.doAnotherCall.selector, - address(wallet), - abi.encodeWithSelector(Stage1Module(wallet).executeUserOp.selector, innerPackedPayload) - ), - gasLimit: 1000000, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_IGNORE_ERROR - }); - - // Pack the outer payload - bytes memory outerPackedPayload = PrimitivesRPC.toPackedPayload(vm, outerPayload); - - // Execute the outer payload - bytes32 outerHash = Payload.hashFor(outerPayload, wallet); - vm.expectEmit(true, true, true, true, address(wallet)); - emit Calls.CallFailed(outerHash, 0, abi.encodeWithSelector(bytes4(keccak256("Error(string)")), "Call failed")); - vm.prank(address(entryPoint)); - Stage1Module(wallet).executeUserOp(outerPackedPayload); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Hooks.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Hooks.t.sol deleted file mode 100644 index b4161a03f5..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Hooks.t.sol +++ /dev/null @@ -1,174 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Factory } from "../../src/Factory.sol"; -import { Hooks, IERC1155Receiver, IERC223Receiver, IERC721Receiver, IERC777Receiver } from "../../src/modules/Hooks.sol"; -import { SelfAuth } from "../../src/modules/auth/SelfAuth.sol"; - -import { AdvTest } from "../utils/TestUtils.sol"; - -contract HooksTest is AdvTest { - - Hooks public hooks; - address public constant TEST_IMPLEMENTATION = address(0x123); - Factory public factory; - - function setUp() public { - // Deploy via factory to test forwarding - Hooks impl = new Hooks(); - factory = new Factory(); - hooks = Hooks(payable(factory.deploy(address(impl), bytes32(0)))); - } - - // Hook Management Tests - function test_addHook() public { - bytes4 signature = bytes4(keccak256("testFunction()")); - vm.prank(address(hooks)); - hooks.addHook(signature, TEST_IMPLEMENTATION); - assertEq(hooks.readHook(signature), TEST_IMPLEMENTATION); - } - - function test_addHook_revertWhenHookExists() public { - bytes4 signature = bytes4(keccak256("testFunction()")); - vm.prank(address(hooks)); - hooks.addHook(signature, TEST_IMPLEMENTATION); - vm.expectRevert(abi.encodeWithSelector(Hooks.HookAlreadyExists.selector, signature)); - vm.prank(address(hooks)); - hooks.addHook(signature, TEST_IMPLEMENTATION); - } - - function test_addHook_revertWhenNotSelf() public { - bytes4 signature = bytes4(keccak256("testFunction()")); - vm.expectRevert(abi.encodeWithSelector(SelfAuth.OnlySelf.selector, address(this))); - hooks.addHook(signature, TEST_IMPLEMENTATION); - } - - function test_removeHook() public { - bytes4 signature = bytes4(keccak256("testFunction()")); - vm.prank(address(hooks)); - hooks.addHook(signature, TEST_IMPLEMENTATION); - vm.prank(address(hooks)); - hooks.removeHook(signature); - assertEq(hooks.readHook(signature), address(0)); - } - - function test_removeHook_revertWhenHookDoesNotExist() public { - bytes4 signature = bytes4(keccak256("testFunction()")); - vm.expectRevert(abi.encodeWithSelector(Hooks.HookDoesNotExist.selector, signature)); - vm.prank(address(hooks)); - hooks.removeHook(signature); - } - - // ERC1155 Receiver Tests - function test_onERC1155Received( - address _from, - address _to, - uint256 _id, - uint256 _value, - bytes calldata _data - ) external view { - bytes4 selector = IERC1155Receiver.onERC1155Received.selector; - assertEq(selector, bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))); - bytes4 returnValue = hooks.onERC1155Received(_from, _to, _id, _value, _data); - assertEq(returnValue, selector); - } - - function test_onERC1155BatchReceived( - address _from, - address _to, - uint256[] calldata _ids, - uint256[] calldata _values, - bytes calldata _data - ) external view { - bytes4 selector = IERC1155Receiver.onERC1155BatchReceived.selector; - assertEq(selector, bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))); - bytes4 returnValue = hooks.onERC1155BatchReceived(_from, _to, _ids, _values, _data); - assertEq(returnValue, selector); - } - - // ERC777 Receiver Tests - function test_tokensReceived( - address _operator, - address _from, - address _to, - uint256 _amount, - bytes calldata _data, - bytes calldata _operatorData - ) public { - bytes4 selector = IERC777Receiver.tokensReceived.selector; - assertEq(selector, bytes4(keccak256("tokensReceived(address,address,address,uint256,bytes,bytes)"))); - hooks.tokensReceived(_operator, _from, _to, _amount, _data, _operatorData); - } - - // ERC721 Receiver Tests - function test_onERC721Received(address _from, address _to, uint256 _tokenId, bytes calldata _data) external view { - bytes4 selector = IERC721Receiver.onERC721Received.selector; - assertEq(selector, bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))); - bytes4 returnValue = hooks.onERC721Received(_from, _to, _tokenId, _data); - assertEq(returnValue, selector); - } - - // ERC223 Receiver Tests - function test_tokenReceived(address _from, uint256 _value, bytes calldata _data) external view { - bytes4 selector = IERC223Receiver.tokenReceived.selector; - assertEq(selector, bytes4(keccak256("tokenReceived(address,uint256,bytes)"))); - bytes4 returnValue = hooks.tokenReceived(_from, _value, _data); - assertEq(returnValue, selector); - } - - // Fallback and Receive Tests - function test_fallback() public { - bytes4 signature = bytes4(keccak256("testFunction()")); - address mockImplementation = address(new MockImplementation()); - vm.prank(address(hooks)); - hooks.addHook(signature, mockImplementation); - - (bool success, bytes memory result) = address(hooks).call(abi.encodeWithSelector(signature)); - assertTrue(success); - assertEq(result, abi.encode(true)); - - success = MockImplementation(address(hooks)).testFunction(); - assertTrue(success); - } - - function test_fallbackRevertWhenHookNotPayable() public { - bytes4 signature = bytes4(keccak256("testFunction()")); - address mockImplementation = address(new MockImplementation()); - vm.prank(address(hooks)); - hooks.addHook(signature, mockImplementation); - - (bool success,) = address(hooks).call{ value: 1 ether }(abi.encodeWithSelector(signature)); - assertFalse(success); - } - - function test_payableFallback() public { - bytes4 signature = bytes4(keccak256("testPayableFunction()")); - address mockImplementation = address(new MockImplementation()); - vm.prank(address(hooks)); - hooks.addHook(signature, mockImplementation); - - (bool success, bytes memory result) = address(hooks).call{ value: 1 ether }(abi.encodeWithSelector(signature)); - assertTrue(success); - assertEq(result, abi.encode(true)); - assertEq(address(hooks).balance, 1 ether); - } - - function test_receive() public { - vm.deal(address(this), 1 ether); - (bool success,) = address(hooks).call{ value: 1 ether }(""); - assertTrue(success); - } - -} - -contract MockImplementation { - - function testFunction() external pure returns (bool) { - return true; - } - - function testPayableFunction() external payable returns (bool) { - return true; - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Implementation.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Implementation.t.sol deleted file mode 100644 index a3ecc0d2ab..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Implementation.t.sol +++ /dev/null @@ -1,31 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Implementation } from "../../src/modules/Implementation.sol"; -import { SelfAuth } from "../../src/modules/auth/SelfAuth.sol"; - -import { AdvTest } from "../utils/TestUtils.sol"; -import { Vm } from "forge-std/Test.sol"; - -contract ImplementationTest is AdvTest { - - Implementation public implementation; - - function setUp() public { - implementation = new Implementation(); - } - - function test_updateImplementation( - address _implementation - ) public { - vm.prank(address(implementation)); - implementation.updateImplementation(_implementation); - assertEq(implementation.getImplementation(), _implementation); - } - - function test_updateImplementation_revertWhenNotSelf() public { - vm.expectRevert(abi.encodeWithSelector(SelfAuth.OnlySelf.selector, address(this))); - implementation.updateImplementation(address(this)); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Nonce.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Nonce.t.sol deleted file mode 100644 index 878b2f6e13..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Nonce.t.sol +++ /dev/null @@ -1,50 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Nonce } from "../../src/modules/Nonce.sol"; -import { SelfAuth } from "../../src/modules/auth/SelfAuth.sol"; - -import { AdvTest } from "../utils/TestUtils.sol"; -import { Vm } from "forge-std/Test.sol"; - -contract NonceImp is Nonce { - - function writeNonce(uint256 _space, uint256 _nonce) public { - super._writeNonce(_space, _nonce); - } - - function consumeNonce(uint256 _space, uint256 _nonce) public { - super._consumeNonce(_space, _nonce); - } - -} - -contract NonceTest is AdvTest { - - NonceImp public nonceImp; - - function setUp() public { - nonceImp = new NonceImp(); - } - - function test_readNonce(uint256 _space, uint256 _nonce) public { - nonceImp.writeNonce(_space, _nonce); - assertEq(nonceImp.readNonce(_space), _nonce); - } - - function test_consumeNonce(uint256 _space, uint256 _nonce) public { - vm.assume(_nonce < type(uint256).max - 1); - nonceImp.writeNonce(_space, _nonce); - nonceImp.consumeNonce(_space, _nonce); - assertEq(nonceImp.readNonce(_space), _nonce + 1); - } - - function test_consumeNonce_revertWhenBadNonce(uint256 _space, uint256 _nonce, uint256 _badNonce) public { - vm.assume(_nonce < type(uint256).max - 1); - vm.assume(_badNonce != _nonce); - nonceImp.writeNonce(_space, _nonce); - vm.expectRevert(abi.encodeWithSelector(Nonce.BadNonce.selector, _space, _badNonce, _nonce)); - nonceImp.consumeNonce(_space, _badNonce); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Payload.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Payload.t.sol deleted file mode 100644 index 0619022251..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/modules/Payload.t.sol +++ /dev/null @@ -1,381 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../../src/modules/Payload.sol"; -import { PrimitivesRPC } from "../utils/PrimitivesRPC.sol"; - -import { AdvTest } from "../utils/TestUtils.sol"; -import { Test, Vm } from "forge-std/Test.sol"; -import { console } from "forge-std/console.sol"; - -contract PayloadImp { - - function fromMessage( - bytes calldata message - ) external pure returns (Payload.Decoded memory) { - return Payload.fromMessage(message); - } - - function fromDigest( - bytes32 digest - ) external pure returns (Payload.Decoded memory) { - return Payload.fromDigest(digest); - } - - function fromConfigUpdate( - bytes32 imageHash - ) external pure returns (Payload.Decoded memory) { - return Payload.fromConfigUpdate(imageHash); - } - - function fromPackedCalls( - bytes calldata packed - ) external view returns (Payload.Decoded memory) { - return Payload.fromPackedCalls(packed); - } - - // Expose this otherwise forge won't catch the revert due to depth - function toEIP712( - Payload.Decoded memory payload - ) external pure returns (bytes32) { - return Payload.toEIP712(payload); - } - - function hash( - Payload.Decoded memory payload - ) external view returns (bytes32) { - return Payload.hash(payload); - } - -} - -contract PayloadTest is AdvTest { - - PayloadImp public payloadImp; - - function setUp() public { - payloadImp = new PayloadImp(); - } - - function test_fromPackedCalls(Payload.Call[] memory _calls, uint256 _space, uint256 _nonce) external { - // Convert nonce into legal range - _nonce = bound(_nonce, 0, type(uint56).max); - _space = bound(_space, 0, type(uint160).max); - - for (uint256 i = 0; i < _calls.length; i++) { - // Convert behaviors into legal ones - _calls[i].behaviorOnError = bound( - _calls[i].behaviorOnError, uint256(Payload.BEHAVIOR_IGNORE_ERROR), uint256(Payload.BEHAVIOR_ABORT_ON_ERROR) - ); - } - - Payload.Decoded memory input; - input.kind = Payload.KIND_TRANSACTIONS; - input.calls = _calls; - input.space = _space; - input.nonce = _nonce; - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, input); - console.logBytes(packed); - - Payload.Decoded memory output = payloadImp.fromPackedCalls(packed); - console.logBytes(abi.encode(output)); - - // Input should equal output - assertEq(abi.encode(input), abi.encode(output)); - } - - function test_fromPackedCalls_2bytes( - Payload.Call memory _call - ) external { - // Convert behaviors into legal ones - _call.behaviorOnError = - bound(_call.behaviorOnError, uint256(Payload.BEHAVIOR_IGNORE_ERROR), uint256(Payload.BEHAVIOR_ABORT_ON_ERROR)); - - Payload.Call[] memory _calls = new Payload.Call[](257); - for (uint256 i = 0; i < 257; i++) { - // Force > 1 byte of calls - _calls[i] = _call; - } - - Payload.Decoded memory input; - input.kind = Payload.KIND_TRANSACTIONS; - input.calls = _calls; - - bytes memory packed = PrimitivesRPC.toPackedPayload(vm, input); - Payload.Decoded memory output = payloadImp.fromPackedCalls(packed); - assertEq(abi.encode(input), abi.encode(output)); - } - - function test_fromPackedCalls_self( - Payload.Call memory _call - ) external { - // Convert behaviors into legal ones - _call.behaviorOnError = - bound(_call.behaviorOnError, uint256(Payload.BEHAVIOR_IGNORE_ERROR), uint256(Payload.BEHAVIOR_ABORT_ON_ERROR)); - _call.to = address(payloadImp); - - Payload.Call[] memory _calls = new Payload.Call[](1); - _calls[0] = _call; - - Payload.Decoded memory input; - input.kind = Payload.KIND_TRANSACTIONS; - input.calls = _calls; - - bytes memory packed = PrimitivesRPC.toPackedPayloadForWallet(vm, input, address(payloadImp)); - Payload.Decoded memory output = payloadImp.fromPackedCalls(packed); - assertEq(abi.encode(input), abi.encode(output)); - } - - function test_fromMessage( - bytes calldata _message - ) external view { - Payload.Decoded memory _expected; - _expected.kind = Payload.KIND_MESSAGE; - _expected.message = _message; - - Payload.Decoded memory _actual = payloadImp.fromMessage(_message); - assertEq(abi.encode(_expected), abi.encode(_actual)); - } - - function test_fromDigest( - bytes32 _digest - ) external view { - Payload.Decoded memory _expected; - _expected.kind = Payload.KIND_DIGEST; - _expected.digest = _digest; - - Payload.Decoded memory _actual = payloadImp.fromDigest(_digest); - assertEq(abi.encode(_expected), abi.encode(_actual)); - } - - function test_fromConfigUpdate( - bytes32 _imageHash - ) external view { - Payload.Decoded memory _expected; - _expected.kind = Payload.KIND_CONFIG_UPDATE; - _expected.imageHash = _imageHash; - - Payload.Decoded memory _actual = payloadImp.fromConfigUpdate(_imageHash); - assertEq(abi.encode(_expected), abi.encode(_actual)); - } - - // TODO: Re-enable this after the SDK gains support for the digest kind - // function test_hashFor_kindDigest( - // bytes32 _digest - // ) external { - // Payload.Decoded memory _payload; - // _payload.kind = Payload.KIND_DIGEST; - // _payload.digest = _digest; - // bytes32 contractHash = Payload.hashFor(_payload, address(this)); - // bytes32 payloadHash = PrimitivesRPC.hashForPayload(vm, address(this), uint64(block.chainid), _payload); - // assertEq(contractHash, payloadHash); - // } - - function test_hash_kindMessage(bytes calldata _message, address[] memory _parents) external { - Payload.Decoded memory _payload; - _payload.kind = Payload.KIND_MESSAGE; - _payload.message = _message; - _payload.parentWallets = _parents; - bytes32 contractHash = payloadImp.hash(_payload); - bytes32 payloadHash = PrimitivesRPC.hashForPayload(vm, address(payloadImp), uint64(block.chainid), _payload); - assertEq(contractHash, payloadHash); - } - - function test_hashFor_kindMessage(bytes calldata _message, address[] memory _parents, address _wallet) external { - Payload.Decoded memory _payload; - _payload.kind = Payload.KIND_MESSAGE; - _payload.message = _message; - _payload.parentWallets = _parents; - bytes32 contractHash = Payload.hashFor(_payload, _wallet); - bytes32 payloadHash = PrimitivesRPC.hashForPayload(vm, _wallet, uint64(block.chainid), _payload); - assertEq(contractHash, payloadHash); - } - - function test_hash_kindMessage_as_digest(bytes calldata _message, address[] memory _parents) external { - bytes32 digest = keccak256(_message); - Payload.Decoded memory _payloadDigest; - _payloadDigest.kind = Payload.KIND_DIGEST; - _payloadDigest.digest = digest; - _payloadDigest.parentWallets = _parents; - Payload.Decoded memory _payloadMessage; - _payloadMessage.kind = Payload.KIND_MESSAGE; - _payloadMessage.message = _message; - _payloadMessage.parentWallets = _parents; - bytes32 contractHashDigest = payloadImp.hash(_payloadDigest); - bytes32 payloadHashMessage = - PrimitivesRPC.hashForPayload(vm, address(payloadImp), uint64(block.chainid), _payloadMessage); - assertEq(contractHashDigest, payloadHashMessage); - } - - function test_hashFor_kindMessage_as_digest( - bytes calldata _message, - address[] memory _parents, - address _wallet - ) external { - bytes32 digest = keccak256(_message); - Payload.Decoded memory _payloadDigest; - _payloadDigest.kind = Payload.KIND_DIGEST; - _payloadDigest.digest = digest; - _payloadDigest.parentWallets = _parents; - Payload.Decoded memory _payloadMessage; - _payloadMessage.kind = Payload.KIND_MESSAGE; - _payloadMessage.message = _message; - _payloadMessage.parentWallets = _parents; - bytes32 contractHashDigest = Payload.hashFor(_payloadDigest, _wallet); - bytes32 payloadHashMessage = PrimitivesRPC.hashForPayload(vm, _wallet, uint64(block.chainid), _payloadMessage); - assertEq(contractHashDigest, payloadHashMessage); - } - - function test_hash_kindConfigUpdate(bytes32 _imageHash, address[] memory _parents) external { - Payload.Decoded memory _payload; - _payload.kind = Payload.KIND_CONFIG_UPDATE; - _payload.imageHash = _imageHash; - _payload.parentWallets = _parents; - bytes32 contractHash = payloadImp.hash(_payload); - bytes32 payloadHash = PrimitivesRPC.hashForPayload(vm, address(payloadImp), uint64(block.chainid), _payload); - assertEq(contractHash, payloadHash); - } - - function test_hashFor_kindConfigUpdate(bytes32 _imageHash, address[] memory _parents, address _wallet) external { - Payload.Decoded memory _payload; - _payload.kind = Payload.KIND_CONFIG_UPDATE; - _payload.imageHash = _imageHash; - _payload.parentWallets = _parents; - bytes32 contractHash = Payload.hashFor(_payload, _wallet); - bytes32 payloadHash = PrimitivesRPC.hashForPayload(vm, _wallet, uint64(block.chainid), _payload); - assertEq(contractHash, payloadHash); - } - - function test_hash_kindTransactions( - address _to, - uint256 _value, - bytes memory _data, - uint256 _gasLimit, - bool _delegateCall, - bool _onlyFallback, - uint256 _behaviorOnError, - uint256 _space, - uint256 _nonce, - address[] memory _parents - ) external { - // Convert nonce into legal range - _nonce = bound(_nonce, 0, type(uint56).max); - _space = bound(_space, 0, type(uint160).max); - - Payload.Decoded memory _payload; - _payload.kind = Payload.KIND_TRANSACTIONS; - _payload.calls = new Payload.Call[](2); - _payload.calls[0] = Payload.Call({ - to: _to, - value: _value, - data: _data, - gasLimit: _gasLimit, - delegateCall: _delegateCall, - onlyFallback: _onlyFallback, - behaviorOnError: bound(_behaviorOnError, 0, 0x02) - }); - _payload.calls[1] = Payload.Call({ - to: address(this), - value: 0, - data: hex"001122", - gasLimit: 1000000, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_IGNORE_ERROR - }); - _payload.space = _space; - _payload.nonce = _nonce; - _payload.parentWallets = _parents; - - bytes32 contractHash = payloadImp.hash(_payload); - bytes32 payloadHash = PrimitivesRPC.hashForPayload(vm, address(payloadImp), uint64(block.chainid), _payload); - assertEq(contractHash, payloadHash); - } - - function test_hashFor_kindTransactions( - address _to, - uint256 _value, - bytes memory _data, - uint256 _gasLimit, - bool _delegateCall, - bool _onlyFallback, - uint256 _behaviorOnError, - uint256 _space, - uint256 _nonce, - address[] memory _parents, - address _wallet - ) external { - // Convert nonce into legal range - _nonce = bound(_nonce, 0, type(uint56).max); - _space = bound(_space, 0, type(uint160).max); - - Payload.Decoded memory _payload; - _payload.kind = Payload.KIND_TRANSACTIONS; - _payload.calls = new Payload.Call[](2); - _payload.calls[0] = Payload.Call({ - to: _to, - value: _value, - data: _data, - gasLimit: _gasLimit, - delegateCall: _delegateCall, - onlyFallback: _onlyFallback, - behaviorOnError: bound(_behaviorOnError, 0, 0x02) - }); - _payload.calls[1] = Payload.Call({ - to: address(this), - value: 0, - data: hex"001122", - gasLimit: 1000000, - delegateCall: false, - onlyFallback: false, - behaviorOnError: Payload.BEHAVIOR_IGNORE_ERROR - }); - - _payload.space = _space; - _payload.nonce = _nonce; - _payload.parentWallets = _parents; - - bytes32 contractHash = Payload.hashFor(_payload, _wallet); - bytes32 payloadHash = PrimitivesRPC.hashForPayload(vm, _wallet, uint64(block.chainid), _payload); - assertEq(contractHash, payloadHash); - } - - function test_hashFor_kindTransactions( - Payload.Call[] memory _calls, - uint256 _space, - uint256 _nonce, - address[] memory _parents, - address _wallet - ) external { - // Convert nonce into legal range - _nonce = bound(_nonce, 0, type(uint56).max); - _space = bound(_space, 0, type(uint160).max); - - Payload.Decoded memory _payload; - _payload.kind = Payload.KIND_TRANSACTIONS; - _payload.calls = _calls; - - _payload.space = _space; - _payload.nonce = _nonce; - _payload.parentWallets = _parents; - - boundToLegalPayload(_payload); - - bytes32 contractHash = Payload.hashFor(_payload, _wallet); - bytes32 payloadHash = PrimitivesRPC.hashForPayload(vm, _wallet, uint64(block.chainid), _payload); - assertEq(contractHash, payloadHash); - } - - function test_hashFor_invalidPayload( - uint8 _kind - ) external { - _kind = uint8(bound(_kind, 0x04, 0xff)); - Payload.Decoded memory _payload; - _payload.kind = _kind; - - vm.expectRevert(abi.encodeWithSelector(Payload.InvalidKind.selector, _kind)); - payloadImp.toEIP712(_payload); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/utils/Base64.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/utils/Base64.t.sol deleted file mode 100644 index 73539d3ee1..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/utils/Base64.t.sol +++ /dev/null @@ -1,161 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Base64 } from "../../src/utils/Base64.sol"; -import { Test, Vm } from "forge-std/Test.sol"; - -contract Base64Test is Test { - - function test_encode( - bytes calldata data - ) external pure { - // Test standard encoding - string memory result = Base64.encode(data); - string memory expected = vm.toBase64(data); - assertEq(result, expected); - - // Test file-safe encoding - string memory fileSafeResult = Base64.encode(data, true); - string memory fileSafeExpected = vm.toBase64URL(data); - assertEq(fileSafeResult, fileSafeExpected); - - // Test encoding without padding - string memory noPaddingResult = Base64.encode(data, false, true); - string memory noPaddingExpected = removePadding(vm.toBase64(data)); - assertEq(noPaddingResult, noPaddingExpected); - - // Test file-safe encoding without padding - string memory fileSafeNoPaddingResult = Base64.encode(data, true, true); - string memory fileSafeNoPaddingExpected = removePadding(vm.toBase64URL(data)); - assertEq(fileSafeNoPaddingResult, fileSafeNoPaddingExpected); - } - - function test_decode( - bytes calldata data - ) external pure { - // Test standard base64 - string memory encoded = Base64.encode(data); - bytes memory decoded = Base64.decode(encoded); - assertEq(decoded, data); - - // Test file-safe base64 - string memory fileSafeEncoded = Base64.encode(data, true); - bytes memory fileSafeDecoded = Base64.decode(fileSafeEncoded); - assertEq(fileSafeDecoded, data); - - // Test without padding - string memory noPaddingEncoded = Base64.encode(data, false, true); - bytes memory noPaddingDecoded = Base64.decode(noPaddingEncoded); - assertEq(noPaddingDecoded, data); - - // Test file-safe without padding - string memory fileSafeNoPaddingEncoded = Base64.encode(data, true, true); - bytes memory fileSafeNoPaddingDecoded = Base64.decode(fileSafeNoPaddingEncoded); - assertEq(fileSafeNoPaddingDecoded, data); - } - - function test_encode_empty() external pure { - bytes memory empty; - string memory result = Base64.encode(empty); - assertEq(result, ""); - } - - function test_decode_empty() external pure { - string memory empty = ""; - bytes memory result = Base64.decode(empty); - assertEq(result.length, 0); - } - - // Manual test cases for specific scenarios - function test_manual_cases() external pure { - // Test single byte - bytes memory singleByte = hex"01"; - string memory encoded = Base64.encode(singleByte); - assertEq(encoded, "AQ=="); - bytes memory decoded = Base64.decode(encoded); - assertEq(decoded, singleByte); - - // Test two bytes - bytes memory twoBytes = hex"0102"; - encoded = Base64.encode(twoBytes); - assertEq(encoded, "AQI="); - decoded = Base64.decode(encoded); - assertEq(decoded, twoBytes); - - // Test three bytes - bytes memory threeBytes = hex"010203"; - encoded = Base64.encode(threeBytes); - assertEq(encoded, "AQID"); - decoded = Base64.decode(encoded); - assertEq(decoded, threeBytes); - - // Test four bytes - bytes memory fourBytes = hex"01020304"; - encoded = Base64.encode(fourBytes); - assertEq(encoded, "AQIDBA=="); - decoded = Base64.decode(encoded); - assertEq(decoded, fourBytes); - - // Test file-safe encoding - encoded = Base64.encode(fourBytes, true); - assertEq(encoded, "AQIDBA=="); - decoded = Base64.decode(encoded); - assertEq(decoded, fourBytes); - - // Test without padding - encoded = Base64.encode(fourBytes, false, true); - assertEq(encoded, "AQIDBA"); - decoded = Base64.decode(encoded); - assertEq(decoded, fourBytes); - - // Test file-safe without padding - encoded = Base64.encode(fourBytes, true, true); - assertEq(encoded, "AQIDBA"); - decoded = Base64.decode(encoded); - assertEq(decoded, fourBytes); - - // Test all zeros - bytes memory allZeros = hex"00000000"; - encoded = Base64.encode(allZeros); - assertEq(encoded, "AAAAAA=="); - decoded = Base64.decode(encoded); - assertEq(decoded, allZeros); - - // Test all ones - bytes memory allOnes = hex"FFFFFFFF"; - encoded = Base64.encode(allOnes); - assertEq(encoded, "/////w=="); - decoded = Base64.decode(encoded); - assertEq(decoded, allOnes); - - // Test non-padded base64 string with length not divisible by 4 - // This will hit the break statement in the decode function - bytes memory nonPaddedData = hex"010203"; - string memory nonPaddedEncoded = "AQID"; - bytes memory nonPaddedDecoded = Base64.decode(nonPaddedEncoded); - assertEq(nonPaddedDecoded, nonPaddedData); - - // "AQI" is 3 characters (mod 4 = 3), so it goes down the "non-padded" path in decode - string memory nonPadded = "AQI"; - bytes memory expected = hex"0102"; // This is what "AQI=" would normally decode to - decoded = Base64.decode(nonPadded); - assertEq(decoded, expected); - } - - // Helper function to remove padding from base64 string - function removePadding( - string memory data - ) internal pure returns (string memory) { - bytes memory dataBytes = bytes(data); - uint256 length = dataBytes.length; - while (length > 0 && dataBytes[length - 1] == "=") { - length--; - } - bytes memory result = new bytes(length); - for (uint256 i = 0; i < length; i++) { - result[i] = dataBytes[i]; - } - return string(result); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/utils/LibBytes.t.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/utils/LibBytes.t.sol deleted file mode 100644 index 900dca5dc4..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/utils/LibBytes.t.sol +++ /dev/null @@ -1,335 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { LibBytes } from "../../src/utils/LibBytes.sol"; -import { AdvTest } from "./TestUtils.sol"; -import { Test, Vm } from "forge-std/Test.sol"; - -contract LibBytesImp { - - function readFirstUint8( - bytes calldata data - ) external pure returns (uint8 a, uint256 newPointer) { - return LibBytes.readFirstUint8(data); - } - - function readUint8(bytes calldata data, uint256 index) external pure returns (uint8 a, uint256 newPointer) { - return LibBytes.readUint8(data, index); - } - - function readAddress(bytes calldata data, uint256 index) external pure returns (address a, uint256 newPointer) { - return LibBytes.readAddress(data, index); - } - - function readUint16(bytes calldata data, uint256 index) external pure returns (uint16 a, uint256 newPointer) { - return LibBytes.readUint16(data, index); - } - - function readUintX( - bytes calldata data, - uint256 index, - uint256 length - ) external pure returns (uint256 a, uint256 newPointer) { - return LibBytes.readUintX(data, index, length); - } - - function readUint24(bytes calldata data, uint256 index) external pure returns (uint24 a, uint256 newPointer) { - return LibBytes.readUint24(data, index); - } - - function readUint64(bytes calldata data, uint256 index) external pure returns (uint64 a, uint256 newPointer) { - return LibBytes.readUint64(data, index); - } - - function readBytes4(bytes calldata data, uint256 pointer) external pure returns (bytes4 a, uint256 newPointer) { - return LibBytes.readBytes4(data, pointer); - } - - function readBytes32(bytes calldata data, uint256 pointer) external pure returns (bytes32 a, uint256 newPointer) { - return LibBytes.readBytes32(data, pointer); - } - - function readUint256(bytes calldata data, uint256 index) external pure returns (uint256 a, uint256 newPointer) { - return LibBytes.readUint256(data, index); - } - - function readUint160(bytes calldata data, uint256 index) external pure returns (uint160 a, uint256 newPointer) { - return LibBytes.readUint160(data, index); - } - - function readRSVCompact( - bytes calldata data, - uint256 index - ) external pure returns (bytes32 r, bytes32 s, uint8 v, uint256 newPointer) { - return LibBytes.readRSVCompact(data, index); - } - -} - -contract LibBytesTest is AdvTest { - - LibBytesImp public bytesImp; - - function setUp() public { - bytesImp = new LibBytesImp(); - } - - function test_readFirstUint8( - bytes calldata suffix - ) external view { - uint8 value = 0x12; - bytes memory fullData = bytes.concat(abi.encodePacked(value), suffix); - (uint8 result, uint256 newPointer) = bytesImp.readFirstUint8(fullData); - assertEq(result, value); - assertEq(newPointer, 1); - } - - function test_readUint8(bytes calldata prefix, uint8 value, bytes calldata suffix) external view { - bytes memory fullData = bytes.concat(prefix, abi.encodePacked(value), suffix); - uint256 index = prefix.length; - (uint8 result, uint256 newPointer) = bytesImp.readUint8(fullData, index); - assertEq(result, value); - assertEq(newPointer, index + 1); - } - - function test_readAddress(bytes calldata prefix, address value, bytes calldata suffix) external view { - bytes memory fullData = bytes.concat(prefix, abi.encodePacked(value), suffix); - uint256 index = prefix.length; - (address result, uint256 newPointer) = bytesImp.readAddress(fullData, index); - assertEq(result, value); - assertEq(newPointer, index + 20); - } - - function test_readUint16(bytes calldata prefix, uint16 value, bytes calldata suffix) external view { - bytes memory fullData = bytes.concat(prefix, abi.encodePacked(value), suffix); - uint256 index = prefix.length; - (uint16 result, uint256 newPointer) = bytesImp.readUint16(fullData, index); - assertEq(result, value); - assertEq(newPointer, index + 2); - } - - function test_readUintX(bytes calldata prefix, uint256 value, uint256 length, bytes calldata suffix) external view { - length = bound(length, 0, 32); - - uint256 mask = length == 32 ? type(uint256).max : ((1 << (length * 8)) - 1); - uint256 maskedValue = value & mask; - - bytes memory encodedValue; - if (length == 1) { - encodedValue = abi.encodePacked(uint8(maskedValue)); - } else if (length == 2) { - encodedValue = abi.encodePacked(uint16(maskedValue)); - } else if (length == 3) { - encodedValue = abi.encodePacked(uint24(maskedValue)); - } else if (length == 4) { - encodedValue = abi.encodePacked(uint32(maskedValue)); - } else if (length == 5) { - encodedValue = abi.encodePacked(uint40(maskedValue)); - } else if (length == 6) { - encodedValue = abi.encodePacked(uint48(maskedValue)); - } else if (length == 7) { - encodedValue = abi.encodePacked(uint56(maskedValue)); - } else if (length == 8) { - encodedValue = abi.encodePacked(uint64(maskedValue)); - } else if (length == 9) { - encodedValue = abi.encodePacked(uint72(maskedValue)); - } else if (length == 10) { - encodedValue = abi.encodePacked(uint80(maskedValue)); - } else if (length == 11) { - encodedValue = abi.encodePacked(uint88(maskedValue)); - } else if (length == 12) { - encodedValue = abi.encodePacked(uint96(maskedValue)); - } else if (length == 13) { - encodedValue = abi.encodePacked(uint104(maskedValue)); - } else if (length == 14) { - encodedValue = abi.encodePacked(uint112(maskedValue)); - } else if (length == 15) { - encodedValue = abi.encodePacked(uint120(maskedValue)); - } else if (length == 16) { - encodedValue = abi.encodePacked(uint128(maskedValue)); - } else if (length == 17) { - encodedValue = abi.encodePacked(uint136(maskedValue)); - } else if (length == 18) { - encodedValue = abi.encodePacked(uint144(maskedValue)); - } else if (length == 19) { - encodedValue = abi.encodePacked(uint152(maskedValue)); - } else if (length == 20) { - encodedValue = abi.encodePacked(uint160(maskedValue)); - } else if (length == 21) { - encodedValue = abi.encodePacked(uint168(maskedValue)); - } else if (length == 22) { - encodedValue = abi.encodePacked(uint176(maskedValue)); - } else if (length == 23) { - encodedValue = abi.encodePacked(uint184(maskedValue)); - } else if (length == 24) { - encodedValue = abi.encodePacked(uint192(maskedValue)); - } else if (length == 25) { - encodedValue = abi.encodePacked(uint200(maskedValue)); - } else if (length == 26) { - encodedValue = abi.encodePacked(uint208(maskedValue)); - } else if (length == 27) { - encodedValue = abi.encodePacked(uint216(maskedValue)); - } else if (length == 28) { - encodedValue = abi.encodePacked(uint224(maskedValue)); - } else if (length == 29) { - encodedValue = abi.encodePacked(uint232(maskedValue)); - } else if (length == 30) { - encodedValue = abi.encodePacked(uint240(maskedValue)); - } else if (length == 31) { - encodedValue = abi.encodePacked(uint248(maskedValue)); - } else { - encodedValue = abi.encodePacked(uint256(maskedValue)); - } - - bytes memory fullData = bytes.concat(prefix, encodedValue, suffix); - uint256 index = prefix.length; - (uint256 result, uint256 newPointer) = bytesImp.readUintX(fullData, index, length); - - assertEq(result, maskedValue); - assertEq(newPointer, index + length); - } - - function test_readUint24(bytes calldata prefix, uint24 value, bytes calldata suffix) external view { - bytes memory fullData = bytes.concat(prefix, abi.encodePacked(value), suffix); - uint256 index = prefix.length; - (uint24 result, uint256 newPointer) = bytesImp.readUint24(fullData, index); - assertEq(result, value); - assertEq(newPointer, index + 3); - } - - function test_readUint64(bytes calldata prefix, uint64 value, bytes calldata suffix) external view { - bytes memory fullData = bytes.concat(prefix, abi.encodePacked(value), suffix); - uint256 index = prefix.length; - (uint64 result, uint256 newPointer) = bytesImp.readUint64(fullData, index); - assertEq(result, value); - assertEq(newPointer, index + 8); - } - - function test_readBytes4(bytes calldata prefix, bytes4 value, bytes calldata suffix) external view { - bytes memory fullData = bytes.concat(prefix, abi.encodePacked(value), suffix); - uint256 pointer = prefix.length; - (bytes4 result, uint256 newPointer) = bytesImp.readBytes4(fullData, pointer); - assertEq(result, value); - assertEq(newPointer, pointer + 4); - } - - function test_readBytes32(bytes calldata prefix, bytes32 value, bytes calldata suffix) external view { - bytes memory fullData = bytes.concat(prefix, abi.encodePacked(value), suffix); - uint256 pointer = prefix.length; - (bytes32 result, uint256 newPointer) = bytesImp.readBytes32(fullData, pointer); - assertEq(result, value); - assertEq(newPointer, pointer + 32); - } - - function test_readUint256(bytes calldata prefix, uint256 value, bytes calldata suffix) external view { - bytes memory fullData = bytes.concat(prefix, abi.encodePacked(value), suffix); - uint256 index = prefix.length; - (uint256 result, uint256 newPointer) = bytesImp.readUint256(fullData, index); - assertEq(result, value); - assertEq(newPointer, index + 32); - } - - function test_readUint160(bytes calldata prefix, uint160 value, bytes calldata suffix) external view { - bytes memory fullData = bytes.concat(prefix, abi.encodePacked(value), suffix); - uint256 index = prefix.length; - (uint160 result, uint256 newPointer) = bytesImp.readUint160(fullData, index); - assertEq(result, value); - assertEq(newPointer, index + 20); - } - - function test_readRSVCompact( - bytes calldata prefix, - bytes32 r, - uint256 sWithParity, - bytes calldata suffix - ) external view { - bool parityBit = (sWithParity & (1 << 255)) > 0; - bytes32 s = bytes32(sWithParity & ((1 << 255) - 1)); - uint8 expectedV = parityBit ? 28 : 27; - - bytes memory fullData = bytes.concat(prefix, abi.encodePacked(r), abi.encodePacked(bytes32(sWithParity)), suffix); - uint256 index = prefix.length; - (bytes32 resultR, bytes32 resultS, uint8 resultV, uint256 newPointer) = bytesImp.readRSVCompact(fullData, index); - - assertEq(resultR, r); - assertEq(resultS, s); - assertEq(resultV, expectedV); - assertEq(newPointer, index + 64); - } - - function test_readFirstUint8_emptyData() external view { - bytes memory emptyData = new bytes(0); - bytesImp.readFirstUint8(emptyData); - } - - function test_readUint8_outOfBounds( - bytes calldata data - ) external view { - vm.assume(data.length > 0); - bytesImp.readUint8(data, data.length); - } - - function test_readAddress_outOfBounds( - bytes calldata data - ) external view { - vm.assume(data.length < 20); - bytesImp.readAddress(data, 0); - } - - function test_readUint16_outOfBounds( - bytes calldata data - ) external view { - vm.assume(data.length < 2); - bytesImp.readUint16(data, 0); - } - - function test_readUint24_outOfBounds( - bytes calldata data - ) external view { - vm.assume(data.length < 3); - bytesImp.readUint24(data, 0); - } - - function test_readUint64_outOfBounds( - bytes calldata data - ) external view { - vm.assume(data.length < 8); - bytesImp.readUint64(data, 0); - } - - function test_readBytes4_outOfBounds( - bytes calldata data - ) external view { - vm.assume(data.length < 4); - bytesImp.readBytes4(data, 0); - } - - function test_readBytes32_outOfBounds( - bytes calldata data - ) external view { - vm.assume(data.length < 32); - bytesImp.readBytes32(data, 0); - } - - function test_readUint256_outOfBounds( - bytes calldata data - ) external view { - vm.assume(data.length < 32); - bytesImp.readUint256(data, 0); - } - - function test_readUint160_outOfBounds( - bytes calldata data - ) external view { - vm.assume(data.length < 20); - bytesImp.readUint160(data, 0); - } - - function test_readRSVCompact_outOfBounds( - bytes calldata data - ) external view { - vm.assume(data.length < 64); - bytesImp.readRSVCompact(data, 0); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/utils/PrimitivesRPC.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/utils/PrimitivesRPC.sol deleted file mode 100644 index d20f8208d6..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/utils/PrimitivesRPC.sol +++ /dev/null @@ -1,581 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.13; - -import { Vm } from "forge-std/Vm.sol"; -import { Payload } from "src/modules/Payload.sol"; - -library PrimitivesRPC { - - uint256 private constant COUNTER_UNINITIALIZED = 0; - uint256 private constant COUNTER_SLOT = uint256(keccak256("sequence.primitives-rpc.counter")); - - function getCounter() private view returns (uint256) { - bytes32 counterSlot = bytes32(COUNTER_SLOT); - uint256 value; - assembly { - value := sload(counterSlot) - } - return value; - } - - function setCounter( - uint256 value - ) private { - bytes32 counterSlot = bytes32(COUNTER_SLOT); - assembly { - sstore(counterSlot, value) - } - } - - function rpcURL( - Vm _vm - ) internal returns (string memory) { - uint256 minPort = uint256(_vm.envUint("SEQ_SDK_RPC_MIN_PORT")); - uint256 maxPort = uint256(_vm.envUint("SEQ_SDK_RPC_MAX_PORT")); - require(maxPort >= minPort, "Invalid port range"); - - // Get or initialize counter - uint256 counter = getCounter(); - if (counter == COUNTER_UNINITIALIZED) { - counter = uint256(keccak256(abi.encodePacked(msg.data))); - } - - // Increment counter - counter++; - setCounter(counter); - - // Generate port within range using counter - uint256 range = maxPort - minPort + 1; - uint256 randomPort = minPort + (counter % range); - - string memory prefix = _vm.envString("SEQ_SDK_RPC_URL_PREFIX"); - string memory suffix = _vm.envString("SEQ_SDK_RPC_URL_SUFFIX"); - - return string.concat(prefix, _vm.toString(randomPort), suffix); - } - - // ---------------------------------------------------------------- - // devTools - // ---------------------------------------------------------------- - - function randomConfig( - Vm _vm, - uint256 _maxDepth, - uint256 _seed, - uint256 _minThresholdOnNested, - string memory _skew - ) internal returns (string memory) { - string memory params = string.concat( - '{"maxDepth":', - _vm.toString(_maxDepth), - ',"seed":"', - _vm.toString(_seed), - '","minThresholdOnNested":', - _vm.toString(_minThresholdOnNested), - ',"skewed":"', - _skew, - '"}' - ); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "devTools_randomConfig", params); - return string(rawResponse); - } - - function randomSessionTopology( - Vm _vm, - uint256 _maxDepth, - uint256 _maxPermissions, - uint256 _maxRules, - uint256 _seed - ) internal returns (string memory) { - string memory params = string.concat( - '{"maxDepth":', - _vm.toString(_maxDepth), - ',"maxPermissions":', - _vm.toString(_maxPermissions), - ',"maxRules":', - _vm.toString(_maxRules), - ',"seed":"', - _vm.toString(_seed), - '"}' - ); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "devTools_randomSessionTopology", params); - return string(rawResponse); - } - - // ---------------------------------------------------------------- - // payload - // ---------------------------------------------------------------- - - function toPackedPayload(Vm _vm, Payload.Decoded memory _decoded) internal returns (bytes memory) { - string memory params = string.concat('{"payload":"', _vm.toString(abi.encode(_decoded)), '"}'); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "payload_toPacked", params); - return (rawResponse); - } - - function toPackedPayloadForWallet( - Vm _vm, - Payload.Decoded memory _decoded, - address _wallet - ) internal returns (bytes memory) { - string memory params = - string.concat('{"payload":"', _vm.toString(abi.encode(_decoded)), '","wallet":"', _vm.toString(_wallet), '"}'); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "payload_toPacked", params); - return (rawResponse); - } - - function hashForPayload( - Vm _vm, - address _wallet, - uint64 _chainId, - Payload.Decoded memory _decoded - ) internal returns (bytes32) { - string memory params = string.concat( - '{"wallet":"', - _vm.toString(_wallet), - '","chainId":"', - _vm.toString(_chainId), - '","payload":"', - _vm.toString(abi.encode(_decoded)), - '"}' - ); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "payload_hashFor", params); - return abi.decode(rawResponse, (bytes32)); - } - - // ---------------------------------------------------------------- - // config - // ---------------------------------------------------------------- - - function newConfig( - Vm _vm, - uint16 _threshold, - uint256 _checkpoint, - string memory _elements - ) internal returns (string memory) { - string memory params = string.concat( - '{"threshold":"', - _vm.toString(_threshold), - '","checkpoint":"', - _vm.toString(_checkpoint), - '","from":"flat","content":"', - _elements, - '"}' - ); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "config_new", params); - return string(rawResponse); - } - - function newConfigWithCheckpointer( - Vm _vm, - address _checkpointer, - uint16 _threshold, - uint256 _checkpoint, - string memory _elements - ) internal returns (string memory) { - string memory params = string.concat( - '{"threshold":"', - _vm.toString(_threshold), - '","checkpoint":"', - _vm.toString(_checkpoint), - '","from":"flat","content":"', - _elements, - '","checkpointer":"', - _vm.toString(_checkpointer), - '"}' - ); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "config_new", params); - return string(rawResponse); - } - - function toEncodedConfig(Vm _vm, string memory configJson) internal returns (bytes memory) { - string memory params = string.concat('{"input":', configJson, "}"); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "config_encode", params); - return (rawResponse); - } - - function getImageHash(Vm _vm, string memory configJson) internal returns (bytes32) { - string memory params = string.concat('{"input":', configJson, "}"); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "config_imageHash", params); - bytes memory hexBytes = (rawResponse); - return abi.decode(hexBytes, (bytes32)); - } - - // ---------------------------------------------------------------- - // signature - // ---------------------------------------------------------------- - - function toEncodedSignature( - Vm _vm, - string memory configJson, - string memory signatures, - bool _chainId - ) internal returns (bytes memory) { - // If you wanted no chainId, adapt the JSON, e.g. `"chainId":false`. - string memory params = string.concat( - '{"input":', configJson, ',"signatures":"', signatures, '","chainId":', _chainId ? "true" : "false", "}" - ); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "signature_encode", params); - return (rawResponse); - } - - function toEncodedSignatureWithCheckpointerData( - Vm _vm, - string memory configJson, - string memory signatures, - bool _chainId, - bytes memory checkpointerData - ) internal returns (bytes memory) { - string memory params = string.concat( - '{"input":', - configJson, - ',"signatures":"', - signatures, - '","chainId":', - _chainId ? "true" : "false", - ',"checkpointerData":"', - _vm.toString(checkpointerData), - '"}' - ); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "signature_encode", params); - return (rawResponse); - } - - function concatSignatures(Vm _vm, bytes[] memory _signatures) internal returns (bytes memory) { - string memory arrayPrefix = '{"signatures":['; - string memory arraySuffix = "]}"; - string memory arrayMid; - for (uint256 i = 0; i < _signatures.length; i++) { - arrayMid = string.concat(arrayMid, i == 0 ? '"' : ',"', _vm.toString(_signatures[i]), '"'); - } - string memory params = string.concat(arrayPrefix, arrayMid, arraySuffix); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "signature_concat", params); - return (rawResponse); - } - - // ---------------------------------------------------------------- - // session - // ---------------------------------------------------------------- - - function sessionEmpty(Vm _vm, address identitySigner) internal returns (string memory) { - string memory params = string.concat('{"identitySigner":"', _vm.toString(identitySigner), '"}'); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "session_empty", params); - return string(rawResponse); - } - - function sessionEncodeTopology(Vm _vm, string memory topologyInput) internal returns (bytes memory) { - string memory params = string.concat('{"sessionTopology":', topologyInput, "}"); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "session_encodeTopology", params); - return rawResponse; - } - - function sessionEncodeCallSignatures( - Vm _vm, - string memory topologyInput, - string[] memory callSignatures, - address[] memory explicitSigners, - address[] memory implicitSigners - ) internal returns (bytes memory) { - string memory callSignaturesJson = _toJsonUnwrapped(_vm, callSignatures); - string memory explicitSignersJson = _toJson(_vm, explicitSigners); - string memory implicitSignersJson = _toJson(_vm, implicitSigners); - string memory params = string.concat( - '{"sessionTopology":', - topologyInput, - ',"callSignatures":', - callSignaturesJson, - ',"explicitSigners":', - explicitSignersJson, - ',"implicitSigners":', - implicitSignersJson, - "}" - ); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "session_encodeCallSignatures", params); - return rawResponse; - } - - function sessionImageHash(Vm _vm, string memory sessionTopologyInput) internal returns (bytes32) { - string memory params = string.concat('{"sessionTopology":', sessionTopologyInput, "}"); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "session_imageHash", params); - return abi.decode(rawResponse, (bytes32)); - } - - // ---------------------------------------------------------------- - // session explicit - // ---------------------------------------------------------------- - - function sessionExplicitAdd( - Vm _vm, - string memory sessionInput, - string memory topologyInput - ) internal returns (string memory) { - string memory params = string.concat('{"explicitSession":', sessionInput, ',"sessionTopology":', topologyInput, "}"); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "session_explicit_add", params); - return string(rawResponse); - } - - function sessionExplicitRemove( - Vm _vm, - address explicitSessionAddress, - string memory topologyInput - ) internal returns (string memory) { - string memory params = string.concat( - '{"explicitSessionAddress":"', _vm.toString(explicitSessionAddress), '","sessionTopology":', topologyInput, "}" - ); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "session_explicit_remove", params); - return string(rawResponse); - } - - // ---------------------------------------------------------------- - // session implicit - // ---------------------------------------------------------------- - - function sessionImplicitAddBlacklistAddress( - Vm _vm, - string memory topologyInput, - address addressToAdd - ) internal returns (string memory) { - string memory params = - string.concat('{"sessionTopology":', topologyInput, ',"blacklistAddress":"', _vm.toString(addressToAdd), '"}'); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "session_implicit_addBlacklistAddress", params); - return string(rawResponse); - } - - function sessionImplicitRemoveBlacklistAddress( - Vm _vm, - string memory topologyInput, - address addressToRemove - ) internal returns (string memory) { - string memory params = - string.concat('{"sessionTopology":', topologyInput, ',"blacklistAddress":"', _vm.toString(addressToRemove), '"}'); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "session_implicit_removeBlacklistAddress", params); - return string(rawResponse); - } - - // ---------------------------------------------------------------- - // wallet - // ---------------------------------------------------------------- - - function getAddress(Vm _vm, bytes32 _configHash, address _factory, address _module) internal returns (address) { - string memory params = string.concat( - '{"imageHash":"', - _vm.toString(_configHash), - '","factory":"', - _vm.toString(_factory), - '","module":"', - _vm.toString(_module), - '"}' - ); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "address_calculate", params); - // Convert the raw response (a non-padded hex string) into an address - string memory addrStr = _vm.toString(rawResponse); - return parseAddress(addrStr); - } - - function parseAddress( - string memory _a - ) internal pure returns (address) { - bytes memory b = bytes(_a); - require(b.length == 42, "Invalid address format"); // "0x" + 40 hex characters - uint160 addr = 0; - for (uint256 i = 2; i < 42; i += 2) { - addr *= 256; - uint8 b1 = uint8(b[i]); - uint8 b2 = uint8(b[i + 1]); - uint8 nib1; - uint8 nib2; - // Convert first hex character - if (b1 >= 48 && b1 <= 57) { - // '0'-'9' - nib1 = b1 - 48; - } else if (b1 >= 65 && b1 <= 70) { - // 'A'-'F' - nib1 = b1 - 55; - } else if (b1 >= 97 && b1 <= 102) { - // 'a'-'f' - nib1 = b1 - 87; - } else { - revert("Invalid hex char"); - } - // Convert second hex character - if (b2 >= 48 && b2 <= 57) { - nib2 = b2 - 48; - } else if (b2 >= 65 && b2 <= 70) { - nib2 = b2 - 55; - } else if (b2 >= 97 && b2 <= 102) { - nib2 = b2 - 87; - } else { - revert("Invalid hex char"); - } - addr += uint160(nib1 * 16 + nib2); - } - return address(addr); - } - - // ---------------------------------------------------------------- - // utils - // ---------------------------------------------------------------- - - function _toJson(Vm _vm, address[] memory _addresses) internal pure returns (string memory) { - if (_addresses.length == 0) { - return "[]"; - } - string memory json = '["'; - for (uint256 i = 0; i < _addresses.length; i++) { - json = string.concat(json, _vm.toString(_addresses[i]), '"'); - if (i < _addresses.length - 1) { - json = string.concat(json, ',"'); - } - } - return string.concat(json, "]"); - } - - // For lists of strings - function _toJson(Vm, string[] memory _strings) internal pure returns (string memory) { - if (_strings.length == 0) { - return "[]"; - } - string memory json = '["'; - for (uint256 i = 0; i < _strings.length; i++) { - json = string.concat(json, _strings[i], '"'); - if (i < _strings.length - 1) { - json = string.concat(json, ',"'); - } - } - return string.concat(json, "]"); - } - - // For lists of JSONified strings - function _toJsonUnwrapped(Vm, string[] memory _strings) internal pure returns (string memory) { - if (_strings.length == 0) { - return "[]"; - } - string memory json = "["; - for (uint256 i = 0; i < _strings.length; i++) { - json = string.concat(json, _strings[i]); - if (i < _strings.length - 1) { - json = string.concat(json, ","); - } - } - return string.concat(json, "]"); - } - - // ---------------------------------------------------------------- - // recovery - // ---------------------------------------------------------------- - - function recoveryHashFromLeaves(Vm _vm, string memory leaves) internal returns (bytes32) { - string memory params = string.concat('{"leaves":"', leaves, '"}'); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "recovery_hashFromLeaves", params); - return abi.decode(rawResponse, (bytes32)); - } - - function recoveryEncode(Vm _vm, string memory leaves) internal returns (bytes memory) { - string memory params = string.concat('{"leaves":"', leaves, '"}'); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "recovery_encode", params); - return rawResponse; - } - - function recoveryTrim(Vm _vm, string memory leaves, address signer) internal returns (bytes memory) { - string memory params = string.concat('{"leaves":"', leaves, '","signer":"', _vm.toString(signer), '"}'); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "recovery_trim", params); - return rawResponse; - } - - function recoveryHashEncoded(Vm _vm, bytes memory encoded) internal returns (bytes32) { - string memory params = string.concat('{"encoded":"', _vm.toString(encoded), '"}'); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "recovery_hashEncoded", params); - return abi.decode(rawResponse, (bytes32)); - } - - // ---------------------------------------------------------------- - // passkeys - // ---------------------------------------------------------------- - - struct PasskeyPublicKey { - bytes32 x; - bytes32 y; - bool requireUserVerification; - string credentialId; - bytes32 metadataHash; - } - - struct PasskeySignatureComponents { - bytes32 r; - bytes32 s; - bytes authenticatorData; - string clientDataJson; - } - - function passkeysEncodeSignature( - Vm _vm, - PasskeyPublicKey memory _pk, - PasskeySignatureComponents memory _sig, - bool _embedMetadata - ) internal returns (bytes memory) { - string memory params = '{"x":"'; - params = string.concat(params, _vm.toString(_pk.x)); - params = string.concat(params, '","y":"', _vm.toString(_pk.y)); - params = string.concat(params, '","requireUserVerification":', _pk.requireUserVerification ? "true" : "false"); - if (bytes(_pk.credentialId).length > 0) { - params = string.concat(params, ',"credentialId":"', _pk.credentialId, '"'); - } else if (_pk.metadataHash != bytes32(0)) { - params = string.concat(params, ',"metadataHash":"', _vm.toString(_pk.metadataHash), '"'); - } - params = string.concat(params, ',"r":"', _vm.toString(_sig.r)); - params = string.concat(params, '","s":"', _vm.toString(_sig.s)); - params = string.concat(params, '","authenticatorData":"', _vm.toString(_sig.authenticatorData)); - params = string.concat(params, '","clientDataJson":', _sig.clientDataJson); - params = string.concat(params, ',"embedMetadata":', _embedMetadata ? "true" : "false", "}"); - - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "passkeys_encodeSignature", params); - return rawResponse; - } - - function passkeysDecodeSignature(Vm _vm, bytes memory _encodedSignature) internal returns (string memory) { - string memory params = string.concat('{"encodedSignature":"', _vm.toString(_encodedSignature), '"}'); - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "passkeys_decodeSignature", params); - return string(rawResponse); - } - - function passkeysComputeRoot(Vm _vm, PasskeyPublicKey memory _pk) internal returns (bytes32) { - string memory params = '{"x":"'; - params = string.concat(params, _vm.toString(_pk.x)); - params = string.concat(params, '","y":"', _vm.toString(_pk.y)); - params = string.concat(params, '","requireUserVerification":', _pk.requireUserVerification ? "true" : "false"); - if (bytes(_pk.credentialId).length > 0) { - params = string.concat(params, ',"credentialId":"', _pk.credentialId, '"'); - } else if (_pk.metadataHash != bytes32(0)) { - params = string.concat(params, ',"metadataHash":"', _vm.toString(_pk.metadataHash), '"'); - } - params = string.concat(params, "}"); - - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "passkeys_computeRoot", params); - return abi.decode(rawResponse, (bytes32)); - } - - function passkeysValidateSignature( - Vm _vm, - bytes32 _challenge, - PasskeyPublicKey memory _pk, - PasskeySignatureComponents memory _sig - ) internal returns (bool) { - string memory params = '{"challenge":"'; - params = string.concat(params, _vm.toString(_challenge)); - params = string.concat(params, '","x":"', _vm.toString(_pk.x)); - params = string.concat(params, '","y":"', _vm.toString(_pk.y)); - params = string.concat(params, '","requireUserVerification":', _pk.requireUserVerification ? "true" : "false"); - if (bytes(_pk.credentialId).length > 0) { - params = string.concat(params, ',"credentialId":"', _pk.credentialId, '"'); - } else if (_pk.metadataHash != bytes32(0)) { - params = string.concat(params, ',"metadataHash":"', _vm.toString(_pk.metadataHash), '"'); - } - params = string.concat(params, ',"r":"', _vm.toString(_sig.r)); - params = string.concat(params, '","s":"', _vm.toString(_sig.s)); - params = string.concat(params, '","authenticatorData":"', _vm.toString(_sig.authenticatorData)); - params = string.concat(params, '","clientDataJson":', _sig.clientDataJson, "}"); - - bytes memory rawResponse = _vm.rpc(rpcURL(_vm), "passkeys_validateSignature", params); - return abi.decode(rawResponse, (bool)); - } - -} diff --git a/lib/signals-implicit-mode/lib/sequence-v3/test/utils/TestUtils.sol b/lib/signals-implicit-mode/lib/sequence-v3/test/utils/TestUtils.sol deleted file mode 100644 index 191a713964..0000000000 --- a/lib/signals-implicit-mode/lib/sequence-v3/test/utils/TestUtils.sol +++ /dev/null @@ -1,129 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { Payload } from "../../src/modules/Payload.sol"; -import "forge-std/Test.sol"; -import "forge-std/console.sol"; - -contract AdvTest is Test { - - function boundPk( - uint256 _a - ) internal pure returns (uint256) { - _a = bound(_a, 1, 0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364139); - return _a; - } - - function boundToLegalPayload( - Payload.Decoded memory _payload - ) internal pure { - _payload.kind = uint8(bound(_payload.kind, uint8(0), uint8(Payload.KIND_DIGEST))); - - if (_payload.kind == Payload.KIND_TRANSACTIONS) { - _payload.space = bound(_payload.space, 0, type(uint160).max); - _payload.nonce = bound(_payload.nonce, 0, type(uint56).max); - - for (uint256 i = 0; i < _payload.calls.length; i++) { - _payload.calls[i].behaviorOnError = bound( - _payload.calls[i].behaviorOnError, - uint256(Payload.BEHAVIOR_IGNORE_ERROR), - uint256(Payload.BEHAVIOR_ABORT_ON_ERROR) - ); - } - } - } - - function assumeNotPrecompile2( - address _addr - ) internal view { - assumeNotPrecompile(_addr); - vm.assume(_addr.code.length == 0); - vm.assume(_addr != address(0x000000000000000000636F6e736F6c652e6c6f67)); - vm.assume(_addr != address(0x4e59b44847b379578588920cA78FbF26c0B4956C)); - } - - function useSeed( - uint256 seed - ) internal pure returns (bytes32 value, uint256 newSeed) { - value = keccak256(abi.encode(seed)); - newSeed = uint256(value); - } - - function boundNoPrecompile( - address _addr - ) internal view returns (address) { - address candidate = _addr; - address invalid1 = address(0x000000000000000000636F6e736F6c652e6c6f67); - address invalid2 = address(0x4e59b44847b379578588920cA78FbF26c0B4956C); - - while ( - (uint160(candidate) >= 1 && uint160(candidate) <= 0xff) || candidate == invalid1 || candidate == invalid2 - || candidate.code.length > 0 - ) { - candidate = address(uint160(uint256(keccak256(abi.encode(candidate))))); - } - - return candidate; - } - - // ERC-2098 Compact Signature - function signRSVCompact(bytes32 hash, Vm.Wallet memory wallet) internal pure returns (bytes memory) { - (uint8 v, bytes32 r, bytes32 s) = vm.sign(wallet.privateKey, hash); - uint256 yParity = v == 28 ? 1 << 255 : 0; - bytes32 yParityAndS = bytes32(uint256(s) | yParity); - return abi.encodePacked(r, yParityAndS); - } - - function generateRandomString( - uint256 seed - ) internal pure returns (string memory) { - uint256 size; - - (seed, size) = useSeed(seed, 0, 300); - bytes memory _bytes = new bytes(size); - - // For every byte, select a UTF-8 random char (a-z, A-Z, 0-9, _, -, !, or ?) - for (uint256 i = 0; i < size; i++) { - uint256 charType; - (seed, charType) = useSeed(seed, 0, 4); - - if (charType == 0) { - // lowercase a-z (ASCII 97-122) - uint256 char; - (seed, char) = useSeed(seed, 97, 122); - _bytes[i] = bytes1(uint8(char)); - } else if (charType == 1) { - // uppercase A-Z (ASCII 65-90) - uint256 char; - (seed, char) = useSeed(seed, 65, 90); - _bytes[i] = bytes1(uint8(char)); - } else if (charType == 2) { - // numbers 0-9 (ASCII 48-57) - uint256 char; - (seed, char) = useSeed(seed, 48, 57); - _bytes[i] = bytes1(uint8(char)); - } else { - // special characters: _, -, !, ? - uint256 specialChar; - (seed, specialChar) = useSeed(seed, 0, 3); - if (specialChar == 0) { - _bytes[i] = bytes1(uint8(95)); // _ (underscore) - } else if (specialChar == 1) { - _bytes[i] = bytes1(uint8(45)); // - (hyphen) - } else if (specialChar == 2) { - _bytes[i] = bytes1(uint8(33)); // ! (exclamation mark) - } else { - _bytes[i] = bytes1(uint8(63)); // ? (question mark) - } - } - } - return string(_bytes); - } - - function useSeed(uint256 _seed, uint256 _min, uint256 _max) internal pure returns (uint256 seed, uint256 val) { - val = uint256(keccak256(abi.encode(_seed))); - seed = val; - val = val % (_max - _min + 1) + _min; - } - -} diff --git a/lib/signals-implicit-mode/out/Attestation.sol/LibAttestation.json b/lib/signals-implicit-mode/out/Attestation.sol/LibAttestation.json deleted file mode 100644 index 631b458e22..0000000000 --- a/lib/signals-implicit-mode/out/Attestation.sol/LibAttestation.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x60566050600b82828239805160001a6073146043577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220f60fbf7d82690b988bb6e8bb0932cdfaa2bf039d8a2674f535dd3bd81385f39664736f6c634300081c0033","sourceMap":"1023:3579:21:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220f60fbf7d82690b988bb6e8bb0932cdfaa2bf039d8a2674f535dd3bd81385f39664736f6c634300081c0033","sourceMap":"1023:3579:21:-:0;;;;;;;;","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"author\":\"Michael Standen\",\"kind\":\"dev\",\"methods\":{},\"title\":\"LibAttestation\",\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"notice\":\"Library for attestation management\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":\"LibAttestation\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":"LibAttestation"},"evmVersion":"paris","libraries":{}},"sources":{"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"}},"version":1},"id":21} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/Base.sol/CommonBase.json b/lib/signals-implicit-mode/out/Base.sol/CommonBase.json deleted file mode 100644 index 943178e2e1..0000000000 --- a/lib/signals-implicit-mode/out/Base.sol/CommonBase.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"stateVariables\":{\"CONSOLE\":{\"details\":\"console.sol and console2.sol work by executing a staticcall to this address. Calculated as `address(uint160(uint88(bytes11(\\\"console.log\\\"))))`.\"},\"CREATE2_FACTORY\":{\"details\":\"Used when deploying with create2. Taken from https://github.com/Arachnid/deterministic-deployment-proxy.\"},\"DEFAULT_SENDER\":{\"details\":\"The default address for tx.origin and msg.sender. Calculated as `address(uint160(uint256(keccak256(\\\"foundry default caller\\\"))))`.\"},\"DEFAULT_TEST_CONTRACT\":{\"details\":\"The address of the first contract `CREATE`d by a running test contract. When running tests, each test contract is `CREATE`d by `DEFAULT_SENDER` with nonce 1. Calculated as `VM.computeCreateAddress(VM.computeCreateAddress(DEFAULT_SENDER, 1), 1)`.\"},\"MULTICALL3_ADDRESS\":{\"details\":\"Deterministic deployment address of the Multicall3 contract. Taken from https://www.multicall3.com.\"},\"SECP256K1_ORDER\":{\"details\":\"The order of the secp256k1 curve.\"},\"VM_ADDRESS\":{\"details\":\"Cheat code address. Calculated as `address(uint160(uint256(keccak256(\\\"hevm cheat code\\\"))))`.\"}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/Base.sol\":\"CommonBase\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/Base.sol":"CommonBase"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"}},"version":1},"id":0} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/Base.sol/ScriptBase.json b/lib/signals-implicit-mode/out/Base.sol/ScriptBase.json deleted file mode 100644 index 02e4cd6850..0000000000 --- a/lib/signals-implicit-mode/out/Base.sol/ScriptBase.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/Base.sol\":\"ScriptBase\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/Base.sol":"ScriptBase"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"}},"version":1},"id":0} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/Base.sol/TestBase.json b/lib/signals-implicit-mode/out/Base.sol/TestBase.json deleted file mode 100644 index 04a03ae8aa..0000000000 --- a/lib/signals-implicit-mode/out/Base.sol/TestBase.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/Base.sol\":\"TestBase\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/Base.sol":"TestBase"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"}},"version":1},"id":0} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/Deploy.s.sol/Deploy.json b/lib/signals-implicit-mode/out/Deploy.s.sol/Deploy.json deleted file mode 100644 index 385366657a..0000000000 --- a/lib/signals-implicit-mode/out/Deploy.s.sol/Deploy.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"IS_SCRIPT","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"run","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"error","name":"DeploymentFailed","inputs":[{"name":"reason","type":"string","internalType":"string"}]}],"bytecode":{"object":"0x60806040526001600c60006101000a81548160ff0219169083151502179055506001600c60026101000a81548160ff021916908315150217905550348015604557600080fd5b50613624806100556000396000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c8063c04062261461003b578063f8ccbf4714610045575b600080fd5b610043610063565b005b61004d610189565b60405161005a9190610a7f565b60405180910390f35b6000737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c1978d1f6040518163ffffffff1660e01b81526004016100b090610af7565b602060405180830381865afa1580156100cd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906100f19190610b52565b905060008060001b905060006040518060200161010d90610a4d565b6020820181038252601f19601f820116604052506040516020016101319190610bf0565b60405160208183030381529060405290506101836040518060400160405280601781526020017f496d706c6963697450726f6a656374526567697374727900000000000000000081525082848661019c565b50505050565b600c60029054906101000a900460ff1681565b60006101a7826104b2565b6101b184846107da565b905060028173ffffffffffffffffffffffffffffffffffffffff163b1161046957610212856040518060400160405280600c81526020017f6465706c6f79696e6720746f000000000000000000000000000000000000000081525083610833565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ce817d47836040518263ffffffff1660e01b815260040161025f9190610c16565b600060405180830381600087803b15801561027957600080fd5b505af115801561028d573d6000803e3d6000fd5b50505050600073ce0042b868300000d44a59004da54a005ffdcf9f73ffffffffffffffffffffffffffffffffffffffff16634af63f0286866040518363ffffffff1660e01b81526004016102e2929190610ca5565b6020604051808303816000875af1158015610301573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103259190610d33565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166376eadd366040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561038357600080fd5b505af1158015610397573d6000803e3d6000fd5b505050508073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614610409576040517f20631f9100000000000000000000000000000000000000000000000000000000815260040161040090610dac565b60405180910390fd5b60028273ffffffffffffffffffffffffffffffffffffffff163b11610463576040517f20631f9100000000000000000000000000000000000000000000000000000000815260040161045a90610e18565b60405180910390fd5b506104aa565b6104a9856040518060400160405280601381526020017f616c7265616479206465706c6f79656420746f0000000000000000000000000081525083610833565b5b949350505050565b600273ce0042b868300000d44a59004da54a005ffdcf9f73ffffffffffffffffffffffffffffffffffffffff163b116107d7576657c084e5f3c00073bb6e024b9cffacb947a71991e386681b1cd1477d73ffffffffffffffffffffffffffffffffffffffff163110156106e95761055d6040518060400160405280601d81526020017f46756e64696e672053696e676c65746f6e20466163746f727920454f410000008152506108d2565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ce817d47826040518263ffffffff1660e01b81526004016105aa9190610c16565b600060405180830381600087803b1580156105c457600080fd5b505af11580156105d8573d6000803e3d6000fd5b5050505073bb6e024b9cffacb947a71991e386681b1cd1477d73ffffffffffffffffffffffffffffffffffffffff166108fc73bb6e024b9cffacb947a71991e386681b1cd1477d73ffffffffffffffffffffffffffffffffffffffff16316657c084e5f3c0006106489190610e67565b9081150290604051600060405180830381858888f19350505050158015610673573d6000803e3d6000fd5b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166376eadd366040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156106d057600080fd5b505af11580156106e4573d6000803e3d6000fd5b505050505b61073c6040518060400160405280601e81526020017f4465706c6f79696e672053696e676c65746f6e20466163746f727920746f000081525073ce0042b868300000d44a59004da54a005ffdcf9f61096b565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16638c0c72e0604051806101a0016040528061016f815260200161348061016f91396040518263ffffffff1660e01b81526004016107a49190610e9b565b600060405180830381600087803b1580156107be57600080fd5b505af11580156107d2573d6000803e3d6000fd5b505050505b50565b600060ff60f81b73ce0042b868300000d44a59004da54a005ffdcf9f8385805190602001206040516020016108129493929190610f85565b6040516020818303038152906040528051906020012060001c905092915050565b6108cd83838360405160240161084b93929190611026565b6040516020818303038152906040527f95ed0195000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610a07565b505050565b610968816040516024016108e6919061106b565b6040516020818303038152906040527f41304fac000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610a07565b50565b610a03828260405160240161098192919061108d565b6040516020818303038152906040527f319af333000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610a07565b5050565b610a1e81610a16610a21610a42565b63ffffffff16565b50565b60006a636f6e736f6c652e6c6f679050600080835160208501845afa505050565b610a5a819050919050565b612393806110ed83390190565b610a626110bd565b565b60008115159050919050565b610a7981610a64565b82525050565b6000602082019050610a946000830184610a70565b92915050565b600082825260208201905092915050565b7f505249564154455f4b4559000000000000000000000000000000000000000000600082015250565b6000610ae1600b83610a9a565b9150610aec82610aab565b602082019050919050565b60006020820190508181036000830152610b1081610ad4565b9050919050565b600080fd5b6000819050919050565b610b2f81610b1c565b8114610b3a57600080fd5b50565b600081519050610b4c81610b26565b92915050565b600060208284031215610b6857610b67610b17565b5b6000610b7684828501610b3d565b91505092915050565b600081519050919050565b600081905092915050565b60005b83811015610bb3578082015181840152602081019050610b98565b60008484015250505050565b6000610bca82610b7f565b610bd48185610b8a565b9350610be4818560208601610b95565b80840191505092915050565b6000610bfc8284610bbf565b915081905092915050565b610c1081610b1c565b82525050565b6000602082019050610c2b6000830184610c07565b92915050565b600082825260208201905092915050565b6000601f19601f8301169050919050565b6000610c5e82610b7f565b610c688185610c31565b9350610c78818560208601610b95565b610c8181610c42565b840191505092915050565b6000819050919050565b610c9f81610c8c565b82525050565b60006040820190508181036000830152610cbf8185610c53565b9050610cce6020830184610c96565b9392505050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000610d0082610cd5565b9050919050565b610d1081610cf5565b8114610d1b57600080fd5b50565b600081519050610d2d81610d07565b92915050565b600060208284031215610d4957610d48610b17565b5b6000610d5784828501610d1e565b91505092915050565b7f4465706c6f7965642061646472657373206d69736d6174636800000000000000600082015250565b6000610d96601983610a9a565b9150610da182610d60565b602082019050919050565b60006020820190508181036000830152610dc581610d89565b9050919050565b7f4465706c6f796d656e74206661696c6564000000000000000000000000000000600082015250565b6000610e02601183610a9a565b9150610e0d82610dcc565b602082019050919050565b60006020820190508181036000830152610e3181610df5565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000610e7282610b1c565b9150610e7d83610b1c565b9250828203905081811115610e9557610e94610e38565b5b92915050565b60006020820190508181036000830152610eb58184610c53565b905092915050565b60007fff0000000000000000000000000000000000000000000000000000000000000082169050919050565b6000819050919050565b610f04610eff82610ebd565b610ee9565b82525050565b6000610f1582610cd5565b9050919050565b60008160601b9050919050565b6000610f3482610f1c565b9050919050565b6000610f4682610f29565b9050919050565b610f5e610f5982610f0a565b610f3b565b82525050565b6000819050919050565b610f7f610f7a82610c8c565b610f64565b82525050565b6000610f918287610ef3565b600182019150610fa18286610f4d565b601482019150610fb18285610f6e565b602082019150610fc18284610f6e565b60208201915081905095945050505050565b600081519050919050565b6000610fe982610fd3565b610ff38185610a9a565b9350611003818560208601610b95565b61100c81610c42565b840191505092915050565b61102081610f0a565b82525050565b600060608201905081810360008301526110408186610fde565b905081810360208301526110548185610fde565b90506110636040830184611017565b949350505050565b600060208201905081810360008301526110858184610fde565b905092915050565b600060408201905081810360008301526110a78185610fde565b90506110b66020830184611017565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052605160045260246000fdfe6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c0033f9016c8085174876e8008303c4d88080b90154608060405234801561001057600080fd5b50610134806100206000396000f3fe6080604052348015600f57600080fd5b506004361060285760003560e01c80634af63f0214602d575b600080fd5b60cf60048036036040811015604157600080fd5b810190602081018135640100000000811115605b57600080fd5b820183602082011115606c57600080fd5b80359060200191846001830284011164010000000083111715608d57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550509135925060eb915050565b604080516001600160a01b039092168252519081900360200190f35b6000818351602085016000f5939250505056fea26469706673582212206b44f8a82cb6b156bfcc3dc6aadd6df4eefd204bc928a4397fd15dacf6d5320564736f6c634300060200331b83247000822470a264697066735822122039573d6272136eb3ffa400cc833234521842692d9fd573208143b2038cc54dfb64736f6c634300081c0033","sourceMap":"240:313:21:-:0;;;3200:4:2;3160:44;;;;;;;;;;;;;;;;;;;;873:4:1;849:28;;;;;;;;;;;;;;;;;;;;240:313:21;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x608060405234801561001057600080fd5b50600436106100365760003560e01c8063c04062261461003b578063f8ccbf4714610045575b600080fd5b610043610063565b005b61004d610189565b60405161005a9190610a7f565b60405180910390f35b6000737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c1978d1f6040518163ffffffff1660e01b81526004016100b090610af7565b602060405180830381865afa1580156100cd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906100f19190610b52565b905060008060001b905060006040518060200161010d90610a4d565b6020820181038252601f19601f820116604052506040516020016101319190610bf0565b60405160208183030381529060405290506101836040518060400160405280601781526020017f496d706c6963697450726f6a656374526567697374727900000000000000000081525082848661019c565b50505050565b600c60029054906101000a900460ff1681565b60006101a7826104b2565b6101b184846107da565b905060028173ffffffffffffffffffffffffffffffffffffffff163b1161046957610212856040518060400160405280600c81526020017f6465706c6f79696e6720746f000000000000000000000000000000000000000081525083610833565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ce817d47836040518263ffffffff1660e01b815260040161025f9190610c16565b600060405180830381600087803b15801561027957600080fd5b505af115801561028d573d6000803e3d6000fd5b50505050600073ce0042b868300000d44a59004da54a005ffdcf9f73ffffffffffffffffffffffffffffffffffffffff16634af63f0286866040518363ffffffff1660e01b81526004016102e2929190610ca5565b6020604051808303816000875af1158015610301573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103259190610d33565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166376eadd366040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561038357600080fd5b505af1158015610397573d6000803e3d6000fd5b505050508073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614610409576040517f20631f9100000000000000000000000000000000000000000000000000000000815260040161040090610dac565b60405180910390fd5b60028273ffffffffffffffffffffffffffffffffffffffff163b11610463576040517f20631f9100000000000000000000000000000000000000000000000000000000815260040161045a90610e18565b60405180910390fd5b506104aa565b6104a9856040518060400160405280601381526020017f616c7265616479206465706c6f79656420746f0000000000000000000000000081525083610833565b5b949350505050565b600273ce0042b868300000d44a59004da54a005ffdcf9f73ffffffffffffffffffffffffffffffffffffffff163b116107d7576657c084e5f3c00073bb6e024b9cffacb947a71991e386681b1cd1477d73ffffffffffffffffffffffffffffffffffffffff163110156106e95761055d6040518060400160405280601d81526020017f46756e64696e672053696e676c65746f6e20466163746f727920454f410000008152506108d2565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ce817d47826040518263ffffffff1660e01b81526004016105aa9190610c16565b600060405180830381600087803b1580156105c457600080fd5b505af11580156105d8573d6000803e3d6000fd5b5050505073bb6e024b9cffacb947a71991e386681b1cd1477d73ffffffffffffffffffffffffffffffffffffffff166108fc73bb6e024b9cffacb947a71991e386681b1cd1477d73ffffffffffffffffffffffffffffffffffffffff16316657c084e5f3c0006106489190610e67565b9081150290604051600060405180830381858888f19350505050158015610673573d6000803e3d6000fd5b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166376eadd366040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156106d057600080fd5b505af11580156106e4573d6000803e3d6000fd5b505050505b61073c6040518060400160405280601e81526020017f4465706c6f79696e672053696e676c65746f6e20466163746f727920746f000081525073ce0042b868300000d44a59004da54a005ffdcf9f61096b565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16638c0c72e0604051806101a0016040528061016f815260200161348061016f91396040518263ffffffff1660e01b81526004016107a49190610e9b565b600060405180830381600087803b1580156107be57600080fd5b505af11580156107d2573d6000803e3d6000fd5b505050505b50565b600060ff60f81b73ce0042b868300000d44a59004da54a005ffdcf9f8385805190602001206040516020016108129493929190610f85565b6040516020818303038152906040528051906020012060001c905092915050565b6108cd83838360405160240161084b93929190611026565b6040516020818303038152906040527f95ed0195000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610a07565b505050565b610968816040516024016108e6919061106b565b6040516020818303038152906040527f41304fac000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610a07565b50565b610a03828260405160240161098192919061108d565b6040516020818303038152906040527f319af333000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610a07565b5050565b610a1e81610a16610a21610a42565b63ffffffff16565b50565b60006a636f6e736f6c652e6c6f679050600080835160208501845afa505050565b610a5a819050919050565b612393806110ed83390190565b610a626110bd565b565b60008115159050919050565b610a7981610a64565b82525050565b6000602082019050610a946000830184610a70565b92915050565b600082825260208201905092915050565b7f505249564154455f4b4559000000000000000000000000000000000000000000600082015250565b6000610ae1600b83610a9a565b9150610aec82610aab565b602082019050919050565b60006020820190508181036000830152610b1081610ad4565b9050919050565b600080fd5b6000819050919050565b610b2f81610b1c565b8114610b3a57600080fd5b50565b600081519050610b4c81610b26565b92915050565b600060208284031215610b6857610b67610b17565b5b6000610b7684828501610b3d565b91505092915050565b600081519050919050565b600081905092915050565b60005b83811015610bb3578082015181840152602081019050610b98565b60008484015250505050565b6000610bca82610b7f565b610bd48185610b8a565b9350610be4818560208601610b95565b80840191505092915050565b6000610bfc8284610bbf565b915081905092915050565b610c1081610b1c565b82525050565b6000602082019050610c2b6000830184610c07565b92915050565b600082825260208201905092915050565b6000601f19601f8301169050919050565b6000610c5e82610b7f565b610c688185610c31565b9350610c78818560208601610b95565b610c8181610c42565b840191505092915050565b6000819050919050565b610c9f81610c8c565b82525050565b60006040820190508181036000830152610cbf8185610c53565b9050610cce6020830184610c96565b9392505050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000610d0082610cd5565b9050919050565b610d1081610cf5565b8114610d1b57600080fd5b50565b600081519050610d2d81610d07565b92915050565b600060208284031215610d4957610d48610b17565b5b6000610d5784828501610d1e565b91505092915050565b7f4465706c6f7965642061646472657373206d69736d6174636800000000000000600082015250565b6000610d96601983610a9a565b9150610da182610d60565b602082019050919050565b60006020820190508181036000830152610dc581610d89565b9050919050565b7f4465706c6f796d656e74206661696c6564000000000000000000000000000000600082015250565b6000610e02601183610a9a565b9150610e0d82610dcc565b602082019050919050565b60006020820190508181036000830152610e3181610df5565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000610e7282610b1c565b9150610e7d83610b1c565b9250828203905081811115610e9557610e94610e38565b5b92915050565b60006020820190508181036000830152610eb58184610c53565b905092915050565b60007fff0000000000000000000000000000000000000000000000000000000000000082169050919050565b6000819050919050565b610f04610eff82610ebd565b610ee9565b82525050565b6000610f1582610cd5565b9050919050565b60008160601b9050919050565b6000610f3482610f1c565b9050919050565b6000610f4682610f29565b9050919050565b610f5e610f5982610f0a565b610f3b565b82525050565b6000819050919050565b610f7f610f7a82610c8c565b610f64565b82525050565b6000610f918287610ef3565b600182019150610fa18286610f4d565b601482019150610fb18285610f6e565b602082019150610fc18284610f6e565b60208201915081905095945050505050565b600081519050919050565b6000610fe982610fd3565b610ff38185610a9a565b9350611003818560208601610b95565b61100c81610c42565b840191505092915050565b61102081610f0a565b82525050565b600060608201905081810360008301526110408186610fde565b905081810360208301526110548185610fde565b90506110636040830184611017565b949350505050565b600060208201905081810360008301526110858184610fde565b905092915050565b600060408201905081810360008301526110a78185610fde565b90506110b66020830184611017565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052605160045260246000fdfe6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c0033f9016c8085174876e8008303c4d88080b90154608060405234801561001057600080fd5b50610134806100206000396000f3fe6080604052348015600f57600080fd5b506004361060285760003560e01c80634af63f0214602d575b600080fd5b60cf60048036036040811015604157600080fd5b810190602081018135640100000000811115605b57600080fd5b820183602082011115606c57600080fd5b80359060200191846001830284011164010000000083111715608d57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550509135925060eb915050565b604080516001600160a01b039092168252519081900360200190f35b6000818351602085016000f5939250505056fea26469706673582212206b44f8a82cb6b156bfcc3dc6aadd6df4eefd204bc928a4397fd15dacf6d5320564736f6c634300060200331b83247000822470a264697066735822122039573d6272136eb3ffa400cc833234521842692d9fd573208143b2038cc54dfb64736f6c634300081c0033","sourceMap":"240:313:21:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;282:268;;;:::i;:::-;;849:28:1;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;282:268:21;312:10;336:42:0;325:10:21;;;:25;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;312:38;;357:12;380:1;372:10;;357:25;;389:21;430:42;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;413:60;;;;;;;;:::i;:::-;;;;;;;;;;;;;389:84;;479:66;;;;;;;;;;;;;;;;;;526:8;536:4;542:2;479:19;:66::i;:::-;;306:244;;;282:268::o;849:28:1:-;;;;;;;;;;;;;:::o;1191:843:15:-;1325:12;1353:39;1389:2;1353:35;:39::i;:::-;1409:37;1429:9;1440:5;1409:19;:37::i;:::-;1402:44;;1480:1;1460:4;:16;;;:21;1456:551;;1497:39;1509:4;1497:39;;;;;;;;;;;;;;;;;1531:4;1497:11;:39::i;:::-;336:42:0;1550:17:15;;;1568:2;1550:21;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1585:18;107:42:16;1606:24:15;;;1631:9;1642:5;1606:42;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;1585:63;;336:42:0;1662:16:15;;;:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1706:10;1698:18;;:4;:18;;;1694:109;;1743:45;;;;;;;;;;:::i;:::-;;;;;;;;1694:109;1840:1;1820:4;:16;;;:21;1816:104;;1868:37;;;;;;;;;;:::i;:::-;;;;;;;;1816:104;1483:447;1456:551;;;1950:46;1962:4;1950:46;;;;;;;;;;;;;;;;;1991:4;1950:11;:46::i;:::-;1456:551;1191:843;;;;;;:::o;490:695::-;608:1;107:42:16;570:34:15;;;:39;566:613;;274:12:16;189:42;629:26:15;;;:50;625:360;;;745:44;;;;;;;;;;;;;;;;;;:11;:44::i;:::-;336:42:0;807:17:15;;;825:2;807:21;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;189:42:16;846:36:15;;:88;189:42:16;907:26:15;;;274:12:16;883:50:15;;;;:::i;:::-;846:88;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;952:16:15;;;:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;625:360;1038:69;;;;;;;;;;;;;;;;;;107:42:16;1038:11:15;:69::i;:::-;336:42:0;1121:26:15;;;1148:19;;;;;;;;;;;;;;;;;1121:47;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;566:613;490:695;:::o;2040:344::-;2131:12;2271:4;2264:12;;107:42:16;2306:5:15;2323:9;2313:20;;;;;;2247:87;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;2237:98;;;;;;2208:145;;2155:222;;2040:344;;;;:::o;12983:174:11:-;13068:82;13138:2;13142;13146;13084:65;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13068:15;:82::i;:::-;12983:174;;;:::o;6191:121::-;6246:59;6301:2;6262:42;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6246:15;:59::i;:::-;6191:121;:::o;7740:145::-;7807:71;7870:2;7874;7823:54;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7807:15;:71::i;:::-;7740:145;;:::o;851:129::-;922:51;965:7;922:42;934:29;922:11;:42::i;:::-;:51;;:::i;:::-;851:129;:::o;180:463::-;265:22;131:42;265:40;;594:1;571;541:7;535:14;510:2;501:7;497:16;461:14;434:5;402:211;381:246;367:270;180:463;:::o;649:196::-;748:33;825:4;816:13;;649:196;;;:::o;-1:-1:-1:-;;;;;;;;:::o;:::-;;;:::i;:::-;:::o;7:90:25:-;41:7;84:5;77:13;70:21;59:32;;7:90;;;:::o;103:109::-;184:21;199:5;184:21;:::i;:::-;179:3;172:34;103:109;;:::o;218:210::-;305:4;343:2;332:9;328:18;320:26;;356:65;418:1;407:9;403:17;394:6;356:65;:::i;:::-;218:210;;;;:::o;434:169::-;518:11;552:6;547:3;540:19;592:4;587:3;583:14;568:29;;434:169;;;;:::o;609:161::-;749:13;745:1;737:6;733:14;726:37;609:161;:::o;776:366::-;918:3;939:67;1003:2;998:3;939:67;:::i;:::-;932:74;;1015:93;1104:3;1015:93;:::i;:::-;1133:2;1128:3;1124:12;1117:19;;776:366;;;:::o;1148:419::-;1314:4;1352:2;1341:9;1337:18;1329:26;;1401:9;1395:4;1391:20;1387:1;1376:9;1372:17;1365:47;1429:131;1555:4;1429:131;:::i;:::-;1421:139;;1148:419;;;:::o;1654:117::-;1763:1;1760;1753:12;1900:77;1937:7;1966:5;1955:16;;1900:77;;;:::o;1983:122::-;2056:24;2074:5;2056:24;:::i;:::-;2049:5;2046:35;2036:63;;2095:1;2092;2085:12;2036:63;1983:122;:::o;2111:143::-;2168:5;2199:6;2193:13;2184:22;;2215:33;2242:5;2215:33;:::i;:::-;2111:143;;;;:::o;2260:351::-;2330:6;2379:2;2367:9;2358:7;2354:23;2350:32;2347:119;;;2385:79;;:::i;:::-;2347:119;2505:1;2530:64;2586:7;2577:6;2566:9;2562:22;2530:64;:::i;:::-;2520:74;;2476:128;2260:351;;;;:::o;2617:98::-;2668:6;2702:5;2696:12;2686:22;;2617:98;;;:::o;2721:147::-;2822:11;2859:3;2844:18;;2721:147;;;;:::o;2874:248::-;2956:1;2966:113;2980:6;2977:1;2974:13;2966:113;;;3065:1;3060:3;3056:11;3050:18;3046:1;3041:3;3037:11;3030:39;3002:2;2999:1;2995:10;2990:15;;2966:113;;;3113:1;3104:6;3099:3;3095:16;3088:27;2936:186;2874:248;;;:::o;3128:386::-;3232:3;3260:38;3292:5;3260:38;:::i;:::-;3314:88;3395:6;3390:3;3314:88;:::i;:::-;3307:95;;3411:65;3469:6;3464:3;3457:4;3450:5;3446:16;3411:65;:::i;:::-;3501:6;3496:3;3492:16;3485:23;;3236:278;3128:386;;;;:::o;3520:271::-;3650:3;3672:93;3761:3;3752:6;3672:93;:::i;:::-;3665:100;;3782:3;3775:10;;3520:271;;;;:::o;3797:118::-;3884:24;3902:5;3884:24;:::i;:::-;3879:3;3872:37;3797:118;;:::o;3921:222::-;4014:4;4052:2;4041:9;4037:18;4029:26;;4065:71;4133:1;4122:9;4118:17;4109:6;4065:71;:::i;:::-;3921:222;;;;:::o;4149:168::-;4232:11;4266:6;4261:3;4254:19;4306:4;4301:3;4297:14;4282:29;;4149:168;;;;:::o;4323:102::-;4364:6;4415:2;4411:7;4406:2;4399:5;4395:14;4391:28;4381:38;;4323:102;;;:::o;4431:373::-;4517:3;4545:38;4577:5;4545:38;:::i;:::-;4599:70;4662:6;4657:3;4599:70;:::i;:::-;4592:77;;4678:65;4736:6;4731:3;4724:4;4717:5;4713:16;4678:65;:::i;:::-;4768:29;4790:6;4768:29;:::i;:::-;4763:3;4759:39;4752:46;;4521:283;4431:373;;;;:::o;4810:77::-;4847:7;4876:5;4865:16;;4810:77;;;:::o;4893:118::-;4980:24;4998:5;4980:24;:::i;:::-;4975:3;4968:37;4893:118;;:::o;5017:419::-;5156:4;5194:2;5183:9;5179:18;5171:26;;5243:9;5237:4;5233:20;5229:1;5218:9;5214:17;5207:47;5271:76;5342:4;5333:6;5271:76;:::i;:::-;5263:84;;5357:72;5425:2;5414:9;5410:18;5401:6;5357:72;:::i;:::-;5017:419;;;;;:::o;5442:126::-;5479:7;5519:42;5512:5;5508:54;5497:65;;5442:126;;;:::o;5574:104::-;5619:7;5648:24;5666:5;5648:24;:::i;:::-;5637:35;;5574:104;;;:::o;5684:138::-;5765:32;5791:5;5765:32;:::i;:::-;5758:5;5755:43;5745:71;;5812:1;5809;5802:12;5745:71;5684:138;:::o;5828:159::-;5893:5;5924:6;5918:13;5909:22;;5940:41;5975:5;5940:41;:::i;:::-;5828:159;;;;:::o;5993:367::-;6071:6;6120:2;6108:9;6099:7;6095:23;6091:32;6088:119;;;6126:79;;:::i;:::-;6088:119;6246:1;6271:72;6335:7;6326:6;6315:9;6311:22;6271:72;:::i;:::-;6261:82;;6217:136;5993:367;;;;:::o;6366:175::-;6506:27;6502:1;6494:6;6490:14;6483:51;6366:175;:::o;6547:366::-;6689:3;6710:67;6774:2;6769:3;6710:67;:::i;:::-;6703:74;;6786:93;6875:3;6786:93;:::i;:::-;6904:2;6899:3;6895:12;6888:19;;6547:366;;;:::o;6919:419::-;7085:4;7123:2;7112:9;7108:18;7100:26;;7172:9;7166:4;7162:20;7158:1;7147:9;7143:17;7136:47;7200:131;7326:4;7200:131;:::i;:::-;7192:139;;6919:419;;;:::o;7344:167::-;7484:19;7480:1;7472:6;7468:14;7461:43;7344:167;:::o;7517:366::-;7659:3;7680:67;7744:2;7739:3;7680:67;:::i;:::-;7673:74;;7756:93;7845:3;7756:93;:::i;:::-;7874:2;7869:3;7865:12;7858:19;;7517:366;;;:::o;7889:419::-;8055:4;8093:2;8082:9;8078:18;8070:26;;8142:9;8136:4;8132:20;8128:1;8117:9;8113:17;8106:47;8170:131;8296:4;8170:131;:::i;:::-;8162:139;;7889:419;;;:::o;8314:180::-;8362:77;8359:1;8352:88;8459:4;8456:1;8449:15;8483:4;8480:1;8473:15;8500:194;8540:4;8560:20;8578:1;8560:20;:::i;:::-;8555:25;;8594:20;8612:1;8594:20;:::i;:::-;8589:25;;8638:1;8635;8631:9;8623:17;;8662:1;8656:4;8653:11;8650:37;;;8667:18;;:::i;:::-;8650:37;8500:194;;;;:::o;8700:309::-;8811:4;8849:2;8838:9;8834:18;8826:26;;8898:9;8892:4;8888:20;8884:1;8873:9;8869:17;8862:47;8926:76;8997:4;8988:6;8926:76;:::i;:::-;8918:84;;8700:309;;;;:::o;9015:149::-;9051:7;9091:66;9084:5;9080:78;9069:89;;9015:149;;;:::o;9170:78::-;9208:7;9237:5;9226:16;;9170:78;;;:::o;9254:153::-;9357:43;9376:23;9393:5;9376:23;:::i;:::-;9357:43;:::i;:::-;9352:3;9345:56;9254:153;;:::o;9413:96::-;9450:7;9479:24;9497:5;9479:24;:::i;:::-;9468:35;;9413:96;;;:::o;9515:94::-;9548:8;9596:5;9592:2;9588:14;9567:35;;9515:94;;;:::o;9615:::-;9654:7;9683:20;9697:5;9683:20;:::i;:::-;9672:31;;9615:94;;;:::o;9715:100::-;9754:7;9783:26;9803:5;9783:26;:::i;:::-;9772:37;;9715:100;;;:::o;9821:157::-;9926:45;9946:24;9964:5;9946:24;:::i;:::-;9926:45;:::i;:::-;9921:3;9914:58;9821:157;;:::o;9984:79::-;10023:7;10052:5;10041:16;;9984:79;;;:::o;10069:157::-;10174:45;10194:24;10212:5;10194:24;:::i;:::-;10174:45;:::i;:::-;10169:3;10162:58;10069:157;;:::o;10232:674::-;10426:3;10441:73;10510:3;10501:6;10441:73;:::i;:::-;10539:1;10534:3;10530:11;10523:18;;10551:75;10622:3;10613:6;10551:75;:::i;:::-;10651:2;10646:3;10642:12;10635:19;;10664:75;10735:3;10726:6;10664:75;:::i;:::-;10764:2;10759:3;10755:12;10748:19;;10777:75;10848:3;10839:6;10777:75;:::i;:::-;10877:2;10872:3;10868:12;10861:19;;10897:3;10890:10;;10232:674;;;;;;;:::o;10912:99::-;10964:6;10998:5;10992:12;10982:22;;10912:99;;;:::o;11017:377::-;11105:3;11133:39;11166:5;11133:39;:::i;:::-;11188:71;11252:6;11247:3;11188:71;:::i;:::-;11181:78;;11268:65;11326:6;11321:3;11314:4;11307:5;11303:16;11268:65;:::i;:::-;11358:29;11380:6;11358:29;:::i;:::-;11353:3;11349:39;11342:46;;11109:285;11017:377;;;;:::o;11400:118::-;11487:24;11505:5;11487:24;:::i;:::-;11482:3;11475:37;11400:118;;:::o;11524:624::-;11713:4;11751:2;11740:9;11736:18;11728:26;;11800:9;11794:4;11790:20;11786:1;11775:9;11771:17;11764:47;11828:78;11901:4;11892:6;11828:78;:::i;:::-;11820:86;;11953:9;11947:4;11943:20;11938:2;11927:9;11923:18;11916:48;11981:78;12054:4;12045:6;11981:78;:::i;:::-;11973:86;;12069:72;12137:2;12126:9;12122:18;12113:6;12069:72;:::i;:::-;11524:624;;;;;;:::o;12154:313::-;12267:4;12305:2;12294:9;12290:18;12282:26;;12354:9;12348:4;12344:20;12340:1;12329:9;12325:17;12318:47;12382:78;12455:4;12446:6;12382:78;:::i;:::-;12374:86;;12154:313;;;;:::o;12473:423::-;12614:4;12652:2;12641:9;12637:18;12629:26;;12701:9;12695:4;12691:20;12687:1;12676:9;12672:17;12665:47;12729:78;12802:4;12793:6;12729:78;:::i;:::-;12721:86;;12817:72;12885:2;12874:9;12870:18;12861:6;12817:72;:::i;:::-;12473:423;;;;;:::o;12902:180::-;12950:77;12947:1;12940:88;13047:4;13044:1;13037:15;13071:4;13068:1;13061:15","linkReferences":{}},"methodIdentifiers":{"IS_SCRIPT()":"f8ccbf47","run()":"c0406226"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\"}],\"name\":\"DeploymentFailed\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IS_SCRIPT\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"run\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"script/Deploy.s.sol\":\"Deploy\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/Script.sol\":{\"keccak256\":\"0xc942e27c7baae499beb01afbbae99f24d42af9a6e4aae675bc6901b704aa8e9b\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://0456008adf68947247f358b62863af4a8e349549d2260f2ff9569ff0e3cf5c98\",\"dweb:/ipfs/QmdviSUj2i7o3TPN5vd2xocqGMFVqjUzaiJTZRYyPxyHPx\"]},\"lib/forge-std/src/StdChains.sol\":{\"keccak256\":\"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2\",\"dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe\"]},\"lib/forge-std/src/StdCheats.sol\":{\"keccak256\":\"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41\",\"dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK\"]},\"lib/forge-std/src/StdConstants.sol\":{\"keccak256\":\"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc\",\"dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r\"]},\"lib/forge-std/src/StdJson.sol\":{\"keccak256\":\"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974\",\"dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3\"]},\"lib/forge-std/src/StdMath.sol\":{\"keccak256\":\"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92\",\"dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/StdStyle.sol\":{\"keccak256\":\"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8\",\"dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK\"]},\"lib/forge-std/src/StdUtils.sol\":{\"keccak256\":\"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a\",\"dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]},\"lib/forge-std/src/console2.sol\":{\"keccak256\":\"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d\",\"dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ\"]},\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]},\"lib/forge-std/src/safeconsole.sol\":{\"keccak256\":\"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab\",\"dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3\"]},\"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol\":{\"keccak256\":\"0x3fdec03d51d77fcda6d6c681e26e7c8d4b85f1457eac91e0ec15411a7ab1e1f6\",\"license\":\"UNLICENSED\",\"urls\":[\"bzz-raw://a690bf4481a37f3f77acdeecac089462db83f0437307610981b24c04b5202f6e\",\"dweb:/ipfs/QmUA9TSjAkqefNBW8BiRqg8XDJiJxJPxSsZHQwJJAbrYQg\"]},\"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol\":{\"keccak256\":\"0x0a17871e1017f36a664b877f5b0db297dc998fdf8b0ab82d00ca50d5bdde88f7\",\"license\":\"UNLICENSED\",\"urls\":[\"bzz-raw://160bc0d890492792f85dfea939160290d90562b27154f64c39c2a615243518a6\",\"dweb:/ipfs/QmbxmqPpTAH7X45G75UjmLh3RSTDj7trMtmkGU6RXmRyEJ\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]},\"script/Deploy.s.sol\":{\"keccak256\":\"0x98a1df98ded339567cb5180cf6da767224b46aab3c5322a25bb157c506c30a18\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://1ee75bbe1b28e5a5736efc5142a1102fb5b0b324d44c45733ac01bdff2168f0e\",\"dweb:/ipfs/QmcYTg4n8mxVdNrUPf4xGrCSRq11QRE6gRNSx838DSzrWA\"]},\"src/registry/IImplicitProjectRegistry.sol\":{\"keccak256\":\"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de\",\"dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6\"]},\"src/registry/IImplicitProjectValidation.sol\":{\"keccak256\":\"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c\",\"dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6\"]},\"src/registry/ImplicitProjectRegistry.sol\":{\"keccak256\":\"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa\",\"dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"string","name":"reason","type":"string"}],"type":"error","name":"DeploymentFailed"},{"inputs":[],"stateMutability":"view","type":"function","name":"IS_SCRIPT","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"run"}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"script/Deploy.s.sol":"Deploy"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/Script.sol":{"keccak256":"0xc942e27c7baae499beb01afbbae99f24d42af9a6e4aae675bc6901b704aa8e9b","urls":["bzz-raw://0456008adf68947247f358b62863af4a8e349549d2260f2ff9569ff0e3cf5c98","dweb:/ipfs/QmdviSUj2i7o3TPN5vd2xocqGMFVqjUzaiJTZRYyPxyHPx"],"license":"MIT"},"lib/forge-std/src/StdChains.sol":{"keccak256":"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa","urls":["bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2","dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe"],"license":"MIT"},"lib/forge-std/src/StdCheats.sol":{"keccak256":"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746","urls":["bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41","dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK"],"license":"MIT"},"lib/forge-std/src/StdConstants.sol":{"keccak256":"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534","urls":["bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc","dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r"],"license":"MIT"},"lib/forge-std/src/StdJson.sol":{"keccak256":"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500","urls":["bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974","dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3"],"license":"MIT"},"lib/forge-std/src/StdMath.sol":{"keccak256":"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2","urls":["bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92","dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/StdStyle.sol":{"keccak256":"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d","urls":["bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8","dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK"],"license":"MIT"},"lib/forge-std/src/StdUtils.sol":{"keccak256":"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8","urls":["bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a","dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"},"lib/forge-std/src/console2.sol":{"keccak256":"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f","urls":["bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d","dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ"],"license":"MIT"},"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"},"lib/forge-std/src/safeconsole.sol":{"keccak256":"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11","urls":["bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab","dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3"],"license":"MIT"},"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol":{"keccak256":"0x3fdec03d51d77fcda6d6c681e26e7c8d4b85f1457eac91e0ec15411a7ab1e1f6","urls":["bzz-raw://a690bf4481a37f3f77acdeecac089462db83f0437307610981b24c04b5202f6e","dweb:/ipfs/QmUA9TSjAkqefNBW8BiRqg8XDJiJxJPxSsZHQwJJAbrYQg"],"license":"UNLICENSED"},"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol":{"keccak256":"0x0a17871e1017f36a664b877f5b0db297dc998fdf8b0ab82d00ca50d5bdde88f7","urls":["bzz-raw://160bc0d890492792f85dfea939160290d90562b27154f64c39c2a615243518a6","dweb:/ipfs/QmbxmqPpTAH7X45G75UjmLh3RSTDj7trMtmkGU6RXmRyEJ"],"license":"UNLICENSED"},"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"},"script/Deploy.s.sol":{"keccak256":"0x98a1df98ded339567cb5180cf6da767224b46aab3c5322a25bb157c506c30a18","urls":["bzz-raw://1ee75bbe1b28e5a5736efc5142a1102fb5b0b324d44c45733ac01bdff2168f0e","dweb:/ipfs/QmcYTg4n8mxVdNrUPf4xGrCSRq11QRE6gRNSx838DSzrWA"],"license":"Apache-2.0"},"src/registry/IImplicitProjectRegistry.sol":{"keccak256":"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf","urls":["bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de","dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6"],"license":"Apache-2.0"},"src/registry/IImplicitProjectValidation.sol":{"keccak256":"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2","urls":["bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c","dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6"],"license":"Apache-2.0"},"src/registry/ImplicitProjectRegistry.sol":{"keccak256":"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d","urls":["bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa","dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8"],"license":"Apache-2.0"}},"version":1},"id":21} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/Deploy.s.sol/VmContractHelper29.json b/lib/signals-implicit-mode/out/Deploy.s.sol/VmContractHelper29.json deleted file mode 100644 index 96c466ef9b..0000000000 --- a/lib/signals-implicit-mode/out/Deploy.s.sol/VmContractHelper29.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_value","type":"uint256","internalType":"uint256"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_args","type":"bytes","internalType":"bytes"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_args","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_args","type":"bytes","internalType":"bytes"},{"name":"_value","type":"uint256","internalType":"uint256"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_args","type":"bytes","internalType":"bytes"},{"name":"_value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"getCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"deployCode(string)":"9a8325a0","deployCode(string,bytes)":"29ce9dde","deployCode(string,bytes,bytes32)":"016155bf","deployCode(string,bytes,uint256)":"ff5d64e4","deployCode(string,bytes,uint256,bytes32)":"3aa773ea","deployCode(string,bytes32)":"17ab1d79","deployCode(string,uint256)":"0af6a701","deployCode(string,uint256,bytes32)":"002cb687","getCode(string)":"8d1cc925"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"_args\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"_args\",\"type\":\"bytes\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"_args\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"_args\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"}],\"name\":\"getCode\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"script/Deploy.s.sol\":\"VmContractHelper29\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/Script.sol\":{\"keccak256\":\"0xc942e27c7baae499beb01afbbae99f24d42af9a6e4aae675bc6901b704aa8e9b\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://0456008adf68947247f358b62863af4a8e349549d2260f2ff9569ff0e3cf5c98\",\"dweb:/ipfs/QmdviSUj2i7o3TPN5vd2xocqGMFVqjUzaiJTZRYyPxyHPx\"]},\"lib/forge-std/src/StdChains.sol\":{\"keccak256\":\"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2\",\"dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe\"]},\"lib/forge-std/src/StdCheats.sol\":{\"keccak256\":\"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41\",\"dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK\"]},\"lib/forge-std/src/StdConstants.sol\":{\"keccak256\":\"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc\",\"dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r\"]},\"lib/forge-std/src/StdJson.sol\":{\"keccak256\":\"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974\",\"dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3\"]},\"lib/forge-std/src/StdMath.sol\":{\"keccak256\":\"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92\",\"dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/StdStyle.sol\":{\"keccak256\":\"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8\",\"dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK\"]},\"lib/forge-std/src/StdUtils.sol\":{\"keccak256\":\"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a\",\"dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]},\"lib/forge-std/src/console2.sol\":{\"keccak256\":\"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d\",\"dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ\"]},\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]},\"lib/forge-std/src/safeconsole.sol\":{\"keccak256\":\"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab\",\"dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3\"]},\"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol\":{\"keccak256\":\"0x3fdec03d51d77fcda6d6c681e26e7c8d4b85f1457eac91e0ec15411a7ab1e1f6\",\"license\":\"UNLICENSED\",\"urls\":[\"bzz-raw://a690bf4481a37f3f77acdeecac089462db83f0437307610981b24c04b5202f6e\",\"dweb:/ipfs/QmUA9TSjAkqefNBW8BiRqg8XDJiJxJPxSsZHQwJJAbrYQg\"]},\"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol\":{\"keccak256\":\"0x0a17871e1017f36a664b877f5b0db297dc998fdf8b0ab82d00ca50d5bdde88f7\",\"license\":\"UNLICENSED\",\"urls\":[\"bzz-raw://160bc0d890492792f85dfea939160290d90562b27154f64c39c2a615243518a6\",\"dweb:/ipfs/QmbxmqPpTAH7X45G75UjmLh3RSTDj7trMtmkGU6RXmRyEJ\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]},\"script/Deploy.s.sol\":{\"keccak256\":\"0xba9906e83eac0f8978d32793160efd51f16bb9b552cd1837462d3f47c4af07f8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://86ac4e9b0c8c6da3dad2e379761b2fa5652890f59d781efd55a215b61d648fdb\",\"dweb:/ipfs/QmQ2JjwsAa79NsD2GjyFgAjTGJgDGf88sfnXL6Cm7C5RU2\"]},\"src/registry/IImplicitProjectRegistry.sol\":{\"keccak256\":\"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de\",\"dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6\"]},\"src/registry/IImplicitProjectValidation.sol\":{\"keccak256\":\"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c\",\"dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6\"]},\"src/registry/ImplicitProjectRegistry.sol\":{\"keccak256\":\"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa\",\"dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"uint256","name":"_value","type":"uint256"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes","name":"_args","type":"bytes"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"uint256","name":"_value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes","name":"_args","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes","name":"_args","type":"bytes"},{"internalType":"uint256","name":"_value","type":"uint256"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes","name":"_args","type":"bytes"},{"internalType":"uint256","name":"_value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"}],"stateMutability":"view","type":"function","name":"getCode","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"script/Deploy.s.sol":"VmContractHelper29"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/Script.sol":{"keccak256":"0xc942e27c7baae499beb01afbbae99f24d42af9a6e4aae675bc6901b704aa8e9b","urls":["bzz-raw://0456008adf68947247f358b62863af4a8e349549d2260f2ff9569ff0e3cf5c98","dweb:/ipfs/QmdviSUj2i7o3TPN5vd2xocqGMFVqjUzaiJTZRYyPxyHPx"],"license":"MIT"},"lib/forge-std/src/StdChains.sol":{"keccak256":"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa","urls":["bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2","dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe"],"license":"MIT"},"lib/forge-std/src/StdCheats.sol":{"keccak256":"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746","urls":["bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41","dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK"],"license":"MIT"},"lib/forge-std/src/StdConstants.sol":{"keccak256":"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534","urls":["bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc","dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r"],"license":"MIT"},"lib/forge-std/src/StdJson.sol":{"keccak256":"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500","urls":["bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974","dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3"],"license":"MIT"},"lib/forge-std/src/StdMath.sol":{"keccak256":"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2","urls":["bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92","dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/StdStyle.sol":{"keccak256":"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d","urls":["bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8","dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK"],"license":"MIT"},"lib/forge-std/src/StdUtils.sol":{"keccak256":"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8","urls":["bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a","dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"},"lib/forge-std/src/console2.sol":{"keccak256":"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f","urls":["bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d","dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ"],"license":"MIT"},"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"},"lib/forge-std/src/safeconsole.sol":{"keccak256":"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11","urls":["bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab","dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3"],"license":"MIT"},"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol":{"keccak256":"0x3fdec03d51d77fcda6d6c681e26e7c8d4b85f1457eac91e0ec15411a7ab1e1f6","urls":["bzz-raw://a690bf4481a37f3f77acdeecac089462db83f0437307610981b24c04b5202f6e","dweb:/ipfs/QmUA9TSjAkqefNBW8BiRqg8XDJiJxJPxSsZHQwJJAbrYQg"],"license":"UNLICENSED"},"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol":{"keccak256":"0x0a17871e1017f36a664b877f5b0db297dc998fdf8b0ab82d00ca50d5bdde88f7","urls":["bzz-raw://160bc0d890492792f85dfea939160290d90562b27154f64c39c2a615243518a6","dweb:/ipfs/QmbxmqPpTAH7X45G75UjmLh3RSTDj7trMtmkGU6RXmRyEJ"],"license":"UNLICENSED"},"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"},"script/Deploy.s.sol":{"keccak256":"0xba9906e83eac0f8978d32793160efd51f16bb9b552cd1837462d3f47c4af07f8","urls":["bzz-raw://86ac4e9b0c8c6da3dad2e379761b2fa5652890f59d781efd55a215b61d648fdb","dweb:/ipfs/QmQ2JjwsAa79NsD2GjyFgAjTGJgDGf88sfnXL6Cm7C5RU2"],"license":"Apache-2.0"},"src/registry/IImplicitProjectRegistry.sol":{"keccak256":"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf","urls":["bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de","dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6"],"license":"Apache-2.0"},"src/registry/IImplicitProjectValidation.sol":{"keccak256":"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2","urls":["bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c","dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6"],"license":"Apache-2.0"},"src/registry/ImplicitProjectRegistry.sol":{"keccak256":"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d","urls":["bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa","dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8"],"license":"Apache-2.0"}},"version":1},"id":28} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/ERC165.sol/ERC165.json b/lib/signals-implicit-mode/out/ERC165.sol/ERC165.json deleted file mode 100644 index 82594a96e3..0000000000 --- a/lib/signals-implicit-mode/out/ERC165.sol/ERC165.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"supportsInterface","inputs":[{"name":"interfaceId","type":"bytes4","internalType":"bytes4"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"supportsInterface(bytes4)":"01ffc9a7"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"details\":\"Implementation of the {IERC165} interface. Contracts that want to implement ERC-165 should inherit from this contract and override {supportsInterface} to check for the additional interface id that will be supported. For example: ```solidity function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); } ```\",\"kind\":\"dev\",\"methods\":{\"supportsInterface(bytes4)\":{\"details\":\"See {IERC165-supportsInterface}.\"}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol\":\"ERC165\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol\":{\"keccak256\":\"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287\",\"dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p\"]},\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol\":{\"keccak256\":\"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621\",\"dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"stateMutability":"view","type":"function","name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}]}],"devdoc":{"kind":"dev","methods":{"supportsInterface(bytes4)":{"details":"See {IERC165-supportsInterface}."}},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol":"ERC165"},"evmVersion":"paris","libraries":{}},"sources":{"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol":{"keccak256":"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa","urls":["bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287","dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p"],"license":"MIT"},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol":{"keccak256":"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8","urls":["bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621","dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL"],"license":"MIT"}},"version":1},"id":19} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/IERC165.sol/IERC165.json b/lib/signals-implicit-mode/out/IERC165.sol/IERC165.json deleted file mode 100644 index 398ec14a24..0000000000 --- a/lib/signals-implicit-mode/out/IERC165.sol/IERC165.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"supportsInterface","inputs":[{"name":"interfaceId","type":"bytes4","internalType":"bytes4"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"supportsInterface(bytes4)":"01ffc9a7"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"details\":\"Interface of the ERC-165 standard, as defined in the https://eips.ethereum.org/EIPS/eip-165[ERC]. Implementers can declare support of contract interfaces, which can then be queried by others ({ERC165Checker}). For an implementation, see {ERC165}.\",\"kind\":\"dev\",\"methods\":{\"supportsInterface(bytes4)\":{\"details\":\"Returns true if this contract implements the interface defined by `interfaceId`. See the corresponding https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[ERC section] to learn more about how these ids are created. This function call must use less than 30 000 gas.\"}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol\":\"IERC165\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol\":{\"keccak256\":\"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621\",\"dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"stateMutability":"view","type":"function","name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}]}],"devdoc":{"kind":"dev","methods":{"supportsInterface(bytes4)":{"details":"Returns true if this contract implements the interface defined by `interfaceId`. See the corresponding https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[ERC section] to learn more about how these ids are created. This function call must use less than 30 000 gas."}},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol":"IERC165"},"evmVersion":"paris","libraries":{}},"sources":{"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol":{"keccak256":"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8","urls":["bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621","dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL"],"license":"MIT"}},"version":1},"id":20} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/IImplicitProjectRegistry.sol/IImplicitProjectRegistry.json b/lib/signals-implicit-mode/out/IImplicitProjectRegistry.sol/IImplicitProjectRegistry.json deleted file mode 100644 index b8f630de02..0000000000 --- a/lib/signals-implicit-mode/out/IImplicitProjectRegistry.sol/IImplicitProjectRegistry.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"addProjectUrl","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"},{"name":"projectUrl","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"claimProject","inputs":[{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"}],"outputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"}],"stateMutability":"nonpayable"},{"type":"function","name":"listProjectUrls","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"view"},{"type":"function","name":"removeProjectUrl","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"},{"name":"projectUrl","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"transferProject","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"},{"name":"newOwner","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"validateAttestation","inputs":[{"name":"wallet","type":"address","internalType":"address"},{"name":"attestation","type":"tuple","internalType":"struct Attestation","components":[{"name":"approvedSigner","type":"address","internalType":"address"},{"name":"identityType","type":"bytes4","internalType":"bytes4"},{"name":"issuerHash","type":"bytes32","internalType":"bytes32"},{"name":"audienceHash","type":"bytes32","internalType":"bytes32"},{"name":"applicationData","type":"bytes","internalType":"bytes"},{"name":"authData","type":"tuple","internalType":"struct AuthData","components":[{"name":"redirectUrl","type":"string","internalType":"string"},{"name":"issuedAt","type":"uint64","internalType":"uint64"}]}]},{"name":"projectId","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"event","name":"ProjectClaimed","inputs":[{"name":"projectId","type":"bytes32","indexed":true,"internalType":"bytes32"},{"name":"owner","type":"address","indexed":true,"internalType":"address"}],"anonymous":false},{"type":"event","name":"ProjectOwnerTransferred","inputs":[{"name":"projectId","type":"bytes32","indexed":true,"internalType":"bytes32"},{"name":"newOwner","type":"address","indexed":true,"internalType":"address"}],"anonymous":false},{"type":"event","name":"ProjectUrlAdded","inputs":[{"name":"projectId","type":"bytes32","indexed":true,"internalType":"bytes32"},{"name":"urlHash","type":"bytes32","indexed":true,"internalType":"bytes32"}],"anonymous":false},{"type":"event","name":"ProjectUrlRemoved","inputs":[{"name":"projectId","type":"bytes32","indexed":true,"internalType":"bytes32"},{"name":"urlHash","type":"bytes32","indexed":true,"internalType":"bytes32"}],"anonymous":false},{"type":"error","name":"InvalidProjectOwner","inputs":[]},{"type":"error","name":"InvalidProjectUrlIndex","inputs":[]},{"type":"error","name":"InvalidRedirectUrl","inputs":[]},{"type":"error","name":"NotProjectOwner","inputs":[]},{"type":"error","name":"ProjectAlreadyClaimed","inputs":[]},{"type":"error","name":"ProjectUrlAlreadyExists","inputs":[]},{"type":"error","name":"ProjectUrlNotFound","inputs":[]}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"addProjectUrl(bytes32,string)":"2f28c69d","claimProject(bytes12)":"d4df1018","listProjectUrls(bytes32)":"f4364de6","removeProjectUrl(bytes32,string)":"dac6c587","transferProject(bytes32,address)":"9630aff8","validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)":"3808a90b"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"name\":\"InvalidProjectOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProjectUrlIndex\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRedirectUrl\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotProjectOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProjectAlreadyClaimed\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProjectUrlAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProjectUrlNotFound\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"ProjectClaimed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"ProjectOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"urlHash\",\"type\":\"bytes32\"}],\"name\":\"ProjectUrlAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"urlHash\",\"type\":\"bytes32\"}],\"name\":\"ProjectUrlRemoved\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"internalType\":\"string\",\"name\":\"projectUrl\",\"type\":\"string\"}],\"name\":\"addProjectUrl\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"}],\"name\":\"claimProject\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"}],\"name\":\"listProjectUrls\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"internalType\":\"string\",\"name\":\"projectUrl\",\"type\":\"string\"}],\"name\":\"removeProjectUrl\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferProject\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"wallet\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"approvedSigner\",\"type\":\"address\"},{\"internalType\":\"bytes4\",\"name\":\"identityType\",\"type\":\"bytes4\"},{\"internalType\":\"bytes32\",\"name\":\"issuerHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"audienceHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"applicationData\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"string\",\"name\":\"redirectUrl\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"issuedAt\",\"type\":\"uint64\"}],\"internalType\":\"struct AuthData\",\"name\":\"authData\",\"type\":\"tuple\"}],\"internalType\":\"struct Attestation\",\"name\":\"attestation\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"}],\"name\":\"validateAttestation\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"author\":\"Michael Standen\",\"kind\":\"dev\",\"methods\":{\"addProjectUrl(bytes32,string)\":{\"params\":{\"projectId\":\"The project id\",\"projectUrl\":\"The project URL\"}},\"claimProject(bytes12)\":{\"params\":{\"projectIdUpper\":\"The project id upper\"},\"returns\":{\"projectId\":\"The concatenation of the `projectIdUpper` and the `msg.sender`\"}},\"listProjectUrls(bytes32)\":{\"params\":{\"projectId\":\"The project id\"},\"returns\":{\"_0\":\"projectUrls The project URLs\"}},\"removeProjectUrl(bytes32,string)\":{\"params\":{\"projectId\":\"The project id\",\"projectUrl\":\"The project URL\"}},\"transferProject(bytes32,address)\":{\"params\":{\"newOwner\":\"The new owner\",\"projectId\":\"The project id\"}},\"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)\":{\"params\":{\"attestation\":\"The attestation\",\"projectId\":\"The project id\",\"wallet\":\"The wallet address\"},\"returns\":{\"_0\":\"magic The attestation magic bytes for the wallet address\"}}},\"title\":\"IImplicitProjectRegistry\",\"version\":1},\"userdoc\":{\"errors\":{\"InvalidProjectOwner()\":[{\"notice\":\"Invalid project owner error\"}],\"InvalidProjectUrlIndex()\":[{\"notice\":\"Invalid project URL index error\"}],\"InvalidRedirectUrl()\":[{\"notice\":\"Invalid redirect url error\"}],\"NotProjectOwner()\":[{\"notice\":\"Not project owner error\"}],\"ProjectAlreadyClaimed()\":[{\"notice\":\"Project already claimed error\"}],\"ProjectUrlAlreadyExists()\":[{\"notice\":\"Project URL already exists error\"}],\"ProjectUrlNotFound()\":[{\"notice\":\"Project URL not found error\"}]},\"events\":{\"ProjectClaimed(bytes32,address)\":{\"notice\":\"Emitted when a project is claimed\"},\"ProjectOwnerTransferred(bytes32,address)\":{\"notice\":\"Emitted when a project owner is transferred\"},\"ProjectUrlAdded(bytes32,bytes32)\":{\"notice\":\"Emitted when a project URL is added\"},\"ProjectUrlRemoved(bytes32,bytes32)\":{\"notice\":\"Emitted when a project URL is removed\"}},\"kind\":\"user\",\"methods\":{\"addProjectUrl(bytes32,string)\":{\"notice\":\"Add a project URL\"},\"claimProject(bytes12)\":{\"notice\":\"Claim a project\"},\"listProjectUrls(bytes32)\":{\"notice\":\"List project URLs\"},\"removeProjectUrl(bytes32,string)\":{\"notice\":\"Remove a project URL\"},\"transferProject(bytes32,address)\":{\"notice\":\"Transfer a project\"},\"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)\":{\"notice\":\"Check if a project has a code\"}},\"notice\":\"Interface for the registry of projects supporting implicit sessions\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"src/registry/IImplicitProjectRegistry.sol\":\"IImplicitProjectRegistry\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]},\"src/registry/IImplicitProjectRegistry.sol\":{\"keccak256\":\"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de\",\"dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6\"]},\"src/registry/IImplicitProjectValidation.sol\":{\"keccak256\":\"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c\",\"dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[],"type":"error","name":"InvalidProjectOwner"},{"inputs":[],"type":"error","name":"InvalidProjectUrlIndex"},{"inputs":[],"type":"error","name":"InvalidRedirectUrl"},{"inputs":[],"type":"error","name":"NotProjectOwner"},{"inputs":[],"type":"error","name":"ProjectAlreadyClaimed"},{"inputs":[],"type":"error","name":"ProjectUrlAlreadyExists"},{"inputs":[],"type":"error","name":"ProjectUrlNotFound"},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32","indexed":true},{"internalType":"address","name":"owner","type":"address","indexed":true}],"type":"event","name":"ProjectClaimed","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32","indexed":true},{"internalType":"address","name":"newOwner","type":"address","indexed":true}],"type":"event","name":"ProjectOwnerTransferred","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32","indexed":true},{"internalType":"bytes32","name":"urlHash","type":"bytes32","indexed":true}],"type":"event","name":"ProjectUrlAdded","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32","indexed":true},{"internalType":"bytes32","name":"urlHash","type":"bytes32","indexed":true}],"type":"event","name":"ProjectUrlRemoved","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"},{"internalType":"string","name":"projectUrl","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"addProjectUrl"},{"inputs":[{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"}],"stateMutability":"nonpayable","type":"function","name":"claimProject","outputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"}]},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"}],"stateMutability":"view","type":"function","name":"listProjectUrls","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}]},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"},{"internalType":"string","name":"projectUrl","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"removeProjectUrl"},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"},{"internalType":"address","name":"newOwner","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"transferProject"},{"inputs":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"struct Attestation","name":"attestation","type":"tuple","components":[{"internalType":"address","name":"approvedSigner","type":"address"},{"internalType":"bytes4","name":"identityType","type":"bytes4"},{"internalType":"bytes32","name":"issuerHash","type":"bytes32"},{"internalType":"bytes32","name":"audienceHash","type":"bytes32"},{"internalType":"bytes","name":"applicationData","type":"bytes"},{"internalType":"struct AuthData","name":"authData","type":"tuple","components":[{"internalType":"string","name":"redirectUrl","type":"string"},{"internalType":"uint64","name":"issuedAt","type":"uint64"}]}]},{"internalType":"bytes32","name":"projectId","type":"bytes32"}],"stateMutability":"view","type":"function","name":"validateAttestation","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}]}],"devdoc":{"kind":"dev","methods":{"addProjectUrl(bytes32,string)":{"params":{"projectId":"The project id","projectUrl":"The project URL"}},"claimProject(bytes12)":{"params":{"projectIdUpper":"The project id upper"},"returns":{"projectId":"The concatenation of the `projectIdUpper` and the `msg.sender`"}},"listProjectUrls(bytes32)":{"params":{"projectId":"The project id"},"returns":{"_0":"projectUrls The project URLs"}},"removeProjectUrl(bytes32,string)":{"params":{"projectId":"The project id","projectUrl":"The project URL"}},"transferProject(bytes32,address)":{"params":{"newOwner":"The new owner","projectId":"The project id"}},"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)":{"params":{"attestation":"The attestation","projectId":"The project id","wallet":"The wallet address"},"returns":{"_0":"magic The attestation magic bytes for the wallet address"}}},"version":1},"userdoc":{"kind":"user","methods":{"addProjectUrl(bytes32,string)":{"notice":"Add a project URL"},"claimProject(bytes12)":{"notice":"Claim a project"},"listProjectUrls(bytes32)":{"notice":"List project URLs"},"removeProjectUrl(bytes32,string)":{"notice":"Remove a project URL"},"transferProject(bytes32,address)":{"notice":"Transfer a project"},"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)":{"notice":"Check if a project has a code"}},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"src/registry/IImplicitProjectRegistry.sol":"IImplicitProjectRegistry"},"evmVersion":"paris","libraries":{}},"sources":{"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"},"src/registry/IImplicitProjectRegistry.sol":{"keccak256":"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf","urls":["bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de","dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6"],"license":"Apache-2.0"},"src/registry/IImplicitProjectValidation.sol":{"keccak256":"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2","urls":["bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c","dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6"],"license":"Apache-2.0"}},"version":1},"id":26} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/IImplicitProjectValidation.sol/IImplicitProjectValidation.json b/lib/signals-implicit-mode/out/IImplicitProjectValidation.sol/IImplicitProjectValidation.json deleted file mode 100644 index 2ec4d4e720..0000000000 --- a/lib/signals-implicit-mode/out/IImplicitProjectValidation.sol/IImplicitProjectValidation.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"validateAttestation","inputs":[{"name":"wallet","type":"address","internalType":"address"},{"name":"attestation","type":"tuple","internalType":"struct Attestation","components":[{"name":"approvedSigner","type":"address","internalType":"address"},{"name":"identityType","type":"bytes4","internalType":"bytes4"},{"name":"issuerHash","type":"bytes32","internalType":"bytes32"},{"name":"audienceHash","type":"bytes32","internalType":"bytes32"},{"name":"applicationData","type":"bytes","internalType":"bytes"},{"name":"authData","type":"tuple","internalType":"struct AuthData","components":[{"name":"redirectUrl","type":"string","internalType":"string"},{"name":"issuedAt","type":"uint64","internalType":"uint64"}]}]},{"name":"projectId","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"error","name":"InvalidRedirectUrl","inputs":[]}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)":"3808a90b"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"name\":\"InvalidRedirectUrl\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"wallet\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"approvedSigner\",\"type\":\"address\"},{\"internalType\":\"bytes4\",\"name\":\"identityType\",\"type\":\"bytes4\"},{\"internalType\":\"bytes32\",\"name\":\"issuerHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"audienceHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"applicationData\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"string\",\"name\":\"redirectUrl\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"issuedAt\",\"type\":\"uint64\"}],\"internalType\":\"struct AuthData\",\"name\":\"authData\",\"type\":\"tuple\"}],\"internalType\":\"struct Attestation\",\"name\":\"attestation\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"}],\"name\":\"validateAttestation\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"author\":\"Michael Standen\",\"kind\":\"dev\",\"methods\":{\"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)\":{\"params\":{\"attestation\":\"The attestation\",\"projectId\":\"The project id\",\"wallet\":\"The wallet address\"},\"returns\":{\"_0\":\"magic The attestation magic bytes for the wallet address\"}}},\"title\":\"IImplicitProjectValidation\",\"version\":1},\"userdoc\":{\"errors\":{\"InvalidRedirectUrl()\":[{\"notice\":\"Invalid redirect url error\"}]},\"kind\":\"user\",\"methods\":{\"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)\":{\"notice\":\"Check if a project has a code\"}},\"notice\":\"Interface for contracts supporting validation of implicit sessions for projects\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"src/registry/IImplicitProjectValidation.sol\":\"IImplicitProjectValidation\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]},\"src/registry/IImplicitProjectValidation.sol\":{\"keccak256\":\"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c\",\"dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[],"type":"error","name":"InvalidRedirectUrl"},{"inputs":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"struct Attestation","name":"attestation","type":"tuple","components":[{"internalType":"address","name":"approvedSigner","type":"address"},{"internalType":"bytes4","name":"identityType","type":"bytes4"},{"internalType":"bytes32","name":"issuerHash","type":"bytes32"},{"internalType":"bytes32","name":"audienceHash","type":"bytes32"},{"internalType":"bytes","name":"applicationData","type":"bytes"},{"internalType":"struct AuthData","name":"authData","type":"tuple","components":[{"internalType":"string","name":"redirectUrl","type":"string"},{"internalType":"uint64","name":"issuedAt","type":"uint64"}]}]},{"internalType":"bytes32","name":"projectId","type":"bytes32"}],"stateMutability":"view","type":"function","name":"validateAttestation","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}]}],"devdoc":{"kind":"dev","methods":{"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)":{"params":{"attestation":"The attestation","projectId":"The project id","wallet":"The wallet address"},"returns":{"_0":"magic The attestation magic bytes for the wallet address"}}},"version":1},"userdoc":{"kind":"user","methods":{"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)":{"notice":"Check if a project has a code"}},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"src/registry/IImplicitProjectValidation.sol":"IImplicitProjectValidation"},"evmVersion":"paris","libraries":{}},"sources":{"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"},"src/registry/IImplicitProjectValidation.sol":{"keccak256":"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2","urls":["bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c","dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6"],"license":"Apache-2.0"}},"version":1},"id":27} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/IMulticall3.sol/IMulticall3.json b/lib/signals-implicit-mode/out/IMulticall3.sol/IMulticall3.json deleted file mode 100644 index 88a16ea42c..0000000000 --- a/lib/signals-implicit-mode/out/IMulticall3.sol/IMulticall3.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"aggregate","inputs":[{"name":"calls","type":"tuple[]","internalType":"struct IMulticall3.Call[]","components":[{"name":"target","type":"address","internalType":"address"},{"name":"callData","type":"bytes","internalType":"bytes"}]}],"outputs":[{"name":"blockNumber","type":"uint256","internalType":"uint256"},{"name":"returnData","type":"bytes[]","internalType":"bytes[]"}],"stateMutability":"payable"},{"type":"function","name":"aggregate3","inputs":[{"name":"calls","type":"tuple[]","internalType":"struct IMulticall3.Call3[]","components":[{"name":"target","type":"address","internalType":"address"},{"name":"allowFailure","type":"bool","internalType":"bool"},{"name":"callData","type":"bytes","internalType":"bytes"}]}],"outputs":[{"name":"returnData","type":"tuple[]","internalType":"struct IMulticall3.Result[]","components":[{"name":"success","type":"bool","internalType":"bool"},{"name":"returnData","type":"bytes","internalType":"bytes"}]}],"stateMutability":"payable"},{"type":"function","name":"aggregate3Value","inputs":[{"name":"calls","type":"tuple[]","internalType":"struct IMulticall3.Call3Value[]","components":[{"name":"target","type":"address","internalType":"address"},{"name":"allowFailure","type":"bool","internalType":"bool"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"callData","type":"bytes","internalType":"bytes"}]}],"outputs":[{"name":"returnData","type":"tuple[]","internalType":"struct IMulticall3.Result[]","components":[{"name":"success","type":"bool","internalType":"bool"},{"name":"returnData","type":"bytes","internalType":"bytes"}]}],"stateMutability":"payable"},{"type":"function","name":"blockAndAggregate","inputs":[{"name":"calls","type":"tuple[]","internalType":"struct IMulticall3.Call[]","components":[{"name":"target","type":"address","internalType":"address"},{"name":"callData","type":"bytes","internalType":"bytes"}]}],"outputs":[{"name":"blockNumber","type":"uint256","internalType":"uint256"},{"name":"blockHash","type":"bytes32","internalType":"bytes32"},{"name":"returnData","type":"tuple[]","internalType":"struct IMulticall3.Result[]","components":[{"name":"success","type":"bool","internalType":"bool"},{"name":"returnData","type":"bytes","internalType":"bytes"}]}],"stateMutability":"payable"},{"type":"function","name":"getBasefee","inputs":[],"outputs":[{"name":"basefee","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getBlockHash","inputs":[{"name":"blockNumber","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"blockHash","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"getBlockNumber","inputs":[],"outputs":[{"name":"blockNumber","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getChainId","inputs":[],"outputs":[{"name":"chainid","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getCurrentBlockCoinbase","inputs":[],"outputs":[{"name":"coinbase","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"getCurrentBlockDifficulty","inputs":[],"outputs":[{"name":"difficulty","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getCurrentBlockGasLimit","inputs":[],"outputs":[{"name":"gaslimit","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getCurrentBlockTimestamp","inputs":[],"outputs":[{"name":"timestamp","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getEthBalance","inputs":[{"name":"addr","type":"address","internalType":"address"}],"outputs":[{"name":"balance","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getLastBlockHash","inputs":[],"outputs":[{"name":"blockHash","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"tryAggregate","inputs":[{"name":"requireSuccess","type":"bool","internalType":"bool"},{"name":"calls","type":"tuple[]","internalType":"struct IMulticall3.Call[]","components":[{"name":"target","type":"address","internalType":"address"},{"name":"callData","type":"bytes","internalType":"bytes"}]}],"outputs":[{"name":"returnData","type":"tuple[]","internalType":"struct IMulticall3.Result[]","components":[{"name":"success","type":"bool","internalType":"bool"},{"name":"returnData","type":"bytes","internalType":"bytes"}]}],"stateMutability":"payable"},{"type":"function","name":"tryBlockAndAggregate","inputs":[{"name":"requireSuccess","type":"bool","internalType":"bool"},{"name":"calls","type":"tuple[]","internalType":"struct IMulticall3.Call[]","components":[{"name":"target","type":"address","internalType":"address"},{"name":"callData","type":"bytes","internalType":"bytes"}]}],"outputs":[{"name":"blockNumber","type":"uint256","internalType":"uint256"},{"name":"blockHash","type":"bytes32","internalType":"bytes32"},{"name":"returnData","type":"tuple[]","internalType":"struct IMulticall3.Result[]","components":[{"name":"success","type":"bool","internalType":"bool"},{"name":"returnData","type":"bytes","internalType":"bytes"}]}],"stateMutability":"payable"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"aggregate((address,bytes)[])":"252dba42","aggregate3((address,bool,bytes)[])":"82ad56cb","aggregate3Value((address,bool,uint256,bytes)[])":"174dea71","blockAndAggregate((address,bytes)[])":"c3077fa9","getBasefee()":"3e64a696","getBlockHash(uint256)":"ee82ac5e","getBlockNumber()":"42cbb15c","getChainId()":"3408e470","getCurrentBlockCoinbase()":"a8b0574e","getCurrentBlockDifficulty()":"72425d9d","getCurrentBlockGasLimit()":"86d516e8","getCurrentBlockTimestamp()":"0f28c97d","getEthBalance(address)":"4d2301cc","getLastBlockHash()":"27e86d6e","tryAggregate(bool,(address,bytes)[])":"bce38bd7","tryBlockAndAggregate(bool,(address,bytes)[])":"399542e9"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"}],\"internalType\":\"struct IMulticall3.Call[]\",\"name\":\"calls\",\"type\":\"tuple[]\"}],\"name\":\"aggregate\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"returnData\",\"type\":\"bytes[]\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"allowFailure\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"}],\"internalType\":\"struct IMulticall3.Call3[]\",\"name\":\"calls\",\"type\":\"tuple[]\"}],\"name\":\"aggregate3\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"internalType\":\"struct IMulticall3.Result[]\",\"name\":\"returnData\",\"type\":\"tuple[]\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"allowFailure\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"}],\"internalType\":\"struct IMulticall3.Call3Value[]\",\"name\":\"calls\",\"type\":\"tuple[]\"}],\"name\":\"aggregate3Value\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"internalType\":\"struct IMulticall3.Result[]\",\"name\":\"returnData\",\"type\":\"tuple[]\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"}],\"internalType\":\"struct IMulticall3.Call[]\",\"name\":\"calls\",\"type\":\"tuple[]\"}],\"name\":\"blockAndAggregate\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"internalType\":\"struct IMulticall3.Result[]\",\"name\":\"returnData\",\"type\":\"tuple[]\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getBasefee\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"basefee\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"}],\"name\":\"getBlockHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getBlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getChainId\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"chainid\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCurrentBlockCoinbase\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"coinbase\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCurrentBlockDifficulty\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"difficulty\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCurrentBlockGasLimit\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"gaslimit\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCurrentBlockTimestamp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timestamp\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"getEthBalance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLastBlockHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"requireSuccess\",\"type\":\"bool\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"}],\"internalType\":\"struct IMulticall3.Call[]\",\"name\":\"calls\",\"type\":\"tuple[]\"}],\"name\":\"tryAggregate\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"internalType\":\"struct IMulticall3.Result[]\",\"name\":\"returnData\",\"type\":\"tuple[]\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"requireSuccess\",\"type\":\"bool\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"callData\",\"type\":\"bytes\"}],\"internalType\":\"struct IMulticall3.Call[]\",\"name\":\"calls\",\"type\":\"tuple[]\"}],\"name\":\"tryBlockAndAggregate\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"internalType\":\"struct IMulticall3.Result[]\",\"name\":\"returnData\",\"type\":\"tuple[]\"}],\"stateMutability\":\"payable\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/interfaces/IMulticall3.sol\":\"IMulticall3\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"struct IMulticall3.Call[]","name":"calls","type":"tuple[]","components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"callData","type":"bytes"}]}],"stateMutability":"payable","type":"function","name":"aggregate","outputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes[]","name":"returnData","type":"bytes[]"}]},{"inputs":[{"internalType":"struct IMulticall3.Call3[]","name":"calls","type":"tuple[]","components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bool","name":"allowFailure","type":"bool"},{"internalType":"bytes","name":"callData","type":"bytes"}]}],"stateMutability":"payable","type":"function","name":"aggregate3","outputs":[{"internalType":"struct IMulticall3.Result[]","name":"returnData","type":"tuple[]","components":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"bytes","name":"returnData","type":"bytes"}]}]},{"inputs":[{"internalType":"struct IMulticall3.Call3Value[]","name":"calls","type":"tuple[]","components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bool","name":"allowFailure","type":"bool"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"callData","type":"bytes"}]}],"stateMutability":"payable","type":"function","name":"aggregate3Value","outputs":[{"internalType":"struct IMulticall3.Result[]","name":"returnData","type":"tuple[]","components":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"bytes","name":"returnData","type":"bytes"}]}]},{"inputs":[{"internalType":"struct IMulticall3.Call[]","name":"calls","type":"tuple[]","components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"callData","type":"bytes"}]}],"stateMutability":"payable","type":"function","name":"blockAndAggregate","outputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes32","name":"blockHash","type":"bytes32"},{"internalType":"struct IMulticall3.Result[]","name":"returnData","type":"tuple[]","components":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"bytes","name":"returnData","type":"bytes"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getBasefee","outputs":[{"internalType":"uint256","name":"basefee","type":"uint256"}]},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"stateMutability":"view","type":"function","name":"getBlockHash","outputs":[{"internalType":"bytes32","name":"blockHash","type":"bytes32"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getBlockNumber","outputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getChainId","outputs":[{"internalType":"uint256","name":"chainid","type":"uint256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getCurrentBlockCoinbase","outputs":[{"internalType":"address","name":"coinbase","type":"address"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getCurrentBlockDifficulty","outputs":[{"internalType":"uint256","name":"difficulty","type":"uint256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getCurrentBlockGasLimit","outputs":[{"internalType":"uint256","name":"gaslimit","type":"uint256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getCurrentBlockTimestamp","outputs":[{"internalType":"uint256","name":"timestamp","type":"uint256"}]},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"stateMutability":"view","type":"function","name":"getEthBalance","outputs":[{"internalType":"uint256","name":"balance","type":"uint256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getLastBlockHash","outputs":[{"internalType":"bytes32","name":"blockHash","type":"bytes32"}]},{"inputs":[{"internalType":"bool","name":"requireSuccess","type":"bool"},{"internalType":"struct IMulticall3.Call[]","name":"calls","type":"tuple[]","components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"callData","type":"bytes"}]}],"stateMutability":"payable","type":"function","name":"tryAggregate","outputs":[{"internalType":"struct IMulticall3.Result[]","name":"returnData","type":"tuple[]","components":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"bytes","name":"returnData","type":"bytes"}]}]},{"inputs":[{"internalType":"bool","name":"requireSuccess","type":"bool"},{"internalType":"struct IMulticall3.Call[]","name":"calls","type":"tuple[]","components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"callData","type":"bytes"}]}],"stateMutability":"payable","type":"function","name":"tryBlockAndAggregate","outputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes32","name":"blockHash","type":"bytes32"},{"internalType":"struct IMulticall3.Result[]","name":"returnData","type":"tuple[]","components":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"bytes","name":"returnData","type":"bytes"}]}]}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/interfaces/IMulticall3.sol":"IMulticall3"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"}},"version":1},"id":17} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/ISignalsImplicitMode.sol/ISignalsImplicitMode.json b/lib/signals-implicit-mode/out/ISignalsImplicitMode.sol/ISignalsImplicitMode.json deleted file mode 100644 index 4cebd18146..0000000000 --- a/lib/signals-implicit-mode/out/ISignalsImplicitMode.sol/ISignalsImplicitMode.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"acceptImplicitRequest","inputs":[{"name":"wallet","type":"address","internalType":"address"},{"name":"attestation","type":"tuple","internalType":"struct Attestation","components":[{"name":"approvedSigner","type":"address","internalType":"address"},{"name":"identityType","type":"bytes4","internalType":"bytes4"},{"name":"issuerHash","type":"bytes32","internalType":"bytes32"},{"name":"audienceHash","type":"bytes32","internalType":"bytes32"},{"name":"applicationData","type":"bytes","internalType":"bytes"},{"name":"authData","type":"tuple","internalType":"struct AuthData","components":[{"name":"redirectUrl","type":"string","internalType":"string"},{"name":"issuedAt","type":"uint64","internalType":"uint64"}]}]},{"name":"call","type":"tuple","internalType":"struct Payload.Call","components":[{"name":"to","type":"address","internalType":"address"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"gasLimit","type":"uint256","internalType":"uint256"},{"name":"delegateCall","type":"bool","internalType":"bool"},{"name":"onlyFallback","type":"bool","internalType":"bool"},{"name":"behaviorOnError","type":"uint256","internalType":"uint256"}]}],"outputs":[{"name":"magic","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))":"9d043a66"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"wallet\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"approvedSigner\",\"type\":\"address\"},{\"internalType\":\"bytes4\",\"name\":\"identityType\",\"type\":\"bytes4\"},{\"internalType\":\"bytes32\",\"name\":\"issuerHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"audienceHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"applicationData\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"string\",\"name\":\"redirectUrl\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"issuedAt\",\"type\":\"uint64\"}],\"internalType\":\"struct AuthData\",\"name\":\"authData\",\"type\":\"tuple\"}],\"internalType\":\"struct Attestation\",\"name\":\"attestation\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"delegateCall\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"onlyFallback\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"behaviorOnError\",\"type\":\"uint256\"}],\"internalType\":\"struct Payload.Call\",\"name\":\"call\",\"type\":\"tuple\"}],\"name\":\"acceptImplicitRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"magic\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"author\":\"Agustin Aguilar, Michael Standen\",\"kind\":\"dev\",\"methods\":{\"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))\":{\"params\":{\"attestation\":\"The attestation data\",\"call\":\"The call to validate\",\"wallet\":\"The wallet's address\"},\"returns\":{\"magic\":\"The hash of the implicit request if valid\"}}},\"title\":\"ISignalsImplicitMode\",\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))\":{\"notice\":\"Determines if an implicit request is valid\"}},\"notice\":\"Interface for the contracts that support implicit mode validation\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":\"ISignalsImplicitMode\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"struct Attestation","name":"attestation","type":"tuple","components":[{"internalType":"address","name":"approvedSigner","type":"address"},{"internalType":"bytes4","name":"identityType","type":"bytes4"},{"internalType":"bytes32","name":"issuerHash","type":"bytes32"},{"internalType":"bytes32","name":"audienceHash","type":"bytes32"},{"internalType":"bytes","name":"applicationData","type":"bytes"},{"internalType":"struct AuthData","name":"authData","type":"tuple","components":[{"internalType":"string","name":"redirectUrl","type":"string"},{"internalType":"uint64","name":"issuedAt","type":"uint64"}]}]},{"internalType":"struct Payload.Call","name":"call","type":"tuple","components":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"bool","name":"delegateCall","type":"bool"},{"internalType":"bool","name":"onlyFallback","type":"bool"},{"internalType":"uint256","name":"behaviorOnError","type":"uint256"}]}],"stateMutability":"view","type":"function","name":"acceptImplicitRequest","outputs":[{"internalType":"bytes32","name":"magic","type":"bytes32"}]}],"devdoc":{"kind":"dev","methods":{"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))":{"params":{"attestation":"The attestation data","call":"The call to validate","wallet":"The wallet's address"},"returns":{"magic":"The hash of the implicit request if valid"}}},"version":1},"userdoc":{"kind":"user","methods":{"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))":{"notice":"Determines if an implicit request is valid"}},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":"ISignalsImplicitMode"},"evmVersion":"paris","libraries":{}},"sources":{"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"}},"version":1},"id":22} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/ISingletonFactory.sol/ISingletonFactory.json b/lib/signals-implicit-mode/out/ISingletonFactory.sol/ISingletonFactory.json deleted file mode 100644 index a67ec81b1d..0000000000 --- a/lib/signals-implicit-mode/out/ISingletonFactory.sol/ISingletonFactory.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"deploy","inputs":[{"name":"_initCode","type":"bytes","internalType":"bytes"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"createdContract","type":"address","internalType":"address payable"}],"stateMutability":"nonpayable"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"deploy(bytes,bytes32)":"4af63f02"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"_initCode\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deploy\",\"outputs\":[{\"internalType\":\"address payable\",\"name\":\"createdContract\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol\":\"ISingletonFactory\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol\":{\"keccak256\":\"0x0a17871e1017f36a664b877f5b0db297dc998fdf8b0ab82d00ca50d5bdde88f7\",\"license\":\"UNLICENSED\",\"urls\":[\"bzz-raw://160bc0d890492792f85dfea939160290d90562b27154f64c39c2a615243518a6\",\"dweb:/ipfs/QmbxmqPpTAH7X45G75UjmLh3RSTDj7trMtmkGU6RXmRyEJ\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"bytes","name":"_initCode","type":"bytes"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deploy","outputs":[{"internalType":"address payable","name":"createdContract","type":"address"}]}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol":"ISingletonFactory"},"evmVersion":"paris","libraries":{}},"sources":{"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol":{"keccak256":"0x0a17871e1017f36a664b877f5b0db297dc998fdf8b0ab82d00ca50d5bdde88f7","urls":["bzz-raw://160bc0d890492792f85dfea939160290d90562b27154f64c39c2a615243518a6","dweb:/ipfs/QmbxmqPpTAH7X45G75UjmLh3RSTDj7trMtmkGU6RXmRyEJ"],"license":"UNLICENSED"}},"version":1},"id":16} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/ImplicitProjectRegistry.sol/ImplicitProjectRegistry.json b/lib/signals-implicit-mode/out/ImplicitProjectRegistry.sol/ImplicitProjectRegistry.json deleted file mode 100644 index 0226fb7d35..0000000000 --- a/lib/signals-implicit-mode/out/ImplicitProjectRegistry.sol/ImplicitProjectRegistry.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"addProjectUrl","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"},{"name":"projectUrl","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"addProjectUrlBatch","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"},{"name":"projectUrls","type":"string[]","internalType":"string[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"addProjectUrlHash","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"},{"name":"projectUrlHash","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"addProjectUrlHashBatch","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"},{"name":"projectUrlHashes","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"claimProject","inputs":[{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"}],"outputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"}],"stateMutability":"nonpayable"},{"type":"function","name":"isProjectUrl","inputs":[{"name":"","type":"bytes32","internalType":"bytes32"},{"name":"","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"listProjectUrls","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"view"},{"type":"function","name":"projectOwner","inputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"projectUrlsList","inputs":[{"name":"","type":"bytes32","internalType":"bytes32"},{"name":"","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"removeProjectUrl","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"},{"name":"projectUrl","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"removeProjectUrlHash","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"},{"name":"projectUrlHash","type":"bytes32","internalType":"bytes32"},{"name":"urlIdx","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"removeProjectUrlHashBatch","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"},{"name":"projectUrlHashes","type":"bytes32[]","internalType":"bytes32[]"},{"name":"urlIdxs","type":"uint256[]","internalType":"uint256[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"transferProject","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"},{"name":"newOwner","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"validateAttestation","inputs":[{"name":"wallet","type":"address","internalType":"address"},{"name":"attestation","type":"tuple","internalType":"struct Attestation","components":[{"name":"approvedSigner","type":"address","internalType":"address"},{"name":"identityType","type":"bytes4","internalType":"bytes4"},{"name":"issuerHash","type":"bytes32","internalType":"bytes32"},{"name":"audienceHash","type":"bytes32","internalType":"bytes32"},{"name":"applicationData","type":"bytes","internalType":"bytes"},{"name":"authData","type":"tuple","internalType":"struct AuthData","components":[{"name":"redirectUrl","type":"string","internalType":"string"},{"name":"issuedAt","type":"uint64","internalType":"uint64"}]}]},{"name":"projectId","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"event","name":"ProjectClaimed","inputs":[{"name":"projectId","type":"bytes32","indexed":true,"internalType":"bytes32"},{"name":"owner","type":"address","indexed":true,"internalType":"address"}],"anonymous":false},{"type":"event","name":"ProjectOwnerTransferred","inputs":[{"name":"projectId","type":"bytes32","indexed":true,"internalType":"bytes32"},{"name":"newOwner","type":"address","indexed":true,"internalType":"address"}],"anonymous":false},{"type":"event","name":"ProjectUrlAdded","inputs":[{"name":"projectId","type":"bytes32","indexed":true,"internalType":"bytes32"},{"name":"urlHash","type":"bytes32","indexed":true,"internalType":"bytes32"}],"anonymous":false},{"type":"event","name":"ProjectUrlRemoved","inputs":[{"name":"projectId","type":"bytes32","indexed":true,"internalType":"bytes32"},{"name":"urlHash","type":"bytes32","indexed":true,"internalType":"bytes32"}],"anonymous":false},{"type":"error","name":"InvalidProjectOwner","inputs":[]},{"type":"error","name":"InvalidProjectUrlIndex","inputs":[]},{"type":"error","name":"InvalidRedirectUrl","inputs":[]},{"type":"error","name":"NotProjectOwner","inputs":[]},{"type":"error","name":"ProjectAlreadyClaimed","inputs":[]},{"type":"error","name":"ProjectUrlAlreadyExists","inputs":[]},{"type":"error","name":"ProjectUrlNotFound","inputs":[]}],"bytecode":{"object":"0x6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c0033","sourceMap":"454:6539:28:-:0;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c0033","sourceMap":"454:6539:28:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2786:260;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;4424:209;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;3093:177;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;6463:396;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2469:175;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;3395:250;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;1600:335;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;668:64;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;4905:701;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;1017:536;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;736:52;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;5732:498;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;589:47;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;6277:137;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2786:260;2910:9;883:10;856:37;;:12;:23;869:9;856:23;;;;;;;;;;;;;;;;;;;;;:37;;;852:107;;910:42;;;;;;;;;;;;;;852:107;2932:9:::1;2927:115;2947:16;:23;2943:1;:27;2927:115;;;2985:50;3004:9;3015:16;3032:1;3015:19;;;;;;;;:::i;:::-;;;;;;;;2985:18;:50::i;:::-;2972:3;;;;;;;2927:115;;;;2786:260:::0;;;:::o;4424:209::-;4555:9;883:10;856:37;;:12;:23;869:9;856:23;;;;;;;;;;;;;;;;;;;;;:37;;;852:107;;910:42;;;;;;;;;;;;;;852:107;4572:56:::1;4594:9;4605:14;4621:6;4572:21;:56::i;:::-;4424:209:::0;;;;:::o;3093:177::-;3197:9;883:10;856:37;;:12;:23;869:9;856:23;;;;;;;;;;;;;;;;;;;;;:37;;;852:107;;910:42;;;;;;;;;;;;;;852:107;3214:51:::1;3233:9;3244:20;3253:10;3244:8;:20::i;:::-;3214:18;:51::i;:::-;3093:177:::0;;;:::o;6463:396::-;6600:7;6615:17;6635:42;6644:11;:20;;;;;;;;:::i;:::-;:32;;;;;;;;:::i;:::-;6635:42;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:8;:42::i;:::-;6615:62;;6688:12;:23;6701:9;6688:23;;;;;;;;;;;:34;6712:9;6688:34;;;;;;;;;;;;;;;;;;;;;6684:110;;;6739:48;6780:6;6739:11;:40;;;:::i;:::-;;;:48;;;;:::i;:::-;6732:55;;;;;6684:110;6807:47;;;;;;;;;;;;;;6463:396;;;;;;:::o;2469:175::-;2577:9;883:10;856:37;;:12;:23;869:9;856:23;;;;;;;;;;;;;;;;;;;;;:37;;;852:107;;910:42;;;;;;;;;;;;;;852:107;2594:45:::1;2613:9;2624:14;2594:18;:45::i;:::-;2469:175:::0;;;:::o;3395:250::-;3509:9;883:10;856:37;;:12;:23;869:9;856:23;;;;;;;;;;;;;;;;;;;;;:37;;;852:107;;910:42;;;;;;;;;;;;;;852:107;3531:9:::1;3526:115;3546:11;:18;3542:1;:22;3526:115;;;3579:55;3598:9;3609:24;3618:11;3630:1;3618:14;;;;;;;;:::i;:::-;;;;;;;;3609:8;:24::i;:::-;3579:18;:55::i;:::-;3566:3;;;;;;;3526:115;;;;3395:250:::0;;;:::o;1600:335::-;1698:9;883:10;856:37;;:12;:23;869:9;856:23;;;;;;;;;;;;;;;;;;;;;:37;;;852:107;;910:42;;;;;;;;;;;;;;852:107;1739:1:::1;1719:22;;:8;:22;;::::0;1715:96:::1;;1758:46;;;;;;;;;;;;;;1715:96;1842:8;1816:12;:23:::0;1829:9:::1;1816:23;;;;;;;;;;;;:34;;;;;;;;;;;;;;;;;;1921:8;1861:69;;1910:9;1861:69;;;;;;;;;;1600:335:::0;;;:::o;668:64::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;4905:701::-;5062:9;883:10;856:37;;:12;:23;869:9;856:23;;;;;;;;;;;;;;;;;;;;;:37;;;852:107;;910:42;;;;;;;;;;;;;;852:107;5110:7:::1;:14;5083:16;:23;:41;5079:118;;5141:49;;;;;;;;;;;;;;5079:118;5305:9;5300:167;5337:1;5320:7;:14;:18;;;;:::i;:::-;5316:1;:22;5300:167;;;5370:7;5382:1;5378;:5;;;;:::i;:::-;5370:14;;;;;;;;:::i;:::-;;;;;;;;5357:7;5365:1;5357:10;;;;;;;;:::i;:::-;;;;;;;;:27;5353:108;;;5403:49;;;;;;;;;;;;;;5353:108;5340:3;;;;;;;5300:167;;;;5477:9;5472:130;5492:16;:23;5488:1;:27;5472:130;;;5530:65;5552:9;5563:16;5580:1;5563:19;;;;;;;;:::i;:::-;;;;;;;;5584:7;5592:1;5584:10;;;;;;;;:::i;:::-;;;;;;;;5530:21;:65::i;:::-;5517:3;;;;;;;5472:130;;;;4905:701:::0;;;;:::o;1017:536::-;1087:17;1112:13;1128:10;1112:26;;1165:1;1148:19;;:5;:19;;;1144:93;;1184:46;;;;;;;;;;;;;;1144:93;1279:14;1295:5;1262:39;;;;;;;;;:::i;:::-;;;;;;;;;;;;;1254:48;;;:::i;:::-;1242:60;;1347:1;1312:37;;:12;:23;1325:9;1312:23;;;;;;;;;;;;;;;;;;;;;:37;;;1308:113;;1366:48;;;;;;;;;;;;;;1308:113;1452:5;1426:12;:23;1439:9;1426:23;;;;;;;;;;;;:31;;;;;;;;;;;;;;;;;;1519:5;1468:57;;1508:9;1468:57;;;;;;;;;;1532:16;1017:536;;;:::o;736:52::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;5732:498::-;5841:9;883:10;856:37;;:12;:23;869:9;856:23;;;;;;;;;;;;;;;;;;;;;:37;;;852:107;;910:42;;;;;;;;;;;;;;852:107;5904:22:::1;5929:20;5938:10;5929:8;:20::i;:::-;5904:45;;5960:9;5955:213;5975:15;:26;5991:9;5975:26;;;;;;;;;;;:33;;;;5971:1;:37;5955:213;;;6060:14;6027:15;:26;6043:9;6027:26;;;;;;;;;;;6054:1;6027:29;;;;;;;;:::i;:::-;;;;;;;;;;:47:::0;6023:139:::1;;6086:51;6108:9;6119:14;6135:1;6086:21;:51::i;:::-;6147:7;;;;6023:139;6010:3;;;;;;;5955:213;;;;6180:45;;;;;;;;;;;;;;964:1;5732:498:::0;;;:::o;589:47::-;;;;;;;;;;;;;;;;;;;;;;:::o;6277:137::-;6352:16;6383:15;:26;6399:9;6383:26;;;;;;;;;;;6376:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6277:137;;;:::o;1939:402::-;2041:12;:23;2054:9;2041:23;;;;;;;;;;;:39;2065:14;2041:39;;;;;;;;;;;;;;;;;;;;;2037:117;;;2097:50;;;;;;;;;;;;;;2037:117;2201:4;2159:12;:23;2172:9;2159:23;;;;;;;;;;;:39;2183:14;2159:39;;;;;;;;;;;;:46;;;;;;;;;;;;;;;;;;2211:15;:26;2227:9;2211:26;;;;;;;;;;;2243:14;2211:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2321:14;2310:9;2269:67;;;;;;;;;;1939:402;;:::o;3649:580::-;3784:15;:26;3800:9;3784:26;;;;;;;;;;;:33;;;;3774:6;:43;;:99;;;;3859:14;3821:15;:26;3837:9;3821:26;;;;;;;;;;;3848:6;3821:34;;;;;;;;:::i;:::-;;;;;;;;;;:52;;3774:99;3770:176;;;3890:49;;;;;;;;;;;;;;3770:176;3993:5;3951:12;:23;3964:9;3951:23;;;;;;;;;;;:39;3975:14;3951:39;;;;;;;;;;;;:47;;;;;;;;;;;;;;;;;;4041:15;:26;4057:9;4041:26;;;;;;;;;;;4104:1;4068:15;:26;4084:9;4068:26;;;;;;;;;;;:33;;;;:37;;;;:::i;:::-;4041:65;;;;;;;;:::i;:::-;;;;;;;;;;4004:15;:26;4020:9;4004:26;;;;;;;;;;;4031:6;4004:34;;;;;;;;:::i;:::-;;;;;;;;;:102;;;;4112:15;:26;4128:9;4112:26;;;;;;;;;;;:32;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;4209:14;4198:9;4155:69;;;;;;;;;;3649:580;;;:::o;6863:127::-;6931:7;6980:3;6963:21;;;;;;;;:::i;:::-;;;;;;;;;;;;;6953:32;;;;;;6946:39;;6863:127;;;:::o;4328:271:21:-;4437:7;284:41:22;;;;;;;:::i;:::-;;;;;;;;;;;;;274:52;;;;;;4531:6:21;4539:11;:24;;;4565:11;:22;;;4476:112;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;4459:135;;;;;;4452:142;;4328:271;;;;:::o;7:75:33:-;40:6;73:2;67:9;57:19;;7:75;:::o;88:117::-;197:1;194;187:12;211:117;320:1;317;310:12;334:77;371:7;400:5;389:16;;334:77;;;:::o;417:122::-;490:24;508:5;490:24;:::i;:::-;483:5;480:35;470:63;;529:1;526;519:12;470:63;417:122;:::o;545:139::-;591:5;629:6;616:20;607:29;;645:33;672:5;645:33;:::i;:::-;545:139;;;;:::o;690:117::-;799:1;796;789:12;813:102;854:6;905:2;901:7;896:2;889:5;885:14;881:28;871:38;;813:102;;;:::o;921:180::-;969:77;966:1;959:88;1066:4;1063:1;1056:15;1090:4;1087:1;1080:15;1107:281;1190:27;1212:4;1190:27;:::i;:::-;1182:6;1178:40;1320:6;1308:10;1305:22;1284:18;1272:10;1269:34;1266:62;1263:88;;;1331:18;;:::i;:::-;1263:88;1371:10;1367:2;1360:22;1150:238;1107:281;;:::o;1394:129::-;1428:6;1455:20;;:::i;:::-;1445:30;;1484:33;1512:4;1504:6;1484:33;:::i;:::-;1394:129;;;:::o;1529:311::-;1606:4;1696:18;1688:6;1685:30;1682:56;;;1718:18;;:::i;:::-;1682:56;1768:4;1760:6;1756:17;1748:25;;1828:4;1822;1818:15;1810:23;;1529:311;;;:::o;1846:117::-;1955:1;1952;1945:12;1986:710;2082:5;2107:81;2123:64;2180:6;2123:64;:::i;:::-;2107:81;:::i;:::-;2098:90;;2208:5;2237:6;2230:5;2223:21;2271:4;2264:5;2260:16;2253:23;;2324:4;2316:6;2312:17;2304:6;2300:30;2353:3;2345:6;2342:15;2339:122;;;2372:79;;:::i;:::-;2339:122;2487:6;2470:220;2504:6;2499:3;2496:15;2470:220;;;2579:3;2608:37;2641:3;2629:10;2608:37;:::i;:::-;2603:3;2596:50;2675:4;2670:3;2666:14;2659:21;;2546:144;2530:4;2525:3;2521:14;2514:21;;2470:220;;;2474:21;2088:608;;1986:710;;;;;:::o;2719:370::-;2790:5;2839:3;2832:4;2824:6;2820:17;2816:27;2806:122;;2847:79;;:::i;:::-;2806:122;2964:6;2951:20;2989:94;3079:3;3071:6;3064:4;3056:6;3052:17;2989:94;:::i;:::-;2980:103;;2796:293;2719:370;;;;:::o;3095:684::-;3188:6;3196;3245:2;3233:9;3224:7;3220:23;3216:32;3213:119;;;3251:79;;:::i;:::-;3213:119;3371:1;3396:53;3441:7;3432:6;3421:9;3417:22;3396:53;:::i;:::-;3386:63;;3342:117;3526:2;3515:9;3511:18;3498:32;3557:18;3549:6;3546:30;3543:117;;;3579:79;;:::i;:::-;3543:117;3684:78;3754:7;3745:6;3734:9;3730:22;3684:78;:::i;:::-;3674:88;;3469:303;3095:684;;;;;:::o;3785:77::-;3822:7;3851:5;3840:16;;3785:77;;;:::o;3868:122::-;3941:24;3959:5;3941:24;:::i;:::-;3934:5;3931:35;3921:63;;3980:1;3977;3970:12;3921:63;3868:122;:::o;3996:139::-;4042:5;4080:6;4067:20;4058:29;;4096:33;4123:5;4096:33;:::i;:::-;3996:139;;;;:::o;4141:619::-;4218:6;4226;4234;4283:2;4271:9;4262:7;4258:23;4254:32;4251:119;;;4289:79;;:::i;:::-;4251:119;4409:1;4434:53;4479:7;4470:6;4459:9;4455:22;4434:53;:::i;:::-;4424:63;;4380:117;4536:2;4562:53;4607:7;4598:6;4587:9;4583:22;4562:53;:::i;:::-;4552:63;;4507:118;4664:2;4690:53;4735:7;4726:6;4715:9;4711:22;4690:53;:::i;:::-;4680:63;;4635:118;4141:619;;;;;:::o;4766:117::-;4875:1;4872;4865:12;4889:308;4951:4;5041:18;5033:6;5030:30;5027:56;;;5063:18;;:::i;:::-;5027:56;5101:29;5123:6;5101:29;:::i;:::-;5093:37;;5185:4;5179;5175:15;5167:23;;4889:308;;;:::o;5203:148::-;5301:6;5296:3;5291;5278:30;5342:1;5333:6;5328:3;5324:16;5317:27;5203:148;;;:::o;5357:425::-;5435:5;5460:66;5476:49;5518:6;5476:49;:::i;:::-;5460:66;:::i;:::-;5451:75;;5549:6;5542:5;5535:21;5587:4;5580:5;5576:16;5625:3;5616:6;5611:3;5607:16;5604:25;5601:112;;;5632:79;;:::i;:::-;5601:112;5722:54;5769:6;5764:3;5759;5722:54;:::i;:::-;5441:341;5357:425;;;;;:::o;5802:340::-;5858:5;5907:3;5900:4;5892:6;5888:17;5884:27;5874:122;;5915:79;;:::i;:::-;5874:122;6032:6;6019:20;6057:79;6132:3;6124:6;6117:4;6109:6;6105:17;6057:79;:::i;:::-;6048:88;;5864:278;5802:340;;;;:::o;6148:654::-;6226:6;6234;6283:2;6271:9;6262:7;6258:23;6254:32;6251:119;;;6289:79;;:::i;:::-;6251:119;6409:1;6434:53;6479:7;6470:6;6459:9;6455:22;6434:53;:::i;:::-;6424:63;;6380:117;6564:2;6553:9;6549:18;6536:32;6595:18;6587:6;6584:30;6581:117;;;6617:79;;:::i;:::-;6581:117;6722:63;6777:7;6768:6;6757:9;6753:22;6722:63;:::i;:::-;6712:73;;6507:288;6148:654;;;;;:::o;6808:126::-;6845:7;6885:42;6878:5;6874:54;6863:65;;6808:126;;;:::o;6940:96::-;6977:7;7006:24;7024:5;7006:24;:::i;:::-;6995:35;;6940:96;;;:::o;7042:122::-;7115:24;7133:5;7115:24;:::i;:::-;7108:5;7105:35;7095:63;;7154:1;7151;7144:12;7095:63;7042:122;:::o;7170:139::-;7216:5;7254:6;7241:20;7232:29;;7270:33;7297:5;7270:33;:::i;:::-;7170:139;;;;:::o;7315:117::-;7424:1;7421;7414:12;7464:237;7542:5;7583:3;7574:6;7569:3;7565:16;7561:26;7558:113;;;7590:79;;:::i;:::-;7558:113;7689:6;7680:15;;7464:237;;;;:::o;7707:843::-;7816:6;7824;7832;7881:2;7869:9;7860:7;7856:23;7852:32;7849:119;;;7887:79;;:::i;:::-;7849:119;8007:1;8032:53;8077:7;8068:6;8057:9;8053:22;8032:53;:::i;:::-;8022:63;;7978:117;8162:2;8151:9;8147:18;8134:32;8193:18;8185:6;8182:30;8179:117;;;8215:79;;:::i;:::-;8179:117;8320:85;8397:7;8388:6;8377:9;8373:22;8320:85;:::i;:::-;8310:95;;8105:310;8454:2;8480:53;8525:7;8516:6;8505:9;8501:22;8480:53;:::i;:::-;8470:63;;8425:118;7707:843;;;;;:::o;8556:118::-;8643:24;8661:5;8643:24;:::i;:::-;8638:3;8631:37;8556:118;;:::o;8680:222::-;8773:4;8811:2;8800:9;8796:18;8788:26;;8824:71;8892:1;8881:9;8877:17;8868:6;8824:71;:::i;:::-;8680:222;;;;:::o;8908:474::-;8976:6;8984;9033:2;9021:9;9012:7;9008:23;9004:32;9001:119;;;9039:79;;:::i;:::-;9001:119;9159:1;9184:53;9229:7;9220:6;9209:9;9205:22;9184:53;:::i;:::-;9174:63;;9130:117;9286:2;9312:53;9357:7;9348:6;9337:9;9333:22;9312:53;:::i;:::-;9302:63;;9257:118;8908:474;;;;;:::o;9388:321::-;9475:4;9565:18;9557:6;9554:30;9551:56;;;9587:18;;:::i;:::-;9551:56;9637:4;9629:6;9625:17;9617:25;;9697:4;9691;9687:15;9679:23;;9388:321;;;:::o;9731:945::-;9837:5;9862:91;9878:74;9945:6;9878:74;:::i;:::-;9862:91;:::i;:::-;9853:100;;9973:5;10002:6;9995:5;9988:21;10036:4;10029:5;10025:16;10018:23;;10089:4;10081:6;10077:17;10069:6;10065:30;10118:3;10110:6;10107:15;10104:122;;;10137:79;;:::i;:::-;10104:122;10252:6;10235:435;10269:6;10264:3;10261:15;10235:435;;;10358:3;10345:17;10394:18;10381:11;10378:35;10375:122;;;10416:79;;:::i;:::-;10375:122;10540:11;10532:6;10528:24;10578:47;10621:3;10609:10;10578:47;:::i;:::-;10573:3;10566:60;10655:4;10650:3;10646:14;10639:21;;10311:359;;10295:4;10290:3;10286:14;10279:21;;10235:435;;;10239:21;9843:833;;9731:945;;;;;:::o;10698:390::-;10779:5;10828:3;10821:4;10813:6;10809:17;10805:27;10795:122;;10836:79;;:::i;:::-;10795:122;10953:6;10940:20;10978:104;11078:3;11070:6;11063:4;11055:6;11051:17;10978:104;:::i;:::-;10969:113;;10785:303;10698:390;;;;:::o;11094:704::-;11197:6;11205;11254:2;11242:9;11233:7;11229:23;11225:32;11222:119;;;11260:79;;:::i;:::-;11222:119;11380:1;11405:53;11450:7;11441:6;11430:9;11426:22;11405:53;:::i;:::-;11395:63;;11351:117;11535:2;11524:9;11520:18;11507:32;11566:18;11558:6;11555:30;11552:117;;;11588:79;;:::i;:::-;11552:117;11693:88;11773:7;11764:6;11753:9;11749:22;11693:88;:::i;:::-;11683:98;;11478:313;11094:704;;;;;:::o;11804:474::-;11872:6;11880;11929:2;11917:9;11908:7;11904:23;11900:32;11897:119;;;11935:79;;:::i;:::-;11897:119;12055:1;12080:53;12125:7;12116:6;12105:9;12101:22;12080:53;:::i;:::-;12070:63;;12026:117;12182:2;12208:53;12253:7;12244:6;12233:9;12229:22;12208:53;:::i;:::-;12198:63;;12153:118;11804:474;;;;;:::o;12284:90::-;12318:7;12361:5;12354:13;12347:21;12336:32;;12284:90;;;:::o;12380:109::-;12461:21;12476:5;12461:21;:::i;:::-;12456:3;12449:34;12380:109;;:::o;12495:210::-;12582:4;12620:2;12609:9;12605:18;12597:26;;12633:65;12695:1;12684:9;12680:17;12671:6;12633:65;:::i;:::-;12495:210;;;;:::o;12711:311::-;12788:4;12878:18;12870:6;12867:30;12864:56;;;12900:18;;:::i;:::-;12864:56;12950:4;12942:6;12938:17;12930:25;;13010:4;13004;13000:15;12992:23;;12711:311;;;:::o;13045:710::-;13141:5;13166:81;13182:64;13239:6;13182:64;:::i;:::-;13166:81;:::i;:::-;13157:90;;13267:5;13296:6;13289:5;13282:21;13330:4;13323:5;13319:16;13312:23;;13383:4;13375:6;13371:17;13363:6;13359:30;13412:3;13404:6;13401:15;13398:122;;;13431:79;;:::i;:::-;13398:122;13546:6;13529:220;13563:6;13558:3;13555:15;13529:220;;;13638:3;13667:37;13700:3;13688:10;13667:37;:::i;:::-;13662:3;13655:50;13734:4;13729:3;13725:14;13718:21;;13605:144;13589:4;13584:3;13580:14;13573:21;;13529:220;;;13533:21;13147:608;;13045:710;;;;;:::o;13778:370::-;13849:5;13898:3;13891:4;13883:6;13879:17;13875:27;13865:122;;13906:79;;:::i;:::-;13865:122;14023:6;14010:20;14048:94;14138:3;14130:6;14123:4;14115:6;14111:17;14048:94;:::i;:::-;14039:103;;13855:293;13778:370;;;;:::o;14154:1039::-;14281:6;14289;14297;14346:2;14334:9;14325:7;14321:23;14317:32;14314:119;;;14352:79;;:::i;:::-;14314:119;14472:1;14497:53;14542:7;14533:6;14522:9;14518:22;14497:53;:::i;:::-;14487:63;;14443:117;14627:2;14616:9;14612:18;14599:32;14658:18;14650:6;14647:30;14644:117;;;14680:79;;:::i;:::-;14644:117;14785:78;14855:7;14846:6;14835:9;14831:22;14785:78;:::i;:::-;14775:88;;14570:303;14940:2;14929:9;14925:18;14912:32;14971:18;14963:6;14960:30;14957:117;;;14993:79;;:::i;:::-;14957:117;15098:78;15168:7;15159:6;15148:9;15144:22;15098:78;:::i;:::-;15088:88;;14883:303;14154:1039;;;;;:::o;15199:150::-;15236:7;15276:66;15269:5;15265:78;15254:89;;15199:150;;;:::o;15355:122::-;15428:24;15446:5;15428:24;:::i;:::-;15421:5;15418:35;15408:63;;15467:1;15464;15457:12;15408:63;15355:122;:::o;15483:139::-;15529:5;15567:6;15554:20;15545:29;;15583:33;15610:5;15583:33;:::i;:::-;15483:139;;;;:::o;15628:329::-;15687:6;15736:2;15724:9;15715:7;15711:23;15707:32;15704:119;;;15742:79;;:::i;:::-;15704:119;15862:1;15887:53;15932:7;15923:6;15912:9;15908:22;15887:53;:::i;:::-;15877:63;;15833:117;15628:329;;;;:::o;15963:474::-;16031:6;16039;16088:2;16076:9;16067:7;16063:23;16059:32;16056:119;;;16094:79;;:::i;:::-;16056:119;16214:1;16239:53;16284:7;16275:6;16264:9;16260:22;16239:53;:::i;:::-;16229:63;;16185:117;16341:2;16367:53;16412:7;16403:6;16392:9;16388:22;16367:53;:::i;:::-;16357:63;;16312:118;15963:474;;;;;:::o;16443:329::-;16502:6;16551:2;16539:9;16530:7;16526:23;16522:32;16519:119;;;16557:79;;:::i;:::-;16519:119;16677:1;16702:53;16747:7;16738:6;16727:9;16723:22;16702:53;:::i;:::-;16692:63;;16648:117;16443:329;;;;:::o;16778:118::-;16865:24;16883:5;16865:24;:::i;:::-;16860:3;16853:37;16778:118;;:::o;16902:222::-;16995:4;17033:2;17022:9;17018:18;17010:26;;17046:71;17114:1;17103:9;17099:17;17090:6;17046:71;:::i;:::-;16902:222;;;;:::o;17130:114::-;17197:6;17231:5;17225:12;17215:22;;17130:114;;;:::o;17250:184::-;17349:11;17383:6;17378:3;17371:19;17423:4;17418:3;17414:14;17399:29;;17250:184;;;;:::o;17440:132::-;17507:4;17530:3;17522:11;;17560:4;17555:3;17551:14;17543:22;;17440:132;;;:::o;17578:108::-;17655:24;17673:5;17655:24;:::i;:::-;17650:3;17643:37;17578:108;;:::o;17692:179::-;17761:10;17782:46;17824:3;17816:6;17782:46;:::i;:::-;17860:4;17855:3;17851:14;17837:28;;17692:179;;;;:::o;17877:113::-;17947:4;17979;17974:3;17970:14;17962:22;;17877:113;;;:::o;18026:732::-;18145:3;18174:54;18222:5;18174:54;:::i;:::-;18244:86;18323:6;18318:3;18244:86;:::i;:::-;18237:93;;18354:56;18404:5;18354:56;:::i;:::-;18433:7;18464:1;18449:284;18474:6;18471:1;18468:13;18449:284;;;18550:6;18544:13;18577:63;18636:3;18621:13;18577:63;:::i;:::-;18570:70;;18663:60;18716:6;18663:60;:::i;:::-;18653:70;;18509:224;18496:1;18493;18489:9;18484:14;;18449:284;;;18453:14;18749:3;18742:10;;18150:608;;;18026:732;;;;:::o;18764:373::-;18907:4;18945:2;18934:9;18930:18;18922:26;;18994:9;18988:4;18984:20;18980:1;18969:9;18965:17;18958:47;19022:108;19125:4;19116:6;19022:108;:::i;:::-;19014:116;;18764:373;;;;:::o;19143:180::-;19191:77;19188:1;19181:88;19288:4;19285:1;19278:15;19312:4;19309:1;19302:15;19329:117;19438:1;19435;19428:12;19452:117;19561:1;19558;19551:12;19575:117;19684:1;19681;19674:12;19698:395;19793:4;19847:11;19834:25;19947:1;19941:4;19937:12;19926:8;19910:14;19906:29;19902:48;19882:18;19878:73;19868:168;;19955:79;;:::i;:::-;19868:168;20067:18;20057:8;20053:33;20045:41;;19798:295;19698:395;;;;:::o;20099:725::-;20177:4;20183:6;20239:11;20226:25;20339:1;20333:4;20329:12;20318:8;20302:14;20298:29;20294:48;20274:18;20270:73;20260:168;;20347:79;;:::i;:::-;20260:168;20459:18;20449:8;20445:33;20437:41;;20511:4;20498:18;20488:28;;20539:18;20531:6;20528:30;20525:117;;;20561:79;;:::i;:::-;20525:117;20669:2;20663:4;20659:13;20651:21;;20726:4;20718:6;20714:17;20698:14;20694:38;20688:4;20684:49;20681:136;;;20736:79;;:::i;:::-;20681:136;20190:634;20099:725;;;;;:::o;20830:117::-;20939:1;20936;20929:12;20953:117;21062:1;21059;21052:12;21076:149;21112:7;21152:66;21145:5;21141:78;21130:89;;21076:149;;;:::o;21231:120::-;21303:23;21320:5;21303:23;:::i;:::-;21296:5;21293:34;21283:62;;21341:1;21338;21331:12;21283:62;21231:120;:::o;21357:137::-;21402:5;21440:6;21427:20;21418:29;;21456:32;21482:5;21456:32;:::i;:::-;21357:137;;;;:::o;21500:307::-;21561:4;21651:18;21643:6;21640:30;21637:56;;;21673:18;;:::i;:::-;21637:56;21711:29;21733:6;21711:29;:::i;:::-;21703:37;;21795:4;21789;21785:15;21777:23;;21500:307;;;:::o;21813:423::-;21890:5;21915:65;21931:48;21972:6;21931:48;:::i;:::-;21915:65;:::i;:::-;21906:74;;22003:6;21996:5;21989:21;22041:4;22034:5;22030:16;22079:3;22070:6;22065:3;22061:16;22058:25;22055:112;;;22086:79;;:::i;:::-;22055:112;22176:54;22223:6;22218:3;22213;22176:54;:::i;:::-;21896:340;21813:423;;;;;:::o;22255:338::-;22310:5;22359:3;22352:4;22344:6;22340:17;22336:27;22326:122;;22367:79;;:::i;:::-;22326:122;22484:6;22471:20;22509:78;22583:3;22575:6;22568:4;22560:6;22556:17;22509:78;:::i;:::-;22500:87;;22316:277;22255:338;;;;:::o;22599:101::-;22635:7;22675:18;22668:5;22664:30;22653:41;;22599:101;;;:::o;22706:120::-;22778:23;22795:5;22778:23;:::i;:::-;22771:5;22768:34;22758:62;;22816:1;22813;22806:12;22758:62;22706:120;:::o;22832:137::-;22877:5;22915:6;22902:20;22893:29;;22931:32;22957:5;22931:32;:::i;:::-;22832:137;;;;:::o;22998:756::-;23074:5;23118:4;23106:9;23101:3;23097:19;23093:30;23090:117;;;23126:79;;:::i;:::-;23090:117;23225:21;23241:4;23225:21;:::i;:::-;23216:30;;23340:1;23329:9;23325:17;23312:31;23370:18;23362:6;23359:30;23356:117;;;23392:79;;:::i;:::-;23356:117;23512:59;23567:3;23558:6;23547:9;23543:22;23512:59;:::i;:::-;23505:4;23498:5;23494:16;23487:85;23256:327;23646:2;23687:48;23731:3;23722:6;23711:9;23707:22;23687:48;:::i;:::-;23680:4;23673:5;23669:16;23662:74;23593:154;22998:756;;;;:::o;23786:1627::-;23865:5;23909:4;23897:9;23892:3;23888:19;23884:30;23881:117;;;23917:79;;:::i;:::-;23881:117;24016:21;24032:4;24016:21;:::i;:::-;24007:30;;24106:1;24146:49;24191:3;24182:6;24171:9;24167:22;24146:49;:::i;:::-;24139:4;24132:5;24128:16;24121:75;24047:160;24274:2;24315:48;24359:3;24350:6;24339:9;24335:22;24315:48;:::i;:::-;24308:4;24301:5;24297:16;24290:74;24217:158;24440:2;24481:49;24526:3;24517:6;24506:9;24502:22;24481:49;:::i;:::-;24474:4;24467:5;24463:16;24456:75;24385:157;24609:2;24650:49;24695:3;24686:6;24675:9;24671:22;24650:49;:::i;:::-;24643:4;24636:5;24632:16;24625:75;24552:159;24809:3;24798:9;24794:19;24781:33;24841:18;24833:6;24830:30;24827:117;;;24863:79;;:::i;:::-;24827:117;24983:58;25037:3;25028:6;25017:9;25013:22;24983:58;:::i;:::-;24976:4;24969:5;24965:16;24958:84;24721:332;25144:3;25133:9;25129:19;25116:33;25176:18;25168:6;25165:30;25162:117;;;25198:79;;:::i;:::-;25162:117;25318:76;25390:3;25381:6;25370:9;25366:22;25318:76;:::i;:::-;25311:4;25304:5;25300:16;25293:102;25063:343;23786:1627;;;;:::o;25419:226::-;25531:9;25565:73;25623:14;25616:5;25565:73;:::i;:::-;25552:86;;25419:226;;;:::o;25651:180::-;25699:77;25696:1;25689:88;25796:4;25793:1;25786:15;25820:4;25817:1;25810:15;25837:194;25877:4;25897:20;25915:1;25897:20;:::i;:::-;25892:25;;25931:20;25949:1;25931:20;:::i;:::-;25926:25;;25975:1;25972;25968:9;25960:17;;25999:1;25993:4;25990:11;25987:37;;;26004:18;;:::i;:::-;25987:37;25837:194;;;;:::o;26037:191::-;26077:3;26096:20;26114:1;26096:20;:::i;:::-;26091:25;;26130:20;26148:1;26130:20;:::i;:::-;26125:25;;26173:1;26170;26166:9;26159:16;;26194:3;26191:1;26188:10;26185:36;;;26201:18;;:::i;:::-;26185:36;26037:191;;;;:::o;26234:79::-;26273:7;26302:5;26291:16;;26234:79;;;:::o;26319:157::-;26424:45;26444:24;26462:5;26444:24;:::i;:::-;26424:45;:::i;:::-;26419:3;26412:58;26319:157;;:::o;26482:94::-;26515:8;26563:5;26559:2;26555:14;26534:35;;26482:94;;;:::o;26582:::-;26621:7;26650:20;26664:5;26650:20;:::i;:::-;26639:31;;26582:94;;;:::o;26682:100::-;26721:7;26750:26;26770:5;26750:26;:::i;:::-;26739:37;;26682:100;;;:::o;26788:157::-;26893:45;26913:24;26931:5;26913:24;:::i;:::-;26893:45;:::i;:::-;26888:3;26881:58;26788:157;;:::o;26951:397::-;27091:3;27106:75;27177:3;27168:6;27106:75;:::i;:::-;27206:2;27201:3;27197:12;27190:19;;27219:75;27290:3;27281:6;27219:75;:::i;:::-;27319:2;27314:3;27310:12;27303:19;;27339:3;27332:10;;26951:397;;;;;:::o;27354:98::-;27405:6;27439:5;27433:12;27423:22;;27354:98;;;:::o;27458:116::-;27509:4;27532:3;27524:11;;27562:4;27557:3;27553:14;27545:22;;27458:116;;;:::o;27580:154::-;27623:11;27659:29;27683:3;27677:10;27659:29;:::i;:::-;27722:5;27698:29;;27635:99;27580:154;;;:::o;27740:107::-;27784:8;27834:5;27828:4;27824:16;27803:37;;27740:107;;;;:::o;27853:594::-;27937:5;27968:38;28000:5;27968:38;:::i;:::-;28031:5;28058:40;28092:5;28058:40;:::i;:::-;28046:52;;28117:35;28143:8;28117:35;:::i;:::-;28108:44;;28176:2;28168:6;28165:14;28162:278;;;28247:169;28332:66;28302:6;28298:2;28294:15;28291:1;28287:23;28247:169;:::i;:::-;28224:5;28203:227;28194:236;;28162:278;27943:504;;27853:594;;;:::o;28453:180::-;28501:77;28498:1;28491:88;28598:4;28595:1;28588:15;28622:4;28619:1;28612:15;28639:99;28691:6;28725:5;28719:12;28709:22;;28639:99;;;:::o;28744:148::-;28846:11;28883:3;28868:18;;28744:148;;;;:::o;28898:248::-;28980:1;28990:113;29004:6;29001:1;28998:13;28990:113;;;29089:1;29084:3;29080:11;29074:18;29070:1;29065:3;29061:11;29054:39;29026:2;29023:1;29019:10;29014:15;;28990:113;;;29137:1;29128:6;29123:3;29119:16;29112:27;28960:186;28898:248;;;:::o;29152:390::-;29258:3;29286:39;29319:5;29286:39;:::i;:::-;29341:89;29423:6;29418:3;29341:89;:::i;:::-;29334:96;;29439:65;29497:6;29492:3;29485:4;29478:5;29474:16;29439:65;:::i;:::-;29529:6;29524:3;29520:16;29513:23;;29262:280;29152:390;;;;:::o;29548:275::-;29680:3;29702:95;29793:3;29784:6;29702:95;:::i;:::-;29695:102;;29814:3;29807:10;;29548:275;;;;:::o;29829:171::-;29969:23;29965:1;29957:6;29953:14;29946:47;29829:171;:::o;30006:402::-;30166:3;30187:85;30269:2;30264:3;30187:85;:::i;:::-;30180:92;;30281:93;30370:3;30281:93;:::i;:::-;30399:2;30394:3;30390:12;30383:19;;30006:402;;;:::o;30414:381::-;30599:3;30621:148;30765:3;30621:148;:::i;:::-;30614:155;;30786:3;30779:10;;30414:381;;;:::o;30801:79::-;30840:7;30869:5;30858:16;;30801:79;;;:::o;30886:157::-;30991:45;31011:24;31029:5;31011:24;:::i;:::-;30991:45;:::i;:::-;30986:3;30979:58;30886:157;;:::o;31049:679::-;31245:3;31260:75;31331:3;31322:6;31260:75;:::i;:::-;31360:2;31355:3;31351:12;31344:19;;31373:75;31444:3;31435:6;31373:75;:::i;:::-;31473:2;31468:3;31464:12;31457:19;;31486:75;31557:3;31548:6;31486:75;:::i;:::-;31586:2;31581:3;31577:12;31570:19;;31599:75;31670:3;31661:6;31599:75;:::i;:::-;31699:2;31694:3;31690:12;31683:19;;31719:3;31712:10;;31049:679;;;;;;;:::o","linkReferences":{}},"methodIdentifiers":{"addProjectUrl(bytes32,string)":"2f28c69d","addProjectUrlBatch(bytes32,string[])":"56cd2b92","addProjectUrlHash(bytes32,bytes32)":"520994f1","addProjectUrlHashBatch(bytes32,bytes32[])":"065d6c69","claimProject(bytes12)":"d4df1018","isProjectUrl(bytes32,bytes32)":"a25acb25","listProjectUrls(bytes32)":"f4364de6","projectOwner(bytes32)":"ebc27b82","projectUrlsList(bytes32,uint256)":"d9acbe6b","removeProjectUrl(bytes32,string)":"dac6c587","removeProjectUrlHash(bytes32,bytes32,uint256)":"1b31f01b","removeProjectUrlHashBatch(bytes32,bytes32[],uint256[])":"d4c9c5c4","transferProject(bytes32,address)":"9630aff8","validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)":"3808a90b"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"name\":\"InvalidProjectOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProjectUrlIndex\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRedirectUrl\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotProjectOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProjectAlreadyClaimed\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProjectUrlAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProjectUrlNotFound\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"ProjectClaimed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"ProjectOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"urlHash\",\"type\":\"bytes32\"}],\"name\":\"ProjectUrlAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"urlHash\",\"type\":\"bytes32\"}],\"name\":\"ProjectUrlRemoved\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"internalType\":\"string\",\"name\":\"projectUrl\",\"type\":\"string\"}],\"name\":\"addProjectUrl\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"internalType\":\"string[]\",\"name\":\"projectUrls\",\"type\":\"string[]\"}],\"name\":\"addProjectUrlBatch\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"projectUrlHash\",\"type\":\"bytes32\"}],\"name\":\"addProjectUrlHash\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32[]\",\"name\":\"projectUrlHashes\",\"type\":\"bytes32[]\"}],\"name\":\"addProjectUrlHashBatch\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"}],\"name\":\"claimProject\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"isProjectUrl\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"}],\"name\":\"listProjectUrls\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"projectOwner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"projectUrlsList\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"internalType\":\"string\",\"name\":\"projectUrl\",\"type\":\"string\"}],\"name\":\"removeProjectUrl\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"projectUrlHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"urlIdx\",\"type\":\"uint256\"}],\"name\":\"removeProjectUrlHash\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32[]\",\"name\":\"projectUrlHashes\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint256[]\",\"name\":\"urlIdxs\",\"type\":\"uint256[]\"}],\"name\":\"removeProjectUrlHashBatch\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferProject\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"wallet\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"approvedSigner\",\"type\":\"address\"},{\"internalType\":\"bytes4\",\"name\":\"identityType\",\"type\":\"bytes4\"},{\"internalType\":\"bytes32\",\"name\":\"issuerHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"audienceHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"applicationData\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"string\",\"name\":\"redirectUrl\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"issuedAt\",\"type\":\"uint64\"}],\"internalType\":\"struct AuthData\",\"name\":\"authData\",\"type\":\"tuple\"}],\"internalType\":\"struct Attestation\",\"name\":\"attestation\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"}],\"name\":\"validateAttestation\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"author\":\"Michael Standen\",\"kind\":\"dev\",\"methods\":{\"addProjectUrl(bytes32,string)\":{\"params\":{\"projectId\":\"The project id\",\"projectUrl\":\"The project URL\"}},\"addProjectUrlBatch(bytes32,string[])\":{\"params\":{\"projectId\":\"The project id\",\"projectUrls\":\"The project URLs\"}},\"addProjectUrlHash(bytes32,bytes32)\":{\"params\":{\"projectId\":\"The project id\",\"projectUrlHash\":\"The project URL hash\"}},\"addProjectUrlHashBatch(bytes32,bytes32[])\":{\"params\":{\"projectId\":\"The project id\",\"projectUrlHashes\":\"The project URL hashes\"}},\"claimProject(bytes12)\":{\"params\":{\"projectIdUpper\":\"The project id upper\"},\"returns\":{\"projectId\":\"The concatenation of the `projectIdUpper` and the `msg.sender`\"}},\"listProjectUrls(bytes32)\":{\"params\":{\"projectId\":\"The project id\"},\"returns\":{\"_0\":\"projectUrls The project URLs\"}},\"removeProjectUrl(bytes32,string)\":{\"details\":\"This function is not optimized. Prefer to use removeProjectUrlHash.\",\"params\":{\"projectId\":\"The project id\",\"projectUrl\":\"The project URL\"}},\"removeProjectUrlHash(bytes32,bytes32,uint256)\":{\"params\":{\"projectId\":\"The project id\",\"projectUrlHash\":\"The project URL hash\",\"urlIdx\":\"The index of the project URL hash to remove\"}},\"removeProjectUrlHashBatch(bytes32,bytes32[],uint256[])\":{\"details\":\"The urlIdxs must be sorted in descending order\",\"params\":{\"projectId\":\"The project id\",\"projectUrlHashes\":\"The project URL hashes\",\"urlIdxs\":\"The indexes of the project URL hashes to remove\"}},\"transferProject(bytes32,address)\":{\"params\":{\"newOwner\":\"The new owner\",\"projectId\":\"The project id\"}},\"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)\":{\"params\":{\"attestation\":\"The attestation\",\"projectId\":\"The project id\",\"wallet\":\"The wallet address\"},\"returns\":{\"_0\":\"magic The attestation magic bytes for the wallet address\"}}},\"title\":\"ImplicitProjectRegistry\",\"version\":1},\"userdoc\":{\"errors\":{\"InvalidProjectOwner()\":[{\"notice\":\"Invalid project owner error\"}],\"InvalidProjectUrlIndex()\":[{\"notice\":\"Invalid project URL index error\"}],\"InvalidRedirectUrl()\":[{\"notice\":\"Invalid redirect url error\"}],\"NotProjectOwner()\":[{\"notice\":\"Not project owner error\"}],\"ProjectAlreadyClaimed()\":[{\"notice\":\"Project already claimed error\"}],\"ProjectUrlAlreadyExists()\":[{\"notice\":\"Project URL already exists error\"}],\"ProjectUrlNotFound()\":[{\"notice\":\"Project URL not found error\"}]},\"events\":{\"ProjectClaimed(bytes32,address)\":{\"notice\":\"Emitted when a project is claimed\"},\"ProjectOwnerTransferred(bytes32,address)\":{\"notice\":\"Emitted when a project owner is transferred\"},\"ProjectUrlAdded(bytes32,bytes32)\":{\"notice\":\"Emitted when a project URL is added\"},\"ProjectUrlRemoved(bytes32,bytes32)\":{\"notice\":\"Emitted when a project URL is removed\"}},\"kind\":\"user\",\"methods\":{\"addProjectUrl(bytes32,string)\":{\"notice\":\"Add a project URL\"},\"addProjectUrlBatch(bytes32,string[])\":{\"notice\":\"Add a list of project URLs\"},\"addProjectUrlHash(bytes32,bytes32)\":{\"notice\":\"Add a project URL hash\"},\"addProjectUrlHashBatch(bytes32,bytes32[])\":{\"notice\":\"Add a list of project URL hashes\"},\"claimProject(bytes12)\":{\"notice\":\"Claim a project\"},\"isProjectUrl(bytes32,bytes32)\":{\"notice\":\"Project URLs\"},\"listProjectUrls(bytes32)\":{\"notice\":\"List project URLs\"},\"projectOwner(bytes32)\":{\"notice\":\"Project owner\"},\"removeProjectUrl(bytes32,string)\":{\"notice\":\"Remove a project URL\"},\"removeProjectUrlHash(bytes32,bytes32,uint256)\":{\"notice\":\"Remove a project URL hash\"},\"removeProjectUrlHashBatch(bytes32,bytes32[],uint256[])\":{\"notice\":\"Remove a list of project URL hashes\"},\"transferProject(bytes32,address)\":{\"notice\":\"Transfer a project\"},\"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)\":{\"notice\":\"Check if a project has a code\"}},\"notice\":\"Registry of projects supporting implicit sessions\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"src/registry/ImplicitProjectRegistry.sol\":\"ImplicitProjectRegistry\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]},\"src/registry/IImplicitProjectRegistry.sol\":{\"keccak256\":\"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de\",\"dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6\"]},\"src/registry/IImplicitProjectValidation.sol\":{\"keccak256\":\"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c\",\"dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6\"]},\"src/registry/ImplicitProjectRegistry.sol\":{\"keccak256\":\"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa\",\"dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[],"type":"error","name":"InvalidProjectOwner"},{"inputs":[],"type":"error","name":"InvalidProjectUrlIndex"},{"inputs":[],"type":"error","name":"InvalidRedirectUrl"},{"inputs":[],"type":"error","name":"NotProjectOwner"},{"inputs":[],"type":"error","name":"ProjectAlreadyClaimed"},{"inputs":[],"type":"error","name":"ProjectUrlAlreadyExists"},{"inputs":[],"type":"error","name":"ProjectUrlNotFound"},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32","indexed":true},{"internalType":"address","name":"owner","type":"address","indexed":true}],"type":"event","name":"ProjectClaimed","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32","indexed":true},{"internalType":"address","name":"newOwner","type":"address","indexed":true}],"type":"event","name":"ProjectOwnerTransferred","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32","indexed":true},{"internalType":"bytes32","name":"urlHash","type":"bytes32","indexed":true}],"type":"event","name":"ProjectUrlAdded","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32","indexed":true},{"internalType":"bytes32","name":"urlHash","type":"bytes32","indexed":true}],"type":"event","name":"ProjectUrlRemoved","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"},{"internalType":"string","name":"projectUrl","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"addProjectUrl"},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"},{"internalType":"string[]","name":"projectUrls","type":"string[]"}],"stateMutability":"nonpayable","type":"function","name":"addProjectUrlBatch"},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"},{"internalType":"bytes32","name":"projectUrlHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"addProjectUrlHash"},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"},{"internalType":"bytes32[]","name":"projectUrlHashes","type":"bytes32[]"}],"stateMutability":"nonpayable","type":"function","name":"addProjectUrlHashBatch"},{"inputs":[{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"}],"stateMutability":"nonpayable","type":"function","name":"claimProject","outputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"}]},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"},{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function","name":"isProjectUrl","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"}],"stateMutability":"view","type":"function","name":"listProjectUrls","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}]},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function","name":"projectOwner","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function","name":"projectUrlsList","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}]},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"},{"internalType":"string","name":"projectUrl","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"removeProjectUrl"},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"},{"internalType":"bytes32","name":"projectUrlHash","type":"bytes32"},{"internalType":"uint256","name":"urlIdx","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"removeProjectUrlHash"},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"},{"internalType":"bytes32[]","name":"projectUrlHashes","type":"bytes32[]"},{"internalType":"uint256[]","name":"urlIdxs","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function","name":"removeProjectUrlHashBatch"},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"},{"internalType":"address","name":"newOwner","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"transferProject"},{"inputs":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"struct Attestation","name":"attestation","type":"tuple","components":[{"internalType":"address","name":"approvedSigner","type":"address"},{"internalType":"bytes4","name":"identityType","type":"bytes4"},{"internalType":"bytes32","name":"issuerHash","type":"bytes32"},{"internalType":"bytes32","name":"audienceHash","type":"bytes32"},{"internalType":"bytes","name":"applicationData","type":"bytes"},{"internalType":"struct AuthData","name":"authData","type":"tuple","components":[{"internalType":"string","name":"redirectUrl","type":"string"},{"internalType":"uint64","name":"issuedAt","type":"uint64"}]}]},{"internalType":"bytes32","name":"projectId","type":"bytes32"}],"stateMutability":"view","type":"function","name":"validateAttestation","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}]}],"devdoc":{"kind":"dev","methods":{"addProjectUrl(bytes32,string)":{"params":{"projectId":"The project id","projectUrl":"The project URL"}},"addProjectUrlBatch(bytes32,string[])":{"params":{"projectId":"The project id","projectUrls":"The project URLs"}},"addProjectUrlHash(bytes32,bytes32)":{"params":{"projectId":"The project id","projectUrlHash":"The project URL hash"}},"addProjectUrlHashBatch(bytes32,bytes32[])":{"params":{"projectId":"The project id","projectUrlHashes":"The project URL hashes"}},"claimProject(bytes12)":{"params":{"projectIdUpper":"The project id upper"},"returns":{"projectId":"The concatenation of the `projectIdUpper` and the `msg.sender`"}},"listProjectUrls(bytes32)":{"params":{"projectId":"The project id"},"returns":{"_0":"projectUrls The project URLs"}},"removeProjectUrl(bytes32,string)":{"details":"This function is not optimized. Prefer to use removeProjectUrlHash.","params":{"projectId":"The project id","projectUrl":"The project URL"}},"removeProjectUrlHash(bytes32,bytes32,uint256)":{"params":{"projectId":"The project id","projectUrlHash":"The project URL hash","urlIdx":"The index of the project URL hash to remove"}},"removeProjectUrlHashBatch(bytes32,bytes32[],uint256[])":{"details":"The urlIdxs must be sorted in descending order","params":{"projectId":"The project id","projectUrlHashes":"The project URL hashes","urlIdxs":"The indexes of the project URL hashes to remove"}},"transferProject(bytes32,address)":{"params":{"newOwner":"The new owner","projectId":"The project id"}},"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)":{"params":{"attestation":"The attestation","projectId":"The project id","wallet":"The wallet address"},"returns":{"_0":"magic The attestation magic bytes for the wallet address"}}},"version":1},"userdoc":{"kind":"user","methods":{"addProjectUrl(bytes32,string)":{"notice":"Add a project URL"},"addProjectUrlBatch(bytes32,string[])":{"notice":"Add a list of project URLs"},"addProjectUrlHash(bytes32,bytes32)":{"notice":"Add a project URL hash"},"addProjectUrlHashBatch(bytes32,bytes32[])":{"notice":"Add a list of project URL hashes"},"claimProject(bytes12)":{"notice":"Claim a project"},"isProjectUrl(bytes32,bytes32)":{"notice":"Project URLs"},"listProjectUrls(bytes32)":{"notice":"List project URLs"},"projectOwner(bytes32)":{"notice":"Project owner"},"removeProjectUrl(bytes32,string)":{"notice":"Remove a project URL"},"removeProjectUrlHash(bytes32,bytes32,uint256)":{"notice":"Remove a project URL hash"},"removeProjectUrlHashBatch(bytes32,bytes32[],uint256[])":{"notice":"Remove a list of project URL hashes"},"transferProject(bytes32,address)":{"notice":"Transfer a project"},"validateAttestation(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),bytes32)":{"notice":"Check if a project has a code"}},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"src/registry/ImplicitProjectRegistry.sol":"ImplicitProjectRegistry"},"evmVersion":"paris","libraries":{}},"sources":{"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"},"src/registry/IImplicitProjectRegistry.sol":{"keccak256":"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf","urls":["bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de","dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6"],"license":"Apache-2.0"},"src/registry/IImplicitProjectValidation.sol":{"keccak256":"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2","urls":["bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c","dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6"],"license":"Apache-2.0"},"src/registry/ImplicitProjectRegistry.sol":{"keccak256":"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d","urls":["bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa","dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8"],"license":"Apache-2.0"}},"version":1},"id":28} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/ImplicitProjectRegistry.t.sol/ImplicitProjectRegistryTest.json b/lib/signals-implicit-mode/out/ImplicitProjectRegistry.t.sol/ImplicitProjectRegistryTest.json deleted file mode 100644 index 19d2931887..0000000000 --- a/lib/signals-implicit-mode/out/ImplicitProjectRegistry.t.sol/ImplicitProjectRegistryTest.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"IS_TEST","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"excludeArtifacts","inputs":[],"outputs":[{"name":"excludedArtifacts_","type":"string[]","internalType":"string[]"}],"stateMutability":"view"},{"type":"function","name":"excludeContracts","inputs":[],"outputs":[{"name":"excludedContracts_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"excludeSelectors","inputs":[],"outputs":[{"name":"excludedSelectors_","type":"tuple[]","internalType":"struct StdInvariant.FuzzSelector[]","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"selectors","type":"bytes4[]","internalType":"bytes4[]"}]}],"stateMutability":"view"},{"type":"function","name":"excludeSenders","inputs":[],"outputs":[{"name":"excludedSenders_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"failed","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"registry","inputs":[],"outputs":[{"name":"","type":"address","internalType":"contract ImplicitProjectRegistry"}],"stateMutability":"view"},{"type":"function","name":"setUp","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"targetArtifactSelectors","inputs":[],"outputs":[{"name":"targetedArtifactSelectors_","type":"tuple[]","internalType":"struct StdInvariant.FuzzArtifactSelector[]","components":[{"name":"artifact","type":"string","internalType":"string"},{"name":"selectors","type":"bytes4[]","internalType":"bytes4[]"}]}],"stateMutability":"view"},{"type":"function","name":"targetArtifacts","inputs":[],"outputs":[{"name":"targetedArtifacts_","type":"string[]","internalType":"string[]"}],"stateMutability":"view"},{"type":"function","name":"targetContracts","inputs":[],"outputs":[{"name":"targetedContracts_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"targetInterfaces","inputs":[],"outputs":[{"name":"targetedInterfaces_","type":"tuple[]","internalType":"struct StdInvariant.FuzzInterface[]","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"artifacts","type":"string[]","internalType":"string[]"}]}],"stateMutability":"view"},{"type":"function","name":"targetSelectors","inputs":[],"outputs":[{"name":"targetedSelectors_","type":"tuple[]","internalType":"struct StdInvariant.FuzzSelector[]","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"selectors","type":"bytes4[]","internalType":"bytes4[]"}]}],"stateMutability":"view"},{"type":"function","name":"targetSenders","inputs":[],"outputs":[{"name":"targetedSenders_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"test_addProjectUrl","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"url","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_addProjectUrlBatch","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urls","type":"string[]","internalType":"string[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_addProjectUrlHash","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHash","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_addProjectUrlHashBatch","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHashes","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_claimProject","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_addProjectUrlAlreadyExists","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"url","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_addProjectUrlAlreadyExistsHash","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"url","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_addProjectUrlByNonOwner","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"nonOwner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"url","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_addProjectUrlHashAlreadyExists","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHash","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_addProjectUrlHashAlreadyExistsFull","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"url","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_addProjectUrlHashBatchByNonOwner","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"nonOwner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHashes","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_addProjectUrlHashByNonOwner","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"nonOwner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHash","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_claimInvalidOwner","inputs":[{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_claimProjectTwice","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"otherUser","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_removeNonexistentUrl","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"url","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_removeNonexistentUrlHash","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHash","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_removeProjectUrlByNonOwner","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"nonOwner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"url","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_removeProjectUrlHashBatchByNonOwner","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"nonOwner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHashes","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_removeProjectUrlHashByNonOwner","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"nonOwner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHash","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_removeUrlHashWrongIndex","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHashes","type":"bytes32[]","internalType":"bytes32[]"},{"name":"urlHashIdx","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_transferByNonAdmin","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"nonOwner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_transferInvalidOwner","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_fail_validateAttestationWithInvalidUrl","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"wallet","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"validUrl","type":"string","internalType":"string"},{"name":"invalidUrl","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_removeProjectUrl","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urls","type":"string[]","internalType":"string[]"},{"name":"urlIdx","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_removeProjectUrlHash","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHashes","type":"bytes32[]","internalType":"bytes32[]"},{"name":"urlHashIdx","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_removeProjectUrlHashBatch","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHashes","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_removeProjectUrlHashBatchWithInvalidUrlIdxs","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHashes","type":"bytes32[]","internalType":"bytes32[]"},{"name":"urlIdxs","type":"uint256[]","internalType":"uint256[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_removeProjectUrlHashBatchWithInvalidUrlIdxsOrder","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHashes","type":"bytes32[]","internalType":"bytes32[]"},{"name":"urlIdxs","type":"uint256[]","internalType":"uint256[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_transferProject","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"newOwner","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urlHash","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_validateAttestationMultiple","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"wallet","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"urls","type":"string[]","internalType":"string[]"},{"name":"urlIdx","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_validateAttestationSingle","inputs":[{"name":"owner","type":"address","internalType":"address"},{"name":"wallet","type":"address","internalType":"address"},{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"url","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"event","name":"ProjectClaimed","inputs":[{"name":"projectId","type":"bytes32","indexed":true,"internalType":"bytes32"},{"name":"owner","type":"address","indexed":true,"internalType":"address"}],"anonymous":false},{"type":"event","name":"ProjectOwnerTransferred","inputs":[{"name":"projectId","type":"bytes32","indexed":true,"internalType":"bytes32"},{"name":"newOwner","type":"address","indexed":true,"internalType":"address"}],"anonymous":false},{"type":"event","name":"ProjectUrlAdded","inputs":[{"name":"projectId","type":"bytes32","indexed":true,"internalType":"bytes32"},{"name":"urlHash","type":"bytes32","indexed":true,"internalType":"bytes32"}],"anonymous":false},{"type":"event","name":"ProjectUrlRemoved","inputs":[{"name":"projectId","type":"bytes32","indexed":true,"internalType":"bytes32"},{"name":"urlHash","type":"bytes32","indexed":true,"internalType":"bytes32"}],"anonymous":false},{"type":"event","name":"log","inputs":[{"name":"","type":"string","indexed":false,"internalType":"string"}],"anonymous":false},{"type":"event","name":"log_address","inputs":[{"name":"","type":"address","indexed":false,"internalType":"address"}],"anonymous":false},{"type":"event","name":"log_array","inputs":[{"name":"val","type":"uint256[]","indexed":false,"internalType":"uint256[]"}],"anonymous":false},{"type":"event","name":"log_array","inputs":[{"name":"val","type":"int256[]","indexed":false,"internalType":"int256[]"}],"anonymous":false},{"type":"event","name":"log_array","inputs":[{"name":"val","type":"address[]","indexed":false,"internalType":"address[]"}],"anonymous":false},{"type":"event","name":"log_bytes","inputs":[{"name":"","type":"bytes","indexed":false,"internalType":"bytes"}],"anonymous":false},{"type":"event","name":"log_bytes32","inputs":[{"name":"","type":"bytes32","indexed":false,"internalType":"bytes32"}],"anonymous":false},{"type":"event","name":"log_int","inputs":[{"name":"","type":"int256","indexed":false,"internalType":"int256"}],"anonymous":false},{"type":"event","name":"log_named_address","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"address","indexed":false,"internalType":"address"}],"anonymous":false},{"type":"event","name":"log_named_array","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"uint256[]","indexed":false,"internalType":"uint256[]"}],"anonymous":false},{"type":"event","name":"log_named_array","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"int256[]","indexed":false,"internalType":"int256[]"}],"anonymous":false},{"type":"event","name":"log_named_array","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"address[]","indexed":false,"internalType":"address[]"}],"anonymous":false},{"type":"event","name":"log_named_bytes","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"bytes","indexed":false,"internalType":"bytes"}],"anonymous":false},{"type":"event","name":"log_named_bytes32","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"bytes32","indexed":false,"internalType":"bytes32"}],"anonymous":false},{"type":"event","name":"log_named_decimal_int","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"int256","indexed":false,"internalType":"int256"},{"name":"decimals","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"log_named_decimal_uint","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"uint256","indexed":false,"internalType":"uint256"},{"name":"decimals","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"log_named_int","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"int256","indexed":false,"internalType":"int256"}],"anonymous":false},{"type":"event","name":"log_named_string","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"string","indexed":false,"internalType":"string"}],"anonymous":false},{"type":"event","name":"log_named_uint","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"log_string","inputs":[{"name":"","type":"string","indexed":false,"internalType":"string"}],"anonymous":false},{"type":"event","name":"log_uint","inputs":[{"name":"","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"logs","inputs":[{"name":"","type":"bytes","indexed":false,"internalType":"bytes"}],"anonymous":false}],"bytecode":{"object":"0x60806040526001600c60006101000a81548160ff0219169083151502179055506001601f60006101000a81548160ff021916908315150217905550348015604557600080fd5b5061f375806100556000396000f3fe608060405234801561001057600080fd5b506004361061027f5760003560e01c80637b1039991161015c578063ba414fa6116100ce578063e20c9f7111610087578063e20c9f71146106cc578063e575719f146106ea578063eed3579214610706578063f72c62f114610722578063fa7626d41461073e578063ff679dab1461075c5761027f565b8063ba414fa614610622578063c5a3633914610640578063ca8c203d1461065c578063ce7bcae314610678578063d360961714610694578063d887d395146106b05761027f565b8063916a17c611610120578063916a17c6146105745780639cc595a414610592578063ad0d1166146105ae578063ad2ac469146105ca578063b0464fdc146105e6578063b5508aa9146106045761027f565b80637b103999146104e45780637d1d95b514610502578063820c2c2c1461051e57806385226c811461053a578063891e3354146105585761027f565b80633e5e3c23116101f557806356f52e42116101b957806356f52e421461043a57806358bab9621461045657806361fd155b1461047257806366d9a9a01461048e57806372976749146104ac578063785cf657146104c85761027f565b80633e5e3c23146103aa5780633f7286f4146103c85780634b05e990146103e65780634cf9fbff14610402578063538d6c481461041e5761027f565b80632955e468116102475780632955e468146103005780632a475b0d1461031c5780632ade3880146103385780632c6eec1e146103565780632d03611e146103725780632e84025c1461038e5761027f565b80630a9254e4146102845780630b3307e81461028e57806312fe420e146102aa5780631ed7831c146102c657806327d334b2146102e4575b600080fd5b61028c610778565b005b6102a860048036038101906102a3919061b20b565b6107e3565b005b6102c460048036038101906102bf919061b28e565b610d6c565b005b6102ce611238565b6040516102db919061b39f565b60405180910390f35b6102fe60048036038101906102f9919061b484565b6112c6565b005b61031a6004803603810190610315919061b28e565b6117a6565b005b6103366004803603810190610331919061b6b9565b611d90565b005b6103406123cc565b60405161034d919061b97c565b60405180910390f35b610370600480360381019061036b919061b99e565b61255a565b005b61038c6004803603810190610387919061ba05565b61297d565b005b6103a860048036038101906103a3919061ba88565b612e38565b005b6103b2613258565b6040516103bf919061b39f565b60405180910390f35b6103d06132e6565b6040516103dd919061b39f565b60405180910390f35b61040060048036038101906103fb919061bb0b565b613374565b005b61041c6004803603810190610417919061bb7a565b613768565b005b6104386004803603810190610433919061b99e565b613cd5565b005b610454600480360381019061044f919061bb0b565b614433565b005b610470600480360381019061046b919061bbe9565b614929565b005b61048c6004803603810190610487919061b484565b614c9f565b005b610496615183565b6040516104a3919061be2c565b60405180910390f35b6104c660048036038101906104c1919061be4e565b61530e565b005b6104e260048036038101906104dd919061bb0b565b615681565b005b6104ec615aee565b6040516104f9919061beed565b60405180910390f35b61051c6004803603810190610517919061ba05565b615b14565b005b6105386004803603810190610533919061bf08565b616191565b005b610542616650565b60405161054f919061c025565b60405180910390f35b610572600480360381019061056d919061c047565b616729565b005b61057c616c71565b604051610589919061c1f9565b60405180910390f35b6105ac60048036038101906105a7919061b20b565b616dc0565b005b6105c860048036038101906105c3919061b99e565b61740a565b005b6105e460048036038101906105df919061bb0b565b61782a565b005b6105ee617c1e565b6040516105fb919061c1f9565b60405180910390f35b61060c617d6d565b604051610619919061c025565b60405180910390f35b61062a617e46565b604051610637919061c236565b60405180910390f35b61065a6004803603810190610655919061c251565b617f54565b005b6106766004803603810190610671919061c2c0565b6184b1565b005b610692600480360381019061068d919061ba88565b61865b565b005b6106ae60048036038101906106a9919061bbe9565b618a96565b005b6106ca60048036038101906106c5919061be4e565b618e82565b005b6106d46191cb565b6040516106e1919061b39f565b60405180910390f35b61070460048036038101906106ff919061bb0b565b619259565b005b610720600480360381019061071b919061c251565b61964d565b005b61073c6004803603810190610737919061ba88565b619d3f565b005b61074661a15f565b604051610753919061c236565b60405180910390f35b6107766004803603810190610771919061bbe9565b61a172565b005b6040516107849061aeca565b604051809103906000f0801580156107a0573d6000803e3d6000fd5b50601f60016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401610860919061c236565b60006040518083038186803b15801561087857600080fd5b505afa15801561088c573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008451116040518263ffffffff1660e01b81526004016108e1919061c236565b60006040518083038186803b1580156108f957600080fd5b505afa15801561090d573d6000803e3d6000fd5b50505050600a8251111561092057600a82525b6109298261a5cc565b91506109448160006001855161093f919061c31c565b61a6e9565b90506000610952848661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56866040518263ffffffff1660e01b81526004016109a1919061c35f565b600060405180830381600087803b1580156109bb57600080fd5b505af11580156109cf573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b8152600401610a2e919061c389565b6020604051808303816000875af1158015610a4d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a71919061c3b9565b5060005b8351811015610b3457601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f183868481518110610ad057610acf61c3e6565b5b60200260200101516040518363ffffffff1660e01b8152600401610af592919061c424565b600060405180830381600087803b158015610b0f57600080fd5b505af1158015610b23573d6000803e3d6000fd5b505050508080600101915050610a75565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015610b9157600080fd5b505af1158015610ba5573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063526c768760e01b6040518263ffffffff1660e01b8152600401610bfd919061c45c565b600060405180830381600087803b158015610c1757600080fd5b505af1158015610c2b573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b8152600401610c7c919061c35f565b600060405180830381600087803b158015610c9657600080fd5b505af1158015610caa573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b31f01b82858581518110610d0057610cff61c3e6565b5b6020026020010151600186610d15919061c477565b6040518463ffffffff1660e01b8152600401610d339392919061c4ba565b600060405180830381600087803b158015610d4d57600080fd5b505af1158015610d61573d6000803e3d6000fd5b505050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401610de8919061c236565b60006040518083038186803b158015610e0057600080fd5b505afa158015610e14573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401610e95919061c236565b60006040518083038186803b158015610ead57600080fd5b505afa158015610ec1573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401610f42919061c236565b60006040518083038186803b158015610f5a57600080fd5b505afa158015610f6e573d6000803e3d6000fd5b505050506000610f7e828561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401610fcd919061c35f565b600060405180830381600087803b158015610fe757600080fd5b505af1158015610ffb573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018836040518263ffffffff1660e01b815260040161105a919061c389565b6020604051808303816000875af1158015611079573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061109d919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b81526004016110f2919061c45c565b600060405180830381600087803b15801561110c57600080fd5b505af1158015611120573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7846040518263ffffffff1660e01b8152600401611171919061c35f565b600060405180830381600087803b15801561118b57600080fd5b505af115801561119f573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639630aff882856040518363ffffffff1660e01b815260040161120092919061c4f1565b600060405180830381600087803b15801561121a57600080fd5b505af115801561122e573d6000803e3d6000fd5b5050505050505050565b606060168054806020026020016040519081016040528092919081815260200182805480156112bc57602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311611272575b5050505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401611343919061c236565b60006040518083038186803b15801561135b57600080fd5b505afa15801561136f573d6000803e3d6000fd5b50505050600081519050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600183116040518263ffffffff1660e01b81526004016113c9919061c236565b60006040518083038186803b1580156113e157600080fd5b505afa1580156113f5573d6000803e3d6000fd5b505050508083526000805b6001845161140e919061c31c565b8110156114735783600182611423919061c477565b815181106114345761143361c3e6565b5b602002602001015184828151811061144f5761144e61c3e6565b5b602002602001015110156114665760019150611473565b8080600101915050611400565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562826040518263ffffffff1660e01b81526004016114c1919061c236565b60006040518083038186803b1580156114d957600080fd5b505afa1580156114ed573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56876040518263ffffffff1660e01b815260040161153e919061c35f565b600060405180830381600087803b15801561155857600080fd5b505af115801561156c573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018876040518263ffffffff1660e01b81526004016115cd919061c389565b6020604051808303816000875af11580156115ec573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611610919061c3b9565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063526c768760e01b6040518263ffffffff1660e01b8152600401611666919061c45c565b600060405180830381600087803b15801561168057600080fd5b505af1158015611694573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4c9c5c48287876040518463ffffffff1660e01b81526004016116f79392919061c696565b600060405180830381600087803b15801561171157600080fd5b505af1158015611725573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561178557600080fd5b505af1158015611799573d6000803e3d6000fd5b5050505050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401611822919061c236565b60006040518083038186803b15801561183a57600080fd5b505afa15801561184e573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016118cf919061c236565b60006040518083038186803b1580156118e757600080fd5b505afa1580156118fb573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b815260040161197c919061c236565b60006040518083038186803b15801561199457600080fd5b505afa1580156119a8573d6000803e3d6000fd5b5050505060006119b8828561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401611a07919061c35f565b600060405180830381600087803b158015611a2157600080fd5b505af1158015611a35573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018836040518263ffffffff1660e01b8152600401611a94919061c389565b6020604051808303816000875af1158015611ab3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611ad7919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401611b25919061c35f565b600060405180830381600087803b158015611b3f57600080fd5b505af1158015611b53573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639630aff882856040518363ffffffff1660e01b8152600401611bb492919061c4f1565b600060405180830381600087803b158015611bce57600080fd5b505af1158015611be2573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063feabeb4b60e01b6040518263ffffffff1660e01b8152600401611c3a919061c45c565b600060405180830381600087803b158015611c5457600080fd5b505af1158015611c68573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401611cb9919061c35f565b600060405180830381600087803b158015611cd357600080fd5b505af1158015611ce7573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018836040518263ffffffff1660e01b8152600401611d46919061c389565b6020604051808303816000875af1158015611d65573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d89919061c3b9565b5050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401611e0d919061c236565b60006040518083038186803b158015611e2557600080fd5b505afa158015611e39573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008451116040518263ffffffff1660e01b8152600401611e8e919061c236565b60006040518083038186803b158015611ea657600080fd5b505afa158015611eba573d6000803e3d6000fd5b50505050600a82511115611ecd57600a82525b611ed68261a773565b9150611ef181600060018551611eec919061c31c565b61a6e9565b90506000611eff848661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56866040518263ffffffff1660e01b8152600401611f4e919061c35f565b600060405180830381600087803b158015611f6857600080fd5b505af1158015611f7c573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b8152600401611fdb919061c389565b6020604051808303816000875af1158015611ffa573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061201e919061c3b9565b5060005b83518110156120e157601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d8386848151811061207d5761207c61c3e6565b5b60200260200101516040518363ffffffff1660e01b81526004016120a292919061c725565b600060405180830381600087803b1580156120bc57600080fd5b505af11580156120d0573d6000803e3d6000fd5b505050508080600101915050612022565b5060006121078484815181106120fa576120f961c3e6565b5b602002602001015161a8aa565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561216557600080fd5b505af1158015612179573d6000803e3d6000fd5b5050505080827f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dac6c587838686815181106121fd576121fc61c3e6565b5b60200260200101516040518363ffffffff1660e01b815260040161222292919061c725565b600060405180830381600087803b15801561223c57600080fd5b505af1158015612250573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156122b057600080fd5b505af11580156122c4573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6846040518263ffffffff1660e01b8152600401612325919061c755565b600060405180830381865afa158015612342573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f8201168201806040525081019061236b919061c807565b9050612385815160018751612380919061c31c565b61a8da565b60005b81518110156123c2576123b58282815181106123a7576123a661c3e6565b5b60200260200101518461a974565b8080600101915050612388565b5050505050505050565b6060601e805480602002602001604051908101604052809291908181526020016000905b8282101561255157838290600052602060002090600202016040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200160018201805480602002602001604051908101604052809291908181526020016000905b8282101561253a5783829060005260206000200180546124ad9061c87f565b80601f01602080910402602001604051908101604052809291908181526020018280546124d99061c87f565b80156125265780601f106124fb57610100808354040283529160200191612526565b820191906000526020600020905b81548152906001019060200180831161250957829003601f168201915b50505050508152602001906001019061248e565b5050505081525050815260200190600101906123f0565b50505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016125d7919061c236565b60006040518083038186803b1580156125ef57600080fd5b505afa158015612603573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401612683919061c236565b60006040518083038186803b15801561269b57600080fd5b505afa1580156126af573d6000803e3d6000fd5b5050505060006126bf838661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b815260040161270e919061c35f565b600060405180830381600087803b15801561272857600080fd5b505af115801561273c573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b815260040161279b919061c389565b6020604051808303816000875af11580156127ba573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127de919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b8152600401612833919061c45c565b600060405180830381600087803b15801561284d57600080fd5b505af1158015612861573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b81526004016128b2919061c35f565b600060405180830381600087803b1580156128cc57600080fd5b505af11580156128e0573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b31f01b828460006040518463ffffffff1660e01b81526004016129449392919061c8eb565b600060405180830381600087803b15801561295e57600080fd5b505af1158015612972573d6000803e3d6000fd5b505050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016129fa919061c236565b60006040518083038186803b158015612a1257600080fd5b505afa158015612a26573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401612aa6919061c236565b60006040518083038186803b158015612abe57600080fd5b505afa158015612ad2573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401612b27919061c236565b60006040518083038186803b158015612b3f57600080fd5b505afa158015612b53573d6000803e3d6000fd5b50505050600a81511115612b6657600a81525b612b6f8161a5cc565b90506000612b7d838661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b8152600401612bcc919061c35f565b600060405180830381600087803b158015612be657600080fd5b505af1158015612bfa573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401612c59919061c389565b6020604051808303816000875af1158015612c78573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c9c919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b8152600401612cf1919061c45c565b600060405180830381600087803b158015612d0b57600080fd5b505af1158015612d1f573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401612d70919061c35f565b600060405180830381600087803b158015612d8a57600080fd5b505af1158015612d9e573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663065d6c6982846040518363ffffffff1660e01b8152600401612dff92919061c922565b600060405180830381600087803b158015612e1957600080fd5b505af1158015612e2d573d6000803e3d6000fd5b505050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401612eb5919061c236565b60006040518083038186803b158015612ecd57600080fd5b505afa158015612ee1573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401612f61919061c236565b60006040518083038186803b158015612f7957600080fd5b505afa158015612f8d573d6000803e3d6000fd5b505050506000612f9d838661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b8152600401612fec919061c35f565b600060405180830381600087803b15801561300657600080fd5b505af115801561301a573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401613079919061c389565b6020604051808303816000875af1158015613098573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130bc919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b8152600401613111919061c45c565b600060405180830381600087803b15801561312b57600080fd5b505af115801561313f573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401613190919061c35f565b600060405180830381600087803b1580156131aa57600080fd5b505af11580156131be573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dac6c58782846040518363ffffffff1660e01b815260040161321f92919061c725565b600060405180830381600087803b15801561323957600080fd5b505af115801561324d573d6000803e3d6000fd5b505050505050505050565b606060188054806020026020016040519081016040528092919081815260200182805480156132dc57602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311613292575b5050505050905090565b6060601780548060200260200160405190810160405280929190818152602001828054801561336a57602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311613320575b5050505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016133f1919061c236565b60006040518083038186803b15801561340957600080fd5b505afa15801561341d573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401613472919061c236565b60006040518083038186803b15801561348a57600080fd5b505afa15801561349e573d6000803e3d6000fd5b5050505060006134ae838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b81526004016134fd919061c35f565b600060405180830381600087803b15801561351757600080fd5b505af115801561352b573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b815260040161358a919061c389565b6020604051808303816000875af11580156135a9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135cd919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0634745a4ee60e01b6040518263ffffffff1660e01b8152600401613622919061c45c565b600060405180830381600087803b15801561363c57600080fd5b505af1158015613650573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b81526004016136a1919061c35f565b600060405180830381600087803b1580156136bb57600080fd5b505af11580156136cf573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dac6c58782846040518363ffffffff1660e01b815260040161373092919061c725565b600060405180830381600087803b15801561374a57600080fd5b505af115801561375e573d6000803e3d6000fd5b5050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016137e5919061c236565b60006040518083038186803b1580156137fd57600080fd5b505afa158015613811573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401613866919061c236565b60006040518083038186803b15801561387e57600080fd5b505afa158015613892573d6000803e3d6000fd5b50505050600a815111156138a557600a81525b6138ae8161a773565b905060006138bc838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56856040518263ffffffff1660e01b815260040161390b919061c35f565b600060405180830381600087803b15801561392557600080fd5b505af1158015613939573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401613998919061c389565b6020604051808303816000875af11580156139b7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906139db919061c3b9565b5060005b8251811015613ab957737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015613a4457600080fd5b505af1158015613a58573d6000803e3d6000fd5b50505050613a7f838281518110613a7257613a7161c3e6565b5b602002602001015161a8aa565b827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a380806001019150506139df565b50601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166356cd2b9282846040518363ffffffff1660e01b8152600401613b1792919061c952565b600060405180830381600087803b158015613b3157600080fd5b505af1158015613b45573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015613ba557600080fd5b505af1158015613bb9573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6836040518263ffffffff1660e01b8152600401613c1a919061c755565b600060405180830381865afa158015613c37573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190613c60919061c807565b9050613c6e8151845161a8da565b60005b8151811015613ccd57613cc0828281518110613c9057613c8f61c3e6565b5b6020026020010151613cbb868481518110613cae57613cad61c3e6565b5b602002602001015161a8aa565b61aa0e565b8080600101915050613c71565b505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401613d52919061c236565b60006040518083038186803b158015613d6a57600080fd5b505afa158015613d7e573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401613dff919061c236565b60006040518083038186803b158015613e1757600080fd5b505afa158015613e2b573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401613eab919061c236565b60006040518083038186803b158015613ec357600080fd5b505afa158015613ed7573d6000803e3d6000fd5b505050506000613ee7838661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b8152600401613f36919061c35f565b600060405180830381600087803b158015613f5057600080fd5b505af1158015613f64573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401613fc3919061c389565b6020604051808303816000875af1158015613fe2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190614006919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561406357600080fd5b505af1158015614077573d6000803e3d6000fd5b505050508373ffffffffffffffffffffffffffffffffffffffff16817f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b815260040161410c919061c35f565b600060405180830381600087803b15801561412657600080fd5b505af115801561413a573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639630aff882866040518363ffffffff1660e01b815260040161419b92919061c4f1565b600060405180830381600087803b1580156141b557600080fd5b505af11580156141c9573d6000803e3d6000fd5b50505050614272601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ebc27b82836040518263ffffffff1660e01b815260040161422b919061c755565b602060405180830381865afa158015614248573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061426c919061c997565b8561aaa8565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b81526004016142bf919061c35f565b600060405180830381600087803b1580156142d957600080fd5b505af11580156142ed573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f182846040518363ffffffff1660e01b815260040161434e92919061c424565b600060405180830381600087803b15801561436857600080fd5b505af115801561437c573d6000803e3d6000fd5b5050505061442c601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6836040518263ffffffff1660e01b81526004016143de919061c755565b600060405180830381865afa1580156143fb573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190614424919061c807565b51600161a8da565b5050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016144b0919061c236565b60006040518083038186803b1580156144c857600080fd5b505afa1580156144dc573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401614531919061c236565b60006040518083038186803b15801561454957600080fd5b505afa15801561455d573d6000803e3d6000fd5b50505050600061456d838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b81526004016145bc919061c35f565b600060405180830381600087803b1580156145d657600080fd5b505af11580156145ea573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401614649919061c389565b6020604051808303816000875af1158015614668573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061468c919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156146e957600080fd5b505af11580156146fd573d6000803e3d6000fd5b5050505061470a8261a8aa565b817fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a3737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401614784919061c35f565b600060405180830381600087803b15801561479e57600080fd5b505af11580156147b2573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82846040518363ffffffff1660e01b815260040161481392919061c725565b600060405180830381600087803b15801561482d57600080fd5b505af1158015614841573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6836040518263ffffffff1660e01b81526004016148a2919061c755565b600060405180830381865afa1580156148bf573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052508101906148e8919061c807565b90506148f38161a5cc565b90506149228160008151811061490c5761490b61c3e6565b5b602002602001015161491d8561a8aa565b61aa0e565b5050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016149a6919061c236565b60006040518083038186803b1580156149be57600080fd5b505afa1580156149d2573d6000803e3d6000fd5b5050505060006149e2838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401614a31919061c35f565b600060405180830381600087803b158015614a4b57600080fd5b505af1158015614a5f573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401614abe919061c389565b6020604051808303816000875af1158015614add573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190614b01919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063526c768760e01b6040518263ffffffff1660e01b8152600401614b56919061c45c565b600060405180830381600087803b158015614b7057600080fd5b505af1158015614b84573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401614bd5919061c35f565b600060405180830381600087803b158015614bef57600080fd5b505af1158015614c03573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b31f01b828460006040518463ffffffff1660e01b8152600401614c679392919061c8eb565b600060405180830381600087803b158015614c8157600080fd5b505af1158015614c95573d6000803e3d6000fd5b5050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401614d1c919061c236565b60006040518083038186803b158015614d3457600080fd5b505afa158015614d48573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008451116040518263ffffffff1660e01b8152600401614d9d919061c236565b60006040518083038186803b158015614db557600080fd5b505afa158015614dc9573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401614e1e919061c236565b60006040518083038186803b158015614e3657600080fd5b505afa158015614e4a573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628351835114156040518263ffffffff1660e01b8152600401614ea0919061c236565b60006040518083038186803b158015614eb857600080fd5b505afa158015614ecc573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56856040518263ffffffff1660e01b8152600401614f1d919061c35f565b600060405180830381600087803b158015614f3757600080fd5b505af1158015614f4b573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b8152600401614fac919061c389565b6020604051808303816000875af1158015614fcb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190614fef919061c3b9565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063526c768760e01b6040518263ffffffff1660e01b8152600401615045919061c45c565b600060405180830381600087803b15801561505f57600080fd5b505af1158015615073573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4c9c5c48285856040518463ffffffff1660e01b81526004016150d69392919061c696565b600060405180830381600087803b1580156150f057600080fd5b505af1158015615104573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561516457600080fd5b505af1158015615178573d6000803e3d6000fd5b505050505050505050565b6060601b805480602002602001604051908101604052809291908181526020016000905b8282101561530557838290600052602060002090600202016040518060400160405290816000820180546151da9061c87f565b80601f01602080910402602001604051908101604052809291908181526020018280546152069061c87f565b80156152535780601f1061522857610100808354040283529160200191615253565b820191906000526020600020905b81548152906001019060200180831161523657829003601f168201915b50505050508152602001600182018054806020026020016040519081016040528092919081815260200182805480156152ed57602002820191906000526020600020906000905b82829054906101000a900460e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168152602001906004019060208260030104928301926001038202915080841161529a5790505b505050505081525050815260200190600101906151a7565b50505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b815260040161538b919061c236565b60006040518083038186803b1580156153a357600080fd5b505afa1580156153b7573d6000803e3d6000fd5b5050505060006153c7828461a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7846040518263ffffffff1660e01b8152600401615416919061c35f565b600060405180830381600087803b15801561543057600080fd5b505af1158015615444573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018836040518263ffffffff1660e01b81526004016154a3919061c389565b6020604051808303816000875af11580156154c2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906154e6919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7846040518263ffffffff1660e01b8152600401615534919061c35f565b600060405180830381600087803b15801561554e57600080fd5b505af1158015615562573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063ff7d580d60e01b6040518263ffffffff1660e01b81526004016155ba919061c45c565b600060405180830381600087803b1580156155d457600080fd5b505af11580156155e8573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639630aff88260006040518363ffffffff1660e01b815260040161564a92919061c4f1565b600060405180830381600087803b15801561566457600080fd5b505af1158015615678573d6000803e3d6000fd5b50505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016156fe919061c236565b60006040518083038186803b15801561571657600080fd5b505afa15801561572a573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b815260040161577f919061c236565b60006040518083038186803b15801561579757600080fd5b505afa1580156157ab573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56846040518263ffffffff1660e01b81526004016157fc919061c35f565b600060405180830381600087803b15801561581657600080fd5b505af115801561582a573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b815260040161588b919061c389565b6020604051808303816000875af11580156158aa573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906158ce919061c3b9565b9050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82846040518363ffffffff1660e01b815260040161592d92919061c725565b600060405180830381600087803b15801561594757600080fd5b505af115801561595b573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0632d86c03a60e01b6040518263ffffffff1660e01b81526004016159b3919061c45c565b600060405180830381600087803b1580156159cd57600080fd5b505af11580156159e1573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82846040518363ffffffff1660e01b8152600401615a4292919061c725565b600060405180830381600087803b158015615a5c57600080fd5b505af1158015615a70573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015615ad057600080fd5b505af1158015615ae4573d6000803e3d6000fd5b5050505050505050565b601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401615b91919061c236565b60006040518083038186803b158015615ba957600080fd5b505afa158015615bbd573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401615c3d919061c236565b60006040518083038186803b158015615c5557600080fd5b505afa158015615c69573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401615cbe919061c236565b60006040518083038186803b158015615cd657600080fd5b505afa158015615cea573d6000803e3d6000fd5b50505050600a81511115615cfd57600a81525b615d068161a5cc565b90506000815167ffffffffffffffff811115615d2557615d2461b05c565b5b604051908082528060200260200182016040528015615d535781602001602082028036833780820191505090505b50905060005b8251811015615d8f5780828281518110615d7657615d7561c3e6565b5b6020026020010181815250508080600101915050615d59565b506000615d9c848761a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56876040518263ffffffff1660e01b8152600401615deb919061c35f565b600060405180830381600087803b158015615e0557600080fd5b505af1158015615e19573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b8152600401615e78919061c389565b6020604051808303816000875af1158015615e97573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190615ebb919061c3b9565b5060005b8351811015615f7e57601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f183868481518110615f1a57615f1961c3e6565b5b60200260200101516040518363ffffffff1660e01b8152600401615f3f92919061c424565b600060405180830381600087803b158015615f5957600080fd5b505af1158015615f6d573d6000803e3d6000fd5b505050508080600101915050615ebf565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015615fdb57600080fd5b505af1158015615fef573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b8152600401616047919061c45c565b600060405180830381600087803b15801561606157600080fd5b505af1158015616075573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b81526004016160c6919061c35f565b600060405180830381600087803b1580156160e057600080fd5b505af11580156160f4573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4c9c5c48285856040518463ffffffff1660e01b81526004016161579392919061c696565b600060405180830381600087803b15801561617157600080fd5b505af1158015616185573d6000803e3d6000fd5b50505050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b815260040161620e919061c236565b60006040518083038186803b15801561622657600080fd5b505afa15801561623a573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008451116040518263ffffffff1660e01b815260040161628f919061c236565b60006040518083038186803b1580156162a757600080fd5b505afa1580156162bb573d6000803e3d6000fd5b50505050600a825111156162ce57600a82525b6162d78261a773565b91506162f2816000600185516162ed919061c31c565b61a6e9565b90506000616300848761a73e565b905061630a61aed7565b83838151811061631d5761631c61c3e6565b5b60200260200101518160a0015160000181905250737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56886040518263ffffffff1660e01b815260040161637e919061c35f565b600060405180830381600087803b15801561639857600080fd5b505af11580156163ac573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018866040518263ffffffff1660e01b815260040161640b919061c389565b6020604051808303816000875af115801561642a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061644e919061c3b9565b5060005b845181101561651157601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d848784815181106164ad576164ac61c3e6565b5b60200260200101516040518363ffffffff1660e01b81526004016164d292919061c725565b600060405180830381600087803b1580156164ec57600080fd5b505af1158015616500573d6000803e3d6000fd5b505050508080600101915050616452565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561656e57600080fd5b505af1158015616582573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633808a90b8884866040518463ffffffff1660e01b81526004016165e79392919061cb09565b602060405180830381865afa158015616604573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190616628919061c3b9565b905061664681616641898561ab6e90919063ffffffff16565b61aa0e565b5050505050505050565b6060601a805480602002602001604051908101604052809291908181526020016000905b828210156167205783829060005260206000200180546166939061c87f565b80601f01602080910402602001604051908101604052809291908181526020018280546166bf9061c87f565b801561670c5780601f106166e15761010080835404028352916020019161670c565b820191906000526020600020905b8154815290600101906020018083116166ef57829003601f168201915b505050505081526020019060010190616674565b50505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016167a6919061c236565b60006040518083038186803b1580156167be57600080fd5b505afa1580156167d2573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008451118015616818575060008351115b6040518263ffffffff1660e01b8152600401616834919061c236565b60006040518083038186803b15801561684c57600080fd5b505afa158015616860573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628280519060200120848051906020012014156040518263ffffffff1660e01b81526004016168c2919061c236565b60006040518083038186803b1580156168da57600080fd5b505afa1580156168ee573d6000803e3d6000fd5b5050505060006168fe848761a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7876040518263ffffffff1660e01b815260040161694d919061c35f565b600060405180830381600087803b15801561696757600080fd5b505af115801561697b573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b81526004016169da919061c389565b6020604051808303816000875af11580156169f9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190616a1d919061c3b9565b50616a2661aed7565b828160a0015160000181905250737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7886040518263ffffffff1660e01b8152600401616a80919061c35f565b600060405180830381600087803b158015616a9a57600080fd5b505af1158015616aae573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d83866040518363ffffffff1660e01b8152600401616b0f92919061c725565b600060405180830381600087803b158015616b2957600080fd5b505af1158015616b3d573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063d7abef4e60e01b6040518263ffffffff1660e01b8152600401616b95919061c45c565b600060405180830381600087803b158015616baf57600080fd5b505af1158015616bc3573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633808a90b8783856040518463ffffffff1660e01b8152600401616c269392919061cb09565b602060405180830381865afa158015616c43573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190616c67919061c3b9565b5050505050505050565b6060601d805480602002602001604051908101604052809291908181526020016000905b82821015616db757838290600052602060002090600202016040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200160018201805480602002602001604051908101604052809291908181526020018280548015616d9f57602002820191906000526020600020906000905b82829054906101000a900460e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191681526020019060040190602082600301049283019260010382029150808411616d4c5790505b50505050508152505081526020019060010190616c95565b50505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401616e3d919061c236565b60006040518083038186803b158015616e5557600080fd5b505afa158015616e69573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008451116040518263ffffffff1660e01b8152600401616ebe919061c236565b60006040518083038186803b158015616ed657600080fd5b505afa158015616eea573d6000803e3d6000fd5b50505050600a82511115616efd57600a82525b616f068261a5cc565b9150616f2181600060018551616f1c919061c31c565b61a6e9565b90506000616f2f848661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56866040518263ffffffff1660e01b8152600401616f7e919061c35f565b600060405180830381600087803b158015616f9857600080fd5b505af1158015616fac573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b815260040161700b919061c389565b6020604051808303816000875af115801561702a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061704e919061c3b9565b5060005b835181101561711157601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f1838684815181106170ad576170ac61c3e6565b5b60200260200101516040518363ffffffff1660e01b81526004016170d292919061c424565b600060405180830381600087803b1580156170ec57600080fd5b505af1158015617100573d6000803e3d6000fd5b505050508080600101915050617052565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561716e57600080fd5b505af1158015617182573d6000803e3d6000fd5b505050508282815181106171995761719861c3e6565b5b6020026020010151817f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b31f01b828585815181106172205761721f61c3e6565b5b6020026020010151856040518463ffffffff1660e01b81526004016172479392919061c4ba565b600060405180830381600087803b15801561726157600080fd5b505af1158015617275573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156172d557600080fd5b505af11580156172e9573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6836040518263ffffffff1660e01b815260040161734a919061c755565b600060405180830381865afa158015617367573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190617390919061c807565b90506173aa8151600186516173a5919061c31c565b61a8da565b60005b8151811015617401576173f48282815181106173cc576173cb61c3e6565b5b60200260200101518686815181106173e7576173e661c3e6565b5b602002602001015161a974565b80806001019150506173ad565b50505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401617487919061c236565b60006040518083038186803b15801561749f57600080fd5b505afa1580156174b3573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401617533919061c236565b60006040518083038186803b15801561754b57600080fd5b505afa15801561755f573d6000803e3d6000fd5b50505050600061756f838661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b81526004016175be919061c35f565b600060405180830381600087803b1580156175d857600080fd5b505af11580156175ec573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b815260040161764b919061c389565b6020604051808303816000875af115801561766a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061768e919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b81526004016176e3919061c45c565b600060405180830381600087803b1580156176fd57600080fd5b505af1158015617711573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401617762919061c35f565b600060405180830381600087803b15801561777c57600080fd5b505af1158015617790573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f182846040518363ffffffff1660e01b81526004016177f192919061c424565b600060405180830381600087803b15801561780b57600080fd5b505af115801561781f573d6000803e3d6000fd5b505050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016178a7919061c236565b60006040518083038186803b1580156178bf57600080fd5b505afa1580156178d3573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56846040518263ffffffff1660e01b8152600401617924919061c35f565b600060405180830381600087803b15801561793e57600080fd5b505af1158015617952573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b81526004016179b3919061c389565b6020604051808303816000875af11580156179d2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906179f6919061c3b9565b9050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f182617a408561a8aa565b6040518363ffffffff1660e01b8152600401617a5d92919061c424565b600060405180830381600087803b158015617a7757600080fd5b505af1158015617a8b573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0632d86c03a60e01b6040518263ffffffff1660e01b8152600401617ae3919061c45c565b600060405180830381600087803b158015617afd57600080fd5b505af1158015617b11573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82846040518363ffffffff1660e01b8152600401617b7292919061c725565b600060405180830381600087803b158015617b8c57600080fd5b505af1158015617ba0573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015617c0057600080fd5b505af1158015617c14573d6000803e3d6000fd5b5050505050505050565b6060601c805480602002602001604051908101604052809291908181526020016000905b82821015617d6457838290600052602060002090600202016040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200160018201805480602002602001604051908101604052809291908181526020018280548015617d4c57602002820191906000526020600020906000905b82829054906101000a900460e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191681526020019060040190602082600301049283019260010382029150808411617cf95790505b50505050508152505081526020019060010190617c42565b50505050905090565b60606019805480602002602001604051908101604052809291908181526020016000905b82821015617e3d578382906000526020600020018054617db09061c87f565b80601f0160208091040260200160405190810160405280929190818152602001828054617ddc9061c87f565b8015617e295780601f10617dfe57610100808354040283529160200191617e29565b820191906000526020600020905b815481529060010190602001808311617e0c57829003601f168201915b505050505081526020019060010190617d91565b50505050905090565b6000600860009054906101000a900460ff1615617e665760019050617f51565b6000801b7f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff1663667f9d707f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c7f6661696c656400000000000000000000000000000000000000000000000000006040518363ffffffff1660e01b8152600401617f0b92919061cb47565b602060405180830381865afa158015617f28573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190617f4c919061c3b9565b141590505b90565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401617fd1919061c236565b60006040518083038186803b158015617fe957600080fd5b505afa158015617ffd573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401618052919061c236565b60006040518083038186803b15801561806a57600080fd5b505afa15801561807e573d6000803e3d6000fd5b50505050600a8151111561809157600a81525b61809a8161a5cc565b905060006180a8838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56856040518263ffffffff1660e01b81526004016180f7919061c35f565b600060405180830381600087803b15801561811157600080fd5b505af1158015618125573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401618184919061c389565b6020604051808303816000875af11580156181a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906181c7919061c3b9565b5060005b825181101561829d57737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561823057600080fd5b505af1158015618244573d6000803e3d6000fd5b5050505082818151811061825b5761825a61c3e6565b5b6020026020010151827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a380806001019150506181cb565b50601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663065d6c6982846040518363ffffffff1660e01b81526004016182fb92919061c922565b600060405180830381600087803b15801561831557600080fd5b505af1158015618329573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561838957600080fd5b505af115801561839d573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6836040518263ffffffff1660e01b81526004016183fe919061c755565b600060405180830381865afa15801561841b573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190618444919061c807565b90506184528151845161a8da565b60005b81518110156184a95761849c8282815181106184745761847361c3e6565b5b602002602001015185838151811061848f5761848e61c3e6565b5b602002602001015161aa0e565b8080600101915050618455565b505050505050565b6000737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7826040518263ffffffff1660e01b8152600401618500919061c35f565b600060405180830381600087803b15801561851a57600080fd5b505af115801561852e573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063ff7d580d60e01b6040518263ffffffff1660e01b8152600401618586919061c45c565b600060405180830381600087803b1580156185a057600080fd5b505af11580156185b4573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018836040518263ffffffff1660e01b8152600401618613919061c389565b6020604051808303816000875af1158015618632573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190618656919061c3b9565b505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016186d8919061c236565b60006040518083038186803b1580156186f057600080fd5b505afa158015618704573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401618759919061c236565b60006040518083038186803b15801561877157600080fd5b505afa158015618785573d6000803e3d6000fd5b505050506000618795838661a73e565b905061879f61aed7565b828160a0015160000181905250737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56876040518263ffffffff1660e01b81526004016187f9919061c35f565b600060405180830381600087803b15801561881357600080fd5b505af1158015618827573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b8152600401618886919061c389565b6020604051808303816000875af11580156188a5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906188c9919061c3b9565b50601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d83856040518363ffffffff1660e01b815260040161892792919061c725565b600060405180830381600087803b15801561894157600080fd5b505af1158015618955573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156189b557600080fd5b505af11580156189c9573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633808a90b8784866040518463ffffffff1660e01b8152600401618a2e9392919061cb09565b602060405180830381865afa158015618a4b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190618a6f919061c3b9565b9050618a8d81618a88888561ab6e90919063ffffffff16565b61aa0e565b50505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401618b13919061c236565b60006040518083038186803b158015618b2b57600080fd5b505afa158015618b3f573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56846040518263ffffffff1660e01b8152600401618b90919061c35f565b600060405180830381600087803b158015618baa57600080fd5b505af1158015618bbe573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401618c1f919061c389565b6020604051808303816000875af1158015618c3e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190618c62919061c3b9565b9050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f182846040518363ffffffff1660e01b8152600401618cc192919061c424565b600060405180830381600087803b158015618cdb57600080fd5b505af1158015618cef573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0632d86c03a60e01b6040518263ffffffff1660e01b8152600401618d47919061c45c565b600060405180830381600087803b158015618d6157600080fd5b505af1158015618d75573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f182846040518363ffffffff1660e01b8152600401618dd692919061c424565b600060405180830381600087803b158015618df057600080fd5b505af1158015618e04573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015618e6457600080fd5b505af1158015618e78573d6000803e3d6000fd5b5050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401618eff919061c236565b60006040518083038186803b158015618f1757600080fd5b505afa158015618f2b573d6000803e3d6000fd5b505050506000618f3b828461a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015618f9957600080fd5b505af1158015618fad573d6000803e3d6000fd5b505050508273ffffffffffffffffffffffffffffffffffffffff16817f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a3737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7846040518263ffffffff1660e01b8152600401619042919061c35f565b600060405180830381600087803b15801561905c57600080fd5b505af1158015619070573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b81526004016190d1919061c389565b6020604051808303816000875af11580156190f0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190619114919061c3b9565b9050619120818361aa0e565b6191c5601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ebc27b82846040518263ffffffff1660e01b815260040161917e919061c755565b602060405180830381865afa15801561919b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906191bf919061c997565b8561aaa8565b50505050565b6060601580548060200260200160405190810160405280929190818152602001828054801561924f57602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311619205575b5050505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016192d6919061c236565b60006040518083038186803b1580156192ee57600080fd5b505afa158015619302573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56846040518263ffffffff1660e01b8152600401619353919061c35f565b600060405180830381600087803b15801561936d57600080fd5b505af1158015619381573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b81526004016193e2919061c389565b6020604051808303816000875af1158015619401573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190619425919061c3b9565b9050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82846040518363ffffffff1660e01b815260040161948492919061c725565b600060405180830381600087803b15801561949e57600080fd5b505af11580156194b2573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0632d86c03a60e01b6040518263ffffffff1660e01b815260040161950a919061c45c565b600060405180830381600087803b15801561952457600080fd5b505af1158015619538573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f1826195848561a8aa565b6040518363ffffffff1660e01b81526004016195a192919061c424565b600060405180830381600087803b1580156195bb57600080fd5b505af11580156195cf573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561962f57600080fd5b505af1158015619643573d6000803e3d6000fd5b5050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016196ca919061c236565b60006040518083038186803b1580156196e257600080fd5b505afa1580156196f6573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b815260040161974b919061c236565b60006040518083038186803b15801561976357600080fd5b505afa158015619777573d6000803e3d6000fd5b50505050600a8151111561978a57600a81525b6197938161a5cc565b905060006197a1838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56856040518263ffffffff1660e01b81526004016197f0919061c35f565b600060405180830381600087803b15801561980a57600080fd5b505af115801561981e573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b815260040161987d919061c389565b6020604051808303816000875af115801561989c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906198c0919061c3b9565b50601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663065d6c6982846040518363ffffffff1660e01b815260040161991e92919061c922565b600060405180830381600087803b15801561993857600080fd5b505af115801561994c573d6000803e3d6000fd5b505050506000825167ffffffffffffffff81111561996d5761996c61b05c565b5b60405190808252806020026020018201604052801561999b5781602001602082028036833780820191505090505b50905060005b8351811015619a09578360018286516199ba919061c31c565b6199c4919061c31c565b815181106199d5576199d461c3e6565b5b60200260200101518282815181106199f0576199ef61c3e6565b5b60200260200101818152505080806001019150506199a1565b506000835167ffffffffffffffff811115619a2757619a2661b05c565b5b604051908082528060200260200182016040528015619a555781602001602082028036833780820191505090505b50905060005b8451811015619aa9576001818651619a73919061c31c565b619a7d919061c31c565b828281518110619a9057619a8f61c3e6565b5b6020026020010181815250508080600101915050619a5b565b5060005b8451811015619b7f57737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015619b1257600080fd5b505af1158015619b26573d6000803e3d6000fd5b50505050828181518110619b3d57619b3c61c3e6565b5b6020026020010151847f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a38080600101915050619aad565b50601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4c9c5c48484846040518463ffffffff1660e01b8152600401619bdf9392919061c696565b600060405180830381600087803b158015619bf957600080fd5b505af1158015619c0d573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015619c6d57600080fd5b505af1158015619c81573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6856040518263ffffffff1660e01b8152600401619ce2919061c755565b600060405180830381865afa158015619cff573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190619d28919061c807565b9050619d368151600061a8da565b50505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401619dbc919061c236565b60006040518083038186803b158015619dd457600080fd5b505afa158015619de8573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401619e68919061c236565b60006040518083038186803b158015619e8057600080fd5b505afa158015619e94573d6000803e3d6000fd5b505050506000619ea4838661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b8152600401619ef3919061c35f565b600060405180830381600087803b158015619f0d57600080fd5b505af1158015619f21573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401619f80919061c389565b6020604051808303816000875af1158015619f9f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190619fc3919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b815260040161a018919061c45c565b600060405180830381600087803b15801561a03257600080fd5b505af115801561a046573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b815260040161a097919061c35f565b600060405180830381600087803b15801561a0b157600080fd5b505af115801561a0c5573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82846040518363ffffffff1660e01b815260040161a12692919061c725565b600060405180830381600087803b15801561a14057600080fd5b505af115801561a154573d6000803e3d6000fd5b505050505050505050565b601f60009054906101000a900460ff1681565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b815260040161a1ef919061c236565b60006040518083038186803b15801561a20757600080fd5b505afa15801561a21b573d6000803e3d6000fd5b50505050600061a22b838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b815260040161a27a919061c35f565b600060405180830381600087803b15801561a29457600080fd5b505af115801561a2a8573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b815260040161a307919061c389565b6020604051808303816000875af115801561a326573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061a34a919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561a3a757600080fd5b505af115801561a3bb573d6000803e3d6000fd5b5050505081817fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a3737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b815260040161a43a919061c35f565b600060405180830381600087803b15801561a45457600080fd5b505af115801561a468573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f182846040518363ffffffff1660e01b815260040161a4c992919061c424565b600060405180830381600087803b15801561a4e357600080fd5b505af115801561a4f7573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6836040518263ffffffff1660e01b815260040161a558919061c755565b600060405180830381865afa15801561a575573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f8201168201806040525081019061a59e919061c807565b905061a5c58160008151811061a5b75761a5b661c3e6565b5b60200260200101518461aa0e565b5050505050565b6060815167ffffffffffffffff81111561a5e95761a5e861b05c565b5b60405190808252806020026020018201604052801561a6175781602001602082028036833780820191505090505b5090506000805b835181101561a6df576000805b8381101561a6845785838151811061a6465761a64561c3e6565b5b602002602001015185828151811061a6615761a66061c3e6565b5b60200260200101510361a677576001915061a684565b808060010191505061a62b565b508061a6d15784828151811061a69d5761a69c61c3e6565b5b602002602001015184848061a6b19061cb70565b95508151811061a6c45761a6c361c3e6565b5b6020026020010181815250505b50808060010191505061a61e565b5080825250919050565b600061a6f684848461abd1565b905061a7376040518060400160405280600c81526020017f426f756e6420726573756c7400000000000000000000000000000000000000008152508261ade0565b9392505050565b6000828260405160200161a75392919061cc21565b60405160208183030381529060405261a76b9061cc7f565b905092915050565b6060815167ffffffffffffffff81111561a7905761a78f61b05c565b5b60405190808252806020026020018201604052801561a7c357816020015b606081526020019060019003908161a7ae5790505b5090506000805b835181101561a8a05760008061a7f986848151811061a7ec5761a7eb61c3e6565b5b602002602001015161a8aa565b905060005b8481101561a8455761a82986828151811061a81c5761a81b61c3e6565b5b602002602001015161a8aa565b820361a838576001925061a845565b808060010191505061a7fe565b508161a8915785838151811061a85e5761a85d61c3e6565b5b602002602001015185858061a8729061cb70565b96508151811061a8855761a88461c3e6565b5b60200260200101819052505b5050808060010191505061a7ca565b5080825250919050565b60008160405160200161a8bd919061cd22565b604051602081830303815290604052805190602001209050919050565b80821461a970577f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff166398296c5483836040518363ffffffff1660e01b815260040161a93f92919061cd39565b60006040518083038186803b15801561a95757600080fd5b505afa15801561a96b573d6000803e3d6000fd5b505050505b5050565b80820361aa0a577f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff1663898e83fc83836040518363ffffffff1660e01b815260040161a9d992919061c424565b60006040518083038186803b15801561a9f157600080fd5b505afa15801561aa05573d6000803e3d6000fd5b505050505b5050565b80821461aaa4577f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff16637c84c69b83836040518363ffffffff1660e01b815260040161aa7392919061c424565b60006040518083038186803b15801561aa8b57600080fd5b505afa15801561aa9f573d6000803e3d6000fd5b505050505b5050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161461ab6a577f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff1663515361f683836040518363ffffffff1660e01b815260040161ab3992919061cd62565b60006040518083038186803b15801561ab5157600080fd5b505afa15801561ab65573d6000803e3d6000fd5b505050505b5050565b600060405160200161ab7f9061cdd7565b60405160208183030381529060405280519060200120828460600151856040015160405160200161abb3949392919061ce0d565b60405160208183030381529060405280519060200120905092915050565b60008183111561ac16576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161ac0d9061cecd565b60405180910390fd5b82841015801561ac265750818411155b1561ac335783905061add9565b60006001848461ac43919061c31c565b61ac4d919061c477565b90506003851115801561ac5f57508481115b1561ac7857848461ac70919061c477565b91505061add9565b60037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff61aca5919061c31c565b851015801561acde5750847fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff61acdb919061c31c565b81115b1561ad2257847fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff61ad0f919061c31c565b8361ad1a919061c31c565b91505061add9565b8285111561ad7e576000838661ad38919061c31c565b90506000828261ad48919061cf1c565b90506000810361ad5d5784935050505061add9565b6001818761ad6b919061c477565b61ad75919061c31c565b9350505061add7565b8385101561add6576000858561ad94919061c31c565b90506000828261ada4919061cf1c565b90506000810361adb95785935050505061add9565b6001818661adc7919061c31c565b61add1919061c477565b935050505b5b505b9392505050565b61ae78828260405160240161adf692919061cf4d565b6040516020818303038152906040527fb60e72cc000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505061ae7c565b5050565b61ae938161ae8b61ae9661aebf565b63ffffffff16565b50565b60008151905060006a636f6e736f6c652e6c6f679050602083016000808483855afa5050505050565b61af4e819050919050565b6123938061cfad83390190565b6040518060c00160405280600073ffffffffffffffffffffffffffffffffffffffff16815260200160007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200160008019168152602001600080191681526020016060815260200161af4861af58565b81525090565b61af5661cf7d565b565b604051806040016040528060608152602001600067ffffffffffffffff1681525090565b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061afbb8261af90565b9050919050565b61afcb8161afb0565b811461afd657600080fd5b50565b60008135905061afe88161afc2565b92915050565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b61b0238161afee565b811461b02e57600080fd5b50565b60008135905061b0408161b01a565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61b0948261b04b565b810181811067ffffffffffffffff8211171561b0b35761b0b261b05c565b5b80604052505050565b600061b0c661af7c565b905061b0d2828261b08b565b919050565b600067ffffffffffffffff82111561b0f25761b0f161b05c565b5b602082029050602081019050919050565b600080fd5b6000819050919050565b61b11b8161b108565b811461b12657600080fd5b50565b60008135905061b1388161b112565b92915050565b600061b15161b14c8461b0d7565b61b0bc565b9050808382526020820190506020840283018581111561b1745761b17361b103565b5b835b8181101561b19d578061b189888261b129565b84526020840193505060208101905061b176565b5050509392505050565b600082601f83011261b1bc5761b1bb61b046565b5b813561b1cc84826020860161b13e565b91505092915050565b6000819050919050565b61b1e88161b1d5565b811461b1f357600080fd5b50565b60008135905061b2058161b1df565b92915050565b6000806000806080858703121561b2255761b22461af86565b5b600061b2338782880161afd9565b945050602061b2448782880161b031565b935050604085013567ffffffffffffffff81111561b2655761b26461af8b565b5b61b2718782880161b1a7565b925050606061b2828782880161b1f6565b91505092959194509250565b60008060006060848603121561b2a75761b2a661af86565b5b600061b2b58682870161afd9565b935050602061b2c68682870161afd9565b925050604061b2d78682870161b031565b9150509250925092565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61b3168161afb0565b82525050565b600061b328838361b30d565b60208301905092915050565b6000602082019050919050565b600061b34c8261b2e1565b61b356818561b2ec565b935061b3618361b2fd565b8060005b8381101561b39257815161b379888261b31c565b975061b3848361b334565b92505060018101905061b365565b5085935050505092915050565b6000602082019050818103600083015261b3b9818461b341565b905092915050565b600067ffffffffffffffff82111561b3dc5761b3db61b05c565b5b602082029050602081019050919050565b600061b40061b3fb8461b3c1565b61b0bc565b9050808382526020820190506020840283018581111561b4235761b42261b103565b5b835b8181101561b44c578061b438888261b1f6565b84526020840193505060208101905061b425565b5050509392505050565b600082601f83011261b46b5761b46a61b046565b5b813561b47b84826020860161b3ed565b91505092915050565b6000806000806080858703121561b49e5761b49d61af86565b5b600061b4ac8782880161afd9565b945050602061b4bd8782880161b031565b935050604085013567ffffffffffffffff81111561b4de5761b4dd61af8b565b5b61b4ea8782880161b1a7565b925050606085013567ffffffffffffffff81111561b50b5761b50a61af8b565b5b61b5178782880161b456565b91505092959194509250565b600067ffffffffffffffff82111561b53e5761b53d61b05c565b5b602082029050602081019050919050565b600080fd5b600067ffffffffffffffff82111561b56f5761b56e61b05c565b5b61b5788261b04b565b9050602081019050919050565b82818337600083830152505050565b600061b5a761b5a28461b554565b61b0bc565b90508281526020810184848401111561b5c35761b5c261b54f565b5b61b5ce84828561b585565b509392505050565b600082601f83011261b5eb5761b5ea61b046565b5b813561b5fb84826020860161b594565b91505092915050565b600061b61761b6128461b523565b61b0bc565b9050808382526020820190506020840283018581111561b63a5761b63961b103565b5b835b8181101561b68157803567ffffffffffffffff81111561b65f5761b65e61b046565b5b80860161b66c898261b5d6565b8552602085019450505060208101905061b63c565b5050509392505050565b600082601f83011261b6a05761b69f61b046565b5b813561b6b084826020860161b604565b91505092915050565b6000806000806080858703121561b6d35761b6d261af86565b5b600061b6e18782880161afd9565b945050602061b6f28782880161b031565b935050604085013567ffffffffffffffff81111561b7135761b71261af8b565b5b61b71f8782880161b68b565b925050606061b7308782880161b1f6565b91505092959194509250565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561b7ce57808201518184015260208101905061b7b3565b60008484015250505050565b600061b7e58261b794565b61b7ef818561b79f565b935061b7ff81856020860161b7b0565b61b8088161b04b565b840191505092915050565b600061b81f838361b7da565b905092915050565b6000602082019050919050565b600061b83f8261b768565b61b849818561b773565b93508360208202850161b85b8561b784565b8060005b8581101561b897578484038952815161b878858261b813565b945061b8838361b827565b925060208a0199505060018101905061b85f565b50829750879550505050505092915050565b600060408301600083015161b8c1600086018261b30d565b506020830151848203602086015261b8d9828261b834565b9150508091505092915050565b600061b8f2838361b8a9565b905092915050565b6000602082019050919050565b600061b9128261b73c565b61b91c818561b747565b93508360208202850161b92e8561b758565b8060005b8581101561b96a578484038952815161b94b858261b8e6565b945061b9568361b8fa565b925060208a0199505060018101905061b932565b50829750879550505050505092915050565b6000602082019050818103600083015261b996818461b907565b905092915050565b6000806000806080858703121561b9b85761b9b761af86565b5b600061b9c68782880161afd9565b945050602061b9d78782880161afd9565b935050604061b9e88782880161b031565b925050606061b9f98782880161b129565b91505092959194509250565b6000806000806080858703121561ba1f5761ba1e61af86565b5b600061ba2d8782880161afd9565b945050602061ba3e8782880161afd9565b935050604061ba4f8782880161b031565b925050606085013567ffffffffffffffff81111561ba705761ba6f61af8b565b5b61ba7c8782880161b1a7565b91505092959194509250565b6000806000806080858703121561baa25761baa161af86565b5b600061bab08782880161afd9565b945050602061bac18782880161afd9565b935050604061bad28782880161b031565b925050606085013567ffffffffffffffff81111561baf35761baf261af8b565b5b61baff8782880161b5d6565b91505092959194509250565b60008060006060848603121561bb245761bb2361af86565b5b600061bb328682870161afd9565b935050602061bb438682870161b031565b925050604084013567ffffffffffffffff81111561bb645761bb6361af8b565b5b61bb708682870161b5d6565b9150509250925092565b60008060006060848603121561bb935761bb9261af86565b5b600061bba18682870161afd9565b935050602061bbb28682870161b031565b925050604084013567ffffffffffffffff81111561bbd35761bbd261af8b565b5b61bbdf8682870161b68b565b9150509250925092565b60008060006060848603121561bc025761bc0161af86565b5b600061bc108682870161afd9565b935050602061bc218682870161b031565b925050604061bc328682870161b129565b9150509250925092565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b61bcc98161bc94565b82525050565b600061bcdb838361bcc0565b60208301905092915050565b6000602082019050919050565b600061bcff8261bc68565b61bd09818561bc73565b935061bd148361bc84565b8060005b8381101561bd4557815161bd2c888261bccf565b975061bd378361bce7565b92505060018101905061bd18565b5085935050505092915050565b6000604083016000830151848203600086015261bd6f828261b7da565b9150506020830151848203602086015261bd89828261bcf4565b9150508091505092915050565b600061bda2838361bd52565b905092915050565b6000602082019050919050565b600061bdc28261bc3c565b61bdcc818561bc47565b93508360208202850161bdde8561bc58565b8060005b8581101561be1a578484038952815161bdfb858261bd96565b945061be068361bdaa565b925060208a0199505060018101905061bde2565b50829750879550505050505092915050565b6000602082019050818103600083015261be46818461bdb7565b905092915050565b6000806040838503121561be655761be6461af86565b5b600061be738582860161afd9565b925050602061be848582860161b031565b9150509250929050565b6000819050919050565b600061beb361beae61bea98461af90565b61be8e565b61af90565b9050919050565b600061bec58261be98565b9050919050565b600061bed78261beba565b9050919050565b61bee78161becc565b82525050565b600060208201905061bf02600083018461bede565b92915050565b600080600080600060a0868803121561bf245761bf2361af86565b5b600061bf328882890161afd9565b955050602061bf438882890161afd9565b945050604061bf548882890161b031565b935050606086013567ffffffffffffffff81111561bf755761bf7461af8b565b5b61bf818882890161b68b565b925050608061bf928882890161b1f6565b9150509295509295909350565b600082825260208201905092915050565b600061bfbb8261b768565b61bfc5818561bf9f565b93508360208202850161bfd78561b784565b8060005b8581101561c013578484038952815161bff4858261b813565b945061bfff8361b827565b925060208a0199505060018101905061bfdb565b50829750879550505050505092915050565b6000602082019050818103600083015261c03f818461bfb0565b905092915050565b600080600080600060a0868803121561c0635761c06261af86565b5b600061c0718882890161afd9565b955050602061c0828882890161afd9565b945050604061c0938882890161b031565b935050606086013567ffffffffffffffff81111561c0b45761c0b361af8b565b5b61c0c08882890161b5d6565b925050608086013567ffffffffffffffff81111561c0e15761c0e061af8b565b5b61c0ed8882890161b5d6565b9150509295509295909350565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600060408301600083015161c13e600086018261b30d565b506020830151848203602086015261c156828261bcf4565b9150508091505092915050565b600061c16f838361c126565b905092915050565b6000602082019050919050565b600061c18f8261c0fa565b61c199818561c105565b93508360208202850161c1ab8561c116565b8060005b8581101561c1e7578484038952815161c1c8858261c163565b945061c1d38361c177565b925060208a0199505060018101905061c1af565b50829750879550505050505092915050565b6000602082019050818103600083015261c213818461c184565b905092915050565b60008115159050919050565b61c2308161c21b565b82525050565b600060208201905061c24b600083018461c227565b92915050565b60008060006060848603121561c26a5761c26961af86565b5b600061c2788682870161afd9565b935050602061c2898682870161b031565b925050604084013567ffffffffffffffff81111561c2aa5761c2a961af8b565b5b61c2b68682870161b1a7565b9150509250925092565b60006020828403121561c2d65761c2d561af86565b5b600061c2e48482850161b031565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061c3278261b1d5565b915061c3328361b1d5565b925082820390508181111561c34a5761c34961c2ed565b5b92915050565b61c3598161afb0565b82525050565b600060208201905061c374600083018461c350565b92915050565b61c3838161afee565b82525050565b600060208201905061c39e600083018461c37a565b92915050565b60008151905061c3b38161b112565b92915050565b60006020828403121561c3cf5761c3ce61af86565b5b600061c3dd8482850161c3a4565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b61c41e8161b108565b82525050565b600060408201905061c439600083018561c415565b61c446602083018461c415565b9392505050565b61c4568161bc94565b82525050565b600060208201905061c471600083018461c44d565b92915050565b600061c4828261b1d5565b915061c48d8361b1d5565b925082820190508082111561c4a55761c4a461c2ed565b5b92915050565b61c4b48161b1d5565b82525050565b600060608201905061c4cf600083018661c415565b61c4dc602083018561c415565b61c4e9604083018461c4ab565b949350505050565b600060408201905061c506600083018561c415565b61c513602083018461c350565b9392505050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61c54f8161b108565b82525050565b600061c561838361c546565b60208301905092915050565b6000602082019050919050565b600061c5858261c51a565b61c58f818561c525565b935061c59a8361c536565b8060005b8381101561c5cb57815161c5b2888261c555565b975061c5bd8361c56d565b92505060018101905061c59e565b5085935050505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61c60d8161b1d5565b82525050565b600061c61f838361c604565b60208301905092915050565b6000602082019050919050565b600061c6438261c5d8565b61c64d818561c5e3565b935061c6588361c5f4565b8060005b8381101561c68957815161c670888261c613565b975061c67b8361c62b565b92505060018101905061c65c565b5085935050505092915050565b600060608201905061c6ab600083018661c415565b818103602083015261c6bd818561c57a565b9050818103604083015261c6d1818461c638565b9050949350505050565b600082825260208201905092915050565b600061c6f78261b794565b61c701818561c6db565b935061c71181856020860161b7b0565b61c71a8161b04b565b840191505092915050565b600060408201905061c73a600083018561c415565b818103602083015261c74c818461c6ec565b90509392505050565b600060208201905061c76a600083018461c415565b92915050565b600061c78361c77e8461b0d7565b61b0bc565b9050808382526020820190506020840283018581111561c7a65761c7a561b103565b5b835b8181101561c7cf578061c7bb888261c3a4565b84526020840193505060208101905061c7a8565b5050509392505050565b600082601f83011261c7ee5761c7ed61b046565b5b815161c7fe84826020860161c770565b91505092915050565b60006020828403121561c81d5761c81c61af86565b5b600082015167ffffffffffffffff81111561c83b5761c83a61af8b565b5b61c8478482850161c7d9565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000600282049050600182168061c89757607f821691505b60208210810361c8aa5761c8a961c850565b5b50919050565b6000819050919050565b600061c8d561c8d061c8cb8461c8b0565b61be8e565b61b1d5565b9050919050565b61c8e58161c8ba565b82525050565b600060608201905061c900600083018661c415565b61c90d602083018561c415565b61c91a604083018461c8dc565b949350505050565b600060408201905061c937600083018561c415565b818103602083015261c949818461c57a565b90509392505050565b600060408201905061c967600083018561c415565b818103602083015261c979818461bfb0565b90509392505050565b60008151905061c9918161afc2565b92915050565b60006020828403121561c9ad5761c9ac61af86565b5b600061c9bb8482850161c982565b91505092915050565b600081519050919050565b600082825260208201905092915050565b600061c9eb8261c9c4565b61c9f5818561c9cf565b935061ca0581856020860161b7b0565b61ca0e8161b04b565b840191505092915050565b600067ffffffffffffffff82169050919050565b61ca368161ca19565b82525050565b6000604083016000830151848203600086015261ca59828261b7da565b915050602083015161ca6e602086018261ca2d565b508091505092915050565b600060c08301600083015161ca91600086018261b30d565b50602083015161caa4602086018261bcc0565b50604083015161cab7604086018261c546565b50606083015161caca606086018261c546565b506080830151848203608086015261cae2828261c9e0565b91505060a083015184820360a086015261cafc828261ca3c565b9150508091505092915050565b600060608201905061cb1e600083018661c350565b818103602083015261cb30818561ca79565b905061cb3f604083018461c415565b949350505050565b600060408201905061cb5c600083018561c350565b61cb69602083018461c415565b9392505050565b600061cb7b8261b1d5565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361cbad5761cbac61c2ed565b5b600182019050919050565b6000819050919050565b61cbd361cbce8261afee565b61cbb8565b82525050565b60008160601b9050919050565b600061cbf18261cbd9565b9050919050565b600061cc038261cbe6565b9050919050565b61cc1b61cc168261afb0565b61cbf8565b82525050565b600061cc2d828561cbc2565b600c8201915061cc3d828461cc0a565b6014820191508190509392505050565b6000819050602082019050919050565b600061cc69825161b108565b80915050919050565b600082821b905092915050565b600061cc8a8261c9c4565b8261cc948461cc4d565b905061cc9f8161cc5d565b9250602082101561ccdf5761ccda7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8360200360080261cc72565b831692505b5050919050565b600081905092915050565b600061ccfc8261b794565b61cd06818561cce6565b935061cd1681856020860161b7b0565b80840191505092915050565b600061cd2e828461ccf1565b915081905092915050565b600060408201905061cd4e600083018561c4ab565b61cd5b602083018461c4ab565b9392505050565b600060408201905061cd77600083018561c350565b61cd84602083018461c350565b9392505050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b600061cdc160158361cce6565b915061cdcc8261cd8b565b601582019050919050565b600061cde28261cdb4565b9150819050919050565b6000819050919050565b61ce0761ce028261b108565b61cdec565b82525050565b600061ce19828761cdf6565b60208201915061ce29828661cc0a565b60148201915061ce39828561cdf6565b60208201915061ce49828461cdf6565b60208201915081905095945050505050565b7f5374645574696c7320626f756e642875696e743235362c75696e743235362c7560008201527f696e74323536293a204d6178206973206c657373207468616e206d696e2e0000602082015250565b600061ceb7603e8361c6db565b915061cec28261ce5b565b604082019050919050565b6000602082019050818103600083015261cee68161ceaa565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600061cf278261b1d5565b915061cf328361b1d5565b92508261cf425761cf4161ceed565b5b828206905092915050565b6000604082019050818103600083015261cf67818561c6ec565b905061cf76602083018461c4ab565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052605160045260246000fdfe6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c0033a2646970667358221220ba21482488e5d17bec6604135b1b31db216266e88c795314fe409bf1cd2b198264736f6c634300081c0033","sourceMap":"622:21245:29:-:0;;;3200:4:2;3160:44;;;;;;;;;;;;;;;;;;;;1087:4:13;1065:26;;;;;;;;;;;;;;;;;;;;622:21245:29;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x608060405234801561001057600080fd5b506004361061027f5760003560e01c80637b1039991161015c578063ba414fa6116100ce578063e20c9f7111610087578063e20c9f71146106cc578063e575719f146106ea578063eed3579214610706578063f72c62f114610722578063fa7626d41461073e578063ff679dab1461075c5761027f565b8063ba414fa614610622578063c5a3633914610640578063ca8c203d1461065c578063ce7bcae314610678578063d360961714610694578063d887d395146106b05761027f565b8063916a17c611610120578063916a17c6146105745780639cc595a414610592578063ad0d1166146105ae578063ad2ac469146105ca578063b0464fdc146105e6578063b5508aa9146106045761027f565b80637b103999146104e45780637d1d95b514610502578063820c2c2c1461051e57806385226c811461053a578063891e3354146105585761027f565b80633e5e3c23116101f557806356f52e42116101b957806356f52e421461043a57806358bab9621461045657806361fd155b1461047257806366d9a9a01461048e57806372976749146104ac578063785cf657146104c85761027f565b80633e5e3c23146103aa5780633f7286f4146103c85780634b05e990146103e65780634cf9fbff14610402578063538d6c481461041e5761027f565b80632955e468116102475780632955e468146103005780632a475b0d1461031c5780632ade3880146103385780632c6eec1e146103565780632d03611e146103725780632e84025c1461038e5761027f565b80630a9254e4146102845780630b3307e81461028e57806312fe420e146102aa5780631ed7831c146102c657806327d334b2146102e4575b600080fd5b61028c610778565b005b6102a860048036038101906102a3919061b20b565b6107e3565b005b6102c460048036038101906102bf919061b28e565b610d6c565b005b6102ce611238565b6040516102db919061b39f565b60405180910390f35b6102fe60048036038101906102f9919061b484565b6112c6565b005b61031a6004803603810190610315919061b28e565b6117a6565b005b6103366004803603810190610331919061b6b9565b611d90565b005b6103406123cc565b60405161034d919061b97c565b60405180910390f35b610370600480360381019061036b919061b99e565b61255a565b005b61038c6004803603810190610387919061ba05565b61297d565b005b6103a860048036038101906103a3919061ba88565b612e38565b005b6103b2613258565b6040516103bf919061b39f565b60405180910390f35b6103d06132e6565b6040516103dd919061b39f565b60405180910390f35b61040060048036038101906103fb919061bb0b565b613374565b005b61041c6004803603810190610417919061bb7a565b613768565b005b6104386004803603810190610433919061b99e565b613cd5565b005b610454600480360381019061044f919061bb0b565b614433565b005b610470600480360381019061046b919061bbe9565b614929565b005b61048c6004803603810190610487919061b484565b614c9f565b005b610496615183565b6040516104a3919061be2c565b60405180910390f35b6104c660048036038101906104c1919061be4e565b61530e565b005b6104e260048036038101906104dd919061bb0b565b615681565b005b6104ec615aee565b6040516104f9919061beed565b60405180910390f35b61051c6004803603810190610517919061ba05565b615b14565b005b6105386004803603810190610533919061bf08565b616191565b005b610542616650565b60405161054f919061c025565b60405180910390f35b610572600480360381019061056d919061c047565b616729565b005b61057c616c71565b604051610589919061c1f9565b60405180910390f35b6105ac60048036038101906105a7919061b20b565b616dc0565b005b6105c860048036038101906105c3919061b99e565b61740a565b005b6105e460048036038101906105df919061bb0b565b61782a565b005b6105ee617c1e565b6040516105fb919061c1f9565b60405180910390f35b61060c617d6d565b604051610619919061c025565b60405180910390f35b61062a617e46565b604051610637919061c236565b60405180910390f35b61065a6004803603810190610655919061c251565b617f54565b005b6106766004803603810190610671919061c2c0565b6184b1565b005b610692600480360381019061068d919061ba88565b61865b565b005b6106ae60048036038101906106a9919061bbe9565b618a96565b005b6106ca60048036038101906106c5919061be4e565b618e82565b005b6106d46191cb565b6040516106e1919061b39f565b60405180910390f35b61070460048036038101906106ff919061bb0b565b619259565b005b610720600480360381019061071b919061c251565b61964d565b005b61073c6004803603810190610737919061ba88565b619d3f565b005b61074661a15f565b604051610753919061c236565b60405180910390f35b6107766004803603810190610771919061bbe9565b61a172565b005b6040516107849061aeca565b604051809103906000f0801580156107a0573d6000803e3d6000fd5b50601f60016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401610860919061c236565b60006040518083038186803b15801561087857600080fd5b505afa15801561088c573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008451116040518263ffffffff1660e01b81526004016108e1919061c236565b60006040518083038186803b1580156108f957600080fd5b505afa15801561090d573d6000803e3d6000fd5b50505050600a8251111561092057600a82525b6109298261a5cc565b91506109448160006001855161093f919061c31c565b61a6e9565b90506000610952848661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56866040518263ffffffff1660e01b81526004016109a1919061c35f565b600060405180830381600087803b1580156109bb57600080fd5b505af11580156109cf573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b8152600401610a2e919061c389565b6020604051808303816000875af1158015610a4d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a71919061c3b9565b5060005b8351811015610b3457601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f183868481518110610ad057610acf61c3e6565b5b60200260200101516040518363ffffffff1660e01b8152600401610af592919061c424565b600060405180830381600087803b158015610b0f57600080fd5b505af1158015610b23573d6000803e3d6000fd5b505050508080600101915050610a75565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015610b9157600080fd5b505af1158015610ba5573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063526c768760e01b6040518263ffffffff1660e01b8152600401610bfd919061c45c565b600060405180830381600087803b158015610c1757600080fd5b505af1158015610c2b573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b8152600401610c7c919061c35f565b600060405180830381600087803b158015610c9657600080fd5b505af1158015610caa573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b31f01b82858581518110610d0057610cff61c3e6565b5b6020026020010151600186610d15919061c477565b6040518463ffffffff1660e01b8152600401610d339392919061c4ba565b600060405180830381600087803b158015610d4d57600080fd5b505af1158015610d61573d6000803e3d6000fd5b505050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401610de8919061c236565b60006040518083038186803b158015610e0057600080fd5b505afa158015610e14573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401610e95919061c236565b60006040518083038186803b158015610ead57600080fd5b505afa158015610ec1573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401610f42919061c236565b60006040518083038186803b158015610f5a57600080fd5b505afa158015610f6e573d6000803e3d6000fd5b505050506000610f7e828561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401610fcd919061c35f565b600060405180830381600087803b158015610fe757600080fd5b505af1158015610ffb573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018836040518263ffffffff1660e01b815260040161105a919061c389565b6020604051808303816000875af1158015611079573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061109d919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b81526004016110f2919061c45c565b600060405180830381600087803b15801561110c57600080fd5b505af1158015611120573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7846040518263ffffffff1660e01b8152600401611171919061c35f565b600060405180830381600087803b15801561118b57600080fd5b505af115801561119f573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639630aff882856040518363ffffffff1660e01b815260040161120092919061c4f1565b600060405180830381600087803b15801561121a57600080fd5b505af115801561122e573d6000803e3d6000fd5b5050505050505050565b606060168054806020026020016040519081016040528092919081815260200182805480156112bc57602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311611272575b5050505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401611343919061c236565b60006040518083038186803b15801561135b57600080fd5b505afa15801561136f573d6000803e3d6000fd5b50505050600081519050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600183116040518263ffffffff1660e01b81526004016113c9919061c236565b60006040518083038186803b1580156113e157600080fd5b505afa1580156113f5573d6000803e3d6000fd5b505050508083526000805b6001845161140e919061c31c565b8110156114735783600182611423919061c477565b815181106114345761143361c3e6565b5b602002602001015184828151811061144f5761144e61c3e6565b5b602002602001015110156114665760019150611473565b8080600101915050611400565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562826040518263ffffffff1660e01b81526004016114c1919061c236565b60006040518083038186803b1580156114d957600080fd5b505afa1580156114ed573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56876040518263ffffffff1660e01b815260040161153e919061c35f565b600060405180830381600087803b15801561155857600080fd5b505af115801561156c573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018876040518263ffffffff1660e01b81526004016115cd919061c389565b6020604051808303816000875af11580156115ec573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611610919061c3b9565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063526c768760e01b6040518263ffffffff1660e01b8152600401611666919061c45c565b600060405180830381600087803b15801561168057600080fd5b505af1158015611694573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4c9c5c48287876040518463ffffffff1660e01b81526004016116f79392919061c696565b600060405180830381600087803b15801561171157600080fd5b505af1158015611725573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561178557600080fd5b505af1158015611799573d6000803e3d6000fd5b5050505050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401611822919061c236565b60006040518083038186803b15801561183a57600080fd5b505afa15801561184e573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016118cf919061c236565b60006040518083038186803b1580156118e757600080fd5b505afa1580156118fb573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b815260040161197c919061c236565b60006040518083038186803b15801561199457600080fd5b505afa1580156119a8573d6000803e3d6000fd5b5050505060006119b8828561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401611a07919061c35f565b600060405180830381600087803b158015611a2157600080fd5b505af1158015611a35573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018836040518263ffffffff1660e01b8152600401611a94919061c389565b6020604051808303816000875af1158015611ab3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611ad7919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401611b25919061c35f565b600060405180830381600087803b158015611b3f57600080fd5b505af1158015611b53573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639630aff882856040518363ffffffff1660e01b8152600401611bb492919061c4f1565b600060405180830381600087803b158015611bce57600080fd5b505af1158015611be2573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063feabeb4b60e01b6040518263ffffffff1660e01b8152600401611c3a919061c45c565b600060405180830381600087803b158015611c5457600080fd5b505af1158015611c68573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401611cb9919061c35f565b600060405180830381600087803b158015611cd357600080fd5b505af1158015611ce7573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018836040518263ffffffff1660e01b8152600401611d46919061c389565b6020604051808303816000875af1158015611d65573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d89919061c3b9565b5050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401611e0d919061c236565b60006040518083038186803b158015611e2557600080fd5b505afa158015611e39573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008451116040518263ffffffff1660e01b8152600401611e8e919061c236565b60006040518083038186803b158015611ea657600080fd5b505afa158015611eba573d6000803e3d6000fd5b50505050600a82511115611ecd57600a82525b611ed68261a773565b9150611ef181600060018551611eec919061c31c565b61a6e9565b90506000611eff848661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56866040518263ffffffff1660e01b8152600401611f4e919061c35f565b600060405180830381600087803b158015611f6857600080fd5b505af1158015611f7c573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b8152600401611fdb919061c389565b6020604051808303816000875af1158015611ffa573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061201e919061c3b9565b5060005b83518110156120e157601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d8386848151811061207d5761207c61c3e6565b5b60200260200101516040518363ffffffff1660e01b81526004016120a292919061c725565b600060405180830381600087803b1580156120bc57600080fd5b505af11580156120d0573d6000803e3d6000fd5b505050508080600101915050612022565b5060006121078484815181106120fa576120f961c3e6565b5b602002602001015161a8aa565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561216557600080fd5b505af1158015612179573d6000803e3d6000fd5b5050505080827f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dac6c587838686815181106121fd576121fc61c3e6565b5b60200260200101516040518363ffffffff1660e01b815260040161222292919061c725565b600060405180830381600087803b15801561223c57600080fd5b505af1158015612250573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156122b057600080fd5b505af11580156122c4573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6846040518263ffffffff1660e01b8152600401612325919061c755565b600060405180830381865afa158015612342573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f8201168201806040525081019061236b919061c807565b9050612385815160018751612380919061c31c565b61a8da565b60005b81518110156123c2576123b58282815181106123a7576123a661c3e6565b5b60200260200101518461a974565b8080600101915050612388565b5050505050505050565b6060601e805480602002602001604051908101604052809291908181526020016000905b8282101561255157838290600052602060002090600202016040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200160018201805480602002602001604051908101604052809291908181526020016000905b8282101561253a5783829060005260206000200180546124ad9061c87f565b80601f01602080910402602001604051908101604052809291908181526020018280546124d99061c87f565b80156125265780601f106124fb57610100808354040283529160200191612526565b820191906000526020600020905b81548152906001019060200180831161250957829003601f168201915b50505050508152602001906001019061248e565b5050505081525050815260200190600101906123f0565b50505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016125d7919061c236565b60006040518083038186803b1580156125ef57600080fd5b505afa158015612603573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401612683919061c236565b60006040518083038186803b15801561269b57600080fd5b505afa1580156126af573d6000803e3d6000fd5b5050505060006126bf838661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b815260040161270e919061c35f565b600060405180830381600087803b15801561272857600080fd5b505af115801561273c573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b815260040161279b919061c389565b6020604051808303816000875af11580156127ba573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127de919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b8152600401612833919061c45c565b600060405180830381600087803b15801561284d57600080fd5b505af1158015612861573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b81526004016128b2919061c35f565b600060405180830381600087803b1580156128cc57600080fd5b505af11580156128e0573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b31f01b828460006040518463ffffffff1660e01b81526004016129449392919061c8eb565b600060405180830381600087803b15801561295e57600080fd5b505af1158015612972573d6000803e3d6000fd5b505050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016129fa919061c236565b60006040518083038186803b158015612a1257600080fd5b505afa158015612a26573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401612aa6919061c236565b60006040518083038186803b158015612abe57600080fd5b505afa158015612ad2573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401612b27919061c236565b60006040518083038186803b158015612b3f57600080fd5b505afa158015612b53573d6000803e3d6000fd5b50505050600a81511115612b6657600a81525b612b6f8161a5cc565b90506000612b7d838661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b8152600401612bcc919061c35f565b600060405180830381600087803b158015612be657600080fd5b505af1158015612bfa573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401612c59919061c389565b6020604051808303816000875af1158015612c78573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c9c919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b8152600401612cf1919061c45c565b600060405180830381600087803b158015612d0b57600080fd5b505af1158015612d1f573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401612d70919061c35f565b600060405180830381600087803b158015612d8a57600080fd5b505af1158015612d9e573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663065d6c6982846040518363ffffffff1660e01b8152600401612dff92919061c922565b600060405180830381600087803b158015612e1957600080fd5b505af1158015612e2d573d6000803e3d6000fd5b505050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401612eb5919061c236565b60006040518083038186803b158015612ecd57600080fd5b505afa158015612ee1573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401612f61919061c236565b60006040518083038186803b158015612f7957600080fd5b505afa158015612f8d573d6000803e3d6000fd5b505050506000612f9d838661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b8152600401612fec919061c35f565b600060405180830381600087803b15801561300657600080fd5b505af115801561301a573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401613079919061c389565b6020604051808303816000875af1158015613098573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130bc919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b8152600401613111919061c45c565b600060405180830381600087803b15801561312b57600080fd5b505af115801561313f573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401613190919061c35f565b600060405180830381600087803b1580156131aa57600080fd5b505af11580156131be573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dac6c58782846040518363ffffffff1660e01b815260040161321f92919061c725565b600060405180830381600087803b15801561323957600080fd5b505af115801561324d573d6000803e3d6000fd5b505050505050505050565b606060188054806020026020016040519081016040528092919081815260200182805480156132dc57602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311613292575b5050505050905090565b6060601780548060200260200160405190810160405280929190818152602001828054801561336a57602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311613320575b5050505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016133f1919061c236565b60006040518083038186803b15801561340957600080fd5b505afa15801561341d573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401613472919061c236565b60006040518083038186803b15801561348a57600080fd5b505afa15801561349e573d6000803e3d6000fd5b5050505060006134ae838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b81526004016134fd919061c35f565b600060405180830381600087803b15801561351757600080fd5b505af115801561352b573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b815260040161358a919061c389565b6020604051808303816000875af11580156135a9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135cd919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0634745a4ee60e01b6040518263ffffffff1660e01b8152600401613622919061c45c565b600060405180830381600087803b15801561363c57600080fd5b505af1158015613650573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b81526004016136a1919061c35f565b600060405180830381600087803b1580156136bb57600080fd5b505af11580156136cf573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dac6c58782846040518363ffffffff1660e01b815260040161373092919061c725565b600060405180830381600087803b15801561374a57600080fd5b505af115801561375e573d6000803e3d6000fd5b5050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016137e5919061c236565b60006040518083038186803b1580156137fd57600080fd5b505afa158015613811573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401613866919061c236565b60006040518083038186803b15801561387e57600080fd5b505afa158015613892573d6000803e3d6000fd5b50505050600a815111156138a557600a81525b6138ae8161a773565b905060006138bc838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56856040518263ffffffff1660e01b815260040161390b919061c35f565b600060405180830381600087803b15801561392557600080fd5b505af1158015613939573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401613998919061c389565b6020604051808303816000875af11580156139b7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906139db919061c3b9565b5060005b8251811015613ab957737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015613a4457600080fd5b505af1158015613a58573d6000803e3d6000fd5b50505050613a7f838281518110613a7257613a7161c3e6565b5b602002602001015161a8aa565b827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a380806001019150506139df565b50601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166356cd2b9282846040518363ffffffff1660e01b8152600401613b1792919061c952565b600060405180830381600087803b158015613b3157600080fd5b505af1158015613b45573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015613ba557600080fd5b505af1158015613bb9573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6836040518263ffffffff1660e01b8152600401613c1a919061c755565b600060405180830381865afa158015613c37573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190613c60919061c807565b9050613c6e8151845161a8da565b60005b8151811015613ccd57613cc0828281518110613c9057613c8f61c3e6565b5b6020026020010151613cbb868481518110613cae57613cad61c3e6565b5b602002602001015161a8aa565b61aa0e565b8080600101915050613c71565b505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401613d52919061c236565b60006040518083038186803b158015613d6a57600080fd5b505afa158015613d7e573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401613dff919061c236565b60006040518083038186803b158015613e1757600080fd5b505afa158015613e2b573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401613eab919061c236565b60006040518083038186803b158015613ec357600080fd5b505afa158015613ed7573d6000803e3d6000fd5b505050506000613ee7838661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b8152600401613f36919061c35f565b600060405180830381600087803b158015613f5057600080fd5b505af1158015613f64573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401613fc3919061c389565b6020604051808303816000875af1158015613fe2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190614006919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561406357600080fd5b505af1158015614077573d6000803e3d6000fd5b505050508373ffffffffffffffffffffffffffffffffffffffff16817f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b815260040161410c919061c35f565b600060405180830381600087803b15801561412657600080fd5b505af115801561413a573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639630aff882866040518363ffffffff1660e01b815260040161419b92919061c4f1565b600060405180830381600087803b1580156141b557600080fd5b505af11580156141c9573d6000803e3d6000fd5b50505050614272601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ebc27b82836040518263ffffffff1660e01b815260040161422b919061c755565b602060405180830381865afa158015614248573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061426c919061c997565b8561aaa8565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b81526004016142bf919061c35f565b600060405180830381600087803b1580156142d957600080fd5b505af11580156142ed573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f182846040518363ffffffff1660e01b815260040161434e92919061c424565b600060405180830381600087803b15801561436857600080fd5b505af115801561437c573d6000803e3d6000fd5b5050505061442c601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6836040518263ffffffff1660e01b81526004016143de919061c755565b600060405180830381865afa1580156143fb573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190614424919061c807565b51600161a8da565b5050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016144b0919061c236565b60006040518083038186803b1580156144c857600080fd5b505afa1580156144dc573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401614531919061c236565b60006040518083038186803b15801561454957600080fd5b505afa15801561455d573d6000803e3d6000fd5b50505050600061456d838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b81526004016145bc919061c35f565b600060405180830381600087803b1580156145d657600080fd5b505af11580156145ea573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401614649919061c389565b6020604051808303816000875af1158015614668573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061468c919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156146e957600080fd5b505af11580156146fd573d6000803e3d6000fd5b5050505061470a8261a8aa565b817fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a3737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401614784919061c35f565b600060405180830381600087803b15801561479e57600080fd5b505af11580156147b2573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82846040518363ffffffff1660e01b815260040161481392919061c725565b600060405180830381600087803b15801561482d57600080fd5b505af1158015614841573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6836040518263ffffffff1660e01b81526004016148a2919061c755565b600060405180830381865afa1580156148bf573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052508101906148e8919061c807565b90506148f38161a5cc565b90506149228160008151811061490c5761490b61c3e6565b5b602002602001015161491d8561a8aa565b61aa0e565b5050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016149a6919061c236565b60006040518083038186803b1580156149be57600080fd5b505afa1580156149d2573d6000803e3d6000fd5b5050505060006149e2838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401614a31919061c35f565b600060405180830381600087803b158015614a4b57600080fd5b505af1158015614a5f573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401614abe919061c389565b6020604051808303816000875af1158015614add573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190614b01919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063526c768760e01b6040518263ffffffff1660e01b8152600401614b56919061c45c565b600060405180830381600087803b158015614b7057600080fd5b505af1158015614b84573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401614bd5919061c35f565b600060405180830381600087803b158015614bef57600080fd5b505af1158015614c03573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b31f01b828460006040518463ffffffff1660e01b8152600401614c679392919061c8eb565b600060405180830381600087803b158015614c8157600080fd5b505af1158015614c95573d6000803e3d6000fd5b5050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401614d1c919061c236565b60006040518083038186803b158015614d3457600080fd5b505afa158015614d48573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008451116040518263ffffffff1660e01b8152600401614d9d919061c236565b60006040518083038186803b158015614db557600080fd5b505afa158015614dc9573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401614e1e919061c236565b60006040518083038186803b158015614e3657600080fd5b505afa158015614e4a573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628351835114156040518263ffffffff1660e01b8152600401614ea0919061c236565b60006040518083038186803b158015614eb857600080fd5b505afa158015614ecc573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56856040518263ffffffff1660e01b8152600401614f1d919061c35f565b600060405180830381600087803b158015614f3757600080fd5b505af1158015614f4b573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b8152600401614fac919061c389565b6020604051808303816000875af1158015614fcb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190614fef919061c3b9565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063526c768760e01b6040518263ffffffff1660e01b8152600401615045919061c45c565b600060405180830381600087803b15801561505f57600080fd5b505af1158015615073573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4c9c5c48285856040518463ffffffff1660e01b81526004016150d69392919061c696565b600060405180830381600087803b1580156150f057600080fd5b505af1158015615104573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561516457600080fd5b505af1158015615178573d6000803e3d6000fd5b505050505050505050565b6060601b805480602002602001604051908101604052809291908181526020016000905b8282101561530557838290600052602060002090600202016040518060400160405290816000820180546151da9061c87f565b80601f01602080910402602001604051908101604052809291908181526020018280546152069061c87f565b80156152535780601f1061522857610100808354040283529160200191615253565b820191906000526020600020905b81548152906001019060200180831161523657829003601f168201915b50505050508152602001600182018054806020026020016040519081016040528092919081815260200182805480156152ed57602002820191906000526020600020906000905b82829054906101000a900460e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168152602001906004019060208260030104928301926001038202915080841161529a5790505b505050505081525050815260200190600101906151a7565b50505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b815260040161538b919061c236565b60006040518083038186803b1580156153a357600080fd5b505afa1580156153b7573d6000803e3d6000fd5b5050505060006153c7828461a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7846040518263ffffffff1660e01b8152600401615416919061c35f565b600060405180830381600087803b15801561543057600080fd5b505af1158015615444573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018836040518263ffffffff1660e01b81526004016154a3919061c389565b6020604051808303816000875af11580156154c2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906154e6919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7846040518263ffffffff1660e01b8152600401615534919061c35f565b600060405180830381600087803b15801561554e57600080fd5b505af1158015615562573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063ff7d580d60e01b6040518263ffffffff1660e01b81526004016155ba919061c45c565b600060405180830381600087803b1580156155d457600080fd5b505af11580156155e8573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639630aff88260006040518363ffffffff1660e01b815260040161564a92919061c4f1565b600060405180830381600087803b15801561566457600080fd5b505af1158015615678573d6000803e3d6000fd5b50505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016156fe919061c236565b60006040518083038186803b15801561571657600080fd5b505afa15801561572a573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b815260040161577f919061c236565b60006040518083038186803b15801561579757600080fd5b505afa1580156157ab573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56846040518263ffffffff1660e01b81526004016157fc919061c35f565b600060405180830381600087803b15801561581657600080fd5b505af115801561582a573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b815260040161588b919061c389565b6020604051808303816000875af11580156158aa573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906158ce919061c3b9565b9050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82846040518363ffffffff1660e01b815260040161592d92919061c725565b600060405180830381600087803b15801561594757600080fd5b505af115801561595b573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0632d86c03a60e01b6040518263ffffffff1660e01b81526004016159b3919061c45c565b600060405180830381600087803b1580156159cd57600080fd5b505af11580156159e1573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82846040518363ffffffff1660e01b8152600401615a4292919061c725565b600060405180830381600087803b158015615a5c57600080fd5b505af1158015615a70573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015615ad057600080fd5b505af1158015615ae4573d6000803e3d6000fd5b5050505050505050565b601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401615b91919061c236565b60006040518083038186803b158015615ba957600080fd5b505afa158015615bbd573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401615c3d919061c236565b60006040518083038186803b158015615c5557600080fd5b505afa158015615c69573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401615cbe919061c236565b60006040518083038186803b158015615cd657600080fd5b505afa158015615cea573d6000803e3d6000fd5b50505050600a81511115615cfd57600a81525b615d068161a5cc565b90506000815167ffffffffffffffff811115615d2557615d2461b05c565b5b604051908082528060200260200182016040528015615d535781602001602082028036833780820191505090505b50905060005b8251811015615d8f5780828281518110615d7657615d7561c3e6565b5b6020026020010181815250508080600101915050615d59565b506000615d9c848761a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56876040518263ffffffff1660e01b8152600401615deb919061c35f565b600060405180830381600087803b158015615e0557600080fd5b505af1158015615e19573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b8152600401615e78919061c389565b6020604051808303816000875af1158015615e97573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190615ebb919061c3b9565b5060005b8351811015615f7e57601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f183868481518110615f1a57615f1961c3e6565b5b60200260200101516040518363ffffffff1660e01b8152600401615f3f92919061c424565b600060405180830381600087803b158015615f5957600080fd5b505af1158015615f6d573d6000803e3d6000fd5b505050508080600101915050615ebf565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015615fdb57600080fd5b505af1158015615fef573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b8152600401616047919061c45c565b600060405180830381600087803b15801561606157600080fd5b505af1158015616075573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b81526004016160c6919061c35f565b600060405180830381600087803b1580156160e057600080fd5b505af11580156160f4573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4c9c5c48285856040518463ffffffff1660e01b81526004016161579392919061c696565b600060405180830381600087803b15801561617157600080fd5b505af1158015616185573d6000803e3d6000fd5b50505050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b815260040161620e919061c236565b60006040518083038186803b15801561622657600080fd5b505afa15801561623a573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008451116040518263ffffffff1660e01b815260040161628f919061c236565b60006040518083038186803b1580156162a757600080fd5b505afa1580156162bb573d6000803e3d6000fd5b50505050600a825111156162ce57600a82525b6162d78261a773565b91506162f2816000600185516162ed919061c31c565b61a6e9565b90506000616300848761a73e565b905061630a61aed7565b83838151811061631d5761631c61c3e6565b5b60200260200101518160a0015160000181905250737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56886040518263ffffffff1660e01b815260040161637e919061c35f565b600060405180830381600087803b15801561639857600080fd5b505af11580156163ac573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018866040518263ffffffff1660e01b815260040161640b919061c389565b6020604051808303816000875af115801561642a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061644e919061c3b9565b5060005b845181101561651157601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d848784815181106164ad576164ac61c3e6565b5b60200260200101516040518363ffffffff1660e01b81526004016164d292919061c725565b600060405180830381600087803b1580156164ec57600080fd5b505af1158015616500573d6000803e3d6000fd5b505050508080600101915050616452565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561656e57600080fd5b505af1158015616582573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633808a90b8884866040518463ffffffff1660e01b81526004016165e79392919061cb09565b602060405180830381865afa158015616604573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190616628919061c3b9565b905061664681616641898561ab6e90919063ffffffff16565b61aa0e565b5050505050505050565b6060601a805480602002602001604051908101604052809291908181526020016000905b828210156167205783829060005260206000200180546166939061c87f565b80601f01602080910402602001604051908101604052809291908181526020018280546166bf9061c87f565b801561670c5780601f106166e15761010080835404028352916020019161670c565b820191906000526020600020905b8154815290600101906020018083116166ef57829003601f168201915b505050505081526020019060010190616674565b50505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016167a6919061c236565b60006040518083038186803b1580156167be57600080fd5b505afa1580156167d2573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008451118015616818575060008351115b6040518263ffffffff1660e01b8152600401616834919061c236565b60006040518083038186803b15801561684c57600080fd5b505afa158015616860573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628280519060200120848051906020012014156040518263ffffffff1660e01b81526004016168c2919061c236565b60006040518083038186803b1580156168da57600080fd5b505afa1580156168ee573d6000803e3d6000fd5b5050505060006168fe848761a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7876040518263ffffffff1660e01b815260040161694d919061c35f565b600060405180830381600087803b15801561696757600080fd5b505af115801561697b573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b81526004016169da919061c389565b6020604051808303816000875af11580156169f9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190616a1d919061c3b9565b50616a2661aed7565b828160a0015160000181905250737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7886040518263ffffffff1660e01b8152600401616a80919061c35f565b600060405180830381600087803b158015616a9a57600080fd5b505af1158015616aae573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d83866040518363ffffffff1660e01b8152600401616b0f92919061c725565b600060405180830381600087803b158015616b2957600080fd5b505af1158015616b3d573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063d7abef4e60e01b6040518263ffffffff1660e01b8152600401616b95919061c45c565b600060405180830381600087803b158015616baf57600080fd5b505af1158015616bc3573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633808a90b8783856040518463ffffffff1660e01b8152600401616c269392919061cb09565b602060405180830381865afa158015616c43573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190616c67919061c3b9565b5050505050505050565b6060601d805480602002602001604051908101604052809291908181526020016000905b82821015616db757838290600052602060002090600202016040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200160018201805480602002602001604051908101604052809291908181526020018280548015616d9f57602002820191906000526020600020906000905b82829054906101000a900460e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191681526020019060040190602082600301049283019260010382029150808411616d4c5790505b50505050508152505081526020019060010190616c95565b50505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401616e3d919061c236565b60006040518083038186803b158015616e5557600080fd5b505afa158015616e69573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008451116040518263ffffffff1660e01b8152600401616ebe919061c236565b60006040518083038186803b158015616ed657600080fd5b505afa158015616eea573d6000803e3d6000fd5b50505050600a82511115616efd57600a82525b616f068261a5cc565b9150616f2181600060018551616f1c919061c31c565b61a6e9565b90506000616f2f848661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56866040518263ffffffff1660e01b8152600401616f7e919061c35f565b600060405180830381600087803b158015616f9857600080fd5b505af1158015616fac573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b815260040161700b919061c389565b6020604051808303816000875af115801561702a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061704e919061c3b9565b5060005b835181101561711157601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f1838684815181106170ad576170ac61c3e6565b5b60200260200101516040518363ffffffff1660e01b81526004016170d292919061c424565b600060405180830381600087803b1580156170ec57600080fd5b505af1158015617100573d6000803e3d6000fd5b505050508080600101915050617052565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561716e57600080fd5b505af1158015617182573d6000803e3d6000fd5b505050508282815181106171995761719861c3e6565b5b6020026020010151817f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b31f01b828585815181106172205761721f61c3e6565b5b6020026020010151856040518463ffffffff1660e01b81526004016172479392919061c4ba565b600060405180830381600087803b15801561726157600080fd5b505af1158015617275573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156172d557600080fd5b505af11580156172e9573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6836040518263ffffffff1660e01b815260040161734a919061c755565b600060405180830381865afa158015617367573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190617390919061c807565b90506173aa8151600186516173a5919061c31c565b61a8da565b60005b8151811015617401576173f48282815181106173cc576173cb61c3e6565b5b60200260200101518686815181106173e7576173e661c3e6565b5b602002602001015161a974565b80806001019150506173ad565b50505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401617487919061c236565b60006040518083038186803b15801561749f57600080fd5b505afa1580156174b3573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401617533919061c236565b60006040518083038186803b15801561754b57600080fd5b505afa15801561755f573d6000803e3d6000fd5b50505050600061756f838661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b81526004016175be919061c35f565b600060405180830381600087803b1580156175d857600080fd5b505af11580156175ec573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b815260040161764b919061c389565b6020604051808303816000875af115801561766a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061768e919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b81526004016176e3919061c45c565b600060405180830381600087803b1580156176fd57600080fd5b505af1158015617711573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b8152600401617762919061c35f565b600060405180830381600087803b15801561777c57600080fd5b505af1158015617790573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f182846040518363ffffffff1660e01b81526004016177f192919061c424565b600060405180830381600087803b15801561780b57600080fd5b505af115801561781f573d6000803e3d6000fd5b505050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016178a7919061c236565b60006040518083038186803b1580156178bf57600080fd5b505afa1580156178d3573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56846040518263ffffffff1660e01b8152600401617924919061c35f565b600060405180830381600087803b15801561793e57600080fd5b505af1158015617952573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b81526004016179b3919061c389565b6020604051808303816000875af11580156179d2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906179f6919061c3b9565b9050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f182617a408561a8aa565b6040518363ffffffff1660e01b8152600401617a5d92919061c424565b600060405180830381600087803b158015617a7757600080fd5b505af1158015617a8b573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0632d86c03a60e01b6040518263ffffffff1660e01b8152600401617ae3919061c45c565b600060405180830381600087803b158015617afd57600080fd5b505af1158015617b11573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82846040518363ffffffff1660e01b8152600401617b7292919061c725565b600060405180830381600087803b158015617b8c57600080fd5b505af1158015617ba0573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015617c0057600080fd5b505af1158015617c14573d6000803e3d6000fd5b5050505050505050565b6060601c805480602002602001604051908101604052809291908181526020016000905b82821015617d6457838290600052602060002090600202016040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200160018201805480602002602001604051908101604052809291908181526020018280548015617d4c57602002820191906000526020600020906000905b82829054906101000a900460e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191681526020019060040190602082600301049283019260010382029150808411617cf95790505b50505050508152505081526020019060010190617c42565b50505050905090565b60606019805480602002602001604051908101604052809291908181526020016000905b82821015617e3d578382906000526020600020018054617db09061c87f565b80601f0160208091040260200160405190810160405280929190818152602001828054617ddc9061c87f565b8015617e295780601f10617dfe57610100808354040283529160200191617e29565b820191906000526020600020905b815481529060010190602001808311617e0c57829003601f168201915b505050505081526020019060010190617d91565b50505050905090565b6000600860009054906101000a900460ff1615617e665760019050617f51565b6000801b7f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff1663667f9d707f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c7f6661696c656400000000000000000000000000000000000000000000000000006040518363ffffffff1660e01b8152600401617f0b92919061cb47565b602060405180830381865afa158015617f28573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190617f4c919061c3b9565b141590505b90565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401617fd1919061c236565b60006040518083038186803b158015617fe957600080fd5b505afa158015617ffd573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401618052919061c236565b60006040518083038186803b15801561806a57600080fd5b505afa15801561807e573d6000803e3d6000fd5b50505050600a8151111561809157600a81525b61809a8161a5cc565b905060006180a8838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56856040518263ffffffff1660e01b81526004016180f7919061c35f565b600060405180830381600087803b15801561811157600080fd5b505af1158015618125573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401618184919061c389565b6020604051808303816000875af11580156181a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906181c7919061c3b9565b5060005b825181101561829d57737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561823057600080fd5b505af1158015618244573d6000803e3d6000fd5b5050505082818151811061825b5761825a61c3e6565b5b6020026020010151827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a380806001019150506181cb565b50601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663065d6c6982846040518363ffffffff1660e01b81526004016182fb92919061c922565b600060405180830381600087803b15801561831557600080fd5b505af1158015618329573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561838957600080fd5b505af115801561839d573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6836040518263ffffffff1660e01b81526004016183fe919061c755565b600060405180830381865afa15801561841b573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190618444919061c807565b90506184528151845161a8da565b60005b81518110156184a95761849c8282815181106184745761847361c3e6565b5b602002602001015185838151811061848f5761848e61c3e6565b5b602002602001015161aa0e565b8080600101915050618455565b505050505050565b6000737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7826040518263ffffffff1660e01b8152600401618500919061c35f565b600060405180830381600087803b15801561851a57600080fd5b505af115801561852e573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e063ff7d580d60e01b6040518263ffffffff1660e01b8152600401618586919061c45c565b600060405180830381600087803b1580156185a057600080fd5b505af11580156185b4573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018836040518263ffffffff1660e01b8152600401618613919061c389565b6020604051808303816000875af1158015618632573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190618656919061c3b9565b505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016186d8919061c236565b60006040518083038186803b1580156186f057600080fd5b505afa158015618704573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b8152600401618759919061c236565b60006040518083038186803b15801561877157600080fd5b505afa158015618785573d6000803e3d6000fd5b505050506000618795838661a73e565b905061879f61aed7565b828160a0015160000181905250737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56876040518263ffffffff1660e01b81526004016187f9919061c35f565b600060405180830381600087803b15801561881357600080fd5b505af1158015618827573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018856040518263ffffffff1660e01b8152600401618886919061c389565b6020604051808303816000875af11580156188a5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906188c9919061c3b9565b50601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d83856040518363ffffffff1660e01b815260040161892792919061c725565b600060405180830381600087803b15801561894157600080fd5b505af1158015618955573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156189b557600080fd5b505af11580156189c9573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633808a90b8784866040518463ffffffff1660e01b8152600401618a2e9392919061cb09565b602060405180830381865afa158015618a4b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190618a6f919061c3b9565b9050618a8d81618a88888561ab6e90919063ffffffff16565b61aa0e565b50505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401618b13919061c236565b60006040518083038186803b158015618b2b57600080fd5b505afa158015618b3f573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56846040518263ffffffff1660e01b8152600401618b90919061c35f565b600060405180830381600087803b158015618baa57600080fd5b505af1158015618bbe573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401618c1f919061c389565b6020604051808303816000875af1158015618c3e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190618c62919061c3b9565b9050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f182846040518363ffffffff1660e01b8152600401618cc192919061c424565b600060405180830381600087803b158015618cdb57600080fd5b505af1158015618cef573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0632d86c03a60e01b6040518263ffffffff1660e01b8152600401618d47919061c45c565b600060405180830381600087803b158015618d6157600080fd5b505af1158015618d75573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f182846040518363ffffffff1660e01b8152600401618dd692919061c424565b600060405180830381600087803b158015618df057600080fd5b505af1158015618e04573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015618e6457600080fd5b505af1158015618e78573d6000803e3d6000fd5b5050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401618eff919061c236565b60006040518083038186803b158015618f1757600080fd5b505afa158015618f2b573d6000803e3d6000fd5b505050506000618f3b828461a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015618f9957600080fd5b505af1158015618fad573d6000803e3d6000fd5b505050508273ffffffffffffffffffffffffffffffffffffffff16817f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a3737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7846040518263ffffffff1660e01b8152600401619042919061c35f565b600060405180830381600087803b15801561905c57600080fd5b505af1158015619070573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b81526004016190d1919061c389565b6020604051808303816000875af11580156190f0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190619114919061c3b9565b9050619120818361aa0e565b6191c5601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ebc27b82846040518263ffffffff1660e01b815260040161917e919061c755565b602060405180830381865afa15801561919b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906191bf919061c997565b8561aaa8565b50505050565b6060601580548060200260200160405190810160405280929190818152602001828054801561924f57602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311619205575b5050505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016192d6919061c236565b60006040518083038186803b1580156192ee57600080fd5b505afa158015619302573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56846040518263ffffffff1660e01b8152600401619353919061c35f565b600060405180830381600087803b15801561936d57600080fd5b505af1158015619381573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b81526004016193e2919061c389565b6020604051808303816000875af1158015619401573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190619425919061c3b9565b9050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82846040518363ffffffff1660e01b815260040161948492919061c725565b600060405180830381600087803b15801561949e57600080fd5b505af11580156194b2573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0632d86c03a60e01b6040518263ffffffff1660e01b815260040161950a919061c45c565b600060405180830381600087803b15801561952457600080fd5b505af1158015619538573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f1826195848561a8aa565b6040518363ffffffff1660e01b81526004016195a192919061c424565b600060405180830381600087803b1580156195bb57600080fd5b505af11580156195cf573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561962f57600080fd5b505af1158015619643573d6000803e3d6000fd5b5050505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016196ca919061c236565b60006040518083038186803b1580156196e257600080fd5b505afa1580156196f6573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008351116040518263ffffffff1660e01b815260040161974b919061c236565b60006040518083038186803b15801561976357600080fd5b505afa158015619777573d6000803e3d6000fd5b50505050600a8151111561978a57600a81525b6197938161a5cc565b905060006197a1838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56856040518263ffffffff1660e01b81526004016197f0919061c35f565b600060405180830381600087803b15801561980a57600080fd5b505af115801561981e573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b815260040161987d919061c389565b6020604051808303816000875af115801561989c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906198c0919061c3b9565b50601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663065d6c6982846040518363ffffffff1660e01b815260040161991e92919061c922565b600060405180830381600087803b15801561993857600080fd5b505af115801561994c573d6000803e3d6000fd5b505050506000825167ffffffffffffffff81111561996d5761996c61b05c565b5b60405190808252806020026020018201604052801561999b5781602001602082028036833780820191505090505b50905060005b8351811015619a09578360018286516199ba919061c31c565b6199c4919061c31c565b815181106199d5576199d461c3e6565b5b60200260200101518282815181106199f0576199ef61c3e6565b5b60200260200101818152505080806001019150506199a1565b506000835167ffffffffffffffff811115619a2757619a2661b05c565b5b604051908082528060200260200182016040528015619a555781602001602082028036833780820191505090505b50905060005b8451811015619aa9576001818651619a73919061c31c565b619a7d919061c31c565b828281518110619a9057619a8f61c3e6565b5b6020026020010181815250508080600101915050619a5b565b5060005b8451811015619b7f57737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015619b1257600080fd5b505af1158015619b26573d6000803e3d6000fd5b50505050828181518110619b3d57619b3c61c3e6565b5b6020026020010151847f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a38080600101915050619aad565b50601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4c9c5c48484846040518463ffffffff1660e01b8152600401619bdf9392919061c696565b600060405180830381600087803b158015619bf957600080fd5b505af1158015619c0d573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015619c6d57600080fd5b505af1158015619c81573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6856040518263ffffffff1660e01b8152600401619ce2919061c755565b600060405180830381865afa158015619cff573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190619d28919061c807565b9050619d368151600061a8da565b50505050505050565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401619dbc919061c236565b60006040518083038186803b158015619dd457600080fd5b505afa158015619de8573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e5628473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b8152600401619e68919061c236565b60006040518083038186803b158015619e8057600080fd5b505afa158015619e94573d6000803e3d6000fd5b505050506000619ea4838661a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7866040518263ffffffff1660e01b8152600401619ef3919061c35f565b600060405180830381600087803b158015619f0d57600080fd5b505af1158015619f21573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b8152600401619f80919061c389565b6020604051808303816000875af1158015619f9f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190619fc3919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c31eb0e0637c2411e960e01b6040518263ffffffff1660e01b815260040161a018919061c45c565b600060405180830381600087803b15801561a03257600080fd5b505af115801561a046573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b815260040161a097919061c35f565b600060405180830381600087803b15801561a0b157600080fd5b505af115801561a0c5573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82846040518363ffffffff1660e01b815260040161a12692919061c725565b600060405180830381600087803b15801561a14057600080fd5b505af115801561a154573d6000803e3d6000fd5b505050505050505050565b601f60009054906101000a900460ff1681565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b815260040161a1ef919061c236565b60006040518083038186803b15801561a20757600080fd5b505afa15801561a21b573d6000803e3d6000fd5b50505050600061a22b838561a73e565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b815260040161a27a919061c35f565b600060405180830381600087803b15801561a29457600080fd5b505af115801561a2a8573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018846040518263ffffffff1660e01b815260040161a307919061c389565b6020604051808303816000875af115801561a326573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061a34a919061c3b9565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663440ed10d6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561a3a757600080fd5b505af115801561a3bb573d6000803e3d6000fd5b5050505081817fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a3737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ca669fa7856040518263ffffffff1660e01b815260040161a43a919061c35f565b600060405180830381600087803b15801561a45457600080fd5b505af115801561a468573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663520994f182846040518363ffffffff1660e01b815260040161a4c992919061c424565b600060405180830381600087803b15801561a4e357600080fd5b505af115801561a4f7573d6000803e3d6000fd5b505050506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4364de6836040518263ffffffff1660e01b815260040161a558919061c755565b600060405180830381865afa15801561a575573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f8201168201806040525081019061a59e919061c807565b905061a5c58160008151811061a5b75761a5b661c3e6565b5b60200260200101518461aa0e565b5050505050565b6060815167ffffffffffffffff81111561a5e95761a5e861b05c565b5b60405190808252806020026020018201604052801561a6175781602001602082028036833780820191505090505b5090506000805b835181101561a6df576000805b8381101561a6845785838151811061a6465761a64561c3e6565b5b602002602001015185828151811061a6615761a66061c3e6565b5b60200260200101510361a677576001915061a684565b808060010191505061a62b565b508061a6d15784828151811061a69d5761a69c61c3e6565b5b602002602001015184848061a6b19061cb70565b95508151811061a6c45761a6c361c3e6565b5b6020026020010181815250505b50808060010191505061a61e565b5080825250919050565b600061a6f684848461abd1565b905061a7376040518060400160405280600c81526020017f426f756e6420726573756c7400000000000000000000000000000000000000008152508261ade0565b9392505050565b6000828260405160200161a75392919061cc21565b60405160208183030381529060405261a76b9061cc7f565b905092915050565b6060815167ffffffffffffffff81111561a7905761a78f61b05c565b5b60405190808252806020026020018201604052801561a7c357816020015b606081526020019060019003908161a7ae5790505b5090506000805b835181101561a8a05760008061a7f986848151811061a7ec5761a7eb61c3e6565b5b602002602001015161a8aa565b905060005b8481101561a8455761a82986828151811061a81c5761a81b61c3e6565b5b602002602001015161a8aa565b820361a838576001925061a845565b808060010191505061a7fe565b508161a8915785838151811061a85e5761a85d61c3e6565b5b602002602001015185858061a8729061cb70565b96508151811061a8855761a88461c3e6565b5b60200260200101819052505b5050808060010191505061a7ca565b5080825250919050565b60008160405160200161a8bd919061cd22565b604051602081830303815290604052805190602001209050919050565b80821461a970577f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff166398296c5483836040518363ffffffff1660e01b815260040161a93f92919061cd39565b60006040518083038186803b15801561a95757600080fd5b505afa15801561a96b573d6000803e3d6000fd5b505050505b5050565b80820361aa0a577f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff1663898e83fc83836040518363ffffffff1660e01b815260040161a9d992919061c424565b60006040518083038186803b15801561a9f157600080fd5b505afa15801561aa05573d6000803e3d6000fd5b505050505b5050565b80821461aaa4577f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff16637c84c69b83836040518363ffffffff1660e01b815260040161aa7392919061c424565b60006040518083038186803b15801561aa8b57600080fd5b505afa15801561aa9f573d6000803e3d6000fd5b505050505b5050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161461ab6a577f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff1663515361f683836040518363ffffffff1660e01b815260040161ab3992919061cd62565b60006040518083038186803b15801561ab5157600080fd5b505afa15801561ab65573d6000803e3d6000fd5b505050505b5050565b600060405160200161ab7f9061cdd7565b60405160208183030381529060405280519060200120828460600151856040015160405160200161abb3949392919061ce0d565b60405160208183030381529060405280519060200120905092915050565b60008183111561ac16576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161ac0d9061cecd565b60405180910390fd5b82841015801561ac265750818411155b1561ac335783905061add9565b60006001848461ac43919061c31c565b61ac4d919061c477565b90506003851115801561ac5f57508481115b1561ac7857848461ac70919061c477565b91505061add9565b60037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff61aca5919061c31c565b851015801561acde5750847fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff61acdb919061c31c565b81115b1561ad2257847fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff61ad0f919061c31c565b8361ad1a919061c31c565b91505061add9565b8285111561ad7e576000838661ad38919061c31c565b90506000828261ad48919061cf1c565b90506000810361ad5d5784935050505061add9565b6001818761ad6b919061c477565b61ad75919061c31c565b9350505061add7565b8385101561add6576000858561ad94919061c31c565b90506000828261ada4919061cf1c565b90506000810361adb95785935050505061add9565b6001818661adc7919061c31c565b61add1919061c477565b935050505b5b505b9392505050565b61ae78828260405160240161adf692919061cf4d565b6040516020818303038152906040527fb60e72cc000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505061ae7c565b5050565b61ae938161ae8b61ae9661aebf565b63ffffffff16565b50565b60008151905060006a636f6e736f6c652e6c6f679050602083016000808483855afa5050505050565b61af4e819050919050565b6123938061cfad83390190565b6040518060c00160405280600073ffffffffffffffffffffffffffffffffffffffff16815260200160007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200160008019168152602001600080191681526020016060815260200161af4861af58565b81525090565b61af5661cf7d565b565b604051806040016040528060608152602001600067ffffffffffffffff1681525090565b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061afbb8261af90565b9050919050565b61afcb8161afb0565b811461afd657600080fd5b50565b60008135905061afe88161afc2565b92915050565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b61b0238161afee565b811461b02e57600080fd5b50565b60008135905061b0408161b01a565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61b0948261b04b565b810181811067ffffffffffffffff8211171561b0b35761b0b261b05c565b5b80604052505050565b600061b0c661af7c565b905061b0d2828261b08b565b919050565b600067ffffffffffffffff82111561b0f25761b0f161b05c565b5b602082029050602081019050919050565b600080fd5b6000819050919050565b61b11b8161b108565b811461b12657600080fd5b50565b60008135905061b1388161b112565b92915050565b600061b15161b14c8461b0d7565b61b0bc565b9050808382526020820190506020840283018581111561b1745761b17361b103565b5b835b8181101561b19d578061b189888261b129565b84526020840193505060208101905061b176565b5050509392505050565b600082601f83011261b1bc5761b1bb61b046565b5b813561b1cc84826020860161b13e565b91505092915050565b6000819050919050565b61b1e88161b1d5565b811461b1f357600080fd5b50565b60008135905061b2058161b1df565b92915050565b6000806000806080858703121561b2255761b22461af86565b5b600061b2338782880161afd9565b945050602061b2448782880161b031565b935050604085013567ffffffffffffffff81111561b2655761b26461af8b565b5b61b2718782880161b1a7565b925050606061b2828782880161b1f6565b91505092959194509250565b60008060006060848603121561b2a75761b2a661af86565b5b600061b2b58682870161afd9565b935050602061b2c68682870161afd9565b925050604061b2d78682870161b031565b9150509250925092565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61b3168161afb0565b82525050565b600061b328838361b30d565b60208301905092915050565b6000602082019050919050565b600061b34c8261b2e1565b61b356818561b2ec565b935061b3618361b2fd565b8060005b8381101561b39257815161b379888261b31c565b975061b3848361b334565b92505060018101905061b365565b5085935050505092915050565b6000602082019050818103600083015261b3b9818461b341565b905092915050565b600067ffffffffffffffff82111561b3dc5761b3db61b05c565b5b602082029050602081019050919050565b600061b40061b3fb8461b3c1565b61b0bc565b9050808382526020820190506020840283018581111561b4235761b42261b103565b5b835b8181101561b44c578061b438888261b1f6565b84526020840193505060208101905061b425565b5050509392505050565b600082601f83011261b46b5761b46a61b046565b5b813561b47b84826020860161b3ed565b91505092915050565b6000806000806080858703121561b49e5761b49d61af86565b5b600061b4ac8782880161afd9565b945050602061b4bd8782880161b031565b935050604085013567ffffffffffffffff81111561b4de5761b4dd61af8b565b5b61b4ea8782880161b1a7565b925050606085013567ffffffffffffffff81111561b50b5761b50a61af8b565b5b61b5178782880161b456565b91505092959194509250565b600067ffffffffffffffff82111561b53e5761b53d61b05c565b5b602082029050602081019050919050565b600080fd5b600067ffffffffffffffff82111561b56f5761b56e61b05c565b5b61b5788261b04b565b9050602081019050919050565b82818337600083830152505050565b600061b5a761b5a28461b554565b61b0bc565b90508281526020810184848401111561b5c35761b5c261b54f565b5b61b5ce84828561b585565b509392505050565b600082601f83011261b5eb5761b5ea61b046565b5b813561b5fb84826020860161b594565b91505092915050565b600061b61761b6128461b523565b61b0bc565b9050808382526020820190506020840283018581111561b63a5761b63961b103565b5b835b8181101561b68157803567ffffffffffffffff81111561b65f5761b65e61b046565b5b80860161b66c898261b5d6565b8552602085019450505060208101905061b63c565b5050509392505050565b600082601f83011261b6a05761b69f61b046565b5b813561b6b084826020860161b604565b91505092915050565b6000806000806080858703121561b6d35761b6d261af86565b5b600061b6e18782880161afd9565b945050602061b6f28782880161b031565b935050604085013567ffffffffffffffff81111561b7135761b71261af8b565b5b61b71f8782880161b68b565b925050606061b7308782880161b1f6565b91505092959194509250565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561b7ce57808201518184015260208101905061b7b3565b60008484015250505050565b600061b7e58261b794565b61b7ef818561b79f565b935061b7ff81856020860161b7b0565b61b8088161b04b565b840191505092915050565b600061b81f838361b7da565b905092915050565b6000602082019050919050565b600061b83f8261b768565b61b849818561b773565b93508360208202850161b85b8561b784565b8060005b8581101561b897578484038952815161b878858261b813565b945061b8838361b827565b925060208a0199505060018101905061b85f565b50829750879550505050505092915050565b600060408301600083015161b8c1600086018261b30d565b506020830151848203602086015261b8d9828261b834565b9150508091505092915050565b600061b8f2838361b8a9565b905092915050565b6000602082019050919050565b600061b9128261b73c565b61b91c818561b747565b93508360208202850161b92e8561b758565b8060005b8581101561b96a578484038952815161b94b858261b8e6565b945061b9568361b8fa565b925060208a0199505060018101905061b932565b50829750879550505050505092915050565b6000602082019050818103600083015261b996818461b907565b905092915050565b6000806000806080858703121561b9b85761b9b761af86565b5b600061b9c68782880161afd9565b945050602061b9d78782880161afd9565b935050604061b9e88782880161b031565b925050606061b9f98782880161b129565b91505092959194509250565b6000806000806080858703121561ba1f5761ba1e61af86565b5b600061ba2d8782880161afd9565b945050602061ba3e8782880161afd9565b935050604061ba4f8782880161b031565b925050606085013567ffffffffffffffff81111561ba705761ba6f61af8b565b5b61ba7c8782880161b1a7565b91505092959194509250565b6000806000806080858703121561baa25761baa161af86565b5b600061bab08782880161afd9565b945050602061bac18782880161afd9565b935050604061bad28782880161b031565b925050606085013567ffffffffffffffff81111561baf35761baf261af8b565b5b61baff8782880161b5d6565b91505092959194509250565b60008060006060848603121561bb245761bb2361af86565b5b600061bb328682870161afd9565b935050602061bb438682870161b031565b925050604084013567ffffffffffffffff81111561bb645761bb6361af8b565b5b61bb708682870161b5d6565b9150509250925092565b60008060006060848603121561bb935761bb9261af86565b5b600061bba18682870161afd9565b935050602061bbb28682870161b031565b925050604084013567ffffffffffffffff81111561bbd35761bbd261af8b565b5b61bbdf8682870161b68b565b9150509250925092565b60008060006060848603121561bc025761bc0161af86565b5b600061bc108682870161afd9565b935050602061bc218682870161b031565b925050604061bc328682870161b129565b9150509250925092565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b61bcc98161bc94565b82525050565b600061bcdb838361bcc0565b60208301905092915050565b6000602082019050919050565b600061bcff8261bc68565b61bd09818561bc73565b935061bd148361bc84565b8060005b8381101561bd4557815161bd2c888261bccf565b975061bd378361bce7565b92505060018101905061bd18565b5085935050505092915050565b6000604083016000830151848203600086015261bd6f828261b7da565b9150506020830151848203602086015261bd89828261bcf4565b9150508091505092915050565b600061bda2838361bd52565b905092915050565b6000602082019050919050565b600061bdc28261bc3c565b61bdcc818561bc47565b93508360208202850161bdde8561bc58565b8060005b8581101561be1a578484038952815161bdfb858261bd96565b945061be068361bdaa565b925060208a0199505060018101905061bde2565b50829750879550505050505092915050565b6000602082019050818103600083015261be46818461bdb7565b905092915050565b6000806040838503121561be655761be6461af86565b5b600061be738582860161afd9565b925050602061be848582860161b031565b9150509250929050565b6000819050919050565b600061beb361beae61bea98461af90565b61be8e565b61af90565b9050919050565b600061bec58261be98565b9050919050565b600061bed78261beba565b9050919050565b61bee78161becc565b82525050565b600060208201905061bf02600083018461bede565b92915050565b600080600080600060a0868803121561bf245761bf2361af86565b5b600061bf328882890161afd9565b955050602061bf438882890161afd9565b945050604061bf548882890161b031565b935050606086013567ffffffffffffffff81111561bf755761bf7461af8b565b5b61bf818882890161b68b565b925050608061bf928882890161b1f6565b9150509295509295909350565b600082825260208201905092915050565b600061bfbb8261b768565b61bfc5818561bf9f565b93508360208202850161bfd78561b784565b8060005b8581101561c013578484038952815161bff4858261b813565b945061bfff8361b827565b925060208a0199505060018101905061bfdb565b50829750879550505050505092915050565b6000602082019050818103600083015261c03f818461bfb0565b905092915050565b600080600080600060a0868803121561c0635761c06261af86565b5b600061c0718882890161afd9565b955050602061c0828882890161afd9565b945050604061c0938882890161b031565b935050606086013567ffffffffffffffff81111561c0b45761c0b361af8b565b5b61c0c08882890161b5d6565b925050608086013567ffffffffffffffff81111561c0e15761c0e061af8b565b5b61c0ed8882890161b5d6565b9150509295509295909350565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600060408301600083015161c13e600086018261b30d565b506020830151848203602086015261c156828261bcf4565b9150508091505092915050565b600061c16f838361c126565b905092915050565b6000602082019050919050565b600061c18f8261c0fa565b61c199818561c105565b93508360208202850161c1ab8561c116565b8060005b8581101561c1e7578484038952815161c1c8858261c163565b945061c1d38361c177565b925060208a0199505060018101905061c1af565b50829750879550505050505092915050565b6000602082019050818103600083015261c213818461c184565b905092915050565b60008115159050919050565b61c2308161c21b565b82525050565b600060208201905061c24b600083018461c227565b92915050565b60008060006060848603121561c26a5761c26961af86565b5b600061c2788682870161afd9565b935050602061c2898682870161b031565b925050604084013567ffffffffffffffff81111561c2aa5761c2a961af8b565b5b61c2b68682870161b1a7565b9150509250925092565b60006020828403121561c2d65761c2d561af86565b5b600061c2e48482850161b031565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061c3278261b1d5565b915061c3328361b1d5565b925082820390508181111561c34a5761c34961c2ed565b5b92915050565b61c3598161afb0565b82525050565b600060208201905061c374600083018461c350565b92915050565b61c3838161afee565b82525050565b600060208201905061c39e600083018461c37a565b92915050565b60008151905061c3b38161b112565b92915050565b60006020828403121561c3cf5761c3ce61af86565b5b600061c3dd8482850161c3a4565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b61c41e8161b108565b82525050565b600060408201905061c439600083018561c415565b61c446602083018461c415565b9392505050565b61c4568161bc94565b82525050565b600060208201905061c471600083018461c44d565b92915050565b600061c4828261b1d5565b915061c48d8361b1d5565b925082820190508082111561c4a55761c4a461c2ed565b5b92915050565b61c4b48161b1d5565b82525050565b600060608201905061c4cf600083018661c415565b61c4dc602083018561c415565b61c4e9604083018461c4ab565b949350505050565b600060408201905061c506600083018561c415565b61c513602083018461c350565b9392505050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61c54f8161b108565b82525050565b600061c561838361c546565b60208301905092915050565b6000602082019050919050565b600061c5858261c51a565b61c58f818561c525565b935061c59a8361c536565b8060005b8381101561c5cb57815161c5b2888261c555565b975061c5bd8361c56d565b92505060018101905061c59e565b5085935050505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61c60d8161b1d5565b82525050565b600061c61f838361c604565b60208301905092915050565b6000602082019050919050565b600061c6438261c5d8565b61c64d818561c5e3565b935061c6588361c5f4565b8060005b8381101561c68957815161c670888261c613565b975061c67b8361c62b565b92505060018101905061c65c565b5085935050505092915050565b600060608201905061c6ab600083018661c415565b818103602083015261c6bd818561c57a565b9050818103604083015261c6d1818461c638565b9050949350505050565b600082825260208201905092915050565b600061c6f78261b794565b61c701818561c6db565b935061c71181856020860161b7b0565b61c71a8161b04b565b840191505092915050565b600060408201905061c73a600083018561c415565b818103602083015261c74c818461c6ec565b90509392505050565b600060208201905061c76a600083018461c415565b92915050565b600061c78361c77e8461b0d7565b61b0bc565b9050808382526020820190506020840283018581111561c7a65761c7a561b103565b5b835b8181101561c7cf578061c7bb888261c3a4565b84526020840193505060208101905061c7a8565b5050509392505050565b600082601f83011261c7ee5761c7ed61b046565b5b815161c7fe84826020860161c770565b91505092915050565b60006020828403121561c81d5761c81c61af86565b5b600082015167ffffffffffffffff81111561c83b5761c83a61af8b565b5b61c8478482850161c7d9565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000600282049050600182168061c89757607f821691505b60208210810361c8aa5761c8a961c850565b5b50919050565b6000819050919050565b600061c8d561c8d061c8cb8461c8b0565b61be8e565b61b1d5565b9050919050565b61c8e58161c8ba565b82525050565b600060608201905061c900600083018661c415565b61c90d602083018561c415565b61c91a604083018461c8dc565b949350505050565b600060408201905061c937600083018561c415565b818103602083015261c949818461c57a565b90509392505050565b600060408201905061c967600083018561c415565b818103602083015261c979818461bfb0565b90509392505050565b60008151905061c9918161afc2565b92915050565b60006020828403121561c9ad5761c9ac61af86565b5b600061c9bb8482850161c982565b91505092915050565b600081519050919050565b600082825260208201905092915050565b600061c9eb8261c9c4565b61c9f5818561c9cf565b935061ca0581856020860161b7b0565b61ca0e8161b04b565b840191505092915050565b600067ffffffffffffffff82169050919050565b61ca368161ca19565b82525050565b6000604083016000830151848203600086015261ca59828261b7da565b915050602083015161ca6e602086018261ca2d565b508091505092915050565b600060c08301600083015161ca91600086018261b30d565b50602083015161caa4602086018261bcc0565b50604083015161cab7604086018261c546565b50606083015161caca606086018261c546565b506080830151848203608086015261cae2828261c9e0565b91505060a083015184820360a086015261cafc828261ca3c565b9150508091505092915050565b600060608201905061cb1e600083018661c350565b818103602083015261cb30818561ca79565b905061cb3f604083018461c415565b949350505050565b600060408201905061cb5c600083018561c350565b61cb69602083018461c415565b9392505050565b600061cb7b8261b1d5565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361cbad5761cbac61c2ed565b5b600182019050919050565b6000819050919050565b61cbd361cbce8261afee565b61cbb8565b82525050565b60008160601b9050919050565b600061cbf18261cbd9565b9050919050565b600061cc038261cbe6565b9050919050565b61cc1b61cc168261afb0565b61cbf8565b82525050565b600061cc2d828561cbc2565b600c8201915061cc3d828461cc0a565b6014820191508190509392505050565b6000819050602082019050919050565b600061cc69825161b108565b80915050919050565b600082821b905092915050565b600061cc8a8261c9c4565b8261cc948461cc4d565b905061cc9f8161cc5d565b9250602082101561ccdf5761ccda7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8360200360080261cc72565b831692505b5050919050565b600081905092915050565b600061ccfc8261b794565b61cd06818561cce6565b935061cd1681856020860161b7b0565b80840191505092915050565b600061cd2e828461ccf1565b915081905092915050565b600060408201905061cd4e600083018561c4ab565b61cd5b602083018461c4ab565b9392505050565b600060408201905061cd77600083018561c350565b61cd84602083018461c350565b9392505050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b600061cdc160158361cce6565b915061cdcc8261cd8b565b601582019050919050565b600061cde28261cdb4565b9150819050919050565b6000819050919050565b61ce0761ce028261b108565b61cdec565b82525050565b600061ce19828761cdf6565b60208201915061ce29828661cc0a565b60148201915061ce39828561cdf6565b60208201915061ce49828461cdf6565b60208201915081905095945050505050565b7f5374645574696c7320626f756e642875696e743235362c75696e743235362c7560008201527f696e74323536293a204d6178206973206c657373207468616e206d696e2e0000602082015250565b600061ceb7603e8361c6db565b915061cec28261ce5b565b604082019050919050565b6000602082019050818103600083015261cee68161ceaa565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600061cf278261b1d5565b915061cf328361b1d5565b92508261cf425761cf4161ceed565b5b828206905092915050565b6000604082019050818103600083015261cf67818561c6ec565b905061cf76602083018461c4ab565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052605160045260246000fdfe6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c0033a2646970667358221220ba21482488e5d17bec6604135b1b31db216266e88c795314fe409bf1cd2b198264736f6c634300081c0033","sourceMap":"622:21245:29:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;769:75;;;:::i;:::-;;20140:912;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;13062:505;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;2907:134:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;9307:819:29;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;12410:648;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;5173:1070;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;3823:151:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;15060:506:29;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;15570:723;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;14563:493;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;3684:133:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;3385:141;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;19216:469:29;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;2765:917;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;1339:793;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;2136:625;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;19689:447;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;8700:603;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;3193:186:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;11992:414:29;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;17319:485;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;725:39;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;16297:1018;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;10783:926;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;3047:140:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;21056:808:29;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;3532:146:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;6247:1125:29;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;14062:497;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;18276:464;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;2754:147:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2459:141;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;1306:195:1;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;4231:938:29;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;11734:254;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;10130:649;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;17808:464;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;869:466;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;2606:142:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;18744:468:29;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;7376:1320;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;13571:487;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;1065:26:13;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;3686:541:29;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;769:75;810:29;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;799:8;;:40;;;;;;;;;;;;;;;;;;769:75::o;20140:912::-;336:42:0;20303:9:29;;;20330:1;20313:19;;:5;:19;;;;20303:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;20339:9:29;;;20368:1;20349:9;:16;:20;20339:31;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20418:2;20399:9;:16;:21;20395:89;;;20467:2;20456:9;20449:21;20395:89;20501:35;20526:9;20501:24;:35::i;:::-;20489:47;;20555:42;20561:10;20573:1;20595;20576:9;:16;:20;;;;:::i;:::-;20555:5;:42::i;:::-;20542:55;;20604:17;20624:33;20635:14;20651:5;20624:10;:33::i;:::-;20604:53;;336:42:0;20664:13:29;;;20678:5;20664:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20690:8;;;;;;;;;;;:21;;;20712:14;20690:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;20738:9;20733:109;20753:9;:16;20749:1;:20;20733:109;;;20784:8;;;;;;;;;;;:26;;;20811:9;20822;20832:1;20822:12;;;;;;;;:::i;:::-;;;;;;;;20784:51;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20771:3;;;;;;;20733:109;;;;336:42:0;20847:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;20868:15:29;;;20884:56;;;20868:73;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;20947:8:29;;;20956:5;20947:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20968:8;;;;;;;;;;;:29;;;20998:9;21009;21019:10;21009:21;;;;;;;;:::i;:::-;;;;;;;;21045:1;21032:10;:14;;;;:::i;:::-;20968:79;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20297:755;20140:912;;;;:::o;13062:505::-;336:42:0;13186:9:29;;;13205:8;13196:17;;:5;:17;;;;13186:28;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;13220:9:29;;;13247:1;13230:19;;:5;:19;;;;13220:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;13256:9:29;;;13286:1;13266:22;;:8;:22;;;;13256:33;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13296:17;13316:33;13327:14;13343:5;13316:10;:33::i;:::-;13296:53;;336:42:0;13356:8:29;;;13365:5;13356:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13377:8;;;;;;;;;;;:21;;;13399:14;13377:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;13421:15:29;;;13437:49;;;13421:66;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;13493:8:29;;;13502;13493:18;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13517:8;;;;;;;;;;;:24;;;13542:9;13553:8;13517:45;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13180:387;13062:505;;;:::o;2907:134:6:-;2954:33;3018:16;2999:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2907:134;:::o;9307:819:29:-;336:42:0;9496:9:29;;;9523:1;9506:19;;:5;:19;;;;9496:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9532:18;9553:7;:14;9532:35;;336:42:0;9573:9:29;;;9596:1;9583:10;:14;9573:25;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9639:10;9628:9;9621:29;9662:15;9696:9;9691:143;9728:1;9711:7;:14;:18;;;;:::i;:::-;9707:1;:22;9691:143;;;9761:7;9773:1;9769;:5;;;;:::i;:::-;9761:14;;;;;;;;:::i;:::-;;;;;;;;9748:7;9756:1;9748:10;;;;;;;;:::i;:::-;;;;;;;;:27;9744:84;;;9800:4;9787:17;;9814:5;;9744:84;9731:3;;;;;;;9691:143;;;;336:42:0;9839:9:29;;;9849:10;9839:21;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;9867:13:29;;;9881:5;9867:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9893:17;9913:8;;;;;;;;;;;:21;;;9935:14;9913:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;9893:57;;336:42:0;9957:15:29;;;9973:56;;;9957:73;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10036:8;;;;;;;;;;;:34;;;10071:9;10082;10093:7;10036:65;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;10107:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9490:636;;;9307:819;;;;:::o;12410:648::-;336:42:0;12534:9:29;;;12553;12544:18;;:5;:18;;;;12534:29;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;12569:9:29;;;12596:1;12579:19;;:5;:19;;;;12569:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;12605:9:29;;;12636:1;12615:23;;:9;:23;;;;12605:34;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;12646:17;12666:33;12677:14;12693:5;12666:10;:33::i;:::-;12646:53;;336:42:0;12706:8:29;;;12715:5;12706:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;12727:8;;;;;;;;;;;:21;;;12749:14;12727:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;12817:8:29;;;12826:5;12817:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;12838:8;;;;;;;;;;;:24;;;12863:9;12874;12838:46;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;12917:15:29;;;12933:55;;;12917:72;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;12995:8:29;;;13004:5;12995:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13016:8;;;;;;;;;;;:21;;;13038:14;13016:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;12528:530;12410:648;;;:::o;5173:1070::-;336:42:0;5314:9:29;;;5341:1;5324:19;;:5;:19;;;;5314:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;5350:9:29;;;5374:1;5360:4;:11;:15;5350:26;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5419:2;5405:4;:11;:16;5401:79;;;5463:2;5457:4;5450:16;5401:79;5492:29;5516:4;5492:23;:29::i;:::-;5485:36;;5536:33;5542:6;5550:1;5567;5553:4;:11;:15;;;;:::i;:::-;5536:5;:33::i;:::-;5527:42;;5576:17;5596:33;5607:14;5623:5;5596:10;:33::i;:::-;5576:53;;336:42:0;5636:13:29;;;5650:5;5636:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5662:8;;;;;;;;;;;:21;;;5684:14;5662:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;5710:9;5705:95;5725:4;:11;5721:1;:15;5705:95;;;5751:8;;;;;;;;;;;:22;;;5774:9;5785:4;5790:1;5785:7;;;;;;;;:::i;:::-;;;;;;;;5751:42;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5738:3;;;;;;;5705:95;;;;5806:15;5824:22;5833:4;5838:6;5833:12;;;;;;;;:::i;:::-;;;;;;;;5824:8;:22::i;:::-;5806:40;;336:42:0;5852:13:29;;;:15;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5932:7;5921:9;5878:62;;;;;;;;;;5947:8;;;;;;;;;;;:25;;;5973:9;5984:4;5989:6;5984:12;;;;;;;;:::i;:::-;;;;;;;;5947:50;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;6003:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6024:27;6054:8;;;;;;;;;;;:24;;;6079:9;6054:35;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;6024:65;;6095:44;6104:10;:17;6137:1;6123:4;:11;:15;;;;:::i;:::-;6095:8;:44::i;:::-;6150:9;6145:94;6165:10;:17;6161:1;:21;6145:94;;;6197:35;6209:10;6220:1;6209:13;;;;;;;;:::i;:::-;;;;;;;;6224:7;6197:11;:35::i;:::-;6184:3;;;;;;;6145:94;;;;5308:935;;;5173:1070;;;;:::o;3823:151:6:-;3872:42;3948:19;3926:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3823:151;:::o;15060:506:29:-;336:42:0;15217:9:29;;;15244:1;15227:19;;:5;:19;;;;15217:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;15253:9:29;;;15272:8;15263:17;;:5;:17;;;;15253:28;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;15288:17;15308:33;15319:14;15335:5;15308:10;:33::i;:::-;15288:53;;336:42:0;15348:8:29;;;15357:5;15348:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;15369:8;;;;;;;;;;;:21;;;15391:14;15369:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;15413:15:29;;;15429:49;;;15413:66;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;15485:8:29;;;15494;15485:18;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;15509:8;;;;;;;;;;;:29;;;15539:9;15550:7;15559:1;15509:52;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;15211:355;15060:506;;;;:::o;15570:723::-;336:42:0;15740:9:29;;;15767:1;15750:19;;:5;:19;;;;15740:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;15776:9:29;;;15795:8;15786:17;;:5;:17;;;;15776:28;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;15810:9:29;;;15839:1;15820:9;:16;:20;15810:31;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;15889:2;15870:9;:16;:21;15866:89;;;15938:2;15927:9;15920:21;15866:89;15972:35;15997:9;15972:24;:35::i;:::-;15960:47;;16014:17;16034:33;16045:14;16061:5;16034:10;:33::i;:::-;16014:53;;336:42:0;16074:8:29;;;16083:5;16074:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;16095:8;;;;;;;;;;;:21;;;16117:14;16095:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;16139:15:29;;;16155:49;;;16139:66;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;16211:8:29;;;16220;16211:18;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;16235:8;;;;;;;;;;;:31;;;16267:9;16278;16235:53;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;15734:559;15570:723;;;;:::o;14563:493::-;336:42:0;14718:9:29;;;14745:1;14728:19;;:5;:19;;;;14718:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;14754:9:29;;;14773:8;14764:17;;:5;:17;;;;14754:28;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;14789:17;14809:33;14820:14;14836:5;14809:10;:33::i;:::-;14789:53;;336:42:0;14849:8:29;;;14858:5;14849:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;14870:8;;;;;;;;;;;:21;;;14892:14;14870:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;14914:15:29;;;14930:49;;;14914:66;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;14986:8:29;;;14995;14986:18;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;15010:8;;;;;;;;;;;:25;;;15036:9;15047:3;15010:41;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;14712:344;14563:493;;;;:::o;3684:133:6:-;3730:33;3794:16;3775:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3684:133;:::o;3385:141::-;3433:35;3501:18;3480:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3385:141;:::o;19216:469:29:-;336:42:0;19343:9:29;;;19370:1;19353:19;;:5;:19;;;;19343:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;19379:9:29;;;19409:1;19395:3;19389:17;:21;19379:32;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;19418:17;19438:33;19449:14;19465:5;19438:10;:33::i;:::-;19418:53;;336:42:0;19478:8:29;;;19487:5;19478:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;19499:8;;;;;;;;;;;:21;;;19521:14;19499:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;19543:15:29;;;19559:52;;;19543:69;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;19618:8:29;;;19627:5;19618:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;19639:8;;;;;;;;;;;:25;;;19665:9;19676:3;19639:41;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;19337:348;19216:469;;;:::o;2765:917::-;336:42:0;2888:9:29;;;2915:1;2898:19;;:5;:19;;;;2888:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;2924:9:29;;;2948:1;2934:4;:11;:15;2924:26;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2993:2;2979:4;:11;:16;2975:79;;;3037:2;3031:4;3024:16;2975:79;3066:29;3090:4;3066:23;:29::i;:::-;3059:36;;3102:17;3122:33;3133:14;3149:5;3122:10;:33::i;:::-;3102:53;;336:42:0;3162:13:29;;;3176:5;3162:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3188:8;;;;;;;;;;;:21;;;3210:14;3188:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;3237:9;3232:151;3252:4;:11;3248:1;:15;3232:151;;;336:42:0;3278:13:29;;;:15;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3358:17;3367:4;3372:1;3367:7;;;;;;;;:::i;:::-;;;;;;;;3358:8;:17::i;:::-;3347:9;3306:70;;;;;;;;;;3265:3;;;;;;;3232:151;;;;3389:8;;;;;;;;;;;:27;;;3417:9;3428:4;3389:44;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;3439:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3460:27;3490:8;;;;;;;;;;;:24;;;3515:9;3490:35;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;3460:65;;3531:40;3540:10;:17;3559:4;:11;3531:8;:40::i;:::-;3582:9;3577:101;3597:10;:17;3593:1;:21;3577:101;;;3629:42;3638:10;3649:1;3638:13;;;;;;;;:::i;:::-;;;;;;;;3653:17;3662:4;3667:1;3662:7;;;;;;;;:::i;:::-;;;;;;;;3653:8;:17::i;:::-;3629:8;:42::i;:::-;3616:3;;;;;;;3577:101;;;;2882:800;;2765:917;;;:::o;1339:793::-;336:42:0;1476:9:29;;;1503:1;1486:19;;:5;:19;;;;1476:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;1512:9:29;;;1542:1;1522:22;;:8;:22;;;;1512:33;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;1551:9:29;;;1570:8;1561:17;;:5;:17;;;;1551:28;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1586:17;1606:33;1617:14;1633:5;1606:10;:33::i;:::-;1586:53;;336:42:0;1646:8:29;;;1655:5;1646:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1667:8;;;;;;;;;;;:21;;;1689:14;1667:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;1711:13:29;;;:15;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1797:8;1737:69;;1786:9;1737:69;;;;;;;;;;336:42:0;1813:8:29;;;1822:5;1813:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1834:8;;;;;;;;;;;:24;;;1859:9;1870:8;1834:45;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1886:52;1895:8;;;;;;;;;;;:21;;;1917:9;1895:32;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;1929:8;1886;:52::i;:::-;336:42:0;1996:8:29;;;2005;1996:18;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2020:8;;;;;;;;;;;:26;;;2047:9;2058:7;2020:46;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2072:55;2081:8;;;;;;;;;;;:24;;;2106:9;2081:35;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;:42;2125:1;2072:8;:55::i;:::-;1470:662;1339:793;;;;:::o;2136:625::-;336:42:0;2251:9:29;;;2278:1;2261:19;;:5;:19;;;;2251:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;2287:9:29;;;2317:1;2303:3;2297:17;:21;2287:32;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2326:17;2346:33;2357:14;2373:5;2346:10;:33::i;:::-;2326:53;;336:42:0;2386:8:29;;;2395:5;2386:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2407:8;;;;;;;;;;;:21;;;2429:14;2407:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;2451:13:29;;;:15;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2529:13;2538:3;2529:8;:13::i;:::-;2518:9;2477:66;;;;;;;;;;336:42:0;2550:8:29;;;2559:5;2550:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2571:8;;;;;;;;;;;:22;;;2594:9;2605:3;2571:38;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2616:21;2640:8;;;;;;;;;;;:24;;;2665:9;2640:35;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;2616:59;;2688:30;2713:4;2688:24;:30::i;:::-;2681:37;;2724:32;2733:4;2738:1;2733:7;;;;;;;;:::i;:::-;;;;;;;;2742:13;2751:3;2742:8;:13::i;:::-;2724:8;:32::i;:::-;2245:516;;2136:625;;;:::o;19689:447::-;336:42:0;19818:9:29;;;19845:1;19828:19;;:5;:19;;;;19818:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;19854:17;19874:33;19885:14;19901:5;19874:10;:33::i;:::-;19854:53;;336:42:0;19914:8:29;;;19923:5;19914:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;19935:8;;;;;;;;;;;:21;;;19957:14;19935:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;19979:15:29;;;19995:56;;;19979:73;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;20058:8:29;;;20067:5;20058:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20079:8;;;;;;;;;;;:29;;;20109:9;20120:7;20129:1;20079:52;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;19812:324;19689:447;;;:::o;8700:603::-;336:42:0;8884:9:29;;;8911:1;8894:19;;:5;:19;;;;8884:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;8920:9:29;;;8949:1;8930:9;:16;:20;8920:31;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;8957:9:29;;;8984:1;8967:7;:14;:18;8957:29;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;8992:9:29;;;9020;:16;9002:7;:14;:34;;8992:45;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;9044:13:29;;;9058:5;9044:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9070:17;9090:8;;;;;;;;;;;:21;;;9112:14;9090:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;9070:57;;336:42:0;9134:15:29;;;9150:56;;;9134:73;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9213:8;;;;;;;;;;;:34;;;9248:9;9259;9270:7;9213:65;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;9284:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8878:425;8700:603;;;;:::o;3193:186:6:-;3249:56;3346:26;3317:55;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3193:186;:::o;11992:414:29:-;336:42:0;12096:9:29;;;12123:1;12106:19;;:5;:19;;;;12096:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;12132:17;12152:33;12163:14;12179:5;12152:10;:33::i;:::-;12132:53;;336:42:0;12192:8:29;;;12201:5;12192:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;12213:8;;;;;;;;;;;:21;;;12235:14;12213:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;12257:8:29;;;12266:5;12257:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;12278:15:29;;;12294:53;;;12278:70;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;12354:8;;;;;;;;;;;:24;;;12379:9;12398:1;12354:47;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;12090:316;11992:414;;:::o;17319:485::-;336:42:0;17452:9:29;;;17479:1;17462:19;;:5;:19;;;;17452:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;17488:9:29;;;17518:1;17504:3;17498:17;:21;17488:32;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;17527:13:29;;;17541:5;17527:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;17553:17;17573:8;;;;;;;;;;;:21;;;17595:14;17573:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;17553:57;;17616:8;;;;;;;;;;;:22;;;17639:9;17650:3;17616:38;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;17661:15:29;;;17677:57;;;17661:74;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;17741:8;;;;;;;;;;;:22;;;17764:9;17775:3;17741:38;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;17785:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;17446:358;17319:485;;;:::o;725:39::-;;;;;;;;;;;;;:::o;16297:1018::-;336:42:0;16470:9:29;;;16497:1;16480:19;;:5;:19;;;;16470:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;16506:9:29;;;16525:8;16516:17;;:5;:17;;;;16506:28;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;16540:9:29;;;16569:1;16550:9;:16;:20;16540:31;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;16619:2;16600:9;:16;:21;16596:89;;;16668:2;16657:9;16650:21;16596:89;16702:35;16727:9;16702:24;:35::i;:::-;16690:47;;16743:24;16784:9;:16;16770:31;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;16743:58;;16812:9;16807:72;16827:9;:16;16823:1;:20;16807:72;;;16871:1;16858:7;16866:1;16858:10;;;;;;;;:::i;:::-;;;;;;;:14;;;;;16845:3;;;;;;;16807:72;;;;16885:17;16905:33;16916:14;16932:5;16905:10;:33::i;:::-;16885:53;;336:42:0;16945:13:29;;;16959:5;16945:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;16971:8;;;;;;;;;;;:21;;;16993:14;16971:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;17019:9;17014:109;17034:9;:16;17030:1;:20;17014:109;;;17065:8;;;;;;;;;;;:26;;;17092:9;17103;17113:1;17103:12;;;;;;;;:::i;:::-;;;;;;;;17065:51;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;17052:3;;;;;;;17014:109;;;;336:42:0;17128:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;17149:15:29;;;17165:49;;;17149:66;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;17221:8:29;;;17230;17221:18;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;17245:8;;;;;;;;;;;:34;;;17280:9;17291;17302:7;17245:65;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;16464:851;;16297:1018;;;;:::o;10783:926::-;336:42:0;10955:9:29;;;10982:1;10965:19;;:5;:19;;;;10955:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;10991:9:29;;;11015:1;11001:4;:11;:15;10991:26;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;11060:2;11046:4;:11;:16;11042:79;;;11104:2;11098:4;11091:16;11042:79;11133:29;11157:4;11133:23;:29::i;:::-;11126:36;;11177:33;11183:6;11191:1;11208;11194:4;:11;:15;;;;:::i;:::-;11177:5;:33::i;:::-;11168:42;;11217:17;11237:33;11248:14;11264:5;11237:10;:33::i;:::-;11217:53;;11277:30;;:::i;:::-;11348:4;11353:6;11348:12;;;;;;;;:::i;:::-;;;;;;;;11313:11;:20;;;:32;;:47;;;;336:42:0;11367:13:29;;;11381:5;11367:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;11393:8;;;;;;;;;;;:21;;;11415:14;11393:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;11441:9;11436:95;11456:4;:11;11452:1;:15;11436:95;;;11482:8;;;;;;;;;;;:22;;;11505:9;11516:4;11521:1;11516:7;;;;;;;;:::i;:::-;;;;;;;;11482:42;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;11469:3;;;;;;;11436:95;;;;336:42:0;11536:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;11557:13;11573:8;;;;;;;;;;;:28;;;11602:6;11610:11;11623:9;11573:60;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;11557:76;;11639:65;11648:5;11655:48;11696:6;11655:11;:40;;:48;;;;:::i;:::-;11639:8;:65::i;:::-;10949:760;;;10783:926;;;;;:::o;3047:140:6:-;3095:34;3162:18;3141:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3047:140;:::o;21056:808:29:-;336:42:0;21251:9:29;;;21278:1;21261:19;;:5;:19;;;;21251:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;21287:9:29;;;21322:1;21303:8;21297:22;:26;:58;;;;;21354:1;21333:10;21327:24;:28;21297:58;21287:69;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;21362:9:29;;;21418:10;21402:28;;;;;;21388:8;21372:26;;;;;;:58;;21362:69;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21438:17;21458:33;21469:14;21485:5;21458:10;:33::i;:::-;21438:53;;336:42:0;21498:8:29;;;21507:5;21498:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21519:8;;;;;;;;;;;:21;;;21541:14;21519:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;21563:30;;:::i;:::-;21634:10;21599:11;:20;;;:32;;:45;;;;336:42:0;21651:8:29;;;21660:5;21651:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21672:8;;;;;;;;;;;:22;;;21695:9;21706:8;21672:43;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;21722:15:29;;;21738:54;;;21722:71;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21799:8;;;;;;;;;;;:28;;;21828:6;21836:11;21849:9;21799:60;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;21245:619;;21056:808;;;;;:::o;3532:146:6:-;3580:40;3653:18;3632:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3532:146;:::o;6247:1125:29:-;336:42:0;6402:9:29;;;6429:1;6412:19;;:5;:19;;;;6402:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;6438:9:29;;;6467:1;6448:9;:16;:20;6438:31;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6517:2;6498:9;:16;:21;6494:89;;;6566:2;6555:9;6548:21;6494:89;6600:35;6625:9;6600:24;:35::i;:::-;6588:47;;6654:42;6660:10;6672:1;6694;6675:9;:16;:20;;;;:::i;:::-;6654:5;:42::i;:::-;6641:55;;6703:17;6723:33;6734:14;6750:5;6723:10;:33::i;:::-;6703:53;;336:42:0;6763:13:29;;;6777:5;6763:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6789:8;;;;;;;;;;;:21;;;6811:14;6789:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;6837:9;6832:109;6852:9;:16;6848:1;:20;6832:109;;;6883:8;;;;;;;;;;;:26;;;6910:9;6921;6931:1;6921:12;;;;;;;;:::i;:::-;;;;;;;;6883:51;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6870:3;;;;;;;6832:109;;;;336:42:0;6947:13:29;;;:15;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7027:9;7037:10;7027:21;;;;;;;;:::i;:::-;;;;;;;;7016:9;6973:76;;;;;;;;;;7056:8;;;;;;;;;;;:29;;;7086:9;7097;7107:10;7097:21;;;;;;;;:::i;:::-;;;;;;;;7120:10;7056:75;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;7137:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7158:21;7182:8;;;;;;;;;;;:24;;;7207:9;7182:35;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;7158:59;;7223:43;7232:4;:11;7264:1;7245:9;:16;:20;;;;:::i;:::-;7223:8;:43::i;:::-;7277:9;7272:96;7292:4;:11;7288:1;:15;7272:96;;;7318:43;7330:4;7335:1;7330:7;;;;;;;;:::i;:::-;;;;;;;;7339:9;7349:10;7339:21;;;;;;;;:::i;:::-;;;;;;;;7318:11;:43::i;:::-;7305:3;;;;;;;7272:96;;;;6396:976;;6247:1125;;;;:::o;14062:497::-;336:42:0;14216:9:29;;;14243:1;14226:19;;:5;:19;;;;14216:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;14252:9:29;;;14271:8;14262:17;;:5;:17;;;;14252:28;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;14287:17;14307:33;14318:14;14334:5;14307:10;:33::i;:::-;14287:53;;336:42:0;14347:8:29;;;14356:5;14347:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;14368:8;;;;;;;;;;;:21;;;14390:14;14368:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;14412:15:29;;;14428:49;;;14412:66;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;14484:8:29;;;14493;14484:18;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;14508:8;;;;;;;;;;;:26;;;14535:9;14546:7;14508:46;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;14210:349;14062:497;;;;:::o;18276:464::-;336:42:0;18413:9:29;;;18440:1;18423:19;;:5;:19;;;;18413:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;18449:13:29;;;18463:5;18449:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;18475:17;18495:8;;;;;;;;;;;:21;;;18517:14;18495:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;18475:57;;18538:8;;;;;;;;;;;:26;;;18565:9;18576:13;18585:3;18576:8;:13::i;:::-;18538:52;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;18597:15:29;;;18613:57;;;18597:74;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;18677:8;;;;;;;;;;;:22;;;18700:9;18711:3;18677:38;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;18721:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;18407:333;18276:464;;;:::o;2754:147:6:-;2803:40;2876:18;2855:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2754:147;:::o;2459:141::-;2508:34;2575:18;2554:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2459:141;:::o;1306:195:1:-;1345:4;1365:7;;;;;;;;;;;1361:134;;;1395:4;1388:11;;;;1361:134;1482:1;1474:10;;219:28;211:37;;1437:7;;;219:28;211:37;;1255:17;1437:33;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;:47;;1430:54;;1306:195;;:::o;4231:938:29:-;336:42:0;4364:9:29;;;4391:1;4374:19;;:5;:19;;;;4364:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;4400:9:29;;;4429:1;4410:9;:16;:20;4400:31;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4479:2;4460:9;:16;:21;4456:89;;;4528:2;4517:9;4510:21;4456:89;4562:35;4587:9;4562:24;:35::i;:::-;4550:47;;4604:17;4624:33;4635:14;4651:5;4624:10;:33::i;:::-;4604:53;;336:42:0;4664:13:29;;;4678:5;4664:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4690:8;;;;;;;;;;;:21;;;4712:14;4690:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;4739:9;4734:151;4754:9;:16;4750:1;:20;4734:151;;;336:42:0;4785:13:29;;;:15;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4865:9;4875:1;4865:12;;;;;;;;:::i;:::-;;;;;;;;4854:9;4813:65;;;;;;;;;;4772:3;;;;;;;4734:151;;;;4891:8;;;;;;;;;;;:31;;;4923:9;4934;4891:53;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;4950:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4971:21;4995:8;;;;;;;;;;;:24;;;5020:9;4995:35;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;4971:59;;5036:39;5045:4;:11;5058:9;:16;5036:8;:39::i;:::-;5086:9;5081:84;5101:4;:11;5097:1;:15;5081:84;;;5127:31;5136:4;5141:1;5136:7;;;;;;;;:::i;:::-;;;;;;;;5145:9;5155:1;5145:12;;;;;;;;:::i;:::-;;;;;;;;5127:8;:31::i;:::-;5114:3;;;;;;;5081:84;;;;4358:811;;4231:938;;;:::o;11734:254::-;11816:13;336:42:0;11849:8:29;;;11858:5;11849:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;11870:15:29;;;11886:53;;;11870:70;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;11946:8;;;;;;;;;;;:21;;;11968:14;11946:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;11810:178;11734:254;:::o;10130:649::-;336:42:0;10277:9:29;;;10304:1;10287:19;;:5;:19;;;;10277:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;10313:9:29;;;10343:1;10329:3;10323:17;:21;10313:32;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10352:17;10372:33;10383:14;10399:5;10372:10;:33::i;:::-;10352:53;;10412:30;;:::i;:::-;10483:3;10448:11;:20;;;:32;;:38;;;;336:42:0;10493:13:29;;;10507:5;10493:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10519:8;;;;;;;;;;;:21;;;10541:14;10519:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;10562:8;;;;;;;;;;;:22;;;10585:9;10596:3;10562:38;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;10606:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10627:13;10643:8;;;;;;;;;;;:28;;;10672:6;10680:11;10693:9;10643:60;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;10627:76;;10709:65;10718:5;10725:48;10766:6;10725:11;:40;;:48;;;;:::i;:::-;10709:8;:65::i;:::-;10271:508;;;10130:649;;;;:::o;17808:464::-;336:42:0;17943:9:29;;;17970:1;17953:19;;:5;:19;;;;17943:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;17979:13:29;;;17993:5;17979:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;18005:17;18025:8;;;;;;;;;;;:21;;;18047:14;18025:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;18005:57;;18068:8;;;;;;;;;;;:26;;;18095:9;18106:7;18068:46;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;18121:15:29;;;18137:57;;;18121:74;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;18201:8;;;;;;;;;;;:26;;;18228:9;18239:7;18201:46;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;18253:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;17937:335;17808:464;;;:::o;869:466::-;336:42:0;960:9:29;;;987:1;970:19;;:5;:19;;;;960:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;996:17;1016:33;1027:14;1043:5;1016:10;:33::i;:::-;996:53;;336:42:0;1056:13:29;;;:15;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1133:5;1082:57;;1122:9;1082:57;;;;;;;;;;336:42:0;1146:8:29;;;1155:5;1146:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1167:24;1194:8;;;;;;;;;;;:21;;;1216:14;1194:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;1167:64;;1238:37;1247:16;1265:9;1238:8;:37::i;:::-;1281:49;1290:8;;;;;;;;;;;:21;;;1312:9;1290:32;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;1324:5;1281:8;:49::i;:::-;954:381;;869:466;;:::o;2606:142:6:-;2655:35;2723:18;2702:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2606:142;:::o;18744:468:29:-;336:42:0;18885:9:29;;;18912:1;18895:19;;:5;:19;;;;18885:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;18921:13:29;;;18935:5;18921:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;18947:17;18967:8;;;;;;;;;;;:21;;;18989:14;18967:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;18947:57;;19010:8;;;;;;;;;;;:22;;;19033:9;19044:3;19010:38;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;19055:15:29;;;19071:57;;;19055:74;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;19135:8;;;;;;;;;;;:26;;;19162:9;19173:13;19182:3;19173:8;:13::i;:::-;19135:52;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;19193:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;18879:333;18744:468;;;:::o;7376:1320::-;336:42:0;7512:9:29;;;7539:1;7522:19;;:5;:19;;;;7512:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;7548:9:29;;;7577:1;7558:9;:16;:20;7548:31;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7627:2;7608:9;:16;:21;7604:89;;;7676:2;7665:9;7658:21;7604:89;7710:35;7735:9;7710:24;:35::i;:::-;7698:47;;7752:17;7772:33;7783:14;7799:5;7772:10;:33::i;:::-;7752:53;;336:42:0;7812:13:29;;;7826:5;7812:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7838:8;;;;;;;;;;;:21;;;7860:14;7838:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;7881:8;;;;;;;;;;;:31;;;7913:9;7924;7881:53;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7975:34;8026:9;:16;8012:31;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7975:68;;8054:9;8049:116;8069:9;:16;8065:1;:20;8049:116;;;8123:9;8156:1;8152;8133:9;:16;:20;;;;:::i;:::-;:24;;;;:::i;:::-;8123:35;;;;;;;;:::i;:::-;;;;;;;;8100:17;8118:1;8100:20;;;;;;;;:::i;:::-;;;;;;;:58;;;;;8087:3;;;;;;;8049:116;;;;8171:24;8212:9;:16;8198:31;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8171:58;;8240:9;8235:95;8255:9;:16;8251:1;:20;8235:95;;;8322:1;8318;8299:9;:16;:20;;;;:::i;:::-;:24;;;;:::i;:::-;8286:7;8294:1;8286:10;;;;;;;;:::i;:::-;;;;;;;:37;;;;;8273:3;;;;;;;8235:95;;;;8341:9;8336:161;8356:9;:16;8352:1;:20;8336:161;;;336:42:0;8387:13:29;;;:15;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8469:17;8487:1;8469:20;;;;;;;;:::i;:::-;;;;;;;;8458:9;8415:75;;;;;;;;;;8374:3;;;;;;;8336:161;;;;8502:8;;;;;;;;;;;:34;;;8537:9;8548:17;8567:7;8502:73;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;8581:12:29;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8602:21;8626:8;;;;;;;;;;;:24;;;8651:9;8626:35;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;8602:59;;8667:24;8676:4;:11;8689:1;8667:8;:24::i;:::-;7506:1190;;;;7376:1320;;;:::o;13571:487::-;336:42:0;13723:9:29;;;13750:1;13733:19;;:5;:19;;;;13723:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;13759:9:29;;;13778:8;13769:17;;:5;:17;;;;13759:28;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13794:17;13814:33;13825:14;13841:5;13814:10;:33::i;:::-;13794:53;;336:42:0;13854:8:29;;;13863:5;13854:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13875:8;;;;;;;;;;;:21;;;13897:14;13875:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;13919:15:29;;;13935:49;;;13919:66;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;13991:8:29;;;14000;13991:18;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;14015:8;;;;;;;;;;;:22;;;14038:9;14049:3;14015:38;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13717:341;13571:487;;;;:::o;1065:26:13:-;;;;;;;;;;;;;:::o;3686:541:29:-;336:42:0;3803:9:29;;;3830:1;3813:19;;:5;:19;;;;3803:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3839:17;3859:33;3870:14;3886:5;3859:10;:33::i;:::-;3839:53;;336:42:0;3899:8:29;;;3908:5;3899:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3920:8;;;;;;;;;;;:21;;;3942:14;3920:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;336:42:0;3964:13:29;;;:15;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4042:7;4031:9;3990:60;;;;;;;;;;336:42:0;4057:8:29;;;4066:5;4057:15;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4078:8;;;;;;;;;;;:26;;;4105:9;4116:7;4078:46;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4131:21;4155:8;;;;;;;;;;;:24;;;4180:9;4155:35;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;4131:59;;4196:26;4205:4;4210:1;4205:7;;;;;;;;:::i;:::-;;;;;;;;4214;4196:8;:26::i;:::-;3797:430;;3686:541;;;:::o;409:619:31:-;498:34;574:5;:12;560:27;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;540:47;;593:25;629:9;624:328;644:5;:12;640:1;:16;624:328;;;671:16;700:9;695:158;715:17;711:1;:21;695:158;;;777:5;783:1;777:8;;;;;;;;:::i;:::-;;;;;;;;753:17;771:1;753:20;;;;;;;;:::i;:::-;;;;;;;;:32;749:96;;813:4;799:18;;829:5;;749:96;734:3;;;;;;;695:158;;;;865:11;860:86;;929:5;935:1;929:8;;;;;;;;:::i;:::-;;;;;;;;888:17;906:19;;;;;:::i;:::-;;;888:38;;;;;;;;:::i;:::-;;;;;;;:49;;;;;860:86;663:289;658:3;;;;;;;624:328;;;;1000:17;981;974:44;966:58;409:619;;;:::o;2815:199:12:-;2898:14;2933:19;2940:1;2943:3;2948;2933:6;:19::i;:::-;2924:28;;2962:45;;;;;;;;;;;;;;;;;;3000:6;2962:21;:45::i;:::-;2815:199;;;;;:::o;221:184:31:-;315:17;377:14;393:5;360:39;;;;;;;;;:::i;:::-;;;;;;;;;;;;;352:48;;;:::i;:::-;340:60;;221:184;;;;:::o;1032:676::-;1119:33;1193:5;:12;1180:26;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1160:46;;1212:25;1248:9;1243:389;1263:5;:12;1259:1;:16;1243:389;;;1290:16;1314:19;1336:18;1345:5;1351:1;1345:8;;;;;;;;:::i;:::-;;;;;;;;1336;:18::i;:::-;1314:40;;1367:9;1362:171;1382:17;1378:1;:21;1362:171;;;1435:30;1444:17;1462:1;1444:20;;;;;;;;:::i;:::-;;;;;;;;1435:8;:30::i;:::-;1420:11;:45;1416:109;;1493:4;1479:18;;1509:5;;1416:109;1401:3;;;;;;;1362:171;;;;1545:11;1540:86;;1609:5;1615:1;1609:8;;;;;;;;:::i;:::-;;;;;;;;1568:17;1586:19;;;;;:::i;:::-;;;1568:38;;;;;;;;:::i;:::-;;;;;;;:49;;;;1540:86;1282:350;;1277:3;;;;;;;1243:389;;;;1680:17;1661;1654:44;1646:58;1032:676;;;:::o;90:127::-;158:7;207:3;190:21;;;;;;;;:::i;:::-;;;;;;;;;;;;;180:32;;;;;;173:39;;90:127;;;:::o;2664:153:1:-;2755:5;2747:4;:13;2743:68;;219:28;211:37;;2776:11;;;2788:4;2794:5;2776:24;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2743:68;2664:153;;:::o;9888:159::-;9982:5;9974:4;:13;9970:71;;219:28;211:37;;10003:14;;;10018:4;10024:5;10003:27;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9970:71;9888:159;;:::o;4362:153::-;4453:5;4445:4;:13;4441:68;;219:28;211:37;;4474:11;;;4486:4;4492:5;4474:24;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4441:68;4362:153;;:::o;4020:::-;4111:5;4103:13;;:4;:13;;;4099:68;;219:28;211:37;;4132:11;;;4144:4;4150:5;4132:24;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4099:68;4020:153;;:::o;4328:271:21:-;4437:7;284:41:22;;;;;;;:::i;:::-;;;;;;;;;;;;;274:52;;;;;;4531:6:21;4539:11;:24;;;4565:11;:22;;;4476:112;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;4459:135;;;;;;4452:142;;4328:271;;;;:::o;1546:1263:12:-;1630:14;1671:3;1664;:10;;1656:85;;;;;;;;;;;;:::i;:::-;;;;;;;;;1975:3;1970:1;:8;;:20;;;;;1987:3;1982:1;:8;;1970:20;1966:34;;;1999:1;1992:8;;;;1966:34;2011:12;2038:1;2032:3;2026;:9;;;;:::i;:::-;:13;;;;:::i;:::-;2011:28;;2234:1;2229;:6;;:18;;;;;2246:1;2239:4;:8;2229:18;2225:38;;;2262:1;2256:3;:7;;;;:::i;:::-;2249:14;;;;;2225:38;2296:1;1042:78;2282:15;;;;:::i;:::-;2277:1;:20;;:46;;;;;2322:1;1042:78;2308:15;;;;:::i;:::-;2301:4;:22;2277:46;2273:82;;;2353:1;1042:78;2339:15;;;;:::i;:::-;2332:3;:23;;;;:::i;:::-;2325:30;;;;;2273:82;2459:3;2455:1;:7;2451:352;;;2478:12;2497:3;2493:1;:7;;;;:::i;:::-;2478:22;;2514:11;2535:4;2528;:11;;;;:::i;:::-;2514:25;;2564:1;2557:3;:8;2553:24;;2574:3;2567:10;;;;;;;2553:24;2612:1;2606:3;2600;:9;;;;:::i;:::-;:13;;;;:::i;:::-;2591:22;;2464:160;;2451:352;;;2638:3;2634:1;:7;2630:173;;;2657:12;2678:1;2672:3;:7;;;;:::i;:::-;2657:22;;2693:11;2714:4;2707;:11;;;;:::i;:::-;2693:25;;2743:1;2736:3;:8;2732:24;;2753:3;2746:10;;;;;;;2732:24;2791:1;2785:3;2779;:9;;;;:::i;:::-;:13;;;;:::i;:::-;2770:22;;2643:160;;2630:173;2451:352;1646:1163;1546:1263;;;;;;:::o;9561:162::-;9645:71;9708:2;9712;9661:54;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9645:15;:71::i;:::-;9561:162;;:::o;8891:133::-;8962:55;9009:7;8962:46;8988:19;8962:25;:46::i;:::-;:55;;:::i;:::-;8891:133;:::o;9030:381::-;9104:21;9128:7;:14;9104:38;;9152:22;679:42;9152:41;;9302:2;9293:7;9289:16;9393:1;9390;9375:13;9361:12;9345:14;9338:5;9327:68;9255:150;;;;9030:381;:::o;8650:235::-;8775:42;8865:4;8856:13;;8650:235;;;:::o;-1:-1:-1:-;;;;;;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;:::o;:::-;;;:::i;:::-;:::o;:::-;;;;;;;;;;;;;;;;;;;;;:::o;7:75:33:-;40:6;73:2;67:9;57:19;;7:75;:::o;88:117::-;197:1;194;187:12;211:117;320:1;317;310:12;334:126;371:7;411:42;404:5;400:54;389:65;;334:126;;;:::o;466:96::-;503:7;532:24;550:5;532:24;:::i;:::-;521:35;;466:96;;;:::o;568:122::-;641:24;659:5;641:24;:::i;:::-;634:5;631:35;621:63;;680:1;677;670:12;621:63;568:122;:::o;696:139::-;742:5;780:6;767:20;758:29;;796:33;823:5;796:33;:::i;:::-;696:139;;;;:::o;841:150::-;878:7;918:66;911:5;907:78;896:89;;841:150;;;:::o;997:122::-;1070:24;1088:5;1070:24;:::i;:::-;1063:5;1060:35;1050:63;;1109:1;1106;1099:12;1050:63;997:122;:::o;1125:139::-;1171:5;1209:6;1196:20;1187:29;;1225:33;1252:5;1225:33;:::i;:::-;1125:139;;;;:::o;1270:117::-;1379:1;1376;1369:12;1393:102;1434:6;1485:2;1481:7;1476:2;1469:5;1465:14;1461:28;1451:38;;1393:102;;;:::o;1501:180::-;1549:77;1546:1;1539:88;1646:4;1643:1;1636:15;1670:4;1667:1;1660:15;1687:281;1770:27;1792:4;1770:27;:::i;:::-;1762:6;1758:40;1900:6;1888:10;1885:22;1864:18;1852:10;1849:34;1846:62;1843:88;;;1911:18;;:::i;:::-;1843:88;1951:10;1947:2;1940:22;1730:238;1687:281;;:::o;1974:129::-;2008:6;2035:20;;:::i;:::-;2025:30;;2064:33;2092:4;2084:6;2064:33;:::i;:::-;1974:129;;;:::o;2109:311::-;2186:4;2276:18;2268:6;2265:30;2262:56;;;2298:18;;:::i;:::-;2262:56;2348:4;2340:6;2336:17;2328:25;;2408:4;2402;2398:15;2390:23;;2109:311;;;:::o;2426:117::-;2535:1;2532;2525:12;2549:77;2586:7;2615:5;2604:16;;2549:77;;;:::o;2632:122::-;2705:24;2723:5;2705:24;:::i;:::-;2698:5;2695:35;2685:63;;2744:1;2741;2734:12;2685:63;2632:122;:::o;2760:139::-;2806:5;2844:6;2831:20;2822:29;;2860:33;2887:5;2860:33;:::i;:::-;2760:139;;;;:::o;2922:710::-;3018:5;3043:81;3059:64;3116:6;3059:64;:::i;:::-;3043:81;:::i;:::-;3034:90;;3144:5;3173:6;3166:5;3159:21;3207:4;3200:5;3196:16;3189:23;;3260:4;3252:6;3248:17;3240:6;3236:30;3289:3;3281:6;3278:15;3275:122;;;3308:79;;:::i;:::-;3275:122;3423:6;3406:220;3440:6;3435:3;3432:15;3406:220;;;3515:3;3544:37;3577:3;3565:10;3544:37;:::i;:::-;3539:3;3532:50;3611:4;3606:3;3602:14;3595:21;;3482:144;3466:4;3461:3;3457:14;3450:21;;3406:220;;;3410:21;3024:608;;2922:710;;;;;:::o;3655:370::-;3726:5;3775:3;3768:4;3760:6;3756:17;3752:27;3742:122;;3783:79;;:::i;:::-;3742:122;3900:6;3887:20;3925:94;4015:3;4007:6;4000:4;3992:6;3988:17;3925:94;:::i;:::-;3916:103;;3732:293;3655:370;;;;:::o;4031:77::-;4068:7;4097:5;4086:16;;4031:77;;;:::o;4114:122::-;4187:24;4205:5;4187:24;:::i;:::-;4180:5;4177:35;4167:63;;4226:1;4223;4216:12;4167:63;4114:122;:::o;4242:139::-;4288:5;4326:6;4313:20;4304:29;;4342:33;4369:5;4342:33;:::i;:::-;4242:139;;;;:::o;4387:975::-;4498:6;4506;4514;4522;4571:3;4559:9;4550:7;4546:23;4542:33;4539:120;;;4578:79;;:::i;:::-;4539:120;4698:1;4723:53;4768:7;4759:6;4748:9;4744:22;4723:53;:::i;:::-;4713:63;;4669:117;4825:2;4851:53;4896:7;4887:6;4876:9;4872:22;4851:53;:::i;:::-;4841:63;;4796:118;4981:2;4970:9;4966:18;4953:32;5012:18;5004:6;5001:30;4998:117;;;5034:79;;:::i;:::-;4998:117;5139:78;5209:7;5200:6;5189:9;5185:22;5139:78;:::i;:::-;5129:88;;4924:303;5266:2;5292:53;5337:7;5328:6;5317:9;5313:22;5292:53;:::i;:::-;5282:63;;5237:118;4387:975;;;;;;;:::o;5368:619::-;5445:6;5453;5461;5510:2;5498:9;5489:7;5485:23;5481:32;5478:119;;;5516:79;;:::i;:::-;5478:119;5636:1;5661:53;5706:7;5697:6;5686:9;5682:22;5661:53;:::i;:::-;5651:63;;5607:117;5763:2;5789:53;5834:7;5825:6;5814:9;5810:22;5789:53;:::i;:::-;5779:63;;5734:118;5891:2;5917:53;5962:7;5953:6;5942:9;5938:22;5917:53;:::i;:::-;5907:63;;5862:118;5368:619;;;;;:::o;5993:114::-;6060:6;6094:5;6088:12;6078:22;;5993:114;;;:::o;6113:184::-;6212:11;6246:6;6241:3;6234:19;6286:4;6281:3;6277:14;6262:29;;6113:184;;;;:::o;6303:132::-;6370:4;6393:3;6385:11;;6423:4;6418:3;6414:14;6406:22;;6303:132;;;:::o;6441:108::-;6518:24;6536:5;6518:24;:::i;:::-;6513:3;6506:37;6441:108;;:::o;6555:179::-;6624:10;6645:46;6687:3;6679:6;6645:46;:::i;:::-;6723:4;6718:3;6714:14;6700:28;;6555:179;;;;:::o;6740:113::-;6810:4;6842;6837:3;6833:14;6825:22;;6740:113;;;:::o;6889:732::-;7008:3;7037:54;7085:5;7037:54;:::i;:::-;7107:86;7186:6;7181:3;7107:86;:::i;:::-;7100:93;;7217:56;7267:5;7217:56;:::i;:::-;7296:7;7327:1;7312:284;7337:6;7334:1;7331:13;7312:284;;;7413:6;7407:13;7440:63;7499:3;7484:13;7440:63;:::i;:::-;7433:70;;7526:60;7579:6;7526:60;:::i;:::-;7516:70;;7372:224;7359:1;7356;7352:9;7347:14;;7312:284;;;7316:14;7612:3;7605:10;;7013:608;;;6889:732;;;;:::o;7627:373::-;7770:4;7808:2;7797:9;7793:18;7785:26;;7857:9;7851:4;7847:20;7843:1;7832:9;7828:17;7821:47;7885:108;7988:4;7979:6;7885:108;:::i;:::-;7877:116;;7627:373;;;;:::o;8006:311::-;8083:4;8173:18;8165:6;8162:30;8159:56;;;8195:18;;:::i;:::-;8159:56;8245:4;8237:6;8233:17;8225:25;;8305:4;8299;8295:15;8287:23;;8006:311;;;:::o;8340:710::-;8436:5;8461:81;8477:64;8534:6;8477:64;:::i;:::-;8461:81;:::i;:::-;8452:90;;8562:5;8591:6;8584:5;8577:21;8625:4;8618:5;8614:16;8607:23;;8678:4;8670:6;8666:17;8658:6;8654:30;8707:3;8699:6;8696:15;8693:122;;;8726:79;;:::i;:::-;8693:122;8841:6;8824:220;8858:6;8853:3;8850:15;8824:220;;;8933:3;8962:37;8995:3;8983:10;8962:37;:::i;:::-;8957:3;8950:50;9029:4;9024:3;9020:14;9013:21;;8900:144;8884:4;8879:3;8875:14;8868:21;;8824:220;;;8828:21;8442:608;;8340:710;;;;;:::o;9073:370::-;9144:5;9193:3;9186:4;9178:6;9174:17;9170:27;9160:122;;9201:79;;:::i;:::-;9160:122;9318:6;9305:20;9343:94;9433:3;9425:6;9418:4;9410:6;9406:17;9343:94;:::i;:::-;9334:103;;9150:293;9073:370;;;;:::o;9449:1185::-;9585:6;9593;9601;9609;9658:3;9646:9;9637:7;9633:23;9629:33;9626:120;;;9665:79;;:::i;:::-;9626:120;9785:1;9810:53;9855:7;9846:6;9835:9;9831:22;9810:53;:::i;:::-;9800:63;;9756:117;9912:2;9938:53;9983:7;9974:6;9963:9;9959:22;9938:53;:::i;:::-;9928:63;;9883:118;10068:2;10057:9;10053:18;10040:32;10099:18;10091:6;10088:30;10085:117;;;10121:79;;:::i;:::-;10085:117;10226:78;10296:7;10287:6;10276:9;10272:22;10226:78;:::i;:::-;10216:88;;10011:303;10381:2;10370:9;10366:18;10353:32;10412:18;10404:6;10401:30;10398:117;;;10434:79;;:::i;:::-;10398:117;10539:78;10609:7;10600:6;10589:9;10585:22;10539:78;:::i;:::-;10529:88;;10324:303;9449:1185;;;;;;;:::o;10640:321::-;10727:4;10817:18;10809:6;10806:30;10803:56;;;10839:18;;:::i;:::-;10803:56;10889:4;10881:6;10877:17;10869:25;;10949:4;10943;10939:15;10931:23;;10640:321;;;:::o;10967:117::-;11076:1;11073;11066:12;11090:308;11152:4;11242:18;11234:6;11231:30;11228:56;;;11264:18;;:::i;:::-;11228:56;11302:29;11324:6;11302:29;:::i;:::-;11294:37;;11386:4;11380;11376:15;11368:23;;11090:308;;;:::o;11404:148::-;11502:6;11497:3;11492;11479:30;11543:1;11534:6;11529:3;11525:16;11518:27;11404:148;;;:::o;11558:425::-;11636:5;11661:66;11677:49;11719:6;11677:49;:::i;:::-;11661:66;:::i;:::-;11652:75;;11750:6;11743:5;11736:21;11788:4;11781:5;11777:16;11826:3;11817:6;11812:3;11808:16;11805:25;11802:112;;;11833:79;;:::i;:::-;11802:112;11923:54;11970:6;11965:3;11960;11923:54;:::i;:::-;11642:341;11558:425;;;;;:::o;12003:340::-;12059:5;12108:3;12101:4;12093:6;12089:17;12085:27;12075:122;;12116:79;;:::i;:::-;12075:122;12233:6;12220:20;12258:79;12333:3;12325:6;12318:4;12310:6;12306:17;12258:79;:::i;:::-;12249:88;;12065:278;12003:340;;;;:::o;12365:945::-;12471:5;12496:91;12512:74;12579:6;12512:74;:::i;:::-;12496:91;:::i;:::-;12487:100;;12607:5;12636:6;12629:5;12622:21;12670:4;12663:5;12659:16;12652:23;;12723:4;12715:6;12711:17;12703:6;12699:30;12752:3;12744:6;12741:15;12738:122;;;12771:79;;:::i;:::-;12738:122;12886:6;12869:435;12903:6;12898:3;12895:15;12869:435;;;12992:3;12979:17;13028:18;13015:11;13012:35;13009:122;;;13050:79;;:::i;:::-;13009:122;13174:11;13166:6;13162:24;13212:47;13255:3;13243:10;13212:47;:::i;:::-;13207:3;13200:60;13289:4;13284:3;13280:14;13273:21;;12945:359;;12929:4;12924:3;12920:14;12913:21;;12869:435;;;12873:21;12477:833;;12365:945;;;;;:::o;13332:390::-;13413:5;13462:3;13455:4;13447:6;13443:17;13439:27;13429:122;;13470:79;;:::i;:::-;13429:122;13587:6;13574:20;13612:104;13712:3;13704:6;13697:4;13689:6;13685:17;13612:104;:::i;:::-;13603:113;;13419:303;13332:390;;;;:::o;13728:995::-;13849:6;13857;13865;13873;13922:3;13910:9;13901:7;13897:23;13893:33;13890:120;;;13929:79;;:::i;:::-;13890:120;14049:1;14074:53;14119:7;14110:6;14099:9;14095:22;14074:53;:::i;:::-;14064:63;;14020:117;14176:2;14202:53;14247:7;14238:6;14227:9;14223:22;14202:53;:::i;:::-;14192:63;;14147:118;14332:2;14321:9;14317:18;14304:32;14363:18;14355:6;14352:30;14349:117;;;14385:79;;:::i;:::-;14349:117;14490:88;14570:7;14561:6;14550:9;14546:22;14490:88;:::i;:::-;14480:98;;14275:313;14627:2;14653:53;14698:7;14689:6;14678:9;14674:22;14653:53;:::i;:::-;14643:63;;14598:118;13728:995;;;;;;;:::o;14729:145::-;14827:6;14861:5;14855:12;14845:22;;14729:145;;;:::o;14880:215::-;15010:11;15044:6;15039:3;15032:19;15084:4;15079:3;15075:14;15060:29;;14880:215;;;;:::o;15101:163::-;15199:4;15222:3;15214:11;;15252:4;15247:3;15243:14;15235:22;;15101:163;;;:::o;15270:124::-;15347:6;15381:5;15375:12;15365:22;;15270:124;;;:::o;15400:184::-;15499:11;15533:6;15528:3;15521:19;15573:4;15568:3;15564:14;15549:29;;15400:184;;;;:::o;15590:142::-;15667:4;15690:3;15682:11;;15720:4;15715:3;15711:14;15703:22;;15590:142;;;:::o;15738:99::-;15790:6;15824:5;15818:12;15808:22;;15738:99;;;:::o;15843:159::-;15917:11;15951:6;15946:3;15939:19;15991:4;15986:3;15982:14;15967:29;;15843:159;;;;:::o;16008:248::-;16090:1;16100:113;16114:6;16111:1;16108:13;16100:113;;;16199:1;16194:3;16190:11;16184:18;16180:1;16175:3;16171:11;16164:39;16136:2;16133:1;16129:10;16124:15;;16100:113;;;16247:1;16238:6;16233:3;16229:16;16222:27;16070:186;16008:248;;;:::o;16262:357::-;16340:3;16368:39;16401:5;16368:39;:::i;:::-;16423:61;16477:6;16472:3;16423:61;:::i;:::-;16416:68;;16493:65;16551:6;16546:3;16539:4;16532:5;16528:16;16493:65;:::i;:::-;16583:29;16605:6;16583:29;:::i;:::-;16578:3;16574:39;16567:46;;16344:275;16262:357;;;;:::o;16625:196::-;16714:10;16749:66;16811:3;16803:6;16749:66;:::i;:::-;16735:80;;16625:196;;;;:::o;16827:123::-;16907:4;16939;16934:3;16930:14;16922:22;;16827:123;;;:::o;16984:971::-;17113:3;17142:64;17200:5;17142:64;:::i;:::-;17222:86;17301:6;17296:3;17222:86;:::i;:::-;17215:93;;17334:3;17379:4;17371:6;17367:17;17362:3;17358:27;17409:66;17469:5;17409:66;:::i;:::-;17498:7;17529:1;17514:396;17539:6;17536:1;17533:13;17514:396;;;17610:9;17604:4;17600:20;17595:3;17588:33;17661:6;17655:13;17689:84;17768:4;17753:13;17689:84;:::i;:::-;17681:92;;17796:70;17859:6;17796:70;:::i;:::-;17786:80;;17895:4;17890:3;17886:14;17879:21;;17574:336;17561:1;17558;17554:9;17549:14;;17514:396;;;17518:14;17926:4;17919:11;;17946:3;17939:10;;17118:837;;;;;16984:971;;;;:::o;18039:663::-;18160:3;18196:4;18191:3;18187:14;18283:4;18276:5;18272:16;18266:23;18302:63;18359:4;18354:3;18350:14;18336:12;18302:63;:::i;:::-;18211:164;18462:4;18455:5;18451:16;18445:23;18515:3;18509:4;18505:14;18498:4;18493:3;18489:14;18482:38;18541:123;18659:4;18645:12;18541:123;:::i;:::-;18533:131;;18385:290;18692:4;18685:11;;18165:537;18039:663;;;;:::o;18708:280::-;18839:10;18874:108;18978:3;18970:6;18874:108;:::i;:::-;18860:122;;18708:280;;;;:::o;18994:144::-;19095:4;19127;19122:3;19118:14;19110:22;;18994:144;;;:::o;19226:1159::-;19407:3;19436:85;19515:5;19436:85;:::i;:::-;19537:117;19647:6;19642:3;19537:117;:::i;:::-;19530:124;;19680:3;19725:4;19717:6;19713:17;19708:3;19704:27;19755:87;19836:5;19755:87;:::i;:::-;19865:7;19896:1;19881:459;19906:6;19903:1;19900:13;19881:459;;;19977:9;19971:4;19967:20;19962:3;19955:33;20028:6;20022:13;20056:126;20177:4;20162:13;20056:126;:::i;:::-;20048:134;;20205:91;20289:6;20205:91;:::i;:::-;20195:101;;20325:4;20320:3;20316:14;20309:21;;19941:399;19928:1;19925;19921:9;19916:14;;19881:459;;;19885:14;20356:4;20349:11;;20376:3;20369:10;;19412:973;;;;;19226:1159;;;;:::o;20391:497::-;20596:4;20634:2;20623:9;20619:18;20611:26;;20683:9;20677:4;20673:20;20669:1;20658:9;20654:17;20647:47;20711:170;20876:4;20867:6;20711:170;:::i;:::-;20703:178;;20391:497;;;;:::o;20894:765::-;20980:6;20988;20996;21004;21053:3;21041:9;21032:7;21028:23;21024:33;21021:120;;;21060:79;;:::i;:::-;21021:120;21180:1;21205:53;21250:7;21241:6;21230:9;21226:22;21205:53;:::i;:::-;21195:63;;21151:117;21307:2;21333:53;21378:7;21369:6;21358:9;21354:22;21333:53;:::i;:::-;21323:63;;21278:118;21435:2;21461:53;21506:7;21497:6;21486:9;21482:22;21461:53;:::i;:::-;21451:63;;21406:118;21563:2;21589:53;21634:7;21625:6;21614:9;21610:22;21589:53;:::i;:::-;21579:63;;21534:118;20894:765;;;;;;;:::o;21665:975::-;21776:6;21784;21792;21800;21849:3;21837:9;21828:7;21824:23;21820:33;21817:120;;;21856:79;;:::i;:::-;21817:120;21976:1;22001:53;22046:7;22037:6;22026:9;22022:22;22001:53;:::i;:::-;21991:63;;21947:117;22103:2;22129:53;22174:7;22165:6;22154:9;22150:22;22129:53;:::i;:::-;22119:63;;22074:118;22231:2;22257:53;22302:7;22293:6;22282:9;22278:22;22257:53;:::i;:::-;22247:63;;22202:118;22387:2;22376:9;22372:18;22359:32;22418:18;22410:6;22407:30;22404:117;;;22440:79;;:::i;:::-;22404:117;22545:78;22615:7;22606:6;22595:9;22591:22;22545:78;:::i;:::-;22535:88;;22330:303;21665:975;;;;;;;:::o;22646:945::-;22742:6;22750;22758;22766;22815:3;22803:9;22794:7;22790:23;22786:33;22783:120;;;22822:79;;:::i;:::-;22783:120;22942:1;22967:53;23012:7;23003:6;22992:9;22988:22;22967:53;:::i;:::-;22957:63;;22913:117;23069:2;23095:53;23140:7;23131:6;23120:9;23116:22;23095:53;:::i;:::-;23085:63;;23040:118;23197:2;23223:53;23268:7;23259:6;23248:9;23244:22;23223:53;:::i;:::-;23213:63;;23168:118;23353:2;23342:9;23338:18;23325:32;23384:18;23376:6;23373:30;23370:117;;;23406:79;;:::i;:::-;23370:117;23511:63;23566:7;23557:6;23546:9;23542:22;23511:63;:::i;:::-;23501:73;;23296:288;22646:945;;;;;;;:::o;23597:799::-;23684:6;23692;23700;23749:2;23737:9;23728:7;23724:23;23720:32;23717:119;;;23755:79;;:::i;:::-;23717:119;23875:1;23900:53;23945:7;23936:6;23925:9;23921:22;23900:53;:::i;:::-;23890:63;;23846:117;24002:2;24028:53;24073:7;24064:6;24053:9;24049:22;24028:53;:::i;:::-;24018:63;;23973:118;24158:2;24147:9;24143:18;24130:32;24189:18;24181:6;24178:30;24175:117;;;24211:79;;:::i;:::-;24175:117;24316:63;24371:7;24362:6;24351:9;24347:22;24316:63;:::i;:::-;24306:73;;24101:288;23597:799;;;;;:::o;24402:849::-;24514:6;24522;24530;24579:2;24567:9;24558:7;24554:23;24550:32;24547:119;;;24585:79;;:::i;:::-;24547:119;24705:1;24730:53;24775:7;24766:6;24755:9;24751:22;24730:53;:::i;:::-;24720:63;;24676:117;24832:2;24858:53;24903:7;24894:6;24883:9;24879:22;24858:53;:::i;:::-;24848:63;;24803:118;24988:2;24977:9;24973:18;24960:32;25019:18;25011:6;25008:30;25005:117;;;25041:79;;:::i;:::-;25005:117;25146:88;25226:7;25217:6;25206:9;25202:22;25146:88;:::i;:::-;25136:98;;24931:313;24402:849;;;;;:::o;25257:619::-;25334:6;25342;25350;25399:2;25387:9;25378:7;25374:23;25370:32;25367:119;;;25405:79;;:::i;:::-;25367:119;25525:1;25550:53;25595:7;25586:6;25575:9;25571:22;25550:53;:::i;:::-;25540:63;;25496:117;25652:2;25678:53;25723:7;25714:6;25703:9;25699:22;25678:53;:::i;:::-;25668:63;;25623:118;25780:2;25806:53;25851:7;25842:6;25831:9;25827:22;25806:53;:::i;:::-;25796:63;;25751:118;25257:619;;;;;:::o;25882:152::-;25987:6;26021:5;26015:12;26005:22;;25882:152;;;:::o;26040:222::-;26177:11;26211:6;26206:3;26199:19;26251:4;26246:3;26242:14;26227:29;;26040:222;;;;:::o;26268:170::-;26373:4;26396:3;26388:11;;26426:4;26421:3;26417:14;26409:22;;26268:170;;;:::o;26444:113::-;26510:6;26544:5;26538:12;26528:22;;26444:113;;;:::o;26563:173::-;26651:11;26685:6;26680:3;26673:19;26725:4;26720:3;26716:14;26701:29;;26563:173;;;;:::o;26742:131::-;26808:4;26831:3;26823:11;;26861:4;26856:3;26852:14;26844:22;;26742:131;;;:::o;26879:149::-;26915:7;26955:66;26948:5;26944:78;26933:89;;26879:149;;;:::o;27034:105::-;27109:23;27126:5;27109:23;:::i;:::-;27104:3;27097:36;27034:105;;:::o;27145:175::-;27212:10;27233:44;27273:3;27265:6;27233:44;:::i;:::-;27309:4;27304:3;27300:14;27286:28;;27145:175;;;;:::o;27326:112::-;27395:4;27427;27422:3;27418:14;27410:22;;27326:112;;;:::o;27472:704::-;27579:3;27608:53;27655:5;27608:53;:::i;:::-;27677:75;27745:6;27740:3;27677:75;:::i;:::-;27670:82;;27776:55;27825:5;27776:55;:::i;:::-;27854:7;27885:1;27870:281;27895:6;27892:1;27889:13;27870:281;;;27971:6;27965:13;27998:61;28055:3;28040:13;27998:61;:::i;:::-;27991:68;;28082:59;28134:6;28082:59;:::i;:::-;28072:69;;27930:221;27917:1;27914;27910:9;27905:14;;27870:281;;;27874:14;28167:3;28160:10;;27584:592;;;27472:704;;;;:::o;28274:730::-;28409:3;28445:4;28440:3;28436:14;28536:4;28529:5;28525:16;28519:23;28589:3;28583:4;28579:14;28572:4;28567:3;28563:14;28556:38;28615:73;28683:4;28669:12;28615:73;:::i;:::-;28607:81;;28460:239;28786:4;28779:5;28775:16;28769:23;28839:3;28833:4;28829:14;28822:4;28817:3;28813:14;28806:38;28865:101;28961:4;28947:12;28865:101;:::i;:::-;28857:109;;28709:268;28994:4;28987:11;;28414:590;28274:730;;;;:::o;29010:308::-;29155:10;29190:122;29308:3;29300:6;29190:122;:::i;:::-;29176:136;;29010:308;;;;:::o;29324:151::-;29432:4;29464;29459:3;29455:14;29447:22;;29324:151;;;:::o;29577:1215::-;29772:3;29801:92;29887:5;29801:92;:::i;:::-;29909:124;30026:6;30021:3;29909:124;:::i;:::-;29902:131;;30059:3;30104:4;30096:6;30092:17;30087:3;30083:27;30134:94;30222:5;30134:94;:::i;:::-;30251:7;30282:1;30267:480;30292:6;30289:1;30286:13;30267:480;;;30363:9;30357:4;30353:20;30348:3;30341:33;30414:6;30408:13;30442:140;30577:4;30562:13;30442:140;:::i;:::-;30434:148;;30605:98;30696:6;30605:98;:::i;:::-;30595:108;;30732:4;30727:3;30723:14;30716:21;;30327:420;30314:1;30311;30307:9;30302:14;;30267:480;;;30271:14;30763:4;30756:11;;30783:3;30776:10;;29777:1015;;;;;29577:1215;;;;:::o;30798:525::-;31017:4;31055:2;31044:9;31040:18;31032:26;;31104:9;31098:4;31094:20;31090:1;31079:9;31075:17;31068:47;31132:184;31311:4;31302:6;31132:184;:::i;:::-;31124:192;;30798:525;;;;:::o;31329:474::-;31397:6;31405;31454:2;31442:9;31433:7;31429:23;31425:32;31422:119;;;31460:79;;:::i;:::-;31422:119;31580:1;31605:53;31650:7;31641:6;31630:9;31626:22;31605:53;:::i;:::-;31595:63;;31551:117;31707:2;31733:53;31778:7;31769:6;31758:9;31754:22;31733:53;:::i;:::-;31723:63;;31678:118;31329:474;;;;;:::o;31809:60::-;31837:3;31858:5;31851:12;;31809:60;;;:::o;31875:142::-;31925:9;31958:53;31976:34;31985:24;32003:5;31985:24;:::i;:::-;31976:34;:::i;:::-;31958:53;:::i;:::-;31945:66;;31875:142;;;:::o;32023:126::-;32073:9;32106:37;32137:5;32106:37;:::i;:::-;32093:50;;32023:126;;;:::o;32155:159::-;32238:9;32271:37;32302:5;32271:37;:::i;:::-;32258:50;;32155:159;;;:::o;32320:197::-;32440:70;32504:5;32440:70;:::i;:::-;32435:3;32428:83;32320:197;;:::o;32523:288::-;32649:4;32687:2;32676:9;32672:18;32664:26;;32700:104;32801:1;32790:9;32786:17;32777:6;32700:104;:::i;:::-;32523:288;;;;:::o;32817:1141::-;32947:6;32955;32963;32971;32979;33028:3;33016:9;33007:7;33003:23;32999:33;32996:120;;;33035:79;;:::i;:::-;32996:120;33155:1;33180:53;33225:7;33216:6;33205:9;33201:22;33180:53;:::i;:::-;33170:63;;33126:117;33282:2;33308:53;33353:7;33344:6;33333:9;33329:22;33308:53;:::i;:::-;33298:63;;33253:118;33410:2;33436:53;33481:7;33472:6;33461:9;33457:22;33436:53;:::i;:::-;33426:63;;33381:118;33566:2;33555:9;33551:18;33538:32;33597:18;33589:6;33586:30;33583:117;;;33619:79;;:::i;:::-;33583:117;33724:88;33804:7;33795:6;33784:9;33780:22;33724:88;:::i;:::-;33714:98;;33509:313;33861:3;33888:53;33933:7;33924:6;33913:9;33909:22;33888:53;:::i;:::-;33878:63;;33832:119;32817:1141;;;;;;;;:::o;33964:194::-;34073:11;34107:6;34102:3;34095:19;34147:4;34142:3;34138:14;34123:29;;33964:194;;;;:::o;34192:991::-;34331:3;34360:64;34418:5;34360:64;:::i;:::-;34440:96;34529:6;34524:3;34440:96;:::i;:::-;34433:103;;34562:3;34607:4;34599:6;34595:17;34590:3;34586:27;34637:66;34697:5;34637:66;:::i;:::-;34726:7;34757:1;34742:396;34767:6;34764:1;34761:13;34742:396;;;34838:9;34832:4;34828:20;34823:3;34816:33;34889:6;34883:13;34917:84;34996:4;34981:13;34917:84;:::i;:::-;34909:92;;35024:70;35087:6;35024:70;:::i;:::-;35014:80;;35123:4;35118:3;35114:14;35107:21;;34802:336;34789:1;34786;34782:9;34777:14;;34742:396;;;34746:14;35154:4;35147:11;;35174:3;35167:10;;34336:847;;;;;34192:991;;;;:::o;35189:413::-;35352:4;35390:2;35379:9;35375:18;35367:26;;35439:9;35433:4;35429:20;35425:1;35414:9;35410:17;35403:47;35467:128;35590:4;35581:6;35467:128;:::i;:::-;35459:136;;35189:413;;;;:::o;35608:1271::-;35723:6;35731;35739;35747;35755;35804:3;35792:9;35783:7;35779:23;35775:33;35772:120;;;35811:79;;:::i;:::-;35772:120;35931:1;35956:53;36001:7;35992:6;35981:9;35977:22;35956:53;:::i;:::-;35946:63;;35902:117;36058:2;36084:53;36129:7;36120:6;36109:9;36105:22;36084:53;:::i;:::-;36074:63;;36029:118;36186:2;36212:53;36257:7;36248:6;36237:9;36233:22;36212:53;:::i;:::-;36202:63;;36157:118;36342:2;36331:9;36327:18;36314:32;36373:18;36365:6;36362:30;36359:117;;;36395:79;;:::i;:::-;36359:117;36500:63;36555:7;36546:6;36535:9;36531:22;36500:63;:::i;:::-;36490:73;;36285:288;36640:3;36629:9;36625:19;36612:33;36672:18;36664:6;36661:30;36658:117;;;36694:79;;:::i;:::-;36658:117;36799:63;36854:7;36845:6;36834:9;36830:22;36799:63;:::i;:::-;36789:73;;36583:289;35608:1271;;;;;;;;:::o;36885:144::-;36982:6;37016:5;37010:12;37000:22;;36885:144;;;:::o;37035:214::-;37164:11;37198:6;37193:3;37186:19;37238:4;37233:3;37229:14;37214:29;;37035:214;;;;:::o;37255:162::-;37352:4;37375:3;37367:11;;37405:4;37400:3;37396:14;37388:22;;37255:162;;;:::o;37499:639::-;37618:3;37654:4;37649:3;37645:14;37741:4;37734:5;37730:16;37724:23;37760:63;37817:4;37812:3;37808:14;37794:12;37760:63;:::i;:::-;37669:164;37920:4;37913:5;37909:16;37903:23;37973:3;37967:4;37963:14;37956:4;37951:3;37947:14;37940:38;37999:101;38095:4;38081:12;37999:101;:::i;:::-;37991:109;;37843:268;38128:4;38121:11;;37623:515;37499:639;;;;:::o;38144:276::-;38273:10;38308:106;38410:3;38402:6;38308:106;:::i;:::-;38294:120;;38144:276;;;;:::o;38426:143::-;38526:4;38558;38553:3;38549:14;38541:22;;38426:143;;;:::o;38655:1151::-;38834:3;38863:84;38941:5;38863:84;:::i;:::-;38963:116;39072:6;39067:3;38963:116;:::i;:::-;38956:123;;39105:3;39150:4;39142:6;39138:17;39133:3;39129:27;39180:86;39260:5;39180:86;:::i;:::-;39289:7;39320:1;39305:456;39330:6;39327:1;39324:13;39305:456;;;39401:9;39395:4;39391:20;39386:3;39379:33;39452:6;39446:13;39480:124;39599:4;39584:13;39480:124;:::i;:::-;39472:132;;39627:90;39710:6;39627:90;:::i;:::-;39617:100;;39746:4;39741:3;39737:14;39730:21;;39365:396;39352:1;39349;39345:9;39340:14;;39305:456;;;39309:14;39777:4;39770:11;;39797:3;39790:10;;38839:967;;;;;38655:1151;;;;:::o;39812:493::-;40015:4;40053:2;40042:9;40038:18;40030:26;;40102:9;40096:4;40092:20;40088:1;40077:9;40073:17;40066:47;40130:168;40293:4;40284:6;40130:168;:::i;:::-;40122:176;;39812:493;;;;:::o;40311:90::-;40345:7;40388:5;40381:13;40374:21;40363:32;;40311:90;;;:::o;40407:109::-;40488:21;40503:5;40488:21;:::i;:::-;40483:3;40476:34;40407:109;;:::o;40522:210::-;40609:4;40647:2;40636:9;40632:18;40624:26;;40660:65;40722:1;40711:9;40707:17;40698:6;40660:65;:::i;:::-;40522:210;;;;:::o;40738:829::-;40840:6;40848;40856;40905:2;40893:9;40884:7;40880:23;40876:32;40873:119;;;40911:79;;:::i;:::-;40873:119;41031:1;41056:53;41101:7;41092:6;41081:9;41077:22;41056:53;:::i;:::-;41046:63;;41002:117;41158:2;41184:53;41229:7;41220:6;41209:9;41205:22;41184:53;:::i;:::-;41174:63;;41129:118;41314:2;41303:9;41299:18;41286:32;41345:18;41337:6;41334:30;41331:117;;;41367:79;;:::i;:::-;41331:117;41472:78;41542:7;41533:6;41522:9;41518:22;41472:78;:::i;:::-;41462:88;;41257:303;40738:829;;;;;:::o;41573:329::-;41632:6;41681:2;41669:9;41660:7;41656:23;41652:32;41649:119;;;41687:79;;:::i;:::-;41649:119;41807:1;41832:53;41877:7;41868:6;41857:9;41853:22;41832:53;:::i;:::-;41822:63;;41778:117;41573:329;;;;:::o;41908:180::-;41956:77;41953:1;41946:88;42053:4;42050:1;42043:15;42077:4;42074:1;42067:15;42094:194;42134:4;42154:20;42172:1;42154:20;:::i;:::-;42149:25;;42188:20;42206:1;42188:20;:::i;:::-;42183:25;;42232:1;42229;42225:9;42217:17;;42256:1;42250:4;42247:11;42244:37;;;42261:18;;:::i;:::-;42244:37;42094:194;;;;:::o;42294:118::-;42381:24;42399:5;42381:24;:::i;:::-;42376:3;42369:37;42294:118;;:::o;42418:222::-;42511:4;42549:2;42538:9;42534:18;42526:26;;42562:71;42630:1;42619:9;42615:17;42606:6;42562:71;:::i;:::-;42418:222;;;;:::o;42646:118::-;42733:24;42751:5;42733:24;:::i;:::-;42728:3;42721:37;42646:118;;:::o;42770:222::-;42863:4;42901:2;42890:9;42886:18;42878:26;;42914:71;42982:1;42971:9;42967:17;42958:6;42914:71;:::i;:::-;42770:222;;;;:::o;42998:143::-;43055:5;43086:6;43080:13;43071:22;;43102:33;43129:5;43102:33;:::i;:::-;42998:143;;;;:::o;43147:351::-;43217:6;43266:2;43254:9;43245:7;43241:23;43237:32;43234:119;;;43272:79;;:::i;:::-;43234:119;43392:1;43417:64;43473:7;43464:6;43453:9;43449:22;43417:64;:::i;:::-;43407:74;;43363:128;43147:351;;;;:::o;43504:180::-;43552:77;43549:1;43542:88;43649:4;43646:1;43639:15;43673:4;43670:1;43663:15;43690:118;43777:24;43795:5;43777:24;:::i;:::-;43772:3;43765:37;43690:118;;:::o;43814:332::-;43935:4;43973:2;43962:9;43958:18;43950:26;;43986:71;44054:1;44043:9;44039:17;44030:6;43986:71;:::i;:::-;44067:72;44135:2;44124:9;44120:18;44111:6;44067:72;:::i;:::-;43814:332;;;;;:::o;44152:115::-;44237:23;44254:5;44237:23;:::i;:::-;44232:3;44225:36;44152:115;;:::o;44273:218::-;44364:4;44402:2;44391:9;44387:18;44379:26;;44415:69;44481:1;44470:9;44466:17;44457:6;44415:69;:::i;:::-;44273:218;;;;:::o;44497:191::-;44537:3;44556:20;44574:1;44556:20;:::i;:::-;44551:25;;44590:20;44608:1;44590:20;:::i;:::-;44585:25;;44633:1;44630;44626:9;44619:16;;44654:3;44651:1;44648:10;44645:36;;;44661:18;;:::i;:::-;44645:36;44497:191;;;;:::o;44694:118::-;44781:24;44799:5;44781:24;:::i;:::-;44776:3;44769:37;44694:118;;:::o;44818:442::-;44967:4;45005:2;44994:9;44990:18;44982:26;;45018:71;45086:1;45075:9;45071:17;45062:6;45018:71;:::i;:::-;45099:72;45167:2;45156:9;45152:18;45143:6;45099:72;:::i;:::-;45181;45249:2;45238:9;45234:18;45225:6;45181:72;:::i;:::-;44818:442;;;;;;:::o;45266:332::-;45387:4;45425:2;45414:9;45410:18;45402:26;;45438:71;45506:1;45495:9;45491:17;45482:6;45438:71;:::i;:::-;45519:72;45587:2;45576:9;45572:18;45563:6;45519:72;:::i;:::-;45266:332;;;;;:::o;45604:114::-;45671:6;45705:5;45699:12;45689:22;;45604:114;;;:::o;45724:184::-;45823:11;45857:6;45852:3;45845:19;45897:4;45892:3;45888:14;45873:29;;45724:184;;;;:::o;45914:132::-;45981:4;46004:3;45996:11;;46034:4;46029:3;46025:14;46017:22;;45914:132;;;:::o;46052:108::-;46129:24;46147:5;46129:24;:::i;:::-;46124:3;46117:37;46052:108;;:::o;46166:179::-;46235:10;46256:46;46298:3;46290:6;46256:46;:::i;:::-;46334:4;46329:3;46325:14;46311:28;;46166:179;;;;:::o;46351:113::-;46421:4;46453;46448:3;46444:14;46436:22;;46351:113;;;:::o;46500:732::-;46619:3;46648:54;46696:5;46648:54;:::i;:::-;46718:86;46797:6;46792:3;46718:86;:::i;:::-;46711:93;;46828:56;46878:5;46828:56;:::i;:::-;46907:7;46938:1;46923:284;46948:6;46945:1;46942:13;46923:284;;;47024:6;47018:13;47051:63;47110:3;47095:13;47051:63;:::i;:::-;47044:70;;47137:60;47190:6;47137:60;:::i;:::-;47127:70;;46983:224;46970:1;46967;46963:9;46958:14;;46923:284;;;46927:14;47223:3;47216:10;;46624:608;;;46500:732;;;;:::o;47238:114::-;47305:6;47339:5;47333:12;47323:22;;47238:114;;;:::o;47358:184::-;47457:11;47491:6;47486:3;47479:19;47531:4;47526:3;47522:14;47507:29;;47358:184;;;;:::o;47548:132::-;47615:4;47638:3;47630:11;;47668:4;47663:3;47659:14;47651:22;;47548:132;;;:::o;47686:108::-;47763:24;47781:5;47763:24;:::i;:::-;47758:3;47751:37;47686:108;;:::o;47800:179::-;47869:10;47890:46;47932:3;47924:6;47890:46;:::i;:::-;47968:4;47963:3;47959:14;47945:28;;47800:179;;;;:::o;47985:113::-;48055:4;48087;48082:3;48078:14;48070:22;;47985:113;;;:::o;48134:732::-;48253:3;48282:54;48330:5;48282:54;:::i;:::-;48352:86;48431:6;48426:3;48352:86;:::i;:::-;48345:93;;48462:56;48512:5;48462:56;:::i;:::-;48541:7;48572:1;48557:284;48582:6;48579:1;48576:13;48557:284;;;48658:6;48652:13;48685:63;48744:3;48729:13;48685:63;:::i;:::-;48678:70;;48771:60;48824:6;48771:60;:::i;:::-;48761:70;;48617:224;48604:1;48601;48597:9;48592:14;;48557:284;;;48561:14;48857:3;48850:10;;48258:608;;;48134:732;;;;:::o;48872:744::-;49121:4;49159:2;49148:9;49144:18;49136:26;;49172:71;49240:1;49229:9;49225:17;49216:6;49172:71;:::i;:::-;49290:9;49284:4;49280:20;49275:2;49264:9;49260:18;49253:48;49318:108;49421:4;49412:6;49318:108;:::i;:::-;49310:116;;49473:9;49467:4;49463:20;49458:2;49447:9;49443:18;49436:48;49501:108;49604:4;49595:6;49501:108;:::i;:::-;49493:116;;48872:744;;;;;;:::o;49622:169::-;49706:11;49740:6;49735:3;49728:19;49780:4;49775:3;49771:14;49756:29;;49622:169;;;;:::o;49797:377::-;49885:3;49913:39;49946:5;49913:39;:::i;:::-;49968:71;50032:6;50027:3;49968:71;:::i;:::-;49961:78;;50048:65;50106:6;50101:3;50094:4;50087:5;50083:16;50048:65;:::i;:::-;50138:29;50160:6;50138:29;:::i;:::-;50133:3;50129:39;50122:46;;49889:285;49797:377;;;;:::o;50180:423::-;50321:4;50359:2;50348:9;50344:18;50336:26;;50372:71;50440:1;50429:9;50425:17;50416:6;50372:71;:::i;:::-;50490:9;50484:4;50480:20;50475:2;50464:9;50460:18;50453:48;50518:78;50591:4;50582:6;50518:78;:::i;:::-;50510:86;;50180:423;;;;;:::o;50609:222::-;50702:4;50740:2;50729:9;50725:18;50717:26;;50753:71;50821:1;50810:9;50806:17;50797:6;50753:71;:::i;:::-;50609:222;;;;:::o;50854:732::-;50961:5;50986:81;51002:64;51059:6;51002:64;:::i;:::-;50986:81;:::i;:::-;50977:90;;51087:5;51116:6;51109:5;51102:21;51150:4;51143:5;51139:16;51132:23;;51203:4;51195:6;51191:17;51183:6;51179:30;51232:3;51224:6;51221:15;51218:122;;;51251:79;;:::i;:::-;51218:122;51366:6;51349:231;51383:6;51378:3;51375:15;51349:231;;;51458:3;51487:48;51531:3;51519:10;51487:48;:::i;:::-;51482:3;51475:61;51565:4;51560:3;51556:14;51549:21;;51425:155;51409:4;51404:3;51400:14;51393:21;;51349:231;;;51353:21;50967:619;;50854:732;;;;;:::o;51609:385::-;51691:5;51740:3;51733:4;51725:6;51721:17;51717:27;51707:122;;51748:79;;:::i;:::-;51707:122;51858:6;51852:13;51883:105;51984:3;51976:6;51969:4;51961:6;51957:17;51883:105;:::i;:::-;51874:114;;51697:297;51609:385;;;;:::o;52000:554::-;52095:6;52144:2;52132:9;52123:7;52119:23;52115:32;52112:119;;;52150:79;;:::i;:::-;52112:119;52291:1;52280:9;52276:17;52270:24;52321:18;52313:6;52310:30;52307:117;;;52343:79;;:::i;:::-;52307:117;52448:89;52529:7;52520:6;52509:9;52505:22;52448:89;:::i;:::-;52438:99;;52241:306;52000:554;;;;:::o;52560:180::-;52608:77;52605:1;52598:88;52705:4;52702:1;52695:15;52729:4;52726:1;52719:15;52746:320;52790:6;52827:1;52821:4;52817:12;52807:22;;52874:1;52868:4;52864:12;52895:18;52885:81;;52951:4;52943:6;52939:17;52929:27;;52885:81;53013:2;53005:6;53002:14;52982:18;52979:38;52976:84;;53032:18;;:::i;:::-;52976:84;52797:269;52746:320;;;:::o;53072:85::-;53117:7;53146:5;53135:16;;53072:85;;;:::o;53163:158::-;53221:9;53254:61;53272:42;53281:32;53307:5;53281:32;:::i;:::-;53272:42;:::i;:::-;53254:61;:::i;:::-;53241:74;;53163:158;;;:::o;53327:147::-;53422:45;53461:5;53422:45;:::i;:::-;53417:3;53410:58;53327:147;;:::o;53480:458::-;53637:4;53675:2;53664:9;53660:18;53652:26;;53688:71;53756:1;53745:9;53741:17;53732:6;53688:71;:::i;:::-;53769:72;53837:2;53826:9;53822:18;53813:6;53769:72;:::i;:::-;53851:80;53927:2;53916:9;53912:18;53903:6;53851:80;:::i;:::-;53480:458;;;;;;:::o;53944:483::-;54115:4;54153:2;54142:9;54138:18;54130:26;;54166:71;54234:1;54223:9;54219:17;54210:6;54166:71;:::i;:::-;54284:9;54278:4;54274:20;54269:2;54258:9;54254:18;54247:48;54312:108;54415:4;54406:6;54312:108;:::i;:::-;54304:116;;53944:483;;;;;:::o;54433:523::-;54624:4;54662:2;54651:9;54647:18;54639:26;;54675:71;54743:1;54732:9;54728:17;54719:6;54675:71;:::i;:::-;54793:9;54787:4;54783:20;54778:2;54767:9;54763:18;54756:48;54821:128;54944:4;54935:6;54821:128;:::i;:::-;54813:136;;54433:523;;;;;:::o;54962:143::-;55019:5;55050:6;55044:13;55035:22;;55066:33;55093:5;55066:33;:::i;:::-;54962:143;;;;:::o;55111:351::-;55181:6;55230:2;55218:9;55209:7;55205:23;55201:32;55198:119;;;55236:79;;:::i;:::-;55198:119;55356:1;55381:64;55437:7;55428:6;55417:9;55413:22;55381:64;:::i;:::-;55371:74;;55327:128;55111:351;;;;:::o;55468:98::-;55519:6;55553:5;55547:12;55537:22;;55468:98;;;:::o;55572:158::-;55645:11;55679:6;55674:3;55667:19;55719:4;55714:3;55710:14;55695:29;;55572:158;;;;:::o;55736:353::-;55812:3;55840:38;55872:5;55840:38;:::i;:::-;55894:60;55947:6;55942:3;55894:60;:::i;:::-;55887:67;;55963:65;56021:6;56016:3;56009:4;56002:5;55998:16;55963:65;:::i;:::-;56053:29;56075:6;56053:29;:::i;:::-;56048:3;56044:39;56037:46;;55816:273;55736:353;;;;:::o;56095:101::-;56131:7;56171:18;56164:5;56160:30;56149:41;;56095:101;;;:::o;56202:105::-;56277:23;56294:5;56277:23;:::i;:::-;56272:3;56265:36;56202:105;;:::o;56355:609::-;56468:3;56504:4;56499:3;56495:14;56598:4;56591:5;56587:16;56581:23;56651:3;56645:4;56641:14;56634:4;56629:3;56625:14;56618:38;56677:73;56745:4;56731:12;56677:73;:::i;:::-;56669:81;;56519:242;56847:4;56840:5;56836:16;56830:23;56866:61;56921:4;56916:3;56912:14;56898:12;56866:61;:::i;:::-;56771:166;56954:4;56947:11;;56473:491;56355:609;;;;:::o;57018:1460::-;57147:3;57183:4;57178:3;57174:14;57280:4;57273:5;57269:16;57263:23;57299:63;57356:4;57351:3;57347:14;57333:12;57299:63;:::i;:::-;57198:174;57462:4;57455:5;57451:16;57445:23;57481:61;57536:4;57531:3;57527:14;57513:12;57481:61;:::i;:::-;57382:170;57640:4;57633:5;57629:16;57623:23;57659:63;57716:4;57711:3;57707:14;57693:12;57659:63;:::i;:::-;57562:170;57822:4;57815:5;57811:16;57805:23;57841:63;57898:4;57893:3;57889:14;57875:12;57841:63;:::i;:::-;57742:172;58007:4;58000:5;57996:16;57990:23;58060:3;58054:4;58050:14;58043:4;58038:3;58034:14;58027:38;58086:71;58152:4;58138:12;58086:71;:::i;:::-;58078:79;;57924:244;58254:4;58247:5;58243:16;58237:23;58307:3;58301:4;58297:14;58290:4;58285:3;58281:14;58274:38;58333:107;58435:4;58421:12;58333:107;:::i;:::-;58325:115;;58178:273;58468:4;58461:11;;57152:1326;57018:1460;;;;:::o;58484:613::-;58693:4;58731:2;58720:9;58716:18;58708:26;;58744:71;58812:1;58801:9;58797:17;58788:6;58744:71;:::i;:::-;58862:9;58856:4;58852:20;58847:2;58836:9;58832:18;58825:48;58890:118;59003:4;58994:6;58890:118;:::i;:::-;58882:126;;59018:72;59086:2;59075:9;59071:18;59062:6;59018:72;:::i;:::-;58484:613;;;;;;:::o;59103:332::-;59224:4;59262:2;59251:9;59247:18;59239:26;;59275:71;59343:1;59332:9;59328:17;59319:6;59275:71;:::i;:::-;59356:72;59424:2;59413:9;59409:18;59400:6;59356:72;:::i;:::-;59103:332;;;;;:::o;59441:233::-;59480:3;59503:24;59521:5;59503:24;:::i;:::-;59494:33;;59549:66;59542:5;59539:77;59536:103;;59619:18;;:::i;:::-;59536:103;59666:1;59659:5;59655:13;59648:20;;59441:233;;;:::o;59680:79::-;59719:7;59748:5;59737:16;;59680:79;;;:::o;59765:157::-;59870:45;59890:24;59908:5;59890:24;:::i;:::-;59870:45;:::i;:::-;59865:3;59858:58;59765:157;;:::o;59928:94::-;59961:8;60009:5;60005:2;60001:14;59980:35;;59928:94;;;:::o;60028:::-;60067:7;60096:20;60110:5;60096:20;:::i;:::-;60085:31;;60028:94;;;:::o;60128:100::-;60167:7;60196:26;60216:5;60196:26;:::i;:::-;60185:37;;60128:100;;;:::o;60234:157::-;60339:45;60359:24;60377:5;60359:24;:::i;:::-;60339:45;:::i;:::-;60334:3;60327:58;60234:157;;:::o;60397:397::-;60537:3;60552:75;60623:3;60614:6;60552:75;:::i;:::-;60652:2;60647:3;60643:12;60636:19;;60665:75;60736:3;60727:6;60665:75;:::i;:::-;60765:2;60760:3;60756:12;60749:19;;60785:3;60778:10;;60397:397;;;;;:::o;60800:116::-;60851:4;60874:3;60866:11;;60904:4;60899:3;60895:14;60887:22;;60800:116;;;:::o;60922:154::-;60965:11;61001:29;61025:3;61019:10;61001:29;:::i;:::-;61064:5;61040:29;;60977:99;60922:154;;;:::o;61082:107::-;61126:8;61176:5;61170:4;61166:16;61145:37;;61082:107;;;;:::o;61195:594::-;61279:5;61310:38;61342:5;61310:38;:::i;:::-;61373:5;61400:40;61434:5;61400:40;:::i;:::-;61388:52;;61459:35;61485:8;61459:35;:::i;:::-;61450:44;;61518:2;61510:6;61507:14;61504:278;;;61589:169;61674:66;61644:6;61640:2;61636:15;61633:1;61629:23;61589:169;:::i;:::-;61566:5;61545:227;61536:236;;61504:278;61285:504;;61195:594;;;:::o;61795:148::-;61897:11;61934:3;61919:18;;61795:148;;;;:::o;61949:390::-;62055:3;62083:39;62116:5;62083:39;:::i;:::-;62138:89;62220:6;62215:3;62138:89;:::i;:::-;62131:96;;62236:65;62294:6;62289:3;62282:4;62275:5;62271:16;62236:65;:::i;:::-;62326:6;62321:3;62317:16;62310:23;;62059:280;61949:390;;;;:::o;62345:275::-;62477:3;62499:95;62590:3;62581:6;62499:95;:::i;:::-;62492:102;;62611:3;62604:10;;62345:275;;;;:::o;62626:332::-;62747:4;62785:2;62774:9;62770:18;62762:26;;62798:71;62866:1;62855:9;62851:17;62842:6;62798:71;:::i;:::-;62879:72;62947:2;62936:9;62932:18;62923:6;62879:72;:::i;:::-;62626:332;;;;;:::o;62964:::-;63085:4;63123:2;63112:9;63108:18;63100:26;;63136:71;63204:1;63193:9;63189:17;63180:6;63136:71;:::i;:::-;63217:72;63285:2;63274:9;63270:18;63261:6;63217:72;:::i;:::-;62964:332;;;;;:::o;63302:171::-;63442:23;63438:1;63430:6;63426:14;63419:47;63302:171;:::o;63479:402::-;63639:3;63660:85;63742:2;63737:3;63660:85;:::i;:::-;63653:92;;63754:93;63843:3;63754:93;:::i;:::-;63872:2;63867:3;63863:12;63856:19;;63479:402;;;:::o;63887:381::-;64072:3;64094:148;64238:3;64094:148;:::i;:::-;64087:155;;64259:3;64252:10;;63887:381;;;:::o;64274:79::-;64313:7;64342:5;64331:16;;64274:79;;;:::o;64359:157::-;64464:45;64484:24;64502:5;64484:24;:::i;:::-;64464:45;:::i;:::-;64459:3;64452:58;64359:157;;:::o;64522:679::-;64718:3;64733:75;64804:3;64795:6;64733:75;:::i;:::-;64833:2;64828:3;64824:12;64817:19;;64846:75;64917:3;64908:6;64846:75;:::i;:::-;64946:2;64941:3;64937:12;64930:19;;64959:75;65030:3;65021:6;64959:75;:::i;:::-;65059:2;65054:3;65050:12;65043:19;;65072:75;65143:3;65134:6;65072:75;:::i;:::-;65172:2;65167:3;65163:12;65156:19;;65192:3;65185:10;;64522:679;;;;;;;:::o;65207:249::-;65347:34;65343:1;65335:6;65331:14;65324:58;65416:32;65411:2;65403:6;65399:15;65392:57;65207:249;:::o;65462:366::-;65604:3;65625:67;65689:2;65684:3;65625:67;:::i;:::-;65618:74;;65701:93;65790:3;65701:93;:::i;:::-;65819:2;65814:3;65810:12;65803:19;;65462:366;;;:::o;65834:419::-;66000:4;66038:2;66027:9;66023:18;66015:26;;66087:9;66081:4;66077:20;66073:1;66062:9;66058:17;66051:47;66115:131;66241:4;66115:131;:::i;:::-;66107:139;;65834:419;;;:::o;66259:180::-;66307:77;66304:1;66297:88;66404:4;66401:1;66394:15;66428:4;66425:1;66418:15;66445:176;66477:1;66494:20;66512:1;66494:20;:::i;:::-;66489:25;;66528:20;66546:1;66528:20;:::i;:::-;66523:25;;66567:1;66557:35;;66572:18;;:::i;:::-;66557:35;66613:1;66610;66606:9;66601:14;;66445:176;;;;:::o;66627:423::-;66768:4;66806:2;66795:9;66791:18;66783:26;;66855:9;66849:4;66845:20;66841:1;66830:9;66826:17;66819:47;66883:78;66956:4;66947:6;66883:78;:::i;:::-;66875:86;;66971:72;67039:2;67028:9;67024:18;67015:6;66971:72;:::i;:::-;66627:423;;;;;:::o;67056:180::-;67104:77;67101:1;67094:88;67201:4;67198:1;67191:15;67225:4;67222:1;67215:15","linkReferences":{}},"methodIdentifiers":{"IS_TEST()":"fa7626d4","excludeArtifacts()":"b5508aa9","excludeContracts()":"e20c9f71","excludeSelectors()":"b0464fdc","excludeSenders()":"1ed7831c","failed()":"ba414fa6","registry()":"7b103999","setUp()":"0a9254e4","targetArtifactSelectors()":"66d9a9a0","targetArtifacts()":"85226c81","targetContracts()":"3f7286f4","targetInterfaces()":"2ade3880","targetSelectors()":"916a17c6","targetSenders()":"3e5e3c23","test_addProjectUrl(address,bytes12,string)":"56f52e42","test_addProjectUrlBatch(address,bytes12,string[])":"4cf9fbff","test_addProjectUrlHash(address,bytes12,bytes32)":"ff679dab","test_addProjectUrlHashBatch(address,bytes12,bytes32[])":"c5a36339","test_claimProject(address,bytes12)":"d887d395","test_fail_addProjectUrlAlreadyExists(address,bytes12,string)":"785cf657","test_fail_addProjectUrlAlreadyExistsHash(address,bytes12,string)":"ad2ac469","test_fail_addProjectUrlByNonOwner(address,address,bytes12,string)":"f72c62f1","test_fail_addProjectUrlHashAlreadyExists(address,bytes12,bytes32)":"d3609617","test_fail_addProjectUrlHashAlreadyExistsFull(address,bytes12,string)":"e575719f","test_fail_addProjectUrlHashBatchByNonOwner(address,address,bytes12,bytes32[])":"2d03611e","test_fail_addProjectUrlHashByNonOwner(address,address,bytes12,bytes32)":"ad0d1166","test_fail_claimInvalidOwner(bytes12)":"ca8c203d","test_fail_claimProjectTwice(address,address,bytes12)":"2955e468","test_fail_removeNonexistentUrl(address,bytes12,string)":"4b05e990","test_fail_removeNonexistentUrlHash(address,bytes12,bytes32)":"58bab962","test_fail_removeProjectUrlByNonOwner(address,address,bytes12,string)":"2e84025c","test_fail_removeProjectUrlHashBatchByNonOwner(address,address,bytes12,bytes32[])":"7d1d95b5","test_fail_removeProjectUrlHashByNonOwner(address,address,bytes12,bytes32)":"2c6eec1e","test_fail_removeUrlHashWrongIndex(address,bytes12,bytes32[],uint256)":"0b3307e8","test_fail_transferByNonAdmin(address,address,bytes12)":"12fe420e","test_fail_transferInvalidOwner(address,bytes12)":"72976749","test_fail_validateAttestationWithInvalidUrl(address,address,bytes12,string,string)":"891e3354","test_removeProjectUrl(address,bytes12,string[],uint256)":"2a475b0d","test_removeProjectUrlHash(address,bytes12,bytes32[],uint256)":"9cc595a4","test_removeProjectUrlHashBatch(address,bytes12,bytes32[])":"eed35792","test_removeProjectUrlHashBatchWithInvalidUrlIdxs(address,bytes12,bytes32[],uint256[])":"61fd155b","test_removeProjectUrlHashBatchWithInvalidUrlIdxsOrder(address,bytes12,bytes32[],uint256[])":"27d334b2","test_transferProject(address,address,bytes12,bytes32)":"538d6c48","test_validateAttestationMultiple(address,address,bytes12,string[],uint256)":"820c2c2c","test_validateAttestationSingle(address,address,bytes12,string)":"ce7bcae3"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"ProjectClaimed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"ProjectOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"urlHash\",\"type\":\"bytes32\"}],\"name\":\"ProjectUrlAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"urlHash\",\"type\":\"bytes32\"}],\"name\":\"ProjectUrlRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"name\":\"log\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"log_address\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"val\",\"type\":\"uint256[]\"}],\"name\":\"log_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"int256[]\",\"name\":\"val\",\"type\":\"int256[]\"}],\"name\":\"log_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"val\",\"type\":\"address[]\"}],\"name\":\"log_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"log_bytes\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"log_bytes32\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"name\":\"log_int\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"val\",\"type\":\"address\"}],\"name\":\"log_named_address\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"val\",\"type\":\"uint256[]\"}],\"name\":\"log_named_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"int256[]\",\"name\":\"val\",\"type\":\"int256[]\"}],\"name\":\"log_named_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"val\",\"type\":\"address[]\"}],\"name\":\"log_named_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"val\",\"type\":\"bytes\"}],\"name\":\"log_named_bytes\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"val\",\"type\":\"bytes32\"}],\"name\":\"log_named_bytes32\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"val\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"log_named_decimal_int\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"val\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"log_named_decimal_uint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"val\",\"type\":\"int256\"}],\"name\":\"log_named_int\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"val\",\"type\":\"string\"}],\"name\":\"log_named_string\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"val\",\"type\":\"uint256\"}],\"name\":\"log_named_uint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"name\":\"log_string\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"log_uint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"logs\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"IS_TEST\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeArtifacts\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"excludedArtifacts_\",\"type\":\"string[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeContracts\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"excludedContracts_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeSelectors\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"bytes4[]\",\"name\":\"selectors\",\"type\":\"bytes4[]\"}],\"internalType\":\"struct StdInvariant.FuzzSelector[]\",\"name\":\"excludedSelectors_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"excludedSenders_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"failed\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contract ImplicitProjectRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"setUp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetArtifactSelectors\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"artifact\",\"type\":\"string\"},{\"internalType\":\"bytes4[]\",\"name\":\"selectors\",\"type\":\"bytes4[]\"}],\"internalType\":\"struct StdInvariant.FuzzArtifactSelector[]\",\"name\":\"targetedArtifactSelectors_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetArtifacts\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"targetedArtifacts_\",\"type\":\"string[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetContracts\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"targetedContracts_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetInterfaces\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"string[]\",\"name\":\"artifacts\",\"type\":\"string[]\"}],\"internalType\":\"struct StdInvariant.FuzzInterface[]\",\"name\":\"targetedInterfaces_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetSelectors\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"bytes4[]\",\"name\":\"selectors\",\"type\":\"bytes4[]\"}],\"internalType\":\"struct StdInvariant.FuzzSelector[]\",\"name\":\"targetedSelectors_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"targetedSenders_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"string\",\"name\":\"url\",\"type\":\"string\"}],\"name\":\"test_addProjectUrl\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"string[]\",\"name\":\"urls\",\"type\":\"string[]\"}],\"name\":\"test_addProjectUrlBatch\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32\",\"name\":\"urlHash\",\"type\":\"bytes32\"}],\"name\":\"test_addProjectUrlHash\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32[]\",\"name\":\"urlHashes\",\"type\":\"bytes32[]\"}],\"name\":\"test_addProjectUrlHashBatch\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"}],\"name\":\"test_claimProject\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"string\",\"name\":\"url\",\"type\":\"string\"}],\"name\":\"test_fail_addProjectUrlAlreadyExists\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"string\",\"name\":\"url\",\"type\":\"string\"}],\"name\":\"test_fail_addProjectUrlAlreadyExistsHash\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nonOwner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"string\",\"name\":\"url\",\"type\":\"string\"}],\"name\":\"test_fail_addProjectUrlByNonOwner\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32\",\"name\":\"urlHash\",\"type\":\"bytes32\"}],\"name\":\"test_fail_addProjectUrlHashAlreadyExists\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"string\",\"name\":\"url\",\"type\":\"string\"}],\"name\":\"test_fail_addProjectUrlHashAlreadyExistsFull\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nonOwner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32[]\",\"name\":\"urlHashes\",\"type\":\"bytes32[]\"}],\"name\":\"test_fail_addProjectUrlHashBatchByNonOwner\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nonOwner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32\",\"name\":\"urlHash\",\"type\":\"bytes32\"}],\"name\":\"test_fail_addProjectUrlHashByNonOwner\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"}],\"name\":\"test_fail_claimInvalidOwner\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"otherUser\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"}],\"name\":\"test_fail_claimProjectTwice\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"string\",\"name\":\"url\",\"type\":\"string\"}],\"name\":\"test_fail_removeNonexistentUrl\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32\",\"name\":\"urlHash\",\"type\":\"bytes32\"}],\"name\":\"test_fail_removeNonexistentUrlHash\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nonOwner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"string\",\"name\":\"url\",\"type\":\"string\"}],\"name\":\"test_fail_removeProjectUrlByNonOwner\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nonOwner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32[]\",\"name\":\"urlHashes\",\"type\":\"bytes32[]\"}],\"name\":\"test_fail_removeProjectUrlHashBatchByNonOwner\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nonOwner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32\",\"name\":\"urlHash\",\"type\":\"bytes32\"}],\"name\":\"test_fail_removeProjectUrlHashByNonOwner\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32[]\",\"name\":\"urlHashes\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint256\",\"name\":\"urlHashIdx\",\"type\":\"uint256\"}],\"name\":\"test_fail_removeUrlHashWrongIndex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nonOwner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"}],\"name\":\"test_fail_transferByNonAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"}],\"name\":\"test_fail_transferInvalidOwner\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"wallet\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"string\",\"name\":\"validUrl\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"invalidUrl\",\"type\":\"string\"}],\"name\":\"test_fail_validateAttestationWithInvalidUrl\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"string[]\",\"name\":\"urls\",\"type\":\"string[]\"},{\"internalType\":\"uint256\",\"name\":\"urlIdx\",\"type\":\"uint256\"}],\"name\":\"test_removeProjectUrl\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32[]\",\"name\":\"urlHashes\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint256\",\"name\":\"urlHashIdx\",\"type\":\"uint256\"}],\"name\":\"test_removeProjectUrlHash\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32[]\",\"name\":\"urlHashes\",\"type\":\"bytes32[]\"}],\"name\":\"test_removeProjectUrlHashBatch\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32[]\",\"name\":\"urlHashes\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint256[]\",\"name\":\"urlIdxs\",\"type\":\"uint256[]\"}],\"name\":\"test_removeProjectUrlHashBatchWithInvalidUrlIdxs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32[]\",\"name\":\"urlHashes\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint256[]\",\"name\":\"urlIdxs\",\"type\":\"uint256[]\"}],\"name\":\"test_removeProjectUrlHashBatchWithInvalidUrlIdxsOrder\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"bytes32\",\"name\":\"urlHash\",\"type\":\"bytes32\"}],\"name\":\"test_transferProject\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"wallet\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"string[]\",\"name\":\"urls\",\"type\":\"string[]\"},{\"internalType\":\"uint256\",\"name\":\"urlIdx\",\"type\":\"uint256\"}],\"name\":\"test_validateAttestationMultiple\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"wallet\",\"type\":\"address\"},{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"string\",\"name\":\"url\",\"type\":\"string\"}],\"name\":\"test_validateAttestationSingle\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"events\":{\"ProjectClaimed(bytes32,address)\":{\"notice\":\"Emitted when a project is claimed\"},\"ProjectOwnerTransferred(bytes32,address)\":{\"notice\":\"Emitted when a project owner is transferred\"},\"ProjectUrlAdded(bytes32,bytes32)\":{\"notice\":\"Emitted when a project URL is added\"},\"ProjectUrlRemoved(bytes32,bytes32)\":{\"notice\":\"Emitted when a project URL is removed\"}},\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"test/ImplicitProjectRegistry.t.sol\":\"ImplicitProjectRegistryTest\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/StdAssertions.sol\":{\"keccak256\":\"0xd8eec16034b53b52c90a3d720e121ce7d30d64cc57d854db7d817d5b382dda43\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://612780755e32668c7e3b747d94d16c7291101144e084dd9ee563f071711e99e3\",\"dweb:/ipfs/QmQgtFJXEmDtSHT7tZQTMbb6PCDpq5UDYFvrBnWk1Xo2SY\"]},\"lib/forge-std/src/StdChains.sol\":{\"keccak256\":\"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2\",\"dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe\"]},\"lib/forge-std/src/StdCheats.sol\":{\"keccak256\":\"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41\",\"dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK\"]},\"lib/forge-std/src/StdConstants.sol\":{\"keccak256\":\"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc\",\"dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r\"]},\"lib/forge-std/src/StdError.sol\":{\"keccak256\":\"0xbf477b11a42d7611696956546bcfaa29317d1166bf65e402344599c05943fc77\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://bc2e117d1135e030862b96a6526a43feb38d396cc79857f1fb696d4eff0e5fd6\",\"dweb:/ipfs/QmdSuQ5RrQudTLsNmWXGEeVJX8gR5U9XPm6m4dwwuQnJrj\"]},\"lib/forge-std/src/StdInvariant.sol\":{\"keccak256\":\"0x4dab3021edfa9511bbdd80c48f060ef62eaf457f99eaf841f561fc2557d9a08d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://07668628673174cf8f27f8f4e1f862bab775013ec247eb34f698c5005f229391\",\"dweb:/ipfs/QmPJsiiYwmCZXMsHmQv5tg8VF3CAhNdat7WnKLTWZZH2v5\"]},\"lib/forge-std/src/StdJson.sol\":{\"keccak256\":\"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974\",\"dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3\"]},\"lib/forge-std/src/StdMath.sol\":{\"keccak256\":\"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92\",\"dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/StdStyle.sol\":{\"keccak256\":\"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8\",\"dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK\"]},\"lib/forge-std/src/StdToml.sol\":{\"keccak256\":\"0x58a72c765ed3f7ff6b105509689658795b8a3739b8931772a497155878381861\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b4a3746f4fabaeb980bd77d9e091d3904ee38a6c0e191bfa8ba6874c6f8558a3\",\"dweb:/ipfs/QmUfFDMEn461FgGEXt5HicyGD54sc28sLaQ9JRWDMBKed8\"]},\"lib/forge-std/src/StdUtils.sol\":{\"keccak256\":\"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a\",\"dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT\"]},\"lib/forge-std/src/Test.sol\":{\"keccak256\":\"0x3dda6083a83dfa3e8526e97bcc28e862ee2442dd58fe94d5c426d65b8e38f73c\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://33f8c02e4dabdab86a6825125856446a8657eacd712318b51b7818e4a6f6e3f4\",\"dweb:/ipfs/QmRKSjVnrk54yr8wTK2e6QxRjiuba2H8HJSKunHAkdo7RG\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]},\"lib/forge-std/src/console2.sol\":{\"keccak256\":\"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d\",\"dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ\"]},\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]},\"lib/forge-std/src/safeconsole.sol\":{\"keccak256\":\"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab\",\"dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3\"]},\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol\":{\"keccak256\":\"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287\",\"dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p\"]},\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol\":{\"keccak256\":\"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621\",\"dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]},\"src/helper/SignalsImplicitMode.sol\":{\"keccak256\":\"0x40d1c9354bca0b8275e0150f53d6e8d760a78ad62c39ed831ab46d2ee6c8ea65\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://cf248253dc5a9c6612e7b3f5ce096c8c83d8f4b328de4889b58fb0fef0e3d8af\",\"dweb:/ipfs/QmcDGY9KwbQQQ5maxhNsM6vWWn8xigcCXw3ihrHpKvad6L\"]},\"src/registry/IImplicitProjectRegistry.sol\":{\"keccak256\":\"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de\",\"dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6\"]},\"src/registry/IImplicitProjectValidation.sol\":{\"keccak256\":\"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c\",\"dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6\"]},\"src/registry/ImplicitProjectRegistry.sol\":{\"keccak256\":\"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa\",\"dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8\"]},\"test/ImplicitProjectRegistry.t.sol\":{\"keccak256\":\"0x5ad8be4e1ad4d899592cdb015d30b30836d842e6a243e78fb222f66bb915e604\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://1d9151ed53ec8cef0186e1a0b084f02ab68c0b4b076c91a148e6106cb0d9dfb9\",\"dweb:/ipfs/QmcQdZ2iBc5wDvDxU4ARfW8HiideFbXsfZE9mi4jwBBWTv\"]},\"test/TestHelper.sol\":{\"keccak256\":\"0xba551fda365d1deef08d0e627d0233810141ea6dbfe770be3ebdb839a6af16a9\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://fb9173a19cc248878fba10321bc83c5226d12eebacded8aad5c114dc39d52f15\",\"dweb:/ipfs/QmTEH8EuNa8FcTEF4PiDPcmLYspxGEw3jbzEwVYFdxZWeD\"]},\"test/mock/SignalsImplicitModeMock.sol\":{\"keccak256\":\"0x15d4554d50385ac8d4529e6d37b74b4f8d7e9ba6051cf7d7614561b6319ff4ba\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://165c71fb13a424c151fed7bb9d7880f7993cbd73f1cde117c148dc7f59216285\",\"dweb:/ipfs/QmWv5YckRhNsGrusXobNodxYtyJqQK2S2VXtNfjwjahwwQ\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32","indexed":true},{"internalType":"address","name":"owner","type":"address","indexed":true}],"type":"event","name":"ProjectClaimed","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32","indexed":true},{"internalType":"address","name":"newOwner","type":"address","indexed":true}],"type":"event","name":"ProjectOwnerTransferred","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32","indexed":true},{"internalType":"bytes32","name":"urlHash","type":"bytes32","indexed":true}],"type":"event","name":"ProjectUrlAdded","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32","indexed":true},{"internalType":"bytes32","name":"urlHash","type":"bytes32","indexed":true}],"type":"event","name":"ProjectUrlRemoved","anonymous":false},{"inputs":[{"internalType":"string","name":"","type":"string","indexed":false}],"type":"event","name":"log","anonymous":false},{"inputs":[{"internalType":"address","name":"","type":"address","indexed":false}],"type":"event","name":"log_address","anonymous":false},{"inputs":[{"internalType":"uint256[]","name":"val","type":"uint256[]","indexed":false}],"type":"event","name":"log_array","anonymous":false},{"inputs":[{"internalType":"int256[]","name":"val","type":"int256[]","indexed":false}],"type":"event","name":"log_array","anonymous":false},{"inputs":[{"internalType":"address[]","name":"val","type":"address[]","indexed":false}],"type":"event","name":"log_array","anonymous":false},{"inputs":[{"internalType":"bytes","name":"","type":"bytes","indexed":false}],"type":"event","name":"log_bytes","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32","indexed":false}],"type":"event","name":"log_bytes32","anonymous":false},{"inputs":[{"internalType":"int256","name":"","type":"int256","indexed":false}],"type":"event","name":"log_int","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"address","name":"val","type":"address","indexed":false}],"type":"event","name":"log_named_address","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"uint256[]","name":"val","type":"uint256[]","indexed":false}],"type":"event","name":"log_named_array","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"int256[]","name":"val","type":"int256[]","indexed":false}],"type":"event","name":"log_named_array","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"address[]","name":"val","type":"address[]","indexed":false}],"type":"event","name":"log_named_array","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"bytes","name":"val","type":"bytes","indexed":false}],"type":"event","name":"log_named_bytes","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"bytes32","name":"val","type":"bytes32","indexed":false}],"type":"event","name":"log_named_bytes32","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"int256","name":"val","type":"int256","indexed":false},{"internalType":"uint256","name":"decimals","type":"uint256","indexed":false}],"type":"event","name":"log_named_decimal_int","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"uint256","name":"val","type":"uint256","indexed":false},{"internalType":"uint256","name":"decimals","type":"uint256","indexed":false}],"type":"event","name":"log_named_decimal_uint","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"int256","name":"val","type":"int256","indexed":false}],"type":"event","name":"log_named_int","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"string","name":"val","type":"string","indexed":false}],"type":"event","name":"log_named_string","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"uint256","name":"val","type":"uint256","indexed":false}],"type":"event","name":"log_named_uint","anonymous":false},{"inputs":[{"internalType":"string","name":"","type":"string","indexed":false}],"type":"event","name":"log_string","anonymous":false},{"inputs":[{"internalType":"uint256","name":"","type":"uint256","indexed":false}],"type":"event","name":"log_uint","anonymous":false},{"inputs":[{"internalType":"bytes","name":"","type":"bytes","indexed":false}],"type":"event","name":"logs","anonymous":false},{"inputs":[],"stateMutability":"view","type":"function","name":"IS_TEST","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeArtifacts","outputs":[{"internalType":"string[]","name":"excludedArtifacts_","type":"string[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeContracts","outputs":[{"internalType":"address[]","name":"excludedContracts_","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeSelectors","outputs":[{"internalType":"struct StdInvariant.FuzzSelector[]","name":"excludedSelectors_","type":"tuple[]","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"bytes4[]","name":"selectors","type":"bytes4[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeSenders","outputs":[{"internalType":"address[]","name":"excludedSenders_","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"failed","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"registry","outputs":[{"internalType":"contract ImplicitProjectRegistry","name":"","type":"address"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"setUp"},{"inputs":[],"stateMutability":"view","type":"function","name":"targetArtifactSelectors","outputs":[{"internalType":"struct StdInvariant.FuzzArtifactSelector[]","name":"targetedArtifactSelectors_","type":"tuple[]","components":[{"internalType":"string","name":"artifact","type":"string"},{"internalType":"bytes4[]","name":"selectors","type":"bytes4[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetArtifacts","outputs":[{"internalType":"string[]","name":"targetedArtifacts_","type":"string[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetContracts","outputs":[{"internalType":"address[]","name":"targetedContracts_","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetInterfaces","outputs":[{"internalType":"struct StdInvariant.FuzzInterface[]","name":"targetedInterfaces_","type":"tuple[]","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"string[]","name":"artifacts","type":"string[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetSelectors","outputs":[{"internalType":"struct StdInvariant.FuzzSelector[]","name":"targetedSelectors_","type":"tuple[]","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"bytes4[]","name":"selectors","type":"bytes4[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetSenders","outputs":[{"internalType":"address[]","name":"targetedSenders_","type":"address[]"}]},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"string","name":"url","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"test_addProjectUrl"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"string[]","name":"urls","type":"string[]"}],"stateMutability":"nonpayable","type":"function","name":"test_addProjectUrlBatch"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32","name":"urlHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"test_addProjectUrlHash"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32[]","name":"urlHashes","type":"bytes32[]"}],"stateMutability":"nonpayable","type":"function","name":"test_addProjectUrlHashBatch"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"}],"stateMutability":"nonpayable","type":"function","name":"test_claimProject"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"string","name":"url","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_addProjectUrlAlreadyExists"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"string","name":"url","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_addProjectUrlAlreadyExistsHash"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"nonOwner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"string","name":"url","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_addProjectUrlByNonOwner"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32","name":"urlHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_addProjectUrlHashAlreadyExists"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"string","name":"url","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_addProjectUrlHashAlreadyExistsFull"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"nonOwner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32[]","name":"urlHashes","type":"bytes32[]"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_addProjectUrlHashBatchByNonOwner"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"nonOwner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32","name":"urlHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_addProjectUrlHashByNonOwner"},{"inputs":[{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_claimInvalidOwner"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"otherUser","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_claimProjectTwice"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"string","name":"url","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_removeNonexistentUrl"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32","name":"urlHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_removeNonexistentUrlHash"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"nonOwner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"string","name":"url","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_removeProjectUrlByNonOwner"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"nonOwner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32[]","name":"urlHashes","type":"bytes32[]"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_removeProjectUrlHashBatchByNonOwner"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"nonOwner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32","name":"urlHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_removeProjectUrlHashByNonOwner"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32[]","name":"urlHashes","type":"bytes32[]"},{"internalType":"uint256","name":"urlHashIdx","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_removeUrlHashWrongIndex"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"nonOwner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_transferByNonAdmin"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_transferInvalidOwner"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"wallet","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"string","name":"validUrl","type":"string"},{"internalType":"string","name":"invalidUrl","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"test_fail_validateAttestationWithInvalidUrl"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"string[]","name":"urls","type":"string[]"},{"internalType":"uint256","name":"urlIdx","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"test_removeProjectUrl"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32[]","name":"urlHashes","type":"bytes32[]"},{"internalType":"uint256","name":"urlHashIdx","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"test_removeProjectUrlHash"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32[]","name":"urlHashes","type":"bytes32[]"}],"stateMutability":"nonpayable","type":"function","name":"test_removeProjectUrlHashBatch"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32[]","name":"urlHashes","type":"bytes32[]"},{"internalType":"uint256[]","name":"urlIdxs","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function","name":"test_removeProjectUrlHashBatchWithInvalidUrlIdxs"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32[]","name":"urlHashes","type":"bytes32[]"},{"internalType":"uint256[]","name":"urlIdxs","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function","name":"test_removeProjectUrlHashBatchWithInvalidUrlIdxsOrder"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"newOwner","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"bytes32","name":"urlHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"test_transferProject"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"wallet","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"string[]","name":"urls","type":"string[]"},{"internalType":"uint256","name":"urlIdx","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"test_validateAttestationMultiple"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"wallet","type":"address"},{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"string","name":"url","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"test_validateAttestationSingle"}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"test/ImplicitProjectRegistry.t.sol":"ImplicitProjectRegistryTest"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/StdAssertions.sol":{"keccak256":"0xd8eec16034b53b52c90a3d720e121ce7d30d64cc57d854db7d817d5b382dda43","urls":["bzz-raw://612780755e32668c7e3b747d94d16c7291101144e084dd9ee563f071711e99e3","dweb:/ipfs/QmQgtFJXEmDtSHT7tZQTMbb6PCDpq5UDYFvrBnWk1Xo2SY"],"license":"MIT"},"lib/forge-std/src/StdChains.sol":{"keccak256":"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa","urls":["bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2","dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe"],"license":"MIT"},"lib/forge-std/src/StdCheats.sol":{"keccak256":"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746","urls":["bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41","dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK"],"license":"MIT"},"lib/forge-std/src/StdConstants.sol":{"keccak256":"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534","urls":["bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc","dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r"],"license":"MIT"},"lib/forge-std/src/StdError.sol":{"keccak256":"0xbf477b11a42d7611696956546bcfaa29317d1166bf65e402344599c05943fc77","urls":["bzz-raw://bc2e117d1135e030862b96a6526a43feb38d396cc79857f1fb696d4eff0e5fd6","dweb:/ipfs/QmdSuQ5RrQudTLsNmWXGEeVJX8gR5U9XPm6m4dwwuQnJrj"],"license":"MIT"},"lib/forge-std/src/StdInvariant.sol":{"keccak256":"0x4dab3021edfa9511bbdd80c48f060ef62eaf457f99eaf841f561fc2557d9a08d","urls":["bzz-raw://07668628673174cf8f27f8f4e1f862bab775013ec247eb34f698c5005f229391","dweb:/ipfs/QmPJsiiYwmCZXMsHmQv5tg8VF3CAhNdat7WnKLTWZZH2v5"],"license":"MIT"},"lib/forge-std/src/StdJson.sol":{"keccak256":"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500","urls":["bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974","dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3"],"license":"MIT"},"lib/forge-std/src/StdMath.sol":{"keccak256":"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2","urls":["bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92","dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/StdStyle.sol":{"keccak256":"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d","urls":["bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8","dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK"],"license":"MIT"},"lib/forge-std/src/StdToml.sol":{"keccak256":"0x58a72c765ed3f7ff6b105509689658795b8a3739b8931772a497155878381861","urls":["bzz-raw://b4a3746f4fabaeb980bd77d9e091d3904ee38a6c0e191bfa8ba6874c6f8558a3","dweb:/ipfs/QmUfFDMEn461FgGEXt5HicyGD54sc28sLaQ9JRWDMBKed8"],"license":"MIT"},"lib/forge-std/src/StdUtils.sol":{"keccak256":"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8","urls":["bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a","dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT"],"license":"MIT"},"lib/forge-std/src/Test.sol":{"keccak256":"0x3dda6083a83dfa3e8526e97bcc28e862ee2442dd58fe94d5c426d65b8e38f73c","urls":["bzz-raw://33f8c02e4dabdab86a6825125856446a8657eacd712318b51b7818e4a6f6e3f4","dweb:/ipfs/QmRKSjVnrk54yr8wTK2e6QxRjiuba2H8HJSKunHAkdo7RG"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"},"lib/forge-std/src/console2.sol":{"keccak256":"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f","urls":["bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d","dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ"],"license":"MIT"},"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"},"lib/forge-std/src/safeconsole.sol":{"keccak256":"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11","urls":["bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab","dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3"],"license":"MIT"},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol":{"keccak256":"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa","urls":["bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287","dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p"],"license":"MIT"},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol":{"keccak256":"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8","urls":["bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621","dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL"],"license":"MIT"},"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"},"src/helper/SignalsImplicitMode.sol":{"keccak256":"0x40d1c9354bca0b8275e0150f53d6e8d760a78ad62c39ed831ab46d2ee6c8ea65","urls":["bzz-raw://cf248253dc5a9c6612e7b3f5ce096c8c83d8f4b328de4889b58fb0fef0e3d8af","dweb:/ipfs/QmcDGY9KwbQQQ5maxhNsM6vWWn8xigcCXw3ihrHpKvad6L"],"license":"Apache-2.0"},"src/registry/IImplicitProjectRegistry.sol":{"keccak256":"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf","urls":["bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de","dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6"],"license":"Apache-2.0"},"src/registry/IImplicitProjectValidation.sol":{"keccak256":"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2","urls":["bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c","dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6"],"license":"Apache-2.0"},"src/registry/ImplicitProjectRegistry.sol":{"keccak256":"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d","urls":["bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa","dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8"],"license":"Apache-2.0"},"test/ImplicitProjectRegistry.t.sol":{"keccak256":"0x5ad8be4e1ad4d899592cdb015d30b30836d842e6a243e78fb222f66bb915e604","urls":["bzz-raw://1d9151ed53ec8cef0186e1a0b084f02ab68c0b4b076c91a148e6106cb0d9dfb9","dweb:/ipfs/QmcQdZ2iBc5wDvDxU4ARfW8HiideFbXsfZE9mi4jwBBWTv"],"license":"Apache-2.0"},"test/TestHelper.sol":{"keccak256":"0xba551fda365d1deef08d0e627d0233810141ea6dbfe770be3ebdb839a6af16a9","urls":["bzz-raw://fb9173a19cc248878fba10321bc83c5226d12eebacded8aad5c114dc39d52f15","dweb:/ipfs/QmTEH8EuNa8FcTEF4PiDPcmLYspxGEw3jbzEwVYFdxZWeD"],"license":"Apache-2.0"},"test/mock/SignalsImplicitModeMock.sol":{"keccak256":"0x15d4554d50385ac8d4529e6d37b74b4f8d7e9ba6051cf7d7614561b6319ff4ba","urls":["bzz-raw://165c71fb13a424c151fed7bb9d7880f7993cbd73f1cde117c148dc7f59216285","dweb:/ipfs/QmWv5YckRhNsGrusXobNodxYtyJqQK2S2VXtNfjwjahwwQ"],"license":"Apache-2.0"}},"version":1},"id":29} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/ImplicitProjectRegistry.t.sol/VmContractHelper42.json b/lib/signals-implicit-mode/out/ImplicitProjectRegistry.t.sol/VmContractHelper42.json deleted file mode 100644 index 1d3eeeb8ba..0000000000 --- a/lib/signals-implicit-mode/out/ImplicitProjectRegistry.t.sol/VmContractHelper42.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_value","type":"uint256","internalType":"uint256"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_args","type":"bytes","internalType":"bytes"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_args","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_args","type":"bytes","internalType":"bytes"},{"name":"_value","type":"uint256","internalType":"uint256"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_args","type":"bytes","internalType":"bytes"},{"name":"_value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"getCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"deployCode(string)":"9a8325a0","deployCode(string,bytes)":"29ce9dde","deployCode(string,bytes,bytes32)":"016155bf","deployCode(string,bytes,uint256)":"ff5d64e4","deployCode(string,bytes,uint256,bytes32)":"3aa773ea","deployCode(string,bytes32)":"17ab1d79","deployCode(string,uint256)":"0af6a701","deployCode(string,uint256,bytes32)":"002cb687","getCode(string)":"8d1cc925"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"_args\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"_args\",\"type\":\"bytes\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"_args\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"_args\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"}],\"name\":\"getCode\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"test/ImplicitProjectRegistry.t.sol\":\"VmContractHelper42\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/StdAssertions.sol\":{\"keccak256\":\"0xd8eec16034b53b52c90a3d720e121ce7d30d64cc57d854db7d817d5b382dda43\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://612780755e32668c7e3b747d94d16c7291101144e084dd9ee563f071711e99e3\",\"dweb:/ipfs/QmQgtFJXEmDtSHT7tZQTMbb6PCDpq5UDYFvrBnWk1Xo2SY\"]},\"lib/forge-std/src/StdChains.sol\":{\"keccak256\":\"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2\",\"dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe\"]},\"lib/forge-std/src/StdCheats.sol\":{\"keccak256\":\"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41\",\"dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK\"]},\"lib/forge-std/src/StdConstants.sol\":{\"keccak256\":\"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc\",\"dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r\"]},\"lib/forge-std/src/StdError.sol\":{\"keccak256\":\"0xbf477b11a42d7611696956546bcfaa29317d1166bf65e402344599c05943fc77\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://bc2e117d1135e030862b96a6526a43feb38d396cc79857f1fb696d4eff0e5fd6\",\"dweb:/ipfs/QmdSuQ5RrQudTLsNmWXGEeVJX8gR5U9XPm6m4dwwuQnJrj\"]},\"lib/forge-std/src/StdInvariant.sol\":{\"keccak256\":\"0x4dab3021edfa9511bbdd80c48f060ef62eaf457f99eaf841f561fc2557d9a08d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://07668628673174cf8f27f8f4e1f862bab775013ec247eb34f698c5005f229391\",\"dweb:/ipfs/QmPJsiiYwmCZXMsHmQv5tg8VF3CAhNdat7WnKLTWZZH2v5\"]},\"lib/forge-std/src/StdJson.sol\":{\"keccak256\":\"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974\",\"dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3\"]},\"lib/forge-std/src/StdMath.sol\":{\"keccak256\":\"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92\",\"dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/StdStyle.sol\":{\"keccak256\":\"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8\",\"dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK\"]},\"lib/forge-std/src/StdToml.sol\":{\"keccak256\":\"0x58a72c765ed3f7ff6b105509689658795b8a3739b8931772a497155878381861\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b4a3746f4fabaeb980bd77d9e091d3904ee38a6c0e191bfa8ba6874c6f8558a3\",\"dweb:/ipfs/QmUfFDMEn461FgGEXt5HicyGD54sc28sLaQ9JRWDMBKed8\"]},\"lib/forge-std/src/StdUtils.sol\":{\"keccak256\":\"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a\",\"dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT\"]},\"lib/forge-std/src/Test.sol\":{\"keccak256\":\"0x3dda6083a83dfa3e8526e97bcc28e862ee2442dd58fe94d5c426d65b8e38f73c\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://33f8c02e4dabdab86a6825125856446a8657eacd712318b51b7818e4a6f6e3f4\",\"dweb:/ipfs/QmRKSjVnrk54yr8wTK2e6QxRjiuba2H8HJSKunHAkdo7RG\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]},\"lib/forge-std/src/console2.sol\":{\"keccak256\":\"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d\",\"dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ\"]},\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]},\"lib/forge-std/src/safeconsole.sol\":{\"keccak256\":\"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab\",\"dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3\"]},\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol\":{\"keccak256\":\"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287\",\"dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p\"]},\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol\":{\"keccak256\":\"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621\",\"dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]},\"src/helper/SignalsImplicitMode.sol\":{\"keccak256\":\"0x40d1c9354bca0b8275e0150f53d6e8d760a78ad62c39ed831ab46d2ee6c8ea65\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://cf248253dc5a9c6612e7b3f5ce096c8c83d8f4b328de4889b58fb0fef0e3d8af\",\"dweb:/ipfs/QmcDGY9KwbQQQ5maxhNsM6vWWn8xigcCXw3ihrHpKvad6L\"]},\"src/registry/IImplicitProjectRegistry.sol\":{\"keccak256\":\"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de\",\"dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6\"]},\"src/registry/IImplicitProjectValidation.sol\":{\"keccak256\":\"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c\",\"dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6\"]},\"src/registry/ImplicitProjectRegistry.sol\":{\"keccak256\":\"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa\",\"dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8\"]},\"test/ImplicitProjectRegistry.t.sol\":{\"keccak256\":\"0xb9ba507ed539bd7bc307a56b39c3462f640eb810c25d3f56df65c46804a9f5a2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://321675990eefddd6e0fcf52d2c085c0407fb183110c47cdd7d4192e95f99a3e3\",\"dweb:/ipfs/Qmf9acchh7c6AUkn6Zra9aDYxf8Y6rk2fowqoYAYg5nsbb\"]},\"test/TestHelper.sol\":{\"keccak256\":\"0xba551fda365d1deef08d0e627d0233810141ea6dbfe770be3ebdb839a6af16a9\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://fb9173a19cc248878fba10321bc83c5226d12eebacded8aad5c114dc39d52f15\",\"dweb:/ipfs/QmTEH8EuNa8FcTEF4PiDPcmLYspxGEw3jbzEwVYFdxZWeD\"]},\"test/mock/SignalsImplicitModeMock.sol\":{\"keccak256\":\"0x15d4554d50385ac8d4529e6d37b74b4f8d7e9ba6051cf7d7614561b6319ff4ba\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://165c71fb13a424c151fed7bb9d7880f7993cbd73f1cde117c148dc7f59216285\",\"dweb:/ipfs/QmWv5YckRhNsGrusXobNodxYtyJqQK2S2VXtNfjwjahwwQ\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"uint256","name":"_value","type":"uint256"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes","name":"_args","type":"bytes"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"uint256","name":"_value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes","name":"_args","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes","name":"_args","type":"bytes"},{"internalType":"uint256","name":"_value","type":"uint256"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes","name":"_args","type":"bytes"},{"internalType":"uint256","name":"_value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"}],"stateMutability":"view","type":"function","name":"getCode","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"test/ImplicitProjectRegistry.t.sol":"VmContractHelper42"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/StdAssertions.sol":{"keccak256":"0xd8eec16034b53b52c90a3d720e121ce7d30d64cc57d854db7d817d5b382dda43","urls":["bzz-raw://612780755e32668c7e3b747d94d16c7291101144e084dd9ee563f071711e99e3","dweb:/ipfs/QmQgtFJXEmDtSHT7tZQTMbb6PCDpq5UDYFvrBnWk1Xo2SY"],"license":"MIT"},"lib/forge-std/src/StdChains.sol":{"keccak256":"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa","urls":["bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2","dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe"],"license":"MIT"},"lib/forge-std/src/StdCheats.sol":{"keccak256":"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746","urls":["bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41","dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK"],"license":"MIT"},"lib/forge-std/src/StdConstants.sol":{"keccak256":"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534","urls":["bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc","dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r"],"license":"MIT"},"lib/forge-std/src/StdError.sol":{"keccak256":"0xbf477b11a42d7611696956546bcfaa29317d1166bf65e402344599c05943fc77","urls":["bzz-raw://bc2e117d1135e030862b96a6526a43feb38d396cc79857f1fb696d4eff0e5fd6","dweb:/ipfs/QmdSuQ5RrQudTLsNmWXGEeVJX8gR5U9XPm6m4dwwuQnJrj"],"license":"MIT"},"lib/forge-std/src/StdInvariant.sol":{"keccak256":"0x4dab3021edfa9511bbdd80c48f060ef62eaf457f99eaf841f561fc2557d9a08d","urls":["bzz-raw://07668628673174cf8f27f8f4e1f862bab775013ec247eb34f698c5005f229391","dweb:/ipfs/QmPJsiiYwmCZXMsHmQv5tg8VF3CAhNdat7WnKLTWZZH2v5"],"license":"MIT"},"lib/forge-std/src/StdJson.sol":{"keccak256":"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500","urls":["bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974","dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3"],"license":"MIT"},"lib/forge-std/src/StdMath.sol":{"keccak256":"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2","urls":["bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92","dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/StdStyle.sol":{"keccak256":"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d","urls":["bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8","dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK"],"license":"MIT"},"lib/forge-std/src/StdToml.sol":{"keccak256":"0x58a72c765ed3f7ff6b105509689658795b8a3739b8931772a497155878381861","urls":["bzz-raw://b4a3746f4fabaeb980bd77d9e091d3904ee38a6c0e191bfa8ba6874c6f8558a3","dweb:/ipfs/QmUfFDMEn461FgGEXt5HicyGD54sc28sLaQ9JRWDMBKed8"],"license":"MIT"},"lib/forge-std/src/StdUtils.sol":{"keccak256":"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8","urls":["bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a","dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT"],"license":"MIT"},"lib/forge-std/src/Test.sol":{"keccak256":"0x3dda6083a83dfa3e8526e97bcc28e862ee2442dd58fe94d5c426d65b8e38f73c","urls":["bzz-raw://33f8c02e4dabdab86a6825125856446a8657eacd712318b51b7818e4a6f6e3f4","dweb:/ipfs/QmRKSjVnrk54yr8wTK2e6QxRjiuba2H8HJSKunHAkdo7RG"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"},"lib/forge-std/src/console2.sol":{"keccak256":"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f","urls":["bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d","dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ"],"license":"MIT"},"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"},"lib/forge-std/src/safeconsole.sol":{"keccak256":"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11","urls":["bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab","dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3"],"license":"MIT"},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol":{"keccak256":"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa","urls":["bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287","dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p"],"license":"MIT"},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol":{"keccak256":"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8","urls":["bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621","dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL"],"license":"MIT"},"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"},"src/helper/SignalsImplicitMode.sol":{"keccak256":"0x40d1c9354bca0b8275e0150f53d6e8d760a78ad62c39ed831ab46d2ee6c8ea65","urls":["bzz-raw://cf248253dc5a9c6612e7b3f5ce096c8c83d8f4b328de4889b58fb0fef0e3d8af","dweb:/ipfs/QmcDGY9KwbQQQ5maxhNsM6vWWn8xigcCXw3ihrHpKvad6L"],"license":"Apache-2.0"},"src/registry/IImplicitProjectRegistry.sol":{"keccak256":"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf","urls":["bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de","dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6"],"license":"Apache-2.0"},"src/registry/IImplicitProjectValidation.sol":{"keccak256":"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2","urls":["bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c","dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6"],"license":"Apache-2.0"},"src/registry/ImplicitProjectRegistry.sol":{"keccak256":"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d","urls":["bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa","dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8"],"license":"Apache-2.0"},"test/ImplicitProjectRegistry.t.sol":{"keccak256":"0xb9ba507ed539bd7bc307a56b39c3462f640eb810c25d3f56df65c46804a9f5a2","urls":["bzz-raw://321675990eefddd6e0fcf52d2c085c0407fb183110c47cdd7d4192e95f99a3e3","dweb:/ipfs/Qmf9acchh7c6AUkn6Zra9aDYxf8Y6rk2fowqoYAYg5nsbb"],"license":"Apache-2.0"},"test/TestHelper.sol":{"keccak256":"0xba551fda365d1deef08d0e627d0233810141ea6dbfe770be3ebdb839a6af16a9","urls":["bzz-raw://fb9173a19cc248878fba10321bc83c5226d12eebacded8aad5c114dc39d52f15","dweb:/ipfs/QmTEH8EuNa8FcTEF4PiDPcmLYspxGEw3jbzEwVYFdxZWeD"],"license":"Apache-2.0"},"test/mock/SignalsImplicitModeMock.sol":{"keccak256":"0x15d4554d50385ac8d4529e6d37b74b4f8d7e9ba6051cf7d7614561b6319ff4ba","urls":["bzz-raw://165c71fb13a424c151fed7bb9d7880f7993cbd73f1cde117c148dc7f59216285","dweb:/ipfs/QmWv5YckRhNsGrusXobNodxYtyJqQK2S2VXtNfjwjahwwQ"],"license":"Apache-2.0"}},"version":1},"id":33} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/LibBytes.sol/LibBytes.json b/lib/signals-implicit-mode/out/LibBytes.sol/LibBytes.json deleted file mode 100644 index 39fe2e663d..0000000000 --- a/lib/signals-implicit-mode/out/LibBytes.sol/LibBytes.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x60566050600b82828239805160001a6073146043577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212205fe2b79b579b9bc8482f3cf44128b1c905144840e77c2361f2d7543bd090d89e64736f6c634300081c0033","sourceMap":"432:3576:24:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212205fe2b79b579b9bc8482f3cf44128b1c905144840e77c2361f2d7543bd090d89e64736f6c634300081c0033","sourceMap":"432:3576:24:-:0;;;;;;;;","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"author\":\"Agustin Aguilar (aa@horizon.io), Michael Standen (mstan@horizon.io)\",\"details\":\"These functions do not check if the input index is within the bounds of the data array.Reading out of bounds may return dirty values.\",\"kind\":\"dev\",\"methods\":{},\"title\":\"Library for reading data from bytes arrays\",\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"notice\":\"This library contains functions for reading data from bytes arrays.\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/sequence-v3/src/utils/LibBytes.sol\":\"LibBytes\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/sequence-v3/src/utils/LibBytes.sol":"LibBytes"},"evmVersion":"paris","libraries":{}},"sources":{"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"}},"version":1},"id":24} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/Payload.sol/Payload.json b/lib/signals-implicit-mode/out/Payload.sol/Payload.json deleted file mode 100644 index 281a169292..0000000000 --- a/lib/signals-implicit-mode/out/Payload.sol/Payload.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"BEHAVIOR_ABORT_ON_ERROR","inputs":[],"outputs":[{"name":"","type":"uint8","internalType":"uint8"}],"stateMutability":"view"},{"type":"function","name":"BEHAVIOR_IGNORE_ERROR","inputs":[],"outputs":[{"name":"","type":"uint8","internalType":"uint8"}],"stateMutability":"view"},{"type":"function","name":"BEHAVIOR_REVERT_ON_ERROR","inputs":[],"outputs":[{"name":"","type":"uint8","internalType":"uint8"}],"stateMutability":"view"},{"type":"function","name":"KIND_CONFIG_UPDATE","inputs":[],"outputs":[{"name":"","type":"uint8","internalType":"uint8"}],"stateMutability":"view"},{"type":"function","name":"KIND_DIGEST","inputs":[],"outputs":[{"name":"","type":"uint8","internalType":"uint8"}],"stateMutability":"view"},{"type":"function","name":"KIND_MESSAGE","inputs":[],"outputs":[{"name":"","type":"uint8","internalType":"uint8"}],"stateMutability":"view"},{"type":"function","name":"KIND_TRANSACTIONS","inputs":[],"outputs":[{"name":"","type":"uint8","internalType":"uint8"}],"stateMutability":"view"},{"type":"error","name":"InvalidKind","inputs":[{"name":"kind","type":"uint8","internalType":"uint8"}]}],"bytecode":{"object":"0x6101ee610052600b82828239805160001a6073146045577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600436106100875760003560e01c8063420b0c2511610065578063420b0c25146100e65780634a7d2aa0146101045780634e5f571514610122578063b570180a1461014057610087565b80630739d59a1461008c578063075a3d2d146100aa5780633d5c1f9b146100c8575b600080fd5b61009461015e565b6040516100a1919061019d565b60405180910390f35b6100b2610163565b6040516100bf919061019d565b60405180910390f35b6100d0610168565b6040516100dd919061019d565b60405180910390f35b6100ee61016d565b6040516100fb919061019d565b60405180910390f35b61010c610172565b604051610119919061019d565b60405180910390f35b61012a610177565b604051610137919061019d565b60405180910390f35b61014861017c565b604051610155919061019d565b60405180910390f35b600281565b600081565b600181565b600281565b600081565b600181565b600381565b600060ff82169050919050565b61019781610181565b82525050565b60006020820190506101b2600083018461018e565b9291505056fea2646970667358221220a54e1df6658c990037662b61a53a59b00946fb4dc476927c3552ce2eb8e2d02f64736f6c634300081c0033","sourceMap":"275:9818:23:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x73000000000000000000000000000000000000000030146080604052600436106100875760003560e01c8063420b0c2511610065578063420b0c25146100e65780634a7d2aa0146101045780634e5f571514610122578063b570180a1461014057610087565b80630739d59a1461008c578063075a3d2d146100aa5780633d5c1f9b146100c8575b600080fd5b61009461015e565b6040516100a1919061019d565b60405180910390f35b6100b2610163565b6040516100bf919061019d565b60405180910390f35b6100d0610168565b6040516100dd919061019d565b60405180910390f35b6100ee61016d565b6040516100fb919061019d565b60405180910390f35b61010c610172565b604051610119919061019d565b60405180910390f35b61012a610177565b604051610137919061019d565b60405180910390f35b61014861017c565b604051610155919061019d565b60405180910390f35b600281565b600081565b600181565b600281565b600081565b600181565b600381565b600060ff82169050919050565b61019781610181565b82525050565b60006020820190506101b2600083018461018e565b9291505056fea2646970667358221220a54e1df6658c990037662b61a53a59b00946fb4dc476927c3552ce2eb8e2d02f64736f6c634300081c0033","sourceMap":"275:9818:23:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2439:47;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2279:46;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2358:41;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2819:52;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2611:50;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2714:53;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2520:40;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2439:47;2482:4;2439:47;:::o;2279:46::-;2321:4;2279:46;:::o;2358:41::-;2395:4;2358:41;:::o;2819:52::-;2867:4;2819:52;:::o;2611:50::-;2657:4;2611:50;:::o;2714:53::-;2763:4;2714:53;:::o;2520:40::-;2556:4;2520:40;:::o;7:86:33:-;42:7;82:4;75:5;71:16;60:27;;7:86;;;:::o;99:120::-;190:22;206:5;190:22;:::i;:::-;185:3;178:35;99:120;;:::o;225:230::-;322:4;360:2;349:9;345:18;337:26;;373:75;445:1;434:9;430:17;421:6;373:75;:::i;:::-;225:230;;;;:::o","linkReferences":{}},"methodIdentifiers":{"BEHAVIOR_ABORT_ON_ERROR()":"420b0c25","BEHAVIOR_IGNORE_ERROR()":"4a7d2aa0","BEHAVIOR_REVERT_ON_ERROR()":"4e5f5715","KIND_CONFIG_UPDATE()":"0739d59a","KIND_DIGEST()":"b570180a","KIND_MESSAGE()":"3d5c1f9b","KIND_TRANSACTIONS()":"075a3d2d"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"kind\",\"type\":\"uint8\"}],\"name\":\"InvalidKind\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"BEHAVIOR_ABORT_ON_ERROR\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"BEHAVIOR_IGNORE_ERROR\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"BEHAVIOR_REVERT_ON_ERROR\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"KIND_CONFIG_UPDATE\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"KIND_DIGEST\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"KIND_MESSAGE\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"KIND_TRANSACTIONS\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"author\":\"Agustin Aguilar, Michael Standen, William Hua\",\"kind\":\"dev\",\"methods\":{},\"stateVariables\":{\"CALLS_TYPEHASH\":{\"details\":\"keccak256(\\\"Calls(Call[] calls,uint256 space,uint256 nonce,address[] wallets)Call(address to,uint256 value,bytes data,uint256 gasLimit,bool delegateCall,bool onlyFallback,uint256 behaviorOnError)\\\")\"},\"CALL_TYPEHASH\":{\"details\":\"keccak256(\\\"Call(address to,uint256 value,bytes data,uint256 gasLimit,bool delegateCall,bool onlyFallback,uint256 behaviorOnError)\\\")\"},\"CONFIG_UPDATE_TYPEHASH\":{\"details\":\"keccak256(\\\"ConfigUpdate(bytes32 imageHash,address[] wallets)\\\")\"},\"EIP712_DOMAIN_NAME_SEQUENCE\":{\"details\":\"keccak256(\\\"Sequence Wallet\\\")\"},\"EIP712_DOMAIN_TYPEHASH\":{\"details\":\"keccak256(\\\"EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)\\\")\"},\"EIP712_DOMAIN_VERSION_SEQUENCE\":{\"details\":\"keccak256(\\\"3\\\")\"},\"MESSAGE_TYPEHASH\":{\"details\":\"keccak256(\\\"Message(bytes message,address[] wallets)\\\")\"}},\"title\":\"Payload\",\"version\":1},\"userdoc\":{\"errors\":{\"InvalidKind(uint8)\":[{\"notice\":\"Error thrown when the kind is invalid\"}]},\"kind\":\"user\",\"methods\":{\"BEHAVIOR_ABORT_ON_ERROR()\":{\"notice\":\"Behavior on error: abort on error\"},\"BEHAVIOR_IGNORE_ERROR()\":{\"notice\":\"Behavior on error: ignore error\"},\"BEHAVIOR_REVERT_ON_ERROR()\":{\"notice\":\"Behavior on error: revert on error\"},\"KIND_CONFIG_UPDATE()\":{\"notice\":\"Kind of config update\"},\"KIND_DIGEST()\":{\"notice\":\"Kind of message\"},\"KIND_MESSAGE()\":{\"notice\":\"Kind of digest\"},\"KIND_TRANSACTIONS()\":{\"notice\":\"Kind of transaction\"}},\"notice\":\"Library for encoding and decoding payloads\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/sequence-v3/src/modules/Payload.sol\":\"Payload\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"uint8","name":"kind","type":"uint8"}],"type":"error","name":"InvalidKind"},{"inputs":[],"stateMutability":"view","type":"function","name":"BEHAVIOR_ABORT_ON_ERROR","outputs":[{"internalType":"uint8","name":"","type":"uint8"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"BEHAVIOR_IGNORE_ERROR","outputs":[{"internalType":"uint8","name":"","type":"uint8"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"BEHAVIOR_REVERT_ON_ERROR","outputs":[{"internalType":"uint8","name":"","type":"uint8"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"KIND_CONFIG_UPDATE","outputs":[{"internalType":"uint8","name":"","type":"uint8"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"KIND_DIGEST","outputs":[{"internalType":"uint8","name":"","type":"uint8"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"KIND_MESSAGE","outputs":[{"internalType":"uint8","name":"","type":"uint8"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"KIND_TRANSACTIONS","outputs":[{"internalType":"uint8","name":"","type":"uint8"}]}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{"BEHAVIOR_ABORT_ON_ERROR()":{"notice":"Behavior on error: abort on error"},"BEHAVIOR_IGNORE_ERROR()":{"notice":"Behavior on error: ignore error"},"BEHAVIOR_REVERT_ON_ERROR()":{"notice":"Behavior on error: revert on error"},"KIND_CONFIG_UPDATE()":{"notice":"Kind of config update"},"KIND_DIGEST()":{"notice":"Kind of message"},"KIND_MESSAGE()":{"notice":"Kind of digest"},"KIND_TRANSACTIONS()":{"notice":"Kind of transaction"}},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/sequence-v3/src/modules/Payload.sol":"Payload"},"evmVersion":"paris","libraries":{}},"sources":{"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"}},"version":1},"id":23} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/Script.sol/Script.json b/lib/signals-implicit-mode/out/Script.sol/Script.json deleted file mode 100644 index bf062643aa..0000000000 --- a/lib/signals-implicit-mode/out/Script.sol/Script.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"IS_SCRIPT","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"IS_SCRIPT()":"f8ccbf47"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"name\":\"IS_SCRIPT\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/Script.sol\":\"Script\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/Script.sol\":{\"keccak256\":\"0xc942e27c7baae499beb01afbbae99f24d42af9a6e4aae675bc6901b704aa8e9b\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://0456008adf68947247f358b62863af4a8e349549d2260f2ff9569ff0e3cf5c98\",\"dweb:/ipfs/QmdviSUj2i7o3TPN5vd2xocqGMFVqjUzaiJTZRYyPxyHPx\"]},\"lib/forge-std/src/StdChains.sol\":{\"keccak256\":\"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2\",\"dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe\"]},\"lib/forge-std/src/StdCheats.sol\":{\"keccak256\":\"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41\",\"dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK\"]},\"lib/forge-std/src/StdConstants.sol\":{\"keccak256\":\"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc\",\"dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r\"]},\"lib/forge-std/src/StdJson.sol\":{\"keccak256\":\"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974\",\"dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3\"]},\"lib/forge-std/src/StdMath.sol\":{\"keccak256\":\"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92\",\"dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/StdStyle.sol\":{\"keccak256\":\"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8\",\"dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK\"]},\"lib/forge-std/src/StdUtils.sol\":{\"keccak256\":\"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a\",\"dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]},\"lib/forge-std/src/console2.sol\":{\"keccak256\":\"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d\",\"dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ\"]},\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]},\"lib/forge-std/src/safeconsole.sol\":{\"keccak256\":\"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab\",\"dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[],"stateMutability":"view","type":"function","name":"IS_SCRIPT","outputs":[{"internalType":"bool","name":"","type":"bool"}]}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/Script.sol":"Script"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/Script.sol":{"keccak256":"0xc942e27c7baae499beb01afbbae99f24d42af9a6e4aae675bc6901b704aa8e9b","urls":["bzz-raw://0456008adf68947247f358b62863af4a8e349549d2260f2ff9569ff0e3cf5c98","dweb:/ipfs/QmdviSUj2i7o3TPN5vd2xocqGMFVqjUzaiJTZRYyPxyHPx"],"license":"MIT"},"lib/forge-std/src/StdChains.sol":{"keccak256":"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa","urls":["bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2","dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe"],"license":"MIT"},"lib/forge-std/src/StdCheats.sol":{"keccak256":"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746","urls":["bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41","dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK"],"license":"MIT"},"lib/forge-std/src/StdConstants.sol":{"keccak256":"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534","urls":["bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc","dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r"],"license":"MIT"},"lib/forge-std/src/StdJson.sol":{"keccak256":"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500","urls":["bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974","dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3"],"license":"MIT"},"lib/forge-std/src/StdMath.sol":{"keccak256":"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2","urls":["bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92","dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/StdStyle.sol":{"keccak256":"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d","urls":["bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8","dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK"],"license":"MIT"},"lib/forge-std/src/StdUtils.sol":{"keccak256":"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8","urls":["bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a","dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"},"lib/forge-std/src/console2.sol":{"keccak256":"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f","urls":["bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d","dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ"],"license":"MIT"},"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"},"lib/forge-std/src/safeconsole.sol":{"keccak256":"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11","urls":["bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab","dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3"],"license":"MIT"}},"version":1},"id":1} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/SignalsImplicitMode.sol/SignalsImplicitMode.json b/lib/signals-implicit-mode/out/SignalsImplicitMode.sol/SignalsImplicitMode.json deleted file mode 100644 index 3ae353a300..0000000000 --- a/lib/signals-implicit-mode/out/SignalsImplicitMode.sol/SignalsImplicitMode.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"acceptImplicitRequest","inputs":[{"name":"wallet","type":"address","internalType":"address"},{"name":"attestation","type":"tuple","internalType":"struct Attestation","components":[{"name":"approvedSigner","type":"address","internalType":"address"},{"name":"identityType","type":"bytes4","internalType":"bytes4"},{"name":"issuerHash","type":"bytes32","internalType":"bytes32"},{"name":"audienceHash","type":"bytes32","internalType":"bytes32"},{"name":"applicationData","type":"bytes","internalType":"bytes"},{"name":"authData","type":"tuple","internalType":"struct AuthData","components":[{"name":"redirectUrl","type":"string","internalType":"string"},{"name":"issuedAt","type":"uint64","internalType":"uint64"}]}]},{"name":"call","type":"tuple","internalType":"struct Payload.Call","components":[{"name":"to","type":"address","internalType":"address"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"gasLimit","type":"uint256","internalType":"uint256"},{"name":"delegateCall","type":"bool","internalType":"bool"},{"name":"onlyFallback","type":"bool","internalType":"bool"},{"name":"behaviorOnError","type":"uint256","internalType":"uint256"}]}],"outputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"supportsInterface","inputs":[{"name":"interfaceId","type":"bytes4","internalType":"bytes4"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))":"9d043a66","supportsInterface(bytes4)":"01ffc9a7"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"wallet\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"approvedSigner\",\"type\":\"address\"},{\"internalType\":\"bytes4\",\"name\":\"identityType\",\"type\":\"bytes4\"},{\"internalType\":\"bytes32\",\"name\":\"issuerHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"audienceHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"applicationData\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"string\",\"name\":\"redirectUrl\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"issuedAt\",\"type\":\"uint64\"}],\"internalType\":\"struct AuthData\",\"name\":\"authData\",\"type\":\"tuple\"}],\"internalType\":\"struct Attestation\",\"name\":\"attestation\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"delegateCall\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"onlyFallback\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"behaviorOnError\",\"type\":\"uint256\"}],\"internalType\":\"struct Payload.Call\",\"name\":\"call\",\"type\":\"tuple\"}],\"name\":\"acceptImplicitRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"author\":\"Michael Standen\",\"kind\":\"dev\",\"methods\":{\"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))\":{\"params\":{\"attestation\":\"The attestation data\",\"call\":\"The call to validate\",\"wallet\":\"The wallet's address\"},\"returns\":{\"_0\":\"The hash of the implicit request if valid\"}},\"supportsInterface(bytes4)\":{\"details\":\"Returns true if this contract implements the interface defined by `interfaceId`. See the corresponding https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[ERC section] to learn more about how these ids are created. This function call must use less than 30 000 gas.\"}},\"title\":\"SignalsImplicitMode\",\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))\":{\"notice\":\"Determines if an implicit request is valid\"}},\"notice\":\"Base contract for implicit mode validation by project\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"src/helper/SignalsImplicitMode.sol\":\"SignalsImplicitMode\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol\":{\"keccak256\":\"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287\",\"dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p\"]},\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol\":{\"keccak256\":\"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621\",\"dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]},\"src/helper/SignalsImplicitMode.sol\":{\"keccak256\":\"0x40d1c9354bca0b8275e0150f53d6e8d760a78ad62c39ed831ab46d2ee6c8ea65\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://cf248253dc5a9c6612e7b3f5ce096c8c83d8f4b328de4889b58fb0fef0e3d8af\",\"dweb:/ipfs/QmcDGY9KwbQQQ5maxhNsM6vWWn8xigcCXw3ihrHpKvad6L\"]},\"src/registry/IImplicitProjectValidation.sol\":{\"keccak256\":\"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c\",\"dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"struct Attestation","name":"attestation","type":"tuple","components":[{"internalType":"address","name":"approvedSigner","type":"address"},{"internalType":"bytes4","name":"identityType","type":"bytes4"},{"internalType":"bytes32","name":"issuerHash","type":"bytes32"},{"internalType":"bytes32","name":"audienceHash","type":"bytes32"},{"internalType":"bytes","name":"applicationData","type":"bytes"},{"internalType":"struct AuthData","name":"authData","type":"tuple","components":[{"internalType":"string","name":"redirectUrl","type":"string"},{"internalType":"uint64","name":"issuedAt","type":"uint64"}]}]},{"internalType":"struct Payload.Call","name":"call","type":"tuple","components":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"bool","name":"delegateCall","type":"bool"},{"internalType":"bool","name":"onlyFallback","type":"bool"},{"internalType":"uint256","name":"behaviorOnError","type":"uint256"}]}],"stateMutability":"view","type":"function","name":"acceptImplicitRequest","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}]},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"stateMutability":"view","type":"function","name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}]}],"devdoc":{"kind":"dev","methods":{"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))":{"params":{"attestation":"The attestation data","call":"The call to validate","wallet":"The wallet's address"},"returns":{"_0":"The hash of the implicit request if valid"}},"supportsInterface(bytes4)":{"details":"Returns true if this contract implements the interface defined by `interfaceId`. See the corresponding https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[ERC section] to learn more about how these ids are created. This function call must use less than 30 000 gas."}},"version":1},"userdoc":{"kind":"user","methods":{"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))":{"notice":"Determines if an implicit request is valid"}},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"src/helper/SignalsImplicitMode.sol":"SignalsImplicitMode"},"evmVersion":"paris","libraries":{}},"sources":{"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol":{"keccak256":"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa","urls":["bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287","dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p"],"license":"MIT"},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol":{"keccak256":"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8","urls":["bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621","dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL"],"license":"MIT"},"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"},"src/helper/SignalsImplicitMode.sol":{"keccak256":"0x40d1c9354bca0b8275e0150f53d6e8d760a78ad62c39ed831ab46d2ee6c8ea65","urls":["bzz-raw://cf248253dc5a9c6612e7b3f5ce096c8c83d8f4b328de4889b58fb0fef0e3d8af","dweb:/ipfs/QmcDGY9KwbQQQ5maxhNsM6vWWn8xigcCXw3ihrHpKvad6L"],"license":"Apache-2.0"},"src/registry/IImplicitProjectValidation.sol":{"keccak256":"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2","urls":["bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c","dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6"],"license":"Apache-2.0"}},"version":1},"id":25} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/SignalsImplicitMode.t.sol/SignalsImplicitModeTest.json b/lib/signals-implicit-mode/out/SignalsImplicitMode.t.sol/SignalsImplicitModeTest.json deleted file mode 100644 index 1fbcd13166..0000000000 --- a/lib/signals-implicit-mode/out/SignalsImplicitMode.t.sol/SignalsImplicitModeTest.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"IS_TEST","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"excludeArtifacts","inputs":[],"outputs":[{"name":"excludedArtifacts_","type":"string[]","internalType":"string[]"}],"stateMutability":"view"},{"type":"function","name":"excludeContracts","inputs":[],"outputs":[{"name":"excludedContracts_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"excludeSelectors","inputs":[],"outputs":[{"name":"excludedSelectors_","type":"tuple[]","internalType":"struct StdInvariant.FuzzSelector[]","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"selectors","type":"bytes4[]","internalType":"bytes4[]"}]}],"stateMutability":"view"},{"type":"function","name":"excludeSenders","inputs":[],"outputs":[{"name":"excludedSenders_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"failed","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"registry","inputs":[],"outputs":[{"name":"","type":"address","internalType":"contract ImplicitProjectRegistry"}],"stateMutability":"view"},{"type":"function","name":"setUp","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"signalsImplicitMode","inputs":[],"outputs":[{"name":"","type":"address","internalType":"contract SignalsImplicitModeMock"}],"stateMutability":"view"},{"type":"function","name":"targetArtifactSelectors","inputs":[],"outputs":[{"name":"targetedArtifactSelectors_","type":"tuple[]","internalType":"struct StdInvariant.FuzzArtifactSelector[]","components":[{"name":"artifact","type":"string","internalType":"string"},{"name":"selectors","type":"bytes4[]","internalType":"bytes4[]"}]}],"stateMutability":"view"},{"type":"function","name":"targetArtifacts","inputs":[],"outputs":[{"name":"targetedArtifacts_","type":"string[]","internalType":"string[]"}],"stateMutability":"view"},{"type":"function","name":"targetContracts","inputs":[],"outputs":[{"name":"targetedContracts_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"targetInterfaces","inputs":[],"outputs":[{"name":"targetedInterfaces_","type":"tuple[]","internalType":"struct StdInvariant.FuzzInterface[]","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"artifacts","type":"string[]","internalType":"string[]"}]}],"stateMutability":"view"},{"type":"function","name":"targetSelectors","inputs":[],"outputs":[{"name":"targetedSelectors_","type":"tuple[]","internalType":"struct StdInvariant.FuzzSelector[]","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"selectors","type":"bytes4[]","internalType":"bytes4[]"}]}],"stateMutability":"view"},{"type":"function","name":"targetSenders","inputs":[],"outputs":[{"name":"targetedSenders_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"test_acceptsValidUrl","inputs":[{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"owner","type":"address","internalType":"address"},{"name":"url","type":"string","internalType":"string"},{"name":"attestation","type":"tuple","internalType":"struct Attestation","components":[{"name":"approvedSigner","type":"address","internalType":"address"},{"name":"identityType","type":"bytes4","internalType":"bytes4"},{"name":"issuerHash","type":"bytes32","internalType":"bytes32"},{"name":"audienceHash","type":"bytes32","internalType":"bytes32"},{"name":"applicationData","type":"bytes","internalType":"bytes"},{"name":"authData","type":"tuple","internalType":"struct AuthData","components":[{"name":"redirectUrl","type":"string","internalType":"string"},{"name":"issuedAt","type":"uint64","internalType":"uint64"}]}]},{"name":"wallet","type":"address","internalType":"address"},{"name":"call","type":"tuple","internalType":"struct Payload.Call","components":[{"name":"to","type":"address","internalType":"address"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"gasLimit","type":"uint256","internalType":"uint256"},{"name":"delegateCall","type":"bool","internalType":"bool"},{"name":"onlyFallback","type":"bool","internalType":"bool"},{"name":"behaviorOnError","type":"uint256","internalType":"uint256"}]}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_acceptsValidUrlFromMultiple","inputs":[{"name":"projectIdUpper","type":"bytes12","internalType":"bytes12"},{"name":"owner","type":"address","internalType":"address"},{"name":"urls","type":"string[]","internalType":"string[]"},{"name":"urlIdx","type":"uint256","internalType":"uint256"},{"name":"attestation","type":"tuple","internalType":"struct Attestation","components":[{"name":"approvedSigner","type":"address","internalType":"address"},{"name":"identityType","type":"bytes4","internalType":"bytes4"},{"name":"issuerHash","type":"bytes32","internalType":"bytes32"},{"name":"audienceHash","type":"bytes32","internalType":"bytes32"},{"name":"applicationData","type":"bytes","internalType":"bytes"},{"name":"authData","type":"tuple","internalType":"struct AuthData","components":[{"name":"redirectUrl","type":"string","internalType":"string"},{"name":"issuedAt","type":"uint64","internalType":"uint64"}]}]},{"name":"wallet","type":"address","internalType":"address"},{"name":"call","type":"tuple","internalType":"struct Payload.Call","components":[{"name":"to","type":"address","internalType":"address"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"gasLimit","type":"uint256","internalType":"uint256"},{"name":"delegateCall","type":"bool","internalType":"bool"},{"name":"onlyFallback","type":"bool","internalType":"bool"},{"name":"behaviorOnError","type":"uint256","internalType":"uint256"}]}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_rejectsInvalidUrl","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"},{"name":"url","type":"string","internalType":"string"},{"name":"attestation","type":"tuple","internalType":"struct Attestation","components":[{"name":"approvedSigner","type":"address","internalType":"address"},{"name":"identityType","type":"bytes4","internalType":"bytes4"},{"name":"issuerHash","type":"bytes32","internalType":"bytes32"},{"name":"audienceHash","type":"bytes32","internalType":"bytes32"},{"name":"applicationData","type":"bytes","internalType":"bytes"},{"name":"authData","type":"tuple","internalType":"struct AuthData","components":[{"name":"redirectUrl","type":"string","internalType":"string"},{"name":"issuedAt","type":"uint64","internalType":"uint64"}]}]},{"name":"wallet","type":"address","internalType":"address"},{"name":"call","type":"tuple","internalType":"struct Payload.Call","components":[{"name":"to","type":"address","internalType":"address"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"gasLimit","type":"uint256","internalType":"uint256"},{"name":"delegateCall","type":"bool","internalType":"bool"},{"name":"onlyFallback","type":"bool","internalType":"bool"},{"name":"behaviorOnError","type":"uint256","internalType":"uint256"}]}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"test_supportsInterface","inputs":[{"name":"projectId","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"event","name":"log","inputs":[{"name":"","type":"string","indexed":false,"internalType":"string"}],"anonymous":false},{"type":"event","name":"log_address","inputs":[{"name":"","type":"address","indexed":false,"internalType":"address"}],"anonymous":false},{"type":"event","name":"log_array","inputs":[{"name":"val","type":"uint256[]","indexed":false,"internalType":"uint256[]"}],"anonymous":false},{"type":"event","name":"log_array","inputs":[{"name":"val","type":"int256[]","indexed":false,"internalType":"int256[]"}],"anonymous":false},{"type":"event","name":"log_array","inputs":[{"name":"val","type":"address[]","indexed":false,"internalType":"address[]"}],"anonymous":false},{"type":"event","name":"log_bytes","inputs":[{"name":"","type":"bytes","indexed":false,"internalType":"bytes"}],"anonymous":false},{"type":"event","name":"log_bytes32","inputs":[{"name":"","type":"bytes32","indexed":false,"internalType":"bytes32"}],"anonymous":false},{"type":"event","name":"log_int","inputs":[{"name":"","type":"int256","indexed":false,"internalType":"int256"}],"anonymous":false},{"type":"event","name":"log_named_address","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"address","indexed":false,"internalType":"address"}],"anonymous":false},{"type":"event","name":"log_named_array","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"uint256[]","indexed":false,"internalType":"uint256[]"}],"anonymous":false},{"type":"event","name":"log_named_array","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"int256[]","indexed":false,"internalType":"int256[]"}],"anonymous":false},{"type":"event","name":"log_named_array","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"address[]","indexed":false,"internalType":"address[]"}],"anonymous":false},{"type":"event","name":"log_named_bytes","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"bytes","indexed":false,"internalType":"bytes"}],"anonymous":false},{"type":"event","name":"log_named_bytes32","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"bytes32","indexed":false,"internalType":"bytes32"}],"anonymous":false},{"type":"event","name":"log_named_decimal_int","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"int256","indexed":false,"internalType":"int256"},{"name":"decimals","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"log_named_decimal_uint","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"uint256","indexed":false,"internalType":"uint256"},{"name":"decimals","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"log_named_int","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"int256","indexed":false,"internalType":"int256"}],"anonymous":false},{"type":"event","name":"log_named_string","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"string","indexed":false,"internalType":"string"}],"anonymous":false},{"type":"event","name":"log_named_uint","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"log_string","inputs":[{"name":"","type":"string","indexed":false,"internalType":"string"}],"anonymous":false},{"type":"event","name":"log_uint","inputs":[{"name":"","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"logs","inputs":[{"name":"","type":"bytes","indexed":false,"internalType":"bytes"}],"anonymous":false}],"bytecode":{"object":"0x60806040526001600c60006101000a81548160ff0219169083151502179055506001601f60006101000a81548160ff021916908315150217905550348015604557600080fd5b50616bb5806100556000396000f3fe608060405234801561001057600080fd5b50600436106101215760003560e01c80637b103999116100ad578063b0464fdc11610071578063b0464fdc146102ae578063b5508aa9146102cc578063ba414fa6146102ea578063e20c9f7114610308578063fa7626d41461032657610121565b80637b1039991461021c57806385226c811461023a57806390110f2d14610258578063916a17c614610274578063a401b02b1461029257610121565b80633e5e3c23116100f45780633e5e3c23146101885780633f7286f4146101a657806350932724146101c457806366d9a9a0146101e05780637aa3488f146101fe57610121565b80630a9254e4146101265780631ed7831c146101305780632ade38801461014e5780632f2377181461016c575b600080fd5b61012e610344565b005b6101386103af565b604051610145919061240f565b60405180910390f35b61015661043d565b6040516101639190612682565b60405180910390f35b61018660048036038101906101819190612c6c565b6105cb565b005b610190610a11565b60405161019d919061240f565b60405180910390f35b6101ae610a9f565b6040516101bb919061240f565b60405180910390f35b6101de60048036038101906101d99190612d4d565b610b2d565b005b6101e8610d63565b6040516101f59190612fe0565b60405180910390f35b610206610eee565b6040516102139190613061565b60405180910390f35b610224610f14565b604051610231919061309d565b60405180910390f35b610242610f3a565b60405161024f919061313e565b60405180910390f35b610272600480360381019061026d9190613246565b611013565b005b61027c61155e565b604051610289919061343b565b60405180910390f35b6102ac60048036038101906102a7919061345d565b6116ad565b005b6102b66118d4565b6040516102c3919061343b565b60405180910390f35b6102d4611a23565b6040516102e1919061313e565b60405180910390f35b6102f2611afc565b6040516102ff9190613499565b60405180910390f35b610310611c0a565b60405161031d919061240f565b60405180910390f35b61032e611c98565b60405161033b9190613499565b60405180910390f35b604051610350906122fb565b604051809103906000f08015801561036c573d6000803e3d6000fd5b50602060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b6060601680548060200260200160405190810160405280929190818152602001828054801561043357602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190600101908083116103e9575b5050505050905090565b6060601e805480602002602001604051908101604052809291908181526020016000905b828210156105c257838290600052602060002090600202016040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200160018201805480602002602001604051908101604052809291908181526020016000905b828210156105ab57838290600052602060002001805461051e906134e3565b80601f016020809104026020016040519081016040528092919081815260200182805461054a906134e3565b80156105975780601f1061056c57610100808354040283529160200191610597565b820191906000526020600020905b81548152906001019060200180831161057a57829003601f168201915b5050505050815260200190600101906104ff565b505050508152505081526020019060010190610461565b50505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016106489190613499565b60006040518083038186803b15801561066057600080fd5b505afa158015610674573d6000803e3d6000fd5b50505050838360a0015160000181905250737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56866040518263ffffffff1660e01b81526004016106d29190613523565b600060405180830381600087803b1580156106ec57600080fd5b505af1158015610700573d6000803e3d6000fd5b505050506000602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018886040518263ffffffff1660e01b8152600401610761919061354d565b6020604051808303816000875af1158015610780573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107a4919061357d565b9050602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82876040518363ffffffff1660e01b8152600401610803929190613603565b600060405180830381600087803b15801561081d57600080fd5b505af1158015610831573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561089157600080fd5b505af11580156108a5573d6000803e3d6000fd5b50505050602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16816040516108d990612308565b6108e4929190613633565b604051809103906000f080158015610900573d6000803e3d6000fd5b50601f60016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060006109568486611cab90919063ffffffff16565b90506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639d043a668688876040518463ffffffff1660e01b81526004016109b993929190613856565b602060405180830381865afa1580156109d6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109fa919061357d565b9050610a068183611d0e565b505050505050505050565b60606018805480602002602001604051908101604052809291908181526020018280548015610a9557602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311610a4b575b5050505050905090565b60606017805480602002602001604051908101604052809291908181526020018280548015610b2357602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311610ad9575b5050505050905090565b602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1685604051610b5d90612308565b610b68929190613633565b604051809103906000f080158015610b84573d6000803e3d6000fd5b50601f60016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550838360a0015160000181905250737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663f28dceb363d7abef4e60e01b604051602401604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506040518263ffffffff1660e01b8152600401610c8991906138e5565b600060405180830381600087803b158015610ca357600080fd5b505af1158015610cb7573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639d043a668385846040518463ffffffff1660e01b8152600401610d1a93929190613856565b602060405180830381865afa158015610d37573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d5b919061357d565b505050505050565b6060601b805480602002602001604051908101604052809291908181526020016000905b82821015610ee55783829060005260206000209060020201604051806040016040529081600082018054610dba906134e3565b80601f0160208091040260200160405190810160405280929190818152602001828054610de6906134e3565b8015610e335780601f10610e0857610100808354040283529160200191610e33565b820191906000526020600020905b815481529060010190602001808311610e1657829003601f168201915b5050505050815260200160018201805480602002602001604051908101604052809291908181526020018280548015610ecd57602002820191906000526020600020906000905b82829054906101000a900460e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191681526020019060040190602082600301049283019260010382029150808411610e7a5790505b50505050508152505081526020019060010190610d87565b50505050905090565b601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6060601a805480602002602001604051908101604052809291908181526020016000905b8282101561100a578382906000526020600020018054610f7d906134e3565b80601f0160208091040260200160405190810160405280929190818152602001828054610fa9906134e3565b8015610ff65780601f10610fcb57610100808354040283529160200191610ff6565b820191906000526020600020905b815481529060010190602001808311610fd957829003601f168201915b505050505081526020019060010190610f5e565b50505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016110909190613499565b60006040518083038186803b1580156110a857600080fd5b505afa1580156110bc573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008751116040518263ffffffff1660e01b81526004016111119190613499565b60006040518083038186803b15801561112957600080fd5b505afa15801561113d573d6000803e3d6000fd5b50505050600a8551111561115057600a85525b61115985611da8565b94506111748460006001885161116f9190613936565b611edf565b93508484815181106111895761118861396a565b5b60200260200101518360a0015160000181905250737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56876040518263ffffffff1660e01b81526004016111ea9190613523565b600060405180830381600087803b15801561120457600080fd5b505af1158015611218573d6000803e3d6000fd5b505050506000602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018896040518263ffffffff1660e01b8152600401611279919061354d565b6020604051808303816000875af1158015611298573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112bc919061357d565b905060005b865181101561138057602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d8389848151811061131c5761131b61396a565b5b60200260200101516040518363ffffffff1660e01b8152600401611341929190613603565b600060405180830381600087803b15801561135b57600080fd5b505af115801561136f573d6000803e3d6000fd5b5050505080806001019150506112c1565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156113dd57600080fd5b505af11580156113f1573d6000803e3d6000fd5b50505050602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff168160405161142590612308565b611430929190613633565b604051809103906000f08015801561144c573d6000803e3d6000fd5b50601f60016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060006114a28486611cab90919063ffffffff16565b90506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639d043a668688876040518463ffffffff1660e01b815260040161150593929190613856565b602060405180830381865afa158015611522573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611546919061357d565b90506115528183611d0e565b50505050505050505050565b6060601d805480602002602001604051908101604052809291908181526020016000905b828210156116a457838290600052602060002090600202016040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016001820180548060200260200160405190810160405280929190818152602001828054801561168c57602002820191906000526020600020906000905b82829054906101000a900460e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200190600401906020826003010492830192600103820291508084116116395790505b50505050508152505081526020019060010190611582565b50505050905090565b602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16816040516116dd90612308565b6116e8929190613633565b604051809103906000f080158015611704573d6000803e3d6000fd5b50601f60016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555061180b601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166301ffc9a77f01ffc9a7000000000000000000000000000000000000000000000000000000006040518263ffffffff1660e01b81526004016117c391906139a8565b602060405180830381865afa1580156117e0573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061180491906139d8565b6001611f34565b6118d1601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166301ffc9a77f9d043a66000000000000000000000000000000000000000000000000000000006040518263ffffffff1660e01b815260040161188991906139a8565b602060405180830381865afa1580156118a6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118ca91906139d8565b6001611f34565b50565b6060601c805480602002602001604051908101604052809291908181526020016000905b82821015611a1a57838290600052602060002090600202016040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200160018201805480602002602001604051908101604052809291908181526020018280548015611a0257602002820191906000526020600020906000905b82829054906101000a900460e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200190600401906020826003010492830192600103820291508084116119af5790505b505050505081525050815260200190600101906118f8565b50505050905090565b60606019805480602002602001604051908101604052809291908181526020016000905b82821015611af3578382906000526020600020018054611a66906134e3565b80601f0160208091040260200160405190810160405280929190818152602001828054611a92906134e3565b8015611adf5780601f10611ab457610100808354040283529160200191611adf565b820191906000526020600020905b815481529060010190602001808311611ac257829003601f168201915b505050505081526020019060010190611a47565b50505050905090565b6000600860009054906101000a900460ff1615611b1c5760019050611c07565b6000801b7f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff1663667f9d707f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c7f6661696c656400000000000000000000000000000000000000000000000000006040518363ffffffff1660e01b8152600401611bc1929190613633565b602060405180830381865afa158015611bde573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c02919061357d565b141590505b90565b60606015805480602002602001604051908101604052809291908181526020018280548015611c8e57602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311611c44575b5050505050905090565b601f60009054906101000a900460ff1681565b6000604051602001611cbc90613a5c565b604051602081830303815290604052805190602001208284606001518560400151604051602001611cf09493929190613ada565b60405160208183030381529060405280519060200120905092915050565b808214611da4577f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff16637c84c69b83836040518363ffffffff1660e01b8152600401611d73929190613b28565b60006040518083038186803b158015611d8b57600080fd5b505afa158015611d9f573d6000803e3d6000fd5b505050505b5050565b6060815167ffffffffffffffff811115611dc557611dc4612746565b5b604051908082528060200260200182016040528015611df857816020015b6060815260200190600190039081611de35790505b5090506000805b8351811015611ed557600080611e2e868481518110611e2157611e2061396a565b5b6020026020010151611fd2565b905060005b84811015611e7a57611e5e868281518110611e5157611e5061396a565b5b6020026020010151611fd2565b8203611e6d5760019250611e7a565b8080600101915050611e33565b5081611ec657858381518110611e9357611e9261396a565b5b6020026020010151858580611ea790613b51565b965081518110611eba57611eb961396a565b5b60200260200101819052505b50508080600101915050611dff565b5080825250919050565b6000611eec848484612002565b9050611f2d6040518060400160405280600c81526020017f426f756e6420726573756c74000000000000000000000000000000000000000081525082612211565b9392505050565b80151582151514611fce577f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff1663f7fe347783836040518363ffffffff1660e01b8152600401611f9d929190613b99565b60006040518083038186803b158015611fb557600080fd5b505afa158015611fc9573d6000803e3d6000fd5b505050505b5050565b600081604051602001611fe59190613bf3565b604051602081830303815290604052805190602001209050919050565b600081831115612047576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161203e90613c7c565b60405180910390fd5b8284101580156120575750818411155b156120645783905061220a565b6000600184846120749190613936565b61207e9190613c9c565b90506003851115801561209057508481115b156120a95784846120a19190613c9c565b91505061220a565b60037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6120d69190613936565b851015801561210f5750847fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff61210c9190613936565b81115b1561215357847fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6121409190613936565b8361214b9190613936565b91505061220a565b828511156121af57600083866121699190613936565b9050600082826121799190613cff565b90506000810361218e5784935050505061220a565b6001818761219c9190613c9c565b6121a69190613936565b93505050612208565b8385101561220757600085856121c59190613936565b9050600082826121d59190613cff565b9050600081036121ea5785935050505061220a565b600181866121f89190613936565b6122029190613c9c565b935050505b5b505b9392505050565b6122a98282604051602401612227929190613d3f565b6040516020818303038152906040527fb60e72cc000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506122ad565b5050565b6122c4816122bc6122c76122f0565b63ffffffff16565b50565b60008151905060006a636f6e736f6c652e6c6f679050602083016000808483855afa5050505050565b612315819050919050565b61239380613d9f83390190565b610a4e8061613283390190565b61231d613d6f565b565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006123768261234b565b9050919050565b6123868161236b565b82525050565b6000612398838361237d565b60208301905092915050565b6000602082019050919050565b60006123bc8261231f565b6123c6818561232a565b93506123d18361233b565b8060005b838110156124025781516123e9888261238c565b97506123f4836123a4565b9250506001810190506123d5565b5085935050505092915050565b6000602082019050818103600083015261242981846123b1565b905092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b60005b838110156124c35780820151818401526020810190506124a8565b60008484015250505050565b6000601f19601f8301169050919050565b60006124eb82612489565b6124f58185612494565b93506125058185602086016124a5565b61250e816124cf565b840191505092915050565b600061252583836124e0565b905092915050565b6000602082019050919050565b60006125458261245d565b61254f8185612468565b93508360208202850161256185612479565b8060005b8581101561259d578484038952815161257e8582612519565b94506125898361252d565b925060208a01995050600181019050612565565b50829750879550505050505092915050565b60006040830160008301516125c7600086018261237d565b50602083015184820360208601526125df828261253a565b9150508091505092915050565b60006125f883836125af565b905092915050565b6000602082019050919050565b600061261882612431565b612622818561243c565b9350836020820285016126348561244d565b8060005b85811015612670578484038952815161265185826125ec565b945061265c83612600565b925060208a01995050600181019050612638565b50829750879550505050505092915050565b6000602082019050818103600083015261269c818461260d565b905092915050565b6000604051905090565b600080fd5b600080fd5b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b6126ed816126b8565b81146126f857600080fd5b50565b60008135905061270a816126e4565b92915050565b6127198161236b565b811461272457600080fd5b50565b60008135905061273681612710565b92915050565b600080fd5b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61277e826124cf565b810181811067ffffffffffffffff8211171561279d5761279c612746565b5b80604052505050565b60006127b06126a4565b90506127bc8282612775565b919050565b600067ffffffffffffffff8211156127dc576127db612746565b5b6127e5826124cf565b9050602081019050919050565b82818337600083830152505050565b600061281461280f846127c1565b6127a6565b9050828152602081018484840111156128305761282f612741565b5b61283b8482856127f2565b509392505050565b600082601f8301126128585761285761273c565b5b8135612868848260208601612801565b91505092915050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b6128b08161287b565b81146128bb57600080fd5b50565b6000813590506128cd816128a7565b92915050565b6000819050919050565b6128e6816128d3565b81146128f157600080fd5b50565b600081359050612903816128dd565b92915050565b600067ffffffffffffffff82111561292457612923612746565b5b61292d826124cf565b9050602081019050919050565b600061294d61294884612909565b6127a6565b90508281526020810184848401111561296957612968612741565b5b6129748482856127f2565b509392505050565b600082601f8301126129915761299061273c565b5b81356129a184826020860161293a565b91505092915050565b600067ffffffffffffffff82169050919050565b6129c7816129aa565b81146129d257600080fd5b50565b6000813590506129e4816129be565b92915050565b600060408284031215612a00576129ff612871565b5b612a0a60406127a6565b9050600082013567ffffffffffffffff811115612a2a57612a29612876565b5b612a3684828501612843565b6000830152506020612a4a848285016129d5565b60208301525092915050565b600060c08284031215612a6c57612a6b612871565b5b612a7660c06127a6565b90506000612a8684828501612727565b6000830152506020612a9a848285016128be565b6020830152506040612aae848285016128f4565b6040830152506060612ac2848285016128f4565b606083015250608082013567ffffffffffffffff811115612ae657612ae5612876565b5b612af28482850161297c565b60808301525060a082013567ffffffffffffffff811115612b1657612b15612876565b5b612b22848285016129ea565b60a08301525092915050565b6000819050919050565b612b4181612b2e565b8114612b4c57600080fd5b50565b600081359050612b5e81612b38565b92915050565b60008115159050919050565b612b7981612b64565b8114612b8457600080fd5b50565b600081359050612b9681612b70565b92915050565b600060e08284031215612bb257612bb1612871565b5b612bbc60e06127a6565b90506000612bcc84828501612727565b6000830152506020612be084828501612b4f565b602083015250604082013567ffffffffffffffff811115612c0457612c03612876565b5b612c108482850161297c565b6040830152506060612c2484828501612b4f565b6060830152506080612c3884828501612b87565b60808301525060a0612c4c84828501612b87565b60a08301525060c0612c6084828501612b4f565b60c08301525092915050565b60008060008060008060c08789031215612c8957612c886126ae565b5b6000612c9789828a016126fb565b9650506020612ca889828a01612727565b955050604087013567ffffffffffffffff811115612cc957612cc86126b3565b5b612cd589828a01612843565b945050606087013567ffffffffffffffff811115612cf657612cf56126b3565b5b612d0289828a01612a56565b9350506080612d1389828a01612727565b92505060a087013567ffffffffffffffff811115612d3457612d336126b3565b5b612d4089828a01612b9c565b9150509295509295509295565b600080600080600060a08688031215612d6957612d686126ae565b5b6000612d77888289016128f4565b955050602086013567ffffffffffffffff811115612d9857612d976126b3565b5b612da488828901612843565b945050604086013567ffffffffffffffff811115612dc557612dc46126b3565b5b612dd188828901612a56565b9350506060612de288828901612727565b925050608086013567ffffffffffffffff811115612e0357612e026126b3565b5b612e0f88828901612b9c565b9150509295509295909350565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b612e7d8161287b565b82525050565b6000612e8f8383612e74565b60208301905092915050565b6000602082019050919050565b6000612eb382612e48565b612ebd8185612e53565b9350612ec883612e64565b8060005b83811015612ef9578151612ee08882612e83565b9750612eeb83612e9b565b925050600181019050612ecc565b5085935050505092915050565b60006040830160008301518482036000860152612f2382826124e0565b91505060208301518482036020860152612f3d8282612ea8565b9150508091505092915050565b6000612f568383612f06565b905092915050565b6000602082019050919050565b6000612f7682612e1c565b612f808185612e27565b935083602082028501612f9285612e38565b8060005b85811015612fce5784840389528151612faf8582612f4a565b9450612fba83612f5e565b925060208a01995050600181019050612f96565b50829750879550505050505092915050565b60006020820190508181036000830152612ffa8184612f6b565b905092915050565b6000819050919050565b600061302761302261301d8461234b565b613002565b61234b565b9050919050565b60006130398261300c565b9050919050565b600061304b8261302e565b9050919050565b61305b81613040565b82525050565b60006020820190506130766000830184613052565b92915050565b60006130878261302e565b9050919050565b6130978161307c565b82525050565b60006020820190506130b2600083018461308e565b92915050565b600082825260208201905092915050565b60006130d48261245d565b6130de81856130b8565b9350836020820285016130f085612479565b8060005b8581101561312c578484038952815161310d8582612519565b94506131188361252d565b925060208a019950506001810190506130f4565b50829750879550505050505092915050565b6000602082019050818103600083015261315881846130c9565b905092915050565b600067ffffffffffffffff82111561317b5761317a612746565b5b602082029050602081019050919050565b600080fd5b60006131a461319f84613160565b6127a6565b905080838252602082019050602084028301858111156131c7576131c661318c565b5b835b8181101561320e57803567ffffffffffffffff8111156131ec576131eb61273c565b5b8086016131f98982612843565b855260208501945050506020810190506131c9565b5050509392505050565b600082601f83011261322d5761322c61273c565b5b813561323d848260208601613191565b91505092915050565b600080600080600080600060e0888a031215613265576132646126ae565b5b60006132738a828b016126fb565b97505060206132848a828b01612727565b965050604088013567ffffffffffffffff8111156132a5576132a46126b3565b5b6132b18a828b01613218565b95505060606132c28a828b01612b4f565b945050608088013567ffffffffffffffff8111156132e3576132e26126b3565b5b6132ef8a828b01612a56565b93505060a06133008a828b01612727565b92505060c088013567ffffffffffffffff811115613321576133206126b3565b5b61332d8a828b01612b9c565b91505092959891949750929550565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6000604083016000830151613380600086018261237d565b50602083015184820360208601526133988282612ea8565b9150508091505092915050565b60006133b18383613368565b905092915050565b6000602082019050919050565b60006133d18261333c565b6133db8185613347565b9350836020820285016133ed85613358565b8060005b85811015613429578484038952815161340a85826133a5565b9450613415836133b9565b925060208a019950506001810190506133f1565b50829750879550505050505092915050565b6000602082019050818103600083015261345581846133c6565b905092915050565b600060208284031215613473576134726126ae565b5b6000613481848285016128f4565b91505092915050565b61349381612b64565b82525050565b60006020820190506134ae600083018461348a565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b600060028204905060018216806134fb57607f821691505b60208210810361350e5761350d6134b4565b5b50919050565b61351d8161236b565b82525050565b60006020820190506135386000830184613514565b92915050565b613547816126b8565b82525050565b6000602082019050613562600083018461353e565b92915050565b600081519050613577816128dd565b92915050565b600060208284031215613593576135926126ae565b5b60006135a184828501613568565b91505092915050565b6135b3816128d3565b82525050565b600082825260208201905092915050565b60006135d582612489565b6135df81856135b9565b93506135ef8185602086016124a5565b6135f8816124cf565b840191505092915050565b600060408201905061361860008301856135aa565b818103602083015261362a81846135ca565b90509392505050565b60006040820190506136486000830185613514565b61365560208301846135aa565b9392505050565b613665816128d3565b82525050565b600081519050919050565b600082825260208201905092915050565b60006136928261366b565b61369c8185613676565b93506136ac8185602086016124a5565b6136b5816124cf565b840191505092915050565b6136c9816129aa565b82525050565b600060408301600083015184820360008601526136ec82826124e0565b915050602083015161370160208601826136c0565b508091505092915050565b600060c083016000830151613724600086018261237d565b5060208301516137376020860182612e74565b50604083015161374a604086018261365c565b50606083015161375d606086018261365c565b50608083015184820360808601526137758282613687565b91505060a083015184820360a086015261378f82826136cf565b9150508091505092915050565b6137a581612b2e565b82525050565b6137b481612b64565b82525050565b600060e0830160008301516137d2600086018261237d565b5060208301516137e5602086018261379c565b50604083015184820360408601526137fd8282613687565b9150506060830151613812606086018261379c565b50608083015161382560808601826137ab565b5060a083015161383860a08601826137ab565b5060c083015161384b60c086018261379c565b508091505092915050565b600060608201905061386b6000830186613514565b818103602083015261387d818561370c565b9050818103604083015261389181846137ba565b9050949350505050565b600082825260208201905092915050565b60006138b78261366b565b6138c1818561389b565b93506138d18185602086016124a5565b6138da816124cf565b840191505092915050565b600060208201905081810360008301526138ff81846138ac565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061394182612b2e565b915061394c83612b2e565b925082820390508181111561396457613963613907565b5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6139a28161287b565b82525050565b60006020820190506139bd6000830184613999565b92915050565b6000815190506139d281612b70565b92915050565b6000602082840312156139ee576139ed6126ae565b5b60006139fc848285016139c3565b91505092915050565b600081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b6000613a46601583613a05565b9150613a5182613a10565b601582019050919050565b6000613a6782613a39565b9150819050919050565b6000819050919050565b613a8c613a87826128d3565b613a71565b82525050565b60008160601b9050919050565b6000613aaa82613a92565b9050919050565b6000613abc82613a9f565b9050919050565b613ad4613acf8261236b565b613ab1565b82525050565b6000613ae68287613a7b565b602082019150613af68286613ac3565b601482019150613b068285613a7b565b602082019150613b168284613a7b565b60208201915081905095945050505050565b6000604082019050613b3d60008301856135aa565b613b4a60208301846135aa565b9392505050565b6000613b5c82612b2e565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613b8e57613b8d613907565b5b600182019050919050565b6000604082019050613bae600083018561348a565b613bbb602083018461348a565b9392505050565b6000613bcd82612489565b613bd78185613a05565b9350613be78185602086016124a5565b80840191505092915050565b6000613bff8284613bc2565b915081905092915050565b7f5374645574696c7320626f756e642875696e743235362c75696e743235362c7560008201527f696e74323536293a204d6178206973206c657373207468616e206d696e2e0000602082015250565b6000613c66603e836135b9565b9150613c7182613c0a565b604082019050919050565b60006020820190508181036000830152613c9581613c59565b9050919050565b6000613ca782612b2e565b9150613cb283612b2e565b9250828201905080821115613cca57613cc9613907565b5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000613d0a82612b2e565b9150613d1583612b2e565b925082613d2557613d24613cd0565b5b828206905092915050565b613d3981612b2e565b82525050565b60006040820190508181036000830152613d5981856135ca565b9050613d686020830184613d30565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052605160045260246000fdfe6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c0033608060405234801561001057600080fd5b50604051610a4e380380610a4e8339818101604052810190610032919061012d565b610042828261004960201b60201c565b505061016d565b816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550806001819055505050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006100c482610099565b9050919050565b6100d4816100b9565b81146100df57600080fd5b50565b6000815190506100f1816100cb565b92915050565b6000819050919050565b61010a816100f7565b811461011557600080fd5b50565b60008151905061012781610101565b92915050565b6000806040838503121561014457610143610094565b5b6000610152858286016100e2565b925050602061016385828601610118565b9150509250929050565b6108d28061017c6000396000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c806301ffc9a71461003b5780639d043a661461006b575b600080fd5b6100556004803603810190610050919061029c565b61009b565b60405161006291906102e4565b60405180910390f35b610085600480360381019061008091906103a0565b610115565b6040516100929190610444565b60405180910390f35b60007f9d043a66000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061010e575061010d826101cb565b5b9050919050565b6000610122848484610235565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633808a90b85856001546040518463ffffffff1660e01b81526004016101819392919061081c565b602060405180830381865afa15801561019e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101c2919061086f565b90509392505050565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b505050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b61027981610244565b811461028457600080fd5b50565b60008135905061029681610270565b92915050565b6000602082840312156102b2576102b161023a565b5b60006102c084828501610287565b91505092915050565b60008115159050919050565b6102de816102c9565b82525050565b60006020820190506102f960008301846102d5565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061032a826102ff565b9050919050565b61033a8161031f565b811461034557600080fd5b50565b60008135905061035781610331565b92915050565b600080fd5b600060c082840312156103785761037761035d565b5b81905092915050565b600060e082840312156103975761039661035d565b5b81905092915050565b6000806000606084860312156103b9576103b861023a565b5b60006103c786828701610348565b935050602084013567ffffffffffffffff8111156103e8576103e761023f565b5b6103f486828701610362565b925050604084013567ffffffffffffffff8111156104155761041461023f565b5b61042186828701610381565b9150509250925092565b6000819050919050565b61043e8161042b565b82525050565b60006020820190506104596000830184610435565b92915050565b6104688161031f565b82525050565b600061047d6020840184610348565b905092915050565b61048e8161031f565b82525050565b60006104a36020840184610287565b905092915050565b6104b481610244565b82525050565b6104c38161042b565b81146104ce57600080fd5b50565b6000813590506104e0816104ba565b92915050565b60006104f560208401846104d1565b905092915050565b6105068161042b565b82525050565b600080fd5b600080fd5b600080fd5b6000808335600160200384360303811261053857610537610516565b5b83810192508235915060208301925067ffffffffffffffff8211156105605761055f61050c565b5b60018202360383131561057657610575610511565b5b509250929050565b600082825260208201905092915050565b82818337600083830152505050565b6000601f19601f8301169050919050565b60006105bb838561057e565b93506105c883858461058f565b6105d18361059e565b840190509392505050565b6000823560016040038336030381126105f8576105f7610516565b5b82810191505092915050565b6000808335600160200384360303811261062157610620610516565b5b83810192508235915060208301925067ffffffffffffffff8211156106495761064861050c565b5b60018202360383131561065f5761065e610511565b5b509250929050565b600082825260208201905092915050565b60006106848385610667565b935061069183858461058f565b61069a8361059e565b840190509392505050565b600067ffffffffffffffff82169050919050565b6106c2816106a5565b81146106cd57600080fd5b50565b6000813590506106df816106b9565b92915050565b60006106f460208401846106d0565b905092915050565b610705816106a5565b82525050565b60006040830161071e6000840184610604565b8583036000870152610731838284610678565b9250505061074260208401846106e5565b61074f60208601826106fc565b508091505092915050565b600060c0830161076d600084018461046e565b61077a6000860182610485565b506107886020840184610494565b61079560208601826104ab565b506107a360408401846104e6565b6107b060408601826104fd565b506107be60608401846104e6565b6107cb60608601826104fd565b506107d9608084018461051b565b85830360808701526107ec8382846105af565b925050506107fd60a08401846105dc565b84820360a086015261080f828261070b565b9150508091505092915050565b6000606082019050610831600083018661045f565b8181036020830152610843818561075a565b90506108526040830184610435565b949350505050565b600081519050610869816104ba565b92915050565b6000602082840312156108855761088461023a565b5b60006108938482850161085a565b9150509291505056fea26469706673582212200f7838d4e08a733173c1114f7d1249b401d87f3d48bda9d4937ec1a8b486922264736f6c634300081c0033a264697066735822122075f50a4f44ee8dfd39658c916fe8136fd521f23dbb04b3f58ee001abedca527164736f6c634300081c0033","sourceMap":"798:3196:30:-:0;;;3200:4:2;3160:44;;;;;;;;;;;;;;;;;;;;1087:4:13;1065:26;;;;;;;;;;;;;;;;;;;;798:3196:30;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x608060405234801561001057600080fd5b50600436106101215760003560e01c80637b103999116100ad578063b0464fdc11610071578063b0464fdc146102ae578063b5508aa9146102cc578063ba414fa6146102ea578063e20c9f7114610308578063fa7626d41461032657610121565b80637b1039991461021c57806385226c811461023a57806390110f2d14610258578063916a17c614610274578063a401b02b1461029257610121565b80633e5e3c23116100f45780633e5e3c23146101885780633f7286f4146101a657806350932724146101c457806366d9a9a0146101e05780637aa3488f146101fe57610121565b80630a9254e4146101265780631ed7831c146101305780632ade38801461014e5780632f2377181461016c575b600080fd5b61012e610344565b005b6101386103af565b604051610145919061240f565b60405180910390f35b61015661043d565b6040516101639190612682565b60405180910390f35b61018660048036038101906101819190612c6c565b6105cb565b005b610190610a11565b60405161019d919061240f565b60405180910390f35b6101ae610a9f565b6040516101bb919061240f565b60405180910390f35b6101de60048036038101906101d99190612d4d565b610b2d565b005b6101e8610d63565b6040516101f59190612fe0565b60405180910390f35b610206610eee565b6040516102139190613061565b60405180910390f35b610224610f14565b604051610231919061309d565b60405180910390f35b610242610f3a565b60405161024f919061313e565b60405180910390f35b610272600480360381019061026d9190613246565b611013565b005b61027c61155e565b604051610289919061343b565b60405180910390f35b6102ac60048036038101906102a7919061345d565b6116ad565b005b6102b66118d4565b6040516102c3919061343b565b60405180910390f35b6102d4611a23565b6040516102e1919061313e565b60405180910390f35b6102f2611afc565b6040516102ff9190613499565b60405180910390f35b610310611c0a565b60405161031d919061240f565b60405180910390f35b61032e611c98565b60405161033b9190613499565b60405180910390f35b604051610350906122fb565b604051809103906000f08015801561036c573d6000803e3d6000fd5b50602060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b6060601680548060200260200160405190810160405280929190818152602001828054801561043357602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190600101908083116103e9575b5050505050905090565b6060601e805480602002602001604051908101604052809291908181526020016000905b828210156105c257838290600052602060002090600202016040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200160018201805480602002602001604051908101604052809291908181526020016000905b828210156105ab57838290600052602060002001805461051e906134e3565b80601f016020809104026020016040519081016040528092919081815260200182805461054a906134e3565b80156105975780601f1061056c57610100808354040283529160200191610597565b820191906000526020600020905b81548152906001019060200180831161057a57829003601f168201915b5050505050815260200190600101906104ff565b505050508152505081526020019060010190610461565b50505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016106489190613499565b60006040518083038186803b15801561066057600080fd5b505afa158015610674573d6000803e3d6000fd5b50505050838360a0015160000181905250737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56866040518263ffffffff1660e01b81526004016106d29190613523565b600060405180830381600087803b1580156106ec57600080fd5b505af1158015610700573d6000803e3d6000fd5b505050506000602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018886040518263ffffffff1660e01b8152600401610761919061354d565b6020604051808303816000875af1158015610780573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107a4919061357d565b9050602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d82876040518363ffffffff1660e01b8152600401610803929190613603565b600060405180830381600087803b15801561081d57600080fd5b505af1158015610831573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561089157600080fd5b505af11580156108a5573d6000803e3d6000fd5b50505050602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16816040516108d990612308565b6108e4929190613633565b604051809103906000f080158015610900573d6000803e3d6000fd5b50601f60016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060006109568486611cab90919063ffffffff16565b90506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639d043a668688876040518463ffffffff1660e01b81526004016109b993929190613856565b602060405180830381865afa1580156109d6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109fa919061357d565b9050610a068183611d0e565b505050505050505050565b60606018805480602002602001604051908101604052809291908181526020018280548015610a9557602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311610a4b575b5050505050905090565b60606017805480602002602001604051908101604052809291908181526020018280548015610b2357602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311610ad9575b5050505050905090565b602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1685604051610b5d90612308565b610b68929190613633565b604051809103906000f080158015610b84573d6000803e3d6000fd5b50601f60016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550838360a0015160000181905250737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663f28dceb363d7abef4e60e01b604051602401604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506040518263ffffffff1660e01b8152600401610c8991906138e5565b600060405180830381600087803b158015610ca357600080fd5b505af1158015610cb7573d6000803e3d6000fd5b50505050601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639d043a668385846040518463ffffffff1660e01b8152600401610d1a93929190613856565b602060405180830381865afa158015610d37573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d5b919061357d565b505050505050565b6060601b805480602002602001604051908101604052809291908181526020016000905b82821015610ee55783829060005260206000209060020201604051806040016040529081600082018054610dba906134e3565b80601f0160208091040260200160405190810160405280929190818152602001828054610de6906134e3565b8015610e335780601f10610e0857610100808354040283529160200191610e33565b820191906000526020600020905b815481529060010190602001808311610e1657829003601f168201915b5050505050815260200160018201805480602002602001604051908101604052809291908181526020018280548015610ecd57602002820191906000526020600020906000905b82829054906101000a900460e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191681526020019060040190602082600301049283019260010382029150808411610e7a5790505b50505050508152505081526020019060010190610d87565b50505050905090565b601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6060601a805480602002602001604051908101604052809291908181526020016000905b8282101561100a578382906000526020600020018054610f7d906134e3565b80601f0160208091040260200160405190810160405280929190818152602001828054610fa9906134e3565b8015610ff65780601f10610fcb57610100808354040283529160200191610ff6565b820191906000526020600020905b815481529060010190602001808311610fd957829003601f168201915b505050505081526020019060010190610f5e565b50505050905090565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e562600073ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff1614156040518263ffffffff1660e01b81526004016110909190613499565b60006040518083038186803b1580156110a857600080fd5b505afa1580156110bc573d6000803e3d6000fd5b50505050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16634c63e56260008751116040518263ffffffff1660e01b81526004016111119190613499565b60006040518083038186803b15801561112957600080fd5b505afa15801561113d573d6000803e3d6000fd5b50505050600a8551111561115057600a85525b61115985611da8565b94506111748460006001885161116f9190613936565b611edf565b93508484815181106111895761118861396a565b5b60200260200101518360a0015160000181905250737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166306447d56876040518263ffffffff1660e01b81526004016111ea9190613523565b600060405180830381600087803b15801561120457600080fd5b505af1158015611218573d6000803e3d6000fd5b505050506000602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d4df1018896040518263ffffffff1660e01b8152600401611279919061354d565b6020604051808303816000875af1158015611298573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112bc919061357d565b905060005b865181101561138057602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f28c69d8389848151811061131c5761131b61396a565b5b60200260200101516040518363ffffffff1660e01b8152600401611341929190613603565b600060405180830381600087803b15801561135b57600080fd5b505af115801561136f573d6000803e3d6000fd5b5050505080806001019150506112c1565b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166390c5013b6040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156113dd57600080fd5b505af11580156113f1573d6000803e3d6000fd5b50505050602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff168160405161142590612308565b611430929190613633565b604051809103906000f08015801561144c573d6000803e3d6000fd5b50601f60016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060006114a28486611cab90919063ffffffff16565b90506000601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639d043a668688876040518463ffffffff1660e01b815260040161150593929190613856565b602060405180830381865afa158015611522573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611546919061357d565b90506115528183611d0e565b50505050505050505050565b6060601d805480602002602001604051908101604052809291908181526020016000905b828210156116a457838290600052602060002090600202016040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016001820180548060200260200160405190810160405280929190818152602001828054801561168c57602002820191906000526020600020906000905b82829054906101000a900460e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200190600401906020826003010492830192600103820291508084116116395790505b50505050508152505081526020019060010190611582565b50505050905090565b602060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16816040516116dd90612308565b6116e8929190613633565b604051809103906000f080158015611704573d6000803e3d6000fd5b50601f60016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555061180b601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166301ffc9a77f01ffc9a7000000000000000000000000000000000000000000000000000000006040518263ffffffff1660e01b81526004016117c391906139a8565b602060405180830381865afa1580156117e0573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061180491906139d8565b6001611f34565b6118d1601f60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166301ffc9a77f9d043a66000000000000000000000000000000000000000000000000000000006040518263ffffffff1660e01b815260040161188991906139a8565b602060405180830381865afa1580156118a6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118ca91906139d8565b6001611f34565b50565b6060601c805480602002602001604051908101604052809291908181526020016000905b82821015611a1a57838290600052602060002090600202016040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200160018201805480602002602001604051908101604052809291908181526020018280548015611a0257602002820191906000526020600020906000905b82829054906101000a900460e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200190600401906020826003010492830192600103820291508084116119af5790505b505050505081525050815260200190600101906118f8565b50505050905090565b60606019805480602002602001604051908101604052809291908181526020016000905b82821015611af3578382906000526020600020018054611a66906134e3565b80601f0160208091040260200160405190810160405280929190818152602001828054611a92906134e3565b8015611adf5780601f10611ab457610100808354040283529160200191611adf565b820191906000526020600020905b815481529060010190602001808311611ac257829003601f168201915b505050505081526020019060010190611a47565b50505050905090565b6000600860009054906101000a900460ff1615611b1c5760019050611c07565b6000801b7f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff1663667f9d707f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c7f6661696c656400000000000000000000000000000000000000000000000000006040518363ffffffff1660e01b8152600401611bc1929190613633565b602060405180830381865afa158015611bde573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c02919061357d565b141590505b90565b60606015805480602002602001604051908101604052809291908181526020018280548015611c8e57602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311611c44575b5050505050905090565b601f60009054906101000a900460ff1681565b6000604051602001611cbc90613a5c565b604051602081830303815290604052805190602001208284606001518560400151604051602001611cf09493929190613ada565b60405160208183030381529060405280519060200120905092915050565b808214611da4577f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff16637c84c69b83836040518363ffffffff1660e01b8152600401611d73929190613b28565b60006040518083038186803b158015611d8b57600080fd5b505afa158015611d9f573d6000803e3d6000fd5b505050505b5050565b6060815167ffffffffffffffff811115611dc557611dc4612746565b5b604051908082528060200260200182016040528015611df857816020015b6060815260200190600190039081611de35790505b5090506000805b8351811015611ed557600080611e2e868481518110611e2157611e2061396a565b5b6020026020010151611fd2565b905060005b84811015611e7a57611e5e868281518110611e5157611e5061396a565b5b6020026020010151611fd2565b8203611e6d5760019250611e7a565b8080600101915050611e33565b5081611ec657858381518110611e9357611e9261396a565b5b6020026020010151858580611ea790613b51565b965081518110611eba57611eb961396a565b5b60200260200101819052505b50508080600101915050611dff565b5080825250919050565b6000611eec848484612002565b9050611f2d6040518060400160405280600c81526020017f426f756e6420726573756c74000000000000000000000000000000000000000081525082612211565b9392505050565b80151582151514611fce577f885cb69240a935d632d79c317109709ecfa91a80626ff3989d68f67f5b1dd12d60001c73ffffffffffffffffffffffffffffffffffffffff1663f7fe347783836040518363ffffffff1660e01b8152600401611f9d929190613b99565b60006040518083038186803b158015611fb557600080fd5b505afa158015611fc9573d6000803e3d6000fd5b505050505b5050565b600081604051602001611fe59190613bf3565b604051602081830303815290604052805190602001209050919050565b600081831115612047576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161203e90613c7c565b60405180910390fd5b8284101580156120575750818411155b156120645783905061220a565b6000600184846120749190613936565b61207e9190613c9c565b90506003851115801561209057508481115b156120a95784846120a19190613c9c565b91505061220a565b60037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6120d69190613936565b851015801561210f5750847fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff61210c9190613936565b81115b1561215357847fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6121409190613936565b8361214b9190613936565b91505061220a565b828511156121af57600083866121699190613936565b9050600082826121799190613cff565b90506000810361218e5784935050505061220a565b6001818761219c9190613c9c565b6121a69190613936565b93505050612208565b8385101561220757600085856121c59190613936565b9050600082826121d59190613cff565b9050600081036121ea5785935050505061220a565b600181866121f89190613936565b6122029190613c9c565b935050505b5b505b9392505050565b6122a98282604051602401612227929190613d3f565b6040516020818303038152906040527fb60e72cc000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506122ad565b5050565b6122c4816122bc6122c76122f0565b63ffffffff16565b50565b60008151905060006a636f6e736f6c652e6c6f679050602083016000808483855afa5050505050565b612315819050919050565b61239380613d9f83390190565b610a4e8061613283390190565b61231d613d6f565b565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006123768261234b565b9050919050565b6123868161236b565b82525050565b6000612398838361237d565b60208301905092915050565b6000602082019050919050565b60006123bc8261231f565b6123c6818561232a565b93506123d18361233b565b8060005b838110156124025781516123e9888261238c565b97506123f4836123a4565b9250506001810190506123d5565b5085935050505092915050565b6000602082019050818103600083015261242981846123b1565b905092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b60005b838110156124c35780820151818401526020810190506124a8565b60008484015250505050565b6000601f19601f8301169050919050565b60006124eb82612489565b6124f58185612494565b93506125058185602086016124a5565b61250e816124cf565b840191505092915050565b600061252583836124e0565b905092915050565b6000602082019050919050565b60006125458261245d565b61254f8185612468565b93508360208202850161256185612479565b8060005b8581101561259d578484038952815161257e8582612519565b94506125898361252d565b925060208a01995050600181019050612565565b50829750879550505050505092915050565b60006040830160008301516125c7600086018261237d565b50602083015184820360208601526125df828261253a565b9150508091505092915050565b60006125f883836125af565b905092915050565b6000602082019050919050565b600061261882612431565b612622818561243c565b9350836020820285016126348561244d565b8060005b85811015612670578484038952815161265185826125ec565b945061265c83612600565b925060208a01995050600181019050612638565b50829750879550505050505092915050565b6000602082019050818103600083015261269c818461260d565b905092915050565b6000604051905090565b600080fd5b600080fd5b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b6126ed816126b8565b81146126f857600080fd5b50565b60008135905061270a816126e4565b92915050565b6127198161236b565b811461272457600080fd5b50565b60008135905061273681612710565b92915050565b600080fd5b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61277e826124cf565b810181811067ffffffffffffffff8211171561279d5761279c612746565b5b80604052505050565b60006127b06126a4565b90506127bc8282612775565b919050565b600067ffffffffffffffff8211156127dc576127db612746565b5b6127e5826124cf565b9050602081019050919050565b82818337600083830152505050565b600061281461280f846127c1565b6127a6565b9050828152602081018484840111156128305761282f612741565b5b61283b8482856127f2565b509392505050565b600082601f8301126128585761285761273c565b5b8135612868848260208601612801565b91505092915050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b6128b08161287b565b81146128bb57600080fd5b50565b6000813590506128cd816128a7565b92915050565b6000819050919050565b6128e6816128d3565b81146128f157600080fd5b50565b600081359050612903816128dd565b92915050565b600067ffffffffffffffff82111561292457612923612746565b5b61292d826124cf565b9050602081019050919050565b600061294d61294884612909565b6127a6565b90508281526020810184848401111561296957612968612741565b5b6129748482856127f2565b509392505050565b600082601f8301126129915761299061273c565b5b81356129a184826020860161293a565b91505092915050565b600067ffffffffffffffff82169050919050565b6129c7816129aa565b81146129d257600080fd5b50565b6000813590506129e4816129be565b92915050565b600060408284031215612a00576129ff612871565b5b612a0a60406127a6565b9050600082013567ffffffffffffffff811115612a2a57612a29612876565b5b612a3684828501612843565b6000830152506020612a4a848285016129d5565b60208301525092915050565b600060c08284031215612a6c57612a6b612871565b5b612a7660c06127a6565b90506000612a8684828501612727565b6000830152506020612a9a848285016128be565b6020830152506040612aae848285016128f4565b6040830152506060612ac2848285016128f4565b606083015250608082013567ffffffffffffffff811115612ae657612ae5612876565b5b612af28482850161297c565b60808301525060a082013567ffffffffffffffff811115612b1657612b15612876565b5b612b22848285016129ea565b60a08301525092915050565b6000819050919050565b612b4181612b2e565b8114612b4c57600080fd5b50565b600081359050612b5e81612b38565b92915050565b60008115159050919050565b612b7981612b64565b8114612b8457600080fd5b50565b600081359050612b9681612b70565b92915050565b600060e08284031215612bb257612bb1612871565b5b612bbc60e06127a6565b90506000612bcc84828501612727565b6000830152506020612be084828501612b4f565b602083015250604082013567ffffffffffffffff811115612c0457612c03612876565b5b612c108482850161297c565b6040830152506060612c2484828501612b4f565b6060830152506080612c3884828501612b87565b60808301525060a0612c4c84828501612b87565b60a08301525060c0612c6084828501612b4f565b60c08301525092915050565b60008060008060008060c08789031215612c8957612c886126ae565b5b6000612c9789828a016126fb565b9650506020612ca889828a01612727565b955050604087013567ffffffffffffffff811115612cc957612cc86126b3565b5b612cd589828a01612843565b945050606087013567ffffffffffffffff811115612cf657612cf56126b3565b5b612d0289828a01612a56565b9350506080612d1389828a01612727565b92505060a087013567ffffffffffffffff811115612d3457612d336126b3565b5b612d4089828a01612b9c565b9150509295509295509295565b600080600080600060a08688031215612d6957612d686126ae565b5b6000612d77888289016128f4565b955050602086013567ffffffffffffffff811115612d9857612d976126b3565b5b612da488828901612843565b945050604086013567ffffffffffffffff811115612dc557612dc46126b3565b5b612dd188828901612a56565b9350506060612de288828901612727565b925050608086013567ffffffffffffffff811115612e0357612e026126b3565b5b612e0f88828901612b9c565b9150509295509295909350565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b612e7d8161287b565b82525050565b6000612e8f8383612e74565b60208301905092915050565b6000602082019050919050565b6000612eb382612e48565b612ebd8185612e53565b9350612ec883612e64565b8060005b83811015612ef9578151612ee08882612e83565b9750612eeb83612e9b565b925050600181019050612ecc565b5085935050505092915050565b60006040830160008301518482036000860152612f2382826124e0565b91505060208301518482036020860152612f3d8282612ea8565b9150508091505092915050565b6000612f568383612f06565b905092915050565b6000602082019050919050565b6000612f7682612e1c565b612f808185612e27565b935083602082028501612f9285612e38565b8060005b85811015612fce5784840389528151612faf8582612f4a565b9450612fba83612f5e565b925060208a01995050600181019050612f96565b50829750879550505050505092915050565b60006020820190508181036000830152612ffa8184612f6b565b905092915050565b6000819050919050565b600061302761302261301d8461234b565b613002565b61234b565b9050919050565b60006130398261300c565b9050919050565b600061304b8261302e565b9050919050565b61305b81613040565b82525050565b60006020820190506130766000830184613052565b92915050565b60006130878261302e565b9050919050565b6130978161307c565b82525050565b60006020820190506130b2600083018461308e565b92915050565b600082825260208201905092915050565b60006130d48261245d565b6130de81856130b8565b9350836020820285016130f085612479565b8060005b8581101561312c578484038952815161310d8582612519565b94506131188361252d565b925060208a019950506001810190506130f4565b50829750879550505050505092915050565b6000602082019050818103600083015261315881846130c9565b905092915050565b600067ffffffffffffffff82111561317b5761317a612746565b5b602082029050602081019050919050565b600080fd5b60006131a461319f84613160565b6127a6565b905080838252602082019050602084028301858111156131c7576131c661318c565b5b835b8181101561320e57803567ffffffffffffffff8111156131ec576131eb61273c565b5b8086016131f98982612843565b855260208501945050506020810190506131c9565b5050509392505050565b600082601f83011261322d5761322c61273c565b5b813561323d848260208601613191565b91505092915050565b600080600080600080600060e0888a031215613265576132646126ae565b5b60006132738a828b016126fb565b97505060206132848a828b01612727565b965050604088013567ffffffffffffffff8111156132a5576132a46126b3565b5b6132b18a828b01613218565b95505060606132c28a828b01612b4f565b945050608088013567ffffffffffffffff8111156132e3576132e26126b3565b5b6132ef8a828b01612a56565b93505060a06133008a828b01612727565b92505060c088013567ffffffffffffffff811115613321576133206126b3565b5b61332d8a828b01612b9c565b91505092959891949750929550565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6000604083016000830151613380600086018261237d565b50602083015184820360208601526133988282612ea8565b9150508091505092915050565b60006133b18383613368565b905092915050565b6000602082019050919050565b60006133d18261333c565b6133db8185613347565b9350836020820285016133ed85613358565b8060005b85811015613429578484038952815161340a85826133a5565b9450613415836133b9565b925060208a019950506001810190506133f1565b50829750879550505050505092915050565b6000602082019050818103600083015261345581846133c6565b905092915050565b600060208284031215613473576134726126ae565b5b6000613481848285016128f4565b91505092915050565b61349381612b64565b82525050565b60006020820190506134ae600083018461348a565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b600060028204905060018216806134fb57607f821691505b60208210810361350e5761350d6134b4565b5b50919050565b61351d8161236b565b82525050565b60006020820190506135386000830184613514565b92915050565b613547816126b8565b82525050565b6000602082019050613562600083018461353e565b92915050565b600081519050613577816128dd565b92915050565b600060208284031215613593576135926126ae565b5b60006135a184828501613568565b91505092915050565b6135b3816128d3565b82525050565b600082825260208201905092915050565b60006135d582612489565b6135df81856135b9565b93506135ef8185602086016124a5565b6135f8816124cf565b840191505092915050565b600060408201905061361860008301856135aa565b818103602083015261362a81846135ca565b90509392505050565b60006040820190506136486000830185613514565b61365560208301846135aa565b9392505050565b613665816128d3565b82525050565b600081519050919050565b600082825260208201905092915050565b60006136928261366b565b61369c8185613676565b93506136ac8185602086016124a5565b6136b5816124cf565b840191505092915050565b6136c9816129aa565b82525050565b600060408301600083015184820360008601526136ec82826124e0565b915050602083015161370160208601826136c0565b508091505092915050565b600060c083016000830151613724600086018261237d565b5060208301516137376020860182612e74565b50604083015161374a604086018261365c565b50606083015161375d606086018261365c565b50608083015184820360808601526137758282613687565b91505060a083015184820360a086015261378f82826136cf565b9150508091505092915050565b6137a581612b2e565b82525050565b6137b481612b64565b82525050565b600060e0830160008301516137d2600086018261237d565b5060208301516137e5602086018261379c565b50604083015184820360408601526137fd8282613687565b9150506060830151613812606086018261379c565b50608083015161382560808601826137ab565b5060a083015161383860a08601826137ab565b5060c083015161384b60c086018261379c565b508091505092915050565b600060608201905061386b6000830186613514565b818103602083015261387d818561370c565b9050818103604083015261389181846137ba565b9050949350505050565b600082825260208201905092915050565b60006138b78261366b565b6138c1818561389b565b93506138d18185602086016124a5565b6138da816124cf565b840191505092915050565b600060208201905081810360008301526138ff81846138ac565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061394182612b2e565b915061394c83612b2e565b925082820390508181111561396457613963613907565b5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6139a28161287b565b82525050565b60006020820190506139bd6000830184613999565b92915050565b6000815190506139d281612b70565b92915050565b6000602082840312156139ee576139ed6126ae565b5b60006139fc848285016139c3565b91505092915050565b600081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b6000613a46601583613a05565b9150613a5182613a10565b601582019050919050565b6000613a6782613a39565b9150819050919050565b6000819050919050565b613a8c613a87826128d3565b613a71565b82525050565b60008160601b9050919050565b6000613aaa82613a92565b9050919050565b6000613abc82613a9f565b9050919050565b613ad4613acf8261236b565b613ab1565b82525050565b6000613ae68287613a7b565b602082019150613af68286613ac3565b601482019150613b068285613a7b565b602082019150613b168284613a7b565b60208201915081905095945050505050565b6000604082019050613b3d60008301856135aa565b613b4a60208301846135aa565b9392505050565b6000613b5c82612b2e565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613b8e57613b8d613907565b5b600182019050919050565b6000604082019050613bae600083018561348a565b613bbb602083018461348a565b9392505050565b6000613bcd82612489565b613bd78185613a05565b9350613be78185602086016124a5565b80840191505092915050565b6000613bff8284613bc2565b915081905092915050565b7f5374645574696c7320626f756e642875696e743235362c75696e743235362c7560008201527f696e74323536293a204d6178206973206c657373207468616e206d696e2e0000602082015250565b6000613c66603e836135b9565b9150613c7182613c0a565b604082019050919050565b60006020820190508181036000830152613c9581613c59565b9050919050565b6000613ca782612b2e565b9150613cb283612b2e565b9250828201905080821115613cca57613cc9613907565b5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000613d0a82612b2e565b9150613d1583612b2e565b925082613d2557613d24613cd0565b5b828206905092915050565b613d3981612b2e565b82525050565b60006040820190508181036000830152613d5981856135ca565b9050613d686020830184613d30565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052605160045260246000fdfe6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea26469706673582212204704a54d531aafb8da32f577e1884f79b39d1cde28ba592d2a3bea76266c660464736f6c634300081c0033608060405234801561001057600080fd5b50604051610a4e380380610a4e8339818101604052810190610032919061012d565b610042828261004960201b60201c565b505061016d565b816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550806001819055505050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006100c482610099565b9050919050565b6100d4816100b9565b81146100df57600080fd5b50565b6000815190506100f1816100cb565b92915050565b6000819050919050565b61010a816100f7565b811461011557600080fd5b50565b60008151905061012781610101565b92915050565b6000806040838503121561014457610143610094565b5b6000610152858286016100e2565b925050602061016385828601610118565b9150509250929050565b6108d28061017c6000396000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c806301ffc9a71461003b5780639d043a661461006b575b600080fd5b6100556004803603810190610050919061029c565b61009b565b60405161006291906102e4565b60405180910390f35b610085600480360381019061008091906103a0565b610115565b6040516100929190610444565b60405180910390f35b60007f9d043a66000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061010e575061010d826101cb565b5b9050919050565b6000610122848484610235565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633808a90b85856001546040518463ffffffff1660e01b81526004016101819392919061081c565b602060405180830381865afa15801561019e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101c2919061086f565b90509392505050565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b505050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b61027981610244565b811461028457600080fd5b50565b60008135905061029681610270565b92915050565b6000602082840312156102b2576102b161023a565b5b60006102c084828501610287565b91505092915050565b60008115159050919050565b6102de816102c9565b82525050565b60006020820190506102f960008301846102d5565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061032a826102ff565b9050919050565b61033a8161031f565b811461034557600080fd5b50565b60008135905061035781610331565b92915050565b600080fd5b600060c082840312156103785761037761035d565b5b81905092915050565b600060e082840312156103975761039661035d565b5b81905092915050565b6000806000606084860312156103b9576103b861023a565b5b60006103c786828701610348565b935050602084013567ffffffffffffffff8111156103e8576103e761023f565b5b6103f486828701610362565b925050604084013567ffffffffffffffff8111156104155761041461023f565b5b61042186828701610381565b9150509250925092565b6000819050919050565b61043e8161042b565b82525050565b60006020820190506104596000830184610435565b92915050565b6104688161031f565b82525050565b600061047d6020840184610348565b905092915050565b61048e8161031f565b82525050565b60006104a36020840184610287565b905092915050565b6104b481610244565b82525050565b6104c38161042b565b81146104ce57600080fd5b50565b6000813590506104e0816104ba565b92915050565b60006104f560208401846104d1565b905092915050565b6105068161042b565b82525050565b600080fd5b600080fd5b600080fd5b6000808335600160200384360303811261053857610537610516565b5b83810192508235915060208301925067ffffffffffffffff8211156105605761055f61050c565b5b60018202360383131561057657610575610511565b5b509250929050565b600082825260208201905092915050565b82818337600083830152505050565b6000601f19601f8301169050919050565b60006105bb838561057e565b93506105c883858461058f565b6105d18361059e565b840190509392505050565b6000823560016040038336030381126105f8576105f7610516565b5b82810191505092915050565b6000808335600160200384360303811261062157610620610516565b5b83810192508235915060208301925067ffffffffffffffff8211156106495761064861050c565b5b60018202360383131561065f5761065e610511565b5b509250929050565b600082825260208201905092915050565b60006106848385610667565b935061069183858461058f565b61069a8361059e565b840190509392505050565b600067ffffffffffffffff82169050919050565b6106c2816106a5565b81146106cd57600080fd5b50565b6000813590506106df816106b9565b92915050565b60006106f460208401846106d0565b905092915050565b610705816106a5565b82525050565b60006040830161071e6000840184610604565b8583036000870152610731838284610678565b9250505061074260208401846106e5565b61074f60208601826106fc565b508091505092915050565b600060c0830161076d600084018461046e565b61077a6000860182610485565b506107886020840184610494565b61079560208601826104ab565b506107a360408401846104e6565b6107b060408601826104fd565b506107be60608401846104e6565b6107cb60608601826104fd565b506107d9608084018461051b565b85830360808701526107ec8382846105af565b925050506107fd60a08401846105dc565b84820360a086015261080f828261070b565b9150508091505092915050565b6000606082019050610831600083018661045f565b8181036020830152610843818561075a565b90506108526040830184610435565b949350505050565b600081519050610869816104ba565b92915050565b6000602082840312156108855761088461023a565b5b60006108938482850161085a565b9150509291505056fea26469706673582212200f7838d4e08a733173c1114f7d1249b401d87f3d48bda9d4937ec1a8b486922264736f6c634300081c0033a264697066735822122075f50a4f44ee8dfd39658c916fe8136fd521f23dbb04b3f58ee001abedca527164736f6c634300081c0033","sourceMap":"798:3196:30:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;995:75;;;:::i;:::-;;2907:134:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;3823:151;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;1419:859:30;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;3684:133:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;3385:141;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;3471:520:30;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;3193:186:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;897:50:30;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;951:39;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;3047:140:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2282:1185:30;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;3532:146:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;1074:341:30;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;2754:147:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2459:141;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;1306:195:1;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2606:142:6;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;1065:26:13;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;995:75:30;1036:29;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;1025:8;;:40;;;;;;;;;;;;;;;;;;995:75::o;2907:134:6:-;2954:33;3018:16;2999:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2907:134;:::o;3823:151::-;3872:42;3948:19;3926:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3823:151;:::o;1419:859:30:-;336:42:0;1622:9:30;;;1649:1;1632:19;;:5;:19;;;;1622:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1693:3;1658:11;:20;;;:32;;:38;;;;336:42:0;1744:13:30;;;1758:5;1744:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1770:17;1790:8;;;;;;;;;;;:21;;;1812:14;1790:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;1770:57;;1833:8;;;;;;;;;;;:22;;;1856:9;1867:3;1833:38;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;1877:12:30;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2000:8;;;;;;;;;;;2011:9;1964:57;;;;;:::i;:::-;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;1942:19;;:79;;;;;;;;;;;;;;;;;;2063:21;2087:48;2128:6;2087:11;:40;;:48;;;;:::i;:::-;2063:72;;2141:19;2163;;;;;;;;;;;:41;;;2205:6;2213:11;2226:4;2163:68;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;2141:90;;2237:36;2246:11;2259:13;2237:8;:36::i;:::-;1616:662;;;1419:859;;;;;;:::o;3684:133:6:-;3730:33;3794:16;3775:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3684:133;:::o;3385:141::-;3433:35;3501:18;3480:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3385:141;:::o;3471:520:30:-;3710:8;;;;;;;;;;;3721:9;3674:57;;;;;:::i;:::-;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;3652:19;;:79;;;;;;;;;;;;;;;;;;3772:3;3737:11;:20;;;:32;;:38;;;;336:42:0;3817:15:30;;;3856:54;;;3833:78;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3817:95;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3918:19;;;;;;;;;;;:41;;;3960:6;3968:11;3981:4;3918:68;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;3471:520;;;;;:::o;3193:186:6:-;3249:56;3346:26;3317:55;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3193:186;:::o;897:50:30:-;;;;;;;;;;;;;:::o;951:39::-;;;;;;;;;;;;;:::o;3047:140:6:-;3095:34;3162:18;3141:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3047:140;:::o;2282:1185:30:-;336:42:0;2520:9:30;;;2547:1;2530:19;;:5;:19;;;;2520:30;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;2556:9:30;;;2580:1;2566:4;:11;:15;2556:26;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2625:2;2611:4;:11;:16;2607:79;;;2669:2;2663:4;2656:16;2607:79;2698:29;2722:4;2698:23;:29::i;:::-;2691:36;;2742:33;2748:6;2756:1;2773;2759:4;:11;:15;;;;:::i;:::-;2742:5;:33::i;:::-;2733:42;;2817:4;2822:6;2817:12;;;;;;;;:::i;:::-;;;;;;;;2782:11;:20;;;:32;;:47;;;;336:42:0;2877:13:30;;;2891:5;2877:20;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2903:17;2923:8;;;;;;;;;;;:21;;;2945:14;2923:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;2903:57;;2971:9;2966:95;2986:4;:11;2982:1;:15;2966:95;;;3012:8;;;;;;;;;;;:22;;;3035:9;3046:4;3051:1;3046:7;;;;;;;;:::i;:::-;;;;;;;;3012:42;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2999:3;;;;;;;2966:95;;;;336:42:0;3066:12:30;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3189:8;;;;;;;;;;;3200:9;3153:57;;;;;:::i;:::-;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;3131:19;;:79;;;;;;;;;;;;;;;;;;3252:21;3276:48;3317:6;3276:11;:40;;:48;;;;:::i;:::-;3252:72;;3330:19;3352;;;;;;;;;;;:41;;;3394:6;3402:11;3415:4;3352:68;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;3330:90;;3426:36;3435:11;3448:13;3426:8;:36::i;:::-;2514:953;;;2282:1185;;;;;;;:::o;3532:146:6:-;3580:40;3653:18;3632:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3532:146;:::o;1074:341:30:-;1204:8;;;;;;;;;;;1215:9;1168:57;;;;;:::i;:::-;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;1146:19;;:79;;;;;;;;;;;;;;;;;;1231:80;1240:19;;;;;;;;;;;:37;;;1278:25;1240:64;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;1306:4;1231:8;:80::i;:::-;1317:93;1326:19;;;;;;;;;;;:37;;;1364:38;1326:77;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;1405:4;1317:8;:93::i;:::-;1074:341;:::o;2754:147:6:-;2803:40;2876:18;2855:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2754:147;:::o;2459:141::-;2508:34;2575:18;2554:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2459:141;:::o;1306:195:1:-;1345:4;1365:7;;;;;;;;;;;1361:134;;;1395:4;1388:11;;;;1361:134;1482:1;1474:10;;219:28;211:37;;1437:7;;;219:28;211:37;;1255:17;1437:33;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;:47;;1430:54;;1306:195;;:::o;2606:142:6:-;2655:35;2723:18;2702:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2606:142;:::o;1065:26:13:-;;;;;;;;;;;;;:::o;4328:271:21:-;4437:7;284:41:22;;;;;;;:::i;:::-;;;;;;;;;;;;;274:52;;;;;;4531:6:21;4539:11;:24;;;4565:11;:22;;;4476:112;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;4459:135;;;;;;4452:142;;4328:271;;;;:::o;4362:153:1:-;4453:5;4445:4;:13;4441:68;;219:28;211:37;;4474:11;;;4486:4;4492:5;4474:24;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4441:68;4362:153;;:::o;1032:676:31:-;1119:33;1193:5;:12;1180:26;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1160:46;;1212:25;1248:9;1243:389;1263:5;:12;1259:1;:16;1243:389;;;1290:16;1314:19;1336:18;1345:5;1351:1;1345:8;;;;;;;;:::i;:::-;;;;;;;;1336;:18::i;:::-;1314:40;;1367:9;1362:171;1382:17;1378:1;:21;1362:171;;;1435:30;1444:17;1462:1;1444:20;;;;;;;;:::i;:::-;;;;;;;;1435:8;:30::i;:::-;1420:11;:45;1416:109;;1493:4;1479:18;;1509:5;;1416:109;1401:3;;;;;;;1362:171;;;;1545:11;1540:86;;1609:5;1615:1;1609:8;;;;;;;;:::i;:::-;;;;;;;;1568:17;1586:19;;;;;:::i;:::-;;;1568:38;;;;;;;;:::i;:::-;;;;;;;:49;;;;1540:86;1282:350;;1277:3;;;;;;;1243:389;;;;1680:17;1661;1654:44;1646:58;1032:676;;;:::o;2815:199:12:-;2898:14;2933:19;2940:1;2943:3;2948;2933:6;:19::i;:::-;2924:28;;2962:45;;;;;;;;;;;;;;;;;;3000:6;2962:21;:45::i;:::-;2815:199;;;;;:::o;2334:147:1:-;2419:5;2411:13;;:4;:13;;;2407:68;;219:28;211:37;;2440:11;;;2452:4;2458:5;2440:24;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2407:68;2334:147;;:::o;90:127:31:-;158:7;207:3;190:21;;;;;;;;:::i;:::-;;;;;;;;;;;;;180:32;;;;;;173:39;;90:127;;;:::o;1546:1263:12:-;1630:14;1671:3;1664;:10;;1656:85;;;;;;;;;;;;:::i;:::-;;;;;;;;;1975:3;1970:1;:8;;:20;;;;;1987:3;1982:1;:8;;1970:20;1966:34;;;1999:1;1992:8;;;;1966:34;2011:12;2038:1;2032:3;2026;:9;;;;:::i;:::-;:13;;;;:::i;:::-;2011:28;;2234:1;2229;:6;;:18;;;;;2246:1;2239:4;:8;2229:18;2225:38;;;2262:1;2256:3;:7;;;;:::i;:::-;2249:14;;;;;2225:38;2296:1;1042:78;2282:15;;;;:::i;:::-;2277:1;:20;;:46;;;;;2322:1;1042:78;2308:15;;;;:::i;:::-;2301:4;:22;2277:46;2273:82;;;2353:1;1042:78;2339:15;;;;:::i;:::-;2332:3;:23;;;;:::i;:::-;2325:30;;;;;2273:82;2459:3;2455:1;:7;2451:352;;;2478:12;2497:3;2493:1;:7;;;;:::i;:::-;2478:22;;2514:11;2535:4;2528;:11;;;;:::i;:::-;2514:25;;2564:1;2557:3;:8;2553:24;;2574:3;2567:10;;;;;;;2553:24;2612:1;2606:3;2600;:9;;;;:::i;:::-;:13;;;;:::i;:::-;2591:22;;2464:160;;2451:352;;;2638:3;2634:1;:7;2630:173;;;2657:12;2678:1;2672:3;:7;;;;:::i;:::-;2657:22;;2693:11;2714:4;2707;:11;;;;:::i;:::-;2693:25;;2743:1;2736:3;:8;2732:24;;2753:3;2746:10;;;;;;;2732:24;2791:1;2785:3;2779;:9;;;;:::i;:::-;:13;;;;:::i;:::-;2770:22;;2643:160;;2630:173;2451:352;1646:1163;1546:1263;;;;;;:::o;9561:162::-;9645:71;9708:2;9712;9661:54;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9645:15;:71::i;:::-;9561:162;;:::o;8891:133::-;8962:55;9009:7;8962:46;8988:19;8962:25;:46::i;:::-;:55;;:::i;:::-;8891:133;:::o;9030:381::-;9104:21;9128:7;:14;9104:38;;9152:22;679:42;9152:41;;9302:2;9293:7;9289:16;9393:1;9390;9375:13;9361:12;9345:14;9338:5;9327:68;9255:150;;;;9030:381;:::o;8650:235::-;8775:42;8865:4;8856:13;;8650:235;;;:::o;-1:-1:-1:-;;;;;;;;:::o;:::-;;;;;;;;:::o;:::-;;;:::i;:::-;:::o;7:114:33:-;74:6;108:5;102:12;92:22;;7:114;;;:::o;127:184::-;226:11;260:6;255:3;248:19;300:4;295:3;291:14;276:29;;127:184;;;;:::o;317:132::-;384:4;407:3;399:11;;437:4;432:3;428:14;420:22;;317:132;;;:::o;455:126::-;492:7;532:42;525:5;521:54;510:65;;455:126;;;:::o;587:96::-;624:7;653:24;671:5;653:24;:::i;:::-;642:35;;587:96;;;:::o;689:108::-;766:24;784:5;766:24;:::i;:::-;761:3;754:37;689:108;;:::o;803:179::-;872:10;893:46;935:3;927:6;893:46;:::i;:::-;971:4;966:3;962:14;948:28;;803:179;;;;:::o;988:113::-;1058:4;1090;1085:3;1081:14;1073:22;;988:113;;;:::o;1137:732::-;1256:3;1285:54;1333:5;1285:54;:::i;:::-;1355:86;1434:6;1429:3;1355:86;:::i;:::-;1348:93;;1465:56;1515:5;1465:56;:::i;:::-;1544:7;1575:1;1560:284;1585:6;1582:1;1579:13;1560:284;;;1661:6;1655:13;1688:63;1747:3;1732:13;1688:63;:::i;:::-;1681:70;;1774:60;1827:6;1774:60;:::i;:::-;1764:70;;1620:224;1607:1;1604;1600:9;1595:14;;1560:284;;;1564:14;1860:3;1853:10;;1261:608;;;1137:732;;;;:::o;1875:373::-;2018:4;2056:2;2045:9;2041:18;2033:26;;2105:9;2099:4;2095:20;2091:1;2080:9;2076:17;2069:47;2133:108;2236:4;2227:6;2133:108;:::i;:::-;2125:116;;1875:373;;;;:::o;2254:145::-;2352:6;2386:5;2380:12;2370:22;;2254:145;;;:::o;2405:215::-;2535:11;2569:6;2564:3;2557:19;2609:4;2604:3;2600:14;2585:29;;2405:215;;;;:::o;2626:163::-;2724:4;2747:3;2739:11;;2777:4;2772:3;2768:14;2760:22;;2626:163;;;:::o;2795:124::-;2872:6;2906:5;2900:12;2890:22;;2795:124;;;:::o;2925:184::-;3024:11;3058:6;3053:3;3046:19;3098:4;3093:3;3089:14;3074:29;;2925:184;;;;:::o;3115:142::-;3192:4;3215:3;3207:11;;3245:4;3240:3;3236:14;3228:22;;3115:142;;;:::o;3263:99::-;3315:6;3349:5;3343:12;3333:22;;3263:99;;;:::o;3368:159::-;3442:11;3476:6;3471:3;3464:19;3516:4;3511:3;3507:14;3492:29;;3368:159;;;;:::o;3533:248::-;3615:1;3625:113;3639:6;3636:1;3633:13;3625:113;;;3724:1;3719:3;3715:11;3709:18;3705:1;3700:3;3696:11;3689:39;3661:2;3658:1;3654:10;3649:15;;3625:113;;;3772:1;3763:6;3758:3;3754:16;3747:27;3595:186;3533:248;;;:::o;3787:102::-;3828:6;3879:2;3875:7;3870:2;3863:5;3859:14;3855:28;3845:38;;3787:102;;;:::o;3895:357::-;3973:3;4001:39;4034:5;4001:39;:::i;:::-;4056:61;4110:6;4105:3;4056:61;:::i;:::-;4049:68;;4126:65;4184:6;4179:3;4172:4;4165:5;4161:16;4126:65;:::i;:::-;4216:29;4238:6;4216:29;:::i;:::-;4211:3;4207:39;4200:46;;3977:275;3895:357;;;;:::o;4258:196::-;4347:10;4382:66;4444:3;4436:6;4382:66;:::i;:::-;4368:80;;4258:196;;;;:::o;4460:123::-;4540:4;4572;4567:3;4563:14;4555:22;;4460:123;;;:::o;4617:971::-;4746:3;4775:64;4833:5;4775:64;:::i;:::-;4855:86;4934:6;4929:3;4855:86;:::i;:::-;4848:93;;4967:3;5012:4;5004:6;5000:17;4995:3;4991:27;5042:66;5102:5;5042:66;:::i;:::-;5131:7;5162:1;5147:396;5172:6;5169:1;5166:13;5147:396;;;5243:9;5237:4;5233:20;5228:3;5221:33;5294:6;5288:13;5322:84;5401:4;5386:13;5322:84;:::i;:::-;5314:92;;5429:70;5492:6;5429:70;:::i;:::-;5419:80;;5528:4;5523:3;5519:14;5512:21;;5207:336;5194:1;5191;5187:9;5182:14;;5147:396;;;5151:14;5559:4;5552:11;;5579:3;5572:10;;4751:837;;;;;4617:971;;;;:::o;5672:663::-;5793:3;5829:4;5824:3;5820:14;5916:4;5909:5;5905:16;5899:23;5935:63;5992:4;5987:3;5983:14;5969:12;5935:63;:::i;:::-;5844:164;6095:4;6088:5;6084:16;6078:23;6148:3;6142:4;6138:14;6131:4;6126:3;6122:14;6115:38;6174:123;6292:4;6278:12;6174:123;:::i;:::-;6166:131;;6018:290;6325:4;6318:11;;5798:537;5672:663;;;;:::o;6341:280::-;6472:10;6507:108;6611:3;6603:6;6507:108;:::i;:::-;6493:122;;6341:280;;;;:::o;6627:144::-;6728:4;6760;6755:3;6751:14;6743:22;;6627:144;;;:::o;6859:1159::-;7040:3;7069:85;7148:5;7069:85;:::i;:::-;7170:117;7280:6;7275:3;7170:117;:::i;:::-;7163:124;;7313:3;7358:4;7350:6;7346:17;7341:3;7337:27;7388:87;7469:5;7388:87;:::i;:::-;7498:7;7529:1;7514:459;7539:6;7536:1;7533:13;7514:459;;;7610:9;7604:4;7600:20;7595:3;7588:33;7661:6;7655:13;7689:126;7810:4;7795:13;7689:126;:::i;:::-;7681:134;;7838:91;7922:6;7838:91;:::i;:::-;7828:101;;7958:4;7953:3;7949:14;7942:21;;7574:399;7561:1;7558;7554:9;7549:14;;7514:459;;;7518:14;7989:4;7982:11;;8009:3;8002:10;;7045:973;;;;;6859:1159;;;;:::o;8024:497::-;8229:4;8267:2;8256:9;8252:18;8244:26;;8316:9;8310:4;8306:20;8302:1;8291:9;8287:17;8280:47;8344:170;8509:4;8500:6;8344:170;:::i;:::-;8336:178;;8024:497;;;;:::o;8527:75::-;8560:6;8593:2;8587:9;8577:19;;8527:75;:::o;8608:117::-;8717:1;8714;8707:12;8731:117;8840:1;8837;8830:12;8854:150;8891:7;8931:66;8924:5;8920:78;8909:89;;8854:150;;;:::o;9010:122::-;9083:24;9101:5;9083:24;:::i;:::-;9076:5;9073:35;9063:63;;9122:1;9119;9112:12;9063:63;9010:122;:::o;9138:139::-;9184:5;9222:6;9209:20;9200:29;;9238:33;9265:5;9238:33;:::i;:::-;9138:139;;;;:::o;9283:122::-;9356:24;9374:5;9356:24;:::i;:::-;9349:5;9346:35;9336:63;;9395:1;9392;9385:12;9336:63;9283:122;:::o;9411:139::-;9457:5;9495:6;9482:20;9473:29;;9511:33;9538:5;9511:33;:::i;:::-;9411:139;;;;:::o;9556:117::-;9665:1;9662;9655:12;9679:117;9788:1;9785;9778:12;9802:180;9850:77;9847:1;9840:88;9947:4;9944:1;9937:15;9971:4;9968:1;9961:15;9988:281;10071:27;10093:4;10071:27;:::i;:::-;10063:6;10059:40;10201:6;10189:10;10186:22;10165:18;10153:10;10150:34;10147:62;10144:88;;;10212:18;;:::i;:::-;10144:88;10252:10;10248:2;10241:22;10031:238;9988:281;;:::o;10275:129::-;10309:6;10336:20;;:::i;:::-;10326:30;;10365:33;10393:4;10385:6;10365:33;:::i;:::-;10275:129;;;:::o;10410:308::-;10472:4;10562:18;10554:6;10551:30;10548:56;;;10584:18;;:::i;:::-;10548:56;10622:29;10644:6;10622:29;:::i;:::-;10614:37;;10706:4;10700;10696:15;10688:23;;10410:308;;;:::o;10724:148::-;10822:6;10817:3;10812;10799:30;10863:1;10854:6;10849:3;10845:16;10838:27;10724:148;;;:::o;10878:425::-;10956:5;10981:66;10997:49;11039:6;10997:49;:::i;:::-;10981:66;:::i;:::-;10972:75;;11070:6;11063:5;11056:21;11108:4;11101:5;11097:16;11146:3;11137:6;11132:3;11128:16;11125:25;11122:112;;;11153:79;;:::i;:::-;11122:112;11243:54;11290:6;11285:3;11280;11243:54;:::i;:::-;10962:341;10878:425;;;;;:::o;11323:340::-;11379:5;11428:3;11421:4;11413:6;11409:17;11405:27;11395:122;;11436:79;;:::i;:::-;11395:122;11553:6;11540:20;11578:79;11653:3;11645:6;11638:4;11630:6;11626:17;11578:79;:::i;:::-;11569:88;;11385:278;11323:340;;;;:::o;11669:117::-;11778:1;11775;11768:12;11792:117;11901:1;11898;11891:12;11915:149;11951:7;11991:66;11984:5;11980:78;11969:89;;11915:149;;;:::o;12070:120::-;12142:23;12159:5;12142:23;:::i;:::-;12135:5;12132:34;12122:62;;12180:1;12177;12170:12;12122:62;12070:120;:::o;12196:137::-;12241:5;12279:6;12266:20;12257:29;;12295:32;12321:5;12295:32;:::i;:::-;12196:137;;;;:::o;12339:77::-;12376:7;12405:5;12394:16;;12339:77;;;:::o;12422:122::-;12495:24;12513:5;12495:24;:::i;:::-;12488:5;12485:35;12475:63;;12534:1;12531;12524:12;12475:63;12422:122;:::o;12550:139::-;12596:5;12634:6;12621:20;12612:29;;12650:33;12677:5;12650:33;:::i;:::-;12550:139;;;;:::o;12695:307::-;12756:4;12846:18;12838:6;12835:30;12832:56;;;12868:18;;:::i;:::-;12832:56;12906:29;12928:6;12906:29;:::i;:::-;12898:37;;12990:4;12984;12980:15;12972:23;;12695:307;;;:::o;13008:423::-;13085:5;13110:65;13126:48;13167:6;13126:48;:::i;:::-;13110:65;:::i;:::-;13101:74;;13198:6;13191:5;13184:21;13236:4;13229:5;13225:16;13274:3;13265:6;13260:3;13256:16;13253:25;13250:112;;;13281:79;;:::i;:::-;13250:112;13371:54;13418:6;13413:3;13408;13371:54;:::i;:::-;13091:340;13008:423;;;;;:::o;13450:338::-;13505:5;13554:3;13547:4;13539:6;13535:17;13531:27;13521:122;;13562:79;;:::i;:::-;13521:122;13679:6;13666:20;13704:78;13778:3;13770:6;13763:4;13755:6;13751:17;13704:78;:::i;:::-;13695:87;;13511:277;13450:338;;;;:::o;13794:101::-;13830:7;13870:18;13863:5;13859:30;13848:41;;13794:101;;;:::o;13901:120::-;13973:23;13990:5;13973:23;:::i;:::-;13966:5;13963:34;13953:62;;14011:1;14008;14001:12;13953:62;13901:120;:::o;14027:137::-;14072:5;14110:6;14097:20;14088:29;;14126:32;14152:5;14126:32;:::i;:::-;14027:137;;;;:::o;14193:756::-;14269:5;14313:4;14301:9;14296:3;14292:19;14288:30;14285:117;;;14321:79;;:::i;:::-;14285:117;14420:21;14436:4;14420:21;:::i;:::-;14411:30;;14535:1;14524:9;14520:17;14507:31;14565:18;14557:6;14554:30;14551:117;;;14587:79;;:::i;:::-;14551:117;14707:59;14762:3;14753:6;14742:9;14738:22;14707:59;:::i;:::-;14700:4;14693:5;14689:16;14682:85;14451:327;14841:2;14882:48;14926:3;14917:6;14906:9;14902:22;14882:48;:::i;:::-;14875:4;14868:5;14864:16;14857:74;14788:154;14193:756;;;;:::o;14981:1627::-;15060:5;15104:4;15092:9;15087:3;15083:19;15079:30;15076:117;;;15112:79;;:::i;:::-;15076:117;15211:21;15227:4;15211:21;:::i;:::-;15202:30;;15301:1;15341:49;15386:3;15377:6;15366:9;15362:22;15341:49;:::i;:::-;15334:4;15327:5;15323:16;15316:75;15242:160;15469:2;15510:48;15554:3;15545:6;15534:9;15530:22;15510:48;:::i;:::-;15503:4;15496:5;15492:16;15485:74;15412:158;15635:2;15676:49;15721:3;15712:6;15701:9;15697:22;15676:49;:::i;:::-;15669:4;15662:5;15658:16;15651:75;15580:157;15804:2;15845:49;15890:3;15881:6;15870:9;15866:22;15845:49;:::i;:::-;15838:4;15831:5;15827:16;15820:75;15747:159;16004:3;15993:9;15989:19;15976:33;16036:18;16028:6;16025:30;16022:117;;;16058:79;;:::i;:::-;16022:117;16178:58;16232:3;16223:6;16212:9;16208:22;16178:58;:::i;:::-;16171:4;16164:5;16160:16;16153:84;15916:332;16339:3;16328:9;16324:19;16311:33;16371:18;16363:6;16360:30;16357:117;;;16393:79;;:::i;:::-;16357:117;16513:76;16585:3;16576:6;16565:9;16561:22;16513:76;:::i;:::-;16506:4;16499:5;16495:16;16488:102;16258:343;14981:1627;;;;:::o;16614:77::-;16651:7;16680:5;16669:16;;16614:77;;;:::o;16697:122::-;16770:24;16788:5;16770:24;:::i;:::-;16763:5;16760:35;16750:63;;16809:1;16806;16799:12;16750:63;16697:122;:::o;16825:139::-;16871:5;16909:6;16896:20;16887:29;;16925:33;16952:5;16925:33;:::i;:::-;16825:139;;;;:::o;16970:90::-;17004:7;17047:5;17040:13;17033:21;17022:32;;16970:90;;;:::o;17066:116::-;17136:21;17151:5;17136:21;:::i;:::-;17129:5;17126:32;17116:60;;17172:1;17169;17162:12;17116:60;17066:116;:::o;17188:133::-;17231:5;17269:6;17256:20;17247:29;;17285:30;17309:5;17285:30;:::i;:::-;17188:133;;;;:::o;17354:1573::-;17426:5;17470:4;17458:9;17453:3;17449:19;17445:30;17442:117;;;17478:79;;:::i;:::-;17442:117;17577:21;17593:4;17577:21;:::i;:::-;17568:30;;17655:1;17695:49;17740:3;17731:6;17720:9;17716:22;17695:49;:::i;:::-;17688:4;17681:5;17677:16;17670:75;17608:148;17816:2;17857:49;17902:3;17893:6;17882:9;17878:22;17857:49;:::i;:::-;17850:4;17843:5;17839:16;17832:75;17766:152;18005:2;17994:9;17990:18;17977:32;18036:18;18028:6;18025:30;18022:117;;;18058:79;;:::i;:::-;18022:117;18178:58;18232:3;18223:6;18212:9;18208:22;18178:58;:::i;:::-;18171:4;18164:5;18160:16;18153:84;17928:320;18311:2;18352:49;18397:3;18388:6;18377:9;18373:22;18352:49;:::i;:::-;18345:4;18338:5;18334:16;18327:75;18258:155;18480:3;18522:46;18564:3;18555:6;18544:9;18540:22;18522:46;:::i;:::-;18515:4;18508:5;18504:16;18497:72;18423:157;18647:3;18689:46;18731:3;18722:6;18711:9;18707:22;18689:46;:::i;:::-;18682:4;18675:5;18671:16;18664:72;18590:157;18817:3;18859:49;18904:3;18895:6;18884:9;18880:22;18859:49;:::i;:::-;18852:4;18845:5;18841:16;18834:75;18757:163;17354:1573;;;;:::o;18933:1663::-;19100:6;19108;19116;19124;19132;19140;19189:3;19177:9;19168:7;19164:23;19160:33;19157:120;;;19196:79;;:::i;:::-;19157:120;19316:1;19341:53;19386:7;19377:6;19366:9;19362:22;19341:53;:::i;:::-;19331:63;;19287:117;19443:2;19469:53;19514:7;19505:6;19494:9;19490:22;19469:53;:::i;:::-;19459:63;;19414:118;19599:2;19588:9;19584:18;19571:32;19630:18;19622:6;19619:30;19616:117;;;19652:79;;:::i;:::-;19616:117;19757:63;19812:7;19803:6;19792:9;19788:22;19757:63;:::i;:::-;19747:73;;19542:288;19897:2;19886:9;19882:18;19869:32;19928:18;19920:6;19917:30;19914:117;;;19950:79;;:::i;:::-;19914:117;20055:83;20130:7;20121:6;20110:9;20106:22;20055:83;:::i;:::-;20045:93;;19840:308;20187:3;20214:53;20259:7;20250:6;20239:9;20235:22;20214:53;:::i;:::-;20204:63;;20158:119;20344:3;20333:9;20329:19;20316:33;20376:18;20368:6;20365:30;20362:117;;;20398:79;;:::i;:::-;20362:117;20503:76;20571:7;20562:6;20551:9;20547:22;20503:76;:::i;:::-;20493:86;;20287:302;18933:1663;;;;;;;;:::o;20602:1517::-;20760:6;20768;20776;20784;20792;20841:3;20829:9;20820:7;20816:23;20812:33;20809:120;;;20848:79;;:::i;:::-;20809:120;20968:1;20993:53;21038:7;21029:6;21018:9;21014:22;20993:53;:::i;:::-;20983:63;;20939:117;21123:2;21112:9;21108:18;21095:32;21154:18;21146:6;21143:30;21140:117;;;21176:79;;:::i;:::-;21140:117;21281:63;21336:7;21327:6;21316:9;21312:22;21281:63;:::i;:::-;21271:73;;21066:288;21421:2;21410:9;21406:18;21393:32;21452:18;21444:6;21441:30;21438:117;;;21474:79;;:::i;:::-;21438:117;21579:83;21654:7;21645:6;21634:9;21630:22;21579:83;:::i;:::-;21569:93;;21364:308;21711:2;21737:53;21782:7;21773:6;21762:9;21758:22;21737:53;:::i;:::-;21727:63;;21682:118;21867:3;21856:9;21852:19;21839:33;21899:18;21891:6;21888:30;21885:117;;;21921:79;;:::i;:::-;21885:117;22026:76;22094:7;22085:6;22074:9;22070:22;22026:76;:::i;:::-;22016:86;;21810:302;20602:1517;;;;;;;;:::o;22125:152::-;22230:6;22264:5;22258:12;22248:22;;22125:152;;;:::o;22283:222::-;22420:11;22454:6;22449:3;22442:19;22494:4;22489:3;22485:14;22470:29;;22283:222;;;;:::o;22511:170::-;22616:4;22639:3;22631:11;;22669:4;22664:3;22660:14;22652:22;;22511:170;;;:::o;22687:113::-;22753:6;22787:5;22781:12;22771:22;;22687:113;;;:::o;22806:173::-;22894:11;22928:6;22923:3;22916:19;22968:4;22963:3;22959:14;22944:29;;22806:173;;;;:::o;22985:131::-;23051:4;23074:3;23066:11;;23104:4;23099:3;23095:14;23087:22;;22985:131;;;:::o;23122:105::-;23197:23;23214:5;23197:23;:::i;:::-;23192:3;23185:36;23122:105;;:::o;23233:175::-;23300:10;23321:44;23361:3;23353:6;23321:44;:::i;:::-;23397:4;23392:3;23388:14;23374:28;;23233:175;;;;:::o;23414:112::-;23483:4;23515;23510:3;23506:14;23498:22;;23414:112;;;:::o;23560:704::-;23667:3;23696:53;23743:5;23696:53;:::i;:::-;23765:75;23833:6;23828:3;23765:75;:::i;:::-;23758:82;;23864:55;23913:5;23864:55;:::i;:::-;23942:7;23973:1;23958:281;23983:6;23980:1;23977:13;23958:281;;;24059:6;24053:13;24086:61;24143:3;24128:13;24086:61;:::i;:::-;24079:68;;24170:59;24222:6;24170:59;:::i;:::-;24160:69;;24018:221;24005:1;24002;23998:9;23993:14;;23958:281;;;23962:14;24255:3;24248:10;;23672:592;;;23560:704;;;;:::o;24362:730::-;24497:3;24533:4;24528:3;24524:14;24624:4;24617:5;24613:16;24607:23;24677:3;24671:4;24667:14;24660:4;24655:3;24651:14;24644:38;24703:73;24771:4;24757:12;24703:73;:::i;:::-;24695:81;;24548:239;24874:4;24867:5;24863:16;24857:23;24927:3;24921:4;24917:14;24910:4;24905:3;24901:14;24894:38;24953:101;25049:4;25035:12;24953:101;:::i;:::-;24945:109;;24797:268;25082:4;25075:11;;24502:590;24362:730;;;;:::o;25098:308::-;25243:10;25278:122;25396:3;25388:6;25278:122;:::i;:::-;25264:136;;25098:308;;;;:::o;25412:151::-;25520:4;25552;25547:3;25543:14;25535:22;;25412:151;;;:::o;25665:1215::-;25860:3;25889:92;25975:5;25889:92;:::i;:::-;25997:124;26114:6;26109:3;25997:124;:::i;:::-;25990:131;;26147:3;26192:4;26184:6;26180:17;26175:3;26171:27;26222:94;26310:5;26222:94;:::i;:::-;26339:7;26370:1;26355:480;26380:6;26377:1;26374:13;26355:480;;;26451:9;26445:4;26441:20;26436:3;26429:33;26502:6;26496:13;26530:140;26665:4;26650:13;26530:140;:::i;:::-;26522:148;;26693:98;26784:6;26693:98;:::i;:::-;26683:108;;26820:4;26815:3;26811:14;26804:21;;26415:420;26402:1;26399;26395:9;26390:14;;26355:480;;;26359:14;26851:4;26844:11;;26871:3;26864:10;;25865:1015;;;;;25665:1215;;;;:::o;26886:525::-;27105:4;27143:2;27132:9;27128:18;27120:26;;27192:9;27186:4;27182:20;27178:1;27167:9;27163:17;27156:47;27220:184;27399:4;27390:6;27220:184;:::i;:::-;27212:192;;26886:525;;;;:::o;27417:60::-;27445:3;27466:5;27459:12;;27417:60;;;:::o;27483:142::-;27533:9;27566:53;27584:34;27593:24;27611:5;27593:24;:::i;:::-;27584:34;:::i;:::-;27566:53;:::i;:::-;27553:66;;27483:142;;;:::o;27631:126::-;27681:9;27714:37;27745:5;27714:37;:::i;:::-;27701:50;;27631:126;;;:::o;27763:159::-;27846:9;27879:37;27910:5;27879:37;:::i;:::-;27866:50;;27763:159;;;:::o;27928:197::-;28048:70;28112:5;28048:70;:::i;:::-;28043:3;28036:83;27928:197;;:::o;28131:288::-;28257:4;28295:2;28284:9;28280:18;28272:26;;28308:104;28409:1;28398:9;28394:17;28385:6;28308:104;:::i;:::-;28131:288;;;;:::o;28425:159::-;28508:9;28541:37;28572:5;28541:37;:::i;:::-;28528:50;;28425:159;;;:::o;28590:197::-;28710:70;28774:5;28710:70;:::i;:::-;28705:3;28698:83;28590:197;;:::o;28793:288::-;28919:4;28957:2;28946:9;28942:18;28934:26;;28970:104;29071:1;29060:9;29056:17;29047:6;28970:104;:::i;:::-;28793:288;;;;:::o;29087:194::-;29196:11;29230:6;29225:3;29218:19;29270:4;29265:3;29261:14;29246:29;;29087:194;;;;:::o;29315:991::-;29454:3;29483:64;29541:5;29483:64;:::i;:::-;29563:96;29652:6;29647:3;29563:96;:::i;:::-;29556:103;;29685:3;29730:4;29722:6;29718:17;29713:3;29709:27;29760:66;29820:5;29760:66;:::i;:::-;29849:7;29880:1;29865:396;29890:6;29887:1;29884:13;29865:396;;;29961:9;29955:4;29951:20;29946:3;29939:33;30012:6;30006:13;30040:84;30119:4;30104:13;30040:84;:::i;:::-;30032:92;;30147:70;30210:6;30147:70;:::i;:::-;30137:80;;30246:4;30241:3;30237:14;30230:21;;29925:336;29912:1;29909;29905:9;29900:14;;29865:396;;;29869:14;30277:4;30270:11;;30297:3;30290:10;;29459:847;;;;;29315:991;;;;:::o;30312:413::-;30475:4;30513:2;30502:9;30498:18;30490:26;;30562:9;30556:4;30552:20;30548:1;30537:9;30533:17;30526:47;30590:128;30713:4;30704:6;30590:128;:::i;:::-;30582:136;;30312:413;;;;:::o;30731:321::-;30818:4;30908:18;30900:6;30897:30;30894:56;;;30930:18;;:::i;:::-;30894:56;30980:4;30972:6;30968:17;30960:25;;31040:4;31034;31030:15;31022:23;;30731:321;;;:::o;31058:117::-;31167:1;31164;31157:12;31197:945;31303:5;31328:91;31344:74;31411:6;31344:74;:::i;:::-;31328:91;:::i;:::-;31319:100;;31439:5;31468:6;31461:5;31454:21;31502:4;31495:5;31491:16;31484:23;;31555:4;31547:6;31543:17;31535:6;31531:30;31584:3;31576:6;31573:15;31570:122;;;31603:79;;:::i;:::-;31570:122;31718:6;31701:435;31735:6;31730:3;31727:15;31701:435;;;31824:3;31811:17;31860:18;31847:11;31844:35;31841:122;;;31882:79;;:::i;:::-;31841:122;32006:11;31998:6;31994:24;32044:47;32087:3;32075:10;32044:47;:::i;:::-;32039:3;32032:60;32121:4;32116:3;32112:14;32105:21;;31777:359;;31761:4;31756:3;31752:14;31745:21;;31701:435;;;31705:21;31309:833;;31197:945;;;;;:::o;32164:390::-;32245:5;32294:3;32287:4;32279:6;32275:17;32271:27;32261:122;;32302:79;;:::i;:::-;32261:122;32419:6;32406:20;32444:104;32544:3;32536:6;32529:4;32521:6;32517:17;32444:104;:::i;:::-;32435:113;;32251:303;32164:390;;;;:::o;32560:1859::-;32761:6;32769;32777;32785;32793;32801;32809;32858:3;32846:9;32837:7;32833:23;32829:33;32826:120;;;32865:79;;:::i;:::-;32826:120;32985:1;33010:53;33055:7;33046:6;33035:9;33031:22;33010:53;:::i;:::-;33000:63;;32956:117;33112:2;33138:53;33183:7;33174:6;33163:9;33159:22;33138:53;:::i;:::-;33128:63;;33083:118;33268:2;33257:9;33253:18;33240:32;33299:18;33291:6;33288:30;33285:117;;;33321:79;;:::i;:::-;33285:117;33426:88;33506:7;33497:6;33486:9;33482:22;33426:88;:::i;:::-;33416:98;;33211:313;33563:2;33589:53;33634:7;33625:6;33614:9;33610:22;33589:53;:::i;:::-;33579:63;;33534:118;33719:3;33708:9;33704:19;33691:33;33751:18;33743:6;33740:30;33737:117;;;33773:79;;:::i;:::-;33737:117;33878:83;33953:7;33944:6;33933:9;33929:22;33878:83;:::i;:::-;33868:93;;33662:309;34010:3;34037:53;34082:7;34073:6;34062:9;34058:22;34037:53;:::i;:::-;34027:63;;33981:119;34167:3;34156:9;34152:19;34139:33;34199:18;34191:6;34188:30;34185:117;;;34221:79;;:::i;:::-;34185:117;34326:76;34394:7;34385:6;34374:9;34370:22;34326:76;:::i;:::-;34316:86;;34110:302;32560:1859;;;;;;;;;;:::o;34425:144::-;34522:6;34556:5;34550:12;34540:22;;34425:144;;;:::o;34575:214::-;34704:11;34738:6;34733:3;34726:19;34778:4;34773:3;34769:14;34754:29;;34575:214;;;;:::o;34795:162::-;34892:4;34915:3;34907:11;;34945:4;34940:3;34936:14;34928:22;;34795:162;;;:::o;35039:639::-;35158:3;35194:4;35189:3;35185:14;35281:4;35274:5;35270:16;35264:23;35300:63;35357:4;35352:3;35348:14;35334:12;35300:63;:::i;:::-;35209:164;35460:4;35453:5;35449:16;35443:23;35513:3;35507:4;35503:14;35496:4;35491:3;35487:14;35480:38;35539:101;35635:4;35621:12;35539:101;:::i;:::-;35531:109;;35383:268;35668:4;35661:11;;35163:515;35039:639;;;;:::o;35684:276::-;35813:10;35848:106;35950:3;35942:6;35848:106;:::i;:::-;35834:120;;35684:276;;;;:::o;35966:143::-;36066:4;36098;36093:3;36089:14;36081:22;;35966:143;;;:::o;36195:1151::-;36374:3;36403:84;36481:5;36403:84;:::i;:::-;36503:116;36612:6;36607:3;36503:116;:::i;:::-;36496:123;;36645:3;36690:4;36682:6;36678:17;36673:3;36669:27;36720:86;36800:5;36720:86;:::i;:::-;36829:7;36860:1;36845:456;36870:6;36867:1;36864:13;36845:456;;;36941:9;36935:4;36931:20;36926:3;36919:33;36992:6;36986:13;37020:124;37139:4;37124:13;37020:124;:::i;:::-;37012:132;;37167:90;37250:6;37167:90;:::i;:::-;37157:100;;37286:4;37281:3;37277:14;37270:21;;36905:396;36892:1;36889;36885:9;36880:14;;36845:456;;;36849:14;37317:4;37310:11;;37337:3;37330:10;;36379:967;;;;;36195:1151;;;;:::o;37352:493::-;37555:4;37593:2;37582:9;37578:18;37570:26;;37642:9;37636:4;37632:20;37628:1;37617:9;37613:17;37606:47;37670:168;37833:4;37824:6;37670:168;:::i;:::-;37662:176;;37352:493;;;;:::o;37851:329::-;37910:6;37959:2;37947:9;37938:7;37934:23;37930:32;37927:119;;;37965:79;;:::i;:::-;37927:119;38085:1;38110:53;38155:7;38146:6;38135:9;38131:22;38110:53;:::i;:::-;38100:63;;38056:117;37851:329;;;;:::o;38186:109::-;38267:21;38282:5;38267:21;:::i;:::-;38262:3;38255:34;38186:109;;:::o;38301:210::-;38388:4;38426:2;38415:9;38411:18;38403:26;;38439:65;38501:1;38490:9;38486:17;38477:6;38439:65;:::i;:::-;38301:210;;;;:::o;38517:180::-;38565:77;38562:1;38555:88;38662:4;38659:1;38652:15;38686:4;38683:1;38676:15;38703:320;38747:6;38784:1;38778:4;38774:12;38764:22;;38831:1;38825:4;38821:12;38852:18;38842:81;;38908:4;38900:6;38896:17;38886:27;;38842:81;38970:2;38962:6;38959:14;38939:18;38936:38;38933:84;;38989:18;;:::i;:::-;38933:84;38754:269;38703:320;;;:::o;39029:118::-;39116:24;39134:5;39116:24;:::i;:::-;39111:3;39104:37;39029:118;;:::o;39153:222::-;39246:4;39284:2;39273:9;39269:18;39261:26;;39297:71;39365:1;39354:9;39350:17;39341:6;39297:71;:::i;:::-;39153:222;;;;:::o;39381:118::-;39468:24;39486:5;39468:24;:::i;:::-;39463:3;39456:37;39381:118;;:::o;39505:222::-;39598:4;39636:2;39625:9;39621:18;39613:26;;39649:71;39717:1;39706:9;39702:17;39693:6;39649:71;:::i;:::-;39505:222;;;;:::o;39733:143::-;39790:5;39821:6;39815:13;39806:22;;39837:33;39864:5;39837:33;:::i;:::-;39733:143;;;;:::o;39882:351::-;39952:6;40001:2;39989:9;39980:7;39976:23;39972:32;39969:119;;;40007:79;;:::i;:::-;39969:119;40127:1;40152:64;40208:7;40199:6;40188:9;40184:22;40152:64;:::i;:::-;40142:74;;40098:128;39882:351;;;;:::o;40239:118::-;40326:24;40344:5;40326:24;:::i;:::-;40321:3;40314:37;40239:118;;:::o;40363:169::-;40447:11;40481:6;40476:3;40469:19;40521:4;40516:3;40512:14;40497:29;;40363:169;;;;:::o;40538:377::-;40626:3;40654:39;40687:5;40654:39;:::i;:::-;40709:71;40773:6;40768:3;40709:71;:::i;:::-;40702:78;;40789:65;40847:6;40842:3;40835:4;40828:5;40824:16;40789:65;:::i;:::-;40879:29;40901:6;40879:29;:::i;:::-;40874:3;40870:39;40863:46;;40630:285;40538:377;;;;:::o;40921:423::-;41062:4;41100:2;41089:9;41085:18;41077:26;;41113:71;41181:1;41170:9;41166:17;41157:6;41113:71;:::i;:::-;41231:9;41225:4;41221:20;41216:2;41205:9;41201:18;41194:48;41259:78;41332:4;41323:6;41259:78;:::i;:::-;41251:86;;40921:423;;;;;:::o;41350:332::-;41471:4;41509:2;41498:9;41494:18;41486:26;;41522:71;41590:1;41579:9;41575:17;41566:6;41522:71;:::i;:::-;41603:72;41671:2;41660:9;41656:18;41647:6;41603:72;:::i;:::-;41350:332;;;;;:::o;41688:108::-;41765:24;41783:5;41765:24;:::i;:::-;41760:3;41753:37;41688:108;;:::o;41802:98::-;41853:6;41887:5;41881:12;41871:22;;41802:98;;;:::o;41906:158::-;41979:11;42013:6;42008:3;42001:19;42053:4;42048:3;42044:14;42029:29;;41906:158;;;;:::o;42070:353::-;42146:3;42174:38;42206:5;42174:38;:::i;:::-;42228:60;42281:6;42276:3;42228:60;:::i;:::-;42221:67;;42297:65;42355:6;42350:3;42343:4;42336:5;42332:16;42297:65;:::i;:::-;42387:29;42409:6;42387:29;:::i;:::-;42382:3;42378:39;42371:46;;42150:273;42070:353;;;;:::o;42429:105::-;42504:23;42521:5;42504:23;:::i;:::-;42499:3;42492:36;42429:105;;:::o;42582:609::-;42695:3;42731:4;42726:3;42722:14;42825:4;42818:5;42814:16;42808:23;42878:3;42872:4;42868:14;42861:4;42856:3;42852:14;42845:38;42904:73;42972:4;42958:12;42904:73;:::i;:::-;42896:81;;42746:242;43074:4;43067:5;43063:16;43057:23;43093:61;43148:4;43143:3;43139:14;43125:12;43093:61;:::i;:::-;42998:166;43181:4;43174:11;;42700:491;42582:609;;;;:::o;43245:1460::-;43374:3;43410:4;43405:3;43401:14;43507:4;43500:5;43496:16;43490:23;43526:63;43583:4;43578:3;43574:14;43560:12;43526:63;:::i;:::-;43425:174;43689:4;43682:5;43678:16;43672:23;43708:61;43763:4;43758:3;43754:14;43740:12;43708:61;:::i;:::-;43609:170;43867:4;43860:5;43856:16;43850:23;43886:63;43943:4;43938:3;43934:14;43920:12;43886:63;:::i;:::-;43789:170;44049:4;44042:5;44038:16;44032:23;44068:63;44125:4;44120:3;44116:14;44102:12;44068:63;:::i;:::-;43969:172;44234:4;44227:5;44223:16;44217:23;44287:3;44281:4;44277:14;44270:4;44265:3;44261:14;44254:38;44313:71;44379:4;44365:12;44313:71;:::i;:::-;44305:79;;44151:244;44481:4;44474:5;44470:16;44464:23;44534:3;44528:4;44524:14;44517:4;44512:3;44508:14;44501:38;44560:107;44662:4;44648:12;44560:107;:::i;:::-;44552:115;;44405:273;44695:4;44688:11;;43379:1326;43245:1460;;;;:::o;44711:108::-;44788:24;44806:5;44788:24;:::i;:::-;44783:3;44776:37;44711:108;;:::o;44825:99::-;44896:21;44911:5;44896:21;:::i;:::-;44891:3;44884:34;44825:99;;:::o;44980:1488::-;45095:3;45131:4;45126:3;45122:14;45216:4;45209:5;45205:16;45199:23;45235:63;45292:4;45287:3;45283:14;45269:12;45235:63;:::i;:::-;45146:162;45391:4;45384:5;45380:16;45374:23;45410:63;45467:4;45462:3;45458:14;45444:12;45410:63;:::i;:::-;45318:165;45565:4;45558:5;45554:16;45548:23;45618:3;45612:4;45608:14;45601:4;45596:3;45592:14;45585:38;45644:71;45710:4;45696:12;45644:71;:::i;:::-;45636:79;;45493:233;45812:4;45805:5;45801:16;45795:23;45831:63;45888:4;45883:3;45879:14;45865:12;45831:63;:::i;:::-;45736:168;45994:4;45987:5;45983:16;45977:23;46013:57;46064:4;46059:3;46055:14;46041:12;46013:57;:::i;:::-;45914:166;46170:4;46163:5;46159:16;46153:23;46189:57;46240:4;46235:3;46231:14;46217:12;46189:57;:::i;:::-;46090:166;46349:4;46342:5;46338:16;46332:23;46368:63;46425:4;46420:3;46416:14;46402:12;46368:63;:::i;:::-;46266:175;46458:4;46451:11;;45100:1368;44980:1488;;;;:::o;46474:756::-;46729:4;46767:2;46756:9;46752:18;46744:26;;46780:71;46848:1;46837:9;46833:17;46824:6;46780:71;:::i;:::-;46898:9;46892:4;46888:20;46883:2;46872:9;46868:18;46861:48;46926:118;47039:4;47030:6;46926:118;:::i;:::-;46918:126;;47091:9;47085:4;47081:20;47076:2;47065:9;47061:18;47054:48;47119:104;47218:4;47209:6;47119:104;:::i;:::-;47111:112;;46474:756;;;;;;:::o;47236:168::-;47319:11;47353:6;47348:3;47341:19;47393:4;47388:3;47384:14;47369:29;;47236:168;;;;:::o;47410:373::-;47496:3;47524:38;47556:5;47524:38;:::i;:::-;47578:70;47641:6;47636:3;47578:70;:::i;:::-;47571:77;;47657:65;47715:6;47710:3;47703:4;47696:5;47692:16;47657:65;:::i;:::-;47747:29;47769:6;47747:29;:::i;:::-;47742:3;47738:39;47731:46;;47500:283;47410:373;;;;:::o;47789:309::-;47900:4;47938:2;47927:9;47923:18;47915:26;;47987:9;47981:4;47977:20;47973:1;47962:9;47958:17;47951:47;48015:76;48086:4;48077:6;48015:76;:::i;:::-;48007:84;;47789:309;;;;:::o;48104:180::-;48152:77;48149:1;48142:88;48249:4;48246:1;48239:15;48273:4;48270:1;48263:15;48290:194;48330:4;48350:20;48368:1;48350:20;:::i;:::-;48345:25;;48384:20;48402:1;48384:20;:::i;:::-;48379:25;;48428:1;48425;48421:9;48413:17;;48452:1;48446:4;48443:11;48440:37;;;48457:18;;:::i;:::-;48440:37;48290:194;;;;:::o;48490:180::-;48538:77;48535:1;48528:88;48635:4;48632:1;48625:15;48659:4;48656:1;48649:15;48676:115;48761:23;48778:5;48761:23;:::i;:::-;48756:3;48749:36;48676:115;;:::o;48797:218::-;48888:4;48926:2;48915:9;48911:18;48903:26;;48939:69;49005:1;48994:9;48990:17;48981:6;48939:69;:::i;:::-;48797:218;;;;:::o;49021:137::-;49075:5;49106:6;49100:13;49091:22;;49122:30;49146:5;49122:30;:::i;:::-;49021:137;;;;:::o;49164:345::-;49231:6;49280:2;49268:9;49259:7;49255:23;49251:32;49248:119;;;49286:79;;:::i;:::-;49248:119;49406:1;49431:61;49484:7;49475:6;49464:9;49460:22;49431:61;:::i;:::-;49421:71;;49377:125;49164:345;;;;:::o;49515:148::-;49617:11;49654:3;49639:18;;49515:148;;;;:::o;49669:171::-;49809:23;49805:1;49797:6;49793:14;49786:47;49669:171;:::o;49846:402::-;50006:3;50027:85;50109:2;50104:3;50027:85;:::i;:::-;50020:92;;50121:93;50210:3;50121:93;:::i;:::-;50239:2;50234:3;50230:12;50223:19;;49846:402;;;:::o;50254:381::-;50439:3;50461:148;50605:3;50461:148;:::i;:::-;50454:155;;50626:3;50619:10;;50254:381;;;:::o;50641:79::-;50680:7;50709:5;50698:16;;50641:79;;;:::o;50726:157::-;50831:45;50851:24;50869:5;50851:24;:::i;:::-;50831:45;:::i;:::-;50826:3;50819:58;50726:157;;:::o;50889:94::-;50922:8;50970:5;50966:2;50962:14;50941:35;;50889:94;;;:::o;50989:::-;51028:7;51057:20;51071:5;51057:20;:::i;:::-;51046:31;;50989:94;;;:::o;51089:100::-;51128:7;51157:26;51177:5;51157:26;:::i;:::-;51146:37;;51089:100;;;:::o;51195:157::-;51300:45;51320:24;51338:5;51320:24;:::i;:::-;51300:45;:::i;:::-;51295:3;51288:58;51195:157;;:::o;51358:679::-;51554:3;51569:75;51640:3;51631:6;51569:75;:::i;:::-;51669:2;51664:3;51660:12;51653:19;;51682:75;51753:3;51744:6;51682:75;:::i;:::-;51782:2;51777:3;51773:12;51766:19;;51795:75;51866:3;51857:6;51795:75;:::i;:::-;51895:2;51890:3;51886:12;51879:19;;51908:75;51979:3;51970:6;51908:75;:::i;:::-;52008:2;52003:3;51999:12;51992:19;;52028:3;52021:10;;51358:679;;;;;;;:::o;52043:332::-;52164:4;52202:2;52191:9;52187:18;52179:26;;52215:71;52283:1;52272:9;52268:17;52259:6;52215:71;:::i;:::-;52296:72;52364:2;52353:9;52349:18;52340:6;52296:72;:::i;:::-;52043:332;;;;;:::o;52381:233::-;52420:3;52443:24;52461:5;52443:24;:::i;:::-;52434:33;;52489:66;52482:5;52479:77;52476:103;;52559:18;;:::i;:::-;52476:103;52606:1;52599:5;52595:13;52588:20;;52381:233;;;:::o;52620:308::-;52729:4;52767:2;52756:9;52752:18;52744:26;;52780:65;52842:1;52831:9;52827:17;52818:6;52780:65;:::i;:::-;52855:66;52917:2;52906:9;52902:18;52893:6;52855:66;:::i;:::-;52620:308;;;;;:::o;52934:390::-;53040:3;53068:39;53101:5;53068:39;:::i;:::-;53123:89;53205:6;53200:3;53123:89;:::i;:::-;53116:96;;53221:65;53279:6;53274:3;53267:4;53260:5;53256:16;53221:65;:::i;:::-;53311:6;53306:3;53302:16;53295:23;;53044:280;52934:390;;;;:::o;53330:275::-;53462:3;53484:95;53575:3;53566:6;53484:95;:::i;:::-;53477:102;;53596:3;53589:10;;53330:275;;;;:::o;53611:249::-;53751:34;53747:1;53739:6;53735:14;53728:58;53820:32;53815:2;53807:6;53803:15;53796:57;53611:249;:::o;53866:366::-;54008:3;54029:67;54093:2;54088:3;54029:67;:::i;:::-;54022:74;;54105:93;54194:3;54105:93;:::i;:::-;54223:2;54218:3;54214:12;54207:19;;53866:366;;;:::o;54238:419::-;54404:4;54442:2;54431:9;54427:18;54419:26;;54491:9;54485:4;54481:20;54477:1;54466:9;54462:17;54455:47;54519:131;54645:4;54519:131;:::i;:::-;54511:139;;54238:419;;;:::o;54663:191::-;54703:3;54722:20;54740:1;54722:20;:::i;:::-;54717:25;;54756:20;54774:1;54756:20;:::i;:::-;54751:25;;54799:1;54796;54792:9;54785:16;;54820:3;54817:1;54814:10;54811:36;;;54827:18;;:::i;:::-;54811:36;54663:191;;;;:::o;54860:180::-;54908:77;54905:1;54898:88;55005:4;55002:1;54995:15;55029:4;55026:1;55019:15;55046:176;55078:1;55095:20;55113:1;55095:20;:::i;:::-;55090:25;;55129:20;55147:1;55129:20;:::i;:::-;55124:25;;55168:1;55158:35;;55173:18;;:::i;:::-;55158:35;55214:1;55211;55207:9;55202:14;;55046:176;;;;:::o;55228:118::-;55315:24;55333:5;55315:24;:::i;:::-;55310:3;55303:37;55228:118;;:::o;55352:423::-;55493:4;55531:2;55520:9;55516:18;55508:26;;55580:9;55574:4;55570:20;55566:1;55555:9;55551:17;55544:47;55608:78;55681:4;55672:6;55608:78;:::i;:::-;55600:86;;55696:72;55764:2;55753:9;55749:18;55740:6;55696:72;:::i;:::-;55352:423;;;;;:::o;55781:180::-;55829:77;55826:1;55819:88;55926:4;55923:1;55916:15;55950:4;55947:1;55940:15","linkReferences":{}},"methodIdentifiers":{"IS_TEST()":"fa7626d4","excludeArtifacts()":"b5508aa9","excludeContracts()":"e20c9f71","excludeSelectors()":"b0464fdc","excludeSenders()":"1ed7831c","failed()":"ba414fa6","registry()":"7b103999","setUp()":"0a9254e4","signalsImplicitMode()":"7aa3488f","targetArtifactSelectors()":"66d9a9a0","targetArtifacts()":"85226c81","targetContracts()":"3f7286f4","targetInterfaces()":"2ade3880","targetSelectors()":"916a17c6","targetSenders()":"3e5e3c23","test_acceptsValidUrl(bytes12,address,string,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),address,(address,uint256,bytes,uint256,bool,bool,uint256))":"2f237718","test_acceptsValidUrlFromMultiple(bytes12,address,string[],uint256,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),address,(address,uint256,bytes,uint256,bool,bool,uint256))":"90110f2d","test_rejectsInvalidUrl(bytes32,string,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),address,(address,uint256,bytes,uint256,bool,bool,uint256))":"50932724","test_supportsInterface(bytes32)":"a401b02b"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"name\":\"log\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"log_address\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"val\",\"type\":\"uint256[]\"}],\"name\":\"log_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"int256[]\",\"name\":\"val\",\"type\":\"int256[]\"}],\"name\":\"log_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"val\",\"type\":\"address[]\"}],\"name\":\"log_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"log_bytes\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"log_bytes32\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"name\":\"log_int\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"val\",\"type\":\"address\"}],\"name\":\"log_named_address\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"val\",\"type\":\"uint256[]\"}],\"name\":\"log_named_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"int256[]\",\"name\":\"val\",\"type\":\"int256[]\"}],\"name\":\"log_named_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"val\",\"type\":\"address[]\"}],\"name\":\"log_named_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"val\",\"type\":\"bytes\"}],\"name\":\"log_named_bytes\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"val\",\"type\":\"bytes32\"}],\"name\":\"log_named_bytes32\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"val\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"log_named_decimal_int\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"val\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"log_named_decimal_uint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"val\",\"type\":\"int256\"}],\"name\":\"log_named_int\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"val\",\"type\":\"string\"}],\"name\":\"log_named_string\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"val\",\"type\":\"uint256\"}],\"name\":\"log_named_uint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"name\":\"log_string\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"log_uint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"logs\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"IS_TEST\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeArtifacts\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"excludedArtifacts_\",\"type\":\"string[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeContracts\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"excludedContracts_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeSelectors\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"bytes4[]\",\"name\":\"selectors\",\"type\":\"bytes4[]\"}],\"internalType\":\"struct StdInvariant.FuzzSelector[]\",\"name\":\"excludedSelectors_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"excludedSenders_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"failed\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contract ImplicitProjectRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"setUp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"signalsImplicitMode\",\"outputs\":[{\"internalType\":\"contract SignalsImplicitModeMock\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetArtifactSelectors\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"artifact\",\"type\":\"string\"},{\"internalType\":\"bytes4[]\",\"name\":\"selectors\",\"type\":\"bytes4[]\"}],\"internalType\":\"struct StdInvariant.FuzzArtifactSelector[]\",\"name\":\"targetedArtifactSelectors_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetArtifacts\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"targetedArtifacts_\",\"type\":\"string[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetContracts\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"targetedContracts_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetInterfaces\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"string[]\",\"name\":\"artifacts\",\"type\":\"string[]\"}],\"internalType\":\"struct StdInvariant.FuzzInterface[]\",\"name\":\"targetedInterfaces_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetSelectors\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"bytes4[]\",\"name\":\"selectors\",\"type\":\"bytes4[]\"}],\"internalType\":\"struct StdInvariant.FuzzSelector[]\",\"name\":\"targetedSelectors_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"targetedSenders_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"url\",\"type\":\"string\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"approvedSigner\",\"type\":\"address\"},{\"internalType\":\"bytes4\",\"name\":\"identityType\",\"type\":\"bytes4\"},{\"internalType\":\"bytes32\",\"name\":\"issuerHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"audienceHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"applicationData\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"string\",\"name\":\"redirectUrl\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"issuedAt\",\"type\":\"uint64\"}],\"internalType\":\"struct AuthData\",\"name\":\"authData\",\"type\":\"tuple\"}],\"internalType\":\"struct Attestation\",\"name\":\"attestation\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"wallet\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"delegateCall\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"onlyFallback\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"behaviorOnError\",\"type\":\"uint256\"}],\"internalType\":\"struct Payload.Call\",\"name\":\"call\",\"type\":\"tuple\"}],\"name\":\"test_acceptsValidUrl\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes12\",\"name\":\"projectIdUpper\",\"type\":\"bytes12\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"string[]\",\"name\":\"urls\",\"type\":\"string[]\"},{\"internalType\":\"uint256\",\"name\":\"urlIdx\",\"type\":\"uint256\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"approvedSigner\",\"type\":\"address\"},{\"internalType\":\"bytes4\",\"name\":\"identityType\",\"type\":\"bytes4\"},{\"internalType\":\"bytes32\",\"name\":\"issuerHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"audienceHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"applicationData\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"string\",\"name\":\"redirectUrl\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"issuedAt\",\"type\":\"uint64\"}],\"internalType\":\"struct AuthData\",\"name\":\"authData\",\"type\":\"tuple\"}],\"internalType\":\"struct Attestation\",\"name\":\"attestation\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"wallet\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"delegateCall\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"onlyFallback\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"behaviorOnError\",\"type\":\"uint256\"}],\"internalType\":\"struct Payload.Call\",\"name\":\"call\",\"type\":\"tuple\"}],\"name\":\"test_acceptsValidUrlFromMultiple\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"},{\"internalType\":\"string\",\"name\":\"url\",\"type\":\"string\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"approvedSigner\",\"type\":\"address\"},{\"internalType\":\"bytes4\",\"name\":\"identityType\",\"type\":\"bytes4\"},{\"internalType\":\"bytes32\",\"name\":\"issuerHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"audienceHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"applicationData\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"string\",\"name\":\"redirectUrl\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"issuedAt\",\"type\":\"uint64\"}],\"internalType\":\"struct AuthData\",\"name\":\"authData\",\"type\":\"tuple\"}],\"internalType\":\"struct Attestation\",\"name\":\"attestation\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"wallet\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"delegateCall\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"onlyFallback\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"behaviorOnError\",\"type\":\"uint256\"}],\"internalType\":\"struct Payload.Call\",\"name\":\"call\",\"type\":\"tuple\"}],\"name\":\"test_rejectsInvalidUrl\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"}],\"name\":\"test_supportsInterface\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"test/SignalsImplicitMode.t.sol\":\"SignalsImplicitModeTest\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/StdAssertions.sol\":{\"keccak256\":\"0xd8eec16034b53b52c90a3d720e121ce7d30d64cc57d854db7d817d5b382dda43\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://612780755e32668c7e3b747d94d16c7291101144e084dd9ee563f071711e99e3\",\"dweb:/ipfs/QmQgtFJXEmDtSHT7tZQTMbb6PCDpq5UDYFvrBnWk1Xo2SY\"]},\"lib/forge-std/src/StdChains.sol\":{\"keccak256\":\"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2\",\"dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe\"]},\"lib/forge-std/src/StdCheats.sol\":{\"keccak256\":\"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41\",\"dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK\"]},\"lib/forge-std/src/StdConstants.sol\":{\"keccak256\":\"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc\",\"dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r\"]},\"lib/forge-std/src/StdError.sol\":{\"keccak256\":\"0xbf477b11a42d7611696956546bcfaa29317d1166bf65e402344599c05943fc77\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://bc2e117d1135e030862b96a6526a43feb38d396cc79857f1fb696d4eff0e5fd6\",\"dweb:/ipfs/QmdSuQ5RrQudTLsNmWXGEeVJX8gR5U9XPm6m4dwwuQnJrj\"]},\"lib/forge-std/src/StdInvariant.sol\":{\"keccak256\":\"0x4dab3021edfa9511bbdd80c48f060ef62eaf457f99eaf841f561fc2557d9a08d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://07668628673174cf8f27f8f4e1f862bab775013ec247eb34f698c5005f229391\",\"dweb:/ipfs/QmPJsiiYwmCZXMsHmQv5tg8VF3CAhNdat7WnKLTWZZH2v5\"]},\"lib/forge-std/src/StdJson.sol\":{\"keccak256\":\"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974\",\"dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3\"]},\"lib/forge-std/src/StdMath.sol\":{\"keccak256\":\"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92\",\"dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/StdStyle.sol\":{\"keccak256\":\"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8\",\"dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK\"]},\"lib/forge-std/src/StdToml.sol\":{\"keccak256\":\"0x58a72c765ed3f7ff6b105509689658795b8a3739b8931772a497155878381861\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b4a3746f4fabaeb980bd77d9e091d3904ee38a6c0e191bfa8ba6874c6f8558a3\",\"dweb:/ipfs/QmUfFDMEn461FgGEXt5HicyGD54sc28sLaQ9JRWDMBKed8\"]},\"lib/forge-std/src/StdUtils.sol\":{\"keccak256\":\"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a\",\"dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT\"]},\"lib/forge-std/src/Test.sol\":{\"keccak256\":\"0x3dda6083a83dfa3e8526e97bcc28e862ee2442dd58fe94d5c426d65b8e38f73c\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://33f8c02e4dabdab86a6825125856446a8657eacd712318b51b7818e4a6f6e3f4\",\"dweb:/ipfs/QmRKSjVnrk54yr8wTK2e6QxRjiuba2H8HJSKunHAkdo7RG\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]},\"lib/forge-std/src/console2.sol\":{\"keccak256\":\"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d\",\"dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ\"]},\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]},\"lib/forge-std/src/safeconsole.sol\":{\"keccak256\":\"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab\",\"dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3\"]},\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol\":{\"keccak256\":\"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287\",\"dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p\"]},\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol\":{\"keccak256\":\"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621\",\"dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]},\"src/helper/SignalsImplicitMode.sol\":{\"keccak256\":\"0x40d1c9354bca0b8275e0150f53d6e8d760a78ad62c39ed831ab46d2ee6c8ea65\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://cf248253dc5a9c6612e7b3f5ce096c8c83d8f4b328de4889b58fb0fef0e3d8af\",\"dweb:/ipfs/QmcDGY9KwbQQQ5maxhNsM6vWWn8xigcCXw3ihrHpKvad6L\"]},\"src/registry/IImplicitProjectRegistry.sol\":{\"keccak256\":\"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de\",\"dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6\"]},\"src/registry/IImplicitProjectValidation.sol\":{\"keccak256\":\"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c\",\"dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6\"]},\"src/registry/ImplicitProjectRegistry.sol\":{\"keccak256\":\"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa\",\"dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8\"]},\"test/SignalsImplicitMode.t.sol\":{\"keccak256\":\"0x1bb5e630261a19eb67d54a4103c5593dcae8693a1c000c8f020e258364d01516\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://4b837d259b7d0780268445045de43312753db8f6de8a707e14334c0ef9de8208\",\"dweb:/ipfs/QmNzPzfNNkZu8oayRf1PCW7tNZiu1pjaXKT8RAFnzac6jf\"]},\"test/TestHelper.sol\":{\"keccak256\":\"0xba551fda365d1deef08d0e627d0233810141ea6dbfe770be3ebdb839a6af16a9\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://fb9173a19cc248878fba10321bc83c5226d12eebacded8aad5c114dc39d52f15\",\"dweb:/ipfs/QmTEH8EuNa8FcTEF4PiDPcmLYspxGEw3jbzEwVYFdxZWeD\"]},\"test/mock/SignalsImplicitModeMock.sol\":{\"keccak256\":\"0x15d4554d50385ac8d4529e6d37b74b4f8d7e9ba6051cf7d7614561b6319ff4ba\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://165c71fb13a424c151fed7bb9d7880f7993cbd73f1cde117c148dc7f59216285\",\"dweb:/ipfs/QmWv5YckRhNsGrusXobNodxYtyJqQK2S2VXtNfjwjahwwQ\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"string","name":"","type":"string","indexed":false}],"type":"event","name":"log","anonymous":false},{"inputs":[{"internalType":"address","name":"","type":"address","indexed":false}],"type":"event","name":"log_address","anonymous":false},{"inputs":[{"internalType":"uint256[]","name":"val","type":"uint256[]","indexed":false}],"type":"event","name":"log_array","anonymous":false},{"inputs":[{"internalType":"int256[]","name":"val","type":"int256[]","indexed":false}],"type":"event","name":"log_array","anonymous":false},{"inputs":[{"internalType":"address[]","name":"val","type":"address[]","indexed":false}],"type":"event","name":"log_array","anonymous":false},{"inputs":[{"internalType":"bytes","name":"","type":"bytes","indexed":false}],"type":"event","name":"log_bytes","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32","indexed":false}],"type":"event","name":"log_bytes32","anonymous":false},{"inputs":[{"internalType":"int256","name":"","type":"int256","indexed":false}],"type":"event","name":"log_int","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"address","name":"val","type":"address","indexed":false}],"type":"event","name":"log_named_address","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"uint256[]","name":"val","type":"uint256[]","indexed":false}],"type":"event","name":"log_named_array","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"int256[]","name":"val","type":"int256[]","indexed":false}],"type":"event","name":"log_named_array","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"address[]","name":"val","type":"address[]","indexed":false}],"type":"event","name":"log_named_array","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"bytes","name":"val","type":"bytes","indexed":false}],"type":"event","name":"log_named_bytes","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"bytes32","name":"val","type":"bytes32","indexed":false}],"type":"event","name":"log_named_bytes32","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"int256","name":"val","type":"int256","indexed":false},{"internalType":"uint256","name":"decimals","type":"uint256","indexed":false}],"type":"event","name":"log_named_decimal_int","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"uint256","name":"val","type":"uint256","indexed":false},{"internalType":"uint256","name":"decimals","type":"uint256","indexed":false}],"type":"event","name":"log_named_decimal_uint","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"int256","name":"val","type":"int256","indexed":false}],"type":"event","name":"log_named_int","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"string","name":"val","type":"string","indexed":false}],"type":"event","name":"log_named_string","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"uint256","name":"val","type":"uint256","indexed":false}],"type":"event","name":"log_named_uint","anonymous":false},{"inputs":[{"internalType":"string","name":"","type":"string","indexed":false}],"type":"event","name":"log_string","anonymous":false},{"inputs":[{"internalType":"uint256","name":"","type":"uint256","indexed":false}],"type":"event","name":"log_uint","anonymous":false},{"inputs":[{"internalType":"bytes","name":"","type":"bytes","indexed":false}],"type":"event","name":"logs","anonymous":false},{"inputs":[],"stateMutability":"view","type":"function","name":"IS_TEST","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeArtifacts","outputs":[{"internalType":"string[]","name":"excludedArtifacts_","type":"string[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeContracts","outputs":[{"internalType":"address[]","name":"excludedContracts_","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeSelectors","outputs":[{"internalType":"struct StdInvariant.FuzzSelector[]","name":"excludedSelectors_","type":"tuple[]","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"bytes4[]","name":"selectors","type":"bytes4[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeSenders","outputs":[{"internalType":"address[]","name":"excludedSenders_","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"failed","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"registry","outputs":[{"internalType":"contract ImplicitProjectRegistry","name":"","type":"address"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"setUp"},{"inputs":[],"stateMutability":"view","type":"function","name":"signalsImplicitMode","outputs":[{"internalType":"contract SignalsImplicitModeMock","name":"","type":"address"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetArtifactSelectors","outputs":[{"internalType":"struct StdInvariant.FuzzArtifactSelector[]","name":"targetedArtifactSelectors_","type":"tuple[]","components":[{"internalType":"string","name":"artifact","type":"string"},{"internalType":"bytes4[]","name":"selectors","type":"bytes4[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetArtifacts","outputs":[{"internalType":"string[]","name":"targetedArtifacts_","type":"string[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetContracts","outputs":[{"internalType":"address[]","name":"targetedContracts_","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetInterfaces","outputs":[{"internalType":"struct StdInvariant.FuzzInterface[]","name":"targetedInterfaces_","type":"tuple[]","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"string[]","name":"artifacts","type":"string[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetSelectors","outputs":[{"internalType":"struct StdInvariant.FuzzSelector[]","name":"targetedSelectors_","type":"tuple[]","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"bytes4[]","name":"selectors","type":"bytes4[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetSenders","outputs":[{"internalType":"address[]","name":"targetedSenders_","type":"address[]"}]},{"inputs":[{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"address","name":"owner","type":"address"},{"internalType":"string","name":"url","type":"string"},{"internalType":"struct Attestation","name":"attestation","type":"tuple","components":[{"internalType":"address","name":"approvedSigner","type":"address"},{"internalType":"bytes4","name":"identityType","type":"bytes4"},{"internalType":"bytes32","name":"issuerHash","type":"bytes32"},{"internalType":"bytes32","name":"audienceHash","type":"bytes32"},{"internalType":"bytes","name":"applicationData","type":"bytes"},{"internalType":"struct AuthData","name":"authData","type":"tuple","components":[{"internalType":"string","name":"redirectUrl","type":"string"},{"internalType":"uint64","name":"issuedAt","type":"uint64"}]}]},{"internalType":"address","name":"wallet","type":"address"},{"internalType":"struct Payload.Call","name":"call","type":"tuple","components":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"bool","name":"delegateCall","type":"bool"},{"internalType":"bool","name":"onlyFallback","type":"bool"},{"internalType":"uint256","name":"behaviorOnError","type":"uint256"}]}],"stateMutability":"nonpayable","type":"function","name":"test_acceptsValidUrl"},{"inputs":[{"internalType":"bytes12","name":"projectIdUpper","type":"bytes12"},{"internalType":"address","name":"owner","type":"address"},{"internalType":"string[]","name":"urls","type":"string[]"},{"internalType":"uint256","name":"urlIdx","type":"uint256"},{"internalType":"struct Attestation","name":"attestation","type":"tuple","components":[{"internalType":"address","name":"approvedSigner","type":"address"},{"internalType":"bytes4","name":"identityType","type":"bytes4"},{"internalType":"bytes32","name":"issuerHash","type":"bytes32"},{"internalType":"bytes32","name":"audienceHash","type":"bytes32"},{"internalType":"bytes","name":"applicationData","type":"bytes"},{"internalType":"struct AuthData","name":"authData","type":"tuple","components":[{"internalType":"string","name":"redirectUrl","type":"string"},{"internalType":"uint64","name":"issuedAt","type":"uint64"}]}]},{"internalType":"address","name":"wallet","type":"address"},{"internalType":"struct Payload.Call","name":"call","type":"tuple","components":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"bool","name":"delegateCall","type":"bool"},{"internalType":"bool","name":"onlyFallback","type":"bool"},{"internalType":"uint256","name":"behaviorOnError","type":"uint256"}]}],"stateMutability":"nonpayable","type":"function","name":"test_acceptsValidUrlFromMultiple"},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"},{"internalType":"string","name":"url","type":"string"},{"internalType":"struct Attestation","name":"attestation","type":"tuple","components":[{"internalType":"address","name":"approvedSigner","type":"address"},{"internalType":"bytes4","name":"identityType","type":"bytes4"},{"internalType":"bytes32","name":"issuerHash","type":"bytes32"},{"internalType":"bytes32","name":"audienceHash","type":"bytes32"},{"internalType":"bytes","name":"applicationData","type":"bytes"},{"internalType":"struct AuthData","name":"authData","type":"tuple","components":[{"internalType":"string","name":"redirectUrl","type":"string"},{"internalType":"uint64","name":"issuedAt","type":"uint64"}]}]},{"internalType":"address","name":"wallet","type":"address"},{"internalType":"struct Payload.Call","name":"call","type":"tuple","components":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"bool","name":"delegateCall","type":"bool"},{"internalType":"bool","name":"onlyFallback","type":"bool"},{"internalType":"uint256","name":"behaviorOnError","type":"uint256"}]}],"stateMutability":"nonpayable","type":"function","name":"test_rejectsInvalidUrl"},{"inputs":[{"internalType":"bytes32","name":"projectId","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"test_supportsInterface"}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"test/SignalsImplicitMode.t.sol":"SignalsImplicitModeTest"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/StdAssertions.sol":{"keccak256":"0xd8eec16034b53b52c90a3d720e121ce7d30d64cc57d854db7d817d5b382dda43","urls":["bzz-raw://612780755e32668c7e3b747d94d16c7291101144e084dd9ee563f071711e99e3","dweb:/ipfs/QmQgtFJXEmDtSHT7tZQTMbb6PCDpq5UDYFvrBnWk1Xo2SY"],"license":"MIT"},"lib/forge-std/src/StdChains.sol":{"keccak256":"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa","urls":["bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2","dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe"],"license":"MIT"},"lib/forge-std/src/StdCheats.sol":{"keccak256":"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746","urls":["bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41","dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK"],"license":"MIT"},"lib/forge-std/src/StdConstants.sol":{"keccak256":"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534","urls":["bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc","dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r"],"license":"MIT"},"lib/forge-std/src/StdError.sol":{"keccak256":"0xbf477b11a42d7611696956546bcfaa29317d1166bf65e402344599c05943fc77","urls":["bzz-raw://bc2e117d1135e030862b96a6526a43feb38d396cc79857f1fb696d4eff0e5fd6","dweb:/ipfs/QmdSuQ5RrQudTLsNmWXGEeVJX8gR5U9XPm6m4dwwuQnJrj"],"license":"MIT"},"lib/forge-std/src/StdInvariant.sol":{"keccak256":"0x4dab3021edfa9511bbdd80c48f060ef62eaf457f99eaf841f561fc2557d9a08d","urls":["bzz-raw://07668628673174cf8f27f8f4e1f862bab775013ec247eb34f698c5005f229391","dweb:/ipfs/QmPJsiiYwmCZXMsHmQv5tg8VF3CAhNdat7WnKLTWZZH2v5"],"license":"MIT"},"lib/forge-std/src/StdJson.sol":{"keccak256":"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500","urls":["bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974","dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3"],"license":"MIT"},"lib/forge-std/src/StdMath.sol":{"keccak256":"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2","urls":["bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92","dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/StdStyle.sol":{"keccak256":"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d","urls":["bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8","dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK"],"license":"MIT"},"lib/forge-std/src/StdToml.sol":{"keccak256":"0x58a72c765ed3f7ff6b105509689658795b8a3739b8931772a497155878381861","urls":["bzz-raw://b4a3746f4fabaeb980bd77d9e091d3904ee38a6c0e191bfa8ba6874c6f8558a3","dweb:/ipfs/QmUfFDMEn461FgGEXt5HicyGD54sc28sLaQ9JRWDMBKed8"],"license":"MIT"},"lib/forge-std/src/StdUtils.sol":{"keccak256":"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8","urls":["bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a","dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT"],"license":"MIT"},"lib/forge-std/src/Test.sol":{"keccak256":"0x3dda6083a83dfa3e8526e97bcc28e862ee2442dd58fe94d5c426d65b8e38f73c","urls":["bzz-raw://33f8c02e4dabdab86a6825125856446a8657eacd712318b51b7818e4a6f6e3f4","dweb:/ipfs/QmRKSjVnrk54yr8wTK2e6QxRjiuba2H8HJSKunHAkdo7RG"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"},"lib/forge-std/src/console2.sol":{"keccak256":"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f","urls":["bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d","dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ"],"license":"MIT"},"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"},"lib/forge-std/src/safeconsole.sol":{"keccak256":"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11","urls":["bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab","dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3"],"license":"MIT"},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol":{"keccak256":"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa","urls":["bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287","dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p"],"license":"MIT"},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol":{"keccak256":"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8","urls":["bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621","dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL"],"license":"MIT"},"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"},"src/helper/SignalsImplicitMode.sol":{"keccak256":"0x40d1c9354bca0b8275e0150f53d6e8d760a78ad62c39ed831ab46d2ee6c8ea65","urls":["bzz-raw://cf248253dc5a9c6612e7b3f5ce096c8c83d8f4b328de4889b58fb0fef0e3d8af","dweb:/ipfs/QmcDGY9KwbQQQ5maxhNsM6vWWn8xigcCXw3ihrHpKvad6L"],"license":"Apache-2.0"},"src/registry/IImplicitProjectRegistry.sol":{"keccak256":"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf","urls":["bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de","dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6"],"license":"Apache-2.0"},"src/registry/IImplicitProjectValidation.sol":{"keccak256":"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2","urls":["bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c","dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6"],"license":"Apache-2.0"},"src/registry/ImplicitProjectRegistry.sol":{"keccak256":"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d","urls":["bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa","dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8"],"license":"Apache-2.0"},"test/SignalsImplicitMode.t.sol":{"keccak256":"0x1bb5e630261a19eb67d54a4103c5593dcae8693a1c000c8f020e258364d01516","urls":["bzz-raw://4b837d259b7d0780268445045de43312753db8f6de8a707e14334c0ef9de8208","dweb:/ipfs/QmNzPzfNNkZu8oayRf1PCW7tNZiu1pjaXKT8RAFnzac6jf"],"license":"Apache-2.0"},"test/TestHelper.sol":{"keccak256":"0xba551fda365d1deef08d0e627d0233810141ea6dbfe770be3ebdb839a6af16a9","urls":["bzz-raw://fb9173a19cc248878fba10321bc83c5226d12eebacded8aad5c114dc39d52f15","dweb:/ipfs/QmTEH8EuNa8FcTEF4PiDPcmLYspxGEw3jbzEwVYFdxZWeD"],"license":"Apache-2.0"},"test/mock/SignalsImplicitModeMock.sol":{"keccak256":"0x15d4554d50385ac8d4529e6d37b74b4f8d7e9ba6051cf7d7614561b6319ff4ba","urls":["bzz-raw://165c71fb13a424c151fed7bb9d7880f7993cbd73f1cde117c148dc7f59216285","dweb:/ipfs/QmWv5YckRhNsGrusXobNodxYtyJqQK2S2VXtNfjwjahwwQ"],"license":"Apache-2.0"}},"version":1},"id":30} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/SignalsImplicitMode.t.sol/VmContractHelper44.json b/lib/signals-implicit-mode/out/SignalsImplicitMode.t.sol/VmContractHelper44.json deleted file mode 100644 index 029979e538..0000000000 --- a/lib/signals-implicit-mode/out/SignalsImplicitMode.t.sol/VmContractHelper44.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_value","type":"uint256","internalType":"uint256"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_args","type":"bytes","internalType":"bytes"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_args","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_args","type":"bytes","internalType":"bytes"},{"name":"_value","type":"uint256","internalType":"uint256"},{"name":"_salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"},{"name":"_args","type":"bytes","internalType":"bytes"},{"name":"_value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"getCode","inputs":[{"name":"_artifact","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"deployCode(string)":"9a8325a0","deployCode(string,bytes)":"29ce9dde","deployCode(string,bytes,bytes32)":"016155bf","deployCode(string,bytes,uint256)":"ff5d64e4","deployCode(string,bytes,uint256,bytes32)":"3aa773ea","deployCode(string,bytes32)":"17ab1d79","deployCode(string,uint256)":"0af6a701","deployCode(string,uint256,bytes32)":"002cb687","getCode(string)":"8d1cc925"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"_args\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"_args\",\"type\":\"bytes\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"_args\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"_salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"_args\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_artifact\",\"type\":\"string\"}],\"name\":\"getCode\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"test/SignalsImplicitMode.t.sol\":\"VmContractHelper44\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/StdAssertions.sol\":{\"keccak256\":\"0xd8eec16034b53b52c90a3d720e121ce7d30d64cc57d854db7d817d5b382dda43\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://612780755e32668c7e3b747d94d16c7291101144e084dd9ee563f071711e99e3\",\"dweb:/ipfs/QmQgtFJXEmDtSHT7tZQTMbb6PCDpq5UDYFvrBnWk1Xo2SY\"]},\"lib/forge-std/src/StdChains.sol\":{\"keccak256\":\"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2\",\"dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe\"]},\"lib/forge-std/src/StdCheats.sol\":{\"keccak256\":\"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41\",\"dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK\"]},\"lib/forge-std/src/StdConstants.sol\":{\"keccak256\":\"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc\",\"dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r\"]},\"lib/forge-std/src/StdError.sol\":{\"keccak256\":\"0xbf477b11a42d7611696956546bcfaa29317d1166bf65e402344599c05943fc77\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://bc2e117d1135e030862b96a6526a43feb38d396cc79857f1fb696d4eff0e5fd6\",\"dweb:/ipfs/QmdSuQ5RrQudTLsNmWXGEeVJX8gR5U9XPm6m4dwwuQnJrj\"]},\"lib/forge-std/src/StdInvariant.sol\":{\"keccak256\":\"0x4dab3021edfa9511bbdd80c48f060ef62eaf457f99eaf841f561fc2557d9a08d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://07668628673174cf8f27f8f4e1f862bab775013ec247eb34f698c5005f229391\",\"dweb:/ipfs/QmPJsiiYwmCZXMsHmQv5tg8VF3CAhNdat7WnKLTWZZH2v5\"]},\"lib/forge-std/src/StdJson.sol\":{\"keccak256\":\"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974\",\"dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3\"]},\"lib/forge-std/src/StdMath.sol\":{\"keccak256\":\"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92\",\"dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/StdStyle.sol\":{\"keccak256\":\"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8\",\"dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK\"]},\"lib/forge-std/src/StdToml.sol\":{\"keccak256\":\"0x58a72c765ed3f7ff6b105509689658795b8a3739b8931772a497155878381861\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b4a3746f4fabaeb980bd77d9e091d3904ee38a6c0e191bfa8ba6874c6f8558a3\",\"dweb:/ipfs/QmUfFDMEn461FgGEXt5HicyGD54sc28sLaQ9JRWDMBKed8\"]},\"lib/forge-std/src/StdUtils.sol\":{\"keccak256\":\"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a\",\"dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT\"]},\"lib/forge-std/src/Test.sol\":{\"keccak256\":\"0x3dda6083a83dfa3e8526e97bcc28e862ee2442dd58fe94d5c426d65b8e38f73c\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://33f8c02e4dabdab86a6825125856446a8657eacd712318b51b7818e4a6f6e3f4\",\"dweb:/ipfs/QmRKSjVnrk54yr8wTK2e6QxRjiuba2H8HJSKunHAkdo7RG\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]},\"lib/forge-std/src/console2.sol\":{\"keccak256\":\"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d\",\"dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ\"]},\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]},\"lib/forge-std/src/safeconsole.sol\":{\"keccak256\":\"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab\",\"dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3\"]},\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol\":{\"keccak256\":\"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287\",\"dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p\"]},\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol\":{\"keccak256\":\"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621\",\"dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]},\"src/helper/SignalsImplicitMode.sol\":{\"keccak256\":\"0x40d1c9354bca0b8275e0150f53d6e8d760a78ad62c39ed831ab46d2ee6c8ea65\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://cf248253dc5a9c6612e7b3f5ce096c8c83d8f4b328de4889b58fb0fef0e3d8af\",\"dweb:/ipfs/QmcDGY9KwbQQQ5maxhNsM6vWWn8xigcCXw3ihrHpKvad6L\"]},\"src/registry/IImplicitProjectRegistry.sol\":{\"keccak256\":\"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de\",\"dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6\"]},\"src/registry/IImplicitProjectValidation.sol\":{\"keccak256\":\"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c\",\"dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6\"]},\"src/registry/ImplicitProjectRegistry.sol\":{\"keccak256\":\"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa\",\"dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8\"]},\"test/SignalsImplicitMode.t.sol\":{\"keccak256\":\"0x065b6f9fa82e5580c0d23c577d04d0ba90a182a9bc407ba738f0579f3b3e91d6\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://ad5a86357a828558c76f1c27ae4c29f1b3924d00acf2bce41cb6cc3f46eb9c16\",\"dweb:/ipfs/QmeJ2LiTA55RsLGdWoEyK3q2tZDHmxBakzWWc54GW6L5yq\"]},\"test/TestHelper.sol\":{\"keccak256\":\"0xba551fda365d1deef08d0e627d0233810141ea6dbfe770be3ebdb839a6af16a9\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://fb9173a19cc248878fba10321bc83c5226d12eebacded8aad5c114dc39d52f15\",\"dweb:/ipfs/QmTEH8EuNa8FcTEF4PiDPcmLYspxGEw3jbzEwVYFdxZWeD\"]},\"test/mock/SignalsImplicitModeMock.sol\":{\"keccak256\":\"0x15d4554d50385ac8d4529e6d37b74b4f8d7e9ba6051cf7d7614561b6319ff4ba\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://165c71fb13a424c151fed7bb9d7880f7993cbd73f1cde117c148dc7f59216285\",\"dweb:/ipfs/QmWv5YckRhNsGrusXobNodxYtyJqQK2S2VXtNfjwjahwwQ\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"uint256","name":"_value","type":"uint256"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes","name":"_args","type":"bytes"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"uint256","name":"_value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes","name":"_args","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes","name":"_args","type":"bytes"},{"internalType":"uint256","name":"_value","type":"uint256"},{"internalType":"bytes32","name":"_salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"},{"internalType":"bytes","name":"_args","type":"bytes"},{"internalType":"uint256","name":"_value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"_artifact","type":"string"}],"stateMutability":"view","type":"function","name":"getCode","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"test/SignalsImplicitMode.t.sol":"VmContractHelper44"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/StdAssertions.sol":{"keccak256":"0xd8eec16034b53b52c90a3d720e121ce7d30d64cc57d854db7d817d5b382dda43","urls":["bzz-raw://612780755e32668c7e3b747d94d16c7291101144e084dd9ee563f071711e99e3","dweb:/ipfs/QmQgtFJXEmDtSHT7tZQTMbb6PCDpq5UDYFvrBnWk1Xo2SY"],"license":"MIT"},"lib/forge-std/src/StdChains.sol":{"keccak256":"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa","urls":["bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2","dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe"],"license":"MIT"},"lib/forge-std/src/StdCheats.sol":{"keccak256":"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746","urls":["bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41","dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK"],"license":"MIT"},"lib/forge-std/src/StdConstants.sol":{"keccak256":"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534","urls":["bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc","dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r"],"license":"MIT"},"lib/forge-std/src/StdError.sol":{"keccak256":"0xbf477b11a42d7611696956546bcfaa29317d1166bf65e402344599c05943fc77","urls":["bzz-raw://bc2e117d1135e030862b96a6526a43feb38d396cc79857f1fb696d4eff0e5fd6","dweb:/ipfs/QmdSuQ5RrQudTLsNmWXGEeVJX8gR5U9XPm6m4dwwuQnJrj"],"license":"MIT"},"lib/forge-std/src/StdInvariant.sol":{"keccak256":"0x4dab3021edfa9511bbdd80c48f060ef62eaf457f99eaf841f561fc2557d9a08d","urls":["bzz-raw://07668628673174cf8f27f8f4e1f862bab775013ec247eb34f698c5005f229391","dweb:/ipfs/QmPJsiiYwmCZXMsHmQv5tg8VF3CAhNdat7WnKLTWZZH2v5"],"license":"MIT"},"lib/forge-std/src/StdJson.sol":{"keccak256":"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500","urls":["bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974","dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3"],"license":"MIT"},"lib/forge-std/src/StdMath.sol":{"keccak256":"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2","urls":["bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92","dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/StdStyle.sol":{"keccak256":"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d","urls":["bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8","dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK"],"license":"MIT"},"lib/forge-std/src/StdToml.sol":{"keccak256":"0x58a72c765ed3f7ff6b105509689658795b8a3739b8931772a497155878381861","urls":["bzz-raw://b4a3746f4fabaeb980bd77d9e091d3904ee38a6c0e191bfa8ba6874c6f8558a3","dweb:/ipfs/QmUfFDMEn461FgGEXt5HicyGD54sc28sLaQ9JRWDMBKed8"],"license":"MIT"},"lib/forge-std/src/StdUtils.sol":{"keccak256":"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8","urls":["bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a","dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT"],"license":"MIT"},"lib/forge-std/src/Test.sol":{"keccak256":"0x3dda6083a83dfa3e8526e97bcc28e862ee2442dd58fe94d5c426d65b8e38f73c","urls":["bzz-raw://33f8c02e4dabdab86a6825125856446a8657eacd712318b51b7818e4a6f6e3f4","dweb:/ipfs/QmRKSjVnrk54yr8wTK2e6QxRjiuba2H8HJSKunHAkdo7RG"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"},"lib/forge-std/src/console2.sol":{"keccak256":"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f","urls":["bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d","dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ"],"license":"MIT"},"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"},"lib/forge-std/src/safeconsole.sol":{"keccak256":"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11","urls":["bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab","dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3"],"license":"MIT"},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol":{"keccak256":"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa","urls":["bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287","dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p"],"license":"MIT"},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol":{"keccak256":"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8","urls":["bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621","dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL"],"license":"MIT"},"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"},"src/helper/SignalsImplicitMode.sol":{"keccak256":"0x40d1c9354bca0b8275e0150f53d6e8d760a78ad62c39ed831ab46d2ee6c8ea65","urls":["bzz-raw://cf248253dc5a9c6612e7b3f5ce096c8c83d8f4b328de4889b58fb0fef0e3d8af","dweb:/ipfs/QmcDGY9KwbQQQ5maxhNsM6vWWn8xigcCXw3ihrHpKvad6L"],"license":"Apache-2.0"},"src/registry/IImplicitProjectRegistry.sol":{"keccak256":"0x261d967aac6d5355a83adb18253527b37ab7bd2e27a299030fbdfa96e01f1caf","urls":["bzz-raw://42aad79306034dd71db71c3d4cbd17e101803046e12ba655429ee23872a9e1de","dweb:/ipfs/QmTJ6zGSB4JLvsEku5xhRnW1kupJohEP19Gf2CXLUZJQi6"],"license":"Apache-2.0"},"src/registry/IImplicitProjectValidation.sol":{"keccak256":"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2","urls":["bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c","dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6"],"license":"Apache-2.0"},"src/registry/ImplicitProjectRegistry.sol":{"keccak256":"0x353dd556f76b82cb8ad5d9ea74ed262beea07c602a66dca48c56465c5000896d","urls":["bzz-raw://f8c8199305b1d39c1c5b0efc8d498457915c0fd56f863d03002dca06737e9aaa","dweb:/ipfs/QmPBwmNeufi3UZ5LBXfspKmdD68rTPzmSUjNSWm3kmGUE8"],"license":"Apache-2.0"},"test/SignalsImplicitMode.t.sol":{"keccak256":"0x065b6f9fa82e5580c0d23c577d04d0ba90a182a9bc407ba738f0579f3b3e91d6","urls":["bzz-raw://ad5a86357a828558c76f1c27ae4c29f1b3924d00acf2bce41cb6cc3f46eb9c16","dweb:/ipfs/QmeJ2LiTA55RsLGdWoEyK3q2tZDHmxBakzWWc54GW6L5yq"],"license":"Apache-2.0"},"test/TestHelper.sol":{"keccak256":"0xba551fda365d1deef08d0e627d0233810141ea6dbfe770be3ebdb839a6af16a9","urls":["bzz-raw://fb9173a19cc248878fba10321bc83c5226d12eebacded8aad5c114dc39d52f15","dweb:/ipfs/QmTEH8EuNa8FcTEF4PiDPcmLYspxGEw3jbzEwVYFdxZWeD"],"license":"Apache-2.0"},"test/mock/SignalsImplicitModeMock.sol":{"keccak256":"0x15d4554d50385ac8d4529e6d37b74b4f8d7e9ba6051cf7d7614561b6319ff4ba","urls":["bzz-raw://165c71fb13a424c151fed7bb9d7880f7993cbd73f1cde117c148dc7f59216285","dweb:/ipfs/QmWv5YckRhNsGrusXobNodxYtyJqQK2S2VXtNfjwjahwwQ"],"license":"Apache-2.0"}},"version":1},"id":34} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/SignalsImplicitModeMock.sol/SignalsImplicitModeMock.json b/lib/signals-implicit-mode/out/SignalsImplicitModeMock.sol/SignalsImplicitModeMock.json deleted file mode 100644 index b58be21162..0000000000 --- a/lib/signals-implicit-mode/out/SignalsImplicitModeMock.sol/SignalsImplicitModeMock.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"constructor","inputs":[{"name":"registry","type":"address","internalType":"address"},{"name":"projectId","type":"bytes32","internalType":"bytes32"}],"stateMutability":"nonpayable"},{"type":"function","name":"acceptImplicitRequest","inputs":[{"name":"wallet","type":"address","internalType":"address"},{"name":"attestation","type":"tuple","internalType":"struct Attestation","components":[{"name":"approvedSigner","type":"address","internalType":"address"},{"name":"identityType","type":"bytes4","internalType":"bytes4"},{"name":"issuerHash","type":"bytes32","internalType":"bytes32"},{"name":"audienceHash","type":"bytes32","internalType":"bytes32"},{"name":"applicationData","type":"bytes","internalType":"bytes"},{"name":"authData","type":"tuple","internalType":"struct AuthData","components":[{"name":"redirectUrl","type":"string","internalType":"string"},{"name":"issuedAt","type":"uint64","internalType":"uint64"}]}]},{"name":"call","type":"tuple","internalType":"struct Payload.Call","components":[{"name":"to","type":"address","internalType":"address"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"gasLimit","type":"uint256","internalType":"uint256"},{"name":"delegateCall","type":"bool","internalType":"bool"},{"name":"onlyFallback","type":"bool","internalType":"bool"},{"name":"behaviorOnError","type":"uint256","internalType":"uint256"}]}],"outputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"supportsInterface","inputs":[{"name":"interfaceId","type":"bytes4","internalType":"bytes4"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"}],"bytecode":{"object":"0x608060405234801561001057600080fd5b50604051610a4e380380610a4e8339818101604052810190610032919061012d565b610042828261004960201b60201c565b505061016d565b816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550806001819055505050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006100c482610099565b9050919050565b6100d4816100b9565b81146100df57600080fd5b50565b6000815190506100f1816100cb565b92915050565b6000819050919050565b61010a816100f7565b811461011557600080fd5b50565b60008151905061012781610101565b92915050565b6000806040838503121561014457610143610094565b5b6000610152858286016100e2565b925050602061016385828601610118565b9150509250929050565b6108d28061017c6000396000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c806301ffc9a71461003b5780639d043a661461006b575b600080fd5b6100556004803603810190610050919061029c565b61009b565b60405161006291906102e4565b60405180910390f35b610085600480360381019061008091906103a0565b610115565b6040516100929190610444565b60405180910390f35b60007f9d043a66000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061010e575061010d826101cb565b5b9050919050565b6000610122848484610235565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633808a90b85856001546040518463ffffffff1660e01b81526004016101819392919061081c565b602060405180830381865afa15801561019e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101c2919061086f565b90509392505050565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b505050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b61027981610244565b811461028457600080fd5b50565b60008135905061029681610270565b92915050565b6000602082840312156102b2576102b161023a565b5b60006102c084828501610287565b91505092915050565b60008115159050919050565b6102de816102c9565b82525050565b60006020820190506102f960008301846102d5565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061032a826102ff565b9050919050565b61033a8161031f565b811461034557600080fd5b50565b60008135905061035781610331565b92915050565b600080fd5b600060c082840312156103785761037761035d565b5b81905092915050565b600060e082840312156103975761039661035d565b5b81905092915050565b6000806000606084860312156103b9576103b861023a565b5b60006103c786828701610348565b935050602084013567ffffffffffffffff8111156103e8576103e761023f565b5b6103f486828701610362565b925050604084013567ffffffffffffffff8111156104155761041461023f565b5b61042186828701610381565b9150509250925092565b6000819050919050565b61043e8161042b565b82525050565b60006020820190506104596000830184610435565b92915050565b6104688161031f565b82525050565b600061047d6020840184610348565b905092915050565b61048e8161031f565b82525050565b60006104a36020840184610287565b905092915050565b6104b481610244565b82525050565b6104c38161042b565b81146104ce57600080fd5b50565b6000813590506104e0816104ba565b92915050565b60006104f560208401846104d1565b905092915050565b6105068161042b565b82525050565b600080fd5b600080fd5b600080fd5b6000808335600160200384360303811261053857610537610516565b5b83810192508235915060208301925067ffffffffffffffff8211156105605761055f61050c565b5b60018202360383131561057657610575610511565b5b509250929050565b600082825260208201905092915050565b82818337600083830152505050565b6000601f19601f8301169050919050565b60006105bb838561057e565b93506105c883858461058f565b6105d18361059e565b840190509392505050565b6000823560016040038336030381126105f8576105f7610516565b5b82810191505092915050565b6000808335600160200384360303811261062157610620610516565b5b83810192508235915060208301925067ffffffffffffffff8211156106495761064861050c565b5b60018202360383131561065f5761065e610511565b5b509250929050565b600082825260208201905092915050565b60006106848385610667565b935061069183858461058f565b61069a8361059e565b840190509392505050565b600067ffffffffffffffff82169050919050565b6106c2816106a5565b81146106cd57600080fd5b50565b6000813590506106df816106b9565b92915050565b60006106f460208401846106d0565b905092915050565b610705816106a5565b82525050565b60006040830161071e6000840184610604565b8583036000870152610731838284610678565b9250505061074260208401846106e5565b61074f60208601826106fc565b508091505092915050565b600060c0830161076d600084018461046e565b61077a6000860182610485565b506107886020840184610494565b61079560208601826104ab565b506107a360408401846104e6565b6107b060408601826104fd565b506107be60608401846104e6565b6107cb60608601826104fd565b506107d9608084018461051b565b85830360808701526107ec8382846105af565b925050506107fd60a08401846105dc565b84820360a086015261080f828261070b565b9150508091505092915050565b6000606082019050610831600083018661045f565b8181036020830152610843818561075a565b90506108526040830184610435565b949350505050565b600081519050610869816104ba565b92915050565b6000602082840312156108855761088461023a565b5b60006108938482850161085a565b9150509291505056fea26469706673582212200f7838d4e08a733173c1114f7d1249b401d87f3d48bda9d4937ec1a8b486922264736f6c634300081c0033","sourceMap":"146:187:32:-:0;;;207:123;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;274:51;305:8;315:9;274:30;;;:51;;:::i;:::-;207:123;;146:187;;952:188:25;1097:9;1057:10;;:50;;;;;;;;;;;;;;;;;;1126:9;1113:10;:22;;;;952:188;;:::o;88:117:33:-;197:1;194;187:12;334:126;371:7;411:42;404:5;400:54;389:65;;334:126;;;:::o;466:96::-;503:7;532:24;550:5;532:24;:::i;:::-;521:35;;466:96;;;:::o;568:122::-;641:24;659:5;641:24;:::i;:::-;634:5;631:35;621:63;;680:1;677;670:12;621:63;568:122;:::o;696:143::-;753:5;784:6;778:13;769:22;;800:33;827:5;800:33;:::i;:::-;696:143;;;;:::o;845:77::-;882:7;911:5;900:16;;845:77;;;:::o;928:122::-;1001:24;1019:5;1001:24;:::i;:::-;994:5;991:35;981:63;;1040:1;1037;1030:12;981:63;928:122;:::o;1056:143::-;1113:5;1144:6;1138:13;1129:22;;1160:33;1187:5;1160:33;:::i;:::-;1056:143;;;;:::o;1205:507::-;1284:6;1292;1341:2;1329:9;1320:7;1316:23;1312:32;1309:119;;;1347:79;;:::i;:::-;1309:119;1467:1;1492:64;1548:7;1539:6;1528:9;1524:22;1492:64;:::i;:::-;1482:74;;1438:128;1605:2;1631:64;1687:7;1678:6;1667:9;1663:22;1631:64;:::i;:::-;1621:74;;1576:129;1205:507;;;;;:::o;146:187:32:-;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x608060405234801561001057600080fd5b50600436106100365760003560e01c806301ffc9a71461003b5780639d043a661461006b575b600080fd5b6100556004803603810190610050919061029c565b61009b565b60405161006291906102e4565b60405180910390f35b610085600480360381019061008091906103a0565b610115565b6040516100929190610444565b60405180910390f35b60007f9d043a66000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061010e575061010d826101cb565b5b9050919050565b6000610122848484610235565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633808a90b85856001546040518463ffffffff1660e01b81526004016101819392919061081c565b602060405180830381865afa15801561019e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101c2919061086f565b90509392505050565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b505050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b61027981610244565b811461028457600080fd5b50565b60008135905061029681610270565b92915050565b6000602082840312156102b2576102b161023a565b5b60006102c084828501610287565b91505092915050565b60008115159050919050565b6102de816102c9565b82525050565b60006020820190506102f960008301846102d5565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061032a826102ff565b9050919050565b61033a8161031f565b811461034557600080fd5b50565b60008135905061035781610331565b92915050565b600080fd5b600060c082840312156103785761037761035d565b5b81905092915050565b600060e082840312156103975761039661035d565b5b81905092915050565b6000806000606084860312156103b9576103b861023a565b5b60006103c786828701610348565b935050602084013567ffffffffffffffff8111156103e8576103e761023f565b5b6103f486828701610362565b925050604084013567ffffffffffffffff8111156104155761041461023f565b5b61042186828701610381565b9150509250925092565b6000819050919050565b61043e8161042b565b82525050565b60006020820190506104596000830184610435565b92915050565b6104688161031f565b82525050565b600061047d6020840184610348565b905092915050565b61048e8161031f565b82525050565b60006104a36020840184610287565b905092915050565b6104b481610244565b82525050565b6104c38161042b565b81146104ce57600080fd5b50565b6000813590506104e0816104ba565b92915050565b60006104f560208401846104d1565b905092915050565b6105068161042b565b82525050565b600080fd5b600080fd5b600080fd5b6000808335600160200384360303811261053857610537610516565b5b83810192508235915060208301925067ffffffffffffffff8211156105605761055f61050c565b5b60018202360383131561057657610575610511565b5b509250929050565b600082825260208201905092915050565b82818337600083830152505050565b6000601f19601f8301169050919050565b60006105bb838561057e565b93506105c883858461058f565b6105d18361059e565b840190509392505050565b6000823560016040038336030381126105f8576105f7610516565b5b82810191505092915050565b6000808335600160200384360303811261062157610620610516565b5b83810192508235915060208301925067ffffffffffffffff8211156106495761064861050c565b5b60018202360383131561065f5761065e610511565b5b509250929050565b600082825260208201905092915050565b60006106848385610667565b935061069183858461058f565b61069a8361059e565b840190509392505050565b600067ffffffffffffffff82169050919050565b6106c2816106a5565b81146106cd57600080fd5b50565b6000813590506106df816106b9565b92915050565b60006106f460208401846106d0565b905092915050565b610705816106a5565b82525050565b60006040830161071e6000840184610604565b8583036000870152610731838284610678565b9250505061074260208401846106e5565b61074f60208601826106fc565b508091505092915050565b600060c0830161076d600084018461046e565b61077a6000860182610485565b506107886020840184610494565b61079560208601826104ab565b506107a360408401846104e6565b6107b060408601826104fd565b506107be60608401846104e6565b6107cb60608601826104fd565b506107d9608084018461051b565b85830360808701526107ec8382846105af565b925050506107fd60a08401846105dc565b84820360a086015261080f828261070b565b9150508091505092915050565b6000606082019050610831600083018661045f565b8181036020830152610843818561075a565b90506108526040830184610435565b949350505050565b600081519050610869816104ba565b92915050565b6000602082840312156108855761088461023a565b5b60006108938482850161085a565b9150509291505056fea26469706673582212200f7838d4e08a733173c1114f7d1249b401d87f3d48bda9d4937ec1a8b486922264736f6c634300081c0033","sourceMap":"146:187:32:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1911:210:25;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;1183:295;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;1911:210;2004:4;2038:38;2023:53;;;:11;:53;;;;:93;;;;2080:36;2104:11;2080:23;:36::i;:::-;2023:93;2016:100;;1911:210;;;:::o;1183:295::-;1331:7;1346:51;1371:6;1379:11;1392:4;1346:24;:51::i;:::-;1410:10;;;;;;;;;;:30;;;1441:6;1449:11;1462:10;;1410:63;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;1403:70;;1183:295;;;;;:::o;763:146:19:-;839:4;877:25;862:40;;;:11;:40;;;;855:47;;763:146;;;:::o;1728:153:25:-;;;;:::o;88:117:33:-;197:1;194;187:12;211:117;320:1;317;310:12;334:149;370:7;410:66;403:5;399:78;388:89;;334:149;;;:::o;489:120::-;561:23;578:5;561:23;:::i;:::-;554:5;551:34;541:62;;599:1;596;589:12;541:62;489:120;:::o;615:137::-;660:5;698:6;685:20;676:29;;714:32;740:5;714:32;:::i;:::-;615:137;;;;:::o;758:327::-;816:6;865:2;853:9;844:7;840:23;836:32;833:119;;;871:79;;:::i;:::-;833:119;991:1;1016:52;1060:7;1051:6;1040:9;1036:22;1016:52;:::i;:::-;1006:62;;962:116;758:327;;;;:::o;1091:90::-;1125:7;1168:5;1161:13;1154:21;1143:32;;1091:90;;;:::o;1187:109::-;1268:21;1283:5;1268:21;:::i;:::-;1263:3;1256:34;1187:109;;:::o;1302:210::-;1389:4;1427:2;1416:9;1412:18;1404:26;;1440:65;1502:1;1491:9;1487:17;1478:6;1440:65;:::i;:::-;1302:210;;;;:::o;1518:126::-;1555:7;1595:42;1588:5;1584:54;1573:65;;1518:126;;;:::o;1650:96::-;1687:7;1716:24;1734:5;1716:24;:::i;:::-;1705:35;;1650:96;;;:::o;1752:122::-;1825:24;1843:5;1825:24;:::i;:::-;1818:5;1815:35;1805:63;;1864:1;1861;1854:12;1805:63;1752:122;:::o;1880:139::-;1926:5;1964:6;1951:20;1942:29;;1980:33;2007:5;1980:33;:::i;:::-;1880:139;;;;:::o;2025:117::-;2134:1;2131;2124:12;2174:237;2252:5;2293:3;2284:6;2279:3;2275:16;2271:26;2268:113;;;2300:79;;:::i;:::-;2268:113;2399:6;2390:15;;2174:237;;;;:::o;2444:230::-;2515:5;2556:3;2547:6;2542:3;2538:16;2534:26;2531:113;;;2563:79;;:::i;:::-;2531:113;2662:6;2653:15;;2444:230;;;;:::o;2680:1053::-;2814:6;2822;2830;2879:2;2867:9;2858:7;2854:23;2850:32;2847:119;;;2885:79;;:::i;:::-;2847:119;3005:1;3030:53;3075:7;3066:6;3055:9;3051:22;3030:53;:::i;:::-;3020:63;;2976:117;3160:2;3149:9;3145:18;3132:32;3191:18;3183:6;3180:30;3177:117;;;3213:79;;:::i;:::-;3177:117;3318:85;3395:7;3386:6;3375:9;3371:22;3318:85;:::i;:::-;3308:95;;3103:310;3480:2;3469:9;3465:18;3452:32;3511:18;3503:6;3500:30;3497:117;;;3533:79;;:::i;:::-;3497:117;3638:78;3708:7;3699:6;3688:9;3684:22;3638:78;:::i;:::-;3628:88;;3423:303;2680:1053;;;;;:::o;3739:77::-;3776:7;3805:5;3794:16;;3739:77;;;:::o;3822:118::-;3909:24;3927:5;3909:24;:::i;:::-;3904:3;3897:37;3822:118;;:::o;3946:222::-;4039:4;4077:2;4066:9;4062:18;4054:26;;4090:71;4158:1;4147:9;4143:17;4134:6;4090:71;:::i;:::-;3946:222;;;;:::o;4174:118::-;4261:24;4279:5;4261:24;:::i;:::-;4256:3;4249:37;4174:118;;:::o;4298:122::-;4350:5;4375:39;4410:2;4405:3;4401:12;4396:3;4375:39;:::i;:::-;4366:48;;4298:122;;;;:::o;4426:108::-;4503:24;4521:5;4503:24;:::i;:::-;4498:3;4491:37;4426:108;;:::o;4540:120::-;4591:5;4616:38;4650:2;4645:3;4641:12;4636:3;4616:38;:::i;:::-;4607:47;;4540:120;;;;:::o;4666:105::-;4741:23;4758:5;4741:23;:::i;:::-;4736:3;4729:36;4666:105;;:::o;4777:122::-;4850:24;4868:5;4850:24;:::i;:::-;4843:5;4840:35;4830:63;;4889:1;4886;4879:12;4830:63;4777:122;:::o;4905:139::-;4951:5;4989:6;4976:20;4967:29;;5005:33;5032:5;5005:33;:::i;:::-;4905:139;;;;:::o;5050:122::-;5102:5;5127:39;5162:2;5157:3;5153:12;5148:3;5127:39;:::i;:::-;5118:48;;5050:122;;;;:::o;5178:108::-;5255:24;5273:5;5255:24;:::i;:::-;5250:3;5243:37;5178:108;;:::o;5292:117::-;5401:1;5398;5391:12;5415:117;5524:1;5521;5514:12;5538:117;5647:1;5644;5637:12;5661:711;5725:5;5732:6;5788:3;5775:17;5880:1;5874:4;5870:12;5859:8;5843:14;5839:29;5835:48;5815:18;5811:73;5801:168;;5888:79;;:::i;:::-;5801:168;6011:8;5991:18;5987:33;5978:42;;6053:5;6040:19;6030:29;;6088:4;6081:5;6077:16;6068:25;;6116:18;6108:6;6105:30;6102:117;;;6138:79;;:::i;:::-;6102:117;6274:4;6266:6;6262:17;6246:14;6242:38;6235:5;6231:50;6228:137;;;6284:79;;:::i;:::-;6228:137;5739:633;5661:711;;;;;:::o;6378:158::-;6451:11;6485:6;6480:3;6473:19;6525:4;6520:3;6516:14;6501:29;;6378:158;;;;:::o;6542:148::-;6640:6;6635:3;6630;6617:30;6681:1;6672:6;6667:3;6663:16;6656:27;6542:148;;;:::o;6696:102::-;6737:6;6788:2;6784:7;6779:2;6772:5;6768:14;6764:28;6754:38;;6696:102;;;:::o;6826:294::-;6912:3;6933:60;6986:6;6981:3;6933:60;:::i;:::-;6926:67;;7003:56;7052:6;7047:3;7040:5;7003:56;:::i;:::-;7084:29;7106:6;7084:29;:::i;:::-;7079:3;7075:39;7068:46;;6826:294;;;;;:::o;7126:376::-;7208:5;7263:3;7250:17;7355:1;7349:4;7345:12;7334:8;7318:14;7314:29;7310:48;7290:18;7286:73;7276:168;;7363:79;;:::i;:::-;7276:168;7486:8;7466:18;7462:33;7453:42;;7214:288;7126:376;;;;:::o;7508:712::-;7573:5;7580:6;7636:3;7623:17;7728:1;7722:4;7718:12;7707:8;7691:14;7687:29;7683:48;7663:18;7659:73;7649:168;;7736:79;;:::i;:::-;7649:168;7859:8;7839:18;7835:33;7826:42;;7901:5;7888:19;7878:29;;7936:4;7929:5;7925:16;7916:25;;7964:18;7956:6;7953:30;7950:117;;;7986:79;;:::i;:::-;7950:117;8122:4;8114:6;8110:17;8094:14;8090:38;8083:5;8079:50;8076:137;;;8132:79;;:::i;:::-;8076:137;7587:633;7508:712;;;;;:::o;8226:159::-;8300:11;8334:6;8329:3;8322:19;8374:4;8369:3;8365:14;8350:29;;8226:159;;;;:::o;8415:297::-;8503:3;8524:61;8578:6;8573:3;8524:61;:::i;:::-;8517:68;;8595:56;8644:6;8639:3;8632:5;8595:56;:::i;:::-;8676:29;8698:6;8676:29;:::i;:::-;8671:3;8667:39;8660:46;;8415:297;;;;;:::o;8718:101::-;8754:7;8794:18;8787:5;8783:30;8772:41;;8718:101;;;:::o;8825:120::-;8897:23;8914:5;8897:23;:::i;:::-;8890:5;8887:34;8877:62;;8935:1;8932;8925:12;8877:62;8825:120;:::o;8951:137::-;8996:5;9034:6;9021:20;9012:29;;9050:32;9076:5;9050:32;:::i;:::-;8951:137;;;;:::o;9094:120::-;9145:5;9170:38;9204:2;9199:3;9195:12;9190:3;9170:38;:::i;:::-;9161:47;;9094:120;;;;:::o;9220:105::-;9295:23;9312:5;9295:23;:::i;:::-;9290:3;9283:36;9220:105;;:::o;9373:706::-;9488:3;9524:4;9519:3;9515:14;9615:62;9671:4;9664:5;9660:16;9653:5;9615:62;:::i;:::-;9724:3;9718:4;9714:14;9707:4;9702:3;9698:14;9691:38;9750:89;9834:4;9820:12;9806;9750:89;:::i;:::-;9742:97;;9539:311;;9919:49;9962:4;9955:5;9951:16;9944:5;9919:49;:::i;:::-;9981:61;10036:4;10031:3;10027:14;10013:12;9981:61;:::i;:::-;9860:192;10069:4;10062:11;;9493:586;9373:706;;;;:::o;10133:1695::-;10264:3;10300:4;10295:3;10291:14;10380:50;10424:4;10417:5;10413:16;10406:5;10380:50;:::i;:::-;10443:63;10500:4;10495:3;10491:14;10477:12;10443:63;:::i;:::-;10315:201;10589:49;10632:4;10625:5;10621:16;10614:5;10589:49;:::i;:::-;10651:61;10706:4;10701:3;10697:14;10683:12;10651:61;:::i;:::-;10526:196;10793:50;10837:4;10830:5;10826:16;10819:5;10793:50;:::i;:::-;10856:63;10913:4;10908:3;10904:14;10890:12;10856:63;:::i;:::-;10732:197;11002:50;11046:4;11039:5;11035:16;11028:5;11002:50;:::i;:::-;11065:63;11122:4;11117:3;11113:14;11099:12;11065:63;:::i;:::-;10939:199;11228:61;11283:4;11276:5;11272:16;11265:5;11228:61;:::i;:::-;11336:3;11330:4;11326:14;11319:4;11314:3;11310:14;11303:38;11362:87;11444:4;11430:12;11416;11362:87;:::i;:::-;11354:95;;11148:312;;11529:79;11602:4;11595:5;11591:16;11584:5;11529:79;:::i;:::-;11655:3;11649:4;11645:14;11638:4;11633:3;11629:14;11622:38;11681:109;11785:4;11771:12;11681:109;:::i;:::-;11673:117;;11470:331;11818:4;11811:11;;10269:1559;10133:1695;;;;:::o;11834:617::-;12045:4;12083:2;12072:9;12068:18;12060:26;;12096:71;12164:1;12153:9;12149:17;12140:6;12096:71;:::i;:::-;12214:9;12208:4;12204:20;12199:2;12188:9;12184:18;12177:48;12242:120;12357:4;12348:6;12242:120;:::i;:::-;12234:128;;12372:72;12440:2;12429:9;12425:18;12416:6;12372:72;:::i;:::-;11834:617;;;;;;:::o;12457:143::-;12514:5;12545:6;12539:13;12530:22;;12561:33;12588:5;12561:33;:::i;:::-;12457:143;;;;:::o;12606:351::-;12676:6;12725:2;12713:9;12704:7;12700:23;12696:32;12693:119;;;12731:79;;:::i;:::-;12693:119;12851:1;12876:64;12932:7;12923:6;12912:9;12908:22;12876:64;:::i;:::-;12866:74;;12822:128;12606:351;;;;:::o","linkReferences":{}},"methodIdentifiers":{"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))":"9d043a66","supportsInterface(bytes4)":"01ffc9a7"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"registry\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"projectId\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"wallet\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"approvedSigner\",\"type\":\"address\"},{\"internalType\":\"bytes4\",\"name\":\"identityType\",\"type\":\"bytes4\"},{\"internalType\":\"bytes32\",\"name\":\"issuerHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"audienceHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"applicationData\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"string\",\"name\":\"redirectUrl\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"issuedAt\",\"type\":\"uint64\"}],\"internalType\":\"struct AuthData\",\"name\":\"authData\",\"type\":\"tuple\"}],\"internalType\":\"struct Attestation\",\"name\":\"attestation\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"delegateCall\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"onlyFallback\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"behaviorOnError\",\"type\":\"uint256\"}],\"internalType\":\"struct Payload.Call\",\"name\":\"call\",\"type\":\"tuple\"}],\"name\":\"acceptImplicitRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{\"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))\":{\"params\":{\"attestation\":\"The attestation data\",\"call\":\"The call to validate\",\"wallet\":\"The wallet's address\"},\"returns\":{\"_0\":\"The hash of the implicit request if valid\"}},\"supportsInterface(bytes4)\":{\"details\":\"Returns true if this contract implements the interface defined by `interfaceId`. See the corresponding https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[ERC section] to learn more about how these ids are created. This function call must use less than 30 000 gas.\"}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))\":{\"notice\":\"Determines if an implicit request is valid\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"test/mock/SignalsImplicitModeMock.sol\":\"SignalsImplicitModeMock\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol\":{\"keccak256\":\"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287\",\"dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p\"]},\"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol\":{\"keccak256\":\"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621\",\"dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]},\"src/helper/SignalsImplicitMode.sol\":{\"keccak256\":\"0x40d1c9354bca0b8275e0150f53d6e8d760a78ad62c39ed831ab46d2ee6c8ea65\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://cf248253dc5a9c6612e7b3f5ce096c8c83d8f4b328de4889b58fb0fef0e3d8af\",\"dweb:/ipfs/QmcDGY9KwbQQQ5maxhNsM6vWWn8xigcCXw3ihrHpKvad6L\"]},\"src/registry/IImplicitProjectValidation.sol\":{\"keccak256\":\"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c\",\"dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6\"]},\"test/mock/SignalsImplicitModeMock.sol\":{\"keccak256\":\"0x15d4554d50385ac8d4529e6d37b74b4f8d7e9ba6051cf7d7614561b6319ff4ba\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://165c71fb13a424c151fed7bb9d7880f7993cbd73f1cde117c148dc7f59216285\",\"dweb:/ipfs/QmWv5YckRhNsGrusXobNodxYtyJqQK2S2VXtNfjwjahwwQ\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"address","name":"registry","type":"address"},{"internalType":"bytes32","name":"projectId","type":"bytes32"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"struct Attestation","name":"attestation","type":"tuple","components":[{"internalType":"address","name":"approvedSigner","type":"address"},{"internalType":"bytes4","name":"identityType","type":"bytes4"},{"internalType":"bytes32","name":"issuerHash","type":"bytes32"},{"internalType":"bytes32","name":"audienceHash","type":"bytes32"},{"internalType":"bytes","name":"applicationData","type":"bytes"},{"internalType":"struct AuthData","name":"authData","type":"tuple","components":[{"internalType":"string","name":"redirectUrl","type":"string"},{"internalType":"uint64","name":"issuedAt","type":"uint64"}]}]},{"internalType":"struct Payload.Call","name":"call","type":"tuple","components":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"bool","name":"delegateCall","type":"bool"},{"internalType":"bool","name":"onlyFallback","type":"bool"},{"internalType":"uint256","name":"behaviorOnError","type":"uint256"}]}],"stateMutability":"view","type":"function","name":"acceptImplicitRequest","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}]},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"stateMutability":"view","type":"function","name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}]}],"devdoc":{"kind":"dev","methods":{"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))":{"params":{"attestation":"The attestation data","call":"The call to validate","wallet":"The wallet's address"},"returns":{"_0":"The hash of the implicit request if valid"}},"supportsInterface(bytes4)":{"details":"Returns true if this contract implements the interface defined by `interfaceId`. See the corresponding https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[ERC section] to learn more about how these ids are created. This function call must use less than 30 000 gas."}},"version":1},"userdoc":{"kind":"user","methods":{"acceptImplicitRequest(address,(address,bytes4,bytes32,bytes32,bytes,(string,uint64)),(address,uint256,bytes,uint256,bool,bool,uint256))":{"notice":"Determines if an implicit request is valid"}},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"test/mock/SignalsImplicitModeMock.sol":"SignalsImplicitModeMock"},"evmVersion":"paris","libraries":{}},"sources":{"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol":{"keccak256":"0xddce8e17e3d3f9ed818b4f4c4478a8262aab8b11ed322f1bf5ed705bb4bd97fa","urls":["bzz-raw://8084aa71a4cc7d2980972412a88fe4f114869faea3fefa5436431644eb5c0287","dweb:/ipfs/Qmbqfs5dRdPvHVKY8kTaeyc65NdqXRQwRK7h9s5UJEhD1p"],"license":"MIT"},"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol":{"keccak256":"0x79796192ec90263f21b464d5bc90b777a525971d3de8232be80d9c4f9fb353b8","urls":["bzz-raw://f6fda447a62815e8064f47eff0dd1cf58d9207ad69b5d32280f8d7ed1d1e4621","dweb:/ipfs/QmfDRc7pxfaXB2Dh9np5Uf29Na3pQ7tafRS684wd3GLjVL"],"license":"MIT"},"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"},"src/helper/SignalsImplicitMode.sol":{"keccak256":"0x40d1c9354bca0b8275e0150f53d6e8d760a78ad62c39ed831ab46d2ee6c8ea65","urls":["bzz-raw://cf248253dc5a9c6612e7b3f5ce096c8c83d8f4b328de4889b58fb0fef0e3d8af","dweb:/ipfs/QmcDGY9KwbQQQ5maxhNsM6vWWn8xigcCXw3ihrHpKvad6L"],"license":"Apache-2.0"},"src/registry/IImplicitProjectValidation.sol":{"keccak256":"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2","urls":["bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c","dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6"],"license":"Apache-2.0"},"test/mock/SignalsImplicitModeMock.sol":{"keccak256":"0x15d4554d50385ac8d4529e6d37b74b4f8d7e9ba6051cf7d7614561b6319ff4ba","urls":["bzz-raw://165c71fb13a424c151fed7bb9d7880f7993cbd73f1cde117c148dc7f59216285","dweb:/ipfs/QmWv5YckRhNsGrusXobNodxYtyJqQK2S2VXtNfjwjahwwQ"],"license":"Apache-2.0"}},"version":1},"id":32} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/SingletonDeployer.s.sol/SingletonDeployer.json b/lib/signals-implicit-mode/out/SingletonDeployer.s.sol/SingletonDeployer.json deleted file mode 100644 index eba754e55b..0000000000 --- a/lib/signals-implicit-mode/out/SingletonDeployer.s.sol/SingletonDeployer.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"IS_SCRIPT","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"IS_SCRIPT()":"f8ccbf47"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"name\":\"IS_SCRIPT\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol\":\"SingletonDeployer\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/Script.sol\":{\"keccak256\":\"0xc942e27c7baae499beb01afbbae99f24d42af9a6e4aae675bc6901b704aa8e9b\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://0456008adf68947247f358b62863af4a8e349549d2260f2ff9569ff0e3cf5c98\",\"dweb:/ipfs/QmdviSUj2i7o3TPN5vd2xocqGMFVqjUzaiJTZRYyPxyHPx\"]},\"lib/forge-std/src/StdChains.sol\":{\"keccak256\":\"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2\",\"dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe\"]},\"lib/forge-std/src/StdCheats.sol\":{\"keccak256\":\"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41\",\"dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK\"]},\"lib/forge-std/src/StdConstants.sol\":{\"keccak256\":\"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc\",\"dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r\"]},\"lib/forge-std/src/StdJson.sol\":{\"keccak256\":\"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974\",\"dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3\"]},\"lib/forge-std/src/StdMath.sol\":{\"keccak256\":\"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92\",\"dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/StdStyle.sol\":{\"keccak256\":\"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8\",\"dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK\"]},\"lib/forge-std/src/StdUtils.sol\":{\"keccak256\":\"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a\",\"dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]},\"lib/forge-std/src/console2.sol\":{\"keccak256\":\"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d\",\"dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ\"]},\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]},\"lib/forge-std/src/safeconsole.sol\":{\"keccak256\":\"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab\",\"dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3\"]},\"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol\":{\"keccak256\":\"0x3fdec03d51d77fcda6d6c681e26e7c8d4b85f1457eac91e0ec15411a7ab1e1f6\",\"license\":\"UNLICENSED\",\"urls\":[\"bzz-raw://a690bf4481a37f3f77acdeecac089462db83f0437307610981b24c04b5202f6e\",\"dweb:/ipfs/QmUA9TSjAkqefNBW8BiRqg8XDJiJxJPxSsZHQwJJAbrYQg\"]},\"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol\":{\"keccak256\":\"0x0a17871e1017f36a664b877f5b0db297dc998fdf8b0ab82d00ca50d5bdde88f7\",\"license\":\"UNLICENSED\",\"urls\":[\"bzz-raw://160bc0d890492792f85dfea939160290d90562b27154f64c39c2a615243518a6\",\"dweb:/ipfs/QmbxmqPpTAH7X45G75UjmLh3RSTDj7trMtmkGU6RXmRyEJ\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[],"stateMutability":"view","type":"function","name":"IS_SCRIPT","outputs":[{"internalType":"bool","name":"","type":"bool"}]}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol":"SingletonDeployer"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/Script.sol":{"keccak256":"0xc942e27c7baae499beb01afbbae99f24d42af9a6e4aae675bc6901b704aa8e9b","urls":["bzz-raw://0456008adf68947247f358b62863af4a8e349549d2260f2ff9569ff0e3cf5c98","dweb:/ipfs/QmdviSUj2i7o3TPN5vd2xocqGMFVqjUzaiJTZRYyPxyHPx"],"license":"MIT"},"lib/forge-std/src/StdChains.sol":{"keccak256":"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa","urls":["bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2","dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe"],"license":"MIT"},"lib/forge-std/src/StdCheats.sol":{"keccak256":"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746","urls":["bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41","dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK"],"license":"MIT"},"lib/forge-std/src/StdConstants.sol":{"keccak256":"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534","urls":["bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc","dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r"],"license":"MIT"},"lib/forge-std/src/StdJson.sol":{"keccak256":"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500","urls":["bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974","dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3"],"license":"MIT"},"lib/forge-std/src/StdMath.sol":{"keccak256":"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2","urls":["bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92","dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/StdStyle.sol":{"keccak256":"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d","urls":["bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8","dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK"],"license":"MIT"},"lib/forge-std/src/StdUtils.sol":{"keccak256":"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8","urls":["bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a","dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"},"lib/forge-std/src/console2.sol":{"keccak256":"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f","urls":["bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d","dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ"],"license":"MIT"},"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"},"lib/forge-std/src/safeconsole.sol":{"keccak256":"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11","urls":["bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab","dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3"],"license":"MIT"},"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol":{"keccak256":"0x3fdec03d51d77fcda6d6c681e26e7c8d4b85f1457eac91e0ec15411a7ab1e1f6","urls":["bzz-raw://a690bf4481a37f3f77acdeecac089462db83f0437307610981b24c04b5202f6e","dweb:/ipfs/QmUA9TSjAkqefNBW8BiRqg8XDJiJxJPxSsZHQwJJAbrYQg"],"license":"UNLICENSED"},"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol":{"keccak256":"0x0a17871e1017f36a664b877f5b0db297dc998fdf8b0ab82d00ca50d5bdde88f7","urls":["bzz-raw://160bc0d890492792f85dfea939160290d90562b27154f64c39c2a615243518a6","dweb:/ipfs/QmbxmqPpTAH7X45G75UjmLh3RSTDj7trMtmkGU6RXmRyEJ"],"license":"UNLICENSED"}},"version":1},"id":15} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdAssertions.sol/StdAssertions.json b/lib/signals-implicit-mode/out/StdAssertions.sol/StdAssertions.json deleted file mode 100644 index 5724030a4c..0000000000 --- a/lib/signals-implicit-mode/out/StdAssertions.sol/StdAssertions.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"failed","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"event","name":"log","inputs":[{"name":"","type":"string","indexed":false,"internalType":"string"}],"anonymous":false},{"type":"event","name":"log_address","inputs":[{"name":"","type":"address","indexed":false,"internalType":"address"}],"anonymous":false},{"type":"event","name":"log_array","inputs":[{"name":"val","type":"uint256[]","indexed":false,"internalType":"uint256[]"}],"anonymous":false},{"type":"event","name":"log_array","inputs":[{"name":"val","type":"int256[]","indexed":false,"internalType":"int256[]"}],"anonymous":false},{"type":"event","name":"log_array","inputs":[{"name":"val","type":"address[]","indexed":false,"internalType":"address[]"}],"anonymous":false},{"type":"event","name":"log_bytes","inputs":[{"name":"","type":"bytes","indexed":false,"internalType":"bytes"}],"anonymous":false},{"type":"event","name":"log_bytes32","inputs":[{"name":"","type":"bytes32","indexed":false,"internalType":"bytes32"}],"anonymous":false},{"type":"event","name":"log_int","inputs":[{"name":"","type":"int256","indexed":false,"internalType":"int256"}],"anonymous":false},{"type":"event","name":"log_named_address","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"address","indexed":false,"internalType":"address"}],"anonymous":false},{"type":"event","name":"log_named_array","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"uint256[]","indexed":false,"internalType":"uint256[]"}],"anonymous":false},{"type":"event","name":"log_named_array","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"int256[]","indexed":false,"internalType":"int256[]"}],"anonymous":false},{"type":"event","name":"log_named_array","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"address[]","indexed":false,"internalType":"address[]"}],"anonymous":false},{"type":"event","name":"log_named_bytes","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"bytes","indexed":false,"internalType":"bytes"}],"anonymous":false},{"type":"event","name":"log_named_bytes32","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"bytes32","indexed":false,"internalType":"bytes32"}],"anonymous":false},{"type":"event","name":"log_named_decimal_int","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"int256","indexed":false,"internalType":"int256"},{"name":"decimals","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"log_named_decimal_uint","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"uint256","indexed":false,"internalType":"uint256"},{"name":"decimals","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"log_named_int","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"int256","indexed":false,"internalType":"int256"}],"anonymous":false},{"type":"event","name":"log_named_string","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"string","indexed":false,"internalType":"string"}],"anonymous":false},{"type":"event","name":"log_named_uint","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"log_string","inputs":[{"name":"","type":"string","indexed":false,"internalType":"string"}],"anonymous":false},{"type":"event","name":"log_uint","inputs":[{"name":"","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"logs","inputs":[{"name":"","type":"bytes","indexed":false,"internalType":"bytes"}],"anonymous":false}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"failed()":"ba414fa6"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"name\":\"log\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"log_address\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"val\",\"type\":\"uint256[]\"}],\"name\":\"log_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"int256[]\",\"name\":\"val\",\"type\":\"int256[]\"}],\"name\":\"log_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"val\",\"type\":\"address[]\"}],\"name\":\"log_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"log_bytes\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"log_bytes32\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"name\":\"log_int\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"val\",\"type\":\"address\"}],\"name\":\"log_named_address\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"val\",\"type\":\"uint256[]\"}],\"name\":\"log_named_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"int256[]\",\"name\":\"val\",\"type\":\"int256[]\"}],\"name\":\"log_named_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"val\",\"type\":\"address[]\"}],\"name\":\"log_named_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"val\",\"type\":\"bytes\"}],\"name\":\"log_named_bytes\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"val\",\"type\":\"bytes32\"}],\"name\":\"log_named_bytes32\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"val\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"log_named_decimal_int\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"val\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"log_named_decimal_uint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"val\",\"type\":\"int256\"}],\"name\":\"log_named_int\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"val\",\"type\":\"string\"}],\"name\":\"log_named_string\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"val\",\"type\":\"uint256\"}],\"name\":\"log_named_uint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"name\":\"log_string\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"log_uint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"logs\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"failed\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdAssertions.sol\":\"StdAssertions\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdAssertions.sol\":{\"keccak256\":\"0xd8eec16034b53b52c90a3d720e121ce7d30d64cc57d854db7d817d5b382dda43\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://612780755e32668c7e3b747d94d16c7291101144e084dd9ee563f071711e99e3\",\"dweb:/ipfs/QmQgtFJXEmDtSHT7tZQTMbb6PCDpq5UDYFvrBnWk1Xo2SY\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"string","name":"","type":"string","indexed":false}],"type":"event","name":"log","anonymous":false},{"inputs":[{"internalType":"address","name":"","type":"address","indexed":false}],"type":"event","name":"log_address","anonymous":false},{"inputs":[{"internalType":"uint256[]","name":"val","type":"uint256[]","indexed":false}],"type":"event","name":"log_array","anonymous":false},{"inputs":[{"internalType":"int256[]","name":"val","type":"int256[]","indexed":false}],"type":"event","name":"log_array","anonymous":false},{"inputs":[{"internalType":"address[]","name":"val","type":"address[]","indexed":false}],"type":"event","name":"log_array","anonymous":false},{"inputs":[{"internalType":"bytes","name":"","type":"bytes","indexed":false}],"type":"event","name":"log_bytes","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32","indexed":false}],"type":"event","name":"log_bytes32","anonymous":false},{"inputs":[{"internalType":"int256","name":"","type":"int256","indexed":false}],"type":"event","name":"log_int","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"address","name":"val","type":"address","indexed":false}],"type":"event","name":"log_named_address","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"uint256[]","name":"val","type":"uint256[]","indexed":false}],"type":"event","name":"log_named_array","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"int256[]","name":"val","type":"int256[]","indexed":false}],"type":"event","name":"log_named_array","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"address[]","name":"val","type":"address[]","indexed":false}],"type":"event","name":"log_named_array","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"bytes","name":"val","type":"bytes","indexed":false}],"type":"event","name":"log_named_bytes","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"bytes32","name":"val","type":"bytes32","indexed":false}],"type":"event","name":"log_named_bytes32","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"int256","name":"val","type":"int256","indexed":false},{"internalType":"uint256","name":"decimals","type":"uint256","indexed":false}],"type":"event","name":"log_named_decimal_int","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"uint256","name":"val","type":"uint256","indexed":false},{"internalType":"uint256","name":"decimals","type":"uint256","indexed":false}],"type":"event","name":"log_named_decimal_uint","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"int256","name":"val","type":"int256","indexed":false}],"type":"event","name":"log_named_int","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"string","name":"val","type":"string","indexed":false}],"type":"event","name":"log_named_string","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"uint256","name":"val","type":"uint256","indexed":false}],"type":"event","name":"log_named_uint","anonymous":false},{"inputs":[{"internalType":"string","name":"","type":"string","indexed":false}],"type":"event","name":"log_string","anonymous":false},{"inputs":[{"internalType":"uint256","name":"","type":"uint256","indexed":false}],"type":"event","name":"log_uint","anonymous":false},{"inputs":[{"internalType":"bytes","name":"","type":"bytes","indexed":false}],"type":"event","name":"logs","anonymous":false},{"inputs":[],"stateMutability":"view","type":"function","name":"failed","outputs":[{"internalType":"bool","name":"","type":"bool"}]}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdAssertions.sol":"StdAssertions"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdAssertions.sol":{"keccak256":"0xd8eec16034b53b52c90a3d720e121ce7d30d64cc57d854db7d817d5b382dda43","urls":["bzz-raw://612780755e32668c7e3b747d94d16c7291101144e084dd9ee563f071711e99e3","dweb:/ipfs/QmQgtFJXEmDtSHT7tZQTMbb6PCDpq5UDYFvrBnWk1Xo2SY"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"}},"version":1},"id":1} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdChains.sol/StdChains.json b/lib/signals-implicit-mode/out/StdChains.sol/StdChains.json deleted file mode 100644 index d5ba6c0caf..0000000000 --- a/lib/signals-implicit-mode/out/StdChains.sol/StdChains.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"notice\":\"StdChains provides information about EVM compatible chains that can be used in scripts/tests. For each chain, the chain's name, chain ID, and a default RPC URL are provided. Chains are identified by their alias, which is the same as the alias in the `[rpc_endpoints]` section of the `foundry.toml` file. For best UX, ensure the alias in the `foundry.toml` file match the alias used in this contract, which can be found as the first argument to the `setChainWithDefaultRpcUrl` call in the `initializeStdChains` function. There are two main ways to use this contract: 1. Set a chain with `setChain(string memory chainAlias, ChainData memory chain)` or `setChain(string memory chainAlias, Chain memory chain)` 2. Get a chain with `getChain(string memory chainAlias)` or `getChain(uint256 chainId)`. The first time either of those are used, chains are initialized with the default set of RPC URLs. This is done in `initializeStdChains`, which uses `setChainWithDefaultRpcUrl`. Defaults are recorded in `defaultRpcUrls`. The `setChain` function is straightforward, and it simply saves off the given chain data. The `getChain` methods use `getChainWithUpdatedRpcUrl` to return a chain. For example, let's say we want to retrieve the RPC URL for `mainnet`: - If you have specified data with `setChain`, it will return that. - If you have configured a mainnet RPC URL in `foundry.toml`, it will return the URL, provided it is valid (e.g. a URL is specified, or an environment variable is given and exists). - If neither of the above conditions is met, the default data is returned. Summarizing the above, the prioritization hierarchy is `setChain` -> `foundry.toml` -> environment variable -> defaults.\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdChains.sol\":\"StdChains\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdChains.sol\":{\"keccak256\":\"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2\",\"dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdChains.sol":"StdChains"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdChains.sol":{"keccak256":"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa","urls":["bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2","dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"}},"version":1},"id":2} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdCheats.sol/StdCheats.json b/lib/signals-implicit-mode/out/StdCheats.sol/StdCheats.json deleted file mode 100644 index 6dd1fe067c..0000000000 --- a/lib/signals-implicit-mode/out/StdCheats.sol/StdCheats.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdCheats.sol\":\"StdCheats\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdCheats.sol\":{\"keccak256\":\"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41\",\"dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]},\"lib/forge-std/src/console2.sol\":{\"keccak256\":\"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d\",\"dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdCheats.sol":"StdCheats"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdCheats.sol":{"keccak256":"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746","urls":["bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41","dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"},"lib/forge-std/src/console2.sol":{"keccak256":"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f","urls":["bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d","dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ"],"license":"MIT"}},"version":1},"id":3} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdCheats.sol/StdCheatsSafe.json b/lib/signals-implicit-mode/out/StdCheats.sol/StdCheatsSafe.json deleted file mode 100644 index 766c8f7b46..0000000000 --- a/lib/signals-implicit-mode/out/StdCheats.sol/StdCheatsSafe.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdCheats.sol\":\"StdCheatsSafe\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdCheats.sol\":{\"keccak256\":\"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41\",\"dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]},\"lib/forge-std/src/console2.sol\":{\"keccak256\":\"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d\",\"dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdCheats.sol":"StdCheatsSafe"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdCheats.sol":{"keccak256":"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746","urls":["bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41","dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"},"lib/forge-std/src/console2.sol":{"keccak256":"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f","urls":["bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d","dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ"],"license":"MIT"}},"version":1},"id":3} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdConstants.sol/StdConstants.json b/lib/signals-implicit-mode/out/StdConstants.sol/StdConstants.json deleted file mode 100644 index 9e60b54435..0000000000 --- a/lib/signals-implicit-mode/out/StdConstants.sol/StdConstants.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x60566050600b82828239805160001a6073146043577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220189061ae74c004758b610140990ebe4d7ef2dd37e875408ebee4328894fb40ef64736f6c634300081c0033","sourceMap":"153:1713:4:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220189061ae74c004758b610140990ebe4d7ef2dd37e875408ebee4328894fb40ef64736f6c634300081c0033","sourceMap":"153:1713:4:-:0;;;;;;;;","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"stateVariables\":{\"CONSOLE\":{\"details\":\"console.sol and console2.sol work by executing a staticcall to this address. Calculated as `address(uint160(uint88(bytes11(\\\"console.log\\\"))))`.\"},\"CREATE2_FACTORY\":{\"details\":\"Used when deploying with create2. Taken from https://github.com/Arachnid/deterministic-deployment-proxy.\"},\"DEFAULT_SENDER\":{\"details\":\"The default address for tx.origin and msg.sender. Calculated as `address(uint160(uint256(keccak256(\\\"foundry default caller\\\"))))`.\"},\"DEFAULT_TEST_CONTRACT\":{\"details\":\"The address of the first contract `CREATE`d by a running test contract. When running tests, each test contract is `CREATE`d by `DEFAULT_SENDER` with nonce 1. Calculated as `VM.computeCreateAddress(VM.computeCreateAddress(DEFAULT_SENDER, 1), 1)`.\"},\"MULTICALL3_ADDRESS\":{\"details\":\"Deterministic deployment address of the Multicall3 contract. Taken from https://www.multicall3.com.\"},\"SECP256K1_ORDER\":{\"details\":\"The order of the secp256k1 curve.\"},\"VM\":{\"details\":\"Cheat code address. Calculated as `address(uint160(uint256(keccak256(\\\"hevm cheat code\\\"))))`.\"}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdConstants.sol\":\"StdConstants\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdConstants.sol\":{\"keccak256\":\"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc\",\"dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdConstants.sol":"StdConstants"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdConstants.sol":{"keccak256":"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534","urls":["bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc","dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"}},"version":1},"id":4} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdError.sol/stdError.json b/lib/signals-implicit-mode/out/StdError.sol/stdError.json deleted file mode 100644 index f0be3a8ab4..0000000000 --- a/lib/signals-implicit-mode/out/StdError.sol/stdError.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"arithmeticError","inputs":[],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"assertionError","inputs":[],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"divisionError","inputs":[],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"encodeStorageError","inputs":[],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"enumConversionError","inputs":[],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"indexOOBError","inputs":[],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"memOverflowError","inputs":[],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"popError","inputs":[],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"zeroVarError","inputs":[],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"}],"bytecode":{"object":"0x610ad7610052600b82828239805160001a6073146045577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe730000000000000000000000000000000000000000301460806040526004361061009d5760003560e01c8063986c5f6811610070578063986c5f681461011a578063b22dc54d14610138578063b67689da14610156578063d160e4de14610174578063fa784a44146101925761009d565b806305ee8612146100a257806310332977146100c05780631de45560146100de5780638995290f146100fc575b600080fd5b6100aa6101b0565b6040516100b79190610762565b60405180910390f35b6100c8610242565b6040516100d59190610762565b60405180910390f35b6100e66102d4565b6040516100f39190610762565b60405180910390f35b610104610366565b6040516101119190610762565b60405180910390f35b6101226103f8565b60405161012f9190610762565b60405180910390f35b61014061048a565b60405161014d9190610762565b60405180910390f35b61015e61051c565b60405161016b9190610762565b60405180910390f35b61017c6105ae565b6040516101899190610762565b60405180910390f35b61019a610640565b6040516101a79190610762565b60405180910390f35b60326040516024016101c291906107d6565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b6001604051602401610254919061082c565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b60216040516024016102e69190610882565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b601160405160240161037891906108d8565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b604160405160240161040a919061092e565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b603160405160240161049c9190610984565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b605160405160240161052e91906109da565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b60226040516024016105c09190610a30565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b60126040516024016106529190610a86565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b600081519050919050565b600082825260208201905092915050565b60005b8381101561070c5780820151818401526020810190506106f1565b60008484015250505050565b6000601f19601f8301169050919050565b6000610734826106d2565b61073e81856106dd565b935061074e8185602086016106ee565b61075781610718565b840191505092915050565b6000602082019050818103600083015261077c8184610729565b905092915050565b6000819050919050565b600060ff82169050919050565b6000819050919050565b60006107c06107bb6107b684610784565b61079b565b61078e565b9050919050565b6107d0816107a5565b82525050565b60006020820190506107eb60008301846107c7565b92915050565b6000819050919050565b600061081661081161080c846107f1565b61079b565b61078e565b9050919050565b610826816107fb565b82525050565b6000602082019050610841600083018461081d565b92915050565b6000819050919050565b600061086c61086761086284610847565b61079b565b61078e565b9050919050565b61087c81610851565b82525050565b60006020820190506108976000830184610873565b92915050565b6000819050919050565b60006108c26108bd6108b88461089d565b61079b565b61078e565b9050919050565b6108d2816108a7565b82525050565b60006020820190506108ed60008301846108c9565b92915050565b6000819050919050565b600061091861091361090e846108f3565b61079b565b61078e565b9050919050565b610928816108fd565b82525050565b6000602082019050610943600083018461091f565b92915050565b6000819050919050565b600061096e61096961096484610949565b61079b565b61078e565b9050919050565b61097e81610953565b82525050565b60006020820190506109996000830184610975565b92915050565b6000819050919050565b60006109c46109bf6109ba8461099f565b61079b565b61078e565b9050919050565b6109d4816109a9565b82525050565b60006020820190506109ef60008301846109cb565b92915050565b6000819050919050565b6000610a1a610a15610a10846109f5565b61079b565b61078e565b9050919050565b610a2a816109ff565b82525050565b6000602082019050610a456000830184610a21565b92915050565b6000819050919050565b6000610a70610a6b610a6684610a4b565b61079b565b61078e565b9050919050565b610a8081610a55565b82525050565b6000602082019050610a9b6000830184610a77565b9291505056fea264697066735822122072c12037a1f19240fca15482aef67291d4236e161591ad9525d146211c74d46664736f6c634300081c0033","sourceMap":"162:850:5:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x730000000000000000000000000000000000000000301460806040526004361061009d5760003560e01c8063986c5f6811610070578063986c5f681461011a578063b22dc54d14610138578063b67689da14610156578063d160e4de14610174578063fa784a44146101925761009d565b806305ee8612146100a257806310332977146100c05780631de45560146100de5780638995290f146100fc575b600080fd5b6100aa6101b0565b6040516100b79190610762565b60405180910390f35b6100c8610242565b6040516100d59190610762565b60405180910390f35b6100e66102d4565b6040516100f39190610762565b60405180910390f35b610104610366565b6040516101119190610762565b60405180910390f35b6101226103f8565b60405161012f9190610762565b60405180910390f35b61014061048a565b60405161014d9190610762565b60405180910390f35b61015e61051c565b60405161016b9190610762565b60405180910390f35b61017c6105ae565b6040516101899190610762565b60405180910390f35b61019a610640565b6040516101a79190610762565b60405180910390f35b60326040516024016101c291906107d6565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b6001604051602401610254919061082c565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b60216040516024016102e69190610882565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b601160405160240161037891906108d8565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b604160405160240161040a919061092e565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b603160405160240161049c9190610984565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b605160405160240161052e91906109da565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b60226040516024016105c09190610a30565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b60126040516024016106529190610a86565b6040516020818303038152906040527f4e487b71000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505081565b600081519050919050565b600082825260208201905092915050565b60005b8381101561070c5780820151818401526020810190506106f1565b60008484015250505050565b6000601f19601f8301169050919050565b6000610734826106d2565b61073e81856106dd565b935061074e8185602086016106ee565b61075781610718565b840191505092915050565b6000602082019050818103600083015261077c8184610729565b905092915050565b6000819050919050565b600060ff82169050919050565b6000819050919050565b60006107c06107bb6107b684610784565b61079b565b61078e565b9050919050565b6107d0816107a5565b82525050565b60006020820190506107eb60008301846107c7565b92915050565b6000819050919050565b600061081661081161080c846107f1565b61079b565b61078e565b9050919050565b610826816107fb565b82525050565b6000602082019050610841600083018461081d565b92915050565b6000819050919050565b600061086c61086761086284610847565b61079b565b61078e565b9050919050565b61087c81610851565b82525050565b60006020820190506108976000830184610873565b92915050565b6000819050919050565b60006108c26108bd6108b88461089d565b61079b565b61078e565b9050919050565b6108d2816108a7565b82525050565b60006020820190506108ed60008301846108c9565b92915050565b6000819050919050565b600061091861091361090e846108f3565b61079b565b61078e565b9050919050565b610928816108fd565b82525050565b6000602082019050610943600083018461091f565b92915050565b6000819050919050565b600061096e61096961096484610949565b61079b565b61078e565b9050919050565b61097e81610953565b82525050565b60006020820190506109996000830184610975565b92915050565b6000819050919050565b60006109c46109bf6109ba8461099f565b61079b565b61078e565b9050919050565b6109d4816109a9565b82525050565b60006020820190506109ef60008301846109cb565b92915050565b6000819050919050565b6000610a1a610a15610a10846109f5565b61079b565b61078e565b9050919050565b610a2a816109ff565b82525050565b6000602082019050610a456000830184610a21565b92915050565b6000819050919050565b6000610a70610a6b610a6684610a4b565b61079b565b61078e565b9050919050565b610a8081610a55565b82525050565b6000602082019050610a9b6000830184610a77565b9291505056fea264697066735822122072c12037a1f19240fca15482aef67291d4236e161591ad9525d146211c74d46664736f6c634300081c0033","sourceMap":"162:850:5:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;740:85;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;185:86;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;461:91;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;277:87;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;831:88;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;654:80;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;925:84;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;558:90;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;370:85;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;740;820:4;778:47;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;740:85;:::o;185:86::-;266:4;224:47;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;185:86;:::o;461:91::-;547:4;505:47;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;461:91;:::o;277:87::-;359:4;317:47;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;277:87;:::o;831:88::-;914:4;872:47;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;831:88;:::o;654:80::-;729:4;687:47;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;654:80;:::o;925:84::-;1004:4;962:47;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;925:84;:::o;558:90::-;643:4;601:47;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;558:90;:::o;370:85::-;450:4;408:47;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;370:85;:::o;7:98:33:-;58:6;92:5;86:12;76:22;;7:98;;;:::o;111:176::-;202:11;236:6;231:3;224:19;276:4;271:3;267:14;252:29;;111:176;;;;:::o;293:248::-;375:1;385:113;399:6;396:1;393:13;385:113;;;484:1;479:3;475:11;469:18;465:1;460:3;456:11;449:39;421:2;418:1;414:10;409:15;;385:113;;;532:1;523:6;518:3;514:16;507:27;355:186;293:248;;;:::o;547:102::-;588:6;639:2;635:7;630:2;623:5;619:14;615:28;605:38;;547:102;;;:::o;655:389::-;749:3;777:38;809:5;777:38;:::i;:::-;831:78;902:6;897:3;831:78;:::i;:::-;824:85;;918:65;976:6;971:3;964:4;957:5;953:16;918:65;:::i;:::-;1008:29;1030:6;1008:29;:::i;:::-;1003:3;999:39;992:46;;753:291;655:389;;;;:::o;1050:325::-;1169:4;1207:2;1196:9;1192:18;1184:26;;1256:9;1250:4;1246:20;1242:1;1231:9;1227:17;1220:47;1284:84;1363:4;1354:6;1284:84;:::i;:::-;1276:92;;1050:325;;;;:::o;1381:86::-;1427:7;1456:5;1445:16;;1381:86;;;:::o;1473:::-;1508:7;1548:4;1541:5;1537:16;1526:27;;1473:86;;;:::o;1565:60::-;1593:3;1614:5;1607:12;;1565:60;;;:::o;1631:156::-;1688:9;1721:60;1737:43;1746:33;1773:5;1746:33;:::i;:::-;1737:43;:::i;:::-;1721:60;:::i;:::-;1708:73;;1631:156;;;:::o;1793:145::-;1887:44;1925:5;1887:44;:::i;:::-;1882:3;1875:57;1793:145;;:::o;1944:236::-;2044:4;2082:2;2071:9;2067:18;2059:26;;2095:78;2170:1;2159:9;2155:17;2146:6;2095:78;:::i;:::-;1944:236;;;;:::o;2186:85::-;2231:7;2260:5;2249:16;;2186:85;;;:::o;2277:154::-;2333:9;2366:59;2382:42;2391:32;2417:5;2391:32;:::i;:::-;2382:42;:::i;:::-;2366:59;:::i;:::-;2353:72;;2277:154;;;:::o;2437:143::-;2530:43;2567:5;2530:43;:::i;:::-;2525:3;2518:56;2437:143;;:::o;2586:234::-;2685:4;2723:2;2712:9;2708:18;2700:26;;2736:77;2810:1;2799:9;2795:17;2786:6;2736:77;:::i;:::-;2586:234;;;;:::o;2826:86::-;2872:7;2901:5;2890:16;;2826:86;;;:::o;2918:156::-;2975:9;3008:60;3024:43;3033:33;3060:5;3033:33;:::i;:::-;3024:43;:::i;:::-;3008:60;:::i;:::-;2995:73;;2918:156;;;:::o;3080:145::-;3174:44;3212:5;3174:44;:::i;:::-;3169:3;3162:57;3080:145;;:::o;3231:236::-;3331:4;3369:2;3358:9;3354:18;3346:26;;3382:78;3457:1;3446:9;3442:17;3433:6;3382:78;:::i;:::-;3231:236;;;;:::o;3473:86::-;3519:7;3548:5;3537:16;;3473:86;;;:::o;3565:156::-;3622:9;3655:60;3671:43;3680:33;3707:5;3680:33;:::i;:::-;3671:43;:::i;:::-;3655:60;:::i;:::-;3642:73;;3565:156;;;:::o;3727:145::-;3821:44;3859:5;3821:44;:::i;:::-;3816:3;3809:57;3727:145;;:::o;3878:236::-;3978:4;4016:2;4005:9;4001:18;3993:26;;4029:78;4104:1;4093:9;4089:17;4080:6;4029:78;:::i;:::-;3878:236;;;;:::o;4120:86::-;4166:7;4195:5;4184:16;;4120:86;;;:::o;4212:156::-;4269:9;4302:60;4318:43;4327:33;4354:5;4327:33;:::i;:::-;4318:43;:::i;:::-;4302:60;:::i;:::-;4289:73;;4212:156;;;:::o;4374:145::-;4468:44;4506:5;4468:44;:::i;:::-;4463:3;4456:57;4374:145;;:::o;4525:236::-;4625:4;4663:2;4652:9;4648:18;4640:26;;4676:78;4751:1;4740:9;4736:17;4727:6;4676:78;:::i;:::-;4525:236;;;;:::o;4767:86::-;4813:7;4842:5;4831:16;;4767:86;;;:::o;4859:156::-;4916:9;4949:60;4965:43;4974:33;5001:5;4974:33;:::i;:::-;4965:43;:::i;:::-;4949:60;:::i;:::-;4936:73;;4859:156;;;:::o;5021:145::-;5115:44;5153:5;5115:44;:::i;:::-;5110:3;5103:57;5021:145;;:::o;5172:236::-;5272:4;5310:2;5299:9;5295:18;5287:26;;5323:78;5398:1;5387:9;5383:17;5374:6;5323:78;:::i;:::-;5172:236;;;;:::o;5414:86::-;5460:7;5489:5;5478:16;;5414:86;;;:::o;5506:156::-;5563:9;5596:60;5612:43;5621:33;5648:5;5621:33;:::i;:::-;5612:43;:::i;:::-;5596:60;:::i;:::-;5583:73;;5506:156;;;:::o;5668:145::-;5762:44;5800:5;5762:44;:::i;:::-;5757:3;5750:57;5668:145;;:::o;5819:236::-;5919:4;5957:2;5946:9;5942:18;5934:26;;5970:78;6045:1;6034:9;6030:17;6021:6;5970:78;:::i;:::-;5819:236;;;;:::o;6061:86::-;6107:7;6136:5;6125:16;;6061:86;;;:::o;6153:156::-;6210:9;6243:60;6259:43;6268:33;6295:5;6268:33;:::i;:::-;6259:43;:::i;:::-;6243:60;:::i;:::-;6230:73;;6153:156;;;:::o;6315:145::-;6409:44;6447:5;6409:44;:::i;:::-;6404:3;6397:57;6315:145;;:::o;6466:236::-;6566:4;6604:2;6593:9;6589:18;6581:26;;6617:78;6692:1;6681:9;6677:17;6668:6;6617:78;:::i;:::-;6466:236;;;;:::o;6708:86::-;6754:7;6783:5;6772:16;;6708:86;;;:::o;6800:156::-;6857:9;6890:60;6906:43;6915:33;6942:5;6915:33;:::i;:::-;6906:43;:::i;:::-;6890:60;:::i;:::-;6877:73;;6800:156;;;:::o;6962:145::-;7056:44;7094:5;7056:44;:::i;:::-;7051:3;7044:57;6962:145;;:::o;7113:236::-;7213:4;7251:2;7240:9;7236:18;7228:26;;7264:78;7339:1;7328:9;7324:17;7315:6;7264:78;:::i;:::-;7113:236;;;;:::o","linkReferences":{}},"methodIdentifiers":{"arithmeticError()":"8995290f","assertionError()":"10332977","divisionError()":"fa784a44","encodeStorageError()":"d160e4de","enumConversionError()":"1de45560","indexOOBError()":"05ee8612","memOverflowError()":"986c5f68","popError()":"b22dc54d","zeroVarError()":"b67689da"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"name\":\"arithmeticError\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"assertionError\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"divisionError\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"encodeStorageError\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"enumConversionError\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"indexOOBError\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"memOverflowError\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"popError\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"zeroVarError\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdError.sol\":\"stdError\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdError.sol\":{\"keccak256\":\"0xbf477b11a42d7611696956546bcfaa29317d1166bf65e402344599c05943fc77\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://bc2e117d1135e030862b96a6526a43feb38d396cc79857f1fb696d4eff0e5fd6\",\"dweb:/ipfs/QmdSuQ5RrQudTLsNmWXGEeVJX8gR5U9XPm6m4dwwuQnJrj\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[],"stateMutability":"view","type":"function","name":"arithmeticError","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"assertionError","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"divisionError","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"encodeStorageError","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"enumConversionError","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"indexOOBError","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"memOverflowError","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"popError","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"zeroVarError","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdError.sol":"stdError"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdError.sol":{"keccak256":"0xbf477b11a42d7611696956546bcfaa29317d1166bf65e402344599c05943fc77","urls":["bzz-raw://bc2e117d1135e030862b96a6526a43feb38d396cc79857f1fb696d4eff0e5fd6","dweb:/ipfs/QmdSuQ5RrQudTLsNmWXGEeVJX8gR5U9XPm6m4dwwuQnJrj"],"license":"MIT"}},"version":1},"id":5} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdInvariant.sol/StdInvariant.json b/lib/signals-implicit-mode/out/StdInvariant.sol/StdInvariant.json deleted file mode 100644 index ed343947e6..0000000000 --- a/lib/signals-implicit-mode/out/StdInvariant.sol/StdInvariant.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"excludeArtifacts","inputs":[],"outputs":[{"name":"excludedArtifacts_","type":"string[]","internalType":"string[]"}],"stateMutability":"view"},{"type":"function","name":"excludeContracts","inputs":[],"outputs":[{"name":"excludedContracts_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"excludeSelectors","inputs":[],"outputs":[{"name":"excludedSelectors_","type":"tuple[]","internalType":"struct StdInvariant.FuzzSelector[]","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"selectors","type":"bytes4[]","internalType":"bytes4[]"}]}],"stateMutability":"view"},{"type":"function","name":"excludeSenders","inputs":[],"outputs":[{"name":"excludedSenders_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"targetArtifactSelectors","inputs":[],"outputs":[{"name":"targetedArtifactSelectors_","type":"tuple[]","internalType":"struct StdInvariant.FuzzArtifactSelector[]","components":[{"name":"artifact","type":"string","internalType":"string"},{"name":"selectors","type":"bytes4[]","internalType":"bytes4[]"}]}],"stateMutability":"view"},{"type":"function","name":"targetArtifacts","inputs":[],"outputs":[{"name":"targetedArtifacts_","type":"string[]","internalType":"string[]"}],"stateMutability":"view"},{"type":"function","name":"targetContracts","inputs":[],"outputs":[{"name":"targetedContracts_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"targetInterfaces","inputs":[],"outputs":[{"name":"targetedInterfaces_","type":"tuple[]","internalType":"struct StdInvariant.FuzzInterface[]","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"artifacts","type":"string[]","internalType":"string[]"}]}],"stateMutability":"view"},{"type":"function","name":"targetSelectors","inputs":[],"outputs":[{"name":"targetedSelectors_","type":"tuple[]","internalType":"struct StdInvariant.FuzzSelector[]","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"selectors","type":"bytes4[]","internalType":"bytes4[]"}]}],"stateMutability":"view"},{"type":"function","name":"targetSenders","inputs":[],"outputs":[{"name":"targetedSenders_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"excludeArtifacts()":"b5508aa9","excludeContracts()":"e20c9f71","excludeSelectors()":"b0464fdc","excludeSenders()":"1ed7831c","targetArtifactSelectors()":"66d9a9a0","targetArtifacts()":"85226c81","targetContracts()":"3f7286f4","targetInterfaces()":"2ade3880","targetSelectors()":"916a17c6","targetSenders()":"3e5e3c23"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"name\":\"excludeArtifacts\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"excludedArtifacts_\",\"type\":\"string[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeContracts\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"excludedContracts_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeSelectors\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"bytes4[]\",\"name\":\"selectors\",\"type\":\"bytes4[]\"}],\"internalType\":\"struct StdInvariant.FuzzSelector[]\",\"name\":\"excludedSelectors_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"excludedSenders_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetArtifactSelectors\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"artifact\",\"type\":\"string\"},{\"internalType\":\"bytes4[]\",\"name\":\"selectors\",\"type\":\"bytes4[]\"}],\"internalType\":\"struct StdInvariant.FuzzArtifactSelector[]\",\"name\":\"targetedArtifactSelectors_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetArtifacts\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"targetedArtifacts_\",\"type\":\"string[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetContracts\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"targetedContracts_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetInterfaces\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"string[]\",\"name\":\"artifacts\",\"type\":\"string[]\"}],\"internalType\":\"struct StdInvariant.FuzzInterface[]\",\"name\":\"targetedInterfaces_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetSelectors\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"bytes4[]\",\"name\":\"selectors\",\"type\":\"bytes4[]\"}],\"internalType\":\"struct StdInvariant.FuzzSelector[]\",\"name\":\"targetedSelectors_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"targetedSenders_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdInvariant.sol\":\"StdInvariant\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdInvariant.sol\":{\"keccak256\":\"0x4dab3021edfa9511bbdd80c48f060ef62eaf457f99eaf841f561fc2557d9a08d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://07668628673174cf8f27f8f4e1f862bab775013ec247eb34f698c5005f229391\",\"dweb:/ipfs/QmPJsiiYwmCZXMsHmQv5tg8VF3CAhNdat7WnKLTWZZH2v5\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[],"stateMutability":"view","type":"function","name":"excludeArtifacts","outputs":[{"internalType":"string[]","name":"excludedArtifacts_","type":"string[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeContracts","outputs":[{"internalType":"address[]","name":"excludedContracts_","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeSelectors","outputs":[{"internalType":"struct StdInvariant.FuzzSelector[]","name":"excludedSelectors_","type":"tuple[]","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"bytes4[]","name":"selectors","type":"bytes4[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeSenders","outputs":[{"internalType":"address[]","name":"excludedSenders_","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetArtifactSelectors","outputs":[{"internalType":"struct StdInvariant.FuzzArtifactSelector[]","name":"targetedArtifactSelectors_","type":"tuple[]","components":[{"internalType":"string","name":"artifact","type":"string"},{"internalType":"bytes4[]","name":"selectors","type":"bytes4[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetArtifacts","outputs":[{"internalType":"string[]","name":"targetedArtifacts_","type":"string[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetContracts","outputs":[{"internalType":"address[]","name":"targetedContracts_","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetInterfaces","outputs":[{"internalType":"struct StdInvariant.FuzzInterface[]","name":"targetedInterfaces_","type":"tuple[]","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"string[]","name":"artifacts","type":"string[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetSelectors","outputs":[{"internalType":"struct StdInvariant.FuzzSelector[]","name":"targetedSelectors_","type":"tuple[]","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"bytes4[]","name":"selectors","type":"bytes4[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetSenders","outputs":[{"internalType":"address[]","name":"targetedSenders_","type":"address[]"}]}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdInvariant.sol":"StdInvariant"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdInvariant.sol":{"keccak256":"0x4dab3021edfa9511bbdd80c48f060ef62eaf457f99eaf841f561fc2557d9a08d","urls":["bzz-raw://07668628673174cf8f27f8f4e1f862bab775013ec247eb34f698c5005f229391","dweb:/ipfs/QmPJsiiYwmCZXMsHmQv5tg8VF3CAhNdat7WnKLTWZZH2v5"],"license":"MIT"}},"version":1},"id":6} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdJson.sol/stdJson.json b/lib/signals-implicit-mode/out/StdJson.sol/stdJson.json deleted file mode 100644 index a3b7e694a4..0000000000 --- a/lib/signals-implicit-mode/out/StdJson.sol/stdJson.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x60566050600b82828239805160001a6073146043577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212201d237618d2175f7790702c8b2be9d2c10a9b4e2d3bc2a450d9b08252185c5ae364736f6c634300081c0033","sourceMap":"610:9092:7:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212201d237618d2175f7790702c8b2be9d2c10a9b4e2d3bc2a450d9b08252185c5ae364736f6c634300081c0033","sourceMap":"610:9092:7:-:0;;;;;;;;","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdJson.sol\":\"stdJson\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdJson.sol\":{\"keccak256\":\"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974\",\"dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdJson.sol":"stdJson"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdJson.sol":{"keccak256":"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500","urls":["bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974","dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"}},"version":1},"id":7} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdMath.sol/stdMath.json b/lib/signals-implicit-mode/out/StdMath.sol/stdMath.json deleted file mode 100644 index f84b4af500..0000000000 --- a/lib/signals-implicit-mode/out/StdMath.sol/stdMath.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x60566050600b82828239805160001a6073146043577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212200b0cc2be5037991076856ec7ffc3cd25a60b88b769a1372c4d96f5da1ba5938964736f6c634300081c0033","sourceMap":"65:1294:8:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212200b0cc2be5037991076856ec7ffc3cd25a60b88b769a1372c4d96f5da1ba5938964736f6c634300081c0033","sourceMap":"65:1294:8:-:0;;;;;;;;","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdMath.sol\":\"stdMath\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdMath.sol\":{\"keccak256\":\"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92\",\"dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdMath.sol":"stdMath"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdMath.sol":{"keccak256":"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2","urls":["bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92","dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC"],"license":"MIT"}},"version":1},"id":8} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdStorage.sol/stdStorage.json b/lib/signals-implicit-mode/out/StdStorage.sol/stdStorage.json deleted file mode 100644 index 6a1617dc85..0000000000 --- a/lib/signals-implicit-mode/out/StdStorage.sol/stdStorage.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x60566050600b82828239805160001a6073146043577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea264697066735822122042b459c9fa2e4a1bfe64a2eb65dfa6403e5d4b62a08cf050ab2ac9891be2931064736f6c634300081c0033","sourceMap":"12755:5081:9:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x73000000000000000000000000000000000000000030146080604052600080fdfea264697066735822122042b459c9fa2e4a1bfe64a2eb65dfa6403e5d4b62a08cf050ab2ac9891be2931064736f6c634300081c0033","sourceMap":"12755:5081:9:-:0;;;;;;;;","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdStorage.sol\":\"stdStorage\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdStorage.sol":"stdStorage"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"}},"version":1},"id":9} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdStorage.sol/stdStorageSafe.json b/lib/signals-implicit-mode/out/StdStorage.sol/stdStorageSafe.json deleted file mode 100644 index 922cdb3ea5..0000000000 --- a/lib/signals-implicit-mode/out/StdStorage.sol/stdStorageSafe.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"event","name":"SlotFound","inputs":[{"name":"who","type":"address","indexed":false,"internalType":"address"},{"name":"fsig","type":"bytes4","indexed":false,"internalType":"bytes4"},{"name":"keysHash","type":"bytes32","indexed":false,"internalType":"bytes32"},{"name":"slot","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"WARNING_UninitedSlot","inputs":[{"name":"who","type":"address","indexed":false,"internalType":"address"},{"name":"slot","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false}],"bytecode":{"object":"0x60566050600b82828239805160001a6073146043577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212207d2c906763add3ee4b50c32d73c3d7e7c62cd6bf8078cf8150df92d5d7232c9264736f6c634300081c0033","sourceMap":"450:12303:9:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212207d2c906763add3ee4b50c32d73c3d7e7c62cd6bf8078cf8150df92d5d7232c9264736f6c634300081c0033","sourceMap":"450:12303:9:-:0;;;;;;;;","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"who\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"fsig\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keysHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"slot\",\"type\":\"uint256\"}],\"name\":\"SlotFound\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"who\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"slot\",\"type\":\"uint256\"}],\"name\":\"WARNING_UninitedSlot\",\"type\":\"event\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdStorage.sol\":\"stdStorageSafe\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"address","name":"who","type":"address","indexed":false},{"internalType":"bytes4","name":"fsig","type":"bytes4","indexed":false},{"internalType":"bytes32","name":"keysHash","type":"bytes32","indexed":false},{"internalType":"uint256","name":"slot","type":"uint256","indexed":false}],"type":"event","name":"SlotFound","anonymous":false},{"inputs":[{"internalType":"address","name":"who","type":"address","indexed":false},{"internalType":"uint256","name":"slot","type":"uint256","indexed":false}],"type":"event","name":"WARNING_UninitedSlot","anonymous":false}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdStorage.sol":"stdStorageSafe"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"}},"version":1},"id":9} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdStyle.sol/StdStyle.json b/lib/signals-implicit-mode/out/StdStyle.sol/StdStyle.json deleted file mode 100644 index b09117c47b..0000000000 --- a/lib/signals-implicit-mode/out/StdStyle.sol/StdStyle.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x60566050600b82828239805160001a6073146043577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220c2c560110cb823b4eb053456fbe1bdfcebc1f867652df0b69cf22467abbf472264736f6c634300081c0033","sourceMap":"100:10361:10:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220c2c560110cb823b4eb053456fbe1bdfcebc1f867652df0b69cf22467abbf472264736f6c634300081c0033","sourceMap":"100:10361:10:-:0;;;;;;;;","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdStyle.sol\":\"StdStyle\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdStyle.sol\":{\"keccak256\":\"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8\",\"dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdStyle.sol":"StdStyle"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdStyle.sol":{"keccak256":"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d","urls":["bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8","dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"}},"version":1},"id":10} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdToml.sol/stdToml.json b/lib/signals-implicit-mode/out/StdToml.sol/stdToml.json deleted file mode 100644 index 8a63e90904..0000000000 --- a/lib/signals-implicit-mode/out/StdToml.sol/stdToml.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x60566050600b82828239805160001a6073146043577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220f980ab93872b7e20fb0d6765278c1edf1800ba2ee0f5282ef13cdfdf313032e864736f6c634300081c0033","sourceMap":"610:9092:11:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220f980ab93872b7e20fb0d6765278c1edf1800ba2ee0f5282ef13cdfdf313032e864736f6c634300081c0033","sourceMap":"610:9092:11:-:0;;;;;;;;","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdToml.sol\":\"stdToml\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdToml.sol\":{\"keccak256\":\"0x58a72c765ed3f7ff6b105509689658795b8a3739b8931772a497155878381861\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b4a3746f4fabaeb980bd77d9e091d3904ee38a6c0e191bfa8ba6874c6f8558a3\",\"dweb:/ipfs/QmUfFDMEn461FgGEXt5HicyGD54sc28sLaQ9JRWDMBKed8\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdToml.sol":"stdToml"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdToml.sol":{"keccak256":"0x58a72c765ed3f7ff6b105509689658795b8a3739b8931772a497155878381861","urls":["bzz-raw://b4a3746f4fabaeb980bd77d9e091d3904ee38a6c0e191bfa8ba6874c6f8558a3","dweb:/ipfs/QmUfFDMEn461FgGEXt5HicyGD54sc28sLaQ9JRWDMBKed8"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"}},"version":1},"id":11} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/StdUtils.sol/StdUtils.json b/lib/signals-implicit-mode/out/StdUtils.sol/StdUtils.json deleted file mode 100644 index 759041d37b..0000000000 --- a/lib/signals-implicit-mode/out/StdUtils.sol/StdUtils.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/StdUtils.sol\":\"StdUtils\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/StdUtils.sol\":{\"keccak256\":\"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a\",\"dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/StdUtils.sol":"StdUtils"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/StdUtils.sol":{"keccak256":"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8","urls":["bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a","dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"}},"version":1},"id":12} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/Test.sol/Test.json b/lib/signals-implicit-mode/out/Test.sol/Test.json deleted file mode 100644 index b0ccebd820..0000000000 --- a/lib/signals-implicit-mode/out/Test.sol/Test.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"IS_TEST","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"excludeArtifacts","inputs":[],"outputs":[{"name":"excludedArtifacts_","type":"string[]","internalType":"string[]"}],"stateMutability":"view"},{"type":"function","name":"excludeContracts","inputs":[],"outputs":[{"name":"excludedContracts_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"excludeSelectors","inputs":[],"outputs":[{"name":"excludedSelectors_","type":"tuple[]","internalType":"struct StdInvariant.FuzzSelector[]","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"selectors","type":"bytes4[]","internalType":"bytes4[]"}]}],"stateMutability":"view"},{"type":"function","name":"excludeSenders","inputs":[],"outputs":[{"name":"excludedSenders_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"failed","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"targetArtifactSelectors","inputs":[],"outputs":[{"name":"targetedArtifactSelectors_","type":"tuple[]","internalType":"struct StdInvariant.FuzzArtifactSelector[]","components":[{"name":"artifact","type":"string","internalType":"string"},{"name":"selectors","type":"bytes4[]","internalType":"bytes4[]"}]}],"stateMutability":"view"},{"type":"function","name":"targetArtifacts","inputs":[],"outputs":[{"name":"targetedArtifacts_","type":"string[]","internalType":"string[]"}],"stateMutability":"view"},{"type":"function","name":"targetContracts","inputs":[],"outputs":[{"name":"targetedContracts_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"targetInterfaces","inputs":[],"outputs":[{"name":"targetedInterfaces_","type":"tuple[]","internalType":"struct StdInvariant.FuzzInterface[]","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"artifacts","type":"string[]","internalType":"string[]"}]}],"stateMutability":"view"},{"type":"function","name":"targetSelectors","inputs":[],"outputs":[{"name":"targetedSelectors_","type":"tuple[]","internalType":"struct StdInvariant.FuzzSelector[]","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"selectors","type":"bytes4[]","internalType":"bytes4[]"}]}],"stateMutability":"view"},{"type":"function","name":"targetSenders","inputs":[],"outputs":[{"name":"targetedSenders_","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"event","name":"log","inputs":[{"name":"","type":"string","indexed":false,"internalType":"string"}],"anonymous":false},{"type":"event","name":"log_address","inputs":[{"name":"","type":"address","indexed":false,"internalType":"address"}],"anonymous":false},{"type":"event","name":"log_array","inputs":[{"name":"val","type":"uint256[]","indexed":false,"internalType":"uint256[]"}],"anonymous":false},{"type":"event","name":"log_array","inputs":[{"name":"val","type":"int256[]","indexed":false,"internalType":"int256[]"}],"anonymous":false},{"type":"event","name":"log_array","inputs":[{"name":"val","type":"address[]","indexed":false,"internalType":"address[]"}],"anonymous":false},{"type":"event","name":"log_bytes","inputs":[{"name":"","type":"bytes","indexed":false,"internalType":"bytes"}],"anonymous":false},{"type":"event","name":"log_bytes32","inputs":[{"name":"","type":"bytes32","indexed":false,"internalType":"bytes32"}],"anonymous":false},{"type":"event","name":"log_int","inputs":[{"name":"","type":"int256","indexed":false,"internalType":"int256"}],"anonymous":false},{"type":"event","name":"log_named_address","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"address","indexed":false,"internalType":"address"}],"anonymous":false},{"type":"event","name":"log_named_array","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"uint256[]","indexed":false,"internalType":"uint256[]"}],"anonymous":false},{"type":"event","name":"log_named_array","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"int256[]","indexed":false,"internalType":"int256[]"}],"anonymous":false},{"type":"event","name":"log_named_array","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"address[]","indexed":false,"internalType":"address[]"}],"anonymous":false},{"type":"event","name":"log_named_bytes","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"bytes","indexed":false,"internalType":"bytes"}],"anonymous":false},{"type":"event","name":"log_named_bytes32","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"bytes32","indexed":false,"internalType":"bytes32"}],"anonymous":false},{"type":"event","name":"log_named_decimal_int","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"int256","indexed":false,"internalType":"int256"},{"name":"decimals","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"log_named_decimal_uint","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"uint256","indexed":false,"internalType":"uint256"},{"name":"decimals","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"log_named_int","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"int256","indexed":false,"internalType":"int256"}],"anonymous":false},{"type":"event","name":"log_named_string","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"string","indexed":false,"internalType":"string"}],"anonymous":false},{"type":"event","name":"log_named_uint","inputs":[{"name":"key","type":"string","indexed":false,"internalType":"string"},{"name":"val","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"log_string","inputs":[{"name":"","type":"string","indexed":false,"internalType":"string"}],"anonymous":false},{"type":"event","name":"log_uint","inputs":[{"name":"","type":"uint256","indexed":false,"internalType":"uint256"}],"anonymous":false},{"type":"event","name":"logs","inputs":[{"name":"","type":"bytes","indexed":false,"internalType":"bytes"}],"anonymous":false}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"IS_TEST()":"fa7626d4","excludeArtifacts()":"b5508aa9","excludeContracts()":"e20c9f71","excludeSelectors()":"b0464fdc","excludeSenders()":"1ed7831c","failed()":"ba414fa6","targetArtifactSelectors()":"66d9a9a0","targetArtifacts()":"85226c81","targetContracts()":"3f7286f4","targetInterfaces()":"2ade3880","targetSelectors()":"916a17c6","targetSenders()":"3e5e3c23"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"name\":\"log\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"log_address\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"val\",\"type\":\"uint256[]\"}],\"name\":\"log_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"int256[]\",\"name\":\"val\",\"type\":\"int256[]\"}],\"name\":\"log_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"val\",\"type\":\"address[]\"}],\"name\":\"log_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"log_bytes\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"log_bytes32\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"name\":\"log_int\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"val\",\"type\":\"address\"}],\"name\":\"log_named_address\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"val\",\"type\":\"uint256[]\"}],\"name\":\"log_named_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"int256[]\",\"name\":\"val\",\"type\":\"int256[]\"}],\"name\":\"log_named_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"val\",\"type\":\"address[]\"}],\"name\":\"log_named_array\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"val\",\"type\":\"bytes\"}],\"name\":\"log_named_bytes\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"val\",\"type\":\"bytes32\"}],\"name\":\"log_named_bytes32\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"val\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"log_named_decimal_int\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"val\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"log_named_decimal_uint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"val\",\"type\":\"int256\"}],\"name\":\"log_named_int\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"val\",\"type\":\"string\"}],\"name\":\"log_named_string\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"val\",\"type\":\"uint256\"}],\"name\":\"log_named_uint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"name\":\"log_string\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"log_uint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"logs\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"IS_TEST\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeArtifacts\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"excludedArtifacts_\",\"type\":\"string[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeContracts\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"excludedContracts_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeSelectors\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"bytes4[]\",\"name\":\"selectors\",\"type\":\"bytes4[]\"}],\"internalType\":\"struct StdInvariant.FuzzSelector[]\",\"name\":\"excludedSelectors_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"excludeSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"excludedSenders_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"failed\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetArtifactSelectors\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"artifact\",\"type\":\"string\"},{\"internalType\":\"bytes4[]\",\"name\":\"selectors\",\"type\":\"bytes4[]\"}],\"internalType\":\"struct StdInvariant.FuzzArtifactSelector[]\",\"name\":\"targetedArtifactSelectors_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetArtifacts\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"targetedArtifacts_\",\"type\":\"string[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetContracts\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"targetedContracts_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetInterfaces\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"string[]\",\"name\":\"artifacts\",\"type\":\"string[]\"}],\"internalType\":\"struct StdInvariant.FuzzInterface[]\",\"name\":\"targetedInterfaces_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetSelectors\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"bytes4[]\",\"name\":\"selectors\",\"type\":\"bytes4[]\"}],\"internalType\":\"struct StdInvariant.FuzzSelector[]\",\"name\":\"targetedSelectors_\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"targetSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"targetedSenders_\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/Test.sol\":\"Test\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/StdAssertions.sol\":{\"keccak256\":\"0xd8eec16034b53b52c90a3d720e121ce7d30d64cc57d854db7d817d5b382dda43\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://612780755e32668c7e3b747d94d16c7291101144e084dd9ee563f071711e99e3\",\"dweb:/ipfs/QmQgtFJXEmDtSHT7tZQTMbb6PCDpq5UDYFvrBnWk1Xo2SY\"]},\"lib/forge-std/src/StdChains.sol\":{\"keccak256\":\"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2\",\"dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe\"]},\"lib/forge-std/src/StdCheats.sol\":{\"keccak256\":\"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41\",\"dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK\"]},\"lib/forge-std/src/StdConstants.sol\":{\"keccak256\":\"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc\",\"dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r\"]},\"lib/forge-std/src/StdError.sol\":{\"keccak256\":\"0xbf477b11a42d7611696956546bcfaa29317d1166bf65e402344599c05943fc77\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://bc2e117d1135e030862b96a6526a43feb38d396cc79857f1fb696d4eff0e5fd6\",\"dweb:/ipfs/QmdSuQ5RrQudTLsNmWXGEeVJX8gR5U9XPm6m4dwwuQnJrj\"]},\"lib/forge-std/src/StdInvariant.sol\":{\"keccak256\":\"0x4dab3021edfa9511bbdd80c48f060ef62eaf457f99eaf841f561fc2557d9a08d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://07668628673174cf8f27f8f4e1f862bab775013ec247eb34f698c5005f229391\",\"dweb:/ipfs/QmPJsiiYwmCZXMsHmQv5tg8VF3CAhNdat7WnKLTWZZH2v5\"]},\"lib/forge-std/src/StdJson.sol\":{\"keccak256\":\"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974\",\"dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3\"]},\"lib/forge-std/src/StdMath.sol\":{\"keccak256\":\"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92\",\"dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/StdStyle.sol\":{\"keccak256\":\"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8\",\"dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK\"]},\"lib/forge-std/src/StdToml.sol\":{\"keccak256\":\"0x58a72c765ed3f7ff6b105509689658795b8a3739b8931772a497155878381861\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b4a3746f4fabaeb980bd77d9e091d3904ee38a6c0e191bfa8ba6874c6f8558a3\",\"dweb:/ipfs/QmUfFDMEn461FgGEXt5HicyGD54sc28sLaQ9JRWDMBKed8\"]},\"lib/forge-std/src/StdUtils.sol\":{\"keccak256\":\"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a\",\"dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT\"]},\"lib/forge-std/src/Test.sol\":{\"keccak256\":\"0x3dda6083a83dfa3e8526e97bcc28e862ee2442dd58fe94d5c426d65b8e38f73c\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://33f8c02e4dabdab86a6825125856446a8657eacd712318b51b7818e4a6f6e3f4\",\"dweb:/ipfs/QmRKSjVnrk54yr8wTK2e6QxRjiuba2H8HJSKunHAkdo7RG\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]},\"lib/forge-std/src/console2.sol\":{\"keccak256\":\"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d\",\"dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ\"]},\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]},\"lib/forge-std/src/safeconsole.sol\":{\"keccak256\":\"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab\",\"dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"string","name":"","type":"string","indexed":false}],"type":"event","name":"log","anonymous":false},{"inputs":[{"internalType":"address","name":"","type":"address","indexed":false}],"type":"event","name":"log_address","anonymous":false},{"inputs":[{"internalType":"uint256[]","name":"val","type":"uint256[]","indexed":false}],"type":"event","name":"log_array","anonymous":false},{"inputs":[{"internalType":"int256[]","name":"val","type":"int256[]","indexed":false}],"type":"event","name":"log_array","anonymous":false},{"inputs":[{"internalType":"address[]","name":"val","type":"address[]","indexed":false}],"type":"event","name":"log_array","anonymous":false},{"inputs":[{"internalType":"bytes","name":"","type":"bytes","indexed":false}],"type":"event","name":"log_bytes","anonymous":false},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32","indexed":false}],"type":"event","name":"log_bytes32","anonymous":false},{"inputs":[{"internalType":"int256","name":"","type":"int256","indexed":false}],"type":"event","name":"log_int","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"address","name":"val","type":"address","indexed":false}],"type":"event","name":"log_named_address","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"uint256[]","name":"val","type":"uint256[]","indexed":false}],"type":"event","name":"log_named_array","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"int256[]","name":"val","type":"int256[]","indexed":false}],"type":"event","name":"log_named_array","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"address[]","name":"val","type":"address[]","indexed":false}],"type":"event","name":"log_named_array","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"bytes","name":"val","type":"bytes","indexed":false}],"type":"event","name":"log_named_bytes","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"bytes32","name":"val","type":"bytes32","indexed":false}],"type":"event","name":"log_named_bytes32","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"int256","name":"val","type":"int256","indexed":false},{"internalType":"uint256","name":"decimals","type":"uint256","indexed":false}],"type":"event","name":"log_named_decimal_int","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"uint256","name":"val","type":"uint256","indexed":false},{"internalType":"uint256","name":"decimals","type":"uint256","indexed":false}],"type":"event","name":"log_named_decimal_uint","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"int256","name":"val","type":"int256","indexed":false}],"type":"event","name":"log_named_int","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"string","name":"val","type":"string","indexed":false}],"type":"event","name":"log_named_string","anonymous":false},{"inputs":[{"internalType":"string","name":"key","type":"string","indexed":false},{"internalType":"uint256","name":"val","type":"uint256","indexed":false}],"type":"event","name":"log_named_uint","anonymous":false},{"inputs":[{"internalType":"string","name":"","type":"string","indexed":false}],"type":"event","name":"log_string","anonymous":false},{"inputs":[{"internalType":"uint256","name":"","type":"uint256","indexed":false}],"type":"event","name":"log_uint","anonymous":false},{"inputs":[{"internalType":"bytes","name":"","type":"bytes","indexed":false}],"type":"event","name":"logs","anonymous":false},{"inputs":[],"stateMutability":"view","type":"function","name":"IS_TEST","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeArtifacts","outputs":[{"internalType":"string[]","name":"excludedArtifacts_","type":"string[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeContracts","outputs":[{"internalType":"address[]","name":"excludedContracts_","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeSelectors","outputs":[{"internalType":"struct StdInvariant.FuzzSelector[]","name":"excludedSelectors_","type":"tuple[]","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"bytes4[]","name":"selectors","type":"bytes4[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"excludeSenders","outputs":[{"internalType":"address[]","name":"excludedSenders_","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"failed","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetArtifactSelectors","outputs":[{"internalType":"struct StdInvariant.FuzzArtifactSelector[]","name":"targetedArtifactSelectors_","type":"tuple[]","components":[{"internalType":"string","name":"artifact","type":"string"},{"internalType":"bytes4[]","name":"selectors","type":"bytes4[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetArtifacts","outputs":[{"internalType":"string[]","name":"targetedArtifacts_","type":"string[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetContracts","outputs":[{"internalType":"address[]","name":"targetedContracts_","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetInterfaces","outputs":[{"internalType":"struct StdInvariant.FuzzInterface[]","name":"targetedInterfaces_","type":"tuple[]","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"string[]","name":"artifacts","type":"string[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetSelectors","outputs":[{"internalType":"struct StdInvariant.FuzzSelector[]","name":"targetedSelectors_","type":"tuple[]","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"bytes4[]","name":"selectors","type":"bytes4[]"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"targetSenders","outputs":[{"internalType":"address[]","name":"targetedSenders_","type":"address[]"}]}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/Test.sol":"Test"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/StdAssertions.sol":{"keccak256":"0xd8eec16034b53b52c90a3d720e121ce7d30d64cc57d854db7d817d5b382dda43","urls":["bzz-raw://612780755e32668c7e3b747d94d16c7291101144e084dd9ee563f071711e99e3","dweb:/ipfs/QmQgtFJXEmDtSHT7tZQTMbb6PCDpq5UDYFvrBnWk1Xo2SY"],"license":"MIT"},"lib/forge-std/src/StdChains.sol":{"keccak256":"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa","urls":["bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2","dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe"],"license":"MIT"},"lib/forge-std/src/StdCheats.sol":{"keccak256":"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746","urls":["bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41","dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK"],"license":"MIT"},"lib/forge-std/src/StdConstants.sol":{"keccak256":"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534","urls":["bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc","dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r"],"license":"MIT"},"lib/forge-std/src/StdError.sol":{"keccak256":"0xbf477b11a42d7611696956546bcfaa29317d1166bf65e402344599c05943fc77","urls":["bzz-raw://bc2e117d1135e030862b96a6526a43feb38d396cc79857f1fb696d4eff0e5fd6","dweb:/ipfs/QmdSuQ5RrQudTLsNmWXGEeVJX8gR5U9XPm6m4dwwuQnJrj"],"license":"MIT"},"lib/forge-std/src/StdInvariant.sol":{"keccak256":"0x4dab3021edfa9511bbdd80c48f060ef62eaf457f99eaf841f561fc2557d9a08d","urls":["bzz-raw://07668628673174cf8f27f8f4e1f862bab775013ec247eb34f698c5005f229391","dweb:/ipfs/QmPJsiiYwmCZXMsHmQv5tg8VF3CAhNdat7WnKLTWZZH2v5"],"license":"MIT"},"lib/forge-std/src/StdJson.sol":{"keccak256":"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500","urls":["bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974","dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3"],"license":"MIT"},"lib/forge-std/src/StdMath.sol":{"keccak256":"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2","urls":["bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92","dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/StdStyle.sol":{"keccak256":"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d","urls":["bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8","dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK"],"license":"MIT"},"lib/forge-std/src/StdToml.sol":{"keccak256":"0x58a72c765ed3f7ff6b105509689658795b8a3739b8931772a497155878381861","urls":["bzz-raw://b4a3746f4fabaeb980bd77d9e091d3904ee38a6c0e191bfa8ba6874c6f8558a3","dweb:/ipfs/QmUfFDMEn461FgGEXt5HicyGD54sc28sLaQ9JRWDMBKed8"],"license":"MIT"},"lib/forge-std/src/StdUtils.sol":{"keccak256":"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8","urls":["bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a","dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT"],"license":"MIT"},"lib/forge-std/src/Test.sol":{"keccak256":"0x3dda6083a83dfa3e8526e97bcc28e862ee2442dd58fe94d5c426d65b8e38f73c","urls":["bzz-raw://33f8c02e4dabdab86a6825125856446a8657eacd712318b51b7818e4a6f6e3f4","dweb:/ipfs/QmRKSjVnrk54yr8wTK2e6QxRjiuba2H8HJSKunHAkdo7RG"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"},"lib/forge-std/src/console2.sol":{"keccak256":"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f","urls":["bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d","dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ"],"license":"MIT"},"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"},"lib/forge-std/src/safeconsole.sol":{"keccak256":"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11","urls":["bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab","dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3"],"license":"MIT"}},"version":1},"id":13} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/TestHelper.sol/TestHelper.json b/lib/signals-implicit-mode/out/TestHelper.sol/TestHelper.json deleted file mode 100644 index 032ec8e974..0000000000 --- a/lib/signals-implicit-mode/out/TestHelper.sol/TestHelper.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x6080604052348015600f57600080fd5b50603f80601d6000396000f3fe6080604052600080fdfea26469706673582212200da4b250cf0c894af8ab01da03278137ac7c847e2469c0eea76bc9167cdcf76964736f6c634300081c0033","sourceMap":"65:1646:31:-:0;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x6080604052600080fdfea26469706673582212200da4b250cf0c894af8ab01da03278137ac7c847e2469c0eea76bc9167cdcf76964736f6c634300081c0033","sourceMap":"65:1646:31:-:0;;;;;","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"test/TestHelper.sol\":\"TestHelper\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"test/TestHelper.sol\":{\"keccak256\":\"0xba551fda365d1deef08d0e627d0233810141ea6dbfe770be3ebdb839a6af16a9\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://fb9173a19cc248878fba10321bc83c5226d12eebacded8aad5c114dc39d52f15\",\"dweb:/ipfs/QmTEH8EuNa8FcTEF4PiDPcmLYspxGEw3jbzEwVYFdxZWeD\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"test/TestHelper.sol":"TestHelper"},"evmVersion":"paris","libraries":{}},"sources":{"test/TestHelper.sol":{"keccak256":"0xba551fda365d1deef08d0e627d0233810141ea6dbfe770be3ebdb839a6af16a9","urls":["bzz-raw://fb9173a19cc248878fba10321bc83c5226d12eebacded8aad5c114dc39d52f15","dweb:/ipfs/QmTEH8EuNa8FcTEF4PiDPcmLYspxGEw3jbzEwVYFdxZWeD"],"license":"Apache-2.0"}},"version":1},"id":31} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/Vm.sol/Vm.json b/lib/signals-implicit-mode/out/Vm.sol/Vm.json deleted file mode 100644 index 48a5db1fa5..0000000000 --- a/lib/signals-implicit-mode/out/Vm.sol/Vm.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"accessList","inputs":[{"name":"access","type":"tuple[]","internalType":"struct VmSafe.AccessListItem[]","components":[{"name":"target","type":"address","internalType":"address"},{"name":"storageKeys","type":"bytes32[]","internalType":"bytes32[]"}]}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"accesses","inputs":[{"name":"target","type":"address","internalType":"address"}],"outputs":[{"name":"readSlots","type":"bytes32[]","internalType":"bytes32[]"},{"name":"writeSlots","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"view"},{"type":"function","name":"activeFork","inputs":[],"outputs":[{"name":"forkId","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"addr","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"keyAddr","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"allowCheatcodes","inputs":[{"name":"account","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"assertApproxEqAbs","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbs","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbs","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbs","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbsDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbsDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbsDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbsDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRel","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRel","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRel","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRel","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRelDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRelDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRelDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRelDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes32[]","internalType":"bytes32[]"},{"name":"right","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"int256[]","internalType":"int256[]"},{"name":"right","type":"int256[]","internalType":"int256[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"address","internalType":"address"},{"name":"right","type":"address","internalType":"address"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"string","internalType":"string"},{"name":"right","type":"string","internalType":"string"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"address[]","internalType":"address[]"},{"name":"right","type":"address[]","internalType":"address[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"address[]","internalType":"address[]"},{"name":"right","type":"address[]","internalType":"address[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bool","internalType":"bool"},{"name":"right","type":"bool","internalType":"bool"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"address","internalType":"address"},{"name":"right","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"uint256[]","internalType":"uint256[]"},{"name":"right","type":"uint256[]","internalType":"uint256[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bool[]","internalType":"bool[]"},{"name":"right","type":"bool[]","internalType":"bool[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"int256[]","internalType":"int256[]"},{"name":"right","type":"int256[]","internalType":"int256[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes32","internalType":"bytes32"},{"name":"right","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"uint256[]","internalType":"uint256[]"},{"name":"right","type":"uint256[]","internalType":"uint256[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes","internalType":"bytes"},{"name":"right","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes32","internalType":"bytes32"},{"name":"right","type":"bytes32","internalType":"bytes32"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"string[]","internalType":"string[]"},{"name":"right","type":"string[]","internalType":"string[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes32[]","internalType":"bytes32[]"},{"name":"right","type":"bytes32[]","internalType":"bytes32[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes","internalType":"bytes"},{"name":"right","type":"bytes","internalType":"bytes"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bool[]","internalType":"bool[]"},{"name":"right","type":"bool[]","internalType":"bool[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes[]","internalType":"bytes[]"},{"name":"right","type":"bytes[]","internalType":"bytes[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"string[]","internalType":"string[]"},{"name":"right","type":"string[]","internalType":"string[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"string","internalType":"string"},{"name":"right","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes[]","internalType":"bytes[]"},{"name":"right","type":"bytes[]","internalType":"bytes[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bool","internalType":"bool"},{"name":"right","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEqDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEqDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEqDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEqDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertFalse","inputs":[{"name":"condition","type":"bool","internalType":"bool"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertFalse","inputs":[{"name":"condition","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGe","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGe","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGe","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGe","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGeDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGeDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGeDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGeDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGt","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGt","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGt","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGt","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGtDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGtDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGtDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGtDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLe","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLe","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLe","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLe","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLeDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLeDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLeDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLeDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLt","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLt","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLt","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLt","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLtDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLtDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLtDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLtDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes32[]","internalType":"bytes32[]"},{"name":"right","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"int256[]","internalType":"int256[]"},{"name":"right","type":"int256[]","internalType":"int256[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bool","internalType":"bool"},{"name":"right","type":"bool","internalType":"bool"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes[]","internalType":"bytes[]"},{"name":"right","type":"bytes[]","internalType":"bytes[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bool","internalType":"bool"},{"name":"right","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bool[]","internalType":"bool[]"},{"name":"right","type":"bool[]","internalType":"bool[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes","internalType":"bytes"},{"name":"right","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"address[]","internalType":"address[]"},{"name":"right","type":"address[]","internalType":"address[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"uint256[]","internalType":"uint256[]"},{"name":"right","type":"uint256[]","internalType":"uint256[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bool[]","internalType":"bool[]"},{"name":"right","type":"bool[]","internalType":"bool[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"string","internalType":"string"},{"name":"right","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"address[]","internalType":"address[]"},{"name":"right","type":"address[]","internalType":"address[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"string","internalType":"string"},{"name":"right","type":"string","internalType":"string"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"address","internalType":"address"},{"name":"right","type":"address","internalType":"address"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes32","internalType":"bytes32"},{"name":"right","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes","internalType":"bytes"},{"name":"right","type":"bytes","internalType":"bytes"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"uint256[]","internalType":"uint256[]"},{"name":"right","type":"uint256[]","internalType":"uint256[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"address","internalType":"address"},{"name":"right","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes32","internalType":"bytes32"},{"name":"right","type":"bytes32","internalType":"bytes32"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"string[]","internalType":"string[]"},{"name":"right","type":"string[]","internalType":"string[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes32[]","internalType":"bytes32[]"},{"name":"right","type":"bytes32[]","internalType":"bytes32[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"string[]","internalType":"string[]"},{"name":"right","type":"string[]","internalType":"string[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"int256[]","internalType":"int256[]"},{"name":"right","type":"int256[]","internalType":"int256[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes[]","internalType":"bytes[]"},{"name":"right","type":"bytes[]","internalType":"bytes[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEqDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEqDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEqDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEqDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertTrue","inputs":[{"name":"condition","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertTrue","inputs":[{"name":"condition","type":"bool","internalType":"bool"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assume","inputs":[{"name":"condition","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assumeNoRevert","inputs":[],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assumeNoRevert","inputs":[{"name":"potentialReverts","type":"tuple[]","internalType":"struct VmSafe.PotentialRevert[]","components":[{"name":"reverter","type":"address","internalType":"address"},{"name":"partialMatch","type":"bool","internalType":"bool"},{"name":"revertData","type":"bytes","internalType":"bytes"}]}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assumeNoRevert","inputs":[{"name":"potentialRevert","type":"tuple","internalType":"struct VmSafe.PotentialRevert","components":[{"name":"reverter","type":"address","internalType":"address"},{"name":"partialMatch","type":"bool","internalType":"bool"},{"name":"revertData","type":"bytes","internalType":"bytes"}]}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"attachBlob","inputs":[{"name":"blob","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"attachDelegation","inputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"attachDelegation","inputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]},{"name":"crossChain","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"blobBaseFee","inputs":[{"name":"newBlobBaseFee","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"blobhashes","inputs":[{"name":"hashes","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"bound","inputs":[{"name":"current","type":"uint256","internalType":"uint256"},{"name":"min","type":"uint256","internalType":"uint256"},{"name":"max","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"bound","inputs":[{"name":"current","type":"int256","internalType":"int256"},{"name":"min","type":"int256","internalType":"int256"},{"name":"max","type":"int256","internalType":"int256"}],"outputs":[{"name":"","type":"int256","internalType":"int256"}],"stateMutability":"view"},{"type":"function","name":"breakpoint","inputs":[{"name":"char","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"breakpoint","inputs":[{"name":"char","type":"string","internalType":"string"},{"name":"value","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"broadcast","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"broadcast","inputs":[{"name":"signer","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"broadcast","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"broadcastRawTransaction","inputs":[{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"chainId","inputs":[{"name":"newChainId","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"clearMockedCalls","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"cloneAccount","inputs":[{"name":"source","type":"address","internalType":"address"},{"name":"target","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"closeFile","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"coinbase","inputs":[{"name":"newCoinbase","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"computeCreate2Address","inputs":[{"name":"salt","type":"bytes32","internalType":"bytes32"},{"name":"initCodeHash","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"computeCreate2Address","inputs":[{"name":"salt","type":"bytes32","internalType":"bytes32"},{"name":"initCodeHash","type":"bytes32","internalType":"bytes32"},{"name":"deployer","type":"address","internalType":"address"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"computeCreateAddress","inputs":[{"name":"deployer","type":"address","internalType":"address"},{"name":"nonce","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"contains","inputs":[{"name":"subject","type":"string","internalType":"string"},{"name":"search","type":"string","internalType":"string"}],"outputs":[{"name":"result","type":"bool","internalType":"bool"}],"stateMutability":"pure"},{"type":"function","name":"cool","inputs":[{"name":"target","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"coolSlot","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"slot","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"copyFile","inputs":[{"name":"from","type":"string","internalType":"string"},{"name":"to","type":"string","internalType":"string"}],"outputs":[{"name":"copied","type":"uint64","internalType":"uint64"}],"stateMutability":"nonpayable"},{"type":"function","name":"copyStorage","inputs":[{"name":"from","type":"address","internalType":"address"},{"name":"to","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"createDir","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"recursive","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"createFork","inputs":[{"name":"urlOrAlias","type":"string","internalType":"string"}],"outputs":[{"name":"forkId","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"createFork","inputs":[{"name":"urlOrAlias","type":"string","internalType":"string"},{"name":"blockNumber","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"forkId","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"createFork","inputs":[{"name":"urlOrAlias","type":"string","internalType":"string"},{"name":"txHash","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"forkId","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"createSelectFork","inputs":[{"name":"urlOrAlias","type":"string","internalType":"string"},{"name":"blockNumber","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"forkId","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"createSelectFork","inputs":[{"name":"urlOrAlias","type":"string","internalType":"string"},{"name":"txHash","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"forkId","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"createSelectFork","inputs":[{"name":"urlOrAlias","type":"string","internalType":"string"}],"outputs":[{"name":"forkId","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"createWallet","inputs":[{"name":"walletLabel","type":"string","internalType":"string"}],"outputs":[{"name":"wallet","type":"tuple","internalType":"struct VmSafe.Wallet","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"},{"name":"privateKey","type":"uint256","internalType":"uint256"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"createWallet","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"wallet","type":"tuple","internalType":"struct VmSafe.Wallet","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"},{"name":"privateKey","type":"uint256","internalType":"uint256"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"createWallet","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"walletLabel","type":"string","internalType":"string"}],"outputs":[{"name":"wallet","type":"tuple","internalType":"struct VmSafe.Wallet","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"},{"name":"privateKey","type":"uint256","internalType":"uint256"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"deal","inputs":[{"name":"account","type":"address","internalType":"address"},{"name":"newBalance","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"deleteSnapshot","inputs":[{"name":"snapshotId","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"success","type":"bool","internalType":"bool"}],"stateMutability":"nonpayable"},{"type":"function","name":"deleteSnapshots","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"deleteStateSnapshot","inputs":[{"name":"snapshotId","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"success","type":"bool","internalType":"bool"}],"stateMutability":"nonpayable"},{"type":"function","name":"deleteStateSnapshots","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"constructorArgs","type":"bytes","internalType":"bytes"},{"name":"salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"constructorArgs","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"constructorArgs","type":"bytes","internalType":"bytes"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"constructorArgs","type":"bytes","internalType":"bytes"},{"name":"value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deriveKey","inputs":[{"name":"mnemonic","type":"string","internalType":"string"},{"name":"derivationPath","type":"string","internalType":"string"},{"name":"index","type":"uint32","internalType":"uint32"},{"name":"language","type":"string","internalType":"string"}],"outputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"deriveKey","inputs":[{"name":"mnemonic","type":"string","internalType":"string"},{"name":"index","type":"uint32","internalType":"uint32"},{"name":"language","type":"string","internalType":"string"}],"outputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"deriveKey","inputs":[{"name":"mnemonic","type":"string","internalType":"string"},{"name":"index","type":"uint32","internalType":"uint32"}],"outputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"deriveKey","inputs":[{"name":"mnemonic","type":"string","internalType":"string"},{"name":"derivationPath","type":"string","internalType":"string"},{"name":"index","type":"uint32","internalType":"uint32"}],"outputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"difficulty","inputs":[{"name":"newDifficulty","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"dumpState","inputs":[{"name":"pathToStateJson","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"eip712HashStruct","inputs":[{"name":"bindingsPath","type":"string","internalType":"string"},{"name":"typeName","type":"string","internalType":"string"},{"name":"abiEncodedData","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"typeHash","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"eip712HashStruct","inputs":[{"name":"typeNameOrDefinition","type":"string","internalType":"string"},{"name":"abiEncodedData","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"typeHash","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"eip712HashType","inputs":[{"name":"bindingsPath","type":"string","internalType":"string"},{"name":"typeName","type":"string","internalType":"string"}],"outputs":[{"name":"typeHash","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"eip712HashType","inputs":[{"name":"typeNameOrDefinition","type":"string","internalType":"string"}],"outputs":[{"name":"typeHash","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"eip712HashTypedData","inputs":[{"name":"jsonData","type":"string","internalType":"string"}],"outputs":[{"name":"digest","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"ensNamehash","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"envAddress","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"envAddress","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"envBool","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"envBool","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"bool[]","internalType":"bool[]"}],"stateMutability":"view"},{"type":"function","name":"envBytes","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"envBytes","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"bytes[]","internalType":"bytes[]"}],"stateMutability":"view"},{"type":"function","name":"envBytes32","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"view"},{"type":"function","name":"envBytes32","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"envExists","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"result","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"envInt","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"int256[]","internalType":"int256[]"}],"stateMutability":"view"},{"type":"function","name":"envInt","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"int256","internalType":"int256"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[{"name":"value","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"int256[]","internalType":"int256[]"}],"outputs":[{"name":"value","type":"int256[]","internalType":"int256[]"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"bool","internalType":"bool"}],"outputs":[{"name":"value","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"address","internalType":"address"}],"outputs":[{"name":"value","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"value","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"bytes[]","internalType":"bytes[]"}],"outputs":[{"name":"value","type":"bytes[]","internalType":"bytes[]"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"uint256[]","internalType":"uint256[]"}],"outputs":[{"name":"value","type":"uint256[]","internalType":"uint256[]"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"string[]","internalType":"string[]"}],"outputs":[{"name":"value","type":"string[]","internalType":"string[]"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"value","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"value","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"int256","internalType":"int256"}],"outputs":[{"name":"value","type":"int256","internalType":"int256"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"address[]","internalType":"address[]"}],"outputs":[{"name":"value","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"bool[]","internalType":"bool[]"}],"outputs":[{"name":"value","type":"bool[]","internalType":"bool[]"}],"stateMutability":"view"},{"type":"function","name":"envString","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"string[]","internalType":"string[]"}],"stateMutability":"view"},{"type":"function","name":"envString","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"envUint","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"envUint","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"uint256[]","internalType":"uint256[]"}],"stateMutability":"view"},{"type":"function","name":"etch","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"newRuntimeBytecode","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"eth_getLogs","inputs":[{"name":"fromBlock","type":"uint256","internalType":"uint256"},{"name":"toBlock","type":"uint256","internalType":"uint256"},{"name":"target","type":"address","internalType":"address"},{"name":"topics","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[{"name":"logs","type":"tuple[]","internalType":"struct VmSafe.EthGetLogs[]","components":[{"name":"emitter","type":"address","internalType":"address"},{"name":"topics","type":"bytes32[]","internalType":"bytes32[]"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"blockHash","type":"bytes32","internalType":"bytes32"},{"name":"blockNumber","type":"uint64","internalType":"uint64"},{"name":"transactionHash","type":"bytes32","internalType":"bytes32"},{"name":"transactionIndex","type":"uint64","internalType":"uint64"},{"name":"logIndex","type":"uint256","internalType":"uint256"},{"name":"removed","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"exists","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"result","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"expectCall","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"msgValue","type":"uint256","internalType":"uint256"},{"name":"gas","type":"uint64","internalType":"uint64"},{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectCall","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"msgValue","type":"uint256","internalType":"uint256"},{"name":"gas","type":"uint64","internalType":"uint64"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectCall","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"msgValue","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectCall","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectCall","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectCall","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"msgValue","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectCallMinGas","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"msgValue","type":"uint256","internalType":"uint256"},{"name":"minGas","type":"uint64","internalType":"uint64"},{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectCallMinGas","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"msgValue","type":"uint256","internalType":"uint256"},{"name":"minGas","type":"uint64","internalType":"uint64"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectCreate","inputs":[{"name":"bytecode","type":"bytes","internalType":"bytes"},{"name":"deployer","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectCreate2","inputs":[{"name":"bytecode","type":"bytes","internalType":"bytes"},{"name":"deployer","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectEmit","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectEmit","inputs":[{"name":"checkTopic1","type":"bool","internalType":"bool"},{"name":"checkTopic2","type":"bool","internalType":"bool"},{"name":"checkTopic3","type":"bool","internalType":"bool"},{"name":"checkData","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectEmit","inputs":[{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectEmit","inputs":[{"name":"checkTopic1","type":"bool","internalType":"bool"},{"name":"checkTopic2","type":"bool","internalType":"bool"},{"name":"checkTopic3","type":"bool","internalType":"bool"},{"name":"checkData","type":"bool","internalType":"bool"},{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectEmit","inputs":[{"name":"checkTopic1","type":"bool","internalType":"bool"},{"name":"checkTopic2","type":"bool","internalType":"bool"},{"name":"checkTopic3","type":"bool","internalType":"bool"},{"name":"checkData","type":"bool","internalType":"bool"},{"name":"emitter","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectEmit","inputs":[{"name":"emitter","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectEmit","inputs":[{"name":"emitter","type":"address","internalType":"address"},{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectEmit","inputs":[{"name":"checkTopic1","type":"bool","internalType":"bool"},{"name":"checkTopic2","type":"bool","internalType":"bool"},{"name":"checkTopic3","type":"bool","internalType":"bool"},{"name":"checkData","type":"bool","internalType":"bool"},{"name":"emitter","type":"address","internalType":"address"},{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectEmitAnonymous","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectEmitAnonymous","inputs":[{"name":"emitter","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectEmitAnonymous","inputs":[{"name":"checkTopic0","type":"bool","internalType":"bool"},{"name":"checkTopic1","type":"bool","internalType":"bool"},{"name":"checkTopic2","type":"bool","internalType":"bool"},{"name":"checkTopic3","type":"bool","internalType":"bool"},{"name":"checkData","type":"bool","internalType":"bool"},{"name":"emitter","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectEmitAnonymous","inputs":[{"name":"checkTopic0","type":"bool","internalType":"bool"},{"name":"checkTopic1","type":"bool","internalType":"bool"},{"name":"checkTopic2","type":"bool","internalType":"bool"},{"name":"checkTopic3","type":"bool","internalType":"bool"},{"name":"checkData","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectPartialRevert","inputs":[{"name":"revertData","type":"bytes4","internalType":"bytes4"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectPartialRevert","inputs":[{"name":"revertData","type":"bytes4","internalType":"bytes4"},{"name":"reverter","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectRevert","inputs":[{"name":"reverter","type":"address","internalType":"address"},{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectRevert","inputs":[{"name":"revertData","type":"bytes4","internalType":"bytes4"},{"name":"reverter","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectRevert","inputs":[{"name":"revertData","type":"bytes","internalType":"bytes"},{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectRevert","inputs":[{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectRevert","inputs":[{"name":"revertData","type":"bytes","internalType":"bytes"},{"name":"reverter","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectRevert","inputs":[{"name":"revertData","type":"bytes4","internalType":"bytes4"},{"name":"reverter","type":"address","internalType":"address"},{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectRevert","inputs":[{"name":"revertData","type":"bytes4","internalType":"bytes4"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectRevert","inputs":[{"name":"revertData","type":"bytes","internalType":"bytes"},{"name":"reverter","type":"address","internalType":"address"},{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectRevert","inputs":[{"name":"reverter","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectRevert","inputs":[{"name":"revertData","type":"bytes4","internalType":"bytes4"},{"name":"count","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectRevert","inputs":[{"name":"revertData","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectRevert","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectSafeMemory","inputs":[{"name":"min","type":"uint64","internalType":"uint64"},{"name":"max","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"expectSafeMemoryCall","inputs":[{"name":"min","type":"uint64","internalType":"uint64"},{"name":"max","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"fee","inputs":[{"name":"newBasefee","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"ffi","inputs":[{"name":"commandInput","type":"string[]","internalType":"string[]"}],"outputs":[{"name":"result","type":"bytes","internalType":"bytes"}],"stateMutability":"nonpayable"},{"type":"function","name":"foundryVersionAtLeast","inputs":[{"name":"version","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"foundryVersionCmp","inputs":[{"name":"version","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"int256","internalType":"int256"}],"stateMutability":"view"},{"type":"function","name":"fsMetadata","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"metadata","type":"tuple","internalType":"struct VmSafe.FsMetadata","components":[{"name":"isDir","type":"bool","internalType":"bool"},{"name":"isSymlink","type":"bool","internalType":"bool"},{"name":"length","type":"uint256","internalType":"uint256"},{"name":"readOnly","type":"bool","internalType":"bool"},{"name":"modified","type":"uint256","internalType":"uint256"},{"name":"accessed","type":"uint256","internalType":"uint256"},{"name":"created","type":"uint256","internalType":"uint256"}]}],"stateMutability":"view"},{"type":"function","name":"getArtifactPathByCode","inputs":[{"name":"code","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"path","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"getArtifactPathByDeployedCode","inputs":[{"name":"deployedCode","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"path","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"getBlobBaseFee","inputs":[],"outputs":[{"name":"blobBaseFee","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getBlobhashes","inputs":[],"outputs":[{"name":"hashes","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"view"},{"type":"function","name":"getBlockNumber","inputs":[],"outputs":[{"name":"height","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getBlockTimestamp","inputs":[],"outputs":[{"name":"timestamp","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getBroadcast","inputs":[{"name":"contractName","type":"string","internalType":"string"},{"name":"chainId","type":"uint64","internalType":"uint64"},{"name":"txType","type":"uint8","internalType":"enum VmSafe.BroadcastTxType"}],"outputs":[{"name":"","type":"tuple","internalType":"struct VmSafe.BroadcastTxSummary","components":[{"name":"txHash","type":"bytes32","internalType":"bytes32"},{"name":"txType","type":"uint8","internalType":"enum VmSafe.BroadcastTxType"},{"name":"contractAddress","type":"address","internalType":"address"},{"name":"blockNumber","type":"uint64","internalType":"uint64"},{"name":"success","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"getBroadcasts","inputs":[{"name":"contractName","type":"string","internalType":"string"},{"name":"chainId","type":"uint64","internalType":"uint64"}],"outputs":[{"name":"","type":"tuple[]","internalType":"struct VmSafe.BroadcastTxSummary[]","components":[{"name":"txHash","type":"bytes32","internalType":"bytes32"},{"name":"txType","type":"uint8","internalType":"enum VmSafe.BroadcastTxType"},{"name":"contractAddress","type":"address","internalType":"address"},{"name":"blockNumber","type":"uint64","internalType":"uint64"},{"name":"success","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"getBroadcasts","inputs":[{"name":"contractName","type":"string","internalType":"string"},{"name":"chainId","type":"uint64","internalType":"uint64"},{"name":"txType","type":"uint8","internalType":"enum VmSafe.BroadcastTxType"}],"outputs":[{"name":"","type":"tuple[]","internalType":"struct VmSafe.BroadcastTxSummary[]","components":[{"name":"txHash","type":"bytes32","internalType":"bytes32"},{"name":"txType","type":"uint8","internalType":"enum VmSafe.BroadcastTxType"},{"name":"contractAddress","type":"address","internalType":"address"},{"name":"blockNumber","type":"uint64","internalType":"uint64"},{"name":"success","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"getChain","inputs":[{"name":"chainAlias","type":"string","internalType":"string"}],"outputs":[{"name":"chain","type":"tuple","internalType":"struct VmSafe.Chain","components":[{"name":"name","type":"string","internalType":"string"},{"name":"chainId","type":"uint256","internalType":"uint256"},{"name":"chainAlias","type":"string","internalType":"string"},{"name":"rpcUrl","type":"string","internalType":"string"}]}],"stateMutability":"view"},{"type":"function","name":"getChain","inputs":[{"name":"chainId","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"chain","type":"tuple","internalType":"struct VmSafe.Chain","components":[{"name":"name","type":"string","internalType":"string"},{"name":"chainId","type":"uint256","internalType":"uint256"},{"name":"chainAlias","type":"string","internalType":"string"},{"name":"rpcUrl","type":"string","internalType":"string"}]}],"stateMutability":"view"},{"type":"function","name":"getChainId","inputs":[],"outputs":[{"name":"blockChainId","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"}],"outputs":[{"name":"creationBytecode","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"getDeployedCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"}],"outputs":[{"name":"runtimeBytecode","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"getDeployment","inputs":[{"name":"contractName","type":"string","internalType":"string"},{"name":"chainId","type":"uint64","internalType":"uint64"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"getDeployment","inputs":[{"name":"contractName","type":"string","internalType":"string"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"getDeployments","inputs":[{"name":"contractName","type":"string","internalType":"string"},{"name":"chainId","type":"uint64","internalType":"uint64"}],"outputs":[{"name":"deployedAddresses","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"getFoundryVersion","inputs":[],"outputs":[{"name":"version","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"getLabel","inputs":[{"name":"account","type":"address","internalType":"address"}],"outputs":[{"name":"currentLabel","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"getMappingKeyAndParentOf","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"elementSlot","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"found","type":"bool","internalType":"bool"},{"name":"key","type":"bytes32","internalType":"bytes32"},{"name":"parent","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"getMappingLength","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"mappingSlot","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"length","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getMappingSlotAt","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"mappingSlot","type":"bytes32","internalType":"bytes32"},{"name":"idx","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"value","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"getNonce","inputs":[{"name":"account","type":"address","internalType":"address"}],"outputs":[{"name":"nonce","type":"uint64","internalType":"uint64"}],"stateMutability":"view"},{"type":"function","name":"getNonce","inputs":[{"name":"wallet","type":"tuple","internalType":"struct VmSafe.Wallet","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"},{"name":"privateKey","type":"uint256","internalType":"uint256"}]}],"outputs":[{"name":"nonce","type":"uint64","internalType":"uint64"}],"stateMutability":"view"},{"type":"function","name":"getRawBlockHeader","inputs":[{"name":"blockNumber","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"rlpHeader","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"getRecordedLogs","inputs":[],"outputs":[{"name":"logs","type":"tuple[]","internalType":"struct VmSafe.Log[]","components":[{"name":"topics","type":"bytes32[]","internalType":"bytes32[]"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"emitter","type":"address","internalType":"address"}]}],"stateMutability":"view"},{"type":"function","name":"getStateDiff","inputs":[],"outputs":[{"name":"diff","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"getStateDiffJson","inputs":[],"outputs":[{"name":"diff","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"getStorageAccesses","inputs":[],"outputs":[{"name":"storageAccesses","type":"tuple[]","internalType":"struct VmSafe.StorageAccess[]","components":[{"name":"account","type":"address","internalType":"address"},{"name":"slot","type":"bytes32","internalType":"bytes32"},{"name":"isWrite","type":"bool","internalType":"bool"},{"name":"previousValue","type":"bytes32","internalType":"bytes32"},{"name":"newValue","type":"bytes32","internalType":"bytes32"},{"name":"reverted","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"getWallets","inputs":[],"outputs":[{"name":"wallets","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"indexOf","inputs":[{"name":"input","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"interceptInitcode","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"isContext","inputs":[{"name":"context","type":"uint8","internalType":"enum VmSafe.ForgeContext"}],"outputs":[{"name":"result","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"isDir","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"result","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"isFile","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"result","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"isPersistent","inputs":[{"name":"account","type":"address","internalType":"address"}],"outputs":[{"name":"persistent","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"keyExists","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"keyExistsJson","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"keyExistsToml","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"label","inputs":[{"name":"account","type":"address","internalType":"address"},{"name":"newLabel","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"lastCallGas","inputs":[],"outputs":[{"name":"gas","type":"tuple","internalType":"struct VmSafe.Gas","components":[{"name":"gasLimit","type":"uint64","internalType":"uint64"},{"name":"gasTotalUsed","type":"uint64","internalType":"uint64"},{"name":"gasMemoryUsed","type":"uint64","internalType":"uint64"},{"name":"gasRefunded","type":"int64","internalType":"int64"},{"name":"gasRemaining","type":"uint64","internalType":"uint64"}]}],"stateMutability":"view"},{"type":"function","name":"load","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"slot","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"data","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"loadAllocs","inputs":[{"name":"pathToAllocsJson","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"makePersistent","inputs":[{"name":"accounts","type":"address[]","internalType":"address[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"makePersistent","inputs":[{"name":"account0","type":"address","internalType":"address"},{"name":"account1","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"makePersistent","inputs":[{"name":"account","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"makePersistent","inputs":[{"name":"account0","type":"address","internalType":"address"},{"name":"account1","type":"address","internalType":"address"},{"name":"account2","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"mockCall","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"data","type":"bytes4","internalType":"bytes4"},{"name":"returnData","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"mockCall","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"msgValue","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"returnData","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"mockCall","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"returnData","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"mockCall","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"msgValue","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes4","internalType":"bytes4"},{"name":"returnData","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"mockCallRevert","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"data","type":"bytes4","internalType":"bytes4"},{"name":"revertData","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"mockCallRevert","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"msgValue","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes4","internalType":"bytes4"},{"name":"revertData","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"mockCallRevert","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"msgValue","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"revertData","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"mockCallRevert","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"revertData","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"mockCalls","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"msgValue","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"returnData","type":"bytes[]","internalType":"bytes[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"mockCalls","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"returnData","type":"bytes[]","internalType":"bytes[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"mockFunction","inputs":[{"name":"callee","type":"address","internalType":"address"},{"name":"target","type":"address","internalType":"address"},{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"noAccessList","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"parseAddress","inputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"outputs":[{"name":"parsedValue","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"parseBool","inputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"outputs":[{"name":"parsedValue","type":"bool","internalType":"bool"}],"stateMutability":"pure"},{"type":"function","name":"parseBytes","inputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"outputs":[{"name":"parsedValue","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseBytes32","inputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"outputs":[{"name":"parsedValue","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"parseInt","inputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"outputs":[{"name":"parsedValue","type":"int256","internalType":"int256"}],"stateMutability":"pure"},{"type":"function","name":"parseJson","inputs":[{"name":"json","type":"string","internalType":"string"}],"outputs":[{"name":"abiEncodedData","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseJson","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"abiEncodedData","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonAddress","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonAddressArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address[]","internalType":"address[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonBool","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonBoolArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool[]","internalType":"bool[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonBytes","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonBytes32","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonBytes32Array","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonBytesArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes[]","internalType":"bytes[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonInt","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"int256","internalType":"int256"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonIntArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"int256[]","internalType":"int256[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonKeys","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"keys","type":"string[]","internalType":"string[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonString","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonStringArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string[]","internalType":"string[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonType","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonType","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonTypeArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonUint","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonUintArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256[]","internalType":"uint256[]"}],"stateMutability":"pure"},{"type":"function","name":"parseToml","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"abiEncodedData","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseToml","inputs":[{"name":"toml","type":"string","internalType":"string"}],"outputs":[{"name":"abiEncodedData","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlAddress","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlAddressArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address[]","internalType":"address[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlBool","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlBoolArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool[]","internalType":"bool[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlBytes","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlBytes32","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlBytes32Array","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlBytesArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes[]","internalType":"bytes[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlInt","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"int256","internalType":"int256"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlIntArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"int256[]","internalType":"int256[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlKeys","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"keys","type":"string[]","internalType":"string[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlString","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlStringArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string[]","internalType":"string[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlType","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlType","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlTypeArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlUint","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlUintArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256[]","internalType":"uint256[]"}],"stateMutability":"pure"},{"type":"function","name":"parseUint","inputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"outputs":[{"name":"parsedValue","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"pauseGasMetering","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"pauseTracing","inputs":[],"outputs":[],"stateMutability":"view"},{"type":"function","name":"prank","inputs":[{"name":"msgSender","type":"address","internalType":"address"},{"name":"txOrigin","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"prank","inputs":[{"name":"msgSender","type":"address","internalType":"address"},{"name":"txOrigin","type":"address","internalType":"address"},{"name":"delegateCall","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"prank","inputs":[{"name":"msgSender","type":"address","internalType":"address"},{"name":"delegateCall","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"prank","inputs":[{"name":"msgSender","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"prevrandao","inputs":[{"name":"newPrevrandao","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"prevrandao","inputs":[{"name":"newPrevrandao","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"projectRoot","inputs":[],"outputs":[{"name":"path","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"prompt","inputs":[{"name":"promptText","type":"string","internalType":"string"}],"outputs":[{"name":"input","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"promptAddress","inputs":[{"name":"promptText","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"promptSecret","inputs":[{"name":"promptText","type":"string","internalType":"string"}],"outputs":[{"name":"input","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"promptSecretUint","inputs":[{"name":"promptText","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"promptUint","inputs":[{"name":"promptText","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"publicKeyP256","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"randomAddress","inputs":[],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"randomBool","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"randomBytes","inputs":[{"name":"len","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"randomBytes4","inputs":[],"outputs":[{"name":"","type":"bytes4","internalType":"bytes4"}],"stateMutability":"view"},{"type":"function","name":"randomBytes8","inputs":[],"outputs":[{"name":"","type":"bytes8","internalType":"bytes8"}],"stateMutability":"view"},{"type":"function","name":"randomInt","inputs":[],"outputs":[{"name":"","type":"int256","internalType":"int256"}],"stateMutability":"view"},{"type":"function","name":"randomInt","inputs":[{"name":"bits","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"int256","internalType":"int256"}],"stateMutability":"view"},{"type":"function","name":"randomUint","inputs":[],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"randomUint","inputs":[{"name":"bits","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"randomUint","inputs":[{"name":"min","type":"uint256","internalType":"uint256"},{"name":"max","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"readCallers","inputs":[],"outputs":[{"name":"callerMode","type":"uint8","internalType":"enum VmSafe.CallerMode"},{"name":"msgSender","type":"address","internalType":"address"},{"name":"txOrigin","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"readDir","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"maxDepth","type":"uint64","internalType":"uint64"}],"outputs":[{"name":"entries","type":"tuple[]","internalType":"struct VmSafe.DirEntry[]","components":[{"name":"errorMessage","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"},{"name":"depth","type":"uint64","internalType":"uint64"},{"name":"isDir","type":"bool","internalType":"bool"},{"name":"isSymlink","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"readDir","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"maxDepth","type":"uint64","internalType":"uint64"},{"name":"followLinks","type":"bool","internalType":"bool"}],"outputs":[{"name":"entries","type":"tuple[]","internalType":"struct VmSafe.DirEntry[]","components":[{"name":"errorMessage","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"},{"name":"depth","type":"uint64","internalType":"uint64"},{"name":"isDir","type":"bool","internalType":"bool"},{"name":"isSymlink","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"readDir","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"entries","type":"tuple[]","internalType":"struct VmSafe.DirEntry[]","components":[{"name":"errorMessage","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"},{"name":"depth","type":"uint64","internalType":"uint64"},{"name":"isDir","type":"bool","internalType":"bool"},{"name":"isSymlink","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"readFile","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"data","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"readFileBinary","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"data","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"readLine","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"line","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"readLink","inputs":[{"name":"linkPath","type":"string","internalType":"string"}],"outputs":[{"name":"targetPath","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"record","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"recordLogs","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"rememberKey","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"keyAddr","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"rememberKeys","inputs":[{"name":"mnemonic","type":"string","internalType":"string"},{"name":"derivationPath","type":"string","internalType":"string"},{"name":"count","type":"uint32","internalType":"uint32"}],"outputs":[{"name":"keyAddrs","type":"address[]","internalType":"address[]"}],"stateMutability":"nonpayable"},{"type":"function","name":"rememberKeys","inputs":[{"name":"mnemonic","type":"string","internalType":"string"},{"name":"derivationPath","type":"string","internalType":"string"},{"name":"language","type":"string","internalType":"string"},{"name":"count","type":"uint32","internalType":"uint32"}],"outputs":[{"name":"keyAddrs","type":"address[]","internalType":"address[]"}],"stateMutability":"nonpayable"},{"type":"function","name":"removeDir","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"recursive","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"removeFile","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"replace","inputs":[{"name":"input","type":"string","internalType":"string"},{"name":"from","type":"string","internalType":"string"},{"name":"to","type":"string","internalType":"string"}],"outputs":[{"name":"output","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"resetGasMetering","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"resetNonce","inputs":[{"name":"account","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"resolveEnv","inputs":[{"name":"input","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"resumeGasMetering","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"resumeTracing","inputs":[],"outputs":[],"stateMutability":"view"},{"type":"function","name":"revertTo","inputs":[{"name":"snapshotId","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"success","type":"bool","internalType":"bool"}],"stateMutability":"nonpayable"},{"type":"function","name":"revertToAndDelete","inputs":[{"name":"snapshotId","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"success","type":"bool","internalType":"bool"}],"stateMutability":"nonpayable"},{"type":"function","name":"revertToState","inputs":[{"name":"snapshotId","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"success","type":"bool","internalType":"bool"}],"stateMutability":"nonpayable"},{"type":"function","name":"revertToStateAndDelete","inputs":[{"name":"snapshotId","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"success","type":"bool","internalType":"bool"}],"stateMutability":"nonpayable"},{"type":"function","name":"revokePersistent","inputs":[{"name":"accounts","type":"address[]","internalType":"address[]"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"revokePersistent","inputs":[{"name":"account","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"roll","inputs":[{"name":"newHeight","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"rollFork","inputs":[{"name":"txHash","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"rollFork","inputs":[{"name":"forkId","type":"uint256","internalType":"uint256"},{"name":"blockNumber","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"rollFork","inputs":[{"name":"blockNumber","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"rollFork","inputs":[{"name":"forkId","type":"uint256","internalType":"uint256"},{"name":"txHash","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"rpc","inputs":[{"name":"urlOrAlias","type":"string","internalType":"string"},{"name":"method","type":"string","internalType":"string"},{"name":"params","type":"string","internalType":"string"}],"outputs":[{"name":"data","type":"bytes","internalType":"bytes"}],"stateMutability":"nonpayable"},{"type":"function","name":"rpc","inputs":[{"name":"method","type":"string","internalType":"string"},{"name":"params","type":"string","internalType":"string"}],"outputs":[{"name":"data","type":"bytes","internalType":"bytes"}],"stateMutability":"nonpayable"},{"type":"function","name":"rpcUrl","inputs":[{"name":"rpcAlias","type":"string","internalType":"string"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"rpcUrlStructs","inputs":[],"outputs":[{"name":"urls","type":"tuple[]","internalType":"struct VmSafe.Rpc[]","components":[{"name":"key","type":"string","internalType":"string"},{"name":"url","type":"string","internalType":"string"}]}],"stateMutability":"view"},{"type":"function","name":"rpcUrls","inputs":[],"outputs":[{"name":"urls","type":"string[2][]","internalType":"string[2][]"}],"stateMutability":"view"},{"type":"function","name":"selectFork","inputs":[{"name":"forkId","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"serializeAddress","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"address[]","internalType":"address[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeAddress","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"address","internalType":"address"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeBool","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"bool[]","internalType":"bool[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeBool","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"bool","internalType":"bool"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeBytes","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"bytes[]","internalType":"bytes[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeBytes","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeBytes32","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeBytes32","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeInt","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"int256","internalType":"int256"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeInt","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"int256[]","internalType":"int256[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeJson","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"value","type":"string","internalType":"string"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeJsonType","inputs":[{"name":"typeDescription","type":"string","internalType":"string"},{"name":"value","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"serializeJsonType","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"},{"name":"value","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeString","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"string[]","internalType":"string[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeString","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"string","internalType":"string"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeUint","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeUint","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"uint256[]","internalType":"uint256[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeUintToHex","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"setArbitraryStorage","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"overwrite","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"setArbitraryStorage","inputs":[{"name":"target","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"setBlockhash","inputs":[{"name":"blockNumber","type":"uint256","internalType":"uint256"},{"name":"blockHash","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"setEnv","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"value","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"setNonce","inputs":[{"name":"account","type":"address","internalType":"address"},{"name":"newNonce","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"setNonceUnsafe","inputs":[{"name":"account","type":"address","internalType":"address"},{"name":"newNonce","type":"uint64","internalType":"uint64"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"setSeed","inputs":[{"name":"seed","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"shuffle","inputs":[{"name":"array","type":"uint256[]","internalType":"uint256[]"}],"outputs":[{"name":"","type":"uint256[]","internalType":"uint256[]"}],"stateMutability":"nonpayable"},{"type":"function","name":"sign","inputs":[{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"sign","inputs":[{"name":"signer","type":"address","internalType":"address"},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"sign","inputs":[{"name":"wallet","type":"tuple","internalType":"struct VmSafe.Wallet","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"},{"name":"privateKey","type":"uint256","internalType":"uint256"}]},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"}],"stateMutability":"nonpayable"},{"type":"function","name":"sign","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"signAndAttachDelegation","inputs":[{"name":"implementation","type":"address","internalType":"address"},{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"signAndAttachDelegation","inputs":[{"name":"implementation","type":"address","internalType":"address"},{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"nonce","type":"uint64","internalType":"uint64"}],"outputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"signAndAttachDelegation","inputs":[{"name":"implementation","type":"address","internalType":"address"},{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"crossChain","type":"bool","internalType":"bool"}],"outputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"signCompact","inputs":[{"name":"wallet","type":"tuple","internalType":"struct VmSafe.Wallet","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"},{"name":"privateKey","type":"uint256","internalType":"uint256"}]},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"vs","type":"bytes32","internalType":"bytes32"}],"stateMutability":"nonpayable"},{"type":"function","name":"signCompact","inputs":[{"name":"signer","type":"address","internalType":"address"},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"vs","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"signCompact","inputs":[{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"vs","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"signCompact","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"vs","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"signDelegation","inputs":[{"name":"implementation","type":"address","internalType":"address"},{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"signDelegation","inputs":[{"name":"implementation","type":"address","internalType":"address"},{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"crossChain","type":"bool","internalType":"bool"}],"outputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"signDelegation","inputs":[{"name":"implementation","type":"address","internalType":"address"},{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"nonce","type":"uint64","internalType":"uint64"}],"outputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"signP256","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"skip","inputs":[{"name":"skipTest","type":"bool","internalType":"bool"},{"name":"reason","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"skip","inputs":[{"name":"skipTest","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"sleep","inputs":[{"name":"duration","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"snapshot","inputs":[],"outputs":[{"name":"snapshotId","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"snapshotGasLastCall","inputs":[{"name":"group","type":"string","internalType":"string"},{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"gasUsed","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"snapshotGasLastCall","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"gasUsed","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"snapshotState","inputs":[],"outputs":[{"name":"snapshotId","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"snapshotValue","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"value","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"snapshotValue","inputs":[{"name":"group","type":"string","internalType":"string"},{"name":"name","type":"string","internalType":"string"},{"name":"value","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"sort","inputs":[{"name":"array","type":"uint256[]","internalType":"uint256[]"}],"outputs":[{"name":"","type":"uint256[]","internalType":"uint256[]"}],"stateMutability":"nonpayable"},{"type":"function","name":"split","inputs":[{"name":"input","type":"string","internalType":"string"},{"name":"delimiter","type":"string","internalType":"string"}],"outputs":[{"name":"outputs","type":"string[]","internalType":"string[]"}],"stateMutability":"pure"},{"type":"function","name":"startBroadcast","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startBroadcast","inputs":[{"name":"signer","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startBroadcast","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startDebugTraceRecording","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startMappingRecording","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startPrank","inputs":[{"name":"msgSender","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startPrank","inputs":[{"name":"msgSender","type":"address","internalType":"address"},{"name":"delegateCall","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startPrank","inputs":[{"name":"msgSender","type":"address","internalType":"address"},{"name":"txOrigin","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startPrank","inputs":[{"name":"msgSender","type":"address","internalType":"address"},{"name":"txOrigin","type":"address","internalType":"address"},{"name":"delegateCall","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startSnapshotGas","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startSnapshotGas","inputs":[{"name":"group","type":"string","internalType":"string"},{"name":"name","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startStateDiffRecording","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"stopAndReturnDebugTraceRecording","inputs":[],"outputs":[{"name":"step","type":"tuple[]","internalType":"struct VmSafe.DebugStep[]","components":[{"name":"stack","type":"uint256[]","internalType":"uint256[]"},{"name":"memoryInput","type":"bytes","internalType":"bytes"},{"name":"opcode","type":"uint8","internalType":"uint8"},{"name":"depth","type":"uint64","internalType":"uint64"},{"name":"isOutOfGas","type":"bool","internalType":"bool"},{"name":"contractAddr","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"stopAndReturnStateDiff","inputs":[],"outputs":[{"name":"accountAccesses","type":"tuple[]","internalType":"struct VmSafe.AccountAccess[]","components":[{"name":"chainInfo","type":"tuple","internalType":"struct VmSafe.ChainInfo","components":[{"name":"forkId","type":"uint256","internalType":"uint256"},{"name":"chainId","type":"uint256","internalType":"uint256"}]},{"name":"kind","type":"uint8","internalType":"enum VmSafe.AccountAccessKind"},{"name":"account","type":"address","internalType":"address"},{"name":"accessor","type":"address","internalType":"address"},{"name":"initialized","type":"bool","internalType":"bool"},{"name":"oldBalance","type":"uint256","internalType":"uint256"},{"name":"newBalance","type":"uint256","internalType":"uint256"},{"name":"deployedCode","type":"bytes","internalType":"bytes"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"reverted","type":"bool","internalType":"bool"},{"name":"storageAccesses","type":"tuple[]","internalType":"struct VmSafe.StorageAccess[]","components":[{"name":"account","type":"address","internalType":"address"},{"name":"slot","type":"bytes32","internalType":"bytes32"},{"name":"isWrite","type":"bool","internalType":"bool"},{"name":"previousValue","type":"bytes32","internalType":"bytes32"},{"name":"newValue","type":"bytes32","internalType":"bytes32"},{"name":"reverted","type":"bool","internalType":"bool"}]},{"name":"depth","type":"uint64","internalType":"uint64"},{"name":"oldNonce","type":"uint64","internalType":"uint64"},{"name":"newNonce","type":"uint64","internalType":"uint64"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"stopBroadcast","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"stopExpectSafeMemory","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"stopMappingRecording","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"stopPrank","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"stopRecord","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"stopSnapshotGas","inputs":[{"name":"group","type":"string","internalType":"string"},{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"gasUsed","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"stopSnapshotGas","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"gasUsed","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"stopSnapshotGas","inputs":[],"outputs":[{"name":"gasUsed","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"store","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"slot","type":"bytes32","internalType":"bytes32"},{"name":"value","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"toBase64","inputs":[{"name":"data","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toBase64","inputs":[{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toBase64URL","inputs":[{"name":"data","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toBase64URL","inputs":[{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toLowercase","inputs":[{"name":"input","type":"string","internalType":"string"}],"outputs":[{"name":"output","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toString","inputs":[{"name":"value","type":"address","internalType":"address"}],"outputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toString","inputs":[{"name":"value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toString","inputs":[{"name":"value","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toString","inputs":[{"name":"value","type":"bool","internalType":"bool"}],"outputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toString","inputs":[{"name":"value","type":"int256","internalType":"int256"}],"outputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toString","inputs":[{"name":"value","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toUppercase","inputs":[{"name":"input","type":"string","internalType":"string"}],"outputs":[{"name":"output","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"transact","inputs":[{"name":"forkId","type":"uint256","internalType":"uint256"},{"name":"txHash","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"transact","inputs":[{"name":"txHash","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"trim","inputs":[{"name":"input","type":"string","internalType":"string"}],"outputs":[{"name":"output","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"tryFfi","inputs":[{"name":"commandInput","type":"string[]","internalType":"string[]"}],"outputs":[{"name":"result","type":"tuple","internalType":"struct VmSafe.FfiResult","components":[{"name":"exitCode","type":"int32","internalType":"int32"},{"name":"stdout","type":"bytes","internalType":"bytes"},{"name":"stderr","type":"bytes","internalType":"bytes"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"txGasPrice","inputs":[{"name":"newGasPrice","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"unixTime","inputs":[],"outputs":[{"name":"milliseconds","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"warmSlot","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"slot","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"warp","inputs":[{"name":"newTimestamp","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeFile","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"data","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeFileBinary","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeJson","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeJson","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeLine","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"data","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeToml","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeToml","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"accessList((address,bytes32[])[])":"743e4cb7","accesses(address)":"65bc9481","activeFork()":"2f103f22","addr(uint256)":"ffa18649","allowCheatcodes(address)":"ea060291","assertApproxEqAbs(int256,int256,uint256)":"240f839d","assertApproxEqAbs(int256,int256,uint256,string)":"8289e621","assertApproxEqAbs(uint256,uint256,uint256)":"16d207c6","assertApproxEqAbs(uint256,uint256,uint256,string)":"f710b062","assertApproxEqAbsDecimal(int256,int256,uint256,uint256)":"3d5bc8bc","assertApproxEqAbsDecimal(int256,int256,uint256,uint256,string)":"6a5066d4","assertApproxEqAbsDecimal(uint256,uint256,uint256,uint256)":"045c55ce","assertApproxEqAbsDecimal(uint256,uint256,uint256,uint256,string)":"60429eb2","assertApproxEqRel(int256,int256,uint256)":"fea2d14f","assertApproxEqRel(int256,int256,uint256,string)":"ef277d72","assertApproxEqRel(uint256,uint256,uint256)":"8cf25ef4","assertApproxEqRel(uint256,uint256,uint256,string)":"1ecb7d33","assertApproxEqRelDecimal(int256,int256,uint256,uint256)":"abbf21cc","assertApproxEqRelDecimal(int256,int256,uint256,uint256,string)":"fccc11c4","assertApproxEqRelDecimal(uint256,uint256,uint256,uint256)":"21ed2977","assertApproxEqRelDecimal(uint256,uint256,uint256,uint256,string)":"82d6c8fd","assertEq(address,address)":"515361f6","assertEq(address,address,string)":"2f2769d1","assertEq(address[],address[])":"3868ac34","assertEq(address[],address[],string)":"3e9173c5","assertEq(bool,bool)":"f7fe3477","assertEq(bool,bool,string)":"4db19e7e","assertEq(bool[],bool[])":"707df785","assertEq(bool[],bool[],string)":"e48a8f8d","assertEq(bytes,bytes)":"97624631","assertEq(bytes,bytes,string)":"e24fed00","assertEq(bytes32,bytes32)":"7c84c69b","assertEq(bytes32,bytes32,string)":"c1fa1ed0","assertEq(bytes32[],bytes32[])":"0cc9ee84","assertEq(bytes32[],bytes32[],string)":"e03e9177","assertEq(bytes[],bytes[])":"e5fb9b4a","assertEq(bytes[],bytes[],string)":"f413f0b6","assertEq(int256,int256)":"fe74f05b","assertEq(int256,int256,string)":"714a2f13","assertEq(int256[],int256[])":"711043ac","assertEq(int256[],int256[],string)":"191f1b30","assertEq(string,string)":"f320d963","assertEq(string,string,string)":"36f656d8","assertEq(string[],string[])":"cf1c049c","assertEq(string[],string[],string)":"eff6b27d","assertEq(uint256,uint256)":"98296c54","assertEq(uint256,uint256,string)":"88b44c85","assertEq(uint256[],uint256[])":"975d5a12","assertEq(uint256[],uint256[],string)":"5d18c73a","assertEqDecimal(int256,int256,uint256)":"48016c04","assertEqDecimal(int256,int256,uint256,string)":"7e77b0c5","assertEqDecimal(uint256,uint256,uint256)":"27af7d9c","assertEqDecimal(uint256,uint256,uint256,string)":"d0cbbdef","assertFalse(bool)":"a5982885","assertFalse(bool,string)":"7ba04809","assertGe(int256,int256)":"0a30b771","assertGe(int256,int256,string)":"a84328dd","assertGe(uint256,uint256)":"a8d4d1d9","assertGe(uint256,uint256,string)":"e25242c0","assertGeDecimal(int256,int256,uint256)":"dc28c0f1","assertGeDecimal(int256,int256,uint256,string)":"5df93c9b","assertGeDecimal(uint256,uint256,uint256)":"3d1fe08a","assertGeDecimal(uint256,uint256,uint256,string)":"8bff9133","assertGt(int256,int256)":"5a362d45","assertGt(int256,int256,string)":"f8d33b9b","assertGt(uint256,uint256)":"db07fcd2","assertGt(uint256,uint256,string)":"d9a3c4d2","assertGtDecimal(int256,int256,uint256)":"78611f0e","assertGtDecimal(int256,int256,uint256,string)":"04a5c7ab","assertGtDecimal(uint256,uint256,uint256)":"eccd2437","assertGtDecimal(uint256,uint256,uint256,string)":"64949a8d","assertLe(int256,int256)":"95fd154e","assertLe(int256,int256,string)":"4dfe692c","assertLe(uint256,uint256)":"8466f415","assertLe(uint256,uint256,string)":"d17d4b0d","assertLeDecimal(int256,int256,uint256)":"11d1364a","assertLeDecimal(int256,int256,uint256,string)":"aa5cf788","assertLeDecimal(uint256,uint256,uint256)":"c304aab7","assertLeDecimal(uint256,uint256,uint256,string)":"7fefbbe0","assertLt(int256,int256)":"3e914080","assertLt(int256,int256,string)":"9ff531e3","assertLt(uint256,uint256)":"b12fc005","assertLt(uint256,uint256,string)":"65d5c135","assertLtDecimal(int256,int256,uint256)":"dbe8d88b","assertLtDecimal(int256,int256,uint256,string)":"40f0b4e0","assertLtDecimal(uint256,uint256,uint256)":"2077337e","assertLtDecimal(uint256,uint256,uint256,string)":"a972d037","assertNotEq(address,address)":"b12e1694","assertNotEq(address,address,string)":"8775a591","assertNotEq(address[],address[])":"46d0b252","assertNotEq(address[],address[],string)":"72c7e0b5","assertNotEq(bool,bool)":"236e4d66","assertNotEq(bool,bool,string)":"1091a261","assertNotEq(bool[],bool[])":"286fafea","assertNotEq(bool[],bool[],string)":"62c6f9fb","assertNotEq(bytes,bytes)":"3cf78e28","assertNotEq(bytes,bytes,string)":"9507540e","assertNotEq(bytes32,bytes32)":"898e83fc","assertNotEq(bytes32,bytes32,string)":"b2332f51","assertNotEq(bytes32[],bytes32[])":"0603ea68","assertNotEq(bytes32[],bytes32[],string)":"b873634c","assertNotEq(bytes[],bytes[])":"edecd035","assertNotEq(bytes[],bytes[],string)":"1dcd1f68","assertNotEq(int256,int256)":"f4c004e3","assertNotEq(int256,int256,string)":"4724c5b9","assertNotEq(int256[],int256[])":"0b72f4ef","assertNotEq(int256[],int256[],string)":"d3977322","assertNotEq(string,string)":"6a8237b3","assertNotEq(string,string,string)":"78bdcea7","assertNotEq(string[],string[])":"bdfacbe8","assertNotEq(string[],string[],string)":"b67187f3","assertNotEq(uint256,uint256)":"b7909320","assertNotEq(uint256,uint256,string)":"98f9bdbd","assertNotEq(uint256[],uint256[])":"56f29cba","assertNotEq(uint256[],uint256[],string)":"9a7fbd8f","assertNotEqDecimal(int256,int256,uint256)":"14e75680","assertNotEqDecimal(int256,int256,uint256,string)":"33949f0b","assertNotEqDecimal(uint256,uint256,uint256)":"669efca7","assertNotEqDecimal(uint256,uint256,uint256,string)":"f5a55558","assertTrue(bool)":"0c9fd581","assertTrue(bool,string)":"a34edc03","assume(bool)":"4c63e562","assumeNoRevert((address,bool,bytes))":"d8591eeb","assumeNoRevert((address,bool,bytes)[])":"8a4592cc","assumeNoRevert()":"285b366a","attachBlob(bytes)":"10cb385c","attachDelegation((uint8,bytes32,bytes32,uint64,address))":"14ae3519","attachDelegation((uint8,bytes32,bytes32,uint64,address),bool)":"f4460d34","blobBaseFee(uint256)":"6d315d7e","blobhashes(bytes32[])":"129de7eb","bound(int256,int256,int256)":"8f48fc07","bound(uint256,uint256,uint256)":"5a6c1eed","breakpoint(string)":"f0259e92","breakpoint(string,bool)":"f7d39a8d","broadcast()":"afc98040","broadcast(address)":"e6962cdb","broadcast(uint256)":"f67a965b","broadcastRawTransaction(bytes)":"8c0c72e0","chainId(uint256)":"4049ddd2","clearMockedCalls()":"3fdf4e15","cloneAccount(address,address)":"533d61c9","closeFile(string)":"48c3241f","coinbase(address)":"ff483c54","computeCreate2Address(bytes32,bytes32)":"890c283b","computeCreate2Address(bytes32,bytes32,address)":"d323826a","computeCreateAddress(address,uint256)":"74637a7a","contains(string,string)":"3fb18aec","cool(address)":"40ff9f21","coolSlot(address,bytes32)":"8c78e654","copyFile(string,string)":"a54a87d8","copyStorage(address,address)":"203dac0d","createDir(string,bool)":"168b64d3","createFork(string)":"31ba3498","createFork(string,bytes32)":"7ca29682","createFork(string,uint256)":"6ba3ba2b","createSelectFork(string)":"98680034","createSelectFork(string,bytes32)":"84d52b7a","createSelectFork(string,uint256)":"71ee464d","createWallet(string)":"7404f1d2","createWallet(uint256)":"7a675bb6","createWallet(uint256,string)":"ed7c5462","deal(address,uint256)":"c88a5e6d","deleteSnapshot(uint256)":"a6368557","deleteSnapshots()":"421ae469","deleteStateSnapshot(uint256)":"08d6b37a","deleteStateSnapshots()":"e0933c74","deployCode(string)":"9a8325a0","deployCode(string,bytes)":"29ce9dde","deployCode(string,bytes,bytes32)":"016155bf","deployCode(string,bytes,uint256)":"ff5d64e4","deployCode(string,bytes,uint256,bytes32)":"3aa773ea","deployCode(string,bytes32)":"17ab1d79","deployCode(string,uint256)":"0af6a701","deployCode(string,uint256,bytes32)":"002cb687","deriveKey(string,string,uint32)":"6bcb2c1b","deriveKey(string,string,uint32,string)":"29233b1f","deriveKey(string,uint32)":"6229498b","deriveKey(string,uint32,string)":"32c8176d","difficulty(uint256)":"46cc92d9","dumpState(string)":"709ecd3f","eip712HashStruct(string,bytes)":"aedeaebc","eip712HashStruct(string,string,bytes)":"6d06c57c","eip712HashType(string)":"6792e9e2","eip712HashType(string,string)":"18fb6406","eip712HashTypedData(string)":"ea25e615","ensNamehash(string)":"8c374c65","envAddress(string)":"350d56bf","envAddress(string,string)":"ad31b9fa","envBool(string)":"7ed1ec7d","envBool(string,string)":"aaaddeaf","envBytes(string)":"4d7baf06","envBytes(string,string)":"ddc2651b","envBytes32(string)":"97949042","envBytes32(string,string)":"5af231c1","envExists(string)":"ce8365f9","envInt(string)":"892a0c61","envInt(string,string)":"42181150","envOr(string,address)":"561fe540","envOr(string,bool)":"4777f3cf","envOr(string,bytes)":"b3e47705","envOr(string,bytes32)":"b4a85892","envOr(string,int256)":"bbcb713e","envOr(string,string)":"d145736c","envOr(string,string,address[])":"c74e9deb","envOr(string,string,bool[])":"eb85e83b","envOr(string,string,bytes32[])":"2281f367","envOr(string,string,bytes[])":"64bc3e64","envOr(string,string,int256[])":"4700d74b","envOr(string,string,string[])":"859216bc","envOr(string,string,uint256[])":"74318528","envOr(string,uint256)":"5e97348f","envString(string)":"f877cb19","envString(string,string)":"14b02bc9","envUint(string)":"c1978d1f","envUint(string,string)":"f3dec099","etch(address,bytes)":"b4d6c782","eth_getLogs(uint256,uint256,address,bytes32[])":"35e1349b","exists(string)":"261a323e","expectCall(address,bytes)":"bd6af434","expectCall(address,bytes,uint64)":"c1adbbff","expectCall(address,uint256,bytes)":"f30c7ba3","expectCall(address,uint256,bytes,uint64)":"a2b1a1ae","expectCall(address,uint256,uint64,bytes)":"23361207","expectCall(address,uint256,uint64,bytes,uint64)":"65b7b7cc","expectCallMinGas(address,uint256,uint64,bytes)":"08e4e116","expectCallMinGas(address,uint256,uint64,bytes,uint64)":"e13a1834","expectCreate(bytes,address)":"73cdce36","expectCreate2(bytes,address)":"ea54a472","expectEmit()":"440ed10d","expectEmit(address)":"86b9620d","expectEmit(address,uint64)":"b43aece3","expectEmit(bool,bool,bool,bool)":"491cc7c2","expectEmit(bool,bool,bool,bool,address)":"81bad6f3","expectEmit(bool,bool,bool,bool,address,uint64)":"c339d02c","expectEmit(bool,bool,bool,bool,uint64)":"5e1d1c33","expectEmit(uint64)":"4c74a335","expectEmitAnonymous()":"2e5f270c","expectEmitAnonymous(address)":"6fc68705","expectEmitAnonymous(bool,bool,bool,bool,bool)":"c948db5e","expectEmitAnonymous(bool,bool,bool,bool,bool,address)":"71c95899","expectPartialRevert(bytes4)":"11fb5b9c","expectPartialRevert(bytes4,address)":"51aa008a","expectRevert()":"f4844814","expectRevert(address)":"d814f38a","expectRevert(address,uint64)":"1ff5f952","expectRevert(bytes)":"f28dceb3","expectRevert(bytes,address)":"61ebcf12","expectRevert(bytes,address,uint64)":"d345fb1f","expectRevert(bytes,uint64)":"4994c273","expectRevert(bytes4)":"c31eb0e0","expectRevert(bytes4,address)":"260bc5de","expectRevert(bytes4,address,uint64)":"b0762d73","expectRevert(bytes4,uint64)":"e45ca72d","expectRevert(uint64)":"4ee38244","expectSafeMemory(uint64,uint64)":"6d016688","expectSafeMemoryCall(uint64,uint64)":"05838bf4","fee(uint256)":"39b37ab0","ffi(string[])":"89160467","foundryVersionAtLeast(string)":"6248be1f","foundryVersionCmp(string)":"ca7b0a09","fsMetadata(string)":"af368a08","getArtifactPathByCode(bytes)":"eb74848c","getArtifactPathByDeployedCode(bytes)":"6d853ba5","getBlobBaseFee()":"1f6d6ef7","getBlobhashes()":"f56ff18b","getBlockNumber()":"42cbb15c","getBlockTimestamp()":"796b89b9","getBroadcast(string,uint64,uint8)":"3dc90cb3","getBroadcasts(string,uint64)":"f2fa4a26","getBroadcasts(string,uint64,uint8)":"f7afe919","getChain(string)":"4cc1c2bb","getChain(uint256)":"b6791ad4","getChainId()":"3408e470","getCode(string)":"8d1cc925","getDeployedCode(string)":"3ebf73b4","getDeployment(string)":"a8091d97","getDeployment(string,uint64)":"0debd5d6","getDeployments(string,uint64)":"74e133dd","getFoundryVersion()":"ea991bb5","getLabel(address)":"28a249b0","getMappingKeyAndParentOf(address,bytes32)":"876e24e6","getMappingLength(address,bytes32)":"2f2fd63f","getMappingSlotAt(address,bytes32,uint256)":"ebc73ab4","getNonce((address,uint256,uint256,uint256))":"a5748aad","getNonce(address)":"2d0335ab","getRawBlockHeader(uint256)":"2c667606","getRecordedLogs()":"191553a4","getStateDiff()":"80df01cc","getStateDiffJson()":"f54fe009","getStorageAccesses()":"2899b1d0","getWallets()":"db7a4605","indexOf(string,string)":"8a0807b7","interceptInitcode()":"838653c7","isContext(uint8)":"64af255d","isDir(string)":"7d15d019","isFile(string)":"e0eb04d4","isPersistent(address)":"d92d8efd","keyExists(string,string)":"528a683c","keyExistsJson(string,string)":"db4235f6","keyExistsToml(string,string)":"600903ad","label(address,string)":"c657c718","lastCallGas()":"2b589b28","load(address,bytes32)":"667f9d70","loadAllocs(string)":"b3a056d7","makePersistent(address)":"57e22dde","makePersistent(address,address)":"4074e0a8","makePersistent(address,address,address)":"efb77a75","makePersistent(address[])":"1d9e269e","mockCall(address,bytes,bytes)":"b96213e4","mockCall(address,bytes4,bytes)":"08e0c537","mockCall(address,uint256,bytes,bytes)":"81409b91","mockCall(address,uint256,bytes4,bytes)":"e7b36a3d","mockCallRevert(address,bytes,bytes)":"dbaad147","mockCallRevert(address,bytes4,bytes)":"2dfba5df","mockCallRevert(address,uint256,bytes,bytes)":"d23cd037","mockCallRevert(address,uint256,bytes4,bytes)":"596c8f04","mockCalls(address,bytes,bytes[])":"5c5c3de9","mockCalls(address,uint256,bytes,bytes[])":"08bcbae1","mockFunction(address,address,bytes)":"adf84d21","noAccessList()":"238ad778","parseAddress(string)":"c6ce059d","parseBool(string)":"974ef924","parseBytes(string)":"8f5d232d","parseBytes32(string)":"087e6e81","parseInt(string)":"42346c5e","parseJson(string)":"6a82600a","parseJson(string,string)":"85940ef1","parseJsonAddress(string,string)":"1e19e657","parseJsonAddressArray(string,string)":"2fce7883","parseJsonBool(string,string)":"9f86dc91","parseJsonBoolArray(string,string)":"91f3b94f","parseJsonBytes(string,string)":"fd921be8","parseJsonBytes32(string,string)":"1777e59d","parseJsonBytes32Array(string,string)":"91c75bc3","parseJsonBytesArray(string,string)":"6631aa99","parseJsonInt(string,string)":"7b048ccd","parseJsonIntArray(string,string)":"9983c28a","parseJsonKeys(string,string)":"213e4198","parseJsonString(string,string)":"49c4fac8","parseJsonStringArray(string,string)":"498fdcf4","parseJsonType(string,string)":"a9da313b","parseJsonType(string,string,string)":"e3f5ae33","parseJsonTypeArray(string,string,string)":"0175d535","parseJsonUint(string,string)":"addde2b6","parseJsonUintArray(string,string)":"522074ab","parseToml(string)":"592151f0","parseToml(string,string)":"37736e08","parseTomlAddress(string,string)":"65e7c844","parseTomlAddressArray(string,string)":"65c428e7","parseTomlBool(string,string)":"d30dced6","parseTomlBoolArray(string,string)":"127cfe9a","parseTomlBytes(string,string)":"d77bfdb9","parseTomlBytes32(string,string)":"8e214810","parseTomlBytes32Array(string,string)":"3e716f81","parseTomlBytesArray(string,string)":"b197c247","parseTomlInt(string,string)":"c1350739","parseTomlIntArray(string,string)":"d3522ae6","parseTomlKeys(string,string)":"812a44b2","parseTomlString(string,string)":"8bb8dd43","parseTomlStringArray(string,string)":"9f629281","parseTomlType(string,string)":"47fa5e11","parseTomlType(string,string,string)":"f9fa5cdb","parseTomlTypeArray(string,string,string)":"49be3743","parseTomlUint(string,string)":"cc7b0487","parseTomlUintArray(string,string)":"b5df27c8","parseUint(string)":"fa91454d","pauseGasMetering()":"d1a5b36f","pauseTracing()":"c94d1f90","prank(address)":"ca669fa7","prank(address,address)":"47e50cce","prank(address,address,bool)":"7d73d042","prank(address,bool)":"a7f8bf5c","prevrandao(bytes32)":"3b925549","prevrandao(uint256)":"9cb1c0d4","projectRoot()":"d930a0e6","prompt(string)":"47eaf474","promptAddress(string)":"62ee05f4","promptSecret(string)":"1e279d41","promptSecretUint(string)":"69ca02b7","promptUint(string)":"652fd489","publicKeyP256(uint256)":"c453949e","randomAddress()":"d5bee9f5","randomBool()":"cdc126bd","randomBytes(uint256)":"6c5d32a9","randomBytes4()":"9b7cd579","randomBytes8()":"0497b0a5","randomInt()":"111f1202","randomInt(uint256)":"12845966","randomUint()":"25124730","randomUint(uint256)":"cf81e69c","randomUint(uint256,uint256)":"d61b051b","readCallers()":"4ad0bac9","readDir(string)":"c4bc59e0","readDir(string,uint64)":"1497876c","readDir(string,uint64,bool)":"8102d70d","readFile(string)":"60f9bb11","readFileBinary(string)":"16ed7bc4","readLine(string)":"70f55728","readLink(string)":"9f5684a2","record()":"266cf109","recordLogs()":"41af2f52","rememberKey(uint256)":"22100064","rememberKeys(string,string,string,uint32)":"f8d58eaf","rememberKeys(string,string,uint32)":"97cb9189","removeDir(string,bool)":"45c62011","removeFile(string)":"f1afe04d","replace(string,string,string)":"e00ad03e","resetGasMetering()":"be367dd3","resetNonce(address)":"1c72346d","resolveEnv(string)":"ddd2128d","resumeGasMetering()":"2bcd50e0","resumeTracing()":"72a09ccb","revertTo(uint256)":"44d7f0a4","revertToAndDelete(uint256)":"03e0aca9","revertToState(uint256)":"c2527405","revertToStateAndDelete(uint256)":"3a1985dc","revokePersistent(address)":"997a0222","revokePersistent(address[])":"3ce969e6","roll(uint256)":"1f7b4f30","rollFork(bytes32)":"0f29772b","rollFork(uint256)":"d9bbf3a1","rollFork(uint256,bytes32)":"f2830f7b","rollFork(uint256,uint256)":"d74c83a4","rpc(string,string)":"1206c8a8","rpc(string,string,string)":"0199a220","rpcUrl(string)":"975a6ce9","rpcUrlStructs()":"9d2ad72a","rpcUrls()":"a85a8418","selectFork(uint256)":"9ebf6827","serializeAddress(string,string,address)":"972c6062","serializeAddress(string,string,address[])":"1e356e1a","serializeBool(string,string,bool)":"ac22e971","serializeBool(string,string,bool[])":"92925aa1","serializeBytes(string,string,bytes)":"f21d52c7","serializeBytes(string,string,bytes[])":"9884b232","serializeBytes32(string,string,bytes32)":"2d812b44","serializeBytes32(string,string,bytes32[])":"201e43e2","serializeInt(string,string,int256)":"3f33db60","serializeInt(string,string,int256[])":"7676e127","serializeJson(string,string)":"9b3358b0","serializeJsonType(string,bytes)":"6d4f96a6","serializeJsonType(string,string,string,bytes)":"6f93bccb","serializeString(string,string,string)":"88da6d35","serializeString(string,string,string[])":"561cd6f3","serializeUint(string,string,uint256)":"129e9002","serializeUint(string,string,uint256[])":"fee9a469","serializeUintToHex(string,string,uint256)":"ae5a2ae8","setArbitraryStorage(address)":"e1631837","setArbitraryStorage(address,bool)":"d3ec2a0b","setBlockhash(uint256,bytes32)":"5314b54a","setEnv(string,string)":"3d5923ee","setNonce(address,uint64)":"f8e18b57","setNonceUnsafe(address,uint64)":"9b67b21c","setSeed(uint256)":"c32a50f9","shuffle(uint256[])":"54f1469c","sign((address,uint256,uint256,uint256),bytes32)":"b25c5a25","sign(address,bytes32)":"8c1aa205","sign(bytes32)":"799cd333","sign(uint256,bytes32)":"e341eaa4","signAndAttachDelegation(address,uint256)":"c7fa7288","signAndAttachDelegation(address,uint256,bool)":"d936e146","signAndAttachDelegation(address,uint256,uint64)":"cde3e5be","signCompact((address,uint256,uint256,uint256),bytes32)":"3d0e292f","signCompact(address,bytes32)":"8e2f97bf","signCompact(bytes32)":"a282dc4b","signCompact(uint256,bytes32)":"cc2a781f","signDelegation(address,uint256)":"5b593c7b","signDelegation(address,uint256,bool)":"cdd7563d","signDelegation(address,uint256,uint64)":"ceba2ec3","signP256(uint256,bytes32)":"83211b40","skip(bool)":"dd82d13e","skip(bool,string)":"c42a80a7","sleep(uint256)":"fa9d8713","snapshot()":"9711715a","snapshotGasLastCall(string)":"dd9fca12","snapshotGasLastCall(string,string)":"200c6772","snapshotState()":"9cd23835","snapshotValue(string,string,uint256)":"6d2b27d8","snapshotValue(string,uint256)":"51db805a","sort(uint256[])":"9ec8b026","split(string,string)":"8bb75533","startBroadcast()":"7fb5297f","startBroadcast(address)":"7fec2a8d","startBroadcast(uint256)":"ce817d47","startDebugTraceRecording()":"419c8832","startMappingRecording()":"3e9705c0","startPrank(address)":"06447d56","startPrank(address,address)":"45b56078","startPrank(address,address,bool)":"4eb859b5","startPrank(address,bool)":"1cc0b435","startSnapshotGas(string)":"3cad9d7b","startSnapshotGas(string,string)":"6cd0cc53","startStateDiffRecording()":"cf22e3c9","stopAndReturnDebugTraceRecording()":"ced398a2","stopAndReturnStateDiff()":"aa5cf90e","stopBroadcast()":"76eadd36","stopExpectSafeMemory()":"0956441b","stopMappingRecording()":"0d4aae9b","stopPrank()":"90c5013b","stopRecord()":"996be76d","stopSnapshotGas()":"f6402eda","stopSnapshotGas(string)":"773b2805","stopSnapshotGas(string,string)":"0c9db707","store(address,bytes32,bytes32)":"70ca10bb","toBase64(bytes)":"a5cbfe65","toBase64(string)":"3f8be2c8","toBase64URL(bytes)":"c8bd0e4a","toBase64URL(string)":"ae3165b3","toLowercase(string)":"50bb0884","toString(address)":"56ca623e","toString(bool)":"71dce7da","toString(bytes)":"71aad10d","toString(bytes32)":"b11a19e8","toString(int256)":"a322c40e","toString(uint256)":"6900a3ae","toUppercase(string)":"074ae3d7","transact(bytes32)":"be646da1","transact(uint256,bytes32)":"4d8abc4b","trim(string)":"b2dad155","tryFfi(string[])":"f45c1ce7","txGasPrice(uint256)":"48f50c0f","unixTime()":"625387dc","warmSlot(address,bytes32)":"b23184cf","warp(uint256)":"e5d6bf02","writeFile(string,string)":"897e0a97","writeFileBinary(string,bytes)":"1f21fc80","writeJson(string,string)":"e23cd19f","writeJson(string,string,string)":"35d6ad46","writeLine(string,string)":"619d897f","writeToml(string,string)":"c0865ba7","writeToml(string,string,string)":"51ac6a33"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"storageKeys\",\"type\":\"bytes32[]\"}],\"internalType\":\"struct VmSafe.AccessListItem[]\",\"name\":\"access\",\"type\":\"tuple[]\"}],\"name\":\"accessList\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"accesses\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"readSlots\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"writeSlots\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"activeFork\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"addr\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"keyAddr\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"allowCheatcodes\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqAbs\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqAbs\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqAbs\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqAbs\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqAbsDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqAbsDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqAbsDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqAbsDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqRel\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqRel\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqRel\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqRel\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqRelDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqRelDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqRelDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqRelDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"left\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"right\",\"type\":\"bytes32[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256[]\",\"name\":\"left\",\"type\":\"int256[]\"},{\"internalType\":\"int256[]\",\"name\":\"right\",\"type\":\"int256[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"left\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"right\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"left\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"right\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"left\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"right\",\"type\":\"address[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"left\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"right\",\"type\":\"address[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"left\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"right\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"left\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"right\",\"type\":\"address\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"left\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"right\",\"type\":\"uint256[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool[]\",\"name\":\"left\",\"type\":\"bool[]\"},{\"internalType\":\"bool[]\",\"name\":\"right\",\"type\":\"bool[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256[]\",\"name\":\"left\",\"type\":\"int256[]\"},{\"internalType\":\"int256[]\",\"name\":\"right\",\"type\":\"int256[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"left\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"right\",\"type\":\"bytes32\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"left\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"right\",\"type\":\"uint256[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"left\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"right\",\"type\":\"bytes\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"left\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"right\",\"type\":\"bytes32\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"left\",\"type\":\"string[]\"},{\"internalType\":\"string[]\",\"name\":\"right\",\"type\":\"string[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"left\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"right\",\"type\":\"bytes32[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"left\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"right\",\"type\":\"bytes\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool[]\",\"name\":\"left\",\"type\":\"bool[]\"},{\"internalType\":\"bool[]\",\"name\":\"right\",\"type\":\"bool[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"left\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes[]\",\"name\":\"right\",\"type\":\"bytes[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"left\",\"type\":\"string[]\"},{\"internalType\":\"string[]\",\"name\":\"right\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"left\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"right\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"left\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes[]\",\"name\":\"right\",\"type\":\"bytes[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"left\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"right\",\"type\":\"bool\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"condition\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertFalse\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"condition\",\"type\":\"bool\"}],\"name\":\"assertFalse\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"}],\"name\":\"assertGe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"}],\"name\":\"assertGe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertGeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertGeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"}],\"name\":\"assertGt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"}],\"name\":\"assertGt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertGtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertGtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"}],\"name\":\"assertLe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"}],\"name\":\"assertLe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertLeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertLeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"}],\"name\":\"assertLt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"}],\"name\":\"assertLt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertLtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertLtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"left\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"right\",\"type\":\"bytes32[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256[]\",\"name\":\"left\",\"type\":\"int256[]\"},{\"internalType\":\"int256[]\",\"name\":\"right\",\"type\":\"int256[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"left\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"right\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"left\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes[]\",\"name\":\"right\",\"type\":\"bytes[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"left\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"right\",\"type\":\"bool\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool[]\",\"name\":\"left\",\"type\":\"bool[]\"},{\"internalType\":\"bool[]\",\"name\":\"right\",\"type\":\"bool[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"left\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"right\",\"type\":\"bytes\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"left\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"right\",\"type\":\"address[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"left\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"right\",\"type\":\"uint256[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool[]\",\"name\":\"left\",\"type\":\"bool[]\"},{\"internalType\":\"bool[]\",\"name\":\"right\",\"type\":\"bool[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"left\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"right\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"left\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"right\",\"type\":\"address[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"left\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"right\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"left\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"right\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"left\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"right\",\"type\":\"bytes32\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"left\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"right\",\"type\":\"bytes\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"left\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"right\",\"type\":\"uint256[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"left\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"right\",\"type\":\"address\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"left\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"right\",\"type\":\"bytes32\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"left\",\"type\":\"string[]\"},{\"internalType\":\"string[]\",\"name\":\"right\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"left\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"right\",\"type\":\"bytes32[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"left\",\"type\":\"string[]\"},{\"internalType\":\"string[]\",\"name\":\"right\",\"type\":\"string[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256[]\",\"name\":\"left\",\"type\":\"int256[]\"},{\"internalType\":\"int256[]\",\"name\":\"right\",\"type\":\"int256[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"left\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes[]\",\"name\":\"right\",\"type\":\"bytes[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertNotEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertNotEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"condition\",\"type\":\"bool\"}],\"name\":\"assertTrue\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"condition\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertTrue\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"condition\",\"type\":\"bool\"}],\"name\":\"assume\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"assumeNoRevert\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"reverter\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"partialMatch\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"revertData\",\"type\":\"bytes\"}],\"internalType\":\"struct VmSafe.PotentialRevert[]\",\"name\":\"potentialReverts\",\"type\":\"tuple[]\"}],\"name\":\"assumeNoRevert\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"reverter\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"partialMatch\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"revertData\",\"type\":\"bytes\"}],\"internalType\":\"struct VmSafe.PotentialRevert\",\"name\":\"potentialRevert\",\"type\":\"tuple\"}],\"name\":\"assumeNoRevert\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"blob\",\"type\":\"bytes\"}],\"name\":\"attachBlob\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"name\":\"attachDelegation\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"},{\"internalType\":\"bool\",\"name\":\"crossChain\",\"type\":\"bool\"}],\"name\":\"attachDelegation\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newBlobBaseFee\",\"type\":\"uint256\"}],\"name\":\"blobBaseFee\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"hashes\",\"type\":\"bytes32[]\"}],\"name\":\"blobhashes\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"current\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"min\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"max\",\"type\":\"uint256\"}],\"name\":\"bound\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"current\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"min\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"max\",\"type\":\"int256\"}],\"name\":\"bound\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"char\",\"type\":\"string\"}],\"name\":\"breakpoint\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"char\",\"type\":\"string\"},{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"name\":\"breakpoint\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"broadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"signer\",\"type\":\"address\"}],\"name\":\"broadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"broadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"broadcastRawTransaction\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newChainId\",\"type\":\"uint256\"}],\"name\":\"chainId\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"clearMockedCalls\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"cloneAccount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"closeFile\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newCoinbase\",\"type\":\"address\"}],\"name\":\"coinbase\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"salt\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"initCodeHash\",\"type\":\"bytes32\"}],\"name\":\"computeCreate2Address\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"salt\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"initCodeHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"deployer\",\"type\":\"address\"}],\"name\":\"computeCreate2Address\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"deployer\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"}],\"name\":\"computeCreateAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"subject\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"search\",\"type\":\"string\"}],\"name\":\"contains\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"cool\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"slot\",\"type\":\"bytes32\"}],\"name\":\"coolSlot\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"from\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"to\",\"type\":\"string\"}],\"name\":\"copyFile\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"copied\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"copyStorage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"bool\",\"name\":\"recursive\",\"type\":\"bool\"}],\"name\":\"createDir\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"urlOrAlias\",\"type\":\"string\"}],\"name\":\"createFork\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"urlOrAlias\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"}],\"name\":\"createFork\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"urlOrAlias\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"}],\"name\":\"createFork\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"urlOrAlias\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"}],\"name\":\"createSelectFork\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"urlOrAlias\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"}],\"name\":\"createSelectFork\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"urlOrAlias\",\"type\":\"string\"}],\"name\":\"createSelectFork\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"walletLabel\",\"type\":\"string\"}],\"name\":\"createWallet\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.Wallet\",\"name\":\"wallet\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"createWallet\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.Wallet\",\"name\":\"wallet\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"walletLabel\",\"type\":\"string\"}],\"name\":\"createWallet\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.Wallet\",\"name\":\"wallet\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"deal\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"snapshotId\",\"type\":\"uint256\"}],\"name\":\"deleteSnapshot\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"deleteSnapshots\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"snapshotId\",\"type\":\"uint256\"}],\"name\":\"deleteStateSnapshot\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"deleteStateSnapshots\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"constructorArgs\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"constructorArgs\",\"type\":\"bytes\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"constructorArgs\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"constructorArgs\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"mnemonic\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"derivationPath\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"index\",\"type\":\"uint32\"},{\"internalType\":\"string\",\"name\":\"language\",\"type\":\"string\"}],\"name\":\"deriveKey\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"mnemonic\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"index\",\"type\":\"uint32\"},{\"internalType\":\"string\",\"name\":\"language\",\"type\":\"string\"}],\"name\":\"deriveKey\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"mnemonic\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"index\",\"type\":\"uint32\"}],\"name\":\"deriveKey\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"mnemonic\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"derivationPath\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"index\",\"type\":\"uint32\"}],\"name\":\"deriveKey\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newDifficulty\",\"type\":\"uint256\"}],\"name\":\"difficulty\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"pathToStateJson\",\"type\":\"string\"}],\"name\":\"dumpState\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"bindingsPath\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeName\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"abiEncodedData\",\"type\":\"bytes\"}],\"name\":\"eip712HashStruct\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"typeHash\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"typeNameOrDefinition\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"abiEncodedData\",\"type\":\"bytes\"}],\"name\":\"eip712HashStruct\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"typeHash\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"bindingsPath\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeName\",\"type\":\"string\"}],\"name\":\"eip712HashType\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"typeHash\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"typeNameOrDefinition\",\"type\":\"string\"}],\"name\":\"eip712HashType\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"typeHash\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"jsonData\",\"type\":\"string\"}],\"name\":\"eip712HashTypedData\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"ensNamehash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"value\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envAddress\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"value\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envBool\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envBool\",\"outputs\":[{\"internalType\":\"bool[]\",\"name\":\"value\",\"type\":\"bool[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envBytes\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"value\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envBytes\",\"outputs\":[{\"internalType\":\"bytes[]\",\"name\":\"value\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envBytes32\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"value\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envBytes32\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"value\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envInt\",\"outputs\":[{\"internalType\":\"int256[]\",\"name\":\"value\",\"type\":\"int256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envInt\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"value\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"bytes32[]\",\"name\":\"defaultValue\",\"type\":\"bytes32[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"value\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"int256[]\",\"name\":\"defaultValue\",\"type\":\"int256[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"int256[]\",\"name\":\"value\",\"type\":\"int256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"bool\",\"name\":\"defaultValue\",\"type\":\"bool\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"address\",\"name\":\"defaultValue\",\"type\":\"address\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"value\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"defaultValue\",\"type\":\"uint256\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"bytes[]\",\"name\":\"defaultValue\",\"type\":\"bytes[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"bytes[]\",\"name\":\"value\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"uint256[]\",\"name\":\"defaultValue\",\"type\":\"uint256[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"value\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"defaultValue\",\"type\":\"string[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"value\",\"type\":\"string[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"defaultValue\",\"type\":\"bytes\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"value\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"defaultValue\",\"type\":\"bytes32\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"value\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"int256\",\"name\":\"defaultValue\",\"type\":\"int256\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"value\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"address[]\",\"name\":\"defaultValue\",\"type\":\"address[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"value\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"defaultValue\",\"type\":\"string\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"value\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"bool[]\",\"name\":\"defaultValue\",\"type\":\"bool[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"bool[]\",\"name\":\"value\",\"type\":\"bool[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envString\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"value\",\"type\":\"string[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"value\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envUint\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"value\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newRuntimeBytecode\",\"type\":\"bytes\"}],\"name\":\"etch\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"fromBlock\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"toBlock\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"}],\"name\":\"eth_getLogs\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"emitter\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"blockNumber\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"transactionHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"transactionIndex\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"logIndex\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"removed\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.EthGetLogs[]\",\"name\":\"logs\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"exists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"msgValue\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"gas\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"expectCall\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"msgValue\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"gas\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectCall\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"msgValue\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectCall\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"expectCall\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectCall\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"msgValue\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"expectCall\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"msgValue\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"minGas\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"expectCallMinGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"msgValue\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"minGas\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectCallMinGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"bytecode\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"deployer\",\"type\":\"address\"}],\"name\":\"expectCreate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"bytecode\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"deployer\",\"type\":\"address\"}],\"name\":\"expectCreate2\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"expectEmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"checkTopic1\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic2\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic3\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkData\",\"type\":\"bool\"}],\"name\":\"expectEmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectEmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"checkTopic1\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic2\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic3\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkData\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectEmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"checkTopic1\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic2\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic3\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkData\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"emitter\",\"type\":\"address\"}],\"name\":\"expectEmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"emitter\",\"type\":\"address\"}],\"name\":\"expectEmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"emitter\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectEmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"checkTopic1\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic2\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic3\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkData\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"emitter\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectEmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"expectEmitAnonymous\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"emitter\",\"type\":\"address\"}],\"name\":\"expectEmitAnonymous\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"checkTopic0\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic1\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic2\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic3\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkData\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"emitter\",\"type\":\"address\"}],\"name\":\"expectEmitAnonymous\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"checkTopic0\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic1\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic2\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkTopic3\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"checkData\",\"type\":\"bool\"}],\"name\":\"expectEmitAnonymous\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"revertData\",\"type\":\"bytes4\"}],\"name\":\"expectPartialRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"revertData\",\"type\":\"bytes4\"},{\"internalType\":\"address\",\"name\":\"reverter\",\"type\":\"address\"}],\"name\":\"expectPartialRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"reverter\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"revertData\",\"type\":\"bytes4\"},{\"internalType\":\"address\",\"name\":\"reverter\",\"type\":\"address\"}],\"name\":\"expectRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"revertData\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"revertData\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"reverter\",\"type\":\"address\"}],\"name\":\"expectRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"revertData\",\"type\":\"bytes4\"},{\"internalType\":\"address\",\"name\":\"reverter\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"revertData\",\"type\":\"bytes4\"}],\"name\":\"expectRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"revertData\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"reverter\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"reverter\",\"type\":\"address\"}],\"name\":\"expectRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"revertData\",\"type\":\"bytes4\"},{\"internalType\":\"uint64\",\"name\":\"count\",\"type\":\"uint64\"}],\"name\":\"expectRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"revertData\",\"type\":\"bytes\"}],\"name\":\"expectRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"expectRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"min\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"max\",\"type\":\"uint64\"}],\"name\":\"expectSafeMemory\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"min\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"max\",\"type\":\"uint64\"}],\"name\":\"expectSafeMemoryCall\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newBasefee\",\"type\":\"uint256\"}],\"name\":\"fee\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"commandInput\",\"type\":\"string[]\"}],\"name\":\"ffi\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"result\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"version\",\"type\":\"string\"}],\"name\":\"foundryVersionAtLeast\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"version\",\"type\":\"string\"}],\"name\":\"foundryVersionCmp\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"fsMetadata\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"isDir\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"isSymlink\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"length\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"readOnly\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"modified\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"accessed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"created\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.FsMetadata\",\"name\":\"metadata\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"code\",\"type\":\"bytes\"}],\"name\":\"getArtifactPathByCode\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"deployedCode\",\"type\":\"bytes\"}],\"name\":\"getArtifactPathByDeployedCode\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getBlobBaseFee\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"blobBaseFee\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getBlobhashes\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"hashes\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getBlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"height\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getBlockTimestamp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timestamp\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"contractName\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"chainId\",\"type\":\"uint64\"},{\"internalType\":\"enum VmSafe.BroadcastTxType\",\"name\":\"txType\",\"type\":\"uint8\"}],\"name\":\"getBroadcast\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"enum VmSafe.BroadcastTxType\",\"name\":\"txType\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"contractAddress\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"blockNumber\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.BroadcastTxSummary\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"contractName\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"chainId\",\"type\":\"uint64\"}],\"name\":\"getBroadcasts\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"enum VmSafe.BroadcastTxType\",\"name\":\"txType\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"contractAddress\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"blockNumber\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.BroadcastTxSummary[]\",\"name\":\"\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"contractName\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"chainId\",\"type\":\"uint64\"},{\"internalType\":\"enum VmSafe.BroadcastTxType\",\"name\":\"txType\",\"type\":\"uint8\"}],\"name\":\"getBroadcasts\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"enum VmSafe.BroadcastTxType\",\"name\":\"txType\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"contractAddress\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"blockNumber\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.BroadcastTxSummary[]\",\"name\":\"\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"chainAlias\",\"type\":\"string\"}],\"name\":\"getChain\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"chainId\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"chainAlias\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"rpcUrl\",\"type\":\"string\"}],\"internalType\":\"struct VmSafe.Chain\",\"name\":\"chain\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"chainId\",\"type\":\"uint256\"}],\"name\":\"getChain\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"chainId\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"chainAlias\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"rpcUrl\",\"type\":\"string\"}],\"internalType\":\"struct VmSafe.Chain\",\"name\":\"chain\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getChainId\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"blockChainId\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"}],\"name\":\"getCode\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"creationBytecode\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"}],\"name\":\"getDeployedCode\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"runtimeBytecode\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"contractName\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"chainId\",\"type\":\"uint64\"}],\"name\":\"getDeployment\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"contractName\",\"type\":\"string\"}],\"name\":\"getDeployment\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"contractName\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"chainId\",\"type\":\"uint64\"}],\"name\":\"getDeployments\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"deployedAddresses\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFoundryVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"version\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getLabel\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"currentLabel\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"elementSlot\",\"type\":\"bytes32\"}],\"name\":\"getMappingKeyAndParentOf\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"found\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"key\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"parent\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"mappingSlot\",\"type\":\"bytes32\"}],\"name\":\"getMappingLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"length\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"mappingSlot\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"idx\",\"type\":\"uint256\"}],\"name\":\"getMappingSlotAt\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"value\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.Wallet\",\"name\":\"wallet\",\"type\":\"tuple\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"}],\"name\":\"getRawBlockHeader\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"rlpHeader\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRecordedLogs\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"emitter\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.Log[]\",\"name\":\"logs\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getStateDiff\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"diff\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getStateDiffJson\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"diff\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getStorageAccesses\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"slot\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"isWrite\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"previousValue\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"newValue\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"reverted\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.StorageAccess[]\",\"name\":\"storageAccesses\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getWallets\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"wallets\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"indexOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"interceptInitcode\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"enum VmSafe.ForgeContext\",\"name\":\"context\",\"type\":\"uint8\"}],\"name\":\"isContext\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"isDir\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"isFile\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"isPersistent\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"persistent\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"keyExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"keyExistsJson\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"keyExistsToml\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"newLabel\",\"type\":\"string\"}],\"name\":\"label\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastCallGas\",\"outputs\":[{\"components\":[{\"internalType\":\"uint64\",\"name\":\"gasLimit\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"gasTotalUsed\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"gasMemoryUsed\",\"type\":\"uint64\"},{\"internalType\":\"int64\",\"name\":\"gasRefunded\",\"type\":\"int64\"},{\"internalType\":\"uint64\",\"name\":\"gasRemaining\",\"type\":\"uint64\"}],\"internalType\":\"struct VmSafe.Gas\",\"name\":\"gas\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"slot\",\"type\":\"bytes32\"}],\"name\":\"load\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"data\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"pathToAllocsJson\",\"type\":\"string\"}],\"name\":\"loadAllocs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"accounts\",\"type\":\"address[]\"}],\"name\":\"makePersistent\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account0\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"account1\",\"type\":\"address\"}],\"name\":\"makePersistent\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"makePersistent\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account0\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"account1\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"account2\",\"type\":\"address\"}],\"name\":\"makePersistent\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"bytes4\",\"name\":\"data\",\"type\":\"bytes4\"},{\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"mockCall\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"msgValue\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"mockCall\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"mockCall\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"msgValue\",\"type\":\"uint256\"},{\"internalType\":\"bytes4\",\"name\":\"data\",\"type\":\"bytes4\"},{\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"mockCall\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"bytes4\",\"name\":\"data\",\"type\":\"bytes4\"},{\"internalType\":\"bytes\",\"name\":\"revertData\",\"type\":\"bytes\"}],\"name\":\"mockCallRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"msgValue\",\"type\":\"uint256\"},{\"internalType\":\"bytes4\",\"name\":\"data\",\"type\":\"bytes4\"},{\"internalType\":\"bytes\",\"name\":\"revertData\",\"type\":\"bytes\"}],\"name\":\"mockCallRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"msgValue\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"revertData\",\"type\":\"bytes\"}],\"name\":\"mockCallRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"revertData\",\"type\":\"bytes\"}],\"name\":\"mockCallRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"msgValue\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bytes[]\",\"name\":\"returnData\",\"type\":\"bytes[]\"}],\"name\":\"mockCalls\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bytes[]\",\"name\":\"returnData\",\"type\":\"bytes[]\"}],\"name\":\"mockCalls\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"callee\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"mockFunction\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"noAccessList\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"name\":\"parseAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"parsedValue\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"name\":\"parseBool\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"parsedValue\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"name\":\"parseBytes\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"parsedValue\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"name\":\"parseBytes32\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"parsedValue\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"name\":\"parseInt\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"parsedValue\",\"type\":\"int256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"name\":\"parseJson\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"abiEncodedData\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJson\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"abiEncodedData\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonAddressArray\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonBool\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonBoolArray\",\"outputs\":[{\"internalType\":\"bool[]\",\"name\":\"\",\"type\":\"bool[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonBytes\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonBytes32\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonBytes32Array\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonBytesArray\",\"outputs\":[{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonInt\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonIntArray\",\"outputs\":[{\"internalType\":\"int256[]\",\"name\":\"\",\"type\":\"int256[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonKeys\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"keys\",\"type\":\"string[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonStringArray\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"\",\"type\":\"string[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"}],\"name\":\"parseJsonType\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"}],\"name\":\"parseJsonType\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"}],\"name\":\"parseJsonTypeArray\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonUintArray\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseToml\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"abiEncodedData\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"}],\"name\":\"parseToml\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"abiEncodedData\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlAddressArray\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlBool\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlBoolArray\",\"outputs\":[{\"internalType\":\"bool[]\",\"name\":\"\",\"type\":\"bool[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlBytes\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlBytes32\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlBytes32Array\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlBytesArray\",\"outputs\":[{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlInt\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlIntArray\",\"outputs\":[{\"internalType\":\"int256[]\",\"name\":\"\",\"type\":\"int256[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlKeys\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"keys\",\"type\":\"string[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlStringArray\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"\",\"type\":\"string[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"}],\"name\":\"parseTomlType\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"}],\"name\":\"parseTomlType\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"}],\"name\":\"parseTomlTypeArray\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlUintArray\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"name\":\"parseUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"parsedValue\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pauseGasMetering\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pauseTracing\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"msgSender\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"txOrigin\",\"type\":\"address\"}],\"name\":\"prank\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"msgSender\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"txOrigin\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"delegateCall\",\"type\":\"bool\"}],\"name\":\"prank\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"msgSender\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"delegateCall\",\"type\":\"bool\"}],\"name\":\"prank\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"msgSender\",\"type\":\"address\"}],\"name\":\"prank\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"newPrevrandao\",\"type\":\"bytes32\"}],\"name\":\"prevrandao\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newPrevrandao\",\"type\":\"uint256\"}],\"name\":\"prevrandao\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"projectRoot\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"promptText\",\"type\":\"string\"}],\"name\":\"prompt\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"promptText\",\"type\":\"string\"}],\"name\":\"promptAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"promptText\",\"type\":\"string\"}],\"name\":\"promptSecret\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"promptText\",\"type\":\"string\"}],\"name\":\"promptSecretUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"promptText\",\"type\":\"string\"}],\"name\":\"promptUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"publicKeyP256\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"randomAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"randomBool\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"len\",\"type\":\"uint256\"}],\"name\":\"randomBytes\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"randomBytes4\",\"outputs\":[{\"internalType\":\"bytes4\",\"name\":\"\",\"type\":\"bytes4\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"randomBytes8\",\"outputs\":[{\"internalType\":\"bytes8\",\"name\":\"\",\"type\":\"bytes8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"randomInt\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"bits\",\"type\":\"uint256\"}],\"name\":\"randomInt\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"randomUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"bits\",\"type\":\"uint256\"}],\"name\":\"randomUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"min\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"max\",\"type\":\"uint256\"}],\"name\":\"randomUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"readCallers\",\"outputs\":[{\"internalType\":\"enum VmSafe.CallerMode\",\"name\":\"callerMode\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"msgSender\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"txOrigin\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"maxDepth\",\"type\":\"uint64\"}],\"name\":\"readDir\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"errorMessage\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"depth\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"isDir\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"isSymlink\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.DirEntry[]\",\"name\":\"entries\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"maxDepth\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"followLinks\",\"type\":\"bool\"}],\"name\":\"readDir\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"errorMessage\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"depth\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"isDir\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"isSymlink\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.DirEntry[]\",\"name\":\"entries\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"readDir\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"errorMessage\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"depth\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"isDir\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"isSymlink\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.DirEntry[]\",\"name\":\"entries\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"readFile\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"data\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"readFileBinary\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"readLine\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"line\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"linkPath\",\"type\":\"string\"}],\"name\":\"readLink\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"targetPath\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"record\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recordLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"rememberKey\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"keyAddr\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"mnemonic\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"derivationPath\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"count\",\"type\":\"uint32\"}],\"name\":\"rememberKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"keyAddrs\",\"type\":\"address[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"mnemonic\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"derivationPath\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"language\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"count\",\"type\":\"uint32\"}],\"name\":\"rememberKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"keyAddrs\",\"type\":\"address[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"bool\",\"name\":\"recursive\",\"type\":\"bool\"}],\"name\":\"removeDir\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"removeFile\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"from\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"to\",\"type\":\"string\"}],\"name\":\"replace\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"output\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"resetGasMetering\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"resetNonce\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"}],\"name\":\"resolveEnv\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"resumeGasMetering\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"resumeTracing\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"snapshotId\",\"type\":\"uint256\"}],\"name\":\"revertTo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"snapshotId\",\"type\":\"uint256\"}],\"name\":\"revertToAndDelete\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"snapshotId\",\"type\":\"uint256\"}],\"name\":\"revertToState\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"snapshotId\",\"type\":\"uint256\"}],\"name\":\"revertToStateAndDelete\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"accounts\",\"type\":\"address[]\"}],\"name\":\"revokePersistent\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"revokePersistent\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newHeight\",\"type\":\"uint256\"}],\"name\":\"roll\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"}],\"name\":\"rollFork\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"}],\"name\":\"rollFork\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"}],\"name\":\"rollFork\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"}],\"name\":\"rollFork\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"urlOrAlias\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"method\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"params\",\"type\":\"string\"}],\"name\":\"rpc\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"method\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"params\",\"type\":\"string\"}],\"name\":\"rpc\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"rpcAlias\",\"type\":\"string\"}],\"name\":\"rpcUrl\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"rpcUrlStructs\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"url\",\"type\":\"string\"}],\"internalType\":\"struct VmSafe.Rpc[]\",\"name\":\"urls\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"rpcUrls\",\"outputs\":[{\"internalType\":\"string[2][]\",\"name\":\"urls\",\"type\":\"string[2][]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"}],\"name\":\"selectFork\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"address[]\",\"name\":\"values\",\"type\":\"address[]\"}],\"name\":\"serializeAddress\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"address\",\"name\":\"value\",\"type\":\"address\"}],\"name\":\"serializeAddress\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"bool[]\",\"name\":\"values\",\"type\":\"bool[]\"}],\"name\":\"serializeBool\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"name\":\"serializeBool\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"}],\"name\":\"serializeBytes\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"value\",\"type\":\"bytes\"}],\"name\":\"serializeBytes\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"bytes32[]\",\"name\":\"values\",\"type\":\"bytes32[]\"}],\"name\":\"serializeBytes32\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"value\",\"type\":\"bytes32\"}],\"name\":\"serializeBytes32\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"int256\",\"name\":\"value\",\"type\":\"int256\"}],\"name\":\"serializeInt\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"int256[]\",\"name\":\"values\",\"type\":\"int256[]\"}],\"name\":\"serializeInt\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"value\",\"type\":\"string\"}],\"name\":\"serializeJson\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"value\",\"type\":\"bytes\"}],\"name\":\"serializeJsonType\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"value\",\"type\":\"bytes\"}],\"name\":\"serializeJsonType\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"values\",\"type\":\"string[]\"}],\"name\":\"serializeString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"value\",\"type\":\"string\"}],\"name\":\"serializeString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"serializeUint\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"uint256[]\",\"name\":\"values\",\"type\":\"uint256[]\"}],\"name\":\"serializeUint\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"serializeUintToHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"overwrite\",\"type\":\"bool\"}],\"name\":\"setArbitraryStorage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"setArbitraryStorage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"}],\"name\":\"setBlockhash\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"value\",\"type\":\"string\"}],\"name\":\"setEnv\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"newNonce\",\"type\":\"uint64\"}],\"name\":\"setNonce\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"newNonce\",\"type\":\"uint64\"}],\"name\":\"setNonceUnsafe\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"}],\"name\":\"setSeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"array\",\"type\":\"uint256[]\"}],\"name\":\"shuffle\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"sign\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"signer\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"sign\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.Wallet\",\"name\":\"wallet\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"sign\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"sign\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"signAndAttachDelegation\",\"outputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"}],\"name\":\"signAndAttachDelegation\",\"outputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"crossChain\",\"type\":\"bool\"}],\"name\":\"signAndAttachDelegation\",\"outputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.Wallet\",\"name\":\"wallet\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"signCompact\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"vs\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"signer\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"signCompact\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"vs\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"signCompact\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"vs\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"signCompact\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"vs\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"signDelegation\",\"outputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"crossChain\",\"type\":\"bool\"}],\"name\":\"signDelegation\",\"outputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"}],\"name\":\"signDelegation\",\"outputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"signP256\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"skipTest\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\"}],\"name\":\"skip\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"skipTest\",\"type\":\"bool\"}],\"name\":\"skip\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"duration\",\"type\":\"uint256\"}],\"name\":\"sleep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"snapshot\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"snapshotId\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"group\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"snapshotGasLastCall\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"snapshotGasLastCall\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"snapshotState\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"snapshotId\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"snapshotValue\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"group\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"snapshotValue\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"array\",\"type\":\"uint256[]\"}],\"name\":\"sort\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delimiter\",\"type\":\"string\"}],\"name\":\"split\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"outputs\",\"type\":\"string[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"startBroadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"signer\",\"type\":\"address\"}],\"name\":\"startBroadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"startBroadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"startDebugTraceRecording\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"startMappingRecording\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"msgSender\",\"type\":\"address\"}],\"name\":\"startPrank\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"msgSender\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"delegateCall\",\"type\":\"bool\"}],\"name\":\"startPrank\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"msgSender\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"txOrigin\",\"type\":\"address\"}],\"name\":\"startPrank\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"msgSender\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"txOrigin\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"delegateCall\",\"type\":\"bool\"}],\"name\":\"startPrank\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"startSnapshotGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"group\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"startSnapshotGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"startStateDiffRecording\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopAndReturnDebugTraceRecording\",\"outputs\":[{\"components\":[{\"internalType\":\"uint256[]\",\"name\":\"stack\",\"type\":\"uint256[]\"},{\"internalType\":\"bytes\",\"name\":\"memoryInput\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"opcode\",\"type\":\"uint8\"},{\"internalType\":\"uint64\",\"name\":\"depth\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"isOutOfGas\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"contractAddr\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.DebugStep[]\",\"name\":\"step\",\"type\":\"tuple[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopAndReturnStateDiff\",\"outputs\":[{\"components\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"chainId\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.ChainInfo\",\"name\":\"chainInfo\",\"type\":\"tuple\"},{\"internalType\":\"enum VmSafe.AccountAccessKind\",\"name\":\"kind\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"accessor\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"initialized\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"deployedCode\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bool\",\"name\":\"reverted\",\"type\":\"bool\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"slot\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"isWrite\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"previousValue\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"newValue\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"reverted\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.StorageAccess[]\",\"name\":\"storageAccesses\",\"type\":\"tuple[]\"},{\"internalType\":\"uint64\",\"name\":\"depth\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"oldNonce\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"newNonce\",\"type\":\"uint64\"}],\"internalType\":\"struct VmSafe.AccountAccess[]\",\"name\":\"accountAccesses\",\"type\":\"tuple[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopBroadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopExpectSafeMemory\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopMappingRecording\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopPrank\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopRecord\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"group\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"stopSnapshotGas\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"stopSnapshotGas\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopSnapshotGas\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"slot\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"value\",\"type\":\"bytes32\"}],\"name\":\"store\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"data\",\"type\":\"string\"}],\"name\":\"toBase64\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"toBase64\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"data\",\"type\":\"string\"}],\"name\":\"toBase64URL\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"toBase64URL\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"}],\"name\":\"toLowercase\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"output\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"value\",\"type\":\"address\"}],\"name\":\"toString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"toString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"value\",\"type\":\"bytes\"}],\"name\":\"toString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"name\":\"toString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"value\",\"type\":\"int256\"}],\"name\":\"toString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"value\",\"type\":\"bytes32\"}],\"name\":\"toString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"}],\"name\":\"toUppercase\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"output\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"}],\"name\":\"transact\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"}],\"name\":\"transact\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"}],\"name\":\"trim\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"output\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"commandInput\",\"type\":\"string[]\"}],\"name\":\"tryFfi\",\"outputs\":[{\"components\":[{\"internalType\":\"int32\",\"name\":\"exitCode\",\"type\":\"int32\"},{\"internalType\":\"bytes\",\"name\":\"stdout\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"stderr\",\"type\":\"bytes\"}],\"internalType\":\"struct VmSafe.FfiResult\",\"name\":\"result\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newGasPrice\",\"type\":\"uint256\"}],\"name\":\"txGasPrice\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unixTime\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"milliseconds\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"slot\",\"type\":\"bytes32\"}],\"name\":\"warmSlot\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newTimestamp\",\"type\":\"uint256\"}],\"name\":\"warp\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"data\",\"type\":\"string\"}],\"name\":\"writeFile\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"writeFileBinary\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"}],\"name\":\"writeJson\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"writeJson\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"data\",\"type\":\"string\"}],\"name\":\"writeLine\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"}],\"name\":\"writeToml\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"writeToml\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"accessList((address,bytes32[])[])\":{\"notice\":\"Utility cheatcode to set an EIP-2930 access list for all subsequent transactions.\"},\"accesses(address)\":{\"notice\":\"Gets all accessed reads and write slot from a `vm.record` session, for a given address.\"},\"activeFork()\":{\"notice\":\"Returns the identifier of the currently active fork. Reverts if no fork is currently active.\"},\"addr(uint256)\":{\"notice\":\"Gets the address for a given private key.\"},\"allowCheatcodes(address)\":{\"notice\":\"In forking mode, explicitly grant the given address cheatcode access.\"},\"assertApproxEqAbs(int256,int256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`.\"},\"assertApproxEqAbs(int256,int256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. Includes error message into revert string on failure.\"},\"assertApproxEqAbs(uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`.\"},\"assertApproxEqAbs(uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. Includes error message into revert string on failure.\"},\"assertApproxEqAbsDecimal(int256,int256,uint256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message.\"},\"assertApproxEqAbsDecimal(int256,int256,uint256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertApproxEqAbsDecimal(uint256,uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message.\"},\"assertApproxEqAbsDecimal(uint256,uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertApproxEqRel(int256,int256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100%\"},\"assertApproxEqRel(int256,int256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Includes error message into revert string on failure.\"},\"assertApproxEqRel(uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100%\"},\"assertApproxEqRel(uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Includes error message into revert string on failure.\"},\"assertApproxEqRelDecimal(int256,int256,uint256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message.\"},\"assertApproxEqRelDecimal(int256,int256,uint256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertApproxEqRelDecimal(uint256,uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message.\"},\"assertApproxEqRelDecimal(uint256,uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertEq(address,address)\":{\"notice\":\"Asserts that two `address` values are equal.\"},\"assertEq(address,address,string)\":{\"notice\":\"Asserts that two `address` values are equal and includes error message into revert string on failure.\"},\"assertEq(address[],address[])\":{\"notice\":\"Asserts that two arrays of `address` values are equal.\"},\"assertEq(address[],address[],string)\":{\"notice\":\"Asserts that two arrays of `address` values are equal and includes error message into revert string on failure.\"},\"assertEq(bool,bool)\":{\"notice\":\"Asserts that two `bool` values are equal.\"},\"assertEq(bool,bool,string)\":{\"notice\":\"Asserts that two `bool` values are equal and includes error message into revert string on failure.\"},\"assertEq(bool[],bool[])\":{\"notice\":\"Asserts that two arrays of `bool` values are equal.\"},\"assertEq(bool[],bool[],string)\":{\"notice\":\"Asserts that two arrays of `bool` values are equal and includes error message into revert string on failure.\"},\"assertEq(bytes,bytes)\":{\"notice\":\"Asserts that two `bytes` values are equal.\"},\"assertEq(bytes,bytes,string)\":{\"notice\":\"Asserts that two `bytes` values are equal and includes error message into revert string on failure.\"},\"assertEq(bytes32,bytes32)\":{\"notice\":\"Asserts that two `bytes32` values are equal.\"},\"assertEq(bytes32,bytes32,string)\":{\"notice\":\"Asserts that two `bytes32` values are equal and includes error message into revert string on failure.\"},\"assertEq(bytes32[],bytes32[])\":{\"notice\":\"Asserts that two arrays of `bytes32` values are equal.\"},\"assertEq(bytes32[],bytes32[],string)\":{\"notice\":\"Asserts that two arrays of `bytes32` values are equal and includes error message into revert string on failure.\"},\"assertEq(bytes[],bytes[])\":{\"notice\":\"Asserts that two arrays of `bytes` values are equal.\"},\"assertEq(bytes[],bytes[],string)\":{\"notice\":\"Asserts that two arrays of `bytes` values are equal and includes error message into revert string on failure.\"},\"assertEq(int256,int256)\":{\"notice\":\"Asserts that two `int256` values are equal.\"},\"assertEq(int256,int256,string)\":{\"notice\":\"Asserts that two `int256` values are equal and includes error message into revert string on failure.\"},\"assertEq(int256[],int256[])\":{\"notice\":\"Asserts that two arrays of `int256` values are equal.\"},\"assertEq(int256[],int256[],string)\":{\"notice\":\"Asserts that two arrays of `int256` values are equal and includes error message into revert string on failure.\"},\"assertEq(string,string)\":{\"notice\":\"Asserts that two `string` values are equal.\"},\"assertEq(string,string,string)\":{\"notice\":\"Asserts that two `string` values are equal and includes error message into revert string on failure.\"},\"assertEq(string[],string[])\":{\"notice\":\"Asserts that two arrays of `string` values are equal.\"},\"assertEq(string[],string[],string)\":{\"notice\":\"Asserts that two arrays of `string` values are equal and includes error message into revert string on failure.\"},\"assertEq(uint256,uint256)\":{\"notice\":\"Asserts that two `uint256` values are equal.\"},\"assertEq(uint256,uint256,string)\":{\"notice\":\"Asserts that two `uint256` values are equal and includes error message into revert string on failure.\"},\"assertEq(uint256[],uint256[])\":{\"notice\":\"Asserts that two arrays of `uint256 values are equal.\"},\"assertEq(uint256[],uint256[],string)\":{\"notice\":\"Asserts that two arrays of `uint256` values are equal and includes error message into revert string on failure.\"},\"assertEqDecimal(int256,int256,uint256)\":{\"notice\":\"Asserts that two `int256` values are equal, formatting them with decimals in failure message.\"},\"assertEqDecimal(int256,int256,uint256,string)\":{\"notice\":\"Asserts that two `int256` values are equal, formatting them with decimals in failure message. Includes error message into revert string on failure.\"},\"assertEqDecimal(uint256,uint256,uint256)\":{\"notice\":\"Asserts that two `uint256` values are equal, formatting them with decimals in failure message.\"},\"assertEqDecimal(uint256,uint256,uint256,string)\":{\"notice\":\"Asserts that two `uint256` values are equal, formatting them with decimals in failure message. Includes error message into revert string on failure.\"},\"assertFalse(bool)\":{\"notice\":\"Asserts that the given condition is false.\"},\"assertFalse(bool,string)\":{\"notice\":\"Asserts that the given condition is false and includes error message into revert string on failure.\"},\"assertGe(int256,int256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than or equal to second.\"},\"assertGe(int256,int256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than or equal to second. Includes error message into revert string on failure.\"},\"assertGe(uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than or equal to second.\"},\"assertGe(uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than or equal to second. Includes error message into revert string on failure.\"},\"assertGeDecimal(int256,int256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message.\"},\"assertGeDecimal(int256,int256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertGeDecimal(uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message.\"},\"assertGeDecimal(uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertGt(int256,int256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than second.\"},\"assertGt(int256,int256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than second. Includes error message into revert string on failure.\"},\"assertGt(uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than second.\"},\"assertGt(uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than second. Includes error message into revert string on failure.\"},\"assertGtDecimal(int256,int256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than second. Formats values with decimals in failure message.\"},\"assertGtDecimal(int256,int256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertGtDecimal(uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than second. Formats values with decimals in failure message.\"},\"assertGtDecimal(uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertLe(int256,int256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than or equal to second.\"},\"assertLe(int256,int256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than or equal to second. Includes error message into revert string on failure.\"},\"assertLe(uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than or equal to second.\"},\"assertLe(uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than or equal to second. Includes error message into revert string on failure.\"},\"assertLeDecimal(int256,int256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message.\"},\"assertLeDecimal(int256,int256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertLeDecimal(uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message.\"},\"assertLeDecimal(uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertLt(int256,int256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than second.\"},\"assertLt(int256,int256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than second. Includes error message into revert string on failure.\"},\"assertLt(uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than second.\"},\"assertLt(uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than second. Includes error message into revert string on failure.\"},\"assertLtDecimal(int256,int256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than second. Formats values with decimals in failure message.\"},\"assertLtDecimal(int256,int256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertLtDecimal(uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than second. Formats values with decimals in failure message.\"},\"assertLtDecimal(uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertNotEq(address,address)\":{\"notice\":\"Asserts that two `address` values are not equal.\"},\"assertNotEq(address,address,string)\":{\"notice\":\"Asserts that two `address` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(address[],address[])\":{\"notice\":\"Asserts that two arrays of `address` values are not equal.\"},\"assertNotEq(address[],address[],string)\":{\"notice\":\"Asserts that two arrays of `address` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(bool,bool)\":{\"notice\":\"Asserts that two `bool` values are not equal.\"},\"assertNotEq(bool,bool,string)\":{\"notice\":\"Asserts that two `bool` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(bool[],bool[])\":{\"notice\":\"Asserts that two arrays of `bool` values are not equal.\"},\"assertNotEq(bool[],bool[],string)\":{\"notice\":\"Asserts that two arrays of `bool` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(bytes,bytes)\":{\"notice\":\"Asserts that two `bytes` values are not equal.\"},\"assertNotEq(bytes,bytes,string)\":{\"notice\":\"Asserts that two `bytes` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(bytes32,bytes32)\":{\"notice\":\"Asserts that two `bytes32` values are not equal.\"},\"assertNotEq(bytes32,bytes32,string)\":{\"notice\":\"Asserts that two `bytes32` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(bytes32[],bytes32[])\":{\"notice\":\"Asserts that two arrays of `bytes32` values are not equal.\"},\"assertNotEq(bytes32[],bytes32[],string)\":{\"notice\":\"Asserts that two arrays of `bytes32` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(bytes[],bytes[])\":{\"notice\":\"Asserts that two arrays of `bytes` values are not equal.\"},\"assertNotEq(bytes[],bytes[],string)\":{\"notice\":\"Asserts that two arrays of `bytes` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(int256,int256)\":{\"notice\":\"Asserts that two `int256` values are not equal.\"},\"assertNotEq(int256,int256,string)\":{\"notice\":\"Asserts that two `int256` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(int256[],int256[])\":{\"notice\":\"Asserts that two arrays of `int256` values are not equal.\"},\"assertNotEq(int256[],int256[],string)\":{\"notice\":\"Asserts that two arrays of `int256` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(string,string)\":{\"notice\":\"Asserts that two `string` values are not equal.\"},\"assertNotEq(string,string,string)\":{\"notice\":\"Asserts that two `string` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(string[],string[])\":{\"notice\":\"Asserts that two arrays of `string` values are not equal.\"},\"assertNotEq(string[],string[],string)\":{\"notice\":\"Asserts that two arrays of `string` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(uint256,uint256)\":{\"notice\":\"Asserts that two `uint256` values are not equal.\"},\"assertNotEq(uint256,uint256,string)\":{\"notice\":\"Asserts that two `uint256` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(uint256[],uint256[])\":{\"notice\":\"Asserts that two arrays of `uint256` values are not equal.\"},\"assertNotEq(uint256[],uint256[],string)\":{\"notice\":\"Asserts that two arrays of `uint256` values are not equal and includes error message into revert string on failure.\"},\"assertNotEqDecimal(int256,int256,uint256)\":{\"notice\":\"Asserts that two `int256` values are not equal, formatting them with decimals in failure message.\"},\"assertNotEqDecimal(int256,int256,uint256,string)\":{\"notice\":\"Asserts that two `int256` values are not equal, formatting them with decimals in failure message. Includes error message into revert string on failure.\"},\"assertNotEqDecimal(uint256,uint256,uint256)\":{\"notice\":\"Asserts that two `uint256` values are not equal, formatting them with decimals in failure message.\"},\"assertNotEqDecimal(uint256,uint256,uint256,string)\":{\"notice\":\"Asserts that two `uint256` values are not equal, formatting them with decimals in failure message. Includes error message into revert string on failure.\"},\"assertTrue(bool)\":{\"notice\":\"Asserts that the given condition is true.\"},\"assertTrue(bool,string)\":{\"notice\":\"Asserts that the given condition is true and includes error message into revert string on failure.\"},\"assume(bool)\":{\"notice\":\"If the condition is false, discard this run's fuzz inputs and generate new ones.\"},\"assumeNoRevert((address,bool,bytes))\":{\"notice\":\"Discard this run's fuzz inputs and generate new ones if next call reverts with the potential revert parameters.\"},\"assumeNoRevert((address,bool,bytes)[])\":{\"notice\":\"Discard this run's fuzz inputs and generate new ones if next call reverts with the any of the potential revert parameters.\"},\"assumeNoRevert()\":{\"notice\":\"Discard this run's fuzz inputs and generate new ones if next call reverted.\"},\"attachBlob(bytes)\":{\"notice\":\"Attach an EIP-4844 blob to the next call\"},\"attachDelegation((uint8,bytes32,bytes32,uint64,address))\":{\"notice\":\"Designate the next call as an EIP-7702 transaction\"},\"attachDelegation((uint8,bytes32,bytes32,uint64,address),bool)\":{\"notice\":\"Designate the next call as an EIP-7702 transaction, with optional cross-chain validity.\"},\"blobBaseFee(uint256)\":{\"notice\":\"Sets `block.blobbasefee`\"},\"blobhashes(bytes32[])\":{\"notice\":\"Sets the blobhashes in the transaction. Not available on EVM versions before Cancun. If used on unsupported EVM versions it will revert.\"},\"bound(int256,int256,int256)\":{\"notice\":\"Returns an int256 value bounded in given range and different from the current one.\"},\"bound(uint256,uint256,uint256)\":{\"notice\":\"Returns an uint256 value bounded in given range and different from the current one.\"},\"breakpoint(string)\":{\"notice\":\"Writes a breakpoint to jump to in the debugger.\"},\"breakpoint(string,bool)\":{\"notice\":\"Writes a conditional breakpoint to jump to in the debugger.\"},\"broadcast()\":{\"notice\":\"Has the next call (at this call depth only) create transactions that can later be signed and sent onchain. Broadcasting address is determined by checking the following in order: 1. If `--sender` argument was provided, that address is used. 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used.\"},\"broadcast(address)\":{\"notice\":\"Has the next call (at this call depth only) create a transaction with the address provided as the sender that can later be signed and sent onchain.\"},\"broadcast(uint256)\":{\"notice\":\"Has the next call (at this call depth only) create a transaction with the private key provided as the sender that can later be signed and sent onchain.\"},\"broadcastRawTransaction(bytes)\":{\"notice\":\"Takes a signed transaction and broadcasts it to the network.\"},\"chainId(uint256)\":{\"notice\":\"Sets `block.chainid`.\"},\"clearMockedCalls()\":{\"notice\":\"Clears all mocked calls.\"},\"cloneAccount(address,address)\":{\"notice\":\"Clones a source account code, state, balance and nonce to a target account and updates in-memory EVM state.\"},\"closeFile(string)\":{\"notice\":\"Closes file for reading, resetting the offset and allowing to read it from beginning with readLine. `path` is relative to the project root.\"},\"coinbase(address)\":{\"notice\":\"Sets `block.coinbase`.\"},\"computeCreate2Address(bytes32,bytes32)\":{\"notice\":\"Compute the address of a contract created with CREATE2 using the default CREATE2 deployer.\"},\"computeCreate2Address(bytes32,bytes32,address)\":{\"notice\":\"Compute the address of a contract created with CREATE2 using the given CREATE2 deployer.\"},\"computeCreateAddress(address,uint256)\":{\"notice\":\"Compute the address a contract will be deployed at for a given deployer address and nonce.\"},\"contains(string,string)\":{\"notice\":\"Returns true if `search` is found in `subject`, false otherwise.\"},\"cool(address)\":{\"notice\":\"Marks the slots of an account and the account address as cold.\"},\"coolSlot(address,bytes32)\":{\"notice\":\"Utility cheatcode to mark specific storage slot as cold, simulating no prior read.\"},\"copyFile(string,string)\":{\"notice\":\"Copies the contents of one file to another. This function will **overwrite** the contents of `to`. On success, the total number of bytes copied is returned and it is equal to the length of the `to` file as reported by `metadata`. Both `from` and `to` are relative to the project root.\"},\"copyStorage(address,address)\":{\"notice\":\"Utility cheatcode to copy storage of `from` contract to another `to` contract.\"},\"createDir(string,bool)\":{\"notice\":\"Creates a new, empty directory at the provided path. This cheatcode will revert in the following situations, but is not limited to just these cases: - User lacks permissions to modify `path`. - A parent of the given path doesn't exist and `recursive` is false. - `path` already exists and `recursive` is false. `path` is relative to the project root.\"},\"createFork(string)\":{\"notice\":\"Creates a new fork with the given endpoint and the _latest_ block and returns the identifier of the fork.\"},\"createFork(string,bytes32)\":{\"notice\":\"Creates a new fork with the given endpoint and at the block the given transaction was mined in, replays all transaction mined in the block before the transaction, and returns the identifier of the fork.\"},\"createFork(string,uint256)\":{\"notice\":\"Creates a new fork with the given endpoint and block and returns the identifier of the fork.\"},\"createSelectFork(string)\":{\"notice\":\"Creates and also selects a new fork with the given endpoint and the latest block and returns the identifier of the fork.\"},\"createSelectFork(string,bytes32)\":{\"notice\":\"Creates and also selects new fork with the given endpoint and at the block the given transaction was mined in, replays all transaction mined in the block before the transaction, returns the identifier of the fork.\"},\"createSelectFork(string,uint256)\":{\"notice\":\"Creates and also selects a new fork with the given endpoint and block and returns the identifier of the fork.\"},\"createWallet(string)\":{\"notice\":\"Derives a private key from the name, labels the account with that name, and returns the wallet.\"},\"createWallet(uint256)\":{\"notice\":\"Generates a wallet from the private key and returns the wallet.\"},\"createWallet(uint256,string)\":{\"notice\":\"Generates a wallet from the private key, labels the account with that name, and returns the wallet.\"},\"deal(address,uint256)\":{\"notice\":\"Sets an address' balance.\"},\"deleteSnapshot(uint256)\":{\"notice\":\"`deleteSnapshot` is being deprecated in favor of `deleteStateSnapshot`. It will be removed in future versions.\"},\"deleteSnapshots()\":{\"notice\":\"`deleteSnapshots` is being deprecated in favor of `deleteStateSnapshots`. It will be removed in future versions.\"},\"deleteStateSnapshot(uint256)\":{\"notice\":\"Removes the snapshot with the given ID created by `snapshot`. Takes the snapshot ID to delete. Returns `true` if the snapshot was successfully deleted. Returns `false` if the snapshot does not exist.\"},\"deleteStateSnapshots()\":{\"notice\":\"Removes _all_ snapshots previously created by `snapshot`.\"},\"deployCode(string)\":{\"notice\":\"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional.\"},\"deployCode(string,bytes)\":{\"notice\":\"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments.\"},\"deployCode(string,bytes,bytes32)\":{\"notice\":\"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments.\"},\"deployCode(string,bytes,uint256)\":{\"notice\":\"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments and `msg.value`.\"},\"deployCode(string,bytes,uint256,bytes32)\":{\"notice\":\"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments and `msg.value`.\"},\"deployCode(string,bytes32)\":{\"notice\":\"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional.\"},\"deployCode(string,uint256)\":{\"notice\":\"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts `msg.value`.\"},\"deployCode(string,uint256,bytes32)\":{\"notice\":\"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts `msg.value`.\"},\"deriveKey(string,string,uint32)\":{\"notice\":\"Derive a private key from a provided mnemonic string (or mnemonic file path) at `{derivationPath}{index}`.\"},\"deriveKey(string,string,uint32,string)\":{\"notice\":\"Derive a private key from a provided mnemonic string (or mnemonic file path) in the specified language at `{derivationPath}{index}`.\"},\"deriveKey(string,uint32)\":{\"notice\":\"Derive a private key from a provided mnemonic string (or mnemonic file path) at the derivation path `m/44'/60'/0'/0/{index}`.\"},\"deriveKey(string,uint32,string)\":{\"notice\":\"Derive a private key from a provided mnemonic string (or mnemonic file path) in the specified language at the derivation path `m/44'/60'/0'/0/{index}`.\"},\"difficulty(uint256)\":{\"notice\":\"Sets `block.difficulty`. Not available on EVM versions from Paris onwards. Use `prevrandao` instead. Reverts if used on unsupported EVM versions.\"},\"dumpState(string)\":{\"notice\":\"Dump a genesis JSON file's `allocs` to disk.\"},\"eip712HashStruct(string,bytes)\":{\"notice\":\"Generates the struct hash of the canonical EIP-712 type representation and its abi-encoded data. Supports 2 different inputs: 1. Name of the type (i.e. \\\"PermitSingle\\\"): * requires previous binding generation with `forge bind-json`. * bindings will be retrieved from the path configured in `foundry.toml`. 2. String representation of the type (i.e. \\\"Foo(Bar bar) Bar(uint256 baz)\\\"). * Note: the cheatcode will use the canonical type even if the input is malformated with the wrong order of elements or with extra whitespaces.\"},\"eip712HashStruct(string,string,bytes)\":{\"notice\":\"Generates the struct hash of the canonical EIP-712 type representation and its abi-encoded data. Requires previous binding generation with `forge bind-json`. Params: * `bindingsPath`: path where the output of `forge bind-json` is stored. * `typeName`: Name of the type (i.e. \\\"PermitSingle\\\"). * `abiEncodedData`: ABI-encoded data for the struct that is being hashed.\"},\"eip712HashType(string)\":{\"notice\":\"Generates the hash of the canonical EIP-712 type representation. Supports 2 different inputs: 1. Name of the type (i.e. \\\"Transaction\\\"): * requires previous binding generation with `forge bind-json`. * bindings will be retrieved from the path configured in `foundry.toml`. 2. String representation of the type (i.e. \\\"Foo(Bar bar) Bar(uint256 baz)\\\"). * Note: the cheatcode will output the canonical type even if the input is malformated with the wrong order of elements or with extra whitespaces.\"},\"eip712HashType(string,string)\":{\"notice\":\"Generates the hash of the canonical EIP-712 type representation. Requires previous binding generation with `forge bind-json`. Params: * `bindingsPath`: path where the output of `forge bind-json` is stored. * `typeName`: Name of the type (i.e. \\\"Transaction\\\").\"},\"eip712HashTypedData(string)\":{\"notice\":\"Generates a ready-to-sign digest of human-readable typed data following the EIP-712 standard.\"},\"ensNamehash(string)\":{\"notice\":\"Returns ENS namehash for provided string.\"},\"envAddress(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `address`. Reverts if the variable was not found or could not be parsed.\"},\"envAddress(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"envBool(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `bool`. Reverts if the variable was not found or could not be parsed.\"},\"envBool(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"envBytes(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `bytes`. Reverts if the variable was not found or could not be parsed.\"},\"envBytes(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"envBytes32(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `bytes32`. Reverts if the variable was not found or could not be parsed.\"},\"envBytes32(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"envExists(string)\":{\"notice\":\"Gets the environment variable `name` and returns true if it exists, else returns false.\"},\"envInt(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `int256`. Reverts if the variable was not found or could not be parsed.\"},\"envInt(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"envOr(string,address)\":{\"notice\":\"Gets the environment variable `name` and parses it as `address`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,bool)\":{\"notice\":\"Gets the environment variable `name` and parses it as `bool`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,bytes)\":{\"notice\":\"Gets the environment variable `name` and parses it as `bytes`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,bytes32)\":{\"notice\":\"Gets the environment variable `name` and parses it as `bytes32`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,int256)\":{\"notice\":\"Gets the environment variable `name` and parses it as `int256`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `string`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,address[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,bool[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,bytes32[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,bytes[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,int256[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,string[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,uint256[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,uint256)\":{\"notice\":\"Gets the environment variable `name` and parses it as `uint256`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envString(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `string`. Reverts if the variable was not found or could not be parsed.\"},\"envString(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"envUint(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `uint256`. Reverts if the variable was not found or could not be parsed.\"},\"envUint(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"etch(address,bytes)\":{\"notice\":\"Sets an address' code.\"},\"eth_getLogs(uint256,uint256,address,bytes32[])\":{\"notice\":\"Gets all the logs according to specified filter.\"},\"exists(string)\":{\"notice\":\"Returns true if the given path points to an existing entity, else returns false.\"},\"expectCall(address,bytes)\":{\"notice\":\"Expects a call to an address with the specified calldata. Calldata can either be a strict or a partial match.\"},\"expectCall(address,bytes,uint64)\":{\"notice\":\"Expects given number of calls to an address with the specified calldata.\"},\"expectCall(address,uint256,bytes)\":{\"notice\":\"Expects a call to an address with the specified `msg.value` and calldata.\"},\"expectCall(address,uint256,bytes,uint64)\":{\"notice\":\"Expects given number of calls to an address with the specified `msg.value` and calldata.\"},\"expectCall(address,uint256,uint64,bytes)\":{\"notice\":\"Expect a call to an address with the specified `msg.value`, gas, and calldata.\"},\"expectCall(address,uint256,uint64,bytes,uint64)\":{\"notice\":\"Expects given number of calls to an address with the specified `msg.value`, gas, and calldata.\"},\"expectCallMinGas(address,uint256,uint64,bytes)\":{\"notice\":\"Expect a call to an address with the specified `msg.value` and calldata, and a *minimum* amount of gas.\"},\"expectCallMinGas(address,uint256,uint64,bytes,uint64)\":{\"notice\":\"Expect given number of calls to an address with the specified `msg.value` and calldata, and a *minimum* amount of gas.\"},\"expectCreate(bytes,address)\":{\"notice\":\"Expects the deployment of the specified bytecode by the specified address using the CREATE opcode\"},\"expectCreate2(bytes,address)\":{\"notice\":\"Expects the deployment of the specified bytecode by the specified address using the CREATE2 opcode\"},\"expectEmit()\":{\"notice\":\"Prepare an expected log with all topic and data checks enabled. Call this function, then emit an event, then call a function. Internally after the call, we check if logs were emitted in the expected order with the expected topics and data.\"},\"expectEmit(address)\":{\"notice\":\"Same as the previous method, but also checks supplied address against emitting contract.\"},\"expectEmit(address,uint64)\":{\"notice\":\"Expect a given number of logs from a specific emitter with all topic and data checks enabled.\"},\"expectEmit(bool,bool,bool,bool)\":{\"notice\":\"Prepare an expected log with (bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData.). Call this function, then emit an event, then call a function. Internally after the call, we check if logs were emitted in the expected order with the expected topics and data (as specified by the booleans).\"},\"expectEmit(bool,bool,bool,bool,address)\":{\"notice\":\"Same as the previous method, but also checks supplied address against emitting contract.\"},\"expectEmit(bool,bool,bool,bool,address,uint64)\":{\"notice\":\"Expect a given number of logs from a specific emitter with the provided topics.\"},\"expectEmit(bool,bool,bool,bool,uint64)\":{\"notice\":\"Expect a given number of logs with the provided topics.\"},\"expectEmit(uint64)\":{\"notice\":\"Expect a given number of logs with all topic and data checks enabled.\"},\"expectEmitAnonymous()\":{\"notice\":\"Prepare an expected anonymous log with all topic and data checks enabled. Call this function, then emit an anonymous event, then call a function. Internally after the call, we check if logs were emitted in the expected order with the expected topics and data.\"},\"expectEmitAnonymous(address)\":{\"notice\":\"Same as the previous method, but also checks supplied address against emitting contract.\"},\"expectEmitAnonymous(bool,bool,bool,bool,bool)\":{\"notice\":\"Prepare an expected anonymous log with (bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData.). Call this function, then emit an anonymous event, then call a function. Internally after the call, we check if logs were emitted in the expected order with the expected topics and data (as specified by the booleans).\"},\"expectEmitAnonymous(bool,bool,bool,bool,bool,address)\":{\"notice\":\"Same as the previous method, but also checks supplied address against emitting contract.\"},\"expectPartialRevert(bytes4)\":{\"notice\":\"Expects an error on next call that starts with the revert data.\"},\"expectPartialRevert(bytes4,address)\":{\"notice\":\"Expects an error on next call to reverter address, that starts with the revert data.\"},\"expectRevert()\":{\"notice\":\"Expects an error on next call with any revert data.\"},\"expectRevert(address)\":{\"notice\":\"Expects an error with any revert data on next call to reverter address.\"},\"expectRevert(address,uint64)\":{\"notice\":\"Expects a `count` number of reverts from the upcoming calls from the reverter address.\"},\"expectRevert(bytes)\":{\"notice\":\"Expects an error on next call that exactly matches the revert data.\"},\"expectRevert(bytes,address)\":{\"notice\":\"Expects an error from reverter address on next call, that exactly matches the revert data.\"},\"expectRevert(bytes,address,uint64)\":{\"notice\":\"Expects a `count` number of reverts from the upcoming calls from the reverter address that exactly match the revert data.\"},\"expectRevert(bytes,uint64)\":{\"notice\":\"Expects a `count` number of reverts from the upcoming calls that exactly match the revert data.\"},\"expectRevert(bytes4)\":{\"notice\":\"Expects an error on next call that exactly matches the revert data.\"},\"expectRevert(bytes4,address)\":{\"notice\":\"Expects an error from reverter address on next call, with any revert data.\"},\"expectRevert(bytes4,address,uint64)\":{\"notice\":\"Expects a `count` number of reverts from the upcoming calls from the reverter address that match the revert data.\"},\"expectRevert(bytes4,uint64)\":{\"notice\":\"Expects a `count` number of reverts from the upcoming calls that match the revert data.\"},\"expectRevert(uint64)\":{\"notice\":\"Expects a `count` number of reverts from the upcoming calls with any revert data or reverter.\"},\"expectSafeMemory(uint64,uint64)\":{\"notice\":\"Only allows memory writes to offsets [0x00, 0x60) \\u222a [min, max) in the current subcontext. If any other memory is written to, the test will fail. Can be called multiple times to add more ranges to the set.\"},\"expectSafeMemoryCall(uint64,uint64)\":{\"notice\":\"Only allows memory writes to offsets [0x00, 0x60) \\u222a [min, max) in the next created subcontext. If any other memory is written to, the test will fail. Can be called multiple times to add more ranges to the set.\"},\"fee(uint256)\":{\"notice\":\"Sets `block.basefee`.\"},\"ffi(string[])\":{\"notice\":\"Performs a foreign function call via the terminal.\"},\"foundryVersionAtLeast(string)\":{\"notice\":\"Returns true if the current Foundry version is greater than or equal to the given version. The given version string must be in the format `major.minor.patch`. This is equivalent to `foundryVersionCmp(version) >= 0`.\"},\"foundryVersionCmp(string)\":{\"notice\":\"Compares the current Foundry version with the given version string. The given version string must be in the format `major.minor.patch`. Returns: -1 if current Foundry version is less than the given version 0 if current Foundry version equals the given version 1 if current Foundry version is greater than the given version This result can then be used with a comparison operator against `0`. For example, to check if the current Foundry version is greater than or equal to `1.0.0`: `if (foundryVersionCmp(\\\"1.0.0\\\") >= 0) { ... }`\"},\"fsMetadata(string)\":{\"notice\":\"Given a path, query the file system to get information about a file, directory, etc.\"},\"getArtifactPathByCode(bytes)\":{\"notice\":\"Gets the artifact path from code (aka. creation code).\"},\"getArtifactPathByDeployedCode(bytes)\":{\"notice\":\"Gets the artifact path from deployed code (aka. runtime code).\"},\"getBlobBaseFee()\":{\"notice\":\"Gets the current `block.blobbasefee`. You should use this instead of `block.blobbasefee` if you use `vm.blobBaseFee`, as `block.blobbasefee` is assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180\"},\"getBlobhashes()\":{\"notice\":\"Gets the blockhashes from the current transaction. Not available on EVM versions before Cancun. If used on unsupported EVM versions it will revert.\"},\"getBlockNumber()\":{\"notice\":\"Gets the current `block.number`. You should use this instead of `block.number` if you use `vm.roll`, as `block.number` is assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180\"},\"getBlockTimestamp()\":{\"notice\":\"Gets the current `block.timestamp`. You should use this instead of `block.timestamp` if you use `vm.warp`, as `block.timestamp` is assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180\"},\"getBroadcast(string,uint64,uint8)\":{\"notice\":\"Returns the most recent broadcast for the given contract on `chainId` matching `txType`. For example: The most recent deployment can be fetched by passing `txType` as `CREATE` or `CREATE2`. The most recent call can be fetched by passing `txType` as `CALL`.\"},\"getBroadcasts(string,uint64)\":{\"notice\":\"Returns all broadcasts for the given contract on `chainId`. Sorted such that the most recent broadcast is the first element, and the oldest is the last. i.e descending order of BroadcastTxSummary.blockNumber.\"},\"getBroadcasts(string,uint64,uint8)\":{\"notice\":\"Returns all broadcasts for the given contract on `chainId` with the specified `txType`. Sorted such that the most recent broadcast is the first element, and the oldest is the last. i.e descending order of BroadcastTxSummary.blockNumber.\"},\"getChain(string)\":{\"notice\":\"Returns a Chain struct for specific alias\"},\"getChain(uint256)\":{\"notice\":\"Returns a Chain struct for specific chainId\"},\"getChainId()\":{\"notice\":\"Gets the current `block.chainid` of the currently selected environment. You should use this instead of `block.chainid` if you use `vm.selectFork` or `vm.createSelectFork`, as `block.chainid` could be assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180\"},\"getCode(string)\":{\"notice\":\"Gets the creation bytecode from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional.\"},\"getDeployedCode(string)\":{\"notice\":\"Gets the deployed bytecode from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional.\"},\"getDeployment(string)\":{\"notice\":\"Returns the most recent deployment for the current `chainId`.\"},\"getDeployment(string,uint64)\":{\"notice\":\"Returns the most recent deployment for the given contract on `chainId`\"},\"getDeployments(string,uint64)\":{\"notice\":\"Returns all deployments for the given contract on `chainId` Sorted in descending order of deployment time i.e descending order of BroadcastTxSummary.blockNumber. The most recent deployment is the first element, and the oldest is the last.\"},\"getFoundryVersion()\":{\"notice\":\"Returns the Foundry version. Format: -+.. Sample output: 0.3.0-nightly+3cb96bde9b.1737036656.debug Note: Build timestamps may vary slightly across platforms due to separate CI jobs. For reliable version comparisons, use UNIX format (e.g., >= 1700000000) to compare timestamps while ignoring minor time differences.\"},\"getLabel(address)\":{\"notice\":\"Gets the label for the specified address.\"},\"getMappingKeyAndParentOf(address,bytes32)\":{\"notice\":\"Gets the map key and parent of a mapping at a given slot, for a given address.\"},\"getMappingLength(address,bytes32)\":{\"notice\":\"Gets the number of elements in the mapping at the given slot, for a given address.\"},\"getMappingSlotAt(address,bytes32,uint256)\":{\"notice\":\"Gets the elements at index idx of the mapping at the given slot, for a given address. The index must be less than the length of the mapping (i.e. the number of keys in the mapping).\"},\"getNonce((address,uint256,uint256,uint256))\":{\"notice\":\"Get the nonce of a `Wallet`.\"},\"getNonce(address)\":{\"notice\":\"Gets the nonce of an account.\"},\"getRawBlockHeader(uint256)\":{\"notice\":\"Gets the RLP encoded block header for a given block number. Returns the block header in the same format as `cast block --raw`.\"},\"getRecordedLogs()\":{\"notice\":\"Gets all the recorded logs.\"},\"getStateDiff()\":{\"notice\":\"Returns state diffs from current `vm.startStateDiffRecording` session.\"},\"getStateDiffJson()\":{\"notice\":\"Returns state diffs from current `vm.startStateDiffRecording` session, in json format.\"},\"getStorageAccesses()\":{\"notice\":\"Returns an array of `StorageAccess` from current `vm.stateStateDiffRecording` session\"},\"getWallets()\":{\"notice\":\"Returns addresses of available unlocked wallets in the script environment.\"},\"indexOf(string,string)\":{\"notice\":\"Returns the index of the first occurrence of a `key` in an `input` string. Returns `NOT_FOUND` (i.e. `type(uint256).max`) if the `key` is not found. Returns 0 in case of an empty `key`.\"},\"interceptInitcode()\":{\"notice\":\"Causes the next contract creation (via new) to fail and return its initcode in the returndata buffer. This allows type-safe access to the initcode payload that would be used for contract creation. Example usage: vm.interceptInitcode(); bytes memory initcode; try new MyContract(param1, param2) { assert(false); } catch (bytes memory interceptedInitcode) { initcode = interceptedInitcode; }\"},\"isContext(uint8)\":{\"notice\":\"Returns true if `forge` command was executed in given context.\"},\"isDir(string)\":{\"notice\":\"Returns true if the path exists on disk and is pointing at a directory, else returns false.\"},\"isFile(string)\":{\"notice\":\"Returns true if the path exists on disk and is pointing at a regular file, else returns false.\"},\"isPersistent(address)\":{\"notice\":\"Returns true if the account is marked as persistent.\"},\"keyExists(string,string)\":{\"notice\":\"Checks if `key` exists in a JSON object `keyExists` is being deprecated in favor of `keyExistsJson`. It will be removed in future versions.\"},\"keyExistsJson(string,string)\":{\"notice\":\"Checks if `key` exists in a JSON object.\"},\"keyExistsToml(string,string)\":{\"notice\":\"Checks if `key` exists in a TOML table.\"},\"label(address,string)\":{\"notice\":\"Labels an address in call traces.\"},\"lastCallGas()\":{\"notice\":\"Gets the gas used in the last call from the callee perspective.\"},\"load(address,bytes32)\":{\"notice\":\"Loads a storage slot from an address.\"},\"loadAllocs(string)\":{\"notice\":\"Load a genesis JSON file's `allocs` into the in-memory EVM state.\"},\"makePersistent(address)\":{\"notice\":\"Marks that the account(s) should use persistent storage across fork swaps in a multifork setup Meaning, changes made to the state of this account will be kept when switching forks.\"},\"makePersistent(address,address)\":{\"notice\":\"See `makePersistent(address)`.\"},\"makePersistent(address,address,address)\":{\"notice\":\"See `makePersistent(address)`.\"},\"makePersistent(address[])\":{\"notice\":\"See `makePersistent(address)`.\"},\"mockCall(address,bytes,bytes)\":{\"notice\":\"Mocks a call to an address, returning specified data. Calldata can either be strict or a partial match, e.g. if you only pass a Solidity selector to the expected calldata, then the entire Solidity function will be mocked.\"},\"mockCall(address,bytes4,bytes)\":{\"notice\":\"Mocks a call to an address, returning specified data. Calldata can either be strict or a partial match, e.g. if you only pass a Solidity selector to the expected calldata, then the entire Solidity function will be mocked. Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`.\"},\"mockCall(address,uint256,bytes,bytes)\":{\"notice\":\"Mocks a call to an address with a specific `msg.value`, returning specified data. Calldata match takes precedence over `msg.value` in case of ambiguity.\"},\"mockCall(address,uint256,bytes4,bytes)\":{\"notice\":\"Mocks a call to an address with a specific `msg.value`, returning specified data. Calldata match takes precedence over `msg.value` in case of ambiguity. Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`.\"},\"mockCallRevert(address,bytes,bytes)\":{\"notice\":\"Reverts a call to an address with specified revert data.\"},\"mockCallRevert(address,bytes4,bytes)\":{\"notice\":\"Reverts a call to an address with specified revert data. Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`.\"},\"mockCallRevert(address,uint256,bytes,bytes)\":{\"notice\":\"Reverts a call to an address with a specific `msg.value`, with specified revert data.\"},\"mockCallRevert(address,uint256,bytes4,bytes)\":{\"notice\":\"Reverts a call to an address with a specific `msg.value`, with specified revert data. Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`.\"},\"mockCalls(address,bytes,bytes[])\":{\"notice\":\"Mocks multiple calls to an address, returning specified data for each call.\"},\"mockCalls(address,uint256,bytes,bytes[])\":{\"notice\":\"Mocks multiple calls to an address with a specific `msg.value`, returning specified data for each call.\"},\"mockFunction(address,address,bytes)\":{\"notice\":\"Whenever a call is made to `callee` with calldata `data`, this cheatcode instead calls `target` with the same calldata. This functionality is similar to a delegate call made to `target` contract from `callee`. Can be used to substitute a call to a function with another implementation that captures the primary logic of the original function but is easier to reason about. If calldata is not a strict match then partial match by selector is attempted.\"},\"noAccessList()\":{\"notice\":\"Utility cheatcode to remove any EIP-2930 access list set by `accessList` cheatcode.\"},\"parseAddress(string)\":{\"notice\":\"Parses the given `string` into an `address`.\"},\"parseBool(string)\":{\"notice\":\"Parses the given `string` into a `bool`.\"},\"parseBytes(string)\":{\"notice\":\"Parses the given `string` into `bytes`.\"},\"parseBytes32(string)\":{\"notice\":\"Parses the given `string` into a `bytes32`.\"},\"parseInt(string)\":{\"notice\":\"Parses the given `string` into a `int256`.\"},\"parseJson(string)\":{\"notice\":\"ABI-encodes a JSON object.\"},\"parseJson(string,string)\":{\"notice\":\"ABI-encodes a JSON object at `key`.\"},\"parseJsonAddress(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `address`.\"},\"parseJsonAddressArray(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `address[]`.\"},\"parseJsonBool(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `bool`.\"},\"parseJsonBoolArray(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `bool[]`.\"},\"parseJsonBytes(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `bytes`.\"},\"parseJsonBytes32(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `bytes32`.\"},\"parseJsonBytes32Array(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `bytes32[]`.\"},\"parseJsonBytesArray(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `bytes[]`.\"},\"parseJsonInt(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `int256`.\"},\"parseJsonIntArray(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `int256[]`.\"},\"parseJsonKeys(string,string)\":{\"notice\":\"Returns an array of all the keys in a JSON object.\"},\"parseJsonString(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `string`.\"},\"parseJsonStringArray(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `string[]`.\"},\"parseJsonType(string,string)\":{\"notice\":\"Parses a string of JSON data and coerces it to type corresponding to `typeDescription`.\"},\"parseJsonType(string,string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to type corresponding to `typeDescription`.\"},\"parseJsonTypeArray(string,string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to type array corresponding to `typeDescription`.\"},\"parseJsonUint(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `uint256`.\"},\"parseJsonUintArray(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `uint256[]`.\"},\"parseToml(string)\":{\"notice\":\"ABI-encodes a TOML table.\"},\"parseToml(string,string)\":{\"notice\":\"ABI-encodes a TOML table at `key`.\"},\"parseTomlAddress(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `address`.\"},\"parseTomlAddressArray(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `address[]`.\"},\"parseTomlBool(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `bool`.\"},\"parseTomlBoolArray(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `bool[]`.\"},\"parseTomlBytes(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `bytes`.\"},\"parseTomlBytes32(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `bytes32`.\"},\"parseTomlBytes32Array(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `bytes32[]`.\"},\"parseTomlBytesArray(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `bytes[]`.\"},\"parseTomlInt(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `int256`.\"},\"parseTomlIntArray(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `int256[]`.\"},\"parseTomlKeys(string,string)\":{\"notice\":\"Returns an array of all the keys in a TOML table.\"},\"parseTomlString(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `string`.\"},\"parseTomlStringArray(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `string[]`.\"},\"parseTomlType(string,string)\":{\"notice\":\"Parses a string of TOML data and coerces it to type corresponding to `typeDescription`.\"},\"parseTomlType(string,string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to type corresponding to `typeDescription`.\"},\"parseTomlTypeArray(string,string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to type array corresponding to `typeDescription`.\"},\"parseTomlUint(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `uint256`.\"},\"parseTomlUintArray(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `uint256[]`.\"},\"parseUint(string)\":{\"notice\":\"Parses the given `string` into a `uint256`.\"},\"pauseGasMetering()\":{\"notice\":\"Pauses gas metering (i.e. gas usage is not counted). Noop if already paused.\"},\"pauseTracing()\":{\"notice\":\"Pauses collection of call traces. Useful in cases when you want to skip tracing of complex calls which are not useful for debugging.\"},\"prank(address)\":{\"notice\":\"Sets the *next* call's `msg.sender` to be the input address.\"},\"prank(address,address)\":{\"notice\":\"Sets the *next* call's `msg.sender` to be the input address, and the `tx.origin` to be the second input.\"},\"prank(address,address,bool)\":{\"notice\":\"Sets the *next* delegate call's `msg.sender` to be the input address, and the `tx.origin` to be the second input.\"},\"prank(address,bool)\":{\"notice\":\"Sets the *next* delegate call's `msg.sender` to be the input address.\"},\"prevrandao(bytes32)\":{\"notice\":\"Sets `block.prevrandao`. Not available on EVM versions before Paris. Use `difficulty` instead. If used on unsupported EVM versions it will revert.\"},\"prevrandao(uint256)\":{\"notice\":\"Sets `block.prevrandao`. Not available on EVM versions before Paris. Use `difficulty` instead. If used on unsupported EVM versions it will revert.\"},\"projectRoot()\":{\"notice\":\"Get the path of the current project root.\"},\"prompt(string)\":{\"notice\":\"Prompts the user for a string value in the terminal.\"},\"promptAddress(string)\":{\"notice\":\"Prompts the user for an address in the terminal.\"},\"promptSecret(string)\":{\"notice\":\"Prompts the user for a hidden string value in the terminal.\"},\"promptSecretUint(string)\":{\"notice\":\"Prompts the user for hidden uint256 in the terminal (usually pk).\"},\"promptUint(string)\":{\"notice\":\"Prompts the user for uint256 in the terminal.\"},\"publicKeyP256(uint256)\":{\"notice\":\"Derives secp256r1 public key from the provided `privateKey`.\"},\"randomAddress()\":{\"notice\":\"Returns a random `address`.\"},\"randomBool()\":{\"notice\":\"Returns a random `bool`.\"},\"randomBytes(uint256)\":{\"notice\":\"Returns a random byte array value of the given length.\"},\"randomBytes4()\":{\"notice\":\"Returns a random fixed-size byte array of length 4.\"},\"randomBytes8()\":{\"notice\":\"Returns a random fixed-size byte array of length 8.\"},\"randomInt()\":{\"notice\":\"Returns a random `int256` value.\"},\"randomInt(uint256)\":{\"notice\":\"Returns a random `int256` value of given bits.\"},\"randomUint()\":{\"notice\":\"Returns a random uint256 value.\"},\"randomUint(uint256)\":{\"notice\":\"Returns a random `uint256` value of given bits.\"},\"randomUint(uint256,uint256)\":{\"notice\":\"Returns random uint256 value between the provided range (=min..=max).\"},\"readCallers()\":{\"notice\":\"Reads the current `msg.sender` and `tx.origin` from state and reports if there is any active caller modification.\"},\"readDir(string)\":{\"notice\":\"Reads the directory at the given path recursively, up to `maxDepth`. `maxDepth` defaults to 1, meaning only the direct children of the given directory will be returned. Follows symbolic links if `followLinks` is true.\"},\"readDir(string,uint64)\":{\"notice\":\"See `readDir(string)`.\"},\"readDir(string,uint64,bool)\":{\"notice\":\"See `readDir(string)`.\"},\"readFile(string)\":{\"notice\":\"Reads the entire content of file to string. `path` is relative to the project root.\"},\"readFileBinary(string)\":{\"notice\":\"Reads the entire content of file as binary. `path` is relative to the project root.\"},\"readLine(string)\":{\"notice\":\"Reads next line of file to string.\"},\"readLink(string)\":{\"notice\":\"Reads a symbolic link, returning the path that the link points to. This cheatcode will revert in the following situations, but is not limited to just these cases: - `path` is not a symbolic link. - `path` does not exist.\"},\"record()\":{\"notice\":\"Records all storage reads and writes. Use `accesses` to get the recorded data. Subsequent calls to `record` will clear the previous data.\"},\"recordLogs()\":{\"notice\":\"Record all the transaction logs.\"},\"rememberKey(uint256)\":{\"notice\":\"Adds a private key to the local forge wallet and returns the address.\"},\"rememberKeys(string,string,string,uint32)\":{\"notice\":\"Derive a set number of wallets from a mnemonic in the specified language at the derivation path `m/44'/60'/0'/0/{0..count}`. The respective private keys are saved to the local forge wallet for later use and their addresses are returned.\"},\"rememberKeys(string,string,uint32)\":{\"notice\":\"Derive a set number of wallets from a mnemonic at the derivation path `m/44'/60'/0'/0/{0..count}`. The respective private keys are saved to the local forge wallet for later use and their addresses are returned.\"},\"removeDir(string,bool)\":{\"notice\":\"Removes a directory at the provided path. This cheatcode will revert in the following situations, but is not limited to just these cases: - `path` doesn't exist. - `path` isn't a directory. - User lacks permissions to modify `path`. - The directory is not empty and `recursive` is false. `path` is relative to the project root.\"},\"removeFile(string)\":{\"notice\":\"Removes a file from the filesystem. This cheatcode will revert in the following situations, but is not limited to just these cases: - `path` points to a directory. - The file doesn't exist. - The user lacks permissions to remove the file. `path` is relative to the project root.\"},\"replace(string,string,string)\":{\"notice\":\"Replaces occurrences of `from` in the given `string` with `to`.\"},\"resetGasMetering()\":{\"notice\":\"Reset gas metering (i.e. gas usage is set to gas limit).\"},\"resetNonce(address)\":{\"notice\":\"Resets the nonce of an account to 0 for EOAs and 1 for contract accounts.\"},\"resolveEnv(string)\":{\"notice\":\"Resolves the env variable placeholders of a given input string.\"},\"resumeGasMetering()\":{\"notice\":\"Resumes gas metering (i.e. gas usage is counted again). Noop if already on.\"},\"resumeTracing()\":{\"notice\":\"Unpauses collection of call traces.\"},\"revertTo(uint256)\":{\"notice\":\"`revertTo` is being deprecated in favor of `revertToState`. It will be removed in future versions.\"},\"revertToAndDelete(uint256)\":{\"notice\":\"`revertToAndDelete` is being deprecated in favor of `revertToStateAndDelete`. It will be removed in future versions.\"},\"revertToState(uint256)\":{\"notice\":\"Revert the state of the EVM to a previous snapshot Takes the snapshot ID to revert to. Returns `true` if the snapshot was successfully reverted. Returns `false` if the snapshot does not exist. **Note:** This does not automatically delete the snapshot. To delete the snapshot use `deleteStateSnapshot`.\"},\"revertToStateAndDelete(uint256)\":{\"notice\":\"Revert the state of the EVM to a previous snapshot and automatically deletes the snapshots Takes the snapshot ID to revert to. Returns `true` if the snapshot was successfully reverted and deleted. Returns `false` if the snapshot does not exist.\"},\"revokePersistent(address)\":{\"notice\":\"Revokes persistent status from the address, previously added via `makePersistent`.\"},\"revokePersistent(address[])\":{\"notice\":\"See `revokePersistent(address)`.\"},\"roll(uint256)\":{\"notice\":\"Sets `block.height`.\"},\"rollFork(bytes32)\":{\"notice\":\"Updates the currently active fork to given transaction. This will `rollFork` with the number of the block the transaction was mined in and replays all transaction mined before it in the block.\"},\"rollFork(uint256)\":{\"notice\":\"Updates the currently active fork to given block number This is similar to `roll` but for the currently active fork.\"},\"rollFork(uint256,bytes32)\":{\"notice\":\"Updates the given fork to block number of the given transaction and replays all transaction mined before it in the block.\"},\"rollFork(uint256,uint256)\":{\"notice\":\"Updates the given fork to given block number.\"},\"rpc(string,string)\":{\"notice\":\"Performs an Ethereum JSON-RPC request to the current fork URL.\"},\"rpc(string,string,string)\":{\"notice\":\"Performs an Ethereum JSON-RPC request to the given endpoint.\"},\"rpcUrl(string)\":{\"notice\":\"Returns the RPC url for the given alias.\"},\"rpcUrlStructs()\":{\"notice\":\"Returns all rpc urls and their aliases as structs.\"},\"rpcUrls()\":{\"notice\":\"Returns all rpc urls and their aliases `[alias, url][]`.\"},\"selectFork(uint256)\":{\"notice\":\"Takes a fork identifier created by `createFork` and sets the corresponding forked state as active.\"},\"serializeAddress(string,string,address)\":{\"notice\":\"See `serializeJson`.\"},\"serializeAddress(string,string,address[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeBool(string,string,bool)\":{\"notice\":\"See `serializeJson`.\"},\"serializeBool(string,string,bool[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeBytes(string,string,bytes)\":{\"notice\":\"See `serializeJson`.\"},\"serializeBytes(string,string,bytes[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeBytes32(string,string,bytes32)\":{\"notice\":\"See `serializeJson`.\"},\"serializeBytes32(string,string,bytes32[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeInt(string,string,int256)\":{\"notice\":\"See `serializeJson`.\"},\"serializeInt(string,string,int256[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeJson(string,string)\":{\"notice\":\"Serializes a key and value to a JSON object stored in-memory that can be later written to a file. Returns the stringified version of the specific JSON file up to that moment.\"},\"serializeJsonType(string,bytes)\":{\"notice\":\"See `serializeJson`.\"},\"serializeJsonType(string,string,string,bytes)\":{\"notice\":\"See `serializeJson`.\"},\"serializeString(string,string,string)\":{\"notice\":\"See `serializeJson`.\"},\"serializeString(string,string,string[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeUint(string,string,uint256)\":{\"notice\":\"See `serializeJson`.\"},\"serializeUint(string,string,uint256[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeUintToHex(string,string,uint256)\":{\"notice\":\"See `serializeJson`.\"},\"setArbitraryStorage(address)\":{\"notice\":\"Utility cheatcode to set arbitrary storage for given target address.\"},\"setArbitraryStorage(address,bool)\":{\"notice\":\"Utility cheatcode to set arbitrary storage for given target address and overwrite any storage slots that have been previously set.\"},\"setBlockhash(uint256,bytes32)\":{\"notice\":\"Set blockhash for the current block. It only sets the blockhash for blocks where `block.number - 256 <= number < block.number`.\"},\"setEnv(string,string)\":{\"notice\":\"Sets environment variables.\"},\"setNonce(address,uint64)\":{\"notice\":\"Sets the nonce of an account. Must be higher than the current nonce of the account.\"},\"setNonceUnsafe(address,uint64)\":{\"notice\":\"Sets the nonce of an account to an arbitrary value.\"},\"setSeed(uint256)\":{\"notice\":\"Set RNG seed.\"},\"shuffle(uint256[])\":{\"notice\":\"Randomly shuffles an array.\"},\"sign((address,uint256,uint256,uint256),bytes32)\":{\"notice\":\"Signs data with a `Wallet`.\"},\"sign(address,bytes32)\":{\"notice\":\"Signs `digest` with signer provided to script using the secp256k1 curve. Raises error if none of the signers passed into the script have provided address.\"},\"sign(bytes32)\":{\"notice\":\"Signs `digest` with signer provided to script using the secp256k1 curve. If `--sender` is provided, the signer with provided address is used, otherwise, if exactly one signer is provided to the script, that signer is used. Raises error if signer passed through `--sender` does not match any unlocked signers or if `--sender` is not provided and not exactly one signer is passed to the script.\"},\"sign(uint256,bytes32)\":{\"notice\":\"Signs `digest` with `privateKey` using the secp256k1 curve.\"},\"signAndAttachDelegation(address,uint256)\":{\"notice\":\"Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction\"},\"signAndAttachDelegation(address,uint256,bool)\":{\"notice\":\"Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction, with optional cross-chain validity.\"},\"signAndAttachDelegation(address,uint256,uint64)\":{\"notice\":\"Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction for specific nonce\"},\"signCompact((address,uint256,uint256,uint256),bytes32)\":{\"notice\":\"Signs data with a `Wallet`. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes.\"},\"signCompact(address,bytes32)\":{\"notice\":\"Signs `digest` with signer provided to script using the secp256k1 curve. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes. Raises error if none of the signers passed into the script have provided address.\"},\"signCompact(bytes32)\":{\"notice\":\"Signs `digest` with signer provided to script using the secp256k1 curve. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes. If `--sender` is provided, the signer with provided address is used, otherwise, if exactly one signer is provided to the script, that signer is used. Raises error if signer passed through `--sender` does not match any unlocked signers or if `--sender` is not provided and not exactly one signer is passed to the script.\"},\"signCompact(uint256,bytes32)\":{\"notice\":\"Signs `digest` with `privateKey` using the secp256k1 curve. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes.\"},\"signDelegation(address,uint256)\":{\"notice\":\"Sign an EIP-7702 authorization for delegation\"},\"signDelegation(address,uint256,bool)\":{\"notice\":\"Sign an EIP-7702 authorization for delegation, with optional cross-chain validity.\"},\"signDelegation(address,uint256,uint64)\":{\"notice\":\"Sign an EIP-7702 authorization for delegation for specific nonce\"},\"signP256(uint256,bytes32)\":{\"notice\":\"Signs `digest` with `privateKey` using the secp256r1 curve.\"},\"skip(bool)\":{\"notice\":\"Marks a test as skipped. Must be called at the top level of a test.\"},\"skip(bool,string)\":{\"notice\":\"Marks a test as skipped with a reason. Must be called at the top level of a test.\"},\"sleep(uint256)\":{\"notice\":\"Suspends execution of the main thread for `duration` milliseconds.\"},\"snapshot()\":{\"notice\":\"`snapshot` is being deprecated in favor of `snapshotState`. It will be removed in future versions.\"},\"snapshotGasLastCall(string)\":{\"notice\":\"Snapshot capture the gas usage of the last call by name from the callee perspective.\"},\"snapshotGasLastCall(string,string)\":{\"notice\":\"Snapshot capture the gas usage of the last call by name in a group from the callee perspective.\"},\"snapshotState()\":{\"notice\":\"Snapshot the current state of the evm. Returns the ID of the snapshot that was created. To revert a snapshot use `revertToState`.\"},\"snapshotValue(string,string,uint256)\":{\"notice\":\"Snapshot capture an arbitrary numerical value by name in a group.\"},\"snapshotValue(string,uint256)\":{\"notice\":\"Snapshot capture an arbitrary numerical value by name. The group name is derived from the contract name.\"},\"sort(uint256[])\":{\"notice\":\"Sorts an array in ascending order.\"},\"split(string,string)\":{\"notice\":\"Splits the given `string` into an array of strings divided by the `delimiter`.\"},\"startBroadcast()\":{\"notice\":\"Has all subsequent calls (at this call depth only) create transactions that can later be signed and sent onchain. Broadcasting address is determined by checking the following in order: 1. If `--sender` argument was provided, that address is used. 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used.\"},\"startBroadcast(address)\":{\"notice\":\"Has all subsequent calls (at this call depth only) create transactions with the address provided that can later be signed and sent onchain.\"},\"startBroadcast(uint256)\":{\"notice\":\"Has all subsequent calls (at this call depth only) create transactions with the private key provided that can later be signed and sent onchain.\"},\"startDebugTraceRecording()\":{\"notice\":\"Records the debug trace during the run.\"},\"startMappingRecording()\":{\"notice\":\"Starts recording all map SSTOREs for later retrieval.\"},\"startPrank(address)\":{\"notice\":\"Sets all subsequent calls' `msg.sender` to be the input address until `stopPrank` is called.\"},\"startPrank(address,address)\":{\"notice\":\"Sets all subsequent calls' `msg.sender` to be the input address until `stopPrank` is called, and the `tx.origin` to be the second input.\"},\"startPrank(address,address,bool)\":{\"notice\":\"Sets all subsequent delegate calls' `msg.sender` to be the input address until `stopPrank` is called, and the `tx.origin` to be the second input.\"},\"startPrank(address,bool)\":{\"notice\":\"Sets all subsequent delegate calls' `msg.sender` to be the input address until `stopPrank` is called.\"},\"startSnapshotGas(string)\":{\"notice\":\"Start a snapshot capture of the current gas usage by name. The group name is derived from the contract name.\"},\"startSnapshotGas(string,string)\":{\"notice\":\"Start a snapshot capture of the current gas usage by name in a group.\"},\"startStateDiffRecording()\":{\"notice\":\"Record all account accesses as part of CREATE, CALL or SELFDESTRUCT opcodes in order, along with the context of the calls\"},\"stopAndReturnDebugTraceRecording()\":{\"notice\":\"Stop debug trace recording and returns the recorded debug trace.\"},\"stopAndReturnStateDiff()\":{\"notice\":\"Returns an ordered array of all account accesses from a `vm.startStateDiffRecording` session.\"},\"stopBroadcast()\":{\"notice\":\"Stops collecting onchain transactions.\"},\"stopExpectSafeMemory()\":{\"notice\":\"Stops all safe memory expectation in the current subcontext.\"},\"stopMappingRecording()\":{\"notice\":\"Stops recording all map SSTOREs for later retrieval and clears the recorded data.\"},\"stopPrank()\":{\"notice\":\"Resets subsequent calls' `msg.sender` to be `address(this)`.\"},\"stopRecord()\":{\"notice\":\"Stops recording storage reads and writes.\"},\"stopSnapshotGas()\":{\"notice\":\"Stop the snapshot capture of the current gas by latest snapshot name, capturing the gas used since the start.\"},\"stopSnapshotGas(string)\":{\"notice\":\"Stop the snapshot capture of the current gas usage by name, capturing the gas used since the start. The group name is derived from the contract name.\"},\"stopSnapshotGas(string,string)\":{\"notice\":\"Stop the snapshot capture of the current gas usage by name in a group, capturing the gas used since the start.\"},\"store(address,bytes32,bytes32)\":{\"notice\":\"Stores a value to an address' storage slot.\"},\"toBase64(bytes)\":{\"notice\":\"Encodes a `bytes` value to a base64 string.\"},\"toBase64(string)\":{\"notice\":\"Encodes a `string` value to a base64 string.\"},\"toBase64URL(bytes)\":{\"notice\":\"Encodes a `bytes` value to a base64url string.\"},\"toBase64URL(string)\":{\"notice\":\"Encodes a `string` value to a base64url string.\"},\"toLowercase(string)\":{\"notice\":\"Converts the given `string` value to Lowercase.\"},\"toString(address)\":{\"notice\":\"Converts the given value to a `string`.\"},\"toString(bool)\":{\"notice\":\"Converts the given value to a `string`.\"},\"toString(bytes)\":{\"notice\":\"Converts the given value to a `string`.\"},\"toString(bytes32)\":{\"notice\":\"Converts the given value to a `string`.\"},\"toString(int256)\":{\"notice\":\"Converts the given value to a `string`.\"},\"toString(uint256)\":{\"notice\":\"Converts the given value to a `string`.\"},\"toUppercase(string)\":{\"notice\":\"Converts the given `string` value to Uppercase.\"},\"transact(bytes32)\":{\"notice\":\"Fetches the given transaction from the active fork and executes it on the current state.\"},\"transact(uint256,bytes32)\":{\"notice\":\"Fetches the given transaction from the given fork and executes it on the current state.\"},\"trim(string)\":{\"notice\":\"Trims leading and trailing whitespace from the given `string` value.\"},\"tryFfi(string[])\":{\"notice\":\"Performs a foreign function call via terminal and returns the exit code, stdout, and stderr.\"},\"txGasPrice(uint256)\":{\"notice\":\"Sets `tx.gasprice`.\"},\"unixTime()\":{\"notice\":\"Returns the time since unix epoch in milliseconds.\"},\"warmSlot(address,bytes32)\":{\"notice\":\"Utility cheatcode to mark specific storage slot as warm, simulating a prior read.\"},\"warp(uint256)\":{\"notice\":\"Sets `block.timestamp`.\"},\"writeFile(string,string)\":{\"notice\":\"Writes data to file, creating a file if it does not exist, and entirely replacing its contents if it does. `path` is relative to the project root.\"},\"writeFileBinary(string,bytes)\":{\"notice\":\"Writes binary data to a file, creating a file if it does not exist, and entirely replacing its contents if it does. `path` is relative to the project root.\"},\"writeJson(string,string)\":{\"notice\":\"Write a serialized JSON object to a file. If the file exists, it will be overwritten.\"},\"writeJson(string,string,string)\":{\"notice\":\"Write a serialized JSON object to an **existing** JSON file, replacing a value with key = This is useful to replace a specific value of a JSON file, without having to parse the entire thing. This cheatcode will create new keys if they didn't previously exist.\"},\"writeLine(string,string)\":{\"notice\":\"Writes line to file, creating a file if it does not exist. `path` is relative to the project root.\"},\"writeToml(string,string)\":{\"notice\":\"Takes serialized JSON, converts to TOML and write a serialized TOML to a file.\"},\"writeToml(string,string,string)\":{\"notice\":\"Takes serialized JSON, converts to TOML and write a serialized TOML table to an **existing** TOML file, replacing a value with key = This is useful to replace a specific value of a TOML file, without having to parse the entire thing. This cheatcode will create new keys if they didn't previously exist.\"}},\"notice\":\"The `Vm` interface does allow manipulation of the EVM state. These are all intended to be used in tests, but it is not recommended to use these cheats in scripts.\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/Vm.sol\":\"Vm\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"struct VmSafe.AccessListItem[]","name":"access","type":"tuple[]","components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32[]","name":"storageKeys","type":"bytes32[]"}]}],"stateMutability":"nonpayable","type":"function","name":"accessList"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"stateMutability":"view","type":"function","name":"accesses","outputs":[{"internalType":"bytes32[]","name":"readSlots","type":"bytes32[]"},{"internalType":"bytes32[]","name":"writeSlots","type":"bytes32[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"activeFork","outputs":[{"internalType":"uint256","name":"forkId","type":"uint256"}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"pure","type":"function","name":"addr","outputs":[{"internalType":"address","name":"keyAddr","type":"address"}]},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"allowCheatcodes"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbs"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbs"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbs"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbs"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbsDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbsDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbsDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbsDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRel"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRel"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRel"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRel"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRelDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRelDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRelDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRelDecimal"},{"inputs":[{"internalType":"bytes32[]","name":"left","type":"bytes32[]"},{"internalType":"bytes32[]","name":"right","type":"bytes32[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"int256[]","name":"left","type":"int256[]"},{"internalType":"int256[]","name":"right","type":"int256[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"address","name":"left","type":"address"},{"internalType":"address","name":"right","type":"address"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"string","name":"left","type":"string"},{"internalType":"string","name":"right","type":"string"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"address[]","name":"left","type":"address[]"},{"internalType":"address[]","name":"right","type":"address[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"address[]","name":"left","type":"address[]"},{"internalType":"address[]","name":"right","type":"address[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bool","name":"left","type":"bool"},{"internalType":"bool","name":"right","type":"bool"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"address","name":"left","type":"address"},{"internalType":"address","name":"right","type":"address"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"uint256[]","name":"left","type":"uint256[]"},{"internalType":"uint256[]","name":"right","type":"uint256[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bool[]","name":"left","type":"bool[]"},{"internalType":"bool[]","name":"right","type":"bool[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"int256[]","name":"left","type":"int256[]"},{"internalType":"int256[]","name":"right","type":"int256[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes32","name":"left","type":"bytes32"},{"internalType":"bytes32","name":"right","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"uint256[]","name":"left","type":"uint256[]"},{"internalType":"uint256[]","name":"right","type":"uint256[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes","name":"left","type":"bytes"},{"internalType":"bytes","name":"right","type":"bytes"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes32","name":"left","type":"bytes32"},{"internalType":"bytes32","name":"right","type":"bytes32"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"string[]","name":"left","type":"string[]"},{"internalType":"string[]","name":"right","type":"string[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes32[]","name":"left","type":"bytes32[]"},{"internalType":"bytes32[]","name":"right","type":"bytes32[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes","name":"left","type":"bytes"},{"internalType":"bytes","name":"right","type":"bytes"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bool[]","name":"left","type":"bool[]"},{"internalType":"bool[]","name":"right","type":"bool[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes[]","name":"left","type":"bytes[]"},{"internalType":"bytes[]","name":"right","type":"bytes[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"string[]","name":"left","type":"string[]"},{"internalType":"string[]","name":"right","type":"string[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"string","name":"left","type":"string"},{"internalType":"string","name":"right","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes[]","name":"left","type":"bytes[]"},{"internalType":"bytes[]","name":"right","type":"bytes[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bool","name":"left","type":"bool"},{"internalType":"bool","name":"right","type":"bool"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertEqDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertEqDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEqDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEqDecimal"},{"inputs":[{"internalType":"bool","name":"condition","type":"bool"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertFalse"},{"inputs":[{"internalType":"bool","name":"condition","type":"bool"}],"stateMutability":"pure","type":"function","name":"assertFalse"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"}],"stateMutability":"pure","type":"function","name":"assertGe"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGe"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertGe"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGe"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertGeDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGeDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGeDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertGeDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"}],"stateMutability":"pure","type":"function","name":"assertGt"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGt"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertGt"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGt"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGtDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGtDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertGtDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertGtDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLe"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertLe"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"}],"stateMutability":"pure","type":"function","name":"assertLe"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLe"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertLeDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLeDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLeDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertLeDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"}],"stateMutability":"pure","type":"function","name":"assertLt"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLt"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLt"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertLt"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertLtDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLtDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLtDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertLtDecimal"},{"inputs":[{"internalType":"bytes32[]","name":"left","type":"bytes32[]"},{"internalType":"bytes32[]","name":"right","type":"bytes32[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"int256[]","name":"left","type":"int256[]"},{"internalType":"int256[]","name":"right","type":"int256[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bool","name":"left","type":"bool"},{"internalType":"bool","name":"right","type":"bool"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes[]","name":"left","type":"bytes[]"},{"internalType":"bytes[]","name":"right","type":"bytes[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bool","name":"left","type":"bool"},{"internalType":"bool","name":"right","type":"bool"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bool[]","name":"left","type":"bool[]"},{"internalType":"bool[]","name":"right","type":"bool[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes","name":"left","type":"bytes"},{"internalType":"bytes","name":"right","type":"bytes"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"address[]","name":"left","type":"address[]"},{"internalType":"address[]","name":"right","type":"address[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"uint256[]","name":"left","type":"uint256[]"},{"internalType":"uint256[]","name":"right","type":"uint256[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bool[]","name":"left","type":"bool[]"},{"internalType":"bool[]","name":"right","type":"bool[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"string","name":"left","type":"string"},{"internalType":"string","name":"right","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"address[]","name":"left","type":"address[]"},{"internalType":"address[]","name":"right","type":"address[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"string","name":"left","type":"string"},{"internalType":"string","name":"right","type":"string"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"address","name":"left","type":"address"},{"internalType":"address","name":"right","type":"address"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes32","name":"left","type":"bytes32"},{"internalType":"bytes32","name":"right","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes","name":"left","type":"bytes"},{"internalType":"bytes","name":"right","type":"bytes"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"uint256[]","name":"left","type":"uint256[]"},{"internalType":"uint256[]","name":"right","type":"uint256[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"address","name":"left","type":"address"},{"internalType":"address","name":"right","type":"address"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes32","name":"left","type":"bytes32"},{"internalType":"bytes32","name":"right","type":"bytes32"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"string[]","name":"left","type":"string[]"},{"internalType":"string[]","name":"right","type":"string[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes32[]","name":"left","type":"bytes32[]"},{"internalType":"bytes32[]","name":"right","type":"bytes32[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"string[]","name":"left","type":"string[]"},{"internalType":"string[]","name":"right","type":"string[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"int256[]","name":"left","type":"int256[]"},{"internalType":"int256[]","name":"right","type":"int256[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes[]","name":"left","type":"bytes[]"},{"internalType":"bytes[]","name":"right","type":"bytes[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertNotEqDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEqDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertNotEqDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEqDecimal"},{"inputs":[{"internalType":"bool","name":"condition","type":"bool"}],"stateMutability":"pure","type":"function","name":"assertTrue"},{"inputs":[{"internalType":"bool","name":"condition","type":"bool"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertTrue"},{"inputs":[{"internalType":"bool","name":"condition","type":"bool"}],"stateMutability":"pure","type":"function","name":"assume"},{"inputs":[],"stateMutability":"pure","type":"function","name":"assumeNoRevert"},{"inputs":[{"internalType":"struct VmSafe.PotentialRevert[]","name":"potentialReverts","type":"tuple[]","components":[{"internalType":"address","name":"reverter","type":"address"},{"internalType":"bool","name":"partialMatch","type":"bool"},{"internalType":"bytes","name":"revertData","type":"bytes"}]}],"stateMutability":"pure","type":"function","name":"assumeNoRevert"},{"inputs":[{"internalType":"struct VmSafe.PotentialRevert","name":"potentialRevert","type":"tuple","components":[{"internalType":"address","name":"reverter","type":"address"},{"internalType":"bool","name":"partialMatch","type":"bool"},{"internalType":"bytes","name":"revertData","type":"bytes"}]}],"stateMutability":"pure","type":"function","name":"assumeNoRevert"},{"inputs":[{"internalType":"bytes","name":"blob","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"attachBlob"},{"inputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}],"stateMutability":"nonpayable","type":"function","name":"attachDelegation"},{"inputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]},{"internalType":"bool","name":"crossChain","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"attachDelegation"},{"inputs":[{"internalType":"uint256","name":"newBlobBaseFee","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"blobBaseFee"},{"inputs":[{"internalType":"bytes32[]","name":"hashes","type":"bytes32[]"}],"stateMutability":"nonpayable","type":"function","name":"blobhashes"},{"inputs":[{"internalType":"uint256","name":"current","type":"uint256"},{"internalType":"uint256","name":"min","type":"uint256"},{"internalType":"uint256","name":"max","type":"uint256"}],"stateMutability":"view","type":"function","name":"bound","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"int256","name":"current","type":"int256"},{"internalType":"int256","name":"min","type":"int256"},{"internalType":"int256","name":"max","type":"int256"}],"stateMutability":"view","type":"function","name":"bound","outputs":[{"internalType":"int256","name":"","type":"int256"}]},{"inputs":[{"internalType":"string","name":"char","type":"string"}],"stateMutability":"pure","type":"function","name":"breakpoint"},{"inputs":[{"internalType":"string","name":"char","type":"string"},{"internalType":"bool","name":"value","type":"bool"}],"stateMutability":"pure","type":"function","name":"breakpoint"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"broadcast"},{"inputs":[{"internalType":"address","name":"signer","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"broadcast"},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"broadcast"},{"inputs":[{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"broadcastRawTransaction"},{"inputs":[{"internalType":"uint256","name":"newChainId","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"chainId"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"clearMockedCalls"},{"inputs":[{"internalType":"address","name":"source","type":"address"},{"internalType":"address","name":"target","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"cloneAccount"},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"closeFile"},{"inputs":[{"internalType":"address","name":"newCoinbase","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"coinbase"},{"inputs":[{"internalType":"bytes32","name":"salt","type":"bytes32"},{"internalType":"bytes32","name":"initCodeHash","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"computeCreate2Address","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"bytes32","name":"salt","type":"bytes32"},{"internalType":"bytes32","name":"initCodeHash","type":"bytes32"},{"internalType":"address","name":"deployer","type":"address"}],"stateMutability":"pure","type":"function","name":"computeCreate2Address","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"address","name":"deployer","type":"address"},{"internalType":"uint256","name":"nonce","type":"uint256"}],"stateMutability":"pure","type":"function","name":"computeCreateAddress","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"subject","type":"string"},{"internalType":"string","name":"search","type":"string"}],"stateMutability":"pure","type":"function","name":"contains","outputs":[{"internalType":"bool","name":"result","type":"bool"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"cool"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32","name":"slot","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"coolSlot"},{"inputs":[{"internalType":"string","name":"from","type":"string"},{"internalType":"string","name":"to","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"copyFile","outputs":[{"internalType":"uint64","name":"copied","type":"uint64"}]},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"copyStorage"},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"bool","name":"recursive","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"createDir"},{"inputs":[{"internalType":"string","name":"urlOrAlias","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"createFork","outputs":[{"internalType":"uint256","name":"forkId","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"urlOrAlias","type":"string"},{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"createFork","outputs":[{"internalType":"uint256","name":"forkId","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"urlOrAlias","type":"string"},{"internalType":"bytes32","name":"txHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"createFork","outputs":[{"internalType":"uint256","name":"forkId","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"urlOrAlias","type":"string"},{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"createSelectFork","outputs":[{"internalType":"uint256","name":"forkId","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"urlOrAlias","type":"string"},{"internalType":"bytes32","name":"txHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"createSelectFork","outputs":[{"internalType":"uint256","name":"forkId","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"urlOrAlias","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"createSelectFork","outputs":[{"internalType":"uint256","name":"forkId","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"walletLabel","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"createWallet","outputs":[{"internalType":"struct VmSafe.Wallet","name":"wallet","type":"tuple","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"},{"internalType":"uint256","name":"privateKey","type":"uint256"}]}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"createWallet","outputs":[{"internalType":"struct VmSafe.Wallet","name":"wallet","type":"tuple","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"},{"internalType":"uint256","name":"privateKey","type":"uint256"}]}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"string","name":"walletLabel","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"createWallet","outputs":[{"internalType":"struct VmSafe.Wallet","name":"wallet","type":"tuple","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"},{"internalType":"uint256","name":"privateKey","type":"uint256"}]}]},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"newBalance","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deal"},{"inputs":[{"internalType":"uint256","name":"snapshotId","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deleteSnapshot","outputs":[{"internalType":"bool","name":"success","type":"bool"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"deleteSnapshots"},{"inputs":[{"internalType":"uint256","name":"snapshotId","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deleteStateSnapshot","outputs":[{"internalType":"bool","name":"success","type":"bool"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"deleteStateSnapshots"},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes32","name":"salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"bytes","name":"constructorArgs","type":"bytes"},{"internalType":"bytes32","name":"salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"uint256","name":"value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"bytes32","name":"salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"bytes","name":"constructorArgs","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"bytes","name":"constructorArgs","type":"bytes"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes32","name":"salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"bytes","name":"constructorArgs","type":"bytes"},{"internalType":"uint256","name":"value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"mnemonic","type":"string"},{"internalType":"string","name":"derivationPath","type":"string"},{"internalType":"uint32","name":"index","type":"uint32"},{"internalType":"string","name":"language","type":"string"}],"stateMutability":"pure","type":"function","name":"deriveKey","outputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"mnemonic","type":"string"},{"internalType":"uint32","name":"index","type":"uint32"},{"internalType":"string","name":"language","type":"string"}],"stateMutability":"pure","type":"function","name":"deriveKey","outputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"mnemonic","type":"string"},{"internalType":"uint32","name":"index","type":"uint32"}],"stateMutability":"pure","type":"function","name":"deriveKey","outputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"mnemonic","type":"string"},{"internalType":"string","name":"derivationPath","type":"string"},{"internalType":"uint32","name":"index","type":"uint32"}],"stateMutability":"pure","type":"function","name":"deriveKey","outputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}]},{"inputs":[{"internalType":"uint256","name":"newDifficulty","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"difficulty"},{"inputs":[{"internalType":"string","name":"pathToStateJson","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"dumpState"},{"inputs":[{"internalType":"string","name":"bindingsPath","type":"string"},{"internalType":"string","name":"typeName","type":"string"},{"internalType":"bytes","name":"abiEncodedData","type":"bytes"}],"stateMutability":"pure","type":"function","name":"eip712HashStruct","outputs":[{"internalType":"bytes32","name":"typeHash","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"typeNameOrDefinition","type":"string"},{"internalType":"bytes","name":"abiEncodedData","type":"bytes"}],"stateMutability":"pure","type":"function","name":"eip712HashStruct","outputs":[{"internalType":"bytes32","name":"typeHash","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"bindingsPath","type":"string"},{"internalType":"string","name":"typeName","type":"string"}],"stateMutability":"pure","type":"function","name":"eip712HashType","outputs":[{"internalType":"bytes32","name":"typeHash","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"typeNameOrDefinition","type":"string"}],"stateMutability":"pure","type":"function","name":"eip712HashType","outputs":[{"internalType":"bytes32","name":"typeHash","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"jsonData","type":"string"}],"stateMutability":"pure","type":"function","name":"eip712HashTypedData","outputs":[{"internalType":"bytes32","name":"digest","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"pure","type":"function","name":"ensNamehash","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envAddress","outputs":[{"internalType":"address","name":"value","type":"address"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envAddress","outputs":[{"internalType":"address[]","name":"value","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envBool","outputs":[{"internalType":"bool","name":"value","type":"bool"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envBool","outputs":[{"internalType":"bool[]","name":"value","type":"bool[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envBytes","outputs":[{"internalType":"bytes","name":"value","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envBytes","outputs":[{"internalType":"bytes[]","name":"value","type":"bytes[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envBytes32","outputs":[{"internalType":"bytes32[]","name":"value","type":"bytes32[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envBytes32","outputs":[{"internalType":"bytes32","name":"value","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envExists","outputs":[{"internalType":"bool","name":"result","type":"bool"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envInt","outputs":[{"internalType":"int256[]","name":"value","type":"int256[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envInt","outputs":[{"internalType":"int256","name":"value","type":"int256"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"bytes32[]","name":"defaultValue","type":"bytes32[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"bytes32[]","name":"value","type":"bytes32[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"int256[]","name":"defaultValue","type":"int256[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"int256[]","name":"value","type":"int256[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"bool","name":"defaultValue","type":"bool"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"bool","name":"value","type":"bool"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"address","name":"defaultValue","type":"address"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"address","name":"value","type":"address"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"uint256","name":"defaultValue","type":"uint256"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"uint256","name":"value","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"bytes[]","name":"defaultValue","type":"bytes[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"bytes[]","name":"value","type":"bytes[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"uint256[]","name":"defaultValue","type":"uint256[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"uint256[]","name":"value","type":"uint256[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"string[]","name":"defaultValue","type":"string[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"string[]","name":"value","type":"string[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"bytes","name":"defaultValue","type":"bytes"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"bytes","name":"value","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"bytes32","name":"defaultValue","type":"bytes32"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"bytes32","name":"value","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"int256","name":"defaultValue","type":"int256"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"int256","name":"value","type":"int256"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"address[]","name":"defaultValue","type":"address[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"address[]","name":"value","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"defaultValue","type":"string"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"string","name":"value","type":"string"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"bool[]","name":"defaultValue","type":"bool[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"bool[]","name":"value","type":"bool[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envString","outputs":[{"internalType":"string[]","name":"value","type":"string[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envString","outputs":[{"internalType":"string","name":"value","type":"string"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envUint","outputs":[{"internalType":"uint256","name":"value","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envUint","outputs":[{"internalType":"uint256[]","name":"value","type":"uint256[]"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"newRuntimeBytecode","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"etch"},{"inputs":[{"internalType":"uint256","name":"fromBlock","type":"uint256"},{"internalType":"uint256","name":"toBlock","type":"uint256"},{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32[]","name":"topics","type":"bytes32[]"}],"stateMutability":"view","type":"function","name":"eth_getLogs","outputs":[{"internalType":"struct VmSafe.EthGetLogs[]","name":"logs","type":"tuple[]","components":[{"internalType":"address","name":"emitter","type":"address"},{"internalType":"bytes32[]","name":"topics","type":"bytes32[]"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"bytes32","name":"blockHash","type":"bytes32"},{"internalType":"uint64","name":"blockNumber","type":"uint64"},{"internalType":"bytes32","name":"transactionHash","type":"bytes32"},{"internalType":"uint64","name":"transactionIndex","type":"uint64"},{"internalType":"uint256","name":"logIndex","type":"uint256"},{"internalType":"bool","name":"removed","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"exists","outputs":[{"internalType":"bool","name":"result","type":"bool"}]},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"uint256","name":"msgValue","type":"uint256"},{"internalType":"uint64","name":"gas","type":"uint64"},{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"expectCall"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"uint256","name":"msgValue","type":"uint256"},{"internalType":"uint64","name":"gas","type":"uint64"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectCall"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"uint256","name":"msgValue","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectCall"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"expectCall"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectCall"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"uint256","name":"msgValue","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"expectCall"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"uint256","name":"msgValue","type":"uint256"},{"internalType":"uint64","name":"minGas","type":"uint64"},{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"expectCallMinGas"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"uint256","name":"msgValue","type":"uint256"},{"internalType":"uint64","name":"minGas","type":"uint64"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectCallMinGas"},{"inputs":[{"internalType":"bytes","name":"bytecode","type":"bytes"},{"internalType":"address","name":"deployer","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"expectCreate"},{"inputs":[{"internalType":"bytes","name":"bytecode","type":"bytes"},{"internalType":"address","name":"deployer","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"expectCreate2"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"expectEmit"},{"inputs":[{"internalType":"bool","name":"checkTopic1","type":"bool"},{"internalType":"bool","name":"checkTopic2","type":"bool"},{"internalType":"bool","name":"checkTopic3","type":"bool"},{"internalType":"bool","name":"checkData","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"expectEmit"},{"inputs":[{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectEmit"},{"inputs":[{"internalType":"bool","name":"checkTopic1","type":"bool"},{"internalType":"bool","name":"checkTopic2","type":"bool"},{"internalType":"bool","name":"checkTopic3","type":"bool"},{"internalType":"bool","name":"checkData","type":"bool"},{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectEmit"},{"inputs":[{"internalType":"bool","name":"checkTopic1","type":"bool"},{"internalType":"bool","name":"checkTopic2","type":"bool"},{"internalType":"bool","name":"checkTopic3","type":"bool"},{"internalType":"bool","name":"checkData","type":"bool"},{"internalType":"address","name":"emitter","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"expectEmit"},{"inputs":[{"internalType":"address","name":"emitter","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"expectEmit"},{"inputs":[{"internalType":"address","name":"emitter","type":"address"},{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectEmit"},{"inputs":[{"internalType":"bool","name":"checkTopic1","type":"bool"},{"internalType":"bool","name":"checkTopic2","type":"bool"},{"internalType":"bool","name":"checkTopic3","type":"bool"},{"internalType":"bool","name":"checkData","type":"bool"},{"internalType":"address","name":"emitter","type":"address"},{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectEmit"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"expectEmitAnonymous"},{"inputs":[{"internalType":"address","name":"emitter","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"expectEmitAnonymous"},{"inputs":[{"internalType":"bool","name":"checkTopic0","type":"bool"},{"internalType":"bool","name":"checkTopic1","type":"bool"},{"internalType":"bool","name":"checkTopic2","type":"bool"},{"internalType":"bool","name":"checkTopic3","type":"bool"},{"internalType":"bool","name":"checkData","type":"bool"},{"internalType":"address","name":"emitter","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"expectEmitAnonymous"},{"inputs":[{"internalType":"bool","name":"checkTopic0","type":"bool"},{"internalType":"bool","name":"checkTopic1","type":"bool"},{"internalType":"bool","name":"checkTopic2","type":"bool"},{"internalType":"bool","name":"checkTopic3","type":"bool"},{"internalType":"bool","name":"checkData","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"expectEmitAnonymous"},{"inputs":[{"internalType":"bytes4","name":"revertData","type":"bytes4"}],"stateMutability":"nonpayable","type":"function","name":"expectPartialRevert"},{"inputs":[{"internalType":"bytes4","name":"revertData","type":"bytes4"},{"internalType":"address","name":"reverter","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"expectPartialRevert"},{"inputs":[{"internalType":"address","name":"reverter","type":"address"},{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectRevert"},{"inputs":[{"internalType":"bytes4","name":"revertData","type":"bytes4"},{"internalType":"address","name":"reverter","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"expectRevert"},{"inputs":[{"internalType":"bytes","name":"revertData","type":"bytes"},{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectRevert"},{"inputs":[{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectRevert"},{"inputs":[{"internalType":"bytes","name":"revertData","type":"bytes"},{"internalType":"address","name":"reverter","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"expectRevert"},{"inputs":[{"internalType":"bytes4","name":"revertData","type":"bytes4"},{"internalType":"address","name":"reverter","type":"address"},{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectRevert"},{"inputs":[{"internalType":"bytes4","name":"revertData","type":"bytes4"}],"stateMutability":"nonpayable","type":"function","name":"expectRevert"},{"inputs":[{"internalType":"bytes","name":"revertData","type":"bytes"},{"internalType":"address","name":"reverter","type":"address"},{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectRevert"},{"inputs":[{"internalType":"address","name":"reverter","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"expectRevert"},{"inputs":[{"internalType":"bytes4","name":"revertData","type":"bytes4"},{"internalType":"uint64","name":"count","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectRevert"},{"inputs":[{"internalType":"bytes","name":"revertData","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"expectRevert"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"expectRevert"},{"inputs":[{"internalType":"uint64","name":"min","type":"uint64"},{"internalType":"uint64","name":"max","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectSafeMemory"},{"inputs":[{"internalType":"uint64","name":"min","type":"uint64"},{"internalType":"uint64","name":"max","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"expectSafeMemoryCall"},{"inputs":[{"internalType":"uint256","name":"newBasefee","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"fee"},{"inputs":[{"internalType":"string[]","name":"commandInput","type":"string[]"}],"stateMutability":"nonpayable","type":"function","name":"ffi","outputs":[{"internalType":"bytes","name":"result","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"version","type":"string"}],"stateMutability":"view","type":"function","name":"foundryVersionAtLeast","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"string","name":"version","type":"string"}],"stateMutability":"view","type":"function","name":"foundryVersionCmp","outputs":[{"internalType":"int256","name":"","type":"int256"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"fsMetadata","outputs":[{"internalType":"struct VmSafe.FsMetadata","name":"metadata","type":"tuple","components":[{"internalType":"bool","name":"isDir","type":"bool"},{"internalType":"bool","name":"isSymlink","type":"bool"},{"internalType":"uint256","name":"length","type":"uint256"},{"internalType":"bool","name":"readOnly","type":"bool"},{"internalType":"uint256","name":"modified","type":"uint256"},{"internalType":"uint256","name":"accessed","type":"uint256"},{"internalType":"uint256","name":"created","type":"uint256"}]}]},{"inputs":[{"internalType":"bytes","name":"code","type":"bytes"}],"stateMutability":"view","type":"function","name":"getArtifactPathByCode","outputs":[{"internalType":"string","name":"path","type":"string"}]},{"inputs":[{"internalType":"bytes","name":"deployedCode","type":"bytes"}],"stateMutability":"view","type":"function","name":"getArtifactPathByDeployedCode","outputs":[{"internalType":"string","name":"path","type":"string"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getBlobBaseFee","outputs":[{"internalType":"uint256","name":"blobBaseFee","type":"uint256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getBlobhashes","outputs":[{"internalType":"bytes32[]","name":"hashes","type":"bytes32[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getBlockNumber","outputs":[{"internalType":"uint256","name":"height","type":"uint256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getBlockTimestamp","outputs":[{"internalType":"uint256","name":"timestamp","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"contractName","type":"string"},{"internalType":"uint64","name":"chainId","type":"uint64"},{"internalType":"enum VmSafe.BroadcastTxType","name":"txType","type":"uint8"}],"stateMutability":"view","type":"function","name":"getBroadcast","outputs":[{"internalType":"struct VmSafe.BroadcastTxSummary","name":"","type":"tuple","components":[{"internalType":"bytes32","name":"txHash","type":"bytes32"},{"internalType":"enum VmSafe.BroadcastTxType","name":"txType","type":"uint8"},{"internalType":"address","name":"contractAddress","type":"address"},{"internalType":"uint64","name":"blockNumber","type":"uint64"},{"internalType":"bool","name":"success","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"contractName","type":"string"},{"internalType":"uint64","name":"chainId","type":"uint64"}],"stateMutability":"view","type":"function","name":"getBroadcasts","outputs":[{"internalType":"struct VmSafe.BroadcastTxSummary[]","name":"","type":"tuple[]","components":[{"internalType":"bytes32","name":"txHash","type":"bytes32"},{"internalType":"enum VmSafe.BroadcastTxType","name":"txType","type":"uint8"},{"internalType":"address","name":"contractAddress","type":"address"},{"internalType":"uint64","name":"blockNumber","type":"uint64"},{"internalType":"bool","name":"success","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"contractName","type":"string"},{"internalType":"uint64","name":"chainId","type":"uint64"},{"internalType":"enum VmSafe.BroadcastTxType","name":"txType","type":"uint8"}],"stateMutability":"view","type":"function","name":"getBroadcasts","outputs":[{"internalType":"struct VmSafe.BroadcastTxSummary[]","name":"","type":"tuple[]","components":[{"internalType":"bytes32","name":"txHash","type":"bytes32"},{"internalType":"enum VmSafe.BroadcastTxType","name":"txType","type":"uint8"},{"internalType":"address","name":"contractAddress","type":"address"},{"internalType":"uint64","name":"blockNumber","type":"uint64"},{"internalType":"bool","name":"success","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"chainAlias","type":"string"}],"stateMutability":"view","type":"function","name":"getChain","outputs":[{"internalType":"struct VmSafe.Chain","name":"chain","type":"tuple","components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"uint256","name":"chainId","type":"uint256"},{"internalType":"string","name":"chainAlias","type":"string"},{"internalType":"string","name":"rpcUrl","type":"string"}]}]},{"inputs":[{"internalType":"uint256","name":"chainId","type":"uint256"}],"stateMutability":"view","type":"function","name":"getChain","outputs":[{"internalType":"struct VmSafe.Chain","name":"chain","type":"tuple","components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"uint256","name":"chainId","type":"uint256"},{"internalType":"string","name":"chainAlias","type":"string"},{"internalType":"string","name":"rpcUrl","type":"string"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getChainId","outputs":[{"internalType":"uint256","name":"blockChainId","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"}],"stateMutability":"view","type":"function","name":"getCode","outputs":[{"internalType":"bytes","name":"creationBytecode","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"}],"stateMutability":"view","type":"function","name":"getDeployedCode","outputs":[{"internalType":"bytes","name":"runtimeBytecode","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"contractName","type":"string"},{"internalType":"uint64","name":"chainId","type":"uint64"}],"stateMutability":"view","type":"function","name":"getDeployment","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"contractName","type":"string"}],"stateMutability":"view","type":"function","name":"getDeployment","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"contractName","type":"string"},{"internalType":"uint64","name":"chainId","type":"uint64"}],"stateMutability":"view","type":"function","name":"getDeployments","outputs":[{"internalType":"address[]","name":"deployedAddresses","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getFoundryVersion","outputs":[{"internalType":"string","name":"version","type":"string"}]},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"stateMutability":"view","type":"function","name":"getLabel","outputs":[{"internalType":"string","name":"currentLabel","type":"string"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32","name":"elementSlot","type":"bytes32"}],"stateMutability":"view","type":"function","name":"getMappingKeyAndParentOf","outputs":[{"internalType":"bool","name":"found","type":"bool"},{"internalType":"bytes32","name":"key","type":"bytes32"},{"internalType":"bytes32","name":"parent","type":"bytes32"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32","name":"mappingSlot","type":"bytes32"}],"stateMutability":"view","type":"function","name":"getMappingLength","outputs":[{"internalType":"uint256","name":"length","type":"uint256"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32","name":"mappingSlot","type":"bytes32"},{"internalType":"uint256","name":"idx","type":"uint256"}],"stateMutability":"view","type":"function","name":"getMappingSlotAt","outputs":[{"internalType":"bytes32","name":"value","type":"bytes32"}]},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"stateMutability":"view","type":"function","name":"getNonce","outputs":[{"internalType":"uint64","name":"nonce","type":"uint64"}]},{"inputs":[{"internalType":"struct VmSafe.Wallet","name":"wallet","type":"tuple","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"},{"internalType":"uint256","name":"privateKey","type":"uint256"}]}],"stateMutability":"view","type":"function","name":"getNonce","outputs":[{"internalType":"uint64","name":"nonce","type":"uint64"}]},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"stateMutability":"view","type":"function","name":"getRawBlockHeader","outputs":[{"internalType":"bytes","name":"rlpHeader","type":"bytes"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getRecordedLogs","outputs":[{"internalType":"struct VmSafe.Log[]","name":"logs","type":"tuple[]","components":[{"internalType":"bytes32[]","name":"topics","type":"bytes32[]"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"address","name":"emitter","type":"address"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getStateDiff","outputs":[{"internalType":"string","name":"diff","type":"string"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getStateDiffJson","outputs":[{"internalType":"string","name":"diff","type":"string"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getStorageAccesses","outputs":[{"internalType":"struct VmSafe.StorageAccess[]","name":"storageAccesses","type":"tuple[]","components":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bytes32","name":"slot","type":"bytes32"},{"internalType":"bool","name":"isWrite","type":"bool"},{"internalType":"bytes32","name":"previousValue","type":"bytes32"},{"internalType":"bytes32","name":"newValue","type":"bytes32"},{"internalType":"bool","name":"reverted","type":"bool"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getWallets","outputs":[{"internalType":"address[]","name":"wallets","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"input","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"indexOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"interceptInitcode"},{"inputs":[{"internalType":"enum VmSafe.ForgeContext","name":"context","type":"uint8"}],"stateMutability":"view","type":"function","name":"isContext","outputs":[{"internalType":"bool","name":"result","type":"bool"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"isDir","outputs":[{"internalType":"bool","name":"result","type":"bool"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"isFile","outputs":[{"internalType":"bool","name":"result","type":"bool"}]},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"stateMutability":"view","type":"function","name":"isPersistent","outputs":[{"internalType":"bool","name":"persistent","type":"bool"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"view","type":"function","name":"keyExists","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"view","type":"function","name":"keyExistsJson","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"view","type":"function","name":"keyExistsToml","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"string","name":"newLabel","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"label"},{"inputs":[],"stateMutability":"view","type":"function","name":"lastCallGas","outputs":[{"internalType":"struct VmSafe.Gas","name":"gas","type":"tuple","components":[{"internalType":"uint64","name":"gasLimit","type":"uint64"},{"internalType":"uint64","name":"gasTotalUsed","type":"uint64"},{"internalType":"uint64","name":"gasMemoryUsed","type":"uint64"},{"internalType":"int64","name":"gasRefunded","type":"int64"},{"internalType":"uint64","name":"gasRemaining","type":"uint64"}]}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32","name":"slot","type":"bytes32"}],"stateMutability":"view","type":"function","name":"load","outputs":[{"internalType":"bytes32","name":"data","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"pathToAllocsJson","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"loadAllocs"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"}],"stateMutability":"nonpayable","type":"function","name":"makePersistent"},{"inputs":[{"internalType":"address","name":"account0","type":"address"},{"internalType":"address","name":"account1","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"makePersistent"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"makePersistent"},{"inputs":[{"internalType":"address","name":"account0","type":"address"},{"internalType":"address","name":"account1","type":"address"},{"internalType":"address","name":"account2","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"makePersistent"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"bytes4","name":"data","type":"bytes4"},{"internalType":"bytes","name":"returnData","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"mockCall"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"uint256","name":"msgValue","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"bytes","name":"returnData","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"mockCall"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"bytes","name":"returnData","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"mockCall"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"uint256","name":"msgValue","type":"uint256"},{"internalType":"bytes4","name":"data","type":"bytes4"},{"internalType":"bytes","name":"returnData","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"mockCall"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"bytes4","name":"data","type":"bytes4"},{"internalType":"bytes","name":"revertData","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"mockCallRevert"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"uint256","name":"msgValue","type":"uint256"},{"internalType":"bytes4","name":"data","type":"bytes4"},{"internalType":"bytes","name":"revertData","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"mockCallRevert"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"uint256","name":"msgValue","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"bytes","name":"revertData","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"mockCallRevert"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"bytes","name":"revertData","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"mockCallRevert"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"uint256","name":"msgValue","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"bytes[]","name":"returnData","type":"bytes[]"}],"stateMutability":"nonpayable","type":"function","name":"mockCalls"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"bytes[]","name":"returnData","type":"bytes[]"}],"stateMutability":"nonpayable","type":"function","name":"mockCalls"},{"inputs":[{"internalType":"address","name":"callee","type":"address"},{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"mockFunction"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"noAccessList"},{"inputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}],"stateMutability":"pure","type":"function","name":"parseAddress","outputs":[{"internalType":"address","name":"parsedValue","type":"address"}]},{"inputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}],"stateMutability":"pure","type":"function","name":"parseBool","outputs":[{"internalType":"bool","name":"parsedValue","type":"bool"}]},{"inputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}],"stateMutability":"pure","type":"function","name":"parseBytes","outputs":[{"internalType":"bytes","name":"parsedValue","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}],"stateMutability":"pure","type":"function","name":"parseBytes32","outputs":[{"internalType":"bytes32","name":"parsedValue","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}],"stateMutability":"pure","type":"function","name":"parseInt","outputs":[{"internalType":"int256","name":"parsedValue","type":"int256"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJson","outputs":[{"internalType":"bytes","name":"abiEncodedData","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJson","outputs":[{"internalType":"bytes","name":"abiEncodedData","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonAddress","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonAddressArray","outputs":[{"internalType":"address[]","name":"","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonBool","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonBoolArray","outputs":[{"internalType":"bool[]","name":"","type":"bool[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonBytes","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonBytes32","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonBytes32Array","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonBytesArray","outputs":[{"internalType":"bytes[]","name":"","type":"bytes[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonInt","outputs":[{"internalType":"int256","name":"","type":"int256"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonIntArray","outputs":[{"internalType":"int256[]","name":"","type":"int256[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonKeys","outputs":[{"internalType":"string[]","name":"keys","type":"string[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonString","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonStringArray","outputs":[{"internalType":"string[]","name":"","type":"string[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonType","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonType","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonTypeArray","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonUintArray","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseToml","outputs":[{"internalType":"bytes","name":"abiEncodedData","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"}],"stateMutability":"pure","type":"function","name":"parseToml","outputs":[{"internalType":"bytes","name":"abiEncodedData","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlAddress","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlAddressArray","outputs":[{"internalType":"address[]","name":"","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlBool","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlBoolArray","outputs":[{"internalType":"bool[]","name":"","type":"bool[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlBytes","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlBytes32","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlBytes32Array","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlBytesArray","outputs":[{"internalType":"bytes[]","name":"","type":"bytes[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlInt","outputs":[{"internalType":"int256","name":"","type":"int256"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlIntArray","outputs":[{"internalType":"int256[]","name":"","type":"int256[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlKeys","outputs":[{"internalType":"string[]","name":"keys","type":"string[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlString","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlStringArray","outputs":[{"internalType":"string[]","name":"","type":"string[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlType","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlType","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlTypeArray","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlUintArray","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}]},{"inputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}],"stateMutability":"pure","type":"function","name":"parseUint","outputs":[{"internalType":"uint256","name":"parsedValue","type":"uint256"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"pauseGasMetering"},{"inputs":[],"stateMutability":"view","type":"function","name":"pauseTracing"},{"inputs":[{"internalType":"address","name":"msgSender","type":"address"},{"internalType":"address","name":"txOrigin","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"prank"},{"inputs":[{"internalType":"address","name":"msgSender","type":"address"},{"internalType":"address","name":"txOrigin","type":"address"},{"internalType":"bool","name":"delegateCall","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"prank"},{"inputs":[{"internalType":"address","name":"msgSender","type":"address"},{"internalType":"bool","name":"delegateCall","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"prank"},{"inputs":[{"internalType":"address","name":"msgSender","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"prank"},{"inputs":[{"internalType":"bytes32","name":"newPrevrandao","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"prevrandao"},{"inputs":[{"internalType":"uint256","name":"newPrevrandao","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"prevrandao"},{"inputs":[],"stateMutability":"view","type":"function","name":"projectRoot","outputs":[{"internalType":"string","name":"path","type":"string"}]},{"inputs":[{"internalType":"string","name":"promptText","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"prompt","outputs":[{"internalType":"string","name":"input","type":"string"}]},{"inputs":[{"internalType":"string","name":"promptText","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"promptAddress","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"promptText","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"promptSecret","outputs":[{"internalType":"string","name":"input","type":"string"}]},{"inputs":[{"internalType":"string","name":"promptText","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"promptSecretUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"promptText","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"promptUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"pure","type":"function","name":"publicKeyP256","outputs":[{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"randomAddress","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"randomBool","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"uint256","name":"len","type":"uint256"}],"stateMutability":"view","type":"function","name":"randomBytes","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"randomBytes4","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"randomBytes8","outputs":[{"internalType":"bytes8","name":"","type":"bytes8"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"randomInt","outputs":[{"internalType":"int256","name":"","type":"int256"}]},{"inputs":[{"internalType":"uint256","name":"bits","type":"uint256"}],"stateMutability":"view","type":"function","name":"randomInt","outputs":[{"internalType":"int256","name":"","type":"int256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"randomUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"uint256","name":"bits","type":"uint256"}],"stateMutability":"view","type":"function","name":"randomUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"uint256","name":"min","type":"uint256"},{"internalType":"uint256","name":"max","type":"uint256"}],"stateMutability":"view","type":"function","name":"randomUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"readCallers","outputs":[{"internalType":"enum VmSafe.CallerMode","name":"callerMode","type":"uint8"},{"internalType":"address","name":"msgSender","type":"address"},{"internalType":"address","name":"txOrigin","type":"address"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"uint64","name":"maxDepth","type":"uint64"}],"stateMutability":"view","type":"function","name":"readDir","outputs":[{"internalType":"struct VmSafe.DirEntry[]","name":"entries","type":"tuple[]","components":[{"internalType":"string","name":"errorMessage","type":"string"},{"internalType":"string","name":"path","type":"string"},{"internalType":"uint64","name":"depth","type":"uint64"},{"internalType":"bool","name":"isDir","type":"bool"},{"internalType":"bool","name":"isSymlink","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"uint64","name":"maxDepth","type":"uint64"},{"internalType":"bool","name":"followLinks","type":"bool"}],"stateMutability":"view","type":"function","name":"readDir","outputs":[{"internalType":"struct VmSafe.DirEntry[]","name":"entries","type":"tuple[]","components":[{"internalType":"string","name":"errorMessage","type":"string"},{"internalType":"string","name":"path","type":"string"},{"internalType":"uint64","name":"depth","type":"uint64"},{"internalType":"bool","name":"isDir","type":"bool"},{"internalType":"bool","name":"isSymlink","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"readDir","outputs":[{"internalType":"struct VmSafe.DirEntry[]","name":"entries","type":"tuple[]","components":[{"internalType":"string","name":"errorMessage","type":"string"},{"internalType":"string","name":"path","type":"string"},{"internalType":"uint64","name":"depth","type":"uint64"},{"internalType":"bool","name":"isDir","type":"bool"},{"internalType":"bool","name":"isSymlink","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"readFile","outputs":[{"internalType":"string","name":"data","type":"string"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"readFileBinary","outputs":[{"internalType":"bytes","name":"data","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"readLine","outputs":[{"internalType":"string","name":"line","type":"string"}]},{"inputs":[{"internalType":"string","name":"linkPath","type":"string"}],"stateMutability":"view","type":"function","name":"readLink","outputs":[{"internalType":"string","name":"targetPath","type":"string"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"record"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"recordLogs"},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"rememberKey","outputs":[{"internalType":"address","name":"keyAddr","type":"address"}]},{"inputs":[{"internalType":"string","name":"mnemonic","type":"string"},{"internalType":"string","name":"derivationPath","type":"string"},{"internalType":"uint32","name":"count","type":"uint32"}],"stateMutability":"nonpayable","type":"function","name":"rememberKeys","outputs":[{"internalType":"address[]","name":"keyAddrs","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"mnemonic","type":"string"},{"internalType":"string","name":"derivationPath","type":"string"},{"internalType":"string","name":"language","type":"string"},{"internalType":"uint32","name":"count","type":"uint32"}],"stateMutability":"nonpayable","type":"function","name":"rememberKeys","outputs":[{"internalType":"address[]","name":"keyAddrs","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"bool","name":"recursive","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"removeDir"},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"removeFile"},{"inputs":[{"internalType":"string","name":"input","type":"string"},{"internalType":"string","name":"from","type":"string"},{"internalType":"string","name":"to","type":"string"}],"stateMutability":"pure","type":"function","name":"replace","outputs":[{"internalType":"string","name":"output","type":"string"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"resetGasMetering"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"resetNonce"},{"inputs":[{"internalType":"string","name":"input","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"resolveEnv","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"resumeGasMetering"},{"inputs":[],"stateMutability":"view","type":"function","name":"resumeTracing"},{"inputs":[{"internalType":"uint256","name":"snapshotId","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"revertTo","outputs":[{"internalType":"bool","name":"success","type":"bool"}]},{"inputs":[{"internalType":"uint256","name":"snapshotId","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"revertToAndDelete","outputs":[{"internalType":"bool","name":"success","type":"bool"}]},{"inputs":[{"internalType":"uint256","name":"snapshotId","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"revertToState","outputs":[{"internalType":"bool","name":"success","type":"bool"}]},{"inputs":[{"internalType":"uint256","name":"snapshotId","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"revertToStateAndDelete","outputs":[{"internalType":"bool","name":"success","type":"bool"}]},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"}],"stateMutability":"nonpayable","type":"function","name":"revokePersistent"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"revokePersistent"},{"inputs":[{"internalType":"uint256","name":"newHeight","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"roll"},{"inputs":[{"internalType":"bytes32","name":"txHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"rollFork"},{"inputs":[{"internalType":"uint256","name":"forkId","type":"uint256"},{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"rollFork"},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"rollFork"},{"inputs":[{"internalType":"uint256","name":"forkId","type":"uint256"},{"internalType":"bytes32","name":"txHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"rollFork"},{"inputs":[{"internalType":"string","name":"urlOrAlias","type":"string"},{"internalType":"string","name":"method","type":"string"},{"internalType":"string","name":"params","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"rpc","outputs":[{"internalType":"bytes","name":"data","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"method","type":"string"},{"internalType":"string","name":"params","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"rpc","outputs":[{"internalType":"bytes","name":"data","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"rpcAlias","type":"string"}],"stateMutability":"view","type":"function","name":"rpcUrl","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"rpcUrlStructs","outputs":[{"internalType":"struct VmSafe.Rpc[]","name":"urls","type":"tuple[]","components":[{"internalType":"string","name":"key","type":"string"},{"internalType":"string","name":"url","type":"string"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"rpcUrls","outputs":[{"internalType":"string[2][]","name":"urls","type":"string[2][]"}]},{"inputs":[{"internalType":"uint256","name":"forkId","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"selectFork"},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"address[]","name":"values","type":"address[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeAddress","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"address","name":"value","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"serializeAddress","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"bool[]","name":"values","type":"bool[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeBool","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"bool","name":"value","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"serializeBool","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"bytes[]","name":"values","type":"bytes[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeBytes","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"bytes","name":"value","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"serializeBytes","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"bytes32[]","name":"values","type":"bytes32[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeBytes32","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"bytes32","name":"value","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"serializeBytes32","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"int256","name":"value","type":"int256"}],"stateMutability":"nonpayable","type":"function","name":"serializeInt","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"int256[]","name":"values","type":"int256[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeInt","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"value","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"serializeJson","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"typeDescription","type":"string"},{"internalType":"bytes","name":"value","type":"bytes"}],"stateMutability":"pure","type":"function","name":"serializeJsonType","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"},{"internalType":"bytes","name":"value","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"serializeJsonType","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"string[]","name":"values","type":"string[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeString","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"string","name":"value","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"serializeString","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"uint256","name":"value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"serializeUint","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"uint256[]","name":"values","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeUint","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"uint256","name":"value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"serializeUintToHex","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bool","name":"overwrite","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"setArbitraryStorage"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"setArbitraryStorage"},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes32","name":"blockHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"setBlockhash"},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"value","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"setEnv"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint64","name":"newNonce","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"setNonce"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint64","name":"newNonce","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"setNonceUnsafe"},{"inputs":[{"internalType":"uint256","name":"seed","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"setSeed"},{"inputs":[{"internalType":"uint256[]","name":"array","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function","name":"shuffle","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}]},{"inputs":[{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"sign","outputs":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}]},{"inputs":[{"internalType":"address","name":"signer","type":"address"},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"sign","outputs":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}]},{"inputs":[{"internalType":"struct VmSafe.Wallet","name":"wallet","type":"tuple","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"},{"internalType":"uint256","name":"privateKey","type":"uint256"}]},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"sign","outputs":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"sign","outputs":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}]},{"inputs":[{"internalType":"address","name":"implementation","type":"address"},{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"signAndAttachDelegation","outputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}]},{"inputs":[{"internalType":"address","name":"implementation","type":"address"},{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"uint64","name":"nonce","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"signAndAttachDelegation","outputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}]},{"inputs":[{"internalType":"address","name":"implementation","type":"address"},{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"bool","name":"crossChain","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"signAndAttachDelegation","outputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}]},{"inputs":[{"internalType":"struct VmSafe.Wallet","name":"wallet","type":"tuple","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"},{"internalType":"uint256","name":"privateKey","type":"uint256"}]},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"signCompact","outputs":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"vs","type":"bytes32"}]},{"inputs":[{"internalType":"address","name":"signer","type":"address"},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"signCompact","outputs":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"vs","type":"bytes32"}]},{"inputs":[{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"signCompact","outputs":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"vs","type":"bytes32"}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"signCompact","outputs":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"vs","type":"bytes32"}]},{"inputs":[{"internalType":"address","name":"implementation","type":"address"},{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"signDelegation","outputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}]},{"inputs":[{"internalType":"address","name":"implementation","type":"address"},{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"bool","name":"crossChain","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"signDelegation","outputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}]},{"inputs":[{"internalType":"address","name":"implementation","type":"address"},{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"uint64","name":"nonce","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"signDelegation","outputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"signP256","outputs":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}]},{"inputs":[{"internalType":"bool","name":"skipTest","type":"bool"},{"internalType":"string","name":"reason","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"skip"},{"inputs":[{"internalType":"bool","name":"skipTest","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"skip"},{"inputs":[{"internalType":"uint256","name":"duration","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"sleep"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"snapshot","outputs":[{"internalType":"uint256","name":"snapshotId","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"group","type":"string"},{"internalType":"string","name":"name","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"snapshotGasLastCall","outputs":[{"internalType":"uint256","name":"gasUsed","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"snapshotGasLastCall","outputs":[{"internalType":"uint256","name":"gasUsed","type":"uint256"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"snapshotState","outputs":[{"internalType":"uint256","name":"snapshotId","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"uint256","name":"value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"snapshotValue"},{"inputs":[{"internalType":"string","name":"group","type":"string"},{"internalType":"string","name":"name","type":"string"},{"internalType":"uint256","name":"value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"snapshotValue"},{"inputs":[{"internalType":"uint256[]","name":"array","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function","name":"sort","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}]},{"inputs":[{"internalType":"string","name":"input","type":"string"},{"internalType":"string","name":"delimiter","type":"string"}],"stateMutability":"pure","type":"function","name":"split","outputs":[{"internalType":"string[]","name":"outputs","type":"string[]"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"startBroadcast"},{"inputs":[{"internalType":"address","name":"signer","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"startBroadcast"},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"startBroadcast"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"startDebugTraceRecording"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"startMappingRecording"},{"inputs":[{"internalType":"address","name":"msgSender","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"startPrank"},{"inputs":[{"internalType":"address","name":"msgSender","type":"address"},{"internalType":"bool","name":"delegateCall","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"startPrank"},{"inputs":[{"internalType":"address","name":"msgSender","type":"address"},{"internalType":"address","name":"txOrigin","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"startPrank"},{"inputs":[{"internalType":"address","name":"msgSender","type":"address"},{"internalType":"address","name":"txOrigin","type":"address"},{"internalType":"bool","name":"delegateCall","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"startPrank"},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"startSnapshotGas"},{"inputs":[{"internalType":"string","name":"group","type":"string"},{"internalType":"string","name":"name","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"startSnapshotGas"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"startStateDiffRecording"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopAndReturnDebugTraceRecording","outputs":[{"internalType":"struct VmSafe.DebugStep[]","name":"step","type":"tuple[]","components":[{"internalType":"uint256[]","name":"stack","type":"uint256[]"},{"internalType":"bytes","name":"memoryInput","type":"bytes"},{"internalType":"uint8","name":"opcode","type":"uint8"},{"internalType":"uint64","name":"depth","type":"uint64"},{"internalType":"bool","name":"isOutOfGas","type":"bool"},{"internalType":"address","name":"contractAddr","type":"address"}]}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopAndReturnStateDiff","outputs":[{"internalType":"struct VmSafe.AccountAccess[]","name":"accountAccesses","type":"tuple[]","components":[{"internalType":"struct VmSafe.ChainInfo","name":"chainInfo","type":"tuple","components":[{"internalType":"uint256","name":"forkId","type":"uint256"},{"internalType":"uint256","name":"chainId","type":"uint256"}]},{"internalType":"enum VmSafe.AccountAccessKind","name":"kind","type":"uint8"},{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"accessor","type":"address"},{"internalType":"bool","name":"initialized","type":"bool"},{"internalType":"uint256","name":"oldBalance","type":"uint256"},{"internalType":"uint256","name":"newBalance","type":"uint256"},{"internalType":"bytes","name":"deployedCode","type":"bytes"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"bool","name":"reverted","type":"bool"},{"internalType":"struct VmSafe.StorageAccess[]","name":"storageAccesses","type":"tuple[]","components":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bytes32","name":"slot","type":"bytes32"},{"internalType":"bool","name":"isWrite","type":"bool"},{"internalType":"bytes32","name":"previousValue","type":"bytes32"},{"internalType":"bytes32","name":"newValue","type":"bytes32"},{"internalType":"bool","name":"reverted","type":"bool"}]},{"internalType":"uint64","name":"depth","type":"uint64"},{"internalType":"uint64","name":"oldNonce","type":"uint64"},{"internalType":"uint64","name":"newNonce","type":"uint64"}]}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopBroadcast"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopExpectSafeMemory"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopMappingRecording"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopPrank"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopRecord"},{"inputs":[{"internalType":"string","name":"group","type":"string"},{"internalType":"string","name":"name","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"stopSnapshotGas","outputs":[{"internalType":"uint256","name":"gasUsed","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"stopSnapshotGas","outputs":[{"internalType":"uint256","name":"gasUsed","type":"uint256"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopSnapshotGas","outputs":[{"internalType":"uint256","name":"gasUsed","type":"uint256"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32","name":"slot","type":"bytes32"},{"internalType":"bytes32","name":"value","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"store"},{"inputs":[{"internalType":"string","name":"data","type":"string"}],"stateMutability":"pure","type":"function","name":"toBase64","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"pure","type":"function","name":"toBase64","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[{"internalType":"string","name":"data","type":"string"}],"stateMutability":"pure","type":"function","name":"toBase64URL","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"pure","type":"function","name":"toBase64URL","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[{"internalType":"string","name":"input","type":"string"}],"stateMutability":"pure","type":"function","name":"toLowercase","outputs":[{"internalType":"string","name":"output","type":"string"}]},{"inputs":[{"internalType":"address","name":"value","type":"address"}],"stateMutability":"pure","type":"function","name":"toString","outputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}]},{"inputs":[{"internalType":"uint256","name":"value","type":"uint256"}],"stateMutability":"pure","type":"function","name":"toString","outputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}]},{"inputs":[{"internalType":"bytes","name":"value","type":"bytes"}],"stateMutability":"pure","type":"function","name":"toString","outputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}]},{"inputs":[{"internalType":"bool","name":"value","type":"bool"}],"stateMutability":"pure","type":"function","name":"toString","outputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}]},{"inputs":[{"internalType":"int256","name":"value","type":"int256"}],"stateMutability":"pure","type":"function","name":"toString","outputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}]},{"inputs":[{"internalType":"bytes32","name":"value","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"toString","outputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}]},{"inputs":[{"internalType":"string","name":"input","type":"string"}],"stateMutability":"pure","type":"function","name":"toUppercase","outputs":[{"internalType":"string","name":"output","type":"string"}]},{"inputs":[{"internalType":"uint256","name":"forkId","type":"uint256"},{"internalType":"bytes32","name":"txHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"transact"},{"inputs":[{"internalType":"bytes32","name":"txHash","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"transact"},{"inputs":[{"internalType":"string","name":"input","type":"string"}],"stateMutability":"pure","type":"function","name":"trim","outputs":[{"internalType":"string","name":"output","type":"string"}]},{"inputs":[{"internalType":"string[]","name":"commandInput","type":"string[]"}],"stateMutability":"nonpayable","type":"function","name":"tryFfi","outputs":[{"internalType":"struct VmSafe.FfiResult","name":"result","type":"tuple","components":[{"internalType":"int32","name":"exitCode","type":"int32"},{"internalType":"bytes","name":"stdout","type":"bytes"},{"internalType":"bytes","name":"stderr","type":"bytes"}]}]},{"inputs":[{"internalType":"uint256","name":"newGasPrice","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"txGasPrice"},{"inputs":[],"stateMutability":"view","type":"function","name":"unixTime","outputs":[{"internalType":"uint256","name":"milliseconds","type":"uint256"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32","name":"slot","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"warmSlot"},{"inputs":[{"internalType":"uint256","name":"newTimestamp","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"warp"},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"string","name":"data","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"writeFile"},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"writeFileBinary"},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"path","type":"string"},{"internalType":"string","name":"valueKey","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"writeJson"},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"path","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"writeJson"},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"string","name":"data","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"writeLine"},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"path","type":"string"},{"internalType":"string","name":"valueKey","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"writeToml"},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"path","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"writeToml"}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{"accessList((address,bytes32[])[])":{"notice":"Utility cheatcode to set an EIP-2930 access list for all subsequent transactions."},"accesses(address)":{"notice":"Gets all accessed reads and write slot from a `vm.record` session, for a given address."},"activeFork()":{"notice":"Returns the identifier of the currently active fork. Reverts if no fork is currently active."},"addr(uint256)":{"notice":"Gets the address for a given private key."},"allowCheatcodes(address)":{"notice":"In forking mode, explicitly grant the given address cheatcode access."},"assertApproxEqAbs(int256,int256,uint256)":{"notice":"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`."},"assertApproxEqAbs(int256,int256,uint256,string)":{"notice":"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. Includes error message into revert string on failure."},"assertApproxEqAbs(uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`."},"assertApproxEqAbs(uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. Includes error message into revert string on failure."},"assertApproxEqAbsDecimal(int256,int256,uint256,uint256)":{"notice":"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message."},"assertApproxEqAbsDecimal(int256,int256,uint256,uint256,string)":{"notice":"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertApproxEqAbsDecimal(uint256,uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message."},"assertApproxEqAbsDecimal(uint256,uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertApproxEqRel(int256,int256,uint256)":{"notice":"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100%"},"assertApproxEqRel(int256,int256,uint256,string)":{"notice":"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Includes error message into revert string on failure."},"assertApproxEqRel(uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100%"},"assertApproxEqRel(uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Includes error message into revert string on failure."},"assertApproxEqRelDecimal(int256,int256,uint256,uint256)":{"notice":"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message."},"assertApproxEqRelDecimal(int256,int256,uint256,uint256,string)":{"notice":"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertApproxEqRelDecimal(uint256,uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message."},"assertApproxEqRelDecimal(uint256,uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertEq(address,address)":{"notice":"Asserts that two `address` values are equal."},"assertEq(address,address,string)":{"notice":"Asserts that two `address` values are equal and includes error message into revert string on failure."},"assertEq(address[],address[])":{"notice":"Asserts that two arrays of `address` values are equal."},"assertEq(address[],address[],string)":{"notice":"Asserts that two arrays of `address` values are equal and includes error message into revert string on failure."},"assertEq(bool,bool)":{"notice":"Asserts that two `bool` values are equal."},"assertEq(bool,bool,string)":{"notice":"Asserts that two `bool` values are equal and includes error message into revert string on failure."},"assertEq(bool[],bool[])":{"notice":"Asserts that two arrays of `bool` values are equal."},"assertEq(bool[],bool[],string)":{"notice":"Asserts that two arrays of `bool` values are equal and includes error message into revert string on failure."},"assertEq(bytes,bytes)":{"notice":"Asserts that two `bytes` values are equal."},"assertEq(bytes,bytes,string)":{"notice":"Asserts that two `bytes` values are equal and includes error message into revert string on failure."},"assertEq(bytes32,bytes32)":{"notice":"Asserts that two `bytes32` values are equal."},"assertEq(bytes32,bytes32,string)":{"notice":"Asserts that two `bytes32` values are equal and includes error message into revert string on failure."},"assertEq(bytes32[],bytes32[])":{"notice":"Asserts that two arrays of `bytes32` values are equal."},"assertEq(bytes32[],bytes32[],string)":{"notice":"Asserts that two arrays of `bytes32` values are equal and includes error message into revert string on failure."},"assertEq(bytes[],bytes[])":{"notice":"Asserts that two arrays of `bytes` values are equal."},"assertEq(bytes[],bytes[],string)":{"notice":"Asserts that two arrays of `bytes` values are equal and includes error message into revert string on failure."},"assertEq(int256,int256)":{"notice":"Asserts that two `int256` values are equal."},"assertEq(int256,int256,string)":{"notice":"Asserts that two `int256` values are equal and includes error message into revert string on failure."},"assertEq(int256[],int256[])":{"notice":"Asserts that two arrays of `int256` values are equal."},"assertEq(int256[],int256[],string)":{"notice":"Asserts that two arrays of `int256` values are equal and includes error message into revert string on failure."},"assertEq(string,string)":{"notice":"Asserts that two `string` values are equal."},"assertEq(string,string,string)":{"notice":"Asserts that two `string` values are equal and includes error message into revert string on failure."},"assertEq(string[],string[])":{"notice":"Asserts that two arrays of `string` values are equal."},"assertEq(string[],string[],string)":{"notice":"Asserts that two arrays of `string` values are equal and includes error message into revert string on failure."},"assertEq(uint256,uint256)":{"notice":"Asserts that two `uint256` values are equal."},"assertEq(uint256,uint256,string)":{"notice":"Asserts that two `uint256` values are equal and includes error message into revert string on failure."},"assertEq(uint256[],uint256[])":{"notice":"Asserts that two arrays of `uint256 values are equal."},"assertEq(uint256[],uint256[],string)":{"notice":"Asserts that two arrays of `uint256` values are equal and includes error message into revert string on failure."},"assertEqDecimal(int256,int256,uint256)":{"notice":"Asserts that two `int256` values are equal, formatting them with decimals in failure message."},"assertEqDecimal(int256,int256,uint256,string)":{"notice":"Asserts that two `int256` values are equal, formatting them with decimals in failure message. Includes error message into revert string on failure."},"assertEqDecimal(uint256,uint256,uint256)":{"notice":"Asserts that two `uint256` values are equal, formatting them with decimals in failure message."},"assertEqDecimal(uint256,uint256,uint256,string)":{"notice":"Asserts that two `uint256` values are equal, formatting them with decimals in failure message. Includes error message into revert string on failure."},"assertFalse(bool)":{"notice":"Asserts that the given condition is false."},"assertFalse(bool,string)":{"notice":"Asserts that the given condition is false and includes error message into revert string on failure."},"assertGe(int256,int256)":{"notice":"Compares two `int256` values. Expects first value to be greater than or equal to second."},"assertGe(int256,int256,string)":{"notice":"Compares two `int256` values. Expects first value to be greater than or equal to second. Includes error message into revert string on failure."},"assertGe(uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be greater than or equal to second."},"assertGe(uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be greater than or equal to second. Includes error message into revert string on failure."},"assertGeDecimal(int256,int256,uint256)":{"notice":"Compares two `int256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message."},"assertGeDecimal(int256,int256,uint256,string)":{"notice":"Compares two `int256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertGeDecimal(uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message."},"assertGeDecimal(uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertGt(int256,int256)":{"notice":"Compares two `int256` values. Expects first value to be greater than second."},"assertGt(int256,int256,string)":{"notice":"Compares two `int256` values. Expects first value to be greater than second. Includes error message into revert string on failure."},"assertGt(uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be greater than second."},"assertGt(uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be greater than second. Includes error message into revert string on failure."},"assertGtDecimal(int256,int256,uint256)":{"notice":"Compares two `int256` values. Expects first value to be greater than second. Formats values with decimals in failure message."},"assertGtDecimal(int256,int256,uint256,string)":{"notice":"Compares two `int256` values. Expects first value to be greater than second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertGtDecimal(uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be greater than second. Formats values with decimals in failure message."},"assertGtDecimal(uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be greater than second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertLe(int256,int256)":{"notice":"Compares two `int256` values. Expects first value to be less than or equal to second."},"assertLe(int256,int256,string)":{"notice":"Compares two `int256` values. Expects first value to be less than or equal to second. Includes error message into revert string on failure."},"assertLe(uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be less than or equal to second."},"assertLe(uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be less than or equal to second. Includes error message into revert string on failure."},"assertLeDecimal(int256,int256,uint256)":{"notice":"Compares two `int256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message."},"assertLeDecimal(int256,int256,uint256,string)":{"notice":"Compares two `int256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertLeDecimal(uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message."},"assertLeDecimal(uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertLt(int256,int256)":{"notice":"Compares two `int256` values. Expects first value to be less than second."},"assertLt(int256,int256,string)":{"notice":"Compares two `int256` values. Expects first value to be less than second. Includes error message into revert string on failure."},"assertLt(uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be less than second."},"assertLt(uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be less than second. Includes error message into revert string on failure."},"assertLtDecimal(int256,int256,uint256)":{"notice":"Compares two `int256` values. Expects first value to be less than second. Formats values with decimals in failure message."},"assertLtDecimal(int256,int256,uint256,string)":{"notice":"Compares two `int256` values. Expects first value to be less than second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertLtDecimal(uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be less than second. Formats values with decimals in failure message."},"assertLtDecimal(uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be less than second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertNotEq(address,address)":{"notice":"Asserts that two `address` values are not equal."},"assertNotEq(address,address,string)":{"notice":"Asserts that two `address` values are not equal and includes error message into revert string on failure."},"assertNotEq(address[],address[])":{"notice":"Asserts that two arrays of `address` values are not equal."},"assertNotEq(address[],address[],string)":{"notice":"Asserts that two arrays of `address` values are not equal and includes error message into revert string on failure."},"assertNotEq(bool,bool)":{"notice":"Asserts that two `bool` values are not equal."},"assertNotEq(bool,bool,string)":{"notice":"Asserts that two `bool` values are not equal and includes error message into revert string on failure."},"assertNotEq(bool[],bool[])":{"notice":"Asserts that two arrays of `bool` values are not equal."},"assertNotEq(bool[],bool[],string)":{"notice":"Asserts that two arrays of `bool` values are not equal and includes error message into revert string on failure."},"assertNotEq(bytes,bytes)":{"notice":"Asserts that two `bytes` values are not equal."},"assertNotEq(bytes,bytes,string)":{"notice":"Asserts that two `bytes` values are not equal and includes error message into revert string on failure."},"assertNotEq(bytes32,bytes32)":{"notice":"Asserts that two `bytes32` values are not equal."},"assertNotEq(bytes32,bytes32,string)":{"notice":"Asserts that two `bytes32` values are not equal and includes error message into revert string on failure."},"assertNotEq(bytes32[],bytes32[])":{"notice":"Asserts that two arrays of `bytes32` values are not equal."},"assertNotEq(bytes32[],bytes32[],string)":{"notice":"Asserts that two arrays of `bytes32` values are not equal and includes error message into revert string on failure."},"assertNotEq(bytes[],bytes[])":{"notice":"Asserts that two arrays of `bytes` values are not equal."},"assertNotEq(bytes[],bytes[],string)":{"notice":"Asserts that two arrays of `bytes` values are not equal and includes error message into revert string on failure."},"assertNotEq(int256,int256)":{"notice":"Asserts that two `int256` values are not equal."},"assertNotEq(int256,int256,string)":{"notice":"Asserts that two `int256` values are not equal and includes error message into revert string on failure."},"assertNotEq(int256[],int256[])":{"notice":"Asserts that two arrays of `int256` values are not equal."},"assertNotEq(int256[],int256[],string)":{"notice":"Asserts that two arrays of `int256` values are not equal and includes error message into revert string on failure."},"assertNotEq(string,string)":{"notice":"Asserts that two `string` values are not equal."},"assertNotEq(string,string,string)":{"notice":"Asserts that two `string` values are not equal and includes error message into revert string on failure."},"assertNotEq(string[],string[])":{"notice":"Asserts that two arrays of `string` values are not equal."},"assertNotEq(string[],string[],string)":{"notice":"Asserts that two arrays of `string` values are not equal and includes error message into revert string on failure."},"assertNotEq(uint256,uint256)":{"notice":"Asserts that two `uint256` values are not equal."},"assertNotEq(uint256,uint256,string)":{"notice":"Asserts that two `uint256` values are not equal and includes error message into revert string on failure."},"assertNotEq(uint256[],uint256[])":{"notice":"Asserts that two arrays of `uint256` values are not equal."},"assertNotEq(uint256[],uint256[],string)":{"notice":"Asserts that two arrays of `uint256` values are not equal and includes error message into revert string on failure."},"assertNotEqDecimal(int256,int256,uint256)":{"notice":"Asserts that two `int256` values are not equal, formatting them with decimals in failure message."},"assertNotEqDecimal(int256,int256,uint256,string)":{"notice":"Asserts that two `int256` values are not equal, formatting them with decimals in failure message. Includes error message into revert string on failure."},"assertNotEqDecimal(uint256,uint256,uint256)":{"notice":"Asserts that two `uint256` values are not equal, formatting them with decimals in failure message."},"assertNotEqDecimal(uint256,uint256,uint256,string)":{"notice":"Asserts that two `uint256` values are not equal, formatting them with decimals in failure message. Includes error message into revert string on failure."},"assertTrue(bool)":{"notice":"Asserts that the given condition is true."},"assertTrue(bool,string)":{"notice":"Asserts that the given condition is true and includes error message into revert string on failure."},"assume(bool)":{"notice":"If the condition is false, discard this run's fuzz inputs and generate new ones."},"assumeNoRevert((address,bool,bytes))":{"notice":"Discard this run's fuzz inputs and generate new ones if next call reverts with the potential revert parameters."},"assumeNoRevert((address,bool,bytes)[])":{"notice":"Discard this run's fuzz inputs and generate new ones if next call reverts with the any of the potential revert parameters."},"assumeNoRevert()":{"notice":"Discard this run's fuzz inputs and generate new ones if next call reverted."},"attachBlob(bytes)":{"notice":"Attach an EIP-4844 blob to the next call"},"attachDelegation((uint8,bytes32,bytes32,uint64,address))":{"notice":"Designate the next call as an EIP-7702 transaction"},"attachDelegation((uint8,bytes32,bytes32,uint64,address),bool)":{"notice":"Designate the next call as an EIP-7702 transaction, with optional cross-chain validity."},"blobBaseFee(uint256)":{"notice":"Sets `block.blobbasefee`"},"blobhashes(bytes32[])":{"notice":"Sets the blobhashes in the transaction. Not available on EVM versions before Cancun. If used on unsupported EVM versions it will revert."},"bound(int256,int256,int256)":{"notice":"Returns an int256 value bounded in given range and different from the current one."},"bound(uint256,uint256,uint256)":{"notice":"Returns an uint256 value bounded in given range and different from the current one."},"breakpoint(string)":{"notice":"Writes a breakpoint to jump to in the debugger."},"breakpoint(string,bool)":{"notice":"Writes a conditional breakpoint to jump to in the debugger."},"broadcast()":{"notice":"Has the next call (at this call depth only) create transactions that can later be signed and sent onchain. Broadcasting address is determined by checking the following in order: 1. If `--sender` argument was provided, that address is used. 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used."},"broadcast(address)":{"notice":"Has the next call (at this call depth only) create a transaction with the address provided as the sender that can later be signed and sent onchain."},"broadcast(uint256)":{"notice":"Has the next call (at this call depth only) create a transaction with the private key provided as the sender that can later be signed and sent onchain."},"broadcastRawTransaction(bytes)":{"notice":"Takes a signed transaction and broadcasts it to the network."},"chainId(uint256)":{"notice":"Sets `block.chainid`."},"clearMockedCalls()":{"notice":"Clears all mocked calls."},"cloneAccount(address,address)":{"notice":"Clones a source account code, state, balance and nonce to a target account and updates in-memory EVM state."},"closeFile(string)":{"notice":"Closes file for reading, resetting the offset and allowing to read it from beginning with readLine. `path` is relative to the project root."},"coinbase(address)":{"notice":"Sets `block.coinbase`."},"computeCreate2Address(bytes32,bytes32)":{"notice":"Compute the address of a contract created with CREATE2 using the default CREATE2 deployer."},"computeCreate2Address(bytes32,bytes32,address)":{"notice":"Compute the address of a contract created with CREATE2 using the given CREATE2 deployer."},"computeCreateAddress(address,uint256)":{"notice":"Compute the address a contract will be deployed at for a given deployer address and nonce."},"contains(string,string)":{"notice":"Returns true if `search` is found in `subject`, false otherwise."},"cool(address)":{"notice":"Marks the slots of an account and the account address as cold."},"coolSlot(address,bytes32)":{"notice":"Utility cheatcode to mark specific storage slot as cold, simulating no prior read."},"copyFile(string,string)":{"notice":"Copies the contents of one file to another. This function will **overwrite** the contents of `to`. On success, the total number of bytes copied is returned and it is equal to the length of the `to` file as reported by `metadata`. Both `from` and `to` are relative to the project root."},"copyStorage(address,address)":{"notice":"Utility cheatcode to copy storage of `from` contract to another `to` contract."},"createDir(string,bool)":{"notice":"Creates a new, empty directory at the provided path. This cheatcode will revert in the following situations, but is not limited to just these cases: - User lacks permissions to modify `path`. - A parent of the given path doesn't exist and `recursive` is false. - `path` already exists and `recursive` is false. `path` is relative to the project root."},"createFork(string)":{"notice":"Creates a new fork with the given endpoint and the _latest_ block and returns the identifier of the fork."},"createFork(string,bytes32)":{"notice":"Creates a new fork with the given endpoint and at the block the given transaction was mined in, replays all transaction mined in the block before the transaction, and returns the identifier of the fork."},"createFork(string,uint256)":{"notice":"Creates a new fork with the given endpoint and block and returns the identifier of the fork."},"createSelectFork(string)":{"notice":"Creates and also selects a new fork with the given endpoint and the latest block and returns the identifier of the fork."},"createSelectFork(string,bytes32)":{"notice":"Creates and also selects new fork with the given endpoint and at the block the given transaction was mined in, replays all transaction mined in the block before the transaction, returns the identifier of the fork."},"createSelectFork(string,uint256)":{"notice":"Creates and also selects a new fork with the given endpoint and block and returns the identifier of the fork."},"createWallet(string)":{"notice":"Derives a private key from the name, labels the account with that name, and returns the wallet."},"createWallet(uint256)":{"notice":"Generates a wallet from the private key and returns the wallet."},"createWallet(uint256,string)":{"notice":"Generates a wallet from the private key, labels the account with that name, and returns the wallet."},"deal(address,uint256)":{"notice":"Sets an address' balance."},"deleteSnapshot(uint256)":{"notice":"`deleteSnapshot` is being deprecated in favor of `deleteStateSnapshot`. It will be removed in future versions."},"deleteSnapshots()":{"notice":"`deleteSnapshots` is being deprecated in favor of `deleteStateSnapshots`. It will be removed in future versions."},"deleteStateSnapshot(uint256)":{"notice":"Removes the snapshot with the given ID created by `snapshot`. Takes the snapshot ID to delete. Returns `true` if the snapshot was successfully deleted. Returns `false` if the snapshot does not exist."},"deleteStateSnapshots()":{"notice":"Removes _all_ snapshots previously created by `snapshot`."},"deployCode(string)":{"notice":"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional."},"deployCode(string,bytes)":{"notice":"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments."},"deployCode(string,bytes,bytes32)":{"notice":"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments."},"deployCode(string,bytes,uint256)":{"notice":"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments and `msg.value`."},"deployCode(string,bytes,uint256,bytes32)":{"notice":"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments and `msg.value`."},"deployCode(string,bytes32)":{"notice":"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional."},"deployCode(string,uint256)":{"notice":"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts `msg.value`."},"deployCode(string,uint256,bytes32)":{"notice":"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts `msg.value`."},"deriveKey(string,string,uint32)":{"notice":"Derive a private key from a provided mnemonic string (or mnemonic file path) at `{derivationPath}{index}`."},"deriveKey(string,string,uint32,string)":{"notice":"Derive a private key from a provided mnemonic string (or mnemonic file path) in the specified language at `{derivationPath}{index}`."},"deriveKey(string,uint32)":{"notice":"Derive a private key from a provided mnemonic string (or mnemonic file path) at the derivation path `m/44'/60'/0'/0/{index}`."},"deriveKey(string,uint32,string)":{"notice":"Derive a private key from a provided mnemonic string (or mnemonic file path) in the specified language at the derivation path `m/44'/60'/0'/0/{index}`."},"difficulty(uint256)":{"notice":"Sets `block.difficulty`. Not available on EVM versions from Paris onwards. Use `prevrandao` instead. Reverts if used on unsupported EVM versions."},"dumpState(string)":{"notice":"Dump a genesis JSON file's `allocs` to disk."},"eip712HashStruct(string,bytes)":{"notice":"Generates the struct hash of the canonical EIP-712 type representation and its abi-encoded data. Supports 2 different inputs: 1. Name of the type (i.e. \"PermitSingle\"): * requires previous binding generation with `forge bind-json`. * bindings will be retrieved from the path configured in `foundry.toml`. 2. String representation of the type (i.e. \"Foo(Bar bar) Bar(uint256 baz)\"). * Note: the cheatcode will use the canonical type even if the input is malformated with the wrong order of elements or with extra whitespaces."},"eip712HashStruct(string,string,bytes)":{"notice":"Generates the struct hash of the canonical EIP-712 type representation and its abi-encoded data. Requires previous binding generation with `forge bind-json`. Params: * `bindingsPath`: path where the output of `forge bind-json` is stored. * `typeName`: Name of the type (i.e. \"PermitSingle\"). * `abiEncodedData`: ABI-encoded data for the struct that is being hashed."},"eip712HashType(string)":{"notice":"Generates the hash of the canonical EIP-712 type representation. Supports 2 different inputs: 1. Name of the type (i.e. \"Transaction\"): * requires previous binding generation with `forge bind-json`. * bindings will be retrieved from the path configured in `foundry.toml`. 2. String representation of the type (i.e. \"Foo(Bar bar) Bar(uint256 baz)\"). * Note: the cheatcode will output the canonical type even if the input is malformated with the wrong order of elements or with extra whitespaces."},"eip712HashType(string,string)":{"notice":"Generates the hash of the canonical EIP-712 type representation. Requires previous binding generation with `forge bind-json`. Params: * `bindingsPath`: path where the output of `forge bind-json` is stored. * `typeName`: Name of the type (i.e. \"Transaction\")."},"eip712HashTypedData(string)":{"notice":"Generates a ready-to-sign digest of human-readable typed data following the EIP-712 standard."},"ensNamehash(string)":{"notice":"Returns ENS namehash for provided string."},"envAddress(string)":{"notice":"Gets the environment variable `name` and parses it as `address`. Reverts if the variable was not found or could not be parsed."},"envAddress(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"envBool(string)":{"notice":"Gets the environment variable `name` and parses it as `bool`. Reverts if the variable was not found or could not be parsed."},"envBool(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"envBytes(string)":{"notice":"Gets the environment variable `name` and parses it as `bytes`. Reverts if the variable was not found or could not be parsed."},"envBytes(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"envBytes32(string)":{"notice":"Gets the environment variable `name` and parses it as `bytes32`. Reverts if the variable was not found or could not be parsed."},"envBytes32(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"envExists(string)":{"notice":"Gets the environment variable `name` and returns true if it exists, else returns false."},"envInt(string)":{"notice":"Gets the environment variable `name` and parses it as `int256`. Reverts if the variable was not found or could not be parsed."},"envInt(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"envOr(string,address)":{"notice":"Gets the environment variable `name` and parses it as `address`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,bool)":{"notice":"Gets the environment variable `name` and parses it as `bool`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,bytes)":{"notice":"Gets the environment variable `name` and parses it as `bytes`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,bytes32)":{"notice":"Gets the environment variable `name` and parses it as `bytes32`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,int256)":{"notice":"Gets the environment variable `name` and parses it as `int256`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string)":{"notice":"Gets the environment variable `name` and parses it as `string`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,address[])":{"notice":"Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,bool[])":{"notice":"Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,bytes32[])":{"notice":"Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,bytes[])":{"notice":"Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,int256[])":{"notice":"Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,string[])":{"notice":"Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,uint256[])":{"notice":"Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,uint256)":{"notice":"Gets the environment variable `name` and parses it as `uint256`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envString(string)":{"notice":"Gets the environment variable `name` and parses it as `string`. Reverts if the variable was not found or could not be parsed."},"envString(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"envUint(string)":{"notice":"Gets the environment variable `name` and parses it as `uint256`. Reverts if the variable was not found or could not be parsed."},"envUint(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"etch(address,bytes)":{"notice":"Sets an address' code."},"eth_getLogs(uint256,uint256,address,bytes32[])":{"notice":"Gets all the logs according to specified filter."},"exists(string)":{"notice":"Returns true if the given path points to an existing entity, else returns false."},"expectCall(address,bytes)":{"notice":"Expects a call to an address with the specified calldata. Calldata can either be a strict or a partial match."},"expectCall(address,bytes,uint64)":{"notice":"Expects given number of calls to an address with the specified calldata."},"expectCall(address,uint256,bytes)":{"notice":"Expects a call to an address with the specified `msg.value` and calldata."},"expectCall(address,uint256,bytes,uint64)":{"notice":"Expects given number of calls to an address with the specified `msg.value` and calldata."},"expectCall(address,uint256,uint64,bytes)":{"notice":"Expect a call to an address with the specified `msg.value`, gas, and calldata."},"expectCall(address,uint256,uint64,bytes,uint64)":{"notice":"Expects given number of calls to an address with the specified `msg.value`, gas, and calldata."},"expectCallMinGas(address,uint256,uint64,bytes)":{"notice":"Expect a call to an address with the specified `msg.value` and calldata, and a *minimum* amount of gas."},"expectCallMinGas(address,uint256,uint64,bytes,uint64)":{"notice":"Expect given number of calls to an address with the specified `msg.value` and calldata, and a *minimum* amount of gas."},"expectCreate(bytes,address)":{"notice":"Expects the deployment of the specified bytecode by the specified address using the CREATE opcode"},"expectCreate2(bytes,address)":{"notice":"Expects the deployment of the specified bytecode by the specified address using the CREATE2 opcode"},"expectEmit()":{"notice":"Prepare an expected log with all topic and data checks enabled. Call this function, then emit an event, then call a function. Internally after the call, we check if logs were emitted in the expected order with the expected topics and data."},"expectEmit(address)":{"notice":"Same as the previous method, but also checks supplied address against emitting contract."},"expectEmit(address,uint64)":{"notice":"Expect a given number of logs from a specific emitter with all topic and data checks enabled."},"expectEmit(bool,bool,bool,bool)":{"notice":"Prepare an expected log with (bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData.). Call this function, then emit an event, then call a function. Internally after the call, we check if logs were emitted in the expected order with the expected topics and data (as specified by the booleans)."},"expectEmit(bool,bool,bool,bool,address)":{"notice":"Same as the previous method, but also checks supplied address against emitting contract."},"expectEmit(bool,bool,bool,bool,address,uint64)":{"notice":"Expect a given number of logs from a specific emitter with the provided topics."},"expectEmit(bool,bool,bool,bool,uint64)":{"notice":"Expect a given number of logs with the provided topics."},"expectEmit(uint64)":{"notice":"Expect a given number of logs with all topic and data checks enabled."},"expectEmitAnonymous()":{"notice":"Prepare an expected anonymous log with all topic and data checks enabled. Call this function, then emit an anonymous event, then call a function. Internally after the call, we check if logs were emitted in the expected order with the expected topics and data."},"expectEmitAnonymous(address)":{"notice":"Same as the previous method, but also checks supplied address against emitting contract."},"expectEmitAnonymous(bool,bool,bool,bool,bool)":{"notice":"Prepare an expected anonymous log with (bool checkTopic1, bool checkTopic2, bool checkTopic3, bool checkData.). Call this function, then emit an anonymous event, then call a function. Internally after the call, we check if logs were emitted in the expected order with the expected topics and data (as specified by the booleans)."},"expectEmitAnonymous(bool,bool,bool,bool,bool,address)":{"notice":"Same as the previous method, but also checks supplied address against emitting contract."},"expectPartialRevert(bytes4)":{"notice":"Expects an error on next call that starts with the revert data."},"expectPartialRevert(bytes4,address)":{"notice":"Expects an error on next call to reverter address, that starts with the revert data."},"expectRevert()":{"notice":"Expects an error on next call with any revert data."},"expectRevert(address)":{"notice":"Expects an error with any revert data on next call to reverter address."},"expectRevert(address,uint64)":{"notice":"Expects a `count` number of reverts from the upcoming calls from the reverter address."},"expectRevert(bytes)":{"notice":"Expects an error on next call that exactly matches the revert data."},"expectRevert(bytes,address)":{"notice":"Expects an error from reverter address on next call, that exactly matches the revert data."},"expectRevert(bytes,address,uint64)":{"notice":"Expects a `count` number of reverts from the upcoming calls from the reverter address that exactly match the revert data."},"expectRevert(bytes,uint64)":{"notice":"Expects a `count` number of reverts from the upcoming calls that exactly match the revert data."},"expectRevert(bytes4)":{"notice":"Expects an error on next call that exactly matches the revert data."},"expectRevert(bytes4,address)":{"notice":"Expects an error from reverter address on next call, with any revert data."},"expectRevert(bytes4,address,uint64)":{"notice":"Expects a `count` number of reverts from the upcoming calls from the reverter address that match the revert data."},"expectRevert(bytes4,uint64)":{"notice":"Expects a `count` number of reverts from the upcoming calls that match the revert data."},"expectRevert(uint64)":{"notice":"Expects a `count` number of reverts from the upcoming calls with any revert data or reverter."},"expectSafeMemory(uint64,uint64)":{"notice":"Only allows memory writes to offsets [0x00, 0x60) ∪ [min, max) in the current subcontext. If any other memory is written to, the test will fail. Can be called multiple times to add more ranges to the set."},"expectSafeMemoryCall(uint64,uint64)":{"notice":"Only allows memory writes to offsets [0x00, 0x60) ∪ [min, max) in the next created subcontext. If any other memory is written to, the test will fail. Can be called multiple times to add more ranges to the set."},"fee(uint256)":{"notice":"Sets `block.basefee`."},"ffi(string[])":{"notice":"Performs a foreign function call via the terminal."},"foundryVersionAtLeast(string)":{"notice":"Returns true if the current Foundry version is greater than or equal to the given version. The given version string must be in the format `major.minor.patch`. This is equivalent to `foundryVersionCmp(version) >= 0`."},"foundryVersionCmp(string)":{"notice":"Compares the current Foundry version with the given version string. The given version string must be in the format `major.minor.patch`. Returns: -1 if current Foundry version is less than the given version 0 if current Foundry version equals the given version 1 if current Foundry version is greater than the given version This result can then be used with a comparison operator against `0`. For example, to check if the current Foundry version is greater than or equal to `1.0.0`: `if (foundryVersionCmp(\"1.0.0\") >= 0) { ... }`"},"fsMetadata(string)":{"notice":"Given a path, query the file system to get information about a file, directory, etc."},"getArtifactPathByCode(bytes)":{"notice":"Gets the artifact path from code (aka. creation code)."},"getArtifactPathByDeployedCode(bytes)":{"notice":"Gets the artifact path from deployed code (aka. runtime code)."},"getBlobBaseFee()":{"notice":"Gets the current `block.blobbasefee`. You should use this instead of `block.blobbasefee` if you use `vm.blobBaseFee`, as `block.blobbasefee` is assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180"},"getBlobhashes()":{"notice":"Gets the blockhashes from the current transaction. Not available on EVM versions before Cancun. If used on unsupported EVM versions it will revert."},"getBlockNumber()":{"notice":"Gets the current `block.number`. You should use this instead of `block.number` if you use `vm.roll`, as `block.number` is assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180"},"getBlockTimestamp()":{"notice":"Gets the current `block.timestamp`. You should use this instead of `block.timestamp` if you use `vm.warp`, as `block.timestamp` is assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180"},"getBroadcast(string,uint64,uint8)":{"notice":"Returns the most recent broadcast for the given contract on `chainId` matching `txType`. For example: The most recent deployment can be fetched by passing `txType` as `CREATE` or `CREATE2`. The most recent call can be fetched by passing `txType` as `CALL`."},"getBroadcasts(string,uint64)":{"notice":"Returns all broadcasts for the given contract on `chainId`. Sorted such that the most recent broadcast is the first element, and the oldest is the last. i.e descending order of BroadcastTxSummary.blockNumber."},"getBroadcasts(string,uint64,uint8)":{"notice":"Returns all broadcasts for the given contract on `chainId` with the specified `txType`. Sorted such that the most recent broadcast is the first element, and the oldest is the last. i.e descending order of BroadcastTxSummary.blockNumber."},"getChain(string)":{"notice":"Returns a Chain struct for specific alias"},"getChain(uint256)":{"notice":"Returns a Chain struct for specific chainId"},"getChainId()":{"notice":"Gets the current `block.chainid` of the currently selected environment. You should use this instead of `block.chainid` if you use `vm.selectFork` or `vm.createSelectFork`, as `block.chainid` could be assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180"},"getCode(string)":{"notice":"Gets the creation bytecode from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional."},"getDeployedCode(string)":{"notice":"Gets the deployed bytecode from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional."},"getDeployment(string)":{"notice":"Returns the most recent deployment for the current `chainId`."},"getDeployment(string,uint64)":{"notice":"Returns the most recent deployment for the given contract on `chainId`"},"getDeployments(string,uint64)":{"notice":"Returns all deployments for the given contract on `chainId` Sorted in descending order of deployment time i.e descending order of BroadcastTxSummary.blockNumber. The most recent deployment is the first element, and the oldest is the last."},"getFoundryVersion()":{"notice":"Returns the Foundry version. Format: -+.. Sample output: 0.3.0-nightly+3cb96bde9b.1737036656.debug Note: Build timestamps may vary slightly across platforms due to separate CI jobs. For reliable version comparisons, use UNIX format (e.g., >= 1700000000) to compare timestamps while ignoring minor time differences."},"getLabel(address)":{"notice":"Gets the label for the specified address."},"getMappingKeyAndParentOf(address,bytes32)":{"notice":"Gets the map key and parent of a mapping at a given slot, for a given address."},"getMappingLength(address,bytes32)":{"notice":"Gets the number of elements in the mapping at the given slot, for a given address."},"getMappingSlotAt(address,bytes32,uint256)":{"notice":"Gets the elements at index idx of the mapping at the given slot, for a given address. The index must be less than the length of the mapping (i.e. the number of keys in the mapping)."},"getNonce((address,uint256,uint256,uint256))":{"notice":"Get the nonce of a `Wallet`."},"getNonce(address)":{"notice":"Gets the nonce of an account."},"getRawBlockHeader(uint256)":{"notice":"Gets the RLP encoded block header for a given block number. Returns the block header in the same format as `cast block --raw`."},"getRecordedLogs()":{"notice":"Gets all the recorded logs."},"getStateDiff()":{"notice":"Returns state diffs from current `vm.startStateDiffRecording` session."},"getStateDiffJson()":{"notice":"Returns state diffs from current `vm.startStateDiffRecording` session, in json format."},"getStorageAccesses()":{"notice":"Returns an array of `StorageAccess` from current `vm.stateStateDiffRecording` session"},"getWallets()":{"notice":"Returns addresses of available unlocked wallets in the script environment."},"indexOf(string,string)":{"notice":"Returns the index of the first occurrence of a `key` in an `input` string. Returns `NOT_FOUND` (i.e. `type(uint256).max`) if the `key` is not found. Returns 0 in case of an empty `key`."},"interceptInitcode()":{"notice":"Causes the next contract creation (via new) to fail and return its initcode in the returndata buffer. This allows type-safe access to the initcode payload that would be used for contract creation. Example usage: vm.interceptInitcode(); bytes memory initcode; try new MyContract(param1, param2) { assert(false); } catch (bytes memory interceptedInitcode) { initcode = interceptedInitcode; }"},"isContext(uint8)":{"notice":"Returns true if `forge` command was executed in given context."},"isDir(string)":{"notice":"Returns true if the path exists on disk and is pointing at a directory, else returns false."},"isFile(string)":{"notice":"Returns true if the path exists on disk and is pointing at a regular file, else returns false."},"isPersistent(address)":{"notice":"Returns true if the account is marked as persistent."},"keyExists(string,string)":{"notice":"Checks if `key` exists in a JSON object `keyExists` is being deprecated in favor of `keyExistsJson`. It will be removed in future versions."},"keyExistsJson(string,string)":{"notice":"Checks if `key` exists in a JSON object."},"keyExistsToml(string,string)":{"notice":"Checks if `key` exists in a TOML table."},"label(address,string)":{"notice":"Labels an address in call traces."},"lastCallGas()":{"notice":"Gets the gas used in the last call from the callee perspective."},"load(address,bytes32)":{"notice":"Loads a storage slot from an address."},"loadAllocs(string)":{"notice":"Load a genesis JSON file's `allocs` into the in-memory EVM state."},"makePersistent(address)":{"notice":"Marks that the account(s) should use persistent storage across fork swaps in a multifork setup Meaning, changes made to the state of this account will be kept when switching forks."},"makePersistent(address,address)":{"notice":"See `makePersistent(address)`."},"makePersistent(address,address,address)":{"notice":"See `makePersistent(address)`."},"makePersistent(address[])":{"notice":"See `makePersistent(address)`."},"mockCall(address,bytes,bytes)":{"notice":"Mocks a call to an address, returning specified data. Calldata can either be strict or a partial match, e.g. if you only pass a Solidity selector to the expected calldata, then the entire Solidity function will be mocked."},"mockCall(address,bytes4,bytes)":{"notice":"Mocks a call to an address, returning specified data. Calldata can either be strict or a partial match, e.g. if you only pass a Solidity selector to the expected calldata, then the entire Solidity function will be mocked. Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`."},"mockCall(address,uint256,bytes,bytes)":{"notice":"Mocks a call to an address with a specific `msg.value`, returning specified data. Calldata match takes precedence over `msg.value` in case of ambiguity."},"mockCall(address,uint256,bytes4,bytes)":{"notice":"Mocks a call to an address with a specific `msg.value`, returning specified data. Calldata match takes precedence over `msg.value` in case of ambiguity. Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`."},"mockCallRevert(address,bytes,bytes)":{"notice":"Reverts a call to an address with specified revert data."},"mockCallRevert(address,bytes4,bytes)":{"notice":"Reverts a call to an address with specified revert data. Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`."},"mockCallRevert(address,uint256,bytes,bytes)":{"notice":"Reverts a call to an address with a specific `msg.value`, with specified revert data."},"mockCallRevert(address,uint256,bytes4,bytes)":{"notice":"Reverts a call to an address with a specific `msg.value`, with specified revert data. Overload to pass the function selector directly `token.approve.selector` instead of `abi.encodeWithSelector(token.approve.selector)`."},"mockCalls(address,bytes,bytes[])":{"notice":"Mocks multiple calls to an address, returning specified data for each call."},"mockCalls(address,uint256,bytes,bytes[])":{"notice":"Mocks multiple calls to an address with a specific `msg.value`, returning specified data for each call."},"mockFunction(address,address,bytes)":{"notice":"Whenever a call is made to `callee` with calldata `data`, this cheatcode instead calls `target` with the same calldata. This functionality is similar to a delegate call made to `target` contract from `callee`. Can be used to substitute a call to a function with another implementation that captures the primary logic of the original function but is easier to reason about. If calldata is not a strict match then partial match by selector is attempted."},"noAccessList()":{"notice":"Utility cheatcode to remove any EIP-2930 access list set by `accessList` cheatcode."},"parseAddress(string)":{"notice":"Parses the given `string` into an `address`."},"parseBool(string)":{"notice":"Parses the given `string` into a `bool`."},"parseBytes(string)":{"notice":"Parses the given `string` into `bytes`."},"parseBytes32(string)":{"notice":"Parses the given `string` into a `bytes32`."},"parseInt(string)":{"notice":"Parses the given `string` into a `int256`."},"parseJson(string)":{"notice":"ABI-encodes a JSON object."},"parseJson(string,string)":{"notice":"ABI-encodes a JSON object at `key`."},"parseJsonAddress(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `address`."},"parseJsonAddressArray(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `address[]`."},"parseJsonBool(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `bool`."},"parseJsonBoolArray(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `bool[]`."},"parseJsonBytes(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `bytes`."},"parseJsonBytes32(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `bytes32`."},"parseJsonBytes32Array(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `bytes32[]`."},"parseJsonBytesArray(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `bytes[]`."},"parseJsonInt(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `int256`."},"parseJsonIntArray(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `int256[]`."},"parseJsonKeys(string,string)":{"notice":"Returns an array of all the keys in a JSON object."},"parseJsonString(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `string`."},"parseJsonStringArray(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `string[]`."},"parseJsonType(string,string)":{"notice":"Parses a string of JSON data and coerces it to type corresponding to `typeDescription`."},"parseJsonType(string,string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to type corresponding to `typeDescription`."},"parseJsonTypeArray(string,string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to type array corresponding to `typeDescription`."},"parseJsonUint(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `uint256`."},"parseJsonUintArray(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `uint256[]`."},"parseToml(string)":{"notice":"ABI-encodes a TOML table."},"parseToml(string,string)":{"notice":"ABI-encodes a TOML table at `key`."},"parseTomlAddress(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `address`."},"parseTomlAddressArray(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `address[]`."},"parseTomlBool(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `bool`."},"parseTomlBoolArray(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `bool[]`."},"parseTomlBytes(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `bytes`."},"parseTomlBytes32(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `bytes32`."},"parseTomlBytes32Array(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `bytes32[]`."},"parseTomlBytesArray(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `bytes[]`."},"parseTomlInt(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `int256`."},"parseTomlIntArray(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `int256[]`."},"parseTomlKeys(string,string)":{"notice":"Returns an array of all the keys in a TOML table."},"parseTomlString(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `string`."},"parseTomlStringArray(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `string[]`."},"parseTomlType(string,string)":{"notice":"Parses a string of TOML data and coerces it to type corresponding to `typeDescription`."},"parseTomlType(string,string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to type corresponding to `typeDescription`."},"parseTomlTypeArray(string,string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to type array corresponding to `typeDescription`."},"parseTomlUint(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `uint256`."},"parseTomlUintArray(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `uint256[]`."},"parseUint(string)":{"notice":"Parses the given `string` into a `uint256`."},"pauseGasMetering()":{"notice":"Pauses gas metering (i.e. gas usage is not counted). Noop if already paused."},"pauseTracing()":{"notice":"Pauses collection of call traces. Useful in cases when you want to skip tracing of complex calls which are not useful for debugging."},"prank(address)":{"notice":"Sets the *next* call's `msg.sender` to be the input address."},"prank(address,address)":{"notice":"Sets the *next* call's `msg.sender` to be the input address, and the `tx.origin` to be the second input."},"prank(address,address,bool)":{"notice":"Sets the *next* delegate call's `msg.sender` to be the input address, and the `tx.origin` to be the second input."},"prank(address,bool)":{"notice":"Sets the *next* delegate call's `msg.sender` to be the input address."},"prevrandao(bytes32)":{"notice":"Sets `block.prevrandao`. Not available on EVM versions before Paris. Use `difficulty` instead. If used on unsupported EVM versions it will revert."},"prevrandao(uint256)":{"notice":"Sets `block.prevrandao`. Not available on EVM versions before Paris. Use `difficulty` instead. If used on unsupported EVM versions it will revert."},"projectRoot()":{"notice":"Get the path of the current project root."},"prompt(string)":{"notice":"Prompts the user for a string value in the terminal."},"promptAddress(string)":{"notice":"Prompts the user for an address in the terminal."},"promptSecret(string)":{"notice":"Prompts the user for a hidden string value in the terminal."},"promptSecretUint(string)":{"notice":"Prompts the user for hidden uint256 in the terminal (usually pk)."},"promptUint(string)":{"notice":"Prompts the user for uint256 in the terminal."},"publicKeyP256(uint256)":{"notice":"Derives secp256r1 public key from the provided `privateKey`."},"randomAddress()":{"notice":"Returns a random `address`."},"randomBool()":{"notice":"Returns a random `bool`."},"randomBytes(uint256)":{"notice":"Returns a random byte array value of the given length."},"randomBytes4()":{"notice":"Returns a random fixed-size byte array of length 4."},"randomBytes8()":{"notice":"Returns a random fixed-size byte array of length 8."},"randomInt()":{"notice":"Returns a random `int256` value."},"randomInt(uint256)":{"notice":"Returns a random `int256` value of given bits."},"randomUint()":{"notice":"Returns a random uint256 value."},"randomUint(uint256)":{"notice":"Returns a random `uint256` value of given bits."},"randomUint(uint256,uint256)":{"notice":"Returns random uint256 value between the provided range (=min..=max)."},"readCallers()":{"notice":"Reads the current `msg.sender` and `tx.origin` from state and reports if there is any active caller modification."},"readDir(string)":{"notice":"Reads the directory at the given path recursively, up to `maxDepth`. `maxDepth` defaults to 1, meaning only the direct children of the given directory will be returned. Follows symbolic links if `followLinks` is true."},"readDir(string,uint64)":{"notice":"See `readDir(string)`."},"readDir(string,uint64,bool)":{"notice":"See `readDir(string)`."},"readFile(string)":{"notice":"Reads the entire content of file to string. `path` is relative to the project root."},"readFileBinary(string)":{"notice":"Reads the entire content of file as binary. `path` is relative to the project root."},"readLine(string)":{"notice":"Reads next line of file to string."},"readLink(string)":{"notice":"Reads a symbolic link, returning the path that the link points to. This cheatcode will revert in the following situations, but is not limited to just these cases: - `path` is not a symbolic link. - `path` does not exist."},"record()":{"notice":"Records all storage reads and writes. Use `accesses` to get the recorded data. Subsequent calls to `record` will clear the previous data."},"recordLogs()":{"notice":"Record all the transaction logs."},"rememberKey(uint256)":{"notice":"Adds a private key to the local forge wallet and returns the address."},"rememberKeys(string,string,string,uint32)":{"notice":"Derive a set number of wallets from a mnemonic in the specified language at the derivation path `m/44'/60'/0'/0/{0..count}`. The respective private keys are saved to the local forge wallet for later use and their addresses are returned."},"rememberKeys(string,string,uint32)":{"notice":"Derive a set number of wallets from a mnemonic at the derivation path `m/44'/60'/0'/0/{0..count}`. The respective private keys are saved to the local forge wallet for later use and their addresses are returned."},"removeDir(string,bool)":{"notice":"Removes a directory at the provided path. This cheatcode will revert in the following situations, but is not limited to just these cases: - `path` doesn't exist. - `path` isn't a directory. - User lacks permissions to modify `path`. - The directory is not empty and `recursive` is false. `path` is relative to the project root."},"removeFile(string)":{"notice":"Removes a file from the filesystem. This cheatcode will revert in the following situations, but is not limited to just these cases: - `path` points to a directory. - The file doesn't exist. - The user lacks permissions to remove the file. `path` is relative to the project root."},"replace(string,string,string)":{"notice":"Replaces occurrences of `from` in the given `string` with `to`."},"resetGasMetering()":{"notice":"Reset gas metering (i.e. gas usage is set to gas limit)."},"resetNonce(address)":{"notice":"Resets the nonce of an account to 0 for EOAs and 1 for contract accounts."},"resolveEnv(string)":{"notice":"Resolves the env variable placeholders of a given input string."},"resumeGasMetering()":{"notice":"Resumes gas metering (i.e. gas usage is counted again). Noop if already on."},"resumeTracing()":{"notice":"Unpauses collection of call traces."},"revertTo(uint256)":{"notice":"`revertTo` is being deprecated in favor of `revertToState`. It will be removed in future versions."},"revertToAndDelete(uint256)":{"notice":"`revertToAndDelete` is being deprecated in favor of `revertToStateAndDelete`. It will be removed in future versions."},"revertToState(uint256)":{"notice":"Revert the state of the EVM to a previous snapshot Takes the snapshot ID to revert to. Returns `true` if the snapshot was successfully reverted. Returns `false` if the snapshot does not exist. **Note:** This does not automatically delete the snapshot. To delete the snapshot use `deleteStateSnapshot`."},"revertToStateAndDelete(uint256)":{"notice":"Revert the state of the EVM to a previous snapshot and automatically deletes the snapshots Takes the snapshot ID to revert to. Returns `true` if the snapshot was successfully reverted and deleted. Returns `false` if the snapshot does not exist."},"revokePersistent(address)":{"notice":"Revokes persistent status from the address, previously added via `makePersistent`."},"revokePersistent(address[])":{"notice":"See `revokePersistent(address)`."},"roll(uint256)":{"notice":"Sets `block.height`."},"rollFork(bytes32)":{"notice":"Updates the currently active fork to given transaction. This will `rollFork` with the number of the block the transaction was mined in and replays all transaction mined before it in the block."},"rollFork(uint256)":{"notice":"Updates the currently active fork to given block number This is similar to `roll` but for the currently active fork."},"rollFork(uint256,bytes32)":{"notice":"Updates the given fork to block number of the given transaction and replays all transaction mined before it in the block."},"rollFork(uint256,uint256)":{"notice":"Updates the given fork to given block number."},"rpc(string,string)":{"notice":"Performs an Ethereum JSON-RPC request to the current fork URL."},"rpc(string,string,string)":{"notice":"Performs an Ethereum JSON-RPC request to the given endpoint."},"rpcUrl(string)":{"notice":"Returns the RPC url for the given alias."},"rpcUrlStructs()":{"notice":"Returns all rpc urls and their aliases as structs."},"rpcUrls()":{"notice":"Returns all rpc urls and their aliases `[alias, url][]`."},"selectFork(uint256)":{"notice":"Takes a fork identifier created by `createFork` and sets the corresponding forked state as active."},"serializeAddress(string,string,address)":{"notice":"See `serializeJson`."},"serializeAddress(string,string,address[])":{"notice":"See `serializeJson`."},"serializeBool(string,string,bool)":{"notice":"See `serializeJson`."},"serializeBool(string,string,bool[])":{"notice":"See `serializeJson`."},"serializeBytes(string,string,bytes)":{"notice":"See `serializeJson`."},"serializeBytes(string,string,bytes[])":{"notice":"See `serializeJson`."},"serializeBytes32(string,string,bytes32)":{"notice":"See `serializeJson`."},"serializeBytes32(string,string,bytes32[])":{"notice":"See `serializeJson`."},"serializeInt(string,string,int256)":{"notice":"See `serializeJson`."},"serializeInt(string,string,int256[])":{"notice":"See `serializeJson`."},"serializeJson(string,string)":{"notice":"Serializes a key and value to a JSON object stored in-memory that can be later written to a file. Returns the stringified version of the specific JSON file up to that moment."},"serializeJsonType(string,bytes)":{"notice":"See `serializeJson`."},"serializeJsonType(string,string,string,bytes)":{"notice":"See `serializeJson`."},"serializeString(string,string,string)":{"notice":"See `serializeJson`."},"serializeString(string,string,string[])":{"notice":"See `serializeJson`."},"serializeUint(string,string,uint256)":{"notice":"See `serializeJson`."},"serializeUint(string,string,uint256[])":{"notice":"See `serializeJson`."},"serializeUintToHex(string,string,uint256)":{"notice":"See `serializeJson`."},"setArbitraryStorage(address)":{"notice":"Utility cheatcode to set arbitrary storage for given target address."},"setArbitraryStorage(address,bool)":{"notice":"Utility cheatcode to set arbitrary storage for given target address and overwrite any storage slots that have been previously set."},"setBlockhash(uint256,bytes32)":{"notice":"Set blockhash for the current block. It only sets the blockhash for blocks where `block.number - 256 <= number < block.number`."},"setEnv(string,string)":{"notice":"Sets environment variables."},"setNonce(address,uint64)":{"notice":"Sets the nonce of an account. Must be higher than the current nonce of the account."},"setNonceUnsafe(address,uint64)":{"notice":"Sets the nonce of an account to an arbitrary value."},"setSeed(uint256)":{"notice":"Set RNG seed."},"shuffle(uint256[])":{"notice":"Randomly shuffles an array."},"sign((address,uint256,uint256,uint256),bytes32)":{"notice":"Signs data with a `Wallet`."},"sign(address,bytes32)":{"notice":"Signs `digest` with signer provided to script using the secp256k1 curve. Raises error if none of the signers passed into the script have provided address."},"sign(bytes32)":{"notice":"Signs `digest` with signer provided to script using the secp256k1 curve. If `--sender` is provided, the signer with provided address is used, otherwise, if exactly one signer is provided to the script, that signer is used. Raises error if signer passed through `--sender` does not match any unlocked signers or if `--sender` is not provided and not exactly one signer is passed to the script."},"sign(uint256,bytes32)":{"notice":"Signs `digest` with `privateKey` using the secp256k1 curve."},"signAndAttachDelegation(address,uint256)":{"notice":"Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction"},"signAndAttachDelegation(address,uint256,bool)":{"notice":"Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction, with optional cross-chain validity."},"signAndAttachDelegation(address,uint256,uint64)":{"notice":"Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction for specific nonce"},"signCompact((address,uint256,uint256,uint256),bytes32)":{"notice":"Signs data with a `Wallet`. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes."},"signCompact(address,bytes32)":{"notice":"Signs `digest` with signer provided to script using the secp256k1 curve. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes. Raises error if none of the signers passed into the script have provided address."},"signCompact(bytes32)":{"notice":"Signs `digest` with signer provided to script using the secp256k1 curve. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes. If `--sender` is provided, the signer with provided address is used, otherwise, if exactly one signer is provided to the script, that signer is used. Raises error if signer passed through `--sender` does not match any unlocked signers or if `--sender` is not provided and not exactly one signer is passed to the script."},"signCompact(uint256,bytes32)":{"notice":"Signs `digest` with `privateKey` using the secp256k1 curve. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes."},"signDelegation(address,uint256)":{"notice":"Sign an EIP-7702 authorization for delegation"},"signDelegation(address,uint256,bool)":{"notice":"Sign an EIP-7702 authorization for delegation, with optional cross-chain validity."},"signDelegation(address,uint256,uint64)":{"notice":"Sign an EIP-7702 authorization for delegation for specific nonce"},"signP256(uint256,bytes32)":{"notice":"Signs `digest` with `privateKey` using the secp256r1 curve."},"skip(bool)":{"notice":"Marks a test as skipped. Must be called at the top level of a test."},"skip(bool,string)":{"notice":"Marks a test as skipped with a reason. Must be called at the top level of a test."},"sleep(uint256)":{"notice":"Suspends execution of the main thread for `duration` milliseconds."},"snapshot()":{"notice":"`snapshot` is being deprecated in favor of `snapshotState`. It will be removed in future versions."},"snapshotGasLastCall(string)":{"notice":"Snapshot capture the gas usage of the last call by name from the callee perspective."},"snapshotGasLastCall(string,string)":{"notice":"Snapshot capture the gas usage of the last call by name in a group from the callee perspective."},"snapshotState()":{"notice":"Snapshot the current state of the evm. Returns the ID of the snapshot that was created. To revert a snapshot use `revertToState`."},"snapshotValue(string,string,uint256)":{"notice":"Snapshot capture an arbitrary numerical value by name in a group."},"snapshotValue(string,uint256)":{"notice":"Snapshot capture an arbitrary numerical value by name. The group name is derived from the contract name."},"sort(uint256[])":{"notice":"Sorts an array in ascending order."},"split(string,string)":{"notice":"Splits the given `string` into an array of strings divided by the `delimiter`."},"startBroadcast()":{"notice":"Has all subsequent calls (at this call depth only) create transactions that can later be signed and sent onchain. Broadcasting address is determined by checking the following in order: 1. If `--sender` argument was provided, that address is used. 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used."},"startBroadcast(address)":{"notice":"Has all subsequent calls (at this call depth only) create transactions with the address provided that can later be signed and sent onchain."},"startBroadcast(uint256)":{"notice":"Has all subsequent calls (at this call depth only) create transactions with the private key provided that can later be signed and sent onchain."},"startDebugTraceRecording()":{"notice":"Records the debug trace during the run."},"startMappingRecording()":{"notice":"Starts recording all map SSTOREs for later retrieval."},"startPrank(address)":{"notice":"Sets all subsequent calls' `msg.sender` to be the input address until `stopPrank` is called."},"startPrank(address,address)":{"notice":"Sets all subsequent calls' `msg.sender` to be the input address until `stopPrank` is called, and the `tx.origin` to be the second input."},"startPrank(address,address,bool)":{"notice":"Sets all subsequent delegate calls' `msg.sender` to be the input address until `stopPrank` is called, and the `tx.origin` to be the second input."},"startPrank(address,bool)":{"notice":"Sets all subsequent delegate calls' `msg.sender` to be the input address until `stopPrank` is called."},"startSnapshotGas(string)":{"notice":"Start a snapshot capture of the current gas usage by name. The group name is derived from the contract name."},"startSnapshotGas(string,string)":{"notice":"Start a snapshot capture of the current gas usage by name in a group."},"startStateDiffRecording()":{"notice":"Record all account accesses as part of CREATE, CALL or SELFDESTRUCT opcodes in order, along with the context of the calls"},"stopAndReturnDebugTraceRecording()":{"notice":"Stop debug trace recording and returns the recorded debug trace."},"stopAndReturnStateDiff()":{"notice":"Returns an ordered array of all account accesses from a `vm.startStateDiffRecording` session."},"stopBroadcast()":{"notice":"Stops collecting onchain transactions."},"stopExpectSafeMemory()":{"notice":"Stops all safe memory expectation in the current subcontext."},"stopMappingRecording()":{"notice":"Stops recording all map SSTOREs for later retrieval and clears the recorded data."},"stopPrank()":{"notice":"Resets subsequent calls' `msg.sender` to be `address(this)`."},"stopRecord()":{"notice":"Stops recording storage reads and writes."},"stopSnapshotGas()":{"notice":"Stop the snapshot capture of the current gas by latest snapshot name, capturing the gas used since the start."},"stopSnapshotGas(string)":{"notice":"Stop the snapshot capture of the current gas usage by name, capturing the gas used since the start. The group name is derived from the contract name."},"stopSnapshotGas(string,string)":{"notice":"Stop the snapshot capture of the current gas usage by name in a group, capturing the gas used since the start."},"store(address,bytes32,bytes32)":{"notice":"Stores a value to an address' storage slot."},"toBase64(bytes)":{"notice":"Encodes a `bytes` value to a base64 string."},"toBase64(string)":{"notice":"Encodes a `string` value to a base64 string."},"toBase64URL(bytes)":{"notice":"Encodes a `bytes` value to a base64url string."},"toBase64URL(string)":{"notice":"Encodes a `string` value to a base64url string."},"toLowercase(string)":{"notice":"Converts the given `string` value to Lowercase."},"toString(address)":{"notice":"Converts the given value to a `string`."},"toString(bool)":{"notice":"Converts the given value to a `string`."},"toString(bytes)":{"notice":"Converts the given value to a `string`."},"toString(bytes32)":{"notice":"Converts the given value to a `string`."},"toString(int256)":{"notice":"Converts the given value to a `string`."},"toString(uint256)":{"notice":"Converts the given value to a `string`."},"toUppercase(string)":{"notice":"Converts the given `string` value to Uppercase."},"transact(bytes32)":{"notice":"Fetches the given transaction from the active fork and executes it on the current state."},"transact(uint256,bytes32)":{"notice":"Fetches the given transaction from the given fork and executes it on the current state."},"trim(string)":{"notice":"Trims leading and trailing whitespace from the given `string` value."},"tryFfi(string[])":{"notice":"Performs a foreign function call via terminal and returns the exit code, stdout, and stderr."},"txGasPrice(uint256)":{"notice":"Sets `tx.gasprice`."},"unixTime()":{"notice":"Returns the time since unix epoch in milliseconds."},"warmSlot(address,bytes32)":{"notice":"Utility cheatcode to mark specific storage slot as warm, simulating a prior read."},"warp(uint256)":{"notice":"Sets `block.timestamp`."},"writeFile(string,string)":{"notice":"Writes data to file, creating a file if it does not exist, and entirely replacing its contents if it does. `path` is relative to the project root."},"writeFileBinary(string,bytes)":{"notice":"Writes binary data to a file, creating a file if it does not exist, and entirely replacing its contents if it does. `path` is relative to the project root."},"writeJson(string,string)":{"notice":"Write a serialized JSON object to a file. If the file exists, it will be overwritten."},"writeJson(string,string,string)":{"notice":"Write a serialized JSON object to an **existing** JSON file, replacing a value with key = This is useful to replace a specific value of a JSON file, without having to parse the entire thing. This cheatcode will create new keys if they didn't previously exist."},"writeLine(string,string)":{"notice":"Writes line to file, creating a file if it does not exist. `path` is relative to the project root."},"writeToml(string,string)":{"notice":"Takes serialized JSON, converts to TOML and write a serialized TOML to a file."},"writeToml(string,string,string)":{"notice":"Takes serialized JSON, converts to TOML and write a serialized TOML table to an **existing** TOML file, replacing a value with key = This is useful to replace a specific value of a TOML file, without having to parse the entire thing. This cheatcode will create new keys if they didn't previously exist."}},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/Vm.sol":"Vm"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"}},"version":1},"id":14} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/Vm.sol/VmSafe.json b/lib/signals-implicit-mode/out/Vm.sol/VmSafe.json deleted file mode 100644 index 30dcbc34f3..0000000000 --- a/lib/signals-implicit-mode/out/Vm.sol/VmSafe.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"accesses","inputs":[{"name":"target","type":"address","internalType":"address"}],"outputs":[{"name":"readSlots","type":"bytes32[]","internalType":"bytes32[]"},{"name":"writeSlots","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"view"},{"type":"function","name":"addr","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"keyAddr","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbs","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbs","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbs","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbs","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbsDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbsDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbsDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqAbsDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRel","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRel","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRel","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRel","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRelDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRelDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRelDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertApproxEqRelDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"maxPercentDelta","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes32[]","internalType":"bytes32[]"},{"name":"right","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"int256[]","internalType":"int256[]"},{"name":"right","type":"int256[]","internalType":"int256[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"address","internalType":"address"},{"name":"right","type":"address","internalType":"address"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"string","internalType":"string"},{"name":"right","type":"string","internalType":"string"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"address[]","internalType":"address[]"},{"name":"right","type":"address[]","internalType":"address[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"address[]","internalType":"address[]"},{"name":"right","type":"address[]","internalType":"address[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bool","internalType":"bool"},{"name":"right","type":"bool","internalType":"bool"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"address","internalType":"address"},{"name":"right","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"uint256[]","internalType":"uint256[]"},{"name":"right","type":"uint256[]","internalType":"uint256[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bool[]","internalType":"bool[]"},{"name":"right","type":"bool[]","internalType":"bool[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"int256[]","internalType":"int256[]"},{"name":"right","type":"int256[]","internalType":"int256[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes32","internalType":"bytes32"},{"name":"right","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"uint256[]","internalType":"uint256[]"},{"name":"right","type":"uint256[]","internalType":"uint256[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes","internalType":"bytes"},{"name":"right","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes32","internalType":"bytes32"},{"name":"right","type":"bytes32","internalType":"bytes32"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"string[]","internalType":"string[]"},{"name":"right","type":"string[]","internalType":"string[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes32[]","internalType":"bytes32[]"},{"name":"right","type":"bytes32[]","internalType":"bytes32[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes","internalType":"bytes"},{"name":"right","type":"bytes","internalType":"bytes"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bool[]","internalType":"bool[]"},{"name":"right","type":"bool[]","internalType":"bool[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes[]","internalType":"bytes[]"},{"name":"right","type":"bytes[]","internalType":"bytes[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"string[]","internalType":"string[]"},{"name":"right","type":"string[]","internalType":"string[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"string","internalType":"string"},{"name":"right","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bytes[]","internalType":"bytes[]"},{"name":"right","type":"bytes[]","internalType":"bytes[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"bool","internalType":"bool"},{"name":"right","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEq","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEqDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEqDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEqDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertEqDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertFalse","inputs":[{"name":"condition","type":"bool","internalType":"bool"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertFalse","inputs":[{"name":"condition","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGe","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGe","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGe","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGe","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGeDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGeDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGeDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGeDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGt","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGt","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGt","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGt","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGtDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGtDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGtDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertGtDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLe","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLe","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLe","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLe","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLeDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLeDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLeDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLeDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLt","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLt","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLt","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLt","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLtDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLtDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLtDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertLtDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes32[]","internalType":"bytes32[]"},{"name":"right","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"int256[]","internalType":"int256[]"},{"name":"right","type":"int256[]","internalType":"int256[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bool","internalType":"bool"},{"name":"right","type":"bool","internalType":"bool"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes[]","internalType":"bytes[]"},{"name":"right","type":"bytes[]","internalType":"bytes[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bool","internalType":"bool"},{"name":"right","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bool[]","internalType":"bool[]"},{"name":"right","type":"bool[]","internalType":"bool[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes","internalType":"bytes"},{"name":"right","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"address[]","internalType":"address[]"},{"name":"right","type":"address[]","internalType":"address[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"uint256[]","internalType":"uint256[]"},{"name":"right","type":"uint256[]","internalType":"uint256[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bool[]","internalType":"bool[]"},{"name":"right","type":"bool[]","internalType":"bool[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"string","internalType":"string"},{"name":"right","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"address[]","internalType":"address[]"},{"name":"right","type":"address[]","internalType":"address[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"string","internalType":"string"},{"name":"right","type":"string","internalType":"string"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"address","internalType":"address"},{"name":"right","type":"address","internalType":"address"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes32","internalType":"bytes32"},{"name":"right","type":"bytes32","internalType":"bytes32"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes","internalType":"bytes"},{"name":"right","type":"bytes","internalType":"bytes"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"uint256[]","internalType":"uint256[]"},{"name":"right","type":"uint256[]","internalType":"uint256[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"address","internalType":"address"},{"name":"right","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes32","internalType":"bytes32"},{"name":"right","type":"bytes32","internalType":"bytes32"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"string[]","internalType":"string[]"},{"name":"right","type":"string[]","internalType":"string[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes32[]","internalType":"bytes32[]"},{"name":"right","type":"bytes32[]","internalType":"bytes32[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"string[]","internalType":"string[]"},{"name":"right","type":"string[]","internalType":"string[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"int256[]","internalType":"int256[]"},{"name":"right","type":"int256[]","internalType":"int256[]"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"bytes[]","internalType":"bytes[]"},{"name":"right","type":"bytes[]","internalType":"bytes[]"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEq","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEqDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEqDecimal","inputs":[{"name":"left","type":"int256","internalType":"int256"},{"name":"right","type":"int256","internalType":"int256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEqDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertNotEqDecimal","inputs":[{"name":"left","type":"uint256","internalType":"uint256"},{"name":"right","type":"uint256","internalType":"uint256"},{"name":"decimals","type":"uint256","internalType":"uint256"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertTrue","inputs":[{"name":"condition","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assertTrue","inputs":[{"name":"condition","type":"bool","internalType":"bool"},{"name":"error","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assume","inputs":[{"name":"condition","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assumeNoRevert","inputs":[],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assumeNoRevert","inputs":[{"name":"potentialReverts","type":"tuple[]","internalType":"struct VmSafe.PotentialRevert[]","components":[{"name":"reverter","type":"address","internalType":"address"},{"name":"partialMatch","type":"bool","internalType":"bool"},{"name":"revertData","type":"bytes","internalType":"bytes"}]}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"assumeNoRevert","inputs":[{"name":"potentialRevert","type":"tuple","internalType":"struct VmSafe.PotentialRevert","components":[{"name":"reverter","type":"address","internalType":"address"},{"name":"partialMatch","type":"bool","internalType":"bool"},{"name":"revertData","type":"bytes","internalType":"bytes"}]}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"attachBlob","inputs":[{"name":"blob","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"attachDelegation","inputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"attachDelegation","inputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]},{"name":"crossChain","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"bound","inputs":[{"name":"current","type":"uint256","internalType":"uint256"},{"name":"min","type":"uint256","internalType":"uint256"},{"name":"max","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"bound","inputs":[{"name":"current","type":"int256","internalType":"int256"},{"name":"min","type":"int256","internalType":"int256"},{"name":"max","type":"int256","internalType":"int256"}],"outputs":[{"name":"","type":"int256","internalType":"int256"}],"stateMutability":"view"},{"type":"function","name":"breakpoint","inputs":[{"name":"char","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"breakpoint","inputs":[{"name":"char","type":"string","internalType":"string"},{"name":"value","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"pure"},{"type":"function","name":"broadcast","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"broadcast","inputs":[{"name":"signer","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"broadcast","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"broadcastRawTransaction","inputs":[{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"closeFile","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"computeCreate2Address","inputs":[{"name":"salt","type":"bytes32","internalType":"bytes32"},{"name":"initCodeHash","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"computeCreate2Address","inputs":[{"name":"salt","type":"bytes32","internalType":"bytes32"},{"name":"initCodeHash","type":"bytes32","internalType":"bytes32"},{"name":"deployer","type":"address","internalType":"address"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"computeCreateAddress","inputs":[{"name":"deployer","type":"address","internalType":"address"},{"name":"nonce","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"contains","inputs":[{"name":"subject","type":"string","internalType":"string"},{"name":"search","type":"string","internalType":"string"}],"outputs":[{"name":"result","type":"bool","internalType":"bool"}],"stateMutability":"pure"},{"type":"function","name":"copyFile","inputs":[{"name":"from","type":"string","internalType":"string"},{"name":"to","type":"string","internalType":"string"}],"outputs":[{"name":"copied","type":"uint64","internalType":"uint64"}],"stateMutability":"nonpayable"},{"type":"function","name":"copyStorage","inputs":[{"name":"from","type":"address","internalType":"address"},{"name":"to","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"createDir","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"recursive","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"createWallet","inputs":[{"name":"walletLabel","type":"string","internalType":"string"}],"outputs":[{"name":"wallet","type":"tuple","internalType":"struct VmSafe.Wallet","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"},{"name":"privateKey","type":"uint256","internalType":"uint256"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"createWallet","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"wallet","type":"tuple","internalType":"struct VmSafe.Wallet","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"},{"name":"privateKey","type":"uint256","internalType":"uint256"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"createWallet","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"walletLabel","type":"string","internalType":"string"}],"outputs":[{"name":"wallet","type":"tuple","internalType":"struct VmSafe.Wallet","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"},{"name":"privateKey","type":"uint256","internalType":"uint256"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"constructorArgs","type":"bytes","internalType":"bytes"},{"name":"salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"constructorArgs","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"constructorArgs","type":"bytes","internalType":"bytes"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"salt","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deployCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"},{"name":"constructorArgs","type":"bytes","internalType":"bytes"},{"name":"value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"deriveKey","inputs":[{"name":"mnemonic","type":"string","internalType":"string"},{"name":"derivationPath","type":"string","internalType":"string"},{"name":"index","type":"uint32","internalType":"uint32"},{"name":"language","type":"string","internalType":"string"}],"outputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"deriveKey","inputs":[{"name":"mnemonic","type":"string","internalType":"string"},{"name":"index","type":"uint32","internalType":"uint32"},{"name":"language","type":"string","internalType":"string"}],"outputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"deriveKey","inputs":[{"name":"mnemonic","type":"string","internalType":"string"},{"name":"index","type":"uint32","internalType":"uint32"}],"outputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"deriveKey","inputs":[{"name":"mnemonic","type":"string","internalType":"string"},{"name":"derivationPath","type":"string","internalType":"string"},{"name":"index","type":"uint32","internalType":"uint32"}],"outputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"eip712HashStruct","inputs":[{"name":"bindingsPath","type":"string","internalType":"string"},{"name":"typeName","type":"string","internalType":"string"},{"name":"abiEncodedData","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"typeHash","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"eip712HashStruct","inputs":[{"name":"typeNameOrDefinition","type":"string","internalType":"string"},{"name":"abiEncodedData","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"typeHash","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"eip712HashType","inputs":[{"name":"bindingsPath","type":"string","internalType":"string"},{"name":"typeName","type":"string","internalType":"string"}],"outputs":[{"name":"typeHash","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"eip712HashType","inputs":[{"name":"typeNameOrDefinition","type":"string","internalType":"string"}],"outputs":[{"name":"typeHash","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"eip712HashTypedData","inputs":[{"name":"jsonData","type":"string","internalType":"string"}],"outputs":[{"name":"digest","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"ensNamehash","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"envAddress","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"envAddress","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"envBool","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"envBool","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"bool[]","internalType":"bool[]"}],"stateMutability":"view"},{"type":"function","name":"envBytes","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"envBytes","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"bytes[]","internalType":"bytes[]"}],"stateMutability":"view"},{"type":"function","name":"envBytes32","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"view"},{"type":"function","name":"envBytes32","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"envExists","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"result","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"envInt","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"int256[]","internalType":"int256[]"}],"stateMutability":"view"},{"type":"function","name":"envInt","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"int256","internalType":"int256"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[{"name":"value","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"int256[]","internalType":"int256[]"}],"outputs":[{"name":"value","type":"int256[]","internalType":"int256[]"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"bool","internalType":"bool"}],"outputs":[{"name":"value","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"address","internalType":"address"}],"outputs":[{"name":"value","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"value","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"bytes[]","internalType":"bytes[]"}],"outputs":[{"name":"value","type":"bytes[]","internalType":"bytes[]"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"uint256[]","internalType":"uint256[]"}],"outputs":[{"name":"value","type":"uint256[]","internalType":"uint256[]"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"string[]","internalType":"string[]"}],"outputs":[{"name":"value","type":"string[]","internalType":"string[]"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"value","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"value","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"int256","internalType":"int256"}],"outputs":[{"name":"value","type":"int256","internalType":"int256"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"address[]","internalType":"address[]"}],"outputs":[{"name":"value","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"defaultValue","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"envOr","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"},{"name":"defaultValue","type":"bool[]","internalType":"bool[]"}],"outputs":[{"name":"value","type":"bool[]","internalType":"bool[]"}],"stateMutability":"view"},{"type":"function","name":"envString","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"string[]","internalType":"string[]"}],"stateMutability":"view"},{"type":"function","name":"envString","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"envUint","inputs":[{"name":"name","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"envUint","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"delim","type":"string","internalType":"string"}],"outputs":[{"name":"value","type":"uint256[]","internalType":"uint256[]"}],"stateMutability":"view"},{"type":"function","name":"eth_getLogs","inputs":[{"name":"fromBlock","type":"uint256","internalType":"uint256"},{"name":"toBlock","type":"uint256","internalType":"uint256"},{"name":"target","type":"address","internalType":"address"},{"name":"topics","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[{"name":"logs","type":"tuple[]","internalType":"struct VmSafe.EthGetLogs[]","components":[{"name":"emitter","type":"address","internalType":"address"},{"name":"topics","type":"bytes32[]","internalType":"bytes32[]"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"blockHash","type":"bytes32","internalType":"bytes32"},{"name":"blockNumber","type":"uint64","internalType":"uint64"},{"name":"transactionHash","type":"bytes32","internalType":"bytes32"},{"name":"transactionIndex","type":"uint64","internalType":"uint64"},{"name":"logIndex","type":"uint256","internalType":"uint256"},{"name":"removed","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"exists","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"result","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"ffi","inputs":[{"name":"commandInput","type":"string[]","internalType":"string[]"}],"outputs":[{"name":"result","type":"bytes","internalType":"bytes"}],"stateMutability":"nonpayable"},{"type":"function","name":"foundryVersionAtLeast","inputs":[{"name":"version","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"foundryVersionCmp","inputs":[{"name":"version","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"int256","internalType":"int256"}],"stateMutability":"view"},{"type":"function","name":"fsMetadata","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"metadata","type":"tuple","internalType":"struct VmSafe.FsMetadata","components":[{"name":"isDir","type":"bool","internalType":"bool"},{"name":"isSymlink","type":"bool","internalType":"bool"},{"name":"length","type":"uint256","internalType":"uint256"},{"name":"readOnly","type":"bool","internalType":"bool"},{"name":"modified","type":"uint256","internalType":"uint256"},{"name":"accessed","type":"uint256","internalType":"uint256"},{"name":"created","type":"uint256","internalType":"uint256"}]}],"stateMutability":"view"},{"type":"function","name":"getArtifactPathByCode","inputs":[{"name":"code","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"path","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"getArtifactPathByDeployedCode","inputs":[{"name":"deployedCode","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"path","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"getBlobBaseFee","inputs":[],"outputs":[{"name":"blobBaseFee","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getBlockNumber","inputs":[],"outputs":[{"name":"height","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getBlockTimestamp","inputs":[],"outputs":[{"name":"timestamp","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getBroadcast","inputs":[{"name":"contractName","type":"string","internalType":"string"},{"name":"chainId","type":"uint64","internalType":"uint64"},{"name":"txType","type":"uint8","internalType":"enum VmSafe.BroadcastTxType"}],"outputs":[{"name":"","type":"tuple","internalType":"struct VmSafe.BroadcastTxSummary","components":[{"name":"txHash","type":"bytes32","internalType":"bytes32"},{"name":"txType","type":"uint8","internalType":"enum VmSafe.BroadcastTxType"},{"name":"contractAddress","type":"address","internalType":"address"},{"name":"blockNumber","type":"uint64","internalType":"uint64"},{"name":"success","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"getBroadcasts","inputs":[{"name":"contractName","type":"string","internalType":"string"},{"name":"chainId","type":"uint64","internalType":"uint64"}],"outputs":[{"name":"","type":"tuple[]","internalType":"struct VmSafe.BroadcastTxSummary[]","components":[{"name":"txHash","type":"bytes32","internalType":"bytes32"},{"name":"txType","type":"uint8","internalType":"enum VmSafe.BroadcastTxType"},{"name":"contractAddress","type":"address","internalType":"address"},{"name":"blockNumber","type":"uint64","internalType":"uint64"},{"name":"success","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"getBroadcasts","inputs":[{"name":"contractName","type":"string","internalType":"string"},{"name":"chainId","type":"uint64","internalType":"uint64"},{"name":"txType","type":"uint8","internalType":"enum VmSafe.BroadcastTxType"}],"outputs":[{"name":"","type":"tuple[]","internalType":"struct VmSafe.BroadcastTxSummary[]","components":[{"name":"txHash","type":"bytes32","internalType":"bytes32"},{"name":"txType","type":"uint8","internalType":"enum VmSafe.BroadcastTxType"},{"name":"contractAddress","type":"address","internalType":"address"},{"name":"blockNumber","type":"uint64","internalType":"uint64"},{"name":"success","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"getChain","inputs":[{"name":"chainAlias","type":"string","internalType":"string"}],"outputs":[{"name":"chain","type":"tuple","internalType":"struct VmSafe.Chain","components":[{"name":"name","type":"string","internalType":"string"},{"name":"chainId","type":"uint256","internalType":"uint256"},{"name":"chainAlias","type":"string","internalType":"string"},{"name":"rpcUrl","type":"string","internalType":"string"}]}],"stateMutability":"view"},{"type":"function","name":"getChain","inputs":[{"name":"chainId","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"chain","type":"tuple","internalType":"struct VmSafe.Chain","components":[{"name":"name","type":"string","internalType":"string"},{"name":"chainId","type":"uint256","internalType":"uint256"},{"name":"chainAlias","type":"string","internalType":"string"},{"name":"rpcUrl","type":"string","internalType":"string"}]}],"stateMutability":"view"},{"type":"function","name":"getChainId","inputs":[],"outputs":[{"name":"blockChainId","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"}],"outputs":[{"name":"creationBytecode","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"getDeployedCode","inputs":[{"name":"artifactPath","type":"string","internalType":"string"}],"outputs":[{"name":"runtimeBytecode","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"getDeployment","inputs":[{"name":"contractName","type":"string","internalType":"string"},{"name":"chainId","type":"uint64","internalType":"uint64"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"getDeployment","inputs":[{"name":"contractName","type":"string","internalType":"string"}],"outputs":[{"name":"deployedAddress","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"getDeployments","inputs":[{"name":"contractName","type":"string","internalType":"string"},{"name":"chainId","type":"uint64","internalType":"uint64"}],"outputs":[{"name":"deployedAddresses","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"getFoundryVersion","inputs":[],"outputs":[{"name":"version","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"getLabel","inputs":[{"name":"account","type":"address","internalType":"address"}],"outputs":[{"name":"currentLabel","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"getMappingKeyAndParentOf","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"elementSlot","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"found","type":"bool","internalType":"bool"},{"name":"key","type":"bytes32","internalType":"bytes32"},{"name":"parent","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"getMappingLength","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"mappingSlot","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"length","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"getMappingSlotAt","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"mappingSlot","type":"bytes32","internalType":"bytes32"},{"name":"idx","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"value","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"getNonce","inputs":[{"name":"account","type":"address","internalType":"address"}],"outputs":[{"name":"nonce","type":"uint64","internalType":"uint64"}],"stateMutability":"view"},{"type":"function","name":"getNonce","inputs":[{"name":"wallet","type":"tuple","internalType":"struct VmSafe.Wallet","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"},{"name":"privateKey","type":"uint256","internalType":"uint256"}]}],"outputs":[{"name":"nonce","type":"uint64","internalType":"uint64"}],"stateMutability":"view"},{"type":"function","name":"getRawBlockHeader","inputs":[{"name":"blockNumber","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"rlpHeader","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"getRecordedLogs","inputs":[],"outputs":[{"name":"logs","type":"tuple[]","internalType":"struct VmSafe.Log[]","components":[{"name":"topics","type":"bytes32[]","internalType":"bytes32[]"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"emitter","type":"address","internalType":"address"}]}],"stateMutability":"view"},{"type":"function","name":"getStateDiff","inputs":[],"outputs":[{"name":"diff","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"getStateDiffJson","inputs":[],"outputs":[{"name":"diff","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"getStorageAccesses","inputs":[],"outputs":[{"name":"storageAccesses","type":"tuple[]","internalType":"struct VmSafe.StorageAccess[]","components":[{"name":"account","type":"address","internalType":"address"},{"name":"slot","type":"bytes32","internalType":"bytes32"},{"name":"isWrite","type":"bool","internalType":"bool"},{"name":"previousValue","type":"bytes32","internalType":"bytes32"},{"name":"newValue","type":"bytes32","internalType":"bytes32"},{"name":"reverted","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"getWallets","inputs":[],"outputs":[{"name":"wallets","type":"address[]","internalType":"address[]"}],"stateMutability":"view"},{"type":"function","name":"indexOf","inputs":[{"name":"input","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"isContext","inputs":[{"name":"context","type":"uint8","internalType":"enum VmSafe.ForgeContext"}],"outputs":[{"name":"result","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"isDir","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"result","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"isFile","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"result","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"keyExists","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"keyExistsJson","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"keyExistsToml","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"label","inputs":[{"name":"account","type":"address","internalType":"address"},{"name":"newLabel","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"lastCallGas","inputs":[],"outputs":[{"name":"gas","type":"tuple","internalType":"struct VmSafe.Gas","components":[{"name":"gasLimit","type":"uint64","internalType":"uint64"},{"name":"gasTotalUsed","type":"uint64","internalType":"uint64"},{"name":"gasMemoryUsed","type":"uint64","internalType":"uint64"},{"name":"gasRefunded","type":"int64","internalType":"int64"},{"name":"gasRemaining","type":"uint64","internalType":"uint64"}]}],"stateMutability":"view"},{"type":"function","name":"load","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"slot","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"data","type":"bytes32","internalType":"bytes32"}],"stateMutability":"view"},{"type":"function","name":"parseAddress","inputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"outputs":[{"name":"parsedValue","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"parseBool","inputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"outputs":[{"name":"parsedValue","type":"bool","internalType":"bool"}],"stateMutability":"pure"},{"type":"function","name":"parseBytes","inputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"outputs":[{"name":"parsedValue","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseBytes32","inputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"outputs":[{"name":"parsedValue","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"parseInt","inputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"outputs":[{"name":"parsedValue","type":"int256","internalType":"int256"}],"stateMutability":"pure"},{"type":"function","name":"parseJson","inputs":[{"name":"json","type":"string","internalType":"string"}],"outputs":[{"name":"abiEncodedData","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseJson","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"abiEncodedData","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonAddress","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonAddressArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address[]","internalType":"address[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonBool","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonBoolArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool[]","internalType":"bool[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonBytes","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonBytes32","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonBytes32Array","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonBytesArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes[]","internalType":"bytes[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonInt","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"int256","internalType":"int256"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonIntArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"int256[]","internalType":"int256[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonKeys","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"keys","type":"string[]","internalType":"string[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonString","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonStringArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string[]","internalType":"string[]"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonType","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonType","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonTypeArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonUint","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"parseJsonUintArray","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256[]","internalType":"uint256[]"}],"stateMutability":"pure"},{"type":"function","name":"parseToml","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"abiEncodedData","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseToml","inputs":[{"name":"toml","type":"string","internalType":"string"}],"outputs":[{"name":"abiEncodedData","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlAddress","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlAddressArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address[]","internalType":"address[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlBool","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlBoolArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bool[]","internalType":"bool[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlBytes","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlBytes32","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlBytes32Array","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes32[]","internalType":"bytes32[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlBytesArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes[]","internalType":"bytes[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlInt","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"int256","internalType":"int256"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlIntArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"int256[]","internalType":"int256[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlKeys","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"keys","type":"string[]","internalType":"string[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlString","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlStringArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string[]","internalType":"string[]"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlType","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlType","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlTypeArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlUint","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"parseTomlUintArray","inputs":[{"name":"toml","type":"string","internalType":"string"},{"name":"key","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256[]","internalType":"uint256[]"}],"stateMutability":"pure"},{"type":"function","name":"parseUint","inputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"outputs":[{"name":"parsedValue","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"pauseGasMetering","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"pauseTracing","inputs":[],"outputs":[],"stateMutability":"view"},{"type":"function","name":"projectRoot","inputs":[],"outputs":[{"name":"path","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"prompt","inputs":[{"name":"promptText","type":"string","internalType":"string"}],"outputs":[{"name":"input","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"promptAddress","inputs":[{"name":"promptText","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"promptSecret","inputs":[{"name":"promptText","type":"string","internalType":"string"}],"outputs":[{"name":"input","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"promptSecretUint","inputs":[{"name":"promptText","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"promptUint","inputs":[{"name":"promptText","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"publicKeyP256","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"}],"stateMutability":"pure"},{"type":"function","name":"randomAddress","inputs":[],"outputs":[{"name":"","type":"address","internalType":"address"}],"stateMutability":"view"},{"type":"function","name":"randomBool","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"randomBytes","inputs":[{"name":"len","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"randomBytes4","inputs":[],"outputs":[{"name":"","type":"bytes4","internalType":"bytes4"}],"stateMutability":"view"},{"type":"function","name":"randomBytes8","inputs":[],"outputs":[{"name":"","type":"bytes8","internalType":"bytes8"}],"stateMutability":"view"},{"type":"function","name":"randomInt","inputs":[],"outputs":[{"name":"","type":"int256","internalType":"int256"}],"stateMutability":"view"},{"type":"function","name":"randomInt","inputs":[{"name":"bits","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"int256","internalType":"int256"}],"stateMutability":"view"},{"type":"function","name":"randomUint","inputs":[],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"randomUint","inputs":[{"name":"bits","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"randomUint","inputs":[{"name":"min","type":"uint256","internalType":"uint256"},{"name":"max","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"readDir","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"maxDepth","type":"uint64","internalType":"uint64"}],"outputs":[{"name":"entries","type":"tuple[]","internalType":"struct VmSafe.DirEntry[]","components":[{"name":"errorMessage","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"},{"name":"depth","type":"uint64","internalType":"uint64"},{"name":"isDir","type":"bool","internalType":"bool"},{"name":"isSymlink","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"readDir","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"maxDepth","type":"uint64","internalType":"uint64"},{"name":"followLinks","type":"bool","internalType":"bool"}],"outputs":[{"name":"entries","type":"tuple[]","internalType":"struct VmSafe.DirEntry[]","components":[{"name":"errorMessage","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"},{"name":"depth","type":"uint64","internalType":"uint64"},{"name":"isDir","type":"bool","internalType":"bool"},{"name":"isSymlink","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"readDir","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"entries","type":"tuple[]","internalType":"struct VmSafe.DirEntry[]","components":[{"name":"errorMessage","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"},{"name":"depth","type":"uint64","internalType":"uint64"},{"name":"isDir","type":"bool","internalType":"bool"},{"name":"isSymlink","type":"bool","internalType":"bool"}]}],"stateMutability":"view"},{"type":"function","name":"readFile","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"data","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"readFileBinary","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"data","type":"bytes","internalType":"bytes"}],"stateMutability":"view"},{"type":"function","name":"readLine","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[{"name":"line","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"readLink","inputs":[{"name":"linkPath","type":"string","internalType":"string"}],"outputs":[{"name":"targetPath","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"record","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"recordLogs","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"rememberKey","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"keyAddr","type":"address","internalType":"address"}],"stateMutability":"nonpayable"},{"type":"function","name":"rememberKeys","inputs":[{"name":"mnemonic","type":"string","internalType":"string"},{"name":"derivationPath","type":"string","internalType":"string"},{"name":"count","type":"uint32","internalType":"uint32"}],"outputs":[{"name":"keyAddrs","type":"address[]","internalType":"address[]"}],"stateMutability":"nonpayable"},{"type":"function","name":"rememberKeys","inputs":[{"name":"mnemonic","type":"string","internalType":"string"},{"name":"derivationPath","type":"string","internalType":"string"},{"name":"language","type":"string","internalType":"string"},{"name":"count","type":"uint32","internalType":"uint32"}],"outputs":[{"name":"keyAddrs","type":"address[]","internalType":"address[]"}],"stateMutability":"nonpayable"},{"type":"function","name":"removeDir","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"recursive","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"removeFile","inputs":[{"name":"path","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"replace","inputs":[{"name":"input","type":"string","internalType":"string"},{"name":"from","type":"string","internalType":"string"},{"name":"to","type":"string","internalType":"string"}],"outputs":[{"name":"output","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"resetGasMetering","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"resolveEnv","inputs":[{"name":"input","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"resumeGasMetering","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"resumeTracing","inputs":[],"outputs":[],"stateMutability":"view"},{"type":"function","name":"rpc","inputs":[{"name":"urlOrAlias","type":"string","internalType":"string"},{"name":"method","type":"string","internalType":"string"},{"name":"params","type":"string","internalType":"string"}],"outputs":[{"name":"data","type":"bytes","internalType":"bytes"}],"stateMutability":"nonpayable"},{"type":"function","name":"rpc","inputs":[{"name":"method","type":"string","internalType":"string"},{"name":"params","type":"string","internalType":"string"}],"outputs":[{"name":"data","type":"bytes","internalType":"bytes"}],"stateMutability":"nonpayable"},{"type":"function","name":"rpcUrl","inputs":[{"name":"rpcAlias","type":"string","internalType":"string"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"view"},{"type":"function","name":"rpcUrlStructs","inputs":[],"outputs":[{"name":"urls","type":"tuple[]","internalType":"struct VmSafe.Rpc[]","components":[{"name":"key","type":"string","internalType":"string"},{"name":"url","type":"string","internalType":"string"}]}],"stateMutability":"view"},{"type":"function","name":"rpcUrls","inputs":[],"outputs":[{"name":"urls","type":"string[2][]","internalType":"string[2][]"}],"stateMutability":"view"},{"type":"function","name":"serializeAddress","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"address[]","internalType":"address[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeAddress","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"address","internalType":"address"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeBool","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"bool[]","internalType":"bool[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeBool","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"bool","internalType":"bool"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeBytes","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"bytes[]","internalType":"bytes[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeBytes","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeBytes32","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"bytes32[]","internalType":"bytes32[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeBytes32","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeInt","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"int256","internalType":"int256"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeInt","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"int256[]","internalType":"int256[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeJson","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"value","type":"string","internalType":"string"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeJsonType","inputs":[{"name":"typeDescription","type":"string","internalType":"string"},{"name":"value","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"serializeJsonType","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"typeDescription","type":"string","internalType":"string"},{"name":"value","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeString","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"string[]","internalType":"string[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeString","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"string","internalType":"string"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeUint","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeUint","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"values","type":"uint256[]","internalType":"uint256[]"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"serializeUintToHex","inputs":[{"name":"objectKey","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"},{"name":"value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"json","type":"string","internalType":"string"}],"stateMutability":"nonpayable"},{"type":"function","name":"setArbitraryStorage","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"overwrite","type":"bool","internalType":"bool"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"setArbitraryStorage","inputs":[{"name":"target","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"setEnv","inputs":[{"name":"name","type":"string","internalType":"string"},{"name":"value","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"setSeed","inputs":[{"name":"seed","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"shuffle","inputs":[{"name":"array","type":"uint256[]","internalType":"uint256[]"}],"outputs":[{"name":"","type":"uint256[]","internalType":"uint256[]"}],"stateMutability":"nonpayable"},{"type":"function","name":"sign","inputs":[{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"sign","inputs":[{"name":"signer","type":"address","internalType":"address"},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"sign","inputs":[{"name":"wallet","type":"tuple","internalType":"struct VmSafe.Wallet","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"},{"name":"privateKey","type":"uint256","internalType":"uint256"}]},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"}],"stateMutability":"nonpayable"},{"type":"function","name":"sign","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"signAndAttachDelegation","inputs":[{"name":"implementation","type":"address","internalType":"address"},{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"signAndAttachDelegation","inputs":[{"name":"implementation","type":"address","internalType":"address"},{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"nonce","type":"uint64","internalType":"uint64"}],"outputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"signAndAttachDelegation","inputs":[{"name":"implementation","type":"address","internalType":"address"},{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"crossChain","type":"bool","internalType":"bool"}],"outputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"signCompact","inputs":[{"name":"wallet","type":"tuple","internalType":"struct VmSafe.Wallet","components":[{"name":"addr","type":"address","internalType":"address"},{"name":"publicKeyX","type":"uint256","internalType":"uint256"},{"name":"publicKeyY","type":"uint256","internalType":"uint256"},{"name":"privateKey","type":"uint256","internalType":"uint256"}]},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"vs","type":"bytes32","internalType":"bytes32"}],"stateMutability":"nonpayable"},{"type":"function","name":"signCompact","inputs":[{"name":"signer","type":"address","internalType":"address"},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"vs","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"signCompact","inputs":[{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"vs","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"signCompact","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"vs","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"signDelegation","inputs":[{"name":"implementation","type":"address","internalType":"address"},{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"signDelegation","inputs":[{"name":"implementation","type":"address","internalType":"address"},{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"crossChain","type":"bool","internalType":"bool"}],"outputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"signDelegation","inputs":[{"name":"implementation","type":"address","internalType":"address"},{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"nonce","type":"uint64","internalType":"uint64"}],"outputs":[{"name":"signedDelegation","type":"tuple","internalType":"struct VmSafe.SignedDelegation","components":[{"name":"v","type":"uint8","internalType":"uint8"},{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"},{"name":"nonce","type":"uint64","internalType":"uint64"},{"name":"implementation","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"signP256","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"},{"name":"digest","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"r","type":"bytes32","internalType":"bytes32"},{"name":"s","type":"bytes32","internalType":"bytes32"}],"stateMutability":"pure"},{"type":"function","name":"sleep","inputs":[{"name":"duration","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"sort","inputs":[{"name":"array","type":"uint256[]","internalType":"uint256[]"}],"outputs":[{"name":"","type":"uint256[]","internalType":"uint256[]"}],"stateMutability":"nonpayable"},{"type":"function","name":"split","inputs":[{"name":"input","type":"string","internalType":"string"},{"name":"delimiter","type":"string","internalType":"string"}],"outputs":[{"name":"outputs","type":"string[]","internalType":"string[]"}],"stateMutability":"pure"},{"type":"function","name":"startBroadcast","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startBroadcast","inputs":[{"name":"signer","type":"address","internalType":"address"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startBroadcast","inputs":[{"name":"privateKey","type":"uint256","internalType":"uint256"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startDebugTraceRecording","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startMappingRecording","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"startStateDiffRecording","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"stopAndReturnDebugTraceRecording","inputs":[],"outputs":[{"name":"step","type":"tuple[]","internalType":"struct VmSafe.DebugStep[]","components":[{"name":"stack","type":"uint256[]","internalType":"uint256[]"},{"name":"memoryInput","type":"bytes","internalType":"bytes"},{"name":"opcode","type":"uint8","internalType":"uint8"},{"name":"depth","type":"uint64","internalType":"uint64"},{"name":"isOutOfGas","type":"bool","internalType":"bool"},{"name":"contractAddr","type":"address","internalType":"address"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"stopAndReturnStateDiff","inputs":[],"outputs":[{"name":"accountAccesses","type":"tuple[]","internalType":"struct VmSafe.AccountAccess[]","components":[{"name":"chainInfo","type":"tuple","internalType":"struct VmSafe.ChainInfo","components":[{"name":"forkId","type":"uint256","internalType":"uint256"},{"name":"chainId","type":"uint256","internalType":"uint256"}]},{"name":"kind","type":"uint8","internalType":"enum VmSafe.AccountAccessKind"},{"name":"account","type":"address","internalType":"address"},{"name":"accessor","type":"address","internalType":"address"},{"name":"initialized","type":"bool","internalType":"bool"},{"name":"oldBalance","type":"uint256","internalType":"uint256"},{"name":"newBalance","type":"uint256","internalType":"uint256"},{"name":"deployedCode","type":"bytes","internalType":"bytes"},{"name":"value","type":"uint256","internalType":"uint256"},{"name":"data","type":"bytes","internalType":"bytes"},{"name":"reverted","type":"bool","internalType":"bool"},{"name":"storageAccesses","type":"tuple[]","internalType":"struct VmSafe.StorageAccess[]","components":[{"name":"account","type":"address","internalType":"address"},{"name":"slot","type":"bytes32","internalType":"bytes32"},{"name":"isWrite","type":"bool","internalType":"bool"},{"name":"previousValue","type":"bytes32","internalType":"bytes32"},{"name":"newValue","type":"bytes32","internalType":"bytes32"},{"name":"reverted","type":"bool","internalType":"bool"}]},{"name":"depth","type":"uint64","internalType":"uint64"},{"name":"oldNonce","type":"uint64","internalType":"uint64"},{"name":"newNonce","type":"uint64","internalType":"uint64"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"stopBroadcast","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"stopMappingRecording","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"stopRecord","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"toBase64","inputs":[{"name":"data","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toBase64","inputs":[{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toBase64URL","inputs":[{"name":"data","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toBase64URL","inputs":[{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toLowercase","inputs":[{"name":"input","type":"string","internalType":"string"}],"outputs":[{"name":"output","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toString","inputs":[{"name":"value","type":"address","internalType":"address"}],"outputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toString","inputs":[{"name":"value","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toString","inputs":[{"name":"value","type":"bytes","internalType":"bytes"}],"outputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toString","inputs":[{"name":"value","type":"bool","internalType":"bool"}],"outputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toString","inputs":[{"name":"value","type":"int256","internalType":"int256"}],"outputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toString","inputs":[{"name":"value","type":"bytes32","internalType":"bytes32"}],"outputs":[{"name":"stringifiedValue","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"toUppercase","inputs":[{"name":"input","type":"string","internalType":"string"}],"outputs":[{"name":"output","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"trim","inputs":[{"name":"input","type":"string","internalType":"string"}],"outputs":[{"name":"output","type":"string","internalType":"string"}],"stateMutability":"pure"},{"type":"function","name":"tryFfi","inputs":[{"name":"commandInput","type":"string[]","internalType":"string[]"}],"outputs":[{"name":"result","type":"tuple","internalType":"struct VmSafe.FfiResult","components":[{"name":"exitCode","type":"int32","internalType":"int32"},{"name":"stdout","type":"bytes","internalType":"bytes"},{"name":"stderr","type":"bytes","internalType":"bytes"}]}],"stateMutability":"nonpayable"},{"type":"function","name":"unixTime","inputs":[],"outputs":[{"name":"milliseconds","type":"uint256","internalType":"uint256"}],"stateMutability":"view"},{"type":"function","name":"writeFile","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"data","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeFileBinary","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"data","type":"bytes","internalType":"bytes"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeJson","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeJson","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeLine","inputs":[{"name":"path","type":"string","internalType":"string"},{"name":"data","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeToml","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"},{"name":"valueKey","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"},{"type":"function","name":"writeToml","inputs":[{"name":"json","type":"string","internalType":"string"},{"name":"path","type":"string","internalType":"string"}],"outputs":[],"stateMutability":"nonpayable"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"accesses(address)":"65bc9481","addr(uint256)":"ffa18649","assertApproxEqAbs(int256,int256,uint256)":"240f839d","assertApproxEqAbs(int256,int256,uint256,string)":"8289e621","assertApproxEqAbs(uint256,uint256,uint256)":"16d207c6","assertApproxEqAbs(uint256,uint256,uint256,string)":"f710b062","assertApproxEqAbsDecimal(int256,int256,uint256,uint256)":"3d5bc8bc","assertApproxEqAbsDecimal(int256,int256,uint256,uint256,string)":"6a5066d4","assertApproxEqAbsDecimal(uint256,uint256,uint256,uint256)":"045c55ce","assertApproxEqAbsDecimal(uint256,uint256,uint256,uint256,string)":"60429eb2","assertApproxEqRel(int256,int256,uint256)":"fea2d14f","assertApproxEqRel(int256,int256,uint256,string)":"ef277d72","assertApproxEqRel(uint256,uint256,uint256)":"8cf25ef4","assertApproxEqRel(uint256,uint256,uint256,string)":"1ecb7d33","assertApproxEqRelDecimal(int256,int256,uint256,uint256)":"abbf21cc","assertApproxEqRelDecimal(int256,int256,uint256,uint256,string)":"fccc11c4","assertApproxEqRelDecimal(uint256,uint256,uint256,uint256)":"21ed2977","assertApproxEqRelDecimal(uint256,uint256,uint256,uint256,string)":"82d6c8fd","assertEq(address,address)":"515361f6","assertEq(address,address,string)":"2f2769d1","assertEq(address[],address[])":"3868ac34","assertEq(address[],address[],string)":"3e9173c5","assertEq(bool,bool)":"f7fe3477","assertEq(bool,bool,string)":"4db19e7e","assertEq(bool[],bool[])":"707df785","assertEq(bool[],bool[],string)":"e48a8f8d","assertEq(bytes,bytes)":"97624631","assertEq(bytes,bytes,string)":"e24fed00","assertEq(bytes32,bytes32)":"7c84c69b","assertEq(bytes32,bytes32,string)":"c1fa1ed0","assertEq(bytes32[],bytes32[])":"0cc9ee84","assertEq(bytes32[],bytes32[],string)":"e03e9177","assertEq(bytes[],bytes[])":"e5fb9b4a","assertEq(bytes[],bytes[],string)":"f413f0b6","assertEq(int256,int256)":"fe74f05b","assertEq(int256,int256,string)":"714a2f13","assertEq(int256[],int256[])":"711043ac","assertEq(int256[],int256[],string)":"191f1b30","assertEq(string,string)":"f320d963","assertEq(string,string,string)":"36f656d8","assertEq(string[],string[])":"cf1c049c","assertEq(string[],string[],string)":"eff6b27d","assertEq(uint256,uint256)":"98296c54","assertEq(uint256,uint256,string)":"88b44c85","assertEq(uint256[],uint256[])":"975d5a12","assertEq(uint256[],uint256[],string)":"5d18c73a","assertEqDecimal(int256,int256,uint256)":"48016c04","assertEqDecimal(int256,int256,uint256,string)":"7e77b0c5","assertEqDecimal(uint256,uint256,uint256)":"27af7d9c","assertEqDecimal(uint256,uint256,uint256,string)":"d0cbbdef","assertFalse(bool)":"a5982885","assertFalse(bool,string)":"7ba04809","assertGe(int256,int256)":"0a30b771","assertGe(int256,int256,string)":"a84328dd","assertGe(uint256,uint256)":"a8d4d1d9","assertGe(uint256,uint256,string)":"e25242c0","assertGeDecimal(int256,int256,uint256)":"dc28c0f1","assertGeDecimal(int256,int256,uint256,string)":"5df93c9b","assertGeDecimal(uint256,uint256,uint256)":"3d1fe08a","assertGeDecimal(uint256,uint256,uint256,string)":"8bff9133","assertGt(int256,int256)":"5a362d45","assertGt(int256,int256,string)":"f8d33b9b","assertGt(uint256,uint256)":"db07fcd2","assertGt(uint256,uint256,string)":"d9a3c4d2","assertGtDecimal(int256,int256,uint256)":"78611f0e","assertGtDecimal(int256,int256,uint256,string)":"04a5c7ab","assertGtDecimal(uint256,uint256,uint256)":"eccd2437","assertGtDecimal(uint256,uint256,uint256,string)":"64949a8d","assertLe(int256,int256)":"95fd154e","assertLe(int256,int256,string)":"4dfe692c","assertLe(uint256,uint256)":"8466f415","assertLe(uint256,uint256,string)":"d17d4b0d","assertLeDecimal(int256,int256,uint256)":"11d1364a","assertLeDecimal(int256,int256,uint256,string)":"aa5cf788","assertLeDecimal(uint256,uint256,uint256)":"c304aab7","assertLeDecimal(uint256,uint256,uint256,string)":"7fefbbe0","assertLt(int256,int256)":"3e914080","assertLt(int256,int256,string)":"9ff531e3","assertLt(uint256,uint256)":"b12fc005","assertLt(uint256,uint256,string)":"65d5c135","assertLtDecimal(int256,int256,uint256)":"dbe8d88b","assertLtDecimal(int256,int256,uint256,string)":"40f0b4e0","assertLtDecimal(uint256,uint256,uint256)":"2077337e","assertLtDecimal(uint256,uint256,uint256,string)":"a972d037","assertNotEq(address,address)":"b12e1694","assertNotEq(address,address,string)":"8775a591","assertNotEq(address[],address[])":"46d0b252","assertNotEq(address[],address[],string)":"72c7e0b5","assertNotEq(bool,bool)":"236e4d66","assertNotEq(bool,bool,string)":"1091a261","assertNotEq(bool[],bool[])":"286fafea","assertNotEq(bool[],bool[],string)":"62c6f9fb","assertNotEq(bytes,bytes)":"3cf78e28","assertNotEq(bytes,bytes,string)":"9507540e","assertNotEq(bytes32,bytes32)":"898e83fc","assertNotEq(bytes32,bytes32,string)":"b2332f51","assertNotEq(bytes32[],bytes32[])":"0603ea68","assertNotEq(bytes32[],bytes32[],string)":"b873634c","assertNotEq(bytes[],bytes[])":"edecd035","assertNotEq(bytes[],bytes[],string)":"1dcd1f68","assertNotEq(int256,int256)":"f4c004e3","assertNotEq(int256,int256,string)":"4724c5b9","assertNotEq(int256[],int256[])":"0b72f4ef","assertNotEq(int256[],int256[],string)":"d3977322","assertNotEq(string,string)":"6a8237b3","assertNotEq(string,string,string)":"78bdcea7","assertNotEq(string[],string[])":"bdfacbe8","assertNotEq(string[],string[],string)":"b67187f3","assertNotEq(uint256,uint256)":"b7909320","assertNotEq(uint256,uint256,string)":"98f9bdbd","assertNotEq(uint256[],uint256[])":"56f29cba","assertNotEq(uint256[],uint256[],string)":"9a7fbd8f","assertNotEqDecimal(int256,int256,uint256)":"14e75680","assertNotEqDecimal(int256,int256,uint256,string)":"33949f0b","assertNotEqDecimal(uint256,uint256,uint256)":"669efca7","assertNotEqDecimal(uint256,uint256,uint256,string)":"f5a55558","assertTrue(bool)":"0c9fd581","assertTrue(bool,string)":"a34edc03","assume(bool)":"4c63e562","assumeNoRevert((address,bool,bytes))":"d8591eeb","assumeNoRevert((address,bool,bytes)[])":"8a4592cc","assumeNoRevert()":"285b366a","attachBlob(bytes)":"10cb385c","attachDelegation((uint8,bytes32,bytes32,uint64,address))":"14ae3519","attachDelegation((uint8,bytes32,bytes32,uint64,address),bool)":"f4460d34","bound(int256,int256,int256)":"8f48fc07","bound(uint256,uint256,uint256)":"5a6c1eed","breakpoint(string)":"f0259e92","breakpoint(string,bool)":"f7d39a8d","broadcast()":"afc98040","broadcast(address)":"e6962cdb","broadcast(uint256)":"f67a965b","broadcastRawTransaction(bytes)":"8c0c72e0","closeFile(string)":"48c3241f","computeCreate2Address(bytes32,bytes32)":"890c283b","computeCreate2Address(bytes32,bytes32,address)":"d323826a","computeCreateAddress(address,uint256)":"74637a7a","contains(string,string)":"3fb18aec","copyFile(string,string)":"a54a87d8","copyStorage(address,address)":"203dac0d","createDir(string,bool)":"168b64d3","createWallet(string)":"7404f1d2","createWallet(uint256)":"7a675bb6","createWallet(uint256,string)":"ed7c5462","deployCode(string)":"9a8325a0","deployCode(string,bytes)":"29ce9dde","deployCode(string,bytes,bytes32)":"016155bf","deployCode(string,bytes,uint256)":"ff5d64e4","deployCode(string,bytes,uint256,bytes32)":"3aa773ea","deployCode(string,bytes32)":"17ab1d79","deployCode(string,uint256)":"0af6a701","deployCode(string,uint256,bytes32)":"002cb687","deriveKey(string,string,uint32)":"6bcb2c1b","deriveKey(string,string,uint32,string)":"29233b1f","deriveKey(string,uint32)":"6229498b","deriveKey(string,uint32,string)":"32c8176d","eip712HashStruct(string,bytes)":"aedeaebc","eip712HashStruct(string,string,bytes)":"6d06c57c","eip712HashType(string)":"6792e9e2","eip712HashType(string,string)":"18fb6406","eip712HashTypedData(string)":"ea25e615","ensNamehash(string)":"8c374c65","envAddress(string)":"350d56bf","envAddress(string,string)":"ad31b9fa","envBool(string)":"7ed1ec7d","envBool(string,string)":"aaaddeaf","envBytes(string)":"4d7baf06","envBytes(string,string)":"ddc2651b","envBytes32(string)":"97949042","envBytes32(string,string)":"5af231c1","envExists(string)":"ce8365f9","envInt(string)":"892a0c61","envInt(string,string)":"42181150","envOr(string,address)":"561fe540","envOr(string,bool)":"4777f3cf","envOr(string,bytes)":"b3e47705","envOr(string,bytes32)":"b4a85892","envOr(string,int256)":"bbcb713e","envOr(string,string)":"d145736c","envOr(string,string,address[])":"c74e9deb","envOr(string,string,bool[])":"eb85e83b","envOr(string,string,bytes32[])":"2281f367","envOr(string,string,bytes[])":"64bc3e64","envOr(string,string,int256[])":"4700d74b","envOr(string,string,string[])":"859216bc","envOr(string,string,uint256[])":"74318528","envOr(string,uint256)":"5e97348f","envString(string)":"f877cb19","envString(string,string)":"14b02bc9","envUint(string)":"c1978d1f","envUint(string,string)":"f3dec099","eth_getLogs(uint256,uint256,address,bytes32[])":"35e1349b","exists(string)":"261a323e","ffi(string[])":"89160467","foundryVersionAtLeast(string)":"6248be1f","foundryVersionCmp(string)":"ca7b0a09","fsMetadata(string)":"af368a08","getArtifactPathByCode(bytes)":"eb74848c","getArtifactPathByDeployedCode(bytes)":"6d853ba5","getBlobBaseFee()":"1f6d6ef7","getBlockNumber()":"42cbb15c","getBlockTimestamp()":"796b89b9","getBroadcast(string,uint64,uint8)":"3dc90cb3","getBroadcasts(string,uint64)":"f2fa4a26","getBroadcasts(string,uint64,uint8)":"f7afe919","getChain(string)":"4cc1c2bb","getChain(uint256)":"b6791ad4","getChainId()":"3408e470","getCode(string)":"8d1cc925","getDeployedCode(string)":"3ebf73b4","getDeployment(string)":"a8091d97","getDeployment(string,uint64)":"0debd5d6","getDeployments(string,uint64)":"74e133dd","getFoundryVersion()":"ea991bb5","getLabel(address)":"28a249b0","getMappingKeyAndParentOf(address,bytes32)":"876e24e6","getMappingLength(address,bytes32)":"2f2fd63f","getMappingSlotAt(address,bytes32,uint256)":"ebc73ab4","getNonce((address,uint256,uint256,uint256))":"a5748aad","getNonce(address)":"2d0335ab","getRawBlockHeader(uint256)":"2c667606","getRecordedLogs()":"191553a4","getStateDiff()":"80df01cc","getStateDiffJson()":"f54fe009","getStorageAccesses()":"2899b1d0","getWallets()":"db7a4605","indexOf(string,string)":"8a0807b7","isContext(uint8)":"64af255d","isDir(string)":"7d15d019","isFile(string)":"e0eb04d4","keyExists(string,string)":"528a683c","keyExistsJson(string,string)":"db4235f6","keyExistsToml(string,string)":"600903ad","label(address,string)":"c657c718","lastCallGas()":"2b589b28","load(address,bytes32)":"667f9d70","parseAddress(string)":"c6ce059d","parseBool(string)":"974ef924","parseBytes(string)":"8f5d232d","parseBytes32(string)":"087e6e81","parseInt(string)":"42346c5e","parseJson(string)":"6a82600a","parseJson(string,string)":"85940ef1","parseJsonAddress(string,string)":"1e19e657","parseJsonAddressArray(string,string)":"2fce7883","parseJsonBool(string,string)":"9f86dc91","parseJsonBoolArray(string,string)":"91f3b94f","parseJsonBytes(string,string)":"fd921be8","parseJsonBytes32(string,string)":"1777e59d","parseJsonBytes32Array(string,string)":"91c75bc3","parseJsonBytesArray(string,string)":"6631aa99","parseJsonInt(string,string)":"7b048ccd","parseJsonIntArray(string,string)":"9983c28a","parseJsonKeys(string,string)":"213e4198","parseJsonString(string,string)":"49c4fac8","parseJsonStringArray(string,string)":"498fdcf4","parseJsonType(string,string)":"a9da313b","parseJsonType(string,string,string)":"e3f5ae33","parseJsonTypeArray(string,string,string)":"0175d535","parseJsonUint(string,string)":"addde2b6","parseJsonUintArray(string,string)":"522074ab","parseToml(string)":"592151f0","parseToml(string,string)":"37736e08","parseTomlAddress(string,string)":"65e7c844","parseTomlAddressArray(string,string)":"65c428e7","parseTomlBool(string,string)":"d30dced6","parseTomlBoolArray(string,string)":"127cfe9a","parseTomlBytes(string,string)":"d77bfdb9","parseTomlBytes32(string,string)":"8e214810","parseTomlBytes32Array(string,string)":"3e716f81","parseTomlBytesArray(string,string)":"b197c247","parseTomlInt(string,string)":"c1350739","parseTomlIntArray(string,string)":"d3522ae6","parseTomlKeys(string,string)":"812a44b2","parseTomlString(string,string)":"8bb8dd43","parseTomlStringArray(string,string)":"9f629281","parseTomlType(string,string)":"47fa5e11","parseTomlType(string,string,string)":"f9fa5cdb","parseTomlTypeArray(string,string,string)":"49be3743","parseTomlUint(string,string)":"cc7b0487","parseTomlUintArray(string,string)":"b5df27c8","parseUint(string)":"fa91454d","pauseGasMetering()":"d1a5b36f","pauseTracing()":"c94d1f90","projectRoot()":"d930a0e6","prompt(string)":"47eaf474","promptAddress(string)":"62ee05f4","promptSecret(string)":"1e279d41","promptSecretUint(string)":"69ca02b7","promptUint(string)":"652fd489","publicKeyP256(uint256)":"c453949e","randomAddress()":"d5bee9f5","randomBool()":"cdc126bd","randomBytes(uint256)":"6c5d32a9","randomBytes4()":"9b7cd579","randomBytes8()":"0497b0a5","randomInt()":"111f1202","randomInt(uint256)":"12845966","randomUint()":"25124730","randomUint(uint256)":"cf81e69c","randomUint(uint256,uint256)":"d61b051b","readDir(string)":"c4bc59e0","readDir(string,uint64)":"1497876c","readDir(string,uint64,bool)":"8102d70d","readFile(string)":"60f9bb11","readFileBinary(string)":"16ed7bc4","readLine(string)":"70f55728","readLink(string)":"9f5684a2","record()":"266cf109","recordLogs()":"41af2f52","rememberKey(uint256)":"22100064","rememberKeys(string,string,string,uint32)":"f8d58eaf","rememberKeys(string,string,uint32)":"97cb9189","removeDir(string,bool)":"45c62011","removeFile(string)":"f1afe04d","replace(string,string,string)":"e00ad03e","resetGasMetering()":"be367dd3","resolveEnv(string)":"ddd2128d","resumeGasMetering()":"2bcd50e0","resumeTracing()":"72a09ccb","rpc(string,string)":"1206c8a8","rpc(string,string,string)":"0199a220","rpcUrl(string)":"975a6ce9","rpcUrlStructs()":"9d2ad72a","rpcUrls()":"a85a8418","serializeAddress(string,string,address)":"972c6062","serializeAddress(string,string,address[])":"1e356e1a","serializeBool(string,string,bool)":"ac22e971","serializeBool(string,string,bool[])":"92925aa1","serializeBytes(string,string,bytes)":"f21d52c7","serializeBytes(string,string,bytes[])":"9884b232","serializeBytes32(string,string,bytes32)":"2d812b44","serializeBytes32(string,string,bytes32[])":"201e43e2","serializeInt(string,string,int256)":"3f33db60","serializeInt(string,string,int256[])":"7676e127","serializeJson(string,string)":"9b3358b0","serializeJsonType(string,bytes)":"6d4f96a6","serializeJsonType(string,string,string,bytes)":"6f93bccb","serializeString(string,string,string)":"88da6d35","serializeString(string,string,string[])":"561cd6f3","serializeUint(string,string,uint256)":"129e9002","serializeUint(string,string,uint256[])":"fee9a469","serializeUintToHex(string,string,uint256)":"ae5a2ae8","setArbitraryStorage(address)":"e1631837","setArbitraryStorage(address,bool)":"d3ec2a0b","setEnv(string,string)":"3d5923ee","setSeed(uint256)":"c32a50f9","shuffle(uint256[])":"54f1469c","sign((address,uint256,uint256,uint256),bytes32)":"b25c5a25","sign(address,bytes32)":"8c1aa205","sign(bytes32)":"799cd333","sign(uint256,bytes32)":"e341eaa4","signAndAttachDelegation(address,uint256)":"c7fa7288","signAndAttachDelegation(address,uint256,bool)":"d936e146","signAndAttachDelegation(address,uint256,uint64)":"cde3e5be","signCompact((address,uint256,uint256,uint256),bytes32)":"3d0e292f","signCompact(address,bytes32)":"8e2f97bf","signCompact(bytes32)":"a282dc4b","signCompact(uint256,bytes32)":"cc2a781f","signDelegation(address,uint256)":"5b593c7b","signDelegation(address,uint256,bool)":"cdd7563d","signDelegation(address,uint256,uint64)":"ceba2ec3","signP256(uint256,bytes32)":"83211b40","sleep(uint256)":"fa9d8713","sort(uint256[])":"9ec8b026","split(string,string)":"8bb75533","startBroadcast()":"7fb5297f","startBroadcast(address)":"7fec2a8d","startBroadcast(uint256)":"ce817d47","startDebugTraceRecording()":"419c8832","startMappingRecording()":"3e9705c0","startStateDiffRecording()":"cf22e3c9","stopAndReturnDebugTraceRecording()":"ced398a2","stopAndReturnStateDiff()":"aa5cf90e","stopBroadcast()":"76eadd36","stopMappingRecording()":"0d4aae9b","stopRecord()":"996be76d","toBase64(bytes)":"a5cbfe65","toBase64(string)":"3f8be2c8","toBase64URL(bytes)":"c8bd0e4a","toBase64URL(string)":"ae3165b3","toLowercase(string)":"50bb0884","toString(address)":"56ca623e","toString(bool)":"71dce7da","toString(bytes)":"71aad10d","toString(bytes32)":"b11a19e8","toString(int256)":"a322c40e","toString(uint256)":"6900a3ae","toUppercase(string)":"074ae3d7","trim(string)":"b2dad155","tryFfi(string[])":"f45c1ce7","unixTime()":"625387dc","writeFile(string,string)":"897e0a97","writeFileBinary(string,bytes)":"1f21fc80","writeJson(string,string)":"e23cd19f","writeJson(string,string,string)":"35d6ad46","writeLine(string,string)":"619d897f","writeToml(string,string)":"c0865ba7","writeToml(string,string,string)":"51ac6a33"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"accesses\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"readSlots\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"writeSlots\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"addr\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"keyAddr\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqAbs\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqAbs\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqAbs\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqAbs\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqAbsDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqAbsDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqAbsDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqAbsDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqRel\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqRel\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqRel\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqRel\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqRelDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqRelDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertApproxEqRelDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"maxPercentDelta\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertApproxEqRelDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"left\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"right\",\"type\":\"bytes32[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256[]\",\"name\":\"left\",\"type\":\"int256[]\"},{\"internalType\":\"int256[]\",\"name\":\"right\",\"type\":\"int256[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"left\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"right\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"left\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"right\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"left\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"right\",\"type\":\"address[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"left\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"right\",\"type\":\"address[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"left\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"right\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"left\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"right\",\"type\":\"address\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"left\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"right\",\"type\":\"uint256[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool[]\",\"name\":\"left\",\"type\":\"bool[]\"},{\"internalType\":\"bool[]\",\"name\":\"right\",\"type\":\"bool[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256[]\",\"name\":\"left\",\"type\":\"int256[]\"},{\"internalType\":\"int256[]\",\"name\":\"right\",\"type\":\"int256[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"left\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"right\",\"type\":\"bytes32\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"left\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"right\",\"type\":\"uint256[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"left\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"right\",\"type\":\"bytes\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"left\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"right\",\"type\":\"bytes32\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"left\",\"type\":\"string[]\"},{\"internalType\":\"string[]\",\"name\":\"right\",\"type\":\"string[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"left\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"right\",\"type\":\"bytes32[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"left\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"right\",\"type\":\"bytes\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool[]\",\"name\":\"left\",\"type\":\"bool[]\"},{\"internalType\":\"bool[]\",\"name\":\"right\",\"type\":\"bool[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"left\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes[]\",\"name\":\"right\",\"type\":\"bytes[]\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"left\",\"type\":\"string[]\"},{\"internalType\":\"string[]\",\"name\":\"right\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"left\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"right\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"left\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes[]\",\"name\":\"right\",\"type\":\"bytes[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"left\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"right\",\"type\":\"bool\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"}],\"name\":\"assertEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"condition\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertFalse\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"condition\",\"type\":\"bool\"}],\"name\":\"assertFalse\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"}],\"name\":\"assertGe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"}],\"name\":\"assertGe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertGeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertGeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"}],\"name\":\"assertGt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"}],\"name\":\"assertGt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertGtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertGtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertGtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"}],\"name\":\"assertLe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"}],\"name\":\"assertLe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLe\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertLeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertLeDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"}],\"name\":\"assertLt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"}],\"name\":\"assertLt\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertLtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertLtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertLtDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"left\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"right\",\"type\":\"bytes32[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256[]\",\"name\":\"left\",\"type\":\"int256[]\"},{\"internalType\":\"int256[]\",\"name\":\"right\",\"type\":\"int256[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"left\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"right\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"left\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes[]\",\"name\":\"right\",\"type\":\"bytes[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"left\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"right\",\"type\":\"bool\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool[]\",\"name\":\"left\",\"type\":\"bool[]\"},{\"internalType\":\"bool[]\",\"name\":\"right\",\"type\":\"bool[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"left\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"right\",\"type\":\"bytes\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"left\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"right\",\"type\":\"address[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"left\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"right\",\"type\":\"uint256[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool[]\",\"name\":\"left\",\"type\":\"bool[]\"},{\"internalType\":\"bool[]\",\"name\":\"right\",\"type\":\"bool[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"left\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"right\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"left\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"right\",\"type\":\"address[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"left\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"right\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"left\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"right\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"left\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"right\",\"type\":\"bytes32\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"left\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"right\",\"type\":\"bytes\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"left\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"right\",\"type\":\"uint256[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"left\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"right\",\"type\":\"address\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"left\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"right\",\"type\":\"bytes32\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"left\",\"type\":\"string[]\"},{\"internalType\":\"string[]\",\"name\":\"right\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"left\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"right\",\"type\":\"bytes32[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"left\",\"type\":\"string[]\"},{\"internalType\":\"string[]\",\"name\":\"right\",\"type\":\"string[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256[]\",\"name\":\"left\",\"type\":\"int256[]\"},{\"internalType\":\"int256[]\",\"name\":\"right\",\"type\":\"int256[]\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"left\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes[]\",\"name\":\"right\",\"type\":\"bytes[]\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"}],\"name\":\"assertNotEq\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertNotEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"left\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"right\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"}],\"name\":\"assertNotEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"left\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"right\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"decimals\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertNotEqDecimal\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"condition\",\"type\":\"bool\"}],\"name\":\"assertTrue\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"condition\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"error\",\"type\":\"string\"}],\"name\":\"assertTrue\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"condition\",\"type\":\"bool\"}],\"name\":\"assume\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"assumeNoRevert\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"reverter\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"partialMatch\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"revertData\",\"type\":\"bytes\"}],\"internalType\":\"struct VmSafe.PotentialRevert[]\",\"name\":\"potentialReverts\",\"type\":\"tuple[]\"}],\"name\":\"assumeNoRevert\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"reverter\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"partialMatch\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"revertData\",\"type\":\"bytes\"}],\"internalType\":\"struct VmSafe.PotentialRevert\",\"name\":\"potentialRevert\",\"type\":\"tuple\"}],\"name\":\"assumeNoRevert\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"blob\",\"type\":\"bytes\"}],\"name\":\"attachBlob\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"name\":\"attachDelegation\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"},{\"internalType\":\"bool\",\"name\":\"crossChain\",\"type\":\"bool\"}],\"name\":\"attachDelegation\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"current\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"min\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"max\",\"type\":\"uint256\"}],\"name\":\"bound\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"current\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"min\",\"type\":\"int256\"},{\"internalType\":\"int256\",\"name\":\"max\",\"type\":\"int256\"}],\"name\":\"bound\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"char\",\"type\":\"string\"}],\"name\":\"breakpoint\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"char\",\"type\":\"string\"},{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"name\":\"breakpoint\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"broadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"signer\",\"type\":\"address\"}],\"name\":\"broadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"broadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"broadcastRawTransaction\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"closeFile\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"salt\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"initCodeHash\",\"type\":\"bytes32\"}],\"name\":\"computeCreate2Address\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"salt\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"initCodeHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"deployer\",\"type\":\"address\"}],\"name\":\"computeCreate2Address\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"deployer\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"}],\"name\":\"computeCreateAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"subject\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"search\",\"type\":\"string\"}],\"name\":\"contains\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"from\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"to\",\"type\":\"string\"}],\"name\":\"copyFile\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"copied\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"copyStorage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"bool\",\"name\":\"recursive\",\"type\":\"bool\"}],\"name\":\"createDir\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"walletLabel\",\"type\":\"string\"}],\"name\":\"createWallet\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.Wallet\",\"name\":\"wallet\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"createWallet\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.Wallet\",\"name\":\"wallet\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"walletLabel\",\"type\":\"string\"}],\"name\":\"createWallet\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.Wallet\",\"name\":\"wallet\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"constructorArgs\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"constructorArgs\",\"type\":\"bytes\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"constructorArgs\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"salt\",\"type\":\"bytes32\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"constructorArgs\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"deployCode\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"mnemonic\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"derivationPath\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"index\",\"type\":\"uint32\"},{\"internalType\":\"string\",\"name\":\"language\",\"type\":\"string\"}],\"name\":\"deriveKey\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"mnemonic\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"index\",\"type\":\"uint32\"},{\"internalType\":\"string\",\"name\":\"language\",\"type\":\"string\"}],\"name\":\"deriveKey\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"mnemonic\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"index\",\"type\":\"uint32\"}],\"name\":\"deriveKey\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"mnemonic\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"derivationPath\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"index\",\"type\":\"uint32\"}],\"name\":\"deriveKey\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"bindingsPath\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeName\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"abiEncodedData\",\"type\":\"bytes\"}],\"name\":\"eip712HashStruct\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"typeHash\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"typeNameOrDefinition\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"abiEncodedData\",\"type\":\"bytes\"}],\"name\":\"eip712HashStruct\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"typeHash\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"bindingsPath\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeName\",\"type\":\"string\"}],\"name\":\"eip712HashType\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"typeHash\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"typeNameOrDefinition\",\"type\":\"string\"}],\"name\":\"eip712HashType\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"typeHash\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"jsonData\",\"type\":\"string\"}],\"name\":\"eip712HashTypedData\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"ensNamehash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"value\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envAddress\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"value\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envBool\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envBool\",\"outputs\":[{\"internalType\":\"bool[]\",\"name\":\"value\",\"type\":\"bool[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envBytes\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"value\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envBytes\",\"outputs\":[{\"internalType\":\"bytes[]\",\"name\":\"value\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envBytes32\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"value\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envBytes32\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"value\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envInt\",\"outputs\":[{\"internalType\":\"int256[]\",\"name\":\"value\",\"type\":\"int256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envInt\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"value\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"bytes32[]\",\"name\":\"defaultValue\",\"type\":\"bytes32[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"value\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"int256[]\",\"name\":\"defaultValue\",\"type\":\"int256[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"int256[]\",\"name\":\"value\",\"type\":\"int256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"bool\",\"name\":\"defaultValue\",\"type\":\"bool\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"address\",\"name\":\"defaultValue\",\"type\":\"address\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"value\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"defaultValue\",\"type\":\"uint256\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"bytes[]\",\"name\":\"defaultValue\",\"type\":\"bytes[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"bytes[]\",\"name\":\"value\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"uint256[]\",\"name\":\"defaultValue\",\"type\":\"uint256[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"value\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"defaultValue\",\"type\":\"string[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"value\",\"type\":\"string[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"defaultValue\",\"type\":\"bytes\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"value\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"defaultValue\",\"type\":\"bytes32\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"value\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"int256\",\"name\":\"defaultValue\",\"type\":\"int256\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"value\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"address[]\",\"name\":\"defaultValue\",\"type\":\"address[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"value\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"defaultValue\",\"type\":\"string\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"value\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"},{\"internalType\":\"bool[]\",\"name\":\"defaultValue\",\"type\":\"bool[]\"}],\"name\":\"envOr\",\"outputs\":[{\"internalType\":\"bool[]\",\"name\":\"value\",\"type\":\"bool[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envString\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"value\",\"type\":\"string[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"value\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"}],\"name\":\"envUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delim\",\"type\":\"string\"}],\"name\":\"envUint\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"value\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"fromBlock\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"toBlock\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"}],\"name\":\"eth_getLogs\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"emitter\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"blockNumber\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"transactionHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"transactionIndex\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"logIndex\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"removed\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.EthGetLogs[]\",\"name\":\"logs\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"exists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"commandInput\",\"type\":\"string[]\"}],\"name\":\"ffi\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"result\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"version\",\"type\":\"string\"}],\"name\":\"foundryVersionAtLeast\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"version\",\"type\":\"string\"}],\"name\":\"foundryVersionCmp\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"fsMetadata\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"isDir\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"isSymlink\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"length\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"readOnly\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"modified\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"accessed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"created\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.FsMetadata\",\"name\":\"metadata\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"code\",\"type\":\"bytes\"}],\"name\":\"getArtifactPathByCode\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"deployedCode\",\"type\":\"bytes\"}],\"name\":\"getArtifactPathByDeployedCode\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getBlobBaseFee\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"blobBaseFee\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getBlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"height\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getBlockTimestamp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timestamp\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"contractName\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"chainId\",\"type\":\"uint64\"},{\"internalType\":\"enum VmSafe.BroadcastTxType\",\"name\":\"txType\",\"type\":\"uint8\"}],\"name\":\"getBroadcast\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"enum VmSafe.BroadcastTxType\",\"name\":\"txType\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"contractAddress\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"blockNumber\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.BroadcastTxSummary\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"contractName\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"chainId\",\"type\":\"uint64\"}],\"name\":\"getBroadcasts\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"enum VmSafe.BroadcastTxType\",\"name\":\"txType\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"contractAddress\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"blockNumber\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.BroadcastTxSummary[]\",\"name\":\"\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"contractName\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"chainId\",\"type\":\"uint64\"},{\"internalType\":\"enum VmSafe.BroadcastTxType\",\"name\":\"txType\",\"type\":\"uint8\"}],\"name\":\"getBroadcasts\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"enum VmSafe.BroadcastTxType\",\"name\":\"txType\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"contractAddress\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"blockNumber\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.BroadcastTxSummary[]\",\"name\":\"\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"chainAlias\",\"type\":\"string\"}],\"name\":\"getChain\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"chainId\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"chainAlias\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"rpcUrl\",\"type\":\"string\"}],\"internalType\":\"struct VmSafe.Chain\",\"name\":\"chain\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"chainId\",\"type\":\"uint256\"}],\"name\":\"getChain\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"chainId\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"chainAlias\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"rpcUrl\",\"type\":\"string\"}],\"internalType\":\"struct VmSafe.Chain\",\"name\":\"chain\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getChainId\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"blockChainId\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"}],\"name\":\"getCode\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"creationBytecode\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"artifactPath\",\"type\":\"string\"}],\"name\":\"getDeployedCode\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"runtimeBytecode\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"contractName\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"chainId\",\"type\":\"uint64\"}],\"name\":\"getDeployment\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"contractName\",\"type\":\"string\"}],\"name\":\"getDeployment\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"deployedAddress\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"contractName\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"chainId\",\"type\":\"uint64\"}],\"name\":\"getDeployments\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"deployedAddresses\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFoundryVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"version\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getLabel\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"currentLabel\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"elementSlot\",\"type\":\"bytes32\"}],\"name\":\"getMappingKeyAndParentOf\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"found\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"key\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"parent\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"mappingSlot\",\"type\":\"bytes32\"}],\"name\":\"getMappingLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"length\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"mappingSlot\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"idx\",\"type\":\"uint256\"}],\"name\":\"getMappingSlotAt\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"value\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.Wallet\",\"name\":\"wallet\",\"type\":\"tuple\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"}],\"name\":\"getRawBlockHeader\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"rlpHeader\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRecordedLogs\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"emitter\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.Log[]\",\"name\":\"logs\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getStateDiff\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"diff\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getStateDiffJson\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"diff\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getStorageAccesses\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"slot\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"isWrite\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"previousValue\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"newValue\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"reverted\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.StorageAccess[]\",\"name\":\"storageAccesses\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getWallets\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"wallets\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"indexOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"enum VmSafe.ForgeContext\",\"name\":\"context\",\"type\":\"uint8\"}],\"name\":\"isContext\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"isDir\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"isFile\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"keyExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"keyExistsJson\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"keyExistsToml\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"newLabel\",\"type\":\"string\"}],\"name\":\"label\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastCallGas\",\"outputs\":[{\"components\":[{\"internalType\":\"uint64\",\"name\":\"gasLimit\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"gasTotalUsed\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"gasMemoryUsed\",\"type\":\"uint64\"},{\"internalType\":\"int64\",\"name\":\"gasRefunded\",\"type\":\"int64\"},{\"internalType\":\"uint64\",\"name\":\"gasRemaining\",\"type\":\"uint64\"}],\"internalType\":\"struct VmSafe.Gas\",\"name\":\"gas\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"slot\",\"type\":\"bytes32\"}],\"name\":\"load\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"data\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"name\":\"parseAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"parsedValue\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"name\":\"parseBool\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"parsedValue\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"name\":\"parseBytes\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"parsedValue\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"name\":\"parseBytes32\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"parsedValue\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"name\":\"parseInt\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"parsedValue\",\"type\":\"int256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"name\":\"parseJson\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"abiEncodedData\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJson\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"abiEncodedData\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonAddressArray\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonBool\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonBoolArray\",\"outputs\":[{\"internalType\":\"bool[]\",\"name\":\"\",\"type\":\"bool[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonBytes\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonBytes32\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonBytes32Array\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonBytesArray\",\"outputs\":[{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonInt\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonIntArray\",\"outputs\":[{\"internalType\":\"int256[]\",\"name\":\"\",\"type\":\"int256[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonKeys\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"keys\",\"type\":\"string[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonStringArray\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"\",\"type\":\"string[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"}],\"name\":\"parseJsonType\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"}],\"name\":\"parseJsonType\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"}],\"name\":\"parseJsonTypeArray\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseJsonUintArray\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseToml\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"abiEncodedData\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"}],\"name\":\"parseToml\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"abiEncodedData\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlAddressArray\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlBool\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlBoolArray\",\"outputs\":[{\"internalType\":\"bool[]\",\"name\":\"\",\"type\":\"bool[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlBytes\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlBytes32\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlBytes32Array\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlBytesArray\",\"outputs\":[{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlInt\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlIntArray\",\"outputs\":[{\"internalType\":\"int256[]\",\"name\":\"\",\"type\":\"int256[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlKeys\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"keys\",\"type\":\"string[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlStringArray\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"\",\"type\":\"string[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"}],\"name\":\"parseTomlType\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"}],\"name\":\"parseTomlType\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"}],\"name\":\"parseTomlTypeArray\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"toml\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"}],\"name\":\"parseTomlUintArray\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"name\":\"parseUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"parsedValue\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pauseGasMetering\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pauseTracing\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"projectRoot\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"promptText\",\"type\":\"string\"}],\"name\":\"prompt\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"promptText\",\"type\":\"string\"}],\"name\":\"promptAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"promptText\",\"type\":\"string\"}],\"name\":\"promptSecret\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"promptText\",\"type\":\"string\"}],\"name\":\"promptSecretUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"promptText\",\"type\":\"string\"}],\"name\":\"promptUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"publicKeyP256\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"randomAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"randomBool\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"len\",\"type\":\"uint256\"}],\"name\":\"randomBytes\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"randomBytes4\",\"outputs\":[{\"internalType\":\"bytes4\",\"name\":\"\",\"type\":\"bytes4\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"randomBytes8\",\"outputs\":[{\"internalType\":\"bytes8\",\"name\":\"\",\"type\":\"bytes8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"randomInt\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"bits\",\"type\":\"uint256\"}],\"name\":\"randomInt\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"randomUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"bits\",\"type\":\"uint256\"}],\"name\":\"randomUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"min\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"max\",\"type\":\"uint256\"}],\"name\":\"randomUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"maxDepth\",\"type\":\"uint64\"}],\"name\":\"readDir\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"errorMessage\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"depth\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"isDir\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"isSymlink\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.DirEntry[]\",\"name\":\"entries\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"maxDepth\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"followLinks\",\"type\":\"bool\"}],\"name\":\"readDir\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"errorMessage\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"depth\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"isDir\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"isSymlink\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.DirEntry[]\",\"name\":\"entries\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"readDir\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"errorMessage\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"uint64\",\"name\":\"depth\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"isDir\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"isSymlink\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.DirEntry[]\",\"name\":\"entries\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"readFile\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"data\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"readFileBinary\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"readLine\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"line\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"linkPath\",\"type\":\"string\"}],\"name\":\"readLink\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"targetPath\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"record\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recordLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"rememberKey\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"keyAddr\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"mnemonic\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"derivationPath\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"count\",\"type\":\"uint32\"}],\"name\":\"rememberKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"keyAddrs\",\"type\":\"address[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"mnemonic\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"derivationPath\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"language\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"count\",\"type\":\"uint32\"}],\"name\":\"rememberKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"keyAddrs\",\"type\":\"address[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"bool\",\"name\":\"recursive\",\"type\":\"bool\"}],\"name\":\"removeDir\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"removeFile\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"from\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"to\",\"type\":\"string\"}],\"name\":\"replace\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"output\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"resetGasMetering\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"}],\"name\":\"resolveEnv\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"resumeGasMetering\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"resumeTracing\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"urlOrAlias\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"method\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"params\",\"type\":\"string\"}],\"name\":\"rpc\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"method\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"params\",\"type\":\"string\"}],\"name\":\"rpc\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"rpcAlias\",\"type\":\"string\"}],\"name\":\"rpcUrl\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"rpcUrlStructs\",\"outputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"key\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"url\",\"type\":\"string\"}],\"internalType\":\"struct VmSafe.Rpc[]\",\"name\":\"urls\",\"type\":\"tuple[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"rpcUrls\",\"outputs\":[{\"internalType\":\"string[2][]\",\"name\":\"urls\",\"type\":\"string[2][]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"address[]\",\"name\":\"values\",\"type\":\"address[]\"}],\"name\":\"serializeAddress\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"address\",\"name\":\"value\",\"type\":\"address\"}],\"name\":\"serializeAddress\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"bool[]\",\"name\":\"values\",\"type\":\"bool[]\"}],\"name\":\"serializeBool\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"name\":\"serializeBool\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"}],\"name\":\"serializeBytes\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"value\",\"type\":\"bytes\"}],\"name\":\"serializeBytes\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"bytes32[]\",\"name\":\"values\",\"type\":\"bytes32[]\"}],\"name\":\"serializeBytes32\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"value\",\"type\":\"bytes32\"}],\"name\":\"serializeBytes32\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"int256\",\"name\":\"value\",\"type\":\"int256\"}],\"name\":\"serializeInt\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"int256[]\",\"name\":\"values\",\"type\":\"int256[]\"}],\"name\":\"serializeInt\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"value\",\"type\":\"string\"}],\"name\":\"serializeJson\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"value\",\"type\":\"bytes\"}],\"name\":\"serializeJsonType\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"typeDescription\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"value\",\"type\":\"bytes\"}],\"name\":\"serializeJsonType\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"values\",\"type\":\"string[]\"}],\"name\":\"serializeString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"value\",\"type\":\"string\"}],\"name\":\"serializeString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"serializeUint\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"uint256[]\",\"name\":\"values\",\"type\":\"uint256[]\"}],\"name\":\"serializeUint\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"objectKey\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"serializeUintToHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"overwrite\",\"type\":\"bool\"}],\"name\":\"setArbitraryStorage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"setArbitraryStorage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"value\",\"type\":\"string\"}],\"name\":\"setEnv\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"}],\"name\":\"setSeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"array\",\"type\":\"uint256[]\"}],\"name\":\"shuffle\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"sign\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"signer\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"sign\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.Wallet\",\"name\":\"wallet\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"sign\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"sign\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"signAndAttachDelegation\",\"outputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"}],\"name\":\"signAndAttachDelegation\",\"outputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"crossChain\",\"type\":\"bool\"}],\"name\":\"signAndAttachDelegation\",\"outputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyX\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"publicKeyY\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.Wallet\",\"name\":\"wallet\",\"type\":\"tuple\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"signCompact\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"vs\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"signer\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"signCompact\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"vs\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"signCompact\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"vs\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"signCompact\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"vs\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"signDelegation\",\"outputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"crossChain\",\"type\":\"bool\"}],\"name\":\"signDelegation\",\"outputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"}],\"name\":\"signDelegation\",\"outputs\":[{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"nonce\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.SignedDelegation\",\"name\":\"signedDelegation\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"digest\",\"type\":\"bytes32\"}],\"name\":\"signP256\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"duration\",\"type\":\"uint256\"}],\"name\":\"sleep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"array\",\"type\":\"uint256[]\"}],\"name\":\"sort\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"delimiter\",\"type\":\"string\"}],\"name\":\"split\",\"outputs\":[{\"internalType\":\"string[]\",\"name\":\"outputs\",\"type\":\"string[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"startBroadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"signer\",\"type\":\"address\"}],\"name\":\"startBroadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"privateKey\",\"type\":\"uint256\"}],\"name\":\"startBroadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"startDebugTraceRecording\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"startMappingRecording\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"startStateDiffRecording\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopAndReturnDebugTraceRecording\",\"outputs\":[{\"components\":[{\"internalType\":\"uint256[]\",\"name\":\"stack\",\"type\":\"uint256[]\"},{\"internalType\":\"bytes\",\"name\":\"memoryInput\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"opcode\",\"type\":\"uint8\"},{\"internalType\":\"uint64\",\"name\":\"depth\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"isOutOfGas\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"contractAddr\",\"type\":\"address\"}],\"internalType\":\"struct VmSafe.DebugStep[]\",\"name\":\"step\",\"type\":\"tuple[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopAndReturnStateDiff\",\"outputs\":[{\"components\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"forkId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"chainId\",\"type\":\"uint256\"}],\"internalType\":\"struct VmSafe.ChainInfo\",\"name\":\"chainInfo\",\"type\":\"tuple\"},{\"internalType\":\"enum VmSafe.AccountAccessKind\",\"name\":\"kind\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"accessor\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"initialized\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"deployedCode\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bool\",\"name\":\"reverted\",\"type\":\"bool\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"slot\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"isWrite\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"previousValue\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"newValue\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"reverted\",\"type\":\"bool\"}],\"internalType\":\"struct VmSafe.StorageAccess[]\",\"name\":\"storageAccesses\",\"type\":\"tuple[]\"},{\"internalType\":\"uint64\",\"name\":\"depth\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"oldNonce\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"newNonce\",\"type\":\"uint64\"}],\"internalType\":\"struct VmSafe.AccountAccess[]\",\"name\":\"accountAccesses\",\"type\":\"tuple[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopBroadcast\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopMappingRecording\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"stopRecord\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"data\",\"type\":\"string\"}],\"name\":\"toBase64\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"toBase64\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"data\",\"type\":\"string\"}],\"name\":\"toBase64URL\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"toBase64URL\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"}],\"name\":\"toLowercase\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"output\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"value\",\"type\":\"address\"}],\"name\":\"toString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"toString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"value\",\"type\":\"bytes\"}],\"name\":\"toString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"name\":\"toString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"value\",\"type\":\"int256\"}],\"name\":\"toString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"value\",\"type\":\"bytes32\"}],\"name\":\"toString\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"stringifiedValue\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"}],\"name\":\"toUppercase\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"output\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"input\",\"type\":\"string\"}],\"name\":\"trim\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"output\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"commandInput\",\"type\":\"string[]\"}],\"name\":\"tryFfi\",\"outputs\":[{\"components\":[{\"internalType\":\"int32\",\"name\":\"exitCode\",\"type\":\"int32\"},{\"internalType\":\"bytes\",\"name\":\"stdout\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"stderr\",\"type\":\"bytes\"}],\"internalType\":\"struct VmSafe.FfiResult\",\"name\":\"result\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unixTime\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"milliseconds\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"data\",\"type\":\"string\"}],\"name\":\"writeFile\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"writeFileBinary\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"}],\"name\":\"writeJson\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"writeJson\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"data\",\"type\":\"string\"}],\"name\":\"writeLine\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"valueKey\",\"type\":\"string\"}],\"name\":\"writeToml\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"json\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"path\",\"type\":\"string\"}],\"name\":\"writeToml\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"accesses(address)\":{\"notice\":\"Gets all accessed reads and write slot from a `vm.record` session, for a given address.\"},\"addr(uint256)\":{\"notice\":\"Gets the address for a given private key.\"},\"assertApproxEqAbs(int256,int256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`.\"},\"assertApproxEqAbs(int256,int256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. Includes error message into revert string on failure.\"},\"assertApproxEqAbs(uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`.\"},\"assertApproxEqAbs(uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. Includes error message into revert string on failure.\"},\"assertApproxEqAbsDecimal(int256,int256,uint256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message.\"},\"assertApproxEqAbsDecimal(int256,int256,uint256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertApproxEqAbsDecimal(uint256,uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message.\"},\"assertApproxEqAbsDecimal(uint256,uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertApproxEqRel(int256,int256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100%\"},\"assertApproxEqRel(int256,int256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Includes error message into revert string on failure.\"},\"assertApproxEqRel(uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100%\"},\"assertApproxEqRel(uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Includes error message into revert string on failure.\"},\"assertApproxEqRelDecimal(int256,int256,uint256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message.\"},\"assertApproxEqRelDecimal(int256,int256,uint256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertApproxEqRelDecimal(uint256,uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message.\"},\"assertApproxEqRelDecimal(uint256,uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertEq(address,address)\":{\"notice\":\"Asserts that two `address` values are equal.\"},\"assertEq(address,address,string)\":{\"notice\":\"Asserts that two `address` values are equal and includes error message into revert string on failure.\"},\"assertEq(address[],address[])\":{\"notice\":\"Asserts that two arrays of `address` values are equal.\"},\"assertEq(address[],address[],string)\":{\"notice\":\"Asserts that two arrays of `address` values are equal and includes error message into revert string on failure.\"},\"assertEq(bool,bool)\":{\"notice\":\"Asserts that two `bool` values are equal.\"},\"assertEq(bool,bool,string)\":{\"notice\":\"Asserts that two `bool` values are equal and includes error message into revert string on failure.\"},\"assertEq(bool[],bool[])\":{\"notice\":\"Asserts that two arrays of `bool` values are equal.\"},\"assertEq(bool[],bool[],string)\":{\"notice\":\"Asserts that two arrays of `bool` values are equal and includes error message into revert string on failure.\"},\"assertEq(bytes,bytes)\":{\"notice\":\"Asserts that two `bytes` values are equal.\"},\"assertEq(bytes,bytes,string)\":{\"notice\":\"Asserts that two `bytes` values are equal and includes error message into revert string on failure.\"},\"assertEq(bytes32,bytes32)\":{\"notice\":\"Asserts that two `bytes32` values are equal.\"},\"assertEq(bytes32,bytes32,string)\":{\"notice\":\"Asserts that two `bytes32` values are equal and includes error message into revert string on failure.\"},\"assertEq(bytes32[],bytes32[])\":{\"notice\":\"Asserts that two arrays of `bytes32` values are equal.\"},\"assertEq(bytes32[],bytes32[],string)\":{\"notice\":\"Asserts that two arrays of `bytes32` values are equal and includes error message into revert string on failure.\"},\"assertEq(bytes[],bytes[])\":{\"notice\":\"Asserts that two arrays of `bytes` values are equal.\"},\"assertEq(bytes[],bytes[],string)\":{\"notice\":\"Asserts that two arrays of `bytes` values are equal and includes error message into revert string on failure.\"},\"assertEq(int256,int256)\":{\"notice\":\"Asserts that two `int256` values are equal.\"},\"assertEq(int256,int256,string)\":{\"notice\":\"Asserts that two `int256` values are equal and includes error message into revert string on failure.\"},\"assertEq(int256[],int256[])\":{\"notice\":\"Asserts that two arrays of `int256` values are equal.\"},\"assertEq(int256[],int256[],string)\":{\"notice\":\"Asserts that two arrays of `int256` values are equal and includes error message into revert string on failure.\"},\"assertEq(string,string)\":{\"notice\":\"Asserts that two `string` values are equal.\"},\"assertEq(string,string,string)\":{\"notice\":\"Asserts that two `string` values are equal and includes error message into revert string on failure.\"},\"assertEq(string[],string[])\":{\"notice\":\"Asserts that two arrays of `string` values are equal.\"},\"assertEq(string[],string[],string)\":{\"notice\":\"Asserts that two arrays of `string` values are equal and includes error message into revert string on failure.\"},\"assertEq(uint256,uint256)\":{\"notice\":\"Asserts that two `uint256` values are equal.\"},\"assertEq(uint256,uint256,string)\":{\"notice\":\"Asserts that two `uint256` values are equal and includes error message into revert string on failure.\"},\"assertEq(uint256[],uint256[])\":{\"notice\":\"Asserts that two arrays of `uint256 values are equal.\"},\"assertEq(uint256[],uint256[],string)\":{\"notice\":\"Asserts that two arrays of `uint256` values are equal and includes error message into revert string on failure.\"},\"assertEqDecimal(int256,int256,uint256)\":{\"notice\":\"Asserts that two `int256` values are equal, formatting them with decimals in failure message.\"},\"assertEqDecimal(int256,int256,uint256,string)\":{\"notice\":\"Asserts that two `int256` values are equal, formatting them with decimals in failure message. Includes error message into revert string on failure.\"},\"assertEqDecimal(uint256,uint256,uint256)\":{\"notice\":\"Asserts that two `uint256` values are equal, formatting them with decimals in failure message.\"},\"assertEqDecimal(uint256,uint256,uint256,string)\":{\"notice\":\"Asserts that two `uint256` values are equal, formatting them with decimals in failure message. Includes error message into revert string on failure.\"},\"assertFalse(bool)\":{\"notice\":\"Asserts that the given condition is false.\"},\"assertFalse(bool,string)\":{\"notice\":\"Asserts that the given condition is false and includes error message into revert string on failure.\"},\"assertGe(int256,int256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than or equal to second.\"},\"assertGe(int256,int256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than or equal to second. Includes error message into revert string on failure.\"},\"assertGe(uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than or equal to second.\"},\"assertGe(uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than or equal to second. Includes error message into revert string on failure.\"},\"assertGeDecimal(int256,int256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message.\"},\"assertGeDecimal(int256,int256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertGeDecimal(uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message.\"},\"assertGeDecimal(uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertGt(int256,int256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than second.\"},\"assertGt(int256,int256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than second. Includes error message into revert string on failure.\"},\"assertGt(uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than second.\"},\"assertGt(uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than second. Includes error message into revert string on failure.\"},\"assertGtDecimal(int256,int256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than second. Formats values with decimals in failure message.\"},\"assertGtDecimal(int256,int256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be greater than second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertGtDecimal(uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than second. Formats values with decimals in failure message.\"},\"assertGtDecimal(uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be greater than second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertLe(int256,int256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than or equal to second.\"},\"assertLe(int256,int256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than or equal to second. Includes error message into revert string on failure.\"},\"assertLe(uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than or equal to second.\"},\"assertLe(uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than or equal to second. Includes error message into revert string on failure.\"},\"assertLeDecimal(int256,int256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message.\"},\"assertLeDecimal(int256,int256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertLeDecimal(uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message.\"},\"assertLeDecimal(uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertLt(int256,int256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than second.\"},\"assertLt(int256,int256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than second. Includes error message into revert string on failure.\"},\"assertLt(uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than second.\"},\"assertLt(uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than second. Includes error message into revert string on failure.\"},\"assertLtDecimal(int256,int256,uint256)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than second. Formats values with decimals in failure message.\"},\"assertLtDecimal(int256,int256,uint256,string)\":{\"notice\":\"Compares two `int256` values. Expects first value to be less than second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertLtDecimal(uint256,uint256,uint256)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than second. Formats values with decimals in failure message.\"},\"assertLtDecimal(uint256,uint256,uint256,string)\":{\"notice\":\"Compares two `uint256` values. Expects first value to be less than second. Formats values with decimals in failure message. Includes error message into revert string on failure.\"},\"assertNotEq(address,address)\":{\"notice\":\"Asserts that two `address` values are not equal.\"},\"assertNotEq(address,address,string)\":{\"notice\":\"Asserts that two `address` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(address[],address[])\":{\"notice\":\"Asserts that two arrays of `address` values are not equal.\"},\"assertNotEq(address[],address[],string)\":{\"notice\":\"Asserts that two arrays of `address` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(bool,bool)\":{\"notice\":\"Asserts that two `bool` values are not equal.\"},\"assertNotEq(bool,bool,string)\":{\"notice\":\"Asserts that two `bool` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(bool[],bool[])\":{\"notice\":\"Asserts that two arrays of `bool` values are not equal.\"},\"assertNotEq(bool[],bool[],string)\":{\"notice\":\"Asserts that two arrays of `bool` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(bytes,bytes)\":{\"notice\":\"Asserts that two `bytes` values are not equal.\"},\"assertNotEq(bytes,bytes,string)\":{\"notice\":\"Asserts that two `bytes` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(bytes32,bytes32)\":{\"notice\":\"Asserts that two `bytes32` values are not equal.\"},\"assertNotEq(bytes32,bytes32,string)\":{\"notice\":\"Asserts that two `bytes32` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(bytes32[],bytes32[])\":{\"notice\":\"Asserts that two arrays of `bytes32` values are not equal.\"},\"assertNotEq(bytes32[],bytes32[],string)\":{\"notice\":\"Asserts that two arrays of `bytes32` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(bytes[],bytes[])\":{\"notice\":\"Asserts that two arrays of `bytes` values are not equal.\"},\"assertNotEq(bytes[],bytes[],string)\":{\"notice\":\"Asserts that two arrays of `bytes` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(int256,int256)\":{\"notice\":\"Asserts that two `int256` values are not equal.\"},\"assertNotEq(int256,int256,string)\":{\"notice\":\"Asserts that two `int256` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(int256[],int256[])\":{\"notice\":\"Asserts that two arrays of `int256` values are not equal.\"},\"assertNotEq(int256[],int256[],string)\":{\"notice\":\"Asserts that two arrays of `int256` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(string,string)\":{\"notice\":\"Asserts that two `string` values are not equal.\"},\"assertNotEq(string,string,string)\":{\"notice\":\"Asserts that two `string` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(string[],string[])\":{\"notice\":\"Asserts that two arrays of `string` values are not equal.\"},\"assertNotEq(string[],string[],string)\":{\"notice\":\"Asserts that two arrays of `string` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(uint256,uint256)\":{\"notice\":\"Asserts that two `uint256` values are not equal.\"},\"assertNotEq(uint256,uint256,string)\":{\"notice\":\"Asserts that two `uint256` values are not equal and includes error message into revert string on failure.\"},\"assertNotEq(uint256[],uint256[])\":{\"notice\":\"Asserts that two arrays of `uint256` values are not equal.\"},\"assertNotEq(uint256[],uint256[],string)\":{\"notice\":\"Asserts that two arrays of `uint256` values are not equal and includes error message into revert string on failure.\"},\"assertNotEqDecimal(int256,int256,uint256)\":{\"notice\":\"Asserts that two `int256` values are not equal, formatting them with decimals in failure message.\"},\"assertNotEqDecimal(int256,int256,uint256,string)\":{\"notice\":\"Asserts that two `int256` values are not equal, formatting them with decimals in failure message. Includes error message into revert string on failure.\"},\"assertNotEqDecimal(uint256,uint256,uint256)\":{\"notice\":\"Asserts that two `uint256` values are not equal, formatting them with decimals in failure message.\"},\"assertNotEqDecimal(uint256,uint256,uint256,string)\":{\"notice\":\"Asserts that two `uint256` values are not equal, formatting them with decimals in failure message. Includes error message into revert string on failure.\"},\"assertTrue(bool)\":{\"notice\":\"Asserts that the given condition is true.\"},\"assertTrue(bool,string)\":{\"notice\":\"Asserts that the given condition is true and includes error message into revert string on failure.\"},\"assume(bool)\":{\"notice\":\"If the condition is false, discard this run's fuzz inputs and generate new ones.\"},\"assumeNoRevert((address,bool,bytes))\":{\"notice\":\"Discard this run's fuzz inputs and generate new ones if next call reverts with the potential revert parameters.\"},\"assumeNoRevert((address,bool,bytes)[])\":{\"notice\":\"Discard this run's fuzz inputs and generate new ones if next call reverts with the any of the potential revert parameters.\"},\"assumeNoRevert()\":{\"notice\":\"Discard this run's fuzz inputs and generate new ones if next call reverted.\"},\"attachBlob(bytes)\":{\"notice\":\"Attach an EIP-4844 blob to the next call\"},\"attachDelegation((uint8,bytes32,bytes32,uint64,address))\":{\"notice\":\"Designate the next call as an EIP-7702 transaction\"},\"attachDelegation((uint8,bytes32,bytes32,uint64,address),bool)\":{\"notice\":\"Designate the next call as an EIP-7702 transaction, with optional cross-chain validity.\"},\"bound(int256,int256,int256)\":{\"notice\":\"Returns an int256 value bounded in given range and different from the current one.\"},\"bound(uint256,uint256,uint256)\":{\"notice\":\"Returns an uint256 value bounded in given range and different from the current one.\"},\"breakpoint(string)\":{\"notice\":\"Writes a breakpoint to jump to in the debugger.\"},\"breakpoint(string,bool)\":{\"notice\":\"Writes a conditional breakpoint to jump to in the debugger.\"},\"broadcast()\":{\"notice\":\"Has the next call (at this call depth only) create transactions that can later be signed and sent onchain. Broadcasting address is determined by checking the following in order: 1. If `--sender` argument was provided, that address is used. 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used.\"},\"broadcast(address)\":{\"notice\":\"Has the next call (at this call depth only) create a transaction with the address provided as the sender that can later be signed and sent onchain.\"},\"broadcast(uint256)\":{\"notice\":\"Has the next call (at this call depth only) create a transaction with the private key provided as the sender that can later be signed and sent onchain.\"},\"broadcastRawTransaction(bytes)\":{\"notice\":\"Takes a signed transaction and broadcasts it to the network.\"},\"closeFile(string)\":{\"notice\":\"Closes file for reading, resetting the offset and allowing to read it from beginning with readLine. `path` is relative to the project root.\"},\"computeCreate2Address(bytes32,bytes32)\":{\"notice\":\"Compute the address of a contract created with CREATE2 using the default CREATE2 deployer.\"},\"computeCreate2Address(bytes32,bytes32,address)\":{\"notice\":\"Compute the address of a contract created with CREATE2 using the given CREATE2 deployer.\"},\"computeCreateAddress(address,uint256)\":{\"notice\":\"Compute the address a contract will be deployed at for a given deployer address and nonce.\"},\"contains(string,string)\":{\"notice\":\"Returns true if `search` is found in `subject`, false otherwise.\"},\"copyFile(string,string)\":{\"notice\":\"Copies the contents of one file to another. This function will **overwrite** the contents of `to`. On success, the total number of bytes copied is returned and it is equal to the length of the `to` file as reported by `metadata`. Both `from` and `to` are relative to the project root.\"},\"copyStorage(address,address)\":{\"notice\":\"Utility cheatcode to copy storage of `from` contract to another `to` contract.\"},\"createDir(string,bool)\":{\"notice\":\"Creates a new, empty directory at the provided path. This cheatcode will revert in the following situations, but is not limited to just these cases: - User lacks permissions to modify `path`. - A parent of the given path doesn't exist and `recursive` is false. - `path` already exists and `recursive` is false. `path` is relative to the project root.\"},\"createWallet(string)\":{\"notice\":\"Derives a private key from the name, labels the account with that name, and returns the wallet.\"},\"createWallet(uint256)\":{\"notice\":\"Generates a wallet from the private key and returns the wallet.\"},\"createWallet(uint256,string)\":{\"notice\":\"Generates a wallet from the private key, labels the account with that name, and returns the wallet.\"},\"deployCode(string)\":{\"notice\":\"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional.\"},\"deployCode(string,bytes)\":{\"notice\":\"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments.\"},\"deployCode(string,bytes,bytes32)\":{\"notice\":\"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments.\"},\"deployCode(string,bytes,uint256)\":{\"notice\":\"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments and `msg.value`.\"},\"deployCode(string,bytes,uint256,bytes32)\":{\"notice\":\"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments and `msg.value`.\"},\"deployCode(string,bytes32)\":{\"notice\":\"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional.\"},\"deployCode(string,uint256)\":{\"notice\":\"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts `msg.value`.\"},\"deployCode(string,uint256,bytes32)\":{\"notice\":\"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts `msg.value`.\"},\"deriveKey(string,string,uint32)\":{\"notice\":\"Derive a private key from a provided mnemonic string (or mnemonic file path) at `{derivationPath}{index}`.\"},\"deriveKey(string,string,uint32,string)\":{\"notice\":\"Derive a private key from a provided mnemonic string (or mnemonic file path) in the specified language at `{derivationPath}{index}`.\"},\"deriveKey(string,uint32)\":{\"notice\":\"Derive a private key from a provided mnemonic string (or mnemonic file path) at the derivation path `m/44'/60'/0'/0/{index}`.\"},\"deriveKey(string,uint32,string)\":{\"notice\":\"Derive a private key from a provided mnemonic string (or mnemonic file path) in the specified language at the derivation path `m/44'/60'/0'/0/{index}`.\"},\"eip712HashStruct(string,bytes)\":{\"notice\":\"Generates the struct hash of the canonical EIP-712 type representation and its abi-encoded data. Supports 2 different inputs: 1. Name of the type (i.e. \\\"PermitSingle\\\"): * requires previous binding generation with `forge bind-json`. * bindings will be retrieved from the path configured in `foundry.toml`. 2. String representation of the type (i.e. \\\"Foo(Bar bar) Bar(uint256 baz)\\\"). * Note: the cheatcode will use the canonical type even if the input is malformated with the wrong order of elements or with extra whitespaces.\"},\"eip712HashStruct(string,string,bytes)\":{\"notice\":\"Generates the struct hash of the canonical EIP-712 type representation and its abi-encoded data. Requires previous binding generation with `forge bind-json`. Params: * `bindingsPath`: path where the output of `forge bind-json` is stored. * `typeName`: Name of the type (i.e. \\\"PermitSingle\\\"). * `abiEncodedData`: ABI-encoded data for the struct that is being hashed.\"},\"eip712HashType(string)\":{\"notice\":\"Generates the hash of the canonical EIP-712 type representation. Supports 2 different inputs: 1. Name of the type (i.e. \\\"Transaction\\\"): * requires previous binding generation with `forge bind-json`. * bindings will be retrieved from the path configured in `foundry.toml`. 2. String representation of the type (i.e. \\\"Foo(Bar bar) Bar(uint256 baz)\\\"). * Note: the cheatcode will output the canonical type even if the input is malformated with the wrong order of elements or with extra whitespaces.\"},\"eip712HashType(string,string)\":{\"notice\":\"Generates the hash of the canonical EIP-712 type representation. Requires previous binding generation with `forge bind-json`. Params: * `bindingsPath`: path where the output of `forge bind-json` is stored. * `typeName`: Name of the type (i.e. \\\"Transaction\\\").\"},\"eip712HashTypedData(string)\":{\"notice\":\"Generates a ready-to-sign digest of human-readable typed data following the EIP-712 standard.\"},\"ensNamehash(string)\":{\"notice\":\"Returns ENS namehash for provided string.\"},\"envAddress(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `address`. Reverts if the variable was not found or could not be parsed.\"},\"envAddress(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"envBool(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `bool`. Reverts if the variable was not found or could not be parsed.\"},\"envBool(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"envBytes(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `bytes`. Reverts if the variable was not found or could not be parsed.\"},\"envBytes(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"envBytes32(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `bytes32`. Reverts if the variable was not found or could not be parsed.\"},\"envBytes32(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"envExists(string)\":{\"notice\":\"Gets the environment variable `name` and returns true if it exists, else returns false.\"},\"envInt(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `int256`. Reverts if the variable was not found or could not be parsed.\"},\"envInt(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"envOr(string,address)\":{\"notice\":\"Gets the environment variable `name` and parses it as `address`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,bool)\":{\"notice\":\"Gets the environment variable `name` and parses it as `bool`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,bytes)\":{\"notice\":\"Gets the environment variable `name` and parses it as `bytes`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,bytes32)\":{\"notice\":\"Gets the environment variable `name` and parses it as `bytes32`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,int256)\":{\"notice\":\"Gets the environment variable `name` and parses it as `int256`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `string`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,address[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,bool[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,bytes32[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,bytes[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,int256[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,string[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,string,uint256[])\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envOr(string,uint256)\":{\"notice\":\"Gets the environment variable `name` and parses it as `uint256`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found.\"},\"envString(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `string`. Reverts if the variable was not found or could not be parsed.\"},\"envString(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"envUint(string)\":{\"notice\":\"Gets the environment variable `name` and parses it as `uint256`. Reverts if the variable was not found or could not be parsed.\"},\"envUint(string,string)\":{\"notice\":\"Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. Reverts if the variable was not found or could not be parsed.\"},\"eth_getLogs(uint256,uint256,address,bytes32[])\":{\"notice\":\"Gets all the logs according to specified filter.\"},\"exists(string)\":{\"notice\":\"Returns true if the given path points to an existing entity, else returns false.\"},\"ffi(string[])\":{\"notice\":\"Performs a foreign function call via the terminal.\"},\"foundryVersionAtLeast(string)\":{\"notice\":\"Returns true if the current Foundry version is greater than or equal to the given version. The given version string must be in the format `major.minor.patch`. This is equivalent to `foundryVersionCmp(version) >= 0`.\"},\"foundryVersionCmp(string)\":{\"notice\":\"Compares the current Foundry version with the given version string. The given version string must be in the format `major.minor.patch`. Returns: -1 if current Foundry version is less than the given version 0 if current Foundry version equals the given version 1 if current Foundry version is greater than the given version This result can then be used with a comparison operator against `0`. For example, to check if the current Foundry version is greater than or equal to `1.0.0`: `if (foundryVersionCmp(\\\"1.0.0\\\") >= 0) { ... }`\"},\"fsMetadata(string)\":{\"notice\":\"Given a path, query the file system to get information about a file, directory, etc.\"},\"getArtifactPathByCode(bytes)\":{\"notice\":\"Gets the artifact path from code (aka. creation code).\"},\"getArtifactPathByDeployedCode(bytes)\":{\"notice\":\"Gets the artifact path from deployed code (aka. runtime code).\"},\"getBlobBaseFee()\":{\"notice\":\"Gets the current `block.blobbasefee`. You should use this instead of `block.blobbasefee` if you use `vm.blobBaseFee`, as `block.blobbasefee` is assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180\"},\"getBlockNumber()\":{\"notice\":\"Gets the current `block.number`. You should use this instead of `block.number` if you use `vm.roll`, as `block.number` is assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180\"},\"getBlockTimestamp()\":{\"notice\":\"Gets the current `block.timestamp`. You should use this instead of `block.timestamp` if you use `vm.warp`, as `block.timestamp` is assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180\"},\"getBroadcast(string,uint64,uint8)\":{\"notice\":\"Returns the most recent broadcast for the given contract on `chainId` matching `txType`. For example: The most recent deployment can be fetched by passing `txType` as `CREATE` or `CREATE2`. The most recent call can be fetched by passing `txType` as `CALL`.\"},\"getBroadcasts(string,uint64)\":{\"notice\":\"Returns all broadcasts for the given contract on `chainId`. Sorted such that the most recent broadcast is the first element, and the oldest is the last. i.e descending order of BroadcastTxSummary.blockNumber.\"},\"getBroadcasts(string,uint64,uint8)\":{\"notice\":\"Returns all broadcasts for the given contract on `chainId` with the specified `txType`. Sorted such that the most recent broadcast is the first element, and the oldest is the last. i.e descending order of BroadcastTxSummary.blockNumber.\"},\"getChain(string)\":{\"notice\":\"Returns a Chain struct for specific alias\"},\"getChain(uint256)\":{\"notice\":\"Returns a Chain struct for specific chainId\"},\"getChainId()\":{\"notice\":\"Gets the current `block.chainid` of the currently selected environment. You should use this instead of `block.chainid` if you use `vm.selectFork` or `vm.createSelectFork`, as `block.chainid` could be assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180\"},\"getCode(string)\":{\"notice\":\"Gets the creation bytecode from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional.\"},\"getDeployedCode(string)\":{\"notice\":\"Gets the deployed bytecode from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional.\"},\"getDeployment(string)\":{\"notice\":\"Returns the most recent deployment for the current `chainId`.\"},\"getDeployment(string,uint64)\":{\"notice\":\"Returns the most recent deployment for the given contract on `chainId`\"},\"getDeployments(string,uint64)\":{\"notice\":\"Returns all deployments for the given contract on `chainId` Sorted in descending order of deployment time i.e descending order of BroadcastTxSummary.blockNumber. The most recent deployment is the first element, and the oldest is the last.\"},\"getFoundryVersion()\":{\"notice\":\"Returns the Foundry version. Format: -+.. Sample output: 0.3.0-nightly+3cb96bde9b.1737036656.debug Note: Build timestamps may vary slightly across platforms due to separate CI jobs. For reliable version comparisons, use UNIX format (e.g., >= 1700000000) to compare timestamps while ignoring minor time differences.\"},\"getLabel(address)\":{\"notice\":\"Gets the label for the specified address.\"},\"getMappingKeyAndParentOf(address,bytes32)\":{\"notice\":\"Gets the map key and parent of a mapping at a given slot, for a given address.\"},\"getMappingLength(address,bytes32)\":{\"notice\":\"Gets the number of elements in the mapping at the given slot, for a given address.\"},\"getMappingSlotAt(address,bytes32,uint256)\":{\"notice\":\"Gets the elements at index idx of the mapping at the given slot, for a given address. The index must be less than the length of the mapping (i.e. the number of keys in the mapping).\"},\"getNonce((address,uint256,uint256,uint256))\":{\"notice\":\"Get the nonce of a `Wallet`.\"},\"getNonce(address)\":{\"notice\":\"Gets the nonce of an account.\"},\"getRawBlockHeader(uint256)\":{\"notice\":\"Gets the RLP encoded block header for a given block number. Returns the block header in the same format as `cast block --raw`.\"},\"getRecordedLogs()\":{\"notice\":\"Gets all the recorded logs.\"},\"getStateDiff()\":{\"notice\":\"Returns state diffs from current `vm.startStateDiffRecording` session.\"},\"getStateDiffJson()\":{\"notice\":\"Returns state diffs from current `vm.startStateDiffRecording` session, in json format.\"},\"getStorageAccesses()\":{\"notice\":\"Returns an array of `StorageAccess` from current `vm.stateStateDiffRecording` session\"},\"getWallets()\":{\"notice\":\"Returns addresses of available unlocked wallets in the script environment.\"},\"indexOf(string,string)\":{\"notice\":\"Returns the index of the first occurrence of a `key` in an `input` string. Returns `NOT_FOUND` (i.e. `type(uint256).max`) if the `key` is not found. Returns 0 in case of an empty `key`.\"},\"isContext(uint8)\":{\"notice\":\"Returns true if `forge` command was executed in given context.\"},\"isDir(string)\":{\"notice\":\"Returns true if the path exists on disk and is pointing at a directory, else returns false.\"},\"isFile(string)\":{\"notice\":\"Returns true if the path exists on disk and is pointing at a regular file, else returns false.\"},\"keyExists(string,string)\":{\"notice\":\"Checks if `key` exists in a JSON object `keyExists` is being deprecated in favor of `keyExistsJson`. It will be removed in future versions.\"},\"keyExistsJson(string,string)\":{\"notice\":\"Checks if `key` exists in a JSON object.\"},\"keyExistsToml(string,string)\":{\"notice\":\"Checks if `key` exists in a TOML table.\"},\"label(address,string)\":{\"notice\":\"Labels an address in call traces.\"},\"lastCallGas()\":{\"notice\":\"Gets the gas used in the last call from the callee perspective.\"},\"load(address,bytes32)\":{\"notice\":\"Loads a storage slot from an address.\"},\"parseAddress(string)\":{\"notice\":\"Parses the given `string` into an `address`.\"},\"parseBool(string)\":{\"notice\":\"Parses the given `string` into a `bool`.\"},\"parseBytes(string)\":{\"notice\":\"Parses the given `string` into `bytes`.\"},\"parseBytes32(string)\":{\"notice\":\"Parses the given `string` into a `bytes32`.\"},\"parseInt(string)\":{\"notice\":\"Parses the given `string` into a `int256`.\"},\"parseJson(string)\":{\"notice\":\"ABI-encodes a JSON object.\"},\"parseJson(string,string)\":{\"notice\":\"ABI-encodes a JSON object at `key`.\"},\"parseJsonAddress(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `address`.\"},\"parseJsonAddressArray(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `address[]`.\"},\"parseJsonBool(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `bool`.\"},\"parseJsonBoolArray(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `bool[]`.\"},\"parseJsonBytes(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `bytes`.\"},\"parseJsonBytes32(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `bytes32`.\"},\"parseJsonBytes32Array(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `bytes32[]`.\"},\"parseJsonBytesArray(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `bytes[]`.\"},\"parseJsonInt(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `int256`.\"},\"parseJsonIntArray(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `int256[]`.\"},\"parseJsonKeys(string,string)\":{\"notice\":\"Returns an array of all the keys in a JSON object.\"},\"parseJsonString(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `string`.\"},\"parseJsonStringArray(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `string[]`.\"},\"parseJsonType(string,string)\":{\"notice\":\"Parses a string of JSON data and coerces it to type corresponding to `typeDescription`.\"},\"parseJsonType(string,string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to type corresponding to `typeDescription`.\"},\"parseJsonTypeArray(string,string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to type array corresponding to `typeDescription`.\"},\"parseJsonUint(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `uint256`.\"},\"parseJsonUintArray(string,string)\":{\"notice\":\"Parses a string of JSON data at `key` and coerces it to `uint256[]`.\"},\"parseToml(string)\":{\"notice\":\"ABI-encodes a TOML table.\"},\"parseToml(string,string)\":{\"notice\":\"ABI-encodes a TOML table at `key`.\"},\"parseTomlAddress(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `address`.\"},\"parseTomlAddressArray(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `address[]`.\"},\"parseTomlBool(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `bool`.\"},\"parseTomlBoolArray(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `bool[]`.\"},\"parseTomlBytes(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `bytes`.\"},\"parseTomlBytes32(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `bytes32`.\"},\"parseTomlBytes32Array(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `bytes32[]`.\"},\"parseTomlBytesArray(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `bytes[]`.\"},\"parseTomlInt(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `int256`.\"},\"parseTomlIntArray(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `int256[]`.\"},\"parseTomlKeys(string,string)\":{\"notice\":\"Returns an array of all the keys in a TOML table.\"},\"parseTomlString(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `string`.\"},\"parseTomlStringArray(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `string[]`.\"},\"parseTomlType(string,string)\":{\"notice\":\"Parses a string of TOML data and coerces it to type corresponding to `typeDescription`.\"},\"parseTomlType(string,string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to type corresponding to `typeDescription`.\"},\"parseTomlTypeArray(string,string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to type array corresponding to `typeDescription`.\"},\"parseTomlUint(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `uint256`.\"},\"parseTomlUintArray(string,string)\":{\"notice\":\"Parses a string of TOML data at `key` and coerces it to `uint256[]`.\"},\"parseUint(string)\":{\"notice\":\"Parses the given `string` into a `uint256`.\"},\"pauseGasMetering()\":{\"notice\":\"Pauses gas metering (i.e. gas usage is not counted). Noop if already paused.\"},\"pauseTracing()\":{\"notice\":\"Pauses collection of call traces. Useful in cases when you want to skip tracing of complex calls which are not useful for debugging.\"},\"projectRoot()\":{\"notice\":\"Get the path of the current project root.\"},\"prompt(string)\":{\"notice\":\"Prompts the user for a string value in the terminal.\"},\"promptAddress(string)\":{\"notice\":\"Prompts the user for an address in the terminal.\"},\"promptSecret(string)\":{\"notice\":\"Prompts the user for a hidden string value in the terminal.\"},\"promptSecretUint(string)\":{\"notice\":\"Prompts the user for hidden uint256 in the terminal (usually pk).\"},\"promptUint(string)\":{\"notice\":\"Prompts the user for uint256 in the terminal.\"},\"publicKeyP256(uint256)\":{\"notice\":\"Derives secp256r1 public key from the provided `privateKey`.\"},\"randomAddress()\":{\"notice\":\"Returns a random `address`.\"},\"randomBool()\":{\"notice\":\"Returns a random `bool`.\"},\"randomBytes(uint256)\":{\"notice\":\"Returns a random byte array value of the given length.\"},\"randomBytes4()\":{\"notice\":\"Returns a random fixed-size byte array of length 4.\"},\"randomBytes8()\":{\"notice\":\"Returns a random fixed-size byte array of length 8.\"},\"randomInt()\":{\"notice\":\"Returns a random `int256` value.\"},\"randomInt(uint256)\":{\"notice\":\"Returns a random `int256` value of given bits.\"},\"randomUint()\":{\"notice\":\"Returns a random uint256 value.\"},\"randomUint(uint256)\":{\"notice\":\"Returns a random `uint256` value of given bits.\"},\"randomUint(uint256,uint256)\":{\"notice\":\"Returns random uint256 value between the provided range (=min..=max).\"},\"readDir(string)\":{\"notice\":\"Reads the directory at the given path recursively, up to `maxDepth`. `maxDepth` defaults to 1, meaning only the direct children of the given directory will be returned. Follows symbolic links if `followLinks` is true.\"},\"readDir(string,uint64)\":{\"notice\":\"See `readDir(string)`.\"},\"readDir(string,uint64,bool)\":{\"notice\":\"See `readDir(string)`.\"},\"readFile(string)\":{\"notice\":\"Reads the entire content of file to string. `path` is relative to the project root.\"},\"readFileBinary(string)\":{\"notice\":\"Reads the entire content of file as binary. `path` is relative to the project root.\"},\"readLine(string)\":{\"notice\":\"Reads next line of file to string.\"},\"readLink(string)\":{\"notice\":\"Reads a symbolic link, returning the path that the link points to. This cheatcode will revert in the following situations, but is not limited to just these cases: - `path` is not a symbolic link. - `path` does not exist.\"},\"record()\":{\"notice\":\"Records all storage reads and writes. Use `accesses` to get the recorded data. Subsequent calls to `record` will clear the previous data.\"},\"recordLogs()\":{\"notice\":\"Record all the transaction logs.\"},\"rememberKey(uint256)\":{\"notice\":\"Adds a private key to the local forge wallet and returns the address.\"},\"rememberKeys(string,string,string,uint32)\":{\"notice\":\"Derive a set number of wallets from a mnemonic in the specified language at the derivation path `m/44'/60'/0'/0/{0..count}`. The respective private keys are saved to the local forge wallet for later use and their addresses are returned.\"},\"rememberKeys(string,string,uint32)\":{\"notice\":\"Derive a set number of wallets from a mnemonic at the derivation path `m/44'/60'/0'/0/{0..count}`. The respective private keys are saved to the local forge wallet for later use and their addresses are returned.\"},\"removeDir(string,bool)\":{\"notice\":\"Removes a directory at the provided path. This cheatcode will revert in the following situations, but is not limited to just these cases: - `path` doesn't exist. - `path` isn't a directory. - User lacks permissions to modify `path`. - The directory is not empty and `recursive` is false. `path` is relative to the project root.\"},\"removeFile(string)\":{\"notice\":\"Removes a file from the filesystem. This cheatcode will revert in the following situations, but is not limited to just these cases: - `path` points to a directory. - The file doesn't exist. - The user lacks permissions to remove the file. `path` is relative to the project root.\"},\"replace(string,string,string)\":{\"notice\":\"Replaces occurrences of `from` in the given `string` with `to`.\"},\"resetGasMetering()\":{\"notice\":\"Reset gas metering (i.e. gas usage is set to gas limit).\"},\"resolveEnv(string)\":{\"notice\":\"Resolves the env variable placeholders of a given input string.\"},\"resumeGasMetering()\":{\"notice\":\"Resumes gas metering (i.e. gas usage is counted again). Noop if already on.\"},\"resumeTracing()\":{\"notice\":\"Unpauses collection of call traces.\"},\"rpc(string,string)\":{\"notice\":\"Performs an Ethereum JSON-RPC request to the current fork URL.\"},\"rpc(string,string,string)\":{\"notice\":\"Performs an Ethereum JSON-RPC request to the given endpoint.\"},\"rpcUrl(string)\":{\"notice\":\"Returns the RPC url for the given alias.\"},\"rpcUrlStructs()\":{\"notice\":\"Returns all rpc urls and their aliases as structs.\"},\"rpcUrls()\":{\"notice\":\"Returns all rpc urls and their aliases `[alias, url][]`.\"},\"serializeAddress(string,string,address)\":{\"notice\":\"See `serializeJson`.\"},\"serializeAddress(string,string,address[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeBool(string,string,bool)\":{\"notice\":\"See `serializeJson`.\"},\"serializeBool(string,string,bool[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeBytes(string,string,bytes)\":{\"notice\":\"See `serializeJson`.\"},\"serializeBytes(string,string,bytes[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeBytes32(string,string,bytes32)\":{\"notice\":\"See `serializeJson`.\"},\"serializeBytes32(string,string,bytes32[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeInt(string,string,int256)\":{\"notice\":\"See `serializeJson`.\"},\"serializeInt(string,string,int256[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeJson(string,string)\":{\"notice\":\"Serializes a key and value to a JSON object stored in-memory that can be later written to a file. Returns the stringified version of the specific JSON file up to that moment.\"},\"serializeJsonType(string,bytes)\":{\"notice\":\"See `serializeJson`.\"},\"serializeJsonType(string,string,string,bytes)\":{\"notice\":\"See `serializeJson`.\"},\"serializeString(string,string,string)\":{\"notice\":\"See `serializeJson`.\"},\"serializeString(string,string,string[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeUint(string,string,uint256)\":{\"notice\":\"See `serializeJson`.\"},\"serializeUint(string,string,uint256[])\":{\"notice\":\"See `serializeJson`.\"},\"serializeUintToHex(string,string,uint256)\":{\"notice\":\"See `serializeJson`.\"},\"setArbitraryStorage(address)\":{\"notice\":\"Utility cheatcode to set arbitrary storage for given target address.\"},\"setArbitraryStorage(address,bool)\":{\"notice\":\"Utility cheatcode to set arbitrary storage for given target address and overwrite any storage slots that have been previously set.\"},\"setEnv(string,string)\":{\"notice\":\"Sets environment variables.\"},\"setSeed(uint256)\":{\"notice\":\"Set RNG seed.\"},\"shuffle(uint256[])\":{\"notice\":\"Randomly shuffles an array.\"},\"sign((address,uint256,uint256,uint256),bytes32)\":{\"notice\":\"Signs data with a `Wallet`.\"},\"sign(address,bytes32)\":{\"notice\":\"Signs `digest` with signer provided to script using the secp256k1 curve. Raises error if none of the signers passed into the script have provided address.\"},\"sign(bytes32)\":{\"notice\":\"Signs `digest` with signer provided to script using the secp256k1 curve. If `--sender` is provided, the signer with provided address is used, otherwise, if exactly one signer is provided to the script, that signer is used. Raises error if signer passed through `--sender` does not match any unlocked signers or if `--sender` is not provided and not exactly one signer is passed to the script.\"},\"sign(uint256,bytes32)\":{\"notice\":\"Signs `digest` with `privateKey` using the secp256k1 curve.\"},\"signAndAttachDelegation(address,uint256)\":{\"notice\":\"Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction\"},\"signAndAttachDelegation(address,uint256,bool)\":{\"notice\":\"Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction, with optional cross-chain validity.\"},\"signAndAttachDelegation(address,uint256,uint64)\":{\"notice\":\"Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction for specific nonce\"},\"signCompact((address,uint256,uint256,uint256),bytes32)\":{\"notice\":\"Signs data with a `Wallet`. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes.\"},\"signCompact(address,bytes32)\":{\"notice\":\"Signs `digest` with signer provided to script using the secp256k1 curve. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes. Raises error if none of the signers passed into the script have provided address.\"},\"signCompact(bytes32)\":{\"notice\":\"Signs `digest` with signer provided to script using the secp256k1 curve. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes. If `--sender` is provided, the signer with provided address is used, otherwise, if exactly one signer is provided to the script, that signer is used. Raises error if signer passed through `--sender` does not match any unlocked signers or if `--sender` is not provided and not exactly one signer is passed to the script.\"},\"signCompact(uint256,bytes32)\":{\"notice\":\"Signs `digest` with `privateKey` using the secp256k1 curve. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes.\"},\"signDelegation(address,uint256)\":{\"notice\":\"Sign an EIP-7702 authorization for delegation\"},\"signDelegation(address,uint256,bool)\":{\"notice\":\"Sign an EIP-7702 authorization for delegation, with optional cross-chain validity.\"},\"signDelegation(address,uint256,uint64)\":{\"notice\":\"Sign an EIP-7702 authorization for delegation for specific nonce\"},\"signP256(uint256,bytes32)\":{\"notice\":\"Signs `digest` with `privateKey` using the secp256r1 curve.\"},\"sleep(uint256)\":{\"notice\":\"Suspends execution of the main thread for `duration` milliseconds.\"},\"sort(uint256[])\":{\"notice\":\"Sorts an array in ascending order.\"},\"split(string,string)\":{\"notice\":\"Splits the given `string` into an array of strings divided by the `delimiter`.\"},\"startBroadcast()\":{\"notice\":\"Has all subsequent calls (at this call depth only) create transactions that can later be signed and sent onchain. Broadcasting address is determined by checking the following in order: 1. If `--sender` argument was provided, that address is used. 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used.\"},\"startBroadcast(address)\":{\"notice\":\"Has all subsequent calls (at this call depth only) create transactions with the address provided that can later be signed and sent onchain.\"},\"startBroadcast(uint256)\":{\"notice\":\"Has all subsequent calls (at this call depth only) create transactions with the private key provided that can later be signed and sent onchain.\"},\"startDebugTraceRecording()\":{\"notice\":\"Records the debug trace during the run.\"},\"startMappingRecording()\":{\"notice\":\"Starts recording all map SSTOREs for later retrieval.\"},\"startStateDiffRecording()\":{\"notice\":\"Record all account accesses as part of CREATE, CALL or SELFDESTRUCT opcodes in order, along with the context of the calls\"},\"stopAndReturnDebugTraceRecording()\":{\"notice\":\"Stop debug trace recording and returns the recorded debug trace.\"},\"stopAndReturnStateDiff()\":{\"notice\":\"Returns an ordered array of all account accesses from a `vm.startStateDiffRecording` session.\"},\"stopBroadcast()\":{\"notice\":\"Stops collecting onchain transactions.\"},\"stopMappingRecording()\":{\"notice\":\"Stops recording all map SSTOREs for later retrieval and clears the recorded data.\"},\"stopRecord()\":{\"notice\":\"Stops recording storage reads and writes.\"},\"toBase64(bytes)\":{\"notice\":\"Encodes a `bytes` value to a base64 string.\"},\"toBase64(string)\":{\"notice\":\"Encodes a `string` value to a base64 string.\"},\"toBase64URL(bytes)\":{\"notice\":\"Encodes a `bytes` value to a base64url string.\"},\"toBase64URL(string)\":{\"notice\":\"Encodes a `string` value to a base64url string.\"},\"toLowercase(string)\":{\"notice\":\"Converts the given `string` value to Lowercase.\"},\"toString(address)\":{\"notice\":\"Converts the given value to a `string`.\"},\"toString(bool)\":{\"notice\":\"Converts the given value to a `string`.\"},\"toString(bytes)\":{\"notice\":\"Converts the given value to a `string`.\"},\"toString(bytes32)\":{\"notice\":\"Converts the given value to a `string`.\"},\"toString(int256)\":{\"notice\":\"Converts the given value to a `string`.\"},\"toString(uint256)\":{\"notice\":\"Converts the given value to a `string`.\"},\"toUppercase(string)\":{\"notice\":\"Converts the given `string` value to Uppercase.\"},\"trim(string)\":{\"notice\":\"Trims leading and trailing whitespace from the given `string` value.\"},\"tryFfi(string[])\":{\"notice\":\"Performs a foreign function call via terminal and returns the exit code, stdout, and stderr.\"},\"unixTime()\":{\"notice\":\"Returns the time since unix epoch in milliseconds.\"},\"writeFile(string,string)\":{\"notice\":\"Writes data to file, creating a file if it does not exist, and entirely replacing its contents if it does. `path` is relative to the project root.\"},\"writeFileBinary(string,bytes)\":{\"notice\":\"Writes binary data to a file, creating a file if it does not exist, and entirely replacing its contents if it does. `path` is relative to the project root.\"},\"writeJson(string,string)\":{\"notice\":\"Write a serialized JSON object to a file. If the file exists, it will be overwritten.\"},\"writeJson(string,string,string)\":{\"notice\":\"Write a serialized JSON object to an **existing** JSON file, replacing a value with key = This is useful to replace a specific value of a JSON file, without having to parse the entire thing. This cheatcode will create new keys if they didn't previously exist.\"},\"writeLine(string,string)\":{\"notice\":\"Writes line to file, creating a file if it does not exist. `path` is relative to the project root.\"},\"writeToml(string,string)\":{\"notice\":\"Takes serialized JSON, converts to TOML and write a serialized TOML to a file.\"},\"writeToml(string,string,string)\":{\"notice\":\"Takes serialized JSON, converts to TOML and write a serialized TOML table to an **existing** TOML file, replacing a value with key = This is useful to replace a specific value of a TOML file, without having to parse the entire thing. This cheatcode will create new keys if they didn't previously exist.\"}},\"notice\":\"The `VmSafe` interface does not allow manipulation of the EVM state or other actions that may result in Script simulations differing from on-chain execution. It is recommended to only use these cheats in scripts.\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/Vm.sol\":\"VmSafe\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"address","name":"target","type":"address"}],"stateMutability":"view","type":"function","name":"accesses","outputs":[{"internalType":"bytes32[]","name":"readSlots","type":"bytes32[]"},{"internalType":"bytes32[]","name":"writeSlots","type":"bytes32[]"}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"pure","type":"function","name":"addr","outputs":[{"internalType":"address","name":"keyAddr","type":"address"}]},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbs"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbs"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbs"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbs"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbsDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbsDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbsDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqAbsDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRel"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRel"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRel"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRel"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRelDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRelDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRelDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"maxPercentDelta","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertApproxEqRelDecimal"},{"inputs":[{"internalType":"bytes32[]","name":"left","type":"bytes32[]"},{"internalType":"bytes32[]","name":"right","type":"bytes32[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"int256[]","name":"left","type":"int256[]"},{"internalType":"int256[]","name":"right","type":"int256[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"address","name":"left","type":"address"},{"internalType":"address","name":"right","type":"address"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"string","name":"left","type":"string"},{"internalType":"string","name":"right","type":"string"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"address[]","name":"left","type":"address[]"},{"internalType":"address[]","name":"right","type":"address[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"address[]","name":"left","type":"address[]"},{"internalType":"address[]","name":"right","type":"address[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bool","name":"left","type":"bool"},{"internalType":"bool","name":"right","type":"bool"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"address","name":"left","type":"address"},{"internalType":"address","name":"right","type":"address"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"uint256[]","name":"left","type":"uint256[]"},{"internalType":"uint256[]","name":"right","type":"uint256[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bool[]","name":"left","type":"bool[]"},{"internalType":"bool[]","name":"right","type":"bool[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"int256[]","name":"left","type":"int256[]"},{"internalType":"int256[]","name":"right","type":"int256[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes32","name":"left","type":"bytes32"},{"internalType":"bytes32","name":"right","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"uint256[]","name":"left","type":"uint256[]"},{"internalType":"uint256[]","name":"right","type":"uint256[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes","name":"left","type":"bytes"},{"internalType":"bytes","name":"right","type":"bytes"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes32","name":"left","type":"bytes32"},{"internalType":"bytes32","name":"right","type":"bytes32"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"string[]","name":"left","type":"string[]"},{"internalType":"string[]","name":"right","type":"string[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes32[]","name":"left","type":"bytes32[]"},{"internalType":"bytes32[]","name":"right","type":"bytes32[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes","name":"left","type":"bytes"},{"internalType":"bytes","name":"right","type":"bytes"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bool[]","name":"left","type":"bool[]"},{"internalType":"bool[]","name":"right","type":"bool[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes[]","name":"left","type":"bytes[]"},{"internalType":"bytes[]","name":"right","type":"bytes[]"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"string[]","name":"left","type":"string[]"},{"internalType":"string[]","name":"right","type":"string[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"string","name":"left","type":"string"},{"internalType":"string","name":"right","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bytes[]","name":"left","type":"bytes[]"},{"internalType":"bytes[]","name":"right","type":"bytes[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"bool","name":"left","type":"bool"},{"internalType":"bool","name":"right","type":"bool"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"}],"stateMutability":"pure","type":"function","name":"assertEq"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertEqDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertEqDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEqDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertEqDecimal"},{"inputs":[{"internalType":"bool","name":"condition","type":"bool"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertFalse"},{"inputs":[{"internalType":"bool","name":"condition","type":"bool"}],"stateMutability":"pure","type":"function","name":"assertFalse"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"}],"stateMutability":"pure","type":"function","name":"assertGe"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGe"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertGe"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGe"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertGeDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGeDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGeDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertGeDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"}],"stateMutability":"pure","type":"function","name":"assertGt"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGt"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertGt"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGt"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGtDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertGtDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertGtDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertGtDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLe"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertLe"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"}],"stateMutability":"pure","type":"function","name":"assertLe"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLe"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertLeDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLeDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLeDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertLeDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"}],"stateMutability":"pure","type":"function","name":"assertLt"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLt"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLt"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertLt"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertLtDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLtDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertLtDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertLtDecimal"},{"inputs":[{"internalType":"bytes32[]","name":"left","type":"bytes32[]"},{"internalType":"bytes32[]","name":"right","type":"bytes32[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"int256[]","name":"left","type":"int256[]"},{"internalType":"int256[]","name":"right","type":"int256[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bool","name":"left","type":"bool"},{"internalType":"bool","name":"right","type":"bool"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes[]","name":"left","type":"bytes[]"},{"internalType":"bytes[]","name":"right","type":"bytes[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bool","name":"left","type":"bool"},{"internalType":"bool","name":"right","type":"bool"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bool[]","name":"left","type":"bool[]"},{"internalType":"bool[]","name":"right","type":"bool[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes","name":"left","type":"bytes"},{"internalType":"bytes","name":"right","type":"bytes"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"address[]","name":"left","type":"address[]"},{"internalType":"address[]","name":"right","type":"address[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"uint256[]","name":"left","type":"uint256[]"},{"internalType":"uint256[]","name":"right","type":"uint256[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bool[]","name":"left","type":"bool[]"},{"internalType":"bool[]","name":"right","type":"bool[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"string","name":"left","type":"string"},{"internalType":"string","name":"right","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"address[]","name":"left","type":"address[]"},{"internalType":"address[]","name":"right","type":"address[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"string","name":"left","type":"string"},{"internalType":"string","name":"right","type":"string"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"address","name":"left","type":"address"},{"internalType":"address","name":"right","type":"address"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes32","name":"left","type":"bytes32"},{"internalType":"bytes32","name":"right","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes","name":"left","type":"bytes"},{"internalType":"bytes","name":"right","type":"bytes"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"uint256[]","name":"left","type":"uint256[]"},{"internalType":"uint256[]","name":"right","type":"uint256[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"address","name":"left","type":"address"},{"internalType":"address","name":"right","type":"address"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes32","name":"left","type":"bytes32"},{"internalType":"bytes32","name":"right","type":"bytes32"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"string[]","name":"left","type":"string[]"},{"internalType":"string[]","name":"right","type":"string[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes32[]","name":"left","type":"bytes32[]"},{"internalType":"bytes32[]","name":"right","type":"bytes32[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"string[]","name":"left","type":"string[]"},{"internalType":"string[]","name":"right","type":"string[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"int256[]","name":"left","type":"int256[]"},{"internalType":"int256[]","name":"right","type":"int256[]"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"bytes[]","name":"left","type":"bytes[]"},{"internalType":"bytes[]","name":"right","type":"bytes[]"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"}],"stateMutability":"pure","type":"function","name":"assertNotEq"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertNotEqDecimal"},{"inputs":[{"internalType":"int256","name":"left","type":"int256"},{"internalType":"int256","name":"right","type":"int256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEqDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"}],"stateMutability":"pure","type":"function","name":"assertNotEqDecimal"},{"inputs":[{"internalType":"uint256","name":"left","type":"uint256"},{"internalType":"uint256","name":"right","type":"uint256"},{"internalType":"uint256","name":"decimals","type":"uint256"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertNotEqDecimal"},{"inputs":[{"internalType":"bool","name":"condition","type":"bool"}],"stateMutability":"pure","type":"function","name":"assertTrue"},{"inputs":[{"internalType":"bool","name":"condition","type":"bool"},{"internalType":"string","name":"error","type":"string"}],"stateMutability":"pure","type":"function","name":"assertTrue"},{"inputs":[{"internalType":"bool","name":"condition","type":"bool"}],"stateMutability":"pure","type":"function","name":"assume"},{"inputs":[],"stateMutability":"pure","type":"function","name":"assumeNoRevert"},{"inputs":[{"internalType":"struct VmSafe.PotentialRevert[]","name":"potentialReverts","type":"tuple[]","components":[{"internalType":"address","name":"reverter","type":"address"},{"internalType":"bool","name":"partialMatch","type":"bool"},{"internalType":"bytes","name":"revertData","type":"bytes"}]}],"stateMutability":"pure","type":"function","name":"assumeNoRevert"},{"inputs":[{"internalType":"struct VmSafe.PotentialRevert","name":"potentialRevert","type":"tuple","components":[{"internalType":"address","name":"reverter","type":"address"},{"internalType":"bool","name":"partialMatch","type":"bool"},{"internalType":"bytes","name":"revertData","type":"bytes"}]}],"stateMutability":"pure","type":"function","name":"assumeNoRevert"},{"inputs":[{"internalType":"bytes","name":"blob","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"attachBlob"},{"inputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}],"stateMutability":"nonpayable","type":"function","name":"attachDelegation"},{"inputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]},{"internalType":"bool","name":"crossChain","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"attachDelegation"},{"inputs":[{"internalType":"uint256","name":"current","type":"uint256"},{"internalType":"uint256","name":"min","type":"uint256"},{"internalType":"uint256","name":"max","type":"uint256"}],"stateMutability":"view","type":"function","name":"bound","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"int256","name":"current","type":"int256"},{"internalType":"int256","name":"min","type":"int256"},{"internalType":"int256","name":"max","type":"int256"}],"stateMutability":"view","type":"function","name":"bound","outputs":[{"internalType":"int256","name":"","type":"int256"}]},{"inputs":[{"internalType":"string","name":"char","type":"string"}],"stateMutability":"pure","type":"function","name":"breakpoint"},{"inputs":[{"internalType":"string","name":"char","type":"string"},{"internalType":"bool","name":"value","type":"bool"}],"stateMutability":"pure","type":"function","name":"breakpoint"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"broadcast"},{"inputs":[{"internalType":"address","name":"signer","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"broadcast"},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"broadcast"},{"inputs":[{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"broadcastRawTransaction"},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"closeFile"},{"inputs":[{"internalType":"bytes32","name":"salt","type":"bytes32"},{"internalType":"bytes32","name":"initCodeHash","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"computeCreate2Address","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"bytes32","name":"salt","type":"bytes32"},{"internalType":"bytes32","name":"initCodeHash","type":"bytes32"},{"internalType":"address","name":"deployer","type":"address"}],"stateMutability":"pure","type":"function","name":"computeCreate2Address","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"address","name":"deployer","type":"address"},{"internalType":"uint256","name":"nonce","type":"uint256"}],"stateMutability":"pure","type":"function","name":"computeCreateAddress","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"subject","type":"string"},{"internalType":"string","name":"search","type":"string"}],"stateMutability":"pure","type":"function","name":"contains","outputs":[{"internalType":"bool","name":"result","type":"bool"}]},{"inputs":[{"internalType":"string","name":"from","type":"string"},{"internalType":"string","name":"to","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"copyFile","outputs":[{"internalType":"uint64","name":"copied","type":"uint64"}]},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"copyStorage"},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"bool","name":"recursive","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"createDir"},{"inputs":[{"internalType":"string","name":"walletLabel","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"createWallet","outputs":[{"internalType":"struct VmSafe.Wallet","name":"wallet","type":"tuple","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"},{"internalType":"uint256","name":"privateKey","type":"uint256"}]}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"createWallet","outputs":[{"internalType":"struct VmSafe.Wallet","name":"wallet","type":"tuple","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"},{"internalType":"uint256","name":"privateKey","type":"uint256"}]}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"string","name":"walletLabel","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"createWallet","outputs":[{"internalType":"struct VmSafe.Wallet","name":"wallet","type":"tuple","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"},{"internalType":"uint256","name":"privateKey","type":"uint256"}]}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes32","name":"salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"bytes","name":"constructorArgs","type":"bytes"},{"internalType":"bytes32","name":"salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"uint256","name":"value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"bytes32","name":"salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"bytes","name":"constructorArgs","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"bytes","name":"constructorArgs","type":"bytes"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes32","name":"salt","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"},{"internalType":"bytes","name":"constructorArgs","type":"bytes"},{"internalType":"uint256","name":"value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"deployCode","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"mnemonic","type":"string"},{"internalType":"string","name":"derivationPath","type":"string"},{"internalType":"uint32","name":"index","type":"uint32"},{"internalType":"string","name":"language","type":"string"}],"stateMutability":"pure","type":"function","name":"deriveKey","outputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"mnemonic","type":"string"},{"internalType":"uint32","name":"index","type":"uint32"},{"internalType":"string","name":"language","type":"string"}],"stateMutability":"pure","type":"function","name":"deriveKey","outputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"mnemonic","type":"string"},{"internalType":"uint32","name":"index","type":"uint32"}],"stateMutability":"pure","type":"function","name":"deriveKey","outputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"mnemonic","type":"string"},{"internalType":"string","name":"derivationPath","type":"string"},{"internalType":"uint32","name":"index","type":"uint32"}],"stateMutability":"pure","type":"function","name":"deriveKey","outputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"bindingsPath","type":"string"},{"internalType":"string","name":"typeName","type":"string"},{"internalType":"bytes","name":"abiEncodedData","type":"bytes"}],"stateMutability":"pure","type":"function","name":"eip712HashStruct","outputs":[{"internalType":"bytes32","name":"typeHash","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"typeNameOrDefinition","type":"string"},{"internalType":"bytes","name":"abiEncodedData","type":"bytes"}],"stateMutability":"pure","type":"function","name":"eip712HashStruct","outputs":[{"internalType":"bytes32","name":"typeHash","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"bindingsPath","type":"string"},{"internalType":"string","name":"typeName","type":"string"}],"stateMutability":"pure","type":"function","name":"eip712HashType","outputs":[{"internalType":"bytes32","name":"typeHash","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"typeNameOrDefinition","type":"string"}],"stateMutability":"pure","type":"function","name":"eip712HashType","outputs":[{"internalType":"bytes32","name":"typeHash","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"jsonData","type":"string"}],"stateMutability":"pure","type":"function","name":"eip712HashTypedData","outputs":[{"internalType":"bytes32","name":"digest","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"pure","type":"function","name":"ensNamehash","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envAddress","outputs":[{"internalType":"address","name":"value","type":"address"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envAddress","outputs":[{"internalType":"address[]","name":"value","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envBool","outputs":[{"internalType":"bool","name":"value","type":"bool"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envBool","outputs":[{"internalType":"bool[]","name":"value","type":"bool[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envBytes","outputs":[{"internalType":"bytes","name":"value","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envBytes","outputs":[{"internalType":"bytes[]","name":"value","type":"bytes[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envBytes32","outputs":[{"internalType":"bytes32[]","name":"value","type":"bytes32[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envBytes32","outputs":[{"internalType":"bytes32","name":"value","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envExists","outputs":[{"internalType":"bool","name":"result","type":"bool"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envInt","outputs":[{"internalType":"int256[]","name":"value","type":"int256[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envInt","outputs":[{"internalType":"int256","name":"value","type":"int256"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"bytes32[]","name":"defaultValue","type":"bytes32[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"bytes32[]","name":"value","type":"bytes32[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"int256[]","name":"defaultValue","type":"int256[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"int256[]","name":"value","type":"int256[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"bool","name":"defaultValue","type":"bool"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"bool","name":"value","type":"bool"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"address","name":"defaultValue","type":"address"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"address","name":"value","type":"address"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"uint256","name":"defaultValue","type":"uint256"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"uint256","name":"value","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"bytes[]","name":"defaultValue","type":"bytes[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"bytes[]","name":"value","type":"bytes[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"uint256[]","name":"defaultValue","type":"uint256[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"uint256[]","name":"value","type":"uint256[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"string[]","name":"defaultValue","type":"string[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"string[]","name":"value","type":"string[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"bytes","name":"defaultValue","type":"bytes"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"bytes","name":"value","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"bytes32","name":"defaultValue","type":"bytes32"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"bytes32","name":"value","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"int256","name":"defaultValue","type":"int256"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"int256","name":"value","type":"int256"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"address[]","name":"defaultValue","type":"address[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"address[]","name":"value","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"defaultValue","type":"string"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"string","name":"value","type":"string"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"},{"internalType":"bool[]","name":"defaultValue","type":"bool[]"}],"stateMutability":"view","type":"function","name":"envOr","outputs":[{"internalType":"bool[]","name":"value","type":"bool[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envString","outputs":[{"internalType":"string[]","name":"value","type":"string[]"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envString","outputs":[{"internalType":"string","name":"value","type":"string"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function","name":"envUint","outputs":[{"internalType":"uint256","name":"value","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"delim","type":"string"}],"stateMutability":"view","type":"function","name":"envUint","outputs":[{"internalType":"uint256[]","name":"value","type":"uint256[]"}]},{"inputs":[{"internalType":"uint256","name":"fromBlock","type":"uint256"},{"internalType":"uint256","name":"toBlock","type":"uint256"},{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32[]","name":"topics","type":"bytes32[]"}],"stateMutability":"view","type":"function","name":"eth_getLogs","outputs":[{"internalType":"struct VmSafe.EthGetLogs[]","name":"logs","type":"tuple[]","components":[{"internalType":"address","name":"emitter","type":"address"},{"internalType":"bytes32[]","name":"topics","type":"bytes32[]"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"bytes32","name":"blockHash","type":"bytes32"},{"internalType":"uint64","name":"blockNumber","type":"uint64"},{"internalType":"bytes32","name":"transactionHash","type":"bytes32"},{"internalType":"uint64","name":"transactionIndex","type":"uint64"},{"internalType":"uint256","name":"logIndex","type":"uint256"},{"internalType":"bool","name":"removed","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"exists","outputs":[{"internalType":"bool","name":"result","type":"bool"}]},{"inputs":[{"internalType":"string[]","name":"commandInput","type":"string[]"}],"stateMutability":"nonpayable","type":"function","name":"ffi","outputs":[{"internalType":"bytes","name":"result","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"version","type":"string"}],"stateMutability":"view","type":"function","name":"foundryVersionAtLeast","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"string","name":"version","type":"string"}],"stateMutability":"view","type":"function","name":"foundryVersionCmp","outputs":[{"internalType":"int256","name":"","type":"int256"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"fsMetadata","outputs":[{"internalType":"struct VmSafe.FsMetadata","name":"metadata","type":"tuple","components":[{"internalType":"bool","name":"isDir","type":"bool"},{"internalType":"bool","name":"isSymlink","type":"bool"},{"internalType":"uint256","name":"length","type":"uint256"},{"internalType":"bool","name":"readOnly","type":"bool"},{"internalType":"uint256","name":"modified","type":"uint256"},{"internalType":"uint256","name":"accessed","type":"uint256"},{"internalType":"uint256","name":"created","type":"uint256"}]}]},{"inputs":[{"internalType":"bytes","name":"code","type":"bytes"}],"stateMutability":"view","type":"function","name":"getArtifactPathByCode","outputs":[{"internalType":"string","name":"path","type":"string"}]},{"inputs":[{"internalType":"bytes","name":"deployedCode","type":"bytes"}],"stateMutability":"view","type":"function","name":"getArtifactPathByDeployedCode","outputs":[{"internalType":"string","name":"path","type":"string"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getBlobBaseFee","outputs":[{"internalType":"uint256","name":"blobBaseFee","type":"uint256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getBlockNumber","outputs":[{"internalType":"uint256","name":"height","type":"uint256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getBlockTimestamp","outputs":[{"internalType":"uint256","name":"timestamp","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"contractName","type":"string"},{"internalType":"uint64","name":"chainId","type":"uint64"},{"internalType":"enum VmSafe.BroadcastTxType","name":"txType","type":"uint8"}],"stateMutability":"view","type":"function","name":"getBroadcast","outputs":[{"internalType":"struct VmSafe.BroadcastTxSummary","name":"","type":"tuple","components":[{"internalType":"bytes32","name":"txHash","type":"bytes32"},{"internalType":"enum VmSafe.BroadcastTxType","name":"txType","type":"uint8"},{"internalType":"address","name":"contractAddress","type":"address"},{"internalType":"uint64","name":"blockNumber","type":"uint64"},{"internalType":"bool","name":"success","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"contractName","type":"string"},{"internalType":"uint64","name":"chainId","type":"uint64"}],"stateMutability":"view","type":"function","name":"getBroadcasts","outputs":[{"internalType":"struct VmSafe.BroadcastTxSummary[]","name":"","type":"tuple[]","components":[{"internalType":"bytes32","name":"txHash","type":"bytes32"},{"internalType":"enum VmSafe.BroadcastTxType","name":"txType","type":"uint8"},{"internalType":"address","name":"contractAddress","type":"address"},{"internalType":"uint64","name":"blockNumber","type":"uint64"},{"internalType":"bool","name":"success","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"contractName","type":"string"},{"internalType":"uint64","name":"chainId","type":"uint64"},{"internalType":"enum VmSafe.BroadcastTxType","name":"txType","type":"uint8"}],"stateMutability":"view","type":"function","name":"getBroadcasts","outputs":[{"internalType":"struct VmSafe.BroadcastTxSummary[]","name":"","type":"tuple[]","components":[{"internalType":"bytes32","name":"txHash","type":"bytes32"},{"internalType":"enum VmSafe.BroadcastTxType","name":"txType","type":"uint8"},{"internalType":"address","name":"contractAddress","type":"address"},{"internalType":"uint64","name":"blockNumber","type":"uint64"},{"internalType":"bool","name":"success","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"chainAlias","type":"string"}],"stateMutability":"view","type":"function","name":"getChain","outputs":[{"internalType":"struct VmSafe.Chain","name":"chain","type":"tuple","components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"uint256","name":"chainId","type":"uint256"},{"internalType":"string","name":"chainAlias","type":"string"},{"internalType":"string","name":"rpcUrl","type":"string"}]}]},{"inputs":[{"internalType":"uint256","name":"chainId","type":"uint256"}],"stateMutability":"view","type":"function","name":"getChain","outputs":[{"internalType":"struct VmSafe.Chain","name":"chain","type":"tuple","components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"uint256","name":"chainId","type":"uint256"},{"internalType":"string","name":"chainAlias","type":"string"},{"internalType":"string","name":"rpcUrl","type":"string"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getChainId","outputs":[{"internalType":"uint256","name":"blockChainId","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"}],"stateMutability":"view","type":"function","name":"getCode","outputs":[{"internalType":"bytes","name":"creationBytecode","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"artifactPath","type":"string"}],"stateMutability":"view","type":"function","name":"getDeployedCode","outputs":[{"internalType":"bytes","name":"runtimeBytecode","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"contractName","type":"string"},{"internalType":"uint64","name":"chainId","type":"uint64"}],"stateMutability":"view","type":"function","name":"getDeployment","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"contractName","type":"string"}],"stateMutability":"view","type":"function","name":"getDeployment","outputs":[{"internalType":"address","name":"deployedAddress","type":"address"}]},{"inputs":[{"internalType":"string","name":"contractName","type":"string"},{"internalType":"uint64","name":"chainId","type":"uint64"}],"stateMutability":"view","type":"function","name":"getDeployments","outputs":[{"internalType":"address[]","name":"deployedAddresses","type":"address[]"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getFoundryVersion","outputs":[{"internalType":"string","name":"version","type":"string"}]},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"stateMutability":"view","type":"function","name":"getLabel","outputs":[{"internalType":"string","name":"currentLabel","type":"string"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32","name":"elementSlot","type":"bytes32"}],"stateMutability":"view","type":"function","name":"getMappingKeyAndParentOf","outputs":[{"internalType":"bool","name":"found","type":"bool"},{"internalType":"bytes32","name":"key","type":"bytes32"},{"internalType":"bytes32","name":"parent","type":"bytes32"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32","name":"mappingSlot","type":"bytes32"}],"stateMutability":"view","type":"function","name":"getMappingLength","outputs":[{"internalType":"uint256","name":"length","type":"uint256"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32","name":"mappingSlot","type":"bytes32"},{"internalType":"uint256","name":"idx","type":"uint256"}],"stateMutability":"view","type":"function","name":"getMappingSlotAt","outputs":[{"internalType":"bytes32","name":"value","type":"bytes32"}]},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"stateMutability":"view","type":"function","name":"getNonce","outputs":[{"internalType":"uint64","name":"nonce","type":"uint64"}]},{"inputs":[{"internalType":"struct VmSafe.Wallet","name":"wallet","type":"tuple","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"},{"internalType":"uint256","name":"privateKey","type":"uint256"}]}],"stateMutability":"view","type":"function","name":"getNonce","outputs":[{"internalType":"uint64","name":"nonce","type":"uint64"}]},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"stateMutability":"view","type":"function","name":"getRawBlockHeader","outputs":[{"internalType":"bytes","name":"rlpHeader","type":"bytes"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getRecordedLogs","outputs":[{"internalType":"struct VmSafe.Log[]","name":"logs","type":"tuple[]","components":[{"internalType":"bytes32[]","name":"topics","type":"bytes32[]"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"address","name":"emitter","type":"address"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getStateDiff","outputs":[{"internalType":"string","name":"diff","type":"string"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getStateDiffJson","outputs":[{"internalType":"string","name":"diff","type":"string"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getStorageAccesses","outputs":[{"internalType":"struct VmSafe.StorageAccess[]","name":"storageAccesses","type":"tuple[]","components":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bytes32","name":"slot","type":"bytes32"},{"internalType":"bool","name":"isWrite","type":"bool"},{"internalType":"bytes32","name":"previousValue","type":"bytes32"},{"internalType":"bytes32","name":"newValue","type":"bytes32"},{"internalType":"bool","name":"reverted","type":"bool"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"getWallets","outputs":[{"internalType":"address[]","name":"wallets","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"input","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"indexOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"enum VmSafe.ForgeContext","name":"context","type":"uint8"}],"stateMutability":"view","type":"function","name":"isContext","outputs":[{"internalType":"bool","name":"result","type":"bool"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"isDir","outputs":[{"internalType":"bool","name":"result","type":"bool"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"isFile","outputs":[{"internalType":"bool","name":"result","type":"bool"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"view","type":"function","name":"keyExists","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"view","type":"function","name":"keyExistsJson","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"view","type":"function","name":"keyExistsToml","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"string","name":"newLabel","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"label"},{"inputs":[],"stateMutability":"view","type":"function","name":"lastCallGas","outputs":[{"internalType":"struct VmSafe.Gas","name":"gas","type":"tuple","components":[{"internalType":"uint64","name":"gasLimit","type":"uint64"},{"internalType":"uint64","name":"gasTotalUsed","type":"uint64"},{"internalType":"uint64","name":"gasMemoryUsed","type":"uint64"},{"internalType":"int64","name":"gasRefunded","type":"int64"},{"internalType":"uint64","name":"gasRemaining","type":"uint64"}]}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes32","name":"slot","type":"bytes32"}],"stateMutability":"view","type":"function","name":"load","outputs":[{"internalType":"bytes32","name":"data","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}],"stateMutability":"pure","type":"function","name":"parseAddress","outputs":[{"internalType":"address","name":"parsedValue","type":"address"}]},{"inputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}],"stateMutability":"pure","type":"function","name":"parseBool","outputs":[{"internalType":"bool","name":"parsedValue","type":"bool"}]},{"inputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}],"stateMutability":"pure","type":"function","name":"parseBytes","outputs":[{"internalType":"bytes","name":"parsedValue","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}],"stateMutability":"pure","type":"function","name":"parseBytes32","outputs":[{"internalType":"bytes32","name":"parsedValue","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}],"stateMutability":"pure","type":"function","name":"parseInt","outputs":[{"internalType":"int256","name":"parsedValue","type":"int256"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJson","outputs":[{"internalType":"bytes","name":"abiEncodedData","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJson","outputs":[{"internalType":"bytes","name":"abiEncodedData","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonAddress","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonAddressArray","outputs":[{"internalType":"address[]","name":"","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonBool","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonBoolArray","outputs":[{"internalType":"bool[]","name":"","type":"bool[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonBytes","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonBytes32","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonBytes32Array","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonBytesArray","outputs":[{"internalType":"bytes[]","name":"","type":"bytes[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonInt","outputs":[{"internalType":"int256","name":"","type":"int256"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonIntArray","outputs":[{"internalType":"int256[]","name":"","type":"int256[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonKeys","outputs":[{"internalType":"string[]","name":"keys","type":"string[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonString","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonStringArray","outputs":[{"internalType":"string[]","name":"","type":"string[]"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonType","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonType","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonTypeArray","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseJsonUintArray","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseToml","outputs":[{"internalType":"bytes","name":"abiEncodedData","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"}],"stateMutability":"pure","type":"function","name":"parseToml","outputs":[{"internalType":"bytes","name":"abiEncodedData","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlAddress","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlAddressArray","outputs":[{"internalType":"address[]","name":"","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlBool","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlBoolArray","outputs":[{"internalType":"bool[]","name":"","type":"bool[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlBytes","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlBytes32","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlBytes32Array","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlBytesArray","outputs":[{"internalType":"bytes[]","name":"","type":"bytes[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlInt","outputs":[{"internalType":"int256","name":"","type":"int256"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlIntArray","outputs":[{"internalType":"int256[]","name":"","type":"int256[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlKeys","outputs":[{"internalType":"string[]","name":"keys","type":"string[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlString","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlStringArray","outputs":[{"internalType":"string[]","name":"","type":"string[]"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlType","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlType","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlTypeArray","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"toml","type":"string"},{"internalType":"string","name":"key","type":"string"}],"stateMutability":"pure","type":"function","name":"parseTomlUintArray","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}]},{"inputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}],"stateMutability":"pure","type":"function","name":"parseUint","outputs":[{"internalType":"uint256","name":"parsedValue","type":"uint256"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"pauseGasMetering"},{"inputs":[],"stateMutability":"view","type":"function","name":"pauseTracing"},{"inputs":[],"stateMutability":"view","type":"function","name":"projectRoot","outputs":[{"internalType":"string","name":"path","type":"string"}]},{"inputs":[{"internalType":"string","name":"promptText","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"prompt","outputs":[{"internalType":"string","name":"input","type":"string"}]},{"inputs":[{"internalType":"string","name":"promptText","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"promptAddress","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[{"internalType":"string","name":"promptText","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"promptSecret","outputs":[{"internalType":"string","name":"input","type":"string"}]},{"inputs":[{"internalType":"string","name":"promptText","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"promptSecretUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"promptText","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"promptUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"pure","type":"function","name":"publicKeyP256","outputs":[{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"randomAddress","outputs":[{"internalType":"address","name":"","type":"address"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"randomBool","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"uint256","name":"len","type":"uint256"}],"stateMutability":"view","type":"function","name":"randomBytes","outputs":[{"internalType":"bytes","name":"","type":"bytes"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"randomBytes4","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"randomBytes8","outputs":[{"internalType":"bytes8","name":"","type":"bytes8"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"randomInt","outputs":[{"internalType":"int256","name":"","type":"int256"}]},{"inputs":[{"internalType":"uint256","name":"bits","type":"uint256"}],"stateMutability":"view","type":"function","name":"randomInt","outputs":[{"internalType":"int256","name":"","type":"int256"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"randomUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"uint256","name":"bits","type":"uint256"}],"stateMutability":"view","type":"function","name":"randomUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"uint256","name":"min","type":"uint256"},{"internalType":"uint256","name":"max","type":"uint256"}],"stateMutability":"view","type":"function","name":"randomUint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"uint64","name":"maxDepth","type":"uint64"}],"stateMutability":"view","type":"function","name":"readDir","outputs":[{"internalType":"struct VmSafe.DirEntry[]","name":"entries","type":"tuple[]","components":[{"internalType":"string","name":"errorMessage","type":"string"},{"internalType":"string","name":"path","type":"string"},{"internalType":"uint64","name":"depth","type":"uint64"},{"internalType":"bool","name":"isDir","type":"bool"},{"internalType":"bool","name":"isSymlink","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"uint64","name":"maxDepth","type":"uint64"},{"internalType":"bool","name":"followLinks","type":"bool"}],"stateMutability":"view","type":"function","name":"readDir","outputs":[{"internalType":"struct VmSafe.DirEntry[]","name":"entries","type":"tuple[]","components":[{"internalType":"string","name":"errorMessage","type":"string"},{"internalType":"string","name":"path","type":"string"},{"internalType":"uint64","name":"depth","type":"uint64"},{"internalType":"bool","name":"isDir","type":"bool"},{"internalType":"bool","name":"isSymlink","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"readDir","outputs":[{"internalType":"struct VmSafe.DirEntry[]","name":"entries","type":"tuple[]","components":[{"internalType":"string","name":"errorMessage","type":"string"},{"internalType":"string","name":"path","type":"string"},{"internalType":"uint64","name":"depth","type":"uint64"},{"internalType":"bool","name":"isDir","type":"bool"},{"internalType":"bool","name":"isSymlink","type":"bool"}]}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"readFile","outputs":[{"internalType":"string","name":"data","type":"string"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"readFileBinary","outputs":[{"internalType":"bytes","name":"data","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"view","type":"function","name":"readLine","outputs":[{"internalType":"string","name":"line","type":"string"}]},{"inputs":[{"internalType":"string","name":"linkPath","type":"string"}],"stateMutability":"view","type":"function","name":"readLink","outputs":[{"internalType":"string","name":"targetPath","type":"string"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"record"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"recordLogs"},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"rememberKey","outputs":[{"internalType":"address","name":"keyAddr","type":"address"}]},{"inputs":[{"internalType":"string","name":"mnemonic","type":"string"},{"internalType":"string","name":"derivationPath","type":"string"},{"internalType":"uint32","name":"count","type":"uint32"}],"stateMutability":"nonpayable","type":"function","name":"rememberKeys","outputs":[{"internalType":"address[]","name":"keyAddrs","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"mnemonic","type":"string"},{"internalType":"string","name":"derivationPath","type":"string"},{"internalType":"string","name":"language","type":"string"},{"internalType":"uint32","name":"count","type":"uint32"}],"stateMutability":"nonpayable","type":"function","name":"rememberKeys","outputs":[{"internalType":"address[]","name":"keyAddrs","type":"address[]"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"bool","name":"recursive","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"removeDir"},{"inputs":[{"internalType":"string","name":"path","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"removeFile"},{"inputs":[{"internalType":"string","name":"input","type":"string"},{"internalType":"string","name":"from","type":"string"},{"internalType":"string","name":"to","type":"string"}],"stateMutability":"pure","type":"function","name":"replace","outputs":[{"internalType":"string","name":"output","type":"string"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"resetGasMetering"},{"inputs":[{"internalType":"string","name":"input","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"resolveEnv","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"resumeGasMetering"},{"inputs":[],"stateMutability":"view","type":"function","name":"resumeTracing"},{"inputs":[{"internalType":"string","name":"urlOrAlias","type":"string"},{"internalType":"string","name":"method","type":"string"},{"internalType":"string","name":"params","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"rpc","outputs":[{"internalType":"bytes","name":"data","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"method","type":"string"},{"internalType":"string","name":"params","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"rpc","outputs":[{"internalType":"bytes","name":"data","type":"bytes"}]},{"inputs":[{"internalType":"string","name":"rpcAlias","type":"string"}],"stateMutability":"view","type":"function","name":"rpcUrl","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[],"stateMutability":"view","type":"function","name":"rpcUrlStructs","outputs":[{"internalType":"struct VmSafe.Rpc[]","name":"urls","type":"tuple[]","components":[{"internalType":"string","name":"key","type":"string"},{"internalType":"string","name":"url","type":"string"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"rpcUrls","outputs":[{"internalType":"string[2][]","name":"urls","type":"string[2][]"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"address[]","name":"values","type":"address[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeAddress","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"address","name":"value","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"serializeAddress","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"bool[]","name":"values","type":"bool[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeBool","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"bool","name":"value","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"serializeBool","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"bytes[]","name":"values","type":"bytes[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeBytes","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"bytes","name":"value","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"serializeBytes","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"bytes32[]","name":"values","type":"bytes32[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeBytes32","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"bytes32","name":"value","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"serializeBytes32","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"int256","name":"value","type":"int256"}],"stateMutability":"nonpayable","type":"function","name":"serializeInt","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"int256[]","name":"values","type":"int256[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeInt","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"value","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"serializeJson","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"typeDescription","type":"string"},{"internalType":"bytes","name":"value","type":"bytes"}],"stateMutability":"pure","type":"function","name":"serializeJsonType","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"string","name":"typeDescription","type":"string"},{"internalType":"bytes","name":"value","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"serializeJsonType","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"string[]","name":"values","type":"string[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeString","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"string","name":"value","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"serializeString","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"uint256","name":"value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"serializeUint","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"uint256[]","name":"values","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function","name":"serializeUint","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"string","name":"objectKey","type":"string"},{"internalType":"string","name":"valueKey","type":"string"},{"internalType":"uint256","name":"value","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"serializeUintToHex","outputs":[{"internalType":"string","name":"json","type":"string"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bool","name":"overwrite","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"setArbitraryStorage"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"setArbitraryStorage"},{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"value","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"setEnv"},{"inputs":[{"internalType":"uint256","name":"seed","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"setSeed"},{"inputs":[{"internalType":"uint256[]","name":"array","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function","name":"shuffle","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}]},{"inputs":[{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"sign","outputs":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}]},{"inputs":[{"internalType":"address","name":"signer","type":"address"},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"sign","outputs":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}]},{"inputs":[{"internalType":"struct VmSafe.Wallet","name":"wallet","type":"tuple","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"},{"internalType":"uint256","name":"privateKey","type":"uint256"}]},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"sign","outputs":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"sign","outputs":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}]},{"inputs":[{"internalType":"address","name":"implementation","type":"address"},{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"signAndAttachDelegation","outputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}]},{"inputs":[{"internalType":"address","name":"implementation","type":"address"},{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"uint64","name":"nonce","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"signAndAttachDelegation","outputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}]},{"inputs":[{"internalType":"address","name":"implementation","type":"address"},{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"bool","name":"crossChain","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"signAndAttachDelegation","outputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}]},{"inputs":[{"internalType":"struct VmSafe.Wallet","name":"wallet","type":"tuple","components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"publicKeyX","type":"uint256"},{"internalType":"uint256","name":"publicKeyY","type":"uint256"},{"internalType":"uint256","name":"privateKey","type":"uint256"}]},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"nonpayable","type":"function","name":"signCompact","outputs":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"vs","type":"bytes32"}]},{"inputs":[{"internalType":"address","name":"signer","type":"address"},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"signCompact","outputs":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"vs","type":"bytes32"}]},{"inputs":[{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"signCompact","outputs":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"vs","type":"bytes32"}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"signCompact","outputs":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"vs","type":"bytes32"}]},{"inputs":[{"internalType":"address","name":"implementation","type":"address"},{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"signDelegation","outputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}]},{"inputs":[{"internalType":"address","name":"implementation","type":"address"},{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"bool","name":"crossChain","type":"bool"}],"stateMutability":"nonpayable","type":"function","name":"signDelegation","outputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}]},{"inputs":[{"internalType":"address","name":"implementation","type":"address"},{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"uint64","name":"nonce","type":"uint64"}],"stateMutability":"nonpayable","type":"function","name":"signDelegation","outputs":[{"internalType":"struct VmSafe.SignedDelegation","name":"signedDelegation","type":"tuple","components":[{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint64","name":"nonce","type":"uint64"},{"internalType":"address","name":"implementation","type":"address"}]}]},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"},{"internalType":"bytes32","name":"digest","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"signP256","outputs":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}]},{"inputs":[{"internalType":"uint256","name":"duration","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"sleep"},{"inputs":[{"internalType":"uint256[]","name":"array","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function","name":"sort","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}]},{"inputs":[{"internalType":"string","name":"input","type":"string"},{"internalType":"string","name":"delimiter","type":"string"}],"stateMutability":"pure","type":"function","name":"split","outputs":[{"internalType":"string[]","name":"outputs","type":"string[]"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"startBroadcast"},{"inputs":[{"internalType":"address","name":"signer","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"startBroadcast"},{"inputs":[{"internalType":"uint256","name":"privateKey","type":"uint256"}],"stateMutability":"nonpayable","type":"function","name":"startBroadcast"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"startDebugTraceRecording"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"startMappingRecording"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"startStateDiffRecording"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopAndReturnDebugTraceRecording","outputs":[{"internalType":"struct VmSafe.DebugStep[]","name":"step","type":"tuple[]","components":[{"internalType":"uint256[]","name":"stack","type":"uint256[]"},{"internalType":"bytes","name":"memoryInput","type":"bytes"},{"internalType":"uint8","name":"opcode","type":"uint8"},{"internalType":"uint64","name":"depth","type":"uint64"},{"internalType":"bool","name":"isOutOfGas","type":"bool"},{"internalType":"address","name":"contractAddr","type":"address"}]}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopAndReturnStateDiff","outputs":[{"internalType":"struct VmSafe.AccountAccess[]","name":"accountAccesses","type":"tuple[]","components":[{"internalType":"struct VmSafe.ChainInfo","name":"chainInfo","type":"tuple","components":[{"internalType":"uint256","name":"forkId","type":"uint256"},{"internalType":"uint256","name":"chainId","type":"uint256"}]},{"internalType":"enum VmSafe.AccountAccessKind","name":"kind","type":"uint8"},{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"accessor","type":"address"},{"internalType":"bool","name":"initialized","type":"bool"},{"internalType":"uint256","name":"oldBalance","type":"uint256"},{"internalType":"uint256","name":"newBalance","type":"uint256"},{"internalType":"bytes","name":"deployedCode","type":"bytes"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"bool","name":"reverted","type":"bool"},{"internalType":"struct VmSafe.StorageAccess[]","name":"storageAccesses","type":"tuple[]","components":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bytes32","name":"slot","type":"bytes32"},{"internalType":"bool","name":"isWrite","type":"bool"},{"internalType":"bytes32","name":"previousValue","type":"bytes32"},{"internalType":"bytes32","name":"newValue","type":"bytes32"},{"internalType":"bool","name":"reverted","type":"bool"}]},{"internalType":"uint64","name":"depth","type":"uint64"},{"internalType":"uint64","name":"oldNonce","type":"uint64"},{"internalType":"uint64","name":"newNonce","type":"uint64"}]}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopBroadcast"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopMappingRecording"},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"stopRecord"},{"inputs":[{"internalType":"string","name":"data","type":"string"}],"stateMutability":"pure","type":"function","name":"toBase64","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"pure","type":"function","name":"toBase64","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[{"internalType":"string","name":"data","type":"string"}],"stateMutability":"pure","type":"function","name":"toBase64URL","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"pure","type":"function","name":"toBase64URL","outputs":[{"internalType":"string","name":"","type":"string"}]},{"inputs":[{"internalType":"string","name":"input","type":"string"}],"stateMutability":"pure","type":"function","name":"toLowercase","outputs":[{"internalType":"string","name":"output","type":"string"}]},{"inputs":[{"internalType":"address","name":"value","type":"address"}],"stateMutability":"pure","type":"function","name":"toString","outputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}]},{"inputs":[{"internalType":"uint256","name":"value","type":"uint256"}],"stateMutability":"pure","type":"function","name":"toString","outputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}]},{"inputs":[{"internalType":"bytes","name":"value","type":"bytes"}],"stateMutability":"pure","type":"function","name":"toString","outputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}]},{"inputs":[{"internalType":"bool","name":"value","type":"bool"}],"stateMutability":"pure","type":"function","name":"toString","outputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}]},{"inputs":[{"internalType":"int256","name":"value","type":"int256"}],"stateMutability":"pure","type":"function","name":"toString","outputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}]},{"inputs":[{"internalType":"bytes32","name":"value","type":"bytes32"}],"stateMutability":"pure","type":"function","name":"toString","outputs":[{"internalType":"string","name":"stringifiedValue","type":"string"}]},{"inputs":[{"internalType":"string","name":"input","type":"string"}],"stateMutability":"pure","type":"function","name":"toUppercase","outputs":[{"internalType":"string","name":"output","type":"string"}]},{"inputs":[{"internalType":"string","name":"input","type":"string"}],"stateMutability":"pure","type":"function","name":"trim","outputs":[{"internalType":"string","name":"output","type":"string"}]},{"inputs":[{"internalType":"string[]","name":"commandInput","type":"string[]"}],"stateMutability":"nonpayable","type":"function","name":"tryFfi","outputs":[{"internalType":"struct VmSafe.FfiResult","name":"result","type":"tuple","components":[{"internalType":"int32","name":"exitCode","type":"int32"},{"internalType":"bytes","name":"stdout","type":"bytes"},{"internalType":"bytes","name":"stderr","type":"bytes"}]}]},{"inputs":[],"stateMutability":"view","type":"function","name":"unixTime","outputs":[{"internalType":"uint256","name":"milliseconds","type":"uint256"}]},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"string","name":"data","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"writeFile"},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"bytes","name":"data","type":"bytes"}],"stateMutability":"nonpayable","type":"function","name":"writeFileBinary"},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"path","type":"string"},{"internalType":"string","name":"valueKey","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"writeJson"},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"path","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"writeJson"},{"inputs":[{"internalType":"string","name":"path","type":"string"},{"internalType":"string","name":"data","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"writeLine"},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"path","type":"string"},{"internalType":"string","name":"valueKey","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"writeToml"},{"inputs":[{"internalType":"string","name":"json","type":"string"},{"internalType":"string","name":"path","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"writeToml"}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{"accesses(address)":{"notice":"Gets all accessed reads and write slot from a `vm.record` session, for a given address."},"addr(uint256)":{"notice":"Gets the address for a given private key."},"assertApproxEqAbs(int256,int256,uint256)":{"notice":"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`."},"assertApproxEqAbs(int256,int256,uint256,string)":{"notice":"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. Includes error message into revert string on failure."},"assertApproxEqAbs(uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`."},"assertApproxEqAbs(uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. Includes error message into revert string on failure."},"assertApproxEqAbsDecimal(int256,int256,uint256,uint256)":{"notice":"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message."},"assertApproxEqAbsDecimal(int256,int256,uint256,uint256,string)":{"notice":"Compares two `int256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertApproxEqAbsDecimal(uint256,uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message."},"assertApproxEqAbsDecimal(uint256,uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects difference to be less than or equal to `maxDelta`. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertApproxEqRel(int256,int256,uint256)":{"notice":"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100%"},"assertApproxEqRel(int256,int256,uint256,string)":{"notice":"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Includes error message into revert string on failure."},"assertApproxEqRel(uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100%"},"assertApproxEqRel(uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Includes error message into revert string on failure."},"assertApproxEqRelDecimal(int256,int256,uint256,uint256)":{"notice":"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message."},"assertApproxEqRelDecimal(int256,int256,uint256,uint256,string)":{"notice":"Compares two `int256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertApproxEqRelDecimal(uint256,uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message."},"assertApproxEqRelDecimal(uint256,uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects relative difference in percents to be less than or equal to `maxPercentDelta`. `maxPercentDelta` is an 18 decimal fixed point number, where 1e18 == 100% Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertEq(address,address)":{"notice":"Asserts that two `address` values are equal."},"assertEq(address,address,string)":{"notice":"Asserts that two `address` values are equal and includes error message into revert string on failure."},"assertEq(address[],address[])":{"notice":"Asserts that two arrays of `address` values are equal."},"assertEq(address[],address[],string)":{"notice":"Asserts that two arrays of `address` values are equal and includes error message into revert string on failure."},"assertEq(bool,bool)":{"notice":"Asserts that two `bool` values are equal."},"assertEq(bool,bool,string)":{"notice":"Asserts that two `bool` values are equal and includes error message into revert string on failure."},"assertEq(bool[],bool[])":{"notice":"Asserts that two arrays of `bool` values are equal."},"assertEq(bool[],bool[],string)":{"notice":"Asserts that two arrays of `bool` values are equal and includes error message into revert string on failure."},"assertEq(bytes,bytes)":{"notice":"Asserts that two `bytes` values are equal."},"assertEq(bytes,bytes,string)":{"notice":"Asserts that two `bytes` values are equal and includes error message into revert string on failure."},"assertEq(bytes32,bytes32)":{"notice":"Asserts that two `bytes32` values are equal."},"assertEq(bytes32,bytes32,string)":{"notice":"Asserts that two `bytes32` values are equal and includes error message into revert string on failure."},"assertEq(bytes32[],bytes32[])":{"notice":"Asserts that two arrays of `bytes32` values are equal."},"assertEq(bytes32[],bytes32[],string)":{"notice":"Asserts that two arrays of `bytes32` values are equal and includes error message into revert string on failure."},"assertEq(bytes[],bytes[])":{"notice":"Asserts that two arrays of `bytes` values are equal."},"assertEq(bytes[],bytes[],string)":{"notice":"Asserts that two arrays of `bytes` values are equal and includes error message into revert string on failure."},"assertEq(int256,int256)":{"notice":"Asserts that two `int256` values are equal."},"assertEq(int256,int256,string)":{"notice":"Asserts that two `int256` values are equal and includes error message into revert string on failure."},"assertEq(int256[],int256[])":{"notice":"Asserts that two arrays of `int256` values are equal."},"assertEq(int256[],int256[],string)":{"notice":"Asserts that two arrays of `int256` values are equal and includes error message into revert string on failure."},"assertEq(string,string)":{"notice":"Asserts that two `string` values are equal."},"assertEq(string,string,string)":{"notice":"Asserts that two `string` values are equal and includes error message into revert string on failure."},"assertEq(string[],string[])":{"notice":"Asserts that two arrays of `string` values are equal."},"assertEq(string[],string[],string)":{"notice":"Asserts that two arrays of `string` values are equal and includes error message into revert string on failure."},"assertEq(uint256,uint256)":{"notice":"Asserts that two `uint256` values are equal."},"assertEq(uint256,uint256,string)":{"notice":"Asserts that two `uint256` values are equal and includes error message into revert string on failure."},"assertEq(uint256[],uint256[])":{"notice":"Asserts that two arrays of `uint256 values are equal."},"assertEq(uint256[],uint256[],string)":{"notice":"Asserts that two arrays of `uint256` values are equal and includes error message into revert string on failure."},"assertEqDecimal(int256,int256,uint256)":{"notice":"Asserts that two `int256` values are equal, formatting them with decimals in failure message."},"assertEqDecimal(int256,int256,uint256,string)":{"notice":"Asserts that two `int256` values are equal, formatting them with decimals in failure message. Includes error message into revert string on failure."},"assertEqDecimal(uint256,uint256,uint256)":{"notice":"Asserts that two `uint256` values are equal, formatting them with decimals in failure message."},"assertEqDecimal(uint256,uint256,uint256,string)":{"notice":"Asserts that two `uint256` values are equal, formatting them with decimals in failure message. Includes error message into revert string on failure."},"assertFalse(bool)":{"notice":"Asserts that the given condition is false."},"assertFalse(bool,string)":{"notice":"Asserts that the given condition is false and includes error message into revert string on failure."},"assertGe(int256,int256)":{"notice":"Compares two `int256` values. Expects first value to be greater than or equal to second."},"assertGe(int256,int256,string)":{"notice":"Compares two `int256` values. Expects first value to be greater than or equal to second. Includes error message into revert string on failure."},"assertGe(uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be greater than or equal to second."},"assertGe(uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be greater than or equal to second. Includes error message into revert string on failure."},"assertGeDecimal(int256,int256,uint256)":{"notice":"Compares two `int256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message."},"assertGeDecimal(int256,int256,uint256,string)":{"notice":"Compares two `int256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertGeDecimal(uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message."},"assertGeDecimal(uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be greater than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertGt(int256,int256)":{"notice":"Compares two `int256` values. Expects first value to be greater than second."},"assertGt(int256,int256,string)":{"notice":"Compares two `int256` values. Expects first value to be greater than second. Includes error message into revert string on failure."},"assertGt(uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be greater than second."},"assertGt(uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be greater than second. Includes error message into revert string on failure."},"assertGtDecimal(int256,int256,uint256)":{"notice":"Compares two `int256` values. Expects first value to be greater than second. Formats values with decimals in failure message."},"assertGtDecimal(int256,int256,uint256,string)":{"notice":"Compares two `int256` values. Expects first value to be greater than second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertGtDecimal(uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be greater than second. Formats values with decimals in failure message."},"assertGtDecimal(uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be greater than second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertLe(int256,int256)":{"notice":"Compares two `int256` values. Expects first value to be less than or equal to second."},"assertLe(int256,int256,string)":{"notice":"Compares two `int256` values. Expects first value to be less than or equal to second. Includes error message into revert string on failure."},"assertLe(uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be less than or equal to second."},"assertLe(uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be less than or equal to second. Includes error message into revert string on failure."},"assertLeDecimal(int256,int256,uint256)":{"notice":"Compares two `int256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message."},"assertLeDecimal(int256,int256,uint256,string)":{"notice":"Compares two `int256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertLeDecimal(uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message."},"assertLeDecimal(uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be less than or equal to second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertLt(int256,int256)":{"notice":"Compares two `int256` values. Expects first value to be less than second."},"assertLt(int256,int256,string)":{"notice":"Compares two `int256` values. Expects first value to be less than second. Includes error message into revert string on failure."},"assertLt(uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be less than second."},"assertLt(uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be less than second. Includes error message into revert string on failure."},"assertLtDecimal(int256,int256,uint256)":{"notice":"Compares two `int256` values. Expects first value to be less than second. Formats values with decimals in failure message."},"assertLtDecimal(int256,int256,uint256,string)":{"notice":"Compares two `int256` values. Expects first value to be less than second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertLtDecimal(uint256,uint256,uint256)":{"notice":"Compares two `uint256` values. Expects first value to be less than second. Formats values with decimals in failure message."},"assertLtDecimal(uint256,uint256,uint256,string)":{"notice":"Compares two `uint256` values. Expects first value to be less than second. Formats values with decimals in failure message. Includes error message into revert string on failure."},"assertNotEq(address,address)":{"notice":"Asserts that two `address` values are not equal."},"assertNotEq(address,address,string)":{"notice":"Asserts that two `address` values are not equal and includes error message into revert string on failure."},"assertNotEq(address[],address[])":{"notice":"Asserts that two arrays of `address` values are not equal."},"assertNotEq(address[],address[],string)":{"notice":"Asserts that two arrays of `address` values are not equal and includes error message into revert string on failure."},"assertNotEq(bool,bool)":{"notice":"Asserts that two `bool` values are not equal."},"assertNotEq(bool,bool,string)":{"notice":"Asserts that two `bool` values are not equal and includes error message into revert string on failure."},"assertNotEq(bool[],bool[])":{"notice":"Asserts that two arrays of `bool` values are not equal."},"assertNotEq(bool[],bool[],string)":{"notice":"Asserts that two arrays of `bool` values are not equal and includes error message into revert string on failure."},"assertNotEq(bytes,bytes)":{"notice":"Asserts that two `bytes` values are not equal."},"assertNotEq(bytes,bytes,string)":{"notice":"Asserts that two `bytes` values are not equal and includes error message into revert string on failure."},"assertNotEq(bytes32,bytes32)":{"notice":"Asserts that two `bytes32` values are not equal."},"assertNotEq(bytes32,bytes32,string)":{"notice":"Asserts that two `bytes32` values are not equal and includes error message into revert string on failure."},"assertNotEq(bytes32[],bytes32[])":{"notice":"Asserts that two arrays of `bytes32` values are not equal."},"assertNotEq(bytes32[],bytes32[],string)":{"notice":"Asserts that two arrays of `bytes32` values are not equal and includes error message into revert string on failure."},"assertNotEq(bytes[],bytes[])":{"notice":"Asserts that two arrays of `bytes` values are not equal."},"assertNotEq(bytes[],bytes[],string)":{"notice":"Asserts that two arrays of `bytes` values are not equal and includes error message into revert string on failure."},"assertNotEq(int256,int256)":{"notice":"Asserts that two `int256` values are not equal."},"assertNotEq(int256,int256,string)":{"notice":"Asserts that two `int256` values are not equal and includes error message into revert string on failure."},"assertNotEq(int256[],int256[])":{"notice":"Asserts that two arrays of `int256` values are not equal."},"assertNotEq(int256[],int256[],string)":{"notice":"Asserts that two arrays of `int256` values are not equal and includes error message into revert string on failure."},"assertNotEq(string,string)":{"notice":"Asserts that two `string` values are not equal."},"assertNotEq(string,string,string)":{"notice":"Asserts that two `string` values are not equal and includes error message into revert string on failure."},"assertNotEq(string[],string[])":{"notice":"Asserts that two arrays of `string` values are not equal."},"assertNotEq(string[],string[],string)":{"notice":"Asserts that two arrays of `string` values are not equal and includes error message into revert string on failure."},"assertNotEq(uint256,uint256)":{"notice":"Asserts that two `uint256` values are not equal."},"assertNotEq(uint256,uint256,string)":{"notice":"Asserts that two `uint256` values are not equal and includes error message into revert string on failure."},"assertNotEq(uint256[],uint256[])":{"notice":"Asserts that two arrays of `uint256` values are not equal."},"assertNotEq(uint256[],uint256[],string)":{"notice":"Asserts that two arrays of `uint256` values are not equal and includes error message into revert string on failure."},"assertNotEqDecimal(int256,int256,uint256)":{"notice":"Asserts that two `int256` values are not equal, formatting them with decimals in failure message."},"assertNotEqDecimal(int256,int256,uint256,string)":{"notice":"Asserts that two `int256` values are not equal, formatting them with decimals in failure message. Includes error message into revert string on failure."},"assertNotEqDecimal(uint256,uint256,uint256)":{"notice":"Asserts that two `uint256` values are not equal, formatting them with decimals in failure message."},"assertNotEqDecimal(uint256,uint256,uint256,string)":{"notice":"Asserts that two `uint256` values are not equal, formatting them with decimals in failure message. Includes error message into revert string on failure."},"assertTrue(bool)":{"notice":"Asserts that the given condition is true."},"assertTrue(bool,string)":{"notice":"Asserts that the given condition is true and includes error message into revert string on failure."},"assume(bool)":{"notice":"If the condition is false, discard this run's fuzz inputs and generate new ones."},"assumeNoRevert((address,bool,bytes))":{"notice":"Discard this run's fuzz inputs and generate new ones if next call reverts with the potential revert parameters."},"assumeNoRevert((address,bool,bytes)[])":{"notice":"Discard this run's fuzz inputs and generate new ones if next call reverts with the any of the potential revert parameters."},"assumeNoRevert()":{"notice":"Discard this run's fuzz inputs and generate new ones if next call reverted."},"attachBlob(bytes)":{"notice":"Attach an EIP-4844 blob to the next call"},"attachDelegation((uint8,bytes32,bytes32,uint64,address))":{"notice":"Designate the next call as an EIP-7702 transaction"},"attachDelegation((uint8,bytes32,bytes32,uint64,address),bool)":{"notice":"Designate the next call as an EIP-7702 transaction, with optional cross-chain validity."},"bound(int256,int256,int256)":{"notice":"Returns an int256 value bounded in given range and different from the current one."},"bound(uint256,uint256,uint256)":{"notice":"Returns an uint256 value bounded in given range and different from the current one."},"breakpoint(string)":{"notice":"Writes a breakpoint to jump to in the debugger."},"breakpoint(string,bool)":{"notice":"Writes a conditional breakpoint to jump to in the debugger."},"broadcast()":{"notice":"Has the next call (at this call depth only) create transactions that can later be signed and sent onchain. Broadcasting address is determined by checking the following in order: 1. If `--sender` argument was provided, that address is used. 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used."},"broadcast(address)":{"notice":"Has the next call (at this call depth only) create a transaction with the address provided as the sender that can later be signed and sent onchain."},"broadcast(uint256)":{"notice":"Has the next call (at this call depth only) create a transaction with the private key provided as the sender that can later be signed and sent onchain."},"broadcastRawTransaction(bytes)":{"notice":"Takes a signed transaction and broadcasts it to the network."},"closeFile(string)":{"notice":"Closes file for reading, resetting the offset and allowing to read it from beginning with readLine. `path` is relative to the project root."},"computeCreate2Address(bytes32,bytes32)":{"notice":"Compute the address of a contract created with CREATE2 using the default CREATE2 deployer."},"computeCreate2Address(bytes32,bytes32,address)":{"notice":"Compute the address of a contract created with CREATE2 using the given CREATE2 deployer."},"computeCreateAddress(address,uint256)":{"notice":"Compute the address a contract will be deployed at for a given deployer address and nonce."},"contains(string,string)":{"notice":"Returns true if `search` is found in `subject`, false otherwise."},"copyFile(string,string)":{"notice":"Copies the contents of one file to another. This function will **overwrite** the contents of `to`. On success, the total number of bytes copied is returned and it is equal to the length of the `to` file as reported by `metadata`. Both `from` and `to` are relative to the project root."},"copyStorage(address,address)":{"notice":"Utility cheatcode to copy storage of `from` contract to another `to` contract."},"createDir(string,bool)":{"notice":"Creates a new, empty directory at the provided path. This cheatcode will revert in the following situations, but is not limited to just these cases: - User lacks permissions to modify `path`. - A parent of the given path doesn't exist and `recursive` is false. - `path` already exists and `recursive` is false. `path` is relative to the project root."},"createWallet(string)":{"notice":"Derives a private key from the name, labels the account with that name, and returns the wallet."},"createWallet(uint256)":{"notice":"Generates a wallet from the private key and returns the wallet."},"createWallet(uint256,string)":{"notice":"Generates a wallet from the private key, labels the account with that name, and returns the wallet."},"deployCode(string)":{"notice":"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional."},"deployCode(string,bytes)":{"notice":"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments."},"deployCode(string,bytes,bytes32)":{"notice":"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments."},"deployCode(string,bytes,uint256)":{"notice":"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments and `msg.value`."},"deployCode(string,bytes,uint256,bytes32)":{"notice":"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts abi-encoded constructor arguments and `msg.value`."},"deployCode(string,bytes32)":{"notice":"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional."},"deployCode(string,uint256)":{"notice":"Deploys a contract from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts `msg.value`."},"deployCode(string,uint256,bytes32)":{"notice":"Deploys a contract from an artifact file, using the CREATE2 salt. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional. Additionally accepts `msg.value`."},"deriveKey(string,string,uint32)":{"notice":"Derive a private key from a provided mnemonic string (or mnemonic file path) at `{derivationPath}{index}`."},"deriveKey(string,string,uint32,string)":{"notice":"Derive a private key from a provided mnemonic string (or mnemonic file path) in the specified language at `{derivationPath}{index}`."},"deriveKey(string,uint32)":{"notice":"Derive a private key from a provided mnemonic string (or mnemonic file path) at the derivation path `m/44'/60'/0'/0/{index}`."},"deriveKey(string,uint32,string)":{"notice":"Derive a private key from a provided mnemonic string (or mnemonic file path) in the specified language at the derivation path `m/44'/60'/0'/0/{index}`."},"eip712HashStruct(string,bytes)":{"notice":"Generates the struct hash of the canonical EIP-712 type representation and its abi-encoded data. Supports 2 different inputs: 1. Name of the type (i.e. \"PermitSingle\"): * requires previous binding generation with `forge bind-json`. * bindings will be retrieved from the path configured in `foundry.toml`. 2. String representation of the type (i.e. \"Foo(Bar bar) Bar(uint256 baz)\"). * Note: the cheatcode will use the canonical type even if the input is malformated with the wrong order of elements or with extra whitespaces."},"eip712HashStruct(string,string,bytes)":{"notice":"Generates the struct hash of the canonical EIP-712 type representation and its abi-encoded data. Requires previous binding generation with `forge bind-json`. Params: * `bindingsPath`: path where the output of `forge bind-json` is stored. * `typeName`: Name of the type (i.e. \"PermitSingle\"). * `abiEncodedData`: ABI-encoded data for the struct that is being hashed."},"eip712HashType(string)":{"notice":"Generates the hash of the canonical EIP-712 type representation. Supports 2 different inputs: 1. Name of the type (i.e. \"Transaction\"): * requires previous binding generation with `forge bind-json`. * bindings will be retrieved from the path configured in `foundry.toml`. 2. String representation of the type (i.e. \"Foo(Bar bar) Bar(uint256 baz)\"). * Note: the cheatcode will output the canonical type even if the input is malformated with the wrong order of elements or with extra whitespaces."},"eip712HashType(string,string)":{"notice":"Generates the hash of the canonical EIP-712 type representation. Requires previous binding generation with `forge bind-json`. Params: * `bindingsPath`: path where the output of `forge bind-json` is stored. * `typeName`: Name of the type (i.e. \"Transaction\")."},"eip712HashTypedData(string)":{"notice":"Generates a ready-to-sign digest of human-readable typed data following the EIP-712 standard."},"ensNamehash(string)":{"notice":"Returns ENS namehash for provided string."},"envAddress(string)":{"notice":"Gets the environment variable `name` and parses it as `address`. Reverts if the variable was not found or could not be parsed."},"envAddress(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"envBool(string)":{"notice":"Gets the environment variable `name` and parses it as `bool`. Reverts if the variable was not found or could not be parsed."},"envBool(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"envBytes(string)":{"notice":"Gets the environment variable `name` and parses it as `bytes`. Reverts if the variable was not found or could not be parsed."},"envBytes(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"envBytes32(string)":{"notice":"Gets the environment variable `name` and parses it as `bytes32`. Reverts if the variable was not found or could not be parsed."},"envBytes32(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"envExists(string)":{"notice":"Gets the environment variable `name` and returns true if it exists, else returns false."},"envInt(string)":{"notice":"Gets the environment variable `name` and parses it as `int256`. Reverts if the variable was not found or could not be parsed."},"envInt(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"envOr(string,address)":{"notice":"Gets the environment variable `name` and parses it as `address`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,bool)":{"notice":"Gets the environment variable `name` and parses it as `bool`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,bytes)":{"notice":"Gets the environment variable `name` and parses it as `bytes`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,bytes32)":{"notice":"Gets the environment variable `name` and parses it as `bytes32`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,int256)":{"notice":"Gets the environment variable `name` and parses it as `int256`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string)":{"notice":"Gets the environment variable `name` and parses it as `string`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,address[])":{"notice":"Gets the environment variable `name` and parses it as an array of `address`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,bool[])":{"notice":"Gets the environment variable `name` and parses it as an array of `bool`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,bytes32[])":{"notice":"Gets the environment variable `name` and parses it as an array of `bytes32`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,bytes[])":{"notice":"Gets the environment variable `name` and parses it as an array of `bytes`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,int256[])":{"notice":"Gets the environment variable `name` and parses it as an array of `int256`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,string[])":{"notice":"Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,string,uint256[])":{"notice":"Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envOr(string,uint256)":{"notice":"Gets the environment variable `name` and parses it as `uint256`. Reverts if the variable could not be parsed. Returns `defaultValue` if the variable was not found."},"envString(string)":{"notice":"Gets the environment variable `name` and parses it as `string`. Reverts if the variable was not found or could not be parsed."},"envString(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `string`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"envUint(string)":{"notice":"Gets the environment variable `name` and parses it as `uint256`. Reverts if the variable was not found or could not be parsed."},"envUint(string,string)":{"notice":"Gets the environment variable `name` and parses it as an array of `uint256`, delimited by `delim`. Reverts if the variable was not found or could not be parsed."},"eth_getLogs(uint256,uint256,address,bytes32[])":{"notice":"Gets all the logs according to specified filter."},"exists(string)":{"notice":"Returns true if the given path points to an existing entity, else returns false."},"ffi(string[])":{"notice":"Performs a foreign function call via the terminal."},"foundryVersionAtLeast(string)":{"notice":"Returns true if the current Foundry version is greater than or equal to the given version. The given version string must be in the format `major.minor.patch`. This is equivalent to `foundryVersionCmp(version) >= 0`."},"foundryVersionCmp(string)":{"notice":"Compares the current Foundry version with the given version string. The given version string must be in the format `major.minor.patch`. Returns: -1 if current Foundry version is less than the given version 0 if current Foundry version equals the given version 1 if current Foundry version is greater than the given version This result can then be used with a comparison operator against `0`. For example, to check if the current Foundry version is greater than or equal to `1.0.0`: `if (foundryVersionCmp(\"1.0.0\") >= 0) { ... }`"},"fsMetadata(string)":{"notice":"Given a path, query the file system to get information about a file, directory, etc."},"getArtifactPathByCode(bytes)":{"notice":"Gets the artifact path from code (aka. creation code)."},"getArtifactPathByDeployedCode(bytes)":{"notice":"Gets the artifact path from deployed code (aka. runtime code)."},"getBlobBaseFee()":{"notice":"Gets the current `block.blobbasefee`. You should use this instead of `block.blobbasefee` if you use `vm.blobBaseFee`, as `block.blobbasefee` is assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180"},"getBlockNumber()":{"notice":"Gets the current `block.number`. You should use this instead of `block.number` if you use `vm.roll`, as `block.number` is assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180"},"getBlockTimestamp()":{"notice":"Gets the current `block.timestamp`. You should use this instead of `block.timestamp` if you use `vm.warp`, as `block.timestamp` is assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180"},"getBroadcast(string,uint64,uint8)":{"notice":"Returns the most recent broadcast for the given contract on `chainId` matching `txType`. For example: The most recent deployment can be fetched by passing `txType` as `CREATE` or `CREATE2`. The most recent call can be fetched by passing `txType` as `CALL`."},"getBroadcasts(string,uint64)":{"notice":"Returns all broadcasts for the given contract on `chainId`. Sorted such that the most recent broadcast is the first element, and the oldest is the last. i.e descending order of BroadcastTxSummary.blockNumber."},"getBroadcasts(string,uint64,uint8)":{"notice":"Returns all broadcasts for the given contract on `chainId` with the specified `txType`. Sorted such that the most recent broadcast is the first element, and the oldest is the last. i.e descending order of BroadcastTxSummary.blockNumber."},"getChain(string)":{"notice":"Returns a Chain struct for specific alias"},"getChain(uint256)":{"notice":"Returns a Chain struct for specific chainId"},"getChainId()":{"notice":"Gets the current `block.chainid` of the currently selected environment. You should use this instead of `block.chainid` if you use `vm.selectFork` or `vm.createSelectFork`, as `block.chainid` could be assumed to be constant across a transaction, and as a result will get optimized out by the compiler. See https://github.com/foundry-rs/foundry/issues/6180"},"getCode(string)":{"notice":"Gets the creation bytecode from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional."},"getDeployedCode(string)":{"notice":"Gets the deployed bytecode from an artifact file. Takes in the relative path to the json file or the path to the artifact in the form of :: where and parts are optional."},"getDeployment(string)":{"notice":"Returns the most recent deployment for the current `chainId`."},"getDeployment(string,uint64)":{"notice":"Returns the most recent deployment for the given contract on `chainId`"},"getDeployments(string,uint64)":{"notice":"Returns all deployments for the given contract on `chainId` Sorted in descending order of deployment time i.e descending order of BroadcastTxSummary.blockNumber. The most recent deployment is the first element, and the oldest is the last."},"getFoundryVersion()":{"notice":"Returns the Foundry version. Format: -+.. Sample output: 0.3.0-nightly+3cb96bde9b.1737036656.debug Note: Build timestamps may vary slightly across platforms due to separate CI jobs. For reliable version comparisons, use UNIX format (e.g., >= 1700000000) to compare timestamps while ignoring minor time differences."},"getLabel(address)":{"notice":"Gets the label for the specified address."},"getMappingKeyAndParentOf(address,bytes32)":{"notice":"Gets the map key and parent of a mapping at a given slot, for a given address."},"getMappingLength(address,bytes32)":{"notice":"Gets the number of elements in the mapping at the given slot, for a given address."},"getMappingSlotAt(address,bytes32,uint256)":{"notice":"Gets the elements at index idx of the mapping at the given slot, for a given address. The index must be less than the length of the mapping (i.e. the number of keys in the mapping)."},"getNonce((address,uint256,uint256,uint256))":{"notice":"Get the nonce of a `Wallet`."},"getNonce(address)":{"notice":"Gets the nonce of an account."},"getRawBlockHeader(uint256)":{"notice":"Gets the RLP encoded block header for a given block number. Returns the block header in the same format as `cast block --raw`."},"getRecordedLogs()":{"notice":"Gets all the recorded logs."},"getStateDiff()":{"notice":"Returns state diffs from current `vm.startStateDiffRecording` session."},"getStateDiffJson()":{"notice":"Returns state diffs from current `vm.startStateDiffRecording` session, in json format."},"getStorageAccesses()":{"notice":"Returns an array of `StorageAccess` from current `vm.stateStateDiffRecording` session"},"getWallets()":{"notice":"Returns addresses of available unlocked wallets in the script environment."},"indexOf(string,string)":{"notice":"Returns the index of the first occurrence of a `key` in an `input` string. Returns `NOT_FOUND` (i.e. `type(uint256).max`) if the `key` is not found. Returns 0 in case of an empty `key`."},"isContext(uint8)":{"notice":"Returns true if `forge` command was executed in given context."},"isDir(string)":{"notice":"Returns true if the path exists on disk and is pointing at a directory, else returns false."},"isFile(string)":{"notice":"Returns true if the path exists on disk and is pointing at a regular file, else returns false."},"keyExists(string,string)":{"notice":"Checks if `key` exists in a JSON object `keyExists` is being deprecated in favor of `keyExistsJson`. It will be removed in future versions."},"keyExistsJson(string,string)":{"notice":"Checks if `key` exists in a JSON object."},"keyExistsToml(string,string)":{"notice":"Checks if `key` exists in a TOML table."},"label(address,string)":{"notice":"Labels an address in call traces."},"lastCallGas()":{"notice":"Gets the gas used in the last call from the callee perspective."},"load(address,bytes32)":{"notice":"Loads a storage slot from an address."},"parseAddress(string)":{"notice":"Parses the given `string` into an `address`."},"parseBool(string)":{"notice":"Parses the given `string` into a `bool`."},"parseBytes(string)":{"notice":"Parses the given `string` into `bytes`."},"parseBytes32(string)":{"notice":"Parses the given `string` into a `bytes32`."},"parseInt(string)":{"notice":"Parses the given `string` into a `int256`."},"parseJson(string)":{"notice":"ABI-encodes a JSON object."},"parseJson(string,string)":{"notice":"ABI-encodes a JSON object at `key`."},"parseJsonAddress(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `address`."},"parseJsonAddressArray(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `address[]`."},"parseJsonBool(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `bool`."},"parseJsonBoolArray(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `bool[]`."},"parseJsonBytes(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `bytes`."},"parseJsonBytes32(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `bytes32`."},"parseJsonBytes32Array(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `bytes32[]`."},"parseJsonBytesArray(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `bytes[]`."},"parseJsonInt(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `int256`."},"parseJsonIntArray(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `int256[]`."},"parseJsonKeys(string,string)":{"notice":"Returns an array of all the keys in a JSON object."},"parseJsonString(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `string`."},"parseJsonStringArray(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `string[]`."},"parseJsonType(string,string)":{"notice":"Parses a string of JSON data and coerces it to type corresponding to `typeDescription`."},"parseJsonType(string,string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to type corresponding to `typeDescription`."},"parseJsonTypeArray(string,string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to type array corresponding to `typeDescription`."},"parseJsonUint(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `uint256`."},"parseJsonUintArray(string,string)":{"notice":"Parses a string of JSON data at `key` and coerces it to `uint256[]`."},"parseToml(string)":{"notice":"ABI-encodes a TOML table."},"parseToml(string,string)":{"notice":"ABI-encodes a TOML table at `key`."},"parseTomlAddress(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `address`."},"parseTomlAddressArray(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `address[]`."},"parseTomlBool(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `bool`."},"parseTomlBoolArray(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `bool[]`."},"parseTomlBytes(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `bytes`."},"parseTomlBytes32(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `bytes32`."},"parseTomlBytes32Array(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `bytes32[]`."},"parseTomlBytesArray(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `bytes[]`."},"parseTomlInt(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `int256`."},"parseTomlIntArray(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `int256[]`."},"parseTomlKeys(string,string)":{"notice":"Returns an array of all the keys in a TOML table."},"parseTomlString(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `string`."},"parseTomlStringArray(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `string[]`."},"parseTomlType(string,string)":{"notice":"Parses a string of TOML data and coerces it to type corresponding to `typeDescription`."},"parseTomlType(string,string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to type corresponding to `typeDescription`."},"parseTomlTypeArray(string,string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to type array corresponding to `typeDescription`."},"parseTomlUint(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `uint256`."},"parseTomlUintArray(string,string)":{"notice":"Parses a string of TOML data at `key` and coerces it to `uint256[]`."},"parseUint(string)":{"notice":"Parses the given `string` into a `uint256`."},"pauseGasMetering()":{"notice":"Pauses gas metering (i.e. gas usage is not counted). Noop if already paused."},"pauseTracing()":{"notice":"Pauses collection of call traces. Useful in cases when you want to skip tracing of complex calls which are not useful for debugging."},"projectRoot()":{"notice":"Get the path of the current project root."},"prompt(string)":{"notice":"Prompts the user for a string value in the terminal."},"promptAddress(string)":{"notice":"Prompts the user for an address in the terminal."},"promptSecret(string)":{"notice":"Prompts the user for a hidden string value in the terminal."},"promptSecretUint(string)":{"notice":"Prompts the user for hidden uint256 in the terminal (usually pk)."},"promptUint(string)":{"notice":"Prompts the user for uint256 in the terminal."},"publicKeyP256(uint256)":{"notice":"Derives secp256r1 public key from the provided `privateKey`."},"randomAddress()":{"notice":"Returns a random `address`."},"randomBool()":{"notice":"Returns a random `bool`."},"randomBytes(uint256)":{"notice":"Returns a random byte array value of the given length."},"randomBytes4()":{"notice":"Returns a random fixed-size byte array of length 4."},"randomBytes8()":{"notice":"Returns a random fixed-size byte array of length 8."},"randomInt()":{"notice":"Returns a random `int256` value."},"randomInt(uint256)":{"notice":"Returns a random `int256` value of given bits."},"randomUint()":{"notice":"Returns a random uint256 value."},"randomUint(uint256)":{"notice":"Returns a random `uint256` value of given bits."},"randomUint(uint256,uint256)":{"notice":"Returns random uint256 value between the provided range (=min..=max)."},"readDir(string)":{"notice":"Reads the directory at the given path recursively, up to `maxDepth`. `maxDepth` defaults to 1, meaning only the direct children of the given directory will be returned. Follows symbolic links if `followLinks` is true."},"readDir(string,uint64)":{"notice":"See `readDir(string)`."},"readDir(string,uint64,bool)":{"notice":"See `readDir(string)`."},"readFile(string)":{"notice":"Reads the entire content of file to string. `path` is relative to the project root."},"readFileBinary(string)":{"notice":"Reads the entire content of file as binary. `path` is relative to the project root."},"readLine(string)":{"notice":"Reads next line of file to string."},"readLink(string)":{"notice":"Reads a symbolic link, returning the path that the link points to. This cheatcode will revert in the following situations, but is not limited to just these cases: - `path` is not a symbolic link. - `path` does not exist."},"record()":{"notice":"Records all storage reads and writes. Use `accesses` to get the recorded data. Subsequent calls to `record` will clear the previous data."},"recordLogs()":{"notice":"Record all the transaction logs."},"rememberKey(uint256)":{"notice":"Adds a private key to the local forge wallet and returns the address."},"rememberKeys(string,string,string,uint32)":{"notice":"Derive a set number of wallets from a mnemonic in the specified language at the derivation path `m/44'/60'/0'/0/{0..count}`. The respective private keys are saved to the local forge wallet for later use and their addresses are returned."},"rememberKeys(string,string,uint32)":{"notice":"Derive a set number of wallets from a mnemonic at the derivation path `m/44'/60'/0'/0/{0..count}`. The respective private keys are saved to the local forge wallet for later use and their addresses are returned."},"removeDir(string,bool)":{"notice":"Removes a directory at the provided path. This cheatcode will revert in the following situations, but is not limited to just these cases: - `path` doesn't exist. - `path` isn't a directory. - User lacks permissions to modify `path`. - The directory is not empty and `recursive` is false. `path` is relative to the project root."},"removeFile(string)":{"notice":"Removes a file from the filesystem. This cheatcode will revert in the following situations, but is not limited to just these cases: - `path` points to a directory. - The file doesn't exist. - The user lacks permissions to remove the file. `path` is relative to the project root."},"replace(string,string,string)":{"notice":"Replaces occurrences of `from` in the given `string` with `to`."},"resetGasMetering()":{"notice":"Reset gas metering (i.e. gas usage is set to gas limit)."},"resolveEnv(string)":{"notice":"Resolves the env variable placeholders of a given input string."},"resumeGasMetering()":{"notice":"Resumes gas metering (i.e. gas usage is counted again). Noop if already on."},"resumeTracing()":{"notice":"Unpauses collection of call traces."},"rpc(string,string)":{"notice":"Performs an Ethereum JSON-RPC request to the current fork URL."},"rpc(string,string,string)":{"notice":"Performs an Ethereum JSON-RPC request to the given endpoint."},"rpcUrl(string)":{"notice":"Returns the RPC url for the given alias."},"rpcUrlStructs()":{"notice":"Returns all rpc urls and their aliases as structs."},"rpcUrls()":{"notice":"Returns all rpc urls and their aliases `[alias, url][]`."},"serializeAddress(string,string,address)":{"notice":"See `serializeJson`."},"serializeAddress(string,string,address[])":{"notice":"See `serializeJson`."},"serializeBool(string,string,bool)":{"notice":"See `serializeJson`."},"serializeBool(string,string,bool[])":{"notice":"See `serializeJson`."},"serializeBytes(string,string,bytes)":{"notice":"See `serializeJson`."},"serializeBytes(string,string,bytes[])":{"notice":"See `serializeJson`."},"serializeBytes32(string,string,bytes32)":{"notice":"See `serializeJson`."},"serializeBytes32(string,string,bytes32[])":{"notice":"See `serializeJson`."},"serializeInt(string,string,int256)":{"notice":"See `serializeJson`."},"serializeInt(string,string,int256[])":{"notice":"See `serializeJson`."},"serializeJson(string,string)":{"notice":"Serializes a key and value to a JSON object stored in-memory that can be later written to a file. Returns the stringified version of the specific JSON file up to that moment."},"serializeJsonType(string,bytes)":{"notice":"See `serializeJson`."},"serializeJsonType(string,string,string,bytes)":{"notice":"See `serializeJson`."},"serializeString(string,string,string)":{"notice":"See `serializeJson`."},"serializeString(string,string,string[])":{"notice":"See `serializeJson`."},"serializeUint(string,string,uint256)":{"notice":"See `serializeJson`."},"serializeUint(string,string,uint256[])":{"notice":"See `serializeJson`."},"serializeUintToHex(string,string,uint256)":{"notice":"See `serializeJson`."},"setArbitraryStorage(address)":{"notice":"Utility cheatcode to set arbitrary storage for given target address."},"setArbitraryStorage(address,bool)":{"notice":"Utility cheatcode to set arbitrary storage for given target address and overwrite any storage slots that have been previously set."},"setEnv(string,string)":{"notice":"Sets environment variables."},"setSeed(uint256)":{"notice":"Set RNG seed."},"shuffle(uint256[])":{"notice":"Randomly shuffles an array."},"sign((address,uint256,uint256,uint256),bytes32)":{"notice":"Signs data with a `Wallet`."},"sign(address,bytes32)":{"notice":"Signs `digest` with signer provided to script using the secp256k1 curve. Raises error if none of the signers passed into the script have provided address."},"sign(bytes32)":{"notice":"Signs `digest` with signer provided to script using the secp256k1 curve. If `--sender` is provided, the signer with provided address is used, otherwise, if exactly one signer is provided to the script, that signer is used. Raises error if signer passed through `--sender` does not match any unlocked signers or if `--sender` is not provided and not exactly one signer is passed to the script."},"sign(uint256,bytes32)":{"notice":"Signs `digest` with `privateKey` using the secp256k1 curve."},"signAndAttachDelegation(address,uint256)":{"notice":"Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction"},"signAndAttachDelegation(address,uint256,bool)":{"notice":"Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction, with optional cross-chain validity."},"signAndAttachDelegation(address,uint256,uint64)":{"notice":"Sign an EIP-7702 authorization and designate the next call as an EIP-7702 transaction for specific nonce"},"signCompact((address,uint256,uint256,uint256),bytes32)":{"notice":"Signs data with a `Wallet`. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes."},"signCompact(address,bytes32)":{"notice":"Signs `digest` with signer provided to script using the secp256k1 curve. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes. Raises error if none of the signers passed into the script have provided address."},"signCompact(bytes32)":{"notice":"Signs `digest` with signer provided to script using the secp256k1 curve. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes. If `--sender` is provided, the signer with provided address is used, otherwise, if exactly one signer is provided to the script, that signer is used. Raises error if signer passed through `--sender` does not match any unlocked signers or if `--sender` is not provided and not exactly one signer is passed to the script."},"signCompact(uint256,bytes32)":{"notice":"Signs `digest` with `privateKey` using the secp256k1 curve. Returns a compact signature (`r`, `vs`) as per EIP-2098, where `vs` encodes both the signature's `s` value, and the recovery id `v` in a single bytes32. This format reduces the signature size from 65 to 64 bytes."},"signDelegation(address,uint256)":{"notice":"Sign an EIP-7702 authorization for delegation"},"signDelegation(address,uint256,bool)":{"notice":"Sign an EIP-7702 authorization for delegation, with optional cross-chain validity."},"signDelegation(address,uint256,uint64)":{"notice":"Sign an EIP-7702 authorization for delegation for specific nonce"},"signP256(uint256,bytes32)":{"notice":"Signs `digest` with `privateKey` using the secp256r1 curve."},"sleep(uint256)":{"notice":"Suspends execution of the main thread for `duration` milliseconds."},"sort(uint256[])":{"notice":"Sorts an array in ascending order."},"split(string,string)":{"notice":"Splits the given `string` into an array of strings divided by the `delimiter`."},"startBroadcast()":{"notice":"Has all subsequent calls (at this call depth only) create transactions that can later be signed and sent onchain. Broadcasting address is determined by checking the following in order: 1. If `--sender` argument was provided, that address is used. 2. If exactly one signer (e.g. private key, hw wallet, keystore) is set when `forge broadcast` is invoked, that signer is used. 3. Otherwise, default foundry sender (1804c8AB1F12E6bbf3894d4083f33e07309d1f38) is used."},"startBroadcast(address)":{"notice":"Has all subsequent calls (at this call depth only) create transactions with the address provided that can later be signed and sent onchain."},"startBroadcast(uint256)":{"notice":"Has all subsequent calls (at this call depth only) create transactions with the private key provided that can later be signed and sent onchain."},"startDebugTraceRecording()":{"notice":"Records the debug trace during the run."},"startMappingRecording()":{"notice":"Starts recording all map SSTOREs for later retrieval."},"startStateDiffRecording()":{"notice":"Record all account accesses as part of CREATE, CALL or SELFDESTRUCT opcodes in order, along with the context of the calls"},"stopAndReturnDebugTraceRecording()":{"notice":"Stop debug trace recording and returns the recorded debug trace."},"stopAndReturnStateDiff()":{"notice":"Returns an ordered array of all account accesses from a `vm.startStateDiffRecording` session."},"stopBroadcast()":{"notice":"Stops collecting onchain transactions."},"stopMappingRecording()":{"notice":"Stops recording all map SSTOREs for later retrieval and clears the recorded data."},"stopRecord()":{"notice":"Stops recording storage reads and writes."},"toBase64(bytes)":{"notice":"Encodes a `bytes` value to a base64 string."},"toBase64(string)":{"notice":"Encodes a `string` value to a base64 string."},"toBase64URL(bytes)":{"notice":"Encodes a `bytes` value to a base64url string."},"toBase64URL(string)":{"notice":"Encodes a `string` value to a base64url string."},"toLowercase(string)":{"notice":"Converts the given `string` value to Lowercase."},"toString(address)":{"notice":"Converts the given value to a `string`."},"toString(bool)":{"notice":"Converts the given value to a `string`."},"toString(bytes)":{"notice":"Converts the given value to a `string`."},"toString(bytes32)":{"notice":"Converts the given value to a `string`."},"toString(int256)":{"notice":"Converts the given value to a `string`."},"toString(uint256)":{"notice":"Converts the given value to a `string`."},"toUppercase(string)":{"notice":"Converts the given `string` value to Uppercase."},"trim(string)":{"notice":"Trims leading and trailing whitespace from the given `string` value."},"tryFfi(string[])":{"notice":"Performs a foreign function call via terminal and returns the exit code, stdout, and stderr."},"unixTime()":{"notice":"Returns the time since unix epoch in milliseconds."},"writeFile(string,string)":{"notice":"Writes data to file, creating a file if it does not exist, and entirely replacing its contents if it does. `path` is relative to the project root."},"writeFileBinary(string,bytes)":{"notice":"Writes binary data to a file, creating a file if it does not exist, and entirely replacing its contents if it does. `path` is relative to the project root."},"writeJson(string,string)":{"notice":"Write a serialized JSON object to a file. If the file exists, it will be overwritten."},"writeJson(string,string,string)":{"notice":"Write a serialized JSON object to an **existing** JSON file, replacing a value with key = This is useful to replace a specific value of a JSON file, without having to parse the entire thing. This cheatcode will create new keys if they didn't previously exist."},"writeLine(string,string)":{"notice":"Writes line to file, creating a file if it does not exist. `path` is relative to the project root."},"writeToml(string,string)":{"notice":"Takes serialized JSON, converts to TOML and write a serialized TOML to a file."},"writeToml(string,string,string)":{"notice":"Takes serialized JSON, converts to TOML and write a serialized TOML table to an **existing** TOML file, replacing a value with key = This is useful to replace a specific value of a TOML file, without having to parse the entire thing. This cheatcode will create new keys if they didn't previously exist."}},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/Vm.sol":"VmSafe"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"}},"version":1},"id":14} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/build-info/1217378287525ed5.json b/lib/signals-implicit-mode/out/build-info/1217378287525ed5.json deleted file mode 100644 index 605e8b87c6..0000000000 --- a/lib/signals-implicit-mode/out/build-info/1217378287525ed5.json +++ /dev/null @@ -1 +0,0 @@ -{"id":"1217378287525ed5","source_id_to_path":{"0":"lib/forge-std/src/Base.sol","1":"lib/forge-std/src/Script.sol","2":"lib/forge-std/src/StdChains.sol","3":"lib/forge-std/src/StdCheats.sol","4":"lib/forge-std/src/StdConstants.sol","5":"lib/forge-std/src/StdJson.sol","6":"lib/forge-std/src/StdMath.sol","7":"lib/forge-std/src/StdStorage.sol","8":"lib/forge-std/src/StdStyle.sol","9":"lib/forge-std/src/StdUtils.sol","10":"lib/forge-std/src/Vm.sol","11":"lib/forge-std/src/console.sol","12":"lib/forge-std/src/console2.sol","13":"lib/forge-std/src/interfaces/IMulticall3.sol","14":"lib/forge-std/src/safeconsole.sol","15":"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol","16":"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol","17":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol","18":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol","19":"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","20":"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","21":"lib/sequence-v3/src/modules/Payload.sol","22":"lib/sequence-v3/src/utils/LibBytes.sol","23":"script/Deploy.s.sol","24":"src/helper/SignalsImplicitMode.sol","25":"src/registry/IImplicitProjectRegistry.sol","26":"src/registry/IImplicitProjectValidation.sol","27":"src/registry/ImplicitProjectRegistry.sol"},"language":"Solidity"} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/build-info/1d3198d5efa69640.json b/lib/signals-implicit-mode/out/build-info/1d3198d5efa69640.json deleted file mode 100644 index a99db02d70..0000000000 --- a/lib/signals-implicit-mode/out/build-info/1d3198d5efa69640.json +++ /dev/null @@ -1 +0,0 @@ -{"id":"1d3198d5efa69640","source_id_to_path":{"0":"lib/forge-std/src/Base.sol","1":"lib/forge-std/src/StdAssertions.sol","2":"lib/forge-std/src/StdChains.sol","3":"lib/forge-std/src/StdCheats.sol","4":"lib/forge-std/src/StdConstants.sol","5":"lib/forge-std/src/StdError.sol","6":"lib/forge-std/src/StdInvariant.sol","7":"lib/forge-std/src/StdJson.sol","8":"lib/forge-std/src/StdMath.sol","9":"lib/forge-std/src/StdStorage.sol","10":"lib/forge-std/src/StdStyle.sol","11":"lib/forge-std/src/StdToml.sol","12":"lib/forge-std/src/StdUtils.sol","13":"lib/forge-std/src/Test.sol","14":"lib/forge-std/src/Vm.sol","15":"lib/forge-std/src/console.sol","16":"lib/forge-std/src/console2.sol","17":"lib/forge-std/src/interfaces/IMulticall3.sol","18":"lib/forge-std/src/safeconsole.sol","19":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol","20":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol","21":"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","22":"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","23":"lib/sequence-v3/src/modules/Payload.sol","24":"lib/sequence-v3/src/utils/LibBytes.sol","25":"src/helper/SignalsImplicitMode.sol","26":"src/registry/IImplicitProjectRegistry.sol","27":"src/registry/IImplicitProjectValidation.sol","28":"src/registry/ImplicitProjectRegistry.sol","29":"test/ImplicitProjectRegistry.t.sol","30":"test/SignalsImplicitMode.t.sol","31":"test/TestHelper.sol","32":"test/mock/SignalsImplicitModeMock.sol"},"language":"Solidity"} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/build-info/6df801dae8a4cdc2.json b/lib/signals-implicit-mode/out/build-info/6df801dae8a4cdc2.json deleted file mode 100644 index 3a6f15e76d..0000000000 --- a/lib/signals-implicit-mode/out/build-info/6df801dae8a4cdc2.json +++ /dev/null @@ -1 +0,0 @@ -{"id":"6df801dae8a4cdc2","source_id_to_path":{"0":"lib/forge-std/src/Base.sol","1":"lib/forge-std/src/StdAssertions.sol","2":"lib/forge-std/src/StdChains.sol","3":"lib/forge-std/src/StdCheats.sol","4":"lib/forge-std/src/StdConstants.sol","5":"lib/forge-std/src/StdError.sol","6":"lib/forge-std/src/StdInvariant.sol","7":"lib/forge-std/src/StdJson.sol","8":"lib/forge-std/src/StdMath.sol","9":"lib/forge-std/src/StdStorage.sol","10":"lib/forge-std/src/StdStyle.sol","11":"lib/forge-std/src/StdToml.sol","12":"lib/forge-std/src/StdUtils.sol","13":"lib/forge-std/src/Test.sol","14":"lib/forge-std/src/Vm.sol","15":"lib/forge-std/src/console.sol","16":"lib/forge-std/src/console2.sol","17":"lib/forge-std/src/interfaces/IMulticall3.sol","18":"lib/forge-std/src/safeconsole.sol","19":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol","20":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol","21":"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","22":"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","23":"lib/sequence-v3/src/modules/Payload.sol","24":"lib/sequence-v3/src/utils/LibBytes.sol","25":"src/helper/SignalsImplicitMode.sol","26":"src/registry/IImplicitProjectRegistry.sol","27":"src/registry/IImplicitProjectValidation.sol","28":"src/registry/ImplicitProjectRegistry.sol","29":"test/ImplicitProjectRegistry.t.sol","30":"test/SignalsImplicitMode.t.sol","31":"test/TestHelper.sol","32":"test/mock/SignalsImplicitModeMock.sol"},"language":"Solidity"} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/build-info/a20ef29be3850d65.json b/lib/signals-implicit-mode/out/build-info/a20ef29be3850d65.json deleted file mode 100644 index 6050741dbf..0000000000 --- a/lib/signals-implicit-mode/out/build-info/a20ef29be3850d65.json +++ /dev/null @@ -1 +0,0 @@ -{"id":"a20ef29be3850d65","source_id_to_path":{"0":"lib/forge-std/src/Base.sol","1":"lib/forge-std/src/Script.sol","2":"lib/forge-std/src/StdChains.sol","3":"lib/forge-std/src/StdCheats.sol","4":"lib/forge-std/src/StdConstants.sol","5":"lib/forge-std/src/StdJson.sol","6":"lib/forge-std/src/StdMath.sol","7":"lib/forge-std/src/StdStorage.sol","8":"lib/forge-std/src/StdStyle.sol","9":"lib/forge-std/src/StdUtils.sol","10":"lib/forge-std/src/Vm.sol","11":"lib/forge-std/src/console.sol","12":"lib/forge-std/src/console2.sol","13":"lib/forge-std/src/interfaces/IMulticall3.sol","14":"lib/forge-std/src/safeconsole.sol","15":"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol","16":"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol","17":"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","18":"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","19":"lib/sequence-v3/src/modules/Payload.sol","20":"lib/sequence-v3/src/utils/LibBytes.sol","21":"script/Deploy.s.sol","22":"src/registry/IImplicitProjectRegistry.sol","23":"src/registry/IImplicitProjectValidation.sol","24":"src/registry/ImplicitProjectRegistry.sol"},"language":"Solidity"} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/build-info/bfaf8263b04c7625.json b/lib/signals-implicit-mode/out/build-info/bfaf8263b04c7625.json deleted file mode 100644 index 4e1c7c3ab8..0000000000 --- a/lib/signals-implicit-mode/out/build-info/bfaf8263b04c7625.json +++ /dev/null @@ -1 +0,0 @@ -{"id":"bfaf8263b04c7625","source_id_to_path":{"0":"lib/forge-std/src/Base.sol","1":"lib/forge-std/src/Script.sol","2":"lib/forge-std/src/StdAssertions.sol","3":"lib/forge-std/src/StdChains.sol","4":"lib/forge-std/src/StdCheats.sol","5":"lib/forge-std/src/StdConstants.sol","6":"lib/forge-std/src/StdError.sol","7":"lib/forge-std/src/StdInvariant.sol","8":"lib/forge-std/src/StdJson.sol","9":"lib/forge-std/src/StdMath.sol","10":"lib/forge-std/src/StdStorage.sol","11":"lib/forge-std/src/StdStyle.sol","12":"lib/forge-std/src/StdToml.sol","13":"lib/forge-std/src/StdUtils.sol","14":"lib/forge-std/src/Test.sol","15":"lib/forge-std/src/Vm.sol","16":"lib/forge-std/src/console.sol","17":"lib/forge-std/src/console2.sol","18":"lib/forge-std/src/interfaces/IMulticall3.sol","19":"lib/forge-std/src/safeconsole.sol","20":"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol","21":"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol","22":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol","23":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol","24":"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","25":"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","26":"lib/sequence-v3/src/modules/Payload.sol","27":"lib/sequence-v3/src/utils/LibBytes.sol","28":"script/Deploy.s.sol","29":"src/helper/SignalsImplicitMode.sol","30":"src/registry/IImplicitProjectRegistry.sol","31":"src/registry/IImplicitProjectValidation.sol","32":"src/registry/ImplicitProjectRegistry.sol","33":"test/ImplicitProjectRegistry.t.sol","34":"test/SignalsImplicitMode.t.sol","35":"test/TestHelper.sol","36":"test/mock/SignalsImplicitModeMock.sol"},"language":"Solidity"} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/build-info/eaf92b5097a38a44.json b/lib/signals-implicit-mode/out/build-info/eaf92b5097a38a44.json deleted file mode 100644 index f2d83e1a48..0000000000 --- a/lib/signals-implicit-mode/out/build-info/eaf92b5097a38a44.json +++ /dev/null @@ -1 +0,0 @@ -{"id":"eaf92b5097a38a44","source_id_to_path":{"0":"lib/forge-std/src/Base.sol","1":"lib/forge-std/src/StdAssertions.sol","2":"lib/forge-std/src/StdChains.sol","3":"lib/forge-std/src/StdCheats.sol","4":"lib/forge-std/src/StdConstants.sol","5":"lib/forge-std/src/StdError.sol","6":"lib/forge-std/src/StdInvariant.sol","7":"lib/forge-std/src/StdJson.sol","8":"lib/forge-std/src/StdMath.sol","9":"lib/forge-std/src/StdStorage.sol","10":"lib/forge-std/src/StdStyle.sol","11":"lib/forge-std/src/StdToml.sol","12":"lib/forge-std/src/StdUtils.sol","13":"lib/forge-std/src/Test.sol","14":"lib/forge-std/src/Vm.sol","15":"lib/forge-std/src/console.sol","16":"lib/forge-std/src/console2.sol","17":"lib/forge-std/src/interfaces/IMulticall3.sol","18":"lib/forge-std/src/safeconsole.sol","19":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol","20":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol","21":"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","22":"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","23":"lib/sequence-v3/src/modules/Payload.sol","24":"lib/sequence-v3/src/utils/LibBytes.sol","25":"src/helper/SignalsImplicitMode.sol","26":"src/registry/IImplicitProjectRegistry.sol","27":"src/registry/IImplicitProjectValidation.sol","28":"src/registry/ImplicitProjectRegistry.sol","29":"test/ImplicitProjectRegistry.t.sol","30":"test/SignalsImplicitMode.t.sol","31":"test/TestHelper.sol","32":"test/mock/SignalsImplicitModeMock.sol"},"language":"Solidity"} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/build-info/efb7c762ba0fcac7.json b/lib/signals-implicit-mode/out/build-info/efb7c762ba0fcac7.json deleted file mode 100644 index afcd738c3e..0000000000 --- a/lib/signals-implicit-mode/out/build-info/efb7c762ba0fcac7.json +++ /dev/null @@ -1 +0,0 @@ -{"id":"efb7c762ba0fcac7","source_id_to_path":{"0":"lib/forge-std/src/Base.sol","1":"lib/forge-std/src/Script.sol","2":"lib/forge-std/src/StdChains.sol","3":"lib/forge-std/src/StdCheats.sol","4":"lib/forge-std/src/StdConstants.sol","5":"lib/forge-std/src/StdJson.sol","6":"lib/forge-std/src/StdMath.sol","7":"lib/forge-std/src/StdStorage.sol","8":"lib/forge-std/src/StdStyle.sol","9":"lib/forge-std/src/StdUtils.sol","10":"lib/forge-std/src/Vm.sol","11":"lib/forge-std/src/console.sol","12":"lib/forge-std/src/console2.sol","13":"lib/forge-std/src/interfaces/IMulticall3.sol","14":"lib/forge-std/src/safeconsole.sol","15":"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol","16":"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol","17":"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","18":"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","19":"lib/sequence-v3/src/modules/Payload.sol","20":"lib/sequence-v3/src/utils/LibBytes.sol","21":"script/Deploy.s.sol","22":"src/registry/IImplicitProjectRegistry.sol","23":"src/registry/IImplicitProjectValidation.sol","24":"src/registry/ImplicitProjectRegistry.sol"},"language":"Solidity"} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/build-info/fa257e35d2cb2ae3.json b/lib/signals-implicit-mode/out/build-info/fa257e35d2cb2ae3.json deleted file mode 100644 index 2984d17b26..0000000000 --- a/lib/signals-implicit-mode/out/build-info/fa257e35d2cb2ae3.json +++ /dev/null @@ -1 +0,0 @@ -{"id":"fa257e35d2cb2ae3","source_id_to_path":{"0":"lib/forge-std/src/Base.sol","1":"lib/forge-std/src/Script.sol","2":"lib/forge-std/src/StdAssertions.sol","3":"lib/forge-std/src/StdChains.sol","4":"lib/forge-std/src/StdCheats.sol","5":"lib/forge-std/src/StdConstants.sol","6":"lib/forge-std/src/StdError.sol","7":"lib/forge-std/src/StdInvariant.sol","8":"lib/forge-std/src/StdJson.sol","9":"lib/forge-std/src/StdMath.sol","10":"lib/forge-std/src/StdStorage.sol","11":"lib/forge-std/src/StdStyle.sol","12":"lib/forge-std/src/StdToml.sol","13":"lib/forge-std/src/StdUtils.sol","14":"lib/forge-std/src/Test.sol","15":"lib/forge-std/src/Vm.sol","16":"lib/forge-std/src/console.sol","17":"lib/forge-std/src/console2.sol","18":"lib/forge-std/src/interfaces/IMulticall3.sol","19":"lib/forge-std/src/safeconsole.sol","20":"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol","21":"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol","22":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol","23":"lib/sequence-v3/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol","24":"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol","25":"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol","26":"lib/sequence-v3/src/modules/Payload.sol","27":"lib/sequence-v3/src/utils/LibBytes.sol","28":"script/Deploy.s.sol","29":"src/helper/SignalsImplicitMode.sol","30":"src/registry/IImplicitProjectRegistry.sol","31":"src/registry/IImplicitProjectValidation.sol","32":"src/registry/ImplicitProjectRegistry.sol","33":"test/ImplicitProjectRegistry.t.sol","34":"test/SignalsImplicitMode.t.sol","35":"test/TestHelper.sol","36":"test/mock/SignalsImplicitModeMock.sol"},"language":"Solidity"} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/console.sol/console.json b/lib/signals-implicit-mode/out/console.sol/console.json deleted file mode 100644 index 570c496260..0000000000 --- a/lib/signals-implicit-mode/out/console.sol/console.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x60566050600b82828239805160001a6073146043577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212202590f5e65131017c59507b5eecb10a4a3def30d52d91b5793ff9291a514e0c9a64736f6c634300081c0033","sourceMap":"66:69203:15:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212202590f5e65131017c59507b5eecb10a4a3def30d52d91b5793ff9291a514e0c9a64736f6c634300081c0033","sourceMap":"66:69203:15:-:0;;;;;;;;","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/console.sol\":\"console\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/console.sol":"console"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"}},"version":1},"id":15} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/safeconsole.sol/safeconsole.json b/lib/signals-implicit-mode/out/safeconsole.sol/safeconsole.json deleted file mode 100644 index 7af35ccaa7..0000000000 --- a/lib/signals-implicit-mode/out/safeconsole.sol/safeconsole.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[],"bytecode":{"object":"0x60566050600b82828239805160001a6073146043577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea264697066735822122080b0b0a7da125da6fabb1d1b62c0f0bfc81a8a286f9efe279daa20b9ea21ddbe64736f6c634300081c0033","sourceMap":"163:427371:18:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x73000000000000000000000000000000000000000030146080604052600080fdfea264697066735822122080b0b0a7da125da6fabb1d1b62c0f0bfc81a8a286f9efe279daa20b9ea21ddbe64736f6c634300081c0033","sourceMap":"163:427371:18:-:0;;;;;;;;","linkReferences":{}},"methodIdentifiers":{},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"author\":\"philogy \",\"details\":\"Code generated automatically by script.\",\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"lib/forge-std/src/safeconsole.sol\":\"safeconsole\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std-1.14.0/=dependencies/forge-std-1.14.0/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/safeconsole.sol\":{\"keccak256\":\"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab\",\"dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std-1.14.0/=dependencies/forge-std-1.14.0/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"lib/forge-std/src/safeconsole.sol":"safeconsole"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/safeconsole.sol":{"keccak256":"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11","urls":["bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab","dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3"],"license":"MIT"}},"version":1},"id":18} \ No newline at end of file diff --git a/lib/signals-implicit-mode/out/script/deploy.s.sol/Deploy.json b/lib/signals-implicit-mode/out/script/deploy.s.sol/Deploy.json deleted file mode 100644 index 19637dbe46..0000000000 --- a/lib/signals-implicit-mode/out/script/deploy.s.sol/Deploy.json +++ /dev/null @@ -1 +0,0 @@ -{"abi":[{"type":"function","name":"IS_SCRIPT","inputs":[],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"run","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"type":"error","name":"DeploymentFailed","inputs":[{"name":"reason","type":"string","internalType":"string"}]}],"bytecode":{"object":"0x60806040526001600c60006101000a81548160ff0219169083151502179055506001600c60026101000a81548160ff021916908315150217905550348015604557600080fd5b50613624806100556000396000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c8063c04062261461003b578063f8ccbf4714610045575b600080fd5b610043610063565b005b61004d610189565b60405161005a9190610a7f565b60405180910390f35b6000737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c1978d1f6040518163ffffffff1660e01b81526004016100b090610af7565b602060405180830381865afa1580156100cd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906100f19190610b52565b905060008060001b905060006040518060200161010d90610a4d565b6020820181038252601f19601f820116604052506040516020016101319190610bf0565b60405160208183030381529060405290506101836040518060400160405280601781526020017f496d706c6963697450726f6a656374526567697374727900000000000000000081525082848661019c565b50505050565b600c60029054906101000a900460ff1681565b60006101a7826104b2565b6101b184846107da565b905060028173ffffffffffffffffffffffffffffffffffffffff163b1161046957610212856040518060400160405280600c81526020017f6465706c6f79696e6720746f000000000000000000000000000000000000000081525083610833565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ce817d47836040518263ffffffff1660e01b815260040161025f9190610c16565b600060405180830381600087803b15801561027957600080fd5b505af115801561028d573d6000803e3d6000fd5b50505050600073ce0042b868300000d44a59004da54a005ffdcf9f73ffffffffffffffffffffffffffffffffffffffff16634af63f0286866040518363ffffffff1660e01b81526004016102e2929190610ca5565b6020604051808303816000875af1158015610301573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103259190610d33565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166376eadd366040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561038357600080fd5b505af1158015610397573d6000803e3d6000fd5b505050508073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614610409576040517f20631f9100000000000000000000000000000000000000000000000000000000815260040161040090610dac565b60405180910390fd5b60028273ffffffffffffffffffffffffffffffffffffffff163b11610463576040517f20631f9100000000000000000000000000000000000000000000000000000000815260040161045a90610e18565b60405180910390fd5b506104aa565b6104a9856040518060400160405280601381526020017f616c7265616479206465706c6f79656420746f0000000000000000000000000081525083610833565b5b949350505050565b600273ce0042b868300000d44a59004da54a005ffdcf9f73ffffffffffffffffffffffffffffffffffffffff163b116107d7576657c084e5f3c00073bb6e024b9cffacb947a71991e386681b1cd1477d73ffffffffffffffffffffffffffffffffffffffff163110156106e95761055d6040518060400160405280601d81526020017f46756e64696e672053696e676c65746f6e20466163746f727920454f410000008152506108d2565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ce817d47826040518263ffffffff1660e01b81526004016105aa9190610c16565b600060405180830381600087803b1580156105c457600080fd5b505af11580156105d8573d6000803e3d6000fd5b5050505073bb6e024b9cffacb947a71991e386681b1cd1477d73ffffffffffffffffffffffffffffffffffffffff166108fc73bb6e024b9cffacb947a71991e386681b1cd1477d73ffffffffffffffffffffffffffffffffffffffff16316657c084e5f3c0006106489190610e67565b9081150290604051600060405180830381858888f19350505050158015610673573d6000803e3d6000fd5b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166376eadd366040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156106d057600080fd5b505af11580156106e4573d6000803e3d6000fd5b505050505b61073c6040518060400160405280601e81526020017f4465706c6f79696e672053696e676c65746f6e20466163746f727920746f000081525073ce0042b868300000d44a59004da54a005ffdcf9f61096b565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16638c0c72e0604051806101a0016040528061016f815260200161348061016f91396040518263ffffffff1660e01b81526004016107a49190610e9b565b600060405180830381600087803b1580156107be57600080fd5b505af11580156107d2573d6000803e3d6000fd5b505050505b50565b600060ff60f81b73ce0042b868300000d44a59004da54a005ffdcf9f8385805190602001206040516020016108129493929190610f85565b6040516020818303038152906040528051906020012060001c905092915050565b6108cd83838360405160240161084b93929190611026565b6040516020818303038152906040527f95ed0195000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610a07565b505050565b610968816040516024016108e6919061106b565b6040516020818303038152906040527f41304fac000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610a07565b50565b610a03828260405160240161098192919061108d565b6040516020818303038152906040527f319af333000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610a07565b5050565b610a1e81610a16610a21610a42565b63ffffffff16565b50565b60006a636f6e736f6c652e6c6f679050600080835160208501845afa505050565b610a5a819050919050565b612393806110ed83390190565b610a626110bd565b565b60008115159050919050565b610a7981610a64565b82525050565b6000602082019050610a946000830184610a70565b92915050565b600082825260208201905092915050565b7f505249564154455f4b4559000000000000000000000000000000000000000000600082015250565b6000610ae1600b83610a9a565b9150610aec82610aab565b602082019050919050565b60006020820190508181036000830152610b1081610ad4565b9050919050565b600080fd5b6000819050919050565b610b2f81610b1c565b8114610b3a57600080fd5b50565b600081519050610b4c81610b26565b92915050565b600060208284031215610b6857610b67610b17565b5b6000610b7684828501610b3d565b91505092915050565b600081519050919050565b600081905092915050565b60005b83811015610bb3578082015181840152602081019050610b98565b60008484015250505050565b6000610bca82610b7f565b610bd48185610b8a565b9350610be4818560208601610b95565b80840191505092915050565b6000610bfc8284610bbf565b915081905092915050565b610c1081610b1c565b82525050565b6000602082019050610c2b6000830184610c07565b92915050565b600082825260208201905092915050565b6000601f19601f8301169050919050565b6000610c5e82610b7f565b610c688185610c31565b9350610c78818560208601610b95565b610c8181610c42565b840191505092915050565b6000819050919050565b610c9f81610c8c565b82525050565b60006040820190508181036000830152610cbf8185610c53565b9050610cce6020830184610c96565b9392505050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000610d0082610cd5565b9050919050565b610d1081610cf5565b8114610d1b57600080fd5b50565b600081519050610d2d81610d07565b92915050565b600060208284031215610d4957610d48610b17565b5b6000610d5784828501610d1e565b91505092915050565b7f4465706c6f7965642061646472657373206d69736d6174636800000000000000600082015250565b6000610d96601983610a9a565b9150610da182610d60565b602082019050919050565b60006020820190508181036000830152610dc581610d89565b9050919050565b7f4465706c6f796d656e74206661696c6564000000000000000000000000000000600082015250565b6000610e02601183610a9a565b9150610e0d82610dcc565b602082019050919050565b60006020820190508181036000830152610e3181610df5565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000610e7282610b1c565b9150610e7d83610b1c565b9250828203905081811115610e9557610e94610e38565b5b92915050565b60006020820190508181036000830152610eb58184610c53565b905092915050565b60007fff0000000000000000000000000000000000000000000000000000000000000082169050919050565b6000819050919050565b610f04610eff82610ebd565b610ee9565b82525050565b6000610f1582610cd5565b9050919050565b60008160601b9050919050565b6000610f3482610f1c565b9050919050565b6000610f4682610f29565b9050919050565b610f5e610f5982610f0a565b610f3b565b82525050565b6000819050919050565b610f7f610f7a82610c8c565b610f64565b82525050565b6000610f918287610ef3565b600182019150610fa18286610f4d565b601482019150610fb18285610f6e565b602082019150610fc18284610f6e565b60208201915081905095945050505050565b600081519050919050565b6000610fe982610fd3565b610ff38185610a9a565b9350611003818560208601610b95565b61100c81610c42565b840191505092915050565b61102081610f0a565b82525050565b600060608201905081810360008301526110408186610fde565b905081810360208301526110548185610fde565b90506110636040830184611017565b949350505050565b600060208201905081810360008301526110858184610fde565b905092915050565b600060408201905081810360008301526110a78185610fde565b90506110b66020830184611017565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052605160045260246000fdfe6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea2646970667358221220768c5864c372b59b00aaf9c4fb0bd421fb0269630e262b0b4ba9fd8f6f438b6064736f6c634300081c0033f9016c8085174876e8008303c4d88080b90154608060405234801561001057600080fd5b50610134806100206000396000f3fe6080604052348015600f57600080fd5b506004361060285760003560e01c80634af63f0214602d575b600080fd5b60cf60048036036040811015604157600080fd5b810190602081018135640100000000811115605b57600080fd5b820183602082011115606c57600080fd5b80359060200191846001830284011164010000000083111715608d57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550509135925060eb915050565b604080516001600160a01b039092168252519081900360200190f35b6000818351602085016000f5939250505056fea26469706673582212206b44f8a82cb6b156bfcc3dc6aadd6df4eefd204bc928a4397fd15dacf6d5320564736f6c634300060200331b83247000822470a26469706673582212208804a17c30bf62a84228857830ff83cedeb31312129171077c3e72e91d36d0c264736f6c634300081c0033","sourceMap":"240:313:21:-:0;;;3200:4:2;3160:44;;;;;;;;;;;;;;;;;;;;873:4:1;849:28;;;;;;;;;;;;;;;;;;;;240:313:21;;;;;;;;;;;;;;;;","linkReferences":{}},"deployedBytecode":{"object":"0x608060405234801561001057600080fd5b50600436106100365760003560e01c8063c04062261461003b578063f8ccbf4714610045575b600080fd5b610043610063565b005b61004d610189565b60405161005a9190610a7f565b60405180910390f35b6000737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663c1978d1f6040518163ffffffff1660e01b81526004016100b090610af7565b602060405180830381865afa1580156100cd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906100f19190610b52565b905060008060001b905060006040518060200161010d90610a4d565b6020820181038252601f19601f820116604052506040516020016101319190610bf0565b60405160208183030381529060405290506101836040518060400160405280601781526020017f496d706c6963697450726f6a656374526567697374727900000000000000000081525082848661019c565b50505050565b600c60029054906101000a900460ff1681565b60006101a7826104b2565b6101b184846107da565b905060028173ffffffffffffffffffffffffffffffffffffffff163b1161046957610212856040518060400160405280600c81526020017f6465706c6f79696e6720746f000000000000000000000000000000000000000081525083610833565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ce817d47836040518263ffffffff1660e01b815260040161025f9190610c16565b600060405180830381600087803b15801561027957600080fd5b505af115801561028d573d6000803e3d6000fd5b50505050600073ce0042b868300000d44a59004da54a005ffdcf9f73ffffffffffffffffffffffffffffffffffffffff16634af63f0286866040518363ffffffff1660e01b81526004016102e2929190610ca5565b6020604051808303816000875af1158015610301573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103259190610d33565b9050737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166376eadd366040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561038357600080fd5b505af1158015610397573d6000803e3d6000fd5b505050508073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614610409576040517f20631f9100000000000000000000000000000000000000000000000000000000815260040161040090610dac565b60405180910390fd5b60028273ffffffffffffffffffffffffffffffffffffffff163b11610463576040517f20631f9100000000000000000000000000000000000000000000000000000000815260040161045a90610e18565b60405180910390fd5b506104aa565b6104a9856040518060400160405280601381526020017f616c7265616479206465706c6f79656420746f0000000000000000000000000081525083610833565b5b949350505050565b600273ce0042b868300000d44a59004da54a005ffdcf9f73ffffffffffffffffffffffffffffffffffffffff163b116107d7576657c084e5f3c00073bb6e024b9cffacb947a71991e386681b1cd1477d73ffffffffffffffffffffffffffffffffffffffff163110156106e95761055d6040518060400160405280601d81526020017f46756e64696e672053696e676c65746f6e20466163746f727920454f410000008152506108d2565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff1663ce817d47826040518263ffffffff1660e01b81526004016105aa9190610c16565b600060405180830381600087803b1580156105c457600080fd5b505af11580156105d8573d6000803e3d6000fd5b5050505073bb6e024b9cffacb947a71991e386681b1cd1477d73ffffffffffffffffffffffffffffffffffffffff166108fc73bb6e024b9cffacb947a71991e386681b1cd1477d73ffffffffffffffffffffffffffffffffffffffff16316657c084e5f3c0006106489190610e67565b9081150290604051600060405180830381858888f19350505050158015610673573d6000803e3d6000fd5b50737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff166376eadd366040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156106d057600080fd5b505af11580156106e4573d6000803e3d6000fd5b505050505b61073c6040518060400160405280601e81526020017f4465706c6f79696e672053696e676c65746f6e20466163746f727920746f000081525073ce0042b868300000d44a59004da54a005ffdcf9f61096b565b737109709ecfa91a80626ff3989d68f67f5b1dd12d73ffffffffffffffffffffffffffffffffffffffff16638c0c72e0604051806101a0016040528061016f815260200161348061016f91396040518263ffffffff1660e01b81526004016107a49190610e9b565b600060405180830381600087803b1580156107be57600080fd5b505af11580156107d2573d6000803e3d6000fd5b505050505b50565b600060ff60f81b73ce0042b868300000d44a59004da54a005ffdcf9f8385805190602001206040516020016108129493929190610f85565b6040516020818303038152906040528051906020012060001c905092915050565b6108cd83838360405160240161084b93929190611026565b6040516020818303038152906040527f95ed0195000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610a07565b505050565b610968816040516024016108e6919061106b565b6040516020818303038152906040527f41304fac000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610a07565b50565b610a03828260405160240161098192919061108d565b6040516020818303038152906040527f319af333000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610a07565b5050565b610a1e81610a16610a21610a42565b63ffffffff16565b50565b60006a636f6e736f6c652e6c6f679050600080835160208501845afa505050565b610a5a819050919050565b612393806110ed83390190565b610a626110bd565b565b60008115159050919050565b610a7981610a64565b82525050565b6000602082019050610a946000830184610a70565b92915050565b600082825260208201905092915050565b7f505249564154455f4b4559000000000000000000000000000000000000000000600082015250565b6000610ae1600b83610a9a565b9150610aec82610aab565b602082019050919050565b60006020820190508181036000830152610b1081610ad4565b9050919050565b600080fd5b6000819050919050565b610b2f81610b1c565b8114610b3a57600080fd5b50565b600081519050610b4c81610b26565b92915050565b600060208284031215610b6857610b67610b17565b5b6000610b7684828501610b3d565b91505092915050565b600081519050919050565b600081905092915050565b60005b83811015610bb3578082015181840152602081019050610b98565b60008484015250505050565b6000610bca82610b7f565b610bd48185610b8a565b9350610be4818560208601610b95565b80840191505092915050565b6000610bfc8284610bbf565b915081905092915050565b610c1081610b1c565b82525050565b6000602082019050610c2b6000830184610c07565b92915050565b600082825260208201905092915050565b6000601f19601f8301169050919050565b6000610c5e82610b7f565b610c688185610c31565b9350610c78818560208601610b95565b610c8181610c42565b840191505092915050565b6000819050919050565b610c9f81610c8c565b82525050565b60006040820190508181036000830152610cbf8185610c53565b9050610cce6020830184610c96565b9392505050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000610d0082610cd5565b9050919050565b610d1081610cf5565b8114610d1b57600080fd5b50565b600081519050610d2d81610d07565b92915050565b600060208284031215610d4957610d48610b17565b5b6000610d5784828501610d1e565b91505092915050565b7f4465706c6f7965642061646472657373206d69736d6174636800000000000000600082015250565b6000610d96601983610a9a565b9150610da182610d60565b602082019050919050565b60006020820190508181036000830152610dc581610d89565b9050919050565b7f4465706c6f796d656e74206661696c6564000000000000000000000000000000600082015250565b6000610e02601183610a9a565b9150610e0d82610dcc565b602082019050919050565b60006020820190508181036000830152610e3181610df5565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000610e7282610b1c565b9150610e7d83610b1c565b9250828203905081811115610e9557610e94610e38565b5b92915050565b60006020820190508181036000830152610eb58184610c53565b905092915050565b60007fff0000000000000000000000000000000000000000000000000000000000000082169050919050565b6000819050919050565b610f04610eff82610ebd565b610ee9565b82525050565b6000610f1582610cd5565b9050919050565b60008160601b9050919050565b6000610f3482610f1c565b9050919050565b6000610f4682610f29565b9050919050565b610f5e610f5982610f0a565b610f3b565b82525050565b6000819050919050565b610f7f610f7a82610c8c565b610f64565b82525050565b6000610f918287610ef3565b600182019150610fa18286610f4d565b601482019150610fb18285610f6e565b602082019150610fc18284610f6e565b60208201915081905095945050505050565b600081519050919050565b6000610fe982610fd3565b610ff38185610a9a565b9350611003818560208601610b95565b61100c81610c42565b840191505092915050565b61102081610f0a565b82525050565b600060608201905081810360008301526110408186610fde565b905081810360208301526110548185610fde565b90506110636040830184611017565b949350505050565b600060208201905081810360008301526110858184610fde565b905092915050565b600060408201905081810360008301526110a78185610fde565b90506110b66020830184611017565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052605160045260246000fdfe6080604052348015600f57600080fd5b506123748061001f6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063a25acb251161008c578063d9acbe6b11610066578063d9acbe6b14610243578063dac6c58714610273578063ebc27b821461028f578063f4364de6146102bf576100ea565b8063a25acb25146101c7578063d4c9c5c4146101f7578063d4df101814610213576100ea565b80633808a90b116100c85780633808a90b14610143578063520994f11461017357806356cd2b921461018f5780639630aff8146101ab576100ea565b8063065d6c69146100ef5780631b31f01b1461010b5780632f28c69d14610127575b600080fd5b61010960048036038101906101049190611436565b6102ef565b005b610125600480360381019061012091906114c8565b6103ca565b005b610141600480360381019061013c91906115d0565b610473565b005b61015d600480360381019061015891906116ae565b610522565b60405161016a919061172c565b60405180910390f35b61018d60048036038101906101889190611747565b610625565b005b6101a960048036038101906101a49190611868565b6106cc565b005b6101c560048036038101906101c091906118c4565b6107af565b005b6101e160048036038101906101dc9190611747565b610947565b6040516101ee919061191f565b60405180910390f35b610211600480360381019061020c91906119fd565b610976565b005b61022d60048036038101906102289190611ae0565b610b48565b60405161023a919061172c565b60405180910390f35b61025d60048036038101906102589190611b0d565b610d14565b60405161026a919061172c565b60405180910390f35b61028d600480360381019061028891906115d0565b610d45565b005b6102a960048036038101906102a49190611b4d565b610e98565b6040516102b69190611b89565b60405180910390f35b6102d960048036038101906102d49190611b4d565b610ecb565b6040516102e69190611c62565b60405180910390f35b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610387576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156103c4576103b7848483815181106103aa576103a9611c84565b5b6020026020010151610f36565b808060010191505061038a565b50505050565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610462576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61046d848484611047565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461050b576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61051d8361051884611200565b610f36565b505050565b60008061058f848060a001906105389190611cc2565b80600001906105479190611cea565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611200565b905060016000848152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff16156105ec576105e485856105d690611fd4565b61123090919063ffffffff16565b91505061061e565b6040517fd7abef4e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146106bd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c78383610f36565b505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610764576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b82518110156107a95761079c8461079785848151811061078a57610789611c84565b5b6020026020010151611200565b610f36565b8080600101915050610767565b50505050565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610847576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036108ad576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160008085815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff16837f7869f0fa3d7efaa83c69bf6de987567787178b8d7e41fea0cadfea68a2e27de560405160405180910390a3505050565b60016020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b823373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610a0e576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151835114610a49576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b60018351610a5a9190612016565b811015610ae85782600182610a6f919061204a565b81518110610a8057610a7f611c84565b5b6020026020010151838281518110610a9b57610a9a611c84565b5b60200260200101511015610adb576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080600101915050610a4c565b5060005b8351811015610b4157610b3485858381518110610b0c57610b0b611c84565b5b6020026020010151858481518110610b2757610b26611c84565b5b6020026020010151611047565b8080600101915050610aec565b5050505050565b600080339050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610bb4576040517fff7d580d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8281604051602001610bc79291906120e7565b604051602081830303815290604052610bdf90612150565b9150600073ffffffffffffffffffffffffffffffffffffffff1660008084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c79576040517ffeabeb4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16827f0f01cd0734cc8ed416ac6ca25cb4fe02dbab63f1236af3858deb14a56663623860405160405180910390a350919050565b60026020528160005260406000208181548110610d3057600080fd5b90600052602060002001600091509150505481565b813373ffffffffffffffffffffffffffffffffffffffff1660008083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610ddd576040517f7c2411e900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610de883611200565b905060005b6002600086815260200190815260200160002080549050811015610e605781600260008781526020019081526020016000208281548110610e3157610e30611c84565b5b906000526020600020015403610e5357610e4c858383611047565b5050610e93565b8080600101915050610ded565b506040517f4745a4ee00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b60006020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606060026000838152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815481526020019060010190808311610f16575b50505050509050919050565b60016000838152602001908152602001600020600082815260200190815260200160002060009054906101000a900460ff1615610f9f576040517f2d86c03a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001806000848152602001908152602001600020600083815260200190815260200160002060006101000a81548160ff0219169083151502179055506002600083815260200190815260200160002081908060018154018082558091505060019003906000526020600020016000909190919091505580827fceac3080d7874c4bba80ceae14b6aa96e0df9d4f673d9e5a352d66444f50206760405160405180910390a35050565b60026000848152602001908152602001600020805490508110158061109b57508160026000858152602001908152602001600020828154811061108d5761108c611c84565b5b906000526020600020015414155b156110d2576040517f526c768700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060016000858152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff02191690831515021790555060026000848152602001908152602001600020600160026000868152602001908152602001600020805490506111459190612016565b8154811061115657611155611c84565b5b906000526020600020015460026000858152602001908152602001600020828154811061118657611185611c84565b5b9060005260206000200181905550600260008481526020019081526020016000208054806111b7576111b66121b7565b5b6001900381819060005260206000200160009055905581837f13d94de535e503661de3c84adf637590f269f37c8d4ed5daabae98376a442a6a60405160405180910390a3505050565b6000816040516020016112139190612257565b604051602081830303815290604052805190602001209050919050565b6000604051602001611241906122ba565b60405160208183030381529060405280519060200120828460600151856040015160405160200161127594939291906122f0565b60405160208183030381529060405280519060200120905092915050565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6112ba816112a7565b81146112c557600080fd5b50565b6000813590506112d7816112b1565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61132b826112e2565b810181811067ffffffffffffffff8211171561134a576113496112f3565b5b80604052505050565b600061135d611293565b90506113698282611322565b919050565b600067ffffffffffffffff821115611389576113886112f3565b5b602082029050602081019050919050565b600080fd5b60006113b26113ad8461136e565b611353565b905080838252602082019050602084028301858111156113d5576113d461139a565b5b835b818110156113fe57806113ea88826112c8565b8452602084019350506020810190506113d7565b5050509392505050565b600082601f83011261141d5761141c6112dd565b5b813561142d84826020860161139f565b91505092915050565b6000806040838503121561144d5761144c61129d565b5b600061145b858286016112c8565b925050602083013567ffffffffffffffff81111561147c5761147b6112a2565b5b61148885828601611408565b9150509250929050565b6000819050919050565b6114a581611492565b81146114b057600080fd5b50565b6000813590506114c28161149c565b92915050565b6000806000606084860312156114e1576114e061129d565b5b60006114ef868287016112c8565b9350506020611500868287016112c8565b9250506040611511868287016114b3565b9150509250925092565b600080fd5b600067ffffffffffffffff82111561153b5761153a6112f3565b5b611544826112e2565b9050602081019050919050565b82818337600083830152505050565b600061157361156e84611520565b611353565b90508281526020810184848401111561158f5761158e61151b565b5b61159a848285611551565b509392505050565b600082601f8301126115b7576115b66112dd565b5b81356115c7848260208601611560565b91505092915050565b600080604083850312156115e7576115e661129d565b5b60006115f5858286016112c8565b925050602083013567ffffffffffffffff811115611616576116156112a2565b5b611622858286016115a2565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006116578261162c565b9050919050565b6116678161164c565b811461167257600080fd5b50565b6000813590506116848161165e565b92915050565b600080fd5b600060c082840312156116a5576116a461168a565b5b81905092915050565b6000806000606084860312156116c7576116c661129d565b5b60006116d586828701611675565b935050602084013567ffffffffffffffff8111156116f6576116f56112a2565b5b6117028682870161168f565b9250506040611713868287016112c8565b9150509250925092565b611726816112a7565b82525050565b6000602082019050611741600083018461171d565b92915050565b6000806040838503121561175e5761175d61129d565b5b600061176c858286016112c8565b925050602061177d858286016112c8565b9150509250929050565b600067ffffffffffffffff8211156117a2576117a16112f3565b5b602082029050602081019050919050565b60006117c66117c184611787565b611353565b905080838252602082019050602084028301858111156117e9576117e861139a565b5b835b8181101561183057803567ffffffffffffffff81111561180e5761180d6112dd565b5b80860161181b89826115a2565b855260208501945050506020810190506117eb565b5050509392505050565b600082601f83011261184f5761184e6112dd565b5b813561185f8482602086016117b3565b91505092915050565b6000806040838503121561187f5761187e61129d565b5b600061188d858286016112c8565b925050602083013567ffffffffffffffff8111156118ae576118ad6112a2565b5b6118ba8582860161183a565b9150509250929050565b600080604083850312156118db576118da61129d565b5b60006118e9858286016112c8565b92505060206118fa85828601611675565b9150509250929050565b60008115159050919050565b61191981611904565b82525050565b60006020820190506119346000830184611910565b92915050565b600067ffffffffffffffff821115611955576119546112f3565b5b602082029050602081019050919050565b60006119796119748461193a565b611353565b9050808382526020820190506020840283018581111561199c5761199b61139a565b5b835b818110156119c557806119b188826114b3565b84526020840193505060208101905061199e565b5050509392505050565b600082601f8301126119e4576119e36112dd565b5b81356119f4848260208601611966565b91505092915050565b600080600060608486031215611a1657611a1561129d565b5b6000611a24868287016112c8565b935050602084013567ffffffffffffffff811115611a4557611a446112a2565b5b611a5186828701611408565b925050604084013567ffffffffffffffff811115611a7257611a716112a2565b5b611a7e868287016119cf565b9150509250925092565b60007fffffffffffffffffffffffff000000000000000000000000000000000000000082169050919050565b611abd81611a88565b8114611ac857600080fd5b50565b600081359050611ada81611ab4565b92915050565b600060208284031215611af657611af561129d565b5b6000611b0484828501611acb565b91505092915050565b60008060408385031215611b2457611b2361129d565b5b6000611b32858286016112c8565b9250506020611b43858286016114b3565b9150509250929050565b600060208284031215611b6357611b6261129d565b5b6000611b71848285016112c8565b91505092915050565b611b838161164c565b82525050565b6000602082019050611b9e6000830184611b7a565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611bd9816112a7565b82525050565b6000611beb8383611bd0565b60208301905092915050565b6000602082019050919050565b6000611c0f82611ba4565b611c198185611baf565b9350611c2483611bc0565b8060005b83811015611c55578151611c3c8882611bdf565b9750611c4783611bf7565b925050600181019050611c28565b5085935050505092915050565b60006020820190508181036000830152611c7c8184611c04565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600082356001604003833603038112611cde57611cdd611cb3565b5b80830191505092915050565b60008083356001602003843603038112611d0757611d06611cb3565b5b80840192508235915067ffffffffffffffff821115611d2957611d28611cb8565b5b602083019250600182023603831315611d4557611d44611cbd565b5b509250929050565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b611d8c81611d57565b8114611d9757600080fd5b50565b600081359050611da981611d83565b92915050565b600067ffffffffffffffff821115611dca57611dc96112f3565b5b611dd3826112e2565b9050602081019050919050565b6000611df3611dee84611daf565b611353565b905082815260208101848484011115611e0f57611e0e61151b565b5b611e1a848285611551565b509392505050565b600082601f830112611e3757611e366112dd565b5b8135611e47848260208601611de0565b91505092915050565b600067ffffffffffffffff82169050919050565b611e6d81611e50565b8114611e7857600080fd5b50565b600081359050611e8a81611e64565b92915050565b600060408284031215611ea657611ea5611d4d565b5b611eb06040611353565b9050600082013567ffffffffffffffff811115611ed057611ecf611d52565b5b611edc848285016115a2565b6000830152506020611ef084828501611e7b565b60208301525092915050565b600060c08284031215611f1257611f11611d4d565b5b611f1c60c0611353565b90506000611f2c84828501611675565b6000830152506020611f4084828501611d9a565b6020830152506040611f54848285016112c8565b6040830152506060611f68848285016112c8565b606083015250608082013567ffffffffffffffff811115611f8c57611f8b611d52565b5b611f9884828501611e22565b60808301525060a082013567ffffffffffffffff811115611fbc57611fbb611d52565b5b611fc884828501611e90565b60a08301525092915050565b6000611fe03683611efc565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061202182611492565b915061202c83611492565b925082820390508181111561204457612043611fe7565b5b92915050565b600061205582611492565b915061206083611492565b925082820190508082111561207857612077611fe7565b5b92915050565b6000819050919050565b61209961209482611a88565b61207e565b82525050565b60008160601b9050919050565b60006120b78261209f565b9050919050565b60006120c9826120ac565b9050919050565b6120e16120dc8261164c565b6120be565b82525050565b60006120f38285612088565b600c8201915061210382846120d0565b6014820191508190509392505050565b600081519050919050565b6000819050602082019050919050565b600061213a82516112a7565b80915050919050565b600082821b905092915050565b600061215b82612113565b826121658461211e565b90506121708161212e565b925060208210156121b0576121ab7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83602003600802612143565b831692505b5050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600081905092915050565b60005b8381101561221a5780820151818401526020810190506121ff565b60008484015250505050565b6000612231826121e6565b61223b81856121f1565b935061224b8185602086016121fc565b80840191505092915050565b60006122638284612226565b915081905092915050565b7f616363657074496d706c69636974526571756573740000000000000000000000600082015250565b60006122a46015836121f1565b91506122af8261226e565b601582019050919050565b60006122c582612297565b9150819050919050565b6000819050919050565b6122ea6122e5826112a7565b6122cf565b82525050565b60006122fc82876122d9565b60208201915061230c82866120d0565b60148201915061231c82856122d9565b60208201915061232c82846122d9565b6020820191508190509594505050505056fea2646970667358221220768c5864c372b59b00aaf9c4fb0bd421fb0269630e262b0b4ba9fd8f6f438b6064736f6c634300081c0033f9016c8085174876e8008303c4d88080b90154608060405234801561001057600080fd5b50610134806100206000396000f3fe6080604052348015600f57600080fd5b506004361060285760003560e01c80634af63f0214602d575b600080fd5b60cf60048036036040811015604157600080fd5b810190602081018135640100000000811115605b57600080fd5b820183602082011115606c57600080fd5b80359060200191846001830284011164010000000083111715608d57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550509135925060eb915050565b604080516001600160a01b039092168252519081900360200190f35b6000818351602085016000f5939250505056fea26469706673582212206b44f8a82cb6b156bfcc3dc6aadd6df4eefd204bc928a4397fd15dacf6d5320564736f6c634300060200331b83247000822470a26469706673582212208804a17c30bf62a84228857830ff83cedeb31312129171077c3e72e91d36d0c264736f6c634300081c0033","sourceMap":"240:313:21:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;282:268;;;:::i;:::-;;849:28:1;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;282:268:21;312:10;336:42:0;325:10:21;;;:25;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;312:38;;357:12;380:1;372:10;;357:25;;389:21;430:42;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;413:60;;;;;;;;:::i;:::-;;;;;;;;;;;;;389:84;;479:66;;;;;;;;;;;;;;;;;;526:8;536:4;542:2;479:19;:66::i;:::-;;306:244;;;282:268::o;849:28:1:-;;;;;;;;;;;;;:::o;1191:843:15:-;1325:12;1353:39;1389:2;1353:35;:39::i;:::-;1409:37;1429:9;1440:5;1409:19;:37::i;:::-;1402:44;;1480:1;1460:4;:16;;;:21;1456:551;;1497:39;1509:4;1497:39;;;;;;;;;;;;;;;;;1531:4;1497:11;:39::i;:::-;336:42:0;1550:17:15;;;1568:2;1550:21;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1585:18;107:42:16;1606:24:15;;;1631:9;1642:5;1606:42;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;1585:63;;336:42:0;1662:16:15;;;:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1706:10;1698:18;;:4;:18;;;1694:109;;1743:45;;;;;;;;;;:::i;:::-;;;;;;;;1694:109;1840:1;1820:4;:16;;;:21;1816:104;;1868:37;;;;;;;;;;:::i;:::-;;;;;;;;1816:104;1483:447;1456:551;;;1950:46;1962:4;1950:46;;;;;;;;;;;;;;;;;1991:4;1950:11;:46::i;:::-;1456:551;1191:843;;;;;;:::o;490:695::-;608:1;107:42:16;570:34:15;;;:39;566:613;;274:12:16;189:42;629:26:15;;;:50;625:360;;;745:44;;;;;;;;;;;;;;;;;;:11;:44::i;:::-;336:42:0;807:17:15;;;825:2;807:21;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;189:42:16;846:36:15;;:88;189:42:16;907:26:15;;;274:12:16;883:50:15;;;;:::i;:::-;846:88;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;336:42:0;952:16:15;;;:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;625:360;1038:69;;;;;;;;;;;;;;;;;;107:42:16;1038:11:15;:69::i;:::-;336:42:0;1121:26:15;;;1148:19;;;;;;;;;;;;;;;;;1121:47;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;566:613;490:695;:::o;2040:344::-;2131:12;2271:4;2264:12;;107:42:16;2306:5:15;2323:9;2313:20;;;;;;2247:87;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;2237:98;;;;;;2208:145;;2155:222;;2040:344;;;;:::o;12983:174:11:-;13068:82;13138:2;13142;13146;13084:65;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13068:15;:82::i;:::-;12983:174;;;:::o;6191:121::-;6246:59;6301:2;6262:42;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6246:15;:59::i;:::-;6191:121;:::o;7740:145::-;7807:71;7870:2;7874;7823:54;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7807:15;:71::i;:::-;7740:145;;:::o;851:129::-;922:51;965:7;922:42;934:29;922:11;:42::i;:::-;:51;;:::i;:::-;851:129;:::o;180:463::-;265:22;131:42;265:40;;594:1;571;541:7;535:14;510:2;501:7;497:16;461:14;434:5;402:211;381:246;367:270;180:463;:::o;649:196::-;748:33;825:4;816:13;;649:196;;;:::o;-1:-1:-1:-;;;;;;;;:::o;:::-;;;:::i;:::-;:::o;7:90:25:-;41:7;84:5;77:13;70:21;59:32;;7:90;;;:::o;103:109::-;184:21;199:5;184:21;:::i;:::-;179:3;172:34;103:109;;:::o;218:210::-;305:4;343:2;332:9;328:18;320:26;;356:65;418:1;407:9;403:17;394:6;356:65;:::i;:::-;218:210;;;;:::o;434:169::-;518:11;552:6;547:3;540:19;592:4;587:3;583:14;568:29;;434:169;;;;:::o;609:161::-;749:13;745:1;737:6;733:14;726:37;609:161;:::o;776:366::-;918:3;939:67;1003:2;998:3;939:67;:::i;:::-;932:74;;1015:93;1104:3;1015:93;:::i;:::-;1133:2;1128:3;1124:12;1117:19;;776:366;;;:::o;1148:419::-;1314:4;1352:2;1341:9;1337:18;1329:26;;1401:9;1395:4;1391:20;1387:1;1376:9;1372:17;1365:47;1429:131;1555:4;1429:131;:::i;:::-;1421:139;;1148:419;;;:::o;1654:117::-;1763:1;1760;1753:12;1900:77;1937:7;1966:5;1955:16;;1900:77;;;:::o;1983:122::-;2056:24;2074:5;2056:24;:::i;:::-;2049:5;2046:35;2036:63;;2095:1;2092;2085:12;2036:63;1983:122;:::o;2111:143::-;2168:5;2199:6;2193:13;2184:22;;2215:33;2242:5;2215:33;:::i;:::-;2111:143;;;;:::o;2260:351::-;2330:6;2379:2;2367:9;2358:7;2354:23;2350:32;2347:119;;;2385:79;;:::i;:::-;2347:119;2505:1;2530:64;2586:7;2577:6;2566:9;2562:22;2530:64;:::i;:::-;2520:74;;2476:128;2260:351;;;;:::o;2617:98::-;2668:6;2702:5;2696:12;2686:22;;2617:98;;;:::o;2721:147::-;2822:11;2859:3;2844:18;;2721:147;;;;:::o;2874:248::-;2956:1;2966:113;2980:6;2977:1;2974:13;2966:113;;;3065:1;3060:3;3056:11;3050:18;3046:1;3041:3;3037:11;3030:39;3002:2;2999:1;2995:10;2990:15;;2966:113;;;3113:1;3104:6;3099:3;3095:16;3088:27;2936:186;2874:248;;;:::o;3128:386::-;3232:3;3260:38;3292:5;3260:38;:::i;:::-;3314:88;3395:6;3390:3;3314:88;:::i;:::-;3307:95;;3411:65;3469:6;3464:3;3457:4;3450:5;3446:16;3411:65;:::i;:::-;3501:6;3496:3;3492:16;3485:23;;3236:278;3128:386;;;;:::o;3520:271::-;3650:3;3672:93;3761:3;3752:6;3672:93;:::i;:::-;3665:100;;3782:3;3775:10;;3520:271;;;;:::o;3797:118::-;3884:24;3902:5;3884:24;:::i;:::-;3879:3;3872:37;3797:118;;:::o;3921:222::-;4014:4;4052:2;4041:9;4037:18;4029:26;;4065:71;4133:1;4122:9;4118:17;4109:6;4065:71;:::i;:::-;3921:222;;;;:::o;4149:168::-;4232:11;4266:6;4261:3;4254:19;4306:4;4301:3;4297:14;4282:29;;4149:168;;;;:::o;4323:102::-;4364:6;4415:2;4411:7;4406:2;4399:5;4395:14;4391:28;4381:38;;4323:102;;;:::o;4431:373::-;4517:3;4545:38;4577:5;4545:38;:::i;:::-;4599:70;4662:6;4657:3;4599:70;:::i;:::-;4592:77;;4678:65;4736:6;4731:3;4724:4;4717:5;4713:16;4678:65;:::i;:::-;4768:29;4790:6;4768:29;:::i;:::-;4763:3;4759:39;4752:46;;4521:283;4431:373;;;;:::o;4810:77::-;4847:7;4876:5;4865:16;;4810:77;;;:::o;4893:118::-;4980:24;4998:5;4980:24;:::i;:::-;4975:3;4968:37;4893:118;;:::o;5017:419::-;5156:4;5194:2;5183:9;5179:18;5171:26;;5243:9;5237:4;5233:20;5229:1;5218:9;5214:17;5207:47;5271:76;5342:4;5333:6;5271:76;:::i;:::-;5263:84;;5357:72;5425:2;5414:9;5410:18;5401:6;5357:72;:::i;:::-;5017:419;;;;;:::o;5442:126::-;5479:7;5519:42;5512:5;5508:54;5497:65;;5442:126;;;:::o;5574:104::-;5619:7;5648:24;5666:5;5648:24;:::i;:::-;5637:35;;5574:104;;;:::o;5684:138::-;5765:32;5791:5;5765:32;:::i;:::-;5758:5;5755:43;5745:71;;5812:1;5809;5802:12;5745:71;5684:138;:::o;5828:159::-;5893:5;5924:6;5918:13;5909:22;;5940:41;5975:5;5940:41;:::i;:::-;5828:159;;;;:::o;5993:367::-;6071:6;6120:2;6108:9;6099:7;6095:23;6091:32;6088:119;;;6126:79;;:::i;:::-;6088:119;6246:1;6271:72;6335:7;6326:6;6315:9;6311:22;6271:72;:::i;:::-;6261:82;;6217:136;5993:367;;;;:::o;6366:175::-;6506:27;6502:1;6494:6;6490:14;6483:51;6366:175;:::o;6547:366::-;6689:3;6710:67;6774:2;6769:3;6710:67;:::i;:::-;6703:74;;6786:93;6875:3;6786:93;:::i;:::-;6904:2;6899:3;6895:12;6888:19;;6547:366;;;:::o;6919:419::-;7085:4;7123:2;7112:9;7108:18;7100:26;;7172:9;7166:4;7162:20;7158:1;7147:9;7143:17;7136:47;7200:131;7326:4;7200:131;:::i;:::-;7192:139;;6919:419;;;:::o;7344:167::-;7484:19;7480:1;7472:6;7468:14;7461:43;7344:167;:::o;7517:366::-;7659:3;7680:67;7744:2;7739:3;7680:67;:::i;:::-;7673:74;;7756:93;7845:3;7756:93;:::i;:::-;7874:2;7869:3;7865:12;7858:19;;7517:366;;;:::o;7889:419::-;8055:4;8093:2;8082:9;8078:18;8070:26;;8142:9;8136:4;8132:20;8128:1;8117:9;8113:17;8106:47;8170:131;8296:4;8170:131;:::i;:::-;8162:139;;7889:419;;;:::o;8314:180::-;8362:77;8359:1;8352:88;8459:4;8456:1;8449:15;8483:4;8480:1;8473:15;8500:194;8540:4;8560:20;8578:1;8560:20;:::i;:::-;8555:25;;8594:20;8612:1;8594:20;:::i;:::-;8589:25;;8638:1;8635;8631:9;8623:17;;8662:1;8656:4;8653:11;8650:37;;;8667:18;;:::i;:::-;8650:37;8500:194;;;;:::o;8700:309::-;8811:4;8849:2;8838:9;8834:18;8826:26;;8898:9;8892:4;8888:20;8884:1;8873:9;8869:17;8862:47;8926:76;8997:4;8988:6;8926:76;:::i;:::-;8918:84;;8700:309;;;;:::o;9015:149::-;9051:7;9091:66;9084:5;9080:78;9069:89;;9015:149;;;:::o;9170:78::-;9208:7;9237:5;9226:16;;9170:78;;;:::o;9254:153::-;9357:43;9376:23;9393:5;9376:23;:::i;:::-;9357:43;:::i;:::-;9352:3;9345:56;9254:153;;:::o;9413:96::-;9450:7;9479:24;9497:5;9479:24;:::i;:::-;9468:35;;9413:96;;;:::o;9515:94::-;9548:8;9596:5;9592:2;9588:14;9567:35;;9515:94;;;:::o;9615:::-;9654:7;9683:20;9697:5;9683:20;:::i;:::-;9672:31;;9615:94;;;:::o;9715:100::-;9754:7;9783:26;9803:5;9783:26;:::i;:::-;9772:37;;9715:100;;;:::o;9821:157::-;9926:45;9946:24;9964:5;9946:24;:::i;:::-;9926:45;:::i;:::-;9921:3;9914:58;9821:157;;:::o;9984:79::-;10023:7;10052:5;10041:16;;9984:79;;;:::o;10069:157::-;10174:45;10194:24;10212:5;10194:24;:::i;:::-;10174:45;:::i;:::-;10169:3;10162:58;10069:157;;:::o;10232:674::-;10426:3;10441:73;10510:3;10501:6;10441:73;:::i;:::-;10539:1;10534:3;10530:11;10523:18;;10551:75;10622:3;10613:6;10551:75;:::i;:::-;10651:2;10646:3;10642:12;10635:19;;10664:75;10735:3;10726:6;10664:75;:::i;:::-;10764:2;10759:3;10755:12;10748:19;;10777:75;10848:3;10839:6;10777:75;:::i;:::-;10877:2;10872:3;10868:12;10861:19;;10897:3;10890:10;;10232:674;;;;;;;:::o;10912:99::-;10964:6;10998:5;10992:12;10982:22;;10912:99;;;:::o;11017:377::-;11105:3;11133:39;11166:5;11133:39;:::i;:::-;11188:71;11252:6;11247:3;11188:71;:::i;:::-;11181:78;;11268:65;11326:6;11321:3;11314:4;11307:5;11303:16;11268:65;:::i;:::-;11358:29;11380:6;11358:29;:::i;:::-;11353:3;11349:39;11342:46;;11109:285;11017:377;;;;:::o;11400:118::-;11487:24;11505:5;11487:24;:::i;:::-;11482:3;11475:37;11400:118;;:::o;11524:624::-;11713:4;11751:2;11740:9;11736:18;11728:26;;11800:9;11794:4;11790:20;11786:1;11775:9;11771:17;11764:47;11828:78;11901:4;11892:6;11828:78;:::i;:::-;11820:86;;11953:9;11947:4;11943:20;11938:2;11927:9;11923:18;11916:48;11981:78;12054:4;12045:6;11981:78;:::i;:::-;11973:86;;12069:72;12137:2;12126:9;12122:18;12113:6;12069:72;:::i;:::-;11524:624;;;;;;:::o;12154:313::-;12267:4;12305:2;12294:9;12290:18;12282:26;;12354:9;12348:4;12344:20;12340:1;12329:9;12325:17;12318:47;12382:78;12455:4;12446:6;12382:78;:::i;:::-;12374:86;;12154:313;;;;:::o;12473:423::-;12614:4;12652:2;12641:9;12637:18;12629:26;;12701:9;12695:4;12691:20;12687:1;12676:9;12672:17;12665:47;12729:78;12802:4;12793:6;12729:78;:::i;:::-;12721:86;;12817:72;12885:2;12874:9;12870:18;12861:6;12817:72;:::i;:::-;12473:423;;;;;:::o;12902:180::-;12950:77;12947:1;12940:88;13047:4;13044:1;13037:15;13071:4;13068:1;13061:15","linkReferences":{}},"methodIdentifiers":{"IS_SCRIPT()":"f8ccbf47","run()":"c0406226"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\"}],\"name\":\"DeploymentFailed\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IS_SCRIPT\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"run\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"script/deploy.s.sol\":\"Deploy\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[\":@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/\",\":account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/\",\":erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/\",\":erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/\",\":forge-std/=lib/forge-std/src/\",\":halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/\",\":openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/\",\":sequence-v3/=lib/sequence-v3/\",\":signals-implicit-mode/=lib/signals-implicit-mode/\"]},\"sources\":{\"lib/forge-std/src/Base.sol\":{\"keccak256\":\"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d\",\"dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs\"]},\"lib/forge-std/src/Script.sol\":{\"keccak256\":\"0xc942e27c7baae499beb01afbbae99f24d42af9a6e4aae675bc6901b704aa8e9b\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://0456008adf68947247f358b62863af4a8e349549d2260f2ff9569ff0e3cf5c98\",\"dweb:/ipfs/QmdviSUj2i7o3TPN5vd2xocqGMFVqjUzaiJTZRYyPxyHPx\"]},\"lib/forge-std/src/StdChains.sol\":{\"keccak256\":\"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2\",\"dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe\"]},\"lib/forge-std/src/StdCheats.sol\":{\"keccak256\":\"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41\",\"dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK\"]},\"lib/forge-std/src/StdConstants.sol\":{\"keccak256\":\"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc\",\"dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r\"]},\"lib/forge-std/src/StdJson.sol\":{\"keccak256\":\"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974\",\"dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3\"]},\"lib/forge-std/src/StdMath.sol\":{\"keccak256\":\"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92\",\"dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC\"]},\"lib/forge-std/src/StdStorage.sol\":{\"keccak256\":\"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc\",\"dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi\"]},\"lib/forge-std/src/StdStyle.sol\":{\"keccak256\":\"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8\",\"dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK\"]},\"lib/forge-std/src/StdUtils.sol\":{\"keccak256\":\"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a\",\"dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT\"]},\"lib/forge-std/src/Vm.sol\":{\"keccak256\":\"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39\",\"license\":\"MIT OR Apache-2.0\",\"urls\":[\"bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9\",\"dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB\"]},\"lib/forge-std/src/console.sol\":{\"keccak256\":\"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57\",\"dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP\"]},\"lib/forge-std/src/console2.sol\":{\"keccak256\":\"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d\",\"dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ\"]},\"lib/forge-std/src/interfaces/IMulticall3.sol\":{\"keccak256\":\"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0\",\"dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2\"]},\"lib/forge-std/src/safeconsole.sol\":{\"keccak256\":\"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab\",\"dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3\"]},\"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol\":{\"keccak256\":\"0x3fdec03d51d77fcda6d6c681e26e7c8d4b85f1457eac91e0ec15411a7ab1e1f6\",\"license\":\"UNLICENSED\",\"urls\":[\"bzz-raw://a690bf4481a37f3f77acdeecac089462db83f0437307610981b24c04b5202f6e\",\"dweb:/ipfs/QmUA9TSjAkqefNBW8BiRqg8XDJiJxJPxSsZHQwJJAbrYQg\"]},\"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol\":{\"keccak256\":\"0x0a17871e1017f36a664b877f5b0db297dc998fdf8b0ab82d00ca50d5bdde88f7\",\"license\":\"UNLICENSED\",\"urls\":[\"bzz-raw://160bc0d890492792f85dfea939160290d90562b27154f64c39c2a615243518a6\",\"dweb:/ipfs/QmbxmqPpTAH7X45G75UjmLh3RSTDj7trMtmkGU6RXmRyEJ\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol\":{\"keccak256\":\"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638\",\"dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF\"]},\"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol\":{\"keccak256\":\"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a\",\"dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4\"]},\"lib/sequence-v3/src/modules/Payload.sol\":{\"keccak256\":\"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17\",\"dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw\"]},\"lib/sequence-v3/src/utils/LibBytes.sol\":{\"keccak256\":\"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c\",\"dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3\"]},\"script/deploy.s.sol\":{\"keccak256\":\"0x98a1df98ded339567cb5180cf6da767224b46aab3c5322a25bb157c506c30a18\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://1ee75bbe1b28e5a5736efc5142a1102fb5b0b324d44c45733ac01bdff2168f0e\",\"dweb:/ipfs/QmcYTg4n8mxVdNrUPf4xGrCSRq11QRE6gRNSx838DSzrWA\"]},\"src/registry/IImplicitProjectRegistry.sol\":{\"keccak256\":\"0xa14fecf045549da52f725265a9ecf08133fc94c61c626ad87d981e4b91cbf203\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://dd92526b0b0038c628295d0ea279871995b998d4f2d2cab92cdcd3fd8535c543\",\"dweb:/ipfs/QmbNuRU7qFEcHsCmEiR6oFpcLH85vFRLpFNiVbUczYDZkH\"]},\"src/registry/IImplicitProjectValidation.sol\":{\"keccak256\":\"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c\",\"dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6\"]},\"src/registry/ImplicitProjectRegistry.sol\":{\"keccak256\":\"0x178b0f0a8022f9d5bdc434b9b54a55387b760d44b2783cef86756eafb7911617\",\"license\":\"Apache-2.0\",\"urls\":[\"bzz-raw://b9720240bade0c56c477f6df7993f6a8f9c6946e1e62d8d9198c2cf2aa2c2a24\",\"dweb:/ipfs/QmXCZmcb4GiUytzy3uPgXwmPYf8VcVy3YmcmgVMwKnncdt\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"string","name":"reason","type":"string"}],"type":"error","name":"DeploymentFailed"},{"inputs":[],"stateMutability":"view","type":"function","name":"IS_SCRIPT","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[],"stateMutability":"nonpayable","type":"function","name":"run"}],"devdoc":{"kind":"dev","methods":{},"version":1},"userdoc":{"kind":"user","methods":{},"version":1}},"settings":{"remappings":["@openzeppelin/contracts/=lib/sequence-v3/lib/openzeppelin-contracts/contracts/","account-abstraction/=lib/sequence-v3/lib/account-abstraction/contracts/","erc2470-libs/=lib/sequence-v3/lib/erc2470-libs/","erc4626-tests/=lib/sequence-v3/lib/openzeppelin-contracts/lib/erc4626-tests/","forge-std/=lib/forge-std/src/","halmos-cheatcodes/=lib/sequence-v3/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/","openzeppelin-contracts/=lib/sequence-v3/lib/openzeppelin-contracts/","sequence-v3/=lib/sequence-v3/","signals-implicit-mode/=lib/signals-implicit-mode/"],"optimizer":{"enabled":false,"runs":200},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"script/deploy.s.sol":"Deploy"},"evmVersion":"paris","libraries":{}},"sources":{"lib/forge-std/src/Base.sol":{"keccak256":"0x4b2a5a85e045dcf6a082700c7252e43854c2eed88f860aaa18ec1e85218ae2bf","urls":["bzz-raw://98d060ed5be569a92d908fc358149039dc8f833d61973aa1b9d1d8235676bf6d","dweb:/ipfs/QmaWQpn5dJmbMS5skwmPPMeUWZG35BLkignPpcA3zyagEs"],"license":"MIT"},"lib/forge-std/src/Script.sol":{"keccak256":"0xc942e27c7baae499beb01afbbae99f24d42af9a6e4aae675bc6901b704aa8e9b","urls":["bzz-raw://0456008adf68947247f358b62863af4a8e349549d2260f2ff9569ff0e3cf5c98","dweb:/ipfs/QmdviSUj2i7o3TPN5vd2xocqGMFVqjUzaiJTZRYyPxyHPx"],"license":"MIT"},"lib/forge-std/src/StdChains.sol":{"keccak256":"0xae394f477769a38276d98d4854bc865fc8d281edbd4e72167507adb8236812aa","urls":["bzz-raw://34a0e609a4ec617b5c349f5e89a3352810cc5e4d3adaf939b32a27e4a5e46de2","dweb:/ipfs/QmPfjimWAGGb6rzDjNMtLeZ93JJbCJJMov5gaNKyTy1doe"],"license":"MIT"},"lib/forge-std/src/StdCheats.sol":{"keccak256":"0x0fa6ec03602648b62cce41aab2096e6b7e052f2846075d967b6958dd586db746","urls":["bzz-raw://cd84e2ca9c1eaed6b76768cc12bb8c1af8289170ea8b7706f58d516460d79c41","dweb:/ipfs/QmQ7BK7co6DE4eWUqMyv11s5eHYkS1tyx8tDSZGZVtf2aK"],"license":"MIT"},"lib/forge-std/src/StdConstants.sol":{"keccak256":"0x319ccdabfa2c0b2428301445873270ffea20f0e039d4fd5e6eeba65158e4e534","urls":["bzz-raw://b633f9d3a719e1d035ce7daa6cc051ddf89a72d34200d14cec37728e245cdabc","dweb:/ipfs/QmRP7HQJpHMx1CsFrY8tXVVx1DQmi2dcb2BoGfiWaA923r"],"license":"MIT"},"lib/forge-std/src/StdJson.sol":{"keccak256":"0xbc0132abe1c2accc2867c0f03667afffdf92f3e95a581bb03c9557eaa38ea500","urls":["bzz-raw://eb6fab37dc73c219cfbb7b4f4998bcf7677ca5397a867e850f40232192073974","dweb:/ipfs/QmUHsbVdp9SKmgek7ZfPcLTKrpZFXpqaqt4sVejzxGEQL3"],"license":"MIT"},"lib/forge-std/src/StdMath.sol":{"keccak256":"0xd90ad4fd8aeaeb8929964e686e769fdedd5eded3fc3815df194a0ab9f91a3fb2","urls":["bzz-raw://7919b70f636c7b805223992f28ad1ad0145d6c1385b5931a3589aface5fe6c92","dweb:/ipfs/QmY7FRaULwoGgFteF8GawjQJRfasNgpWnU2aiMsFrYpuTC"],"license":"MIT"},"lib/forge-std/src/StdStorage.sol":{"keccak256":"0x04102de0a79398e4bdea57b7a4818655b4cc66d6f81d1cff08bf428cd0b384cd","urls":["bzz-raw://53edc6c8f7f67cafc0129f039637c77d979880f7f1947defea31e8f0c05095bc","dweb:/ipfs/QmUKXJd1vFCkxxrkXNLURdXrx2apoyWQFrFb5UqNkjdHVi"],"license":"MIT"},"lib/forge-std/src/StdStyle.sol":{"keccak256":"0x43e2a8a9b9c2574dabe74f11adf6f782df218f463540e3b5b563609fe108597d","urls":["bzz-raw://51363ca97404cf4128e1141428949768c31929e75e014b02c85e887fbbb4f1b8","dweb:/ipfs/QmVhtbQc2fU4rRmbcfBtz34mAgG4BAZBsbna1Ca4SkoPsK"],"license":"MIT"},"lib/forge-std/src/StdUtils.sol":{"keccak256":"0xb2469a902a326074034c4f7081d868113db0edbb7cf48b86528af2d6b07295f8","urls":["bzz-raw://1430a81c4978be875e2a3b31a8bfa4e1438fecd327f23771b690d64db63c020a","dweb:/ipfs/QmW6aB2u1LNaRgGQFwjV7L7UbxsRg63iJ7AuujPouEa4cT"],"license":"MIT"},"lib/forge-std/src/Vm.sol":{"keccak256":"0x6f235e293b4406784ff3bd89b2e4d51d0922918cf6825e7a7a09413606932e39","urls":["bzz-raw://afc4fceb24a18596a239e82eb354c41d9a4e28d3fc56fcce04146af2c692b1b9","dweb:/ipfs/QmQCHSAb5k9KQW9kEzeoPdirSknkWso4q4t5CSVFLNnMLB"],"license":"MIT OR Apache-2.0"},"lib/forge-std/src/console.sol":{"keccak256":"0x4bbf47eb762cef93729d6ef15e78789957147039b113e5d4df48e3d3fd16d0f5","urls":["bzz-raw://af9e3a7c3d82fb5b10b57ca4d1a82f2acbef80c077f6f6ef0cc0187c7bfd9f57","dweb:/ipfs/QmR9VzmnBDJpgiDP6CHT6truehukF9HpYvuP6kRiJbDwPP"],"license":"MIT"},"lib/forge-std/src/console2.sol":{"keccak256":"0x3b8fe79f48f065a4e4d35362171304a33784c3a90febae5f2787805a438de12f","urls":["bzz-raw://61de63af08803549299e68b6e6e88d40f3c5afac450e4ee0a228c66a61ba003d","dweb:/ipfs/QmWVoQ5rrVxnczD4ZZoPbD4PC9Z3uExJtzjD4awTqd14MZ"],"license":"MIT"},"lib/forge-std/src/interfaces/IMulticall3.sol":{"keccak256":"0x7aac1389150499a922d1f9ef5749c908cef127cb2075b92fa17e9cb611263d0a","urls":["bzz-raw://d95ebb7c7c463e08ebc12dab639945752fb2480acfc6e86da32f72732a7fd0c0","dweb:/ipfs/QmNXK8P8oPWwajsQHvAHw3JPyQidPLCGQN3hWu1Lk6PBL2"],"license":"MIT"},"lib/forge-std/src/safeconsole.sol":{"keccak256":"0xbef9786cb49d3eade757bad87568c49c8c8f35721f0193c95ffb055d9e466e11","urls":["bzz-raw://3bafd2b0b2d28068d329f95ea8a1fbce3719c257fcb863fc01abcbafd8d531ab","dweb:/ipfs/QmUeaFjKWTVDBsHVfSob4mwt6A5hTnKDz22HaUXeZhypa3"],"license":"MIT"},"lib/sequence-v3/lib/erc2470-libs/script/SingletonDeployer.s.sol":{"keccak256":"0x3fdec03d51d77fcda6d6c681e26e7c8d4b85f1457eac91e0ec15411a7ab1e1f6","urls":["bzz-raw://a690bf4481a37f3f77acdeecac089462db83f0437307610981b24c04b5202f6e","dweb:/ipfs/QmUA9TSjAkqefNBW8BiRqg8XDJiJxJPxSsZHQwJJAbrYQg"],"license":"UNLICENSED"},"lib/sequence-v3/lib/erc2470-libs/src/ISingletonFactory.sol":{"keccak256":"0x0a17871e1017f36a664b877f5b0db297dc998fdf8b0ab82d00ca50d5bdde88f7","urls":["bzz-raw://160bc0d890492792f85dfea939160290d90562b27154f64c39c2a615243518a6","dweb:/ipfs/QmbxmqPpTAH7X45G75UjmLh3RSTDj7trMtmkGU6RXmRyEJ"],"license":"UNLICENSED"},"lib/sequence-v3/src/extensions/sessions/implicit/Attestation.sol":{"keccak256":"0xcaa44022b5eb4bc7ab487b3b1a0125da67e2e891cee983ef6cdb6814f045efc8","urls":["bzz-raw://94829782b6dcb482d7c002511c590d1ad8de3b21e5e72575df18be73565b3638","dweb:/ipfs/QmZ4u9FxALzMzKR7auW8FmFkhGVw8kRDeDRJ1PKwKaWNWF"],"license":"Apache-2.0"},"lib/sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol":{"keccak256":"0x6cb48f50c49bcb3c7071306fe9fac6c102bc9eabf73d9909e19ab3b9a835d0a8","urls":["bzz-raw://15297e969f64fc1152654d1cefbe276c15a0ecfc11f86b4c276bb0b454fe700a","dweb:/ipfs/QmeehNFYBPPtJePwUcqiYCgiuFotur4VVVCV1KvegdCCZ4"],"license":"Apache-2.0"},"lib/sequence-v3/src/modules/Payload.sol":{"keccak256":"0x03b3dc2a4a556d3007671e910813dc4703ecb16f5bc2c6645e4c0d8512f2d76a","urls":["bzz-raw://9b41263156d5a310a48038e8c3871e9acdb806c018bc952d1a56efed62954e17","dweb:/ipfs/QmaiuTbQgaiCvtN2V6roe4RTi6hHV85mNZpWKqvKA8ofqw"],"license":"Apache-2.0"},"lib/sequence-v3/src/utils/LibBytes.sol":{"keccak256":"0x4fe0b4786b2157e12384b90ae9daa1009b74b2547a8a24b800a8b998278c874b","urls":["bzz-raw://065129e32d1a318e89fb7587e136c33177a7848393f9055c0ac601b84741cd8c","dweb:/ipfs/QmVWucfHSHRJriRFNoJqoeDcVB4fDfqbccM8KPBmwcxVu3"],"license":"Apache-2.0"},"script/deploy.s.sol":{"keccak256":"0x98a1df98ded339567cb5180cf6da767224b46aab3c5322a25bb157c506c30a18","urls":["bzz-raw://1ee75bbe1b28e5a5736efc5142a1102fb5b0b324d44c45733ac01bdff2168f0e","dweb:/ipfs/QmcYTg4n8mxVdNrUPf4xGrCSRq11QRE6gRNSx838DSzrWA"],"license":"Apache-2.0"},"src/registry/IImplicitProjectRegistry.sol":{"keccak256":"0xa14fecf045549da52f725265a9ecf08133fc94c61c626ad87d981e4b91cbf203","urls":["bzz-raw://dd92526b0b0038c628295d0ea279871995b998d4f2d2cab92cdcd3fd8535c543","dweb:/ipfs/QmbNuRU7qFEcHsCmEiR6oFpcLH85vFRLpFNiVbUczYDZkH"],"license":"Apache-2.0"},"src/registry/IImplicitProjectValidation.sol":{"keccak256":"0x1e8c305e011aa13d774e0ff3cfd9286af3d8174c4e33ba5ef8f724ea2dd6e5b2","urls":["bzz-raw://057ad8894656688eefb257c02696f37281d3e7610cd3c3db8f1c3954fba9ea9c","dweb:/ipfs/QmbdeFH1XxLyWqdTEmRkGNiebMVAxuREtuLpZXRErCyYM6"],"license":"Apache-2.0"},"src/registry/ImplicitProjectRegistry.sol":{"keccak256":"0x178b0f0a8022f9d5bdc434b9b54a55387b760d44b2783cef86756eafb7911617","urls":["bzz-raw://b9720240bade0c56c477f6df7993f6a8f9c6946e1e62d8d9198c2cf2aa2c2a24","dweb:/ipfs/QmXCZmcb4GiUytzy3uPgXwmPYf8VcVy3YmcmgVMwKnncdt"],"license":"Apache-2.0"}},"version":1},"id":21} \ No newline at end of file diff --git a/lib/signals-implicit-mode/remappings.txt b/lib/signals-implicit-mode/remappings.txt deleted file mode 100644 index f2b981474a..0000000000 --- a/lib/signals-implicit-mode/remappings.txt +++ /dev/null @@ -1 +0,0 @@ -forge-std-1.14.0/=dependencies/forge-std-1.14.0/ diff --git a/lib/signals-implicit-mode/script/Deploy.s.sol b/lib/signals-implicit-mode/script/Deploy.s.sol deleted file mode 100644 index 2505cb9a16..0000000000 --- a/lib/signals-implicit-mode/script/Deploy.s.sol +++ /dev/null @@ -1,18 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.27; - -import { SingletonDeployer, console } from "erc2470-libs/script/SingletonDeployer.s.sol"; -import { ImplicitProjectRegistry } from "src/registry/ImplicitProjectRegistry.sol"; - -contract Deploy is SingletonDeployer { - - function run() external { - uint256 pk = vm.envUint("PRIVATE_KEY"); - - bytes32 salt = bytes32(0); - - bytes memory initCode = abi.encodePacked(type(ImplicitProjectRegistry).creationCode); - _deployIfNotAlready("ImplicitProjectRegistry", initCode, salt, pk); - } - -} diff --git a/lib/signals-implicit-mode/soldeer.lock b/lib/signals-implicit-mode/soldeer.lock deleted file mode 100644 index 907ff2fd5d..0000000000 --- a/lib/signals-implicit-mode/soldeer.lock +++ /dev/null @@ -1,6 +0,0 @@ -[[dependencies]] -name = "forge-std" -version = "1.14.0" -url = "https://soldeer-revisions.s3.amazonaws.com/forge-std/1_14_0_05-01-2026_15:24:39_forge-std-1.14.zip" -checksum = "d10079d1b7aac1a36dd2eeb4c5d042e8ed27b00f4ef89530b7f0a6ecd18cada3" -integrity = "64133846def1b04b1726d2bf1292c19050a0e8cb832b60c6104c19595b9699f8" diff --git a/lib/signals-implicit-mode/src/helper/SignalsImplicitMode.sol b/lib/signals-implicit-mode/src/helper/SignalsImplicitMode.sol deleted file mode 100644 index 7679bc1e73..0000000000 --- a/lib/signals-implicit-mode/src/helper/SignalsImplicitMode.sol +++ /dev/null @@ -1,58 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.13; - -import { IImplicitProjectValidation } from "../registry/IImplicitProjectValidation.sol"; - -import { ERC165, IERC165 } from "openzeppelin-contracts/contracts/utils/introspection/ERC165.sol"; -import { Attestation } from "sequence-v3/src/extensions/sessions/implicit/Attestation.sol"; -import { ISignalsImplicitMode } from "sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol"; -import { Payload } from "sequence-v3/src/modules/Payload.sol"; - -/// @title SignalsImplicitMode -/// @author Michael Standen -/// @notice Base contract for implicit mode validation by project -abstract contract SignalsImplicitMode is ISignalsImplicitMode, ERC165 { - - IImplicitProjectValidation internal _validator; - bytes32 internal _projectId; - - /// @notice Initialize implicit mode validation - /// @param validator The IImplicitProjectValidation address - /// @param projectId The project id - function _initializeSignalsImplicitMode( - address validator, - bytes32 projectId - ) internal { - _validator = IImplicitProjectValidation(validator); - _projectId = projectId; - } - - /// @inheritdoc ISignalsImplicitMode - function acceptImplicitRequest( - address wallet, - Attestation calldata attestation, - Payload.Call calldata call - ) external view returns (bytes32) { - _validateImplicitRequest(wallet, attestation, call); - return _validator.validateAttestation(wallet, attestation, _projectId); - } - - /// @notice Validates an implicit request - /// @dev Optional hook for additional validation of the implicit requests - /// @param wallet The wallet's address - /// @param attestation The attestation data - /// @param call The call to validate - function _validateImplicitRequest( - address wallet, - Attestation calldata attestation, - Payload.Call calldata call - ) internal view virtual { } - - /// @inheritdoc IERC165 - function supportsInterface( - bytes4 interfaceId - ) public view virtual override returns (bool) { - return interfaceId == type(ISignalsImplicitMode).interfaceId || super.supportsInterface(interfaceId); - } - -} diff --git a/lib/signals-implicit-mode/src/registry/IImplicitProjectRegistry.sol b/lib/signals-implicit-mode/src/registry/IImplicitProjectRegistry.sol deleted file mode 100644 index bc96fb9b37..0000000000 --- a/lib/signals-implicit-mode/src/registry/IImplicitProjectRegistry.sol +++ /dev/null @@ -1,79 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.13; - -import { IImplicitProjectValidation } from "./IImplicitProjectValidation.sol"; - -/// @title IImplicitProjectRegistry -/// @author Michael Standen -/// @notice Interface for the registry of projects supporting implicit sessions -interface IImplicitProjectRegistry is IImplicitProjectValidation { - - /// @notice Claim a project - /// @param projectIdUpper The project id upper - /// @return projectId The concatenation of the `projectIdUpper` and the `msg.sender` - function claimProject( - bytes12 projectIdUpper - ) external returns (bytes32 projectId); - - /// @notice Transfer a project - /// @param projectId The project id - /// @param newOwner The new owner - function transferProject( - bytes32 projectId, - address newOwner - ) external; - - /// @notice Add a project URL - /// @param projectId The project id - /// @param projectUrl The project URL - function addProjectUrl( - bytes32 projectId, - string memory projectUrl - ) external; - - /// @notice Remove a project URL - /// @param projectId The project id - /// @param projectUrl The project URL - function removeProjectUrl( - bytes32 projectId, - string memory projectUrl - ) external; - - /// @notice List project URLs - /// @param projectId The project id - /// @return projectUrls The project URLs - function listProjectUrls( - bytes32 projectId - ) external view returns (bytes32[] memory); - - /// @notice Not project owner error - error NotProjectOwner(); - - /// @notice Project already claimed error - error ProjectAlreadyClaimed(); - - /// @notice Invalid project owner error - error InvalidProjectOwner(); - - /// @notice Project URL not found error - error ProjectUrlNotFound(); - - /// @notice Project URL already exists error - error ProjectUrlAlreadyExists(); - - /// @notice Invalid project URL index error - error InvalidProjectUrlIndex(); - - /// @notice Emitted when a project is claimed - event ProjectClaimed(bytes32 indexed projectId, address indexed owner); - - /// @notice Emitted when a project owner is transferred - event ProjectOwnerTransferred(bytes32 indexed projectId, address indexed newOwner); - - /// @notice Emitted when a project URL is added - event ProjectUrlAdded(bytes32 indexed projectId, bytes32 indexed urlHash); - - /// @notice Emitted when a project URL is removed - event ProjectUrlRemoved(bytes32 indexed projectId, bytes32 indexed urlHash); - -} diff --git a/lib/signals-implicit-mode/src/registry/IImplicitProjectValidation.sol b/lib/signals-implicit-mode/src/registry/IImplicitProjectValidation.sol deleted file mode 100644 index b68c4a61ef..0000000000 --- a/lib/signals-implicit-mode/src/registry/IImplicitProjectValidation.sol +++ /dev/null @@ -1,25 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.13; - -import { Attestation } from "sequence-v3/src/extensions/sessions/implicit/Attestation.sol"; - -/// @title IImplicitProjectValidation -/// @author Michael Standen -/// @notice Interface for contracts supporting validation of implicit sessions for projects -interface IImplicitProjectValidation { - - /// @notice Invalid redirect url error - error InvalidRedirectUrl(); - - /// @notice Check if a project has a code - /// @param wallet The wallet address - /// @param attestation The attestation - /// @param projectId The project id - /// @return magic The attestation magic bytes for the wallet address - function validateAttestation( - address wallet, - Attestation calldata attestation, - bytes32 projectId - ) external view returns (bytes32); - -} diff --git a/lib/signals-implicit-mode/src/registry/ImplicitProjectRegistry.sol b/lib/signals-implicit-mode/src/registry/ImplicitProjectRegistry.sol deleted file mode 100644 index 2297ab652b..0000000000 --- a/lib/signals-implicit-mode/src/registry/ImplicitProjectRegistry.sol +++ /dev/null @@ -1,211 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.13; - -import { IImplicitProjectRegistry } from "./IImplicitProjectRegistry.sol"; -import { IImplicitProjectValidation } from "./IImplicitProjectValidation.sol"; - -import { Attestation, LibAttestation } from "sequence-v3/src/extensions/sessions/implicit/Attestation.sol"; - -/// @title ImplicitProjectRegistry -/// @author Michael Standen -/// @notice Registry of projects supporting implicit sessions -contract ImplicitProjectRegistry is IImplicitProjectRegistry { - - using LibAttestation for Attestation; - - /// @notice Project owner - mapping(bytes32 => address) public projectOwner; - - /// @notice Project URLs - mapping(bytes32 => mapping(bytes32 => bool)) public isProjectUrl; - mapping(bytes32 => bytes32[]) public projectUrlsList; - - modifier onlyProjectOwner( - bytes32 projectId - ) { - if (projectOwner[projectId] != msg.sender) { - revert IImplicitProjectRegistry.NotProjectOwner(); - } - _; - } - - /// @inheritdoc IImplicitProjectRegistry - function claimProject( - bytes12 projectIdUpper - ) public returns (bytes32 projectId) { - address owner = msg.sender; - if (owner == address(0)) { - revert IImplicitProjectRegistry.InvalidProjectOwner(); - } - projectId = bytes32(abi.encodePacked(projectIdUpper, owner)); - if (projectOwner[projectId] != address(0)) { - revert IImplicitProjectRegistry.ProjectAlreadyClaimed(); - } - projectOwner[projectId] = owner; - emit IImplicitProjectRegistry.ProjectClaimed(projectId, owner); - - return projectId; - } - - /// @inheritdoc IImplicitProjectRegistry - function transferProject( - bytes32 projectId, - address newOwner - ) public onlyProjectOwner(projectId) { - if (newOwner == address(0)) { - revert IImplicitProjectRegistry.InvalidProjectOwner(); - } - projectOwner[projectId] = newOwner; - emit IImplicitProjectRegistry.ProjectOwnerTransferred(projectId, newOwner); - } - - function _addProjectUrlHash( - bytes32 projectId, - bytes32 projectUrlHash - ) internal { - if (isProjectUrl[projectId][projectUrlHash]) { - revert IImplicitProjectRegistry.ProjectUrlAlreadyExists(); - } - isProjectUrl[projectId][projectUrlHash] = true; - projectUrlsList[projectId].push(projectUrlHash); - emit IImplicitProjectRegistry.ProjectUrlAdded(projectId, projectUrlHash); - } - - /// @notice Add a project URL hash - /// @param projectId The project id - /// @param projectUrlHash The project URL hash - function addProjectUrlHash( - bytes32 projectId, - bytes32 projectUrlHash - ) external onlyProjectOwner(projectId) { - _addProjectUrlHash(projectId, projectUrlHash); - } - - /// @notice Add a list of project URL hashes - /// @param projectId The project id - /// @param projectUrlHashes The project URL hashes - function addProjectUrlHashBatch( - bytes32 projectId, - bytes32[] memory projectUrlHashes - ) external onlyProjectOwner(projectId) { - for (uint256 i; i < projectUrlHashes.length; i++) { - _addProjectUrlHash(projectId, projectUrlHashes[i]); - } - } - - /// @inheritdoc IImplicitProjectRegistry - function addProjectUrl( - bytes32 projectId, - string memory projectUrl - ) public onlyProjectOwner(projectId) { - _addProjectUrlHash(projectId, _hashUrl(projectUrl)); - } - - /// @notice Add a list of project URLs - /// @param projectId The project id - /// @param projectUrls The project URLs - function addProjectUrlBatch( - bytes32 projectId, - string[] memory projectUrls - ) external onlyProjectOwner(projectId) { - for (uint256 i; i < projectUrls.length; i++) { - _addProjectUrlHash(projectId, _hashUrl(projectUrls[i])); - } - } - - function _removeProjectUrlHash( - bytes32 projectId, - bytes32 projectUrlHash, - uint256 urlIdx - ) internal { - if (urlIdx >= projectUrlsList[projectId].length || projectUrlsList[projectId][urlIdx] != projectUrlHash) { - revert IImplicitProjectRegistry.InvalidProjectUrlIndex(); - } - isProjectUrl[projectId][projectUrlHash] = false; - projectUrlsList[projectId][urlIdx] = projectUrlsList[projectId][projectUrlsList[projectId].length - 1]; - projectUrlsList[projectId].pop(); - emit IImplicitProjectRegistry.ProjectUrlRemoved(projectId, projectUrlHash); - } - - /// @notice Remove a project URL hash - /// @param projectId The project id - /// @param projectUrlHash The project URL hash - /// @param urlIdx The index of the project URL hash to remove - function removeProjectUrlHash( - bytes32 projectId, - bytes32 projectUrlHash, - uint256 urlIdx - ) external onlyProjectOwner(projectId) { - _removeProjectUrlHash(projectId, projectUrlHash, urlIdx); - } - - /// @notice Remove a list of project URL hashes - /// @param projectId The project id - /// @param projectUrlHashes The project URL hashes - /// @param urlIdxs The indexes of the project URL hashes to remove - /// @dev The urlIdxs must be sorted in descending order - function removeProjectUrlHashBatch( - bytes32 projectId, - bytes32[] memory projectUrlHashes, - uint256[] memory urlIdxs - ) external onlyProjectOwner(projectId) { - if (projectUrlHashes.length != urlIdxs.length) { - revert IImplicitProjectRegistry.InvalidProjectUrlIndex(); - } - // Ensure the urlIdxs are sorted descending to prevent issues with reordering during removals - for (uint256 i; i < urlIdxs.length - 1; i++) { - if (urlIdxs[i] < urlIdxs[i + 1]) { - revert IImplicitProjectRegistry.InvalidProjectUrlIndex(); - } - } - for (uint256 i; i < projectUrlHashes.length; i++) { - _removeProjectUrlHash(projectId, projectUrlHashes[i], urlIdxs[i]); - } - } - - /// @inheritdoc IImplicitProjectRegistry - /// @dev This function is not optimized. Prefer to use removeProjectUrlHash. - function removeProjectUrl( - bytes32 projectId, - string memory projectUrl - ) external onlyProjectOwner(projectId) { - // Find the index of the project URL hash - bytes32 projectUrlHash = _hashUrl(projectUrl); - for (uint256 i; i < projectUrlsList[projectId].length; i++) { - if (projectUrlsList[projectId][i] == projectUrlHash) { - _removeProjectUrlHash(projectId, projectUrlHash, i); - return; - } - } - revert IImplicitProjectRegistry.ProjectUrlNotFound(); - } - - /// @inheritdoc IImplicitProjectRegistry - function listProjectUrls( - bytes32 projectId - ) external view returns (bytes32[] memory) { - return projectUrlsList[projectId]; - } - - /// @inheritdoc IImplicitProjectValidation - function validateAttestation( - address wallet, - Attestation calldata attestation, - bytes32 projectId - ) external view returns (bytes32) { - bytes32 hashedUrl = _hashUrl(attestation.authData.redirectUrl); - - if (isProjectUrl[projectId][hashedUrl]) { - return attestation.generateImplicitRequestMagic(wallet); - } - - revert IImplicitProjectValidation.InvalidRedirectUrl(); - } - - function _hashUrl( - string memory url - ) internal pure returns (bytes32) { - return keccak256(abi.encodePacked(url)); - } - -} diff --git a/lib/signals-implicit-mode/test/ImplicitProjectRegistry.t.sol b/lib/signals-implicit-mode/test/ImplicitProjectRegistry.t.sol deleted file mode 100644 index 2a7be43729..0000000000 --- a/lib/signals-implicit-mode/test/ImplicitProjectRegistry.t.sol +++ /dev/null @@ -1,774 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.13; - -import { TestHelper } from "./TestHelper.sol"; -import { SignalsImplicitModeMock } from "./mock/SignalsImplicitModeMock.sol"; -import { Test, console } from "forge-std/Test.sol"; - -import { IImplicitProjectRegistry } from "../src/registry/IImplicitProjectRegistry.sol"; -import { IImplicitProjectValidation } from "../src/registry/IImplicitProjectValidation.sol"; -import { ImplicitProjectRegistry } from "../src/registry/ImplicitProjectRegistry.sol"; - -import { Attestation, LibAttestation } from "sequence-v3/src/extensions/sessions/implicit/Attestation.sol"; - -contract ImplicitProjectRegistryTest is Test, TestHelper { - - using LibAttestation for Attestation; - - ImplicitProjectRegistry public registry; - - function setUp() public { - registry = new ImplicitProjectRegistry(); - } - - // Positive Tests - - function test_claimProject( - address owner, - bytes12 projectIdUpper - ) public { - vm.assume(owner != address(0)); - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.expectEmit(); - emit IImplicitProjectRegistry.ProjectClaimed(projectId, owner); - - vm.prank(owner); - bytes32 claimedProjectId = registry.claimProject(projectIdUpper); - - assertEq(claimedProjectId, projectId); - assertEq(registry.projectOwner(projectId), owner); - } - - function test_transferProject( - address owner, - address newOwner, - bytes12 projectIdUpper, - bytes32 urlHash - ) public { - vm.assume(owner != address(0)); - vm.assume(newOwner != address(0)); - vm.assume(owner != newOwner); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - vm.expectEmit(); - emit IImplicitProjectRegistry.ProjectOwnerTransferred(projectId, newOwner); - - vm.prank(owner); - registry.transferProject(projectId, newOwner); - - assertEq(registry.projectOwner(projectId), newOwner); - - // Check functions now work with the new owner - vm.prank(newOwner); - registry.addProjectUrlHash(projectId, urlHash); - assertEq(registry.listProjectUrls(projectId).length, 1); - } - - function test_addProjectUrl( - address owner, - bytes12 projectIdUpper, - string memory url - ) public { - vm.assume(owner != address(0)); - vm.assume(bytes(url).length > 0); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - vm.expectEmit(); - emit IImplicitProjectRegistry.ProjectUrlAdded(projectId, _hashUrl(url)); - - vm.prank(owner); - registry.addProjectUrl(projectId, url); - - bytes32[] memory urls = registry.listProjectUrls(projectId); - urls = _deduplicateBytes32Array(urls); - assertEq(urls[0], _hashUrl(url)); - } - - function test_addProjectUrlBatch( - address owner, - bytes12 projectIdUpper, - string[] memory urls - ) public { - vm.assume(owner != address(0)); - vm.assume(urls.length > 0); - // Max 10 urls - if (urls.length > 10) { - assembly { - mstore(urls, 10) - } - } - urls = _deduplicateStringArray(urls); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.startPrank(owner); - registry.claimProject(projectIdUpper); - - for (uint256 i; i < urls.length; i++) { - vm.expectEmit(); - emit IImplicitProjectRegistry.ProjectUrlAdded(projectId, _hashUrl(urls[i])); - } - - registry.addProjectUrlBatch(projectId, urls); - vm.stopPrank(); - - bytes32[] memory actualUrls = registry.listProjectUrls(projectId); - assertEq(actualUrls.length, urls.length); - for (uint256 i; i < actualUrls.length; i++) { - assertEq(actualUrls[i], _hashUrl(urls[i])); - } - } - - function test_addProjectUrlHash( - address owner, - bytes12 projectIdUpper, - bytes32 urlHash - ) public { - vm.assume(owner != address(0)); - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - vm.expectEmit(); - emit IImplicitProjectRegistry.ProjectUrlAdded(projectId, urlHash); - - vm.prank(owner); - registry.addProjectUrlHash(projectId, urlHash); - - bytes32[] memory urls = registry.listProjectUrls(projectId); - assertEq(urls[0], urlHash); - } - - function test_addProjectUrlHashBatch( - address owner, - bytes12 projectIdUpper, - bytes32[] memory urlHashes - ) public { - vm.assume(owner != address(0)); - vm.assume(urlHashes.length > 0); - // Max 10 urls - if (urlHashes.length > 10) { - assembly { - mstore(urlHashes, 10) - } - } - urlHashes = _deduplicateBytes32Array(urlHashes); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.startPrank(owner); - registry.claimProject(projectIdUpper); - - for (uint256 i; i < urlHashes.length; i++) { - vm.expectEmit(); - emit IImplicitProjectRegistry.ProjectUrlAdded(projectId, urlHashes[i]); - } - - registry.addProjectUrlHashBatch(projectId, urlHashes); - vm.stopPrank(); - - bytes32[] memory urls = registry.listProjectUrls(projectId); - assertEq(urls.length, urlHashes.length); - for (uint256 i; i < urls.length; i++) { - assertEq(urls[i], urlHashes[i]); - } - } - - function test_removeProjectUrl( - address owner, - bytes12 projectIdUpper, - string[] memory urls, - uint256 urlIdx - ) public { - vm.assume(owner != address(0)); - vm.assume(urls.length > 0); - // Max 10 urls - if (urls.length > 10) { - assembly { - mstore(urls, 10) - } - } - urls = _deduplicateStringArray(urls); - urlIdx = bound(urlIdx, 0, urls.length - 1); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.startPrank(owner); - registry.claimProject(projectIdUpper); - for (uint256 i; i < urls.length; i++) { - registry.addProjectUrl(projectId, urls[i]); - } - - bytes32 urlHash = _hashUrl(urls[urlIdx]); - vm.expectEmit(); - emit IImplicitProjectRegistry.ProjectUrlRemoved(projectId, urlHash); - - registry.removeProjectUrl(projectId, urls[urlIdx]); - vm.stopPrank(); - - bytes32[] memory actualUrls = registry.listProjectUrls(projectId); - assertEq(actualUrls.length, urls.length - 1); - for (uint256 i; i < actualUrls.length; i++) { - assertNotEq(actualUrls[i], urlHash); - } - } - - function test_removeProjectUrlHash( - address owner, - bytes12 projectIdUpper, - bytes32[] memory urlHashes, - uint256 urlHashIdx - ) public { - vm.assume(owner != address(0)); - vm.assume(urlHashes.length > 0); - // Max 10 urls - if (urlHashes.length > 10) { - assembly { - mstore(urlHashes, 10) - } - } - urlHashes = _deduplicateBytes32Array(urlHashes); - urlHashIdx = bound(urlHashIdx, 0, urlHashes.length - 1); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.startPrank(owner); - registry.claimProject(projectIdUpper); - for (uint256 i; i < urlHashes.length; i++) { - registry.addProjectUrlHash(projectId, urlHashes[i]); - } - - vm.expectEmit(); - emit IImplicitProjectRegistry.ProjectUrlRemoved(projectId, urlHashes[urlHashIdx]); - - registry.removeProjectUrlHash(projectId, urlHashes[urlHashIdx], urlHashIdx); - vm.stopPrank(); - - bytes32[] memory urls = registry.listProjectUrls(projectId); - assertEq(urls.length, urlHashes.length - 1); - for (uint256 i; i < urls.length; i++) { - assertNotEq(urls[i], urlHashes[urlHashIdx]); - } - } - - function test_removeProjectUrlHashBatch( - address owner, - bytes12 projectIdUpper, - bytes32[] memory urlHashes - ) public { - vm.assume(owner != address(0)); - vm.assume(urlHashes.length > 0); - // Max 10 urls - if (urlHashes.length > 10) { - assembly { - mstore(urlHashes, 10) - } - } - urlHashes = _deduplicateBytes32Array(urlHashes); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.startPrank(owner); - registry.claimProject(projectIdUpper); - registry.addProjectUrlHashBatch(projectId, urlHashes); - - // Reverse the urlHashes list - bytes32[] memory reversedUrlHashes = new bytes32[](urlHashes.length); - for (uint256 i; i < urlHashes.length; i++) { - reversedUrlHashes[i] = urlHashes[urlHashes.length - i - 1]; - } - - uint256[] memory urlIdxs = new uint256[](urlHashes.length); - for (uint256 i; i < urlHashes.length; i++) { - urlIdxs[i] = urlHashes.length - i - 1; - } - - for (uint256 i; i < urlHashes.length; i++) { - vm.expectEmit(); - emit IImplicitProjectRegistry.ProjectUrlRemoved(projectId, reversedUrlHashes[i]); - } - registry.removeProjectUrlHashBatch(projectId, reversedUrlHashes, urlIdxs); - vm.stopPrank(); - - bytes32[] memory urls = registry.listProjectUrls(projectId); - assertEq(urls.length, 0); - } - - function test_removeProjectUrlHashBatchWithInvalidUrlIdxs( - address owner, - bytes12 projectIdUpper, - bytes32[] memory urlHashes, - uint256[] memory urlIdxs - ) public { - vm.assume(owner != address(0)); - vm.assume(urlHashes.length > 0); - vm.assume(urlIdxs.length > 0); - vm.assume(urlIdxs.length != urlHashes.length); - - vm.startPrank(owner); - bytes32 projectId = registry.claimProject(projectIdUpper); - - vm.expectRevert(IImplicitProjectRegistry.InvalidProjectUrlIndex.selector); - registry.removeProjectUrlHashBatch(projectId, urlHashes, urlIdxs); - vm.stopPrank(); - } - - function test_removeProjectUrlHashBatchWithInvalidUrlIdxsOrder( - address owner, - bytes12 projectIdUpper, - bytes32[] memory urlHashes, - uint256[] memory urlIdxs - ) public { - vm.assume(owner != address(0)); - uint256 idxsLength = urlIdxs.length; - vm.assume(idxsLength > 1); - assembly { - mstore(urlHashes, idxsLength) - } - - bool isUnsorted = false; - for (uint256 i; i < urlIdxs.length - 1; i++) { - if (urlIdxs[i] < urlIdxs[i + 1]) { - isUnsorted = true; - break; - } - } - vm.assume(isUnsorted); - - vm.startPrank(owner); - bytes32 projectId = registry.claimProject(projectIdUpper); - - vm.expectRevert(IImplicitProjectRegistry.InvalidProjectUrlIndex.selector); - registry.removeProjectUrlHashBatch(projectId, urlHashes, urlIdxs); - vm.stopPrank(); - } - - function test_validateAttestationSingle( - address owner, - address wallet, - bytes12 projectIdUpper, - string memory url - ) public { - vm.assume(owner != address(0)); - vm.assume(bytes(url).length > 0); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - Attestation memory attestation; - attestation.authData.redirectUrl = url; - - vm.startPrank(owner); - registry.claimProject(projectIdUpper); - registry.addProjectUrl(projectId, url); - vm.stopPrank(); - - bytes32 magic = registry.validateAttestation(wallet, attestation, projectId); - assertEq(magic, attestation.generateImplicitRequestMagic(wallet)); - } - - function test_validateAttestationMultiple( - address owner, - address wallet, - bytes12 projectIdUpper, - string[] memory urls, - uint256 urlIdx - ) public { - vm.assume(owner != address(0)); - vm.assume(urls.length > 0); - // Max 10 urls - if (urls.length > 10) { - assembly { - mstore(urls, 10) - } - } - urls = _deduplicateStringArray(urls); - urlIdx = bound(urlIdx, 0, urls.length - 1); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - Attestation memory attestation; - attestation.authData.redirectUrl = urls[urlIdx]; - - vm.startPrank(owner); - registry.claimProject(projectIdUpper); - for (uint256 i; i < urls.length; i++) { - registry.addProjectUrl(projectId, urls[i]); - } - vm.stopPrank(); - - bytes32 magic = registry.validateAttestation(wallet, attestation, projectId); - assertEq(magic, attestation.generateImplicitRequestMagic(wallet)); - } - - // Negative Tests - - function test_fail_claimInvalidOwner( - bytes12 projectIdUpper - ) public { - address owner = address(0); - - vm.prank(owner); - vm.expectRevert(IImplicitProjectRegistry.InvalidProjectOwner.selector); - registry.claimProject(projectIdUpper); - } - - function test_fail_transferInvalidOwner( - address owner, - bytes12 projectIdUpper - ) public { - vm.assume(owner != address(0)); - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - vm.prank(owner); - vm.expectRevert(IImplicitProjectRegistry.InvalidProjectOwner.selector); - registry.transferProject(projectId, address(0)); - } - - function test_fail_claimProjectTwice( - address owner, - address otherUser, - bytes12 projectIdUpper - ) public { - vm.assume(owner != otherUser); - vm.assume(owner != address(0)); - vm.assume(otherUser != address(0)); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - // Transfer the project to the other user - vm.prank(owner); - registry.transferProject(projectId, otherUser); - - // Attempt to reclaim - vm.expectRevert(IImplicitProjectRegistry.ProjectAlreadyClaimed.selector); - vm.prank(owner); - registry.claimProject(projectIdUpper); - } - - function test_fail_transferByNonAdmin( - address owner, - address nonOwner, - bytes12 projectIdUpper - ) public { - vm.assume(owner != nonOwner); - vm.assume(owner != address(0)); - vm.assume(nonOwner != address(0)); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - vm.expectRevert(IImplicitProjectRegistry.NotProjectOwner.selector); - vm.prank(nonOwner); - registry.transferProject(projectId, nonOwner); - } - - function test_fail_addProjectUrlByNonOwner( - address owner, - address nonOwner, - bytes12 projectIdUpper, - string memory url - ) public { - vm.assume(owner != address(0)); - vm.assume(owner != nonOwner); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - vm.expectRevert(IImplicitProjectRegistry.NotProjectOwner.selector); - vm.prank(nonOwner); - registry.addProjectUrl(projectId, url); - } - - function test_fail_addProjectUrlHashByNonOwner( - address owner, - address nonOwner, - bytes12 projectIdUpper, - bytes32 urlHash - ) public { - vm.assume(owner != address(0)); - vm.assume(owner != nonOwner); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - vm.expectRevert(IImplicitProjectRegistry.NotProjectOwner.selector); - vm.prank(nonOwner); - registry.addProjectUrlHash(projectId, urlHash); - } - - function test_fail_removeProjectUrlByNonOwner( - address owner, - address nonOwner, - bytes12 projectIdUpper, - string memory url - ) public { - vm.assume(owner != address(0)); - vm.assume(owner != nonOwner); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - vm.expectRevert(IImplicitProjectRegistry.NotProjectOwner.selector); - vm.prank(nonOwner); - registry.removeProjectUrl(projectId, url); - } - - function test_fail_removeProjectUrlHashByNonOwner( - address owner, - address nonOwner, - bytes12 projectIdUpper, - bytes32 urlHash - ) public { - vm.assume(owner != address(0)); - vm.assume(owner != nonOwner); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - vm.expectRevert(IImplicitProjectRegistry.NotProjectOwner.selector); - vm.prank(nonOwner); - registry.removeProjectUrlHash(projectId, urlHash, 0); - } - - function test_fail_addProjectUrlHashBatchByNonOwner( - address owner, - address nonOwner, - bytes12 projectIdUpper, - bytes32[] memory urlHashes - ) public { - vm.assume(owner != address(0)); - vm.assume(owner != nonOwner); - vm.assume(urlHashes.length > 0); - // Max 10 urls - if (urlHashes.length > 10) { - assembly { - mstore(urlHashes, 10) - } - } - urlHashes = _deduplicateBytes32Array(urlHashes); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - vm.expectRevert(IImplicitProjectRegistry.NotProjectOwner.selector); - vm.prank(nonOwner); - registry.addProjectUrlHashBatch(projectId, urlHashes); - } - - function test_fail_removeProjectUrlHashBatchByNonOwner( - address owner, - address nonOwner, - bytes12 projectIdUpper, - bytes32[] memory urlHashes - ) public { - vm.assume(owner != address(0)); - vm.assume(owner != nonOwner); - vm.assume(urlHashes.length > 0); - // Max 10 urls - if (urlHashes.length > 10) { - assembly { - mstore(urlHashes, 10) - } - } - urlHashes = _deduplicateBytes32Array(urlHashes); - uint256[] memory urlIdxs = new uint256[](urlHashes.length); - for (uint256 i; i < urlHashes.length; i++) { - urlIdxs[i] = i; - } - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.startPrank(owner); - registry.claimProject(projectIdUpper); - for (uint256 i; i < urlHashes.length; i++) { - registry.addProjectUrlHash(projectId, urlHashes[i]); - } - vm.stopPrank(); - - vm.expectRevert(IImplicitProjectRegistry.NotProjectOwner.selector); - vm.prank(nonOwner); - registry.removeProjectUrlHashBatch(projectId, urlHashes, urlIdxs); - } - - function test_fail_addProjectUrlAlreadyExists( - address owner, - bytes12 projectIdUpper, - string memory url - ) public { - vm.assume(owner != address(0)); - vm.assume(bytes(url).length > 0); - - vm.startPrank(owner); - bytes32 projectId = registry.claimProject(projectIdUpper); - registry.addProjectUrl(projectId, url); - - vm.expectRevert(IImplicitProjectRegistry.ProjectUrlAlreadyExists.selector); - registry.addProjectUrl(projectId, url); - vm.stopPrank(); - } - - function test_fail_addProjectUrlHashAlreadyExists( - address owner, - bytes12 projectIdUpper, - bytes32 urlHash - ) public { - vm.assume(owner != address(0)); - vm.startPrank(owner); - bytes32 projectId = registry.claimProject(projectIdUpper); - registry.addProjectUrlHash(projectId, urlHash); - - vm.expectRevert(IImplicitProjectRegistry.ProjectUrlAlreadyExists.selector); - registry.addProjectUrlHash(projectId, urlHash); - vm.stopPrank(); - } - - function test_fail_addProjectUrlAlreadyExistsHash( - address owner, - bytes12 projectIdUpper, - string memory url - ) public { - vm.assume(owner != address(0)); - vm.startPrank(owner); - bytes32 projectId = registry.claimProject(projectIdUpper); - registry.addProjectUrlHash(projectId, _hashUrl(url)); - - vm.expectRevert(IImplicitProjectRegistry.ProjectUrlAlreadyExists.selector); - registry.addProjectUrl(projectId, url); - vm.stopPrank(); - } - - function test_fail_addProjectUrlHashAlreadyExistsFull( - address owner, - bytes12 projectIdUpper, - string memory url - ) public { - vm.assume(owner != address(0)); - vm.startPrank(owner); - bytes32 projectId = registry.claimProject(projectIdUpper); - registry.addProjectUrl(projectId, url); - - vm.expectRevert(IImplicitProjectRegistry.ProjectUrlAlreadyExists.selector); - registry.addProjectUrlHash(projectId, _hashUrl(url)); - vm.stopPrank(); - } - - function test_fail_removeNonexistentUrl( - address owner, - bytes12 projectIdUpper, - string memory url - ) public { - vm.assume(owner != address(0)); - vm.assume(bytes(url).length > 0); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - vm.expectRevert(IImplicitProjectRegistry.ProjectUrlNotFound.selector); - vm.prank(owner); - registry.removeProjectUrl(projectId, url); - } - - function test_fail_removeNonexistentUrlHash( - address owner, - bytes12 projectIdUpper, - bytes32 urlHash - ) public { - vm.assume(owner != address(0)); - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - vm.expectRevert(IImplicitProjectRegistry.InvalidProjectUrlIndex.selector); - vm.prank(owner); - registry.removeProjectUrlHash(projectId, urlHash, 0); - } - - function test_fail_removeUrlHashWrongIndex( - address owner, - bytes12 projectIdUpper, - bytes32[] memory urlHashes, - uint256 urlHashIdx - ) public { - vm.assume(owner != address(0)); - vm.assume(urlHashes.length > 0); - // Max 10 urls - if (urlHashes.length > 10) { - assembly { - mstore(urlHashes, 10) - } - } - urlHashes = _deduplicateBytes32Array(urlHashes); - urlHashIdx = bound(urlHashIdx, 0, urlHashes.length - 1); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.startPrank(owner); - registry.claimProject(projectIdUpper); - for (uint256 i; i < urlHashes.length; i++) { - registry.addProjectUrlHash(projectId, urlHashes[i]); - } - vm.stopPrank(); - - vm.expectRevert(IImplicitProjectRegistry.InvalidProjectUrlIndex.selector); - vm.prank(owner); - registry.removeProjectUrlHash(projectId, urlHashes[urlHashIdx], urlHashIdx + 1); - } - - function test_fail_validateAttestationWithInvalidUrl( - address owner, - address wallet, - bytes12 projectIdUpper, - string memory validUrl, - string memory invalidUrl - ) public { - vm.assume(owner != address(0)); - vm.assume(bytes(validUrl).length > 0 && bytes(invalidUrl).length > 0); - vm.assume(keccak256(bytes(validUrl)) != keccak256(bytes(invalidUrl))); - - bytes32 projectId = _projectId(projectIdUpper, owner); - - vm.prank(owner); - registry.claimProject(projectIdUpper); - - Attestation memory attestation; - attestation.authData.redirectUrl = invalidUrl; - - vm.prank(owner); - registry.addProjectUrl(projectId, validUrl); - - vm.expectRevert(IImplicitProjectValidation.InvalidRedirectUrl.selector); - registry.validateAttestation(wallet, attestation, projectId); - } - -} diff --git a/lib/signals-implicit-mode/test/SignalsImplicitMode.t.sol b/lib/signals-implicit-mode/test/SignalsImplicitMode.t.sol deleted file mode 100644 index fba898eb2f..0000000000 --- a/lib/signals-implicit-mode/test/SignalsImplicitMode.t.sol +++ /dev/null @@ -1,115 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.13; - -import { TestHelper } from "./TestHelper.sol"; -import { SignalsImplicitModeMock } from "./mock/SignalsImplicitModeMock.sol"; -import { Test, console } from "forge-std/Test.sol"; - -import { IImplicitProjectValidation } from "../src/registry/IImplicitProjectValidation.sol"; -import { ImplicitProjectRegistry } from "../src/registry/ImplicitProjectRegistry.sol"; - -import { IERC165 } from "openzeppelin-contracts/contracts/utils/introspection/IERC165.sol"; -import { Attestation, LibAttestation } from "sequence-v3/src/extensions/sessions/implicit/Attestation.sol"; -import { ISignalsImplicitMode } from "sequence-v3/src/extensions/sessions/implicit/ISignalsImplicitMode.sol"; -import { Payload } from "sequence-v3/src/modules/Payload.sol"; - -contract SignalsImplicitModeTest is Test, TestHelper { - - using LibAttestation for Attestation; - - SignalsImplicitModeMock public signalsImplicitMode; - ImplicitProjectRegistry public registry; - - function setUp() public { - registry = new ImplicitProjectRegistry(); - } - - function test_supportsInterface( - bytes32 projectId - ) public { - signalsImplicitMode = new SignalsImplicitModeMock(address(registry), projectId); - assertEq(signalsImplicitMode.supportsInterface(type(IERC165).interfaceId), true); - assertEq(signalsImplicitMode.supportsInterface(type(ISignalsImplicitMode).interfaceId), true); - } - - function test_acceptsValidUrl( - bytes12 projectIdUpper, - address owner, - string memory url, - Attestation memory attestation, - address wallet, - Payload.Call memory call - ) public { - vm.assume(owner != address(0)); - attestation.authData.redirectUrl = url; - - // Claim the project and add the url - vm.startPrank(owner); - bytes32 projectId = registry.claimProject(projectIdUpper); - registry.addProjectUrl(projectId, url); - vm.stopPrank(); - - // Initialize the signals implicit mode - signalsImplicitMode = new SignalsImplicitModeMock(address(registry), projectId); - - // Accept the implicit request - bytes32 expectedMagic = attestation.generateImplicitRequestMagic(wallet); - bytes32 actualMagic = signalsImplicitMode.acceptImplicitRequest(wallet, attestation, call); - assertEq(actualMagic, expectedMagic); - } - - function test_acceptsValidUrlFromMultiple( - bytes12 projectIdUpper, - address owner, - string[] memory urls, - uint256 urlIdx, - Attestation memory attestation, - address wallet, - Payload.Call memory call - ) public { - vm.assume(owner != address(0)); - vm.assume(urls.length > 0); - // Max 10 urls - if (urls.length > 10) { - assembly { - mstore(urls, 10) - } - } - urls = _deduplicateStringArray(urls); - urlIdx = bound(urlIdx, 0, urls.length - 1); - - attestation.authData.redirectUrl = urls[urlIdx]; - - // Claim the project and add the url - vm.startPrank(owner); - bytes32 projectId = registry.claimProject(projectIdUpper); - for (uint256 i; i < urls.length; i++) { - registry.addProjectUrl(projectId, urls[i]); - } - vm.stopPrank(); - - // Initialize the signals implicit mode - signalsImplicitMode = new SignalsImplicitModeMock(address(registry), projectId); - - // Accept the implicit request - bytes32 expectedMagic = attestation.generateImplicitRequestMagic(wallet); - bytes32 actualMagic = signalsImplicitMode.acceptImplicitRequest(wallet, attestation, call); - assertEq(actualMagic, expectedMagic); - } - - function test_rejectsInvalidUrl( - bytes32 projectId, - string memory url, - Attestation memory attestation, - address wallet, - Payload.Call memory call - ) public { - signalsImplicitMode = new SignalsImplicitModeMock(address(registry), projectId); - attestation.authData.redirectUrl = url; - - // Accept the implicit request - vm.expectRevert(abi.encodeWithSelector(IImplicitProjectValidation.InvalidRedirectUrl.selector)); - signalsImplicitMode.acceptImplicitRequest(wallet, attestation, call); - } - -} diff --git a/lib/signals-implicit-mode/test/TestHelper.sol b/lib/signals-implicit-mode/test/TestHelper.sol deleted file mode 100644 index 7f1339766e..0000000000 --- a/lib/signals-implicit-mode/test/TestHelper.sol +++ /dev/null @@ -1,64 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.13; - -contract TestHelper { - - function _hashUrl( - string memory url - ) internal pure returns (bytes32) { - return keccak256(abi.encodePacked(url)); - } - - function _projectId( - bytes12 projectIdUpper, - address owner - ) internal pure returns (bytes32 projectId) { - projectId = bytes32(abi.encodePacked(projectIdUpper, owner)); - } - - function _deduplicateBytes32Array( - bytes32[] memory array - ) internal pure returns (bytes32[] memory deduplicatedArray) { - deduplicatedArray = new bytes32[](array.length); - uint256 deduplicatedIndex; - for (uint256 i; i < array.length; i++) { - bool isDuplicate; - for (uint256 j; j < deduplicatedIndex; j++) { - if (deduplicatedArray[j] == array[i]) { - isDuplicate = true; - break; - } - } - if (!isDuplicate) { - deduplicatedArray[deduplicatedIndex++] = array[i]; - } - } - assembly { - mstore(deduplicatedArray, deduplicatedIndex) - } - } - - function _deduplicateStringArray( - string[] memory array - ) internal pure returns (string[] memory deduplicatedArray) { - deduplicatedArray = new string[](array.length); - uint256 deduplicatedIndex; - for (uint256 i; i < array.length; i++) { - bool isDuplicate; - bytes32 currentHash = _hashUrl(array[i]); - for (uint256 j; j < deduplicatedIndex; j++) { - if (currentHash == _hashUrl(deduplicatedArray[j])) { - isDuplicate = true; - break; - } - } - if (!isDuplicate) { - deduplicatedArray[deduplicatedIndex++] = array[i]; - } - } - assembly { - mstore(deduplicatedArray, deduplicatedIndex) - } - } - -} diff --git a/lib/signals-implicit-mode/test/mock/SignalsImplicitModeMock.sol b/lib/signals-implicit-mode/test/mock/SignalsImplicitModeMock.sol deleted file mode 100644 index 566e942dae..0000000000 --- a/lib/signals-implicit-mode/test/mock/SignalsImplicitModeMock.sol +++ /dev/null @@ -1,15 +0,0 @@ -// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.13; - -import { SignalsImplicitMode } from "../../src/helper/SignalsImplicitMode.sol"; - -contract SignalsImplicitModeMock is SignalsImplicitMode { - - constructor( - address registry, - bytes32 projectId - ) { - _initializeSignalsImplicitMode(registry, projectId); - } - -} diff --git a/package.json b/package.json index 8d8be28e3a..92559c5103 100644 --- a/package.json +++ b/package.json @@ -20,96 +20,20 @@ "deps:fix": "syncpack fix" }, "devDependencies": { - "@changesets/cli": "^2.30.0", - "@types/node": "^25.5.0", - "lefthook": "^2.1.4", + "@changesets/cli": "^2.29.8", + "lefthook": "^2.1.1", "prettier": "^3.8.1", "rimraf": "^6.1.3", - "syncpack": "^14.2.0", - "turbo": "^2.8.19", + "syncpack": "^14.0.0", + "turbo": "^2.8.10", "typescript": "^5.9.3" }, "pnpm": { "overrides": { - "ox": "^0.9.17", - "tmp@<=0.2.3": ">=0.2.4", - "lodash@>=4.0.0 <=4.17.22": ">=4.17.23", - "diff@>=4.0.0 <4.0.4": ">=4.0.4", - "minimatch@<3.1.3": ">=3.1.3", - "minimatch@>=9.0.0 <9.0.6": ">=9.0.6", - "rollup@>=4.0.0 <4.59.0": ">=4.59.0", - "basic-ftp@<5.2.0": ">=5.2.0", - "minimatch@>=9.0.0 <9.0.7": ">=9.0.7", - "minimatch@>=10.0.0 <10.2.3": ">=10.2.3", - "minimatch@<3.1.4": ">=3.1.4", - "ajv@<6.14.0": ">=6.14.0", - "flatted@<3.4.0": ">=3.4.0", - "next@>=9.5.0 <15.5.13": ">=15.5.13", - "next@>=10.0.0 <16.1.7": ">=16.1.7", - "yargs-parser@<=5.0.0": ">=5.0.1", - "got@<11.8.5": ">=11.8.5", - "node-fetch@<2.6.7": ">=2.6.7", - "json5@<1.0.2": ">=1.0.2", - "debug@>=3.2.0 <3.2.7": ">=3.2.7", - "tar@<6.2.1": ">=6.2.1", - "axios@>=0.8.1 <0.28.0": ">=0.28.0", - "tough-cookie@<4.1.3": ">=4.1.3", - "async@>=2.0.0 <2.6.4": ">=2.6.4", - "braces@<3.0.3": ">=3.0.3", - "ws@>=8.0.0 <8.17.1": ">=8.17.1", - "ws@>=2.1.0 <5.2.4": ">=5.2.4", - "micromatch@<4.0.8": ">=4.0.8", - "elliptic@<=6.6.0": ">=6.6.1", - "cookie@<0.7.0": ">=0.7.0", - "form-data@<2.5.4": ">=2.5.4", - "elliptic@>=4.0.0 <=6.5.6": ">=6.5.7", - "elliptic@>=2.0.0 <=6.5.6": ">=6.5.7", - "elliptic@>=5.2.1 <=6.5.6": ">=6.5.7", - "underscore@>=1.3.2 <1.12.1": ">=1.12.1", - "axios@<0.30.0": ">=0.30.0", - "elliptic@<6.6.0": ">=6.6.0", - "elliptic@<6.5.6": ">=6.5.6", - "undici@<6.23.0": ">=6.23.0", - "tar@<7.5.7": ">=7.5.7", - "semver@>=2.0.0-alpha <5.7.2": ">=5.7.2", - "axios@<=0.30.2": ">=0.30.3", - "tar@<=7.5.2": ">=7.5.3", - "tar@<7.5.8": ">=7.5.8", - "bn.js@<4.12.3": ">=4.12.3", - "serialize-javascript@<=7.0.2": ">=7.0.3", - "qs@<6.14.1": ">=6.14.1", - "underscore@<=1.13.7": ">=1.13.8", - "tar@<=7.5.9": ">=7.5.10", - "tar@<=7.5.10": ">=7.5.11", - "undici@<6.24.0": ">=6.24.0", - "tar@<=7.5.3": ">=7.5.4", - "fast-xml-parser@>=4.0.0-beta.3 <=5.5.5": ">=5.5.6" - }, - "onlyBuiltDependencies": [ - "@parcel/watcher", - "@prisma/engines", - "@tailwindcss/oxide", - "@trufflesuite/bigint-buffer", - "bufferutil", - "core-js", - "core-js-pure", - "es5-ext", - "esbuild", - "keccak", - "lefthook", - "postinstall-postinstall", - "prisma", - "protobufjs", - "scrypt", - "secp256k1", - "sharp", - "utf-8-validate", - "web3", - "web3-bzz", - "web3-shh" - ] + "ox": "^0.9.17" + } }, - "packageManager": "pnpm@9.15.9+sha512.68046141893c66fad01c079231128e9afb89ef87e2691d69e4d40eee228988295fd4682181bae55b58418c3a253bde65a505ec7c5f9403ece5cc3cd37dcf2531", + "packageManager": "pnpm@10.24.0", "engines": { "node": ">=18" }, @@ -132,11 +56,5 @@ "pinVersion": "workspace:^" } ] - }, - "dependencies": { - "@0xsequence/guard": "^3.0.4", - "@0xsequence/indexer": "^3.0.4", - "@0xsequence/wallet-contracts": "^3.0.1", - "flag": "^5.0.1" } } diff --git a/packages/cli/CHANGELOG.md b/packages/cli/CHANGELOG.md new file mode 100644 index 0000000000..a2911e2304 --- /dev/null +++ b/packages/cli/CHANGELOG.md @@ -0,0 +1,449 @@ +# @wagmi/cli + +## 2.3.1 + +### Patch Changes + +- [#4655](https://github.com/wevm/wagmi/pull/4655) [`43241c8417f3c342036bb46ec8e507d052ae2691`](https://github.com/wevm/wagmi/commit/43241c8417f3c342036bb46ec8e507d052ae2691) Thanks [@tmm](https://github.com/tmm)! - Bumped internal deps. + +## 2.3.0 + +### Minor Changes + +- [#4629](https://github.com/wevm/wagmi/pull/4629) [`66dec7d75d580b3121ebc7e8162c1f9ae37cfd41`](https://github.com/wevm/wagmi/commit/66dec7d75d580b3121ebc7e8162c1f9ae37cfd41) Thanks [@allezxandre](https://github.com/allezxandre)! - Upgraded to Sourcify v2 API in `sourcify` plugin + +## 2.2.1 + +### Patch Changes + +- [`7b0dbe3886c1a7c6dbbdab945d7436ec20ad8f93`](https://github.com/wevm/wagmi/commit/7b0dbe3886c1a7c6dbbdab945d7436ec20ad8f93) Thanks [@tmm](https://github.com/tmm)! - Updated block explorer chains. + +## 2.2.0 + +### Minor Changes + +- [#4503](https://github.com/wevm/wagmi/pull/4503) [`8fce8a6f97aa2ee5fd1bda6a3ece422b10324b5a`](https://github.com/wevm/wagmi/commit/8fce8a6f97aa2ee5fd1bda6a3ece422b10324b5a) Thanks [@tmm](https://github.com/tmm)! - Updated Etherscan Plugin to use Etherscan API v2. + +- [#4507](https://github.com/wevm/wagmi/pull/4507) [`6f09cc57935891e1c67d6df3459f6998985c69dc`](https://github.com/wevm/wagmi/commit/6f09cc57935891e1c67d6df3459f6998985c69dc) Thanks [@tmm](https://github.com/tmm)! - Added `tryFetchProxyImplementation` flag to Etherscan Plugin to enable fetching the implementation ABI instead of the proxy ABI. + +## 2.1.22 + +### Patch Changes + +- [#4462](https://github.com/wevm/wagmi/pull/4462) [`0b2238d27cecbcd33aee64fb0e30ddc18b6ddf74`](https://github.com/wevm/wagmi/commit/0b2238d27cecbcd33aee64fb0e30ddc18b6ddf74) Thanks [@groninge01](https://github.com/groninge01)! - Added Sonic to Etherscan plugin. + +## 2.1.21 + +### Patch Changes + +- [#4457](https://github.com/wevm/wagmi/pull/4457) [`21ec74da7f93fc13e253d7b35ddeddc23422a6c1`](https://github.com/wevm/wagmi/commit/21ec74da7f93fc13e253d7b35ddeddc23422a6c1) Thanks [@tmm](https://github.com/tmm)! - Removed internal dependency. + +## 2.1.20 + +### Patch Changes + +- [#4450](https://github.com/wevm/wagmi/pull/4450) [`7b9a6bb35881b657a00bdd7ccd7edea32660f5bf`](https://github.com/wevm/wagmi/commit/7b9a6bb35881b657a00bdd7ccd7edea32660f5bf) Thanks [@tmm](https://github.com/tmm)! - Removed internal usage of `fs-extra`. + +## 2.1.19 + +### Patch Changes + +- [#4449](https://github.com/wevm/wagmi/pull/4449) [`3fa5c238baa13d948e89974b0bb8530f8fa264fd`](https://github.com/wevm/wagmi/commit/3fa5c238baa13d948e89974b0bb8530f8fa264fd) Thanks [@tmm](https://github.com/tmm)! - Removed `ora` for `nanospinner`. + +## 2.1.18 + +### Patch Changes + +- [#4399](https://github.com/wevm/wagmi/pull/4399) [`bc18673e4c272e3b60a1b6016934fe3fbeb6d93a`](https://github.com/wevm/wagmi/commit/bc18673e4c272e3b60a1b6016934fe3fbeb6d93a) Thanks [@tmm](https://github.com/tmm)! - Added Polygon Amoy to Sourcify and Etherscan plugins. + +## 2.1.17 + +### Patch Changes + +- [#4370](https://github.com/wevm/wagmi/pull/4370) [`cb58b1ea3ad40e77210f24eb598f9d2306db998c`](https://github.com/wevm/wagmi/commit/cb58b1ea3ad40e77210f24eb598f9d2306db998c) Thanks [@talentlessguy](https://github.com/talentlessguy)! - Bumped internal dependencies. + +## 2.1.16 + +### Patch Changes + +- [#4224](https://github.com/wevm/wagmi/pull/4224) [`b0eb89c2a0781bb3434996fa53ee7ceb3bb44db9`](https://github.com/wevm/wagmi/commit/b0eb89c2a0781bb3434996fa53ee7ceb3bb44db9) Thanks [@roderik](https://github.com/roderik)! - Fixed package detection for Bun. + +## 2.1.15 + +### Patch Changes + +- [`0bb8b562ae04ecfeb2d6b2f1b980ebae31dc127e`](https://github.com/wevm/wagmi/commit/0bb8b562ae04ecfeb2d6b2f1b980ebae31dc127e) Thanks [@tmm](https://github.com/tmm)! - Improved TypeScript `'exactOptionalPropertyTypes'` support. + +## 2.1.14 + +### Patch Changes + +- [#4120](https://github.com/wevm/wagmi/pull/4120) [`59407bf1276a46e6f1f22a370dde71c92524cd0f`](https://github.com/wevm/wagmi/commit/59407bf1276a46e6f1f22a370dde71c92524cd0f) Thanks [@tmm](https://github.com/tmm)! - Fixed an issue where the Foundry and Hardhat plugins' `exclude` option was ignored. + +## 2.1.13 + +### Patch Changes + +- [`7264d1f450727f6ba0cbea8aa1c7a83e22a5bf20`](https://github.com/wevm/wagmi/commit/7264d1f450727f6ba0cbea8aa1c7a83e22a5bf20) Thanks [@tmm](https://github.com/tmm)! - Fixed generate not exiting for long-running processes. + +## 2.1.12 + +### Patch Changes + +- [`ac038b29623ccb0d2fee40d9f943c8df28138dac`](https://github.com/wevm/wagmi/commit/ac038b29623ccb0d2fee40d9f943c8df28138dac) Thanks [@tmm](https://github.com/tmm)! - Updated Foundry default excludes. + +## 2.1.11 + +### Patch Changes + +- [#4084](https://github.com/wevm/wagmi/pull/4084) [`b54203bf8fa911e6f14b9675980cf38fb95d7d3e`](https://github.com/wevm/wagmi/commit/b54203bf8fa911e6f14b9675980cf38fb95d7d3e) Thanks [@tmm](https://github.com/tmm)! - Reduced internal dependencies. + +## 2.1.10 + +### Patch Changes + +- [#4051](https://github.com/wevm/wagmi/pull/4051) [`275e78b0e585f0ec9da2f9661ce9990aed18e9f4`](https://github.com/wevm/wagmi/commit/275e78b0e585f0ec9da2f9661ce9990aed18e9f4) Thanks [@tmm](https://github.com/tmm)! - Updated Sourcify plugin internals. + +## 2.1.9 + +### Patch Changes + +- [`f9346dbcffaf57a8949cb96e43df111a89d733b1`](https://github.com/wevm/wagmi/commit/f9346dbcffaf57a8949cb96e43df111a89d733b1) Thanks [@tmm](https://github.com/tmm)! - Updated Foundry plugin default excludes. + +## 2.1.8 + +### Patch Changes + +- [#3957](https://github.com/wevm/wagmi/pull/3957) [`7d00680f73b090eb34af928ae74277bec1973953`](https://github.com/wevm/wagmi/commit/7d00680f73b090eb34af928ae74277bec1973953) Thanks [@cstoneham](https://github.com/cstoneham)! - Added Blast to Etherscan plugin + +## 2.1.7 + +### Patch Changes + +- [`1122678bbad0232590bd4060a73752de2c84982d`](https://github.com/wevm/wagmi/commit/1122678bbad0232590bd4060a73752de2c84982d) Thanks [@tmm](https://github.com/tmm)! - Published unpublished changes in [#3756](https://github.com/wevm/wagmi/pull/3756). + +## 2.1.6 + +### Patch Changes + +- [#3756](https://github.com/wevm/wagmi/pull/3756) [`c7d6f467`](https://github.com/wevm/wagmi/commit/c7d6f4679125fd2f6cca5b5ef362abf47e37f934) Thanks [@jrfrantz](https://github.com/jrfrantz)! - Added basescan to etherscan cli plugin + +## 2.1.5 + +### Patch Changes + +- [`e1ca4e63`](https://github.com/wevm/wagmi/commit/e1ca4e637ae6cec7f5902b0a2c0e0efc3b751a1d) Thanks [@tmm](https://github.com/tmm)! - Added title to CLI process. + +- [#3723](https://github.com/wevm/wagmi/pull/3723) [`d6bc98ca`](https://github.com/wevm/wagmi/commit/d6bc98ca0ce9081f192f62e0b0fcfea3cb07a2bb) Thanks [@leecobaby](https://github.com/leecobaby)! - Broadened TypeScript detection. + +## 2.1.4 + +### Patch Changes + +- [#3737](https://github.com/wevm/wagmi/pull/3737) [`11020fed`](https://github.com/wevm/wagmi/commit/11020fedfc68639eace241e328331cff43bf91af) Thanks [@oskarvu](https://github.com/oskarvu)! - Added Gnosis to Etherscan plugin. + +## 2.1.3 + +### Patch Changes + +- [#3660](https://github.com/wevm/wagmi/pull/3660) [`11a22a23`](https://github.com/wevm/wagmi/commit/11a22a23d88c025cde9c91610e9ddf62cd4fa650) Thanks [@JazzBashara](https://github.com/JazzBashara)! - Replaced SnowTrace with SnowScan for the Etherscan plugin + +## 2.1.2 + +### Patch Changes + +- [#3641](https://github.com/wevm/wagmi/pull/3641) [`0a866403`](https://github.com/wevm/wagmi/commit/0a866403182ea6b8ba7f976c45be294e48fb7de8) Thanks [@cmwhited](https://github.com/cmwhited)! - Added Arbitrum Sepolia testnet to Etherscan plugin + +- [#3633](https://github.com/wevm/wagmi/pull/3633) [`a1d3d1ab`](https://github.com/wevm/wagmi/commit/a1d3d1ab2b023c61c0dbb5d7bf867a9fca673630) Thanks [@pegahcarter](https://github.com/pegahcarter)! - Added Fraxtal to Etherscan plugin + +- [#3616](https://github.com/wevm/wagmi/pull/3616) [`2a9f4473`](https://github.com/wevm/wagmi/commit/2a9f4473adc5bcdddf388389387ed5459583769e) Thanks [@petermazzocco](https://github.com/petermazzocco)! - Added Holesky Testnet to Etherscan Plugin + +## 2.1.1 + +### Patch Changes + +- [#3579](https://github.com/wevm/wagmi/pull/3579) [`a057919c`](https://github.com/wevm/wagmi/commit/a057919ca3942adeed90af2e343403dc5274e84c) Thanks [@FaisalAli19](https://github.com/FaisalAli19)! - Added Optimism Sepolia Etherscan support + +## 2.1.0 + +### Minor Changes + +- [#3506](https://github.com/wevm/wagmi/pull/3506) [`134eb4a1`](https://github.com/wevm/wagmi/commit/134eb4a1e0e29aab87bd5c7cdf05b06dfd7c4fc4) Thanks [@vmaark](https://github.com/vmaark)! - Added resolution of TypeScript Wagmi CLI config to determine if TypeScript generated output is allowed. + +## 2.0.4 + +### Patch Changes + +- [#3462](https://github.com/wevm/wagmi/pull/3462) [`d25573ea`](https://github.com/wevm/wagmi/commit/d25573ea03358f967953e37c176b220a7b341769) Thanks [@cruzdanilo](https://github.com/cruzdanilo)! - Upgraded dependencies + +## 2.0.3 + +### Patch Changes + +- [#3410](https://github.com/wevm/wagmi/pull/3410) [`55e31c3e`](https://github.com/wevm/wagmi/commit/55e31c3e96c2cbd1d9eb44e5a89f4365489c8310) Thanks [@o-az](https://github.com/o-az)! - Fixed actions plugin issue where `functionName` was used instead of `eventName` for generated contract event actions. + +## 2.0.2 + +### Patch Changes + +- [#3371](https://github.com/wevm/wagmi/pull/3371) [`8294d9e5`](https://github.com/wevm/wagmi/commit/8294d9e5b358018ba869b2018cd7ed95462e021f) Thanks [@iceanddust](https://github.com/iceanddust)! - Fixed prop name when generating contract event watch hooks + +## 2.0.1 + +### Major Changes + +- [#3333](https://github.com/wevm/wagmi/pull/3333) [`b3a0baaa`](https://github.com/wevm/wagmi/commit/b3a0baaaee7decf750d376aab2502cd33ca4825a) Thanks [@tmm](https://github.com/tmm)! - Wagmi CLI 2.0. + + [Breaking Changes & Migration Guide](https://wagmi.sh/cli/guides/migrate-from-v1-to-v2) + +## 1.5.2 + +### Patch Changes + +- [#3051](https://github.com/wagmi-dev/wagmi/pull/3051) [`4704d351`](https://github.com/wagmi-dev/wagmi/commit/4704d351164d39704a4e375c06525554fcc8340e) Thanks [@oxSaturn](https://github.com/oxSaturn)! - Fixed ESM require issue for prettier + +## 1.5.1 + +### Patch Changes + +- [#3035](https://github.com/wagmi-dev/wagmi/pull/3035) [`187bf96c`](https://github.com/wagmi-dev/wagmi/commit/187bf96c9fd31675b9d17a7cb4d4e24eea3fa777) Thanks [@cruzdanilo](https://github.com/cruzdanilo)! - ignore foundry invariant lib + +## 1.5.0 + +### Minor Changes + +- [#2956](https://github.com/wevm/wagmi/pull/2956) [`2abeb285`](https://github.com/wevm/wagmi/commit/2abeb285674af3e539cc2550b1f5027b1eb0c895) Thanks [@tmm](https://github.com/tmm)! - Replaced `@wagmi/chains` with `viem/chains`. + +## 1.4.1 + +### Patch Changes + +- [#2962](https://github.com/wevm/wagmi/pull/2962) [`8ac5b572`](https://github.com/wevm/wagmi/commit/8ac5b57254f77eeb0e07dd83f7d49f396d4581d8) Thanks [@tmm](https://github.com/tmm)! - Fixed esbuild version + +## 1.4.0 + +### Minor Changes + +- [#2946](https://github.com/wevm/wagmi/pull/2946) [`1c3228bf`](https://github.com/wevm/wagmi/commit/1c3228bf3fe99b0900b2c9a223c9b81c70bdcd90) Thanks [@tomquirk](https://github.com/tomquirk)! - Added default chain ID to generated `useContractRead` hook. + +### Patch Changes + +- [#2547](https://github.com/wevm/wagmi/pull/2547) [`8c3889fe`](https://github.com/wevm/wagmi/commit/8c3889fe82c5a1ddb29e74e3863ea6f4917b777a) Thanks [@Iamshankhadeep](https://github.com/Iamshankhadeep)! - Deterministic CLI output + +- [#2958](https://github.com/wevm/wagmi/pull/2958) [`b31f36d5`](https://github.com/wevm/wagmi/commit/b31f36d522a634f53d44349d6a9ea47f59d84d7a) Thanks [@tmm](https://github.com/tmm)! - Removed generated file header + +- [#2960](https://github.com/wevm/wagmi/pull/2960) [`5d4c4592`](https://github.com/wevm/wagmi/commit/5d4c4592009568cd0b096906a424f27469721a42) Thanks [@tmm](https://github.com/tmm)! - Updated esbuild version + +## 1.3.0 + +### Minor Changes + +- [#2616](https://github.com/wevm/wagmi/pull/2616) [`c282a8f7`](https://github.com/wevm/wagmi/commit/c282a8f786d57fec77c931fe99dc20220e843bc8) Thanks [@portdeveloper](https://github.com/portdeveloper)! - Added sepolia chain id + +## 1.2.1 + +### Patch Changes + +- [#2607](https://github.com/wevm/wagmi/pull/2607) [`79335b4c`](https://github.com/wevm/wagmi/commit/79335b4c0fcd5e8152a2a1d28314c634db9d9cbf) Thanks [@roninjin10](https://github.com/roninjin10)! - Fixed opitmism goerli chain id + +## 1.2.0 + +### Minor Changes + +- [#2536](https://github.com/wevm/wagmi/pull/2536) [`85e9760a`](https://github.com/wevm/wagmi/commit/85e9760a140cb169ac6236d9466b96e2105dd193) Thanks [@tmm](https://github.com/tmm)! - Changed `Address` type import from ABIType to viem. + +## 1.1.0 + +### Minor Changes + +- [#2482](https://github.com/wevm/wagmi/pull/2482) [`8764b54a`](https://github.com/wevm/wagmi/commit/8764b54aab68020063946112e8fe52aff650c99c) Thanks [@tmm](https://github.com/tmm)! - Bumped minimum TypeScript version to v5.0.4. + +### Patch Changes + +- [#2484](https://github.com/wevm/wagmi/pull/2484) [`3adf1f4f`](https://github.com/wevm/wagmi/commit/3adf1f4feab863cb7b5d52c81ad46f7e4eb56f09) Thanks [@jxom](https://github.com/jxom)! - Updated `abitype` to 0.8.7 + +- [#2484](https://github.com/wevm/wagmi/pull/2484) [`3adf1f4f`](https://github.com/wevm/wagmi/commit/3adf1f4feab863cb7b5d52c81ad46f7e4eb56f09) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +## 1.0.3 + +### Patch Changes + +- [#2441](https://github.com/wevm/wagmi/pull/2441) [`326edee4`](https://github.com/wevm/wagmi/commit/326edee4bc85db84a7a4e3768e33785849ab8d8e) Thanks [@tmm](https://github.com/tmm)! - Fixed internal type issue + +## 1.0.2 + +### Patch Changes + +- [#2430](https://github.com/wevm/wagmi/pull/2430) [`71d92029`](https://github.com/wevm/wagmi/commit/71d92029ee4344842cd41698858a330fee95b6e0) Thanks [@tmm](https://github.com/tmm)! - Added message when command is not found. + +## 1.0.1 + +### Patch Changes + +- [`ea651cd7`](https://github.com/wevm/wagmi/commit/ea651cd7fc75b7866272605467db11fd6e1d81af) Thanks [@jxom](https://github.com/jxom)! - Downgraded abitype. + +## 1.0.0 + +### Major Changes + +- [#2235](https://github.com/wevm/wagmi/pull/2235) [`5be0655c`](https://github.com/wevm/wagmi/commit/5be0655c8e48b25d38009022461fbf611af54349) Thanks [@jxom](https://github.com/jxom)! - Released v1. Read [Migration Guide](https://next.wagmi.sh/react/migration-guide#1xx-breaking-changes). + +## 1.0.0-next.7 + +### Patch Changes + +- Fixed react plugin generic. + +## 1.0.0-next.6 + +### Major Changes + +- Updated references. + +## 1.0.0-next.5 + +### Major Changes + +- Added `config.setConnectors` + +## 1.0.0-next.4 + +### Major Changes + +- Updated viem. + Removed `goerli` export from main entrypoint. + +## 1.0.0-next.3 + +### Major Changes + +- Updated references. + +## 1.0.0-next.2 + +### Major Changes + +- Updated dependencies + +### Patch Changes + +- Updated dependencies []: + - @wagmi/chains@1.0.0-next.0 + +## 1.0.0-next.1 + +### Major Changes + +- updated viem + +## 1.0.0-next.0 + +### Major Changes + +- [`a7dda00c`](https://github.com/wevm/wagmi/commit/a7dda00c5b546f8b2c42b527e4d9ac1b9e9ab1fb) Thanks [@jxom](https://github.com/jxom)! - Released v1. + +### Patch Changes + +- Updated dependencies [[`a7dda00c`](https://github.com/wevm/wagmi/commit/a7dda00c5b546f8b2c42b527e4d9ac1b9e9ab1fb)]: + - @wagmi/core@1.0.0-next.0 + - wagmi@1.0.0-next.0 + +## 0.1.15 + +### Patch Changes + +- [#2145](https://github.com/wevm/wagmi/pull/2145) [`2520743c`](https://github.com/wevm/wagmi/commit/2520743c417a158a00d5edca13a9aa92cefb0cfd) Thanks [@tmm](https://github.com/tmm)! - Fixed issue using Hardhat Plugin with npm. + +## 0.1.14 + +### Patch Changes + +- [#2039](https://github.com/wevm/wagmi/pull/2039) [`bac893ab`](https://github.com/wevm/wagmi/commit/bac893ab26012d4d8741c4f80e8b8813aee26f0c) Thanks [@tmm](https://github.com/tmm)! - Updated references. + +- [#2039](https://github.com/wevm/wagmi/pull/2039) [`bac893ab`](https://github.com/wevm/wagmi/commit/bac893ab26012d4d8741c4f80e8b8813aee26f0c) Thanks [@tmm](https://github.com/tmm)! - Fixed Actions plugin `overridePackageName` option. + +## 0.1.13 + +### Patch Changes + +- [#2000](https://github.com/wevm/wagmi/pull/2000) [`01254765`](https://github.com/wevm/wagmi/commit/01254765eb37b77aca26500c00c721f08a260912) Thanks [@tmm](https://github.com/tmm)! - Fixed React plugin name conflict. + +## 0.1.12 + +### Patch Changes + +- [#1992](https://github.com/wevm/wagmi/pull/1992) [`efc93cad`](https://github.com/wevm/wagmi/commit/efc93cadacdb9c9960644dabe4ae837d384df52b) Thanks [@tmm](https://github.com/tmm)! - Refactored internals from ethers to viem. + +## 0.1.11 + +### Patch Changes + +- [#1916](https://github.com/wevm/wagmi/pull/1916) [`950490fd`](https://github.com/wevm/wagmi/commit/950490fd132b3fb5b3455e77b58d70f134b8e5c9) Thanks [@technophile-04](https://github.com/technophile-04)! - Updated React plugin to use `Address` type instead of hardcoding `` `0x{string}` ``. + +## 0.1.10 + +### Patch Changes + +- [#1892](https://github.com/wevm/wagmi/pull/1892) [`d3d6973b`](https://github.com/wevm/wagmi/commit/d3d6973ba9407e490140d2434eb83aad88d6e10d) Thanks [@greg-schrammel](https://github.com/greg-schrammel)! - Fixed generated read hooks `select` type. + +## 0.1.9 + +### Patch Changes + +- [#1886](https://github.com/wevm/wagmi/pull/1886) [`36e119c6`](https://github.com/wevm/wagmi/commit/36e119c6d4bc28a7ae15c9602d0c613bc9681356) Thanks [@roninjin10](https://github.com/roninjin10)! - Fixed package detection for yarn^3 + +## 0.1.8 + +### Patch Changes + +- [#1884](https://github.com/wevm/wagmi/pull/1884) [`cc03bb44`](https://github.com/wevm/wagmi/commit/cc03bb44268874f95203de67f6d32586e34c0857) Thanks [@roninjin10](https://github.com/roninjin10)! - Added better compatibility for yarn@^3 in `@wagmi/cli`. + +## 0.1.7 + +### Patch Changes + +- [#1841](https://github.com/wevm/wagmi/pull/1841) [`cb707f01`](https://github.com/wevm/wagmi/commit/cb707f01cbdcc62a70cf5c8a162d77948d6b6a56) Thanks [@tmm](https://github.com/tmm)! - Added [Sourcify](https://sourcify.dev) CLI plugin. + +## 0.1.6 + +### Patch Changes + +- [#1803](https://github.com/wevm/wagmi/pull/1803) [`09b13538`](https://github.com/wevm/wagmi/commit/09b13538abcde879034293cae39551c30cc81445) Thanks [@shotaronowhere](https://github.com/shotaronowhere)! - Swapped deprecated Arbitrum Rinkeby for Arbitrum Goerli URL for Etherscan Plugin. + +## 0.1.5 + +### Patch Changes + +- [#1788](https://github.com/wevm/wagmi/pull/1788) [`c3e16d82`](https://github.com/wevm/wagmi/commit/c3e16d82c9c39b8b1c2f3c51037e11d642a20cd6) Thanks [@tmm](https://github.com/tmm)! - Fixed CLI import + +## 0.1.4 + +### Patch Changes + +- [#1779](https://github.com/wevm/wagmi/pull/1779) [`97346750`](https://github.com/wevm/wagmi/commit/973467505dc2bb46198a3e9fe6072306170d24c0) Thanks [@tmm](https://github.com/tmm)! - Made `project` optional for Foundry plugin + +## 0.1.3 + +### Patch Changes + +- [#1754](https://github.com/wevm/wagmi/pull/1754) [`298728b5`](https://github.com/wevm/wagmi/commit/298728b5918fa15b6b5b082597204a268d4b01f1) Thanks [@tmm](https://github.com/tmm)! - Updated project resolution for Foundry and Hardhat plugins. + +- [#1738](https://github.com/wevm/wagmi/pull/1738) [`37c221d0`](https://github.com/wevm/wagmi/commit/37c221d0f4d175084e23a6b172d72f177bfa0c81) Thanks [@roninjin10](https://github.com/roninjin10)! - Added automatic Foundry config detection for artifacts directory. + +## 0.1.2 + +### Patch Changes + +- [#1743](https://github.com/wevm/wagmi/pull/1743) [`379315fa`](https://github.com/wevm/wagmi/commit/379315fa359c3118b5d200ec50db3812b0cdd984) Thanks [@kyscott18](https://github.com/kyscott18)! - Add celoscan to `etherscan` plugin + +## 0.1.1 + +### Patch Changes + +- [#1736](https://github.com/wevm/wagmi/pull/1736) [`7c43e431`](https://github.com/wevm/wagmi/commit/7c43e431e2eb970610cc6490cee6a4093655a683) Thanks [@tmm](https://github.com/tmm)! - Fixed generated address object key type. + +## 0.1.0 + +### Minor Changes + +- [#1732](https://github.com/wevm/wagmi/pull/1732) [`01e21897`](https://github.com/wevm/wagmi/commit/01e2189747a5c22dc758c6d719b4145adc2a643c) Thanks [@tmm](https://github.com/tmm)! - Initial release diff --git a/packages/cli/README.md b/packages/cli/README.md new file mode 100644 index 0000000000..640acb22d2 --- /dev/null +++ b/packages/cli/README.md @@ -0,0 +1,13 @@ +# @wagmi/cli + +Manage and generate code from Ethereum ABIs + +## Installation + +```bash +pnpm add @wagmi/cli +``` + +## Documentation + +For documentation and guides, visit [wagmi.sh](https://wagmi.sh). diff --git a/packages/cli/package.json b/packages/cli/package.json new file mode 100644 index 0000000000..f3848081e5 --- /dev/null +++ b/packages/cli/package.json @@ -0,0 +1,94 @@ +{ + "name": "@wagmi/cli", + "description": "Manage and generate code from Ethereum ABIs", + "version": "2.3.1", + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/wevm/wagmi.git", + "directory": "packages/cli" + }, + "scripts": { + "build": "pnpm run clean && pnpm run build:esm+types", + "build:esm+types": "tsc --project tsconfig.build.json --outDir ./dist/esm --declaration --declarationMap --declarationDir ./dist/types", + "check:types": "tsc --noEmit", + "clean": "rm -rf dist tsconfig.tsbuildinfo config plugins", + "dev": "bun src/cli.ts", + "test:build": "publint --strict && attw --pack --ignore-rules cjs-resolves-to-esm" + }, + "files": [ + "dist/**", + "!dist/**/*.tsbuildinfo", + "src/**/*.ts", + "!src/**/*.test.ts", + "!src/**/*.test-d.ts", + "/config", + "/plugins" + ], + "bin": { + "wagmi": "./dist/esm/cli.js" + }, + "sideEffects": false, + "type": "module", + "main": "./dist/esm/exports/index.js", + "types": "./dist/types/exports/index.d.ts", + "typings": "./dist/types/exports/index.d.ts", + "exports": { + ".": { + "types": "./dist/types/exports/index.d.ts", + "default": "./dist/esm/exports/index.js" + }, + "./config": { + "types": "./dist/types/exports/config.d.ts", + "default": "./dist/esm/exports/config.js" + }, + "./plugins": { + "types": "./dist/types/exports/plugins.d.ts", + "default": "./dist/esm/exports/plugins.js" + }, + "./package.json": "./package.json" + }, + "typesVersions": { + "*": { + "config": ["./dist/types/exports/config.d.ts"], + "plugins": ["./dist/types/exports/plugins.d.ts"] + } + }, + "peerDependencies": { + "typescript": ">=5.0.4" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + }, + "dependencies": { + "abitype": "^1.0.4", + "bundle-require": "^5.1.0", + "cac": "^6.7.14", + "change-case": "^5.4.4", + "chokidar": "4.0.3", + "dedent": "^1.5.3", + "dotenv": "^16.3.1", + "dotenv-expand": "^10.0.0", + "esbuild": "~0.27.0", + "escalade": "3.2.0", + "fdir": "^6.1.1", + "nanospinner": "1.2.2", + "pathe": "^2.0.3", + "picocolors": "^1.0.0", + "picomatch": "^4.0.2", + "prettier": "^3.0.3", + "viem": "2.x", + "zod": "^3.22.3" + }, + "devDependencies": { + "@types/dedent": "^0.7.2", + "@types/node": "^22.14.0", + "fixturez": "^1.1.0", + "msw": "^2.4.9" + }, + "contributors": ["awkweb.eth ", "jxom.eth "], + "funding": "https://github.com/sponsors/wevm", + "keywords": ["wagmi", "eth", "ethereum", "dapps", "wallet", "web3", "cli"] +} diff --git a/packages/cli/src/cli.ts b/packages/cli/src/cli.ts new file mode 100644 index 0000000000..551543bb2b --- /dev/null +++ b/packages/cli/src/cli.ts @@ -0,0 +1,53 @@ +#!/usr/bin/env node +import { cac } from 'cac' + +import { type Generate, generate } from './commands/generate.js' +import { type Init, init } from './commands/init.js' +import * as logger from './logger.js' +import { version } from './version.js' + +const cli = cac('wagmi') + +cli + .command('generate', 'generate code based on configuration') + .option('-c, --config ', '[string] path to config file') + .option('-r, --root ', '[string] root path to resolve config from') + .option('-w, --watch', '[boolean] watch for changes') + .example((name) => `${name} generate`) + .action(async (options: Generate) => { + await generate(options) + if (!options.watch) process.exit(0) + }) + +cli + .command('init', 'create configuration file') + .option('-c, --config ', '[string] path to config file') + .option('-r, --root ', '[string] root path to resolve config from') + .example((name) => `${name} init`) + .action(async (options: Init) => { + await init(options) + process.exit(0) + }) + +cli.help() +cli.version(version) + +void (async () => { + try { + process.title = 'node (wagmi)' + } catch {} + + try { + // Parse CLI args without running command + cli.parse(process.argv, { run: false }) + if (!cli.matchedCommand) { + if (cli.args.length === 0) { + if (!cli.options.help && !cli.options.version) cli.outputHelp() + } else throw new Error(`Unknown command: ${cli.args.join(' ')}`) + } + await cli.runMatchedCommand() + } catch (error) { + logger.error(`\n${(error as Error).message}`) + process.exit(1) + } +})() diff --git a/packages/cli/src/commands/generate.test.ts b/packages/cli/src/commands/generate.test.ts new file mode 100644 index 0000000000..91e4265216 --- /dev/null +++ b/packages/cli/src/commands/generate.test.ts @@ -0,0 +1,409 @@ +import { readFile } from 'node:fs/promises' +import dedent from 'dedent' +import { resolve } from 'pathe' +import { afterEach, beforeEach, expect, test, vi } from 'vitest' + +import { createFixture, typecheck, watchConsole } from '../../test/utils.js' +import { generate } from './generate.js' + +let console: ReturnType +beforeEach(() => { + console = watchConsole() + vi.useFakeTimers() + + const date = new Date(2023, 0, 30, 12) + vi.setSystemTime(date) +}) + +afterEach(() => { + vi.restoreAllMocks() + vi.useRealTimers() +}) + +test('generates output', async () => { + const { dir } = await createFixture({ + files: { + tsconfig: true, + 'wagmi.config.js': dedent` + export default { + out: 'generated.js', + contracts: [ + { + abi: [], + name: 'Foo', + }, + ], + } + `, + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await generate() + + expect(console.formatted).toMatchInlineSnapshot(` + "- Validating plugins + √ Validating plugins + - Resolving contracts + √ Resolving contracts + - Running plugins + √ Running plugins + - Writing to generated.js + √ Writing to generated.js" + `) +}) + +test('generates typescript output', async () => { + const { dir, paths } = await createFixture({ + files: { + tsconfig: true, + 'wagmi.config.ts': dedent` + export default { + out: 'generated.ts', + contracts: [ + { + abi: [], + name: 'Foo', + }, + ], + } + `, + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await generate() + + expect(console.formatted).toMatchInlineSnapshot(` + "- Validating plugins + √ Validating plugins + - Resolving contracts + √ Resolving contracts + - Running plugins + √ Running plugins + - Writing to generated.ts + √ Writing to generated.ts" + `) + await expect(typecheck(paths.tsconfig)).resolves.toMatchInlineSnapshot('""') +}) + +test('generates output with plugin', async () => { + const { dir } = await createFixture({ + files: { + tsconfig: true, + 'wagmi.config.ts': dedent` + export default { + out: 'generated.ts', + contracts: [ + { + abi: [], + name: 'Foo', + }, + ], + plugins: [ + { + name: 'Test', + async run({ contracts, isTypeScript, outputs }) { + return { + imports: '/* imports test */', + prepend: '/* prepend test */', + content: '/* content test */', + } + }, + }, + ], + } + `, + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await generate() + + expect(console.formatted).toMatchInlineSnapshot(` + "- Validating plugins + √ Validating plugins + - Resolving contracts + √ Resolving contracts + - Running plugins + √ Running plugins + - Writing to generated.ts + √ Writing to generated.ts" + `) + /* eslint-disable no-irregular-whitespace */ + await expect( + readFile(resolve(dir, 'generated.ts'), 'utf8'), + ).resolves.toMatchInlineSnapshot(` + "/* imports test */ + + /* prepend test */ + + ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + // Foo + ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + + export const fooAbi = [] as const + + ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + // Test + ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + + /* content test */ + " + `) + /* eslint-enable no-irregular-whitespace */ +}) + +test('behavior: invalid cli options', async () => { + const { dir } = await createFixture() + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect( + generate({ + // @ts-expect-error possible to pass untyped options through from cli + config: 1, + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [Error: Invalid option + - Expected string, received number at \`config\`] + `) +}) + +test('behavior: config not found', async () => { + const { dir } = await createFixture() + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(generate()).rejects.toThrowErrorMatchingInlineSnapshot( + '[Error: Config not found]', + ) +}) + +test('behavior: config not found for path', async () => { + const { dir } = await createFixture() + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + try { + await generate({ config: 'wagmi.config.js' }) + } catch (error) { + expect( + (error as Error).message.replace(dir, 'path/to/project'), + ).toMatchInlineSnapshot('"Config not found at wagmi.config.js"') + } +}) + +test('behavior: config out not unique', async () => { + const { dir } = await createFixture({ + files: { + 'wagmi.config.js': dedent` + export default [ + { + out: 'generated.ts', + contracts: [ + { + abi: [], + name: 'Foo', + }, + ] + }, + { + out: 'generated.ts', + contracts: [ + { + abi: [], + name: 'Foo', + }, + ], + }, + ] + `, + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(generate()).rejects.toThrowErrorMatchingInlineSnapshot( + `[Error: out "generated.ts" must be unique.]`, + ) +}) + +test('behavior: config contract names not unique', async () => { + const { dir } = await createFixture({ + files: { + 'wagmi.config.js': dedent` + export default { + out: 'generated.ts', + contracts: [ + { + abi: [], + name: 'Foo', + }, + { + abi: [], + name: 'Foo', + }, + ], + } + `, + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(generate()).rejects.toThrowErrorMatchingInlineSnapshot( + `[Error: Contract name "Foo" must be unique.]`, + ) +}) + +test('behavior: displays message if no contracts found', async () => { + const { dir } = await createFixture({ + files: { + 'wagmi.config.js': "export default { out: 'generated.ts' }", + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await generate() + + expect(console.formatted).toMatchInlineSnapshot( + ` + "- Validating plugins + √ Validating plugins + - Resolving contracts + × Resolving contracts + No contracts found." + `, + ) +}) + +test('behavior: throws when abi is invalid', async () => { + const { dir } = await createFixture({ + files: { + 'wagmi.config.js': dedent` + export default { + out: 'generated.ts', + contracts: [ + { + abi: [{ + type: 'function', + name: 'balanceOf', + stateMutability: 'view', + inputs: [{ type: 'address' }], + }], + name: 'Foo', + }, + ], + } + `, + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(generate()).rejects.toThrowErrorMatchingInlineSnapshot(` + [Error: Invalid ABI for contract "Foo" + - Invalid input at \`[0]\`] + `) +}) + +test('behavior: throws when address is invalid', async () => { + const { dir } = await createFixture({ + files: { + 'wagmi.config.js': dedent` + export default { + out: 'generated.ts', + contracts: [ + { + abi: [], + address: '0xfoo', + name: 'Foo', + }, + ], + } + `, + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(generate()).rejects.toThrowErrorMatchingInlineSnapshot(` + [Error: Invalid address for contract "Foo" + - Invalid address] + `) +}) + +test('behavior: throws when multichain address is invalid', async () => { + const { dir } = await createFixture({ + files: { + 'wagmi.config.js': dedent` + export default { + out: 'generated.ts', + contracts: [ + { + abi: [], + address: { + 1: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 5: '0xfoo', + }, + name: 'Foo', + }, + ], + } + `, + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(generate()).rejects.toThrowErrorMatchingInlineSnapshot(` + [Error: Invalid address for contract "Foo" + - Invalid address at \`5\`] + `) +}) + +test('behavior: displays message if using --watch flag without watchers configured', async () => { + const { dir } = await createFixture({ + files: { + 'wagmi.config.js': dedent` + export default { + out: 'generated.ts', + contracts: [ + { + abi: [], + name: 'Foo', + }, + ], + } + `, + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await generate({ watch: true }) + + expect(console.formatted).toMatchInlineSnapshot(` + "- Validating plugins + √ Validating plugins + - Resolving contracts + √ Resolving contracts + - Running plugins + √ Running plugins + - Writing to generated.ts + √ Writing to generated.ts + Used --watch flag, but no plugins are watching." + `) +}) + +test.todo('behavior: save config file logs change') +test.todo('behavior: updates on add file') +test.todo('behavior: updates on change file') +test.todo('behavior: updates on unlink file') +test.todo('behavior: runs watch command') +test.todo('behavior: shuts down watch on SIGINT/SIGTERM') diff --git a/packages/cli/src/commands/generate.ts b/packages/cli/src/commands/generate.ts new file mode 100644 index 0000000000..992a2e2923 --- /dev/null +++ b/packages/cli/src/commands/generate.ts @@ -0,0 +1,409 @@ +import { mkdir, writeFile } from 'node:fs/promises' +import { Abi as AbiSchema } from 'abitype/zod' +import { camelCase } from 'change-case' +import type { ChokidarOptions, FSWatcher } from 'chokidar' +import { watch } from 'chokidar' +import { default as dedent } from 'dedent' +import { basename, dirname, resolve } from 'pathe' +import pc from 'picocolors' +import { type Abi, type Address, getAddress } from 'viem' +import { z } from 'zod' + +import type { Contract, ContractConfig, Plugin, Watch } from '../config.js' +import { fromZodError } from '../errors.js' +import * as logger from '../logger.js' +import { findConfig } from '../utils/findConfig.js' +import { format } from '../utils/format.js' +import { getAddressDocString } from '../utils/getAddressDocString.js' +import { getIsUsingTypeScript } from '../utils/getIsUsingTypeScript.js' +import { resolveConfig } from '../utils/resolveConfig.js' + +const Generate = z.object({ + /** Path to config file */ + config: z.string().optional(), + /** Directory to search for config file */ + root: z.string().optional(), + /** Watch for file system changes to config and plugins */ + watch: z.boolean().optional(), +}) +export type Generate = z.infer + +export async function generate(options: Generate = {}) { + // Validate command line options + try { + await Generate.parseAsync(options) + } catch (error) { + if (error instanceof z.ZodError) + throw fromZodError(error, { prefix: 'Invalid option' }) + throw error + } + + // Get cli config file + const configPath = await findConfig(options) + if (!configPath) { + if (options.config) + throw new Error(`Config not found at ${pc.gray(options.config)}`) + throw new Error('Config not found') + } + + const resolvedConfigs = await resolveConfig({ configPath }) + const isTypeScript = await getIsUsingTypeScript() + + type Watcher = FSWatcher & { config?: Watch } + const watchers: Watcher[] = [] + const watchWriteDelay = 100 + const watchOptions = { + atomic: true, + // awaitWriteFinish: true, + ignoreInitial: true, + persistent: true, + } satisfies ChokidarOptions + + const outNames = new Set() + const isArrayConfig = Array.isArray(resolvedConfigs) + const configs = isArrayConfig ? resolvedConfigs : [resolvedConfigs] + for (const config of configs) { + if (isArrayConfig) + logger.log(`Using config ${pc.gray(basename(configPath))}`) + if (!config.out) throw new Error('out is required.') + if (outNames.has(config.out)) + throw new Error(`out "${config.out}" must be unique.`) + outNames.add(config.out) + + // Collect contracts and watch configs from plugins + const plugins = (config.plugins ?? []).map((x, i) => ({ + ...x, + id: `${x.name}-${i}`, + })) + const spinner = logger.spinner('Validating plugins') + spinner.start() + for (const plugin of plugins) { + await plugin.validate?.() + } + spinner.success() + + // Add plugin contracts to config contracts + const contractConfigs = config.contracts ?? [] + const watchConfigs: Watch[] = [] + spinner.start('Resolving contracts') + for (const plugin of plugins) { + if (plugin.watch) watchConfigs.push(plugin.watch) + if (plugin.contracts) { + const contracts = await plugin.contracts() + contractConfigs.push(...contracts) + } + } + + // Get contracts from config + const contractNames = new Set() + const contractMap = new Map() + for (const contractConfig of contractConfigs) { + if (contractNames.has(contractConfig.name)) + throw new Error( + `Contract name "${contractConfig.name}" must be unique.`, + ) + const contract = await getContract({ ...contractConfig, isTypeScript }) + contractMap.set(contract.name, contract) + + contractNames.add(contractConfig.name) + } + + // Sort contracts by name Ascending (low to high) as the key is `String` + const sortedAscContractMap = new Map([...contractMap].sort()) + const contracts = [...sortedAscContractMap.values()] + if (!contracts.length && !options.watch) { + spinner.error() + logger.warn('No contracts found.') + return + } + spinner.success() + + // Run plugins + const imports = [] + const prepend = [] + const content = [] + type Output = { + plugin: Pick + } & Awaited>> + const outputs: Output[] = [] + spinner.start('Running plugins') + for (const plugin of plugins) { + if (!plugin.run) continue + const result = await plugin.run({ + contracts, + isTypeScript, + outputs, + }) + outputs.push({ + plugin: { name: plugin.name }, + ...result, + }) + if (!result.imports && !result.prepend && !result.content) continue + content.push(getBannerContent({ name: plugin.name }), result.content) + result.imports && imports.push(result.imports) + result.prepend && prepend.push(result.prepend) + } + spinner.success() + + // Write output to file + spinner.start(`Writing to ${pc.gray(config.out)}`) + await writeContracts({ + content, + contracts, + imports, + prepend, + filename: config.out, + }) + spinner.success() + + if (options.watch) { + if (!watchConfigs.length) { + logger.log(pc.gray('Used --watch flag, but no plugins are watching.')) + continue + } + logger.log() + logger.log('Setting up watch process') + + // Watch for changes + let timeout: NodeJS.Timeout | null + for (const watchConfig of watchConfigs) { + const paths = + typeof watchConfig.paths === 'function' + ? await watchConfig.paths() + : watchConfig.paths + const watcher = watch(paths, watchOptions) + // Watch for changes to files, new files, and deleted files + watcher.on('all', async (event, path) => { + if (event !== 'change' && event !== 'add' && event !== 'unlink') + return + + let needsWrite = false + if (event === 'change' || event === 'add') { + const eventFn = + event === 'change' ? watchConfig.onChange : watchConfig.onAdd + const config = await eventFn?.(path) + if (!config) return + const contract = await getContract({ ...config, isTypeScript }) + contractMap.set(contract.name, contract) + needsWrite = true + } else if (event === 'unlink') { + const name = await watchConfig.onRemove?.(path) + if (!name) return + contractMap.delete(name) + needsWrite = true + } + + // Debounce writes + if (needsWrite) { + if (timeout) clearTimeout(timeout) + timeout = setTimeout(async () => { + timeout = null + // Sort contracts by name Ascending (low to high) as the key is `String` + const sortedAscContractMap = new Map([...contractMap].sort()) + const contracts = [...sortedAscContractMap.values()] + const imports = [] + const prepend = [] + const content = [] + const outputs: Output[] = [] + for (const plugin of plugins) { + if (!plugin.run) continue + const result = await plugin.run({ + contracts, + isTypeScript, + outputs, + }) + outputs.push({ + plugin: { name: plugin.name }, + ...result, + }) + if (!result.imports && !result.prepend && !result.content) + continue + content.push( + getBannerContent({ name: plugin.name }), + result.content, + ) + result.imports && imports.push(result.imports) + result.prepend && prepend.push(result.prepend) + } + + const spinner = logger.spinner( + `Writing to ${pc.gray(config.out)}`, + ) + spinner.start() + await writeContracts({ + content, + contracts, + imports, + prepend, + filename: config.out, + }) + spinner.success() + }, watchWriteDelay) + needsWrite = false + } + }) + + // Run parallel command on ready + if (watchConfig.command) + watcher.on('ready', async () => { + await watchConfig.command?.() + }) + ;(watcher as Watcher).config = watchConfig + watchers.push(watcher) + } + } + } + + if (!watchers.length) return + + // Watch `@wagmi/cli` config file for changes + const watcher = watch(configPath).on('change', async (path) => { + logger.log( + `> Found a change to config ${pc.gray( + basename(path), + )}. Restart process for changes to take effect.`, + ) + }) + watchers.push(watcher) + + // Display message and close watchers on exit + process.once('SIGINT', shutdown) + process.once('SIGTERM', shutdown) + async function shutdown() { + logger.log() + logger.log('Shutting down watch process') + const promises = [] + for (const watcher of watchers) { + if (watcher.config?.onClose) promises.push(watcher.config?.onClose?.()) + promises.push(watcher.close()) + } + await Promise.allSettled(promises) + process.exit(0) + } +} + +async function getContract({ + abi, + address, + name, + isTypeScript, +}: ContractConfig & { isTypeScript: boolean }): Promise { + const constAssertion = isTypeScript ? ' as const' : '' + const abiName = `${camelCase(name)}Abi` + try { + abi = (await AbiSchema.parseAsync(abi)) as Abi + } catch (error) { + if (error instanceof z.ZodError) + throw fromZodError(error, { + prefix: `Invalid ABI for contract "${name}"`, + }) + throw error + } + const docString = + typeof address === 'object' + ? dedent`\n + /** + ${getAddressDocString({ address })} + */ + ` + : '' + let content = dedent` + ${getBannerContent({ name })} + + ${docString} + export const ${abiName} = ${JSON.stringify(abi)}${constAssertion} + ` + + let meta: Contract['meta'] = { abiName } + if (address) { + let resolvedAddress: Address | Record + try { + const Address = z + .string() + .regex(/^0x[a-fA-F0-9]{40}$/, { message: 'Invalid address' }) + .transform((val) => getAddress(val)) as z.ZodType
+ const MultiChainAddress = z.record(z.string(), Address) + const AddressSchema = z.union([Address, MultiChainAddress]) + resolvedAddress = await AddressSchema.parseAsync(address) + } catch (error) { + if (error instanceof z.ZodError) + throw fromZodError(error, { + prefix: `Invalid address for contract "${name}"`, + }) + throw error + } + + const addressName = `${camelCase(name)}Address` + const configName = `${camelCase(name)}Config` + meta = { + ...meta, + addressName, + configName, + } + + const addressContent = + typeof resolvedAddress === 'string' + ? JSON.stringify(resolvedAddress) + : // Remove quotes from chain id key + JSON.stringify(resolvedAddress, null, 2).replace(/"(\d*)":/gm, '$1:') + content = dedent` + ${content} + + ${docString} + export const ${addressName} = ${addressContent}${constAssertion} + + ${docString} + export const ${configName} = { address: ${addressName}, abi: ${abiName} }${constAssertion} + ` + } + + return { abi, address, content, meta, name } +} + +async function writeContracts({ + content, + contracts, + imports, + prepend, + filename, +}: { + content: string[] + contracts: Contract[] + imports: string[] + prepend: string[] + filename: string +}) { + // Assemble code + let code = dedent` + ${imports.join('\n\n') ?? ''} + + ${prepend.join('\n\n') ?? ''} + ` + for (const contract of contracts) { + code = dedent` + ${code} + + ${contract.content} + ` + } + code = dedent` + ${code} + + ${content.join('\n\n') ?? ''} + ` + + // Format and write output + const cwd = process.cwd() + const outPath = resolve(cwd, filename) + await mkdir(dirname(outPath), { recursive: true }) + const formatted = await format(code) + await writeFile(outPath, formatted) +} + +function getBannerContent({ name }: { name: string }) { + return dedent` + ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + // ${name} + ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + ` +} diff --git a/packages/cli/src/commands/init.test.ts b/packages/cli/src/commands/init.test.ts new file mode 100644 index 0000000000..ed4a1d1644 --- /dev/null +++ b/packages/cli/src/commands/init.test.ts @@ -0,0 +1,189 @@ +import { existsSync } from 'node:fs' +import { mkdir, readFile } from 'node:fs/promises' +import { resolve } from 'pathe' +import { afterEach, beforeEach, expect, test, vi } from 'vitest' + +import { createFixture, watchConsole } from '../../test/utils.js' +import { defaultConfig } from '../config.js' +import { init } from './init.js' + +let console: ReturnType +beforeEach(() => { + console = watchConsole() +}) + +afterEach(() => { + vi.restoreAllMocks() +}) + +test('creates config file', async () => { + const { dir } = await createFixture() + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + const configFile = await init() + + expect(existsSync(configFile)).toBeTruthy() + expect(await readFile(configFile, 'utf-8')).toMatchInlineSnapshot(` + "// @ts-check + + /** @type {import('@wagmi/cli').Config} */ + export default { + out: 'src/generated.js', + contracts: [], + plugins: [], + } + " + `) + expect( + console.formatted.replaceAll(dir, 'path/to/project'), + ).toMatchInlineSnapshot(` + "- Creating config + √ Creating config + Config created at wagmi.config.js" + `) +}) + +test('parameters: config', async () => { + const { dir } = await createFixture() + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + const configFile = await init({ + config: 'foo.config.ts', + }) + + expect(existsSync(configFile)).toBeTruthy() + expect(await readFile(configFile, 'utf-8')).toMatchInlineSnapshot(` + "// @ts-check + + /** @type {import('@wagmi/cli').Config} */ + export default { + out: 'src/generated.js', + contracts: [], + plugins: [], + } + " + `) + expect( + console.formatted.replaceAll(dir, 'path/to/project'), + ).toMatchInlineSnapshot(` + "- Creating config + √ Creating config + Config created at foo.config.ts" + `) +}) + +test('parameters: content', async () => { + const { dir } = await createFixture({ + files: { + 'tsconfig.json': '{}', + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + const configFile = await init({ + content: { + ...defaultConfig, + out: 'foo/bar/baz.ts', + }, + }) + + expect(existsSync(configFile)).toBeTruthy() + expect(await readFile(configFile, 'utf-8')).toMatchInlineSnapshot(` + "import { defineConfig } from '@wagmi/cli' + + export default defineConfig({ + out: 'foo/bar/baz.ts', + contracts: [], + plugins: [], + }) + " + `) + expect( + console.formatted.replaceAll(dir, 'path/to/project'), + ).toMatchInlineSnapshot(` + "- Creating config + √ Creating config + Config created at wagmi.config.ts" + `) +}) + +test('parameters: root', async () => { + const { dir } = await createFixture() + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + mkdir(resolve(dir, 'foo')) + + const configFile = await init({ + root: 'foo/', + }) + + expect(existsSync(configFile)).toBeTruthy() + expect(await readFile(configFile, 'utf-8')).toMatchInlineSnapshot(` + "// @ts-check + + /** @type {import('@wagmi/cli').Config} */ + export default { + out: 'src/generated.js', + contracts: [], + plugins: [], + } + " + `) + expect( + console.formatted.replaceAll(dir, 'path/to/project'), + ).toMatchInlineSnapshot(` + "- Creating config + √ Creating config + Config created at foo/wagmi.config.js" + `) +}) + +test('behavior: creates config file in TypeScript format', async () => { + const { dir } = await createFixture({ + files: { + 'tsconfig.json': '{}', + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + const configFile = await init() + + expect(existsSync(configFile)).toBeTruthy() + expect(await readFile(configFile, 'utf-8')).toMatchInlineSnapshot(` + "import { defineConfig } from '@wagmi/cli' + + export default defineConfig({ + out: 'src/generated.ts', + contracts: [], + plugins: [], + }) + " + `) + expect( + console.formatted.replaceAll(dir, 'path/to/project'), + ).toMatchInlineSnapshot(` + "- Creating config + √ Creating config + Config created at wagmi.config.ts" + `) +}) + +test('behavior: displays config file location when config exists', async () => { + const { dir } = await createFixture({ + files: { + 'wagmi.config.ts': '', + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + const configFile = await init() + + expect( + console.formatted.replaceAll(configFile, 'path/to/project/wagmi.config.ts'), + ).toMatchInlineSnapshot('"Config already exists at wagmi.config.ts"') +}) diff --git a/packages/cli/src/commands/init.ts b/packages/cli/src/commands/init.ts new file mode 100644 index 0000000000..ce4e5b32d9 --- /dev/null +++ b/packages/cli/src/commands/init.ts @@ -0,0 +1,95 @@ +import { writeFile } from 'node:fs/promises' +import dedent from 'dedent' +import { relative, resolve } from 'pathe' +import pc from 'picocolors' +import { z } from 'zod' + +import { type Config, defaultConfig } from '../config.js' +import { fromZodError } from '../errors.js' +import * as logger from '../logger.js' +import { findConfig } from '../utils/findConfig.js' +import { format } from '../utils/format.js' +import { getIsUsingTypeScript } from '../utils/getIsUsingTypeScript.js' + +export type Init = { + /** Path to config file */ + config?: string + /** Watch for file system changes to config and plugins */ + content?: Config + /** Directory to init config file */ + root?: string +} + +const Init = z.object({ + config: z.string().optional(), + content: z.object({}).optional(), + root: z.string().optional(), +}) + +export async function init(options: Init = {}) { + // Validate command line options + try { + await Init.parseAsync(options) + } catch (error) { + if (error instanceof z.ZodError) + throw fromZodError(error, { prefix: 'Invalid option' }) + throw error + } + + // Check for existing config file + const configPath = await findConfig(options) + if (configPath) { + logger.info( + `Config already exists at ${pc.gray( + relative(process.cwd(), configPath), + )}`, + ) + return configPath + } + + const spinner = logger.spinner('Creating config') + spinner.start() + // Check if project is using TypeScript + const isUsingTypeScript = await getIsUsingTypeScript() + const rootDir = resolve(options.root || process.cwd()) + let outPath: string + if (options.config) { + outPath = resolve(rootDir, options.config) + } else { + const extension = isUsingTypeScript ? 'ts' : 'js' + outPath = resolve(rootDir, `wagmi.config.${extension}`) + } + + let content: string + if (isUsingTypeScript) { + const config = options.content ?? defaultConfig + content = dedent(` + import { defineConfig } from '@wagmi/cli' + + export default defineConfig(${JSON.stringify(config)}) + `) + } else { + const config = options.content ?? { + ...defaultConfig, + out: defaultConfig.out.replace('.ts', '.js'), + } + content = dedent(` + // @ts-check + + /** @type {import('@wagmi/cli').Config} */ + export default ${JSON.stringify(config, null, 2).replace( + /"(\d*)":/gm, + '$1:', + )} + `) + } + + const formatted = await format(content) + await writeFile(outPath, formatted) + spinner.success() + logger.success( + `Config created at ${pc.gray(relative(process.cwd(), outPath))}`, + ) + + return outPath +} diff --git a/packages/cli/src/config.test.ts b/packages/cli/src/config.test.ts new file mode 100644 index 0000000000..f95d7cb6d3 --- /dev/null +++ b/packages/cli/src/config.test.ts @@ -0,0 +1,39 @@ +import { expect, test, vi } from 'vitest' + +import { type Config, defineConfig } from './config.js' + +test('object', () => { + const config: Config = { + contracts: [], + out: 'wagmi.ts', + plugins: [], + } + expect(defineConfig(config)).toEqual(config) +}) + +test('array', () => { + const config: Config = { + contracts: [], + out: 'wagmi.ts', + plugins: [], + } + expect(defineConfig([config, config])).toEqual([config, config]) +}) + +test('function', () => { + const config = vi.fn().mockImplementation(() => ({ + contracts: [], + out: 'wagmi.ts', + plugins: [], + })) + expect(defineConfig(config)).toEqual(config) +}) + +test('async function', () => { + const config = vi.fn().mockImplementation(async () => ({ + contracts: [], + out: 'wagmi.ts', + plugins: [], + })) + expect(defineConfig(config)).toEqual(config) +}) diff --git a/packages/cli/src/config.ts b/packages/cli/src/config.ts new file mode 100644 index 0000000000..146a1e3424 --- /dev/null +++ b/packages/cli/src/config.ts @@ -0,0 +1,121 @@ +import type { Abi, Address } from 'viem' + +import type { Compute, MaybeArray, MaybePromise } from './types.js' + +export type ContractConfig< + chainId extends number = number, + requiredChainId extends number | undefined = undefined, +> = { + /** + * Contract ABI + */ + abi: Abi + /** + * Contract address or addresses. + * + * Accepts an object `{ [chainId]: address }` to support multiple chains. + * + * @example + * '0x314159265dd8dbb310642f98f50c066173c1259b' + * + * @example + * { + * 1: '0x314159265dd8dbb310642f98f50c066173c1259b', + * 5: '0x112234455c3a32fd11230c42e7bccd4a84e02010', + * } + */ + address?: + | Address + | (requiredChainId extends number + ? Record & Partial> + : Record) + | undefined + /** + * Name of contract. + */ + name: string +} + +export type Contract = Compute< + ContractConfig & { + /** Generated string content */ + content: string + /** Meta info about contract */ + meta: { + abiName: string + addressName?: string | undefined + configName?: string | undefined + } + } +> + +export type Watch = { + /** Command to run along with watch process */ + command?: (() => MaybePromise) | undefined + /** Paths to watch for changes. */ + paths: string[] | (() => MaybePromise) + /** Callback that fires when file is added */ + onAdd?: + | ((path: string) => MaybePromise) + | undefined + /** Callback that fires when file changes */ + onChange: (path: string) => MaybePromise + /** Callback that fires when watcher is shutdown */ + onClose?: (() => MaybePromise) | undefined + /** Callback that fires when file is removed */ + onRemove?: ((path: string) => MaybePromise) | undefined +} + +export type Plugin = { + /** Contracts provided by plugin */ + contracts?: (() => MaybePromise) | undefined + /** Plugin name */ + name: string + /** Run plugin logic */ + run?: + | ((config: { + /** All resolved contracts from config and plugins */ + contracts: Contract[] + /** Whether TypeScript is detected in project */ + isTypeScript: boolean + /** Previous plugin outputs */ + outputs: readonly { + plugin: Pick + imports?: string + prepend?: string + content: string + }[] + }) => MaybePromise<{ + imports?: string + prepend?: string + content: string + }>) + | undefined + /** + * Validate plugin configuration or other @wagmi/cli settings require for plugin. + */ + validate?: (() => MaybePromise) | undefined + /** File system watch config */ + watch?: Watch | undefined +} + +export type Config = { + /** Contracts to use in commands */ + contracts?: ContractConfig[] | undefined + /** Output file path */ + out: string + /** Plugins to run */ + plugins?: Plugin[] | undefined +} + +export function defineConfig( + config: MaybeArray | (() => MaybePromise>), +) { + return config +} + +export const defaultConfig = { + out: 'src/generated.ts', + contracts: [], + plugins: [], +} satisfies Config diff --git a/packages/cli/src/errors.ts b/packages/cli/src/errors.ts new file mode 100644 index 0000000000..6ef37093fc --- /dev/null +++ b/packages/cli/src/errors.ts @@ -0,0 +1,57 @@ +import type { z } from 'zod' + +class ValidationError extends Error { + details: Zod.ZodIssue[] + + constructor( + message: string, + options: { + details: Zod.ZodIssue[] + }, + ) { + super(message) + this.details = options.details + } +} + +// From https://github.com/causaly/zod-validation-error +export function fromZodError( + zError: z.ZodError, + { + maxIssuesInMessage = 99, + issueSeparator = '\n- ', + prefixSeparator = '\n- ', + prefix = 'Validation Error', + }: { + maxIssuesInMessage?: number + issueSeparator?: string + prefixSeparator?: string + prefix?: string + } = {}, +): ValidationError { + function joinPath(arr: Array): string { + return arr.reduce((acc, value) => { + if (typeof value === 'number') return `${acc}[${value}]` + const separator = acc === '' ? '' : '.' + return acc + separator + value + }, '') + } + + const reason = zError.errors + // limit max number of issues printed in the reason section + .slice(0, maxIssuesInMessage) + // format error message + .map((issue) => { + const { message, path } = issue + if (path.length > 0) return `${message} at \`${joinPath(path)}\`` + return message + }) + // concat as string + .join(issueSeparator) + + const message = reason ? [prefix, reason].join(prefixSeparator) : prefix + + return new ValidationError(message, { + details: zError.errors, + }) +} diff --git a/packages/cli/src/exports/config.test.ts b/packages/cli/src/exports/config.test.ts new file mode 100644 index 0000000000..c833780ffc --- /dev/null +++ b/packages/cli/src/exports/config.test.ts @@ -0,0 +1,12 @@ +import { expect, test } from 'vitest' + +import * as Exports from './config.js' + +test('exports', () => { + expect(Object.keys(Exports)).toMatchInlineSnapshot(` + [ + "defineConfig", + "defaultConfig", + ] + `) +}) diff --git a/packages/cli/src/exports/config.ts b/packages/cli/src/exports/config.ts new file mode 100644 index 0000000000..b3c4a83ba4 --- /dev/null +++ b/packages/cli/src/exports/config.ts @@ -0,0 +1,10 @@ +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { + type ContractConfig, + type Contract, + type Watch, + type Plugin, + type Config, + defineConfig, + defaultConfig, +} from '../config.js' diff --git a/packages/cli/src/exports/index.test-d.ts b/packages/cli/src/exports/index.test-d.ts new file mode 100644 index 0000000000..b056d56358 --- /dev/null +++ b/packages/cli/src/exports/index.test-d.ts @@ -0,0 +1,4 @@ +import { expectTypeOf } from 'vitest' + +// noop test because vitest typecheck fails unless each workspace project has type test +expectTypeOf(1).toEqualTypeOf() diff --git a/packages/cli/src/exports/index.test.ts b/packages/cli/src/exports/index.test.ts new file mode 100644 index 0000000000..2da78e8da1 --- /dev/null +++ b/packages/cli/src/exports/index.test.ts @@ -0,0 +1,14 @@ +import { expect, test } from 'vitest' + +import * as Exports from './index.js' + +test('exports', () => { + expect(Object.keys(Exports)).toMatchInlineSnapshot(` + [ + "defineConfig", + "logger", + "loadEnv", + "version", + ] + `) +}) diff --git a/packages/cli/src/exports/index.ts b/packages/cli/src/exports/index.ts new file mode 100644 index 0000000000..1c5e624df6 --- /dev/null +++ b/packages/cli/src/exports/index.ts @@ -0,0 +1,14 @@ +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { + defineConfig, + type Config, + type ContractConfig, + type Plugin, +} from '../config.js' + +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * as logger from '../logger.js' + +export { loadEnv } from '../utils/loadEnv.js' + +export { version } from '../version.js' diff --git a/packages/cli/src/exports/plugins.test.ts b/packages/cli/src/exports/plugins.test.ts new file mode 100644 index 0000000000..4d7b5a97cd --- /dev/null +++ b/packages/cli/src/exports/plugins.test.ts @@ -0,0 +1,20 @@ +import { expect, test } from 'vitest' + +import * as Exports from './plugins.js' + +test('exports', () => { + expect(Object.keys(Exports)).toMatchInlineSnapshot(` + [ + "actions", + "blockExplorer", + "etherscan", + "fetch", + "foundry", + "foundryDefaultExcludes", + "hardhat", + "hardhatDefaultExcludes", + "react", + "sourcify", + ] + `) +}) diff --git a/packages/cli/src/exports/plugins.ts b/packages/cli/src/exports/plugins.ts new file mode 100644 index 0000000000..a289b5c576 --- /dev/null +++ b/packages/cli/src/exports/plugins.ts @@ -0,0 +1,27 @@ +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { actions, type ActionsConfig } from '../plugins/actions.js' + +export { + blockExplorer, + type BlockExplorerConfig, +} from '../plugins/blockExplorer.js' + +export { etherscan, type EtherscanConfig } from '../plugins/etherscan.js' + +export { fetch, type FetchConfig } from '../plugins/fetch.js' + +export { + foundry, + foundryDefaultExcludes, + type FoundryConfig, +} from '../plugins/foundry.js' + +export { + hardhat, + hardhatDefaultExcludes, + type HardhatConfig, +} from '../plugins/hardhat.js' + +export { react, type ReactConfig } from '../plugins/react.js' + +export { sourcify, type SourcifyConfig } from '../plugins/sourcify.js' diff --git a/packages/cli/src/logger.test.ts b/packages/cli/src/logger.test.ts new file mode 100644 index 0000000000..7338c3bb14 --- /dev/null +++ b/packages/cli/src/logger.test.ts @@ -0,0 +1,32 @@ +import { afterEach, expect, test, vi } from 'vitest' + +import { watchConsole } from '../test/utils.js' + +import * as logger from './logger.js' + +const mockLog = vi.fn() + +afterEach(() => { + vi.restoreAllMocks() +}) + +test.each(['success', 'info', 'log', 'warn', 'error'])('%s()', (level) => { + const spy = vi.spyOn(logger, level as any) + spy.mockImplementation(mockLog) + const loggerFn = (logger as any)[level] + loggerFn(level) + expect(spy).toHaveBeenCalledWith(level) +}) + +test('spinner', () => { + const console = watchConsole() + const spinner = logger.spinner('start') + spinner.start() + spinner.success('success') + spinner.error('error') + expect(console.formatted).toMatchInlineSnapshot(` + "- start + √ success + × error" + `) +}) diff --git a/packages/cli/src/logger.ts b/packages/cli/src/logger.ts new file mode 100644 index 0000000000..b56fb9728b --- /dev/null +++ b/packages/cli/src/logger.ts @@ -0,0 +1,37 @@ +import { format as utilFormat } from 'node:util' +import { createSpinner } from 'nanospinner' +import pc from 'picocolors' + +function format(args: any[]) { + return utilFormat(...args) + .split('\n') + .join('\n') +} + +export function success(...args: any[]) { + // biome-ignore lint/suspicious/noConsoleLog: console.log is used for logging + console.log(pc.green(format(args))) +} + +export function info(...args: any[]) { + console.info(pc.blue(format(args))) +} + +export function log(...args: any[]) { + // biome-ignore lint/suspicious/noConsoleLog: console.log is used for logging + console.log(pc.white(format(args))) +} + +export function warn(...args: any[]) { + console.warn(pc.yellow(format(args))) +} + +export function error(...args: any[]) { + console.error(pc.red(format(args))) +} + +export function spinner(text: string) { + return createSpinner(text, { + color: 'yellow', + }) +} diff --git a/packages/cli/src/plugins/__fixtures__/foundry/.gitignore b/packages/cli/src/plugins/__fixtures__/foundry/.gitignore new file mode 100644 index 0000000000..3269660cc7 --- /dev/null +++ b/packages/cli/src/plugins/__fixtures__/foundry/.gitignore @@ -0,0 +1,11 @@ +# Compiler files +cache/ +out/ + +# Ignores development broadcast logs +!/broadcast +/broadcast/*/31337/ +/broadcast/**/dry-run/ + +# Dotenv file +.env diff --git a/packages/cli/src/plugins/__fixtures__/foundry/src/Counter.sol b/packages/cli/src/plugins/__fixtures__/foundry/src/Counter.sol new file mode 100644 index 0000000000..5242caa433 --- /dev/null +++ b/packages/cli/src/plugins/__fixtures__/foundry/src/Counter.sol @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity ^0.8.13; + +contract Counter { + uint256 public number; + + function setNumber(uint256 newNumber) public { + number = newNumber; + } + + function increment() public { + number++; + } +} diff --git a/packages/cli/src/plugins/__fixtures__/foundry/src/Foo.sol b/packages/cli/src/plugins/__fixtures__/foundry/src/Foo.sol new file mode 100644 index 0000000000..f478736520 --- /dev/null +++ b/packages/cli/src/plugins/__fixtures__/foundry/src/Foo.sol @@ -0,0 +1,11 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity ^0.8.13; + +contract Foo { + string public bar; + + function setFoo(string memory baz) public { + bar = baz; + } +} + diff --git a/packages/cli/src/plugins/__fixtures__/hardhat/.gitignore b/packages/cli/src/plugins/__fixtures__/hardhat/.gitignore new file mode 100644 index 0000000000..85d361b914 --- /dev/null +++ b/packages/cli/src/plugins/__fixtures__/hardhat/.gitignore @@ -0,0 +1,10 @@ +node_modules +.env +coverage +coverage.json +typechain +typechain-types + +# Hardhat files +cache +artifacts \ No newline at end of file diff --git a/packages/cli/src/plugins/__fixtures__/hardhat/contracts/Counter.sol b/packages/cli/src/plugins/__fixtures__/hardhat/contracts/Counter.sol new file mode 100644 index 0000000000..5242caa433 --- /dev/null +++ b/packages/cli/src/plugins/__fixtures__/hardhat/contracts/Counter.sol @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity ^0.8.13; + +contract Counter { + uint256 public number; + + function setNumber(uint256 newNumber) public { + number = newNumber; + } + + function increment() public { + number++; + } +} diff --git a/packages/cli/src/plugins/__fixtures__/hardhat/contracts/Foo.sol b/packages/cli/src/plugins/__fixtures__/hardhat/contracts/Foo.sol new file mode 100644 index 0000000000..699a63ce0f --- /dev/null +++ b/packages/cli/src/plugins/__fixtures__/hardhat/contracts/Foo.sol @@ -0,0 +1,10 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity ^0.8.13; + +contract Foo { + string public bar; + + function setFoo(string memory baz) public { + bar = baz; + } +} diff --git a/packages/cli/src/plugins/__fixtures__/hardhat/hardhat.config.js b/packages/cli/src/plugins/__fixtures__/hardhat/hardhat.config.js new file mode 100644 index 0000000000..c8126eedfa --- /dev/null +++ b/packages/cli/src/plugins/__fixtures__/hardhat/hardhat.config.js @@ -0,0 +1,3 @@ +module.exports = { + solidity: '0.8.17', +} diff --git a/packages/cli/src/plugins/__fixtures__/hardhat/package.json b/packages/cli/src/plugins/__fixtures__/hardhat/package.json new file mode 100644 index 0000000000..85c9ffb7bd --- /dev/null +++ b/packages/cli/src/plugins/__fixtures__/hardhat/package.json @@ -0,0 +1,7 @@ +{ + "name": "hardhat-fixture", + "private": true, + "devDependencies": { + "hardhat": "^2.22.3" + } +} diff --git a/packages/cli/src/plugins/__snapshots__/blockExplorer.test.ts.snap b/packages/cli/src/plugins/__snapshots__/blockExplorer.test.ts.snap new file mode 100644 index 0000000000..2abd351741 --- /dev/null +++ b/packages/cli/src/plugins/__snapshots__/blockExplorer.test.ts.snap @@ -0,0 +1,736 @@ +// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html + +exports[`fetches ABI 1`] = ` +[ + { + "abi": [ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "approved", + "type": "address", + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "Approval", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "operator", + "type": "address", + }, + { + "indexed": false, + "internalType": "bool", + "name": "approved", + "type": "bool", + }, + ], + "name": "ApprovalForAll", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "Transfer", + "type": "event", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "approve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + }, + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "getApproved", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "internalType": "address", + "name": "operator", + "type": "address", + }, + ], + "name": "isApprovedForAll", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "ownerOf", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes", + }, + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "operator", + "type": "address", + }, + { + "internalType": "bool", + "name": "approved", + "type": "bool", + }, + ], + "name": "setApprovalForAll", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "interfaceId", + "type": "bytes4", + }, + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "tokenURI", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "pure", + "type": "function", + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "transferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "address": "0xaf0326d92b97df1221759476b072abfd8084f9be", + "name": "WagmiMintExample", + }, +] +`; + +exports[`fetches ABI with multichain deployment 1`] = ` +[ + { + "abi": [ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "approved", + "type": "address", + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "Approval", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "operator", + "type": "address", + }, + { + "indexed": false, + "internalType": "bool", + "name": "approved", + "type": "bool", + }, + ], + "name": "ApprovalForAll", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "Transfer", + "type": "event", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "approve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + }, + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "getApproved", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "internalType": "address", + "name": "operator", + "type": "address", + }, + ], + "name": "isApprovedForAll", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "ownerOf", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes", + }, + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "operator", + "type": "address", + }, + { + "internalType": "bool", + "name": "approved", + "type": "bool", + }, + ], + "name": "setApprovalForAll", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "interfaceId", + "type": "bytes4", + }, + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "tokenURI", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "pure", + "type": "function", + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "transferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "address": { + "1": "0xaf0326d92b97df1221759476b072abfd8084f9be", + "10": "0xaf0326d92b97df1221759476b072abfd8084f9be", + }, + "name": "WagmiMintExample", + }, +] +`; diff --git a/packages/cli/src/plugins/__snapshots__/etherscan.test.ts.snap b/packages/cli/src/plugins/__snapshots__/etherscan.test.ts.snap new file mode 100644 index 0000000000..e03ee30f81 --- /dev/null +++ b/packages/cli/src/plugins/__snapshots__/etherscan.test.ts.snap @@ -0,0 +1,1238 @@ +// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html + +exports[`fetches ABI 1`] = ` +[ + { + "abi": [ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "approved", + "type": "address", + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "Approval", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "operator", + "type": "address", + }, + { + "indexed": false, + "internalType": "bool", + "name": "approved", + "type": "bool", + }, + ], + "name": "ApprovalForAll", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "Transfer", + "type": "event", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "approve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + }, + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "getApproved", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "internalType": "address", + "name": "operator", + "type": "address", + }, + ], + "name": "isApprovedForAll", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "ownerOf", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes", + }, + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "operator", + "type": "address", + }, + { + "internalType": "bool", + "name": "approved", + "type": "bool", + }, + ], + "name": "setApprovalForAll", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "interfaceId", + "type": "bytes4", + }, + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "tokenURI", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "pure", + "type": "function", + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "transferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "address": { + "1": "0xaf0326d92b97df1221759476b072abfd8084f9be", + }, + "name": "WagmiMintExample", + }, +] +`; + +exports[`fetches ABI with multichain deployment 1`] = ` +[ + { + "abi": [ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "approved", + "type": "address", + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "Approval", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "operator", + "type": "address", + }, + { + "indexed": false, + "internalType": "bool", + "name": "approved", + "type": "bool", + }, + ], + "name": "ApprovalForAll", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "Transfer", + "type": "event", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "approve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + }, + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "getApproved", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "internalType": "address", + "name": "operator", + "type": "address", + }, + ], + "name": "isApprovedForAll", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "ownerOf", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes", + }, + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "operator", + "type": "address", + }, + { + "internalType": "bool", + "name": "approved", + "type": "bool", + }, + ], + "name": "setApprovalForAll", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "interfaceId", + "type": "bytes4", + }, + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "tokenURI", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "pure", + "type": "function", + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "transferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "address": { + "1": "0xaf0326d92b97df1221759476b072abfd8084f9be", + "10": "0xaf0326d92b97df1221759476b072abfd8084f9be", + }, + "name": "WagmiMintExample", + }, +] +`; + +exports[`tryFetchProxyImplementation: fetches ABI 1`] = ` +[ + { + "abi": [ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "approved", + "type": "address", + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "Approval", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "operator", + "type": "address", + }, + { + "indexed": false, + "internalType": "bool", + "name": "approved", + "type": "bool", + }, + ], + "name": "ApprovalForAll", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "Transfer", + "type": "event", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "approve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + }, + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "getApproved", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "internalType": "address", + "name": "operator", + "type": "address", + }, + ], + "name": "isApprovedForAll", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "ownerOf", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes", + }, + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "operator", + "type": "address", + }, + { + "internalType": "bool", + "name": "approved", + "type": "bool", + }, + ], + "name": "setApprovalForAll", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "interfaceId", + "type": "bytes4", + }, + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "tokenURI", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "pure", + "type": "function", + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "transferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "address": { + "1": "0xaf0326d92b97df1221759476b072abfd8084f9be", + }, + "name": "WagmiMintExample", + }, +] +`; + +exports[`tryFetchProxyImplementation: fetches implementation ABI 1`] = ` +[ + { + "abi": [ + { + "constant": false, + "inputs": [ + { + "name": "newImplementation", + "type": "address", + }, + ], + "name": "upgradeTo", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function", + }, + { + "constant": false, + "inputs": [ + { + "name": "newImplementation", + "type": "address", + }, + { + "name": "data", + "type": "bytes", + }, + ], + "name": "upgradeToAndCall", + "outputs": [], + "payable": true, + "stateMutability": "payable", + "type": "function", + }, + { + "constant": true, + "inputs": [], + "name": "implementation", + "outputs": [ + { + "name": "", + "type": "address", + }, + ], + "payable": false, + "stateMutability": "view", + "type": "function", + }, + { + "constant": false, + "inputs": [ + { + "name": "newAdmin", + "type": "address", + }, + ], + "name": "changeAdmin", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function", + }, + { + "constant": true, + "inputs": [], + "name": "admin", + "outputs": [ + { + "name": "", + "type": "address", + }, + ], + "payable": false, + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "name": "_implementation", + "type": "address", + }, + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor", + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "name": "previousAdmin", + "type": "address", + }, + { + "indexed": false, + "name": "newAdmin", + "type": "address", + }, + ], + "name": "AdminChanged", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "name": "implementation", + "type": "address", + }, + ], + "name": "Upgraded", + "type": "event", + }, + ], + "address": { + "1": "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48", + }, + "name": "FiatToken", + }, +] +`; diff --git a/packages/cli/src/plugins/__snapshots__/fetch.test.ts.snap b/packages/cli/src/plugins/__snapshots__/fetch.test.ts.snap new file mode 100644 index 0000000000..83c4e81f53 --- /dev/null +++ b/packages/cli/src/plugins/__snapshots__/fetch.test.ts.snap @@ -0,0 +1,367 @@ +// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html + +exports[`fetches ABI 1`] = ` +[ + { + "abi": [ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "approved", + "type": "address", + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "Approval", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "operator", + "type": "address", + }, + { + "indexed": false, + "internalType": "bool", + "name": "approved", + "type": "bool", + }, + ], + "name": "ApprovalForAll", + "type": "event", + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "Transfer", + "type": "event", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "approve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + }, + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "getApproved", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + }, + { + "internalType": "address", + "name": "operator", + "type": "address", + }, + ], + "name": "isApprovedForAll", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "ownerOf", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes", + }, + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "operator", + "type": "address", + }, + { + "internalType": "bool", + "name": "approved", + "type": "bool", + }, + ], + "name": "setApprovalForAll", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "interfaceId", + "type": "bytes4", + }, + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "tokenURI", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string", + }, + ], + "stateMutability": "pure", + "type": "function", + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address", + }, + { + "internalType": "address", + "name": "to", + "type": "address", + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256", + }, + ], + "name": "transferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "address": "0xaf0326d92b97df1221759476b072abfd8084f9be", + "name": "WagmiMintExample", + }, +] +`; diff --git a/packages/cli/src/plugins/__snapshots__/sourcify.test.ts.snap b/packages/cli/src/plugins/__snapshots__/sourcify.test.ts.snap new file mode 100644 index 0000000000..77e82fecde --- /dev/null +++ b/packages/cli/src/plugins/__snapshots__/sourcify.test.ts.snap @@ -0,0 +1,214 @@ +// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html + +exports[`fetches ABI 1`] = ` +[ + { + "abi": [ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor", + }, + { + "inputs": [ + { + "name": "pubkey", + "type": "bytes", + }, + { + "name": "withdrawal_credentials", + "type": "bytes", + }, + { + "name": "amount", + "type": "bytes", + }, + { + "name": "signature", + "type": "bytes", + }, + { + "name": "index", + "type": "bytes", + }, + ], + "name": "DepositEvent", + "type": "event", + }, + { + "inputs": [ + { + "name": "pubkey", + "type": "bytes", + }, + { + "name": "withdrawal_credentials", + "type": "bytes", + }, + { + "name": "signature", + "type": "bytes", + }, + { + "name": "deposit_data_root", + "type": "bytes32", + }, + ], + "name": "deposit", + "outputs": [], + "stateMutability": "payable", + "type": "function", + }, + { + "inputs": [], + "name": "get_deposit_count", + "outputs": [ + { + "type": "bytes", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "get_deposit_root", + "outputs": [ + { + "type": "bytes32", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "name": "interfaceId", + "type": "bytes4", + }, + ], + "name": "supportsInterface", + "outputs": [ + { + "type": "bool", + }, + ], + "stateMutability": "pure", + "type": "function", + }, + ], + "address": { + "1": "0x00000000219ab540356cbb839cbe05303d7705fa", + }, + "name": "DepositContract", + }, +] +`; + +exports[`fetches ABI with multichain deployment 1`] = ` +[ + { + "abi": [ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor", + }, + { + "inputs": [ + { + "name": "pubkey", + "type": "bytes", + }, + { + "name": "withdrawal_credentials", + "type": "bytes", + }, + { + "name": "amount", + "type": "bytes", + }, + { + "name": "signature", + "type": "bytes", + }, + { + "name": "index", + "type": "bytes", + }, + ], + "name": "DepositEvent", + "type": "event", + }, + { + "inputs": [ + { + "name": "pubkey", + "type": "bytes", + }, + { + "name": "withdrawal_credentials", + "type": "bytes", + }, + { + "name": "signature", + "type": "bytes", + }, + { + "name": "deposit_data_root", + "type": "bytes32", + }, + ], + "name": "deposit", + "outputs": [], + "stateMutability": "payable", + "type": "function", + }, + { + "inputs": [], + "name": "get_deposit_count", + "outputs": [ + { + "type": "bytes", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [], + "name": "get_deposit_root", + "outputs": [ + { + "type": "bytes32", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "name": "interfaceId", + "type": "bytes4", + }, + ], + "name": "supportsInterface", + "outputs": [ + { + "type": "bool", + }, + ], + "stateMutability": "pure", + "type": "function", + }, + ], + "address": { + "100": "0xC4c622862a8F548997699bE24EA4bc504e5cA865", + "137": "0xC4c622862a8F548997699bE24EA4bc504e5cA865", + }, + "name": "Community", + }, +] +`; diff --git a/packages/cli/src/plugins/actions.test.ts b/packages/cli/src/plugins/actions.test.ts new file mode 100644 index 0000000000..51b445b616 --- /dev/null +++ b/packages/cli/src/plugins/actions.test.ts @@ -0,0 +1,359 @@ +import { erc20Abi } from 'viem' +import { expect, test } from 'vitest' + +import { actions } from './actions.js' + +test('default', async () => { + const result = await actions().run?.({ + contracts: [ + { + name: 'erc20', + abi: erc20Abi, + content: '', + meta: { + abiName: 'erc20Abi', + }, + }, + ], + isTypeScript: true, + outputs: [], + }) + + expect(result?.imports).toMatchInlineSnapshot(` + "import { createReadContract, createWriteContract, createSimulateContract, createWatchContractEvent } from '@wagmi/core/codegen' + " + `) + expect(result?.content).toMatchInlineSnapshot(` + "/** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const readErc20 = /*#__PURE__*/ createReadContract({ abi: erc20Abi }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"allowance"\` + */ + export const readErc20Allowance = /*#__PURE__*/ createReadContract({ abi: erc20Abi, functionName: 'allowance' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"balanceOf"\` + */ + export const readErc20BalanceOf = /*#__PURE__*/ createReadContract({ abi: erc20Abi, functionName: 'balanceOf' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"decimals"\` + */ + export const readErc20Decimals = /*#__PURE__*/ createReadContract({ abi: erc20Abi, functionName: 'decimals' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"name"\` + */ + export const readErc20Name = /*#__PURE__*/ createReadContract({ abi: erc20Abi, functionName: 'name' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"symbol"\` + */ + export const readErc20Symbol = /*#__PURE__*/ createReadContract({ abi: erc20Abi, functionName: 'symbol' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"totalSupply"\` + */ + export const readErc20TotalSupply = /*#__PURE__*/ createReadContract({ abi: erc20Abi, functionName: 'totalSupply' }) + + /** + * Wraps __{@link writeContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const writeErc20 = /*#__PURE__*/ createWriteContract({ abi: erc20Abi }) + + /** + * Wraps __{@link writeContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"approve"\` + */ + export const writeErc20Approve = /*#__PURE__*/ createWriteContract({ abi: erc20Abi, functionName: 'approve' }) + + /** + * Wraps __{@link writeContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transfer"\` + */ + export const writeErc20Transfer = /*#__PURE__*/ createWriteContract({ abi: erc20Abi, functionName: 'transfer' }) + + /** + * Wraps __{@link writeContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transferFrom"\` + */ + export const writeErc20TransferFrom = /*#__PURE__*/ createWriteContract({ abi: erc20Abi, functionName: 'transferFrom' }) + + /** + * Wraps __{@link simulateContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const simulateErc20 = /*#__PURE__*/ createSimulateContract({ abi: erc20Abi }) + + /** + * Wraps __{@link simulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"approve"\` + */ + export const simulateErc20Approve = /*#__PURE__*/ createSimulateContract({ abi: erc20Abi, functionName: 'approve' }) + + /** + * Wraps __{@link simulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transfer"\` + */ + export const simulateErc20Transfer = /*#__PURE__*/ createSimulateContract({ abi: erc20Abi, functionName: 'transfer' }) + + /** + * Wraps __{@link simulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transferFrom"\` + */ + export const simulateErc20TransferFrom = /*#__PURE__*/ createSimulateContract({ abi: erc20Abi, functionName: 'transferFrom' }) + + /** + * Wraps __{@link watchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const watchErc20Event = /*#__PURE__*/ createWatchContractEvent({ abi: erc20Abi }) + + /** + * Wraps __{@link watchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ and \`eventName\` set to \`"Approval"\` + */ + export const watchErc20ApprovalEvent = /*#__PURE__*/ createWatchContractEvent({ abi: erc20Abi, eventName: 'Approval' }) + + /** + * Wraps __{@link watchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ and \`eventName\` set to \`"Transfer"\` + */ + export const watchErc20TransferEvent = /*#__PURE__*/ createWatchContractEvent({ abi: erc20Abi, eventName: 'Transfer' })" + `) +}) + +test('address', async () => { + const result = await actions().run?.({ + contracts: [ + { + name: 'erc20', + abi: erc20Abi, + content: '', + meta: { + abiName: 'erc20Abi', + addressName: 'erc20Address', + }, + }, + ], + isTypeScript: true, + outputs: [], + }) + + expect(result?.content).toMatchInlineSnapshot(` + "/** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const readErc20 = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"allowance"\` + */ + export const readErc20Allowance = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'allowance' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"balanceOf"\` + */ + export const readErc20BalanceOf = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'balanceOf' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"decimals"\` + */ + export const readErc20Decimals = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'decimals' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"name"\` + */ + export const readErc20Name = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'name' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"symbol"\` + */ + export const readErc20Symbol = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'symbol' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"totalSupply"\` + */ + export const readErc20TotalSupply = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'totalSupply' }) + + /** + * Wraps __{@link writeContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const writeErc20 = /*#__PURE__*/ createWriteContract({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link writeContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"approve"\` + */ + export const writeErc20Approve = /*#__PURE__*/ createWriteContract({ abi: erc20Abi, address: erc20Address, functionName: 'approve' }) + + /** + * Wraps __{@link writeContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transfer"\` + */ + export const writeErc20Transfer = /*#__PURE__*/ createWriteContract({ abi: erc20Abi, address: erc20Address, functionName: 'transfer' }) + + /** + * Wraps __{@link writeContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transferFrom"\` + */ + export const writeErc20TransferFrom = /*#__PURE__*/ createWriteContract({ abi: erc20Abi, address: erc20Address, functionName: 'transferFrom' }) + + /** + * Wraps __{@link simulateContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const simulateErc20 = /*#__PURE__*/ createSimulateContract({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link simulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"approve"\` + */ + export const simulateErc20Approve = /*#__PURE__*/ createSimulateContract({ abi: erc20Abi, address: erc20Address, functionName: 'approve' }) + + /** + * Wraps __{@link simulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transfer"\` + */ + export const simulateErc20Transfer = /*#__PURE__*/ createSimulateContract({ abi: erc20Abi, address: erc20Address, functionName: 'transfer' }) + + /** + * Wraps __{@link simulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transferFrom"\` + */ + export const simulateErc20TransferFrom = /*#__PURE__*/ createSimulateContract({ abi: erc20Abi, address: erc20Address, functionName: 'transferFrom' }) + + /** + * Wraps __{@link watchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const watchErc20Event = /*#__PURE__*/ createWatchContractEvent({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link watchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ and \`eventName\` set to \`"Approval"\` + */ + export const watchErc20ApprovalEvent = /*#__PURE__*/ createWatchContractEvent({ abi: erc20Abi, address: erc20Address, eventName: 'Approval' }) + + /** + * Wraps __{@link watchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ and \`eventName\` set to \`"Transfer"\` + */ + export const watchErc20TransferEvent = /*#__PURE__*/ createWatchContractEvent({ abi: erc20Abi, address: erc20Address, eventName: 'Transfer' })" + `) +}) + +test('legacy hook names', async () => { + const result = await actions({ getActionName: 'legacy' }).run?.({ + contracts: [ + { + name: 'erc20', + abi: erc20Abi, + content: '', + meta: { + abiName: 'erc20Abi', + addressName: 'erc20Address', + }, + }, + ], + isTypeScript: true, + outputs: [], + }) + + expect(result?.content).toMatchInlineSnapshot(` + "/** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const readErc20 = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"allowance"\` + */ + export const readErc20Allowance = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'allowance' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"balanceOf"\` + */ + export const readErc20BalanceOf = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'balanceOf' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"decimals"\` + */ + export const readErc20Decimals = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'decimals' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"name"\` + */ + export const readErc20Name = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'name' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"symbol"\` + */ + export const readErc20Symbol = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'symbol' }) + + /** + * Wraps __{@link readContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"totalSupply"\` + */ + export const readErc20TotalSupply = /*#__PURE__*/ createReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'totalSupply' }) + + /** + * Wraps __{@link writeContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const writeErc20 = /*#__PURE__*/ createWriteContract({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link writeContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"approve"\` + */ + export const writeErc20Approve = /*#__PURE__*/ createWriteContract({ abi: erc20Abi, address: erc20Address, functionName: 'approve' }) + + /** + * Wraps __{@link writeContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transfer"\` + */ + export const writeErc20Transfer = /*#__PURE__*/ createWriteContract({ abi: erc20Abi, address: erc20Address, functionName: 'transfer' }) + + /** + * Wraps __{@link writeContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transferFrom"\` + */ + export const writeErc20TransferFrom = /*#__PURE__*/ createWriteContract({ abi: erc20Abi, address: erc20Address, functionName: 'transferFrom' }) + + /** + * Wraps __{@link simulateContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const prepareWriteErc20 = /*#__PURE__*/ createSimulateContract({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link simulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"approve"\` + */ + export const prepareWriteErc20Approve = /*#__PURE__*/ createSimulateContract({ abi: erc20Abi, address: erc20Address, functionName: 'approve' }) + + /** + * Wraps __{@link simulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transfer"\` + */ + export const prepareWriteErc20Transfer = /*#__PURE__*/ createSimulateContract({ abi: erc20Abi, address: erc20Address, functionName: 'transfer' }) + + /** + * Wraps __{@link simulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transferFrom"\` + */ + export const prepareWriteErc20TransferFrom = /*#__PURE__*/ createSimulateContract({ abi: erc20Abi, address: erc20Address, functionName: 'transferFrom' }) + + /** + * Wraps __{@link watchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const watchErc20Event = /*#__PURE__*/ createWatchContractEvent({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link watchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ and \`eventName\` set to \`"Approval"\` + */ + export const watchErc20ApprovalEvent = /*#__PURE__*/ createWatchContractEvent({ abi: erc20Abi, address: erc20Address, eventName: 'Approval' }) + + /** + * Wraps __{@link watchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ and \`eventName\` set to \`"Transfer"\` + */ + export const watchErc20TransferEvent = /*#__PURE__*/ createWatchContractEvent({ abi: erc20Abi, address: erc20Address, eventName: 'Transfer' })" + `) +}) + +test('override package name', async () => { + const result = await actions({ overridePackageName: 'wagmi' }).run?.({ + contracts: [ + { + name: 'erc20', + abi: erc20Abi, + content: '', + meta: { + abiName: 'erc20Abi', + }, + }, + ], + isTypeScript: true, + outputs: [], + }) + + expect(result?.imports).toMatchInlineSnapshot(` + "import { createReadContract, createWriteContract, createSimulateContract, createWatchContractEvent } from 'wagmi/codegen' + " + `) +}) diff --git a/packages/cli/src/plugins/actions.ts b/packages/cli/src/plugins/actions.ts new file mode 100644 index 0000000000..01c804fd91 --- /dev/null +++ b/packages/cli/src/plugins/actions.ts @@ -0,0 +1,321 @@ +import { pascalCase } from 'change-case' + +import type { Contract, Plugin } from '../config.js' +import type { Compute, RequiredBy } from '../types.js' +import { getAddressDocString } from '../utils/getAddressDocString.js' +import { getIsPackageInstalled } from '../utils/packages.js' + +export type ActionsConfig = { + getActionName?: + | 'legacy' // TODO: Deprecate `'legacy'` option + | ((options: { + contractName: string + itemName?: string | undefined + type: 'read' | 'simulate' | 'watch' | 'write' + }) => string) + overridePackageName?: '@wagmi/core' | 'wagmi' | undefined +} + +type ActionsResult = Compute> + +export function actions(config: ActionsConfig = {}): ActionsResult { + return { + name: 'Action', + async run({ contracts }) { + const imports = new Set([]) + const content: string[] = [] + const pure = '/*#__PURE__*/' + + const actionNames = new Set() + for (const contract of contracts) { + let hasReadFunction = false + let hasWriteFunction = false + let hasEvent = false + const readItems = [] + const writeItems = [] + const eventItems = [] + for (const item of contract.abi) { + if (item.type === 'function') + if ( + item.stateMutability === 'view' || + item.stateMutability === 'pure' + ) { + hasReadFunction = true + readItems.push(item) + } else { + hasWriteFunction = true + writeItems.push(item) + } + else if (item.type === 'event') { + hasEvent = true + eventItems.push(item) + } + } + + let innerContent: string + if (contract.meta.addressName) + innerContent = `abi: ${contract.meta.abiName}, address: ${contract.meta.addressName}` + else innerContent = `abi: ${contract.meta.abiName}` + + if (hasReadFunction) { + const actionName = getActionName( + config, + actionNames, + 'read', + contract.name, + ) + const docString = genDocString('readContract', contract) + const functionName = 'createReadContract' + imports.add(functionName) + content.push( + `${docString} +export const ${actionName} = ${pure} ${functionName}({ ${innerContent} })`, + ) + + const names = new Set() + for (const item of readItems) { + if (item.type !== 'function') continue + if ( + item.stateMutability !== 'pure' && + item.stateMutability !== 'view' + ) + continue + + // Skip overrides since they are captured by same hook + if (names.has(item.name)) continue + names.add(item.name) + + const hookName = getActionName( + config, + actionNames, + 'read', + contract.name, + item.name, + ) + const docString = genDocString('readContract', contract, { + name: 'functionName', + value: item.name, + }) + content.push( + `${docString} +export const ${hookName} = ${pure} ${functionName}({ ${innerContent}, functionName: '${item.name}' })`, + ) + } + } + + if (hasWriteFunction) { + { + const actionName = getActionName( + config, + actionNames, + 'write', + contract.name, + ) + const docString = genDocString('writeContract', contract) + const functionName = 'createWriteContract' + imports.add(functionName) + content.push( + `${docString} +export const ${actionName} = ${pure} ${functionName}({ ${innerContent} })`, + ) + + const names = new Set() + for (const item of writeItems) { + if (item.type !== 'function') continue + if ( + item.stateMutability !== 'nonpayable' && + item.stateMutability !== 'payable' + ) + continue + + // Skip overrides since they are captured by same hook + if (names.has(item.name)) continue + names.add(item.name) + + const actionName = getActionName( + config, + actionNames, + 'write', + contract.name, + item.name, + ) + const docString = genDocString('writeContract', contract, { + name: 'functionName', + value: item.name, + }) + content.push( + `${docString} +export const ${actionName} = ${pure} ${functionName}({ ${innerContent}, functionName: '${item.name}' })`, + ) + } + } + + { + const actionName = getActionName( + config, + actionNames, + 'simulate', + contract.name, + ) + const docString = genDocString('simulateContract', contract) + const functionName = 'createSimulateContract' + imports.add(functionName) + content.push( + `${docString} +export const ${actionName} = ${pure} ${functionName}({ ${innerContent} })`, + ) + + const names = new Set() + for (const item of writeItems) { + if (item.type !== 'function') continue + if ( + item.stateMutability !== 'nonpayable' && + item.stateMutability !== 'payable' + ) + continue + + // Skip overrides since they are captured by same hook + if (names.has(item.name)) continue + names.add(item.name) + + const actionName = getActionName( + config, + actionNames, + 'simulate', + contract.name, + item.name, + ) + const docString = genDocString('simulateContract', contract, { + name: 'functionName', + value: item.name, + }) + content.push( + `${docString} +export const ${actionName} = ${pure} ${functionName}({ ${innerContent}, functionName: '${item.name}' })`, + ) + } + } + } + + if (hasEvent) { + const actionName = getActionName( + config, + actionNames, + 'watch', + contract.name, + ) + const docString = genDocString('watchContractEvent', contract) + const functionName = 'createWatchContractEvent' + imports.add(functionName) + content.push( + `${docString} +export const ${actionName} = ${pure} ${functionName}({ ${innerContent} })`, + ) + + const names = new Set() + for (const item of eventItems) { + if (item.type !== 'event') continue + + // Skip overrides since they are captured by same hook + if (names.has(item.name)) continue + names.add(item.name) + + const actionName = getActionName( + config, + actionNames, + 'watch', + contract.name, + item.name, + ) + const docString = genDocString('watchContractEvent', contract, { + name: 'eventName', + value: item.name, + }) + content.push( + `${docString} +export const ${actionName} = ${pure} ${functionName}({ ${innerContent}, eventName: '${item.name}' })`, + ) + } + } + } + + const importValues = [...imports.values()] + + let packageName = '@wagmi/core/codegen' + if (config.overridePackageName) { + switch (config.overridePackageName) { + case '@wagmi/core': + packageName = '@wagmi/core/codegen' + break + case 'wagmi': + packageName = 'wagmi/codegen' + break + } + } else if (await getIsPackageInstalled({ packageName: 'wagmi' })) + packageName = 'wagmi/codegen' + else if (await getIsPackageInstalled({ packageName: '@wagmi/core' })) + packageName = '@wagmi/core/codegen' + + return { + imports: importValues.length + ? `import { ${importValues.join(', ')} } from '${packageName}'\n` + : '', + content: content.join('\n\n'), + } + }, + } +} + +function genDocString( + actionName: string, + contract: Contract, + item?: { name: string; value: string }, +) { + let description = `Wraps __{@link ${actionName}}__ with \`abi\` set to __{@link ${contract.meta.abiName}}__` + if (item) description += ` and \`${item.name}\` set to \`"${item.value}"\`` + + const docString = getAddressDocString({ address: contract.address }) + if (docString) + return `/** + * ${description} + * + ${docString} + */` + + return `/** + * ${description} + */` +} + +function getActionName( + config: ActionsConfig, + actionNames: Set, + type: 'read' | 'simulate' | 'watch' | 'write', + contractName: string, + itemName?: string | undefined, +) { + const ContractName = pascalCase(contractName) + const ItemName = itemName ? pascalCase(itemName) : undefined + + let actionName: string + if (typeof config.getActionName === 'function') + actionName = config.getActionName({ + type, + contractName: ContractName, + itemName: ItemName, + }) + else if (typeof config.getActionName === 'string' && type === 'simulate') { + actionName = `prepareWrite${ContractName}${ItemName ?? ''}` + } else { + actionName = `${type}${ContractName}${ItemName ?? ''}` + if (type === 'watch') actionName = `${actionName}Event` + } + + if (actionNames.has(actionName)) + throw new Error( + `Action name "${actionName}" must be unique for contract "${contractName}". Try using \`getActionName\` to create a unique name.`, + ) + + actionNames.add(actionName) + return actionName +} diff --git a/packages/cli/src/plugins/blockExplorer.test.ts b/packages/cli/src/plugins/blockExplorer.test.ts new file mode 100644 index 0000000000..13372f53ec --- /dev/null +++ b/packages/cli/src/plugins/blockExplorer.test.ts @@ -0,0 +1,53 @@ +import { setupServer } from 'msw/node' +import { afterAll, afterEach, beforeAll, expect, test } from 'vitest' + +import { + address, + apiKey, + baseUrl, + handlers, + unverifiedContractAddress, +} from '../../test/utils.js' +import { blockExplorer } from './blockExplorer.js' + +const server = setupServer(...handlers) + +beforeAll(() => server.listen()) +afterEach(() => server.resetHandlers()) +afterAll(() => server.close()) + +test('fetches ABI', async () => { + await expect( + blockExplorer({ + apiKey, + baseUrl, + contracts: [{ name: 'WagmiMintExample', address }], + }).contracts!(), + ).resolves.toMatchSnapshot() +}) + +test('fetches ABI with multichain deployment', async () => { + await expect( + blockExplorer({ + apiKey, + baseUrl, + contracts: [ + { name: 'WagmiMintExample', address: { 1: address, 10: address } }, + ], + }).contracts?.(), + ).resolves.toMatchSnapshot() +}) + +test('fails to fetch for unverified contract', async () => { + await expect( + blockExplorer({ + apiKey, + baseUrl, + contracts: [ + { name: 'WagmiMintExample', address: unverifiedContractAddress }, + ], + }).contracts?.(), + ).rejects.toThrowErrorMatchingInlineSnapshot( + '[Error: Contract source code not verified]', + ) +}) diff --git a/packages/cli/src/plugins/blockExplorer.ts b/packages/cli/src/plugins/blockExplorer.ts new file mode 100644 index 0000000000..2518b6e936 --- /dev/null +++ b/packages/cli/src/plugins/blockExplorer.ts @@ -0,0 +1,107 @@ +import { camelCase } from 'change-case' +import type { Address } from 'viem' +import { z } from 'zod' + +import type { ContractConfig } from '../config.js' +import { fromZodError } from '../errors.js' +import type { Compute } from '../types.js' +import { fetch } from './fetch.js' + +export type BlockExplorerConfig = { + /** + * API key for block explorer. Appended to the request URL as query param `&apikey=${apiKey}`. + */ + apiKey?: string | undefined + /** + * Base URL for block explorer. + */ + baseUrl: string + /** + * Duration in milliseconds to cache ABIs. + * + * @default 1_800_000 // 30m in ms + */ + cacheDuration?: number | undefined + /** + * Chain ID for block explorer. Appended to the request URL as query param `&chainId=${chainId}`. + */ + chainId?: number | undefined + /** + * Contracts to fetch ABIs for. + */ + contracts: Compute>[] + /** + * Function to get address from contract config. + */ + getAddress?: + | ((config: { + address: NonNullable + }) => Address) + | undefined + /** + * Name of source. + */ + name?: ContractConfig['name'] | undefined +} + +const BlockExplorerResponse = z.discriminatedUnion('status', [ + z.object({ + status: z.literal('1'), + message: z.literal('OK'), + result: z + .string() + .transform((val) => JSON.parse(val) as ContractConfig['abi']), + }), + z.object({ + status: z.literal('0'), + message: z.literal('NOTOK'), + result: z.string(), + }), +]) + +/** + * Fetches contract ABIs from block explorers, supporting `?module=contract&action=getabi` requests. + */ +export function blockExplorer(config: BlockExplorerConfig) { + const { + apiKey, + baseUrl, + cacheDuration, + chainId, + contracts, + getAddress = ({ address }) => { + if (typeof address === 'string') return address + return Object.values(address)[0]! + }, + name = 'Block Explorer', + } = config + + return fetch({ + cacheDuration, + contracts, + name, + getCacheKey({ contract }) { + if (typeof contract.address === 'string') + return `${camelCase(name)}:${contract.address}` + return `${camelCase(name)}:${JSON.stringify(contract.address)}` + }, + async parse({ response }) { + const json = await response.json() + const parsed = await BlockExplorerResponse.safeParseAsync(json) + if (!parsed.success) + throw fromZodError(parsed.error, { prefix: 'Invalid response' }) + if (parsed.data.status === '0') throw new Error(parsed.data.result) + return parsed.data.result + }, + request({ address }) { + if (!address) throw new Error('address is required') + return { + url: `${baseUrl}?${chainId ? `chainId=${chainId}&` : ''}module=contract&action=getabi&address=${getAddress( + { + address, + }, + )}${apiKey ? `&apikey=${apiKey}` : ''}`, + } + }, + }) +} diff --git a/packages/cli/src/plugins/etherscan.test.ts b/packages/cli/src/plugins/etherscan.test.ts new file mode 100644 index 0000000000..dc496f4630 --- /dev/null +++ b/packages/cli/src/plugins/etherscan.test.ts @@ -0,0 +1,112 @@ +import { mkdir, rm } from 'node:fs/promises' +import { setupServer } from 'msw/node' +import { afterAll, afterEach, beforeAll, expect, test } from 'vitest' + +import { + address, + apiKey, + handlers, + invalidApiKey, + proxyAddress, + timeoutAddress, + unverifiedContractAddress, +} from '../../test/utils.js' +import { etherscan } from './etherscan.js' +import { getCacheDir } from './fetch.js' + +const server = setupServer(...handlers) + +beforeAll(() => server.listen()) +afterEach(() => server.resetHandlers()) +afterAll(() => server.close()) + +test('fetches ABI', async () => { + await expect( + etherscan({ + apiKey, + chainId: 1, + contracts: [{ name: 'WagmiMintExample', address }], + }).contracts?.(), + ).resolves.toMatchSnapshot() +}) + +test('fetches ABI with multichain deployment', async () => { + await expect( + etherscan({ + apiKey, + chainId: 1, + contracts: [ + { name: 'WagmiMintExample', address: { 1: address, 10: address } }, + ], + }).contracts?.(), + ).resolves.toMatchSnapshot() +}) + +test('fails to fetch for unverified contract', async () => { + await expect( + etherscan({ + apiKey, + chainId: 1, + contracts: [ + { name: 'WagmiMintExample', address: unverifiedContractAddress }, + ], + }).contracts?.(), + ).rejects.toThrowErrorMatchingInlineSnapshot( + '[Error: Contract source code not verified]', + ) +}) + +test('missing address for chainId', async () => { + await expect( + etherscan({ + apiKey, + chainId: 1, + // @ts-expect-error `chainId` and `keyof typeof contracts[number].address` mismatch + contracts: [{ name: 'WagmiMintExample', address: { 10: address } }], + }).contracts?.(), + ).rejects.toThrowErrorMatchingInlineSnapshot( + `[Error: No address found for chainId "1". Make sure chainId "1" is set as an address.]`, + ) +}) + +test('invalid api key', async () => { + await expect( + etherscan({ + apiKey: invalidApiKey, + chainId: 1, + contracts: [{ name: 'WagmiMintExample', address: timeoutAddress }], + }).contracts?.(), + ).rejects.toThrowErrorMatchingInlineSnapshot('[Error: Invalid API Key]') +}) + +test('tryFetchProxyImplementation: fetches ABI', async () => { + const cacheDir = getCacheDir() + await mkdir(cacheDir, { recursive: true }) + + await expect( + etherscan({ + apiKey, + chainId: 1, + contracts: [{ name: 'WagmiMintExample', address }], + tryFetchProxyImplementation: true, + }).contracts?.(), + ).resolves.toMatchSnapshot() + + await rm(cacheDir, { recursive: true }) +}) + +test('tryFetchProxyImplementation: fetches implementation ABI', async () => { + const cacheDir = getCacheDir() + await mkdir(cacheDir, { recursive: true }) + + await expect( + etherscan({ + apiKey, + chainId: 1, + contracts: [{ name: 'FiatToken', address: proxyAddress }], + tryFetchProxyImplementation: true, + }).contracts?.(), + ).resolves.toMatchSnapshot() + + await rm(cacheDir, { recursive: true }) +}) diff --git a/packages/cli/src/plugins/etherscan.ts b/packages/cli/src/plugins/etherscan.ts new file mode 100644 index 0000000000..fda375c240 --- /dev/null +++ b/packages/cli/src/plugins/etherscan.ts @@ -0,0 +1,268 @@ +import { mkdir, writeFile } from 'node:fs/promises' +import { Address as AddressSchema } from 'abitype/zod' +import { camelCase } from 'change-case' +import { join } from 'pathe' +import type { Abi, Address } from 'viem' +import { z } from 'zod' + +import type { ContractConfig } from '../config.js' +import { fromZodError } from '../errors.js' +import type { Compute } from '../types.js' +import { fetch, getCacheDir } from './fetch.js' + +export type EtherscanConfig = { + /** + * Etherscan API key. + * + * Create or manage keys at https://etherscan.io/myapikey + */ + apiKey: string + /** + * Duration in milliseconds to cache ABIs. + * + * @default 1_800_000 // 30m in ms + */ + cacheDuration?: number | undefined + /** + * Chain ID to use for fetching ABI. + * + * If `address` is an object, `chainId` is used to select the address. + * + * View supported chains on the [Etherscan docs](https://docs.etherscan.io/etherscan-v2/getting-started/supported-chains). + */ + chainId: (chainId extends ChainId ? chainId : never) | (ChainId & {}) + /** + * Contracts to fetch ABIs for. + */ + contracts: Compute, 'abi'>>[] + /** + * Whether to try fetching proxy implementation address of the contract + * + * @default false + */ + tryFetchProxyImplementation?: boolean | undefined +} + +/** + * Fetches contract ABIs from Etherscan. + */ +export function etherscan( + config: EtherscanConfig, +) { + const { + apiKey, + cacheDuration = 1_800_000, + chainId, + tryFetchProxyImplementation = false, + } = config + + const contracts = config.contracts.map((x) => ({ + ...x, + address: + typeof x.address === 'string' ? { [chainId]: x.address } : x.address, + })) as Omit[] + + const name = 'Etherscan' + + const getCacheKey: Parameters[0]['getCacheKey'] = ({ + contract, + }) => { + if (typeof contract.address === 'string') + return `${camelCase(name)}:${contract.address}` + return `${camelCase(name)}:${JSON.stringify(contract.address)}` + } + + return fetch({ + cacheDuration, + contracts, + name, + getCacheKey, + async parse({ response }) { + const json = await response.json() + const parsed = await GetAbiResponse.safeParseAsync(json) + if (!parsed.success) + throw fromZodError(parsed.error, { prefix: 'Invalid response' }) + if (parsed.data.status === '0') throw new Error(parsed.data.result) + return parsed.data.result + }, + async request(contract) { + if (!contract.address) throw new Error('address is required') + + const resolvedAddress = (() => { + if (!contract.address) throw new Error('address is required') + if (typeof contract.address === 'string') return contract.address + const contractAddress = contract.address[chainId] + if (!contractAddress) + throw new Error( + `No address found for chainId "${chainId}". Make sure chainId "${chainId}" is set as an address.`, + ) + return contractAddress + })() + + const options = { + address: resolvedAddress, + apiKey, + chainId, + } + + let abi: Abi | undefined + const implementationAddress = await (async () => { + if (!tryFetchProxyImplementation) return + const json = await globalThis + .fetch(buildUrl({ ...options, action: 'getsourcecode' })) + .then((res) => res.json()) + const parsed = await GetSourceCodeResponse.safeParseAsync(json) + if (!parsed.success) + throw fromZodError(parsed.error, { prefix: 'Invalid response' }) + if (parsed.data.status === '0') throw new Error(parsed.data.result) + if (!parsed.data.result[0]) return + abi = parsed.data.result[0].ABI + return parsed.data.result[0].Implementation as Address + })() + + if (abi) { + const cacheDir = getCacheDir() + await mkdir(cacheDir, { recursive: true }) + const cacheKey = getCacheKey({ contract }) + const cacheFilePath = join(cacheDir, `${cacheKey}.json`) + await writeFile( + cacheFilePath, + `${JSON.stringify({ abi, timestamp: Date.now() + cacheDuration }, undefined, 2)}\n`, + ) + } + + return { + url: buildUrl({ + ...options, + action: 'getabi', + address: implementationAddress || resolvedAddress, + }), + } + }, + }) +} + +function buildUrl(options: { + action: 'getabi' | 'getsourcecode' + address: Address + apiKey: string + chainId: ChainId | undefined +}) { + const baseUrl = 'https://api.etherscan.io/v2/api' + const { action, address, apiKey, chainId } = options + return `${baseUrl}?${chainId ? `chainId=${chainId}&` : ''}module=contract&action=${action}&address=${address}${apiKey ? `&apikey=${apiKey}` : ''}` +} + +const GetAbiResponse = z.discriminatedUnion('status', [ + z.object({ + status: z.literal('1'), + message: z.literal('OK'), + result: z.string().transform((val) => JSON.parse(val) as Abi), + }), + z.object({ + status: z.literal('0'), + message: z.literal('NOTOK'), + result: z.string(), + }), +]) + +const GetSourceCodeResponse = z.discriminatedUnion('status', [ + z.object({ + status: z.literal('1'), + message: z.literal('OK'), + result: z.array( + z.discriminatedUnion('Proxy', [ + z.object({ + ABI: z.string().transform((val) => JSON.parse(val) as Abi), + Implementation: AddressSchema, + Proxy: z.literal('1'), + }), + z.object({ + ABI: z.string().transform((val) => JSON.parse(val) as Abi), + Implementation: z.string(), + Proxy: z.literal('0'), + }), + ]), + ), + }), + z.object({ + status: z.literal('0'), + message: z.literal('NOTOK'), + result: z.string(), + }), +]) + +// Supported chains +// https://docs.etherscan.io/etherscan-v2/getting-started/supported-chains +type ChainId = + | 1 // Ethereum Mainnet + | 11155111 // Sepolia Testnet + | 17000 // Holesky Testnet + | 560048 // Hoodi Testnet + | 56 // BNB Smart Chain Mainnet + | 97 // BNB Smart Chain Testnet + | 137 // Polygon Mainnet + | 80002 // Polygon Amoy Testnet + | 1101 // Polygon zkEVM Mainnet + | 2442 // Polygon zkEVM Cardona Testnet + | 8453 // Base Mainnet + | 84532 // Base Sepolia Testnet + | 42161 // Arbitrum One Mainnet + | 42170 // Arbitrum Nova Mainnet + | 421614 // Arbitrum Sepolia Testnet + | 59144 // Linea Mainnet + | 59141 // Linea Sepolia Testnet + | 250 // Fantom Opera Mainnet + | 4002 // Fantom Testnet + | 81457 // Blast Mainnet + | 168587773 // Blast Sepolia Testnet + | 10 // OP Mainnet + | 11155420 // OP Sepolia Testnet + | 43114 // Avalanche C-Chain + | 43113 // Avalanche Fuji Testnet + | 199 // BitTorrent Chain Mainnet + | 1028 // BitTorrent Chain Testnet + | 42220 // Celo Mainnet + | 44787 // Celo Alfajores Testnet + | 25 // Cronos Mainnet + | 252 // Fraxtal Mainnet + | 2522 // Fraxtal Testnet + | 100 // Gnosis + | 255 // Kroma Mainnet + | 2358 // Kroma Sepolia Testnet + | 5000 // Mantle Mainnet + | 5003 // Mantle Sepolia Testnet + | 1284 // Moonbeam Mainnet + | 1285 // Moonriver Mainnet + | 1287 // Moonbase Alpha Testnet + | 204 // opBNB Mainnet + | 5611 // opBNB Testnet + | 534352 // Scroll Mainnet + | 534351 // Scroll Sepolia Testnet + | 167000 // Taiko Mainnet + | 167009 // Taiko Hekla L2 Testnet + | 1111 // WEMIX3.0 Mainnet + | 1112 // WEMIX3.0 Testnet + | 324 // zkSync Mainnet + | 300 // zkSync Sepolia Testnet + | 660279 // Xai Mainnet + | 37714555429 // Xai Sepolia Testnet + | 50 // XDC Mainnet + | 51 // XDC Apothem Testnet + | 33139 // ApeChain Mainnet + | 33111 // ApeChain Curtis Testnet + | 480 // World Mainnet + | 4801 // World Sepolia Testnet + | 50104 // Sophon Mainnet + | 531050104 // Sophon Sepolia Testnet + | 146 // Sonic Mainnet + | 57054 // Sonic Blaze Testnet + | 130 // Unichain Mainnet + | 1301 // Unichain Sepolia Testnet + | 2741 // Abstract Mainnet + | 11124 // Abstract Sepolia Testnet + | 80094 // Berachain Mainnet + | 80069 // Berachain Bepolia Testnet + | 1923 // Swellchain Mainnet + | 1924 // Swellchain Testnet + | 10143 // Monad Testnet diff --git a/packages/cli/src/plugins/fetch.test.ts b/packages/cli/src/plugins/fetch.test.ts new file mode 100644 index 0000000000..600cbfeda7 --- /dev/null +++ b/packages/cli/src/plugins/fetch.test.ts @@ -0,0 +1,186 @@ +import { mkdir, rm, writeFile } from 'node:fs/promises' +import { homedir } from 'node:os' +import { setupServer } from 'msw/node' +import { afterAll, afterEach, beforeAll, expect, test } from 'vitest' + +import { + address, + apiKey, + baseUrl, + handlers, + timeoutAddress, + unverifiedContractAddress, +} from '../../test/utils.js' +import { fetch, getCacheDir } from './fetch.js' + +const server = setupServer(...handlers) + +beforeAll(() => server.listen()) +afterEach(() => server.resetHandlers()) +afterAll(() => server.close()) + +type Fetch = Parameters[0] +const request: Fetch['request'] = ({ address }) => { + return { + url: `${baseUrl}?module=contract&action=getabi&address=${address}&apikey=${apiKey}`, + } +} +const parse: Fetch['parse'] = async ({ response }) => { + const data = (await response.json()) as + | { status: '1'; message: 'OK'; result: string } + | { status: '0'; message: 'NOTOK'; result: string } + if (data.status === '0') throw new Error(data.result) + return JSON.parse(data.result) +} + +test('fetches ABI', async () => { + await expect( + fetch({ + contracts: [{ name: 'WagmiMintExample', address }], + request, + parse, + }).contracts?.(), + ).resolves.toMatchSnapshot() +}) + +test('fails to fetch for unverified contract', async () => { + await expect( + fetch({ + contracts: [ + { name: 'WagmiMintExample', address: unverifiedContractAddress }, + ], + request, + parse, + }).contracts?.(), + ).rejects.toThrowErrorMatchingInlineSnapshot( + '[Error: Contract source code not verified]', + ) +}) + +test('aborts request', async () => { + await expect( + fetch({ + contracts: [{ name: 'WagmiMintExample', address: timeoutAddress }], + request, + parse, + timeoutDuration: 1_000, + }).contracts?.(), + ).rejects.toThrowErrorMatchingInlineSnapshot( + '[AbortError: This operation was aborted]', + ) +}) + +test('reads from cache', async () => { + const cacheDir = `${homedir}/.wagmi-cli/plugins/fetch/cache` + await mkdir(cacheDir, { recursive: true }) + + const contract = { + name: 'WagmiMintExample', + address: timeoutAddress, + } as const + const cacheKey = JSON.stringify(contract) + const cacheFilePath = `${cacheDir}/${cacheKey}.json` + await writeFile( + cacheFilePath, + JSON.stringify( + { + abi: [ + { + inputs: [], + name: 'mint', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + ], + timestamp: Date.now() + 30_000, + }, + null, + 2, + ), + ) + + await expect( + fetch({ + contracts: [contract], + request, + parse, + }).contracts?.(), + ).resolves.toMatchInlineSnapshot(` + [ + { + "abi": [ + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "address": "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + "name": "WagmiMintExample", + }, + ] + `) + + await rm(cacheDir, { recursive: true }) +}) + +test('fails and reads from cache', async () => { + const cacheDir = getCacheDir() + await mkdir(cacheDir, { recursive: true }) + + const contract = { + name: 'WagmiMintExample', + address: timeoutAddress, + } as const + const cacheKey = JSON.stringify(contract) + const cacheFilePath = `${cacheDir}/${cacheKey}.json` + await writeFile( + cacheFilePath, + JSON.stringify( + { + abi: [ + { + inputs: [], + name: 'mint', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + ], + timestamp: Date.now() - 30_000, + }, + null, + 2, + ), + ) + + await expect( + fetch({ + contracts: [contract], + request, + parse, + timeoutDuration: 1, + }).contracts?.(), + ).resolves.toMatchInlineSnapshot(` + [ + { + "abi": [ + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "address": "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + "name": "WagmiMintExample", + }, + ] + `) + + await rm(cacheDir, { recursive: true }) +}) diff --git a/packages/cli/src/plugins/fetch.ts b/packages/cli/src/plugins/fetch.ts new file mode 100644 index 0000000000..778d4a8162 --- /dev/null +++ b/packages/cli/src/plugins/fetch.ts @@ -0,0 +1,127 @@ +import { mkdir, readFile, writeFile } from 'node:fs/promises' +import { homedir } from 'node:os' +import { join } from 'pathe' + +import type { Abi } from 'viem' +import type { ContractConfig, Plugin } from '../config.js' +import type { Compute, RequiredBy } from '../types.js' + +export type FetchConfig = { + /** + * Duration in milliseconds to cache ABIs from request. + * + * @default 1_800_000 // 30m in ms + */ + cacheDuration?: number | undefined + /** + * Contracts to fetch ABIs for. + */ + contracts: Compute>[] + /** + * Function for creating a cache key for contract. + */ + getCacheKey?: + | ((config: { contract: Compute> }) => string) + | undefined + /** + * Name of source. + */ + name?: ContractConfig['name'] | undefined + /** + * Function for parsing ABI from fetch response. + * + * @default ({ response }) => response.json() + */ + parse?: + | ((config: { + response: Response + }) => ContractConfig['abi'] | Promise) + | undefined + /** + * Function for returning a request to fetch ABI from. + */ + request: (config: { + address?: ContractConfig['address'] | undefined + name: ContractConfig['name'] + }) => + | { url: RequestInfo; init?: RequestInit | undefined } + | Promise<{ url: RequestInfo; init?: RequestInit | undefined }> + /** + * Duration in milliseconds before request times out. + * + * @default 5_000 // 5s in ms + */ + timeoutDuration?: number | undefined +} + +type FetchResult = Compute> + +/** Fetches and parses contract ABIs from network resource with `fetch`. */ +export function fetch(config: FetchConfig): FetchResult { + const { + cacheDuration = 1_800_000, + contracts: contractConfigs, + getCacheKey = ({ contract }) => JSON.stringify(contract), + name = 'Fetch', + parse = ({ response }) => response.json(), + request, + timeoutDuration = 5_000, + } = config + + return { + async contracts() { + const cacheDir = getCacheDir() + await mkdir(cacheDir, { recursive: true }) + + const timestamp = Date.now() + cacheDuration + const contracts = [] + for (const contract of contractConfigs) { + const cacheKey = getCacheKey({ contract }) + const cacheFilePath = join(cacheDir, `${cacheKey}.json`) + const cachedFile = JSON.parse( + await readFile(cacheFilePath, 'utf8').catch(() => 'null'), + ) + + let abi: Abi | undefined + if (cachedFile?.timestamp > Date.now()) abi = cachedFile.abi + else { + try { + const controller = new globalThis.AbortController() + const timeout = setTimeout( + () => controller.abort(), + timeoutDuration, + ) + + const { url, init } = await request(contract) + const response = await globalThis.fetch(url, { + ...init, + signal: controller.signal, + }) + clearTimeout(timeout) + + abi = await parse({ response }) + await writeFile( + cacheFilePath, + `${JSON.stringify({ abi, timestamp }, undefined, 2)}\n`, + ) + } catch (error) { + try { + // Attempt to read from cache if fetch fails. + abi = JSON.parse(await readFile(cacheFilePath, 'utf8')).abi + } catch {} + if (!abi) throw error + } + } + + if (!abi) throw Error('Failed to fetch ABI for contract.') + contracts.push({ abi, address: contract.address, name: contract.name }) + } + return contracts + }, + name, + } +} + +export function getCacheDir() { + return join(homedir(), '.wagmi-cli/plugins/fetch/cache') +} diff --git a/packages/cli/src/plugins/foundry.test.ts b/packages/cli/src/plugins/foundry.test.ts new file mode 100644 index 0000000000..75e5ec73ee --- /dev/null +++ b/packages/cli/src/plugins/foundry.test.ts @@ -0,0 +1,153 @@ +import fixtures from 'fixturez' +import { dirname, resolve } from 'pathe' +import { afterEach, expect, test, vi } from 'vitest' + +import { foundry } from './foundry.js' + +const f = fixtures(__dirname) + +afterEach(() => { + vi.restoreAllMocks() +}) + +test('forge not installed', async () => { + const dir = f.temp() + expect( + foundry({ + project: dir, + forge: { + path: '/path/to/forge', + }, + }).validate?.(), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [Error: forge must be installed to use Foundry plugin. + To install, follow the instructions at https://book.getfoundry.sh/getting-started/installation] + `) +}) + +test('project does not exist', async () => { + const dir = f.temp() + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + try { + await foundry({ project: '../path/to/project' }).validate?.() + } catch (error) { + expect( + (error as Error).message.replace(dirname(dir), '..'), + ).toMatchInlineSnapshot('"Foundry project ../path/to/project not found."') + } +}) + +test('validates without project', async () => { + const dir = resolve(__dirname, '__fixtures__/foundry/') + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(foundry().validate?.()).resolves.toBeUndefined() +}) + +test('contracts', async () => { + await expect( + foundry({ + project: resolve(__dirname, '__fixtures__/foundry/'), + exclude: ['Foo.sol/**'], + }).contracts?.(), + ).resolves.toMatchInlineSnapshot(` + [ + { + "abi": [ + { + "inputs": [], + "name": "increment", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [], + "name": "number", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newNumber", + "type": "uint256", + }, + ], + "name": "setNumber", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "address": undefined, + "name": "Counter", + }, + ] + `) +}) + +test('contracts without project', async () => { + const dir = resolve(__dirname, '__fixtures__/foundry/') + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect( + foundry({ + exclude: ['Foo.sol/**'], + }).contracts?.(), + ).resolves.toMatchInlineSnapshot(` + [ + { + "abi": [ + { + "inputs": [], + "name": "increment", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [], + "name": "number", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newNumber", + "type": "uint256", + }, + ], + "name": "setNumber", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "address": undefined, + "name": "Counter", + }, + ] + `) +}) diff --git a/packages/cli/src/plugins/foundry.ts b/packages/cli/src/plugins/foundry.ts new file mode 100644 index 0000000000..dab307a58f --- /dev/null +++ b/packages/cli/src/plugins/foundry.ts @@ -0,0 +1,263 @@ +import { execSync, spawn, spawnSync } from 'node:child_process' +import { existsSync } from 'node:fs' +import { readFile } from 'node:fs/promises' +import dedent from 'dedent' +import { fdir } from 'fdir' +import { basename, extname, join, resolve } from 'pathe' +import pc from 'picocolors' +import { z } from 'zod' + +import type { ContractConfig, Plugin } from '../config.js' +import * as logger from '../logger.js' +import type { Compute, RequiredBy } from '../types.js' + +export const foundryDefaultExcludes = [ + 'Base.sol/**', + 'Common.sol/**', + 'Components.sol/**', + 'IERC165.sol/**', + 'IERC20.sol/**', + 'IERC721.sol/**', + 'IMulticall2.sol/**', + 'MockERC20.sol/**', + 'MockERC721.sol/**', + 'Script.sol/**', + 'StdAssertions.sol/**', + 'StdChains.sol/**', + 'StdCheats.sol/**', + 'StdError.sol/**', + 'StdInvariant.sol/**', + 'StdJson.sol/**', + 'StdMath.sol/**', + 'StdStorage.sol/**', + 'StdStyle.sol/**', + 'StdToml.sol/**', + 'StdUtils.sol/**', + 'Test.sol/**', + 'Vm.sol/**', + 'build-info/**', + 'console.sol/**', + 'console2.sol/**', + 'safeconsole.sol/**', + '**.s.sol/*.json', + '**.t.sol/*.json', +] + +export type FoundryConfig = { + /** + * Project's artifacts directory. + * + * Same as your project's `--out` (`-o`) option. + * + * @default foundry.config#out | 'out' + */ + artifacts?: string | undefined + /** Mapping of addresses to attach to artifacts. */ + deployments?: { [key: string]: ContractConfig['address'] } | undefined + /** Artifact files to exclude. */ + exclude?: string[] | undefined + /** [Forge](https://book.getfoundry.sh/forge) configuration */ + forge?: + | { + /** + * Remove build artifacts and cache directories on start up. + * + * @default false + */ + clean?: boolean | undefined + /** + * Build Foundry project before fetching artifacts. + * + * @default true + */ + build?: boolean | undefined + /** + * Path to `forge` executable command + * + * @default "forge" + */ + path?: string | undefined + /** + * Rebuild every time a watched file or directory is changed. + * + * @default true + */ + rebuild?: boolean | undefined + } + | undefined + /** Artifact files to include. */ + include?: string[] | undefined + /** Optional prefix to prepend to artifact names. */ + namePrefix?: string | undefined + /** Path to foundry project. */ + project?: string | undefined +} + +type FoundryResult = Compute< + RequiredBy +> + +const FoundryConfigSchema = z.object({ + out: z.string().default('out'), + src: z.string().default('src'), +}) + +/** Resolves ABIs from [Foundry](https://github.com/foundry-rs/foundry) project. */ +export function foundry(config: FoundryConfig = {}): FoundryResult { + const { + artifacts, + deployments = {}, + exclude = foundryDefaultExcludes, + forge: { + clean = false, + build = true, + path: forgeExecutable = 'forge', + rebuild = true, + } = {}, + include = ['*.json'], + namePrefix = '', + } = config + + function getContractName(artifactPath: string, usePrefix = true) { + const filename = basename(artifactPath) + const extension = extname(artifactPath) + return `${usePrefix ? namePrefix : ''}${filename.replace(extension, '')}` + } + + async function getContract(artifactPath: string) { + const artifact = await JSON.parse(await readFile(artifactPath, 'utf8')) + return { + abi: artifact.abi, + address: (deployments as Record)[ + getContractName(artifactPath, false) + ], + name: getContractName(artifactPath), + } + } + + function getArtifactPaths(artifactsDirectory: string) { + const crawler = new fdir().withBasePath().globWithOptions( + include.map((x) => `${artifactsDirectory}/**/${x}`), + { + dot: true, + ignore: exclude.map((x) => `${artifactsDirectory}/**/${x}`), + }, + ) + return crawler.crawl(artifactsDirectory).withPromise() + } + + const project = resolve(process.cwd(), config.project ?? '') + + let foundryConfig: z.infer = { + out: 'out', + src: 'src', + } + try { + const result = spawnSync( + forgeExecutable, + ['config', '--json', '--root', project], + { + encoding: 'utf-8', + shell: true, + }, + ) + if (result.error) throw result.error + if (result.status !== 0) + throw new Error(`Failed with code ${result.status}`) + if (result.signal) throw new Error('Process terminated by signal') + foundryConfig = FoundryConfigSchema.parse(JSON.parse(result.stdout)) + } catch { + } finally { + foundryConfig = { + ...foundryConfig, + out: artifacts ?? foundryConfig.out, + } + } + + const artifactsDirectory = join(project, foundryConfig.out) + + return { + async contracts() { + if (clean) + execSync(`${forgeExecutable} clean --root ${project}`, { + encoding: 'utf-8', + stdio: 'pipe', + }) + if (build) + execSync(`${forgeExecutable} build --root ${project}`, { + encoding: 'utf-8', + stdio: 'pipe', + }) + if (!existsSync(artifactsDirectory)) + throw new Error('Artifacts not found.') + + const artifactPaths = await getArtifactPaths(artifactsDirectory) + const contracts = [] + for (const artifactPath of artifactPaths) { + const contract = await getContract(artifactPath) + if (!contract.abi?.length) continue + contracts.push(contract) + } + return contracts + }, + name: 'Foundry', + async validate() { + // Check that project directory exists + if (!existsSync(project)) + throw new Error(`Foundry project ${pc.gray(config.project)} not found.`) + + // Ensure forge is installed + if (clean || build || rebuild) + try { + execSync(`${forgeExecutable} --version`, { + encoding: 'utf-8', + stdio: 'pipe', + }) + } catch (_error) { + throw new Error(dedent` + forge must be installed to use Foundry plugin. + To install, follow the instructions at https://book.getfoundry.sh/getting-started/installation + `) + } + }, + watch: { + command: rebuild + ? async () => { + logger.log( + `${pc.magenta('Foundry')} Watching project at ${pc.gray( + project, + )}`, + ) + const subprocess = spawn(forgeExecutable, [ + 'build', + '--watch', + '--root', + project, + ]) + subprocess.stdout?.on('data', (data) => { + process.stdout.write(`${pc.magenta('Foundry')} ${data}`) + }) + + process.once('SIGINT', shutdown) + process.once('SIGTERM', shutdown) + function shutdown() { + subprocess?.kill() + } + } + : undefined, + paths: [ + ...include.map((x) => `${artifactsDirectory}/**/${x}`), + ...exclude.map((x) => `!${artifactsDirectory}/**/${x}`), + ], + async onAdd(path) { + return getContract(path) + }, + async onChange(path) { + return getContract(path) + }, + async onRemove(path) { + return getContractName(path) + }, + }, + } +} diff --git a/packages/cli/src/plugins/hardhat.test.ts b/packages/cli/src/plugins/hardhat.test.ts new file mode 100644 index 0000000000..efb416c5e6 --- /dev/null +++ b/packages/cli/src/plugins/hardhat.test.ts @@ -0,0 +1,85 @@ +import fixtures from 'fixturez' +import { dirname, resolve } from 'pathe' +import { afterEach, expect, test, vi } from 'vitest' + +import { hardhat } from './hardhat.js' + +const f = fixtures(__dirname) + +afterEach(() => { + vi.restoreAllMocks() +}) + +test('validate', async () => { + const temp = f.temp() + expect( + hardhat({ project: temp }).validate?.(), + ).rejects.toThrowErrorMatchingInlineSnapshot( + '[Error: hardhat must be installed to use Hardhat plugin.]', + ) +}) + +test('project does not exist', async () => { + const dir = f.temp() + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + try { + await hardhat({ project: '../path/to/project' }).validate?.() + } catch (error) { + expect( + (error as Error).message.replace(dirname(dir), '..'), + ).toMatchInlineSnapshot('"Hardhat project ../path/to/project not found."') + } +}) + +test('contracts', async () => { + expect( + hardhat({ + project: resolve(__dirname, '__fixtures__/hardhat/'), + exclude: ['Foo.sol/**'], + }).contracts?.(), + ).resolves.toMatchInlineSnapshot(` + [ + { + "abi": [ + { + "inputs": [], + "name": "increment", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + { + "inputs": [], + "name": "number", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256", + }, + ], + "stateMutability": "view", + "type": "function", + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newNumber", + "type": "uint256", + }, + ], + "name": "setNumber", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "address": undefined, + "name": "Counter", + }, + ] + `) +}, 10_000) diff --git a/packages/cli/src/plugins/hardhat.ts b/packages/cli/src/plugins/hardhat.ts new file mode 100644 index 0000000000..a4feb6efdf --- /dev/null +++ b/packages/cli/src/plugins/hardhat.ts @@ -0,0 +1,235 @@ +import { execSync, spawn } from 'node:child_process' +import { existsSync } from 'node:fs' +import { readFile } from 'node:fs/promises' +import { fdir } from 'fdir' +import { basename, extname, join, resolve } from 'pathe' +import pc from 'picocolors' + +import type { ContractConfig, Plugin } from '../config.js' +import * as logger from '../logger.js' +import type { Compute, RequiredBy } from '../types.js' +import { getIsPackageInstalled, getPackageManager } from '../utils/packages.js' + +export const hardhatDefaultExcludes = ['build-info/**', '*.dbg.json'] + +export type HardhatConfig = { + /** + * Project's artifacts directory. + * + * Same as your project's `artifacts` [path configuration](https://hardhat.org/hardhat-runner/docs/config#path-configuration) option. + * + * @default 'artifacts/' + */ + artifacts?: string | undefined + /** Mapping of addresses to attach to artifacts. */ + deployments?: { [key: string]: ContractConfig['address'] } | undefined + /** Artifact files to exclude. */ + exclude?: string[] | undefined + /** Commands to run */ + commands?: + | { + /** + * Remove build artifacts and cache directories on start up. + * + * @default `${packageManger} hardhat clean` + */ + clean?: string | boolean | undefined + /** + * Build Hardhat project before fetching artifacts. + * + * @default `${packageManger} hardhat compile` + */ + build?: string | boolean | undefined + /** + * Command to run when watched file or directory is changed. + * + * @default `${packageManger} hardhat compile` + */ + rebuild?: string | boolean | undefined + } + | undefined + /** Artifact files to include. */ + include?: string[] | undefined + /** Optional prefix to prepend to artifact names. */ + namePrefix?: string | undefined + /** Path to Hardhat project. */ + project: string + /** + * Project's artifacts directory. + * + * Same as your project's `sources` [path configuration](https://hardhat.org/hardhat-runner/docs/config#path-configuration) option. + * + * @default 'contracts/' + */ + sources?: string | undefined +} + +type HardhatResult = Compute< + RequiredBy +> + +/** Resolves ABIs from [Hardhat](https://github.com/NomicFoundation/hardhat) project. */ +export function hardhat(config: HardhatConfig): HardhatResult { + const { + artifacts = 'artifacts', + deployments = {}, + exclude = hardhatDefaultExcludes, + commands = {}, + include = ['*.json'], + namePrefix = '', + sources = 'contracts', + } = config + + function getContractName(artifact: { contractName: string }) { + return `${namePrefix}${artifact.contractName}` + } + + async function getContract(artifactPath: string) { + const artifact = await JSON.parse(await readFile(artifactPath, 'utf8')) + return { + abi: artifact.abi, + address: deployments[artifact.contractName], + name: getContractName(artifact), + } + } + + function getArtifactPaths(artifactsDirectory: string) { + const crawler = new fdir().withBasePath().globWithOptions( + include.map((x) => `${artifactsDirectory}/**/${x}`), + { + dot: true, + ignore: exclude.map((x) => `${artifactsDirectory}/**/${x}`), + }, + ) + return crawler.crawl(artifactsDirectory).withPromise() + } + + const project = resolve(process.cwd(), config.project) + const artifactsDirectory = join(project, artifacts) + const sourcesDirectory = join(project, sources) + + const { build = true, clean = false, rebuild = true } = commands + return { + async contracts() { + if (clean) { + const packageManager = await getPackageManager(true) + const [command, ...options] = ( + typeof clean === 'boolean' ? `${packageManager} hardhat clean` : clean + ).split(' ') + execSync(`${command!} ${options.join(' ')}`, { + cwd: project, + encoding: 'utf-8', + stdio: 'pipe', + }) + } + if (build) { + const packageManager = await getPackageManager(true) + const [command, ...options] = ( + typeof build === 'boolean' + ? `${packageManager} hardhat compile` + : build + ).split(' ') + execSync(`${command!} ${options.join(' ')}`, { + cwd: project, + encoding: 'utf-8', + stdio: 'pipe', + }) + } + if (!existsSync(artifactsDirectory)) + throw new Error('Artifacts not found.') + + const artifactPaths = await getArtifactPaths(artifactsDirectory) + const contracts = [] + for (const artifactPath of artifactPaths) { + const contract = await getContract(artifactPath) + if (!contract.abi?.length) continue + contracts.push(contract) + } + return contracts + }, + name: 'Hardhat', + async validate() { + // Check that project directory exists + if (!existsSync(project)) + throw new Error(`Hardhat project ${pc.gray(project)} not found.`) + + // Check that `hardhat` is installed + const packageName = 'hardhat' + const isPackageInstalled = await getIsPackageInstalled({ + packageName, + cwd: project, + }) + if (isPackageInstalled) return + throw new Error(`${packageName} must be installed to use Hardhat plugin.`) + }, + watch: { + command: rebuild + ? async () => { + logger.log( + `${pc.blue('Hardhat')} Watching project at ${pc.gray(project)}`, + ) + + const [command, ...options] = ( + typeof rebuild === 'boolean' + ? `${await getPackageManager(true)} hardhat compile` + : rebuild + ).split(' ') + + const { watch } = await import('chokidar') + const watcher = watch(sourcesDirectory, { + atomic: true, + awaitWriteFinish: true, + ignoreInitial: true, + persistent: true, + }) + watcher.on('all', async (event, path) => { + if (event !== 'change' && event !== 'add' && event !== 'unlink') + return + logger.log( + `${pc.blue('Hardhat')} Detected ${event} at ${basename(path)}`, + ) + const subprocess = spawn(command!, options, { + cwd: project, + }) + subprocess.stdout?.on('data', (data) => { + process.stdout.write(`${pc.blue('Hardhat')} ${data}`) + }) + }) + + process.once('SIGINT', shutdown) + process.once('SIGTERM', shutdown) + async function shutdown() { + await watcher.close() + } + } + : undefined, + paths: [ + artifactsDirectory, + ...include.map((x) => `${artifactsDirectory}/**/${x}`), + ...exclude.map((x) => `!${artifactsDirectory}/**/${x}`), + ], + async onAdd(path) { + return getContract(path) + }, + async onChange(path) { + return getContract(path) + }, + async onRemove(path) { + const filename = basename(path) + const extension = extname(path) + // Since we can't use `getContractName`, guess from path + const removedContractName = `${namePrefix}${filename.replace( + extension, + '', + )}` + const artifactPaths = await getArtifactPaths(artifactsDirectory) + for (const artifactPath of artifactPaths) { + const contract = await getContract(artifactPath) + // If contract with same name exists, don't remove + if (contract.name === removedContractName) return + } + return removedContractName + }, + }, + } +} diff --git a/packages/cli/src/plugins/react.test.ts b/packages/cli/src/plugins/react.test.ts new file mode 100644 index 0000000000..939a5299ae --- /dev/null +++ b/packages/cli/src/plugins/react.test.ts @@ -0,0 +1,337 @@ +import { erc20Abi } from 'viem' +import { expect, test } from 'vitest' + +import { react } from './react.js' + +test('default', async () => { + const result = await react().run?.({ + contracts: [ + { + name: 'erc20', + abi: erc20Abi, + content: '', + meta: { + abiName: 'erc20Abi', + }, + }, + ], + isTypeScript: true, + outputs: [], + }) + + expect(result?.imports).toMatchInlineSnapshot(` + "import { createUseReadContract, createUseWriteContract, createUseSimulateContract, createUseWatchContractEvent } from 'wagmi/codegen' + " + `) + expect(result?.content).toMatchInlineSnapshot(` + "/** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const useReadErc20 = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"allowance"\` + */ + export const useReadErc20Allowance = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, functionName: 'allowance' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"balanceOf"\` + */ + export const useReadErc20BalanceOf = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, functionName: 'balanceOf' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"decimals"\` + */ + export const useReadErc20Decimals = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, functionName: 'decimals' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"name"\` + */ + export const useReadErc20Name = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, functionName: 'name' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"symbol"\` + */ + export const useReadErc20Symbol = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, functionName: 'symbol' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"totalSupply"\` + */ + export const useReadErc20TotalSupply = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, functionName: 'totalSupply' }) + + /** + * Wraps __{@link useWriteContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const useWriteErc20 = /*#__PURE__*/ createUseWriteContract({ abi: erc20Abi }) + + /** + * Wraps __{@link useWriteContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"approve"\` + */ + export const useWriteErc20Approve = /*#__PURE__*/ createUseWriteContract({ abi: erc20Abi, functionName: 'approve' }) + + /** + * Wraps __{@link useWriteContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transfer"\` + */ + export const useWriteErc20Transfer = /*#__PURE__*/ createUseWriteContract({ abi: erc20Abi, functionName: 'transfer' }) + + /** + * Wraps __{@link useWriteContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transferFrom"\` + */ + export const useWriteErc20TransferFrom = /*#__PURE__*/ createUseWriteContract({ abi: erc20Abi, functionName: 'transferFrom' }) + + /** + * Wraps __{@link useSimulateContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const useSimulateErc20 = /*#__PURE__*/ createUseSimulateContract({ abi: erc20Abi }) + + /** + * Wraps __{@link useSimulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"approve"\` + */ + export const useSimulateErc20Approve = /*#__PURE__*/ createUseSimulateContract({ abi: erc20Abi, functionName: 'approve' }) + + /** + * Wraps __{@link useSimulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transfer"\` + */ + export const useSimulateErc20Transfer = /*#__PURE__*/ createUseSimulateContract({ abi: erc20Abi, functionName: 'transfer' }) + + /** + * Wraps __{@link useSimulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transferFrom"\` + */ + export const useSimulateErc20TransferFrom = /*#__PURE__*/ createUseSimulateContract({ abi: erc20Abi, functionName: 'transferFrom' }) + + /** + * Wraps __{@link useWatchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const useWatchErc20Event = /*#__PURE__*/ createUseWatchContractEvent({ abi: erc20Abi }) + + /** + * Wraps __{@link useWatchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ and \`eventName\` set to \`"Approval"\` + */ + export const useWatchErc20ApprovalEvent = /*#__PURE__*/ createUseWatchContractEvent({ abi: erc20Abi, eventName: 'Approval' }) + + /** + * Wraps __{@link useWatchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ and \`eventName\` set to \`"Transfer"\` + */ + export const useWatchErc20TransferEvent = /*#__PURE__*/ createUseWatchContractEvent({ abi: erc20Abi, eventName: 'Transfer' })" + `) +}) + +test('address', async () => { + const result = await react().run?.({ + contracts: [ + { + name: 'erc20', + abi: erc20Abi, + content: '', + meta: { + abiName: 'erc20Abi', + addressName: 'erc20Address', + }, + }, + ], + isTypeScript: true, + outputs: [], + }) + + expect(result?.content).toMatchInlineSnapshot(` + "/** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const useReadErc20 = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"allowance"\` + */ + export const useReadErc20Allowance = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'allowance' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"balanceOf"\` + */ + export const useReadErc20BalanceOf = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'balanceOf' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"decimals"\` + */ + export const useReadErc20Decimals = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'decimals' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"name"\` + */ + export const useReadErc20Name = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'name' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"symbol"\` + */ + export const useReadErc20Symbol = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'symbol' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"totalSupply"\` + */ + export const useReadErc20TotalSupply = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'totalSupply' }) + + /** + * Wraps __{@link useWriteContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const useWriteErc20 = /*#__PURE__*/ createUseWriteContract({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link useWriteContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"approve"\` + */ + export const useWriteErc20Approve = /*#__PURE__*/ createUseWriteContract({ abi: erc20Abi, address: erc20Address, functionName: 'approve' }) + + /** + * Wraps __{@link useWriteContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transfer"\` + */ + export const useWriteErc20Transfer = /*#__PURE__*/ createUseWriteContract({ abi: erc20Abi, address: erc20Address, functionName: 'transfer' }) + + /** + * Wraps __{@link useWriteContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transferFrom"\` + */ + export const useWriteErc20TransferFrom = /*#__PURE__*/ createUseWriteContract({ abi: erc20Abi, address: erc20Address, functionName: 'transferFrom' }) + + /** + * Wraps __{@link useSimulateContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const useSimulateErc20 = /*#__PURE__*/ createUseSimulateContract({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link useSimulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"approve"\` + */ + export const useSimulateErc20Approve = /*#__PURE__*/ createUseSimulateContract({ abi: erc20Abi, address: erc20Address, functionName: 'approve' }) + + /** + * Wraps __{@link useSimulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transfer"\` + */ + export const useSimulateErc20Transfer = /*#__PURE__*/ createUseSimulateContract({ abi: erc20Abi, address: erc20Address, functionName: 'transfer' }) + + /** + * Wraps __{@link useSimulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transferFrom"\` + */ + export const useSimulateErc20TransferFrom = /*#__PURE__*/ createUseSimulateContract({ abi: erc20Abi, address: erc20Address, functionName: 'transferFrom' }) + + /** + * Wraps __{@link useWatchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const useWatchErc20Event = /*#__PURE__*/ createUseWatchContractEvent({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link useWatchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ and \`eventName\` set to \`"Approval"\` + */ + export const useWatchErc20ApprovalEvent = /*#__PURE__*/ createUseWatchContractEvent({ abi: erc20Abi, address: erc20Address, eventName: 'Approval' }) + + /** + * Wraps __{@link useWatchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ and \`eventName\` set to \`"Transfer"\` + */ + export const useWatchErc20TransferEvent = /*#__PURE__*/ createUseWatchContractEvent({ abi: erc20Abi, address: erc20Address, eventName: 'Transfer' })" + `) +}) + +test('legacy hook names', async () => { + const result = await react({ getHookName: 'legacy' }).run?.({ + contracts: [ + { + name: 'erc20', + abi: erc20Abi, + content: '', + meta: { + abiName: 'erc20Abi', + addressName: 'erc20Address', + }, + }, + ], + isTypeScript: true, + outputs: [], + }) + + expect(result?.content).toMatchInlineSnapshot(` + "/** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const useErc20Read = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"allowance"\` + */ + export const useErc20Allowance = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'allowance' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"balanceOf"\` + */ + export const useErc20BalanceOf = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'balanceOf' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"decimals"\` + */ + export const useErc20Decimals = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'decimals' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"name"\` + */ + export const useErc20Name = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'name' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"symbol"\` + */ + export const useErc20Symbol = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'symbol' }) + + /** + * Wraps __{@link useReadContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"totalSupply"\` + */ + export const useErc20TotalSupply = /*#__PURE__*/ createUseReadContract({ abi: erc20Abi, address: erc20Address, functionName: 'totalSupply' }) + + /** + * Wraps __{@link useWriteContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const useErc20Write = /*#__PURE__*/ createUseWriteContract({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link useWriteContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"approve"\` + */ + export const useErc20Approve = /*#__PURE__*/ createUseWriteContract({ abi: erc20Abi, address: erc20Address, functionName: 'approve' }) + + /** + * Wraps __{@link useWriteContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transfer"\` + */ + export const useErc20Transfer = /*#__PURE__*/ createUseWriteContract({ abi: erc20Abi, address: erc20Address, functionName: 'transfer' }) + + /** + * Wraps __{@link useWriteContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transferFrom"\` + */ + export const useErc20TransferFrom = /*#__PURE__*/ createUseWriteContract({ abi: erc20Abi, address: erc20Address, functionName: 'transferFrom' }) + + /** + * Wraps __{@link useSimulateContract}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const usePrepareErc20Write = /*#__PURE__*/ createUseSimulateContract({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link useSimulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"approve"\` + */ + export const usePrepareErc20Approve = /*#__PURE__*/ createUseSimulateContract({ abi: erc20Abi, address: erc20Address, functionName: 'approve' }) + + /** + * Wraps __{@link useSimulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transfer"\` + */ + export const usePrepareErc20Transfer = /*#__PURE__*/ createUseSimulateContract({ abi: erc20Abi, address: erc20Address, functionName: 'transfer' }) + + /** + * Wraps __{@link useSimulateContract}__ with \`abi\` set to __{@link erc20Abi}__ and \`functionName\` set to \`"transferFrom"\` + */ + export const usePrepareErc20TransferFrom = /*#__PURE__*/ createUseSimulateContract({ abi: erc20Abi, address: erc20Address, functionName: 'transferFrom' }) + + /** + * Wraps __{@link useWatchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ + */ + export const useErc20Event = /*#__PURE__*/ createUseWatchContractEvent({ abi: erc20Abi, address: erc20Address }) + + /** + * Wraps __{@link useWatchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ and \`eventName\` set to \`"Approval"\` + */ + export const useErc20ApprovalEvent = /*#__PURE__*/ createUseWatchContractEvent({ abi: erc20Abi, address: erc20Address, eventName: 'Approval' }) + + /** + * Wraps __{@link useWatchContractEvent}__ with \`abi\` set to __{@link erc20Abi}__ and \`eventName\` set to \`"Transfer"\` + */ + export const useErc20TransferEvent = /*#__PURE__*/ createUseWatchContractEvent({ abi: erc20Abi, address: erc20Address, eventName: 'Transfer' })" + `) +}) diff --git a/packages/cli/src/plugins/react.ts b/packages/cli/src/plugins/react.ts new file mode 100644 index 0000000000..b76ea006a5 --- /dev/null +++ b/packages/cli/src/plugins/react.ts @@ -0,0 +1,312 @@ +import { pascalCase } from 'change-case' + +import type { Contract, Plugin } from '../config.js' +import type { Compute, RequiredBy } from '../types.js' +import { getAddressDocString } from '../utils/getAddressDocString.js' + +export type ReactConfig = { + getHookName?: + | 'legacy' // TODO: Deprecate `'legacy'` option + | ((options: { + contractName: string + itemName?: string | undefined + type: 'read' | 'simulate' | 'watch' | 'write' + }) => `use${string}`) +} + +type ReactResult = Compute> + +export function react(config: ReactConfig = {}): ReactResult { + return { + name: 'React', + async run({ contracts }) { + const imports = new Set([]) + const content: string[] = [] + const pure = '/*#__PURE__*/' + + const hookNames = new Set() + for (const contract of contracts) { + let hasReadFunction = false + let hasWriteFunction = false + let hasEvent = false + const readItems = [] + const writeItems = [] + const eventItems = [] + for (const item of contract.abi) { + if (item.type === 'function') + if ( + item.stateMutability === 'view' || + item.stateMutability === 'pure' + ) { + hasReadFunction = true + readItems.push(item) + } else { + hasWriteFunction = true + writeItems.push(item) + } + else if (item.type === 'event') { + hasEvent = true + eventItems.push(item) + } + } + + let innerContent: string + if (contract.meta.addressName) + innerContent = `abi: ${contract.meta.abiName}, address: ${contract.meta.addressName}` + else innerContent = `abi: ${contract.meta.abiName}` + + if (hasReadFunction) { + const hookName = getHookName(config, hookNames, 'read', contract.name) + const docString = genDocString('useReadContract', contract) + const functionName = 'createUseReadContract' + imports.add(functionName) + content.push( + `${docString} +export const ${hookName} = ${pure} ${functionName}({ ${innerContent} })`, + ) + + const names = new Set() + for (const item of readItems) { + if (item.type !== 'function') continue + if ( + item.stateMutability !== 'pure' && + item.stateMutability !== 'view' + ) + continue + + // Skip overrides since they are captured by same hook + if (names.has(item.name)) continue + names.add(item.name) + + const hookName = getHookName( + config, + hookNames, + 'read', + contract.name, + item.name, + ) + const docString = genDocString('useReadContract', contract, { + name: 'functionName', + value: item.name, + }) + content.push( + `${docString} +export const ${hookName} = ${pure} ${functionName}({ ${innerContent}, functionName: '${item.name}' })`, + ) + } + } + + if (hasWriteFunction) { + { + const hookName = getHookName( + config, + hookNames, + 'write', + contract.name, + ) + const docString = genDocString('useWriteContract', contract) + const functionName = 'createUseWriteContract' + imports.add(functionName) + content.push( + `${docString} +export const ${hookName} = ${pure} ${functionName}({ ${innerContent} })`, + ) + + const names = new Set() + for (const item of writeItems) { + if (item.type !== 'function') continue + if ( + item.stateMutability !== 'nonpayable' && + item.stateMutability !== 'payable' + ) + continue + + // Skip overrides since they are captured by same hook + if (names.has(item.name)) continue + names.add(item.name) + + const hookName = getHookName( + config, + hookNames, + 'write', + contract.name, + item.name, + ) + const docString = genDocString('useWriteContract', contract, { + name: 'functionName', + value: item.name, + }) + content.push( + `${docString} +export const ${hookName} = ${pure} ${functionName}({ ${innerContent}, functionName: '${item.name}' })`, + ) + } + } + + { + const hookName = getHookName( + config, + hookNames, + 'simulate', + contract.name, + ) + const docString = genDocString('useSimulateContract', contract) + const functionName = 'createUseSimulateContract' + imports.add(functionName) + content.push( + `${docString} +export const ${hookName} = ${pure} ${functionName}({ ${innerContent} })`, + ) + + const names = new Set() + for (const item of writeItems) { + if (item.type !== 'function') continue + if ( + item.stateMutability !== 'nonpayable' && + item.stateMutability !== 'payable' + ) + continue + + // Skip overrides since they are captured by same hook + if (names.has(item.name)) continue + names.add(item.name) + + const hookName = getHookName( + config, + hookNames, + 'simulate', + contract.name, + item.name, + ) + const docString = genDocString('useSimulateContract', contract, { + name: 'functionName', + value: item.name, + }) + content.push( + `${docString} +export const ${hookName} = ${pure} ${functionName}({ ${innerContent}, functionName: '${item.name}' })`, + ) + } + } + } + + if (hasEvent) { + const hookName = getHookName( + config, + hookNames, + 'watch', + contract.name, + ) + const docString = genDocString('useWatchContractEvent', contract) + const functionName = 'createUseWatchContractEvent' + imports.add(functionName) + content.push( + `${docString} +export const ${hookName} = ${pure} ${functionName}({ ${innerContent} })`, + ) + + const names = new Set() + for (const item of eventItems) { + if (item.type !== 'event') continue + + // Skip overrides since they are captured by same hook + if (names.has(item.name)) continue + names.add(item.name) + + const hookName = getHookName( + config, + hookNames, + 'watch', + contract.name, + item.name, + ) + const docString = genDocString('useWatchContractEvent', contract, { + name: 'eventName', + value: item.name, + }) + content.push( + `${docString} +export const ${hookName} = ${pure} ${functionName}({ ${innerContent}, eventName: '${item.name}' })`, + ) + } + } + } + + const importValues = [...imports.values()] + + return { + imports: importValues.length + ? `import { ${importValues.join(', ')} } from 'wagmi/codegen'\n` + : '', + content: content.join('\n\n'), + } + }, + } +} + +function genDocString( + hookName: string, + contract: Contract, + item?: { name: string; value: string }, +) { + let description = `Wraps __{@link ${hookName}}__ with \`abi\` set to __{@link ${contract.meta.abiName}}__` + if (item) description += ` and \`${item.name}\` set to \`"${item.value}"\`` + + const docString = getAddressDocString({ address: contract.address }) + if (docString) + return `/** + * ${description} + * + ${docString} + */` + + return `/** + * ${description} + */` +} + +function getHookName( + config: ReactConfig, + hookNames: Set, + type: 'read' | 'simulate' | 'watch' | 'write', + contractName: string, + itemName?: string | undefined, +) { + const ContractName = pascalCase(contractName) + const ItemName = itemName ? pascalCase(itemName) : undefined + + let hookName: string + if (typeof config.getHookName === 'function') + hookName = config.getHookName({ + type, + contractName: ContractName, + itemName: ItemName, + }) + else if (typeof config.getHookName === 'string') { + switch (type) { + case 'read': + hookName = `use${ContractName}${ItemName ?? 'Read'}` + break + case 'simulate': + hookName = `usePrepare${ContractName}${ItemName ?? 'Write'}` + break + case 'watch': + hookName = `use${ContractName}${ItemName ?? ''}Event` + break + case 'write': + hookName = `use${ContractName}${ItemName ?? 'Write'}` + break + } + } else { + hookName = `use${pascalCase(type)}${ContractName}${ItemName ?? ''}` + if (type === 'watch') hookName = `${hookName}Event` + } + + if (hookNames.has(hookName)) + throw new Error( + `Hook name "${hookName}" must be unique for contract "${contractName}". Try using \`getHookName\` to create a unique name.`, + ) + + hookNames.add(hookName) + return hookName +} diff --git a/packages/cli/src/plugins/sourcify.test.ts b/packages/cli/src/plugins/sourcify.test.ts new file mode 100644 index 0000000000..842a291147 --- /dev/null +++ b/packages/cli/src/plugins/sourcify.test.ts @@ -0,0 +1,83 @@ +import { http, HttpResponse } from 'msw' +import { setupServer } from 'msw/node' +import { afterAll, afterEach, beforeAll, expect, test } from 'vitest' + +import { depositAbi } from '../../test/constants.js' +import { sourcify } from './sourcify.js' + +const baseUrl = 'https://sourcify.dev/server/v2/contract' +const address = '0x00000000219ab540356cbb839cbe05303d7705fa' +const chainId = 1 +const multichainAddress = '0xC4c622862a8F548997699bE24EA4bc504e5cA865' +const multichainIdGnosis = 100 +const multichainIdPolygon = 137 +const successJson = { + abi: depositAbi, +} + +const handlers = [ + http.get(`${baseUrl}/${chainId}/${address}`, () => + HttpResponse.json(successJson), + ), + http.get(`${baseUrl}/${multichainIdGnosis}/${address}`, () => + HttpResponse.json({}, { status: 404 }), + ), + http.get(`${baseUrl}/${multichainIdGnosis}/${multichainAddress}`, () => + HttpResponse.json(successJson), + ), + http.get(`${baseUrl}/${multichainIdPolygon}/${multichainAddress}`, () => + HttpResponse.json(successJson), + ), +] + +const server = setupServer(...handlers) + +beforeAll(() => server.listen()) +afterEach(() => server.resetHandlers()) +afterAll(() => server.close()) + +test('fetches ABI', () => { + expect( + sourcify({ + chainId: chainId, + contracts: [{ name: 'DepositContract', address }], + }).contracts?.(), + ).resolves.toMatchSnapshot() +}) + +test('fetches ABI with multichain deployment', () => { + expect( + sourcify({ + chainId: 100, + contracts: [ + { + name: 'Community', + address: { 100: multichainAddress, 137: multichainAddress }, + }, + ], + }).contracts?.(), + ).resolves.toMatchSnapshot() +}) + +test('fails to fetch for unverified contract', () => { + expect( + sourcify({ + chainId: 100, + contracts: [{ name: 'DepositContract', address }], + }).contracts?.(), + ).rejects.toThrowErrorMatchingInlineSnapshot( + '[Error: Contract not found in Sourcify repository.]', + ) +}) + +test('missing address for chainId', () => { + expect( + sourcify({ + chainId: 1, + // @ts-expect-error `chainId` and `keyof typeof contracts[number].address` mismatch + contracts: [{ name: 'DepositContract', address: { 10: address } }], + }).contracts?.(), + ).rejects.toThrowErrorMatchingInlineSnapshot( + `[Error: No address found for chainId "1". Make sure chainId "1" is set as an address.]`, + ) +}) diff --git a/packages/cli/src/plugins/sourcify.ts b/packages/cli/src/plugins/sourcify.ts new file mode 100644 index 0000000000..0d452046ca --- /dev/null +++ b/packages/cli/src/plugins/sourcify.ts @@ -0,0 +1,312 @@ +import { Abi as AbiSchema } from 'abitype/zod' +import type { Address } from 'viem' +import { z } from 'zod' + +import type { ContractConfig } from '../config.js' +import { fromZodError } from '../errors.js' +import type { Compute } from '../types.js' +import { fetch } from './fetch.js' + +export type SourcifyConfig = { + /** + * Duration in milliseconds to cache ABIs. + * + * @default 1_800_000 // 30m in ms + */ + cacheDuration?: number | undefined + /** + * Chain id to use for fetching ABI. + * + * If `address` is an object, `chainId` is used to select the address. + * + * See https://docs.sourcify.dev/docs/chains for supported chains. + */ + chainId: (chainId extends ChainId ? chainId : never) | (ChainId & {}) + /** + * Contracts to fetch ABIs for. + */ + contracts: Compute, 'abi'>>[] +} + +const SourcifyResponse = z.object({ + abi: AbiSchema, +}) + +/** Fetches contract ABIs from Sourcify. */ +export function sourcify( + config: SourcifyConfig, +) { + const { cacheDuration, chainId, contracts: contracts_ } = config + + const contracts = contracts_.map((x) => ({ + ...x, + address: + typeof x.address === 'string' ? { [chainId]: x.address } : x.address, + })) as Omit[] + + return fetch({ + cacheDuration, + contracts, + async parse({ response }) { + if (response.status === 404) + throw new Error('Contract not found in Sourcify repository.') + + const json = await response.json() + const parsed = await SourcifyResponse.safeParseAsync(json) + if (!parsed.success) + throw fromZodError(parsed.error, { prefix: 'Invalid response' }) + + if (parsed.data.abi) return parsed.data.abi as ContractConfig['abi'] + throw new Error('contract not found') + }, + request({ address }) { + if (!address) throw new Error('address is required') + + let contractAddress: Address | undefined + if (typeof address === 'string') contractAddress = address + else if (typeof address === 'object') contractAddress = address[chainId] + + if (!contractAddress) + throw new Error( + `No address found for chainId "${chainId}". Make sure chainId "${chainId}" is set as an address.`, + ) + return { + url: `https://sourcify.dev/server/v2/contract/${chainId}/${contractAddress}?fields=abi`, + } + }, + }) +} + +// Supported chains +// https://docs.sourcify.dev/docs/chains +type ChainId = + | 1 // Ethereum Mainnet + | 17000 // Ethereum Testnet Holesky + | 5 // Ethereum Testnet Goerli + | 11155111 // Ethereum Testnet Sepolia + | 3 // Ethereum Testnet Ropsten + | 4 // Ethereum Testnet Rinkeby + | 10 // OP Mainnet + | 100 // Gnosis + | 100009 // VeChain + | 100010 // VeChain Testnet + | 1001 // Kaia Kairos Testnet + | 10200 // Gnosis Chiado Testnet + | 10242 // Arthera Mainnet + | 10243 // Arthera Testnet + | 1030 // Conflux eSpace + | 103090 // Crystaleum + | 105105 // Stratis Mainnet + | 106 // Velas EVM Mainnet + | 10849 // Lamina1 + | 10850 // Lamina1 Identity + | 1088 // Metis Andromeda Mainnet + | 1101 // Polygon zkEVM + | 111000 // Siberium Test Network + | 11111 // WAGMI + | 1114 // Core Blockchain Testnet2 + | 1115 // Core Blockchain Testnet + | 11155420 // OP Sepolia Testnet + | 1116 // Core Blockchain Mainnet + | 11235 // Haqq Network + | 1127469 // Tiltyard Subnet + | 11297108099 // Palm Testnet + | 11297108109 // Palm + | 1149 // Symplexia Smart Chain + | 122 // Fuse Mainnet + | 1284 // Moonbeam + | 1285 // Moonriver + | 1287 // Moonbase Alpha + | 12898 // PlayFair Testnet Subnet + | 1291 // Swisstronik Testnet + | 1313161554 // Aurora Mainnet + | 1313161555 // Aurora Testnet + | 13337 // Beam Testnet + | 13381 // Phoenix Mainnet + | 1339 // Elysium Mainnet + | 137 // Polygon Mainnet + | 14 // Flare Mainnet + | 1433 // Rikeza Network Mainnet + | 1516 // Story Odyssey Testnet + | 16180 // PLYR PHI + | 16350 // Incentiv Devnet + | 167005 // Taiko Grimsvotn L2 + | 167006 // Taiko Eldfell L3 + | 17069 // Garnet Holesky + | 180 // AME Chain Mainnet + | 1890 // Lightlink Phoenix Mainnet + | 1891 // Lightlink Pegasus Testnet + | 19 // Songbird Canary-Network + | 19011 // HOME Verse Mainnet + | 192837465 // Gather Mainnet Network + | 2000 // Dogechain Mainnet + | 200810 // Bitlayer Testnet + | 200901 // Bitlayer Mainnet + | 2017 // Adiri + | 2020 // Ronin Mainnet + | 2021 // Edgeware EdgeEVM Mainnet + | 202401 // YMTECH-BESU Testnet + | 2037 // Kiwi Subnet + | 2038 // Shrapnel Testnet + | 2044 // Shrapnel Subnet + | 2047 // Stratos Testnet + | 2048 // Stratos + | 205205 // Auroria Testnet + | 212 // MAPO Makalu + | 216 // Happychain Testnet + | 222000222 // Kanazawa + | 2221 // Kava Testnet + | 2222 // Kava + | 223 // B2 Mainnet + | 22776 // MAP Protocol + | 23294 // Oasis Sapphire + | 23295 // Oasis Sapphire Testnet + | 2358 // Kroma Sepolia + | 2442 // Polygon zkEVM Cardona Testnet + | 246 // Energy Web Chain + | 25 // Cronos Mainnet + | 250 // Fantom Opera + | 252 // Fraxtal + | 2522 // Fraxtal Testnet + | 255 // Kroma + | 25925 // KUB Testnet + | 26100 // Ferrum Quantum Portal Network + | 28 // Boba Network Rinkeby Testnet + | 28528 // Optimism Bedrock (Goerli Alpha Testnet) + | 288 // Boba Network + | 295 // Hedera Mainnet + | 30 // Rootstock Mainnet + | 300 // zkSync Sepolia Testnet + | 311752642 // OneLedger Mainnet + | 314 // Filecoin - Mainnet + | 314159 // Filecoin - Calibration testnet + | 32769 // Zilliqa EVM + | 32770 // Zilliqa 2 EVM proto-mainnet + | 33101 // Zilliqa EVM Testnet + | 33103 // Zilliqa 2 EVM proto-testnet + | 33111 // Curtis + | 333000333 // Meld + | 335 // DFK Chain Test + | 336 // Shiden + | 34443 // Mode + | 35441 // Q Mainnet + | 35443 // Q Testnet + | 356256156 // Gather Testnet Network + | 369 // PulseChain + | 3737 // Crossbell + | 37714555429 // Xai Testnet v2 + | 383414847825 // Zeniq + | 39797 // Energi Mainnet + | 40 // Telos EVM Mainnet + | 4000 // Ozone Chain Mainnet + | 41 // Telos EVM Testnet + | 4157 // CrossFi Testnet + | 420 // Optimism Goerli Testnet + | 4200 // Merlin Mainnet + | 420420 // Kekchain + | 420666 // Kekchain (kektest) + | 42161 // Arbitrum One + | 421611 // Arbitrum Rinkeby + | 421613 // Arbitrum Goerli + | 4216137055 // OneLedger Testnet Frankenstein + | 421614 // Arbitrum Sepolia + | 42170 // Arbitrum Nova + | 42220 // Celo Mainnet + | 42261 // Oasis Emerald Testnet + | 42262 // Oasis Emerald + | 42766 // ZKFair Mainnet + | 43 // Darwinia Pangolin Testnet + | 43113 // Avalanche Fuji Testnet + | 43114 // Avalanche C-Chain + | 432201 // Dexalot Subnet Testnet + | 432204 // Dexalot Subnet + | 4337 // Beam + | 44 // Crab Network + | 44787 // Celo Alfajores Testnet + | 46 // Darwinia Network + | 486217935 // Gather Devnet Network + | 48898 // Zircuit Garfield Testnet + | 48899 // Zircuit Testnet + | 48900 // Zircuit Mainnet + | 49797 // Energi Testnet + | 50 // XDC Network + | 5000 // Mantle + | 5003 // Mantle Sepolia Testnet + | 51 // XDC Apothem Network + | 5115 // Citrea Testnet + | 534 // Candle + | 534351 // Scroll Sepolia Testnet + | 534352 // Scroll + | 53935 // DFK Chain + | 54211 // Haqq Chain Testnet + | 56 // BNB Smart Chain Mainnet + | 560048 // Hoodi testnet + | 57 // Syscoin Mainnet + | 570 // Rollux Mainnet + | 5700 // Syscoin Tanenbaum Testnet + | 57000 // Rollux Testnet + | 5845 // Tangle + | 59141 // Linea Sepolia + | 59144 // Linea + | 592 // Astar + | 59902 // Metis Sepolia Testnet + | 61 // Ethereum Classic + | 6119 // UPTN + | 62320 // Celo Baklava Testnet + | 62621 // MultiVAC Mainnet + | 62831 // PLYR TAU Testnet + | 6321 // Aura Euphoria Testnet + | 6322 // Aura Mainnet + | 641230 // Bear Network Chain Mainnet + | 648 // Endurance Smart Chain Mainnet + | 660279 // Xai Mainnet + | 666666666 // Degen Chain + | 69 // Optimism Kovan + | 690 // Redstone + | 7000 // ZetaChain Mainnet + | 7001 // ZetaChain Testnet + | 7078815900 // Mekong + | 710420 // Tiltyard Mainnet Subnet + | 71401 // Godwoken Testnet v1 + | 71402 // Godwoken Mainnet + | 7171 // Bitrock Mainnet + | 7200 // exSat Mainnet + | 723107 // TixChain Testnet + | 73799 // Energy Web Volta Testnet + | 764984 // Lamina1 Testnet + | 7668 // The Root Network - Mainnet + | 7672 // The Root Network - Porcini Testnet + | 767368 // Lamina1 Identity Testnet + | 77 // POA Network Sokol + | 7700 // Canto + | 7701 // Canto Tesnet + | 7771 // Bitrock Testnet + | 7777777 // Zora + | 78430 // Amplify Subnet + | 78431 // Bulletin Subnet + | 78432 // Conduit Subnet + | 8 // Ubiq + | 80001 // Mumbai + | 80002 // Amoy + | 82 // Meter Mainnet + | 8217 // Kaia Mainnet + | 83 // Meter Testnet + | 839999 // exSat Testnet + | 841 // Taraxa Mainnet + | 842 // Taraxa Testnet + | 8453 // Base + | 84531 // Base Goerli Testnet + | 84532 // Base Sepolia Testnet + | 888 // Wanchain + | 9000 // Evmos Testnet + | 9001 // Evmos + | 919 // Mode Testnet + | 957 // Lyra Chain + | 96 // KUB Mainnet + | 97 // BNB Smart Chain Testnet + | 970 // Oort Mainnet + | 99 // POA Network Core + | 9977 // Mind Smart Chain Testnet + | 999 // Wanchain Testnet + | 9996 // Mind Smart Chain Mainnet + | 999999999 // Zora Sepolia Testnet diff --git a/packages/cli/src/types.ts b/packages/cli/src/types.ts new file mode 100644 index 0000000000..adb2889348 --- /dev/null +++ b/packages/cli/src/types.ts @@ -0,0 +1,10 @@ +export type Compute = { [key in keyof type]: type[key] } & unknown + +export type MaybeArray = T | T[] + +export type MaybePromise = T | Promise + +export type RequiredBy = Required< + Pick +> & + Omit diff --git a/packages/cli/src/utils/findConfig.test.ts b/packages/cli/src/utils/findConfig.test.ts new file mode 100644 index 0000000000..52c2066773 --- /dev/null +++ b/packages/cli/src/utils/findConfig.test.ts @@ -0,0 +1,42 @@ +import { afterEach, expect, test, vi } from 'vitest' + +import { createFixture } from '../../test/utils.js' +import { findConfig } from './findConfig.js' + +afterEach(() => { + vi.restoreAllMocks() +}) + +test('finds config file', async () => { + const { dir, paths } = await createFixture({ + files: { 'wagmi.config.ts': '' }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(findConfig()).resolves.toBe(paths['wagmi.config.ts']) +}) + +test('finds config file at location', async () => { + const { dir, paths } = await createFixture({ + files: { 'wagmi.config.ts': '' }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(findConfig({ config: paths['wagmi.config.ts'] })).resolves.toBe( + paths['wagmi.config.ts'], + ) +}) + +test('finds config file at root', async () => { + const { dir, paths } = await createFixture({ + files: { 'wagmi.config.ts': '' }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(findConfig({ root: dir })).resolves.toBe( + paths['wagmi.config.ts'], + ) +}) diff --git a/packages/cli/src/utils/findConfig.ts b/packages/cli/src/utils/findConfig.ts new file mode 100644 index 0000000000..2e94e2d5a4 --- /dev/null +++ b/packages/cli/src/utils/findConfig.ts @@ -0,0 +1,39 @@ +import { existsSync } from 'node:fs' +import escalade from 'escalade' +import { resolve } from 'pathe' + +// Do not reorder +// In order of preference files are checked +const configFiles = [ + 'wagmi.config.ts', + 'wagmi.config.js', + 'wagmi.config.mjs', + 'wagmi.config.mts', +] + +type FindConfigParameters = { + /** Config file name */ + config?: string | undefined + /** Config file directory */ + root?: string | undefined +} + +/** + * Resolves path to wagmi CLI config file. + */ +export async function findConfig(parameters: FindConfigParameters = {}) { + const { config, root } = parameters + const rootDir = resolve(root || process.cwd()) + if (config) { + const path = resolve(rootDir, config) + if (existsSync(path)) return path + return + } + const configPath = await escalade(rootDir, (_dir, names) => { + for (const name of names) { + if (configFiles.includes(name)) return name + } + return undefined + }) + return configPath +} diff --git a/packages/cli/src/utils/format.test.ts b/packages/cli/src/utils/format.test.ts new file mode 100644 index 0000000000..6d04eb5465 --- /dev/null +++ b/packages/cli/src/utils/format.test.ts @@ -0,0 +1,12 @@ +import { expect, test } from 'vitest' + +import { format } from './format.js' + +test('formats code', async () => { + await expect( + format(`const foo = "bar"`), + ).resolves.toMatchInlineSnapshot(` + "const foo = 'bar' + " + `) +}) diff --git a/packages/cli/src/utils/format.ts b/packages/cli/src/utils/format.ts new file mode 100644 index 0000000000..d440e60471 --- /dev/null +++ b/packages/cli/src/utils/format.ts @@ -0,0 +1,17 @@ +import prettier from 'prettier' + +export async function format(content: string) { + const config = await prettier.resolveConfig(process.cwd()) + return prettier.format(content, { + arrowParens: 'always', + endOfLine: 'lf', + parser: 'typescript', + printWidth: 80, + semi: false, + singleQuote: true, + tabWidth: 2, + trailingComma: 'all', + ...config, + plugins: [], + }) +} diff --git a/packages/cli/src/utils/getAddressDocString.test.ts b/packages/cli/src/utils/getAddressDocString.test.ts new file mode 100644 index 0000000000..798e6e14e5 --- /dev/null +++ b/packages/cli/src/utils/getAddressDocString.test.ts @@ -0,0 +1,40 @@ +import { expect, test } from 'vitest' + +import { getAddressDocString } from './getAddressDocString.js' + +test('address', async () => { + expect( + getAddressDocString({ + address: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e', + }), + ).toMatchInlineSnapshot('""') +}) + +test('multichain address with known chain ids', async () => { + expect( + getAddressDocString({ + address: { + 1: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e', + 5: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e', + 10: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e', + }, + }), + ).toMatchInlineSnapshot(` + "* - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://optimistic.etherscan.io/address/0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e)" + `) +}) + +test('multichain address with unknown chain id', async () => { + expect( + getAddressDocString({ + address: { + 1: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e', + 2: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e', + }, + }), + ).toMatchInlineSnapshot( + '"* [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e)"', + ) +}) diff --git a/packages/cli/src/utils/getAddressDocString.ts b/packages/cli/src/utils/getAddressDocString.ts new file mode 100644 index 0000000000..d0e137928c --- /dev/null +++ b/packages/cli/src/utils/getAddressDocString.ts @@ -0,0 +1,53 @@ +import { capitalCase } from 'change-case' +import dedent from 'dedent' +import * as allChains from 'viem/chains' + +import type { Contract } from '../config.js' + +const chainMap: Record = {} +for (const chain of Object.values(allChains)) { + if (typeof chain !== 'object') continue + if (!('id' in chain)) continue + chainMap[chain.id] = chain +} + +export function getAddressDocString(parameters: { + address: Contract['address'] +}) { + const { address } = parameters + if (!address || typeof address === 'string') return '' + + if (Object.keys(address).length === 1) + return `* ${getLink({ + address: address[Number.parseInt(Object.keys(address)[0]!)]!, + chainId: Number.parseInt(Object.keys(address)[0]!), + })}` + + const addresses = Object.entries(address).filter( + (x) => chainMap[Number.parseInt(x[0])], + ) + if (addresses.length === 0) return '' + if (addresses.length === 1 && addresses[0]) + return `* ${getLink({ + address: addresses[0][1], + chainId: Number.parseInt(addresses[0][0])!, + })}` + + return dedent` + ${addresses.reduce((prev, curr) => { + const chainId = Number.parseInt(curr[0]) + const address = curr[1] + return `${prev}\n* - ${getLink({ address, chainId })}` + }, '')} + ` +} + +function getLink({ address, chainId }: { address: string; chainId: number }) { + const chain = chainMap[chainId] + if (!chain) return '' + const blockExplorer = chain.blockExplorers?.default + if (!blockExplorer) return '' + return `[__View Contract on ${capitalCase(chain.name)} ${capitalCase( + blockExplorer.name, + )}__](${blockExplorer.url}/address/${address})` +} diff --git a/packages/cli/src/utils/getIsUsingTypeScript.test.ts b/packages/cli/src/utils/getIsUsingTypeScript.test.ts new file mode 100644 index 0000000000..3ba7c86a65 --- /dev/null +++ b/packages/cli/src/utils/getIsUsingTypeScript.test.ts @@ -0,0 +1,43 @@ +import { afterEach, expect, test, vi } from 'vitest' + +import { createFixture } from '../../test/utils.js' +import { getIsUsingTypeScript } from './getIsUsingTypeScript.js' + +afterEach(() => { + vi.restoreAllMocks() +}) + +test('true if has tsconfig', async () => { + const { dir } = await createFixture({ + files: { + 'tsconfig.json': '', + }, + }) + + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(getIsUsingTypeScript()).resolves.toBe(true) +}) + +test('true if has wagmi.config', async () => { + const { dir } = await createFixture({ + files: { + 'wagmi.config.ts': '', + }, + }) + + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(getIsUsingTypeScript()).resolves.toBe(true) +}) + +test('false', async () => { + const { dir } = await createFixture() + + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + await expect(getIsUsingTypeScript()).resolves.toBe(false) +}) diff --git a/packages/cli/src/utils/getIsUsingTypeScript.ts b/packages/cli/src/utils/getIsUsingTypeScript.ts new file mode 100644 index 0000000000..bd2383b0eb --- /dev/null +++ b/packages/cli/src/utils/getIsUsingTypeScript.ts @@ -0,0 +1,33 @@ +import escalade from 'escalade' + +export async function getIsUsingTypeScript() { + try { + const cwd = process.cwd() + const tsconfig = await escalade(cwd, (_dir, names) => { + const files = [ + 'tsconfig.json', + 'tsconfig.base.json', + 'tsconfig.lib.json', + 'tsconfig.node.json', + ] + for (const name of names) { + if (files.includes(name)) return name + } + return undefined + }) + if (tsconfig) return true + + const wagmiConfig = await escalade(cwd, (_dir, names) => { + const files = ['wagmi.config.ts', 'wagmi.config.mts'] + for (const name of names) { + if (files.includes(name)) return name + } + return undefined + }) + if (wagmiConfig) return true + + return false + } catch { + return false + } +} diff --git a/packages/cli/src/utils/loadEnv.test.ts b/packages/cli/src/utils/loadEnv.test.ts new file mode 100644 index 0000000000..d577778eb0 --- /dev/null +++ b/packages/cli/src/utils/loadEnv.test.ts @@ -0,0 +1,77 @@ +import { afterEach, expect, test, vi } from 'vitest' + +import { createFixture } from '../../test/utils.js' +import { loadEnv } from './loadEnv.js' + +afterEach(() => { + vi.restoreAllMocks() +}) + +test('loads env', async () => { + const { dir } = await createFixture({ + files: { + '.env': ` + FOO=bar + SOME_ENV_VAR=1 + `, + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + expect(loadEnv()).toMatchInlineSnapshot(` + { + "FOO": "bar", + "SOME_ENV_VAR": "1", + } + `) +}) + +test('loads env from envDir', async () => { + const { dir } = await createFixture({ + files: { + '.env': ` + FOO=bar + SOME_ENV_VAR=1 + `, + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + expect(loadEnv({ envDir: dir })).toMatchInlineSnapshot(` + { + "FOO": "bar", + "SOME_ENV_VAR": "1", + } + `) +}) + +test('loads env with mode', async () => { + const mode = 'dev' + const { dir } = await createFixture({ + files: { + [`.env.${mode}`]: ` + FOO=bar + SOME_ENV_VAR=1 + `, + }, + }) + const spy = vi.spyOn(process, 'cwd') + spy.mockImplementation(() => dir) + + expect(loadEnv({ mode })).toMatchInlineSnapshot(` + { + "FOO": "bar", + "SOME_ENV_VAR": "1", + } + `) +}) + +test('throws error when mode is "local"', async () => { + expect(() => { + loadEnv({ mode: 'local' }) + }).toThrowErrorMatchingInlineSnapshot( + `[Error: "local" cannot be used as a mode name because it conflicts with the .local postfix for .env files.]`, + ) +}) diff --git a/packages/cli/src/utils/loadEnv.ts b/packages/cli/src/utils/loadEnv.ts new file mode 100644 index 0000000000..d7ffa99919 --- /dev/null +++ b/packages/cli/src/utils/loadEnv.ts @@ -0,0 +1,90 @@ +import { parse } from 'dotenv' +import { expand } from 'dotenv-expand' + +import { existsSync, readFileSync, statSync } from 'node:fs' +import { dirname, join } from 'node:path' + +// https://github.com/vitejs/vite/blob/main/packages/vite/src/node/env.ts#L7 +export function loadEnv( + config: { + mode?: string + envDir?: string + } = {}, +): Record { + const mode = config.mode + if (mode === 'local') { + throw new Error( + `"local" cannot be used as a mode name because it conflicts with the .local postfix for .env files.`, + ) + } + + const envFiles = [ + /** default file */ '.env', + /** local file */ '.env.local', + ...(mode + ? [ + /** mode file */ `.env.${mode}`, + /** mode local file */ `.env.${mode}.local`, + ] + : []), + ] + + const envDir = config.envDir ?? process.cwd() + const parsed = Object.fromEntries( + envFiles.flatMap((file) => { + const path = lookupFile(envDir, [file], { + pathOnly: true, + rootDir: envDir, + }) + if (!path) return [] + return Object.entries(parse(readFileSync(path))) + }), + ) + + try { + // let environment variables use each other + expand({ parsed }) + } catch (error) { + // custom error handling until https://github.com/motdotla/dotenv-expand/issues/65 is fixed upstream + // check for message "TypeError: Cannot read properties of undefined (reading 'split')" + if ((error as Error).message.includes('split')) { + throw new Error( + 'dotenv-expand failed to expand env vars. Maybe you need to escape `$`?', + ) + } + throw error + } + + return parsed +} + +function lookupFile( + dir: string, + formats: string[], + options?: { + pathOnly?: boolean + rootDir?: string + predicate?: (file: string) => boolean + }, +): string | undefined { + for (const format of formats) { + const fullPath = join(dir, format) + if (existsSync(fullPath) && statSync(fullPath).isFile()) { + const result = options?.pathOnly + ? fullPath + : readFileSync(fullPath, 'utf-8') + if (!options?.predicate || options.predicate(result)) { + return result + } + } + } + + const parentDir = dirname(dir) + if ( + parentDir !== dir && + (!options?.rootDir || parentDir.startsWith(options?.rootDir)) + ) + return lookupFile(parentDir, formats, options) + + return undefined +} diff --git a/packages/cli/src/utils/packages.test.ts b/packages/cli/src/utils/packages.test.ts new file mode 100644 index 0000000000..96ea2e26ef --- /dev/null +++ b/packages/cli/src/utils/packages.test.ts @@ -0,0 +1,19 @@ +import { expect, test } from 'vitest' + +import { getIsPackageInstalled, getPackageManager } from './packages.js' + +test('getIsPackageInstalled: true', async () => { + await expect(getIsPackageInstalled({ packageName: 'vitest' })).resolves.toBe( + true, + ) +}) + +test('getIsPackageInstalled: false', async () => { + await expect( + getIsPackageInstalled({ packageName: 'vitest-unknown' }), + ).resolves.toBe(false) +}) + +test('getPackageManager', async () => { + await expect(getPackageManager()).resolves.toMatchInlineSnapshot('"pnpm"') +}) diff --git a/packages/cli/src/utils/packages.ts b/packages/cli/src/utils/packages.ts new file mode 100644 index 0000000000..e55eeaf0ea --- /dev/null +++ b/packages/cli/src/utils/packages.ts @@ -0,0 +1,124 @@ +import { execSync } from 'node:child_process' +import { promises as fs } from 'node:fs' +import { resolve } from 'node:path' + +export async function getIsPackageInstalled(parameters: { + packageName: string + cwd?: string +}) { + const { packageName, cwd = process.cwd() } = parameters + try { + const packageManager = await getPackageManager() + const command = (() => { + switch (packageManager) { + case 'yarn': + return ['why', packageName] + case 'bun': + return ['pm', 'ls', '--all'] + default: + return ['ls', packageName] + } + })() + + const result = execSync(`${packageManager} ${command.join(' ')}`, { + cwd, + encoding: 'utf-8', + stdio: 'pipe', + }) + + // For Bun, we need to check if the package name is in the output + if (packageManager === 'bun') return result.includes(packageName) + + return result !== '' + } catch (_error) { + return false + } +} + +export async function getPackageManager(executable?: boolean | undefined) { + const userAgent = process.env.npm_config_user_agent + if (userAgent) { + if (userAgent.includes('pnpm')) return 'pnpm' + // The yarn@^3 user agent includes npm, so yarn must be checked first. + if (userAgent.includes('yarn')) return 'yarn' + if (userAgent.includes('npm')) return executable ? 'npx' : 'npm' + if (userAgent.includes('bun')) return executable ? 'bunx' : 'bun' + } + + const packageManager = await detect() + if (packageManager === 'npm' && executable) return 'npx' + return packageManager +} + +type PackageManager = 'npm' | 'yarn' | 'pnpm' | 'bun' + +async function detect( + parameters: { cwd?: string; includeGlobalBun?: boolean } = {}, +) { + const { cwd, includeGlobalBun } = parameters + const type = await getTypeofLockFile(cwd) + if (type) { + return type + } + const [hasYarn, hasPnpm, hasBun] = await Promise.all([ + hasGlobalInstallation('yarn'), + hasGlobalInstallation('pnpm'), + includeGlobalBun && hasGlobalInstallation('bun'), + ]) + if (hasYarn) return 'yarn' + if (hasPnpm) return 'pnpm' + if (hasBun) return 'bun' + return 'npm' +} + +const cache = new Map() + +function hasGlobalInstallation(pm: PackageManager): boolean { + const key = `has_global_${pm}` + if (cache.has(key)) return cache.get(key) + + try { + const result = execSync(`${pm} --version`, { + encoding: 'utf-8', + stdio: 'pipe', + }) + const isGlobal = /^\d+.\d+.\d+$/.test(result) + cache.set(key, isGlobal) + return isGlobal + } catch { + return false + } +} + +function getTypeofLockFile(cwd = '.'): Promise { + const key = `lockfile_${cwd}` + if (cache.has(key)) { + return Promise.resolve(cache.get(key)) + } + + return Promise.all([ + pathExists(resolve(cwd, 'yarn.lock')), + pathExists(resolve(cwd, 'package-lock.json')), + pathExists(resolve(cwd, 'pnpm-lock.yaml')), + pathExists(resolve(cwd, 'bun.lockb')), + ]).then(([isYarn, isNpm, isPnpm, isBun]) => { + let value: PackageManager | null = null + + if (isYarn) value = 'yarn' + else if (isPnpm) value = 'pnpm' + else if (isBun) value = 'bun' + else if (isNpm) value = 'npm' + + cache.set(key, value) + return value + }) +} + +async function pathExists(p: string) { + try { + await fs.access(p) + return true + } catch { + return false + } +} diff --git a/packages/cli/src/utils/resolveConfig.test.ts b/packages/cli/src/utils/resolveConfig.test.ts new file mode 100644 index 0000000000..6669edc9b6 --- /dev/null +++ b/packages/cli/src/utils/resolveConfig.test.ts @@ -0,0 +1,83 @@ +import { expect, test } from 'vitest' + +import { createFixture } from '../../test/utils.js' +import { defaultConfig } from '../config.js' +import { findConfig } from './findConfig.js' +import { resolveConfig } from './resolveConfig.js' + +test.skip('resolves config', async () => { + const { paths } = await createFixture({ + files: { + 'wagmi.config.ts': ` + import { defineConfig } from '@wagmi/cli' + + export default defineConfig(${JSON.stringify(defaultConfig)}) + `, + }, + }) + + const configPath = await findConfig({ + config: paths['wagmi.config.ts'], + }) + await expect( + resolveConfig({ configPath: configPath! }), + ).resolves.toMatchInlineSnapshot(` + { + "contracts": [], + "out": "src/generated.ts", + "plugins": [], + } + `) +}) + +test.skip('resolves function config', async () => { + const { paths } = await createFixture({ + files: { + 'wagmi.config.ts': ` + import { defineConfig } from '@wagmi/cli' + + export default defineConfig(() => (${JSON.stringify(defaultConfig)})) + `, + }, + }) + + const configPath = await findConfig({ + config: paths['wagmi.config.ts'], + }) + await expect( + resolveConfig({ configPath: configPath! }), + ).resolves.toMatchInlineSnapshot(` + { + "contracts": [], + "out": "src/generated.ts", + "plugins": [], + } + `) +}) + +test.skip('resolves array config', async () => { + const { paths } = await createFixture({ + files: { + 'wagmi.config.ts': ` + import { defineConfig } from '@wagmi/cli' + + export default defineConfig([${JSON.stringify(defaultConfig)}]) + `, + }, + }) + + const configPath = await findConfig({ + config: paths['wagmi.config.ts'], + }) + await expect( + resolveConfig({ configPath: configPath! }), + ).resolves.toMatchInlineSnapshot(` + [ + { + "contracts": [], + "out": "src/generated.ts", + "plugins": [], + }, + ] + `) +}) diff --git a/packages/cli/src/utils/resolveConfig.ts b/packages/cli/src/utils/resolveConfig.ts new file mode 100644 index 0000000000..048b1c337f --- /dev/null +++ b/packages/cli/src/utils/resolveConfig.ts @@ -0,0 +1,21 @@ +import { bundleRequire } from 'bundle-require' + +import type { Config } from '../config.js' +import type { MaybeArray } from '../types.js' + +type ResolveConfigParameters = { + /** Path to config file */ + configPath: string +} + +/** Bundles and returns wagmi config object from path. */ +export async function resolveConfig( + parameters: ResolveConfigParameters, +): Promise> { + const { configPath } = parameters + const res = await bundleRequire({ filepath: configPath }) + let config = res.mod.default + if (config.default) config = config.default + if (typeof config !== 'function') return config + return await config() +} diff --git a/packages/cli/src/version.ts b/packages/cli/src/version.ts new file mode 100644 index 0000000000..166b988ccb --- /dev/null +++ b/packages/cli/src/version.ts @@ -0,0 +1 @@ +export const version = '2.3.1' diff --git a/packages/cli/test/constants.ts b/packages/cli/test/constants.ts new file mode 100644 index 0000000000..9b84c5bb1b --- /dev/null +++ b/packages/cli/test/constants.ts @@ -0,0 +1,32 @@ +import { parseAbi } from 'viem' + +export const wagmiAbi = parseAbi([ + 'constructor()', + 'event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId)', + 'event ApprovalForAll(address indexed owner, address indexed operator, bool approved)', + 'event Transfer(address indexed from, address indexed to, uint256 indexed tokenId)', + 'function approve(address to, uint256 tokenId)', + 'function balanceOf(address owner) view returns (uint256)', + 'function getApproved(uint256 tokenId) view returns (address)', + 'function isApprovedForAll(address owner, address operator) view returns (bool)', + 'function mint()', + 'function name() view returns (string)', + 'function ownerOf(uint256 tokenId) view returns (address)', + 'function safeTransferFrom(address from, address to, uint256 tokenId)', + 'function safeTransferFrom(address from, address to, uint256 tokenId, bytes _data)', + 'function setApprovalForAll(address operator, bool approved)', + 'function supportsInterface(bytes4 interfaceId) view returns (bool)', + 'function symbol() view returns (string)', + 'function tokenURI(uint256 tokenId) pure returns (string)', + 'function totalSupply() view returns (uint256)', + 'function transferFrom(address from, address to, uint256 tokenId)', +]) + +export const depositAbi = parseAbi([ + 'constructor()', + 'event DepositEvent(bytes pubkey, bytes withdrawal_credentials, bytes amount, bytes signature, bytes index)', + 'function deposit(bytes pubkey, bytes withdrawal_credentials, bytes signature, bytes32 deposit_data_root) payable', + 'function get_deposit_count() view returns (bytes)', + 'function get_deposit_root() view returns (bytes32)', + 'function supportsInterface(bytes4 interfaceId) pure returns (bool)', +]) diff --git a/packages/cli/test/setup.ts b/packages/cli/test/setup.ts new file mode 100644 index 0000000000..d2eed4a5e5 --- /dev/null +++ b/packages/cli/test/setup.ts @@ -0,0 +1,57 @@ +import { mkdir } from 'node:fs/promises' +import { homedir } from 'node:os' +import type { createSpinner as nanospinner_createSpinner } from 'nanospinner' +import { join } from 'pathe' +import { vi } from 'vitest' + +const cacheDir = join(homedir(), '.wagmi-cli/plugins/fetch/cache') +await mkdir(cacheDir, { recursive: true }) + +vi.mock('nanospinner', async (importOriginal) => { + const mod = await importOriginal<{ + createSpinner: typeof nanospinner_createSpinner + }>() + + function createSpinner( + initialText: string, + opts: Parameters[1], + ) { + let currentText = '' + const spinner = mod.createSpinner(initialText, opts) + return { + ...spinner, + start(text = initialText) { + // biome-ignore lint/suspicious/noConsoleLog: console.log is used for logging + console.log(`- ${text}`) + spinner.start(text) + currentText = text + }, + success(text = currentText) { + // biome-ignore lint/suspicious/noConsoleLog: console.log is used for logging + console.log(`√ ${text}`) + spinner.success(text) + }, + error(text = currentText) { + console.error(`× ${text}`) + spinner.error(text) + }, + } + } + return { createSpinner } +}) + +vi.mock('picocolors', async () => { + function pass(input: string | number | null | undefined) { + return input + } + return { + default: { + blue: pass, + gray: pass, + green: pass, + red: pass, + white: pass, + yellow: pass, + }, + } +}) diff --git a/packages/cli/test/utils.ts b/packages/cli/test/utils.ts new file mode 100644 index 0000000000..4ea6c6051e --- /dev/null +++ b/packages/cli/test/utils.ts @@ -0,0 +1,292 @@ +import { spawnSync } from 'node:child_process' +import { cp, mkdir, symlink, writeFile } from 'node:fs/promises' +import fixtures from 'fixturez' +import { http, HttpResponse } from 'msw' +import * as path from 'pathe' +import { vi } from 'vitest' + +const f = fixtures(__dirname) + +type Json = + | string + | number + | boolean + | null + | { [property: string]: Json } + | Json[] + +export async function createFixture< + TFiles extends { [filename: string]: string | Json } & { + tsconfig?: true + }, +>( + config: { + copyNodeModules?: boolean + dir?: string + files?: TFiles + } = {}, +) { + const dir = config.dir ?? f.temp() + await mkdir(dir, { recursive: true }) + + // Create test files + const paths: { [_ in keyof TFiles]: string } = {} as any + await Promise.all( + (Object.keys(config.files ?? {}) as (keyof TFiles)[]).map( + async (filename_) => { + let file: Json | true | undefined + let filename = filename_ + if (filename === 'tsconfig') { + filename = 'tsconfig.json' + file = getTsConfig(dir) + } else file = config.files![filename] + + const filePath = path.join(dir, filename.toString()) + await mkdir(path.dirname(filePath), { recursive: true }) + + await writeFile( + filePath, + typeof file === 'string' ? file : JSON.stringify(file, null, 2), + ) + paths[filename === 'tsconfig.json' ? 'tsconfig' : filename] = filePath + }, + ), + ) + + if (config.copyNodeModules) { + await symlink( + path.join(__dirname, '../node_modules'), + path.join(dir, 'node_modules'), + 'dir', + ) + await cp( + path.join(__dirname, '../package.json'), + path.join(dir, 'package.json'), + ) + } + + return { + dir, + paths: paths, + } +} + +type TsConfig = { + compilerOptions: { [property: string]: any } + exclude: string[] + include: string[] +} +function getTsConfig(baseUrl: string) { + return { + compilerOptions: { + allowJs: true, + baseUrl: '.', + esModuleInterop: true, + forceConsistentCasingInFileNames: true, + incremental: true, + isolatedModules: true, + jsx: 'preserve', + lib: ['dom', 'dom.iterable', 'esnext'], + module: 'esnext', + moduleResolution: 'node', + noEmit: true, + paths: { + '@wagmi/cli': [path.relative(baseUrl, 'packages/cli/src')], + '@wagmi/cli/*': [path.relative(baseUrl, 'packages/cli/src/*')], + '@wagmi/connectors': [ + path.relative(baseUrl, 'packages/connectors/src'), + ], + '@wagmi/connectors/*': [ + path.relative(baseUrl, 'packages/connectors/src/*'), + ], + '@wagmi/core': [path.relative(baseUrl, 'packages/core/src')], + '@wagmi/core/*': [path.relative(baseUrl, 'packages/core/src/*')], + wagmi: [path.relative(baseUrl, 'packages/react/src')], + 'wagmi/*': [path.relative(baseUrl, 'packages/react/src/*')], + }, + resolveJsonModule: true, + skipLibCheck: true, + strict: true, + target: 'es6', + }, + include: [`${baseUrl}/**/*.ts`, `${baseUrl}/**/*.tsx`], + exclude: ['node_modules'], + } as TsConfig +} + +export function watchConsole() { + type Console = 'info' | 'log' | 'warn' | 'error' + const output: { [_ in Console | 'all']: string[] } = { + info: [], + log: [], + warn: [], + error: [], + all: [], + } + function handleOutput(method: Console) { + return (message: string) => { + output[method].push(message) + output.all.push(message) + } + } + return { + debug: console.debug, + info: vi.spyOn(console, 'info').mockImplementation(handleOutput('info')), + log: vi.spyOn(console, 'log').mockImplementation(handleOutput('log')), + warn: vi.spyOn(console, 'warn').mockImplementation(handleOutput('warn')), + error: vi.spyOn(console, 'error').mockImplementation(handleOutput('error')), + output, + get formatted() { + return output.all.join('\n') + }, + } +} + +export async function typecheck(project: string) { + try { + const result = spawnSync( + 'tsc', + ['--noEmit', '--target', 'es2021', '--pretty', 'false', '-p', project], + { + encoding: 'utf-8', + stdio: 'pipe', + }, + ) + if (result.error) throw result.error + if (result.status !== 0) + throw new Error(`Failed with code ${result.status}`) + if (result.signal) throw new Error('Process terminated by signal') + return result.stdout + } catch (error) { + throw new Error( + (error as Error).message.replaceAll( + path.dirname(project), + '/path/to/project', + ), + ) + } +} + +export const baseUrl = 'https://api.etherscan.io/v2/api' +export const apiKey = 'abc' +export const invalidApiKey = 'xyz' +export const address = '0xaf0326d92b97df1221759476b072abfd8084f9be' +export const proxyAddress = '0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48' +export const implementationAddress = + '0x43506849d7c04f9138d1a2050bbf3a0c054402dd' +export const unverifiedContractAddress = + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e' +export const timeoutAddress = '0xecb504d39723b0be0e3a9aa33d646642d1051ee1' + +export const handlers = [ + http.get(baseUrl, async ({ request }) => { + const url = new URL(request.url) + const search = url.search.replace(/^\?chainId=\d&/, '?') + + if ( + search === + `?module=contract&action=getabi&address=${unverifiedContractAddress}&apikey=${apiKey}` + ) + return HttpResponse.json({ + status: '0', + message: 'NOTOK', + result: 'Contract source code not verified', + }) + + if ( + search === + `?module=contract&action=getabi&address=${timeoutAddress}&apikey=${invalidApiKey}` + ) + return HttpResponse.json({ + status: '0', + message: 'NOTOK', + result: 'Invalid API Key', + }) + + if ( + search === + `?module=contract&action=getabi&address=${address}&apikey=${apiKey}` + ) + return HttpResponse.json({ + status: '1', + message: 'OK', + result: + '[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"}]', + }) + + if ( + search === + `?module=contract&action=getabi&address=${timeoutAddress}&apikey=${apiKey}` + ) { + await new Promise((resolve) => setTimeout(resolve, 10_000)) + return HttpResponse.json({}) + } + + if ( + search === + `?module=contract&action=getabi&address=${implementationAddress}&apikey=${apiKey}` + ) + return HttpResponse.json({ + status: '1', + message: 'OK', + result: + '[{"constant":false,"inputs":[{"name":"newImplementation","type":"address"}],"name":"upgradeTo","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"newImplementation","type":"address"},{"name":"data","type":"bytes"}],"name":"upgradeToAndCall","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[],"name":"implementation","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"newAdmin","type":"address"}],"name":"changeAdmin","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"admin","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[{"name":"_implementation","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"payable":true,"stateMutability":"payable","type":"fallback"},{"anonymous":false,"inputs":[{"indexed":false,"name":"previousAdmin","type":"address"},{"indexed":false,"name":"newAdmin","type":"address"}],"name":"AdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"implementation","type":"address"}],"name":"Upgraded","type":"event"}]', + }) + + if ( + search === + `?module=contract&action=getsourcecode&address=${proxyAddress}&apikey=${apiKey}` + ) + return HttpResponse.json({ + status: '1', + message: 'OK', + result: [ + { + SourceCode: '...', + ABI: '[{"constant":false,"inputs":[{"name":"newImplementation","type":"address"}],"name":"upgradeTo","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"newImplementation","type":"address"},{"name":"data","type":"bytes"}],"name":"upgradeToAndCall","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[],"name":"implementation","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"newAdmin","type":"address"}],"name":"changeAdmin","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"admin","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[{"name":"_implementation","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"payable":true,"stateMutability":"payable","type":"fallback"},{"anonymous":false,"inputs":[{"indexed":false,"name":"previousAdmin","type":"address"},{"indexed":false,"name":"newAdmin","type":"address"}],"name":"AdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"implementation","type":"address"}],"name":"Upgraded","type":"event"}]', + ContractName: 'FiatTokenProxy', + CompilerVersion: 'v0.4.24+commit.e67f0147', + OptimizationUsed: '0', + Runs: '200', + ConstructorArguments: + '0000000000000000000000000882477e7895bdc5cea7cb1552ed914ab157fe56', + EVMVersion: 'Default', + Library: '', + LicenseType: '', + Proxy: '1', + Implementation: '0x43506849d7c04f9138d1a2050bbf3a0c054402dd', + SwarmSource: + 'bzzr://a4a547cfc7202c5acaaae74d428e988bc62ad5024eb0165532d3a8f91db4ed24', + }, + ], + }) + + if ( + search === + `?module=contract&action=getsourcecode&address=${address}&apikey=${apiKey}` + ) + return HttpResponse.json({ + status: '1', + message: 'OK', + result: [ + { + SourceCode: '...', + ABI: '[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"}]', + ContractName: 'WagmiMintExample', + CompilerVersion: 'v0.8.11+commit.d7f03943', + OptimizationUsed: '1', + Runs: '10000', + ConstructorArguments: '', + EVMVersion: 'Default', + Library: '', + LicenseType: '', + Proxy: '0', + Implementation: '', + SwarmSource: '', + }, + ], + }) + + throw new Error(`Unhandled request: ${search}`) + }), +] diff --git a/packages/cli/tsconfig.build.json b/packages/cli/tsconfig.build.json new file mode 100644 index 0000000000..3a046d812b --- /dev/null +++ b/packages/cli/tsconfig.build.json @@ -0,0 +1,9 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["src/**/*.ts"], + "exclude": ["src/**/*.test.ts"], + "compilerOptions": { + "sourceMap": true, + "types": ["@types/node"] + } +} diff --git a/packages/cli/tsconfig.json b/packages/cli/tsconfig.json new file mode 100644 index 0000000000..4054dee118 --- /dev/null +++ b/packages/cli/tsconfig.json @@ -0,0 +1,5 @@ +{ + "extends": "./tsconfig.build.json", + "include": ["src/**/*.ts", "test/**/*.ts", "types/**/*.d.ts"], + "exclude": [] +} diff --git a/packages/cli/types/fixturez.d.ts b/packages/cli/types/fixturez.d.ts new file mode 100644 index 0000000000..f96282756f --- /dev/null +++ b/packages/cli/types/fixturez.d.ts @@ -0,0 +1,18 @@ +declare module 'fixturez' { + interface FixturezOpts { + glob?: string + cleanup?: boolean + root?: string + } + + interface Fixturez { + find(basename: string): string + copy(basename: string): string + temp(): string + cleanup(): void + } + + function fixturez(dirname: string, opts?: FixturezOpts): Fixturez + + export = fixturez +} diff --git a/packages/connectors/CHANGELOG.md b/packages/connectors/CHANGELOG.md new file mode 100644 index 0000000000..c67e25dcb0 --- /dev/null +++ b/packages/connectors/CHANGELOG.md @@ -0,0 +1,1640 @@ +# @wagmi/connectors + +## 5.8.3 + +### Patch Changes + +- [#4660](https://github.com/wevm/wagmi/pull/4660) [`42b1fed58e9ac09da0f8ebf3e9271f98a707aaac`](https://github.com/wevm/wagmi/commit/42b1fed58e9ac09da0f8ebf3e9271f98a707aaac) Thanks [@ganchoradkov](https://github.com/ganchoradkov)! - Updated `@walletconnect/ethereum-provider` version to `2.20.2` + +## 5.8.2 + +### Patch Changes + +- Updated dependencies [[`29297a48af72b537173d948ccd2fe37d39914c66`](https://github.com/wevm/wagmi/commit/29297a48af72b537173d948ccd2fe37d39914c66), [`07370106d5fb6b8fe300992d93abf25b3d0eaf57`](https://github.com/wevm/wagmi/commit/07370106d5fb6b8fe300992d93abf25b3d0eaf57)]: + - @wagmi/core@2.17.2 + +## 5.8.1 + +### Patch Changes + +- Updated dependencies [[`01f64e64fa4f85cdd30023903f972f4f9023681f`](https://github.com/wevm/wagmi/commit/01f64e64fa4f85cdd30023903f972f4f9023681f)]: + - @wagmi/core@2.17.1 + +## 5.8.0 + +### Minor Changes + +- [#4644](https://github.com/wevm/wagmi/pull/4644) [`cc5517ff6880bb630f1b201930acc20dd1a0b451`](https://github.com/wevm/wagmi/commit/cc5517ff6880bb630f1b201930acc20dd1a0b451) Thanks [@lukaisailovic](https://github.com/lukaisailovic)! - Updated `@walletconnect/etherereum-provider` to `2.20.0`. + +## 5.7.13 + +### Patch Changes + +- [#4622](https://github.com/wevm/wagmi/pull/4622) [`88427b2bcd13ec375ef519e9ad1ccffef9f02a7b`](https://github.com/wevm/wagmi/commit/88427b2bcd13ec375ef519e9ad1ccffef9f02a7b) Thanks [@dan1kov](https://github.com/dan1kov)! - Added `rdns` property to Coinbase Wallet v3 connector + +- [#4605](https://github.com/wevm/wagmi/pull/4605) [`3f8b2edc4f237cccff1009bcef03d51ca27a7324`](https://github.com/wevm/wagmi/commit/3f8b2edc4f237cccff1009bcef03d51ca27a7324) Thanks [@chybisov](https://github.com/chybisov)! - Bumped `@safe-global/safe-apps-provider` version to `0.18.6`. + +- Updated dependencies [[`799ee4d4b23c2ecd64e3f3668e67634e81939719`](https://github.com/wevm/wagmi/commit/799ee4d4b23c2ecd64e3f3668e67634e81939719)]: + - @wagmi/core@2.17.0 + +## 5.7.12 + +### Patch Changes + +- [#4608](https://github.com/wevm/wagmi/pull/4608) [`b59c024b23c69f5459b17390531207cfdf126ce4`](https://github.com/wevm/wagmi/commit/b59c024b23c69f5459b17390531207cfdf126ce4) Thanks [@jxom](https://github.com/jxom)! - Updated `@walletconnect/ethereum-provider`. + +## 5.7.11 + +### Patch Changes + +- Updated dependencies [[`a4bd0623eed28e3761a27295831a60ad835f0ee0`](https://github.com/wevm/wagmi/commit/a4bd0623eed28e3761a27295831a60ad835f0ee0)]: + - @wagmi/core@2.16.7 + +## 5.7.10 + +### Patch Changes + +- [#4573](https://github.com/wevm/wagmi/pull/4573) [`e944812ebc234a72c1417b77cff341166f5e0fef`](https://github.com/wevm/wagmi/commit/e944812ebc234a72c1417b77cff341166f5e0fef) Thanks [@ganchoradkov](https://github.com/ganchoradkov)! - updated `@walletconnect/ethereum-provider` to `2.19.1` + +- Updated dependencies [[`edf47477b2f6385a1c3ae01d36a8498c47f30a0b`](https://github.com/wevm/wagmi/commit/edf47477b2f6385a1c3ae01d36a8498c47f30a0b)]: + - @wagmi/core@2.16.6 + +## 5.7.9 + +### Patch Changes + +- [#4571](https://github.com/wevm/wagmi/pull/4571) [`5b7101fddb61df56e34b2e02b46bc409e496eaf9`](https://github.com/wevm/wagmi/commit/5b7101fddb61df56e34b2e02b46bc409e496eaf9) Thanks [@ganchoradkov](https://github.com/ganchoradkov)! - Updated `@walletconnect/ethereum-provider` to `2.19.0` + +## 5.7.8 + +### Patch Changes + +- Updated dependencies [[`d0c9a86921a4e939373cc6e763284e53f2a2e93c`](https://github.com/wevm/wagmi/commit/d0c9a86921a4e939373cc6e763284e53f2a2e93c)]: + - @wagmi/core@2.16.5 + +## 5.7.7 + +### Patch Changes + +- [`507f864d91238bfd423d0e36d3619eb9f6e52eec`](https://github.com/wevm/wagmi/commit/507f864d91238bfd423d0e36d3619eb9f6e52eec) Thanks [@jxom](https://github.com/jxom)! - Updated `@coinbase/wallet-sdk`. + +- Updated dependencies [[`507f864d91238bfd423d0e36d3619eb9f6e52eec`](https://github.com/wevm/wagmi/commit/507f864d91238bfd423d0e36d3619eb9f6e52eec)]: + - @wagmi/core@2.16.4 + +## 5.7.6 + +### Patch Changes + +- [#4524](https://github.com/wevm/wagmi/pull/4524) [`639952c97f0fe3927106f42d3c9f7f366cdf7f7a`](https://github.com/wevm/wagmi/commit/639952c97f0fe3927106f42d3c9f7f366cdf7f7a) Thanks [@chakra-guy](https://github.com/chakra-guy)! - Updated MetaMask SDK. + +- [#4525](https://github.com/wevm/wagmi/pull/4525) [`5aa2c095f7bfb6dfcf91c6945c3e1f9c9dd05766`](https://github.com/wevm/wagmi/commit/5aa2c095f7bfb6dfcf91c6945c3e1f9c9dd05766) Thanks [@EdouardBougon](https://github.com/EdouardBougon)! - Added Phantom flag to Injected Connector. + +## 5.7.5 + +### Patch Changes + +- [#4512](https://github.com/wevm/wagmi/pull/4512) [`a257e8d4f97431a4af872cda1817b4ae17c7bbed`](https://github.com/wevm/wagmi/commit/a257e8d4f97431a4af872cda1817b4ae17c7bbed) Thanks [@EdouardBougon](https://github.com/EdouardBougon)! - Fixed MetaMask switchChain/addChain handling. + +## 5.7.4 + +### Patch Changes + +- [#4505](https://github.com/wevm/wagmi/pull/4505) [`c8a257e0f6d2ece013b873895c35769a8a804fdc`](https://github.com/wevm/wagmi/commit/c8a257e0f6d2ece013b873895c35769a8a804fdc) Thanks [@chakra-guy](https://github.com/chakra-guy)! - Bumped Metamask SDK Version (changes include [bug fixes and minor changes](https://github.com/MetaMask/metamask-sdk/pull/1194)). + +## 5.7.3 + +### Patch Changes + +- [#4480](https://github.com/wevm/wagmi/pull/4480) [`384a1d91597622eb59e1c05dc13ce25017c5b6d8`](https://github.com/wevm/wagmi/commit/384a1d91597622eb59e1c05dc13ce25017c5b6d8) Thanks [@RodeRickIsWatching](https://github.com/RodeRickIsWatching)! - Fixed invocation of default storage. + +- Updated dependencies [[`384a1d91597622eb59e1c05dc13ce25017c5b6d8`](https://github.com/wevm/wagmi/commit/384a1d91597622eb59e1c05dc13ce25017c5b6d8)]: + - @wagmi/core@2.16.3 + +## 5.7.2 + +### Patch Changes + +- [`012907032b532a438fce48f407470250cbc8f0c6`](https://github.com/wevm/wagmi/commit/012907032b532a438fce48f407470250cbc8f0c6) Thanks [@jxom](https://github.com/jxom)! - Fixed assignment in `getDefaultStorage`. + +- Updated dependencies [[`012907032b532a438fce48f407470250cbc8f0c6`](https://github.com/wevm/wagmi/commit/012907032b532a438fce48f407470250cbc8f0c6)]: + - @wagmi/core@2.16.2 + +## 5.7.1 + +### Patch Changes + +- [#4471](https://github.com/wevm/wagmi/pull/4471) [`9c8c35a3b829f2c58edcd3a29e2dcd99974d7470`](https://github.com/wevm/wagmi/commit/9c8c35a3b829f2c58edcd3a29e2dcd99974d7470) Thanks [@EdouardBougon](https://github.com/EdouardBougon)! - Improved MetaMask chain switching behavior. + +- Updated dependencies [[`3892ebd21c06beef4b28ece4e70d2a38807bce6f`](https://github.com/wevm/wagmi/commit/3892ebd21c06beef4b28ece4e70d2a38807bce6f)]: + - @wagmi/core@2.16.1 + +## 5.7.0 + +### Minor Changes + +- [#4440](https://github.com/wevm/wagmi/pull/4440) [`e3f63a02c1f7d80481804584f262bc98dab0400d`](https://github.com/wevm/wagmi/commit/e3f63a02c1f7d80481804584f262bc98dab0400d) Thanks [@johanneskares](https://github.com/johanneskares)! - Added Coinbase Smart Wallet "Instant Onboarding" mode to `coinbaseWallet`. + +## 5.6.2 + +### Patch Changes + +- [#4437](https://github.com/wevm/wagmi/pull/4437) [`adf2253b10c6d4fc583e4bc9f01a8ef5ca267c85`](https://github.com/wevm/wagmi/commit/adf2253b10c6d4fc583e4bc9f01a8ef5ca267c85) Thanks [@chybisov](https://github.com/chybisov)! - Bumped `@safe-global/safe-apps-provider` version to `0.18.5`. + +## 5.6.1 + +### Patch Changes + +- [#4458](https://github.com/wevm/wagmi/pull/4458) [`987404f590c1d29ebb3cb68928f5e54aa032793d`](https://github.com/wevm/wagmi/commit/987404f590c1d29ebb3cb68928f5e54aa032793d) Thanks [@EdouardBougon](https://github.com/EdouardBougon)! - Fixed MetaMask internal metadata handling. + +## 5.6.0 + +### Minor Changes + +- [#4453](https://github.com/wevm/wagmi/pull/4453) [`070e48480194c8d7f45bda1d7dd1346e6f5d7227`](https://github.com/wevm/wagmi/commit/070e48480194c8d7f45bda1d7dd1346e6f5d7227) Thanks [@tmm](https://github.com/tmm)! - Added narrowing to `config.connectors`. + +### Patch Changes + +- [#4456](https://github.com/wevm/wagmi/pull/4456) [`8b0726c1106fce88b782e676498eabf0718b2619`](https://github.com/wevm/wagmi/commit/8b0726c1106fce88b782e676498eabf0718b2619) Thanks [@EdouardBougon](https://github.com/EdouardBougon)! - Bumped MetaMask SDK and fixed internal metadata handling. +- Updated dependencies [[`afea6b67822a7a2b96901ec851441d27ee0f7a52`](https://github.com/wevm/wagmi/commit/afea6b67822a7a2b96901ec851441d27ee0f7a52), [`070e48480194c8d7f45bda1d7dd1346e6f5d7227`](https://github.com/wevm/wagmi/commit/070e48480194c8d7f45bda1d7dd1346e6f5d7227)]: + - @wagmi/core@2.16.0 + +## 5.5.3 + +### Patch Changes + +- [#4433](https://github.com/wevm/wagmi/pull/4433) [`06e186cd679b27fe195309110e766fcf46d4efbc`](https://github.com/wevm/wagmi/commit/06e186cd679b27fe195309110e766fcf46d4efbc) Thanks [@Aerilym](https://github.com/Aerilym)! - Bumped Metamask SDK version to `0.31.1`. + +- Updated dependencies [[`06e186cd679b27fe195309110e766fcf46d4efbc`](https://github.com/wevm/wagmi/commit/06e186cd679b27fe195309110e766fcf46d4efbc)]: + - @wagmi/core@2.15.2 + +## 5.5.2 + +### Patch Changes + +- [#4422](https://github.com/wevm/wagmi/pull/4422) [`e563ef69130a511fd6f3f72ed4cd4fbe1390541f`](https://github.com/wevm/wagmi/commit/e563ef69130a511fd6f3f72ed4cd4fbe1390541f) Thanks [@abretonc7s](https://github.com/abretonc7s)! - Bumped MetaMask SDK. + +## 5.5.1 + +### Patch Changes + +- Updated dependencies [[`b8bbb409f4934538e3dd6cac5aaf7346292d0693`](https://github.com/wevm/wagmi/commit/b8bbb409f4934538e3dd6cac5aaf7346292d0693)]: + - @wagmi/core@2.15.1 + +## 5.5.0 + +### Minor Changes + +- [#4417](https://github.com/wevm/wagmi/pull/4417) [`42e65ea4fea99c639817088bba915e0933d17141`](https://github.com/wevm/wagmi/commit/42e65ea4fea99c639817088bba915e0933d17141) Thanks [@jxom](https://github.com/jxom)! - Removed simulation in `writeContract` & `sendTransaction`. + +### Patch Changes + +- Updated dependencies [[`42e65ea4fea99c639817088bba915e0933d17141`](https://github.com/wevm/wagmi/commit/42e65ea4fea99c639817088bba915e0933d17141)]: + - @wagmi/core@2.15.0 + +## 5.4.0 + +### Minor Changes + +- [#4409](https://github.com/wevm/wagmi/pull/4409) [`7ca62b44cd997d48f92c2b81343726a5908aa00b`](https://github.com/wevm/wagmi/commit/7ca62b44cd997d48f92c2b81343726a5908aa00b) Thanks [@fan-zhang-sv](https://github.com/fan-zhang-sv)! - Added `preference` object for Coinbase Wallet connector. + +## 5.3.10 + +### Patch Changes + +- [#4406](https://github.com/wevm/wagmi/pull/4406) [`a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3`](https://github.com/wevm/wagmi/commit/a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3) Thanks [@tmm](https://github.com/tmm)! - Added additional RDNS to MetaMask Connector. + +- Updated dependencies [[`a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3`](https://github.com/wevm/wagmi/commit/a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3)]: + - @wagmi/core@2.14.6 + +## 5.3.9 + +### Patch Changes + +- [`b12a04eeec985c48d2feac94b011d41fb29ca23e`](https://github.com/wevm/wagmi/commit/b12a04eeec985c48d2feac94b011d41fb29ca23e) Thanks [@tmm](https://github.com/tmm)! - Bumped Coinbase Wallet SDK version. + +## 5.3.8 + +### Patch Changes + +- [#4390](https://github.com/wevm/wagmi/pull/4390) [`dac62dc99a0679fa632a0fae49873d6053d06b35`](https://github.com/wevm/wagmi/commit/dac62dc99a0679fa632a0fae49873d6053d06b35) Thanks [@chybisov](https://github.com/chybisov)! - Bumped Safe Apps Provider version. + +- Updated dependencies [[`6b9bbacdc7bffd44fc2165362a5e65fd434e7646`](https://github.com/wevm/wagmi/commit/6b9bbacdc7bffd44fc2165362a5e65fd434e7646)]: + - @wagmi/core@2.14.5 + +## 5.3.7 + +### Patch Changes + +- Updated dependencies [[`e08681c81fbdf475213e2d0f4c5517d0abf4e743`](https://github.com/wevm/wagmi/commit/e08681c81fbdf475213e2d0f4c5517d0abf4e743)]: + - @wagmi/core@2.14.4 + +## 5.3.6 + +### Patch Changes + +- [#4385](https://github.com/wevm/wagmi/pull/4385) [`7558ff3133c11bc4c49473d08ee9a47eaa12df5b`](https://github.com/wevm/wagmi/commit/7558ff3133c11bc4c49473d08ee9a47eaa12df5b) Thanks [@cb-jake](https://github.com/cb-jake)! - Bumped Coinbase Wallet SDK version. + +## 5.3.5 + +### Patch Changes + +- [`7fe78f2d09778fc01fd0cffe85ba198e64999275`](https://github.com/wevm/wagmi/commit/7fe78f2d09778fc01fd0cffe85ba198e64999275) Thanks [@tmm](https://github.com/tmm)! - Fixed MetaMask connector not returning provider in some cases. + +- Updated dependencies [[`cb7dd2ebb871d0be8f1a11a8cd8ce592cd74b7c7`](https://github.com/wevm/wagmi/commit/cb7dd2ebb871d0be8f1a11a8cd8ce592cd74b7c7)]: + - @wagmi/core@2.14.3 + +## 5.3.4 + +### Patch Changes + +- [#4371](https://github.com/wevm/wagmi/pull/4371) [`b6861a4c378dab78d8751ae0ac2aa425f3c24b8f`](https://github.com/wevm/wagmi/commit/b6861a4c378dab78d8751ae0ac2aa425f3c24b8f) Thanks [@iceanddust](https://github.com/iceanddust)! - Fixed Safe connector not working in some Vite apps + +- Updated dependencies [[`d0d0963bb5904a15cf0355862d62dd141ce0c31c`](https://github.com/wevm/wagmi/commit/d0d0963bb5904a15cf0355862d62dd141ce0c31c), [`ecac0ba36243d94c9199d0bd21937104c835d9a0`](https://github.com/wevm/wagmi/commit/ecac0ba36243d94c9199d0bd21937104c835d9a0)]: + - @wagmi/core@2.14.2 + +## 5.3.3 + +### Patch Changes + +- [#4362](https://github.com/wevm/wagmi/pull/4362) [`83c6d16b7d6dddfa6bda036e04f00ec313c6248c`](https://github.com/wevm/wagmi/commit/83c6d16b7d6dddfa6bda036e04f00ec313c6248c) Thanks [@EdouardBougon](https://github.com/EdouardBougon)! - Fixed MetaMask connector internal logic. + +## 5.3.2 + +### Patch Changes + +- [#4357](https://github.com/wevm/wagmi/pull/4357) [`8970cc51398e1ac713435533096215c6d31ffdf9`](https://github.com/wevm/wagmi/commit/8970cc51398e1ac713435533096215c6d31ffdf9) Thanks [@tmm](https://github.com/tmm)! - Bumped dependencies. + +## 5.3.1 + +### Patch Changes + +- Updated dependencies [[`052e72e1f8c1c14fcbdce04a9f8fa7ec28d83702`](https://github.com/wevm/wagmi/commit/052e72e1f8c1c14fcbdce04a9f8fa7ec28d83702), [`b250fc21ee577b2a75c5a34ff684f62fb4ad771a`](https://github.com/wevm/wagmi/commit/b250fc21ee577b2a75c5a34ff684f62fb4ad771a)]: + - @wagmi/core@2.14.1 + +## 5.3.0 + +### Minor Changes + +- [#4343](https://github.com/wevm/wagmi/pull/4343) [`f43e074f473820b208a6295d7c97f847332f1a1d`](https://github.com/wevm/wagmi/commit/f43e074f473820b208a6295d7c97f847332f1a1d) Thanks [@tmm](https://github.com/tmm)! - Added `rdns` property to connector interface. This is used to filter out duplicate [EIP-6963](https://eips.ethereum.org/EIPS/eip-6963) injected providers when [`createConfig#multiInjectedProviderDiscovery`](https://wagmi.sh/core/api/createConfig#multiinjectedproviderdiscovery) is enabled and `createConfig#connectors` already matches EIP-6963 providers' `rdns` property. + +### Patch Changes + +- Updated dependencies [[`f43e074f473820b208a6295d7c97f847332f1a1d`](https://github.com/wevm/wagmi/commit/f43e074f473820b208a6295d7c97f847332f1a1d)]: + - @wagmi/core@2.14.0 + +## 5.2.2 + +### Patch Changes + +- [#4347](https://github.com/wevm/wagmi/pull/4347) [`5ae49af590ff168426c9c283d54c34ae5148fcd9`](https://github.com/wevm/wagmi/commit/5ae49af590ff168426c9c283d54c34ae5148fcd9) Thanks [@EdouardBougon](https://github.com/EdouardBougon)! - Added workaround for MetaMask mobile sometimes disconnecting. + +- [#4350](https://github.com/wevm/wagmi/pull/4350) [`f3182b22e6e454d9bd74f1b940ef34431fd9555d`](https://github.com/wevm/wagmi/commit/f3182b22e6e454d9bd74f1b940ef34431fd9555d) Thanks [@abretonc7s](https://github.com/abretonc7s)! - Updated MetaMask SDK. + +- Updated dependencies [[`c05caabc20c3ced9682cfc7ba1f3f7dcfece0703`](https://github.com/wevm/wagmi/commit/c05caabc20c3ced9682cfc7ba1f3f7dcfece0703)]: + - @wagmi/core@2.13.9 + +## 5.2.1 + +### Patch Changes + +- [#4345](https://github.com/wevm/wagmi/pull/4345) [`91a40f2db08e3a91db421b8732a5511a1e6c88fd`](https://github.com/wevm/wagmi/commit/91a40f2db08e3a91db421b8732a5511a1e6c88fd) Thanks [@tmm](https://github.com/tmm)! - Bumped MetaMask SDK. + +## 5.2.0 + +### Minor Changes + +- [#4337](https://github.com/wevm/wagmi/pull/4337) [`34a0c3b7eea778aee7c27f7ace5e4b2be4e8a0a4`](https://github.com/wevm/wagmi/commit/34a0c3b7eea778aee7c27f7ace5e4b2be4e8a0a4) Thanks [@tmm](https://github.com/tmm)! - Added "Connect and Sign" behavior to MetaMask Connector. + +## 5.1.15 + +### Patch Changes + +- [`3b2123664b7ac66848390739e855c3b9702ab60c`](https://github.com/wevm/wagmi/commit/3b2123664b7ac66848390739e855c3b9702ab60c) Thanks [@tmm](https://github.com/tmm)! - Bumped WalletConnect Provider. + +## 5.1.14 + +### Patch Changes + +- [#4207](https://github.com/wevm/wagmi/pull/4207) [`56f2482508f2ba71bd6b0295c70c6abca7101e57`](https://github.com/wevm/wagmi/commit/56f2482508f2ba71bd6b0295c70c6abca7101e57) Thanks [@Smert](https://github.com/Smert)! - Updated chain switch listener for `injected` and `metaMask` to be more robust. + +- Updated dependencies [[`56f2482508f2ba71bd6b0295c70c6abca7101e57`](https://github.com/wevm/wagmi/commit/56f2482508f2ba71bd6b0295c70c6abca7101e57)]: + - @wagmi/core@2.13.8 + +## 5.1.13 + +### Patch Changes + +- Updated dependencies [[`be75c2d4ef636d7362420ab0a106bfdf63f5d1e6`](https://github.com/wevm/wagmi/commit/be75c2d4ef636d7362420ab0a106bfdf63f5d1e6)]: + - @wagmi/core@2.13.7 + +## 5.1.12 + +### Patch Changes + +- Updated dependencies [[`edcbf5d6fbe92f639bead800502edda9e0aa39f1`](https://github.com/wevm/wagmi/commit/edcbf5d6fbe92f639bead800502edda9e0aa39f1)]: + - @wagmi/core@2.13.6 + +## 5.1.11 + +### Patch Changes + +- [#4271](https://github.com/wevm/wagmi/pull/4271) [`82404c960e04c83e0bae6e1e12459ef9debf9554`](https://github.com/wevm/wagmi/commit/82404c960e04c83e0bae6e1e12459ef9debf9554) Thanks [@omridan159](https://github.com/omridan159)! - Bumped MetaMask SDK. + +- [#4227](https://github.com/wevm/wagmi/pull/4227) [`d07ad7f63a018256908a673d078aaf79e47ac703`](https://github.com/wevm/wagmi/commit/d07ad7f63a018256908a673d078aaf79e47ac703) Thanks [@xianchenxc](https://github.com/xianchenxc)! - Fixed MetaMask Connector throwing error after switching to a chain that was just added via `'wallet_addEthereumChain'`. + +## 5.1.10 + +### Patch Changes + +- [#4255](https://github.com/wevm/wagmi/pull/4255) [`81de006e66121a18c61945c1f9b8426c83a5713c`](https://github.com/wevm/wagmi/commit/81de006e66121a18c61945c1f9b8426c83a5713c) Thanks [@tomiir](https://github.com/tomiir)! - Bumped `@walletconnect/ethereum-provider` from version `2.15.3` to version `2.16.1`. + +- Updated dependencies [[`f47ce8f6d263e49fdff90b8edb3190142d2657bb`](https://github.com/wevm/wagmi/commit/f47ce8f6d263e49fdff90b8edb3190142d2657bb)]: + - @wagmi/core@2.13.5 + +## 5.1.9 + +### Patch Changes + +- [#4243](https://github.com/wevm/wagmi/pull/4243) [`21bd0e473d374cbbd7a01bececa6022d529026ba`](https://github.com/wevm/wagmi/commit/21bd0e473d374cbbd7a01bececa6022d529026ba) Thanks [@tomiir](https://github.com/tomiir)! - Bumped `@walletconnect/ethereum-provider` from version `2.15.2` to version `2.15.3` + +- [#4251](https://github.com/wevm/wagmi/pull/4251) [`5c89c6853e616437a3be2b019db895451fecfb3c`](https://github.com/wevm/wagmi/commit/5c89c6853e616437a3be2b019db895451fecfb3c) Thanks [@tmm](https://github.com/tmm)! - Bumped MM SDK. + +## 5.1.8 + +### Patch Changes + +- [`b580ad4edff1721e0b9d138cf5ae2ec74d2374c7`](https://github.com/wevm/wagmi/commit/b580ad4edff1721e0b9d138cf5ae2ec74d2374c7) Thanks [@tmm](https://github.com/tmm)! - Bumped WalletConnect Provider. + +## 5.1.7 + +### Patch Changes + +- [#4213](https://github.com/wevm/wagmi/pull/4213) [`91fd81a068789c5020e891f539bcad8f54a7a52f`](https://github.com/wevm/wagmi/commit/91fd81a068789c5020e891f539bcad8f54a7a52f) Thanks [@tomiir](https://github.com/tomiir)! - Updated `@walletconnect/ethereum-provider` from version `2.15.0` to version `2.15.1`. + +## 5.1.6 + +### Patch Changes + +- [#4208](https://github.com/wevm/wagmi/pull/4208) [`3168616298cbb6135d0ffda771cba4126e83eba8`](https://github.com/wevm/wagmi/commit/3168616298cbb6135d0ffda771cba4126e83eba8) Thanks [@tomiir](https://github.com/tomiir)! - Updated WalletConnect Ethereum Provider version from `2.14.0` to `2.15.0`. + +- [#4211](https://github.com/wevm/wagmi/pull/4211) [`d7608ef9a79459465dc8c06a2ab740465c881907`](https://github.com/wevm/wagmi/commit/d7608ef9a79459465dc8c06a2ab740465c881907) Thanks [@tmm](https://github.com/tmm)! - Added default name for MetaMask Connector. + +## 5.1.5 + +### Patch Changes + +- Updated dependencies [[`b4c8971788c70b09479946ecfa998cff2f1b3953`](https://github.com/wevm/wagmi/commit/b4c8971788c70b09479946ecfa998cff2f1b3953)]: + - @wagmi/core@2.13.4 + +## 5.1.4 + +### Patch Changes + +- Updated dependencies [[`871dbdbfe59ac8ad01d1ec6150ea7b091b7b7de4`](https://github.com/wevm/wagmi/commit/871dbdbfe59ac8ad01d1ec6150ea7b091b7b7de4)]: + - @wagmi/core@2.13.3 + +## 5.1.3 + +### Patch Changes + +- Updated dependencies [[`1b9b523fa9b9dfe839aecdf4b40caa9547d7e594`](https://github.com/wevm/wagmi/commit/1b9b523fa9b9dfe839aecdf4b40caa9547d7e594)]: + - @wagmi/core@2.13.2 + +## 5.1.2 + +### Patch Changes + +- [`abb490dac4f0f02f46cb0878e7ca9a0db6aada56`](https://github.com/wevm/wagmi/commit/abb490dac4f0f02f46cb0878e7ca9a0db6aada56) Thanks [@tmm](https://github.com/tmm)! - Bumped MetaMask SDK version. + +- [`28e0e5c9a4f856583f9d36a807502bd51a0c6ec2`](https://github.com/wevm/wagmi/commit/28e0e5c9a4f856583f9d36a807502bd51a0c6ec2) Thanks [@tmm](https://github.com/tmm)! - Bumped WalletConnect Ethereum Provider version. + +## 5.1.1 + +### Patch Changes + +- Updated dependencies [[`07c1227f306d0efb9421d4bb77a774f92f5fcf45`](https://github.com/wevm/wagmi/commit/07c1227f306d0efb9421d4bb77a774f92f5fcf45)]: + - @wagmi/core@2.13.1 + +## 5.1.0 + +### Minor Changes + +- [#4162](https://github.com/wevm/wagmi/pull/4162) [`a73a7737b756886b388f120ae423e72cca53e8a0`](https://github.com/wevm/wagmi/commit/a73a7737b756886b388f120ae423e72cca53e8a0) Thanks [@jxom](https://github.com/jxom)! - Added functionality for consumer-defined RPC URLs (`config.transports`) to be propagated to the WalletConnect & MetaMask Connectors. + +### Patch Changes + +- Updated dependencies [[`a73a7737b756886b388f120ae423e72cca53e8a0`](https://github.com/wevm/wagmi/commit/a73a7737b756886b388f120ae423e72cca53e8a0)]: + - @wagmi/core@2.13.0 + +## 5.0.26 + +### Patch Changes + +- [`8d81df5cc884d0a210dedd3c1ea0e2e9e52b83c5`](https://github.com/wevm/wagmi/commit/8d81df5cc884d0a210dedd3c1ea0e2e9e52b83c5) Thanks [@tmm](https://github.com/tmm)! - Fixed `metaMask` connector switch chain issue. + +- Updated dependencies [[`5bc8c8877810b2eec24a829df87dce40a51e6f20`](https://github.com/wevm/wagmi/commit/5bc8c8877810b2eec24a829df87dce40a51e6f20)]: + - @wagmi/core@2.12.2 + +## 5.0.25 + +### Patch Changes + +- [#4146](https://github.com/wevm/wagmi/pull/4146) [`cc996e08e930c9e88cf753a1e874652059e81a3b`](https://github.com/wevm/wagmi/commit/cc996e08e930c9e88cf753a1e874652059e81a3b) Thanks [@jxom](https://github.com/jxom)! - Updated `@safe-global/safe-apps-sdk` + `@safe-global/safe-apps-provider` dependencies. + +- Updated dependencies [[`cc996e08e930c9e88cf753a1e874652059e81a3b`](https://github.com/wevm/wagmi/commit/cc996e08e930c9e88cf753a1e874652059e81a3b)]: + - @wagmi/core@2.12.1 + +## 5.0.24 + +### Patch Changes + +- Updated dependencies [[`5581a810ef70308e99c6f8b630cd4bca59f64afc`](https://github.com/wevm/wagmi/commit/5581a810ef70308e99c6f8b630cd4bca59f64afc)]: + - @wagmi/core@2.12.0 + +## 5.0.23 + +### Patch Changes + +- [`d3814ab4b88f9f0e052b53bc3d458df87b43f01d`](https://github.com/wevm/wagmi/commit/d3814ab4b88f9f0e052b53bc3d458df87b43f01d) Thanks [@jxom](https://github.com/jxom)! - Updated `mipd` dependency. + +- Updated dependencies [[`b08013eaa9ce97c02f8a7128ea400e3da7ef74bb`](https://github.com/wevm/wagmi/commit/b08013eaa9ce97c02f8a7128ea400e3da7ef74bb), [`d3814ab4b88f9f0e052b53bc3d458df87b43f01d`](https://github.com/wevm/wagmi/commit/d3814ab4b88f9f0e052b53bc3d458df87b43f01d)]: + - @wagmi/core@2.11.8 + +## 5.0.22 + +### Patch Changes + +- [`0bb8b562ae04ecfeb2d6b2f1b980ebae31dc127e`](https://github.com/wevm/wagmi/commit/0bb8b562ae04ecfeb2d6b2f1b980ebae31dc127e) Thanks [@tmm](https://github.com/tmm)! - Improved TypeScript `'exactOptionalPropertyTypes'` support. + +- Updated dependencies [[`0bb8b562ae04ecfeb2d6b2f1b980ebae31dc127e`](https://github.com/wevm/wagmi/commit/0bb8b562ae04ecfeb2d6b2f1b980ebae31dc127e)]: + - @wagmi/core@2.11.7 + +## 5.0.21 + +### Patch Changes + +- [#4094](https://github.com/wevm/wagmi/pull/4094) [`ff0760b5900114bcfdf420a9fba3cc278ac95afe`](https://github.com/wevm/wagmi/commit/ff0760b5900114bcfdf420a9fba3cc278ac95afe) Thanks [@omridan159](https://github.com/omridan159)! - Bumped MetaMask SDK to fix `metaMask` connector error bubbling. + +- Updated dependencies [[`95965c1f19d480b97f2b297a077a9e607dee32ad`](https://github.com/wevm/wagmi/commit/95965c1f19d480b97f2b297a077a9e607dee32ad)]: + - @wagmi/core@2.11.6 + +## 5.0.20 + +### Patch Changes + +- [`43fa971d34cac57fa5a2898ad4d839b95d7af37c`](https://github.com/wevm/wagmi/commit/43fa971d34cac57fa5a2898ad4d839b95d7af37c) Thanks [@tmm](https://github.com/tmm)! - Bumped Coinbase Wallet SDK and fixed `metaMask` connector hang on mobile. + +## 5.0.19 + +### Patch Changes + +- [#4083](https://github.com/wevm/wagmi/pull/4083) [`b7ad208030d9f2e3f89912ff76b16cdbd848feda`](https://github.com/wevm/wagmi/commit/b7ad208030d9f2e3f89912ff76b16cdbd848feda) Thanks [@omridan159](https://github.com/omridan159)! - Bumped MetaMask SDK + +## 5.0.18 + +### Patch Changes + +- [#4081](https://github.com/wevm/wagmi/pull/4081) [`44d24620c9e3957f3245d14d6a042736371df70b`](https://github.com/wevm/wagmi/commit/44d24620c9e3957f3245d14d6a042736371df70b) Thanks [@tmm](https://github.com/tmm)! - Bumped MetaMask SDK + +## 5.0.17 + +### Patch Changes + +- Updated dependencies [[`04f2b846b113f3d300d82c9fa75212f1805817c5`](https://github.com/wevm/wagmi/commit/04f2b846b113f3d300d82c9fa75212f1805817c5)]: + - @wagmi/core@2.11.5 + +## 5.0.16 + +### Patch Changes + +- [#4071](https://github.com/wevm/wagmi/pull/4071) [`02c38c28d1aa0ad7a61c33775de603ed974c5c1b`](https://github.com/wevm/wagmi/commit/02c38c28d1aa0ad7a61c33775de603ed974c5c1b) Thanks [@omridan159](https://github.com/omridan159)! - Bumped MetaMask SDK + +- Updated dependencies [[`9e8345cd56186b997b5e56deaa2cfc69b30d15f6`](https://github.com/wevm/wagmi/commit/9e8345cd56186b997b5e56deaa2cfc69b30d15f6)]: + - @wagmi/core@2.11.4 + +## 5.0.15 + +### Patch Changes + +- Updated dependencies [[`8974e6269bb5d7bfaa90db0246bc7d13e8bff798`](https://github.com/wevm/wagmi/commit/8974e6269bb5d7bfaa90db0246bc7d13e8bff798)]: + - @wagmi/core@2.11.3 + +## 5.0.14 + +### Patch Changes + +- Updated dependencies [[`b4d9ef79deb554ee20fed6666a474be5e7cdd522`](https://github.com/wevm/wagmi/commit/b4d9ef79deb554ee20fed6666a474be5e7cdd522)]: + - @wagmi/core@2.11.2 + +## 5.0.13 + +### Patch Changes + +- [`9c862d8d63e3d692a22cef2a90782b74a9103f17`](https://github.com/wevm/wagmi/commit/9c862d8d63e3d692a22cef2a90782b74a9103f17) Thanks [@tmm](https://github.com/tmm)! - Reverted internal module loading utility. + +- Updated dependencies [[`9c862d8d63e3d692a22cef2a90782b74a9103f17`](https://github.com/wevm/wagmi/commit/9c862d8d63e3d692a22cef2a90782b74a9103f17)]: + - @wagmi/core@2.11.1 + +## 5.0.12 + +### Patch Changes + +- Updated dependencies [[`06bb598a7f04c7b167f5b7ff6d46bd15886a6a14`](https://github.com/wevm/wagmi/commit/06bb598a7f04c7b167f5b7ff6d46bd15886a6a14), [`24a45b269bd0214a29d6f82a84ac66ef8c3f3822`](https://github.com/wevm/wagmi/commit/24a45b269bd0214a29d6f82a84ac66ef8c3f3822)]: + - @wagmi/core@2.11.0 + +## 5.0.11 + +### Patch Changes + +- [#4020](https://github.com/wevm/wagmi/pull/4020) [`e3b124ce414b8fd1b2214e2c5a28dc72158a13d1`](https://github.com/wevm/wagmi/commit/e3b124ce414b8fd1b2214e2c5a28dc72158a13d1) Thanks [@tmm](https://github.com/tmm)! - Added reconnection support to `metaMask` on mobile and use deeplinks by default. + +- Updated dependencies [[`f2a7cefab96691ebed8b8e45ffde071c47b58dbe`](https://github.com/wevm/wagmi/commit/f2a7cefab96691ebed8b8e45ffde071c47b58dbe), [`f0ea0b2a7fe193dadfeb49a4c8031ee451c638b5`](https://github.com/wevm/wagmi/commit/f0ea0b2a7fe193dadfeb49a4c8031ee451c638b5)]: + - @wagmi/core@2.10.6 + +## 5.0.10 + +### Patch Changes + +- [`560952acd4bfe33db6c7c07b35c613cef278677c`](https://github.com/wevm/wagmi/commit/560952acd4bfe33db6c7c07b35c613cef278677c) Thanks [@tmm](https://github.com/tmm)! - Captured Coinbase Smart Wallet error when closing window as EIP-1193 `4001` error. + +## 5.0.9 + +### Patch Changes + +- [`32cdd7b7dc5aff916c040628519562c3a99d418d`](https://github.com/wevm/wagmi/commit/32cdd7b7dc5aff916c040628519562c3a99d418d) Thanks [@tmm](https://github.com/tmm)! - Bumped `@metamask/sdk` to remove peer dependency install warning. + +## 5.0.8 + +### Patch Changes + +- [#3997](https://github.com/wevm/wagmi/pull/3997) [`c1952d1ff7f0a491dc88595a49159451b07b5621`](https://github.com/wevm/wagmi/commit/c1952d1ff7f0a491dc88595a49159451b07b5621) Thanks [@nateReiners](https://github.com/nateReiners)! - Bumped Coinbase Wallet SDK. + +## 5.0.7 + +### Patch Changes + +- Updated dependencies [[`030c7c2cb380dfd67a2182f62e2aa7a6e1601898`](https://github.com/wevm/wagmi/commit/030c7c2cb380dfd67a2182f62e2aa7a6e1601898)]: + - @wagmi/core@2.10.5 + +## 5.0.6 + +### Patch Changes + +- Updated dependencies [[`51fde8a0433b4fff357c1a8d7e08b41b4c86c968`](https://github.com/wevm/wagmi/commit/51fde8a0433b4fff357c1a8d7e08b41b4c86c968)]: + - @wagmi/core@2.10.4 + +## 5.0.5 + +### Patch Changes + +- [#3979](https://github.com/wevm/wagmi/pull/3979) [`70dd28669dd8d2ce08217cd02e29a8fbba7a08d4`](https://github.com/wevm/wagmi/commit/70dd28669dd8d2ce08217cd02e29a8fbba7a08d4) Thanks [@tmm](https://github.com/tmm)! - Fixed `walletConnect` connector. + +## 5.0.4 + +### Patch Changes + +- [#3972](https://github.com/wevm/wagmi/pull/3972) [`be9e1b8a9818b92eb0654a20d9471e9e39329e7e`](https://github.com/wevm/wagmi/commit/be9e1b8a9818b92eb0654a20d9471e9e39329e7e) Thanks [@nateReiners](https://github.com/nateReiners)! - Bumped Coinbase Wallet SDK. + +## 5.0.3 + +### Patch Changes + +- [#3962](https://github.com/wevm/wagmi/pull/3962) [`2804a8a583b1874271154898b4bae38756ef581c`](https://github.com/wevm/wagmi/commit/2804a8a583b1874271154898b4bae38756ef581c) Thanks [@tmm](https://github.com/tmm)! - Added timeout to `getInfo` called in `safe` connector since [non-Safe App iFrames cause it to not resolve](https://github.com/safe-global/safe-apps-sdk/issues/263#issuecomment-1029835840). + +- Updated dependencies [[`2804a8a583b1874271154898b4bae38756ef581c`](https://github.com/wevm/wagmi/commit/2804a8a583b1874271154898b4bae38756ef581c)]: + - @wagmi/core@2.10.3 + +## 5.0.2 + +### Patch Changes + +- [#3940](https://github.com/wevm/wagmi/pull/3940) [`a5071f581dfdfb961718873643a2fc629101c72a`](https://github.com/wevm/wagmi/commit/a5071f581dfdfb961718873643a2fc629101c72a) Thanks [@jxom](https://github.com/jxom)! - Fixed usage of `metaMask` connector in Vite environments. + +- Updated dependencies [[`a5071f581dfdfb961718873643a2fc629101c72a`](https://github.com/wevm/wagmi/commit/a5071f581dfdfb961718873643a2fc629101c72a)]: + - @wagmi/core@2.10.2 + +## 5.0.1 + +### Patch Changes + +- Bumped versions. + +- Updated dependencies []: + - @wagmi/core@2.10.1 + +## 5.0.0 + +### Major Changes + +- [#3928](https://github.com/wevm/wagmi/pull/3928) [`3117e71825f9c58a0d718f3d1686f1a191fa9cb1`](https://github.com/wevm/wagmi/commit/3117e71825f9c58a0d718f3d1686f1a191fa9cb1) Thanks [@tmm](https://github.com/tmm)! - **Breaking:** Updated default Coinbase SDK in `coinbaseWallet` Connector to v4.x. + + Added a `version` property (defaults to `'4'`) to the `coinbaseWallet` Connector to target a version of the Coinbase SDK: + + ```diff + coinbaseWallet({ + + version: '3' | '4', + }) + ``` + + If `headlessMode` property is set to `true`, then the Connector will target v3 of the Coinbase SDK. + + The following properties are removed in v4 of the `coinbaseWallet` Connector: + + - `chainId` + - `darkMode` + - `diagnosticLogger` + - `enableMobileDeepLink` + - `jsonRpcUrl` + - `linkApiUrl` + - `overrideIsCoinbaseBrowser` + - `overrideIsCoinbaseWallet` + - `overrideIsMetaMask` + - `reloadOnDisconnect` + - `uiConstructor` + + Consumers can still use the above properties in v3 by passing `version: '3'` to the Connector. However, please note that v3 of the Coinbase SDK is deprecated and will be removed in a future release. + +### Patch Changes + +- Updated dependencies [[`3117e71825f9c58a0d718f3d1686f1a191fa9cb1`](https://github.com/wevm/wagmi/commit/3117e71825f9c58a0d718f3d1686f1a191fa9cb1)]: + - @wagmi/core@2.10.0 + +## 4.3.10 + +### Patch Changes + +- [#3906](https://github.com/wevm/wagmi/pull/3906) [`32fcb4a31dde6b0206961d8ffe9c651f8a459c67`](https://github.com/wevm/wagmi/commit/32fcb4a31dde6b0206961d8ffe9c651f8a459c67) Thanks [@tmm](https://github.com/tmm)! - Added support for Vue. + +- Updated dependencies [[`32fcb4a31dde6b0206961d8ffe9c651f8a459c67`](https://github.com/wevm/wagmi/commit/32fcb4a31dde6b0206961d8ffe9c651f8a459c67)]: + - @wagmi/core@2.9.8 + +## 4.3.9 + +### Patch Changes + +- [#3924](https://github.com/wevm/wagmi/pull/3924) [`1f58734f88458e0f6adb05c99f0c90f36ab286b8`](https://github.com/wevm/wagmi/commit/1f58734f88458e0f6adb05c99f0c90f36ab286b8) Thanks [@jxom](https://github.com/jxom)! - Refactored `isChainsStale` logic in `walletConnect` connector. + +- Updated dependencies [[`1f58734f88458e0f6adb05c99f0c90f36ab286b8`](https://github.com/wevm/wagmi/commit/1f58734f88458e0f6adb05c99f0c90f36ab286b8)]: + - @wagmi/core@2.9.7 + +## 4.3.8 + +### Patch Changes + +- [#3917](https://github.com/wevm/wagmi/pull/3917) [`05948fdad5bb4a56b08916d45b3dec2cb1e5f55b`](https://github.com/wevm/wagmi/commit/05948fdad5bb4a56b08916d45b3dec2cb1e5f55b) Thanks [@jxom](https://github.com/jxom)! - Updated `@metamask/sdk`. + +- Updated dependencies [[`05948fdad5bb4a56b08916d45b3dec2cb1e5f55b`](https://github.com/wevm/wagmi/commit/05948fdad5bb4a56b08916d45b3dec2cb1e5f55b)]: + - @wagmi/core@2.9.6 + +## 4.3.7 + +### Patch Changes + +- Updated dependencies [[`4fecbbb66d0aacd03b8c62a6455d11a33cde8f85`](https://github.com/wevm/wagmi/commit/4fecbbb66d0aacd03b8c62a6455d11a33cde8f85)]: + - @wagmi/core@2.9.5 + +## 4.3.6 + +### Patch Changes + +- Updated dependencies [[`e6139a97c4b8804d734b1547b5e3921ce01fbe24`](https://github.com/wevm/wagmi/commit/e6139a97c4b8804d734b1547b5e3921ce01fbe24)]: + - @wagmi/core@2.9.4 + +## 4.3.5 + +### Patch Changes + +- [#3904](https://github.com/wevm/wagmi/pull/3904) [`addca28ebc20f1a4367c35fe9ef786decff9c87e`](https://github.com/wevm/wagmi/commit/addca28ebc20f1a4367c35fe9ef786decff9c87e) Thanks [@jxom](https://github.com/jxom)! - Updated `@walletconnect/ethereum-provider`. + +- Updated dependencies [[`addca28ebc20f1a4367c35fe9ef786decff9c87e`](https://github.com/wevm/wagmi/commit/addca28ebc20f1a4367c35fe9ef786decff9c87e)]: + - @wagmi/core@2.9.3 + +## 4.3.4 + +### Patch Changes + +- [#3902](https://github.com/wevm/wagmi/pull/3902) [`204b7b624612405500ec098fb9e35facd3f74ca4`](https://github.com/wevm/wagmi/commit/204b7b624612405500ec098fb9e35facd3f74ca4) Thanks [@jxom](https://github.com/jxom)! - Made third-party SDK imports type-only. + +- Updated dependencies [[`204b7b624612405500ec098fb9e35facd3f74ca4`](https://github.com/wevm/wagmi/commit/204b7b624612405500ec098fb9e35facd3f74ca4)]: + - @wagmi/core@2.9.2 + +## 4.3.3 + +### Patch Changes + +- Updated dependencies [[`cda6a5d5`](https://github.com/wevm/wagmi/commit/cda6a5d56328330fbde050b4ef40b01c58d2519a)]: + - @wagmi/core@2.9.1 + +## 4.3.2 + +### Patch Changes + +- Updated dependencies [[`017828fc`](https://github.com/wevm/wagmi/commit/017828fc027c7a84b54ea9d627e9389f4d60d6c2)]: + - @wagmi/core@2.9.0 + +## 4.3.1 + +### Patch Changes + +- Updated dependencies [[`d4a78eb0`](https://github.com/wevm/wagmi/commit/d4a78eb07119d2e5617e52481ac7d6c6d1583ddc)]: + - @wagmi/core@2.8.1 + +## 4.3.0 + +### Minor Changes + +- [#3868](https://github.com/wevm/wagmi/pull/3868) [`c2af20b8`](https://github.com/wevm/wagmi/commit/c2af20b88cf16970d087faaec10b463357a5836e) Thanks [@jxom](https://github.com/jxom)! - Added `supportsSimulation` property to connectors that indicates if the connector's wallet supports contract simulation. + +### Patch Changes + +- Updated dependencies [[`0d141f17`](https://github.com/wevm/wagmi/commit/0d141f171d6ec44bcbfc9c876565b5e2fb8af6de), [`c2af20b8`](https://github.com/wevm/wagmi/commit/c2af20b88cf16970d087faaec10b463357a5836e)]: + - @wagmi/core@2.8.0 + +## 4.2.0 + +### Minor Changes + +- [#3857](https://github.com/wevm/wagmi/pull/3857) [`d4274c03`](https://github.com/wevm/wagmi/commit/d4274c03a6af5f2d26d31432016ebc14950a330e) Thanks [@tmm](https://github.com/tmm)! - Added `addEthereumChainParameter` to `switchChain`-related methods. + +### Patch Changes + +- Updated dependencies [[`d4274c03`](https://github.com/wevm/wagmi/commit/d4274c03a6af5f2d26d31432016ebc14950a330e), [`4781a405`](https://github.com/wevm/wagmi/commit/4781a4056d4ffc2c74f96a75429e9b2cd2417ad8), [`400c960b`](https://github.com/wevm/wagmi/commit/400c960b30d701c134850c695ae903a382c29b5b)]: + - @wagmi/core@2.7.0 + +## 4.1.28 + +### Patch Changes + +- [`e3c832a1`](https://github.com/wevm/wagmi/commit/e3c832a12c301f9b0ee129d877b3101d220ba8b2) Thanks [@jxom](https://github.com/jxom)! - Fixed undefined `navigator` issue in MetaMask connector. + +- Updated dependencies [[`e3c832a1`](https://github.com/wevm/wagmi/commit/e3c832a12c301f9b0ee129d877b3101d220ba8b2)]: + - @wagmi/core@2.6.19 + +## 4.1.27 + +### Patch Changes + +- [#3848](https://github.com/wevm/wagmi/pull/3848) [`dd40a41c`](https://github.com/wevm/wagmi/commit/dd40a41c526ab60a288aff2250ed8dba92a27b16) Thanks [@jxom](https://github.com/jxom)! - Updated MetaMask SDK. + +- Updated dependencies [[`dd40a41c`](https://github.com/wevm/wagmi/commit/dd40a41c526ab60a288aff2250ed8dba92a27b16)]: + - @wagmi/core@2.6.18 + +## 4.1.26 + +### Patch Changes + +- Updated dependencies [[`a97bfbae`](https://github.com/wevm/wagmi/commit/a97bfbaeb615cfef04665e5e7348d85d17f960f0)]: + - @wagmi/core@2.6.17 + +## 4.1.25 + +### Patch Changes + +- [#3788](https://github.com/wevm/wagmi/pull/3788) [`42ad380d`](https://github.com/wevm/wagmi/commit/42ad380d9a5d8bc0f61d73612142dea9d098de5e) Thanks [@tmm](https://github.com/tmm)! - Refactored connectors to remove unnecessarily event listeners. + +- Updated dependencies [[`42ad380d`](https://github.com/wevm/wagmi/commit/42ad380d9a5d8bc0f61d73612142dea9d098de5e)]: + - @wagmi/core@2.6.16 + +## 4.1.24 + +### Patch Changes + +- Updated dependencies [[`b907d5ac`](https://github.com/wevm/wagmi/commit/b907d5ac3a746bcbccc06d1fe78c5bd8f9a7d685)]: + - @wagmi/core@2.6.15 + +## 4.1.23 + +### Patch Changes + +- Updated dependencies [[`b3b54ef1`](https://github.com/wevm/wagmi/commit/b3b54ef179c5fa0d1694d38d4b808549a0550409), [`3da20bb8`](https://github.com/wevm/wagmi/commit/3da20bb80e7c3efeef8227ced66ad615370fc242), [`a3d1858f`](https://github.com/wevm/wagmi/commit/a3d1858fce448d2b70e36ee692ef1589b74e9d3f)]: + - @wagmi/core@2.6.14 + +## 4.1.22 + +### Patch Changes + +- Updated dependencies [[`b80236dc`](https://github.com/wevm/wagmi/commit/b80236dc623095fe8f1e1d10957d7776fb6ab48b)]: + - @wagmi/core@2.6.13 + +## 4.1.21 + +### Patch Changes + +- Updated dependencies [[`a59069e9`](https://github.com/wevm/wagmi/commit/a59069e9fab45dd606bb89a7f829fe94c51a5494), [`0acd3132`](https://github.com/wevm/wagmi/commit/0acd31320f534993af566be5490c2978b6184f66)]: + - @wagmi/core@2.6.12 + +## 4.1.20 + +### Patch Changes + +- [`e1ca4e63`](https://github.com/wevm/wagmi/commit/e1ca4e637ae6cec7f5902b0a2c0e0efc3b751a1d) Thanks [@tmm](https://github.com/tmm)! - Deprecated `normalizeChainId`. Use `Number` instead. + +- Updated dependencies [[`e1ca4e63`](https://github.com/wevm/wagmi/commit/e1ca4e637ae6cec7f5902b0a2c0e0efc3b751a1d)]: + - @wagmi/core@2.6.11 + +## 4.1.19 + +### Patch Changes + +- Updated dependencies [[`dbdca8fd`](https://github.com/wevm/wagmi/commit/dbdca8fd14b90c166222a66a373c1b33c06ce019)]: + - @wagmi/core@2.6.10 + +## 4.1.18 + +### Patch Changes + +- Updated dependencies [[`d56edf4f`](https://github.com/wevm/wagmi/commit/d56edf4f27c52acc7a0f57114454b0d3e22cacd6)]: + - @wagmi/core@2.6.9 + +## 4.1.17 + +### Patch Changes + +- Updated dependencies [[`e46bcd47`](https://github.com/wevm/wagmi/commit/e46bcd4738a18da15b53f6612b614379c1985374)]: + - @wagmi/core@2.6.8 + +## 4.1.16 + +### Patch Changes + +- [`1c1fee6a`](https://github.com/wevm/wagmi/commit/1c1fee6ab8f01f7734ac6ce05093fa8e388beb3e) Thanks [@jxom](https://github.com/jxom)! - Updated `@walletconnect/ethereum-provider`. + +- [#3653](https://github.com/wevm/wagmi/pull/3653) [`88a2d744`](https://github.com/wevm/wagmi/commit/88a2d744a1315908c9e54156026df3ad2435ad44) Thanks [@tash-2s](https://github.com/tash-2s)! - Fixed error occurring when adding chains without explorers to MetaMask. + +- Updated dependencies [[`b479b5e8`](https://github.com/wevm/wagmi/commit/b479b5e8a5866cba792862f22e6352c4fb566137), [`f5648dd2`](https://github.com/wevm/wagmi/commit/f5648dd28b3576b628f57732b89287f55acbb1c1), [`1c1fee6a`](https://github.com/wevm/wagmi/commit/1c1fee6ab8f01f7734ac6ce05093fa8e388beb3e), [`88a2d744`](https://github.com/wevm/wagmi/commit/88a2d744a1315908c9e54156026df3ad2435ad44)]: + - @wagmi/core@2.6.7 + +## 4.1.15 + +### Patch Changes + +- Updated dependencies [[`a91c0b64`](https://github.com/wevm/wagmi/commit/a91c0b64ba8b3e6537a560e69724eb601f26af27)]: + - @wagmi/core@2.6.6 + +## 4.1.14 + +### Patch Changes + +- [#3591](https://github.com/wevm/wagmi/pull/3591) [`ca5decdb`](https://github.com/wevm/wagmi/commit/ca5decdb712f81e3f5dab933a94b967bca5b6af4) Thanks [@tmm](https://github.com/tmm)! - Fixed Coinbase Wallet import. + +- Updated dependencies [[`c677dcd2`](https://github.com/wevm/wagmi/commit/c677dcd245dccdf69289a3d66dded237b09570a2)]: + - @wagmi/core@2.6.5 + +## 4.1.13 + +### Patch Changes + +- [#3569](https://github.com/wevm/wagmi/pull/3569) [`fa25b448`](https://github.com/wevm/wagmi/commit/fa25b4482504b4d9729a5687ea6d6dc959265bc0) Thanks [@svenvoskamp](https://github.com/svenvoskamp)! - Updated dependencies. + +- [#3558](https://github.com/wevm/wagmi/pull/3558) [`895f28e8`](https://github.com/wevm/wagmi/commit/895f28e873af7c8eda5ca85734ff67c8979fd950) Thanks [@tmm](https://github.com/tmm)! - Fixed connector warnings. + +- Updated dependencies [[`7c6618e6`](https://github.com/wevm/wagmi/commit/7c6618e6a0eb1ff39cf8f66b34d3ddc14be538fe), [`895f28e8`](https://github.com/wevm/wagmi/commit/895f28e873af7c8eda5ca85734ff67c8979fd950)]: + - @wagmi/core@2.6.4 + +## 4.1.12 + +### Patch Changes + +- Updated dependencies [[`9c3b85dd`](https://github.com/wevm/wagmi/commit/9c3b85dd0a9a4a593e1d7e029345275735330e32), [`2a72214a`](https://github.com/wevm/wagmi/commit/2a72214a2901d6b6ddd39f80238aa0bd4db670a7)]: + - @wagmi/core@2.6.3 + +## 4.1.11 + +### Patch Changes + +- [#3518](https://github.com/wevm/wagmi/pull/3518) [`338e857d`](https://github.com/wevm/wagmi/commit/338e857d8cb2fe85e13d9207bef14cada1c1962d) Thanks [@tmm](https://github.com/tmm)! - Bumped dependencies. + +- Updated dependencies [[`414eb048`](https://github.com/wevm/wagmi/commit/414eb048af492caac70c0e874dfc87c30702804a), [`338e857d`](https://github.com/wevm/wagmi/commit/338e857d8cb2fe85e13d9207bef14cada1c1962d)]: + - @wagmi/core@2.6.2 + +## 4.1.10 + +### Patch Changes + +- [#3510](https://github.com/wevm/wagmi/pull/3510) [`660ff80d`](https://github.com/wevm/wagmi/commit/660ff80d5b046967a446eba43ee54b8359a37d0d) Thanks [@tmm](https://github.com/tmm)! - Fixed issue where connectors returning multiple addresses didn't checksum correctly. + +- Updated dependencies [[`660ff80d`](https://github.com/wevm/wagmi/commit/660ff80d5b046967a446eba43ee54b8359a37d0d), [`101a7dd1`](https://github.com/wevm/wagmi/commit/101a7dd131b0cae2dc25579ecab9044290efd37b)]: + - @wagmi/core@2.6.1 + +## 4.1.9 + +### Patch Changes + +- [#3496](https://github.com/wevm/wagmi/pull/3496) [`ba7f8a75`](https://github.com/wevm/wagmi/commit/ba7f8a758efb07664c6e401b5e7e325e7c62341b) Thanks [@tmm](https://github.com/tmm)! - Bumped dependencies. + +- Updated dependencies [[`ba7f8a75`](https://github.com/wevm/wagmi/commit/ba7f8a758efb07664c6e401b5e7e325e7c62341b)]: + - @wagmi/core@2.6.0 + +## 4.1.8 + +### Patch Changes + +- Updated dependencies [[`ca98041d`](https://github.com/wevm/wagmi/commit/ca98041d1b39893d90246929485f4db0d1c6f9f7)]: + - @wagmi/core@2.5.0 + +## 4.1.7 + +### Patch Changes + +- [#3427](https://github.com/wevm/wagmi/pull/3427) [`370f1b4a`](https://github.com/wevm/wagmi/commit/370f1b4a3f154d181acf381c31c2e7862e22c0e4) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Bumped dependencies. + +- Updated dependencies [[`370f1b4a`](https://github.com/wevm/wagmi/commit/370f1b4a3f154d181acf381c31c2e7862e22c0e4)]: + - @wagmi/core@2.4.0 + +## 4.1.6 + +### Patch Changes + +- Updated dependencies [[`3be5bb7b`](https://github.com/wevm/wagmi/commit/3be5bb7b0b38646e12e6da5c762ef74dff66bcc2)]: + - @wagmi/core@2.3.1 + +## 4.1.5 + +### Patch Changes + +- [#3459](https://github.com/wevm/wagmi/pull/3459) [`d950b666`](https://github.com/wevm/wagmi/commit/d950b666b56700ca039ce16cdfdf34564991e7f5) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Bumped dependencies + +- [`1cfb6e5a`](https://github.com/wevm/wagmi/commit/1cfb6e5a875e707abcee00dd5739e87da05e8c90) Thanks [@jxom](https://github.com/jxom)! - Bumped listener limit on WalletConnect connector. + +- Updated dependencies [[`d950b666`](https://github.com/wevm/wagmi/commit/d950b666b56700ca039ce16cdfdf34564991e7f5), [`90ef39bb`](https://github.com/wevm/wagmi/commit/90ef39bb0f4ecb3c914d317875348e35ba0f4524), [`1cfb6e5a`](https://github.com/wevm/wagmi/commit/1cfb6e5a875e707abcee00dd5739e87da05e8c90)]: + - @wagmi/core@2.3.0 + +## 4.1.4 + +### Patch Changes + +- [#3443](https://github.com/wevm/wagmi/pull/3443) [`007024a6`](https://github.com/wevm/wagmi/commit/007024a684ddbecf924cdc06dd6a8854fc3d5eeb) Thanks [@jmrossy](https://github.com/jmrossy)! - Bumped dependencies. + +- [#3447](https://github.com/wevm/wagmi/pull/3447) [`a02a26ad`](https://github.com/wevm/wagmi/commit/a02a26ad030d3afb78f744377d61b5c60b65d97a) Thanks [@tmm](https://github.com/tmm)! - Bumped dependencies. + +- Updated dependencies [[`a02a26ad`](https://github.com/wevm/wagmi/commit/a02a26ad030d3afb78f744377d61b5c60b65d97a), [`007024a6`](https://github.com/wevm/wagmi/commit/007024a684ddbecf924cdc06dd6a8854fc3d5eeb)]: + - @wagmi/core@2.2.1 + +## 4.1.3 + +### Patch Changes + +- Updated dependencies [[`00bf10a4`](https://github.com/wevm/wagmi/commit/00bf10a428b0d1c5dac35ebf25b19571e033ac26), [`64c073f6`](https://github.com/wevm/wagmi/commit/64c073f6c2720961e2d6aff986670b73dbfab9c3), [`fb6c4148`](https://github.com/wevm/wagmi/commit/fb6c4148d9e9e2fccfbe74c8f343b444dc68dec5)]: + - @wagmi/core@2.2.0 + +## 4.1.2 + +### Patch Changes + +- Updated dependencies [[`e00b8205`](https://github.com/wevm/wagmi/commit/e00b82058685751637edfa9a6b2d196a12549fe7)]: + - @wagmi/core@2.1.2 + +## 4.1.1 + +### Patch Changes + +- [`ec0d8b41`](https://github.com/wevm/wagmi/commit/ec0d8b4112181fefb11025e436a94a6114761d37) Thanks [@tmm](https://github.com/tmm)! - Added note to `metaMask` connector. + +- Updated dependencies [[`64b82282`](https://github.com/wevm/wagmi/commit/64b82282c1e57e77c25aa0814673780e4d11edd4), [`ec0d8b41`](https://github.com/wevm/wagmi/commit/ec0d8b4112181fefb11025e436a94a6114761d37)]: + - @wagmi/core@2.1.1 + +## 4.1.0 + +### Minor Changes + +- Updated dependencies [[`c9cd302e`](https://github.com/wevm/wagmi/commit/c9cd302e1c65c980deaee2e12567c2a8ec08b399)]: + - @wagmi/core@2.1.0 + +## 4.0.2 + +### Patch Changes + +- [#3384](https://github.com/wevm/wagmi/pull/3384) [`ee868c33`](https://github.com/wevm/wagmi/commit/ee868c3385dae511230b6ddcb5627c1293cc1844) Thanks [@tmm](https://github.com/tmm)! - Fixed connectors not bubbling error when connecting with `chainId` and subsequent user rejection. + +- Updated dependencies [[`ee868c33`](https://github.com/wevm/wagmi/commit/ee868c3385dae511230b6ddcb5627c1293cc1844)]: + - @wagmi/core@2.0.2 + +## 4.0.1 + +### Major Changes + +- [#3333](https://github.com/wevm/wagmi/pull/3333) [`b3a0baaa`](https://github.com/wevm/wagmi/commit/b3a0baaaee7decf750d376aab2502cd33ca4825a) Thanks [@tmm](https://github.com/tmm)! - Added support for Wagmi 2.0. + +### Patch Changes + +- Updated dependencies [[`b3a0baaa`](https://github.com/wevm/wagmi/commit/b3a0baaaee7decf750d376aab2502cd33ca4825a)]: + - @wagmi/core@2.0.0 + +## 3.1.11 + +### Patch Changes + +- [#3361](https://github.com/wevm/wagmi/pull/3361) [`bbbbf587`](https://github.com/wevm/wagmi/commit/bbbbf587e41bae12b072b7a7c897d580fc07cd2b) Thanks [@0xAsimetriq](https://github.com/0xAsimetriq)! - Updated WalletConnect connector dependencies + +## 3.1.10 + +### Patch Changes + +- [`53ca1f7e`](https://github.com/wevm/wagmi/commit/53ca1f7eb411d912e11fcce7e03bd61ed067959c) Thanks [@tmm](https://github.com/tmm)! - Removed LedgerConnector due to security vulnerability + +## 3.1.9 + +### Patch Changes + +- [#3114](https://github.com/wevm/wagmi/pull/3114) [`51eca0fb`](https://github.com/wevm/wagmi/commit/51eca0fbaea6932f31a5b8b4213f0252280053e2) Thanks [@akathecoder](https://github.com/akathecoder)! - Added Okto Wallet to Injected Wallets Connector + +- [#3299](https://github.com/wevm/wagmi/pull/3299) [`b02020b3`](https://github.com/wevm/wagmi/commit/b02020b3724e0228198f35817611bb063295906e) Thanks [@dasanra](https://github.com/dasanra)! - Fixed issue with [Safe SDK](https://github.com/wevm/viem/issues/579) by bumping `@safe-global/safe-apps-provider@0.18.1` + +## 3.1.8 + +### Patch Changes + +- [#3197](https://github.com/wevm/wagmi/pull/3197) [`e8f7bcbc`](https://github.com/wevm/wagmi/commit/e8f7bcbcd9c038a901c29e71769682c088efe2ac) Thanks [@ByteZhang1024](https://github.com/ByteZhang1024)! - Added OneKey Wallet to injected connector flags. + +## 3.1.7 + +### Patch Changes + +- [#3276](https://github.com/wevm/wagmi/pull/3276) [`83223a06`](https://github.com/wevm/wagmi/commit/83223a0659e2f675d897a1d3374c7af752c16abf) Thanks [@glitch-txs](https://github.com/glitch-txs)! - Removed required namespaces from WalletConnect connector + +## 3.1.6 + +### Patch Changes + +- [#3236](https://github.com/wevm/wagmi/pull/3236) [`cc7e18f2`](https://github.com/wevm/wagmi/commit/cc7e18f2e7f6b8b989f60f0b05aee70e996a9975) Thanks [@0xAsimetriq](https://github.com/0xAsimetriq)! - Updated @walletconnect/ethereum-provider + +- [#3236](https://github.com/wevm/wagmi/pull/3236) [`cc7e18f2`](https://github.com/wevm/wagmi/commit/cc7e18f2e7f6b8b989f60f0b05aee70e996a9975) Thanks [@0xAsimetriq](https://github.com/0xAsimetriq)! - Updated @walletconnect/ethereum-provider + +## 3.1.5 + +### Patch Changes + +- [#3220](https://github.com/wagmi-dev/wagmi/pull/3220) [`a1950449`](https://github.com/wagmi-dev/wagmi/commit/a1950449127ddf72fff8ecd1fc34c3690befbb05) Thanks [@rkalis](https://github.com/rkalis)! - Fixed a bug where injected walets with an empty providers array could not connect + +## 3.1.4 + +### Patch Changes + +- [#3115](https://github.com/wagmi-dev/wagmi/pull/3115) [`4e6ec415`](https://github.com/wagmi-dev/wagmi/commit/4e6ec4151baece94e940e227e0e3711c7f8534d9) Thanks [@bifot](https://github.com/bifot)! - Added SafePal injected name mapping. + +## 3.1.3 + +### Patch Changes + +- [#3141](https://github.com/wagmi-dev/wagmi/pull/3141) [`e78aa337`](https://github.com/wagmi-dev/wagmi/commit/e78aa337c454f04b41a3cbd381d25270dd4a0afd) Thanks [@einaralex](https://github.com/einaralex)! - Updated WalletConnect libraries. + +## 3.1.2 + +### Patch Changes + +- [#3009](https://github.com/wagmi-dev/wagmi/pull/3009) [`3aaba328`](https://github.com/wagmi-dev/wagmi/commit/3aaba32808ddb4035ec885f96992c91078056715) Thanks [@0xAsimetriq](https://github.com/0xAsimetriq)! - Update WalletConnect dependencies + +## 3.1.1 + +### Patch Changes + +- [#2973](https://github.com/wevm/wagmi/pull/2973) [`bf831bb3`](https://github.com/wevm/wagmi/commit/bf831bb30df8037cc4312342d0fe3c045408c2fe) Thanks [@masm](https://github.com/masm)! - Added Zeal wallet + +## 3.1.0 + +### Minor Changes + +- [#2956](https://github.com/wevm/wagmi/pull/2956) [`2abeb285`](https://github.com/wevm/wagmi/commit/2abeb285674af3e539cc2550b1f5027b1eb0c895) Thanks [@tmm](https://github.com/tmm)! - Replaced `@wagmi/chains` with `viem/chains`. + +## 3.0.0 + +### Patch Changes + +- 0306383: Updated WalletConnect dependencies +- Updated dependencies [d1ef9b4] +- Updated dependencies [484c846] + - @wagmi/chains@1.8.0 + +## 2.7.0 + +### Minor Changes + +- a270cb9: Updated WalletConnect dependencies. + +### Patch Changes + +- 06cc1b4: Add SubWallet injected flags +- 131a337: Added Desig Wallet name mapping. +- e089d7d: Added Fordefi Wallet name mapping. +- ce84d0a: Added Coin98 Wallet injected flags. +- Updated dependencies [8fdacd8] +- Updated dependencies [2e9283a] +- Updated dependencies [a432a2b] +- Updated dependencies [408740a] +- Updated dependencies [6794a61] +- Updated dependencies [0c5a32b] +- Updated dependencies [ebc85ec] +- Updated dependencies [5683df2] +- Updated dependencies [414ff36] +- Updated dependencies [4f514c6] +- Updated dependencies [1cf72bc] +- Updated dependencies [cd68471] +- Updated dependencies [baf3143] +- Updated dependencies [9737f24] +- Updated dependencies [7797238] +- Updated dependencies [3846811] +- Updated dependencies [0ea344c] + - @wagmi/chains@1.7.0 + +## 2.6.6 + +### Patch Changes + +- 56c127d: Updated WalletConnect dependencies. +- Updated dependencies [4b411d2] +- Updated dependencies [df697ac] +- Updated dependencies [186f5a7] +- Updated dependencies [a96b514] +- Updated dependencies [0a6e6da] + - @wagmi/chains@1.5.0 + +## 2.6.5 + +### Patch Changes + +- 51e346e: Updated WalletConnectConnector logic to handle individual namespaces like eip155:\* + +## 2.6.4 + +### Patch Changes + +- 0a57de2: Added conditional for WalletConnectConnector optionalChains + +## 2.6.3 + +### Patch Changes + +- f2d532d: Updated WalletConnect dependencies, exposed `relayUrl` option for `WalletConnectConnector` +- ff53857: Fixed issue importing `EthereumProvider` in Vite environments. +- Updated dependencies [d642e1d] +- Updated dependencies [3027d7b] +- Updated dependencies [97dbd44] + - @wagmi/chains@1.4.0 + +## 2.6.2 + +### Patch Changes + +- 27bb1b3: Added explicit type annotations for the `getWalletClient()` method. + +## 2.6.1 + +### Patch Changes + +- a3507a9: Updated @walletconnect/ethereum-provider dependency + +## 2.6.0 + +### Minor Changes + +- 32dc317: Updated @walletconnect/ethereum-provider and @walletconnect/modal dependencies + +## 2.5.0 + +### Minor Changes + +- 57e674e: Updated `@safe-global/safe-apps-sdk` & `@safe-global/safe-apps-provider` + +## 2.4.0 + +### Patch Changes + +- f21c8e0: Added WalletConnect v2 support to Ledger connector. +- 27482bb: Add HAQQ Wallet detection +- 7d6aa43: Exported `normalizeChainId`. +- Updated dependencies [62b8209] +- Updated dependencies [106ac13] +- Updated dependencies [8b3f5e5] + - @wagmi/chains@1.3.0 + +## 2.3.0 + +### Minor Changes + +- 28219ae: Added metadata property to WalletConnect init function +- 6fef949: Updated @walletconnect/modal and @walletconnect/ethereum-provider deps + +### Patch Changes + +- 72f6465: Added `TTWallet` to `getInjectedName` list +- Updated dependencies [a7cbd04] +- Updated dependencies [f6ee133] + - @wagmi/chains@1.2.0 + +## 2.2.0 + +### Minor Changes + +- 6c841d4: Changed `Address` type import from ABIType to viem. + +### Patch Changes + +- 09c83f8: Update @walletconnect/ethereum-provider, Replace @web3modal/standalone with @walletconnect/modal, Fix issue with wallet_addEthereumChain method in WalletConnectConnector + +## 2.1.1 + +### Patch Changes + +- c24de75: Updated `@walletconnect/ethereum-provider` and `@web3modal/standalone` dependencies. +- 605c422: Bumped `viem` peer dependency. +- dc1c546: Throw ResourceUnavailableError on -30002 errors. + +## 2.1.0 + +### Minor Changes + +- b001569: Bumped minimum TypeScript version to v5.0.4. + +### Patch Changes + +- 0f05b2b: Updated `abitype` to `0.8.7`. +- 6aea7ee: Fixed internal types. +- b187cb0: Added `isNovaWallet` injected flag. +- 5e44429: Added Edgeware mainnet and testnet +- b18b314: Updated @walletconnect/ethereum-provider and @web3modal/standalone dependencies +- Updated dependencies [b62a199] +- Updated dependencies [b001569] +- Updated dependencies [260ab59] +- Updated dependencies [6aea7ee] +- Updated dependencies [5e44429] + - @wagmi/chains@1.0.0 + +## 2.0.0 + +### Patch Changes + +- Updated dependencies [36c14b2] + - @wagmi/chains@0.3.0 + +## 1.0.5 + +### Patch Changes + +- fa61dfe: Updated viem. +- Updated dependencies [577d2a0] + - @wagmi/chains@0.2.25 + +## 1.0.4 + +### Patch Changes + +- bbbd11b: Corrected Rabby Wallet name +- Updated dependencies [0639a1f] + - @wagmi/chains@0.2.24 + +## 1.0.3 + +### Patch Changes + +- 64dfe61: Update @web3modal/standalone to v2.4.1, Update @walletconnect/ethereum-provider to 2.7.4 +- bab7ad8: Added Defiant to injected connector flags +- 44cde07: Added Talisman wallet flag + +## 1.0.2 + +### Patch Changes + +- bce5a0c: Removed chain fallback when instantiating a Wallet Client. + +## 1.0.1 + +### Patch Changes + +- [`ea651cd7`](https://github.com/wevm/wagmi/commit/ea651cd7fc75b7866272605467db11fd6e1d81af) Thanks [@jxom](https://github.com/jxom)! - Downgraded abitype. + +## 1.0.0 + +### Major Changes + +- 7e274f5: Released v1. + +### Patch Changes + +- 0966bf7: Changed Kucoin Wallet name mapping to Halo Wallet + +## 1.0.0-next.5 + +### Major Changes + +- Updated references. + +## 1.0.0-next.4 + +### Major Changes + +- Updated references. + +## 1.0.0-next.3 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/chains@1.0.0-next.0 + +## 1.0.0-next.2 + +### Major Changes + +- updated viem + +## 1.0.0-next.1 + +### Major Changes + +- [`a7dda00c`](https://github.com/wevm/wagmi/commit/a7dda00c5b546f8b2c42b527e4d9ac1b9e9ab1fb) Thanks [@jxom](https://github.com/jxom)! - Released v1. + +## 1.0.0-next.0 + +### Major Changes + +- 33488cf: Released v1. + +## 0.3.19 + +### Patch Changes + +- 274eef3: - Updated @web3modal/standalone to 2.3.7 + - Updated @walletconnect/ethereum-provider to 2.7.1 +- 41697df: Updated @walletconnect/ethereum-provider version to 2.7.2 +- 82dcb72: Added Enkrypt extension detection + +## 0.3.18 + +### Patch Changes + +- f66e065: Added BlockWallet to injected connector flags. + +## 0.3.17 + +### Patch Changes + +- 12ab5d1: Updated @coinbase/wallet-sdk to 3.6.6 + +## 0.3.16 + +### Patch Changes + +- c1e3ddf: Reverted ABIType version change. + +## 0.3.15 + +### Patch Changes + +- d4825e6: Fixed ABIType version to match downstream packages. + +## 0.3.14 + +### Patch Changes + +- c25ac82: Added more flags to `MetaMaskConnector` `getProvider` check. +- b19a932: Updated @web3modal/standalone to 2.3.0, @walletconnect/ethereum-provider to 2.7.0 +- cdc387e: Added `ImToken` to `getInjectedName` list + +## 0.3.13 + +### Patch Changes + +- 2a21d27: Updated `@coinbase/wallet-sdk` to `3.6.4` + +## 0.3.12 + +### Patch Changes + +- 9bb22b6: Updated `@walletconnect/ethereum-provider` to `2.6.2`, relaxed `@web3modal/standalone` version requirement +- 0d7625b: Added Rabby to injected connector flags +- f63d7fd: Added correct error to switch network cause. + +## 0.3.11 + +### Patch Changes + +- 0778abc: Renamed `isTally` injected provider to `Taho` + +## 0.3.10 + +### Patch Changes + +- 4267020: Added `qrModalOptions` option to `WalletConnectConnector` +- e78fb0a: Pinned WalletConnect dependencies + +## 0.3.9 + +### Patch Changes + +- 5cd0afc: Added `isZerion` to `InjectedProviderFlags` and `getInjectedName` +- be4825e: Added GameStop Wallet to injected connector flags + +## 0.3.8 + +### Patch Changes + +- 11f3fe2: Fixed issue where `UNSTABLE_shimOnConnectSelectAccount` would not bubble up error for MetaMask if request to connect was already active. + +## 0.3.7 + +### Patch Changes + +- 04c0e47: Fixed issue switching chain after adding to MetaMask. + +## 0.3.6 + +### Patch Changes + +- 85330c1: Removed `InjectedConnector` `shimChainChangedDisconnect` shim (no longer necessary). + +## 0.3.5 + +### Patch Changes + +- 8b1a526: Added Dawn wallet flag + +## 0.3.4 + +### Patch Changes + +- 6b15d6f: Updated `@walletconnect/ethereum-provider` to `2.5.1`. +- 1f452e7: Added OKX Wallet to injected connector flags. +- a4d9083: Added Backpack wallet to injected connector flags. +- 6a4af48: Enabled support for programmatic chain switching on `LedgerConnector` & added `"ledger"` to the switch chain regex on `WalletConnectLegacyConnector`. + +## 0.3.3 + +### Patch Changes + +- f24ce0c: Updated @walletconnect/ethereum-provider to 2.4.8 +- e3a3fee: Added "uniswap wallet" to the regex that determines wallets allowed to switch chains in the WalletConnect legacy connector +- 641af48: Added name mapping for Bifrost Wallet +- 4d2c90a: Added name mapping for Phantom +- 3d276d0: Added Status as the name of the injected connector for the Status App + +## 0.3.2 + +### Patch Changes + +- 13a6a07: Updated `@walletconnect/ethereum-provider` to `2.4.7`. + +## 0.3.1 + +### Patch Changes + +- a23c40f: Added name mapping for [Frontier](https://frontier.xyz) Wallet +- d779fb3: Added name mapping for HyperPay. + +## 0.3.0 + +### Minor Changes + +- c4d5bb5: **Breaking:** Removed the `version` config option for `WalletConnectConnector`. + + `WalletConnectConnector` now uses WalletConnect v2 by default. WalletConnect v1 is now `WalletConnectLegacyConnector`. + + ### WalletConnect v2 + + ```diff + import { WalletConnectConnector } from '@wagmi/connectors/walletConnect' + + const connector = new WalletConnectConnector({ + options: { + - version: '2', + projectId: 'abc', + }, + }) + ``` + + ### WalletConnect v1 + + ```diff + -import { WalletConnectConnector } from '@wagmi/connectors/walletConnect' + +import { WalletConnectLegacyConnector } from '@wagmi/connectors/walletConnectLegacy' + + -const connector = new WalletConnectConnector({ + +const connector = new WalletConnectLegacyConnector({ + options: { + qrcode: true, + }, + }) + ``` + +## 0.2.7 + +### Patch Changes + +- 57f1226: Added name mapping for XDEFI + +## 0.2.6 + +### Patch Changes + +- bb1b88c: Added name mapping for Bitski injected wallet +- fcb5595: Fixed shim disconnect key to read from defined Connector ID. +- 49f8853: Fixed `SafeConnector` import type error that existed for specific build environments. + +## 0.2.5 + +### Patch Changes + +- 5d121f2: Added `isApexWallet` to injected `window.ethereum` flags. +- e3566eb: Updated `@web3modal/standalone` to `2.1.1` for WalletConnectConnector. + +## 0.2.4 + +### Patch Changes + +- a4f31bc: Added Connector for [Safe](https://safe.global) wallet +- d5e25d9: Locked ethers peer dependency version to >=5.5.1 <6 + +## 0.2.3 + +### Patch Changes + +- 6fa74dd: Updated `@walletconnect/universal-provider` + Added more signable methods to WC v2. + +## 0.2.2 + +### Patch Changes + +- 6b0725b: Fixed race condition between `switchNetwork` and mutation Hooks that use `chainId` (e.g. `sendTransaction`). + +## 0.2.1 + +### Patch Changes + +- 942fcde: Updated `@walletconnect/universal-provider` and `@web3modal/standalone` packages for WalletConnectConnector (v2). + + Improved initialization flow for `@walletconnect/universal-provider` for WalletConnectConnector (v2). + +## 0.2.0 + +### Minor Changes + +- be33c7d: Chains are now narrowed to their most specific type using the TypeScript [`satisfies`](https://devblogs.microsoft.com/typescript/announcing-typescript-4-9/#the-satisfies-operator) operator. + +## 0.1.10 + +### Patch Changes + +- d75e8d2: Fixed ABIType version mismatch between packages. + +## 0.1.9 + +### Patch Changes + +- 8c3fc00: Added public RPC URL to Connector fallback chains + +## 0.1.8 + +### Patch Changes + +- 5e6dc30: Replaced legacy qrcodemodal with web3modal for WalletConnect v2. + +## 0.1.7 + +### Patch Changes + +- be4add2: Added `isRainbow` flag to `InjectedConnector`. + +## 0.1.6 + +### Patch Changes + +- 3dfc558: Add `switchSigner` method to `MockProvider`. + +## 0.1.5 + +### Patch Changes + +- 7dce4b5: Bumped WalletConnect Universal Provider version. + +## 0.1.4 + +### Patch Changes + +- 4cec598: Added CJS escape hatch bundle under the "cjs" tag. + +## 0.1.3 + +### Patch Changes + +- 822bc88: The `WalletConnectConnector` now supports WalletConnect v2. + + It can be enabled by setting `version` to `'2'` and supplying a [WalletConnect Cloud `projectId`](https://cloud.walletconnect.com/sign-in). + +## 0.1.2 + +### Patch Changes + +- 5e5f37f: Fixed issue where connecting to MetaMask may return with a stale address + +## 0.1.1 + +### Patch Changes + +- 919790c: Updated `@ledgerhq/connect-kit-loader` to `1.0.1` + +## 0.1.0 + +### Minor Changes + +- 5db7cba: Added `LedgerConnector` +- 55a0ca2: Initial release of the `@wagmi/connectors` package – a collection of Connectors for wagmi. diff --git a/packages/connectors/README.md b/packages/connectors/README.md new file mode 100644 index 0000000000..05418ec15c --- /dev/null +++ b/packages/connectors/README.md @@ -0,0 +1,13 @@ +# @wagmi/connectors + +Collection of connectors for Wagmi + +## Installation + +```bash +pnpm add @wagmi/connectors @wagmi/core viem +``` + +## Documentation + +For documentation and guides, visit [wagmi.sh](https://wagmi.sh). diff --git a/packages/connectors/package.json b/packages/connectors/package.json new file mode 100644 index 0000000000..5ddcfaa107 --- /dev/null +++ b/packages/connectors/package.json @@ -0,0 +1,71 @@ +{ + "name": "@wagmi/connectors", + "description": "Collection of connectors for Wagmi", + "version": "5.8.3", + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/wevm/wagmi.git", + "directory": "packages/connectors" + }, + "scripts": { + "build": "pnpm run clean && pnpm run build:esm+types", + "build:esm+types": "tsc --project tsconfig.build.json --outDir ./dist/esm --declaration --declarationMap --declarationDir ./dist/types", + "check:types": "tsc --noEmit", + "clean": "rm -rf dist tsconfig.tsbuildinfo", + "test:build": "publint --strict && attw --pack --ignore-rules cjs-resolves-to-esm" + }, + "files": [ + "dist/**", + "!dist/**/*.tsbuildinfo", + "src/**/*.ts", + "!src/**/*.test.ts", + "!src/**/*.test-d.ts" + ], + "sideEffects": false, + "type": "module", + "main": "./dist/esm/exports/index.js", + "types": "./dist/types/exports/index.d.ts", + "typings": "./dist/types/exports/index.d.ts", + "exports": { + ".": { + "types": "./dist/types/exports/index.d.ts", + "default": "./dist/esm/exports/index.js" + }, + "./package.json": "./package.json" + }, + "peerDependencies": { + "@wagmi/core": "workspace:*", + "typescript": ">=5.0.4", + "viem": "2.x" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + }, + "dependencies": { + "@coinbase/wallet-sdk": "4.3.0", + "@metamask/sdk": "0.33.1", + "@safe-global/safe-apps-provider": "0.18.6", + "@safe-global/safe-apps-sdk": "9.1.0", + "@walletconnect/ethereum-provider": "2.20.2", + "cbw-sdk": "npm:@coinbase/wallet-sdk@3.9.3" + }, + "devDependencies": { + "@wagmi/core": "workspace:*", + "msw": "^2.4.9" + }, + "contributors": ["awkweb.eth ", "jxom.eth "], + "funding": "https://github.com/sponsors/wevm", + "keywords": [ + "react", + "hooks", + "eth", + "ethereum", + "dapps", + "wallet", + "web3", + "abi" + ] +} diff --git a/packages/connectors/src/coinbaseWallet.test.ts b/packages/connectors/src/coinbaseWallet.test.ts new file mode 100644 index 0000000000..99b141e49b --- /dev/null +++ b/packages/connectors/src/coinbaseWallet.test.ts @@ -0,0 +1,17 @@ +import { config } from '@wagmi/test' +import { expect, expectTypeOf, test } from 'vitest' + +import { coinbaseWallet } from './coinbaseWallet.js' + +test('setup', () => { + const connectorFn = coinbaseWallet({ appName: 'wagmi', version: '4' }) + const connector = config._internal.connectors.setup(connectorFn) + expect(connector.name).toEqual('Coinbase Wallet') + + type ConnectFnParameters = NonNullable< + Parameters<(typeof connector)['connect']>[0] + > + expectTypeOf().toMatchTypeOf< + boolean | undefined + >() +}) diff --git a/packages/connectors/src/coinbaseWallet.ts b/packages/connectors/src/coinbaseWallet.ts new file mode 100644 index 0000000000..630c91261e --- /dev/null +++ b/packages/connectors/src/coinbaseWallet.ts @@ -0,0 +1,546 @@ +import type { + Preference, + ProviderInterface, + createCoinbaseWalletSDK, +} from '@coinbase/wallet-sdk' +import { + ChainNotConfiguredError, + type Connector, + createConnector, +} from '@wagmi/core' +import type { Compute, Mutable, Omit } from '@wagmi/core/internal' +import type { + CoinbaseWalletProvider as CBW_Provider, + CoinbaseWalletSDK as CBW_SDK, +} from 'cbw-sdk' +import { + type AddEthereumChainParameter, + type Address, + type Hex, + type ProviderRpcError, + SwitchChainError, + UserRejectedRequestError, + getAddress, + numberToHex, +} from 'viem' + +type Version = '3' | '4' + +export type CoinbaseWalletParameters = + version extends '4' + ? Compute< + { + headlessMode?: false | undefined + /** Coinbase Wallet SDK version */ + version?: version | '3' | undefined + } & Version4Parameters + > + : Compute< + { + /** + * @deprecated `headlessMode` will be removed in the next major version. Upgrade to `version: '4'`. + */ + headlessMode?: true | undefined + /** + * Coinbase Wallet SDK version + * @deprecated Version 3 will be removed in the next major version. Upgrade to `version: '4'`. + * @default '4' + */ + version?: version | '4' | undefined + } & Version3Parameters + > + +coinbaseWallet.type = 'coinbaseWallet' as const +export function coinbaseWallet( + parameters: CoinbaseWalletParameters = {} as any, +): version extends '4' + ? ReturnType + : ReturnType { + if (parameters.version === '3' || parameters.headlessMode) + return version3(parameters as Version3Parameters) as any + return version4(parameters as Version4Parameters) as any +} + +type Version4Parameters = Mutable< + Omit< + Parameters[0], + | 'appChainIds' // set via wagmi config + | 'preference' + > & { + // TODO(v3): Remove `Preference['options']` + /** + * Preference for the type of wallet to display. + * @default 'all' + */ + preference?: Preference['options'] | Compute | undefined + } +> + +function version4(parameters: Version4Parameters) { + type Provider = ProviderInterface & { + // for backwards compatibility + close?(): void + } + type Properties = { + connect(parameters?: { + chainId?: number | undefined + instantOnboarding?: boolean | undefined + isReconnecting?: boolean | undefined + }): Promise<{ + accounts: readonly Address[] + chainId: number + }> + } + + let walletProvider: Provider | undefined + + let accountsChanged: Connector['onAccountsChanged'] | undefined + let chainChanged: Connector['onChainChanged'] | undefined + let disconnect: Connector['onDisconnect'] | undefined + + return createConnector((config) => ({ + id: 'coinbaseWalletSDK', + name: 'Coinbase Wallet', + rdns: 'com.coinbase.wallet', + type: coinbaseWallet.type, + async connect({ chainId, ...rest } = {}) { + try { + const provider = await this.getProvider() + const accounts = ( + (await provider.request({ + method: 'eth_requestAccounts', + params: + 'instantOnboarding' in rest && rest.instantOnboarding + ? [{ onboarding: 'instant' }] + : [], + })) as string[] + ).map((x) => getAddress(x)) + + if (!accountsChanged) { + accountsChanged = this.onAccountsChanged.bind(this) + provider.on('accountsChanged', accountsChanged) + } + if (!chainChanged) { + chainChanged = this.onChainChanged.bind(this) + provider.on('chainChanged', chainChanged) + } + if (!disconnect) { + disconnect = this.onDisconnect.bind(this) + provider.on('disconnect', disconnect) + } + + // Switch to chain if provided + let currentChainId = await this.getChainId() + if (chainId && currentChainId !== chainId) { + const chain = await this.switchChain!({ chainId }).catch((error) => { + if (error.code === UserRejectedRequestError.code) throw error + return { id: currentChainId } + }) + currentChainId = chain?.id ?? currentChainId + } + + return { accounts, chainId: currentChainId } + } catch (error) { + if ( + /(user closed modal|accounts received is empty|user denied account|request rejected)/i.test( + (error as Error).message, + ) + ) + throw new UserRejectedRequestError(error as Error) + throw error + } + }, + async disconnect() { + const provider = await this.getProvider() + + if (accountsChanged) { + provider.removeListener('accountsChanged', accountsChanged) + accountsChanged = undefined + } + if (chainChanged) { + provider.removeListener('chainChanged', chainChanged) + chainChanged = undefined + } + if (disconnect) { + provider.removeListener('disconnect', disconnect) + disconnect = undefined + } + + provider.disconnect() + provider.close?.() + }, + async getAccounts() { + const provider = await this.getProvider() + return ( + (await provider.request({ + method: 'eth_accounts', + })) as string[] + ).map((x) => getAddress(x)) + }, + async getChainId() { + const provider = await this.getProvider() + const chainId = (await provider.request({ + method: 'eth_chainId', + })) as Hex + return Number(chainId) + }, + async getProvider() { + if (!walletProvider) { + const preference = (() => { + if (typeof parameters.preference === 'string') + return { options: parameters.preference } + return { + ...parameters.preference, + options: parameters.preference?.options ?? 'all', + } + })() + + const { createCoinbaseWalletSDK } = await import('@coinbase/wallet-sdk') + const sdk = createCoinbaseWalletSDK({ + ...parameters, + appChainIds: config.chains.map((x) => x.id), + preference, + }) + + walletProvider = sdk.getProvider() + } + + return walletProvider + }, + async isAuthorized() { + try { + const accounts = await this.getAccounts() + return !!accounts.length + } catch { + return false + } + }, + async switchChain({ addEthereumChainParameter, chainId }) { + const chain = config.chains.find((chain) => chain.id === chainId) + if (!chain) throw new SwitchChainError(new ChainNotConfiguredError()) + + const provider = await this.getProvider() + + try { + await provider.request({ + method: 'wallet_switchEthereumChain', + params: [{ chainId: numberToHex(chain.id) }], + }) + return chain + } catch (error) { + // Indicates chain is not added to provider + if ((error as ProviderRpcError).code === 4902) { + try { + let blockExplorerUrls: string[] | undefined + if (addEthereumChainParameter?.blockExplorerUrls) + blockExplorerUrls = addEthereumChainParameter.blockExplorerUrls + else + blockExplorerUrls = chain.blockExplorers?.default.url + ? [chain.blockExplorers?.default.url] + : [] + + let rpcUrls: readonly string[] + if (addEthereumChainParameter?.rpcUrls?.length) + rpcUrls = addEthereumChainParameter.rpcUrls + else rpcUrls = [chain.rpcUrls.default?.http[0] ?? ''] + + const addEthereumChain = { + blockExplorerUrls, + chainId: numberToHex(chainId), + chainName: addEthereumChainParameter?.chainName ?? chain.name, + iconUrls: addEthereumChainParameter?.iconUrls, + nativeCurrency: + addEthereumChainParameter?.nativeCurrency ?? + chain.nativeCurrency, + rpcUrls, + } satisfies AddEthereumChainParameter + + await provider.request({ + method: 'wallet_addEthereumChain', + params: [addEthereumChain], + }) + + return chain + } catch (error) { + throw new UserRejectedRequestError(error as Error) + } + } + + throw new SwitchChainError(error as Error) + } + }, + onAccountsChanged(accounts) { + if (accounts.length === 0) this.onDisconnect() + else + config.emitter.emit('change', { + accounts: accounts.map((x) => getAddress(x)), + }) + }, + onChainChanged(chain) { + const chainId = Number(chain) + config.emitter.emit('change', { chainId }) + }, + async onDisconnect(_error) { + config.emitter.emit('disconnect') + + const provider = await this.getProvider() + if (accountsChanged) { + provider.removeListener('accountsChanged', accountsChanged) + accountsChanged = undefined + } + if (chainChanged) { + provider.removeListener('chainChanged', chainChanged) + chainChanged = undefined + } + if (disconnect) { + provider.removeListener('disconnect', disconnect) + disconnect = undefined + } + }, + })) +} + +type Version3Parameters = Mutable< + Omit< + ConstructorParameters[0], + 'reloadOnDisconnect' // remove property since TSDoc says default is `true` + > +> & { + /** + * Fallback Ethereum JSON RPC URL + * @default "" + */ + jsonRpcUrl?: string | undefined + /** + * Fallback Ethereum Chain ID + * @default 1 + */ + chainId?: number | undefined + /** + * Whether or not to reload dapp automatically after disconnect. + * @default false + */ + reloadOnDisconnect?: boolean | undefined +} + +function version3(parameters: Version3Parameters) { + const reloadOnDisconnect = false + + type Provider = CBW_Provider + + let sdk: CBW_SDK | undefined + let walletProvider: Provider | undefined + + let accountsChanged: Connector['onAccountsChanged'] | undefined + let chainChanged: Connector['onChainChanged'] | undefined + let disconnect: Connector['onDisconnect'] | undefined + + return createConnector((config) => ({ + id: 'coinbaseWalletSDK', + name: 'Coinbase Wallet', + rdns: 'com.coinbase.wallet', + type: coinbaseWallet.type, + async connect({ chainId } = {}) { + try { + const provider = await this.getProvider() + const accounts = ( + (await provider.request({ + method: 'eth_requestAccounts', + })) as string[] + ).map((x) => getAddress(x)) + + if (!accountsChanged) { + accountsChanged = this.onAccountsChanged.bind(this) + provider.on('accountsChanged', accountsChanged) + } + if (!chainChanged) { + chainChanged = this.onChainChanged.bind(this) + provider.on('chainChanged', chainChanged) + } + if (!disconnect) { + disconnect = this.onDisconnect.bind(this) + provider.on('disconnect', disconnect) + } + + // Switch to chain if provided + let currentChainId = await this.getChainId() + if (chainId && currentChainId !== chainId) { + const chain = await this.switchChain!({ chainId }).catch((error) => { + if (error.code === UserRejectedRequestError.code) throw error + return { id: currentChainId } + }) + currentChainId = chain?.id ?? currentChainId + } + + return { accounts, chainId: currentChainId } + } catch (error) { + if ( + /(user closed modal|accounts received is empty|user denied account)/i.test( + (error as Error).message, + ) + ) + throw new UserRejectedRequestError(error as Error) + throw error + } + }, + async disconnect() { + const provider = await this.getProvider() + + if (accountsChanged) { + provider.removeListener('accountsChanged', accountsChanged) + accountsChanged = undefined + } + if (chainChanged) { + provider.removeListener('chainChanged', chainChanged) + chainChanged = undefined + } + if (disconnect) { + provider.removeListener('disconnect', disconnect) + disconnect = undefined + } + + provider.disconnect() + provider.close() + }, + async getAccounts() { + const provider = await this.getProvider() + return ( + await provider.request({ + method: 'eth_accounts', + }) + ).map((x) => getAddress(x)) + }, + async getChainId() { + const provider = await this.getProvider() + const chainId = await provider.request({ + method: 'eth_chainId', + }) + return Number(chainId) + }, + async getProvider() { + if (!walletProvider) { + // Unwrapping import for Vite compatibility. + // See: https://github.com/vitejs/vite/issues/9703 + const CoinbaseWalletSDK = await (async () => { + const { default: SDK } = await import('cbw-sdk') + if (typeof SDK !== 'function' && typeof SDK.default === 'function') + return SDK.default + return SDK as unknown as typeof SDK.default + })() + + sdk = new CoinbaseWalletSDK({ ...parameters, reloadOnDisconnect }) + + // Force types to retrieve private `walletExtension` method from the Coinbase Wallet SDK. + const walletExtensionChainId = ( + sdk as unknown as { + get walletExtension(): { getChainId(): number } | undefined + } + ).walletExtension?.getChainId() + + const chain = + config.chains.find((chain) => + parameters.chainId + ? chain.id === parameters.chainId + : chain.id === walletExtensionChainId, + ) || config.chains[0] + const chainId = parameters.chainId || chain?.id + const jsonRpcUrl = + parameters.jsonRpcUrl || chain?.rpcUrls.default.http[0] + + walletProvider = sdk.makeWeb3Provider(jsonRpcUrl, chainId) + } + + return walletProvider + }, + async isAuthorized() { + try { + const accounts = await this.getAccounts() + return !!accounts.length + } catch { + return false + } + }, + async switchChain({ addEthereumChainParameter, chainId }) { + const chain = config.chains.find((chain) => chain.id === chainId) + if (!chain) throw new SwitchChainError(new ChainNotConfiguredError()) + + const provider = await this.getProvider() + + try { + await provider.request({ + method: 'wallet_switchEthereumChain', + params: [{ chainId: numberToHex(chain.id) }], + }) + return chain + } catch (error) { + // Indicates chain is not added to provider + if ((error as ProviderRpcError).code === 4902) { + try { + let blockExplorerUrls: string[] | undefined + if (addEthereumChainParameter?.blockExplorerUrls) + blockExplorerUrls = addEthereumChainParameter.blockExplorerUrls + else + blockExplorerUrls = chain.blockExplorers?.default.url + ? [chain.blockExplorers?.default.url] + : [] + + let rpcUrls: readonly string[] + if (addEthereumChainParameter?.rpcUrls?.length) + rpcUrls = addEthereumChainParameter.rpcUrls + else rpcUrls = [chain.rpcUrls.default?.http[0] ?? ''] + + const addEthereumChain = { + blockExplorerUrls, + chainId: numberToHex(chainId), + chainName: addEthereumChainParameter?.chainName ?? chain.name, + iconUrls: addEthereumChainParameter?.iconUrls, + nativeCurrency: + addEthereumChainParameter?.nativeCurrency ?? + chain.nativeCurrency, + rpcUrls, + } satisfies AddEthereumChainParameter + + await provider.request({ + method: 'wallet_addEthereumChain', + params: [addEthereumChain], + }) + + return chain + } catch (error) { + throw new UserRejectedRequestError(error as Error) + } + } + + throw new SwitchChainError(error as Error) + } + }, + onAccountsChanged(accounts) { + if (accounts.length === 0) this.onDisconnect() + else + config.emitter.emit('change', { + accounts: accounts.map((x) => getAddress(x)), + }) + }, + onChainChanged(chain) { + const chainId = Number(chain) + config.emitter.emit('change', { chainId }) + }, + async onDisconnect(_error) { + config.emitter.emit('disconnect') + + const provider = await this.getProvider() + if (accountsChanged) { + provider.removeListener('accountsChanged', accountsChanged) + accountsChanged = undefined + } + if (chainChanged) { + provider.removeListener('chainChanged', chainChanged) + chainChanged = undefined + } + if (disconnect) { + provider.removeListener('disconnect', disconnect) + disconnect = undefined + } + }, + })) +} diff --git a/packages/connectors/src/exports/index.test.ts b/packages/connectors/src/exports/index.test.ts new file mode 100644 index 0000000000..bcf100cb61 --- /dev/null +++ b/packages/connectors/src/exports/index.test.ts @@ -0,0 +1,17 @@ +import { expect, test } from 'vitest' + +import * as connectors from './index.js' + +test('exports', () => { + expect(Object.keys(connectors)).toMatchInlineSnapshot(` + [ + "injected", + "mock", + "coinbaseWallet", + "metaMask", + "safe", + "walletConnect", + "version", + ] + `) +}) diff --git a/packages/connectors/src/exports/index.ts b/packages/connectors/src/exports/index.ts new file mode 100644 index 0000000000..bac0975956 --- /dev/null +++ b/packages/connectors/src/exports/index.ts @@ -0,0 +1,23 @@ +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { + type InjectedParameters, + injected, + type MockParameters, + mock, +} from '@wagmi/core' + +export { + type CoinbaseWalletParameters, + coinbaseWallet, +} from '../coinbaseWallet.js' + +export { type MetaMaskParameters, metaMask } from '../metaMask.js' + +export { type SafeParameters, safe } from '../safe.js' + +export { + type WalletConnectParameters, + walletConnect, +} from '../walletConnect.js' + +export { version } from '../version.js' diff --git a/packages/connectors/src/metaMask.test.ts b/packages/connectors/src/metaMask.test.ts new file mode 100644 index 0000000000..40c3f0f7f9 --- /dev/null +++ b/packages/connectors/src/metaMask.test.ts @@ -0,0 +1,10 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { metaMask } from './metaMask.js' + +test('setup', () => { + const connectorFn = metaMask() + const connector = config._internal.connectors.setup(connectorFn) + expect(connector.name).toEqual('MetaMask') +}) diff --git a/packages/connectors/src/metaMask.ts b/packages/connectors/src/metaMask.ts new file mode 100644 index 0000000000..02ab4c3fb3 --- /dev/null +++ b/packages/connectors/src/metaMask.ts @@ -0,0 +1,505 @@ +import type { + MetaMaskSDK, + MetaMaskSDKOptions, + RPC_URLS_MAP, + SDKProvider, +} from '@metamask/sdk' +import { + ChainNotConfiguredError, + type Connector, + ProviderNotFoundError, + createConnector, + extractRpcUrls, +} from '@wagmi/core' +import type { + Compute, + ExactPartial, + OneOf, + RemoveUndefined, + UnionCompute, +} from '@wagmi/core/internal' +import { + type AddEthereumChainParameter, + type Address, + type Hex, + type ProviderConnectInfo, + type ProviderRpcError, + ResourceUnavailableRpcError, + type RpcError, + SwitchChainError, + UserRejectedRequestError, + getAddress, + hexToNumber, + numberToHex, + withRetry, + withTimeout, +} from 'viem' + +export type MetaMaskParameters = UnionCompute< + WagmiMetaMaskSDKOptions & + OneOf< + | { + /* Shortcut to connect and sign a message */ + connectAndSign?: string | undefined + } + | { + // TODO: Strongly type `method` and `params` + /* Allow `connectWith` any rpc method */ + connectWith?: { method: string; params: unknown[] } | undefined + } + > +> + +type WagmiMetaMaskSDKOptions = Compute< + ExactPartial< + Omit< + MetaMaskSDKOptions, + | '_source' + | 'forceDeleteProvider' + | 'forceInjectProvider' + | 'injectProvider' + | 'useDeeplink' + | 'readonlyRPCMap' + > + > & { + /** @deprecated */ + forceDeleteProvider?: MetaMaskSDKOptions['forceDeleteProvider'] + /** @deprecated */ + forceInjectProvider?: MetaMaskSDKOptions['forceInjectProvider'] + /** @deprecated */ + injectProvider?: MetaMaskSDKOptions['injectProvider'] + /** @deprecated */ + useDeeplink?: MetaMaskSDKOptions['useDeeplink'] + } +> + +metaMask.type = 'metaMask' as const +export function metaMask(parameters: MetaMaskParameters = {}) { + type Provider = SDKProvider + type Properties = { + onConnect(connectInfo: ProviderConnectInfo): void + onDisplayUri(uri: string): void + } + type Listener = Parameters[1] + + let sdk: MetaMaskSDK + let provider: Provider | undefined + let providerPromise: Promise + + let accountsChanged: Connector['onAccountsChanged'] | undefined + let chainChanged: Connector['onChainChanged'] | undefined + let connect: Connector['onConnect'] | undefined + let displayUri: ((uri: string) => void) | undefined + let disconnect: Connector['onDisconnect'] | undefined + + return createConnector((config) => ({ + id: 'metaMaskSDK', + name: 'MetaMask', + rdns: ['io.metamask', 'io.metamask.mobile'], + type: metaMask.type, + async setup() { + const provider = await this.getProvider() + if (provider?.on) { + if (!connect) { + connect = this.onConnect.bind(this) + provider.on('connect', connect as Listener) + } + + // We shouldn't need to listen for `'accountsChanged'` here since the `'connect'` event should suffice (and wallet shouldn't be connected yet). + // Some wallets, like MetaMask, do not implement the `'connect'` event and overload `'accountsChanged'` instead. + if (!accountsChanged) { + accountsChanged = this.onAccountsChanged.bind(this) + provider.on('accountsChanged', accountsChanged as Listener) + } + } + }, + async connect({ chainId, isReconnecting } = {}) { + const provider = await this.getProvider() + if (!displayUri) { + displayUri = this.onDisplayUri + provider.on('display_uri', displayUri as Listener) + } + + let accounts: readonly Address[] = [] + if (isReconnecting) accounts = await this.getAccounts().catch(() => []) + + try { + let signResponse: string | undefined + let connectWithResponse: unknown | undefined + if (!accounts?.length) { + if (parameters.connectAndSign || parameters.connectWith) { + if (parameters.connectAndSign) + signResponse = await sdk.connectAndSign({ + msg: parameters.connectAndSign, + }) + else if (parameters.connectWith) + connectWithResponse = await sdk.connectWith({ + method: parameters.connectWith.method, + params: parameters.connectWith.params, + }) + + accounts = await this.getAccounts() + } else { + const requestedAccounts = (await sdk.connect()) as string[] + accounts = requestedAccounts.map((x) => getAddress(x)) + } + } + // Switch to chain if provided + let currentChainId = (await this.getChainId()) as number + if (chainId && currentChainId !== chainId) { + const chain = await this.switchChain!({ chainId }).catch((error) => { + if (error.code === UserRejectedRequestError.code) throw error + return { id: currentChainId } + }) + currentChainId = chain?.id ?? currentChainId + } + + if (displayUri) { + provider.removeListener('display_uri', displayUri) + displayUri = undefined + } + + if (signResponse) + provider.emit('connectAndSign', { + accounts, + chainId: currentChainId, + signResponse, + }) + else if (connectWithResponse) + provider.emit('connectWith', { + accounts, + chainId: currentChainId, + connectWithResponse, + }) + + // Manage EIP-1193 event listeners + // https://eips.ethereum.org/EIPS/eip-1193#events + if (connect) { + provider.removeListener('connect', connect) + connect = undefined + } + if (!accountsChanged) { + accountsChanged = this.onAccountsChanged.bind(this) + provider.on('accountsChanged', accountsChanged as Listener) + } + if (!chainChanged) { + chainChanged = this.onChainChanged.bind(this) + provider.on('chainChanged', chainChanged as Listener) + } + if (!disconnect) { + disconnect = this.onDisconnect.bind(this) + provider.on('disconnect', disconnect as Listener) + } + + return { accounts, chainId: currentChainId } + } catch (err) { + const error = err as RpcError + if (error.code === UserRejectedRequestError.code) + throw new UserRejectedRequestError(error) + if (error.code === ResourceUnavailableRpcError.code) + throw new ResourceUnavailableRpcError(error) + throw error + } + }, + async disconnect() { + const provider = await this.getProvider() + + // Manage EIP-1193 event listeners + if (chainChanged) { + provider.removeListener('chainChanged', chainChanged) + chainChanged = undefined + } + if (disconnect) { + provider.removeListener('disconnect', disconnect) + disconnect = undefined + } + if (!connect) { + connect = this.onConnect.bind(this) + provider.on('connect', connect as Listener) + } + + await sdk.terminate() + }, + async getAccounts() { + const provider = await this.getProvider() + const accounts = (await provider.request({ + method: 'eth_accounts', + })) as string[] + return accounts.map((x) => getAddress(x)) + }, + async getChainId() { + const provider = await this.getProvider() + const chainId = + provider.getChainId() || + (await provider?.request({ method: 'eth_chainId' })) + return Number(chainId) + }, + async getProvider() { + async function initProvider() { + // Unwrapping import for Vite compatibility. + // See: https://github.com/vitejs/vite/issues/9703 + const MetaMaskSDK = await (async () => { + const { default: SDK } = await import('@metamask/sdk') + if (typeof SDK !== 'function' && typeof SDK.default === 'function') + return SDK.default + return SDK as unknown as typeof SDK.default + })() + + const readonlyRPCMap: RPC_URLS_MAP = {} + for (const chain of config.chains) + readonlyRPCMap[numberToHex(chain.id)] = extractRpcUrls({ + chain, + transports: config.transports, + })?.[0] + + sdk = new MetaMaskSDK({ + _source: 'wagmi', + forceDeleteProvider: false, + forceInjectProvider: false, + injectProvider: false, + // Workaround cast since MetaMask SDK does not support `'exactOptionalPropertyTypes'` + ...(parameters as RemoveUndefined), + readonlyRPCMap, + dappMetadata: { + ...parameters.dappMetadata, + // Test if name and url are set AND not empty + name: parameters.dappMetadata?.name + ? parameters.dappMetadata?.name + : 'wagmi', + url: parameters.dappMetadata?.url + ? parameters.dappMetadata?.url + : typeof window !== 'undefined' + ? window.location.origin + : 'https://wagmi.sh', + }, + useDeeplink: parameters.useDeeplink ?? true, + }) + const result = await sdk.init() + // On initial load, sometimes `sdk.getProvider` does not return provider. + // https://github.com/wevm/wagmi/issues/4367 + // Use result of `init` call if available. + const provider = (() => { + if (result?.activeProvider) return result.activeProvider + return sdk.getProvider() + })() + if (!provider) throw new ProviderNotFoundError() + return provider + } + + if (!provider) { + if (!providerPromise) providerPromise = initProvider() + provider = await providerPromise + } + return provider! + }, + async isAuthorized() { + try { + // MetaMask mobile provider sometimes fails to immediately resolve + // JSON-RPC requests on page load + const timeout = 200 + const accounts = await withRetry( + () => withTimeout(() => this.getAccounts(), { timeout }), + { + delay: timeout + 1, + retryCount: 3, + }, + ) + return !!accounts.length + } catch { + return false + } + }, + async switchChain({ addEthereumChainParameter, chainId }) { + const provider = await this.getProvider() + + const chain = config.chains.find((x) => x.id === chainId) + if (!chain) throw new SwitchChainError(new ChainNotConfiguredError()) + + try { + await provider.request({ + method: 'wallet_switchEthereumChain', + params: [{ chainId: numberToHex(chainId) }], + }) + + // During `'wallet_switchEthereumChain'`, MetaMask makes a `'net_version'` RPC call to the target chain. + // If this request fails, MetaMask does not emit the `'chainChanged'` event, but will still switch the chain. + // To counter this behavior, we request and emit the current chain ID to confirm the chain switch either via + // this callback or an externally emitted `'chainChanged'` event. + // https://github.com/MetaMask/metamask-extension/issues/24247 + await waitForChainIdToSync() + await sendAndWaitForChangeEvent(chainId) + + return chain + } catch (err) { + const error = err as RpcError + + if (error.code === UserRejectedRequestError.code) + throw new UserRejectedRequestError(error) + + // Indicates chain is not added to provider + if ( + error.code === 4902 || + // Unwrapping for MetaMask Mobile + // https://github.com/MetaMask/metamask-mobile/issues/2944#issuecomment-976988719 + (error as ProviderRpcError<{ originalError?: { code: number } }>) + ?.data?.originalError?.code === 4902 + ) { + try { + await provider.request({ + method: 'wallet_addEthereumChain', + params: [ + { + blockExplorerUrls: (() => { + const { default: blockExplorer, ...blockExplorers } = + chain.blockExplorers ?? {} + if (addEthereumChainParameter?.blockExplorerUrls) + return addEthereumChainParameter.blockExplorerUrls + if (blockExplorer) + return [ + blockExplorer.url, + ...Object.values(blockExplorers).map((x) => x.url), + ] + return + })(), + chainId: numberToHex(chainId), + chainName: addEthereumChainParameter?.chainName ?? chain.name, + iconUrls: addEthereumChainParameter?.iconUrls, + nativeCurrency: + addEthereumChainParameter?.nativeCurrency ?? + chain.nativeCurrency, + rpcUrls: (() => { + if (addEthereumChainParameter?.rpcUrls?.length) + return addEthereumChainParameter.rpcUrls + return [chain.rpcUrls.default?.http[0] ?? ''] + })(), + } satisfies AddEthereumChainParameter, + ], + }) + + await waitForChainIdToSync() + await sendAndWaitForChangeEvent(chainId) + + return chain + } catch (err) { + const error = err as RpcError + if (error.code === UserRejectedRequestError.code) + throw new UserRejectedRequestError(error) + throw new SwitchChainError(error) + } + } + + throw new SwitchChainError(error) + } + + async function waitForChainIdToSync() { + // On mobile, there is a race condition between the result of `'wallet_addEthereumChain'` and `'eth_chainId'`. + // To avoid this, we wait for `'eth_chainId'` to return the expected chain ID with a retry loop. + await withRetry( + async () => { + const value = hexToNumber( + // `'eth_chainId'` is cached by the MetaMask SDK side to avoid unnecessary deeplinks + (await provider.request({ method: 'eth_chainId' })) as Hex, + ) + // `value` doesn't match expected `chainId`, throw to trigger retry + if (value !== chainId) + throw new Error('User rejected switch after adding network.') + return value + }, + { + delay: 50, + retryCount: 20, // android device encryption is slower + }, + ) + } + + async function sendAndWaitForChangeEvent(chainId: number) { + await new Promise((resolve) => { + const listener = ((data) => { + if ('chainId' in data && data.chainId === chainId) { + config.emitter.off('change', listener) + resolve() + } + }) satisfies Parameters[1] + config.emitter.on('change', listener) + config.emitter.emit('change', { chainId }) + }) + } + }, + async onAccountsChanged(accounts) { + // Disconnect if there are no accounts + if (accounts.length === 0) { + // ... and using browser extension + if (sdk.isExtensionActive()) this.onDisconnect() + // FIXME(upstream): Mobile app sometimes emits invalid `accountsChanged` event with empty accounts array + else return + } + // Connect if emitter is listening for connect event (e.g. is disconnected and connects through wallet interface) + else if (config.emitter.listenerCount('connect')) { + const chainId = (await this.getChainId()).toString() + this.onConnect({ chainId }) + } + // Regular change event + else + config.emitter.emit('change', { + accounts: accounts.map((x) => getAddress(x)), + }) + }, + onChainChanged(chain) { + const chainId = Number(chain) + config.emitter.emit('change', { chainId }) + }, + async onConnect(connectInfo) { + const accounts = await this.getAccounts() + if (accounts.length === 0) return + + const chainId = Number(connectInfo.chainId) + config.emitter.emit('connect', { accounts, chainId }) + + const provider = await this.getProvider() + if (connect) { + provider.removeListener('connect', connect) + connect = undefined + } + if (!accountsChanged) { + accountsChanged = this.onAccountsChanged.bind(this) + provider.on('accountsChanged', accountsChanged as Listener) + } + if (!chainChanged) { + chainChanged = this.onChainChanged.bind(this) + provider.on('chainChanged', chainChanged as Listener) + } + if (!disconnect) { + disconnect = this.onDisconnect.bind(this) + provider.on('disconnect', disconnect as Listener) + } + }, + async onDisconnect(error) { + const provider = await this.getProvider() + + // If MetaMask emits a `code: 1013` error, wait for reconnection before disconnecting + // https://github.com/MetaMask/providers/pull/120 + if (error && (error as RpcError<1013>).code === 1013) { + if (provider && !!(await this.getAccounts()).length) return + } + + config.emitter.emit('disconnect') + + // Manage EIP-1193 event listeners + if (chainChanged) { + provider.removeListener('chainChanged', chainChanged) + chainChanged = undefined + } + if (disconnect) { + provider.removeListener('disconnect', disconnect) + disconnect = undefined + } + if (!connect) { + connect = this.onConnect.bind(this) + provider.on('connect', connect as Listener) + } + }, + onDisplayUri(uri) { + config.emitter.emit('message', { type: 'display_uri', data: uri }) + }, + })) +} diff --git a/packages/connectors/src/safe.test.ts b/packages/connectors/src/safe.test.ts new file mode 100644 index 0000000000..0571115f36 --- /dev/null +++ b/packages/connectors/src/safe.test.ts @@ -0,0 +1,23 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { safe } from './safe.js' + +/* + * To manually test the Safe connector: + * + * 1. Run the wagmi playground app (`pnpm dev`) + * 2. Add a custom Safe App with App URL set to `http://localhost:5173` (make sure there is a `manifest.json` file served by the playground) + * 3. Open the playground app at `https://app.safe.global/eth:0x4557B18E779944BFE9d78A672452331C186a9f48/apps?appUrl=http%3A%2F%2Flocalhost%3A5173` + * + * See https://docs.gnosis-safe.io/learn/safe-tools/sdks/safe-apps/releasing-your-safe-app for more info. + */ + +test('setup', () => { + const connectorFn = safe({ + allowedDomains: [/gnosis-safe.io$/, /app.safe.global$/], + debug: false, + }) + const connector = config._internal.connectors.setup(connectorFn) + expect(connector.name).toEqual('Safe') +}) diff --git a/packages/connectors/src/safe.ts b/packages/connectors/src/safe.ts new file mode 100644 index 0000000000..13153e106f --- /dev/null +++ b/packages/connectors/src/safe.ts @@ -0,0 +1,145 @@ +import type { SafeAppProvider } from '@safe-global/safe-apps-provider' +import type { Opts } from '@safe-global/safe-apps-sdk' +import { + type Connector, + ProviderNotFoundError, + createConnector, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { getAddress, withTimeout } from 'viem' + +export type SafeParameters = Compute< + Opts & { + /** + * Connector automatically connects when used as Safe App. + * + * This flag simulates the disconnect behavior by keeping track of connection status in storage + * and only autoconnecting when previously connected by user action (e.g. explicitly choosing to connect). + * + * @default false + */ + shimDisconnect?: boolean | undefined + /** + * Timeout in milliseconds for `getInfo` (from the Safe SDK) to resolve. + * + * `getInfo` does not resolve when not used in Safe App iFrame. This allows the connector to force a timeout. + * @default 10 + */ + unstable_getInfoTimeout?: number | undefined + } +> + +safe.type = 'safe' as const +export function safe(parameters: SafeParameters = {}) { + const { shimDisconnect = false } = parameters + + type Provider = SafeAppProvider | undefined + type Properties = Record + type StorageItem = { 'safe.disconnected': true } + + let provider_: Provider | undefined + + let disconnect: Connector['onDisconnect'] | undefined + + return createConnector((config) => ({ + id: 'safe', + name: 'Safe', + type: safe.type, + async connect() { + const provider = await this.getProvider() + if (!provider) throw new ProviderNotFoundError() + + const accounts = await this.getAccounts() + const chainId = await this.getChainId() + + if (!disconnect) { + disconnect = this.onDisconnect.bind(this) + provider.on('disconnect', disconnect) + } + + // Remove disconnected shim if it exists + if (shimDisconnect) await config.storage?.removeItem('safe.disconnected') + + return { accounts, chainId } + }, + async disconnect() { + const provider = await this.getProvider() + if (!provider) throw new ProviderNotFoundError() + + if (disconnect) { + provider.removeListener('disconnect', disconnect) + disconnect = undefined + } + + // Add shim signalling connector is disconnected + if (shimDisconnect) + await config.storage?.setItem('safe.disconnected', true) + }, + async getAccounts() { + const provider = await this.getProvider() + if (!provider) throw new ProviderNotFoundError() + return (await provider.request({ method: 'eth_accounts' })).map( + getAddress, + ) + }, + async getProvider() { + // Only allowed in iframe context + const isIframe = + typeof window !== 'undefined' && window?.parent !== window + if (!isIframe) return + + if (!provider_) { + const { default: SDK } = await import('@safe-global/safe-apps-sdk') + const sdk = new SDK(parameters) + + // `getInfo` hangs when not used in Safe App iFrame + // https://github.com/safe-global/safe-apps-sdk/issues/263#issuecomment-1029835840 + const safe = await withTimeout(() => sdk.safe.getInfo(), { + timeout: parameters.unstable_getInfoTimeout ?? 10, + }) + if (!safe) throw new Error('Could not load Safe information') + // Unwrapping import for Vite compatibility. + // See: https://github.com/vitejs/vite/issues/9703 + const SafeAppProvider = await (async () => { + const Provider = await import('@safe-global/safe-apps-provider') + if ( + typeof Provider.SafeAppProvider !== 'function' && + typeof Provider.default.SafeAppProvider === 'function' + ) + return Provider.default.SafeAppProvider + return Provider.SafeAppProvider + })() + provider_ = new SafeAppProvider(safe, sdk) + } + return provider_ + }, + async getChainId() { + const provider = await this.getProvider() + if (!provider) throw new ProviderNotFoundError() + return Number(provider.chainId) + }, + async isAuthorized() { + try { + const isDisconnected = + shimDisconnect && + // If shim exists in storage, connector is disconnected + (await config.storage?.getItem('safe.disconnected')) + if (isDisconnected) return false + + const accounts = await this.getAccounts() + return !!accounts.length + } catch { + return false + } + }, + onAccountsChanged() { + // Not relevant for Safe because changing account requires app reload. + }, + onChainChanged() { + // Not relevant for Safe because Safe smart contract wallets only exist on single chain. + }, + onDisconnect() { + config.emitter.emit('disconnect') + }, + })) +} diff --git a/packages/connectors/src/version.ts b/packages/connectors/src/version.ts new file mode 100644 index 0000000000..11f81d1c34 --- /dev/null +++ b/packages/connectors/src/version.ts @@ -0,0 +1 @@ +export const version = '5.8.3' diff --git a/packages/connectors/src/walletConnect.test.ts b/packages/connectors/src/walletConnect.test.ts new file mode 100644 index 0000000000..4e8a74ebfe --- /dev/null +++ b/packages/connectors/src/walletConnect.test.ts @@ -0,0 +1,67 @@ +import { config, walletConnectProjectId } from '@wagmi/test' +import { http, HttpResponse } from 'msw' +import { setupServer } from 'msw/node' +import { + afterAll, + afterEach, + beforeAll, + expect, + expectTypeOf, + test, + vi, +} from 'vitest' + +import { walletConnect } from './walletConnect.js' + +const handlers = [ + http.get('https://relay.walletconnect.com', async () => + HttpResponse.json( + { + topic: '222781e3-3fad-4184-acde-077796bf0d3d', + type: 'sub', + payload: '', + silent: true, + }, + { status: 200 }, + ), + ), +] + +const server = setupServer(...handlers) + +beforeAll(() => { + server.listen({ + onUnhandledRequest: 'warn', + }) + + const matchMedia = vi.fn().mockImplementation((query) => { + return { + matches: false, + media: query, + onchange: null, + addListener: vi.fn(), // deprecated + removeListener: vi.fn(), // deprecated + addEventListener: vi.fn(), + removeEventListener: vi.fn(), + dispatchEvent: vi.fn(), + } + }) + vi.stubGlobal('matchMedia', matchMedia) +}) + +afterEach(() => server.resetHandlers()) + +afterAll(() => server.close()) + +test('setup', () => { + const connectorFn = walletConnect({ projectId: walletConnectProjectId }) + const connector = config._internal.connectors.setup(connectorFn) + expect(connector.name).toEqual('WalletConnect') + + type ConnectFnParameters = NonNullable< + Parameters<(typeof connector)['connect']>[0] + > + expectTypeOf().toMatchTypeOf< + string | undefined + >() +}) diff --git a/packages/connectors/src/walletConnect.ts b/packages/connectors/src/walletConnect.ts new file mode 100644 index 0000000000..fc4f794c1f --- /dev/null +++ b/packages/connectors/src/walletConnect.ts @@ -0,0 +1,468 @@ +import { + ChainNotConfiguredError, + type Connector, + ProviderNotFoundError, + createConnector, + extractRpcUrls, +} from '@wagmi/core' +import type { Compute, ExactPartial, Omit } from '@wagmi/core/internal' +import type { EthereumProvider } from '@walletconnect/ethereum-provider' +import { + type AddEthereumChainParameter, + type Address, + type ProviderConnectInfo, + type ProviderRpcError, + type RpcError, + SwitchChainError, + UserRejectedRequestError, + getAddress, + numberToHex, +} from 'viem' + +type WalletConnectConnector = Connector & { + onDisplayUri(uri: string): void + onSessionDelete(data: { topic: string }): void +} + +type EthereumProviderOptions = Parameters<(typeof EthereumProvider)['init']>[0] + +export type WalletConnectParameters = Compute< + { + /** + * If a new chain is added to a previously existing configured connector `chains`, this flag + * will determine if that chain should be considered as stale. A stale chain is a chain that + * WalletConnect has yet to establish a relationship with (e.g. the user has not approved or + * rejected the chain). + * + * This flag mainly affects the behavior when a wallet does not support dynamic chain authorization + * with WalletConnect v2. + * + * If `true` (default), the new chain will be treated as a stale chain. If the user + * has yet to establish a relationship (approved/rejected) with this chain in their WalletConnect + * session, the connector will disconnect upon the dapp auto-connecting, and the user will have to + * reconnect to the dapp (revalidate the chain) in order to approve the newly added chain. + * This is the default behavior to avoid an unexpected error upon switching chains which may + * be a confusing user experience (e.g. the user will not know they have to reconnect + * unless the dapp handles these types of errors). + * + * If `false`, the new chain will be treated as a potentially valid chain. This means that if the user + * has yet to establish a relationship with the chain in their WalletConnect session, wagmi will successfully + * auto-connect the user. This comes with the trade-off that the connector will throw an error + * when attempting to switch to the unapproved chain if the wallet does not support dynamic session updates. + * This may be useful in cases where a dapp constantly + * modifies their configured chains, and they do not want to disconnect the user upon + * auto-connecting. If the user decides to switch to the unapproved chain, it is important that the + * dapp handles this error and prompts the user to reconnect to the dapp in order to approve + * the newly added chain. + * + * @default true + */ + isNewChainsStale?: boolean + } & Omit< + EthereumProviderOptions, + | 'chains' + | 'events' + | 'optionalChains' + | 'optionalEvents' + | 'optionalMethods' + | 'methods' + | 'rpcMap' + | 'showQrModal' + > & + ExactPartial> +> + +walletConnect.type = 'walletConnect' as const +export function walletConnect(parameters: WalletConnectParameters) { + const isNewChainsStale = parameters.isNewChainsStale ?? true + + type Provider = Awaited> + type Properties = { + connect(parameters?: { + chainId?: number | undefined + isReconnecting?: boolean | undefined + pairingTopic?: string | undefined + }): Promise<{ + accounts: readonly Address[] + chainId: number + }> + getNamespaceChainsIds(): number[] + getRequestedChainsIds(): Promise + isChainsStale(): Promise + onConnect(connectInfo: ProviderConnectInfo): void + onDisplayUri(uri: string): void + onSessionDelete(data: { topic: string }): void + setRequestedChainsIds(chains: number[]): void + requestedChainsStorageKey: `${string}.requestedChains` + } + type StorageItem = { + [_ in Properties['requestedChainsStorageKey']]: number[] + } + + let provider_: Provider | undefined + let providerPromise: Promise + const NAMESPACE = 'eip155' + + let accountsChanged: WalletConnectConnector['onAccountsChanged'] | undefined + let chainChanged: WalletConnectConnector['onChainChanged'] | undefined + let connect: WalletConnectConnector['onConnect'] | undefined + let displayUri: WalletConnectConnector['onDisplayUri'] | undefined + let sessionDelete: WalletConnectConnector['onSessionDelete'] | undefined + let disconnect: WalletConnectConnector['onDisconnect'] | undefined + + return createConnector((config) => ({ + id: 'walletConnect', + name: 'WalletConnect', + type: walletConnect.type, + async setup() { + const provider = await this.getProvider().catch(() => null) + if (!provider) return + if (!connect) { + connect = this.onConnect.bind(this) + provider.on('connect', connect) + } + if (!sessionDelete) { + sessionDelete = this.onSessionDelete.bind(this) + provider.on('session_delete', sessionDelete) + } + }, + async connect({ chainId, ...rest } = {}) { + try { + const provider = await this.getProvider() + if (!provider) throw new ProviderNotFoundError() + if (!displayUri) { + displayUri = this.onDisplayUri + provider.on('display_uri', displayUri) + } + + let targetChainId = chainId + if (!targetChainId) { + const state = (await config.storage?.getItem('state')) ?? {} + const isChainSupported = config.chains.some( + (x) => x.id === state.chainId, + ) + if (isChainSupported) targetChainId = state.chainId + else targetChainId = config.chains[0]?.id + } + if (!targetChainId) throw new Error('No chains found on connector.') + + const isChainsStale = await this.isChainsStale() + // If there is an active session with stale chains, disconnect current session. + if (provider.session && isChainsStale) await provider.disconnect() + + // If there isn't an active session or chains are stale, connect. + if (!provider.session || isChainsStale) { + const optionalChains = config.chains + .filter((chain) => chain.id !== targetChainId) + .map((optionalChain) => optionalChain.id) + await provider.connect({ + optionalChains: [targetChainId, ...optionalChains], + ...('pairingTopic' in rest + ? { pairingTopic: rest.pairingTopic } + : {}), + }) + + this.setRequestedChainsIds(config.chains.map((x) => x.id)) + } + + // If session exists and chains are authorized, enable provider for required chain + const accounts = (await provider.enable()).map((x) => getAddress(x)) + const currentChainId = await this.getChainId() + + if (displayUri) { + provider.removeListener('display_uri', displayUri) + displayUri = undefined + } + if (connect) { + provider.removeListener('connect', connect) + connect = undefined + } + if (!accountsChanged) { + accountsChanged = this.onAccountsChanged.bind(this) + provider.on('accountsChanged', accountsChanged) + } + if (!chainChanged) { + chainChanged = this.onChainChanged.bind(this) + provider.on('chainChanged', chainChanged) + } + if (!disconnect) { + disconnect = this.onDisconnect.bind(this) + provider.on('disconnect', disconnect) + } + if (!sessionDelete) { + sessionDelete = this.onSessionDelete.bind(this) + provider.on('session_delete', sessionDelete) + } + + return { accounts, chainId: currentChainId } + } catch (error) { + if ( + /(user rejected|connection request reset)/i.test( + (error as ProviderRpcError)?.message, + ) + ) { + throw new UserRejectedRequestError(error as Error) + } + throw error + } + }, + async disconnect() { + const provider = await this.getProvider() + try { + await provider?.disconnect() + } catch (error) { + if (!/No matching key/i.test((error as Error).message)) throw error + } finally { + if (chainChanged) { + provider?.removeListener('chainChanged', chainChanged) + chainChanged = undefined + } + if (disconnect) { + provider?.removeListener('disconnect', disconnect) + disconnect = undefined + } + if (!connect) { + connect = this.onConnect.bind(this) + provider?.on('connect', connect) + } + if (accountsChanged) { + provider?.removeListener('accountsChanged', accountsChanged) + accountsChanged = undefined + } + if (sessionDelete) { + provider?.removeListener('session_delete', sessionDelete) + sessionDelete = undefined + } + + this.setRequestedChainsIds([]) + } + }, + async getAccounts() { + const provider = await this.getProvider() + return provider.accounts.map((x) => getAddress(x)) + }, + async getProvider({ chainId } = {}) { + async function initProvider() { + const optionalChains = config.chains.map((x) => x.id) as [number] + if (!optionalChains.length) return + const { EthereumProvider } = await import( + '@walletconnect/ethereum-provider' + ) + return await EthereumProvider.init({ + ...parameters, + disableProviderPing: true, + optionalChains, + projectId: parameters.projectId, + rpcMap: Object.fromEntries( + config.chains.map((chain) => { + const [url] = extractRpcUrls({ + chain, + transports: config.transports, + }) + return [chain.id, url] + }), + ), + showQrModal: parameters.showQrModal ?? true, + }) + } + + if (!provider_) { + if (!providerPromise) providerPromise = initProvider() + provider_ = await providerPromise + provider_?.events.setMaxListeners(Number.POSITIVE_INFINITY) + } + if (chainId) await this.switchChain?.({ chainId }) + return provider_! + }, + async getChainId() { + const provider = await this.getProvider() + return provider.chainId + }, + async isAuthorized() { + try { + const [accounts, provider] = await Promise.all([ + this.getAccounts(), + this.getProvider(), + ]) + + // If an account does not exist on the session, then the connector is unauthorized. + if (!accounts.length) return false + + // If the chains are stale on the session, then the connector is unauthorized. + const isChainsStale = await this.isChainsStale() + if (isChainsStale && provider.session) { + await provider.disconnect().catch(() => {}) + return false + } + return true + } catch { + return false + } + }, + async switchChain({ addEthereumChainParameter, chainId }) { + const provider = await this.getProvider() + if (!provider) throw new ProviderNotFoundError() + + const chain = config.chains.find((x) => x.id === chainId) + if (!chain) throw new SwitchChainError(new ChainNotConfiguredError()) + + try { + await Promise.all([ + new Promise((resolve) => { + const listener = ({ + chainId: currentChainId, + }: { chainId?: number | undefined }) => { + if (currentChainId === chainId) { + config.emitter.off('change', listener) + resolve() + } + } + config.emitter.on('change', listener) + }), + provider.request({ + method: 'wallet_switchEthereumChain', + params: [{ chainId: numberToHex(chainId) }], + }), + ]) + + const requestedChains = await this.getRequestedChainsIds() + this.setRequestedChainsIds([...requestedChains, chainId]) + + return chain + } catch (err) { + const error = err as RpcError + + if (/(user rejected)/i.test(error.message)) + throw new UserRejectedRequestError(error) + + // Indicates chain is not added to provider + try { + let blockExplorerUrls: string[] | undefined + if (addEthereumChainParameter?.blockExplorerUrls) + blockExplorerUrls = addEthereumChainParameter.blockExplorerUrls + else + blockExplorerUrls = chain.blockExplorers?.default.url + ? [chain.blockExplorers?.default.url] + : [] + + let rpcUrls: readonly string[] + if (addEthereumChainParameter?.rpcUrls?.length) + rpcUrls = addEthereumChainParameter.rpcUrls + else rpcUrls = [...chain.rpcUrls.default.http] + + const addEthereumChain = { + blockExplorerUrls, + chainId: numberToHex(chainId), + chainName: addEthereumChainParameter?.chainName ?? chain.name, + iconUrls: addEthereumChainParameter?.iconUrls, + nativeCurrency: + addEthereumChainParameter?.nativeCurrency ?? chain.nativeCurrency, + rpcUrls, + } satisfies AddEthereumChainParameter + + await provider.request({ + method: 'wallet_addEthereumChain', + params: [addEthereumChain], + }) + + const requestedChains = await this.getRequestedChainsIds() + this.setRequestedChainsIds([...requestedChains, chainId]) + return chain + } catch (error) { + throw new UserRejectedRequestError(error as Error) + } + } + }, + onAccountsChanged(accounts) { + if (accounts.length === 0) this.onDisconnect() + else + config.emitter.emit('change', { + accounts: accounts.map((x) => getAddress(x)), + }) + }, + onChainChanged(chain) { + const chainId = Number(chain) + config.emitter.emit('change', { chainId }) + }, + async onConnect(connectInfo) { + const chainId = Number(connectInfo.chainId) + const accounts = await this.getAccounts() + config.emitter.emit('connect', { accounts, chainId }) + }, + async onDisconnect(_error) { + this.setRequestedChainsIds([]) + config.emitter.emit('disconnect') + + const provider = await this.getProvider() + if (accountsChanged) { + provider.removeListener('accountsChanged', accountsChanged) + accountsChanged = undefined + } + if (chainChanged) { + provider.removeListener('chainChanged', chainChanged) + chainChanged = undefined + } + if (disconnect) { + provider.removeListener('disconnect', disconnect) + disconnect = undefined + } + if (sessionDelete) { + provider.removeListener('session_delete', sessionDelete) + sessionDelete = undefined + } + if (!connect) { + connect = this.onConnect.bind(this) + provider.on('connect', connect) + } + }, + onDisplayUri(uri) { + config.emitter.emit('message', { type: 'display_uri', data: uri }) + }, + onSessionDelete() { + this.onDisconnect() + }, + getNamespaceChainsIds() { + if (!provider_) return [] + const chainIds = provider_.session?.namespaces[NAMESPACE]?.accounts?.map( + (account) => Number.parseInt(account.split(':')[1] || ''), + ) + return chainIds ?? [] + }, + async getRequestedChainsIds() { + return ( + (await config.storage?.getItem(this.requestedChainsStorageKey)) ?? [] + ) + }, + /** + * Checks if the target chains match the chains that were + * initially requested by the connector for the WalletConnect session. + * If there is a mismatch, this means that the chains on the connector + * are considered stale, and need to be revalidated at a later point (via + * connection). + * + * There may be a scenario where a dapp adds a chain to the + * connector later on, however, this chain will not have been approved or rejected + * by the wallet. In this case, the chain is considered stale. + */ + async isChainsStale() { + if (!isNewChainsStale) return false + + const connectorChains = config.chains.map((x) => x.id) + const namespaceChains = this.getNamespaceChainsIds() + if ( + namespaceChains.length && + !namespaceChains.some((id) => connectorChains.includes(id)) + ) + return false + + const requestedChains = await this.getRequestedChainsIds() + return !connectorChains.every((id) => requestedChains.includes(id)) + }, + async setRequestedChainsIds(chains) { + await config.storage?.setItem(this.requestedChainsStorageKey, chains) + }, + get requestedChainsStorageKey() { + return `${this.id}.requestedChains` as Properties['requestedChainsStorageKey'] + }, + })) +} diff --git a/packages/connectors/tsconfig.build.json b/packages/connectors/tsconfig.build.json new file mode 100644 index 0000000000..fbed2b1036 --- /dev/null +++ b/packages/connectors/tsconfig.build.json @@ -0,0 +1,8 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["src/**/*.ts"], + "exclude": ["src/**/*.test.ts", "src/**/*.test-d.ts"], + "compilerOptions": { + "sourceMap": true + } +} diff --git a/packages/connectors/tsconfig.json b/packages/connectors/tsconfig.json new file mode 100644 index 0000000000..bd33919ac3 --- /dev/null +++ b/packages/connectors/tsconfig.json @@ -0,0 +1,5 @@ +{ + "extends": "./tsconfig.build.json", + "include": ["src/**/*.ts"], + "exclude": [] +} diff --git a/packages/core/README.md b/packages/core/README.md new file mode 100644 index 0000000000..b46e39c559 --- /dev/null +++ b/packages/core/README.md @@ -0,0 +1,13 @@ +# @wagmi/core + +VanillaJS library for Ethereum + +## Installation + +```bash +pnpm add @wagmi/core viem +``` + +## Documentation + +For documentation and guides, visit [wagmi.sh](https://wagmi.sh). diff --git a/packages/core/src/actions/call.test.ts b/packages/core/src/actions/call.test.ts new file mode 100644 index 0000000000..2ef01160da --- /dev/null +++ b/packages/core/src/actions/call.test.ts @@ -0,0 +1,149 @@ +import { accounts, address, config } from '@wagmi/test' +import { parseEther, parseGwei } from 'viem' +import { expect, test } from 'vitest' + +import { call } from './call.js' + +const name4bytes = '0x06fdde03' +const mint4bytes = '0x1249c58b' +const mintWithParams4bytes = '0xa0712d68' +const fourTwenty = + '00000000000000000000000000000000000000000000000000000000000001a4' + +const account = accounts[0] + +test('default', async () => { + await expect( + call(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + }), + ).resolves.toMatchInlineSnapshot(` + { + "data": "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000057761676d69000000000000000000000000000000000000000000000000000000", + } + `) +}) + +test('zero data', async () => { + await expect( + call(config, { + account, + data: mint4bytes, + to: address.wagmiMintExample, + }), + ).resolves.toMatchInlineSnapshot(` + { + "data": undefined, + } + `) +}) + +// TODO: Re-enable +test.skip('parameters: blockNumber', async () => { + await expect( + call(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + blockNumber: 16280770n, + }), + ).resolves.toMatchInlineSnapshot(` + { + "data": "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000057761676d69000000000000000000000000000000000000000000000000000000", + } + `) +}) + +test('insufficient funds', async () => { + await expect( + call(config, { + account, + to: accounts[1], + value: parseEther('100000'), + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [CallExecutionError: The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account. + + This error could arise when the account does not have enough funds to: + - pay for the total gas fee, + - pay for the value to send. + + The cost of the transaction is calculated as \`gas * gas fee + value\`, where: + - \`gas\` is the amount of gas needed for transaction to execute, + - \`gas fee\` is the gas fee, + - \`value\` is the amount of ether to send to the recipient. + + Raw Call Arguments: + from: 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266 + to: 0x70997970c51812dc3a010c7d01b50e0d17dc79c8 + value: 100000 ETH + + Details: Insufficient funds for gas * price + value + Version: viem@2.29.2] + `) +}) + +test('maxFeePerGas less than maxPriorityFeePerGas', async () => { + await expect( + call(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + maxFeePerGas: parseGwei('20'), + maxPriorityFeePerGas: parseGwei('22'), + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [CallExecutionError: The provided tip (\`maxPriorityFeePerGas\` = 22 gwei) cannot be higher than the fee cap (\`maxFeePerGas\` = 20 gwei). + + Raw Call Arguments: + from: 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266 + to: 0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2 + data: 0x06fdde03 + maxFeePerGas: 20 gwei + maxPriorityFeePerGas: 22 gwei + + Version: viem@2.29.2] + `) +}) + +test('contract revert (contract error)', async () => { + await expect( + call(config, { + account, + data: `${mintWithParams4bytes}${fourTwenty}`, + to: address.wagmiMintExample, + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [CallExecutionError: Execution reverted with reason: Token ID is taken. + + Raw Call Arguments: + from: 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266 + to: 0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2 + data: 0xa0712d6800000000000000000000000000000000000000000000000000000000000001a4 + + Details: execution reverted: Token ID is taken + Version: viem@2.29.2] + `) +}) + +test('contract revert (insufficient params)', async () => { + await expect( + call(config, { + account, + data: mintWithParams4bytes, + to: address.wagmiMintExample, + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [CallExecutionError: Execution reverted for an unknown reason. + + Raw Call Arguments: + from: 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266 + to: 0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2 + data: 0xa0712d68 + + Details: execution reverted + Version: viem@2.29.2] + `) +}) diff --git a/packages/core/src/actions/call.ts b/packages/core/src/actions/call.ts new file mode 100644 index 0000000000..90e6c1ae20 --- /dev/null +++ b/packages/core/src/actions/call.ts @@ -0,0 +1,27 @@ +import type { + CallErrorType as viem_CallErrorType, + CallParameters as viem_CallParameters, + CallReturnType as viem_CallReturnType, +} from 'viem' +import { call as viem_call } from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import { getAction } from '../utils/getAction.js' + +export type CallParameters = + viem_CallParameters & ChainIdParameter + +export type CallReturnType = viem_CallReturnType + +export type CallErrorType = viem_CallErrorType + +export async function call( + config: config, + parameters: CallParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_call, 'call') + return action(rest) +} diff --git a/packages/core/src/actions/codegen/createReadContract.test-d.ts b/packages/core/src/actions/codegen/createReadContract.test-d.ts new file mode 100644 index 0000000000..f5c9dd302b --- /dev/null +++ b/packages/core/src/actions/codegen/createReadContract.test-d.ts @@ -0,0 +1,130 @@ +import { abi, config, mainnet, optimism } from '@wagmi/test' +import { assertType, expectTypeOf, test } from 'vitest' + +import { createReadContract } from './createReadContract.js' + +test('default', async () => { + const readErc20 = createReadContract({ + abi: abi.erc20, + address: '0x', + }) + + const result = await readErc20(config, { + functionName: 'balanceOf', + args: ['0x'], + chainId: 1, + }) + expectTypeOf(result).toEqualTypeOf() +}) + +test('multichain address', async () => { + const readErc20 = createReadContract({ + abi: abi.erc20, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + }) + + const result = await readErc20(config, { + functionName: 'balanceOf', + args: ['0x'], + chainId: mainnet.id, + // ^? + }) + assertType(result) + + readErc20(config, { + functionName: 'balanceOf', + args: ['0x'], + // @ts-expect-error chain id must match address keys + chainId: 420, + }) + + readErc20(config, { + functionName: 'balanceOf', + args: ['0x'], + // @ts-expect-error address not allowed + address: '0x', + }) +}) + +test('overloads', async () => { + const readViewOverloads = createReadContract({ + abi: abi.viewOverloads, + address: '0x', + }) + + const result1 = await readViewOverloads(config, { + functionName: 'foo', + }) + assertType(result1) + + const result2 = await readViewOverloads(config, { + functionName: 'foo', + args: [], + }) + assertType(result2) + + const result3 = await readViewOverloads(config, { + functionName: 'foo', + args: ['0x'], + }) + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + assertType(result3) + + const result4 = await readViewOverloads(config, { + functionName: 'foo', + args: ['0x', '0x'], + }) + assertType<{ + foo: `0x${string}` + bar: `0x${string}` + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + }>(result4) +}) + +test('functionName', async () => { + const readErc20BalanceOf = createReadContract({ + abi: abi.erc20, + address: '0x', + functionName: 'balanceOf', + }) + + const result = await readErc20BalanceOf(config, { + args: ['0x'], + chainId: 1, + }) + expectTypeOf(result).toEqualTypeOf() +}) + +test('functionName with overloads', async () => { + const readViewOverloads = createReadContract({ + abi: abi.viewOverloads, + address: '0x', + functionName: 'foo', + }) + + const result1 = await readViewOverloads(config, {}) + assertType(result1) + + const result2 = await readViewOverloads(config, { + args: [], + }) + assertType(result2) + + const result3 = await readViewOverloads(config, { + args: ['0x'], + }) + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + assertType(result3) + + const result4 = await readViewOverloads(config, { + args: ['0x', '0x'], + }) + assertType<{ + foo: `0x${string}` + bar: `0x${string}` + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + }>(result4) +}) diff --git a/packages/core/src/actions/codegen/createReadContract.test.ts b/packages/core/src/actions/codegen/createReadContract.test.ts new file mode 100644 index 0000000000..9de7ae718f --- /dev/null +++ b/packages/core/src/actions/codegen/createReadContract.test.ts @@ -0,0 +1,50 @@ +import { abi, address, chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { createReadContract } from './createReadContract.js' + +test('default', async () => { + const readWagmiMintExample = createReadContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + }) + + await expect( + readWagmiMintExample(config, { + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }), + ).resolves.toMatchInlineSnapshot('4n') +}) + +test('multichain', async () => { + const readWagmiMintExample = createReadContract({ + address: { + [chain.mainnet.id]: address.wagmiMintExample, + [chain.mainnet2.id]: address.wagmiMintExample, + }, + abi: abi.wagmiMintExample, + }) + + await expect( + readWagmiMintExample(config, { + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + chainId: chain.mainnet2.id, + }), + ).resolves.toMatchInlineSnapshot('4n') +}) + +test('functionName', async () => { + const readWagmiMintExampleBalanceOf = createReadContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'balanceOf', + }) + + await expect( + readWagmiMintExampleBalanceOf(config, { + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }), + ).resolves.toMatchInlineSnapshot('4n') +}) diff --git a/packages/core/src/actions/codegen/createReadContract.ts b/packages/core/src/actions/codegen/createReadContract.ts new file mode 100644 index 0000000000..f7dbfbed45 --- /dev/null +++ b/packages/core/src/actions/codegen/createReadContract.ts @@ -0,0 +1,100 @@ +import type { + Abi, + Address, + ContractFunctionArgs, + ContractFunctionName, +} from 'viem' + +import type { Config } from '../../createConfig.js' +import type { UnionCompute, UnionStrictOmit } from '../../types/utils.js' +import { getAccount } from '../getAccount.js' +import { getChainId } from '../getChainId.js' +import { + type ReadContractParameters, + type ReadContractReturnType, + readContract, +} from '../readContract.js' + +type stateMutability = 'pure' | 'view' + +export type CreateReadContractParameters< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined = undefined, + functionName extends + | ContractFunctionName + | undefined = undefined, +> = { + abi: abi | Abi | readonly unknown[] + address?: address | Address | Record | undefined + functionName?: + | functionName + | ContractFunctionName + | undefined +} + +export type CreateReadContractReturnType< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined, + functionName extends ContractFunctionName | undefined, + /// + omittedProperties extends 'abi' | 'address' | 'chainId' | 'functionName' = + | 'abi' + | (address extends undefined ? never : 'address') + | (address extends Record ? 'chainId' : never) + | (functionName extends undefined ? never : 'functionName'), +> = < + config extends Config, + name extends functionName extends ContractFunctionName + ? functionName + : ContractFunctionName, + args extends ContractFunctionArgs, +>( + config: config, + parameters: UnionCompute< + UnionStrictOmit< + ReadContractParameters, + omittedProperties + > + > & + (address extends Record + ? { chainId?: keyof address | undefined } + : unknown), +) => Promise> + +export function createReadContract< + const abi extends Abi | readonly unknown[], + const address extends + | Address + | Record + | undefined = undefined, + functionName extends + | ContractFunctionName + | undefined = undefined, +>( + c: CreateReadContractParameters, +): CreateReadContractReturnType { + if (c.address !== undefined && typeof c.address === 'object') + return (config, parameters) => { + const configChainId = getChainId(config) + const account = getAccount(config) + const chainId = + (parameters as { chainId?: number })?.chainId ?? + account.chainId ?? + configChainId + return readContract(config, { + ...(parameters as any), + ...(c.functionName ? { functionName: c.functionName } : {}), + address: c.address?.[chainId], + abi: c.abi, + }) + } + + return (config, parameters) => { + return readContract(config, { + ...(parameters as any), + ...(c.address ? { address: c.address } : {}), + ...(c.functionName ? { functionName: c.functionName } : {}), + abi: c.abi, + }) + } +} diff --git a/packages/core/src/actions/codegen/createSimulateContract.test-d.ts b/packages/core/src/actions/codegen/createSimulateContract.test-d.ts new file mode 100644 index 0000000000..91e5998977 --- /dev/null +++ b/packages/core/src/actions/codegen/createSimulateContract.test-d.ts @@ -0,0 +1,211 @@ +import { abi, config, mainnet, optimism } from '@wagmi/test' +import { http, type Address } from 'viem' +import { celo } from 'viem/chains' +import { assertType, expectTypeOf, test } from 'vitest' + +import { createConfig } from '../../createConfig.js' +import { createSimulateContract } from './createSimulateContract.js' + +test('default', async () => { + const simulateErc20 = createSimulateContract({ + abi: abi.erc20, + address: '0x', + }) + + const result = await simulateErc20(config, { + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 1, + }) + + expectTypeOf(result).toMatchTypeOf<{ + result: boolean + request: { + chainId: 1 + abi: readonly [ + { + readonly name: 'transferFrom' + readonly type: 'function' + readonly stateMutability: 'nonpayable' + readonly inputs: readonly [ + { readonly type: 'address'; readonly name: 'sender' }, + { readonly type: 'address'; readonly name: 'recipient' }, + { readonly type: 'uint256'; readonly name: 'amount' }, + ] + readonly outputs: readonly [{ type: 'bool' }] + }, + ] + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + } + }>() +}) + +test('multichain address', async () => { + const simulateErc20 = createSimulateContract({ + abi: abi.erc20, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + }) + + const result = await simulateErc20(config, { + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: optimism.id, + }) + expectTypeOf(result.result).toEqualTypeOf() + + simulateErc20(config, { + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + // @ts-expect-error chain id must match address keys + chainId: 420, + }) + + simulateErc20(config, { + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + // @ts-expect-error address not allowed + address: '0x', + }) +}) + +test('overloads', async () => { + const simulateWriteOverloads = createSimulateContract({ + abi: abi.writeOverloads, + address: '0x', + }) + + const result1 = await simulateWriteOverloads(config, { + functionName: 'foo', + }) + assertType(result1.result) + + const result2 = await simulateWriteOverloads(config, { + functionName: 'foo', + args: [], + }) + assertType(result2.result) + + const result3 = await simulateWriteOverloads(config, { + functionName: 'foo', + args: ['0x'], + }) + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + assertType(result3.result) + + const result4 = await simulateWriteOverloads(config, { + functionName: 'foo', + args: ['0x', '0x'], + }) + assertType< + | { + foo: `0x${string}` + bar: `0x${string}` + } + | undefined + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + >(result4.result) +}) + +test('functionName', async () => { + const simulateErc20 = createSimulateContract({ + abi: abi.erc20, + address: '0x', + functionName: 'transferFrom', + }) + + const result = await simulateErc20(config, { + args: ['0x', '0x', 123n], + chainId: 1, + }) + + expectTypeOf(result).toMatchTypeOf<{ + result: boolean + request: { + chainId: 1 + abi: readonly [ + { + readonly name: 'transferFrom' + readonly type: 'function' + readonly stateMutability: 'nonpayable' + readonly inputs: readonly [ + { readonly type: 'address'; readonly name: 'sender' }, + { readonly type: 'address'; readonly name: 'recipient' }, + { readonly type: 'uint256'; readonly name: 'amount' }, + ] + readonly outputs: readonly [{ type: 'bool' }] + }, + ] + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + } + }>() +}) + +test('functionName with overloads', async () => { + const simulateWriteOverloads = createSimulateContract({ + abi: abi.writeOverloads, + address: '0x', + functionName: 'foo', + }) + + const result1 = await simulateWriteOverloads(config, {}) + assertType(result1.result) + + const result2 = await simulateWriteOverloads(config, { + args: [], + }) + assertType(result2.result) + + const result3 = await simulateWriteOverloads(config, { + args: ['0x'], + }) + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + assertType(result3.result) + + const result4 = await simulateWriteOverloads(config, { + args: ['0x', '0x'], + }) + assertType< + | { + foo: `0x${string}` + bar: `0x${string}` + } + | undefined + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + >(result4.result) +}) + +test('chain formatters', async () => { + const simulateErc20 = createSimulateContract({ + abi: abi.erc20, + address: '0x', + }) + + const config = createConfig({ + chains: [celo, mainnet], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + + const response = await simulateErc20(config, { + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + }) + if (response.chainId === celo.id) { + expectTypeOf(response.request.feeCurrency).toEqualTypeOf< + `0x${string}` | undefined + >() + } + + const response2 = await simulateErc20(config, { + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: celo.id, + }) + expectTypeOf(response2.request.feeCurrency).toEqualTypeOf< + `0x${string}` | undefined + >() +}) diff --git a/packages/core/src/actions/codegen/createSimulateContract.test.ts b/packages/core/src/actions/codegen/createSimulateContract.test.ts new file mode 100644 index 0000000000..bd37d13770 --- /dev/null +++ b/packages/core/src/actions/codegen/createSimulateContract.test.ts @@ -0,0 +1,137 @@ +import { abi, address, chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { connect } from '../connect.js' +import { disconnect } from '../disconnect.js' +import { createSimulateContract } from './createSimulateContract.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const simulateWagmiMintExample = createSimulateContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + }) + + await expect( + simulateWagmiMintExample(config, { + functionName: 'mint', + }), + ).resolves.toMatchInlineSnapshot(` + { + "chainId": 1, + "request": { + "abi": [ + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": undefined, + "chainId": undefined, + "dataSuffix": undefined, + "functionName": "mint", + }, + "result": undefined, + } + `) + + await disconnect(config, { connector }) +}) + +test('multichain', async () => { + await connect(config, { connector }) + + const simulateWagmiMintExample = createSimulateContract({ + address: { + [chain.mainnet.id]: address.wagmiMintExample, + [chain.mainnet2.id]: address.wagmiMintExample, + }, + abi: abi.wagmiMintExample, + }) + + await expect( + simulateWagmiMintExample(config, { + functionName: 'mint', + chainId: chain.mainnet2.id, + }), + ).resolves.toMatchInlineSnapshot(` + { + "chainId": 456, + "request": { + "abi": [ + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": undefined, + "chainId": 456, + "dataSuffix": undefined, + "functionName": "mint", + }, + "result": undefined, + } + `) + + await disconnect(config, { connector }) +}) + +test('functionName', async () => { + await connect(config, { connector }) + + const simulateWagmiMintExample = createSimulateContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'mint', + }) + + await expect( + simulateWagmiMintExample(config, {}), + ).resolves.toMatchInlineSnapshot(` + { + "chainId": 1, + "request": { + "abi": [ + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": undefined, + "chainId": undefined, + "dataSuffix": undefined, + "functionName": "mint", + }, + "result": undefined, + } + `) + + await disconnect(config, { connector }) +}) diff --git a/packages/core/src/actions/codegen/createSimulateContract.ts b/packages/core/src/actions/codegen/createSimulateContract.ts new file mode 100644 index 0000000000..016384e245 --- /dev/null +++ b/packages/core/src/actions/codegen/createSimulateContract.ts @@ -0,0 +1,122 @@ +import type { + Abi, + Account, + Address, + Chain, + ContractFunctionArgs, + ContractFunctionName, + SimulateContractParameters as viem_SimulateContractParameters, +} from 'viem' + +import type { Config } from '../../createConfig.js' +import type { SelectChains } from '../../types/chain.js' +import type { + ChainIdParameter, + ConnectorParameter, +} from '../../types/properties.js' +import type { UnionCompute, UnionStrictOmit } from '../../types/utils.js' +import { getAccount } from '../getAccount.js' +import { getChainId } from '../getChainId.js' +import { + type SimulateContractReturnType, + simulateContract, +} from '../simulateContract.js' + +type stateMutability = 'nonpayable' | 'payable' + +export type CreateSimulateContractParameters< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined = undefined, + functionName extends + | ContractFunctionName + | undefined = undefined, +> = { + abi: abi | Abi | readonly unknown[] + address?: address | Address | Record | undefined + functionName?: + | functionName + | ContractFunctionName + | undefined +} + +export type CreateSimulateContractReturnType< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined, + functionName extends ContractFunctionName | undefined, +> = < + config extends Config, + name extends functionName extends ContractFunctionName + ? functionName + : ContractFunctionName, + args extends ContractFunctionArgs, + chainId extends config['chains'][number]['id'] | undefined = undefined, + /// + chains extends readonly Chain[] = SelectChains, +>( + config: config, + parameters: { + [key in keyof chains]: UnionCompute< + UnionStrictOmit< + viem_SimulateContractParameters< + abi, + name, + args, + chains[key], + chains[key], + Account | Address + >, + | 'abi' + | 'chain' + | (address extends undefined ? never : 'address') + | (functionName extends undefined ? never : 'functionName') + > + > & + ChainIdParameter & + ConnectorParameter & { + chainId?: address extends Record + ? + | keyof address + | (chainId extends keyof address ? chainId : never) + | undefined + : chainId | number | undefined + } + }[number], +) => Promise> + +export function createSimulateContract< + const abi extends Abi | readonly unknown[], + const address extends + | Address + | Record + | undefined = undefined, + functionName extends + | ContractFunctionName + | undefined = undefined, +>( + c: CreateSimulateContractParameters, +): CreateSimulateContractReturnType { + if (c.address !== undefined && typeof c.address === 'object') + return (config, parameters) => { + const configChainId = getChainId(config) + const account = getAccount(config) + const chainId = + (parameters as { chainId?: number })?.chainId ?? + account.chainId ?? + configChainId + return simulateContract(config, { + ...(parameters as any), + ...(c.functionName ? { functionName: c.functionName } : {}), + address: c.address?.[chainId], + abi: c.abi, + }) + } + + return (config, parameters) => { + return simulateContract(config, { + ...(parameters as any), + ...(c.address ? { address: c.address } : {}), + ...(c.functionName ? { functionName: c.functionName } : {}), + abi: c.abi, + }) + } +} diff --git a/packages/core/src/actions/codegen/createWatchContractEvent.test-d.ts b/packages/core/src/actions/codegen/createWatchContractEvent.test-d.ts new file mode 100644 index 0000000000..6c0485f39d --- /dev/null +++ b/packages/core/src/actions/codegen/createWatchContractEvent.test-d.ts @@ -0,0 +1,123 @@ +import { abi, config, mainnet, optimism } from '@wagmi/test' +import { http, webSocket } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../../createConfig.js' +import { createWatchContractEvent } from './createWatchContractEvent.js' + +test('default', () => { + const watchErc20Event = createWatchContractEvent({ + abi: abi.erc20, + }) + + watchErc20Event(config, { + eventName: 'Transfer', + chainId: 1, + onLogs(logs) { + expectTypeOf(logs[0]!.eventName).toEqualTypeOf<'Transfer'>() + expectTypeOf(logs[0]!.args).toEqualTypeOf<{ + from?: `0x${string}` | undefined + to?: `0x${string}` | undefined + value?: bigint | undefined + }>() + }, + }) +}) + +test('multichain address', () => { + const watchErc20Event = createWatchContractEvent({ + abi: abi.erc20, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + }) + + watchErc20Event(config, { + eventName: 'Transfer', + chainId: mainnet.id, + // ^? + onLogs() {}, + }) + + watchErc20Event(config, { + eventName: 'Transfer', + // @ts-expect-error chain id must match address keys + chainId: 420, + onLogs() {}, + }) + + watchErc20Event(config, { + eventName: 'Transfer', + // @ts-expect-error chain id must match address keys + address: '0x', + onLogs() {}, + }) +}) + +test('differing transports', () => { + const watchErc20Event = createWatchContractEvent({ + abi: abi.erc20, + }) + + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + watchErc20Event(config, { + poll: false, + address: '0x', + onLogs() {}, + }) + + watchErc20Event(config, { + chainId: mainnet.id, + poll: true, + address: '0x', + onLogs() {}, + }) + watchErc20Event(config, { + config, + chainId: mainnet.id, + // @ts-expect-error poll required since http transport + poll: false, + address: '0x', + onLogs() {}, + }) + + watchErc20Event(config, { + chainId: optimism.id, + poll: true, + address: '0x', + onLogs() {}, + }) + watchErc20Event(config, { + chainId: optimism.id, + poll: false, + address: '0x', + onLogs() {}, + }) +}) + +test('eventName', () => { + const watchErc20Event = createWatchContractEvent({ + abi: abi.erc20, + eventName: 'Transfer', + }) + + watchErc20Event(config, { + chainId: 1, + onLogs(logs) { + expectTypeOf(logs[0]!.eventName).toEqualTypeOf<'Transfer'>() + expectTypeOf(logs[0]!.args).toEqualTypeOf<{ + from?: `0x${string}` | undefined + to?: `0x${string}` | undefined + value?: bigint | undefined + }>() + }, + }) +}) diff --git a/packages/core/src/actions/codegen/createWatchContractEvent.test.ts b/packages/core/src/actions/codegen/createWatchContractEvent.test.ts new file mode 100644 index 0000000000..19ba09b2a2 --- /dev/null +++ b/packages/core/src/actions/codegen/createWatchContractEvent.test.ts @@ -0,0 +1,41 @@ +import { abi, address, chain, config } from '@wagmi/test' +import type { WatchEventOnLogsParameter } from 'viem' +import { test } from 'vitest' + +import { createWatchContractEvent } from './createWatchContractEvent.js' + +test('default', async () => { + const watchErc20Event = createWatchContractEvent({ + address: address.usdc, + abi: abi.wagmiMintExample, + }) + + let logs: WatchEventOnLogsParameter = [] + const unwatch = watchErc20Event(config, { + eventName: 'Transfer', + onLogs(next) { + logs = logs.concat(next) + }, + }) + unwatch() +}) + +test('multichain', async () => { + const watchErc20Event = createWatchContractEvent({ + address: { + [chain.mainnet.id]: address.usdc, + [chain.mainnet2.id]: address.usdc, + }, + abi: abi.wagmiMintExample, + }) + + let logs: WatchEventOnLogsParameter = [] + const unwatch = watchErc20Event(config, { + eventName: 'Transfer', + chainId: chain.mainnet2.id, + onLogs(next) { + logs = logs.concat(next) + }, + }) + unwatch() +}) diff --git a/packages/core/src/actions/codegen/createWatchContractEvent.ts b/packages/core/src/actions/codegen/createWatchContractEvent.ts new file mode 100644 index 0000000000..2817efc704 --- /dev/null +++ b/packages/core/src/actions/codegen/createWatchContractEvent.ts @@ -0,0 +1,88 @@ +import type { Abi, Address, ContractEventName } from 'viem' + +import type { Config } from '../../createConfig.js' +import type { UnionCompute, UnionStrictOmit } from '../../types/utils.js' +import { getAccount } from '../getAccount.js' +import { getChainId } from '../getChainId.js' +import { + type WatchContractEventParameters, + type WatchContractEventReturnType, + watchContractEvent, +} from '../watchContractEvent.js' + +export type CreateWatchContractEventParameters< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined = undefined, + eventName extends ContractEventName | undefined = undefined, +> = { + abi: abi | Abi | readonly unknown[] + address?: address | Address | Record | undefined + eventName?: eventName | ContractEventName | undefined +} + +export type CreateWatchContractEventReturnType< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined, + eventName extends ContractEventName | undefined, + /// + omittedProperties extends 'abi' | 'address' | 'chainId' | 'eventName' = + | 'abi' + | (address extends undefined ? never : 'address') + | (address extends Record ? 'chainId' : never) + | (eventName extends undefined ? never : 'eventName'), +> = < + config extends Config, + name extends eventName extends ContractEventName + ? eventName + : ContractEventName, + strict extends boolean | undefined = undefined, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + config: config, + parameters: UnionCompute< + UnionStrictOmit< + WatchContractEventParameters, + omittedProperties + > + > & + (address extends Record + ? { chainId?: keyof address | undefined } + : unknown), +) => WatchContractEventReturnType + +export function createWatchContractEvent< + const abi extends Abi | readonly unknown[], + const address extends + | Address + | Record + | undefined = undefined, + eventName extends ContractEventName | undefined = undefined, +>( + c: CreateWatchContractEventParameters, +): CreateWatchContractEventReturnType { + if (c.address !== undefined && typeof c.address === 'object') + return (config, parameters) => { + const configChainId = getChainId(config) + const account = getAccount(config) + const chainId = + (parameters as { chainId?: number })?.chainId ?? + account.chainId ?? + configChainId + return watchContractEvent(config, { + ...(parameters as any), + ...(c.eventName ? { eventName: c.eventName } : {}), + address: c.address?.[chainId], + abi: c.abi, + }) + } + + return (config, parameters) => { + return watchContractEvent(config, { + ...(parameters as any), + ...(c.address ? { address: c.address } : {}), + ...(c.eventName ? { eventName: c.eventName } : {}), + abi: c.abi, + }) + } +} diff --git a/packages/core/src/actions/codegen/createWriteContract.test-d.ts b/packages/core/src/actions/codegen/createWriteContract.test-d.ts new file mode 100644 index 0000000000..9c69ede5bf --- /dev/null +++ b/packages/core/src/actions/codegen/createWriteContract.test-d.ts @@ -0,0 +1,129 @@ +import { abi, config, mainnet, optimism } from '@wagmi/test' +import { test } from 'vitest' + +import { simulateContract } from '../simulateContract.js' +import { createWriteContract } from './createWriteContract.js' + +test('default', () => { + const writeErc20 = createWriteContract({ + abi: abi.erc20, + address: '0x', + }) + + writeErc20(config, { + functionName: 'transfer', + args: ['0x', 123n], + }) +}) + +test('multichain address', () => { + const writeErc20 = createWriteContract({ + abi: abi.erc20, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + }) + + writeErc20(config, { + functionName: 'transfer', + args: ['0x', 123n], + chainId: mainnet.id, + // ^? + }) + + writeErc20(config, { + functionName: 'transfer', + args: ['0x', 123n], + // @ts-expect-error chain id must match address keys + chainId: 420, + }) + + writeErc20(config, { + // @ts-expect-error address not allowed + address: '0x', + functionName: 'transfer', + args: ['0x', 123n], + }) +}) + +test('overloads', () => { + const writeOverloads = createWriteContract({ + abi: abi.writeOverloads, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + }) + + writeOverloads(config, { + functionName: 'foo', + args: [], + }) + + writeOverloads(config, { + functionName: 'foo', + args: ['0x'], + }) + + writeOverloads(config, { + functionName: 'foo', + args: ['0x', '0x'], + }) +}) + +test('useSimulateContract', async () => { + const writeErc20 = createWriteContract({ + abi: abi.erc20, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + }) + + const { request } = await simulateContract(config, { + account: '0x', + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 1, + }) + + writeErc20(config, request) +}) + +test('functionName', () => { + const writeErc20 = createWriteContract({ + abi: abi.erc20, + address: '0x', + functionName: 'transfer', + }) + + writeErc20(config, { + args: ['0x', 123n], + }) +}) + +test('functionName with overloads', () => { + const writeOverloads = createWriteContract({ + abi: abi.writeOverloads, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + functionName: 'foo', + }) + + writeOverloads(config, { + args: [], + }) + + writeOverloads(config, { + args: ['0x'], + }) + + writeOverloads(config, { + args: ['0x', '0x'], + }) +}) diff --git a/packages/core/src/actions/codegen/createWriteContract.test.ts b/packages/core/src/actions/codegen/createWriteContract.test.ts new file mode 100644 index 0000000000..04511d13ab --- /dev/null +++ b/packages/core/src/actions/codegen/createWriteContract.test.ts @@ -0,0 +1,11 @@ +import { abi } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { createWriteContract } from './createWriteContract.js' + +test('default', () => { + const writeErc20 = createWriteContract({ + abi: abi.erc20, + }) + expect(writeErc20).toBeDefined() +}) diff --git a/packages/core/src/actions/codegen/createWriteContract.ts b/packages/core/src/actions/codegen/createWriteContract.ts new file mode 100644 index 0000000000..6c1d891a3f --- /dev/null +++ b/packages/core/src/actions/codegen/createWriteContract.ts @@ -0,0 +1,145 @@ +import type { + Abi, + Account, + Address, + Chain, + ContractFunctionArgs, + ContractFunctionName, + WriteContractParameters as viem_WriteContractParameters, +} from 'viem' + +import type { Config } from '../../createConfig.js' +import type { SelectChains } from '../../types/chain.js' +import type { + ChainIdParameter, + ConnectorParameter, +} from '../../types/properties.js' +import type { + Compute, + UnionCompute, + UnionStrictOmit, +} from '../../types/utils.js' +import { getAccount } from '../getAccount.js' +import { getChainId } from '../getChainId.js' +import { + type WriteContractReturnType, + writeContract, +} from '../writeContract.js' + +type stateMutability = 'nonpayable' | 'payable' + +export type CreateWriteContractParameters< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined = undefined, + functionName extends + | ContractFunctionName + | undefined = undefined, +> = { + abi: abi | Abi | readonly unknown[] + address?: address | Address | Record | undefined + functionName?: + | functionName + | ContractFunctionName + | undefined +} + +export type CreateWriteContractReturnType< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined, + functionName extends ContractFunctionName | undefined, +> = < + config extends Config, + name extends functionName extends ContractFunctionName + ? functionName + : ContractFunctionName, + args extends ContractFunctionArgs, + chainId extends config['chains'][number]['id'], + /// + allFunctionNames = ContractFunctionName, + chains extends readonly Chain[] = SelectChains, + omittedProperties extends 'abi' | 'address' | 'functionName' = + | 'abi' + | (address extends undefined ? never : 'address') + | (functionName extends undefined ? never : 'functionName'), +>( + config: config, + parameters: UnionCompute< + { + [key in keyof chains]: UnionStrictOmit< + viem_WriteContractParameters< + abi, + name, + args, + chains[key], + Account, + chains[key], + allFunctionNames + >, + omittedProperties | 'chain' + > + }[number] & + (address extends Record + ? { + chainId?: + | keyof address + | (chainId extends keyof address ? chainId : never) + | undefined + } + : Compute>) & + ConnectorParameter & { + /** @deprecated */ + __mode?: 'prepared' + } + >, +) => Promise + +export function createWriteContract< + const abi extends Abi | readonly unknown[], + const address extends + | Address + | Record + | undefined = undefined, + functionName extends + | ContractFunctionName + | undefined = undefined, +>( + c: CreateWriteContractParameters, +): CreateWriteContractReturnType { + if (c.address !== undefined && typeof c.address === 'object') + return (config, parameters) => { + const configChainId = getChainId(config) + const account = getAccount(config) + + let chainId: number | undefined + if (parameters.chainId) chainId = parameters.chainId + else if ( + (parameters as unknown as { account: Address | Account | undefined }) + .account && + (parameters as unknown as { account: Address | Account | undefined }) + .account === account.address + ) + chainId = account.chainId + else if ( + (parameters as unknown as { account: Address | Account | undefined }) + .account === undefined + ) + chainId = account.chainId + else chainId = configChainId + + return writeContract(config, { + ...(parameters as any), + ...(c.functionName ? { functionName: c.functionName } : {}), + address: chainId ? c.address?.[chainId] : undefined, + abi: c.abi, + }) + } + + return (config, parameters) => { + return writeContract(config, { + ...(parameters as any), + ...(c.address ? { address: c.address } : {}), + ...(c.functionName ? { functionName: c.functionName } : {}), + abi: c.abi, + }) + } +} diff --git a/packages/core/src/actions/connect.test-d.ts b/packages/core/src/actions/connect.test-d.ts new file mode 100644 index 0000000000..ad790b1209 --- /dev/null +++ b/packages/core/src/actions/connect.test-d.ts @@ -0,0 +1,48 @@ +import { accounts } from '@wagmi/test' +import { http } from 'viem' +import { mainnet } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import type { CreateConnectorFn } from '../connectors/createConnector.js' +import { mock } from '../connectors/mock.js' +import { type Connector, createConfig } from '../createConfig.js' +import { connect } from './connect.js' + +const config = createConfig({ + chains: [mainnet], + transports: { [mainnet.id]: http() }, +}) + +test('parameters: connector (ConnectorFn)', () => { + const connectorFn = mock({ accounts }) + + connect(config, { + connector: connectorFn, + foo: 'bar', + }) + expectTypeOf< + typeof connectorFn extends CreateConnectorFn ? true : false + >().toEqualTypeOf() + + type Result = NonNullable< + Parameters>[1] + > + expectTypeOf().toEqualTypeOf() +}) + +test('parameters: connector (Connector)', () => { + const connector = config._internal.connectors.setup(mock({ accounts })) + + connect(config, { + connector, + foo: 'bar', + }) + expectTypeOf< + typeof connector extends Connector ? true : false + >().toEqualTypeOf() + + type Result = NonNullable< + Parameters>[1] + > + expectTypeOf().toEqualTypeOf() +}) diff --git a/packages/core/src/actions/connect.test.ts b/packages/core/src/actions/connect.test.ts new file mode 100644 index 0000000000..eece8c3a4d --- /dev/null +++ b/packages/core/src/actions/connect.test.ts @@ -0,0 +1,71 @@ +import { accounts, chain, config } from '@wagmi/test' +import { beforeEach, expect, test } from 'vitest' + +import { mock } from '../connectors/mock.js' +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' + +const connector = config._internal.connectors.setup(mock({ accounts })) + +beforeEach(async () => { + if (config.state.current === connector.uid) + await disconnect(config, { connector }) +}) + +test('default', async () => { + await expect(connect(config, { connector })).resolves.toMatchObject( + expect.objectContaining({ + accounts: expect.any(Array), + chainId: expect.any(Number), + }), + ) +}) + +test('parameters: chainId', async () => { + const chainId = chain.mainnet2.id + await expect(connect(config, { connector, chainId })).resolves.toMatchObject( + expect.objectContaining({ + accounts: expect.any(Array), + chainId, + }), + ) +}) + +test('parameters: connector', async () => { + const connector_ = config._internal.connectors.setup(mock({ accounts })) + await expect( + connect(config, { connector: connector_ }), + ).resolves.toMatchObject( + expect.objectContaining({ + accounts: expect.any(Array), + chainId: expect.any(Number), + }), + ) + await disconnect(config, { connector: connector_ }) +}) + +test('behavior: user rejected request', async () => { + const connector_ = config._internal.connectors.setup( + mock({ + accounts, + features: { connectError: true }, + }), + ) + await expect( + connect(config, { connector: connector_ }), + ).rejects.toMatchInlineSnapshot(` + [UserRejectedRequestError: User rejected the request. + + Details: Failed to connect. + Version: viem@2.29.2] + `) +}) + +test('behavior: already connected', async () => { + await connect(config, { connector }) + await expect(connect(config, { connector })).rejects.toMatchInlineSnapshot(` + [ConnectorAlreadyConnectedError: Connector already connected. + + Version: @wagmi/core@x.y.z] + `) +}) diff --git a/packages/core/src/actions/connect.ts b/packages/core/src/actions/connect.ts new file mode 100644 index 0000000000..f69809e504 --- /dev/null +++ b/packages/core/src/actions/connect.ts @@ -0,0 +1,110 @@ +import type { + Address, + ResourceUnavailableRpcErrorType, + UserRejectedRequestErrorType, +} from 'viem' + +import type { CreateConnectorFn } from '../connectors/createConnector.js' +import type { Config, Connector } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import { + ConnectorAlreadyConnectedError, + type ConnectorAlreadyConnectedErrorType, +} from '../errors/config.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' + +export type ConnectParameters< + config extends Config = Config, + connector extends Connector | CreateConnectorFn = + | Connector + | CreateConnectorFn, + /// + parameters extends unknown | undefined = + | (connector extends CreateConnectorFn + ? Omit< + NonNullable['connect']>[0]>, + 'isReconnecting' + > + : never) + | (connector extends Connector + ? Omit< + NonNullable[0]>, + 'isReconnecting' + > + : never), +> = Compute< + ChainIdParameter & { + connector: connector | CreateConnectorFn + } +> & + parameters + +export type ConnectReturnType = { + accounts: readonly [Address, ...Address[]] + chainId: + | config['chains'][number]['id'] + | (number extends config['chains'][number]['id'] ? number : number & {}) +} + +export type ConnectErrorType = + | ConnectorAlreadyConnectedErrorType + // connector.connect() + | UserRejectedRequestErrorType + | ResourceUnavailableRpcErrorType + // base + | BaseErrorType + | ErrorType + +/** https://wagmi.sh/core/api/actions/connect */ +export async function connect< + config extends Config, + connector extends Connector | CreateConnectorFn, +>( + config: config, + parameters: ConnectParameters, +): Promise> { + // "Register" connector if not already created + let connector: Connector + if (typeof parameters.connector === 'function') { + connector = config._internal.connectors.setup(parameters.connector) + } else connector = parameters.connector + + // Check if connector is already connected + if (connector.uid === config.state.current) + throw new ConnectorAlreadyConnectedError() + + try { + config.setState((x) => ({ ...x, status: 'connecting' })) + connector.emitter.emit('message', { type: 'connecting' }) + + const { connector: _, ...rest } = parameters + const data = await connector.connect(rest) + const accounts = data.accounts as readonly [Address, ...Address[]] + + connector.emitter.off('connect', config._internal.events.connect) + connector.emitter.on('change', config._internal.events.change) + connector.emitter.on('disconnect', config._internal.events.disconnect) + + await config.storage?.setItem('recentConnectorId', connector.id) + config.setState((x) => ({ + ...x, + connections: new Map(x.connections).set(connector.uid, { + accounts, + chainId: data.chainId, + connector: connector, + }), + current: connector.uid, + status: 'connected', + })) + + return { accounts, chainId: data.chainId } + } catch (error) { + config.setState((x) => ({ + ...x, + // Keep existing connector connected in case of error + status: x.current ? 'connected' : 'disconnected', + })) + throw error + } +} diff --git a/packages/core/src/actions/deployContract.test-d.ts b/packages/core/src/actions/deployContract.test-d.ts new file mode 100644 index 0000000000..b7a6a897d3 --- /dev/null +++ b/packages/core/src/actions/deployContract.test-d.ts @@ -0,0 +1,71 @@ +import { abi, bytecode, config } from '@wagmi/test' +import { http } from 'viem' +import { celo, mainnet } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { + type DeployContractParameters, + deployContract, +} from './deployContract.js' + +test('default', async () => { + await deployContract(config, { + abi: abi.bayc, + bytecode: bytecode.bayc, + args: ['Bored Ape Wagmi Club', 'BAYC', 69420n, 0n], + chainId: mainnet.id, + }) +}) + +test('chain formatters', () => { + const config = createConfig({ + chains: [mainnet, celo], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + + type Result = DeployContractParameters + expectTypeOf().toMatchTypeOf<{ + chainId?: typeof celo.id | typeof mainnet.id | undefined + feeCurrency?: `0x${string}` | undefined + }>() + deployContract(config, { + abi: abi.bayc, + bytecode: bytecode.bayc, + args: ['Bored Ape Wagmi Club', 'BAYC', 69420n, 0n], + feeCurrency: '0x', + }) + + type Result2 = DeployContractParameters< + typeof abi.bayc, + typeof config, + typeof celo.id + > + expectTypeOf().toMatchTypeOf<{ + feeCurrency?: `0x${string}` | undefined + }>() + deployContract(config, { + chainId: celo.id, + abi: abi.bayc, + bytecode: bytecode.bayc, + args: ['Bored Ape Wagmi Club', 'BAYC', 69420n, 0n], + feeCurrency: '0x', + }) + + type Result3 = DeployContractParameters< + typeof abi.bayc, + typeof config, + typeof mainnet.id + > + expectTypeOf().not.toMatchTypeOf<{ + feeCurrency?: `0x${string}` | undefined + }>() + deployContract(config, { + chainId: mainnet.id, + abi: abi.bayc, + bytecode: bytecode.bayc, + args: ['Bored Ape Wagmi Club', 'BAYC', 69420n, 0n], + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/core/src/actions/deployContract.test.ts b/packages/core/src/actions/deployContract.test.ts new file mode 100644 index 0000000000..bebf42342e --- /dev/null +++ b/packages/core/src/actions/deployContract.test.ts @@ -0,0 +1,67 @@ +import { + abi, + bytecode, + config, + testClient, + transactionHashRegex, +} from '@wagmi/test' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { deployContract } from './deployContract.js' +import { disconnect } from './disconnect.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + await expect( + deployContract(config, { + abi: abi.bayc, + bytecode: bytecode.bayc, + args: ['Bored Ape Wagmi Club', 'BAYC', 69420n, 0n], + }), + ).resolves.toMatch(transactionHashRegex) + await disconnect(config, { connector }) +}) + +test('behavior: no funds', async () => { + const data = await connect(config, { connector }) + const connectedAddress = data.accounts[0] + + await testClient.mainnet.setBalance({ + address: connectedAddress, + value: parseEther('0'), + }) + + await expect( + deployContract(config, { + chainId: testClient.mainnet.chain.id, + abi: abi.bayc, + bytecode: bytecode.bayc, + args: ['Bored Ape Wagmi Club', 'BAYC', 69420n, 0n], + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [TransactionExecutionError: The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account. + + This error could arise when the account does not have enough funds to: + - pay for the total gas fee, + - pay for the value to send. + + The cost of the transaction is calculated as \`gas * gas fee + value\`, where: + - \`gas\` is the amount of gas needed for transaction to execute, + - \`gas fee\` is the gas fee, + - \`value\` is the amount of ether to send to the recipient. + + Request Arguments: + chain: undefined (id: 1) + from: 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266 + data: 0x608060405260405180602001604052806000815250600b90805190602001906200002b92919062000484565b506000600f60006101000a81548160ff0219169083151502179055503480156200005457600080fd5b50604051620046d0380380620046d0833981810160405260808110156200007a57600080fd5b81019080805160405193929190846401000000008211156200009b57600080fd5b83820191506020820185811115620000b257600080fd5b8251866001820283011164010000000082111715620000d057600080fd5b8083526020830192505050908051906020019080838360005b8381101562000106578082015181840152602081019050620000e9565b50505050905090810190601f168015620001345780820380516001836020036101000a031916815260200191505b50604052602001805160405193929190846401000000008211156200015857600080fd5b838201915060208201858111156200016f57600080fd5b82518660018202830111640100000000821117156200018d57600080fd5b8083526020830192505050908051906020019080838360005b83811015620001c3578082015181840152602081019050620001a6565b50505050905090810190601f168015620001f15780820380516001836020036101000a031916815260200191505b5060405260200180519060200190929190805190602001909291905050508383620002296301ffc9a760e01b6200037360201b60201c565b81600690805190602001906200024192919062000484565b5080600790805190602001906200025a92919062000484565b50620002736380ac58cd60e01b6200037360201b60201c565b6200028b635b5e139f60e01b6200037360201b60201c565b620002a363780e9d6360e01b6200037360201b60201c565b50506000620002b76200047c60201b60201c565b905080600a60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35081600e81905550620bdd808101601081905550505050506200052a565b63ffffffff60e01b817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916141562000410576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601c8152602001807f4552433136353a20696e76616c696420696e746572666163652069640000000081525060200191505060405180910390fd5b6001600080837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200190815260200160002060006101000a81548160ff02191690831515021790555050565b600033905090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620004c757805160ff1916838001178555620004f8565b82800160010185558215620004f8579182015b82811115620004f7578251825591602001919060010190620004da565b5b5090506200050791906200050b565b5090565b5b80821115620005265760008160009055506001016200050c565b5090565b614196806200053a6000396000f3fe60806040526004361061021a5760003560e01c80636c0360eb11610123578063b0f67427116100ab578063e36d64981161006f578063e36d649814610ddf578063e985e9c514610e0a578063e986655014610e91578063eb8d244414610ea8578063f2fde38b14610ed55761021a565b8063b0f6742714610bac578063b88d4fde14610bc3578063bb8a16bd14610cd5578063c87b56dd14610d00578063cb774d4714610db45761021a565b80637d17fcbe116100f25780637d17fcbe14610a395780638da5cb5b14610a5057806395d89b4114610a91578063a22cb46514610b21578063a723533e14610b7e5761021a565b80636c0360eb1461090257806370a0823114610992578063715018a6146109f75780637a3f451e14610a0e5761021a565b80632f745c59116101a65780634f6ccce7116101755780634f6ccce7146106cb57806355f804b31461071a578063571dff3b146107e2578063607e20e31461080d5780636352211e1461089d5761021a565b80632f745c59146105b357806334918dfd146106225780633ccfd60b1461063957806342842e0e146106505761021a565b8063095ea7b3116101ed578063095ea7b3146103bf578063109695231461041a57806318160ddd146104e257806318e20a381461050d57806323b872dd146105385761021a565b8063018a2c371461021f57806301ffc9a71461025a57806306fdde03146102ca578063081812fc1461035a575b600080fd5b34801561022b57600080fd5b506102586004803603602081101561024257600080fd5b8101908080359060200190929190505050610f26565b005b34801561026657600080fd5b506102b26004803603602081101561027d57600080fd5b8101908080357bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19169060200190929190505050610fdf565b60405180821515815260200191505060405180910390f35b3480156102d657600080fd5b506102df611046565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561031f578082015181840152602081019050610304565b50505050905090810190601f16801561034c5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561036657600080fd5b506103936004803603602081101561037d57600080fd5b81019080803590602001909291905050506110e8565b604051808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b3480156103cb57600080fd5b50610418600480360360408110156103e257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611183565b005b34801561042657600080fd5b506104e06004803603602081101561043d57600080fd5b810190808035906020019064010000000081111561045a57600080fd5b82018360208201111561046c57600080fd5b8035906020019184600183028401116401000000008311171561048e57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f8201169050808301925050505050505091929192905050506112c7565b005b3480156104ee57600080fd5b506104f7611390565b6040518082815260200191505060405180910390f35b34801561051957600080fd5b506105226113a1565b6040518082815260200191505060405180910390f35b34801561054457600080fd5b506105b16004803603606081101561055b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506113a7565b005b3480156105bf57600080fd5b5061060c600480360360408110156105d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061141d565b6040518082815260200191505060405180910390f35b34801561062e57600080fd5b50610637611478565b005b34801561064557600080fd5b5061064e611553565b005b34801561065c57600080fd5b506106c96004803603606081101561067357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611651565b005b3480156106d757600080fd5b50610704600480360360208110156106ee57600080fd5b8101908080359060200190929190505050611671565b6040518082815260200191505060405180910390f35b34801561072657600080fd5b506107e06004803603602081101561073d57600080fd5b810190808035906020019064010000000081111561075a57600080fd5b82018360208201111561076c57600080fd5b8035906020019184600183028401116401000000008311171561078e57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f820116905080830192505050505050509192919290505050611694565b005b3480156107ee57600080fd5b506107f761174f565b6040518082815260200191505060405180910390f35b34801561081957600080fd5b50610822611754565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610862578082015181840152602081019050610847565b50505050905090810190601f16801561088f5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156108a957600080fd5b506108d6600480360360208110156108c057600080fd5b81019080803590602001909291905050506117f2565b604051808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561090e57600080fd5b50610917611829565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561095757808201518184015260208101905061093c565b50505050905090810190601f1680156109845780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561099e57600080fd5b506109e1600480360360208110156109b557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506118cb565b6040518082815260200191505060405180910390f35b348015610a0357600080fd5b50610a0c6119a0565b005b348015610a1a57600080fd5b50610a23611b10565b6040518082815260200191505060405180910390f35b348015610a4557600080fd5b50610a4e611b1c565b005b348015610a5c57600080fd5b50610a65611c4c565b604051808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b348015610a9d57600080fd5b50610aa6611c76565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610ae6578082015181840152602081019050610acb565b50505050905090810190601f168015610b135780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b348015610b2d57600080fd5b50610b7c60048036036040811015610b4457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803515159060200190929190505050611d18565b005b610baa60048036036020811015610b9457600080fd5b8101908080359060200190929190505050611ece565b005b348015610bb857600080fd5b50610bc1612127565b005b348015610bcf57600080fd5b50610cd360048036036080811015610be657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190640100000000811115610c4d57600080fd5b820183602082011115610c5f57600080fd5b80359060200191846001830284011164010000000083111715610c8157600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050919291929050505061220b565b005b348015610ce157600080fd5b50610cea612283565b6040518082815260200191505060405180910390f35b348015610d0c57600080fd5b50610d3960048036036020811015610d2357600080fd5b8101908080359060200190929190505050612289565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610d79578082015181840152602081019050610d5e565b50505050905090810190601f168015610da65780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b348015610dc057600080fd5b50610dc961255a565b6040518082815260200191505060405180910390f35b348015610deb57600080fd5b50610df4612560565b6040518082815260200191505060405180910390f35b348015610e1657600080fd5b50610e7960048036036040811015610e2d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612566565b60405180821515815260200191505060405180910390f35b348015610e9d57600080fd5b50610ea66125fa565b005b348015610eb457600080fd5b50610ebd612764565b60405180821515815260200191505060405180910390f35b348015610ee157600080fd5b50610f2460048036036020811015610ef857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612777565b005b610f2e61296c565b73ffffffffffffffffffffffffffffffffffffffff16610f4c611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614610fd5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b8060108190555050565b6000806000837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200190815260200160002060009054906101000a900460ff169050919050565b606060068054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156110de5780601f106110b3576101008083540402835291602001916110de565b820191906000526020600020905b8154815290600101906020018083116110c157829003601f168201915b5050505050905090565b60006110f382612974565b611148576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c81526020018061408b602c913960400191505060405180910390fd5b6004600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b600061118e826117f2565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415611215576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602181526020018061410f6021913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff1661123461296c565b73ffffffffffffffffffffffffffffffffffffffff16148061126357506112628161125d61296c565b612566565b5b6112b8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526038815260200180613f956038913960400191505060405180910390fd5b6112c28383612991565b505050565b6112cf61296c565b73ffffffffffffffffffffffffffffffffffffffff166112ed611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614611376576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b80600b908051906020019061138c929190613de6565b5050565b600061139c6002612a4a565b905090565b60105481565b6113b86113b261296c565b82612a5f565b61140d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260318152602001806141306031913960400191505060405180910390fd5b611418838383612b53565b505050565b600061147082600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020612d9690919063ffffffff16565b905092915050565b61148061296c565b73ffffffffffffffffffffffffffffffffffffffff1661149e611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614611527576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600f60009054906101000a900460ff1615600f60006101000a81548160ff021916908315150217905550565b61155b61296c565b73ffffffffffffffffffffffffffffffffffffffff16611579611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614611602576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b60004790503373ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f1935050505015801561164d573d6000803e3d6000fd5b5050565b61166c8383836040518060200160405280600081525061220b565b505050565b600080611688836002612db090919063ffffffff16565b50905080915050919050565b61169c61296c565b73ffffffffffffffffffffffffffffffffffffffff166116ba611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614611743576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b61174c81612ddc565b50565b601481565b600b8054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156117ea5780601f106117bf576101008083540402835291602001916117ea565b820191906000526020600020905b8154815290600101906020018083116117cd57829003601f168201915b505050505081565b600061182282604051806060016040528060298152602001613ff7602991396002612df69092919063ffffffff16565b9050919050565b606060098054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156118c15780601f10611896576101008083540402835291602001916118c1565b820191906000526020600020905b8154815290600101906020018083116118a457829003601f168201915b5050505050905090565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611952576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a815260200180613fcd602a913960400191505060405180910390fd5b611999600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020612e15565b9050919050565b6119a861296c565b73ffffffffffffffffffffffffffffffffffffffff166119c6611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614611a4f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff16600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a36000600a60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b67011c37937e08000081565b611b2461296c565b73ffffffffffffffffffffffffffffffffffffffff16611b42611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614611bcb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b6000600d5414611c43576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601d8152602001807f5374617274696e6720696e64657820697320616c72656164792073657400000081525060200191505060405180910390fd5b43600c81905550565b6000600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b606060078054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015611d0e5780601f10611ce357610100808354040283529160200191611d0e565b820191906000526020600020905b815481529060010190602001808311611cf157829003601f168201915b5050505050905090565b611d2061296c565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611dc1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260198152602001807f4552433732313a20617070726f766520746f2063616c6c65720000000000000081525060200191505060405180910390fd5b8060056000611dce61296c565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff16611e7b61296c565b73ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c318360405180821515815260200191505060405180910390a35050565b600f60009054906101000a900460ff16611f50576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f53616c65206d7573742062652061637469766520746f206d696e74204170650081525060200191505060405180910390fd5b6014811115611faa576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180613f746021913960400191505060405180910390fd5b600e54611fc782611fb9611390565b612e2a90919063ffffffff16565b111561201e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260288152602001806140426028913960400191505060405180910390fd5b3461203a8267011c37937e080000612eb290919063ffffffff16565b11156120ae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45746865722076616c75652073656e74206973206e6f7420636f72726563740081525060200191505060405180910390fd5b60005b818110156120ef5760006120c3611390565b9050600e546120d0611390565b10156120e1576120e03382612f38565b5b5080806001019150506120b1565b506000600c541480156121175750600e54612108611390565b148061211657506010544210155b5b156121245743600c819055505b50565b61212f61296c565b73ffffffffffffffffffffffffffffffffffffffff1661214d611c4c565b73ffffffffffffffffffffffffffffffffffffffff16146121d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b60006121e0611390565b905060005b601e811015612207576121fa33828401612f38565b80806001019150506121e5565b5050565b61221c61221661296c565b83612a5f565b612271576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260318152602001806141306031913960400191505060405180910390fd5b61227d84848484612f56565b50505050565b600e5481565b606061229482612974565b6122e9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602f8152602001806140e0602f913960400191505060405180910390fd5b6060600860008481526020019081526020016000208054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156123925780601f1061236757610100808354040283529160200191612392565b820191906000526020600020905b81548152906001019060200180831161237557829003601f168201915b5050505050905060606123a3611829565b90506000815114156123b9578192505050612555565b60008251111561248a5780826040516020018083805190602001908083835b602083106123fb57805182526020820191506020810190506020830392506123d8565b6001836020036101000a03801982511681845116808217855250505050505090500182805190602001908083835b6020831061244c5780518252602082019150602081019050602083039250612429565b6001836020036101000a0380198251168184511680821785525050505050509050019250505060405160208183030381529060405292505050612555565b8061249485612fc8565b6040516020018083805190602001908083835b602083106124ca57805182526020820191506020810190506020830392506124a7565b6001836020036101000a03801982511681845116808217855250505050505090500182805190602001908083835b6020831061251b57805182526020820191506020810190506020830392506124f8565b6001836020036101000a03801982511681845116808217855250505050505090500192505050604051602081830303815290604052925050505b919050565b600d5481565b600c5481565b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b6000600d5414612672576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601d8152602001807f5374617274696e6720696e64657820697320616c72656164792073657400000081525060200191505060405180910390fd5b6000600c5414156126eb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f5374617274696e6720696e64657820626c6f636b206d7573742062652073657481525060200191505060405180910390fd5b600e54600c544060001c816126fc57fe5b06600d8190555060ff61271a600c544361310f90919063ffffffff16565b111561273a57600e54600143034060001c8161273257fe5b06600d819055505b6000600d5414156127625761275b6001600d54612e2a90919063ffffffff16565b600d819055505b565b600f60009054906101000a900460ff1681565b61277f61296c565b73ffffffffffffffffffffffffffffffffffffffff1661279d611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614612826576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614156128ac576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180613ed86026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff16600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a380600a60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600033905090565b600061298a82600261319290919063ffffffff16565b9050919050565b816004600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff16612a04836117f2565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000612a58826000016131ac565b9050919050565b6000612a6a82612974565b612abf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c815260200180613f48602c913960400191505060405180910390fd5b6000612aca836117f2565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161480612b3957508373ffffffffffffffffffffffffffffffffffffffff16612b21846110e8565b73ffffffffffffffffffffffffffffffffffffffff16145b80612b4a5750612b498185612566565b5b91505092915050565b8273ffffffffffffffffffffffffffffffffffffffff16612b73826117f2565b73ffffffffffffffffffffffffffffffffffffffff1614612bdf576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806140b76029913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415612c65576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526024815260200180613efe6024913960400191505060405180910390fd5b612c708383836131bd565b612c7b600082612991565b612ccc81600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206131c290919063ffffffff16565b50612d1e81600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206131dc90919063ffffffff16565b50612d35818360026131f69092919063ffffffff16565b50808273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4505050565b6000612da5836000018361322b565b60001c905092915050565b600080600080612dc386600001866132ae565b915091508160001c8160001c9350935050509250929050565b8060099080519060200190612df2929190613de6565b5050565b6000612e09846000018460001b84613347565b60001c90509392505050565b6000612e238260000161343d565b9050919050565b600080828401905083811015612ea8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600080831415612ec55760009050612f32565b6000828402905082848281612ed657fe5b0414612f2d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602181526020018061406a6021913960400191505060405180910390fd5b809150505b92915050565b612f5282826040518060200160405280600081525061344e565b5050565b612f61848484612b53565b612f6d848484846134bf565b612fc2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526032815260200180613ea66032913960400191505060405180910390fd5b50505050565b60606000821415613010576040518060400160405280600181526020017f3000000000000000000000000000000000000000000000000000000000000000815250905061310a565b600082905060005b6000821461303a578080600101915050600a828161303257fe5b049150613018565b60608167ffffffffffffffff8111801561305357600080fd5b506040519080825280601f01601f1916602001820160405280156130865781602001600182028036833780820191505090505b50905060006001830390508593505b6000841461310257600a84816130a757fe5b0660300160f81b828280600190039350815181106130c157fe5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600a84816130fa57fe5b049350613095565b819450505050505b919050565b600082821115613187576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601e8152602001807f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525060200191505060405180910390fd5b818303905092915050565b60006131a4836000018360001b6136d8565b905092915050565b600081600001805490509050919050565b505050565b60006131d4836000018360001b6136fb565b905092915050565b60006131ee836000018360001b6137e3565b905092915050565b6000613222846000018460001b8473ffffffffffffffffffffffffffffffffffffffff1660001b613853565b90509392505050565b60008183600001805490501161328c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180613e846022913960400191505060405180910390fd5b82600001828154811061329b57fe5b9060005260206000200154905092915050565b60008082846000018054905011613310576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806140206022913960400191505060405180910390fd5b600084600001848154811061332157fe5b906000526020600020906002020190508060000154816001015492509250509250929050565b6000808460010160008581526020019081526020016000205490506000811415839061340e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156133d35780820151818401526020810190506133b8565b50505050905090810190601f1680156134005780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5084600001600182038154811061342157fe5b9060005260206000209060020201600101549150509392505050565b600081600001805490509050919050565b613458838361392f565b61346560008484846134bf565b6134ba576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526032815260200180613ea66032913960400191505060405180910390fd5b505050565b60006134e08473ffffffffffffffffffffffffffffffffffffffff16613b23565b6134ed57600190506136d0565b606061365763150b7a0260e01b61350261296c565b888787604051602401808573ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff16815260200183815260200180602001828103825283818151815260200191508051906020019080838360005b8381101561358657808201518184015260208101905061356b565b50505050905090810190601f1680156135b35780820380516001836020036101000a031916815260200191505b5095505050505050604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050604051806060016040528060328152602001613ea6603291398773ffffffffffffffffffffffffffffffffffffffff16613b369092919063ffffffff16565b9050600081806020019051602081101561367057600080fd5b8101908080519060200190929190505050905063150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614925050505b949350505050565b600080836001016000848152602001908152602001600020541415905092915050565b600080836001016000848152602001908152602001600020549050600081146137d7576000600182039050600060018660000180549050039050600086600001828154811061374657fe5b906000526020600020015490508087600001848154811061376357fe5b906000526020600020018190555060018301876001016000838152602001908152602001600020819055508660000180548061379b57fe5b600190038181906000526020600020016000905590558660010160008781526020019081526020016000206000905560019450505050506137dd565b60009150505b92915050565b60006137ef8383613b4e565b61384857826000018290806001815401808255809150506001900390600052602060002001600090919091909150558260000180549050836001016000848152602001908152602001600020819055506001905061384d565b600090505b92915050565b60008084600101600085815260200190815260200160002054905060008114156138fa57846000016040518060400160405280868152602001858152509080600181540180825580915050600190039060005260206000209060020201600090919091909150600082015181600001556020820151816001015550508460000180549050856001016000868152602001908152602001600020819055506001915050613928565b8285600001600183038154811061390d57fe5b90600052602060002090600202016001018190555060009150505b9392505050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156139d2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4552433732313a206d696e7420746f20746865207a65726f206164647265737381525060200191505060405180910390fd5b6139db81612974565b15613a4e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601c8152602001807f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000081525060200191505060405180910390fd5b613a5a600083836131bd565b613aab81600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206131dc90919063ffffffff16565b50613ac2818360026131f69092919063ffffffff16565b50808273ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a45050565b600080823b905060008111915050919050565b6060613b458484600085613b71565b90509392505050565b600080836001016000848152602001908152602001600020541415905092915050565b606082471015613bcc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180613f226026913960400191505060405180910390fd5b613bd585613b23565b613c47576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601d8152602001807f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000081525060200191505060405180910390fd5b600060608673ffffffffffffffffffffffffffffffffffffffff1685876040518082805190602001908083835b60208310613c975780518252602082019150602081019050602083039250613c74565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d8060008114613cf9576040519150601f19603f3d011682016040523d82523d6000602084013e613cfe565b606091505b5091509150613d0e828286613d1a565b92505050949350505050565b60608315613d2a57829050613ddf565b600083511115613d3d5782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015613da4578082015181840152602081019050613d89565b50505050905090810190601f168015613dd15780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b9392505050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10613e2757805160ff1916838001178555613e55565b82800160010185558215613e55579182015b82811115613e54578251825591602001919060010190613e39565b5b509050613e629190613e66565b5090565b5b80821115613e7f576000816000905550600101613e67565b509056fe456e756d657261626c655365743a20696e646578206f7574206f6620626f756e64734552433732313a207472616e7366657220746f206e6f6e20455243373231526563656976657220696d706c656d656e7465724f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573734552433732313a207472616e7366657220746f20746865207a65726f2061646472657373416464726573733a20696e73756666696369656e742062616c616e636520666f722063616c6c4552433732313a206f70657261746f7220717565727920666f72206e6f6e6578697374656e7420746f6b656e43616e206f6e6c79206d696e7420323020746f6b656e7320617420612074696d654552433732313a20617070726f76652063616c6c6572206973206e6f74206f776e6572206e6f7220617070726f76656420666f7220616c6c4552433732313a2062616c616e636520717565727920666f7220746865207a65726f20616464726573734552433732313a206f776e657220717565727920666f72206e6f6e6578697374656e7420746f6b656e456e756d657261626c654d61703a20696e646578206f7574206f6620626f756e6473507572636861736520776f756c6420657863656564206d617820737570706c79206f662041706573536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f774552433732313a20617070726f76656420717565727920666f72206e6f6e6578697374656e7420746f6b656e4552433732313a207472616e73666572206f6620746f6b656e2074686174206973206e6f74206f776e4552433732314d657461646174613a2055524920717565727920666f72206e6f6e6578697374656e7420746f6b656e4552433732313a20617070726f76616c20746f2063757272656e74206f776e65724552433732313a207472616e736665722063616c6c6572206973206e6f74206f776e6572206e6f7220617070726f766564a2646970667358221220b0e64d1fa6c4dbeb9c6f54607d7e1996943fe27624a80652f57b53fda084621b64736f6c63430007000033000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000002710000000000000000000000000000000000000000000000000000000006080e6d70000000000000000000000000000000000000000000000000000000000000011426f7265644170655961636874436c756200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000044241594300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000010f2c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000014426f72656420417065205761676d6920436c756200000000000000000000000000000000000000000000000000000000000000000000000000000000000000044241594300000000000000000000000000000000000000000000000000000000 + + Details: Insufficient funds for gas * price + value + Version: viem@2.29.2] + `) + + await disconnect(config, { connector }) +}) diff --git a/packages/core/src/actions/deployContract.ts b/packages/core/src/actions/deployContract.ts new file mode 100644 index 0000000000..a688dd7cfd --- /dev/null +++ b/packages/core/src/actions/deployContract.ts @@ -0,0 +1,87 @@ +import type { Abi, Account, Chain, Client, ContractConstructorArgs } from 'viem' +import { + type DeployContractErrorType as viem_DeployContractErrorType, + type DeployContractParameters as viem_DeployContractParameters, + type DeployContractReturnType as viem_DeployContractReturnType, + deployContract as viem_deployContract, +} from 'viem/actions' +import type { Config } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import type { SelectChains } from '../types/chain.js' +import type { + ChainIdParameter, + ConnectorParameter, +} from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' +import { + type GetConnectorClientErrorType, + getConnectorClient, +} from './getConnectorClient.js' + +export type DeployContractParameters< + abi extends Abi | readonly unknown[] = Abi, + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + /// + allArgs = ContractConstructorArgs, + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: Compute< + Omit< + viem_DeployContractParameters< + abi, + chains[key], + Account, + chains[key], + allArgs + >, + 'chain' + > & + ChainIdParameter & + ConnectorParameter + > +}[number] + +export type DeployContractReturnType = viem_DeployContractReturnType + +export type DeployContractErrorType = + // getConnectorClient() + | GetConnectorClientErrorType + // base + | BaseErrorType + | ErrorType + // viem + | viem_DeployContractErrorType + +/** https://wagmi.sh/core/api/actions/deployContract */ +export async function deployContract< + config extends Config, + const abi extends Abi | readonly unknown[], + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: DeployContractParameters, +): Promise { + const { account, chainId, connector, ...rest } = parameters + + let client: Client + if (typeof account === 'object' && account?.type === 'local') + client = config.getClient({ chainId }) + else + client = await getConnectorClient(config, { + account: account ?? undefined, + chainId, + connector, + }) + + const action = getAction(client, viem_deployContract, 'deployContract') + const hash = await action({ + ...(rest as any), + ...(account ? { account } : {}), + chain: chainId ? { id: chainId } : null, + }) + + return hash +} diff --git a/packages/core/src/actions/disconnect.test.ts b/packages/core/src/actions/disconnect.test.ts new file mode 100644 index 0000000000..03d63db7de --- /dev/null +++ b/packages/core/src/actions/disconnect.test.ts @@ -0,0 +1,33 @@ +import { accounts, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { mock } from '../connectors/mock.js' +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' + +const connector = config._internal.connectors.setup(mock({ accounts })) + +test('default', async () => { + await connect(config, { connector }) + expect(config.state.status).toEqual('connected') + await disconnect(config) + expect(config.state.status).toEqual('disconnected') +}) + +test('parameters: connector', async () => { + await connect(config, { connector }) + expect(config.state.status).toEqual('connected') + await disconnect(config, { connector }) + expect(config.state.status).toEqual('disconnected') +}) + +test('behavior: uses next connector on disconnect', async () => { + const connector_ = config._internal.connectors.setup(mock({ accounts })) + await connect(config, { connector: connector_ }) + await connect(config, { connector }) + + expect(config.state.status).toEqual('connected') + await disconnect(config, { connector }) + expect(config.state.status).toEqual('connected') + await disconnect(config, { connector: connector_ }) +}) diff --git a/packages/core/src/actions/disconnect.ts b/packages/core/src/actions/disconnect.ts new file mode 100644 index 0000000000..6efb4c790c --- /dev/null +++ b/packages/core/src/actions/disconnect.ts @@ -0,0 +1,71 @@ +import type { Config, Connection, Connector } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import type { + ConnectorNotConnectedErrorType, + ConnectorNotFoundErrorType, +} from '../errors/config.js' +import type { ConnectorParameter } from '../types/properties.js' + +export type DisconnectParameters = ConnectorParameter + +export type DisconnectReturnType = void + +export type DisconnectErrorType = + | ConnectorNotFoundErrorType + | ConnectorNotConnectedErrorType + // base + | BaseErrorType + | ErrorType + +/** https://wagmi.sh/core/api/actions/disconnect */ +export async function disconnect( + config: Config, + parameters: DisconnectParameters = {}, +): Promise { + let connector: Connector | undefined + if (parameters.connector) connector = parameters.connector + else { + const { connections, current } = config.state + const connection = connections.get(current!) + connector = connection?.connector + } + + const connections = config.state.connections + + if (connector) { + await connector.disconnect() + connector.emitter.off('change', config._internal.events.change) + connector.emitter.off('disconnect', config._internal.events.disconnect) + connector.emitter.on('connect', config._internal.events.connect) + + connections.delete(connector.uid) + } + + config.setState((x) => { + // if no connections exist, move to disconnected state + if (connections.size === 0) + return { + ...x, + connections: new Map(), + current: null, + status: 'disconnected', + } + + // switch over to another connection + const nextConnection = connections.values().next().value as Connection + return { + ...x, + connections: new Map(connections), + current: nextConnection.connector.uid, + } + }) + + // Set recent connector if exists + { + const current = config.state.current + if (!current) return + const connector = config.state.connections.get(current)?.connector + if (!connector) return + await config.storage?.setItem('recentConnectorId', connector.id) + } +} diff --git a/packages/core/src/actions/estimateFeesPerGas.test-d.ts b/packages/core/src/actions/estimateFeesPerGas.test-d.ts new file mode 100644 index 0000000000..dada2ea311 --- /dev/null +++ b/packages/core/src/actions/estimateFeesPerGas.test-d.ts @@ -0,0 +1,41 @@ +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' +import { estimateFeesPerGas } from './estimateFeesPerGas.js' + +test('types', async () => { + const default_ = await estimateFeesPerGas(config) + expectTypeOf(default_).toMatchTypeOf<{ + gasPrice?: undefined + maxFeePerGas: bigint + maxPriorityFeePerGas: bigint + formatted: { + gasPrice?: undefined + maxFeePerGas: string + maxPriorityFeePerGas: string + } + }>() + + const legacy = await estimateFeesPerGas(config, { type: 'legacy' }) + expectTypeOf(legacy).toMatchTypeOf<{ + gasPrice: bigint + maxFeePerGas?: undefined + maxPriorityFeePerGas?: undefined + formatted: { + gasPrice: string + maxFeePerGas?: undefined + maxPriorityFeePerGas?: undefined + } + }>() + + const eip1559 = await estimateFeesPerGas(config, { type: 'eip1559' }) + expectTypeOf(eip1559).toMatchTypeOf<{ + gasPrice?: undefined + maxFeePerGas: bigint + maxPriorityFeePerGas: bigint + formatted: { + gasPrice?: undefined + maxFeePerGas: string + maxPriorityFeePerGas: string + } + }>() +}) diff --git a/packages/core/src/actions/estimateFeesPerGas.test.ts b/packages/core/src/actions/estimateFeesPerGas.test.ts new file mode 100644 index 0000000000..4c5d668b83 --- /dev/null +++ b/packages/core/src/actions/estimateFeesPerGas.test.ts @@ -0,0 +1,16 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { estimateFeesPerGas } from './estimateFeesPerGas.js' + +test('default', async () => { + const result = await estimateFeesPerGas(config) + expect(Object.keys(result)).toMatchInlineSnapshot(` + [ + "formatted", + "gasPrice", + "maxFeePerGas", + "maxPriorityFeePerGas", + ] + `) +}) diff --git a/packages/core/src/actions/estimateFeesPerGas.ts b/packages/core/src/actions/estimateFeesPerGas.ts new file mode 100644 index 0000000000..66915f010a --- /dev/null +++ b/packages/core/src/actions/estimateFeesPerGas.ts @@ -0,0 +1,87 @@ +import { + type Chain, + type FeeValuesEIP1559, + type FeeValuesLegacy, + type FeeValuesType, + formatUnits, +} from 'viem' +import { + type EstimateFeesPerGasErrorType as viem_EstimateFeesPerGasErrorType, + type EstimateFeesPerGasParameters as viem_EstimateFeesPerGasParameters, + type EstimateFeesPerGasReturnType as viem_EstimateFeesPerGasReturnType, + estimateFeesPerGas as viem_estimateFeesPerGas, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Unit } from '../types/unit.js' +import type { Compute } from '../types/utils.js' +import type { UnionCompute, UnionLooseOmit } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' +import { getUnit } from '../utils/getUnit.js' + +export type EstimateFeesPerGasParameters< + type extends FeeValuesType = FeeValuesType, + config extends Config = Config, +> = UnionCompute< + UnionLooseOmit< + viem_EstimateFeesPerGasParameters, + 'chain' + > & + ChainIdParameter & { + /** @deprecated */ + formatUnits?: Unit | undefined + } +> + +export type EstimateFeesPerGasReturnType< + type extends FeeValuesType = FeeValuesType, +> = Compute< + viem_EstimateFeesPerGasReturnType & { + /** @deprecated */ + formatted: UnionCompute< + | (type extends 'legacy' ? FeeValuesLegacy : never) + | (type extends 'eip1559' ? FeeValuesEIP1559 : never) + > + } +> + +export type EstimateFeesPerGasErrorType = viem_EstimateFeesPerGasErrorType + +export async function estimateFeesPerGas< + config extends Config, + type extends FeeValuesType = 'eip1559', +>( + config: config, + parameters: EstimateFeesPerGasParameters = {}, +): Promise> { + const { chainId, formatUnits: units = 'gwei', ...rest } = parameters + + const client = config.getClient({ chainId }) + const action = getAction( + client, + viem_estimateFeesPerGas, + 'estimateFeesPerGas', + ) + + const { gasPrice, maxFeePerGas, maxPriorityFeePerGas } = await action({ + ...rest, + chain: client.chain, + }) + + const unit = getUnit(units) + const formatted = { + gasPrice: gasPrice ? formatUnits(gasPrice, unit) : undefined, + maxFeePerGas: maxFeePerGas ? formatUnits(maxFeePerGas, unit) : undefined, + maxPriorityFeePerGas: maxPriorityFeePerGas + ? formatUnits(maxPriorityFeePerGas, unit) + : undefined, + } + + return { + formatted, + gasPrice, + maxFeePerGas, + maxPriorityFeePerGas, + } as EstimateFeesPerGasReturnType +} diff --git a/packages/core/src/actions/estimateGas.test-d.ts b/packages/core/src/actions/estimateGas.test-d.ts new file mode 100644 index 0000000000..5fc66c0ec0 --- /dev/null +++ b/packages/core/src/actions/estimateGas.test-d.ts @@ -0,0 +1,47 @@ +import { http, parseEther } from 'viem' +import { celo, mainnet } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { type EstimateGasParameters, estimateGas } from './estimateGas.js' + +test('chain formatters', () => { + const config = createConfig({ + chains: [mainnet, celo], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + + type Result = EstimateGasParameters + expectTypeOf().toMatchTypeOf<{ + chainId?: typeof celo.id | typeof mainnet.id | undefined + feeCurrency?: `0x${string}` | undefined + }>() + estimateGas(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + feeCurrency: '0x', + }) + + type Result2 = EstimateGasParameters + expectTypeOf().toMatchTypeOf<{ + feeCurrency?: `0x${string}` | undefined + }>() + estimateGas(config, { + chainId: celo.id, + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + feeCurrency: '0x', + }) + + type Result3 = EstimateGasParameters + expectTypeOf().not.toMatchTypeOf<{ + feeCurrency?: `0x${string}` | undefined + }>() + estimateGas(config, { + chainId: mainnet.id, + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/core/src/actions/estimateGas.test.ts b/packages/core/src/actions/estimateGas.test.ts new file mode 100644 index 0000000000..f0154c55fa --- /dev/null +++ b/packages/core/src/actions/estimateGas.test.ts @@ -0,0 +1,47 @@ +import { accounts, config } from '@wagmi/test' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { mock } from '../connectors/mock.js' +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { estimateGas } from './estimateGas.js' + +const connector = config._internal.connectors.setup(mock({ accounts })) + +test('parameters: account', async () => { + await expect( + estimateGas(config, { + account: accounts[0], + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }), + ).resolves.toMatchInlineSnapshot('21000n') +}) + +test('parameters: connector', async () => { + await connect(config, { connector }) + + await expect( + estimateGas(config, { + connector, + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }), + ).resolves.toMatchInlineSnapshot('21000n') + + await disconnect(config, { connector }) +}) + +test('behavior: no account and not connected', async () => { + await expect( + estimateGas(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ConnectorNotConnectedError: Connector not connected. + + Version: @wagmi/core@x.y.z] + `) +}) diff --git a/packages/core/src/actions/estimateGas.ts b/packages/core/src/actions/estimateGas.ts new file mode 100644 index 0000000000..c049fa42f8 --- /dev/null +++ b/packages/core/src/actions/estimateGas.ts @@ -0,0 +1,73 @@ +import type { Account, Address, Chain } from 'viem' +import { + type EstimateGasErrorType as viem_EstimateGasErrorType, + type EstimateGasParameters as viem_EstimateGasParameters, + type EstimateGasReturnType as viem_EstimateGasReturnType, + estimateGas as viem_estimateGas, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import type { SelectChains } from '../types/chain.js' +import type { + ChainIdParameter, + ConnectorParameter, +} from '../types/properties.js' +import type { UnionCompute, UnionLooseOmit } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' +import { + type GetConnectorClientErrorType, + getConnectorClient, +} from './getConnectorClient.js' + +export type EstimateGasParameters< + config extends Config = Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: UnionCompute< + UnionLooseOmit, 'chain'> & + ChainIdParameter & + ConnectorParameter + > +}[number] + +export type EstimateGasReturnType = viem_EstimateGasReturnType + +export type EstimateGasErrorType = + // getConnectorClient() + | GetConnectorClientErrorType + // base + | BaseErrorType + | ErrorType + // viem + | viem_EstimateGasErrorType + +/** https://wagmi.sh/core/api/actions/estimateGas */ +export async function estimateGas< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, +>( + config: config, + parameters: EstimateGasParameters, +): Promise { + const { chainId, connector, ...rest } = parameters + + let account: Address | Account + if (parameters.account) account = parameters.account + else { + const connectorClient = await getConnectorClient(config, { + account: parameters.account, + chainId, + connector, + }) + account = connectorClient.account + } + + const client = config.getClient({ chainId }) + const action = getAction(client, viem_estimateGas, 'estimateGas') + return action({ ...(rest as viem_EstimateGasParameters), account }) +} diff --git a/packages/core/src/actions/estimateMaxPriorityFeePerGas.test.ts b/packages/core/src/actions/estimateMaxPriorityFeePerGas.test.ts new file mode 100644 index 0000000000..deb969ebec --- /dev/null +++ b/packages/core/src/actions/estimateMaxPriorityFeePerGas.test.ts @@ -0,0 +1,16 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { estimateMaxPriorityFeePerGas } from './estimateMaxPriorityFeePerGas.js' + +test('default', async () => { + await expect(estimateMaxPriorityFeePerGas(config)).resolves.toBeDefined() +}) + +test('parameters: chainId', async () => { + await expect( + estimateMaxPriorityFeePerGas(config, { + chainId: chain.mainnet2.id, + }), + ).resolves.toBeDefined() +}) diff --git a/packages/core/src/actions/estimateMaxPriorityFeePerGas.ts b/packages/core/src/actions/estimateMaxPriorityFeePerGas.ts new file mode 100644 index 0000000000..06378d84fd --- /dev/null +++ b/packages/core/src/actions/estimateMaxPriorityFeePerGas.ts @@ -0,0 +1,49 @@ +import type { Chain } from 'viem' +import { + type EstimateMaxPriorityFeePerGasErrorType as viem_EstimateMaxPriorityFeePerGasErrorType, + type EstimateMaxPriorityFeePerGasParameters as viem_EstimateMaxPriorityFeePerGasParameters, + type EstimateMaxPriorityFeePerGasReturnType as viem_EstimateMaxPriorityFeePerGasReturnType, + estimateMaxPriorityFeePerGas as viem_estimateMaxPriorityFeePerGas, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute, UnionLooseOmit } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type EstimateMaxPriorityFeePerGasParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute< + UnionLooseOmit< + viem_EstimateMaxPriorityFeePerGasParameters & + ChainIdParameter, + 'chain' + > +> + +export type EstimateMaxPriorityFeePerGasReturnType = + viem_EstimateMaxPriorityFeePerGasReturnType + +export type EstimateMaxPriorityFeePerGasErrorType = + viem_EstimateMaxPriorityFeePerGasErrorType + +/** https://wagmi.sh/core/api/actions/estimateMaxPriorityFeePerGas */ +export async function estimateMaxPriorityFeePerGas< + config extends Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + config: config, + parameters: EstimateMaxPriorityFeePerGasParameters = {}, +): Promise { + const { chainId } = parameters + const client = config.getClient({ chainId }) + const action = getAction( + client, + viem_estimateMaxPriorityFeePerGas, + 'estimateMaxPriorityFeePerGas', + ) + return action({ chain: client.chain }) +} diff --git a/packages/core/src/actions/getAccount.test-d.ts b/packages/core/src/actions/getAccount.test-d.ts new file mode 100644 index 0000000000..728468039b --- /dev/null +++ b/packages/core/src/actions/getAccount.test-d.ts @@ -0,0 +1,69 @@ +import { config } from '@wagmi/test' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import type { Connector } from '../createConfig.js' +import { getAccount } from './getAccount.js' + +test('states', () => { + const result = getAccount(config) + + switch (result.status) { + case 'reconnecting': { + expectTypeOf(result).toMatchTypeOf<{ + address: Address | undefined + chain: (typeof config)['chains'][number] | undefined + chainId: number | undefined + connector: Connector | undefined + isConnected: boolean + isConnecting: false + isDisconnected: false + isReconnecting: true + status: 'reconnecting' + }>() + break + } + case 'connecting': { + expectTypeOf(result).toMatchTypeOf<{ + address: Address | undefined + chain: (typeof config)['chains'][number] | undefined + chainId: number | undefined + connector: Connector | undefined + isConnected: false + isReconnecting: false + isConnecting: true + isDisconnected: false + status: 'connecting' + }>() + break + } + case 'connected': { + expectTypeOf(result).toMatchTypeOf<{ + address: Address + chain: (typeof config)['chains'][number] | undefined + chainId: number + connector: Connector + isConnected: true + isConnecting: false + isDisconnected: false + isReconnecting: false + status: 'connected' + }>() + break + } + case 'disconnected': { + expectTypeOf(result).toMatchTypeOf<{ + address: undefined + chain: undefined + chainId: undefined + connector: undefined + isConnected: false + isReconnecting: false + isConnecting: false + isDisconnected: true + status: 'disconnected' + }>() + break + } + } +}) diff --git a/packages/core/src/actions/getAccount.test.ts b/packages/core/src/actions/getAccount.test.ts new file mode 100644 index 0000000000..a538357875 --- /dev/null +++ b/packages/core/src/actions/getAccount.test.ts @@ -0,0 +1,37 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { getAccount } from './getAccount.js' + +test('default', () => { + expect(getAccount(config)).toMatchInlineSnapshot(` + { + "address": undefined, + "addresses": undefined, + "chain": undefined, + "chainId": undefined, + "connector": undefined, + "isConnected": false, + "isConnecting": false, + "isDisconnected": true, + "isReconnecting": false, + "status": "disconnected", + } + `) +}) + +test('behavior: connected', async () => { + let result = getAccount(config) + expect(result.status).toEqual('disconnected') + + await connect(config, { connector: config.connectors[0]! }) + result = getAccount(config) + expect(result.address).toBeDefined() + expect(result.status).toEqual('connected') + + await disconnect(config) + result = getAccount(config) + expect(result.status).toEqual('disconnected') +}) diff --git a/packages/core/src/actions/getAccount.ts b/packages/core/src/actions/getAccount.ts new file mode 100644 index 0000000000..af5daea028 --- /dev/null +++ b/packages/core/src/actions/getAccount.ts @@ -0,0 +1,126 @@ +import type { Address, Chain } from 'viem' + +import type { Config, Connector } from '../createConfig.js' + +export type GetAccountReturnType< + config extends Config = Config, + /// + chain = Config extends config ? Chain : config['chains'][number], +> = + | { + address: Address + addresses: readonly [Address, ...Address[]] + chain: chain | undefined + chainId: number + connector: Connector + isConnected: true + isConnecting: false + isDisconnected: false + isReconnecting: false + status: 'connected' + } + | { + address: Address | undefined + addresses: readonly Address[] | undefined + chain: chain | undefined + chainId: number | undefined + connector: Connector | undefined + isConnected: boolean + isConnecting: false + isDisconnected: false + isReconnecting: true + status: 'reconnecting' + } + | { + address: Address | undefined + addresses: readonly Address[] | undefined + chain: chain | undefined + chainId: number | undefined + connector: Connector | undefined + isConnected: false + isReconnecting: false + isConnecting: true + isDisconnected: false + status: 'connecting' + } + | { + address: undefined + addresses: undefined + chain: undefined + chainId: undefined + connector: undefined + isConnected: false + isReconnecting: false + isConnecting: false + isDisconnected: true + status: 'disconnected' + } + +/** https://wagmi.sh/core/api/actions/getAccount */ +export function getAccount( + config: config, +): GetAccountReturnType { + const uid = config.state.current! + const connection = config.state.connections.get(uid) + const addresses = connection?.accounts + const address = addresses?.[0] + const chain = config.chains.find( + (chain) => chain.id === connection?.chainId, + ) as GetAccountReturnType['chain'] + const status = config.state.status + + switch (status) { + case 'connected': + return { + address: address!, + addresses: addresses!, + chain, + chainId: connection?.chainId!, + connector: connection?.connector!, + isConnected: true, + isConnecting: false, + isDisconnected: false, + isReconnecting: false, + status, + } + case 'reconnecting': + return { + address, + addresses, + chain, + chainId: connection?.chainId, + connector: connection?.connector, + isConnected: !!address, + isConnecting: false, + isDisconnected: false, + isReconnecting: true, + status, + } + case 'connecting': + return { + address, + addresses, + chain, + chainId: connection?.chainId, + connector: connection?.connector, + isConnected: false, + isConnecting: true, + isDisconnected: false, + isReconnecting: false, + status, + } + case 'disconnected': + return { + address: undefined, + addresses: undefined, + chain: undefined, + chainId: undefined, + connector: undefined, + isConnected: false, + isConnecting: false, + isDisconnected: true, + isReconnecting: false, + status, + } + } +} diff --git a/packages/core/src/actions/getBalance.test.ts b/packages/core/src/actions/getBalance.test.ts new file mode 100644 index 0000000000..954c09c2e6 --- /dev/null +++ b/packages/core/src/actions/getBalance.test.ts @@ -0,0 +1,102 @@ +import { accounts, chain, config, testClient } from '@wagmi/test' +import { parseEther } from 'viem' +import { beforeEach, expect, test } from 'vitest' + +import { getBalance } from './getBalance.js' + +const address = accounts[0] + +beforeEach(async () => { + await testClient.mainnet.setBalance({ + address, + value: parseEther('10000'), + }) + await testClient.mainnet.mine({ blocks: 1 }) + await testClient.mainnet2.setBalance({ + address, + value: parseEther('420'), + }) + await testClient.mainnet2.mine({ blocks: 1 }) +}) + +test('default', async () => { + await expect(getBalance(config, { address })).resolves.toMatchInlineSnapshot(` + { + "decimals": 18, + "formatted": "10000", + "symbol": "ETH", + "value": 10000000000000000000000n, + } + `) + + await testClient.mainnet.setBalance({ + address, + value: parseEther('6969.12222215666'), + }) + await expect(getBalance(config, { address })).resolves.toMatchInlineSnapshot(` + { + "decimals": 18, + "formatted": "6969.12222215666", + "symbol": "ETH", + "value": 6969122222156660000000n, + } + `) +}) + +test('parameters: chainId', async () => { + await expect( + getBalance(config, { address, chainId: chain.mainnet2.id }), + ).resolves.toMatchInlineSnapshot(` + { + "decimals": 18, + "formatted": "420", + "symbol": "WAG", + "value": 420000000000000000000n, + } + `) +}) + +test('parameters: token', async () => { + await expect( + getBalance(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + token: '0x6B175474E89094C44Da98b954EedeAC495271d0F', + }), + ).resolves.toMatchInlineSnapshot(` + { + "decimals": 18, + "formatted": "0.559062564299199392", + "symbol": "DAI", + "value": 559062564299199392n, + } + `) +}) + +test('parameters: token (bytes32 symbol)', async () => { + await expect( + getBalance(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + token: '0x9f8f72aa9304c8b593d555f12ef6589cc3a579a2', + }), + ).resolves.toMatchInlineSnapshot(` + { + "decimals": 18, + "formatted": "0", + "symbol": "MKR", + "value": 0n, + } + `) +}) + +test('parameters: unit', async () => { + await expect( + getBalance(config, { address, unit: 'wei' }), + ).resolves.toMatchInlineSnapshot(` + { + "decimals": 18, + "formatted": "10000000000000000000000", + "symbol": "ETH", + "value": 10000000000000000000000n, + } + `) +}) diff --git a/packages/core/src/actions/getBalance.ts b/packages/core/src/actions/getBalance.ts new file mode 100644 index 0000000000..1aae5667b1 --- /dev/null +++ b/packages/core/src/actions/getBalance.ts @@ -0,0 +1,149 @@ +import { type Address, type Hex, formatUnits, hexToString, trim } from 'viem' +import { + type GetBalanceErrorType as viem_GetBalanceErrorType, + type GetBalanceParameters as viem_GetBalanceParameters, + getBalance as viem_getBalance, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Unit } from '../types/unit.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' +import { getUnit } from '../utils/getUnit.js' +import { type ReadContractsErrorType, readContracts } from './readContracts.js' + +export type GetBalanceParameters = Compute< + ChainIdParameter & + viem_GetBalanceParameters & { + /** @deprecated */ + token?: Address | undefined + /** @deprecated */ + unit?: Unit | undefined + } +> + +export type GetBalanceReturnType = { + decimals: number + /** @deprecated */ + formatted: string + symbol: string + value: bigint +} + +export type GetBalanceErrorType = viem_GetBalanceErrorType + +/** https://wagmi.sh/core/api/actions/getBalance */ +export async function getBalance( + config: config, + parameters: GetBalanceParameters, +): Promise { + const { + address, + blockNumber, + blockTag, + chainId, + token: tokenAddress, + unit = 'ether', + } = parameters + + if (tokenAddress) { + try { + return await getTokenBalance(config, { + balanceAddress: address, + chainId, + symbolType: 'string', + tokenAddress, + }) + } catch (error) { + // In the chance that there is an error upon decoding the contract result, + // it could be likely that the contract data is represented as bytes32 instead + // of a string. + if ( + (error as ReadContractsErrorType).name === + 'ContractFunctionExecutionError' + ) { + const balance = await getTokenBalance(config, { + balanceAddress: address, + chainId, + symbolType: 'bytes32', + tokenAddress, + }) + const symbol = hexToString( + trim(balance.symbol as Hex, { dir: 'right' }), + ) + return { ...balance, symbol } + } + throw error + } + } + + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getBalance, 'getBalance') + const value = await action( + blockNumber ? { address, blockNumber } : { address, blockTag }, + ) + const chain = config.chains.find((x) => x.id === chainId) ?? client.chain! + return { + decimals: chain.nativeCurrency.decimals, + formatted: formatUnits(value, getUnit(unit)), + symbol: chain.nativeCurrency.symbol, + value, + } +} + +type GetTokenBalanceParameters = { + balanceAddress: Address + chainId?: number | undefined + symbolType: 'bytes32' | 'string' + tokenAddress: Address + unit?: Unit | undefined +} + +async function getTokenBalance( + config: Config, + parameters: GetTokenBalanceParameters, +) { + const { balanceAddress, chainId, symbolType, tokenAddress, unit } = parameters + const contract = { + abi: [ + { + type: 'function', + name: 'balanceOf', + stateMutability: 'view', + inputs: [{ type: 'address' }], + outputs: [{ type: 'uint256' }], + }, + { + type: 'function', + name: 'decimals', + stateMutability: 'view', + inputs: [], + outputs: [{ type: 'uint8' }], + }, + { + type: 'function', + name: 'symbol', + stateMutability: 'view', + inputs: [], + outputs: [{ type: symbolType }], + }, + ], + address: tokenAddress, + } as const + const [value, decimals, symbol] = await readContracts(config, { + allowFailure: false, + contracts: [ + { + ...contract, + functionName: 'balanceOf', + args: [balanceAddress], + chainId, + }, + { ...contract, functionName: 'decimals', chainId }, + { ...contract, functionName: 'symbol', chainId }, + ] as const, + }) + const formatted = formatUnits(value ?? '0', getUnit(unit ?? decimals)) + return { decimals, formatted, symbol, value } +} diff --git a/packages/core/src/actions/getBlock.test-d.ts b/packages/core/src/actions/getBlock.test-d.ts new file mode 100644 index 0000000000..2344c50267 --- /dev/null +++ b/packages/core/src/actions/getBlock.test-d.ts @@ -0,0 +1,35 @@ +import { http, type Hex } from 'viem' +import { celo, mainnet } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { getBlock } from './getBlock.js' + +test('chain formatters', async () => { + const config = createConfig({ + chains: [celo, mainnet], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + const result = await getBlock(config) + if (result.chainId === celo.id) { + expectTypeOf(result.difficulty).toEqualTypeOf() + expectTypeOf(result.gasLimit).toEqualTypeOf() + expectTypeOf(result.mixHash).toEqualTypeOf() + expectTypeOf(result.nonce).toEqualTypeOf<`0x${string}`>() + expectTypeOf(result.uncles).toEqualTypeOf() + } +}) + +test('chainId', async () => { + const config = createConfig({ + chains: [celo, mainnet], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + const result = await getBlock(config, { + chainId: celo.id, + }) + expectTypeOf(result.difficulty).toEqualTypeOf() + expectTypeOf(result.gasLimit).toEqualTypeOf() + expectTypeOf(result.mixHash).toEqualTypeOf() + expectTypeOf(result.nonce).toEqualTypeOf<`0x${string}`>() +}) diff --git a/packages/core/src/actions/getBlock.test.ts b/packages/core/src/actions/getBlock.test.ts new file mode 100644 index 0000000000..b1e92ba364 --- /dev/null +++ b/packages/core/src/actions/getBlock.test.ts @@ -0,0 +1,153 @@ +import { config, mainnet } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getBlock } from './getBlock.js' + +test('default', async () => { + await expect(getBlock(config)).resolves.toBeDefined() +}) + +test('args: blockNumber', async () => { + const { transactions, ...block } = await getBlock(config, { + blockNumber: mainnet.fork.blockNumber, + }) + expect(transactions).toMatchObject( + expect.arrayContaining([expect.any(String)]), + ) + expect(block).toMatchInlineSnapshot(` + { + "baseFeePerGas": 24076814055n, + "blobGasUsed": undefined, + "chainId": 1, + "difficulty": 0n, + "excessBlobGas": undefined, + "extraData": "0x546974616e2028746974616e6275696c6465722e78797a29", + "gasLimit": 30000000n, + "gasUsed": 26325393n, + "hash": "0xcfa5df46abf1521f68ae72a7f7c4661949f4fb08a3d1296fe8082f6580a414e0", + "logsBloom": "0x2df3b5a24d2d57e7d73f96dbfea3577b1d5fbaacfcb9b5fb86db74d2e4ffd1e48bba050c33edada84fe477213937158c1e95d3da9f457f6f36e3ff0afdffcb667c5ee5f9e3ddffa9db1af6bbf15fcbbca5139717d5eedab4daa63cd8bb7dfa3e976b1e7023e2dc4586cef3caa0b73d6ff2ba3afb989c9f58f6b67bb4ed596c5aeb78cef51f69ad3675df70ffbd2aa6576d7c9e3debd00cccec3b69fc617b8568bfe588f7e126ef591f34ddd0d8b68c28b7ed45b46af3a7bb75c0e2fe4bec54fb772c87ae6f7efcdfb13139b758cfda4d98dffe426fef6d1c2e55f36b5bb1f0a2aef7bcbdf83d31ea646cf6ef3fe9d8b9af2ad4197f7ea2de462bd029fdef7e6f", + "miner": "0x4838b106fce9647bdf1e7877bf73ce8b0bad5f97", + "mixHash": "0x92ac9cd6e57bacd7c7d3e9b087c3907b1c085e284eec2dce7379a847cb4c9940", + "nonce": "0x0000000000000000", + "number": 19258213n, + "parentHash": "0x40cb7885ad596d0397d664a4dc9ef5c2011c09e9a62b386f838f5f5362582ebb", + "receiptsRoot": "0x910a69ba396ab4f59c2c77aa413e941fc4da97a021b8d8bbf12c125bfc42d9d3", + "sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347", + "size": 158252n, + "stateRoot": "0x6e27207d219b0251dbc2fde71f3cde8e33703261f032056453c27275500dddbc", + "timestamp": 1708302299n, + "totalDifficulty": null, + "transactionsRoot": "0x897dba26a3a940b62f86da6e5fec5f71312ad7c871a4031db79dee67442c9d1e", + "uncles": [], + "withdrawals": [ + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x112da72", + "index": "0x21ec946", + "validatorIndex": "0x5cd8e", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x1119345", + "index": "0x21ec947", + "validatorIndex": "0x5cd8f", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x110e2ca", + "index": "0x21ec948", + "validatorIndex": "0x5cd90", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x1119245", + "index": "0x21ec949", + "validatorIndex": "0x5cd91", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x1115a03", + "index": "0x21ec94a", + "validatorIndex": "0x5cd92", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x111cf3f", + "index": "0x21ec94b", + "validatorIndex": "0x5cd93", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x1106006", + "index": "0x21ec94c", + "validatorIndex": "0x5cd94", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x1115bb3", + "index": "0x21ec94d", + "validatorIndex": "0x5cd95", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x111e0d9", + "index": "0x21ec94e", + "validatorIndex": "0x5cd96", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x110829f", + "index": "0x21ec94f", + "validatorIndex": "0x5cd97", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x11029ab", + "index": "0x21ec950", + "validatorIndex": "0x5cd98", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x11140a6", + "index": "0x21ec951", + "validatorIndex": "0x5cd99", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x111396c", + "index": "0x21ec952", + "validatorIndex": "0x5cd9a", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x110de16", + "index": "0x21ec953", + "validatorIndex": "0x5cd9b", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x1121062", + "index": "0x21ec954", + "validatorIndex": "0x5cd9c", + }, + { + "address": "0xb9d7934878b5fb9610b3fe8a5e441e8fad7e293f", + "amount": "0x11188bc", + "index": "0x21ec955", + "validatorIndex": "0x5cd9d", + }, + ], + "withdrawalsRoot": "0x26638497bd55075025ac2362d92bd789ac1232fd50c4b3866565280318027950", + } + `) +}) + +test('args: includeTransactions', async () => { + const { transactions } = await getBlock(config, { + includeTransactions: true, + blockNumber: mainnet.fork.blockNumber, + }) + expect(transactions).toMatchObject( + expect.arrayContaining([expect.any(Object)]), + ) +}) diff --git a/packages/core/src/actions/getBlock.ts b/packages/core/src/actions/getBlock.ts new file mode 100644 index 0000000000..babb52cd41 --- /dev/null +++ b/packages/core/src/actions/getBlock.ts @@ -0,0 +1,74 @@ +import type { BlockTag, Chain } from 'viem' +import { + type GetBlockErrorType as viem_GetBlockErrorType, + type GetBlockParameters as viem_GetBlockParameters, + type GetBlockReturnType as viem_GetBlockReturnType, + getBlock as viem_getBlock, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { SelectChains } from '../types/chain.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute, IsNarrowable } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetBlockParameters< + includeTransactions extends boolean = false, + blockTag extends BlockTag = 'latest', + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute< + viem_GetBlockParameters & + ChainIdParameter +> + +export type GetBlockReturnType< + includeTransactions extends boolean = false, + blockTag extends BlockTag = 'latest', + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = Compute< + { + [key in keyof chains]: viem_GetBlockReturnType< + IsNarrowable extends true ? chains[key] : undefined, + includeTransactions, + blockTag + > & { chainId: chains[key]['id'] } + }[number] +> + +export type GetBlockErrorType = viem_GetBlockErrorType + +/** https://wagmi.sh/core/actions/getBlock */ +export async function getBlock< + config extends Config, + chainId extends config['chains'][number]['id'], + includeTransactions extends boolean = false, + blockTag extends BlockTag = 'latest', +>( + config: config, + parameters: GetBlockParameters< + includeTransactions, + blockTag, + config, + chainId + > = {}, +): Promise> { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getBlock, 'getBlock') + const block = await action(rest) + return { + ...(block as unknown as GetBlockReturnType< + includeTransactions, + blockTag, + config, + chainId + >), + chainId: client.chain.id, + } +} diff --git a/packages/core/src/actions/getBlockNumber.test.ts b/packages/core/src/actions/getBlockNumber.test.ts new file mode 100644 index 0000000000..7e18744e14 --- /dev/null +++ b/packages/core/src/actions/getBlockNumber.test.ts @@ -0,0 +1,8 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getBlockNumber } from './getBlockNumber.js' + +test('default', async () => { + await expect(getBlockNumber(config)).resolves.toBeDefined() +}) diff --git a/packages/core/src/actions/getBlockNumber.ts b/packages/core/src/actions/getBlockNumber.ts new file mode 100644 index 0000000000..ecad7c0f67 --- /dev/null +++ b/packages/core/src/actions/getBlockNumber.ts @@ -0,0 +1,36 @@ +import { + type GetBlockNumberErrorType as viem_GetBlockNumberErrorType, + type GetBlockNumberParameters as viem_GetBlockNumberParameters, + type GetBlockNumberReturnType as viem_GetBlockNumberReturnType, + getBlockNumber as viem_getBlockNumber, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetBlockNumberParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute> + +export type GetBlockNumberReturnType = viem_GetBlockNumberReturnType + +export type GetBlockNumberErrorType = viem_GetBlockNumberErrorType + +/** https://wagmi.sh/core/api/actions/getBlockNumber */ +export function getBlockNumber< + config extends Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + config: config, + parameters: GetBlockNumberParameters = {}, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getBlockNumber, 'getBlockNumber') + return action(rest) +} diff --git a/packages/core/src/actions/getBlockTransactionCount.test.ts b/packages/core/src/actions/getBlockTransactionCount.test.ts new file mode 100644 index 0000000000..d8a593aa00 --- /dev/null +++ b/packages/core/src/actions/getBlockTransactionCount.test.ts @@ -0,0 +1,61 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getBlockTransactionCount } from './getBlockTransactionCount.js' + +test('default', async () => { + await expect(getBlockTransactionCount(config)).resolves.toBeTypeOf('number') +}) + +test('parameters: chainId', async () => { + await expect( + getBlockTransactionCount(config, { chainId: chain.mainnet2.id }), + ).resolves.toBeTypeOf('number') +}) + +test('parameters: blockNumber', async () => { + await expect( + getBlockTransactionCount(config, { blockNumber: 13677382n }), + ).resolves.toBeTypeOf('number') +}) + +test('parameters: blockHash', async () => { + await expect( + getBlockTransactionCount(config, { + blockHash: + '0x6201f37a245850d1f11e4be3ac45bc51bd9d43ee4a127192cad550f351cfa575', + }), + ).resolves.toBeTypeOf('number') +}) + +test('parameters: blockTag', async () => { + await expect( + getBlockTransactionCount(config, { + blockTag: 'earliest', + }), + ).resolves.toBeTypeOf('number') + + await expect( + getBlockTransactionCount(config, { + blockTag: 'finalized', + }), + ).resolves.toBeTypeOf('number') + + await expect( + getBlockTransactionCount(config, { + blockTag: 'latest', + }), + ).resolves.toBeTypeOf('number') + + await expect( + getBlockTransactionCount(config, { + blockTag: 'pending', + }), + ).resolves.toBeTypeOf('number') + + await expect( + getBlockTransactionCount(config, { + blockTag: 'safe', + }), + ).resolves.toBeTypeOf('number') +}) diff --git a/packages/core/src/actions/getBlockTransactionCount.ts b/packages/core/src/actions/getBlockTransactionCount.ts new file mode 100644 index 0000000000..e30aca976a --- /dev/null +++ b/packages/core/src/actions/getBlockTransactionCount.ts @@ -0,0 +1,44 @@ +import { + type GetBlockTransactionCountErrorType as viem_GetBlockTransactionCountErrorType, + type GetBlockTransactionCountParameters as viem_GetBlockTransactionCountParameters, + type GetBlockTransactionCountReturnType as viem_GetBlockTransactionCountReturnType, + getBlockTransactionCount as viem_getBlockTransactionCount, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { UnionCompute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetBlockTransactionCountParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = UnionCompute< + viem_GetBlockTransactionCountParameters & ChainIdParameter +> + +export type GetBlockTransactionCountReturnType = + viem_GetBlockTransactionCountReturnType + +export type GetBlockTransactionCountErrorType = + viem_GetBlockTransactionCountErrorType + +/** https://wagmi.sh/core/api/actions/getBlockTransactionCount */ +export function getBlockTransactionCount< + config extends Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + config: config, + parameters: GetBlockTransactionCountParameters = {}, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction( + client, + viem_getBlockTransactionCount, + 'getBlockTransactionCount', + ) + return action(rest) +} diff --git a/packages/core/src/actions/getBytecode.test.ts b/packages/core/src/actions/getBytecode.test.ts new file mode 100644 index 0000000000..1d5b6bdff9 --- /dev/null +++ b/packages/core/src/actions/getBytecode.test.ts @@ -0,0 +1,45 @@ +import { address, chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getBytecode } from './getBytecode.js' + +test('default', async () => { + await expect( + getBytecode(config, { + address: '0x0000000000000000000000000000000000000000', + }), + ).resolves.toBe(undefined) + + await expect( + getBytecode(config, { + address: address.wagmiMintExample, + }), + ).resolves.toMatch(/^0x.*/) +}) + +test('parameters: blockNumber', async () => { + await expect( + getBytecode(config, { + address: address.wagmiMintExample, + blockNumber: 15564163n, + }), + ).resolves.toBe(undefined) +}) + +test('parameters: blockTag', async () => { + await expect( + getBytecode(config, { + address: address.wagmiMintExample, + blockTag: 'earliest', + }), + ).resolves.toBe(undefined) +}) + +test('parameters: chainId', async () => { + await expect( + getBytecode(config, { + address: address.wagmiMintExample, + chainId: chain.optimism.id, + }), + ).resolves.toBe(undefined) +}) diff --git a/packages/core/src/actions/getBytecode.ts b/packages/core/src/actions/getBytecode.ts new file mode 100644 index 0000000000..2ece822a86 --- /dev/null +++ b/packages/core/src/actions/getBytecode.ts @@ -0,0 +1,30 @@ +import { + type GetBytecodeErrorType as viem_GetBytecodeErrorType, + type GetBytecodeParameters as viem_GetBytecodeParameters, + type GetBytecodeReturnType as viem_GetBytecodeReturnType, + getBytecode as viem_getBytecode, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetBytecodeParameters = Compute< + viem_GetBytecodeParameters & ChainIdParameter +> + +export type GetBytecodeReturnType = viem_GetBytecodeReturnType + +export type GetBytecodeErrorType = viem_GetBytecodeErrorType + +/** https://wagmi.sh/core/api/actions/getBytecode */ +export async function getBytecode( + config: config, + parameters: GetBytecodeParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getBytecode, 'getBytecode') + return action(rest) +} diff --git a/packages/core/src/actions/getCallsStatus.test.ts b/packages/core/src/actions/getCallsStatus.test.ts new file mode 100644 index 0000000000..72978a3c7f --- /dev/null +++ b/packages/core/src/actions/getCallsStatus.test.ts @@ -0,0 +1,70 @@ +import { accounts, config, testClient } from '@wagmi/test' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { getCallsStatus } from './getCallsStatus.js' +import { sendCalls } from './sendCalls.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + const { id } = await sendCalls(config, { + calls: [ + { + data: '0xdeadbeef', + to: accounts[1], + value: parseEther('1'), + }, + { + to: accounts[2], + value: parseEther('2'), + }, + { + to: accounts[3], + value: parseEther('3'), + }, + ], + }) + await testClient.mainnet.mine({ blocks: 1 }) + const { receipts, status } = await getCallsStatus(config, { + id, + }) + + expect(status).toBe('success') + expect( + receipts?.map((x) => ({ ...x, blockHash: undefined })), + ).toMatchInlineSnapshot( + ` + [ + { + "blockHash": undefined, + "blockNumber": 19258214n, + "gasUsed": 21064n, + "logs": [], + "status": "success", + "transactionHash": "0x13c53b2d4d9da424835525349cd66e553330f323d6fb19458b801ae1f7989a41", + }, + { + "blockHash": undefined, + "blockNumber": 19258214n, + "gasUsed": 21000n, + "logs": [], + "status": "success", + "transactionHash": "0xd8397b3e82b061c26a0c2093f1ceca0c3662a512614f7d6370349e89d0eea007", + }, + { + "blockHash": undefined, + "blockNumber": 19258214n, + "gasUsed": 21000n, + "logs": [], + "status": "success", + "transactionHash": "0x4d26e346593d9ea265bb164b115e89aa92df43b0b8778ac75d4ad28e2a22b101", + }, + ] + `, + ) + await disconnect(config, { connector }) +}) diff --git a/packages/core/src/actions/getCallsStatus.ts b/packages/core/src/actions/getCallsStatus.ts new file mode 100644 index 0000000000..85f7a592c5 --- /dev/null +++ b/packages/core/src/actions/getCallsStatus.ts @@ -0,0 +1,27 @@ +import { + type GetCallsStatusErrorType as viem_GetCallsStatusErrorType, + type GetCallsStatusParameters as viem_GetCallsStatusParameters, + type GetCallsStatusReturnType as viem_GetCallsStatusReturnType, + getCallsStatus as viem_getCallsStatus, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ConnectorParameter } from '../types/properties.js' +import { getConnectorClient } from './getConnectorClient.js' + +export type GetCallsStatusParameters = viem_GetCallsStatusParameters & + ConnectorParameter + +export type GetCallsStatusReturnType = viem_GetCallsStatusReturnType + +export type GetCallsStatusErrorType = viem_GetCallsStatusErrorType + +/** https://wagmi.sh/core/api/actions/getCallsStatus */ +export async function getCallsStatus( + config: config, + parameters: GetCallsStatusParameters, +): Promise { + const { connector, id } = parameters + const client = await getConnectorClient(config, { connector }) + return viem_getCallsStatus(client, { id }) +} diff --git a/packages/core/src/actions/getCapabilities.test.ts b/packages/core/src/actions/getCapabilities.test.ts new file mode 100644 index 0000000000..e7c02ec444 --- /dev/null +++ b/packages/core/src/actions/getCapabilities.test.ts @@ -0,0 +1,64 @@ +import { accounts, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { getCapabilities } from './getCapabilities.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + const capabilities = await getCapabilities(config) + expect(capabilities).toMatchInlineSnapshot(` + { + "8453": { + "paymasterService": { + "supported": true, + }, + "sessionKeys": { + "supported": true, + }, + }, + "84532": { + "paymasterService": { + "supported": true, + }, + }, + } + `) + await disconnect(config, { connector }) +}) + +test('args: account', async () => { + await connect(config, { connector }) + const capabilities = await getCapabilities(config, { + account: accounts[1], + }) + expect(capabilities).toMatchInlineSnapshot(` + { + "8453": { + "paymasterService": { + "supported": false, + }, + "sessionKeys": { + "supported": true, + }, + }, + "84532": { + "paymasterService": { + "supported": false, + }, + }, + } + `) + await disconnect(config, { connector }) +}) + +test('behavior: not connected', async () => { + await expect(getCapabilities(config)).rejects.toMatchInlineSnapshot(` + [ConnectorNotConnectedError: Connector not connected. + + Version: @wagmi/core@x.y.z] + `) +}) diff --git a/packages/core/src/actions/getCapabilities.ts b/packages/core/src/actions/getCapabilities.ts new file mode 100644 index 0000000000..ab8ea82bfb --- /dev/null +++ b/packages/core/src/actions/getCapabilities.ts @@ -0,0 +1,39 @@ +import type { Account } from 'viem' +import { + type GetCapabilitiesErrorType as viem_GetCapabilitiesErrorType, + type GetCapabilitiesParameters as viem_GetCapabilitiesParameters, + type GetCapabilitiesReturnType as viem_GetCapabilitiesReturnType, + getCapabilities as viem_getCapabilities, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ConnectorParameter } from '../types/properties.js' +import { getConnectorClient } from './getConnectorClient.js' + +export type GetCapabilitiesParameters< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, +> = viem_GetCapabilitiesParameters & ConnectorParameter + +export type GetCapabilitiesReturnType< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, +> = viem_GetCapabilitiesReturnType + +export type GetCapabilitiesErrorType = viem_GetCapabilitiesErrorType + +/** https://wagmi.sh/core/api/actions/getCapabilities */ +export async function getCapabilities< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, +>( + config: config, + parameters: GetCapabilitiesParameters = {}, +): Promise> { + const { account, chainId, connector } = parameters + const client = await getConnectorClient(config, { account, connector }) + return viem_getCapabilities(client as any, { + account: account as Account, + chainId, + }) +} diff --git a/packages/core/src/actions/getChainId.test.ts b/packages/core/src/actions/getChainId.test.ts new file mode 100644 index 0000000000..3dcedcf085 --- /dev/null +++ b/packages/core/src/actions/getChainId.test.ts @@ -0,0 +1,10 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getChainId } from './getChainId.js' + +test('default', async () => { + expect(getChainId(config)).toEqual(chain.mainnet.id) + config.setState((x) => ({ ...x, chainId: chain.mainnet2.id })) + expect(getChainId(config)).toEqual(chain.mainnet2.id) +}) diff --git a/packages/core/src/actions/getChainId.ts b/packages/core/src/actions/getChainId.ts new file mode 100644 index 0000000000..208602e05b --- /dev/null +++ b/packages/core/src/actions/getChainId.ts @@ -0,0 +1,11 @@ +import type { Config } from '../createConfig.js' + +export type GetChainIdReturnType = + config['chains'][number]['id'] + +/** https://wagmi.sh/core/api/actions/getChainId */ +export function getChainId( + config: config, +): GetChainIdReturnType { + return config.state.chainId +} diff --git a/packages/core/src/actions/getChains.test-d.ts b/packages/core/src/actions/getChains.test-d.ts new file mode 100644 index 0000000000..cd5f04c9c5 --- /dev/null +++ b/packages/core/src/actions/getChains.test-d.ts @@ -0,0 +1,12 @@ +import { type chain, config } from '@wagmi/test' +import type { Chain } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { getChains } from './getChains.js' + +test('default', async () => { + const chains = getChains(config) + expectTypeOf(chains[0]).toEqualTypeOf() + expectTypeOf(chains[2]).toEqualTypeOf() + expectTypeOf(chains[3]).toEqualTypeOf() +}) diff --git a/packages/core/src/actions/getChains.test.ts b/packages/core/src/actions/getChains.test.ts new file mode 100644 index 0000000000..fbaeae7645 --- /dev/null +++ b/packages/core/src/actions/getChains.test.ts @@ -0,0 +1,14 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getChains } from './getChains.js' + +test('default', async () => { + expect(getChains(config)).toEqual([ + chain.mainnet, + chain.mainnet2, + chain.optimism, + ]) + config._internal.chains.setState([chain.mainnet, chain.mainnet2]) + expect(getChains(config)).toEqual([chain.mainnet, chain.mainnet2]) +}) diff --git a/packages/core/src/actions/getChains.ts b/packages/core/src/actions/getChains.ts new file mode 100644 index 0000000000..a91e6e89b4 --- /dev/null +++ b/packages/core/src/actions/getChains.ts @@ -0,0 +1,21 @@ +import type { Chain } from 'viem' +import type { Config } from '../createConfig.js' +import { deepEqual } from '../utils/deepEqual.js' + +export type GetChainsReturnType = readonly [ + ...config['chains'], + ...Chain[], +] + +let previousChains: readonly Chain[] = [] + +/** https://wagmi.sh/core/api/actions/getChains */ +export function getChains( + config: config, +): GetChainsReturnType { + const chains = config.chains + if (deepEqual(previousChains, chains)) + return previousChains as GetChainsReturnType + previousChains = chains + return chains as unknown as GetChainsReturnType +} diff --git a/packages/core/src/actions/getClient.test-d.ts b/packages/core/src/actions/getClient.test-d.ts new file mode 100644 index 0000000000..f64cbae2ce --- /dev/null +++ b/packages/core/src/actions/getClient.test-d.ts @@ -0,0 +1,27 @@ +import { chain, config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { getClient } from './getClient.js' + +test('default', () => { + const client = getClient(config) + expectTypeOf(client.chain).toEqualTypeOf<(typeof config)['chains'][number]>() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('parameters: chainId', () => { + const client = getClient(config, { + chainId: chain.mainnet.id, + }) + expectTypeOf(client.chain).toEqualTypeOf() + expectTypeOf(client.chain).not.toEqualTypeOf() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('behavior: unconfigured chain', () => { + const client = getClient(config, { + // @ts-expect-error + chainId: 123456, + }) + expectTypeOf(client).toEqualTypeOf() +}) diff --git a/packages/core/src/actions/getClient.test.ts b/packages/core/src/actions/getClient.test.ts new file mode 100644 index 0000000000..9eb0fa574b --- /dev/null +++ b/packages/core/src/actions/getClient.test.ts @@ -0,0 +1,17 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getClient } from './getClient.js' + +test('default', () => { + expect(getClient(config)).toBeDefined() +}) + +test('behavior: unconfigured chain', () => { + expect( + getClient(config, { + // @ts-expect-error + chainId: 123456, + }), + ).toBeUndefined() +}) diff --git a/packages/core/src/actions/getClient.ts b/packages/core/src/actions/getClient.ts new file mode 100644 index 0000000000..82f1c6c171 --- /dev/null +++ b/packages/core/src/actions/getClient.ts @@ -0,0 +1,52 @@ +import type { Client } from 'viem' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute, IsNarrowable } from '../types/utils.js' + +export type GetClientParameters< + config extends Config = Config, + chainId extends + | config['chains'][number]['id'] + | number + | undefined = config['chains'][number]['id'], +> = ChainIdParameter + +export type GetClientReturnType< + config extends Config = Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], + /// + resolvedChainId extends + | config['chains'][number]['id'] + | undefined = IsNarrowable< + config['chains'][number]['id'], + number + > extends true + ? IsNarrowable extends true + ? chainId + : config['chains'][number]['id'] + : config['chains'][number]['id'] | undefined, +> = resolvedChainId extends config['chains'][number]['id'] + ? Compute< + Client< + config['_internal']['transports'][resolvedChainId], + Extract + > + > + : undefined + +export function getClient< + config extends Config, + chainId extends config['chains'][number]['id'] | number | undefined, +>( + config: config, + parameters: GetClientParameters = {}, +): GetClientReturnType { + let client = undefined + try { + client = config.getClient(parameters) + } catch {} + return client as GetClientReturnType +} diff --git a/packages/core/src/actions/getConnections.test.ts b/packages/core/src/actions/getConnections.test.ts new file mode 100644 index 0000000000..22e6748cf9 --- /dev/null +++ b/packages/core/src/actions/getConnections.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { getConnections } from './getConnections.js' + +test('default', async () => { + const connector = config.connectors[0]! + expect(getConnections(config)).toEqual([]) + await connect(config, { connector }) + expect(getConnections(config).length).toEqual(1) + await disconnect(config, { connector }) + expect(getConnections(config)).toEqual([]) +}) diff --git a/packages/core/src/actions/getConnections.ts b/packages/core/src/actions/getConnections.ts new file mode 100644 index 0000000000..72cdbc27d7 --- /dev/null +++ b/packages/core/src/actions/getConnections.ts @@ -0,0 +1,16 @@ +import type { Config, Connection } from '../createConfig.js' +import type { Compute } from '../types/utils.js' +import { deepEqual } from '../utils/deepEqual.js' + +export type GetConnectionsReturnType = Compute[] + +let previousConnections: Connection[] = [] + +/** https://wagmi.sh/core/api/actions/getConnections */ +export function getConnections(config: Config): GetConnectionsReturnType { + const connections = [...config.state.connections.values()] + if (config.state.status === 'reconnecting') return previousConnections + if (deepEqual(previousConnections, connections)) return previousConnections + previousConnections = connections + return connections +} diff --git a/packages/core/src/actions/getConnectorClient.test-d.ts b/packages/core/src/actions/getConnectorClient.test-d.ts new file mode 100644 index 0000000000..c4d980a7d5 --- /dev/null +++ b/packages/core/src/actions/getConnectorClient.test-d.ts @@ -0,0 +1,19 @@ +import { chain, config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { getConnectorClient } from './getConnectorClient.js' + +test('default', async () => { + const client = await getConnectorClient(config) + expectTypeOf(client.chain).toEqualTypeOf<(typeof config)['chains'][number]>() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('parameters: chainId', async () => { + const client = await getConnectorClient(config, { + chainId: chain.mainnet.id, + }) + expectTypeOf(client.chain).toEqualTypeOf() + expectTypeOf(client.chain).not.toEqualTypeOf() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) diff --git a/packages/core/src/actions/getConnectorClient.test.ts b/packages/core/src/actions/getConnectorClient.test.ts new file mode 100644 index 0000000000..a9d60f5142 --- /dev/null +++ b/packages/core/src/actions/getConnectorClient.test.ts @@ -0,0 +1,106 @@ +import { address, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import type { Connector } from '../createConfig.js' +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { getConnectorClient } from './getConnectorClient.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + await expect(getConnectorClient(config)).resolves.toBeDefined() + await disconnect(config, { connector }) +}) + +test('parameters: connector', async () => { + const connector2 = config.connectors[1]! + await connect(config, { connector }) + await connect(config, { connector: connector2 }) + await expect(getConnectorClient(config, { connector })).resolves.toBeDefined() + await disconnect(config, { connector }) + await disconnect(config, { connector: connector2 }) +}) + +test.todo('custom connector client') + +test('behavior: account address is checksummed', async () => { + await connect(config, { connector }) + const account = '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266' + const client = await getConnectorClient(config, { account }) + expect(client.account.address).toMatchInlineSnapshot( + '"0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266"', + ) + expect(client.account.address).not.toBe(account) + await disconnect(config, { connector }) +}) + +test('behavior: not connected', async () => { + await expect( + getConnectorClient(config), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ConnectorNotConnectedError: Connector not connected. + + Version: @wagmi/core@x.y.z] + `) +}) + +test('behavior: connector is on different chain', async () => { + await connect(config, { chainId: 1, connector }) + config.setState((state) => { + const uid = state.current! + const connection = state.connections.get(uid)! + return { + ...state, + connections: new Map(state.connections).set(uid, { + ...connection, + chainId: 456, + }), + } + }) + await expect( + getConnectorClient(config, { account: address.usdcHolder }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ConnectorChainMismatchError: The current chain of the connector (id: 1) does not match the connection's chain (id: 456). + + Current Chain ID: 1 + Expected Chain ID: 456 + + Version: @wagmi/core@x.y.z] + `) + await disconnect(config, { connector }) +}) + +test('behavior: account does not exist on connector', async () => { + await connect(config, { connector }) + await expect( + getConnectorClient(config, { account: address.usdcHolder }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ConnectorAccountNotFoundError: Account "0x5414d89a8bF7E99d732BC52f3e6A3Ef461c0C078" not found for connector "Mock Connector". + + Version: @wagmi/core@x.y.z] + `) + await disconnect(config, { connector }) +}) + +test('behavior: reconnecting', async () => { + config.setState((state) => ({ ...state, status: 'reconnecting' })) + const { id, name, type, uid } = connector + await expect( + getConnectorClient(config, { + connector: { + id, + name, + type, + uid, + } as unknown as Connector, + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ConnectorUnavailableReconnectingError: Connector "Mock Connector" unavailable while reconnecting. + + Details: During the reconnection step, the only connector methods guaranteed to be available are: \`id\`, \`name\`, \`type\`, \`uid\`. All other methods are not guaranteed to be available until reconnection completes and connectors are fully restored. This error commonly occurs for connectors that asynchronously inject after reconnection has already started. + Version: @wagmi/core@x.y.z] + `) + config.setState((state) => ({ ...state, status: 'disconnected' })) +}) diff --git a/packages/core/src/actions/getConnectorClient.ts b/packages/core/src/actions/getConnectorClient.ts new file mode 100644 index 0000000000..534ba76bc6 --- /dev/null +++ b/packages/core/src/actions/getConnectorClient.ts @@ -0,0 +1,147 @@ +import { + type Account, + type Address, + type BaseErrorType, + type Client, + createClient, + custom, +} from 'viem' +import { getAddress, parseAccount } from 'viem/utils' + +import type { Config, Connection } from '../createConfig.js' +import type { ErrorType } from '../errors/base.js' +import { + ConnectorAccountNotFoundError, + type ConnectorAccountNotFoundErrorType, + ConnectorChainMismatchError, + type ConnectorChainMismatchErrorType, + ConnectorNotConnectedError, + type ConnectorNotConnectedErrorType, + ConnectorUnavailableReconnectingError, + type ConnectorUnavailableReconnectingErrorType, +} from '../errors/config.js' +import type { + ChainIdParameter, + ConnectorParameter, +} from '../types/properties.js' +import type { Compute } from '../types/utils.js' + +export type GetConnectorClientParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute< + ChainIdParameter & + ConnectorParameter & { + /** + * Account to use for the client. + * + * - `Account | Address`: An Account MUST exist on the connector. + * - `null`: Account MAY NOT exist on the connector. This is useful for + * actions that can infer the account from the connector (e.g. sending a + * call without a connected account – the user will be prompted to select + * an account within the wallet). + */ + account?: Address | Account | null | undefined + } +> + +export type GetConnectorClientReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute< + Client< + config['_internal']['transports'][chainId], + Extract, + Account + > +> + +export type GetConnectorClientErrorType = + | ConnectorAccountNotFoundErrorType + | ConnectorChainMismatchErrorType + | ConnectorNotConnectedErrorType + | ConnectorUnavailableReconnectingErrorType + // base + | BaseErrorType + | ErrorType + +/** https://wagmi.sh/core/api/actions/getConnectorClient */ +export async function getConnectorClient< + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: GetConnectorClientParameters = {}, +): Promise> { + // Get connection + let connection: Connection | undefined + if (parameters.connector) { + const { connector } = parameters + if ( + config.state.status === 'reconnecting' && + !connector.getAccounts && + !connector.getChainId + ) + throw new ConnectorUnavailableReconnectingError({ connector }) + + const [accounts, chainId] = await Promise.all([ + connector.getAccounts().catch((e) => { + if (parameters.account === null) return [] + throw e + }), + connector.getChainId(), + ]) + connection = { + accounts: accounts as readonly [Address, ...Address[]], + chainId, + connector, + } + } else connection = config.state.connections.get(config.state.current!) + if (!connection) throw new ConnectorNotConnectedError() + + const chainId = parameters.chainId ?? connection.chainId + + // Check connector using same chainId as connection + const connectorChainId = await connection.connector.getChainId() + if (connectorChainId !== connection.chainId) + throw new ConnectorChainMismatchError({ + connectionChainId: connection.chainId, + connectorChainId, + }) + + // If connector has custom `getClient` implementation + type Return = GetConnectorClientReturnType + const connector = connection.connector + if (connector.getClient) + return connector.getClient({ chainId }) as unknown as Return + + // Default using `custom` transport + const account = parseAccount(parameters.account ?? connection.accounts[0]!) + if (account) account.address = getAddress(account.address) // TODO: Checksum address as part of `parseAccount`? + + // If account was provided, check that it exists on the connector + if ( + parameters.account && + !connection.accounts.some( + (x) => x.toLowerCase() === account.address.toLowerCase(), + ) + ) + throw new ConnectorAccountNotFoundError({ + address: account.address, + connector, + }) + + const chain = config.chains.find((chain) => chain.id === chainId) + const provider = (await connection.connector.getProvider({ chainId })) as { + request(...args: any): Promise + } + + return createClient({ + account, + chain, + name: 'Connector Client', + transport: (opts) => custom(provider)({ ...opts, retryCount: 0 }), + }) as Return +} diff --git a/packages/core/src/actions/getConnectors.test.ts b/packages/core/src/actions/getConnectors.test.ts new file mode 100644 index 0000000000..d15f5fbb08 --- /dev/null +++ b/packages/core/src/actions/getConnectors.test.ts @@ -0,0 +1,8 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getConnectors } from './getConnectors.js' + +test('default', () => { + expect(getConnectors(config)).toEqual(config.connectors) +}) diff --git a/packages/core/src/actions/getConnectors.ts b/packages/core/src/actions/getConnectors.ts new file mode 100644 index 0000000000..439362d3f4 --- /dev/null +++ b/packages/core/src/actions/getConnectors.ts @@ -0,0 +1,17 @@ +import type { Config, Connector } from '../createConfig.js' +import { deepEqual } from '../utils/deepEqual.js' + +export type GetConnectorsReturnType = + config['connectors'] + +let previousConnectors: readonly Connector[] = [] + +/** https://wagmi.sh/core/api/actions/getConnectors */ +export function getConnectors( + config: config, +): GetConnectorsReturnType { + const connectors = config.connectors + if (deepEqual(previousConnectors, connectors)) return previousConnectors + previousConnectors = connectors + return connectors +} diff --git a/packages/core/src/actions/getEnsAddress.test.ts b/packages/core/src/actions/getEnsAddress.test.ts new file mode 100644 index 0000000000..d120c82ef5 --- /dev/null +++ b/packages/core/src/actions/getEnsAddress.test.ts @@ -0,0 +1,12 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getEnsAddress } from './getEnsAddress.js' + +test('default', async () => { + await expect( + getEnsAddress(config, { name: 'wevm.eth' }), + ).resolves.toMatchInlineSnapshot( + '"0xd2135CfB216b74109775236E36d4b433F1DF507B"', + ) +}) diff --git a/packages/core/src/actions/getEnsAddress.ts b/packages/core/src/actions/getEnsAddress.ts new file mode 100644 index 0000000000..5f882999be --- /dev/null +++ b/packages/core/src/actions/getEnsAddress.ts @@ -0,0 +1,30 @@ +import { + type GetEnsAddressErrorType as viem_GetEnsAddressErrorType, + type GetEnsAddressParameters as viem_GetEnsAddressParameters, + type GetEnsAddressReturnType as viem_GetEnsAddressReturnType, + getEnsAddress as viem_getEnsAddress, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetEnsAddressParameters = Compute< + viem_GetEnsAddressParameters & ChainIdParameter +> + +export type GetEnsAddressReturnType = viem_GetEnsAddressReturnType + +export type GetEnsAddressErrorType = viem_GetEnsAddressErrorType + +/** https://wagmi.sh/core/api/actions/getEnsAddress */ +export function getEnsAddress( + config: config, + parameters: GetEnsAddressParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getEnsAddress, 'getEnsAddress') + return action(rest) +} diff --git a/packages/core/src/actions/getEnsAvatar.test.ts b/packages/core/src/actions/getEnsAvatar.test.ts new file mode 100644 index 0000000000..ed1e830481 --- /dev/null +++ b/packages/core/src/actions/getEnsAvatar.test.ts @@ -0,0 +1,12 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getEnsAvatar } from './getEnsAvatar.js' + +test('default', async () => { + await expect( + getEnsAvatar(config, { + name: 'wevm.eth', + }), + ).resolves.toMatchInlineSnapshot('"https://euc.li/wevm.eth"') +}) diff --git a/packages/core/src/actions/getEnsAvatar.ts b/packages/core/src/actions/getEnsAvatar.ts new file mode 100644 index 0000000000..e6c3855d13 --- /dev/null +++ b/packages/core/src/actions/getEnsAvatar.ts @@ -0,0 +1,30 @@ +import { + type GetEnsAvatarErrorType as viem_GetEnsAvatarErrorType, + type GetEnsAvatarParameters as viem_GetEnsAvatarParameters, + type GetEnsAvatarReturnType as viem_GetEnsAvatarReturnType, + getEnsAvatar as viem_getEnsAvatar, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetEnsAvatarParameters = Compute< + viem_GetEnsAvatarParameters & ChainIdParameter +> + +export type GetEnsAvatarReturnType = viem_GetEnsAvatarReturnType + +export type GetEnsAvatarErrorType = viem_GetEnsAvatarErrorType + +/** https://wagmi.sh/core/api/actions/getEnsAvatar */ +export function getEnsAvatar( + config: config, + parameters: GetEnsAvatarParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getEnsAvatar, 'getEnsAvatar') + return action(rest) +} diff --git a/packages/core/src/actions/getEnsName.test.ts b/packages/core/src/actions/getEnsName.test.ts new file mode 100644 index 0000000000..38d1bae97b --- /dev/null +++ b/packages/core/src/actions/getEnsName.test.ts @@ -0,0 +1,12 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getEnsName } from './getEnsName.js' + +test('default', async () => { + await expect( + getEnsName(config, { + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + }), + ).resolves.toMatchInlineSnapshot('"wevm.eth"') +}) diff --git a/packages/core/src/actions/getEnsName.ts b/packages/core/src/actions/getEnsName.ts new file mode 100644 index 0000000000..e6ab338db4 --- /dev/null +++ b/packages/core/src/actions/getEnsName.ts @@ -0,0 +1,30 @@ +import { + type GetEnsNameErrorType as viem_GetEnsNameErrorType, + type GetEnsNameParameters as viem_GetEnsNameParameters, + type GetEnsNameReturnType as viem_GetEnsNameReturnType, + getEnsName as viem_getEnsName, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetEnsNameParameters = Compute< + viem_GetEnsNameParameters & ChainIdParameter +> + +export type GetEnsNameReturnType = viem_GetEnsNameReturnType + +export type GetEnsNameErrorType = viem_GetEnsNameErrorType + +/** https://wagmi.sh/core/api/actions/getEnsName */ +export function getEnsName( + config: config, + parameters: GetEnsNameParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getEnsName, 'getEnsName') + return action(rest) +} diff --git a/packages/core/src/actions/getEnsResolver.test.ts b/packages/core/src/actions/getEnsResolver.test.ts new file mode 100644 index 0000000000..4bc30be55b --- /dev/null +++ b/packages/core/src/actions/getEnsResolver.test.ts @@ -0,0 +1,14 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getEnsResolver } from './getEnsResolver.js' + +test('default', async () => { + await expect( + getEnsResolver(config, { + name: 'wevm.eth', + }), + ).resolves.toMatchInlineSnapshot( + '"0x4976fb03C32e5B8cfe2b6cCB31c09Ba78EBaBa41"', + ) +}) diff --git a/packages/core/src/actions/getEnsResolver.ts b/packages/core/src/actions/getEnsResolver.ts new file mode 100644 index 0000000000..ab59b7d76c --- /dev/null +++ b/packages/core/src/actions/getEnsResolver.ts @@ -0,0 +1,30 @@ +import { + type GetEnsResolverErrorType as viem_GetEnsResolverErrorType, + type GetEnsResolverParameters as viem_GetEnsResolverParameters, + type GetEnsResolverReturnType as viem_GetEnsResolverReturnType, + getEnsResolver as viem_getEnsResolver, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetEnsResolverParameters = Compute< + viem_GetEnsResolverParameters & ChainIdParameter +> + +export type GetEnsResolverReturnType = viem_GetEnsResolverReturnType + +export type GetEnsResolverErrorType = viem_GetEnsResolverErrorType + +/** https://wagmi.sh/core/api/actions/getEnsResolver */ +export function getEnsResolver( + config: config, + parameters: GetEnsResolverParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getEnsResolver, 'getEnsResolver') + return action(rest) +} diff --git a/packages/core/src/actions/getEnsText.test.ts b/packages/core/src/actions/getEnsText.test.ts new file mode 100644 index 0000000000..63801747d5 --- /dev/null +++ b/packages/core/src/actions/getEnsText.test.ts @@ -0,0 +1,13 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getEnsText } from './getEnsText.js' + +test('default', async () => { + await expect( + getEnsText(config, { + name: 'wevm.eth', + key: 'com.twitter', + }), + ).resolves.toMatchInlineSnapshot('"wevm_dev"') +}) diff --git a/packages/core/src/actions/getEnsText.ts b/packages/core/src/actions/getEnsText.ts new file mode 100644 index 0000000000..d786f72b78 --- /dev/null +++ b/packages/core/src/actions/getEnsText.ts @@ -0,0 +1,30 @@ +import { + type GetEnsTextErrorType as viem_GetEnsTextErrorType, + type GetEnsTextParameters as viem_GetEnsTextParameters, + type GetEnsTextReturnType as viem_GetEnsTextReturnType, + getEnsText as viem_getEnsText, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetEnsTextParameters = Compute< + viem_GetEnsTextParameters & ChainIdParameter +> + +export type GetEnsTextReturnType = viem_GetEnsTextReturnType + +export type GetEnsTextErrorType = viem_GetEnsTextErrorType + +/** https://wagmi.sh/core/api/actions/getEnsText */ +export function getEnsText( + config: config, + parameters: GetEnsTextParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getEnsText, 'getEnsText') + return action(rest) +} diff --git a/packages/core/src/actions/getFeeHistory.test.ts b/packages/core/src/actions/getFeeHistory.test.ts new file mode 100644 index 0000000000..2630381556 --- /dev/null +++ b/packages/core/src/actions/getFeeHistory.test.ts @@ -0,0 +1,63 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getFeeHistory } from './getFeeHistory.js' + +test('default', async () => { + await expect( + getFeeHistory(config, { + blockCount: 4, + rewardPercentiles: [25, 75], + }), + ).resolves.toMatchObject({ + baseFeePerGas: expect.arrayContaining([expect.any(BigInt)]), + gasUsedRatio: expect.arrayContaining([expect.any(Number)]), + oldestBlock: expect.any(BigInt), + reward: expect.any(Array), + }) +}) + +test('parameters: chainId', async () => { + await expect( + getFeeHistory(config, { + blockCount: 4, + rewardPercentiles: [25, 75], + chainId: chain.mainnet2.id, + }), + ).resolves.toMatchObject({ + baseFeePerGas: expect.arrayContaining([expect.any(BigInt)]), + gasUsedRatio: expect.arrayContaining([expect.any(Number)]), + oldestBlock: expect.any(BigInt), + reward: expect.any(Array), + }) +}) + +test('parameters: blockNumber', async () => { + await expect( + getFeeHistory(config, { + blockCount: 4, + rewardPercentiles: [25, 75], + blockNumber: 18677379n, + }), + ).resolves.toMatchObject({ + baseFeePerGas: expect.arrayContaining([expect.any(BigInt)]), + gasUsedRatio: expect.arrayContaining([expect.any(Number)]), + oldestBlock: expect.any(BigInt), + reward: expect.any(Array), + }) +}) + +test('parameters: blockTag', async () => { + await expect( + getFeeHistory(config, { + blockCount: 4, + rewardPercentiles: [25, 75], + blockTag: 'safe', + }), + ).resolves.toMatchObject({ + baseFeePerGas: expect.arrayContaining([expect.any(BigInt)]), + gasUsedRatio: expect.arrayContaining([expect.any(Number)]), + oldestBlock: expect.any(BigInt), + reward: expect.any(Array), + }) +}) diff --git a/packages/core/src/actions/getFeeHistory.ts b/packages/core/src/actions/getFeeHistory.ts new file mode 100644 index 0000000000..9588214139 --- /dev/null +++ b/packages/core/src/actions/getFeeHistory.ts @@ -0,0 +1,36 @@ +import { + type GetFeeHistoryErrorType as viem_GetFeeHistoryErrorType, + type GetFeeHistoryParameters as viem_GetFeeHistoryParameters, + type GetFeeHistoryReturnType as viem_GetFeeHistoryReturnType, + getFeeHistory as viem_getFeeHistory, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetFeeHistoryParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute> + +export type GetFeeHistoryReturnType = viem_GetFeeHistoryReturnType + +export type GetFeeHistoryErrorType = viem_GetFeeHistoryErrorType + +/** https://wagmi.sh/core/api/actions/getFeeHistory */ +export function getFeeHistory< + config extends Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + config: config, + parameters: GetFeeHistoryParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getFeeHistory, 'getFeeHistory') + return action(rest) +} diff --git a/packages/core/src/actions/getGasPrice.test.ts b/packages/core/src/actions/getGasPrice.test.ts new file mode 100644 index 0000000000..64b7ba6fd5 --- /dev/null +++ b/packages/core/src/actions/getGasPrice.test.ts @@ -0,0 +1,21 @@ +import { chain, config, testClient } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getGasPrice } from './getGasPrice.js' + +test('default', async () => { + await testClient.mainnet.setNextBlockBaseFeePerGas({ + baseFeePerGas: 2_000_000_000n, + }) + await expect(getGasPrice(config)).resolves.toBe(3000000000n) +}) + +test('parameters: chainId', async () => { + await testClient.mainnet2.setNextBlockBaseFeePerGas({ + baseFeePerGas: 1_000_000_000n, + }) + await testClient.mainnet2.mine({ blocks: 1 }) + await expect( + getGasPrice(config, { chainId: chain.mainnet2.id }), + ).resolves.toBe(1875000000n) +}) diff --git a/packages/core/src/actions/getGasPrice.ts b/packages/core/src/actions/getGasPrice.ts new file mode 100644 index 0000000000..c6482c44a2 --- /dev/null +++ b/packages/core/src/actions/getGasPrice.ts @@ -0,0 +1,35 @@ +import { + type GetGasPriceErrorType as viem_GetGasPriceErrorType, + type GetGasPriceReturnType as viem_GetGasPriceReturnType, + getGasPrice as viem_getGasPrice, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetGasPriceParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute> + +export type GetGasPriceReturnType = viem_GetGasPriceReturnType + +export type GetGasPriceErrorType = viem_GetGasPriceErrorType + +/** https://wagmi.sh/core/api/actions/getGasPrice */ +export function getGasPrice< + config extends Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + config: config, + parameters: GetGasPriceParameters = {}, +): Promise { + const { chainId } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getGasPrice, 'getGasPrice') + return action({}) +} diff --git a/packages/core/src/actions/getProof.test.ts b/packages/core/src/actions/getProof.test.ts new file mode 100644 index 0000000000..5ff0af2828 --- /dev/null +++ b/packages/core/src/actions/getProof.test.ts @@ -0,0 +1,16 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getProof } from './getProof.js' + +test('default', async () => { + await expect( + getProof(config, { + chainId: chain.optimism.id, + address: '0x4200000000000000000000000000000000000016', + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }), + ).resolves.toBeDefined() +}) diff --git a/packages/core/src/actions/getProof.ts b/packages/core/src/actions/getProof.ts new file mode 100644 index 0000000000..ee9ec218d3 --- /dev/null +++ b/packages/core/src/actions/getProof.ts @@ -0,0 +1,30 @@ +import { + type GetProofErrorType as viem_GetProofErrorType, + type GetProofParameters as viem_GetProofParameters, + type GetProofReturnType as viem_GetProofReturnType, + getProof as viem_getProof, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetProofParameters = Compute< + viem_GetProofParameters & ChainIdParameter +> + +export type GetProofReturnType = viem_GetProofReturnType + +export type GetProofErrorType = viem_GetProofErrorType + +/** https://wagmi.sh/core/api/actions/getProof */ +export async function getProof( + config: config, + parameters: GetProofParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getProof, 'getProof') + return action(rest) +} diff --git a/packages/core/src/actions/getPublicClient.test-d.ts b/packages/core/src/actions/getPublicClient.test-d.ts new file mode 100644 index 0000000000..711f11a29f --- /dev/null +++ b/packages/core/src/actions/getPublicClient.test-d.ts @@ -0,0 +1,27 @@ +import { chain, config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { getPublicClient } from './getPublicClient.js' + +test('default', () => { + const client = getPublicClient(config) + expectTypeOf(client.chain).toEqualTypeOf<(typeof config)['chains'][number]>() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('parameters: chainId', () => { + const client = getPublicClient(config, { + chainId: chain.mainnet.id, + }) + expectTypeOf(client.chain).toEqualTypeOf() + expectTypeOf(client.chain).not.toEqualTypeOf() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('behavior: unconfigured chain', () => { + const client = getPublicClient(config, { + // @ts-expect-error + chainId: 123456, + }) + expectTypeOf(client).toEqualTypeOf() +}) diff --git a/packages/core/src/actions/getPublicClient.test.ts b/packages/core/src/actions/getPublicClient.test.ts new file mode 100644 index 0000000000..c77d0bfb94 --- /dev/null +++ b/packages/core/src/actions/getPublicClient.test.ts @@ -0,0 +1,17 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getPublicClient } from './getPublicClient.js' + +test('default', () => { + expect(getPublicClient(config)).toBeDefined() +}) + +test('behavior: unconfigured chain', () => { + expect( + getPublicClient(config, { + // @ts-expect-error + chainId: 123456, + }), + ).toBeUndefined() +}) diff --git a/packages/core/src/actions/getPublicClient.ts b/packages/core/src/actions/getPublicClient.ts new file mode 100644 index 0000000000..1fbd53ed30 --- /dev/null +++ b/packages/core/src/actions/getPublicClient.ts @@ -0,0 +1,52 @@ +import { type Client, type PublicClient, publicActions } from 'viem' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute, IsNarrowable } from '../types/utils.js' +import { getClient } from './getClient.js' + +export type GetPublicClientParameters< + config extends Config = Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], +> = ChainIdParameter + +export type GetPublicClientReturnType< + config extends Config = Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], + /// + resolvedChainId extends + | config['chains'][number]['id'] + | undefined = IsNarrowable< + config['chains'][number]['id'], + number + > extends true + ? IsNarrowable extends true + ? chainId + : config['chains'][number]['id'] + : config['chains'][number]['id'] | undefined, +> = resolvedChainId extends config['chains'][number]['id'] + ? Compute< + PublicClient< + config['_internal']['transports'][resolvedChainId], + Extract + > + > + : undefined + +export function getPublicClient< + config extends Config, + chainId extends config['chains'][number]['id'] | number | undefined, +>( + config: config, + parameters: GetPublicClientParameters = {}, +): GetPublicClientReturnType { + const client = getClient(config, parameters) + return (client as Client)?.extend(publicActions) as GetPublicClientReturnType< + config, + chainId + > +} diff --git a/packages/core/src/actions/getStorageAt.test.ts b/packages/core/src/actions/getStorageAt.test.ts new file mode 100644 index 0000000000..bc612fe91b --- /dev/null +++ b/packages/core/src/actions/getStorageAt.test.ts @@ -0,0 +1,59 @@ +import { address, chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getStorageAt } from './getStorageAt.js' + +test('default', async () => { + await expect( + getStorageAt(config, { + address: address.wagmiMintExample, + slot: '0x0', + }), + ).resolves.toBe( + '0x7761676d6900000000000000000000000000000000000000000000000000000a', + ) + await expect( + getStorageAt(config, { + address: address.wagmiMintExample, + slot: '0x1', + }), + ).resolves.toBe( + '0x5741474d4900000000000000000000000000000000000000000000000000000a', + ) +}) + +test('parameters: blockNumber', async () => { + await expect( + getStorageAt(config, { + address: address.wagmiMintExample, + blockNumber: 16280770n, + slot: '0x0', + }), + ).resolves.toBe( + '0x7761676d6900000000000000000000000000000000000000000000000000000a', + ) +}) + +test('parameters: blockTag', async () => { + await expect( + getStorageAt(config, { + address: address.wagmiMintExample, + blockTag: 'safe', + slot: '0x0', + }), + ).resolves.toBe( + '0x7761676d6900000000000000000000000000000000000000000000000000000a', + ) +}) + +test('parameters: chainId', async () => { + await expect( + getStorageAt(config, { + address: address.wagmiMintExample, + chainId: chain.optimism.id, + slot: '0x0', + }), + ).resolves.toBe( + '0x0000000000000000000000000000000000000000000000000000000000000000', + ) +}) diff --git a/packages/core/src/actions/getStorageAt.ts b/packages/core/src/actions/getStorageAt.ts new file mode 100644 index 0000000000..a07ec081b7 --- /dev/null +++ b/packages/core/src/actions/getStorageAt.ts @@ -0,0 +1,30 @@ +import { + type GetStorageAtErrorType as viem_GetStorageAtErrorType, + type GetStorageAtParameters as viem_GetStorageAtParameters, + type GetStorageAtReturnType as viem_GetStorageAtReturnType, + getStorageAt as viem_getStorageAt, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetStorageAtParameters = Compute< + viem_GetStorageAtParameters & ChainIdParameter +> + +export type GetStorageAtReturnType = viem_GetStorageAtReturnType + +export type GetStorageAtErrorType = viem_GetStorageAtErrorType + +/** https://wagmi.sh/core/api/actions/getStorageAt */ +export async function getStorageAt( + config: config, + parameters: GetStorageAtParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getStorageAt, 'getStorageAt') + return action(rest) +} diff --git a/packages/core/src/actions/getToken.test.ts b/packages/core/src/actions/getToken.test.ts new file mode 100644 index 0000000000..ed8903f3dd --- /dev/null +++ b/packages/core/src/actions/getToken.test.ts @@ -0,0 +1,84 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getToken } from './getToken.js' + +test('default', async () => { + await expect( + getToken(config, { + address: '0x1f9840a85d5af5bf1d1762f925bdaddc4201f984', + }), + ).resolves.toMatchInlineSnapshot(` + { + "address": "0x1f9840a85d5af5bf1d1762f925bdaddc4201f984", + "decimals": 18, + "name": "Uniswap", + "symbol": "UNI", + "totalSupply": { + "formatted": "1000000000", + "value": 1000000000000000000000000000n, + }, + } + `) +}) + +test('parameters: formatUnits', async () => { + await expect( + getToken(config, { + address: '0x1f9840a85d5af5bf1d1762f925bdaddc4201f984', + formatUnits: 'gwei', + }), + ).resolves.toMatchInlineSnapshot(` + { + "address": "0x1f9840a85d5af5bf1d1762f925bdaddc4201f984", + "decimals": 18, + "name": "Uniswap", + "symbol": "UNI", + "totalSupply": { + "formatted": "1000000000000000000", + "value": 1000000000000000000000000000n, + }, + } + `) +}) + +test('behavior: bytes32 token', async () => { + await expect( + getToken(config, { + address: '0x9f8f72aa9304c8b593d555f12ef6589cc3a579a2', + }), + ).resolves.toMatchInlineSnapshot(` + { + "address": "0x9f8f72aa9304c8b593d555f12ef6589cc3a579a2", + "decimals": 18, + "name": "Maker", + "symbol": "MKR", + "totalSupply": { + "formatted": "977631.036950888222010062", + "value": 977631036950888222010062n, + }, + } + `) +}) + +test('behavior: bogus token', async () => { + await expect( + getToken(config, { + address: '0xa0cf798816d4b9b9866b5330eea46a18382f251e', + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ContractFunctionExecutionError: The contract function "decimals" returned no data ("0x"). + + This could be due to any of the following: + - The contract does not have the function "decimals", + - The parameters passed to the contract function may be invalid, or + - The address is not a contract. + + Contract Call: + address: 0xa0cf798816d4b9b9866b5330eea46a18382f251e + function: decimals() + + Docs: https://viem.sh/docs/contract/multicall + Version: viem@2.29.2] + `) +}) diff --git a/packages/core/src/actions/getToken.ts b/packages/core/src/actions/getToken.ts new file mode 100644 index 0000000000..480a742820 --- /dev/null +++ b/packages/core/src/actions/getToken.ts @@ -0,0 +1,141 @@ +import type { Address, Hex } from 'viem' +import { + ContractFunctionExecutionError, + formatUnits, + hexToString, + trim, +} from 'viem' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Unit } from '../types/unit.js' +import type { Compute } from '../types/utils.js' +import { getUnit } from '../utils/getUnit.js' +import { type ReadContractsErrorType, readContracts } from './readContracts.js' + +export type GetTokenParameters = Compute< + ChainIdParameter & { + address: Address + formatUnits?: Unit | undefined + } +> + +export type GetTokenReturnType = { + address: Address + decimals: number + name: string | undefined + symbol: string | undefined + totalSupply: { + formatted: string + value: bigint + } +} + +export type GetTokenErrorType = ReadContractsErrorType + +/** @deprecated */ +export async function getToken( + config: config, + parameters: GetTokenParameters, +): Promise { + const { address, chainId, formatUnits: unit = 18 } = parameters + + function getAbi(type: type) { + return [ + { + type: 'function', + name: 'decimals', + stateMutability: 'view', + inputs: [], + outputs: [{ type: 'uint8' }], + }, + { + type: 'function', + name: 'name', + stateMutability: 'view', + inputs: [], + outputs: [{ type }], + }, + { + type: 'function', + name: 'symbol', + stateMutability: 'view', + inputs: [], + outputs: [{ type }], + }, + { + type: 'function', + name: 'totalSupply', + stateMutability: 'view', + inputs: [], + outputs: [{ type: 'uint256' }], + }, + ] as const + } + + try { + const abi = getAbi('string') + const contractConfig = { address, abi, chainId } as const + const [decimals, name, symbol, totalSupply] = await readContracts(config, { + allowFailure: true, + contracts: [ + { ...contractConfig, functionName: 'decimals' }, + { ...contractConfig, functionName: 'name' }, + { ...contractConfig, functionName: 'symbol' }, + { ...contractConfig, functionName: 'totalSupply' }, + ] as const, + }) + + // throw if `name` or `symbol` failed + if (name.error instanceof ContractFunctionExecutionError) throw name.error + if (symbol.error instanceof ContractFunctionExecutionError) + throw symbol.error + + // `decimals` and `totalSupply` are required + if (decimals.error) throw decimals.error + if (totalSupply.error) throw totalSupply.error + + return { + address, + decimals: decimals.result, + name: name.result, + symbol: symbol.result, + totalSupply: { + formatted: formatUnits(totalSupply.result!, getUnit(unit)), + value: totalSupply.result, + }, + } + } catch (error) { + // In the chance that there is an error upon decoding the contract result, + // it could be likely that the contract data is represented as bytes32 instead + // of a string. + if (error instanceof ContractFunctionExecutionError) { + const abi = getAbi('bytes32') + const contractConfig = { address, abi, chainId } as const + const [decimals, name, symbol, totalSupply] = await readContracts( + config, + { + allowFailure: false, + contracts: [ + { ...contractConfig, functionName: 'decimals' }, + { ...contractConfig, functionName: 'name' }, + { ...contractConfig, functionName: 'symbol' }, + { ...contractConfig, functionName: 'totalSupply' }, + ] as const, + }, + ) + return { + address, + decimals, + name: hexToString(trim(name as Hex, { dir: 'right' })), + symbol: hexToString(trim(symbol as Hex, { dir: 'right' })), + totalSupply: { + formatted: formatUnits(totalSupply, getUnit(unit)), + value: totalSupply, + }, + } + } + + throw error + } +} diff --git a/packages/core/src/actions/getTransaction.test-d.ts b/packages/core/src/actions/getTransaction.test-d.ts new file mode 100644 index 0000000000..9476b781c1 --- /dev/null +++ b/packages/core/src/actions/getTransaction.test-d.ts @@ -0,0 +1,29 @@ +import { http } from 'viem' +import { celo, mainnet } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { getTransaction } from './getTransaction.js' + +test('chain formatters', async () => { + const config = createConfig({ + chains: [celo, mainnet], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + const result = await getTransaction(config, { hash: '0x123' }) + if (result.chainId === celo.id) { + expectTypeOf(result.feeCurrency).toEqualTypeOf<`0x${string}` | null>() + } +}) + +test('chainId', async () => { + const config = createConfig({ + chains: [celo, mainnet], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + const result = await getTransaction(config, { + hash: '0x123', + chainId: celo.id, + }) + expectTypeOf(result.feeCurrency).toEqualTypeOf<`0x${string}` | null>() +}) diff --git a/packages/core/src/actions/getTransaction.test.ts b/packages/core/src/actions/getTransaction.test.ts new file mode 100644 index 0000000000..3615e6a0d9 --- /dev/null +++ b/packages/core/src/actions/getTransaction.test.ts @@ -0,0 +1,36 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getTransaction } from './getTransaction.js' + +test('default', async () => { + await expect( + getTransaction(config, { + hash: '0xa559259bd2d0e8372421e222ff3545f705b5da60005bd787a23c2e68d6d7fefd', + }), + ).resolves.toMatchInlineSnapshot(` + { + "accessList": [], + "blockHash": "0x61c4e868008b465addd7c0a5da03db28bb9911597c58e239a85dd14dd43fd56a", + "blockNumber": 17488642n, + "chainId": 1, + "from": "0xd2135cfb216b74109775236e36d4b433f1df507b", + "gas": 53671n, + "gasPrice": 15806335296n, + "hash": "0xa559259bd2d0e8372421e222ff3545f705b5da60005bd787a23c2e68d6d7fefd", + "input": "0xa9059cbb0000000000000000000000006acbe090725d8b1cd59fe5f3e0c9c3685ebb77af00000000000000000000000000000000000000000000000000000002540be400", + "maxFeePerGas": 19000000000n, + "maxPriorityFeePerGas": 1000000000n, + "nonce": 29, + "r": "0x60a19c4a708571d2a7c661dc5494542fa2c6ddd8e7dc218e4c4795b6ba7969f5", + "s": "0x7ef2778cc21f5c12861208d0c030e77193a234273e32a1dd5066d7d677aa1ef2", + "to": "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48", + "transactionIndex": 58, + "type": "eip1559", + "typeHex": "0x2", + "v": 1n, + "value": 0n, + "yParity": 1, + } + `) +}) diff --git a/packages/core/src/actions/getTransaction.ts b/packages/core/src/actions/getTransaction.ts new file mode 100644 index 0000000000..0148282811 --- /dev/null +++ b/packages/core/src/actions/getTransaction.ts @@ -0,0 +1,51 @@ +import type { Chain } from 'viem' +import { + type GetTransactionErrorType as viem_GetTransactionErrorType, + type GetTransactionParameters as viem_GetTransactionParameters, + type GetTransactionReturnType as viem_GetTransactionReturnType, + getTransaction as viem_getTransaction, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { SelectChains } from '../types/chain.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute, IsNarrowable } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetTransactionParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute> + +export type GetTransactionReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = Compute< + { + [key in keyof chains]: viem_GetTransactionReturnType< + IsNarrowable extends true ? chains[key] : undefined + > & { chainId: chains[key]['id'] } + }[number] +> + +export type GetTransactionErrorType = viem_GetTransactionErrorType + +/** https://wagmi.sh/core/api/actions/getTransaction */ +export function getTransaction< + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: GetTransactionParameters, +): Promise> { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_getTransaction, 'getTransaction') + return action(rest) as unknown as Promise< + GetTransactionReturnType + > +} diff --git a/packages/core/src/actions/getTransactionConfirmations.test-d.ts b/packages/core/src/actions/getTransactionConfirmations.test-d.ts new file mode 100644 index 0000000000..fd9168dfa2 --- /dev/null +++ b/packages/core/src/actions/getTransactionConfirmations.test-d.ts @@ -0,0 +1,85 @@ +import { config } from '@wagmi/test' +import { mainnet, zkSync } from 'viem/chains' +import { test } from 'vitest' + +import { http } from 'viem' +import { createConfig } from '../createConfig.js' +import { getTransactionConfirmations } from './getTransactionConfirmations.js' + +test('default', async () => { + getTransactionConfirmations(config, { + transactionReceipt: { + blockHash: '0x', + blockNumber: 1n, + contractAddress: '0x', + cumulativeGasUsed: 1n, + effectiveGasPrice: 1n, + from: '0x', + gasUsed: 1n, + l1Fee: 1n, + logs: [], + logsBloom: '0x', + status: 'success', + to: '0x', + transactionHash: '0x', + transactionIndex: 1, + type: 'eip1559', + }, + }) +}) + +test('chain formatters', async () => { + const config = createConfig({ + chains: [mainnet, zkSync], + transports: { [mainnet.id]: http(), [zkSync.id]: http() }, + }) + + const transactionReceipt = { + blockHash: '0x', + blockNumber: 1n, + contractAddress: '0x', + cumulativeGasUsed: 1n, + effectiveGasPrice: 1n, + from: '0x', + gasUsed: 1n, + logsBloom: '0x', + status: 'success', + to: '0x', + transactionHash: '0x', + transactionIndex: 1, + type: 'eip1559', + } as const + + getTransactionConfirmations(config, { + transactionReceipt: { + ...transactionReceipt, + l1BatchNumber: 1n, + l1BatchTxIndex: 1n, + logs: [], + l2ToL1Logs: [], + }, + }) + + getTransactionConfirmations(config, { + chainId: zkSync.id, + transactionReceipt: { + ...transactionReceipt, + l1BatchNumber: 1n, + l1BatchTxIndex: 1n, + logs: [], + l2ToL1Logs: [], + }, + }) + + getTransactionConfirmations(config, { + chainId: mainnet.id, + transactionReceipt: { + ...transactionReceipt, + // @ts-expect-error + l1BatchNumber: 1n, + l1BatchTxIndex: 1n, + logs: [], + l2ToL1Logs: [], + }, + }) +}) diff --git a/packages/core/src/actions/getTransactionConfirmations.test.ts b/packages/core/src/actions/getTransactionConfirmations.test.ts new file mode 100644 index 0000000000..a2f47d6a42 --- /dev/null +++ b/packages/core/src/actions/getTransactionConfirmations.test.ts @@ -0,0 +1,25 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getTransactionConfirmations } from './getTransactionConfirmations.js' +import { getTransactionReceipt } from './getTransactionReceipt.js' + +test('default', async () => { + await expect( + getTransactionConfirmations(config, { + hash: '0xa559259bd2d0e8372421e222ff3545f705b5da60005bd787a23c2e68d6d7fefd', + }), + ).resolves.toBeTypeOf('bigint') +}) + +test('parameters: transactionReceipt', async () => { + const transactionReceipt = await getTransactionReceipt(config, { + hash: '0xa559259bd2d0e8372421e222ff3545f705b5da60005bd787a23c2e68d6d7fefd', + }) + + await expect( + getTransactionConfirmations(config, { + transactionReceipt, + }), + ).resolves.toBeTypeOf('bigint') +}) diff --git a/packages/core/src/actions/getTransactionConfirmations.ts b/packages/core/src/actions/getTransactionConfirmations.ts new file mode 100644 index 0000000000..8baa88cf16 --- /dev/null +++ b/packages/core/src/actions/getTransactionConfirmations.ts @@ -0,0 +1,52 @@ +import type { Chain } from 'viem' +import { + type GetTransactionConfirmationsErrorType as viem_GetTransactionConfirmationsErrorType, + type GetTransactionConfirmationsParameters as viem_GetTransactionConfirmationsParameters, + type GetTransactionConfirmationsReturnType as viem_GetTransactionConfirmationsReturnType, + getTransactionConfirmations as viem_getTransactionConfirmations, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { SelectChains } from '../types/chain.js' +import type { ChainIdParameter } from '../types/properties.js' +import { getAction } from '../utils/getAction.js' + +export type GetTransactionConfirmationsParameters< + config extends Config = Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: viem_GetTransactionConfirmationsParameters< + chains[key] + > & + ChainIdParameter +}[number] + +export type GetTransactionConfirmationsReturnType = + viem_GetTransactionConfirmationsReturnType + +export type GetTransactionConfirmationsErrorType = + viem_GetTransactionConfirmationsErrorType + +/** https://wagmi.sh/core/api/actions/getTransactionConfirmations */ +export function getTransactionConfirmations< + config extends Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], +>( + config: config, + parameters: GetTransactionConfirmationsParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction( + client, + viem_getTransactionConfirmations, + 'getTransactionConfirmations', + ) + return action(rest as viem_GetTransactionConfirmationsParameters) +} diff --git a/packages/core/src/actions/getTransactionCount.test.ts b/packages/core/src/actions/getTransactionCount.test.ts new file mode 100644 index 0000000000..95f0e6ddee --- /dev/null +++ b/packages/core/src/actions/getTransactionCount.test.ts @@ -0,0 +1,50 @@ +import { accounts, chain, config, testClient } from '@wagmi/test' +import { expect, test } from 'vitest' + +import type { BlockTag } from 'viem' +import { getTransactionCount } from './getTransactionCount.js' + +const address = accounts[0] + +test('default', async () => { + await expect(getTransactionCount(config, { address })).resolves.toBeTypeOf( + 'number', + ) +}) + +test('parameters: chainId', async () => { + await testClient.mainnet2.setNonce({ + address, + nonce: 6969, + }) + await testClient.mainnet2.mine({ blocks: 1 }) + await expect( + getTransactionCount(config, { address, chainId: chain.mainnet2.id }), + ).resolves.toBeTypeOf('number') +}) + +test('parameters: blockNumber', async () => { + await expect( + getTransactionCount(config, { address, blockNumber: 13677382n }), + ).resolves.toBeTypeOf('number') +}) + +test.each([ + { blockTag: 'earliest' }, + { blockTag: 'finalized' }, + { blockTag: 'latest' }, + { blockTag: 'pending' }, + { blockTag: 'safe' }, +] as { blockTag: BlockTag; expected: number }[])( + 'parameters: blockTag $blockTag', + async ({ blockTag }) => { + await testClient.mainnet.restart() + + await expect( + getTransactionCount(config, { + address, + blockTag, + }), + ).resolves.toBeTypeOf('number') + }, +) diff --git a/packages/core/src/actions/getTransactionCount.ts b/packages/core/src/actions/getTransactionCount.ts new file mode 100644 index 0000000000..6872e6ede6 --- /dev/null +++ b/packages/core/src/actions/getTransactionCount.ts @@ -0,0 +1,34 @@ +import { + type GetTransactionCountErrorType as viem_GetTransactionCountErrorType, + type GetTransactionCountParameters as viem_GetTransactionCountParameters, + type GetTransactionCountReturnType as viem_GetTransactionCountReturnType, + getTransactionCount as viem_getTransactionCount, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetTransactionCountParameters = + Compute & viem_GetTransactionCountParameters> + +export type GetTransactionCountReturnType = viem_GetTransactionCountReturnType + +export type GetTransactionCountErrorType = viem_GetTransactionCountErrorType + +/** https://wagmi.sh/core/api/actions/getTransactionCount */ +export async function getTransactionCount( + config: config, + parameters: GetTransactionCountParameters, +): Promise { + const { address, blockNumber, blockTag, chainId } = parameters + + const client = config.getClient({ chainId }) + const action = getAction( + client, + viem_getTransactionCount, + 'getTransactionCount', + ) + return action(blockNumber ? { address, blockNumber } : { address, blockTag }) +} diff --git a/packages/core/src/actions/getTransactionReceipt.test-d.ts b/packages/core/src/actions/getTransactionReceipt.test-d.ts new file mode 100644 index 0000000000..e9850eacc7 --- /dev/null +++ b/packages/core/src/actions/getTransactionReceipt.test-d.ts @@ -0,0 +1,36 @@ +import { http } from 'viem' +import { mainnet, zkSync } from 'viem/chains' +import type { ZkSyncL2ToL1Log, ZkSyncLog } from 'viem/zksync' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { getTransactionReceipt } from './getTransactionReceipt.js' + +test('chain formatters', async () => { + const config = createConfig({ + chains: [mainnet, zkSync], + transports: { [mainnet.id]: http(), [zkSync.id]: http() }, + }) + const result = await getTransactionReceipt(config, { hash: '0x123' }) + if (result.chainId === zkSync.id) { + expectTypeOf(result.l1BatchNumber).toEqualTypeOf() + expectTypeOf(result.l1BatchTxIndex).toEqualTypeOf() + expectTypeOf(result.logs).toEqualTypeOf() + expectTypeOf(result.l2ToL1Logs).toEqualTypeOf() + } +}) + +test('chainId', async () => { + const config = createConfig({ + chains: [zkSync], + transports: { [zkSync.id]: http() }, + }) + const result = await getTransactionReceipt(config, { + hash: '0x123', + chainId: zkSync.id, + }) + expectTypeOf(result.l1BatchNumber).toEqualTypeOf() + expectTypeOf(result.l1BatchTxIndex).toEqualTypeOf() + expectTypeOf(result.logs).toEqualTypeOf() + expectTypeOf(result.l2ToL1Logs).toEqualTypeOf() +}) diff --git a/packages/core/src/actions/getTransactionReceipt.test.ts b/packages/core/src/actions/getTransactionReceipt.test.ts new file mode 100644 index 0000000000..82fee0b11f --- /dev/null +++ b/packages/core/src/actions/getTransactionReceipt.test.ts @@ -0,0 +1,35 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getTransaction } from './getTransaction.js' +import { getTransactionReceipt } from './getTransactionReceipt.js' + +test('default', async () => { + const transaction = await getTransaction(config, { + blockNumber: 16280769n, + index: 0, + }) + + await expect( + getTransactionReceipt(config, { + hash: transaction.hash, + }), + ).resolves.toMatchInlineSnapshot(` + { + "blockHash": "0xb932f77cf770d1d1c8f861153eec1e990f5d56b6ffdb4ac06aef3cca51ef37d4", + "blockNumber": 16280769n, + "contractAddress": null, + "cumulativeGasUsed": 21000n, + "effectiveGasPrice": 33427926161n, + "from": "0x043022ef9fca1066024d19d681e2ccf44ff90de3", + "gasUsed": 21000n, + "logs": [], + "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "status": "success", + "to": "0x318a5fb4f1604fc46375a1db9a9018b6e423b345", + "transactionHash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + "transactionIndex": 0, + "type": "legacy", + } + `) +}) diff --git a/packages/core/src/actions/getTransactionReceipt.ts b/packages/core/src/actions/getTransactionReceipt.ts new file mode 100644 index 0000000000..8c06e36ba6 --- /dev/null +++ b/packages/core/src/actions/getTransactionReceipt.ts @@ -0,0 +1,57 @@ +import type { Chain } from 'viem' +import { + type GetTransactionReceiptErrorType as viem_GetTransactionReceiptErrorType, + type GetTransactionReceiptParameters as viem_GetTransactionReceiptParameters, + type GetTransactionReceiptReturnType as viem_GetTransactionReceiptReturnType, + getTransactionReceipt as viem_getTransactionReceipt, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { SelectChains } from '../types/chain.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute, IsNarrowable } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type GetTransactionReceiptParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute< + viem_GetTransactionReceiptParameters & ChainIdParameter +> + +export type GetTransactionReceiptReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = Compute< + { + [key in keyof chains]: viem_GetTransactionReceiptReturnType< + IsNarrowable extends true ? chains[key] : undefined + > & { chainId: chains[key]['id'] } + }[number] +> + +export type GetTransactionReceiptErrorType = viem_GetTransactionReceiptErrorType + +/** https://wagmi.sh/core/api/actions/getTransactionReceipt */ +export async function getTransactionReceipt< + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: GetTransactionReceiptParameters, +): Promise> { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction( + client, + viem_getTransactionReceipt, + 'getTransactionReceipt', + ) + return action(rest) as unknown as Promise< + GetTransactionReceiptReturnType + > +} diff --git a/packages/core/src/actions/getWalletClient.test-d.ts b/packages/core/src/actions/getWalletClient.test-d.ts new file mode 100644 index 0000000000..d1d87f5e97 --- /dev/null +++ b/packages/core/src/actions/getWalletClient.test-d.ts @@ -0,0 +1,22 @@ +import { chain, config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import type { Account } from 'viem' +import { getWalletClient } from './getWalletClient.js' + +test('default', async () => { + const client = await getWalletClient(config) + expectTypeOf(client.chain).toEqualTypeOf<(typeof config)['chains'][number]>() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() + expectTypeOf(client.account).toEqualTypeOf() +}) + +test('parameters: chainId', async () => { + const client = await getWalletClient(config, { + chainId: chain.mainnet.id, + }) + expectTypeOf(client.chain).toEqualTypeOf() + expectTypeOf(client.chain).not.toEqualTypeOf() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() + expectTypeOf(client.account).toEqualTypeOf() +}) diff --git a/packages/core/src/actions/getWalletClient.test.ts b/packages/core/src/actions/getWalletClient.test.ts new file mode 100644 index 0000000000..2350f81b3e --- /dev/null +++ b/packages/core/src/actions/getWalletClient.test.ts @@ -0,0 +1,24 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { getWalletClient } from './getWalletClient.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + await expect(getWalletClient(config)).resolves.toBeDefined() + await disconnect(config, { connector }) +}) + +test('behavior: not connected', async () => { + await expect( + getWalletClient(config), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ConnectorNotConnectedError: Connector not connected. + + Version: @wagmi/core@x.y.z] + `) +}) diff --git a/packages/core/src/actions/getWalletClient.ts b/packages/core/src/actions/getWalletClient.ts new file mode 100644 index 0000000000..bf49668701 --- /dev/null +++ b/packages/core/src/actions/getWalletClient.ts @@ -0,0 +1,50 @@ +import { type Account, type WalletClient, walletActions } from 'viem' + +import type { Config } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import type { Compute } from '../types/utils.js' +import { + type GetConnectorClientErrorType, + type GetConnectorClientParameters, + getConnectorClient, +} from './getConnectorClient.js' + +export type GetWalletClientParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = GetConnectorClientParameters + +export type GetWalletClientReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute< + WalletClient< + config['_internal']['transports'][chainId], + Extract, + Account + > +> + +export type GetWalletClientErrorType = + // getConnectorClient() + | GetConnectorClientErrorType + // base + | BaseErrorType + | ErrorType + +export async function getWalletClient< + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: GetWalletClientParameters = {}, +): Promise> { + const client = await getConnectorClient(config, parameters) + // @ts-ignore + return client.extend(walletActions) as unknown as GetWalletClientReturnType< + config, + chainId + > +} diff --git a/packages/core/src/actions/multicall.test-d.ts b/packages/core/src/actions/multicall.test-d.ts new file mode 100644 index 0000000000..bb70db9989 --- /dev/null +++ b/packages/core/src/actions/multicall.test-d.ts @@ -0,0 +1,106 @@ +import { abi, config } from '@wagmi/test' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { multicall } from './multicall.js' + +test('default', async () => { + const result = await multicall(config, { + chainId: 1, + contracts: [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ], + }) + expectTypeOf(result).toEqualTypeOf< + [ + ( + | { error: Error; result?: undefined; status: 'failure' } + | { error?: undefined; result: bigint; status: 'success' } + ), + ( + | { error: Error; result?: undefined; status: 'failure' } + | { error?: undefined; result: string; status: 'success' } + ), + ] + >() +}) + +test('allowFailure', async () => { + const result = await multicall(config, { + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ], + }) + expectTypeOf(result).toEqualTypeOf<[bigint, string]>() +}) + +test('MulticallParameters', async () => { + type Result = Parameters< + typeof multicall< + typeof config, + [ + { + address: '0x' + abi: typeof abi.viewOverloads + functionName: 'foo' + }, + ] + > + >[1]['contracts'][0] + expectTypeOf().toEqualTypeOf<'foo' | 'bar'>() + expectTypeOf().toEqualTypeOf< + readonly [] | readonly [Address] | readonly [Address, Address] | undefined + >() +}) + +test('overloads', async () => { + const res = await multicall(config, { + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + }, + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x'], + }, + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x', '0x'], + }, + ], + }) + + expectTypeOf(res).toEqualTypeOf< + [number, string, { foo: Address; bar: Address }] + >() +}) diff --git a/packages/core/src/actions/multicall.test.ts b/packages/core/src/actions/multicall.test.ts new file mode 100644 index 0000000000..cf2d7c0ddf --- /dev/null +++ b/packages/core/src/actions/multicall.test.ts @@ -0,0 +1,46 @@ +import { abi, address, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { multicall } from './multicall.js' + +test('default', async () => { + await expect( + multicall(config, { + contracts: [ + { + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + ], + }), + ).resolves.toMatchInlineSnapshot(` + [ + { + "result": 4n, + "status": "success", + }, + ] + `) +}) + +test('allowFailure', async () => { + await expect( + multicall(config, { + allowFailure: false, + contracts: [ + { + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + ], + }), + ).resolves.toMatchInlineSnapshot(` + [ + 4n, + ] + `) +}) diff --git a/packages/core/src/actions/multicall.ts b/packages/core/src/actions/multicall.ts new file mode 100644 index 0000000000..528bb0118e --- /dev/null +++ b/packages/core/src/actions/multicall.ts @@ -0,0 +1,42 @@ +import type { + ContractFunctionParameters, + MulticallErrorType as viem_MulticallErrorType, + MulticallParameters as viem_MulticallParameters, + MulticallReturnType as viem_MulticallReturnType, +} from 'viem' +import { multicall as viem_multicall } from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import { getAction } from '../utils/getAction.js' + +export type MulticallParameters< + contracts extends readonly unknown[] = readonly ContractFunctionParameters[], + allowFailure extends boolean = true, + config extends Config = Config, +> = viem_MulticallParameters & ChainIdParameter + +export type MulticallReturnType< + contracts extends readonly unknown[] = readonly ContractFunctionParameters[], + allowFailure extends boolean = true, +> = viem_MulticallReturnType + +export type MulticallErrorType = viem_MulticallErrorType + +export async function multicall< + config extends Config, + const contracts extends readonly ContractFunctionParameters[], + allowFailure extends boolean = true, +>( + config: config, + parameters: MulticallParameters, +): Promise> { + const { allowFailure = true, chainId, contracts, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_multicall, 'multicall') + return action({ + allowFailure, + contracts, + ...rest, + }) as Promise> +} diff --git a/packages/core/src/actions/prepareTransactionRequest.test-d.ts b/packages/core/src/actions/prepareTransactionRequest.test-d.ts new file mode 100644 index 0000000000..a8a0091157 --- /dev/null +++ b/packages/core/src/actions/prepareTransactionRequest.test-d.ts @@ -0,0 +1,80 @@ +import { accounts, config } from '@wagmi/test' +import { http, parseEther } from 'viem' +import { celo, mainnet } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { + type PrepareTransactionRequestParameters, + prepareTransactionRequest, +} from './prepareTransactionRequest.js' + +const targetAccount = accounts[1] + +test('default', async () => { + const response = await prepareTransactionRequest(config, { + chainId: 1, + to: '0x', + value: parseEther('1'), + }) + const { nonce: _nonce, ...request } = response + request.to + request.chainId + + expectTypeOf(response).toMatchTypeOf<{ + chainId: 1 + }>() +}) + +test('chain formatters', async () => { + const config = createConfig({ + chains: [celo, mainnet], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + + type Result = PrepareTransactionRequestParameters + expectTypeOf().toMatchTypeOf<{ + chainId?: typeof celo.id | typeof mainnet.id | undefined + feeCurrency?: `0x${string}` | undefined + }>() + const request = await prepareTransactionRequest(config, { + to: targetAccount, + value: parseEther('0.01'), + feeCurrency: '0x', + }) + if (request.chainId === celo.id) { + expectTypeOf(request.chainId).toEqualTypeOf(celo.id) + expectTypeOf(request.feeCurrency).toEqualTypeOf<`0x${string}` | undefined>() + } + + type Result2 = PrepareTransactionRequestParameters< + typeof config, + typeof celo.id + > + expectTypeOf().toMatchTypeOf<{ + feeCurrency?: `0x${string}` | undefined + }>() + const request2 = await prepareTransactionRequest(config, { + chainId: celo.id, + to: targetAccount, + value: parseEther('0.01'), + feeCurrency: '0x', + }) + expectTypeOf(request2.chainId).toEqualTypeOf(celo.id) + expectTypeOf(request2.feeCurrency).toEqualTypeOf<`0x${string}` | undefined>() + + type Result3 = PrepareTransactionRequestParameters< + typeof config, + typeof mainnet.id + > + expectTypeOf().not.toMatchTypeOf<{ + feeCurrency?: `0x${string}` | undefined + }>() + prepareTransactionRequest(config, { + chainId: mainnet.id, + to: targetAccount, + value: parseEther('0.01'), + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/core/src/actions/prepareTransactionRequest.test.ts b/packages/core/src/actions/prepareTransactionRequest.test.ts new file mode 100644 index 0000000000..271037af8f --- /dev/null +++ b/packages/core/src/actions/prepareTransactionRequest.test.ts @@ -0,0 +1,108 @@ +import { accounts, config, privateKey } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { parseEther } from 'viem' +import { privateKeyToAccount } from 'viem/accounts' +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { prepareTransactionRequest } from './prepareTransactionRequest.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const request = await prepareTransactionRequest(config, { + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) + + const { + gas: _gas, + maxFeePerGas: _mfpg, + maxPriorityFeePerGas: _mpfpg, + nonce: _nonce, + ...rest + } = request + expect(rest).toMatchInlineSnapshot(` + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + "from": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "to": "0x70997970c51812dc3a010c7d01b50e0d17dc79c8", + "type": "eip1559", + "value": 1000000000000000000n, + } + `) + + await disconnect(config, { connector }) +}) + +test('parameters: account', async () => { + await connect(config, { connector }) + + const request = await prepareTransactionRequest(config, { + account: accounts[0], + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) + + const { + gas: _gas, + maxFeePerGas: _mfpg, + maxPriorityFeePerGas: _mpfpg, + nonce: _nonce, + ...rest + } = request + expect(rest).toMatchInlineSnapshot(` + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + "from": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "to": "0x70997970c51812dc3a010c7d01b50e0d17dc79c8", + "type": "eip1559", + "value": 1000000000000000000n, + } + `) + + await disconnect(config, { connector }) +}) + +test('behavior: local account', async () => { + const account = privateKeyToAccount(privateKey) + + const request = await prepareTransactionRequest(config, { + account, + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) + + const { + gas: _gas, + maxFeePerGas: _mfpg, + maxPriorityFeePerGas: _mpfpg, + nonce: _nonce, + ...rest + } = request + expect(rest).toMatchInlineSnapshot(` + { + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "nonceManager": undefined, + "publicKey": "0x048318535b54105d4a7aae60c08fc45f9687181b4fdfc625bd1a753fa7397fed753547f11ca8696646f2f3acb08e31016afac23e630c5d11f59f61fef57b0d2aa5", + "sign": [Function], + "signAuthorization": [Function], + "signMessage": [Function], + "signTransaction": [Function], + "signTypedData": [Function], + "source": "privateKey", + "type": "local", + }, + "chainId": 1, + "from": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "to": "0x70997970c51812dc3a010c7d01b50e0d17dc79c8", + "type": "eip1559", + "value": 1000000000000000000n, + } + `) +}) diff --git a/packages/core/src/actions/prepareTransactionRequest.ts b/packages/core/src/actions/prepareTransactionRequest.ts new file mode 100644 index 0000000000..36ed81f774 --- /dev/null +++ b/packages/core/src/actions/prepareTransactionRequest.ts @@ -0,0 +1,125 @@ +import type { + Account, + Address, + Chain, + PrepareTransactionRequestErrorType as viem_PrepareTransactionRequestErrorType, + PrepareTransactionRequestParameters as viem_PrepareTransactionRequestParameters, + PrepareTransactionRequestRequest as viem_PrepareTransactionRequestRequest, + PrepareTransactionRequestReturnType as viem_PrepareTransactionRequestReturnType, +} from 'viem' +import { prepareTransactionRequest as viem_prepareTransactionRequest } from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { SelectChains } from '../types/chain.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { + Compute, + IsNarrowable, + UnionCompute, + UnionStrictOmit, +} from '../types/utils.js' +import { getAction } from '../utils/getAction.js' +import { getAccount } from './getAccount.js' + +export type PrepareTransactionRequestParameters< + config extends Config = Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], + request extends viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + > = viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + >, + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: UnionCompute< + UnionStrictOmit< + viem_PrepareTransactionRequestParameters< + chains[key], + Account, + chains[key], + Account | Address, + request extends viem_PrepareTransactionRequestRequest< + chains[key], + chains[key] + > + ? request + : never + >, + 'chain' + > & + ChainIdParameter & { + to: Address + } + > +}[number] + +export type PrepareTransactionRequestReturnType< + config extends Config = Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], + request extends viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + > = viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + >, + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: Compute< + viem_PrepareTransactionRequestReturnType< + IsNarrowable extends true ? chains[key] : undefined, + Account, + chains[key], + Account, + request extends viem_PrepareTransactionRequestRequest< + IsNarrowable extends true ? chains[key] : undefined, + chains[key] + > + ? request + : never + > + > & { + chainId: chains[key]['id'] + } +}[number] + +export type PrepareTransactionRequestErrorType = + viem_PrepareTransactionRequestErrorType + +/** https://wagmi.sh/core/api/actions/prepareTransactionRequest */ +export async function prepareTransactionRequest< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, + const request extends viem_PrepareTransactionRequestRequest< + SelectChains['0'], + SelectChains['0'] + >, +>( + config: config, + parameters: PrepareTransactionRequestParameters, +): Promise> { + const { account: account_, chainId, ...rest } = parameters + + const account = account_ ?? getAccount(config).address + const client = config.getClient({ chainId }) + + const action = getAction( + client, + viem_prepareTransactionRequest, + 'prepareTransactionRequest', + ) + return action({ + ...rest, + ...(account ? { account } : {}), + } as unknown as viem_PrepareTransactionRequestParameters) as unknown as Promise< + PrepareTransactionRequestReturnType + > +} diff --git a/packages/core/src/actions/readContract.test-d.ts b/packages/core/src/actions/readContract.test-d.ts new file mode 100644 index 0000000000..a667ec03e8 --- /dev/null +++ b/packages/core/src/actions/readContract.test-d.ts @@ -0,0 +1,74 @@ +import { abi, config } from '@wagmi/test' +import { assertType, expectTypeOf, test } from 'vitest' + +import { readContract } from './readContract.js' + +test('default', async () => { + const result = await readContract(config, { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }) + expectTypeOf(result).toEqualTypeOf() +}) + +test('overloads', async () => { + const result1 = await readContract(config, { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + }) + assertType(result1) + + const result2 = await readContract(config, { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: [], + }) + assertType(result2) + + const result3 = await readContract(config, { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x'], + }) + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + assertType(result3) + + const result4 = await readContract(config, { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x', '0x'], + }) + assertType<{ + foo: `0x${string}` + bar: `0x${string}` + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + }>(result4) +}) + +test('deployless read (bytecode)', async () => { + const result = await readContract(config, { + code: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }) + expectTypeOf(result).toEqualTypeOf() +}) + +test('deployless read (factory)', async () => { + const result = await readContract(config, { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + factory: '0x', + factoryData: '0x', + }) + expectTypeOf(result).toEqualTypeOf() +}) diff --git a/packages/core/src/actions/readContract.test.ts b/packages/core/src/actions/readContract.test.ts new file mode 100644 index 0000000000..37f0db7e0c --- /dev/null +++ b/packages/core/src/actions/readContract.test.ts @@ -0,0 +1,37 @@ +import { abi, address, bytecode, chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { readContract } from './readContract.js' + +test('default', async () => { + await expect( + readContract(config, { + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }), + ).resolves.toMatchInlineSnapshot('4n') +}) + +test('parameters: chainId', async () => { + await expect( + readContract(config, { + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + chainId: chain.mainnet2.id, + }), + ).resolves.toMatchInlineSnapshot('4n') +}) + +test('parameters: deployless read (bytecode)', async () => { + await expect( + readContract(config, { + abi: abi.wagmiMintExample, + functionName: 'name', + code: bytecode.wagmiMintExample, + }), + ).resolves.toMatchInlineSnapshot(`"wagmi"`) +}) diff --git a/packages/core/src/actions/readContract.ts b/packages/core/src/actions/readContract.ts new file mode 100644 index 0000000000..e01e74e9f2 --- /dev/null +++ b/packages/core/src/actions/readContract.ts @@ -0,0 +1,58 @@ +import type { Abi } from 'viem' +import type { ContractFunctionArgs, ContractFunctionName } from 'viem' +import { + type ReadContractErrorType as viem_ReadContractErrorType, + type ReadContractParameters as viem_ReadContractParameters, + type ReadContractReturnType as viem_ReadContractReturnType, + readContract as viem_readContract, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import { getAction } from '../utils/getAction.js' + +export type ReadContractParameters< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'pure' | 'view' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'pure' | 'view', + functionName + > = ContractFunctionArgs, + config extends Config = Config, +> = viem_ReadContractParameters & + ChainIdParameter + +export type ReadContractReturnType< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'pure' | 'view' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'pure' | 'view', + functionName + > = ContractFunctionArgs, +> = viem_ReadContractReturnType + +export type ReadContractErrorType = viem_ReadContractErrorType + +/** https://wagmi.sh/core/api/actions/readContract */ +export function readContract< + config extends Config, + const abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs, +>( + config: config, + parameters: ReadContractParameters, +): Promise> { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_readContract, 'readContract') + return action(rest as any) +} diff --git a/packages/core/src/actions/readContracts.test-d.ts b/packages/core/src/actions/readContracts.test-d.ts new file mode 100644 index 0000000000..a68b2acab6 --- /dev/null +++ b/packages/core/src/actions/readContracts.test-d.ts @@ -0,0 +1,118 @@ +import { abi, config } from '@wagmi/test' +import { assertType, expectTypeOf, test } from 'vitest' + +import { readContracts } from './readContracts.js' + +test('default', async () => { + const result = await readContracts(config, { + contracts: [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + chainId: 1, + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ], + }) + expectTypeOf(result).toEqualTypeOf< + [ + ( + | { error: Error; result?: undefined; status: 'failure' } + | { error?: undefined; result: bigint; status: 'success' } + ), + ( + | { error: Error; result?: undefined; status: 'failure' } + | { error?: undefined; result: string; status: 'success' } + ), + ] + >() +}) + +test('allowFailure', async () => { + const result = await readContracts(config, { + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ], + }) + expectTypeOf(result).toEqualTypeOf<[bigint, string]>() +}) + +test('overloads', async () => { + const result1 = await readContracts(config, { + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + }, + ], + }) + assertType<[number] | undefined>(result1) + + const result2 = await readContracts(config, { + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: [], + }, + ], + }) + assertType<[number] | undefined>(result2) + + const result3 = await readContracts(config, { + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x'], + }, + ], + }) + assertType<[string] | undefined>(result3) + + const result4 = await readContracts(config, { + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x', '0x'], + }, + ], + }) + assertType< + | [ + { + foo: `0x${string}` + bar: `0x${string}` + }, + ] + | undefined + >(result4) +}) diff --git a/packages/core/src/actions/readContracts.test.ts b/packages/core/src/actions/readContracts.test.ts new file mode 100644 index 0000000000..4bc33f60da --- /dev/null +++ b/packages/core/src/actions/readContracts.test.ts @@ -0,0 +1,678 @@ +import { abi, address, chain } from '@wagmi/test' +import { http, type MulticallResponse } from 'viem' +import { expect, expectTypeOf, test, vi } from 'vitest' + +import { createConfig } from '../createConfig.js' +import * as multicall from './multicall.js' +import * as readContract from './readContract.js' +import { readContracts } from './readContracts.js' + +const contracts = [ + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + functionName: 'love', + args: ['0x27a69ffba1e939ddcfecc8c7e0f967b872bac65c'], + }, + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + functionName: 'love', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + functionName: 'getAlive', + }, + { + abi: abi.mloot, + address: address.mloot, + functionName: 'tokenOfOwnerByIndex', + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', 0n], + }, +] + +const { mainnet, mainnet2, optimism } = chain + +const config = createConfig({ + chains: [ + { ...mainnet, contracts: { multicall3: undefined } }, + { ...mainnet2, contracts: { multicall3: undefined } }, + ], + transports: { + [mainnet.id]: http(), + [mainnet2.id]: http(), + }, +}) + +test('default', async () => { + const spy = vi.spyOn(multicall, 'multicall') + const config = createConfig({ + chains: [mainnet, mainnet2], + transports: { + [mainnet.id]: http(), + [mainnet2.id]: http(), + }, + }) + const results = await readContracts(config, { contracts }) + + expect(spy).toHaveBeenCalledWith(config, { + allowFailure: true, + contracts, + chainId: mainnet.id, + }) + expect(results).toMatchInlineSnapshot(` + [ + { + "result": 2n, + "status": "success", + }, + { + "result": 1n, + "status": "success", + }, + { + "result": false, + "status": "success", + }, + { + "result": 370395n, + "status": "success", + }, + ] + `) +}) + +test.skip('falls back to readContract if multicall is not available', async () => { + const spy = vi.spyOn(readContract, 'readContract') + const config = createConfig({ + chains: [mainnet, { ...mainnet2, contracts: { multicall3: undefined } }], + transports: { + [mainnet.id]: http(), + [mainnet2.id]: http(), + }, + }) + const chainId = mainnet2.id + const contracts = [ + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet2.id, + functionName: 'love', + args: ['0x27a69ffba1e939ddcfecc8c7e0f967b872bac65c'], + }, + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet2.id, + functionName: 'love', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet2.id, + functionName: 'getAlive', + }, + { + abi: abi.mloot, + address: address.mloot, + chainId: mainnet2.id, + functionName: 'tokenOfOwnerByIndex', + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', 0n], + }, + ] as const + const results = await readContracts(config, { contracts }) + expectTypeOf(results).toEqualTypeOf< + [ + MulticallResponse, + MulticallResponse, + MulticallResponse, + MulticallResponse, + ] + >() + + for (const contract of contracts) { + expect(spy).toBeCalledWith(config, { ...contract, chainId }) + } + expect(results).toMatchInlineSnapshot(` + [ + { + "result": 2n, + "status": "success", + }, + { + "result": 1n, + "status": "success", + }, + { + "result": false, + "status": "success", + }, + { + "result": 370395n, + "status": "success", + }, + ] + `) +}) + +test.skip('multichain', async () => { + const config = createConfig({ + chains: [mainnet, mainnet2, optimism], + transports: { + [mainnet.id]: http(), + [mainnet2.id]: http(), + [optimism.id]: http(), + }, + }) + + const spy = vi.spyOn(multicall, 'multicall') + const mainnetContracts = [ + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet.id, + functionName: 'love', + args: ['0x27a69ffba1e939ddcfecc8c7e0f967b872bac65c'], + }, + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet.id, + functionName: 'love', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet.id, + functionName: 'love', + args: ['0xd2135CfB216b74109775236E36d4b433F1DF507B'], + }, + ] as const + const mainnet2Contracts = [ + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet2.id, + functionName: 'getAlive', + }, + { + abi: abi.mloot, + address: address.mloot, + chainId: mainnet2.id, + functionName: 'tokenOfOwnerByIndex', + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', 0n], + }, + ] as const + const optimismContracts = [ + { + abi: abi.erc20, + address: address.optimism.usdc, + chainId: optimism.id, + functionName: 'symbol', + }, + { + abi: abi.erc20, + address: address.optimism.usdc, + chainId: optimism.id, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + ] as const + const results = await readContracts(config, { + contracts: [ + mainnetContracts[0]!, + optimismContracts[0]!, + mainnetContracts[1]!, + mainnet2Contracts[0]!, + optimismContracts[1]!, + mainnet2Contracts[1]!, + mainnetContracts[2]!, + ], + }) + expectTypeOf(results).toEqualTypeOf< + [ + MulticallResponse, + MulticallResponse, + MulticallResponse, + MulticallResponse, + MulticallResponse, + MulticallResponse, + MulticallResponse, + ] + >() + + expect(spy).toHaveBeenCalledWith(config, { + allowFailure: true, + contracts: mainnetContracts, + chainId: mainnet.id, + overrides: undefined, + }) + expect(spy).toHaveBeenCalledWith(config, { + allowFailure: true, + contracts: mainnet2Contracts, + chainId: mainnet2.id, + overrides: undefined, + }) + expect(results).toMatchInlineSnapshot(` + [ + { + "result": 2n, + "status": "success", + }, + { + "result": "USDC", + "status": "success", + }, + { + "result": 1n, + "status": "success", + }, + { + "result": false, + "status": "success", + }, + { + "result": 10959340n, + "status": "success", + }, + { + "result": 370395n, + "status": "success", + }, + { + "result": 0n, + "status": "success", + }, + ] + `) +}) + +test('multi-chain: falls back to readContract if multicall is not available', async () => { + const config = createConfig({ + chains: [mainnet, { ...optimism, contracts: { multicall3: undefined } }], + transports: { + [mainnet.id]: http(), + [optimism.id]: http(), + }, + }) + + const spy = vi.spyOn(readContract, 'readContract') + const mainnetContracts = [ + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet.id, + functionName: 'love', + args: ['0x27a69ffba1e939ddcfecc8c7e0f967b872bac65c'], + }, + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet.id, + functionName: 'love', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + ] as const + const optimismContracts = [ + { + abi: abi.erc20, + address: address.optimism.usdc, + chainId: optimism.id, + functionName: 'symbol', + }, + { + abi: abi.erc20, + address: address.optimism.usdc, + chainId: optimism.id, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + ] as const + const results = await readContracts(config, { + contracts: [...mainnetContracts, ...optimismContracts], + }) + expectTypeOf(results).toEqualTypeOf< + [ + MulticallResponse, + MulticallResponse, + MulticallResponse, + MulticallResponse, + ] + >() + + for (const contract of mainnetContracts) { + expect(spy).toBeCalledWith(config, { ...contract, chainId: mainnet.id }) + } + for (const contract of optimismContracts) { + expect(spy).toBeCalledWith(config, { ...contract, chainId: optimism.id }) + } + expect(results).toMatchInlineSnapshot(` + [ + { + "result": 2n, + "status": "success", + }, + { + "result": 1n, + "status": "success", + }, + { + "result": "USDC", + "status": "success", + }, + { + "result": 10959340n, + "status": "success", + }, + ] + `) +}) + +test('throws if allowFailure=false & a contract method fails', async () => { + await expect( + readContracts(config, { + allowFailure: false, + contracts: [ + ...contracts, + { + abi: abi.mloot, + address: address.mloot, + functionName: 'tokenOfOwnerByIndex', + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', 69420n], + }, + ], + }), + ).rejects.toThrowErrorMatchingInlineSnapshot( + ` + [ContractFunctionExecutionError: The contract function "tokenOfOwnerByIndex" reverted with the following reason: + ERC721Enumerable: owner index out of bounds + + Contract Call: + address: 0x1dfe7ca09e99d10835bf73044a23b73fc20623df + function: tokenOfOwnerByIndex(address owner, uint256 index) + args: (0xA0Cf798816D4b9b9866b5330EEa46a18382f251e, 69420) + + Docs: https://viem.sh/docs/contract/readContract + Version: viem@2.29.2] + `, + ) +}) + +test('allowFailure=true & a contract method fails', async () => { + expect( + await readContracts(config, { + allowFailure: true, + contracts: [ + ...contracts, + { + abi: abi.mloot, + address: address.mloot, + functionName: 'tokenOfOwnerByIndex', + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', 69420n], + }, + { + abi: abi.mloot, + address: address.mloot, + functionName: 'tokenOfOwnerByIndex', + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', 69421n], + }, + ], + }), + ).toMatchInlineSnapshot(` + [ + { + "result": 2n, + "status": "success", + }, + { + "result": 1n, + "status": "success", + }, + { + "result": false, + "status": "success", + }, + { + "result": 370395n, + "status": "success", + }, + { + "error": [ContractFunctionExecutionError: The contract function "tokenOfOwnerByIndex" reverted with the following reason: + ERC721Enumerable: owner index out of bounds + + Contract Call: + address: 0x1dfe7ca09e99d10835bf73044a23b73fc20623df + function: tokenOfOwnerByIndex(address owner, uint256 index) + args: (0xA0Cf798816D4b9b9866b5330EEa46a18382f251e, 69420) + + Docs: https://viem.sh/docs/contract/readContract + Version: viem@2.29.2], + "result": undefined, + "status": "failure", + }, + { + "error": [ContractFunctionExecutionError: The contract function "tokenOfOwnerByIndex" reverted with the following reason: + ERC721Enumerable: owner index out of bounds + + Contract Call: + address: 0x1dfe7ca09e99d10835bf73044a23b73fc20623df + function: tokenOfOwnerByIndex(address owner, uint256 index) + args: (0xA0Cf798816D4b9b9866b5330EEa46a18382f251e, 69421) + + Docs: https://viem.sh/docs/contract/readContract + Version: viem@2.29.2], + "result": undefined, + "status": "failure", + }, + ] + `) +}) + +test('throws if allowFailure=false & encoding contract function data fails', async () => { + await expect( + readContracts(config, { + allowFailure: false, + contracts: [ + ...contracts, + { + abi: abi.mloot, + functionName: 'ownerOf', + // address is not the mloot contract + address: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + args: [10e30], + }, + ], + }), + ).rejects.toThrowErrorMatchingInlineSnapshot( + ` + [ContractFunctionExecutionError: The contract function "ownerOf" returned no data ("0x"). + + This could be due to any of the following: + - The contract does not have the function "ownerOf", + - The parameters passed to the contract function may be invalid, or + - The address is not a contract. + + Contract Call: + address: 0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC + function: ownerOf(uint256 tokenId) + args: (1e+31) + + Docs: https://viem.sh/docs/contract/readContract + Version: viem@2.29.2] + `, + ) +}) + +test('allowFailure=true & encoding contract function data fails', async () => { + expect( + await readContracts(config, { + allowFailure: true, + contracts: [ + ...contracts, + { + abi: abi.mloot, + functionName: 'ownerOf', + // address is not the mloot contract + address: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + args: [10e30], + }, + { + abi: abi.mloot, + functionName: 'ownerOf', + // address is not the mloot contract + address: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + args: [10e30], + }, + ], + }), + ).toMatchInlineSnapshot(` + [ + { + "result": 2n, + "status": "success", + }, + { + "result": 1n, + "status": "success", + }, + { + "result": false, + "status": "success", + }, + { + "result": 370395n, + "status": "success", + }, + { + "error": [ContractFunctionExecutionError: The contract function "ownerOf" returned no data ("0x"). + + This could be due to any of the following: + - The contract does not have the function "ownerOf", + - The parameters passed to the contract function may be invalid, or + - The address is not a contract. + + Contract Call: + address: 0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC + function: ownerOf(uint256 tokenId) + args: (1e+31) + + Docs: https://viem.sh/docs/contract/readContract + Version: viem@2.29.2], + "result": undefined, + "status": "failure", + }, + { + "error": [ContractFunctionExecutionError: The contract function "ownerOf" returned no data ("0x"). + + This could be due to any of the following: + - The contract does not have the function "ownerOf", + - The parameters passed to the contract function may be invalid, or + - The address is not a contract. + + Contract Call: + address: 0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC + function: ownerOf(uint256 tokenId) + args: (1e+31) + + Docs: https://viem.sh/docs/contract/readContract + Version: viem@2.29.2], + "result": undefined, + "status": "failure", + }, + ] + `) +}) + +test('should throw if allowFailure=false & a contract has no response', async () => { + await expect( + readContracts(config, { + allowFailure: false, + contracts: [ + ...contracts, + { + abi: abi.wagmigotchi, + functionName: 'love', + // address is not the wagmigotchi contract + address: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + ], + }), + ).rejects.toThrowErrorMatchingInlineSnapshot( + ` + [ContractFunctionExecutionError: The contract function "love" returned no data ("0x"). + + This could be due to any of the following: + - The contract does not have the function "love", + - The parameters passed to the contract function may be invalid, or + - The address is not a contract. + + Contract Call: + address: 0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC + function: love(address) + args: (0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC) + + Docs: https://viem.sh/docs/contract/readContract + Version: viem@2.29.2] + `, + ) +}) + +test('allowFailure=true & a contract has no response', async () => { + expect( + await readContracts(config, { + allowFailure: true, + contracts: [ + ...contracts, + { + abi: abi.wagmigotchi, + functionName: 'love', + // address is not the wagmigotchi contract + address: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + ], + }), + ).toMatchInlineSnapshot(` + [ + { + "result": 2n, + "status": "success", + }, + { + "result": 1n, + "status": "success", + }, + { + "result": false, + "status": "success", + }, + { + "result": 370395n, + "status": "success", + }, + { + "error": [ContractFunctionExecutionError: The contract function "love" returned no data ("0x"). + + This could be due to any of the following: + - The contract does not have the function "love", + - The parameters passed to the contract function may be invalid, or + - The address is not a contract. + + Contract Call: + address: 0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC + function: love(address) + args: (0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC) + + Docs: https://viem.sh/docs/contract/readContract + Version: viem@2.29.2], + "result": undefined, + "status": "failure", + }, + ] + `) +}) diff --git a/packages/core/src/actions/readContracts.ts b/packages/core/src/actions/readContracts.ts new file mode 100644 index 0000000000..45f2a0cef4 --- /dev/null +++ b/packages/core/src/actions/readContracts.ts @@ -0,0 +1,96 @@ +import type { + ContractFunctionParameters, + MulticallParameters as viem_MulticallParameters, + MulticallReturnType as viem_MulticallReturnType, +} from 'viem' +import { ContractFunctionExecutionError } from 'viem' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import { type MulticallErrorType, multicall } from './multicall.js' +import { type ReadContractErrorType, readContract } from './readContract.js' + +export type ReadContractsParameters< + contracts extends readonly unknown[] = readonly ContractFunctionParameters[], + allowFailure extends boolean = true, + config extends Config = Config, +> = viem_MulticallParameters< + contracts, + allowFailure, + { properties: ChainIdParameter } +> + +export type ReadContractsReturnType< + contracts extends readonly unknown[] = readonly ContractFunctionParameters[], + allowFailure extends boolean = true, +> = viem_MulticallReturnType + +export type ReadContractsErrorType = MulticallErrorType | ReadContractErrorType + +export async function readContracts< + config extends Config, + const contracts extends readonly ContractFunctionParameters[], + allowFailure extends boolean = true, +>( + config: config, + parameters: ReadContractsParameters, +): Promise> { + const { allowFailure = true, blockNumber, blockTag, ...rest } = parameters + const contracts = parameters.contracts as (ContractFunctionParameters & { + chainId?: number | undefined + })[] + + try { + const contractsByChainId: { + [chainId: number]: { + contract: ContractFunctionParameters + index: number + }[] + } = {} + for (const [index, contract] of contracts.entries()) { + const chainId = contract.chainId ?? config.state.chainId + if (!contractsByChainId[chainId]) contractsByChainId[chainId] = [] + contractsByChainId[chainId]?.push({ contract, index }) + } + const promises = () => + Object.entries(contractsByChainId).map(([chainId, contracts]) => + multicall(config, { + ...rest, + allowFailure, + blockNumber, + blockTag, + chainId: Number.parseInt(chainId), + contracts: contracts.map(({ contract }) => contract), + }), + ) + + const multicallResults = (await Promise.all(promises())).flat() + // Reorder the contract results back to the order they were + // provided in. + const resultIndexes = Object.values(contractsByChainId).flatMap( + (contracts) => contracts.map(({ index }) => index), + ) + return multicallResults.reduce((results, result, index) => { + if (results) (results as unknown[])[resultIndexes[index]!] = result + return results + }, [] as unknown[]) as ReadContractsReturnType + } catch (error) { + if (error instanceof ContractFunctionExecutionError) throw error + + const promises = () => + contracts.map((contract) => + readContract(config, { ...contract, blockNumber, blockTag }), + ) + if (allowFailure) + return (await Promise.allSettled(promises())).map((result) => { + if (result.status === 'fulfilled') + return { result: result.value, status: 'success' } + return { error: result.reason, result: undefined, status: 'failure' } + }) as ReadContractsReturnType + + return (await Promise.all(promises())) as ReadContractsReturnType< + contracts, + allowFailure + > + } +} diff --git a/packages/core/src/actions/reconnect.test.ts b/packages/core/src/actions/reconnect.test.ts new file mode 100644 index 0000000000..910d16e304 --- /dev/null +++ b/packages/core/src/actions/reconnect.test.ts @@ -0,0 +1,119 @@ +import { accounts, config, mainnet } from '@wagmi/test' +import { http } from 'viem' +import { afterEach, expect, test, vi } from 'vitest' + +import { mock } from '../connectors/mock.js' +import { createConfig } from '../createConfig.js' +import { createStorage } from '../createStorage.js' +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { reconnect } from './reconnect.js' + +const connector = config._internal.connectors.setup( + mock({ + accounts, + features: { reconnect: true }, + }), +) + +afterEach(async () => { + if (config.state.current === connector.uid) + await disconnect(config, { connector }) + else if (config.state.current) await disconnect(config) +}) + +test('default', async () => { + await expect( + reconnect(config, { connectors: [connector] }), + ).resolves.toStrictEqual([]) + expect(config.state.status).toEqual('disconnected') +}) + +test('parameters: connectors (Connector)', async () => { + await connect(config, { connector }) + await expect( + reconnect(config, { connectors: [connector] }), + ).resolves.toMatchObject( + expect.arrayContaining([ + expect.objectContaining({ + accounts: expect.any(Array), + chainId: expect.any(Number), + }), + ]), + ) + expect(config.state.status).toEqual('connected') +}) + +test('parameters: connectors (CreateConnectorFn)', async () => { + const connector = mock({ + accounts, + features: { reconnect: true }, + }) + await connect(config, { connector }) + await expect( + reconnect(config, { connectors: [connector] }), + ).resolves.toMatchObject( + expect.arrayContaining([ + expect.objectContaining({ + accounts: expect.any(Array), + chainId: expect.any(Number), + }), + ]), + ) + expect(config.state.status).toEqual('connected') +}) + +test("behavior: doesn't reconnect if already reconnecting", async () => { + const previousStatus = config.state.status + config.setState((x) => ({ ...x, status: 'reconnecting' })) + await expect( + reconnect(config, { connectors: [connector] }), + ).resolves.toStrictEqual([]) + config.setState((x) => ({ ...x, status: previousStatus })) +}) + +test('behavior: recovers from invalid state', async () => { + const state = { + 'wagmi.store': JSON.stringify({ + state: { + status: 'connected', // <-- invalid - `status` should not be kept in storage + chainId: 1, + current: '983b8aca245', + }, + version: Number.NaN, // mocked version is `'x.y.z'`, which will get interpreted as `NaN` + }), + } as Record + Object.defineProperty(window, 'localStorage', { + value: { + getItem: vi.fn((key) => state[key] ?? null), + removeItem: vi.fn((key) => state.delete?.[key]), + setItem: vi.fn((key, value) => { + state[key] = value + }), + }, + writable: true, + }) + + const storage = createStorage<{ store: object }>({ + storage: window.localStorage, + }) + + const config = createConfig({ + chains: [mainnet], + storage, + transports: { + [mainnet.id]: http(), + }, + }) + + await reconnect(config, { connectors: [connector] }) + + expect(config.state).toMatchInlineSnapshot(` + { + "chainId": 1, + "connections": Map {}, + "current": null, + "status": "disconnected", + } + `) +}) diff --git a/packages/core/src/actions/reconnect.ts b/packages/core/src/actions/reconnect.ts new file mode 100644 index 0000000000..2234c934d4 --- /dev/null +++ b/packages/core/src/actions/reconnect.ts @@ -0,0 +1,127 @@ +import type { Address } from 'viem' + +import type { CreateConnectorFn } from '../connectors/createConnector.js' +import type { Config, Connection, Connector } from '../createConfig.js' +import type { ErrorType } from '../errors/base.js' +import type { Compute } from '../types/utils.js' + +export type ReconnectParameters = { + /** Connectors to attempt reconnect with */ + connectors?: readonly (CreateConnectorFn | Connector)[] | undefined +} + +export type ReconnectReturnType = Compute[] + +export type ReconnectErrorType = ErrorType + +let isReconnecting = false + +/** https://wagmi.sh/core/api/actions/reconnect */ +export async function reconnect( + config: Config, + parameters: ReconnectParameters = {}, +): Promise { + // If already reconnecting, do nothing + if (isReconnecting) return [] + isReconnecting = true + + config.setState((x) => ({ + ...x, + status: x.current ? 'reconnecting' : 'connecting', + })) + + const connectors: Connector[] = [] + if (parameters.connectors?.length) { + for (const connector_ of parameters.connectors) { + let connector: Connector + // "Register" connector if not already created + if (typeof connector_ === 'function') + connector = config._internal.connectors.setup(connector_) + else connector = connector_ + connectors.push(connector) + } + } else connectors.push(...config.connectors) + + // Try recently-used connectors first + let recentConnectorId: string | null | undefined + try { + recentConnectorId = await config.storage?.getItem('recentConnectorId') + } catch {} + const scores: Record = {} + for (const [, connection] of config.state.connections) { + scores[connection.connector.id] = 1 + } + if (recentConnectorId) scores[recentConnectorId] = 0 + const sorted = + Object.keys(scores).length > 0 + ? // .toSorted() + [...connectors].sort( + (a, b) => (scores[a.id] ?? 10) - (scores[b.id] ?? 10), + ) + : connectors + + // Iterate through each connector and try to connect + let connected = false + const connections: Connection[] = [] + const providers: unknown[] = [] + for (const connector of sorted) { + const provider = await connector.getProvider().catch(() => undefined) + if (!provider) continue + + // If we already have an instance of this connector's provider, + // then we have already checked it (ie. injected connectors can + // share the same `window.ethereum` instance, so we don't want to + // connect to it again). + if (providers.some((x) => x === provider)) continue + + const isAuthorized = await connector.isAuthorized() + if (!isAuthorized) continue + + const data = await connector + .connect({ isReconnecting: true }) + .catch(() => null) + if (!data) continue + + connector.emitter.off('connect', config._internal.events.connect) + connector.emitter.on('change', config._internal.events.change) + connector.emitter.on('disconnect', config._internal.events.disconnect) + + config.setState((x) => { + const connections = new Map(connected ? x.connections : new Map()).set( + connector.uid, + { accounts: data.accounts, chainId: data.chainId, connector }, + ) + return { + ...x, + current: connected ? x.current : connector.uid, + connections, + } + }) + connections.push({ + accounts: data.accounts as readonly [Address, ...Address[]], + chainId: data.chainId, + connector, + }) + providers.push(provider) + connected = true + } + + // Prevent overwriting connected status from race condition + if ( + config.state.status === 'reconnecting' || + config.state.status === 'connecting' + ) { + // If connecting didn't succeed, set to disconnected + if (!connected) + config.setState((x) => ({ + ...x, + connections: new Map(), + current: null, + status: 'disconnected', + })) + else config.setState((x) => ({ ...x, status: 'connected' })) + } + + isReconnecting = false + return connections +} diff --git a/packages/core/src/actions/sendCalls.test.ts b/packages/core/src/actions/sendCalls.test.ts new file mode 100644 index 0000000000..cb25e2b0ba --- /dev/null +++ b/packages/core/src/actions/sendCalls.test.ts @@ -0,0 +1,121 @@ +import { accounts, config } from '@wagmi/test' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { sendCalls } from './sendCalls.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + await expect( + sendCalls(config, { + calls: [ + { + data: '0xdeadbeef', + to: accounts[1], + value: parseEther('1'), + }, + { + to: accounts[2], + value: parseEther('2'), + }, + { + to: accounts[3], + value: parseEther('3'), + }, + ], + }), + ).resolves.toMatchInlineSnapshot( + ` + { + "id": "0x5dedb5a4ff8968db37459b52b83cbdc92b01c9c709c9cff26e345ef5cf27f92e", + } + `, + ) + await disconnect(config, { connector }) +}) + +test('behavior: not connected', async () => { + await expect( + sendCalls(config, { + calls: [ + { + to: accounts[1], + value: parseEther('1'), + }, + { + to: accounts[2], + value: parseEther('2'), + }, + { + to: accounts[3], + value: parseEther('3'), + }, + ], + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ConnectorNotConnectedError: Connector not connected. + + Version: @wagmi/core@x.y.z] + `) +}) + +test('behavior: nullish account (account filled by wallet)', async () => { + await expect( + sendCalls(config, { + account: null, + connector, + calls: [ + { + to: accounts[1], + value: parseEther('1'), + }, + { + to: accounts[2], + value: parseEther('2'), + }, + { + to: accounts[3], + value: parseEther('3'), + }, + ], + }), + ).resolves.toMatchInlineSnapshot( + ` + { + "id": "0x035b56a56a5b2fea10e194bae4c846b415de48a8288c7eb704ba7880edcc29a0", + } + `, + ) +}) + +test('behavior: account does not exist on connector', async () => { + await connect(config, { connector }) + await expect( + sendCalls(config, { + account: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + calls: [ + { + to: accounts[1], + value: parseEther('1'), + }, + { + to: accounts[2], + value: parseEther('2'), + }, + { + to: accounts[3], + value: parseEther('3'), + }, + ], + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ConnectorAccountNotFoundError: Account "0xA0Cf798816D4b9b9866b5330EEa46a18382f251e" not found for connector "Mock Connector". + + Version: @wagmi/core@x.y.z] + `) + await disconnect(config, { connector }) +}) diff --git a/packages/core/src/actions/sendCalls.ts b/packages/core/src/actions/sendCalls.ts new file mode 100644 index 0000000000..6139455d60 --- /dev/null +++ b/packages/core/src/actions/sendCalls.ts @@ -0,0 +1,74 @@ +import type { Account, Chain } from 'viem' +import { + type SendCallsErrorType as viem_SendCallsErrorType, + type SendCallsParameters as viem_SendCallsParameters, + type SendCallsReturnType as viem_SendCallsReturnType, + sendCalls as viem_sendCalls, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import type { SelectChains } from '../types/chain.js' +import type { + ChainIdParameter, + ConnectorParameter, +} from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { + type GetConnectorClientErrorType, + getConnectorClient, +} from './getConnectorClient.js' + +export type SendCallsParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + calls extends readonly unknown[] = readonly unknown[], + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: Compute< + Omit< + viem_SendCallsParameters, + 'chain' + > & + ChainIdParameter & + ConnectorParameter + > +}[number] + +export type SendCallsReturnType = viem_SendCallsReturnType + +export type SendCallsErrorType = + // getConnectorClient() + | GetConnectorClientErrorType + // base + | BaseErrorType + | ErrorType + // viem + | viem_SendCallsErrorType + +/** https://wagmi.sh/core/api/actions/sendCalls */ +export async function sendCalls< + const calls extends readonly unknown[], + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: SendCallsParameters, +): Promise { + const { account, chainId, connector, calls, ...rest } = parameters + + const client = await getConnectorClient(config, { + account, + chainId, + connector, + }) + + return viem_sendCalls(client, { + ...(rest as any), + ...(typeof account !== 'undefined' ? { account } : {}), + calls, + chain: chainId ? { id: chainId } : undefined, + }) +} diff --git a/packages/core/src/actions/sendTransaction.test-d.ts b/packages/core/src/actions/sendTransaction.test-d.ts new file mode 100644 index 0000000000..54ce62a947 --- /dev/null +++ b/packages/core/src/actions/sendTransaction.test-d.ts @@ -0,0 +1,50 @@ +import { http, parseEther } from 'viem' +import { celo, mainnet } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { + type SendTransactionParameters, + sendTransaction, +} from './sendTransaction.js' + +test('chain formatters', () => { + const config = createConfig({ + chains: [mainnet, celo], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + + type Result = SendTransactionParameters + expectTypeOf().toMatchTypeOf<{ + chainId?: typeof celo.id | typeof mainnet.id | undefined + feeCurrency?: `0x${string}` | undefined + }>() + sendTransaction(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + feeCurrency: '0x', + }) + + type Result2 = SendTransactionParameters + expectTypeOf().toMatchTypeOf<{ + feeCurrency?: `0x${string}` | undefined + }>() + sendTransaction(config, { + chainId: celo.id, + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + feeCurrency: '0x', + }) + + type Result3 = SendTransactionParameters + expectTypeOf().not.toMatchTypeOf<{ + feeCurrency?: `0x${string}` | undefined + }>() + sendTransaction(config, { + chainId: mainnet.id, + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/core/src/actions/sendTransaction.test.ts b/packages/core/src/actions/sendTransaction.test.ts new file mode 100644 index 0000000000..e263d96670 --- /dev/null +++ b/packages/core/src/actions/sendTransaction.test.ts @@ -0,0 +1,105 @@ +import { config, privateKey, transactionHashRegex } from '@wagmi/test' +import { parseEther } from 'viem' +import { beforeEach, expect, test } from 'vitest' + +import { privateKeyToAccount } from 'viem/accounts' +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { sendTransaction } from './sendTransaction.js' + +const connector = config.connectors[0]! + +beforeEach(async () => { + if (config.state.current === connector.uid) + await disconnect(config, { connector }) +}) + +test('default', async () => { + const result = await connect(config, { connector }) + config.state.connections.set(connector.uid, { + ...result, + // Switch up the current account because the default one is running out of funds somewhere + accounts: result.accounts.slice(1) as unknown as typeof result.accounts, + connector, + }) + await expect( + sendTransaction(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.0001'), + }), + ).resolves.toMatch(transactionHashRegex) + await disconnect(config, { connector }) +}) + +test('behavior: connector not connected', async () => { + await connect(config, { connector }) + await expect( + sendTransaction(config, { + connector: config.connectors[1], + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.0001'), + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ConnectorNotConnectedError: Connector not connected. + + Version: @wagmi/core@x.y.z] + `) + await disconnect(config, { connector }) +}) + +test('behavior: account does not exist on connector', async () => { + await connect(config, { connector }) + await expect( + sendTransaction(config, { + account: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.0001'), + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ConnectorAccountNotFoundError: Account "0xA0Cf798816D4b9b9866b5330EEa46a18382f251e" not found for connector "Mock Connector". + + Version: @wagmi/core@x.y.z] + `) + await disconnect(config, { connector }) +}) + +test('behavior: value exceeds balance', async () => { + await connect(config, { connector }) + await expect( + sendTransaction(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('99999'), + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [TransactionExecutionError: The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account. + + This error could arise when the account does not have enough funds to: + - pay for the total gas fee, + - pay for the value to send. + + The cost of the transaction is calculated as \`gas * gas fee + value\`, where: + - \`gas\` is the amount of gas needed for transaction to execute, + - \`gas fee\` is the gas fee, + - \`value\` is the amount of ether to send to the recipient. + + Request Arguments: + from: 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266 + to: 0xd2135CfB216b74109775236E36d4b433F1DF507B + value: 99999 ETH + + Details: Insufficient funds for gas * price + value + Version: viem@2.29.2] + `) + await disconnect(config, { connector }) +}) + +test('behavior: local account', async () => { + const account = privateKeyToAccount(privateKey) + await expect( + sendTransaction(config, { + account, + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.000001'), + }), + ).resolves.toMatch(transactionHashRegex) +}) diff --git a/packages/core/src/actions/sendTransaction.ts b/packages/core/src/actions/sendTransaction.ts new file mode 100644 index 0000000000..76bc3a420a --- /dev/null +++ b/packages/core/src/actions/sendTransaction.ts @@ -0,0 +1,86 @@ +import type { + Account, + Chain, + Client, + TransactionRequest, + SendTransactionErrorType as viem_SendTransactionErrorType, + SendTransactionParameters as viem_SendTransactionParameters, + SendTransactionReturnType as viem_SendTransactionReturnType, +} from 'viem' +import { sendTransaction as viem_sendTransaction } from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import type { SelectChains } from '../types/chain.js' +import type { + ChainIdParameter, + ConnectorParameter, +} from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' +import { + type GetConnectorClientErrorType, + getConnectorClient, +} from './getConnectorClient.js' + +export type SendTransactionParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: Compute< + Omit< + viem_SendTransactionParameters, + 'chain' | 'gas' + > & + ChainIdParameter & + ConnectorParameter + > +}[number] & { + /** Gas provided for transaction execution. */ + gas?: TransactionRequest['gas'] | null +} + +export type SendTransactionReturnType = viem_SendTransactionReturnType + +export type SendTransactionErrorType = + // getConnectorClient() + | GetConnectorClientErrorType + // base + | BaseErrorType + | ErrorType + // viem + | viem_SendTransactionErrorType + +/** https://wagmi.sh/core/api/actions/sendTransaction */ +export async function sendTransaction< + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: SendTransactionParameters, +): Promise { + const { account, chainId, connector, ...rest } = parameters + + let client: Client + if (typeof account === 'object' && account?.type === 'local') + client = config.getClient({ chainId }) + else + client = await getConnectorClient(config, { + account: account ?? undefined, + chainId, + connector, + }) + + const action = getAction(client, viem_sendTransaction, 'sendTransaction') + const hash = await action({ + ...(rest as any), + ...(account ? { account } : {}), + chain: chainId ? { id: chainId } : null, + gas: rest.gas ?? undefined, + }) + + return hash +} diff --git a/packages/core/src/actions/showCallsStatus.test.ts b/packages/core/src/actions/showCallsStatus.test.ts new file mode 100644 index 0000000000..5822242382 --- /dev/null +++ b/packages/core/src/actions/showCallsStatus.test.ts @@ -0,0 +1,36 @@ +import { accounts, config, testClient } from '@wagmi/test' +import { parseEther } from 'viem' +import { test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { sendCalls } from './sendCalls.js' +import { showCallsStatus } from './showCallsStatus.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + const { id } = await sendCalls(config, { + calls: [ + { + data: '0xdeadbeef', + to: accounts[1], + value: parseEther('1'), + }, + { + to: accounts[2], + value: parseEther('2'), + }, + { + to: accounts[3], + value: parseEther('3'), + }, + ], + }) + await testClient.mainnet.mine({ blocks: 1 }) + await showCallsStatus(config, { + id, + }) + await disconnect(config, { connector }) +}) diff --git a/packages/core/src/actions/showCallsStatus.ts b/packages/core/src/actions/showCallsStatus.ts new file mode 100644 index 0000000000..e3c6ae067d --- /dev/null +++ b/packages/core/src/actions/showCallsStatus.ts @@ -0,0 +1,27 @@ +import { + type ShowCallsStatusErrorType as viem_ShowCallsStatusErrorType, + type ShowCallsStatusParameters as viem_ShowCallsStatusParameters, + type ShowCallsStatusReturnType as viem_ShowCallsStatusReturnType, + showCallsStatus as viem_showCallsStatus, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ConnectorParameter } from '../types/properties.js' +import { getConnectorClient } from './getConnectorClient.js' + +export type ShowCallsStatusParameters = viem_ShowCallsStatusParameters & + ConnectorParameter + +export type ShowCallsStatusReturnType = viem_ShowCallsStatusReturnType + +export type ShowCallsStatusErrorType = viem_ShowCallsStatusErrorType + +/** https://wagmi.sh/core/api/actions/showCallsStatus */ +export async function showCallsStatus( + config: config, + parameters: ShowCallsStatusParameters, +): Promise { + const { connector, id } = parameters + const client = await getConnectorClient(config, { connector }) + return viem_showCallsStatus(client, { id }) +} diff --git a/packages/core/src/actions/signMessage.test.ts b/packages/core/src/actions/signMessage.test.ts new file mode 100644 index 0000000000..5b87c7d652 --- /dev/null +++ b/packages/core/src/actions/signMessage.test.ts @@ -0,0 +1,67 @@ +import { accounts, config, privateKey } from '@wagmi/test' +import { recoverMessageAddress } from 'viem' +import { privateKeyToAccount } from 'viem/accounts' +import { expect, test } from 'vitest' + +import { mock } from '../connectors/mock.js' +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { getAccount } from './getAccount.js' +import { signMessage } from './signMessage.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + const signature = await signMessage(config, { message: 'foo bar baz' }) + await expect( + recoverMessageAddress({ + message: 'foo bar baz', + signature, + }), + ).resolves.toEqual(getAccount(config).address) + await disconnect(config, { connector }) +}) + +test('behavior: local account', async () => { + const account = privateKeyToAccount(privateKey) + const signature = await signMessage(config, { + account, + message: 'foo bar baz', + }) + await expect( + recoverMessageAddress({ + message: 'foo bar baz', + signature, + }), + ).resolves.toEqual(account.address) +}) + +test('behavior: user rejected request', async () => { + const connector_ = config._internal.connectors.setup( + mock({ + accounts, + features: { signMessageError: true }, + }), + ) + await connect(config, { connector: connector_ }) + await expect( + signMessage(config, { message: 'foo bar baz' }), + ).rejects.toMatchInlineSnapshot(` + [UserRejectedRequestError: User rejected the request. + + Details: Failed to sign message. + Version: viem@2.29.2] + `) + await disconnect(config, { connector: connector_ }) +}) + +test('behavior: not connected', async () => { + await expect( + signMessage(config, { message: 'foo bar baz' }), + ).rejects.toMatchInlineSnapshot(` + [ConnectorNotConnectedError: Connector not connected. + + Version: @wagmi/core@x.y.z] + `) +}) diff --git a/packages/core/src/actions/signMessage.ts b/packages/core/src/actions/signMessage.ts new file mode 100644 index 0000000000..67f0c293a6 --- /dev/null +++ b/packages/core/src/actions/signMessage.ts @@ -0,0 +1,51 @@ +import type { Account, Client } from 'viem' +import { + type SignMessageErrorType as viem_SignMessageErrorType, + type SignMessageParameters as viem_SignMessageParameters, + type SignMessageReturnType as viem_SignMessageReturnType, + signMessage as viem_signMessage, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import type { ConnectorParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' +import { + type GetConnectorClientErrorType, + getConnectorClient, +} from './getConnectorClient.js' + +export type SignMessageParameters = Compute< + viem_SignMessageParameters & ConnectorParameter +> + +export type SignMessageReturnType = viem_SignMessageReturnType + +export type SignMessageErrorType = + // getConnectorClient() + | GetConnectorClientErrorType + // base + | BaseErrorType + | ErrorType + // viem + | viem_SignMessageErrorType + +/** https://wagmi.sh/core/api/actions/signMessage */ +export async function signMessage( + config: Config, + parameters: SignMessageParameters, +): Promise { + const { account, connector, ...rest } = parameters + + let client: Client + if (typeof account === 'object' && account.type === 'local') + client = config.getClient() + else client = await getConnectorClient(config, { account, connector }) + + const action = getAction(client, viem_signMessage, 'signMessage') + return action({ + ...rest, + ...(account ? { account } : {}), + } as viem_SignMessageParameters) +} diff --git a/packages/core/src/actions/signTypedData.test-d.ts b/packages/core/src/actions/signTypedData.test-d.ts new file mode 100644 index 0000000000..a502d26e91 --- /dev/null +++ b/packages/core/src/actions/signTypedData.test-d.ts @@ -0,0 +1,31 @@ +import { config, typedData } from '@wagmi/test' +import { test } from 'vitest' + +import { signTypedData } from './signTypedData.js' + +test('default', async () => { + signTypedData(config, { + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + }) +}) + +test('domain', async () => { + signTypedData(config, { + primaryType: 'EIP712Domain', + domain: {}, + }) +}) + +test('custom domain', async () => { + signTypedData(config, { + types: { + EIP712Domain: [{ type: 'uint256', name: 'chainId' }], + }, + primaryType: 'EIP712Domain', + domain: { + chainId: 123n, + }, + }) +}) diff --git a/packages/core/src/actions/signTypedData.test.ts b/packages/core/src/actions/signTypedData.test.ts new file mode 100644 index 0000000000..b72ecab8cb --- /dev/null +++ b/packages/core/src/actions/signTypedData.test.ts @@ -0,0 +1,85 @@ +import { accounts, config, privateKey, typedData } from '@wagmi/test' +import { recoverTypedDataAddress } from 'viem' +import { expect, test } from 'vitest' + +import { privateKeyToAccount } from 'viem/accounts' +import { mock } from '../connectors/mock.js' +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { getAccount } from './getAccount.js' +import { signTypedData } from './signTypedData.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + const signature = await signTypedData(config, { + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + }) + await expect( + recoverTypedDataAddress({ + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + signature, + }), + ).resolves.toBe(getAccount(config).address) + await disconnect(config, { connector }) +}) + +test('behavior: user rejected request', async () => { + const connector_ = config._internal.connectors.setup( + mock({ + accounts, + features: { signTypedDataError: true }, + }), + ) + await connect(config, { connector: connector_ }) + await expect( + signTypedData(config, { + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + }), + ).rejects.toMatchInlineSnapshot(` + [UserRejectedRequestError: User rejected the request. + + Details: Failed to sign typed data. + Version: viem@2.29.2] + `) + await disconnect(config, { connector: connector_ }) +}) + +test('behavior: not connected', async () => { + await expect( + signTypedData(config, { + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + }), + ).rejects.toMatchInlineSnapshot(` + [ConnectorNotConnectedError: Connector not connected. + + Version: @wagmi/core@x.y.z] + `) +}) + +test('behavior: local account', async () => { + const account = privateKeyToAccount(privateKey) + const signature = await signTypedData(config, { + account, + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + }) + await expect( + recoverTypedDataAddress({ + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + signature, + }), + ).resolves.toBe(account.address) +}) diff --git a/packages/core/src/actions/signTypedData.ts b/packages/core/src/actions/signTypedData.ts new file mode 100644 index 0000000000..22cea12662 --- /dev/null +++ b/packages/core/src/actions/signTypedData.ts @@ -0,0 +1,60 @@ +import type { Account, Client, TypedData } from 'viem' +import { + type SignMessageErrorType as viem_SignMessageErrorType, + type SignTypedDataParameters as viem_SignTypedDataParameters, + type SignTypedDataReturnType as viem_SignTypedDataReturnType, + signTypedData as viem_signTypedData, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import type { ConnectorParameter } from '../types/properties.js' +import type { UnionCompute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' +import { + type GetConnectorClientErrorType, + getConnectorClient, +} from './getConnectorClient.js' + +export type SignTypedDataParameters< + typedData extends TypedData | Record = TypedData, + primaryType extends keyof typedData | 'EIP712Domain' = keyof typedData, + /// + primaryTypes = typedData extends TypedData ? keyof typedData : string, +> = UnionCompute< + viem_SignTypedDataParameters & + ConnectorParameter +> + +export type SignTypedDataReturnType = viem_SignTypedDataReturnType + +export type SignTypedDataErrorType = + // getConnectorClient() + | GetConnectorClientErrorType + // base + | BaseErrorType + | ErrorType + // viem + | viem_SignMessageErrorType + +/** https://wagmi.sh/core/api/actions/signTypedData */ +export async function signTypedData< + const typedData extends TypedData | Record, + primaryType extends keyof typedData | 'EIP712Domain', +>( + config: Config, + parameters: SignTypedDataParameters, +): Promise { + const { account, connector, ...rest } = parameters + + let client: Client + if (typeof account === 'object' && account.type === 'local') + client = config.getClient() + else client = await getConnectorClient(config, { account, connector }) + + const action = getAction(client, viem_signTypedData, 'signTypedData') + return action({ + ...rest, + ...(account ? { account } : {}), + } as unknown as viem_SignTypedDataParameters) +} diff --git a/packages/core/src/actions/simulateContract.test-d.ts b/packages/core/src/actions/simulateContract.test-d.ts new file mode 100644 index 0000000000..3f893ff8f8 --- /dev/null +++ b/packages/core/src/actions/simulateContract.test-d.ts @@ -0,0 +1,160 @@ +import { abi, config } from '@wagmi/test' +import { http, type Address } from 'viem' +import { celo, mainnet } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { + type SimulateContractParameters, + type SimulateContractReturnType, + simulateContract, +} from './simulateContract.js' + +test('default', async () => { + const response = await simulateContract(config, { + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 1, + }) + + expectTypeOf(response).toMatchTypeOf<{ + result: boolean + request: { + chainId: 1 + abi: readonly [ + { + readonly name: 'transferFrom' + readonly type: 'function' + readonly stateMutability: 'nonpayable' + readonly inputs: readonly [ + { readonly type: 'address'; readonly name: 'sender' }, + { readonly type: 'address'; readonly name: 'recipient' }, + { readonly type: 'uint256'; readonly name: 'amount' }, + ] + readonly outputs: readonly [{ type: 'bool' }] + }, + ] + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + } + }>() +}) + +test('chain formatters', async () => { + const config = createConfig({ + chains: [celo, mainnet], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + + type Result = SimulateContractParameters< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config + > + expectTypeOf().toMatchTypeOf<{ + chainId?: typeof celo.id | typeof mainnet.id | undefined + feeCurrency?: `0x${string}` | undefined + }>() + const response = await simulateContract(config, { + account: '0x', + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + feeCurrency: '0x', + }) + + if (response.chainId === celo.id) { + expectTypeOf(response.chainId).toEqualTypeOf(celo.id) + expectTypeOf(response.request.feeCurrency).toEqualTypeOf< + `0x${string}` | undefined + >() + } + + type Result2 = SimulateContractParameters< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + typeof celo.id + > + expectTypeOf().toMatchTypeOf<{ + functionName: 'approve' | 'transfer' | 'transferFrom' + args: readonly [Address, Address, bigint] + feeCurrency?: `0x${string}` | undefined + }>() + const response2 = await simulateContract(config, { + chainId: celo.id, + account: '0x', + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + feeCurrency: '0x', + }) + expectTypeOf(response2.chainId).toEqualTypeOf(celo.id) + expectTypeOf(response2.request.feeCurrency).toEqualTypeOf< + `0x${string}` | undefined + >() + + type Result3 = SimulateContractParameters< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + typeof mainnet.id + > + expectTypeOf().toMatchTypeOf<{ + functionName: 'approve' | 'transfer' | 'transferFrom' + args: readonly [Address, Address, bigint] + }>() + expectTypeOf().not.toMatchTypeOf<{ + feeCurrency?: `0x${string}` | undefined + }>() + simulateContract(config, { + chainId: mainnet.id, + account: '0x', + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + // @ts-expect-error + feeCurrency: '0x', + }) +}) + +test('SimulateContractParameters', () => { + type Result = SimulateContractParameters< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + (typeof config)['chains'][number]['id'] + > + expectTypeOf().toMatchTypeOf<{ + chainId?: (typeof config)['chains'][number]['id'] | undefined + functionName: 'approve' | 'transfer' | 'transferFrom' + args: readonly [Address, Address, bigint] + }>() +}) + +test('SimulateContractReturnType', () => { + type Result = SimulateContractReturnType< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + (typeof config)['chains'][number]['id'] + > + expectTypeOf().toMatchTypeOf<{ + result: boolean + request: { + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + chainId: (typeof config)['chains'][number]['id'] + } + }>() +}) diff --git a/packages/core/src/actions/simulateContract.test.ts b/packages/core/src/actions/simulateContract.test.ts new file mode 100644 index 0000000000..a52cbd5568 --- /dev/null +++ b/packages/core/src/actions/simulateContract.test.ts @@ -0,0 +1,84 @@ +import { abi, accounts, address, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { simulateContract } from './simulateContract.js' + +const connector = config.connectors[0]! + +test('parameters: account', async () => { + await expect( + simulateContract(config, { + account: accounts[0], + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'mint', + }), + ).resolves.toMatchInlineSnapshot(` + { + "chainId": 1, + "request": { + "abi": [ + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": undefined, + "chainId": undefined, + "dataSuffix": undefined, + "functionName": "mint", + }, + "result": undefined, + } + `) +}) + +test('parameters: connector', async () => { + await connect(config, { connector }) + + await expect( + simulateContract(config, { + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'mint', + connector, + }), + ).resolves.toMatchInlineSnapshot(` + { + "chainId": 1, + "request": { + "abi": [ + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": undefined, + "chainId": undefined, + "dataSuffix": undefined, + "functionName": "mint", + }, + "result": undefined, + } + `) + + await disconnect(config, { connector }) +}) diff --git a/packages/core/src/actions/simulateContract.ts b/packages/core/src/actions/simulateContract.ts new file mode 100644 index 0000000000..e5fe5655ff --- /dev/null +++ b/packages/core/src/actions/simulateContract.ts @@ -0,0 +1,166 @@ +import type { + Abi, + Account, + Address, + Chain, + ContractFunctionArgs, + ContractFunctionName, +} from 'viem' +import { + type SimulateContractErrorType as viem_SimulateContractErrorType, + type SimulateContractParameters as viem_SimulateContractParameters, + type SimulateContractReturnType as viem_SimulateContractReturnType, + simulateContract as viem_simulateContract, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import type { SelectChains } from '../types/chain.js' +import type { + ChainIdParameter, + ConnectorParameter, +} from '../types/properties.js' +import type { + Compute, + PartialBy, + UnionCompute, + UnionStrictOmit, +} from '../types/utils.js' +import { getAction } from '../utils/getAction.js' +import { + type GetConnectorClientErrorType, + getConnectorClient, +} from './getConnectorClient.js' + +export type SimulateContractParameters< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'nonpayable' | 'payable' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + > = ContractFunctionArgs, + config extends Config = Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: UnionCompute< + UnionStrictOmit< + viem_SimulateContractParameters< + abi, + functionName, + args, + chains[key], + chains[key], + Account | Address + >, + 'chain' + > + > & + ChainIdParameter & + ConnectorParameter +}[number] + +export type SimulateContractReturnType< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'nonpayable' | 'payable' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + > = ContractFunctionArgs, + config extends Config = Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: viem_SimulateContractReturnType< + abi, + functionName, + args, + chains[key], + Account, + chains[key] + > & { + chainId: chains[key]['id'] + request: Compute< + PartialBy< + { chainId: chainId; chain: chains[key] }, + chainId extends config['chains'][number]['id'] ? never : 'chainId' + > + > + } +}[number] + +export type SimulateContractErrorType = + // getConnectorClient() + | GetConnectorClientErrorType + // base + | BaseErrorType + | ErrorType + // viem + | viem_SimulateContractErrorType + +/** https://wagmi.sh/core/api/actions/simulateContract */ +export async function simulateContract< + config extends Config, + const abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + chainId extends config['chains'][number]['id'] | undefined = undefined, +>( + config: config, + parameters: SimulateContractParameters< + abi, + functionName, + args, + config, + chainId + >, +): Promise< + SimulateContractReturnType +> { + const { abi, chainId, connector, ...rest } = + parameters as SimulateContractParameters + + let account: Address | Account + if (parameters.account) account = parameters.account + else { + const connectorClient = await getConnectorClient(config, { + chainId, + connector, + }) + account = connectorClient.account + } + + const client = config.getClient({ chainId }) + const action = getAction(client, viem_simulateContract, 'simulateContract') + const { result, request } = await action({ ...rest, abi, account }) + + return { + chainId: client.chain.id, + result, + request: { ...request, chainId }, + } as unknown as SimulateContractReturnType< + abi, + functionName, + args, + config, + chainId + > +} diff --git a/packages/core/src/actions/switchAccount.test.ts b/packages/core/src/actions/switchAccount.test.ts new file mode 100644 index 0000000000..97d0e84b37 --- /dev/null +++ b/packages/core/src/actions/switchAccount.test.ts @@ -0,0 +1,32 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { getAccount } from './getAccount.js' +import { switchAccount } from './switchAccount.js' + +const connector1 = config.connectors[0]! +const connector2 = config.connectors[1]! + +test('default', async () => { + await connect(config, { connector: connector2 }) + await connect(config, { connector: connector1 }) + + const address1 = getAccount(config).address + + await switchAccount(config, { connector: connector2 }) + + const address2 = getAccount(config).address + expect(address2).toBeDefined() + expect(address1).not.toBe(address2) + + await switchAccount(config, { connector: connector1 }) + + const address3 = getAccount(config).address + expect(address3).toBeDefined() + expect(address1).toBe(address3) + + await disconnect(config, { connector: connector1 }) + await disconnect(config, { connector: connector2 }) +}) diff --git a/packages/core/src/actions/switchAccount.ts b/packages/core/src/actions/switchAccount.ts new file mode 100644 index 0000000000..ec577a57c7 --- /dev/null +++ b/packages/core/src/actions/switchAccount.ts @@ -0,0 +1,45 @@ +import type { Address } from 'viem' + +import type { Config, Connector } from '../createConfig.js' +import type { BaseError, ErrorType } from '../errors/base.js' +import { + ConnectorNotConnectedError, + type ConnectorNotConnectedErrorType, +} from '../errors/config.js' + +export type SwitchAccountParameters = { + connector: Connector +} + +export type SwitchAccountReturnType = { + accounts: readonly [Address, ...Address[]] + chainId: + | config['chains'][number]['id'] + | (number extends config['chains'][number]['id'] ? number : number & {}) +} + +export type SwitchAccountErrorType = + | ConnectorNotConnectedErrorType + | BaseError + | ErrorType + +/** https://wagmi.sh/core/api/actions/switchAccount */ +export async function switchAccount( + config: config, + parameters: SwitchAccountParameters, +): Promise> { + const { connector } = parameters + + const connection = config.state.connections.get(connector.uid) + if (!connection) throw new ConnectorNotConnectedError() + + await config.storage?.setItem('recentConnectorId', connector.id) + config.setState((x) => ({ + ...x, + current: connector.uid, + })) + return { + accounts: connection.accounts, + chainId: connection.chainId, + } +} diff --git a/packages/core/src/actions/switchChain.test.ts b/packages/core/src/actions/switchChain.test.ts new file mode 100644 index 0000000000..466d77824f --- /dev/null +++ b/packages/core/src/actions/switchChain.test.ts @@ -0,0 +1,73 @@ +import { accounts, chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { mock } from '../connectors/mock.js' +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { getAccount } from './getAccount.js' +import { switchChain } from './switchChain.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const chainId1 = getAccount(config).chainId + + await switchChain(config, { chainId: chain.mainnet2.id }) + + const chainId2 = getAccount(config).chainId + expect(chainId2).toBeDefined() + expect(chainId1).not.toBe(chainId2) + + await switchChain(config, { chainId: chain.mainnet.id }) + + const chainId3 = getAccount(config).chainId + expect(chainId3).toBeDefined() + expect(chainId1).toBe(chainId3) + + await disconnect(config, { connector }) +}) + +test('behavior: user rejected request', async () => { + const connector_ = config._internal.connectors.setup( + mock({ + accounts, + features: { switchChainError: true }, + }), + ) + await connect(config, { connector: connector_ }) + await expect( + switchChain(config, { chainId: chain.mainnet.id }), + ).rejects.toMatchInlineSnapshot(` + [UserRejectedRequestError: User rejected the request. + + Details: Failed to switch chain. + Version: viem@2.29.2] + `) + await disconnect(config, { connector: connector_ }) +}) + +test('behavior: not supported', async () => { + const { switchChain: _, ...connector_ } = config._internal.connectors.setup( + mock({ accounts }), + ) + await connect(config, { connector: connector_ }) + await expect( + switchChain(config, { chainId: chain.mainnet.id }), + ).rejects.toMatchInlineSnapshot(` + [SwitchChainNotSupportedError: "Mock Connector" does not support programmatic chain switching. + + Version: @wagmi/core@x.y.z] + `) + await disconnect(config, { connector: connector_ }) +}) + +test('behavior: not connected', async () => { + const chainId = config.state.chainId + expect(config.state.chainId).toMatchInlineSnapshot('1') + await switchChain(config, { chainId: chain.mainnet2.id }) + expect(config.state.chainId).toMatchInlineSnapshot('456') + await switchChain(config, { chainId }) + expect(config.state.chainId).toMatchInlineSnapshot('1') +}) diff --git a/packages/core/src/actions/switchChain.ts b/packages/core/src/actions/switchChain.ts new file mode 100644 index 0000000000..59f337d141 --- /dev/null +++ b/packages/core/src/actions/switchChain.ts @@ -0,0 +1,83 @@ +import type { + AddEthereumChainParameter, + UserRejectedRequestErrorType, + SwitchChainErrorType as viem_SwitchChainErrorType, +} from 'viem' + +import type { Config } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import { + ChainNotConfiguredError, + type ChainNotConfiguredErrorType, +} from '../errors/config.js' +import { + type ProviderNotFoundErrorType, + SwitchChainNotSupportedError, + type SwitchChainNotSupportedErrorType, +} from '../errors/connector.js' +import type { ConnectorParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' + +export type SwitchChainParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute< + ConnectorParameter & { + chainId: chainId | config['chains'][number]['id'] + addEthereumChainParameter?: + | Compute>> + | undefined + } +> + +export type SwitchChainReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Extract< + config['chains'][number], + { id: Config extends config ? number : chainId } +> + +export type SwitchChainErrorType = + | SwitchChainNotSupportedErrorType + | ChainNotConfiguredErrorType + // connector.switchChain() + | ProviderNotFoundErrorType + | UserRejectedRequestErrorType + // base + | BaseErrorType + | ErrorType + // viem + | viem_SwitchChainErrorType + +/** https://wagmi.sh/core/api/actions/switchChain */ +export async function switchChain< + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: SwitchChainParameters, +): Promise> { + const { addEthereumChainParameter, chainId } = parameters + + const connection = config.state.connections.get( + parameters.connector?.uid ?? config.state.current!, + ) + if (connection) { + const connector = connection.connector + if (!connector.switchChain) + throw new SwitchChainNotSupportedError({ connector }) + const chain = await connector.switchChain({ + addEthereumChainParameter, + chainId, + }) + return chain as SwitchChainReturnType + } + + const chain = config.chains.find((x) => x.id === chainId) + if (!chain) throw new ChainNotConfiguredError() + config.setState((x) => ({ ...x, chainId })) + return chain as SwitchChainReturnType +} diff --git a/packages/core/src/actions/verifyMessage.test.ts b/packages/core/src/actions/verifyMessage.test.ts new file mode 100644 index 0000000000..f2766cbea4 --- /dev/null +++ b/packages/core/src/actions/verifyMessage.test.ts @@ -0,0 +1,72 @@ +import { accounts, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { verifyMessage } from './verifyMessage.js' + +const eoaAddress = accounts[0] +const smartAccountAddress = '0x3FCf42e10CC70Fe75A62EB3aDD6D305Aa840d145' + +test('smart account: valid signature', async () => { + expect( + await verifyMessage(config, { + address: smartAccountAddress, + message: 'This is a test message for viem!', + signature: + '0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c', + }), + ).toBe(true) +}) + +test('smart account: invalid signature', async () => { + expect( + await verifyMessage(config, { + address: smartAccountAddress, + message: 'This is a test message for viem!', + signature: '0xdead', + }), + ).toBe(false) +}) + +test('smart account: account not deployed', async () => { + expect( + await verifyMessage(config, { + blockNumber: 1234567890n, + address: smartAccountAddress, + message: 'This is a test message for viem!', + signature: + '0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c', + }), + ).toBe(false) +}) + +test('eoa: valid signature', async () => { + expect( + await verifyMessage(config, { + address: eoaAddress, + message: 'This is a test message for viem!', + signature: + '0xc4c7f2820177020d66d5fd00d084cdd3f575a868c059c29a2d7f23398d04819709a14f83d98b446dda539ca5dcb87d75aa3340eb15e66d67606850622a3420f61b', + }), + ).toBe(true) +}) + +test('eoa: invalid signature', async () => { + expect( + await verifyMessage(config, { + address: eoaAddress, + message: 'This is a test message for viem!', + signature: '0xdead', + }), + ).toBe(false) +}) + +test('eoa: raw message', async () => { + expect( + await verifyMessage(config, { + address: eoaAddress, + message: { raw: '0x68656c6c6f20776f726c64' }, + signature: + '0xa461f509887bd19e312c0c58467ce8ff8e300d3c1a90b608a760c5b80318eaf15fe57c96f9175d6cd4daad4663763baa7e78836e067d0163e9a2ccf2ff753f5b1b', + }), + ).toBe(true) +}) diff --git a/packages/core/src/actions/verifyMessage.ts b/packages/core/src/actions/verifyMessage.ts new file mode 100644 index 0000000000..851f8589fa --- /dev/null +++ b/packages/core/src/actions/verifyMessage.ts @@ -0,0 +1,30 @@ +import { + type VerifyMessageErrorType as viem_VerifyMessageErrorType, + type VerifyMessageParameters as viem_VerifyMessageParameters, + type VerifyMessageReturnType as viem_VerifyMessageReturnType, + verifyMessage as viem_verifyMessage, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type VerifyMessageParameters = Compute< + viem_VerifyMessageParameters & ChainIdParameter +> + +export type VerifyMessageReturnType = viem_VerifyMessageReturnType + +export type VerifyMessageErrorType = viem_VerifyMessageErrorType + +/** https://wagmi.sh/core/api/actions/verifyMessage */ +export async function verifyMessage( + config: config, + parameters: VerifyMessageParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_verifyMessage, 'verifyMessage') + return action(rest) +} diff --git a/packages/core/src/actions/verifyTypedData.test.ts b/packages/core/src/actions/verifyTypedData.test.ts new file mode 100644 index 0000000000..c4b98c68dc --- /dev/null +++ b/packages/core/src/actions/verifyTypedData.test.ts @@ -0,0 +1,42 @@ +import { config, typedData } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { verifyTypedData } from './verifyTypedData.js' + +const smartAccountAddress = '0x3FCf42e10CC70Fe75A62EB3aDD6D305Aa840d145' +const notDeployedAddress = '0xdeadbeefdeadbeefdeadbeefdeadbeefdeadbeef' + +test('valid signature', async () => { + expect( + await verifyTypedData(config, { + ...typedData.basic, + primaryType: 'Mail', + address: smartAccountAddress, + signature: + '0x79d756d805073dc97b7bc885b0d56ddf319a2599530fe1e178c2a7de5be88980068d24f20a79b318ea0a84d33ae06f93db77e4235e5d9eeb8b1d7a63922ada3e1c', + }), + ).toBe(true) +}) + +test('invalid signature', async () => { + expect( + await verifyTypedData(config, { + ...typedData.basic, + primaryType: 'Mail', + address: smartAccountAddress, + signature: '0xdead', + }), + ).toBe(false) +}) + +test('account not deployed', async () => { + expect( + await verifyTypedData(config, { + ...typedData.basic, + primaryType: 'Mail', + address: notDeployedAddress, + signature: + '0x79d756d805073dc97b7bc885b0d56ddf319a2599530fe1e178c2a7de5be88980068d24f20a79b318ea0a84d33ae06f93db77e4235e5d9eeb8b1d7a63922ada3e1c', + }), + ).toBe(false) +}) diff --git a/packages/core/src/actions/verifyTypedData.ts b/packages/core/src/actions/verifyTypedData.ts new file mode 100644 index 0000000000..4fac5463f5 --- /dev/null +++ b/packages/core/src/actions/verifyTypedData.ts @@ -0,0 +1,40 @@ +import type { TypedData } from 'viem' +import { + type VerifyTypedDataErrorType as viem_VerifyTypedDataErrorType, + type VerifyTypedDataParameters as viem_VerifyTypedDataParameters, + type VerifyTypedDataReturnType as viem_VerifyTypedDataReturnType, + verifyTypedData as viem_verifyTypedData, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type VerifyTypedDataParameters< + typedData extends TypedData | Record = TypedData, + primaryType extends keyof typedData | 'EIP712Domain' = keyof typedData, + config extends Config = Config, +> = Compute< + viem_VerifyTypedDataParameters & + ChainIdParameter +> + +export type VerifyTypedDataReturnType = viem_VerifyTypedDataReturnType + +export type VerifyTypedDataErrorType = viem_VerifyTypedDataErrorType + +/** https://wagmi.sh/core/api/actions/verifyTypedData */ +export async function verifyTypedData< + config extends Config, + const typedData extends TypedData | Record, + primaryType extends keyof typedData | 'EIP712Domain', +>( + config: config, + parameters: VerifyTypedDataParameters, +): Promise { + const { chainId, ...rest } = parameters + const client = config.getClient({ chainId }) + const action = getAction(client, viem_verifyTypedData, 'verifyTypedData') + return action(rest as viem_VerifyTypedDataParameters) +} diff --git a/packages/core/src/actions/waitForCallsStatus.test.ts b/packages/core/src/actions/waitForCallsStatus.test.ts new file mode 100644 index 0000000000..338fe02616 --- /dev/null +++ b/packages/core/src/actions/waitForCallsStatus.test.ts @@ -0,0 +1,77 @@ +import { accounts, config, testClient, wait } from '@wagmi/test' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { sendCalls } from './sendCalls.js' +import { waitForCallsStatus } from './waitForCallsStatus.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const { id } = await sendCalls(config, { + calls: [ + { + data: '0xdeadbeef', + to: accounts[1], + value: parseEther('1'), + }, + { + to: accounts[2], + value: parseEther('2'), + }, + { + to: accounts[3], + value: parseEther('3'), + }, + ], + }) + + const [{ receipts, status }] = await Promise.all([ + waitForCallsStatus(config, { + id, + }), + (async () => { + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + })(), + ]) + + expect(status).toBe('success') + expect( + receipts?.map((x) => ({ ...x, blockHash: undefined })), + ).toMatchInlineSnapshot( + ` + [ + { + "blockHash": undefined, + "blockNumber": 19258214n, + "gasUsed": 21064n, + "logs": [], + "status": "success", + "transactionHash": "0x13c53b2d4d9da424835525349cd66e553330f323d6fb19458b801ae1f7989a41", + }, + { + "blockHash": undefined, + "blockNumber": 19258214n, + "gasUsed": 21000n, + "logs": [], + "status": "success", + "transactionHash": "0xd8397b3e82b061c26a0c2093f1ceca0c3662a512614f7d6370349e89d0eea007", + }, + { + "blockHash": undefined, + "blockNumber": 19258214n, + "gasUsed": 21000n, + "logs": [], + "status": "success", + "transactionHash": "0x4d26e346593d9ea265bb164b115e89aa92df43b0b8778ac75d4ad28e2a22b101", + }, + ] + `, + ) + await disconnect(config, { connector }) +}) diff --git a/packages/core/src/actions/waitForCallsStatus.ts b/packages/core/src/actions/waitForCallsStatus.ts new file mode 100644 index 0000000000..a1c5764d32 --- /dev/null +++ b/packages/core/src/actions/waitForCallsStatus.ts @@ -0,0 +1,27 @@ +import { + type WaitForCallsStatusErrorType as viem_WaitForCallsStatusErrorType, + type WaitForCallsStatusParameters as viem_WaitForCallsStatusParameters, + type WaitForCallsStatusReturnType as viem_WaitForCallsStatusReturnType, + waitForCallsStatus as viem_waitForCallsStatus, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { ConnectorParameter } from '../types/properties.js' +import { getConnectorClient } from './getConnectorClient.js' + +export type WaitForCallsStatusParameters = viem_WaitForCallsStatusParameters & + ConnectorParameter + +export type WaitForCallsStatusReturnType = viem_WaitForCallsStatusReturnType + +export type WaitForCallsStatusErrorType = viem_WaitForCallsStatusErrorType + +/** https://wagmi.sh/core/api/actions/waitForCallsStatus */ +export async function waitForCallsStatus( + config: config, + parameters: WaitForCallsStatusParameters, +): Promise { + const { connector } = parameters + const client = await getConnectorClient(config, { connector }) + return viem_waitForCallsStatus(client, parameters) +} diff --git a/packages/core/src/actions/waitForTransactionReceipt.test-d.ts b/packages/core/src/actions/waitForTransactionReceipt.test-d.ts new file mode 100644 index 0000000000..0cce58d1e4 --- /dev/null +++ b/packages/core/src/actions/waitForTransactionReceipt.test-d.ts @@ -0,0 +1,36 @@ +import { http } from 'viem' +import { mainnet, zkSync } from 'viem/chains' +import type { ZkSyncL2ToL1Log, ZkSyncLog } from 'viem/zksync' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { waitForTransactionReceipt } from './waitForTransactionReceipt.js' + +test('chain formatters', async () => { + const config = createConfig({ + chains: [mainnet, zkSync], + transports: { [mainnet.id]: http(), [zkSync.id]: http() }, + }) + const result = await waitForTransactionReceipt(config, { hash: '0x123' }) + if (result.chainId === zkSync.id) { + expectTypeOf(result.l1BatchNumber).toEqualTypeOf() + expectTypeOf(result.l1BatchTxIndex).toEqualTypeOf() + expectTypeOf(result.logs).toEqualTypeOf() + expectTypeOf(result.l2ToL1Logs).toEqualTypeOf() + } +}) + +test('chainId', async () => { + const config = createConfig({ + chains: [zkSync], + transports: { [zkSync.id]: http() }, + }) + const result = await waitForTransactionReceipt(config, { + hash: '0x123', + chainId: zkSync.id, + }) + expectTypeOf(result.l1BatchNumber).toEqualTypeOf() + expectTypeOf(result.l1BatchTxIndex).toEqualTypeOf() + expectTypeOf(result.logs).toEqualTypeOf() + expectTypeOf(result.l2ToL1Logs).toEqualTypeOf() +}) diff --git a/packages/core/src/actions/waitForTransactionReceipt.test.ts b/packages/core/src/actions/waitForTransactionReceipt.test.ts new file mode 100644 index 0000000000..c060e82665 --- /dev/null +++ b/packages/core/src/actions/waitForTransactionReceipt.test.ts @@ -0,0 +1,58 @@ +import { config, testClient, wait } from '@wagmi/test' +import { parseEther } from 'viem' +import { beforeEach, expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { sendTransaction } from './sendTransaction.js' +import { waitForTransactionReceipt } from './waitForTransactionReceipt.js' + +const connector = config.connectors[0]! + +beforeEach(async () => { + if (config.state.current === connector.uid) + await disconnect(config, { connector }) +}) + +test('default', async () => { + await connect(config, { connector }) + + const hash = await sendTransaction(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) + + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + + await expect( + waitForTransactionReceipt(config, { hash }), + ).resolves.toMatchObject({ + chainId: 1, + transactionHash: hash, + }) + + await disconnect(config, { connector }) +}) + +test('behavior: transaction reverted', async () => { + await expect( + waitForTransactionReceipt(config, { + hash: '0x745367f76807d411b7fa4c3a552a62e3e45303ef40145fff04d84b867c2575d3', + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [CallExecutionError: Execution reverted with reason: PartyBid::claim: contribution already claimed. + + Raw Call Arguments: + to: 0xf1332f21487e74612ed3a0fb36da729b73f1ae19 + value: 0 ETH + data: 0x1e83409a000000000000000000000000a0cf798816d4b9b9866b5330eea46a18382f251e + gas: 128730 + maxFeePerGas: 43.307900987 gwei + maxPriorityFeePerGas: 1.5 gwei + nonce: 43 + + Details: execution reverted: PartyBid::claim: contribution already claimed + Version: viem@2.29.2] + `) +}) diff --git a/packages/core/src/actions/waitForTransactionReceipt.ts b/packages/core/src/actions/waitForTransactionReceipt.ts new file mode 100644 index 0000000000..5ac8fcdb20 --- /dev/null +++ b/packages/core/src/actions/waitForTransactionReceipt.ts @@ -0,0 +1,86 @@ +import type { Chain } from 'viem' +import { hexToString } from 'viem' +import { + call, + getTransaction, + type WaitForTransactionReceiptErrorType as viem_WaitForTransactionReceiptErrorType, + type WaitForTransactionReceiptParameters as viem_WaitForTransactionReceiptParameters, + type WaitForTransactionReceiptReturnType as viem_WaitForTransactionReceiptReturnType, + waitForTransactionReceipt as viem_waitForTransactionReceipt, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { SelectChains } from '../types/chain.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { Compute, IsNarrowable } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type WaitForTransactionReceiptParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute< + viem_WaitForTransactionReceiptParameters & ChainIdParameter +> + +export type WaitForTransactionReceiptReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = Compute< + { + [key in keyof chains]: viem_WaitForTransactionReceiptReturnType< + IsNarrowable extends true ? chains[key] : undefined + > & { chainId: chains[key]['id'] } + }[number] +> + +export type WaitForTransactionReceiptErrorType = + viem_WaitForTransactionReceiptErrorType + +export async function waitForTransactionReceipt< + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: WaitForTransactionReceiptParameters, +): Promise> { + const { chainId, timeout = 0, ...rest } = parameters + + const client = config.getClient({ chainId }) + const action = getAction( + client, + viem_waitForTransactionReceipt, + 'waitForTransactionReceipt', + ) + const receipt = await action({ ...rest, timeout }) + + if (receipt.status === 'reverted') { + const action_getTransaction = getAction( + client, + getTransaction, + 'getTransaction', + ) + const txn = await action_getTransaction({ hash: receipt.transactionHash }) + const action_call = getAction(client, call, 'call') + const code = await action_call({ + ...(txn as any), + data: txn.input, + gasPrice: txn.type !== 'eip1559' ? txn.gasPrice : undefined, + maxFeePerGas: txn.type === 'eip1559' ? txn.maxFeePerGas : undefined, + maxPriorityFeePerGas: + txn.type === 'eip1559' ? txn.maxPriorityFeePerGas : undefined, + }) + const reason = code?.data + ? hexToString(`0x${code.data.substring(138)}`) + : 'unknown reason' + throw new Error(reason) + } + + return { + ...receipt, + chainId: client.chain.id, + } as WaitForTransactionReceiptReturnType +} diff --git a/packages/core/src/actions/watchAccount.test.ts b/packages/core/src/actions/watchAccount.test.ts new file mode 100644 index 0000000000..c803165888 --- /dev/null +++ b/packages/core/src/actions/watchAccount.test.ts @@ -0,0 +1,38 @@ +import { config } from '@wagmi/test' +import type { Address } from 'viem' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { watchAccount } from './watchAccount.js' + +test('default', async () => { + const accounts: { address: Address | undefined; status: string }[] = [] + const unwatch = watchAccount(config, { + onChange(data) { + accounts.push({ address: data.address, status: data.status }) + }, + }) + + await connect(config, { connector: config.connectors[0]! }) + await disconnect(config) + + expect(accounts).toMatchInlineSnapshot(` + [ + { + "address": undefined, + "status": "connecting", + }, + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "status": "connected", + }, + { + "address": undefined, + "status": "disconnected", + }, + ] + `) + + unwatch() +}) diff --git a/packages/core/src/actions/watchAccount.ts b/packages/core/src/actions/watchAccount.ts new file mode 100644 index 0000000000..dfa8ae4908 --- /dev/null +++ b/packages/core/src/actions/watchAccount.ts @@ -0,0 +1,33 @@ +import type { Config } from '../createConfig.js' +import { deepEqual } from '../utils/deepEqual.js' +import { type GetAccountReturnType, getAccount } from './getAccount.js' + +export type WatchAccountParameters = { + onChange( + account: GetAccountReturnType, + prevAccount: GetAccountReturnType, + ): void +} + +export type WatchAccountReturnType = () => void + +/** https://wagmi.sh/core/api/actions/watchAccount */ +export function watchAccount( + config: config, + parameters: WatchAccountParameters, +): WatchAccountReturnType { + const { onChange } = parameters + + return config.subscribe(() => getAccount(config), onChange, { + equalityFn(a, b) { + const { connector: aConnector, ...aRest } = a + const { connector: bConnector, ...bRest } = b + return ( + deepEqual(aRest, bRest) && + // check connector separately + aConnector?.id === bConnector?.id && + aConnector?.uid === bConnector?.uid + ) + }, + }) +} diff --git a/packages/core/src/actions/watchAsset.test.ts b/packages/core/src/actions/watchAsset.test.ts new file mode 100644 index 0000000000..6d4cd86b58 --- /dev/null +++ b/packages/core/src/actions/watchAsset.test.ts @@ -0,0 +1,23 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { watchAsset } from './watchAsset.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + await expect( + watchAsset(config, { + type: 'ERC20', + options: { + address: '0x0000000000000000000000000000000000000000', + symbol: 'NULL', + decimals: 18, + }, + }), + ).resolves.toMatchInlineSnapshot('true') + await disconnect(config, { connector }) +}) diff --git a/packages/core/src/actions/watchAsset.ts b/packages/core/src/actions/watchAsset.ts new file mode 100644 index 0000000000..cd5690bf57 --- /dev/null +++ b/packages/core/src/actions/watchAsset.ts @@ -0,0 +1,44 @@ +import { + type WatchAssetErrorType as viem_WatchAssetErrorType, + type WatchAssetParameters as viem_WatchAssetParameters, + type WatchAssetReturnType as viem_WatchAssetReturnType, + watchAsset as viem_watchAsset, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import type { ConnectorParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' +import { + type GetConnectorClientErrorType, + getConnectorClient, +} from './getConnectorClient.js' + +export type WatchAssetParameters = Compute< + viem_WatchAssetParameters & ConnectorParameter +> + +export type WatchAssetReturnType = viem_WatchAssetReturnType + +export type WatchAssetErrorType = + // getConnectorClient() + | GetConnectorClientErrorType + // base + | BaseErrorType + | ErrorType + // viem + | viem_WatchAssetErrorType + +/** https://wagmi.sh/core/api/actions/watchAsset */ +export async function watchAsset( + config: Config, + parameters: WatchAssetParameters, +): Promise { + const { connector, ...rest } = parameters + + const client = await getConnectorClient(config, { connector }) + + const action = getAction(client, viem_watchAsset, 'watchAsset') + return action(rest as viem_WatchAssetParameters) +} diff --git a/packages/core/src/actions/watchBlockNumber.test-d.ts b/packages/core/src/actions/watchBlockNumber.test-d.ts new file mode 100644 index 0000000000..ae63ed8af6 --- /dev/null +++ b/packages/core/src/actions/watchBlockNumber.test-d.ts @@ -0,0 +1,56 @@ +import { http, webSocket } from 'viem' +import { mainnet, optimism } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { + type WatchBlockNumberParameters, + watchBlockNumber, +} from './watchBlockNumber.js' + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + type Result = WatchBlockNumberParameters< + typeof config, + typeof mainnet.id | typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + watchBlockNumber(config, { + poll: false, + onBlockNumber() {}, + }) + + type Result2 = WatchBlockNumberParameters + expectTypeOf().toEqualTypeOf() + watchBlockNumber(config, { + chainId: mainnet.id, + poll: true, + onBlockNumber() {}, + }) + watchBlockNumber(config, { + chainId: mainnet.id, + // @ts-expect-error + poll: false, + onBlockNumber() {}, + }) + + type Result3 = WatchBlockNumberParameters + expectTypeOf().toEqualTypeOf() + watchBlockNumber(config, { + chainId: optimism.id, + poll: true, + onBlockNumber() {}, + }) + watchBlockNumber(config, { + chainId: optimism.id, + poll: false, + onBlockNumber() {}, + }) +}) diff --git a/packages/core/src/actions/watchBlockNumber.test.ts b/packages/core/src/actions/watchBlockNumber.test.ts new file mode 100644 index 0000000000..0a4299db58 --- /dev/null +++ b/packages/core/src/actions/watchBlockNumber.test.ts @@ -0,0 +1,27 @@ +import { config, testClient, wait } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { watchBlockNumber } from './watchBlockNumber.js' + +test('default', async () => { + const blockNumbers: bigint[] = [] + const unwatch = watchBlockNumber(config, { + onBlockNumber(blockNumber) { + blockNumbers.push(blockNumber) + }, + }) + + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + + expect(blockNumbers.length).toBe(3) + expect( + blockNumbers.map((blockNumber) => blockNumber - blockNumbers[0]!), + ).toEqual([0n, 1n, 2n]) + + unwatch() +}) diff --git a/packages/core/src/actions/watchBlockNumber.ts b/packages/core/src/actions/watchBlockNumber.ts new file mode 100644 index 0000000000..712849080a --- /dev/null +++ b/packages/core/src/actions/watchBlockNumber.ts @@ -0,0 +1,78 @@ +import { + type WatchBlockNumberParameters as viem_WatchBlockNumberParameters, + type WatchBlockNumberReturnType as viem_WatchBlockNumberReturnType, + watchBlockNumber as viem_watchBlockNumber, +} from 'viem/actions' + +import type { Chain, Transport, WebSocketTransport } from 'viem' +import type { Config } from '../createConfig.js' +import type { SelectChains } from '../types/chain.js' +import type { + ChainIdParameter, + SyncConnectedChainParameter, +} from '../types/properties.js' +import type { UnionCompute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type WatchBlockNumberParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: UnionCompute< + viem_WatchBlockNumberParameters< + config['_internal']['transports'][chains[key]['id']] extends infer transport extends + Transport + ? Transport extends transport + ? WebSocketTransport + : transport + : WebSocketTransport + > & + ChainIdParameter & + SyncConnectedChainParameter + > +}[number] + +export type WatchBlockNumberReturnType = viem_WatchBlockNumberReturnType + +// TODO: wrap in viem's `observe` to avoid duplicate invocations. +/** https://wagmi.sh/core/api/actions/watchBlockNumber */ +export function watchBlockNumber< + config extends Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + config: config, + parameters: WatchBlockNumberParameters, +): WatchBlockNumberReturnType { + const { syncConnectedChain = config._internal.syncConnectedChain, ...rest } = + parameters as WatchBlockNumberParameters + + let unwatch: WatchBlockNumberReturnType | undefined + const listener = (chainId: number | undefined) => { + if (unwatch) unwatch() + + const client = config.getClient({ chainId }) + const action = getAction(client, viem_watchBlockNumber, 'watchBlockNumber') + unwatch = action(rest as viem_WatchBlockNumberParameters) + return unwatch + } + + // set up listener for block number changes + const unlisten = listener(parameters.chainId) + + // set up subscriber for connected chain changes + let unsubscribe: (() => void) | undefined + if (syncConnectedChain && !parameters.chainId) + unsubscribe = config.subscribe( + ({ chainId }) => chainId, + async (chainId) => listener(chainId), + ) + + return () => { + unlisten?.() + unsubscribe?.() + } +} diff --git a/packages/core/src/actions/watchBlocks.test-d.ts b/packages/core/src/actions/watchBlocks.test-d.ts new file mode 100644 index 0000000000..1899dcb1ae --- /dev/null +++ b/packages/core/src/actions/watchBlocks.test-d.ts @@ -0,0 +1,59 @@ +import { http, webSocket } from 'viem' +import { mainnet, optimism } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { type WatchBlocksParameters, watchBlocks } from './watchBlocks.js' + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + type Result = WatchBlocksParameters< + false, + 'latest', + typeof config, + typeof mainnet.id | typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + watchBlocks(config, { + poll: false, + onBlock() {}, + }) + + type Result2 = WatchBlocksParameters< + false, + 'latest', + typeof config, + typeof mainnet.id + > + expectTypeOf().toEqualTypeOf() + watchBlocks(config, { + chainId: mainnet.id, + poll: true, + onBlock() {}, + }) + + type Result3 = WatchBlocksParameters< + false, + 'latest', + typeof config, + typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + watchBlocks(config, { + chainId: optimism.id, + poll: true, + onBlock() {}, + }) + watchBlocks(config, { + chainId: optimism.id, + poll: false, + onBlock() {}, + }) +}) diff --git a/packages/core/src/actions/watchBlocks.test.ts b/packages/core/src/actions/watchBlocks.test.ts new file mode 100644 index 0000000000..caf4c0dc61 --- /dev/null +++ b/packages/core/src/actions/watchBlocks.test.ts @@ -0,0 +1,30 @@ +import { config, testClient, wait } from '@wagmi/test' +import { expect, test } from 'vitest' + +import type { Block } from 'viem' +import { watchBlocks } from './watchBlocks.js' + +test('default', async () => { + const blocks: Block[] = [] + const unwatch = watchBlocks(config, { + onBlock(block) { + blocks.push(block) + }, + }) + + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + + expect(blocks.length).toBe(3) + expect(blocks.map((block) => block.number! - blocks[0]?.number!)).toEqual([ + 0n, + 1n, + 2n, + ]) + + unwatch() +}) diff --git a/packages/core/src/actions/watchBlocks.ts b/packages/core/src/actions/watchBlocks.ts new file mode 100644 index 0000000000..c6f3225dc9 --- /dev/null +++ b/packages/core/src/actions/watchBlocks.ts @@ -0,0 +1,90 @@ +import { + type WatchBlocksParameters as viem_WatchBlocksParameters, + type WatchBlocksReturnType as viem_WatchBlocksReturnType, + watchBlocks as viem_watchBlocks, +} from 'viem/actions' + +import type { BlockTag, Chain, Transport, WebSocketTransport } from 'viem' +import type { Config } from '../createConfig.js' +import type { SelectChains } from '../types/chain.js' +import type { + ChainIdParameter, + SyncConnectedChainParameter, +} from '../types/properties.js' +import type { IsNarrowable, UnionCompute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type WatchBlocksParameters< + includeTransactions extends boolean = false, + blockTag extends BlockTag = 'latest', + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: UnionCompute< + viem_WatchBlocksParameters< + config['_internal']['transports'][chains[key]['id']] extends infer transport extends + Transport + ? Transport extends transport + ? WebSocketTransport + : transport + : WebSocketTransport, + IsNarrowable extends true ? chains[key] : undefined, + includeTransactions, + blockTag + > & + ChainIdParameter & + SyncConnectedChainParameter + > +}[number] + +export type WatchBlocksReturnType = viem_WatchBlocksReturnType + +// TODO: wrap in viem's `observe` to avoid duplicate invocations. +/** https://wagmi.sh/core/actions/watchBlocks */ +export function watchBlocks< + config extends Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + includeTransactions extends boolean = false, + blockTag extends BlockTag = 'latest', +>( + config: config, + parameters: WatchBlocksParameters< + includeTransactions, + blockTag, + config, + chainId + >, +): WatchBlocksReturnType { + const { syncConnectedChain = config._internal.syncConnectedChain, ...rest } = + parameters as WatchBlocksParameters + + let unwatch: WatchBlocksReturnType | undefined + const listener = (chainId: number | undefined) => { + if (unwatch) unwatch() + + const client = config.getClient({ chainId }) + const action = getAction(client, viem_watchBlocks, 'watchBlocks') + unwatch = action(rest as viem_WatchBlocksParameters) + return unwatch + } + + // set up listener for block number changes + const unlisten = listener(parameters.chainId) + + // set up subscriber for connected chain changes + let unsubscribe: (() => void) | undefined + if (syncConnectedChain && !parameters.chainId) + unsubscribe = config.subscribe( + ({ chainId }) => chainId, + async (chainId) => listener(chainId), + ) + + return () => { + unlisten?.() + unsubscribe?.() + } +} diff --git a/packages/core/src/actions/watchChainId.test.ts b/packages/core/src/actions/watchChainId.test.ts new file mode 100644 index 0000000000..9e27ba7edd --- /dev/null +++ b/packages/core/src/actions/watchChainId.test.ts @@ -0,0 +1,26 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { watchChainId } from './watchChainId.js' + +test('default', async () => { + const chainIds: number[] = [] + const unwatch = watchChainId(config, { + onChange(chainId) { + chainIds.push(chainId) + }, + }) + config.setState((x) => ({ ...x, chainId: chain.mainnet2.id })) + config.setState((x) => ({ ...x, chainId: chain.mainnet.id })) + config.setState((x) => ({ ...x, chainId: chain.mainnet2.id })) + + expect(chainIds).toMatchInlineSnapshot(` + [ + 456, + 1, + 456, + ] + `) + + unwatch() +}) diff --git a/packages/core/src/actions/watchChainId.ts b/packages/core/src/actions/watchChainId.ts new file mode 100644 index 0000000000..e3d4f010a4 --- /dev/null +++ b/packages/core/src/actions/watchChainId.ts @@ -0,0 +1,20 @@ +import type { Config } from '../createConfig.js' +import type { GetChainIdReturnType } from './getChainId.js' + +export type WatchChainIdParameters = { + onChange( + chainId: GetChainIdReturnType, + prevChainId: GetChainIdReturnType, + ): void +} + +export type WatchChainIdReturnType = () => void + +/** https://wagmi.sh/core/api/actions/watchChainId */ +export function watchChainId( + config: config, + parameters: WatchChainIdParameters, +): WatchChainIdReturnType { + const { onChange } = parameters + return config.subscribe((state) => state.chainId, onChange) +} diff --git a/packages/core/src/actions/watchChains.test.ts b/packages/core/src/actions/watchChains.test.ts new file mode 100644 index 0000000000..d7d586a833 --- /dev/null +++ b/packages/core/src/actions/watchChains.test.ts @@ -0,0 +1,37 @@ +import { chain, config } from '@wagmi/test' +import type { Chain } from 'viem' +import { expect, test } from 'vitest' + +import { watchChains } from './watchChains.js' + +test('default', async () => { + let chains: readonly [Chain, ...Chain[]] = config.chains + const unwatch = watchChains(config, { + onChange(nextChains) { + chains = nextChains + }, + }) + + config._internal.chains.setState([chain.mainnet, chain.mainnet2]) + expect(chains.map((x) => x.id)).toMatchInlineSnapshot(` + [ + 1, + 456, + ] + `) + + config._internal.chains.setState([ + chain.mainnet, + chain.mainnet2, + chain.optimism, + ]) + expect(chains.map((x) => x.id)).toMatchInlineSnapshot(` + [ + 1, + 456, + 10, + ] + `) + + unwatch() +}) diff --git a/packages/core/src/actions/watchChains.ts b/packages/core/src/actions/watchChains.ts new file mode 100644 index 0000000000..db5c496d5a --- /dev/null +++ b/packages/core/src/actions/watchChains.ts @@ -0,0 +1,29 @@ +import type { Config } from '../createConfig.js' +import type { GetChainsReturnType } from './getChains.js' + +export type WatchChainsParameters = { + onChange( + chains: GetChainsReturnType, + prevChains: GetChainsReturnType, + ): void +} + +export type WatchChainsReturnType = () => void + +/** + * @internal + * We don't expose this because as far as consumers know, you can't chainge (lol) `config.chains` at runtime. + * Setting `config.chains` via `config._internal.chains.setState(...)` is an extremely advanced use case that's not worth documenting or supporting in the public API at this time. + */ +export function watchChains( + config: config, + parameters: WatchChainsParameters, +): WatchChainsReturnType { + const { onChange } = parameters + return config._internal.chains.subscribe((chains, prevChains) => { + onChange( + chains as unknown as GetChainsReturnType, + prevChains as unknown as GetChainsReturnType, + ) + }) +} diff --git a/packages/core/src/actions/watchClient.test-d.ts b/packages/core/src/actions/watchClient.test-d.ts new file mode 100644 index 0000000000..42830f02c3 --- /dev/null +++ b/packages/core/src/actions/watchClient.test-d.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { watchClient } from './watchClient.js' + +test('default', () => { + watchClient(config, { + onChange(client) { + expectTypeOf(client.chain).toEqualTypeOf< + (typeof config)['chains'][number] + >() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() + }, + }) +}) diff --git a/packages/core/src/actions/watchClient.test.ts b/packages/core/src/actions/watchClient.test.ts new file mode 100644 index 0000000000..9cb5f447d2 --- /dev/null +++ b/packages/core/src/actions/watchClient.test.ts @@ -0,0 +1,23 @@ +import { config } from '@wagmi/test' +import type { Client } from 'viem' +import { expect, test } from 'vitest' + +import { switchChain } from './switchChain.js' +import { watchClient } from './watchClient.js' + +test('default', async () => { + const clients: Client[] = [] + const unwatch = watchClient(config, { + onChange(client) { + clients.push(client) + }, + }) + + switchChain(config, { chainId: 456 }) + switchChain(config, { chainId: 10 }) + switchChain(config, { chainId: 1 }) + + expect(clients.length).toBe(3) + + unwatch() +}) diff --git a/packages/core/src/actions/watchClient.ts b/packages/core/src/actions/watchClient.ts new file mode 100644 index 0000000000..4247353537 --- /dev/null +++ b/packages/core/src/actions/watchClient.ts @@ -0,0 +1,35 @@ +import type { Config } from '../createConfig.js' +import { type GetClientReturnType, getClient } from './getClient.js' + +export type WatchClientParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = { + onChange( + publicClient: GetClientReturnType, + prevClient: GetClientReturnType, + ): void +} + +export type WatchClientReturnType = () => void + +/** https://wagmi.sh/core/api/actions/watchClient */ +export function watchClient< + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: WatchClientParameters, +): WatchClientReturnType { + const { onChange } = parameters + return config.subscribe( + () => getClient(config) as GetClientReturnType, + onChange, + { + equalityFn(a, b) { + return a?.uid === b?.uid + }, + }, + ) +} diff --git a/packages/core/src/actions/watchConnections.test.ts b/packages/core/src/actions/watchConnections.test.ts new file mode 100644 index 0000000000..9ddf4444ab --- /dev/null +++ b/packages/core/src/actions/watchConnections.test.ts @@ -0,0 +1,25 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import type { Connection } from '../createConfig.js' +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { watchConnections } from './watchConnections.js' + +test('default', async () => { + const connections: Connection[][] = [] + const unwatch = watchConnections(config, { + onChange(connection) { + connections.push(connection) + }, + }) + + const connector = config.connectors[0]! + expect(connections).toEqual([]) + await connect(config, { connector }) + expect(connections[0]?.length).toEqual(1) + await disconnect(config, { connector }) + expect(connections[1]).toEqual([]) + + unwatch() +}) diff --git a/packages/core/src/actions/watchConnections.ts b/packages/core/src/actions/watchConnections.ts new file mode 100644 index 0000000000..56b94fd455 --- /dev/null +++ b/packages/core/src/actions/watchConnections.ts @@ -0,0 +1,26 @@ +import type { Config } from '../createConfig.js' +import { deepEqual } from '../utils/deepEqual.js' +import { + type GetConnectionsReturnType, + getConnections, +} from './getConnections.js' + +export type WatchConnectionsParameters = { + onChange( + connections: GetConnectionsReturnType, + prevConnections: GetConnectionsReturnType, + ): void +} + +export type WatchConnectionsReturnType = () => void + +/** https://wagmi.sh/core/api/actions/watchConnections */ +export function watchConnections( + config: Config, + parameters: WatchConnectionsParameters, +): WatchConnectionsReturnType { + const { onChange } = parameters + return config.subscribe(() => getConnections(config), onChange, { + equalityFn: deepEqual, + }) +} diff --git a/packages/core/src/actions/watchConnectors.test.ts b/packages/core/src/actions/watchConnectors.test.ts new file mode 100644 index 0000000000..6e66f75f93 --- /dev/null +++ b/packages/core/src/actions/watchConnectors.test.ts @@ -0,0 +1,27 @@ +import { accounts, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { mock } from '../connectors/mock.js' +import type { Connector } from '../createConfig.js' +import { watchConnectors } from './watchConnectors.js' + +test('default', async () => { + const connectors: (readonly Connector[])[] = [] + const unwatch = watchConnectors(config, { + onChange(connector) { + connectors.push(connector) + }, + }) + + const count = config.connectors.length + expect(config.connectors).toEqual(config.connectors) + + config._internal.connectors.setState(() => [ + ...config.connectors, + config._internal.connectors.setup(mock({ accounts })), + ]) + + expect(config.connectors.length).toBe(count + 1) + + unwatch() +}) diff --git a/packages/core/src/actions/watchConnectors.ts b/packages/core/src/actions/watchConnectors.ts new file mode 100644 index 0000000000..e463ab52fa --- /dev/null +++ b/packages/core/src/actions/watchConnectors.ts @@ -0,0 +1,22 @@ +import type { Config } from '../createConfig.js' +import type { GetConnectorsReturnType } from './getConnectors.js' + +export type WatchConnectorsParameters = { + onChange( + connections: GetConnectorsReturnType, + prevConnectors: GetConnectorsReturnType, + ): void +} + +export type WatchConnectorsReturnType = () => void + +/** https://wagmi.sh/core/api/actions/watchConnectors */ +export function watchConnectors( + config: config, + parameters: WatchConnectorsParameters, +): WatchConnectorsReturnType { + const { onChange } = parameters + return config._internal.connectors.subscribe((connectors, prevConnectors) => { + onChange(Object.values(connectors), prevConnectors) + }) +} diff --git a/packages/core/src/actions/watchContractEvent.test-d.ts b/packages/core/src/actions/watchContractEvent.test-d.ts new file mode 100644 index 0000000000..e6624fff57 --- /dev/null +++ b/packages/core/src/actions/watchContractEvent.test-d.ts @@ -0,0 +1,142 @@ +import { abi, config } from '@wagmi/test' +import { http, webSocket } from 'viem' +import { mainnet, optimism } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { + type WatchContractEventParameters, + watchContractEvent, +} from './watchContractEvent.js' + +test('default', () => { + watchContractEvent(config, { + address: '0x', + abi: abi.erc20, + eventName: 'Transfer', + args: { + from: '0x', + to: '0x', + }, + onLogs(logs) { + expectTypeOf(logs[0]!.eventName).toEqualTypeOf<'Transfer'>() + expectTypeOf(logs[0]!.args).toEqualTypeOf<{ + from?: `0x${string}` | undefined + to?: `0x${string}` | undefined + value?: bigint | undefined + }>() + }, + }) +}) + +test('behavior: no eventName', () => { + type Result = WatchContractEventParameters< + typeof abi.erc20, + undefined, + true, + typeof config + > + expectTypeOf().toEqualTypeOf< + | { + from?: `0x${string}` | `0x${string}`[] | null | undefined + to?: `0x${string}` | `0x${string}`[] | null | undefined + } + | { + owner?: `0x${string}` | `0x${string}`[] | null | undefined + spender?: `0x${string}` | `0x${string}`[] | null | undefined + } + | undefined + >() + + watchContractEvent(config, { + address: '0x', + abi: abi.erc20, + args: { + // TODO: Figure out why this is not working + // @ts-ignore + from: '0x', + to: '0x', + }, + onLogs(logs) { + expectTypeOf(logs[0]!.eventName).toEqualTypeOf<'Transfer' | 'Approval'>() + expectTypeOf(logs[0]!.args).toEqualTypeOf< + | Record + | readonly unknown[] + | { + from?: `0x${string}` | undefined + to?: `0x${string}` | undefined + value?: bigint | undefined + } + | { + owner?: `0x${string}` | undefined + spender?: `0x${string}` | undefined + value?: bigint | undefined + } + >() + }, + }) +}) + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + type Result = WatchContractEventParameters< + typeof abi.erc20, + 'Transfer' | 'Approval', + true, + typeof config, + typeof mainnet.id | typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + watchContractEvent(config, { + poll: false, + address: '0x', + abi: abi.erc20, + onLogs() {}, + }) + + type Result2 = WatchContractEventParameters< + typeof abi.erc20, + 'Transfer' | 'Approval', + true, + typeof config, + typeof mainnet.id + > + expectTypeOf().toEqualTypeOf() + watchContractEvent(config, { + chainId: mainnet.id, + poll: true, + address: '0x', + abi: abi.erc20, + onLogs() {}, + }) + + type Result3 = WatchContractEventParameters< + typeof abi.erc20, + 'Transfer' | 'Approval', + true, + typeof config, + typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + watchContractEvent(config, { + chainId: optimism.id, + poll: true, + address: '0x', + abi: abi.erc20, + onLogs() {}, + }) + watchContractEvent(config, { + chainId: optimism.id, + poll: false, + address: '0x', + abi: abi.erc20, + onLogs() {}, + }) +}) diff --git a/packages/core/src/actions/watchContractEvent.test.ts b/packages/core/src/actions/watchContractEvent.test.ts new file mode 100644 index 0000000000..759a21dd19 --- /dev/null +++ b/packages/core/src/actions/watchContractEvent.test.ts @@ -0,0 +1,96 @@ +import { + abi, + accounts, + address, + config, + testClient, + transactionHashRegex, + wait, +} from '@wagmi/test' +import { http, createWalletClient, parseEther } from 'viem' +import type { WatchEventOnLogsParameter } from 'viem/actions' +import { beforeEach, expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { getBalance } from './getBalance.js' +import { watchContractEvent } from './watchContractEvent.js' +import { writeContract } from './writeContract.js' + +const connector = config.connectors[0]! + +// TODO: Some test does not call disconnect after finishing. Remove once fixing it. +beforeEach(async () => { + if (config.state.current) { + const connection = config.state.connections.get(config.state.current)! + const connector = connection.connector + await disconnect(config, { connector }) + } +}) + +test('default', async () => { + const data = await connect(config, { connector }) + const connectedAddress = data.accounts[0] + + // impersonate usdc holder account and transfer usdc to connected account + await testClient.mainnet.impersonateAccount({ address: address.usdcHolder }) + await testClient.mainnet.setBalance({ + address: address.usdcHolder, + value: 10000000000000000000000n, + }) + await createWalletClient({ + account: address.usdcHolder, + chain: testClient.mainnet.chain, + transport: http(), + }).writeContract({ + address: address.usdc, + abi: abi.erc20, + functionName: 'transfer', + args: [connectedAddress, parseEther('10', 'gwei')], + }) + await testClient.mainnet.mine({ blocks: 1 }) + await testClient.mainnet.stopImpersonatingAccount({ + address: address.usdcHolder, + }) + + const balance = await getBalance(config, { + address: connectedAddress, + token: address.usdc, + }) + expect(balance.value).toBeGreaterThan(0n) + + // start watching transfer events + let logs: WatchEventOnLogsParameter = [] + const unwatch = watchContractEvent(config, { + address: address.usdc, + abi: abi.erc20, + eventName: 'Transfer', + onLogs(next) { + logs = logs.concat(next) + }, + }) + + await writeContract(config, { + address: address.usdc, + abi: abi.erc20, + functionName: 'transfer', + args: [accounts[1], parseEther('1', 'gwei')], + }) + + await writeContract(config, { + address: address.usdc, + abi: abi.erc20, + functionName: 'transfer', + args: [accounts[3], parseEther('1', 'gwei')], + }) + + await testClient.mainnet.mine({ blocks: 1 }) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(1000) // wait for events to be emitted + + unwatch() + expect(logs.length).toBe(2) + expect(logs[0]?.transactionHash).toMatch(transactionHashRegex) + + await disconnect(config, { connector }) +}) diff --git a/packages/core/src/actions/watchContractEvent.ts b/packages/core/src/actions/watchContractEvent.ts new file mode 100644 index 0000000000..ddc15741da --- /dev/null +++ b/packages/core/src/actions/watchContractEvent.ts @@ -0,0 +1,102 @@ +import type { + Abi, + Chain, + ContractEventName, + Transport, + WebSocketTransport, +} from 'viem' +import { + type WatchContractEventParameters as viem_WatchContractEventParameters, + type WatchContractEventReturnType as viem_WatchContractEventReturnType, + watchContractEvent as viem_watchContractEvent, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { SelectChains } from '../types/chain.js' +import type { + ChainIdParameter, + SyncConnectedChainParameter, +} from '../types/properties.js' +import type { UnionCompute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type WatchContractEventParameters< + abi extends Abi | readonly unknown[] = Abi, + eventName extends ContractEventName | undefined = ContractEventName, + strict extends boolean | undefined = undefined, + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: UnionCompute< + viem_WatchContractEventParameters< + abi, + eventName, + strict, + config['_internal']['transports'][chains[key]['id']] extends infer transport extends + Transport + ? Transport extends transport + ? WebSocketTransport + : transport + : WebSocketTransport + > & + ChainIdParameter & + SyncConnectedChainParameter + > +}[number] + +export type WatchContractEventReturnType = viem_WatchContractEventReturnType + +// TODO: wrap in viem's `observe` to avoid duplicate invocations. +/** https://wagmi.sh/core/api/actions/watchContractEvent */ +export function watchContractEvent< + config extends Config, + chainId extends config['chains'][number]['id'], + const abi extends Abi | readonly unknown[], + eventName extends ContractEventName | undefined, + strict extends boolean | undefined = undefined, +>( + config: config, + parameters: WatchContractEventParameters< + abi, + eventName, + strict, + config, + chainId + >, +) { + const { syncConnectedChain = config._internal.syncConnectedChain, ...rest } = + parameters + + let unwatch: WatchContractEventReturnType | undefined + const listener = (chainId: number | undefined) => { + if (unwatch) unwatch() + + const client = config.getClient({ chainId }) + const action = getAction( + client, + viem_watchContractEvent, + 'watchContractEvent', + ) + unwatch = action(rest as unknown as viem_WatchContractEventParameters) + return unwatch + } + + // set up listener for transaction changes + const unlisten = listener(parameters.chainId) + + // set up subscriber for connected chain changes + let unsubscribe: (() => void) | undefined + if (syncConnectedChain && !parameters.chainId) + unsubscribe = config.subscribe( + ({ chainId }) => chainId, + async (chainId) => listener(chainId), + ) + + return () => { + unlisten?.() + unsubscribe?.() + } +} diff --git a/packages/core/src/actions/watchPendingTransactions.test-d.ts b/packages/core/src/actions/watchPendingTransactions.test-d.ts new file mode 100644 index 0000000000..0af40a24c5 --- /dev/null +++ b/packages/core/src/actions/watchPendingTransactions.test-d.ts @@ -0,0 +1,56 @@ +import { http, webSocket } from 'viem' +import { mainnet, optimism } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { + type WatchPendingTransactionsParameters, + watchPendingTransactions, +} from './watchPendingTransactions.js' + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + type Result = WatchPendingTransactionsParameters< + typeof config, + typeof mainnet.id | typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + watchPendingTransactions(config, { + poll: false, + onTransactions() {}, + }) + + type Result2 = WatchPendingTransactionsParameters< + typeof config, + typeof mainnet.id + > + expectTypeOf().toEqualTypeOf() + watchPendingTransactions(config, { + chainId: mainnet.id, + poll: true, + onTransactions() {}, + }) + + type Result3 = WatchPendingTransactionsParameters< + typeof config, + typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + watchPendingTransactions(config, { + chainId: optimism.id, + poll: true, + onTransactions() {}, + }) + watchPendingTransactions(config, { + chainId: optimism.id, + poll: false, + onTransactions() {}, + }) +}) diff --git a/packages/core/src/actions/watchPendingTransactions.test.ts b/packages/core/src/actions/watchPendingTransactions.test.ts new file mode 100644 index 0000000000..510b9acce3 --- /dev/null +++ b/packages/core/src/actions/watchPendingTransactions.test.ts @@ -0,0 +1,49 @@ +import { + accounts, + config, + testClient, + transactionHashRegex, + wait, +} from '@wagmi/test' +import { parseEther } from 'viem' +import type { OnTransactionsParameter } from 'viem/actions' +import { expect, test } from 'vitest' + +import { connect } from './connect.js' +import { disconnect } from './disconnect.js' +import { sendTransaction } from './sendTransaction.js' +import { watchPendingTransactions } from './watchPendingTransactions.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + let transactions: OnTransactionsParameter = [] + const unwatch = watchPendingTransactions(config, { + onTransactions(next) { + transactions = [...transactions, ...next] + }, + }) + await wait(500) + + await sendTransaction(config, { + to: accounts[1], + value: parseEther('1'), + }) + await wait(100) + + await sendTransaction(config, { + to: accounts[3], + value: parseEther('1'), + }) + await wait(100) + + await testClient.mainnet.mine({ blocks: 1 }) + + unwatch() + expect(transactions.length).toBe(2) + expect(transactions[0]).toMatch(transactionHashRegex) + + await disconnect(config, { connector }) +}) diff --git a/packages/core/src/actions/watchPendingTransactions.ts b/packages/core/src/actions/watchPendingTransactions.ts new file mode 100644 index 0000000000..29f0354501 --- /dev/null +++ b/packages/core/src/actions/watchPendingTransactions.ts @@ -0,0 +1,82 @@ +import type { Chain, Transport, WebSocketTransport } from 'viem' +import { + type WatchPendingTransactionsParameters as viem_WatchPendingTransactionsParameters, + type WatchPendingTransactionsReturnType as viem_WatchPendingTransactionsReturnType, + watchPendingTransactions as viem_watchPendingTransactions, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { SelectChains } from '../types/chain.js' +import type { + ChainIdParameter, + SyncConnectedChainParameter, +} from '../types/properties.js' +import type { UnionCompute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' + +export type WatchPendingTransactionsParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: UnionCompute< + viem_WatchPendingTransactionsParameters< + config['_internal']['transports'][chains[key]['id']] extends infer transport extends + Transport + ? Transport extends transport + ? WebSocketTransport + : transport + : WebSocketTransport + > & + ChainIdParameter & + SyncConnectedChainParameter + > +}[number] + +export type WatchPendingTransactionsReturnType = + viem_WatchPendingTransactionsReturnType + +// TODO: wrap in viem's `observe` to avoid duplicate invocations. +/** https://wagmi.sh/core/api/actions/watchPendingTransactions */ +export function watchPendingTransactions< + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: WatchPendingTransactionsParameters, +) { + const { syncConnectedChain = config._internal.syncConnectedChain, ...rest } = + parameters + + let unwatch: WatchPendingTransactionsReturnType | undefined + const listener = (chainId: number | undefined) => { + if (unwatch) unwatch() + + const client = config.getClient({ chainId }) + const action = getAction( + client, + viem_watchPendingTransactions, + 'watchPendingTransactions', + ) + unwatch = action(rest as viem_WatchPendingTransactionsParameters) + return unwatch + } + + // set up listener for transaction changes + const unlisten = listener(parameters.chainId) + + // set up subscriber for connected chain changes + let unsubscribe: (() => void) | undefined + if (syncConnectedChain && !parameters.chainId) + unsubscribe = config.subscribe( + ({ chainId }) => chainId, + async (chainId) => listener(chainId), + ) + + return () => { + unlisten?.() + unsubscribe?.() + } +} diff --git a/packages/core/src/actions/watchPublicClient.test-d.ts b/packages/core/src/actions/watchPublicClient.test-d.ts new file mode 100644 index 0000000000..a7353636cb --- /dev/null +++ b/packages/core/src/actions/watchPublicClient.test-d.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { watchPublicClient } from './watchPublicClient.js' + +test('default', () => { + watchPublicClient(config, { + onChange(client) { + expectTypeOf(client.chain).toEqualTypeOf< + (typeof config)['chains'][number] + >() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() + }, + }) +}) diff --git a/packages/core/src/actions/watchPublicClient.test.ts b/packages/core/src/actions/watchPublicClient.test.ts new file mode 100644 index 0000000000..3d9594002c --- /dev/null +++ b/packages/core/src/actions/watchPublicClient.test.ts @@ -0,0 +1,23 @@ +import { config } from '@wagmi/test' +import type { Client } from 'viem' +import { expect, test } from 'vitest' + +import { switchChain } from './switchChain.js' +import { watchPublicClient } from './watchPublicClient.js' + +test('default', async () => { + const clients: Client[] = [] + const unwatch = watchPublicClient(config, { + onChange(client) { + clients.push(client) + }, + }) + + switchChain(config, { chainId: 456 }) + switchChain(config, { chainId: 10 }) + switchChain(config, { chainId: 1 }) + + expect(clients.length).toBe(3) + + unwatch() +}) diff --git a/packages/core/src/actions/watchPublicClient.ts b/packages/core/src/actions/watchPublicClient.ts new file mode 100644 index 0000000000..b7d854c2ad --- /dev/null +++ b/packages/core/src/actions/watchPublicClient.ts @@ -0,0 +1,38 @@ +import type { Config } from '../createConfig.js' +import { + type GetPublicClientReturnType, + getPublicClient, +} from './getPublicClient.js' + +export type WatchPublicClientParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = { + onChange( + publicClient: GetPublicClientReturnType, + prevPublicClient: GetPublicClientReturnType, + ): void +} + +export type WatchPublicClientReturnType = () => void + +/** https://wagmi.sh/core/api/actions/watchPublicClient */ +export function watchPublicClient< + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: WatchPublicClientParameters, +): WatchPublicClientReturnType { + const { onChange } = parameters + return config.subscribe( + () => getPublicClient(config) as GetPublicClientReturnType, + onChange, + { + equalityFn(a, b) { + return a?.uid === b?.uid + }, + }, + ) +} diff --git a/packages/core/src/actions/writeContract.test-d.ts b/packages/core/src/actions/writeContract.test-d.ts new file mode 100644 index 0000000000..68009a3773 --- /dev/null +++ b/packages/core/src/actions/writeContract.test-d.ts @@ -0,0 +1,152 @@ +import { abi, config } from '@wagmi/test' +import { http, type Address, parseAbi } from 'viem' +import { celo, mainnet } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { simulateContract } from './simulateContract.js' +import { type WriteContractParameters, writeContract } from './writeContract.js' + +test('default', async () => { + await writeContract(config, { + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 1, + }) +}) + +test('simulateContract', async () => { + const { request } = await simulateContract(config, { + account: '0x', + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 1, + }) + await writeContract(config, request) + await writeContract(config, { + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + }) +}) + +test('chain formatters', () => { + const config = createConfig({ + chains: [mainnet, celo], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + + type Result = WriteContractParameters< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config + > + expectTypeOf().toMatchTypeOf<{ + chainId?: typeof celo.id | typeof mainnet.id | undefined + feeCurrency?: `0x${string}` | undefined + }>() + writeContract(config, { + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + feeCurrency: '0x', + }) + + type Result2 = WriteContractParameters< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + typeof celo.id + > + expectTypeOf().toMatchTypeOf<{ + functionName: 'approve' | 'transfer' | 'transferFrom' + args: readonly [Address, Address, bigint] + feeCurrency?: `0x${string}` | undefined + }>() + writeContract(config, { + chainId: celo.id, + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + feeCurrency: '0x', + }) + + type Result3 = WriteContractParameters< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + typeof mainnet.id + > + expectTypeOf().toMatchTypeOf<{ + functionName: 'approve' | 'transfer' | 'transferFrom' + args: readonly [Address, Address, bigint] + }>() + expectTypeOf().not.toMatchTypeOf<{ + feeCurrency?: `0x${string}` | undefined + }>() + writeContract(config, { + chainId: mainnet.id, + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + // @ts-expect-error + feeCurrency: '0x', + }) +}) + +test('overloads', async () => { + const abi = parseAbi([ + 'function foo() returns (int8)', + 'function foo(address) returns (string)', + 'function foo(address, address) returns ((address foo, address bar))', + 'function bar(uint256) returns (int8)', + ]) + + type Result = WriteContractParameters + expectTypeOf().toEqualTypeOf<'foo' | 'bar'>() + expectTypeOf().toEqualTypeOf< + | readonly [] + | readonly [`0x${string}`] + | readonly [`0x${string}`, `0x${string}`] + | undefined + >() + writeContract(config, { + address: '0x', + abi, + functionName: 'foo', + }) + writeContract(config, { + address: '0x', + abi, + functionName: 'foo', + args: ['0x'], + }) + writeContract(config, { + address: '0x', + abi, + functionName: 'foo', + args: ['0x', '0x'], + }) + writeContract(config, { + address: '0x', + abi, + functionName: 'foo', + // @ts-expect-error + args: ['0x', 123n], + }) + + type Result2 = WriteContractParameters + expectTypeOf().toEqualTypeOf<'foo' | 'bar'>() + expectTypeOf().toEqualTypeOf() +}) diff --git a/packages/core/src/actions/writeContract.ts b/packages/core/src/actions/writeContract.ts new file mode 100644 index 0000000000..5fb6d87104 --- /dev/null +++ b/packages/core/src/actions/writeContract.ts @@ -0,0 +1,114 @@ +import type { + Abi, + Account, + Chain, + Client, + ContractFunctionArgs, + ContractFunctionName, +} from 'viem' +import { + type WriteContractErrorType as viem_WriteContractErrorType, + type WriteContractParameters as viem_WriteContractParameters, + type WriteContractReturnType as viem_WriteContractReturnType, + writeContract as viem_writeContract, +} from 'viem/actions' + +import type { Config } from '../createConfig.js' +import type { BaseErrorType, ErrorType } from '../errors/base.js' +import type { SelectChains } from '../types/chain.js' +import type { + ChainIdParameter, + ConnectorParameter, +} from '../types/properties.js' +import type { Compute, UnionCompute } from '../types/utils.js' +import { getAction } from '../utils/getAction.js' +import { + type GetConnectorClientErrorType, + getConnectorClient, +} from './getConnectorClient.js' + +export type WriteContractParameters< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'nonpayable' | 'payable' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + > = ContractFunctionArgs, + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + /// + allFunctionNames = ContractFunctionName, + chains extends readonly Chain[] = SelectChains, +> = UnionCompute< + { + // TODO: Should use `UnionStrictOmit<..., 'chain'>` on `viem_WriteContractParameters` result instead + // temp workaround that doesn't affect runtime behavior for for https://github.com/wevm/wagmi/issues/3981 + [key in keyof chains]: viem_WriteContractParameters< + abi, + functionName, + args, + chains[key], + Account, + chains[key], + allFunctionNames + > + }[number] & + Compute> & + ConnectorParameter & { + /** @deprecated */ + __mode?: 'prepared' + } +> + +export type WriteContractReturnType = viem_WriteContractReturnType + +export type WriteContractErrorType = + // getConnectorClient() + | GetConnectorClientErrorType + // base + | BaseErrorType + | ErrorType + // viem + | viem_WriteContractErrorType + +/** https://wagmi.sh/core/api/actions/writeContract */ +export async function writeContract< + config extends Config, + const abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: WriteContractParameters, +): Promise { + const { account, chainId, connector, ...request } = parameters + + let client: Client + if (typeof account === 'object' && account?.type === 'local') + client = config.getClient({ chainId }) + else + client = await getConnectorClient(config, { + account: account ?? undefined, + chainId, + connector, + }) + + const action = getAction(client, viem_writeContract, 'writeContract') + const hash = await action({ + ...(request as any), + ...(account ? { account } : {}), + chain: chainId ? { id: chainId } : null, + }) + + return hash +} diff --git a/packages/core/src/connectors/createConnector.test.ts b/packages/core/src/connectors/createConnector.test.ts new file mode 100644 index 0000000000..d1ff9f20af --- /dev/null +++ b/packages/core/src/connectors/createConnector.test.ts @@ -0,0 +1,31 @@ +import type { Address } from 'viem' +import { test } from 'vitest' +import { createConnector } from './createConnector.js' + +test('default', () => { + createConnector(() => { + return { + id: 'test', + name: 'Test Connector', + type: 'test', + async setup() {}, + async connect() { + return { accounts: [] as Address[], chainId: 123 } + }, + async disconnect() {}, + async getAccounts() { + return [] + }, + async getChainId() { + return 123 + }, + async isAuthorized() { + return true + }, + onAccountsChanged() {}, + onChainChanged() {}, + async onDisconnect(_error) {}, + async getProvider() {}, + } + }) +}) diff --git a/packages/core/src/connectors/createConnector.ts b/packages/core/src/connectors/createConnector.ts new file mode 100644 index 0000000000..54b4d9955c --- /dev/null +++ b/packages/core/src/connectors/createConnector.ts @@ -0,0 +1,93 @@ +import type { + AddEthereumChainParameter, + Address, + Chain, + Client, + ProviderConnectInfo, + ProviderMessage, +} from 'viem' + +import type { Transport } from '../createConfig.js' +import type { Emitter } from '../createEmitter.js' +import type { Storage } from '../createStorage.js' +import type { Compute, ExactPartial, StrictOmit } from '../types/utils.js' + +export type ConnectorEventMap = { + change: { + accounts?: readonly Address[] | undefined + chainId?: number | undefined + } + connect: { accounts: readonly Address[]; chainId: number } + disconnect: never + error: { error: Error } + message: { type: string; data?: unknown | undefined } +} + +export type CreateConnectorFn< + provider = unknown, + properties extends Record = Record, + storageItem extends Record = Record, +> = (config: { + chains: readonly [Chain, ...Chain[]] + emitter: Emitter + storage?: Compute> | null | undefined + transports?: Record | undefined +}) => Compute< + { + readonly icon?: string | undefined + readonly id: string + readonly name: string + readonly rdns?: string | readonly string[] | undefined + /** @deprecated */ + readonly supportsSimulation?: boolean | undefined + readonly type: string + + setup?(): Promise + connect( + parameters?: + | { chainId?: number | undefined; isReconnecting?: boolean | undefined } + | undefined, + ): Promise<{ + accounts: readonly Address[] + chainId: number + }> + disconnect(): Promise + getAccounts(): Promise + getChainId(): Promise + getProvider( + parameters?: { chainId?: number | undefined } | undefined, + ): Promise + getClient?( + parameters?: { chainId?: number | undefined } | undefined, + ): Promise + isAuthorized(): Promise + switchChain?( + parameters: Compute<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + }>, + ): Promise + + onAccountsChanged(accounts: string[]): void + onChainChanged(chainId: string): void + onConnect?(connectInfo: ProviderConnectInfo): void + onDisconnect(error?: Error | undefined): void + onMessage?(message: ProviderMessage): void + } & properties +> + +export function createConnector< + provider, + properties extends Record = Record, + storageItem extends Record = Record, + /// + createConnectorFn extends CreateConnectorFn< + provider, + properties, + storageItem + > = CreateConnectorFn, +>(createConnectorFn: createConnectorFn) { + return createConnectorFn +} diff --git a/packages/core/src/connectors/injected.test.ts b/packages/core/src/connectors/injected.test.ts new file mode 100644 index 0000000000..9188a53bae --- /dev/null +++ b/packages/core/src/connectors/injected.test.ts @@ -0,0 +1,25 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { injected } from './injected.js' + +test('setup', () => { + const connectorFn = injected() + const connector = config._internal.connectors.setup(connectorFn) + expect(connector.name).toEqual('Injected') +}) + +test.each([ + { wallet: undefined, expected: 'Injected' }, + { wallet: 'coinbaseWallet', expected: 'Coinbase Wallet' }, + { wallet: 'metaMask', expected: 'MetaMask' }, + { wallet: 'phantom', expected: 'Phantom' }, + { wallet: 'rainbow', expected: 'Rainbow' }, +] as const satisfies readonly { + wallet: string | undefined + expected: string +}[])('injected({ wallet: $wallet })', ({ wallet, expected }) => { + const connectorFn = injected({ target: wallet }) + const connector = config._internal.connectors.setup(connectorFn) + expect(connector.name).toEqual(expected) +}) diff --git a/packages/core/src/connectors/injected.ts b/packages/core/src/connectors/injected.ts new file mode 100644 index 0000000000..d686d0aa29 --- /dev/null +++ b/packages/core/src/connectors/injected.ts @@ -0,0 +1,697 @@ +import { + type AddEthereumChainParameter, + type Address, + type EIP1193Provider, + type ProviderConnectInfo, + type ProviderRpcError, + ResourceUnavailableRpcError, + type RpcError, + SwitchChainError, + UserRejectedRequestError, + getAddress, + numberToHex, + withRetry, + withTimeout, +} from 'viem' + +import type { Connector } from '../createConfig.js' +import { ChainNotConfiguredError } from '../errors/config.js' +import { ProviderNotFoundError } from '../errors/connector.js' +import type { Compute } from '../types/utils.js' +import { createConnector } from './createConnector.js' + +export type InjectedParameters = { + /** + * Some injected providers do not support programmatic disconnect. + * This flag simulates the disconnect behavior by keeping track of connection status in storage. + * @default true + */ + shimDisconnect?: boolean | undefined + /** + * [EIP-1193](https://eips.ethereum.org/EIPS/eip-1193) Ethereum Provider to target + */ + target?: TargetId | Target | (() => Target | undefined) | undefined + unstable_shimAsyncInject?: boolean | number | undefined +} + +injected.type = 'injected' as const +export function injected(parameters: InjectedParameters = {}) { + const { shimDisconnect = true, unstable_shimAsyncInject } = parameters + + function getTarget(): Compute { + const target = parameters.target + if (typeof target === 'function') { + const result = target() + if (result) return result + } + + if (typeof target === 'object') return target + + if (typeof target === 'string') + return { + ...(targetMap[target as keyof typeof targetMap] ?? { + id: target, + name: `${target[0]!.toUpperCase()}${target.slice(1)}`, + provider: `is${target[0]!.toUpperCase()}${target.slice(1)}`, + }), + } + + return { + id: 'injected', + name: 'Injected', + provider(window) { + return window?.ethereum + }, + } + } + + type Provider = WalletProvider | undefined + type Properties = { + onConnect(connectInfo: ProviderConnectInfo): void + } + type StorageItem = { + [_ in 'injected.connected' | `${string}.disconnected`]: true + } + + let accountsChanged: Connector['onAccountsChanged'] | undefined + let chainChanged: Connector['onChainChanged'] | undefined + let connect: Connector['onConnect'] | undefined + let disconnect: Connector['onDisconnect'] | undefined + + return createConnector((config) => ({ + get icon() { + return getTarget().icon + }, + get id() { + return getTarget().id + }, + get name() { + return getTarget().name + }, + /** @deprecated */ + get supportsSimulation() { + return true + }, + type: injected.type, + async setup() { + const provider = await this.getProvider() + // Only start listening for events if `target` is set, otherwise `injected()` will also receive events + if (provider?.on && parameters.target) { + if (!connect) { + connect = this.onConnect.bind(this) + provider.on('connect', connect) + } + + // We shouldn't need to listen for `'accountsChanged'` here since the `'connect'` event should suffice (and wallet shouldn't be connected yet). + // Some wallets, like MetaMask, do not implement the `'connect'` event and overload `'accountsChanged'` instead. + if (!accountsChanged) { + accountsChanged = this.onAccountsChanged.bind(this) + provider.on('accountsChanged', accountsChanged) + } + } + }, + async connect({ chainId, isReconnecting } = {}) { + const provider = await this.getProvider() + if (!provider) throw new ProviderNotFoundError() + + let accounts: readonly Address[] = [] + if (isReconnecting) accounts = await this.getAccounts().catch(() => []) + else if (shimDisconnect) { + // Attempt to show another prompt for selecting account if `shimDisconnect` flag is enabled + try { + const permissions = await provider.request({ + method: 'wallet_requestPermissions', + params: [{ eth_accounts: {} }], + }) + accounts = (permissions[0]?.caveats?.[0]?.value as string[])?.map( + (x) => getAddress(x), + ) + // `'wallet_requestPermissions'` can return a different order of accounts than `'eth_accounts'` + // switch to `'eth_accounts'` ordering if more than one account is connected + // https://github.com/wevm/wagmi/issues/4140 + if (accounts.length > 0) { + const sortedAccounts = await this.getAccounts() + accounts = sortedAccounts + } + } catch (err) { + const error = err as RpcError + // Not all injected providers support `wallet_requestPermissions` (e.g. MetaMask iOS). + // Only bubble up error if user rejects request + if (error.code === UserRejectedRequestError.code) + throw new UserRejectedRequestError(error) + // Or prompt is already open + if (error.code === ResourceUnavailableRpcError.code) throw error + } + } + + try { + if (!accounts?.length && !isReconnecting) { + const requestedAccounts = await provider.request({ + method: 'eth_requestAccounts', + }) + accounts = requestedAccounts.map((x) => getAddress(x)) + } + + // Manage EIP-1193 event listeners + // https://eips.ethereum.org/EIPS/eip-1193#events + if (connect) { + provider.removeListener('connect', connect) + connect = undefined + } + if (!accountsChanged) { + accountsChanged = this.onAccountsChanged.bind(this) + provider.on('accountsChanged', accountsChanged) + } + if (!chainChanged) { + chainChanged = this.onChainChanged.bind(this) + provider.on('chainChanged', chainChanged) + } + if (!disconnect) { + disconnect = this.onDisconnect.bind(this) + provider.on('disconnect', disconnect) + } + + // Switch to chain if provided + let currentChainId = await this.getChainId() + if (chainId && currentChainId !== chainId) { + const chain = await this.switchChain!({ chainId }).catch((error) => { + if (error.code === UserRejectedRequestError.code) throw error + return { id: currentChainId } + }) + currentChainId = chain?.id ?? currentChainId + } + + // Remove disconnected shim if it exists + if (shimDisconnect) + await config.storage?.removeItem(`${this.id}.disconnected`) + + // Add connected shim if no target exists + if (!parameters.target) + await config.storage?.setItem('injected.connected', true) + + return { accounts, chainId: currentChainId } + } catch (err) { + const error = err as RpcError + if (error.code === UserRejectedRequestError.code) + throw new UserRejectedRequestError(error) + if (error.code === ResourceUnavailableRpcError.code) + throw new ResourceUnavailableRpcError(error) + throw error + } + }, + async disconnect() { + const provider = await this.getProvider() + if (!provider) throw new ProviderNotFoundError() + + // Manage EIP-1193 event listeners + if (chainChanged) { + provider.removeListener('chainChanged', chainChanged) + chainChanged = undefined + } + if (disconnect) { + provider.removeListener('disconnect', disconnect) + disconnect = undefined + } + if (!connect) { + connect = this.onConnect.bind(this) + provider.on('connect', connect) + } + + // Experimental support for MetaMask disconnect + // https://github.com/MetaMask/metamask-improvement-proposals/blob/main/MIPs/mip-2.md + try { + // Adding timeout as not all wallets support this method and can hang + // https://github.com/wevm/wagmi/issues/4064 + await withTimeout( + () => + // TODO: Remove explicit type for viem@3 + provider.request<{ + Method: 'wallet_revokePermissions' + Parameters: [permissions: { eth_accounts: Record }] + ReturnType: null + }>({ + // `'wallet_revokePermissions'` added in `viem@2.10.3` + method: 'wallet_revokePermissions', + params: [{ eth_accounts: {} }], + }), + { timeout: 100 }, + ) + } catch {} + + // Add shim signalling connector is disconnected + if (shimDisconnect) { + await config.storage?.setItem(`${this.id}.disconnected`, true) + } + + if (!parameters.target) + await config.storage?.removeItem('injected.connected') + }, + async getAccounts() { + const provider = await this.getProvider() + if (!provider) throw new ProviderNotFoundError() + const accounts = await provider.request({ method: 'eth_accounts' }) + return accounts.map((x) => getAddress(x)) + }, + async getChainId() { + const provider = await this.getProvider() + if (!provider) throw new ProviderNotFoundError() + const hexChainId = await provider.request({ method: 'eth_chainId' }) + return Number(hexChainId) + }, + async getProvider() { + if (typeof window === 'undefined') return undefined + + let provider: Provider + const target = getTarget() + if (typeof target.provider === 'function') + provider = target.provider(window as Window | undefined) + else if (typeof target.provider === 'string') + provider = findProvider(window, target.provider) + else provider = target.provider + + // Some wallets do not conform to EIP-1193 (e.g. Trust Wallet) + // https://github.com/wevm/wagmi/issues/3526#issuecomment-1912683002 + if (provider && !provider.removeListener) { + // Try using `off` handler if it exists, otherwise noop + if ('off' in provider && typeof provider.off === 'function') + provider.removeListener = + provider.off as typeof provider.removeListener + else provider.removeListener = () => {} + } + + return provider + }, + async isAuthorized() { + try { + const isDisconnected = + shimDisconnect && + // If shim exists in storage, connector is disconnected + (await config.storage?.getItem(`${this.id}.disconnected`)) + if (isDisconnected) return false + + // Don't allow injected connector to connect if no target is set and it hasn't already connected + // (e.g. flag in storage is not set). This prevents a targetless injected connector from connecting + // automatically whenever there is a targeted connector configured. + if (!parameters.target) { + const connected = await config.storage?.getItem('injected.connected') + if (!connected) return false + } + + const provider = await this.getProvider() + if (!provider) { + if ( + unstable_shimAsyncInject !== undefined && + unstable_shimAsyncInject !== false + ) { + // If no provider is found, check for async injection + // https://github.com/wevm/references/issues/167 + // https://github.com/MetaMask/detect-provider + const handleEthereum = async () => { + if (typeof window !== 'undefined') + window.removeEventListener( + 'ethereum#initialized', + handleEthereum, + ) + const provider = await this.getProvider() + return !!provider + } + const timeout = + typeof unstable_shimAsyncInject === 'number' + ? unstable_shimAsyncInject + : 1_000 + const res = await Promise.race([ + ...(typeof window !== 'undefined' + ? [ + new Promise((resolve) => + window.addEventListener( + 'ethereum#initialized', + () => resolve(handleEthereum()), + { once: true }, + ), + ), + ] + : []), + new Promise((resolve) => + setTimeout(() => resolve(handleEthereum()), timeout), + ), + ]) + if (res) return true + } + + throw new ProviderNotFoundError() + } + + // Use retry strategy as some injected wallets (e.g. MetaMask) fail to + // immediately resolve JSON-RPC requests on page load. + const accounts = await withRetry(() => this.getAccounts()) + return !!accounts.length + } catch { + return false + } + }, + async switchChain({ addEthereumChainParameter, chainId }) { + const provider = await this.getProvider() + if (!provider) throw new ProviderNotFoundError() + + const chain = config.chains.find((x) => x.id === chainId) + if (!chain) throw new SwitchChainError(new ChainNotConfiguredError()) + + const promise = new Promise((resolve) => { + const listener = ((data) => { + if ('chainId' in data && data.chainId === chainId) { + config.emitter.off('change', listener) + resolve() + } + }) satisfies Parameters[1] + config.emitter.on('change', listener) + }) + + try { + await Promise.all([ + provider + .request({ + method: 'wallet_switchEthereumChain', + params: [{ chainId: numberToHex(chainId) }], + }) + // During `'wallet_switchEthereumChain'`, MetaMask makes a `'net_version'` RPC call to the target chain. + // If this request fails, MetaMask does not emit the `'chainChanged'` event, but will still switch the chain. + // To counter this behavior, we request and emit the current chain ID to confirm the chain switch either via + // this callback or an externally emitted `'chainChanged'` event. + // https://github.com/MetaMask/metamask-extension/issues/24247 + .then(async () => { + const currentChainId = await this.getChainId() + if (currentChainId === chainId) + config.emitter.emit('change', { chainId }) + }), + promise, + ]) + return chain + } catch (err) { + const error = err as RpcError + + // Indicates chain is not added to provider + if ( + error.code === 4902 || + // Unwrapping for MetaMask Mobile + // https://github.com/MetaMask/metamask-mobile/issues/2944#issuecomment-976988719 + (error as ProviderRpcError<{ originalError?: { code: number } }>) + ?.data?.originalError?.code === 4902 + ) { + try { + const { default: blockExplorer, ...blockExplorers } = + chain.blockExplorers ?? {} + let blockExplorerUrls: string[] | undefined + if (addEthereumChainParameter?.blockExplorerUrls) + blockExplorerUrls = addEthereumChainParameter.blockExplorerUrls + else if (blockExplorer) + blockExplorerUrls = [ + blockExplorer.url, + ...Object.values(blockExplorers).map((x) => x.url), + ] + + let rpcUrls: readonly string[] + if (addEthereumChainParameter?.rpcUrls?.length) + rpcUrls = addEthereumChainParameter.rpcUrls + else rpcUrls = [chain.rpcUrls.default?.http[0] ?? ''] + + const addEthereumChain = { + blockExplorerUrls, + chainId: numberToHex(chainId), + chainName: addEthereumChainParameter?.chainName ?? chain.name, + iconUrls: addEthereumChainParameter?.iconUrls, + nativeCurrency: + addEthereumChainParameter?.nativeCurrency ?? + chain.nativeCurrency, + rpcUrls, + } satisfies AddEthereumChainParameter + + await Promise.all([ + provider + .request({ + method: 'wallet_addEthereumChain', + params: [addEthereumChain], + }) + .then(async () => { + const currentChainId = await this.getChainId() + if (currentChainId === chainId) + config.emitter.emit('change', { chainId }) + else + throw new UserRejectedRequestError( + new Error('User rejected switch after adding network.'), + ) + }), + promise, + ]) + + return chain + } catch (error) { + throw new UserRejectedRequestError(error as Error) + } + } + + if (error.code === UserRejectedRequestError.code) + throw new UserRejectedRequestError(error) + throw new SwitchChainError(error) + } + }, + async onAccountsChanged(accounts) { + // Disconnect if there are no accounts + if (accounts.length === 0) this.onDisconnect() + // Connect if emitter is listening for connect event (e.g. is disconnected and connects through wallet interface) + else if (config.emitter.listenerCount('connect')) { + const chainId = (await this.getChainId()).toString() + this.onConnect({ chainId }) + // Remove disconnected shim if it exists + if (shimDisconnect) + await config.storage?.removeItem(`${this.id}.disconnected`) + } + // Regular change event + else + config.emitter.emit('change', { + accounts: accounts.map((x) => getAddress(x)), + }) + }, + onChainChanged(chain) { + const chainId = Number(chain) + config.emitter.emit('change', { chainId }) + }, + async onConnect(connectInfo) { + const accounts = await this.getAccounts() + if (accounts.length === 0) return + + const chainId = Number(connectInfo.chainId) + config.emitter.emit('connect', { accounts, chainId }) + + // Manage EIP-1193 event listeners + const provider = await this.getProvider() + if (provider) { + if (connect) { + provider.removeListener('connect', connect) + connect = undefined + } + if (!accountsChanged) { + accountsChanged = this.onAccountsChanged.bind(this) + provider.on('accountsChanged', accountsChanged) + } + if (!chainChanged) { + chainChanged = this.onChainChanged.bind(this) + provider.on('chainChanged', chainChanged) + } + if (!disconnect) { + disconnect = this.onDisconnect.bind(this) + provider.on('disconnect', disconnect) + } + } + }, + async onDisconnect(error) { + const provider = await this.getProvider() + + // If MetaMask emits a `code: 1013` error, wait for reconnection before disconnecting + // https://github.com/MetaMask/providers/pull/120 + if (error && (error as RpcError<1013>).code === 1013) { + if (provider && !!(await this.getAccounts()).length) return + } + + // No need to remove `${this.id}.disconnected` from storage because `onDisconnect` is typically + // only called when the wallet is disconnected through the wallet's interface, meaning the wallet + // actually disconnected and we don't need to simulate it. + config.emitter.emit('disconnect') + + // Manage EIP-1193 event listeners + if (provider) { + if (chainChanged) { + provider.removeListener('chainChanged', chainChanged) + chainChanged = undefined + } + if (disconnect) { + provider.removeListener('disconnect', disconnect) + disconnect = undefined + } + if (!connect) { + connect = this.onConnect.bind(this) + provider.on('connect', connect) + } + } + }, + })) +} + +const targetMap = { + coinbaseWallet: { + id: 'coinbaseWallet', + name: 'Coinbase Wallet', + provider(window) { + if (window?.coinbaseWalletExtension) return window.coinbaseWalletExtension + return findProvider(window, 'isCoinbaseWallet') + }, + }, + metaMask: { + id: 'metaMask', + name: 'MetaMask', + provider(window) { + return findProvider(window, (provider) => { + if (!provider.isMetaMask) return false + // Brave tries to make itself look like MetaMask + // Could also try RPC `web3_clientVersion` if following is unreliable + if (provider.isBraveWallet && !provider._events && !provider._state) + return false + // Other wallets that try to look like MetaMask + const flags = [ + 'isApexWallet', + 'isAvalanche', + 'isBitKeep', + 'isBlockWallet', + 'isKuCoinWallet', + 'isMathWallet', + 'isOkxWallet', + 'isOKExWallet', + 'isOneInchIOSWallet', + 'isOneInchAndroidWallet', + 'isOpera', + 'isPhantom', + 'isPortal', + 'isRabby', + 'isTokenPocket', + 'isTokenary', + 'isUniswapWallet', + 'isZerion', + ] satisfies WalletProviderFlags[] + for (const flag of flags) if (provider[flag]) return false + return true + }) + }, + }, + phantom: { + id: 'phantom', + name: 'Phantom', + provider(window) { + if (window?.phantom?.ethereum) return window.phantom?.ethereum + return findProvider(window, 'isPhantom') + }, + }, +} as const satisfies TargetMap + +type TargetMap = { [_ in TargetId]?: Target | undefined } + +type Target = { + icon?: string | undefined + id: string + name: string + provider: + | WalletProviderFlags + | WalletProvider + | ((window?: Window | undefined) => WalletProvider | undefined) +} + +/** @deprecated */ +type TargetId = Compute extends `is${infer name}` + ? name extends `${infer char}${infer rest}` + ? `${Lowercase}${rest}` + : never + : never + +/** + * @deprecated As of 2024/10/16, we are no longer accepting new provider flags as EIP-6963 should be used instead. + */ +type WalletProviderFlags = + | 'isApexWallet' + | 'isAvalanche' + | 'isBackpack' + | 'isBifrost' + | 'isBitKeep' + | 'isBitski' + | 'isBlockWallet' + | 'isBraveWallet' + | 'isCoinbaseWallet' + | 'isDawn' + | 'isEnkrypt' + | 'isExodus' + | 'isFrame' + | 'isFrontier' + | 'isGamestop' + | 'isHyperPay' + | 'isImToken' + | 'isKuCoinWallet' + | 'isMathWallet' + | 'isMetaMask' + | 'isOkxWallet' + | 'isOKExWallet' + | 'isOneInchAndroidWallet' + | 'isOneInchIOSWallet' + | 'isOpera' + | 'isPhantom' + | 'isPortal' + | 'isRabby' + | 'isRainbow' + | 'isStatus' + | 'isTally' + | 'isTokenPocket' + | 'isTokenary' + | 'isTrust' + | 'isTrustWallet' + | 'isUniswapWallet' + | 'isXDEFI' + | 'isZerion' + +type WalletProvider = Compute< + EIP1193Provider & { + [key in WalletProviderFlags]?: true | undefined + } & { + providers?: WalletProvider[] | undefined + /** Only exists in MetaMask as of 2022/04/03 */ + _events?: { connect?: (() => void) | undefined } | undefined + /** Only exists in MetaMask as of 2022/04/03 */ + _state?: + | { + accounts?: string[] + initialized?: boolean + isConnected?: boolean + isPermanentlyDisconnected?: boolean + isUnlocked?: boolean + } + | undefined + } +> + +type Window = { + coinbaseWalletExtension?: WalletProvider | undefined + ethereum?: WalletProvider | undefined + phantom?: { ethereum: WalletProvider } | undefined +} + +function findProvider( + window: globalThis.Window | Window | undefined, + select?: WalletProviderFlags | ((provider: WalletProvider) => boolean), +) { + function isProvider(provider: WalletProvider) { + if (typeof select === 'function') return select(provider) + if (typeof select === 'string') return provider[select] + return true + } + + const ethereum = (window as Window).ethereum + if (ethereum?.providers) + return ethereum.providers.find((provider) => isProvider(provider)) + if (ethereum && isProvider(ethereum)) return ethereum + return undefined +} diff --git a/packages/core/src/connectors/mock.test.ts b/packages/core/src/connectors/mock.test.ts new file mode 100644 index 0000000000..d8a812a3d7 --- /dev/null +++ b/packages/core/src/connectors/mock.test.ts @@ -0,0 +1,112 @@ +import { accounts, config } from '@wagmi/test' +import { expect, expectTypeOf, test } from 'vitest' + +import type { Connector } from '../createConfig.js' +import type { CreateConnectorFn } from './createConnector.js' +import { mock } from './mock.js' + +test('setup', () => { + const connectorFn = mock({ accounts }) + const connector = config._internal.connectors.setup(connectorFn) + expect(connector.name).toEqual('Mock Connector') + + expectTypeOf< + typeof connectorFn extends CreateConnectorFn ? true : false + >().toEqualTypeOf() + expectTypeOf< + typeof connector extends Connector ? true : false + >().toEqualTypeOf() + + type ConnectFnParameters = NonNullable< + Parameters<(typeof connector)['connect']>[0] + > + expectTypeOf().toMatchTypeOf() +}) + +test('behavior: features.connectError', () => { + const connectorFn = mock({ accounts, features: { connectError: true } }) + const connector = config._internal.connectors.setup(connectorFn) + expect(() => connector.connect()).rejects.toThrowErrorMatchingInlineSnapshot(` + [UserRejectedRequestError: User rejected the request. + + Details: Failed to connect. + Version: viem@2.29.2] + `) +}) + +test('behavior: connector.getProvider request errors', async () => { + const connectorFn = mock({ + accounts, + features: { + signMessageError: true, + signTypedDataError: true, + switchChainError: true, + watchAssetError: true, + }, + }) + const connector = config._internal.connectors.setup( + connectorFn, + ) as ReturnType + const provider = await connector.getProvider() + + expect( + provider.request({ + method: 'eth_signTypedData_v4', + params: [] as any, + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [UserRejectedRequestError: User rejected the request. + + Details: Failed to sign typed data. + Version: viem@2.29.2] + `) + + expect( + provider.request({ + method: 'wallet_switchEthereumChain', + params: [] as any, + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [UserRejectedRequestError: User rejected the request. + + Details: Failed to switch chain. + Version: viem@2.29.2] + `) + + expect( + provider.request({ + method: 'wallet_watchAsset', + params: [] as any, + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [UserRejectedRequestError: User rejected the request. + + Details: Failed to switch chain. + Version: viem@2.29.2] + `) + + expect( + provider.request({ + method: 'personal_sign', + params: [] as any, + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [UserRejectedRequestError: User rejected the request. + + Details: Failed to sign message. + Version: viem@2.29.2] + `) +}) + +test('behavior: reconnect', async () => { + const connectorFn = mock({ + accounts, + features: { + defaultConnected: true, + reconnect: true, + }, + }) + const connector = config._internal.connectors.setup(connectorFn) + + await expect(connector.isAuthorized()).resolves.toBeTruthy() +}) diff --git a/packages/core/src/connectors/mock.ts b/packages/core/src/connectors/mock.ts new file mode 100644 index 0000000000..9d4dc9d846 --- /dev/null +++ b/packages/core/src/connectors/mock.ts @@ -0,0 +1,315 @@ +import { + type Address, + type EIP1193RequestFn, + type Hex, + RpcRequestError, + SwitchChainError, + type Transport, + UserRejectedRequestError, + type WalletCallReceipt, + type WalletGetCallsStatusReturnType, + type WalletRpcSchema, + custom, + fromHex, + getAddress, + keccak256, + numberToHex, + stringToHex, +} from 'viem' +import { rpc } from 'viem/utils' + +import { + ChainNotConfiguredError, + ConnectorNotConnectedError, +} from '../errors/config.js' +import { createConnector } from './createConnector.js' + +export type MockParameters = { + accounts: readonly [Address, ...Address[]] + features?: + | { + defaultConnected?: boolean | undefined + connectError?: boolean | Error | undefined + switchChainError?: boolean | Error | undefined + signMessageError?: boolean | Error | undefined + signTypedDataError?: boolean | Error | undefined + reconnect?: boolean | undefined + watchAssetError?: boolean | Error | undefined + } + | undefined +} + +mock.type = 'mock' as const +export function mock(parameters: MockParameters) { + const transactionCache = new Map() + const features = + parameters.features ?? + ({ defaultConnected: false } satisfies MockParameters['features']) + + type Provider = ReturnType< + Transport<'custom', unknown, EIP1193RequestFn> + > + type Properties = { + connect(parameters?: { + chainId?: number | undefined + isReconnecting?: boolean | undefined + foo?: string | undefined + }): Promise<{ + accounts: readonly Address[] + chainId: number + }> + } + let connected = features.defaultConnected + let connectedChainId: number + + return createConnector((config) => ({ + id: 'mock', + name: 'Mock Connector', + type: mock.type, + async setup() { + connectedChainId = config.chains[0].id + }, + async connect({ chainId } = {}) { + if (features.connectError) { + if (typeof features.connectError === 'boolean') + throw new UserRejectedRequestError(new Error('Failed to connect.')) + throw features.connectError + } + + const provider = await this.getProvider() + const accounts = await provider.request({ + method: 'eth_requestAccounts', + }) + + let currentChainId = await this.getChainId() + if (chainId && currentChainId !== chainId) { + const chain = await this.switchChain!({ chainId }) + currentChainId = chain.id + } + + connected = true + + return { + accounts: accounts.map((x) => getAddress(x)), + chainId: currentChainId, + } + }, + async disconnect() { + connected = false + }, + async getAccounts() { + if (!connected) throw new ConnectorNotConnectedError() + const provider = await this.getProvider() + const accounts = await provider.request({ method: 'eth_accounts' }) + return accounts.map((x) => getAddress(x)) + }, + async getChainId() { + const provider = await this.getProvider() + const hexChainId = await provider.request({ method: 'eth_chainId' }) + return fromHex(hexChainId, 'number') + }, + async isAuthorized() { + if (!features.reconnect) return false + if (!connected) return false + const accounts = await this.getAccounts() + return !!accounts.length + }, + async switchChain({ chainId }) { + const provider = await this.getProvider() + const chain = config.chains.find((x) => x.id === chainId) + if (!chain) throw new SwitchChainError(new ChainNotConfiguredError()) + + await provider.request({ + method: 'wallet_switchEthereumChain', + params: [{ chainId: numberToHex(chainId) }], + }) + return chain + }, + onAccountsChanged(accounts) { + if (accounts.length === 0) this.onDisconnect() + else + config.emitter.emit('change', { + accounts: accounts.map((x) => getAddress(x)), + }) + }, + onChainChanged(chain) { + const chainId = Number(chain) + config.emitter.emit('change', { chainId }) + }, + async onDisconnect(_error) { + config.emitter.emit('disconnect') + connected = false + }, + async getProvider({ chainId } = {}) { + const chain = + config.chains.find((x) => x.id === chainId) ?? config.chains[0] + const url = chain.rpcUrls.default.http[0]! + + const request: EIP1193RequestFn = async ({ method, params }) => { + // eth methods + if (method === 'eth_chainId') return numberToHex(connectedChainId) + if (method === 'eth_requestAccounts') return parameters.accounts + if (method === 'eth_signTypedData_v4') + if (features.signTypedDataError) { + if (typeof features.signTypedDataError === 'boolean') + throw new UserRejectedRequestError( + new Error('Failed to sign typed data.'), + ) + throw features.signTypedDataError + } + + // wallet methods + if (method === 'wallet_switchEthereumChain') { + if (features.switchChainError) { + if (typeof features.switchChainError === 'boolean') + throw new UserRejectedRequestError( + new Error('Failed to switch chain.'), + ) + throw features.switchChainError + } + type Params = [{ chainId: Hex }] + connectedChainId = fromHex((params as Params)[0].chainId, 'number') + this.onChainChanged(connectedChainId.toString()) + return + } + + if (method === 'wallet_watchAsset') { + if (features.watchAssetError) { + if (typeof features.watchAssetError === 'boolean') + throw new UserRejectedRequestError( + new Error('Failed to switch chain.'), + ) + throw features.watchAssetError + } + return connected + } + + if (method === 'wallet_getCapabilities') + return { + '0x2105': { + paymasterService: { + supported: + (params as [Hex])[0] === + '0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266', + }, + sessionKeys: { + supported: true, + }, + }, + '0x14A34': { + paymasterService: { + supported: + (params as [Hex])[0] === + '0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266', + }, + }, + } + + if (method === 'wallet_sendCalls') { + const hashes = [] + const calls = (params as any)[0].calls + for (const call of calls) { + const { result, error } = await rpc.http(url, { + body: { + method: 'eth_sendTransaction', + params: [call], + }, + }) + if (error) + throw new RpcRequestError({ + body: { method, params }, + error, + url, + }) + hashes.push(result) + } + const id = keccak256(stringToHex(JSON.stringify(calls))) + transactionCache.set(id, hashes) + return { id } + } + + if (method === 'wallet_getCallsStatus') { + const hashes = transactionCache.get((params as any)[0]) + if (!hashes) + return { + atomic: false, + chainId: '0x1', + id: (params as any)[0], + status: 100, + receipts: [], + version: '2.0.0', + } satisfies WalletGetCallsStatusReturnType + + const receipts = await Promise.all( + hashes.map(async (hash) => { + const { result, error } = await rpc.http(url, { + body: { + method: 'eth_getTransactionReceipt', + params: [hash], + id: 0, + }, + }) + if (error) + throw new RpcRequestError({ + body: { method, params }, + error, + url, + }) + if (!result) return null + return { + blockHash: result.blockHash, + blockNumber: result.blockNumber, + gasUsed: result.gasUsed, + logs: result.logs, + status: result.status, + transactionHash: result.transactionHash, + } satisfies WalletCallReceipt + }), + ) + const receipts_ = receipts.filter((x) => x !== null) + if (receipts_.length === 0) + return { + atomic: false, + chainId: '0x1', + id: (params as any)[0], + status: 100, + receipts: [], + version: '2.0.0', + } satisfies WalletGetCallsStatusReturnType + return { + atomic: false, + chainId: '0x1', + id: (params as any)[0], + status: 200, + receipts: receipts_, + version: '2.0.0', + } satisfies WalletGetCallsStatusReturnType + } + + if (method === 'wallet_showCallsStatus') return + + // other methods + if (method === 'personal_sign') { + if (features.signMessageError) { + if (typeof features.signMessageError === 'boolean') + throw new UserRejectedRequestError( + new Error('Failed to sign message.'), + ) + throw features.signMessageError + } + // Change `personal_sign` to `eth_sign` and swap params + method = 'eth_sign' + type Params = [data: Hex, address: Address] + params = [(params as Params)[1], (params as Params)[0]] + } + + const body = { method, params } + const { error, result } = await rpc.http(url, { body }) + if (error) throw new RpcRequestError({ body, error, url }) + + return result + } + return custom({ request })({ retryCount: 0 }) + }, + })) +} diff --git a/packages/core/src/createConfig.test-d.ts b/packages/core/src/createConfig.test-d.ts new file mode 100644 index 0000000000..3daa57bd5f --- /dev/null +++ b/packages/core/src/createConfig.test-d.ts @@ -0,0 +1,110 @@ +import { accounts } from '@wagmi/test' +import { http, createClient, webSocket } from 'viem' +import { mainnet, sepolia } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { mock } from './connectors/mock.js' +import { type CreateConfigParameters, createConfig } from './createConfig.js' + +test('high-level config', () => { + // Create config without needing to import viem modules. + const config = createConfig({ + cacheTime: 100, + chains: [mainnet, sepolia], + connectors: [mock({ accounts })], + batch: { multicall: true }, + pollingInterval: { [mainnet.id]: 100 }, + transports: { + [mainnet.id]: webSocket(), + [sepolia.id]: http(), + }, + }) + const client = config.getClient({ chainId: mainnet.id }) + expectTypeOf(client.chain).toEqualTypeOf(mainnet) + expectTypeOf(client.transport.type).toEqualTypeOf<'webSocket'>() +}) + +test('low-level config', () => { + // Create a "multi chain" config using viem modules. + const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [mock({ accounts })], + client({ chain }) { + return createClient({ chain, transport: http() }) + }, + }) + const client = config.getClient({ chainId: mainnet.id }) + expectTypeOf(client.chain).toEqualTypeOf(mainnet) +}) + +test('behavior: `chains` must have at least one chain', () => { + createConfig({ + // @ts-expect-error + chains: [], + connectors: [mock({ accounts })], + transports: { + [mainnet.id]: http(), + }, + }) + createConfig({ + // @ts-expect-error + chains: [], + connectors: [mock({ accounts })], + client: ({ chain }) => + createClient({ + chain, + transport: http(), + }), + }) +}) + +test('behavior: missing transport for chain', () => { + createConfig({ + chains: [mainnet, sepolia], + connectors: [mock({ accounts })], + // @ts-expect-error + transports: { + [mainnet.id]: http(), + }, + }) + createConfig({ + chains: [mainnet, sepolia], + connectors: [mock({ accounts })], + transports: { + [mainnet.id]: http(), + // @ts-expect-error + [123]: http(), + }, + }) +}) + +test('behavior: parameters should not include certain client config properties', () => { + type Result = keyof CreateConfigParameters + expectTypeOf<'account' extends Result ? true : false>().toEqualTypeOf() + expectTypeOf<'chain' extends Result ? true : false>().toEqualTypeOf() + expectTypeOf< + 'transport' extends Result ? true : false + >().toEqualTypeOf() +}) + +test('infer connectors', () => { + const connectorFn = mock({ accounts }) + const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [connectorFn], + transports: { + [mainnet.id]: webSocket(), + [sepolia.id]: http(), + }, + }) + + const connector = config.connectors[0]! + expectTypeOf(connector).toEqualTypeOf( + config._internal.connectors.setup(connectorFn), + ) + + type ConnectFnParameters = NonNullable< + Parameters<(typeof connector)['connect']>[0] + > + expectTypeOf().toMatchTypeOf() +}) diff --git a/packages/core/src/createConfig.test.ts b/packages/core/src/createConfig.test.ts new file mode 100644 index 0000000000..a6ae41e280 --- /dev/null +++ b/packages/core/src/createConfig.test.ts @@ -0,0 +1,440 @@ +import { accounts, chain, wait } from '@wagmi/test' +import { + type EIP1193Provider, + type EIP6963ProviderDetail, + announceProvider, +} from 'mipd' +import { http } from 'viem' +import { expect, test, vi } from 'vitest' + +import { connect } from './actions/connect.js' +import { disconnect } from './actions/disconnect.js' +import { switchChain } from './actions/switchChain.js' +import { createConnector } from './connectors/createConnector.js' +import { mock } from './connectors/mock.js' +import { createConfig } from './createConfig.js' +import { createStorage } from './createStorage.js' + +const { mainnet, optimism } = chain + +vi.mock(import('mipd'), async (importOriginal) => { + const mod = await importOriginal() + + let cache: typeof mod | undefined + if (!cache) + cache = { + ...mod, + createStore() { + const store = mod.createStore() + return { + ...store, + getProviders() { + return [ + getProviderDetail({ name: 'Example', rdns: 'com.example' }), + getProviderDetail({ name: 'Mock', rdns: 'com.mock' }), + ] + }, + } + }, + } + return cache +}) + +test('default', () => { + const config = createConfig({ + chains: [mainnet], + connectors: [mock({ accounts })], + transports: { + [mainnet.id]: http(), + }, + }) + expect(config).toBeDefined() +}) + +test('getClient', () => { + const config = createConfig({ + chains: [mainnet, optimism], + connectors: [mock({ accounts })], + syncConnectedChain: true, + transports: { + [mainnet.id]: http(), + [optimism.id]: http(), + }, + }) + + { + const client = config.getClient() + expect(client.chain.id).toBe(mainnet.id) + } + + { + const client = config.getClient({ chainId: mainnet.id }) + expect(client.chain.id).toBe(mainnet.id) + } + + expect(() => + config.getClient({ + // @ts-expect-error + chainId: 123456, + }), + ).toThrowErrorMatchingInlineSnapshot(` + [ChainNotConfiguredError: Chain not configured. + + Version: @wagmi/core@x.y.z] + `) + + expect(() => { + // @ts-expect-error + config.state.chainId = 123456 + config.getClient() + }).toThrowErrorMatchingInlineSnapshot(` + [ChainNotConfiguredError: Chain not configured. + + Version: @wagmi/core@x.y.z] + `) +}) + +test('behavior: syncConnectedChain', async () => { + const config = createConfig({ + chains: [mainnet, optimism], + connectors: [mock({ accounts })], + syncConnectedChain: true, + transports: { + [mainnet.id]: http(), + [optimism.id]: http(), + }, + }) + // defaults to first chain in `createConfig({ chains })` + expect(config.getClient().chain.id).toBe(mainnet.id) + + // switches to optimism + await switchChain(config, { chainId: optimism.id }) + expect(config.getClient().chain.id).toBe(optimism.id) + + // connects to mainnet + await connect(config, { + chainId: mainnet.id, + connector: config.connectors[0]!, + }) + expect(config.getClient().chain.id).toBe(mainnet.id) + + // switches to optimism + await switchChain(config, { chainId: optimism.id }) + expect(config.getClient().chain.id).toBe(optimism.id) + + // disconnects, still connected to optimism + await disconnect(config) + expect(config.getClient().chain.id).toBe(optimism.id) +}) + +test('behavior: migrate for current version', async () => { + const state = { + 'wagmi.store': JSON.stringify({ + state: { + connections: { + __type: 'Map', + value: [ + [ + '983b8aca245', + { + accounts: [ + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + ], + chainId: 1, + connector: { + id: 'io.metamask', + name: 'MetaMask', + type: 'injected', + uid: '983b8aca245', + }, + }, + ], + ], + }, + chainId: 1, + current: '983b8aca245', + }, + version: Number.NaN, // mocked version is `'x.y.z'`, which will get interpreted as `NaN` + }), + } as Record + Object.defineProperty(window, 'localStorage', { + value: { + getItem: vi.fn((key) => state[key] ?? null), + removeItem: vi.fn((key) => state.delete?.[key]), + setItem: vi.fn((key, value) => { + state[key] = value + }), + }, + writable: true, + }) + + const storage = createStorage<{ store: object }>({ + storage: window.localStorage, + }) + + const config = createConfig({ + chains: [mainnet], + storage, + transports: { [mainnet.id]: http() }, + }) + + await wait(100) + + expect(config.state).toMatchInlineSnapshot(` + { + "chainId": 1, + "connections": Map { + "983b8aca245" => { + "accounts": [ + "0xA0Cf798816D4b9b9866b5330EEa46a18382f251e", + "0xd2135CfB216b74109775236E36d4b433F1DF507B", + ], + "chainId": 1, + "connector": { + "id": "io.metamask", + "name": "MetaMask", + "type": "injected", + "uid": "983b8aca245", + }, + }, + }, + "current": "983b8aca245", + "status": "disconnected", + } + `) +}) + +test('behavior: migrate chainId', async () => { + const state = { + 'wagmi.store': JSON.stringify({ + state: { chainId: 10 }, + version: 1, + }), + } as Record + Object.defineProperty(window, 'localStorage', { + value: { + getItem: vi.fn((key) => state[key] ?? null), + removeItem: vi.fn((key) => state.delete?.[key]), + setItem: vi.fn((key, value) => { + state[key] = value + }), + }, + writable: true, + }) + + const storage = createStorage<{ store: object }>({ + storage: window.localStorage, + }) + + const config = createConfig({ + chains: [mainnet, optimism], + storage, + transports: { + [mainnet.id]: http(), + [optimism.id]: http(), + }, + }) + + await wait(100) + + expect(config.state).toMatchInlineSnapshot(` + { + "chainId": 10, + "connections": Map {}, + "current": null, + "status": "disconnected", + } + `) +}) + +test('behavior: properties passed through to Viem Client via getClient', () => { + { + const properties = { + batch: { + multicall: { + batchSize: 102_400, + }, + }, + cacheTime: 5_000, + pollingInterval: 1_000, + } + + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: http(), + }, + ...properties, + }) + + const { + account: _a, + chain: _c, + extend: _e, + key: _k, + name: _n, + request: _r, + transport: _tr, + uid: _u, + type: _ty, + ...rest + } = config.getClient() + expect(rest).toEqual(properties) + } + + { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: http(), + }, + batch: { + [mainnet.id]: { + multicall: { + batchSize: 1024, + }, + }, + }, + }) + + const client = config.getClient() + expect(client.batch).toMatchInlineSnapshot(` + { + "multicall": { + "batchSize": 1024, + }, + } + `) + + const client2 = config.getClient({ chainId: optimism.id }) + expect(client2.batch).toMatchInlineSnapshot(` + { + "multicall": true, + } + `) + } +}) + +test('behavior: restore unconfigured chainId', () => { + const state = { + 'wagmi.store': JSON.stringify({ + state: { chainId: 10 }, + version: 1, + }), + } as Record + Object.defineProperty(window, 'localStorage', { + value: { + getItem: vi.fn((key) => state[key] ?? null), + removeItem: vi.fn((key) => state.delete?.[key]), + setItem: vi.fn((key, value) => { + state[key] = value + }), + }, + writable: true, + }) + + const storage = createStorage<{ store: object }>({ + storage: window.localStorage, + }) + + const config = createConfig({ + chains: [mainnet], + storage, + transports: { + [mainnet.id]: http(), + }, + }) + + expect(config.state).toMatchInlineSnapshot(` + { + "chainId": 1, + "connections": Map {}, + "current": null, + "status": "disconnected", + } + `) + + const client = config.getClient() + expect(client.chain.id).toBe(mainnet.id) +}) + +test('behavior: setup connector', async () => { + const config = createConfig({ + chains: [mainnet], + transports: { + [mainnet.id]: http(), + }, + }) + + const connectorFn = mock({ accounts }) + const connector = config._internal.connectors.setup(connectorFn) + config._internal.connectors.setState((x) => [...x, connector]) + + await connect(config, { + chainId: mainnet.id, + connector: config.connectors.find((x) => x.uid === connector.uid)!, + }) + + expect(config.state.current).toBe(connector.uid) + + await disconnect(config) +}) + +test('behavior: eip 6963 providers', async () => { + const detail_1 = getProviderDetail({ name: 'Foo Wallet', rdns: 'com.foo' }) + const detail_2 = getProviderDetail({ name: 'Bar Wallet', rdns: 'com.bar' }) + const detail_3 = getProviderDetail({ name: 'Mock', rdns: 'com.mock' }) + + const config = createConfig({ + chains: [mainnet], + connectors: [ + createConnector((c) => { + return { + ...mock({ accounts })(c), + rdns: ['com.mock', 'com.baz'], + } + }), + ], + transports: { + [mainnet.id]: http(), + }, + }) + + await wait(100) + announceProvider(detail_1)() + await wait(100) + announceProvider(detail_1)() + await wait(100) + announceProvider(detail_2)() + await wait(100) + announceProvider(detail_3)() + await wait(100) + + expect( + config.connectors.flatMap((x) => x.rdns ?? x.id), + ).toMatchInlineSnapshot(` + [ + "com.mock", + "com.baz", + "com.example", + "com.foo", + "com.bar", + ] + `) +}) + +function getProviderDetail( + info: Pick, +): EIP6963ProviderDetail { + return { + info: { + icon: 'data:image/svg+xml,', + uuid: crypto.randomUUID(), + ...info, + }, + provider: `` as unknown as EIP1193Provider, + } +} diff --git a/packages/core/src/createConfig.ts b/packages/core/src/createConfig.ts new file mode 100644 index 0000000000..154eef5f6d --- /dev/null +++ b/packages/core/src/createConfig.ts @@ -0,0 +1,653 @@ +import { + type EIP6963ProviderDetail, + type Store as MipdStore, + createStore as createMipd, +} from 'mipd' +import { + type Address, + type Chain, + type Client, + type EIP1193RequestFn, + createClient, + type ClientConfig as viem_ClientConfig, + type Transport as viem_Transport, +} from 'viem' +import { persist, subscribeWithSelector } from 'zustand/middleware' +import { type Mutate, type StoreApi, createStore } from 'zustand/vanilla' + +import type { + ConnectorEventMap, + CreateConnectorFn, +} from './connectors/createConnector.js' +import { injected } from './connectors/injected.js' +import { type Emitter, type EventData, createEmitter } from './createEmitter.js' +import { + type Storage, + createStorage, + getDefaultStorage, +} from './createStorage.js' +import { ChainNotConfiguredError } from './errors/config.js' +import type { + Compute, + ExactPartial, + LooseOmit, + OneOf, + RemoveUndefined, +} from './types/utils.js' +import { uid } from './utils/uid.js' +import { version } from './version.js' + +export function createConfig< + const chains extends readonly [Chain, ...Chain[]], + transports extends Record, + const connectorFns extends readonly CreateConnectorFn[], +>( + parameters: CreateConfigParameters, +): Config { + const { + multiInjectedProviderDiscovery = true, + storage = createStorage({ + storage: getDefaultStorage(), + }), + syncConnectedChain = true, + ssr = false, + ...rest + } = parameters + + ///////////////////////////////////////////////////////////////////////////////////////////////// + // Set up connectors, clients, etc. + ///////////////////////////////////////////////////////////////////////////////////////////////// + + const mipd = + typeof window !== 'undefined' && multiInjectedProviderDiscovery + ? createMipd() + : undefined + + const chains = createStore(() => rest.chains) + const connectors = createStore(() => { + const collection = [] + const rdnsSet = new Set() + for (const connectorFns of rest.connectors ?? []) { + const connector = setup(connectorFns) + collection.push(connector) + if (!ssr && connector.rdns) { + const rdnsValues = + typeof connector.rdns === 'string' ? [connector.rdns] : connector.rdns + for (const rdns of rdnsValues) { + rdnsSet.add(rdns) + } + } + } + if (!ssr && mipd) { + const providers = mipd.getProviders() + for (const provider of providers) { + if (rdnsSet.has(provider.info.rdns)) continue + collection.push(setup(providerDetailToConnector(provider))) + } + } + return collection + }) + function setup(connectorFn: CreateConnectorFn): Connector { + // Set up emitter with uid and add to connector so they are "linked" together. + const emitter = createEmitter(uid()) + const connector = { + ...connectorFn({ + emitter, + chains: chains.getState(), + storage, + transports: rest.transports, + }), + emitter, + uid: emitter.uid, + } + + // Start listening for `connect` events on connector setup + // This allows connectors to "connect" themselves without user interaction (e.g. MetaMask's "Manually connect to current site") + emitter.on('connect', connect) + connector.setup?.() + + return connector + } + function providerDetailToConnector(providerDetail: EIP6963ProviderDetail) { + const { info } = providerDetail + const provider = providerDetail.provider as any + return injected({ target: { ...info, id: info.rdns, provider } }) + } + + const clients = new Map>() + function getClient( + config: { chainId?: chainId | chains[number]['id'] | undefined } = {}, + ): Client> { + const chainId = config.chainId ?? store.getState().chainId + const chain = chains.getState().find((x) => x.id === chainId) + + // chainId specified and not configured + if (config.chainId && !chain) throw new ChainNotConfiguredError() + + // If the target chain is not configured, use the client of the current chain. + type Return = Client> + { + const client = clients.get(store.getState().chainId) + if (client && !chain) return client as Return + if (!chain) throw new ChainNotConfiguredError() + } + + // If a memoized client exists for a chain id, use that. + { + const client = clients.get(chainId) + if (client) return client as Return + } + + let client: Client + if (rest.client) client = rest.client({ chain }) + else { + const chainId = chain.id as chains[number]['id'] + const chainIds = chains.getState().map((x) => x.id) + // Grab all properties off `rest` and resolve for use in `createClient` + const properties: Partial = {} + const entries = Object.entries(rest) as [keyof typeof rest, any][] + + for (const [key, value] of entries) { + if ( + key === 'chains' || + key === 'client' || + key === 'connectors' || + key === 'transports' + ) + continue + + if (typeof value === 'object') { + // check if value is chainId-specific since some values can be objects + // e.g. { batch: { multicall: { batchSize: 1024 } } } + if (chainId in value) properties[key] = value[chainId] + else { + // check if value is chainId-specific, but does not have value for current chainId + const hasChainSpecificValue = chainIds.some((x) => x in value) + if (hasChainSpecificValue) continue + properties[key] = value + } + } else properties[key] = value + } + + client = createClient({ + ...properties, + chain, + batch: properties.batch ?? { multicall: true }, + transport: (parameters) => + rest.transports[chainId]({ ...parameters, connectors }), + }) + } + + clients.set(chainId, client) + return client as Return + } + + ///////////////////////////////////////////////////////////////////////////////////////////////// + // Create store + ///////////////////////////////////////////////////////////////////////////////////////////////// + + function getInitialState(): State { + return { + chainId: chains.getState()[0].id, + connections: new Map(), + current: null, + status: 'disconnected', + } + } + + let currentVersion: number + const prefix = '0.0.0-canary-' + if (version.startsWith(prefix)) + currentVersion = Number.parseInt(version.replace(prefix, '')) + // use package major version to version store + else currentVersion = Number.parseInt(version.split('.')[0] ?? '0') + + const store = createStore( + subscribeWithSelector( + // only use persist middleware if storage exists + storage + ? persist(getInitialState, { + migrate(persistedState, version) { + if (version === currentVersion) return persistedState as State + + const initialState = getInitialState() + const chainId = validatePersistedChainId( + persistedState, + initialState.chainId, + ) + return { ...initialState, chainId } + }, + name: 'store', + partialize(state) { + // Only persist "critical" store properties to preserve storage size. + return { + connections: { + __type: 'Map', + value: Array.from(state.connections.entries()).map( + ([key, connection]) => { + const { id, name, type, uid } = connection.connector + const connector = { id, name, type, uid } + return [key, { ...connection, connector }] + }, + ), + } as unknown as PartializedState['connections'], + chainId: state.chainId, + current: state.current, + } satisfies PartializedState + }, + merge(persistedState, currentState) { + // `status` should not be persisted as it messes with reconnection + if ( + typeof persistedState === 'object' && + persistedState && + 'status' in persistedState + ) + delete persistedState.status + // Make sure persisted `chainId` is valid + const chainId = validatePersistedChainId( + persistedState, + currentState.chainId, + ) + return { + ...currentState, + ...(persistedState as object), + chainId, + } + }, + skipHydration: ssr, + storage: storage as Storage>, + version: currentVersion, + }) + : getInitialState, + ), + ) + store.setState(getInitialState()) + + function validatePersistedChainId( + persistedState: unknown, + defaultChainId: number, + ) { + return persistedState && + typeof persistedState === 'object' && + 'chainId' in persistedState && + typeof persistedState.chainId === 'number' && + chains.getState().some((x) => x.id === persistedState.chainId) + ? persistedState.chainId + : defaultChainId + } + + ///////////////////////////////////////////////////////////////////////////////////////////////// + // Subscribe to changes + ///////////////////////////////////////////////////////////////////////////////////////////////// + + // Update default chain when connector chain changes + if (syncConnectedChain) + store.subscribe( + ({ connections, current }) => + current ? connections.get(current)?.chainId : undefined, + (chainId) => { + // If chain is not configured, then don't switch over to it. + const isChainConfigured = chains + .getState() + .some((x) => x.id === chainId) + if (!isChainConfigured) return + + return store.setState((x) => ({ + ...x, + chainId: chainId ?? x.chainId, + })) + }, + ) + + // EIP-6963 subscribe for new wallet providers + mipd?.subscribe((providerDetails) => { + const connectorIdSet = new Set() + const connectorRdnsSet = new Set() + for (const connector of connectors.getState()) { + connectorIdSet.add(connector.id) + if (connector.rdns) { + const rdnsValues = + typeof connector.rdns === 'string' ? [connector.rdns] : connector.rdns + for (const rdns of rdnsValues) { + connectorRdnsSet.add(rdns) + } + } + } + + const newConnectors: Connector[] = [] + for (const providerDetail of providerDetails) { + if (connectorRdnsSet.has(providerDetail.info.rdns)) continue + const connector = setup(providerDetailToConnector(providerDetail)) + if (connectorIdSet.has(connector.id)) continue + newConnectors.push(connector) + } + + if (storage && !store.persist.hasHydrated()) return + connectors.setState((x) => [...x, ...newConnectors], true) + }) + + ///////////////////////////////////////////////////////////////////////////////////////////////// + // Emitter listeners + ///////////////////////////////////////////////////////////////////////////////////////////////// + + function change(data: EventData) { + store.setState((x) => { + const connection = x.connections.get(data.uid) + if (!connection) return x + return { + ...x, + connections: new Map(x.connections).set(data.uid, { + accounts: + (data.accounts as readonly [Address, ...Address[]]) ?? + connection.accounts, + chainId: data.chainId ?? connection.chainId, + connector: connection.connector, + }), + } + }) + } + function connect(data: EventData) { + // Disable handling if reconnecting/connecting + if ( + store.getState().status === 'connecting' || + store.getState().status === 'reconnecting' + ) + return + + store.setState((x) => { + const connector = connectors.getState().find((x) => x.uid === data.uid) + if (!connector) return x + + if (connector.emitter.listenerCount('connect')) + connector.emitter.off('connect', change) + if (!connector.emitter.listenerCount('change')) + connector.emitter.on('change', change) + if (!connector.emitter.listenerCount('disconnect')) + connector.emitter.on('disconnect', disconnect) + + return { + ...x, + connections: new Map(x.connections).set(data.uid, { + accounts: data.accounts as readonly [Address, ...Address[]], + chainId: data.chainId, + connector: connector, + }), + current: data.uid, + status: 'connected', + } + }) + } + function disconnect(data: EventData) { + store.setState((x) => { + const connection = x.connections.get(data.uid) + if (connection) { + const connector = connection.connector + if (connector.emitter.listenerCount('change')) + connection.connector.emitter.off('change', change) + if (connector.emitter.listenerCount('disconnect')) + connection.connector.emitter.off('disconnect', disconnect) + if (!connector.emitter.listenerCount('connect')) + connection.connector.emitter.on('connect', connect) + } + + x.connections.delete(data.uid) + + if (x.connections.size === 0) + return { + ...x, + connections: new Map(), + current: null, + status: 'disconnected', + } + + const nextConnection = x.connections.values().next().value as Connection + return { + ...x, + connections: new Map(x.connections), + current: nextConnection.connector.uid, + } + }) + } + + return { + get chains() { + return chains.getState() as chains + }, + get connectors() { + return connectors.getState() as Connector[] + }, + storage, + + getClient, + get state() { + return store.getState() as unknown as State + }, + setState(value) { + let newState: State + if (typeof value === 'function') newState = value(store.getState() as any) + else newState = value + + // Reset state if it got set to something not matching the base state + const initialState = getInitialState() + if (typeof newState !== 'object') newState = initialState + const isCorrupt = Object.keys(initialState).some((x) => !(x in newState)) + if (isCorrupt) newState = initialState + + store.setState(newState, true) + }, + subscribe(selector, listener, options) { + return store.subscribe( + selector as unknown as (state: State) => any, + listener, + options + ? ({ + ...options, + fireImmediately: options.emitImmediately, + // Workaround cast since Zustand does not support `'exactOptionalPropertyTypes'` + } as RemoveUndefined) + : undefined, + ) + }, + + _internal: { + mipd, + store, + ssr: Boolean(ssr), + syncConnectedChain, + transports: rest.transports as transports, + chains: { + setState(value) { + const nextChains = ( + typeof value === 'function' ? value(chains.getState()) : value + ) as chains + if (nextChains.length === 0) return + return chains.setState(nextChains, true) + }, + subscribe(listener) { + return chains.subscribe(listener) + }, + }, + connectors: { + providerDetailToConnector, + setup: setup as ( + connectorFn: connectorFn, + ) => Connector, + setState(value) { + return connectors.setState( + typeof value === 'function' ? value(connectors.getState()) : value, + true, + ) + }, + subscribe(listener) { + return connectors.subscribe(listener) + }, + }, + events: { change, connect, disconnect }, + }, + } +} + +///////////////////////////////////////////////////////////////////////////////////////////////// +// Types +///////////////////////////////////////////////////////////////////////////////////////////////// + +export type CreateConfigParameters< + chains extends readonly [Chain, ...Chain[]] = readonly [Chain, ...Chain[]], + transports extends Record = Record< + chains[number]['id'], + Transport + >, + connectorFns extends + readonly CreateConnectorFn[] = readonly CreateConnectorFn[], +> = Compute< + { + chains: chains + connectors?: connectorFns | undefined + multiInjectedProviderDiscovery?: boolean | undefined + storage?: Storage | null | undefined + ssr?: boolean | undefined + syncConnectedChain?: boolean | undefined + } & OneOf< + | ({ transports: transports } & { + [key in keyof ClientConfig]?: + | ClientConfig[key] + | { [_ in chains[number]['id']]?: ClientConfig[key] | undefined } + | undefined + }) + | { + client(parameters: { chain: chains[number] }): Client< + transports[chains[number]['id']], + chains[number] + > + } + > +> + +export type Config< + chains extends readonly [Chain, ...Chain[]] = readonly [Chain, ...Chain[]], + transports extends Record = Record< + chains[number]['id'], + Transport + >, + connectorFns extends + readonly CreateConnectorFn[] = readonly CreateConnectorFn[], +> = { + readonly chains: chains + readonly connectors: readonly Connector[] + readonly storage: Storage | null + + readonly state: State + setState( + value: State | ((state: State) => State), + ): void + subscribe( + selector: (state: State) => state, + listener: (state: state, previousState: state) => void, + options?: + | { + emitImmediately?: boolean | undefined + equalityFn?: ((a: state, b: state) => boolean) | undefined + } + | undefined, + ): () => void + + getClient(parameters?: { + chainId?: chainId | chains[number]['id'] | undefined + }): Client> + + /** + * Not part of versioned API, proceed with caution. + * @internal + */ + _internal: Internal +} + +type Internal< + chains extends readonly [Chain, ...Chain[]] = readonly [Chain, ...Chain[]], + transports extends Record = Record< + chains[number]['id'], + Transport + >, +> = { + readonly mipd: MipdStore | undefined + readonly store: Mutate, [['zustand/persist', any]]> + readonly ssr: boolean + readonly syncConnectedChain: boolean + readonly transports: transports + + chains: { + setState( + value: + | readonly [Chain, ...Chain[]] + | (( + state: readonly [Chain, ...Chain[]], + ) => readonly [Chain, ...Chain[]]), + ): void + subscribe( + listener: ( + state: readonly [Chain, ...Chain[]], + prevState: readonly [Chain, ...Chain[]], + ) => void, + ): () => void + } + connectors: { + providerDetailToConnector( + providerDetail: EIP6963ProviderDetail, + ): CreateConnectorFn + setup( + connectorFn: connectorFn, + ): Connector + setState(value: Connector[] | ((state: Connector[]) => Connector[])): void + subscribe( + listener: (state: Connector[], prevState: Connector[]) => void, + ): () => void + } + events: { + change(data: EventData): void + connect(data: EventData): void + disconnect(data: EventData): void + } +} + +export type State< + chains extends readonly [Chain, ...Chain[]] = readonly [Chain, ...Chain[]], +> = { + chainId: chains[number]['id'] + connections: Map + current: string | null + status: 'connected' | 'connecting' | 'disconnected' | 'reconnecting' +} + +export type PartializedState = Compute< + ExactPartial> +> + +export type Connection = { + accounts: readonly [Address, ...Address[]] + chainId: number + connector: Connector +} + +export type Connector< + createConnectorFn extends CreateConnectorFn = CreateConnectorFn, +> = ReturnType & { + emitter: Emitter + uid: string +} + +export type Transport< + type extends string = string, + rpcAttributes = Record, + eip1193RequestFn extends EIP1193RequestFn = EIP1193RequestFn, +> = ( + params: Parameters< + viem_Transport + >[0] & { + connectors?: StoreApi | undefined + }, +) => ReturnType> + +type ClientConfig = LooseOmit< + viem_ClientConfig, + 'account' | 'chain' | 'key' | 'name' | 'transport' | 'type' +> diff --git a/packages/core/src/createEmitter.test.ts b/packages/core/src/createEmitter.test.ts new file mode 100644 index 0000000000..5eb453bb51 --- /dev/null +++ b/packages/core/src/createEmitter.test.ts @@ -0,0 +1,19 @@ +import { expect, test, vi } from 'vitest' + +import type { ConnectorEventMap } from './connectors/createConnector.js' +import { createEmitter } from './createEmitter.js' +import { uid } from './utils/uid.js' + +test('default', () => { + const emitter = createEmitter(uid()) + + const onMessage = vi.fn() + emitter.on('message', onMessage) + emitter.emit('message', { type: 'bar', data: 'baz' }) + + expect(onMessage).toHaveBeenCalledWith({ + type: 'bar', + data: 'baz', + uid: emitter.uid, + }) +}) diff --git a/packages/core/src/createEmitter.ts b/packages/core/src/createEmitter.ts new file mode 100644 index 0000000000..20bf4c5a88 --- /dev/null +++ b/packages/core/src/createEmitter.ts @@ -0,0 +1,68 @@ +import { EventEmitter } from 'eventemitter3' + +type EventMap = Record +type EventKey = string & keyof eventMap +type EventFn = ( + ...parameters: parameters +) => void +export type EventData< + eventMap extends EventMap, + eventName extends keyof eventMap, +> = (eventMap[eventName] extends [never] ? unknown : eventMap[eventName]) & { + uid: string +} + +export class Emitter { + _emitter = new EventEmitter() + + constructor(public uid: string) {} + + on>( + eventName: key, + fn: EventFn< + eventMap[key] extends [never] + ? [{ uid: string }] + : [data: eventMap[key] & { uid: string }] + >, + ) { + this._emitter.on(eventName, fn as EventFn) + } + + once>( + eventName: key, + fn: EventFn< + eventMap[key] extends [never] + ? [{ uid: string }] + : [data: eventMap[key] & { uid: string }] + >, + ) { + this._emitter.once(eventName, fn as EventFn) + } + + off>( + eventName: key, + fn: EventFn< + eventMap[key] extends [never] + ? [{ uid: string }] + : [data: eventMap[key] & { uid: string }] + >, + ) { + this._emitter.off(eventName, fn as EventFn) + } + + emit>( + eventName: key, + ...params: eventMap[key] extends [never] ? [] : [data: eventMap[key]] + ) { + const data = params[0] + this._emitter.emit(eventName, { uid: this.uid, ...data }) + } + + listenerCount>(eventName: key) { + return this._emitter.listenerCount(eventName) + } +} + +export function createEmitter(uid: string) { + return new Emitter(uid) +} diff --git a/packages/core/src/createStorage.test-d.ts b/packages/core/src/createStorage.test-d.ts new file mode 100644 index 0000000000..6bb4c7f300 --- /dev/null +++ b/packages/core/src/createStorage.test-d.ts @@ -0,0 +1,74 @@ +import { expectTypeOf, test } from 'vitest' +import { createStorage } from './createStorage.js' + +import type { Connection } from './createConfig.js' + +test('getItem', () => { + const storage = createStorage({ storage: localStorage }) + + expectTypeOf(storage.getItem('recentConnectorId')).toEqualTypeOf< + string | null | Promise + >() + expectTypeOf(storage.getItem('recentConnectorId', 'foo')).toEqualTypeOf< + string | Promise + >() + expectTypeOf(storage.getItem('foo')).toEqualTypeOf() + // @ts-expect-error incorrect argument type + storage.getItem('recentConnectorId', 1n) + + expectTypeOf(storage.getItem('state')).toEqualTypeOf< + | { + chainId?: number | undefined + connections?: Map | undefined + current?: string | null | undefined + status?: + | 'connected' + | 'connecting' + | 'reconnecting' + | 'disconnected' + | undefined + } + | null + | Promise<{ + chainId?: number | undefined + connections?: Map | undefined + current?: string | null | undefined + status?: + | 'connected' + | 'connecting' + | 'reconnecting' + | 'disconnected' + | undefined + } | null> + >() + + const customStorage = createStorage<{ foo: number }>({ + storage: localStorage, + }) + expectTypeOf(customStorage.getItem('foo')).toEqualTypeOf< + number | null | Promise + >() + expectTypeOf(customStorage.getItem('foo', 1)).toEqualTypeOf< + number | Promise + >() +}) + +test('setItem', () => { + const storage = createStorage({ storage: localStorage }) + + storage.setItem('recentConnectorId', 'foo') + // @ts-expect-error incorrect argument type + storage.setItem('recentConnectorId', 1n) +}) + +test('serialize/deserialize types', () => { + createStorage({ + deserialize(value) { + return value + }, + serialize(value) { + return value + }, + storage: localStorage, + }) +}) diff --git a/packages/core/src/createStorage.test.ts b/packages/core/src/createStorage.test.ts new file mode 100644 index 0000000000..06aa0f89d6 --- /dev/null +++ b/packages/core/src/createStorage.test.ts @@ -0,0 +1,45 @@ +import { expect, test, vi } from 'vitest' + +import { createStorage } from './createStorage.js' + +Object.defineProperty(window, 'localStorage', { + value: { + getItem: vi.fn(() => null), + removeItem: vi.fn(() => null), + setItem: vi.fn(() => null), + }, + writable: true, +}) + +test('inits', () => { + const storage = createStorage({ storage: window.localStorage }) + expect(storage).toBeDefined() +}) + +test('getItem', () => { + const storage = createStorage({ storage: window.localStorage }) + storage.getItem('recentConnectorId') + expect(window.localStorage.getItem).toHaveBeenCalledTimes(1) + expect(window.localStorage.getItem).toHaveBeenCalledWith( + 'wagmi.recentConnectorId', + ) +}) + +test('setItem', () => { + const storage = createStorage({ storage: window.localStorage }) + storage.setItem('recentConnectorId', 'bar') + expect(window.localStorage.setItem).toHaveBeenCalledTimes(1) + expect(window.localStorage.setItem).toHaveBeenCalledWith( + 'wagmi.recentConnectorId', + '"bar"', + ) +}) + +test('removeItem', () => { + const storage = createStorage({ storage: window.localStorage }) + storage.removeItem('recentConnectorId') + expect(window.localStorage.removeItem).toHaveBeenCalledTimes(1) + expect(window.localStorage.removeItem).toHaveBeenCalledWith( + 'wagmi.recentConnectorId', + ) +}) diff --git a/packages/core/src/createStorage.ts b/packages/core/src/createStorage.ts new file mode 100644 index 0000000000..8995ca3202 --- /dev/null +++ b/packages/core/src/createStorage.ts @@ -0,0 +1,112 @@ +import type { PartializedState } from './createConfig.js' +import type { Compute } from './types/utils.js' +import { deserialize as deserialize_ } from './utils/deserialize.js' +import { serialize as serialize_ } from './utils/serialize.js' + +// key-values for loose autocomplete and typing +export type StorageItemMap = { + recentConnectorId: string + state: PartializedState +} + +export type Storage< + itemMap extends Record = Record, + /// + storageItemMap extends StorageItemMap = StorageItemMap & itemMap, +> = { + key: string + getItem< + key extends keyof storageItemMap, + value extends storageItemMap[key], + defaultValue extends value | null | undefined, + >( + key: key, + defaultValue?: defaultValue | undefined, + ): + | (defaultValue extends null ? value | null : value) + | Promise + setItem< + key extends keyof storageItemMap, + value extends storageItemMap[key] | null, + >(key: key, value: value): void | Promise + removeItem(key: keyof storageItemMap): void | Promise +} + +export type BaseStorage = { + getItem( + key: string, + ): string | null | undefined | Promise + setItem(key: string, value: string): void | Promise + removeItem(key: string): void | Promise +} + +export type CreateStorageParameters = { + deserialize?: ((value: string) => type | unknown) | undefined + key?: string | undefined + serialize?: ((value: type | any) => string) | undefined + storage?: Compute | undefined +} + +export function createStorage< + itemMap extends Record = Record, + storageItemMap extends StorageItemMap = StorageItemMap & itemMap, +>(parameters: CreateStorageParameters): Compute> { + const { + deserialize = deserialize_, + key: prefix = 'wagmi', + serialize = serialize_, + storage = noopStorage, + } = parameters + + function unwrap(value: type): type | Promise { + if (value instanceof Promise) return value.then((x) => x).catch(() => null) + return value + } + + return { + ...storage, + key: prefix, + async getItem(key, defaultValue) { + const value = storage.getItem(`${prefix}.${key as string}`) + const unwrapped = await unwrap(value) + if (unwrapped) return deserialize(unwrapped) ?? null + return (defaultValue ?? null) as any + }, + async setItem(key, value) { + const storageKey = `${prefix}.${key as string}` + if (value === null) await unwrap(storage.removeItem(storageKey)) + else await unwrap(storage.setItem(storageKey, serialize(value))) + }, + async removeItem(key) { + await unwrap(storage.removeItem(`${prefix}.${key as string}`)) + }, + } +} + +export const noopStorage = { + getItem: () => null, + setItem: () => {}, + removeItem: () => {}, +} satisfies BaseStorage + +export function getDefaultStorage() { + const storage = (() => { + if (typeof window !== 'undefined' && window.localStorage) + return window.localStorage + return noopStorage + })() + return { + getItem(key) { + return storage.getItem(key) + }, + removeItem(key) { + storage.removeItem(key) + }, + setItem(key, value) { + try { + storage.setItem(key, value) + // silence errors by default (QuotaExceededError, SecurityError, etc.) + } catch {} + }, + } satisfies BaseStorage +} diff --git a/packages/core/src/errors/base.test.ts b/packages/core/src/errors/base.test.ts new file mode 100644 index 0000000000..443b1ea3cf --- /dev/null +++ b/packages/core/src/errors/base.test.ts @@ -0,0 +1,155 @@ +import { expect, test } from 'vitest' + +import { BaseError } from './base.js' + +test('BaseError', () => { + expect(new BaseError('An error occurred.')).toMatchInlineSnapshot(` + [WagmiCoreError: An error occurred. + + Version: @wagmi/core@x.y.z] + `) + + expect( + new BaseError('An error occurred.', { details: 'details' }), + ).toMatchInlineSnapshot(` + [WagmiCoreError: An error occurred. + + Details: details + Version: @wagmi/core@x.y.z] + `) + + expect(new BaseError('', { details: 'details' })).toMatchInlineSnapshot(` + [WagmiCoreError: An error occurred. + + Details: details + Version: @wagmi/core@x.y.z] + `) +}) + +test('BaseError (w/ docsPath)', () => { + expect( + new BaseError('An error occurred.', { + details: 'details', + docsPath: '/lol', + }), + ).toMatchInlineSnapshot(` + [WagmiCoreError: An error occurred. + + Docs: https://wagmi.sh/core/lol.html + Details: details + Version: @wagmi/core@x.y.z] + `) + expect( + new BaseError('An error occurred.', { + cause: new BaseError('error', { docsPath: '/docs' }), + }), + ).toMatchInlineSnapshot(` + [WagmiCoreError: An error occurred. + + Docs: https://wagmi.sh/core/docs.html + Version: @wagmi/core@x.y.z] + `) + expect( + new BaseError('An error occurred.', { + cause: new BaseError('error'), + docsPath: '/lol', + }), + ).toMatchInlineSnapshot(` + [WagmiCoreError: An error occurred. + + Docs: https://wagmi.sh/core/lol.html + Version: @wagmi/core@x.y.z] + `) + expect( + new BaseError('An error occurred.', { + details: 'details', + docsPath: '/lol', + docsSlug: 'test', + }), + ).toMatchInlineSnapshot(` + [WagmiCoreError: An error occurred. + + Docs: https://wagmi.sh/core/lol.html#test + Details: details + Version: @wagmi/core@x.y.z] + `) +}) + +test('BaseError (w/ metaMessages)', () => { + expect( + new BaseError('An error occurred.', { + details: 'details', + metaMessages: ['Reason: idk', 'Cause: lol'], + }), + ).toMatchInlineSnapshot(` + [WagmiCoreError: An error occurred. + + Reason: idk + Cause: lol + + Details: details + Version: @wagmi/core@x.y.z] + `) +}) + +test('inherited BaseError', () => { + const err = new BaseError('An error occurred.', { + details: 'details', + docsPath: '/lol', + }) + expect( + new BaseError('An internal error occurred.', { + cause: err, + }), + ).toMatchInlineSnapshot(` + [WagmiCoreError: An internal error occurred. + + Docs: https://wagmi.sh/core/lol.html + Details: details + Version: @wagmi/core@x.y.z] + `) +}) + +test('inherited Error', () => { + const err = new Error('details') + expect( + new BaseError('An internal error occurred.', { + cause: err, + docsPath: '/lol', + }), + ).toMatchInlineSnapshot(` + [WagmiCoreError: An internal error occurred. + + Docs: https://wagmi.sh/core/lol.html + Details: details + Version: @wagmi/core@x.y.z] + `) +}) + +test('walk: no predicate fn (walks to leaf)', () => { + class FooError extends BaseError {} + class BarError extends BaseError {} + + const err = new BaseError('test1', { + cause: new FooError('test2', { cause: new BarError('test3') }), + }) + expect(err.walk()).toMatchInlineSnapshot(` + [WagmiCoreError: test3 + + Version: @wagmi/core@x.y.z] + `) +}) + +test('walk: predicate fn', () => { + class FooError extends BaseError {} + class BarError extends BaseError {} + + const err = new BaseError('test1', { + cause: new FooError('test2', { cause: new BarError('test3') }), + }) + expect(err.walk((err) => err instanceof FooError)).toMatchInlineSnapshot(` + [WagmiCoreError: test2 + + Version: @wagmi/core@x.y.z] + `) +}) diff --git a/packages/core/src/errors/base.ts b/packages/core/src/errors/base.ts new file mode 100644 index 0000000000..8540c1da7b --- /dev/null +++ b/packages/core/src/errors/base.ts @@ -0,0 +1,74 @@ +import type { Compute, OneOf } from '../types/utils.js' +import { getVersion } from '../utils/getVersion.js' + +export type ErrorType = Error & { name: name } + +type BaseErrorOptions = Compute< + OneOf<{ details?: string | undefined } | { cause: BaseError | Error }> & { + docsPath?: string | undefined + docsSlug?: string | undefined + metaMessages?: string[] | undefined + } +> + +export type BaseErrorType = BaseError & { name: 'WagmiCoreError' } +export class BaseError extends Error { + details: string + docsPath?: string | undefined + metaMessages?: string[] | undefined + shortMessage: string + + override name = 'WagmiCoreError' + get docsBaseUrl() { + return 'https://wagmi.sh/core' + } + get version() { + return getVersion() + } + + constructor(shortMessage: string, options: BaseErrorOptions = {}) { + super() + + const details = + options.cause instanceof BaseError + ? options.cause.details + : options.cause?.message + ? options.cause.message + : options.details! + const docsPath = + options.cause instanceof BaseError + ? options.cause.docsPath || options.docsPath + : options.docsPath + + this.message = [ + shortMessage || 'An error occurred.', + '', + ...(options.metaMessages ? [...options.metaMessages, ''] : []), + ...(docsPath + ? [ + `Docs: ${this.docsBaseUrl}${docsPath}.html${ + options.docsSlug ? `#${options.docsSlug}` : '' + }`, + ] + : []), + ...(details ? [`Details: ${details}`] : []), + `Version: ${this.version}`, + ].join('\n') + + if (options.cause) this.cause = options.cause + this.details = details + this.docsPath = docsPath + this.metaMessages = options.metaMessages + this.shortMessage = shortMessage + } + + walk(fn?: (err: unknown) => boolean) { + return this.#walk(this, fn) + } + + #walk(err: unknown, fn?: (err: unknown) => boolean): unknown { + if (fn?.(err)) return err + if ((err as Error).cause) return this.#walk((err as Error).cause, fn) + return err + } +} diff --git a/packages/core/src/errors/config.test.ts b/packages/core/src/errors/config.test.ts new file mode 100644 index 0000000000..1ec07fd107 --- /dev/null +++ b/packages/core/src/errors/config.test.ts @@ -0,0 +1,68 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { + ChainNotConfiguredError, + ConnectorAccountNotFoundError, + ConnectorAlreadyConnectedError, + ConnectorChainMismatchError, + ConnectorNotConnectedError, + ConnectorNotFoundError, + ConnectorUnavailableReconnectingError, +} from './config.js' + +test('constructors', () => { + expect(new ChainNotConfiguredError()).toMatchInlineSnapshot(` + [ChainNotConfiguredError: Chain not configured. + + Version: @wagmi/core@x.y.z] + `) + expect(new ConnectorAlreadyConnectedError()).toMatchInlineSnapshot(` + [ConnectorAlreadyConnectedError: Connector already connected. + + Version: @wagmi/core@x.y.z] + `) + expect(new ConnectorNotConnectedError()).toMatchInlineSnapshot(` + [ConnectorNotConnectedError: Connector not connected. + + Version: @wagmi/core@x.y.z] + `) + expect(new ConnectorNotFoundError()).toMatchInlineSnapshot(` + [ConnectorNotFoundError: Connector not found. + + Version: @wagmi/core@x.y.z] + `) + expect( + new ConnectorAccountNotFoundError({ + address: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + connector: config.connectors[0]!, + }), + ).toMatchInlineSnapshot(` + [ConnectorAccountNotFoundError: Account "0xA0Cf798816D4b9b9866b5330EEa46a18382f251e" not found for connector "Mock Connector". + + Version: @wagmi/core@x.y.z] + `) + expect( + new ConnectorChainMismatchError({ + connectionChainId: 1, + connectorChainId: 123, + }), + ).toMatchInlineSnapshot(` + [ConnectorChainMismatchError: The current chain of the connector (id: 123) does not match the connection's chain (id: 1). + + Current Chain ID: 123 + Expected Chain ID: 1 + + Version: @wagmi/core@x.y.z] + `) + expect( + new ConnectorUnavailableReconnectingError({ + connector: { name: 'Rabby Wallet' }, + }), + ).toMatchInlineSnapshot(` + [ConnectorUnavailableReconnectingError: Connector "Rabby Wallet" unavailable while reconnecting. + + Details: During the reconnection step, the only connector methods guaranteed to be available are: \`id\`, \`name\`, \`type\`, \`uid\`. All other methods are not guaranteed to be available until reconnection completes and connectors are fully restored. This error commonly occurs for connectors that asynchronously inject after reconnection has already started. + Version: @wagmi/core@x.y.z] + `) +}) diff --git a/packages/core/src/errors/config.ts b/packages/core/src/errors/config.ts new file mode 100644 index 0000000000..2956f0132c --- /dev/null +++ b/packages/core/src/errors/config.ts @@ -0,0 +1,103 @@ +import type { Address } from 'viem' + +import type { Connector } from '../createConfig.js' +import { BaseError } from './base.js' + +export type ChainNotConfiguredErrorType = ChainNotConfiguredError & { + name: 'ChainNotConfiguredError' +} +export class ChainNotConfiguredError extends BaseError { + override name = 'ChainNotConfiguredError' + constructor() { + super('Chain not configured.') + } +} + +export type ConnectorAlreadyConnectedErrorType = + ConnectorAlreadyConnectedError & { + name: 'ConnectorAlreadyConnectedError' + } +export class ConnectorAlreadyConnectedError extends BaseError { + override name = 'ConnectorAlreadyConnectedError' + constructor() { + super('Connector already connected.') + } +} + +export type ConnectorNotConnectedErrorType = ConnectorNotConnectedError & { + name: 'ConnectorNotConnectedError' +} +export class ConnectorNotConnectedError extends BaseError { + override name = 'ConnectorNotConnectedError' + constructor() { + super('Connector not connected.') + } +} + +export type ConnectorNotFoundErrorType = ConnectorNotFoundError & { + name: 'ConnectorNotFoundError' +} +export class ConnectorNotFoundError extends BaseError { + override name = 'ConnectorNotFoundError' + constructor() { + super('Connector not found.') + } +} + +export type ConnectorAccountNotFoundErrorType = + ConnectorAccountNotFoundError & { + name: 'ConnectorAccountNotFoundError' + } +export class ConnectorAccountNotFoundError extends BaseError { + override name = 'ConnectorAccountNotFoundError' + constructor({ + address, + connector, + }: { + address: Address + connector: Connector + }) { + super(`Account "${address}" not found for connector "${connector.name}".`) + } +} + +export type ConnectorChainMismatchErrorType = ConnectorAccountNotFoundError & { + name: 'ConnectorChainMismatchError' +} +export class ConnectorChainMismatchError extends BaseError { + override name = 'ConnectorChainMismatchError' + constructor({ + connectionChainId, + connectorChainId, + }: { + connectionChainId: number + connectorChainId: number + }) { + super( + `The current chain of the connector (id: ${connectorChainId}) does not match the connection's chain (id: ${connectionChainId}).`, + { + metaMessages: [ + `Current Chain ID: ${connectorChainId}`, + `Expected Chain ID: ${connectionChainId}`, + ], + }, + ) + } +} + +export type ConnectorUnavailableReconnectingErrorType = + ConnectorUnavailableReconnectingError & { + name: 'ConnectorUnavailableReconnectingError' + } +export class ConnectorUnavailableReconnectingError extends BaseError { + override name = 'ConnectorUnavailableReconnectingError' + constructor({ connector }: { connector: { name: string } }) { + super(`Connector "${connector.name}" unavailable while reconnecting.`, { + details: [ + 'During the reconnection step, the only connector methods guaranteed to be available are: `id`, `name`, `type`, `uid`.', + 'All other methods are not guaranteed to be available until reconnection completes and connectors are fully restored.', + 'This error commonly occurs for connectors that asynchronously inject after reconnection has already started.', + ].join(' '), + }) + } +} diff --git a/packages/core/src/errors/connector.test.ts b/packages/core/src/errors/connector.test.ts new file mode 100644 index 0000000000..258ef834cd --- /dev/null +++ b/packages/core/src/errors/connector.test.ts @@ -0,0 +1,24 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { + ProviderNotFoundError, + SwitchChainNotSupportedError, +} from './connector.js' + +test('constructors', () => { + expect(new ProviderNotFoundError()).toMatchInlineSnapshot(` + [ProviderNotFoundError: Provider not found. + + Version: @wagmi/core@x.y.z] + `) + expect( + new SwitchChainNotSupportedError({ + connector: config.connectors[0]!, + }), + ).toMatchInlineSnapshot(` + [SwitchChainNotSupportedError: "Mock Connector" does not support programmatic chain switching. + + Version: @wagmi/core@x.y.z] + `) +}) diff --git a/packages/core/src/errors/connector.ts b/packages/core/src/errors/connector.ts new file mode 100644 index 0000000000..c6c30ef1a5 --- /dev/null +++ b/packages/core/src/errors/connector.ts @@ -0,0 +1,23 @@ +import type { Connector } from '../createConfig.js' +import { BaseError } from './base.js' + +export type ProviderNotFoundErrorType = ProviderNotFoundError & { + name: 'ProviderNotFoundError' +} +export class ProviderNotFoundError extends BaseError { + override name = 'ProviderNotFoundError' + constructor() { + super('Provider not found.') + } +} + +export type SwitchChainNotSupportedErrorType = SwitchChainNotSupportedError & { + name: 'SwitchChainNotSupportedError' +} +export class SwitchChainNotSupportedError extends BaseError { + override name = 'SwitchChainNotSupportedError' + + constructor({ connector }: { connector: Connector }) { + super(`"${connector.name}" does not support programmatic chain switching.`) + } +} diff --git a/packages/core/src/experimental/actions/writeContracts.test.ts b/packages/core/src/experimental/actions/writeContracts.test.ts new file mode 100644 index 0000000000..b74cd780ef --- /dev/null +++ b/packages/core/src/experimental/actions/writeContracts.test.ts @@ -0,0 +1,99 @@ +import { abi, address, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { connect } from '../../actions/connect.js' +import { disconnect } from '../../actions/disconnect.js' +import { writeContracts } from './writeContracts.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + await expect( + writeContracts(config, { + contracts: [ + { + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }, + { + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }, + { + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }, + ], + }), + ).resolves.toMatchInlineSnapshot( + ` + { + "id": "0x8913636bd97cf4bcc0a6343c730905a27ead0f7480ff82190072e916439eb212", + } + `, + ) + await disconnect(config, { connector }) +}) + +test('behavior: not connected', async () => { + await expect( + writeContracts(config, { + contracts: [ + { + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }, + { + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }, + { + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }, + ], + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ConnectorNotConnectedError: Connector not connected. + + Version: @wagmi/core@x.y.z] + `) +}) + +test('behavior: account does not exist on connector', async () => { + await connect(config, { connector }) + await expect( + writeContracts(config, { + account: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + contracts: [ + { + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }, + { + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }, + { + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }, + ], + }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ConnectorAccountNotFoundError: Account "0xA0Cf798816D4b9b9866b5330EEa46a18382f251e" not found for connector "Mock Connector". + + Version: @wagmi/core@x.y.z] + `) + await disconnect(config, { connector }) +}) diff --git a/packages/core/src/experimental/actions/writeContracts.ts b/packages/core/src/experimental/actions/writeContracts.ts new file mode 100644 index 0000000000..06e6687592 --- /dev/null +++ b/packages/core/src/experimental/actions/writeContracts.ts @@ -0,0 +1,78 @@ +import type { Account, Chain, ContractFunctionParameters } from 'viem' +import { + type WriteContractsErrorType as viem_WriteContractsErrorType, + type WriteContractsParameters as viem_WriteContractsParameters, + type WriteContractsReturnType as viem_WriteContractsReturnType, + writeContracts as viem_writeContracts, +} from 'viem/experimental' + +import { + type GetConnectorClientErrorType, + getConnectorClient, +} from '../../actions/getConnectorClient.js' +import type { Config } from '../../createConfig.js' +import type { BaseErrorType, ErrorType } from '../../errors/base.js' +import type { SelectChains } from '../../types/chain.js' +import type { + ChainIdParameter, + ConnectorParameter, +} from '../../types/properties.js' +import type { Compute } from '../../types/utils.js' + +export type WriteContractsParameters< + contracts extends readonly unknown[] = readonly ContractFunctionParameters[], + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + /// + chains extends readonly Chain[] = SelectChains, +> = { + [key in keyof chains]: Compute< + Omit< + viem_WriteContractsParameters< + contracts, + chains[key], + Account, + chains[key] + >, + 'chain' + > & + ChainIdParameter & + ConnectorParameter + > +}[number] + +export type WriteContractsReturnType = viem_WriteContractsReturnType + +export type WriteContractsErrorType = + // getConnectorClient() + | GetConnectorClientErrorType + // base + | BaseErrorType + | ErrorType + // viem + | viem_WriteContractsErrorType + +/** https://wagmi.sh/core/api/actions/writeContracts */ +export async function writeContracts< + const contracts extends readonly unknown[], + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + parameters: WriteContractsParameters, +): Promise { + const { account, chainId, connector, ...rest } = parameters + + const client = await getConnectorClient(config, { + account, + chainId, + connector, + }) + + return viem_writeContracts(client, { + ...(rest as any), + ...(account ? { account } : {}), + chain: chainId ? { id: chainId } : undefined, + }) +} diff --git a/packages/core/src/experimental/query/writeContracts.test.ts b/packages/core/src/experimental/query/writeContracts.test.ts new file mode 100644 index 0000000000..5f4a1f28dd --- /dev/null +++ b/packages/core/src/experimental/query/writeContracts.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { writeContractsMutationOptions } from './writeContracts.js' + +test('default', () => { + expect(writeContractsMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "writeContracts", + ], + } + `) +}) diff --git a/packages/core/src/experimental/query/writeContracts.ts b/packages/core/src/experimental/query/writeContracts.ts new file mode 100644 index 0000000000..192a842ca0 --- /dev/null +++ b/packages/core/src/experimental/query/writeContracts.ts @@ -0,0 +1,70 @@ +import type { MutateOptions, MutationOptions } from '@tanstack/query-core' + +import type { Config } from '../../createConfig.js' +import type { Compute } from '../../types/utils.js' +import { + type WriteContractsErrorType, + type WriteContractsParameters, + type WriteContractsReturnType, + writeContracts, +} from '../actions/writeContracts.js' + +export function writeContractsMutationOptions< + const contracts extends readonly unknown[], + config extends Config, +>(config: config) { + return { + mutationFn(variables) { + return writeContracts(config, variables as any) as any + }, + mutationKey: ['writeContracts'], + } as const satisfies MutationOptions< + WriteContractsData, + WriteContractsErrorType, + WriteContractsVariables + > +} + +export type WriteContractsData = Compute + +export type WriteContractsVariables< + contracts extends readonly unknown[], + config extends Config, + chainId extends config['chains'][number]['id'], +> = WriteContractsParameters + +export type WriteContractsMutate< + contracts extends readonly unknown[], + config extends Config, + context = unknown, +> = ( + variables: WriteContractsVariables, + options?: + | Compute< + MutateOptions< + WriteContractsData, + WriteContractsErrorType, + Compute>, + context + > + > + | undefined, +) => void + +export type WriteContractsMutateAsync< + contracts extends readonly unknown[], + config extends Config, + context = unknown, +> = ( + variables: WriteContractsVariables, + options?: + | Compute< + MutateOptions< + WriteContractsData, + WriteContractsErrorType, + Compute>, + context + > + > + | undefined, +) => Promise diff --git a/packages/core/src/exports/actions.test.ts b/packages/core/src/exports/actions.test.ts new file mode 100644 index 0000000000..eaaedba14f --- /dev/null +++ b/packages/core/src/exports/actions.test.ts @@ -0,0 +1,86 @@ +import { expect, test } from 'vitest' + +import * as actions from './actions.js' + +test('exports', () => { + expect(Object.keys(actions)).toMatchInlineSnapshot(` + [ + "call", + "connect", + "deployContract", + "disconnect", + "estimateGas", + "estimateFeesPerGas", + "estimateMaxPriorityFeePerGas", + "getAccount", + "getBalance", + "fetchBalance", + "getBlock", + "getBlockNumber", + "fetchBlockNumber", + "getBlockTransactionCount", + "getBytecode", + "getCallsStatus", + "getCapabilities", + "getChainId", + "getChains", + "getClient", + "getConnections", + "getConnectors", + "getConnectorClient", + "getEnsAddress", + "fetchEnsAddress", + "getEnsAvatar", + "fetchEnsAvatar", + "getEnsName", + "fetchEnsName", + "getEnsResolver", + "fetchEnsResolver", + "getEnsText", + "getFeeHistory", + "getGasPrice", + "getProof", + "getPublicClient", + "getStorageAt", + "getToken", + "fetchToken", + "getTransaction", + "fetchTransaction", + "getTransactionConfirmations", + "getTransactionCount", + "getTransactionReceipt", + "getWalletClient", + "multicall", + "prepareTransactionRequest", + "readContract", + "readContracts", + "reconnect", + "sendCalls", + "sendTransaction", + "showCallsStatus", + "signMessage", + "signTypedData", + "simulateContract", + "switchAccount", + "switchChain", + "switchNetwork", + "verifyMessage", + "verifyTypedData", + "waitForCallsStatus", + "watchAccount", + "watchAsset", + "watchBlocks", + "watchBlockNumber", + "watchChainId", + "watchClient", + "watchConnections", + "watchConnectors", + "watchContractEvent", + "watchPendingTransactions", + "watchPublicClient", + "waitForTransactionReceipt", + "waitForTransaction", + "writeContract", + ] + `) +}) diff --git a/packages/core/src/exports/actions.ts b/packages/core/src/exports/actions.ts new file mode 100644 index 0000000000..d03c2adb76 --- /dev/null +++ b/packages/core/src/exports/actions.ts @@ -0,0 +1,460 @@ +//////////////////////////////////////////////////////////////////////////////// +// Actions +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { + type CallErrorType, + type CallParameters, + type CallReturnType, + call, +} from '../actions/call.js' + +export { + type ConnectErrorType, + type ConnectParameters, + type ConnectReturnType, + connect, +} from '../actions/connect.js' + +export { + type DeployContractErrorType, + type DeployContractParameters, + type DeployContractReturnType, + deployContract, +} from '../actions/deployContract.js' + +export { + type DisconnectErrorType, + type DisconnectParameters, + type DisconnectReturnType, + disconnect, +} from '../actions/disconnect.js' + +export { + type EstimateGasErrorType, + type EstimateGasParameters, + type EstimateGasReturnType, + estimateGas, +} from '../actions/estimateGas.js' + +export { + type EstimateFeesPerGasErrorType, + type EstimateFeesPerGasParameters, + type EstimateFeesPerGasReturnType, + estimateFeesPerGas, +} from '../actions/estimateFeesPerGas.js' + +export { + type EstimateMaxPriorityFeePerGasErrorType, + type EstimateMaxPriorityFeePerGasParameters, + type EstimateMaxPriorityFeePerGasReturnType, + estimateMaxPriorityFeePerGas, +} from '../actions/estimateMaxPriorityFeePerGas.js' + +export { + type GetAccountReturnType, + getAccount, +} from '../actions/getAccount.js' + +export { + type GetBalanceParameters, + type GetBalanceReturnType, + type GetBalanceErrorType, + getBalance, + /** @deprecated use `getBalance` instead */ + getBalance as fetchBalance, +} from '../actions/getBalance.js' + +export { + type GetBlockErrorType, + type GetBlockParameters, + type GetBlockReturnType, + getBlock, +} from '../actions/getBlock.js' + +export { + type GetBlockNumberErrorType, + type GetBlockNumberParameters, + type GetBlockNumberReturnType, + getBlockNumber, + /** @deprecated use `getBlockNumber` instead */ + getBlockNumber as fetchBlockNumber, +} from '../actions/getBlockNumber.js' + +export { + type GetBlockTransactionCountErrorType, + type GetBlockTransactionCountParameters, + type GetBlockTransactionCountReturnType, + getBlockTransactionCount, +} from '../actions/getBlockTransactionCount.js' + +export { + type GetBytecodeErrorType, + type GetBytecodeParameters, + type GetBytecodeReturnType, + getBytecode, +} from '../actions/getBytecode.js' + +export { + type GetCallsStatusErrorType, + type GetCallsStatusParameters, + type GetCallsStatusReturnType, + getCallsStatus, +} from '../actions/getCallsStatus.js' + +export { + type GetCapabilitiesErrorType, + type GetCapabilitiesParameters, + type GetCapabilitiesReturnType, + getCapabilities, +} from '../actions/getCapabilities.js' + +export { + type GetChainIdReturnType, + getChainId, +} from '../actions/getChainId.js' + +export { + type GetChainsReturnType, + getChains, +} from '../actions/getChains.js' + +export { + type GetClientParameters, + type GetClientReturnType, + getClient, +} from '../actions/getClient.js' + +export { + type GetConnectionsReturnType, + getConnections, +} from '../actions/getConnections.js' + +export { + type GetConnectorsReturnType, + getConnectors, +} from '../actions/getConnectors.js' + +export { + type GetConnectorClientErrorType, + type GetConnectorClientParameters, + type GetConnectorClientReturnType, + getConnectorClient, +} from '../actions/getConnectorClient.js' + +export { + type GetEnsAddressErrorType, + type GetEnsAddressParameters, + type GetEnsAddressReturnType, + getEnsAddress, + /** @deprecated use `getEnsAddress` instead */ + getEnsAddress as fetchEnsAddress, +} from '../actions/getEnsAddress.js' + +export { + type GetEnsAvatarErrorType, + type GetEnsAvatarParameters, + type GetEnsAvatarReturnType, + getEnsAvatar, + /** @deprecated use `getEnsAvatar` instead */ + getEnsAvatar as fetchEnsAvatar, +} from '../actions/getEnsAvatar.js' + +export { + type GetEnsNameErrorType, + type GetEnsNameParameters, + type GetEnsNameReturnType, + getEnsName, + /** @deprecated */ + getEnsName as fetchEnsName, +} from '../actions/getEnsName.js' + +export { + type GetEnsResolverErrorType, + type GetEnsResolverParameters, + type GetEnsResolverReturnType, + getEnsResolver, + /** @deprecated use `getEnsResolver` instead */ + getEnsResolver as fetchEnsResolver, +} from '../actions/getEnsResolver.js' + +export { + type GetEnsTextErrorType, + type GetEnsTextParameters, + type GetEnsTextReturnType, + getEnsText, +} from '../actions/getEnsText.js' + +export { + type GetFeeHistoryErrorType, + type GetFeeHistoryParameters, + type GetFeeHistoryReturnType, + getFeeHistory, +} from '../actions/getFeeHistory.js' + +export { + type GetGasPriceErrorType, + type GetGasPriceParameters, + type GetGasPriceReturnType, + getGasPrice, +} from '../actions/getGasPrice.js' + +export { + type GetProofErrorType, + type GetProofParameters, + type GetProofReturnType, + getProof, +} from '../actions/getProof.js' + +export { + type GetPublicClientParameters, + type GetPublicClientReturnType, + getPublicClient, +} from '../actions/getPublicClient.js' + +export { + type GetStorageAtErrorType, + type GetStorageAtParameters, + type GetStorageAtReturnType, + getStorageAt, +} from '../actions/getStorageAt.js' + +export { + type GetTokenErrorType, + type GetTokenParameters, + type GetTokenReturnType, + getToken, + /** @deprecated use `getToken` instead */ + getToken as fetchToken, +} from '../actions/getToken.js' + +export { + type GetTransactionErrorType, + type GetTransactionParameters, + type GetTransactionReturnType, + getTransaction, + /** @deprecated use `getTransaction` instead */ + getTransaction as fetchTransaction, +} from '../actions/getTransaction.js' + +export { + type GetTransactionConfirmationsErrorType, + type GetTransactionConfirmationsParameters, + type GetTransactionConfirmationsReturnType, + getTransactionConfirmations, +} from '../actions/getTransactionConfirmations.js' + +export { + type GetTransactionCountErrorType, + type GetTransactionCountParameters, + type GetTransactionCountReturnType, + getTransactionCount, +} from '../actions/getTransactionCount.js' + +export { + type GetTransactionReceiptErrorType, + type GetTransactionReceiptParameters, + type GetTransactionReceiptReturnType, + getTransactionReceipt, +} from '../actions/getTransactionReceipt.js' + +export { + type GetWalletClientErrorType, + type GetWalletClientParameters, + type GetWalletClientReturnType, + getWalletClient, +} from '../actions/getWalletClient.js' + +export { + type MulticallParameters, + type MulticallReturnType, + multicall, +} from '../actions/multicall.js' + +export { + type PrepareTransactionRequestParameters, + type PrepareTransactionRequestReturnType, + type PrepareTransactionRequestErrorType, + prepareTransactionRequest, +} from '../actions/prepareTransactionRequest.js' + +export { + type ReadContractParameters, + type ReadContractReturnType, + type ReadContractErrorType, + readContract, +} from '../actions/readContract.js' + +export { + type ReadContractsParameters, + type ReadContractsReturnType, + type ReadContractsErrorType, + readContracts, +} from '../actions/readContracts.js' + +export { + type ReconnectErrorType, + type ReconnectParameters, + type ReconnectReturnType, + reconnect, +} from '../actions/reconnect.js' + +export { + type SendCallsErrorType, + type SendCallsParameters, + type SendCallsReturnType, + sendCalls, +} from '../actions/sendCalls.js' + +export { + type SendTransactionErrorType, + type SendTransactionParameters, + type SendTransactionReturnType, + sendTransaction, +} from '../actions/sendTransaction.js' + +export { + type ShowCallsStatusErrorType, + type ShowCallsStatusParameters, + type ShowCallsStatusReturnType, + showCallsStatus, +} from '../actions/showCallsStatus.js' + +export { + type SignMessageErrorType, + type SignMessageParameters, + type SignMessageReturnType, + signMessage, +} from '../actions/signMessage.js' + +export { + type SignTypedDataErrorType, + type SignTypedDataParameters, + type SignTypedDataReturnType, + signTypedData, +} from '../actions/signTypedData.js' + +export { + type SimulateContractErrorType, + type SimulateContractParameters, + type SimulateContractReturnType, + simulateContract, +} from '../actions/simulateContract.js' + +export { + type SwitchAccountErrorType, + type SwitchAccountParameters, + type SwitchAccountReturnType, + switchAccount, +} from '../actions/switchAccount.js' + +export { + type SwitchChainErrorType, + type SwitchChainParameters, + type SwitchChainReturnType, + switchChain, + /** @deprecated use `switchChain` instead */ + switchChain as switchNetwork, +} from '../actions/switchChain.js' + +export { + type VerifyMessageParameters, + type VerifyMessageReturnType, + verifyMessage, +} from '../actions/verifyMessage.js' + +export { + type VerifyTypedDataParameters, + type VerifyTypedDataReturnType, + verifyTypedData, +} from '../actions/verifyTypedData.js' + +export { + type WaitForCallsStatusErrorType, + type WaitForCallsStatusParameters, + type WaitForCallsStatusReturnType, + waitForCallsStatus, +} from '../actions/waitForCallsStatus.js' + +export { + type WatchAccountParameters, + type WatchAccountReturnType, + watchAccount, +} from '../actions/watchAccount.js' + +export { + type WatchAssetParameters, + type WatchAssetReturnType, + watchAsset, +} from '../actions/watchAsset.js' + +export { + type WatchBlocksParameters, + type WatchBlocksReturnType, + watchBlocks, +} from '../actions/watchBlocks.js' + +export { + type WatchBlockNumberParameters, + type WatchBlockNumberReturnType, + watchBlockNumber, +} from '../actions/watchBlockNumber.js' + +export { + type WatchChainIdParameters, + type WatchChainIdReturnType, + watchChainId, +} from '../actions/watchChainId.js' + +export { + type WatchClientParameters, + type WatchClientReturnType, + watchClient, +} from '../actions/watchClient.js' + +export { + type WatchConnectionsParameters, + type WatchConnectionsReturnType, + watchConnections, +} from '../actions/watchConnections.js' + +export { + type WatchConnectorsParameters, + type WatchConnectorsReturnType, + watchConnectors, +} from '../actions/watchConnectors.js' + +export { + type WatchContractEventParameters, + type WatchContractEventReturnType, + watchContractEvent, +} from '../actions/watchContractEvent.js' + +export { + type WatchPendingTransactionsParameters, + type WatchPendingTransactionsReturnType, + watchPendingTransactions, +} from '../actions/watchPendingTransactions.js' + +export { + type WatchPublicClientParameters, + type WatchPublicClientReturnType, + watchPublicClient, +} from '../actions/watchPublicClient.js' + +export { + type WaitForTransactionReceiptErrorType, + type WaitForTransactionReceiptParameters, + type WaitForTransactionReceiptReturnType, + waitForTransactionReceipt, + /** @deprecated use `waitForTransactionReceipt` instead */ + waitForTransactionReceipt as waitForTransaction, +} from '../actions/waitForTransactionReceipt.js' + +export { + type WriteContractErrorType, + type WriteContractParameters, + type WriteContractReturnType, + writeContract, +} from '../actions/writeContract.js' diff --git a/packages/core/src/exports/chains.ts b/packages/core/src/exports/chains.ts new file mode 100644 index 0000000000..1fca7f537f --- /dev/null +++ b/packages/core/src/exports/chains.ts @@ -0,0 +1,7 @@ +//////////////////////////////////////////////////////////////////////////////// +// viem/chains +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from 'viem/chains' diff --git a/packages/core/src/exports/codegen.test.ts b/packages/core/src/exports/codegen.test.ts new file mode 100644 index 0000000000..c947b7d188 --- /dev/null +++ b/packages/core/src/exports/codegen.test.ts @@ -0,0 +1,14 @@ +import { expect, test } from 'vitest' + +import * as codegen from './codegen.js' + +test('exports', () => { + expect(Object.keys(codegen)).toMatchInlineSnapshot(` + [ + "createSimulateContract", + "createReadContract", + "createWatchContractEvent", + "createWriteContract", + ] + `) +}) diff --git a/packages/core/src/exports/codegen.ts b/packages/core/src/exports/codegen.ts new file mode 100644 index 0000000000..bed8aa1cc7 --- /dev/null +++ b/packages/core/src/exports/codegen.ts @@ -0,0 +1,24 @@ +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { + type CreateSimulateContractParameters, + type CreateSimulateContractReturnType, + createSimulateContract, +} from '../actions/codegen/createSimulateContract.js' + +export { + type CreateReadContractParameters, + type CreateReadContractReturnType, + createReadContract, +} from '../actions/codegen/createReadContract.js' + +export { + type CreateWatchContractEventParameters, + type CreateWatchContractEventReturnType, + createWatchContractEvent, +} from '../actions/codegen/createWatchContractEvent.js' + +export { + type CreateWriteContractParameters, + type CreateWriteContractReturnType, + createWriteContract, +} from '../actions/codegen/createWriteContract.js' diff --git a/packages/core/src/exports/experimental.ts b/packages/core/src/exports/experimental.ts new file mode 100644 index 0000000000..f74baa82cb --- /dev/null +++ b/packages/core/src/exports/experimental.ts @@ -0,0 +1,158 @@ +//////////////////////////////////////////////////////////////////////////////// +// Actions +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { + /** @deprecated This is no longer experimental – use `import type { GetCallsStatusErrorType } from '@wagmi/core'` instead. */ + type GetCallsStatusErrorType, + /** @deprecated This is no longer experimental – use `import type { GetCallsStatusParameters } from '@wagmi/core'` instead. */ + type GetCallsStatusParameters, + /** @deprecated This is no longer experimental – use `import type { GetCallsStatusReturnType } from '@wagmi/core'` instead. */ + type GetCallsStatusReturnType, + /** @deprecated This is no longer experimental – use `import { getCallsStatus } from '@wagmi/core'` instead. */ + getCallsStatus, +} from '../actions/getCallsStatus.js' + +export { + /** @deprecated This is no longer experimental – use `import type { GetCapabilitiesErrorType } from '@wagmi/core'` instead. */ + type GetCapabilitiesErrorType, + /** @deprecated This is no longer experimental – use `import type { GetCapabilitiesParameters } from '@wagmi/core'` instead. */ + type GetCapabilitiesParameters, + /** @deprecated This is no longer experimental – use `import type { GetCapabilitiesReturnType } from '@wagmi/core'` instead. */ + type GetCapabilitiesReturnType, + /** @deprecated This is no longer experimental – use `import { getCapabilities } from '@wagmi/core'` instead. */ + getCapabilities, +} from '../actions/getCapabilities.js' + +export { + /** @deprecated This is no longer experimental – use `import type { SendCallsErrorType } from '@wagmi/core'` instead. */ + type SendCallsErrorType, + /** @deprecated This is no longer experimental – use `import type { SendCallsParameters } from '@wagmi/core'` instead. */ + type SendCallsParameters, + /** @deprecated This is no longer experimental – use `import type { SendCallsReturnType } from '@wagmi/core'` instead. */ + type SendCallsReturnType, + /** @deprecated This is no longer experimental – use `import { sendCalls } from '@wagmi/core'` instead. */ + sendCalls, +} from '../actions/sendCalls.js' + +export { + /** @deprecated This is no longer experimental – use `import type { ShowCallsStatusErrorType } from '@wagmi/core'` instead. */ + type ShowCallsStatusErrorType, + /** @deprecated This is no longer experimental – use `import type { ShowCallsStatusParameters } from '@wagmi/core'` instead. */ + type ShowCallsStatusParameters, + /** @deprecated This is no longer experimental – use `import type { ShowCallsStatusReturnType } from '@wagmi/core'` instead. */ + type ShowCallsStatusReturnType, + /** @deprecated This is no longer experimental – use `import { showCallsStatus } from '@wagmi/core'` instead. */ + showCallsStatus, +} from '../actions/showCallsStatus.js' + +export { + /** @deprecated This is no longer experimental – use `import type { WaitForCallsStatusErrorType } from '@wagmi/core'` instead. */ + type WaitForCallsStatusErrorType, + /** @deprecated This is no longer experimental – use `import type { WaitForCallsStatusParameters } from '@wagmi/core'` instead. */ + type WaitForCallsStatusParameters, + /** @deprecated This is no longer experimental – use `import type { WaitForCallsStatusReturnType } from '@wagmi/core'` instead. */ + type WaitForCallsStatusReturnType, + /** @deprecated This is no longer experimental – use `import { waitForCallsStatus } from '@wagmi/core'` instead. */ + waitForCallsStatus, +} from '../actions/waitForCallsStatus.js' + +export { + /** @deprecated Use `SendCallsErrorType` instead. */ + type WriteContractsErrorType, + /** @deprecated Use `SendCallsParameters` instead. */ + type WriteContractsParameters, + /** @deprecated Use `SendCallsReturnType` instead. */ + type WriteContractsReturnType, + /** @deprecated Use `sendCalls` instead. */ + writeContracts, +} from '../experimental/actions/writeContracts.js' + +//////////////////////////////////////////////////////////////////////////////// +// Tanstack Query +//////////////////////////////////////////////////////////////////////////////// + +export { + /** @deprecated This is no longer experimental – use `import type { GetCallsStatusData } from '@wagmi/core/query'` instead. */ + type GetCallsStatusData, + /** @deprecated This is no longer experimental – use `import type { GetCallsStatusOptions } from '@wagmi/core/query'` instead. */ + type GetCallsStatusOptions, + /** @deprecated This is no longer experimental – use `import type { GetCallsStatusQueryFnData } from '@wagmi/core/query'` instead. */ + type GetCallsStatusQueryFnData, + /** @deprecated This is no longer experimental – use `import type { GetCallsStatusQueryKey } from '@wagmi/core/query'` instead. */ + type GetCallsStatusQueryKey, + /** @deprecated This is no longer experimental – use `import { getCallsStatusQueryOptions } from '@wagmi/core/query'` instead. */ + getCallsStatusQueryOptions, + /** @deprecated This is no longer experimental – use `import { getCallsStatusQueryKey } from '@wagmi/core/query'` instead. */ + getCallsStatusQueryKey, +} from '../query/getCallsStatus.js' + +export { + /** @deprecated This is no longer experimental – use `import type { GetCapabilitiesData } from '@wagmi/core/query'` instead. */ + type GetCapabilitiesData, + /** @deprecated This is no longer experimental – use `import type { GetCapabilitiesOptions } from '@wagmi/core/query'` instead. */ + type GetCapabilitiesOptions, + /** @deprecated This is no longer experimental – use `import type { GetCapabilitiesQueryFnData } from '@wagmi/core/query'` instead. */ + type GetCapabilitiesQueryFnData, + /** @deprecated This is no longer experimental – use `import type { GetCapabilitiesQueryKey } from '@wagmi/core/query'` instead. */ + type GetCapabilitiesQueryKey, + /** @deprecated This is no longer experimental – use `import { getCapabilitiesQueryOptions } from '@wagmi/core/query'` instead. */ + getCapabilitiesQueryOptions, + /** @deprecated This is no longer experimental – use `import { getCapabilitiesQueryKey } from '@wagmi/core/query'` instead. */ + getCapabilitiesQueryKey, +} from '../query/getCapabilities.js' + +export { + /** @deprecated This is no longer experimental – use `import type { SendCallsData } from '@wagmi/core/query'` instead. */ + type SendCallsData, + /** @deprecated This is no longer experimental – use `import type { SendCallsMutate } from '@wagmi/core/query'` instead. */ + type SendCallsMutate, + /** @deprecated This is no longer experimental – use `import type { SendCallsMutateAsync } from '@wagmi/core/query'` instead. */ + type SendCallsMutateAsync, + /** @deprecated This is no longer experimental – use `import type { SendCallsVariables } from '@wagmi/core/query'` instead. */ + type SendCallsVariables, + /** @deprecated This is no longer experimental – use `import { sendCallsMutationOptions } from '@wagmi/core/query'` instead. */ + sendCallsMutationOptions, +} from '../query/sendCalls.js' + +export { + /** @deprecated This is no longer experimental – use `import type { ShowCallsStatusData } from '@wagmi/core/query'` instead. */ + type ShowCallsStatusData, + /** @deprecated This is no longer experimental – use `import type { ShowCallsStatusMutate } from '@wagmi/core/query'` instead. */ + type ShowCallsStatusMutate, + /** @deprecated This is no longer experimental – use `import type { ShowCallsStatusMutateAsync } from '@wagmi/core/query'` instead. */ + type ShowCallsStatusMutateAsync, + /** @deprecated This is no longer experimental – use `import type { ShowCallsStatusVariables } from '@wagmi/core/query'` instead. */ + type ShowCallsStatusVariables, + /** @deprecated This is no longer experimental – use `import { showCallsStatusMutationOptions } from '@wagmi/core/query'` instead. */ + showCallsStatusMutationOptions, +} from '../query/showCallsStatus.js' + +export { + /** @deprecated This is no longer experimental – use `import type { WaitForCallsStatusData } from '@wagmi/core/query'` instead. */ + type WaitForCallsStatusData, + /** @deprecated This is no longer experimental – use `import type { WaitForCallsStatusOptions } from '@wagmi/core/query'` instead. */ + type WaitForCallsStatusOptions, + /** @deprecated This is no longer experimental – use `import type { WaitForCallsStatusQueryFnData } from '@wagmi/core/query'` instead. */ + type WaitForCallsStatusQueryFnData, + /** @deprecated This is no longer experimental – use `import type { WaitForCallsStatusQueryKey } from '@wagmi/core/query'` instead. */ + type WaitForCallsStatusQueryKey, + /** @deprecated This is no longer experimental – use `import { waitForCallsStatusQueryKey } from '@wagmi/core/query'` instead. */ + waitForCallsStatusQueryKey, + /** @deprecated This is no longer experimental – use `import { waitForCallsStatusQueryOptions } from '@wagmi/core/query'` instead. */ + waitForCallsStatusQueryOptions, +} from '../query/waitForCallsStatus.js' + +export { + /** @deprecated Use `SendCallsData` instead. */ + type WriteContractsData, + /** @deprecated Use `SendCallsMutate` instead. */ + type WriteContractsMutate, + /** @deprecated Use `SendCallsMutateAsync` instead. */ + type WriteContractsMutateAsync, + /** @deprecated Use `SendCallsVariables` instead. */ + type WriteContractsVariables, + /** @deprecated Use `sendCallsMutationOptions` instead. */ + writeContractsMutationOptions, +} from '../experimental/query/writeContracts.js' diff --git a/packages/core/src/exports/index.test.ts b/packages/core/src/exports/index.test.ts new file mode 100644 index 0000000000..55f3885806 --- /dev/null +++ b/packages/core/src/exports/index.test.ts @@ -0,0 +1,117 @@ +import { expect, test } from 'vitest' + +import * as core from './index.js' + +test('exports', () => { + expect(Object.keys(core)).toMatchInlineSnapshot(` + [ + "call", + "connect", + "deployContract", + "disconnect", + "estimateGas", + "estimateFeesPerGas", + "estimateMaxPriorityFeePerGas", + "getAccount", + "getBalance", + "fetchBalance", + "getBlock", + "getBlockNumber", + "fetchBlockNumber", + "getBlockTransactionCount", + "getBytecode", + "getCallsStatus", + "getCapabilities", + "getChainId", + "getChains", + "getClient", + "getConnections", + "getConnectors", + "getConnectorClient", + "getEnsAddress", + "fetchEnsAddress", + "getEnsAvatar", + "fetchEnsAvatar", + "getEnsName", + "fetchEnsName", + "getEnsResolver", + "fetchEnsResolver", + "getEnsText", + "getFeeHistory", + "getGasPrice", + "getProof", + "getPublicClient", + "getStorageAt", + "getToken", + "fetchToken", + "getTransaction", + "fetchTransaction", + "getTransactionConfirmations", + "getTransactionCount", + "getTransactionReceipt", + "getWalletClient", + "multicall", + "prepareTransactionRequest", + "readContract", + "readContracts", + "reconnect", + "sendCalls", + "sendTransaction", + "showCallsStatus", + "signMessage", + "signTypedData", + "simulateContract", + "switchAccount", + "switchChain", + "switchNetwork", + "verifyMessage", + "verifyTypedData", + "waitForCallsStatus", + "watchAccount", + "watchAsset", + "watchBlocks", + "watchBlockNumber", + "watchChainId", + "watchClient", + "watchConnections", + "watchConnectors", + "watchContractEvent", + "watchPendingTransactions", + "watchPublicClient", + "waitForTransactionReceipt", + "waitForTransaction", + "writeContract", + "createConnector", + "injected", + "mock", + "createConfig", + "createStorage", + "noopStorage", + "hydrate", + "BaseError", + "ChainNotConfiguredError", + "ConnectorNotConnectedError", + "ConnectorAlreadyConnectedError", + "ConnectorNotFoundError", + "ConnectorAccountNotFoundError", + "ConnectorChainMismatchError", + "ConnectorUnavailableReconnectingError", + "ProviderNotFoundError", + "SwitchChainNotSupportedError", + "custom", + "http", + "webSocket", + "unstable_connector", + "fallback", + "cookieStorage", + "cookieToInitialState", + "parseCookie", + "deepEqual", + "deserialize", + "extractRpcUrls", + "normalizeChainId", + "serialize", + "version", + ] + `) +}) diff --git a/packages/core/src/exports/index.ts b/packages/core/src/exports/index.ts new file mode 100644 index 0000000000..1e0e210ea2 --- /dev/null +++ b/packages/core/src/exports/index.ts @@ -0,0 +1,594 @@ +//////////////////////////////////////////////////////////////////////////////// +// Actions +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { + type CallErrorType, + type CallParameters, + type CallReturnType, + call, +} from '../actions/call.js' + +export { + type ConnectErrorType, + type ConnectParameters, + type ConnectReturnType, + connect, +} from '../actions/connect.js' + +export { + type DeployContractErrorType, + type DeployContractParameters, + type DeployContractReturnType, + deployContract, +} from '../actions/deployContract.js' + +export { + type DisconnectErrorType, + type DisconnectParameters, + type DisconnectReturnType, + disconnect, +} from '../actions/disconnect.js' + +export { + type EstimateGasErrorType, + type EstimateGasParameters, + type EstimateGasReturnType, + estimateGas, +} from '../actions/estimateGas.js' + +export { + type EstimateFeesPerGasErrorType, + type EstimateFeesPerGasParameters, + type EstimateFeesPerGasReturnType, + estimateFeesPerGas, +} from '../actions/estimateFeesPerGas.js' + +export { + type EstimateMaxPriorityFeePerGasErrorType, + type EstimateMaxPriorityFeePerGasParameters, + type EstimateMaxPriorityFeePerGasReturnType, + estimateMaxPriorityFeePerGas, +} from '../actions/estimateMaxPriorityFeePerGas.js' + +export { + type GetAccountReturnType, + getAccount, +} from '../actions/getAccount.js' + +export { + type GetBalanceParameters, + type GetBalanceReturnType, + type GetBalanceErrorType, + getBalance, + /** @deprecated use `getBalance` instead */ + getBalance as fetchBalance, +} from '../actions/getBalance.js' + +export { + type GetBlockErrorType, + type GetBlockParameters, + type GetBlockReturnType, + getBlock, +} from '../actions/getBlock.js' + +export { + type GetBlockNumberErrorType, + type GetBlockNumberParameters, + type GetBlockNumberReturnType, + getBlockNumber, + /** @deprecated use `getBlockNumber` instead */ + getBlockNumber as fetchBlockNumber, +} from '../actions/getBlockNumber.js' + +export { + type GetBlockTransactionCountErrorType, + type GetBlockTransactionCountParameters, + type GetBlockTransactionCountReturnType, + getBlockTransactionCount, +} from '../actions/getBlockTransactionCount.js' + +export { + type GetBytecodeErrorType, + type GetBytecodeParameters, + type GetBytecodeReturnType, + getBytecode, +} from '../actions/getBytecode.js' + +export { + type GetCallsStatusErrorType, + type GetCallsStatusParameters, + type GetCallsStatusReturnType, + getCallsStatus, +} from '../actions/getCallsStatus.js' + +export { + type GetCapabilitiesErrorType, + type GetCapabilitiesParameters, + type GetCapabilitiesReturnType, + getCapabilities, +} from '../actions/getCapabilities.js' + +export { + type GetChainIdReturnType, + getChainId, +} from '../actions/getChainId.js' + +export { + type GetChainsReturnType, + getChains, +} from '../actions/getChains.js' + +export { + type GetClientParameters, + type GetClientReturnType, + getClient, +} from '../actions/getClient.js' + +export { + type GetConnectionsReturnType, + getConnections, +} from '../actions/getConnections.js' + +export { + type GetConnectorsReturnType, + getConnectors, +} from '../actions/getConnectors.js' + +export { + type GetConnectorClientErrorType, + type GetConnectorClientParameters, + type GetConnectorClientReturnType, + getConnectorClient, +} from '../actions/getConnectorClient.js' + +export { + type GetEnsAddressErrorType, + type GetEnsAddressParameters, + type GetEnsAddressReturnType, + getEnsAddress, + /** @deprecated use `getEnsAddress` instead */ + getEnsAddress as fetchEnsAddress, +} from '../actions/getEnsAddress.js' + +export { + type GetEnsAvatarErrorType, + type GetEnsAvatarParameters, + type GetEnsAvatarReturnType, + getEnsAvatar, + /** @deprecated use `getEnsAvatar` instead */ + getEnsAvatar as fetchEnsAvatar, +} from '../actions/getEnsAvatar.js' + +export { + type GetEnsNameErrorType, + type GetEnsNameParameters, + type GetEnsNameReturnType, + getEnsName, + /** @deprecated */ + getEnsName as fetchEnsName, +} from '../actions/getEnsName.js' + +export { + type GetEnsResolverErrorType, + type GetEnsResolverParameters, + type GetEnsResolverReturnType, + getEnsResolver, + /** @deprecated use `getEnsResolver` instead */ + getEnsResolver as fetchEnsResolver, +} from '../actions/getEnsResolver.js' + +export { + type GetEnsTextErrorType, + type GetEnsTextParameters, + type GetEnsTextReturnType, + getEnsText, +} from '../actions/getEnsText.js' + +export { + type GetFeeHistoryErrorType, + type GetFeeHistoryParameters, + type GetFeeHistoryReturnType, + getFeeHistory, +} from '../actions/getFeeHistory.js' + +export { + type GetGasPriceErrorType, + type GetGasPriceParameters, + type GetGasPriceReturnType, + getGasPrice, +} from '../actions/getGasPrice.js' + +export { + type GetProofErrorType, + type GetProofParameters, + type GetProofReturnType, + getProof, +} from '../actions/getProof.js' + +export { + type GetPublicClientParameters, + type GetPublicClientReturnType, + getPublicClient, +} from '../actions/getPublicClient.js' + +export { + type GetStorageAtErrorType, + type GetStorageAtParameters, + type GetStorageAtReturnType, + getStorageAt, +} from '../actions/getStorageAt.js' + +export { + type GetTokenErrorType, + type GetTokenParameters, + type GetTokenReturnType, + getToken, + /** @deprecated use `getToken` instead */ + getToken as fetchToken, +} from '../actions/getToken.js' + +export { + type GetTransactionErrorType, + type GetTransactionParameters, + type GetTransactionReturnType, + getTransaction, + /** @deprecated use `getTransaction` instead */ + getTransaction as fetchTransaction, +} from '../actions/getTransaction.js' + +export { + type GetTransactionConfirmationsErrorType, + type GetTransactionConfirmationsParameters, + type GetTransactionConfirmationsReturnType, + getTransactionConfirmations, +} from '../actions/getTransactionConfirmations.js' + +export { + type GetTransactionCountErrorType, + type GetTransactionCountParameters, + type GetTransactionCountReturnType, + getTransactionCount, +} from '../actions/getTransactionCount.js' + +export { + type GetTransactionReceiptErrorType, + type GetTransactionReceiptParameters, + type GetTransactionReceiptReturnType, + getTransactionReceipt, +} from '../actions/getTransactionReceipt.js' + +export { + type GetWalletClientErrorType, + type GetWalletClientParameters, + type GetWalletClientReturnType, + getWalletClient, +} from '../actions/getWalletClient.js' + +export { + type MulticallParameters, + type MulticallReturnType, + multicall, +} from '../actions/multicall.js' + +export { + type PrepareTransactionRequestErrorType, + type PrepareTransactionRequestParameters, + type PrepareTransactionRequestReturnType, + prepareTransactionRequest, +} from '../actions/prepareTransactionRequest.js' + +export { + type ReadContractParameters, + type ReadContractReturnType, + type ReadContractErrorType, + readContract, +} from '../actions/readContract.js' + +export { + type ReadContractsParameters, + type ReadContractsReturnType, + type ReadContractsErrorType, + readContracts, +} from '../actions/readContracts.js' + +export { + type ReconnectErrorType, + type ReconnectParameters, + type ReconnectReturnType, + reconnect, +} from '../actions/reconnect.js' + +export { + type SendCallsErrorType, + type SendCallsParameters, + type SendCallsReturnType, + sendCalls, +} from '../actions/sendCalls.js' + +export { + type SendTransactionErrorType, + type SendTransactionParameters, + type SendTransactionReturnType, + sendTransaction, +} from '../actions/sendTransaction.js' + +export { + type ShowCallsStatusErrorType, + type ShowCallsStatusParameters, + type ShowCallsStatusReturnType, + showCallsStatus, +} from '../actions/showCallsStatus.js' + +export { + type SignMessageErrorType, + type SignMessageParameters, + type SignMessageReturnType, + signMessage, +} from '../actions/signMessage.js' + +export { + type SignTypedDataErrorType, + type SignTypedDataParameters, + type SignTypedDataReturnType, + signTypedData, +} from '../actions/signTypedData.js' + +export { + type SimulateContractErrorType, + type SimulateContractParameters, + type SimulateContractReturnType, + simulateContract, +} from '../actions/simulateContract.js' + +export { + type SwitchAccountErrorType, + type SwitchAccountParameters, + type SwitchAccountReturnType, + switchAccount, +} from '../actions/switchAccount.js' + +export { + type SwitchChainErrorType, + type SwitchChainParameters, + type SwitchChainReturnType, + switchChain, + /** @deprecated use `switchChain` instead */ + switchChain as switchNetwork, +} from '../actions/switchChain.js' + +export { + type VerifyMessageErrorType, + type VerifyMessageParameters, + type VerifyMessageReturnType, + verifyMessage, +} from '../actions/verifyMessage.js' + +export { + type VerifyTypedDataErrorType, + type VerifyTypedDataParameters, + type VerifyTypedDataReturnType, + verifyTypedData, +} from '../actions/verifyTypedData.js' + +export { + type WaitForCallsStatusErrorType, + type WaitForCallsStatusParameters, + type WaitForCallsStatusReturnType, + waitForCallsStatus, +} from '../actions/waitForCallsStatus.js' + +export { + type WatchAccountParameters, + type WatchAccountReturnType, + watchAccount, +} from '../actions/watchAccount.js' + +export { + type WatchAssetParameters, + type WatchAssetErrorType, + type WatchAssetReturnType, + watchAsset, +} from '../actions/watchAsset.js' + +export { + type WatchBlocksParameters, + type WatchBlocksReturnType, + watchBlocks, +} from '../actions/watchBlocks.js' + +export { + type WatchBlockNumberParameters, + type WatchBlockNumberReturnType, + watchBlockNumber, +} from '../actions/watchBlockNumber.js' + +export { + type WatchChainIdParameters, + type WatchChainIdReturnType, + watchChainId, +} from '../actions/watchChainId.js' + +export { + type WatchClientParameters, + type WatchClientReturnType, + watchClient, +} from '../actions/watchClient.js' + +export { + type WatchConnectionsParameters, + type WatchConnectionsReturnType, + watchConnections, +} from '../actions/watchConnections.js' + +export { + type WatchConnectorsParameters, + type WatchConnectorsReturnType, + watchConnectors, +} from '../actions/watchConnectors.js' + +export { + type WatchContractEventParameters, + type WatchContractEventReturnType, + watchContractEvent, +} from '../actions/watchContractEvent.js' + +export { + type WatchPendingTransactionsParameters, + type WatchPendingTransactionsReturnType, + watchPendingTransactions, +} from '../actions/watchPendingTransactions.js' + +export { + type WatchPublicClientParameters, + type WatchPublicClientReturnType, + watchPublicClient, +} from '../actions/watchPublicClient.js' + +export { + type WaitForTransactionReceiptErrorType, + type WaitForTransactionReceiptParameters, + type WaitForTransactionReceiptReturnType, + waitForTransactionReceipt, + /** @deprecated use `waitForTransactionReceipt` instead */ + waitForTransactionReceipt as waitForTransaction, +} from '../actions/waitForTransactionReceipt.js' + +export { + type WriteContractErrorType, + type WriteContractParameters, + type WriteContractReturnType, + writeContract, +} from '../actions/writeContract.js' + +//////////////////////////////////////////////////////////////////////////////// +// Connectors +//////////////////////////////////////////////////////////////////////////////// + +export { + type ConnectorEventMap, + type CreateConnectorFn, + createConnector, +} from '../connectors/createConnector.js' + +export { + type InjectedParameters, + injected, +} from '../connectors/injected.js' + +export { + type MockParameters, + mock, +} from '../connectors/mock.js' + +//////////////////////////////////////////////////////////////////////////////// +// createConfig +//////////////////////////////////////////////////////////////////////////////// + +export { + type Connection, + type Connector, + type Config, + type CreateConfigParameters, + type PartializedState, + type State, + type Transport, + createConfig, +} from '../createConfig.js' + +//////////////////////////////////////////////////////////////////////////////// +// createStorage +//////////////////////////////////////////////////////////////////////////////// + +export { + type CreateStorageParameters, + type Storage, + type StorageItemMap, + createStorage, + noopStorage, +} from '../createStorage.js' + +//////////////////////////////////////////////////////////////////////////////// +// Hydrate +//////////////////////////////////////////////////////////////////////////////// + +export { hydrate } from '../hydrate.js' + +//////////////////////////////////////////////////////////////////////////////// +// Errors +//////////////////////////////////////////////////////////////////////////////// + +export { BaseError } from '../errors/base.js' + +export { + type ChainNotConfiguredErrorType, + ChainNotConfiguredError, + type ConnectorNotConnectedErrorType, + ConnectorNotConnectedError, + type ConnectorAlreadyConnectedErrorType, + ConnectorAlreadyConnectedError, + type ConnectorNotFoundErrorType, + ConnectorNotFoundError, + type ConnectorAccountNotFoundErrorType, + ConnectorAccountNotFoundError, + type ConnectorChainMismatchErrorType, + ConnectorChainMismatchError, + type ConnectorUnavailableReconnectingErrorType, + ConnectorUnavailableReconnectingError, +} from '../errors/config.js' + +export { + type ProviderNotFoundErrorType, + ProviderNotFoundError, + type SwitchChainNotSupportedErrorType, + SwitchChainNotSupportedError, +} from '../errors/connector.js' + +//////////////////////////////////////////////////////////////////////////////// +// Transports +//////////////////////////////////////////////////////////////////////////////// + +export { custom, http, webSocket } from 'viem' + +export { + type ConnectorTransportConfig, + type ConnectorTransport, + unstable_connector, +} from '../transports/connector.js' + +export { fallback } from '../transports/fallback.js' + +//////////////////////////////////////////////////////////////////////////////// +// Types +//////////////////////////////////////////////////////////////////////////////// + +export type { SelectChains } from '../types/chain.js' + +export type { Register, ResolvedRegister } from '../types/register.js' + +//////////////////////////////////////////////////////////////////////////////// +// Utilities +//////////////////////////////////////////////////////////////////////////////// + +export { + cookieStorage, + cookieToInitialState, + parseCookie, +} from '../utils/cookie.js' + +export { deepEqual } from '../utils/deepEqual.js' + +export { deserialize } from '../utils/deserialize.js' + +export { extractRpcUrls } from '../utils/extractRpcUrls.js' + +export { normalizeChainId } from '../utils/normalizeChainId.js' + +export { serialize } from '../utils/serialize.js' + +//////////////////////////////////////////////////////////////////////////////// +// Version +//////////////////////////////////////////////////////////////////////////////// + +export { version } from '../version.js' diff --git a/packages/core/src/exports/internal.test.ts b/packages/core/src/exports/internal.test.ts new file mode 100644 index 0000000000..425a1b4eba --- /dev/null +++ b/packages/core/src/exports/internal.test.ts @@ -0,0 +1,15 @@ +import { expect, test } from 'vitest' + +import * as internal from './internal.js' + +test('exports', () => { + expect(Object.keys(internal)).toMatchInlineSnapshot(` + [ + "watchChains", + "Emitter", + "createEmitter", + "deepEqual", + "uid", + ] + `) +}) diff --git a/packages/core/src/exports/internal.ts b/packages/core/src/exports/internal.ts new file mode 100644 index 0000000000..670420d89a --- /dev/null +++ b/packages/core/src/exports/internal.ts @@ -0,0 +1,52 @@ +//////////////////////////////////////////////////////////////////////////////// +// Actions +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { + type WatchChainsParameters, + type WatchChainsReturnType, + watchChains, +} from '../actions/watchChains.js' + +//////////////////////////////////////////////////////////////////////////////// +// Emitter +//////////////////////////////////////////////////////////////////////////////// + +export { + type EventData, + Emitter, + createEmitter, +} from '../createEmitter.js' + +//////////////////////////////////////////////////////////////////////////////// +// Types +//////////////////////////////////////////////////////////////////////////////// + +export type { SelectChains } from '../types/chain.js' + +export type { + ChainIdParameter, + ConnectorParameter, + ScopeKeyParameter, +} from '../types/properties.js' + +export type { + Compute, + ExactPartial, + Mutable, + StrictOmit as Omit, + OneOf, + RemoveUndefined, + UnionCompute, + UnionStrictOmit, + UnionExactPartial, +} from '../types/utils.js' + +//////////////////////////////////////////////////////////////////////////////// +// Utilities +//////////////////////////////////////////////////////////////////////////////// + +export { deepEqual } from '../utils/deepEqual.js' + +export { uid } from '../utils/uid.js' diff --git a/packages/core/src/exports/query.test.ts b/packages/core/src/exports/query.test.ts new file mode 100644 index 0000000000..cbdaf925de --- /dev/null +++ b/packages/core/src/exports/query.test.ts @@ -0,0 +1,97 @@ +import { expect, test } from 'vitest' + +import * as query from './query.js' + +test('exports', () => { + expect(Object.keys(query)).toMatchInlineSnapshot(` + [ + "callQueryKey", + "callQueryOptions", + "connectMutationOptions", + "deployContractMutationOptions", + "disconnectMutationOptions", + "estimateFeesPerGasQueryKey", + "estimateFeesPerGasQueryOptions", + "estimateGasQueryKey", + "estimateGasQueryOptions", + "estimateMaxPriorityFeePerGasQueryKey", + "estimateMaxPriorityFeePerGasQueryOptions", + "getBalanceQueryKey", + "getBalanceQueryOptions", + "getBlockQueryKey", + "getBlockQueryOptions", + "getBlockNumberQueryKey", + "getBlockNumberQueryOptions", + "getBlockTransactionCountQueryKey", + "getBlockTransactionCountQueryOptions", + "getBytecodeQueryKey", + "getBytecodeQueryOptions", + "getCallsStatusQueryKey", + "getCallsStatusQueryOptions", + "getCapabilitiesQueryKey", + "getCapabilitiesQueryOptions", + "getConnectorClientQueryKey", + "getConnectorClientQueryOptions", + "getEnsAddressQueryKey", + "getEnsAddressQueryOptions", + "getEnsAvatarQueryKey", + "getEnsAvatarQueryOptions", + "getEnsNameQueryKey", + "getEnsNameQueryOptions", + "getEnsResolverQueryKey", + "getEnsResolverQueryOptions", + "getEnsTextQueryKey", + "getEnsTextQueryOptions", + "getFeeHistoryQueryKey", + "getFeeHistoryQueryOptions", + "getGasPriceQueryKey", + "getGasPriceQueryOptions", + "getProofQueryKey", + "getProofQueryOptions", + "getStorageAtQueryKey", + "getStorageAtQueryOptions", + "getTokenQueryKey", + "getTokenQueryOptions", + "getTransactionQueryKey", + "getTransactionQueryOptions", + "getTransactionConfirmationsQueryKey", + "getTransactionConfirmationsQueryOptions", + "getTransactionCountQueryKey", + "getTransactionCountQueryOptions", + "getTransactionReceiptQueryKey", + "getTransactionReceiptQueryOptions", + "getWalletClientQueryKey", + "getWalletClientQueryOptions", + "infiniteReadContractsQueryKey", + "infiniteReadContractsQueryOptions", + "prepareTransactionRequestQueryKey", + "prepareTransactionRequestQueryOptions", + "readContractQueryKey", + "readContractQueryOptions", + "readContractsQueryKey", + "readContractsQueryOptions", + "reconnectMutationOptions", + "sendCallsMutationOptions", + "showCallsStatusMutationOptions", + "sendTransactionMutationOptions", + "signMessageMutationOptions", + "signTypedDataMutationOptions", + "switchAccountMutationOptions", + "simulateContractQueryKey", + "simulateContractQueryOptions", + "switchChainMutationOptions", + "verifyMessageQueryKey", + "verifyMessageQueryOptions", + "verifyTypedDataQueryKey", + "verifyTypedDataQueryOptions", + "waitForCallsStatusQueryKey", + "waitForCallsStatusQueryOptions", + "waitForTransactionReceiptQueryKey", + "waitForTransactionReceiptQueryOptions", + "watchAssetMutationOptions", + "writeContractMutationOptions", + "hashFn", + "structuralSharing", + ] + `) +}) diff --git a/packages/core/src/exports/query.ts b/packages/core/src/exports/query.ts new file mode 100644 index 0000000000..d689f558d5 --- /dev/null +++ b/packages/core/src/exports/query.ts @@ -0,0 +1,434 @@ +//////////////////////////////////////////////////////////////////////////////// +// Tanstack Query +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { + type CallData, + type CallOptions, + type CallQueryFnData, + type CallQueryKey, + callQueryKey, + callQueryOptions, +} from '../query/call.js' + +export { + type ConnectData, + type ConnectVariables, + type ConnectMutate, + type ConnectMutateAsync, + connectMutationOptions, +} from '../query/connect.js' + +export { + type DeployContractData, + type DeployContractVariables, + type DeployContractMutate, + type DeployContractMutateAsync, + deployContractMutationOptions, +} from '../query/deployContract.js' + +export { + type DisconnectData, + type DisconnectVariables, + type DisconnectMutate, + type DisconnectMutateAsync, + disconnectMutationOptions, +} from '../query/disconnect.js' + +export { + type EstimateFeesPerGasData, + type EstimateFeesPerGasOptions, + type EstimateFeesPerGasQueryFnData, + type EstimateFeesPerGasQueryKey, + estimateFeesPerGasQueryKey, + estimateFeesPerGasQueryOptions, +} from '../query/estimateFeesPerGas.js' + +export { + type EstimateGasData, + type EstimateGasOptions, + type EstimateGasQueryFnData, + type EstimateGasQueryKey, + estimateGasQueryKey, + estimateGasQueryOptions, +} from '../query/estimateGas.js' + +export { + type EstimateMaxPriorityFeePerGasData, + type EstimateMaxPriorityFeePerGasOptions, + type EstimateMaxPriorityFeePerGasQueryFnData, + type EstimateMaxPriorityFeePerGasQueryKey, + estimateMaxPriorityFeePerGasQueryKey, + estimateMaxPriorityFeePerGasQueryOptions, +} from '../query/estimateMaxPriorityFeePerGas.js' + +export { + type GetBalanceData, + type GetBalanceOptions, + type GetBalanceQueryFnData, + type GetBalanceQueryKey, + getBalanceQueryKey, + getBalanceQueryOptions, +} from '../query/getBalance.js' + +export { + type GetBlockData, + type GetBlockOptions, + type GetBlockQueryFnData, + type GetBlockQueryKey, + getBlockQueryKey, + getBlockQueryOptions, +} from '../query/getBlock.js' + +export { + type GetBlockNumberData, + type GetBlockNumberOptions, + type GetBlockNumberQueryFnData, + type GetBlockNumberQueryKey, + getBlockNumberQueryKey, + getBlockNumberQueryOptions, +} from '../query/getBlockNumber.js' + +export { + type GetBlockTransactionCountData, + type GetBlockTransactionCountOptions, + type GetBlockTransactionCountQueryFnData, + type GetBlockTransactionCountQueryKey, + getBlockTransactionCountQueryKey, + getBlockTransactionCountQueryOptions, +} from '../query/getBlockTransactionCount.js' + +export { + type GetBytecodeData, + type GetBytecodeOptions, + type GetBytecodeQueryFnData, + type GetBytecodeQueryKey, + getBytecodeQueryKey, + getBytecodeQueryOptions, +} from '../query/getBytecode.js' + +export { + type GetCallsStatusData, + type GetCallsStatusOptions, + type GetCallsStatusQueryFnData, + type GetCallsStatusQueryKey, + getCallsStatusQueryKey, + getCallsStatusQueryOptions, +} from '../query/getCallsStatus.js' + +export { + type GetCapabilitiesData, + type GetCapabilitiesOptions, + type GetCapabilitiesQueryFnData, + type GetCapabilitiesQueryKey, + getCapabilitiesQueryKey, + getCapabilitiesQueryOptions, +} from '../query/getCapabilities.js' + +export { + type GetConnectorClientData, + type GetConnectorClientOptions, + type GetConnectorClientQueryFnData, + type GetConnectorClientQueryKey, + getConnectorClientQueryKey, + getConnectorClientQueryOptions, +} from '../query/getConnectorClient.js' + +export { + type GetEnsAddressData, + type GetEnsAddressOptions, + type GetEnsAddressQueryFnData, + type GetEnsAddressQueryKey, + getEnsAddressQueryKey, + getEnsAddressQueryOptions, +} from '../query/getEnsAddress.js' + +export { + type GetEnsAvatarData, + type GetEnsAvatarOptions, + type GetEnsAvatarQueryFnData, + type GetEnsAvatarQueryKey, + getEnsAvatarQueryKey, + getEnsAvatarQueryOptions, +} from '../query/getEnsAvatar.js' + +export { + type GetEnsNameData, + type GetEnsNameOptions, + type GetEnsNameQueryFnData, + type GetEnsNameQueryKey, + getEnsNameQueryKey, + getEnsNameQueryOptions, +} from '../query/getEnsName.js' + +export { + type GetEnsResolverData, + type GetEnsResolverOptions, + type GetEnsResolverQueryFnData, + type GetEnsResolverQueryKey, + getEnsResolverQueryKey, + getEnsResolverQueryOptions, +} from '../query/getEnsResolver.js' + +export { + type GetEnsTextData, + type GetEnsTextOptions, + type GetEnsTextQueryFnData, + type GetEnsTextQueryKey, + getEnsTextQueryKey, + getEnsTextQueryOptions, +} from '../query/getEnsText.js' + +export { + type GetFeeHistoryData, + type GetFeeHistoryOptions, + type GetFeeHistoryQueryFnData, + type GetFeeHistoryQueryKey, + getFeeHistoryQueryKey, + getFeeHistoryQueryOptions, +} from '../query/getFeeHistory.js' + +export { + type GetGasPriceData, + type GetGasPriceOptions, + type GetGasPriceQueryFnData, + type GetGasPriceQueryKey, + getGasPriceQueryKey, + getGasPriceQueryOptions, +} from '../query/getGasPrice.js' + +export { + type GetProofData, + type GetProofOptions, + type GetProofQueryFnData, + type GetProofQueryKey, + getProofQueryKey, + getProofQueryOptions, +} from '../query/getProof.js' + +export { + type GetStorageAtData, + type GetStorageAtOptions, + type GetStorageAtQueryFnData, + type GetStorageAtQueryKey, + getStorageAtQueryKey, + getStorageAtQueryOptions, +} from '../query/getStorageAt.js' + +export { + type GetTokenData, + type GetTokenOptions, + type GetTokenQueryFnData, + type GetTokenQueryKey, + getTokenQueryKey, + getTokenQueryOptions, +} from '../query/getToken.js' + +export { + type GetTransactionData, + type GetTransactionOptions, + type GetTransactionQueryFnData, + type GetTransactionQueryKey, + getTransactionQueryKey, + getTransactionQueryOptions, +} from '../query/getTransaction.js' + +export { + type GetTransactionConfirmationsData, + type GetTransactionConfirmationsOptions, + type GetTransactionConfirmationsQueryFnData, + type GetTransactionConfirmationsQueryKey, + getTransactionConfirmationsQueryKey, + getTransactionConfirmationsQueryOptions, +} from '../query/getTransactionConfirmations.js' + +export { + type GetTransactionCountData, + type GetTransactionCountOptions, + type GetTransactionCountQueryFnData, + type GetTransactionCountQueryKey, + getTransactionCountQueryKey, + getTransactionCountQueryOptions, +} from '../query/getTransactionCount.js' + +export { + type GetTransactionReceiptData, + type GetTransactionReceiptOptions, + type GetTransactionReceiptQueryFnData, + type GetTransactionReceiptQueryKey, + getTransactionReceiptQueryKey, + getTransactionReceiptQueryOptions, +} from '../query/getTransactionReceipt.js' + +export { + type GetWalletClientData, + type GetWalletClientOptions, + type GetWalletClientQueryFnData, + type GetWalletClientQueryKey, + getWalletClientQueryKey, + getWalletClientQueryOptions, +} from '../query/getWalletClient.js' + +export { + type InfiniteReadContractsData, + type InfiniteReadContractsOptions, + type InfiniteReadContractsQueryFnData, + type InfiniteReadContractsQueryKey, + infiniteReadContractsQueryKey, + infiniteReadContractsQueryOptions, +} from '../query/infiniteReadContracts.js' + +export { + type PrepareTransactionRequestData, + type PrepareTransactionRequestOptions, + type PrepareTransactionRequestQueryFnData, + type PrepareTransactionRequestQueryKey, + prepareTransactionRequestQueryKey, + prepareTransactionRequestQueryOptions, +} from '../query/prepareTransactionRequest.js' + +export { + type ReadContractData, + type ReadContractOptions, + type ReadContractQueryFnData, + type ReadContractQueryKey, + readContractQueryKey, + readContractQueryOptions, +} from '../query/readContract.js' + +export { + type ReadContractsData, + type ReadContractsOptions, + type ReadContractsQueryFnData, + type ReadContractsQueryKey, + readContractsQueryKey, + readContractsQueryOptions, +} from '../query/readContracts.js' + +export { + type ReconnectData, + type ReconnectVariables, + type ReconnectMutate, + type ReconnectMutateAsync, + reconnectMutationOptions, +} from '../query/reconnect.js' + +export { + type SendCallsData, + type SendCallsVariables, + type SendCallsMutate, + type SendCallsMutateAsync, + sendCallsMutationOptions, +} from '../query/sendCalls.js' + +export { + type ShowCallsStatusData, + type ShowCallsStatusVariables, + type ShowCallsStatusMutate, + type ShowCallsStatusMutateAsync, + showCallsStatusMutationOptions, +} from '../query/showCallsStatus.js' + +export { + type SendTransactionData, + type SendTransactionVariables, + type SendTransactionMutate, + type SendTransactionMutateAsync, + sendTransactionMutationOptions, +} from '../query/sendTransaction.js' + +export { + type SignMessageData, + type SignMessageVariables, + type SignMessageMutate, + type SignMessageMutateAsync, + signMessageMutationOptions, +} from '../query/signMessage.js' + +export { + type SignTypedDataData, + type SignTypedDataVariables, + type SignTypedDataMutate, + type SignTypedDataMutateAsync, + signTypedDataMutationOptions, +} from '../query/signTypedData.js' + +export { + type SwitchAccountData, + type SwitchAccountVariables, + type SwitchAccountMutate, + type SwitchAccountMutateAsync, + switchAccountMutationOptions, +} from '../query/switchAccount.js' + +export { + type SimulateContractData, + type SimulateContractOptions, + type SimulateContractQueryFnData, + type SimulateContractQueryKey, + simulateContractQueryKey, + simulateContractQueryOptions, +} from '../query/simulateContract.js' + +export { + type SwitchChainData, + type SwitchChainVariables, + type SwitchChainMutate, + type SwitchChainMutateAsync, + switchChainMutationOptions, +} from '../query/switchChain.js' + +export { + type VerifyMessageData, + type VerifyMessageOptions, + type VerifyMessageQueryFnData, + type VerifyMessageQueryKey, + verifyMessageQueryKey, + verifyMessageQueryOptions, +} from '../query/verifyMessage.js' + +export { + type VerifyTypedDataData, + type VerifyTypedDataOptions, + type VerifyTypedDataQueryFnData, + type VerifyTypedDataQueryKey, + verifyTypedDataQueryKey, + verifyTypedDataQueryOptions, +} from '../query/verifyTypedData.js' + +export { + type WaitForCallsStatusData, + type WaitForCallsStatusOptions, + type WaitForCallsStatusQueryFnData, + type WaitForCallsStatusQueryKey, + waitForCallsStatusQueryKey, + waitForCallsStatusQueryOptions, +} from '../query/waitForCallsStatus.js' + +export { + type WaitForTransactionReceiptData, + type WaitForTransactionReceiptOptions, + type WaitForTransactionReceiptQueryFnData, + type WaitForTransactionReceiptQueryKey, + waitForTransactionReceiptQueryKey, + waitForTransactionReceiptQueryOptions, +} from '../query/waitForTransactionReceipt.js' + +export { + type WatchAssetData, + type WatchAssetVariables, + type WatchAssetMutate, + type WatchAssetMutateAsync, + watchAssetMutationOptions, +} from '../query/watchAsset.js' + +export { + type WriteContractData, + type WriteContractVariables, + type WriteContractMutate, + type WriteContractMutateAsync, + writeContractMutationOptions, +} from '../query/writeContract.js' + +export { hashFn, structuralSharing } from '../query/utils.js' diff --git a/packages/core/src/hydrate.test.ts b/packages/core/src/hydrate.test.ts new file mode 100644 index 0000000000..3dc6e28549 --- /dev/null +++ b/packages/core/src/hydrate.test.ts @@ -0,0 +1,114 @@ +import { accounts, config, wait } from '@wagmi/test' +import type { EIP1193Provider } from 'mipd' +import { http } from 'viem' +import { mainnet } from 'viem/chains' +import { expect, test, vi } from 'vitest' + +import { createConnector } from './connectors/createConnector.js' +import { mock } from './connectors/mock.js' +import { createConfig } from './createConfig.js' +import { createStorage } from './createStorage.js' +import { hydrate } from './hydrate.js' +import { cookieStorage } from './utils/cookie.js' + +vi.mock(import('mipd'), async (importOriginal) => { + const mod = await importOriginal() + + let cache: typeof mod | undefined + if (!cache) + cache = { + ...mod, + createStore() { + const store = mod.createStore() + return { + ...store, + getProviders() { + const info = { + icon: 'data:image/svg+xml,', + uuid: crypto.randomUUID(), + } as const + const provider = '' as unknown as EIP1193Provider + return [ + { info: { ...info, name: 'Foo', rdns: 'com.foo' }, provider }, + { info: { ...info, name: 'Bar', rdns: 'com.bar' }, provider }, + { info: { ...info, name: 'Mock', rdns: 'com.mock' }, provider }, + ] + }, + } + }, + } + return cache +}) + +test('default', () => { + const { onMount } = hydrate(config, { + initialState: undefined, + reconnectOnMount: false, + }) + onMount() + + expect(onMount).toBeDefined() +}) + +test('initialState', () => { + const config = createConfig({ + chains: [mainnet], + transports: { [mainnet.id]: http() }, + ssr: true, + storage: createStorage({ storage: cookieStorage }), + }) + + const { onMount } = hydrate(config, { + initialState: { + chainId: 1, + current: null, + connections: new Map(), + status: 'disconnected', + }, + reconnectOnMount: true, + }) + onMount() + + expect(onMount).toBeDefined() +}) + +test('ssr', async () => { + const config = createConfig({ + chains: [mainnet], + connectors: [ + createConnector((c) => { + return { + ...mock({ accounts })(c), + rdns: 'com.mock', + } + }), + ], + ssr: true, + storage: createStorage({ storage: cookieStorage }), + transports: { [mainnet.id]: http() }, + }) + + const { onMount } = hydrate(config, { + initialState: { + chainId: 10, + current: null, + connections: new Map(), + status: 'disconnected', + }, + reconnectOnMount: false, + }) + onMount() + expect(onMount).toBeDefined() + expect(config.chains[0].id).toBe(1) + + await wait(100) + expect(config.connectors.map((x) => x.rdns ?? x.id)).toMatchInlineSnapshot( + ` + [ + "com.mock", + "com.foo", + "com.bar", + ] + `, + ) +}) diff --git a/packages/core/src/hydrate.ts b/packages/core/src/hydrate.ts new file mode 100644 index 0000000000..70bc2199e6 --- /dev/null +++ b/packages/core/src/hydrate.ts @@ -0,0 +1,62 @@ +import { reconnect } from './actions/reconnect.js' +import type { Config, State } from './createConfig.js' + +type HydrateParameters = { + initialState?: State | undefined + reconnectOnMount?: boolean | undefined +} + +export function hydrate(config: Config, parameters: HydrateParameters) { + const { initialState, reconnectOnMount } = parameters + + if (initialState && !config._internal.store.persist.hasHydrated()) + config.setState({ + ...initialState, + chainId: config.chains.some((x) => x.id === initialState.chainId) + ? initialState.chainId + : config.chains[0].id, + connections: reconnectOnMount ? initialState.connections : new Map(), + status: reconnectOnMount ? 'reconnecting' : 'disconnected', + }) + + return { + async onMount() { + if (config._internal.ssr) { + await config._internal.store.persist.rehydrate() + if (config._internal.mipd) { + config._internal.connectors.setState((connectors) => { + const rdnsSet = new Set() + for (const connector of connectors ?? []) { + if (connector.rdns) { + const rdnsValues = Array.isArray(connector.rdns) + ? connector.rdns + : [connector.rdns] + for (const rdns of rdnsValues) { + rdnsSet.add(rdns) + } + } + } + const mipdConnectors = [] + const providers = config._internal.mipd?.getProviders() ?? [] + for (const provider of providers) { + if (rdnsSet.has(provider.info.rdns)) continue + const connectorFn = + config._internal.connectors.providerDetailToConnector(provider) + const connector = config._internal.connectors.setup(connectorFn) + mipdConnectors.push(connector) + } + return [...connectors, ...mipdConnectors] + }) + } + } + + if (reconnectOnMount) reconnect(config) + else if (config.storage) + // Reset connections that may have been hydrated from storage. + config.setState((x) => ({ + ...x, + connections: new Map(), + })) + }, + } +} diff --git a/packages/core/src/query/call.test.ts b/packages/core/src/query/call.test.ts new file mode 100644 index 0000000000..1e9ee03f7a --- /dev/null +++ b/packages/core/src/query/call.test.ts @@ -0,0 +1,306 @@ +import { accounts, address, chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { parseEther, parseGwei } from 'viem' +import { callQueryOptions } from './call.js' + +const name4bytes = '0x06fdde03' +const account = accounts[0] + +test('default', () => { + expect( + callQueryOptions(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "data": "0x06fdde03", + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + } + `) +}) + +test('parameters: accessList', () => { + expect( + callQueryOptions(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + accessList: [ + { + address: '0x1', + storageKeys: ['0x1'], + }, + ], + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "call", + { + "accessList": [ + { + "address": "0x1", + "storageKeys": [ + "0x1", + ], + }, + ], + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "data": "0x06fdde03", + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + } + `) +}) + +test('parameters: blockNumber', () => { + expect( + callQueryOptions(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + blockNumber: 1234567890n, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockNumber": 1234567890n, + "data": "0x06fdde03", + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + } + `) +}) + +test('parameters: blockTag', () => { + expect( + callQueryOptions(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + blockTag: 'safe', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockTag": "safe", + "data": "0x06fdde03", + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + callQueryOptions(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + chainId: chain.mainnet2.id, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 456, + "data": "0x06fdde03", + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + } + `) +}) + +test('parameters: gas', () => { + expect( + callQueryOptions(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + gas: 100000n, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "data": "0x06fdde03", + "gas": 100000n, + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + } + `) +}) + +test('parameters: gasPrice', () => { + expect( + callQueryOptions(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + gasPrice: parseGwei('20'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "data": "0x06fdde03", + "gasPrice": 20000000000n, + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + } + `) +}) + +test('parameters: maxFeePerGas', () => { + expect( + callQueryOptions(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + maxFeePerGas: parseGwei('20'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "data": "0x06fdde03", + "maxFeePerGas": 20000000000n, + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + } + `) +}) + +test('parameters: maxPriorityFeePerGas', () => { + expect( + callQueryOptions(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + maxPriorityFeePerGas: parseGwei('2'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "data": "0x06fdde03", + "maxPriorityFeePerGas": 2000000000n, + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + } + `) +}) + +test('parameters: nonce', () => { + expect( + callQueryOptions(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + nonce: 123, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "data": "0x06fdde03", + "nonce": 123, + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + } + `) +}) + +test('parameters: type', () => { + expect( + callQueryOptions(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + type: 'eip1559', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "data": "0x06fdde03", + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "type": "eip1559", + }, + ], + } + `) +}) + +test('parameters: value', () => { + expect( + callQueryOptions(config, { + account, + data: name4bytes, + to: address.wagmiMintExample, + value: parseEther('1'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "data": "0x06fdde03", + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "value": 1000000000000000000n, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/call.ts b/packages/core/src/query/call.ts new file mode 100644 index 0000000000..2ca4491b86 --- /dev/null +++ b/packages/core/src/query/call.ts @@ -0,0 +1,51 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type CallErrorType, + type CallParameters, + type CallReturnType, + call, +} from '../actions/call.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type CallOptions = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function callQueryOptions( + config: config, + options: CallOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { scopeKey: _, ...parameters } = queryKey[1] + const data = await call(config, { + ...parameters, + } as CallParameters) + return data ?? null + }, + queryKey: callQueryKey(options), + } as const satisfies QueryOptions< + CallQueryFnData, + CallErrorType, + CallData, + CallQueryKey + > +} + +export type CallQueryFnData = CallReturnType + +export type CallData = CallQueryFnData + +export function callQueryKey( + options: CallOptions, +) { + return ['call', filterQueryOptions(options)] as const +} + +export type CallQueryKey = ReturnType< + typeof callQueryKey +> diff --git a/packages/core/src/query/connect.test.ts b/packages/core/src/query/connect.test.ts new file mode 100644 index 0000000000..b8300ee0ee --- /dev/null +++ b/packages/core/src/query/connect.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { connectMutationOptions } from './connect.js' + +test('default', () => { + expect(connectMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "connect", + ], + } + `) +}) diff --git a/packages/core/src/query/connect.ts b/packages/core/src/query/connect.ts new file mode 100644 index 0000000000..f521512789 --- /dev/null +++ b/packages/core/src/query/connect.ts @@ -0,0 +1,70 @@ +import type { MutateOptions, MutationOptions } from '@tanstack/query-core' + +import { + type ConnectErrorType, + type ConnectParameters, + type ConnectReturnType, + connect, +} from '../actions/connect.js' +import type { Config, Connector } from '../createConfig.js' + +import type { CreateConnectorFn } from '../connectors/createConnector.js' +import type { Compute } from '../types/utils.js' + +export function connectMutationOptions(config: config) { + return { + mutationFn(variables) { + return connect(config, variables) + }, + mutationKey: ['connect'], + } as const satisfies MutationOptions< + ConnectData, + ConnectErrorType, + ConnectVariables + > +} + +export type ConnectData = ConnectReturnType + +export type ConnectVariables< + config extends Config, + connector extends Connector | CreateConnectorFn, +> = ConnectParameters + +export type ConnectMutate = < + connector extends + | config['connectors'][number] + | Connector + | CreateConnectorFn, +>( + variables: ConnectVariables, + options?: + | Compute< + MutateOptions< + ConnectData, + ConnectErrorType, + Compute>, + context + > + > + | undefined, +) => void + +export type ConnectMutateAsync = < + connector extends + | config['connectors'][number] + | Connector + | CreateConnectorFn, +>( + variables: ConnectVariables, + options?: + | Compute< + MutateOptions< + ConnectData, + ConnectErrorType, + Compute>, + context + > + > + | undefined, +) => Promise> diff --git a/packages/core/src/query/deployContract.test.ts b/packages/core/src/query/deployContract.test.ts new file mode 100644 index 0000000000..51157c03df --- /dev/null +++ b/packages/core/src/query/deployContract.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { deployContractMutationOptions } from './deployContract.js' + +test('default', () => { + expect(deployContractMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "deployContract", + ], + } + `) +}) diff --git a/packages/core/src/query/deployContract.ts b/packages/core/src/query/deployContract.ts new file mode 100644 index 0000000000..d4fac04531 --- /dev/null +++ b/packages/core/src/query/deployContract.ts @@ -0,0 +1,73 @@ +import type { MutateOptions, MutationOptions } from '@tanstack/query-core' +import type { Abi, ContractConstructorArgs } from 'viem' + +import { + type DeployContractErrorType, + type DeployContractParameters, + type DeployContractReturnType, + deployContract, +} from '../actions/deployContract.js' +import type { Config } from '../createConfig.js' +import type { Compute } from '../types/utils.js' + +export function deployContractMutationOptions( + config: config, +) { + return { + mutationFn(variables) { + return deployContract(config, variables) + }, + mutationKey: ['deployContract'], + } as const satisfies MutationOptions< + DeployContractData, + DeployContractErrorType, + DeployContractVariables + > +} + +export type DeployContractData = Compute + +export type DeployContractVariables< + abi extends Abi | readonly unknown[], + config extends Config, + chainId extends config['chains'][number]['id'], + /// + allArgs = ContractConstructorArgs, +> = DeployContractParameters + +export type DeployContractMutate = < + abi extends Abi | readonly unknown[], + chainId extends config['chains'][number]['id'], +>( + variables: DeployContractVariables, + options?: + | Compute< + MutateOptions< + DeployContractData, + DeployContractErrorType, + Compute>, + context + > + > + | undefined, +) => void + +export type DeployContractMutateAsync< + config extends Config, + context = unknown, +> = < + abi extends Abi | readonly unknown[], + chainId extends config['chains'][number]['id'], +>( + variables: DeployContractVariables, + options?: + | Compute< + MutateOptions< + DeployContractData, + DeployContractErrorType, + Compute>, + context + > + > + | undefined, +) => Promise diff --git a/packages/core/src/query/disconnect.test.ts b/packages/core/src/query/disconnect.test.ts new file mode 100644 index 0000000000..4637c7e88f --- /dev/null +++ b/packages/core/src/query/disconnect.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { disconnectMutationOptions } from './disconnect.js' + +test('default', () => { + expect(disconnectMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "disconnect", + ], + } + `) +}) diff --git a/packages/core/src/query/disconnect.ts b/packages/core/src/query/disconnect.ts new file mode 100644 index 0000000000..018873da03 --- /dev/null +++ b/packages/core/src/query/disconnect.ts @@ -0,0 +1,43 @@ +import type { MutationOptions } from '@tanstack/query-core' + +import { + type DisconnectErrorType, + type DisconnectParameters, + type DisconnectReturnType, + disconnect, +} from '../actions/disconnect.js' +import type { Config } from '../createConfig.js' +import type { Mutate, MutateAsync } from './types.js' + +export function disconnectMutationOptions( + config: config, +) { + return { + mutationFn(variables) { + return disconnect(config, variables) + }, + mutationKey: ['disconnect'], + } as const satisfies MutationOptions< + DisconnectData, + DisconnectErrorType, + DisconnectVariables + > +} + +export type DisconnectData = DisconnectReturnType + +export type DisconnectVariables = DisconnectParameters | undefined + +export type DisconnectMutate = Mutate< + DisconnectData, + DisconnectErrorType, + DisconnectVariables, + context +> + +export type DisconnectMutateAsync = MutateAsync< + DisconnectData, + DisconnectErrorType, + DisconnectVariables, + context +> diff --git a/packages/core/src/query/estimateFeesPerGas.test.ts b/packages/core/src/query/estimateFeesPerGas.test.ts new file mode 100644 index 0000000000..6b9965e651 --- /dev/null +++ b/packages/core/src/query/estimateFeesPerGas.test.ts @@ -0,0 +1,32 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { estimateFeesPerGasQueryOptions } from './estimateFeesPerGas.js' + +test('default', () => { + expect(estimateFeesPerGasQueryOptions(config)).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "estimateFeesPerGas", + {}, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + estimateFeesPerGasQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "estimateFeesPerGas", + { + "chainId": 1, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/estimateFeesPerGas.ts b/packages/core/src/query/estimateFeesPerGas.ts new file mode 100644 index 0000000000..7cf2f607c8 --- /dev/null +++ b/packages/core/src/query/estimateFeesPerGas.ts @@ -0,0 +1,56 @@ +import type { QueryOptions } from '@tanstack/query-core' +import type { FeeValuesType } from 'viem' + +import { + type EstimateFeesPerGasErrorType, + type EstimateFeesPerGasParameters, + type EstimateFeesPerGasReturnType, + estimateFeesPerGas, +} from '../actions/estimateFeesPerGas.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type EstimateFeesPerGasOptions< + type extends FeeValuesType, + config extends Config, +> = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function estimateFeesPerGasQueryOptions< + config extends Config, + type extends FeeValuesType = 'eip1559', +>(config: config, options: EstimateFeesPerGasOptions = {}) { + return { + async queryFn({ queryKey }) { + const { scopeKey: _, ...parameters } = queryKey[1] + return estimateFeesPerGas(config, parameters) + }, + queryKey: estimateFeesPerGasQueryKey(options), + } as const satisfies QueryOptions< + EstimateFeesPerGasQueryFnData, + EstimateFeesPerGasErrorType, + EstimateFeesPerGasData, + EstimateFeesPerGasQueryKey + > +} + +export type EstimateFeesPerGasQueryFnData = + EstimateFeesPerGasReturnType + +export type EstimateFeesPerGasData = + EstimateFeesPerGasQueryFnData + +export function estimateFeesPerGasQueryKey< + config extends Config, + type extends FeeValuesType = 'eip1559', +>(options: EstimateFeesPerGasOptions = {}) { + return ['estimateFeesPerGas', filterQueryOptions(options)] as const +} + +export type EstimateFeesPerGasQueryKey< + config extends Config, + type extends FeeValuesType, +> = ReturnType> diff --git a/packages/core/src/query/estimateGas.test-d.ts b/packages/core/src/query/estimateGas.test-d.ts new file mode 100644 index 0000000000..e48c4b089a --- /dev/null +++ b/packages/core/src/query/estimateGas.test-d.ts @@ -0,0 +1,55 @@ +import { http, type Address, parseEther } from 'viem' +import { celo, mainnet } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { + type EstimateGasOptions, + estimateGasQueryOptions, +} from './estimateGas.js' + +test('chain formatters', () => { + const config = createConfig({ + chains: [mainnet, celo], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + + type Result = EstimateGasOptions< + typeof config, + (typeof config)['chains'][number]['id'] + > + expectTypeOf().toMatchTypeOf<{ + chainId?: typeof celo.id | typeof mainnet.id | undefined + feeCurrency?: `0x${string}` | undefined + }>() + estimateGasQueryOptions(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + feeCurrency: '0x', + }) + + type Result2 = EstimateGasOptions + expectTypeOf().toMatchTypeOf<{ + functionName?: 'approve' | 'transfer' | 'transferFrom' | undefined + args?: readonly [Address, Address, bigint] | undefined + feeCurrency?: `0x${string}` | undefined + }>() + estimateGasQueryOptions(config, { + chainId: celo.id, + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + feeCurrency: '0x', + }) + + type Result3 = EstimateGasOptions + expectTypeOf().not.toMatchTypeOf<{ + feeCurrency?: `0x${string}` | undefined + }>() + estimateGasQueryOptions(config, { + chainId: mainnet.id, + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/core/src/query/estimateGas.test.ts b/packages/core/src/query/estimateGas.test.ts new file mode 100644 index 0000000000..6c31cadbc1 --- /dev/null +++ b/packages/core/src/query/estimateGas.test.ts @@ -0,0 +1,25 @@ +import { config } from '@wagmi/test' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { estimateGasQueryOptions } from './estimateGas.js' + +test('default', () => { + expect( + estimateGasQueryOptions(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "estimateGas", + { + "to": "0xd2135CfB216b74109775236E36d4b433F1DF507B", + "value": 10000000000000000n, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/estimateGas.ts b/packages/core/src/query/estimateGas.ts new file mode 100644 index 0000000000..749002f92c --- /dev/null +++ b/packages/core/src/query/estimateGas.ts @@ -0,0 +1,56 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type EstimateGasErrorType, + type EstimateGasParameters, + type EstimateGasReturnType, + estimateGas, +} from '../actions/estimateGas.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { UnionExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type EstimateGasOptions< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, +> = UnionExactPartial> & + ScopeKeyParameter + +export function estimateGasQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +>(config: config, options: EstimateGasOptions = {} as any) { + return { + async queryFn({ queryKey }) { + const { connector } = options + const { account, scopeKey: _, ...parameters } = queryKey[1] + if (!account && !connector) + throw new Error('account or connector is required') + return estimateGas(config, { account, connector, ...(parameters as any) }) + }, + queryKey: estimateGasQueryKey(options), + } as const satisfies QueryOptions< + EstimateGasQueryFnData, + EstimateGasErrorType, + EstimateGasData, + EstimateGasQueryKey + > +} + +export type EstimateGasQueryFnData = EstimateGasReturnType + +export type EstimateGasData = EstimateGasQueryFnData + +export function estimateGasQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, +>(options: EstimateGasOptions = {} as any) { + const { connector: _, ...rest } = options + return ['estimateGas', filterQueryOptions(rest)] as const +} + +export type EstimateGasQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, +> = ReturnType> diff --git a/packages/core/src/query/estimateMaxPriorityFeePerGas.test.ts b/packages/core/src/query/estimateMaxPriorityFeePerGas.test.ts new file mode 100644 index 0000000000..38bcde076d --- /dev/null +++ b/packages/core/src/query/estimateMaxPriorityFeePerGas.test.ts @@ -0,0 +1,36 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { estimateMaxPriorityFeePerGasQueryOptions } from './estimateMaxPriorityFeePerGas.js' + +test('default', () => { + expect( + estimateMaxPriorityFeePerGasQueryOptions(config), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "estimateMaxPriorityFeePerGas", + {}, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + estimateMaxPriorityFeePerGasQueryOptions(config, { + chainId: chain.mainnet.id, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "estimateMaxPriorityFeePerGas", + { + "chainId": 1, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/estimateMaxPriorityFeePerGas.ts b/packages/core/src/query/estimateMaxPriorityFeePerGas.ts new file mode 100644 index 0000000000..cb58e65a79 --- /dev/null +++ b/packages/core/src/query/estimateMaxPriorityFeePerGas.ts @@ -0,0 +1,51 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type EstimateMaxPriorityFeePerGasErrorType, + type EstimateMaxPriorityFeePerGasParameters, + type EstimateMaxPriorityFeePerGasReturnType, + estimateMaxPriorityFeePerGas, +} from '../actions/estimateMaxPriorityFeePerGas.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type EstimateMaxPriorityFeePerGasOptions = + Compute< + ExactPartial> & + ScopeKeyParameter + > + +export function estimateMaxPriorityFeePerGasQueryOptions( + config: config, + options: EstimateMaxPriorityFeePerGasOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { scopeKey: _, ...parameters } = queryKey[1] + return estimateMaxPriorityFeePerGas(config, parameters) + }, + queryKey: estimateMaxPriorityFeePerGasQueryKey(options), + } as const satisfies QueryOptions< + EstimateMaxPriorityFeePerGasQueryFnData, + EstimateMaxPriorityFeePerGasErrorType, + EstimateMaxPriorityFeePerGasData, + EstimateMaxPriorityFeePerGasQueryKey + > +} + +export type EstimateMaxPriorityFeePerGasQueryFnData = + EstimateMaxPriorityFeePerGasReturnType + +export type EstimateMaxPriorityFeePerGasData = + EstimateMaxPriorityFeePerGasQueryFnData + +export function estimateMaxPriorityFeePerGasQueryKey( + options: EstimateMaxPriorityFeePerGasOptions = {}, +) { + return ['estimateMaxPriorityFeePerGas', filterQueryOptions(options)] as const +} + +export type EstimateMaxPriorityFeePerGasQueryKey = + ReturnType> diff --git a/packages/core/src/query/getBalance.test.ts b/packages/core/src/query/getBalance.test.ts new file mode 100644 index 0000000000..1f9e1ecda9 --- /dev/null +++ b/packages/core/src/query/getBalance.test.ts @@ -0,0 +1,63 @@ +import { accounts, chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getBalanceQueryOptions } from './getBalance.js' + +const address = accounts[0] + +test('default', () => { + expect(getBalanceQueryOptions(config, { address })).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "balance", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getBalanceQueryOptions(config, { address, chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "balance", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + }, + ], + } + `) +}) + +test.todo('parameters: token') + +test('parameters: unit', () => { + expect( + getBalanceQueryOptions(config, { + address, + chainId: chain.mainnet.id, + token: '0x0000000000000000000000000000000000000000', + unit: 'gwei', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "balance", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + "token": "0x0000000000000000000000000000000000000000", + "unit": "gwei", + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getBalance.ts b/packages/core/src/query/getBalance.ts new file mode 100644 index 0000000000..e1dd287633 --- /dev/null +++ b/packages/core/src/query/getBalance.ts @@ -0,0 +1,53 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetBalanceErrorType, + type GetBalanceParameters, + type GetBalanceReturnType, + getBalance, +} from '../actions/getBalance.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, PartialBy } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetBalanceOptions = Compute< + PartialBy, 'address'> & ScopeKeyParameter +> + +export function getBalanceQueryOptions( + config: config, + options: GetBalanceOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { address, scopeKey: _, ...parameters } = queryKey[1] + if (!address) throw new Error('address is required') + const balance = await getBalance(config, { + ...(parameters as GetBalanceParameters), + address, + }) + return balance ?? null + }, + queryKey: getBalanceQueryKey(options), + } as const satisfies QueryOptions< + GetBalanceQueryFnData, + GetBalanceErrorType, + GetBalanceData, + GetBalanceQueryKey + > +} + +export type GetBalanceQueryFnData = Compute + +export type GetBalanceData = GetBalanceQueryFnData + +export function getBalanceQueryKey( + options: GetBalanceOptions = {}, +) { + return ['balance', filterQueryOptions(options)] as const +} + +export type GetBalanceQueryKey = ReturnType< + typeof getBalanceQueryKey +> diff --git a/packages/core/src/query/getBlock.test.ts b/packages/core/src/query/getBlock.test.ts new file mode 100644 index 0000000000..f31fb8c26e --- /dev/null +++ b/packages/core/src/query/getBlock.test.ts @@ -0,0 +1,32 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getBlockQueryOptions } from './getBlock.js' + +test('default', () => { + expect(getBlockQueryOptions(config)).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "block", + {}, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getBlockQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "block", + { + "chainId": 1, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getBlock.ts b/packages/core/src/query/getBlock.ts new file mode 100644 index 0000000000..f8f4db8417 --- /dev/null +++ b/packages/core/src/query/getBlock.ts @@ -0,0 +1,84 @@ +import type { QueryOptions } from '@tanstack/query-core' +import type { BlockTag } from 'viem' + +import { + type GetBlockErrorType, + type GetBlockParameters, + type GetBlockReturnType, + getBlock, +} from '../actions/getBlock.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetBlockOptions< + includeTransactions extends boolean, + blockTag extends BlockTag, + config extends Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = Compute< + ExactPartial< + GetBlockParameters + > & + ScopeKeyParameter +> + +export function getBlockQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'], + includeTransactions extends boolean, + blockTag extends BlockTag, +>( + config: config, + options: GetBlockOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { scopeKey: _, ...parameters } = queryKey[1] + const block = await getBlock(config, parameters) + return (block ?? null) as any + }, + queryKey: getBlockQueryKey(options), + } as const satisfies QueryOptions< + GetBlockQueryFnData, + GetBlockErrorType, + GetBlockData, + GetBlockQueryKey + > +} + +export type GetBlockQueryFnData< + includeTransactions extends boolean, + blockTag extends BlockTag, + config extends Config, + chainId extends config['chains'][number]['id'], +> = GetBlockReturnType + +export type GetBlockData< + includeTransactions extends boolean, + blockTag extends BlockTag, + config extends Config, + chainId extends config['chains'][number]['id'], +> = GetBlockQueryFnData + +export function getBlockQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], + includeTransactions extends boolean = false, + blockTag extends BlockTag = 'latest', +>( + options: GetBlockOptions = {}, +) { + return ['block', filterQueryOptions(options)] as const +} + +export type GetBlockQueryKey< + includeTransactions extends boolean, + blockTag extends BlockTag, + config extends Config, + chainId extends config['chains'][number]['id'], +> = ReturnType< + typeof getBlockQueryKey +> diff --git a/packages/core/src/query/getBlockNumber.test.ts b/packages/core/src/query/getBlockNumber.test.ts new file mode 100644 index 0000000000..b2ff0c2d14 --- /dev/null +++ b/packages/core/src/query/getBlockNumber.test.ts @@ -0,0 +1,34 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getBlockNumberQueryOptions } from './getBlockNumber.js' + +test('default', () => { + expect(getBlockNumberQueryOptions(config)).toMatchInlineSnapshot(` + { + "gcTime": 0, + "queryFn": [Function], + "queryKey": [ + "blockNumber", + {}, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getBlockNumberQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "gcTime": 0, + "queryFn": [Function], + "queryKey": [ + "blockNumber", + { + "chainId": 1, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getBlockNumber.ts b/packages/core/src/query/getBlockNumber.ts new file mode 100644 index 0000000000..9585068a92 --- /dev/null +++ b/packages/core/src/query/getBlockNumber.ts @@ -0,0 +1,55 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetBlockNumberErrorType, + type GetBlockNumberParameters, + type GetBlockNumberReturnType, + getBlockNumber, +} from '../actions/getBlockNumber.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetBlockNumberOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +> = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getBlockNumberQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +>(config: config, options: GetBlockNumberOptions = {}) { + return { + gcTime: 0, + async queryFn({ queryKey }) { + const { scopeKey: _, ...parameters } = queryKey[1] + const blockNumber = await getBlockNumber(config, parameters) + return blockNumber ?? null + }, + queryKey: getBlockNumberQueryKey(options), + } as const satisfies QueryOptions< + GetBlockNumberQueryFnData, + GetBlockNumberErrorType, + GetBlockNumberData, + GetBlockNumberQueryKey + > +} + +export type GetBlockNumberQueryFnData = GetBlockNumberReturnType + +export type GetBlockNumberData = GetBlockNumberQueryFnData + +export function getBlockNumberQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +>(options: GetBlockNumberOptions = {}) { + return ['blockNumber', filterQueryOptions(options)] as const +} + +export type GetBlockNumberQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +> = ReturnType> diff --git a/packages/core/src/query/getBlockTransactionCount.test.ts b/packages/core/src/query/getBlockTransactionCount.test.ts new file mode 100644 index 0000000000..d6c45ee09b --- /dev/null +++ b/packages/core/src/query/getBlockTransactionCount.test.ts @@ -0,0 +1,50 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getBlockTransactionCountQueryOptions } from './getBlockTransactionCount.js' + +test('default', () => { + expect(getBlockTransactionCountQueryOptions(config)).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "blockTransactionCount", + {}, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getBlockTransactionCountQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "blockTransactionCount", + { + "chainId": 1, + }, + ], + } + `) +}) + +test('parameters: blockTag', () => { + expect( + getBlockTransactionCountQueryOptions(config, { + blockTag: 'earliest', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "blockTransactionCount", + { + "blockTag": "earliest", + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getBlockTransactionCount.ts b/packages/core/src/query/getBlockTransactionCount.ts new file mode 100644 index 0000000000..453e95e001 --- /dev/null +++ b/packages/core/src/query/getBlockTransactionCount.ts @@ -0,0 +1,62 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetBlockTransactionCountErrorType, + type GetBlockTransactionCountParameters, + type GetBlockTransactionCountReturnType, + getBlockTransactionCount, +} from '../actions/getBlockTransactionCount.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { ExactPartial, UnionCompute } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetBlockTransactionCountOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +> = UnionCompute< + ExactPartial> & + ScopeKeyParameter +> + +export function getBlockTransactionCountQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + options: GetBlockTransactionCountOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { scopeKey: _, ...parameters } = queryKey[1] + const blockTransactionCount = await getBlockTransactionCount( + config, + parameters, + ) + return blockTransactionCount ?? null + }, + queryKey: getBlockTransactionCountQueryKey(options), + } as const satisfies QueryOptions< + GetBlockTransactionCountQueryFnData, + GetBlockTransactionCountErrorType, + GetBlockTransactionCountData, + GetBlockTransactionCountQueryKey + > +} + +export type GetBlockTransactionCountQueryFnData = + GetBlockTransactionCountReturnType + +export type GetBlockTransactionCountData = GetBlockTransactionCountQueryFnData + +export function getBlockTransactionCountQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +>(options: GetBlockTransactionCountOptions = {}) { + return ['blockTransactionCount', filterQueryOptions(options)] as const +} + +export type GetBlockTransactionCountQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +> = ReturnType> diff --git a/packages/core/src/query/getBytecode.test.ts b/packages/core/src/query/getBytecode.test.ts new file mode 100644 index 0000000000..83f22ebf2e --- /dev/null +++ b/packages/core/src/query/getBytecode.test.ts @@ -0,0 +1,82 @@ +import { address, chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getBytecodeQueryOptions } from './getBytecode.js' + +test('default', () => { + expect( + getBytecodeQueryOptions(config, { + address: address.wagmiMintExample, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getBytecodeQueryOptions(config, { + address: address.wagmiMintExample, + chainId: chain.mainnet2.id, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 456, + }, + ], + } + `) +}) + +test('parameters: blockNumber', () => { + expect( + getBytecodeQueryOptions(config, { + address: address.wagmiMintExample, + blockNumber: 1234567890n, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "blockNumber": 1234567890n, + }, + ], + } + `) +}) + +test('parameters: blockTag', () => { + expect( + getBytecodeQueryOptions(config, { + address: address.wagmiMintExample, + blockTag: 'safe', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "blockTag": "safe", + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getBytecode.ts b/packages/core/src/query/getBytecode.ts new file mode 100644 index 0000000000..7000c50eaa --- /dev/null +++ b/packages/core/src/query/getBytecode.ts @@ -0,0 +1,49 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetBytecodeErrorType, + type GetBytecodeParameters, + type GetBytecodeReturnType, + getBytecode, +} from '../actions/getBytecode.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetBytecodeOptions = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getBytecodeQueryOptions( + config: config, + options: GetBytecodeOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { address, scopeKey: _, ...parameters } = queryKey[1] + if (!address) throw new Error('address is required') + const bytecode = await getBytecode(config, { ...parameters, address }) + return (bytecode ?? null) as any + }, + queryKey: getBytecodeQueryKey(options), + } as const satisfies QueryOptions< + GetBytecodeQueryFnData, + GetBytecodeErrorType, + GetBytecodeData, + GetBytecodeQueryKey + > +} +export type GetBytecodeQueryFnData = GetBytecodeReturnType + +export type GetBytecodeData = GetBytecodeQueryFnData + +export function getBytecodeQueryKey( + options: GetBytecodeOptions, +) { + return ['getBytecode', filterQueryOptions(options)] as const +} + +export type GetBytecodeQueryKey = ReturnType< + typeof getBytecodeQueryKey +> diff --git a/packages/core/src/query/getCallsStatus.test.ts b/packages/core/src/query/getCallsStatus.test.ts new file mode 100644 index 0000000000..fe834ecc79 --- /dev/null +++ b/packages/core/src/query/getCallsStatus.test.ts @@ -0,0 +1,23 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getCallsStatusQueryOptions } from './getCallsStatus.js' + +test('default', () => { + expect( + getCallsStatusQueryOptions(config, { + id: '0x0000000000000000000000000000000000000000', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "callsStatus", + { + "id": "0x0000000000000000000000000000000000000000", + }, + ], + "retry": [Function], + } + `) +}) diff --git a/packages/core/src/query/getCallsStatus.ts b/packages/core/src/query/getCallsStatus.ts new file mode 100644 index 0000000000..869263eef0 --- /dev/null +++ b/packages/core/src/query/getCallsStatus.ts @@ -0,0 +1,50 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetCallsStatusErrorType, + type GetCallsStatusParameters, + type GetCallsStatusReturnType, + getCallsStatus, +} from '../actions/getCallsStatus.js' +import type { Config } from '../createConfig.js' +import { ConnectorNotConnectedError } from '../errors/config.js' +import { filterQueryOptions } from '../query/utils.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute } from '../types/utils.js' + +export type GetCallsStatusOptions = Compute< + GetCallsStatusParameters & ScopeKeyParameter +> + +export function getCallsStatusQueryOptions( + config: config, + options: GetCallsStatusOptions, +) { + return { + async queryFn({ queryKey }) { + const { scopeKey: _, ...parameters } = queryKey[1] + const status = await getCallsStatus(config, parameters) + return status + }, + queryKey: getCallsStatusQueryKey(options), + retry(failureCount, error) { + if (error instanceof ConnectorNotConnectedError) return false + return failureCount < 3 + }, + } as const satisfies QueryOptions< + GetCallsStatusQueryFnData, + GetCallsStatusErrorType, + GetCallsStatusData, + GetCallsStatusQueryKey + > +} + +export type GetCallsStatusQueryFnData = GetCallsStatusReturnType + +export type GetCallsStatusData = GetCallsStatusQueryFnData + +export function getCallsStatusQueryKey(options: GetCallsStatusOptions) { + return ['callsStatus', filterQueryOptions(options)] as const +} + +export type GetCallsStatusQueryKey = ReturnType diff --git a/packages/core/src/query/getCapabilities.test.ts b/packages/core/src/query/getCapabilities.test.ts new file mode 100644 index 0000000000..942eb37e04 --- /dev/null +++ b/packages/core/src/query/getCapabilities.test.ts @@ -0,0 +1,36 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getCapabilitiesQueryOptions } from './getCapabilities.js' + +test('default', () => { + expect(getCapabilitiesQueryOptions(config)).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "capabilities", + {}, + ], + "retry": [Function], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getCapabilitiesQueryOptions(config, { + account: '0x0000000000000000000000000000000000000000', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "capabilities", + { + "account": "0x0000000000000000000000000000000000000000", + }, + ], + "retry": [Function], + } + `) +}) diff --git a/packages/core/src/query/getCapabilities.ts b/packages/core/src/query/getCapabilities.ts new file mode 100644 index 0000000000..754b77b551 --- /dev/null +++ b/packages/core/src/query/getCapabilities.ts @@ -0,0 +1,65 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetCapabilitiesErrorType, + type GetCapabilitiesParameters, + type GetCapabilitiesReturnType, + getCapabilities, +} from '../actions/getCapabilities.js' +import type { Config } from '../createConfig.js' +import { ConnectorNotConnectedError } from '../errors/config.js' +import { filterQueryOptions } from '../query/utils.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' + +export type GetCapabilitiesOptions< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, +> = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getCapabilitiesQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, +>(config: config, options: GetCapabilitiesOptions = {}) { + return { + async queryFn({ queryKey }) { + const { scopeKey: _, ...parameters } = queryKey[1] + const capabilities = await getCapabilities(config, parameters) + return capabilities + }, + queryKey: getCapabilitiesQueryKey(options), + retry(failureCount, error) { + if (error instanceof ConnectorNotConnectedError) return false + return failureCount < 3 + }, + } as const satisfies QueryOptions< + GetCapabilitiesQueryFnData, + GetCapabilitiesErrorType, + GetCapabilitiesData, + GetCapabilitiesQueryKey + > +} + +export type GetCapabilitiesQueryFnData< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, +> = GetCapabilitiesReturnType + +export type GetCapabilitiesData< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, +> = GetCapabilitiesQueryFnData + +export function getCapabilitiesQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, +>(options: GetCapabilitiesOptions = {}) { + return ['capabilities', filterQueryOptions(options)] as const +} + +export type GetCapabilitiesQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, +> = ReturnType> diff --git a/packages/core/src/query/getConnectorClient.test.ts b/packages/core/src/query/getConnectorClient.test.ts new file mode 100644 index 0000000000..fdec57969d --- /dev/null +++ b/packages/core/src/query/getConnectorClient.test.ts @@ -0,0 +1,37 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getConnectorClientQueryOptions } from './getConnectorClient.js' + +test('default', () => { + expect(getConnectorClientQueryOptions(config)).toMatchInlineSnapshot(` + { + "gcTime": 0, + "queryFn": [Function], + "queryKey": [ + "connectorClient", + { + "connectorUid": undefined, + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getConnectorClientQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "gcTime": 0, + "queryFn": [Function], + "queryKey": [ + "connectorClient", + { + "chainId": 1, + "connectorUid": undefined, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getConnectorClient.ts b/packages/core/src/query/getConnectorClient.ts new file mode 100644 index 0000000000..7bc65029f0 --- /dev/null +++ b/packages/core/src/query/getConnectorClient.ts @@ -0,0 +1,69 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetConnectorClientErrorType, + type GetConnectorClientParameters, + type GetConnectorClientReturnType, + getConnectorClient, +} from '../actions/getConnectorClient.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetConnectorClientOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +> = Compute< + ExactPartial> & + ScopeKeyParameter +> + +export function getConnectorClientQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +>(config: config, options: GetConnectorClientOptions = {}) { + return { + gcTime: 0, + async queryFn({ queryKey }) { + const { connector } = options + const { connectorUid: _, scopeKey: _s, ...parameters } = queryKey[1] + return getConnectorClient(config, { + ...parameters, + connector, + }) as unknown as Promise> + }, + queryKey: getConnectorClientQueryKey(options), + } as const satisfies QueryOptions< + GetConnectorClientQueryFnData, + GetConnectorClientErrorType, + GetConnectorClientData, + GetConnectorClientQueryKey + > +} + +export type GetConnectorClientQueryFnData< + config extends Config, + chainId extends config['chains'][number]['id'], +> = GetConnectorClientReturnType + +export type GetConnectorClientData< + config extends Config, + chainId extends config['chains'][number]['id'], +> = GetConnectorClientQueryFnData + +export function getConnectorClientQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +>(options: GetConnectorClientOptions = {}) { + const { connector, ...parameters } = options + return [ + 'connectorClient', + { ...filterQueryOptions(parameters), connectorUid: connector?.uid }, + ] as const +} + +export type GetConnectorClientQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +> = ReturnType> diff --git a/packages/core/src/query/getEnsAddress.test.ts b/packages/core/src/query/getEnsAddress.test.ts new file mode 100644 index 0000000000..0e88461e61 --- /dev/null +++ b/packages/core/src/query/getEnsAddress.test.ts @@ -0,0 +1,32 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getEnsAddressQueryOptions } from './getEnsAddress.js' + +test('default', () => { + expect(getEnsAddressQueryOptions(config)).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "ensAddress", + {}, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getEnsAddressQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "ensAddress", + { + "chainId": 1, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getEnsAddress.ts b/packages/core/src/query/getEnsAddress.ts new file mode 100644 index 0000000000..7f18c9dd63 --- /dev/null +++ b/packages/core/src/query/getEnsAddress.ts @@ -0,0 +1,49 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetEnsAddressErrorType, + type GetEnsAddressParameters, + type GetEnsAddressReturnType, + getEnsAddress, +} from '../actions/getEnsAddress.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetEnsAddressOptions = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getEnsAddressQueryOptions( + config: config, + options: GetEnsAddressOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { name, scopeKey: _, ...parameters } = queryKey[1] + if (!name) throw new Error('name is required') + return getEnsAddress(config, { ...parameters, name }) + }, + queryKey: getEnsAddressQueryKey(options), + } as const satisfies QueryOptions< + GetEnsAddressQueryFnData, + GetEnsAddressErrorType, + GetEnsAddressData, + GetEnsAddressQueryKey + > +} + +export type GetEnsAddressQueryFnData = GetEnsAddressReturnType + +export type GetEnsAddressData = GetEnsAddressQueryFnData + +export function getEnsAddressQueryKey( + options: GetEnsAddressOptions = {}, +) { + return ['ensAddress', filterQueryOptions(options)] as const +} + +export type GetEnsAddressQueryKey = ReturnType< + typeof getEnsAddressQueryKey +> diff --git a/packages/core/src/query/getEnsAvatar.test.ts b/packages/core/src/query/getEnsAvatar.test.ts new file mode 100644 index 0000000000..8b62526426 --- /dev/null +++ b/packages/core/src/query/getEnsAvatar.test.ts @@ -0,0 +1,32 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getEnsAvatarQueryOptions } from './getEnsAvatar.js' + +test('default', () => { + expect(getEnsAvatarQueryOptions(config)).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "ensAvatar", + {}, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getEnsAvatarQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "ensAvatar", + { + "chainId": 1, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getEnsAvatar.ts b/packages/core/src/query/getEnsAvatar.ts new file mode 100644 index 0000000000..f399736e08 --- /dev/null +++ b/packages/core/src/query/getEnsAvatar.ts @@ -0,0 +1,49 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetEnsAvatarErrorType, + type GetEnsAvatarParameters, + type GetEnsAvatarReturnType, + getEnsAvatar, +} from '../actions/getEnsAvatar.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetEnsAvatarOptions = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getEnsAvatarQueryOptions( + config: config, + options: GetEnsAvatarOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { name, scopeKey: _, ...parameters } = queryKey[1] + if (!name) throw new Error('name is required') + return getEnsAvatar(config, { ...parameters, name }) + }, + queryKey: getEnsAvatarQueryKey(options), + } as const satisfies QueryOptions< + GetEnsAvatarQueryFnData, + GetEnsAvatarErrorType, + GetEnsAvatarData, + GetEnsAvatarQueryKey + > +} + +export type GetEnsAvatarQueryFnData = GetEnsAvatarReturnType + +export type GetEnsAvatarData = GetEnsAvatarQueryFnData + +export function getEnsAvatarQueryKey( + options: GetEnsAvatarOptions = {}, +) { + return ['ensAvatar', filterQueryOptions(options)] as const +} + +export type GetEnsAvatarQueryKey = ReturnType< + typeof getEnsAvatarQueryKey +> diff --git a/packages/core/src/query/getEnsName.test.ts b/packages/core/src/query/getEnsName.test.ts new file mode 100644 index 0000000000..006c76a12d --- /dev/null +++ b/packages/core/src/query/getEnsName.test.ts @@ -0,0 +1,32 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getEnsNameQueryOptions } from './getEnsName.js' + +test('default', () => { + expect(getEnsNameQueryOptions(config)).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "ensName", + {}, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getEnsNameQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "ensName", + { + "chainId": 1, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getEnsName.ts b/packages/core/src/query/getEnsName.ts new file mode 100644 index 0000000000..cff1534e07 --- /dev/null +++ b/packages/core/src/query/getEnsName.ts @@ -0,0 +1,49 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetEnsNameErrorType, + type GetEnsNameParameters, + type GetEnsNameReturnType, + getEnsName, +} from '../actions/getEnsName.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetEnsNameOptions = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getEnsNameQueryOptions( + config: config, + options: GetEnsNameOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { address, scopeKey: _, ...parameters } = queryKey[1] + if (!address) throw new Error('address is required') + return getEnsName(config, { ...parameters, address }) + }, + queryKey: getEnsNameQueryKey(options), + } as const satisfies QueryOptions< + GetEnsNameQueryFnData, + GetEnsNameErrorType, + GetEnsNameData, + GetEnsNameQueryKey + > +} + +export type GetEnsNameQueryFnData = GetEnsNameReturnType + +export type GetEnsNameData = GetEnsNameQueryFnData + +export function getEnsNameQueryKey( + options: GetEnsNameOptions = {}, +) { + return ['ensName', filterQueryOptions(options)] as const +} + +export type GetEnsNameQueryKey = ReturnType< + typeof getEnsNameQueryKey +> diff --git a/packages/core/src/query/getEnsResolver.test.ts b/packages/core/src/query/getEnsResolver.test.ts new file mode 100644 index 0000000000..36baf9ba90 --- /dev/null +++ b/packages/core/src/query/getEnsResolver.test.ts @@ -0,0 +1,32 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getEnsResolverQueryOptions } from './getEnsResolver.js' + +test('default', () => { + expect(getEnsResolverQueryOptions(config)).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "ensResolver", + {}, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getEnsResolverQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "ensResolver", + { + "chainId": 1, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getEnsResolver.ts b/packages/core/src/query/getEnsResolver.ts new file mode 100644 index 0000000000..124499325d --- /dev/null +++ b/packages/core/src/query/getEnsResolver.ts @@ -0,0 +1,49 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetEnsResolverErrorType, + type GetEnsResolverParameters, + type GetEnsResolverReturnType, + getEnsResolver, +} from '../actions/getEnsResolver.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetEnsResolverOptions = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getEnsResolverQueryOptions( + config: config, + options: GetEnsResolverOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { name, scopeKey: _, ...parameters } = queryKey[1] + if (!name) throw new Error('name is required') + return getEnsResolver(config, { ...parameters, name }) + }, + queryKey: getEnsResolverQueryKey(options), + } as const satisfies QueryOptions< + GetEnsResolverQueryFnData, + GetEnsResolverErrorType, + GetEnsResolverData, + GetEnsResolverQueryKey + > +} + +export type GetEnsResolverQueryFnData = GetEnsResolverReturnType + +export type GetEnsResolverData = GetEnsResolverQueryFnData + +export function getEnsResolverQueryKey( + options: GetEnsResolverOptions = {}, +) { + return ['ensResolver', filterQueryOptions(options)] as const +} + +export type GetEnsResolverQueryKey = ReturnType< + typeof getEnsResolverQueryKey +> diff --git a/packages/core/src/query/getEnsText.test.ts b/packages/core/src/query/getEnsText.test.ts new file mode 100644 index 0000000000..1370410633 --- /dev/null +++ b/packages/core/src/query/getEnsText.test.ts @@ -0,0 +1,46 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getEnsTextQueryOptions } from './getEnsText.js' + +test('default', () => { + expect( + getEnsTextQueryOptions(config, { + name: 'wevm.eth', + key: 'com.twitter', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "ensText", + { + "key": "com.twitter", + "name": "wevm.eth", + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getEnsTextQueryOptions(config, { + chainId: chain.mainnet.id, + name: 'wevm.eth', + key: 'com.twitter', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "ensText", + { + "chainId": 1, + "key": "com.twitter", + "name": "wevm.eth", + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getEnsText.ts b/packages/core/src/query/getEnsText.ts new file mode 100644 index 0000000000..2f1c464dea --- /dev/null +++ b/packages/core/src/query/getEnsText.ts @@ -0,0 +1,49 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetEnsTextErrorType, + type GetEnsTextParameters, + type GetEnsTextReturnType, + getEnsText, +} from '../actions/getEnsText.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetEnsTextOptions = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getEnsTextQueryOptions( + config: config, + options: GetEnsTextOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { key, name, scopeKey: _, ...parameters } = queryKey[1] + if (!key || !name) throw new Error('key and name are required') + return getEnsText(config, { ...parameters, key, name }) + }, + queryKey: getEnsTextQueryKey(options), + } as const satisfies QueryOptions< + GetEnsTextQueryFnData, + GetEnsTextErrorType, + GetEnsTextData, + GetEnsTextQueryKey + > +} + +export type GetEnsTextQueryFnData = GetEnsTextReturnType + +export type GetEnsTextData = GetEnsTextQueryFnData + +export function getEnsTextQueryKey( + options: GetEnsTextOptions = {}, +) { + return ['ensText', filterQueryOptions(options)] as const +} + +export type GetEnsTextQueryKey = ReturnType< + typeof getEnsTextQueryKey +> diff --git a/packages/core/src/query/getFeeHistory.test.ts b/packages/core/src/query/getFeeHistory.test.ts new file mode 100644 index 0000000000..aa40793235 --- /dev/null +++ b/packages/core/src/query/getFeeHistory.test.ts @@ -0,0 +1,128 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getFeeHistoryQueryOptions } from './getFeeHistory.js' + +test('default', async () => { + expect( + getFeeHistoryQueryOptions(config, { + blockCount: 4, + rewardPercentiles: [25, 75], + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "feeHistory", + { + "blockCount": 4, + "rewardPercentiles": [ + 25, + 75, + ], + }, + ], + } + `) +}) + +test('parameters: chainId', async () => { + expect( + getFeeHistoryQueryOptions(config, { + blockCount: 4, + rewardPercentiles: [25, 75], + chainId: chain.mainnet2.id, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "feeHistory", + { + "blockCount": 4, + "chainId": 456, + "rewardPercentiles": [ + 25, + 75, + ], + }, + ], + } + `) +}) + +test('parameters: blockNumber', async () => { + expect( + getFeeHistoryQueryOptions(config, { + blockCount: 4, + rewardPercentiles: [25, 75], + blockNumber: 18677379n, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "feeHistory", + { + "blockCount": 4, + "blockNumber": 18677379n, + "rewardPercentiles": [ + 25, + 75, + ], + }, + ], + } + `) +}) + +test('parameters: blockTag', async () => { + expect( + getFeeHistoryQueryOptions(config, { + blockCount: 4, + rewardPercentiles: [25, 75], + blockTag: 'safe', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "feeHistory", + { + "blockCount": 4, + "blockTag": "safe", + "rewardPercentiles": [ + 25, + 75, + ], + }, + ], + } + `) +}) + +test('behavior: blockCount is required', async () => { + const options = getFeeHistoryQueryOptions(config, {}) + expect( + options.queryFn({ + queryKey: options.queryKey, + signal: new AbortSignal(), + meta: undefined, + }), + ).rejects.toThrowErrorMatchingInlineSnapshot( + '[Error: blockCount is required]', + ) +}) + +test('behavior: rewardPercentiles is required', async () => { + const options = getFeeHistoryQueryOptions(config, { blockCount: 4 }) + expect( + options.queryFn({ + queryKey: options.queryKey, + signal: new AbortSignal(), + meta: undefined, + }), + ).rejects.toThrowErrorMatchingInlineSnapshot( + '[Error: rewardPercentiles is required]', + ) +}) diff --git a/packages/core/src/query/getFeeHistory.ts b/packages/core/src/query/getFeeHistory.ts new file mode 100644 index 0000000000..6eeef0d681 --- /dev/null +++ b/packages/core/src/query/getFeeHistory.ts @@ -0,0 +1,69 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetFeeHistoryErrorType, + type GetFeeHistoryParameters, + type GetFeeHistoryReturnType, + getFeeHistory, +} from '../actions/getFeeHistory.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, PartialBy } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetFeeHistoryOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +> = Compute< + PartialBy< + GetFeeHistoryParameters, + 'blockCount' | 'rewardPercentiles' + > & + ScopeKeyParameter +> + +export function getFeeHistoryQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +>(config: config, options: GetFeeHistoryOptions = {}) { + return { + async queryFn({ queryKey }) { + const { + blockCount, + rewardPercentiles, + scopeKey: _, + ...parameters + } = queryKey[1] + if (!blockCount) throw new Error('blockCount is required') + if (!rewardPercentiles) throw new Error('rewardPercentiles is required') + const feeHistory = await getFeeHistory(config, { + ...(parameters as GetFeeHistoryParameters), + blockCount, + rewardPercentiles, + }) + return feeHistory ?? null + }, + queryKey: getFeeHistoryQueryKey(options), + } as const satisfies QueryOptions< + GetFeeHistoryQueryFnData, + GetFeeHistoryErrorType, + GetFeeHistoryData, + GetFeeHistoryQueryKey + > +} + +export type GetFeeHistoryQueryFnData = GetFeeHistoryReturnType + +export type GetFeeHistoryData = GetFeeHistoryQueryFnData + +export function getFeeHistoryQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +>(options: GetFeeHistoryOptions = {}) { + return ['feeHistory', filterQueryOptions(options)] as const +} + +export type GetFeeHistoryQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +> = ReturnType> diff --git a/packages/core/src/query/getGasPrice.test.ts b/packages/core/src/query/getGasPrice.test.ts new file mode 100644 index 0000000000..2b90303669 --- /dev/null +++ b/packages/core/src/query/getGasPrice.test.ts @@ -0,0 +1,32 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getGasPriceQueryOptions } from './getGasPrice.js' + +test('default', () => { + expect(getGasPriceQueryOptions(config)).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "gasPrice", + {}, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getGasPriceQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "gasPrice", + { + "chainId": 1, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getGasPrice.ts b/packages/core/src/query/getGasPrice.ts new file mode 100644 index 0000000000..153d4a102d --- /dev/null +++ b/packages/core/src/query/getGasPrice.ts @@ -0,0 +1,54 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetGasPriceErrorType, + type GetGasPriceParameters, + type GetGasPriceReturnType, + getGasPrice, +} from '../actions/getGasPrice.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetGasPriceOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +> = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getGasPriceQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +>(config: config, options: GetGasPriceOptions = {}) { + return { + async queryFn({ queryKey }) { + const { scopeKey: _, ...parameters } = queryKey[1] + const gasPrice = await getGasPrice(config, parameters) + return gasPrice ?? null + }, + queryKey: getGasPriceQueryKey(options), + } as const satisfies QueryOptions< + GetGasPriceQueryFnData, + GetGasPriceErrorType, + GetGasPriceData, + GetGasPriceQueryKey + > +} + +export type GetGasPriceQueryFnData = GetGasPriceReturnType + +export type GetGasPriceData = GetGasPriceQueryFnData + +export function getGasPriceQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +>(options: GetGasPriceOptions = {}) { + return ['gasPrice', filterQueryOptions(options)] as const +} + +export type GetGasPriceQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +> = ReturnType> diff --git a/packages/core/src/query/getProof.test.ts b/packages/core/src/query/getProof.test.ts new file mode 100644 index 0000000000..30c02256c7 --- /dev/null +++ b/packages/core/src/query/getProof.test.ts @@ -0,0 +1,106 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getProofQueryOptions } from './getProof.js' + +test('default', () => { + expect( + getProofQueryOptions(config, { + address: '0x4200000000000000000000000000000000000016', + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getProof", + { + "address": "0x4200000000000000000000000000000000000016", + "storageKeys": [ + "0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99", + ], + }, + ], + } + `) +}) + +test('parameters: blockNumber', () => { + expect( + getProofQueryOptions(config, { + address: '0x4200000000000000000000000000000000000016', + blockNumber: 1234567890n, + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getProof", + { + "address": "0x4200000000000000000000000000000000000016", + "blockNumber": 1234567890n, + "storageKeys": [ + "0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99", + ], + }, + ], + } + `) +}) + +test('parameters: blockTag', () => { + expect( + getProofQueryOptions(config, { + address: '0x4200000000000000000000000000000000000016', + blockTag: 'safe', + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getProof", + { + "address": "0x4200000000000000000000000000000000000016", + "blockTag": "safe", + "storageKeys": [ + "0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99", + ], + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getProofQueryOptions(config, { + address: '0x4200000000000000000000000000000000000016', + chainId: chain.mainnet2.id, + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getProof", + { + "address": "0x4200000000000000000000000000000000000016", + "chainId": 456, + "storageKeys": [ + "0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99", + ], + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getProof.ts b/packages/core/src/query/getProof.ts new file mode 100644 index 0000000000..8da0b42b17 --- /dev/null +++ b/packages/core/src/query/getProof.ts @@ -0,0 +1,50 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetProofErrorType, + type GetProofParameters, + type GetProofReturnType, + getProof, +} from '../actions/getProof.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetProofOptions = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getProofQueryOptions( + config: config, + options: GetProofOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { address, scopeKey: _, storageKeys, ...parameters } = queryKey[1] + if (!address || !storageKeys) + throw new Error('address and storageKeys are required') + return getProof(config, { ...parameters, address, storageKeys }) + }, + queryKey: getProofQueryKey(options), + } as const satisfies QueryOptions< + GetProofQueryFnData, + GetProofErrorType, + GetProofData, + GetProofQueryKey + > +} + +export type GetProofQueryFnData = GetProofReturnType + +export type GetProofData = GetProofQueryFnData + +export function getProofQueryKey( + options: GetProofOptions, +) { + return ['getProof', filterQueryOptions(options)] as const +} + +export type GetProofQueryKey = ReturnType< + typeof getProofQueryKey +> diff --git a/packages/core/src/query/getStorageAt.test.ts b/packages/core/src/query/getStorageAt.test.ts new file mode 100644 index 0000000000..87193c1e6f --- /dev/null +++ b/packages/core/src/query/getStorageAt.test.ts @@ -0,0 +1,90 @@ +import { address, chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getStorageAtQueryOptions } from './getStorageAt.js' + +test('default', () => { + expect( + getStorageAtQueryOptions(config, { + address: address.wagmiMintExample, + slot: '0x0', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getStorageAt", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "slot": "0x0", + }, + ], + } + `) +}) + +test('parameters: blockNumber', () => { + expect( + getStorageAtQueryOptions(config, { + address: address.wagmiMintExample, + blockNumber: 16280770n, + slot: '0x0', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getStorageAt", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "blockNumber": 16280770n, + "slot": "0x0", + }, + ], + } + `) +}) + +test('parameters: blockTag', () => { + expect( + getStorageAtQueryOptions(config, { + address: address.wagmiMintExample, + blockTag: 'safe', + slot: '0x0', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getStorageAt", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "blockTag": "safe", + "slot": "0x0", + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getStorageAtQueryOptions(config, { + address: address.wagmiMintExample, + chainId: chain.mainnet2.id, + slot: '0x0', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getStorageAt", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 456, + "slot": "0x0", + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getStorageAt.ts b/packages/core/src/query/getStorageAt.ts new file mode 100644 index 0000000000..c2ed90c927 --- /dev/null +++ b/packages/core/src/query/getStorageAt.ts @@ -0,0 +1,49 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetStorageAtErrorType, + type GetStorageAtParameters, + type GetStorageAtReturnType, + getStorageAt, +} from '../actions/getStorageAt.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetStorageAtOptions = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getStorageAtQueryOptions( + config: config, + options: GetStorageAtOptions = {}, +) { + return { + queryFn({ queryKey }) { + const { address, slot, scopeKey: _, ...parameters } = queryKey[1] + if (!address || !slot) throw new Error('address and slot are required') + return getStorageAt(config, { ...parameters, address, slot }) + }, + queryKey: getStorageAtQueryKey(options), + } as const satisfies QueryOptions< + GetStorageAtQueryFnData, + GetStorageAtErrorType, + GetStorageAtData, + GetStorageAtQueryKey + > +} + +export type GetStorageAtQueryFnData = GetStorageAtReturnType + +export type GetStorageAtData = GetStorageAtQueryFnData + +export function getStorageAtQueryKey( + options: GetStorageAtOptions, +) { + return ['getStorageAt', filterQueryOptions(options)] as const +} + +export type GetStorageAtQueryKey = ReturnType< + typeof getStorageAtQueryKey +> diff --git a/packages/core/src/query/getToken.test.ts b/packages/core/src/query/getToken.test.ts new file mode 100644 index 0000000000..87ec1731c9 --- /dev/null +++ b/packages/core/src/query/getToken.test.ts @@ -0,0 +1,32 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getTokenQueryOptions } from './getToken.js' + +test('default', () => { + expect(getTokenQueryOptions(config)).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "token", + {}, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getTokenQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "token", + { + "chainId": 1, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getToken.ts b/packages/core/src/query/getToken.ts new file mode 100644 index 0000000000..8e4a2b866a --- /dev/null +++ b/packages/core/src/query/getToken.ts @@ -0,0 +1,49 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetTokenErrorType, + type GetTokenParameters, + type GetTokenReturnType, + getToken, +} from '../actions/getToken.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetTokenOptions = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getTokenQueryOptions( + config: config, + options: GetTokenOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { address, scopeKey: _, ...parameters } = queryKey[1] + if (!address) throw new Error('address is required') + return getToken(config, { ...parameters, address }) + }, + queryKey: getTokenQueryKey(options), + } as const satisfies QueryOptions< + GetTokenQueryFnData, + GetTokenErrorType, + GetTokenData, + GetTokenQueryKey + > +} + +export type GetTokenQueryFnData = GetTokenReturnType + +export type GetTokenData = GetTokenQueryFnData + +export function getTokenQueryKey( + options: GetTokenOptions = {}, +) { + return ['token', filterQueryOptions(options)] as const +} + +export type GetTokenQueryKey = ReturnType< + typeof getTokenQueryKey +> diff --git a/packages/core/src/query/getTransaction.test.ts b/packages/core/src/query/getTransaction.test.ts new file mode 100644 index 0000000000..e1db72b325 --- /dev/null +++ b/packages/core/src/query/getTransaction.test.ts @@ -0,0 +1,32 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getTransactionQueryOptions } from './getTransaction.js' + +test('default', () => { + expect(getTransactionQueryOptions(config)).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "transaction", + {}, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getTransactionQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "transaction", + { + "chainId": 1, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getTransaction.ts b/packages/core/src/query/getTransaction.ts new file mode 100644 index 0000000000..8564854774 --- /dev/null +++ b/packages/core/src/query/getTransaction.ts @@ -0,0 +1,69 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetTransactionErrorType, + type GetTransactionParameters, + type GetTransactionReturnType, + getTransaction, +} from '../actions/getTransaction.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetTransactionOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +> = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getTransactionQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +>(config: config, options: GetTransactionOptions = {}) { + return { + async queryFn({ queryKey }) { + const { blockHash, blockNumber, blockTag, hash, index } = queryKey[1] + if (!blockHash && !blockNumber && !blockTag && !hash) + throw new Error('blockHash, blockNumber, blockTag, or hash is required') + if (!hash && !index) + throw new Error( + 'index is required for blockHash, blockNumber, or blockTag', + ) + const { scopeKey: _, ...rest } = queryKey[1] + return getTransaction( + config, + rest as GetTransactionParameters, + ) as unknown as Promise> + }, + queryKey: getTransactionQueryKey(options), + } as const satisfies QueryOptions< + GetTransactionQueryFnData, + GetTransactionErrorType, + GetTransactionData, + GetTransactionQueryKey + > +} + +export type GetTransactionQueryFnData< + config extends Config, + chainId extends config['chains'][number]['id'], +> = GetTransactionReturnType + +export type GetTransactionData< + config extends Config, + chainId extends config['chains'][number]['id'], +> = GetTransactionQueryFnData + +export function getTransactionQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +>(options: GetTransactionOptions = {}) { + return ['transaction', filterQueryOptions(options)] as const +} + +export type GetTransactionQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +> = ReturnType> diff --git a/packages/core/src/query/getTransactionConfirmations.test.ts b/packages/core/src/query/getTransactionConfirmations.test.ts new file mode 100644 index 0000000000..ac4d6d4f4a --- /dev/null +++ b/packages/core/src/query/getTransactionConfirmations.test.ts @@ -0,0 +1,42 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getTransactionConfirmationsQueryOptions } from './getTransactionConfirmations.js' + +test('default', () => { + expect( + getTransactionConfirmationsQueryOptions(config, { + hash: '0xa559259bd2d0e8372421e222ff3545f705b5da60005bd787a23c2e68d6d7fefd', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "transactionConfirmations", + { + "hash": "0xa559259bd2d0e8372421e222ff3545f705b5da60005bd787a23c2e68d6d7fefd", + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getTransactionConfirmationsQueryOptions(config, { + chainId: chain.mainnet.id, + hash: '0xa559259bd2d0e8372421e222ff3545f705b5da60005bd787a23c2e68d6d7fefd', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "transactionConfirmations", + { + "chainId": 1, + "hash": "0xa559259bd2d0e8372421e222ff3545f705b5da60005bd787a23c2e68d6d7fefd", + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getTransactionConfirmations.ts b/packages/core/src/query/getTransactionConfirmations.ts new file mode 100644 index 0000000000..5c34decf37 --- /dev/null +++ b/packages/core/src/query/getTransactionConfirmations.ts @@ -0,0 +1,78 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetTransactionConfirmationsErrorType, + type GetTransactionConfirmationsParameters, + type GetTransactionConfirmationsReturnType, + getTransactionConfirmations, +} from '../actions/getTransactionConfirmations.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { UnionExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetTransactionConfirmationsOptions< + config extends Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], +> = UnionExactPartial> & + ScopeKeyParameter + +export function getTransactionConfirmationsQueryOptions< + config extends Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], +>( + config: config, + options: GetTransactionConfirmationsOptions = {} as any, +) { + return { + async queryFn({ queryKey }) { + const { + hash, + transactionReceipt, + scopeKey: _, + ...parameters + } = queryKey[1] + if (!hash && !transactionReceipt) + throw new Error('hash or transactionReceipt is required') + + const confirmations = await getTransactionConfirmations(config, { + hash, + transactionReceipt, + ...(parameters as any), + }) + return confirmations ?? null + }, + queryKey: getTransactionConfirmationsQueryKey(options), + } as const satisfies QueryOptions< + GetTransactionConfirmationsQueryFnData, + GetTransactionConfirmationsErrorType, + GetTransactionConfirmationsData, + GetTransactionConfirmationsQueryKey + > +} + +export type GetTransactionConfirmationsQueryFnData = + GetTransactionConfirmationsReturnType + +export type GetTransactionConfirmationsData = + GetTransactionConfirmationsQueryFnData + +export function getTransactionConfirmationsQueryKey< + config extends Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], +>(options: GetTransactionConfirmationsOptions = {} as any) { + return ['transactionConfirmations', filterQueryOptions(options)] as const +} + +export type GetTransactionConfirmationsQueryKey< + config extends Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], +> = ReturnType> diff --git a/packages/core/src/query/getTransactionCount.test.ts b/packages/core/src/query/getTransactionCount.test.ts new file mode 100644 index 0000000000..666953629b --- /dev/null +++ b/packages/core/src/query/getTransactionCount.test.ts @@ -0,0 +1,82 @@ +import { accounts, chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getTransactionCountQueryOptions } from './getTransactionCount.js' + +const address = accounts[0] + +test('default', () => { + expect( + getTransactionCountQueryOptions(config, { address }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "transactionCount", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getTransactionCountQueryOptions(config, { + address, + chainId: chain.mainnet.id, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "transactionCount", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + }, + ], + } + `) +}) + +test('parameters: blockNumber', () => { + expect( + getTransactionCountQueryOptions(config, { + address, + blockNumber: 13677382n, + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "transactionCount", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockNumber": 13677382n, + }, + ], + } + `) +}) + +test('parameters: blockTag', () => { + expect( + getTransactionCountQueryOptions(config, { + address, + blockTag: 'earliest', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "transactionCount", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockTag": "earliest", + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getTransactionCount.ts b/packages/core/src/query/getTransactionCount.ts new file mode 100644 index 0000000000..31fd2c1d8f --- /dev/null +++ b/packages/core/src/query/getTransactionCount.ts @@ -0,0 +1,55 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetTransactionCountErrorType, + type GetTransactionCountParameters, + type GetTransactionCountReturnType, + getTransactionCount, +} from '../actions/getTransactionCount.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, PartialBy } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetTransactionCountOptions = Compute< + PartialBy, 'address'> & + ScopeKeyParameter +> + +export function getTransactionCountQueryOptions( + config: config, + options: GetTransactionCountOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { address, scopeKey: _, ...parameters } = queryKey[1] + if (!address) throw new Error('address is required') + const transactionCount = await getTransactionCount(config, { + ...(parameters as GetTransactionCountParameters), + address, + }) + return transactionCount ?? null + }, + queryKey: getTransactionCountQueryKey(options), + } as const satisfies QueryOptions< + GetTransactionCountQueryFnData, + GetTransactionCountErrorType, + GetTransactionCountData, + GetTransactionCountQueryKey + > +} + +export type GetTransactionCountQueryFnData = + Compute + +export type GetTransactionCountData = GetTransactionCountQueryFnData + +export function getTransactionCountQueryKey( + options: GetTransactionCountOptions = {}, +) { + return ['transactionCount', filterQueryOptions(options)] as const +} + +export type GetTransactionCountQueryKey = ReturnType< + typeof getTransactionCountQueryKey +> diff --git a/packages/core/src/query/getTransactionReceipt.test.ts b/packages/core/src/query/getTransactionReceipt.test.ts new file mode 100644 index 0000000000..7c719b8d87 --- /dev/null +++ b/packages/core/src/query/getTransactionReceipt.test.ts @@ -0,0 +1,42 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getTransactionReceiptQueryOptions } from './getTransactionReceipt.js' + +test('default', () => { + expect( + getTransactionReceiptQueryOptions(config, { + hash: '0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getTransactionReceipt", + { + "hash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getTransactionReceiptQueryOptions(config, { + chainId: chain.mainnet2.id, + hash: '0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "getTransactionReceipt", + { + "chainId": 456, + "hash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getTransactionReceipt.ts b/packages/core/src/query/getTransactionReceipt.ts new file mode 100644 index 0000000000..0d7d559d49 --- /dev/null +++ b/packages/core/src/query/getTransactionReceipt.ts @@ -0,0 +1,60 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetTransactionReceiptErrorType, + type GetTransactionReceiptParameters, + getTransactionReceipt, +} from '../actions/getTransactionReceipt.js' +import type { GetTransactionReceiptReturnType } from '../actions/getTransactionReceipt.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetTransactionReceiptOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +> = Compute< + ExactPartial> & + ScopeKeyParameter +> + +export function getTransactionReceiptQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +>(config: config, options: GetTransactionReceiptOptions = {}) { + return { + queryFn({ queryKey }) { + const { hash, scopeKey: _, ...parameters } = queryKey[1] + if (!hash) throw new Error('hash is required') + return getTransactionReceipt(config, { ...parameters, hash }) + }, + queryKey: getTransactionReceiptQueryKey(options), + } as const satisfies QueryOptions< + GetTransactionReceiptQueryFnData, + GetTransactionReceiptErrorType, + GetTransactionReceiptData, + GetTransactionReceiptQueryKey + > +} +export type GetTransactionReceiptQueryFnData< + config extends Config, + chainId extends config['chains'][number]['id'], +> = GetTransactionReceiptReturnType + +export type GetTransactionReceiptData< + config extends Config, + chainId extends config['chains'][number]['id'], +> = GetTransactionReceiptQueryFnData + +export function getTransactionReceiptQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +>(options: GetTransactionReceiptOptions) { + return ['getTransactionReceipt', filterQueryOptions(options)] as const +} + +export type GetTransactionReceiptQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +> = ReturnType> diff --git a/packages/core/src/query/getWalletClient.test.ts b/packages/core/src/query/getWalletClient.test.ts new file mode 100644 index 0000000000..899b480882 --- /dev/null +++ b/packages/core/src/query/getWalletClient.test.ts @@ -0,0 +1,37 @@ +import { chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { getWalletClientQueryOptions } from './getWalletClient.js' + +test('default', () => { + expect(getWalletClientQueryOptions(config)).toMatchInlineSnapshot(` + { + "gcTime": 0, + "queryFn": [Function], + "queryKey": [ + "walletClient", + { + "connectorUid": undefined, + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + getWalletClientQueryOptions(config, { chainId: chain.mainnet.id }), + ).toMatchInlineSnapshot(` + { + "gcTime": 0, + "queryFn": [Function], + "queryKey": [ + "walletClient", + { + "chainId": 1, + "connectorUid": undefined, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/getWalletClient.ts b/packages/core/src/query/getWalletClient.ts new file mode 100644 index 0000000000..3c64b39a07 --- /dev/null +++ b/packages/core/src/query/getWalletClient.ts @@ -0,0 +1,65 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type GetWalletClientErrorType, + type GetWalletClientParameters, + type GetWalletClientReturnType, + getWalletClient, +} from '../actions/getWalletClient.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type GetWalletClientOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +> = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function getWalletClientQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +>(config: config, options: GetWalletClientOptions = {}) { + return { + gcTime: 0, + async queryFn({ queryKey }) { + const { connector } = options + const { connectorUid: _, scopeKey: _s, ...parameters } = queryKey[1] + return getWalletClient(config, { ...parameters, connector }) + }, + queryKey: getWalletClientQueryKey(options), + } as const satisfies QueryOptions< + GetWalletClientQueryFnData, + GetWalletClientErrorType, + GetWalletClientData, + GetWalletClientQueryKey + > +} + +export type GetWalletClientQueryFnData< + config extends Config, + chainId extends config['chains'][number]['id'], +> = GetWalletClientReturnType + +export type GetWalletClientData< + config extends Config, + chainId extends config['chains'][number]['id'], +> = GetWalletClientQueryFnData + +export function getWalletClientQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +>(options: GetWalletClientOptions = {}) { + const { connector, ...parameters } = options + return [ + 'walletClient', + { ...filterQueryOptions(parameters), connectorUid: connector?.uid }, + ] as const +} + +export type GetWalletClientQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +> = ReturnType> diff --git a/packages/core/src/query/infiniteReadContracts.test-d.ts b/packages/core/src/query/infiniteReadContracts.test-d.ts new file mode 100644 index 0000000000..c76dd3bccc --- /dev/null +++ b/packages/core/src/query/infiniteReadContracts.test-d.ts @@ -0,0 +1,201 @@ +import { abi, config } from '@wagmi/test' +import type { MulticallResponse } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { infiniteReadContractsQueryOptions } from './infiniteReadContracts.js' + +test('default', async () => { + const options = infiniteReadContractsQueryOptions(config, { + cacheKey: 'foo', + contracts(pageParam) { + expectTypeOf(pageParam).toEqualTypeOf(options.initialPageParam) + return [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ] + }, + query: { + initialPageParam: 0, + getNextPageParam(lastPage, allPages, lastPageParam, allPageParams) { + expectTypeOf(lastPage).toEqualTypeOf< + [MulticallResponse, MulticallResponse] + >() + expectTypeOf(allPages).toEqualTypeOf< + [MulticallResponse, MulticallResponse][] + >() + expectTypeOf(lastPageParam).toEqualTypeOf(options.initialPageParam) + expectTypeOf(allPageParams).toEqualTypeOf([options.initialPageParam]) + return lastPageParam + 1 + }, + }, + }) + const result = await options.queryFn({} as any) + expectTypeOf(result).toEqualTypeOf< + [MulticallResponse, MulticallResponse] + >() +}) + +test('allowFailure: false', async () => { + const options = infiniteReadContractsQueryOptions(config, { + allowFailure: false, + cacheKey: 'foo', + contracts(pageParam) { + expectTypeOf(pageParam).toEqualTypeOf(options.initialPageParam) + return [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ] + }, + query: { + initialPageParam: 0, + getNextPageParam(lastPage, allPages, lastPageParam, allPageParams) { + expectTypeOf(lastPage).toEqualTypeOf<[bigint, string]>() + expectTypeOf(allPages).toEqualTypeOf<[bigint, string][]>() + expectTypeOf(lastPageParam).toEqualTypeOf(options.initialPageParam) + expectTypeOf(allPageParams).toEqualTypeOf([options.initialPageParam]) + return lastPageParam + 1 + }, + }, + }) + const result = await options.queryFn({} as any) + expectTypeOf(result).toEqualTypeOf<[bigint, string]>() +}) + +test('initialPageParam', async () => { + const options = infiniteReadContractsQueryOptions(config, { + allowFailure: false, + cacheKey: 'foo', + contracts(pageParam) { + expectTypeOf(pageParam).toEqualTypeOf(options.initialPageParam) + return [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ] + }, + query: { + initialPageParam: 'bar', + getNextPageParam(lastPage, allPages, lastPageParam, allPageParams) { + expectTypeOf(lastPage).toEqualTypeOf<[bigint, string]>() + expectTypeOf(allPages).toEqualTypeOf<[bigint, string][]>() + expectTypeOf(lastPageParam).toEqualTypeOf(options.initialPageParam) + expectTypeOf(allPageParams).toEqualTypeOf([options.initialPageParam]) + return lastPageParam + 1 + }, + }, + }) + const result = await options.queryFn({} as any) + expectTypeOf(result).toEqualTypeOf<[bigint, string]>() +}) + +test('behavior: `contracts` after `getNextPageParam`', async () => { + const options = infiniteReadContractsQueryOptions(config, { + allowFailure: false, + cacheKey: 'foo', + query: { + initialPageParam: 0, + getNextPageParam(lastPage, allPages, lastPageParam, allPageParams) { + expectTypeOf(lastPage).toEqualTypeOf() + expectTypeOf(allPages).toEqualTypeOf() + expectTypeOf(lastPageParam).toEqualTypeOf(options.initialPageParam) + expectTypeOf(allPageParams).toEqualTypeOf([options.initialPageParam]) + return lastPageParam + 1 + }, + }, + contracts(pageParam) { + expectTypeOf(pageParam).toEqualTypeOf(options.initialPageParam) + return [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ] + }, + }) + const result = await options.queryFn({} as any) + expectTypeOf(result).toEqualTypeOf() +}) + +test('overloads', async () => { + const options = infiniteReadContractsQueryOptions(config, { + allowFailure: false, + cacheKey: 'foo', + contracts(pageParam) { + expectTypeOf(pageParam).toEqualTypeOf() + return [ + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + }, + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x'], + }, + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x', '0x'], + }, + ] + }, + query: { + initialPageParam: 0, + getNextPageParam(_, allPages) { + return allPages.length + 1 + }, + }, + }) + + const result = await options.queryFn({} as any) + expectTypeOf(result).toEqualTypeOf< + [ + number, + string, + { + foo: `0x${string}` + bar: `0x${string}` + }, + ] + >() +}) diff --git a/packages/core/src/query/infiniteReadContracts.test.ts b/packages/core/src/query/infiniteReadContracts.test.ts new file mode 100644 index 0000000000..509e984838 --- /dev/null +++ b/packages/core/src/query/infiniteReadContracts.test.ts @@ -0,0 +1,60 @@ +import { abi, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { infiniteReadContractsQueryOptions } from './infiniteReadContracts.js' + +test('default', () => { + expect( + infiniteReadContractsQueryOptions(config, { + allowFailure: true, + batchSize: 1024, + blockNumber: 123n, + blockTag: 'latest', + cacheKey: 'foo', + chainId: 1, + multicallAddress: '0x', + scopeKey: 'bar', + contracts(_pageParam) { + return [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ] + }, + query: { + initialPageParam: 0, + getNextPageParam(_lastPage, _allPages, lastPageParam, _allPageParams) { + return lastPageParam + 1 + }, + }, + }), + ).toMatchInlineSnapshot(` + { + "getNextPageParam": [Function], + "initialPageParam": 0, + "queryFn": [Function], + "queryKey": [ + "infiniteReadContracts", + { + "allowFailure": true, + "batchSize": 1024, + "blockNumber": 123n, + "blockTag": "latest", + "cacheKey": "foo", + "chainId": 1, + "multicallAddress": "0x", + "scopeKey": "bar", + }, + ], + } + `) +}) diff --git a/packages/core/src/query/infiniteReadContracts.ts b/packages/core/src/query/infiniteReadContracts.ts new file mode 100644 index 0000000000..28a8d3f52a --- /dev/null +++ b/packages/core/src/query/infiniteReadContracts.ts @@ -0,0 +1,127 @@ +import type { ContractFunctionParameters } from 'viem' +import { + type ReadContractsErrorType, + type ReadContractsParameters, + type ReadContractsReturnType, + readContracts, +} from '../actions/readContracts.js' +import type { Config } from '../createConfig.js' +import type { + ChainIdParameter, + ScopeKeyParameter, +} from '../types/properties.js' +import type { StrictOmit } from '../types/utils.js' +import type { InfiniteQueryOptions } from './types.js' +import { filterQueryOptions } from './utils.js' + +export type InfiniteReadContractsOptions< + contracts extends readonly unknown[], + allowFailure extends boolean, + pageParam, + config extends Config, +> = { + cacheKey: string + contracts( + pageParam: pageParam, + ): ReadContractsParameters['contracts'] +} & StrictOmit< + ReadContractsParameters, + 'contracts' +> & + ScopeKeyParameter + +export function infiniteReadContractsQueryOptions< + config extends Config, + const contracts extends readonly ContractFunctionParameters[], + allowFailure extends boolean = true, + pageParam = unknown, +>( + config: config, + options: InfiniteReadContractsOptions< + contracts, + allowFailure, + pageParam, + config + > & + ChainIdParameter & + RequiredPageParamsParameters, +) { + return { + ...options.query, + async queryFn({ pageParam, queryKey }) { + const { contracts } = options + const { cacheKey: _, scopeKey: _s, ...parameters } = queryKey[1] + return (await readContracts(config, { + ...parameters, + contracts: contracts(pageParam as any), + })) as ReadContractsReturnType + }, + queryKey: infiniteReadContractsQueryKey(options), + } as const satisfies InfiniteQueryOptions< + InfiniteReadContractsQueryFnData, + ReadContractsErrorType, + InfiniteReadContractsData, + InfiniteReadContractsData, + InfiniteReadContractsQueryKey, + pageParam + > +} + +type RequiredPageParamsParameters< + contracts extends readonly unknown[], + allowFailure extends boolean, + pageParam, +> = { + query: { + initialPageParam: pageParam + getNextPageParam( + lastPage: InfiniteReadContractsQueryFnData, + allPages: InfiniteReadContractsQueryFnData[], + lastPageParam: pageParam, + allPageParams: pageParam[], + ): pageParam | undefined | null + } +} + +export type InfiniteReadContractsQueryFnData< + contracts extends readonly unknown[], + allowFailure extends boolean, +> = ReadContractsReturnType + +export type InfiniteReadContractsData< + contracts extends readonly unknown[], + allowFailure extends boolean, +> = InfiniteReadContractsQueryFnData + +export function infiniteReadContractsQueryKey< + config extends Config, + const contracts extends readonly unknown[], + allowFailure extends boolean, + pageParam, +>( + options: InfiniteReadContractsOptions< + contracts, + allowFailure, + pageParam, + config + > & + ChainIdParameter & + RequiredPageParamsParameters, +) { + const { contracts: _, query: _q, ...parameters } = options + return ['infiniteReadContracts', filterQueryOptions(parameters)] as const +} + +export type InfiniteReadContractsQueryKey< + contracts extends readonly unknown[], + allowFailure extends boolean, + pageParam, + config extends Config, +> = ReturnType< + typeof infiniteReadContractsQueryKey< + config, + contracts, + allowFailure, + pageParam + > +> diff --git a/packages/core/src/query/prepareTransactionRequest.test.ts b/packages/core/src/query/prepareTransactionRequest.test.ts new file mode 100644 index 0000000000..d33c156be4 --- /dev/null +++ b/packages/core/src/query/prepareTransactionRequest.test.ts @@ -0,0 +1,241 @@ +import { accounts, chain, config } from '@wagmi/test' +import { parseEther, parseGwei } from 'viem' +import { privateKeyToAccount } from 'viem/accounts' +import { expect, test } from 'vitest' + +import { prepareTransactionRequestQueryOptions } from './prepareTransactionRequest.js' + +const targetAccount = accounts[0] + +test('default', () => { + expect( + prepareTransactionRequestQueryOptions(config, { + to: targetAccount, + value: parseEther('1'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "prepareTransactionRequest", + { + "to": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "value": 1000000000000000000n, + }, + ], + } + `) +}) + +test('parameters: account', () => { + expect( + prepareTransactionRequestQueryOptions(config, { + account: privateKeyToAccount( + '0x0123456789012345678901234567890123456789012345678901234567890123', + ), + to: targetAccount, + value: parseEther('1'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "prepareTransactionRequest", + { + "account": { + "address": "0x14791697260E4c9A71f18484C9f997B308e59325", + "nonceManager": undefined, + "publicKey": "0x046655feed4d214c261e0a6b554395596f1f1476a77d999560e5a8df9b8a1a3515217e88dd05e938efdd71b2cce322bf01da96cd42087b236e8f5043157a9c068e", + "sign": [Function], + "signAuthorization": [Function], + "signMessage": [Function], + "signTransaction": [Function], + "signTypedData": [Function], + "source": "privateKey", + "type": "local", + }, + "to": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "value": 1000000000000000000n, + }, + ], + } + `) +}) + +test('parameters: data', () => { + expect( + prepareTransactionRequestQueryOptions(config, { + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: targetAccount, + value: parseEther('1'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "prepareTransactionRequest", + { + "data": "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2", + "to": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "value": 1000000000000000000n, + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + prepareTransactionRequestQueryOptions(config, { + chainId: chain.mainnet2.id, + to: targetAccount, + value: parseEther('1'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "prepareTransactionRequest", + { + "chainId": 456, + "to": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "value": 1000000000000000000n, + }, + ], + } + `) +}) + +test('parameters: nonce', () => { + expect( + prepareTransactionRequestQueryOptions(config, { + nonce: 5, + to: targetAccount, + value: parseEther('1'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "prepareTransactionRequest", + { + "nonce": 5, + "to": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "value": 1000000000000000000n, + }, + ], + } + `) +}) + +test('parameters: gasPrice', () => { + expect( + prepareTransactionRequestQueryOptions(config, { + gasPrice: parseGwei('10'), + to: targetAccount, + value: parseEther('1'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "prepareTransactionRequest", + { + "gasPrice": 10000000000n, + "to": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "value": 1000000000000000000n, + }, + ], + } + `) +}) + +test('parameters: maxFeePerGas', () => { + expect( + prepareTransactionRequestQueryOptions(config, { + maxFeePerGas: parseGwei('100'), + to: targetAccount, + value: parseEther('1'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "prepareTransactionRequest", + { + "maxFeePerGas": 100000000000n, + "to": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "value": 1000000000000000000n, + }, + ], + } + `) +}) + +test('parameters: maxPriorityFeePerGas', () => { + expect( + prepareTransactionRequestQueryOptions(config, { + maxPriorityFeePerGas: parseGwei('5'), + to: targetAccount, + value: parseEther('1'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "prepareTransactionRequest", + { + "maxPriorityFeePerGas": 5000000000n, + "to": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "value": 1000000000000000000n, + }, + ], + } + `) +}) + +test('parameters: type', () => { + expect( + prepareTransactionRequestQueryOptions(config, { + type: 'eip1559', + to: targetAccount, + value: parseEther('1'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "prepareTransactionRequest", + { + "to": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "eip1559", + "value": 1000000000000000000n, + }, + ], + } + `) +}) + +test('parameters: parameters', () => { + expect( + prepareTransactionRequestQueryOptions(config, { + parameters: ['gas'], + to: targetAccount, + value: parseEther('1'), + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "prepareTransactionRequest", + { + "parameters": [ + "gas", + ], + "to": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "value": 1000000000000000000n, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/prepareTransactionRequest.ts b/packages/core/src/query/prepareTransactionRequest.ts new file mode 100644 index 0000000000..5ed4b419fa --- /dev/null +++ b/packages/core/src/query/prepareTransactionRequest.ts @@ -0,0 +1,101 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import type { PrepareTransactionRequestRequest as viem_PrepareTransactionRequestRequest } from 'viem' + +import { + type PrepareTransactionRequestErrorType, + type PrepareTransactionRequestParameters, + type PrepareTransactionRequestReturnType, + prepareTransactionRequest, +} from '../actions/prepareTransactionRequest.js' +import type { Config } from '../createConfig.js' +import type { SelectChains } from '../types/chain.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { UnionExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type PrepareTransactionRequestOptions< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, + request extends viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + >, +> = UnionExactPartial< + PrepareTransactionRequestParameters +> & + ScopeKeyParameter + +export function prepareTransactionRequestQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, + request extends viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + >, +>( + config: config, + options: PrepareTransactionRequestOptions< + config, + chainId, + request + > = {} as any, +) { + return { + queryFn({ queryKey }) { + const { scopeKey: _, to, ...parameters } = queryKey[1] + if (!to) throw new Error('to is required') + return prepareTransactionRequest(config, { + to, + ...(parameters as any), + }) as unknown as Promise< + PrepareTransactionRequestQueryFnData + > + }, + queryKey: prepareTransactionRequestQueryKey(options), + } as const satisfies QueryOptions< + PrepareTransactionRequestQueryFnData, + PrepareTransactionRequestErrorType, + PrepareTransactionRequestData, + PrepareTransactionRequestQueryKey + > +} +export type PrepareTransactionRequestQueryFnData< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, + request extends viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + >, +> = PrepareTransactionRequestReturnType + +export type PrepareTransactionRequestData< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, + request extends viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + >, +> = PrepareTransactionRequestQueryFnData + +export function prepareTransactionRequestQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, + request extends viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + >, +>(options: PrepareTransactionRequestOptions) { + return ['prepareTransactionRequest', filterQueryOptions(options)] as const +} + +export type PrepareTransactionRequestQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, + request extends viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + >, +> = ReturnType< + typeof prepareTransactionRequestQueryKey +> diff --git a/packages/core/src/query/readContract.test-d.ts b/packages/core/src/query/readContract.test-d.ts new file mode 100644 index 0000000000..286b8819c7 --- /dev/null +++ b/packages/core/src/query/readContract.test-d.ts @@ -0,0 +1,15 @@ +import { abi, config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { readContractQueryOptions } from './readContract.js' + +test('default', async () => { + const options = readContractQueryOptions(config, { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }) + const result = await options.queryFn({} as any) + expectTypeOf(result).toEqualTypeOf() +}) diff --git a/packages/core/src/query/readContract.test.ts b/packages/core/src/query/readContract.test.ts new file mode 100644 index 0000000000..6c17b849ab --- /dev/null +++ b/packages/core/src/query/readContract.test.ts @@ -0,0 +1,29 @@ +import { abi, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { readContractQueryOptions } from './readContract.js' + +test('default', () => { + expect( + readContractQueryOptions(config, { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "readContract", + { + "address": "0x", + "args": [ + "0x", + ], + "functionName": "balanceOf", + }, + ], + } + `) +}) diff --git a/packages/core/src/query/readContract.ts b/packages/core/src/query/readContract.ts new file mode 100644 index 0000000000..52c586665f --- /dev/null +++ b/packages/core/src/query/readContract.ts @@ -0,0 +1,93 @@ +import type { QueryOptions } from '@tanstack/query-core' +import type { Abi, ContractFunctionArgs, ContractFunctionName } from 'viem' + +import { + type ReadContractErrorType, + type ReadContractParameters, + type ReadContractReturnType, + readContract, +} from '../actions/readContract.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { UnionExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type ReadContractOptions< + abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs, + config extends Config, +> = UnionExactPartial> & + ScopeKeyParameter + +export function readContractQueryOptions< + config extends Config, + const abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs, +>( + config: config, + options: ReadContractOptions = {} as any, +) { + return { + // TODO: Support `signal` once Viem actions allow passthrough + // https://tkdodo.eu/blog/why-you-want-react-query#bonus-cancellation + async queryFn({ queryKey }) { + const abi = options.abi as Abi + if (!abi) throw new Error('abi is required') + + const { functionName, scopeKey: _, ...parameters } = queryKey[1] + const addressOrCodeParams = (() => { + const params = queryKey[1] as unknown as ReadContractParameters + if (params.address) return { address: params.address } + if (params.code) return { code: params.code } + throw new Error('address or code is required') + })() + + if (!functionName) throw new Error('functionName is required') + + return readContract(config, { + abi, + functionName, + args: parameters.args as readonly unknown[], + ...addressOrCodeParams, + ...parameters, + }) as Promise> + }, + queryKey: readContractQueryKey(options as any) as any, + } as const satisfies QueryOptions< + ReadContractQueryFnData, + ReadContractErrorType, + ReadContractData, + ReadContractQueryKey + > +} + +export type ReadContractQueryFnData< + abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs, +> = ReadContractReturnType + +export type ReadContractData< + abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs, +> = ReadContractQueryFnData + +export function readContractQueryKey< + config extends Config, + const abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs, +>(options: ReadContractOptions = {} as any) { + const { abi: _, ...rest } = options + return ['readContract', filterQueryOptions(rest)] as const +} + +export type ReadContractQueryKey< + abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs, + config extends Config, +> = ReturnType> diff --git a/packages/core/src/query/readContracts.test-d.ts b/packages/core/src/query/readContracts.test-d.ts new file mode 100644 index 0000000000..b6236e191b --- /dev/null +++ b/packages/core/src/query/readContracts.test-d.ts @@ -0,0 +1,58 @@ +import { abi, config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { readContractsQueryOptions } from './readContracts.js' + +test('default', async () => { + const options = readContractsQueryOptions(config, { + contracts: [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ], + }) + const result = await options.queryFn({} as any) + expectTypeOf(result).toEqualTypeOf< + [ + ( + | { error: Error; result?: undefined; status: 'failure' } + | { error?: undefined; result: bigint; status: 'success' } + ), + ( + | { error: Error; result?: undefined; status: 'failure' } + | { error?: undefined; result: string; status: 'success' } + ), + ] + >() +}) + +test('allowFailure: false', async () => { + const options = readContractsQueryOptions(config, { + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ], + }) + const result = await options.queryFn({} as any) + expectTypeOf(result).toEqualTypeOf<[bigint, string]>() +}) diff --git a/packages/core/src/query/readContracts.test.ts b/packages/core/src/query/readContracts.test.ts new file mode 100644 index 0000000000..755b80c202 --- /dev/null +++ b/packages/core/src/query/readContracts.test.ts @@ -0,0 +1,38 @@ +import { abi, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { readContractsQueryOptions } from './readContracts.js' + +test('default', () => { + expect( + readContractsQueryOptions(config, { + contracts: [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }, + ], + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "readContracts", + { + "contracts": [ + { + "address": "0x", + "args": [ + "0x", + ], + "chainId": undefined, + "functionName": "balanceOf", + }, + ], + }, + ], + } + `) +}) diff --git a/packages/core/src/query/readContracts.ts b/packages/core/src/query/readContracts.ts new file mode 100644 index 0000000000..96bb2163cd --- /dev/null +++ b/packages/core/src/query/readContracts.ts @@ -0,0 +1,98 @@ +import type { QueryOptions } from '@tanstack/query-core' +import type { + ContractFunctionParameters, + MulticallParameters as viem_MulticallParameters, +} from 'viem' + +import { + type ReadContractsErrorType, + type ReadContractsReturnType, + readContracts, +} from '../actions/readContracts.js' +import type { Config } from '../createConfig.js' +import type { ChainIdParameter } from '../types/properties.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type ReadContractsOptions< + contracts extends readonly unknown[], + allowFailure extends boolean, + config extends Config, +> = ExactPartial< + viem_MulticallParameters< + contracts, + allowFailure, + { optional: true; properties: ChainIdParameter } + > +> & + ScopeKeyParameter + +export function readContractsQueryOptions< + config extends Config, + const contracts extends readonly unknown[], + allowFailure extends boolean = true, +>( + config: config, + options: ReadContractsOptions & + ChainIdParameter = {}, +) { + return { + async queryFn({ queryKey }) { + const contracts: ContractFunctionParameters[] = [] + const length = queryKey[1].contracts.length + for (let i = 0; i < length; i++) { + const contract = queryKey[1].contracts[i]! + const abi = (options.contracts?.[i] as ContractFunctionParameters).abi + contracts.push({ ...contract, abi }) + } + const { scopeKey: _, ...parameters } = queryKey[1] + return readContracts(config, { + ...parameters, + contracts, + }) as Promise> + }, + queryKey: readContractsQueryKey(options), + } as const satisfies QueryOptions< + ReadContractsQueryFnData, + ReadContractsErrorType, + ReadContractsData, + ReadContractsQueryKey + > +} + +export type ReadContractsQueryFnData< + contracts extends readonly unknown[], + allowFailure extends boolean, +> = ReadContractsReturnType + +export type ReadContractsData< + contracts extends readonly unknown[], + allowFailure extends boolean, +> = ReadContractsQueryFnData + +export function readContractsQueryKey< + config extends Config, + const contracts extends readonly unknown[], + allowFailure extends boolean, +>( + options: ReadContractsOptions & + ChainIdParameter = {}, +) { + const contracts = [] + for (const contract of (options.contracts ?? + []) as (ContractFunctionParameters & { chainId: number })[]) { + const { abi: _, ...rest } = contract + contracts.push({ ...rest, chainId: rest.chainId ?? options.chainId }) + } + return [ + 'readContracts', + filterQueryOptions({ ...options, contracts }), + ] as const +} + +export type ReadContractsQueryKey< + contracts extends readonly unknown[], + allowFailure extends boolean, + config extends Config, +> = ReturnType> diff --git a/packages/core/src/query/reconnect.test.ts b/packages/core/src/query/reconnect.test.ts new file mode 100644 index 0000000000..fbcb56c3fc --- /dev/null +++ b/packages/core/src/query/reconnect.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { reconnectMutationOptions } from './reconnect.js' + +test('default', () => { + expect(reconnectMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "reconnect", + ], + } + `) +}) diff --git a/packages/core/src/query/reconnect.ts b/packages/core/src/query/reconnect.ts new file mode 100644 index 0000000000..13126cdd34 --- /dev/null +++ b/packages/core/src/query/reconnect.ts @@ -0,0 +1,42 @@ +import type { MutationOptions } from '@tanstack/query-core' + +import { + type ReconnectErrorType, + type ReconnectParameters, + type ReconnectReturnType, + reconnect, +} from '../actions/reconnect.js' +import type { Config } from '../createConfig.js' +import type { Compute } from '../types/utils.js' +import type { Mutate, MutateAsync } from './types.js' + +export function reconnectMutationOptions(config: Config) { + return { + mutationFn(variables) { + return reconnect(config, variables) + }, + mutationKey: ['reconnect'], + } as const satisfies MutationOptions< + ReconnectData, + ReconnectErrorType, + ReconnectVariables + > +} + +export type ReconnectData = Compute + +export type ReconnectVariables = ReconnectParameters | undefined + +export type ReconnectMutate = Mutate< + ReconnectData, + ReconnectErrorType, + ReconnectVariables, + context +> + +export type ReconnectMutateAsync = MutateAsync< + ReconnectData, + ReconnectErrorType, + ReconnectVariables, + context +> diff --git a/packages/core/src/query/sendCalls.test.ts b/packages/core/src/query/sendCalls.test.ts new file mode 100644 index 0000000000..9892aa43e3 --- /dev/null +++ b/packages/core/src/query/sendCalls.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { sendCallsMutationOptions } from './sendCalls.js' + +test('default', () => { + expect(sendCallsMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "sendCalls", + ], + } + `) +}) diff --git a/packages/core/src/query/sendCalls.ts b/packages/core/src/query/sendCalls.ts new file mode 100644 index 0000000000..5d07b89b8f --- /dev/null +++ b/packages/core/src/query/sendCalls.ts @@ -0,0 +1,67 @@ +import type { MutateOptions, MutationOptions } from '@tanstack/query-core' + +import { + type SendCallsErrorType, + type SendCallsParameters, + type SendCallsReturnType, + sendCalls, +} from '../actions/sendCalls.js' +import type { Config } from '../createConfig.js' +import type { Compute } from '../types/utils.js' + +export function sendCallsMutationOptions( + config: config, +) { + return { + mutationFn(variables) { + return sendCalls(config, variables) + }, + mutationKey: ['sendCalls'], + } as const satisfies MutationOptions< + SendCallsData, + SendCallsErrorType, + SendCallsVariables + > +} + +export type SendCallsData = Compute + +export type SendCallsVariables< + config extends Config, + chainId extends config['chains'][number]['id'], + calls extends readonly unknown[] = readonly unknown[], +> = SendCallsParameters + +export type SendCallsMutate = < + const calls extends readonly unknown[], + chainId extends config['chains'][number]['id'], +>( + variables: SendCallsVariables, + options?: + | Compute< + MutateOptions< + SendCallsData, + SendCallsErrorType, + Compute>, + context + > + > + | undefined, +) => void + +export type SendCallsMutateAsync = < + const calls extends readonly unknown[], + chainId extends config['chains'][number]['id'], +>( + variables: SendCallsVariables, + options?: + | Compute< + MutateOptions< + SendCallsData, + SendCallsErrorType, + Compute>, + context + > + > + | undefined, +) => Promise diff --git a/packages/core/src/query/sendTransaction.test.ts b/packages/core/src/query/sendTransaction.test.ts new file mode 100644 index 0000000000..4cda333e71 --- /dev/null +++ b/packages/core/src/query/sendTransaction.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { sendTransactionMutationOptions } from './sendTransaction.js' + +test('default', () => { + expect(sendTransactionMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "sendTransaction", + ], + } + `) +}) diff --git a/packages/core/src/query/sendTransaction.ts b/packages/core/src/query/sendTransaction.ts new file mode 100644 index 0000000000..e6df10fef7 --- /dev/null +++ b/packages/core/src/query/sendTransaction.ts @@ -0,0 +1,65 @@ +import type { MutateOptions, MutationOptions } from '@tanstack/query-core' + +import { + type SendTransactionErrorType, + type SendTransactionParameters, + type SendTransactionReturnType, + sendTransaction, +} from '../actions/sendTransaction.js' +import type { Config } from '../createConfig.js' +import type { Compute } from '../types/utils.js' + +export function sendTransactionMutationOptions( + config: config, +) { + return { + mutationFn(variables) { + return sendTransaction(config, variables) + }, + mutationKey: ['sendTransaction'], + } as const satisfies MutationOptions< + SendTransactionData, + SendTransactionErrorType, + SendTransactionVariables + > +} + +export type SendTransactionData = Compute + +export type SendTransactionVariables< + config extends Config, + chainId extends config['chains'][number]['id'], +> = SendTransactionParameters + +export type SendTransactionMutate = < + chainId extends config['chains'][number]['id'], +>( + variables: SendTransactionVariables, + options?: + | Compute< + MutateOptions< + SendTransactionData, + SendTransactionErrorType, + Compute>, + context + > + > + | undefined, +) => void + +export type SendTransactionMutateAsync< + config extends Config, + context = unknown, +> = ( + variables: SendTransactionVariables, + options?: + | Compute< + MutateOptions< + SendTransactionData, + SendTransactionErrorType, + Compute>, + context + > + > + | undefined, +) => Promise diff --git a/packages/core/src/query/showCallsStatus.test.ts b/packages/core/src/query/showCallsStatus.test.ts new file mode 100644 index 0000000000..ad26ab6171 --- /dev/null +++ b/packages/core/src/query/showCallsStatus.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { showCallsStatusMutationOptions } from './showCallsStatus.js' + +test('default', () => { + expect(showCallsStatusMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "showCallsStatus", + ], + } + `) +}) diff --git a/packages/core/src/query/showCallsStatus.ts b/packages/core/src/query/showCallsStatus.ts new file mode 100644 index 0000000000..86a703cbc8 --- /dev/null +++ b/packages/core/src/query/showCallsStatus.ts @@ -0,0 +1,57 @@ +import type { MutateOptions, MutationOptions } from '@tanstack/query-core' + +import { + type ShowCallsStatusErrorType, + type ShowCallsStatusParameters, + type ShowCallsStatusReturnType, + showCallsStatus, +} from '../actions/showCallsStatus.js' +import type { Config } from '../createConfig.js' +import type { Compute } from '../types/utils.js' + +export function showCallsStatusMutationOptions( + config: config, +) { + return { + mutationFn(variables) { + return showCallsStatus(config, variables) + }, + mutationKey: ['showCallsStatus'], + } as const satisfies MutationOptions< + ShowCallsStatusData, + ShowCallsStatusErrorType, + ShowCallsStatusVariables + > +} + +export type ShowCallsStatusData = Compute + +export type ShowCallsStatusVariables = ShowCallsStatusParameters + +export type ShowCallsStatusMutate = ( + variables: ShowCallsStatusVariables, + options?: + | Compute< + MutateOptions< + ShowCallsStatusData, + ShowCallsStatusErrorType, + Compute, + context + > + > + | undefined, +) => void + +export type ShowCallsStatusMutateAsync = ( + variables: ShowCallsStatusVariables, + options?: + | Compute< + MutateOptions< + ShowCallsStatusData, + ShowCallsStatusErrorType, + Compute, + context + > + > + | undefined, +) => Promise diff --git a/packages/core/src/query/signMessage.test.ts b/packages/core/src/query/signMessage.test.ts new file mode 100644 index 0000000000..b8ad84d0af --- /dev/null +++ b/packages/core/src/query/signMessage.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { signMessageMutationOptions } from './signMessage.js' + +test('default', () => { + expect(signMessageMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "signMessage", + ], + } + `) +}) diff --git a/packages/core/src/query/signMessage.ts b/packages/core/src/query/signMessage.ts new file mode 100644 index 0000000000..d2a4d8156a --- /dev/null +++ b/packages/core/src/query/signMessage.ts @@ -0,0 +1,42 @@ +import type { MutationOptions } from '@tanstack/query-core' + +import { + type SignMessageErrorType, + type SignMessageParameters, + type SignMessageReturnType, + signMessage, +} from '../actions/signMessage.js' +import type { Config } from '../createConfig.js' +import type { Compute } from '../types/utils.js' +import type { Mutate, MutateAsync } from './types.js' + +export function signMessageMutationOptions(config: Config) { + return { + mutationFn(variables) { + return signMessage(config, variables) + }, + mutationKey: ['signMessage'], + } as const satisfies MutationOptions< + SignMessageData, + SignMessageErrorType, + SignMessageVariables + > +} + +export type SignMessageData = SignMessageReturnType + +export type SignMessageVariables = Compute + +export type SignMessageMutate = Mutate< + SignMessageData, + SignMessageErrorType, + SignMessageVariables, + context +> + +export type SignMessageMutateAsync = MutateAsync< + SignMessageData, + SignMessageErrorType, + SignMessageVariables, + context +> diff --git a/packages/core/src/query/signTypedData.test.ts b/packages/core/src/query/signTypedData.test.ts new file mode 100644 index 0000000000..02cbb66480 --- /dev/null +++ b/packages/core/src/query/signTypedData.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { signTypedDataMutationOptions } from './signTypedData.js' + +test('default', () => { + expect(signTypedDataMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "signTypedData", + ], + } + `) +}) diff --git a/packages/core/src/query/signTypedData.ts b/packages/core/src/query/signTypedData.ts new file mode 100644 index 0000000000..fe8eeb0268 --- /dev/null +++ b/packages/core/src/query/signTypedData.ts @@ -0,0 +1,75 @@ +import type { MutateOptions, MutationOptions } from '@tanstack/query-core' + +import type { TypedData } from 'viem' +import { + type SignTypedDataErrorType, + type SignTypedDataParameters, + type SignTypedDataReturnType, + signTypedData, +} from '../actions/signTypedData.js' +import type { Config } from '../createConfig.js' +import type { Compute } from '../types/utils.js' + +export function signTypedDataMutationOptions( + config: config, +) { + return { + mutationFn(variables) { + return signTypedData(config, variables) + }, + mutationKey: ['signTypedData'], + } as const satisfies MutationOptions< + SignTypedDataData, + SignTypedDataErrorType, + SignTypedDataVariables + > +} + +export type SignTypedDataData = Compute + +export type SignTypedDataVariables< + typedData extends TypedData | Record = TypedData, + primaryType extends keyof typedData | 'EIP712Domain' = keyof typedData, + /// + primaryTypes = typedData extends TypedData ? keyof typedData : string, +> = SignTypedDataParameters + +export type SignTypedDataMutate = < + const typedData extends TypedData | Record, + primaryType extends keyof typedData | 'EIP712Domain', +>( + variables: SignTypedDataVariables, + options?: + | MutateOptions< + SignTypedDataData, + SignTypedDataErrorType, + SignTypedDataVariables< + typedData, + primaryType, + // use `primaryType` to make sure it's not union of all possible primary types + primaryType + >, + context + > + | undefined, +) => void + +export type SignTypedDataMutateAsync = < + const typedData extends TypedData | Record, + primaryType extends keyof typedData | 'EIP712Domain', +>( + variables: SignTypedDataVariables, + options?: + | MutateOptions< + SignTypedDataData, + SignTypedDataErrorType, + SignTypedDataVariables< + typedData, + primaryType, + // use `primaryType` to make sure it's not union of all possible primary types + primaryType + >, + context + > + | undefined, +) => Promise diff --git a/packages/core/src/query/simulateContract.test-d.ts b/packages/core/src/query/simulateContract.test-d.ts new file mode 100644 index 0000000000..11023e7297 --- /dev/null +++ b/packages/core/src/query/simulateContract.test-d.ts @@ -0,0 +1,81 @@ +import { abi } from '@wagmi/test' +import { http, type Address } from 'viem' +import { celo, mainnet } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { + type SimulateContractOptions, + simulateContractQueryOptions, +} from './simulateContract.js' + +test('chain formatters', () => { + const config = createConfig({ + chains: [mainnet, celo], + transports: { [celo.id]: http(), [mainnet.id]: http() }, + }) + + type Result = SimulateContractOptions< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + (typeof config)['chains'][number]['id'] + > + expectTypeOf().toMatchTypeOf<{ + chainId?: typeof celo.id | typeof mainnet.id | undefined + feeCurrency?: `0x${string}` | undefined + }>() + simulateContractQueryOptions(config, { + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + feeCurrency: '0x', + }) + + type Result2 = SimulateContractOptions< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + typeof celo.id + > + expectTypeOf().toMatchTypeOf<{ + functionName?: 'approve' | 'transfer' | 'transferFrom' | undefined + args?: readonly [Address, Address, bigint] | undefined + feeCurrency?: `0x${string}` | undefined + }>() + simulateContractQueryOptions(config, { + chainId: celo.id, + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + feeCurrency: '0x', + }) + + type Result3 = SimulateContractOptions< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + typeof mainnet.id + > + expectTypeOf().toMatchTypeOf<{ + functionName?: 'approve' | 'transfer' | 'transferFrom' | undefined + args?: readonly [Address, Address, bigint] | undefined + }>() + expectTypeOf().not.toMatchTypeOf<{ + feeCurrency?: `0x${string}` | undefined + }>() + simulateContractQueryOptions(config, { + chainId: mainnet.id, + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/core/src/query/simulateContract.test.ts b/packages/core/src/query/simulateContract.test.ts new file mode 100644 index 0000000000..354e4b0f02 --- /dev/null +++ b/packages/core/src/query/simulateContract.test.ts @@ -0,0 +1,31 @@ +import { abi, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { simulateContractQueryOptions } from './simulateContract.js' + +test('default', () => { + expect( + simulateContractQueryOptions(config, { + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "simulateContract", + { + "address": "0x", + "args": [ + "0x", + "0x", + 123n, + ], + "functionName": "transferFrom", + }, + ], + } + `) +}) diff --git a/packages/core/src/query/simulateContract.ts b/packages/core/src/query/simulateContract.ts new file mode 100644 index 0000000000..c3970999d4 --- /dev/null +++ b/packages/core/src/query/simulateContract.ts @@ -0,0 +1,132 @@ +import type { QueryOptions } from '@tanstack/query-core' +import type { Abi, ContractFunctionArgs, ContractFunctionName } from 'viem' + +import { + type SimulateContractErrorType, + type SimulateContractParameters, + type SimulateContractReturnType, + simulateContract, +} from '../actions/simulateContract.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { UnionExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type SimulateContractOptions< + abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, +> = UnionExactPartial< + SimulateContractParameters +> & + ScopeKeyParameter + +export function simulateContractQueryOptions< + config extends Config, + const abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + chainId extends config['chains'][number]['id'] | undefined, +>( + config: config, + options: SimulateContractOptions< + abi, + functionName, + args, + config, + chainId + > = {} as any, +) { + return { + async queryFn({ queryKey }) { + const { abi, connector } = options + if (!abi) throw new Error('abi is required') + const { scopeKey: _, ...parameters } = queryKey[1] + const { address, functionName } = parameters + if (!address) throw new Error('address is required') + if (!functionName) throw new Error('functionName is required') + return simulateContract(config, { + abi, + connector, + ...(parameters as any), + }) + }, + queryKey: simulateContractQueryKey(options), + } as const satisfies QueryOptions< + SimulateContractQueryFnData, + SimulateContractErrorType, + SimulateContractData, + SimulateContractQueryKey + > +} + +export type SimulateContractQueryFnData< + abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, +> = SimulateContractReturnType + +export type SimulateContractData< + abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, +> = SimulateContractQueryFnData + +export function simulateContractQueryKey< + config extends Config, + abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + chainId extends config['chains'][number]['id'] | undefined, +>( + options: SimulateContractOptions< + abi, + functionName, + args, + config, + chainId + > = {} as any, +) { + const { abi: _, connector: _c, ...rest } = options + return ['simulateContract', filterQueryOptions(rest)] as const +} + +export type SimulateContractQueryKey< + abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + config extends Config, + chainId extends config['chains'][number]['id'] | undefined, +> = ReturnType< + typeof simulateContractQueryKey +> diff --git a/packages/core/src/query/switchAccount.test.ts b/packages/core/src/query/switchAccount.test.ts new file mode 100644 index 0000000000..25a7066c61 --- /dev/null +++ b/packages/core/src/query/switchAccount.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { switchAccountMutationOptions } from './switchAccount.js' + +test('default', () => { + expect(switchAccountMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "switchAccount", + ], + } + `) +}) diff --git a/packages/core/src/query/switchAccount.ts b/packages/core/src/query/switchAccount.ts new file mode 100644 index 0000000000..29a10b2ce8 --- /dev/null +++ b/packages/core/src/query/switchAccount.ts @@ -0,0 +1,52 @@ +import type { MutationOptions } from '@tanstack/query-core' + +import { + type SwitchAccountErrorType, + type SwitchAccountParameters, + type SwitchAccountReturnType, + switchAccount, +} from '../actions/switchAccount.js' +import type { Config } from '../createConfig.js' +import type { Compute } from '../types/utils.js' +import type { Mutate, MutateAsync } from './types.js' + +export function switchAccountMutationOptions( + config: config, +) { + return { + mutationFn(variables) { + return switchAccount(config, variables) + }, + mutationKey: ['switchAccount'], + } as const satisfies MutationOptions< + SwitchAccountData, + SwitchAccountErrorType, + SwitchAccountVariables + > +} + +export type SwitchAccountData = Compute< + SwitchAccountReturnType +> + +export type SwitchAccountVariables = Compute + +export type SwitchAccountMutate< + config extends Config, + context = unknown, +> = Mutate< + SwitchAccountData, + SwitchAccountErrorType, + SwitchAccountVariables, + context +> + +export type SwitchAccountMutateAsync< + config extends Config, + context = unknown, +> = MutateAsync< + SwitchAccountData, + SwitchAccountErrorType, + SwitchAccountVariables, + context +> diff --git a/packages/core/src/query/switchChain.test.ts b/packages/core/src/query/switchChain.test.ts new file mode 100644 index 0000000000..09a4277c20 --- /dev/null +++ b/packages/core/src/query/switchChain.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { switchChainMutationOptions } from './switchChain.js' + +test('default', () => { + expect(switchChainMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "switchChain", + ], + } + `) +}) diff --git a/packages/core/src/query/switchChain.ts b/packages/core/src/query/switchChain.ts new file mode 100644 index 0000000000..1924ca8429 --- /dev/null +++ b/packages/core/src/query/switchChain.ts @@ -0,0 +1,67 @@ +import type { MutateOptions, MutationOptions } from '@tanstack/query-core' + +import { + type SwitchChainErrorType, + type SwitchChainParameters, + type SwitchChainReturnType, + switchChain, +} from '../actions/switchChain.js' +import type { Config } from '../createConfig.js' +import type { Compute } from '../types/utils.js' + +export function switchChainMutationOptions( + config: config, +) { + return { + mutationFn(variables) { + return switchChain(config, variables) + }, + mutationKey: ['switchChain'], + } as const satisfies MutationOptions< + SwitchChainData, + SwitchChainErrorType, + SwitchChainVariables + > +} + +export type SwitchChainData< + config extends Config, + chainId extends config['chains'][number]['id'], +> = Compute> + +export type SwitchChainVariables< + config extends Config, + chainId extends config['chains'][number]['id'], +> = Compute> + +export type SwitchChainMutate = < + chainId extends config['chains'][number]['id'], +>( + variables: SwitchChainVariables, + options?: + | Compute< + MutateOptions< + SwitchChainData, + SwitchChainErrorType, + Compute>, + context + > + > + | undefined, +) => void + +export type SwitchChainMutateAsync = < + chainId extends config['chains'][number]['id'], +>( + variables: SwitchChainVariables, + options?: + | Compute< + MutateOptions< + SwitchChainData, + SwitchChainErrorType, + Compute>, + context + > + > + | undefined, +) => Promise> diff --git a/packages/core/src/query/types.ts b/packages/core/src/query/types.ts new file mode 100644 index 0000000000..6a279d52d5 --- /dev/null +++ b/packages/core/src/query/types.ts @@ -0,0 +1,84 @@ +import type { + DefaultError, + InfiniteQueryObserverOptions, + MutateOptions, + QueryFunction, + QueryKey, +} from '@tanstack/query-core' + +import type { Compute, StrictOmit } from '../types/utils.js' + +export type InfiniteQueryOptions< + queryFnData = unknown, + error = DefaultError, + data = queryFnData, + queryData = queryFnData, + queryKey extends QueryKey = QueryKey, + pageParam = unknown, + /// + options extends InfiniteQueryObserverOptions< + queryFnData, + error, + data, + queryData, + queryKey, + pageParam + > = InfiniteQueryObserverOptions< + queryFnData, + error, + data, + queryData, + queryKey, + pageParam + >, +> = Compute< + // `queryFn` doesn't pass through `pageParam` correctly + StrictOmit & { + queryFn?( + context: QueryFunctionContext, + ): options['queryFn'] extends (...args: any) => any + ? ReturnType> + : unknown + } +> + +// `QueryFunctionContext` not exported resulting in TS2742 error so grabbing from `QueryFunction` +type QueryFunctionContext< + TQueryKey extends QueryKey = QueryKey, + TPageParam = never, +> = Parameters>[0] + +export type Mutate< + data = unknown, + error = unknown, + variables = void, + context = unknown, +> = ( + ...args: Parameters, context>> +) => void + +export type MutateAsync< + data = unknown, + error = unknown, + variables = void, + context = unknown, +> = MutateFn, context> + +type MutateFn< + data = unknown, + error = unknown, + variables = void, + context = unknown, +> = undefined extends variables + ? ( + variables?: variables, + options?: + | Compute> + | undefined, + ) => Promise + : ( + variables: variables, + options?: + | Compute> + | undefined, + ) => Promise diff --git a/packages/core/src/query/utils.test.ts b/packages/core/src/query/utils.test.ts new file mode 100644 index 0000000000..920b2e5f37 --- /dev/null +++ b/packages/core/src/query/utils.test.ts @@ -0,0 +1,20 @@ +import { expect, test } from 'vitest' + +import { structuralSharing } from './utils.js' + +test('structuralSharing', () => { + expect( + structuralSharing({ foo: 'bar' }, { foo: 'bar' }), + ).toMatchInlineSnapshot(` + { + "foo": "bar", + } + `) + expect( + structuralSharing({ foo: 'bar' }, { foo: 'baz' }), + ).toMatchInlineSnapshot(` + { + "foo": "baz", + } + `) +}) diff --git a/packages/core/src/query/utils.ts b/packages/core/src/query/utils.ts new file mode 100644 index 0000000000..ab4ea3b989 --- /dev/null +++ b/packages/core/src/query/utils.ts @@ -0,0 +1,73 @@ +import { type QueryKey, replaceEqualDeep } from '@tanstack/query-core' + +export function structuralSharing( + oldData: data | undefined, + newData: data, +): data { + return replaceEqualDeep(oldData, newData) +} + +export function hashFn(queryKey: QueryKey): string { + return JSON.stringify(queryKey, (_, value) => { + if (isPlainObject(value)) + return Object.keys(value) + .sort() + .reduce((result, key) => { + result[key] = value[key] + return result + }, {} as any) + if (typeof value === 'bigint') return value.toString() + return value + }) +} + +// biome-ignore lint/complexity/noBannedTypes: +function isPlainObject(value: any): value is Object { + if (!hasObjectPrototype(value)) { + return false + } + + // If has modified constructor + const ctor = value.constructor + if (typeof ctor === 'undefined') return true + + // If has modified prototype + const prot = ctor.prototype + if (!hasObjectPrototype(prot)) return false + + // If constructor does not have an Object-specific method + // biome-ignore lint/suspicious/noPrototypeBuiltins: + if (!prot.hasOwnProperty('isPrototypeOf')) return false + + // Most likely a plain Object + return true +} + +function hasObjectPrototype(o: any): boolean { + return Object.prototype.toString.call(o) === '[object Object]' +} + +export function filterQueryOptions>( + options: type, +): type { + // destructuring is super fast + // biome-ignore format: no formatting + const { + // import('@tanstack/query-core').QueryOptions + _defaulted, behavior, gcTime, initialData, initialDataUpdatedAt, maxPages, meta, networkMode, queryFn, queryHash, queryKey, queryKeyHashFn, retry, retryDelay, structuralSharing, + + // import('@tanstack/query-core').InfiniteQueryObserverOptions + getPreviousPageParam, getNextPageParam, initialPageParam, + + // import('@tanstack/react-query').UseQueryOptions + _optimisticResults, enabled, notifyOnChangeProps, placeholderData, refetchInterval, refetchIntervalInBackground, refetchOnMount, refetchOnReconnect, refetchOnWindowFocus, retryOnMount, select, staleTime, suspense, throwOnError, + + //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + // wagmi + //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + config, connector, query, + ...rest + } = options + + return rest as type +} diff --git a/packages/core/src/query/verifyMessage.test.ts b/packages/core/src/query/verifyMessage.test.ts new file mode 100644 index 0000000000..ae43f6b07f --- /dev/null +++ b/packages/core/src/query/verifyMessage.test.ts @@ -0,0 +1,104 @@ +import { accounts, chain, config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { verifyMessageQueryOptions } from './verifyMessage.js' + +const address = accounts[0] + +test('default', () => { + expect( + verifyMessageQueryOptions(config, { + address, + message: 'This is a test message for viem!', + signature: + '0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "verifyMessage", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "message": "This is a test message for viem!", + "signature": "0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c", + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + verifyMessageQueryOptions(config, { + chainId: chain.mainnet2.id, + address, + message: 'This is a test message for viem!', + signature: + '0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "verifyMessage", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 456, + "message": "This is a test message for viem!", + "signature": "0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c", + }, + ], + } + `) +}) + +test('parameters: blockNumber', () => { + expect( + verifyMessageQueryOptions(config, { + blockNumber: 1234567890n, + address, + message: 'This is a test message for viem!', + signature: + '0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "verifyMessage", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockNumber": 1234567890n, + "message": "This is a test message for viem!", + "signature": "0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c", + }, + ], + } + `) +}) + +test('parameters: blockTag', () => { + expect( + verifyMessageQueryOptions(config, { + blockTag: 'safe', + address, + message: 'This is a test message for viem!', + signature: + '0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "verifyMessage", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockTag": "safe", + "message": "This is a test message for viem!", + "signature": "0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c", + }, + ], + } + `) +}) diff --git a/packages/core/src/query/verifyMessage.ts b/packages/core/src/query/verifyMessage.ts new file mode 100644 index 0000000000..d827e64b2b --- /dev/null +++ b/packages/core/src/query/verifyMessage.ts @@ -0,0 +1,56 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type VerifyMessageErrorType, + type VerifyMessageParameters, + type VerifyMessageReturnType, + verifyMessage, +} from '../actions/verifyMessage.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type VerifyMessageOptions = Compute< + ExactPartial> & ScopeKeyParameter +> + +export function verifyMessageQueryOptions( + config: config, + options: VerifyMessageOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { address, message, signature } = queryKey[1] + if (!address || !message || !signature) + throw new Error('address, message, and signature are required') + + const { scopeKey: _, ...parameters } = queryKey[1] + + const verified = await verifyMessage( + config, + parameters as VerifyMessageParameters, + ) + return verified ?? null + }, + queryKey: verifyMessageQueryKey(options), + } as const satisfies QueryOptions< + VerifyMessageQueryFnData, + VerifyMessageErrorType, + VerifyMessageData, + VerifyMessageQueryKey + > +} +export type VerifyMessageQueryFnData = VerifyMessageReturnType + +export type VerifyMessageData = VerifyMessageQueryFnData + +export function verifyMessageQueryKey( + options: VerifyMessageOptions, +) { + return ['verifyMessage', filterQueryOptions(options)] as const +} + +export type VerifyMessageQueryKey = ReturnType< + typeof verifyMessageQueryKey +> diff --git a/packages/core/src/query/verifyTypedData.test.ts b/packages/core/src/query/verifyTypedData.test.ts new file mode 100644 index 0000000000..f4145099ce --- /dev/null +++ b/packages/core/src/query/verifyTypedData.test.ts @@ -0,0 +1,284 @@ +import { accounts, chain, config, typedData } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { verifyTypedDataQueryOptions } from './verifyTypedData.js' + +const address = accounts[0] + +test('default', () => { + expect( + verifyTypedDataQueryOptions(config, { + address, + ...typedData.basic, + primaryType: 'Mail', + signature: + '0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "verifyTypedData", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "domain": { + "chainId": 1, + "name": "Ether Mail", + "verifyingContract": "0x0000000000000000000000000000000000000000", + "version": "1", + }, + "message": { + "contents": "Hello, Bob!", + "from": { + "name": "Cow", + "wallet": "0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826", + }, + "to": { + "name": "Bob", + "wallet": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", + }, + }, + "primaryType": "Mail", + "signature": "0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c", + "types": { + "Mail": [ + { + "name": "from", + "type": "Person", + }, + { + "name": "to", + "type": "Person", + }, + { + "name": "contents", + "type": "string", + }, + ], + "Person": [ + { + "name": "name", + "type": "string", + }, + { + "name": "wallet", + "type": "address", + }, + ], + }, + }, + ], + } + `) +}) + +test('parameters: chainId', () => { + expect( + verifyTypedDataQueryOptions(config, { + ...typedData.basic, + domain: { + ...typedData.basic.domain, + chainId: chain.mainnet2.id, + }, + chainId: chain.mainnet2.id, + address, + primaryType: 'Mail', + signature: + '0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "verifyTypedData", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 456, + "domain": { + "chainId": 456, + "name": "Ether Mail", + "verifyingContract": "0x0000000000000000000000000000000000000000", + "version": "1", + }, + "message": { + "contents": "Hello, Bob!", + "from": { + "name": "Cow", + "wallet": "0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826", + }, + "to": { + "name": "Bob", + "wallet": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", + }, + }, + "primaryType": "Mail", + "signature": "0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c", + "types": { + "Mail": [ + { + "name": "from", + "type": "Person", + }, + { + "name": "to", + "type": "Person", + }, + { + "name": "contents", + "type": "string", + }, + ], + "Person": [ + { + "name": "name", + "type": "string", + }, + { + "name": "wallet", + "type": "address", + }, + ], + }, + }, + ], + } + `) +}) + +test('parameters: blockNumber', () => { + expect( + verifyTypedDataQueryOptions(config, { + blockNumber: 1234567890n, + address, + ...typedData.basic, + primaryType: 'Mail', + signature: + '0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "verifyTypedData", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockNumber": 1234567890n, + "domain": { + "chainId": 1, + "name": "Ether Mail", + "verifyingContract": "0x0000000000000000000000000000000000000000", + "version": "1", + }, + "message": { + "contents": "Hello, Bob!", + "from": { + "name": "Cow", + "wallet": "0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826", + }, + "to": { + "name": "Bob", + "wallet": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", + }, + }, + "primaryType": "Mail", + "signature": "0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c", + "types": { + "Mail": [ + { + "name": "from", + "type": "Person", + }, + { + "name": "to", + "type": "Person", + }, + { + "name": "contents", + "type": "string", + }, + ], + "Person": [ + { + "name": "name", + "type": "string", + }, + { + "name": "wallet", + "type": "address", + }, + ], + }, + }, + ], + } + `) +}) + +test('parameters: blockTag', () => { + expect( + verifyTypedDataQueryOptions(config, { + blockTag: 'pending', + address, + ...typedData.basic, + primaryType: 'Mail', + signature: + '0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "verifyTypedData", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockTag": "pending", + "domain": { + "chainId": 1, + "name": "Ether Mail", + "verifyingContract": "0x0000000000000000000000000000000000000000", + "version": "1", + }, + "message": { + "contents": "Hello, Bob!", + "from": { + "name": "Cow", + "wallet": "0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826", + }, + "to": { + "name": "Bob", + "wallet": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", + }, + }, + "primaryType": "Mail", + "signature": "0xefd5fb29a274ea6682673d8b3caa9263e936d48d486e5df68893003e0a76496439594d12245008c6fba1c8e3ef28241cffe1bef27ff6bca487b167f261f329251c", + "types": { + "Mail": [ + { + "name": "from", + "type": "Person", + }, + { + "name": "to", + "type": "Person", + }, + { + "name": "contents", + "type": "string", + }, + ], + "Person": [ + { + "name": "name", + "type": "string", + }, + { + "name": "wallet", + "type": "address", + }, + ], + }, + }, + ], + } + `) +}) diff --git a/packages/core/src/query/verifyTypedData.ts b/packages/core/src/query/verifyTypedData.ts new file mode 100644 index 0000000000..d7d3970b7e --- /dev/null +++ b/packages/core/src/query/verifyTypedData.ts @@ -0,0 +1,82 @@ +import type { QueryOptions } from '@tanstack/query-core' +import type { TypedData } from 'viem' + +import { + type VerifyTypedDataErrorType, + type VerifyTypedDataParameters, + type VerifyTypedDataReturnType, + verifyTypedData, +} from '../actions/verifyTypedData.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type VerifyTypedDataOptions< + typedData extends TypedData | Record, + primaryType extends keyof typedData | 'EIP712Domain', + config extends Config, +> = ExactPartial> & + ScopeKeyParameter + +export function verifyTypedDataQueryOptions< + config extends Config, + const typedData extends TypedData | Record, + primaryType extends keyof typedData | 'EIP712Domain', +>( + config: config, + options: VerifyTypedDataOptions = {} as any, +) { + return { + async queryFn({ queryKey }) { + const { + address, + message, + primaryType, + signature, + types, + scopeKey: _, + ...parameters + } = queryKey[1] + if (!address) throw new Error('address is required') + if (!message) throw new Error('message is required') + if (!primaryType) throw new Error('primaryType is required') + if (!signature) throw new Error('signature is required') + if (!types) throw new Error('types is required') + + const verified = await verifyTypedData(config, { + ...parameters, + address, + message, + primaryType, + signature, + types, + } as VerifyTypedDataParameters) + return verified ?? null + }, + queryKey: verifyTypedDataQueryKey(options), + } as const satisfies QueryOptions< + VerifyTypedDataQueryFnData, + VerifyTypedDataErrorType, + VerifyTypedDataData, + VerifyTypedDataQueryKey + > +} + +export type VerifyTypedDataQueryFnData = VerifyTypedDataReturnType + +export type VerifyTypedDataData = VerifyTypedDataQueryFnData + +export function verifyTypedDataQueryKey< + config extends Config, + const typedData extends TypedData | Record, + primaryType extends keyof typedData | 'EIP712Domain', +>(options: VerifyTypedDataOptions) { + return ['verifyTypedData', filterQueryOptions(options)] as const +} + +export type VerifyTypedDataQueryKey< + typedData extends TypedData | Record, + primaryType extends keyof typedData | 'EIP712Domain', + config extends Config, +> = ReturnType> diff --git a/packages/core/src/query/waitForCallsStatus.test.ts b/packages/core/src/query/waitForCallsStatus.test.ts new file mode 100644 index 0000000000..215ec72759 --- /dev/null +++ b/packages/core/src/query/waitForCallsStatus.test.ts @@ -0,0 +1,23 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { waitForCallsStatusQueryOptions } from './waitForCallsStatus.js' + +test('default', () => { + expect( + waitForCallsStatusQueryOptions(config, { + id: '0x0000000000000000000000000000000000000000', + }), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "callsStatus", + { + "id": "0x0000000000000000000000000000000000000000", + }, + ], + "retry": [Function], + } + `) +}) diff --git a/packages/core/src/query/waitForCallsStatus.ts b/packages/core/src/query/waitForCallsStatus.ts new file mode 100644 index 0000000000..197c279e93 --- /dev/null +++ b/packages/core/src/query/waitForCallsStatus.ts @@ -0,0 +1,53 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type WaitForCallsStatusErrorType, + type WaitForCallsStatusParameters, + type WaitForCallsStatusReturnType, + waitForCallsStatus, +} from '../actions/waitForCallsStatus.js' +import type { Config } from '../createConfig.js' +import { ConnectorNotConnectedError } from '../errors/config.js' +import { filterQueryOptions } from '../query/utils.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, PartialBy } from '../types/utils.js' + +export type WaitForCallsStatusOptions = Compute< + PartialBy & ScopeKeyParameter +> + +export function waitForCallsStatusQueryOptions( + config: config, + options: WaitForCallsStatusOptions, +) { + return { + async queryFn({ queryKey }) { + const { scopeKey: _, id, ...parameters } = queryKey[1] + if (!id) throw new Error('id is required') + const status = await waitForCallsStatus(config, { ...parameters, id }) + return status + }, + queryKey: waitForCallsStatusQueryKey(options), + retry(failureCount, error) { + if (error instanceof ConnectorNotConnectedError) return false + return failureCount < 3 + }, + } as const satisfies QueryOptions< + WaitForCallsStatusQueryFnData, + WaitForCallsStatusErrorType, + WaitForCallsStatusData, + WaitForCallsStatusQueryKey + > +} + +export type WaitForCallsStatusQueryFnData = WaitForCallsStatusReturnType + +export type WaitForCallsStatusData = WaitForCallsStatusQueryFnData + +export function waitForCallsStatusQueryKey(options: WaitForCallsStatusOptions) { + return ['callsStatus', filterQueryOptions(options)] as const +} + +export type WaitForCallsStatusQueryKey = ReturnType< + typeof waitForCallsStatusQueryKey +> diff --git a/packages/core/src/query/waitForTransactionReceipt.test.ts b/packages/core/src/query/waitForTransactionReceipt.test.ts new file mode 100644 index 0000000000..1877e1bfeb --- /dev/null +++ b/packages/core/src/query/waitForTransactionReceipt.test.ts @@ -0,0 +1,18 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { waitForTransactionReceiptQueryOptions } from './waitForTransactionReceipt.js' + +test('default', () => { + expect( + waitForTransactionReceiptQueryOptions(config, {}), + ).toMatchInlineSnapshot(` + { + "queryFn": [Function], + "queryKey": [ + "waitForTransactionReceipt", + {}, + ], + } + `) +}) diff --git a/packages/core/src/query/waitForTransactionReceipt.ts b/packages/core/src/query/waitForTransactionReceipt.ts new file mode 100644 index 0000000000..3507dabeb8 --- /dev/null +++ b/packages/core/src/query/waitForTransactionReceipt.ts @@ -0,0 +1,71 @@ +import type { QueryOptions } from '@tanstack/query-core' + +import { + type WaitForTransactionReceiptErrorType, + type WaitForTransactionReceiptParameters, + type WaitForTransactionReceiptReturnType, + waitForTransactionReceipt, +} from '../actions/waitForTransactionReceipt.js' +import type { Config } from '../createConfig.js' +import type { ScopeKeyParameter } from '../types/properties.js' +import type { Compute, ExactPartial } from '../types/utils.js' +import { filterQueryOptions } from './utils.js' + +export type WaitForTransactionReceiptOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +> = Compute< + ExactPartial> & + ScopeKeyParameter +> + +export function waitForTransactionReceiptQueryOptions< + config extends Config, + chainId extends config['chains'][number]['id'], +>( + config: config, + options: WaitForTransactionReceiptOptions = {}, +) { + return { + async queryFn({ queryKey }) { + const { hash, ...parameters } = queryKey[1] + if (!hash) throw new Error('hash is required') + return waitForTransactionReceipt(config, { + ...parameters, + onReplaced: options.onReplaced, + hash, + }) as unknown as Promise< + WaitForTransactionReceiptReturnType + > + }, + queryKey: waitForTransactionReceiptQueryKey(options), + } as const satisfies QueryOptions< + WaitForTransactionReceiptQueryFnData, + WaitForTransactionReceiptErrorType, + WaitForTransactionReceiptData, + WaitForTransactionReceiptQueryKey + > +} + +export type WaitForTransactionReceiptQueryFnData< + config extends Config, + chainId extends config['chains'][number]['id'], +> = WaitForTransactionReceiptReturnType + +export type WaitForTransactionReceiptData< + config extends Config, + chainId extends config['chains'][number]['id'], +> = WaitForTransactionReceiptQueryFnData + +export function waitForTransactionReceiptQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +>(options: WaitForTransactionReceiptOptions = {}) { + const { onReplaced: _, ...rest } = options + return ['waitForTransactionReceipt', filterQueryOptions(rest)] as const +} + +export type WaitForTransactionReceiptQueryKey< + config extends Config, + chainId extends config['chains'][number]['id'], +> = ReturnType> diff --git a/packages/core/src/query/watchAsset.test.ts b/packages/core/src/query/watchAsset.test.ts new file mode 100644 index 0000000000..b580beadba --- /dev/null +++ b/packages/core/src/query/watchAsset.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { watchAssetMutationOptions } from './watchAsset.js' + +test('default', () => { + expect(watchAssetMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "watchAsset", + ], + } + `) +}) diff --git a/packages/core/src/query/watchAsset.ts b/packages/core/src/query/watchAsset.ts new file mode 100644 index 0000000000..52ab82be60 --- /dev/null +++ b/packages/core/src/query/watchAsset.ts @@ -0,0 +1,42 @@ +import type { MutationOptions } from '@tanstack/query-core' + +import { + type WatchAssetErrorType, + type WatchAssetParameters, + type WatchAssetReturnType, + watchAsset, +} from '../actions/watchAsset.js' +import type { Config } from '../createConfig.js' +import type { Compute } from '../types/utils.js' +import type { Mutate, MutateAsync } from './types.js' + +export function watchAssetMutationOptions(config: Config) { + return { + mutationFn(variables) { + return watchAsset(config, variables) + }, + mutationKey: ['watchAsset'], + } as const satisfies MutationOptions< + WatchAssetData, + WatchAssetErrorType, + WatchAssetVariables + > +} + +export type WatchAssetData = WatchAssetReturnType + +export type WatchAssetVariables = Compute + +export type WatchAssetMutate = Mutate< + WatchAssetData, + WatchAssetErrorType, + WatchAssetVariables, + context +> + +export type WatchAssetMutateAsync = MutateAsync< + WatchAssetData, + WatchAssetErrorType, + WatchAssetVariables, + context +> diff --git a/packages/core/src/query/writeContract.test-d.ts b/packages/core/src/query/writeContract.test-d.ts new file mode 100644 index 0000000000..3c80a83132 --- /dev/null +++ b/packages/core/src/query/writeContract.test-d.ts @@ -0,0 +1,145 @@ +import { http } from 'viem' +import { writeContract } from 'viem/actions' +import { base } from 'viem/chains' +import { test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import type { WriteContractMutate } from './writeContract.js' + +// https://github.com/wevm/wagmi/issues/3981 +test('gh#3981', () => { + const config = createConfig({ + chains: [base], + transports: { + [base.id]: http(), + }, + }) + + const abi = [ + { + type: 'function', + name: 'example1', + inputs: [ + { name: 'exampleName', type: 'address', internalType: 'address' }, + ], + outputs: [], + stateMutability: 'payable', + }, + { + type: 'function', + name: 'example2', + inputs: [ + { name: 'exampleName', type: 'address', internalType: 'address' }, + ], + outputs: [], + stateMutability: 'nonpayable', + }, + ] as const + + const write: WriteContractMutate = () => {} + write({ + abi, + address: '0x...', + functionName: 'example1', + args: ['0x...'], + value: 123n, + }) + write({ + abi: [ + { + type: 'function', + name: 'example1', + inputs: [ + { name: 'exampleName', type: 'address', internalType: 'address' }, + ], + outputs: [], + stateMutability: 'payable', + }, + { + type: 'function', + name: 'example2', + inputs: [ + { name: 'exampleName', type: 'address', internalType: 'address' }, + ], + outputs: [], + stateMutability: 'nonpayable', + }, + ] as const, + address: '0x...', + functionName: 'example1', + args: ['0x...'], + value: 123n, + }) + + write({ + abi, + address: '0x...', + functionName: 'example2', + args: ['0x...'], + // @ts-expect-error + value: 123n, + }) + write({ + abi: [ + { + type: 'function', + name: 'example1', + inputs: [ + { name: 'exampleName', type: 'address', internalType: 'address' }, + ], + outputs: [], + stateMutability: 'payable', + }, + { + type: 'function', + name: 'example2', + inputs: [ + { name: 'exampleName', type: 'address', internalType: 'address' }, + ], + outputs: [], + stateMutability: 'nonpayable', + }, + ], + address: '0x...', + functionName: 'example1', + args: ['0x...'], + value: 123n, + }) + + const client = config.getClient({ chainId: base.id }) + writeContract(client, { + abi, + address: '0x...', + account: '0x...', + functionName: 'example1', + args: ['0x...'], + value: 123n, + }) + writeContract(client, { + abi: [ + { + type: 'function', + name: 'example1', + inputs: [ + { name: 'exampleName', type: 'address', internalType: 'address' }, + ], + outputs: [], + stateMutability: 'payable', + }, + { + type: 'function', + name: 'example2', + inputs: [ + { name: 'exampleName', type: 'address', internalType: 'address' }, + ], + outputs: [], + stateMutability: 'nonpayable', + }, + ] as const, + address: '0x...', + account: '0x...', + functionName: 'example1', + args: ['0x...'], + value: 123n, + }) +}) diff --git a/packages/core/src/query/writeContract.test.ts b/packages/core/src/query/writeContract.test.ts new file mode 100644 index 0000000000..04cde53c76 --- /dev/null +++ b/packages/core/src/query/writeContract.test.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expect, test } from 'vitest' + +import { writeContractMutationOptions } from './writeContract.js' + +test('default', () => { + expect(writeContractMutationOptions(config)).toMatchInlineSnapshot(` + { + "mutationFn": [Function], + "mutationKey": [ + "writeContract", + ], + } + `) +}) diff --git a/packages/core/src/query/writeContract.ts b/packages/core/src/query/writeContract.ts new file mode 100644 index 0000000000..0e368fe40b --- /dev/null +++ b/packages/core/src/query/writeContract.ts @@ -0,0 +1,116 @@ +import type { MutateOptions, MutationOptions } from '@tanstack/query-core' +import type { Abi, ContractFunctionArgs, ContractFunctionName } from 'viem' + +import { + type WriteContractErrorType, + type WriteContractParameters, + type WriteContractReturnType, + writeContract, +} from '../actions/writeContract.js' +import type { Config } from '../createConfig.js' +import type { Compute } from '../types/utils.js' + +export function writeContractMutationOptions( + config: config, +) { + return { + mutationFn(variables) { + return writeContract(config, variables) + }, + mutationKey: ['writeContract'], + } as const satisfies MutationOptions< + WriteContractData, + WriteContractErrorType, + WriteContractVariables< + Abi, + string, + readonly unknown[], + config, + config['chains'][number]['id'] + > + > +} + +export type WriteContractData = Compute + +export type WriteContractVariables< + abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + config extends Config, + chainId extends config['chains'][number]['id'], + /// + allFunctionNames = ContractFunctionName, +> = WriteContractParameters< + abi, + functionName, + args, + config, + chainId, + allFunctionNames +> + +export type WriteContractMutate = < + const abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + chainId extends config['chains'][number]['id'], +>( + variables: WriteContractVariables, + options?: + | MutateOptions< + WriteContractData, + WriteContractErrorType, + WriteContractVariables< + abi, + functionName, + args, + config, + chainId, + // use `functionName` to make sure it's not union of all possible function names + functionName + >, + context + > + | undefined, +) => void + +export type WriteContractMutateAsync< + config extends Config, + context = unknown, +> = < + const abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + chainId extends config['chains'][number]['id'], +>( + variables: WriteContractVariables, + options?: + | MutateOptions< + WriteContractData, + WriteContractErrorType, + WriteContractVariables< + abi, + functionName, + args, + config, + chainId, + // use `functionName` to make sure it's not union of all possible function names + functionName + >, + context + > + | undefined, +) => Promise diff --git a/packages/core/src/transports/connector.test.ts b/packages/core/src/transports/connector.test.ts new file mode 100644 index 0000000000..4b71c2b46b --- /dev/null +++ b/packages/core/src/transports/connector.test.ts @@ -0,0 +1,97 @@ +import { config } from '@wagmi/test' +import { optimism } from 'viem/chains' +import { expect, test } from 'vitest' +import { createStore } from 'zustand' + +import { injected } from '../connectors/injected.js' +import { mock } from '../connectors/mock.js' +import { unstable_connector } from './connector.js' + +const connector = config.connectors[0]! + +test('setup', () => { + expect(unstable_connector(injected)({})).toMatchInlineSnapshot(` + { + "config": { + "key": "connector", + "methods": undefined, + "name": "Connector", + "request": [Function], + "retryCount": 3, + "retryDelay": 150, + "timeout": undefined, + "type": "connector", + }, + "request": [Function], + "value": undefined, + } + `) +}) + +test('behavior: connector type not found', () => { + const transport = unstable_connector({ type: 'foo' })({}) + expect(() => + transport.request({ method: 'eth_chainId' }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ProviderDisconnectedError: The Provider is disconnected from all chains. + + Details: Could not find connector of type "foo" in \`connectors\` passed to \`createConfig\`. + Version: viem@2.29.2] + `) +}) + +test('behavior: provider is disconnected', () => { + const transport = unstable_connector(mock)({ + connectors: createStore(() => [ + { + ...connector, + async getProvider() { + return undefined + }, + }, + ]), + }) + + expect(() => + transport.request({ method: 'eth_chainId' }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ProviderDisconnectedError: The Provider is disconnected from all chains. + + Details: Provider is disconnected. + Version: viem@2.29.2] + `) +}) + +test('behavior: chainId mismatch', () => { + const transport = unstable_connector(mock)({ + chain: optimism, + connectors: createStore(() => [ + { + ...connector, + async getProvider(options = {}) { + if (options.chainId === optimism.id) return connector.getProvider() + return undefined + }, + }, + ]), + }) + + expect(() => + transport.request({ method: 'eth_chainId' }), + ).rejects.toThrowErrorMatchingInlineSnapshot(` + [ChainDisconnectedError: The Provider is not connected to the requested chain. + + Details: The current chain of the connector (id: 1) does not match the target chain for the request (id: 10 – OP Mainnet). + Version: viem@2.29.2] + `) +}) + +test('behavior: request', () => { + const transport = unstable_connector(mock)({ + connectors: createStore(() => [connector]), + }) + + expect( + transport.request({ method: 'eth_chainId' }), + ).resolves.toThrowErrorMatchingInlineSnapshot(`"0x1"`) +}) diff --git a/packages/core/src/transports/connector.ts b/packages/core/src/transports/connector.ts new file mode 100644 index 0000000000..0f03d43188 --- /dev/null +++ b/packages/core/src/transports/connector.ts @@ -0,0 +1,87 @@ +import { + ChainDisconnectedError, + type EIP1193Parameters, + type EIP1193Provider, + type EIP1193RequestFn, + ProviderDisconnectedError, + type TransportConfig, + type WalletRpcSchema, + createTransport, + hexToNumber, + withRetry, + withTimeout, +} from 'viem' + +import type { Connector, Transport } from '../createConfig.js' + +export type ConnectorTransportConfig = { + /** The key of the transport. */ + key?: TransportConfig['key'] | undefined + /** The name of the transport. */ + name?: TransportConfig['name'] | undefined + /** The max number of times to retry. */ + retryCount?: TransportConfig['retryCount'] | undefined + /** The base delay (in ms) between retries. */ + retryDelay?: TransportConfig['retryDelay'] | undefined +} + +export type ConnectorTransport = Transport + +export function unstable_connector( + connector: Pick, + config: ConnectorTransportConfig = {}, +): Transport<'connector'> { + const { type } = connector + const { key = 'connector', name = 'Connector', retryDelay } = config + + return (parameters) => { + const { chain, connectors } = parameters + const retryCount = config.retryCount ?? parameters.retryCount + + const request: EIP1193RequestFn = async ({ method, params }) => { + const connector = connectors?.getState().find((c) => c.type === type) + if (!connector) + throw new ProviderDisconnectedError( + new Error( + `Could not find connector of type "${type}" in \`connectors\` passed to \`createConfig\`.`, + ), + ) + + const provider = (await connector.getProvider({ + chainId: chain?.id, + })) as EIP1193Provider | undefined + if (!provider) + throw new ProviderDisconnectedError( + new Error('Provider is disconnected.'), + ) + + // We are applying a retry & timeout strategy here as some injected wallets (e.g. MetaMask) fail to + // immediately resolve a JSON-RPC request on page load. + const chainId = hexToNumber( + await withRetry(() => + withTimeout(() => provider.request({ method: 'eth_chainId' }), { + timeout: 100, + }), + ), + ) + if (chain && chainId !== chain.id) + throw new ChainDisconnectedError( + new Error( + `The current chain of the connector (id: ${chainId}) does not match the target chain for the request (id: ${chain.id} – ${chain.name}).`, + ), + ) + + const body = { method, params } as EIP1193Parameters + return provider.request(body) + } + + return createTransport({ + key, + name, + request, + retryCount, + retryDelay, + type: 'connector', + }) + } +} diff --git a/packages/core/src/transports/fallback.test.ts b/packages/core/src/transports/fallback.test.ts new file mode 100644 index 0000000000..dcae23cb79 --- /dev/null +++ b/packages/core/src/transports/fallback.test.ts @@ -0,0 +1,63 @@ +import { http } from 'viem' +import { expect, test } from 'vitest' +import { unstable_connector } from './connector.js' +import { fallback } from './fallback.js' + +test('setup', () => { + expect( + fallback([ + unstable_connector({ type: 'injected' }), + http('https://example.com'), + ])({}), + ).toMatchInlineSnapshot(` + { + "config": { + "key": "fallback", + "methods": undefined, + "name": "Fallback", + "request": [Function], + "retryCount": 3, + "retryDelay": 150, + "timeout": undefined, + "type": "fallback", + }, + "request": [Function], + "value": { + "onResponse": [Function], + "transports": [ + { + "config": { + "key": "connector", + "methods": undefined, + "name": "Connector", + "request": [Function], + "retryCount": 0, + "retryDelay": 150, + "timeout": undefined, + "type": "connector", + }, + "request": [Function], + "value": undefined, + }, + { + "config": { + "key": "http", + "methods": undefined, + "name": "HTTP JSON-RPC", + "request": [Function], + "retryCount": 0, + "retryDelay": 150, + "timeout": 10000, + "type": "http", + }, + "request": [Function], + "value": { + "fetchOptions": undefined, + "url": "https://example.com", + }, + }, + ], + }, + } + `) +}) diff --git a/packages/core/src/transports/fallback.ts b/packages/core/src/transports/fallback.ts new file mode 100644 index 0000000000..67069f5de1 --- /dev/null +++ b/packages/core/src/transports/fallback.ts @@ -0,0 +1,10 @@ +import { fallback as viem_fallback } from 'viem' + +import type { Transport } from '../createConfig.js' + +export function fallback( + transports: Transport[], + config?: Parameters[1], +) { + return viem_fallback(transports, config) +} diff --git a/packages/core/src/types/chain.test-d.ts b/packages/core/src/types/chain.test-d.ts new file mode 100644 index 0000000000..65632709e1 --- /dev/null +++ b/packages/core/src/types/chain.test-d.ts @@ -0,0 +1,33 @@ +import type { Chain, mainnet, optimism, sepolia } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import type { Config } from '../createConfig.js' +import type { SelectChains } from './chain.js' +import type { Merge } from './utils.js' + +test('not narrowable', () => { + type Result = SelectChains + expectTypeOf().toEqualTypeOf() +}) + +test('chainId', () => { + type Result = SelectChains< + Config, + 1 + > + expectTypeOf().toEqualTypeOf() +}) + +test('at least one chain has formatters', () => { + type Result = SelectChains> + expectTypeOf().toEqualTypeOf< + readonly [typeof mainnet, typeof optimism] + >() +}) + +test('no formatters', () => { + type Result = SelectChains> + expectTypeOf().toEqualTypeOf< + readonly [Merge] + >() +}) diff --git a/packages/core/src/types/chain.ts b/packages/core/src/types/chain.ts new file mode 100644 index 0000000000..5f81783171 --- /dev/null +++ b/packages/core/src/types/chain.ts @@ -0,0 +1,26 @@ +import type { Chain, ChainFormatters } from 'viem' + +import type { Config } from '../createConfig.js' +import type { IsNarrowable, Merge } from './utils.js' + +/** Filters {@link Config} chains by {@link chainId} or simplifies if no `ChainFormatters` are present. */ +export type SelectChains< + config extends Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, +> = Config extends config + ? readonly [Chain] // chains not inferrable, return default + : IsNarrowable extends true + ? readonly [Extract] // select specific chain + : HasFormatter extends true + ? config['chains'] // return all chains since one has formatter + : // return default chain with ID set to union (allows for more simple type since the only thing that is different is the chain ID for each chain) + readonly [Merge] + +type HasFormatter = chains extends readonly [ + infer head extends Chain, + ...infer tail extends readonly Chain[], +] + ? IsNarrowable extends true + ? true + : HasFormatter + : false diff --git a/packages/core/src/types/properties.ts b/packages/core/src/types/properties.ts new file mode 100644 index 0000000000..760cc46bd2 --- /dev/null +++ b/packages/core/src/types/properties.ts @@ -0,0 +1,23 @@ +import type { Config, Connector } from '../createConfig.js' + +export type ChainIdParameter< + config extends Config, + chainId extends + | config['chains'][number]['id'] + | undefined = config['chains'][number]['id'], +> = { + chainId?: + | (chainId extends config['chains'][number]['id'] ? chainId : undefined) + | config['chains'][number]['id'] + | undefined +} + +export type ConnectorParameter = { + connector?: Connector | undefined +} + +export type ScopeKeyParameter = { scopeKey?: string | undefined } + +export type SyncConnectedChainParameter = { + syncConnectedChain?: boolean | undefined +} diff --git a/packages/core/src/types/register.ts b/packages/core/src/types/register.ts new file mode 100644 index 0000000000..db420adfdc --- /dev/null +++ b/packages/core/src/types/register.ts @@ -0,0 +1,9 @@ +import type { Config } from '../createConfig.js' + +// biome-ignore lint/suspicious/noEmptyInterface: +export interface Register {} +export type ResolvedRegister = { + config: Register extends { config: infer config extends Config } + ? config + : Config +} diff --git a/packages/core/src/types/unit.ts b/packages/core/src/types/unit.ts new file mode 100644 index 0000000000..a64f794a87 --- /dev/null +++ b/packages/core/src/types/unit.ts @@ -0,0 +1 @@ +export type Unit = 'ether' | 'gwei' | 'wei' | number diff --git a/packages/core/src/types/utils.test-d.ts b/packages/core/src/types/utils.test-d.ts new file mode 100644 index 0000000000..523f9f2e36 --- /dev/null +++ b/packages/core/src/types/utils.test-d.ts @@ -0,0 +1,40 @@ +import { assertType, expectTypeOf, test } from 'vitest' + +import type { + Compute, + ExactPartial, + IsNever, + Mutable, + OneOf, + PartialBy, +} from './utils.js' + +test('ExactPartial', () => { + expectTypeOf>().toEqualTypeOf<{ + foo?: boolean | undefined + bar?: boolean | undefined + }>() +}) + +test('IsNever', () => { + expectTypeOf>().toEqualTypeOf() +}) + +test('Mutable', () => { + expectTypeOf< + Mutable<{ foo: boolean; readonly bar: boolean }> + >().toEqualTypeOf<{ foo: boolean; bar: boolean }>() +}) + +test('OneOf', () => { + assertType>({ foo: false }) + assertType>({ bar: false }) +}) + +test('PartialBy', () => { + type Result = Compute> + expectTypeOf().toEqualTypeOf<{ + foo?: string | undefined + bar: number + }>() +}) diff --git a/packages/core/src/types/utils.ts b/packages/core/src/types/utils.ts new file mode 100644 index 0000000000..aecd58a142 --- /dev/null +++ b/packages/core/src/types/utils.ts @@ -0,0 +1,101 @@ +/** Combines members of an intersection into a readable type. */ +// https://twitter.com/mattpocockuk/status/1622730173446557697?s=20&t=NdpAcmEFXY01xkqU3KO0Mg +export type Compute = { [key in keyof type]: type[key] } & unknown + +/** + * Makes all properties of an object optional. + * + * Compatible with [`exactOptionalPropertyTypes`](https://www.typescriptlang.org/tsconfig#exactOptionalPropertyTypes). + */ +export type ExactPartial = { + [key in keyof type]?: type[key] | undefined +} + +/** Checks if {@link type} can be narrowed further than {@link type2} */ +export type IsNarrowable = IsUnknown extends true + ? false + : undefined extends type + ? false + : IsNever< + (type extends type2 ? true : false) & + (type2 extends type ? false : true) + > extends true + ? false + : true + +/** + * @internal + * Checks if {@link type} is `never` + */ +export type IsNever = [type] extends [never] ? true : false + +/** + * @internal + * Checks if {@link type} is `unknown` + */ +export type IsUnknown = unknown extends type ? true : false + +/** Merges two object types into new type */ +export type Merge = Compute< + LooseOmit & + obj2 +> + +/** Removes `readonly` from all properties of an object. */ +export type Mutable = { + -readonly [key in keyof type]: type[key] +} + +/** Strict version of built-in Omit type */ +export type StrictOmit = Pick< + type, + Exclude +> + +/** Makes objects destructurable. */ +export type OneOf< + union extends object, + /// + keys extends KeyofUnion = KeyofUnion, +> = union extends infer Item + ? Compute]?: undefined }> + : never +type KeyofUnion = type extends type ? keyof type : never + +/** Makes {@link key} optional in {@link type} while preserving type inference. */ +// s/o trpc (https://github.com/trpc/trpc/blob/main/packages/server/src/types.ts#L6) +export type PartialBy = ExactPartial< + Pick +> & + StrictOmit + +/* Removes `undefined` from object property */ +export type RemoveUndefined = { + [key in keyof type]: NonNullable +} + +/////////////////////////////////////////////////////////////////////////// +// Loose types + +/** Loose version of {@link StrictOmit} */ +export type LooseOmit = Pick< + type, + Exclude +> + +/////////////////////////////////////////////////////////////////////////// +// Union types + +export type UnionCompute = type extends object ? Compute : type + +export type UnionLooseOmit = type extends any + ? LooseOmit + : never + +export type UnionStrictOmit = type extends any + ? StrictOmit + : never + +export type UnionExactPartial = type extends object + ? ExactPartial + : type diff --git a/packages/core/src/utils/cookie.test.ts b/packages/core/src/utils/cookie.test.ts new file mode 100644 index 0000000000..f21f5ccee1 --- /dev/null +++ b/packages/core/src/utils/cookie.test.ts @@ -0,0 +1,69 @@ +import { http } from 'viem' +import { mainnet } from 'viem/chains' +import { expect, test } from 'vitest' + +import { createConfig } from '../createConfig.js' +import { createStorage } from '../createStorage.js' +import { cookieStorage, cookieToInitialState, parseCookie } from './cookie.js' + +test('cookieStorage', () => { + expect(cookieStorage.getItem('recentConnectorId')).toMatchInlineSnapshot( + 'null', + ) + cookieStorage.setItem('recentConnectorId', 'foo') + expect(cookieStorage.getItem('recentConnectorId')).toMatchInlineSnapshot( + `"foo"`, + ) + cookieStorage.removeItem('recentConnectorId') + expect(cookieStorage.getItem('recentConnectorId')).toMatchInlineSnapshot( + 'null', + ) +}) + +test('cookieToInitialState', () => { + const config = createConfig({ + chains: [mainnet], + transports: { [mainnet.id]: http() }, + storage: createStorage({ storage: cookieStorage }), + }) + + expect( + cookieToInitialState( + config, + 'wagmi.store={"state":{"connections":{"__type":"Map","value":[]},"chainId":1,"current":null},"version":2}; ', + ), + ).toMatchInlineSnapshot(` + { + "chainId": 1, + "connections": Map {}, + "current": null, + } + `) + + expect(cookieToInitialState(config)).toMatchInlineSnapshot('undefined') + expect(cookieToInitialState(config), 'foo').toMatchInlineSnapshot('undefined') +}) + +test('parseCookie', () => { + expect( + parseCookie( + 'wagmi.store={"state":{"connections":{"__type":"Map","value":[]},"chainId":1,"current":null},"version":2}; ', + 'wagmi.store', + ), + ).toMatchInlineSnapshot( + `"{"state":{"connections":{"__type":"Map","value":[]},"chainId":1,"current":null},"version":2}"`, + ) + + expect( + parseCookie( + 'foo="bar"; wagmi.store={"state":{"connections":{"__type":"Map","value":[]},"chainId":1,"current":null},"version":2}; ', + 'wagmi.store', + ), + ).toMatchInlineSnapshot( + `"{"state":{"connections":{"__type":"Map","value":[]},"chainId":1,"current":null},"version":2}"`, + ) + + expect(parseCookie('foo="bar"; ', 'wagmi.store')).toMatchInlineSnapshot( + 'undefined', + ) +}) diff --git a/packages/core/src/utils/cookie.ts b/packages/core/src/utils/cookie.ts new file mode 100644 index 0000000000..ccd07bc7b7 --- /dev/null +++ b/packages/core/src/utils/cookie.ts @@ -0,0 +1,33 @@ +import type { Config, State } from '../createConfig.js' +import type { BaseStorage } from '../createStorage.js' +import { deserialize } from './deserialize.js' + +export const cookieStorage = { + getItem(key) { + if (typeof window === 'undefined') return null + const value = parseCookie(document.cookie, key) + return value ?? null + }, + setItem(key, value) { + if (typeof window === 'undefined') return + document.cookie = `${key}=${value};path=/;samesite=Lax` + }, + removeItem(key) { + if (typeof window === 'undefined') return + document.cookie = `${key}=;max-age=-1;path=/` + }, +} satisfies BaseStorage + +export function cookieToInitialState(config: Config, cookie?: string | null) { + if (!cookie) return undefined + const key = `${config.storage?.key}.store` + const parsed = parseCookie(cookie, key) + if (!parsed) return undefined + return deserialize<{ state: State }>(parsed).state +} + +export function parseCookie(cookie: string, key: string) { + const keyValue = cookie.split('; ').find((x) => x.startsWith(`${key}=`)) + if (!keyValue) return undefined + return keyValue.substring(key.length + 1) +} diff --git a/packages/core/src/utils/deepEqual.test.ts b/packages/core/src/utils/deepEqual.test.ts new file mode 100644 index 0000000000..6105fe496f --- /dev/null +++ b/packages/core/src/utils/deepEqual.test.ts @@ -0,0 +1,40 @@ +import { expect, test } from 'vitest' + +import { deepEqual } from './deepEqual.js' + +test('compares primitive values', () => { + expect(deepEqual(true, true)).toBe(true) + expect(deepEqual(true, false)).toBe(false) + + expect(deepEqual(1, 1)).toBe(true) + expect(deepEqual(1, 2)).toBe(false) + + expect(deepEqual('zustand', 'zustand')).toBe(true) + expect(deepEqual('zustand', 'redux')).toBe(false) +}) + +test('compares objects', () => { + expect(deepEqual({ foo: 'bar', asd: 123 }, { foo: 'bar', asd: 123 })).toBe( + true, + ) + + expect( + deepEqual({ foo: 'bar', asd: 123 }, { foo: 'bar', foobar: true }), + ).toBe(false) + + expect( + deepEqual({ foo: 'bar', asd: 123 }, { foo: 'bar', asd: 123, foobar: true }), + ).toBe(false) +}) + +test('compares arrays', () => { + expect(deepEqual([1, 2, 3], [1, 2, 3])).toBe(true) + + expect(deepEqual([1, 2, 3], [2, 3, 4])).toBe(false) + + expect( + deepEqual([{ foo: 'bar' }, { asd: 123 }], [{ foo: 'bar' }, { asd: 123 }]), + ).toBe(true) + + expect(deepEqual([{ foo: 'bar' }], [{ foo: 'bar', asd: 123 }])).toBe(false) +}) diff --git a/packages/core/src/utils/deepEqual.ts b/packages/core/src/utils/deepEqual.ts new file mode 100644 index 0000000000..89b47a6bdd --- /dev/null +++ b/packages/core/src/utils/deepEqual.ts @@ -0,0 +1,43 @@ +/** Forked from https://github.com/epoberezkin/fast-deep-equal */ + +export function deepEqual(a: any, b: any) { + if (a === b) return true + + if (a && b && typeof a === 'object' && typeof b === 'object') { + if (a.constructor !== b.constructor) return false + + let length: number + let i: number + + if (Array.isArray(a) && Array.isArray(b)) { + length = a.length + if (length !== b.length) return false + for (i = length; i-- !== 0; ) if (!deepEqual(a[i], b[i])) return false + return true + } + + if (a.valueOf !== Object.prototype.valueOf) + return a.valueOf() === b.valueOf() + if (a.toString !== Object.prototype.toString) + return a.toString() === b.toString() + + const keys = Object.keys(a) + length = keys.length + if (length !== Object.keys(b).length) return false + + for (i = length; i-- !== 0; ) + if (!Object.prototype.hasOwnProperty.call(b, keys[i]!)) return false + + for (i = length; i-- !== 0; ) { + const key = keys[i] + + if (key && !deepEqual(a[key], b[key])) return false + } + + return true + } + + // true if both NaN, false otherwise + // biome-ignore lint/suspicious/noSelfCompare: + return a !== a && b !== b +} diff --git a/packages/core/src/utils/deserialize.test.ts b/packages/core/src/utils/deserialize.test.ts new file mode 100644 index 0000000000..11f73ff79b --- /dev/null +++ b/packages/core/src/utils/deserialize.test.ts @@ -0,0 +1,114 @@ +import { expect, test } from 'vitest' + +import { deserialize } from './deserialize.js' +import { serialize } from './serialize.js' + +test('deserializes', () => { + const deserializedCache = deserialize( + serialize({ + some: 'complex', + object: { + that: 'has', + many: [ + { many: 'many', manymany: 'many' }, + { many: 'many' }, + { many: 'many' }, + { + many: { + properties: { + ones: { + that: { + have: { + functions: () => null, + }, + }, + }, + }, + }, + }, + ], + }, + and: { + ones: { + that: { + have: { + bigints: 123456789012345678901234567890n, + }, + }, + }, + }, + also: { + ones: { + that: { + have: { + proxies: new Proxy({ lol: 'nice' }, {}), + }, + }, + }, + }, + }), + ) + expect(deserializedCache).toMatchInlineSnapshot(` + { + "also": { + "ones": { + "that": { + "have": { + "proxies": { + "lol": "nice", + }, + }, + }, + }, + }, + "and": { + "ones": { + "that": { + "have": { + "bigints": 123456789012345678901234567890n, + }, + }, + }, + }, + "object": { + "many": [ + { + "many": "many", + "manymany": "many", + }, + { + "many": "many", + }, + { + "many": "many", + }, + { + "many": { + "properties": { + "ones": { + "that": { + "have": {}, + }, + }, + }, + }, + }, + ], + "that": "has", + }, + "some": "complex", + } + `) +}) + +test('Map', () => { + const map = new Map().set('foo', { bar: 'baz' }) + const deserializedCache = deserialize(serialize({ map })) + expect(deserializedCache).toEqual({ map }) +}) + +test('bigint', () => { + const bigint = 123n + const deserializedCache = deserialize(serialize({ bigint })) + expect(deserializedCache).toEqual({ bigint }) +}) diff --git a/packages/core/src/utils/deserialize.ts b/packages/core/src/utils/deserialize.ts new file mode 100644 index 0000000000..36fe30dab8 --- /dev/null +++ b/packages/core/src/utils/deserialize.ts @@ -0,0 +1,10 @@ +type Reviver = (key: string, value: any) => any + +export function deserialize(value: string, reviver?: Reviver): type { + return JSON.parse(value, (key, value_) => { + let value = value_ + if (value?.__type === 'bigint') value = BigInt(value.value) + if (value?.__type === 'Map') value = new Map(value.value) + return reviver?.(key, value) ?? value + }) +} diff --git a/packages/core/src/utils/extractRpcUrls.test.ts b/packages/core/src/utils/extractRpcUrls.test.ts new file mode 100644 index 0000000000..6d2c21e26e --- /dev/null +++ b/packages/core/src/utils/extractRpcUrls.test.ts @@ -0,0 +1,92 @@ +import { http } from 'viem' +import { mainnet, optimism, sepolia } from 'viem/chains' +import { expect, test } from 'vitest' + +import { injected } from '../connectors/injected.js' +import { unstable_connector } from '../transports/connector.js' +import { fallback } from '../transports/fallback.js' +import { extractRpcUrls } from './extractRpcUrls.js' + +test('default', () => { + expect( + extractRpcUrls({ + chain: mainnet, + transports: { + [mainnet.id]: fallback([ + http('https://wagmi.com'), + http('https://lol.com'), + ]), + [sepolia.id]: http('https://sepoliarocks.com'), + [optimism.id]: http(), + }, + }), + ).toMatchInlineSnapshot(` + [ + "https://wagmi.com", + "https://lol.com", + ] + `) + + expect( + extractRpcUrls({ + chain: sepolia, + transports: { + [mainnet.id]: fallback([ + http('https://wagmi.com'), + http('https://lol.com'), + ]), + [sepolia.id]: http('https://sepoliarocks.com'), + [optimism.id]: http(), + }, + }), + ).toMatchInlineSnapshot(` + [ + "https://sepoliarocks.com", + ] + `) + + expect( + extractRpcUrls({ + chain: optimism, + transports: { + [mainnet.id]: fallback([ + http('https://wagmi.com'), + http('https://lol.com'), + ]), + [sepolia.id]: http('https://sepoliarocks.com'), + [optimism.id]: http(), + }, + }), + ).toMatchInlineSnapshot(` + [ + "https://mainnet.optimism.io", + ] + `) + + expect( + extractRpcUrls({ + chain: mainnet, + }), + ).toMatchInlineSnapshot(` + [ + "https://eth.merkle.io", + ] + `) + + expect( + extractRpcUrls({ + chain: mainnet, + transports: { + [mainnet.id]: fallback([ + unstable_connector(injected), + http('https://lol.com'), + ]), + }, + }), + ).toMatchInlineSnapshot(` + [ + "https://eth.merkle.io", + "https://lol.com", + ] + `) +}) diff --git a/packages/core/src/utils/extractRpcUrls.ts b/packages/core/src/utils/extractRpcUrls.ts new file mode 100644 index 0000000000..a617eac13c --- /dev/null +++ b/packages/core/src/utils/extractRpcUrls.ts @@ -0,0 +1,19 @@ +import type { Chain, Transport } from 'viem' + +type ExtractRpcUrlsParameters = { + transports?: Record | undefined + chain: Chain +} + +export function extractRpcUrls(parameters: ExtractRpcUrlsParameters) { + const { chain } = parameters + const fallbackUrl = chain.rpcUrls.default.http[0] + + if (!parameters.transports) return [fallbackUrl] + + const transport = parameters.transports?.[chain.id]?.({ chain }) + const transports = (transport?.value?.transports as NonNullable< + typeof transport + >[]) || [transport] + return transports.map(({ value }) => value?.url || fallbackUrl) +} diff --git a/packages/core/src/utils/getAction.test.ts b/packages/core/src/utils/getAction.test.ts new file mode 100644 index 0000000000..7173852947 --- /dev/null +++ b/packages/core/src/utils/getAction.test.ts @@ -0,0 +1,49 @@ +import { abi, address, config } from '@wagmi/test' +import * as viem_actions from 'viem/actions' +import { expect, test, vi } from 'vitest' + +import { getAction } from './getAction.js' + +test('uses tree-shakable action', async () => { + const client = config.getClient({ chainId: 1 }) + + const name = 'getBlockNumber' + const actions = { ...viem_actions } + const spy = vi.spyOn(actions, name) + const action = getAction(client, actions[name], name) + + await action({}) + expect(spy).toBeCalledWith(client, {}) +}) + +test('uses client action', async () => { + const client = config + .getClient({ chainId: 1 }) + .extend(() => ({ getBlockNumber: async () => 69n })) + + const name = 'getBlockNumber' + const spy = vi.spyOn(client, name) + const action = getAction(client, client[name], name) + + await action({}) + expect(spy).toBeCalledWith({}) +}) + +test('internal call', async () => { + const client = config.getClient({ chainId: 1 }).extend(() => ({ + async call() { + return { + data: '0x0000000000000000000000000000000000000000000000000000000000000045', + } + }, + })) + + await expect( + viem_actions.readContract(client, { + address: address.wagmiMintExample, + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }), + ).resolves.toEqual(69n) +}) diff --git a/packages/core/src/utils/getAction.ts b/packages/core/src/utils/getAction.ts new file mode 100644 index 0000000000..514ceb5d50 --- /dev/null +++ b/packages/core/src/utils/getAction.ts @@ -0,0 +1,44 @@ +import type { + Account, + Chain, + Client, + PublicActions, + RpcSchema, + Transport, + WalletActions, +} from 'viem' + +/** + * Retrieves and returns an action from the client (if exists), and falls + * back to the tree-shakable action. + * + * Useful for extracting overridden actions from a client (ie. if a consumer + * wants to override the `sendTransaction` implementation). + */ +export function getAction< + transport extends Transport, + chain extends Chain | undefined, + account extends Account | undefined, + rpcSchema extends RpcSchema | undefined, + extended extends { [key: string]: unknown }, + client extends Client, + parameters, + returnType, +>( + client: client, + actionFn: (_: any, parameters: parameters) => returnType, + // Some minifiers drop `Function.prototype.name`, or replace it with short letters, + // meaning that `actionFn.name` will not always work. For that case, the consumer + // needs to pass the name explicitly. + name: keyof PublicActions | keyof WalletActions, +): (parameters: parameters) => returnType { + const action_implicit = client[actionFn.name] + if (typeof action_implicit === 'function') + return action_implicit as (params: parameters) => returnType + + const action_explicit = client[name] + if (typeof action_explicit === 'function') + return action_explicit as (params: parameters) => returnType + + return (params) => actionFn(client, params) +} diff --git a/packages/core/src/utils/getUnit.test.ts b/packages/core/src/utils/getUnit.test.ts new file mode 100644 index 0000000000..1054303def --- /dev/null +++ b/packages/core/src/utils/getUnit.test.ts @@ -0,0 +1,9 @@ +import { expect, test } from 'vitest' + +import { getUnit } from './getUnit.js' + +test('default', () => { + expect(getUnit(1)).toMatchInlineSnapshot('1') + expect(getUnit('wei')).toMatchInlineSnapshot('0') + expect(getUnit('ether')).toMatchInlineSnapshot('18') +}) diff --git a/packages/core/src/utils/getUnit.ts b/packages/core/src/utils/getUnit.ts new file mode 100644 index 0000000000..084f45b622 --- /dev/null +++ b/packages/core/src/utils/getUnit.ts @@ -0,0 +1,9 @@ +import { weiUnits } from 'viem' + +import type { Unit } from '../types/unit.js' + +export function getUnit(unit: Unit) { + if (typeof unit === 'number') return unit + if (unit === 'wei') return 0 + return Math.abs(weiUnits[unit]) +} diff --git a/packages/core/src/utils/getVersion.test.ts b/packages/core/src/utils/getVersion.test.ts new file mode 100644 index 0000000000..29fa256178 --- /dev/null +++ b/packages/core/src/utils/getVersion.test.ts @@ -0,0 +1,7 @@ +import { expect, test } from 'vitest' + +import { getVersion } from './getVersion.js' + +test('default', () => { + expect(getVersion()).toMatchInlineSnapshot(`"@wagmi/core@x.y.z"`) +}) diff --git a/packages/core/src/utils/getVersion.ts b/packages/core/src/utils/getVersion.ts new file mode 100644 index 0000000000..3506365267 --- /dev/null +++ b/packages/core/src/utils/getVersion.ts @@ -0,0 +1,3 @@ +import { version } from '../version.js' + +export const getVersion = () => `@wagmi/core@${version}` diff --git a/packages/core/src/utils/normalizeChainId.test.ts b/packages/core/src/utils/normalizeChainId.test.ts new file mode 100644 index 0000000000..de9d1882e3 --- /dev/null +++ b/packages/core/src/utils/normalizeChainId.test.ts @@ -0,0 +1,24 @@ +import { expect, test } from 'vitest' + +import { normalizeChainId } from './normalizeChainId.js' + +test.each([ + { chainId: 1, expected: 1 }, + { chainId: '1', expected: 1 }, + { chainId: '0x1', expected: 1 }, + { chainId: '0x4', expected: 4 }, + { chainId: 42, expected: 42 }, + { chainId: '42', expected: 42 }, + { chainId: '0x2a', expected: 42 }, + { chainId: ' 0x2a', expected: 42 }, + { chainId: BigInt(1), expected: 1 }, + { chainId: BigInt(10), expected: 10 }, +])('normalizeChainId($chainId)', ({ chainId, expected }) => { + expect(normalizeChainId(chainId)).toEqual(expected) +}) + +test('unknown type', () => { + expect(() => normalizeChainId({})).toThrow( + 'Cannot normalize chainId "[object Object]" of type "object"', + ) +}) diff --git a/packages/core/src/utils/normalizeChainId.ts b/packages/core/src/utils/normalizeChainId.ts new file mode 100644 index 0000000000..a1017c0953 --- /dev/null +++ b/packages/core/src/utils/normalizeChainId.ts @@ -0,0 +1,13 @@ +/** @deprecated use `Number` instead */ +export function normalizeChainId(chainId: bigint | number | string | unknown) { + if (typeof chainId === 'string') + return Number.parseInt( + chainId, + chainId.trim().substring(0, 2) === '0x' ? 16 : 10, + ) + if (typeof chainId === 'bigint') return Number(chainId) + if (typeof chainId === 'number') return chainId + throw new Error( + `Cannot normalize chainId "${chainId}" of type "${typeof chainId}"`, + ) +} diff --git a/packages/core/src/utils/serialize.test.ts b/packages/core/src/utils/serialize.test.ts new file mode 100644 index 0000000000..e182101130 --- /dev/null +++ b/packages/core/src/utils/serialize.test.ts @@ -0,0 +1,241 @@ +import { describe, expect, it } from 'vitest' + +import { serialize } from './serialize.js' + +class Foo { + value: string + + constructor(value: string) { + this.value = value + } +} + +const simpleObject = { + boolean: true, + fn() { + return 'foo' + }, + nan: Number.NaN, + nil: null, + number: 123, + string: 'foo', + undef: undefined, + [Symbol('key')]: 'value', +} + +const bigintObject = Object.assign({}, simpleObject, { + bigint: 123n, + nested: { + bigint: { + value: 69n, + }, + }, +}) + +const bufferString = 'this is a test buffer' +const complexObject = Object.assign({}, simpleObject, { + array: ['foo', { bar: 'baz' }], + buffer: Buffer.alloc(bufferString.length, bufferString), + error: new Error('boom'), + foo: new Foo('value'), + map: new Map().set('foo', { bar: 'baz' }), + object: { foo: { bar: 'baz' } }, + promise: Promise.resolve('foo'), + regexp: /foo/, + set: new Set().add('foo').add({ bar: 'baz' }), + weakmap: new WeakMap([ + [{}, 'foo'], + [{}, 'bar'], + ]), + weakset: new WeakSet([{}, {}]), +}) + +const circularObject = Object.assign( + {}, + complexObject, + { + map: { __type: 'Map', value: [['foo', { bar: 'baz' }]] }, + }, + { + deeply: { + nested: { + reference: {}, + }, + }, + }, +) + +circularObject.deeply.nested.reference = circularObject + +describe('stringify', () => { + describe('handling of object types', () => { + it('should handle simple objects', () => { + const result = serialize(simpleObject) + + expect(result).toMatchInlineSnapshot( + `"{"boolean":true,"nan":null,"nil":null,"number":123,"string":"foo"}"`, + ) + }) + + it('should handle objects with bigints', () => { + const result = serialize(bigintObject) + + expect(result).toMatchInlineSnapshot( + `"{"boolean":true,"nan":null,"nil":null,"number":123,"string":"foo","bigint":{"__type":"bigint","value":"123"},"nested":{"bigint":{"value":{"__type":"bigint","value":"69"}}}}"`, + ) + }) + + it('should handle simple objects with a custom replacer', () => { + const replacer = (_key: string, value: any) => + value && typeof value === 'object' ? value : `primitive-${value}` + + const result = serialize(simpleObject, replacer) + + expect(result).toMatchInlineSnapshot( + `"{"boolean":"primitive-true","fn":"primitive-fn() {\\n return \\"foo\\";\\n }","nan":"primitive-NaN","nil":"primitive-null","number":"primitive-123","string":"primitive-foo","undef":"primitive-undefined"}"`, + ) + }) + + it('should handle simple objects with indentation', () => { + const result = serialize(simpleObject, null, 2) + + expect(result).toMatchInlineSnapshot(` + "{ + "boolean": true, + "nan": null, + "nil": null, + "number": 123, + "string": "foo" + }" + `) + }) + + it('should handle bigint objects with indentation', () => { + const result = serialize(bigintObject, null, 2) + + expect(result).toMatchInlineSnapshot(` + "{ + "boolean": true, + "nan": null, + "nil": null, + "number": 123, + "string": "foo", + "bigint": { + "__type": "bigint", + "value": "123" + }, + "nested": { + "bigint": { + "value": { + "__type": "bigint", + "value": "69" + } + } + } + }" + `) + }) + + it('should handle complex objects', () => { + const result = serialize(complexObject) + + expect(result).toMatchInlineSnapshot( + `"{"boolean":true,"nan":null,"nil":null,"number":123,"string":"foo","array":["foo",{"bar":"baz"}],"buffer":{"type":"Buffer","data":[116,104,105,115,32,105,115,32,97,32,116,101,115,116,32,98,117,102,102,101,114]},"error":{},"foo":{"value":"value"},"map":{"__type":"Map","value":[["foo",{"bar":"baz"}]]},"object":{"foo":{"bar":"baz"}},"promise":{},"regexp":{},"set":{},"weakmap":{},"weakset":{}}"`, + ) + }) + + it('should handle complex objects with a custom replacer', () => { + const replacer = (_key: string, value: any) => + value && typeof value === 'object' ? value : `primitive-${value}` + + const result = serialize(complexObject, replacer) + + expect(result).toMatchInlineSnapshot( + `"{"boolean":"primitive-true","fn":"primitive-fn() {\\n return \\"foo\\";\\n }","nan":"primitive-NaN","nil":"primitive-null","number":"primitive-123","string":"primitive-foo","undef":"primitive-undefined","array":["primitive-foo",{"bar":"primitive-baz"}],"buffer":{"type":"primitive-Buffer","data":["primitive-116","primitive-104","primitive-105","primitive-115","primitive-32","primitive-105","primitive-115","primitive-32","primitive-97","primitive-32","primitive-116","primitive-101","primitive-115","primitive-116","primitive-32","primitive-98","primitive-117","primitive-102","primitive-102","primitive-101","primitive-114"]},"error":{},"foo":{"value":"primitive-value"},"map":{"__type":"primitive-Map","value":[["primitive-foo",{"bar":"primitive-baz"}]]},"object":{"foo":{"bar":"primitive-baz"}},"promise":{},"regexp":{},"set":{},"weakmap":{},"weakset":{}}"`, + ) + }) + + it('should handle circular objects', () => { + const result = serialize(circularObject) + + expect(result).toEqual( + JSON.stringify( + circularObject, + (() => { + const cache: any[] = [] + + return (_key, value) => { + if (value && typeof value === 'object' && ~cache.indexOf(value)) { + return '[ref=.]' + } + + cache.push(value) + + return value + } + })(), + ), + ) + }) + + it('should handle circular objects with a custom circular replacer', () => { + const result = serialize( + circularObject, + null, + null, + (_key: string, _value: string, referenceKey: string) => referenceKey, + ) + const circularReplacer = (() => { + const cache: any[] = [] + + return (_key: string, value: any) => { + if (value && typeof value === 'object' && ~cache.indexOf(value)) { + return '.' + } + + cache.push(value) + + return value + } + })() + + expect(result).toEqual(JSON.stringify(circularObject, circularReplacer)) + }) + }) + + describe('key references', () => { + it('should point to the top level object when it is referenced', () => { + const object = { + foo: 'bar', + deeply: { + recursive: { + object: {}, + }, + }, + } + + object.deeply.recursive.object = object + + expect(serialize(object)).toEqual( + `{"foo":"bar","deeply":{"recursive":{"object":"[ref=.]"}}}`, + ) + }) + + it('should point to the nested object when it is referenced', () => { + const object = { + foo: 'bar', + deeply: { + recursive: { + object: {}, + }, + }, + } + + object.deeply.recursive.object = object.deeply.recursive + + expect(serialize(object)).toEqual( + `{"foo":"bar","deeply":{"recursive":{"object":"[ref=.deeply.recursive]"}}}`, + ) + }) + }) +}) diff --git a/packages/core/src/utils/serialize.ts b/packages/core/src/utils/serialize.ts new file mode 100644 index 0000000000..3f538c7b87 --- /dev/null +++ b/packages/core/src/utils/serialize.ts @@ -0,0 +1,116 @@ +/** + * Get the reference key for the circular value + * + * @param keys the keys to build the reference key from + * @param cutoff the maximum number of keys to include + * @returns the reference key + */ +function getReferenceKey(keys: string[], cutoff: number) { + return keys.slice(0, cutoff).join('.') || '.' +} + +/** + * Faster `Array.prototype.indexOf` implementation build for slicing / splicing + * + * @param array the array to match the value in + * @param value the value to match + * @returns the matching index, or -1 + */ +function getCutoff(array: any[], value: any) { + const { length } = array + + for (let index = 0; index < length; ++index) { + if (array[index] === value) { + return index + 1 + } + } + + return 0 +} + +type StandardReplacer = (key: string, value: any) => any +type CircularReplacer = (key: string, value: any, referenceKey: string) => any + +/** + * Create a replacer method that handles circular values + * + * @param [replacer] a custom replacer to use for non-circular values + * @param [circularReplacer] a custom replacer to use for circular methods + * @returns the value to stringify + */ +function createReplacer( + replacer?: StandardReplacer | null | undefined, + circularReplacer?: CircularReplacer | null | undefined, +): StandardReplacer { + const hasReplacer = typeof replacer === 'function' + const hasCircularReplacer = typeof circularReplacer === 'function' + + const cache: any[] = [] + const keys: string[] = [] + + return function replace(this: any, key: string, value: any) { + if (typeof value === 'object') { + if (cache.length) { + const thisCutoff = getCutoff(cache, this) + + if (thisCutoff === 0) { + cache[cache.length] = this + } else { + cache.splice(thisCutoff) + keys.splice(thisCutoff) + } + + keys[keys.length] = key + + const valueCutoff = getCutoff(cache, value) + + if (valueCutoff !== 0) { + return hasCircularReplacer + ? circularReplacer.call( + this, + key, + value, + getReferenceKey(keys, valueCutoff), + ) + : `[ref=${getReferenceKey(keys, valueCutoff)}]` + } + } else { + cache[0] = value + keys[0] = key + } + } + + return hasReplacer ? replacer.call(this, key, value) : value + } +} + +/** + * Stringifier that handles circular values + * + * Forked from https://github.com/planttheidea/fast-stringify + * + * @param value to stringify + * @param [replacer] a custom replacer function for handling standard values + * @param [indent] the number of spaces to indent the output by + * @param [circularReplacer] a custom replacer function for handling circular values + * @returns the stringified output + */ +export function serialize( + value: any, + replacer?: StandardReplacer | null | undefined, + indent?: number | null | undefined, + circularReplacer?: CircularReplacer | null | undefined, +) { + return JSON.stringify( + value, + createReplacer((key, value_) => { + let value = value_ + if (typeof value === 'bigint') + value = { __type: 'bigint', value: value_.toString() } + if (value instanceof Map) + value = { __type: 'Map', value: Array.from(value_.entries()) } + return replacer?.(key, value) ?? value + }, circularReplacer), + indent ?? undefined, + ) +} diff --git a/packages/core/src/utils/uid.ts b/packages/core/src/utils/uid.ts new file mode 100644 index 0000000000..4adc3e4e2b --- /dev/null +++ b/packages/core/src/utils/uid.ts @@ -0,0 +1,49 @@ +const size = 256 +let index = size +let buffer: string + +function getRandomBytes(byteLength: number): Uint8Array { + if ( + typeof globalThis !== 'undefined' && + globalThis.crypto && + typeof globalThis.crypto.getRandomValues === 'function' + ) { + const array = new Uint8Array(byteLength) + globalThis.crypto.getRandomValues(array) + return array + } + + // Fallback for Node.js environments that expose `require('crypto')`. + try { + // eslint-disable-next-line @typescript-eslint/no-var-requires + const nodeCrypto = require('crypto') as { + randomBytes: (size: number) => { readonly [n: number]: number; length: number } + } + const buf = nodeCrypto.randomBytes(byteLength) + const array = new Uint8Array(byteLength) + for (let i = 0; i < byteLength; i++) array[i] = buf[i] + return array + } catch { + // ignore and fall through to non-cryptographic fallback + } + + // Last-resort, non-cryptographic fallback (used only if no crypto APIs are available). + const array = new Uint8Array(byteLength) + for (let i = 0; i < byteLength; i++) { + array[i] = (Math.random() * 256) | 0 + } + return array +} + +export function uid(length = 11) { + if (!buffer || index + length > size * 2) { + buffer = '' + index = 0 + const randomBytes = getRandomBytes(size) + for (let i = 0; i < size; i++) { + const byte = randomBytes[i] + buffer += byte.toString(16).padStart(2, '0') + } + } + return buffer.substring(index, index++ + length) +} diff --git a/packages/core/test/setup.ts b/packages/core/test/setup.ts new file mode 100644 index 0000000000..f59a0488fe --- /dev/null +++ b/packages/core/test/setup.ts @@ -0,0 +1,5 @@ +import { vi } from 'vitest' + +vi.mock('../src/version.ts', () => { + return { version: 'x.y.z' } +}) diff --git a/packages/core/tsconfig.build.json b/packages/core/tsconfig.build.json new file mode 100644 index 0000000000..fbed2b1036 --- /dev/null +++ b/packages/core/tsconfig.build.json @@ -0,0 +1,8 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["src/**/*.ts"], + "exclude": ["src/**/*.test.ts", "src/**/*.test-d.ts"], + "compilerOptions": { + "sourceMap": true + } +} diff --git a/packages/core/tsconfig.json b/packages/core/tsconfig.json new file mode 100644 index 0000000000..bacbc9228c --- /dev/null +++ b/packages/core/tsconfig.json @@ -0,0 +1,5 @@ +{ + "extends": "./tsconfig.build.json", + "include": ["src/**/*.ts", "test/**/*.ts"], + "exclude": [] +} diff --git a/packages/create-wagmi/CHANGELOG.md b/packages/create-wagmi/CHANGELOG.md new file mode 100644 index 0000000000..7ab58fe7e1 --- /dev/null +++ b/packages/create-wagmi/CHANGELOG.md @@ -0,0 +1,278 @@ +# create-wagmi + +## 2.0.14 + +### Patch Changes + +- [#4450](https://github.com/wevm/wagmi/pull/4450) [`7b9a6bb35881b657a00bdd7ccd7edea32660f5bf`](https://github.com/wevm/wagmi/commit/7b9a6bb35881b657a00bdd7ccd7edea32660f5bf) Thanks [@tmm](https://github.com/tmm)! - Removed internal usage of `fs-extra`. + +## 2.0.13 + +### Patch Changes + +- [#4060](https://github.com/wevm/wagmi/pull/4060) [`95965c1f19d480b97f2b297a077a9e607dee32ad`](https://github.com/wevm/wagmi/commit/95965c1f19d480b97f2b297a077a9e607dee32ad) Thanks [@dalechyn](https://github.com/dalechyn)! - Bumped Tanstack Query dependencies to fix typing issues between exported Wagmi query options and TanStack Query suspense query methods (due to [`direction` property in `QueryFunctionContext` being deprecated](https://github.com/TanStack/query/pull/7410)). + +## 2.0.12 + +### Patch Changes + +- [`c00303d0c5909680b3124f92c0a2d2f31ea30405`](https://github.com/wevm/wagmi/commit/c00303d0c5909680b3124f92c0a2d2f31ea30405) Thanks [@tmm](https://github.com/tmm)! - Bumped Next.js version + +## 2.0.11 + +### Patch Changes + +- [#3871](https://github.com/wevm/wagmi/pull/3871) [`0e6bd286`](https://github.com/wevm/wagmi/commit/0e6bd286ca2572d2bfbe206db460528b7c2ebc63) Thanks [@jxom](https://github.com/jxom)! - Added `.npmrc` with `legacy-peer-deps = true` to templates. + +## 2.0.10 + +### Patch Changes + +- [`3f8203bd`](https://github.com/wevm/wagmi/commit/3f8203bd77fcf6b6756640b5971d09741ae3853d) Thanks [@tmm](https://github.com/tmm)! - Set Wagmi-related package versions to latest. + +## 2.0.9 + +### Patch Changes + +- [#3518](https://github.com/wevm/wagmi/pull/3518) [`338e857d`](https://github.com/wevm/wagmi/commit/338e857d8cb2fe85e13d9207bef14cada1c1962d) Thanks [@tmm](https://github.com/tmm)! - Bumped dependencies. + +## 2.0.8 + +### Patch Changes + +- [#3510](https://github.com/wevm/wagmi/pull/3510) [`660ff80d`](https://github.com/wevm/wagmi/commit/660ff80d5b046967a446eba43ee54b8359a37d0d) Thanks [@tmm](https://github.com/tmm)! - Fixed issue where connectors returning multiple addresses didn't checksum correctly. + +## 2.0.7 + +### Patch Changes + +- [#3496](https://github.com/wevm/wagmi/pull/3496) [`ba7f8a75`](https://github.com/wevm/wagmi/commit/ba7f8a758efb07664c6e401b5e7e325e7c62341b) Thanks [@tmm](https://github.com/tmm)! - Bumped dependencies. + +## 2.0.6 + +### Patch Changes + +- [#3427](https://github.com/wevm/wagmi/pull/3427) [`370f1b4a`](https://github.com/wevm/wagmi/commit/370f1b4a3f154d181acf381c31c2e7862e22c0e4) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Bumped dependencies. + +## 2.0.5 + +### Patch Changes + +- [#3459](https://github.com/wevm/wagmi/pull/3459) [`d950b666`](https://github.com/wevm/wagmi/commit/d950b666b56700ca039ce16cdfdf34564991e7f5) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Bumped dependencies + +## 2.0.4 + +### Patch Changes + +- [#3443](https://github.com/wevm/wagmi/pull/3443) [`007024a6`](https://github.com/wevm/wagmi/commit/007024a684ddbecf924cdc06dd6a8854fc3d5eeb) Thanks [@jmrossy](https://github.com/jmrossy)! - Bumped dependencies. + +- [#3447](https://github.com/wevm/wagmi/pull/3447) [`a02a26ad`](https://github.com/wevm/wagmi/commit/a02a26ad030d3afb78f744377d61b5c60b65d97a) Thanks [@tmm](https://github.com/tmm)! - Bumped dependencies. + +## 2.0.3 + +### Patch Changes + +- [`ec0d8b41`](https://github.com/wevm/wagmi/commit/ec0d8b4112181fefb11025e436a94a6114761d37) Thanks [@tmm](https://github.com/tmm)! - Added note to `metaMask` connector. + +## 2.0.2 + +### Patch Changes + +- [#3384](https://github.com/wevm/wagmi/pull/3384) [`ee868c33`](https://github.com/wevm/wagmi/commit/ee868c3385dae511230b6ddcb5627c1293cc1844) Thanks [@tmm](https://github.com/tmm)! - Fixed connectors not bubbling error when connecting with `chainId` and subsequent user rejection. + +## 2.0.1 + +### Major Changes + +- [#3333](https://github.com/wevm/wagmi/pull/3333) [`b3a0baaa`](https://github.com/wevm/wagmi/commit/b3a0baaaee7decf750d376aab2502cd33ca4825a) Thanks [@tmm](https://github.com/tmm)! - Added support for Wagmi 2.0. + +## 1.0.5 + +### Patch Changes + +- 6ba996f: Fixed optional WalletConnect Cloud Project ID prompt + +## 1.0.4 + +### Patch Changes + +- eb8dd9d: Updated wagmi & viem. Added ConnectKit template back in. + +## 1.0.3 + +### Patch Changes + +- 00d9080: Added RainbowKit & Web3Modal wagmi v1 templates + +## 1.0.2 + +### Patch Changes + +- 3c65f77: Fixed Next.js default template title + +## 1.0.0 + +### Major Changes + +- affc13e: Updated to wagmi v1. + +## 0.1.19 + +### Patch Changes + +- 1282f0e: Updated templates to use WalletConnect v2 by default + +## 0.1.18 + +### Patch Changes + +- 12dcfe0: Updated wagmi to 0.12 in ConnectKit templates. + +## 0.1.17 + +### Patch Changes + +- 6eba01a: Updated wagmi to 0.12. +- 3a0ab8c: Added .env to .gitignore in templates. + +## 0.1.16 + +### Patch Changes + +- 7ad50f1: Upgraded `@wagmi/cli` + +## 0.1.15 + +### Patch Changes + +- 6e30599: Added `test` config to `foundry.toml` on the Foundry templates. + +## 0.1.14 + +### Patch Changes + +- 19f3675: Bumped `wagmi` to `~0.11.0`. + +## 0.1.13 + +### Patch Changes + +- c1ab75c: Bump @wagmi/cli + +## 0.1.12 + +### Patch Changes + +- af6e551: Added templates for `@wagmi/cli`: + + - `@wagmi/cli (Mint NFT Example)` + - `@wagmi/cli + ERC20` + - `@wagmi/cli + Etherscan (Mint NFT Example)` + - `@wagmi/cli + Foundry (Counter.sol Example)` + +## 0.1.11 + +### Patch Changes + +- cc638dd: Fixed an issue where Vite projects used `process.env` instead of `import.meta.env`. +- 75d1c2d: Updated `wagmi` to `~0.10.0`. + +## 0.1.10 + +### Patch Changes + +- 9cd7140: Amend gitignore files for Vite templates + +## 0.1.9 + +### Patch Changes + +- 904a2e1: Fixed import env variables in Vite (React) templates + +## 0.1.8 + +### Patch Changes + +- 65cc841: Update RainbowKit & ConnectKit templates to `wagmi@~0.9.0` + +## 0.1.7 + +### Patch Changes + +- a59d9c5: Upgrade `default` & `web3modal` templates to `wagmi@0.9` + +## 0.1.6 + +### Patch Changes + +- b544457: Updated `connectkit` to `1.1.0` in the ConnectKit templates + +## 0.1.5 + +### Patch Changes + +- 6bd6c74: Updated repo link in package.json + +## 0.1.4 + +### Patch Changes + +- c39666b: Added ability to select providers +- 37708ed: **Added ability to select frameworks.** + + Each directory in `templates/` now mirrors a "framework", where its child directories mirror a "template" for that framework. + + Example: + + ``` + templates/ + next/ + connectkit/ + default/ + rainbowkit/ + web3modal + vite-react/ + connectkit/ + default/ + rainbowkit/ + web3modal/ + ``` + +- 399d2b9: Moved template configuration to the template level + added hooks + +## 0.1.3 + +### Patch Changes + +- 353332a: Added Web3Modal template +- dd95b14: **next-with-connectkit**: Update `connectkit` to `^1.0.0` + +## 0.1.2 + +### Patch Changes + +- 34f666b: Fixed issue where package manager install process would not log error + +## 0.1.1 + +### Patch Changes + +- 900cbdc: Updated `@rainbow-me/rainbowkit` dependency in Next + RainbowKit template + +## 0.1.0 + +### Minor Changes + +- 23993d2: ## 🎉 Initial release 🎉 + + Get up and running quickly with wagmi by using the `create-wagmi` CLI. This tool interactively scaffolds a new wagmi project for you so you can start building instantly without the hassle of setting up `git`, installing packages, worrying about TypeScript configuration, etc. + + To get started, `create-wagmi` can be instantiated with one of your favorite package managers: + + ```bash + npm init wagmi + # or + pnpm create wagmi + # or + yarn create wagmi + ``` diff --git a/packages/create-wagmi/README.md b/packages/create-wagmi/README.md new file mode 100644 index 0000000000..f923127ca2 --- /dev/null +++ b/packages/create-wagmi/README.md @@ -0,0 +1,17 @@ +# create-wagmi + +Get up and running quickly with [Wagmi](https://wagmi.sh) by using the `create-wagmi` CLI. + +## Installation + +```bash +npm create wagmi +# or +pnpm create wagmi +# or +yarn create wagmi +``` + +## Documentation + +For documentation and guides, visit [wagmi.sh](https://wagmi.sh/cli/create-wagmi). diff --git a/packages/create-wagmi/package.json b/packages/create-wagmi/package.json new file mode 100644 index 0000000000..7b6798c628 --- /dev/null +++ b/packages/create-wagmi/package.json @@ -0,0 +1,49 @@ +{ + "name": "create-wagmi", + "description": "Create Wagmi apps with one command", + "version": "2.0.14", + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/wevm/wagmi.git", + "directory": "packages/create-wagmi" + }, + "scripts": { + "build": "pnpm run clean && pnpm run build:esm+types", + "build:esm+types": "tsc --project tsconfig.build.json --outDir ./dist/esm --declaration --declarationMap --declarationDir ./dist/types", + "check:types": "tsc --noEmit", + "clean": "rm -rf dist tsconfig.tsbuildinfo", + "dev": "bun src/cli.ts", + "test:build": "publint --strict" + }, + "files": [ + "dist/**", + "!dist/**/*.tsbuildinfo", + "src/**/*.ts", + "!src/**/*.test.ts", + "!src/**/*.test-d.ts", + "templates/**" + ], + "bin": { + "wagmi": "./dist/esm/cli.js" + }, + "sideEffects": false, + "type": "module", + "exports": { + "./package.json": "./package.json" + }, + "dependencies": { + "cac": "^6.7.14", + "cross-spawn": "^7.0.5", + "picocolors": "^1.0.0", + "prompts": "^2.4.2" + }, + "devDependencies": { + "@types/cross-spawn": "^6.0.6", + "@types/node": "^20.12.10", + "@types/prompts": "^2.4.9" + }, + "contributors": ["awkweb.eth ", "jxom.eth "], + "funding": "https://github.com/sponsors/wevm", + "keywords": ["wagmi", "eth", "ethereum", "dapps", "wallet", "web3", "cli"] +} diff --git a/packages/create-wagmi/src/cli.test.ts b/packages/create-wagmi/src/cli.test.ts new file mode 100644 index 0000000000..4d6915a6f3 --- /dev/null +++ b/packages/create-wagmi/src/cli.test.ts @@ -0,0 +1,151 @@ +import { + type ExecSyncOptionsWithStringEncoding, + execSync, +} from 'node:child_process' +import { mkdirSync, readdirSync, writeFileSync } from 'node:fs' +import { rm } from 'node:fs/promises' +import { join } from 'node:path' +import pc from 'picocolors' +import { afterEach, beforeAll, expect, test } from 'vitest' + +import { version } from './version.js' + +const cliPath = join(__dirname, '../dist/esm/cli.js') + +const projectName = 'test-app' +const genPath = join(__dirname, projectName) + +function run( + args: string[], + options: ExecSyncOptionsWithStringEncoding = { encoding: 'utf8' }, +): string { + return execSync(`node ${cliPath} ${args.join(' ')}`, options) +} + +function createNonEmptyDir() { + mkdirSync(genPath, { recursive: true }) + const file = join(genPath, 'foo') + writeFileSync(file, 'bar') +} + +beforeAll(async () => { + execSync('pnpm --filter create-wagmi build') + await rm(genPath, { recursive: true, force: true }) +}) +afterEach(async () => { + await rm(genPath, { recursive: true, force: true }) +}) + +test('prompts for the project name if none supplied', () => { + const stdout = run([]) + expect(stdout).toContain('Project name:') +}) + +test('prompts for the framework if none supplied when target dir is current directory', () => { + mkdirSync(genPath) + const stdout = run(['.'], { cwd: genPath, encoding: 'utf8' }) + expect(stdout).toContain('Select a framework:') +}) + +test('prompts for the framework if none supplied', () => { + const stdout = run([projectName]) + expect(stdout).toContain('Select a framework:') +}) + +test('prompts for the framework on not supplying a value for --template', () => { + const stdout = run([projectName, '--template']) + expect(stdout).toContain('Select a framework:') +}) + +test('prompts for the framework on supplying an invalid template', () => { + const stdout = run([projectName, '--template', 'unknown']) + expect(stdout).toContain( + `"unknown" isn't a valid template. Please choose from below:`, + ) +}) + +test('asks to overwrite non-empty target directory', () => { + createNonEmptyDir() + const stdout = run([projectName], { cwd: __dirname, encoding: 'utf8' }) + expect(stdout).toContain(`Target directory "${projectName}" is not empty.`) +}) + +test('asks to overwrite non-empty current directory', () => { + createNonEmptyDir() + const stdout = run(['.'], { cwd: genPath, encoding: 'utf8' }) + expect(stdout).toContain('Current directory is not empty.') +}) + +const templateFiles = readdirSync( + join(cliPath, '../../../templates/vite-react'), +) + .map((filePath) => { + if (filePath === '_gitignore') return '.gitignore' + if (filePath === '_env.local') return '.env.local' + if (filePath === '_npmrc') return '.npmrc' + return filePath + }) + .sort() + +test('successfully scaffolds a project based on vite-react starter template', () => { + mkdirSync(genPath, { recursive: true }) + const stdout = run([projectName, '--template', 'vite-react'], { + cwd: __dirname, + encoding: 'utf8', + }) + const generatedFiles = readdirSync(genPath).sort() + + expect(stdout).toContain(`Scaffolding project in ${genPath}`) + expect(templateFiles).toEqual(generatedFiles) +}) + +test('works with the -t alias', () => { + mkdirSync(genPath, { recursive: true }) + const stdout = run([projectName, '-t', 'vite-react'], { + cwd: __dirname, + encoding: 'utf8', + }) + const generatedFiles = readdirSync(genPath).sort() + + expect(stdout).toContain(`Scaffolding project in ${genPath}`) + expect(templateFiles).toEqual(generatedFiles) +}) + +test('uses different package manager', () => { + mkdirSync(genPath, { recursive: true }) + const stdout = run([projectName, '--bun', '-t', 'vite-react'], { + cwd: __dirname, + encoding: 'utf8', + }) + + expect(stdout).toContain('bun install') +}) + +test('shows help', () => { + const stdout = run(['--help']) + expect( + stdout + .replace(version, 'x.y.z') + .replace(pc.green(''), ''), + ).toMatchInlineSnapshot(` + "create-wagmi/x.y.z + + Usage: + $ create-wagmi [options] + + Options: + -t, --template [name] Template to bootstrap with. Available: vite-react, next, vite-vue, nuxt, vite-vanilla + --bun Use bun as your package manager + --npm Use npm as your package manager + --pnpm Use pnpm as your package manager + --yarn Use yarn as your package manager + -h, --help Display this message + -v, --version Display version number + " + `) +}) + +test('shows version', () => { + const stdout = run(['--version']) + expect(stdout).toContain(`create-wagmi/${version} `) +}) diff --git a/packages/create-wagmi/src/cli.ts b/packages/create-wagmi/src/cli.ts new file mode 100644 index 0000000000..ecb6a25a4c --- /dev/null +++ b/packages/create-wagmi/src/cli.ts @@ -0,0 +1,284 @@ +#!/usr/bin/env node +import * as fs from 'node:fs' +import * as path from 'node:path' +import { fileURLToPath } from 'node:url' +import { cac } from 'cac' +import spawn from 'cross-spawn' +import pc from 'picocolors' +import prompts from 'prompts' + +import { type Framework, frameworks } from './frameworks.js' +import { + copy, + emptyDir, + formatTargetDir, + isEmpty, + isValidPackageName, + pkgFromUserAgent, + toValidPackageName, +} from './utils.js' +import { version } from './version.js' + +const templates = frameworks + .map((f) => f.variants?.map((v) => v.name) || [f.name]) + .reduce((a, b) => a.concat(b), []) + +const cli = cac('create-wagmi') + +cli + .usage(`${pc.green('')} [options]`) + .option( + '-t, --template [name]', + `Template to bootstrap with. Available: ${templates + .sort((a, b) => (a && !b ? -1 : 1)) + .join(', ')}`, + ) + .option('--bun', 'Use bun as your package manager') + .option('--npm', 'Use npm as your package manager') + .option('--pnpm', 'Use pnpm as your package manager') + .option('--yarn', 'Use yarn as your package manager') + +cli.help() +cli.version(version) + +const cwd = process.cwd() + +const renameFiles: Record = { + '_env.local': '.env.local', + // https://github.com/npm/npm/issues/1862 + _gitignore: '.gitignore', + _npmrc: '.npmrc', +} + +const defaultTargetDir = 'wagmi-project' + +async function init() { + const { args, options } = cli.parse(process.argv) + if (options.help) return + if (options.version) return + + const argTargetDir = formatTargetDir(args[0]) + const argTemplate = options.template || options.t + + let targetDir = argTargetDir || defaultTargetDir + function getProjectName() { + return targetDir === '.' ? path.basename(path.resolve()) : targetDir + } + + let result: prompts.Answers< + 'framework' | 'overwrite' | 'packageName' | 'projectName' | 'variant' + > + try { + result = await prompts( + [ + { + type: argTargetDir ? null : 'text', + name: 'projectName', + message: pc.reset('Project name:'), + initial: defaultTargetDir, + onState(state) { + targetDir = formatTargetDir(state.value) || defaultTargetDir + }, + }, + { + type() { + return !fs.existsSync(targetDir) || isEmpty(targetDir) + ? null + : 'confirm' + }, + name: 'overwrite', + message() { + return `${ + targetDir === '.' + ? 'Current directory' + : `Target directory "${targetDir}"` + } is not empty. Remove existing files and continue?` + }, + }, + { + type(_, { overwrite }: { overwrite?: boolean }) { + if (overwrite === false) + throw new Error(`${pc.red('✖')} Operation cancelled`) + return null + }, + name: 'overwriteChecker', + }, + { + type() { + return isValidPackageName(getProjectName()) ? null : 'text' + }, + name: 'packageName', + message: pc.reset('Package name:'), + initial() { + return toValidPackageName(getProjectName()) + }, + validate(dir) { + return isValidPackageName(dir) || 'Invalid package.json name' + }, + }, + { + type: + argTemplate && templates.includes(argTemplate) ? null : 'select', + name: 'framework', + message: + typeof argTemplate === 'string' && !templates.includes(argTemplate) + ? pc.reset( + `"${argTemplate}" isn't a valid template. Please choose from below: `, + ) + : pc.reset('Select a framework:'), + initial: 0, + choices: frameworks.map((framework) => { + const frameworkColor = framework.color + return { + title: frameworkColor(framework.display || framework.name), + value: framework, + } + }), + }, + { + type(framework: Framework) { + return framework?.variants?.length > 1 ? 'select' : null + }, + name: 'variant', + message: pc.reset('Select a variant:'), + choices(framework: Framework) { + return framework.variants.map((variant) => { + const variantColor = variant.color + return { + title: variantColor(variant.display || variant.name), + value: variant.name, + } + }) + }, + }, + ], + { + onCancel() { + throw new Error(`${pc.red('✖')} Operation cancelled`) + }, + }, + ) + } catch (error) { + // biome-ignore lint/suspicious/noConsoleLog: + console.log((error as Error).message) + return + } + + // user choice associated with prompts + const { + framework, + overwrite, + packageName, + variant = framework?.variants[0]?.name, + } = result + + const root = path.join(cwd, targetDir) + + if (overwrite) emptyDir(root) + else if (!fs.existsSync(root)) fs.mkdirSync(root, { recursive: true }) + + // determine template + const template: string = variant || framework?.name || argTemplate + + const pkgInfo = pkgFromUserAgent(process.env.npm_config_user_agent) + type PkgManager = 'bun' | 'npm' | 'pnpm' | 'yarn' + let pkgManager: PkgManager + if (options.bun) pkgManager = 'bun' + else if (options.npm) pkgManager = 'npm' + else if (options.pnpm) pkgManager = 'pnpm' + else if (options.yarn) pkgManager = 'yarn' + else pkgManager = pkgInfo ? (pkgInfo.name as PkgManager) : 'npm' + const isYarn1 = pkgManager === 'yarn' && pkgInfo?.version?.startsWith('1.') + + const { customCommand } = + frameworks.flatMap((f) => f.variants).find((v) => v.name === template) ?? {} + + if (customCommand) { + const fullCustomCommand = customCommand + .replace(/^npm create /, () => { + // `bun create` uses it's own set of templates, + // the closest alternative is using `bun x` directly on the package + if (pkgManager === 'bun') return 'bun x create-' + return `${pkgManager} create ` + }) + // Only Yarn 1.x doesn't support `@version` in the `create` command + .replace('@latest', () => (isYarn1 ? '' : '@latest')) + .replace(/^npm exec/, () => { + // Prefer `pnpm dlx`, `yarn dlx`, or `bun x` + if (pkgManager === 'pnpm') return 'pnpm dlx' + if (pkgManager === 'yarn' && !isYarn1) return 'yarn dlx' + if (pkgManager === 'bun') return 'bun x' + // Use `npm exec` in all other cases, + // including Yarn 1.x and other custom npm clients. + return 'npm exec' + }) + + const [command, ...args] = fullCustomCommand.split(' ') + // we replace TARGET_DIR here because targetDir may include a space + const replacedArgs = args.map((arg) => arg.replace('TARGET_DIR', targetDir)) + const { status } = spawn.sync(command!, replacedArgs, { + stdio: 'inherit', + }) + process.exit(status ?? 0) + } + + // biome-ignore lint/suspicious/noConsoleLog: + console.log(`\nScaffolding project in ${root}...`) + + const templateDir = path.resolve( + fileURLToPath(import.meta.url), + '../../../templates', + template, + ) + + function write(file: string, content?: string) { + const targetPath = path.join(root, renameFiles[file] ?? file) + if (content) fs.writeFileSync(targetPath, content) + else copy(path.join(templateDir, file), targetPath) + } + + const files = fs.readdirSync(templateDir) + for (const file of files.filter((f) => f !== 'package.json')) { + write(file) + } + + const pkg = JSON.parse( + fs.readFileSync(path.join(templateDir, 'package.json'), 'utf-8'), + ) + + pkg.name = packageName || getProjectName() + + write('package.json', `${JSON.stringify(pkg, null, 2)}\n`) + + const cdProjectName = path.relative(cwd, root) + // biome-ignore lint/suspicious/noConsoleLog: + console.log('\nDone. Now run:\n') + if (root !== cwd) + // biome-ignore lint/suspicious/noConsoleLog: + console.log( + ` cd ${ + cdProjectName.includes(' ') ? `"${cdProjectName}"` : cdProjectName + }`, + ) + + switch (pkgManager) { + case 'yarn': + // biome-ignore lint/suspicious/noConsoleLog: + console.log(' yarn') + // biome-ignore lint/suspicious/noConsoleLog: + console.log(' yarn dev') + break + default: + // biome-ignore lint/suspicious/noConsoleLog: + console.log(` ${pkgManager} install`) + // biome-ignore lint/suspicious/noConsoleLog: + console.log(` ${pkgManager} run dev`) + break + } + // biome-ignore lint/suspicious/noConsoleLog: + console.log() +} + +init().catch((e) => { + console.error(e) +}) diff --git a/packages/create-wagmi/src/frameworks.ts b/packages/create-wagmi/src/frameworks.ts new file mode 100644 index 0000000000..1b414bafc8 --- /dev/null +++ b/packages/create-wagmi/src/frameworks.ts @@ -0,0 +1,66 @@ +import pc from 'picocolors' + +type ColorFunc = (str: string | number) => string + +type FrameworkVariant = { + name: string + display: string + color: ColorFunc + customCommand?: string +} + +export type Framework = { + name: string + display: string + color: ColorFunc + variants: readonly FrameworkVariant[] +} + +export const frameworks: readonly Framework[] = [ + { + name: 'react', + display: 'React', + color: pc.cyan, + variants: [ + { + name: 'vite-react', + display: 'Vite', + color: pc.blue, + }, + { + name: 'next', + display: 'Next', + color: pc.yellow, + }, + ], + }, + { + name: 'vue', + display: 'Vue', + color: pc.green, + variants: [ + { + name: 'vite-vue', + display: 'Vite', + color: pc.blue, + }, + { + name: 'nuxt', + display: 'Nuxt', + color: pc.yellow, + }, + ], + }, + { + name: 'vanilla', + display: 'Vanilla', + color: pc.magenta, + variants: [ + { + name: 'vite-vanilla', + display: 'Vite', + color: pc.blue, + }, + ], + }, +] diff --git a/packages/create-wagmi/src/index.test-d.ts b/packages/create-wagmi/src/index.test-d.ts new file mode 100644 index 0000000000..b056d56358 --- /dev/null +++ b/packages/create-wagmi/src/index.test-d.ts @@ -0,0 +1,4 @@ +import { expectTypeOf } from 'vitest' + +// noop test because vitest typecheck fails unless each workspace project has type test +expectTypeOf(1).toEqualTypeOf() diff --git a/packages/create-wagmi/src/utils.ts b/packages/create-wagmi/src/utils.ts new file mode 100644 index 0000000000..d04f60ed93 --- /dev/null +++ b/packages/create-wagmi/src/utils.ts @@ -0,0 +1,79 @@ +import * as fs from 'node:fs' +import * as path from 'node:path' + +export function formatTargetDir(targetDir: string | undefined) { + return targetDir?.trim().replace(/\/+$/g, '') +} + +export function copy(src: string, dest: string) { + const stat = fs.statSync(src) + if (stat.isDirectory()) copyDir(src, dest) + else fs.copyFileSync(src, dest) +} + +function copyDir(srcDir: string, destDir: string) { + fs.mkdirSync(destDir, { recursive: true }) + for (const file of fs.readdirSync(srcDir)) { + const srcFile = path.resolve(srcDir, file) + const destFile = path.resolve(destDir, file) + copy(srcFile, destFile) + } +} + +export function isValidPackageName(projectName: string) { + return /^(?:@[a-z\d\-*~][a-z\d\-*._~]*\/)?[a-z\d\-~][a-z\d\-._~]*$/.test( + projectName, + ) +} + +export function toValidPackageName(projectName: string) { + return projectName + .trim() + .toLowerCase() + .replace(/\s+/g, '-') + .replace(/^[._]/, '') + .replace(/[^a-z\d\-~]+/g, '-') +} + +export function isEmpty(path: string) { + const files = fs.readdirSync(path) + return files.length === 0 || (files.length === 1 && files[0] === '.git') +} + +export function emptyDir(dir: string) { + if (!fs.existsSync(dir)) return + for (const file of fs.readdirSync(dir)) { + if (file === '.git') continue + fs.rmSync(path.resolve(dir, file), { recursive: true, force: true }) + } +} + +export function pkgFromUserAgent(userAgent: string | undefined) { + if (!userAgent) return undefined + const pkgSpec = userAgent.split(' ')[0]! + const pkgSpecArr = pkgSpec.split('/') + return { + name: pkgSpecArr[0], + version: pkgSpecArr[1], + } +} + +// function setupReactSwc(root: string, isTs: boolean) { +// editFile(path.resolve(root, 'package.json'), (content) => { +// return content.replace( +// /"@vitejs\/plugin-react": ".+?"/, +// `"@vitejs/plugin-react-swc": "^3.3.2"`, +// ) +// }) +// editFile( +// path.resolve(root, `vite.config.${isTs ? 'ts' : 'js'}`), +// (content) => { +// return content.replace('@vitejs/plugin-react', '@vitejs/plugin-react-swc') +// }, +// ) +// } + +// function editFile(file: string, callback: (content: string) => string) { +// const content = fs.readFileSync(file, 'utf-8') +// fs.writeFileSync(file, callback(content), 'utf-8') +// } diff --git a/packages/create-wagmi/src/version.ts b/packages/create-wagmi/src/version.ts new file mode 100644 index 0000000000..5556800c0d --- /dev/null +++ b/packages/create-wagmi/src/version.ts @@ -0,0 +1 @@ +export const version = '2.0.14' diff --git a/packages/create-wagmi/templates/next/README.md b/packages/create-wagmi/templates/next/README.md new file mode 100644 index 0000000000..bd3aa7b7f0 --- /dev/null +++ b/packages/create-wagmi/templates/next/README.md @@ -0,0 +1 @@ +This is a [Next.js](https://nextjs.org) project bootstrapped with [`create-wagmi`](https://github.com/wevm/wagmi/tree/main/packages/create-wagmi). diff --git a/packages/create-wagmi/templates/next/_env.local b/packages/create-wagmi/templates/next/_env.local new file mode 100644 index 0000000000..9a11dba16a --- /dev/null +++ b/packages/create-wagmi/templates/next/_env.local @@ -0,0 +1,2 @@ +NEXT_PUBLIC_WC_PROJECT_ID= +NEXT_TELEMETRY_DISABLED=1 \ No newline at end of file diff --git a/packages/create-wagmi/templates/next/_gitignore b/packages/create-wagmi/templates/next/_gitignore new file mode 100644 index 0000000000..8f322f0d8f --- /dev/null +++ b/packages/create-wagmi/templates/next/_gitignore @@ -0,0 +1,35 @@ +# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. + +# dependencies +/node_modules +/.pnp +.pnp.js + +# testing +/coverage + +# next.js +/.next/ +/out/ + +# production +/build + +# misc +.DS_Store +*.pem + +# debug +npm-debug.log* +yarn-debug.log* +yarn-error.log* + +# local env files +.env*.local + +# vercel +.vercel + +# typescript +*.tsbuildinfo +next-env.d.ts diff --git a/packages/create-wagmi/templates/next/_npmrc b/packages/create-wagmi/templates/next/_npmrc new file mode 100644 index 0000000000..ca1e9d98b5 --- /dev/null +++ b/packages/create-wagmi/templates/next/_npmrc @@ -0,0 +1 @@ +legacy-peer-deps = true \ No newline at end of file diff --git a/packages/create-wagmi/templates/next/next-env.d.ts b/packages/create-wagmi/templates/next/next-env.d.ts new file mode 100644 index 0000000000..4f11a03dc6 --- /dev/null +++ b/packages/create-wagmi/templates/next/next-env.d.ts @@ -0,0 +1,5 @@ +/// +/// + +// NOTE: This file should not be edited +// see https://nextjs.org/docs/basic-features/typescript for more information. diff --git a/packages/create-wagmi/templates/next/next.config.js b/packages/create-wagmi/templates/next/next.config.js new file mode 100644 index 0000000000..767719fc4f --- /dev/null +++ b/packages/create-wagmi/templates/next/next.config.js @@ -0,0 +1,4 @@ +/** @type {import('next').NextConfig} */ +const nextConfig = {} + +module.exports = nextConfig diff --git a/packages/create-wagmi/templates/next/package.json b/packages/create-wagmi/templates/next/package.json new file mode 100644 index 0000000000..55ac1dac6d --- /dev/null +++ b/packages/create-wagmi/templates/next/package.json @@ -0,0 +1,32 @@ +{ + "name": "wagmi-next-starter", + "private": true, + "version": "0.0.0", + "scripts": { + "dev": "next dev", + "build": "next build", + "start": "next start", + "lint": "next lint" + }, + "dependencies": { + "@tanstack/react-query": "5.45.1", + "next": "15.4.10", + "react": "^19.1.0", + "react-dom": "^18.3.1", + "viem": "latest", + "wagmi": "latest" + }, + "devDependencies": { + "@types/node": "^20.12.10", + "@types/react": "^18.3.1", + "@types/react-dom": "^18.3.0", + "@wagmi/cli": "latest", + "bufferutil": "^4.0.8", + "encoding": "^0.1.13", + "lokijs": "^1.5.12", + "pino-pretty": "^10.3.1", + "supports-color": "^9.4.0", + "typescript": "^5.4.5", + "utf-8-validate": "^5.0.2" + } +} diff --git a/packages/create-wagmi/templates/next/src/app/globals.css b/packages/create-wagmi/templates/next/src/app/globals.css new file mode 100644 index 0000000000..0733a7ee6b --- /dev/null +++ b/packages/create-wagmi/templates/next/src/app/globals.css @@ -0,0 +1,21 @@ +:root { + background-color: #181818; + color: rgba(255, 255, 255, 0.87); + color-scheme: light dark; + font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; + font-synthesis: none; + font-weight: 400; + line-height: 1.5; + text-rendering: optimizeLegibility; + + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + -webkit-text-size-adjust: 100%; +} + +@media (prefers-color-scheme: light) { + :root { + background-color: #f8f8f8; + color: #181818; + } +} diff --git a/packages/create-wagmi/templates/next/src/app/layout.tsx b/packages/create-wagmi/templates/next/src/app/layout.tsx new file mode 100644 index 0000000000..da5b293bf0 --- /dev/null +++ b/packages/create-wagmi/templates/next/src/app/layout.tsx @@ -0,0 +1,30 @@ +import './globals.css' +import type { Metadata } from 'next' +import { Inter } from 'next/font/google' +import { headers } from 'next/headers' +import { type ReactNode } from 'react' +import { cookieToInitialState } from 'wagmi' + +import { getConfig } from '../wagmi' +import { Providers } from './providers' + +const inter = Inter({ subsets: ['latin'] }) + +export const metadata: Metadata = { + title: 'Create Wagmi', + description: 'Generated by create-wagmi', +} + +export default async function RootLayout(props: { children: ReactNode }) { + const initialState = cookieToInitialState( + getConfig(), + (await headers()).get('cookie'), + ) + return ( + + + {props.children} + + + ) +} diff --git a/packages/create-wagmi/templates/next/src/app/page.tsx b/packages/create-wagmi/templates/next/src/app/page.tsx new file mode 100644 index 0000000000..f5dcbdf812 --- /dev/null +++ b/packages/create-wagmi/templates/next/src/app/page.tsx @@ -0,0 +1,48 @@ +'use client' + +import { useAccount, useConnect, useDisconnect } from 'wagmi' + +function App() { + const account = useAccount() + const { connectors, connect, status, error } = useConnect() + const { disconnect } = useDisconnect() + + return ( + <> +
+

Account

+ +
+ status: {account.status} +
+ addresses: {JSON.stringify(account.addresses)} +
+ chainId: {account.chainId} +
+ + {account.status === 'connected' && ( + + )} +
+ +
+

Connect

+ {connectors.map((connector) => ( + + ))} +
{status}
+
{error?.message}
+
+ + ) +} + +export default App diff --git a/packages/create-wagmi/templates/next/src/app/providers.tsx b/packages/create-wagmi/templates/next/src/app/providers.tsx new file mode 100644 index 0000000000..b4086cf531 --- /dev/null +++ b/packages/create-wagmi/templates/next/src/app/providers.tsx @@ -0,0 +1,23 @@ +'use client' + +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import { type ReactNode, useState } from 'react' +import { type State, WagmiProvider } from 'wagmi' + +import { getConfig } from '@/wagmi' + +export function Providers(props: { + children: ReactNode + initialState?: State +}) { + const [config] = useState(() => getConfig()) + const [queryClient] = useState(() => new QueryClient()) + + return ( + + + {props.children} + + + ) +} diff --git a/packages/create-wagmi/templates/next/src/wagmi.ts b/packages/create-wagmi/templates/next/src/wagmi.ts new file mode 100644 index 0000000000..b34f4c0079 --- /dev/null +++ b/packages/create-wagmi/templates/next/src/wagmi.ts @@ -0,0 +1,28 @@ +import { http, cookieStorage, createConfig, createStorage } from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' +import { coinbaseWallet, injected, walletConnect } from 'wagmi/connectors' + +export function getConfig() { + return createConfig({ + chains: [mainnet, sepolia], + connectors: [ + injected(), + coinbaseWallet(), + walletConnect({ projectId: process.env.NEXT_PUBLIC_WC_PROJECT_ID }), + ], + storage: createStorage({ + storage: cookieStorage, + }), + ssr: true, + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, + }) +} + +declare module 'wagmi' { + interface Register { + config: ReturnType + } +} diff --git a/packages/create-wagmi/templates/next/tsconfig.json b/packages/create-wagmi/templates/next/tsconfig.json new file mode 100644 index 0000000000..e59724b283 --- /dev/null +++ b/packages/create-wagmi/templates/next/tsconfig.json @@ -0,0 +1,27 @@ +{ + "compilerOptions": { + "target": "es5", + "lib": ["dom", "dom.iterable", "esnext"], + "allowJs": true, + "skipLibCheck": true, + "strict": true, + "noEmit": true, + "esModuleInterop": true, + "module": "esnext", + "moduleResolution": "bundler", + "resolveJsonModule": true, + "isolatedModules": true, + "jsx": "preserve", + "incremental": true, + "plugins": [ + { + "name": "next" + } + ], + "paths": { + "@/*": ["./src/*"] + } + }, + "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"], + "exclude": ["node_modules"] +} diff --git a/packages/create-wagmi/templates/nuxt/_env.local b/packages/create-wagmi/templates/nuxt/_env.local new file mode 100644 index 0000000000..437e9e3e7b --- /dev/null +++ b/packages/create-wagmi/templates/nuxt/_env.local @@ -0,0 +1,3 @@ +NUXT_PUBLIC_WC_PROJECT_ID= +NUXT_TELEMETRY_DISABLED=1 + diff --git a/packages/create-wagmi/templates/nuxt/_gitignore b/packages/create-wagmi/templates/nuxt/_gitignore new file mode 100644 index 0000000000..4a7f73a2ed --- /dev/null +++ b/packages/create-wagmi/templates/nuxt/_gitignore @@ -0,0 +1,24 @@ +# Nuxt dev/build outputs +.output +.data +.nuxt +.nitro +.cache +dist + +# Node dependencies +node_modules + +# Logs +logs +*.log + +# Misc +.DS_Store +.fleet +.idea + +# Local env files +.env +.env.* +!.env.example diff --git a/packages/create-wagmi/templates/nuxt/_npmrc b/packages/create-wagmi/templates/nuxt/_npmrc new file mode 100644 index 0000000000..057cc841f2 --- /dev/null +++ b/packages/create-wagmi/templates/nuxt/_npmrc @@ -0,0 +1,2 @@ +legacy-peer-deps = true + diff --git a/packages/create-wagmi/templates/nuxt/app.vue b/packages/create-wagmi/templates/nuxt/app.vue new file mode 100644 index 0000000000..98b46bf528 --- /dev/null +++ b/packages/create-wagmi/templates/nuxt/app.vue @@ -0,0 +1,28 @@ + + + diff --git a/packages/create-wagmi/templates/nuxt/components/Account.vue b/packages/create-wagmi/templates/nuxt/components/Account.vue new file mode 100644 index 0000000000..33f1491dac --- /dev/null +++ b/packages/create-wagmi/templates/nuxt/components/Account.vue @@ -0,0 +1,22 @@ + + + diff --git a/packages/create-wagmi/templates/nuxt/components/Connect.vue b/packages/create-wagmi/templates/nuxt/components/Connect.vue new file mode 100644 index 0000000000..93320448c0 --- /dev/null +++ b/packages/create-wagmi/templates/nuxt/components/Connect.vue @@ -0,0 +1,19 @@ + + + diff --git a/packages/create-wagmi/templates/nuxt/nuxt.config.ts b/packages/create-wagmi/templates/nuxt/nuxt.config.ts new file mode 100644 index 0000000000..adfe7fd2d8 --- /dev/null +++ b/packages/create-wagmi/templates/nuxt/nuxt.config.ts @@ -0,0 +1,7 @@ +import { defineNuxtConfig } from 'nuxt/config' + +// https://nuxt.com/docs/api/configuration/nuxt-config +export default defineNuxtConfig({ + devtools: { enabled: true }, + modules: ['@wagmi/vue/nuxt'], +}) diff --git a/packages/create-wagmi/templates/nuxt/package.json b/packages/create-wagmi/templates/nuxt/package.json new file mode 100644 index 0000000000..65ff657528 --- /dev/null +++ b/packages/create-wagmi/templates/nuxt/package.json @@ -0,0 +1,21 @@ +{ + "name": "nuxt-app", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "build": "nuxt build", + "dev": "nuxt dev", + "generate": "nuxt generate", + "preview": "nuxt preview", + "postinstall": "nuxt prepare" + }, + "dependencies": { + "@tanstack/vue-query": ">=5.45.0", + "@wagmi/vue": "latest", + "nuxt": "^3.11.2", + "viem": "latest", + "vue": ">=3.4.21", + "vue-router": "^4.3.2" + } +} diff --git a/packages/create-wagmi/templates/nuxt/plugins/wagmi.ts b/packages/create-wagmi/templates/nuxt/plugins/wagmi.ts new file mode 100644 index 0000000000..b6abe5bcd2 --- /dev/null +++ b/packages/create-wagmi/templates/nuxt/plugins/wagmi.ts @@ -0,0 +1,10 @@ +import { VueQueryPlugin } from '@tanstack/vue-query' +import { WagmiPlugin } from '@wagmi/vue' +import { defineNuxtPlugin } from 'nuxt/app' + +import { config } from '../wagmi' + +// TODO: Move to @wagmi/vue/nuxt nitro plugin +export default defineNuxtPlugin((nuxtApp) => { + nuxtApp.vueApp.use(WagmiPlugin, { config }).use(VueQueryPlugin, {}) +}) diff --git a/packages/create-wagmi/templates/nuxt/server/tsconfig.json b/packages/create-wagmi/templates/nuxt/server/tsconfig.json new file mode 100644 index 0000000000..b9ed69c19e --- /dev/null +++ b/packages/create-wagmi/templates/nuxt/server/tsconfig.json @@ -0,0 +1,3 @@ +{ + "extends": "../.nuxt/tsconfig.server.json" +} diff --git a/packages/create-wagmi/templates/nuxt/tsconfig.json b/packages/create-wagmi/templates/nuxt/tsconfig.json new file mode 100644 index 0000000000..a746f2a70c --- /dev/null +++ b/packages/create-wagmi/templates/nuxt/tsconfig.json @@ -0,0 +1,4 @@ +{ + // https://nuxt.com/docs/guide/concepts/typescript + "extends": "./.nuxt/tsconfig.json" +} diff --git a/packages/create-wagmi/templates/nuxt/wagmi.ts b/packages/create-wagmi/templates/nuxt/wagmi.ts new file mode 100644 index 0000000000..83e8569ea8 --- /dev/null +++ b/packages/create-wagmi/templates/nuxt/wagmi.ts @@ -0,0 +1,29 @@ +import { http, cookieStorage, createConfig, createStorage } from '@wagmi/vue' +import { mainnet, optimism, sepolia } from '@wagmi/vue/chains' +import { injected, metaMask, walletConnect } from '@wagmi/vue/connectors' + +export const config = createConfig({ + chains: [mainnet, sepolia, optimism], + connectors: [ + injected(), + walletConnect({ + projectId: process.env.NUXT_PUBLIC_WC_PROJECT_ID!, + }), + metaMask(), + ], + storage: createStorage({ + storage: cookieStorage, + }), + ssr: true, + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + [optimism.id]: http(), + }, +}) + +declare module '@wagmi/vue' { + interface Register { + config: typeof config + } +} diff --git a/packages/create-wagmi/templates/vite-react/README.md b/packages/create-wagmi/templates/vite-react/README.md new file mode 100644 index 0000000000..15f6f79541 --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/README.md @@ -0,0 +1 @@ +This is a [Vite](https://vitejs.dev) project bootstrapped with [`create-wagmi`](https://github.com/wevm/wagmi/tree/main/packages/create-wagmi). diff --git a/packages/create-wagmi/templates/vite-react/_env.local b/packages/create-wagmi/templates/vite-react/_env.local new file mode 100644 index 0000000000..936f763762 --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/_env.local @@ -0,0 +1 @@ +VITE_WC_PROJECT_ID= \ No newline at end of file diff --git a/packages/create-wagmi/templates/vite-react/_gitignore b/packages/create-wagmi/templates/vite-react/_gitignore new file mode 100644 index 0000000000..a547bf36d8 --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/_gitignore @@ -0,0 +1,24 @@ +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +pnpm-debug.log* +lerna-debug.log* + +node_modules +dist +dist-ssr +*.local + +# Editor directories and files +.vscode/* +!.vscode/extensions.json +.idea +.DS_Store +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? diff --git a/packages/create-wagmi/templates/vite-react/_npmrc b/packages/create-wagmi/templates/vite-react/_npmrc new file mode 100644 index 0000000000..ca1e9d98b5 --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/_npmrc @@ -0,0 +1 @@ +legacy-peer-deps = true \ No newline at end of file diff --git a/packages/create-wagmi/templates/vite-react/biome.json b/packages/create-wagmi/templates/vite-react/biome.json new file mode 100644 index 0000000000..08eb8a26ab --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/biome.json @@ -0,0 +1,13 @@ +{ + "formatter": { + "enabled": true, + "indentStyle": "space", + "lineWidth": 120 + }, + "linter": { + "enabled": true + }, + "organizeImports": { + "enabled": true + } +} diff --git a/packages/create-wagmi/templates/vite-react/index.html b/packages/create-wagmi/templates/vite-react/index.html new file mode 100644 index 0000000000..f519ce85a7 --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/index.html @@ -0,0 +1,12 @@ + + + + + + Create Wagmi + + +
+ + + diff --git a/packages/create-wagmi/templates/vite-react/package.json b/packages/create-wagmi/templates/vite-react/package.json new file mode 100644 index 0000000000..0eeaab9a10 --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/package.json @@ -0,0 +1,29 @@ +{ + "name": "wagmi-vite-starter", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "lint": "biome check .", + "preview": "vite preview" + }, + "dependencies": { + "@tanstack/react-query": "5.45.1", + "react": "^18.3.1", + "react-dom": "^18.3.1", + "viem": "latest", + "wagmi": "latest" + }, + "devDependencies": { + "@biomejs/biome": "^1.8.0", + "@types/react": "^18.3.1", + "@types/react-dom": "^18.3.0", + "@vitejs/plugin-react": "^4.2.1", + "@wagmi/cli": "latest", + "buffer": "^6.0.3", + "typescript": "^5.8.3", + "vite": "^5.2.11" + } +} diff --git a/packages/create-wagmi/templates/vite-react/src/App.tsx b/packages/create-wagmi/templates/vite-react/src/App.tsx new file mode 100644 index 0000000000..faa8ce1c79 --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/src/App.tsx @@ -0,0 +1,46 @@ +import { useAccount, useConnect, useDisconnect } from 'wagmi' + +function App() { + const account = useAccount() + const { connectors, connect, status, error } = useConnect() + const { disconnect } = useDisconnect() + + return ( + <> +
+

Account

+ +
+ status: {account.status} +
+ addresses: {JSON.stringify(account.addresses)} +
+ chainId: {account.chainId} +
+ + {account.status === 'connected' && ( + + )} +
+ +
+

Connect

+ {connectors.map((connector) => ( + + ))} +
{status}
+
{error?.message}
+
+ + ) +} + +export default App diff --git a/packages/create-wagmi/templates/vite-react/src/index.css b/packages/create-wagmi/templates/vite-react/src/index.css new file mode 100644 index 0000000000..0733a7ee6b --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/src/index.css @@ -0,0 +1,21 @@ +:root { + background-color: #181818; + color: rgba(255, 255, 255, 0.87); + color-scheme: light dark; + font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; + font-synthesis: none; + font-weight: 400; + line-height: 1.5; + text-rendering: optimizeLegibility; + + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + -webkit-text-size-adjust: 100%; +} + +@media (prefers-color-scheme: light) { + :root { + background-color: #f8f8f8; + color: #181818; + } +} diff --git a/packages/create-wagmi/templates/vite-react/src/main.tsx b/packages/create-wagmi/templates/vite-react/src/main.tsx new file mode 100644 index 0000000000..d999e1a932 --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/src/main.tsx @@ -0,0 +1,24 @@ +import { Buffer } from 'buffer' +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import React from 'react' +import ReactDOM from 'react-dom/client' +import { WagmiProvider } from 'wagmi' + +import App from './App.tsx' +import { config } from './wagmi.ts' + +import './index.css' + +globalThis.Buffer = Buffer + +const queryClient = new QueryClient() + +ReactDOM.createRoot(document.getElementById('root')!).render( + + + + + + + , +) diff --git a/packages/create-wagmi/templates/vite-react/src/vite-env.d.ts b/packages/create-wagmi/templates/vite-react/src/vite-env.d.ts new file mode 100644 index 0000000000..11f02fe2a0 --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/packages/create-wagmi/templates/vite-react/src/wagmi.ts b/packages/create-wagmi/templates/vite-react/src/wagmi.ts new file mode 100644 index 0000000000..43cf231934 --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/src/wagmi.ts @@ -0,0 +1,22 @@ +import { http, createConfig } from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' +import { coinbaseWallet, injected, walletConnect } from 'wagmi/connectors' + +export const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [ + injected(), + coinbaseWallet(), + walletConnect({ projectId: import.meta.env.VITE_WC_PROJECT_ID }), + ], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) + +declare module 'wagmi' { + interface Register { + config: typeof config + } +} diff --git a/packages/create-wagmi/templates/vite-react/tsconfig.json b/packages/create-wagmi/templates/vite-react/tsconfig.json new file mode 100644 index 0000000000..a7fc6fbf23 --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "module": "ESNext", + "skipLibCheck": true, + + /* Bundler mode */ + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "react-jsx", + + /* Linting */ + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true + }, + "include": ["src"], + "references": [{ "path": "./tsconfig.node.json" }] +} diff --git a/packages/create-wagmi/templates/vite-react/tsconfig.node.json b/packages/create-wagmi/templates/vite-react/tsconfig.node.json new file mode 100644 index 0000000000..42872c59f5 --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/tsconfig.node.json @@ -0,0 +1,10 @@ +{ + "compilerOptions": { + "composite": true, + "skipLibCheck": true, + "module": "ESNext", + "moduleResolution": "bundler", + "allowSyntheticDefaultImports": true + }, + "include": ["vite.config.ts"] +} diff --git a/packages/create-wagmi/templates/vite-react/vite.config.ts b/packages/create-wagmi/templates/vite-react/vite.config.ts new file mode 100644 index 0000000000..36f7f4e1bc --- /dev/null +++ b/packages/create-wagmi/templates/vite-react/vite.config.ts @@ -0,0 +1,7 @@ +import react from '@vitejs/plugin-react' +import { defineConfig } from 'vite' + +// https://vitejs.dev/config/ +export default defineConfig({ + plugins: [react()], +}) diff --git a/packages/create-wagmi/templates/vite-vanilla/_env.local b/packages/create-wagmi/templates/vite-vanilla/_env.local new file mode 100644 index 0000000000..936f763762 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vanilla/_env.local @@ -0,0 +1 @@ +VITE_WC_PROJECT_ID= \ No newline at end of file diff --git a/packages/create-wagmi/templates/vite-vanilla/_gitignore b/packages/create-wagmi/templates/vite-vanilla/_gitignore new file mode 100644 index 0000000000..a547bf36d8 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vanilla/_gitignore @@ -0,0 +1,24 @@ +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +pnpm-debug.log* +lerna-debug.log* + +node_modules +dist +dist-ssr +*.local + +# Editor directories and files +.vscode/* +!.vscode/extensions.json +.idea +.DS_Store +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? diff --git a/packages/create-wagmi/templates/vite-vanilla/_npmrc b/packages/create-wagmi/templates/vite-vanilla/_npmrc new file mode 100644 index 0000000000..ca1e9d98b5 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vanilla/_npmrc @@ -0,0 +1 @@ +legacy-peer-deps = true \ No newline at end of file diff --git a/packages/create-wagmi/templates/vite-vanilla/index.html b/packages/create-wagmi/templates/vite-vanilla/index.html new file mode 100644 index 0000000000..e2028cc129 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vanilla/index.html @@ -0,0 +1,12 @@ + + + + + + Create Wagmi + + +
+ + + diff --git a/packages/create-wagmi/templates/vite-vanilla/package.json b/packages/create-wagmi/templates/vite-vanilla/package.json new file mode 100644 index 0000000000..e48954313c --- /dev/null +++ b/packages/create-wagmi/templates/vite-vanilla/package.json @@ -0,0 +1,24 @@ +{ + "name": "wagmi-core-vanilla-starter", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "@wagmi/connectors": "latest", + "@wagmi/core": "latest", + "react": "^18.3.1", + "react-dom": "^18.3.1", + "viem": "latest" + }, + "devDependencies": { + "@wagmi/cli": "latest", + "buffer": "^6.0.3", + "typescript": "^5.8.3", + "vite": "^5.2.11" + } +} diff --git a/packages/create-wagmi/templates/vite-vanilla/src/main.ts b/packages/create-wagmi/templates/vite-vanilla/src/main.ts new file mode 100644 index 0000000000..f2b80f3459 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vanilla/src/main.ts @@ -0,0 +1,89 @@ +import { Buffer } from 'buffer' +import { connect, disconnect, reconnect, watchAccount } from '@wagmi/core' + +import './style.css' +import { config } from './wagmi' + +globalThis.Buffer = Buffer + +document.querySelector('#app')!.innerHTML = ` +
+
+

Account

+ +
+ status: +
+ addresses: +
+ chainId: +
+
+ +
+

Connect

+ ${config.connectors + .map( + (connector) => + ``, + ) + .join('')} +
+
+` + +setupApp(document.querySelector('#app')!) + +function setupApp(element: HTMLDivElement) { + const connectElement = element.querySelector('#connect') + const buttons = element.querySelectorAll('.connect') + for (const button of buttons) { + const connector = config.connectors.find( + (connector) => connector.uid === button.id, + )! + button.addEventListener('click', async () => { + try { + const errorElement = element.querySelector('#error') + if (errorElement) errorElement.remove() + await connect(config, { connector }) + } catch (error) { + const errorElement = document.createElement('div') + errorElement.id = 'error' + errorElement.innerText = (error as Error).message + connectElement?.appendChild(errorElement) + } + }) + } + + watchAccount(config, { + onChange(account) { + const accountElement = element.querySelector('#account')! + accountElement.innerHTML = ` +

Account

+
+ status: ${account.status} +
+ addresses: ${ + account.addresses ? JSON.stringify(account.addresses) : '' + } +
+ chainId: ${account.chainId ?? ''} +
+ ${ + account.status === 'connected' + ? `` + : '' + } + ` + + const disconnectButton = + element.querySelector('#disconnect') + if (disconnectButton) + disconnectButton.addEventListener('click', () => disconnect(config)) + }, + }) + + reconnect(config) + .then(() => {}) + .catch(() => {}) +} diff --git a/packages/create-wagmi/templates/vite-vanilla/src/style.css b/packages/create-wagmi/templates/vite-vanilla/src/style.css new file mode 100644 index 0000000000..0733a7ee6b --- /dev/null +++ b/packages/create-wagmi/templates/vite-vanilla/src/style.css @@ -0,0 +1,21 @@ +:root { + background-color: #181818; + color: rgba(255, 255, 255, 0.87); + color-scheme: light dark; + font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; + font-synthesis: none; + font-weight: 400; + line-height: 1.5; + text-rendering: optimizeLegibility; + + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + -webkit-text-size-adjust: 100%; +} + +@media (prefers-color-scheme: light) { + :root { + background-color: #f8f8f8; + color: #181818; + } +} diff --git a/packages/create-wagmi/templates/vite-vanilla/src/vite-env.d.ts b/packages/create-wagmi/templates/vite-vanilla/src/vite-env.d.ts new file mode 100644 index 0000000000..11f02fe2a0 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vanilla/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/packages/create-wagmi/templates/vite-vanilla/src/wagmi.ts b/packages/create-wagmi/templates/vite-vanilla/src/wagmi.ts new file mode 100644 index 0000000000..6baeff5293 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vanilla/src/wagmi.ts @@ -0,0 +1,16 @@ +import { coinbaseWallet, injected, walletConnect } from '@wagmi/connectors' +import { http, createConfig } from '@wagmi/core' +import { mainnet, sepolia } from '@wagmi/core/chains' + +export const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [ + injected(), + coinbaseWallet(), + walletConnect({ projectId: import.meta.env.VITE_WC_PROJECT_ID }), + ], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) diff --git a/packages/create-wagmi/templates/vite-vanilla/tsconfig.json b/packages/create-wagmi/templates/vite-vanilla/tsconfig.json new file mode 100644 index 0000000000..75abdef265 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vanilla/tsconfig.json @@ -0,0 +1,23 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + + /* Bundler mode */ + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + + /* Linting */ + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true + }, + "include": ["src"] +} diff --git a/packages/create-wagmi/templates/vite-vue/README.md b/packages/create-wagmi/templates/vite-vue/README.md new file mode 100644 index 0000000000..15f6f79541 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/README.md @@ -0,0 +1 @@ +This is a [Vite](https://vitejs.dev) project bootstrapped with [`create-wagmi`](https://github.com/wevm/wagmi/tree/main/packages/create-wagmi). diff --git a/packages/create-wagmi/templates/vite-vue/_env.local b/packages/create-wagmi/templates/vite-vue/_env.local new file mode 100644 index 0000000000..936f763762 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/_env.local @@ -0,0 +1 @@ +VITE_WC_PROJECT_ID= \ No newline at end of file diff --git a/packages/create-wagmi/templates/vite-vue/_gitignore b/packages/create-wagmi/templates/vite-vue/_gitignore new file mode 100644 index 0000000000..a547bf36d8 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/_gitignore @@ -0,0 +1,24 @@ +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +pnpm-debug.log* +lerna-debug.log* + +node_modules +dist +dist-ssr +*.local + +# Editor directories and files +.vscode/* +!.vscode/extensions.json +.idea +.DS_Store +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? diff --git a/packages/create-wagmi/templates/vite-vue/_npmrc b/packages/create-wagmi/templates/vite-vue/_npmrc new file mode 100644 index 0000000000..ca1e9d98b5 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/_npmrc @@ -0,0 +1 @@ +legacy-peer-deps = true \ No newline at end of file diff --git a/packages/create-wagmi/templates/vite-vue/biome.json b/packages/create-wagmi/templates/vite-vue/biome.json new file mode 100644 index 0000000000..08eb8a26ab --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/biome.json @@ -0,0 +1,13 @@ +{ + "formatter": { + "enabled": true, + "indentStyle": "space", + "lineWidth": 120 + }, + "linter": { + "enabled": true + }, + "organizeImports": { + "enabled": true + } +} diff --git a/packages/create-wagmi/templates/vite-vue/index.html b/packages/create-wagmi/templates/vite-vue/index.html new file mode 100644 index 0000000000..e2028cc129 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/index.html @@ -0,0 +1,12 @@ + + + + + + Create Wagmi + + +
+ + + diff --git a/packages/create-wagmi/templates/vite-vue/package.json b/packages/create-wagmi/templates/vite-vue/package.json new file mode 100644 index 0000000000..8d306e620c --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/package.json @@ -0,0 +1,24 @@ +{ + "name": "wagmi-vue-vite-starter", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "vue-tsc && vite build", + "lint": "biome check .", + "preview": "vite preview" + }, + "dependencies": { + "@tanstack/vue-query": ">=5.45.0", + "@wagmi/vue": "latest", + "viem": "latest", + "vue": ">=3.4.21" + }, + "devDependencies": { + "@vitejs/plugin-vue": "^5.0.4", + "buffer": "^6.0.3", + "vite": "^5.2.11", + "vue-tsc": "^2.0.6" + } +} diff --git a/packages/create-wagmi/templates/vite-vue/src/App.vue b/packages/create-wagmi/templates/vite-vue/src/App.vue new file mode 100644 index 0000000000..421aeb9a7b --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/src/App.vue @@ -0,0 +1,19 @@ + + + diff --git a/packages/create-wagmi/templates/vite-vue/src/components/Account.vue b/packages/create-wagmi/templates/vite-vue/src/components/Account.vue new file mode 100644 index 0000000000..33f1491dac --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/src/components/Account.vue @@ -0,0 +1,22 @@ + + + diff --git a/packages/create-wagmi/templates/vite-vue/src/components/Connect.vue b/packages/create-wagmi/templates/vite-vue/src/components/Connect.vue new file mode 100644 index 0000000000..93320448c0 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/src/components/Connect.vue @@ -0,0 +1,19 @@ + + + diff --git a/packages/create-wagmi/templates/vite-vue/src/main.ts b/packages/create-wagmi/templates/vite-vue/src/main.ts new file mode 100644 index 0000000000..820eed3722 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/src/main.ts @@ -0,0 +1,17 @@ +import { Buffer } from 'buffer' +import { VueQueryPlugin } from '@tanstack/vue-query' +import { WagmiPlugin } from '@wagmi/vue' +import { createApp } from 'vue' + +// `@coinbase-wallet/sdk` uses `Buffer` +globalThis.Buffer = Buffer + +import App from './App.vue' +import './style.css' +import { config } from './wagmi' + +const app = createApp(App) + +app.use(WagmiPlugin, { config }).use(VueQueryPlugin, {}) + +app.mount('#app') diff --git a/packages/create-wagmi/templates/vite-vue/src/style.css b/packages/create-wagmi/templates/vite-vue/src/style.css new file mode 100644 index 0000000000..0733a7ee6b --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/src/style.css @@ -0,0 +1,21 @@ +:root { + background-color: #181818; + color: rgba(255, 255, 255, 0.87); + color-scheme: light dark; + font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; + font-synthesis: none; + font-weight: 400; + line-height: 1.5; + text-rendering: optimizeLegibility; + + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + -webkit-text-size-adjust: 100%; +} + +@media (prefers-color-scheme: light) { + :root { + background-color: #f8f8f8; + color: #181818; + } +} diff --git a/packages/create-wagmi/templates/vite-vue/src/vite-env.d.ts b/packages/create-wagmi/templates/vite-vue/src/vite-env.d.ts new file mode 100644 index 0000000000..11f02fe2a0 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/packages/create-wagmi/templates/vite-vue/src/wagmi.ts b/packages/create-wagmi/templates/vite-vue/src/wagmi.ts new file mode 100644 index 0000000000..f0282e9490 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/src/wagmi.ts @@ -0,0 +1,25 @@ +import { http, createConfig, createStorage } from '@wagmi/vue' +import { mainnet, optimism, sepolia } from '@wagmi/vue/chains' +import { coinbaseWallet, walletConnect } from '@wagmi/vue/connectors' + +export const config = createConfig({ + chains: [mainnet, sepolia, optimism], + connectors: [ + walletConnect({ + projectId: import.meta.env.VITE_WC_PROJECT_ID, + }), + coinbaseWallet({ appName: 'Vite Vue Playground', darkMode: true }), + ], + storage: createStorage({ storage: localStorage, key: 'vite-vue' }), + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + [optimism.id]: http(), + }, +}) + +declare module '@wagmi/vue' { + interface Register { + config: typeof config + } +} diff --git a/packages/create-wagmi/templates/vite-vue/tsconfig.json b/packages/create-wagmi/templates/vite-vue/tsconfig.json new file mode 100644 index 0000000000..9e03e60496 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + + /* Bundler mode */ + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "preserve", + + /* Linting */ + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true + }, + "include": ["src/**/*.ts", "src/**/*.tsx", "src/**/*.vue"], + "references": [{ "path": "./tsconfig.node.json" }] +} diff --git a/packages/create-wagmi/templates/vite-vue/tsconfig.node.json b/packages/create-wagmi/templates/vite-vue/tsconfig.node.json new file mode 100644 index 0000000000..97ede7ee6f --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/tsconfig.node.json @@ -0,0 +1,11 @@ +{ + "compilerOptions": { + "composite": true, + "skipLibCheck": true, + "module": "ESNext", + "moduleResolution": "bundler", + "allowSyntheticDefaultImports": true, + "strict": true + }, + "include": ["vite.config.ts"] +} diff --git a/packages/create-wagmi/templates/vite-vue/vite.config.ts b/packages/create-wagmi/templates/vite-vue/vite.config.ts new file mode 100644 index 0000000000..c3fa62d865 --- /dev/null +++ b/packages/create-wagmi/templates/vite-vue/vite.config.ts @@ -0,0 +1,7 @@ +import vue from '@vitejs/plugin-vue' +import { defineConfig } from 'vite' + +// https://vitejs.dev/config/ +export default defineConfig({ + plugins: [vue()], +}) diff --git a/packages/create-wagmi/tsconfig.build.json b/packages/create-wagmi/tsconfig.build.json new file mode 100644 index 0000000000..45ae2069ef --- /dev/null +++ b/packages/create-wagmi/tsconfig.build.json @@ -0,0 +1,8 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["src/**/*.ts"], + "exclude": ["src/**/*.test.ts"], + "compilerOptions": { + "sourceMap": true + } +} diff --git a/packages/create-wagmi/tsconfig.json b/packages/create-wagmi/tsconfig.json new file mode 100644 index 0000000000..bd33919ac3 --- /dev/null +++ b/packages/create-wagmi/tsconfig.json @@ -0,0 +1,5 @@ +{ + "extends": "./tsconfig.build.json", + "include": ["src/**/*.ts"], + "exclude": [] +} diff --git a/packages/indexer/CHANGELOG.md b/packages/indexer/CHANGELOG.md index 5eac945aaf..88b541e93e 100644 --- a/packages/indexer/CHANGELOG.md +++ b/packages/indexer/CHANGELOG.md @@ -1,1358 +1,3365 @@ -# @0xsequence/indexer +# @wagmi/core -## 1.10.8 +## 2.17.2 ### Patch Changes -- update metadata bindings +- [`29297a48af72b537173d948ccd2fe37d39914c66`](https://github.com/wevm/wagmi/commit/29297a48af72b537173d948ccd2fe37d39914c66) Thanks [@jxom](https://github.com/jxom)! - Fixed `sendCalls` generics. -## 1.10.7 +- [`07370106d5fb6b8fe300992d93abf25b3d0eaf57`](https://github.com/wevm/wagmi/commit/07370106d5fb6b8fe300992d93abf25b3d0eaf57) Thanks [@jxom](https://github.com/jxom)! - Fixed propagation of `waitForCallsStatus` parameters. + +## 2.17.1 ### Patch Changes -- minor fixes to waas client +- [#4649](https://github.com/wevm/wagmi/pull/4649) [`01f64e64fa4f85cdd30023903f972f4f9023681f`](https://github.com/wevm/wagmi/commit/01f64e64fa4f85cdd30023903f972f4f9023681f) Thanks [@jxom](https://github.com/jxom)! - Added `chainId` parameter to `getCapabilities`/`useCapabilities`. -## 1.10.6 +## 2.17.0 -### Patch Changes +### Minor Changes -- metadata: update bindings +- [#4638](https://github.com/wevm/wagmi/pull/4638) [`799ee4d4b23c2ecd64e3f3668e67634e81939719`](https://github.com/wevm/wagmi/commit/799ee4d4b23c2ecd64e3f3668e67634e81939719) Thanks [@jxom](https://github.com/jxom)! - Stabilized EIP-5792 Actions & Hooks. -## 1.10.5 +## 2.16.7 ### Patch Changes -- network: ape-chain-testnet -> apechain-testnet +- [`a4bd0623eed28e3761a27295831a60ad835f0ee0`](https://github.com/wevm/wagmi/commit/a4bd0623eed28e3761a27295831a60ad835f0ee0) Thanks [@jxom](https://github.com/jxom)! - **Experimental (EIP-5792):** Updated `id` parameter to be optional on `useWaitForCallsStatus`. -## 1.10.4 +## 2.16.6 ### Patch Changes -- network: add b3-sepolia, ape-chain-testnet, blast, blast-sepolia +- [#4586](https://github.com/wevm/wagmi/pull/4586) [`edf47477b2f6385a1c3ae01d36a8498c47f30a0b`](https://github.com/wevm/wagmi/commit/edf47477b2f6385a1c3ae01d36a8498c47f30a0b) Thanks [@jxom](https://github.com/jxom)! - **Experimental (EIP-5792):** Added `waitForCallsStatus` + `useWaitForCallsStatus`. -## 1.10.3 +## 2.16.5 ### Patch Changes -- typing fix +- [`d0c9a86921a4e939373cc6e763284e53f2a2e93c`](https://github.com/wevm/wagmi/commit/d0c9a86921a4e939373cc6e763284e53f2a2e93c) Thanks [@jxom](https://github.com/jxom)! - **Experimental (ERC-5792)**: Added support for `account: null` in `sendCalls` to cater for sending calls without a connected account (account will be filled by the wallet). -## 1.10.2 +## 2.16.4 ### Patch Changes -- - waas: add getIdToken method - - indexer: update api client +- [`507f864d91238bfd423d0e36d3619eb9f6e52eec`](https://github.com/wevm/wagmi/commit/507f864d91238bfd423d0e36d3619eb9f6e52eec) Thanks [@jxom](https://github.com/jxom)! - Updated `@coinbase/wallet-sdk`. -## 1.10.1 +## 2.16.3 ### Patch Changes -- metadata: update bindings +- [#4480](https://github.com/wevm/wagmi/pull/4480) [`384a1d91597622eb59e1c05dc13ce25017c5b6d8`](https://github.com/wevm/wagmi/commit/384a1d91597622eb59e1c05dc13ce25017c5b6d8) Thanks [@RodeRickIsWatching](https://github.com/RodeRickIsWatching)! - Fixed invocation of default storage. -## 1.10.0 +## 2.16.2 -### Minor Changes +### Patch Changes -- waas release v1.3.0 +- [`012907032b532a438fce48f407470250cbc8f0c6`](https://github.com/wevm/wagmi/commit/012907032b532a438fce48f407470250cbc8f0c6) Thanks [@jxom](https://github.com/jxom)! - Fixed assignment in `getDefaultStorage`. -## 1.9.37 +## 2.16.1 ### Patch Changes -- network: adds nativeToken data to NetworkMetadata constants +- [#4472](https://github.com/wevm/wagmi/pull/4472) [`3892ebd21c06beef4b28ece4e70d2a38807bce6f`](https://github.com/wevm/wagmi/commit/3892ebd21c06beef4b28ece4e70d2a38807bce6f) Thanks [@tmm](https://github.com/tmm)! - Added handling to default storage for `setItem` errors, like `QuotaExceededError`, `SecurityError`, etc. + +## 2.16.0 + +### Minor Changes -## 1.9.36 +- [#4453](https://github.com/wevm/wagmi/pull/4453) [`070e48480194c8d7f45bda1d7dd1346e6f5d7227`](https://github.com/wevm/wagmi/commit/070e48480194c8d7f45bda1d7dd1346e6f5d7227) Thanks [@tmm](https://github.com/tmm)! - Added narrowing to `config.connectors`. ### Patch Changes -- guard: export client +- [`afea6b67822a7a2b96901ec851441d27ee0f7a52`](https://github.com/wevm/wagmi/commit/afea6b67822a7a2b96901ec851441d27ee0f7a52) Thanks [@tmm](https://github.com/tmm)! - Passed through parameters to `connector.connect` in `connect` action. -## 1.9.35 +## 2.15.2 ### Patch Changes -- guard: update bindings +- [#4433](https://github.com/wevm/wagmi/pull/4433) [`06e186cd679b27fe195309110e766fcf46d4efbc`](https://github.com/wevm/wagmi/commit/06e186cd679b27fe195309110e766fcf46d4efbc) Thanks [@Aerilym](https://github.com/Aerilym)! - Bumped Metamask SDK version to `0.31.1`. -## 1.9.34 +## 2.15.1 ### Patch Changes -- waas: always use lowercase email +- [`b8bbb409f4934538e3dd6cac5aaf7346292d0693`](https://github.com/wevm/wagmi/commit/b8bbb409f4934538e3dd6cac5aaf7346292d0693) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where `null` gas would accidentally pass through. -## 1.9.33 +## 2.15.0 -### Patch Changes +### Minor Changes -- waas: umd build +- [#4417](https://github.com/wevm/wagmi/pull/4417) [`42e65ea4fea99c639817088bba915e0933d17141`](https://github.com/wevm/wagmi/commit/42e65ea4fea99c639817088bba915e0933d17141) Thanks [@jxom](https://github.com/jxom)! - Removed simulation in `writeContract` & `sendTransaction`. -## 1.9.32 +## 2.14.6 ### Patch Changes -- indexer: update bindings +- [#4406](https://github.com/wevm/wagmi/pull/4406) [`a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3`](https://github.com/wevm/wagmi/commit/a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3) Thanks [@tmm](https://github.com/tmm)! - Added support for multiple connector `rdns` entries. -## 1.9.31 +## 2.14.5 ### Patch Changes -- metadata: token directory changes +- [#4400](https://github.com/wevm/wagmi/pull/4400) [`6b9bbacdc7bffd44fc2165362a5e65fd434e7646`](https://github.com/wevm/wagmi/commit/6b9bbacdc7bffd44fc2165362a5e65fd434e7646) Thanks [@AzzouQ](https://github.com/AzzouQ)! - Fixed `createWatchContractEvent` internal wiring, where `eventName` was incorrectly `functionName`. -## 1.9.30 +## 2.14.4 ### Patch Changes -- update +- [#4311](https://github.com/wevm/wagmi/pull/4311) [`e08681c81fbdf475213e2d0f4c5517d0abf4e743`](https://github.com/wevm/wagmi/commit/e08681c81fbdf475213e2d0f4c5517d0abf4e743) Thanks [@chybisov](https://github.com/chybisov)! - Fixed `injected` connector race condition after calling `'wallet_addEthereumChain'` in `switchChain`. -## 1.9.29 +## 2.14.3 ### Patch Changes -- disable gnosis chain +- [`cb7dd2ebb871d0be8f1a11a8cd8ce592cd74b7c7`](https://github.com/wevm/wagmi/commit/cb7dd2ebb871d0be8f1a11a8cd8ce592cd74b7c7) Thanks [@tmm](https://github.com/tmm)! - Removed unnecessary internal deep equal check in `structuralSharing`. -## 1.9.28 +## 2.14.2 ### Patch Changes -- add utils/merkletree +- [#4339](https://github.com/wevm/wagmi/pull/4339) [`d0d0963bb5904a15cf0355862d62dd141ce0c31c`](https://github.com/wevm/wagmi/commit/d0d0963bb5904a15cf0355862d62dd141ce0c31c) Thanks [@AndriyAntonenko](https://github.com/AndriyAntonenko)! - Fixed bug in `waitForTransactionReceipt`, where transaction data wasn't passed to `'eth_call'` method as part of getting the revert reason. -## 1.9.27 +- [`ecac0ba36243d94c9199d0bd21937104c835d9a0`](https://github.com/wevm/wagmi/commit/ecac0ba36243d94c9199d0bd21937104c835d9a0) Thanks [@tmm](https://github.com/tmm)! - Fixed `getBalance` symbol error handling. + +## 2.14.1 ### Patch Changes -- network: optimistic -> optimism -- waas: remove defaults -- api, sessions: update bindings +- [`052e72e1f8c1c14fcbdce04a9f8fa7ec28d83702`](https://github.com/wevm/wagmi/commit/052e72e1f8c1c14fcbdce04a9f8fa7ec28d83702) Thanks [@tmm](https://github.com/tmm)! - Added `defaultConnected` feature to `mock` connector. + +- [#4349](https://github.com/wevm/wagmi/pull/4349) [`b250fc21ee577b2a75c5a34ff684f62fb4ad771a`](https://github.com/wevm/wagmi/commit/b250fc21ee577b2a75c5a34ff684f62fb4ad771a) Thanks [@tmm](https://github.com/tmm)! - Bumped internal deps. + +## 2.14.0 + +### Minor Changes + +- [#4343](https://github.com/wevm/wagmi/pull/4343) [`f43e074f473820b208a6295d7c97f847332f1a1d`](https://github.com/wevm/wagmi/commit/f43e074f473820b208a6295d7c97f847332f1a1d) Thanks [@tmm](https://github.com/tmm)! - Added `rdns` property to connector interface. This is used to filter out duplicate [EIP-6963](https://eips.ethereum.org/EIPS/eip-6963) injected providers when [`createConfig#multiInjectedProviderDiscovery`](https://wagmi.sh/core/api/createConfig#multiinjectedproviderdiscovery) is enabled and `createConfig#connectors` already matches EIP-6963 providers' `rdns` property. -## 1.9.26 +## 2.13.9 ### Patch Changes -- - add backend interfaces for pluggable interfaces - - introduce @0xsequence/react-native - - update pnpm to lockfile v9 +- [#4336](https://github.com/wevm/wagmi/pull/4336) [`c05caabc20c3ced9682cfc7ba1f3f7dcfece0703`](https://github.com/wevm/wagmi/commit/c05caabc20c3ced9682cfc7ba1f3f7dcfece0703) Thanks [@EdouardBougon](https://github.com/EdouardBougon)! - Added deprecation notice to `injected` target flags. -## 1.9.25 +## 2.13.8 ### Patch Changes -- update webrpc clients with new error types +- [#4207](https://github.com/wevm/wagmi/pull/4207) [`56f2482508f2ba71bd6b0295c70c6abca7101e57`](https://github.com/wevm/wagmi/commit/56f2482508f2ba71bd6b0295c70c6abca7101e57) Thanks [@Smert](https://github.com/Smert)! - Updated chain switch listener for `injected` and `metaMask` to be more robust. -## 1.9.24 +## 2.13.7 ### Patch Changes -- waas: add memoryStore backend to localStore +- [`be75c2d4ef636d7362420ab0a106bfdf63f5d1e6`](https://github.com/wevm/wagmi/commit/be75c2d4ef636d7362420ab0a106bfdf63f5d1e6) Thanks [@tmm](https://github.com/tmm)! - Added guard for missing `provider.on` for `injected` connector. -## 1.9.23 +## 2.13.6 ### Patch Changes -- update api client bindings +- [#4286](https://github.com/wevm/wagmi/pull/4286) [`edcbf5d6fbe92f639bead800502edda9e0aa39f1`](https://github.com/wevm/wagmi/commit/edcbf5d6fbe92f639bead800502edda9e0aa39f1) Thanks [@holic](https://github.com/holic)! - Removed duplicate code. -## 1.9.22 +## 2.13.5 ### Patch Changes -- update metadata client bindings +- [#4259](https://github.com/wevm/wagmi/pull/4259) [`f47ce8f6d263e49fdff90b8edb3190142d2657bb`](https://github.com/wevm/wagmi/commit/f47ce8f6d263e49fdff90b8edb3190142d2657bb) Thanks [@tmm](https://github.com/tmm)! - Added guard to `getConnectorClient` when reconnecting to check if connector is fully restored. -## 1.9.21 +## 2.13.4 ### Patch Changes -- api client bindings +- [`b4c8971788c70b09479946ecfa998cff2f1b3953`](https://github.com/wevm/wagmi/commit/b4c8971788c70b09479946ecfa998cff2f1b3953) Thanks [@tmm](https://github.com/tmm)! - Made `serialize` and `deserialize` types more permissive. -## 1.9.20 +## 2.13.3 ### Patch Changes -- api client bindings update +- [`871dbdbfe59ac8ad01d1ec6150ea7b091b7b7de4`](https://github.com/wevm/wagmi/commit/871dbdbfe59ac8ad01d1ec6150ea7b091b7b7de4) Thanks [@tmm](https://github.com/tmm)! - Added validation to internal state for persisted `chainId`. -## 1.9.19 +## 2.13.2 ### Patch Changes -- waas update +- [`1b9b523fa9b9dfe839aecdf4b40caa9547d7e594`](https://github.com/wevm/wagmi/commit/1b9b523fa9b9dfe839aecdf4b40caa9547d7e594) Thanks [@tmm](https://github.com/tmm)! - Fixed built-in cookie storage `removeItem` working for all paths. -## 1.9.18 +## 2.13.1 ### Patch Changes -- provider: prohibit dangerous functions +- [`07c1227f306d0efb9421d4bb77a774f92f5fcf45`](https://github.com/wevm/wagmi/commit/07c1227f306d0efb9421d4bb77a774f92f5fcf45) Thanks [@tmm](https://github.com/tmm)! - Fixed internal `extractRpcUrls` usage with `unstable_connector`. -## 1.9.17 +## 2.13.0 + +### Minor Changes + +- [#4162](https://github.com/wevm/wagmi/pull/4162) [`a73a7737b756886b388f120ae423e72cca53e8a0`](https://github.com/wevm/wagmi/commit/a73a7737b756886b388f120ae423e72cca53e8a0) Thanks [@jxom](https://github.com/jxom)! - Added functionality for consumer-defined RPC URLs (`config.transports`) to be propagated to the WalletConnect & MetaMask Connectors. + +## 2.12.2 ### Patch Changes -- network: add xr-sepolia +- [`5bc8c8877810b2eec24a829df87dce40a51e6f20`](https://github.com/wevm/wagmi/commit/5bc8c8877810b2eec24a829df87dce40a51e6f20) Thanks [@tmm](https://github.com/tmm)! - Fixed reconnection when `status` is defined. -## 1.9.16 +## 2.12.1 ### Patch Changes -- waas: sequence.feeOptions +- [#4146](https://github.com/wevm/wagmi/pull/4146) [`cc996e08e930c9e88cf753a1e874652059e81a3b`](https://github.com/wevm/wagmi/commit/cc996e08e930c9e88cf753a1e874652059e81a3b) Thanks [@jxom](https://github.com/jxom)! - Updated `@safe-global/safe-apps-sdk` + `@safe-global/safe-apps-provider` dependencies. + +## 2.12.0 + +### Minor Changes + +- [#4128](https://github.com/wevm/wagmi/pull/4128) [`5581a810ef70308e99c6f8b630cd4bca59f64afc`](https://github.com/wevm/wagmi/commit/5581a810ef70308e99c6f8b630cd4bca59f64afc) Thanks [@dalechyn](https://github.com/dalechyn)! - Added `watchAsset` action. -## 1.9.15 +## 2.11.8 ### Patch Changes -- metadata: collection external_link field name fix +- [`b08013eaa9ce97c02f8a7128ea400e3da7ef74bb`](https://github.com/wevm/wagmi/commit/b08013eaa9ce97c02f8a7128ea400e3da7ef74bb) Thanks [@tmm](https://github.com/tmm)! - Fixed injected accounts ordering for `'wallet_requestPermissions'`. -## 1.9.14 +- [`d3814ab4b88f9f0e052b53bc3d458df87b43f01d`](https://github.com/wevm/wagmi/commit/d3814ab4b88f9f0e052b53bc3d458df87b43f01d) Thanks [@jxom](https://github.com/jxom)! - Updated `mipd` dependency. + +## 2.11.7 ### Patch Changes -- network: astar-zkatana -> astar-zkyoto -- network: deprecate polygon mumbai network -- network: add xai and polygon amoy +- [`0bb8b562ae04ecfeb2d6b2f1b980ebae31dc127e`](https://github.com/wevm/wagmi/commit/0bb8b562ae04ecfeb2d6b2f1b980ebae31dc127e) Thanks [@tmm](https://github.com/tmm)! - Improved TypeScript `'exactOptionalPropertyTypes'` support. -## 1.9.13 +## 2.11.6 ### Patch Changes -- waas: fix @0xsequence/network dependency +- [#4060](https://github.com/wevm/wagmi/pull/4060) [`95965c1f19d480b97f2b297a077a9e607dee32ad`](https://github.com/wevm/wagmi/commit/95965c1f19d480b97f2b297a077a9e607dee32ad) Thanks [@dalechyn](https://github.com/dalechyn)! - Bumped Tanstack Query dependencies to fix typing issues between exported Wagmi query options and TanStack Query suspense query methods (due to [`direction` property in `QueryFunctionContext` being deprecated](https://github.com/TanStack/query/pull/7410)). -## 1.9.12 +## 2.11.5 ### Patch Changes -- indexer: update rpc bindings -- provider: signMessage: Serialize the BytesLike or string message into hexstring before sending -- waas: SessionAuthProof +- [#4079](https://github.com/wevm/wagmi/pull/4079) [`04f2b846b113f3d300d82c9fa75212f1805817c5`](https://github.com/wevm/wagmi/commit/04f2b846b113f3d300d82c9fa75212f1805817c5) Thanks [@tmm](https://github.com/tmm)! - Added revalidation for config chain ID in SSR and migration. -## 1.9.11 +## 2.11.4 ### Patch Changes -- metdata, update rpc bindings +- [`9e8345cd56186b997b5e56deaa2cfc69b30d15f6`](https://github.com/wevm/wagmi/commit/9e8345cd56186b997b5e56deaa2cfc69b30d15f6) Thanks [@tmm](https://github.com/tmm)! - Switched `Register` to `interface` to fix declaration merging. -## 1.9.10 +## 2.11.3 ### Patch Changes -- update metadata rpc bindings +- [#4065](https://github.com/wevm/wagmi/pull/4065) [`8974e6269bb5d7bfaa90db0246bc7d13e8bff798`](https://github.com/wevm/wagmi/commit/8974e6269bb5d7bfaa90db0246bc7d13e8bff798) Thanks [@alx-khramov](https://github.com/alx-khramov)! - Added timeout to internal call of `'wallet_revokePermissions'` request during `injected#disconnect` as some wallets that do not support this method hang. -## 1.9.9 +## 2.11.2 ### Patch Changes -- metadata, add SequenceCollections rpc client +- [#4042](https://github.com/wevm/wagmi/pull/4042) [`b4d9ef79deb554ee20fed6666a474be5e7cdd522`](https://github.com/wevm/wagmi/commit/b4d9ef79deb554ee20fed6666a474be5e7cdd522) Thanks [@tmm](https://github.com/tmm)! - Removed `injected` connector `isAuthorized` timeout. -## 1.9.8 +## 2.11.1 ### Patch Changes -- waas client update +- [`9c862d8d63e3d692a22cef2a90782b74a9103f17`](https://github.com/wevm/wagmi/commit/9c862d8d63e3d692a22cef2a90782b74a9103f17) Thanks [@tmm](https://github.com/tmm)! - Reverted internal module loading utility. + +## 2.11.0 + +### Minor Changes -## 1.9.7 +- [#3816](https://github.com/wevm/wagmi/pull/3816) [`06bb598a7f04c7b167f5b7ff6d46bd15886a6a14`](https://github.com/wevm/wagmi/commit/06bb598a7f04c7b167f5b7ff6d46bd15886a6a14) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `deployContract` action. ### Patch Changes -- update rpc client bindings for api, metadata and relayer +- [`24a45b269bd0214a29d6f82a84ac66ef8c3f3822`](https://github.com/wevm/wagmi/commit/24a45b269bd0214a29d6f82a84ac66ef8c3f3822) Thanks [@tmm](https://github.com/tmm)! - Added `SameSite` default to `cookieStorage` -## 1.9.6 +## 2.10.6 ### Patch Changes -- waas package update +- [#4009](https://github.com/wevm/wagmi/pull/4009) [`f2a7cefab96691ebed8b8e45ffde071c47b58dbe`](https://github.com/wevm/wagmi/commit/f2a7cefab96691ebed8b8e45ffde071c47b58dbe) Thanks [@roninjin10](https://github.com/roninjin10)! - Marked `to` as optional for `sendTransaction`. -## 1.9.5 +- [#4023](https://github.com/wevm/wagmi/pull/4023) [`f0ea0b2a7fe193dadfeb49a4c8031ee451c638b5`](https://github.com/wevm/wagmi/commit/f0ea0b2a7fe193dadfeb49a4c8031ee451c638b5) Thanks [@jxom](https://github.com/jxom)! - Added chain check to `getConnectorClient` since it's possible for connection state chain ID to get out of sync with the connector (e.g. [wallet bug](https://github.com/MetaMask/metamask-extension/issues/25097)). + +## 2.10.5 ### Patch Changes -- RpcRelayer prioritize project access key +- [#3970](https://github.com/wevm/wagmi/pull/3970) [`030c7c2cb380dfd67a2182f62e2aa7a6e1601898`](https://github.com/wevm/wagmi/commit/030c7c2cb380dfd67a2182f62e2aa7a6e1601898) Thanks [@nanxiaobei](https://github.com/nanxiaobei)! - Fixed `cookieStorage` not working across paths. -## 1.9.4 +## 2.10.4 ### Patch Changes -- waas: fix network dependency +- [#3984](https://github.com/wevm/wagmi/pull/3984) [`51fde8a0433b4fff357c1a8d7e08b41b4c86c968`](https://github.com/wevm/wagmi/commit/51fde8a0433b4fff357c1a8d7e08b41b4c86c968) Thanks [@tmm](https://github.com/tmm)! - Fixed `writeContract` query types for `value` property. -## 1.9.3 +## 2.10.3 ### Patch Changes -- provider: don't append access key to RPC url if user has already provided it +- [#3962](https://github.com/wevm/wagmi/pull/3962) [`2804a8a583b1874271154898b4bae38756ef581c`](https://github.com/wevm/wagmi/commit/2804a8a583b1874271154898b4bae38756ef581c) Thanks [@tmm](https://github.com/tmm)! - Added catch to `reconnect`. -## 1.9.2 +## 2.10.2 ### Patch Changes -- network: add xai-sepolia +- [#3940](https://github.com/wevm/wagmi/pull/3940) [`a5071f581dfdfb961718873643a2fc629101c72a`](https://github.com/wevm/wagmi/commit/a5071f581dfdfb961718873643a2fc629101c72a) Thanks [@jxom](https://github.com/jxom)! - Fixed usage of `metaMask` connector in Vite environments. -## 1.9.1 +## 2.10.1 ### Patch Changes -- analytics fix +- Bumped versions. -## 1.9.0 +## 2.10.0 ### Minor Changes -- waas release +- [#3928](https://github.com/wevm/wagmi/pull/3928) [`3117e71825f9c58a0d718f3d1686f1a191fa9cb1`](https://github.com/wevm/wagmi/commit/3117e71825f9c58a0d718f3d1686f1a191fa9cb1) Thanks [@tmm](https://github.com/tmm)! - Updated the default Coinbase SDK in `coinbaseWallet` Connector to v4.x. -## 1.8.8 +## 2.9.8 ### Patch Changes -- update metadata bindings +- [#3906](https://github.com/wevm/wagmi/pull/3906) [`32fcb4a31dde6b0206961d8ffe9c651f8a459c67`](https://github.com/wevm/wagmi/commit/32fcb4a31dde6b0206961d8ffe9c651f8a459c67) Thanks [@tmm](https://github.com/tmm)! - Added support for Vue. -## 1.8.7 +## 2.9.7 ### Patch Changes -- provider: update databeat to 0.9.1 +- [#3924](https://github.com/wevm/wagmi/pull/3924) [`1f58734f88458e0f6adb05c99f0c90f36ab286b8`](https://github.com/wevm/wagmi/commit/1f58734f88458e0f6adb05c99f0c90f36ab286b8) Thanks [@jxom](https://github.com/jxom)! - Refactored `isChainsStale` logic in `walletConnect` connector. -## 1.8.6 +## 2.9.6 ### Patch Changes -- guard: SignedOwnershipProof +- [#3917](https://github.com/wevm/wagmi/pull/3917) [`05948fdad5bb4a56b08916d45b3dec2cb1e5f55b`](https://github.com/wevm/wagmi/commit/05948fdad5bb4a56b08916d45b3dec2cb1e5f55b) Thanks [@jxom](https://github.com/jxom)! - Updated `@metamask/sdk`. -## 1.8.5 +## 2.9.5 ### Patch Changes -- guard: signOwnershipProof and isSignedOwnershipProof +- [`4fecbbb66d0aacd03b8c62a6455d11a33cde8f85`](https://github.com/wevm/wagmi/commit/4fecbbb66d0aacd03b8c62a6455d11a33cde8f85) Thanks [@jxom](https://github.com/jxom)! - Fixed address comparison in `getConnectorClient`. -## 1.8.4 +## 2.9.4 ### Patch Changes -- network: add homeverse to networks list +- [#3910](https://github.com/wevm/wagmi/pull/3910) [`e6139a97c4b8804d734b1547b5e3921ce01fbe24`](https://github.com/wevm/wagmi/commit/e6139a97c4b8804d734b1547b5e3921ce01fbe24) Thanks [@tmm](https://github.com/tmm)! - Added experimental `wallet_revokePermissions` support to `injected`. -## 1.8.3 +## 2.9.3 ### Patch Changes -- api: introduce basic linked wallet support +- [#3904](https://github.com/wevm/wagmi/pull/3904) [`addca28ebc20f1a4367c35fe9ef786decff9c87e`](https://github.com/wevm/wagmi/commit/addca28ebc20f1a4367c35fe9ef786decff9c87e) Thanks [@jxom](https://github.com/jxom)! - Updated `@walletconnect/ethereum-provider`. -## 1.8.2 +## 2.9.2 ### Patch Changes -- provider: don't initialize analytics unless explicitly requested +- [#3902](https://github.com/wevm/wagmi/pull/3902) [`204b7b624612405500ec098fb9e35facd3f74ca4`](https://github.com/wevm/wagmi/commit/204b7b624612405500ec098fb9e35facd3f74ca4) Thanks [@jxom](https://github.com/jxom)! - Made third-party SDK imports type-only. -## 1.8.1 +## 2.9.1 ### Patch Changes -- update to analytics provider +- [`cda6a5d5`](https://github.com/wevm/wagmi/commit/cda6a5d56328330fbde050b4ef40b01c58d2519a) Thanks [@jxom](https://github.com/jxom)! - Updated packages. -## 1.8.0 +## 2.9.0 ### Minor Changes -- provider: project analytics +- [#3878](https://github.com/wevm/wagmi/pull/3878) [`017828fc`](https://github.com/wevm/wagmi/commit/017828fc027c7a84b54ea9d627e9389f4d60d6c2) Thanks [@jxom](https://github.com/jxom)! - Added experimental EIP-5792 Actions & Hooks. -## 1.7.2 +## 2.8.1 ### Patch Changes -- 0xsequence: ChainId should not be exported as a type -- account, wallet: fix nonce selection +- [#3869](https://github.com/wevm/wagmi/pull/3869) [`d4a78eb0`](https://github.com/wevm/wagmi/commit/d4a78eb07119d2e5617e52481ac7d6c6d1583ddc) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where `prepareTransactionRequest` would internally call unsupported wallet RPC methods. + +## 2.8.0 + +### Minor Changes -## 1.7.1 +- [#3868](https://github.com/wevm/wagmi/pull/3868) [`c2af20b8`](https://github.com/wevm/wagmi/commit/c2af20b88cf16970d087faaec10b463357a5836e) Thanks [@jxom](https://github.com/jxom)! - Added `supportsSimulation` property to connectors that indicates if the connector's wallet supports contract simulation. ### Patch Changes -- network: add missing avalanche logoURI +- [#3858](https://github.com/wevm/wagmi/pull/3858) [`0d141f17`](https://github.com/wevm/wagmi/commit/0d141f171d6ec44bcbfc9c876565b5e2fb8af6de) Thanks [@yulafezmesi](https://github.com/yulafezmesi)! - Fixed accessing reverted reason property inside `waitForTransactionReceipt`. -## 1.7.0 +## 2.7.0 ### Minor Changes -- provider: projectAccessKey is now required +- [#3857](https://github.com/wevm/wagmi/pull/3857) [`d4274c03`](https://github.com/wevm/wagmi/commit/d4274c03a6af5f2d26d31432016ebc14950a330e) Thanks [@tmm](https://github.com/tmm)! - Added `addEthereumChainParameter` to `switchChain`-related methods. ### Patch Changes -- network: add NetworkMetadata.logoURI property for all networks +- [#3849](https://github.com/wevm/wagmi/pull/3849) [`4781a405`](https://github.com/wevm/wagmi/commit/4781a4056d4ffc2c74f96a75429e9b2cd2417ad8) Thanks [@tmm](https://github.com/tmm)! - Fixed `shimDisconnect: false` behavior. -## 1.6.3 +- [#3859](https://github.com/wevm/wagmi/pull/3859) [`400c960b`](https://github.com/wevm/wagmi/commit/400c960b30d701c134850c695ae903a382c29b5b) Thanks [@holic](https://github.com/holic)! - Added workaround to injected connector for MetaMask bug, where chain switching does not work if target chain RPC `'net_version'` request fails. + +## 2.6.19 ### Patch Changes -- network list update +- [`e3c832a1`](https://github.com/wevm/wagmi/commit/e3c832a12c301f9b0ee129d877b3101d220ba8b2) Thanks [@jxom](https://github.com/jxom)! - Fixed undefined `navigator` issue in MetaMask connector. -## 1.6.2 +## 2.6.18 ### Patch Changes -- auth: projectAccessKey option -- wallet: use 12 bytes for random space +- [#3848](https://github.com/wevm/wagmi/pull/3848) [`dd40a41c`](https://github.com/wevm/wagmi/commit/dd40a41c526ab60a288aff2250ed8dba92a27b16) Thanks [@jxom](https://github.com/jxom)! - Updated MetaMask SDK. -## 1.6.1 +## 2.6.17 ### Patch Changes -- core: add simple config from subdigest support -- core: fix encode tree with subdigest -- account: implement buildOnChainSignature on Account +- [#3822](https://github.com/wevm/wagmi/pull/3822) [`a97bfbae`](https://github.com/wevm/wagmi/commit/a97bfbaeb615cfef04665e5e7348d85d17f960f0) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where Wagmi would not correctly rehydrate the active chain when a persisted store was being used. -## 1.6.0 +## 2.6.16 -### Minor Changes +### Patch Changes + +- [#3788](https://github.com/wevm/wagmi/pull/3788) [`42ad380d`](https://github.com/wevm/wagmi/commit/42ad380d9a5d8bc0f61d73612142dea9d098de5e) Thanks [@tmm](https://github.com/tmm)! - Refactored connectors to remove unnecessarily event listeners. -- account, wallet: parallel transactions by default +## 2.6.15 ### Patch Changes -- provider: emit disconnect on sign out +- [#3782](https://github.com/wevm/wagmi/pull/3782) [`b907d5ac`](https://github.com/wevm/wagmi/commit/b907d5ac3a746bcbccc06d1fe78c5bd8f9a7d685) Thanks [@jxom](https://github.com/jxom)! - Refactored injected connector connection logic. -## 1.5.0 +## 2.6.14 -### Minor Changes +### Patch Changes + +- [#3777](https://github.com/wevm/wagmi/pull/3777) [`b3b54ef1`](https://github.com/wevm/wagmi/commit/b3b54ef179c5fa0d1694d38d4b808549a0550409) Thanks [@desfero](https://github.com/desfero)! - Fixed `writeContract` to forward `chainIn` when simulating contract call + +- [#3779](https://github.com/wevm/wagmi/pull/3779) [`3da20bb8`](https://github.com/wevm/wagmi/commit/3da20bb80e7c3efeef8227ced66ad615370fc242) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `eth_requestAccounts` would be called upon reconnect instead of `eth_accounts`. -- signhub: add 'signing' signer status +- [`a3d1858f`](https://github.com/wevm/wagmi/commit/a3d1858fce448d2b70e36ee692ef1589b74e9d3f) Thanks [@jxom](https://github.com/jxom)! - Fixed hydration conditional in `createConfig`. + +## 2.6.13 ### Patch Changes -- auth: Session.open: onAccountAddress callback -- account: allow empty transaction bundles +- [`b80236dc`](https://github.com/wevm/wagmi/commit/b80236dc623095fe8f1e1d10957d7776fb6ab48b) Thanks [@jxom](https://github.com/jxom)! - Removed unneeded `uniqueBy` check on connectors state. -## 1.4.9 +## 2.6.12 ### Patch Changes -- rename SequenceMetadataClient to SequenceMetadata +- [#3763](https://github.com/wevm/wagmi/pull/3763) [`a59069e9`](https://github.com/wevm/wagmi/commit/a59069e9fab45dd606bb89a7f829fe94c51a5494) Thanks [@tmm](https://github.com/tmm)! - Fixed `getConnectorClient` internal address comparison. -## 1.4.8 +- [#3608](https://github.com/wevm/wagmi/pull/3608) [`0acd3132`](https://github.com/wevm/wagmi/commit/0acd31320f534993af566be5490c2978b6184f66) Thanks [@mqklin](https://github.com/mqklin)! - Disabled `wallet_requestPermissions` prompt when `shimDisconnect` is `false`. + +## 2.6.11 ### Patch Changes -- account: Account.getSigners +- [`e1ca4e63`](https://github.com/wevm/wagmi/commit/e1ca4e637ae6cec7f5902b0a2c0e0efc3b751a1d) Thanks [@tmm](https://github.com/tmm)! - Deprecated `normalizeChainId`. Use `Number` instead. -## 1.4.7 +## 2.6.10 ### Patch Changes -- update indexer client bindings +- [`dbdca8fd`](https://github.com/wevm/wagmi/commit/dbdca8fd14b90c166222a66a373c1b33c06ce019) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where duplicate connectors could be instantiated if injected after page mount. -## 1.4.6 +## 2.6.9 ### Patch Changes -- - add sepolia networks, mark goerli as deprecated - - update indexer client bindings +- [#3715](https://github.com/wevm/wagmi/pull/3715) [`d56edf4f`](https://github.com/wevm/wagmi/commit/d56edf4f27c52acc7a0f57114454b0d3e22cacd6) Thanks [@jxom](https://github.com/jxom)! - Fixed SSR hydration issues. -## 1.4.5 +## 2.6.8 ### Patch Changes -- indexer/metadata: update client bindings -- auth: selectWallet with new address +- [#3643](https://github.com/wevm/wagmi/pull/3643) [`e46bcd47`](https://github.com/wevm/wagmi/commit/e46bcd4738a18da15b53f6612b614379c1985374) Thanks [@TateB](https://github.com/TateB)! - Fixed race condition arising from `reconnect`. -## 1.4.4 +## 2.6.7 ### Patch Changes -- indexer: update bindings -- auth: handle jwt expiry +- [#3642](https://github.com/wevm/wagmi/pull/3642) [`b479b5e8`](https://github.com/wevm/wagmi/commit/b479b5e8a5866cba792862f22e6352c4fb566137) Thanks [@johanneskares](https://github.com/johanneskares)! - Fixed a bug where minification caused the wrong functions to be called on the client. -## 1.4.3 +- [`f5648dd2`](https://github.com/wevm/wagmi/commit/f5648dd28b3576b628f57732b89287f55acbb1c1) Thanks [@jxom](https://github.com/jxom)! - Updated `prepareTransactionRequest` types for `viem@2.8.0`. + +- [`1c1fee6a`](https://github.com/wevm/wagmi/commit/1c1fee6ab8f01f7734ac6ce05093fa8e388beb3e) Thanks [@jxom](https://github.com/jxom)! - Updated `@walletconnect/ethereum-provider`. + +- [#3653](https://github.com/wevm/wagmi/pull/3653) [`88a2d744`](https://github.com/wevm/wagmi/commit/88a2d744a1315908c9e54156026df3ad2435ad44) Thanks [@tash-2s](https://github.com/tash-2s)! - Fixed error occurring when adding chains without explorers to MetaMask. + +## 2.6.6 ### Patch Changes -- guard: return active status from GuardSigner.getAuthMethods +- [#3644](https://github.com/wevm/wagmi/pull/3644) [`a91c0b64`](https://github.com/wevm/wagmi/commit/a91c0b64ba8b3e6537a560e69724eb601f26af27) Thanks [@nishuzumi](https://github.com/nishuzumi)! - Exported types -## 1.4.2 +## 2.6.5 ### Patch Changes -- guard: update bindings +- [#3580](https://github.com/wevm/wagmi/pull/3580) [`c677dcd2`](https://github.com/wevm/wagmi/commit/c677dcd245dccdf69289a3d66dded237b09570a2) Thanks [@tmm](https://github.com/tmm)! - Updated internals. -## 1.4.1 +## 2.6.4 ### Patch Changes -- network: remove unused networks -- signhub: orchestrator interface -- guard: auth methods interface -- guard: update bindings for pin and totp -- guard: no more retry logic +- [#3571](https://github.com/wevm/wagmi/pull/3571) [`7c6618e6`](https://github.com/wevm/wagmi/commit/7c6618e6a0eb1ff39cf8f66b34d3ddc14be538fe) Thanks [@tmm](https://github.com/tmm)! - Fixed `getClient` passthrough properties from `createConfig`. -## 1.4.0 +- [#3558](https://github.com/wevm/wagmi/pull/3558) [`895f28e8`](https://github.com/wevm/wagmi/commit/895f28e873af7c8eda5ca85734ff67c8979fd950) Thanks [@tmm](https://github.com/tmm)! - Fixed connector warnings. -### Minor Changes +## 2.6.3 -- project access key support +### Patch Changes -## 1.3.0 +- [#3533](https://github.com/wevm/wagmi/pull/3533) [`9c3b85dd`](https://github.com/wevm/wagmi/commit/9c3b85dd0a9a4a593e1d7e029345275735330e32) Thanks [@tmm](https://github.com/tmm)! - Fixed `account` property passthrough for actions. -### Minor Changes +- [`2a72214a`](https://github.com/wevm/wagmi/commit/2a72214a2901d6b6ddd39f80238aa0bd4db670a7) Thanks [@tmm](https://github.com/tmm)! - Shimmed EIP-1193 `removeListener` for injected since some wallets do not follow spec. -- signhub: account children +## 2.6.2 ### Patch Changes -- guard: do not throw when building deploy transaction -- network: snowtrace.io -> subnets.avax.network/c-chain +- [#3519](https://github.com/wevm/wagmi/pull/3519) [`414eb048`](https://github.com/wevm/wagmi/commit/414eb048af492caac70c0e874dfc87c30702804a) Thanks [@tmm](https://github.com/tmm)! - Fixed multicall passing through all properties to Viem method. + +- [#3518](https://github.com/wevm/wagmi/pull/3518) [`338e857d`](https://github.com/wevm/wagmi/commit/338e857d8cb2fe85e13d9207bef14cada1c1962d) Thanks [@tmm](https://github.com/tmm)! - Fixed internal store migration between versions. -## 1.2.9 +## 2.6.1 ### Patch Changes -- account: AccountSigner.sendTransaction simulateForFeeOptions -- relayer: update bindings +- [#3510](https://github.com/wevm/wagmi/pull/3510) [`660ff80d`](https://github.com/wevm/wagmi/commit/660ff80d5b046967a446eba43ee54b8359a37d0d) Thanks [@tmm](https://github.com/tmm)! - Fixed issue where connectors returning multiple addresses didn't checksum correctly. -## 1.2.8 +- [#3433](https://github.com/wevm/wagmi/pull/3433) [`101a7dd1`](https://github.com/wevm/wagmi/commit/101a7dd131b0cae2dc25579ecab9044290efd37b) Thanks [@tmm](https://github.com/tmm)! - Fixed `getClient` and `getPublicClient` throwing when used with unconfigured `chainId`. -### Patch Changes +## 2.6.0 + +### Minor Changes -- rename X-Sequence-Token-Key header to X-Access-Key +- [#3496](https://github.com/wevm/wagmi/pull/3496) [`ba7f8a75`](https://github.com/wevm/wagmi/commit/ba7f8a758efb07664c6e401b5e7e325e7c62341b) Thanks [@tmm](https://github.com/tmm)! - Updated action internals to resolve Viem Client actions. -## 1.2.7 +## 2.5.0 -### Patch Changes +### Minor Changes -- add x-sequence-token-key to clients +- [#3461](https://github.com/wevm/wagmi/pull/3461) [`ca98041d`](https://github.com/wevm/wagmi/commit/ca98041d1b39893d90246929485f4db0d1c6f9f7) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `getTransactionConfirmations` action. -## 1.2.6 +## 2.4.0 -### Patch Changes +### Minor Changes -- Fix bind multicall provider +- [#3427](https://github.com/wevm/wagmi/pull/3427) [`370f1b4a`](https://github.com/wevm/wagmi/commit/370f1b4a3f154d181acf381c31c2e7862e22c0e4) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `prepareTransactionRequest` action. -## 1.2.5 +## 2.3.1 ### Patch Changes -- Multicall default configuration fixes +- [#3476](https://github.com/wevm/wagmi/pull/3476) [`3be5bb7b`](https://github.com/wevm/wagmi/commit/3be5bb7b0b38646e12e6da5c762ef74dff66bcc2) Thanks [@jxom](https://github.com/jxom)! - Modified persist strategy to only store "critical" properties that are needed before hydration. + +## 2.3.0 -## 1.2.4 +### Minor Changes + +- [#3459](https://github.com/wevm/wagmi/pull/3459) [`d950b666`](https://github.com/wevm/wagmi/commit/d950b666b56700ca039ce16cdfdf34564991e7f5) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `getEnsText` action. ### Patch Changes -- provider: Adding missing payment provider types to PaymentProviderOption -- provider: WalletRequestHandler.notifyChainChanged +- [#3467](https://github.com/wevm/wagmi/pull/3467) [`90ef39bb`](https://github.com/wevm/wagmi/commit/90ef39bb0f4ecb3c914d317875348e35ba0f4524) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where connectors that share the same provider instance could reconnect when they have never been connected before. -## 1.2.3 +- [`1cfb6e5a`](https://github.com/wevm/wagmi/commit/1cfb6e5a875e707abcee00dd5739e87da05e8c90) Thanks [@jxom](https://github.com/jxom)! - Bumped listener limit on WalletConnect connector. + +## 2.2.1 ### Patch Changes -- auth, provider: connect to accept optional authorizeNonce +- [#3447](https://github.com/wevm/wagmi/pull/3447) [`a02a26ad`](https://github.com/wevm/wagmi/commit/a02a26ad030d3afb78f744377d61b5c60b65d97a) Thanks [@tmm](https://github.com/tmm)! - Fixed account typing. -## 1.2.2 +- [#3443](https://github.com/wevm/wagmi/pull/3443) [`007024a6`](https://github.com/wevm/wagmi/commit/007024a684ddbecf924cdc06dd6a8854fc3d5eeb) Thanks [@jmrossy](https://github.com/jmrossy)! - Fixed invalid `chainId` parameter passed through actions to Viem. + +## 2.2.0 + +### Minor Changes + +- [#3434](https://github.com/wevm/wagmi/pull/3434) [`00bf10a4`](https://github.com/wevm/wagmi/commit/00bf10a428b0d1c5dac35ebf25b19571e033ac26) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `getBytecode` and `getStorageAt` actions. + +- [#3416](https://github.com/wevm/wagmi/pull/3416) [`64c073f6`](https://github.com/wevm/wagmi/commit/64c073f6c2720961e2d6aff986670b73dbfab9c3) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `getTransactionReceipt` action. + +- [#3408](https://github.com/wevm/wagmi/pull/3408) [`fb6c4148`](https://github.com/wevm/wagmi/commit/fb6c4148d9e9e2fccfbe74c8f343b444dc68dec5) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `getProof` action. + +## 2.1.2 ### Patch Changes -- provider: allow createContract calls -- core: check for explicit zero address in contract deployments +- [#3407](https://github.com/wevm/wagmi/pull/3407) [`e00b8205`](https://github.com/wevm/wagmi/commit/e00b82058685751637edfa9a6b2d196a12549fe7) Thanks [@jxom](https://github.com/jxom)! - Added a prelude gas estimate check to `sendTransaction`/`useSendTransaction`. -## 1.2.1 +## 2.1.1 ### Patch Changes -- auth: use sequence api chain id as reference chain id if available +- [#3402](https://github.com/wevm/wagmi/pull/3402) [`64b82282`](https://github.com/wevm/wagmi/commit/64b82282c1e57e77c25aa0814673780e4d11edd4) Thanks [@Songkeys](https://github.com/Songkeys)! - Fixed SSR cookie support for cookies that have special characters, e.g. `=`. -## 1.2.0 +- [`ec0d8b41`](https://github.com/wevm/wagmi/commit/ec0d8b4112181fefb11025e436a94a6114761d37) Thanks [@tmm](https://github.com/tmm)! - Added note to `metaMask` connector. + +## 2.1.0 ### Minor Changes -- split services from session, better local support +- [#3387](https://github.com/wevm/wagmi/pull/3387) [`c9cd302e`](https://github.com/wevm/wagmi/commit/c9cd302e1c65c980deaee2e12567c2a8ec08b399) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `call` action. -## 1.1.15 +## 2.0.2 ### Patch Changes -- guard: remove error filtering +- [#3384](https://github.com/wevm/wagmi/pull/3384) [`ee868c33`](https://github.com/wevm/wagmi/commit/ee868c3385dae511230b6ddcb5627c1293cc1844) Thanks [@tmm](https://github.com/tmm)! - Fixed connectors not bubbling error when connecting with `chainId` and subsequent user rejection. -## 1.1.14 +## 2.0.1 -### Patch Changes +### Major Changes -- guard: add GuardSigner.onError +- [#3333](https://github.com/wevm/wagmi/pull/3333) [`b3a0baaa`](https://github.com/wevm/wagmi/commit/b3a0baaaee7decf750d376aab2502cd33ca4825a) Thanks [@tmm](https://github.com/tmm)! - Wagmi Core 2.0 featuring: -## 1.1.13 + - Full TanStack Query support + queryKeys + - Connect multiple connectors + - Switch chains while disconnected + - EIP-6963 enabled + - Strongly typed chainId and chain properties + - Smaller bundle size + - Miscellaneous improvements and bug fixes + + [Breaking Changes & Migration Guide](https://wagmi.sh/core/guides/migrate-from-v1-to-v2) + +## 1.4.13 ### Patch Changes -- provider: pass client version with connect options -- provider: removing large from BannerSize +- Updated dependencies [[`bbbbf587`](https://github.com/wevm/wagmi/commit/bbbbf587e41bae12b072b7a7c897d580fc07cd2b)]: + - @wagmi/connectors@3.1.11 -## 1.1.12 +## 1.4.12 ### Patch Changes -- provider: adding bannerSize to ConnectOptions +- [`53ca1f7e`](https://github.com/wevm/wagmi/commit/53ca1f7eb411d912e11fcce7e03bd61ed067959c) Thanks [@tmm](https://github.com/tmm)! - Removed LedgerConnector due to security vulnerability -## 1.1.11 +- Updated dependencies [[`53ca1f7e`](https://github.com/wevm/wagmi/commit/53ca1f7eb411d912e11fcce7e03bd61ed067959c)]: + - @wagmi/connectors@3.1.10 + +## 1.4.11 ### Patch Changes -- add homeverse configs +- [#3299](https://github.com/wevm/wagmi/pull/3299) [`b02020b3`](https://github.com/wevm/wagmi/commit/b02020b3724e0228198f35817611bb063295906e) Thanks [@dasanra](https://github.com/dasanra)! - Fixed issue with [Safe SDK](https://github.com/wevm/viem/issues/579) by bumping `@safe-global/safe-apps-provider@0.18.1` + +- Updated dependencies [[`51eca0fb`](https://github.com/wevm/wagmi/commit/51eca0fbaea6932f31a5b8b4213f0252280053e2), [`b02020b3`](https://github.com/wevm/wagmi/commit/b02020b3724e0228198f35817611bb063295906e)]: + - @wagmi/connectors@3.1.9 -## 1.1.10 +## 1.4.10 ### Patch Changes -- handle default EIP6492 on send +- Updated dependencies [[`e8f7bcbc`](https://github.com/wevm/wagmi/commit/e8f7bcbcd9c038a901c29e71769682c088efe2ac)]: + - @wagmi/connectors@3.1.8 -## 1.1.9 +## 1.4.9 ### Patch Changes -- Custom default EIP6492 on client +- [#3276](https://github.com/wevm/wagmi/pull/3276) [`83223a06`](https://github.com/wevm/wagmi/commit/83223a0659e2f675d897a1d3374c7af752c16abf) Thanks [@glitch-txs](https://github.com/glitch-txs)! - Removed required namespaces from WalletConnect connector + +- Updated dependencies [[`83223a06`](https://github.com/wevm/wagmi/commit/83223a0659e2f675d897a1d3374c7af752c16abf)]: + - @wagmi/connectors@3.1.7 -## 1.1.8 +## 1.4.8 ### Patch Changes -- metadata: searchMetadata: add types filter +- Updated dependencies [[`cc7e18f2`](https://github.com/wevm/wagmi/commit/cc7e18f2e7f6b8b989f60f0b05aee70e996a9975), [`cc7e18f2`](https://github.com/wevm/wagmi/commit/cc7e18f2e7f6b8b989f60f0b05aee70e996a9975)]: + - @wagmi/connectors@3.1.6 -## 1.1.7 +## 1.4.7 ### Patch Changes -- adding signInWith connect settings option to allow dapps to automatically login their users with a certain provider optimizing the normal authentication flow +- Updated dependencies [[`a1950449`](https://github.com/wagmi-dev/wagmi/commit/a1950449127ddf72fff8ecd1fc34c3690befbb05)]: + - @wagmi/connectors@3.1.5 -## 1.1.6 +## 1.4.6 ### Patch Changes -- metadata: searchMetadata: add chainID and excludeTokenMetadata filters +- Updated dependencies [[`4e6ec415`](https://github.com/wagmi-dev/wagmi/commit/4e6ec4151baece94e940e227e0e3711c7f8534d9)]: + - @wagmi/connectors@3.1.4 -## 1.1.5 +## 1.4.5 ### Patch Changes -- account: re-compute meta-transaction id for wallet deployment transactions +- Updated dependencies [[`e78aa337`](https://github.com/wagmi-dev/wagmi/commit/e78aa337c454f04b41a3cbd381d25270dd4a0afd)]: + - @wagmi/connectors@3.1.3 -## 1.1.4 +## 1.4.4 ### Patch Changes -- network: rename base-mainnet to base -- provider: override isDefaultChain with ConnectOptions.networkId if provided +- [#3125](https://github.com/wagmi-dev/wagmi/pull/3125) [`725e73fe`](https://github.com/wagmi-dev/wagmi/commit/725e73feb9143dbaa6d540bb76d2009cef29da0b) Thanks [@lukasrosario](https://github.com/lukasrosario)! - Fixed an issue where `dataSuffix` was not being passed down into viem's `simulateContract`, causing the data to be omitted from requests. -## 1.1.3 +## 1.4.3 ### Patch Changes -- provider: use network id from transport session -- provider: sign authorization using ConnectOptions.networkId if provided +- [#3076](https://github.com/wagmi-dev/wagmi/pull/3076) [`4c36831b`](https://github.com/wagmi-dev/wagmi/commit/4c36831b7aa44d03b5c0decf64dcd20faae28a67) Thanks [@jxom](https://github.com/jxom)! - Pass `chain` to viem `sendTransaction`/`writeContract`. -## 1.1.2 +- [#3006](https://github.com/wagmi-dev/wagmi/pull/3006) [`f2ddce23`](https://github.com/wagmi-dev/wagmi/commit/f2ddce23324aff0a91e066100918dac552dc3b4a) Thanks [@jxom](https://github.com/jxom)! - Changed `normalize` to a dynamic import. + +## 1.4.2 ### Patch Changes -- provider: jsonrpc chain id fixes +- Updated dependencies [[`3aaba328`](https://github.com/wagmi-dev/wagmi/commit/3aaba32808ddb4035ec885f96992c91078056715)]: + - @wagmi/connectors@3.1.2 -## 1.1.1 +## 1.4.1 ### Patch Changes -- network: add base mainnet and sepolia -- provider: reject toxic transaction requests +- Updated dependencies [[`bf831bb3`](https://github.com/wagmi-dev/wagmi/commit/bf831bb30df8037cc4312342d0fe3c045408c2fe)]: + - @wagmi/connectors@3.1.1 -## 1.1.0 +## 1.4.0 ### Minor Changes -- Refactor dapp facing provider - -## 1.0.5 +- [#2956](https://github.com/wagmi-dev/wagmi/pull/2956) [`2abeb285`](https://github.com/wagmi-dev/wagmi/commit/2abeb285674af3e539cc2550b1f5027b1eb0c895) Thanks [@tmm](https://github.com/tmm)! - Replaced `@wagmi/chains` with `viem/chains`. ### Patch Changes -- network: export network constants -- guard: use the correct global for fetch -- network: nova-explorer.arbitrum.io -> nova.arbiscan.io +- Updated dependencies [[`2abeb285`](https://github.com/wagmi-dev/wagmi/commit/2abeb285674af3e539cc2550b1f5027b1eb0c895)]: + - @wagmi/connectors@3.1.0 -## 1.0.4 +## 1.3.10 ### Patch Changes -- provider: accept name or number for networkId +- [`557e6400`](https://github.com/wagmi-dev/wagmi/commit/557e6400b9cef3b2c5131739143956c37d7c934a) Thanks [@jxom](https://github.com/jxom)! - Updated references. -## 1.0.3 +## 1.3.9 ### Patch Changes -- Simpler isValidSignature helpers +- [`247c5d11`](https://github.com/wagmi-dev/wagmi/commit/247c5d113e83acf3a6894264c00d4b125d455107) Thanks [@jxom](https://github.com/jxom)! - Updated references. -## 1.0.2 +## 1.3.8 ### Patch Changes -- add extra signature validation utils methods +- [#2741](https://github.com/wagmi-dev/wagmi/pull/2741) [`5b1453d9`](https://github.com/wagmi-dev/wagmi/commit/5b1453d95973ed51f1c235a919fffb707eab9b70) Thanks [@jxom](https://github.com/jxom)! - Updated references -## 1.0.1 +## 1.3.7 ### Patch Changes -- add homeverse testnet +- [#2700](https://github.com/wagmi-dev/wagmi/pull/2700) [`30118e97`](https://github.com/wagmi-dev/wagmi/commit/30118e979b1b00302e035f31f58c15d1aed911d5) Thanks [@jxom](https://github.com/jxom)! - Updated references. -## 1.0.0 +## 1.3.6 -### Major Changes +### Patch Changes -- https://sequence.xyz/blog/sequence-wallet-light-state-sync-full-merkle-wallets +- [`7ad2fdb8`](https://github.com/wagmi-dev/wagmi/commit/7ad2fdb81c7734d0c8107670800c68390e3bad99) Thanks [@jxom](https://github.com/jxom)! - Updated references. -## 0.43.34 +## 1.3.5 ### Patch Changes -- auth: no jwt for indexer +- [`aab63fc1`](https://github.com/wagmi-dev/wagmi/commit/aab63fc1f8949004573978ecd8574fada3360758) Thanks [@jxom](https://github.com/jxom)! - Updated references. -## 0.43.33 +## 1.3.4 ### Patch Changes -- Adding onConnectOptionsChange handler to WalletRequestHandler +- [`22246d98`](https://github.com/wagmi-dev/wagmi/commit/22246d9884277d28ccad6ca2d9529b96b67d47fc) Thanks [@jxom](https://github.com/jxom)! - Updated references. -## 0.43.32 +## 1.3.3 ### Patch Changes -- add Base Goerli network +- [`1946aa43`](https://github.com/wagmi-dev/wagmi/commit/1946aa43a65b684ef41b7b4c43c67bf29c13e854) Thanks [@jxom](https://github.com/jxom)! - Updated references -## 0.43.31 +## 1.3.2 ### Patch Changes -- remove AuxDataProvider, add promptSignInConnect +- [`e86d0940`](https://github.com/wagmi-dev/wagmi/commit/e86d09409bb20b64d24e1263abcf0291314f03c7) Thanks [@jxom](https://github.com/jxom)! - Updated references -## 0.43.30 +## 1.3.1 ### Patch Changes -- add arbitrum goerli testnet +- [`964042fa`](https://github.com/wagmi-dev/wagmi/commit/964042fa94d682977923c595820c58283fb9244a) Thanks [@jxom](https://github.com/jxom)! - Updated references. -## 0.43.29 +## 1.3.0 -### Patch Changes +### Minor Changes -- provider: check availability of window object +- [#2619](https://github.com/wagmi-dev/wagmi/pull/2619) [`0d79748c`](https://github.com/wagmi-dev/wagmi/commit/0d79748cec2b6ac2410ad2c9816cc662f2b70962) Thanks [@jxom](https://github.com/jxom)! - Updated references: + - Updated `@safe-global/safe-apps-sdk` to `^8.0.0` (the one with `viem` support) -## 0.43.28 +## 1.2.2 ### Patch Changes -- update api bindings +- [#2611](https://github.com/wagmi-dev/wagmi/pull/2611) [`6d1ed7a1`](https://github.com/wagmi-dev/wagmi/commit/6d1ed7a156729b4df5d66fef3ae9a8b5762a2d34) Thanks [@jxom](https://github.com/jxom)! - Updated references. -## 0.43.27 +## 1.2.1 ### Patch Changes -- Add rpc is sequence method +- [#2589](https://github.com/wagmi-dev/wagmi/pull/2589) [`9680c347`](https://github.com/wagmi-dev/wagmi/commit/9680c347476500d28ceca20d23eeaed7931cb6e0) Thanks [@jxom](https://github.com/jxom)! - Fixed `writeContract` parameters to be compatible with `prepareWriteContract`. -## 0.43.26 +- [#2587](https://github.com/wagmi-dev/wagmi/pull/2587) [`cfff9994`](https://github.com/wagmi-dev/wagmi/commit/cfff999459384ac644ff7e62f53a7b787cf37507) Thanks [@jxom](https://github.com/jxom)! - Updated references -### Patch Changes +## 1.2.0 -- add zkevm url to enum +### Minor Changes -## 0.43.25 +- [#2536](https://github.com/wagmi-dev/wagmi/pull/2536) [`85e9760a`](https://github.com/wagmi-dev/wagmi/commit/85e9760a140cb169ac6236d9466b96e2105dd193) Thanks [@tmm](https://github.com/tmm)! - Changed `Address` type import from ABIType to viem. ### Patch Changes -- added polygon zkevm to mainnet networks +- [#2539](https://github.com/wagmi-dev/wagmi/pull/2539) [`96319c64`](https://github.com/wagmi-dev/wagmi/commit/96319c640b9d07b375821c08a5c213355d8c290b) Thanks [@jxom](https://github.com/jxom)! - Updated references -## 0.43.24 +## 1.1.1 ### Patch Changes -- name change from zkevm to polygon-zkevm +- [`02b98a9f`](https://github.com/wagmi-dev/wagmi/commit/02b98a9f9b2c503a47af4a8967e0202b5db21787) Thanks [@jxom](https://github.com/jxom)! - Updated `viem` peer dependency. -## 0.43.23 +- [`02b98a9f`](https://github.com/wagmi-dev/wagmi/commit/02b98a9f9b2c503a47af4a8967e0202b5db21787) Thanks [@jxom](https://github.com/jxom)! - Updated references. -### Patch Changes +## 1.1.0 -- update zkEVM name to Polygon zkEVM +### Minor Changes -## 0.43.22 +- [#2482](https://github.com/wagmi-dev/wagmi/pull/2482) [`8764b54a`](https://github.com/wagmi-dev/wagmi/commit/8764b54aab68020063946112e8fe52aff650c99c) Thanks [@tmm](https://github.com/tmm)! - Bumped minimum TypeScript version to v5.0.4. ### Patch Changes -- add zkevm chain +- [#2484](https://github.com/wagmi-dev/wagmi/pull/2484) [`3adf1f4f`](https://github.com/wagmi-dev/wagmi/commit/3adf1f4feab863cb7b5d52c81ad46f7e4eb56f09) Thanks [@jxom](https://github.com/jxom)! - Updated `abitype` to 0.8.7 + +- [#2484](https://github.com/wagmi-dev/wagmi/pull/2484) [`3adf1f4f`](https://github.com/wagmi-dev/wagmi/commit/3adf1f4feab863cb7b5d52c81ad46f7e4eb56f09) Thanks [@jxom](https://github.com/jxom)! - Updated references. -## 0.43.21 +## 1.0.8 ### Patch Changes -- api: update client bindings +- [#2441](https://github.com/wagmi-dev/wagmi/pull/2441) [`326edee4`](https://github.com/wagmi-dev/wagmi/commit/326edee4bc85db84a7a4e3768e33785849ab8d8e) Thanks [@tmm](https://github.com/tmm)! - Fixed internal type issue -## 0.43.20 +## 1.0.7 ### Patch Changes -- indexer: update bindings +- [#2433](https://github.com/wagmi-dev/wagmi/pull/2433) [`54fcff5f`](https://github.com/wagmi-dev/wagmi/commit/54fcff5f02f6933bbbe045ee0c83c5a78b6bba49) Thanks [@jxom](https://github.com/jxom)! - Added ability to pass an `account` to `writeContract`/`prepareWriteContract`. -## 0.43.19 +## 1.0.6 ### Patch Changes -- session proof update +- [`ca2e1e96`](https://github.com/wagmi-dev/wagmi/commit/ca2e1e96149b87a7dc42c9db07e1f1ad2bb02c4a) Thanks [@jxom](https://github.com/jxom)! - Updated references. -## 0.43.18 +- [#2401](https://github.com/wagmi-dev/wagmi/pull/2401) [`0f9dc875`](https://github.com/wagmi-dev/wagmi/commit/0f9dc875e90cfdd7a2028e04b7204caf9ea313b2) Thanks [@jxom](https://github.com/jxom)! - Exposed `account` on `readContract`/`useContractRead`. + +## 1.0.5 ### Patch Changes -- rpc client global check, hardening +- [`90e2b3b3`](https://github.com/wagmi-dev/wagmi/commit/90e2b3b39efe0585fe28645ac2264109be17362a) Thanks [@jxom](https://github.com/jxom)! - Updated references. -## 0.43.17 +## 1.0.4 ### Patch Changes -- rpc clients, check of 'global' is defined +- [#2344](https://github.com/wagmi-dev/wagmi/pull/2344) [`8a725458`](https://github.com/wagmi-dev/wagmi/commit/8a72545853ae1024acd9efd18c06142e8c6c5750) Thanks [@jxom](https://github.com/jxom)! - Added gas estimation back into `prepareSendTransaction`. -## 0.43.16 +## 1.0.3 ### Patch Changes -- ethers peerDep to v5, update rpc client global use +- [#2338](https://github.com/wagmi-dev/wagmi/pull/2338) [`92bfdc2c`](https://github.com/wagmi-dev/wagmi/commit/92bfdc2c744539558ba93c95f140b46ad331cee4) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where synchronous switch chain behavior (WalletConnect v2) would encounter chain id race conditions in `watchWalletClient`. -## 0.43.15 +## 1.0.2 ### Patch Changes -- - provider: expand receiver type on some util methods +- [#2304](https://github.com/wevm/wagmi/pull/2304) [`09a4fd38`](https://github.com/wevm/wagmi/commit/09a4fd38f44eb176797925fd85314be17b610cd4) Thanks [@jxom](https://github.com/jxom)! - Removed assert chain workaround. -## 0.43.14 +## 1.0.1 ### Patch Changes -- bump +- [`ea651cd7`](https://github.com/wevm/wagmi/commit/ea651cd7fc75b7866272605467db11fd6e1d81af) Thanks [@jxom](https://github.com/jxom)! - Downgraded abitype. -## 0.43.13 +- Updated dependencies [[`ea651cd7`](https://github.com/wevm/wagmi/commit/ea651cd7fc75b7866272605467db11fd6e1d81af)]: + - @wagmi/connectors@1.0.1 -### Patch Changes +## 1.0.0 -- update rpc bindings +### Major Changes -## 0.43.12 +- [#2235](https://github.com/wevm/wagmi/pull/2235) [`5be0655c`](https://github.com/wevm/wagmi/commit/5be0655c8e48b25d38009022461fbf611af54349) Thanks [@jxom](https://github.com/jxom)! - Released v1. Read [Migration Guide](https://next.wagmi.sh/react/migration-guide#1xx-breaking-changes). -### Patch Changes +## 1.0.0-next.7 + +### Major Changes -- provider: single wallet init, and add new unregisterWallet() method +- [#2235](https://github.com/wevm/wagmi/pull/2235) [`708b2ce2`](https://github.com/wevm/wagmi/commit/708b2ce26efa8d3d910806a97cea5171dabc65de) Thanks [@jxom](https://github.com/jxom)! - Added `config.setPublicClient` & `config.setWebSocketPublicClient` -## 0.43.11 +- Updated references. ### Patch Changes -- fix lockfiles -- re-add mocha type deleter +- Updated dependencies []: + - @wagmi/connectors@1.0.0-next.5 -## 0.43.10 +## 1.0.0-next.6 -### Patch Changes +### Major Changes -- various improvements +- [#2235](https://github.com/wevm/wagmi/pull/2235) [`708b2ce2`](https://github.com/wevm/wagmi/commit/708b2ce26efa8d3d910806a97cea5171dabc65de) Thanks [@jxom](https://github.com/jxom)! - Added `config.setPublicClient` & `config.setWebSocketPublicClient` -## 0.43.9 +- Added `config.setConnectors` ### Patch Changes -- update deps +- Updated dependencies []: + - @wagmi/connectors@1.0.0-next.6 -## 0.43.8 +## 1.0.0-next.5 -### Patch Changes +### Major Changes -- network: JsonRpcProvider with caching +- [#2235](https://github.com/wevm/wagmi/pull/2235) [`708b2ce2`](https://github.com/wevm/wagmi/commit/708b2ce26efa8d3d910806a97cea5171dabc65de) Thanks [@jxom](https://github.com/jxom)! - Added `config.setPublicClient` & `config.setWebSocketPublicClient` -## 0.43.7 +## 1.0.0-next.4 + +### Major Changes + +- Updated viem. + Removed `goerli` export from main entrypoint. ### Patch Changes -- provider: fix wallet network init +- Updated dependencies []: + - @wagmi/connectors@1.0.0-next.5 + +## 1.0.0-next.3 -## 0.43.6 +### Major Changes + +- Updated references. ### Patch Changes -- metadatata: update rpc bindings +- Updated dependencies []: + - @wagmi/connectors@1.0.0-next.4 + +## 1.0.0-next.2 + +### Major Changes -## 0.43.5 +- **Breaking:** Renamed `createClient` to `createConfig` +- **Breaking:** Renamed `getClient` to `getConfig` +- **Breaking:** Removed `request` as an argument to `prepareSendTransaction` & `sendTransaction`. Arguments now belong on the root level of the Action. ### Patch Changes -- provider: do not set default network for connect messages -- provider: forward missing error message +- Updated dependencies []: + - @wagmi/chains@1.0.0-next.0 + - @wagmi/connectors@1.0.0-next.3 + +## 1.0.0-next.1 + +### Major Changes -## 0.43.4 +- updated viem ### Patch Changes -- no-change version bump to fix incorrectly tagged snapshot build +- Updated dependencies []: + - @wagmi/connectors@1.0.0-next.2 -## 0.43.3 +## 1.0.0-next.0 + +### Major Changes + +- [`a7dda00c`](https://github.com/wevm/wagmi/commit/a7dda00c5b546f8b2c42b527e4d9ac1b9e9ab1fb) Thanks [@jxom](https://github.com/jxom)! - Released v1. ### Patch Changes -- metadata: update bindings +- Updated dependencies [[`a7dda00c`](https://github.com/wevm/wagmi/commit/a7dda00c5b546f8b2c42b527e4d9ac1b9e9ab1fb)]: + - @wagmi/connectors@1.0.0-next.1 -## 0.43.2 +## 0.10.11 ### Patch Changes -- provider: implement connectUnchecked +- [#2270](https://github.com/wevm/wagmi/pull/2270) [`6d1fa9df`](https://github.com/wevm/wagmi/commit/6d1fa9df790287729c3b33d4f01fd23c2f8153f1) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies []: + - @wagmi/connectors@0.3.19 -## 0.43.1 +## 0.10.10 ### Patch Changes -- update to latest ethauth dep +- [#2208](https://github.com/wevm/wagmi/pull/2208) [`cfc696d8`](https://github.com/wevm/wagmi/commit/cfc696d83c6f768a2e1a29c5197efeed7f1d40a1) Thanks [@bangtoven](https://github.com/bangtoven)! - Bumped references to apply coinbase wallet sdk updates -## 0.43.0 +- Updated dependencies []: + - @wagmi/connectors@0.3.16 -### Minor Changes +## 0.10.9 -- move ethers to a peer dependency +### Patch Changes -## 0.42.10 +- [#2143](https://github.com/wevm/wagmi/pull/2143) [`26dc5326`](https://github.com/wevm/wagmi/commit/26dc53260fde1d3278018c0b20a6d48a093d9427) Thanks [@tmm](https://github.com/tmm)! - Exported Sepolia Chain. -### Patch Changes +- [#2146](https://github.com/wevm/wagmi/pull/2146) [`21b6842e`](https://github.com/wevm/wagmi/commit/21b6842e8c296a0bbe71ebe0780d898abc4cf4a8) Thanks [@tmm](https://github.com/tmm)! - Bumped references -- add auxDataProvider +- Updated dependencies []: + - @wagmi/connectors@0.3.12 -## 0.42.9 +## 0.10.8 ### Patch Changes -- provider: add eip-191 exceptions +- [#2099](https://github.com/wevm/wagmi/pull/2099) [`f1fee5b3`](https://github.com/wevm/wagmi/commit/f1fee5b30a1bd13b5e66118bf9cdc44b0dc003a1) Thanks [@jxom](https://github.com/jxom)! - Added chains: -## 0.42.8 + - `nexi` + - `polygonZkEvm` + - `xdc` + - `xdcTestnet` -### Patch Changes +- [#2085](https://github.com/wevm/wagmi/pull/2085) [`7d64e3f5`](https://github.com/wevm/wagmi/commit/7d64e3f538a6149777bfa84ea9435769b2a7db58) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where multicall would not throw if the target chain was not configured on the wagmi client. -- provider: skip setting intent origin if we're unity plugin +- Updated dependencies []: + - @wagmi/connectors@0.3.10 -## 0.42.7 +## 0.10.7 ### Patch Changes -- Add sign in options to connection settings +- [#2082](https://github.com/wevm/wagmi/pull/2082) [`2ccc8a25`](https://github.com/wevm/wagmi/commit/2ccc8a255e93f0a2bb7b22101656b3905ec59abd) Thanks [@jxom](https://github.com/jxom)! - Updated references. -## 0.42.6 +- Updated dependencies []: + - @wagmi/connectors@0.3.10 + +## 0.10.6 ### Patch Changes -- api bindings update +- [#2056](https://github.com/wevm/wagmi/pull/2056) [`944f6513`](https://github.com/wevm/wagmi/commit/944f6513adf09a6f0b3bd34f591d3bbd1f1ffd2e) Thanks [@tmm](https://github.com/tmm)! - Bumped references. + +- Updated dependencies []: + - @wagmi/connectors@0.3.8 -## 0.42.5 +## 0.10.5 ### Patch Changes -- relayer: don't treat missing receipt as hard failure +- [#2053](https://github.com/wevm/wagmi/pull/2053) [`665df1bf`](https://github.com/wevm/wagmi/commit/665df1bf2afccb533102069def395e19fb7194dd) Thanks [@tmm](https://github.com/tmm)! - Fixed issue where you add a new chain to MetaMask, but the switch after is rejected. -## 0.42.4 +- Updated dependencies []: + - @wagmi/connectors@0.3.7 + +## 0.10.4 ### Patch Changes -- provider: add custom app protocol to connect options +- [#2046](https://github.com/wevm/wagmi/pull/2046) [`90d8e9b8`](https://github.com/wevm/wagmi/commit/90d8e9b87962b72c54311649537e91a953660f9b) Thanks [@tmm](https://github.com/tmm)! - Exported internal type. + +- Updated dependencies []: + - @wagmi/connectors@0.3.6 -## 0.42.3 +## 0.10.3 ### Patch Changes -- update api bindings +- [#2039](https://github.com/wevm/wagmi/pull/2039) [`bac893ab`](https://github.com/wevm/wagmi/commit/bac893ab26012d4d8741c4f80e8b8813aee26f0c) Thanks [@tmm](https://github.com/tmm)! - Updated references. -## 0.42.2 +- [#2043](https://github.com/wevm/wagmi/pull/2043) [`49a58320`](https://github.com/wevm/wagmi/commit/49a58320ab5f1f13bc4de25abcc028c8335e98f0) Thanks [@tmm](https://github.com/tmm)! - Removed `InjectedConnector` `shimChainChangedDisconnect` shim (no longer necessary). + +- Updated dependencies []: + - @wagmi/connectors@0.3.6 + +## 0.10.2 ### Patch Changes -- disable rinkeby network +- [#2016](https://github.com/wevm/wagmi/pull/2016) [`06bf61de`](https://github.com/wevm/wagmi/commit/06bf61dee6d2920777bd9392491e6b7aedebe7ab) Thanks [@jxom](https://github.com/jxom)! - Added chains: -## 0.42.1 + - `boba` + - `chronos` + - `crossbell` + - `dfk` + - `dogechain` + - `flare` + - `flareTestnet` + - `klaytn` + - `scrollTestnet` + - `shardeumSphinx` + - `skaleCalypso` + - `skaleCalypsoTestnet` + - `skaleChaosTestnet` + - `skaleCryptoBlades` + - `skaleCryptoColosseum` + - `skaleEuropa` + - `skaleEuropaTestnet` + - `skaleExorde` + - `skaleHumanProtocol` + - `skaleNebula` + - `skaleNebulaTestnet` + - `skaleRazor` + - `skaleTitan` + - `skaleTitanTestnet` + - `songbird` + - `songbirdTestnet` + - `titan` + - `titanTestnet` + - `wanchain` + - `wanchainTestnet` -### Patch Changes +- [#2016](https://github.com/wevm/wagmi/pull/2016) [`06bf61de`](https://github.com/wevm/wagmi/commit/06bf61dee6d2920777bd9392491e6b7aedebe7ab) Thanks [@jxom](https://github.com/jxom)! - Updated references/ submodule. -- wallet: optional waitForReceipt parameter +- Updated dependencies []: + - @wagmi/connectors@0.3.4 -## 0.42.0 +## 0.10.0 ### Minor Changes -- relayer: estimateGasLimits -> simulate -- add simulator package +- [#1902](https://github.com/wevm/wagmi/pull/1902) [`0994e896`](https://github.com/wevm/wagmi/commit/0994e8966349b8811db0a5886db3831dafc99245) Thanks [@jxom](https://github.com/jxom)! - **Breaking:** Removed the `version` config option for `WalletConnectConnector`. + + `WalletConnectConnector` now uses WalletConnect v2 by default. WalletConnect v1 is now `WalletConnectLegacyConnector`. + + ### WalletConnect v2 + + ```diff + import { WalletConnectConnector } from 'wagmi/connectors/walletConnect' + + const connector = new WalletConnectConnector({ + options: { + - version: '2', + projectId: 'abc', + }, + }) + ``` + + ### WalletConnect v1 + + ```diff + -import { WalletConnectConnector } from 'wagmi/connectors/walletConnect' + +import { WalletConnectConnector } from 'wagmi/connectors/walletConnectLegacy' + + -const connector = new WalletConnectConnector({ + +const connector = new WalletConnectLegacyConnector({ + options: { + qrcode: true, + }, + }) + ``` ### Patch Changes -- transactions: fix flattenAuxTransactions -- provider: only filter nullish values -- provider: re-map transaction 'gas' back to 'gasLimit' +- Updated dependencies []: + - @wagmi/connectors@0.3.2 -## 0.41.3 +## 0.9.7 ### Patch Changes -- api bindings update +- [#1907](https://github.com/wevm/wagmi/pull/1907) [`cc4e74ee`](https://github.com/wevm/wagmi/commit/cc4e74ee19665eccb3767052dab6ab956ff4e676) Thanks [@jxom](https://github.com/jxom)! - Added the following chains to the `wagmi/chains` entrypoint: + + - `baseGoerli` + - `harmonyOne` + - `polygonZkEvmTestnet` + +- Updated dependencies []: + - @wagmi/connectors@0.2.7 -## 0.41.2 +## 0.9.6 ### Patch Changes -- api bindings update +- [#1882](https://github.com/wevm/wagmi/pull/1882) [`282cc1b0`](https://github.com/wevm/wagmi/commit/282cc1b02003684d582cea411b11792a59c26fd0) Thanks [@tmm](https://github.com/tmm)! - Updated references. -## 0.41.1 +- Updated dependencies []: + - @wagmi/connectors@0.2.6 + +## 0.9.5 ### Patch Changes -- update default networks +- [#1812](https://github.com/wevm/wagmi/pull/1812) [`c7fd7fbd`](https://github.com/wevm/wagmi/commit/c7fd7fbde6f6c69a3a9a4f89d948c4dfb1d22679) Thanks [@jxom](https://github.com/jxom)! - Added the following chains to the `wagmi/chains` entrypoint: -## 0.41.0 + - `filecoinCalibration` + - `moonbaseAlpha` + - `moonbeam` + - `moonriver` -### Minor Changes +- Updated dependencies []: + - @wagmi/connectors@0.2.5 -- relayer: fix Relayer.wait() interface +## 0.9.4 - The interface for calling Relayer.wait() has changed. Instead of a single optional ill-defined timeout/delay parameter, there are three optional parameters, in order: +### Patch Changes - - timeout: the maximum time to wait for the transaction receipt - - delay: the polling interval, i.e. the time to wait between requests - - maxFails: the maximum number of hard failures to tolerate before giving up +- [#1786](https://github.com/wevm/wagmi/pull/1786) [`b173a431`](https://github.com/wevm/wagmi/commit/b173a43165c7925a4e56ce1e0327a31917e7edc5) Thanks [@tmm](https://github.com/tmm)! - Locked ethers peer dependency version to >=5.5.1 <6 - Please update your codebase accordingly. +- [#1787](https://github.com/wevm/wagmi/pull/1787) [`f023fd8f`](https://github.com/wevm/wagmi/commit/f023fd8f66befb78b9a4df5ca971ceaa64e37ab4) Thanks [@tmm](https://github.com/tmm)! - Added `SafeConnector` -- relayer: add optional waitForReceipt parameter to Relayer.relay +- Updated dependencies []: + - @wagmi/connectors@0.2.4 - The behaviour of Relayer.relay() was not well-defined with respect to whether or not it waited for a receipt. - This change allows the caller to specify whether to wait or not, with the default behaviour being to wait. +## 0.9.3 ### Patch Changes -- relayer: wait receipt retry logic -- fix wrapped object error -- provider: forward delegateCall and revertOnError transaction fields +- [#1773](https://github.com/wevm/wagmi/pull/1773) [`9aaf1955`](https://github.com/wevm/wagmi/commit/9aaf195514d3b5f4d085c797fc5021d42a9efb6c) Thanks [@jxom](https://github.com/jxom)! - Updated `@walletconnect/universal-provider` on `WalletConnectConnector` v2. + Added more signable methods to `WalletConnectConnector` v2. + +- [#1773](https://github.com/wevm/wagmi/pull/1773) [`9aaf1955`](https://github.com/wevm/wagmi/commit/9aaf195514d3b5f4d085c797fc5021d42a9efb6c) Thanks [@jxom](https://github.com/jxom)! - Added Telos to the `wagmi/chains` entrypoint. Thanks @donnyquixotic! -## 0.40.6 +- Updated dependencies []: + - @wagmi/connectors@0.2.3 + +## 0.9.2 ### Patch Changes -- add arbitrum-nova chain +- [#1756](https://github.com/wevm/wagmi/pull/1756) [`31d06b8c`](https://github.com/wevm/wagmi/commit/31d06b8ce1e7af5e9d1a7ba57f1743b2dff7a53d) Thanks [@jxom](https://github.com/jxom)! - Added OKC Chain. Thanks @clark-cui! + +- [#1756](https://github.com/wevm/wagmi/pull/1756) [`31d06b8c`](https://github.com/wevm/wagmi/commit/31d06b8ce1e7af5e9d1a7ba57f1743b2dff7a53d) Thanks [@jxom](https://github.com/jxom)! - Fixed race condition between `switchNetwork` and mutation Actions that use `chainId` (e.g. `sendTransaction`). Thanks @DanInTheD4rk! -## 0.40.5 +- Updated dependencies []: + - @wagmi/connectors@0.2.2 + +## 0.9.1 ### Patch Changes -- api: update bindings +- [#1752](https://github.com/wevm/wagmi/pull/1752) [`144a0e76`](https://github.com/wevm/wagmi/commit/144a0e76ef4bb9ba0650b5ffb9c63f95329819a4) Thanks [@jxom](https://github.com/jxom)! - Improved `WalletConnectConnector` (v2) initialization & updated dependencies. -## 0.40.4 +- [#1752](https://github.com/wevm/wagmi/pull/1752) [`144a0e76`](https://github.com/wevm/wagmi/commit/144a0e76ef4bb9ba0650b5ffb9c63f95329819a4) Thanks [@jxom](https://github.com/jxom)! - Added the following chains to the `wagmi/chains` entrypoint: -### Patch Changes + - Aurora – thanks @salil-naik + - Bronos – thanks @chedetinaveen + - Canto – thanks @tster + - Celo – thanks @aaronmgdr -- add unreal transport +- Updated dependencies []: + - @wagmi/connectors@0.2.1 -## 0.40.3 +## 0.9.0 + +### Minor Changes + +- [#1732](https://github.com/wevm/wagmi/pull/1732) [`01e21897`](https://github.com/wevm/wagmi/commit/01e2189747a5c22dc758c6d719b4145adc2a643c) Thanks [@tmm](https://github.com/tmm)! - Bumped minimum TypeScript version to typescript@>=4.9.4. TypeScript 5.0 is coming soon and has some great features we are excited to bring into wagmi. To prepare for this, update your TypeScript version to 4.9.4 or higher. There are likely no [breaking changes](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-4-9.html#correctness-fixes-and-breaking-changes) if you are coming from typescript@4.7.x || typescript@4.8.x. + +## 0.8.19 ### Patch Changes -- provider: fix MessageToSign message type +- [#1718](https://github.com/wevm/wagmi/pull/1718) [`e62b5ef8`](https://github.com/wevm/wagmi/commit/e62b5ef8aaa8063abb5264790768899ea35bbd31) Thanks [@tmm](https://github.com/tmm)! - Updated references -## 0.40.2 +## 0.8.18 ### Patch Changes -- Wallet provider, loadSession method +- [#1708](https://github.com/wevm/wagmi/pull/1708) [`07fc3801`](https://github.com/wevm/wagmi/commit/07fc3801fa13c2cb5f7cf9b86ba8320b05a6a135) Thanks [@jxom](https://github.com/jxom)! - Updated `references/` submodule. -## 0.40.1 +## 0.8.17 ### Patch Changes -- export sequence.initWallet and sequence.getWallet +- [#1705](https://github.com/wevm/wagmi/pull/1705) [`9ff797dc`](https://github.com/wevm/wagmi/commit/9ff797dcb979dc86b798a432b74c98598165430d) Thanks [@jxom](https://github.com/jxom)! - Added the following chains to the `@wagmi/core/chains` entrypoint: -## 0.40.0 + - `crossbell` (thanks @Songkeys) + - `filecoin` & `filecoinHyperspace` (thanks @neil0x46dc) + - `gnosisChiado` (thanks @theNvN) + - `metis` & `metisGoerli` (thanks @CookedCookee) -### Minor Changes +## 0.8.16 + +### Patch Changes -- add sequence.initWallet(network, config) and sequence.getWallet() helper methods +- [#1699](https://github.com/wevm/wagmi/pull/1699) [`2f1e7950`](https://github.com/wevm/wagmi/commit/2f1e7950e55550d9b50ef5ccb97cb609f4af39b1) Thanks [@tmm](https://github.com/tmm)! - Added public RPC URL property to Chain -## 0.39.6 +## 0.8.15 ### Patch Changes -- indexer: update client bindings +- [#1685](https://github.com/wevm/wagmi/pull/1685) [`917f5bc1`](https://github.com/wevm/wagmi/commit/917f5bc1fad578e35a8c6ee787e339bfdc156bab) Thanks [@jxom](https://github.com/jxom)! - Replaced qrcodemodal with web3modal for the WalletConnect v2 Connector. -## 0.39.5 +## 0.8.14 ### Patch Changes -- provider: fix networkRpcUrl config option +- [#1646](https://github.com/wevm/wagmi/pull/1646) [`fcdbe353`](https://github.com/wevm/wagmi/commit/fcdbe3531e6d05cda4a4a511bae1ad4c9e426d88) Thanks [@jxom](https://github.com/jxom)! - Upgraded `zustand` to v4.3.1. -## 0.39.4 +## 0.8.13 ### Patch Changes -- api: update client bindings +- [#1639](https://github.com/wevm/wagmi/pull/1639) [`c6869f06`](https://github.com/wevm/wagmi/commit/c6869f0604fffb197752a08256f31db77f52e746) Thanks [@jxom](https://github.com/jxom)! - Added `isRainbow` flag to `InjectedConnector`. -## 0.39.3 +## 0.8.12 ### Patch Changes -- add request method on Web3Provider +- [#1636](https://github.com/wevm/wagmi/pull/1636) [`025f6771`](https://github.com/wevm/wagmi/commit/025f6771b32ff7eed22f527be81c5141ddaf9c3d) Thanks [@DanielSinclair](https://github.com/DanielSinclair)! - Added `isRainbow` flag to injected `window.ethereum` types. -## 0.39.2 +## 0.8.11 ### Patch Changes -- update umd name +- [#1621](https://github.com/wevm/wagmi/pull/1621) [`5812b590`](https://github.com/wevm/wagmi/commit/5812b5909277bf2862cb57a31d52465b47291410) Thanks [@tmm](https://github.com/tmm)! - Bumped @wagmi/connectors -## 0.39.1 +## 0.8.10 ### Patch Changes -- add Aurora network -- add origin info for accountsChanged event to handle it per dapp +- [#1598](https://github.com/wevm/wagmi/pull/1598) [`fc10ebe6`](https://github.com/wevm/wagmi/commit/fc10ebe659dd5f3b7a8e00581f094652280a779b) Thanks [@jxom](https://github.com/jxom)! - Fixed CJS dependency version range -## 0.39.0 +## 0.8.9 -### Minor Changes +### Patch Changes -- abstract window.localStorage to interface type +- [#1593](https://github.com/wevm/wagmi/pull/1593) [`216d555c`](https://github.com/wevm/wagmi/commit/216d555c62bd95c3c7c8f8e20f7269f6c8504610) Thanks [@jxom](https://github.com/jxom)! - Added CJS escape hatch bundle under the "cjs" tag. -## 0.38.2 +## 0.8.8 ### Patch Changes -- provider: add Settings.defaultPurchaseAmount +- [#1573](https://github.com/wevm/wagmi/pull/1573) [`ef380d9c`](https://github.com/wevm/wagmi/commit/ef380d9c6d51ae0495b9c35925d2843c75d97fd4) Thanks [@tmm](https://github.com/tmm)! - Updated internal types. -## 0.38.1 +## 0.8.7 ### Patch Changes -- update api and metadata rpc bindings +- [#1570](https://github.com/wevm/wagmi/pull/1570) [`216f585b`](https://github.com/wevm/wagmi/commit/216f585be8a9e3a56e3243f49ccd54d655b5a6dd) Thanks [@wslyvh](https://github.com/wslyvh)! - Added `watchPendingTransactions` -## 0.38.0 +- [#1470](https://github.com/wevm/wagmi/pull/1470) [`3a1a6c9f`](https://github.com/wevm/wagmi/commit/3a1a6c9fe5db5c360adfd116f9a03a1238b5720c) Thanks [@jxom](https://github.com/jxom)! - The `WalletConnectConnector` now supports WalletConnect v2. -### Minor Changes + It can be enabled by setting `version` to `'2'` and supplying a [WalletConnect Cloud `projectId`](https://cloud.walletconnect.com/sign-in). + +## 0.8.6 + +### Patch Changes + +- [#1539](https://github.com/wevm/wagmi/pull/1539) [`732da004`](https://github.com/wevm/wagmi/commit/732da0042c7e28091b2e36a484ea8239971306f5) Thanks [@0xFlicker](https://github.com/0xFlicker)! - All Providers (ie. Alchemy, Infura, Public) now use the ENS Registry address on the wagmi `Chain` object (`chain.contracts.ensRegistry`). -- api: update bindings, change TokenPrice interface -- bridge: remove @0xsequence/bridge package -- api: update bindings, rename ContractCallArg to TupleComponent +- [#1574](https://github.com/wevm/wagmi/pull/1574) [`ecde3d10`](https://github.com/wevm/wagmi/commit/ecde3d1029ccdf90e2853ba0e9ae4f5f4ebb9c4c) Thanks [@jxom](https://github.com/jxom)! - Added the following chains: -## 0.37.1 + - `iotex` + - `iotexTestnet` + - `zkSync` + - `zkSyncTestnet` + +## 0.8.5 ### Patch Changes -- Add back sortNetworks - Removing sorting was a breaking change for dapps on older versions which directly integrate sequence. +- [#1542](https://github.com/wevm/wagmi/pull/1542) [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549) Thanks [@jxom](https://github.com/jxom)! - Added the following chains: -## 0.37.0 + - `evmos` + - `evmosTestnet` + - `gnosis` -### Minor Changes +- [#1542](https://github.com/wevm/wagmi/pull/1542) [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549) Thanks [@jxom](https://github.com/jxom)! - Updated Goerli symbol to `"ETH"`. -- network related fixes and improvements -- api: bindings: exchange rate lookups +- [#1542](https://github.com/wevm/wagmi/pull/1542) [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549) Thanks [@jxom](https://github.com/jxom)! - Updated Arbitrum Goerli RPC and Block Explorer. -## 0.36.13 +- [#1542](https://github.com/wevm/wagmi/pull/1542) [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where connecting to MetaMask may return with a stale address. + +- [#1542](https://github.com/wevm/wagmi/pull/1542) [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549) Thanks [@jxom](https://github.com/jxom)! - Removed ENS registry for Sepolia. + +## 0.8.4 ### Patch Changes -- api: update bindings with new price endpoints +- [#1508](https://github.com/wevm/wagmi/pull/1508) [`0b50b62f`](https://github.com/wevm/wagmi/commit/0b50b62f7389619e429509a3e337e451e823b059) Thanks [@jxom](https://github.com/jxom)! - Updated `@wagmi/chains` to `0.1.3`. -## 0.36.12 +- [#1504](https://github.com/wevm/wagmi/pull/1504) [`11b8b794`](https://github.com/wevm/wagmi/commit/11b8b794fbfd4a2b40f39962e2758e9fbf48cb54) Thanks [@tmm](https://github.com/tmm)! - Converted ethers custom "ACTION_REJECTED" error to standard RPC Error. + +## 0.8.3 ### Patch Changes -- wallet: skip remote signers if not needed -- auth: check that signature meets threshold before requesting auth token +- [#1431](https://github.com/wevm/wagmi/pull/1431) [`af28f8f9`](https://github.com/wevm/wagmi/commit/af28f8f9cfc227e7c391927fdb934183edb5c2dc) Thanks [@jxom](https://github.com/jxom)! - Re-export connectors from `@wagmi/connectors` + +- [#1431](https://github.com/wevm/wagmi/pull/1431) [`af28f8f9`](https://github.com/wevm/wagmi/commit/af28f8f9cfc227e7c391927fdb934183edb5c2dc) Thanks [@jxom](https://github.com/jxom)! - Added `LedgerConnector` connector -## 0.36.11 +## 0.8.2 ### Patch Changes -- Prefix EIP191 message on wallet-request-handler +- [#1442](https://github.com/wevm/wagmi/pull/1442) [`cde15289`](https://github.com/wevm/wagmi/commit/cde152899c758dea10787412b0aef669ed7202b2) Thanks [@0xproflupin](https://github.com/0xproflupin)! - Added Phantom wallet support to `InjectedConnector` -## 0.36.10 +- [#1448](https://github.com/wevm/wagmi/pull/1448) [`c6075f3a`](https://github.com/wevm/wagmi/commit/c6075f3a16885d850ad2656272351f9517c9f67b) Thanks [@tmm](https://github.com/tmm)! - Updated [ABIType](https://github.com/wevm/abitype) version. -### Patch Changes +- [#1444](https://github.com/wevm/wagmi/pull/1444) [`310a8bc4`](https://github.com/wevm/wagmi/commit/310a8bc428ce4e7f68377f581b45dcdd64381cce) Thanks [@jxom](https://github.com/jxom)! - Assert that a `connector` exists before invoking the callback in `watchSigner`. -- support bannerUrl on connect +- [#1434](https://github.com/wevm/wagmi/pull/1434) [`100e2a3b`](https://github.com/wevm/wagmi/commit/100e2a3b22f4602716554487b1d98738e053be76) Thanks [@tmm](https://github.com/tmm)! - Updated `MockConnector` `chainId` behavior to default to first chain from `chains` if not provided in `options`. -## 0.36.9 +## 0.8.1 ### Patch Changes -- minor dev xp improvements +- [#1437](https://github.com/wevm/wagmi/pull/1437) [`c34a3dc6`](https://github.com/wevm/wagmi/commit/c34a3dc6396e6473d9f0505fad88ec910f8f5275) Thanks [@jxom](https://github.com/jxom)! - Omitted `"EIP712Domain"` type from `signTypedData` `types` arg since ethers throws an [internal error](https://github.com/ethers-io/ethers.js/blob/c80fcddf50a9023486e9f9acb1848aba4c19f7b6/packages/hash/src.ts/typed-data.ts#L466) if you include it. -## 0.36.8 +- [#1445](https://github.com/wevm/wagmi/pull/1445) [`51dd53cb`](https://github.com/wevm/wagmi/commit/51dd53cba3fe0f79fa1393270b738194577ddf54) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where the wagmi client wouldn't rehydrate the store in local storage when `autoConnect` is truthy. -### Patch Changes +## 0.8.0 -- more connect options (theme, payment providers, funding currencies) +### Minor Changes -## 0.36.7 +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: the shape of the `Chain` type has been modified. + + #### RPC URLs + + The `rpcUrls` shape has changed to include an array of URLs, and also the transport method (`http` or `webSocket`): -### Patch Changes + ```diff + type Chain = { + ... + rpcUrls: { + - [key: string]: string + + [key: string]: { + + http: string[] + + webSocket: string[] + + } + } + ... + } + ``` -- fix missing break + Note that you will also need to ensure that usage is migrated: -## 0.36.6 + ```diff + - const rpcUrl = mainnet.rpcUrls.alchemy + + const rpcUrl = mainnet.rpcUrls.alchemy.http[0] + ``` -### Patch Changes + #### Contracts -- wallet_switchEthereumChain support + The `multicall` and `ens` attributes have been moved into the `contracts` object: -## 0.36.5 + ```diff + type Contract = { + address: Address + blockCreated?: number + } -### Patch Changes + type Chain = { + ... + - multicall: Contract + - ens: Contract + + contracts: { + + multicall3: Contract + + ensRegistry: Contract + + } + ... + } + ``` + + Note that you will also need to ensure that usage is migrated: + + ```diff + - const multicallContract = mainnet.multicall + + const multicallContract = mainnet.contracts.multicall3 + ``` -- auth: bump ethauth to 0.7.0 - network, wallet: don't assume position of auth network in list - api/indexer/metadata: trim trailing slash on hostname, and add endpoint urls - relayer: Allow to specify local relayer transaction parameters like gas price or gas limit +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: Upgraded `@coinbase/wallet-sdk` peer dependency to `3.6.0`. -## 0.36.4 + **Migration steps**: Update `@coinbase/wallet-sdk` to `^3.6.0`. + +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: Removed the `wait` argument on `waitForTransaction`. Use the transaction `hash` instead. + + ```diff + const data = await waitForTransaction({ + - wait: transaction.wait + + hash: transaction.hash + }) + ``` -### Patch Changes +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: With the introduction of the [`@wagmi/core/chains` entrypoint](/core/chains), `@wagmi/core` no longer exports the following: + + - `chain` + - `allChains` + - `defaultChains` + - `defaultL2Chains` + - `chainId` + - `etherscanBlockExplorers` + - `alchemyRpcUrls`, `infuraRpcUrls`, `publicRpcUrls` + + Read below for migration steps. + + #### Removed `chain` + + The `chain` export has been removed. `@wagmi/core` now only exports the `mainnet` & `goerli` chains. If you need to use an alternative chain (`polygon`, `optimism`, etc), you will need to import it from the [`@wagmi/core/chains` entrypoint](/core/chains). -- Updating list of chain ids to include other ethereum compatible chains + ```diff + import { + - chain + configureChains + } from '@wagmi/core' + + import { mainnet, polygon, optimism } from '@wagmi/core/chains' + + const { ... } = configureChains( + - [chain.mainnet, chain.polygon, chain.optimism], + + [mainnet, polygon, optimism], + { + ... + } + ) + ``` -## 0.36.3 + #### Removed `allChains` -### Patch Changes + The `allChains` export has been removed. If you need a list of all chains, you can utilize [`@wagmi/core/chains` entrypoint](/core/chains). -- provider: pass connect options to prompter methods + ```diff + - import { allChains } from '@wagmi/core' + + import * as allChains from '@wagmi/core/chains' -## 0.36.2 + const { ... } = configureChains(allChains, ...) + ``` -### Patch Changes + #### Removed `defaultChains` & `defaultL2Chains` -- transactions: Setting target to 0x0 when empty to during SequenceTxAbiEncode + The `defaultChains` & `defaultL2Chains` exports have been removed. If you still need the `defaultChains` or `defaultL2Chains` exports, you can build them yourself: -## 0.36.1 + ```diff + - import { defaultChains } from '@wagmi/core' + + import { mainnet, goerli } from '@wagmi/core/chains' -### Patch Changes + + const defaultChains = [mainnet, goerli] + ``` -- metadata: update client with more fields + > The `defaultChains` export was previously populated with `mainnet` & `goerli`. -## 0.36.0 + ```diff + - import { defaultL2Chains } from '@wagmi/core' + + import { + + arbitrum, + + arbitrumGoerli, + + polygon, + + polygonMumbai, + + optimism, + + optimismGoerli + + } from '@wagmi/core/chains' -### Minor Changes + + const defaultL2Chains = [ + + arbitrum, + + arbitrumGoerli, + + polygon, + + polygonMumbai, + + optimism + + optimismGoerli + + ] + ``` -- relayer, wallet: fee quote support + > The `defaultL2Chains` export was previously populated with `arbitrum` & `optimism`. -## 0.35.12 + #### Removed `chainId` -### Patch Changes + The `chainId` export has been removed. You can extract a chain ID from the chain itself. -- provider: rename wallet.commands to wallet.utils + ```diff + - import { chainId } from '@wagmi/core' + + import { mainnet, polygon, optimism } from '@wagmi/core/chains' -## 0.35.11 + -const mainnetChainId = chainId.mainnet + -const polygonChainId = chainId.polygon + -const optimismChainId = chainId.optimism + +const mainnetChainId = mainnet.chainId + +const polygonChainId = polygon.chainId + +const optimismChainId = optimism.chainId + ``` -### Patch Changes + #### Removed `etherscanBlockExplorers` + + The `etherscanBlockExplorers` export has been removed. You can extract a block explorer from the chain itself. + + ```diff + - import { etherscanBlockExplorers } from '@wagmi/core' + + import { mainnet, polygon, optimism } from '@wagmi/core/chains' + + -const mainnetEtherscanBlockExplorer = etherscanBlockExplorers.mainnet + -const polygonEtherscanBlockExplorer = etherscanBlockExplorers.polygon + -const optimismEtherscanBlockExplorer = etherscanBlockExplorers.optimism + +const mainnetEtherscanBlockExplorer = mainnet.blockExplorer + +const polygonEtherscanBlockExplorer = polygon.blockExplorer + +const optimismEtherscanBlockExplorer = optimism.blockExplorer + ``` + + #### Removed `alchemyRpcUrls`, `infuraRpcUrls` & `publicRpcUrls` + + The `alchemyRpcUrls`, `infuraRpcUrls` & `publicRpcUrls` exports have been removed. You can extract a RPC URL from the chain itself. + + ```diff + - import { alchemyRpcUrls, infuraRpcUrls, publicRpcUrls } from '@wagmi/core' + + import { mainnet } from '@wagmi/core/chains' + + -const mainnetAlchemyRpcUrl = alchemyRpcUrls.mainnet + -const mainnetInfuraRpcUrl = infuraRpcUrls.mainnet + -const mainnetOptimismRpcUrl = publicRpcUrls.mainnet + +const mainnetAlchemyRpcUrl = mainnet.rpcUrls.alchemy + +const mainnetInfuraRpcUrl = mainnet.rpcUrls.infura + +const mainnetOptimismRpcUrl = mainnet.rpcUrls.optimism + ``` -- provider/utils: smoother message validation +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: Changed `waitForTransaction` behavior to throw an error if the transaction reverted. -## 0.35.10 +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - Updated errors to use `cause` instead of `internal` ### Patch Changes -- upgrade deps +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - `waitForTransaction` now respects repriced (sped up) transactions. -## 0.35.9 +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - Export `getClient` + +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - `waitForTransaction` now throws an error for cancelled or replaced transactions. + +## 0.7.9 ### Patch Changes -- provider: window-transport override event handlers with new wallet instance +- [#1411](https://github.com/wevm/wagmi/pull/1411) [`659be184`](https://github.com/wevm/wagmi/commit/659be1840c613ce9f7aca9ac96694c4f60da4a66) Thanks [@tmm](https://github.com/tmm)! - Fixed issue where block invalidation was not properly disabled when setting `enabled: false`. -## 0.35.8 +## 0.7.8 ### Patch Changes -- provider: async wallet sign in improvements +- [#1406](https://github.com/wevm/wagmi/pull/1406) [`4f18c450`](https://github.com/wevm/wagmi/commit/4f18c450a4d7952bfcfa6c533348ffbe55893d3c) Thanks [@tmm](https://github.com/tmm)! - Function for selecting the [EIP-1193](https://eips.ethereum.org/EIPS/eip-1193) Ethereum Provider to target. Defaults to `() => typeof window !== 'undefined' ? window.ethereum : undefined`. + + ```ts + import { InjectedConnector } from "@wagmi/core/connectors/injected"; + + const connector = new InjectedConnector({ + options: { + name: "My Injected Wallet", + getProvider: () => + typeof window !== "undefined" ? window.myInjectedWallet : undefined, + }, + }); + ``` -## 0.35.7 +## 0.7.7 ### Patch Changes -- config: cache wallet configs +- [#1386](https://github.com/wevm/wagmi/pull/1386) [`206a2adb`](https://github.com/wevm/wagmi/commit/206a2adbb4ee5149a364543b34612050ccf78c21) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `persister` would still use `window.localStorage` instead of the wagmi `storage`. -## 0.35.6 +- [#1376](https://github.com/wevm/wagmi/pull/1376) [`a70a9528`](https://github.com/wevm/wagmi/commit/a70a9528f93f4d7fea28b7652751dfef2dcacf9b) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where `switchChain` on `WalletConnectConnector` would not resolve. + +- [#1386](https://github.com/wevm/wagmi/pull/1386) [`206a2adb`](https://github.com/wevm/wagmi/commit/206a2adbb4ee5149a364543b34612050ccf78c21) Thanks [@jxom](https://github.com/jxom)! - Added `serialize`/`deserialize` as config options to `createStorage`. + +- [#1392](https://github.com/wevm/wagmi/pull/1392) [`88afc849`](https://github.com/wevm/wagmi/commit/88afc84978afe9689ab7364633e4422ecd7699ea) Thanks [@tmm](https://github.com/tmm)! - Added check for active connector when connecting + +## 0.7.6 ### Patch Changes -- provider: support async signin of wallet request handler +- [#1384](https://github.com/wevm/wagmi/pull/1384) [`027e88d6`](https://github.com/wevm/wagmi/commit/027e88d6e5f8d028d46ee78aec8500701e0173d9) Thanks [@tmm](https://github.com/tmm)! - Fixed issue reconnecting after disconnect with `MetaMaskConnector` in MetaMask mobile browser. -## 0.35.5 +## 0.7.5 ### Patch Changes -- wallet: skip threshold check during fee estimation +- [`1169914a`](https://github.com/wevm/wagmi/commit/1169914a0f0ad2810ca1c536b1f1bc6c20f2c1be) Thanks [@jxom](https://github.com/jxom)! - Use `get_accounts` for `getSigner` in InjectedConnector -## 0.35.4 +## 0.7.4 ### Patch Changes -- - browser extension mode, center window +- [#1309](https://github.com/wevm/wagmi/pull/1309) [`1f4a4261`](https://github.com/wevm/wagmi/commit/1f4a4261247b1d3a90e3123157bc851a35d49b9c) Thanks [@tmm](https://github.com/tmm)! - Fixed internal type -## 0.35.3 +## 0.7.3 ### Patch Changes -- - update window position when in browser extension mode +- [#1294](https://github.com/wevm/wagmi/pull/1294) [`b2f88949`](https://github.com/wevm/wagmi/commit/b2f88949f32aabaf13f318472648cd51a8b7f2e7) Thanks [@tmm](https://github.com/tmm)! - Set `abi` return type value for `prepareContractWrite` as more permissive when not inferrable as `Abi`. -## 0.35.2 +## 0.7.2 ### Patch Changes -- - provider: WindowMessageHandler accept optional windowHref +- [`e9f806b6`](https://github.com/wevm/wagmi/commit/e9f806b652ba62effb3ddac464815e447fc287f6) Thanks [@tmm](https://github.com/tmm)! - Bumped abitype and zustand versions. -## 0.35.1 +## 0.7.1 ### Patch Changes -- wallet: update config on undeployed too +- [#1272](https://github.com/wevm/wagmi/pull/1272) [`1f7fc41`](https://github.com/wevm/wagmi/commit/1f7fc419f7960bbdc51dfa85c2f33b89f1ecc1bf) Thanks [@tmm](https://github.com/tmm)! - Fixed ethers import path -## 0.35.0 +## 0.7.0 ### Minor Changes -- - config: add buildStubSignature - - provider: add checks to signing cases for wallet deployment and config statuses - - provider: add prompt for wallet deployment - - relayer: add BaseRelayer.prependWalletDeploy - - relayer: add Relayer.feeOptions - - relayer: account for wallet deployment in fee estimation - - transactions: add fromTransactionish - - wallet: add Account.prependConfigUpdate - - wallet: add Account.getFeeOptions +- [#1202](https://github.com/wevm/wagmi/pull/1202) [`9bf56af`](https://github.com/wevm/wagmi/commit/9bf56af3c30bdb80abb1e785c002e00986fadfb2) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: Removed the following deprecated chains: -## 0.34.0 + - `ropsten` + - `rinkeby` + - `kovan` + - `optimismKovan` + - `arbitrumRinkeby` -### Minor Changes + If you feel you still need to include one of these testnets in your application, you will have to define it manually: -- - upgrade deps + ```diff + -import { rinkeby } from 'wagmi' + +import { Chain } from 'wagmi' -## 0.31.0 + +export const rinkeby: Chain = { + + id: 4, + + name: 'Rinkeby', + + network: 'rinkeby', + + nativeCurrency: { name: 'Rinkeby Ether', symbol: 'ETH', decimals: 18 }, + + rpcUrls: { + + alchemy: 'https://eth-rinkeby.alchemyapi.io/v2', + + default: 'https://rpc.ankr.com/eth_rinkeby', + + infura: 'https://rinkeby.infura.io/v3', + + public: 'https://rpc.ankr.com/eth_rinkeby', + + }, + + blockExplorers: { + + etherscan: 'https://rinkeby.etherscan.io', + + default: 'https://rinkeby.etherscan.io', + + }, + + ens: { + + address: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e', + + }, + + multicall: { + + address: '0xca11bde05977b3631167028862be2a173976ca11', + + blockCreated: 10299530, + + }, + + testnet: true, + } + ``` -### Minor Changes + You can reference these removed chains [here](https://github.com/wevm/wagmi/blob/389765f7d9af063ab0df07389a2bbfbc10a41060/packages/core/src/constants/chains.ts). -- - upgrading to ethers v5.5 +- [#1202](https://github.com/wevm/wagmi/pull/1202) [`9bf56af`](https://github.com/wevm/wagmi/commit/9bf56af3c30bdb80abb1e785c002e00986fadfb2) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: `addressOrName` renamed to `address` for `fetchBalance` and `fetchEnsAvatar`. -## 0.30.0 + ```diff + const result = await fetchBalance({ + - addressOrName: '0x…', + + address: '0x…', + }) + ``` -### Minor Changes + If you were using an ENS name instead of an address, you can resolve the name to an address before passing it to the action. + + ```diff + + const { data: address } = await fetchEnsAddress({ name: 'example.eth' }) + const result = await fetchBalance({ + - addressOrName: 'example.eth', + + address, + }) + ``` + +- [#1202](https://github.com/wevm/wagmi/pull/1202) [`9bf56af`](https://github.com/wevm/wagmi/commit/9bf56af3c30bdb80abb1e785c002e00986fadfb2) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: Made `apiKey` required on `infuraProvider` and `alchemyProvider`. -- - upgrade most deps + ```diff + import { configureChains } from 'wagmi' -## 0.29.8 + const config = configureChains(defaultChains, [ + - alchemyProvider(), + + alchemyProvider({ apiKey: process.env.ALCHEMY_API_KEY }) + ]) + ``` + + You can find your Alchemy API key from the [Alchemy Dashboard](https://dashboard.alchemyapi.io/), or your Infura API key from the [Infura Dashboard](https://infura.io/login). + +- [#1202](https://github.com/wevm/wagmi/pull/1202) [`9bf56af`](https://github.com/wevm/wagmi/commit/9bf56af3c30bdb80abb1e785c002e00986fadfb2) Thanks [@tmm](https://github.com/tmm)! - Removed CommonJS support + +## 0.6.12 ### Patch Changes -- update api +- [#1250](https://github.com/wevm/wagmi/pull/1250) [`ce2e0f4`](https://github.com/wevm/wagmi/commit/ce2e0f4a46b8fd1c509ead552012ef4c072a525b) Thanks [@tmm](https://github.com/tmm)! - Added support for Trust Wallet browser extension. -## 0.29.3 +## 0.6.11 ### Patch Changes -- indexer: add bridge contract types +- [#1234](https://github.com/wevm/wagmi/pull/1234) [`3ff9303`](https://github.com/wevm/wagmi/commit/3ff930349250f62137cca4ca3b382522882abf8a) Thanks [@tmm](https://github.com/tmm)! - Fixed issue with adding chain to wallet without block explorer URL. -## 0.29.0 +## 0.6.10 -### Minor Changes +### Patch Changes + +- [#1232](https://github.com/wevm/wagmi/pull/1232) [`c0ca509`](https://github.com/wevm/wagmi/commit/c0ca509506dcf6d98b058df549dc761c9a5f3d1c) Thanks [@tmm](https://github.com/tmm)! - Added validation to check that chain is configured for connector when accessing `Signer`. + +## 0.6.9 + +### Patch Changes + +- [#1207](https://github.com/wevm/wagmi/pull/1207) [`c73d463`](https://github.com/wevm/wagmi/commit/c73d463d65c9dbfcfe709187e47323a769589741) Thanks [@lvshaoping007](https://github.com/lvshaoping007)! - Added Kucoin wallet support to `InjectedConnector` + +## 0.6.8 + +### Patch Changes + +- [#1132](https://github.com/wevm/wagmi/pull/1132) [`d41c0d6`](https://github.com/wevm/wagmi/commit/d41c0d650f8c0e54145758685b7604b8909d7ae0) Thanks [@toniocodo](https://github.com/toniocodo)! - Added ERC-4626 ABI + +- [#1201](https://github.com/wevm/wagmi/pull/1201) [`9a07efa`](https://github.com/wevm/wagmi/commit/9a07efaa397d3ba03f2edbe527c359f21e22139a) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where non-checksum addresses did not resolve with an ENS name + +## 0.6.7 -- major architectural changes in Sequence design +### Patch Changes + +- [#1174](https://github.com/wevm/wagmi/pull/1174) [`196a458`](https://github.com/wevm/wagmi/commit/196a458f64141e8a9f39c1b1e1af5937f692cb39) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `client.chains` (active connector chains) would be populated when there is no active connector (disconnected user). - - only one API instance, API is no longer a per-chain service - - separate per-chain indexer service, API no longer handles indexing - - single contract metadata service, API no longer serves metadata +- [#1176](https://github.com/wevm/wagmi/pull/1176) [`389765f`](https://github.com/wevm/wagmi/commit/389765f7d9af063ab0df07389a2bbfbc10a41060) Thanks [@jxom](https://github.com/jxom)! - Migrate away from Alchemy RPC URLs in the public RPC URL list - chaind package has been removed, indexer and metadata packages have been added +## 0.6.6 + +### Patch Changes - stronger typing with new explicit ChainId type +- [`81ce9e6`](https://github.com/wevm/wagmi/commit/81ce9e64d85f7d01370324c1a529988a0919894f) Thanks [@jxom](https://github.com/jxom)! - Add `isPortal` to injected MetaMask flags. - multicall fixes and improvements +- [`c2c0109`](https://github.com/wevm/wagmi/commit/c2c01096ef4cd0ffadbb49062969c208604c6194) Thanks [@jxom](https://github.com/jxom)! - Add etherscan block explorer to Optimism Goerli + +## 0.6.5 + +### Patch Changes + +- [#1162](https://github.com/wevm/wagmi/pull/1162) [`30335b3`](https://github.com/wevm/wagmi/commit/30335b3199fb425e398e9c492b50c68d5e2ade7e) Thanks [@tmm](https://github.com/tmm)! - Fixed issue where non-indexed event parameter types were set to `null`. + +- [#1162](https://github.com/wevm/wagmi/pull/1162) [`30335b3`](https://github.com/wevm/wagmi/commit/30335b3199fb425e398e9c492b50c68d5e2ade7e) Thanks [@tmm](https://github.com/tmm)! - Fixed issue where `useContractReads` and `useContractInfiniteReads` types were slowing down TypeScript compiler. + +## 0.6.4 + +### Patch Changes + +- [#1103](https://github.com/wevm/wagmi/pull/1103) [`651eda0`](https://github.com/wevm/wagmi/commit/651eda06384bd0955268427f898e9337b2dc5a31) Thanks [@tmm](https://github.com/tmm)! - Bumped `abitype` dependency. + +## 0.6.3 + +### Patch Changes + +- [#1086](https://github.com/wevm/wagmi/pull/1086) [`4e28d2a`](https://github.com/wevm/wagmi/commit/4e28d2ad4c2e6b3479b728563040b9529463cbcf) Thanks [@tmm](https://github.com/tmm)! - Exposed module types. + +## 0.6.2 + +### Patch Changes + +- [#1080](https://github.com/wevm/wagmi/pull/1080) [`3be5e8b`](https://github.com/wevm/wagmi/commit/3be5e8b01e58ed40cc9dab7ef9533c0197cb74d0) Thanks [@tmm](https://github.com/tmm)! - Added `abitype` to `dependencies` so types ship correctly. + +## 0.6.1 + +### Patch Changes + +- [#1074](https://github.com/wevm/wagmi/pull/1074) [`8db807f`](https://github.com/wevm/wagmi/commit/8db807f16149aa278c2a7db9ee5245431db12173) Thanks [@IljaDaderko](https://github.com/IljaDaderko)! - Exported `EventListener` type + +## 0.6.0 + +### Minor Changes + +- [#940](https://github.com/wevm/wagmi/pull/940) [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: `watchSigner` now requires an arguments object (that accepts an optional `chainId`) as it's first parameter. + + ```diff + import { watchSigner } from `@wagmi/core` + + -watchSigner(signer => { + +watchSigner({}, signer => { + console.log('new signer!', signer) + }) + ``` + +- [#940](https://github.com/wevm/wagmi/pull/940) [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: `prepareSendTransaction` now throws when a `chainId` is specified and the end-user is on a different chain id (the wrong network). + +- [#941](https://github.com/wevm/wagmi/pull/941) [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: `addressOrName` and `contractInterface` renamed to `address` and `abi` respectively for contract actions: `getContract`, `multicall`, `prepareWriteContract`, `readContract`, `readContracts`, `watchContractEvent`, `watchMulticall`, `watchReadContract`, `watchReadContracts`, `writeContract`. + + ```diff + import { readContract } from '@wagmi/core' + + const result = await readContract({ + - addressOrName: '0x…', + + address: '0x…', + - contractInterface: […] as const, + + abi: […] as const, + functionName: 'balanceOf', + args: ['0x…'], + }) + ``` + + If you were using an ENS name instead of an address, you can resolve the name to an address before passing it to the action. + + ```diff + - import { readContract } from '@wagmi/core' + + import { fetchEnsAddress, readContract } from '@wagmi/core' + + + const address = await fetchEnsAddress('example.eth') + const result = await readContract({ + - addressOrName: 'example.eth', + + address, + abi: […] as const, + functionName: 'balanceOf', + args: ['0x…'], + }) + ``` + +- [#940](https://github.com/wevm/wagmi/pull/940) [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: `prepareWriteContract` now throws when a `chainId` is specified and the end-user is on a different chain id (the wrong network). + +- [#940](https://github.com/wevm/wagmi/pull/940) [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: `prepareSendTransaction` now only accepts a `signer` instead of `signerOrProvider`. + + This is to reach parity with `prepareWriteContract`. + + If no `signer` is provided, wagmi will use the signer that is currently connected. If no user is connected, then `prepareWriteContract` will throw an error. + +- [#941](https://github.com/wevm/wagmi/pull/941) [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: `args` config option must now be an array for the following actions: `readContract`, `writeContract`, `prepareWriteContract`, `multicall`, `readContracts`, `watchMulticall`, and `watchReadContracts`. + + ```diff + import { readContract } from '@wagmi/core' + + const result = await readContract({ + address: '0x…', + abi: […], + functionName: 'balanceOf', + - args: '0x…', + + args: ['0x…'], + }) + ``` + +- [#941](https://github.com/wevm/wagmi/pull/941) [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: `watchContractEvent` now accepts a configuration object and callback instead of positional arguments. + + ```diff + import { watchContractEvent } from '@wagmi/core' + + - const unsubscribe = watchContractEvent( + - { + - address: '0x…', + - abi: […], + - }, + - 'Transfer', + - (from, to, tokenId) => { + - // ... + - }, + - { once: true }, + - ) + + const unsubscribe = watchContractEvent( + + { + + address: '0x…', + + abi: […], + + eventName: 'Transfer', + + once: true, + + }, + + (from, to, tokenId) => { + + // ... + + }, + + ) + ``` + +- [#941](https://github.com/wevm/wagmi/pull/941) [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: Updated TypeScript version to `typescript@>=4.7.4`. + + `@wagmi/core` can now infer types based on [ABI](https://docs.soliditylang.org/en/v0.8.15/abi-spec.html#json) and [EIP-712](https://eips.ethereum.org/EIPS/eip-712) Typed Data definitions, giving you full end-to-end type-safety from your contracts to your frontend and incredible developer experience (e.g. autocomplete contract function names and catch misspellings, type contract function arguments, etc.). + + For this to work, you must upgrade to `typescript@>=4.7.4`. Why is TypeScript v4.7.4 or greater necessary? TypeScript 4.7.4 introduced the ability to [extend constraints on inferred type variables](https://devblogs.microsoft.com/typescript/announcing-typescript-4-7/#extends-constraints-on-infer-type-variables), which is used extensively to help narrow types for ABIs. Good news! When upgrading TypeScript from 4.6 to 4.7 there are likely no [breaking changes](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-4-7.html#breaking-changes) for your set up. + +- [#941](https://github.com/wevm/wagmi/pull/941) [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: Updated TypeScript generics for contract interaction and typed data actions. + + Adding a [const assertion](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-4.html#const-assertions) to `abi` allows TypeScript to infer `functionName`, `args`, `overrides`, and return types for functions, and `eventName` and `listener` types for events. + + ```diff + import { readContract } from '@wagmi/core' + + const result = await readContract({ + address: '0x…', + - abi: […], + + abi: […] as const, + functionName: 'balanceOf', // will autocomplete and catch typos + args: ['0x…'], // inferred based on `functionName` + }) + result // inferred based on `functionName` + ``` + + This works for the following actions: `readContract`, `writeContract`, `prepareWriteContract`, `multicall`, `readContracts`, `watchMulticall`, `watchReadContracts`, and `watchContractEvent`. + + Adding a [const assertion](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-4.html#const-assertions) to `signTypedData`'s config option, `types`, allows TypeScript to infer `value`. + + ```diff + import { signTypedData } from '@wagmi/core' + + const result = await signTypedData({ + domain: { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', + }, + types: { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], + - }, + + } as const, + value: { // `value` is inferred based on `types` + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + }) + ``` + +### Patch Changes + +- [#1061](https://github.com/wevm/wagmi/pull/1061) [`a4ffe8b`](https://github.com/wevm/wagmi/commit/a4ffe8b25516d5504685ae94579da4cd8c409329) Thanks [@alecananian](https://github.com/alecananian)! - Added Arbitrum Goerli Arbiscan block explorer + +- [#940](https://github.com/wevm/wagmi/pull/940) [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663) Thanks [@jxom](https://github.com/jxom)! - The `fetchSigner` action now accepts an optional `chainId` to use for signer initialization as an argument. + + ```tsx + import { fetchSigner } from "@wagmi/core"; + import { optimism } from "@wagmi/core/chains"; + + // ... + + fetchSigner({ chainId: optimism.id }); + ``` + +- [#1048](https://github.com/wevm/wagmi/pull/1048) [`ed13074`](https://github.com/wevm/wagmi/commit/ed130747c0f28c1d9980a1328883e4000a60455e) Thanks [@Max-3-7](https://github.com/Max-3-7)! - Added support for Avalanche core wallet + +- [#1046](https://github.com/wevm/wagmi/pull/1046) [`ab9ecaa`](https://github.com/wevm/wagmi/commit/ab9ecaa74dfa4324279e167dd7e348319ef7d35d) Thanks [@jxom](https://github.com/jxom)! - make ethers block format validator compatible with Celo + +- [#1050](https://github.com/wevm/wagmi/pull/1050) [`73d4d47`](https://github.com/wevm/wagmi/commit/73d4d47bc679f4f9a1cf46010fe2bf858c9d0b5c) Thanks [@jxom](https://github.com/jxom)! - update dependencies + + - `zustand@4.1.1` + +## 0.5.8 + +### Patch Changes + +- [`8cb07462`](https://github.com/wevm/wagmi/commit/8cb07462acc3c5637398d11d2451f8b8e330d553) Thanks [@jxom](https://github.com/jxom)! - Added `chainId` as an argument to `watchBlockNumber`. + +* [`53c1a474`](https://github.com/wevm/wagmi/commit/53c1a4747d03b685e8cfbf55361fc2a56777fb06) Thanks [@tmm](https://github.com/tmm)! - Added missing `decimals` option to `Connector` `watchAsset` + +- [`4d74dd4f`](https://github.com/wevm/wagmi/commit/4d74dd4ff827ba5c43c3546a218f38cee45ea76a) Thanks [@jxom](https://github.com/jxom)! - Support ERC20 contracts that represent strings as bytes32 + +## 0.5.7 + +### Patch Changes + +- [`aa51bc4d`](https://github.com/wevm/wagmi/commit/aa51bc4dc5683bf0178597d2fdb8f2e9d82e7970) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue in `CoinbaseWalletConnector` where the browser extension would unintendedly reset the network when the browser is refreshed. + +* [#955](https://github.com/wevm/wagmi/pull/955) [`e326cd80`](https://github.com/wevm/wagmi/commit/e326cd80fe65267db623eb6c80ccdd75572914cf) Thanks [@0xFlicker](https://github.com/0xFlicker)! - Added Infura RPC URL for Sepolia + +- [`cec14089`](https://github.com/wevm/wagmi/commit/cec14089500c86687226ab272b4c3fcb85ae3d69) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `useProvider` & `getProvider` were not returning referentially equal providers. + +* [`cec14089`](https://github.com/wevm/wagmi/commit/cec14089500c86687226ab272b4c3fcb85ae3d69) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where the `watch` option was not respecting the neighboring `chainId` option in `useBlockNumber`. + +- [`cec14089`](https://github.com/wevm/wagmi/commit/cec14089500c86687226ab272b4c3fcb85ae3d69) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where block listeners (via `watch`) were firing excessively on L2 chains. + +## 0.5.6 + +### Patch Changes + +- [#936](https://github.com/wevm/wagmi/pull/936) [`3329d1f`](https://github.com/wevm/wagmi/commit/3329d1f5880431566e14ac1640f48d0975aec4c2) Thanks [@jxom](https://github.com/jxom)! - Added the ability to provide a custom logger to override how logs are broadcasted to the consumer in wagmi. + + A custom logger can be provided to the wagmi client via `logger`. + + ### API + + ```tsx + logger?: { + warn: typeof console.warn | null + } + ``` + + ### Examples + + **Passing in a custom logger** + + You can pass in a function to define your own custom logger. + + ```diff + + import { logWarn } from './logger'; + + const client = createClient({ + ... + + logger: { + + warn: message => logWarn(message) + + } + ... + }) + ``` + + **Disabling a logger** + + You can disable a logger by passing `null` as the value. + + ```diff + const client = createClient({ + ... + + logger: { + + warn: null + + } + ... + }) + ``` + +* [#889](https://github.com/wevm/wagmi/pull/889) [`27788ed`](https://github.com/wevm/wagmi/commit/27788ed989b5dc26849c7945fb91a92e56766018) Thanks [@jxom](https://github.com/jxom)! - Make multicall & readContracts more error robust + +## 0.5.5 + +### Patch Changes + +- [#912](https://github.com/wevm/wagmi/pull/912) [`e529e12`](https://github.com/wevm/wagmi/commit/e529e125c713ed3ef24a59c6bf226fe4deee7ac9) Thanks [@zouhangwithsweet](https://github.com/zouhangwithsweet)! - Added BitKeep to injected flags + +- [#912](https://github.com/wevm/wagmi/pull/910) Thanks [@mytangying](https://github.com/zouhangwithsweet)! - Added MathWallet to injected flags + +- [#904](https://github.com/wevm/wagmi/pull/904) [`c231058`](https://github.com/wevm/wagmi/commit/c23105850f335f8798031e14c7098b7dee8c2975) Thanks [@jxom](https://github.com/jxom)! - Minimized contract interface returned from `prepareWriteContract`. + +## 0.5.4 + +### Patch Changes + +- [#852](https://github.com/wevm/wagmi/pull/852) [`c3192d0`](https://github.com/wevm/wagmi/commit/c3192d0663aa332ae9edfd9dd49b333454013ab7) Thanks [@skeithc](https://github.com/skeithc)! - Added support for the Sepolia testnet + +## 0.5.3 + +### Patch Changes + +- [#835](https://github.com/wevm/wagmi/pull/835) [`1b85e54`](https://github.com/wevm/wagmi/commit/1b85e54ae654e2564cf5bc2dae6411fe0a25875c) Thanks [@jxom](https://github.com/jxom)! - Update `@coinbase/wallet-sdk` to `3.4.1` + +* [#834](https://github.com/wevm/wagmi/pull/834) [`9655879`](https://github.com/wevm/wagmi/commit/96558793b0319df47aefafa6b7b9c959068d491b) Thanks [@jxom](https://github.com/jxom)! - Update zustand to `4.0.0` + +## 0.5.2 + +### Patch Changes + +- [#823](https://github.com/wevm/wagmi/pull/823) [`10b8b78`](https://github.com/wevm/wagmi/commit/10b8b78605b7246b2c55b8d69f96663906e5cd20) Thanks [@tmm](https://github.com/tmm)! - Add Optimism Goerli to `chain` lookup. + +## 0.5.1 + +### Patch Changes + +- [#767](https://github.com/wevm/wagmi/pull/767) [`e9392f3`](https://github.com/wevm/wagmi/commit/e9392f396e48e928bd9d2522e3ad671c589f08cb) Thanks [@klyap](https://github.com/klyap)! - Add Optimism Goerli chain ahead of [Kovan deprecation](https://dev.optimism.io/kovan-to-goerli). + +* [#817](https://github.com/wevm/wagmi/pull/817) [`7e5cac7`](https://github.com/wevm/wagmi/commit/7e5cac75815dcd8aa563462342a4853fc5207735) Thanks [@alecananian](https://github.com/alecananian)! - Added custom name mapping for 1inch Wallet injected provider + +- [#806](https://github.com/wevm/wagmi/pull/806) [`0b34e56`](https://github.com/wevm/wagmi/commit/0b34e56db97e6dcdb71088e0149b2d55ebc604a5) Thanks [@vmichalik](https://github.com/vmichalik)! - Fix canonical testnet native asset symbols by changing them to ETH + +* [#778](https://github.com/wevm/wagmi/pull/778) [`0892908`](https://github.com/wevm/wagmi/commit/08929084eeeba1a3a55aa098fa9d92a243685ad5) Thanks [@0xcadams](https://github.com/0xcadams)! - Add Arbitrum Goerli chain. + +## 0.5.0 + +### Minor Changes + +- [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The configuration passed to the `sendTransaction` action now needs to be: + + - prepared with the `prepareSendTransaction` action **(new functionality)**, or + - recklessly unprepared **(previous functionality)** + + > Why? [Read here](https://wagmi.sh/docs/prepare-hooks) + + ### Prepared usage + + ```diff + import { prepareSendTransaction, sendTransaction } from '@wagmi/core' + + +const config = await prepareSendTransaction({ + + request: { + + to: 'moxey.eth', + + value: parseEther('1'), + + } + +}) + + const result = await sendTransaction({ + - request: { + - to: 'moxey.eth', + - value: parseEther('1') + - } + + ...config + }) + ``` + + ### Recklessly unprepared usage + + It is possible to use `sendTransaction` without preparing the configuration first by passing `mode: 'recklesslyUnprepared'`. + + ```diff + import { sendTransaction } from '@wagmi/core' + + const result = await sendTransaction({ + + mode: 'recklesslyUnprepared', + request: { + to: 'moxey.eth', + value: parseEther('1'), + } + }) + ``` + +* [#760](https://github.com/wevm/wagmi/pull/760) [`d8af6bf`](https://github.com/wevm/wagmi/commit/d8af6bf50885aec110ae4d64716642453aa27896) Thanks [@tmm](https://github.com/tmm)! - **Breaking:** `alchemyProvider` and `infuraProvider` now use a generic `apiKey` configuration option instead of `alchemyId` and `infuraId`. + + ```diff + import { alchemyProvider } from '@wagmi/core/providers/alchemy' + import { infuraProvider } from '@wagmi/core/providers/infura' + + alchemyProvider({ + - alchemyId: 'yourAlchemyApiKey', + + apiKey: 'yourAlchemyApiKey', + }) + + infuraProvider({ + - infuraId: 'yourInfuraApiKey', + + apiKey: 'yourInfuraApiKey', + }) + ``` + +- [#727](https://github.com/wevm/wagmi/pull/727) [`ac3b9b8`](https://github.com/wevm/wagmi/commit/ac3b9b87f80cb45b65d003f09d916d7d1427a62e) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: Moved the `pollingInterval` config option from the chain provider config to `configureChains` config. + + ```diff + const { chains, provider } = configureChains( + [chain.mainnet, chain.polygon], + [ + - alchemyProvider({ apiKey, pollingInterval: 5000 }), + - publicProvider({ pollingInterval: 5000 }) + + alchemyProvider({ apiKey }), + + publicProvider() + ], + + { pollingInterval: 5000 } + ) + ``` + +* [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - **Breaking:** The `sendTransaction` action now returns an object only consisting of `hash` & `wait`, and not the full [`TransactionResponse`](https://docs.ethers.io/v5/api/providers/types/#providers-TransactionResponse). + + If you require the full `TransactionResponse`, you can use `fetchTransaction`: + + ```diff + import { sendTransaction, fetchTransaction } from '@wagmi/core' + + const { + hash, + wait, + - ...transaction + } = sendTransaction(...) + + +const transaction = fetchTransaction({ hash }) + ``` + + > Why? The old implementation of `sendTransaction` created a long-running async task, causing [UX pitfalls](https://wagmi.sh/docs/prepare-hooks#ux-pitfalls-without-prepare-hooks) when invoked in a click handler. + +- [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: If a `chainId` is passed to `writeContract` or `sendTransaction`, it will no longer attempt to switch chain before sending the transaction. Instead, it will throw an error if the user is on the wrong chain. + + > Why? + > + > - Eagerly prompting to switch chain in these actions created a long-running async task that that makes [iOS App Links](https://wagmi.sh/docs/prepare-hooks#ios-app-link-constraints) vulnerable. + > - Not all wallets support programmatic chain switching. + +### Patch Changes + +- [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The configuration passed to the `writeContract` action now needs to be: + + - prepared with the `prepareWriteContract` action **(new functionality)**, or + - recklessly unprepared **(previous functionality)** + + > Why? [Read here](https://wagmi.sh/docs/prepare-hooks) + + ### Prepared usage + + ```diff + import { prepareWriteContract, writeContract } from '@wagmi/core' + + const tokenId = 69 + + +const config = await prepareWriteContract({ + + addressOrName: '0x...', + + contractInterface: wagmiAbi, + + functionName: 'mint', + + args: [tokenId] + +}) + + const result = await writeContract({ + - addressOrName: '0x...', + - contractInterface: wagmiAbi, + - functionName: 'mint', + - args: [tokenId], + + ...config + }) + ``` + + ### Recklessly unprepared usage + + It is possible to use `writeContract` without preparing the configuration first by passing `mode: 'recklesslyUnprepared'`. + + ```diff + import { writeContract } from '@wagmi/core' + + const tokenId = 69 + + const result = await writeContract({ + + mode: 'recklesslyUnprepared', + addressOrName: '0x...', + contractInterface: wagmiAbi, + functionName: 'mint', + args: [tokenId], + }) + ``` + +* [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - Added the `prepareSendTransaction` hook that prepares the parameters required for sending a transaction. + + It returns config to be passed through to `sendTransaction`. + + ```ts + import { prepareSendTransaction, sendTransaction } from "@wagmi/core"; + + const config = await prepareSendTransaction({ + request: { + to: "moxey.eth", + value: parseEther("1"), + }, + }); + const result = await sendTransaction(config); + ``` + +- [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - Added the `prepareWriteContract` hook that prepares the parameters required for a contract write transaction. + + It returns config to be passed through to `writeContract`. + + Example: + + ```tsx + import { prepareWriteContract, writeContract } from "@wagmi/core"; + + const config = await prepareWriteContract({ + addressOrName: "0x...", + contractInterface: wagmiAbi, + functionName: "mint", + }); + const result = await writeContract(config); + ``` + +* [#739](https://github.com/wevm/wagmi/pull/739) [`c2295a5`](https://github.com/wevm/wagmi/commit/c2295a56cc86d02cc6602e2b4557b8ab9a091a3f) Thanks [@tmm](https://github.com/tmm)! - Fix balance formatting for tokens that do not have 18 decimals. + +- [#759](https://github.com/wevm/wagmi/pull/759) [`959953d`](https://github.com/wevm/wagmi/commit/959953d1f5b3e8189bac56de245c62333470d18e) Thanks [@tmm](https://github.com/tmm)! - Added `fetchTransaction` action: + + ```ts + import { fetchTransaction } from "@wagmi/core"; + + const transaction = await fetchTransaction({ + hash: "0x5c504ed432cb51138bcf09aa5e8a410dd4a1e204ef84bfed1be16dfba1b22060", + }); + ``` + +## 0.4.9 + +### Patch Changes + +- [#721](https://github.com/tmm/wagmi/pull/721) [`abea25f`](https://github.com/tmm/wagmi/commit/abea25fd15d81d1ecaec9d3fbd687042ab29b1e6) Thanks [@tmm](https://github.com/tmm)! - Stay connected to existing `client.connector` when `connect` action fails to connect to new connector. + +* [#721](https://github.com/tmm/wagmi/pull/721) [`abea25f`](https://github.com/tmm/wagmi/commit/abea25fd15d81d1ecaec9d3fbd687042ab29b1e6) Thanks [@tmm](https://github.com/tmm)! - Switch `fetchToken` action to multicall and add `name` output property. + +## 0.4.8 + +### Patch Changes + +- [#693](https://github.com/tmm/wagmi/pull/693) [`56e468c`](https://github.com/tmm/wagmi/commit/56e468c3617ec222527bb3c02eadec3ebeff923a) Thanks [@markdalgleish](https://github.com/markdalgleish)! - Fix import errors with Coinbase Wallet SDK in Vite + +## 0.4.7 + +### Patch Changes + +- [#677](https://github.com/tmm/wagmi/pull/677) [`35e4219`](https://github.com/tmm/wagmi/commit/35e42199af9dd346549c1718e144728f55b8d7dd) Thanks [@jxom](https://github.com/jxom)! - Move `parseContractResult` to `@wagmi/core` + +## 0.4.6 + +### Patch Changes + +- [#670](https://github.com/tmm/wagmi/pull/670) [`29a0d21`](https://github.com/tmm/wagmi/commit/29a0d21ee83995559f63542778dfa805f15e7441) Thanks [@tmm](https://github.com/tmm)! - Added ethers-compatible `deepEqual` function. + +## 0.4.5 + +### Patch Changes + +- [#654](https://github.com/tmm/wagmi/pull/654) [`e66530b`](https://github.com/tmm/wagmi/commit/e66530bf4881b3533c528f8c5a5f41be0eab0a64) Thanks [@jxom](https://github.com/jxom)! - fix `multicall` returning nullish data for all calls unexpectedly + +## 0.4.4 + +### Patch Changes + +- [#616](https://github.com/tmm/wagmi/pull/616) [`7a7a17a`](https://github.com/tmm/wagmi/commit/7a7a17a46d4c9e6465cc46a111b5fe8a56109f1b) Thanks [@tmm](https://github.com/tmm)! - Adds `UNSTABLE_shimOnConnectSelectAccount` flag. With this flag and "disconnected" with `shimDisconnect` enabled, the user is prompted to select a different MetaMask account (than the currently connected account) when trying to connect (e.g. `useConnect`/`connect` action). + +## 0.4.3 + +### Patch Changes + +- [#631](https://github.com/tmm/wagmi/pull/631) [`a780e32`](https://github.com/tmm/wagmi/commit/a780e32e91a0072c795fa0b5a6111302768e2a01) Thanks [@tmm](https://github.com/tmm)! - Fix WalletConnect stale session + +## 0.4.2 + +### Patch Changes + +- [#624](https://github.com/tmm/wagmi/pull/624) [`416fa7e`](https://github.com/tmm/wagmi/commit/416fa7ee1f8019ab86e33fb93783ffddecc02c49) Thanks [@jxom](https://github.com/jxom)! - Fix broken `WebSocketProvider` type defs + +## 0.4.1 + +### Patch Changes + +- [#622](https://github.com/tmm/wagmi/pull/622) [`d171581`](https://github.com/tmm/wagmi/commit/d171581464891dd870d97b6232205da0cb152d9b) Thanks [@tmm](https://github.com/tmm)! - Use `domain.chainId` to validate and switch chain before signing in `signTypedData`. + +* [#618](https://github.com/tmm/wagmi/pull/618) [`a5138e8`](https://github.com/tmm/wagmi/commit/a5138e82a00e4d9469ad78c97b2d34200d7f1fbe) Thanks [@tmm](https://github.com/tmm)! - Fix adding chains when using MetaMask mobile app, add `publicRpcUrls` constant, and default to public endpoint when adding chain. + +## 0.4.0 + +### Minor Changes + +- [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The `provider` config option is now required on `createClient`. It is recommended to pass the [`provider` given from `configureChains`](https://wagmi.sh/docs/providers/configuring-chains). + + ```diff + import { + createClient, + + defaultChains, + + configureChains + } from 'wagmi' + +import { publicProvider } from 'wagmi/providers/publicProvider' + + +const { provider } = configureChains(defaultChains, [ + + publicProvider + +]) + + const client = createClient({ + + provider + }) + ``` + + If you previously used an ethers.js Provider, you now need to provide your `chains` on the Provider instance: + + ```diff + import { + createClient, + + defaultChains + } from 'wagmi' + import ethers from 'ethers' + + const client = createClient({ + - provider: getDefaultProvider() + + provider: Object.assign(getDefaultProvider(), { chains: defaultChains }) + }) + ``` + +* [`4f8f3c0`](https://github.com/tmm/wagmi/commit/4f8f3c0d65383bd8bbdfc3f1033adfdb11d80ebb) Thanks [@nachoiacovino](https://github.com/nachoiacovino)! - Use ethereum-lists chains symbols + +- [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - **Breaking:** Removed the `chainId` parameter from `connectors` function on `createClient`. + + ```diff + const client = createClient({ + - connectors({ chainId }) { + + connectors() { + ... + } + }) + ``` + + If you previously derived RPC URLs from the `chainId` on `connectors`, you can now remove that logic as `wagmi` now handles RPC URLs internally when used with `configureChains`. + + ```diff + import { + chain, + + configureChains, + createClient + } from 'wagmi'; + + +import { publicProvider } from 'wagmi/providers/public' + + import { CoinbaseWalletConnector } from 'wagmi/connectors/coinbaseWallet' + import { InjectedConnector } from 'wagmi/connectors/injected' + import { MetaMaskConnector } from 'wagmi/connectors/metaMask' + import { WalletConnectConnector } from 'wagmi/connectors/walletConnect' + + +const { chains } = configureChains( + + [chain.mainnet], + + [publicProvider()] + +); + + const client = createClient({ + - connectors({ chainId }) { + - const chain = chains.find((x) => x.id === chainId) ?? defaultChain + - const rpcUrl = chain.rpcUrls.alchemy + - ? `${chain.rpcUrls.alchemy}/${alchemyId}` + - : chain.rpcUrls.default + - return [ + + connectors: [ + new MetaMaskConnector({ chains }), + new CoinbaseWalletConnector({ + chains, + options: { + appName: 'wagmi', + - chainId: chain.id, + - jsonRpcUrl: rpcUrl, + }, + }), + new WalletConnectConnector({ + chains, + options: { + qrcode: true, + - rpc: { [chain.id]: rpcUrl }, + }, + }), + new InjectedConnector({ + chains, + options: { name: 'Injected' }, + }), + ] + - }, + }) + ``` + +* [#611](https://github.com/tmm/wagmi/pull/611) [`3089c34`](https://github.com/tmm/wagmi/commit/3089c34196d4034acabac031e0a2f7ee63ae30cc) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: `Connector`s `getProvider` method no longer supports the `create` config parameter. Use the `chainId` config option instead. + +- [#596](https://github.com/tmm/wagmi/pull/596) [`a770af7`](https://github.com/tmm/wagmi/commit/a770af7d2cb214b6620d5341115f1e938e1e77ff) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: `TypedDataDomain` and `TypedDataField` types were removed and incorporated into `SignTypedDataArgs`. + +* [`4f8f3c0`](https://github.com/tmm/wagmi/commit/4f8f3c0d65383bd8bbdfc3f1033adfdb11d80ebb) Thanks [@nachoiacovino](https://github.com/nachoiacovino)! - Update symbols to match ethereum-lists/chains + +- [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The `writeContract` function parameters have been consolidated into a singular config parameter. + + Before: + + ```tsx + writeContract( + { + addressOrName: "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + contractInterface: wagmigotchiABI, + }, + "feed", + ); + ``` + + After: + + ```tsx + readContract({ + addressOrName: "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + contractInterface: wagmigotchiABI, + functionName: "feed", + }); + ``` + +### Patch Changes + +- [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The `readContract` & `watchReadContract` function parameters have been consolidated into a singular config parameter. + + Before: + + ```tsx + readContract( + { + addressOrName: "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + contractInterface: wagmigotchiABI, + }, + "getHunger", + { args: [0] }, + ); + + watchReadContract( + { + addressOrName: "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + contractInterface: wagmigotchiABI, + }, + "getHunger", + { args: [0] }, + (result) => {}, + ); + ``` + + After: + + ```tsx + readContract({ + addressOrName: "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + contractInterface: wagmigotchiABI, + functionName: "getHunger", + args: [0], + }); + + watchReadContract( + { + addressOrName: "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + contractInterface: wagmigotchiABI, + functionName: "getHunger", + args: [0], + }, + (result) => {}, + ); + ``` + +* [#598](https://github.com/tmm/wagmi/pull/598) [`fef26bf`](https://github.com/tmm/wagmi/commit/fef26bf8aef76fc9621e3cd54d4e0ca8f69abb38) Thanks [@markdalgleish](https://github.com/markdalgleish)! - Update `@coinbase/wallet-sdk` peer dependency to `>=3.3.0` to fix errors when connecting with older versions of the Coinbase Wallet extension and mobile app. + +- [#611](https://github.com/tmm/wagmi/pull/611) [`3089c34`](https://github.com/tmm/wagmi/commit/3089c34196d4034acabac031e0a2f7ee63ae30cc) Thanks [@tmm](https://github.com/tmm)! - Added `chainId` config parameter for `writeContract` and `sendTransaction`. + + If `chainId` is provided, the connector will validate that `chainId` is the active chain before sending a transaction (and switch to `chainId` if necessary). + +* [#582](https://github.com/tmm/wagmi/pull/582) [`b03830a`](https://github.com/tmm/wagmi/commit/b03830a54465215c2526f9509543fe2c978bfe70) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where the wagmi client's `status` would not update from `"disconnected"` to `"connecting" -> "connected"` when the `connect` action is invoked. + +- [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - Added a `multicall` & `watchMulticall` action that provides multicall support. + + Internally uses the [`multicall3` contract](https://github.com/mds1/multicall). + + [See example usage](https://github.com/tmm/wagmi/blob/194866032985fdd3f49bc46bf1b14181d7cb61d1/packages/core/src/actions/contracts/multicall.test.ts) + +* [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - Added a `readContracts` & `watchReadContracts` action that provides the ability to batch up multiple ethers Contract read-only methods. + +## 0.3.8 + +### Patch Changes + +- [#570](https://github.com/tmm/wagmi/pull/570) [`0e3fe15`](https://github.com/tmm/wagmi/commit/0e3fe15445377f35d6f4142b49bf1c96bfeb62cd) Thanks [@tmm](https://github.com/tmm)! - adds chain for [Foundry](https://github.com/foundry-rs) + +## 0.3.7 + +### Patch Changes + +- [#550](https://github.com/tmm/wagmi/pull/550) [`2a5313e`](https://github.com/tmm/wagmi/commit/2a5313e8cbc9ba6335e8e4b85e43862c9b711bd3) Thanks [@tmm](https://github.com/tmm)! - fix `CoinbaseWalletConnector` possible type error + +* [#548](https://github.com/tmm/wagmi/pull/548) [`0c48719`](https://github.com/tmm/wagmi/commit/0c487199f2421f042abc1f1d139468ccbbc5646a) Thanks [@dohaki](https://github.com/dohaki)! - add ensAddress to Chain type + +- [#549](https://github.com/tmm/wagmi/pull/549) [`89b3a74`](https://github.com/tmm/wagmi/commit/89b3a74ead4234daacd0dcf8506659887ebf0553) Thanks [@tmm](https://github.com/tmm)! - Turns on [`noUncheckedIndexedAccess`](https://www.typescriptlang.org/tsconfig#noUncheckedIndexedAccess=) and [`strictNullChecks`](https://www.typescriptlang.org/tsconfig#strictNullChecks=) for better runtime safety. + +## 0.3.6 + +### Patch Changes + +- [#526](https://github.com/tmm/wagmi/pull/526) [`e95c5f9`](https://github.com/tmm/wagmi/commit/e95c5f91859e57d079b962a72d06b93dce004d2f) Thanks [@jxom](https://github.com/jxom)! - Added `shimChainChangedDisconnect` option to `InjectedConnector`. Defaults to `true` for `MetaMaskConnector`. + +* [#526](https://github.com/tmm/wagmi/pull/526) [`e95c5f9`](https://github.com/tmm/wagmi/commit/e95c5f91859e57d079b962a72d06b93dce004d2f) Thanks [@jxom](https://github.com/jxom)! - Added `lastUsedChainId` property to the wagmi `Client`. + +- [#526](https://github.com/tmm/wagmi/pull/526) [`e95c5f9`](https://github.com/tmm/wagmi/commit/e95c5f91859e57d079b962a72d06b93dce004d2f) Thanks [@jxom](https://github.com/jxom)! - Added `chainId` config option to the `connect` action. + + Example: + + ```tsx + import { connect } from "@wagmi/core"; + + await connect({ chainId: 69 }); + ``` + +## 0.3.5 + +### Patch Changes + +- [#543](https://github.com/tmm/wagmi/pull/543) [`4d489fd`](https://github.com/tmm/wagmi/commit/4d489fd630dd8c00440bdaf4d646de662c41ff52) Thanks [@tmm](https://github.com/tmm)! - fix fee data formatting for null values + +## 0.3.4 + +### Patch Changes + +- [`c4deb66`](https://github.com/tmm/wagmi/commit/c4deb6655a52e4cc4e5b3fd82202db11d6106848) Thanks [@jxom](https://github.com/jxom)! - infer `options.chainId` config from `chains` on WalletConnectConnector + +## 0.3.3 + +### Patch Changes + +- [#486](https://github.com/tmm/wagmi/pull/486) [`dbfe3dd`](https://github.com/tmm/wagmi/commit/dbfe3dd320d178d6854a8096101200c1508786bb) Thanks [@tmm](https://github.com/tmm)! - add chains entrypoint + +## 0.3.2 + +### Patch Changes + +- [`17212da`](https://github.com/tmm/wagmi/commit/17212da601640110d2835300e6433d1433db212e) Thanks [@jxom](https://github.com/jxom)! - Made the `defaultChains` type generic in `configureChains`. + +## 0.3.1 + +### Patch Changes + +- [#484](https://github.com/tmm/wagmi/pull/484) [`1b9a503`](https://github.com/tmm/wagmi/commit/1b9a5033d51c6655b4f6570c490da6e0e9a29da9) Thanks [@tmm](https://github.com/tmm)! - export React Context + +## 0.3.0 + +### Minor Changes + +- [#408](https://github.com/tmm/wagmi/pull/408) [`bfcc3a5`](https://github.com/tmm/wagmi/commit/bfcc3a51bbb1551753e3ccde6af134e9fd4fec9a) Thanks [@jxom](https://github.com/jxom)! - **Breaking:** The `connectors` option on `createClient` no longer reacts to chain switching. + + **Passing a function to `connectors` has been deprecated.** + + If you previously derived an RPC URL from the `chainId` in `connectors`, you will need to migrate to use the [`configureChains` API](https://wagmi.sh/docs/providers/configuring-chains). + + ### Before + + ```tsx + import { providers } from "ethers"; + import { chain, createClient, defaultChains } from "wagmi"; + import { CoinbaseWalletConnector } from "wagmi/connectors/coinbaseWallet"; + import { InjectedConnector } from "wagmi/connectors/injected"; + import { MetaMaskConnector } from "wagmi/connectors/metaMask"; + import { WalletConnectConnector } from "wagmi/connectors/walletConnect"; + + const alchemyId = process.env.ALCHEMY_ID; + + const chains = defaultChains; + const defaultChain = chain.mainnet; + + const client = createClient({ + autoConnect: true, + connectors({ chainId }) { + const chain = chains.find((x) => x.id === chainId) ?? defaultChain; + const rpcUrl = chain.rpcUrls.alchemy + ? `${chain.rpcUrls.alchemy}/${alchemyId}` + : chain.rpcUrls.default; + return [ + new MetaMaskConnector({ chains }), + new CoinbaseWalletConnector({ + chains, + options: { + appName: "wagmi", + chainId: chain.id, + jsonRpcUrl: rpcUrl, + }, + }), + new WalletConnectConnector({ + chains, + options: { + qrcode: true, + rpc: { [chain.id]: rpcUrl }, + }, + }), + new InjectedConnector({ + chains, + options: { + name: "Injected", + shimDisconnect: true, + }, + }), + ]; + }, + }); + ``` + + ### After + + ```tsx + import { chain, createClient, defaultChains } from "wagmi"; + + import { alchemyProvider } from "wagmi/providers/alchemy"; + import { publicProvider } from "wagmi/providers/public"; + + import { CoinbaseWalletConnector } from "wagmi/connectors/coinbaseWallet"; + import { InjectedConnector } from "wagmi/connectors/injected"; + import { MetaMaskConnector } from "wagmi/connectors/metaMask"; + import { WalletConnectConnector } from "wagmi/connectors/walletConnect"; + + const alchemyId = process.env.ALCHEMY_ID; + + const { chains } = configureChains(defaultChains, [ + alchemyProvider({ alchemyId }), + publicProvider(), + ]); + + const client = createClient({ + autoConnect: true, + connectors: [ + new MetaMaskConnector({ chains }), + new CoinbaseWalletConnector({ + chains, + options: { + appName: "wagmi", + }, + }), + new WalletConnectConnector({ + chains, + options: { + qrcode: true, + }, + }), + new InjectedConnector({ + chains, + options: { + name: "Injected", + shimDisconnect: true, + }, + }), + ], + }); + ``` + +* [#468](https://github.com/tmm/wagmi/pull/468) [`44a884b`](https://github.com/tmm/wagmi/commit/44a884b84171c418f57701e80ef8de972948ef0b) Thanks [@tmm](https://github.com/tmm)! - **Breaking:** Duplicate exports with different names and the same functionality were removed to simplify the public API. In addition, confusing exports were renamed to be more descriptive. + + - `createWagmiClient` alias was removed. Use `createClient` instead. + - `useWagmiClient` alias was removed. Use `useClient` instead. + - `WagmiClient` alias was removed. Use `Client` instead. + - `createWagmiStorage` alias was removed. Use `createStorage` instead. + - `Provider` was renamed and `WagmiProvider` alias was removed. Use `WagmiConfig` instead. + +- [#408](https://github.com/tmm/wagmi/pull/408) [`bfcc3a5`](https://github.com/tmm/wagmi/commit/bfcc3a51bbb1551753e3ccde6af134e9fd4fec9a) Thanks [@jxom](https://github.com/jxom)! - Add `configureChains` API. + + The `configureChains` function allows you to configure your chains with a selected provider (Alchemy, Infura, JSON RPC, Public RPC URLs). This means you don't have to worry about deriving your own RPC URLs for each chain, or instantiating a Ethereum Provider. + + `configureChains` accepts 3 parameters: an array of chains, and an array of providers, and a config object. + + [Learn more about configuring chains & providers.](https://wagmi.sh/docs/providers/configuring-chains) + + ### Before + + ```tsx + import { providers } from "ethers"; + import { chain, createClient, defaultChains } from "wagmi"; + import { CoinbaseWalletConnector } from "wagmi/connectors/coinbaseWallet"; + import { InjectedConnector } from "wagmi/connectors/injected"; + import { MetaMaskConnector } from "wagmi/connectors/metaMask"; + import { WalletConnectConnector } from "wagmi/connectors/walletConnect"; + + const alchemyId = process.env.ALCHEMY_ID; + + const chains = defaultChains; + const defaultChain = chain.mainnet; + + const client = createClient({ + autoConnect: true, + connectors({ chainId }) { + const chain = chains.find((x) => x.id === chainId) ?? defaultChain; + const rpcUrl = chain.rpcUrls.alchemy + ? `${chain.rpcUrls.alchemy}/${alchemyId}` + : chain.rpcUrls.default; + return [ + new MetaMaskConnector({ chains }), + new CoinbaseWalletConnector({ + chains, + options: { + appName: "wagmi", + chainId: chain.id, + jsonRpcUrl: rpcUrl, + }, + }), + new WalletConnectConnector({ + chains, + options: { + qrcode: true, + rpc: { [chain.id]: rpcUrl }, + }, + }), + new InjectedConnector({ + chains, + options: { + name: "Injected", + shimDisconnect: true, + }, + }), + ]; + }, + provider: ({ chainId }) => + new providers.AlchemyProvider(chainId, alchemyId), + }); + ``` + + ### After + + ```tsx + import { chain, createClient, defaultChains } from "wagmi"; + + import { alchemyProvider } from "wagmi/providers/alchemy"; + import { publicProvider } from "wagmi/providers/public"; + + import { CoinbaseWalletConnector } from "wagmi/connectors/coinbaseWallet"; + import { InjectedConnector } from "wagmi/connectors/injected"; + import { MetaMaskConnector } from "wagmi/connectors/metaMask"; + import { WalletConnectConnector } from "wagmi/connectors/walletConnect"; + + const alchemyId = process.env.ALCHEMY_ID; + + const { chains, provider, webSocketProvider } = configureChains( + defaultChains, + [alchemyProvider({ alchemyId }), publicProvider()], + ); + + const client = createClient({ + autoConnect: true, + connectors: [ + new MetaMaskConnector({ chains }), + new CoinbaseWalletConnector({ + chains, + options: { + appName: "wagmi", + }, + }), + new WalletConnectConnector({ + chains, + options: { + qrcode: true, + }, + }), + new InjectedConnector({ + chains, + options: { + name: "Injected", + shimDisconnect: true, + }, + }), + ], + provider, + webSocketProvider, + }); + ``` + +### Patch Changes + +- [#404](https://github.com/tmm/wagmi/pull/404) [`f81c156`](https://github.com/tmm/wagmi/commit/f81c15665e2e71534f84ada3fa705f2d78627472) Thanks [@holic](https://github.com/holic)! - Add `ProviderRpcError` and `RpcError` error classes. + + Certain wagmi-standardized errors may wrap `ProviderRpcError` or `RpcError`. For these cases, you can access the original provider rpc or rpc error value using the `internal` property. + +* [#459](https://github.com/tmm/wagmi/pull/459) [`72dcf7c`](https://github.com/tmm/wagmi/commit/72dcf7c09e814261b2e43a8fa364c57675c472de) Thanks [@tmm](https://github.com/tmm)! - update dependencies + +- [#473](https://github.com/tmm/wagmi/pull/473) [`a54f3e2`](https://github.com/tmm/wagmi/commit/a54f3e23ea385ed8aa4ad188128d7089ba20f83e) Thanks [@cesargdm](https://github.com/cesargdm)! - Add workaround for CoinbaseWalletSDK import on esbuild + +* [#447](https://github.com/tmm/wagmi/pull/447) [`b9ebf78`](https://github.com/tmm/wagmi/commit/b9ebf782e0900725bcb76483686b30f09d357ebd) Thanks [@tmm](https://github.com/tmm)! - Fix case where connector disconnected while app was closed and stale data was returned when autoconnecting. For example, [MetaMask was locked](https://github.com/tmm/wagmi/issues/444) when page was closed. + +## 0.2.5 + +### Patch Changes + +- [`4e03666`](https://github.com/tmm/wagmi/commit/4e03666428d42fc9186c617001b5eb356229677e) Thanks [@tmm](https://github.com/tmm)! - bump dependencies #429 + add imToken support for WC switch chains #432 + fix MetaMask and Brave Wallet collision #436 + +## 0.2.4 + +### Patch Changes + +- [#421](https://github.com/tmm/wagmi/pull/421) [`a232b3f`](https://github.com/tmm/wagmi/commit/a232b3ff5cc41e882c4d2a34c599a8cb670edd2b) Thanks [@tmm](https://github.com/tmm)! - fix erc721 abi + +## 0.2.3 + +### Patch Changes + +- [#412](https://github.com/tmm/wagmi/pull/412) [`80bef4f`](https://github.com/tmm/wagmi/commit/80bef4ff3f714b0b8f896f1b4b658acc7266299b) Thanks [@markdalgleish](https://github.com/markdalgleish)! - Import providers from `ethers` peer dependency rather than `@ethersproject/providers` to avoid multiple conflicting versions being installed + +## 0.2.2 + +### Patch Changes + +- [`018c2a1`](https://github.com/tmm/wagmi/commit/018c2a11b22ee513571cc7f83fd63f7eb169ee70) Thanks [@tmm](https://github.com/tmm)! - - warn and fallback to default client #380 + + - remove signerOrProvider option from read contract #390 + + - MetaMaskConnector #391 + +## 0.2.1 + +### Patch Changes + +- [`afc4607`](https://github.com/tmm/wagmi/commit/afc46071e91601ab8a2b465524da796cd60b6ad4) Thanks [@tmm](https://github.com/tmm)! - - Fix time scaling e9593df + - Use fully-specified path for use-sync-external-store import 7b235c1 + - Update serialize 236fc17 + +## 0.2.0 + +### Minor Changes + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - don't persist account data when `autoConnect` is falsy + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - - fix(@wagmi/core): persist connector chains to local storage + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - - Favour `message` event over `connecting` event to conform to EIP-1193 + - Export `useWaitForTransaction` + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - Initial 0.3.0 release + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - Add `cacheOnBlock` config for `useContractRead` + Update `react-query` to v4 + Fix `watchBlockNumber` listener leak + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - add `connecting` event to connectors + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - Fix issue where `getProvider` was not being awaited in `getSigner` + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - - remove storage persistence of `connector` + - add `chains` to client state + +### Patch Changes + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - add chainId to actions and hooks + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - showtime + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - improve type support for ethers providers + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - update zustand + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - update babel target + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - update block explorers and rpc urls structure + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - keep previous data when watching + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - republish + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - fix stale connectors when switching chains + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - last beta + +## 0.2.0-next.18 + +### Patch Changes + +- showtime + +## 0.2.0-next.17 + +### Patch Changes + +- update block explorers and rpc urls structure + +## 0.2.0-next.16 + +### Patch Changes + +- last beta + +## 0.2.0-next.15 + +### Patch Changes + +- update zustand + +## 0.2.0-next.14 + +### Minor Changes + +- Add `cacheOnBlock` config for `useContractRead` +- Update `react-query` to v4 +- Fix `watchBlockNumber` listener leak + +## 0.2.0-next.13 + +### Patch Changes + +- keep previous data when watching + +## 0.2.0-next.12 + +### Patch Changes + +- add chainId to actions and hooks + +## 0.2.0-next.11 + +### Patch Changes + +- fix stale connectors when switching chains + +## 0.2.0-next.10 + +### Patch Changes + +- republish + +## 0.2.0-next.9 + +### Patch Changes + +- improve type support for ethers providers + +## 0.2.0-next.8 + +### Patch Changes + +- update babel target + +## 0.2.0-next.7 + +### Minor Changes + +- - Favour `message` event over `connecting` event to conform to EIP-1193 + - Export `useWaitForTransaction` + +## 0.2.0-next.6 + +### Minor Changes + +- add `connecting` event to connectors + +## 0.2.0-next.5 + +### Minor Changes + +- don't persist account data when `autoConnect` is falsy + +## 0.2.0-next.4 + +### Minor Changes + +- remove storage persistence of `connector` +- add `chains` to client state + +## 0.2.0-next.3 + +### Minor Changes + +- Fix issue where `getProvider` was not being awaited in `getSigner` + +## 0.2.0-next.2 + +### Minor Changes + +- fix: persist connector chains to local storage + +## 0.2.0-next.1 + +### Minor Changes + +- Initial 0.3.0 release + +## 0.1.22 + +### Patch Changes + +- [`747d895`](https://github.com/tmm/wagmi/commit/747d895a54b562958afde34b1d34e81ab5039e2c) Thanks [@tmm](https://github.com/tmm)! - add warning to WalletLinkConnector + +## 0.1.21 + +### Patch Changes + +- [`c858c51`](https://github.com/tmm/wagmi/commit/c858c51b44d9039f1d0db5bcf016639f47d1931f) Thanks [@tmm](https://github.com/tmm)! - update coinbase connector + +## 0.1.20 + +### Patch Changes + +- [#326](https://github.com/tmm/wagmi/pull/326) [`36e6989`](https://github.com/tmm/wagmi/commit/36e69894f4c27aaad7fb6d678476c8bb870244bb) Thanks [@0xGabi](https://github.com/0xGabi)! - Add Gnosis Chain + +## 0.1.19 + +### Patch Changes + +- [`d467df6`](https://github.com/tmm/wagmi/commit/d467df6374210dbc4b016788b4beb4fded54cb4d) Thanks [@tmm](https://github.com/tmm)! - fix global type leaking + +## 0.1.18 + +### Patch Changes + +- [#294](https://github.com/tmm/wagmi/pull/294) [`1d253f3`](https://github.com/tmm/wagmi/commit/1d253f3a59b61d24c88d25c99decd84a6c734e5d) Thanks [@tmm](https://github.com/tmm)! - change babel target + +## 0.1.17 + +### Patch Changes + +- [#292](https://github.com/tmm/wagmi/pull/292) [`53c9be1`](https://github.com/tmm/wagmi/commit/53c9be17ee0c2ae6b8f34f2351b8858257b3f5f2) Thanks [@tmm](https://github.com/tmm)! - fix private fields + +## 0.1.16 + +### Patch Changes + +- [`79a2499`](https://github.com/tmm/wagmi/commit/79a249989029f818c32c0e84c0dd2c75e8aa990a) Thanks [@tmm](https://github.com/tmm)! - update build target to es2021 + +## 0.1.15 + +### Patch Changes + +- [`f9790b5`](https://github.com/tmm/wagmi/commit/f9790b55600df09c77bb8ca349c5a3457df1b07c) Thanks [@tmm](https://github.com/tmm)! - fix WalletConnect issue + +## 0.1.14 + +### Patch Changes + +- [#236](https://github.com/tmm/wagmi/pull/236) [`53bad61`](https://github.com/tmm/wagmi/commit/53bad615788764e31121678083c382c1bd042fe8) Thanks [@markdalgleish](https://github.com/markdalgleish)! - Updated `@walletconnect/ethereum-provider` to [v1.7.4](https://github.com/WalletConnect/walletconnect-monorepo/releases/tag/1.7.4) + +## 0.1.13 + +### Patch Changes + +- [`8e9412a`](https://github.com/tmm/wagmi/commit/8e9412af71958301ae2f9748febb936e79900aa0) Thanks [@tmm](https://github.com/tmm)! - bump walletlink + +## 0.1.12 + +### Patch Changes + +- [#210](https://github.com/tmm/wagmi/pull/210) [`684468a`](https://github.com/tmm/wagmi/commit/684468aee3e42a1ce2b4b599f3f17d1819213de8) Thanks [@tmm](https://github.com/tmm)! - update chains to match chainslist.org + +## 0.1.11 + +### Patch Changes + +- [#195](https://github.com/tmm/wagmi/pull/195) [`25b6083`](https://github.com/tmm/wagmi/commit/25b6083a662a0236794d1765343467691421c14b) Thanks [@tmm](https://github.com/tmm)! - rename wagmi-private to wagmi-core + +## 0.1.10 + +### Patch Changes + +- [#192](https://github.com/tmm/wagmi/pull/192) [`428cedb`](https://github.com/tmm/wagmi/commit/428cedb3dec4e3e4b9f4559c8e65932e05f94e05) Thanks [@tmm](https://github.com/tmm)! - rename core and testing packages + +## 0.1.9 + +### Patch Changes + +- [#190](https://github.com/tmm/wagmi/pull/190) [`7034bb8`](https://github.com/tmm/wagmi/commit/7034bb868412b9f481b206371280e84c2d52706d) Thanks [@tmm](https://github.com/tmm)! - add shim for metamask chain changed to prevent disconnect + +## 0.1.8 + +### Patch Changes + +- [#137](https://github.com/tmm/wagmi/pull/137) [`dceeb43`](https://github.com/tmm/wagmi/commit/dceeb430d9021fbf98366859cb1cd0149e80c55c) Thanks [@tmm](https://github.com/tmm)! - add siwe guide + +## 0.1.7 + +### Patch Changes + +- [#127](https://github.com/tmm/wagmi/pull/127) [`f05b031`](https://github.com/tmm/wagmi/commit/f05b0310f7f7e6447e9b6c81cedbb27dcf2f3649) Thanks [@tmm](https://github.com/tmm)! - update switch chain return type + +## 0.1.6 + +### Patch Changes + +- [`1412eed`](https://github.com/tmm/wagmi/commit/1412eed0d1494bb4f8c6845a0e890f79e4e68e03) Thanks [@tmm](https://github.com/tmm)! - add frame to injected + +## 0.1.5 + +### Patch Changes + +- [`e338c3b`](https://github.com/tmm/wagmi/commit/e338c3b6cc255742be6a67593aa5da6c17e90fbd) Thanks [@tmm](https://github.com/tmm)! - checksum connector address on change events + + add shim to injected connector for simulating disconnect + +## 0.1.4 + +### Patch Changes + +- [`0176c4e`](https://github.com/tmm/wagmi/commit/0176c4e83fb0c5f159c3c802a1da3d6deb2184ae) Thanks [@tmm](https://github.com/tmm)! - added switchChain to WalletConnect and WalletLink connectors + +## 0.1.3 + +### Patch Changes + +- [`071d7fb`](https://github.com/tmm/wagmi/commit/071d7fbca35ec4832700b5343661ceb2dae20598) Thanks [@tmm](https://github.com/tmm)! - add hardhat chain + +## 0.1.2 + +### Patch Changes + +- [`78bade9`](https://github.com/tmm/wagmi/commit/78bade9d0da97ab38a7e6594c34e3841ec1c8fe6) Thanks [@tmm](https://github.com/tmm)! - add type definitions + +## 0.1.1 + +### Patch Changes + +- [#56](https://github.com/tmm/wagmi/pull/56) [`2ebfd8e`](https://github.com/tmm/wagmi/commit/2ebfd8e85b560f25cd46cff04619c84643cab297) Thanks [@tmm](https://github.com/tmm)! - add chain support status + +## 0.1.0 + +### Minor Changes + +- [#52](https://github.com/tmm/wagmi/pull/52) [`da7a3a6`](https://github.com/tmm/wagmi/commit/da7a3a615def2443f65c041999100ce35e9774cc) Thanks [@tmm](https://github.com/tmm)! - Moves connectors to their own entrypoints to reduce bundle size. + + ```ts + // old - WalletLinkConnector unused, but still in final bundle + import { InjectedConnector, WalletConnectConnector } from "wagmi"; + + // new - WalletLinkConnector not in final bundle + import { InjectedConnector } from "wagmi/connectors/injected"; + import { WalletConnectConnector } from "wagmi/connectors/walletConnect"; + ``` + +## 0.0.17 + +### Patch Changes + +- [#25](https://github.com/tmm/wagmi/pull/25) [`9a7dab7`](https://github.com/tmm/wagmi/commit/9a7dab78b3518658bc7d85dc397990f0d28da175) Thanks [@tmm](https://github.com/tmm)! - update response types + +## 0.0.16 + +### Patch Changes + +- [`d1574cf`](https://github.com/tmm/wagmi/commit/d1574cf5f7a578ccd480889c2e375134145a4aba) Thanks [@tmm](https://github.com/tmm)! - add better type information for contract results + +## 0.0.15 + +### Patch Changes + +- [`3909624`](https://github.com/tmm/wagmi/commit/39096249c1fa9516beabb11735beb67c94032879) Thanks [@tmm](https://github.com/tmm)! - make contract read and write execute overrides param optional + +## 0.0.14 + +### Patch Changes + +- [`63312e2`](https://github.com/tmm/wagmi/commit/63312e2b06b8d835abc2908cba399d941ca79408) Thanks [@tmm](https://github.com/tmm)! - add once to contract event + +## 0.0.13 + +### Patch Changes + +- [`6f890b0`](https://github.com/tmm/wagmi/commit/6f890b0dabbdbea913ec91cb8bfc970c05ed0a93) Thanks [@tmm](https://github.com/tmm)! - update readme + +## 0.0.12 + +### Patch Changes + +- [#19](https://github.com/tmm/wagmi/pull/19) [`7bc1c47`](https://github.com/tmm/wagmi/commit/7bc1c47875e9ef24e9c79cfafc6b23e7a838b5bc) Thanks [@tmm](https://github.com/tmm)! - remove console log from walletlink connector + +## 0.0.11 + +### Patch Changes + +- [#17](https://github.com/tmm/wagmi/pull/17) [`571648b`](https://github.com/tmm/wagmi/commit/571648b754f7f538536bafc9387bd3104657ea49) Thanks [@tmm](https://github.com/tmm)! - standardize connector provider + +## 0.0.10 + +### Patch Changes + +- [#15](https://github.com/tmm/wagmi/pull/15) [`5f7675c`](https://github.com/tmm/wagmi/commit/5f7675c3ffd848522d4117c07c1f62b17dfc6616) Thanks [@tmm](https://github.com/tmm)! - read and write contract functions + +## 0.0.9 + +### Patch Changes + +- [#13](https://github.com/tmm/wagmi/pull/13) [`e5545f5`](https://github.com/tmm/wagmi/commit/e5545f5565cf0bbf5e62ec7ccab3051705b1d313) Thanks [@tmm](https://github.com/tmm)! - add testing package + +## 0.0.8 + +### Patch Changes + +- [`5332500`](https://github.com/tmm/wagmi/commit/5332500918ac240d29ffe4d2aed8566a8ac001e4) Thanks [@tmm](https://github.com/tmm)! - update signing + +## 0.0.7 + +### Patch Changes + +- [`0bff89a`](https://github.com/tmm/wagmi/commit/0bff89ab2ad28b2cb9b346d1ac870e859d9278bc) Thanks [@tmm](https://github.com/tmm)! - update injected connector + +## 0.0.6 + +### Patch Changes + +- [`37d39d1`](https://github.com/tmm/wagmi/commit/37d39d174ddfa122462bbe2d02141cd61eb9db4a) Thanks [@tmm](https://github.com/tmm)! - add message signing + +## 0.0.5 + +### Patch Changes + +- [`d7d94f0`](https://github.com/tmm/wagmi/commit/d7d94f06f7d30468e5e39d64db63124c6315cf82) Thanks [@tmm](https://github.com/tmm)! - fix injected connector name + +## 0.0.4 + +### Patch Changes + +- [`29fbe29`](https://github.com/tmm/wagmi/commit/29fbe2920046b9e87a34faa04500ccf3c4f83748) Thanks [@tmm](https://github.com/tmm)! - fix external deps + +## 0.0.3 + +### Patch Changes + +- [#6](https://github.com/tmm/wagmi/pull/6) [`8dc3a5d`](https://github.com/tmm/wagmi/commit/8dc3a5d5f418813b09663534fe585d9bcf94dbeb) Thanks [@tmm](https://github.com/tmm)! - clean up deps + +## 0.0.2 + +### Patch Changes - forbid "wait" transactions in sendTransactionBatch calls +- [#4](https://github.com/tmm/wagmi/pull/4) [`2fbd821`](https://github.com/tmm/wagmi/commit/2fbd8216379bd03c9cc5c06b10b75637e75cb7d8) Thanks [@tmm](https://github.com/tmm)! - init changesets diff --git a/packages/react/CHANGELOG.md b/packages/react/CHANGELOG.md new file mode 100644 index 0000000000..7dfc14098a --- /dev/null +++ b/packages/react/CHANGELOG.md @@ -0,0 +1,5037 @@ +# wagmi + +## 2.15.4 + +### Patch Changes + +- Updated dependencies [[`42b1fed58e9ac09da0f8ebf3e9271f98a707aaac`](https://github.com/wevm/wagmi/commit/42b1fed58e9ac09da0f8ebf3e9271f98a707aaac)]: + - @wagmi/connectors@5.8.3 + +## 2.15.3 + +### Patch Changes + +- Updated dependencies [[`29297a48af72b537173d948ccd2fe37d39914c66`](https://github.com/wevm/wagmi/commit/29297a48af72b537173d948ccd2fe37d39914c66), [`07370106d5fb6b8fe300992d93abf25b3d0eaf57`](https://github.com/wevm/wagmi/commit/07370106d5fb6b8fe300992d93abf25b3d0eaf57)]: + - @wagmi/core@2.17.2 + - @wagmi/connectors@5.8.2 + +## 2.15.2 + +### Patch Changes + +- [#4649](https://github.com/wevm/wagmi/pull/4649) [`01f64e64fa4f85cdd30023903f972f4f9023681f`](https://github.com/wevm/wagmi/commit/01f64e64fa4f85cdd30023903f972f4f9023681f) Thanks [@jxom](https://github.com/jxom)! - Added `chainId` parameter to `getCapabilities`/`useCapabilities`. + +- Updated dependencies [[`01f64e64fa4f85cdd30023903f972f4f9023681f`](https://github.com/wevm/wagmi/commit/01f64e64fa4f85cdd30023903f972f4f9023681f)]: + - @wagmi/core@2.17.1 + - @wagmi/connectors@5.8.1 + +## 2.15.1 + +### Patch Changes + +- Updated dependencies [[`cc5517ff6880bb630f1b201930acc20dd1a0b451`](https://github.com/wevm/wagmi/commit/cc5517ff6880bb630f1b201930acc20dd1a0b451)]: + - @wagmi/connectors@5.8.0 + +## 2.15.0 + +### Minor Changes + +- [#4638](https://github.com/wevm/wagmi/pull/4638) [`799ee4d4b23c2ecd64e3f3668e67634e81939719`](https://github.com/wevm/wagmi/commit/799ee4d4b23c2ecd64e3f3668e67634e81939719) Thanks [@jxom](https://github.com/jxom)! - Stabilized EIP-5792 Actions & Hooks. + +### Patch Changes + +- Updated dependencies [[`88427b2bcd13ec375ef519e9ad1ccffef9f02a7b`](https://github.com/wevm/wagmi/commit/88427b2bcd13ec375ef519e9ad1ccffef9f02a7b), [`799ee4d4b23c2ecd64e3f3668e67634e81939719`](https://github.com/wevm/wagmi/commit/799ee4d4b23c2ecd64e3f3668e67634e81939719), [`3f8b2edc4f237cccff1009bcef03d51ca27a7324`](https://github.com/wevm/wagmi/commit/3f8b2edc4f237cccff1009bcef03d51ca27a7324)]: + - @wagmi/connectors@6.0.0 + - @wagmi/core@2.17.0 + +## 2.14.16 + +### Patch Changes + +- Updated dependencies [[`b59c024b23c69f5459b17390531207cfdf126ce4`](https://github.com/wevm/wagmi/commit/b59c024b23c69f5459b17390531207cfdf126ce4)]: + - @wagmi/connectors@5.7.12 + +## 2.14.15 + +### Patch Changes + +- [`a4bd0623eed28e3761a27295831a60ad835f0ee0`](https://github.com/wevm/wagmi/commit/a4bd0623eed28e3761a27295831a60ad835f0ee0) Thanks [@jxom](https://github.com/jxom)! - **Experimental (EIP-5792):** Updated `id` parameter to be optional on `useWaitForCallsStatus`. + +- Updated dependencies [[`a4bd0623eed28e3761a27295831a60ad835f0ee0`](https://github.com/wevm/wagmi/commit/a4bd0623eed28e3761a27295831a60ad835f0ee0)]: + - @wagmi/core@2.16.7 + - @wagmi/connectors@5.7.11 + +## 2.14.14 + +### Patch Changes + +- [#4586](https://github.com/wevm/wagmi/pull/4586) [`edf47477b2f6385a1c3ae01d36a8498c47f30a0b`](https://github.com/wevm/wagmi/commit/edf47477b2f6385a1c3ae01d36a8498c47f30a0b) Thanks [@jxom](https://github.com/jxom)! - **Experimental (EIP-5792):** Added `waitForCallsStatus` + `useWaitForCallsStatus`. + +- Updated dependencies [[`edf47477b2f6385a1c3ae01d36a8498c47f30a0b`](https://github.com/wevm/wagmi/commit/edf47477b2f6385a1c3ae01d36a8498c47f30a0b), [`e944812ebc234a72c1417b77cff341166f5e0fef`](https://github.com/wevm/wagmi/commit/e944812ebc234a72c1417b77cff341166f5e0fef)]: + - @wagmi/core@2.16.6 + - @wagmi/connectors@5.7.10 + +## 2.14.13 + +### Patch Changes + +- Updated dependencies [[`5b7101fddb61df56e34b2e02b46bc409e496eaf9`](https://github.com/wevm/wagmi/commit/5b7101fddb61df56e34b2e02b46bc409e496eaf9)]: + - @wagmi/connectors@5.7.9 + +## 2.14.12 + +### Patch Changes + +- [`d0c9a86921a4e939373cc6e763284e53f2a2e93c`](https://github.com/wevm/wagmi/commit/d0c9a86921a4e939373cc6e763284e53f2a2e93c) Thanks [@jxom](https://github.com/jxom)! - **Experimental (ERC-5792)**: Added support for `account: null` in `sendCalls` to cater for sending calls without a connected account (account will be filled by the wallet). + +- Updated dependencies [[`d0c9a86921a4e939373cc6e763284e53f2a2e93c`](https://github.com/wevm/wagmi/commit/d0c9a86921a4e939373cc6e763284e53f2a2e93c)]: + - @wagmi/core@2.16.5 + - @wagmi/connectors@5.7.8 + +## 2.14.11 + +### Patch Changes + +- [`507f864d91238bfd423d0e36d3619eb9f6e52eec`](https://github.com/wevm/wagmi/commit/507f864d91238bfd423d0e36d3619eb9f6e52eec) Thanks [@jxom](https://github.com/jxom)! - Updated `@coinbase/wallet-sdk`. + +- Updated dependencies [[`507f864d91238bfd423d0e36d3619eb9f6e52eec`](https://github.com/wevm/wagmi/commit/507f864d91238bfd423d0e36d3619eb9f6e52eec)]: + - @wagmi/connectors@5.7.7 + - @wagmi/core@2.16.4 + +## 2.14.10 + +### Patch Changes + +- Updated dependencies [[`639952c97f0fe3927106f42d3c9f7f366cdf7f7a`](https://github.com/wevm/wagmi/commit/639952c97f0fe3927106f42d3c9f7f366cdf7f7a), [`5aa2c095f7bfb6dfcf91c6945c3e1f9c9dd05766`](https://github.com/wevm/wagmi/commit/5aa2c095f7bfb6dfcf91c6945c3e1f9c9dd05766)]: + - @wagmi/connectors@5.7.6 + +## 2.14.9 + +### Patch Changes + +- Updated dependencies [[`a257e8d4f97431a4af872cda1817b4ae17c7bbed`](https://github.com/wevm/wagmi/commit/a257e8d4f97431a4af872cda1817b4ae17c7bbed)]: + - @wagmi/connectors@5.7.5 + +## 2.14.8 + +### Patch Changes + +- Updated dependencies [[`c8a257e0f6d2ece013b873895c35769a8a804fdc`](https://github.com/wevm/wagmi/commit/c8a257e0f6d2ece013b873895c35769a8a804fdc)]: + - @wagmi/connectors@5.7.4 + +## 2.14.7 + +### Patch Changes + +- [#4497](https://github.com/wevm/wagmi/pull/4497) [`00c144b21bac3f0797b683d8a4a81f7399c6e042`](https://github.com/wevm/wagmi/commit/00c144b21bac3f0797b683d8a4a81f7399c6e042) Thanks [@tmm](https://github.com/tmm)! - Bumped `use-sync-external-store` version for React 19. + +## 2.14.6 + +### Patch Changes + +- [#4480](https://github.com/wevm/wagmi/pull/4480) [`384a1d91597622eb59e1c05dc13ce25017c5b6d8`](https://github.com/wevm/wagmi/commit/384a1d91597622eb59e1c05dc13ce25017c5b6d8) Thanks [@RodeRickIsWatching](https://github.com/RodeRickIsWatching)! - Fixed invocation of default storage. + +- Updated dependencies [[`384a1d91597622eb59e1c05dc13ce25017c5b6d8`](https://github.com/wevm/wagmi/commit/384a1d91597622eb59e1c05dc13ce25017c5b6d8)]: + - @wagmi/core@2.16.3 + - @wagmi/connectors@5.7.3 + +## 2.14.5 + +### Patch Changes + +- [`012907032b532a438fce48f407470250cbc8f0c6`](https://github.com/wevm/wagmi/commit/012907032b532a438fce48f407470250cbc8f0c6) Thanks [@jxom](https://github.com/jxom)! - Fixed assignment in `getDefaultStorage`. + +- Updated dependencies [[`012907032b532a438fce48f407470250cbc8f0c6`](https://github.com/wevm/wagmi/commit/012907032b532a438fce48f407470250cbc8f0c6)]: + - @wagmi/core@2.16.2 + - @wagmi/connectors@5.7.2 + +## 2.14.4 + +### Patch Changes + +- Updated dependencies [[`9c8c35a3b829f2c58edcd3a29e2dcd99974d7470`](https://github.com/wevm/wagmi/commit/9c8c35a3b829f2c58edcd3a29e2dcd99974d7470), [`3892ebd21c06beef4b28ece4e70d2a38807bce6f`](https://github.com/wevm/wagmi/commit/3892ebd21c06beef4b28ece4e70d2a38807bce6f)]: + - @wagmi/connectors@5.7.1 + - @wagmi/core@2.16.1 + +## 2.14.3 + +### Patch Changes + +- Updated dependencies [[`e3f63a02c1f7d80481804584f262bc98dab0400d`](https://github.com/wevm/wagmi/commit/e3f63a02c1f7d80481804584f262bc98dab0400d)]: + - @wagmi/connectors@5.7.0 + +## 2.14.2 + +### Patch Changes + +- Updated dependencies [[`adf2253b10c6d4fc583e4bc9f01a8ef5ca267c85`](https://github.com/wevm/wagmi/commit/adf2253b10c6d4fc583e4bc9f01a8ef5ca267c85)]: + - @wagmi/connectors@5.6.2 + +## 2.14.1 + +### Patch Changes + +- Updated dependencies [[`987404f590c1d29ebb3cb68928f5e54aa032793d`](https://github.com/wevm/wagmi/commit/987404f590c1d29ebb3cb68928f5e54aa032793d)]: + - @wagmi/connectors@5.6.1 + +## 2.14.0 + +### Minor Changes + +- [#4453](https://github.com/wevm/wagmi/pull/4453) [`070e48480194c8d7f45bda1d7dd1346e6f5d7227`](https://github.com/wevm/wagmi/commit/070e48480194c8d7f45bda1d7dd1346e6f5d7227) Thanks [@tmm](https://github.com/tmm)! - Added support to `useConnect` for custom `connector.connect` parameters. + +### Patch Changes + +- Updated dependencies [[`afea6b67822a7a2b96901ec851441d27ee0f7a52`](https://github.com/wevm/wagmi/commit/afea6b67822a7a2b96901ec851441d27ee0f7a52), [`070e48480194c8d7f45bda1d7dd1346e6f5d7227`](https://github.com/wevm/wagmi/commit/070e48480194c8d7f45bda1d7dd1346e6f5d7227), [`8b0726c1106fce88b782e676498eabf0718b2619`](https://github.com/wevm/wagmi/commit/8b0726c1106fce88b782e676498eabf0718b2619)]: + - @wagmi/connectors@5.6.0 + - @wagmi/core@2.16.0 + +## 2.13.5 + +### Patch Changes + +- [#4447](https://github.com/wevm/wagmi/pull/4447) [`244f7777d9d227b3134d4cb9b9dda64f50cbddd3`](https://github.com/wevm/wagmi/commit/244f7777d9d227b3134d4cb9b9dda64f50cbddd3) Thanks [@Aerilym](https://github.com/Aerilym)! - Fixed config parameter passing in useSimulateContract and useEstimateGas + +## 2.13.4 + +### Patch Changes + +- [`2f79a3da4872d6158569017b1927a07a1ff5e7ba`](https://github.com/wevm/wagmi/commit/2f79a3da4872d6158569017b1927a07a1ff5e7ba) Thanks [@tmm](https://github.com/tmm)! - Exported `injected` and `mock`. + +## 2.13.3 + +### Patch Changes + +- [#4433](https://github.com/wevm/wagmi/pull/4433) [`06e186cd679b27fe195309110e766fcf46d4efbc`](https://github.com/wevm/wagmi/commit/06e186cd679b27fe195309110e766fcf46d4efbc) Thanks [@Aerilym](https://github.com/Aerilym)! - Bumped Metamask SDK version to `0.31.1`. + +- Updated dependencies [[`06e186cd679b27fe195309110e766fcf46d4efbc`](https://github.com/wevm/wagmi/commit/06e186cd679b27fe195309110e766fcf46d4efbc)]: + - @wagmi/connectors@5.5.3 + - @wagmi/core@2.15.2 + +## 2.13.2 + +### Patch Changes + +- Updated dependencies [[`e563ef69130a511fd6f3f72ed4cd4fbe1390541f`](https://github.com/wevm/wagmi/commit/e563ef69130a511fd6f3f72ed4cd4fbe1390541f)]: + - @wagmi/connectors@5.5.2 + +## 2.13.1 + +### Patch Changes + +- [`b8bbb409f4934538e3dd6cac5aaf7346292d0693`](https://github.com/wevm/wagmi/commit/b8bbb409f4934538e3dd6cac5aaf7346292d0693) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where `null` gas would accidentally pass through. + +- Updated dependencies [[`b8bbb409f4934538e3dd6cac5aaf7346292d0693`](https://github.com/wevm/wagmi/commit/b8bbb409f4934538e3dd6cac5aaf7346292d0693)]: + - @wagmi/core@2.15.1 + - @wagmi/connectors@5.5.1 + +## 2.13.0 + +### Minor Changes + +- [#4417](https://github.com/wevm/wagmi/pull/4417) [`42e65ea4fea99c639817088bba915e0933d17141`](https://github.com/wevm/wagmi/commit/42e65ea4fea99c639817088bba915e0933d17141) Thanks [@jxom](https://github.com/jxom)! - Removed simulation in `writeContract` & `sendTransaction`. + +### Patch Changes + +- Updated dependencies [[`42e65ea4fea99c639817088bba915e0933d17141`](https://github.com/wevm/wagmi/commit/42e65ea4fea99c639817088bba915e0933d17141)]: + - @wagmi/connectors@6.0.0 + - @wagmi/core@2.15.0 + +## 2.12.33 + +### Patch Changes + +- Updated dependencies [[`7ca62b44cd997d48f92c2b81343726a5908aa00b`](https://github.com/wevm/wagmi/commit/7ca62b44cd997d48f92c2b81343726a5908aa00b)]: + - @wagmi/connectors@5.4.0 + +## 2.12.32 + +### Patch Changes + +- Updated dependencies [[`a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3`](https://github.com/wevm/wagmi/commit/a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3), [`a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3`](https://github.com/wevm/wagmi/commit/a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3)]: + - @wagmi/core@2.14.6 + - @wagmi/connectors@5.3.10 + +## 2.12.31 + +### Patch Changes + +- Updated dependencies [[`b12a04eeec985c48d2feac94b011d41fb29ca23e`](https://github.com/wevm/wagmi/commit/b12a04eeec985c48d2feac94b011d41fb29ca23e)]: + - @wagmi/connectors@5.3.9 + +## 2.12.30 + +### Patch Changes + +- Updated dependencies [[`6b9bbacdc7bffd44fc2165362a5e65fd434e7646`](https://github.com/wevm/wagmi/commit/6b9bbacdc7bffd44fc2165362a5e65fd434e7646), [`dac62dc99a0679fa632a0fae49873d6053d06b35`](https://github.com/wevm/wagmi/commit/dac62dc99a0679fa632a0fae49873d6053d06b35)]: + - @wagmi/core@2.14.5 + - @wagmi/connectors@5.3.8 + +## 2.12.29 + +### Patch Changes + +- Updated dependencies [[`e08681c81fbdf475213e2d0f4c5517d0abf4e743`](https://github.com/wevm/wagmi/commit/e08681c81fbdf475213e2d0f4c5517d0abf4e743)]: + - @wagmi/core@2.14.4 + - @wagmi/connectors@5.3.7 + +## 2.12.28 + +### Patch Changes + +- Updated dependencies [[`7558ff3133c11bc4c49473d08ee9a47eaa12df5b`](https://github.com/wevm/wagmi/commit/7558ff3133c11bc4c49473d08ee9a47eaa12df5b)]: + - @wagmi/connectors@5.3.6 + +## 2.12.27 + +### Patch Changes + +- Updated dependencies [[`cb7dd2ebb871d0be8f1a11a8cd8ce592cd74b7c7`](https://github.com/wevm/wagmi/commit/cb7dd2ebb871d0be8f1a11a8cd8ce592cd74b7c7), [`7fe78f2d09778fc01fd0cffe85ba198e64999275`](https://github.com/wevm/wagmi/commit/7fe78f2d09778fc01fd0cffe85ba198e64999275)]: + - @wagmi/core@2.14.3 + - @wagmi/connectors@5.3.5 + +## 2.12.26 + +### Patch Changes + +- Updated dependencies [[`b6861a4c378dab78d8751ae0ac2aa425f3c24b8f`](https://github.com/wevm/wagmi/commit/b6861a4c378dab78d8751ae0ac2aa425f3c24b8f), [`d0d0963bb5904a15cf0355862d62dd141ce0c31c`](https://github.com/wevm/wagmi/commit/d0d0963bb5904a15cf0355862d62dd141ce0c31c), [`ecac0ba36243d94c9199d0bd21937104c835d9a0`](https://github.com/wevm/wagmi/commit/ecac0ba36243d94c9199d0bd21937104c835d9a0)]: + - @wagmi/connectors@5.3.4 + - @wagmi/core@2.14.2 + +## 2.12.25 + +### Patch Changes + +- Updated dependencies [[`83c6d16b7d6dddfa6bda036e04f00ec313c6248c`](https://github.com/wevm/wagmi/commit/83c6d16b7d6dddfa6bda036e04f00ec313c6248c)]: + - @wagmi/connectors@5.3.3 + +## 2.12.24 + +### Patch Changes + +- [`a4c5389c1a299bd7acf9df4a0d607e2ced709280`](https://github.com/wevm/wagmi/commit/a4c5389c1a299bd7acf9df4a0d607e2ced709280) Thanks [@jxom](https://github.com/jxom)! - Exported `Transport` type (for inference). + +## 2.12.23 + +### Patch Changes + +- Updated dependencies [[`8970cc51398e1ac713435533096215c6d31ffdf9`](https://github.com/wevm/wagmi/commit/8970cc51398e1ac713435533096215c6d31ffdf9)]: + - @wagmi/connectors@5.3.2 + +## 2.12.22 + +### Patch Changes + +- Updated dependencies [[`052e72e1f8c1c14fcbdce04a9f8fa7ec28d83702`](https://github.com/wevm/wagmi/commit/052e72e1f8c1c14fcbdce04a9f8fa7ec28d83702), [`b250fc21ee577b2a75c5a34ff684f62fb4ad771a`](https://github.com/wevm/wagmi/commit/b250fc21ee577b2a75c5a34ff684f62fb4ad771a)]: + - @wagmi/core@2.14.1 + - @wagmi/connectors@5.3.1 + +## 2.12.21 + +### Patch Changes + +- Updated dependencies [[`f43e074f473820b208a6295d7c97f847332f1a1d`](https://github.com/wevm/wagmi/commit/f43e074f473820b208a6295d7c97f847332f1a1d)]: + - @wagmi/connectors@6.0.0 + - @wagmi/core@2.14.0 + +## 2.12.20 + +### Patch Changes + +- Updated dependencies [[`c05caabc20c3ced9682cfc7ba1f3f7dcfece0703`](https://github.com/wevm/wagmi/commit/c05caabc20c3ced9682cfc7ba1f3f7dcfece0703), [`5ae49af590ff168426c9c283d54c34ae5148fcd9`](https://github.com/wevm/wagmi/commit/5ae49af590ff168426c9c283d54c34ae5148fcd9), [`f3182b22e6e454d9bd74f1b940ef34431fd9555d`](https://github.com/wevm/wagmi/commit/f3182b22e6e454d9bd74f1b940ef34431fd9555d)]: + - @wagmi/core@2.13.9 + - @wagmi/connectors@5.2.2 + +## 2.12.19 + +### Patch Changes + +- Updated dependencies [[`91a40f2db08e3a91db421b8732a5511a1e6c88fd`](https://github.com/wevm/wagmi/commit/91a40f2db08e3a91db421b8732a5511a1e6c88fd)]: + - @wagmi/connectors@5.2.1 + +## 2.12.18 + +### Patch Changes + +- Updated dependencies [[`34a0c3b7eea778aee7c27f7ace5e4b2be4e8a0a4`](https://github.com/wevm/wagmi/commit/34a0c3b7eea778aee7c27f7ace5e4b2be4e8a0a4)]: + - @wagmi/connectors@5.2.0 + +## 2.12.17 + +### Patch Changes + +- Updated dependencies [[`3b2123664b7ac66848390739e855c3b9702ab60c`](https://github.com/wevm/wagmi/commit/3b2123664b7ac66848390739e855c3b9702ab60c)]: + - @wagmi/connectors@5.1.15 + +## 2.12.16 + +### Patch Changes + +- Updated dependencies [[`56f2482508f2ba71bd6b0295c70c6abca7101e57`](https://github.com/wevm/wagmi/commit/56f2482508f2ba71bd6b0295c70c6abca7101e57)]: + - @wagmi/connectors@5.1.14 + - @wagmi/core@2.13.8 + +## 2.12.15 + +### Patch Changes + +- [#4229](https://github.com/wevm/wagmi/pull/4229) [`c6b8efd26254c8e692b2b67286ed538fc183b992`](https://github.com/wevm/wagmi/commit/c6b8efd26254c8e692b2b67286ed538fc183b992) Thanks [@weilliao05621](https://github.com/weilliao05621)! - Stabilized `useAccount` return type object reference. + +## 2.12.14 + +### Patch Changes + +- Updated dependencies [[`be75c2d4ef636d7362420ab0a106bfdf63f5d1e6`](https://github.com/wevm/wagmi/commit/be75c2d4ef636d7362420ab0a106bfdf63f5d1e6)]: + - @wagmi/core@2.13.7 + - @wagmi/connectors@5.1.13 + +## 2.12.13 + +### Patch Changes + +- Updated dependencies [[`edcbf5d6fbe92f639bead800502edda9e0aa39f1`](https://github.com/wevm/wagmi/commit/edcbf5d6fbe92f639bead800502edda9e0aa39f1)]: + - @wagmi/core@2.13.6 + - @wagmi/connectors@5.1.12 + +## 2.12.12 + +### Patch Changes + +- Updated dependencies [[`82404c960e04c83e0bae6e1e12459ef9debf9554`](https://github.com/wevm/wagmi/commit/82404c960e04c83e0bae6e1e12459ef9debf9554), [`d07ad7f63a018256908a673d078aaf79e47ac703`](https://github.com/wevm/wagmi/commit/d07ad7f63a018256908a673d078aaf79e47ac703)]: + - @wagmi/connectors@5.1.11 + +## 2.12.11 + +### Patch Changes + +- [#4262](https://github.com/wevm/wagmi/pull/4262) [`8531f83db3a1fbb8202c3e426b7f85679f587a52`](https://github.com/wevm/wagmi/commit/8531f83db3a1fbb8202c3e426b7f85679f587a52) Thanks [@nezouse](https://github.com/nezouse)! - Added experimental actions entrypoint. + +## 2.12.10 + +### Patch Changes + +- [#4260](https://github.com/wevm/wagmi/pull/4260) [`969a208a110b760a13fd7263360320f52440a9b6`](https://github.com/wevm/wagmi/commit/969a208a110b760a13fd7263360320f52440a9b6) Thanks [@tmm](https://github.com/tmm)! - Fixed `useReadContract` deployless reads support. + +- [#4259](https://github.com/wevm/wagmi/pull/4259) [`f47ce8f6d263e49fdff90b8edb3190142d2657bb`](https://github.com/wevm/wagmi/commit/f47ce8f6d263e49fdff90b8edb3190142d2657bb) Thanks [@tmm](https://github.com/tmm)! - Disabled `useConnectorClient` and `useWalletClient` during reconnection if connector is not fully restored. + +- Updated dependencies [[`81de006e66121a18c61945c1f9b8426c83a5713c`](https://github.com/wevm/wagmi/commit/81de006e66121a18c61945c1f9b8426c83a5713c), [`f47ce8f6d263e49fdff90b8edb3190142d2657bb`](https://github.com/wevm/wagmi/commit/f47ce8f6d263e49fdff90b8edb3190142d2657bb)]: + - @wagmi/connectors@5.1.10 + - @wagmi/core@2.13.5 + +## 2.12.9 + +### Patch Changes + +- Updated dependencies [[`21bd0e473d374cbbd7a01bececa6022d529026ba`](https://github.com/wevm/wagmi/commit/21bd0e473d374cbbd7a01bececa6022d529026ba), [`5c89c6853e616437a3be2b019db895451fecfb3c`](https://github.com/wevm/wagmi/commit/5c89c6853e616437a3be2b019db895451fecfb3c)]: + - @wagmi/connectors@5.1.9 + +## 2.12.8 + +### Patch Changes + +- Updated dependencies [[`b580ad4edff1721e0b9d138cf5ae2ec74d2374c7`](https://github.com/wevm/wagmi/commit/b580ad4edff1721e0b9d138cf5ae2ec74d2374c7)]: + - @wagmi/connectors@5.1.8 + +## 2.12.7 + +### Patch Changes + +- Updated dependencies [[`91fd81a068789c5020e891f539bcad8f54a7a52f`](https://github.com/wevm/wagmi/commit/91fd81a068789c5020e891f539bcad8f54a7a52f)]: + - @wagmi/connectors@5.1.7 + +## 2.12.6 + +### Patch Changes + +- Updated dependencies [[`3168616298cbb6135d0ffda771cba4126e83eba8`](https://github.com/wevm/wagmi/commit/3168616298cbb6135d0ffda771cba4126e83eba8), [`d7608ef9a79459465dc8c06a2ab740465c881907`](https://github.com/wevm/wagmi/commit/d7608ef9a79459465dc8c06a2ab740465c881907)]: + - @wagmi/connectors@5.1.6 + +## 2.12.5 + +### Patch Changes + +- Updated dependencies [[`b4c8971788c70b09479946ecfa998cff2f1b3953`](https://github.com/wevm/wagmi/commit/b4c8971788c70b09479946ecfa998cff2f1b3953)]: + - @wagmi/core@2.13.4 + - @wagmi/connectors@5.1.5 + +## 2.12.4 + +### Patch Changes + +- Updated dependencies [[`871dbdbfe59ac8ad01d1ec6150ea7b091b7b7de4`](https://github.com/wevm/wagmi/commit/871dbdbfe59ac8ad01d1ec6150ea7b091b7b7de4)]: + - @wagmi/core@2.13.3 + - @wagmi/connectors@5.1.4 + +## 2.12.3 + +### Patch Changes + +- Updated dependencies [[`1b9b523fa9b9dfe839aecdf4b40caa9547d7e594`](https://github.com/wevm/wagmi/commit/1b9b523fa9b9dfe839aecdf4b40caa9547d7e594)]: + - @wagmi/core@2.13.2 + - @wagmi/connectors@5.1.3 + +## 2.12.2 + +### Patch Changes + +- Updated dependencies [[`abb490dac4f0f02f46cb0878e7ca9a0db6aada56`](https://github.com/wevm/wagmi/commit/abb490dac4f0f02f46cb0878e7ca9a0db6aada56), [`28e0e5c9a4f856583f9d36a807502bd51a0c6ec2`](https://github.com/wevm/wagmi/commit/28e0e5c9a4f856583f9d36a807502bd51a0c6ec2)]: + - @wagmi/connectors@5.1.2 + +## 2.12.1 + +### Patch Changes + +- Updated dependencies [[`07c1227f306d0efb9421d4bb77a774f92f5fcf45`](https://github.com/wevm/wagmi/commit/07c1227f306d0efb9421d4bb77a774f92f5fcf45)]: + - @wagmi/core@2.13.1 + - @wagmi/connectors@5.1.1 + +## 2.12.0 + +### Minor Changes + +- [#4162](https://github.com/wevm/wagmi/pull/4162) [`a73a7737b756886b388f120ae423e72cca53e8a0`](https://github.com/wevm/wagmi/commit/a73a7737b756886b388f120ae423e72cca53e8a0) Thanks [@jxom](https://github.com/jxom)! - Added functionality for consumer-defined RPC URLs (`config.transports`) to be propagated to the WalletConnect & MetaMask Connectors. + +### Patch Changes + +- Updated dependencies [[`a73a7737b756886b388f120ae423e72cca53e8a0`](https://github.com/wevm/wagmi/commit/a73a7737b756886b388f120ae423e72cca53e8a0)]: + - @wagmi/connectors@6.0.0 + - @wagmi/core@2.13.0 + +## 2.11.3 + +### Patch Changes + +- [#4124](https://github.com/wevm/wagmi/pull/4124) [`26616462db2e0140025f22c505c4541cfecb9308`](https://github.com/wevm/wagmi/commit/26616462db2e0140025f22c505c4541cfecb9308) Thanks [@t0rbik](https://github.com/t0rbik)! - Updated `useConnectorClient` to be enabled when status is `'reconnecting'` or `'connected'` (previously was also enabled when status was `'connecting'`). + +## 2.11.2 + +### Patch Changes + +- Updated dependencies [[`5bc8c8877810b2eec24a829df87dce40a51e6f20`](https://github.com/wevm/wagmi/commit/5bc8c8877810b2eec24a829df87dce40a51e6f20), [`8d81df5cc884d0a210dedd3c1ea0e2e9e52b83c5`](https://github.com/wevm/wagmi/commit/8d81df5cc884d0a210dedd3c1ea0e2e9e52b83c5)]: + - @wagmi/core@2.12.2 + - @wagmi/connectors@5.0.26 + +## 2.11.1 + +### Patch Changes + +- [#4146](https://github.com/wevm/wagmi/pull/4146) [`cc996e08e930c9e88cf753a1e874652059e81a3b`](https://github.com/wevm/wagmi/commit/cc996e08e930c9e88cf753a1e874652059e81a3b) Thanks [@jxom](https://github.com/jxom)! - Updated `@safe-global/safe-apps-sdk` + `@safe-global/safe-apps-provider` dependencies. + +- Updated dependencies [[`cc996e08e930c9e88cf753a1e874652059e81a3b`](https://github.com/wevm/wagmi/commit/cc996e08e930c9e88cf753a1e874652059e81a3b)]: + - @wagmi/connectors@5.0.25 + - @wagmi/core@2.12.1 + +## 2.11.0 + +### Minor Changes + +- [#4128](https://github.com/wevm/wagmi/pull/4128) [`5581a810ef70308e99c6f8b630cd4bca59f64afc`](https://github.com/wevm/wagmi/commit/5581a810ef70308e99c6f8b630cd4bca59f64afc) Thanks [@dalechyn](https://github.com/dalechyn)! - Added `useWatchAsset` hook. + +### Patch Changes + +- Updated dependencies [[`5581a810ef70308e99c6f8b630cd4bca59f64afc`](https://github.com/wevm/wagmi/commit/5581a810ef70308e99c6f8b630cd4bca59f64afc)]: + - @wagmi/core@2.12.0 + - @wagmi/connectors@6.0.0 + +## 2.10.11 + +### Patch Changes + +- [`d3814ab4b88f9f0e052b53bc3d458df87b43f01d`](https://github.com/wevm/wagmi/commit/d3814ab4b88f9f0e052b53bc3d458df87b43f01d) Thanks [@jxom](https://github.com/jxom)! - Updated `mipd` dependency. + +- Updated dependencies [[`b08013eaa9ce97c02f8a7128ea400e3da7ef74bb`](https://github.com/wevm/wagmi/commit/b08013eaa9ce97c02f8a7128ea400e3da7ef74bb), [`d3814ab4b88f9f0e052b53bc3d458df87b43f01d`](https://github.com/wevm/wagmi/commit/d3814ab4b88f9f0e052b53bc3d458df87b43f01d)]: + - @wagmi/core@2.11.8 + - @wagmi/connectors@5.0.23 + +## 2.10.10 + +### Patch Changes + +- Updated dependencies [[`0bb8b562ae04ecfeb2d6b2f1b980ebae31dc127e`](https://github.com/wevm/wagmi/commit/0bb8b562ae04ecfeb2d6b2f1b980ebae31dc127e)]: + - @wagmi/connectors@5.0.22 + - @wagmi/core@2.11.7 + +## 2.10.9 + +### Patch Changes + +- [#4060](https://github.com/wevm/wagmi/pull/4060) [`95965c1f19d480b97f2b297a077a9e607dee32ad`](https://github.com/wevm/wagmi/commit/95965c1f19d480b97f2b297a077a9e607dee32ad) Thanks [@dalechyn](https://github.com/dalechyn)! - Bumped Tanstack Query dependencies to fix typing issues between exported Wagmi query options and TanStack Query suspense query methods (due to [`direction` property in `QueryFunctionContext` being deprecated](https://github.com/TanStack/query/pull/7410)). + +- Updated dependencies [[`ff0760b5900114bcfdf420a9fba3cc278ac95afe`](https://github.com/wevm/wagmi/commit/ff0760b5900114bcfdf420a9fba3cc278ac95afe), [`95965c1f19d480b97f2b297a077a9e607dee32ad`](https://github.com/wevm/wagmi/commit/95965c1f19d480b97f2b297a077a9e607dee32ad)]: + - @wagmi/connectors@5.0.21 + - @wagmi/core@2.11.6 + +## 2.10.8 + +### Patch Changes + +- Updated dependencies [[`43fa971d34cac57fa5a2898ad4d839b95d7af37c`](https://github.com/wevm/wagmi/commit/43fa971d34cac57fa5a2898ad4d839b95d7af37c)]: + - @wagmi/connectors@5.0.20 + +## 2.10.7 + +### Patch Changes + +- Updated dependencies [[`b7ad208030d9f2e3f89912ff76b16cdbd848feda`](https://github.com/wevm/wagmi/commit/b7ad208030d9f2e3f89912ff76b16cdbd848feda)]: + - @wagmi/connectors@5.0.19 + +## 2.10.6 + +### Patch Changes + +- Updated dependencies [[`44d24620c9e3957f3245d14d6a042736371df70b`](https://github.com/wevm/wagmi/commit/44d24620c9e3957f3245d14d6a042736371df70b)]: + - @wagmi/connectors@5.0.18 + +## 2.10.5 + +### Patch Changes + +- Updated dependencies [[`04f2b846b113f3d300d82c9fa75212f1805817c5`](https://github.com/wevm/wagmi/commit/04f2b846b113f3d300d82c9fa75212f1805817c5)]: + - @wagmi/core@2.11.5 + - @wagmi/connectors@5.0.17 + +## 2.10.4 + +### Patch Changes + +- Updated dependencies [[`9e8345cd56186b997b5e56deaa2cfc69b30d15f6`](https://github.com/wevm/wagmi/commit/9e8345cd56186b997b5e56deaa2cfc69b30d15f6), [`02c38c28d1aa0ad7a61c33775de603ed974c5c1b`](https://github.com/wevm/wagmi/commit/02c38c28d1aa0ad7a61c33775de603ed974c5c1b)]: + - @wagmi/core@2.11.4 + - @wagmi/connectors@5.0.16 + +## 2.10.3 + +### Patch Changes + +- Updated dependencies [[`8974e6269bb5d7bfaa90db0246bc7d13e8bff798`](https://github.com/wevm/wagmi/commit/8974e6269bb5d7bfaa90db0246bc7d13e8bff798)]: + - @wagmi/core@2.11.3 + - @wagmi/connectors@5.0.15 + +## 2.10.2 + +### Patch Changes + +- Updated dependencies [[`b4d9ef79deb554ee20fed6666a474be5e7cdd522`](https://github.com/wevm/wagmi/commit/b4d9ef79deb554ee20fed6666a474be5e7cdd522)]: + - @wagmi/core@2.11.2 + - @wagmi/connectors@5.0.14 + +## 2.10.1 + +### Patch Changes + +- Updated dependencies [[`9c862d8d63e3d692a22cef2a90782b74a9103f17`](https://github.com/wevm/wagmi/commit/9c862d8d63e3d692a22cef2a90782b74a9103f17)]: + - @wagmi/connectors@5.0.13 + - @wagmi/core@2.11.1 + +## 2.10.0 + +### Minor Changes + +- [#3816](https://github.com/wevm/wagmi/pull/3816) [`06bb598a7f04c7b167f5b7ff6d46bd15886a6a14`](https://github.com/wevm/wagmi/commit/06bb598a7f04c7b167f5b7ff6d46bd15886a6a14) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `useDeployContract` hook. + +### Patch Changes + +- Updated dependencies [[`06bb598a7f04c7b167f5b7ff6d46bd15886a6a14`](https://github.com/wevm/wagmi/commit/06bb598a7f04c7b167f5b7ff6d46bd15886a6a14), [`24a45b269bd0214a29d6f82a84ac66ef8c3f3822`](https://github.com/wevm/wagmi/commit/24a45b269bd0214a29d6f82a84ac66ef8c3f3822)]: + - @wagmi/core@2.11.0 + - @wagmi/connectors@6.0.0 + +## 2.9.12 + +### Patch Changes + +- Updated dependencies [[`f2a7cefab96691ebed8b8e45ffde071c47b58dbe`](https://github.com/wevm/wagmi/commit/f2a7cefab96691ebed8b8e45ffde071c47b58dbe), [`f0ea0b2a7fe193dadfeb49a4c8031ee451c638b5`](https://github.com/wevm/wagmi/commit/f0ea0b2a7fe193dadfeb49a4c8031ee451c638b5), [`e3b124ce414b8fd1b2214e2c5a28dc72158a13d1`](https://github.com/wevm/wagmi/commit/e3b124ce414b8fd1b2214e2c5a28dc72158a13d1)]: + - @wagmi/core@2.10.6 + - @wagmi/connectors@5.0.11 + +## 2.9.11 + +### Patch Changes + +- Updated dependencies [[`560952acd4bfe33db6c7c07b35c613cef278677c`](https://github.com/wevm/wagmi/commit/560952acd4bfe33db6c7c07b35c613cef278677c)]: + - @wagmi/connectors@5.0.10 + +## 2.9.10 + +### Patch Changes + +- Updated dependencies [[`32cdd7b7dc5aff916c040628519562c3a99d418d`](https://github.com/wevm/wagmi/commit/32cdd7b7dc5aff916c040628519562c3a99d418d)]: + - @wagmi/connectors@5.0.9 + +## 2.9.9 + +### Patch Changes + +- Updated dependencies [[`c1952d1ff7f0a491dc88595a49159451b07b5621`](https://github.com/wevm/wagmi/commit/c1952d1ff7f0a491dc88595a49159451b07b5621)]: + - @wagmi/connectors@5.0.8 + +## 2.9.8 + +### Patch Changes + +- Updated dependencies [[`030c7c2cb380dfd67a2182f62e2aa7a6e1601898`](https://github.com/wevm/wagmi/commit/030c7c2cb380dfd67a2182f62e2aa7a6e1601898)]: + - @wagmi/core@2.10.5 + - @wagmi/connectors@5.0.7 + +## 2.9.7 + +### Patch Changes + +- Updated dependencies [[`51fde8a0433b4fff357c1a8d7e08b41b4c86c968`](https://github.com/wevm/wagmi/commit/51fde8a0433b4fff357c1a8d7e08b41b4c86c968)]: + - @wagmi/core@2.10.4 + - @wagmi/connectors@5.0.6 + +## 2.9.6 + +### Patch Changes + +- Updated dependencies [[`70dd28669dd8d2ce08217cd02e29a8fbba7a08d4`](https://github.com/wevm/wagmi/commit/70dd28669dd8d2ce08217cd02e29a8fbba7a08d4)]: + - @wagmi/connectors@5.0.5 + +## 2.9.5 + +### Patch Changes + +- Updated dependencies [[`be9e1b8a9818b92eb0654a20d9471e9e39329e7e`](https://github.com/wevm/wagmi/commit/be9e1b8a9818b92eb0654a20d9471e9e39329e7e)]: + - @wagmi/connectors@5.0.4 + +## 2.9.4 + +### Patch Changes + +- Updated dependencies [[`2804a8a583b1874271154898b4bae38756ef581c`](https://github.com/wevm/wagmi/commit/2804a8a583b1874271154898b4bae38756ef581c), [`2804a8a583b1874271154898b4bae38756ef581c`](https://github.com/wevm/wagmi/commit/2804a8a583b1874271154898b4bae38756ef581c)]: + - @wagmi/connectors@5.0.3 + - @wagmi/core@2.10.3 + +## 2.9.3 + +### Patch Changes + +- [`ec2f63f106fd468f28b43d3b88ab3e89aaf5e81a`](https://github.com/wevm/wagmi/commit/ec2f63f106fd468f28b43d3b88ab3e89aaf5e81a) Thanks [@tmm](https://github.com/tmm)! - Fixed `useSwitchChain` `chains` typing. + +## 2.9.2 + +### Patch Changes + +- [#3940](https://github.com/wevm/wagmi/pull/3940) [`a5071f581dfdfb961718873643a2fc629101c72a`](https://github.com/wevm/wagmi/commit/a5071f581dfdfb961718873643a2fc629101c72a) Thanks [@jxom](https://github.com/jxom)! - Fixed usage of `metaMask` connector in Vite environments. + +- Updated dependencies [[`a5071f581dfdfb961718873643a2fc629101c72a`](https://github.com/wevm/wagmi/commit/a5071f581dfdfb961718873643a2fc629101c72a)]: + - @wagmi/connectors@5.0.2 + - @wagmi/core@2.10.2 + +## 2.9.1 + +### Patch Changes + +- Bumped versions. + +- Updated dependencies []: + - @wagmi/connectors@5.0.1 + - @wagmi/core@2.10.1 + +## 2.9.0 + +### Minor Changes + +- [#3928](https://github.com/wevm/wagmi/pull/3928) [`3117e71825f9c58a0d718f3d1686f1a191fa9cb1`](https://github.com/wevm/wagmi/commit/3117e71825f9c58a0d718f3d1686f1a191fa9cb1) Thanks [@tmm](https://github.com/tmm)! - Updated the default Coinbase SDK in `coinbaseWallet` Connector to v4.x. + +### Patch Changes + +- Updated dependencies [[`3117e71825f9c58a0d718f3d1686f1a191fa9cb1`](https://github.com/wevm/wagmi/commit/3117e71825f9c58a0d718f3d1686f1a191fa9cb1), [`3117e71825f9c58a0d718f3d1686f1a191fa9cb1`](https://github.com/wevm/wagmi/commit/3117e71825f9c58a0d718f3d1686f1a191fa9cb1)]: + - @wagmi/connectors@5.0.0 + - @wagmi/core@2.10.0 + +## 2.8.8 + +### Patch Changes + +- [#3906](https://github.com/wevm/wagmi/pull/3906) [`32fcb4a31dde6b0206961d8ffe9c651f8a459c67`](https://github.com/wevm/wagmi/commit/32fcb4a31dde6b0206961d8ffe9c651f8a459c67) Thanks [@tmm](https://github.com/tmm)! - Added support for Vue. + +- Updated dependencies [[`32fcb4a31dde6b0206961d8ffe9c651f8a459c67`](https://github.com/wevm/wagmi/commit/32fcb4a31dde6b0206961d8ffe9c651f8a459c67)]: + - @wagmi/connectors@4.3.10 + - @wagmi/core@2.9.8 + +## 2.8.7 + +### Patch Changes + +- [#3924](https://github.com/wevm/wagmi/pull/3924) [`1f58734f88458e0f6adb05c99f0c90f36ab286b8`](https://github.com/wevm/wagmi/commit/1f58734f88458e0f6adb05c99f0c90f36ab286b8) Thanks [@jxom](https://github.com/jxom)! - Refactored `isChainsStale` logic in `walletConnect` connector. + +- Updated dependencies [[`1f58734f88458e0f6adb05c99f0c90f36ab286b8`](https://github.com/wevm/wagmi/commit/1f58734f88458e0f6adb05c99f0c90f36ab286b8)]: + - @wagmi/connectors@4.3.9 + - @wagmi/core@2.9.7 + +## 2.8.6 + +### Patch Changes + +- [#3917](https://github.com/wevm/wagmi/pull/3917) [`05948fdad5bb4a56b08916d45b3dec2cb1e5f55b`](https://github.com/wevm/wagmi/commit/05948fdad5bb4a56b08916d45b3dec2cb1e5f55b) Thanks [@jxom](https://github.com/jxom)! - Updated `@metamask/sdk`. + +- Updated dependencies [[`05948fdad5bb4a56b08916d45b3dec2cb1e5f55b`](https://github.com/wevm/wagmi/commit/05948fdad5bb4a56b08916d45b3dec2cb1e5f55b)]: + - @wagmi/connectors@4.3.8 + - @wagmi/core@2.9.6 + +## 2.8.5 + +### Patch Changes + +- [`4fecbbb66d0aacd03b8c62a6455d11a33cde8f85`](https://github.com/wevm/wagmi/commit/4fecbbb66d0aacd03b8c62a6455d11a33cde8f85) Thanks [@jxom](https://github.com/jxom)! - Fixed address comparison in `getConnectorClient`. + +- Updated dependencies [[`4fecbbb66d0aacd03b8c62a6455d11a33cde8f85`](https://github.com/wevm/wagmi/commit/4fecbbb66d0aacd03b8c62a6455d11a33cde8f85)]: + - @wagmi/core@2.9.5 + - @wagmi/connectors@4.3.7 + +## 2.8.4 + +### Patch Changes + +- Updated dependencies [[`e6139a97c4b8804d734b1547b5e3921ce01fbe24`](https://github.com/wevm/wagmi/commit/e6139a97c4b8804d734b1547b5e3921ce01fbe24)]: + - @wagmi/core@2.9.4 + - @wagmi/connectors@4.3.6 + +## 2.8.3 + +### Patch Changes + +- [#3904](https://github.com/wevm/wagmi/pull/3904) [`addca28ebc20f1a4367c35fe9ef786decff9c87e`](https://github.com/wevm/wagmi/commit/addca28ebc20f1a4367c35fe9ef786decff9c87e) Thanks [@jxom](https://github.com/jxom)! - Updated `@walletconnect/ethereum-provider`. + +- Updated dependencies [[`addca28ebc20f1a4367c35fe9ef786decff9c87e`](https://github.com/wevm/wagmi/commit/addca28ebc20f1a4367c35fe9ef786decff9c87e)]: + - @wagmi/connectors@4.3.5 + - @wagmi/core@2.9.3 + +## 2.8.2 + +### Patch Changes + +- [#3902](https://github.com/wevm/wagmi/pull/3902) [`204b7b624612405500ec098fb9e35facd3f74ca4`](https://github.com/wevm/wagmi/commit/204b7b624612405500ec098fb9e35facd3f74ca4) Thanks [@jxom](https://github.com/jxom)! - Made third-party SDK imports type-only. + +- Updated dependencies [[`204b7b624612405500ec098fb9e35facd3f74ca4`](https://github.com/wevm/wagmi/commit/204b7b624612405500ec098fb9e35facd3f74ca4)]: + - @wagmi/connectors@4.3.4 + - @wagmi/core@2.9.2 + +## 2.8.1 + +### Patch Changes + +- [`cda6a5d5`](https://github.com/wevm/wagmi/commit/cda6a5d56328330fbde050b4ef40b01c58d2519a) Thanks [@jxom](https://github.com/jxom)! - Updated packages. + +- Updated dependencies [[`cda6a5d5`](https://github.com/wevm/wagmi/commit/cda6a5d56328330fbde050b4ef40b01c58d2519a)]: + - @wagmi/core@2.9.1 + - @wagmi/connectors@4.3.3 + +## 2.8.0 + +### Minor Changes + +- [#3878](https://github.com/wevm/wagmi/pull/3878) [`017828fc`](https://github.com/wevm/wagmi/commit/017828fc027c7a84b54ea9d627e9389f4d60d6c2) Thanks [@jxom](https://github.com/jxom)! - Added experimental EIP-5792 Actions & Hooks. + +### Patch Changes + +- Updated dependencies [[`017828fc`](https://github.com/wevm/wagmi/commit/017828fc027c7a84b54ea9d627e9389f4d60d6c2)]: + - @wagmi/core@2.9.0 + - @wagmi/connectors@4.3.2 + +## 2.7.1 + +### Patch Changes + +- [#3869](https://github.com/wevm/wagmi/pull/3869) [`d4a78eb0`](https://github.com/wevm/wagmi/commit/d4a78eb07119d2e5617e52481ac7d6c6d1583ddc) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where `prepareTransactionRequest` would internally call unsupported wallet RPC methods. + +- Updated dependencies [[`d4a78eb0`](https://github.com/wevm/wagmi/commit/d4a78eb07119d2e5617e52481ac7d6c6d1583ddc)]: + - @wagmi/core@2.8.1 + - @wagmi/connectors@4.3.1 + +## 2.7.0 + +### Minor Changes + +- [#3868](https://github.com/wevm/wagmi/pull/3868) [`c2af20b8`](https://github.com/wevm/wagmi/commit/c2af20b88cf16970d087faaec10b463357a5836e) Thanks [@jxom](https://github.com/jxom)! - Added `supportsSimulation` property to connectors that indicates if the connector's wallet supports contract simulation. + +### Patch Changes + +- [#3858](https://github.com/wevm/wagmi/pull/3858) [`0d141f17`](https://github.com/wevm/wagmi/commit/0d141f171d6ec44bcbfc9c876565b5e2fb8af6de) Thanks [@yulafezmesi](https://github.com/yulafezmesi)! - Fixed accessing reverted reason property inside `waitForTransactionReceipt`. + +- Updated dependencies [[`0d141f17`](https://github.com/wevm/wagmi/commit/0d141f171d6ec44bcbfc9c876565b5e2fb8af6de), [`c2af20b8`](https://github.com/wevm/wagmi/commit/c2af20b88cf16970d087faaec10b463357a5836e)]: + - @wagmi/core@2.8.0 + - @wagmi/connectors@5.0.0 + +## 2.6.0 + +### Minor Changes + +- [#3857](https://github.com/wevm/wagmi/pull/3857) [`d4274c03`](https://github.com/wevm/wagmi/commit/d4274c03a6af5f2d26d31432016ebc14950a330e) Thanks [@tmm](https://github.com/tmm)! - Added `addEthereumChainParameter` to `switchChain`-related methods. + +### Patch Changes + +- Updated dependencies [[`d4274c03`](https://github.com/wevm/wagmi/commit/d4274c03a6af5f2d26d31432016ebc14950a330e), [`4781a405`](https://github.com/wevm/wagmi/commit/4781a4056d4ffc2c74f96a75429e9b2cd2417ad8), [`400c960b`](https://github.com/wevm/wagmi/commit/400c960b30d701c134850c695ae903a382c29b5b)]: + - @wagmi/connectors@5.0.0 + - @wagmi/core@2.7.0 + +## 2.5.22 + +### Patch Changes + +- [`e3c832a1`](https://github.com/wevm/wagmi/commit/e3c832a12c301f9b0ee129d877b3101d220ba8b2) Thanks [@jxom](https://github.com/jxom)! - Fixed undefined `navigator` issue in MetaMask connector. + +- Updated dependencies [[`e3c832a1`](https://github.com/wevm/wagmi/commit/e3c832a12c301f9b0ee129d877b3101d220ba8b2)]: + - @wagmi/connectors@4.1.28 + - @wagmi/core@2.6.19 + +## 2.5.21 + +### Patch Changes + +- [#3848](https://github.com/wevm/wagmi/pull/3848) [`dd40a41c`](https://github.com/wevm/wagmi/commit/dd40a41c526ab60a288aff2250ed8dba92a27b16) Thanks [@jxom](https://github.com/jxom)! - Updated MetaMask SDK. + +- Updated dependencies [[`dd40a41c`](https://github.com/wevm/wagmi/commit/dd40a41c526ab60a288aff2250ed8dba92a27b16)]: + - @wagmi/connectors@4.1.27 + - @wagmi/core@2.6.18 + +## 2.5.20 + +### Patch Changes + +- [#3822](https://github.com/wevm/wagmi/pull/3822) [`a97bfbae`](https://github.com/wevm/wagmi/commit/a97bfbaeb615cfef04665e5e7348d85d17f960f0) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where Wagmi would not correctly rehydrate the active chain when a persisted store was being used. + +- Updated dependencies [[`a97bfbae`](https://github.com/wevm/wagmi/commit/a97bfbaeb615cfef04665e5e7348d85d17f960f0)]: + - @wagmi/core@2.6.17 + - @wagmi/connectors@4.1.26 + +## 2.5.19 + +### Patch Changes + +- [#3793](https://github.com/wevm/wagmi/pull/3793) [`f85b83ae`](https://github.com/wevm/wagmi/commit/f85b83ae95dd0bb73ffbdb49afa174e7c68298e1) Thanks [@tmm](https://github.com/tmm)! - Wired up `config` inside hooks so you can pass it explicitly and not use the `WagmiProvider`. + +- Updated dependencies [[`42ad380d`](https://github.com/wevm/wagmi/commit/42ad380d9a5d8bc0f61d73612142dea9d098de5e)]: + - @wagmi/connectors@4.1.25 + - @wagmi/core@2.6.16 + +## 2.5.18 + +### Patch Changes + +- Updated dependencies [[`b907d5ac`](https://github.com/wevm/wagmi/commit/b907d5ac3a746bcbccc06d1fe78c5bd8f9a7d685)]: + - @wagmi/core@2.6.15 + - @wagmi/connectors@4.1.24 + +## 2.5.17 + +### Patch Changes + +- [#3779](https://github.com/wevm/wagmi/pull/3779) [`3da20bb8`](https://github.com/wevm/wagmi/commit/3da20bb80e7c3efeef8227ced66ad615370fc242) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `eth_requestAccounts` would be called upon reconnect instead of `eth_accounts`. + +- [`a3d1858f`](https://github.com/wevm/wagmi/commit/a3d1858fce448d2b70e36ee692ef1589b74e9d3f) Thanks [@jxom](https://github.com/jxom)! - Fixed hydration conditional in `createConfig`. + +- Updated dependencies [[`b3b54ef1`](https://github.com/wevm/wagmi/commit/b3b54ef179c5fa0d1694d38d4b808549a0550409), [`3da20bb8`](https://github.com/wevm/wagmi/commit/3da20bb80e7c3efeef8227ced66ad615370fc242), [`a3d1858f`](https://github.com/wevm/wagmi/commit/a3d1858fce448d2b70e36ee692ef1589b74e9d3f)]: + - @wagmi/core@2.6.14 + - @wagmi/connectors@4.1.23 + +## 2.5.16 + +### Patch Changes + +- [`b80236dc`](https://github.com/wevm/wagmi/commit/b80236dc623095fe8f1e1d10957d7776fb6ab48b) Thanks [@jxom](https://github.com/jxom)! - Removed unneeded `uniqueBy` check on connectors state. + +- Updated dependencies [[`b80236dc`](https://github.com/wevm/wagmi/commit/b80236dc623095fe8f1e1d10957d7776fb6ab48b)]: + - @wagmi/core@2.6.13 + - @wagmi/connectors@4.1.22 + +## 2.5.15 + +### Patch Changes + +- [#3740](https://github.com/wevm/wagmi/pull/3740) [`3373c644`](https://github.com/wevm/wagmi/commit/3373c6444c38ef16532d18cfc351b3fe2bf2d351) Thanks [@BrickheadJohnny](https://github.com/BrickheadJohnny)! - Removed unnecessary re-renders from `useConnectorClient` and `useWalletClient`. + +- Updated dependencies [[`a59069e9`](https://github.com/wevm/wagmi/commit/a59069e9fab45dd606bb89a7f829fe94c51a5494), [`0acd3132`](https://github.com/wevm/wagmi/commit/0acd31320f534993af566be5490c2978b6184f66)]: + - @wagmi/core@2.6.12 + - @wagmi/connectors@4.1.21 + +## 2.5.14 + +### Patch Changes + +- [`e1ca4e63`](https://github.com/wevm/wagmi/commit/e1ca4e637ae6cec7f5902b0a2c0e0efc3b751a1d) Thanks [@tmm](https://github.com/tmm)! - Deprecated `normalizeChainId`. Use `Number` instead. + +- Updated dependencies [[`e1ca4e63`](https://github.com/wevm/wagmi/commit/e1ca4e637ae6cec7f5902b0a2c0e0efc3b751a1d)]: + - @wagmi/connectors@4.1.20 + - @wagmi/core@2.6.11 + +## 2.5.13 + +### Patch Changes + +- [`dbdca8fd`](https://github.com/wevm/wagmi/commit/dbdca8fd14b90c166222a66a373c1b33c06ce019) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where duplicate connectors could be instantiated if injected after page mount. + +- Updated dependencies [[`dbdca8fd`](https://github.com/wevm/wagmi/commit/dbdca8fd14b90c166222a66a373c1b33c06ce019)]: + - @wagmi/core@2.6.10 + - @wagmi/connectors@4.1.19 + +## 2.5.12 + +### Patch Changes + +- [#3612](https://github.com/wevm/wagmi/pull/3612) [`97237bb0`](https://github.com/wevm/wagmi/commit/97237bb05c30860b9b12c094e82a38ce59d9bedf) Thanks [@m1heng](https://github.com/m1heng)! - Added missing `functionName` parameter to `useWriteContract` codegen helper. + +## 2.5.11 + +### Patch Changes + +- [#3714](https://github.com/wevm/wagmi/pull/3714) [`f1628d65`](https://github.com/wevm/wagmi/commit/f1628d65f06e9ef18e6c4e2eb4f6e3ab2e700924) Thanks [@dalechyn](https://github.com/dalechyn)! - Replaced `Omit` with `UnionOmit` for `UseMutationReturnType`. + +- [#3715](https://github.com/wevm/wagmi/pull/3715) [`d56edf4f`](https://github.com/wevm/wagmi/commit/d56edf4f27c52acc7a0f57114454b0d3e22cacd6) Thanks [@jxom](https://github.com/jxom)! - Fixed SSR hydration issues. + +- Updated dependencies [[`d56edf4f`](https://github.com/wevm/wagmi/commit/d56edf4f27c52acc7a0f57114454b0d3e22cacd6)]: + - @wagmi/core@2.6.9 + - @wagmi/connectors@4.1.18 + +## 2.5.10 + +### Patch Changes + +- [#3643](https://github.com/wevm/wagmi/pull/3643) [`e46bcd47`](https://github.com/wevm/wagmi/commit/e46bcd4738a18da15b53f6612b614379c1985374) Thanks [@TateB](https://github.com/TateB)! - Fixed race condition arising from `reconnect`. + +- Updated dependencies [[`e46bcd47`](https://github.com/wevm/wagmi/commit/e46bcd4738a18da15b53f6612b614379c1985374)]: + - @wagmi/core@2.6.8 + - @wagmi/connectors@4.1.17 + +## 2.5.9 + +### Patch Changes + +- [`f5648dd2`](https://github.com/wevm/wagmi/commit/f5648dd28b3576b628f57732b89287f55acbb1c1) Thanks [@jxom](https://github.com/jxom)! - Updated `prepareTransactionRequest` types for `viem@2.8.0`. + +- [`1c1fee6a`](https://github.com/wevm/wagmi/commit/1c1fee6ab8f01f7734ac6ce05093fa8e388beb3e) Thanks [@jxom](https://github.com/jxom)! - Updated `@walletconnect/ethereum-provider`. + +- Updated dependencies [[`b479b5e8`](https://github.com/wevm/wagmi/commit/b479b5e8a5866cba792862f22e6352c4fb566137), [`f5648dd2`](https://github.com/wevm/wagmi/commit/f5648dd28b3576b628f57732b89287f55acbb1c1), [`1c1fee6a`](https://github.com/wevm/wagmi/commit/1c1fee6ab8f01f7734ac6ce05093fa8e388beb3e), [`88a2d744`](https://github.com/wevm/wagmi/commit/88a2d744a1315908c9e54156026df3ad2435ad44)]: + - @wagmi/core@2.6.7 + - @wagmi/connectors@4.1.16 + +## 2.5.8 + +### Patch Changes + +- Updated dependencies [[`a91c0b64`](https://github.com/wevm/wagmi/commit/a91c0b64ba8b3e6537a560e69724eb601f26af27)]: + - @wagmi/core@2.6.6 + - @wagmi/connectors@4.1.15 + +## 2.5.7 + +### Patch Changes + +- [#3580](https://github.com/wevm/wagmi/pull/3580) [`c677dcd2`](https://github.com/wevm/wagmi/commit/c677dcd245dccdf69289a3d66dded237b09570a2) Thanks [@tmm](https://github.com/tmm)! - Made `useSwitchChain().chains` reactive. + +- Updated dependencies [[`ca5decdb`](https://github.com/wevm/wagmi/commit/ca5decdb712f81e3f5dab933a94b967bca5b6af4), [`c677dcd2`](https://github.com/wevm/wagmi/commit/c677dcd245dccdf69289a3d66dded237b09570a2)]: + - @wagmi/connectors@4.1.14 + - @wagmi/core@2.6.5 + +## 2.5.6 + +### Patch Changes + +- Updated dependencies [[`7c6618e6`](https://github.com/wevm/wagmi/commit/7c6618e6a0eb1ff39cf8f66b34d3ddc14be538fe), [`fa25b448`](https://github.com/wevm/wagmi/commit/fa25b4482504b4d9729a5687ea6d6dc959265bc0), [`895f28e8`](https://github.com/wevm/wagmi/commit/895f28e873af7c8eda5ca85734ff67c8979fd950)]: + - @wagmi/core@2.6.4 + - @wagmi/connectors@4.1.13 + +## 2.5.5 + +### Patch Changes + +- Updated dependencies [[`9c3b85dd`](https://github.com/wevm/wagmi/commit/9c3b85dd0a9a4a593e1d7e029345275735330e32), [`2a72214a`](https://github.com/wevm/wagmi/commit/2a72214a2901d6b6ddd39f80238aa0bd4db670a7)]: + - @wagmi/core@2.6.3 + - @wagmi/connectors@4.1.12 + +## 2.5.4 + +### Patch Changes + +- [`3f8203bd`](https://github.com/wevm/wagmi/commit/3f8203bd77fcf6b6756640b5971d09741ae3853d) Thanks [@tmm](https://github.com/tmm)! - Fixed `useBlock` parameters passthrough to Viem. + +## 2.5.3 + +### Patch Changes + +- [#3518](https://github.com/wevm/wagmi/pull/3518) [`338e857d`](https://github.com/wevm/wagmi/commit/338e857d8cb2fe85e13d9207bef14cada1c1962d) Thanks [@tmm](https://github.com/tmm)! - Bumped dependencies. + +- Updated dependencies [[`414eb048`](https://github.com/wevm/wagmi/commit/414eb048af492caac70c0e874dfc87c30702804a), [`338e857d`](https://github.com/wevm/wagmi/commit/338e857d8cb2fe85e13d9207bef14cada1c1962d), [`338e857d`](https://github.com/wevm/wagmi/commit/338e857d8cb2fe85e13d9207bef14cada1c1962d)]: + - @wagmi/core@2.6.2 + - @wagmi/connectors@4.1.11 + +## 2.5.2 + +### Patch Changes + +- [#3433](https://github.com/wevm/wagmi/pull/3433) [`101a7dd1`](https://github.com/wevm/wagmi/commit/101a7dd131b0cae2dc25579ecab9044290efd37b) Thanks [@tmm](https://github.com/tmm)! - Fixed `useClient` and `usePublicClient` throwing when used with unconfigured `chainId`. + +- [#3510](https://github.com/wevm/wagmi/pull/3510) [`660ff80d`](https://github.com/wevm/wagmi/commit/660ff80d5b046967a446eba43ee54b8359a37d0d) Thanks [@tmm](https://github.com/tmm)! - Fixed issue where connectors returning multiple addresses didn't checksum correctly. + +- Updated dependencies [[`660ff80d`](https://github.com/wevm/wagmi/commit/660ff80d5b046967a446eba43ee54b8359a37d0d), [`101a7dd1`](https://github.com/wevm/wagmi/commit/101a7dd131b0cae2dc25579ecab9044290efd37b)]: + - @wagmi/connectors@4.1.10 + - @wagmi/core@2.6.1 + +## 2.5.1 + +### Patch Changes + +- [#3496](https://github.com/wevm/wagmi/pull/3496) [`ba7f8a75`](https://github.com/wevm/wagmi/commit/ba7f8a758efb07664c6e401b5e7e325e7c62341b) Thanks [@tmm](https://github.com/tmm)! - Bumped dependencies. + +- Updated dependencies [[`ba7f8a75`](https://github.com/wevm/wagmi/commit/ba7f8a758efb07664c6e401b5e7e325e7c62341b), [`ba7f8a75`](https://github.com/wevm/wagmi/commit/ba7f8a758efb07664c6e401b5e7e325e7c62341b)]: + - @wagmi/connectors@4.1.9 + - @wagmi/core@2.6.0 + +## 2.5.0 + +### Minor Changes + +- [#3461](https://github.com/wevm/wagmi/pull/3461) [`ca98041d`](https://github.com/wevm/wagmi/commit/ca98041d1b39893d90246929485f4db0d1c6f9f7) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `useTransactionConfirmations` hook. + +### Patch Changes + +- Updated dependencies [[`ca98041d`](https://github.com/wevm/wagmi/commit/ca98041d1b39893d90246929485f4db0d1c6f9f7)]: + - @wagmi/core@2.5.0 + - @wagmi/connectors@4.1.8 + +## 2.4.0 + +### Minor Changes + +- [#3427](https://github.com/wevm/wagmi/pull/3427) [`370f1b4a`](https://github.com/wevm/wagmi/commit/370f1b4a3f154d181acf381c31c2e7862e22c0e4) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `usePrepareTransactionRequest` hook. + +### Patch Changes + +- Updated dependencies [[`370f1b4a`](https://github.com/wevm/wagmi/commit/370f1b4a3f154d181acf381c31c2e7862e22c0e4), [`370f1b4a`](https://github.com/wevm/wagmi/commit/370f1b4a3f154d181acf381c31c2e7862e22c0e4)]: + - @wagmi/connectors@4.1.7 + - @wagmi/core@2.4.0 + +## 2.3.1 + +### Patch Changes + +- [#3476](https://github.com/wevm/wagmi/pull/3476) [`3be5bb7b`](https://github.com/wevm/wagmi/commit/3be5bb7b0b38646e12e6da5c762ef74dff66bcc2) Thanks [@jxom](https://github.com/jxom)! - Modified persist strategy to only store "critical" properties that are needed before hydration. + +- Updated dependencies [[`3be5bb7b`](https://github.com/wevm/wagmi/commit/3be5bb7b0b38646e12e6da5c762ef74dff66bcc2)]: + - @wagmi/core@2.3.1 + - @wagmi/connectors@4.1.6 + +## 2.3.0 + +### Minor Changes + +- [#3459](https://github.com/wevm/wagmi/pull/3459) [`d950b666`](https://github.com/wevm/wagmi/commit/d950b666b56700ca039ce16cdfdf34564991e7f5) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `useEnsText` action. + +### Patch Changes + +- [#3467](https://github.com/wevm/wagmi/pull/3467) [`90ef39bb`](https://github.com/wevm/wagmi/commit/90ef39bb0f4ecb3c914d317875348e35ba0f4524) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where connectors that share the same provider instance could reconnect when they have never been connected before. + +- [`1cfb6e5a`](https://github.com/wevm/wagmi/commit/1cfb6e5a875e707abcee00dd5739e87da05e8c90) Thanks [@jxom](https://github.com/jxom)! - Bumped listener limit on WalletConnect connector. + +- Updated dependencies [[`d950b666`](https://github.com/wevm/wagmi/commit/d950b666b56700ca039ce16cdfdf34564991e7f5), [`d950b666`](https://github.com/wevm/wagmi/commit/d950b666b56700ca039ce16cdfdf34564991e7f5), [`90ef39bb`](https://github.com/wevm/wagmi/commit/90ef39bb0f4ecb3c914d317875348e35ba0f4524), [`1cfb6e5a`](https://github.com/wevm/wagmi/commit/1cfb6e5a875e707abcee00dd5739e87da05e8c90)]: + - @wagmi/core@2.3.0 + - @wagmi/connectors@5.0.0 + +## 2.2.1 + +### Patch Changes + +- [#3443](https://github.com/wevm/wagmi/pull/3443) [`007024a6`](https://github.com/wevm/wagmi/commit/007024a684ddbecf924cdc06dd6a8854fc3d5eeb) Thanks [@jmrossy](https://github.com/jmrossy)! - Bumped dependencies. + +- [#3447](https://github.com/wevm/wagmi/pull/3447) [`a02a26ad`](https://github.com/wevm/wagmi/commit/a02a26ad030d3afb78f744377d61b5c60b65d97a) Thanks [@tmm](https://github.com/tmm)! - Fixed account typing. + +- Updated dependencies [[`007024a6`](https://github.com/wevm/wagmi/commit/007024a684ddbecf924cdc06dd6a8854fc3d5eeb), [`a02a26ad`](https://github.com/wevm/wagmi/commit/a02a26ad030d3afb78f744377d61b5c60b65d97a), [`a02a26ad`](https://github.com/wevm/wagmi/commit/a02a26ad030d3afb78f744377d61b5c60b65d97a), [`007024a6`](https://github.com/wevm/wagmi/commit/007024a684ddbecf924cdc06dd6a8854fc3d5eeb)]: + - @wagmi/connectors@4.1.4 + - @wagmi/core@2.2.1 + +## 2.2.0 + +### Minor Changes + +- [#3434](https://github.com/wevm/wagmi/pull/3434) [`00bf10a4`](https://github.com/wevm/wagmi/commit/00bf10a428b0d1c5dac35ebf25b19571e033ac26) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `useBytecode` and `useStorageAt` hooks. + +- [#3408](https://github.com/wevm/wagmi/pull/3408) [`fb6c4148`](https://github.com/wevm/wagmi/commit/fb6c4148d9e9e2fccfbe74c8f343b444dc68dec5) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `useProof` hook. + +- [#3416](https://github.com/wevm/wagmi/pull/3416) [`64c073f6`](https://github.com/wevm/wagmi/commit/64c073f6c2720961e2d6aff986670b73dbfab9c3) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `useTransactionReceipt` hook. + +### Patch Changes + +- Updated dependencies [[`00bf10a4`](https://github.com/wevm/wagmi/commit/00bf10a428b0d1c5dac35ebf25b19571e033ac26), [`64c073f6`](https://github.com/wevm/wagmi/commit/64c073f6c2720961e2d6aff986670b73dbfab9c3), [`fb6c4148`](https://github.com/wevm/wagmi/commit/fb6c4148d9e9e2fccfbe74c8f343b444dc68dec5)]: + - @wagmi/core@2.2.0 + - @wagmi/connectors@5.0.0 + +## 2.1.2 + +### Patch Changes + +- [#3407](https://github.com/wevm/wagmi/pull/3407) [`e00b8205`](https://github.com/wevm/wagmi/commit/e00b82058685751637edfa9a6b2d196a12549fe7) Thanks [@jxom](https://github.com/jxom)! - Added a prelude gas estimate check to `sendTransaction`/`useSendTransaction`. + +- Updated dependencies [[`e00b8205`](https://github.com/wevm/wagmi/commit/e00b82058685751637edfa9a6b2d196a12549fe7)]: + - @wagmi/core@2.1.2 + - @wagmi/connectors@4.1.2 + +## 2.1.1 + +### Patch Changes + +- [#3402](https://github.com/wevm/wagmi/pull/3402) [`64b82282`](https://github.com/wevm/wagmi/commit/64b82282c1e57e77c25aa0814673780e4d11edd4) Thanks [@Songkeys](https://github.com/Songkeys)! - Fixed SSR cookie support for cookies that have special characters, e.g. `=`. + +- [`ec0d8b41`](https://github.com/wevm/wagmi/commit/ec0d8b4112181fefb11025e436a94a6114761d37) Thanks [@tmm](https://github.com/tmm)! - Added note to `metaMask` connector. + +- Updated dependencies [[`64b82282`](https://github.com/wevm/wagmi/commit/64b82282c1e57e77c25aa0814673780e4d11edd4), [`ec0d8b41`](https://github.com/wevm/wagmi/commit/ec0d8b4112181fefb11025e436a94a6114761d37)]: + - @wagmi/core@2.1.1 + - @wagmi/connectors@4.1.1 + +## 2.1.0 + +### Minor Changes + +- [#3387](https://github.com/wevm/wagmi/pull/3387) [`c9cd302e`](https://github.com/wevm/wagmi/commit/c9cd302e1c65c980deaee2e12567c2a8ec08b399) Thanks [@marthendalnunes](https://github.com/marthendalnunes)! - Added `useCall` hook. + +### Patch Changes + +- Updated dependencies [[`c9cd302e`](https://github.com/wevm/wagmi/commit/c9cd302e1c65c980deaee2e12567c2a8ec08b399)]: + - @wagmi/core@2.1.0 + - @wagmi/connectors@5.0.0 + +## 2.0.3 + +### Patch Changes + +- [#3384](https://github.com/wevm/wagmi/pull/3384) [`ee868c33`](https://github.com/wevm/wagmi/commit/ee868c3385dae511230b6ddcb5627c1293cc1844) Thanks [@tmm](https://github.com/tmm)! - Fixed connectors not bubbling error when connecting with `chainId` and subsequent user rejection. + +- Updated dependencies [[`ee868c33`](https://github.com/wevm/wagmi/commit/ee868c3385dae511230b6ddcb5627c1293cc1844)]: + - @wagmi/connectors@4.0.2 + - @wagmi/core@2.0.2 + +## 2.0.2 + +### Patch Changes + +- [#3379](https://github.com/wevm/wagmi/pull/3379) [`30a186e5`](https://github.com/wevm/wagmi/commit/30a186e53d1135657d04f72f40d1c27186025370) Thanks [@tmm](https://github.com/tmm)! - Fixed `useConnect` error getting unset. + +## 2.0.1 + +### Major Changes + +- [#3333](https://github.com/wevm/wagmi/pull/3333) [`b3a0baaa`](https://github.com/wevm/wagmi/commit/b3a0baaaee7decf750d376aab2502cd33ca4825a) Thanks [@tmm](https://github.com/tmm)! - Wagmi 2.0 featuring: + + - Full TanStack Query support + queryKeys + - Connect multiple connectors + - Switch chains while disconnected + - EIP-6963 enabled + - Strongly typed chainId and chain properties + - Smaller bundle size + - Miscellaneous improvements and bug fixes + + [Breaking Changes & Migration Guide](https://wagmi.sh/react/guides/migrate-from-v1-to-v2) + +### Patch Changes + +- Updated dependencies [[`b3a0baaa`](https://github.com/wevm/wagmi/commit/b3a0baaaee7decf750d376aab2502cd33ca4825a), [`b3a0baaa`](https://github.com/wevm/wagmi/commit/b3a0baaaee7decf750d376aab2502cd33ca4825a)]: + - @wagmi/connectors@4.0.0 + - @wagmi/core@2.0.0 + +## 1.4.13 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@1.4.13 + +## 1.4.12 + +### Patch Changes + +- [`53ca1f7e`](https://github.com/wevm/wagmi/commit/53ca1f7eb411d912e11fcce7e03bd61ed067959c) Thanks [@tmm](https://github.com/tmm)! - Removed LedgerConnector due to security vulnerability + +- Updated dependencies [[`53ca1f7e`](https://github.com/wevm/wagmi/commit/53ca1f7eb411d912e11fcce7e03bd61ed067959c)]: + - @wagmi/core@1.4.12 + +## 1.4.11 + +### Patch Changes + +- [#3299](https://github.com/wevm/wagmi/pull/3299) [`b02020b3`](https://github.com/wevm/wagmi/commit/b02020b3724e0228198f35817611bb063295906e) Thanks [@dasanra](https://github.com/dasanra)! - Fixed issue with [Safe SDK](https://github.com/wevm/viem/issues/579) by bumping `@safe-global/safe-apps-provider@0.18.1` + +- Updated dependencies [[`b02020b3`](https://github.com/wevm/wagmi/commit/b02020b3724e0228198f35817611bb063295906e)]: + - @wagmi/core@1.4.11 + +## 1.4.10 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@1.4.10 + +## 1.4.9 + +### Patch Changes + +- [#3276](https://github.com/wevm/wagmi/pull/3276) [`83223a06`](https://github.com/wevm/wagmi/commit/83223a0659e2f675d897a1d3374c7af752c16abf) Thanks [@glitch-txs](https://github.com/glitch-txs)! - Removed required namespaces from WalletConnect connector + +- Updated dependencies [[`83223a06`](https://github.com/wevm/wagmi/commit/83223a0659e2f675d897a1d3374c7af752c16abf)]: + - @wagmi/core@1.4.9 + +## 1.4.8 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@1.4.8 + +## 1.4.7 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@1.4.7 + +## 1.4.6 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@1.4.6 + +## 1.4.5 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@1.4.5 + +## 1.4.4 + +### Patch Changes + +- [#3125](https://github.com/wagmi-dev/wagmi/pull/3125) [`725e73fe`](https://github.com/wagmi-dev/wagmi/commit/725e73feb9143dbaa6d540bb76d2009cef29da0b) Thanks [@lukasrosario](https://github.com/lukasrosario)! - Fixed an issue where `dataSuffix` was not being passed down into viem's `simulateContract`, causing the data to be omitted from requests. + +- Updated dependencies [[`725e73fe`](https://github.com/wagmi-dev/wagmi/commit/725e73feb9143dbaa6d540bb76d2009cef29da0b)]: + - @wagmi/core@1.4.4 + +## 1.4.3 + +### Patch Changes + +- [#3076](https://github.com/wagmi-dev/wagmi/pull/3076) [`4c36831b`](https://github.com/wagmi-dev/wagmi/commit/4c36831b7aa44d03b5c0decf64dcd20faae28a67) Thanks [@jxom](https://github.com/jxom)! - Pass `chain` to viem `sendTransaction`/`writeContract`. + +- [#3006](https://github.com/wagmi-dev/wagmi/pull/3006) [`f2ddce23`](https://github.com/wagmi-dev/wagmi/commit/f2ddce23324aff0a91e066100918dac552dc3b4a) Thanks [@jxom](https://github.com/jxom)! - Changed `normalize` to a dynamic import. + +- Updated dependencies [[`4c36831b`](https://github.com/wagmi-dev/wagmi/commit/4c36831b7aa44d03b5c0decf64dcd20faae28a67), [`f2ddce23`](https://github.com/wagmi-dev/wagmi/commit/f2ddce23324aff0a91e066100918dac552dc3b4a)]: + - @wagmi/core@1.4.3 + +## 1.4.2 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@1.4.2 + +## 1.4.1 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@1.4.1 + +## 1.4.0 + +### Minor Changes + +- [#2956](https://github.com/wagmi-dev/wagmi/pull/2956) [`2abeb285`](https://github.com/wagmi-dev/wagmi/commit/2abeb285674af3e539cc2550b1f5027b1eb0c895) Thanks [@tmm](https://github.com/tmm)! - Replaced `@wagmi/chains` with `viem/chains`. + +### Patch Changes + +- Updated dependencies [[`2abeb285`](https://github.com/wagmi-dev/wagmi/commit/2abeb285674af3e539cc2550b1f5027b1eb0c895)]: + - @wagmi/core@1.4.0 + +## 1.3.11 + +### Patch Changes + +- [`557e6400`](https://github.com/wagmi-dev/wagmi/commit/557e6400b9cef3b2c5131739143956c37d7c934a) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies [[`557e6400`](https://github.com/wagmi-dev/wagmi/commit/557e6400b9cef3b2c5131739143956c37d7c934a)]: + - @wagmi/core@1.3.10 + +## 1.3.10 + +### Patch Changes + +- [`247c5d11`](https://github.com/wagmi-dev/wagmi/commit/247c5d113e83acf3a6894264c00d4b125d455107) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies [[`247c5d11`](https://github.com/wagmi-dev/wagmi/commit/247c5d113e83acf3a6894264c00d4b125d455107)]: + - @wagmi/core@1.3.9 + +## 1.3.9 + +### Patch Changes + +- [#2741](https://github.com/wagmi-dev/wagmi/pull/2741) [`5b1453d9`](https://github.com/wagmi-dev/wagmi/commit/5b1453d95973ed51f1c235a919fffb707eab9b70) Thanks [@jxom](https://github.com/jxom)! - Updated references + +- Updated dependencies [[`5b1453d9`](https://github.com/wagmi-dev/wagmi/commit/5b1453d95973ed51f1c235a919fffb707eab9b70)]: + - @wagmi/core@1.3.8 + +## 1.3.8 + +### Patch Changes + +- [#2700](https://github.com/wagmi-dev/wagmi/pull/2700) [`30118e97`](https://github.com/wagmi-dev/wagmi/commit/30118e979b1b00302e035f31f58c15d1aed911d5) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies [[`30118e97`](https://github.com/wagmi-dev/wagmi/commit/30118e979b1b00302e035f31f58c15d1aed911d5)]: + - @wagmi/core@1.3.7 + +## 1.3.7 + +### Patch Changes + +- [`7ad2fdb8`](https://github.com/wagmi-dev/wagmi/commit/7ad2fdb81c7734d0c8107670800c68390e3bad99) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies [[`7ad2fdb8`](https://github.com/wagmi-dev/wagmi/commit/7ad2fdb81c7734d0c8107670800c68390e3bad99)]: + - @wagmi/core@1.3.6 + +## 1.3.6 + +### Patch Changes + +- [`aab63fc1`](https://github.com/wagmi-dev/wagmi/commit/aab63fc1f8949004573978ecd8574fada3360758) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies [[`aab63fc1`](https://github.com/wagmi-dev/wagmi/commit/aab63fc1f8949004573978ecd8574fada3360758)]: + - @wagmi/core@1.3.5 + +## 1.3.5 + +### Patch Changes + +- [#2669](https://github.com/wagmi-dev/wagmi/pull/2669) [`db75c459`](https://github.com/wagmi-dev/wagmi/commit/db75c4593b9c46970dc9d3c96d7adafc76878fc3) Thanks [@llllvvuu](https://github.com/llllvvuu)! - Modified `useAccount` and `useNetwork` to be reactive of wagmi Config (`config`). + +## 1.3.4 + +### Patch Changes + +- [`b056f809`](https://github.com/wagmi-dev/wagmi/commit/b056f8095674d4addc6ecd09adf6001fe52e2b15) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `onConnect` was not being called when multiple instances of `useAccount` existed. + +- [`22246d98`](https://github.com/wagmi-dev/wagmi/commit/22246d9884277d28ccad6ca2d9529b96b67d47fc) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies [[`22246d98`](https://github.com/wagmi-dev/wagmi/commit/22246d9884277d28ccad6ca2d9529b96b67d47fc)]: + - @wagmi/core@1.3.4 + +## 1.3.3 + +### Patch Changes + +- [`1946aa43`](https://github.com/wagmi-dev/wagmi/commit/1946aa43a65b684ef41b7b4c43c67bf29c13e854) Thanks [@jxom](https://github.com/jxom)! - Updated references + +- Updated dependencies [[`1946aa43`](https://github.com/wagmi-dev/wagmi/commit/1946aa43a65b684ef41b7b4c43c67bf29c13e854)]: + - @wagmi/core@1.3.3 + +## 1.3.2 + +### Patch Changes + +- [`e86d0940`](https://github.com/wagmi-dev/wagmi/commit/e86d09409bb20b64d24e1263abcf0291314f03c7) Thanks [@jxom](https://github.com/jxom)! - Updated references + +- Updated dependencies [[`e86d0940`](https://github.com/wagmi-dev/wagmi/commit/e86d09409bb20b64d24e1263abcf0291314f03c7)]: + - @wagmi/core@1.3.2 + +## 1.3.1 + +### Patch Changes + +- [`964042fa`](https://github.com/wagmi-dev/wagmi/commit/964042fa94d682977923c595820c58283fb9244a) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies [[`964042fa`](https://github.com/wagmi-dev/wagmi/commit/964042fa94d682977923c595820c58283fb9244a)]: + - @wagmi/core@1.3.1 + +## 1.3.0 + +### Minor Changes + +- [#2619](https://github.com/wagmi-dev/wagmi/pull/2619) [`0d79748c`](https://github.com/wagmi-dev/wagmi/commit/0d79748cec2b6ac2410ad2c9816cc662f2b70962) Thanks [@jxom](https://github.com/jxom)! - Updated references: + - Updated `@safe-global/safe-apps-sdk` to `^8.0.0` (the one with `viem` support) + +### Patch Changes + +- Updated dependencies [[`0d79748c`](https://github.com/wagmi-dev/wagmi/commit/0d79748cec2b6ac2410ad2c9816cc662f2b70962)]: + - @wagmi/core@1.3.0 + +## 1.2.2 + +### Patch Changes + +- [#2611](https://github.com/wagmi-dev/wagmi/pull/2611) [`6d1ed7a1`](https://github.com/wagmi-dev/wagmi/commit/6d1ed7a156729b4df5d66fef3ae9a8b5762a2d34) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies [[`6d1ed7a1`](https://github.com/wagmi-dev/wagmi/commit/6d1ed7a156729b4df5d66fef3ae9a8b5762a2d34)]: + - @wagmi/core@1.2.2 + +## 1.2.1 + +### Patch Changes + +- [#2589](https://github.com/wagmi-dev/wagmi/pull/2589) [`9680c347`](https://github.com/wagmi-dev/wagmi/commit/9680c347476500d28ceca20d23eeaed7931cb6e0) Thanks [@jxom](https://github.com/jxom)! - Fixed `writeContract` parameters to be compatible with `prepareWriteContract`. + +- [#2587](https://github.com/wagmi-dev/wagmi/pull/2587) [`cfff9994`](https://github.com/wagmi-dev/wagmi/commit/cfff999459384ac644ff7e62f53a7b787cf37507) Thanks [@jxom](https://github.com/jxom)! - Updated references + +- Updated dependencies [[`9680c347`](https://github.com/wagmi-dev/wagmi/commit/9680c347476500d28ceca20d23eeaed7931cb6e0), [`cfff9994`](https://github.com/wagmi-dev/wagmi/commit/cfff999459384ac644ff7e62f53a7b787cf37507)]: + - @wagmi/core@1.2.1 + +## 1.2.0 + +### Minor Changes + +- [#2536](https://github.com/wagmi-dev/wagmi/pull/2536) [`85e9760a`](https://github.com/wagmi-dev/wagmi/commit/85e9760a140cb169ac6236d9466b96e2105dd193) Thanks [@tmm](https://github.com/tmm)! - Changed `Address` type import from ABIType to viem. + +### Patch Changes + +- [#2539](https://github.com/wagmi-dev/wagmi/pull/2539) [`96319c64`](https://github.com/wagmi-dev/wagmi/commit/96319c640b9d07b375821c08a5c213355d8c290b) Thanks [@jxom](https://github.com/jxom)! - Updated references + +- Updated dependencies [[`85e9760a`](https://github.com/wagmi-dev/wagmi/commit/85e9760a140cb169ac6236d9466b96e2105dd193), [`96319c64`](https://github.com/wagmi-dev/wagmi/commit/96319c640b9d07b375821c08a5c213355d8c290b)]: + - @wagmi/core@1.2.0 + +## 1.1.1 + +### Patch Changes + +- [`02b98a9f`](https://github.com/wagmi-dev/wagmi/commit/02b98a9f9b2c503a47af4a8967e0202b5db21787) Thanks [@jxom](https://github.com/jxom)! - Updated `viem` peer dependency. + +- [`02b98a9f`](https://github.com/wagmi-dev/wagmi/commit/02b98a9f9b2c503a47af4a8967e0202b5db21787) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies [[`02b98a9f`](https://github.com/wagmi-dev/wagmi/commit/02b98a9f9b2c503a47af4a8967e0202b5db21787), [`02b98a9f`](https://github.com/wagmi-dev/wagmi/commit/02b98a9f9b2c503a47af4a8967e0202b5db21787)]: + - @wagmi/core@1.1.1 + +## 1.1.0 + +### Minor Changes + +- [#2482](https://github.com/wagmi-dev/wagmi/pull/2482) [`8764b54a`](https://github.com/wagmi-dev/wagmi/commit/8764b54aab68020063946112e8fe52aff650c99c) Thanks [@tmm](https://github.com/tmm)! - Bumped minimum TypeScript version to v5.0.4. + +### Patch Changes + +- [#2471](https://github.com/wagmi-dev/wagmi/pull/2471) [`74099cef`](https://github.com/wagmi-dev/wagmi/commit/74099cefd922317641529f7881a4c8a740d62cbe) Thanks [@iuriiiurevich](https://github.com/iuriiiurevich)! - Added `keepPreviousData` prop to `useContractRead`. + +- [#2484](https://github.com/wagmi-dev/wagmi/pull/2484) [`3adf1f4f`](https://github.com/wagmi-dev/wagmi/commit/3adf1f4feab863cb7b5d52c81ad46f7e4eb56f09) Thanks [@jxom](https://github.com/jxom)! - Updated `abitype` to 0.8.7 + +- [#2484](https://github.com/wagmi-dev/wagmi/pull/2484) [`3adf1f4f`](https://github.com/wagmi-dev/wagmi/commit/3adf1f4feab863cb7b5d52c81ad46f7e4eb56f09) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- [`01d4a6ed`](https://github.com/wagmi-dev/wagmi/commit/01d4a6ed53110712692599095d94f04dfb5b6e38) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `useInvalidateOnBlock`'s `onBlock` was being called on every render. + +- Updated dependencies [[`8764b54a`](https://github.com/wagmi-dev/wagmi/commit/8764b54aab68020063946112e8fe52aff650c99c), [`3adf1f4f`](https://github.com/wagmi-dev/wagmi/commit/3adf1f4feab863cb7b5d52c81ad46f7e4eb56f09), [`3adf1f4f`](https://github.com/wagmi-dev/wagmi/commit/3adf1f4feab863cb7b5d52c81ad46f7e4eb56f09)]: + - @wagmi/core@1.1.0 + +## 1.0.9 + +### Patch Changes + +- [#2446](https://github.com/wagmi-dev/wagmi/pull/2446) [`899d8c06`](https://github.com/wagmi-dev/wagmi/commit/899d8c0698e6cc958ca8ad9ec586883edf20516e) Thanks [@iuriiiurevich](https://github.com/iuriiiurevich)! - Added `cancelRefetch: false` to `useInvalidateOnBlock`. + +## 1.0.8 + +### Patch Changes + +- [#2441](https://github.com/wagmi-dev/wagmi/pull/2441) [`326edee4`](https://github.com/wagmi-dev/wagmi/commit/326edee4bc85db84a7a4e3768e33785849ab8d8e) Thanks [@tmm](https://github.com/tmm)! - Fixed internal type issue + +- Updated dependencies [[`326edee4`](https://github.com/wagmi-dev/wagmi/commit/326edee4bc85db84a7a4e3768e33785849ab8d8e)]: + - @wagmi/core@1.0.8 + +## 1.0.7 + +### Patch Changes + +- [#2433](https://github.com/wagmi-dev/wagmi/pull/2433) [`54fcff5f`](https://github.com/wagmi-dev/wagmi/commit/54fcff5f02f6933bbbe045ee0c83c5a78b6bba49) Thanks [@jxom](https://github.com/jxom)! - Added ability to pass an `account` to `useContractWrite`/`usePrepareContractWrite`. + +- Updated dependencies [[`54fcff5f`](https://github.com/wagmi-dev/wagmi/commit/54fcff5f02f6933bbbe045ee0c83c5a78b6bba49)]: + - @wagmi/core@1.0.7 + +## 1.0.6 + +### Patch Changes + +- [`ca2e1e96`](https://github.com/wagmi-dev/wagmi/commit/ca2e1e96149b87a7dc42c9db07e1f1ad2bb02c4a) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- [#2401](https://github.com/wagmi-dev/wagmi/pull/2401) [`0f9dc875`](https://github.com/wagmi-dev/wagmi/commit/0f9dc875e90cfdd7a2028e04b7204caf9ea313b2) Thanks [@jxom](https://github.com/jxom)! - Exposed `account` on `readContract`/`useContractRead`. + +- Updated dependencies [[`ca2e1e96`](https://github.com/wagmi-dev/wagmi/commit/ca2e1e96149b87a7dc42c9db07e1f1ad2bb02c4a), [`0f9dc875`](https://github.com/wagmi-dev/wagmi/commit/0f9dc875e90cfdd7a2028e04b7204caf9ea313b2)]: + - @wagmi/core@1.0.6 + +## 1.0.5 + +### Patch Changes + +- [`90e2b3b3`](https://github.com/wagmi-dev/wagmi/commit/90e2b3b39efe0585fe28645ac2264109be17362a) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies [[`90e2b3b3`](https://github.com/wagmi-dev/wagmi/commit/90e2b3b39efe0585fe28645ac2264109be17362a)]: + - @wagmi/core@1.0.5 + +## 1.0.4 + +### Patch Changes + +- [#2344](https://github.com/wagmi-dev/wagmi/pull/2344) [`8a725458`](https://github.com/wagmi-dev/wagmi/commit/8a72545853ae1024acd9efd18c06142e8c6c5750) Thanks [@jxom](https://github.com/jxom)! - Added gas estimation back into `prepareSendTransaction`. + +- Updated dependencies [[`8a725458`](https://github.com/wagmi-dev/wagmi/commit/8a72545853ae1024acd9efd18c06142e8c6c5750)]: + - @wagmi/core@1.0.4 + +## 1.0.3 + +### Patch Changes + +- [#2338](https://github.com/wagmi-dev/wagmi/pull/2338) [`92bfdc2c`](https://github.com/wagmi-dev/wagmi/commit/92bfdc2c744539558ba93c95f140b46ad331cee4) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where synchronous switch chain behavior (WalletConnect v2) would encounter chain id race conditions in `watchWalletClient`. + +- Updated dependencies [[`92bfdc2c`](https://github.com/wagmi-dev/wagmi/commit/92bfdc2c744539558ba93c95f140b46ad331cee4)]: + - @wagmi/core@1.0.3 + +## 1.0.2 + +### Patch Changes + +- Updated dependencies [[`09a4fd38`](https://github.com/wevm/wagmi/commit/09a4fd38f44eb176797925fd85314be17b610cd4)]: + - @wagmi/core@1.0.2 + +## 1.0.1 + +### Patch Changes + +- [`ea651cd7`](https://github.com/wevm/wagmi/commit/ea651cd7fc75b7866272605467db11fd6e1d81af) Thanks [@jxom](https://github.com/jxom)! - Downgraded abitype. + +- Updated dependencies [[`ea651cd7`](https://github.com/wevm/wagmi/commit/ea651cd7fc75b7866272605467db11fd6e1d81af)]: + - @wagmi/core@1.0.1 + +## 1.0.0 + +### Major Changes + +- [#2235](https://github.com/wevm/wagmi/pull/2235) [`5be0655c`](https://github.com/wevm/wagmi/commit/5be0655c8e48b25d38009022461fbf611af54349) Thanks [@jxom](https://github.com/jxom)! - Released v1. Read [Migration Guide](https://next.wagmi.sh/react/migration-guide#1xx-breaking-changes). + +### Patch Changes + +- Updated dependencies [[`5be0655c`](https://github.com/wevm/wagmi/commit/5be0655c8e48b25d38009022461fbf611af54349)]: + - @wagmi/core@1.0.0 + +## 1.0.0-next.9 + +### Patch Changes + +- Fixed `useContractEvent` effect dependencies. + +## 1.0.0-next.8 + +### Patch Changes + +- Added "use client" banner + +## 1.0.0-next.7 + +### Major Changes + +- [#2235](https://github.com/wevm/wagmi/pull/2235) [`708b2ce2`](https://github.com/wevm/wagmi/commit/708b2ce26efa8d3d910806a97cea5171dabc65de) Thanks [@jxom](https://github.com/jxom)! - Added `config.setPublicClient` & `config.setWebSocketPublicClient` + +- Updated references. + +### Patch Changes + +- Updated dependencies [[`708b2ce2`](https://github.com/wevm/wagmi/commit/708b2ce26efa8d3d910806a97cea5171dabc65de)]: + - @wagmi/core@1.0.0-next.7 + +## 1.0.0-next.6 + +### Major Changes + +- Added `config.setConnectors` + +### Patch Changes + +- Updated dependencies [[`708b2ce2`](https://github.com/wevm/wagmi/commit/708b2ce26efa8d3d910806a97cea5171dabc65de)]: + - @wagmi/core@1.0.0-next.6 + +## 1.0.0-next.5 + +### Major Changes + +- [#2235](https://github.com/wevm/wagmi/pull/2235) [`708b2ce2`](https://github.com/wevm/wagmi/commit/708b2ce26efa8d3d910806a97cea5171dabc65de) Thanks [@jxom](https://github.com/jxom)! - Added `config.setPublicClient` & `config.setWebSocketPublicClient` + +### Patch Changes + +- Updated dependencies [[`708b2ce2`](https://github.com/wevm/wagmi/commit/708b2ce26efa8d3d910806a97cea5171dabc65de)]: + - @wagmi/core@1.0.0-next.5 + +## 1.0.0-next.4 + +### Major Changes + +- Updated viem. + Removed `goerli` export from main entrypoint. + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@1.0.0-next.4 + +## 1.0.0-next.3 + +### Major Changes + +- Updated references. + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@1.0.0-next.3 + +## 1.0.0-next.2 + +### Major Changes + +- **Breaking:** Renamed `createClient` to `createConfig` +- **Breaking:** Renamed `useClient` to `useConfig` +- **Breaking:** Removed `request` as an argument to `usePrepareSendTransaction` & `useSendTransaction`. Arguments now belong on the root level of the Hook. + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@1.0.0-next.2 + +## 1.0.0-next.1 + +### Major Changes + +- updated viem + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@1.0.0-next.1 + +## 1.0.0-next.0 + +### Major Changes + +- [`a7dda00c`](https://github.com/wevm/wagmi/commit/a7dda00c5b546f8b2c42b527e4d9ac1b9e9ab1fb) Thanks [@jxom](https://github.com/jxom)! - Released v1. + +### Patch Changes + +- Updated dependencies [[`a7dda00c`](https://github.com/wevm/wagmi/commit/a7dda00c5b546f8b2c42b527e4d9ac1b9e9ab1fb)]: + - @wagmi/core@1.0.0-next.0 + +## 0.12.13 + +### Patch Changes + +- [#2270](https://github.com/wevm/wagmi/pull/2270) [`6d1fa9df`](https://github.com/wevm/wagmi/commit/6d1fa9df790287729c3b33d4f01fd23c2f8153f1) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies [[`6d1fa9df`](https://github.com/wevm/wagmi/commit/6d1fa9df790287729c3b33d4f01fd23c2f8153f1)]: + - @wagmi/core@0.10.11 + +## 0.12.12 + +### Patch Changes + +- [#2208](https://github.com/wevm/wagmi/pull/2208) [`cfc696d8`](https://github.com/wevm/wagmi/commit/cfc696d83c6f768a2e1a29c5197efeed7f1d40a1) Thanks [@bangtoven](https://github.com/bangtoven)! - Bumped references to apply coinbase wallet sdk updates + +- Updated dependencies [[`cfc696d8`](https://github.com/wevm/wagmi/commit/cfc696d83c6f768a2e1a29c5197efeed7f1d40a1)]: + - @wagmi/core@0.10.10 + +## 0.12.11 + +### Patch Changes + +- [#2203](https://github.com/wevm/wagmi/pull/2203) [`a4ca4b05`](https://github.com/wevm/wagmi/commit/a4ca4b05c5bd20c20c5d0741bfb18f2c798b9529) Thanks [@tmm](https://github.com/tmm)! - Downgraded abitype. + +## 0.12.10 + +### Patch Changes + +- [#2143](https://github.com/wevm/wagmi/pull/2143) [`26dc5326`](https://github.com/wevm/wagmi/commit/26dc53260fde1d3278018c0b20a6d48a093d9427) Thanks [@tmm](https://github.com/tmm)! - Exported Sepolia Chain. + +- [#2146](https://github.com/wevm/wagmi/pull/2146) [`21b6842e`](https://github.com/wevm/wagmi/commit/21b6842e8c296a0bbe71ebe0780d898abc4cf4a8) Thanks [@tmm](https://github.com/tmm)! - Bumped references + +- Updated dependencies [[`26dc5326`](https://github.com/wevm/wagmi/commit/26dc53260fde1d3278018c0b20a6d48a093d9427), [`21b6842e`](https://github.com/wevm/wagmi/commit/21b6842e8c296a0bbe71ebe0780d898abc4cf4a8)]: + - @wagmi/core@0.10.9 + +## 0.12.9 + +### Patch Changes + +- [#2120](https://github.com/wevm/wagmi/pull/2120) [`664c2b16`](https://github.com/wevm/wagmi/commit/664c2b1690bdce1ad7a619ac8f673c168dec6529) Thanks [@jxom](https://github.com/jxom)! - Bumped React Query & ABIType dependencies + +## 0.12.8 + +### Patch Changes + +- [#2099](https://github.com/wevm/wagmi/pull/2099) [`f1fee5b3`](https://github.com/wevm/wagmi/commit/f1fee5b30a1bd13b5e66118bf9cdc44b0dc003a1) Thanks [@jxom](https://github.com/jxom)! - Added chains: + + - `nexi` + - `polygonZkEvm` + - `xdc` + - `xdcTestnet` + +- [#2085](https://github.com/wevm/wagmi/pull/2085) [`7d64e3f5`](https://github.com/wevm/wagmi/commit/7d64e3f538a6149777bfa84ea9435769b2a7db58) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where multicall would not throw if the target chain was not configured on the wagmi client. + +- Updated dependencies [[`f1fee5b3`](https://github.com/wevm/wagmi/commit/f1fee5b30a1bd13b5e66118bf9cdc44b0dc003a1), [`7d64e3f5`](https://github.com/wevm/wagmi/commit/7d64e3f538a6149777bfa84ea9435769b2a7db58)]: + - @wagmi/core@0.10.8 + +## 0.12.7 + +### Patch Changes + +- [#2082](https://github.com/wevm/wagmi/pull/2082) [`2ccc8a25`](https://github.com/wevm/wagmi/commit/2ccc8a255e93f0a2bb7b22101656b3905ec59abd) Thanks [@jxom](https://github.com/jxom)! - Updated references. + +- Updated dependencies [[`2ccc8a25`](https://github.com/wevm/wagmi/commit/2ccc8a255e93f0a2bb7b22101656b3905ec59abd)]: + - @wagmi/core@0.10.7 + +## 0.12.6 + +### Patch Changes + +- [#2056](https://github.com/wevm/wagmi/pull/2056) [`944f6513`](https://github.com/wevm/wagmi/commit/944f6513adf09a6f0b3bd34f591d3bbd1f1ffd2e) Thanks [@tmm](https://github.com/tmm)! - Bumped references. + +- Updated dependencies [[`944f6513`](https://github.com/wevm/wagmi/commit/944f6513adf09a6f0b3bd34f591d3bbd1f1ffd2e)]: + - @wagmi/core@0.10.6 + +## 0.12.5 + +### Patch Changes + +- [#2053](https://github.com/wevm/wagmi/pull/2053) [`665df1bf`](https://github.com/wevm/wagmi/commit/665df1bf2afccb533102069def395e19fb7194dd) Thanks [@tmm](https://github.com/tmm)! - Fixed issue where you add a new chain to MetaMask, but the switch after is rejected. + +- Updated dependencies [[`665df1bf`](https://github.com/wevm/wagmi/commit/665df1bf2afccb533102069def395e19fb7194dd)]: + - @wagmi/core@0.10.5 + +## 0.12.4 + +### Patch Changes + +- [#2046](https://github.com/wevm/wagmi/pull/2046) [`90d8e9b8`](https://github.com/wevm/wagmi/commit/90d8e9b87962b72c54311649537e91a953660f9b) Thanks [@tmm](https://github.com/tmm)! - Exported internal type. + +- Updated dependencies [[`90d8e9b8`](https://github.com/wevm/wagmi/commit/90d8e9b87962b72c54311649537e91a953660f9b)]: + - @wagmi/core@0.10.4 + +## 0.12.3 + +### Patch Changes + +- [#2039](https://github.com/wevm/wagmi/pull/2039) [`bac893ab`](https://github.com/wevm/wagmi/commit/bac893ab26012d4d8741c4f80e8b8813aee26f0c) Thanks [@tmm](https://github.com/tmm)! - Updated references. + +- [#2043](https://github.com/wevm/wagmi/pull/2043) [`49a58320`](https://github.com/wevm/wagmi/commit/49a58320ab5f1f13bc4de25abcc028c8335e98f0) Thanks [@tmm](https://github.com/tmm)! - Removed `InjectedConnector` `shimChainChangedDisconnect` shim (no longer necessary). + +- [#2042](https://github.com/wevm/wagmi/pull/2042) [`e7ac7afc`](https://github.com/wevm/wagmi/commit/e7ac7afccb005e8d208c78d55b1fec979b8522a6) Thanks [@tmm](https://github.com/tmm)! - Fixed exposed types that weren't passed down. + +- Updated dependencies [[`bac893ab`](https://github.com/wevm/wagmi/commit/bac893ab26012d4d8741c4f80e8b8813aee26f0c), [`49a58320`](https://github.com/wevm/wagmi/commit/49a58320ab5f1f13bc4de25abcc028c8335e98f0)]: + - @wagmi/core@0.10.3 + +## 0.12.2 + +### Patch Changes + +- [#2016](https://github.com/wevm/wagmi/pull/2016) [`06bf61de`](https://github.com/wevm/wagmi/commit/06bf61dee6d2920777bd9392491e6b7aedebe7ab) Thanks [@jxom](https://github.com/jxom)! - Added chains: + + - `boba` + - `chronos` + - `crossbell` + - `dfk` + - `dogechain` + - `flare` + - `flareTestnet` + - `klaytn` + - `scrollTestnet` + - `shardeumSphinx` + - `skaleCalypso` + - `skaleCalypsoTestnet` + - `skaleChaosTestnet` + - `skaleCryptoBlades` + - `skaleCryptoColosseum` + - `skaleEuropa` + - `skaleEuropaTestnet` + - `skaleExorde` + - `skaleHumanProtocol` + - `skaleNebula` + - `skaleNebulaTestnet` + - `skaleRazor` + - `skaleTitan` + - `skaleTitanTestnet` + - `songbird` + - `songbirdTestnet` + - `titan` + - `titanTestnet` + - `wanchain` + - `wanchainTestnet` + +- [#2016](https://github.com/wevm/wagmi/pull/2016) [`06bf61de`](https://github.com/wevm/wagmi/commit/06bf61dee6d2920777bd9392491e6b7aedebe7ab) Thanks [@jxom](https://github.com/jxom)! - Updated references/ submodule. + +- Updated dependencies [[`06bf61de`](https://github.com/wevm/wagmi/commit/06bf61dee6d2920777bd9392491e6b7aedebe7ab), [`06bf61de`](https://github.com/wevm/wagmi/commit/06bf61dee6d2920777bd9392491e6b7aedebe7ab)]: + - @wagmi/core@0.10.2 + +## 0.12.0 + +### Minor Changes + +- [#1902](https://github.com/wevm/wagmi/pull/1902) [`0994e896`](https://github.com/wevm/wagmi/commit/0994e8966349b8811db0a5886db3831dafc99245) Thanks [@jxom](https://github.com/jxom)! - **Breaking:** Removed the `version` config option for `WalletConnectConnector`. + + `WalletConnectConnector` now uses WalletConnect v2 by default. WalletConnect v1 is now `WalletConnectLegacyConnector`. + + ### WalletConnect v2 + + ```diff + import { WalletConnectConnector } from 'wagmi/connectors/walletConnect' + + const connector = new WalletConnectConnector({ + options: { + - version: '2', + projectId: 'abc', + }, + }) + ``` + + ### WalletConnect v1 + + ```diff + -import { WalletConnectConnector } from 'wagmi/connectors/walletConnect' + +import { WalletConnectConnector } from 'wagmi/connectors/walletConnectLegacy' + + -const connector = new WalletConnectConnector({ + +const connector = new WalletConnectLegacyConnector({ + options: { + qrcode: true, + }, + }) + ``` + +### Patch Changes + +- Updated dependencies [[`0994e896`](https://github.com/wevm/wagmi/commit/0994e8966349b8811db0a5886db3831dafc99245)]: + - @wagmi/core@0.10.0 + +## 0.11.7 + +### Patch Changes + +- [#1907](https://github.com/wevm/wagmi/pull/1907) [`cc4e74ee`](https://github.com/wevm/wagmi/commit/cc4e74ee19665eccb3767052dab6ab956ff4e676) Thanks [@jxom](https://github.com/jxom)! - Added the following chains to the `wagmi/chains` entrypoint: + + - `baseGoerli` + - `harmonyOne` + - `polygonZkEvmTestnet` + +- Updated dependencies [[`cc4e74ee`](https://github.com/wevm/wagmi/commit/cc4e74ee19665eccb3767052dab6ab956ff4e676)]: + - @wagmi/core@0.9.7 + +## 0.11.6 + +### Patch Changes + +- [#1882](https://github.com/wevm/wagmi/pull/1882) [`282cc1b0`](https://github.com/wevm/wagmi/commit/282cc1b02003684d582cea411b11792a59c26fd0) Thanks [@tmm](https://github.com/tmm)! - Updated references. + +- Updated dependencies [[`282cc1b0`](https://github.com/wevm/wagmi/commit/282cc1b02003684d582cea411b11792a59c26fd0)]: + - @wagmi/core@0.9.6 + +## 0.11.5 + +### Patch Changes + +- [#1812](https://github.com/wevm/wagmi/pull/1812) [`c7fd7fbd`](https://github.com/wevm/wagmi/commit/c7fd7fbde6f6c69a3a9a4f89d948c4dfb1d22679) Thanks [@jxom](https://github.com/jxom)! - Added the following chains to the `wagmi/chains` entrypoint: + + - `filecoinCalibration` + - `moonbaseAlpha` + - `moonbeam` + - `moonriver` + +- Updated dependencies [[`c7fd7fbd`](https://github.com/wevm/wagmi/commit/c7fd7fbde6f6c69a3a9a4f89d948c4dfb1d22679)]: + - @wagmi/core@0.9.5 + +## 0.11.4 + +### Patch Changes + +- [#1679](https://github.com/wevm/wagmi/pull/1679) [`3cef111b`](https://github.com/wevm/wagmi/commit/3cef111b1e30120233d8754b33587cdf94aedd8f) Thanks [@aj-may](https://github.com/aj-may)! - Fixed `useAccount` `onConnect` and `onDisconnect` callbacks for React Strict Mode. + +- [#1786](https://github.com/wevm/wagmi/pull/1786) [`b173a431`](https://github.com/wevm/wagmi/commit/b173a43165c7925a4e56ce1e0327a31917e7edc5) Thanks [@tmm](https://github.com/tmm)! - Locked ethers peer dependency version to >=5.5.1 <6 + +- [#1787](https://github.com/wevm/wagmi/pull/1787) [`f023fd8f`](https://github.com/wevm/wagmi/commit/f023fd8f66befb78b9a4df5ca971ceaa64e37ab4) Thanks [@tmm](https://github.com/tmm)! - Added `SafeConnector` + +- Updated dependencies [[`b173a431`](https://github.com/wevm/wagmi/commit/b173a43165c7925a4e56ce1e0327a31917e7edc5), [`f023fd8f`](https://github.com/wevm/wagmi/commit/f023fd8f66befb78b9a4df5ca971ceaa64e37ab4)]: + - @wagmi/core@0.9.4 + +## 0.11.3 + +### Patch Changes + +- [#1773](https://github.com/wevm/wagmi/pull/1773) [`9aaf1955`](https://github.com/wevm/wagmi/commit/9aaf195514d3b5f4d085c797fc5021d42a9efb6c) Thanks [@jxom](https://github.com/jxom)! - Updated `@walletconnect/universal-provider` on `WalletConnectConnector` v2. + Added more signable methods to `WalletConnectConnector` v2. + +- [#1773](https://github.com/wevm/wagmi/pull/1773) [`9aaf1955`](https://github.com/wevm/wagmi/commit/9aaf195514d3b5f4d085c797fc5021d42a9efb6c) Thanks [@jxom](https://github.com/jxom)! - Added Telos to the `wagmi/chains` entrypoint. Thanks @donnyquixotic! + +- Updated dependencies [[`9aaf1955`](https://github.com/wevm/wagmi/commit/9aaf195514d3b5f4d085c797fc5021d42a9efb6c), [`9aaf1955`](https://github.com/wevm/wagmi/commit/9aaf195514d3b5f4d085c797fc5021d42a9efb6c)]: + - @wagmi/core@0.9.3 + +## 0.11.2 + +### Patch Changes + +- [#1756](https://github.com/wevm/wagmi/pull/1756) [`31d06b8c`](https://github.com/wevm/wagmi/commit/31d06b8ce1e7af5e9d1a7ba57f1743b2dff7a53d) Thanks [@jxom](https://github.com/jxom)! - Added OKC Chain. Thanks @clark-cui! + +- [#1756](https://github.com/wevm/wagmi/pull/1756) [`31d06b8c`](https://github.com/wevm/wagmi/commit/31d06b8ce1e7af5e9d1a7ba57f1743b2dff7a53d) Thanks [@jxom](https://github.com/jxom)! - Fixed race condition between `switchNetwork` and mutation Actions that use `chainId` (e.g. `sendTransaction`). Thanks @DanInTheD4rk! + +- Updated dependencies [[`31d06b8c`](https://github.com/wevm/wagmi/commit/31d06b8ce1e7af5e9d1a7ba57f1743b2dff7a53d), [`31d06b8c`](https://github.com/wevm/wagmi/commit/31d06b8ce1e7af5e9d1a7ba57f1743b2dff7a53d)]: + - @wagmi/core@0.9.2 + +## 0.11.1 + +### Patch Changes + +- [#1752](https://github.com/wevm/wagmi/pull/1752) [`144a0e76`](https://github.com/wevm/wagmi/commit/144a0e76ef4bb9ba0650b5ffb9c63f95329819a4) Thanks [@jxom](https://github.com/jxom)! - Improved `WalletConnectConnector` (v2) initialization & updated dependencies. + +- [#1752](https://github.com/wevm/wagmi/pull/1752) [`144a0e76`](https://github.com/wevm/wagmi/commit/144a0e76ef4bb9ba0650b5ffb9c63f95329819a4) Thanks [@jxom](https://github.com/jxom)! - Added the following chains to the `wagmi/chains` entrypoint: + + - Aurora – thanks @salil-naik + - Bronos – thanks @chedetinaveen + - Canto – thanks @tster + - Celo – thanks @aaronmgdr + +- Updated dependencies [[`144a0e76`](https://github.com/wevm/wagmi/commit/144a0e76ef4bb9ba0650b5ffb9c63f95329819a4), [`144a0e76`](https://github.com/wevm/wagmi/commit/144a0e76ef4bb9ba0650b5ffb9c63f95329819a4)]: + - @wagmi/core@0.9.1 + +## 0.11.0 + +### Minor Changes + +- [#1732](https://github.com/wevm/wagmi/pull/1732) [`01e21897`](https://github.com/wevm/wagmi/commit/01e2189747a5c22dc758c6d719b4145adc2a643c) Thanks [@tmm](https://github.com/tmm)! - Bumped minimum TypeScript version to typescript@>=4.9.4. TypeScript 5.0 is coming soon and has some great features we are excited to bring into wagmi. To prepare for this, update your TypeScript version to 4.9.4 or higher. There are likely no [breaking changes](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-4-9.html#correctness-fixes-and-breaking-changes) if you are coming from typescript@4.7.x || typescript@4.8.x. + +### Patch Changes + +- Updated dependencies [[`01e21897`](https://github.com/wevm/wagmi/commit/01e2189747a5c22dc758c6d719b4145adc2a643c)]: + - @wagmi/core@0.9.0 + +## 0.10.15 + +### Patch Changes + +- [#1718](https://github.com/wevm/wagmi/pull/1718) [`e62b5ef8`](https://github.com/wevm/wagmi/commit/e62b5ef8aaa8063abb5264790768899ea35bbd31) Thanks [@tmm](https://github.com/tmm)! - Updated references + +- Updated dependencies [[`e62b5ef8`](https://github.com/wevm/wagmi/commit/e62b5ef8aaa8063abb5264790768899ea35bbd31)]: + - @wagmi/core@0.8.19 + +## 0.10.14 + +### Patch Changes + +- [#1708](https://github.com/wevm/wagmi/pull/1708) [`07fc3801`](https://github.com/wevm/wagmi/commit/07fc3801fa13c2cb5f7cf9b86ba8320b05a6a135) Thanks [@jxom](https://github.com/jxom)! - Updated `references/` submodule. + +- Updated dependencies [[`07fc3801`](https://github.com/wevm/wagmi/commit/07fc3801fa13c2cb5f7cf9b86ba8320b05a6a135)]: + - @wagmi/core@0.8.18 + +## 0.10.13 + +### Patch Changes + +- [#1705](https://github.com/wevm/wagmi/pull/1705) [`9ff797dc`](https://github.com/wevm/wagmi/commit/9ff797dcb979dc86b798a432b74c98598165430d) Thanks [@jxom](https://github.com/jxom)! - Added the following chains to the `wagmi/chains` entrypoint: + + - `crossbell` (thanks @Songkeys) + - `filecoin` & `filecoinHyperspace` (thanks @neil0x46dc) + - `gnosisChiado` (thanks @theNvN) + - `metis` & `metisGoerli` (thanks @CookedCookee) + +- Updated dependencies [[`9ff797dc`](https://github.com/wevm/wagmi/commit/9ff797dcb979dc86b798a432b74c98598165430d)]: + - @wagmi/core@0.8.17 + +## 0.10.12 + +### Patch Changes + +- [#1699](https://github.com/wevm/wagmi/pull/1699) [`2f1e7950`](https://github.com/wevm/wagmi/commit/2f1e7950e55550d9b50ef5ccb97cb609f4af39b1) Thanks [@tmm](https://github.com/tmm)! - Added public RPC URL property to Chain + +- Updated dependencies [[`2f1e7950`](https://github.com/wevm/wagmi/commit/2f1e7950e55550d9b50ef5ccb97cb609f4af39b1)]: + - @wagmi/core@0.8.16 + +## 0.10.11 + +### Patch Changes + +- [#1685](https://github.com/wevm/wagmi/pull/1685) [`917f5bc1`](https://github.com/wevm/wagmi/commit/917f5bc1fad578e35a8c6ee787e339bfdc156bab) Thanks [@jxom](https://github.com/jxom)! - Replaced qrcodemodal with web3modal for the WalletConnect v2 Connector. + +- Updated dependencies [[`917f5bc1`](https://github.com/wevm/wagmi/commit/917f5bc1fad578e35a8c6ee787e339bfdc156bab)]: + - @wagmi/core@0.8.15 + +## 0.10.10 + +### Patch Changes + +- [#1648](https://github.com/wevm/wagmi/pull/1648) [`a2db9170`](https://github.com/wevm/wagmi/commit/a2db91709720161cd70eeb5e84dd78433264f0a3) Thanks [@tmm](https://github.com/tmm)! - Exported internal type. + +## 0.10.9 + +### Patch Changes + +- [#1646](https://github.com/wevm/wagmi/pull/1646) [`fcdbe353`](https://github.com/wevm/wagmi/commit/fcdbe3531e6d05cda4a4a511bae1ad4c9e426d88) Thanks [@jxom](https://github.com/jxom)! - Upgraded `zustand` to v4.3.1. + +- Updated dependencies [[`fcdbe353`](https://github.com/wevm/wagmi/commit/fcdbe3531e6d05cda4a4a511bae1ad4c9e426d88)]: + - @wagmi/core@0.8.14 + +## 0.10.8 + +### Patch Changes + +- [#1639](https://github.com/wevm/wagmi/pull/1639) [`c6869f06`](https://github.com/wevm/wagmi/commit/c6869f0604fffb197752a08256f31db77f52e746) Thanks [@jxom](https://github.com/jxom)! - Added `isRainbow` flag to `InjectedConnector`. + +- Updated dependencies [[`c6869f06`](https://github.com/wevm/wagmi/commit/c6869f0604fffb197752a08256f31db77f52e746)]: + - @wagmi/core@0.8.13 + +## 0.10.7 + +### Patch Changes + +- [#1636](https://github.com/wevm/wagmi/pull/1636) [`025f6771`](https://github.com/wevm/wagmi/commit/025f6771b32ff7eed22f527be81c5141ddaf9c3d) Thanks [@DanielSinclair](https://github.com/DanielSinclair)! - Added `isRainbow` flag to injected `window.ethereum` types. + +- Updated dependencies [[`025f6771`](https://github.com/wevm/wagmi/commit/025f6771b32ff7eed22f527be81c5141ddaf9c3d)]: + - @wagmi/core@0.8.12 + +## 0.10.6 + +### Patch Changes + +- [#1623](https://github.com/wevm/wagmi/pull/1623) [`c97a4bc5`](https://github.com/wevm/wagmi/commit/c97a4bc5df422dc9a9d3d8bac0261ec6933ce15b) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `useSigner` would not update on account change. + +## 0.10.5 + +### Patch Changes + +- [#1621](https://github.com/wevm/wagmi/pull/1621) [`5812b590`](https://github.com/wevm/wagmi/commit/5812b5909277bf2862cb57a31d52465b47291410) Thanks [@tmm](https://github.com/tmm)! - Bumped @wagmi/connectors + +- Updated dependencies [[`5812b590`](https://github.com/wevm/wagmi/commit/5812b5909277bf2862cb57a31d52465b47291410)]: + - @wagmi/core@0.8.11 + +## 0.10.4 + +### Patch Changes + +- [#1607](https://github.com/wevm/wagmi/pull/1607) [`49a41357`](https://github.com/wevm/wagmi/commit/49a41357f9ca39479bdf759f5998bc169a91ac87) Thanks [@tmm](https://github.com/tmm)! - Exported hook types. + +## 0.10.3 + +### Patch Changes + +- [#1598](https://github.com/wevm/wagmi/pull/1598) [`fc10ebe6`](https://github.com/wevm/wagmi/commit/fc10ebe659dd5f3b7a8e00581f094652280a779b) Thanks [@jxom](https://github.com/jxom)! - Fixed CJS dependency version range + +- Updated dependencies [[`fc10ebe6`](https://github.com/wevm/wagmi/commit/fc10ebe659dd5f3b7a8e00581f094652280a779b)]: + - @wagmi/core@0.8.10 + +## 0.10.2 + +### Patch Changes + +- [#1593](https://github.com/wevm/wagmi/pull/1593) [`216d555c`](https://github.com/wevm/wagmi/commit/216d555c62bd95c3c7c8f8e20f7269f6c8504610) Thanks [@jxom](https://github.com/jxom)! - Added CJS escape hatch bundle under the "cjs" tag. + +- Updated dependencies [[`216d555c`](https://github.com/wevm/wagmi/commit/216d555c62bd95c3c7c8f8e20f7269f6c8504610)]: + - @wagmi/core@0.8.9 + +## 0.10.1 + +### Patch Changes + +- [#1573](https://github.com/wevm/wagmi/pull/1573) [`ef380d9c`](https://github.com/wevm/wagmi/commit/ef380d9c6d51ae0495b9c35925d2843c75d97fd4) Thanks [@tmm](https://github.com/tmm)! - Updated internal types. + +- Updated dependencies [[`ef380d9c`](https://github.com/wevm/wagmi/commit/ef380d9c6d51ae0495b9c35925d2843c75d97fd4)]: + - @wagmi/core@0.8.8 + +## 0.10.0 + +### Minor Changes + +- [#1470](https://github.com/wevm/wagmi/pull/1470) [`3a1a6c9f`](https://github.com/wevm/wagmi/commit/3a1a6c9fe5db5c360adfd116f9a03a1238b5720c) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The `useSigner` hook now always returns `undefined` when no signer is present. Previously, it returned `null`. + + When no signer is present, the hook will be in an `"idle"` status. + +### Patch Changes + +- [#1470](https://github.com/wevm/wagmi/pull/1470) [`3a1a6c9f`](https://github.com/wevm/wagmi/commit/3a1a6c9fe5db5c360adfd116f9a03a1238b5720c) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `useSigner` would broadcast to other `useSigner`s unnecessarily. + +- [#1470](https://github.com/wevm/wagmi/pull/1470) [`3a1a6c9f`](https://github.com/wevm/wagmi/commit/3a1a6c9fe5db5c360adfd116f9a03a1238b5720c) Thanks [@jxom](https://github.com/jxom)! - The `WalletConnectConnector` now supports WalletConnect v2. + + It can be enabled by setting `version` to `'2'` and supplying a [WalletConnect Cloud `projectId`](https://cloud.walletconnect.com/sign-in). + +- [#1570](https://github.com/wevm/wagmi/pull/1570) [`216f585b`](https://github.com/wevm/wagmi/commit/216f585be8a9e3a56e3243f49ccd54d655b5a6dd) Thanks [@jxom](https://github.com/jxom)! - Added `useWatchPendingTransactions` + +- Updated dependencies [[`216f585b`](https://github.com/wevm/wagmi/commit/216f585be8a9e3a56e3243f49ccd54d655b5a6dd), [`3a1a6c9f`](https://github.com/wevm/wagmi/commit/3a1a6c9fe5db5c360adfd116f9a03a1238b5720c)]: + - @wagmi/core@0.8.7 + +## 0.9.6 + +### Patch Changes + +- [#1539](https://github.com/wevm/wagmi/pull/1539) [`732da004`](https://github.com/wevm/wagmi/commit/732da0042c7e28091b2e36a484ea8239971306f5) Thanks [@0xFlicker](https://github.com/0xFlicker)! - All Providers (ie. Alchemy, Infura, Public) now use the ENS Registry address on the wagmi `Chain` object (`chain.contracts.ensRegistry`). + +- [#1574](https://github.com/wevm/wagmi/pull/1574) [`ecde3d10`](https://github.com/wevm/wagmi/commit/ecde3d1029ccdf90e2853ba0e9ae4f5f4ebb9c4c) Thanks [@jxom](https://github.com/jxom)! - Added the following chains: + + - `iotex` + - `iotexTestnet` + - `zkSync` + - `zkSyncTestnet` + +- Updated dependencies [[`732da004`](https://github.com/wevm/wagmi/commit/732da0042c7e28091b2e36a484ea8239971306f5), [`ecde3d10`](https://github.com/wevm/wagmi/commit/ecde3d1029ccdf90e2853ba0e9ae4f5f4ebb9c4c)]: + - @wagmi/core@0.8.6 + +## 0.9.5 + +### Patch Changes + +- [#1542](https://github.com/wevm/wagmi/pull/1542) [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549) Thanks [@jxom](https://github.com/jxom)! - Added the following chains: + + - `evmos` + - `evmosTestnet` + - `gnosis` + +- [#1542](https://github.com/wevm/wagmi/pull/1542) [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549) Thanks [@jxom](https://github.com/jxom)! - Updated Goerli symbol to `"ETH"`. + +- [#1542](https://github.com/wevm/wagmi/pull/1542) [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549) Thanks [@jxom](https://github.com/jxom)! - Updated Arbitrum Goerli RPC and Block Explorer. + +- [#1542](https://github.com/wevm/wagmi/pull/1542) [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where connecting to MetaMask may return with a stale address. + +- [#1542](https://github.com/wevm/wagmi/pull/1542) [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549) Thanks [@jxom](https://github.com/jxom)! - Removed ENS registry for Sepolia. + +- Updated dependencies [[`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549), [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549), [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549), [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549), [`731b3b73`](https://github.com/wevm/wagmi/commit/731b3b733c6a093d1693d49de601705b7c730549)]: + - @wagmi/core@0.8.5 + +## 0.9.4 + +### Patch Changes + +- [#1508](https://github.com/wevm/wagmi/pull/1508) [`0b50b62f`](https://github.com/wevm/wagmi/commit/0b50b62f7389619e429509a3e337e451e823b059) Thanks [@jxom](https://github.com/jxom)! - Updated `@wagmi/chains` to `0.1.3`. + +- [#1507](https://github.com/wevm/wagmi/pull/1507) [`7a083bcf`](https://github.com/wevm/wagmi/commit/7a083bcf31d671817a4da2f40fb2160a1ba9d7b7) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `useBlockNumber` would return data when `watch` is enabled and `enabled` is falsy. + +- [#1504](https://github.com/wevm/wagmi/pull/1504) [`11b8b794`](https://github.com/wevm/wagmi/commit/11b8b794fbfd4a2b40f39962e2758e9fbf48cb54) Thanks [@tmm](https://github.com/tmm)! - Converted ethers custom "ACTION_REJECTED" error to standard RPC Error. + +- Updated dependencies [[`0b50b62f`](https://github.com/wevm/wagmi/commit/0b50b62f7389619e429509a3e337e451e823b059), [`11b8b794`](https://github.com/wevm/wagmi/commit/11b8b794fbfd4a2b40f39962e2758e9fbf48cb54)]: + - @wagmi/core@0.8.4 + +## 0.9.3 + +### Patch Changes + +- [#1431](https://github.com/wevm/wagmi/pull/1431) [`af28f8f9`](https://github.com/wevm/wagmi/commit/af28f8f9cfc227e7c391927fdb934183edb5c2dc) Thanks [@jxom](https://github.com/jxom)! - Re-export connectors from `@wagmi/connectors` + +- [#1431](https://github.com/wevm/wagmi/pull/1431) [`af28f8f9`](https://github.com/wevm/wagmi/commit/af28f8f9cfc227e7c391927fdb934183edb5c2dc) Thanks [@jxom](https://github.com/jxom)! - Added `LedgerConnector` connector + +- Updated dependencies [[`af28f8f9`](https://github.com/wevm/wagmi/commit/af28f8f9cfc227e7c391927fdb934183edb5c2dc), [`af28f8f9`](https://github.com/wevm/wagmi/commit/af28f8f9cfc227e7c391927fdb934183edb5c2dc)]: + - @wagmi/core@0.8.3 + +## 0.9.2 + +### Patch Changes + +- [#1442](https://github.com/wevm/wagmi/pull/1442) [`cde15289`](https://github.com/wevm/wagmi/commit/cde152899c758dea10787412b0aef669ed7202b2) Thanks [@0xproflupin](https://github.com/0xproflupin)! - Added Phantom wallet support to `InjectedConnector` + +- [#1448](https://github.com/wevm/wagmi/pull/1448) [`c6075f3a`](https://github.com/wevm/wagmi/commit/c6075f3a16885d850ad2656272351f9517c9f67b) Thanks [@tmm](https://github.com/tmm)! - Updated [ABIType](https://github.com/wevm/abitype) version. + +- [#1444](https://github.com/wevm/wagmi/pull/1444) [`310a8bc4`](https://github.com/wevm/wagmi/commit/310a8bc428ce4e7f68377f581b45dcdd64381cce) Thanks [@jxom](https://github.com/jxom)! - Assert that a `connector` exists before invoking the callback in `watchSigner`. + +- [#1434](https://github.com/wevm/wagmi/pull/1434) [`100e2a3b`](https://github.com/wevm/wagmi/commit/100e2a3b22f4602716554487b1d98738e053be76) Thanks [@tmm](https://github.com/tmm)! - Updated `MockConnector` `chainId` behavior to default to first chain from `chains` if not provided in `options`. + +- Updated dependencies [[`cde15289`](https://github.com/wevm/wagmi/commit/cde152899c758dea10787412b0aef669ed7202b2), [`c6075f3a`](https://github.com/wevm/wagmi/commit/c6075f3a16885d850ad2656272351f9517c9f67b), [`310a8bc4`](https://github.com/wevm/wagmi/commit/310a8bc428ce4e7f68377f581b45dcdd64381cce), [`100e2a3b`](https://github.com/wevm/wagmi/commit/100e2a3b22f4602716554487b1d98738e053be76)]: + - @wagmi/core@0.8.2 + +## 0.9.1 + +### Patch Changes + +- [#1437](https://github.com/wevm/wagmi/pull/1437) [`c34a3dc6`](https://github.com/wevm/wagmi/commit/c34a3dc6396e6473d9f0505fad88ec910f8f5275) Thanks [@jxom](https://github.com/jxom)! - Omitted `"EIP712Domain"` type from `signTypedData` `types` arg since ethers throws an [internal error](https://github.com/ethers-io/ethers.js/blob/c80fcddf50a9023486e9f9acb1848aba4c19f7b6/packages/hash/src.ts/typed-data.ts#L466) if you include it. + +- [#1445](https://github.com/wevm/wagmi/pull/1445) [`51dd53cb`](https://github.com/wevm/wagmi/commit/51dd53cba3fe0f79fa1393270b738194577ddf54) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where the wagmi client wouldn't rehydrate the store in local storage when `autoConnect` is truthy. + +- Updated dependencies [[`c34a3dc6`](https://github.com/wevm/wagmi/commit/c34a3dc6396e6473d9f0505fad88ec910f8f5275), [`51dd53cb`](https://github.com/wevm/wagmi/commit/51dd53cba3fe0f79fa1393270b738194577ddf54)]: + - @wagmi/core@0.8.1 + +## 0.9.0 + +### Minor Changes + +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: With the introduction of the [`wagmi/chains` entrypoint](/react/chains#wagmichains), `wagmi` no longer exports the following: + + - `chain` + - `allChains` + - `defaultChains` + - `defaultL2Chains` + - `chainId` + - `etherscanBlockExplorers` + - `alchemyRpcUrls`, `infuraRpcUrls`, `publicRpcUrls` + + Read below for migration steps. + + #### Removed `chain` + + The `chain` export has been removed. `wagmi` now only exports the `mainnet` & `goerli` chains. If you need to use an alternative chain (`polygon`, `optimism`, etc), you will need to import it from the [`wagmi/chains` entrypoint](/react/chains#wagmichains). + + ```diff + import { + - chain + configureChains + } from 'wagmi' + + import { mainnet, polygon, optimism } from 'wagmi/chains' + + const { ... } = configureChains( + - [chain.mainnet, chain.polygon, chain.optimism], + + [mainnet, polygon, optimism], + { + ... + } + ) + ``` + + #### Removed `allChains` + + The `allChains` export has been removed. If you need a list of all chains, you can utilize [`wagmi/chains` entrypoint](/react/chains#wagmichains). + + ```diff + - import { allChains } from 'wagmi' + + import * as allChains from 'wagmi/chains' + + const { ... } = configureChains(allChains, ...) + ``` + + #### Removed `defaultChains` & `defaultL2Chains` + + The `defaultChains` & `defaultL2Chains` exports have been removed. If you still need the `defaultChains` or `defaultL2Chains` exports, you can build them yourself: + + ```diff + - import { defaultChains } from 'wagmi' + + import { mainnet, goerli } from 'wagmi/chains' + + + const defaultChains = [mainnet, goerli] + ``` + + > The `defaultChains` export was previously populated with `mainnet` & `goerli`. + + ```diff + - import { defaultL2Chains } from 'wagmi' + + import { + + arbitrum, + + arbitrumGoerli, + + polygon, + + polygonMumbai, + + optimism, + + optimismGoerli + + } from 'wagmi/chains' + + + const defaultL2Chains = [ + + arbitrum, + + arbitrumGoerli, + + polygon, + + polygonMumbai, + + optimism + + optimismGoerli + + ] + ``` + + > The `defaultL2Chains` export was previously populated with `arbitrum` & `optimism`. + + #### Removed `chainId` + + The `chainId` export has been removed. You can extract a chain ID from the chain itself. + + ```diff + - import { chainId } from 'wagmi' + + import { mainnet, polygon, optimism } from 'wagmi/chains' + + -const mainnetChainId = chainId.mainnet + -const polygonChainId = chainId.polygon + -const optimismChainId = chainId.optimism + +const mainnetChainId = mainnet.chainId + +const polygonChainId = polygon.chainId + +const optimismChainId = optimism.chainId + ``` + + #### Removed `etherscanBlockExplorers` + + The `etherscanBlockExplorers` export has been removed. You can extract a block explorer from the chain itself. + + ```diff + - import { etherscanBlockExplorers } from 'wagmi' + + import { mainnet, polygon, optimism } from 'wagmi/chains' + + -const mainnetEtherscanBlockExplorer = etherscanBlockExplorers.mainnet + -const polygonEtherscanBlockExplorer = etherscanBlockExplorers.polygon + -const optimismEtherscanBlockExplorer = etherscanBlockExplorers.optimism + +const mainnetEtherscanBlockExplorer = mainnet.blockExplorer + +const polygonEtherscanBlockExplorer = polygon.blockExplorer + +const optimismEtherscanBlockExplorer = optimism.blockExplorer + ``` + + #### Removed `alchemyRpcUrls`, `infuraRpcUrls` & `publicRpcUrls` + + The `alchemyRpcUrls`, `infuraRpcUrls` & `publicRpcUrls` exports have been removed. You can extract a RPC URL from the chain itself. + + ```diff + - import { alchemyRpcUrls, infuraRpcUrls, publicRpcUrls } from 'wagmi' + + import { mainnet } from 'wagmi/chains' + + -const mainnetAlchemyRpcUrl = alchemyRpcUrls.mainnet + -const mainnetInfuraRpcUrl = infuraRpcUrls.mainnet + -const mainnetOptimismRpcUrl = publicRpcUrls.mainnet + +const mainnetAlchemyRpcUrl = mainnet.rpcUrls.alchemy + +const mainnetInfuraRpcUrl = mainnet.rpcUrls.infura + +const mainnetOptimismRpcUrl = mainnet.rpcUrls.optimism + ``` + +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: the shape of the `Chain` type has been modified. + + #### RPC URLs + + The `rpcUrls` shape has changed to include an array of URLs, and also the transport method (`http` or `webSocket`): + + ```diff + type Chain = { + ... + rpcUrls: { + - [key: string]: string + + [key: string]: { + + http: string[] + + webSocket: string[] + + } + } + ... + } + ``` + + Note that you will also need to ensure that usage is migrated: + + ```diff + - const rpcUrl = mainnet.rpcUrls.alchemy + + const rpcUrl = mainnet.rpcUrls.alchemy.http[0] + ``` + + #### Contracts + + The `multicall` and `ens` attributes have been moved into the `contracts` object: + + ```diff + type Contract = { + address: Address + blockCreated?: number + } + + type Chain = { + ... + - multicall: Contract + - ens: Contract + + contracts: { + + multicall3: Contract + + ensRegistry: Contract + + } + ... + } + ``` + + Note that you will also need to ensure that usage is migrated: + + ```diff + - const multicallContract = mainnet.multicall + + const multicallContract = mainnet.contracts.multicall3 + ``` + +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: Removed the `wait` config option on `useWaitForTransaction`. Use the transaction `hash` instead. + + ```diff + const { data } = useWaitForTransaction({ + - wait: transaction.wait + + hash: transaction.hash + }) + ``` + +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - Updated errors to use `cause` instead of `internal` + +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - `useEnsResolver`'s result is no longer persisted by the query client since it cannot serialize its prototype methods. + +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: Changed `useWaitForTransaction` behavior to return an error if the transaction reverted. + +### Patch Changes + +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - `useWaitForTransaction` now throws an error for cancelled or replaced transactions. + +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - `useWaitForTransaction` now respects repriced (sped up) transactions. + +- [#1344](https://github.com/wevm/wagmi/pull/1344) [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652) Thanks [@jxom](https://github.com/jxom)! - Updated `@coinbase/wallet-sdk` to `^3.6.0`. + +- Updated dependencies [[`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652), [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652), [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652), [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652), [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652), [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652), [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652), [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652), [`57a19374`](https://github.com/wevm/wagmi/commit/57a1937464a4ccf72719fc86c38d1734f6306652)]: + - @wagmi/core@0.8.0 + +## 0.8.10 + +### Patch Changes + +- [#1411](https://github.com/wevm/wagmi/pull/1411) [`659be184`](https://github.com/wevm/wagmi/commit/659be1840c613ce9f7aca9ac96694c4f60da4a66) Thanks [@tmm](https://github.com/tmm)! - Fixed issue where block invalidation was not properly disabled when setting `enabled: false`. + +- [#1409](https://github.com/wevm/wagmi/pull/1409) [`b557b3ee`](https://github.com/wevm/wagmi/commit/b557b3ee4fc58217e61d860fc3d1109d2abc813e) Thanks [@jxom](https://github.com/jxom)! - Ensure that `useSyncExternalStoreWithTracked` rerenders when no values are being tracked. + +- Updated dependencies [[`659be184`](https://github.com/wevm/wagmi/commit/659be1840c613ce9f7aca9ac96694c4f60da4a66)]: + - @wagmi/core@0.7.9 + +## 0.8.9 + +### Patch Changes + +- [#1406](https://github.com/wevm/wagmi/pull/1406) [`4f18c450`](https://github.com/wevm/wagmi/commit/4f18c450a4d7952bfcfa6c533348ffbe55893d3c) Thanks [@tmm](https://github.com/tmm)! - Function for selecting the [EIP-1193](https://eips.ethereum.org/EIPS/eip-1193) Ethereum Provider to target. Defaults to `() => typeof window !== 'undefined' ? window.ethereum : undefined`. + + ```ts + import { InjectedConnector } from "wagmi/connectors/injected"; + + const connector = new InjectedConnector({ + options: { + name: "My Injected Wallet", + getProvider: () => + typeof window !== "undefined" ? window.myInjectedWallet : undefined, + }, + }); + ``` + +- Updated dependencies [[`4f18c450`](https://github.com/wevm/wagmi/commit/4f18c450a4d7952bfcfa6c533348ffbe55893d3c)]: + - @wagmi/core@0.7.8 + +## 0.8.8 + +### Patch Changes + +- [#1386](https://github.com/wevm/wagmi/pull/1386) [`206a2adb`](https://github.com/wevm/wagmi/commit/206a2adbb4ee5149a364543b34612050ccf78c21) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `persister` would still use `window.localStorage` instead of the wagmi `storage`. + +- [#1376](https://github.com/wevm/wagmi/pull/1376) [`a70a9528`](https://github.com/wevm/wagmi/commit/a70a9528f93f4d7fea28b7652751dfef2dcacf9b) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where `switchChain` on `WalletConnectConnector` would not resolve. + +- [#1392](https://github.com/wevm/wagmi/pull/1392) [`88afc849`](https://github.com/wevm/wagmi/commit/88afc84978afe9689ab7364633e4422ecd7699ea) Thanks [@tmm](https://github.com/tmm)! - Added check for active connector when connecting + +- Updated dependencies [[`206a2adb`](https://github.com/wevm/wagmi/commit/206a2adbb4ee5149a364543b34612050ccf78c21), [`a70a9528`](https://github.com/wevm/wagmi/commit/a70a9528f93f4d7fea28b7652751dfef2dcacf9b), [`206a2adb`](https://github.com/wevm/wagmi/commit/206a2adbb4ee5149a364543b34612050ccf78c21), [`88afc849`](https://github.com/wevm/wagmi/commit/88afc84978afe9689ab7364633e4422ecd7699ea)]: + - @wagmi/core@0.7.7 + +## 0.8.7 + +### Patch Changes + +- [#1384](https://github.com/wevm/wagmi/pull/1384) [`027e88d6`](https://github.com/wevm/wagmi/commit/027e88d6e5f8d028d46ee78aec8500701e0173d9) Thanks [@tmm](https://github.com/tmm)! - Fixed issue reconnecting after disconnect with `MetaMaskConnector` in MetaMask mobile browser. + +- [#1377](https://github.com/wevm/wagmi/pull/1377) [`089c4f3b`](https://github.com/wevm/wagmi/commit/089c4f3b3b8ce5cf7807f144410e2f64b72e0580) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where transforming `useContractRead`, `useContractReads` or `useContractInfiniteReads`'s return data via `select` wasn't inferring the type. + +- Updated dependencies [[`027e88d6`](https://github.com/wevm/wagmi/commit/027e88d6e5f8d028d46ee78aec8500701e0173d9)]: + - @wagmi/core@0.7.6 + +## 0.8.6 + +### Patch Changes + +- [`1169914a`](https://github.com/wevm/wagmi/commit/1169914a0f0ad2810ca1c536b1f1bc6c20f2c1be) Thanks [@jxom](https://github.com/jxom)! - Use `get_accounts` for `getSigner` in InjectedConnector + +- Updated dependencies [[`1169914a`](https://github.com/wevm/wagmi/commit/1169914a0f0ad2810ca1c536b1f1bc6c20f2c1be)]: + - @wagmi/core@0.7.5 + +## 0.8.5 + +### Patch Changes + +- [#1282](https://github.com/wevm/wagmi/pull/1282) [`6d286c9e`](https://github.com/wevm/wagmi/commit/6d286c9ed6f64a9872352904d4d171a6bc1c7a96) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `useContractRead` would perform an unnecessary rerender if another hook had `watch` enabled. + +## 0.8.4 + +### Patch Changes + +- [#1309](https://github.com/wevm/wagmi/pull/1309) [`1f4a4261`](https://github.com/wevm/wagmi/commit/1f4a4261247b1d3a90e3123157bc851a35d49b9c) Thanks [@tmm](https://github.com/tmm)! - Fixed internal type + +- Updated dependencies [[`1f4a4261`](https://github.com/wevm/wagmi/commit/1f4a4261247b1d3a90e3123157bc851a35d49b9c)]: + - @wagmi/core@0.7.4 + +## 0.8.3 + +### Patch Changes + +- [#1294](https://github.com/wevm/wagmi/pull/1294) [`b2f88949`](https://github.com/wevm/wagmi/commit/b2f88949f32aabaf13f318472648cd51a8b7f2e7) Thanks [@tmm](https://github.com/tmm)! - Set `abi` return type value for `usePrepareContractWrite` as more permissive when not inferrable as `Abi`. + +- Updated dependencies [[`b2f88949`](https://github.com/wevm/wagmi/commit/b2f88949f32aabaf13f318472648cd51a8b7f2e7)]: + - @wagmi/core@0.7.3 + +## 0.8.2 + +### Patch Changes + +- [`e9f806b6`](https://github.com/wevm/wagmi/commit/e9f806b652ba62effb3ddac464815e447fc287f6) Thanks [@tmm](https://github.com/tmm)! - Bumped abitype and zustand versions. + +- [#1290](https://github.com/wevm/wagmi/pull/1290) [`88450052`](https://github.com/wevm/wagmi/commit/88450052b9f070fe53e18d84f72918c410b961f0) Thanks [@tmm](https://github.com/tmm)! - Fixed `useAccount`'s' `onConnect` callback `isReconnected` flag. + +- Updated dependencies [[`e9f806b6`](https://github.com/wevm/wagmi/commit/e9f806b652ba62effb3ddac464815e447fc287f6)]: + - @wagmi/core@0.7.2 + +## 0.8.1 + +### Patch Changes + +- [#1272](https://github.com/wevm/wagmi/pull/1272) [`1f7fc41`](https://github.com/wevm/wagmi/commit/1f7fc419f7960bbdc51dfa85c2f33b89f1ecc1bf) Thanks [@tmm](https://github.com/tmm)! - Fixed ethers import path + +- Updated dependencies [[`1f7fc41`](https://github.com/wevm/wagmi/commit/1f7fc419f7960bbdc51dfa85c2f33b89f1ecc1bf)]: + - @wagmi/core@0.7.1 + +## 0.8.0 + +### Minor Changes + +- [#1202](https://github.com/wevm/wagmi/pull/1202) [`9bf56af`](https://github.com/wevm/wagmi/commit/9bf56af3c30bdb80abb1e785c002e00986fadfb2) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: Removed the following deprecated chains: + + - `ropsten` + - `rinkeby` + - `kovan` + - `optimismKovan` + - `arbitrumRinkeby` + + If you feel you still need to include one of these testnets in your application, you will have to define it manually: + + ```diff + -import { rinkeby } from 'wagmi' + +import { Chain } from 'wagmi' + + +export const rinkeby: Chain = { + + id: 4, + + name: 'Rinkeby', + + network: 'rinkeby', + + nativeCurrency: { name: 'Rinkeby Ether', symbol: 'ETH', decimals: 18 }, + + rpcUrls: { + + alchemy: 'https://eth-rinkeby.alchemyapi.io/v2', + + default: 'https://rpc.ankr.com/eth_rinkeby', + + infura: 'https://rinkeby.infura.io/v3', + + public: 'https://rpc.ankr.com/eth_rinkeby', + + }, + + blockExplorers: { + + etherscan: 'https://rinkeby.etherscan.io', + + default: 'https://rinkeby.etherscan.io', + + }, + + ens: { + + address: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e', + + }, + + multicall: { + + address: '0xca11bde05977b3631167028862be2a173976ca11', + + blockCreated: 10299530, + + }, + + testnet: true, + } + ``` + + You can reference these removed chains [here](https://github.com/wevm/wagmi/blob/389765f7d9af063ab0df07389a2bbfbc10a41060/packages/core/src/constants/chains.ts). + +- [#1202](https://github.com/wevm/wagmi/pull/1202) [`9bf56af`](https://github.com/wevm/wagmi/commit/9bf56af3c30bdb80abb1e785c002e00986fadfb2) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: Made `apiKey` required on `infuraProvider` and `alchemyProvider`. + + ```diff + import { configureChains } from 'wagmi' + + const config = configureChains(defaultChains, [ + - alchemyProvider(), + + alchemyProvider({ apiKey: process.env.ALCHEMY_API_KEY }) + ]) + ``` + + You can find your Alchemy API key from the [Alchemy Dashboard](https://dashboard.alchemyapi.io/), or your Infura API key from the [Infura Dashboard](https://infura.io/login). + +- [#1202](https://github.com/wevm/wagmi/pull/1202) [`9bf56af`](https://github.com/wevm/wagmi/commit/9bf56af3c30bdb80abb1e785c002e00986fadfb2) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: `addressOrName` renamed to `address` for `useBalance` and `useEnsAvatar`. + + ```diff + const result = useBalance({ + - addressOrName: '0x…', + + address: '0x…', + }) + ``` + + If you were using an ENS name instead of an address, you can resolve the name to an address before passing it to the action. + + ```diff + + const { data: address } = useEnsAddress({ name: 'example.eth' }) + const result = useBalance({ + - addressOrName: 'example.eth', + + address, + }) + ``` + +- [#1202](https://github.com/wevm/wagmi/pull/1202) [`9bf56af`](https://github.com/wevm/wagmi/commit/9bf56af3c30bdb80abb1e785c002e00986fadfb2) Thanks [@tmm](https://github.com/tmm)! - Removed CommonJS support + +### Patch Changes + +- Updated dependencies [[`9bf56af`](https://github.com/wevm/wagmi/commit/9bf56af3c30bdb80abb1e785c002e00986fadfb2), [`9bf56af`](https://github.com/wevm/wagmi/commit/9bf56af3c30bdb80abb1e785c002e00986fadfb2), [`9bf56af`](https://github.com/wevm/wagmi/commit/9bf56af3c30bdb80abb1e785c002e00986fadfb2), [`9bf56af`](https://github.com/wevm/wagmi/commit/9bf56af3c30bdb80abb1e785c002e00986fadfb2)]: + - @wagmi/core@0.7.0 + +## 0.7.15 + +### Patch Changes + +- [#1262](https://github.com/wevm/wagmi/pull/1262) [`45e2ca4`](https://github.com/wevm/wagmi/commit/45e2ca4d1f33a7b1165c387d420b8d47f4f66935) Thanks [@tmm](https://github.com/tmm)! - Added default for `structuralSharing` for `useContractRead`, `useContractReads`, and `useContractInfiniteReads`. + +## 0.7.14 + +### Patch Changes + +- [#1260](https://github.com/wevm/wagmi/pull/1260) [`0e12f03`](https://github.com/wevm/wagmi/commit/0e12f0380442bccca9ed18991e783819778032fe) Thanks [@ilmpc](https://github.com/ilmpc)! - Deprecated `isDataEqual` option from and added `structuralSharing` option to `useContractRead`, `useContractReads`, and `useContractInfiniteReads`. + +## 0.7.13 + +### Patch Changes + +- [#1250](https://github.com/wevm/wagmi/pull/1250) [`ce2e0f4`](https://github.com/wevm/wagmi/commit/ce2e0f4a46b8fd1c509ead552012ef4c072a525b) Thanks [@tmm](https://github.com/tmm)! - Added support for Trust Wallet browser extension. + +- Updated dependencies [[`ce2e0f4`](https://github.com/wevm/wagmi/commit/ce2e0f4a46b8fd1c509ead552012ef4c072a525b)]: + - @wagmi/core@0.6.12 + +## 0.7.12 + +### Patch Changes + +- [#1234](https://github.com/wevm/wagmi/pull/1234) [`3ff9303`](https://github.com/wevm/wagmi/commit/3ff930349250f62137cca4ca3b382522882abf8a) Thanks [@tmm](https://github.com/tmm)! - Fixed issue with adding chain to wallet without block explorer URL. + +- Updated dependencies [[`3ff9303`](https://github.com/wevm/wagmi/commit/3ff930349250f62137cca4ca3b382522882abf8a)]: + - @wagmi/core@0.6.11 + +## 0.7.11 + +### Patch Changes + +- [#1232](https://github.com/wevm/wagmi/pull/1232) [`c0ca509`](https://github.com/wevm/wagmi/commit/c0ca509506dcf6d98b058df549dc761c9a5f3d1c) Thanks [@tmm](https://github.com/tmm)! - Added validation to check that chain is configured for connector when accessing `Signer`. + +- Updated dependencies [[`c0ca509`](https://github.com/wevm/wagmi/commit/c0ca509506dcf6d98b058df549dc761c9a5f3d1c)]: + - @wagmi/core@0.6.10 + +## 0.7.10 + +### Patch Changes + +- [#1206](https://github.com/wevm/wagmi/pull/1206) [`15ff089`](https://github.com/wevm/wagmi/commit/15ff0896216abecf5967294ae5aeb26ea7fb480b) Thanks [@jxom](https://github.com/jxom)! - Added `scopeKey` as a configuration option to the Hooks which scope its cache to a given context. Hooks that have identical scope will share the same cache. + +- [#1207](https://github.com/wevm/wagmi/pull/1207) [`c73d463`](https://github.com/wevm/wagmi/commit/c73d463d65c9dbfcfe709187e47323a769589741) Thanks [@lvshaoping007](https://github.com/lvshaoping007)! - Added Kucoin wallet support to `InjectedConnector` + +- Updated dependencies [[`c73d463`](https://github.com/wevm/wagmi/commit/c73d463d65c9dbfcfe709187e47323a769589741)]: + - @wagmi/core@0.6.9 + +## 0.7.9 + +### Patch Changes + +- [#1201](https://github.com/wevm/wagmi/pull/1201) [`9a07efa`](https://github.com/wevm/wagmi/commit/9a07efaa397d3ba03f2edbe527c359f21e22139a) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where non-checksum addresses did not resolve with an ENS name + +- [#1132](https://github.com/wevm/wagmi/pull/1132) [`d41c0d6`](https://github.com/wevm/wagmi/commit/d41c0d650f8c0e54145758685b7604b8909d7ae0) Thanks [@toniocodo](https://github.com/toniocodo)! - Added ERC-4626 ABI + +- Updated dependencies [[`d41c0d6`](https://github.com/wevm/wagmi/commit/d41c0d650f8c0e54145758685b7604b8909d7ae0), [`9a07efa`](https://github.com/wevm/wagmi/commit/9a07efaa397d3ba03f2edbe527c359f21e22139a)]: + - @wagmi/core@0.6.8 + +## 0.7.8 + +### Patch Changes + +- [#1174](https://github.com/wevm/wagmi/pull/1174) [`196a458`](https://github.com/wevm/wagmi/commit/196a458f64141e8a9f39c1b1e1af5937f692cb39) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `client.chains` (active connector chains) would be populated when there is no active connector (disconnected user). + +- [#1176](https://github.com/wevm/wagmi/pull/1176) [`389765f`](https://github.com/wevm/wagmi/commit/389765f7d9af063ab0df07389a2bbfbc10a41060) Thanks [@jxom](https://github.com/jxom)! - Migrate away from Alchemy RPC URLs in the public RPC URL list + +- Updated dependencies [[`196a458`](https://github.com/wevm/wagmi/commit/196a458f64141e8a9f39c1b1e1af5937f692cb39), [`389765f`](https://github.com/wevm/wagmi/commit/389765f7d9af063ab0df07389a2bbfbc10a41060)]: + - @wagmi/core@0.6.7 + +## 0.7.7 + +### Patch Changes + +- [#1166](https://github.com/wevm/wagmi/pull/1166) [`6fbe910`](https://github.com/wevm/wagmi/commit/6fbe91080b54e33e8543e9638ff5089e749ada3f) Thanks [@jxom](https://github.com/jxom)! - Export the React entrypoint `Client` type instead of `@wagmi/core`'s `Client`. + +- [`81ce9e6`](https://github.com/wevm/wagmi/commit/81ce9e64d85f7d01370324c1a529988a0919894f) Thanks [@jxom](https://github.com/jxom)! - Add `isPortal` to injected MetaMask flags. + +- [`c2c0109`](https://github.com/wevm/wagmi/commit/c2c01096ef4cd0ffadbb49062969c208604c6194) Thanks [@jxom](https://github.com/jxom)! - Add etherscan block explorer to Optimism Goerli + +- Updated dependencies [[`81ce9e6`](https://github.com/wevm/wagmi/commit/81ce9e64d85f7d01370324c1a529988a0919894f), [`c2c0109`](https://github.com/wevm/wagmi/commit/c2c01096ef4cd0ffadbb49062969c208604c6194)]: + - @wagmi/core@0.6.6 + +## 0.7.6 + +### Patch Changes + +- [#1162](https://github.com/wevm/wagmi/pull/1162) [`30335b3`](https://github.com/wevm/wagmi/commit/30335b3199fb425e398e9c492b50c68d5e2ade7e) Thanks [@tmm](https://github.com/tmm)! - Fixed issue where non-indexed event parameter types were set to `null`. + +- [#1162](https://github.com/wevm/wagmi/pull/1162) [`30335b3`](https://github.com/wevm/wagmi/commit/30335b3199fb425e398e9c492b50c68d5e2ade7e) Thanks [@tmm](https://github.com/tmm)! - Fixed issue where `useContractReads` and `useContractInfiniteReads` types were slowing down TypeScript compiler. + +- Updated dependencies [[`30335b3`](https://github.com/wevm/wagmi/commit/30335b3199fb425e398e9c492b50c68d5e2ade7e), [`30335b3`](https://github.com/wevm/wagmi/commit/30335b3199fb425e398e9c492b50c68d5e2ade7e)]: + - @wagmi/core@0.6.5 + +## 0.7.5 + +### Patch Changes + +- [#1103](https://github.com/wevm/wagmi/pull/1103) [`651eda0`](https://github.com/wevm/wagmi/commit/651eda06384bd0955268427f898e9337b2dc5a31) Thanks [@tmm](https://github.com/tmm)! - Bumped `abitype` dependency. + +- Updated dependencies [[`651eda0`](https://github.com/wevm/wagmi/commit/651eda06384bd0955268427f898e9337b2dc5a31)]: + - @wagmi/core@0.6.4 + +## 0.7.4 + +### Patch Changes + +- [#1099](https://github.com/wevm/wagmi/pull/1099) [`748e617`](https://github.com/wevm/wagmi/commit/748e61719ad706acae057be903321ebe0c2e817e) Thanks [@jxom](https://github.com/jxom)! - Added `isFetchedAfterMount` to the return value of hooks. + + The `isFetchedAfterMount` will be truthy if the hook has fetched after the component has been mounted. This value can be utilized to not show the result if it has previously been cached. + +- [#1091](https://github.com/wevm/wagmi/pull/1091) [`a3aaf59`](https://github.com/wevm/wagmi/commit/a3aaf590e8e993017baa9a1ac50ecd63dd287caf) Thanks [@tmm](https://github.com/tmm)! - Fixed `useAccount` `onConnect`/`onDisconnect` from not firing when the account was already connected/disconnected. + +## 0.7.3 + +### Patch Changes + +- [#1086](https://github.com/wevm/wagmi/pull/1086) [`4e28d2a`](https://github.com/wevm/wagmi/commit/4e28d2ad4c2e6b3479b728563040b9529463cbcf) Thanks [@tmm](https://github.com/tmm)! - Exposed module types. + +- Updated dependencies [[`4e28d2a`](https://github.com/wevm/wagmi/commit/4e28d2ad4c2e6b3479b728563040b9529463cbcf)]: + - @wagmi/core@0.6.3 + +## 0.7.2 + +### Patch Changes + +- [#1080](https://github.com/wevm/wagmi/pull/1080) [`3be5e8b`](https://github.com/wevm/wagmi/commit/3be5e8b01e58ed40cc9dab7ef9533c0197cb74d0) Thanks [@tmm](https://github.com/tmm)! - Added `abitype` to `dependencies` so types ship correctly. + +- Updated dependencies [[`3be5e8b`](https://github.com/wevm/wagmi/commit/3be5e8b01e58ed40cc9dab7ef9533c0197cb74d0)]: + - @wagmi/core@0.6.2 + +## 0.7.1 + +### Patch Changes + +- [#1074](https://github.com/wevm/wagmi/pull/1074) [`8db807f`](https://github.com/wevm/wagmi/commit/8db807f16149aa278c2a7db9ee5245431db12173) Thanks [@IljaDaderko](https://github.com/IljaDaderko)! - Exported `EventListener` type + +- Updated dependencies [[`8db807f`](https://github.com/wevm/wagmi/commit/8db807f16149aa278c2a7db9ee5245431db12173)]: + - @wagmi/core@0.6.1 + +## 0.7.0 + +### Minor Changes + +- [#940](https://github.com/wevm/wagmi/pull/940) [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: `usePrepareContractWrite` now throws when a `chainId` is specified and the end-user is on a different chain id (the wrong network). + + If you wish to defer this check until the click handler is pressed, you can place `chainId` in `useContractWrite` instead: + + ```diff + import { usePrepareContractWrite, useContractWrite } from 'wagmi' + import { optimism } from 'wagmi/chains' + + // ... + + const { config } = usePrepareContractWrite({ + addressOrName: '0xaf0326d92b97df1221759476b072abfd8084f9be', + contractInterface: ['function mint()'], + functionName: 'mint', + }) + const { write } = useContractWrite({ + ...config, + + chainId: optimism.id + }) + + ``` + +- [#940](https://github.com/wevm/wagmi/pull/940) [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The `usePrepareSendTransaction` hook will now only run when the end-user is connected to their wallet. + + This is to reach parity with `usePrepareContractWrite`. + + If the end-user is not connected, then the `usePrepareSendTransaction` hook will remain idle. + +- [#940](https://github.com/wevm/wagmi/pull/940) [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: `usePrepareSendTransaction` now throws when a `chainId` is specified and the end-user is on a different chain id (the wrong network). + + If you wish to defer this check until the click handler is pressed, you can place `chainId` in `useContractWrite` instead: + + ```diff + import { usePrepareSendTransaction, useContractWrite } from 'wagmi' + import { optimism } from 'wagmi/chains' + + // ... + + const { config } = usePrepareSendTransaction({ + request: { + to: 'moxey.eth', + value: parseEther('1'), + }, + }) + const { sendTransaction } = useSendTransaction({ + ...config, + + chainId: optimism.id + }) + + ``` + +- [#941](https://github.com/wevm/wagmi/pull/941) [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: `useContractEvent` no longer accepts a `signerOrProvider` configuration option. + +- [#941](https://github.com/wevm/wagmi/pull/941) [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: `addressOrName` and `contractInterface` renamed to `address` and `abi` respectively for contract hooks: `useContract`, `useContractEvent`, `useContractRead`, `useContractReads`, `useContractInfiniteReads`, `useContractWrite`, `usePrepareContractWrite`. + + ```diff + import { useContractRead } from 'wagmi' + + const result = useContractRead({ + - addressOrName: '0x…', + + address: '0x…', + - contractInterface: […] as const, + + abi: […] as const, + functionName: 'balanceOf', + args: ['0x…'], + }) + ``` + + If you were using an ENS name instead of an address, you can resolve the name to an address before passing it to the action. + + ```diff + - import { useContractRead } from 'wagmi' + + import { useContractRead, useEnsAddress } from 'wagmi' + + + const { data: address} = useEnsAddress({ name: 'example.eth'}) + const result = useContractRead({ + - addressOrName: 'example.eth', + + address, + abi: […], + functionName: 'balanceOf', + args: ['0x…'], + }) + ``` + +- [#941](https://github.com/wevm/wagmi/pull/941) [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: Updated TypeScript generics for contract and typed data hooks. + + Adding a [const assertion](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-4.html#const-assertions) to `abi` allows TypeScript to infer `functionName`, `args`, `overrides`, and return types for functions, and `eventName` and `listener` types for events. + + ```diff + import { useContractRead } from 'wagmi' + + const result = useContractRead({ + address: '0x…', + - abi: […], + + abi: […] as const, + functionName: 'balanceOf', // will autocomplete and catch typos + args: ['0x…'], // inferred based on `abi`, `functionName`, `args` + }) + result.data // inferred based on `functionName` + ``` + + This works for the following actions: `useContractRead`, `useContractWrite`, `usePrepareContractWrite`, `useContractReads`, `useContractInfiniteReads`, and `useContractEvent`. + + Adding a [const assertion](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-4.html#const-assertions) to `useSignTypedData`'s config option, `types`, allows TypeScript to infer `value`. + + ```diff + import { useSignTypedData } from 'wagmi' + + const result = useSignTypedData({ + domain: { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', + }, + types: { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], + - }, + + } as const, + value: { // `value` is inferred based on `types` + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + }) + ``` + +- [#941](https://github.com/wevm/wagmi/pull/941) [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: Updated TypeScript version to `typescript@>=4.7.4`. + + `@wagmi/core` can now infer types based on [ABI](https://docs.soliditylang.org/en/v0.8.15/abi-spec.html#json) and [EIP-712](https://eips.ethereum.org/EIPS/eip-712) Typed Data definitions, giving you full end-to-end type-safety from your contracts to your frontend and incredible developer experience (e.g. autocomplete contract function names and catch misspellings, type contract function arguments, etc.). + + For this to work, you must upgrade to `typescript@>=4.7.4`. Why is TypeScript v4.7.4 or greater necessary? TypeScript 4.7.4 introduced the ability to [extend constraints on inferred type variables](https://devblogs.microsoft.com/typescript/announcing-typescript-4-7/#extends-constraints-on-infer-type-variables), which is used extensively to help narrow types for ABIs. Good news! When upgrading TypeScript from 4.6 to 4.7 there are likely no [breaking changes](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-4-7.html#breaking-changes) for your set up. + +- [#941](https://github.com/wevm/wagmi/pull/941) [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: Updated `paginatedIndexesConfig` `fn` parameter return type. `fn` now returns an array instead of a single object. + + ```diff + import { BigNumber } from 'ethers' + import { paginatedIndexesConfig, useContractInfiniteReads } from 'wagmi' + + useContractInfiniteReads({ + cacheKey: 'contracts', + ...paginatedIndexesConfig( + - (index) => ({ + + (index) => [{ + ...mlootContractConfig, + functionName: 'tokenURI', + args: [BigNumber.from(index)] as const, + - }), + + }], + { start: 0, perPage: 10, direction: 'increment' }, + ), + }) + ``` + +- [#941](https://github.com/wevm/wagmi/pull/941) [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: `args` config option must now be an array for the following hooks: `useContractRead`, `useContractWrite`, `usePrepareContractWrite`, `useContractReads`, and `useContractInfiniteReads`. + + ```diff + import { useContractRead } from 'wagmi' + + const { data } = useContractRead({ + address: '0x…', + abi: […], + functionName: 'balanceOf', + - args: '0x…', + + args: ['0x…'], + }) + ``` + +### Patch Changes + +- [#940](https://github.com/wevm/wagmi/pull/940) [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663) Thanks [@jxom](https://github.com/jxom)! - The `useSigner` hook now accepts an optional `chainId` to use for signer initialization as an argument. + + ```tsx + import { useSigner } from "wagmi"; + import { optimism } from "wagmi/core"; + + // ... + + useSigner({ chainId: optimism.id }); + ``` + +- [#1061](https://github.com/wevm/wagmi/pull/1061) [`a4ffe8b`](https://github.com/wevm/wagmi/commit/a4ffe8b25516d5504685ae94579da4cd8c409329) Thanks [@alecananian](https://github.com/alecananian)! - Added Arbitrum Goerli Arbiscan block explorer + +- [#1050](https://github.com/wevm/wagmi/pull/1050) [`73d4d47`](https://github.com/wevm/wagmi/commit/73d4d47bc679f4f9a1cf46010fe2bf858c9d0b5c) Thanks [@jxom](https://github.com/jxom)! - update dependencies + + - `@coinbase/wallet-sdk@3.5.3` + - `@tanstack/query-sync-storage-persister@4.10.1` + - `@tanstack/react-query@4.10.1` + - `@tanstack/react-query-persist-client@4.10.1` + - `@walletconnect/ethereum-provider@1.8.0` + +- [#1048](https://github.com/wevm/wagmi/pull/1048) [`ed13074`](https://github.com/wevm/wagmi/commit/ed130747c0f28c1d9980a1328883e4000a60455e) Thanks [@Max-3-7](https://github.com/Max-3-7)! - Added support for Avalanche core wallet + +- [#1046](https://github.com/wevm/wagmi/pull/1046) [`ab9ecaa`](https://github.com/wevm/wagmi/commit/ab9ecaa74dfa4324279e167dd7e348319ef7d35d) Thanks [@jxom](https://github.com/jxom)! - make ethers block format validator compatible with Celo + +- Updated dependencies [[`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663), [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663), [`a4ffe8b`](https://github.com/wevm/wagmi/commit/a4ffe8b25516d5504685ae94579da4cd8c409329), [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663), [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c), [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663), [`ed13074`](https://github.com/wevm/wagmi/commit/ed130747c0f28c1d9980a1328883e4000a60455e), [`b6cb8f4`](https://github.com/wevm/wagmi/commit/b6cb8f4cd15eb13073bc7e9ecb4bfa2c261c0663), [`ab9ecaa`](https://github.com/wevm/wagmi/commit/ab9ecaa74dfa4324279e167dd7e348319ef7d35d), [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c), [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c), [`73d4d47`](https://github.com/wevm/wagmi/commit/73d4d47bc679f4f9a1cf46010fe2bf858c9d0b5c), [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c), [`0c96009`](https://github.com/wevm/wagmi/commit/0c96009398647a515a57f72ef25c32724f7c978c)]: + - @wagmi/core@0.6.0 + +## 0.6.8 + +### Patch Changes + +- [`0b77286b`](https://github.com/wevm/wagmi/commit/0b77286b89cb8603426cf5081872416c291a6531) Thanks [@jxom](https://github.com/jxom)! - Isolate wagmi's React Query `queryClient` instance. + +* [`8cb07462`](https://github.com/wevm/wagmi/commit/8cb07462acc3c5637398d11d2451f8b8e330d553) Thanks [@jxom](https://github.com/jxom)! - Added `chainId` as an argument to `watchBlockNumber`. + +- [`53c1a474`](https://github.com/wevm/wagmi/commit/53c1a4747d03b685e8cfbf55361fc2a56777fb06) Thanks [@tmm](https://github.com/tmm)! - Added missing `decimals` option to `Connector` `watchAsset` + +* [`4d74dd4f`](https://github.com/wevm/wagmi/commit/4d74dd4ff827ba5c43c3546a218f38cee45ea76a) Thanks [@jxom](https://github.com/jxom)! - Support ERC20 contracts that represent strings as bytes32 + +* Updated dependencies [[`8cb07462`](https://github.com/wevm/wagmi/commit/8cb07462acc3c5637398d11d2451f8b8e330d553), [`53c1a474`](https://github.com/wevm/wagmi/commit/53c1a4747d03b685e8cfbf55361fc2a56777fb06), [`4d74dd4f`](https://github.com/wevm/wagmi/commit/4d74dd4ff827ba5c43c3546a218f38cee45ea76a)]: + - @wagmi/core@0.5.8 + +## 0.6.7 + +### Patch Changes + +- [`aa51bc4d`](https://github.com/wevm/wagmi/commit/aa51bc4dc5683bf0178597d2fdb8f2e9d82e7970) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue in `CoinbaseWalletConnector` where the browser extension would unintendedly reset the network when the browser is refreshed. + +* [#955](https://github.com/wevm/wagmi/pull/955) [`e326cd80`](https://github.com/wevm/wagmi/commit/e326cd80fe65267db623eb6c80ccdd75572914cf) Thanks [@0xFlicker](https://github.com/0xFlicker)! - Added Infura RPC URL for Sepolia + +- [`cec14089`](https://github.com/wevm/wagmi/commit/cec14089500c86687226ab272b4c3fcb85ae3d69) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `useProvider` & `getProvider` were not returning referentially equal providers. + +* [`cec14089`](https://github.com/wevm/wagmi/commit/cec14089500c86687226ab272b4c3fcb85ae3d69) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where the `watch` option was not respecting the neighboring `chainId` option in `useBlockNumber`. + +- [`cec14089`](https://github.com/wevm/wagmi/commit/cec14089500c86687226ab272b4c3fcb85ae3d69) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where block listeners (via `watch`) were firing excessively on L2 chains. + +- Updated dependencies [[`aa51bc4d`](https://github.com/wevm/wagmi/commit/aa51bc4dc5683bf0178597d2fdb8f2e9d82e7970), [`e326cd80`](https://github.com/wevm/wagmi/commit/e326cd80fe65267db623eb6c80ccdd75572914cf), [`cec14089`](https://github.com/wevm/wagmi/commit/cec14089500c86687226ab272b4c3fcb85ae3d69), [`cec14089`](https://github.com/wevm/wagmi/commit/cec14089500c86687226ab272b4c3fcb85ae3d69), [`cec14089`](https://github.com/wevm/wagmi/commit/cec14089500c86687226ab272b4c3fcb85ae3d69)]: + - @wagmi/core@0.5.7 + +## 0.6.6 + +### Patch Changes + +- [#936](https://github.com/wevm/wagmi/pull/936) [`3329d1f`](https://github.com/wevm/wagmi/commit/3329d1f5880431566e14ac1640f48d0975aec4c2) Thanks [@jxom](https://github.com/jxom)! - Added the ability to provide a custom logger to override how logs are broadcasted to the consumer in wagmi. + + A custom logger can be provided to the wagmi client via `logger`. + + ### API + + ```tsx + logger?: { + warn: typeof console.warn | null + } + ``` + + ### Examples + + **Passing in a custom logger** + + You can pass in a function to define your own custom logger. + + ```diff + + import { logWarn } from './logger'; + + const client = createClient({ + ... + + logger: { + + warn: message => logWarn(message) + + } + ... + }) + ``` + + **Disabling a logger** + + You can disable a logger by passing `null` as the value. + + ```diff + const client = createClient({ + ... + + logger: { + + warn: null + + } + ... + }) + ``` + +* [#889](https://github.com/wevm/wagmi/pull/889) [`27788ed`](https://github.com/wevm/wagmi/commit/27788ed989b5dc26849c7945fb91a92e56766018) Thanks [@jxom](https://github.com/jxom)! - Make multicall & readContracts more error robust + +* Updated dependencies [[`3329d1f`](https://github.com/wevm/wagmi/commit/3329d1f5880431566e14ac1640f48d0975aec4c2), [`27788ed`](https://github.com/wevm/wagmi/commit/27788ed989b5dc26849c7945fb91a92e56766018)]: + - @wagmi/core@0.5.6 + +## 0.6.5 + +### Patch Changes + +- [#912](https://github.com/wevm/wagmi/pull/912) [`e529e12`](https://github.com/wevm/wagmi/commit/e529e125c713ed3ef24a59c6bf226fe4deee7ac9) Thanks [@zouhangwithsweet](https://github.com/zouhangwithsweet)! - Added BitKeep to injected flags + +- [#912](https://github.com/wevm/wagmi/pull/910) Thanks [@mytangying](https://github.com/zouhangwithsweet)! - Added MathWallet to injected flags + +- [#904](https://github.com/wevm/wagmi/pull/904) [`c231058`](https://github.com/wevm/wagmi/commit/c23105850f335f8798031e14c7098b7dee8c2975) Thanks [@jxom](https://github.com/jxom)! - Removed `contractInterface` & `signer` from persisted query keys. + +- Updated dependencies [[`e529e12`](https://github.com/wevm/wagmi/commit/e529e125c713ed3ef24a59c6bf226fe4deee7ac9), [`c231058`](https://github.com/wevm/wagmi/commit/c23105850f335f8798031e14c7098b7dee8c2975)]: + - @wagmi/core@0.5.5 + +## 0.6.4 + +### Patch Changes + +- [#852](https://github.com/wevm/wagmi/pull/852) [`c3192d0`](https://github.com/wevm/wagmi/commit/c3192d0663aa332ae9edfd9dd49b333454013ab7) Thanks [@skeithc](https://github.com/skeithc)! - Added support for the Sepolia testnet + +- Updated dependencies [[`c3192d0`](https://github.com/wevm/wagmi/commit/c3192d0663aa332ae9edfd9dd49b333454013ab7)]: + - @wagmi/core@0.5.4 + +## 0.6.3 + +### Patch Changes + +- [#835](https://github.com/wevm/wagmi/pull/835) [`1b85e54`](https://github.com/wevm/wagmi/commit/1b85e54ae654e2564cf5bc2dae6411fe0a25875c) Thanks [@jxom](https://github.com/jxom)! - Update `@coinbase/wallet-sdk` to `3.4.1` + +* [#843](https://github.com/wevm/wagmi/pull/843) [`e77dee6`](https://github.com/wevm/wagmi/commit/e77dee6a606b8aac4279569c54cec8902476fee9) Thanks [@tmm](https://github.com/tmm)! - Fix `MockConnector` entrypoint path + +- [#834](https://github.com/wevm/wagmi/pull/834) [`9655879`](https://github.com/wevm/wagmi/commit/96558793b0319df47aefafa6b7b9c959068d491b) Thanks [@jxom](https://github.com/jxom)! - Update zustand to `4.0.0` + +* [#833](https://github.com/wevm/wagmi/pull/833) [`3ae6d0f`](https://github.com/wevm/wagmi/commit/3ae6d0f5e2d65432024272b43afe68a8f63bb7ea) Thanks [@jxom](https://github.com/jxom)! - Updated `react-query@4.0.0-beta.23` to `@tanstack/react-query@^4.0.10` + +* Updated dependencies [[`1b85e54`](https://github.com/wevm/wagmi/commit/1b85e54ae654e2564cf5bc2dae6411fe0a25875c), [`9655879`](https://github.com/wevm/wagmi/commit/96558793b0319df47aefafa6b7b9c959068d491b)]: + - @wagmi/core@0.5.3 + +## 0.6.2 + +### Patch Changes + +- [#823](https://github.com/wevm/wagmi/pull/823) [`10b8b78`](https://github.com/wevm/wagmi/commit/10b8b78605b7246b2c55b8d69f96663906e5cd20) Thanks [@tmm](https://github.com/tmm)! - Add Optimism Goerli to `chain` lookup. + +- Updated dependencies [[`10b8b78`](https://github.com/wevm/wagmi/commit/10b8b78605b7246b2c55b8d69f96663906e5cd20)]: + - @wagmi/core@0.5.2 + +## 0.6.1 + +### Patch Changes + +- [#767](https://github.com/wevm/wagmi/pull/767) [`e9392f3`](https://github.com/wevm/wagmi/commit/e9392f396e48e928bd9d2522e3ad671c589f08cb) Thanks [@klyap](https://github.com/klyap)! - Add Optimism Goerli chain ahead of [Kovan deprecation](https://dev.optimism.io/kovan-to-goerli). + +* [#817](https://github.com/wevm/wagmi/pull/817) [`7e5cac7`](https://github.com/wevm/wagmi/commit/7e5cac75815dcd8aa563462342a4853fc5207735) Thanks [@alecananian](https://github.com/alecananian)! - Added custom name mapping for 1inch Wallet injected provider + +- [#806](https://github.com/wevm/wagmi/pull/806) [`0b34e56`](https://github.com/wevm/wagmi/commit/0b34e56db97e6dcdb71088e0149b2d55ebc604a5) Thanks [@vmichalik](https://github.com/vmichalik)! - Fix canonical testnet native asset symbols by changing them to ETH + +* [#778](https://github.com/wevm/wagmi/pull/778) [`0892908`](https://github.com/wevm/wagmi/commit/08929084eeeba1a3a55aa098fa9d92a243685ad5) Thanks [@0xcadams](https://github.com/0xcadams)! - Add Arbitrum Goerli chain. + +* Updated dependencies [[`e9392f3`](https://github.com/wevm/wagmi/commit/e9392f396e48e928bd9d2522e3ad671c589f08cb), [`7e5cac7`](https://github.com/wevm/wagmi/commit/7e5cac75815dcd8aa563462342a4853fc5207735), [`0b34e56`](https://github.com/wevm/wagmi/commit/0b34e56db97e6dcdb71088e0149b2d55ebc604a5), [`0892908`](https://github.com/wevm/wagmi/commit/08929084eeeba1a3a55aa098fa9d92a243685ad5)]: + - @wagmi/core@0.5.1 + +## 0.6.0 + +### Minor Changes + +- [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - **Breaking:** The `useSendTransaction` hook's `data` now returns an object only consisting of `hash` & `wait`, and not the full [`TransactionResponse`](https://docs.ethers.io/v5/api/providers/types/#providers-TransactionResponse). + + If you require the full `TransactionResponse`, you can use `useTransaction`: + + ```diff + import { useSendTransaction, useTransaction } from 'wagmi' + + const { + data: { + hash, + wait, + - ...transaction + } + } = useSendTransaction(...) + + +const { data: transaction } = useTransaction({ hash }) + ``` + + > Why? The old implementation of `useSendTransaction` created a long-running async task, causing [UX pitfalls](https://wagmi.sh/docs/prepare-hooks#ux-pitfalls-without-prepare-hooks) when invoked in a click handler. + +* [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The configuration passed to the `useSendTransaction` hook now needs to be either: + + - prepared with the `usePrepareSendTransaction` hook **(new)**, or + - recklessly unprepared **(previous functionality)** + + > Why? [Read here](https://wagmi.sh/docs/prepare-hooks) + + ### Prepared usage + + ```diff + import { usePrepareSendTransaction, useSendTransaction } from 'wagmi' + + +const { config } = usePrepareSendTransaction({ + + request: { + + to: 'moxey.eth', + + value: parseEther('1'), + + } + +}) + + const { data } = useSendTransaction({ + - request: { + - to: 'moxey.eth', + - value: parseEther('1') + - } + + ...config + }) + ``` + + ### Recklessly unprepared usage + + If you are not ready to upgrade to `usePrepareSendTransaction`, it is possible to use `useSendTransaction` without preparing the configuration first by passing `mode: 'recklesslyUnprepared'`. + + ```diff + import { useSendTransaction } from 'wagmi' + + const { data } = useSendTransaction({ + + mode: 'recklesslyUnprepared', + request: { + to: 'moxey.eth', + value: parseEther('1'), + } + }) + ``` + +- [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: If a `chainId` is passed to `useContractWrite` or `useSendTransaction`, it will no longer attempt to switch chain before sending the transaction. Instead, it will throw an error if the user is on the wrong chain. + + > Why? Eagerly prompting to switch chain in these actions created a long-running async task that that makes [iOS App Links](https://wagmi.sh/docs/prepare-hooks#ios-app-link-constraints) vulnerable. + +* [#760](https://github.com/wevm/wagmi/pull/760) [`d8af6bf`](https://github.com/wevm/wagmi/commit/d8af6bf50885aec110ae4d64716642453aa27896) Thanks [@tmm](https://github.com/tmm)! - **Breaking:** `alchemyProvider` and `infuraProvider` now use a generic `apiKey` configuration option instead of `alchemyId` and `infuraId`. + + ```diff + import { alchemyProvider } from '@wagmi/core/providers/alchemy' + import { infuraProvider } from '@wagmi/core/providers/infura' + + alchemyProvider({ + - alchemyId: 'yourAlchemyApiKey', + + apiKey: 'yourAlchemyApiKey', + }) + + infuraProvider({ + - infuraId: 'yourInfuraApiKey', + + apiKey: 'yourInfuraApiKey', + }) + ``` + +- [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - Added the `usePrepareContractWrite` hook that eagerly fetches the parameters required for sending a contract write transaction such as the gas estimate. + + It returns config to be passed through to `useContractWrite`. + + ```ts + const { config } = usePrepareContractWrite({ + addressOrName: "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + contractInterface: wagmigotchiABI, + functionName: "feed", + }); + const { write } = useContractWrite(config); + ``` + +* [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - **Breaking:** When `useSendTransaction` is in "prepare mode" (used with `usePrepareSendTransaction`), `sendTransaction`/`sendTransactionAsync` will be `undefined` until the configuration has been prepared. Ensure that your usage reflects this. + + ```tsx + const { config } = usePrepareSendTransaction({ ... }) + const { sendTransaction } = useSendTransaction(config) + + + ``` + +- [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - Added the `usePrepareSendTransaction` hook that eagerly fetches the parameters required for sending a transaction such as the gas estimate and resolving an ENS address (if required). + + It returns config to be passed through to `useSendTransaction`. + + ```ts + import { usePrepareSendTransaction, useSendTransaction } from "@wagmi/core"; + + const { config } = usePrepareSendTransaction({ + request: { + to: "moxey.eth", + value: parseEther("1"), + }, + }); + const { sendTransaction } = useSendTransaction(config); + ``` + +* [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - **Breaking:** The `sendTransaction`/`sendTransactionAsync` configuration object has now been altered to only accept "reckless" configuration. If one or more of these values are set, it can lead to [UX pitfalls](https://wagmi.sh/docs/prepare-hooks#ux-pitfalls-without-prepare-hooks). + + ```diff + + ``` + +- [#727](https://github.com/wevm/wagmi/pull/727) [`ac3b9b8`](https://github.com/wevm/wagmi/commit/ac3b9b87f80cb45b65d003f09d916d7d1427a62e) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: Moved the `pollingInterval` config option from the chain provider config to `configureChains` config. + + ```diff + const { chains, provider } = configureChains( + [chain.mainnet, chain.polygon], + [ + - alchemyProvider({ apiKey, pollingInterval: 5000 }), + - publicProvider({ pollingInterval: 5000 }) + + alchemyProvider({ apiKey }), + + publicProvider() + ], + + { pollingInterval: 5000 } + ) + ``` + +* [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - **Breaking:** When `useContractWrite` is in "prepare mode" (used with `usePrepareContractWrite`), `write`/`writeAsync` will be `undefined` until the configuration has been prepared. Ensure that your usage reflects this. + + ```tsx + const { config } = usePrepareContractWrite({ ... }) + const { write } = useContractWrite(config) + + + ``` + +- [#658](https://github.com/wevm/wagmi/pull/658) [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The configuration passed to the `useContractWrite` hook now needs to be either: + + - prepared with the `usePrepareContractWrite` hook **(new)**, or + - recklessly unprepared **(previous functionality)** + + > Why? [Read here](https://wagmi.sh/docs/prepare-hooks) + + ### Prepared usage + + ```diff + import { usePrepareContractWrite, useContractWrite } from 'wagmi' + + +const { config } = usePrepareContractWrite({ + + addressOrName: '0x...', + + contractInterface: wagmiAbi, + + functionName: 'mint', + + args: [tokenId] + +}) + + const { data } = useContractWrite({ + - addressOrName: '0x...', + - contractInterface: wagmiAbi, + - functionName: 'mint', + - args: [tokenId], + + ...config + }) + ``` + + ### Recklessly unprepared usage + + If you are not ready to upgrade to `usePrepareContractWrite`, it is possible to use `useContractWrite` without preparing the configuration first by passing `mode: 'recklesslyUnprepared'`. + + ```diff + import { useContractWrite } from 'wagmi' + + const { data } = useContractWrite({ + + mode: 'recklesslyUnprepared', + addressOrName: '0x...', + contractInterface: wagmiAbi, + functionName: 'mint', + args: [tokenId], + }) + ``` + +### Patch Changes + +- [#733](https://github.com/wevm/wagmi/pull/733) [`6232487`](https://github.com/wevm/wagmi/commit/623248703bc728d539e28bf8a89b8ab22f0a5703) Thanks [@tmm](https://github.com/tmm)! - Add mock connector entrypoint + +* [#762](https://github.com/wevm/wagmi/pull/762) [`ccaeed5`](https://github.com/wevm/wagmi/commit/ccaeed53d731f51879e0cdd5648797a32f7d7a31) Thanks [@jxom](https://github.com/jxom)! - Fix `useContractRead` return value unexpectedly returning null for falsy values + +- [#734](https://github.com/wevm/wagmi/pull/734) [`7c2fa04`](https://github.com/wevm/wagmi/commit/7c2fa04e9b695840d6fa088e1f8d069f3c916551) Thanks [@jxom](https://github.com/jxom)! - Fix issue where `useProvider` & `useWebSocketProvider` would not update when `chainId` config changes + +* [#739](https://github.com/wevm/wagmi/pull/739) [`c2295a5`](https://github.com/wevm/wagmi/commit/c2295a56cc86d02cc6602e2b4557b8ab9a091a3f) Thanks [@tmm](https://github.com/tmm)! - Fix balance formatting for tokens that do not have 18 decimals. + +- [#759](https://github.com/wevm/wagmi/pull/759) [`959953d`](https://github.com/wevm/wagmi/commit/959953d1f5b3e8189bac56de245c62333470d18e) Thanks [@tmm](https://github.com/tmm)! - Added `useTransaction` hook: + + ```ts + import { useTransaction } from "wagmi"; + + const result = useTransaction({ + hash: "0x5c504ed432cb51138bcf09aa5e8a410dd4a1e204ef84bfed1be16dfba1b22060", + }); + ``` + +- Updated dependencies [[`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432), [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432), [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432), [`d8af6bf`](https://github.com/wevm/wagmi/commit/d8af6bf50885aec110ae4d64716642453aa27896), [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432), [`c2295a5`](https://github.com/wevm/wagmi/commit/c2295a56cc86d02cc6602e2b4557b8ab9a091a3f), [`ac3b9b8`](https://github.com/wevm/wagmi/commit/ac3b9b87f80cb45b65d003f09d916d7d1427a62e), [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432), [`d70c115`](https://github.com/wevm/wagmi/commit/d70c115131f299fb61f87867b6ac4218e0bcf432), [`959953d`](https://github.com/wevm/wagmi/commit/959953d1f5b3e8189bac56de245c62333470d18e)]: + - @wagmi/core@0.5.0 + +## 0.5.11 + +### Patch Changes + +- [`4c7d123`](https://github.com/wevm/wagmi/commit/4c7d123c8e74f93e770096857eb8c40ce0a47681) Thanks [@jxom](https://github.com/jxom)! - Fix issue where `useProvider` & `useWebSocketProvider` would not update when `chainId` config changes + +## 0.5.10 + +### Patch Changes + +- [#713](https://github.com/tmm/wagmi/pull/713) [`08b0113`](https://github.com/tmm/wagmi/commit/08b0113bef9f32dceab2ecd823b1ee00f9bdc45d) Thanks [@jxom](https://github.com/jxom)! - Fix an issue where the `useContractRead` query function could return `undefined` instead of a serializable `null`. + +* [#725](https://github.com/tmm/wagmi/pull/725) [`b976920`](https://github.com/tmm/wagmi/commit/b97692051d778d7e112872663832c97963a8029a) Thanks [@tmm](https://github.com/tmm)! - Lock `react-query` version + +- [#721](https://github.com/tmm/wagmi/pull/721) [`abea25f`](https://github.com/tmm/wagmi/commit/abea25fd15d81d1ecaec9d3fbd687042ab29b1e6) Thanks [@tmm](https://github.com/tmm)! - Add `name` to `useToken` `data` value. + +- Updated dependencies [[`abea25f`](https://github.com/tmm/wagmi/commit/abea25fd15d81d1ecaec9d3fbd687042ab29b1e6), [`abea25f`](https://github.com/tmm/wagmi/commit/abea25fd15d81d1ecaec9d3fbd687042ab29b1e6)]: + - @wagmi/core@0.4.9 + +## 0.5.9 + +### Patch Changes + +- [#677](https://github.com/tmm/wagmi/pull/677) [`35e4219`](https://github.com/tmm/wagmi/commit/35e42199af9dd346549c1718e144728f55b8d7dd) Thanks [@jxom](https://github.com/jxom)! - Move `parseContractResult` to `@wagmi/core` + +* [#677](https://github.com/tmm/wagmi/pull/677) [`35e4219`](https://github.com/tmm/wagmi/commit/35e42199af9dd346549c1718e144728f55b8d7dd) Thanks [@jxom](https://github.com/jxom)! - Parse tuples correctly in `parseContractResult` + +* Updated dependencies [[`35e4219`](https://github.com/tmm/wagmi/commit/35e42199af9dd346549c1718e144728f55b8d7dd)]: + - @wagmi/core@0.4.7 + +## 0.5.8 + +### Patch Changes + +- [#670](https://github.com/tmm/wagmi/pull/670) [`29a0d21`](https://github.com/tmm/wagmi/commit/29a0d21ee83995559f63542778dfa805f15e7441) Thanks [@tmm](https://github.com/tmm)! - Fix broken release not containing `deepEqual` from `@wagmi/core`. + +- Updated dependencies [[`29a0d21`](https://github.com/tmm/wagmi/commit/29a0d21ee83995559f63542778dfa805f15e7441)]: + - @wagmi/core@0.4.6 + +## 0.5.7 + +### Patch Changes + +- [#659](https://github.com/tmm/wagmi/pull/659) [`be76586`](https://github.com/tmm/wagmi/commit/be76586431238dc5a0970a6f10a3dff9faa8ca2d) Thanks [@jxom](https://github.com/jxom)! - Added an `isDataEqual` config option to `useContractRead`, `useContractReads` & `useContractInfiniteReads` to define whether or not that data has changed. Defaults to `deepEqual`. + +* [#659](https://github.com/tmm/wagmi/pull/659) [`be76586`](https://github.com/tmm/wagmi/commit/be76586431238dc5a0970a6f10a3dff9faa8ca2d) Thanks [@jxom](https://github.com/jxom)! - Added `onBlock` config to `useBlockNumber` + +- [#659](https://github.com/tmm/wagmi/pull/659) [`be76586`](https://github.com/tmm/wagmi/commit/be76586431238dc5a0970a6f10a3dff9faa8ca2d) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue where `useContractRead` & `useContractReads` would return unstable data. + +## 0.5.6 + +### Patch Changes + +- [#654](https://github.com/tmm/wagmi/pull/654) [`e66530b`](https://github.com/tmm/wagmi/commit/e66530bf4881b3533c528f8c5a5f41be0eab0a64) Thanks [@jxom](https://github.com/jxom)! - omit `contractInterface` from `useContractRead` & `useContractReads` query key hash + +* [#654](https://github.com/tmm/wagmi/pull/654) [`e66530b`](https://github.com/tmm/wagmi/commit/e66530bf4881b3533c528f8c5a5f41be0eab0a64) Thanks [@jxom](https://github.com/jxom)! - fix `multicall` returning nullish data for all calls unexpectedly + +* Updated dependencies [[`e66530b`](https://github.com/tmm/wagmi/commit/e66530bf4881b3533c528f8c5a5f41be0eab0a64)]: + - @wagmi/core@0.4.5 + +## 0.5.5 + +### Patch Changes + +- [#629](https://github.com/tmm/wagmi/pull/629) [`199db71`](https://github.com/tmm/wagmi/commit/199db7165eed43d36cb882d373f95e7c49212f23) Thanks [@jxom](https://github.com/jxom)! - Add `wagmi/actions` entrypoint that exports imperative `@wagmi/core` actions + +* [#616](https://github.com/tmm/wagmi/pull/616) [`7a7a17a`](https://github.com/tmm/wagmi/commit/7a7a17a46d4c9e6465cc46a111b5fe8a56109f1b) Thanks [@tmm](https://github.com/tmm)! - Adds `UNSTABLE_shimOnConnectSelectAccount` flag. With this flag and "disconnected" with `shimDisconnect` enabled, the user is prompted to select a different MetaMask account (than the currently connected account) when trying to connect (e.g. `useConnect`/`connect` action). + +* Updated dependencies [[`7a7a17a`](https://github.com/tmm/wagmi/commit/7a7a17a46d4c9e6465cc46a111b5fe8a56109f1b)]: + - @wagmi/core@0.4.4 + +## 0.5.4 + +### Patch Changes + +- [#631](https://github.com/tmm/wagmi/pull/631) [`a780e32`](https://github.com/tmm/wagmi/commit/a780e32e91a0072c795fa0b5a6111302768e2a01) Thanks [@tmm](https://github.com/tmm)! - Fix WalletConnect stale session + +- Updated dependencies [[`a780e32`](https://github.com/tmm/wagmi/commit/a780e32e91a0072c795fa0b5a6111302768e2a01)]: + - @wagmi/core@0.4.3 + +## 0.5.3 + +### Patch Changes + +- [#627](https://github.com/tmm/wagmi/pull/627) [`5985530`](https://github.com/tmm/wagmi/commit/59855301d138313e83a607b3f05053e9f46a78a8) Thanks [@jxom](https://github.com/jxom)! - equalityFn in `useSyncExternalStoreWithTracked` should return truthy when there are no tracked keys. + +## 0.5.2 + +### Patch Changes + +- [#624](https://github.com/tmm/wagmi/pull/624) [`416fa7e`](https://github.com/tmm/wagmi/commit/416fa7ee1f8019ab86e33fb93783ffddecc02c49) Thanks [@jxom](https://github.com/jxom)! - Fix broken `WebSocketProvider` type defs + +- Updated dependencies [[`416fa7e`](https://github.com/tmm/wagmi/commit/416fa7ee1f8019ab86e33fb93783ffddecc02c49)]: + - @wagmi/core@0.4.2 + +## 0.5.1 + +### Patch Changes + +- [#622](https://github.com/tmm/wagmi/pull/622) [`d171581`](https://github.com/tmm/wagmi/commit/d171581464891dd870d97b6232205da0cb152d9b) Thanks [@tmm](https://github.com/tmm)! - Use `domain.chainId` to validate and switch chain before signing in `useSignTypedData`. + +* [#618](https://github.com/tmm/wagmi/pull/618) [`a5138e8`](https://github.com/tmm/wagmi/commit/a5138e82a00e4d9469ad78c97b2d34200d7f1fbe) Thanks [@tmm](https://github.com/tmm)! - Fix adding chains when using MetaMask mobile app, add `publicRpcUrls` constant, and default to public endpoint when adding chain. + +* Updated dependencies [[`d171581`](https://github.com/tmm/wagmi/commit/d171581464891dd870d97b6232205da0cb152d9b), [`a5138e8`](https://github.com/tmm/wagmi/commit/a5138e82a00e4d9469ad78c97b2d34200d7f1fbe)]: + - @wagmi/core@0.4.1 + +## 0.5.0 + +### Minor Changes + +- [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The `useContractWrite` hook parameters have been consolidated into a singular config parameter. + + Before: + + ```tsx + useContractWrite( + { + addressOrName: mlootContractAddress, + contractInterface: mlootABI, + }, + "claim", + ); + ``` + + After: + + ```tsx + useContractWrite({ + addressOrName: mlootContractAddress, + contractInterface: mlootABI, + functionName: "claim", + }); + ``` + +* [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The `useContractEvent` hook parameters have been consolidated into a singular config parameter. + + Before: + + ```tsx + useContractEvent( + { + addressOrName: uniContractAddress, + contractInterface: erc20ABI, + }, + 'Transfer', + listener, + ), + ``` + + After: + + ```tsx + useContractEvent({ + addressOrName: uniContractAddress, + contractInterface: erc20ABI, + eventName: "Transfer", + listener, + }); + ``` + +- [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The `client` prop is now required on `WagmiConfig`. + + ````diff + ```tsx + import { + createClient, + + configureChains, + + defaultChains + } from 'wagmi' + +import { publicProvider } from 'wagmi/providers/public' + + +const { provider, webSocketProvider } = configureChains(defaultChains, [ + + publicProvider(), + +]) + + +const client = createClient({ + + provider, + + webSocketProvider, + +}) + + function App() { + return ( + + + + ) + } + ```` + +* [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The `provider` config option is now required on `createClient`. It is recommended to pass the [`provider` given from `configureChains`](https://wagmi.sh/docs/providers/configuring-chains). + + ```diff + import { + createClient, + + defaultChains, + + configureChains + } from 'wagmi' + +import { publicProvider } from 'wagmi/providers/publicProvider' + + +const { provider } = configureChains(defaultChains, [ + + publicProvider + +]) + + const client = createClient({ + + provider + }) + ``` + + If you previously used an ethers.js Provider, you now need to provide your `chains` on the Provider instance: + + ```diff + import { + createClient, + + defaultChains + } from 'wagmi' + import ethers from 'ethers' + + const client = createClient({ + - provider: getDefaultProvider() + + provider: Object.assign(getDefaultProvider(), { chains: defaultChains }) + }) + ``` + +- [`4f8f3c0`](https://github.com/tmm/wagmi/commit/4f8f3c0d65383bd8bbdfc3f1033adfdb11d80ebb) Thanks [@nachoiacovino](https://github.com/nachoiacovino)! - Use ethereum-lists chains symbols + +* [#582](https://github.com/tmm/wagmi/pull/582) [`b03830a`](https://github.com/tmm/wagmi/commit/b03830a54465215c2526f9509543fe2c978bfe70) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The following changes were made to the `useAccount` return value: + + ### The `data` value is now `address` & `connector` + + ```diff + { + - data?: { + - address: string + - connector: Connector + - } + + address?: string + + connector?: Connector + } + ``` + + ### Global connection status values have been added + + The following global connection status values have been added: + + ```diff + { + + isConnecting: boolean + + isReconnecting: boolean + + isConnected: boolean + + isDisconnected: boolean + + status: 'connecting' | 'reconnecting' | 'connected' | 'disconnected' + } + ``` + + The `useAccount` hook is now aware of any connection event in your application, so now you can use these connection status values to determine if your user is connected, disconnected or connecting to a wallet on a global scope. + + ### `error`, states & `refetch` values have been removed + + Since the `useAccount` hook never dealt with asynchronous data, all of these values were + redundant & unused. + + ```diff + { + - error?: Error + - isIdle: boolean + - isLoading: boolean + - isFetching: boolean + - isSuccess: boolean + - isError: boolean + - isFetched: boolean + - isRefetching: boolean + - refetch: (options: { + - throwOnError: boolean + - cancelRefetch: boolean + - }) => Promise<{ + - address: string + - connector: Connector + - }> + - status: 'idle' | 'error' | 'loading' | 'success' + } + ``` + + ### Summary of changes + + Below is the whole diff of changes to the `useAccount` return value. + + ```diff + { + - data?: { + - address: string + - connector: Connector + - } + + address?: string + + connector?: Connector + - error?: Error + - isIdle: boolean + - isLoading: boolean + - isFetching: boolean + - isSuccess: boolean + - isError: boolean + - isFetched: boolean + - isRefetching: boolean + + isConnecting: boolean + + isReconnecting: boolean + + isConnected: boolean + + isDisconnected: boolean + - refetch: (options: { + - throwOnError: boolean + - cancelRefetch: boolean + - }) => Promise<{ + - address: string + - connector: Connector + - }> + - status: 'idle' | 'error' | 'loading' | 'success' + + status: 'connecting' | 'reconnecting' | 'connected' | 'disconnected' + } + ``` + +- [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - **Breaking:** Removed the `chainId` parameter from `connectors` function on `createClient`. + + ```diff + const client = createClient({ + - connectors({ chainId }) { + + connectors() { + ... + } + }) + ``` + + If you previously derived RPC URLs from the `chainId` on `connectors`, you can now remove that logic as `wagmi` now handles RPC URLs internally when used with `configureChains`. + + ```diff + import { + chain, + + configureChains, + createClient + } from 'wagmi'; + + +import { publicProvider } from 'wagmi/providers/public' + + import { CoinbaseWalletConnector } from 'wagmi/connectors/coinbaseWallet' + import { InjectedConnector } from 'wagmi/connectors/injected' + import { MetaMaskConnector } from 'wagmi/connectors/metaMask' + import { WalletConnectConnector } from 'wagmi/connectors/walletConnect' + + +const { chains } = configureChains( + + [chain.mainnet], + + [publicProvider()] + +); + + const client = createClient({ + - connectors({ chainId }) { + - const chain = chains.find((x) => x.id === chainId) ?? defaultChain + - const rpcUrl = chain.rpcUrls.alchemy + - ? `${chain.rpcUrls.alchemy}/${alchemyId}` + - : chain.rpcUrls.default + - return [ + + connectors: [ + new MetaMaskConnector({ chains }), + new CoinbaseWalletConnector({ + chains, + options: { + appName: 'wagmi', + - chainId: chain.id, + - jsonRpcUrl: rpcUrl, + }, + }), + new WalletConnectConnector({ + chains, + options: { + qrcode: true, + - rpc: { [chain.id]: rpcUrl }, + }, + }), + new InjectedConnector({ + chains, + options: { name: 'Injected' }, + }), + ] + - }, + }) + ``` + +* [#596](https://github.com/tmm/wagmi/pull/596) [`a770af7`](https://github.com/tmm/wagmi/commit/a770af7d2cb214b6620d5341115f1e938e1e77ff) Thanks [@tmm](https://github.com/tmm)! - **Breaking**: `TypedDataDomain` and `TypedDataField` types were removed and incorporated into `SignTypedDataArgs`. + +- [#582](https://github.com/tmm/wagmi/pull/582) [`b03830a`](https://github.com/tmm/wagmi/commit/b03830a54465215c2526f9509543fe2c978bfe70) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The following changes were made to the `useAccount` configuration: + + ## `onConnect` has been added + + The `onConnect` callback is invoked when the account connects. + + It provides the connected address & connector, as well as a `isReconnected` flag for if the user reconnected via `autoConnect`. + + ```tsx + const account = useAccount({ + onConnect({ address, connector, isReconnected }) { + console.log("Connected"); + }, + }); + ``` + + ## `onDisconnect` has been added + + The `onDisconnect` callback is invoked when the account disconnected. + + ```tsx + const account = useAccount({ + onDisconnect() { + console.log("Disconnected"); + }, + }); + ``` + + ## `suspense` has been removed + + The `useAccount` hook is a synchronous hook – so `suspense` never worked. + + ```diff + const account = useAccount({ + - suspense: true, + }) + ``` + + ## `onError` has been removed + + The `useAccount` hook never had any error definitions – so `onError` was never invoked. + + ```diff + const account = useAccount({ + - onError(error) { + - console.log('Error', error) + - }, + }) + ``` + + ## `onSettled` has been removed + + The `useAccount` hook is a synchronous hook. `onSettled` was always invoked immediately. + + ```diff + const account = useAccount({ + - onSettled(data) { + - console.log('Settled', data) + - }, + }) + ``` + + If you used `onSettled`, you can move the code beneath the `useAccount` hook: + + ```diff + const account = useAccount({ + - onSettled(data) { + - console.log('Address:', data.address) + - }, + }) + + console.log('Address:', account.address) + ``` + + ## `onSuccess` has been removed + + The `useAccount` hook is a synchronous hook. `onSuccess` was always invoked immediately. + + ```diff + const account = useAccount({ + - onSuccess(data) { + - console.log('Success', data) + - }, + }) + ``` + + If you used `onSuccess`, you can move the code beneath the `useAccount` hook: + + ```diff + const account = useAccount({ + - onSuccess(data) { + - console.log('Address:', data.address) + - }, + }) + + console.log('Address:', account.address) + ``` + +* [#582](https://github.com/tmm/wagmi/pull/582) [`b03830a`](https://github.com/tmm/wagmi/commit/b03830a54465215c2526f9509543fe2c978bfe70) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The following changes were made to the `useConnect` return value: + + ### Connection status flags have been moved + + The `isConnected`, `isConnecting`, `isReconnecting` & `isDisconnected` flags have been moved to the `useAccount` hook. + + ```diff + -import { useConnect } from 'wagmi' + +import { useAccount } from 'wagmi' + + function App() { + const { + isConnected, + isConnecting, + isConnecting, + isDisconnected + - } = useConnect() + + } = useAccount() + } + ``` + + ### New `connect` mutation status flags have been added + + The `isLoading`, `isSuccess` and `isError` flags have been added to `useConnect`. + + These flags represent the **local** async state of `useConnect`. + + ### `activeConnector` has been removed + + The `activeConnector` value has been removed. You can find the active connector on `useAccount`. + + ```diff + -import { useConnect } from 'wagmi' + +import { useAccount } from 'wagmi' + + function App() { + - const { activeConnector } = useConnect() + + const { connector } = useAccount() + } + ``` + +- [#582](https://github.com/tmm/wagmi/pull/582) [`b03830a`](https://github.com/tmm/wagmi/commit/b03830a54465215c2526f9509543fe2c978bfe70) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The following changes were made to the `useConnect` configuration: + + ### `onBeforeConnect` has been renamed + + The `onBeforeConnect` callback has been renamed to `onMutate` + + ### `onConnect` has been renamed + + The `onConnect` callback has been renamed to `onSuccess` + +* [#582](https://github.com/tmm/wagmi/pull/582) [`b03830a`](https://github.com/tmm/wagmi/commit/b03830a54465215c2526f9509543fe2c978bfe70) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The `connector` parameter to `connect` & `connectAsync` now has to be in the config object parameter shape. + + ```diff + import { useConnect } from 'wagmi' + + function App() { + const { connect, connectors } = useConnect() + + return ( + + ) + } + ``` + +- [#582](https://github.com/tmm/wagmi/pull/582) [`b03830a`](https://github.com/tmm/wagmi/commit/b03830a54465215c2526f9509543fe2c978bfe70) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The "switch network" functionality has been moved out of `useNetwork` into a new `useSwitchNetwork` hook. + + The `useNetwork` hook now accepts no configuration and only returns `chain` (renamed from `activeChain`) and `chains`. + + ```diff + import { + useNetwork + + useSwitchNetwork + } from 'wagmi' + + const { + - activeChain + + chain, + chains, + - data, + - error, + - isError, + - isIdle, + - isLoading, + - isSuccess, + - pendingChainId, + - switchNetwork, + - switchNetworkAsync, + - status, + - reset, + -} = useNetwork({ + - chainId: 69, + - onError(error) {}, + - onMutate(args) {}, + - onSettled(data, error) {}, + - onSuccess(data) {} + -}) + +} = useNetwork() + + +const { + + data, + + error, + + isError, + + isIdle, + + isLoading, + + isSuccess, + + pendingChainId, + + switchNetwork, + + switchNetworkAsync, + + status, + + reset, + +} = useSwitchNetwork({ + + chainId: 69, + + onError(error) {}, + + onMutate(args) {}, + + onSettled(data, error) {}, + + onSuccess(data) {} + +}) + ``` + +* [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - **Breaking**: The `useContractRead` hook parameters have been consolidated into a singular config parameter. + + Before: + + ```tsx + useContractRead( + { + addressOrName: wagmigotchiContractAddress, + contractInterface: wagmigotchiABI, + }, + "love", + { args: "0x27a69ffba1e939ddcfecc8c7e0f967b872bac65c" }, + ); + ``` + + After: + + ```tsx + useContractRead({ + addressOrName: wagmigotchiContractAddress, + contractInterface: wagmigotchiABI, + functionName: "love", + args: "0x27a69ffba1e939ddcfecc8c7e0f967b872bac65c", + }); + ``` + +### Patch Changes + +- [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - Added a `useContractInfiniteReads` hook that provides the ability to call multiple ethers Contract read-only methods with "infinite scrolling" ("fetch more") support. Useful for rendering a dynamic list of contract data. + + [Learn more](https://wagmi.sh/docs/hooks/useContractInfiniteReads) + +* [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4) Thanks [@jxom](https://github.com/jxom)! - Added a `useContractReads` hook that provides the ability to batch up multiple ethers Contract read-only methods. + + [Learn more](https://wagmi.sh/docs/hooks/useContractReads) + +- [#598](https://github.com/tmm/wagmi/pull/598) [`fef26bf`](https://github.com/tmm/wagmi/commit/fef26bf8aef76fc9621e3cd54d4e0ca8f69abb38) Thanks [@markdalgleish](https://github.com/markdalgleish)! - Update `@coinbase/wallet-sdk` to fix errors when connecting with older versions of the Coinbase Wallet extension and mobile app. + +* [#611](https://github.com/tmm/wagmi/pull/611) [`3089c34`](https://github.com/tmm/wagmi/commit/3089c34196d4034acabac031e0a2f7ee63ae30cc) Thanks [@tmm](https://github.com/tmm)! - Added `chainId` config parameter for `useContractWrite` and `useSendTransaction`. + + If `chainId` is provided, the connector will validate that `chainId` is the active chain before sending a transaction (and switch to `chainId` if necessary). + +* Updated dependencies [[`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4), [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4), [`4f8f3c0`](https://github.com/tmm/wagmi/commit/4f8f3c0d65383bd8bbdfc3f1033adfdb11d80ebb), [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4), [`3089c34`](https://github.com/tmm/wagmi/commit/3089c34196d4034acabac031e0a2f7ee63ae30cc), [`a770af7`](https://github.com/tmm/wagmi/commit/a770af7d2cb214b6620d5341115f1e938e1e77ff), [`4f8f3c0`](https://github.com/tmm/wagmi/commit/4f8f3c0d65383bd8bbdfc3f1033adfdb11d80ebb), [`fef26bf`](https://github.com/tmm/wagmi/commit/fef26bf8aef76fc9621e3cd54d4e0ca8f69abb38), [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4), [`3089c34`](https://github.com/tmm/wagmi/commit/3089c34196d4034acabac031e0a2f7ee63ae30cc), [`b03830a`](https://github.com/tmm/wagmi/commit/b03830a54465215c2526f9509543fe2c978bfe70), [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4), [`fc94210`](https://github.com/tmm/wagmi/commit/fc94210b67daa91aa164625dfe189d5b6c2f92d4)]: + - @wagmi/core@0.4.0 + +## 0.4.12 + +### Patch Changes + +- [#570](https://github.com/tmm/wagmi/pull/570) [`0e3fe15`](https://github.com/tmm/wagmi/commit/0e3fe15445377f35d6f4142b49bf1c96bfeb62cd) Thanks [@tmm](https://github.com/tmm)! - adds chain for [Foundry](https://github.com/foundry-rs) + +- Updated dependencies [[`0e3fe15`](https://github.com/tmm/wagmi/commit/0e3fe15445377f35d6f4142b49bf1c96bfeb62cd)]: + - @wagmi/core@0.3.8 + +## 0.4.11 + +### Patch Changes + +- [#566](https://github.com/tmm/wagmi/pull/566) [`8713c00`](https://github.com/tmm/wagmi/commit/8713c00f70fcac3afef4ba183e3c87c6d3cbbf65) Thanks [@jxom](https://github.com/jxom)! - Fixed `parseContractResult` breaking `useContractRead` for more complex contract types + +## 0.4.10 + +### Patch Changes + +- [`20a1ab7`](https://github.com/tmm/wagmi/commit/20a1ab7bd02a24c4f1ea02be1bc3ecfbe4abc584) Thanks [@jxom](https://github.com/jxom)! - Updated to `react-query@4.0.0-beta.23` + +* [`20a1ab7`](https://github.com/tmm/wagmi/commit/20a1ab7bd02a24c4f1ea02be1bc3ecfbe4abc584) Thanks [@jxom](https://github.com/jxom)! - Fixed an issue in `useContractRead` where contract structs wouldn't be parsed back to an ethers `Result` correctly. + +## 0.4.9 + +### Patch Changes + +- [#555](https://github.com/tmm/wagmi/pull/555) [`8bf014d`](https://github.com/tmm/wagmi/commit/8bf014d8167e9f9feb1fd91488aab42dd51c92af) Thanks [@tmm](https://github.com/tmm)! - wire up `useEnsName` `chainId` + +## 0.4.8 + +### Patch Changes + +- [#550](https://github.com/tmm/wagmi/pull/550) [`2a5313e`](https://github.com/tmm/wagmi/commit/2a5313e8cbc9ba6335e8e4b85e43862c9b711bd3) Thanks [@tmm](https://github.com/tmm)! - fix `CoinbaseWalletConnector` possible type error + +* [#548](https://github.com/tmm/wagmi/pull/548) [`0c48719`](https://github.com/tmm/wagmi/commit/0c487199f2421f042abc1f1d139468ccbbc5646a) Thanks [@dohaki](https://github.com/dohaki)! - add ensAddress to Chain type + +- [#549](https://github.com/tmm/wagmi/pull/549) [`89b3a74`](https://github.com/tmm/wagmi/commit/89b3a74ead4234daacd0dcf8506659887ebf0553) Thanks [@tmm](https://github.com/tmm)! - Turns on [`noUncheckedIndexedAccess`](https://www.typescriptlang.org/tsconfig#noUncheckedIndexedAccess=) and [`strictNullChecks`](https://www.typescriptlang.org/tsconfig#strictNullChecks=) for better runtime safety. + +- Updated dependencies [[`2a5313e`](https://github.com/tmm/wagmi/commit/2a5313e8cbc9ba6335e8e4b85e43862c9b711bd3), [`0c48719`](https://github.com/tmm/wagmi/commit/0c487199f2421f042abc1f1d139468ccbbc5646a), [`89b3a74`](https://github.com/tmm/wagmi/commit/89b3a74ead4234daacd0dcf8506659887ebf0553)]: + - @wagmi/core@0.3.7 + +## 0.4.7 + +### Patch Changes + +- [#526](https://github.com/tmm/wagmi/pull/526) [`e95c5f9`](https://github.com/tmm/wagmi/commit/e95c5f91859e57d079b962a72d06b93dce004d2f) Thanks [@jxom](https://github.com/jxom)! - Added `shimChainChangedDisconnect` option to `InjectedConnector`. Defaults to `true` for `MetaMaskConnector`. + +* [#526](https://github.com/tmm/wagmi/pull/526) [`e95c5f9`](https://github.com/tmm/wagmi/commit/e95c5f91859e57d079b962a72d06b93dce004d2f) Thanks [@jxom](https://github.com/jxom)! - Added `chainId` config option to `useConnect()` & `connect()`. Consumers can now pick what chain they want their user to be connected to. + + Examples: + + ```tsx + import { useConnect, chain } from "wagmi"; + import { InjectedConnector } from "wagmi/connectors/injected"; + + function App() { + const connect = useConnect({ + chainId: chain.polygon.id, + }); + } + ``` + + ```tsx + import { useConnect, chain } from "wagmi"; + import { InjectedConnector } from "wagmi/connectors/injected"; + + function App() { + const connect = useConnect(); + + return ( + + ); + } + ``` + +* Updated dependencies [[`e95c5f9`](https://github.com/tmm/wagmi/commit/e95c5f91859e57d079b962a72d06b93dce004d2f), [`e95c5f9`](https://github.com/tmm/wagmi/commit/e95c5f91859e57d079b962a72d06b93dce004d2f), [`e95c5f9`](https://github.com/tmm/wagmi/commit/e95c5f91859e57d079b962a72d06b93dce004d2f)]: + - @wagmi/core@0.3.6 + +## 0.4.6 + +### Patch Changes + +- [#543](https://github.com/tmm/wagmi/pull/543) [`4d489fd`](https://github.com/tmm/wagmi/commit/4d489fd630dd8c00440bdaf4d646de662c41ff52) Thanks [@tmm](https://github.com/tmm)! - fix fee data formatting for null values + +- Updated dependencies [[`4d489fd`](https://github.com/tmm/wagmi/commit/4d489fd630dd8c00440bdaf4d646de662c41ff52)]: + - @wagmi/core@0.3.5 + +## 0.4.5 + +### Patch Changes + +- [`01cc47b`](https://github.com/tmm/wagmi/commit/01cc47b2385c78d82bc799c2dedacb2a42457e2f) Thanks [@jxom](https://github.com/jxom)! - Update `react-query` to `4.0.0-beta.19` + +## 0.4.4 + +### Patch Changes + +- [`c4deb66`](https://github.com/tmm/wagmi/commit/c4deb6655a52e4cc4e5b3fd82202db11d6106848) Thanks [@jxom](https://github.com/jxom)! - infer `options.chainId` config from `chains` on WalletConnectConnector + +- Updated dependencies [[`c4deb66`](https://github.com/tmm/wagmi/commit/c4deb6655a52e4cc4e5b3fd82202db11d6106848)]: + - @wagmi/core@0.3.4 + +## 0.4.3 + +### Patch Changes + +- [#486](https://github.com/tmm/wagmi/pull/486) [`dbfe3dd`](https://github.com/tmm/wagmi/commit/dbfe3dd320d178d6854a8096101200c1508786bb) Thanks [@tmm](https://github.com/tmm)! - add chains entrypoint + +- Updated dependencies [[`dbfe3dd`](https://github.com/tmm/wagmi/commit/dbfe3dd320d178d6854a8096101200c1508786bb)]: + - @wagmi/core@0.3.3 + +## 0.4.2 + +### Patch Changes + +- [`b1a2e58`](https://github.com/tmm/wagmi/commit/b1a2e5830e325be448bf865aeccda60217fc8d75) Thanks [@jxom](https://github.com/jxom)! - Made the `defaultChains` type generic in `configureChains`. + +## 0.4.1 + +### Patch Changes + +- [#484](https://github.com/tmm/wagmi/pull/484) [`1b9a503`](https://github.com/tmm/wagmi/commit/1b9a5033d51c6655b4f6570c490da6e0e9a29da9) Thanks [@tmm](https://github.com/tmm)! - export React Context + +- Updated dependencies [[`1b9a503`](https://github.com/tmm/wagmi/commit/1b9a5033d51c6655b4f6570c490da6e0e9a29da9)]: + - @wagmi/core@0.3.1 + +## 0.4.0 + +### Minor Changes + +- [#468](https://github.com/tmm/wagmi/pull/468) [`44a884b`](https://github.com/tmm/wagmi/commit/44a884b84171c418f57701e80ef8de972948ef0b) Thanks [@tmm](https://github.com/tmm)! - **Breaking:** Duplicate exports with different names and the same functionality were removed to simplify the public API. In addition, confusing exports were renamed to be more descriptive. + + - `createWagmiClient` alias was removed. Use `createClient` instead. + - `useWagmiClient` alias was removed. Use `useClient` instead. + - `WagmiClient` alias was removed. Use `Client` instead. + - `createWagmiStorage` alias was removed. Use `createStorage` instead. + - `Provider` was renamed and `WagmiProvider` alias was removed. Use `WagmiConfig` instead. + +* [#408](https://github.com/tmm/wagmi/pull/408) [`bfcc3a5`](https://github.com/tmm/wagmi/commit/bfcc3a51bbb1551753e3ccde6af134e9fd4fec9a) Thanks [@jxom](https://github.com/jxom)! - Add `configureChains` API. + + The `configureChains` function allows you to configure your chains with a selected provider (Alchemy, Infura, JSON RPC, Public RPC URLs). This means you don't have to worry about deriving your own RPC URLs for each chain, or instantiating a Ethereum Provider. + + `configureChains` accepts 3 parameters: an array of chains, and an array of providers, and a config object. + + [Learn more about configuring chains & providers.](https://wagmi.sh/docs/providers/configuring-chains) + + ### Before + + ```tsx + import { providers } from "ethers"; + import { chain, createClient, defaultChains } from "wagmi"; + import { CoinbaseWalletConnector } from "wagmi/connectors/coinbaseWallet"; + import { InjectedConnector } from "wagmi/connectors/injected"; + import { MetaMaskConnector } from "wagmi/connectors/metaMask"; + import { WalletConnectConnector } from "wagmi/connectors/walletConnect"; + + const alchemyId = process.env.ALCHEMY_ID; + + const chains = defaultChains; + const defaultChain = chain.mainnet; + + const client = createClient({ + autoConnect: true, + connectors({ chainId }) { + const chain = chains.find((x) => x.id === chainId) ?? defaultChain; + const rpcUrl = chain.rpcUrls.alchemy + ? `${chain.rpcUrls.alchemy}/${alchemyId}` + : chain.rpcUrls.default; + return [ + new MetaMaskConnector({ chains }), + new CoinbaseWalletConnector({ + chains, + options: { + appName: "wagmi", + chainId: chain.id, + jsonRpcUrl: rpcUrl, + }, + }), + new WalletConnectConnector({ + chains, + options: { + qrcode: true, + rpc: { [chain.id]: rpcUrl }, + }, + }), + new InjectedConnector({ + chains, + options: { + name: "Injected", + shimDisconnect: true, + }, + }), + ]; + }, + provider: ({ chainId }) => + new providers.AlchemyProvider(chainId, alchemyId), + }); + ``` + + ### After + + ```tsx + import { chain, createClient, defaultChains } from "wagmi"; + + import { alchemyProvider } from "wagmi/providers/alchemy"; + import { publicProvider } from "wagmi/providers/public"; + + import { CoinbaseWalletConnector } from "wagmi/connectors/coinbaseWallet"; + import { InjectedConnector } from "wagmi/connectors/injected"; + import { MetaMaskConnector } from "wagmi/connectors/metaMask"; + import { WalletConnectConnector } from "wagmi/connectors/walletConnect"; + + const alchemyId = process.env.ALCHEMY_ID; + + const { chains, provider, webSocketProvider } = configureChains( + defaultChains, + [alchemyProvider({ alchemyId }), publicProvider()], + ); + + const client = createClient({ + autoConnect: true, + connectors: [ + new MetaMaskConnector({ chains }), + new CoinbaseWalletConnector({ + chains, + options: { + appName: "wagmi", + }, + }), + new WalletConnectConnector({ + chains, + options: { + qrcode: true, + }, + }), + new InjectedConnector({ + chains, + options: { + name: "Injected", + shimDisconnect: true, + }, + }), + ], + provider, + webSocketProvider, + }); + ``` + +### Patch Changes + +- [#404](https://github.com/tmm/wagmi/pull/404) [`f81c156`](https://github.com/tmm/wagmi/commit/f81c15665e2e71534f84ada3fa705f2d78627472) Thanks [@holic](https://github.com/holic)! - Add `ProviderRpcError` and `RpcError` error classes. + + Certain wagmi-standardized errors may wrap `ProviderRpcError` or `RpcError`. For these cases, you can access the original provider rpc or rpc error value using the `internal` property. + +* [#459](https://github.com/tmm/wagmi/pull/459) [`72dcf7c`](https://github.com/tmm/wagmi/commit/72dcf7c09e814261b2e43a8fa364c57675c472de) Thanks [@tmm](https://github.com/tmm)! - update dependencies + +- [#447](https://github.com/tmm/wagmi/pull/447) [`b9ebf78`](https://github.com/tmm/wagmi/commit/b9ebf782e0900725bcb76483686b30f09d357ebd) Thanks [@tmm](https://github.com/tmm)! - Fix case where connector disconnected while app was closed and stale data was returned when autoconnecting. For example, [MetaMask was locked](https://github.com/tmm/wagmi/issues/444) when page was closed. + +- Updated dependencies [[`f81c156`](https://github.com/tmm/wagmi/commit/f81c15665e2e71534f84ada3fa705f2d78627472), [`bfcc3a5`](https://github.com/tmm/wagmi/commit/bfcc3a51bbb1551753e3ccde6af134e9fd4fec9a), [`44a884b`](https://github.com/tmm/wagmi/commit/44a884b84171c418f57701e80ef8de972948ef0b), [`72dcf7c`](https://github.com/tmm/wagmi/commit/72dcf7c09e814261b2e43a8fa364c57675c472de), [`a54f3e2`](https://github.com/tmm/wagmi/commit/a54f3e23ea385ed8aa4ad188128d7089ba20f83e), [`b9ebf78`](https://github.com/tmm/wagmi/commit/b9ebf782e0900725bcb76483686b30f09d357ebd), [`bfcc3a5`](https://github.com/tmm/wagmi/commit/bfcc3a51bbb1551753e3ccde6af134e9fd4fec9a)]: + - @wagmi/core@0.3.0 + +## 0.3.5 + +### Patch Changes + +- [`4e03666`](https://github.com/tmm/wagmi/commit/4e03666428d42fc9186c617001b5eb356229677e) Thanks [@tmm](https://github.com/tmm)! - bump dependencies #429 + add imToken support for WC switch chains #432 + fix MetaMask and Brave Wallet collision #436 +- Updated dependencies [[`4e03666`](https://github.com/tmm/wagmi/commit/4e03666428d42fc9186c617001b5eb356229677e)]: + - @wagmi/core@0.2.5 + +## 0.3.4 + +### Patch Changes + +- [#421](https://github.com/tmm/wagmi/pull/421) [`a232b3f`](https://github.com/tmm/wagmi/commit/a232b3ff5cc41e882c4d2a34c599a8cb670edd2b) Thanks [@tmm](https://github.com/tmm)! - fix erc721 abi + +- Updated dependencies [[`a232b3f`](https://github.com/tmm/wagmi/commit/a232b3ff5cc41e882c4d2a34c599a8cb670edd2b)]: + - @wagmi/core@0.2.4 + +## 0.3.3 + +### Patch Changes + +- [#412](https://github.com/tmm/wagmi/pull/412) [`80bef4f`](https://github.com/tmm/wagmi/commit/80bef4ff3f714b0b8f896f1b4b658acc7266299b) Thanks [@markdalgleish](https://github.com/markdalgleish)! - Import providers from `ethers` peer dependency rather than `@ethersproject/providers` to avoid multiple conflicting versions being installed + +- Updated dependencies [[`80bef4f`](https://github.com/tmm/wagmi/commit/80bef4ff3f714b0b8f896f1b4b658acc7266299b)]: + - @wagmi/core@0.2.3 + +## 0.3.2 + +### Patch Changes + +- [`018c2a1`](https://github.com/tmm/wagmi/commit/018c2a11b22ee513571cc7f83fd63f7eb169ee70) Thanks [@tmm](https://github.com/tmm)! - - warn and fallback to default client #380 + + - remove signerOrProvider option from read contract #390 + + - MetaMaskConnector #391 + +- Updated dependencies [[`018c2a1`](https://github.com/tmm/wagmi/commit/018c2a11b22ee513571cc7f83fd63f7eb169ee70)]: + - @wagmi/core@0.2.2 + +## 0.3.1 + +### Patch Changes + +- [`afc4607`](https://github.com/tmm/wagmi/commit/afc46071e91601ab8a2b465524da796cd60b6ad4) Thanks [@tmm](https://github.com/tmm)! - - Fix time scaling e9593df + - Use fully-specified path for use-sync-external-store import 7b235c1 + - Update serialize 236fc17 +- Updated dependencies [[`afc4607`](https://github.com/tmm/wagmi/commit/afc46071e91601ab8a2b465524da796cd60b6ad4)]: + - @wagmi/core@0.2.1 + +## 0.3.0 + +### Minor Changes + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - don't persist account data when `autoConnect` is falsy + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - - fix(@wagmi/core): persist connector chains to local storage + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - - Favour `message` event over `connecting` event to conform to EIP-1193 + - Export `useWaitForTransaction` + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - force address to be required in `useAccount` + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - Initial 0.3.0 release + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - Add `cacheOnBlock` config for `useContractRead` + Update `react-query` to v4 + Fix `watchBlockNumber` listener leak + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - - fix `useContractWrite` mutation fn arguments + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - Update react-query to 4.0.0-beta.5 + +### Patch Changes + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - add chainId to actions and hooks + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - showtime + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - improve type support for ethers providers + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - update zustand + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - update babel target + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - update block explorers and rpc urls structure + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - keep previous data when watching + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - republish + +- [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - fix stale connectors when switching chains + +* [#311](https://github.com/tmm/wagmi/pull/311) [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d) Thanks [@tmm](https://github.com/tmm)! - last beta + +* Updated dependencies [[`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d), [`24ce011`](https://github.com/tmm/wagmi/commit/24ce0113022b890e9582c6cc24035926e0d2b32d)]: + - @wagmi/core@0.2.0 + +## 0.3.0-next.21 + +### Patch Changes + +- showtime + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.18 + +## 0.3.0-next.20 + +### Patch Changes + +- update block explorers and rpc urls structure + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.17 + +## 0.3.0-next.19 + +### Minor Changes + +- Update react-query to 4.0.0-beta.5 + +## 0.3.0-next.18 + +### Patch Changes + +- last beta + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.16 + +## 0.3.0-next.17 + +### Patch Changes + +- update zustand + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.15 + +## 0.3.0-next.16 + +### Minor Changes + +- Add `cacheOnBlock` config for `useContractRead` +- Update `react-query` to v4 +- Fix `watchBlockNumber` listener leak + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.14 + +## 0.3.0-next.15 + +### Patch Changes + +- keep previous data when watching + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.13 + +## 0.3.0-next.14 + +### Patch Changes + +- add chainId to actions and hooks + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.12 + +## 0.3.0-next.13 + +### Patch Changes + +- fix stale connectors when switching chains + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.11 + +## 0.3.0-next.12 + +### Patch Changes + +- republish + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.10 + +## 0.3.0-next.11 + +### Patch Changes + +- improve type support for ethers providers + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.9 + +## 0.3.0-next.10 + +### Patch Changes + +- update babel target + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.8 + +## 0.3.0-next.9 + +### Minor Changes + +- - Favour `message` event over `connecting` event to conform to EIP-1193 + - Export `useWaitForTransaction` + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.7 + +## 0.3.0-next.8 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.6 + +## 0.3.0-next.7 + +### Minor Changes + +- don't persist account data when `autoConnect` is falsy + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.5 + +## 0.3.0-next.6 + +### Minor Changes + +- fix `useContractWrite` mutation fn arguments + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.4 + +## 0.3.0-next.5 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.3 + +## 0.3.0-next.4 + +### Minor Changes + +- force address to be required in `useAccount` + +## 0.3.0-next.3 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.2 + +## 0.3.0-next.2 + +### Minor Changes + +- Initial 0.3.0 release + +### Patch Changes + +- Updated dependencies []: + - @wagmi/core@0.2.0-next.1 + +## 0.2.28 + +### Patch Changes + +- [`747d895`](https://github.com/tmm/wagmi/commit/747d895a54b562958afde34b1d34e81ab5039e2c) Thanks [@tmm](https://github.com/tmm)! - add warning to WalletLinkConnector + +- Updated dependencies [[`747d895`](https://github.com/tmm/wagmi/commit/747d895a54b562958afde34b1d34e81ab5039e2c)]: + - wagmi-core@0.1.22 + +## 0.2.27 + +### Patch Changes + +- [`c858c51`](https://github.com/tmm/wagmi/commit/c858c51b44d9039f1d0db5bcf016639f47d1931f) Thanks [@tmm](https://github.com/tmm)! - update coinbase connector + +- Updated dependencies [[`c858c51`](https://github.com/tmm/wagmi/commit/c858c51b44d9039f1d0db5bcf016639f47d1931f)]: + - wagmi-core@0.1.21 + +## 0.2.26 + +### Patch Changes + +- Updated dependencies [[`36e6989`](https://github.com/tmm/wagmi/commit/36e69894f4c27aaad7fb6d678476c8bb870244bb)]: + - wagmi-core@0.1.20 + +## 0.2.25 + +### Patch Changes + +- [`d467df6`](https://github.com/tmm/wagmi/commit/d467df6374210dbc4b016788b4beb4fded54cb4d) Thanks [@tmm](https://github.com/tmm)! - fix global type leaking + +- Updated dependencies [[`d467df6`](https://github.com/tmm/wagmi/commit/d467df6374210dbc4b016788b4beb4fded54cb4d)]: + - wagmi-core@0.1.19 + +## 0.2.24 + +### Patch Changes + +- [#294](https://github.com/tmm/wagmi/pull/294) [`1d253f3`](https://github.com/tmm/wagmi/commit/1d253f3a59b61d24c88d25c99decd84a6c734e5d) Thanks [@tmm](https://github.com/tmm)! - change babel target + +- Updated dependencies [[`1d253f3`](https://github.com/tmm/wagmi/commit/1d253f3a59b61d24c88d25c99decd84a6c734e5d)]: + - wagmi-core@0.1.18 + +## 0.2.23 + +### Patch Changes + +- [#292](https://github.com/tmm/wagmi/pull/292) [`53c9be1`](https://github.com/tmm/wagmi/commit/53c9be17ee0c2ae6b8f34f2351b8858257b3f5f2) Thanks [@tmm](https://github.com/tmm)! - fix private fields + +- Updated dependencies [[`53c9be1`](https://github.com/tmm/wagmi/commit/53c9be17ee0c2ae6b8f34f2351b8858257b3f5f2)]: + - wagmi-core@0.1.17 + +## 0.2.22 + +### Patch Changes + +- [`79a2499`](https://github.com/tmm/wagmi/commit/79a249989029f818c32c0e84c0dd2c75e8aa990a) Thanks [@tmm](https://github.com/tmm)! - update build target to es2021 + +- Updated dependencies [[`79a2499`](https://github.com/tmm/wagmi/commit/79a249989029f818c32c0e84c0dd2c75e8aa990a)]: + - wagmi-core@0.1.16 + +## 0.2.21 + +### Patch Changes + +- [`f9790b5`](https://github.com/tmm/wagmi/commit/f9790b55600df09c77bb8ca349c5a3457df1b07c) Thanks [@tmm](https://github.com/tmm)! - fix WalletConnect issue + +- Updated dependencies [[`f9790b5`](https://github.com/tmm/wagmi/commit/f9790b55600df09c77bb8ca349c5a3457df1b07c)]: + - wagmi-core@0.1.15 + +## 0.2.20 + +### Patch Changes + +- [`fed29fb`](https://github.com/tmm/wagmi/commit/fed29fb4714abe234e2dabb63782cfc4439a10cf) Thanks [@tmm](https://github.com/tmm)! - export useSignTypedData + +## 0.2.19 + +### Patch Changes + +- [`6987278`](https://github.com/tmm/wagmi/commit/69872786e0b54b89a20945cc5471c1f4675b0a68) Thanks [@tmm](https://github.com/tmm)! - add useSignedTypeData + +## 0.2.18 + +### Patch Changes + +- [#236](https://github.com/tmm/wagmi/pull/236) [`53bad61`](https://github.com/tmm/wagmi/commit/53bad615788764e31121678083c382c1bd042fe8) Thanks [@markdalgleish](https://github.com/markdalgleish)! - Updated `@walletconnect/ethereum-provider` to [v1.7.4](https://github.com/WalletConnect/walletconnect-monorepo/releases/tag/1.7.4) + +- Updated dependencies [[`53bad61`](https://github.com/tmm/wagmi/commit/53bad615788764e31121678083c382c1bd042fe8)]: + - wagmi-core@0.1.14 + +## 0.2.17 + +### Patch Changes + +- [`8e9412a`](https://github.com/tmm/wagmi/commit/8e9412af71958301ae2f9748febb936e79900aa0) Thanks [@tmm](https://github.com/tmm)! - bump walletlink + +- Updated dependencies [[`8e9412a`](https://github.com/tmm/wagmi/commit/8e9412af71958301ae2f9748febb936e79900aa0)]: + - wagmi-core@0.1.13 + +## 0.2.16 + +### Patch Changes + +- [#210](https://github.com/tmm/wagmi/pull/210) [`684468a`](https://github.com/tmm/wagmi/commit/684468aee3e42a1ce2b4b599f3f17d1819213de8) Thanks [@tmm](https://github.com/tmm)! - update chains to match chainslist.org + +- Updated dependencies [[`684468a`](https://github.com/tmm/wagmi/commit/684468aee3e42a1ce2b4b599f3f17d1819213de8)]: + - wagmi-core@0.1.12 + +## 0.2.15 + +### Patch Changes + +- [#195](https://github.com/tmm/wagmi/pull/195) [`25b6083`](https://github.com/tmm/wagmi/commit/25b6083a662a0236794d1765343467691421c14b) Thanks [@tmm](https://github.com/tmm)! - rename wagmi-private to wagmi-core + +- Updated dependencies [[`25b6083`](https://github.com/tmm/wagmi/commit/25b6083a662a0236794d1765343467691421c14b)]: + - wagmi-core@0.1.11 + +## 0.2.14 + +### Patch Changes + +- [#192](https://github.com/tmm/wagmi/pull/192) [`428cedb`](https://github.com/tmm/wagmi/commit/428cedb3dec4e3e4b9f4559c8e65932e05f94e05) Thanks [@tmm](https://github.com/tmm)! - rename core and testing packages + +- Updated dependencies [[`428cedb`](https://github.com/tmm/wagmi/commit/428cedb3dec4e3e4b9f4559c8e65932e05f94e05)]: + - wagmi-core@0.1.10 + +## 0.2.13 + +### Patch Changes + +- [#190](https://github.com/tmm/wagmi/pull/190) [`7034bb8`](https://github.com/tmm/wagmi/commit/7034bb868412b9f481b206371280e84c2d52706d) Thanks [@tmm](https://github.com/tmm)! - add shim for metamask chain changed to prevent disconnect + +- Updated dependencies [[`7034bb8`](https://github.com/tmm/wagmi/commit/7034bb868412b9f481b206371280e84c2d52706d)]: + - wagmi-private@0.1.9 + +## 0.2.12 + +### Patch Changes + +- [`566b47f`](https://github.com/tmm/wagmi/commit/566b47f53c80e1cdcc368d43c53b1772eeb5be20) Thanks [@tmm](https://github.com/tmm)! - fix contract read skip option + +## 0.2.11 + +### Patch Changes + +- [`09f0719`](https://github.com/tmm/wagmi/commit/09f071947012e3133362a7eb80c0f39356899190) Thanks [@tmm](https://github.com/tmm)! - - safe state updates h/t @bpierre + - add useEnsResolveName hook h/t @shunkakinoki + +## 0.2.10 + +### Patch Changes + +- [#159](https://github.com/tmm/wagmi/pull/159) [`981438d`](https://github.com/tmm/wagmi/commit/981438d527fb6b5f025dd9bb405fa9e7a2751597) Thanks [@markdalgleish](https://github.com/markdalgleish)! - add `WagmiProvider` alias for `Provider` + +## 0.2.9 + +### Patch Changes + +- [#137](https://github.com/tmm/wagmi/pull/137) [`dceeb43`](https://github.com/tmm/wagmi/commit/dceeb430d9021fbf98366859cb1cd0149e80c55c) Thanks [@tmm](https://github.com/tmm)! - add siwe guide + +- Updated dependencies [[`dceeb43`](https://github.com/tmm/wagmi/commit/dceeb430d9021fbf98366859cb1cd0149e80c55c)]: + - wagmi-private@0.1.8 + +## 0.2.8 + +### Patch Changes + +- [`b49cb89`](https://github.com/tmm/wagmi/commit/b49cb89ef59289ee1185eafab427d3ab55c17c25) Thanks [@tmm](https://github.com/tmm)! - refactor contract read/write hook state + +## 0.2.7 + +### Patch Changes + +- [`7132631`](https://github.com/tmm/wagmi/commit/713263159899feb257c11614716f0af4f6b06a14) Thanks [@tmm](https://github.com/tmm)! - update contract read and write state + +## 0.2.6 + +### Patch Changes + +- [#127](https://github.com/tmm/wagmi/pull/127) [`f05b031`](https://github.com/tmm/wagmi/commit/f05b0310f7f7e6447e9b6c81cedbb27dcf2f3649) Thanks [@tmm](https://github.com/tmm)! - update switch chain return type + +- Updated dependencies [[`f05b031`](https://github.com/tmm/wagmi/commit/f05b0310f7f7e6447e9b6c81cedbb27dcf2f3649)]: + - wagmi-private@0.1.7 + +## 0.2.5 + +### Patch Changes + +- [`1412eed`](https://github.com/tmm/wagmi/commit/1412eed0d1494bb4f8c6845a0e890f79e4e68e03) Thanks [@tmm](https://github.com/tmm)! - add frame to injected + +- Updated dependencies [[`1412eed`](https://github.com/tmm/wagmi/commit/1412eed0d1494bb4f8c6845a0e890f79e4e68e03)]: + - wagmi-private@0.1.6 + +## 0.2.4 + +### Patch Changes + +- [#122](https://github.com/tmm/wagmi/pull/122) [`94f599c`](https://github.com/tmm/wagmi/commit/94f599cc1de74a977956d4118d85ab0d36915471) Thanks [@tmm](https://github.com/tmm)! - add decimals to useBalance + +## 0.2.3 + +### Patch Changes + +- [`e338c3b`](https://github.com/tmm/wagmi/commit/e338c3b6cc255742be6a67593aa5da6c17e90fbd) Thanks [@tmm](https://github.com/tmm)! - checksum connector address on change events + + add shim to injected connector for simulating disconnect + +- Updated dependencies [[`e338c3b`](https://github.com/tmm/wagmi/commit/e338c3b6cc255742be6a67593aa5da6c17e90fbd)]: + - wagmi-private@0.1.5 + +## 0.2.2 + +### Patch Changes + +- [`0176c4e`](https://github.com/tmm/wagmi/commit/0176c4e83fb0c5f159c3c802a1da3d6deb2184ae) Thanks [@tmm](https://github.com/tmm)! - added switchChain to WalletConnect and WalletLink connectors + +- Updated dependencies [[`0176c4e`](https://github.com/tmm/wagmi/commit/0176c4e83fb0c5f159c3c802a1da3d6deb2184ae)]: + - wagmi-private@0.1.4 + +## 0.2.1 + +### Patch Changes + +- [`f12d9cc`](https://github.com/tmm/wagmi/commit/f12d9ccfdf87a2f75299b53a7dd6b1ad046a49d8) Thanks [@tmm](https://github.com/tmm)! - fixes overrides type + +## 0.2.0 + +### Minor Changes + +- [#98](https://github.com/tmm/wagmi/pull/98) [`b2ec758`](https://github.com/tmm/wagmi/commit/b2ec7580436f52fd35005c6dd3f4472650a14d02) Thanks [@oveddan](https://github.com/oveddan)! - Exported Context + +## 0.1.7 + +### Patch Changes + +- [`d965757`](https://github.com/tmm/wagmi/commit/d9657578bc17648716c4671b8cc35ad295bc71d2) Thanks [@tmm](https://github.com/tmm)! - use balance eth symbol + +## 0.1.6 + +### Patch Changes + +- [`071d7fb`](https://github.com/tmm/wagmi/commit/071d7fbca35ec4832700b5343661ceb2dae20598) Thanks [@tmm](https://github.com/tmm)! - add hardhat chain + +- Updated dependencies [[`071d7fb`](https://github.com/tmm/wagmi/commit/071d7fbca35ec4832700b5343661ceb2dae20598)]: + - wagmi-private@0.1.3 + +## 0.1.5 + +### Patch Changes + +- [`db4d869`](https://github.com/tmm/wagmi/commit/db4d869fd9380b26a1f3f96ab34abd14ca73d068) Thanks [@tmm](https://github.com/tmm)! - - add global connecting property for `Provider` `autoConnect` (h/t @sammdec) + - fix `useContractEvent` error (h/t @math-marcellino) + +## 0.1.4 + +### Patch Changes + +- [#73](https://github.com/tmm/wagmi/pull/73) [`0c78ccc`](https://github.com/tmm/wagmi/commit/0c78ccc4e7f311525d4ea712b79cf532899e2006) Thanks [@tmm](https://github.com/tmm)! - fix module exports + +## 0.1.3 + +### Patch Changes + +- [`78bade9`](https://github.com/tmm/wagmi/commit/78bade9d0da97ab38a7e6594c34e3841ec1c8fe6) Thanks [@tmm](https://github.com/tmm)! - add type definitions + +- Updated dependencies [[`78bade9`](https://github.com/tmm/wagmi/commit/78bade9d0da97ab38a7e6594c34e3841ec1c8fe6)]: + - wagmi-private@0.1.2 + +## 0.1.2 + +### Patch Changes + +- [#56](https://github.com/tmm/wagmi/pull/56) [`2ebfd8e`](https://github.com/tmm/wagmi/commit/2ebfd8e85b560f25cd46cff04619c84643cab297) Thanks [@tmm](https://github.com/tmm)! - add chain support status + +- Updated dependencies [[`2ebfd8e`](https://github.com/tmm/wagmi/commit/2ebfd8e85b560f25cd46cff04619c84643cab297)]: + - wagmi-private@0.1.1 + +## 0.1.1 + +### Patch Changes + +- [#54](https://github.com/tmm/wagmi/pull/54) [`25acd3d`](https://github.com/tmm/wagmi/commit/25acd3dfbb4498af5e1139ae9c892f5013404cbc) Thanks [@tmm](https://github.com/tmm)! - Stale contract object when useContract hook arguments change @zakangelle + +## 0.1.0 + +### Minor Changes + +- [#52](https://github.com/tmm/wagmi/pull/52) [`da7a3a6`](https://github.com/tmm/wagmi/commit/da7a3a615def2443f65c041999100ce35e9774cc) Thanks [@tmm](https://github.com/tmm)! - Moves connectors to their own entrypoints to reduce bundle size. + + ```ts + // old - WalletLinkConnector unused, but still in final bundle + import { InjectedConnector, WalletConnectConnector } from "wagmi"; + + // new - WalletLinkConnector not in final bundle + import { InjectedConnector } from "wagmi/connectors/injected"; + import { WalletConnectConnector } from "wagmi/connectors/walletConnect"; + ``` + +### Patch Changes + +- Updated dependencies [[`da7a3a6`](https://github.com/tmm/wagmi/commit/da7a3a615def2443f65c041999100ce35e9774cc)]: + - wagmi-private@0.1.0 + +## 0.0.17 + +### Patch Changes + +- [#25](https://github.com/tmm/wagmi/pull/25) [`9a7dab7`](https://github.com/tmm/wagmi/commit/9a7dab78b3518658bc7d85dc397990f0d28da175) Thanks [@tmm](https://github.com/tmm)! - update response types + +- Updated dependencies [[`9a7dab7`](https://github.com/tmm/wagmi/commit/9a7dab78b3518658bc7d85dc397990f0d28da175)]: + - wagmi-private@0.0.17 + +## 0.0.16 + +### Patch Changes + +- [`d1574cf`](https://github.com/tmm/wagmi/commit/d1574cf5f7a578ccd480889c2e375134145a4aba) Thanks [@tmm](https://github.com/tmm)! - add better type information for contract results + +- Updated dependencies [[`d1574cf`](https://github.com/tmm/wagmi/commit/d1574cf5f7a578ccd480889c2e375134145a4aba)]: + - wagmi-private@0.0.16 + +## 0.0.15 + +### Patch Changes + +- [`3909624`](https://github.com/tmm/wagmi/commit/39096249c1fa9516beabb11735beb67c94032879) Thanks [@tmm](https://github.com/tmm)! - make contract read and write execute overrides param optional + +- Updated dependencies [[`3909624`](https://github.com/tmm/wagmi/commit/39096249c1fa9516beabb11735beb67c94032879)]: + - wagmi-private@0.0.15 + +## 0.0.14 + +### Patch Changes + +- [`63312e2`](https://github.com/tmm/wagmi/commit/63312e2b06b8d835abc2908cba399d941ca79408) Thanks [@tmm](https://github.com/tmm)! - add once to contract event + +- Updated dependencies [[`63312e2`](https://github.com/tmm/wagmi/commit/63312e2b06b8d835abc2908cba399d941ca79408)]: + - wagmi-private@0.0.14 + +## 0.0.13 + +### Patch Changes + +- [`6f890b0`](https://github.com/tmm/wagmi/commit/6f890b0dabbdbea913ec91cb8bfc970c05ed0a93) Thanks [@tmm](https://github.com/tmm)! - update readme + +- Updated dependencies [[`6f890b0`](https://github.com/tmm/wagmi/commit/6f890b0dabbdbea913ec91cb8bfc970c05ed0a93)]: + - wagmi-private@0.0.13 + +## 0.0.12 + +### Patch Changes + +- [#19](https://github.com/tmm/wagmi/pull/19) [`7bc1c47`](https://github.com/tmm/wagmi/commit/7bc1c47875e9ef24e9c79cfafc6b23e7a838b5bc) Thanks [@tmm](https://github.com/tmm)! - remove console log from walletlink connector + +- Updated dependencies [[`7bc1c47`](https://github.com/tmm/wagmi/commit/7bc1c47875e9ef24e9c79cfafc6b23e7a838b5bc)]: + - wagmi-private@0.0.12 + +## 0.0.11 + +### Patch Changes + +- [#17](https://github.com/tmm/wagmi/pull/17) [`571648b`](https://github.com/tmm/wagmi/commit/571648b754f7f538536bafc9387bd3104657ea49) Thanks [@tmm](https://github.com/tmm)! - standardize connector provider + +- Updated dependencies [[`571648b`](https://github.com/tmm/wagmi/commit/571648b754f7f538536bafc9387bd3104657ea49)]: + - wagmi-private@0.0.11 + +## 0.0.10 + +### Patch Changes + +- [#15](https://github.com/tmm/wagmi/pull/15) [`5f7675c`](https://github.com/tmm/wagmi/commit/5f7675c3ffd848522d4117c07c1f62b17dfc6616) Thanks [@tmm](https://github.com/tmm)! - read and write contract functions + +- Updated dependencies [[`5f7675c`](https://github.com/tmm/wagmi/commit/5f7675c3ffd848522d4117c07c1f62b17dfc6616)]: + - wagmi-private@0.0.10 + +## 0.0.9 + +### Patch Changes + +- [#13](https://github.com/tmm/wagmi/pull/13) [`e5545f5`](https://github.com/tmm/wagmi/commit/e5545f5565cf0bbf5e62ec7ccab3051705b1d313) Thanks [@tmm](https://github.com/tmm)! - add testing package + +- Updated dependencies [[`e5545f5`](https://github.com/tmm/wagmi/commit/e5545f5565cf0bbf5e62ec7ccab3051705b1d313)]: + - wagmi-private@0.0.9 + +## 0.0.8 + +### Patch Changes + +- [`5332500`](https://github.com/tmm/wagmi/commit/5332500918ac240d29ffe4d2aed8566a8ac001e4) Thanks [@tmm](https://github.com/tmm)! - update signing + +- Updated dependencies [[`5332500`](https://github.com/tmm/wagmi/commit/5332500918ac240d29ffe4d2aed8566a8ac001e4)]: + - wagmi-private@0.0.8 + +## 0.0.7 + +### Patch Changes + +- [`0bff89a`](https://github.com/tmm/wagmi/commit/0bff89ab2ad28b2cb9b346d1ac870e859d9278bc) Thanks [@tmm](https://github.com/tmm)! - update injected connector + +- Updated dependencies [[`0bff89a`](https://github.com/tmm/wagmi/commit/0bff89ab2ad28b2cb9b346d1ac870e859d9278bc)]: + - wagmi-private@0.0.7 + +## 0.0.6 + +### Patch Changes + +- [`37d39d1`](https://github.com/tmm/wagmi/commit/37d39d174ddfa122462bbe2d02141cd61eb9db4a) Thanks [@tmm](https://github.com/tmm)! - add message signing + +- Updated dependencies [[`37d39d1`](https://github.com/tmm/wagmi/commit/37d39d174ddfa122462bbe2d02141cd61eb9db4a)]: + - wagmi-private@0.0.6 + +## 0.0.5 + +### Patch Changes + +- [`d7d94f0`](https://github.com/tmm/wagmi/commit/d7d94f06f7d30468e5e39d64db63124c6315cf82) Thanks [@tmm](https://github.com/tmm)! - fix injected connector name + +- Updated dependencies [[`d7d94f0`](https://github.com/tmm/wagmi/commit/d7d94f06f7d30468e5e39d64db63124c6315cf82)]: + - wagmi-private@0.0.5 + +## 0.0.4 + +### Patch Changes + +- [`29fbe29`](https://github.com/tmm/wagmi/commit/29fbe2920046b9e87a34faa04500ccf3c4f83748) Thanks [@tmm](https://github.com/tmm)! - fix external deps + +- Updated dependencies [[`29fbe29`](https://github.com/tmm/wagmi/commit/29fbe2920046b9e87a34faa04500ccf3c4f83748)]: + - wagmi-private@0.0.4 + +## 0.0.3 + +### Patch Changes + +- [#6](https://github.com/tmm/wagmi/pull/6) [`8dc3a5d`](https://github.com/tmm/wagmi/commit/8dc3a5d5f418813b09663534fe585d9bcf94dbeb) Thanks [@tmm](https://github.com/tmm)! - clean up deps + +- Updated dependencies [[`8dc3a5d`](https://github.com/tmm/wagmi/commit/8dc3a5d5f418813b09663534fe585d9bcf94dbeb)]: + - wagmi-private@0.0.3 + +## 0.0.2 + +### Patch Changes + +- [#4](https://github.com/tmm/wagmi/pull/4) [`2fbd821`](https://github.com/tmm/wagmi/commit/2fbd8216379bd03c9cc5c06b10b75637e75cb7d8) Thanks [@tmm](https://github.com/tmm)! - init changesets + +- Updated dependencies [[`2fbd821`](https://github.com/tmm/wagmi/commit/2fbd8216379bd03c9cc5c06b10b75637e75cb7d8)]: + - wagmi-private@0.0.2 diff --git a/packages/react/README.md b/packages/react/README.md new file mode 100644 index 0000000000..4c87fd5e67 --- /dev/null +++ b/packages/react/README.md @@ -0,0 +1,13 @@ +# wagmi + +React Hooks for Ethereum + +## Installation + +```bash +pnpm add wagmi viem @tanstack/react-query +``` + +## Documentation + +For documentation and guides, visit [wagmi.sh](https://wagmi.sh). diff --git a/packages/react/package.json b/packages/react/package.json new file mode 100644 index 0000000000..79311aa5ce --- /dev/null +++ b/packages/react/package.json @@ -0,0 +1,119 @@ +{ + "name": "wagmi", + "description": "React Hooks for Ethereum", + "version": "2.15.4", + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/wevm/wagmi.git", + "directory": "packages/react" + }, + "scripts": { + "build": "pnpm run clean && pnpm run build:esm+types", + "build:esm+types": "tsc --project tsconfig.build.json --outDir ./dist/esm --declaration --declarationMap --declarationDir ./dist/types", + "check:types": "tsc --noEmit", + "clean": "rm -rf dist tsconfig.tsbuildinfo actions chains codegen connectors experimental query", + "test:build": "publint --strict && attw --pack --ignore-rules cjs-resolves-to-esm" + }, + "files": [ + "dist/**", + "!dist/**/*.tsbuildinfo", + "src/**/*.ts", + "!src/**/*.test.ts", + "!src/**/*.test-d.ts", + "/actions", + "/chains", + "/codegen", + "/connectors", + "/experimental", + "/query" + ], + "sideEffects": false, + "type": "module", + "main": "./dist/esm/exports/index.js", + "types": "./dist/types/exports/index.d.ts", + "typings": "./dist/types/exports/index.d.ts", + "exports": { + ".": { + "types": "./dist/types/exports/index.d.ts", + "default": "./dist/esm/exports/index.js" + }, + "./actions": { + "types": "./dist/types/exports/actions.d.ts", + "default": "./dist/esm/exports/actions.js" + }, + "./actions/experimental": { + "types": "./dist/types/exports/actions/experimental.d.ts", + "default": "./dist/esm/exports/actions/experimental.js" + }, + "./chains": { + "types": "./dist/types/exports/chains.d.ts", + "default": "./dist/esm/exports/chains.js" + }, + "./codegen": { + "types": "./dist/types/exports/codegen.d.ts", + "default": "./dist/esm/exports/codegen.js" + }, + "./connectors": { + "types": "./dist/types/exports/connectors.d.ts", + "default": "./dist/esm/exports/connectors.js" + }, + "./experimental": { + "types": "./dist/types/exports/experimental.d.ts", + "default": "./dist/esm/exports/experimental.js" + }, + "./query": { + "types": "./dist/types/exports/query.d.ts", + "default": "./dist/esm/exports/query.js" + }, + "./package.json": "./package.json" + }, + "typesVersions": { + "*": { + "actions": ["./dist/types/exports/actions.d.ts"], + "chains": ["./dist/types/exports/chains.d.ts"], + "codegen": ["./dist/types/exports/codegen.d.ts"], + "connectors": ["./dist/types/exports/connectors.d.ts"], + "experimental": ["./dist/types/exports/experimental.d.ts"], + "query": ["./dist/types/exports/query.d.ts"] + } + }, + "peerDependencies": { + "@tanstack/react-query": ">=5.0.0", + "react": ">=18", + "typescript": ">=5.0.4", + "viem": "2.x" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + }, + "dependencies": { + "@wagmi/connectors": "workspace:*", + "@wagmi/core": "workspace:*", + "use-sync-external-store": "1.4.0" + }, + "devDependencies": { + "@tanstack/react-query": "catalog:", + "@testing-library/dom": "catalog:", + "@testing-library/react": "catalog:", + "@types/react": "catalog:", + "@types/react-dom": "catalog:", + "@types/use-sync-external-store": "^0.0.6", + "react": "catalog:", + "react-dom": "catalog:" + }, + "contributors": ["awkweb.eth ", "jxom.eth "], + "funding": "https://github.com/sponsors/wevm", + "keywords": [ + "wagmi", + "react", + "hooks", + "eth", + "ethereum", + "dapps", + "wallet", + "web3" + ] +} diff --git a/packages/react/src/context.test.tsx b/packages/react/src/context.test.tsx new file mode 100644 index 0000000000..7a716ac685 --- /dev/null +++ b/packages/react/src/context.test.tsx @@ -0,0 +1,101 @@ +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import { render, waitFor } from '@testing-library/react' +import { http, connect, createConfig, mock } from '@wagmi/core' +import { accounts, addressRegex, config, mainnet } from '@wagmi/test' +import React from 'react' +import { expect, test } from 'vitest' + +import { WagmiProvider } from './context.js' +import { useAccount } from './hooks/useAccount.js' +import { useConnectorClient } from './hooks/useConnectorClient.js' + +test('default', () => { + function Component() { + const { address } = useAccount() + const { data } = useConnectorClient() + return ( +
+

wevm

+
useAccount: {address}
+
useConnectorClient: {data?.account?.address}
+
+ ) + } + + const queryClient = new QueryClient() + const result = render( + + + + + , + ) + expect(result.getByRole('heading').innerText).toMatchInlineSnapshot(`"wevm"`) + result.unmount() +}) + +test('fake ssr config', () => { + const config = createConfig({ + chains: [mainnet], + pollingInterval: 100, + ssr: true, + transports: { + [mainnet.id]: http(), + }, + }) + const queryClient = new QueryClient() + + const result = render( + + +

wevm

+
+
, + ) + expect(result.getAllByRole('heading')).toMatchInlineSnapshot(` + [ +

+ wevm +

, + ] + `) + result.unmount() +}) + +test('mock reconnect', async () => { + function Component() { + const { address } = useAccount() + return ( +
+

{address}

+
+ ) + } + + const connector = mock({ + accounts, + features: { reconnect: true }, + }) + const config = createConfig({ + chains: [mainnet], + connectors: [connector], + storage: null, + transports: { + [mainnet.id]: http(), + }, + }) + await connect(config, { connector }) + + const queryClient = new QueryClient() + const result = render( + + + + + , + ) + await waitFor(() => + expect(result.getByRole('heading').innerText).toMatch(addressRegex), + ) + result.unmount() +}) diff --git a/packages/react/src/context.ts b/packages/react/src/context.ts new file mode 100644 index 0000000000..ec484ccd74 --- /dev/null +++ b/packages/react/src/context.ts @@ -0,0 +1,28 @@ +'use client' + +import type { ResolvedRegister, State } from '@wagmi/core' +import { createContext, createElement } from 'react' +import { Hydrate } from './hydrate.js' + +export const WagmiContext = createContext< + ResolvedRegister['config'] | undefined +>(undefined) + +export type WagmiProviderProps = { + config: ResolvedRegister['config'] + initialState?: State | undefined + reconnectOnMount?: boolean | undefined +} + +export function WagmiProvider( + parameters: React.PropsWithChildren, +) { + const { children, config } = parameters + + const props = { value: config } + return createElement( + Hydrate, + parameters, + createElement(WagmiContext.Provider, props, children), + ) +} diff --git a/packages/react/src/errors/base.test.ts b/packages/react/src/errors/base.test.ts new file mode 100644 index 0000000000..2980541ed8 --- /dev/null +++ b/packages/react/src/errors/base.test.ts @@ -0,0 +1,155 @@ +import { expect, test } from 'vitest' + +import { BaseError } from './base.js' + +test('BaseError', () => { + expect(new BaseError('An error occurred.')).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Version: wagmi@x.y.z] + `) + + expect( + new BaseError('An error occurred.', { details: 'details' }), + ).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Details: details + Version: wagmi@x.y.z] + `) + + expect(new BaseError('', { details: 'details' })).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Details: details + Version: wagmi@x.y.z] + `) +}) + +test('BaseError (w/ docsPath)', () => { + expect( + new BaseError('An error occurred.', { + details: 'details', + docsPath: '/lol', + }), + ).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Docs: https://wagmi.sh/react/lol.html + Details: details + Version: wagmi@x.y.z] + `) + expect( + new BaseError('An error occurred.', { + cause: new BaseError('error', { docsPath: '/docs' }), + }), + ).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Docs: https://wagmi.sh/react/docs.html + Version: wagmi@x.y.z] + `) + expect( + new BaseError('An error occurred.', { + cause: new BaseError('error'), + docsPath: '/lol', + }), + ).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Docs: https://wagmi.sh/react/lol.html + Version: wagmi@x.y.z] + `) + expect( + new BaseError('An error occurred.', { + details: 'details', + docsPath: '/lol', + docsSlug: 'test', + }), + ).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Docs: https://wagmi.sh/react/lol.html#test + Details: details + Version: wagmi@x.y.z] + `) +}) + +test('BaseError (w/ metaMessages)', () => { + expect( + new BaseError('An error occurred.', { + details: 'details', + metaMessages: ['Reason: idk', 'Cause: lol'], + }), + ).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Reason: idk + Cause: lol + + Details: details + Version: wagmi@x.y.z] + `) +}) + +test('inherited BaseError', () => { + const err = new BaseError('An error occurred.', { + details: 'details', + docsPath: '/lol', + }) + expect( + new BaseError('An internal error occurred.', { + cause: err, + }), + ).toMatchInlineSnapshot(` + [WagmiError: An internal error occurred. + + Docs: https://wagmi.sh/react/lol.html + Details: details + Version: wagmi@x.y.z] + `) +}) + +test('inherited Error', () => { + const err = new Error('details') + expect( + new BaseError('An internal error occurred.', { + cause: err, + docsPath: '/lol', + }), + ).toMatchInlineSnapshot(` + [WagmiError: An internal error occurred. + + Docs: https://wagmi.sh/react/lol.html + Details: details + Version: wagmi@x.y.z] + `) +}) + +test('walk: no predicate fn (walks to leaf)', () => { + class FooError extends BaseError {} + class BarError extends BaseError {} + + const err = new BaseError('test1', { + cause: new FooError('test2', { cause: new BarError('test3') }), + }) + expect(err.walk()).toMatchInlineSnapshot(` + [WagmiError: test3 + + Version: wagmi@x.y.z] + `) +}) + +test('walk: predicate fn', () => { + class FooError extends BaseError {} + class BarError extends BaseError {} + + const err = new BaseError('test1', { + cause: new FooError('test2', { cause: new BarError('test3') }), + }) + expect(err.walk((err) => err instanceof FooError)).toMatchInlineSnapshot(` + [WagmiError: test2 + + Version: wagmi@x.y.z] + `) +}) diff --git a/packages/react/src/errors/base.ts b/packages/react/src/errors/base.ts new file mode 100644 index 0000000000..b2ee83c86e --- /dev/null +++ b/packages/react/src/errors/base.ts @@ -0,0 +1,14 @@ +import { BaseError as CoreError } from '@wagmi/core' + +import { getVersion } from '../utils/getVersion.js' + +export type BaseErrorType = BaseError & { name: 'WagmiError' } +export class BaseError extends CoreError { + override name = 'WagmiError' + override get docsBaseUrl() { + return 'https://wagmi.sh/react' + } + override get version() { + return getVersion() + } +} diff --git a/packages/react/src/errors/context.test.ts b/packages/react/src/errors/context.test.ts new file mode 100644 index 0000000000..8dc5a16c4a --- /dev/null +++ b/packages/react/src/errors/context.test.ts @@ -0,0 +1,12 @@ +import { expect, test } from 'vitest' + +import { WagmiProviderNotFoundError } from './context.js' + +test('WagmiProviderNotFoundError', () => { + expect(new WagmiProviderNotFoundError()).toMatchInlineSnapshot(` + [WagmiProviderNotFoundError: \`useConfig\` must be used within \`WagmiProvider\`. + + Docs: https://wagmi.sh/react/api/WagmiProvider.html + Version: wagmi@x.y.z] + `) +}) diff --git a/packages/react/src/errors/context.ts b/packages/react/src/errors/context.ts new file mode 100644 index 0000000000..0ea5cadaaa --- /dev/null +++ b/packages/react/src/errors/context.ts @@ -0,0 +1,13 @@ +import { BaseError } from './base.js' + +export type WagmiProviderNotFoundErrorType = WagmiProviderNotFoundError & { + name: 'WagmiProviderNotFoundError' +} +export class WagmiProviderNotFoundError extends BaseError { + override name = 'WagmiProviderNotFoundError' + constructor() { + super('`useConfig` must be used within `WagmiProvider`.', { + docsPath: '/api/WagmiProvider', + }) + } +} diff --git a/packages/react/src/experimental/hooks/useWriteContracts.test.ts b/packages/react/src/experimental/hooks/useWriteContracts.test.ts new file mode 100644 index 0000000000..ea6d4815de --- /dev/null +++ b/packages/react/src/experimental/hooks/useWriteContracts.test.ts @@ -0,0 +1,45 @@ +import { connect, disconnect } from '@wagmi/core' +import { abi, address, config } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useWriteContracts } from './useWriteContracts.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useWriteContracts()) + + result.current.writeContracts({ + contracts: [ + { + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }, + { + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }, + { + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }, + ], + }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current.data).toMatchInlineSnapshot( + ` + { + "id": "0x8913636bd97cf4bcc0a6343c730905a27ead0f7480ff82190072e916439eb212", + } + `, + ) + + await disconnect(config, { connector }) +}) diff --git a/packages/react/src/experimental/hooks/useWriteContracts.ts b/packages/react/src/experimental/hooks/useWriteContracts.ts new file mode 100644 index 0000000000..8d0d32aefb --- /dev/null +++ b/packages/react/src/experimental/hooks/useWriteContracts.ts @@ -0,0 +1,85 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { Config, ResolvedRegister } from '@wagmi/core' +import { + type WriteContractsData, + type WriteContractsErrorType, + type WriteContractsMutate, + type WriteContractsMutateAsync, + type WriteContractsVariables, + writeContractsMutationOptions, +} from '@wagmi/core/experimental' +import type { Compute } from '@wagmi/core/internal' +import type { ContractFunctionParameters } from 'viem' + +import { useConfig } from '../../hooks/useConfig.js' +import type { ConfigParameter } from '../../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../../utils/query.js' + +export type UseWriteContractsParameters< + contracts extends readonly unknown[] = readonly ContractFunctionParameters[], + config extends Config = Config, + context = unknown, +> = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + WriteContractsData, + WriteContractsErrorType, + WriteContractsVariables< + contracts, + config, + config['chains'][number]['id'] + >, + context + > + | undefined + } +> + +export type UseWriteContractsReturnType< + contracts extends readonly unknown[] = readonly ContractFunctionParameters[], + config extends Config = Config, + context = unknown, +> = Compute< + UseMutationReturnType< + WriteContractsData, + WriteContractsErrorType, + WriteContractsVariables, + context + > & { + writeContracts: WriteContractsMutate + writeContractsAsync: WriteContractsMutateAsync + } +> + +/** https://wagmi.sh/react/api/hooks/useWriteContracts */ +export function useWriteContracts< + const contracts extends + readonly unknown[] = readonly ContractFunctionParameters[], + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseWriteContractsParameters = {}, +): UseWriteContractsReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = writeContractsMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + type Return = UseWriteContractsReturnType + return { + ...result, + writeContracts: mutate as Return['writeContracts'], + writeContractsAsync: mutateAsync as Return['writeContractsAsync'], + } +} diff --git a/packages/react/src/exports/actions.test.ts b/packages/react/src/exports/actions.test.ts new file mode 100644 index 0000000000..eaaedba14f --- /dev/null +++ b/packages/react/src/exports/actions.test.ts @@ -0,0 +1,86 @@ +import { expect, test } from 'vitest' + +import * as actions from './actions.js' + +test('exports', () => { + expect(Object.keys(actions)).toMatchInlineSnapshot(` + [ + "call", + "connect", + "deployContract", + "disconnect", + "estimateGas", + "estimateFeesPerGas", + "estimateMaxPriorityFeePerGas", + "getAccount", + "getBalance", + "fetchBalance", + "getBlock", + "getBlockNumber", + "fetchBlockNumber", + "getBlockTransactionCount", + "getBytecode", + "getCallsStatus", + "getCapabilities", + "getChainId", + "getChains", + "getClient", + "getConnections", + "getConnectors", + "getConnectorClient", + "getEnsAddress", + "fetchEnsAddress", + "getEnsAvatar", + "fetchEnsAvatar", + "getEnsName", + "fetchEnsName", + "getEnsResolver", + "fetchEnsResolver", + "getEnsText", + "getFeeHistory", + "getGasPrice", + "getProof", + "getPublicClient", + "getStorageAt", + "getToken", + "fetchToken", + "getTransaction", + "fetchTransaction", + "getTransactionConfirmations", + "getTransactionCount", + "getTransactionReceipt", + "getWalletClient", + "multicall", + "prepareTransactionRequest", + "readContract", + "readContracts", + "reconnect", + "sendCalls", + "sendTransaction", + "showCallsStatus", + "signMessage", + "signTypedData", + "simulateContract", + "switchAccount", + "switchChain", + "switchNetwork", + "verifyMessage", + "verifyTypedData", + "waitForCallsStatus", + "watchAccount", + "watchAsset", + "watchBlocks", + "watchBlockNumber", + "watchChainId", + "watchClient", + "watchConnections", + "watchConnectors", + "watchContractEvent", + "watchPendingTransactions", + "watchPublicClient", + "waitForTransactionReceipt", + "waitForTransaction", + "writeContract", + ] + `) +}) diff --git a/packages/react/src/exports/actions.ts b/packages/react/src/exports/actions.ts new file mode 100644 index 0000000000..3ff9c743c5 --- /dev/null +++ b/packages/react/src/exports/actions.ts @@ -0,0 +1,7 @@ +//////////////////////////////////////////////////////////////////////////////// +// @wagmi/core/actions +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from '@wagmi/core/actions' diff --git a/packages/react/src/exports/actions/experimental.test.ts b/packages/react/src/exports/actions/experimental.test.ts new file mode 100644 index 0000000000..7c4b92df8c --- /dev/null +++ b/packages/react/src/exports/actions/experimental.test.ts @@ -0,0 +1,25 @@ +import { expect, test } from 'vitest' + +import * as experimentalActions from './experimental.js' + +test('exports', () => { + expect(Object.keys(experimentalActions)).toMatchInlineSnapshot(` + [ + "getCallsStatus", + "getCapabilities", + "sendCalls", + "showCallsStatus", + "waitForCallsStatus", + "writeContracts", + "getCallsStatusQueryOptions", + "getCallsStatusQueryKey", + "getCapabilitiesQueryOptions", + "getCapabilitiesQueryKey", + "sendCallsMutationOptions", + "showCallsStatusMutationOptions", + "waitForCallsStatusQueryKey", + "waitForCallsStatusQueryOptions", + "writeContractsMutationOptions", + ] + `) +}) diff --git a/packages/react/src/exports/actions/experimental.ts b/packages/react/src/exports/actions/experimental.ts new file mode 100644 index 0000000000..6ee0334af5 --- /dev/null +++ b/packages/react/src/exports/actions/experimental.ts @@ -0,0 +1,7 @@ +//////////////////////////////////////////////////////////////////////////////// +// @wagmi/core/experimental +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from '@wagmi/core/experimental' diff --git a/packages/react/src/exports/chains.ts b/packages/react/src/exports/chains.ts new file mode 100644 index 0000000000..1fca7f537f --- /dev/null +++ b/packages/react/src/exports/chains.ts @@ -0,0 +1,7 @@ +//////////////////////////////////////////////////////////////////////////////// +// viem/chains +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from 'viem/chains' diff --git a/packages/react/src/exports/codegen.test.ts b/packages/react/src/exports/codegen.test.ts new file mode 100644 index 0000000000..19697cc9a9 --- /dev/null +++ b/packages/react/src/exports/codegen.test.ts @@ -0,0 +1,18 @@ +import { expect, test } from 'vitest' + +import * as codegen from './codegen.js' + +test('exports', () => { + expect(Object.keys(codegen)).toMatchInlineSnapshot(` + [ + "createSimulateContract", + "createReadContract", + "createWatchContractEvent", + "createWriteContract", + "createUseSimulateContract", + "createUseReadContract", + "createUseWatchContractEvent", + "createUseWriteContract", + ] + `) +}) diff --git a/packages/react/src/exports/codegen.ts b/packages/react/src/exports/codegen.ts new file mode 100644 index 0000000000..c642f63bcb --- /dev/null +++ b/packages/react/src/exports/codegen.ts @@ -0,0 +1,35 @@ +//////////////////////////////////////////////////////////////////////////////// +// @wagmi/core/codegen +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from '@wagmi/core/codegen' + +//////////////////////////////////////////////////////////////////////////////// +// Hooks +//////////////////////////////////////////////////////////////////////////////// + +export { + type CreateUseSimulateContractParameters, + type CreateUseSimulateContractReturnType, + createUseSimulateContract, +} from '../hooks/codegen/createUseSimulateContract.js' + +export { + type CreateUseReadContractParameters, + type CreateUseReadContractReturnType, + createUseReadContract, +} from '../hooks/codegen/createUseReadContract.js' + +export { + type CreateUseWatchContractEventParameters, + type CreateUseWatchContractEventReturnType, + createUseWatchContractEvent, +} from '../hooks/codegen/createUseWatchContractEvent.js' + +export { + type CreateUseWriteContractParameters, + type CreateUseWriteContractReturnType, + createUseWriteContract, +} from '../hooks/codegen/createUseWriteContract.js' diff --git a/packages/react/src/exports/connectors.test.ts b/packages/react/src/exports/connectors.test.ts new file mode 100644 index 0000000000..068db8227c --- /dev/null +++ b/packages/react/src/exports/connectors.test.ts @@ -0,0 +1,17 @@ +import { expect, test } from 'vitest' + +import * as connectors from './connectors.js' + +test('exports', () => { + expect(Object.keys(connectors)).toMatchInlineSnapshot(` + [ + "injected", + "mock", + "coinbaseWallet", + "metaMask", + "safe", + "walletConnect", + "version", + ] + `) +}) diff --git a/packages/react/src/exports/connectors.ts b/packages/react/src/exports/connectors.ts new file mode 100644 index 0000000000..e10367e318 --- /dev/null +++ b/packages/react/src/exports/connectors.ts @@ -0,0 +1,7 @@ +//////////////////////////////////////////////////////////////////////////////// +// @wagmi/connectors +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from '@wagmi/connectors' diff --git a/packages/react/src/exports/experimental.ts b/packages/react/src/exports/experimental.ts new file mode 100644 index 0000000000..996eb56a73 --- /dev/null +++ b/packages/react/src/exports/experimental.ts @@ -0,0 +1,58 @@ +//////////////////////////////////////////////////////////////////////////////// +// Hooks +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { + /** @deprecated This is no longer experimental – use `import type { UseCallsStatusParameters } from 'wagmi'` instead. */ + type UseCallsStatusParameters, + /** @deprecated This is no longer experimental – use `import type { UseCallsStatusReturnType } from 'wagmi'` instead. */ + type UseCallsStatusReturnType, + /** @deprecated This is no longer experimental – use `import { useCallsStatus } from 'wagmi'` instead. */ + useCallsStatus, +} from '../hooks/useCallsStatus.js' + +export { + /** @deprecated This is no longer experimental – use `import type { UseCapabilitiesParameters } from 'wagmi'` instead. */ + type UseCapabilitiesParameters, + /** @deprecated This is no longer experimental – use `import type { UseCapabilitiesReturnType } from 'wagmi'` instead. */ + type UseCapabilitiesReturnType, + /** @deprecated This is no longer experimental – use `import { useCapabilities } from 'wagmi'` instead. */ + useCapabilities, +} from '../hooks/useCapabilities.js' + +export { + /** @deprecated This is no longer experimental – use `import type { UseSendCallsParameters } from 'wagmi'` instead. */ + type UseSendCallsParameters, + /** @deprecated This is no longer experimental – use `import type { UseSendCallsReturnType } from 'wagmi'` instead. */ + type UseSendCallsReturnType, + /** @deprecated This is no longer experimental – use `import { useSendCalls } from 'wagmi'` instead. */ + useSendCalls, +} from '../hooks/useSendCalls.js' + +export { + /** @deprecated This is no longer experimental – use `import type { UseShowCallsStatusParameters } from 'wagmi'` instead. */ + type UseShowCallsStatusParameters, + /** @deprecated This is no longer experimental – use `import type { UseShowCallsStatusReturnType } from 'wagmi'` instead. */ + type UseShowCallsStatusReturnType, + /** @deprecated This is no longer experimental – use `import { useShowCallsStatus } from 'wagmi'` instead. */ + useShowCallsStatus, +} from '../hooks/useShowCallsStatus.js' + +export { + /** @deprecated This is no longer experimental – use `import type { UseWaitForCallsStatusParameters } from 'wagmi'` instead. */ + type UseWaitForCallsStatusParameters, + /** @deprecated This is no longer experimental – use `import type { UseWaitForCallsStatusReturnType } from 'wagmi'` instead. */ + type UseWaitForCallsStatusReturnType, + /** @deprecated This is no longer experimental – use `import { useWaitForCallsStatus } from 'wagmi'` instead. */ + useWaitForCallsStatus, +} from '../hooks/useWaitForCallsStatus.js' + +export { + /** @deprecated Use `UseSendCallsParameters` instead. */ + type UseWriteContractsParameters, + /** @deprecated Use `UseSendCallsReturnType` instead. */ + type UseWriteContractsReturnType, + /** @deprecated Use `useSendCalls` instead. */ + useWriteContracts, +} from '../experimental/hooks/useWriteContracts.js' diff --git a/packages/react/src/exports/index.test.ts b/packages/react/src/exports/index.test.ts new file mode 100644 index 0000000000..d8d6f7c6d5 --- /dev/null +++ b/packages/react/src/exports/index.test.ts @@ -0,0 +1,111 @@ +import { expect, test } from 'vitest' + +import * as react from './index.js' + +test('exports', () => { + expect(Object.keys(react)).toMatchInlineSnapshot(` + [ + "WagmiContext", + "WagmiProvider", + "Context", + "WagmiConfig", + "BaseError", + "WagmiProviderNotFoundError", + "useAccount", + "useAccountEffect", + "useBalance", + "useBlock", + "useBlockNumber", + "useBlockTransactionCount", + "useBytecode", + "useCallsStatus", + "useCapabilities", + "useCall", + "useChainId", + "useChains", + "useClient", + "useConfig", + "useConnect", + "useConnections", + "useConnectors", + "useConnectorClient", + "useDeployContract", + "useDisconnect", + "useEnsAddress", + "useEnsAvatar", + "useEnsName", + "useEnsResolver", + "useEnsText", + "useEstimateFeesPerGas", + "useFeeData", + "useEstimateGas", + "useEstimateMaxPriorityFeePerGas", + "useFeeHistory", + "useGasPrice", + "useInfiniteReadContracts", + "useContractInfiniteReads", + "usePrepareTransactionRequest", + "useProof", + "usePublicClient", + "useReadContract", + "useContractRead", + "useReadContracts", + "useContractReads", + "useReconnect", + "useSendCalls", + "useSendTransaction", + "useShowCallsStatus", + "useSignMessage", + "useSignTypedData", + "useSimulateContract", + "useStorageAt", + "useSwitchAccount", + "useSwitchChain", + "useToken", + "useTransaction", + "useTransactionConfirmations", + "useTransactionCount", + "useTransactionReceipt", + "useVerifyMessage", + "useVerifyTypedData", + "useWalletClient", + "useWaitForCallsStatus", + "useWaitForTransactionReceipt", + "useWatchAsset", + "useWatchBlocks", + "useWatchBlockNumber", + "useWatchContractEvent", + "useWatchPendingTransactions", + "useWriteContract", + "useContractWrite", + "Hydrate", + "createConfig", + "createConnector", + "injected", + "mock", + "ChainNotConfiguredError", + "ConnectorAlreadyConnectedError", + "ConnectorNotFoundError", + "ConnectorAccountNotFoundError", + "ConnectorChainMismatchError", + "ConnectorUnavailableReconnectingError", + "ProviderNotFoundError", + "SwitchChainNotSupportedError", + "createStorage", + "noopStorage", + "custom", + "fallback", + "http", + "webSocket", + "unstable_connector", + "cookieStorage", + "cookieToInitialState", + "deepEqual", + "deserialize", + "normalizeChainId", + "parseCookie", + "serialize", + "version", + ] + `) +}) diff --git a/packages/react/src/exports/index.ts b/packages/react/src/exports/index.ts new file mode 100644 index 0000000000..a4b8502982 --- /dev/null +++ b/packages/react/src/exports/index.ts @@ -0,0 +1,487 @@ +//////////////////////////////////////////////////////////////////////////////// +// Context +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { + type WagmiProviderProps, + WagmiContext, + WagmiProvider, + /** @deprecated Use `WagmiContext` instead */ + WagmiContext as Context, + /** @deprecated Use `WagmiProvider` instead */ + WagmiProvider as WagmiConfig, +} from '../context.js' + +//////////////////////////////////////////////////////////////////////////////// +// Errors +//////////////////////////////////////////////////////////////////////////////// + +export { type BaseErrorType, BaseError } from '../errors/base.js' + +export { + type WagmiProviderNotFoundErrorType, + WagmiProviderNotFoundError, +} from '../errors/context.js' + +//////////////////////////////////////////////////////////////////////////////// +// Hooks +//////////////////////////////////////////////////////////////////////////////// + +export { + type UseAccountParameters, + type UseAccountReturnType, + useAccount, +} from '../hooks/useAccount.js' + +export { + type UseAccountEffectParameters, + useAccountEffect, +} from '../hooks/useAccountEffect.js' + +export { + type UseBalanceParameters, + type UseBalanceReturnType, + useBalance, +} from '../hooks/useBalance.js' + +export { + type UseBlockParameters, + type UseBlockReturnType, + useBlock, +} from '../hooks/useBlock.js' + +export { + type UseBlockNumberParameters, + type UseBlockNumberReturnType, + useBlockNumber, +} from '../hooks/useBlockNumber.js' + +export { + type UseBlockTransactionCountParameters, + type UseBlockTransactionCountReturnType, + useBlockTransactionCount, +} from '../hooks/useBlockTransactionCount.js' + +export { + type UseBytecodeParameters, + type UseBytecodeReturnType, + useBytecode, +} from '../hooks/useBytecode.js' + +export { + type UseCallsStatusParameters, + type UseCallsStatusReturnType, + useCallsStatus, +} from '../hooks/useCallsStatus.js' + +export { + type UseCapabilitiesParameters, + type UseCapabilitiesReturnType, + useCapabilities, +} from '../hooks/useCapabilities.js' + +export { + type UseCallParameters, + type UseCallReturnType, + useCall, +} from '../hooks/useCall.js' + +export { + type UseChainIdParameters, + type UseChainIdReturnType, + useChainId, +} from '../hooks/useChainId.js' + +export { + type UseChainsParameters, + type UseChainsReturnType, + useChains, +} from '../hooks/useChains.js' + +export { + type UseClientParameters, + type UseClientReturnType, + useClient, +} from '../hooks/useClient.js' + +export { + type UseConfigParameters, + type UseConfigReturnType, + useConfig, +} from '../hooks/useConfig.js' + +export { + type UseConnectParameters, + type UseConnectReturnType, + useConnect, +} from '../hooks/useConnect.js' + +export { + type UseConnectionsParameters, + type UseConnectionsReturnType, + useConnections, +} from '../hooks/useConnections.js' + +export { + type UseConnectorsParameters, + type UseConnectorsReturnType, + useConnectors, +} from '../hooks/useConnectors.js' + +export { + type UseConnectorClientParameters, + type UseConnectorClientReturnType, + useConnectorClient, +} from '../hooks/useConnectorClient.js' + +export { + type UseDeployContractParameters, + type UseDeployContractReturnType, + useDeployContract, +} from '../hooks/useDeployContract.js' + +export { + type UseDisconnectParameters, + type UseDisconnectReturnType, + useDisconnect, +} from '../hooks/useDisconnect.js' + +export { + type UseEnsAddressParameters, + type UseEnsAddressReturnType, + useEnsAddress, +} from '../hooks/useEnsAddress.js' + +export { + type UseEnsAvatarParameters, + type UseEnsAvatarReturnType, + useEnsAvatar, +} from '../hooks/useEnsAvatar.js' + +export { + type UseEnsNameParameters, + type UseEnsNameReturnType, + useEnsName, +} from '../hooks/useEnsName.js' + +export { + type UseEnsResolverParameters, + type UseEnsResolverReturnType, + useEnsResolver, +} from '../hooks/useEnsResolver.js' + +export { + type UseEnsTextParameters, + type UseEnsTextReturnType, + useEnsText, +} from '../hooks/useEnsText.js' + +export { + type UseEstimateFeesPerGasParameters, + type UseEstimateFeesPerGasReturnType, + useEstimateFeesPerGas, + /** @deprecated Use `useEstimateFeesPerGas` instead */ + useEstimateFeesPerGas as useFeeData, +} from '../hooks/useEstimateFeesPerGas.js' + +export { + type UseEstimateGasParameters, + type UseEstimateGasReturnType, + useEstimateGas, +} from '../hooks/useEstimateGas.js' + +export { + type UseEstimateMaxPriorityFeePerGasParameters, + type UseEstimateMaxPriorityFeePerGasReturnType, + useEstimateMaxPriorityFeePerGas, +} from '../hooks/useEstimateMaxPriorityFeePerGas.js' + +export { + type UseFeeHistoryParameters, + type UseFeeHistoryReturnType, + useFeeHistory, +} from '../hooks/useFeeHistory.js' + +export { + type UseGasPriceParameters, + type UseGasPriceReturnType, + useGasPrice, +} from '../hooks/useGasPrice.js' + +export { + type UseInfiniteContractReadsParameters, + type UseInfiniteContractReadsReturnType, + useInfiniteReadContracts, + /** @deprecated Use `useInfiniteReadContracts` instead */ + useInfiniteReadContracts as useContractInfiniteReads, +} from '../hooks/useInfiniteReadContracts.js' + +export { + type UsePrepareTransactionRequestParameters, + type UsePrepareTransactionRequestReturnType, + usePrepareTransactionRequest, +} from '../hooks/usePrepareTransactionRequest.js' + +export { + type UseProofParameters, + type UseProofReturnType, + useProof, +} from '../hooks/useProof.js' + +export { + type UsePublicClientParameters, + type UsePublicClientReturnType, + usePublicClient, +} from '../hooks/usePublicClient.js' + +export { + type UseReadContractParameters, + type UseReadContractReturnType, + useReadContract, + /** @deprecated Use `useWriteContract` instead */ + useReadContract as useContractRead, +} from '../hooks/useReadContract.js' + +export { + type UseReadContractsParameters, + type UseReadContractsReturnType, + useReadContracts, + /** @deprecated Use `useWriteContract` instead */ + useReadContracts as useContractReads, +} from '../hooks/useReadContracts.js' + +export { + type UseReconnectParameters, + type UseReconnectReturnType, + useReconnect, +} from '../hooks/useReconnect.js' + +export { + type UseSendCallsParameters, + type UseSendCallsReturnType, + useSendCalls, +} from '../hooks/useSendCalls.js' + +export { + type UseSendTransactionParameters, + type UseSendTransactionReturnType, + useSendTransaction, +} from '../hooks/useSendTransaction.js' + +export { + type UseShowCallsStatusParameters, + type UseShowCallsStatusReturnType, + useShowCallsStatus, +} from '../hooks/useShowCallsStatus.js' + +export { + type UseSignMessageParameters, + type UseSignMessageReturnType, + useSignMessage, +} from '../hooks/useSignMessage.js' + +export { + type UseSignTypedDataParameters, + type UseSignTypedDataReturnType, + useSignTypedData, +} from '../hooks/useSignTypedData.js' + +export { + type UseSimulateContractParameters, + type UseSimulateContractReturnType, + useSimulateContract, +} from '../hooks/useSimulateContract.js' + +export { + type UseStorageAtParameters, + type UseStorageAtReturnType, + useStorageAt, +} from '../hooks/useStorageAt.js' + +export { + type UseSwitchAccountParameters, + type UseSwitchAccountReturnType, + useSwitchAccount, +} from '../hooks/useSwitchAccount.js' + +export { + type UseSwitchChainParameters, + type UseSwitchChainReturnType, + useSwitchChain, +} from '../hooks/useSwitchChain.js' + +export { + type UseTokenParameters, + type UseTokenReturnType, + /** @deprecated Use `useReadContracts` instead */ + useToken, +} from '../hooks/useToken.js' + +export { + type UseTransactionParameters, + type UseTransactionReturnType, + useTransaction, +} from '../hooks/useTransaction.js' + +export { + type UseTransactionConfirmationsParameters, + type UseTransactionConfirmationsReturnType, + useTransactionConfirmations, +} from '../hooks/useTransactionConfirmations.js' + +export { + type UseTransactionCountParameters, + type UseTransactionCountReturnType, + useTransactionCount, +} from '../hooks/useTransactionCount.js' + +export { + type UseTransactionReceiptParameters, + type UseTransactionReceiptReturnType, + useTransactionReceipt, +} from '../hooks/useTransactionReceipt.js' + +export { + type UseVerifyMessageParameters, + type UseVerifyMessageReturnType, + useVerifyMessage, +} from '../hooks/useVerifyMessage.js' + +export { + type UseVerifyTypedDataParameters, + type UseVerifyTypedDataReturnType, + useVerifyTypedData, +} from '../hooks/useVerifyTypedData.js' + +export { + type UseWalletClientParameters, + type UseWalletClientReturnType, + useWalletClient, +} from '../hooks/useWalletClient.js' + +export { + type UseWaitForCallsStatusParameters, + type UseWaitForCallsStatusReturnType, + useWaitForCallsStatus, +} from '../hooks/useWaitForCallsStatus.js' + +export { + type UseWaitForTransactionReceiptParameters, + type UseWaitForTransactionReceiptReturnType, + useWaitForTransactionReceipt, +} from '../hooks/useWaitForTransactionReceipt.js' + +export { + type UseWatchAssetParameters, + type UseWatchAssetReturnType, + useWatchAsset, +} from '../hooks/useWatchAsset.js' + +export { + type UseWatchBlocksParameters, + type UseWatchBlocksReturnType, + useWatchBlocks, +} from '../hooks/useWatchBlocks.js' + +export { + type UseWatchBlockNumberParameters, + type UseWatchBlockNumberReturnType, + useWatchBlockNumber, +} from '../hooks/useWatchBlockNumber.js' + +export { + type UseWatchContractEventParameters, + type UseWatchContractEventReturnType, + useWatchContractEvent, +} from '../hooks/useWatchContractEvent.js' + +export { + type UseWatchPendingTransactionsParameters, + type UseWatchPendingTransactionsReturnType, + useWatchPendingTransactions, +} from '../hooks/useWatchPendingTransactions.js' + +export { + type UseWriteContractParameters, + type UseWriteContractReturnType, + useWriteContract, + /** @deprecated Use `useWriteContract` instead */ + useWriteContract as useContractWrite, +} from '../hooks/useWriteContract.js' + +//////////////////////////////////////////////////////////////////////////////// +// Hydrate +//////////////////////////////////////////////////////////////////////////////// + +export { + type HydrateProps, + Hydrate, +} from '../hydrate.js' + +//////////////////////////////////////////////////////////////////////////////// +// @wagmi/core +//////////////////////////////////////////////////////////////////////////////// + +export { + // Config + type Connection, + type Connector, + type Config, + type CreateConfigParameters, + type PartializedState, + type State, + createConfig, + // Connector + type ConnectorEventMap, + type CreateConnectorFn, + createConnector, + injected, + mock, + // Errors + type ChainNotConfiguredErrorType, + ChainNotConfiguredError, + type ConnectorAlreadyConnectedErrorType, + ConnectorAlreadyConnectedError, + type ConnectorNotFoundErrorType, + ConnectorNotFoundError, + type ConnectorAccountNotFoundErrorType, + ConnectorAccountNotFoundError, + type ConnectorChainMismatchErrorType, + ConnectorChainMismatchError, + type ConnectorUnavailableReconnectingErrorType, + ConnectorUnavailableReconnectingError, + type ProviderNotFoundErrorType, + ProviderNotFoundError, + type SwitchChainNotSupportedErrorType, + SwitchChainNotSupportedError, + // Storage + type CreateStorageParameters, + type Storage, + createStorage, + noopStorage, + // Transports + custom, + fallback, + http, + webSocket, + unstable_connector, + type Transport, + // Types + type Register, + type ResolvedRegister, + // Utilities + cookieStorage, + cookieToInitialState, + deepEqual, + deserialize, + normalizeChainId, + parseCookie, + serialize, +} from '@wagmi/core' + +//////////////////////////////////////////////////////////////////////////////// +// Version +//////////////////////////////////////////////////////////////////////////////// + +export { version } from '../version.js' diff --git a/packages/react/src/exports/query.test.ts b/packages/react/src/exports/query.test.ts new file mode 100644 index 0000000000..002b6abaab --- /dev/null +++ b/packages/react/src/exports/query.test.ts @@ -0,0 +1,100 @@ +import { expect, test } from 'vitest' + +import * as query from './query.js' + +test('exports', () => { + expect(Object.keys(query)).toMatchInlineSnapshot(` + [ + "callQueryKey", + "callQueryOptions", + "connectMutationOptions", + "deployContractMutationOptions", + "disconnectMutationOptions", + "estimateFeesPerGasQueryKey", + "estimateFeesPerGasQueryOptions", + "estimateGasQueryKey", + "estimateGasQueryOptions", + "estimateMaxPriorityFeePerGasQueryKey", + "estimateMaxPriorityFeePerGasQueryOptions", + "getBalanceQueryKey", + "getBalanceQueryOptions", + "getBlockQueryKey", + "getBlockQueryOptions", + "getBlockNumberQueryKey", + "getBlockNumberQueryOptions", + "getBlockTransactionCountQueryKey", + "getBlockTransactionCountQueryOptions", + "getBytecodeQueryKey", + "getBytecodeQueryOptions", + "getCallsStatusQueryKey", + "getCallsStatusQueryOptions", + "getCapabilitiesQueryKey", + "getCapabilitiesQueryOptions", + "getConnectorClientQueryKey", + "getConnectorClientQueryOptions", + "getEnsAddressQueryKey", + "getEnsAddressQueryOptions", + "getEnsAvatarQueryKey", + "getEnsAvatarQueryOptions", + "getEnsNameQueryKey", + "getEnsNameQueryOptions", + "getEnsResolverQueryKey", + "getEnsResolverQueryOptions", + "getEnsTextQueryKey", + "getEnsTextQueryOptions", + "getFeeHistoryQueryKey", + "getFeeHistoryQueryOptions", + "getGasPriceQueryKey", + "getGasPriceQueryOptions", + "getProofQueryKey", + "getProofQueryOptions", + "getStorageAtQueryKey", + "getStorageAtQueryOptions", + "getTokenQueryKey", + "getTokenQueryOptions", + "getTransactionQueryKey", + "getTransactionQueryOptions", + "getTransactionConfirmationsQueryKey", + "getTransactionConfirmationsQueryOptions", + "getTransactionCountQueryKey", + "getTransactionCountQueryOptions", + "getTransactionReceiptQueryKey", + "getTransactionReceiptQueryOptions", + "getWalletClientQueryKey", + "getWalletClientQueryOptions", + "infiniteReadContractsQueryKey", + "infiniteReadContractsQueryOptions", + "prepareTransactionRequestQueryKey", + "prepareTransactionRequestQueryOptions", + "readContractQueryKey", + "readContractQueryOptions", + "readContractsQueryKey", + "readContractsQueryOptions", + "reconnectMutationOptions", + "sendCallsMutationOptions", + "showCallsStatusMutationOptions", + "sendTransactionMutationOptions", + "signMessageMutationOptions", + "signTypedDataMutationOptions", + "switchAccountMutationOptions", + "simulateContractQueryKey", + "simulateContractQueryOptions", + "switchChainMutationOptions", + "verifyMessageQueryKey", + "verifyMessageQueryOptions", + "verifyTypedDataQueryKey", + "verifyTypedDataQueryOptions", + "waitForCallsStatusQueryKey", + "waitForCallsStatusQueryOptions", + "waitForTransactionReceiptQueryKey", + "waitForTransactionReceiptQueryOptions", + "watchAssetMutationOptions", + "writeContractMutationOptions", + "hashFn", + "structuralSharing", + "useInfiniteQuery", + "useMutation", + "useQuery", + ] + `) +}) diff --git a/packages/react/src/exports/query.ts b/packages/react/src/exports/query.ts new file mode 100644 index 0000000000..ff91fee2d9 --- /dev/null +++ b/packages/react/src/exports/query.ts @@ -0,0 +1,19 @@ +//////////////////////////////////////////////////////////////////////////////// +// @wagmi/core/query +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from '@wagmi/core/query' + +export { + type UseInfiniteQueryParameters, + type UseInfiniteQueryReturnType, + type UseMutationParameters, + type UseMutationReturnType, + type UseQueryParameters, + type UseQueryReturnType, + useInfiniteQuery, + useMutation, + useQuery, +} from '../utils/query.js' diff --git a/packages/react/src/hooks/codegen/createUseReadContract.test-d.ts b/packages/react/src/hooks/codegen/createUseReadContract.test-d.ts new file mode 100644 index 0000000000..f0331efed2 --- /dev/null +++ b/packages/react/src/hooks/codegen/createUseReadContract.test-d.ts @@ -0,0 +1,152 @@ +import { abi, mainnet, optimism } from '@wagmi/test' +import { assertType, expectTypeOf, test } from 'vitest' + +import { createUseReadContract } from './createUseReadContract.js' + +test('default', () => { + const useReadErc20 = createUseReadContract({ + abi: abi.erc20, + }) + + const result = useReadErc20({ + functionName: 'balanceOf', + args: ['0x'], + chainId: 123, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) + +test('select data', () => { + const useReadErc20 = createUseReadContract({ + abi: abi.erc20, + }) + + const result = useReadErc20({ + address: '0x', + functionName: 'balanceOf', + args: ['0x'], + query: { + select(data) { + expectTypeOf(data).toEqualTypeOf() + return data?.toString() + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) + +test('multichain address', () => { + const useReadErc20 = createUseReadContract({ + abi: abi.erc20, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + }) + + const result = useReadErc20({ + functionName: 'balanceOf', + args: ['0x'], + chainId: mainnet.id, + // ^? + }) + assertType(result.data) + + useReadErc20({ + functionName: 'balanceOf', + args: ['0x'], + // @ts-expect-error chain id must match address keys + chainId: 420, + }) + + useReadErc20({ + functionName: 'balanceOf', + args: ['0x'], + // @ts-expect-error address not allowed + address: '0x', + }) +}) + +test('overloads', () => { + const useReadViewOverloads = createUseReadContract({ + abi: abi.viewOverloads, + }) + + const result1 = useReadViewOverloads({ + functionName: 'foo', + }) + assertType(result1.data) + + const result2 = useReadViewOverloads({ + functionName: 'foo', + args: [], + }) + assertType(result2.data) + + const result3 = useReadViewOverloads({ + functionName: 'foo', + args: ['0x'], + }) + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + assertType(result3.data) + + const result4 = useReadViewOverloads({ + functionName: 'foo', + args: ['0x', '0x'], + }) + assertType< + | { + foo: `0x${string}` + bar: `0x${string}` + } + | undefined + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + >(result4.data) +}) + +test('functionName', () => { + const useReadErc20BalanceOf = createUseReadContract({ + abi: abi.erc20, + address: '0x', + functionName: 'balanceOf', + }) + + const result = useReadErc20BalanceOf({ + args: ['0x'], + chainId: 1, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) + +test('functionName with overloads', () => { + const useReadViewOverloads = createUseReadContract({ + abi: abi.viewOverloads, + functionName: 'foo', + }) + + const result1 = useReadViewOverloads() + assertType(result1.data) + + const result2 = useReadViewOverloads({ + args: [], + }) + assertType(result2.data) + + const result3 = useReadViewOverloads({ + args: ['0x'], + }) + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + assertType(result3.data) + + const result4 = useReadViewOverloads({ + args: ['0x', '0x'], + }) + assertType< + | { + foo: `0x${string}` + bar: `0x${string}` + } + | undefined + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + >(result4.data) +}) diff --git a/packages/react/src/hooks/codegen/createUseReadContract.test.ts b/packages/react/src/hooks/codegen/createUseReadContract.test.ts new file mode 100644 index 0000000000..4419c030c5 --- /dev/null +++ b/packages/react/src/hooks/codegen/createUseReadContract.test.ts @@ -0,0 +1,177 @@ +import { abi, address, chain } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { createUseReadContract } from './createUseReadContract.js' + +test('default', async () => { + const useReadWagmiMintExample = createUseReadContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + }) + + const { result } = renderHook(() => + useReadWagmiMintExample({ + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": 4n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "readContract", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": [ + "0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC", + ], + "chainId": 1, + "functionName": "balanceOf", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('multichain', async () => { + const useReadWagmiMintExample = createUseReadContract({ + address: { + [chain.mainnet.id]: address.wagmiMintExample, + [chain.mainnet2.id]: address.wagmiMintExample, + }, + abi: abi.wagmiMintExample, + }) + + const { result } = renderHook(() => + useReadWagmiMintExample({ + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + chainId: chain.mainnet2.id, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": 4n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "readContract", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": [ + "0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC", + ], + "chainId": 456, + "functionName": "balanceOf", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('functionName', async () => { + const useReadWagmiMintExampleBalanceOf = createUseReadContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'balanceOf', + }) + + const { result } = renderHook(() => + useReadWagmiMintExampleBalanceOf({ + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": 4n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "readContract", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": [ + "0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC", + ], + "chainId": 1, + "functionName": "balanceOf", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/codegen/createUseReadContract.ts b/packages/react/src/hooks/codegen/createUseReadContract.ts new file mode 100644 index 0000000000..1c5f509e58 --- /dev/null +++ b/packages/react/src/hooks/codegen/createUseReadContract.ts @@ -0,0 +1,127 @@ +import type { + Config, + ReadContractErrorType, + ReadContractParameters, + ResolvedRegister, +} from '@wagmi/core' +import type { + ScopeKeyParameter, + UnionCompute, + UnionExactPartial, + UnionStrictOmit, +} from '@wagmi/core/internal' +import type { + ReadContractData, + ReadContractQueryFnData, + ReadContractQueryKey, +} from '@wagmi/core/query' +import type { + Abi, + Address, + ContractFunctionArgs, + ContractFunctionName, +} from 'viem' + +import type { ConfigParameter, QueryParameter } from '../../types/properties.js' +import { useAccount } from '../useAccount.js' +import { useChainId } from '../useChainId.js' +import { useConfig } from '../useConfig.js' +import { + type UseReadContractReturnType, + useReadContract, +} from '../useReadContract.js' + +type stateMutability = 'pure' | 'view' + +export type CreateUseReadContractParameters< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined = undefined, + functionName extends + | ContractFunctionName + | undefined = undefined, +> = { + abi: abi | Abi | readonly unknown[] + address?: address | Address | Record | undefined + functionName?: + | functionName + | ContractFunctionName + | undefined +} + +export type CreateUseReadContractReturnType< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined, + functionName extends ContractFunctionName | undefined, + /// + omittedProperties extends 'abi' | 'address' | 'chainId' | 'functionName' = + | 'abi' + | (address extends undefined ? never : 'address') + | (address extends Record ? 'chainId' : never) + | (functionName extends undefined ? never : 'functionName'), +> = < + name extends functionName extends ContractFunctionName + ? functionName + : ContractFunctionName, + args extends ContractFunctionArgs, + config extends Config = ResolvedRegister['config'], + selectData = ReadContractData, +>( + parameters?: UnionCompute< + UnionExactPartial< + UnionStrictOmit< + ReadContractParameters, + omittedProperties + > + > & + ScopeKeyParameter & + ConfigParameter & + QueryParameter< + ReadContractQueryFnData, + ReadContractErrorType, + selectData, + ReadContractQueryKey + > + > & + (address extends Record + ? { chainId?: keyof address | undefined } + : unknown), +) => UseReadContractReturnType + +export function createUseReadContract< + const abi extends Abi | readonly unknown[], + const address extends + | Address + | Record + | undefined = undefined, + functionName extends + | ContractFunctionName + | undefined = undefined, +>( + props: CreateUseReadContractParameters, +): CreateUseReadContractReturnType { + if (props.address !== undefined && typeof props.address === 'object') + return (parameters) => { + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + const account = useAccount({ config }) + const chainId = + (parameters as { chainId?: number })?.chainId ?? + account.chainId ?? + configChainId + return useReadContract({ + ...(parameters as any), + ...(props.functionName ? { functionName: props.functionName } : {}), + address: props.address?.[chainId], + abi: props.abi, + }) + } + + return (parameters) => { + return useReadContract({ + ...(parameters as any), + ...(props.address ? { address: props.address } : {}), + ...(props.functionName ? { functionName: props.functionName } : {}), + abi: props.abi, + }) + } +} diff --git a/packages/react/src/hooks/codegen/createUseSimulateContract.test-d.ts b/packages/react/src/hooks/codegen/createUseSimulateContract.test-d.ts new file mode 100644 index 0000000000..5388e69109 --- /dev/null +++ b/packages/react/src/hooks/codegen/createUseSimulateContract.test-d.ts @@ -0,0 +1,199 @@ +import { abi, mainnet, optimism } from '@wagmi/test' +import type { Address } from 'viem' +import { assertType, expectTypeOf, test } from 'vitest' + +import { createUseSimulateContract } from './createUseSimulateContract.js' + +test('default', () => { + const useSimulateErc20 = createUseSimulateContract({ + abi: abi.erc20, + }) + + const result = useSimulateErc20({ + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 123, + }) + result.data?.request.chainId + expectTypeOf(result.data).toMatchTypeOf< + | { + result: boolean + request: { + chainId: 123 + abi: readonly [ + { + readonly name: 'transferFrom' + readonly type: 'function' + readonly stateMutability: 'nonpayable' + readonly inputs: readonly [ + { readonly type: 'address'; readonly name: 'sender' }, + { readonly type: 'address'; readonly name: 'recipient' }, + { readonly type: 'uint256'; readonly name: 'amount' }, + ] + readonly outputs: readonly [{ type: 'bool' }] + }, + ] + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + } + } + | undefined + >() +}) + +test('select data', () => { + const useSimulateErc20 = createUseSimulateContract({ + abi: abi.erc20, + }) + + const result = useSimulateErc20({ + address: '0x', + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + query: { + select(data) { + expectTypeOf(data.result).toEqualTypeOf() + return data?.toString() + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) + +test('multichain address', () => { + const useSimulateErc20 = createUseSimulateContract({ + abi: abi.erc20, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + }) + + const result = useSimulateErc20({ + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: optimism.id, + }) + expectTypeOf(result.data?.result).toEqualTypeOf() + + useSimulateErc20({ + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + // @ts-expect-error chain id must match address keys + chainId: 420, + }) + + useSimulateErc20({ + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + // @ts-expect-error address not allowed + address: '0x', + }) +}) + +test('overloads', () => { + const useSimulateWriteOverloads = createUseSimulateContract({ + abi: abi.writeOverloads, + }) + + const result1 = useSimulateWriteOverloads({ + functionName: 'foo', + }) + assertType(result1.data?.result) + + const result2 = useSimulateWriteOverloads({ + functionName: 'foo', + args: [], + }) + assertType(result2.data?.result) + + const result3 = useSimulateWriteOverloads({ + functionName: 'foo', + args: ['0x'], + }) + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + assertType(result3.data?.result) + + const result4 = useSimulateWriteOverloads({ + functionName: 'foo', + args: ['0x', '0x'], + }) + assertType< + | { + foo: `0x${string}` + bar: `0x${string}` + } + | undefined + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + >(result4.data?.result) +}) + +test('functionName', () => { + const useSimulateErc20 = createUseSimulateContract({ + abi: abi.erc20, + functionName: 'transferFrom', + }) + + const result = useSimulateErc20({ + args: ['0x', '0x', 123n], + chainId: 123, + }) + result.data?.request.chainId + expectTypeOf(result.data).toMatchTypeOf< + | { + result: boolean + request: { + chainId: 123 + abi: readonly [ + { + readonly name: 'transferFrom' + readonly type: 'function' + readonly stateMutability: 'nonpayable' + readonly inputs: readonly [ + { readonly type: 'address'; readonly name: 'sender' }, + { readonly type: 'address'; readonly name: 'recipient' }, + { readonly type: 'uint256'; readonly name: 'amount' }, + ] + readonly outputs: readonly [{ type: 'bool' }] + }, + ] + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + } + } + | undefined + >() +}) + +test('functionName with overloads', () => { + const useSimulateWriteOverloads = createUseSimulateContract({ + abi: abi.writeOverloads, + functionName: 'foo', + }) + + const result1 = useSimulateWriteOverloads({}) + assertType(result1.data?.result) + + const result2 = useSimulateWriteOverloads({ + args: [], + }) + assertType(result2.data?.result) + + const result3 = useSimulateWriteOverloads({ + args: ['0x'], + }) + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + assertType(result3.data?.result) + + const result4 = useSimulateWriteOverloads({ + args: ['0x', '0x'], + }) + assertType< + | { + foo: `0x${string}` + bar: `0x${string}` + } + | undefined + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + >(result4.data?.result) +}) diff --git a/packages/react/src/hooks/codegen/createUseSimulateContract.test.ts b/packages/react/src/hooks/codegen/createUseSimulateContract.test.ts new file mode 100644 index 0000000000..c6e70b90ca --- /dev/null +++ b/packages/react/src/hooks/codegen/createUseSimulateContract.test.ts @@ -0,0 +1,258 @@ +import { connect, disconnect } from '@wagmi/core' +import { abi, address, chain, config } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { createUseSimulateContract } from './createUseSimulateContract.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const useSimulateWagmiMintExample = createUseSimulateContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + }) + + const { result } = renderHook(() => + useSimulateWagmiMintExample({ + functionName: 'mint', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "chainId": 1, + "request": { + "abi": [ + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": undefined, + "chainId": 1, + "dataSuffix": undefined, + "functionName": "mint", + }, + "result": undefined, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "simulateContract", + { + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 1, + "functionName": "mint", + }, + ], + "refetch": [Function], + "status": "success", + } + `) + + await disconnect(config, { connector }) +}) + +test('multichain', async () => { + await connect(config, { connector }) + + const useReadWagmiMintExample = createUseSimulateContract({ + address: { + [chain.mainnet.id]: address.wagmiMintExample, + [chain.mainnet2.id]: address.wagmiMintExample, + }, + abi: abi.wagmiMintExample, + }) + + const { result } = renderHook(() => + useReadWagmiMintExample({ + functionName: 'mint', + chainId: chain.mainnet2.id, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "chainId": 456, + "request": { + "abi": [ + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": undefined, + "chainId": 456, + "dataSuffix": undefined, + "functionName": "mint", + }, + "result": undefined, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "simulateContract", + { + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 456, + "functionName": "mint", + }, + ], + "refetch": [Function], + "status": "success", + } + `) + + await disconnect(config, { connector }) +}) + +test('functionName', async () => { + await connect(config, { connector }) + + const useSimulateWagmiMintExample = createUseSimulateContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'mint', + }) + + const { result } = renderHook(() => useSimulateWagmiMintExample({})) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "chainId": 1, + "request": { + "abi": [ + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": undefined, + "chainId": 1, + "dataSuffix": undefined, + "functionName": "mint", + }, + "result": undefined, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "simulateContract", + { + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 1, + "functionName": "mint", + }, + ], + "refetch": [Function], + "status": "success", + } + `) + + await disconnect(config, { connector }) +}) diff --git a/packages/react/src/hooks/codegen/createUseSimulateContract.ts b/packages/react/src/hooks/codegen/createUseSimulateContract.ts new file mode 100644 index 0000000000..51758b995a --- /dev/null +++ b/packages/react/src/hooks/codegen/createUseSimulateContract.ts @@ -0,0 +1,120 @@ +import type { + Config, + ResolvedRegister, + SimulateContractErrorType, + SimulateContractParameters, +} from '@wagmi/core' +import type { ScopeKeyParameter, UnionExactPartial } from '@wagmi/core/internal' +import type { + SimulateContractData, + SimulateContractQueryFnData, + SimulateContractQueryKey, +} from '@wagmi/core/query' +import type { + Abi, + Address, + ContractFunctionArgs, + ContractFunctionName, +} from 'viem' + +import type { ConfigParameter, QueryParameter } from '../../types/properties.js' +import { useAccount } from '../useAccount.js' +import { useChainId } from '../useChainId.js' +import { useConfig } from '../useConfig.js' +import { + type UseSimulateContractReturnType, + useSimulateContract, +} from '../useSimulateContract.js' + +type stateMutability = 'nonpayable' | 'payable' + +export type CreateUseSimulateContractParameters< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined = undefined, + functionName extends + | ContractFunctionName + | undefined = undefined, +> = { + abi: abi | Abi | readonly unknown[] + address?: address | Address | Record | undefined + functionName?: + | functionName + | ContractFunctionName + | undefined +} + +export type CreateUseSimulateContractReturnType< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined, + functionName extends ContractFunctionName | undefined, +> = < + name extends functionName extends ContractFunctionName + ? functionName + : ContractFunctionName, + args extends ContractFunctionArgs, + config extends Config = ResolvedRegister['config'], + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = SimulateContractData, +>( + parameters?: { + abi?: undefined + address?: address extends undefined ? Address : undefined + functionName?: functionName extends undefined ? name : undefined + chainId?: address extends Record + ? + | keyof address + | (chainId extends keyof address ? chainId : never) + | undefined + : chainId | number | undefined + } & UnionExactPartial< + // TODO: Take `abi` and `address` from above and omit from below (currently breaks inference) + SimulateContractParameters + > & + ScopeKeyParameter & + ConfigParameter & + QueryParameter< + SimulateContractQueryFnData, + SimulateContractErrorType, + selectData, + SimulateContractQueryKey + >, +) => UseSimulateContractReturnType + +export function createUseSimulateContract< + const abi extends Abi | readonly unknown[], + const address extends + | Address + | Record + | undefined = undefined, + functionName extends + | ContractFunctionName + | undefined = undefined, +>( + props: CreateUseSimulateContractParameters, +): CreateUseSimulateContractReturnType { + if (props.address !== undefined && typeof props.address === 'object') + return (parameters) => { + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + const account = useAccount({ config }) + const chainId = + (parameters as { chainId?: number })?.chainId ?? + account.chainId ?? + configChainId + return useSimulateContract({ + ...(parameters as any), + ...(props.functionName ? { functionName: props.functionName } : {}), + address: props.address?.[chainId], + abi: props.abi, + }) + } + + return (parameters) => { + return useSimulateContract({ + ...(parameters as any), + ...(props.address ? { address: props.address } : {}), + ...(props.functionName ? { functionName: props.functionName } : {}), + abi: props.abi, + }) + } +} diff --git a/packages/react/src/hooks/codegen/createUseWatchContractEvent.test-d.ts b/packages/react/src/hooks/codegen/createUseWatchContractEvent.test-d.ts new file mode 100644 index 0000000000..b3a69775b8 --- /dev/null +++ b/packages/react/src/hooks/codegen/createUseWatchContractEvent.test-d.ts @@ -0,0 +1,123 @@ +import { http, createConfig, webSocket } from '@wagmi/core' +import { abi, mainnet, optimism } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { createUseWatchContractEvent } from './createUseWatchContractEvent.js' + +test('default', () => { + const useWatchErc20Event = createUseWatchContractEvent({ + abi: abi.erc20, + }) + + useWatchErc20Event({ + eventName: 'Transfer', + chainId: 123, + onLogs(logs) { + expectTypeOf(logs[0]!.eventName).toEqualTypeOf<'Transfer'>() + expectTypeOf(logs[0]!.args).toEqualTypeOf<{ + from?: `0x${string}` | undefined + to?: `0x${string}` | undefined + value?: bigint | undefined + }>() + }, + }) +}) + +test('multichain address', () => { + const useWatchErc20Event = createUseWatchContractEvent({ + abi: abi.erc20, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + }) + + useWatchErc20Event({ + eventName: 'Transfer', + chainId: mainnet.id, + // ^? + }) + + useWatchErc20Event({ + eventName: 'Transfer', + // @ts-expect-error chain id must match address keys + chainId: 420, + }) + + useWatchErc20Event({ + eventName: 'Transfer', + // @ts-expect-error chain id must match address keys + address: '0x', + }) +}) + +test('differing transports', () => { + const useWatchErc20Event = createUseWatchContractEvent({ + abi: abi.erc20, + }) + + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + useWatchErc20Event({ + config, + poll: false, + address: '0x', + onLogs() {}, + }) + + useWatchErc20Event({ + config, + chainId: mainnet.id, + poll: true, + address: '0x', + onLogs() {}, + }) + useWatchErc20Event({ + config, + chainId: mainnet.id, + // @ts-expect-error poll required since http transport + poll: false, + address: '0x', + onLogs() {}, + }) + + useWatchErc20Event({ + config, + chainId: optimism.id, + poll: true, + address: '0x', + onLogs() {}, + }) + useWatchErc20Event({ + config, + chainId: optimism.id, + poll: false, + address: '0x', + onLogs() {}, + }) +}) + +test('eventName', () => { + const useWatchErc20Event = createUseWatchContractEvent({ + abi: abi.erc20, + eventName: 'Transfer', + }) + + useWatchErc20Event({ + chainId: 123, + onLogs(logs) { + expectTypeOf(logs[0]!.eventName).toEqualTypeOf<'Transfer'>() + expectTypeOf(logs[0]!.args).toEqualTypeOf<{ + from?: `0x${string}` | undefined + to?: `0x${string}` | undefined + value?: bigint | undefined + }>() + }, + }) +}) diff --git a/packages/react/src/hooks/codegen/createUseWatchContractEvent.test.ts b/packages/react/src/hooks/codegen/createUseWatchContractEvent.test.ts new file mode 100644 index 0000000000..61464fe3d2 --- /dev/null +++ b/packages/react/src/hooks/codegen/createUseWatchContractEvent.test.ts @@ -0,0 +1,44 @@ +import { abi, address, chain } from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import type { WatchEventOnLogsParameter } from 'viem' +import { test } from 'vitest' + +import { createUseWatchContractEvent } from './createUseWatchContractEvent.js' + +test('default', async () => { + const useWatchErc20Event = createUseWatchContractEvent({ + address: address.usdc, + abi: abi.wagmiMintExample, + }) + + let logs: WatchEventOnLogsParameter = [] + renderHook(() => + useWatchErc20Event({ + eventName: 'Transfer', + onLogs(next) { + logs = logs.concat(next) + }, + }), + ) +}) + +test('multichain', async () => { + const useWatchErc20Event = createUseWatchContractEvent({ + address: { + [chain.mainnet.id]: address.usdc, + [chain.mainnet2.id]: address.usdc, + }, + abi: abi.wagmiMintExample, + }) + + let logs: WatchEventOnLogsParameter = [] + renderHook(() => + useWatchErc20Event({ + eventName: 'Transfer', + chainId: chain.mainnet2.id, + onLogs(next) { + logs = logs.concat(next) + }, + }), + ) +}) diff --git a/packages/react/src/hooks/codegen/createUseWatchContractEvent.ts b/packages/react/src/hooks/codegen/createUseWatchContractEvent.ts new file mode 100644 index 0000000000..e453b9442b --- /dev/null +++ b/packages/react/src/hooks/codegen/createUseWatchContractEvent.ts @@ -0,0 +1,101 @@ +import type { + Config, + ResolvedRegister, + WatchContractEventParameters, +} from '@wagmi/core' +import type { + UnionCompute, + UnionExactPartial, + UnionStrictOmit, +} from '@wagmi/core/internal' +import type { Abi, Address, ContractEventName } from 'viem' + +import type { + ConfigParameter, + EnabledParameter, +} from '../../types/properties.js' +import { useAccount } from '../useAccount.js' +import { useChainId } from '../useChainId.js' +import { useConfig } from '../useConfig.js' +import { useWatchContractEvent } from '../useWatchContractEvent.js' + +export type CreateUseWatchContractEventParameters< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined = undefined, + eventName extends ContractEventName | undefined = undefined, +> = { + abi: abi | Abi | readonly unknown[] + address?: address | Address | Record | undefined + eventName?: eventName | ContractEventName | undefined +} + +export type CreateUseWatchContractEventReturnType< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined, + eventName extends ContractEventName | undefined, + /// + omittedProperties extends 'abi' | 'address' | 'chainId' | 'eventName' = + | 'abi' + | (address extends undefined ? never : 'address') + | (address extends Record ? 'chainId' : never) + | (eventName extends undefined ? never : 'eventName'), +> = < + name extends eventName extends ContractEventName + ? eventName + : ContractEventName, + strict extends boolean | undefined = undefined, + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + parameters?: UnionCompute< + UnionExactPartial< + UnionStrictOmit< + WatchContractEventParameters, + omittedProperties + > + > & + ConfigParameter & + EnabledParameter + > & + (address extends Record + ? { chainId?: keyof address | undefined } + : unknown), +) => void + +export function createUseWatchContractEvent< + const abi extends Abi | readonly unknown[], + const address extends + | Address + | Record + | undefined = undefined, + eventName extends ContractEventName | undefined = undefined, +>( + props: CreateUseWatchContractEventParameters, +): CreateUseWatchContractEventReturnType { + if (props.address !== undefined && typeof props.address === 'object') + return (parameters) => { + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + const account = useAccount({ config }) + const chainId = + (parameters as { chainId?: number })?.chainId ?? + account.chainId ?? + configChainId + return useWatchContractEvent({ + ...(parameters as any), + ...(props.eventName ? { eventName: props.eventName } : {}), + address: props.address?.[chainId], + abi: props.abi, + }) + } + + return (parameters) => { + return useWatchContractEvent({ + ...(parameters as any), + ...(props.address ? { address: props.address } : {}), + ...(props.eventName ? { eventName: props.eventName } : {}), + abi: props.abi, + }) + } +} diff --git a/packages/react/src/hooks/codegen/createUseWriteContract.test-d.ts b/packages/react/src/hooks/codegen/createUseWriteContract.test-d.ts new file mode 100644 index 0000000000..14906fda41 --- /dev/null +++ b/packages/react/src/hooks/codegen/createUseWriteContract.test-d.ts @@ -0,0 +1,153 @@ +import { abi } from '@wagmi/test' +import type { Address, Hash } from 'viem' +import { mainnet, optimism } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { useSimulateContract } from '../useSimulateContract.js' +import { createUseWriteContract } from './createUseWriteContract.js' + +const contextValue = { foo: 'bar' } as const + +test('default', () => { + const useWriteErc20 = createUseWriteContract({ + abi: abi.erc20, + }) + + const { writeContract } = useWriteErc20() + writeContract({ + address: '0x', + functionName: 'transfer', + args: ['0x', 123n], + }) +}) + +test('context', () => { + const useWriteErc20 = createUseWriteContract({ + abi: abi.erc20, + }) + + const { writeContract } = useWriteErc20({ + mutation: { + onMutate() { + return contextValue + }, + onSuccess(data, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(variables.functionName).toEqualTypeOf() + expectTypeOf(variables.args).toEqualTypeOf< + readonly unknown[] | undefined + >() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + writeContract( + { + address: '0x', + functionName: 'transfer', + args: ['0x', 123n], + }, + { + onSuccess(data, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(variables.functionName).toEqualTypeOf<'transfer'>() + expectTypeOf(variables.args).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) + +test('multichain address', () => { + const useWriteErc20 = createUseWriteContract({ + abi: abi.erc20, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + }) + + const { writeContract } = useWriteErc20() + writeContract({ + functionName: 'transfer', + args: ['0x', 123n], + chainId: mainnet.id, + // ^? + }) + + writeContract({ + functionName: 'transfer', + args: ['0x', 123n], + // @ts-expect-error chain id must match address keys + chainId: 420, + }) + + writeContract({ + // @ts-expect-error address not allowed + address: '0x', + functionName: 'transfer', + args: ['0x', 123n], + }) +}) + +test('overloads', () => { + const useWriteOverloads = createUseWriteContract({ + abi: abi.writeOverloads, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + }) + + const { writeContract } = useWriteOverloads() + writeContract({ + functionName: 'foo', + args: [], + }) + + writeContract({ + functionName: 'foo', + args: ['0x'], + }) + + writeContract({ + functionName: 'foo', + args: ['0x', '0x'], + }) +}) + +test('useSimulateContract', () => { + const useWriteErc20 = createUseWriteContract({ + abi: abi.erc20, + address: { + [mainnet.id]: '0x', + [optimism.id]: '0x', + }, + }) + + const { data } = useSimulateContract({ + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 1, + }) + const { writeContract } = useWriteErc20() + + const request = data?.request + if (request) writeContract(request) +}) + +test('functionName', () => { + const useWriteErc20 = createUseWriteContract({ + abi: abi.erc20, + functionName: 'transfer', + }) + + const { writeContract } = useWriteErc20() + writeContract({ + address: '0x', + args: ['0x', 123n], + }) +}) diff --git a/packages/react/src/hooks/codegen/createUseWriteContract.test.ts b/packages/react/src/hooks/codegen/createUseWriteContract.test.ts new file mode 100644 index 0000000000..e89dc62141 --- /dev/null +++ b/packages/react/src/hooks/codegen/createUseWriteContract.test.ts @@ -0,0 +1,13 @@ +import { abi } from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import { test } from 'vitest' + +import { createUseWriteContract } from './createUseWriteContract.js' + +test('default', () => { + const useWriteErc20 = createUseWriteContract({ + abi: abi.erc20, + }) + + renderHook(() => useWriteErc20()) +}) diff --git a/packages/react/src/hooks/codegen/createUseWriteContract.ts b/packages/react/src/hooks/codegen/createUseWriteContract.ts new file mode 100644 index 0000000000..9e58fd973b --- /dev/null +++ b/packages/react/src/hooks/codegen/createUseWriteContract.ts @@ -0,0 +1,297 @@ +import type { MutateOptions } from '@tanstack/react-query' +import type { + Config, + ResolvedRegister, + WriteContractErrorType, +} from '@wagmi/core' +import type { + ChainIdParameter, + Compute, + ConnectorParameter, + SelectChains, + UnionCompute, + UnionStrictOmit, +} from '@wagmi/core/internal' +import type { + WriteContractData, + WriteContractVariables, +} from '@wagmi/core/query' +import { useCallback } from 'react' +import type { + Abi, + Account, + Address, + Chain, + ContractFunctionArgs, + ContractFunctionName, +} from 'viem' +import type { WriteContractParameters as viem_WriteContractParameters } from 'viem/actions' + +import { useAccount } from '../useAccount.js' +import { useChainId } from '../useChainId.js' +import { useConfig } from '../useConfig.js' +import { + type UseWriteContractParameters, + useWriteContract, + type UseWriteContractReturnType as wagmi_UseWriteContractReturnType, +} from '../useWriteContract.js' + +type stateMutability = 'nonpayable' | 'payable' + +export type CreateUseWriteContractParameters< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined = undefined, + functionName extends + | ContractFunctionName + | undefined = undefined, +> = { + abi: abi | Abi | readonly unknown[] + address?: address | Address | Record | undefined + functionName?: + | functionName + | ContractFunctionName + | undefined +} + +export type CreateUseWriteContractReturnType< + abi extends Abi | readonly unknown[], + address extends Address | Record | undefined, + functionName extends ContractFunctionName | undefined, +> = ( + parameters?: UseWriteContractParameters, +) => Compute< + Omit< + wagmi_UseWriteContractReturnType, + 'writeContract' | 'writeContractAsync' + > & { + writeContract: < + const abi2 extends abi, + name extends functionName extends ContractFunctionName< + abi, + stateMutability + > + ? functionName + : ContractFunctionName, + args extends ContractFunctionArgs, + chainId extends config['chains'][number]['id'], + >( + variables: Variables< + abi2, + functionName, + name, + args, + config, + chainId, + address + >, + options?: + | MutateOptions< + WriteContractData, + WriteContractErrorType, + WriteContractVariables< + abi2, + name, + args, + config, + chainId, + // use `functionName` to make sure it's not union of all possible function names + name + >, + context + > + | undefined, + ) => void + writeContractAsync: < + const abi2 extends abi, + name extends functionName extends ContractFunctionName< + abi, + stateMutability + > + ? functionName + : ContractFunctionName, + args extends ContractFunctionArgs, + chainId extends config['chains'][number]['id'], + >( + variables: Variables< + abi2, + functionName, + name, + args, + config, + chainId, + address + >, + options?: + | MutateOptions< + WriteContractData, + WriteContractErrorType, + WriteContractVariables< + abi2, + name, + args, + config, + chainId, + // use `functionName` to make sure it's not union of all possible function names + name + >, + context + > + | undefined, + ) => Promise + } +> + +export function createUseWriteContract< + const abi extends Abi | readonly unknown[], + const address extends + | Address + | Record + | undefined = undefined, + functionName extends + | ContractFunctionName + | undefined = undefined, +>( + props: CreateUseWriteContractParameters, +): CreateUseWriteContractReturnType { + if (props.address !== undefined && typeof props.address === 'object') + return (parameters) => { + const config = useConfig(parameters) + const result = useWriteContract(parameters) + const configChainId = useChainId({ config }) + const account = useAccount({ config }) + type Args = Parameters + return { + ...(result as any), + writeContract: useCallback( + (...args: Args) => { + let chainId: number | undefined + if (args[0].chainId) chainId = args[0].chainId + else if (args[0].account && args[0].account === account.address) + chainId = account.chainId + else if (args[0].account === undefined) chainId = account.chainId + else chainId = configChainId + + const variables = { + ...(args[0] as any), + address: chainId ? props.address?.[chainId] : undefined, + ...(props.functionName + ? { functionName: props.functionName } + : {}), + abi: props.abi, + } + result.writeContract(variables, args[1] as any) + }, + [ + account.address, + account.chainId, + props, + configChainId, + result.writeContract, + ], + ), + writeContractAsync: useCallback( + (...args: Args) => { + let chainId: number | undefined + if (args[0].chainId) chainId = args[0].chainId + else if (args[0].account && args[0].account === account.address) + chainId = account.chainId + else if (args[0].account === undefined) chainId = account.chainId + else chainId = configChainId + + const variables = { + ...(args[0] as any), + address: chainId ? props.address?.[chainId] : undefined, + ...(props.functionName + ? { functionName: props.functionName } + : {}), + abi: props.abi, + } + return result.writeContractAsync(variables, args[1] as any) + }, + [ + account.address, + account.chainId, + props, + configChainId, + result.writeContractAsync, + ], + ), + } + } + + return (parameters) => { + const result = useWriteContract(parameters) + type Args = Parameters + return { + ...(result as any), + writeContract: useCallback( + (...args: Args) => { + const variables = { + ...(args[0] as any), + ...(props.address ? { address: props.address } : {}), + ...(props.functionName ? { functionName: props.functionName } : {}), + abi: props.abi, + } + result.writeContract(variables, args[1] as any) + }, + [props, result.writeContract], + ), + writeContractAsync: useCallback( + (...args: Args) => { + const variables = { + ...(args[0] as any), + ...(props.address ? { address: props.address } : {}), + ...(props.functionName ? { functionName: props.functionName } : {}), + abi: props.abi, + } + return result.writeContractAsync(variables, args[1] as any) + }, + [props, result.writeContractAsync], + ), + } + } +} + +type Variables< + abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName | undefined, + name extends ContractFunctionName, + args extends ContractFunctionArgs, + config extends Config, + chainId extends config['chains'][number]['id'], + address extends Address | Record | undefined, + /// + allFunctionNames = ContractFunctionName, + chains extends readonly Chain[] = SelectChains, + omittedProperties extends 'abi' | 'address' | 'functionName' = + | 'abi' + | (address extends undefined ? never : 'address') + | (functionName extends undefined ? never : 'functionName'), +> = UnionCompute< + { + [key in keyof chains]: UnionStrictOmit< + viem_WriteContractParameters< + abi, + name, + args, + chains[key], + Account, + chains[key], + allFunctionNames + >, + omittedProperties | 'chain' + > + }[number] & + (address extends Record + ? { + chainId?: + | keyof address + | (chainId extends keyof address ? chainId : never) + | undefined + } + : Compute>) & + ConnectorParameter & { + /** @deprecated */ + __mode?: 'prepared' + } +> diff --git a/packages/react/src/hooks/useAccount.test-d.ts b/packages/react/src/hooks/useAccount.test-d.ts new file mode 100644 index 0000000000..a22d816d6a --- /dev/null +++ b/packages/react/src/hooks/useAccount.test-d.ts @@ -0,0 +1,68 @@ +import type { Connector } from '@wagmi/core' +import type { Address, Chain } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { useAccount } from './useAccount.js' + +test('states', () => { + const result = useAccount() + + switch (result.status) { + case 'reconnecting': { + expectTypeOf(result).toMatchTypeOf<{ + address: Address | undefined + chain: Chain | undefined + chainId: number | undefined + connector: Connector | undefined + isConnected: boolean + isConnecting: false + isDisconnected: false + isReconnecting: true + status: 'reconnecting' + }>() + break + } + case 'connecting': { + expectTypeOf(result).toMatchTypeOf<{ + address: Address | undefined + chain: Chain | undefined + chainId: number | undefined + connector: Connector | undefined + isConnected: false + isReconnecting: false + isConnecting: true + isDisconnected: false + status: 'connecting' + }>() + break + } + case 'connected': { + expectTypeOf(result).toMatchTypeOf<{ + address: Address + chain: Chain | undefined + chainId: number + connector: Connector + isConnected: true + isConnecting: false + isDisconnected: false + isReconnecting: false + status: 'connected' + }>() + break + } + case 'disconnected': { + expectTypeOf(result).toMatchTypeOf<{ + address: undefined + chain: undefined + chainId: undefined + connector: undefined + isConnected: false + isReconnecting: false + isConnecting: false + isDisconnected: true + status: 'disconnected' + }>() + break + } + } +}) diff --git a/packages/react/src/hooks/useAccount.test.ts b/packages/react/src/hooks/useAccount.test.ts new file mode 100644 index 0000000000..3c4af3c3f9 --- /dev/null +++ b/packages/react/src/hooks/useAccount.test.ts @@ -0,0 +1,29 @@ +import { connect, disconnect } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import { Fragment, createElement } from 'react' +import { expect, test } from 'vitest' + +import { useAccount } from './useAccount.js' + +test('default', async () => { + const { result, rerender } = renderHook(() => useAccount()) + + expect(result.current.address).not.toBeDefined() + expect(result.current.status).toEqual('disconnected') + + await connect(config, { connector: config.connectors[0]! }) + rerender() + + expect(result.current.address).toBeDefined() + expect(result.current.status).toEqual('connected') + + await disconnect(config) +}) + +test('parameters: config', () => { + const { result } = renderHook(() => useAccount({ config }), { + wrapper: ({ children }) => createElement(Fragment, { children }), + }) + expect(result.current).toBeDefined() +}) diff --git a/packages/react/src/hooks/useAccount.ts b/packages/react/src/hooks/useAccount.ts new file mode 100644 index 0000000000..c7c1779469 --- /dev/null +++ b/packages/react/src/hooks/useAccount.ts @@ -0,0 +1,31 @@ +'use client' + +import { + type Config, + type GetAccountReturnType, + type ResolvedRegister, + getAccount, + watchAccount, +} from '@wagmi/core' + +import type { ConfigParameter } from '../types/properties.js' +import { useConfig } from './useConfig.js' +import { useSyncExternalStoreWithTracked } from './useSyncExternalStoreWithTracked.js' + +export type UseAccountParameters = + ConfigParameter + +export type UseAccountReturnType = + GetAccountReturnType + +/** https://wagmi.sh/react/api/hooks/useAccount */ +export function useAccount( + parameters: UseAccountParameters = {}, +): UseAccountReturnType { + const config = useConfig(parameters) + + return useSyncExternalStoreWithTracked( + (onChange) => watchAccount(config, { onChange }), + () => getAccount(config), + ) +} diff --git a/packages/react/src/hooks/useAccountEffect.test.ts b/packages/react/src/hooks/useAccountEffect.test.ts new file mode 100644 index 0000000000..b252ee0f98 --- /dev/null +++ b/packages/react/src/hooks/useAccountEffect.test.ts @@ -0,0 +1,77 @@ +import { mock } from '@wagmi/connectors' +import { http, connect, createConfig, disconnect } from '@wagmi/core' +import { accounts, chain, config } from '@wagmi/test' +import { createWrapper, renderHook, waitFor } from '@wagmi/test/react' +import { Fragment, createElement } from 'react' +import { expect, test, vi } from 'vitest' + +import { WagmiProvider } from '../context.js' +import { useAccountEffect } from './useAccountEffect.js' +import { useConnect } from './useConnect.js' +import { useDisconnect } from './useDisconnect.js' + +test('parameters: config', () => { + const { result } = renderHook(() => useAccountEffect({ config }), { + wrapper: ({ children }) => createElement(Fragment, { children }), + }) + expect(result.current).toBeUndefined() +}) + +test('behavior: connect and disconnect called once', async () => { + const onConnect = vi.fn() + const onDisconnect = vi.fn() + + const { result } = renderHook(() => ({ + useAccountEffect: useAccountEffect({ onConnect, onDisconnect }), + useConnect: useConnect(), + useDisconnect: useDisconnect(), + })) + + result.current.useConnect.connect({ + connector: result.current.useConnect.connectors[0]!, + }) + await waitFor(() => expect(result.current.useConnect.isSuccess).toBeTruthy()) + + result.current.useConnect.connect({ + connector: result.current.useConnect.connectors[0]!, + }) + await waitFor(() => expect(result.current.useConnect.isSuccess).toBeTruthy()) + + result.current.useDisconnect.disconnect() + await waitFor(() => + expect(result.current.useDisconnect.isSuccess).toBeTruthy(), + ) + result.current.useDisconnect.disconnect() + await waitFor(() => + expect(result.current.useDisconnect.isSuccess).toBeTruthy(), + ) + + expect(onConnect).toBeCalledTimes(1) + expect(onDisconnect).toBeCalledTimes(1) +}) + +test('behavior: connect called on reconnect', async () => { + const config = createConfig({ + chains: [chain.mainnet], + connectors: [ + mock({ + accounts, + features: { reconnect: true }, + }), + ], + transports: { [chain.mainnet.id]: http() }, + }) + + await connect(config, { connector: config.connectors[0]! }) + const onConnect = vi.fn((data) => { + expect(data.isReconnected).toBeTruthy() + }) + + renderHook(() => useAccountEffect({ onConnect }), { + wrapper: createWrapper(WagmiProvider, { config, reconnectOnMount: true }), + }) + + await waitFor(() => expect(onConnect).toBeCalledTimes(1)) + + await disconnect(config) +}) diff --git a/packages/react/src/hooks/useAccountEffect.ts b/packages/react/src/hooks/useAccountEffect.ts new file mode 100644 index 0000000000..5c77585e35 --- /dev/null +++ b/packages/react/src/hooks/useAccountEffect.ts @@ -0,0 +1,62 @@ +'use client' + +import { type GetAccountReturnType, watchAccount } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { useEffect } from 'react' + +import type { ConfigParameter } from '../types/properties.js' +import { useConfig } from './useConfig.js' + +export type UseAccountEffectParameters = Compute< + { + onConnect?( + data: Compute< + Pick< + Extract, + 'address' | 'addresses' | 'chain' | 'chainId' | 'connector' + > & { + isReconnected: boolean + } + >, + ): void + onDisconnect?(): void + } & ConfigParameter +> + +/** https://wagmi.sh/react/api/hooks/useAccountEffect */ +export function useAccountEffect(parameters: UseAccountEffectParameters = {}) { + const { onConnect, onDisconnect } = parameters + + const config = useConfig(parameters) + + useEffect(() => { + return watchAccount(config, { + onChange(data, prevData) { + if ( + (prevData.status === 'reconnecting' || + (prevData.status === 'connecting' && + prevData.address === undefined)) && + data.status === 'connected' + ) { + const { address, addresses, chain, chainId, connector } = data + const isReconnected = + prevData.status === 'reconnecting' || + // if `previousAccount.status` is `undefined`, the connector connected immediately. + prevData.status === undefined + onConnect?.({ + address, + addresses, + chain, + chainId, + connector, + isReconnected, + }) + } else if ( + prevData.status === 'connected' && + data.status === 'disconnected' + ) + onDisconnect?.() + }, + }) + }, [config, onConnect, onDisconnect]) +} diff --git a/packages/react/src/hooks/useBalance.test-d.ts b/packages/react/src/hooks/useBalance.test-d.ts new file mode 100644 index 0000000000..74630d50c7 --- /dev/null +++ b/packages/react/src/hooks/useBalance.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useBalance } from './useBalance.js' + +test('select data', () => { + const result = useBalance({ + query: { + select(data) { + return data?.value + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useBalance.test.ts b/packages/react/src/hooks/useBalance.test.ts new file mode 100644 index 0000000000..ba7f857808 --- /dev/null +++ b/packages/react/src/hooks/useBalance.test.ts @@ -0,0 +1,312 @@ +import { accounts, chain, testClient, wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { type Address, parseEther } from 'viem' +import { beforeEach, expect, test } from 'vitest' + +import { useBalance } from './useBalance.js' + +const address = accounts[0] + +beforeEach(async () => { + await testClient.mainnet.setBalance({ address, value: parseEther('10000') }) + await testClient.mainnet.mine({ blocks: 1 }) + await testClient.mainnet2.setBalance({ address, value: parseEther('69') }) + await testClient.mainnet2.mine({ blocks: 1 }) +}) + +test('default', async () => { + const { result } = renderHook(() => useBalance({ address })) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toMatchObject( + expect.objectContaining({ + decimals: expect.any(Number), + formatted: expect.any(String), + symbol: expect.any(String), + value: expect.any(BigInt), + }), + ) + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "balance", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: chainId', async () => { + const { result } = renderHook(() => + useBalance({ address, chainId: chain.mainnet2.id }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "decimals": 18, + "formatted": "69", + "symbol": "WAG", + "value": 69000000000000000000n, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "balance", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 456, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: token', async () => { + const { result } = renderHook(() => + useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + token: '0x6B175474E89094C44Da98b954EedeAC495271d0F', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "decimals": 18, + "formatted": "0.559062564299199392", + "symbol": "DAI", + "value": 559062564299199392n, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "balance", + { + "address": "0x4557B18E779944BFE9d78A672452331C186a9f48", + "chainId": 1, + "token": "0x6B175474E89094C44Da98b954EedeAC495271d0F", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: unit', async () => { + const { result } = renderHook(() => + useBalance({ address, chainId: chain.mainnet2.id, unit: 'wei' }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "decimals": 18, + "formatted": "69000000000000000000", + "symbol": "WAG", + "value": 69000000000000000000n, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "balance", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 456, + "unit": "wei", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: address: undefined -> defined', async () => { + let address: Address | undefined = undefined + + const { result, rerender } = renderHook(() => useBalance({ address })) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "balance", + { + "address": undefined, + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + + address = accounts[0] + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "decimals": 18, + "formatted": "10000", + "symbol": "ETH", + "value": 10000000000000000000000n, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "balance", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useBalance()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useBalance.ts b/packages/react/src/hooks/useBalance.ts new file mode 100644 index 0000000000..93568089f7 --- /dev/null +++ b/packages/react/src/hooks/useBalance.ts @@ -0,0 +1,54 @@ +'use client' + +import type { Config, GetBalanceErrorType, ResolvedRegister } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetBalanceData, + type GetBalanceOptions, + type GetBalanceQueryKey, + getBalanceQueryOptions, +} from '@wagmi/core/query' +import type { GetBalanceQueryFnData } from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseBalanceParameters< + config extends Config = Config, + selectData = GetBalanceData, +> = Compute< + GetBalanceOptions & + ConfigParameter & + QueryParameter< + GetBalanceQueryFnData, + GetBalanceErrorType, + selectData, + GetBalanceQueryKey + > +> + +export type UseBalanceReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useBalance */ +export function useBalance< + config extends Config = ResolvedRegister['config'], + selectData = GetBalanceData, +>( + parameters: UseBalanceParameters = {}, +): UseBalanceReturnType { + const { address, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getBalanceQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(address && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useBlock.test-d.ts b/packages/react/src/hooks/useBlock.test-d.ts new file mode 100644 index 0000000000..04aae75076 --- /dev/null +++ b/packages/react/src/hooks/useBlock.test-d.ts @@ -0,0 +1,64 @@ +import { http, createConfig, webSocket } from '@wagmi/core' +import { mainnet, optimism } from '@wagmi/core/chains' +import { expectTypeOf, test } from 'vitest' + +import { useBlock } from './useBlock.js' + +test('select data', () => { + const result = useBlock({ + query: { + select(data) { + return data?.number + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + useBlock({ + config, + watch: { + poll: false, + }, + }) + + useBlock({ + config, + chainId: mainnet.id, + watch: { + poll: true, + }, + }) + useBlock({ + config, + chainId: mainnet.id, + watch: { + // @ts-expect-error + poll: false, + }, + }) + + useBlock({ + config, + chainId: optimism.id, + watch: { + poll: true, + }, + }) + useBlock({ + config, + chainId: optimism.id, + watch: { + poll: false, + }, + }) +}) diff --git a/packages/react/src/hooks/useBlock.test.ts b/packages/react/src/hooks/useBlock.test.ts new file mode 100644 index 0000000000..0d2095ec61 --- /dev/null +++ b/packages/react/src/hooks/useBlock.test.ts @@ -0,0 +1,67 @@ +import { testClient } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useBlock } from './useBlock.js' + +test('mounts', async () => { + const { result } = renderHook(() => useBlock()) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeDefined() + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "block", + { + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: watch', async () => { + await testClient.mainnet.restart() + + const { result } = renderHook(() => useBlock({ watch: true })) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + const block = result.current.data! + expect(block).toBeDefined() + + await testClient.mainnet.mine({ blocks: 1 }) + await waitFor(() => { + expect(result.current.data?.number).toEqual(block.number + 1n) + }) + + await testClient.mainnet.mine({ blocks: 1 }) + await waitFor(() => { + expect(result.current.data?.number).toEqual(block.number + 2n) + }) +}) diff --git a/packages/react/src/hooks/useBlock.ts b/packages/react/src/hooks/useBlock.ts new file mode 100644 index 0000000000..1a16a5bd9e --- /dev/null +++ b/packages/react/src/hooks/useBlock.ts @@ -0,0 +1,131 @@ +'use client' + +import { useQueryClient } from '@tanstack/react-query' +import type { Config, GetBlockErrorType, ResolvedRegister } from '@wagmi/core' +import type { + Compute, + UnionCompute, + UnionStrictOmit, +} from '@wagmi/core/internal' +import { + type GetBlockData, + type GetBlockOptions, + type GetBlockQueryFnData, + type GetBlockQueryKey, + getBlockQueryOptions, +} from '@wagmi/core/query' +import type { BlockTag } from 'viem' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' +import { + type UseWatchBlocksParameters, + useWatchBlocks, +} from './useWatchBlocks.js' + +export type UseBlockParameters< + includeTransactions extends boolean = false, + blockTag extends BlockTag = 'latest', + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetBlockData, +> = Compute< + GetBlockOptions & + ConfigParameter & + QueryParameter< + GetBlockQueryFnData, + GetBlockErrorType, + selectData, + GetBlockQueryKey + > & { + watch?: + | boolean + | UnionCompute< + UnionStrictOmit< + UseWatchBlocksParameters< + includeTransactions, + blockTag, + config, + chainId + >, + 'chainId' | 'config' | 'onBlock' | 'onError' + > + > + | undefined + } +> + +export type UseBlockReturnType< + includeTransactions extends boolean = false, + blockTag extends BlockTag = 'latest', + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetBlockData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/hooks/useBlock */ +export function useBlock< + includeTransactions extends boolean = false, + blockTag extends BlockTag = 'latest', + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetBlockData, +>( + parameters: UseBlockParameters< + includeTransactions, + blockTag, + config, + chainId, + selectData + > = {}, +): UseBlockReturnType< + includeTransactions, + blockTag, + config, + chainId, + selectData +> { + const { query = {}, watch } = parameters + + const config = useConfig(parameters) + const queryClient = useQueryClient() + const configChainId = useChainId({ config }) + const chainId = parameters.chainId ?? configChainId + + const options = getBlockQueryOptions(config, { + ...parameters, + chainId, + }) + const enabled = Boolean(query.enabled ?? true) + + useWatchBlocks({ + ...({ + config: parameters.config, + chainId: parameters.chainId!, + ...(typeof watch === 'object' ? watch : {}), + } as UseWatchBlocksParameters), + enabled: Boolean( + enabled && (typeof watch === 'object' ? watch.enabled : watch), + ), + onBlock(block) { + queryClient.setQueryData(options.queryKey, block) + }, + }) + + return useQuery({ + ...(query as any), + ...options, + enabled, + }) as UseBlockReturnType< + includeTransactions, + blockTag, + config, + chainId, + selectData + > +} diff --git a/packages/react/src/hooks/useBlockNumber.test-d.ts b/packages/react/src/hooks/useBlockNumber.test-d.ts new file mode 100644 index 0000000000..dfb4ca4dbe --- /dev/null +++ b/packages/react/src/hooks/useBlockNumber.test-d.ts @@ -0,0 +1,65 @@ +import { http, createConfig, webSocket } from '@wagmi/core' +import { mainnet, optimism } from '@wagmi/core/chains' +import { expectTypeOf, test } from 'vitest' + +import { useBlockNumber } from './useBlockNumber.js' + +test('select data', () => { + const result = useBlockNumber({ + query: { + select(data) { + expectTypeOf(data).toEqualTypeOf() + return data?.toString() + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + useBlockNumber({ + config, + watch: { + poll: false, + }, + }) + + useBlockNumber({ + config, + chainId: mainnet.id, + watch: { + poll: true, + }, + }) + useBlockNumber({ + config, + chainId: mainnet.id, + watch: { + // @ts-expect-error + poll: false, + }, + }) + + useBlockNumber({ + config, + chainId: optimism.id, + watch: { + poll: true, + }, + }) + useBlockNumber({ + config, + chainId: optimism.id, + watch: { + poll: false, + }, + }) +}) diff --git a/packages/react/src/hooks/useBlockNumber.test.ts b/packages/react/src/hooks/useBlockNumber.test.ts new file mode 100644 index 0000000000..93006a6663 --- /dev/null +++ b/packages/react/src/hooks/useBlockNumber.test.ts @@ -0,0 +1,68 @@ +import { testClient } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useBlockNumber } from './useBlockNumber.js' + +test('mounts', async () => { + await testClient.mainnet.resetFork() + + const { result } = renderHook(() => useBlockNumber()) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": 19258213n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "blockNumber", + { + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: watch', async () => { + await testClient.mainnet.restart() + + const { result } = renderHook(() => useBlockNumber({ watch: true })) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + const blockNumber = result.current.data! + expect(result.current.data).toMatchInlineSnapshot('19258213n') + + await testClient.mainnet.mine({ blocks: 1 }) + await waitFor(() => { + expect(result.current.data).toEqual(blockNumber + 1n) + }) + + await testClient.mainnet.mine({ blocks: 1 }) + await waitFor(() => { + expect(result.current.data).toEqual(blockNumber + 2n) + }) +}) diff --git a/packages/react/src/hooks/useBlockNumber.ts b/packages/react/src/hooks/useBlockNumber.ts new file mode 100644 index 0000000000..f91d8466e3 --- /dev/null +++ b/packages/react/src/hooks/useBlockNumber.ts @@ -0,0 +1,97 @@ +'use client' + +import { useQueryClient } from '@tanstack/react-query' +import type { + Config, + GetBlockNumberErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { + Compute, + UnionCompute, + UnionStrictOmit, +} from '@wagmi/core/internal' +import { + type GetBlockNumberData, + type GetBlockNumberOptions, + type GetBlockNumberQueryFnData, + type GetBlockNumberQueryKey, + getBlockNumberQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' +import { + type UseWatchBlockNumberParameters, + useWatchBlockNumber, +} from './useWatchBlockNumber.js' + +export type UseBlockNumberParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetBlockNumberData, +> = Compute< + GetBlockNumberOptions & + ConfigParameter & + QueryParameter< + GetBlockNumberQueryFnData, + GetBlockNumberErrorType, + selectData, + GetBlockNumberQueryKey + > & { + watch?: + | boolean + | UnionCompute< + UnionStrictOmit< + UseWatchBlockNumberParameters, + 'chainId' | 'config' | 'onBlockNumber' | 'onError' + > + > + | undefined + } +> + +export type UseBlockNumberReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useBlockNumber */ +export function useBlockNumber< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetBlockNumberData, +>( + parameters: UseBlockNumberParameters = {}, +): UseBlockNumberReturnType { + const { query = {}, watch } = parameters + + const config = useConfig(parameters) + const queryClient = useQueryClient() + const configChainId = useChainId({ config }) + const chainId = parameters.chainId ?? configChainId + + const options = getBlockNumberQueryOptions(config, { + ...parameters, + chainId, + }) + + useWatchBlockNumber({ + ...({ + config: parameters.config, + chainId: parameters.chainId, + ...(typeof watch === 'object' ? watch : {}), + } as UseWatchBlockNumberParameters), + enabled: Boolean( + (query.enabled ?? true) && + (typeof watch === 'object' ? watch.enabled : watch), + ), + onBlockNumber(blockNumber) { + queryClient.setQueryData(options.queryKey, blockNumber) + }, + }) + + return useQuery({ ...query, ...options }) +} diff --git a/packages/react/src/hooks/useBlockTransactionCount.test-d.ts b/packages/react/src/hooks/useBlockTransactionCount.test-d.ts new file mode 100644 index 0000000000..ff23fcfe95 --- /dev/null +++ b/packages/react/src/hooks/useBlockTransactionCount.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useBlockTransactionCount } from './useBlockTransactionCount.js' + +test('select data', () => { + const result = useBlockTransactionCount({ + query: { + select(data) { + return data + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useBlockTransactionCount.test.ts b/packages/react/src/hooks/useBlockTransactionCount.test.ts new file mode 100644 index 0000000000..dad6c95506 --- /dev/null +++ b/packages/react/src/hooks/useBlockTransactionCount.test.ts @@ -0,0 +1,231 @@ +import { chain } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useBlockTransactionCount } from './useBlockTransactionCount.js' + +test('default', async () => { + const { result } = renderHook(() => useBlockTransactionCount({})) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('number') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "blockTransactionCount", + { + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: chainId', async () => { + const { result } = renderHook(() => + useBlockTransactionCount({ chainId: chain.mainnet2.id }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('number') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "blockTransactionCount", + { + "chainId": 456, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: blockNumber', async () => { + const { result } = renderHook(() => + useBlockTransactionCount({ blockNumber: 13677382n }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('number') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "blockTransactionCount", + { + "blockNumber": 13677382n, + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: blockHash', async () => { + const { result } = renderHook(() => + useBlockTransactionCount({ + blockHash: + '0x6201f37a245850d1f11e4be3ac45bc51bd9d43ee4a127192cad550f351cfa575', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('number') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "blockTransactionCount", + { + "blockHash": "0x6201f37a245850d1f11e4be3ac45bc51bd9d43ee4a127192cad550f351cfa575", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: blockTag', async () => { + const { result } = renderHook(() => + useBlockTransactionCount({ + blockTag: 'safe', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('number') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "blockTransactionCount", + { + "blockTag": "safe", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/useBlockTransactionCount.ts b/packages/react/src/hooks/useBlockTransactionCount.ts new file mode 100644 index 0000000000..edbd6e8ddf --- /dev/null +++ b/packages/react/src/hooks/useBlockTransactionCount.ts @@ -0,0 +1,67 @@ +'use client' + +import type { + Config, + GetBlockTransactionCountErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { UnionCompute } from '@wagmi/core/internal' +import { + type GetBlockTransactionCountData, + type GetBlockTransactionCountOptions, + type GetBlockTransactionCountQueryFnData, + type GetBlockTransactionCountQueryKey, + getBlockTransactionCountQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseBlockTransactionCountParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetBlockTransactionCountData, +> = UnionCompute< + GetBlockTransactionCountOptions & + ConfigParameter & + QueryParameter< + GetBlockTransactionCountQueryFnData, + GetBlockTransactionCountErrorType, + selectData, + GetBlockTransactionCountQueryKey + > +> + +export type UseBlockTransactionCountReturnType< + selectData = GetBlockTransactionCountData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useBlockTransactionCount */ +export function useBlockTransactionCount< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetBlockTransactionCountData, +>( + parameters: UseBlockTransactionCountParameters< + config, + chainId, + selectData + > = {}, +): UseBlockTransactionCountReturnType { + const { query = {} } = parameters + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + const chainId = parameters.chainId ?? configChainId + + const options = getBlockTransactionCountQueryOptions(config, { + ...parameters, + chainId, + }) + + return useQuery({ ...query, ...options }) +} diff --git a/packages/react/src/hooks/useBytecode.test-d.ts b/packages/react/src/hooks/useBytecode.test-d.ts new file mode 100644 index 0000000000..eff094e710 --- /dev/null +++ b/packages/react/src/hooks/useBytecode.test-d.ts @@ -0,0 +1,15 @@ +import { expectTypeOf, test } from 'vitest' + +import type { Hex } from 'viem' +import { useBytecode } from './useBytecode.js' + +test('select data', () => { + const result = useBytecode({ + query: { + select(data) { + return data + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useBytecode.test.ts b/packages/react/src/hooks/useBytecode.test.ts new file mode 100644 index 0000000000..4c25fa9558 --- /dev/null +++ b/packages/react/src/hooks/useBytecode.test.ts @@ -0,0 +1,291 @@ +import { address, chain, wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import type { Address } from 'viem' +import { useBytecode } from './useBytecode.js' + +test('default', async () => { + const { result } = renderHook(() => + useBytecode({ + address: address.wagmiMintExample, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) + expect(data).toMatch(/^0x.*/) +}) + +test('parameters: blockNumber', async () => { + const { result } = renderHook(() => + useBytecode({ + address: address.wagmiMintExample, + blockNumber: 15564163n, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": null, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "blockNumber": 15564163n, + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: blockTag', async () => { + const { result } = renderHook(() => + useBytecode({ + address: address.wagmiMintExample, + blockTag: 'earliest', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": null, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "blockTag": "earliest", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: chainId', async () => { + const { result } = renderHook(() => + useBytecode({ + address: address.wagmiMintExample, + chainId: chain.optimism.id, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": null, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 10, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: address: undefined -> defined', async () => { + let contractAddress: Address | undefined = undefined + + const { result, rerender } = renderHook(() => + useBytecode({ + address: contractAddress, + }), + ) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "getBytecode", + { + "address": undefined, + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + + contractAddress = address.wagmiMintExample + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) + expect(data).toMatch(/^0x.*/) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useBytecode()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useBytecode.ts b/packages/react/src/hooks/useBytecode.ts new file mode 100644 index 0000000000..3dd01d438a --- /dev/null +++ b/packages/react/src/hooks/useBytecode.ts @@ -0,0 +1,57 @@ +'use client' + +import type { + Config, + GetBytecodeErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetBytecodeData, + type GetBytecodeOptions, + type GetBytecodeQueryKey, + getBytecodeQueryOptions, +} from '@wagmi/core/query' +import type { GetBytecodeQueryFnData } from '@wagmi/core/query' +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseBytecodeParameters< + config extends Config = Config, + selectData = GetBytecodeData, +> = Compute< + GetBytecodeOptions & + ConfigParameter & + QueryParameter< + GetBytecodeQueryFnData, + GetBytecodeErrorType, + selectData, + GetBytecodeQueryKey + > +> + +export type UseBytecodeReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useBytecode */ +export function useBytecode< + config extends Config = ResolvedRegister['config'], + selectData = GetBytecodeData, +>( + parameters: UseBytecodeParameters = {}, +): UseBytecodeReturnType { + const { address, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getBytecodeQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(address && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useCall.test-d.ts b/packages/react/src/hooks/useCall.test-d.ts new file mode 100644 index 0000000000..5c47b096c7 --- /dev/null +++ b/packages/react/src/hooks/useCall.test-d.ts @@ -0,0 +1,14 @@ +import type { CallReturnType } from 'viem' +import { expectTypeOf, test } from 'vitest' +import { useCall } from './useCall.js' + +test('select data', () => { + const result = useCall({ + query: { + select(data) { + return data + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useCall.test.ts b/packages/react/src/hooks/useCall.test.ts new file mode 100644 index 0000000000..ee8ce813c4 --- /dev/null +++ b/packages/react/src/hooks/useCall.test.ts @@ -0,0 +1,224 @@ +import { accounts, address, chain } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useCall } from './useCall.js' + +const name4bytes = '0x06fdde03' + +const account = accounts[0] + +test('default', async () => { + const { result } = renderHook(() => + useCall({ + account, + data: name4bytes, + to: address.wagmiMintExample, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "data": "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000057761676d69000000000000000000000000000000000000000000000000000000", + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + "data": "0x06fdde03", + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +// TODO: Re-enable +test.skip('parameters: blockTag', async () => { + const { result } = renderHook(() => + useCall({ + account, + data: name4bytes, + to: address.wagmiMintExample, + blockTag: 'safe', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "data": "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000057761676d69000000000000000000000000000000000000000000000000000000", + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockTag": "safe", + "chainId": 1, + "data": "0x06fdde03", + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +// TODO: Re-enable +test.skip('parameters: blockNumber', async () => { + const { result } = renderHook(() => + useCall({ + account, + data: name4bytes, + to: address.wagmiMintExample, + blockNumber: 16280770n, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "data": "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000057761676d69000000000000000000000000000000000000000000000000000000", + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockNumber": 16280770n, + "chainId": 1, + "data": "0x06fdde03", + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: chainId', async () => { + const { result } = renderHook(() => + useCall({ + account, + data: name4bytes, + to: address.wagmiMintExample, + chainId: chain.mainnet2.id, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "data": "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000057761676d69000000000000000000000000000000000000000000000000000000", + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "call", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 456, + "data": "0x06fdde03", + "to": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/useCall.ts b/packages/react/src/hooks/useCall.ts new file mode 100644 index 0000000000..423e04fbff --- /dev/null +++ b/packages/react/src/hooks/useCall.ts @@ -0,0 +1,55 @@ +'use client' + +import type { CallErrorType, Config, ResolvedRegister } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type CallData, + type CallOptions, + type CallQueryKey, + callQueryOptions, +} from '@wagmi/core/query' +import type { CallQueryFnData } from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseCallParameters< + config extends Config = Config, + selectData = CallData, +> = Compute< + CallOptions & + ConfigParameter & + QueryParameter< + CallQueryFnData, + CallErrorType, + selectData, + CallQueryKey + > +> + +export type UseCallReturnType = UseQueryReturnType< + selectData, + CallErrorType +> + +/** https://wagmi.sh/react/api/hooks/useCall */ +export function useCall< + config extends Config = ResolvedRegister['config'], + selectData = CallData, +>( + parameters: UseCallParameters = {}, +): UseCallReturnType { + const { query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = callQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + + return useQuery({ ...query, ...options }) +} diff --git a/packages/react/src/hooks/useCallsStatus.test.ts b/packages/react/src/hooks/useCallsStatus.test.ts new file mode 100644 index 0000000000..f3af1c24bc --- /dev/null +++ b/packages/react/src/hooks/useCallsStatus.test.ts @@ -0,0 +1,101 @@ +import { connect, disconnect } from '@wagmi/core' +import { accounts, config, testClient } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { useCallsStatus } from './useCallsStatus.js' +import { useSendCalls } from './useSendCalls.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useSendCalls()) + + result.current.sendCalls({ + calls: [ + { + data: '0xdeadbeef', + to: accounts[1], + value: parseEther('1'), + }, + { + to: accounts[2], + value: parseEther('2'), + }, + { + to: accounts[3], + value: parseEther('3'), + }, + ], + }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { result: result_2 } = renderHook(() => + useCallsStatus({ id: result.current.data?.id! }), + ) + await waitFor(() => expect(result_2.current.isSuccess).toBeTruthy()) + + expect(result_2.current.data).toMatchInlineSnapshot( + ` + { + "atomic": false, + "chainId": 1, + "id": "0x5dedb5a4ff8968db37459b52b83cbdc92b01c9c709c9cff26e345ef5cf27f92e", + "receipts": [], + "status": "pending", + "statusCode": 100, + "version": "2.0.0", + } + `, + ) + + await testClient.mainnet.mine({ blocks: 1 }) + + const { result: result_3 } = renderHook(() => + useCallsStatus({ id: result.current.data?.id! }), + ) + await waitFor(() => expect(result_3.current.isSuccess).toBeTruthy()) + + expect(result_3.current.data?.status).toBe('success') + expect(result_3.current.data?.statusCode).toBe(200) + expect( + result_3.current.data?.receipts?.map((x) => ({ + ...x, + blockHash: undefined, + })), + ).toMatchInlineSnapshot( + ` + [ + { + "blockHash": undefined, + "blockNumber": 19258214n, + "gasUsed": 21064n, + "logs": [], + "status": "success", + "transactionHash": "0x13c53b2d4d9da424835525349cd66e553330f323d6fb19458b801ae1f7989a41", + }, + { + "blockHash": undefined, + "blockNumber": 19258214n, + "gasUsed": 21000n, + "logs": [], + "status": "success", + "transactionHash": "0xd8397b3e82b061c26a0c2093f1ceca0c3662a512614f7d6370349e89d0eea007", + }, + { + "blockHash": undefined, + "blockNumber": 19258214n, + "gasUsed": 21000n, + "logs": [], + "status": "success", + "transactionHash": "0x4d26e346593d9ea265bb164b115e89aa92df43b0b8778ac75d4ad28e2a22b101", + }, + ] + `, + ) + + await disconnect(config, { connector }) +}) diff --git a/packages/react/src/hooks/useCallsStatus.ts b/packages/react/src/hooks/useCallsStatus.ts new file mode 100644 index 0000000000..ab4c90c1f2 --- /dev/null +++ b/packages/react/src/hooks/useCallsStatus.ts @@ -0,0 +1,52 @@ +'use client' + +import type { + Config, + GetCallsStatusErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetCallsStatusData, + type GetCallsStatusOptions, + type GetCallsStatusQueryFnData, + type GetCallsStatusQueryKey, + getCallsStatusQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseCallsStatusParameters< + config extends Config = Config, + selectData = GetCallsStatusData, +> = Compute< + GetCallsStatusOptions & + ConfigParameter & + QueryParameter< + GetCallsStatusQueryFnData, + GetCallsStatusErrorType, + selectData, + GetCallsStatusQueryKey + > +> + +export type UseCallsStatusReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useCallsStatus */ +export function useCallsStatus< + config extends Config = ResolvedRegister['config'], + selectData = GetCallsStatusData, +>( + parameters: UseCallsStatusParameters, +): UseCallsStatusReturnType { + const { query = {} } = parameters + + const config = useConfig(parameters) + + const options = getCallsStatusQueryOptions(config, parameters) + + return useQuery({ ...query, ...options }) +} diff --git a/packages/react/src/hooks/useCapabilities.test.ts b/packages/react/src/hooks/useCapabilities.test.ts new file mode 100644 index 0000000000..65dcf171b5 --- /dev/null +++ b/packages/react/src/hooks/useCapabilities.test.ts @@ -0,0 +1,167 @@ +import { connect, disconnect } from '@wagmi/core' +import { accounts, config } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useCapabilities } from './useCapabilities.js' + +const connector = config.connectors[0]! + +test('mounts', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useCapabilities()) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "8453": { + "paymasterService": { + "supported": true, + }, + "sessionKeys": { + "supported": true, + }, + }, + "84532": { + "paymasterService": { + "supported": true, + }, + }, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "capabilities", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + }, + ], + "refetch": [Function], + "status": "success", + } + `) + + await disconnect(config, { connector }) +}) + +test('args: account', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useCapabilities({ account: accounts[1] })) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "8453": { + "paymasterService": { + "supported": false, + }, + "sessionKeys": { + "supported": true, + }, + }, + "84532": { + "paymasterService": { + "supported": false, + }, + }, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "capabilities", + { + "account": "0x70997970c51812dc3a010c7d01b50e0d17dc79c8", + }, + ], + "refetch": [Function], + "status": "success", + } + `) + + await disconnect(config, { connector }) +}) + +test('behavior: not connected', async () => { + const { result } = renderHook(() => useCapabilities()) + + await waitFor(() => expect(result.current.isError).toBeTruthy()) + + const { error, failureReason: _, ...rest } = result.current + expect(error?.message.includes('Connector not connected.')).toBeTruthy() + expect(rest).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "errorUpdateCount": 2, + "errorUpdatedAt": 1675209600000, + "failureCount": 1, + "fetchStatus": "idle", + "isError": true, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": true, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": false, + "queryKey": [ + "capabilities", + { + "account": undefined, + }, + ], + "refetch": [Function], + "status": "error", + } + `) +}) diff --git a/packages/react/src/hooks/useCapabilities.ts b/packages/react/src/hooks/useCapabilities.ts new file mode 100644 index 0000000000..399a56cd38 --- /dev/null +++ b/packages/react/src/hooks/useCapabilities.ts @@ -0,0 +1,62 @@ +'use client' + +import type { + Config, + GetCapabilitiesErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetCapabilitiesData, + type GetCapabilitiesOptions, + type GetCapabilitiesQueryFnData, + type GetCapabilitiesQueryKey, + getCapabilitiesQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useAccount } from './useAccount.js' +import { useConfig } from './useConfig.js' + +export type UseCapabilitiesParameters< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = GetCapabilitiesData, +> = Compute< + GetCapabilitiesOptions & + ConfigParameter & + QueryParameter< + GetCapabilitiesQueryFnData, + GetCapabilitiesErrorType, + selectData, + GetCapabilitiesQueryKey + > +> + +export type UseCapabilitiesReturnType< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = GetCapabilitiesData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useCapabilities */ +export function useCapabilities< + config extends Config = ResolvedRegister['config'], + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = GetCapabilitiesData, +>( + parameters: UseCapabilitiesParameters = {}, +): UseCapabilitiesReturnType { + const { account, query = {} } = parameters + + const { address } = useAccount() + const config = useConfig(parameters) + + const options = getCapabilitiesQueryOptions(config, { + ...parameters, + account: account ?? address, + }) + + return useQuery({ ...query, ...options }) +} diff --git a/packages/react/src/hooks/useChainId.test-d.ts b/packages/react/src/hooks/useChainId.test-d.ts new file mode 100644 index 0000000000..682b5fab7a --- /dev/null +++ b/packages/react/src/hooks/useChainId.test-d.ts @@ -0,0 +1,14 @@ +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useChainId } from './useChainId.js' + +test('default', () => { + const chainId = useChainId() + expectTypeOf(chainId).toEqualTypeOf() +}) + +test('parameters: config', () => { + const chainId = useChainId({ config }) + expectTypeOf(chainId).toEqualTypeOf<1 | 456 | 10>() +}) diff --git a/packages/react/src/hooks/useChainId.test.ts b/packages/react/src/hooks/useChainId.test.ts new file mode 100644 index 0000000000..e4745b46e3 --- /dev/null +++ b/packages/react/src/hooks/useChainId.test.ts @@ -0,0 +1,24 @@ +import { config } from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import { Fragment, createElement } from 'react' +import { expect, test } from 'vitest' + +import { useChainId } from './useChainId.js' + +test('default', async () => { + const { result, rerender } = renderHook(() => useChainId()) + + expect(result.current).toMatchInlineSnapshot('1') + + config.setState((x) => ({ ...x, chainId: 456 })) + rerender() + + expect(result.current).toMatchInlineSnapshot('456') +}) + +test('parameters: config', () => { + const { result } = renderHook(() => useChainId({ config }), { + wrapper: ({ children }) => createElement(Fragment, { children }), + }) + expect(result.current).toBeDefined() +}) diff --git a/packages/react/src/hooks/useChainId.ts b/packages/react/src/hooks/useChainId.ts new file mode 100644 index 0000000000..ce7cb208dd --- /dev/null +++ b/packages/react/src/hooks/useChainId.ts @@ -0,0 +1,32 @@ +'use client' + +import { + type Config, + type GetChainIdReturnType, + type ResolvedRegister, + getChainId, + watchChainId, +} from '@wagmi/core' +import { useSyncExternalStore } from 'react' + +import type { ConfigParameter } from '../types/properties.js' +import { useConfig } from './useConfig.js' + +export type UseChainIdParameters = + ConfigParameter + +export type UseChainIdReturnType = + GetChainIdReturnType + +/** https://wagmi.sh/react/api/hooks/useChainId */ +export function useChainId( + parameters: UseChainIdParameters = {}, +): UseChainIdReturnType { + const config = useConfig(parameters) + + return useSyncExternalStore( + (onChange) => watchChainId(config, { onChange }), + () => getChainId(config), + () => getChainId(config), + ) +} diff --git a/packages/react/src/hooks/useChains.test.ts b/packages/react/src/hooks/useChains.test.ts new file mode 100644 index 0000000000..1d9d6fca4f --- /dev/null +++ b/packages/react/src/hooks/useChains.test.ts @@ -0,0 +1,31 @@ +import { config } from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import { Fragment, createElement } from 'react' +import { expect, test } from 'vitest' + +import { useChains } from './useChains.js' + +test('default', async () => { + const { result } = renderHook(() => useChains()) + + expect(result.current.map((x) => x.id)).toMatchInlineSnapshot(` + [ + 1, + 456, + 10, + ] + `) +}) + +test('parameters: config', () => { + const { result } = renderHook(() => useChains({ config }), { + wrapper: ({ children }) => createElement(Fragment, { children }), + }) + expect(result.current.map((x) => x.id)).toMatchInlineSnapshot(` + [ + 1, + 456, + 10, + ] + `) +}) diff --git a/packages/react/src/hooks/useChains.ts b/packages/react/src/hooks/useChains.ts new file mode 100644 index 0000000000..b3e93b417a --- /dev/null +++ b/packages/react/src/hooks/useChains.ts @@ -0,0 +1,32 @@ +'use client' + +import { + type Config, + type GetChainsReturnType, + type ResolvedRegister, + getChains, +} from '@wagmi/core' +import { watchChains } from '@wagmi/core/internal' +import { useSyncExternalStore } from 'react' + +import type { ConfigParameter } from '../types/properties.js' +import { useConfig } from './useConfig.js' + +export type UseChainsParameters = + ConfigParameter + +export type UseChainsReturnType = + GetChainsReturnType + +/** https://wagmi.sh/react/api/hooks/useChains */ +export function useChains( + parameters: UseChainsParameters = {}, +): UseChainsReturnType { + const config = useConfig(parameters) + + return useSyncExternalStore( + (onChange) => watchChains(config, { onChange }), + () => getChains(config), + () => getChains(config), + ) +} diff --git a/packages/react/src/hooks/useClient.test-d.ts b/packages/react/src/hooks/useClient.test-d.ts new file mode 100644 index 0000000000..80ee4ec48d --- /dev/null +++ b/packages/react/src/hooks/useClient.test-d.ts @@ -0,0 +1,40 @@ +import { chain, config } from '@wagmi/test' +import type { Chain } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { useClient } from './useClient.js' + +test('default', () => { + const client = useClient({ config }) + expectTypeOf(client.chain).toEqualTypeOf<(typeof config)['chains'][number]>() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('parameters: chainId', () => { + const client = useClient({ + config, + chainId: chain.mainnet.id, + }) + expectTypeOf(client.chain).toEqualTypeOf() + expectTypeOf(client.chain).not.toEqualTypeOf() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('behavior: unconfigured chain', () => { + { + const client = useClient({ chainId: 123456 }) + if (client) { + expectTypeOf(client.chain).toEqualTypeOf() + expectTypeOf(client.transport.type).toEqualTypeOf() + } else { + expectTypeOf(client).toEqualTypeOf() + } + } + + const client = useClient({ + config, + // @ts-expect-error + chainId: 123456, + }) + expectTypeOf(client).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useClient.test.ts b/packages/react/src/hooks/useClient.test.ts new file mode 100644 index 0000000000..93ef8d9fa9 --- /dev/null +++ b/packages/react/src/hooks/useClient.test.ts @@ -0,0 +1,30 @@ +import { switchChain } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import { Fragment, createElement } from 'react' +import { expect, test } from 'vitest' + +import { useClient } from './useClient.js' + +test('default', async () => { + const { result, rerender } = renderHook(() => useClient()) + + expect(result.current?.chain.id).toEqual(1) + + await switchChain(config, { chainId: 456 }) + rerender() + + expect(result.current?.chain.id).toEqual(456) +}) + +test('parameters: config', () => { + const { result } = renderHook(() => useClient({ config }), { + wrapper: ({ children }) => createElement(Fragment, { children }), + }) + expect(result.current).toBeDefined() +}) + +test('behavior: unconfigured chain', () => { + const { result } = renderHook(() => useClient({ chainId: 123456 })) + expect(result.current).toBeUndefined() +}) diff --git a/packages/react/src/hooks/useClient.ts b/packages/react/src/hooks/useClient.ts new file mode 100644 index 0000000000..abfee745b3 --- /dev/null +++ b/packages/react/src/hooks/useClient.ts @@ -0,0 +1,49 @@ +'use client' + +import { + type Config, + type GetClientParameters, + type GetClientReturnType, + type ResolvedRegister, + getClient, + watchClient, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { useSyncExternalStoreWithSelector } from 'use-sync-external-store/shim/with-selector.js' + +import type { ConfigParameter } from '../types/properties.js' +import { useConfig } from './useConfig.js' + +export type UseClientParameters< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | number | undefined = + | config['chains'][number]['id'] + | undefined, +> = Compute & ConfigParameter> + +export type UseClientReturnType< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | number | undefined = + | config['chains'][number]['id'] + | undefined, +> = GetClientReturnType + +/** https://wagmi.sh/react/api/hooks/useClient */ +export function useClient< + config extends Config = ResolvedRegister['config'], + chainId extends config['chains'][number]['id'] | number | undefined = + | config['chains'][number]['id'] + | undefined, +>( + parameters: UseClientParameters = {}, +): UseClientReturnType { + const config = useConfig(parameters) + + return useSyncExternalStoreWithSelector( + (onChange) => watchClient(config, { onChange }), + () => getClient(config, parameters), + () => getClient(config, parameters), + (x) => x, + (a, b) => a?.uid === b?.uid, + ) as any +} diff --git a/packages/react/src/hooks/useConfig.test-d.ts b/packages/react/src/hooks/useConfig.test-d.ts new file mode 100644 index 0000000000..f2b9d2bb31 --- /dev/null +++ b/packages/react/src/hooks/useConfig.test-d.ts @@ -0,0 +1,16 @@ +import type { Config } from '@wagmi/core' +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useConfig } from './useConfig.js' + +test('default', async () => { + const result = useConfig() + expectTypeOf(result).toEqualTypeOf() +}) + +test('parameters: config', async () => { + const result = useConfig({ config }) + expectTypeOf(result).not.toEqualTypeOf() + expectTypeOf(result).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useConfig.test.ts b/packages/react/src/hooks/useConfig.test.ts new file mode 100644 index 0000000000..e0fc9c40ce --- /dev/null +++ b/packages/react/src/hooks/useConfig.test.ts @@ -0,0 +1,23 @@ +import { createWrapper, renderHook } from '@wagmi/test/react' +import { expect, test, vi } from 'vitest' + +import { useConfig } from './useConfig.js' + +test('mounts', () => { + const { result } = renderHook(() => useConfig()) + expect(result.current).toBeDefined() +}) + +test('behavior: throws when not inside Provider', () => { + vi.spyOn(console, 'error').mockImplementation(() => {}) + + try { + renderHook(() => useConfig(), { + wrapper: createWrapper(() => null, undefined), + }) + } catch (error) { + expect(error).toMatchInlineSnapshot( + '[Error: `useConfig` must be used within `WagmiProvider`.]', + ) + } +}) diff --git a/packages/react/src/hooks/useConfig.ts b/packages/react/src/hooks/useConfig.ts new file mode 100644 index 0000000000..af9ea5b9c0 --- /dev/null +++ b/packages/react/src/hooks/useConfig.ts @@ -0,0 +1,22 @@ +'use client' + +import type { Config, ResolvedRegister } from '@wagmi/core' +import { useContext } from 'react' + +import { WagmiContext } from '../context.js' +import { WagmiProviderNotFoundError } from '../errors/context.js' +import type { ConfigParameter } from '../types/properties.js' + +export type UseConfigParameters = + ConfigParameter + +export type UseConfigReturnType = config + +/** https://wagmi.sh/react/api/hooks/useConfig */ +export function useConfig( + parameters: UseConfigParameters = {}, +): UseConfigReturnType { + const config = parameters.config ?? useContext(WagmiContext) + if (!config) throw new WagmiProviderNotFoundError() + return config as UseConfigReturnType +} diff --git a/packages/react/src/hooks/useConnect.test-d.ts b/packages/react/src/hooks/useConnect.test-d.ts new file mode 100644 index 0000000000..e678d2edd8 --- /dev/null +++ b/packages/react/src/hooks/useConnect.test-d.ts @@ -0,0 +1,124 @@ +import type { + ConnectErrorType, + Connector, + CreateConnectorFn, +} from '@wagmi/core' +import { config } from '@wagmi/test' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { useConnect } from './useConnect.js' + +const connector = config.connectors[0]! +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { connect, context, data, error, variables } = useConnect({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: Connector | CreateConnectorFn + }>() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: Connector | CreateConnectorFn + }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: Connector | CreateConnectorFn + }>() + expectTypeOf(data).toEqualTypeOf<{ + accounts: readonly [Address, ...Address[]] + chainId: number + }>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: Connector | CreateConnectorFn + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf< + | { + chainId?: number | undefined + connector: CreateConnectorFn | Connector + } + | undefined + >() + expectTypeOf(context).toEqualTypeOf() + + connect( + { + connector, + foo: 'bar', + }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: typeof connector | CreateConnectorFn + foo?: string | undefined + }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: typeof connector | CreateConnectorFn + foo?: string | undefined + }>() + expectTypeOf(data).toEqualTypeOf<{ + accounts: readonly [Address, ...Address[]] + chainId: number + }>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: typeof connector | CreateConnectorFn + foo?: string | undefined + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/react/src/hooks/useConnect.test.ts b/packages/react/src/hooks/useConnect.test.ts new file mode 100644 index 0000000000..d80ff30509 --- /dev/null +++ b/packages/react/src/hooks/useConnect.test.ts @@ -0,0 +1,35 @@ +import { disconnect } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { afterEach, expect, test } from 'vitest' + +import { useAccount } from './useAccount.js' +import { useConnect } from './useConnect.js' + +const connector = config.connectors[0]! + +afterEach(async () => { + if (config.state.current === connector.uid) + await disconnect(config, { connector }) +}) + +test('default', async () => { + const { result } = renderHook(() => ({ + useAccount: useAccount(), + useConnect: useConnect(), + })) + + expect(result.current.useAccount.address).not.toBeDefined() + expect(result.current.useAccount.status).toEqual('disconnected') + + result.current.useConnect.connect({ + connector: result.current.useConnect.connectors[0]!, + }) + + await waitFor(() => + expect(result.current.useAccount.isConnected).toBeTruthy(), + ) + + expect(result.current.useAccount.address).toBeDefined() + expect(result.current.useAccount.status).toEqual('connected') +}) diff --git a/packages/react/src/hooks/useConnect.ts b/packages/react/src/hooks/useConnect.ts new file mode 100644 index 0000000000..acfe69234d --- /dev/null +++ b/packages/react/src/hooks/useConnect.ts @@ -0,0 +1,90 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { Config, ConnectErrorType, ResolvedRegister } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type ConnectData, + type ConnectMutate, + type ConnectMutateAsync, + type ConnectVariables, + connectMutationOptions, +} from '@wagmi/core/query' +import { useEffect } from 'react' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' +import { type UseConnectorsReturnType, useConnectors } from './useConnectors.js' + +export type UseConnectParameters< + config extends Config = Config, + context = unknown, +> = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + ConnectData, + ConnectErrorType, + ConnectVariables, + context + > + | undefined + } +> + +export type UseConnectReturnType< + config extends Config = Config, + context = unknown, +> = Compute< + UseMutationReturnType< + ConnectData, + ConnectErrorType, + ConnectVariables, + context + > & { + connect: ConnectMutate + connectAsync: ConnectMutateAsync + connectors: Compute | config['connectors'] + } +> + +/** https://wagmi.sh/react/api/hooks/useConnect */ +export function useConnect< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseConnectParameters = {}, +): UseConnectReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = connectMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + // Reset mutation back to an idle state when the connector disconnects. + useEffect(() => { + return config.subscribe( + ({ status }) => status, + (status, previousStatus) => { + if (previousStatus === 'connected' && status === 'disconnected') + result.reset() + }, + ) + }, [config, result.reset]) + + type Return = UseConnectReturnType + return { + ...(result as Return), + connect: mutate as Return['connect'], + connectAsync: mutateAsync as Return['connectAsync'], + connectors: useConnectors({ config }), + } +} diff --git a/packages/react/src/hooks/useConnections.test.ts b/packages/react/src/hooks/useConnections.test.ts new file mode 100644 index 0000000000..1eb4febcdb --- /dev/null +++ b/packages/react/src/hooks/useConnections.test.ts @@ -0,0 +1,25 @@ +import { connect } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import { Fragment, createElement } from 'react' +import { expect, test } from 'vitest' + +import { useConnections } from './useConnections.js' + +test('default', async () => { + const { result, rerender } = renderHook(() => useConnections()) + + expect(result.current).toEqual([]) + + await connect(config, { connector: config.connectors[0]! }) + rerender() + + expect(result.current.length).toBe(1) +}) + +test('parameters: config', () => { + const { result } = renderHook(() => useConnections({ config }), { + wrapper: ({ children }) => createElement(Fragment, { children }), + }) + expect(result.current).toBeDefined() +}) diff --git a/packages/react/src/hooks/useConnections.ts b/packages/react/src/hooks/useConnections.ts new file mode 100644 index 0000000000..db53db7227 --- /dev/null +++ b/packages/react/src/hooks/useConnections.ts @@ -0,0 +1,28 @@ +'use client' + +import { + type GetConnectionsReturnType, + getConnections, + watchConnections, +} from '@wagmi/core' +import { useSyncExternalStore } from 'react' + +import type { ConfigParameter } from '../types/properties.js' +import { useConfig } from './useConfig.js' + +export type UseConnectionsParameters = ConfigParameter + +export type UseConnectionsReturnType = GetConnectionsReturnType + +/** https://wagmi.sh/react/api/hooks/useConnections */ +export function useConnections( + parameters: UseConnectionsParameters = {}, +): UseConnectionsReturnType { + const config = useConfig(parameters) + + return useSyncExternalStore( + (onChange) => watchConnections(config, { onChange }), + () => getConnections(config), + () => getConnections(config), + ) +} diff --git a/packages/react/src/hooks/useConnectorClient.test-d.ts b/packages/react/src/hooks/useConnectorClient.test-d.ts new file mode 100644 index 0000000000..b919e6a904 --- /dev/null +++ b/packages/react/src/hooks/useConnectorClient.test-d.ts @@ -0,0 +1,12 @@ +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useConnectorClient } from './useConnectorClient.js' + +test('parameters: config', async () => { + const client = useConnectorClient({ config }) + expectTypeOf(client.data?.chain?.id!).toEqualTypeOf<1 | 456 | 10>() + + const client2 = useConnectorClient({ config, chainId: 1 }) + expectTypeOf(client2.data?.chain?.id!).toEqualTypeOf<1>() +}) diff --git a/packages/react/src/hooks/useConnectorClient.test.tsx b/packages/react/src/hooks/useConnectorClient.test.tsx new file mode 100644 index 0000000000..f8737c53ec --- /dev/null +++ b/packages/react/src/hooks/useConnectorClient.test.tsx @@ -0,0 +1,239 @@ +import { connect, disconnect } from '@wagmi/core' +import { config, wait } from '@wagmi/test' +import { render, renderHook, waitFor } from '@wagmi/test/react' +import * as React from 'react' +import { expect, test } from 'vitest' + +import { useAccount } from './useAccount.js' +import { useConnect } from './useConnect.js' +import { useConnectorClient } from './useConnectorClient.js' +import { useDisconnect } from './useDisconnect.js' +import { useSwitchChain } from './useSwitchChain.js' + +const connector = config.connectors[0]! + +test('default', async () => { + const { result } = renderHook(() => useConnectorClient()) + + await waitFor(() => expect(result.current.isPending).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "connectorClient", + { + "chainId": 1, + "connectorUid": undefined, + }, + ], + "refetch": [Function], + "status": "pending", + } + `) +}) + +test('behavior: connected on mount', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useConnectorClient()) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, queryKey: _, ...rest } = result.current + expect(data).toMatchObject( + expect.objectContaining({ + account: expect.any(Object), + chain: expect.any(Object), + }), + ) + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": true, + "refetch": [Function], + "status": "success", + } + `) + + await disconnect(config, { connector }) +}) + +test('behavior: connect and disconnect', async () => { + const { result } = renderHook(() => ({ + useConnect: useConnect(), + useConnectorClient: useConnectorClient(), + useDisconnect: useDisconnect(), + })) + + expect(result.current.useConnectorClient.data).not.toBeDefined() + + result.current.useConnect.connect({ + connector: result.current.useConnect.connectors[0]!, + }) + + await waitFor(() => + expect(result.current.useConnectorClient.data).toBeDefined(), + ) + + result.current.useDisconnect.disconnect() + + await waitFor(() => + expect(result.current.useConnectorClient.data).not.toBeDefined(), + ) +}) + +test('behavior: switch chains', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => ({ + useConnectorClient: useConnectorClient(), + useSwitchChain: useSwitchChain(), + })) + + expect(result.current.useConnectorClient.data).not.toBeDefined() + + await waitFor(() => + expect(result.current.useConnectorClient.data).toBeDefined(), + ) + + result.current.useSwitchChain.switchChain({ chainId: 456 }) + await waitFor(() => { + expect(result.current.useSwitchChain.isSuccess).toBeTruthy() + result.current.useSwitchChain.reset() + }) + expect(result.current.useConnectorClient.data?.chain.id).toEqual(456) + + result.current.useSwitchChain.switchChain({ chainId: 1 }) + await waitFor(() => + expect(result.current.useSwitchChain.isSuccess).toBeTruthy(), + ) + expect(result.current.useConnectorClient.data?.chain.id).toEqual(1) + + await disconnect(config, { connector }) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useConnectorClient()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) + +test('behavior: disabled when connecting', async () => { + const { result } = renderHook(() => useConnectorClient()) + + config.setState((x) => ({ ...x, status: 'connecting' })) + + await wait(100) + expect(result.current.isLoading).not.toBeTruthy() +}) + +test('behavior: re-render does not invalidate query', async () => { + const { getByTestId } = render() + + getByTestId('connect').click() + await waitFor(() => { + expect(getByTestId('address').innerText).toContain( + '0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266', + ) + expect(getByTestId('client').innerText).toBeTruthy() + + expect(getByTestId('child-client').innerText).toBeTruthy() + expect(getByTestId('render-count').innerText).toEqual('1') + }) + + const initialClient = getByTestId('child-client').innerText + + getByTestId('rerender').click() + await waitFor(() => { + expect(getByTestId('render-count').innerText).toEqual('2') + }) + await wait(200) + + expect(getByTestId('child-client').innerText).toEqual(initialClient) +}) + +function Parent() { + const [renderCount, setRenderCount] = React.useState(1) + + const { connectors, connect } = useConnect() + const { address } = useAccount() + const { data } = useConnectorClient() + + return ( + <> +
{address}
+
{data?.uid}
+ + + + + + ) +} + +function Child(props: { + renderCount: number +}) { + const { renderCount } = props + const { data } = useConnectorClient() + return ( +
+ {data?.uid} + {renderCount} +
+ ) +} diff --git a/packages/react/src/hooks/useConnectorClient.ts b/packages/react/src/hooks/useConnectorClient.ts new file mode 100644 index 0000000000..16bbf33ae0 --- /dev/null +++ b/packages/react/src/hooks/useConnectorClient.ts @@ -0,0 +1,113 @@ +'use client' + +import { useQueryClient } from '@tanstack/react-query' +import type { + Config, + GetConnectorClientErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute, Omit } from '@wagmi/core/internal' +import { + type GetConnectorClientData, + type GetConnectorClientOptions, + type GetConnectorClientQueryFnData, + type GetConnectorClientQueryKey, + getConnectorClientQueryOptions, +} from '@wagmi/core/query' +import { useEffect, useRef } from 'react' + +import type { ConfigParameter } from '../types/properties.js' +import { + type UseQueryParameters, + type UseQueryReturnType, + useQuery, +} from '../utils/query.js' +import { useAccount } from './useAccount.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseConnectorClientParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetConnectorClientData, +> = Compute< + GetConnectorClientOptions & + ConfigParameter & { + query?: + | Compute< + Omit< + UseQueryParameters< + GetConnectorClientQueryFnData, + GetConnectorClientErrorType, + selectData, + GetConnectorClientQueryKey + >, + 'gcTime' | 'staleTime' + > + > + | undefined + } +> + +export type UseConnectorClientReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetConnectorClientData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useConnectorClient */ +export function useConnectorClient< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetConnectorClientData, +>( + parameters: UseConnectorClientParameters = {}, +): UseConnectorClientReturnType { + const { query = {}, ...rest } = parameters + + const config = useConfig(rest) + const queryClient = useQueryClient() + const { address, connector, status } = useAccount({ config }) + const chainId = useChainId({ config }) + const activeConnector = parameters.connector ?? connector + + const { queryKey, ...options } = getConnectorClientQueryOptions< + config, + chainId + >(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + connector: activeConnector, + }) + const enabled = Boolean( + (status === 'connected' || + (status === 'reconnecting' && activeConnector?.getProvider)) && + (query.enabled ?? true), + ) + + const addressRef = useRef(address) + // biome-ignore lint/correctness/useExhaustiveDependencies: `queryKey` not required + useEffect(() => { + const previousAddress = addressRef.current + if (!address && previousAddress) { + // remove when account is disconnected + queryClient.removeQueries({ queryKey }) + addressRef.current = undefined + } else if (address !== previousAddress) { + // invalidate when address changes + queryClient.invalidateQueries({ queryKey }) + addressRef.current = address + } + }, [address, queryClient]) + + return useQuery({ + ...query, + ...options, + queryKey, + enabled, + staleTime: Number.POSITIVE_INFINITY, + }) +} diff --git a/packages/react/src/hooks/useConnectors.test.ts b/packages/react/src/hooks/useConnectors.test.ts new file mode 100644 index 0000000000..f287cceb32 --- /dev/null +++ b/packages/react/src/hooks/useConnectors.test.ts @@ -0,0 +1,30 @@ +import { mock } from '@wagmi/connectors' +import { accounts, config } from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import { Fragment, createElement } from 'react' +import { expect, test } from 'vitest' + +import { useConnectors } from './useConnectors.js' + +test('default', async () => { + const { result, rerender } = renderHook(() => useConnectors()) + + const count = config.connectors.length + expect(result.current.length).toBe(count) + expect(result.current).toEqual(config.connectors) + + config._internal.connectors.setState(() => [ + ...config.connectors, + config._internal.connectors.setup(mock({ accounts })), + ]) + rerender() + + expect(result.current.length).toBe(count + 1) +}) + +test('parameters: config', () => { + const { result } = renderHook(() => useConnectors({ config }), { + wrapper: ({ children }) => createElement(Fragment, { children }), + }) + expect(result.current).toBeDefined() +}) diff --git a/packages/react/src/hooks/useConnectors.ts b/packages/react/src/hooks/useConnectors.ts new file mode 100644 index 0000000000..40a681689d --- /dev/null +++ b/packages/react/src/hooks/useConnectors.ts @@ -0,0 +1,34 @@ +'use client' + +import { + type Config, + type GetConnectorsReturnType, + type ResolvedRegister, + getConnectors, + watchConnectors, +} from '@wagmi/core' +import { useSyncExternalStore } from 'react' + +import type { ConfigParameter } from '../types/properties.js' +import { useConfig } from './useConfig.js' + +export type UseConnectorsParameters = + ConfigParameter + +export type UseConnectorsReturnType = + GetConnectorsReturnType + +/** https://wagmi.sh/react/api/hooks/useConnectors */ +export function useConnectors< + config extends Config = ResolvedRegister['config'], +>( + parameters: UseConnectorsParameters = {}, +): UseConnectorsReturnType { + const config = useConfig(parameters) + + return useSyncExternalStore( + (onChange) => watchConnectors(config, { onChange }), + () => getConnectors(config), + () => getConnectors(config), + ) +} diff --git a/packages/react/src/hooks/useDeployContract.test-d.ts b/packages/react/src/hooks/useDeployContract.test-d.ts new file mode 100644 index 0000000000..93e53c472f --- /dev/null +++ b/packages/react/src/hooks/useDeployContract.test-d.ts @@ -0,0 +1,105 @@ +import type { DeployContractErrorType } from '@wagmi/core' +import { abi, bytecode } from '@wagmi/test' +import type { Abi, Hash } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { useDeployContract } from './useDeployContract.js' + +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { context, data, error, deployContract, variables } = useDeployContract( + { + mutation: { + onMutate(variables) { + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: Abi + args?: readonly unknown[] | undefined + }>() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: Abi + args?: readonly unknown[] | undefined + }>() + }, + onSuccess(data, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: Abi + args?: readonly unknown[] | undefined + }>() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: Abi + args?: readonly unknown[] | undefined + }>() + }, + }, + }, + ) + + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf< + { chainId?: number | undefined } | undefined + >() + expectTypeOf(context).toEqualTypeOf() + + deployContract( + { + abi: abi.bayc, + bytecode: bytecode.bayc, + args: ['Bored Ape Wagmi Club', 'BAYC', 69420n, 0n], + chainId: 1, + }, + { + onError(error, variables, context) { + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: typeof abi.bayc + args: readonly [string, string, bigint, bigint] + }>() + }, + onSuccess(data, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: typeof abi.bayc + args: readonly [string, string, bigint, bigint] + }>() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: typeof abi.bayc + args: readonly [string, string, bigint, bigint] + }>() + }, + }, + ) +}) diff --git a/packages/react/src/hooks/useDeployContract.test.ts b/packages/react/src/hooks/useDeployContract.test.ts new file mode 100644 index 0000000000..561129bdbc --- /dev/null +++ b/packages/react/src/hooks/useDeployContract.test.ts @@ -0,0 +1,24 @@ +import { connect, disconnect } from '@wagmi/core' +import { abi, bytecode, config, transactionHashRegex } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useDeployContract } from './useDeployContract.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + const { result } = renderHook(() => useDeployContract()) + + result.current.deployContract({ + abi: abi.bayc, + bytecode: bytecode.bayc, + args: ['Bored Ape Wagmi Club', 'BAYC', 69420n, 0n], + }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current.data).toMatch(transactionHashRegex) + + await disconnect(config, { connector }) +}) diff --git a/packages/react/src/hooks/useDeployContract.ts b/packages/react/src/hooks/useDeployContract.ts new file mode 100644 index 0000000000..d37f3206d4 --- /dev/null +++ b/packages/react/src/hooks/useDeployContract.ts @@ -0,0 +1,78 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { + Config, + DeployContractErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type DeployContractData, + type DeployContractMutate, + type DeployContractMutateAsync, + type DeployContractVariables, + deployContractMutationOptions, +} from '@wagmi/core/query' +import type { Abi } from 'viem' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseDeployContractParameters< + config extends Config = Config, + context = unknown, +> = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + DeployContractData, + DeployContractErrorType, + DeployContractVariables, + context + > + | undefined + } +> + +export type UseDeployContractReturnType< + config extends Config = Config, + context = unknown, +> = UseMutationReturnType< + DeployContractData, + DeployContractErrorType, + DeployContractVariables, + context +> & { + deployContract: DeployContractMutate + deployContractAsync: DeployContractMutateAsync +} + +/** https://wagmi.sh/react/api/hooks/useDeployContract */ +export function useDeployContract< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseDeployContractParameters = {}, +): UseDeployContractReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = deployContractMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + type Return = UseDeployContractReturnType + return { + ...result, + deployContract: mutate as Return['deployContract'], + deployContractAsync: mutateAsync as Return['deployContractAsync'], + } +} diff --git a/packages/react/src/hooks/useDisconnect.test-d.ts b/packages/react/src/hooks/useDisconnect.test-d.ts new file mode 100644 index 0000000000..7bf3689450 --- /dev/null +++ b/packages/react/src/hooks/useDisconnect.test-d.ts @@ -0,0 +1,87 @@ +import type { Connector, DisconnectErrorType } from '@wagmi/core' +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useDisconnect } from './useDisconnect.js' + +const connector = config.connectors[0]! +const contextValue = { foo: 'bar' } as const + +test('parameter', () => { + expectTypeOf(useDisconnect().disconnect) + .parameter(0) + .toEqualTypeOf<{ connector?: Connector | undefined } | undefined>() + expectTypeOf(useDisconnect().disconnect) + .parameter(0) + .toEqualTypeOf<{ connector?: Connector | undefined } | undefined>() +}) + +test('context', () => { + const { context, data, disconnect, error, variables } = useDisconnect({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(context).toEqualTypeOf() + + disconnect( + { connector }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/react/src/hooks/useDisconnect.test.ts b/packages/react/src/hooks/useDisconnect.test.ts new file mode 100644 index 0000000000..26c7787d98 --- /dev/null +++ b/packages/react/src/hooks/useDisconnect.test.ts @@ -0,0 +1,32 @@ +import { connect } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { beforeEach, expect, test } from 'vitest' + +import { useAccount } from './useAccount.js' +import { useDisconnect } from './useDisconnect.js' + +const connector = config.connectors[0]! + +beforeEach(async () => { + await connect(config, { connector }) +}) + +test('default', async () => { + const { result } = renderHook(() => ({ + useAccount: useAccount(), + useDisconnect: useDisconnect(), + })) + + expect(result.current.useAccount.address).toBeDefined() + expect(result.current.useAccount.status).toEqual('connected') + + result.current.useDisconnect.disconnect() + + await waitFor(() => + expect(result.current.useAccount.isDisconnected).toBeTruthy(), + ) + + expect(result.current.useAccount.address).not.toBeDefined() + expect(result.current.useAccount.status).toEqual('disconnected') +}) diff --git a/packages/react/src/hooks/useDisconnect.ts b/packages/react/src/hooks/useDisconnect.ts new file mode 100644 index 0000000000..b5bff5bfe3 --- /dev/null +++ b/packages/react/src/hooks/useDisconnect.ts @@ -0,0 +1,70 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { Connector, DisconnectErrorType } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type DisconnectData, + type DisconnectMutate, + type DisconnectMutateAsync, + type DisconnectVariables, + disconnectMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' +import { useConnections } from './useConnections.js' + +export type UseDisconnectParameters = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + DisconnectData, + DisconnectErrorType, + DisconnectVariables, + context + > + | undefined + } +> + +export type UseDisconnectReturnType = Compute< + UseMutationReturnType< + DisconnectData, + DisconnectErrorType, + DisconnectVariables, + context + > & { + connectors: readonly Connector[] + disconnect: DisconnectMutate + disconnectAsync: DisconnectMutateAsync + } +> + +/** https://wagmi.sh/react/api/hooks/useDisconnect */ +export function useDisconnect( + parameters: UseDisconnectParameters = {}, +): UseDisconnectReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = disconnectMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + return { + ...result, + connectors: useConnections({ config }).map( + (connection) => connection.connector, + ), + disconnect: mutate, + disconnectAsync: mutateAsync, + } +} diff --git a/packages/react/src/hooks/useEnsAddress.test.ts b/packages/react/src/hooks/useEnsAddress.test.ts new file mode 100644 index 0000000000..ff73c45f9d --- /dev/null +++ b/packages/react/src/hooks/useEnsAddress.test.ts @@ -0,0 +1,50 @@ +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useEnsAddress } from './useEnsAddress.js' + +test('default', async () => { + const { result } = renderHook(() => + useEnsAddress({ + name: 'wevm.eth', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": "0xd2135CfB216b74109775236E36d4b433F1DF507B", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "ensAddress", + { + "chainId": 1, + "name": "wevm.eth", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/useEnsAddress.ts b/packages/react/src/hooks/useEnsAddress.ts new file mode 100644 index 0000000000..999e07d999 --- /dev/null +++ b/packages/react/src/hooks/useEnsAddress.ts @@ -0,0 +1,58 @@ +'use client' + +import type { + Config, + GetEnsAddressErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetEnsAddressData, + type GetEnsAddressOptions, + type GetEnsAddressQueryFnData, + type GetEnsAddressQueryKey, + getEnsAddressQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseEnsAddressParameters< + config extends Config = Config, + selectData = GetEnsAddressData, +> = Compute< + GetEnsAddressOptions & + ConfigParameter & + QueryParameter< + GetEnsAddressQueryFnData, + GetEnsAddressErrorType, + selectData, + GetEnsAddressQueryKey + > +> + +export type UseEnsAddressReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useEnsAddress */ +export function useEnsAddress< + config extends Config = ResolvedRegister['config'], + selectData = GetEnsAddressData, +>( + parameters: UseEnsAddressParameters = {}, +): UseEnsAddressReturnType { + const { name, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getEnsAddressQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(name && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useEnsAvatar.test.ts b/packages/react/src/hooks/useEnsAvatar.test.ts new file mode 100644 index 0000000000..d1f558be13 --- /dev/null +++ b/packages/react/src/hooks/useEnsAvatar.test.ts @@ -0,0 +1,50 @@ +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useEnsAvatar } from './useEnsAvatar.js' + +test('default', async () => { + const { result } = renderHook(() => + useEnsAvatar({ + name: 'wevm.eth', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": "https://euc.li/wevm.eth", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "ensAvatar", + { + "chainId": 1, + "name": "wevm.eth", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/useEnsAvatar.ts b/packages/react/src/hooks/useEnsAvatar.ts new file mode 100644 index 0000000000..721653bf07 --- /dev/null +++ b/packages/react/src/hooks/useEnsAvatar.ts @@ -0,0 +1,58 @@ +'use client' + +import type { + Config, + GetEnsAvatarErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetEnsAvatarData, + type GetEnsAvatarOptions, + type GetEnsAvatarQueryFnData, + type GetEnsAvatarQueryKey, + getEnsAvatarQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseEnsAvatarParameters< + config extends Config = Config, + selectData = GetEnsAvatarData, +> = Compute< + GetEnsAvatarOptions & + ConfigParameter & + QueryParameter< + GetEnsAvatarQueryFnData, + GetEnsAvatarErrorType, + selectData, + GetEnsAvatarQueryKey + > +> + +export type UseEnsAvatarReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useEnsAvatar */ +export function useEnsAvatar< + config extends Config = ResolvedRegister['config'], + selectData = GetEnsAvatarData, +>( + parameters: UseEnsAvatarParameters = {}, +): UseEnsAvatarReturnType { + const { name, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getEnsAvatarQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(name && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useEnsName.test.ts b/packages/react/src/hooks/useEnsName.test.ts new file mode 100644 index 0000000000..8a069b076d --- /dev/null +++ b/packages/react/src/hooks/useEnsName.test.ts @@ -0,0 +1,50 @@ +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useEnsName } from './useEnsName.js' + +test('default', async () => { + const { result } = renderHook(() => + useEnsName({ + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": "wevm.eth", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "ensName", + { + "address": "0xd2135CfB216b74109775236E36d4b433F1DF507B", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/useEnsName.ts b/packages/react/src/hooks/useEnsName.ts new file mode 100644 index 0000000000..ddf88fed9d --- /dev/null +++ b/packages/react/src/hooks/useEnsName.ts @@ -0,0 +1,54 @@ +'use client' + +import type { Config, GetEnsNameErrorType, ResolvedRegister } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetEnsNameData, + type GetEnsNameOptions, + type GetEnsNameQueryFnData, + type GetEnsNameQueryKey, + getEnsNameQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseEnsNameParameters< + config extends Config = Config, + selectData = GetEnsNameData, +> = Compute< + GetEnsNameOptions & + ConfigParameter & + QueryParameter< + GetEnsNameQueryFnData, + GetEnsNameErrorType, + selectData, + GetEnsNameQueryKey + > +> + +export type UseEnsNameReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useEnsName */ +export function useEnsName< + config extends Config = ResolvedRegister['config'], + selectData = GetEnsNameData, +>( + parameters: UseEnsNameParameters = {}, +): UseEnsNameReturnType { + const { address, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getEnsNameQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(address && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useEnsResolver.test.ts b/packages/react/src/hooks/useEnsResolver.test.ts new file mode 100644 index 0000000000..f5b89d8f63 --- /dev/null +++ b/packages/react/src/hooks/useEnsResolver.test.ts @@ -0,0 +1,50 @@ +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useEnsResolver } from './useEnsResolver.js' + +test('default', async () => { + const { result } = renderHook(() => + useEnsResolver({ + name: 'wevm.eth', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": "0x4976fb03C32e5B8cfe2b6cCB31c09Ba78EBaBa41", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "ensResolver", + { + "chainId": 1, + "name": "wevm.eth", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/useEnsResolver.ts b/packages/react/src/hooks/useEnsResolver.ts new file mode 100644 index 0000000000..e883debfa6 --- /dev/null +++ b/packages/react/src/hooks/useEnsResolver.ts @@ -0,0 +1,58 @@ +'use client' + +import type { + Config, + GetEnsResolverErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetEnsResolverData, + type GetEnsResolverOptions, + type GetEnsResolverQueryFnData, + type GetEnsResolverQueryKey, + getEnsResolverQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseEnsResolverParameters< + config extends Config = Config, + selectData = GetEnsResolverData, +> = Compute< + GetEnsResolverOptions & + ConfigParameter & + QueryParameter< + GetEnsResolverQueryFnData, + GetEnsResolverErrorType, + selectData, + GetEnsResolverQueryKey + > +> + +export type UseEnsResolverReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useEnsResolver */ +export function useEnsResolver< + config extends Config = ResolvedRegister['config'], + selectData = GetEnsResolverData, +>( + parameters: UseEnsResolverParameters = {}, +): UseEnsResolverReturnType { + const { name, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getEnsResolverQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(name && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useEnsText.test.ts b/packages/react/src/hooks/useEnsText.test.ts new file mode 100644 index 0000000000..5e1c4b1d8c --- /dev/null +++ b/packages/react/src/hooks/useEnsText.test.ts @@ -0,0 +1,150 @@ +import { wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useEnsText } from './useEnsText.js' + +test('default', async () => { + const { result } = renderHook(() => + useEnsText({ + key: 'com.twitter', + name: 'wevm.eth', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": "wevm_dev", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "ensText", + { + "chainId": 1, + "key": "com.twitter", + "name": "wevm.eth", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: name: undefined -> defined', async () => { + let name: string | undefined = undefined + + const { result, rerender } = renderHook(() => + useEnsText({ + key: 'com.twitter', + name, + }), + ) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "ensText", + { + "chainId": 1, + "key": "com.twitter", + "name": undefined, + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + + name = 'wevm.eth' + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": "wevm_dev", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "ensText", + { + "chainId": 1, + "key": "com.twitter", + "name": "wevm.eth", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useEnsText()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useEnsText.ts b/packages/react/src/hooks/useEnsText.ts new file mode 100644 index 0000000000..2e65238c4f --- /dev/null +++ b/packages/react/src/hooks/useEnsText.ts @@ -0,0 +1,54 @@ +'use client' + +import type { Config, GetEnsTextErrorType, ResolvedRegister } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetEnsTextData, + type GetEnsTextOptions, + type GetEnsTextQueryFnData, + type GetEnsTextQueryKey, + getEnsTextQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseEnsTextParameters< + config extends Config = Config, + selectData = GetEnsTextData, +> = Compute< + GetEnsTextOptions & + ConfigParameter & + QueryParameter< + GetEnsTextQueryFnData, + GetEnsTextErrorType, + selectData, + GetEnsTextQueryKey + > +> + +export type UseEnsTextReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useEnsText */ +export function useEnsText< + config extends Config = ResolvedRegister['config'], + selectData = GetEnsTextData, +>( + parameters: UseEnsTextParameters = {}, +): UseEnsTextReturnType { + const { key, name, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getEnsTextQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(key && name && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useEstimateFeesPerGas.test-d.ts b/packages/react/src/hooks/useEstimateFeesPerGas.test-d.ts new file mode 100644 index 0000000000..679def0fd6 --- /dev/null +++ b/packages/react/src/hooks/useEstimateFeesPerGas.test-d.ts @@ -0,0 +1,49 @@ +import { expectTypeOf, test } from 'vitest' +import { useEstimateFeesPerGas } from './useEstimateFeesPerGas.js' + +test('types', () => { + const result = useEstimateFeesPerGas() + expectTypeOf(result.data).toMatchTypeOf< + | { + gasPrice?: undefined + maxFeePerGas: bigint + maxPriorityFeePerGas: bigint + formatted: { + gasPrice?: undefined + maxFeePerGas: string + maxPriorityFeePerGas: string + } + } + | undefined + >() + + const result2 = useEstimateFeesPerGas({ type: 'legacy' }) + expectTypeOf(result2.data).toMatchTypeOf< + | { + gasPrice: bigint + maxFeePerGas?: undefined + maxPriorityFeePerGas?: undefined + formatted: { + gasPrice: string + maxFeePerGas?: undefined + maxPriorityFeePerGas?: undefined + } + } + | undefined + >() + + const result3 = useEstimateFeesPerGas({ type: 'eip1559' }) + expectTypeOf(result3.data).toMatchTypeOf< + | { + gasPrice?: undefined + maxFeePerGas: bigint + maxPriorityFeePerGas: bigint + formatted: { + gasPrice?: undefined + maxFeePerGas: string + maxPriorityFeePerGas: string + } + } + | undefined + >() +}) diff --git a/packages/react/src/hooks/useEstimateFeesPerGas.test.ts b/packages/react/src/hooks/useEstimateFeesPerGas.test.ts new file mode 100644 index 0000000000..5d1859eda9 --- /dev/null +++ b/packages/react/src/hooks/useEstimateFeesPerGas.test.ts @@ -0,0 +1,19 @@ +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useEstimateFeesPerGas } from './useEstimateFeesPerGas.js' + +test('default', async () => { + const { result } = renderHook(() => useEstimateFeesPerGas()) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(Object.keys(result.current.data!)).toMatchInlineSnapshot(` + [ + "formatted", + "gasPrice", + "maxFeePerGas", + "maxPriorityFeePerGas", + ] + `) +}) diff --git a/packages/react/src/hooks/useEstimateFeesPerGas.ts b/packages/react/src/hooks/useEstimateFeesPerGas.ts new file mode 100644 index 0000000000..59dc2aa910 --- /dev/null +++ b/packages/react/src/hooks/useEstimateFeesPerGas.ts @@ -0,0 +1,62 @@ +'use client' + +import type { + Config, + EstimateFeesPerGasErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type EstimateFeesPerGasData, + type EstimateFeesPerGasOptions, + type EstimateFeesPerGasQueryFnData, + type EstimateFeesPerGasQueryKey, + estimateFeesPerGasQueryOptions, +} from '@wagmi/core/query' +import type { FeeValuesType } from 'viem' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseEstimateFeesPerGasParameters< + type extends FeeValuesType = FeeValuesType, + config extends Config = Config, + selectData = EstimateFeesPerGasData, +> = Compute< + EstimateFeesPerGasOptions & + ConfigParameter & + QueryParameter< + EstimateFeesPerGasQueryFnData, + EstimateFeesPerGasErrorType, + selectData, + EstimateFeesPerGasQueryKey + > +> + +export type UseEstimateFeesPerGasReturnType< + type extends FeeValuesType = FeeValuesType, + selectData = EstimateFeesPerGasData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useEstimateFeesPerGas */ +export function useEstimateFeesPerGas< + config extends Config = ResolvedRegister['config'], + type extends FeeValuesType = 'eip1559', + selectData = EstimateFeesPerGasData, +>( + parameters: UseEstimateFeesPerGasParameters = {}, +): UseEstimateFeesPerGasReturnType { + const { query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = estimateFeesPerGasQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + + return useQuery({ ...query, ...options }) +} diff --git a/packages/react/src/hooks/useEstimateGas.test-d.ts b/packages/react/src/hooks/useEstimateGas.test-d.ts new file mode 100644 index 0000000000..d50618aad2 --- /dev/null +++ b/packages/react/src/hooks/useEstimateGas.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useEstimateGas } from './useEstimateGas.js' + +test('select data', () => { + const result = useEstimateGas({ + query: { + select(data) { + return data.toString() + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useEstimateGas.test.ts b/packages/react/src/hooks/useEstimateGas.test.ts new file mode 100644 index 0000000000..0c3ab08324 --- /dev/null +++ b/packages/react/src/hooks/useEstimateGas.test.ts @@ -0,0 +1,139 @@ +import { accounts } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { type Address, parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { useEstimateGas } from './useEstimateGas.js' + +test('default', async () => { + const { result } = renderHook(() => + useEstimateGas({ + account: accounts[0], + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": 21000n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "estimateGas", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + "to": "0xd2135CfB216b74109775236E36d4b433F1DF507B", + "value": 10000000000000000n, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: address: undefined -> defined', async () => { + let account: Address | undefined = undefined + + const { result, rerender } = renderHook(() => useEstimateGas({ account })) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "estimateGas", + { + "account": undefined, + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + + account = accounts[0] + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": 53001n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "estimateGas", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/useEstimateGas.ts b/packages/react/src/hooks/useEstimateGas.ts new file mode 100644 index 0000000000..87c0e19e44 --- /dev/null +++ b/packages/react/src/hooks/useEstimateGas.ts @@ -0,0 +1,70 @@ +'use client' + +import type { + Config, + EstimateGasErrorType, + ResolvedRegister, +} from '@wagmi/core' +import { + type EstimateGasData, + type EstimateGasOptions, + type EstimateGasQueryFnData, + type EstimateGasQueryKey, + estimateGasQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' +import { useConnectorClient } from './useConnectorClient.js' + +export type UseEstimateGasParameters< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = EstimateGasData, +> = EstimateGasOptions & + ConfigParameter & + QueryParameter< + EstimateGasQueryFnData, + EstimateGasErrorType, + selectData, + EstimateGasQueryKey + > + +export type UseEstimateGasReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useEstimateGas */ +export function useEstimateGas< + config extends Config = ResolvedRegister['config'], + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = EstimateGasData, +>( + parameters?: UseEstimateGasParameters, +): UseEstimateGasReturnType + +export function useEstimateGas( + parameters: UseEstimateGasParameters = {}, +): UseEstimateGasReturnType { + const { connector, query = {} } = parameters + + const config = useConfig(parameters) + const { data: connectorClient } = useConnectorClient({ + config, + connector, + query: { enabled: parameters.account === undefined }, + }) + const account = parameters.account ?? connectorClient?.account + const chainId = useChainId({ config }) + + const options = estimateGasQueryOptions(config, { + ...parameters, + account, + chainId: parameters.chainId ?? chainId, + connector, + }) + const enabled = Boolean((account || connector) && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useEstimateMaxPriorityFeePerGas.test-d.ts b/packages/react/src/hooks/useEstimateMaxPriorityFeePerGas.test-d.ts new file mode 100644 index 0000000000..c4b1be1c8b --- /dev/null +++ b/packages/react/src/hooks/useEstimateMaxPriorityFeePerGas.test-d.ts @@ -0,0 +1,13 @@ +import { expectTypeOf, test } from 'vitest' +import { useEstimateMaxPriorityFeePerGas } from './useEstimateMaxPriorityFeePerGas.js' + +test('select data', () => { + const result = useEstimateMaxPriorityFeePerGas({ + query: { + select(data) { + return data.toString() + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useEstimateMaxPriorityFeePerGas.test.ts b/packages/react/src/hooks/useEstimateMaxPriorityFeePerGas.test.ts new file mode 100644 index 0000000000..21c09188e3 --- /dev/null +++ b/packages/react/src/hooks/useEstimateMaxPriorityFeePerGas.test.ts @@ -0,0 +1,96 @@ +import { chain, testClient } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useEstimateMaxPriorityFeePerGas } from './useEstimateMaxPriorityFeePerGas.js' + +test('default', async () => { + await testClient.mainnet.restart() + + const { result } = renderHook(() => useEstimateMaxPriorityFeePerGas()) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('bigint') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "estimateMaxPriorityFeePerGas", + { + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: chainId', async () => { + await testClient.mainnet2.restart() + await testClient.mainnet2.mine({ blocks: 1 }) + + const { result } = renderHook(() => + useEstimateMaxPriorityFeePerGas({ chainId: chain.mainnet2.id }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('bigint') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "estimateMaxPriorityFeePerGas", + { + "chainId": 456, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/useEstimateMaxPriorityFeePerGas.ts b/packages/react/src/hooks/useEstimateMaxPriorityFeePerGas.ts new file mode 100644 index 0000000000..0f884dba75 --- /dev/null +++ b/packages/react/src/hooks/useEstimateMaxPriorityFeePerGas.ts @@ -0,0 +1,61 @@ +'use client' + +import type { + Config, + EstimateMaxPriorityFeePerGasErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type EstimateMaxPriorityFeePerGasData, + type EstimateMaxPriorityFeePerGasOptions, + type EstimateMaxPriorityFeePerGasQueryFnData, + type EstimateMaxPriorityFeePerGasQueryKey, + estimateMaxPriorityFeePerGasQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseEstimateMaxPriorityFeePerGasParameters< + config extends Config = Config, + selectData = EstimateMaxPriorityFeePerGasData, +> = Compute< + EstimateMaxPriorityFeePerGasOptions & + ConfigParameter & + QueryParameter< + EstimateMaxPriorityFeePerGasQueryFnData, + EstimateMaxPriorityFeePerGasErrorType, + selectData, + EstimateMaxPriorityFeePerGasQueryKey + > +> + +export type UseEstimateMaxPriorityFeePerGasReturnType< + selectData = EstimateMaxPriorityFeePerGasData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useEstimateMaxPriorityFeePerGas */ +export function useEstimateMaxPriorityFeePerGas< + config extends Config = ResolvedRegister['config'], + selectData = EstimateMaxPriorityFeePerGasData, +>( + parameters: UseEstimateMaxPriorityFeePerGasParameters< + config, + selectData + > = {}, +): UseEstimateMaxPriorityFeePerGasReturnType { + const { query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = estimateMaxPriorityFeePerGasQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + + return useQuery({ ...query, ...options }) +} diff --git a/packages/react/src/hooks/useFeeHistory.test-d.ts b/packages/react/src/hooks/useFeeHistory.test-d.ts new file mode 100644 index 0000000000..855fa893ae --- /dev/null +++ b/packages/react/src/hooks/useFeeHistory.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useFeeHistory } from './useFeeHistory.js' + +test('select data', () => { + const result = useFeeHistory({ + query: { + select(data) { + return data.gasUsedRatio + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useFeeHistory.test.ts b/packages/react/src/hooks/useFeeHistory.test.ts new file mode 100644 index 0000000000..53b6a8c55b --- /dev/null +++ b/packages/react/src/hooks/useFeeHistory.test.ts @@ -0,0 +1,452 @@ +import { chain, wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useFeeHistory } from './useFeeHistory.js' + +test('default', async () => { + const { result } = renderHook(() => + useFeeHistory({ + blockCount: 4, + rewardPercentiles: [25, 75], + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toMatchObject({ + baseFeePerGas: expect.arrayContaining([expect.any(BigInt)]), + gasUsedRatio: expect.arrayContaining([expect.any(Number)]), + oldestBlock: expect.any(BigInt), + reward: expect.any(Array), + }) + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "feeHistory", + { + "blockCount": 4, + "chainId": 1, + "rewardPercentiles": [ + 25, + 75, + ], + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: chainId', async () => { + const { result } = renderHook(() => + useFeeHistory({ + blockCount: 4, + rewardPercentiles: [25, 75], + chainId: chain.mainnet2.id, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toMatchObject({ + baseFeePerGas: expect.arrayContaining([expect.any(BigInt)]), + gasUsedRatio: expect.arrayContaining([expect.any(Number)]), + oldestBlock: expect.any(BigInt), + reward: expect.any(Array), + }) + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "feeHistory", + { + "blockCount": 4, + "chainId": 456, + "rewardPercentiles": [ + 25, + 75, + ], + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: blockNumber', async () => { + const { result } = renderHook(() => + useFeeHistory({ + blockCount: 4, + rewardPercentiles: [25, 75], + blockNumber: 18677379n, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toMatchObject({ + baseFeePerGas: expect.arrayContaining([expect.any(BigInt)]), + gasUsedRatio: expect.arrayContaining([expect.any(Number)]), + oldestBlock: expect.any(BigInt), + reward: expect.any(Array), + }) + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "feeHistory", + { + "blockCount": 4, + "blockNumber": 18677379n, + "chainId": 1, + "rewardPercentiles": [ + 25, + 75, + ], + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: blockTag', async () => { + const { result } = renderHook(() => + useFeeHistory({ + blockCount: 4, + rewardPercentiles: [25, 75], + blockTag: 'safe', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toMatchObject({ + baseFeePerGas: expect.arrayContaining([expect.any(BigInt)]), + gasUsedRatio: expect.arrayContaining([expect.any(Number)]), + oldestBlock: expect.any(BigInt), + reward: expect.any(Array), + }) + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "feeHistory", + { + "blockCount": 4, + "blockTag": "safe", + "chainId": 1, + "rewardPercentiles": [ + 25, + 75, + ], + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: blockCount: undefined -> defined', async () => { + let blockCount: number | undefined = undefined + + const { result, rerender } = renderHook(() => + useFeeHistory({ + blockCount, + rewardPercentiles: [25, 75], + }), + ) + + { + const { data, ...rest } = result.current + expect(data).toBeTypeOf('undefined') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "feeHistory", + { + "blockCount": undefined, + "chainId": 1, + "rewardPercentiles": [ + 25, + 75, + ], + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + } + + blockCount = 4 + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toMatchObject({ + baseFeePerGas: expect.arrayContaining([expect.any(BigInt)]), + gasUsedRatio: expect.arrayContaining([expect.any(Number)]), + oldestBlock: expect.any(BigInt), + reward: expect.any(Array), + }) + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "feeHistory", + { + "blockCount": 4, + "chainId": 1, + "rewardPercentiles": [ + 25, + 75, + ], + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: rewardPercentiles: undefined -> defined', async () => { + let rewardPercentiles: number[] | undefined = undefined + + const { result, rerender } = renderHook(() => + useFeeHistory({ + blockCount: 4, + rewardPercentiles, + }), + ) + + { + const { data, ...rest } = result.current + expect(data).toBeTypeOf('undefined') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "feeHistory", + { + "blockCount": 4, + "chainId": 1, + "rewardPercentiles": undefined, + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + } + + rewardPercentiles = [25, 75] + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toMatchObject({ + baseFeePerGas: expect.arrayContaining([expect.any(BigInt)]), + gasUsedRatio: expect.arrayContaining([expect.any(Number)]), + oldestBlock: expect.any(BigInt), + reward: expect.any(Array), + }) + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "feeHistory", + { + "blockCount": 4, + "chainId": 1, + "rewardPercentiles": [ + 25, + 75, + ], + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useFeeHistory()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useFeeHistory.ts b/packages/react/src/hooks/useFeeHistory.ts new file mode 100644 index 0000000000..0754757b31 --- /dev/null +++ b/packages/react/src/hooks/useFeeHistory.ts @@ -0,0 +1,64 @@ +'use client' + +import type { + Config, + GetFeeHistoryErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetFeeHistoryData, + type GetFeeHistoryOptions, + type GetFeeHistoryQueryFnData, + type GetFeeHistoryQueryKey, + getFeeHistoryQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseFeeHistoryParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetFeeHistoryData, +> = Compute< + GetFeeHistoryOptions & + ConfigParameter & + QueryParameter< + GetFeeHistoryQueryFnData, + GetFeeHistoryErrorType, + selectData, + GetFeeHistoryQueryKey + > +> + +export type UseFeeHistoryReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useFeeHistory */ +export function useFeeHistory< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetFeeHistoryData, +>( + parameters: UseFeeHistoryParameters = {}, +): UseFeeHistoryReturnType { + const { blockCount, rewardPercentiles, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getFeeHistoryQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean( + blockCount && rewardPercentiles && (query.enabled ?? true), + ) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useGasPrice.test-d.ts b/packages/react/src/hooks/useGasPrice.test-d.ts new file mode 100644 index 0000000000..7108993a20 --- /dev/null +++ b/packages/react/src/hooks/useGasPrice.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useGasPrice } from './useGasPrice.js' + +test('select data', () => { + const result = useGasPrice({ + query: { + select(data) { + return data?.toString() + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useGasPrice.test.ts b/packages/react/src/hooks/useGasPrice.test.ts new file mode 100644 index 0000000000..5dd97cc96c --- /dev/null +++ b/packages/react/src/hooks/useGasPrice.test.ts @@ -0,0 +1,103 @@ +import { chain, testClient } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useGasPrice } from './useGasPrice.js' + +test('default', async () => { + await testClient.mainnet.restart() + + await testClient.mainnet.setNextBlockBaseFeePerGas({ + baseFeePerGas: 2_000_000_000n, + }) + await testClient.mainnet.mine({ blocks: 1 }) + + const { result } = renderHook(() => useGasPrice()) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": 2750000000n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "gasPrice", + { + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: chainId', async () => { + await testClient.mainnet2.restart() + + await testClient.mainnet2.setNextBlockBaseFeePerGas({ + baseFeePerGas: 1_000_000_000n, + }) + await testClient.mainnet2.mine({ blocks: 1 }) + + const { result } = renderHook(() => + useGasPrice({ chainId: chain.mainnet2.id }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": 1875000000n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "gasPrice", + { + "chainId": 456, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/useGasPrice.ts b/packages/react/src/hooks/useGasPrice.ts new file mode 100644 index 0000000000..dc823dcf64 --- /dev/null +++ b/packages/react/src/hooks/useGasPrice.ts @@ -0,0 +1,62 @@ +'use client' + +import type { + Config, + GetGasPriceErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetGasPriceData, + type GetGasPriceOptions, + type GetGasPriceQueryFnData, + type GetGasPriceQueryKey, + getGasPriceQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseGasPriceParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetGasPriceData, +> = Compute< + GetGasPriceOptions & + ConfigParameter & + QueryParameter< + GetGasPriceQueryFnData, + GetGasPriceErrorType, + selectData, + GetGasPriceQueryKey + > +> + +export type UseGasPriceReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useGasPrice */ +export function useGasPrice< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetGasPriceData, +>( + parameters: UseGasPriceParameters = {}, +): UseGasPriceReturnType { + const { query = {} } = parameters + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + const chainId = parameters.chainId ?? configChainId + + const options = getGasPriceQueryOptions(config, { + ...parameters, + chainId, + }) + + return useQuery({ ...query, ...options }) +} diff --git a/packages/react/src/hooks/useInfiniteReadContracts.test-d.ts b/packages/react/src/hooks/useInfiniteReadContracts.test-d.ts new file mode 100644 index 0000000000..60b3a2cddd --- /dev/null +++ b/packages/react/src/hooks/useInfiniteReadContracts.test-d.ts @@ -0,0 +1,44 @@ +import { abi } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useInfiniteReadContracts } from './useInfiniteReadContracts.js' + +test('select data', () => { + const result = useInfiniteReadContracts({ + allowFailure: false, + cacheKey: 'foo', + contracts(pageParam) { + expectTypeOf(pageParam).toEqualTypeOf() + return [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ] + }, + query: { + initialPageParam: '0', + getNextPageParam(lastPage, allPages, lastPageParam, allPageParams) { + expectTypeOf(lastPage).toEqualTypeOf<[bigint, string]>() + expectTypeOf(allPages).toEqualTypeOf<[bigint, string][]>() + expectTypeOf(lastPageParam).toEqualTypeOf() + expectTypeOf(allPageParams).toEqualTypeOf() + return lastPageParam + 1 + }, + select(data) { + expectTypeOf(data.pageParams[0]!).toEqualTypeOf() + expectTypeOf(data.pages[0]!).toEqualTypeOf<[bigint, string]>() + return data.pages[0]?.[0]! + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useInfiniteReadContracts.test.ts b/packages/react/src/hooks/useInfiniteReadContracts.test.ts new file mode 100644 index 0000000000..0feb1e0e98 --- /dev/null +++ b/packages/react/src/hooks/useInfiniteReadContracts.test.ts @@ -0,0 +1,91 @@ +import { abi, address } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useInfiniteReadContracts } from './useInfiniteReadContracts.js' + +test( + 'default', + async () => { + const limit = 3 + + const { result } = renderHook(() => + useInfiniteReadContracts({ + cacheKey: 'foo', + contracts(pageParam) { + return [...new Array(limit)].map( + (_, i) => + ({ + address: address.shields, + abi: abi.shields, + functionName: 'tokenURI', + args: [BigInt(pageParam + i + 1)], + }) as const, + ) + }, + query: { + initialPageParam: 0, + getNextPageParam(_lastPage, _allPages, lastPageParam) { + return lastPageParam + limit + }, + select(data) { + const results = [] + for (const page of data.pages) { + for (const response of page) { + if (response.status === 'success') { + const decoded = atob( + response.result.replace(/(^.*base64,)/, ''), + ) + const json = JSON.parse(decoded) as { name: string } + results.push(json.name) + } else results.push('Error fetching shield') + } + } + return results + }, + }, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + expect(result.current.data).toMatchInlineSnapshot(` + [ + "Three Shields on Pink Perfect", + "Three Shields on Sky Perfect", + "Three Shields on Evergreen Perfect", + ] + `) + + await result.current.fetchNextPage() + + await waitFor(() => expect(result.current.hasNextPage).toBeTruthy()) + expect(result.current.data).toMatchInlineSnapshot(` + [ + "Three Shields on Pink Perfect", + "Three Shields on Sky Perfect", + "Three Shields on Evergreen Perfect", + "Three Shields on Hi-Vis Perfect", + "Three Shields on Gray Perfect", + "Everlasting: Tracery on Onyx and Pink Razor Bordure", + ] + `) + + await result.current.fetchNextPage() + + await waitFor(() => expect(result.current.hasNextPage).toBeTruthy()) + expect(result.current.data).toMatchInlineSnapshot(` + [ + "Three Shields on Pink Perfect", + "Three Shields on Sky Perfect", + "Three Shields on Evergreen Perfect", + "Three Shields on Hi-Vis Perfect", + "Three Shields on Gray Perfect", + "Everlasting: Tracery on Onyx and Pink Razor Bordure", + "The Book of Shields on Pink Perfect", + "Menacing: Necklace on Evergreen and Hi-Vis Chief Indented", + "Secured: Telescope and Stars on Ultraviolet and Sky Doppler", + ] + `) + }, + { timeout: 20_000 }, +) diff --git a/packages/react/src/hooks/useInfiniteReadContracts.ts b/packages/react/src/hooks/useInfiniteReadContracts.ts new file mode 100644 index 0000000000..2622f434a6 --- /dev/null +++ b/packages/react/src/hooks/useInfiniteReadContracts.ts @@ -0,0 +1,89 @@ +'use client' + +import type { + Config, + ReadContractsErrorType, + ResolvedRegister, +} from '@wagmi/core' +import { + type InfiniteReadContractsQueryFnData, + type InfiniteReadContractsQueryKey, + infiniteReadContractsQueryOptions, + structuralSharing, +} from '@wagmi/core/query' +import type { ContractFunctionParameters } from 'viem' + +import type { + InfiniteReadContractsData, + InfiniteReadContractsOptions, +} from '../exports/query.js' +import type { + ConfigParameter, + InfiniteQueryParameter, +} from '../types/properties.js' +import { + type UseInfiniteQueryParameters, + type UseInfiniteQueryReturnType, + useInfiniteQuery, +} from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseInfiniteContractReadsParameters< + contracts extends readonly unknown[] = readonly ContractFunctionParameters[], + allowFailure extends boolean = true, + config extends Config = Config, + pageParam = unknown, + selectData = InfiniteReadContractsData, +> = InfiniteReadContractsOptions & + ConfigParameter & + InfiniteQueryParameter< + InfiniteReadContractsQueryFnData, + ReadContractsErrorType, + selectData, + InfiniteReadContractsData, + InfiniteReadContractsQueryKey, + pageParam + > + +export type UseInfiniteContractReadsReturnType< + contracts extends readonly unknown[] = readonly ContractFunctionParameters[], + allowFailure extends boolean = true, + selectData = InfiniteReadContractsData, +> = UseInfiniteQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useInfiniteReadContracts */ +export function useInfiniteReadContracts< + const contracts extends readonly unknown[], + allowFailure extends boolean = true, + config extends Config = ResolvedRegister['config'], + pageParam = unknown, + selectData = InfiniteReadContractsData, +>( + parameters: UseInfiniteContractReadsParameters< + contracts, + allowFailure, + config, + pageParam, + selectData + >, +): UseInfiniteContractReadsReturnType { + const { contracts = [], query } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = infiniteReadContractsQueryOptions(config, { + ...parameters, + chainId, + contracts: contracts as UseInfiniteContractReadsParameters['contracts'], + query: query as UseInfiniteQueryParameters, + }) + + return useInfiniteQuery({ + ...(query as any), + ...options, + initialPageParam: options.initialPageParam, + structuralSharing: query.structuralSharing ?? structuralSharing, + }) +} diff --git a/packages/react/src/hooks/usePrepareTransactionRequest.test-d.ts b/packages/react/src/hooks/usePrepareTransactionRequest.test-d.ts new file mode 100644 index 0000000000..9c39595ab4 --- /dev/null +++ b/packages/react/src/hooks/usePrepareTransactionRequest.test-d.ts @@ -0,0 +1,27 @@ +import { config } from '@wagmi/test' +import type { PrepareTransactionRequestReturnType } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { usePrepareTransactionRequest } from './usePrepareTransactionRequest.js' + +test('select data', () => { + const result = usePrepareTransactionRequest({ + query: { + select(data) { + return data + }, + }, + }) + + expectTypeOf(result.data).toMatchTypeOf< + PrepareTransactionRequestReturnType | undefined + >() +}) + +test('parameters: config', () => { + const result = usePrepareTransactionRequest({ + config, + chainId: 456, + }) + if (result.data) expectTypeOf(result.data.chainId).toEqualTypeOf<456>() +}) diff --git a/packages/react/src/hooks/usePrepareTransactionRequest.test.ts b/packages/react/src/hooks/usePrepareTransactionRequest.test.ts new file mode 100644 index 0000000000..7b90729dbf --- /dev/null +++ b/packages/react/src/hooks/usePrepareTransactionRequest.test.ts @@ -0,0 +1,81 @@ +import { connect, disconnect } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { usePrepareTransactionRequest } from './usePrepareTransactionRequest.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => + usePrepareTransactionRequest({ + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { + data: { + gas: _gas, + maxFeePerGas: _mfpg, + maxPriorityFeePerGas: _mpfpg, + nonce: _nonce, + ...data + } = {}, + ...rest + } = result.current + + expect(data).toMatchInlineSnapshot(` + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + "from": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "to": "0x70997970c51812dc3a010c7d01b50e0d17dc79c8", + "type": "eip1559", + "value": 1000000000000000000n, + } + `) + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "prepareTransactionRequest", + { + "chainId": 1, + "to": "0x70997970c51812dc3a010c7d01b50e0d17dc79c8", + "value": 1000000000000000000n, + }, + ], + "refetch": [Function], + "status": "success", + } + `) + + await disconnect(config, { connector }) +}) diff --git a/packages/react/src/hooks/usePrepareTransactionRequest.ts b/packages/react/src/hooks/usePrepareTransactionRequest.ts new file mode 100644 index 0000000000..509d85eb08 --- /dev/null +++ b/packages/react/src/hooks/usePrepareTransactionRequest.ts @@ -0,0 +1,102 @@ +'use client' + +import type { + Config, + PrepareTransactionRequestErrorType, + ResolvedRegister, + SelectChains, +} from '@wagmi/core' +import { + type PrepareTransactionRequestData, + type PrepareTransactionRequestOptions, + type PrepareTransactionRequestQueryKey, + prepareTransactionRequestQueryOptions, +} from '@wagmi/core/query' +import type { PrepareTransactionRequestQueryFnData } from '@wagmi/core/query' +import type { PrepareTransactionRequestRequest as viem_PrepareTransactionRequestRequest } from 'viem' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UsePrepareTransactionRequestParameters< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, + request extends viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + > = viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + >, + selectData = PrepareTransactionRequestData, +> = PrepareTransactionRequestOptions & + ConfigParameter & + QueryParameter< + PrepareTransactionRequestQueryFnData, + PrepareTransactionRequestErrorType, + selectData, + PrepareTransactionRequestQueryKey + > + +export type UsePrepareTransactionRequestReturnType< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, + request extends viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + > = viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + >, + selectData = PrepareTransactionRequestData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/usePrepareTransactionRequest */ +export function usePrepareTransactionRequest< + config extends Config = ResolvedRegister['config'], + chainId extends config['chains'][number]['id'] | undefined = undefined, + request extends viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + > = viem_PrepareTransactionRequestRequest< + SelectChains[0], + SelectChains[0] + >, + selectData = PrepareTransactionRequestData, +>( + parameters: UsePrepareTransactionRequestParameters< + config, + chainId, + request, + selectData + > = {} as any, +): UsePrepareTransactionRequestReturnType< + config, + chainId, + request, + selectData +> { + const { to, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = prepareTransactionRequestQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + } as PrepareTransactionRequestOptions) + const enabled = Boolean(to && (query.enabled ?? true)) + + return useQuery({ + ...(query as any), + ...options, + enabled, + }) as UsePrepareTransactionRequestReturnType< + config, + chainId, + request, + selectData + > +} diff --git a/packages/react/src/hooks/useProof.test-d.ts b/packages/react/src/hooks/useProof.test-d.ts new file mode 100644 index 0000000000..55f8b15330 --- /dev/null +++ b/packages/react/src/hooks/useProof.test-d.ts @@ -0,0 +1,14 @@ +import type { GetProofReturnType } from 'viem' +import { expectTypeOf, test } from 'vitest' +import { useProof } from './useProof.js' + +test('select data', () => { + const result = useProof({ + query: { + select(data) { + return data + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useProof.test.ts b/packages/react/src/hooks/useProof.test.ts new file mode 100644 index 0000000000..3c3cb51945 --- /dev/null +++ b/packages/react/src/hooks/useProof.test.ts @@ -0,0 +1,163 @@ +import { chain, wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import type { Address } from 'viem' +import { useProof } from './useProof.js' + +test('default', async () => { + const { result } = renderHook(() => + useProof({ + address: '0x4200000000000000000000000000000000000016', + chainId: chain.optimism.id, + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect({ ...result.current, data: null }).toMatchInlineSnapshot(` + { + "data": null, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getProof", + { + "address": "0x4200000000000000000000000000000000000016", + "chainId": 10, + "storageKeys": [ + "0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99", + ], + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: address: undefined -> defined', async () => { + let address: Address | undefined = undefined + + const { result, rerender } = renderHook(() => + useProof({ + address, + chainId: chain.optimism.id, + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }), + ) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "getProof", + { + "address": undefined, + "chainId": 10, + "storageKeys": [ + "0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99", + ], + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + + address = '0x4200000000000000000000000000000000000016' + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect({ ...result.current, data: null }).toMatchInlineSnapshot(` + { + "data": null, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getProof", + { + "address": "0x4200000000000000000000000000000000000016", + "chainId": 10, + "storageKeys": [ + "0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99", + ], + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useProof()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useProof.ts b/packages/react/src/hooks/useProof.ts new file mode 100644 index 0000000000..f473d509aa --- /dev/null +++ b/packages/react/src/hooks/useProof.ts @@ -0,0 +1,56 @@ +'use client' + +import type { Config, GetProofErrorType, ResolvedRegister } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetProofData, + type GetProofOptions, + type GetProofQueryKey, + getProofQueryOptions, +} from '@wagmi/core/query' +import type { GetProofQueryFnData } from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseProofParameters< + config extends Config = Config, + selectData = GetProofData, +> = Compute< + GetProofOptions & + ConfigParameter & + QueryParameter< + GetProofQueryFnData, + GetProofErrorType, + selectData, + GetProofQueryKey + > +> + +export type UseProofReturnType = UseQueryReturnType< + selectData, + GetProofErrorType +> + +/** https://wagmi.sh/react/api/hooks/useProof */ +export function useProof< + config extends Config = ResolvedRegister['config'], + selectData = GetProofData, +>( + parameters: UseProofParameters = {}, +): UseProofReturnType { + const { address, storageKeys, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getProofQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(address && storageKeys && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/usePublicClient.test-d.ts b/packages/react/src/hooks/usePublicClient.test-d.ts new file mode 100644 index 0000000000..5d259e5c4e --- /dev/null +++ b/packages/react/src/hooks/usePublicClient.test-d.ts @@ -0,0 +1,40 @@ +import { chain, config } from '@wagmi/test' +import type { Chain } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { usePublicClient } from './usePublicClient.js' + +test('default', () => { + const client = usePublicClient({ config }) + expectTypeOf(client.chain).toEqualTypeOf<(typeof config)['chains'][number]>() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('parameters: chainId', () => { + const client = usePublicClient({ + config, + chainId: chain.mainnet.id, + }) + expectTypeOf(client.chain).toEqualTypeOf() + expectTypeOf(client.chain).not.toEqualTypeOf() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('behavior: unconfigured chain', () => { + { + const client = usePublicClient({ chainId: 123456 }) + if (client) { + expectTypeOf(client.chain).toEqualTypeOf() + expectTypeOf(client.transport.type).toEqualTypeOf() + } else { + expectTypeOf(client).toEqualTypeOf() + } + } + + const client = usePublicClient({ + config, + // @ts-expect-error + chainId: 123456, + }) + expectTypeOf(client).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/usePublicClient.test.ts b/packages/react/src/hooks/usePublicClient.test.ts new file mode 100644 index 0000000000..93602746bb --- /dev/null +++ b/packages/react/src/hooks/usePublicClient.test.ts @@ -0,0 +1,30 @@ +import { switchChain } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import { Fragment, createElement } from 'react' +import { expect, test } from 'vitest' + +import { usePublicClient } from './usePublicClient.js' + +test('default', async () => { + const { result, rerender } = renderHook(() => usePublicClient()) + + expect(result.current?.chain.id).toEqual(1) + + await switchChain(config, { chainId: 456 }) + rerender() + + expect(result.current?.chain.id).toEqual(456) +}) + +test('parameters: config', () => { + const { result } = renderHook(() => usePublicClient({ config }), { + wrapper: ({ children }) => createElement(Fragment, { children }), + }) + expect(result.current).toBeDefined() +}) + +test('behavior: unconfigured chain', () => { + const { result } = renderHook(() => usePublicClient({ chainId: 123456 })) + expect(result.current).toBeUndefined() +}) diff --git a/packages/react/src/hooks/usePublicClient.ts b/packages/react/src/hooks/usePublicClient.ts new file mode 100644 index 0000000000..5193f170b6 --- /dev/null +++ b/packages/react/src/hooks/usePublicClient.ts @@ -0,0 +1,51 @@ +'use client' + +import { + type Config, + type GetPublicClientParameters, + type GetPublicClientReturnType, + type ResolvedRegister, + getPublicClient, + watchPublicClient, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { useSyncExternalStoreWithSelector } from 'use-sync-external-store/shim/with-selector.js' + +import type { ConfigParameter } from '../types/properties.js' +import { useConfig } from './useConfig.js' + +export type UsePublicClientParameters< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | number | undefined = + | config['chains'][number]['id'] + | undefined, +> = Compute< + GetPublicClientParameters & ConfigParameter +> + +export type UsePublicClientReturnType< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | number | undefined = + | config['chains'][number]['id'] + | undefined, +> = GetPublicClientReturnType + +/** https://wagmi.sh/react/api/hooks/usePublicClient */ +export function usePublicClient< + config extends Config = ResolvedRegister['config'], + chainId extends config['chains'][number]['id'] | number | undefined = + | config['chains'][number]['id'] + | undefined, +>( + parameters: UsePublicClientParameters = {}, +): UsePublicClientReturnType { + const config = useConfig(parameters) + + return useSyncExternalStoreWithSelector( + (onChange) => watchPublicClient(config, { onChange }), + () => getPublicClient(config, parameters), + () => getPublicClient(config, parameters), + (x) => x, + (a, b) => a?.uid === b?.uid, + ) as any +} diff --git a/packages/react/src/hooks/useReadContract.test-d.ts b/packages/react/src/hooks/useReadContract.test-d.ts new file mode 100644 index 0000000000..3b57d49a9e --- /dev/null +++ b/packages/react/src/hooks/useReadContract.test-d.ts @@ -0,0 +1,96 @@ +import { abi } from '@wagmi/test' +import type { Address } from 'viem' +import { assertType, expectTypeOf, test } from 'vitest' + +import { + type UseReadContractParameters, + type UseReadContractReturnType, + useReadContract, +} from './useReadContract.js' + +test('select data', () => { + const result = useReadContract({ + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + query: { + select(data) { + expectTypeOf(data).toEqualTypeOf() + return data?.toString() + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) + +test('UseReadContractParameters', () => { + type Result = UseReadContractParameters + expectTypeOf>().toEqualTypeOf<{ + functionName?: + | 'symbol' + | 'name' + | 'allowance' + | 'balanceOf' + | 'decimals' + | 'totalSupply' + | undefined + args?: readonly [Address] | undefined + }>() +}) + +test('UseReadContractReturnType', () => { + type Result = UseReadContractReturnType + expectTypeOf().toEqualTypeOf() +}) + +test('overloads', () => { + const result1 = useReadContract({ + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + }) + assertType(result1.data) + + const result2 = useReadContract({ + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: [], + }) + assertType(result2.data) + + const result3 = useReadContract({ + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x'], + }) + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + assertType(result3.data) + + const result4 = useReadContract({ + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x', '0x'], + }) + assertType< + | { + foo: `0x${string}` + bar: `0x${string}` + } + | undefined + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + >(result4.data) +}) + +test('deployless read (bytecode)', () => { + const result = useReadContract({ + code: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useReadContract.test.ts b/packages/react/src/hooks/useReadContract.test.ts new file mode 100644 index 0000000000..c94ca996ce --- /dev/null +++ b/packages/react/src/hooks/useReadContract.test.ts @@ -0,0 +1,194 @@ +import { QueryClientProvider } from '@tanstack/react-query' +import { abi, address, bytecode, chain, config, wait } from '@wagmi/test' +import { queryClient, renderHook, waitFor } from '@wagmi/test/react' +import { createElement } from 'react' +import { expect, test } from 'vitest' + +import { useReadContract } from './useReadContract.js' + +test('default', async () => { + const { result } = renderHook(() => + useReadContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": 4n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "readContract", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": [ + "0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC", + ], + "chainId": 1, + "functionName": "balanceOf", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: chainId', async () => { + const { result } = renderHook(() => + useReadContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + chainId: chain.mainnet2.id, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": 4n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "readContract", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": [ + "0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC", + ], + "chainId": 456, + "functionName": "balanceOf", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: config', async () => { + const { result } = renderHook( + () => + useReadContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + config, + }), + { + wrapper: ({ children }) => + createElement(QueryClientProvider, { client: queryClient }, children), + }, + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": 4n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "readContract", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": [ + "0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC", + ], + "chainId": 1, + "functionName": "balanceOf", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: deployless read (bytecode)', async () => { + const { result } = renderHook(() => + useReadContract({ + abi: abi.wagmiMintExample, + functionName: 'name', + code: bytecode.wagmiMintExample, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current.data).toMatchInlineSnapshot(`"wagmi"`) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useReadContract()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useReadContract.ts b/packages/react/src/hooks/useReadContract.ts new file mode 100644 index 0000000000..6eb6d6d64f --- /dev/null +++ b/packages/react/src/hooks/useReadContract.ts @@ -0,0 +1,99 @@ +'use client' + +import type { + Config, + ReadContractErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { UnionCompute } from '@wagmi/core/internal' +import { + type ReadContractData, + type ReadContractOptions, + type ReadContractQueryFnData, + type ReadContractQueryKey, + readContractQueryOptions, + structuralSharing, +} from '@wagmi/core/query' +import type { Abi, ContractFunctionArgs, ContractFunctionName, Hex } from 'viem' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseReadContractParameters< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'pure' | 'view' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'pure' | 'view', + functionName + > = ContractFunctionArgs, + config extends Config = Config, + selectData = ReadContractData, +> = UnionCompute< + ReadContractOptions & + ConfigParameter & + QueryParameter< + ReadContractQueryFnData, + ReadContractErrorType, + selectData, + ReadContractQueryKey + > +> + +export type UseReadContractReturnType< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'pure' | 'view' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'pure' | 'view', + functionName + > = ContractFunctionArgs, + selectData = ReadContractData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useReadContract */ +export function useReadContract< + const abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs, + config extends Config = ResolvedRegister['config'], + selectData = ReadContractData, +>( + parameters: UseReadContractParameters< + abi, + functionName, + args, + config, + selectData + > = {} as any, +): UseReadContractReturnType { + const { abi, address, functionName, query = {} } = parameters + // @ts-ignore + const code = parameters.code as Hex | undefined + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = readContractQueryOptions( + config, + { ...(parameters as any), chainId: parameters.chainId ?? chainId }, + ) + const enabled = Boolean( + (address || code) && abi && functionName && (query.enabled ?? true), + ) + + return useQuery({ + ...query, + ...options, + enabled, + structuralSharing: query.structuralSharing ?? structuralSharing, + }) +} diff --git a/packages/react/src/hooks/useReadContracts.test-d.ts b/packages/react/src/hooks/useReadContracts.test-d.ts new file mode 100644 index 0000000000..8aa786436a --- /dev/null +++ b/packages/react/src/hooks/useReadContracts.test-d.ts @@ -0,0 +1,93 @@ +import { abi } from '@wagmi/test' +import { assertType, expectTypeOf, test } from 'vitest' + +import { useReadContracts } from './useReadContracts.js' + +test('select data', () => { + const result = useReadContracts({ + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + chainId: 1, + args: ['0x'], + }, + { + address: '0x', + abi: abi.wagmiMintExample, + functionName: 'tokenURI', + args: [123n], + }, + ], + query: { + select(data) { + expectTypeOf(data).toEqualTypeOf<[bigint, string]>() + return data[0] + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) + +test('overloads', async () => { + const result1 = useReadContracts({ + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + }, + ], + }) + assertType<[number] | undefined>(result1.data) + + const result2 = useReadContracts({ + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: [], + }, + ], + }) + assertType<[number] | undefined>(result2.data) + + const result3 = useReadContracts({ + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x'], + }, + ], + }) + assertType<[string] | undefined>(result3.data) + + const result4 = useReadContracts({ + allowFailure: false, + contracts: [ + { + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x', '0x'], + }, + ], + }) + assertType< + | [ + { + foo: `0x${string}` + bar: `0x${string}` + }, + ] + | undefined + >(result4.data) +}) diff --git a/packages/react/src/hooks/useReadContracts.test.ts b/packages/react/src/hooks/useReadContracts.test.ts new file mode 100644 index 0000000000..e7636b254e --- /dev/null +++ b/packages/react/src/hooks/useReadContracts.test.ts @@ -0,0 +1,262 @@ +import { abi, address, chain } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useReadContracts } from './useReadContracts.js' + +test('default', async () => { + const { result } = renderHook(() => + useReadContracts({ + contracts: [ + { + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + { + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'symbol', + }, + ], + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": [ + { + "result": 4n, + "status": "success", + }, + { + "result": "WAGMI", + "status": "success", + }, + ], + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "readContracts", + { + "chainId": 1, + "contracts": [ + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": [ + "0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC", + ], + "chainId": 1, + "functionName": "balanceOf", + }, + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 1, + "functionName": "symbol", + }, + ], + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test.skip('multichain', async () => { + const { mainnet, mainnet2, optimism } = chain + const { result } = renderHook(() => + useReadContracts({ + contracts: [ + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet.id, + functionName: 'love', + args: ['0x27a69ffba1e939ddcfecc8c7e0f967b872bac65c'], + }, + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet.id, + functionName: 'love', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet.id, + functionName: 'love', + args: ['0xd2135CfB216b74109775236E36d4b433F1DF507B'], + }, + { + abi: abi.wagmigotchi, + address: address.wagmigotchi, + chainId: mainnet2.id, + functionName: 'getAlive', + }, + { + abi: abi.mloot, + address: address.mloot, + chainId: mainnet2.id, + functionName: 'tokenOfOwnerByIndex', + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', 0n], + }, + { + abi: abi.erc20, + address: address.optimism.usdc, + chainId: optimism.id, + functionName: 'symbol', + }, + { + abi: abi.erc20, + address: address.optimism.usdc, + chainId: optimism.id, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }, + ], + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": [ + { + "result": 2n, + "status": "success", + }, + { + "result": 1n, + "status": "success", + }, + { + "result": 0n, + "status": "success", + }, + { + "result": false, + "status": "success", + }, + { + "result": 370395n, + "status": "success", + }, + { + "result": "USDC", + "status": "success", + }, + { + "result": 10959340n, + "status": "success", + }, + ], + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "readContracts", + { + "chainId": 1, + "contracts": [ + { + "address": "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + "args": [ + "0x27a69ffba1e939ddcfecc8c7e0f967b872bac65c", + ], + "chainId": 1, + "functionName": "love", + }, + { + "address": "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + "args": [ + "0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC", + ], + "chainId": 1, + "functionName": "love", + }, + { + "address": "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + "args": [ + "0xd2135CfB216b74109775236E36d4b433F1DF507B", + ], + "chainId": 1, + "functionName": "love", + }, + { + "address": "0xecb504d39723b0be0e3a9aa33d646642d1051ee1", + "chainId": 456, + "functionName": "getAlive", + }, + { + "address": "0x1dfe7ca09e99d10835bf73044a23b73fc20623df", + "args": [ + "0xA0Cf798816D4b9b9866b5330EEa46a18382f251e", + 0n, + ], + "chainId": 456, + "functionName": "tokenOfOwnerByIndex", + }, + { + "address": "0x7f5c764cbc14f9669b88837ca1490cca17c31607", + "chainId": 10, + "functionName": "symbol", + }, + { + "address": "0x7f5c764cbc14f9669b88837ca1490cca17c31607", + "args": [ + "0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC", + ], + "chainId": 10, + "functionName": "balanceOf", + }, + ], + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/useReadContracts.ts b/packages/react/src/hooks/useReadContracts.ts new file mode 100644 index 0000000000..7be786c4a8 --- /dev/null +++ b/packages/react/src/hooks/useReadContracts.ts @@ -0,0 +1,91 @@ +'use client' + +import type { + Config, + ReadContractsErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type ReadContractsData, + type ReadContractsOptions, + type ReadContractsQueryFnData, + type ReadContractsQueryKey, + readContractsQueryOptions, + structuralSharing, +} from '@wagmi/core/query' +import { useMemo } from 'react' +import type { ContractFunctionParameters } from 'viem' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseReadContractsParameters< + contracts extends readonly unknown[] = readonly ContractFunctionParameters[], + allowFailure extends boolean = true, + config extends Config = Config, + selectData = ReadContractsData, +> = Compute< + ReadContractsOptions & + ConfigParameter & + QueryParameter< + ReadContractsQueryFnData, + ReadContractsErrorType, + selectData, + ReadContractsQueryKey + > +> + +export type UseReadContractsReturnType< + contracts extends readonly unknown[] = readonly ContractFunctionParameters[], + allowFailure extends boolean = true, + selectData = ReadContractsData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useReadContracts */ +export function useReadContracts< + const contracts extends readonly unknown[], + allowFailure extends boolean = true, + config extends Config = ResolvedRegister['config'], + selectData = ReadContractsData, +>( + parameters: UseReadContractsParameters< + contracts, + allowFailure, + config, + selectData + > = {}, +): UseReadContractsReturnType { + const { contracts = [], query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = readContractsQueryOptions( + config, + { ...parameters, chainId }, + ) + + const enabled = useMemo(() => { + let isContractsValid = false + for (const contract of contracts) { + const { abi, address, functionName } = + contract as ContractFunctionParameters + if (!abi || !address || !functionName) { + isContractsValid = false + break + } + isContractsValid = true + } + return Boolean(isContractsValid && (query.enabled ?? true)) + }, [contracts, query.enabled]) + + return useQuery({ + ...options, + ...query, + enabled, + structuralSharing: query.structuralSharing ?? structuralSharing, + }) +} diff --git a/packages/react/src/hooks/useReconnect.test-d.ts b/packages/react/src/hooks/useReconnect.test-d.ts new file mode 100644 index 0000000000..424159e469 --- /dev/null +++ b/packages/react/src/hooks/useReconnect.test-d.ts @@ -0,0 +1,154 @@ +import type { + Connector, + CreateConnectorFn, + ReconnectErrorType, +} from '@wagmi/core' +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import type { Address } from 'viem' +import { useReconnect } from './useReconnect.js' + +const connectors = [config.connectors[0]!] +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { context, data, error, reconnect, variables } = useReconnect({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + expectTypeOf(data).toEqualTypeOf< + { + accounts: readonly [Address, ...Address[]] + chainId: number + connector: Connector + }[] + >() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + connector: Connector + }[] + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + connector: Connector + }[] + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: readonly (CreateConnectorFn | Connector)[] | undefined + } + | undefined + >() + expectTypeOf(context).toEqualTypeOf() + + reconnect( + { connectors }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + expectTypeOf(data).toEqualTypeOf< + { + accounts: readonly [Address, ...Address[]] + chainId: number + connector: Connector + }[] + >() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + connector: Connector + }[] + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/react/src/hooks/useReconnect.test.ts b/packages/react/src/hooks/useReconnect.test.ts new file mode 100644 index 0000000000..be783b2440 --- /dev/null +++ b/packages/react/src/hooks/useReconnect.test.ts @@ -0,0 +1,83 @@ +import { mock } from '@wagmi/connectors' +import { connect, disconnect } from '@wagmi/core' +import { accounts, config } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { afterEach, expect, test } from 'vitest' + +import { useReconnect } from './useReconnect.js' + +const connector = config._internal.connectors.setup( + mock({ + accounts, + features: { reconnect: true }, + }), +) + +afterEach(async () => { + if (config.state.current) await disconnect(config) +}) + +test('default', async () => { + const { result } = renderHook(() => useReconnect()) + + expect(result.current.connectors).toBeDefined() + + result.current.reconnect() + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current.data).toStrictEqual([]) +}) + +test('parameters: connectors (Connector)', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useReconnect()) + + expect(result.current.connectors).toBeDefined() + + result.current.reconnect({ connectors: [connector] }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current.data).toMatchObject( + expect.arrayContaining([ + expect.objectContaining({ + accounts: expect.any(Array), + chainId: expect.any(Number), + }), + ]), + ) +}) + +test('parameters: connectors (CreateConnectorFn)', async () => { + const connector = mock({ + accounts, + features: { reconnect: true }, + }) + await connect(config, { connector }) + + const { result } = renderHook(() => useReconnect()) + + expect(result.current.connectors).toBeDefined() + + result.current.reconnect({ connectors: [connector] }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current.data).toMatchObject( + expect.arrayContaining([ + expect.objectContaining({ + accounts: expect.any(Array), + chainId: expect.any(Number), + }), + ]), + ) +}) + +test("behavior: doesn't reconnect if already reconnecting", async () => { + const previousStatus = config.state.status + config.setState((x) => ({ ...x, status: 'reconnecting' })) + const { result } = renderHook(() => useReconnect()) + await expect( + result.current.reconnectAsync({ connectors: [connector] }), + ).resolves.toStrictEqual([]) + config.setState((x) => ({ ...x, status: previousStatus })) +}) diff --git a/packages/react/src/hooks/useReconnect.ts b/packages/react/src/hooks/useReconnect.ts new file mode 100644 index 0000000000..23e6d365e4 --- /dev/null +++ b/packages/react/src/hooks/useReconnect.ts @@ -0,0 +1,67 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { Connector, ReconnectErrorType } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type ReconnectData, + type ReconnectMutate, + type ReconnectMutateAsync, + type ReconnectVariables, + reconnectMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseReconnectParameters = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + ReconnectData, + ReconnectErrorType, + ReconnectVariables, + context + > + | undefined + } +> + +export type UseReconnectReturnType = Compute< + UseMutationReturnType< + ReconnectData, + ReconnectErrorType, + ReconnectVariables, + context + > & { + connectors: readonly Connector[] + reconnect: ReconnectMutate + reconnectAsync: ReconnectMutateAsync + } +> + +/** https://wagmi.sh/react/api/hooks/useReconnect */ +export function useReconnect( + parameters: UseReconnectParameters = {}, +): UseReconnectReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = reconnectMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + return { + ...result, + connectors: config.connectors, + reconnect: mutate, + reconnectAsync: mutateAsync, + } +} diff --git a/packages/react/src/hooks/useSendCalls.test.ts b/packages/react/src/hooks/useSendCalls.test.ts new file mode 100644 index 0000000000..a088dcf221 --- /dev/null +++ b/packages/react/src/hooks/useSendCalls.test.ts @@ -0,0 +1,44 @@ +import { connect, disconnect } from '@wagmi/core' +import { accounts, config } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { useSendCalls } from './useSendCalls.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useSendCalls()) + + result.current.sendCalls({ + calls: [ + { + data: '0xdeadbeef', + to: accounts[1], + value: parseEther('1'), + }, + { + to: accounts[2], + value: parseEther('2'), + }, + { + to: accounts[3], + value: parseEther('3'), + }, + ], + }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current.data).toMatchInlineSnapshot( + ` + { + "id": "0x5dedb5a4ff8968db37459b52b83cbdc92b01c9c709c9cff26e345ef5cf27f92e", + } + `, + ) + + await disconnect(config, { connector }) +}) diff --git a/packages/react/src/hooks/useSendCalls.ts b/packages/react/src/hooks/useSendCalls.ts new file mode 100644 index 0000000000..49366cb218 --- /dev/null +++ b/packages/react/src/hooks/useSendCalls.ts @@ -0,0 +1,75 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { Config, ResolvedRegister, SendCallsErrorType } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type SendCallsData, + type SendCallsMutate, + type SendCallsMutateAsync, + type SendCallsVariables, + sendCallsMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseSendCallsParameters< + config extends Config = Config, + context = unknown, +> = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + SendCallsData, + SendCallsErrorType, + SendCallsVariables, + context + > + | undefined + } +> + +export type UseSendCallsReturnType< + config extends Config = Config, + context = unknown, +> = Compute< + UseMutationReturnType< + SendCallsData, + SendCallsErrorType, + SendCallsVariables, + context + > & { + sendCalls: SendCallsMutate + sendCallsAsync: SendCallsMutateAsync + } +> + +/** https://wagmi.sh/react/api/hooks/useSendCalls */ +export function useSendCalls< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseSendCallsParameters = {}, +): UseSendCallsReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = sendCallsMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + type Return = UseSendCallsReturnType + return { + ...result, + sendCalls: mutate as Return['sendCalls'], + sendCallsAsync: mutateAsync as Return['sendCallsAsync'], + } +} diff --git a/packages/react/src/hooks/useSendTransaction.test-d.ts b/packages/react/src/hooks/useSendTransaction.test-d.ts new file mode 100644 index 0000000000..170c1e61e3 --- /dev/null +++ b/packages/react/src/hooks/useSendTransaction.test-d.ts @@ -0,0 +1,78 @@ +import type { SendTransactionErrorType } from '@wagmi/core' +import type { Hash } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { useSendTransaction } from './useSendTransaction.js' + +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { context, data, error, sendTransaction, variables } = + useSendTransaction({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toMatchTypeOf< + { chainId?: number | undefined } | undefined + >() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + }>() + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf< + { chainId?: number | undefined } | undefined + >() + expectTypeOf(context).toEqualTypeOf() + + sendTransaction( + { to: '0x' }, + { + onError(error, variables, context) { + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + }>() + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/react/src/hooks/useSendTransaction.test.ts b/packages/react/src/hooks/useSendTransaction.test.ts new file mode 100644 index 0000000000..a2e8977e2f --- /dev/null +++ b/packages/react/src/hooks/useSendTransaction.test.ts @@ -0,0 +1,25 @@ +import { connect, disconnect } from '@wagmi/core' +import { config, transactionHashRegex } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { useSendTransaction } from './useSendTransaction.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useSendTransaction()) + + result.current.sendTransaction({ + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current.data).toMatch(transactionHashRegex) + + await disconnect(config, { connector }) +}) diff --git a/packages/react/src/hooks/useSendTransaction.ts b/packages/react/src/hooks/useSendTransaction.ts new file mode 100644 index 0000000000..8f57b1509c --- /dev/null +++ b/packages/react/src/hooks/useSendTransaction.ts @@ -0,0 +1,79 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { + Config, + ResolvedRegister, + SendTransactionErrorType, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type SendTransactionData, + type SendTransactionMutate, + type SendTransactionMutateAsync, + type SendTransactionVariables, + sendTransactionMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseSendTransactionParameters< + config extends Config = Config, + context = unknown, +> = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + SendTransactionData, + SendTransactionErrorType, + SendTransactionVariables, + context + > + | undefined + } +> + +export type UseSendTransactionReturnType< + config extends Config = Config, + context = unknown, +> = Compute< + UseMutationReturnType< + SendTransactionData, + SendTransactionErrorType, + SendTransactionVariables, + context + > & { + sendTransaction: SendTransactionMutate + sendTransactionAsync: SendTransactionMutateAsync + } +> + +/** https://wagmi.sh/react/api/hooks/useSendTransaction */ +export function useSendTransaction< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseSendTransactionParameters = {}, +): UseSendTransactionReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = sendTransactionMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + type Return = UseSendTransactionReturnType + return { + ...result, + sendTransaction: mutate as Return['sendTransaction'], + sendTransactionAsync: mutateAsync as Return['sendTransactionAsync'], + } +} diff --git a/packages/react/src/hooks/useShowCallsStatus.ts b/packages/react/src/hooks/useShowCallsStatus.ts new file mode 100644 index 0000000000..82a4dd3909 --- /dev/null +++ b/packages/react/src/hooks/useShowCallsStatus.ts @@ -0,0 +1,76 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { + Config, + ResolvedRegister, + ShowCallsStatusErrorType, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type ShowCallsStatusData, + type ShowCallsStatusMutate, + type ShowCallsStatusMutateAsync, + type ShowCallsStatusVariables, + showCallsStatusMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseShowCallsStatusParameters< + config extends Config = Config, + context = unknown, +> = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + ShowCallsStatusData, + ShowCallsStatusErrorType, + ShowCallsStatusVariables, + context + > + | undefined + } +> + +export type UseShowCallsStatusReturnType = Compute< + UseMutationReturnType< + ShowCallsStatusData, + ShowCallsStatusErrorType, + ShowCallsStatusVariables, + context + > & { + showCallsStatus: ShowCallsStatusMutate + showCallsStatusAsync: ShowCallsStatusMutateAsync + } +> + +/** https://wagmi.sh/react/api/hooks/useShowCallsStatus */ +export function useShowCallsStatus< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseShowCallsStatusParameters = {}, +): UseShowCallsStatusReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = showCallsStatusMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + type Return = UseShowCallsStatusReturnType + return { + ...result, + showCallsStatus: mutate as Return['showCallsStatus'], + showCallsStatusAsync: mutateAsync as Return['showCallsStatusAsync'], + } +} diff --git a/packages/react/src/hooks/useSignMessage.test-d.ts b/packages/react/src/hooks/useSignMessage.test-d.ts new file mode 100644 index 0000000000..706c4a51fe --- /dev/null +++ b/packages/react/src/hooks/useSignMessage.test-d.ts @@ -0,0 +1,62 @@ +import type { SignMessageErrorType } from '@wagmi/core' +import type { SignMessageVariables } from '@wagmi/core/query' +import { expectTypeOf, test } from 'vitest' + +import { useSignMessage } from './useSignMessage.js' + +const message = 'hello world' +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { context, data, error, signMessage, variables } = useSignMessage({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(data).toEqualTypeOf<`0x${string}`>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf<`0x${string}` | undefined>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data).toEqualTypeOf<`0x${string}` | undefined>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + signMessage( + { message }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(data).toEqualTypeOf<`0x${string}`>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf<`0x${string}` | undefined>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/react/src/hooks/useSignMessage.test.ts b/packages/react/src/hooks/useSignMessage.test.ts new file mode 100644 index 0000000000..aa6dd4a184 --- /dev/null +++ b/packages/react/src/hooks/useSignMessage.test.ts @@ -0,0 +1,43 @@ +import { connect, disconnect, getAccount } from '@wagmi/core' +import { config, privateKey } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { recoverMessageAddress } from 'viem' +import { expect, test } from 'vitest' + +import { privateKeyToAccount } from 'viem/accounts' +import { useSignMessage } from './useSignMessage.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useSignMessage()) + + result.current.signMessage({ message: 'foo bar baz' }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + await expect( + recoverMessageAddress({ + message: 'foo bar baz', + signature: result.current.data!, + }), + ).resolves.toEqual(getAccount(config).address) + + await disconnect(config, { connector }) +}) + +test('behavior: local account', async () => { + const { result } = renderHook(() => useSignMessage()) + + const account = privateKeyToAccount(privateKey) + result.current.signMessage({ account, message: 'foo bar baz' }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + await expect( + recoverMessageAddress({ + message: 'foo bar baz', + signature: result.current.data!, + }), + ).resolves.toEqual(account.address) +}) diff --git a/packages/react/src/hooks/useSignMessage.ts b/packages/react/src/hooks/useSignMessage.ts new file mode 100644 index 0000000000..0bea4bb65f --- /dev/null +++ b/packages/react/src/hooks/useSignMessage.ts @@ -0,0 +1,65 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { SignMessageErrorType } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type SignMessageData, + type SignMessageMutate, + type SignMessageMutateAsync, + type SignMessageVariables, + signMessageMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseSignMessageParameters = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + SignMessageData, + SignMessageErrorType, + SignMessageVariables, + context + > + | undefined + } +> + +export type UseSignMessageReturnType = Compute< + UseMutationReturnType< + SignMessageData, + SignMessageErrorType, + SignMessageVariables, + context + > & { + signMessage: SignMessageMutate + signMessageAsync: SignMessageMutateAsync + } +> + +/** https://wagmi.sh/react/api/hooks/useSignMessage */ +export function useSignMessage( + parameters: UseSignMessageParameters = {}, +): UseSignMessageReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = signMessageMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + return { + ...result, + signMessage: mutate, + signMessageAsync: mutateAsync, + } +} diff --git a/packages/react/src/hooks/useSignTypedData.test-d.ts b/packages/react/src/hooks/useSignTypedData.test-d.ts new file mode 100644 index 0000000000..a51f77cfbb --- /dev/null +++ b/packages/react/src/hooks/useSignTypedData.test-d.ts @@ -0,0 +1,93 @@ +import type { + SignTypedDataErrorType, + SignTypedDataReturnType, +} from '@wagmi/core' +import type { SignTypedDataVariables } from '@wagmi/core/query' +import { typedData } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useSignTypedData } from './useSignTypedData.js' + +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { context, data, error, signTypedData, variables } = useSignTypedData({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toMatchTypeOf() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toMatchTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toMatchTypeOf() + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf() + expectTypeOf(context).toEqualTypeOf() + + signTypedData( + { + types: typedData.basic.types, + primaryType: 'Person', + message: { + name: 'Bob', + wallet: '0x', + }, + }, + { + onError(error, variables, context) { + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf<{ + types: typeof typedData.basic.types + primaryType: 'Person' + message: { + name: string + wallet: `0x${string}` + } + }>() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf<{ + types: typeof typedData.basic.types + primaryType: 'Person' + message: { + name: string + wallet: `0x${string}` + } + }>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf<{ + types: typeof typedData.basic.types + primaryType: 'Person' + message: { + name: string + wallet: `0x${string}` + } + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/react/src/hooks/useSignTypedData.test.ts b/packages/react/src/hooks/useSignTypedData.test.ts new file mode 100644 index 0000000000..3a38daa0da --- /dev/null +++ b/packages/react/src/hooks/useSignTypedData.test.ts @@ -0,0 +1,56 @@ +import { connect, disconnect, getAccount } from '@wagmi/core' +import { config, privateKey, typedData } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { recoverTypedDataAddress } from 'viem' +import { expect, test } from 'vitest' + +import { privateKeyToAccount } from 'viem/accounts' +import { useSignTypedData } from './useSignTypedData.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useSignTypedData()) + + result.current.signTypedData({ + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + await expect( + recoverTypedDataAddress({ + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + signature: result.current.data!, + }), + ).resolves.toEqual(getAccount(config).address) + + await disconnect(config, { connector }) +}) + +test('behavior: local account', async () => { + const { result } = renderHook(() => useSignTypedData()) + + const account = privateKeyToAccount(privateKey) + result.current.signTypedData({ + account, + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + await expect( + recoverTypedDataAddress({ + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + signature: result.current.data!, + }), + ).resolves.toEqual(account.address) +}) diff --git a/packages/react/src/hooks/useSignTypedData.ts b/packages/react/src/hooks/useSignTypedData.ts new file mode 100644 index 0000000000..080cd04405 --- /dev/null +++ b/packages/react/src/hooks/useSignTypedData.ts @@ -0,0 +1,66 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { SignTypedDataErrorType } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type SignTypedDataData, + type SignTypedDataMutate, + type SignTypedDataMutateAsync, + type SignTypedDataVariables, + signTypedDataMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseSignTypedDataParameters = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + SignTypedDataData, + SignTypedDataErrorType, + SignTypedDataVariables, + context + > + | undefined + } +> + +export type UseSignTypedDataReturnType = Compute< + UseMutationReturnType< + SignTypedDataData, + SignTypedDataErrorType, + SignTypedDataVariables, + context + > & { + signTypedData: SignTypedDataMutate + signTypedDataAsync: SignTypedDataMutateAsync + } +> + +/** https://wagmi.sh/react/api/hooks/useSignTypedData */ +export function useSignTypedData( + parameters: UseSignTypedDataParameters = {}, +): UseSignTypedDataReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = signTypedDataMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + type Return = UseSignTypedDataReturnType + return { + ...result, + signTypedData: mutate as Return['signTypedData'], + signTypedDataAsync: mutateAsync as Return['signTypedDataAsync'], + } +} diff --git a/packages/react/src/hooks/useSimulateContract.test-d.ts b/packages/react/src/hooks/useSimulateContract.test-d.ts new file mode 100644 index 0000000000..8159cdfccf --- /dev/null +++ b/packages/react/src/hooks/useSimulateContract.test-d.ts @@ -0,0 +1,104 @@ +import { abi, type config } from '@wagmi/test' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { + type UseSimulateContractParameters, + type UseSimulateContractReturnType, + useSimulateContract, +} from './useSimulateContract.js' + +test('default', () => { + const result = useSimulateContract({ + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + }) + + expectTypeOf(result.data).toMatchTypeOf< + | { + result: boolean + request: { + chainId?: undefined + abi: readonly [ + { + readonly name: 'transferFrom' + readonly type: 'function' + readonly stateMutability: 'nonpayable' + readonly inputs: readonly [ + { readonly type: 'address'; readonly name: 'sender' }, + { readonly type: 'address'; readonly name: 'recipient' }, + { readonly type: 'uint256'; readonly name: 'amount' }, + ] + readonly outputs: readonly [{ type: 'bool' }] + }, + ] + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + } + } + | undefined + >() +}) + +test('select data', () => { + const result = useSimulateContract({ + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 1, + query: { + select(data) { + expectTypeOf(data.result).toEqualTypeOf() + return data.request.args + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf< + readonly [Address, Address, bigint] | undefined + >() +}) + +test('UseSimulateContractParameters', () => { + type Result = UseSimulateContractParameters + expectTypeOf().toMatchTypeOf<{ + functionName?: 'approve' | 'transfer' | 'transferFrom' | undefined + args?: readonly [Address, Address, bigint] | undefined + }>() +}) + +test('UseSimulateContractReturnType', () => { + type Result = UseSimulateContractReturnType< + typeof abi.erc20, + 'transferFrom', + ['0x', '0x', 123n], + typeof config, + 1 + > + expectTypeOf().toMatchTypeOf< + | { + result: boolean + request: { + chainId: number + abi: readonly [ + { + readonly name: 'transferFrom' + readonly type: 'function' + readonly stateMutability: 'nonpayable' + readonly inputs: readonly [ + { readonly type: 'address'; readonly name: 'sender' }, + { readonly type: 'address'; readonly name: 'recipient' }, + { readonly type: 'uint256'; readonly name: 'amount' }, + ] + readonly outputs: readonly [{ type: 'bool' }] + }, + ] + functionName: 'approve' | 'transfer' | 'transferFrom' + args: readonly [Address, Address, bigint] + } + } + | undefined + >() +}) diff --git a/packages/react/src/hooks/useSimulateContract.test.ts b/packages/react/src/hooks/useSimulateContract.test.ts new file mode 100644 index 0000000000..3c785133c9 --- /dev/null +++ b/packages/react/src/hooks/useSimulateContract.test.ts @@ -0,0 +1,95 @@ +import { connect, disconnect } from '@wagmi/core' +import { abi, address, config, wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useSimulateContract } from './useSimulateContract.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => + useSimulateContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'mint', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "chainId": 1, + "request": { + "abi": [ + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": undefined, + "chainId": 1, + "dataSuffix": undefined, + "functionName": "mint", + }, + "result": undefined, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "simulateContract", + { + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 1, + "functionName": "mint", + }, + ], + "refetch": [Function], + "status": "success", + } + `) + + await disconnect(config, { connector }) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useSimulateContract()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useSimulateContract.ts b/packages/react/src/hooks/useSimulateContract.ts new file mode 100644 index 0000000000..e17913fb4f --- /dev/null +++ b/packages/react/src/hooks/useSimulateContract.ts @@ -0,0 +1,117 @@ +'use client' + +import type { + Config, + ResolvedRegister, + SimulateContractErrorType, +} from '@wagmi/core' +import { + type SimulateContractData, + type SimulateContractOptions, + type SimulateContractQueryFnData, + type SimulateContractQueryKey, + simulateContractQueryOptions, +} from '@wagmi/core/query' +import type { Abi, ContractFunctionArgs, ContractFunctionName } from 'viem' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' +import { useConnectorClient } from './useConnectorClient.js' + +export type UseSimulateContractParameters< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'nonpayable' | 'payable' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + > = ContractFunctionArgs, + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = SimulateContractData, +> = SimulateContractOptions & + ConfigParameter & + QueryParameter< + SimulateContractQueryFnData, + SimulateContractErrorType, + selectData, + SimulateContractQueryKey + > + +export type UseSimulateContractReturnType< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'nonpayable' | 'payable' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + > = ContractFunctionArgs, + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = SimulateContractData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useSimulateContract */ +export function useSimulateContract< + const abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + config extends Config = ResolvedRegister['config'], + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = SimulateContractData, +>( + parameters: UseSimulateContractParameters< + abi, + functionName, + args, + config, + chainId, + selectData + > = {} as any, +): UseSimulateContractReturnType< + abi, + functionName, + args, + config, + chainId, + selectData +> { + const { abi, address, connector, functionName, query = {} } = parameters + + const config = useConfig(parameters) + const { data: connectorClient } = useConnectorClient({ + config, + connector, + query: { enabled: parameters.account === undefined }, + }) + const chainId = useChainId({ config }) + + const options = simulateContractQueryOptions< + config, + abi, + functionName, + args, + chainId + >(config, { + ...parameters, + account: parameters.account ?? connectorClient?.account, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean( + abi && address && functionName && (query.enabled ?? true), + ) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useStorageAt.test-d.ts b/packages/react/src/hooks/useStorageAt.test-d.ts new file mode 100644 index 0000000000..bbc37fa03d --- /dev/null +++ b/packages/react/src/hooks/useStorageAt.test-d.ts @@ -0,0 +1,15 @@ +import { expectTypeOf, test } from 'vitest' + +import type { Hex } from 'viem' +import { useStorageAt } from './useStorageAt.js' + +test('select data', () => { + const result = useStorageAt({ + query: { + select(data) { + return data + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useStorageAt.test.ts b/packages/react/src/hooks/useStorageAt.test.ts new file mode 100644 index 0000000000..9386480c93 --- /dev/null +++ b/packages/react/src/hooks/useStorageAt.test.ts @@ -0,0 +1,299 @@ +import { address, chain, wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import type { Address } from 'viem' +import { useStorageAt } from './useStorageAt.js' + +test('default', async () => { + const { result } = renderHook(() => + useStorageAt({ + address: address.wagmiMintExample, + slot: '0x0', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": "0x7761676d6900000000000000000000000000000000000000000000000000000a", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getStorageAt", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 1, + "slot": "0x0", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: blockNumber', async () => { + const { result } = renderHook(() => + useStorageAt({ + address: address.wagmiMintExample, + blockNumber: 16280770n, + slot: '0x0', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": "0x7761676d6900000000000000000000000000000000000000000000000000000a", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getStorageAt", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "blockNumber": 16280770n, + "chainId": 1, + "slot": "0x0", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: blockTag', async () => { + const { result } = renderHook(() => + useStorageAt({ + address: address.wagmiMintExample, + blockTag: 'safe', + slot: '0x0', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": "0x7761676d6900000000000000000000000000000000000000000000000000000a", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getStorageAt", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "blockTag": "safe", + "chainId": 1, + "slot": "0x0", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: chainId', async () => { + const { result } = renderHook(() => + useStorageAt({ + address: address.wagmiMintExample, + chainId: chain.optimism.id, + slot: '0x0', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getStorageAt", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 10, + "slot": "0x0", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: address: undefined -> defined', async () => { + let contractAddress: Address | undefined = undefined + + const { result, rerender } = renderHook(() => + useStorageAt({ + address: contractAddress, + slot: '0x0', + }), + ) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "getStorageAt", + { + "address": undefined, + "chainId": 1, + "slot": "0x0", + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + + contractAddress = address.wagmiMintExample + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + expect(result.current).toMatchInlineSnapshot(` + { + "data": "0x7761676d6900000000000000000000000000000000000000000000000000000a", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getStorageAt", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 1, + "slot": "0x0", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useStorageAt()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useStorageAt.ts b/packages/react/src/hooks/useStorageAt.ts new file mode 100644 index 0000000000..3a58376fd4 --- /dev/null +++ b/packages/react/src/hooks/useStorageAt.ts @@ -0,0 +1,57 @@ +'use client' + +import type { + Config, + GetStorageAtErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetStorageAtData, + type GetStorageAtOptions, + type GetStorageAtQueryKey, + getStorageAtQueryOptions, +} from '@wagmi/core/query' +import type { GetStorageAtQueryFnData } from '@wagmi/core/query' +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseStorageAtParameters< + config extends Config = Config, + selectData = GetStorageAtData, +> = Compute< + GetStorageAtOptions & + ConfigParameter & + QueryParameter< + GetStorageAtQueryFnData, + GetStorageAtErrorType, + selectData, + GetStorageAtQueryKey + > +> + +export type UseStorageAtReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useStorageAt */ +export function useStorageAt< + config extends Config = ResolvedRegister['config'], + selectData = GetStorageAtData, +>( + parameters: UseStorageAtParameters = {}, +): UseStorageAtReturnType { + const { address, slot, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getStorageAtQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(address && slot && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useSwitchAccount.test-d.ts b/packages/react/src/hooks/useSwitchAccount.test-d.ts new file mode 100644 index 0000000000..f7d97355a3 --- /dev/null +++ b/packages/react/src/hooks/useSwitchAccount.test-d.ts @@ -0,0 +1,87 @@ +import type { Connector, SwitchAccountErrorType } from '@wagmi/core' +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import type { Address } from 'viem' +import { useSwitchAccount } from './useSwitchAccount.js' + +const connector = config.connectors[0]! +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { context, data, error, switchAccount, variables } = useSwitchAccount({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + expectTypeOf(data).toEqualTypeOf<{ + accounts: readonly [Address, ...Address[]] + chainId: number + }>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector } | undefined>() + expectTypeOf(context).toEqualTypeOf() + + switchAccount( + { connector }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + expectTypeOf(data).toEqualTypeOf<{ + accounts: readonly [Address, ...Address[]] + chainId: number + }>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/react/src/hooks/useSwitchAccount.test.ts b/packages/react/src/hooks/useSwitchAccount.test.ts new file mode 100644 index 0000000000..5461d08213 --- /dev/null +++ b/packages/react/src/hooks/useSwitchAccount.test.ts @@ -0,0 +1,44 @@ +import { connect, disconnect } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useAccount } from './useAccount.js' +import { useSwitchAccount } from './useSwitchAccount.js' + +const connector1 = config.connectors[0]! +const connector2 = config.connectors[1]! + +test('default', async () => { + await connect(config, { connector: connector2 }) + await connect(config, { connector: connector1 }) + + const { result } = renderHook(() => ({ + useAccount: useAccount(), + useSwitchAccount: useSwitchAccount(), + })) + + const address1 = result.current.useAccount.address + expect(address1).toBeDefined() + + result.current.useSwitchAccount.switchAccount({ connector: connector2 }) + await waitFor(() => + expect(result.current.useSwitchAccount.isSuccess).toBeTruthy(), + ) + + const address2 = result.current.useAccount.address + expect(address2).toBeDefined() + expect(address1).not.toBe(address2) + + result.current.useSwitchAccount.switchAccount({ connector: connector1 }) + await waitFor(() => + expect(result.current.useSwitchAccount.isSuccess).toBeTruthy(), + ) + + const address3 = result.current.useAccount.address + expect(address3).toBeDefined() + expect(address1).toBe(address3) + + await disconnect(config, { connector: connector1 }) + await disconnect(config, { connector: connector2 }) +}) diff --git a/packages/react/src/hooks/useSwitchAccount.ts b/packages/react/src/hooks/useSwitchAccount.ts new file mode 100644 index 0000000000..e9dc305545 --- /dev/null +++ b/packages/react/src/hooks/useSwitchAccount.ts @@ -0,0 +1,84 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { + Config, + Connector, + ResolvedRegister, + SwitchAccountErrorType, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type SwitchAccountData, + type SwitchAccountMutate, + type SwitchAccountMutateAsync, + type SwitchAccountVariables, + switchAccountMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' +import { useConnections } from './useConnections.js' + +export type UseSwitchAccountParameters< + config extends Config = Config, + context = unknown, +> = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + SwitchAccountData, + SwitchAccountErrorType, + SwitchAccountVariables, + context + > + | undefined + } +> + +export type UseSwitchAccountReturnType< + config extends Config = Config, + context = unknown, +> = Compute< + UseMutationReturnType< + SwitchAccountData, + SwitchAccountErrorType, + SwitchAccountVariables, + context + > & { + connectors: readonly Connector[] + switchAccount: SwitchAccountMutate + switchAccountAsync: SwitchAccountMutateAsync + } +> + +/** https://wagmi.sh/react/api/hooks/useSwitchAccount */ +export function useSwitchAccount< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseSwitchAccountParameters = {}, +): UseSwitchAccountReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = switchAccountMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + return { + ...result, + connectors: useConnections({ config }).map( + (connection) => connection.connector, + ), + switchAccount: mutate, + switchAccountAsync: mutateAsync, + } +} diff --git a/packages/react/src/hooks/useSwitchChain.test-d.ts b/packages/react/src/hooks/useSwitchChain.test-d.ts new file mode 100644 index 0000000000..07098c7724 --- /dev/null +++ b/packages/react/src/hooks/useSwitchChain.test-d.ts @@ -0,0 +1,118 @@ +import type { Connector, SwitchChainErrorType } from '@wagmi/core' +import type { Chain } from '@wagmi/core/chains' +import type { Compute, ExactPartial } from '@wagmi/core/internal' +import { chain } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import type { AddEthereumChainParameter } from 'viem' +import { useSwitchChain } from './useSwitchChain.js' + +const chainId = chain.mainnet.id +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { chains, context, data, error, switchChain, variables } = + useSwitchChain({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + expectTypeOf(data).toEqualTypeOf>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf | undefined>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(chains).toEqualTypeOf() + expectTypeOf(data).toEqualTypeOf | undefined>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf< + | { + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + } + | undefined + >() + expectTypeOf(context).toEqualTypeOf() + + switchChain( + { chainId }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + expectTypeOf(data).toEqualTypeOf>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf | undefined>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/react/src/hooks/useSwitchChain.test.ts b/packages/react/src/hooks/useSwitchChain.test.ts new file mode 100644 index 0000000000..1fe0ca46b2 --- /dev/null +++ b/packages/react/src/hooks/useSwitchChain.test.ts @@ -0,0 +1,114 @@ +import { connect, disconnect } from '@wagmi/core' +import { chain, config } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useAccount } from './useAccount.js' +import { useSwitchChain } from './useSwitchChain.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => ({ + useAccount: useAccount(), + useSwitchChain: useSwitchChain(), + })) + + const chainId1 = result.current.useAccount.chainId + expect(chainId1).toBeDefined() + + result.current.useSwitchChain.switchChain({ chainId: chain.mainnet2.id }) + await waitFor(() => + expect(result.current.useSwitchChain.isSuccess).toBeTruthy(), + ) + + const chainId2 = result.current.useAccount.chainId + expect(chainId2).toBeDefined() + expect(chainId1).not.toBe(chainId2) + + result.current.useSwitchChain.switchChain({ chainId: chain.mainnet.id }) + await waitFor(() => + expect(result.current.useSwitchChain.isSuccess).toBeTruthy(), + ) + + const chainId3 = result.current.useAccount.chainId + expect(chainId3).toBeDefined() + expect(chainId1).toBe(chainId3) + + await disconnect(config, { connector }) +}) + +test('behavior: chains updates', () => { + const { result, rerender } = renderHook(() => useSwitchChain()) + + const chains = result.current.chains + expect( + result.current.chains.map(({ id, name }) => ({ + id, + name, + })), + ).toMatchInlineSnapshot(` + [ + { + "id": 1, + "name": "Ethereum", + }, + { + "id": 456, + "name": "Ethereum", + }, + { + "id": 10, + "name": "OP Mainnet", + }, + ] + `) + + config._internal.chains.setState([chain.mainnet, chain.mainnet2]) + rerender() + + expect( + result.current.chains.map(({ id, name }) => ({ + id, + name, + })), + ).toMatchInlineSnapshot(` + [ + { + "id": 1, + "name": "Ethereum", + }, + { + "id": 456, + "name": "Ethereum", + }, + ] + `) + + config._internal.chains.setState(chains) + rerender() + + expect( + result.current.chains.map(({ id, name }) => ({ + id, + name, + })), + ).toMatchInlineSnapshot(` + [ + { + "id": 1, + "name": "Ethereum", + }, + { + "id": 456, + "name": "Ethereum", + }, + { + "id": 10, + "name": "OP Mainnet", + }, + ] + `) +}) diff --git a/packages/react/src/hooks/useSwitchChain.ts b/packages/react/src/hooks/useSwitchChain.ts new file mode 100644 index 0000000000..97ecf4ce9e --- /dev/null +++ b/packages/react/src/hooks/useSwitchChain.ts @@ -0,0 +1,82 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { + Config, + ResolvedRegister, + SwitchChainErrorType, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type SwitchChainData, + type SwitchChainMutate, + type SwitchChainMutateAsync, + type SwitchChainVariables, + switchChainMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useChains } from './useChains.js' +import { useConfig } from './useConfig.js' + +export type UseSwitchChainParameters< + config extends Config = Config, + context = unknown, +> = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + SwitchChainData, + SwitchChainErrorType, + SwitchChainVariables, + context + > + | undefined + } +> + +export type UseSwitchChainReturnType< + config extends Config = Config, + context = unknown, +> = Compute< + UseMutationReturnType< + SwitchChainData, + SwitchChainErrorType, + SwitchChainVariables, + context + > & { + chains: config['chains'] + switchChain: SwitchChainMutate + switchChainAsync: SwitchChainMutateAsync + } +> + +/** https://wagmi.sh/react/api/hooks/useSwitchChain */ +export function useSwitchChain< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseSwitchChainParameters = {}, +): UseSwitchChainReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = switchChainMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + type Return = UseSwitchChainReturnType + return { + ...result, + chains: useChains({ config }) as unknown as config['chains'], + switchChain: mutate as Return['switchChain'], + switchChainAsync: mutateAsync as Return['switchChainAsync'], + } +} diff --git a/packages/react/src/hooks/useSyncExternalStoreWithTracked.test.tsx b/packages/react/src/hooks/useSyncExternalStoreWithTracked.test.tsx new file mode 100644 index 0000000000..e0b1e71a94 --- /dev/null +++ b/packages/react/src/hooks/useSyncExternalStoreWithTracked.test.tsx @@ -0,0 +1,275 @@ +import { fireEvent, screen } from '@testing-library/react' +import { act, cleanup, render, renderHook } from '@wagmi/test/react' +import React from 'react' +import * as ReactDOM from 'react-dom' +import { afterEach, expect, test } from 'vitest' + +import { useSyncExternalStoreWithTracked } from './useSyncExternalStoreWithTracked.js' + +function createExternalStore(initialState: state) { + const listeners = new Set<() => void>() + let currentState = initialState + return { + set(updater: (state: state) => state) { + currentState = updater(currentState) + ReactDOM.unstable_batchedUpdates(() => { + for (const listener of listeners) { + listener() + } + }) + }, + subscribe(listener: () => void) { + listeners.add(listener) + return () => listeners.delete(listener) + }, + getState() { + return currentState + }, + } +} + +function useExternalStore( + store: ReturnType, + cb: (state: any) => void, +) { + const state = useSyncExternalStoreWithTracked( + store.subscribe, + store.getState, + store.getState, + ) + cb(state) + return state as any +} + +afterEach(() => { + cleanup() +}) + +test('rerenders only when the tracked value changes', async () => { + const externalStore = createExternalStore({ + foo: 'bar', + gm: 'wagmi', + isGonnaMakeIt: false, + }) + + const renders: any[] = [] + + renderHook(() => { + const { gm } = useExternalStore(externalStore, (state) => { + renders.push(state) + }) + + return gm + }) + + act(() => { + externalStore.set((x) => ({ ...x, foo: 'baz', isGonnaMakeIt: true })) + }) + + expect(renders).toMatchInlineSnapshot(` + [ + { + "foo": "bar", + "gm": "wagmi", + "isGonnaMakeIt": false, + }, + ] + `) + + act(() => { + externalStore.set((x) => ({ ...x, gm: 'ngmi' })) + }) + + expect(renders).toMatchInlineSnapshot(` + [ + { + "foo": "bar", + "gm": "wagmi", + "isGonnaMakeIt": false, + }, + { + "foo": "baz", + "gm": "ngmi", + "isGonnaMakeIt": true, + }, + ] + `) +}) + +test('rerenders when all values are being tracked', async () => { + const externalStore = createExternalStore({ + foo: 'bar', + gm: 'wagmi', + isGonnaMakeIt: false, + }) + + const renders: any[] = [] + + renderHook(() => { + const { foo, gm, isGonnaMakeIt } = useExternalStore( + externalStore, + (state) => { + renders.push(state) + }, + ) + + return { + foo, + gm, + isGonnaMakeIt, + } + }) + + act(() => { + externalStore.set((x) => ({ ...x, isGonnaMakeIt: true })) + }) + + expect(renders).toMatchInlineSnapshot(` + [ + { + "foo": "bar", + "gm": "wagmi", + "isGonnaMakeIt": false, + }, + { + "foo": "bar", + "gm": "wagmi", + "isGonnaMakeIt": true, + }, + ] + `) +}) + +test('rerenders when no values are being tracked', async () => { + const externalStore = createExternalStore({ + foo: 'bar', + gm: 'wagmi', + isGonnaMakeIt: false, + }) + + const renders: any[] = [] + + renderHook(() => { + useExternalStore(externalStore, (state) => { + renders.push(state) + }) + }) + + act(() => { + externalStore.set((x) => ({ ...x, isGonnaMakeIt: true })) + }) + + expect(renders).toMatchInlineSnapshot(` + [ + { + "foo": "bar", + "gm": "wagmi", + "isGonnaMakeIt": false, + }, + { + "foo": "bar", + "gm": "wagmi", + "isGonnaMakeIt": true, + }, + ] + `) +}) + +test('store object reference is stable across rerenders', async () => { + const externalStore = createExternalStore({ + foo: 'bar', + gm: 'wagmi', + isGonnaMakeIt: false, + }) + + let childRenderCount = 0 + const MemoComponent = React.memo((props: { store: any }) => { + childRenderCount++ + return
{props.store.isGonnaMakeIt}
+ }) + + const renders: any[] = [] + + function Test() { + const store = useExternalStore(externalStore, (state) => { + renders.push(state) + }) + const [, rerender] = React.useState(0) + + return ( + <> + + + + ) + } + + render() + + const forceRerenderBtn = screen.getByRole('button') + expect(childRenderCount).toBe(1) + expect(renders.length).toBe(1) + + // updating parent state, child should not rerender + fireEvent.click(forceRerenderBtn) + expect(childRenderCount).toBe(1) + expect(renders.length).toBe(2) + + // child and parent both rerender when store changes + act(() => { + externalStore.set((x) => ({ ...x, isGonnaMakeIt: true })) + }) + expect(childRenderCount).toBe(2) + expect(renders.length).toBe(3) +}) + +test('array', async () => { + const externalStore = createExternalStore(['foo']) + + const renders: any[] = [] + + renderHook(() => { + const array = useExternalStore(externalStore, (state) => { + renders.push(state) + }) + + return array + }) + + act(() => { + externalStore.set((x) => [...x, 'bar']) + }) + + expect(renders).toMatchInlineSnapshot(` + [ + [ + "foo", + ], + [ + "foo", + "bar", + ], + ] + `) + + act(() => { + externalStore.set((x) => [...x, 'baz']) + }) + + expect(renders).toMatchInlineSnapshot(` + [ + [ + "foo", + ], + [ + "foo", + "bar", + ], + [ + "foo", + "bar", + "baz", + ], + ] + `) +}) diff --git a/packages/react/src/hooks/useSyncExternalStoreWithTracked.ts b/packages/react/src/hooks/useSyncExternalStoreWithTracked.ts new file mode 100644 index 0000000000..4e372a556d --- /dev/null +++ b/packages/react/src/hooks/useSyncExternalStoreWithTracked.ts @@ -0,0 +1,67 @@ +'use client' + +import { deepEqual } from '@wagmi/core/internal' +import { useMemo, useRef } from 'react' +import { useSyncExternalStoreWithSelector } from 'use-sync-external-store/shim/with-selector.js' + +const isPlainObject = (obj: unknown) => + typeof obj === 'object' && !Array.isArray(obj) + +export function useSyncExternalStoreWithTracked< + snapshot extends selection, + selection = snapshot, +>( + subscribe: (onStoreChange: () => void) => () => void, + getSnapshot: () => snapshot, + getServerSnapshot: undefined | null | (() => snapshot) = getSnapshot, + isEqual: (a: selection, b: selection) => boolean = deepEqual, +) { + const trackedKeys = useRef([]) + const result = useSyncExternalStoreWithSelector( + subscribe, + getSnapshot, + getServerSnapshot, + (x) => x, + (a, b) => { + if (isPlainObject(a) && isPlainObject(b) && trackedKeys.current.length) { + for (const key of trackedKeys.current) { + const equal = isEqual( + (a as { [_a: string]: any })[key], + (b as { [_b: string]: any })[key], + ) + if (!equal) return false + } + return true + } + return isEqual(a, b) + }, + ) + + return useMemo(() => { + if (isPlainObject(result)) { + const trackedResult = { ...result } + let properties = {} + for (const [key, value] of Object.entries( + trackedResult as { [key: string]: any }, + )) { + properties = { + ...properties, + [key]: { + configurable: false, + enumerable: true, + get: () => { + if (!trackedKeys.current.includes(key)) { + trackedKeys.current.push(key) + } + return value + }, + }, + } + } + Object.defineProperties(trackedResult, properties) + return trackedResult + } + + return result + }, [result]) +} diff --git a/packages/react/src/hooks/useToken.test-d.ts b/packages/react/src/hooks/useToken.test-d.ts new file mode 100644 index 0000000000..2018951919 --- /dev/null +++ b/packages/react/src/hooks/useToken.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useToken } from './useToken.js' + +test('select data', () => { + const result = useToken({ + query: { + select(data) { + return data?.name + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useToken.test.ts b/packages/react/src/hooks/useToken.test.ts new file mode 100644 index 0000000000..6023797532 --- /dev/null +++ b/packages/react/src/hooks/useToken.test.ts @@ -0,0 +1,59 @@ +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useToken } from './useToken.js' + +test('default', async () => { + const { result } = renderHook(() => + useToken({ + address: '0x1f9840a85d5af5bf1d1762f925bdaddc4201f984', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "address": "0x1f9840a85d5af5bf1d1762f925bdaddc4201f984", + "decimals": 18, + "name": "Uniswap", + "symbol": "UNI", + "totalSupply": { + "formatted": "1000000000", + "value": 1000000000000000000000000000n, + }, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "token", + { + "address": "0x1f9840a85d5af5bf1d1762f925bdaddc4201f984", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/useToken.ts b/packages/react/src/hooks/useToken.ts new file mode 100644 index 0000000000..1d43912f72 --- /dev/null +++ b/packages/react/src/hooks/useToken.ts @@ -0,0 +1,60 @@ +'use client' + +import type { Config, GetTokenErrorType, ResolvedRegister } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetTokenData, + type GetTokenOptions, + type GetTokenQueryFnData, + type GetTokenQueryKey, + getTokenQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseTokenParameters< + config extends Config = Config, + selectData = GetTokenData, +> = Compute< + GetTokenOptions & + ConfigParameter & + QueryParameter< + GetTokenQueryFnData, + GetTokenErrorType, + selectData, + GetTokenQueryKey + > +> + +export type UseTokenReturnType = UseQueryReturnType< + selectData, + GetTokenErrorType +> + +/** + * @deprecated + * + * https://wagmi.sh/react/api/hooks/useToken + */ +export function useToken< + config extends Config = ResolvedRegister['config'], + selectData = GetTokenData, +>( + parameters: UseTokenParameters = {}, +): UseTokenReturnType { + const { address, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getTokenQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(address && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useTransaction.test-d.ts b/packages/react/src/hooks/useTransaction.test-d.ts new file mode 100644 index 0000000000..211efa7f6c --- /dev/null +++ b/packages/react/src/hooks/useTransaction.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useTransaction } from './useTransaction.js' + +test('select data', () => { + const result = useTransaction({ + query: { + select(data) { + return data?.nonce + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useTransaction.test.ts b/packages/react/src/hooks/useTransaction.test.ts new file mode 100644 index 0000000000..190cffb1fe --- /dev/null +++ b/packages/react/src/hooks/useTransaction.test.ts @@ -0,0 +1,72 @@ +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useTransaction } from './useTransaction.js' + +test('default', async () => { + const { result } = renderHook(() => + useTransaction({ + hash: '0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "accessList": [], + "blockHash": "0xd725a38b51e5ceec8c5f6c9ccfdb2cc423af993bb650af5eedca5e4be7156ba7", + "blockNumber": 15189204n, + "chainId": 1, + "from": "0xa0cf798816d4b9b9866b5330eea46a18382f251e", + "gas": 21000n, + "gasPrice": 9371645552n, + "hash": "0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30", + "input": "0x", + "maxFeePerGas": 13644824566n, + "maxPriorityFeePerGas": 1500000000n, + "nonce": 86, + "r": "0x40174f9a38df876c1a7ce2587848819d4082ccd6d67a88aa5cabe59bf594e14f", + "s": "0x7c0c82f62a8a5a9b0e9cf30a54a72fdae8fc54b5b79ddafef0acd30e94e83872", + "to": "0xd2135cfb216b74109775236e36d4b433f1df507b", + "transactionIndex": 144, + "type": "eip1559", + "typeHex": "0x2", + "v": 0n, + "value": 100000000000000000n, + "yParity": 0, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "transaction", + { + "chainId": 1, + "hash": "0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) diff --git a/packages/react/src/hooks/useTransaction.ts b/packages/react/src/hooks/useTransaction.ts new file mode 100644 index 0000000000..6cc920e873 --- /dev/null +++ b/packages/react/src/hooks/useTransaction.ts @@ -0,0 +1,72 @@ +'use client' + +import type { + Config, + GetTransactionErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetTransactionData, + type GetTransactionOptions, + type GetTransactionQueryFnData, + type GetTransactionQueryKey, + getTransactionQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseTransactionParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetTransactionData, +> = Compute< + GetTransactionOptions & + ConfigParameter & + QueryParameter< + GetTransactionQueryFnData, + GetTransactionErrorType, + selectData, + GetTransactionQueryKey + > +> + +export type UseTransactionReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetTransactionData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useTransaction */ +export function useTransaction< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetTransactionData, +>( + parameters: UseTransactionParameters = {}, +): UseTransactionReturnType { + const { blockHash, blockNumber, blockTag, hash, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getTransactionQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean( + !(blockHash && blockNumber && blockTag && hash) && (query.enabled ?? true), + ) + + return useQuery({ + ...(query as any), + ...options, + enabled, + }) as UseTransactionReturnType +} diff --git a/packages/react/src/hooks/useTransactionConfirmations.test-d.ts b/packages/react/src/hooks/useTransactionConfirmations.test-d.ts new file mode 100644 index 0000000000..e2bbcb4266 --- /dev/null +++ b/packages/react/src/hooks/useTransactionConfirmations.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useTransactionConfirmations } from './useTransactionConfirmations.js' + +test('select data', () => { + const result = useTransactionConfirmations({ + query: { + select(data) { + return data + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useTransactionConfirmations.test.ts b/packages/react/src/hooks/useTransactionConfirmations.test.ts new file mode 100644 index 0000000000..4f4a79c251 --- /dev/null +++ b/packages/react/src/hooks/useTransactionConfirmations.test.ts @@ -0,0 +1,215 @@ +import { config, wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import type { Hash } from 'viem' +import { expect, test } from 'vitest' + +import { getTransactionReceipt } from '@wagmi/core' +import { useTransactionConfirmations } from './useTransactionConfirmations.js' + +test('default', async () => { + const { result } = renderHook(() => + useTransactionConfirmations({ + hash: '0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('bigint') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "transactionConfirmations", + { + "chainId": 1, + "hash": "0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: transactionReceipt', async () => { + const transactionReceipt = await getTransactionReceipt(config, { + hash: '0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30', + }) + + const { result } = renderHook(() => + useTransactionConfirmations({ + transactionReceipt, + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('bigint') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "transactionConfirmations", + { + "chainId": 1, + "transactionReceipt": { + "blockHash": "0xd725a38b51e5ceec8c5f6c9ccfdb2cc423af993bb650af5eedca5e4be7156ba7", + "blockNumber": 15189204n, + "contractAddress": null, + "cumulativeGasUsed": 12949744n, + "effectiveGasPrice": 9371645552n, + "from": "0xa0cf798816d4b9b9866b5330eea46a18382f251e", + "gasUsed": 21000n, + "logs": [], + "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "status": "success", + "to": "0xd2135cfb216b74109775236e36d4b433f1df507b", + "transactionHash": "0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30", + "transactionIndex": 144, + "type": "eip1559", + }, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: hash: undefined -> defined', async () => { + let hash: Hash | undefined = undefined + + const { result, rerender } = renderHook(() => + useTransactionConfirmations({ + hash, + }), + ) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "transactionConfirmations", + { + "chainId": 1, + "hash": undefined, + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + + hash = '0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30' + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('bigint') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "transactionConfirmations", + { + "chainId": 1, + "hash": "0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useTransactionConfirmations()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useTransactionConfirmations.ts b/packages/react/src/hooks/useTransactionConfirmations.ts new file mode 100644 index 0000000000..c8e9ddec3f --- /dev/null +++ b/packages/react/src/hooks/useTransactionConfirmations.ts @@ -0,0 +1,66 @@ +'use client' + +import type { + Config, + GetTransactionConfirmationsErrorType, + ResolvedRegister, +} from '@wagmi/core' +import { + type GetTransactionConfirmationsData, + type GetTransactionConfirmationsOptions, + type GetTransactionConfirmationsQueryFnData, + type GetTransactionConfirmationsQueryKey, + getTransactionConfirmationsQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseTransactionConfirmationsParameters< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = GetTransactionConfirmationsData, +> = GetTransactionConfirmationsOptions & + ConfigParameter & + QueryParameter< + GetTransactionConfirmationsQueryFnData, + GetTransactionConfirmationsErrorType, + selectData, + GetTransactionConfirmationsQueryKey + > + +export type UseTransactionConfirmationsReturnType< + selectData = GetTransactionConfirmationsData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useTransactionConfirmations */ +export function useTransactionConfirmations< + config extends Config = ResolvedRegister['config'], + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = GetTransactionConfirmationsData, +>( + parameters: UseTransactionConfirmationsParameters< + config, + chainId, + selectData + > = {} as any, +): UseTransactionConfirmationsReturnType { + const { hash, transactionReceipt, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getTransactionConfirmationsQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean( + !(hash && transactionReceipt) && + (hash || transactionReceipt) && + (query.enabled ?? true), + ) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useTransactionCount.test-d.ts b/packages/react/src/hooks/useTransactionCount.test-d.ts new file mode 100644 index 0000000000..069d10b9cd --- /dev/null +++ b/packages/react/src/hooks/useTransactionCount.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useTransactionCount } from './useTransactionCount.js' + +test('select data', () => { + const result = useTransactionCount({ + query: { + select(data) { + return data + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useTransactionCount.test.ts b/packages/react/src/hooks/useTransactionCount.test.ts new file mode 100644 index 0000000000..13a241ea88 --- /dev/null +++ b/packages/react/src/hooks/useTransactionCount.test.ts @@ -0,0 +1,238 @@ +import { accounts, chain, wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import type { Address } from 'viem' +import { expect, test } from 'vitest' + +import { useTransactionCount } from './useTransactionCount.js' + +const address = accounts[0] + +test('default', async () => { + const { result } = renderHook(() => useTransactionCount({ address })) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('number') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "transactionCount", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: chainId', async () => { + const { result } = renderHook(() => + useTransactionCount({ address, chainId: chain.mainnet2.id }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('number') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "transactionCount", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 456, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: blockNumber', async () => { + const { result } = renderHook(() => + useTransactionCount({ address, blockNumber: 13677382n }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('number') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "transactionCount", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockNumber": 13677382n, + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: address: undefined -> defined', async () => { + let address: Address | undefined = undefined + + const { result, rerender } = renderHook(() => + useTransactionCount({ address }), + ) + + { + const { data, ...rest } = result.current + expect(data).toBeTypeOf('undefined') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "transactionCount", + { + "address": undefined, + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + } + + address = accounts[0] + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, ...rest } = result.current + expect(data).toBeTypeOf('number') + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "transactionCount", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useTransactionCount()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useTransactionCount.ts b/packages/react/src/hooks/useTransactionCount.ts new file mode 100644 index 0000000000..341536aea7 --- /dev/null +++ b/packages/react/src/hooks/useTransactionCount.ts @@ -0,0 +1,59 @@ +'use client' + +import type { + Config, + GetTransactionCountErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import type { GetTransactionCountQueryFnData } from '@wagmi/core/query' +import { + type GetTransactionCountData, + type GetTransactionCountOptions, + type GetTransactionCountQueryKey, + getTransactionCountQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseTransactionCountParameters< + config extends Config = Config, + selectData = GetTransactionCountData, +> = Compute< + GetTransactionCountOptions & + ConfigParameter & + QueryParameter< + GetTransactionCountQueryFnData, + GetTransactionCountErrorType, + selectData, + GetTransactionCountQueryKey + > +> + +export type UseTransactionCountReturnType< + selectData = GetTransactionCountData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useTransactionCount */ +export function useTransactionCount< + config extends Config = ResolvedRegister['config'], + selectData = GetTransactionCountData, +>( + parameters: UseTransactionCountParameters = {}, +): UseTransactionCountReturnType { + const { address, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getTransactionCountQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(address && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useTransactionReceipt.test-d.ts b/packages/react/src/hooks/useTransactionReceipt.test-d.ts new file mode 100644 index 0000000000..af2785934a --- /dev/null +++ b/packages/react/src/hooks/useTransactionReceipt.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useTransactionReceipt } from './useTransactionReceipt.js' + +test('select data', () => { + const result = useTransactionReceipt({ + query: { + select(data) { + return data?.blockNumber + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useTransactionReceipt.test.ts b/packages/react/src/hooks/useTransactionReceipt.test.ts new file mode 100644 index 0000000000..fd2e24d76b --- /dev/null +++ b/packages/react/src/hooks/useTransactionReceipt.test.ts @@ -0,0 +1,237 @@ +import { chain, wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import type { Hash } from 'viem' +import { expect, test } from 'vitest' +import { useTransactionReceipt } from './useTransactionReceipt.js' + +test('default', async () => { + const { result } = renderHook(() => + useTransactionReceipt({ + hash: '0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "blockHash": "0xb932f77cf770d1d1c8f861153eec1e990f5d56b6ffdb4ac06aef3cca51ef37d4", + "blockNumber": 16280769n, + "contractAddress": null, + "cumulativeGasUsed": 21000n, + "effectiveGasPrice": 33427926161n, + "from": "0x043022ef9fca1066024d19d681e2ccf44ff90de3", + "gasUsed": 21000n, + "logs": [], + "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "status": "success", + "to": "0x318a5fb4f1604fc46375a1db9a9018b6e423b345", + "transactionHash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + "transactionIndex": 0, + "type": "legacy", + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getTransactionReceipt", + { + "chainId": 1, + "hash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: chainId', async () => { + const { result } = renderHook(() => + useTransactionReceipt({ + chainId: chain.mainnet2.id, + hash: '0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "blockHash": "0xb932f77cf770d1d1c8f861153eec1e990f5d56b6ffdb4ac06aef3cca51ef37d4", + "blockNumber": 16280769n, + "contractAddress": null, + "cumulativeGasUsed": 21000n, + "effectiveGasPrice": 33427926161n, + "from": "0x043022ef9fca1066024d19d681e2ccf44ff90de3", + "gasUsed": 21000n, + "logs": [], + "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "status": "success", + "to": "0x318a5fb4f1604fc46375a1db9a9018b6e423b345", + "transactionHash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + "transactionIndex": 0, + "type": "legacy", + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getTransactionReceipt", + { + "chainId": 456, + "hash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: hash: undefined -> defined', async () => { + let hash: Hash | undefined = undefined + + const { result, rerender } = renderHook(() => + useTransactionReceipt({ + hash, + }), + ) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "getTransactionReceipt", + { + "chainId": 1, + "hash": undefined, + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + + hash = '0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871' + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": { + "blockHash": "0xb932f77cf770d1d1c8f861153eec1e990f5d56b6ffdb4ac06aef3cca51ef37d4", + "blockNumber": 16280769n, + "contractAddress": null, + "cumulativeGasUsed": 21000n, + "effectiveGasPrice": 33427926161n, + "from": "0x043022ef9fca1066024d19d681e2ccf44ff90de3", + "gasUsed": 21000n, + "logs": [], + "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "status": "success", + "to": "0x318a5fb4f1604fc46375a1db9a9018b6e423b345", + "transactionHash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + "transactionIndex": 0, + "type": "legacy", + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getTransactionReceipt", + { + "chainId": 1, + "hash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useTransactionReceipt()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useTransactionReceipt.ts b/packages/react/src/hooks/useTransactionReceipt.ts new file mode 100644 index 0000000000..f29ab6204e --- /dev/null +++ b/packages/react/src/hooks/useTransactionReceipt.ts @@ -0,0 +1,69 @@ +'use client' + +import type { + Config, + GetTransactionReceiptErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetTransactionReceiptData, + type GetTransactionReceiptOptions, + type GetTransactionReceiptQueryKey, + getTransactionReceiptQueryOptions, +} from '@wagmi/core/query' +import type { GetTransactionReceiptQueryFnData } from '@wagmi/core/query' +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseTransactionReceiptParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetTransactionReceiptData, +> = Compute< + GetTransactionReceiptOptions & + ConfigParameter & + QueryParameter< + GetTransactionReceiptQueryFnData, + GetTransactionReceiptErrorType, + selectData, + GetTransactionReceiptQueryKey + > +> + +export type UseTransactionReceiptReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetTransactionReceiptData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useTransactionReceipt */ +export function useTransactionReceipt< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetTransactionReceiptData, +>( + parameters: UseTransactionReceiptParameters = {}, +): UseTransactionReceiptReturnType { + const { hash, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = getTransactionReceiptQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(hash && (query.enabled ?? true)) + + return useQuery({ + ...(query as any), + ...options, + enabled, + }) as UseTransactionReceiptReturnType +} diff --git a/packages/react/src/hooks/useVerifyMessage.test-d.ts b/packages/react/src/hooks/useVerifyMessage.test-d.ts new file mode 100644 index 0000000000..5a9ad7e257 --- /dev/null +++ b/packages/react/src/hooks/useVerifyMessage.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useVerifyMessage } from './useVerifyMessage.js' + +test('select data', () => { + const result = useVerifyMessage({ + query: { + select(data) { + return data + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useVerifyMessage.test.ts b/packages/react/src/hooks/useVerifyMessage.test.ts new file mode 100644 index 0000000000..244b6331f7 --- /dev/null +++ b/packages/react/src/hooks/useVerifyMessage.test.ts @@ -0,0 +1,318 @@ +import { accounts, chain, wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import type { Hex } from 'viem' +import { useVerifyMessage } from './useVerifyMessage.js' + +const address = accounts[0] + +test('default', async () => { + const { result } = renderHook(() => + useVerifyMessage({ + address, + message: 'This is a test message for viem!', + signature: + '0xc4c7f2820177020d66d5fd00d084cdd3f575a868c059c29a2d7f23398d04819709a14f83d98b446dda539ca5dcb87d75aa3340eb15e66d67606850622a3420f61b', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": true, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "verifyMessage", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + "message": "This is a test message for viem!", + "signature": "0xc4c7f2820177020d66d5fd00d084cdd3f575a868c059c29a2d7f23398d04819709a14f83d98b446dda539ca5dcb87d75aa3340eb15e66d67606850622a3420f61b", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: chainId', async () => { + const { result } = renderHook(() => + useVerifyMessage({ + chainId: chain.mainnet2.id, + address, + message: 'This is a test message for viem!', + signature: + '0xc4c7f2820177020d66d5fd00d084cdd3f575a868c059c29a2d7f23398d04819709a14f83d98b446dda539ca5dcb87d75aa3340eb15e66d67606850622a3420f61b', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": true, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "verifyMessage", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 456, + "message": "This is a test message for viem!", + "signature": "0xc4c7f2820177020d66d5fd00d084cdd3f575a868c059c29a2d7f23398d04819709a14f83d98b446dda539ca5dcb87d75aa3340eb15e66d67606850622a3420f61b", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: blockNumber', async () => { + const { result } = renderHook(() => + useVerifyMessage({ + blockNumber: 12345678n, + address, + message: 'This is a test message for viem!', + signature: + '0xc4c7f2820177020d66d5fd00d084cdd3f575a868c059c29a2d7f23398d04819709a14f83d98b446dda539ca5dcb87d75aa3340eb15e66d67606850622a3420f61b', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": true, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "verifyMessage", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockNumber": 12345678n, + "chainId": 1, + "message": "This is a test message for viem!", + "signature": "0xc4c7f2820177020d66d5fd00d084cdd3f575a868c059c29a2d7f23398d04819709a14f83d98b446dda539ca5dcb87d75aa3340eb15e66d67606850622a3420f61b", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('parameters: blockTag', async () => { + const { result } = renderHook(() => + useVerifyMessage({ + blockTag: 'pending', + address, + message: 'This is a test message for viem!', + signature: + '0xc4c7f2820177020d66d5fd00d084cdd3f575a868c059c29a2d7f23398d04819709a14f83d98b446dda539ca5dcb87d75aa3340eb15e66d67606850622a3420f61b', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": true, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "verifyMessage", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "blockTag": "pending", + "chainId": 1, + "message": "This is a test message for viem!", + "signature": "0xc4c7f2820177020d66d5fd00d084cdd3f575a868c059c29a2d7f23398d04819709a14f83d98b446dda539ca5dcb87d75aa3340eb15e66d67606850622a3420f61b", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: signature: undefined -> defined', async () => { + let signature: Hex | undefined = undefined + + const { result, rerender } = renderHook(() => + useVerifyMessage({ + address, + message: 'This is a test message for viem!', + signature, + }), + ) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "verifyMessage", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + "message": "This is a test message for viem!", + "signature": undefined, + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + + signature = + '0xc4c7f2820177020d66d5fd00d084cdd3f575a868c059c29a2d7f23398d04819709a14f83d98b446dda539ca5dcb87d75aa3340eb15e66d67606850622a3420f61b' + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": true, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "verifyMessage", + { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + "message": "This is a test message for viem!", + "signature": "0xc4c7f2820177020d66d5fd00d084cdd3f575a868c059c29a2d7f23398d04819709a14f83d98b446dda539ca5dcb87d75aa3340eb15e66d67606850622a3420f61b", + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useVerifyMessage()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useVerifyMessage.ts b/packages/react/src/hooks/useVerifyMessage.ts new file mode 100644 index 0000000000..ae8bb6df21 --- /dev/null +++ b/packages/react/src/hooks/useVerifyMessage.ts @@ -0,0 +1,59 @@ +'use client' + +import type { + Config, + ResolvedRegister, + VerifyMessageErrorType, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type VerifyMessageData, + type VerifyMessageOptions, + type VerifyMessageQueryKey, + verifyMessageQueryOptions, +} from '@wagmi/core/query' +import type { VerifyMessageQueryFnData } from '@wagmi/core/query' +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseVerifyMessageParameters< + config extends Config = Config, + selectData = VerifyMessageData, +> = Compute< + VerifyMessageOptions & + ConfigParameter & + QueryParameter< + VerifyMessageQueryFnData, + VerifyMessageErrorType, + selectData, + VerifyMessageQueryKey + > +> + +export type UseVerifyMessageReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useVerifyMessage */ +export function useVerifyMessage< + config extends Config = ResolvedRegister['config'], + selectData = VerifyMessageData, +>( + parameters: UseVerifyMessageParameters = {}, +): UseVerifyMessageReturnType { + const { address, message, signature, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = verifyMessageQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean( + address && message && signature && (query.enabled ?? true), + ) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useVerifyTypedData.test-d.ts b/packages/react/src/hooks/useVerifyTypedData.test-d.ts new file mode 100644 index 0000000000..91f875e0b6 --- /dev/null +++ b/packages/react/src/hooks/useVerifyTypedData.test-d.ts @@ -0,0 +1,40 @@ +import type { typedData } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import type { Address } from 'viem' +import { + type UseVerifyTypedDataParameters, + useVerifyTypedData, +} from './useVerifyTypedData.js' + +test('select data', () => { + const result = useVerifyTypedData({ + query: { + select(data) { + return data + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) + +test('UseReadContractParameters', () => { + type Result = UseVerifyTypedDataParameters< + typeof typedData.basic.types, + 'Mail' + > + expectTypeOf>().toEqualTypeOf<{ + primaryType?: 'Mail' | 'Person' + message?: { + from: { + name: string + wallet: Address + } + to: { + name: string + wallet: Address + } + contents: string + } + }>() +}) diff --git a/packages/react/src/hooks/useVerifyTypedData.test.ts b/packages/react/src/hooks/useVerifyTypedData.test.ts new file mode 100644 index 0000000000..d57331743f --- /dev/null +++ b/packages/react/src/hooks/useVerifyTypedData.test.ts @@ -0,0 +1,481 @@ +import { typedData, wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import type { Hex } from 'viem' +import { expect, test } from 'vitest' + +import { useVerifyTypedData } from './useVerifyTypedData.js' + +const smartAccountAddress = '0x3FCf42e10CC70Fe75A62EB3aDD6D305Aa840d145' +const notDeployedAddress = '0xdeadbeefdeadbeefdeadbeefdeadbeefdeadbeef' + +test('valid signature', async () => { + const { result } = renderHook(() => + useVerifyTypedData({ + ...typedData.basic, + primaryType: 'Mail', + address: smartAccountAddress, + signature: + '0x79d756d805073dc97b7bc885b0d56ddf319a2599530fe1e178c2a7de5be88980068d24f20a79b318ea0a84d33ae06f93db77e4235e5d9eeb8b1d7a63922ada3e1c', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": true, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "verifyTypedData", + { + "address": "0x3FCf42e10CC70Fe75A62EB3aDD6D305Aa840d145", + "chainId": 1, + "domain": { + "chainId": 1, + "name": "Ether Mail", + "verifyingContract": "0x0000000000000000000000000000000000000000", + "version": "1", + }, + "message": { + "contents": "Hello, Bob!", + "from": { + "name": "Cow", + "wallet": "0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826", + }, + "to": { + "name": "Bob", + "wallet": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", + }, + }, + "primaryType": "Mail", + "signature": "0x79d756d805073dc97b7bc885b0d56ddf319a2599530fe1e178c2a7de5be88980068d24f20a79b318ea0a84d33ae06f93db77e4235e5d9eeb8b1d7a63922ada3e1c", + "types": { + "Mail": [ + { + "name": "from", + "type": "Person", + }, + { + "name": "to", + "type": "Person", + }, + { + "name": "contents", + "type": "string", + }, + ], + "Person": [ + { + "name": "name", + "type": "string", + }, + { + "name": "wallet", + "type": "address", + }, + ], + }, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('invalid signature', async () => { + const { result } = renderHook(() => + useVerifyTypedData({ + ...typedData.basic, + primaryType: 'Mail', + address: smartAccountAddress, + signature: '0xdead', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": false, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "verifyTypedData", + { + "address": "0x3FCf42e10CC70Fe75A62EB3aDD6D305Aa840d145", + "chainId": 1, + "domain": { + "chainId": 1, + "name": "Ether Mail", + "verifyingContract": "0x0000000000000000000000000000000000000000", + "version": "1", + }, + "message": { + "contents": "Hello, Bob!", + "from": { + "name": "Cow", + "wallet": "0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826", + }, + "to": { + "name": "Bob", + "wallet": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", + }, + }, + "primaryType": "Mail", + "signature": "0xdead", + "types": { + "Mail": [ + { + "name": "from", + "type": "Person", + }, + { + "name": "to", + "type": "Person", + }, + { + "name": "contents", + "type": "string", + }, + ], + "Person": [ + { + "name": "name", + "type": "string", + }, + { + "name": "wallet", + "type": "address", + }, + ], + }, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('account not deployed', async () => { + const { result } = renderHook(() => + useVerifyTypedData({ + ...typedData.basic, + primaryType: 'Mail', + address: notDeployedAddress, + signature: + '0x79d756d805073dc97b7bc885b0d56ddf319a2599530fe1e178c2a7de5be88980068d24f20a79b318ea0a84d33ae06f93db77e4235e5d9eeb8b1d7a63922ada3e1c', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": false, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "verifyTypedData", + { + "address": "0xdeadbeefdeadbeefdeadbeefdeadbeefdeadbeef", + "chainId": 1, + "domain": { + "chainId": 1, + "name": "Ether Mail", + "verifyingContract": "0x0000000000000000000000000000000000000000", + "version": "1", + }, + "message": { + "contents": "Hello, Bob!", + "from": { + "name": "Cow", + "wallet": "0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826", + }, + "to": { + "name": "Bob", + "wallet": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", + }, + }, + "primaryType": "Mail", + "signature": "0x79d756d805073dc97b7bc885b0d56ddf319a2599530fe1e178c2a7de5be88980068d24f20a79b318ea0a84d33ae06f93db77e4235e5d9eeb8b1d7a63922ada3e1c", + "types": { + "Mail": [ + { + "name": "from", + "type": "Person", + }, + { + "name": "to", + "type": "Person", + }, + { + "name": "contents", + "type": "string", + }, + ], + "Person": [ + { + "name": "name", + "type": "string", + }, + { + "name": "wallet", + "type": "address", + }, + ], + }, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: signature: undefined -> defined', async () => { + let signature: Hex | undefined = undefined + + const { result, rerender } = renderHook(() => + useVerifyTypedData({ + ...typedData.basic, + primaryType: 'Mail', + address: smartAccountAddress, + signature, + }), + ) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "verifyTypedData", + { + "address": "0x3FCf42e10CC70Fe75A62EB3aDD6D305Aa840d145", + "chainId": 1, + "domain": { + "chainId": 1, + "name": "Ether Mail", + "verifyingContract": "0x0000000000000000000000000000000000000000", + "version": "1", + }, + "message": { + "contents": "Hello, Bob!", + "from": { + "name": "Cow", + "wallet": "0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826", + }, + "to": { + "name": "Bob", + "wallet": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", + }, + }, + "primaryType": "Mail", + "signature": undefined, + "types": { + "Mail": [ + { + "name": "from", + "type": "Person", + }, + { + "name": "to", + "type": "Person", + }, + { + "name": "contents", + "type": "string", + }, + ], + "Person": [ + { + "name": "name", + "type": "string", + }, + { + "name": "wallet", + "type": "address", + }, + ], + }, + }, + ], + "refetch": [Function], + "status": "pending", + } + `) + + signature = + '0x79d756d805073dc97b7bc885b0d56ddf319a2599530fe1e178c2a7de5be88980068d24f20a79b318ea0a84d33ae06f93db77e4235e5d9eeb8b1d7a63922ada3e1c' + rerender() + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": true, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "verifyTypedData", + { + "address": "0x3FCf42e10CC70Fe75A62EB3aDD6D305Aa840d145", + "chainId": 1, + "domain": { + "chainId": 1, + "name": "Ether Mail", + "verifyingContract": "0x0000000000000000000000000000000000000000", + "version": "1", + }, + "message": { + "contents": "Hello, Bob!", + "from": { + "name": "Cow", + "wallet": "0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826", + }, + "to": { + "name": "Bob", + "wallet": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", + }, + }, + "primaryType": "Mail", + "signature": "0x79d756d805073dc97b7bc885b0d56ddf319a2599530fe1e178c2a7de5be88980068d24f20a79b318ea0a84d33ae06f93db77e4235e5d9eeb8b1d7a63922ada3e1c", + "types": { + "Mail": [ + { + "name": "from", + "type": "Person", + }, + { + "name": "to", + "type": "Person", + }, + { + "name": "contents", + "type": "string", + }, + ], + "Person": [ + { + "name": "name", + "type": "string", + }, + { + "name": "wallet", + "type": "address", + }, + ], + }, + }, + ], + "refetch": [Function], + "status": "success", + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const { result } = renderHook(() => useVerifyTypedData()) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useVerifyTypedData.ts b/packages/react/src/hooks/useVerifyTypedData.ts new file mode 100644 index 0000000000..b02d1a8510 --- /dev/null +++ b/packages/react/src/hooks/useVerifyTypedData.ts @@ -0,0 +1,81 @@ +'use client' + +import type { + Config, + ResolvedRegister, + VerifyTypedDataErrorType, +} from '@wagmi/core' +import { + type VerifyTypedDataData, + type VerifyTypedDataOptions, + type VerifyTypedDataQueryKey, + verifyTypedDataQueryOptions, +} from '@wagmi/core/query' +import type { VerifyTypedDataQueryFnData } from '@wagmi/core/query' +import type { TypedData } from 'viem' +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseVerifyTypedDataParameters< + typedData extends TypedData | Record = TypedData, + primaryType extends keyof typedData | 'EIP712Domain' = keyof typedData, + config extends Config = Config, + selectData = VerifyTypedDataData, +> = VerifyTypedDataOptions & + ConfigParameter & + QueryParameter< + VerifyTypedDataQueryFnData, + VerifyTypedDataErrorType, + selectData, + VerifyTypedDataQueryKey + > + +export type UseVerifyTypedDataReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useVerifyTypedData */ +export function useVerifyTypedData< + const typedData extends TypedData | Record, + primaryType extends keyof typedData | 'EIP712Domain', + config extends Config = ResolvedRegister['config'], + selectData = VerifyTypedDataData, +>( + parameters: UseVerifyTypedDataParameters< + typedData, + primaryType, + config, + selectData + > = {} as any, +): UseVerifyTypedDataReturnType { + const { + address, + message, + primaryType, + signature, + types, + query = {}, + } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = verifyTypedDataQueryOptions( + config, + { + ...parameters, + chainId: parameters.chainId ?? chainId, + }, + ) + const enabled = Boolean( + address && + message && + primaryType && + signature && + types && + (query.enabled ?? true), + ) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useWaitForCallsStatus.test.ts b/packages/react/src/hooks/useWaitForCallsStatus.test.ts new file mode 100644 index 0000000000..96f5a2a7e4 --- /dev/null +++ b/packages/react/src/hooks/useWaitForCallsStatus.test.ts @@ -0,0 +1,101 @@ +import { connect, disconnect } from '@wagmi/core' +import { accounts, config, testClient, wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { useSendCalls } from './useSendCalls.js' +import { useWaitForCallsStatus } from './useWaitForCallsStatus.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const useSendCalls_render = renderHook(() => useSendCalls()) + const useWaitForCallsStatus_render = renderHook(() => + useWaitForCallsStatus({ id: useSendCalls_render.result.current.data?.id }), + ) + + useSendCalls_render.result.current.sendCalls({ + calls: [ + { + data: '0xdeadbeef', + to: accounts[1], + value: parseEther('1'), + }, + { + to: accounts[2], + value: parseEther('2'), + }, + { + to: accounts[3], + value: parseEther('3'), + }, + ], + }) + await waitFor(() => + expect(useSendCalls_render.result.current.isSuccess).toBeTruthy(), + ) + + expect(useWaitForCallsStatus_render.result.current.fetchStatus).toBe('idle') + useWaitForCallsStatus_render.rerender() + expect(useWaitForCallsStatus_render.result.current.fetchStatus).toBe( + 'fetching', + ) + + await Promise.all([ + waitFor(() => + expect( + useWaitForCallsStatus_render.result.current.isSuccess, + ).toBeTruthy(), + ), + (async () => { + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + })(), + ]) + + expect(useWaitForCallsStatus_render.result.current.data?.status).toBe( + 'success', + ) + expect( + useWaitForCallsStatus_render.result.current.data?.receipts?.map((x) => ({ + ...x, + blockHash: undefined, + })), + ).toMatchInlineSnapshot( + ` + [ + { + "blockHash": undefined, + "blockNumber": 19258214n, + "gasUsed": 21064n, + "logs": [], + "status": "success", + "transactionHash": "0x13c53b2d4d9da424835525349cd66e553330f323d6fb19458b801ae1f7989a41", + }, + { + "blockHash": undefined, + "blockNumber": 19258214n, + "gasUsed": 21000n, + "logs": [], + "status": "success", + "transactionHash": "0xd8397b3e82b061c26a0c2093f1ceca0c3662a512614f7d6370349e89d0eea007", + }, + { + "blockHash": undefined, + "blockNumber": 19258214n, + "gasUsed": 21000n, + "logs": [], + "status": "success", + "transactionHash": "0x4d26e346593d9ea265bb164b115e89aa92df43b0b8778ac75d4ad28e2a22b101", + }, + ] + `, + ) + + await testClient.mainnet.mine({ blocks: 1 }) + + await disconnect(config, { connector }) +}) diff --git a/packages/react/src/hooks/useWaitForCallsStatus.ts b/packages/react/src/hooks/useWaitForCallsStatus.ts new file mode 100644 index 0000000000..7c428c9405 --- /dev/null +++ b/packages/react/src/hooks/useWaitForCallsStatus.ts @@ -0,0 +1,54 @@ +'use client' + +import type { + Config, + ResolvedRegister, + WaitForCallsStatusErrorType, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type WaitForCallsStatusData, + type WaitForCallsStatusOptions, + type WaitForCallsStatusQueryFnData, + type WaitForCallsStatusQueryKey, + waitForCallsStatusQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseWaitForCallsStatusParameters< + config extends Config = Config, + selectData = WaitForCallsStatusData, +> = Compute< + WaitForCallsStatusOptions & + ConfigParameter & + QueryParameter< + WaitForCallsStatusQueryFnData, + WaitForCallsStatusErrorType, + selectData, + WaitForCallsStatusQueryKey + > +> + +export type UseWaitForCallsStatusReturnType< + selectData = WaitForCallsStatusData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useWaitForCallsStatus */ +export function useWaitForCallsStatus< + config extends Config = ResolvedRegister['config'], + selectData = WaitForCallsStatusData, +>( + parameters: UseWaitForCallsStatusParameters, +): UseWaitForCallsStatusReturnType { + const { id, query = {} } = parameters + + const config = useConfig(parameters) + + const options = waitForCallsStatusQueryOptions(config, parameters) + const enabled = Boolean(id && (query.enabled ?? true)) + + return useQuery({ ...query, ...options, enabled }) +} diff --git a/packages/react/src/hooks/useWaitForTransactionReceipt.test-d.ts b/packages/react/src/hooks/useWaitForTransactionReceipt.test-d.ts new file mode 100644 index 0000000000..2d3bd28445 --- /dev/null +++ b/packages/react/src/hooks/useWaitForTransactionReceipt.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useWaitForTransactionReceipt } from './useWaitForTransactionReceipt.js' + +test('select data', () => { + const result = useWaitForTransactionReceipt({ + query: { + select(data) { + return data?.blockNumber + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf() +}) diff --git a/packages/react/src/hooks/useWaitForTransactionReceipt.test.ts b/packages/react/src/hooks/useWaitForTransactionReceipt.test.ts new file mode 100644 index 0000000000..484d25087f --- /dev/null +++ b/packages/react/src/hooks/useWaitForTransactionReceipt.test.ts @@ -0,0 +1,77 @@ +import { wait } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' +import { useWaitForTransactionReceipt } from './useWaitForTransactionReceipt.js' + +test('default', async () => { + const { result } = renderHook(() => + useWaitForTransactionReceipt({ + hash: '0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30', + }), + ) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result).toMatchInlineSnapshot(` + { + "current": { + "data": { + "blockHash": "0xd725a38b51e5ceec8c5f6c9ccfdb2cc423af993bb650af5eedca5e4be7156ba7", + "blockNumber": 15189204n, + "chainId": 1, + "contractAddress": null, + "cumulativeGasUsed": 12949744n, + "effectiveGasPrice": 9371645552n, + "from": "0xa0cf798816d4b9b9866b5330eea46a18382f251e", + "gasUsed": 21000n, + "logs": [], + "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "status": "success", + "to": "0xd2135cfb216b74109775236e36d4b433f1df507b", + "transactionHash": "0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30", + "transactionIndex": 144, + "type": "eip1559", + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "waitForTransactionReceipt", + { + "chainId": 1, + "hash": "0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30", + }, + ], + "refetch": [Function], + "status": "success", + }, + } + `) +}) + +test('disabled when hash is undefined', async () => { + const { result } = renderHook(() => + useWaitForTransactionReceipt({ hash: undefined }), + ) + + await wait(100) + await waitFor(() => expect(result.current.isPending).toBeTruthy()) +}) diff --git a/packages/react/src/hooks/useWaitForTransactionReceipt.ts b/packages/react/src/hooks/useWaitForTransactionReceipt.ts new file mode 100644 index 0000000000..c07d1639bc --- /dev/null +++ b/packages/react/src/hooks/useWaitForTransactionReceipt.ts @@ -0,0 +1,74 @@ +'use client' + +import type { + Config, + ResolvedRegister, + WaitForTransactionReceiptErrorType, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type WaitForTransactionReceiptData, + type WaitForTransactionReceiptOptions, + type WaitForTransactionReceiptQueryFnData, + type WaitForTransactionReceiptQueryKey, + waitForTransactionReceiptQueryOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseWaitForTransactionReceiptParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = WaitForTransactionReceiptData, +> = Compute< + WaitForTransactionReceiptOptions & + ConfigParameter & + QueryParameter< + WaitForTransactionReceiptQueryFnData, + WaitForTransactionReceiptErrorType, + selectData, + WaitForTransactionReceiptQueryKey + > +> + +export type UseWaitForTransactionReceiptReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = WaitForTransactionReceiptData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useWaitForTransactionReceipt */ +export function useWaitForTransactionReceipt< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = WaitForTransactionReceiptData, +>( + parameters: UseWaitForTransactionReceiptParameters< + config, + chainId, + selectData + > = {}, +): UseWaitForTransactionReceiptReturnType { + const { hash, query = {} } = parameters + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const options = waitForTransactionReceiptQueryOptions(config, { + ...parameters, + chainId: parameters.chainId ?? chainId, + }) + const enabled = Boolean(hash && (query.enabled ?? true)) + + return useQuery({ + ...(query as any), + ...options, + enabled, + }) as UseWaitForTransactionReceiptReturnType +} diff --git a/packages/react/src/hooks/useWalletClient.test-d.ts b/packages/react/src/hooks/useWalletClient.test-d.ts new file mode 100644 index 0000000000..c2ea48bcb1 --- /dev/null +++ b/packages/react/src/hooks/useWalletClient.test-d.ts @@ -0,0 +1,12 @@ +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useWalletClient } from './useWalletClient.js' + +test('parameters: config', async () => { + const client = useWalletClient({ config }) + expectTypeOf(client.data?.chain?.id!).toEqualTypeOf<1 | 456 | 10>() + + const client2 = useWalletClient({ config, chainId: 1 }) + expectTypeOf(client2.data?.chain?.id!).toEqualTypeOf<1>() +}) diff --git a/packages/react/src/hooks/useWalletClient.test.tsx b/packages/react/src/hooks/useWalletClient.test.tsx new file mode 100644 index 0000000000..40fdd5850a --- /dev/null +++ b/packages/react/src/hooks/useWalletClient.test.tsx @@ -0,0 +1,222 @@ +import { connect, disconnect } from '@wagmi/core' +import { config, wait } from '@wagmi/test' +import { render, renderHook, waitFor } from '@wagmi/test/react' +import * as React from 'react' +import { expect, test } from 'vitest' + +import { useAccount } from './useAccount.js' +import { useConnect } from './useConnect.js' +import { useDisconnect } from './useDisconnect.js' +import { useSwitchChain } from './useSwitchChain.js' +import { useWalletClient } from './useWalletClient.js' + +// Almost identical implementation to `useConnectorClient` (except for return type) +// Should update both in tandem + +const connector = config.connectors[0]! + +test('default', async () => { + const { result } = renderHook(() => useWalletClient()) + + await waitFor(() => expect(result.current.isPending).toBeTruthy()) + + expect(result.current).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "walletClient", + { + "chainId": 1, + "connectorUid": undefined, + }, + ], + "refetch": [Function], + "status": "pending", + } + `) +}) + +test('behavior: connected on mount', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useWalletClient()) + + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + const { data, queryKey: _, ...rest } = result.current + expect(data).toMatchObject( + expect.objectContaining({ + account: expect.any(Object), + chain: expect.any(Object), + }), + ) + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": true, + "refetch": [Function], + "status": "success", + } + `) + + await disconnect(config, { connector }) +}) + +test('behavior: connect and disconnect', async () => { + const { result } = renderHook(() => ({ + useConnect: useConnect(), + useWalletClient: useWalletClient(), + useDisconnect: useDisconnect(), + })) + + expect(result.current.useWalletClient.data).not.toBeDefined() + + result.current.useConnect.connect({ + connector: result.current.useConnect.connectors[0]!, + }) + + await waitFor(() => expect(result.current.useWalletClient.data).toBeDefined()) + + result.current.useDisconnect.disconnect() + + await waitFor(() => + expect(result.current.useWalletClient.data).not.toBeDefined(), + ) +}) + +test('behavior: switch chains', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => ({ + useWalletClient: useWalletClient(), + useSwitchChain: useSwitchChain(), + })) + + expect(result.current.useWalletClient.data).not.toBeDefined() + + await waitFor(() => expect(result.current.useWalletClient.data).toBeDefined()) + + result.current.useSwitchChain.switchChain({ chainId: 456 }) + await waitFor(() => { + expect(result.current.useSwitchChain.isSuccess).toBeTruthy() + result.current.useSwitchChain.reset() + }) + expect(result.current.useWalletClient.data?.chain.id).toEqual(456) + + result.current.useSwitchChain.switchChain({ chainId: 1 }) + await waitFor(() => + expect(result.current.useSwitchChain.isSuccess).toBeTruthy(), + ) + expect(result.current.useWalletClient.data?.chain.id).toEqual(1) + + await disconnect(config, { connector }) +}) + +test('behavior: re-render does not invalidate query', async () => { + const { getByTestId } = render() + + getByTestId('connect').click() + await waitFor(() => { + expect(getByTestId('address').innerText).toContain( + '0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266', + ) + expect(getByTestId('client').innerText).toBeTruthy() + + expect(getByTestId('child-client').innerText).toBeTruthy() + expect(getByTestId('render-count').innerText).toEqual('1') + }) + + const initialClient = getByTestId('child-client').innerText + + getByTestId('rerender').click() + await waitFor(() => { + expect(getByTestId('render-count').innerText).toEqual('2') + }) + await wait(200) + + expect(getByTestId('child-client').innerText).toEqual(initialClient) +}) + +function Parent() { + const [renderCount, setRenderCount] = React.useState(1) + + const { connectors, connect } = useConnect() + const { address } = useAccount() + const { data } = useWalletClient() + + return ( + <> +
{address}
+
{data?.uid}
+ + + + + + ) +} + +function Child(props: { + renderCount: number +}) { + const { renderCount } = props + const { data } = useWalletClient() + return ( +
+ {data?.uid} + {renderCount} +
+ ) +} diff --git a/packages/react/src/hooks/useWalletClient.ts b/packages/react/src/hooks/useWalletClient.ts new file mode 100644 index 0000000000..24a3bccdda --- /dev/null +++ b/packages/react/src/hooks/useWalletClient.ts @@ -0,0 +1,116 @@ +'use client' + +// Almost identical implementation to `useConnectorClient` (except for return type) +// Should update both in tandem + +import { useQueryClient } from '@tanstack/react-query' +import type { + Config, + GetWalletClientErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute, Omit } from '@wagmi/core/internal' +import { + type GetWalletClientData, + type GetWalletClientOptions, + type GetWalletClientQueryFnData, + type GetWalletClientQueryKey, + getWalletClientQueryOptions, +} from '@wagmi/core/query' +import { useEffect, useRef } from 'react' + +import type { ConfigParameter } from '../types/properties.js' +import { + type UseQueryParameters, + type UseQueryReturnType, + useQuery, +} from '../utils/query.js' +import { useAccount } from './useAccount.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseWalletClientParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetWalletClientData, +> = Compute< + GetWalletClientOptions & + ConfigParameter & { + query?: + | Compute< + Omit< + UseQueryParameters< + GetWalletClientQueryFnData, + GetWalletClientErrorType, + selectData, + GetWalletClientQueryKey + >, + 'gcTime' | 'staleTime' + > + > + | undefined + } +> + +export type UseWalletClientReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetWalletClientData, +> = UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useWalletClient */ +export function useWalletClient< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetWalletClientData, +>( + parameters: UseWalletClientParameters = {}, +): UseWalletClientReturnType { + const { query = {}, ...rest } = parameters + + const config = useConfig(rest) + const queryClient = useQueryClient() + const { address, connector, status } = useAccount({ config }) + const chainId = useChainId({ config }) + const activeConnector = parameters.connector ?? connector + + const { queryKey, ...options } = getWalletClientQueryOptions( + config, + { + ...parameters, + chainId: parameters.chainId ?? chainId, + connector: parameters.connector ?? connector, + }, + ) + const enabled = Boolean( + (status === 'connected' || + (status === 'reconnecting' && activeConnector?.getProvider)) && + (query.enabled ?? true), + ) + + const addressRef = useRef(address) + // biome-ignore lint/correctness/useExhaustiveDependencies: `queryKey` not required + useEffect(() => { + const previousAddress = addressRef.current + if (!address && previousAddress) { + // remove when account is disconnected + queryClient.removeQueries({ queryKey }) + addressRef.current = undefined + } else if (address !== previousAddress) { + // invalidate when address changes + queryClient.invalidateQueries({ queryKey }) + addressRef.current = address + } + }, [address, queryClient]) + + return useQuery({ + ...query, + ...options, + queryKey, + enabled, + staleTime: Number.POSITIVE_INFINITY, + } as any) as UseWalletClientReturnType +} diff --git a/packages/react/src/hooks/useWatchAsset.test-d.ts b/packages/react/src/hooks/useWatchAsset.test-d.ts new file mode 100644 index 0000000000..0b7258c583 --- /dev/null +++ b/packages/react/src/hooks/useWatchAsset.test-d.ts @@ -0,0 +1,66 @@ +import type { WatchAssetErrorType } from '@wagmi/core' +import type { WatchAssetVariables } from '@wagmi/core/query' +import { expectTypeOf, test } from 'vitest' + +import { useWatchAsset } from './useWatchAsset.js' + +const tokenInfo = { + address: '0x0000000000000000000000000000000000000000', + symbol: 'NULL', + decimals: 18, +} +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { context, data, error, watchAsset, variables } = useWatchAsset({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + watchAsset( + { type: 'ERC20', options: tokenInfo }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/react/src/hooks/useWatchAsset.test.ts b/packages/react/src/hooks/useWatchAsset.test.ts new file mode 100644 index 0000000000..989b0323c8 --- /dev/null +++ b/packages/react/src/hooks/useWatchAsset.test.ts @@ -0,0 +1,27 @@ +import { connect, disconnect } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useWatchAsset } from './useWatchAsset.js' + +const connector = config.connectors[0]! + +const tokenInfo = { + address: '0x0000000000000000000000000000000000000000', + symbol: 'NULL', + decimals: 18, +} + +test('default', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useWatchAsset()) + + result.current.watchAsset({ type: 'ERC20', options: tokenInfo }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current.data).toEqual(true) + + await disconnect(config, { connector }) +}) diff --git a/packages/react/src/hooks/useWatchAsset.ts b/packages/react/src/hooks/useWatchAsset.ts new file mode 100644 index 0000000000..cda4d6b0be --- /dev/null +++ b/packages/react/src/hooks/useWatchAsset.ts @@ -0,0 +1,65 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { WatchAssetErrorType } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type WatchAssetData, + type WatchAssetMutate, + type WatchAssetMutateAsync, + type WatchAssetVariables, + watchAssetMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseWatchAssetParameters = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + WatchAssetData, + WatchAssetErrorType, + WatchAssetVariables, + context + > + | undefined + } +> + +export type UseWatchAssetReturnType = Compute< + UseMutationReturnType< + WatchAssetData, + WatchAssetErrorType, + WatchAssetVariables, + context + > & { + watchAsset: WatchAssetMutate + watchAssetAsync: WatchAssetMutateAsync + } +> + +/** https://wagmi.sh/react/api/hooks/useWatchAsset */ +export function useWatchAsset( + parameters: UseWatchAssetParameters = {}, +): UseWatchAssetReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = watchAssetMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + return { + ...result, + watchAsset: mutate, + watchAssetAsync: mutateAsync, + } +} diff --git a/packages/react/src/hooks/useWatchBlockNumber.test-d.ts b/packages/react/src/hooks/useWatchBlockNumber.test-d.ts new file mode 100644 index 0000000000..0d669725bc --- /dev/null +++ b/packages/react/src/hooks/useWatchBlockNumber.test-d.ts @@ -0,0 +1,71 @@ +import { createConfig } from '@wagmi/core' +import { http, webSocket } from 'viem' +import { mainnet, optimism } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { + type UseWatchBlockNumberParameters, + useWatchBlockNumber, +} from './useWatchBlockNumber.js' + +test('default', () => { + useWatchBlockNumber({ + poll: false, + onBlockNumber() {}, + }) +}) + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + type Result = UseWatchBlockNumberParameters< + typeof config, + typeof mainnet.id | typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + useWatchBlockNumber({ + config, + poll: false, + onBlockNumber() {}, + }) + + type Result2 = UseWatchBlockNumberParameters + expectTypeOf().toEqualTypeOf() + useWatchBlockNumber({ + config, + chainId: mainnet.id, + poll: true, + onBlockNumber() {}, + }) + useWatchBlockNumber({ + config, + chainId: mainnet.id, + // @ts-expect-error + poll: false, + onBlockNumber() {}, + }) + + type Result3 = UseWatchBlockNumberParameters< + typeof config, + typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + useWatchBlockNumber({ + config, + chainId: optimism.id, + poll: true, + onBlockNumber() {}, + }) + useWatchBlockNumber({ + config, + chainId: optimism.id, + poll: false, + onBlockNumber() {}, + }) +}) diff --git a/packages/react/src/hooks/useWatchBlockNumber.test.ts b/packages/react/src/hooks/useWatchBlockNumber.test.ts new file mode 100644 index 0000000000..ecb900b357 --- /dev/null +++ b/packages/react/src/hooks/useWatchBlockNumber.test.ts @@ -0,0 +1,28 @@ +import { testClient, wait } from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useWatchBlockNumber } from './useWatchBlockNumber.js' + +test('default', async () => { + const blockNumbers: bigint[] = [] + renderHook(() => + useWatchBlockNumber({ + onBlockNumber(blockNumber) { + blockNumbers.push(blockNumber) + }, + }), + ) + + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + + expect(blockNumbers.length).toBe(3) + expect( + blockNumbers.map((blockNumber) => blockNumber - blockNumbers[0]!), + ).toEqual([0n, 1n, 2n]) +}) diff --git a/packages/react/src/hooks/useWatchBlockNumber.ts b/packages/react/src/hooks/useWatchBlockNumber.ts new file mode 100644 index 0000000000..33ddac48a6 --- /dev/null +++ b/packages/react/src/hooks/useWatchBlockNumber.ts @@ -0,0 +1,65 @@ +'use client' + +import { + type Config, + type ResolvedRegister, + type WatchBlockNumberParameters, + watchBlockNumber, +} from '@wagmi/core' +import type { UnionCompute, UnionExactPartial } from '@wagmi/core/internal' +import { useEffect } from 'react' + +import type { ConfigParameter, EnabledParameter } from '../types/properties.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseWatchBlockNumberParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = UnionCompute< + UnionExactPartial> & + ConfigParameter & + EnabledParameter +> + +export type UseWatchBlockNumberReturnType = void + +/** https://wagmi.sh/react/api/hooks/useWatchBlockNumber */ +export function useWatchBlockNumber< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + parameters: UseWatchBlockNumberParameters = {} as any, +): UseWatchBlockNumberReturnType { + const { enabled = true, onBlockNumber, config: _, ...rest } = parameters + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + const chainId = parameters.chainId ?? configChainId + + // TODO(react@19): cleanup + // biome-ignore lint/correctness/useExhaustiveDependencies: `rest` changes every render so only including properties in dependency array + useEffect(() => { + if (!enabled) return + if (!onBlockNumber) return + return watchBlockNumber(config, { + ...(rest as any), + chainId, + onBlockNumber, + }) + }, [ + chainId, + config, + enabled, + onBlockNumber, + /// + rest.onError, + rest.emitMissed, + rest.emitOnBegin, + rest.poll, + rest.pollingInterval, + rest.syncConnectedChain, + ]) +} diff --git a/packages/react/src/hooks/useWatchBlocks.test-d.ts b/packages/react/src/hooks/useWatchBlocks.test-d.ts new file mode 100644 index 0000000000..2051bfb66f --- /dev/null +++ b/packages/react/src/hooks/useWatchBlocks.test-d.ts @@ -0,0 +1,73 @@ +import { createConfig } from '@wagmi/core' +import { http, webSocket } from 'viem' +import { mainnet, optimism } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { + type UseWatchBlocksParameters, + useWatchBlocks, +} from './useWatchBlocks.js' + +test('default', () => { + useWatchBlocks({ + poll: false, + onBlock() {}, + }) +}) + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + type Result = UseWatchBlocksParameters< + false, + 'latest', + typeof config, + typeof mainnet.id | typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + useWatchBlocks({ + config, + poll: false, + onBlock() {}, + }) + + type Result2 = UseWatchBlocksParameters< + false, + 'latest', + typeof config, + typeof mainnet.id + > + expectTypeOf().toEqualTypeOf() + useWatchBlocks({ + config, + chainId: mainnet.id, + poll: true, + onBlock() {}, + }) + + type Result3 = UseWatchBlocksParameters< + false, + 'latest', + typeof config, + typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + useWatchBlocks({ + config, + chainId: optimism.id, + poll: true, + onBlock() {}, + }) + useWatchBlocks({ + config, + chainId: optimism.id, + poll: false, + onBlock() {}, + }) +}) diff --git a/packages/react/src/hooks/useWatchBlocks.test.ts b/packages/react/src/hooks/useWatchBlocks.test.ts new file mode 100644 index 0000000000..039c718834 --- /dev/null +++ b/packages/react/src/hooks/useWatchBlocks.test.ts @@ -0,0 +1,31 @@ +import { testClient, wait } from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import type { Block } from 'viem' +import { expect, test } from 'vitest' + +import { useWatchBlocks } from './useWatchBlocks.js' + +test('default', async () => { + const blocks: Block[] = [] + renderHook(() => + useWatchBlocks({ + onBlock(block) { + blocks.push(block) + }, + }), + ) + + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + + expect(blocks.length).toBe(3) + expect(blocks.map((block) => block.number! - blocks[0]!.number!)).toEqual([ + 0n, + 1n, + 2n, + ]) +}) diff --git a/packages/react/src/hooks/useWatchBlocks.ts b/packages/react/src/hooks/useWatchBlocks.ts new file mode 100644 index 0000000000..466929c841 --- /dev/null +++ b/packages/react/src/hooks/useWatchBlocks.ts @@ -0,0 +1,79 @@ +'use client' + +import { + type Config, + type ResolvedRegister, + type WatchBlocksParameters, + watchBlocks, +} from '@wagmi/core' +import type { UnionCompute, UnionExactPartial } from '@wagmi/core/internal' +import { useEffect } from 'react' +import type { BlockTag } from 'viem' + +import type { ConfigParameter, EnabledParameter } from '../types/properties.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseWatchBlocksParameters< + includeTransactions extends boolean = false, + blockTag extends BlockTag = 'latest', + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = UnionCompute< + UnionExactPartial< + WatchBlocksParameters + > & + ConfigParameter & + EnabledParameter +> + +export type UseWatchBlocksReturnType = void + +/** https://wagmi.sh/react/hooks/useWatchBlocks */ +export function useWatchBlocks< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + includeTransactions extends boolean = false, + blockTag extends BlockTag = 'latest', +>( + parameters: UseWatchBlocksParameters< + includeTransactions, + blockTag, + config, + chainId + > = {} as any, +): UseWatchBlocksReturnType { + const { enabled = true, onBlock, config: _, ...rest } = parameters + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + const chainId = parameters.chainId ?? configChainId + + // TODO(react@19): cleanup + // biome-ignore lint/correctness/useExhaustiveDependencies: `rest` changes every render so only including properties in dependency array + useEffect(() => { + if (!enabled) return + if (!onBlock) return + return watchBlocks(config, { + ...(rest as any), + chainId, + onBlock, + }) + }, [ + chainId, + config, + enabled, + onBlock, + /// + rest.blockTag, + rest.emitMissed, + rest.emitOnBegin, + rest.includeTransactions, + rest.onError, + rest.poll, + rest.pollingInterval, + rest.syncConnectedChain, + ]) +} diff --git a/packages/react/src/hooks/useWatchContractEvent.test-d.ts b/packages/react/src/hooks/useWatchContractEvent.test-d.ts new file mode 100644 index 0000000000..b1d74de450 --- /dev/null +++ b/packages/react/src/hooks/useWatchContractEvent.test-d.ts @@ -0,0 +1,128 @@ +import { http, createConfig, webSocket } from '@wagmi/core' +import { mainnet, optimism } from '@wagmi/core/chains' +import { abi } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { + type UseWatchContractEventParameters, + useWatchContractEvent, +} from './useWatchContractEvent.js' + +test('default', () => { + useWatchContractEvent({ + address: '0x', + abi: abi.erc20, + eventName: 'Transfer', + poll: false, + args: { + from: '0x', + to: '0x', + }, + onLogs(logs) { + expectTypeOf(logs[0]!.eventName).toEqualTypeOf<'Transfer'>() + expectTypeOf(logs[0]!.args).toEqualTypeOf<{ + from?: `0x${string}` | undefined + to?: `0x${string}` | undefined + value?: bigint | undefined + }>() + }, + }) +}) + +test('behavior: no eventName', () => { + useWatchContractEvent({ + address: '0x', + abi: abi.erc20, + args: { + // TODO: Figure out why this is not working + // @ts-ignore + from: '0x', + to: '0x', + }, + onLogs(logs) { + expectTypeOf(logs[0]!.eventName).toEqualTypeOf<'Transfer' | 'Approval'>() + expectTypeOf(logs[0]!.args).toEqualTypeOf< + | Record + | readonly unknown[] + | { + from?: `0x${string}` | undefined + to?: `0x${string}` | undefined + value?: bigint | undefined + } + | { + owner?: `0x${string}` | undefined + spender?: `0x${string}` | undefined + value?: bigint | undefined + } + >() + }, + }) +}) + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + type Result = UseWatchContractEventParameters< + typeof abi.erc20, + 'Transfer' | 'Approval', + true, + typeof config, + typeof mainnet.id | typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + useWatchContractEvent({ + config, + poll: false, + address: '0x', + abi: abi.erc20, + onLogs() {}, + }) + + type Result2 = UseWatchContractEventParameters< + typeof abi.erc20, + 'Transfer' | 'Approval', + true, + typeof config, + typeof mainnet.id + > + expectTypeOf().toEqualTypeOf() + useWatchContractEvent({ + config, + chainId: mainnet.id, + poll: true, + address: '0x', + abi: abi.erc20, + onLogs() {}, + }) + + type Result3 = UseWatchContractEventParameters< + typeof abi.erc20, + 'Transfer' | 'Approval', + true, + typeof config, + typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + useWatchContractEvent({ + config, + chainId: optimism.id, + poll: true, + address: '0x', + abi: abi.erc20, + onLogs() {}, + }) + useWatchContractEvent({ + config, + chainId: optimism.id, + poll: false, + address: '0x', + abi: abi.erc20, + onLogs() {}, + }) +}) diff --git a/packages/react/src/hooks/useWatchContractEvent.test.ts b/packages/react/src/hooks/useWatchContractEvent.test.ts new file mode 100644 index 0000000000..e6ad2aa1dc --- /dev/null +++ b/packages/react/src/hooks/useWatchContractEvent.test.ts @@ -0,0 +1,86 @@ +import { connect, disconnect, getBalance, writeContract } from '@wagmi/core' +import { + abi, + accounts, + address, + config, + testClient, + transactionHashRegex, + wait, +} from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import { http, createWalletClient, parseEther } from 'viem' +import type { WatchEventOnLogsParameter } from 'viem/actions' +import { expect, test } from 'vitest' + +import { useWatchContractEvent } from './useWatchContractEvent.js' + +const connector = config.connectors[0]! + +test('default', async () => { + const data = await connect(config, { connector }) + const connectedAddress = data.accounts[0] + + // impersonate usdc holder account and transfer usdc to connected account + await testClient.mainnet.impersonateAccount({ address: address.usdcHolder }) + await testClient.mainnet.setBalance({ + address: address.usdcHolder, + value: 10000000000000000000000n, + }) + await createWalletClient({ + account: address.usdcHolder, + chain: testClient.mainnet.chain, + transport: http(), + }).writeContract({ + address: address.usdc, + abi: abi.erc20, + functionName: 'transfer', + args: [connectedAddress, parseEther('10', 'gwei')], + }) + await testClient.mainnet.mine({ blocks: 1 }) + await testClient.mainnet.stopImpersonatingAccount({ + address: address.usdcHolder, + }) + + const balance = await getBalance(config, { + address: connectedAddress, + token: address.usdc, + }) + expect(balance.value).toBeGreaterThan(0n) + + // start watching transfer events + let logs: WatchEventOnLogsParameter = [] + renderHook(() => + useWatchContractEvent({ + address: address.usdc, + abi: abi.erc20, + eventName: 'Transfer', + onLogs(next) { + logs = logs.concat(next) + }, + }), + ) + + await writeContract(config, { + address: address.usdc, + abi: abi.erc20, + functionName: 'transfer', + args: [accounts[1], parseEther('1', 'gwei')], + }) + + await writeContract(config, { + address: address.usdc, + abi: abi.erc20, + functionName: 'transfer', + args: [accounts[3], parseEther('1', 'gwei')], + }) + + await testClient.mainnet.mine({ blocks: 1 }) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(1000) // wait for events to be emitted + + expect(logs.length).toBe(2) + expect(logs[0]?.transactionHash).toMatch(transactionHashRegex) + + await disconnect(config, { connector }) +}) diff --git a/packages/react/src/hooks/useWatchContractEvent.ts b/packages/react/src/hooks/useWatchContractEvent.ts new file mode 100644 index 0000000000..0d7710df2a --- /dev/null +++ b/packages/react/src/hooks/useWatchContractEvent.ts @@ -0,0 +1,85 @@ +'use client' + +import { + type Config, + type ResolvedRegister, + type WatchContractEventParameters, + watchContractEvent, +} from '@wagmi/core' +import type { UnionCompute, UnionExactPartial } from '@wagmi/core/internal' +import { useEffect } from 'react' +import type { Abi, ContractEventName } from 'viem' + +import type { ConfigParameter, EnabledParameter } from '../types/properties.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseWatchContractEventParameters< + abi extends Abi | readonly unknown[] = Abi, + eventName extends ContractEventName = ContractEventName, + strict extends boolean | undefined = undefined, + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = UnionCompute< + UnionExactPartial< + WatchContractEventParameters + > & + ConfigParameter & + EnabledParameter +> + +export type UseWatchContractEventReturnType = void + +/** https://wagmi.sh/react/api/hooks/useWatchContractEvent */ +export function useWatchContractEvent< + const abi extends Abi | readonly unknown[], + eventName extends ContractEventName, + strict extends boolean | undefined = undefined, + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + parameters: UseWatchContractEventParameters< + abi, + eventName, + strict, + config, + chainId + > = {} as any, +): UseWatchContractEventReturnType { + const { enabled = true, onLogs, config: _, ...rest } = parameters + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + const chainId = parameters.chainId ?? configChainId + + // TODO(react@19): cleanup + // biome-ignore lint/correctness/useExhaustiveDependencies: `rest` changes every render so only including properties in dependency array + useEffect(() => { + if (!enabled) return + if (!onLogs) return + return watchContractEvent(config, { + ...(rest as any), + chainId, + onLogs, + }) + }, [ + chainId, + config, + enabled, + onLogs, + /// + rest.abi, + rest.address, + rest.args, + rest.batch, + rest.eventName, + rest.fromBlock, + rest.onError, + rest.poll, + rest.pollingInterval, + rest.strict, + rest.syncConnectedChain, + ]) +} diff --git a/packages/react/src/hooks/useWatchPendingTransactions.test-d.ts b/packages/react/src/hooks/useWatchPendingTransactions.test-d.ts new file mode 100644 index 0000000000..56ccc49cbf --- /dev/null +++ b/packages/react/src/hooks/useWatchPendingTransactions.test-d.ts @@ -0,0 +1,67 @@ +import { createConfig } from '@wagmi/core' +import { http, webSocket } from 'viem' +import { mainnet, optimism } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import { + type UseWatchPendingTransactionsParameters, + useWatchPendingTransactions, +} from './useWatchPendingTransactions.js' + +test('default', () => { + useWatchPendingTransactions({ + poll: false, + onTransactions() {}, + }) +}) + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + type Result = UseWatchPendingTransactionsParameters< + typeof config, + typeof mainnet.id | typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + useWatchPendingTransactions({ + config, + poll: false, + onTransactions() {}, + }) + + type Result2 = UseWatchPendingTransactionsParameters< + typeof config, + typeof mainnet.id + > + expectTypeOf().toEqualTypeOf() + useWatchPendingTransactions({ + config, + chainId: mainnet.id, + poll: true, + onTransactions() {}, + }) + + type Result3 = UseWatchPendingTransactionsParameters< + typeof config, + typeof optimism.id + > + expectTypeOf().toEqualTypeOf() + useWatchPendingTransactions({ + config, + chainId: optimism.id, + poll: true, + onTransactions() {}, + }) + useWatchPendingTransactions({ + config, + chainId: optimism.id, + poll: false, + onTransactions() {}, + }) +}) diff --git a/packages/react/src/hooks/useWatchPendingTransactions.test.ts b/packages/react/src/hooks/useWatchPendingTransactions.test.ts new file mode 100644 index 0000000000..e1981f3fa1 --- /dev/null +++ b/packages/react/src/hooks/useWatchPendingTransactions.test.ts @@ -0,0 +1,49 @@ +import { connect, disconnect, sendTransaction } from '@wagmi/core' +import { + accounts, + config, + testClient, + transactionHashRegex, + wait, +} from '@wagmi/test' +import { renderHook } from '@wagmi/test/react' +import { parseEther } from 'viem' +import type { OnTransactionsParameter } from 'viem/actions' +import { expect, test } from 'vitest' + +import { useWatchPendingTransactions } from './useWatchPendingTransactions.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + let transactions: OnTransactionsParameter = [] + renderHook(() => + useWatchPendingTransactions({ + onTransactions(next) { + transactions = [...transactions, ...next] + }, + }), + ) + await wait(1000) + + await sendTransaction(config, { + to: accounts[1], + value: parseEther('1'), + }) + await wait(200) + + await sendTransaction(config, { + to: accounts[3], + value: parseEther('1'), + }) + await wait(200) + + await testClient.mainnet.mine({ blocks: 1 }) + + expect(transactions.length).toBe(2) + expect(transactions[0]).toMatch(transactionHashRegex) + + await disconnect(config, { connector }) +}) diff --git a/packages/react/src/hooks/useWatchPendingTransactions.ts b/packages/react/src/hooks/useWatchPendingTransactions.ts new file mode 100644 index 0000000000..7461ffcfb4 --- /dev/null +++ b/packages/react/src/hooks/useWatchPendingTransactions.ts @@ -0,0 +1,67 @@ +'use client' + +import { + type Config, + type ResolvedRegister, + type WatchPendingTransactionsParameters, + watchPendingTransactions, +} from '@wagmi/core' +import type { UnionCompute, UnionExactPartial } from '@wagmi/core/internal' +import { useEffect } from 'react' + +import type { ConfigParameter, EnabledParameter } from '../types/properties.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseWatchPendingTransactionsParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = UnionCompute< + UnionExactPartial> & + ConfigParameter & + EnabledParameter +> + +export type UseWatchPendingTransactionsReturnType = void + +/** https://wagmi.sh/react/api/hooks/useWatchPendingTransactions */ +export function useWatchPendingTransactions< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + parameters: UseWatchPendingTransactionsParameters< + config, + chainId + > = {} as any, +): UseWatchPendingTransactionsReturnType { + const { enabled = true, onTransactions, config: _, ...rest } = parameters + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + const chainId = parameters.chainId ?? configChainId + + // TODO(react@19): cleanup + // biome-ignore lint/correctness/useExhaustiveDependencies: `rest` changes every render so only including properties in dependency array + useEffect(() => { + if (!enabled) return + if (!onTransactions) return + return watchPendingTransactions(config, { + ...(rest as any), + chainId, + onTransactions, + }) + }, [ + chainId, + config, + enabled, + onTransactions, + /// + rest.batch, + rest.onError, + rest.poll, + rest.pollingInterval, + rest.syncConnectedChain, + ]) +} diff --git a/packages/react/src/hooks/useWriteContract.test-d.ts b/packages/react/src/hooks/useWriteContract.test-d.ts new file mode 100644 index 0000000000..344c11255b --- /dev/null +++ b/packages/react/src/hooks/useWriteContract.test-d.ts @@ -0,0 +1,185 @@ +import { http, type WriteContractErrorType, createConfig } from '@wagmi/core' +import { base } from '@wagmi/core/chains' +import { abi } from '@wagmi/test' +import type { Abi, Address, Hash } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { useSimulateContract } from './useSimulateContract.js' +import { useWriteContract } from './useWriteContract.js' + +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { + context, + data, + error, + writeContract: write, + variables, + } = useWriteContract({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: Abi + functionName: string + args?: readonly unknown[] | undefined + }>() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: Abi + functionName: string + args?: readonly unknown[] | undefined + }>() + }, + onSuccess(data, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: Abi + functionName: string + args?: readonly unknown[] | undefined + }>() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: Abi + functionName: string + args?: readonly unknown[] | undefined + }>() + }, + }, + }) + + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf< + { chainId?: number | undefined } | undefined + >() + expectTypeOf(context).toEqualTypeOf() + + write( + { + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 1, + }, + { + onError(error, variables, context) { + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: typeof abi.erc20 + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + }>() + }, + onSuccess(data, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables.functionName).toEqualTypeOf<'transferFrom'>() + expectTypeOf(variables.args).toEqualTypeOf< + readonly [Address, Address, bigint] + >() + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: typeof abi.erc20 + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + }>() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: typeof abi.erc20 + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + }>() + }, + }, + ) +}) + +test('useSimulateContract', () => { + const { data } = useSimulateContract({ + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 1, + }) + const { writeContract } = useWriteContract() + + const request = data?.request + if (request) writeContract(request) +}) + +// https://github.com/wevm/wagmi/issues/3981 +test('gh#3981', () => { + const config = createConfig({ + chains: [base], + transports: { + [base.id]: http(), + }, + }) + + const abi = [ + { + type: 'function', + name: 'example1', + inputs: [ + { name: 'exampleName', type: 'address', internalType: 'address' }, + ], + outputs: [], + stateMutability: 'payable', + }, + { + type: 'function', + name: 'example2', + inputs: [ + { name: 'exampleName', type: 'address', internalType: 'address' }, + ], + outputs: [], + stateMutability: 'nonpayable', + }, + ] as const + + const { writeContract } = useWriteContract({ config }) + writeContract({ + abi, + address: '0x...', + functionName: 'example1', + args: ['0x...'], + value: 123n, + }) + writeContract({ + abi, + address: '0x...', + functionName: 'example2', + args: ['0x...'], + // @ts-expect-error + value: 123n, + }) +}) diff --git a/packages/react/src/hooks/useWriteContract.test.ts b/packages/react/src/hooks/useWriteContract.test.ts new file mode 100644 index 0000000000..16ef870c2b --- /dev/null +++ b/packages/react/src/hooks/useWriteContract.test.ts @@ -0,0 +1,25 @@ +import { connect, disconnect } from '@wagmi/core' +import { abi, address, config } from '@wagmi/test' +import { renderHook, waitFor } from '@wagmi/test/react' +import { expect, test } from 'vitest' + +import { useWriteContract } from './useWriteContract.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const { result } = renderHook(() => useWriteContract()) + + result.current.writeContract({ + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }) + await waitFor(() => expect(result.current.isSuccess).toBeTruthy()) + + expect(result.current.data).toBeDefined() + + await disconnect(config, { connector }) +}) diff --git a/packages/react/src/hooks/useWriteContract.ts b/packages/react/src/hooks/useWriteContract.ts new file mode 100644 index 0000000000..b07e856c93 --- /dev/null +++ b/packages/react/src/hooks/useWriteContract.ts @@ -0,0 +1,87 @@ +'use client' + +import { useMutation } from '@tanstack/react-query' +import type { + Config, + ResolvedRegister, + WriteContractErrorType, +} from '@wagmi/core' +import { + type WriteContractData, + type WriteContractMutate, + type WriteContractMutateAsync, + type WriteContractVariables, + writeContractMutationOptions, +} from '@wagmi/core/query' +import type { Abi } from 'viem' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseWriteContractParameters< + config extends Config = Config, + context = unknown, +> = ConfigParameter & { + mutation?: + | UseMutationParameters< + WriteContractData, + WriteContractErrorType, + WriteContractVariables< + Abi, + string, + readonly unknown[], + config, + config['chains'][number]['id'] + >, + context + > + | undefined +} + +export type UseWriteContractReturnType< + config extends Config = Config, + context = unknown, +> = UseMutationReturnType< + WriteContractData, + WriteContractErrorType, + WriteContractVariables< + Abi, + string, + readonly unknown[], + config, + config['chains'][number]['id'] + >, + context +> & { + writeContract: WriteContractMutate + writeContractAsync: WriteContractMutateAsync +} + +/** https://wagmi.sh/react/api/hooks/useWriteContract */ +export function useWriteContract< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseWriteContractParameters = {}, +): UseWriteContractReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = writeContractMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + type Return = UseWriteContractReturnType + return { + ...result, + writeContract: mutate as Return['writeContract'], + writeContractAsync: mutateAsync as Return['writeContractAsync'], + } +} diff --git a/packages/react/src/hydrate.ts b/packages/react/src/hydrate.ts new file mode 100644 index 0000000000..b185929c22 --- /dev/null +++ b/packages/react/src/hydrate.ts @@ -0,0 +1,36 @@ +'use client' + +import { type ResolvedRegister, type State, hydrate } from '@wagmi/core' +import { type ReactElement, useEffect, useRef } from 'react' + +export type HydrateProps = { + config: ResolvedRegister['config'] + initialState?: State | undefined + reconnectOnMount?: boolean | undefined +} + +export function Hydrate(parameters: React.PropsWithChildren) { + const { children, config, initialState, reconnectOnMount = true } = parameters + + const { onMount } = hydrate(config, { + initialState, + reconnectOnMount, + }) + + // Hydrate for non-SSR + if (!config._internal.ssr) onMount() + + // Hydrate for SSR + const active = useRef(true) + // biome-ignore lint/correctness/useExhaustiveDependencies: `queryKey` not required + useEffect(() => { + if (!active.current) return + if (!config._internal.ssr) return + onMount() + return () => { + active.current = false + } + }, []) + + return children as ReactElement +} diff --git a/packages/react/src/types/properties.ts b/packages/react/src/types/properties.ts new file mode 100644 index 0000000000..7d903faf0a --- /dev/null +++ b/packages/react/src/types/properties.ts @@ -0,0 +1,51 @@ +import type { DefaultError, QueryKey } from '@tanstack/react-query' +import type { Config } from '@wagmi/core' +import type { Omit } from '@wagmi/core/internal' + +import type { + UseInfiniteQueryParameters, + UseQueryParameters, +} from '../utils/query.js' + +export type EnabledParameter = { + enabled?: boolean | undefined +} + +export type ConfigParameter = { + config?: Config | config | undefined +} + +export type QueryParameter< + queryFnData = unknown, + error = DefaultError, + data = queryFnData, + queryKey extends QueryKey = QueryKey, +> = { + query?: + | Omit< + UseQueryParameters, + 'queryFn' | 'queryHash' | 'queryKey' | 'queryKeyHashFn' | 'throwOnError' + > + | undefined +} + +export type InfiniteQueryParameter< + queryFnData = unknown, + error = DefaultError, + data = queryFnData, + queryData = queryFnData, + queryKey extends QueryKey = QueryKey, + pageParam = unknown, +> = { + query: Omit< + UseInfiniteQueryParameters< + queryFnData, + error, + data, + queryData, + queryKey, + pageParam + >, + 'queryFn' | 'queryHash' | 'queryKey' | 'queryKeyHashFn' | 'throwOnError' + > +} diff --git a/packages/react/src/utils/getVersion.test.ts b/packages/react/src/utils/getVersion.test.ts new file mode 100644 index 0000000000..e8368facea --- /dev/null +++ b/packages/react/src/utils/getVersion.test.ts @@ -0,0 +1,7 @@ +import { expect, test } from 'vitest' + +import { getVersion } from './getVersion.js' + +test('default', () => { + expect(getVersion()).toMatchInlineSnapshot(`"wagmi@x.y.z"`) +}) diff --git a/packages/react/src/utils/getVersion.ts b/packages/react/src/utils/getVersion.ts new file mode 100644 index 0000000000..1a8a9437b3 --- /dev/null +++ b/packages/react/src/utils/getVersion.ts @@ -0,0 +1,3 @@ +import { version } from '../version.js' + +export const getVersion = () => `wagmi@${version}` diff --git a/packages/react/src/utils/query.ts b/packages/react/src/utils/query.ts new file mode 100644 index 0000000000..3aafb16123 --- /dev/null +++ b/packages/react/src/utils/query.ts @@ -0,0 +1,145 @@ +import { + type DefaultError, + type QueryKey, + type UseInfiniteQueryOptions, + type UseInfiniteQueryResult, + type UseMutationOptions, + type UseMutationResult, + type UseQueryOptions, + type UseQueryResult, + useInfiniteQuery as tanstack_useInfiniteQuery, + useQuery as tanstack_useQuery, + useMutation, +} from '@tanstack/react-query' +import type { + Compute, + ExactPartial, + Omit, + UnionStrictOmit, +} from '@wagmi/core/internal' +import { hashFn } from '@wagmi/core/query' + +export type UseMutationParameters< + data = unknown, + error = Error, + variables = void, + context = unknown, +> = Compute< + Omit< + UseMutationOptions, context>, + 'mutationFn' | 'mutationKey' | 'throwOnError' + > +> + +export type UseMutationReturnType< + data = unknown, + error = Error, + variables = void, + context = unknown, +> = Compute< + UnionStrictOmit< + UseMutationResult, + 'mutate' | 'mutateAsync' + > +> + +export { useMutation } + +//////////////////////////////////////////////////////////////////////////////// + +export type UseQueryParameters< + queryFnData = unknown, + error = DefaultError, + data = queryFnData, + queryKey extends QueryKey = QueryKey, +> = Compute< + ExactPartial< + Omit, 'initialData'> + > & { + // Fix `initialData` type + initialData?: + | UseQueryOptions['initialData'] + | undefined + } +> + +export type UseQueryReturnType = Compute< + UseQueryResult & { + queryKey: QueryKey + } +> + +// Adding some basic customization. +// Ideally we don't have this function, but `import('@tanstack/react-query').useQuery` currently has some quirks where it is super hard to +// pass down the inferred `initialData` type because of it's discriminated overload in the on `useQuery`. +export function useQuery( + parameters: UseQueryParameters & { + queryKey: QueryKey + }, +): UseQueryReturnType { + const result = tanstack_useQuery({ + ...(parameters as any), + queryKeyHashFn: hashFn, // for bigint support + }) as UseQueryReturnType + result.queryKey = parameters.queryKey + return result +} + +//////////////////////////////////////////////////////////////////////////////// + +export type UseInfiniteQueryParameters< + queryFnData = unknown, + error = DefaultError, + data = queryFnData, + queryData = queryFnData, + queryKey extends QueryKey = QueryKey, + pageParam = unknown, +> = Compute< + Omit< + UseInfiniteQueryOptions< + queryFnData, + error, + data, + queryData, + queryKey, + pageParam + >, + 'initialData' + > & { + // Fix `initialData` type + initialData?: + | UseInfiniteQueryOptions< + queryFnData, + error, + data, + queryKey + >['initialData'] + | undefined + } +> + +export type UseInfiniteQueryReturnType< + data = unknown, + error = DefaultError, +> = UseInfiniteQueryResult & { + queryKey: QueryKey +} + +// Adding some basic customization. +export function useInfiniteQuery< + queryFnData, + error, + data, + queryKey extends QueryKey, +>( + parameters: UseInfiniteQueryParameters & { + queryKey: QueryKey + }, +): UseInfiniteQueryReturnType { + const result = tanstack_useInfiniteQuery({ + ...(parameters as any), + queryKeyHashFn: hashFn, // for bigint support + }) as UseInfiniteQueryReturnType + result.queryKey = parameters.queryKey + return result +} diff --git a/packages/react/src/version.ts b/packages/react/src/version.ts new file mode 100644 index 0000000000..0ec209c466 --- /dev/null +++ b/packages/react/src/version.ts @@ -0,0 +1 @@ +export const version = '2.15.4' diff --git a/packages/react/test/setup.ts b/packages/react/test/setup.ts new file mode 100644 index 0000000000..5c0dcc071d --- /dev/null +++ b/packages/react/test/setup.ts @@ -0,0 +1,8 @@ +import { vi } from 'vitest' + +// Make dates stable across runs +Date.now = vi.fn(() => new Date(Date.UTC(2023, 1, 1)).valueOf()) + +vi.mock('../src/version.ts', () => { + return { version: 'x.y.z' } +}) diff --git a/packages/react/tsconfig.build.json b/packages/react/tsconfig.build.json new file mode 100644 index 0000000000..fbed2b1036 --- /dev/null +++ b/packages/react/tsconfig.build.json @@ -0,0 +1,8 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["src/**/*.ts"], + "exclude": ["src/**/*.test.ts", "src/**/*.test-d.ts"], + "compilerOptions": { + "sourceMap": true + } +} diff --git a/packages/react/tsconfig.json b/packages/react/tsconfig.json new file mode 100644 index 0000000000..1b247fdd49 --- /dev/null +++ b/packages/react/tsconfig.json @@ -0,0 +1,8 @@ +{ + "extends": "./tsconfig.build.json", + "compilerOptions": { + "jsx": "preserve" + }, + "include": ["src/**/*.ts", "src/**/*.tsx", "test/**/*.ts", "test/**/*.tsx"], + "exclude": [] +} diff --git a/packages/register-tests/react/package.json b/packages/register-tests/react/package.json new file mode 100644 index 0000000000..769092f959 --- /dev/null +++ b/packages/register-tests/react/package.json @@ -0,0 +1,16 @@ +{ + "name": "react-register", + "private": true, + "type": "module", + "scripts": { + "check:types": "tsc --noEmit" + }, + "dependencies": { + "@tanstack/react-query": "catalog:", + "react": "catalog:", + "wagmi": "workspace:*" + }, + "devDependencies": { + "@types/react": "catalog:" + } +} diff --git a/packages/register-tests/react/src/config.ts b/packages/register-tests/react/src/config.ts new file mode 100644 index 0000000000..5772212c1b --- /dev/null +++ b/packages/register-tests/react/src/config.ts @@ -0,0 +1,26 @@ +import { http } from 'viem' +import { createConfig, mock } from 'wagmi' +import { celo, mainnet, optimism, zkSync } from 'wagmi/chains' + +export const config = createConfig({ + chains: [celo, mainnet, optimism, zkSync], + connectors: [mock({ accounts: ['0x'] })], + transports: { + [celo.id]: http(), + [mainnet.id]: http(), + [optimism.id]: http(), + [zkSync.id]: http(), + }, +}) + +export type ChainId = + | typeof celo.id + | typeof mainnet.id + | typeof optimism.id + | typeof zkSync.id + +declare module 'wagmi' { + interface Register { + config: typeof config + } +} diff --git a/packages/register-tests/react/src/createUseSimulateContract.test-d.ts b/packages/register-tests/react/src/createUseSimulateContract.test-d.ts new file mode 100644 index 0000000000..b469ccd024 --- /dev/null +++ b/packages/register-tests/react/src/createUseSimulateContract.test-d.ts @@ -0,0 +1,39 @@ +import { abi, config as testConfig } from '@wagmi/test' +import { test } from 'vitest' +import { celo, mainnet, optimism } from 'wagmi/chains' +import { createUseSimulateContract } from 'wagmi/codegen' + +const useSimulateErc20 = createUseSimulateContract({ + abi: abi.erc20, +}) + +test('chain formatters', () => { + useSimulateErc20({ + feeCurrency: '0x', + }) + + useSimulateErc20({ + chainId: celo.id, + feeCurrency: '0x', + }) + + useSimulateErc20({ + chainId: mainnet.id, + // @ts-expect-error + feeCurrency: '0x', + }) + + useSimulateErc20({ + chainId: optimism.id, + // @ts-expect-error + feeCurrency: '0x', + }) +}) + +test('parameters: config', async () => { + useSimulateErc20({ + config: testConfig, + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/register-tests/react/src/createUseWriteContract.test-d.ts b/packages/register-tests/react/src/createUseWriteContract.test-d.ts new file mode 100644 index 0000000000..0b6c538130 --- /dev/null +++ b/packages/register-tests/react/src/createUseWriteContract.test-d.ts @@ -0,0 +1,66 @@ +import { abi, config } from '@wagmi/test' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' +import { celo, mainnet, optimism } from 'wagmi/chains' +import { createUseWriteContract } from 'wagmi/codegen' + +const useWriteErc20 = createUseWriteContract({ + abi: abi.erc20, +}) + +test('chain formatters', () => { + const { writeContract } = useWriteErc20() + const shared = { + address: '0x', + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + } as const + + writeContract({ + ...shared, + feeCurrency: '0x', + }) + + type Result = Parameters< + typeof writeContract< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof celo.id + > + >[0] + expectTypeOf().toEqualTypeOf< + `0x${string}` | undefined + >() + writeContract({ + ...shared, + chainId: celo.id, + feeCurrency: '0x', + }) + + writeContract({ + ...shared, + chainId: mainnet.id, + // @ts-expect-error + feeCurrency: '0x', + }) + + writeContract({ + ...shared, + chainId: optimism.id, + // @ts-expect-error + feeCurrency: '0x', + }) +}) + +test('parameters: config', async () => { + const { writeContract } = useWriteErc20({ config }) + + writeContract({ + address: '0x', + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/register-tests/react/src/useAccount.test-d.ts b/packages/register-tests/react/src/useAccount.test-d.ts new file mode 100644 index 0000000000..be563933a6 --- /dev/null +++ b/packages/register-tests/react/src/useAccount.test-d.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' +import { useAccount } from 'wagmi' + +import type { ChainId } from './config.js' + +test('default', () => { + const result = useAccount() + if (result.chain) expectTypeOf(result.chain.id).toEqualTypeOf() +}) + +test('parameters: config', async () => { + const result = useAccount({ config }) + if (result.chain) expectTypeOf(result.chain.id).toEqualTypeOf<1 | 10 | 456>() +}) diff --git a/packages/register-tests/react/src/useBlock.test-d.ts b/packages/register-tests/react/src/useBlock.test-d.ts new file mode 100644 index 0000000000..5f583a63e6 --- /dev/null +++ b/packages/register-tests/react/src/useBlock.test-d.ts @@ -0,0 +1,27 @@ +import type { Hex } from 'viem' +import { expectTypeOf, test } from 'vitest' +import { useBlock } from 'wagmi' +import { celo } from 'wagmi/chains' + +test('chain formatters', () => { + const result = useBlock() + + if (result.data) expectTypeOf(result.data.difficulty).toEqualTypeOf() + + if (result.data?.chainId === celo.id) { + expectTypeOf(result.data.difficulty).toEqualTypeOf() + expectTypeOf(result.data.gasLimit).toEqualTypeOf() + expectTypeOf(result.data.mixHash).toEqualTypeOf() + expectTypeOf(result.data.nonce).toEqualTypeOf<`0x${string}`>() + expectTypeOf(result.data.uncles).toEqualTypeOf() + } + + const result2 = useBlock({ chainId: celo.id }) + if (result2.data) { + expectTypeOf(result2.data.difficulty).toEqualTypeOf() + expectTypeOf(result2.data.gasLimit).toEqualTypeOf() + expectTypeOf(result2.data.mixHash).toEqualTypeOf() + expectTypeOf(result2.data.nonce).toEqualTypeOf<`0x${string}`>() + expectTypeOf(result2.data.uncles).toEqualTypeOf() + } +}) diff --git a/packages/register-tests/react/src/useChainId.test-d.ts b/packages/register-tests/react/src/useChainId.test-d.ts new file mode 100644 index 0000000000..d1a8e035d6 --- /dev/null +++ b/packages/register-tests/react/src/useChainId.test-d.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' +import { useChainId } from 'wagmi' + +import type { ChainId } from './config.js' + +test('default', async () => { + const chainId = useChainId() + expectTypeOf(chainId).toEqualTypeOf() +}) + +test('parameters: config', async () => { + const chainId = useChainId({ config }) + expectTypeOf(chainId).toEqualTypeOf<1 | 456 | 10>() +}) diff --git a/packages/register-tests/react/src/useChains.test-d.ts b/packages/register-tests/react/src/useChains.test-d.ts new file mode 100644 index 0000000000..c40fd5e1d2 --- /dev/null +++ b/packages/register-tests/react/src/useChains.test-d.ts @@ -0,0 +1,11 @@ +import { expectTypeOf, test } from 'vitest' +import { useChains } from 'wagmi' +import type { Chain, celo, optimism } from 'wagmi/chains' + +test('default', () => { + const chains = useChains() + + expectTypeOf(chains[0]).toEqualTypeOf() + expectTypeOf(chains[2]).toEqualTypeOf() + expectTypeOf(chains[5]).toEqualTypeOf() +}) diff --git a/packages/register-tests/react/src/useClient.test-d.ts b/packages/register-tests/react/src/useClient.test-d.ts new file mode 100644 index 0000000000..0ce810b31c --- /dev/null +++ b/packages/register-tests/react/src/useClient.test-d.ts @@ -0,0 +1,38 @@ +import { type chain, config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' +import { useClient } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +import type { ChainId } from './config.js' + +test('default', () => { + const client = useClient() + expectTypeOf(client.chain.id).toEqualTypeOf() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('parameters: config', () => { + const client = useClient({ config }) + expectTypeOf(client.chain.id).toEqualTypeOf< + (typeof config)['chains'][number]['id'] + >() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('parameters: chainId', () => { + const client = useClient({ + config, + chainId: mainnet.id, + }) + expectTypeOf(client.chain).toEqualTypeOf() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('behavior: unconfigured chain', () => { + const client = useClient({ + config, + // @ts-expect-error + chainId: 123456, + }) + expectTypeOf(client).toEqualTypeOf() +}) diff --git a/packages/register-tests/react/src/useConfig.test-d.ts b/packages/register-tests/react/src/useConfig.test-d.ts new file mode 100644 index 0000000000..25eb5246de --- /dev/null +++ b/packages/register-tests/react/src/useConfig.test-d.ts @@ -0,0 +1,17 @@ +import { config as testConfig } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' +import { type Config, useConfig } from 'wagmi' + +import type { config } from './config.js' + +test('default', async () => { + const result = useConfig() + expectTypeOf(result).not.toEqualTypeOf() + expectTypeOf(result).toEqualTypeOf() +}) + +test('parameters: config', async () => { + const result = useConfig({ config: testConfig }) + expectTypeOf(result).not.toEqualTypeOf() + expectTypeOf(result).toEqualTypeOf() +}) diff --git a/packages/register-tests/react/src/useConnect.test-d.ts b/packages/register-tests/react/src/useConnect.test-d.ts new file mode 100644 index 0000000000..2386dca7e9 --- /dev/null +++ b/packages/register-tests/react/src/useConnect.test-d.ts @@ -0,0 +1,13 @@ +import { expectTypeOf, test } from 'vitest' +import { useConnect } from 'wagmi' + +test('infers connect parameters', () => { + const { connect, connectors, variables } = useConnect() + const connector = connectors[0]! + + expectTypeOf(variables?.foo).toEqualTypeOf() + connect({ + connector, + foo: 'bar', + }) +}) diff --git a/packages/register-tests/react/src/usePrepareTransactionRequest.test-d.ts b/packages/register-tests/react/src/usePrepareTransactionRequest.test-d.ts new file mode 100644 index 0000000000..460408515c --- /dev/null +++ b/packages/register-tests/react/src/usePrepareTransactionRequest.test-d.ts @@ -0,0 +1,42 @@ +import { config as testConfig } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' +import { usePrepareTransactionRequest } from 'wagmi' +import { celo, mainnet, optimism } from 'wagmi/chains' + +test('chain formatters', () => { + const { data } = usePrepareTransactionRequest({ + feeCurrency: '0x', + }) + if (data && data.chainId === celo.id) { + expectTypeOf(data.feeCurrency).toEqualTypeOf<`0x${string}` | undefined>() + } + + const { data: data2 } = usePrepareTransactionRequest({ + chainId: celo.id, + feeCurrency: '0x', + }) + if (data2) { + expectTypeOf(data2.chainId).toEqualTypeOf(celo.id) + expectTypeOf(data2.feeCurrency).toEqualTypeOf<`0x${string}` | undefined>() + } + + usePrepareTransactionRequest({ + chainId: mainnet.id, + // @ts-expect-error + feeCurrency: '0x', + }) + + usePrepareTransactionRequest({ + chainId: optimism.id, + // @ts-expect-error + feeCurrency: '0x', + }) +}) + +test('parameters: config', async () => { + usePrepareTransactionRequest({ + config: testConfig, + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/register-tests/react/src/usePublicClient.ts b/packages/register-tests/react/src/usePublicClient.ts new file mode 100644 index 0000000000..55c6967ab2 --- /dev/null +++ b/packages/register-tests/react/src/usePublicClient.ts @@ -0,0 +1,38 @@ +import { type chain, config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' +import { usePublicClient } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +import type { ChainId } from './config.js' + +test('default', () => { + const client = usePublicClient() + expectTypeOf(client.chain.id).toEqualTypeOf() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('parameters: config', () => { + const client = usePublicClient({ config }) + expectTypeOf(client.chain.id).toEqualTypeOf< + (typeof config)['chains'][number]['id'] + >() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('parameters: chainId', () => { + const client = usePublicClient({ + config, + chainId: mainnet.id, + }) + expectTypeOf(client.chain).toEqualTypeOf() + expectTypeOf(client.transport.type).toEqualTypeOf<'http'>() +}) + +test('behavior: unconfigured chain', () => { + const client = usePublicClient({ + config, + // @ts-expect-error + chainId: 123456, + }) + expectTypeOf(client).toEqualTypeOf() +}) diff --git a/packages/register-tests/react/src/useReadContract.test-d.ts b/packages/register-tests/react/src/useReadContract.test-d.ts new file mode 100644 index 0000000000..02ca83ed64 --- /dev/null +++ b/packages/register-tests/react/src/useReadContract.test-d.ts @@ -0,0 +1,24 @@ +import type { abi } from '@wagmi/test' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' +import type { useReadContract } from 'wagmi' + +import type { ChainId } from './config.js' + +test('UseReadContractParameters', () => { + type Result = NonNullable< + Parameters>[0] + > + expectTypeOf().toMatchTypeOf<{ + functionName?: + | 'symbol' + | 'name' + | 'allowance' + | 'balanceOf' + | 'decimals' + | 'totalSupply' + | undefined + args?: readonly [Address] | undefined + chainId?: ChainId | undefined + }>() +}) diff --git a/packages/register-tests/react/src/useReadContracts.test-d.ts b/packages/register-tests/react/src/useReadContracts.test-d.ts new file mode 100644 index 0000000000..bb719b7c49 --- /dev/null +++ b/packages/register-tests/react/src/useReadContracts.test-d.ts @@ -0,0 +1,45 @@ +import type { abi } from '@wagmi/test' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' +import type { useReadContracts } from 'wagmi' + +import type { ChainId } from './config.js' + +test('UseReadContractsParameters', () => { + type Result = NonNullable< + Parameters< + typeof useReadContracts< + [ + { + abi: typeof abi.erc20 + functionName: 'balanceOf' + address: Address + args: readonly [Address] + }, + ] + > + >[0] + >['contracts'] + expectTypeOf().toMatchTypeOf< + | readonly [ + { + abi?: typeof abi.erc20 | undefined + functionName?: + | 'approve' + | 'symbol' + | 'name' + | 'allowance' + | 'balanceOf' + | 'decimals' + | 'totalSupply' + | 'transfer' + | 'transferFrom' + | undefined + address?: Address | undefined + args?: readonly [Address] | undefined + chainId?: ChainId | undefined + }, + ] + | undefined + >() +}) diff --git a/packages/register-tests/react/src/useSendTransaction.test-d.ts b/packages/register-tests/react/src/useSendTransaction.test-d.ts new file mode 100644 index 0000000000..60839f5023 --- /dev/null +++ b/packages/register-tests/react/src/useSendTransaction.test-d.ts @@ -0,0 +1,55 @@ +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' +import { useSendTransaction } from 'wagmi' +import { celo, mainnet, optimism } from 'wagmi/chains' +import type { ChainId } from './config.js' + +test('chain formatters', () => { + const { sendTransaction } = useSendTransaction() + + sendTransaction( + { + to: '0x', + feeCurrency: '0x', + }, + { + onSuccess(_data, variables) { + expectTypeOf(variables.chainId).toEqualTypeOf() + }, + }, + ) + + type Result = Parameters>[0] + expectTypeOf().toEqualTypeOf< + `0x${string}` | undefined + >() + sendTransaction({ + chainId: celo.id, + to: '0x', + feeCurrency: '0x', + }) + + sendTransaction({ + chainId: mainnet.id, + to: '0x', + // @ts-expect-error + feeCurrency: '0x', + }) + + sendTransaction({ + chainId: optimism.id, + to: '0x', + // @ts-expect-error + feeCurrency: '0x', + }) +}) + +test('parameters: config', async () => { + const { sendTransaction } = useSendTransaction({ config }) + + sendTransaction({ + to: '0x', + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/register-tests/react/src/useSimulateContract.test-d.ts b/packages/register-tests/react/src/useSimulateContract.test-d.ts new file mode 100644 index 0000000000..96c75d76e8 --- /dev/null +++ b/packages/register-tests/react/src/useSimulateContract.test-d.ts @@ -0,0 +1,94 @@ +import { type abi, config as testConfig } from '@wagmi/test' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' +import { type UseSimulateContractParameters, useSimulateContract } from 'wagmi' +import type { SimulateContractParameters } from 'wagmi/actions' +import { celo, mainnet, optimism } from 'wagmi/chains' +import type { SimulateContractOptions } from 'wagmi/query' + +import type { ChainId, config } from './config.js' + +test('chain formatters', () => { + const { data } = useSimulateContract({ + feeCurrency: '0x', + }) + if (data && data.chainId === celo.id) { + expectTypeOf(data.request.feeCurrency).toEqualTypeOf< + `0x${string}` | undefined + >() + } + + const { data: data2 } = useSimulateContract({ + chainId: celo.id, + feeCurrency: '0x', + }) + if (data2) { + expectTypeOf(data2.request.feeCurrency).toEqualTypeOf< + `0x${string}` | undefined + >() + } + + useSimulateContract({ + chainId: mainnet.id, + // @ts-expect-error + feeCurrency: '0x', + }) + + useSimulateContract({ + chainId: optimism.id, + // @ts-expect-error + feeCurrency: '0x', + }) +}) + +test('UseSimulateContractParameters', () => { + type Result = UseSimulateContractParameters< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config + > + + expectTypeOf<{ + functionName?: 'approve' | 'transfer' | 'transferFrom' | undefined + args?: readonly [Address, Address, bigint] | undefined + chainId?: ChainId | undefined + }>().toMatchTypeOf() + + type Result2 = UseSimulateContractParameters< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + typeof celo.id + > + expectTypeOf().toEqualTypeOf() + expectTypeOf().toEqualTypeOf< + `0x${string}` | undefined + >() + + type Result3 = SimulateContractParameters< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + typeof celo.id + > + expectTypeOf().toEqualTypeOf() + type Result4 = SimulateContractOptions< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + typeof celo.id + > + expectTypeOf().toEqualTypeOf() +}) + +test('parameters: config', async () => { + useSimulateContract({ + config: testConfig, + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/register-tests/react/src/useSwitchChain.test-d.ts b/packages/register-tests/react/src/useSwitchChain.test-d.ts new file mode 100644 index 0000000000..2d02557b85 --- /dev/null +++ b/packages/register-tests/react/src/useSwitchChain.test-d.ts @@ -0,0 +1,25 @@ +import { expectTypeOf, test } from 'vitest' +import { useSwitchChain } from 'wagmi' +import { type celo, mainnet, type optimism } from 'wagmi/chains' + +import type { ChainId, config } from './config.js' + +test('default', () => { + const { chains, switchChain } = useSwitchChain() + + expectTypeOf(chains).toEqualTypeOf<(typeof config)['chains']>() + expectTypeOf(chains[0]).toEqualTypeOf() + expectTypeOf(chains[2]).toEqualTypeOf() + + switchChain( + { chainId: 1 }, + { + onSuccess(data) { + expectTypeOf(data).toEqualTypeOf(mainnet) + }, + }, + ) + + type Result = Parameters[0] + expectTypeOf().toEqualTypeOf() +}) diff --git a/packages/register-tests/react/src/useTransaction.test-d.ts b/packages/register-tests/react/src/useTransaction.test-d.ts new file mode 100644 index 0000000000..135b99bb2d --- /dev/null +++ b/packages/register-tests/react/src/useTransaction.test-d.ts @@ -0,0 +1,23 @@ +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' +import { useTransaction } from 'wagmi' +import { celo } from 'wagmi/chains' + +test('chain formatters', () => { + const result = useTransaction() + if (result.data?.chainId === celo.id) { + expectTypeOf(result.data.feeCurrency).toEqualTypeOf<`0x${string}` | null>() + } + + const result2 = useTransaction({ chainId: celo.id }) + expectTypeOf(result2.data?.feeCurrency).toEqualTypeOf< + `0x${string}` | null | undefined + >() +}) + +test('parameters: config', async () => { + const result = useTransaction({ config }) + + if (result.data && 'feeCurrency' in result.data) + expectTypeOf(result.data.feeCurrency).toEqualTypeOf() +}) diff --git a/packages/register-tests/react/src/useTransactionConfirmations.test-d.ts b/packages/register-tests/react/src/useTransactionConfirmations.test-d.ts new file mode 100644 index 0000000000..fe2445db21 --- /dev/null +++ b/packages/register-tests/react/src/useTransactionConfirmations.test-d.ts @@ -0,0 +1,66 @@ +import { config as testConfig } from '@wagmi/test' +import { test } from 'vitest' +import { useTransactionConfirmations } from 'wagmi' +import { mainnet, zkSync } from 'wagmi/chains' + +const transactionReceipt = { + blockHash: '0x', + blockNumber: 1n, + contractAddress: '0x', + cumulativeGasUsed: 1n, + effectiveGasPrice: 1n, + from: '0x', + gasUsed: 1n, + logsBloom: '0x', + status: 'success', + to: '0x', + transactionHash: '0x', + transactionIndex: 1, + type: 'eip1559', +} as const + +test('chain formatters', async () => { + useTransactionConfirmations({ + transactionReceipt: { + ...transactionReceipt, + l1BatchNumber: 1n, + l1BatchTxIndex: 1n, + logs: [], + l2ToL1Logs: [], + }, + }) + + useTransactionConfirmations({ + chainId: zkSync.id, + transactionReceipt: { + ...transactionReceipt, + l1BatchNumber: 1n, + l1BatchTxIndex: 1n, + logs: [], + l2ToL1Logs: [], + }, + }) + + useTransactionConfirmations({ + chainId: mainnet.id, + transactionReceipt: { + ...transactionReceipt, + // @ts-expect-error + l1BatchNumber: 1n, + l1BatchTxIndex: 1n, + logs: [], + l2ToL1Logs: [], + }, + }) +}) + +test('parameters: config', async () => { + useTransactionConfirmations({ + config: testConfig, + transactionReceipt: { + ...transactionReceipt, + // @ts-expect-error + l1BatchNumber: 1n, + }, + }) +}) diff --git a/packages/register-tests/react/src/useTransactionReceipt.test-d.ts b/packages/register-tests/react/src/useTransactionReceipt.test-d.ts new file mode 100644 index 0000000000..1bbd8183da --- /dev/null +++ b/packages/register-tests/react/src/useTransactionReceipt.test-d.ts @@ -0,0 +1,31 @@ +import { config } from '@wagmi/test' +import type { ZkSyncL2ToL1Log, ZkSyncLog } from 'viem/zksync' +import { expectTypeOf, test } from 'vitest' +import { useTransactionReceipt } from 'wagmi' +import { zkSync } from 'wagmi/chains' + +test('chain formatters', () => { + const result = useTransactionReceipt() + + if (result.data?.chainId === zkSync.id) { + expectTypeOf(result.data.l1BatchNumber).toEqualTypeOf() + expectTypeOf(result.data.l1BatchTxIndex).toEqualTypeOf() + expectTypeOf(result.data.logs).toEqualTypeOf() + expectTypeOf(result.data.l2ToL1Logs).toEqualTypeOf() + } + + const result2 = useTransactionReceipt({ chainId: zkSync.id }) + if (result2.data) { + expectTypeOf(result2.data.l1BatchNumber).toEqualTypeOf() + expectTypeOf(result2.data.l1BatchTxIndex).toEqualTypeOf() + expectTypeOf(result2.data.logs).toEqualTypeOf() + expectTypeOf(result2.data.l2ToL1Logs).toEqualTypeOf() + } +}) + +test('parameters: config', async () => { + const result = useTransactionReceipt({ config }) + + if (result.data && 'l1BatchNumber' in result.data) + expectTypeOf(result.data.l1BatchNumber).toEqualTypeOf() +}) diff --git a/packages/register-tests/react/src/useWaitForTransactionReceipt.ts b/packages/register-tests/react/src/useWaitForTransactionReceipt.ts new file mode 100644 index 0000000000..0d2501f500 --- /dev/null +++ b/packages/register-tests/react/src/useWaitForTransactionReceipt.ts @@ -0,0 +1,31 @@ +import { config } from '@wagmi/test' +import type { ZkSyncL2ToL1Log, ZkSyncLog } from 'viem/zksync' +import { expectTypeOf, test } from 'vitest' +import { useWaitForTransactionReceipt } from 'wagmi' +import { zkSync } from 'wagmi/chains' + +test('chain formatters', () => { + const result = useWaitForTransactionReceipt() + + if (result.data?.chainId === zkSync.id) { + expectTypeOf(result.data.l1BatchNumber).toEqualTypeOf() + expectTypeOf(result.data.l1BatchTxIndex).toEqualTypeOf() + expectTypeOf(result.data.logs).toEqualTypeOf() + expectTypeOf(result.data.l2ToL1Logs).toEqualTypeOf() + } + + const result2 = useWaitForTransactionReceipt({ chainId: zkSync.id }) + if (result2.data) { + expectTypeOf(result2.data.l1BatchNumber).toEqualTypeOf() + expectTypeOf(result2.data.l1BatchTxIndex).toEqualTypeOf() + expectTypeOf(result2.data.logs).toEqualTypeOf() + expectTypeOf(result2.data.l2ToL1Logs).toEqualTypeOf() + } +}) + +test('parameters: config', async () => { + const result = useWaitForTransactionReceipt({ config }) + + if (result.data && 'l1BatchNumber' in result.data) + expectTypeOf(result.data.l1BatchNumber).toEqualTypeOf() +}) diff --git a/packages/register-tests/react/src/useWriteContract.test-d.ts b/packages/register-tests/react/src/useWriteContract.test-d.ts new file mode 100644 index 0000000000..c499ff8f37 --- /dev/null +++ b/packages/register-tests/react/src/useWriteContract.test-d.ts @@ -0,0 +1,65 @@ +import { abi, config } from '@wagmi/test' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' +import { useWriteContract } from 'wagmi' +import { celo, mainnet, optimism } from 'wagmi/chains' + +test('chain formatters', () => { + const { writeContract } = useWriteContract() + + const shared = { + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + } as const + + writeContract({ + ...shared, + feeCurrency: '0x', + }) + + type Result = Parameters< + typeof writeContract< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof celo.id + > + >[0] + expectTypeOf().toEqualTypeOf< + `0x${string}` | undefined + >() + writeContract({ + ...shared, + chainId: celo.id, + feeCurrency: '0x', + }) + + writeContract({ + ...shared, + chainId: mainnet.id, + // @ts-expect-error + feeCurrency: '0x', + }) + + writeContract({ + ...shared, + chainId: optimism.id, + // @ts-expect-error + feeCurrency: '0x', + }) +}) + +test('parameters: config', async () => { + const { writeContract } = useWriteContract({ config }) + + writeContract({ + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/register-tests/react/tsconfig.json b/packages/register-tests/react/tsconfig.json new file mode 100644 index 0000000000..77a211dbbb --- /dev/null +++ b/packages/register-tests/react/tsconfig.json @@ -0,0 +1,5 @@ +{ + "extends": "../../../tsconfig.base.json", + "include": ["src/**/*.ts"], + "exclude": [] +} diff --git a/packages/register-tests/vue/package.json b/packages/register-tests/vue/package.json new file mode 100644 index 0000000000..fc41697d7f --- /dev/null +++ b/packages/register-tests/vue/package.json @@ -0,0 +1,13 @@ +{ + "name": "vue-register", + "private": true, + "type": "module", + "scripts": { + "check:types": "tsc --noEmit" + }, + "dependencies": { + "@tanstack/vue-query": "catalog:", + "@wagmi/vue": "workspace:*", + "vue": "catalog:" + } +} diff --git a/packages/register-tests/vue/src/config.ts b/packages/register-tests/vue/src/config.ts new file mode 100644 index 0000000000..fd13c5a6be --- /dev/null +++ b/packages/register-tests/vue/src/config.ts @@ -0,0 +1,26 @@ +import { createConfig, mock } from '@wagmi/vue' +import { celo, mainnet, optimism, zkSync } from '@wagmi/vue/chains' +import { http } from 'viem' + +export const config = createConfig({ + chains: [celo, mainnet, optimism, zkSync], + connectors: [mock({ accounts: ['0x'] })], + transports: { + [celo.id]: http(), + [mainnet.id]: http(), + [optimism.id]: http(), + [zkSync.id]: http(), + }, +}) + +export type ChainId = + | typeof celo.id + | typeof mainnet.id + | typeof optimism.id + | typeof zkSync.id + +declare module '@wagmi/vue' { + interface Register { + config: typeof config + } +} diff --git a/packages/register-tests/vue/src/useAccount.test-d.ts b/packages/register-tests/vue/src/useAccount.test-d.ts new file mode 100644 index 0000000000..6471bf4550 --- /dev/null +++ b/packages/register-tests/vue/src/useAccount.test-d.ts @@ -0,0 +1,17 @@ +import { config } from '@wagmi/test' +import { useAccount } from '@wagmi/vue' +import { expectTypeOf, test } from 'vitest' + +import type { ChainId } from './config.js' + +test('default', () => { + const result = useAccount() + if (result.chain.value) + expectTypeOf(result.chain.value.id).toEqualTypeOf() +}) + +test('parameters: config', async () => { + const result = useAccount({ config }) + if (result.chain.value) + expectTypeOf(result.chain.value.id).toEqualTypeOf<1 | 10 | 456>() +}) diff --git a/packages/register-tests/vue/src/useChainId.test-d.ts b/packages/register-tests/vue/src/useChainId.test-d.ts new file mode 100644 index 0000000000..ffeddcb6ba --- /dev/null +++ b/packages/register-tests/vue/src/useChainId.test-d.ts @@ -0,0 +1,15 @@ +import { config } from '@wagmi/test' +import { useChainId } from '@wagmi/vue' +import { expectTypeOf, test } from 'vitest' + +import type { ChainId } from './config.js' + +test('default', async () => { + const chainId = useChainId() + expectTypeOf(chainId.value).toEqualTypeOf() +}) + +test('parameters: config', async () => { + const chainId = useChainId({ config }) + expectTypeOf(chainId.value).toEqualTypeOf<1 | 456 | 10>() +}) diff --git a/packages/register-tests/vue/src/useChains.test-d.ts b/packages/register-tests/vue/src/useChains.test-d.ts new file mode 100644 index 0000000000..d1bf0eb151 --- /dev/null +++ b/packages/register-tests/vue/src/useChains.test-d.ts @@ -0,0 +1,11 @@ +import { useChains } from '@wagmi/vue' +import type { Chain, celo, optimism } from '@wagmi/vue/chains' +import { expectTypeOf, test } from 'vitest' + +test('default', () => { + const chains = useChains() + + expectTypeOf(chains.value[0]).toEqualTypeOf() + expectTypeOf(chains.value[2]).toEqualTypeOf() + expectTypeOf(chains.value[5]).toEqualTypeOf() +}) diff --git a/packages/register-tests/vue/src/useClient.test-d.ts b/packages/register-tests/vue/src/useClient.test-d.ts new file mode 100644 index 0000000000..99cea8d3f2 --- /dev/null +++ b/packages/register-tests/vue/src/useClient.test-d.ts @@ -0,0 +1,38 @@ +import { type chain, config } from '@wagmi/test' +import { useClient } from '@wagmi/vue' +import { mainnet } from '@wagmi/vue/chains' +import { expectTypeOf, test } from 'vitest' + +import type { ChainId } from './config.js' + +test('default', () => { + const client = useClient() + expectTypeOf(client.value.chain.id).toEqualTypeOf() + expectTypeOf(client.value.transport.type).toEqualTypeOf<'http'>() +}) + +test('parameters: config', () => { + const client = useClient({ config }) + expectTypeOf(client.value.chain.id).toEqualTypeOf< + (typeof config)['chains'][number]['id'] + >() + expectTypeOf(client.value.transport.type).toEqualTypeOf<'http'>() +}) + +test('parameters: chainId', () => { + const client = useClient({ + config, + chainId: mainnet.id, + }) + expectTypeOf(client.value.chain).toEqualTypeOf() + expectTypeOf(client.value.transport.type).toEqualTypeOf<'http'>() +}) + +test('behavior: unconfigured chain', () => { + const client = useClient({ + config, + // @ts-expect-error + chainId: 123456, + }) + expectTypeOf(client.value).toEqualTypeOf() +}) diff --git a/packages/register-tests/vue/src/useConfig.test-d.ts b/packages/register-tests/vue/src/useConfig.test-d.ts new file mode 100644 index 0000000000..c65f70c214 --- /dev/null +++ b/packages/register-tests/vue/src/useConfig.test-d.ts @@ -0,0 +1,17 @@ +import { config as testConfig } from '@wagmi/test' +import { type Config, useConfig } from '@wagmi/vue' +import { expectTypeOf, test } from 'vitest' + +import type { config } from './config.js' + +test('default', async () => { + const result = useConfig() + expectTypeOf(result).not.toEqualTypeOf() + expectTypeOf(result).toEqualTypeOf() +}) + +test('parameters: config', async () => { + const result = useConfig({ config: testConfig }) + expectTypeOf(result).not.toEqualTypeOf() + expectTypeOf(result).toEqualTypeOf() +}) diff --git a/packages/register-tests/vue/src/useConnect.test-d.ts b/packages/register-tests/vue/src/useConnect.test-d.ts new file mode 100644 index 0000000000..128834ff6d --- /dev/null +++ b/packages/register-tests/vue/src/useConnect.test-d.ts @@ -0,0 +1,13 @@ +import { useConnect } from '@wagmi/vue' +import { expectTypeOf, test } from 'vitest' + +test('infers connect parameters', () => { + const { connect, connectors, variables } = useConnect() + const connector = connectors[0]! + + expectTypeOf(variables.value?.foo).toEqualTypeOf() + connect({ + connector, + foo: 'bar', + }) +}) diff --git a/packages/register-tests/vue/src/useReadContract.test-d.ts b/packages/register-tests/vue/src/useReadContract.test-d.ts new file mode 100644 index 0000000000..c2a1a6386a --- /dev/null +++ b/packages/register-tests/vue/src/useReadContract.test-d.ts @@ -0,0 +1,30 @@ +import type { abi } from '@wagmi/test' +import type { useReadContract } from '@wagmi/vue' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import type { DeepUnwrapRef } from '../../../vue/src/types/ref.js' +import type { ChainId } from './config.js' + +test('UseReadContractParameters', () => { + type Result = DeepUnwrapRef< + NonNullable< + Parameters< + typeof useReadContract + >[0] + > + > + + expectTypeOf().toMatchTypeOf<{ + functionName?: + | 'symbol' + | 'name' + | 'allowance' + | 'balanceOf' + | 'decimals' + | 'totalSupply' + | undefined + args?: readonly [Address] | undefined + chainId?: ChainId | undefined + }>() +}) diff --git a/packages/register-tests/vue/src/useSendTransaction.test-d.ts b/packages/register-tests/vue/src/useSendTransaction.test-d.ts new file mode 100644 index 0000000000..c49a8ef386 --- /dev/null +++ b/packages/register-tests/vue/src/useSendTransaction.test-d.ts @@ -0,0 +1,55 @@ +import { config } from '@wagmi/test' +import { useSendTransaction } from '@wagmi/vue' +import { celo, mainnet, optimism } from '@wagmi/vue/chains' +import { expectTypeOf, test } from 'vitest' +import type { ChainId } from './config.js' + +test('chain formatters', () => { + const { sendTransaction } = useSendTransaction() + + sendTransaction( + { + to: '0x', + feeCurrency: '0x', + }, + { + onSuccess(_data, variables) { + expectTypeOf(variables.chainId).toEqualTypeOf() + }, + }, + ) + + type Result = Parameters>[0] + expectTypeOf().toEqualTypeOf< + `0x${string}` | undefined + >() + sendTransaction({ + chainId: celo.id, + to: '0x', + feeCurrency: '0x', + }) + + sendTransaction({ + chainId: mainnet.id, + to: '0x', + // @ts-expect-error + feeCurrency: '0x', + }) + + sendTransaction({ + chainId: optimism.id, + to: '0x', + // @ts-expect-error + feeCurrency: '0x', + }) +}) + +test('parameters: config', async () => { + const { sendTransaction } = useSendTransaction({ config }) + + sendTransaction({ + to: '0x', + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/register-tests/vue/src/useSimulateContract.test-d.ts b/packages/register-tests/vue/src/useSimulateContract.test-d.ts new file mode 100644 index 0000000000..2a2b65c4d5 --- /dev/null +++ b/packages/register-tests/vue/src/useSimulateContract.test-d.ts @@ -0,0 +1,86 @@ +import { type abi, config as testConfig } from '@wagmi/test' +import { + type UseSimulateContractParameters, + useSimulateContract, +} from '@wagmi/vue' +import type { SimulateContractParameters } from '@wagmi/vue/actions' +import { celo, mainnet, optimism } from '@wagmi/vue/chains' +import type { SimulateContractOptions } from '@wagmi/vue/query' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import type { ChainId, config } from './config.js' + +test('chain formatters', () => { + const { data } = useSimulateContract({ + feeCurrency: '0x', + }) + if (data.value && data.value.chainId === celo.id) { + expectTypeOf(data.value.request.feeCurrency).toEqualTypeOf< + `0x${string}` | undefined + >() + } + + const { data: data2 } = useSimulateContract({ + chainId: celo.id, + feeCurrency: '0x', + }) + if (data2.value) { + expectTypeOf(data2.value.request.feeCurrency).toEqualTypeOf< + `0x${string}` | undefined + >() + } + + useSimulateContract({ + chainId: mainnet.id, + // @ts-expect-error + feeCurrency: '0x', + }) + + useSimulateContract({ + chainId: optimism.id, + // @ts-expect-error + feeCurrency: '0x', + }) +}) + +test('UseSimulateContractParameters', () => { + type Result = UseSimulateContractParameters< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config + > + + expectTypeOf<{ + functionName?: 'approve' | 'transfer' | 'transferFrom' | undefined + args?: readonly [Address, Address, bigint] | undefined + chainId?: ChainId | undefined + }>().toMatchTypeOf() + + type Result2 = SimulateContractParameters< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + typeof celo.id + > + expectTypeOf().toEqualTypeOf() + + type Result3 = SimulateContractOptions< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof config, + typeof celo.id + > + expectTypeOf().toEqualTypeOf() +}) + +test('parameters: config', async () => { + useSimulateContract({ + config: testConfig, + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/register-tests/vue/src/useSwitchChain.test-d.ts b/packages/register-tests/vue/src/useSwitchChain.test-d.ts new file mode 100644 index 0000000000..cf0153b3b7 --- /dev/null +++ b/packages/register-tests/vue/src/useSwitchChain.test-d.ts @@ -0,0 +1,27 @@ +import { useSwitchChain } from '@wagmi/vue' +import { type celo, mainnet, type optimism } from '@wagmi/vue/chains' +import { expectTypeOf, test } from 'vitest' + +import type { ChainId, config } from './config.js' + +test('default', () => { + const switchChain = useSwitchChain() + + const chains = switchChain.chains.value + + expectTypeOf(chains).toEqualTypeOf<(typeof config)['chains']>() + expectTypeOf(chains[0]).toEqualTypeOf() + expectTypeOf(chains[2]).toEqualTypeOf() + + switchChain.switchChain( + { chainId: 1 }, + { + onSuccess(data) { + expectTypeOf(data).toEqualTypeOf(mainnet) + }, + }, + ) + + type Result = Parameters<(typeof switchChain)['switchChain']>[0] + expectTypeOf().toEqualTypeOf() +}) diff --git a/packages/register-tests/vue/src/useTransaction.test-d.ts b/packages/register-tests/vue/src/useTransaction.test-d.ts new file mode 100644 index 0000000000..7bc262c38f --- /dev/null +++ b/packages/register-tests/vue/src/useTransaction.test-d.ts @@ -0,0 +1,25 @@ +import { config } from '@wagmi/test' +import { useTransaction } from '@wagmi/vue' +import { celo } from '@wagmi/vue/chains' +import { expectTypeOf, test } from 'vitest' + +test('chain formatters', () => { + const result = useTransaction() + if (result.data?.value?.chainId === celo.id) { + expectTypeOf(result.data.value.feeCurrency).toEqualTypeOf< + `0x${string}` | null + >() + } + + const result2 = useTransaction({ chainId: celo.id }) + expectTypeOf(result2.data?.value?.feeCurrency).toEqualTypeOf< + `0x${string}` | null | undefined + >() +}) + +test('parameters: config', async () => { + const result = useTransaction({ config }) + + if (result.data && 'feeCurrency' in result.data) + expectTypeOf(result.data.feeCurrency).toEqualTypeOf() +}) diff --git a/packages/register-tests/vue/src/useTransactionReceipt.test-d.ts b/packages/register-tests/vue/src/useTransactionReceipt.test-d.ts new file mode 100644 index 0000000000..c202d82dbb --- /dev/null +++ b/packages/register-tests/vue/src/useTransactionReceipt.test-d.ts @@ -0,0 +1,41 @@ +import { config } from '@wagmi/test' +import { useTransactionReceipt } from '@wagmi/vue' +import { zkSync } from '@wagmi/vue/chains' +import type { ZkSyncL2ToL1Log, ZkSyncLog } from 'viem/zksync' +import { expectTypeOf, test } from 'vitest' + +test('chain formatters', () => { + const result = useTransactionReceipt() + + if (result.data?.value?.chainId === zkSync.id) { + expectTypeOf(result.data.value.l1BatchNumber).toEqualTypeOf() + expectTypeOf(result.data.value.l1BatchTxIndex).toEqualTypeOf< + bigint | null + >() + expectTypeOf(result.data.value.logs).toEqualTypeOf() + expectTypeOf(result.data.value.l2ToL1Logs).toEqualTypeOf< + ZkSyncL2ToL1Log[] + >() + } + + const result2 = useTransactionReceipt({ chainId: zkSync.id }) + if (result2.data.value) { + expectTypeOf(result2.data.value.l1BatchNumber).toEqualTypeOf< + bigint | null + >() + expectTypeOf(result2.data.value.l1BatchTxIndex).toEqualTypeOf< + bigint | null + >() + expectTypeOf(result2.data.value.logs).toEqualTypeOf() + expectTypeOf(result2.data.value.l2ToL1Logs).toEqualTypeOf< + ZkSyncL2ToL1Log[] + >() + } +}) + +test('parameters: config', async () => { + const result = useTransactionReceipt({ config }) + + if (result.data && 'l1BatchNumber' in result.data) + expectTypeOf(result.data.l1BatchNumber).toEqualTypeOf() +}) diff --git a/packages/register-tests/vue/src/useWaitForTransaction.test-d.ts b/packages/register-tests/vue/src/useWaitForTransaction.test-d.ts new file mode 100644 index 0000000000..e0286617c1 --- /dev/null +++ b/packages/register-tests/vue/src/useWaitForTransaction.test-d.ts @@ -0,0 +1,41 @@ +import { config } from '@wagmi/test' +import { useWaitForTransactionReceipt } from '@wagmi/vue' +import { zkSync } from '@wagmi/vue/chains' +import type { ZkSyncL2ToL1Log, ZkSyncLog } from 'viem/zksync' +import { expectTypeOf, test } from 'vitest' + +test('chain formatters', () => { + const result = useWaitForTransactionReceipt() + + if (result.data?.value?.chainId === zkSync.id) { + expectTypeOf(result.data.value.l1BatchNumber).toEqualTypeOf() + expectTypeOf(result.data.value.l1BatchTxIndex).toEqualTypeOf< + bigint | null + >() + expectTypeOf(result.data.value.logs).toEqualTypeOf() + expectTypeOf(result.data.value.l2ToL1Logs).toEqualTypeOf< + ZkSyncL2ToL1Log[] + >() + } + + const result2 = useWaitForTransactionReceipt({ chainId: zkSync.id }) + if (result2.data.value) { + expectTypeOf(result2.data.value.l1BatchNumber).toEqualTypeOf< + bigint | null + >() + expectTypeOf(result2.data.value.l1BatchTxIndex).toEqualTypeOf< + bigint | null + >() + expectTypeOf(result2.data.value.logs).toEqualTypeOf() + expectTypeOf(result2.data.value.l2ToL1Logs).toEqualTypeOf< + ZkSyncL2ToL1Log[] + >() + } +}) + +test('parameters: config', async () => { + const result = useWaitForTransactionReceipt({ config }) + + if (result.data && 'l1BatchNumber' in result.data) + expectTypeOf(result.data.l1BatchNumber).toEqualTypeOf() +}) diff --git a/packages/register-tests/vue/src/useWriteContract.test-d.ts b/packages/register-tests/vue/src/useWriteContract.test-d.ts new file mode 100644 index 0000000000..ec4f38430c --- /dev/null +++ b/packages/register-tests/vue/src/useWriteContract.test-d.ts @@ -0,0 +1,65 @@ +import { abi, config } from '@wagmi/test' +import { useWriteContract } from '@wagmi/vue' +import { celo, mainnet, optimism } from '@wagmi/vue/chains' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' + +test('chain formatters', () => { + const { writeContract } = useWriteContract() + + const shared = { + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + } as const + + writeContract({ + ...shared, + feeCurrency: '0x', + }) + + type Result = Parameters< + typeof writeContract< + typeof abi.erc20, + 'transferFrom', + [Address, Address, bigint], + typeof celo.id + > + >[0] + expectTypeOf().toEqualTypeOf< + `0x${string}` | undefined + >() + writeContract({ + ...shared, + chainId: celo.id, + feeCurrency: '0x', + }) + + writeContract({ + ...shared, + chainId: mainnet.id, + // @ts-expect-error + feeCurrency: '0x', + }) + + writeContract({ + ...shared, + chainId: optimism.id, + // @ts-expect-error + feeCurrency: '0x', + }) +}) + +test('parameters: config', async () => { + const { writeContract } = useWriteContract({ config }) + + writeContract({ + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + // @ts-expect-error + feeCurrency: '0x', + }) +}) diff --git a/packages/register-tests/vue/tsconfig.json b/packages/register-tests/vue/tsconfig.json new file mode 100644 index 0000000000..77a211dbbb --- /dev/null +++ b/packages/register-tests/vue/tsconfig.json @@ -0,0 +1,5 @@ +{ + "extends": "../../../tsconfig.base.json", + "include": ["src/**/*.ts"], + "exclude": [] +} diff --git a/packages/services/api/CHANGELOG.md b/packages/services/api/CHANGELOG.md index de944ea36e..28bacf399a 100644 --- a/packages/services/api/CHANGELOG.md +++ b/packages/services/api/CHANGELOG.md @@ -1,174 +1,5 @@ # @0xsequence/api -## 3.0.5 - -### Patch Changes - -- Account federation support - -## 3.0.4 - -### Patch Changes - -- id-token login support - -## 3.0.3 - -### Patch Changes - -- 3.0.3 - -## 3.0.2 - -### Patch Changes - -- allow native self transfer - -## 3.0.1 - -### Patch Changes - -- Network and session fixes - -## 3.0.0 - -### Patch Changes - -- f68be62: ethauth support -- 49d8a2f: New chains, minor fixes -- 3411232: Beta release with dapp connector fixes -- 23cb9e9: New chains, relayer rpc fix -- f5f6a7a: dapp-client updates -- e7de3b1: Fix signer 404 error, minor fixes -- 493836f: multicall3 optimization -- 30e1f1a: 3.0.0 beta -- d5017e8: Beta release for v3 -- 24a5fab: Final RC before 3.0.0 -- e5e1a03: Apple auth fixes -- 0b63113: Apple auth fix -- a89134a: Userdata service updates -- 7c6c811: 3.0.0-beta.3 with fixes -- 3.0.0 release -- 98ce38b: 3.0.0-beta.2 with identity instrument updates -- 747e6b5: Relayer fee options fix -- 40c19ff: dapp client updates for EOA login -- 6d5de25: 3.0.0-beta.1 -- 934acd1: RC5 upgrade - -## 3.0.0-beta.19 - -### Patch Changes - -- Final RC before 3.0.0 - -## 3.0.0-beta.18 - -### Patch Changes - -- multicall3 optimization - -## 3.0.0-beta.17 - -### Patch Changes - -- New chains, relayer rpc fix - -## 3.0.0-beta.16 - -### Patch Changes - -- ethauth support - -## 3.0.0-beta.15 - -### Patch Changes - -- New chains, minor fixes - -## 3.0.0-beta.14 - -### Patch Changes - -- Relayer fee options fix - -## 3.0.0-beta.13 - -### Patch Changes - -- Userdata service updates - -## 3.0.0-beta.12 - -### Patch Changes - -- Beta release with dapp connector fixes - -## 3.0.0-beta.11 - -### Patch Changes - -- 3.0.0 beta - -## 3.0.0-beta.10 - -### Patch Changes - -- dapp-client updates - -## 3.0.0-beta.9 - -### Patch Changes - -- dapp client updates for EOA login - -## 3.0.0-beta.8 - -### Patch Changes - -- Apple auth fixes - -## 3.0.0-beta.7 - -### Patch Changes - -- Apple auth fix - -## 3.0.0-beta.6 - -### Patch Changes - -- Fix signer 404 error, minor fixes - -## 3.0.0-beta.5 - -### Patch Changes - -- Beta release for v3 - -## 3.0.0-beta.4 - -### Patch Changes - -- RC5 upgrade - -## 3.0.0-beta.3 - -### Patch Changes - -- 3.0.0-beta.3 with fixes - -## 3.0.0-beta.2 - -### Patch Changes - -- 3.0.0-beta.2 with identity instrument updates - -## 3.0.0-beta.1 - -### Patch Changes - -- 3.0.0-beta.1 - ## 2.3.8 ### Patch Changes diff --git a/packages/services/api/package.json b/packages/services/api/package.json index 8d2f87a228..bba908e695 100644 --- a/packages/services/api/package.json +++ b/packages/services/api/package.json @@ -1,31 +1,28 @@ { "name": "@0xsequence/api", - "version": "3.0.5", + "version": "3.0.0", "description": "api sub-package for Sequence", - "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/services/api", - "author": "Sequence Platforms ULC", + "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/api", + "author": "Sequence Platforms Inc.", "license": "Apache-2.0", "publishConfig": { "access": "public" }, - "type": "module", "scripts": { "build": "tsc", "dev": "tsc --watch", "test": "echo", - "typecheck": "tsc --noEmit", - "lint": "eslint . --max-warnings 0" + "typecheck": "tsc --noEmit" }, "exports": { ".": { - "types": "./dist/index.d.ts", + "types": "./src/index.ts", "default": "./dist/index.js" } }, "devDependencies": { "@repo/typescript-config": "workspace:^", - "@types/node": "^25.3.0", - "@repo/eslint-config": "workspace:^", - "typescript": "^5.9.3" + "@types/node": "^22.15.29", + "typescript": "^5.8.3" } } diff --git a/packages/services/builder/CHANGELOG.md b/packages/services/builder/CHANGELOG.md index e458893450..0a86b4aa5c 100644 --- a/packages/services/builder/CHANGELOG.md +++ b/packages/services/builder/CHANGELOG.md @@ -1,174 +1,5 @@ # @0xsequence/builder -## 3.0.5 - -### Patch Changes - -- Account federation support - -## 3.0.4 - -### Patch Changes - -- id-token login support - -## 3.0.3 - -### Patch Changes - -- 3.0.3 - -## 3.0.2 - -### Patch Changes - -- allow native self transfer - -## 3.0.1 - -### Patch Changes - -- Network and session fixes - -## 3.0.0 - -### Patch Changes - -- f68be62: ethauth support -- 49d8a2f: New chains, minor fixes -- 3411232: Beta release with dapp connector fixes -- 23cb9e9: New chains, relayer rpc fix -- f5f6a7a: dapp-client updates -- e7de3b1: Fix signer 404 error, minor fixes -- 493836f: multicall3 optimization -- 30e1f1a: 3.0.0 beta -- d5017e8: Beta release for v3 -- 24a5fab: Final RC before 3.0.0 -- e5e1a03: Apple auth fixes -- 0b63113: Apple auth fix -- a89134a: Userdata service updates -- 7c6c811: 3.0.0-beta.3 with fixes -- 3.0.0 release -- 98ce38b: 3.0.0-beta.2 with identity instrument updates -- 747e6b5: Relayer fee options fix -- 40c19ff: dapp client updates for EOA login -- 6d5de25: 3.0.0-beta.1 -- 934acd1: RC5 upgrade - -## 3.0.0-beta.19 - -### Patch Changes - -- Final RC before 3.0.0 - -## 3.0.0-beta.18 - -### Patch Changes - -- multicall3 optimization - -## 3.0.0-beta.17 - -### Patch Changes - -- New chains, relayer rpc fix - -## 3.0.0-beta.16 - -### Patch Changes - -- ethauth support - -## 3.0.0-beta.15 - -### Patch Changes - -- New chains, minor fixes - -## 3.0.0-beta.14 - -### Patch Changes - -- Relayer fee options fix - -## 3.0.0-beta.13 - -### Patch Changes - -- Userdata service updates - -## 3.0.0-beta.12 - -### Patch Changes - -- Beta release with dapp connector fixes - -## 3.0.0-beta.11 - -### Patch Changes - -- 3.0.0 beta - -## 3.0.0-beta.10 - -### Patch Changes - -- dapp-client updates - -## 3.0.0-beta.9 - -### Patch Changes - -- dapp client updates for EOA login - -## 3.0.0-beta.8 - -### Patch Changes - -- Apple auth fixes - -## 3.0.0-beta.7 - -### Patch Changes - -- Apple auth fix - -## 3.0.0-beta.6 - -### Patch Changes - -- Fix signer 404 error, minor fixes - -## 3.0.0-beta.5 - -### Patch Changes - -- Beta release for v3 - -## 3.0.0-beta.4 - -### Patch Changes - -- RC5 upgrade - -## 3.0.0-beta.3 - -### Patch Changes - -- 3.0.0-beta.3 with fixes - -## 3.0.0-beta.2 - -### Patch Changes - -- 3.0.0-beta.2 with identity instrument updates - -## 3.0.0-beta.1 - -### Patch Changes - -- 3.0.0-beta.1 - ## 2.3.8 ### Patch Changes diff --git a/packages/services/builder/package.json b/packages/services/builder/package.json index 1897f0ab87..e5668967a9 100644 --- a/packages/services/builder/package.json +++ b/packages/services/builder/package.json @@ -1,31 +1,28 @@ { "name": "@0xsequence/builder", - "version": "3.0.5", + "version": "3.0.0", "description": "builder sub-package for Sequence", - "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/services/builder", - "author": "Sequence Platforms ULC", + "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/builder", + "author": "Sequence Platforms Inc.", "license": "Apache-2.0", "publishConfig": { "access": "public" }, - "type": "module", "scripts": { "build": "tsc", "dev": "tsc --watch", "test": "echo", - "typecheck": "tsc --noEmit", - "lint": "eslint . --max-warnings 0" + "typecheck": "tsc --noEmit" }, "exports": { ".": { - "types": "./dist/index.d.ts", + "types": "./src/index.ts", "default": "./dist/index.js" } }, "devDependencies": { - "@repo/eslint-config": "workspace:^", "@repo/typescript-config": "workspace:^", - "@types/node": "^25.3.0", - "typescript": "^5.9.3" + "@types/node": "^22.15.29", + "typescript": "^5.8.3" } } diff --git a/packages/services/guard/CHANGELOG.md b/packages/services/guard/CHANGELOG.md index a705f48ba3..d84438e123 100644 --- a/packages/services/guard/CHANGELOG.md +++ b/packages/services/guard/CHANGELOG.md @@ -1,870 +1,10 @@ # @0xsequence/guard -## 3.0.5 - -### Patch Changes - -- Account federation support - -## 3.0.4 - -### Patch Changes - -- id-token login support - -## 3.0.3 - -### Patch Changes - -- 3.0.3 - -## 3.0.2 - -### Patch Changes - -- allow native self transfer - -## 3.0.1 - -### Patch Changes - -- Network and session fixes - -## 3.0.0 - -### Patch Changes - -- f68be62: ethauth support -- 49d8a2f: New chains, minor fixes -- 3411232: Beta release with dapp connector fixes -- 23cb9e9: New chains, relayer rpc fix -- f5f6a7a: dapp-client updates -- e7de3b1: Fix signer 404 error, minor fixes -- 493836f: multicall3 optimization -- 30e1f1a: 3.0.0 beta -- d5017e8: Beta release for v3 -- 24a5fab: Final RC before 3.0.0 -- e5e1a03: Apple auth fixes -- 0b63113: Apple auth fix -- a89134a: Userdata service updates -- 7c6c811: 3.0.0-beta.3 with fixes -- 3.0.0 release -- 98ce38b: 3.0.0-beta.2 with identity instrument updates -- 747e6b5: Relayer fee options fix -- 40c19ff: dapp client updates for EOA login -- 6d5de25: 3.0.0-beta.1 -- 934acd1: RC5 upgrade - -## 3.0.0-beta.19 - -### Patch Changes - -- Final RC before 3.0.0 - -## 3.0.0-beta.18 - -### Patch Changes - -- multicall3 optimization - -## 3.0.0-beta.17 - -### Patch Changes - -- New chains, relayer rpc fix - -## 3.0.0-beta.16 - -### Patch Changes - -- ethauth support - -## 3.0.0-beta.15 - -### Patch Changes - -- New chains, minor fixes - -## 3.0.0-beta.14 - -### Patch Changes - -- Relayer fee options fix - -## 3.0.0-beta.13 - -### Patch Changes - -- Userdata service updates - -## 3.0.0-beta.12 - -### Patch Changes - -- Beta release with dapp connector fixes - -## 3.0.0-beta.11 - -### Patch Changes - -- 3.0.0 beta - -## 3.0.0-beta.10 - -### Patch Changes - -- dapp-client updates - -## 3.0.0-beta.9 - -### Patch Changes - -- dapp client updates for EOA login - -## 3.0.0-beta.8 - -### Patch Changes - -- Apple auth fixes - -## 3.0.0-beta.7 - -### Patch Changes - -- Apple auth fix - -## 3.0.0-beta.6 - -### Patch Changes - -- Fix signer 404 error, minor fixes - -## 3.0.0-beta.5 - -### Patch Changes - -- Beta release for v3 - -## 3.0.0-beta.4 - -### Patch Changes - -- RC5 upgrade - -## 3.0.0-beta.3 - -### Patch Changes - -- 3.0.0-beta.3 with fixes - -## 3.0.0-beta.2 - -### Patch Changes - -- 3.0.0-beta.2 with identity instrument updates - -## 3.0.0-beta.1 - -### Patch Changes - -- 3.0.0-beta.1 - -## 2.3.8 - -### Patch Changes - -- indexer: update clients -- Updated dependencies - - @0xsequence/account@2.3.8 - - @0xsequence/core@2.3.8 - - @0xsequence/signhub@2.3.8 - - @0xsequence/utils@2.3.8 - -## 2.3.7 - -### Patch Changes - -- Metadata updates -- Updated dependencies - - @0xsequence/account@2.3.7 - - @0xsequence/core@2.3.7 - - @0xsequence/signhub@2.3.7 - - @0xsequence/utils@2.3.7 - -## 2.3.6 - -### Patch Changes - -- New chains -- Updated dependencies - - @0xsequence/account@2.3.6 - - @0xsequence/core@2.3.6 - - @0xsequence/signhub@2.3.6 - - @0xsequence/utils@2.3.6 - -## 2.3.5 - -### Patch Changes - -- Add Frequency Testnet -- Updated dependencies - - @0xsequence/account@2.3.5 - - @0xsequence/core@2.3.5 - - @0xsequence/signhub@2.3.5 - - @0xsequence/utils@2.3.5 - -## 2.3.4 - -### Patch Changes - -- metadata: exclude deprecated methods on rpc client -- Updated dependencies - - @0xsequence/account@2.3.4 - - @0xsequence/core@2.3.4 - - @0xsequence/signhub@2.3.4 - - @0xsequence/utils@2.3.4 - -## 2.3.3 - -### Patch Changes - -- metadata: client update -- Updated dependencies - - @0xsequence/account@2.3.3 - - @0xsequence/core@2.3.3 - - @0xsequence/signhub@2.3.3 - - @0xsequence/utils@2.3.3 - -## 2.3.2 - -### Patch Changes - -- metadata: update rpc client -- Updated dependencies - - @0xsequence/account@2.3.2 - - @0xsequence/core@2.3.2 - - @0xsequence/signhub@2.3.2 - - @0xsequence/utils@2.3.2 - -## 2.3.1 - -### Patch Changes - -- indexer: update rpc client -- Updated dependencies - - @0xsequence/account@2.3.1 - - @0xsequence/core@2.3.1 - - @0xsequence/signhub@2.3.1 - - @0xsequence/utils@2.3.1 - -## 2.3.0 - -### Minor Changes - -- update metadata rpc client - -### Patch Changes - -- Updated dependencies - - @0xsequence/account@2.3.0 - - @0xsequence/core@2.3.0 - - @0xsequence/signhub@2.3.0 - - @0xsequence/utils@2.3.0 - -## 2.2.15 - -### Patch Changes - -- API updates -- Updated dependencies - - @0xsequence/account@2.2.15 - - @0xsequence/core@2.2.15 - - @0xsequence/signhub@2.2.15 - - @0xsequence/utils@2.2.15 - -## 2.2.14 - -### Patch Changes - -- Somnia Testnet and Monad Testnet -- Updated dependencies - - @0xsequence/account@2.2.14 - - @0xsequence/core@2.2.14 - - @0xsequence/signhub@2.2.14 - - @0xsequence/utils@2.2.14 - -## 2.2.13 - -### Patch Changes - -- Add XR1 to all networks -- Updated dependencies - - @0xsequence/account@2.2.13 - - @0xsequence/core@2.2.13 - - @0xsequence/signhub@2.2.13 - - @0xsequence/utils@2.2.13 - -## 2.2.12 - -### Patch Changes - -- Add XR1 -- Updated dependencies - - @0xsequence/account@2.2.12 - - @0xsequence/core@2.2.12 - - @0xsequence/signhub@2.2.12 - - @0xsequence/utils@2.2.12 - -## 2.2.11 - -### Patch Changes - -- Relayer updates -- Updated dependencies - - @0xsequence/account@2.2.11 - - @0xsequence/core@2.2.11 - - @0xsequence/signhub@2.2.11 - - @0xsequence/utils@2.2.11 - -## 2.2.10 - -### Patch Changes - -- Etherlink support -- Updated dependencies - - @0xsequence/account@2.2.10 - - @0xsequence/core@2.2.10 - - @0xsequence/signhub@2.2.10 - - @0xsequence/utils@2.2.10 - -## 2.2.9 - -### Patch Changes - -- Indexer gateway native token balances -- Updated dependencies - - @0xsequence/account@2.2.9 - - @0xsequence/core@2.2.9 - - @0xsequence/signhub@2.2.9 - - @0xsequence/utils@2.2.9 - -## 2.2.8 - -### Patch Changes - -- Add Moonbeam and Moonbase Alpha -- Updated dependencies - - @0xsequence/account@2.2.8 - - @0xsequence/core@2.2.8 - - @0xsequence/signhub@2.2.8 - - @0xsequence/utils@2.2.8 - -## 2.2.7 - -### Patch Changes - -- Update Builder package -- Updated dependencies - - @0xsequence/account@2.2.7 - - @0xsequence/core@2.2.7 - - @0xsequence/signhub@2.2.7 - - @0xsequence/utils@2.2.7 - -## 2.2.6 - -### Patch Changes - -- Update relayer package -- Updated dependencies - - @0xsequence/account@2.2.6 - - @0xsequence/core@2.2.6 - - @0xsequence/signhub@2.2.6 - - @0xsequence/utils@2.2.6 - -## 2.2.5 - -### Patch Changes - -- auth: fix sequence indexer gateway url -- account: immutable wallet proxy hook -- Updated dependencies -- Updated dependencies - - @0xsequence/account@2.2.5 - - @0xsequence/core@2.2.5 - - @0xsequence/signhub@2.2.5 - - @0xsequence/utils@2.2.5 - -## 2.2.4 - -### Patch Changes - -- network: update soneium mainnet block explorer url -- waas: signTypedData intent support -- Updated dependencies -- Updated dependencies - - @0xsequence/account@2.2.4 - - @0xsequence/core@2.2.4 - - @0xsequence/signhub@2.2.4 - - @0xsequence/utils@2.2.4 - -## 2.2.3 - -### Patch Changes - -- provider: updating initWallet to use connected network configs if they exist -- Updated dependencies - - @0xsequence/account@2.2.3 - - @0xsequence/core@2.2.3 - - @0xsequence/signhub@2.2.3 - - @0xsequence/utils@2.2.3 - -## 2.2.2 - -### Patch Changes - -- pass projectAccessKey to relayer at all times -- Updated dependencies - - @0xsequence/account@2.2.2 - - @0xsequence/core@2.2.2 - - @0xsequence/signhub@2.2.2 - - @0xsequence/utils@2.2.2 - -## 2.2.1 - -### Patch Changes - -- waas-ethers: sign typed data -- Updated dependencies - - @0xsequence/account@2.2.1 - - @0xsequence/core@2.2.1 - - @0xsequence/signhub@2.2.1 - - @0xsequence/utils@2.2.1 - -## 2.2.0 - -### Minor Changes - -- indexer: gateway client -- @0xsequence/builder -- upgrade puppeteer to v23.10.3 - -### Patch Changes - -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/account@2.2.0 - - @0xsequence/core@2.2.0 - - @0xsequence/signhub@2.2.0 - - @0xsequence/utils@2.2.0 - -## 2.1.8 - -### Patch Changes - -- Add Soneium Mainnet -- Updated dependencies - - @0xsequence/account@2.1.8 - - @0xsequence/core@2.1.8 - - @0xsequence/signhub@2.1.8 - - @0xsequence/utils@2.1.8 - -## 2.1.7 - -### Patch Changes - -- guard: pass project access key to guard requests -- Updated dependencies - - @0xsequence/account@2.1.7 - - @0xsequence/core@2.1.7 - - @0xsequence/signhub@2.1.7 - - @0xsequence/utils@2.1.7 - -## 2.1.6 - -### Patch Changes - -- Add LAOS and Telos Testnet chains -- Updated dependencies - - @0xsequence/account@2.1.6 - - @0xsequence/core@2.1.6 - - @0xsequence/signhub@2.1.6 - - @0xsequence/utils@2.1.6 - -## 2.1.5 - -### Patch Changes - -- account: save presigned configuration with reference chain id 1 -- Updated dependencies - - @0xsequence/account@2.1.5 - - @0xsequence/core@2.1.5 - - @0xsequence/signhub@2.1.5 - - @0xsequence/utils@2.1.5 - -## 2.1.4 - -### Patch Changes - -- provider: pass projectAccessKey into MuxMessageProvider -- Updated dependencies - - @0xsequence/account@2.1.4 - - @0xsequence/core@2.1.4 - - @0xsequence/signhub@2.1.4 - - @0xsequence/utils@2.1.4 - -## 2.1.3 - -### Patch Changes - -- waas: time drift date fix due to strange browser quirk -- Updated dependencies - - @0xsequence/account@2.1.3 - - @0xsequence/core@2.1.3 - - @0xsequence/signhub@2.1.3 - - @0xsequence/utils@2.1.3 - -## 2.1.2 - -### Patch Changes - -- provider: export analytics correctly -- Updated dependencies - - @0xsequence/account@2.1.2 - - @0xsequence/core@2.1.2 - - @0xsequence/signhub@2.1.2 - - @0xsequence/utils@2.1.2 - -## 2.1.1 - -### Patch Changes - -- Add LAOS chain support -- Updated dependencies - - @0xsequence/account@2.1.1 - - @0xsequence/core@2.1.1 - - @0xsequence/signhub@2.1.1 - - @0xsequence/utils@2.1.1 - -## 2.1.0 - -### Minor Changes - -- account: forward project access key when estimating fees and sending transactions - -### Patch Changes - -- sessions: save signatures with reference chain id -- Updated dependencies -- Updated dependencies - - @0xsequence/account@2.1.0 - - @0xsequence/core@2.1.0 - - @0xsequence/signhub@2.1.0 - - @0xsequence/utils@2.1.0 - -## 2.0.26 - -### Patch Changes - -- account: fix chain id comparison -- Updated dependencies - - @0xsequence/account@2.0.26 - - @0xsequence/core@2.0.26 - - @0xsequence/signhub@2.0.26 - - @0xsequence/utils@2.0.26 - -## 2.0.25 - -### Patch Changes - -- skale-nebula: deploy gas limit = 10m -- Updated dependencies - - @0xsequence/account@2.0.25 - - @0xsequence/core@2.0.25 - - @0xsequence/signhub@2.0.25 - - @0xsequence/utils@2.0.25 - -## 2.0.24 - -### Patch Changes - -- sessions: arweave: configurable gateway url -- waas: use /status to get time drift before sending any intents -- Updated dependencies -- Updated dependencies - - @0xsequence/account@2.0.24 - - @0xsequence/core@2.0.24 - - @0xsequence/signhub@2.0.24 - - @0xsequence/utils@2.0.24 - -## 2.0.23 - -### Patch Changes - -- Add The Root Network support -- Updated dependencies - - @0xsequence/account@2.0.23 - - @0xsequence/core@2.0.23 - - @0xsequence/signhub@2.0.23 - - @0xsequence/utils@2.0.23 - -## 2.0.22 - -### Patch Changes - -- Add SKALE Nebula Mainnet support -- Updated dependencies - - @0xsequence/account@2.0.22 - - @0xsequence/core@2.0.22 - - @0xsequence/signhub@2.0.22 - - @0xsequence/utils@2.0.22 - -## 2.0.21 - -### Patch Changes - -- account: add publishWitnessFor -- Updated dependencies - - @0xsequence/account@2.0.21 - - @0xsequence/core@2.0.21 - - @0xsequence/signhub@2.0.21 - - @0xsequence/utils@2.0.21 - -## 2.0.20 - -### Patch Changes - -- upgrade deps, and improve waas session status handling -- Updated dependencies - - @0xsequence/account@2.0.20 - - @0xsequence/core@2.0.20 - - @0xsequence/signhub@2.0.20 - - @0xsequence/utils@2.0.20 - -## 2.0.19 - -### Patch Changes - -- Add Immutable zkEVM support -- Updated dependencies - - @0xsequence/account@2.0.19 - - @0xsequence/core@2.0.19 - - @0xsequence/signhub@2.0.19 - - @0xsequence/utils@2.0.19 - -## 2.0.18 - -### Patch Changes - -- waas: new contractCall transaction type -- sessions: add arweave owner -- Updated dependencies -- Updated dependencies - - @0xsequence/account@2.0.18 - - @0xsequence/core@2.0.18 - - @0xsequence/signhub@2.0.18 - - @0xsequence/utils@2.0.18 - -## 2.0.17 - -### Patch Changes - -- update waas auth to clear session before signIn -- Updated dependencies - - @0xsequence/account@2.0.17 - - @0xsequence/core@2.0.17 - - @0xsequence/signhub@2.0.17 - - @0xsequence/utils@2.0.17 - -## 2.0.16 - -### Patch Changes - -- Removed Astar chains -- Updated dependencies - - @0xsequence/account@2.0.16 - - @0xsequence/core@2.0.16 - - @0xsequence/signhub@2.0.16 - - @0xsequence/utils@2.0.16 - -## 2.0.15 - -### Patch Changes - -- indexer: update bindings with token balance additions -- Updated dependencies - - @0xsequence/account@2.0.15 - - @0xsequence/core@2.0.15 - - @0xsequence/signhub@2.0.15 - - @0xsequence/utils@2.0.15 - -## 2.0.14 - -### Patch Changes - -- sessions: arweave config reader -- network: add b3 and apechain mainnet configs -- Updated dependencies -- Updated dependencies - - @0xsequence/account@2.0.14 - - @0xsequence/core@2.0.14 - - @0xsequence/signhub@2.0.14 - - @0xsequence/utils@2.0.14 - -## 2.0.13 - -### Patch Changes - -- network: toy-testnet -- Updated dependencies - - @0xsequence/account@2.0.13 - - @0xsequence/core@2.0.13 - - @0xsequence/signhub@2.0.13 - - @0xsequence/utils@2.0.13 - -## 2.0.12 - -### Patch Changes - -- api: update bindings -- Updated dependencies - - @0xsequence/account@2.0.12 - - @0xsequence/core@2.0.12 - - @0xsequence/signhub@2.0.12 - - @0xsequence/utils@2.0.12 - -## 2.0.11 - -### Patch Changes - -- waas: intents test fix -- api: update bindings -- Updated dependencies -- Updated dependencies - - @0xsequence/account@2.0.11 - - @0xsequence/core@2.0.11 - - @0xsequence/signhub@2.0.11 - - @0xsequence/utils@2.0.11 - -## 2.0.10 - -### Patch Changes - -- network: soneium minato testnet -- Updated dependencies - - @0xsequence/account@2.0.10 - - @0xsequence/core@2.0.10 - - @0xsequence/signhub@2.0.10 - - @0xsequence/utils@2.0.10 - -## 2.0.9 - -### Patch Changes - -- network: fix SKALE network name -- Updated dependencies - - @0xsequence/account@2.0.9 - - @0xsequence/core@2.0.9 - - @0xsequence/signhub@2.0.9 - - @0xsequence/utils@2.0.9 - -## 2.0.8 - -### Patch Changes - -- metadata: update bindings -- Updated dependencies - - @0xsequence/account@2.0.8 - - @0xsequence/core@2.0.8 - - @0xsequence/signhub@2.0.8 - - @0xsequence/utils@2.0.8 - -## 2.0.7 - -### Patch Changes - -- wallet request handler fix -- Updated dependencies - - @0xsequence/account@2.0.7 - - @0xsequence/core@2.0.7 - - @0xsequence/signhub@2.0.7 - - @0xsequence/utils@2.0.7 - -## 2.0.6 - -### Patch Changes - -- network: matic -> pol -- Updated dependencies - - @0xsequence/account@2.0.6 - - @0xsequence/core@2.0.6 - - @0xsequence/signhub@2.0.6 - - @0xsequence/utils@2.0.6 - -## 2.0.5 - -### Patch Changes - -- provider: update databeat to 0.9.2 -- Updated dependencies - - @0xsequence/account@2.0.5 - - @0xsequence/core@2.0.5 - - @0xsequence/signhub@2.0.5 - - @0xsequence/utils@2.0.5 - -## 2.0.4 - -### Patch Changes - -- network: add skale-nebula-testnet -- Updated dependencies - - @0xsequence/account@2.0.4 - - @0xsequence/core@2.0.4 - - @0xsequence/signhub@2.0.4 - - @0xsequence/utils@2.0.4 - -## 2.0.3 - -### Patch Changes - -- waas: check session status in SequenceWaaS.isSignedIn() -- Updated dependencies - - @0xsequence/account@2.0.3 - - @0xsequence/core@2.0.3 - - @0xsequence/signhub@2.0.3 - - @0xsequence/utils@2.0.3 - -## 2.0.2 - -### Patch Changes - -- sessions: property convert serialized bignumber hex value to bigint -- Updated dependencies - - @0xsequence/account@2.0.2 - - @0xsequence/core@2.0.2 - - @0xsequence/signhub@2.0.2 - - @0xsequence/utils@2.0.2 - -## 2.0.1 - -### Patch Changes - -- waas: http signature check for authenticator requests -- provider: unwrap legacy json rpc responses -- use json replacer and reviver for bigints -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/account@2.0.1 - - @0xsequence/core@2.0.1 - - @0xsequence/signhub@2.0.1 - - @0xsequence/utils@2.0.1 - ## 2.0.0 ### Major Changes -- ethers v6 +- changeset ### Patch Changes @@ -874,17 +14,6 @@ - @0xsequence/signhub@2.0.0 - @0xsequence/utils@2.0.0 -## 1.10.15 - -### Patch Changes - -- utils: extractProjectIdFromAccessKey -- Updated dependencies - - @0xsequence/account@1.10.15 - - @0xsequence/core@1.10.15 - - @0xsequence/signhub@1.10.15 - - @0xsequence/utils@1.10.15 - ## 1.10.14 ### Patch Changes @@ -2471,6 +1600,7 @@ - relayer: fix Relayer.wait() interface The interface for calling Relayer.wait() has changed. Instead of a single optional ill-defined timeout/delay parameter, there are three optional parameters, in order: + - timeout: the maximum time to wait for the transaction receipt - delay: the polling interval, i.e. the time to wait between requests - maxFails: the maximum number of hard failures to tolerate before giving up diff --git a/packages/services/guard/package.json b/packages/services/guard/package.json index fc489cd03c..a7ec3a3d49 100644 --- a/packages/services/guard/package.json +++ b/packages/services/guard/package.json @@ -1,9 +1,9 @@ { "name": "@0xsequence/guard", - "version": "3.0.5", + "version": "3.0.0", "description": "guard sub-package for Sequence", - "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/services/guard", - "author": "Sequence Platforms ULC", + "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/guard", + "author": "Sequence Platforms Inc.", "license": "Apache-2.0", "type": "module", "publishConfig": { @@ -15,8 +15,7 @@ "dev": "tsc --watch", "test": "vitest run", "test:coverage": "vitest run --coverage", - "typecheck": "tsc --noEmit", - "lint": "eslint . --max-warnings 0" + "typecheck": "tsc --noEmit" }, "exports": { ".": { @@ -25,13 +24,12 @@ } }, "devDependencies": { - "@repo/eslint-config": "workspace:^", "@repo/typescript-config": "workspace:^", - "@types/node": "^25.3.0", - "typescript": "^5.9.3", - "vitest": "^4.0.18" + "@types/node": "^22.15.29", + "typescript": "^5.8.3", + "vitest": "^3.2.1" }, "dependencies": { - "ox": "^0.9.17" + "ox": "^0.7.2" } } diff --git a/packages/services/identity-instrument/package.json b/packages/services/identity-instrument/package.json index bb61d8e20c..3accab80e9 100644 --- a/packages/services/identity-instrument/package.json +++ b/packages/services/identity-instrument/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/identity-instrument", - "version": "3.0.5", + "version": "0.0.0", "license": "Apache-2.0", "type": "module", "publishConfig": { @@ -10,9 +10,7 @@ "scripts": { "build": "tsc", "dev": "tsc --watch", - "test": "vitest run", - "lint": "eslint . --max-warnings 0", - "typecheck": "tsc --noEmit" + "test": "vitest run" }, "exports": { ".": { @@ -21,15 +19,14 @@ } }, "devDependencies": { - "@repo/eslint-config": "workspace:^", "@repo/typescript-config": "workspace:^", - "@types/node": "^25.3.0", - "typescript": "^5.9.3", - "vitest": "^4.0.18" + "@types/node": "^22.15.29", + "typescript": "^5.8.3", + "vitest": "^3.2.1" }, "dependencies": { "json-canonicalize": "^2.0.0", "jwt-decode": "^4.0.0", - "ox": "^0.9.17" + "ox": "^0.7.2" } } diff --git a/packages/services/indexer/CHANGELOG.md b/packages/services/indexer/CHANGELOG.md index fb104e35fb..d6863dc7b0 100644 --- a/packages/services/indexer/CHANGELOG.md +++ b/packages/services/indexer/CHANGELOG.md @@ -1,174 +1,5 @@ # @0xsequence/indexer -## 3.0.5 - -### Patch Changes - -- Account federation support - -## 3.0.4 - -### Patch Changes - -- id-token login support - -## 3.0.3 - -### Patch Changes - -- 3.0.3 - -## 3.0.2 - -### Patch Changes - -- allow native self transfer - -## 3.0.1 - -### Patch Changes - -- Network and session fixes - -## 3.0.0 - -### Patch Changes - -- f68be62: ethauth support -- 49d8a2f: New chains, minor fixes -- 3411232: Beta release with dapp connector fixes -- 23cb9e9: New chains, relayer rpc fix -- f5f6a7a: dapp-client updates -- e7de3b1: Fix signer 404 error, minor fixes -- 493836f: multicall3 optimization -- 30e1f1a: 3.0.0 beta -- d5017e8: Beta release for v3 -- 24a5fab: Final RC before 3.0.0 -- e5e1a03: Apple auth fixes -- 0b63113: Apple auth fix -- a89134a: Userdata service updates -- 7c6c811: 3.0.0-beta.3 with fixes -- 3.0.0 release -- 98ce38b: 3.0.0-beta.2 with identity instrument updates -- 747e6b5: Relayer fee options fix -- 40c19ff: dapp client updates for EOA login -- 6d5de25: 3.0.0-beta.1 -- 934acd1: RC5 upgrade - -## 3.0.0-beta.19 - -### Patch Changes - -- Final RC before 3.0.0 - -## 3.0.0-beta.18 - -### Patch Changes - -- multicall3 optimization - -## 3.0.0-beta.17 - -### Patch Changes - -- New chains, relayer rpc fix - -## 3.0.0-beta.16 - -### Patch Changes - -- ethauth support - -## 3.0.0-beta.15 - -### Patch Changes - -- New chains, minor fixes - -## 3.0.0-beta.14 - -### Patch Changes - -- Relayer fee options fix - -## 3.0.0-beta.13 - -### Patch Changes - -- Userdata service updates - -## 3.0.0-beta.12 - -### Patch Changes - -- Beta release with dapp connector fixes - -## 3.0.0-beta.11 - -### Patch Changes - -- 3.0.0 beta - -## 3.0.0-beta.10 - -### Patch Changes - -- dapp-client updates - -## 3.0.0-beta.9 - -### Patch Changes - -- dapp client updates for EOA login - -## 3.0.0-beta.8 - -### Patch Changes - -- Apple auth fixes - -## 3.0.0-beta.7 - -### Patch Changes - -- Apple auth fix - -## 3.0.0-beta.6 - -### Patch Changes - -- Fix signer 404 error, minor fixes - -## 3.0.0-beta.5 - -### Patch Changes - -- Beta release for v3 - -## 3.0.0-beta.4 - -### Patch Changes - -- RC5 upgrade - -## 3.0.0-beta.3 - -### Patch Changes - -- 3.0.0-beta.3 with fixes - -## 3.0.0-beta.2 - -### Patch Changes - -- 3.0.0-beta.2 with identity instrument updates - -## 3.0.0-beta.1 - -### Patch Changes - -- 3.0.0-beta.1 - ## 2.3.8 ### Patch Changes @@ -555,6 +386,12 @@ - utils: extractProjectIdFromAccessKey +## 2.0.0 + +### Major Changes + +- changeset + ## 1.10.14 ### Patch Changes @@ -1906,6 +1743,12 @@ - - upgrade deps +## 0.31.3 + +### Patch Changes + +- update metadata bindings + ## 0.31.0 ### Minor Changes diff --git a/packages/services/indexer/package.json b/packages/services/indexer/package.json index 7ad0de895c..0eec0d29d4 100644 --- a/packages/services/indexer/package.json +++ b/packages/services/indexer/package.json @@ -1,31 +1,28 @@ { "name": "@0xsequence/indexer", - "version": "3.0.5", + "version": "3.0.0", "description": "indexer sub-package for Sequence", - "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/services/indexer", - "author": "Sequence Platforms ULC", + "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/indexer", + "author": "Sequence Platforms Inc.", "license": "Apache-2.0", "publishConfig": { "access": "public" }, - "type": "module", "scripts": { "build": "tsc", "dev": "tsc --watch", "test": "echo", - "typecheck": "tsc --noEmit", - "lint": "eslint . --max-warnings 0" + "typecheck": "tsc --noEmit" }, "exports": { ".": { - "types": "./dist/index.d.ts", + "types": "./src/index.ts", "default": "./dist/index.js" } }, "devDependencies": { - "@repo/eslint-config": "workspace:^", "@repo/typescript-config": "workspace:^", - "@types/node": "^25.3.0", - "typescript": "^5.9.3" + "@types/node": "^22.15.29", + "typescript": "^5.8.3" } } diff --git a/packages/services/marketplace/CHANGELOG.md b/packages/services/marketplace/CHANGELOG.md index 5a97b94e85..6295f3498c 100644 --- a/packages/services/marketplace/CHANGELOG.md +++ b/packages/services/marketplace/CHANGELOG.md @@ -1,174 +1,5 @@ # @0xsequence/marketplace -## 3.0.5 - -### Patch Changes - -- Account federation support - -## 3.0.4 - -### Patch Changes - -- id-token login support - -## 3.0.3 - -### Patch Changes - -- 3.0.3 - -## 3.0.2 - -### Patch Changes - -- allow native self transfer - -## 3.0.1 - -### Patch Changes - -- Network and session fixes - -## 3.0.0 - -### Patch Changes - -- f68be62: ethauth support -- 49d8a2f: New chains, minor fixes -- 3411232: Beta release with dapp connector fixes -- 23cb9e9: New chains, relayer rpc fix -- f5f6a7a: dapp-client updates -- e7de3b1: Fix signer 404 error, minor fixes -- 493836f: multicall3 optimization -- 30e1f1a: 3.0.0 beta -- d5017e8: Beta release for v3 -- 24a5fab: Final RC before 3.0.0 -- e5e1a03: Apple auth fixes -- 0b63113: Apple auth fix -- a89134a: Userdata service updates -- 7c6c811: 3.0.0-beta.3 with fixes -- 3.0.0 release -- 98ce38b: 3.0.0-beta.2 with identity instrument updates -- 747e6b5: Relayer fee options fix -- 40c19ff: dapp client updates for EOA login -- 6d5de25: 3.0.0-beta.1 -- 934acd1: RC5 upgrade - -## 3.0.0-beta.19 - -### Patch Changes - -- Final RC before 3.0.0 - -## 3.0.0-beta.18 - -### Patch Changes - -- multicall3 optimization - -## 3.0.0-beta.17 - -### Patch Changes - -- New chains, relayer rpc fix - -## 3.0.0-beta.16 - -### Patch Changes - -- ethauth support - -## 3.0.0-beta.15 - -### Patch Changes - -- New chains, minor fixes - -## 3.0.0-beta.14 - -### Patch Changes - -- Relayer fee options fix - -## 3.0.0-beta.13 - -### Patch Changes - -- Userdata service updates - -## 3.0.0-beta.12 - -### Patch Changes - -- Beta release with dapp connector fixes - -## 3.0.0-beta.11 - -### Patch Changes - -- 3.0.0 beta - -## 3.0.0-beta.10 - -### Patch Changes - -- dapp-client updates - -## 3.0.0-beta.9 - -### Patch Changes - -- dapp client updates for EOA login - -## 3.0.0-beta.8 - -### Patch Changes - -- Apple auth fixes - -## 3.0.0-beta.7 - -### Patch Changes - -- Apple auth fix - -## 3.0.0-beta.6 - -### Patch Changes - -- Fix signer 404 error, minor fixes - -## 3.0.0-beta.5 - -### Patch Changes - -- Beta release for v3 - -## 3.0.0-beta.4 - -### Patch Changes - -- RC5 upgrade - -## 3.0.0-beta.3 - -### Patch Changes - -- 3.0.0-beta.3 with fixes - -## 3.0.0-beta.2 - -### Patch Changes - -- 3.0.0-beta.2 with identity instrument updates - -## 3.0.0-beta.1 - -### Patch Changes - -- 3.0.0-beta.1 - ## 2.3.8 ### Patch Changes diff --git a/packages/services/marketplace/package.json b/packages/services/marketplace/package.json index 865e0e5b44..106c486daf 100644 --- a/packages/services/marketplace/package.json +++ b/packages/services/marketplace/package.json @@ -1,31 +1,28 @@ { "name": "@0xsequence/marketplace", - "version": "3.0.5", + "version": "3.0.0", "description": "marketplace sub-package for Sequence", - "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/services/marketplace", - "author": "Sequence Platforms ULC", + "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/marketplace", + "author": "Sequence Platforms Inc.", "license": "Apache-2.0", "publishConfig": { "access": "public" }, - "type": "module", "scripts": { "build": "tsc", "dev": "tsc --watch", "test": "echo", - "typecheck": "tsc --noEmit", - "lint": "eslint . --max-warnings 0" + "typecheck": "tsc --noEmit" }, "exports": { ".": { - "types": "./dist/index.d.ts", + "types": "./src/index.ts", "default": "./dist/index.js" } }, "devDependencies": { - "@repo/eslint-config": "workspace:^", "@repo/typescript-config": "workspace:^", - "@types/node": "^25.3.0", - "typescript": "^5.9.3" + "@types/node": "^22.15.29", + "typescript": "^5.8.3" } } diff --git a/packages/services/metadata/CHANGELOG.md b/packages/services/metadata/CHANGELOG.md index 3362b424e0..951224496b 100644 --- a/packages/services/metadata/CHANGELOG.md +++ b/packages/services/metadata/CHANGELOG.md @@ -1,174 +1,5 @@ # @0xsequence/metadata -## 3.0.5 - -### Patch Changes - -- Account federation support - -## 3.0.4 - -### Patch Changes - -- id-token login support - -## 3.0.3 - -### Patch Changes - -- 3.0.3 - -## 3.0.2 - -### Patch Changes - -- allow native self transfer - -## 3.0.1 - -### Patch Changes - -- Network and session fixes - -## 3.0.0 - -### Patch Changes - -- f68be62: ethauth support -- 49d8a2f: New chains, minor fixes -- 3411232: Beta release with dapp connector fixes -- 23cb9e9: New chains, relayer rpc fix -- f5f6a7a: dapp-client updates -- e7de3b1: Fix signer 404 error, minor fixes -- 493836f: multicall3 optimization -- 30e1f1a: 3.0.0 beta -- d5017e8: Beta release for v3 -- 24a5fab: Final RC before 3.0.0 -- e5e1a03: Apple auth fixes -- 0b63113: Apple auth fix -- a89134a: Userdata service updates -- 7c6c811: 3.0.0-beta.3 with fixes -- 3.0.0 release -- 98ce38b: 3.0.0-beta.2 with identity instrument updates -- 747e6b5: Relayer fee options fix -- 40c19ff: dapp client updates for EOA login -- 6d5de25: 3.0.0-beta.1 -- 934acd1: RC5 upgrade - -## 3.0.0-beta.19 - -### Patch Changes - -- Final RC before 3.0.0 - -## 3.0.0-beta.18 - -### Patch Changes - -- multicall3 optimization - -## 3.0.0-beta.17 - -### Patch Changes - -- New chains, relayer rpc fix - -## 3.0.0-beta.16 - -### Patch Changes - -- ethauth support - -## 3.0.0-beta.15 - -### Patch Changes - -- New chains, minor fixes - -## 3.0.0-beta.14 - -### Patch Changes - -- Relayer fee options fix - -## 3.0.0-beta.13 - -### Patch Changes - -- Userdata service updates - -## 3.0.0-beta.12 - -### Patch Changes - -- Beta release with dapp connector fixes - -## 3.0.0-beta.11 - -### Patch Changes - -- 3.0.0 beta - -## 3.0.0-beta.10 - -### Patch Changes - -- dapp-client updates - -## 3.0.0-beta.9 - -### Patch Changes - -- dapp client updates for EOA login - -## 3.0.0-beta.8 - -### Patch Changes - -- Apple auth fixes - -## 3.0.0-beta.7 - -### Patch Changes - -- Apple auth fix - -## 3.0.0-beta.6 - -### Patch Changes - -- Fix signer 404 error, minor fixes - -## 3.0.0-beta.5 - -### Patch Changes - -- Beta release for v3 - -## 3.0.0-beta.4 - -### Patch Changes - -- RC5 upgrade - -## 3.0.0-beta.3 - -### Patch Changes - -- 3.0.0-beta.3 with fixes - -## 3.0.0-beta.2 - -### Patch Changes - -- 3.0.0-beta.2 with identity instrument updates - -## 3.0.0-beta.1 - -### Patch Changes - -- 3.0.0-beta.1 - ## 2.3.8 ### Patch Changes @@ -555,6 +386,12 @@ - utils: extractProjectIdFromAccessKey +## 2.0.0 + +### Major Changes + +- changeset + ## 1.10.14 ### Patch Changes diff --git a/packages/services/metadata/package.json b/packages/services/metadata/package.json index acb19b042c..af9069cd66 100644 --- a/packages/services/metadata/package.json +++ b/packages/services/metadata/package.json @@ -1,31 +1,28 @@ { "name": "@0xsequence/metadata", - "version": "3.0.5", + "version": "3.0.0", "publishConfig": { "access": "public" }, "description": "metadata sub-package for Sequence", - "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/services/metadata", - "author": "Sequence Platforms ULC", + "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/metadata", + "author": "Sequence Platforms Inc.", "license": "Apache-2.0", - "type": "module", "scripts": { "build": "tsc", "dev": "tsc --watch", "test": "echo", - "typecheck": "tsc --noEmit", - "lint": "eslint . --max-warnings 0" + "typecheck": "tsc --noEmit" }, "exports": { ".": { - "types": "./dist/index.d.ts", + "types": "./src/index.ts", "default": "./dist/index.js" } }, "devDependencies": { - "@repo/eslint-config": "workspace:^", "@repo/typescript-config": "workspace:^", - "@types/node": "^25.3.0", - "typescript": "^5.9.3" + "@types/node": "^22.15.29", + "typescript": "^5.8.3" } } diff --git a/packages/services/relayer/CHANGELOG.md b/packages/services/relayer/CHANGELOG.md index abefb99b79..cdba14f8e1 100644 --- a/packages/services/relayer/CHANGELOG.md +++ b/packages/services/relayer/CHANGELOG.md @@ -1,879 +1,10 @@ # @0xsequence/relayer -## 3.0.5 - -### Patch Changes - -- Account federation support -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.5 - -## 3.0.4 - -### Patch Changes - -- id-token login support -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.4 - -## 3.0.3 - -### Patch Changes - -- 3.0.3 -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.3 - -## 3.0.2 - -### Patch Changes - -- allow native self transfer -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.2 - -## 3.0.1 - -### Patch Changes - -- Network and session fixes -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.1 - -## 3.0.0 - -### Patch Changes - -- f68be62: ethauth support -- 49d8a2f: New chains, minor fixes -- 3411232: Beta release with dapp connector fixes -- 23cb9e9: New chains, relayer rpc fix -- f5f6a7a: dapp-client updates -- e7de3b1: Fix signer 404 error, minor fixes -- 493836f: multicall3 optimization -- 30e1f1a: 3.0.0 beta -- d5017e8: Beta release for v3 -- 24a5fab: Final RC before 3.0.0 -- e5e1a03: Apple auth fixes -- 0b63113: Apple auth fix -- a89134a: Userdata service updates -- 7c6c811: 3.0.0-beta.3 with fixes -- 3.0.0 release -- 98ce38b: 3.0.0-beta.2 with identity instrument updates -- 747e6b5: Relayer fee options fix -- 40c19ff: dapp client updates for EOA login -- 6d5de25: 3.0.0-beta.1 -- 934acd1: RC5 upgrade -- Updated dependencies [f68be62] -- Updated dependencies [49d8a2f] -- Updated dependencies [3411232] -- Updated dependencies [23cb9e9] -- Updated dependencies [f5f6a7a] -- Updated dependencies [e7de3b1] -- Updated dependencies [493836f] -- Updated dependencies [30e1f1a] -- Updated dependencies [d5017e8] -- Updated dependencies [24a5fab] -- Updated dependencies [e5e1a03] -- Updated dependencies [0b63113] -- Updated dependencies [a89134a] -- Updated dependencies [7c6c811] -- Updated dependencies -- Updated dependencies [98ce38b] -- Updated dependencies [747e6b5] -- Updated dependencies [40c19ff] -- Updated dependencies [6d5de25] -- Updated dependencies [934acd1] - - @0xsequence/wallet-primitives@3.0.0 - -## 3.0.0-beta.19 - -### Patch Changes - -- Final RC before 3.0.0 -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.19 - -## 3.0.0-beta.18 - -### Patch Changes - -- multicall3 optimization -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.18 - -## 3.0.0-beta.17 - -### Patch Changes - -- New chains, relayer rpc fix -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.17 - -## 3.0.0-beta.16 - -### Patch Changes - -- ethauth support -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.16 - -## 3.0.0-beta.15 - -### Patch Changes - -- New chains, minor fixes -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.15 - -## 3.0.0-beta.14 - -### Patch Changes - -- Relayer fee options fix -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.14 - -## 3.0.0-beta.13 - -### Patch Changes - -- Userdata service updates -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.13 - -## 3.0.0-beta.12 - -### Patch Changes - -- Beta release with dapp connector fixes -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.12 - -## 3.0.0-beta.11 - -### Patch Changes - -- 3.0.0 beta -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.11 - -## 3.0.0-beta.10 - -### Patch Changes - -- dapp-client updates -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.10 - -## 3.0.0-beta.9 - -### Patch Changes - -- dapp client updates for EOA login -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.9 - -## 3.0.0-beta.8 - -### Patch Changes - -- Apple auth fixes -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.8 - -## 3.0.0-beta.7 - -### Patch Changes - -- Apple auth fix -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.7 - -## 3.0.0-beta.6 - -### Patch Changes - -- Fix signer 404 error, minor fixes -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.6 - -## 3.0.0-beta.5 - -### Patch Changes - -- Beta release for v3 -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.5 - -## 3.0.0-beta.4 - -### Patch Changes - -- RC5 upgrade -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.4 - -## 3.0.0-beta.3 - -### Patch Changes - -- 3.0.0-beta.3 with fixes -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.3 - -## 3.0.0-beta.2 - -### Patch Changes - -- 3.0.0-beta.2 with identity instrument updates -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.2 - -## 3.0.0-beta.1 - -### Patch Changes - -- 3.0.0-beta.1 -- Updated dependencies - - @0xsequence/wallet-primitives@3.0.0-beta.1 - -## 2.3.8 - -### Patch Changes - -- indexer: update clients -- Updated dependencies - - @0xsequence/abi@2.3.8 - - @0xsequence/core@2.3.8 - - @0xsequence/utils@2.3.8 - -## 2.3.7 - -### Patch Changes - -- Metadata updates -- Updated dependencies - - @0xsequence/abi@2.3.7 - - @0xsequence/core@2.3.7 - - @0xsequence/utils@2.3.7 - -## 2.3.6 - -### Patch Changes - -- New chains -- Updated dependencies - - @0xsequence/abi@2.3.6 - - @0xsequence/core@2.3.6 - - @0xsequence/utils@2.3.6 - -## 2.3.5 - -### Patch Changes - -- Add Frequency Testnet -- Updated dependencies - - @0xsequence/abi@2.3.5 - - @0xsequence/core@2.3.5 - - @0xsequence/utils@2.3.5 - -## 2.3.4 - -### Patch Changes - -- metadata: exclude deprecated methods on rpc client -- Updated dependencies - - @0xsequence/abi@2.3.4 - - @0xsequence/core@2.3.4 - - @0xsequence/utils@2.3.4 - -## 2.3.3 - -### Patch Changes - -- metadata: client update -- Updated dependencies - - @0xsequence/abi@2.3.3 - - @0xsequence/core@2.3.3 - - @0xsequence/utils@2.3.3 - -## 2.3.2 - -### Patch Changes - -- metadata: update rpc client -- Updated dependencies - - @0xsequence/abi@2.3.2 - - @0xsequence/core@2.3.2 - - @0xsequence/utils@2.3.2 - -## 2.3.1 - -### Patch Changes - -- indexer: update rpc client -- Updated dependencies - - @0xsequence/abi@2.3.1 - - @0xsequence/core@2.3.1 - - @0xsequence/utils@2.3.1 - -## 2.3.0 - -### Minor Changes - -- update metadata rpc client - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@2.3.0 - - @0xsequence/core@2.3.0 - - @0xsequence/utils@2.3.0 - -## 2.2.15 - -### Patch Changes - -- API updates -- Updated dependencies - - @0xsequence/abi@2.2.15 - - @0xsequence/core@2.2.15 - - @0xsequence/utils@2.2.15 - -## 2.2.14 - -### Patch Changes - -- Somnia Testnet and Monad Testnet -- Updated dependencies - - @0xsequence/abi@2.2.14 - - @0xsequence/core@2.2.14 - - @0xsequence/utils@2.2.14 - -## 2.2.13 - -### Patch Changes - -- Add XR1 to all networks -- Updated dependencies - - @0xsequence/abi@2.2.13 - - @0xsequence/core@2.2.13 - - @0xsequence/utils@2.2.13 - -## 2.2.12 - -### Patch Changes - -- Add XR1 -- Updated dependencies - - @0xsequence/abi@2.2.12 - - @0xsequence/core@2.2.12 - - @0xsequence/utils@2.2.12 - -## 2.2.11 - -### Patch Changes - -- Relayer updates -- Updated dependencies - - @0xsequence/abi@2.2.11 - - @0xsequence/core@2.2.11 - - @0xsequence/utils@2.2.11 - -## 2.2.10 - -### Patch Changes - -- Etherlink support -- Updated dependencies - - @0xsequence/abi@2.2.10 - - @0xsequence/core@2.2.10 - - @0xsequence/utils@2.2.10 - -## 2.2.9 - -### Patch Changes - -- Indexer gateway native token balances -- Updated dependencies - - @0xsequence/abi@2.2.9 - - @0xsequence/core@2.2.9 - - @0xsequence/utils@2.2.9 - -## 2.2.8 - -### Patch Changes - -- Add Moonbeam and Moonbase Alpha -- Updated dependencies - - @0xsequence/abi@2.2.8 - - @0xsequence/core@2.2.8 - - @0xsequence/utils@2.2.8 - -## 2.2.7 - -### Patch Changes - -- Update Builder package -- Updated dependencies - - @0xsequence/abi@2.2.7 - - @0xsequence/core@2.2.7 - - @0xsequence/utils@2.2.7 - -## 2.2.6 - -### Patch Changes - -- Update relayer package -- Updated dependencies - - @0xsequence/abi@2.2.6 - - @0xsequence/core@2.2.6 - - @0xsequence/utils@2.2.6 - -## 2.2.5 - -### Patch Changes - -- auth: fix sequence indexer gateway url -- account: immutable wallet proxy hook -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@2.2.5 - - @0xsequence/core@2.2.5 - - @0xsequence/utils@2.2.5 - -## 2.2.4 - -### Patch Changes - -- network: update soneium mainnet block explorer url -- waas: signTypedData intent support -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@2.2.4 - - @0xsequence/core@2.2.4 - - @0xsequence/utils@2.2.4 - -## 2.2.3 - -### Patch Changes - -- provider: updating initWallet to use connected network configs if they exist -- Updated dependencies - - @0xsequence/abi@2.2.3 - - @0xsequence/core@2.2.3 - - @0xsequence/utils@2.2.3 - -## 2.2.2 - -### Patch Changes - -- pass projectAccessKey to relayer at all times -- Updated dependencies - - @0xsequence/abi@2.2.2 - - @0xsequence/core@2.2.2 - - @0xsequence/utils@2.2.2 - -## 2.2.1 - -### Patch Changes - -- waas-ethers: sign typed data -- Updated dependencies - - @0xsequence/abi@2.2.1 - - @0xsequence/core@2.2.1 - - @0xsequence/utils@2.2.1 - -## 2.2.0 - -### Minor Changes - -- indexer: gateway client -- @0xsequence/builder -- upgrade puppeteer to v23.10.3 - -### Patch Changes - -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@2.2.0 - - @0xsequence/core@2.2.0 - - @0xsequence/utils@2.2.0 - -## 2.1.8 - -### Patch Changes - -- Add Soneium Mainnet -- Updated dependencies - - @0xsequence/abi@2.1.8 - - @0xsequence/core@2.1.8 - - @0xsequence/utils@2.1.8 - -## 2.1.7 - -### Patch Changes - -- guard: pass project access key to guard requests -- Updated dependencies - - @0xsequence/abi@2.1.7 - - @0xsequence/core@2.1.7 - - @0xsequence/utils@2.1.7 - -## 2.1.6 - -### Patch Changes - -- Add LAOS and Telos Testnet chains -- Updated dependencies - - @0xsequence/abi@2.1.6 - - @0xsequence/core@2.1.6 - - @0xsequence/utils@2.1.6 - -## 2.1.5 - -### Patch Changes - -- account: save presigned configuration with reference chain id 1 -- Updated dependencies - - @0xsequence/abi@2.1.5 - - @0xsequence/core@2.1.5 - - @0xsequence/utils@2.1.5 - -## 2.1.4 - -### Patch Changes - -- provider: pass projectAccessKey into MuxMessageProvider -- Updated dependencies - - @0xsequence/abi@2.1.4 - - @0xsequence/core@2.1.4 - - @0xsequence/utils@2.1.4 - -## 2.1.3 - -### Patch Changes - -- waas: time drift date fix due to strange browser quirk -- Updated dependencies - - @0xsequence/abi@2.1.3 - - @0xsequence/core@2.1.3 - - @0xsequence/utils@2.1.3 - -## 2.1.2 - -### Patch Changes - -- provider: export analytics correctly -- Updated dependencies - - @0xsequence/abi@2.1.2 - - @0xsequence/core@2.1.2 - - @0xsequence/utils@2.1.2 - -## 2.1.1 - -### Patch Changes - -- Add LAOS chain support -- Updated dependencies - - @0xsequence/abi@2.1.1 - - @0xsequence/core@2.1.1 - - @0xsequence/utils@2.1.1 - -## 2.1.0 - -### Minor Changes - -- account: forward project access key when estimating fees and sending transactions - -### Patch Changes - -- sessions: save signatures with reference chain id -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@2.1.0 - - @0xsequence/core@2.1.0 - - @0xsequence/utils@2.1.0 - -## 2.0.26 - -### Patch Changes - -- account: fix chain id comparison -- Updated dependencies - - @0xsequence/abi@2.0.26 - - @0xsequence/core@2.0.26 - - @0xsequence/utils@2.0.26 - -## 2.0.25 - -### Patch Changes - -- skale-nebula: deploy gas limit = 10m -- Updated dependencies - - @0xsequence/abi@2.0.25 - - @0xsequence/core@2.0.25 - - @0xsequence/utils@2.0.25 - -## 2.0.24 - -### Patch Changes - -- sessions: arweave: configurable gateway url -- waas: use /status to get time drift before sending any intents -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@2.0.24 - - @0xsequence/core@2.0.24 - - @0xsequence/utils@2.0.24 - -## 2.0.23 - -### Patch Changes - -- Add The Root Network support -- Updated dependencies - - @0xsequence/abi@2.0.23 - - @0xsequence/core@2.0.23 - - @0xsequence/utils@2.0.23 - -## 2.0.22 - -### Patch Changes - -- Add SKALE Nebula Mainnet support -- Updated dependencies - - @0xsequence/abi@2.0.22 - - @0xsequence/core@2.0.22 - - @0xsequence/utils@2.0.22 - -## 2.0.21 - -### Patch Changes - -- account: add publishWitnessFor -- Updated dependencies - - @0xsequence/abi@2.0.21 - - @0xsequence/core@2.0.21 - - @0xsequence/utils@2.0.21 - -## 2.0.20 - -### Patch Changes - -- upgrade deps, and improve waas session status handling -- Updated dependencies - - @0xsequence/abi@2.0.20 - - @0xsequence/core@2.0.20 - - @0xsequence/utils@2.0.20 - -## 2.0.19 - -### Patch Changes - -- Add Immutable zkEVM support -- Updated dependencies - - @0xsequence/abi@2.0.19 - - @0xsequence/core@2.0.19 - - @0xsequence/utils@2.0.19 - -## 2.0.18 - -### Patch Changes - -- waas: new contractCall transaction type -- sessions: add arweave owner -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@2.0.18 - - @0xsequence/core@2.0.18 - - @0xsequence/utils@2.0.18 - -## 2.0.17 - -### Patch Changes - -- update waas auth to clear session before signIn -- Updated dependencies - - @0xsequence/abi@2.0.17 - - @0xsequence/core@2.0.17 - - @0xsequence/utils@2.0.17 - -## 2.0.16 - -### Patch Changes - -- Removed Astar chains -- Updated dependencies - - @0xsequence/abi@2.0.16 - - @0xsequence/core@2.0.16 - - @0xsequence/utils@2.0.16 - -## 2.0.15 - -### Patch Changes - -- indexer: update bindings with token balance additions -- Updated dependencies - - @0xsequence/abi@2.0.15 - - @0xsequence/core@2.0.15 - - @0xsequence/utils@2.0.15 - -## 2.0.14 - -### Patch Changes - -- sessions: arweave config reader -- network: add b3 and apechain mainnet configs -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@2.0.14 - - @0xsequence/core@2.0.14 - - @0xsequence/utils@2.0.14 - -## 2.0.13 - -### Patch Changes - -- network: toy-testnet -- Updated dependencies - - @0xsequence/abi@2.0.13 - - @0xsequence/core@2.0.13 - - @0xsequence/utils@2.0.13 - -## 2.0.12 - -### Patch Changes - -- api: update bindings -- Updated dependencies - - @0xsequence/abi@2.0.12 - - @0xsequence/core@2.0.12 - - @0xsequence/utils@2.0.12 - -## 2.0.11 - -### Patch Changes - -- waas: intents test fix -- api: update bindings -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@2.0.11 - - @0xsequence/core@2.0.11 - - @0xsequence/utils@2.0.11 - -## 2.0.10 - -### Patch Changes - -- network: soneium minato testnet -- Updated dependencies - - @0xsequence/abi@2.0.10 - - @0xsequence/core@2.0.10 - - @0xsequence/utils@2.0.10 - -## 2.0.9 - -### Patch Changes - -- network: fix SKALE network name -- Updated dependencies - - @0xsequence/abi@2.0.9 - - @0xsequence/core@2.0.9 - - @0xsequence/utils@2.0.9 - -## 2.0.8 - -### Patch Changes - -- metadata: update bindings -- Updated dependencies - - @0xsequence/abi@2.0.8 - - @0xsequence/core@2.0.8 - - @0xsequence/utils@2.0.8 - -## 2.0.7 - -### Patch Changes - -- wallet request handler fix -- Updated dependencies - - @0xsequence/abi@2.0.7 - - @0xsequence/core@2.0.7 - - @0xsequence/utils@2.0.7 - -## 2.0.6 - -### Patch Changes - -- network: matic -> pol -- Updated dependencies - - @0xsequence/abi@2.0.6 - - @0xsequence/core@2.0.6 - - @0xsequence/utils@2.0.6 - -## 2.0.5 - -### Patch Changes - -- provider: update databeat to 0.9.2 -- Updated dependencies - - @0xsequence/abi@2.0.5 - - @0xsequence/core@2.0.5 - - @0xsequence/utils@2.0.5 - -## 2.0.4 - -### Patch Changes - -- network: add skale-nebula-testnet -- Updated dependencies - - @0xsequence/abi@2.0.4 - - @0xsequence/core@2.0.4 - - @0xsequence/utils@2.0.4 - -## 2.0.3 - -### Patch Changes - -- waas: check session status in SequenceWaaS.isSignedIn() -- Updated dependencies - - @0xsequence/abi@2.0.3 - - @0xsequence/core@2.0.3 - - @0xsequence/utils@2.0.3 - -## 2.0.2 - -### Patch Changes - -- sessions: property convert serialized bignumber hex value to bigint -- Updated dependencies - - @0xsequence/abi@2.0.2 - - @0xsequence/core@2.0.2 - - @0xsequence/utils@2.0.2 - -## 2.0.1 - -### Patch Changes - -- waas: http signature check for authenticator requests -- provider: unwrap legacy json rpc responses -- use json replacer and reviver for bigints -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@2.0.1 - - @0xsequence/core@2.0.1 - - @0xsequence/utils@2.0.1 - ## 2.0.0 ### Major Changes -- ethers v6 +- changeset ### Patch Changes @@ -882,16 +13,6 @@ - @0xsequence/core@2.0.0 - @0xsequence/utils@2.0.0 -## 1.10.15 - -### Patch Changes - -- utils: extractProjectIdFromAccessKey -- Updated dependencies - - @0xsequence/abi@1.10.15 - - @0xsequence/core@1.10.15 - - @0xsequence/utils@1.10.15 - ## 1.10.14 ### Patch Changes @@ -2714,6 +1835,7 @@ - relayer: fix Relayer.wait() interface The interface for calling Relayer.wait() has changed. Instead of a single optional ill-defined timeout/delay parameter, there are three optional parameters, in order: + - timeout: the maximum time to wait for the transaction receipt - delay: the polling interval, i.e. the time to wait between requests - maxFails: the maximum number of hard failures to tolerate before giving up @@ -3376,6 +2498,7 @@ ### Minor Changes - major architectural changes in Sequence design + - only one API instance, API is no longer a per-chain service - separate per-chain indexer service, API no longer handles indexing - single contract metadata service, API no longer serves metadata diff --git a/packages/services/relayer/package.json b/packages/services/relayer/package.json index 0c1422d970..55bf3f7f2a 100644 --- a/packages/services/relayer/package.json +++ b/packages/services/relayer/package.json @@ -1,13 +1,13 @@ { "name": "@0xsequence/relayer", - "version": "3.0.5", + "version": "3.0.0", "type": "module", "publishConfig": { "access": "public" }, "description": "relayer sub-package for Sequence", - "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/services/relayer", - "author": "Sequence Platforms ULC", + "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/relayer", + "author": "Sequence Platforms Inc.", "license": "Apache-2.0", "scripts": { "build": "tsc", @@ -17,8 +17,7 @@ "old-test:file": "NODE_OPTIONS='--import tsx' mocha --timeout 60000", "old-test:concurrently": "concurrently -k --success first 'pnpm start:hardhat > /dev/null' ", "start:hardhat": "pnpm hardhat node --port 9547", - "typecheck": "tsc --noEmit", - "lint": "eslint . --max-warnings 0" + "typecheck": "tsc --noEmit" }, "exports": { ".": { @@ -27,16 +26,8 @@ } }, "devDependencies": { - "@repo/eslint-config": "workspace:^", "@repo/typescript-config": "workspace:^", - "@types/node": "^25.3.0", - "typescript": "^5.9.3", - "vitest": "^4.0.18" - }, - "dependencies": { - "@0xsequence/wallet-primitives": "workspace:^", - "mipd": "^0.0.7", - "ox": "^0.9.17", - "viem": "^2.40.3" + "@types/node": "^22.15.29", + "typescript": "^5.8.3" } } diff --git a/packages/services/relayer/src/relayer/relayer.ts b/packages/services/relayer/src/relayer/relayer.ts index 3ed5a69627..69079d6ca6 100644 --- a/packages/services/relayer/src/relayer/relayer.ts +++ b/packages/services/relayer/src/relayer/relayer.ts @@ -26,8 +26,10 @@ export interface Relayer { checkPrecondition(precondition: Precondition.Precondition): Promise } -export function isRelayer(relayer: any): relayer is Relayer { +export function isRelayer(relayer: unknown): relayer is Relayer { return ( + typeof relayer === 'object' && + relayer !== null && 'isAvailable' in relayer && 'feeOptions' in relayer && 'relay' in relayer && diff --git a/packages/services/relayer/src/relayer/rpc-relayer/relayer.gen.ts b/packages/services/relayer/src/relayer/rpc-relayer/relayer.gen.ts deleted file mode 100644 index 8a9ff4a7b4..0000000000 --- a/packages/services/relayer/src/relayer/rpc-relayer/relayer.gen.ts +++ /dev/null @@ -1,2500 +0,0 @@ -/* eslint-disable */ -// sequence-relayer v0.4.1 0a2503bc893179ba968b0015d7580aabf6a88dd4 -// -- -// Code generated by Webrpc-gen@v0.32.2 with typescript generator. DO NOT EDIT. -// -// webrpc-gen -schema=relayer.ridl -target=typescript -client -out=./clients/relayer.gen.ts -compat - -// Webrpc description and code-gen version -export const WebrpcVersion = 'v1' - -// Schema version of your RIDL schema -export const WebrpcSchemaVersion = 'v0.4.1' - -// Schema hash generated from your RIDL schema -export const WebrpcSchemaHash = '0a2503bc893179ba968b0015d7580aabf6a88dd4' - -// -// Client interface -// - -export interface RelayerClient { - ping(headers?: object, signal?: AbortSignal): Promise - - version(headers?: object, signal?: AbortSignal): Promise - - runtimeStatus(headers?: object, signal?: AbortSignal): Promise - - getSequenceContext(headers?: object, signal?: AbortSignal): Promise - - getChainID(headers?: object, signal?: AbortSignal): Promise - - /** - * - * Transactions - * - * TODO (future): rename this to just, 'SendTransaction(txn: MetaTransaction)' or 'SendTransaction(txn: SignedTransaction)', or something.. - * Project ID is only used by service and admin calls. Other clients must have projectID passed via the context - * TODO: rename return txnHash: string to metaTxnID: string - */ - sendMetaTxn(req: SendMetaTxnArgs, headers?: object, signal?: AbortSignal): Promise - - getMetaTxnNonce(req: GetMetaTxnNonceArgs, headers?: object, signal?: AbortSignal): Promise - - /** - * TODO: one day, make GetMetaTxnReceipt respond immediately with receipt or not - * and add WaitTransactionReceipt method, which will block and wait, similar to how GetMetaTxnReceipt - * is implemented now. - * For backwards compat, we can leave the current GetMetaTxnReceipt how it is, an deprecate it, and introduce - * new, GetTransactionReceipt and WaitTransactionReceipt methods - * we can also accept metaTxnId and txnHash .. so can take either or.. I wonder if ERC-4337 has any convention on this? - */ - getMetaTxnReceipt( - req: GetMetaTxnReceiptArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - simulate(req: SimulateArgs, headers?: object, signal?: AbortSignal): Promise - - simulateV3(req: SimulateV3Args, headers?: object, signal?: AbortSignal): Promise - - /** - * TODO: deprecated, to be removed by https://github.com/0xsequence/stack/pull/356 at a later date - */ - updateMetaTxnGasLimits( - req: UpdateMetaTxnGasLimitsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - feeTokens(headers?: object, signal?: AbortSignal): Promise - - feeOptions(req: FeeOptionsArgs, headers?: object, signal?: AbortSignal): Promise - - /** - * Bridge gas endpoints for S2S calls - * Used for bridge fees (e.g., LayerZero messaging fees) that require msg.value to be fronted at runtime. - * bridgeGas will be included in fee calculation so the relayer gets reimbursed. - */ - sendMetaTxnWithBridgeGas( - req: SendMetaTxnWithBridgeGasArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - feeOptionsWithBridgeGas( - req: FeeOptionsWithBridgeGasArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - /** - * TODO: deprecated, to be removed by https://github.com/0xsequence/stack/pull/356 at a later date - */ - getMetaTxnNetworkFeeOptions( - req: GetMetaTxnNetworkFeeOptionsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - /** - * - * Sender administration - * - */ - startSender(req: StartSenderArgs, headers?: object, signal?: AbortSignal): Promise - - stopSender(req: StopSenderArgs, headers?: object, signal?: AbortSignal): Promise - - repairSender(req: RepairSenderArgs, headers?: object, signal?: AbortSignal): Promise - - getMetaTransactions( - req: GetMetaTransactionsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - getTransactionCost( - req: GetTransactionCostArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - /** - * Legacy Gas Tank - */ - getGasTank(req: GetGasTankArgs, headers?: object, signal?: AbortSignal): Promise - - addGasTank(req: AddGasTankArgs, headers?: object, signal?: AbortSignal): Promise - - updateGasTank(req: UpdateGasTankArgs, headers?: object, signal?: AbortSignal): Promise - - /** - * Legacy Gas Adjustment - */ - nextGasTankBalanceAdjustmentNonce( - req: NextGasTankBalanceAdjustmentNonceArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - adjustGasTankBalance( - req: AdjustGasTankBalanceArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - getGasTankBalanceAdjustment( - req: GetGasTankBalanceAdjustmentArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - listGasTankBalanceAdjustments( - req: ListGasTankBalanceAdjustmentsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - /** - * Project-Level Gas Sponsorship - */ - listGasSponsors(req: ListGasSponsorsArgs, headers?: object, signal?: AbortSignal): Promise - - getGasSponsor(req: GetGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise - - addGasSponsor(req: AddGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise - - updateGasSponsor(req: UpdateGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise - - removeGasSponsor(req: RemoveGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise - - /** - * Ecosystem-level Gas Sponsorship - */ - listEcosystemGasSponsors( - req: ListEcosystemGasSponsorsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - getEcosystemGasSponsor( - req: GetEcosystemGasSponsorArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - addEcosystemGasSponsor( - req: AddEcosystemGasSponsorArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - updateEcosystemGasSponsor( - req: UpdateEcosystemGasSponsorArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - removeEcosystemGasSponsor( - req: RemoveEcosystemGasSponsorArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - /** - * Gas Sponsor Lookup - */ - addressGasSponsors( - req: AddressGasSponsorsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - /** - * Project Balance - */ - getProjectBalance( - req: GetProjectBalanceArgs, - headers?: object, - signal?: AbortSignal, - ): Promise - - adjustProjectBalance( - req: AdjustProjectBalanceArgs, - headers?: object, - signal?: AbortSignal, - ): Promise -} - -// -// Schema types -// - -export enum RepairOperation { - SKIP = 'SKIP', - REQUEUE = 'REQUEUE', - DROP = 'DROP', -} - -export enum ETHTxnStatus { - UNKNOWN = 'UNKNOWN', - DROPPED = 'DROPPED', - QUEUED = 'QUEUED', - SENT = 'SENT', - SUCCEEDED = 'SUCCEEDED', - PARTIALLY_FAILED = 'PARTIALLY_FAILED', - FAILED = 'FAILED', - PENDING_PRECONDITION = 'PENDING_PRECONDITION', - MINED = 'MINED', -} - -export enum TransferType { - SEND = 'SEND', - RECEIVE = 'RECEIVE', - BRIDGE_DEPOSIT = 'BRIDGE_DEPOSIT', - BRIDGE_WITHDRAW = 'BRIDGE_WITHDRAW', - BURN = 'BURN', - UNKNOWN = 'UNKNOWN', -} - -export enum SimulateStatus { - SKIPPED = 'SKIPPED', - SUCCEEDED = 'SUCCEEDED', - FAILED = 'FAILED', - ABORTED = 'ABORTED', - REVERTED = 'REVERTED', - NOT_ENOUGH_GAS = 'NOT_ENOUGH_GAS', -} - -export enum FeeTokenType { - UNKNOWN = 'UNKNOWN', - ERC20_TOKEN = 'ERC20_TOKEN', - ERC1155_TOKEN = 'ERC1155_TOKEN', -} - -export enum Order { - DESC = 'DESC', - ASC = 'ASC', -} - -export interface Version { - webrpcVersion: string - schemaVersion: string - schemaHash: string - appVersion: string -} - -export interface RuntimeStatus { - healthOK: boolean - startTime: string - uptime: number - ver: string - branch: string - commitHash: string - chainID: number - useEIP1559: boolean - senders: Array - checks: RuntimeChecks -} - -export interface SenderStatus { - index: number - address: string - etherBalance: number - enabled: boolean - active: boolean - nonce?: NonceStatus - current?: CurrentStatus -} - -export interface NonceStatus { - chain: number - mempool: number -} - -export interface CurrentStatus { - transaction: string - first: TransactionStatus - latest?: TransactionStatus -} - -export interface TransactionStatus { - transaction: string - gas: number - gasPrice: string - priorityFee: string - time: string - age: string - error?: string -} - -export interface RuntimeChecks {} - -export interface SequenceContext { - factory: string - mainModule: string - mainModuleUpgradable: string - guestModule: string - utils: string -} - -export interface GasTank { - id: number - chainId: number - name: string - currentBalance: number - unlimited: boolean - feeMarkupFactor: number - updatedAt: string - createdAt: string -} - -export interface GasTankBalanceAdjustment { - gasTankId: number - nonce: number - amount: number - totalBalance: number - balanceTimestamp: string - createdAt: string -} - -export interface GasSponsor { - id: number - gasTankId: number - projectId: number - ecosystemId: number - chainId: number - address: string - name: string - active: boolean - updatedAt: string - createdAt: string - deletedAt: string -} - -export interface GasSponsorUsage { - name: string - id: number - totalGasUsed: number - totalTxnFees: number - totalTxnFeesUsd: number - avgGasPrice: number - totalTxns: number - startTime: string - endTime: string -} - -export interface MetaTxn { - walletAddress: string - contract: string - input: string -} - -export interface MetaTxnLog { - id: number - chainId: number - projectId: number - txnHash: string - txnNonce: string - metaTxnID?: string - txnStatus: ETHTxnStatus - txnRevertReason: string - requeues: number - queuedAt: string - sentAt: string - minedAt: string - target: string - input: string - bridgeGas?: string - txnArgs: { [key: string]: any } - txnReceipt?: { [key: string]: any } - walletAddress: string - metaTxnNonce: string - gasLimit: number - gasPrice: string - gasUsed: number - gasEstimated: number - gasFeeMarkup?: number - usdRate: string - creditsUsed: number - cost: string - isWhitelisted: boolean - gasSponsor?: number - gasTank?: number - updatedAt: string - createdAt: string -} - -export interface MetaTxnReceipt { - id: string - status: string - revertReason?: string - index: number - logs: Array - receipts: Array - blockNumber: string - txnHash: string - txnReceipt: string -} - -export interface MetaTxnReceiptLog { - address: string - topics: Array - data: string -} - -export interface Transactions { - chainID: string - transactions: Array - preconditions?: Array -} - -export interface Transaction { - delegateCall: boolean - revertOnError: boolean - gasLimit: string - target: string - value: string - data: string -} - -export interface TransactionPrecondition { - type: string - chainId: number - ownerAddress: string - tokenAddress: string - minAmount: bigint -} - -export interface TxnLogUser { - username: string -} - -export interface TxnLogTransfer { - transferType: TransferType - contractAddress: string - from: string - to: string - ids: Array - amounts: Array -} - -export interface SimulateResult { - executed: boolean - succeeded: boolean - result?: string - reason?: string - gasUsed: number - gasLimit: number -} - -export interface SimulateV3Result { - status: SimulateStatus - result?: string - error?: string - gasUsed: number - gasLimit: number -} - -export interface FeeOption { - token: FeeToken - to: string - value: string - gasLimit: number -} - -export interface FeeToken { - chainId: number - name: string - symbol: string - type: FeeTokenType - decimals?: number - logoURL: string - contractAddress?: string - tokenID?: string -} - -export interface Page { - pageSize: number - page: number - more: boolean - column: string - sort: Array -} - -export interface Sort { - column: string - order: Order -} - -export interface PingArgs {} - -export interface PingReturn { - status: boolean -} - -export interface VersionArgs {} - -export interface VersionReturn { - version: Version -} - -export interface RuntimeStatusArgs {} - -export interface RuntimeStatusReturn { - status: RuntimeStatus -} - -export interface GetSequenceContextArgs {} - -export interface GetSequenceContextReturn { - data: SequenceContext -} - -export interface GetChainIDArgs {} - -export interface GetChainIDReturn { - chainID: number -} - -export interface SendMetaTxnArgs { - call: MetaTxn - quote?: string - projectID?: number - preconditions?: Array -} - -export interface SendMetaTxnReturn { - status: boolean - txnHash: string -} - -export interface GetMetaTxnNonceArgs { - walletContractAddress: string - space?: string -} - -export interface GetMetaTxnNonceReturn { - nonce: string -} - -export interface GetMetaTxnReceiptArgs { - metaTxID: string -} - -export interface GetMetaTxnReceiptReturn { - receipt: MetaTxnReceipt -} - -export interface SimulateArgs { - wallet: string - transactions: string -} - -export interface SimulateReturn { - results: Array -} - -export interface SimulateV3Args { - wallet: string - calls: string -} - -export interface SimulateV3Return { - results: Array -} - -export interface UpdateMetaTxnGasLimitsArgs { - walletAddress: string - walletConfig: any - payload: string -} - -export interface UpdateMetaTxnGasLimitsReturn { - payload: string -} - -export interface FeeTokensArgs {} - -export interface FeeTokensReturn { - isFeeRequired: boolean - tokens: Array - paymentAddress: string -} - -export interface FeeOptionsArgs { - wallet: string - to: string - data: string - simulate?: boolean -} - -export interface FeeOptionsReturn { - options: Array - sponsored: boolean - quote?: string -} - -export interface SendMetaTxnWithBridgeGasArgs { - call: MetaTxn - quote?: string - projectID?: number - bridgeGas: string - preconditions?: Array -} - -export interface SendMetaTxnWithBridgeGasReturn { - status: boolean - txnHash: string -} - -export interface FeeOptionsWithBridgeGasArgs { - wallet: string - to: string - data: string - simulate?: boolean - bridgeGas: string -} - -export interface FeeOptionsWithBridgeGasReturn { - options: Array - sponsored: boolean - quote?: string -} - -export interface GetMetaTxnNetworkFeeOptionsArgs { - walletConfig: any - payload: string -} - -export interface GetMetaTxnNetworkFeeOptionsReturn { - options: Array -} - -export interface StartSenderArgs { - sender: number -} - -export interface StartSenderReturn {} - -export interface StopSenderArgs { - sender: number -} - -export interface StopSenderReturn {} - -export interface RepairSenderArgs { - sender: number - nonce: number - operation: RepairOperation -} - -export interface RepairSenderReturn {} - -export interface GetMetaTransactionsArgs { - projectId: number - page?: Page -} - -export interface GetMetaTransactionsReturn { - page: Page - transactions: Array -} - -export interface GetTransactionCostArgs { - projectId: number - from: string - to: string -} - -export interface GetTransactionCostReturn { - cost: number -} - -export interface GetGasTankArgs { - id: number -} - -export interface GetGasTankReturn { - gasTank: GasTank -} - -export interface AddGasTankArgs { - name: string - feeMarkupFactor: number - unlimited?: boolean -} - -export interface AddGasTankReturn { - status: boolean - gasTank: GasTank -} - -export interface UpdateGasTankArgs { - id: number - name?: string - feeMarkupFactor?: number - unlimited?: boolean -} - -export interface UpdateGasTankReturn { - status: boolean - gasTank: GasTank -} - -export interface NextGasTankBalanceAdjustmentNonceArgs { - id: number -} - -export interface NextGasTankBalanceAdjustmentNonceReturn { - nonce: number -} - -export interface AdjustGasTankBalanceArgs { - id: number - nonce: number - amount: number -} - -export interface AdjustGasTankBalanceReturn { - status: boolean - adjustment: GasTankBalanceAdjustment -} - -export interface GetGasTankBalanceAdjustmentArgs { - id: number - nonce: number -} - -export interface GetGasTankBalanceAdjustmentReturn { - adjustment: GasTankBalanceAdjustment -} - -export interface ListGasTankBalanceAdjustmentsArgs { - id: number - page?: Page -} - -export interface ListGasTankBalanceAdjustmentsReturn { - page: Page - adjustments: Array -} - -export interface ListGasSponsorsArgs { - projectId: number - page?: Page -} - -export interface ListGasSponsorsReturn { - page: Page - gasSponsors: Array -} - -export interface GetGasSponsorArgs { - projectId: number - id: number -} - -export interface GetGasSponsorReturn { - gasSponsor: GasSponsor -} - -export interface AddGasSponsorArgs { - projectId: number - address: string - name?: string - active?: boolean -} - -export interface AddGasSponsorReturn { - status: boolean - gasSponsor: GasSponsor -} - -export interface UpdateGasSponsorArgs { - projectId: number - id: number - name?: string - active?: boolean -} - -export interface UpdateGasSponsorReturn { - status: boolean - gasSponsor: GasSponsor -} - -export interface RemoveGasSponsorArgs { - projectId: number - id: number -} - -export interface RemoveGasSponsorReturn { - status: boolean -} - -export interface ListEcosystemGasSponsorsArgs { - ecosystemId: number - page?: Page -} - -export interface ListEcosystemGasSponsorsReturn { - page: Page - gasSponsors: Array -} - -export interface GetEcosystemGasSponsorArgs { - ecosystemId: number - id: number -} - -export interface GetEcosystemGasSponsorReturn { - gasSponsor: GasSponsor -} - -export interface AddEcosystemGasSponsorArgs { - ecosystemId: number - address: string - name?: string - active?: boolean -} - -export interface AddEcosystemGasSponsorReturn { - status: boolean - gasSponsor: GasSponsor -} - -export interface UpdateEcosystemGasSponsorArgs { - ecosystemId: number - id: number - name?: string - active?: boolean -} - -export interface UpdateEcosystemGasSponsorReturn { - status: boolean - gasSponsor: GasSponsor -} - -export interface RemoveEcosystemGasSponsorArgs { - ecosystemId: number - id: number -} - -export interface RemoveEcosystemGasSponsorReturn { - status: boolean -} - -export interface AddressGasSponsorsArgs { - address: string - page?: Page -} - -export interface AddressGasSponsorsReturn { - page: Page - gasSponsors: Array -} - -export interface GetProjectBalanceArgs { - projectId: number -} - -export interface GetProjectBalanceReturn { - balance: number -} - -export interface AdjustProjectBalanceArgs { - projectId: number - amount: number - identifier: string -} - -export interface AdjustProjectBalanceReturn { - balance: number -} - -// -// Client -// - -export class Relayer implements RelayerClient { - protected hostname: string - protected fetch: Fetch - protected path = '/rpc/Relayer/' - - constructor(hostname: string, fetch: Fetch) { - this.hostname = hostname.replace(/\/*$/, '') - this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) - } - - private url(name: string): string { - return this.hostname + this.path + name - } - - queryKey = { - ping: () => ['Relayer', 'ping'] as const, - version: () => ['Relayer', 'version'] as const, - runtimeStatus: () => ['Relayer', 'runtimeStatus'] as const, - getSequenceContext: () => ['Relayer', 'getSequenceContext'] as const, - getChainID: () => ['Relayer', 'getChainID'] as const, - sendMetaTxn: (req: SendMetaTxnArgs) => ['Relayer', 'sendMetaTxn', req] as const, - getMetaTxnNonce: (req: GetMetaTxnNonceArgs) => ['Relayer', 'getMetaTxnNonce', req] as const, - getMetaTxnReceipt: (req: GetMetaTxnReceiptArgs) => ['Relayer', 'getMetaTxnReceipt', req] as const, - simulate: (req: SimulateArgs) => ['Relayer', 'simulate', req] as const, - simulateV3: (req: SimulateV3Args) => ['Relayer', 'simulateV3', req] as const, - updateMetaTxnGasLimits: (req: UpdateMetaTxnGasLimitsArgs) => ['Relayer', 'updateMetaTxnGasLimits', req] as const, - feeTokens: () => ['Relayer', 'feeTokens'] as const, - feeOptions: (req: FeeOptionsArgs) => ['Relayer', 'feeOptions', req] as const, - sendMetaTxnWithBridgeGas: (req: SendMetaTxnWithBridgeGasArgs) => - ['Relayer', 'sendMetaTxnWithBridgeGas', req] as const, - feeOptionsWithBridgeGas: (req: FeeOptionsWithBridgeGasArgs) => ['Relayer', 'feeOptionsWithBridgeGas', req] as const, - getMetaTxnNetworkFeeOptions: (req: GetMetaTxnNetworkFeeOptionsArgs) => - ['Relayer', 'getMetaTxnNetworkFeeOptions', req] as const, - startSender: (req: StartSenderArgs) => ['Relayer', 'startSender', req] as const, - stopSender: (req: StopSenderArgs) => ['Relayer', 'stopSender', req] as const, - repairSender: (req: RepairSenderArgs) => ['Relayer', 'repairSender', req] as const, - getMetaTransactions: (req: GetMetaTransactionsArgs) => ['Relayer', 'getMetaTransactions', req] as const, - getTransactionCost: (req: GetTransactionCostArgs) => ['Relayer', 'getTransactionCost', req] as const, - getGasTank: (req: GetGasTankArgs) => ['Relayer', 'getGasTank', req] as const, - addGasTank: (req: AddGasTankArgs) => ['Relayer', 'addGasTank', req] as const, - updateGasTank: (req: UpdateGasTankArgs) => ['Relayer', 'updateGasTank', req] as const, - nextGasTankBalanceAdjustmentNonce: (req: NextGasTankBalanceAdjustmentNonceArgs) => - ['Relayer', 'nextGasTankBalanceAdjustmentNonce', req] as const, - adjustGasTankBalance: (req: AdjustGasTankBalanceArgs) => ['Relayer', 'adjustGasTankBalance', req] as const, - getGasTankBalanceAdjustment: (req: GetGasTankBalanceAdjustmentArgs) => - ['Relayer', 'getGasTankBalanceAdjustment', req] as const, - listGasTankBalanceAdjustments: (req: ListGasTankBalanceAdjustmentsArgs) => - ['Relayer', 'listGasTankBalanceAdjustments', req] as const, - listGasSponsors: (req: ListGasSponsorsArgs) => ['Relayer', 'listGasSponsors', req] as const, - getGasSponsor: (req: GetGasSponsorArgs) => ['Relayer', 'getGasSponsor', req] as const, - addGasSponsor: (req: AddGasSponsorArgs) => ['Relayer', 'addGasSponsor', req] as const, - updateGasSponsor: (req: UpdateGasSponsorArgs) => ['Relayer', 'updateGasSponsor', req] as const, - removeGasSponsor: (req: RemoveGasSponsorArgs) => ['Relayer', 'removeGasSponsor', req] as const, - listEcosystemGasSponsors: (req: ListEcosystemGasSponsorsArgs) => - ['Relayer', 'listEcosystemGasSponsors', req] as const, - getEcosystemGasSponsor: (req: GetEcosystemGasSponsorArgs) => ['Relayer', 'getEcosystemGasSponsor', req] as const, - addEcosystemGasSponsor: (req: AddEcosystemGasSponsorArgs) => ['Relayer', 'addEcosystemGasSponsor', req] as const, - updateEcosystemGasSponsor: (req: UpdateEcosystemGasSponsorArgs) => - ['Relayer', 'updateEcosystemGasSponsor', req] as const, - removeEcosystemGasSponsor: (req: RemoveEcosystemGasSponsorArgs) => - ['Relayer', 'removeEcosystemGasSponsor', req] as const, - addressGasSponsors: (req: AddressGasSponsorsArgs) => ['Relayer', 'addressGasSponsors', req] as const, - getProjectBalance: (req: GetProjectBalanceArgs) => ['Relayer', 'getProjectBalance', req] as const, - adjustProjectBalance: (req: AdjustProjectBalanceArgs) => ['Relayer', 'adjustProjectBalance', req] as const, - } - - ping = (headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('Ping'), createHttpRequest('{}', headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'PingReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - version = (headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('Version'), createHttpRequest('{}', headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'VersionReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - runtimeStatus = (headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('RuntimeStatus'), createHttpRequest('{}', headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'RuntimeStatusReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - getSequenceContext = (headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('GetSequenceContext'), createHttpRequest('{}', headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'GetSequenceContextReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - getChainID = (headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('GetChainID'), createHttpRequest('{}', headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'GetChainIDReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - sendMetaTxn = (req: SendMetaTxnArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('SendMetaTxn'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'SendMetaTxnReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - getMetaTxnNonce = ( - req: GetMetaTxnNonceArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('GetMetaTxnNonce'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'GetMetaTxnNonceReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - getMetaTxnReceipt = ( - req: GetMetaTxnReceiptArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('GetMetaTxnReceipt'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'GetMetaTxnReceiptReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - simulate = (req: SimulateArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('Simulate'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'SimulateReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - simulateV3 = (req: SimulateV3Args, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('SimulateV3'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'SimulateV3Return') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - updateMetaTxnGasLimits = ( - req: UpdateMetaTxnGasLimitsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('UpdateMetaTxnGasLimits'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'UpdateMetaTxnGasLimitsReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - feeTokens = (headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('FeeTokens'), createHttpRequest('{}', headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'FeeTokensReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - feeOptions = (req: FeeOptionsArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('FeeOptions'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'FeeOptionsReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - sendMetaTxnWithBridgeGas = ( - req: SendMetaTxnWithBridgeGasArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('SendMetaTxnWithBridgeGas'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'SendMetaTxnWithBridgeGasReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - feeOptionsWithBridgeGas = ( - req: FeeOptionsWithBridgeGasArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('FeeOptionsWithBridgeGas'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'FeeOptionsWithBridgeGasReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - getMetaTxnNetworkFeeOptions = ( - req: GetMetaTxnNetworkFeeOptionsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch( - this.url('GetMetaTxnNetworkFeeOptions'), - createHttpRequest(JsonEncode(req), headers, signal), - ).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'GetMetaTxnNetworkFeeOptionsReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - startSender = (req: StartSenderArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('StartSender'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'StartSenderReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - stopSender = (req: StopSenderArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('StopSender'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'StopSenderReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - repairSender = (req: RepairSenderArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('RepairSender'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'RepairSenderReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - getMetaTransactions = ( - req: GetMetaTransactionsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('GetMetaTransactions'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'GetMetaTransactionsReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - getTransactionCost = ( - req: GetTransactionCostArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('GetTransactionCost'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'GetTransactionCostReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - getGasTank = (req: GetGasTankArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('GetGasTank'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'GetGasTankReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - addGasTank = (req: AddGasTankArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('AddGasTank'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'AddGasTankReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - updateGasTank = (req: UpdateGasTankArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('UpdateGasTank'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'UpdateGasTankReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - nextGasTankBalanceAdjustmentNonce = ( - req: NextGasTankBalanceAdjustmentNonceArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch( - this.url('NextGasTankBalanceAdjustmentNonce'), - createHttpRequest(JsonEncode(req), headers, signal), - ).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'NextGasTankBalanceAdjustmentNonceReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - adjustGasTankBalance = ( - req: AdjustGasTankBalanceArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('AdjustGasTankBalance'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'AdjustGasTankBalanceReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - getGasTankBalanceAdjustment = ( - req: GetGasTankBalanceAdjustmentArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch( - this.url('GetGasTankBalanceAdjustment'), - createHttpRequest(JsonEncode(req), headers, signal), - ).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'GetGasTankBalanceAdjustmentReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - listGasTankBalanceAdjustments = ( - req: ListGasTankBalanceAdjustmentsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch( - this.url('ListGasTankBalanceAdjustments'), - createHttpRequest(JsonEncode(req), headers, signal), - ).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'ListGasTankBalanceAdjustmentsReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - listGasSponsors = ( - req: ListGasSponsorsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('ListGasSponsors'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'ListGasSponsorsReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - getGasSponsor = (req: GetGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('GetGasSponsor'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'GetGasSponsorReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - addGasSponsor = (req: AddGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('AddGasSponsor'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'AddGasSponsorReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - updateGasSponsor = ( - req: UpdateGasSponsorArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('UpdateGasSponsor'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'UpdateGasSponsorReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - removeGasSponsor = ( - req: RemoveGasSponsorArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('RemoveGasSponsor'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'RemoveGasSponsorReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - listEcosystemGasSponsors = ( - req: ListEcosystemGasSponsorsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('ListEcosystemGasSponsors'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'ListEcosystemGasSponsorsReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - getEcosystemGasSponsor = ( - req: GetEcosystemGasSponsorArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('GetEcosystemGasSponsor'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'GetEcosystemGasSponsorReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - addEcosystemGasSponsor = ( - req: AddEcosystemGasSponsorArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('AddEcosystemGasSponsor'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'AddEcosystemGasSponsorReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - updateEcosystemGasSponsor = ( - req: UpdateEcosystemGasSponsorArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('UpdateEcosystemGasSponsor'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'UpdateEcosystemGasSponsorReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - removeEcosystemGasSponsor = ( - req: RemoveEcosystemGasSponsorArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('RemoveEcosystemGasSponsor'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'RemoveEcosystemGasSponsorReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - addressGasSponsors = ( - req: AddressGasSponsorsArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('AddressGasSponsors'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'AddressGasSponsorsReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - getProjectBalance = ( - req: GetProjectBalanceArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('GetProjectBalance'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'GetProjectBalanceReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } - - adjustProjectBalance = ( - req: AdjustProjectBalanceArgs, - headers?: object, - signal?: AbortSignal, - ): Promise => { - return this.fetch(this.url('AdjustProjectBalance'), createHttpRequest(JsonEncode(req), headers, signal)).then( - (res) => { - return buildResponse(res).then((_data) => { - return JsonDecode(_data, 'AdjustProjectBalanceReturn') - }) - }, - (error) => { - throw WebrpcRequestFailedError.new({ - cause: `fetch(): ${error instanceof Error ? error.message : String(error)}`, - }) - }, - ) - } -} - -const createHttpRequest = (body: string = '{}', headers: object = {}, signal: AbortSignal | null = null): object => { - const reqHeaders: { [key: string]: string } = { - ...headers, - 'Content-Type': 'application/json', - [WebrpcHeader]: WebrpcHeaderValue, - } - return { method: 'POST', headers: reqHeaders, body, signal } -} - -const buildResponse = (res: Response): Promise => { - return res.text().then((text) => { - let data - try { - data = JSON.parse(text) - } catch (error) { - throw WebrpcBadResponseError.new({ - status: res.status, - cause: `JSON.parse(): ${error instanceof Error ? error.message : String(error)}: response text: ${text}`, - }) - } - if (!res.ok) { - const code: number = typeof data.code === 'number' ? data.code : 0 - throw (webrpcErrorByCode[code] || WebrpcError).new(data) - } - return data - }) -} - -export type Fetch = (input: RequestInfo, init?: RequestInit) => Promise - -// -// BigInt helpers -// - -const BIG_INT_FIELDS: { [typ: string]: (string | [string, string])[] } = { - SendMetaTxnArgs: [['preconditions', 'TransactionPrecondition[]']], - SendMetaTxnWithBridgeGasArgs: [['preconditions', 'TransactionPrecondition[]']], - TransactionPrecondition: ['minAmount'], - Transactions: [['preconditions', 'TransactionPrecondition[]']], -} - -// Decode in-place: mutate object graph; throw if expected numeric string is invalid. -function decodeType(typ: string, obj: any): any { - if (obj == null || typeof obj !== 'object') return obj - const descs = BIG_INT_FIELDS[typ] || [] - if (!descs.length) return obj - for (const d of descs) { - if (Array.isArray(d)) { - const [fieldName, nestedType] = d - if (fieldName.endsWith('[]')) { - const base = fieldName.slice(0, -2) - const arr = obj[base] - if (Array.isArray(arr)) { - for (let i = 0; i < arr.length; i++) arr[i] = decodeType(nestedType, arr[i]) - } - } else if (obj[fieldName]) { - // Handle nestedType that might be an array type like 'Message[]' - if (nestedType.endsWith('[]')) { - const baseType = nestedType.slice(0, -2) - const arr = obj[fieldName] - if (Array.isArray(arr)) { - for (let i = 0; i < arr.length; i++) arr[i] = decodeType(baseType, arr[i]) - } - } else { - obj[fieldName] = decodeType(nestedType, obj[fieldName]) - } - } - continue - } - if (d.endsWith('[]')) { - const base = d.slice(0, -2) - const arr = obj[base] - if (Array.isArray(arr)) { - for (let i = 0; i < arr.length; i++) { - const v = arr[i] - if (typeof v === 'string') { - try { - arr[i] = BigInt(v) - } catch (e) { - throw WebrpcBadResponseError.new({ cause: `Invalid bigint value for ${base}[${i}]: ${v}` }) - } - } - } - } - continue - } - const v = obj[d] - if (typeof v === 'string') { - try { - obj[d] = BigInt(v) - } catch (e) { - throw WebrpcBadResponseError.new({ cause: `Invalid bigint value for ${d}: ${v}` }) - } - } - } - return obj -} - -// Encode object to JSON with BigInts converted to decimal strings. -export const JsonEncode = (obj: T): string => { - return JSON.stringify(obj, (key, value) => (typeof value === 'bigint' ? value.toString() : value)) -} - -// Decode data (JSON string or already-parsed object) and convert declared BigInt string fields back to BigInt. -export const JsonDecode = (data: string | any, typ: string = ''): T => { - let parsed: any = data - if (typeof data === 'string') { - try { - parsed = JSON.parse(data) - } catch (err) { - throw WebrpcBadResponseError.new({ cause: `JsonDecode: JSON.parse failed: ${(err as Error).message}` }) - } - } - return decodeType(typ, parsed) as T -} - -// -// Errors -// - -type WebrpcErrorParams = { name?: string; code?: number; message?: string; status?: number; cause?: string } - -export class WebrpcError extends Error { - code: number - status: number - - constructor(error: WebrpcErrorParams = {}) { - super(error.message) - this.name = error.name || 'WebrpcEndpointError' - this.code = typeof error.code === 'number' ? error.code : 0 - this.message = error.message || `endpoint error` - this.status = typeof error.status === 'number' ? error.status : 400 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, WebrpcError.prototype) - } - - static new(payload: any): WebrpcError { - return new this({ message: payload.message, code: payload.code, status: payload.status, cause: payload.cause }) - } -} - -export class WebrpcEndpointError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'WebrpcEndpoint' - this.code = typeof error.code === 'number' ? error.code : 0 - this.message = error.message || `endpoint error` - this.status = typeof error.status === 'number' ? error.status : 400 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, WebrpcEndpointError.prototype) - } -} - -export class WebrpcRequestFailedError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'WebrpcRequestFailed' - this.code = typeof error.code === 'number' ? error.code : -1 - this.message = error.message || `request failed` - this.status = typeof error.status === 'number' ? error.status : 400 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, WebrpcRequestFailedError.prototype) - } -} - -export class WebrpcBadRouteError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'WebrpcBadRoute' - this.code = typeof error.code === 'number' ? error.code : -2 - this.message = error.message || `bad route` - this.status = typeof error.status === 'number' ? error.status : 404 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, WebrpcBadRouteError.prototype) - } -} - -export class WebrpcBadMethodError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'WebrpcBadMethod' - this.code = typeof error.code === 'number' ? error.code : -3 - this.message = error.message || `bad method` - this.status = typeof error.status === 'number' ? error.status : 405 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, WebrpcBadMethodError.prototype) - } -} - -export class WebrpcBadRequestError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'WebrpcBadRequest' - this.code = typeof error.code === 'number' ? error.code : -4 - this.message = error.message || `bad request` - this.status = typeof error.status === 'number' ? error.status : 400 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, WebrpcBadRequestError.prototype) - } -} - -export class WebrpcBadResponseError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'WebrpcBadResponse' - this.code = typeof error.code === 'number' ? error.code : -5 - this.message = error.message || `bad response` - this.status = typeof error.status === 'number' ? error.status : 500 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, WebrpcBadResponseError.prototype) - } -} - -export class WebrpcServerPanicError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'WebrpcServerPanic' - this.code = typeof error.code === 'number' ? error.code : -6 - this.message = error.message || `server panic` - this.status = typeof error.status === 'number' ? error.status : 500 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, WebrpcServerPanicError.prototype) - } -} - -export class WebrpcInternalErrorError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'WebrpcInternalError' - this.code = typeof error.code === 'number' ? error.code : -7 - this.message = error.message || `internal error` - this.status = typeof error.status === 'number' ? error.status : 500 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, WebrpcInternalErrorError.prototype) - } -} - -export class WebrpcClientAbortedError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'WebrpcClientAborted' - this.code = typeof error.code === 'number' ? error.code : -8 - this.message = error.message || `request aborted by client` - this.status = typeof error.status === 'number' ? error.status : 400 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, WebrpcClientAbortedError.prototype) - } -} - -export class WebrpcStreamLostError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'WebrpcStreamLost' - this.code = typeof error.code === 'number' ? error.code : -9 - this.message = error.message || `stream lost` - this.status = typeof error.status === 'number' ? error.status : 400 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, WebrpcStreamLostError.prototype) - } -} - -export class WebrpcStreamFinishedError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'WebrpcStreamFinished' - this.code = typeof error.code === 'number' ? error.code : -10 - this.message = error.message || `stream finished` - this.status = typeof error.status === 'number' ? error.status : 200 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, WebrpcStreamFinishedError.prototype) - } -} - -// -// Schema errors -// - -export class UnauthorizedError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'Unauthorized' - this.code = typeof error.code === 'number' ? error.code : 1000 - this.message = error.message || `Unauthorized access` - this.status = typeof error.status === 'number' ? error.status : 401 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, UnauthorizedError.prototype) - } -} - -export class PermissionDeniedError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'PermissionDenied' - this.code = typeof error.code === 'number' ? error.code : 1001 - this.message = error.message || `Permission denied` - this.status = typeof error.status === 'number' ? error.status : 403 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, PermissionDeniedError.prototype) - } -} - -export class SessionExpiredError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'SessionExpired' - this.code = typeof error.code === 'number' ? error.code : 1002 - this.message = error.message || `Session expired` - this.status = typeof error.status === 'number' ? error.status : 403 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, SessionExpiredError.prototype) - } -} - -export class MethodNotFoundError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'MethodNotFound' - this.code = typeof error.code === 'number' ? error.code : 1003 - this.message = error.message || `Method not found` - this.status = typeof error.status === 'number' ? error.status : 404 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, MethodNotFoundError.prototype) - } -} - -export class RequestConflictError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'RequestConflict' - this.code = typeof error.code === 'number' ? error.code : 1004 - this.message = error.message || `Conflict with target resource` - this.status = typeof error.status === 'number' ? error.status : 409 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, RequestConflictError.prototype) - } -} - -export class AbortedError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'Aborted' - this.code = typeof error.code === 'number' ? error.code : 1005 - this.message = error.message || `Request aborted` - this.status = typeof error.status === 'number' ? error.status : 400 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, AbortedError.prototype) - } -} - -export class GeoblockedError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'Geoblocked' - this.code = typeof error.code === 'number' ? error.code : 1006 - this.message = error.message || `Geoblocked region` - this.status = typeof error.status === 'number' ? error.status : 451 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, GeoblockedError.prototype) - } -} - -export class RateLimitedError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'RateLimited' - this.code = typeof error.code === 'number' ? error.code : 1007 - this.message = error.message || `Rate-limited. Please slow down.` - this.status = typeof error.status === 'number' ? error.status : 429 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, RateLimitedError.prototype) - } -} - -export class ProjectNotFoundError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'ProjectNotFound' - this.code = typeof error.code === 'number' ? error.code : 1008 - this.message = error.message || `Project not found` - this.status = typeof error.status === 'number' ? error.status : 401 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, ProjectNotFoundError.prototype) - } -} - -export class AccessKeyNotFoundError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'AccessKeyNotFound' - this.code = typeof error.code === 'number' ? error.code : 1101 - this.message = error.message || `Access key not found` - this.status = typeof error.status === 'number' ? error.status : 401 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, AccessKeyNotFoundError.prototype) - } -} - -export class AccessKeyMismatchError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'AccessKeyMismatch' - this.code = typeof error.code === 'number' ? error.code : 1102 - this.message = error.message || `Access key mismatch` - this.status = typeof error.status === 'number' ? error.status : 403 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, AccessKeyMismatchError.prototype) - } -} - -export class InvalidOriginError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'InvalidOrigin' - this.code = typeof error.code === 'number' ? error.code : 1103 - this.message = error.message || `Invalid origin for Access Key` - this.status = typeof error.status === 'number' ? error.status : 403 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, InvalidOriginError.prototype) - } -} - -export class InvalidServiceError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'InvalidService' - this.code = typeof error.code === 'number' ? error.code : 1104 - this.message = error.message || `Service not enabled for Access key` - this.status = typeof error.status === 'number' ? error.status : 403 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, InvalidServiceError.prototype) - } -} - -export class UnauthorizedUserError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'UnauthorizedUser' - this.code = typeof error.code === 'number' ? error.code : 1105 - this.message = error.message || `Unauthorized user` - this.status = typeof error.status === 'number' ? error.status : 403 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, UnauthorizedUserError.prototype) - } -} - -export class InvalidChainError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'InvalidChain' - this.code = typeof error.code === 'number' ? error.code : 1106 - this.message = error.message || `Network not enabled for Access key` - this.status = typeof error.status === 'number' ? error.status : 403 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, InvalidChainError.prototype) - } -} - -export class QuotaExceededError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'QuotaExceeded' - this.code = typeof error.code === 'number' ? error.code : 1200 - this.message = error.message || `Quota request exceeded` - this.status = typeof error.status === 'number' ? error.status : 429 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, QuotaExceededError.prototype) - } -} - -export class QuotaRateLimitError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'QuotaRateLimit' - this.code = typeof error.code === 'number' ? error.code : 1201 - this.message = error.message || `Quota rate limit exceeded` - this.status = typeof error.status === 'number' ? error.status : 429 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, QuotaRateLimitError.prototype) - } -} - -export class NoDefaultKeyError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'NoDefaultKey' - this.code = typeof error.code === 'number' ? error.code : 1300 - this.message = error.message || `No default access key found` - this.status = typeof error.status === 'number' ? error.status : 403 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, NoDefaultKeyError.prototype) - } -} - -export class MaxAccessKeysError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'MaxAccessKeys' - this.code = typeof error.code === 'number' ? error.code : 1301 - this.message = error.message || `Access keys limit reached` - this.status = typeof error.status === 'number' ? error.status : 403 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, MaxAccessKeysError.prototype) - } -} - -export class AtLeastOneKeyError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'AtLeastOneKey' - this.code = typeof error.code === 'number' ? error.code : 1302 - this.message = error.message || `You need at least one Access Key` - this.status = typeof error.status === 'number' ? error.status : 403 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, AtLeastOneKeyError.prototype) - } -} - -export class TimeoutError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'Timeout' - this.code = typeof error.code === 'number' ? error.code : 1900 - this.message = error.message || `Request timed out` - this.status = typeof error.status === 'number' ? error.status : 408 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, TimeoutError.prototype) - } -} - -export class InvalidArgumentError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'InvalidArgument' - this.code = typeof error.code === 'number' ? error.code : 2001 - this.message = error.message || `Invalid argument` - this.status = typeof error.status === 'number' ? error.status : 400 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, InvalidArgumentError.prototype) - } -} - -export class UnavailableError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'Unavailable' - this.code = typeof error.code === 'number' ? error.code : 2002 - this.message = error.message || `Unavailable resource` - this.status = typeof error.status === 'number' ? error.status : 400 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, UnavailableError.prototype) - } -} - -export class QueryFailedError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'QueryFailed' - this.code = typeof error.code === 'number' ? error.code : 2003 - this.message = error.message || `Query failed` - this.status = typeof error.status === 'number' ? error.status : 400 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, QueryFailedError.prototype) - } -} - -export class NotFoundError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'NotFound' - this.code = typeof error.code === 'number' ? error.code : 3000 - this.message = error.message || `Resource not found` - this.status = typeof error.status === 'number' ? error.status : 400 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, NotFoundError.prototype) - } -} - -export class InsufficientFeeError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'InsufficientFee' - this.code = typeof error.code === 'number' ? error.code : 3004 - this.message = error.message || `Insufficient fee` - this.status = typeof error.status === 'number' ? error.status : 402 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, InsufficientFeeError.prototype) - } -} - -export class NotEnoughBalanceError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'NotEnoughBalance' - this.code = typeof error.code === 'number' ? error.code : 3005 - this.message = error.message || `Not enough balance` - this.status = typeof error.status === 'number' ? error.status : 402 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, NotEnoughBalanceError.prototype) - } -} - -export class SimulationFailedError extends WebrpcError { - constructor(error: WebrpcErrorParams = {}) { - super(error) - this.name = error.name || 'SimulationFailed' - this.code = typeof error.code === 'number' ? error.code : 3006 - this.message = error.message || `Simulation failed` - this.status = typeof error.status === 'number' ? error.status : 400 - if (error.cause !== undefined) this.cause = error.cause - Object.setPrototypeOf(this, SimulationFailedError.prototype) - } -} - -export enum errors { - WebrpcEndpoint = 'WebrpcEndpoint', - WebrpcRequestFailed = 'WebrpcRequestFailed', - WebrpcBadRoute = 'WebrpcBadRoute', - WebrpcBadMethod = 'WebrpcBadMethod', - WebrpcBadRequest = 'WebrpcBadRequest', - WebrpcBadResponse = 'WebrpcBadResponse', - WebrpcServerPanic = 'WebrpcServerPanic', - WebrpcInternalError = 'WebrpcInternalError', - WebrpcClientAborted = 'WebrpcClientAborted', - WebrpcStreamLost = 'WebrpcStreamLost', - WebrpcStreamFinished = 'WebrpcStreamFinished', - Unauthorized = 'Unauthorized', - PermissionDenied = 'PermissionDenied', - SessionExpired = 'SessionExpired', - MethodNotFound = 'MethodNotFound', - RequestConflict = 'RequestConflict', - Aborted = 'Aborted', - Geoblocked = 'Geoblocked', - RateLimited = 'RateLimited', - ProjectNotFound = 'ProjectNotFound', - AccessKeyNotFound = 'AccessKeyNotFound', - AccessKeyMismatch = 'AccessKeyMismatch', - InvalidOrigin = 'InvalidOrigin', - InvalidService = 'InvalidService', - UnauthorizedUser = 'UnauthorizedUser', - InvalidChain = 'InvalidChain', - QuotaExceeded = 'QuotaExceeded', - QuotaRateLimit = 'QuotaRateLimit', - NoDefaultKey = 'NoDefaultKey', - MaxAccessKeys = 'MaxAccessKeys', - AtLeastOneKey = 'AtLeastOneKey', - Timeout = 'Timeout', - InvalidArgument = 'InvalidArgument', - Unavailable = 'Unavailable', - QueryFailed = 'QueryFailed', - NotFound = 'NotFound', - InsufficientFee = 'InsufficientFee', - NotEnoughBalance = 'NotEnoughBalance', - SimulationFailed = 'SimulationFailed', -} - -export enum WebrpcErrorCodes { - WebrpcEndpoint = 0, - WebrpcRequestFailed = -1, - WebrpcBadRoute = -2, - WebrpcBadMethod = -3, - WebrpcBadRequest = -4, - WebrpcBadResponse = -5, - WebrpcServerPanic = -6, - WebrpcInternalError = -7, - WebrpcClientAborted = -8, - WebrpcStreamLost = -9, - WebrpcStreamFinished = -10, - Unauthorized = 1000, - PermissionDenied = 1001, - SessionExpired = 1002, - MethodNotFound = 1003, - RequestConflict = 1004, - Aborted = 1005, - Geoblocked = 1006, - RateLimited = 1007, - ProjectNotFound = 1008, - AccessKeyNotFound = 1101, - AccessKeyMismatch = 1102, - InvalidOrigin = 1103, - InvalidService = 1104, - UnauthorizedUser = 1105, - InvalidChain = 1106, - QuotaExceeded = 1200, - QuotaRateLimit = 1201, - NoDefaultKey = 1300, - MaxAccessKeys = 1301, - AtLeastOneKey = 1302, - Timeout = 1900, - InvalidArgument = 2001, - Unavailable = 2002, - QueryFailed = 2003, - NotFound = 3000, - InsufficientFee = 3004, - NotEnoughBalance = 3005, - SimulationFailed = 3006, -} - -export const webrpcErrorByCode: { [code: number]: any } = { - [0]: WebrpcEndpointError, - [-1]: WebrpcRequestFailedError, - [-2]: WebrpcBadRouteError, - [-3]: WebrpcBadMethodError, - [-4]: WebrpcBadRequestError, - [-5]: WebrpcBadResponseError, - [-6]: WebrpcServerPanicError, - [-7]: WebrpcInternalErrorError, - [-8]: WebrpcClientAbortedError, - [-9]: WebrpcStreamLostError, - [-10]: WebrpcStreamFinishedError, - [1000]: UnauthorizedError, - [1001]: PermissionDeniedError, - [1002]: SessionExpiredError, - [1003]: MethodNotFoundError, - [1004]: RequestConflictError, - [1005]: AbortedError, - [1006]: GeoblockedError, - [1007]: RateLimitedError, - [1008]: ProjectNotFoundError, - [1101]: AccessKeyNotFoundError, - [1102]: AccessKeyMismatchError, - [1103]: InvalidOriginError, - [1104]: InvalidServiceError, - [1105]: UnauthorizedUserError, - [1106]: InvalidChainError, - [1200]: QuotaExceededError, - [1201]: QuotaRateLimitError, - [1300]: NoDefaultKeyError, - [1301]: MaxAccessKeysError, - [1302]: AtLeastOneKeyError, - [1900]: TimeoutError, - [2001]: InvalidArgumentError, - [2002]: UnavailableError, - [2003]: QueryFailedError, - [3000]: NotFoundError, - [3004]: InsufficientFeeError, - [3005]: NotEnoughBalanceError, - [3006]: SimulationFailedError, -} - -// -// Webrpc -// - -export const WebrpcHeader = 'Webrpc' - -export const WebrpcHeaderValue = 'webrpc@v0.32.2;gen-typescript@v0.23.1;sequence-relayer@v0.4.1' - -type WebrpcGenVersions = { - WebrpcGenVersion: string - codeGenName: string - codeGenVersion: string - schemaName: string - schemaVersion: string -} - -export function VersionFromHeader(headers: Headers): WebrpcGenVersions { - const headerValue = headers.get(WebrpcHeader) - if (!headerValue) { - return { - WebrpcGenVersion: '', - codeGenName: '', - codeGenVersion: '', - schemaName: '', - schemaVersion: '', - } - } - - return parseWebrpcGenVersions(headerValue) -} - -function parseWebrpcGenVersions(header: string): WebrpcGenVersions { - const versions = header.split(';') - if (versions.length < 3) { - return { - WebrpcGenVersion: '', - codeGenName: '', - codeGenVersion: '', - schemaName: '', - schemaVersion: '', - } - } - - const [_, WebrpcGenVersion] = versions[0]!.split('@') - const [codeGenName, codeGenVersion] = versions[1]!.split('@') - const [schemaName, schemaVersion] = versions[2]!.split('@') - - return { - WebrpcGenVersion: WebrpcGenVersion ?? '', - codeGenName: codeGenName ?? '', - codeGenVersion: codeGenVersion ?? '', - schemaName: schemaName ?? '', - schemaVersion: schemaVersion ?? '', - } -} diff --git a/packages/test/package.json b/packages/test/package.json new file mode 100644 index 0000000000..d1c6fb9c19 --- /dev/null +++ b/packages/test/package.json @@ -0,0 +1,118 @@ +{ + "name": "@wagmi/test", + "description": "Test utils for wagmi", + "private": true, + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/wevm/wagmi.git", + "directory": "packages/test" + }, + "scripts": { + "build": "pnpm run clean && pnpm run build:esm+types", + "build:esm+types": "tsc --project tsconfig.build.json --outDir ./dist/esm --declaration --declarationMap --declarationDir ./dist/types", + "check:types": "tsc --noEmit", + "clean": "rm -rf dist tsconfig.tsbuildinfo", + "test:build": "publint --strict" + }, + "files": [ + "dist/**", + "!dist/**/*.tsbuildinfo", + "src/**/*.ts", + "!src/**/*.test.ts", + "!src/**/*.test-d.ts", + "react/**", + "vue/**" + ], + "sideEffects": false, + "type": "module", + "main": "./dist/esm/exports/index.js", + "types": "./dist/types/exports/index.d.ts", + "typings": "./dist/types/exports/index.d.ts", + "exports": { + ".": { + "types": "./dist/types/exports/index.d.ts", + "default": "./dist/esm/exports/index.js" + }, + "./react": { + "types": "./dist/types/exports/react.d.ts", + "default": "./dist/esm/exports/react.js" + }, + "./vue": { + "types": "./dist/types/exports/vue.d.ts", + "default": "./dist/esm/exports/vue.js" + }, + "./package.json": "./package.json" + }, + "typesVersions": { + "*": { + "react": ["./dist/types/exports/react.d.ts"], + "vue": ["./dist/types/exports/vue.d.ts"] + } + }, + "peerDependencies": { + "@tanstack/react-query": ">=5.0.0", + "@tanstack/vue-query": ">=5.0.0", + "@testing-library/react": ">=14.0.0", + "@types/react": ">=18", + "@types/react-dom": ">=18", + "@wagmi/core": "workspace:*", + "@wagmi/vue": "workspace:*", + "prool": "^0.0.23", + "react": ">=18", + "react-dom": ">=18", + "typescript": ">=5.0.4", + "viem": "2.x", + "vue": ">=3", + "wagmi": "workspace:*" + }, + "peerDependenciesMeta": { + "@tanstack/react-query": { + "optional": true + }, + "@tanstack/vue-query": { + "optional": true + }, + "@testing-library/react": { + "optional": true + }, + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + }, + "react": { + "optional": true + }, + "react-dom": { + "optional": true + }, + "typescript": { + "optional": true + }, + "vue": { + "optional": true + }, + "wagmi": { + "optional": true + } + }, + "devDependencies": { + "@tanstack/react-query": "catalog:", + "@tanstack/vue-query": "catalog:", + "@testing-library/dom": "catalog:", + "@testing-library/react": "catalog:", + "@types/react": "catalog:", + "@types/react-dom": "catalog:", + "@wagmi/core": "workspace:*", + "@wagmi/vue": "workspace:*", + "react": "catalog:", + "react-dom": "catalog:", + "vue": "catalog:", + "wagmi": "workspace:*" + }, + "contributors": ["awkweb.eth ", "jxom.eth "], + "funding": "https://github.com/sponsors/wevm", + "keywords": ["eth", "ethereum", "dapps", "wallet", "web3"] +} diff --git a/packages/test/src/chains.ts b/packages/test/src/chains.ts new file mode 100644 index 0000000000..af9bdc5d99 --- /dev/null +++ b/packages/test/src/chains.ts @@ -0,0 +1,51 @@ +import type { Compute } from '@wagmi/core/internal' +import { + type Chain as viem_Chain, + mainnet as viem_mainnet, + optimism as viem_optimism, +} from 'viem/chains' + +import { getRpcUrls } from './utils.js' + +type Fork = { blockNumber: bigint; url: string } + +export type Chain = Compute< + viem_Chain & { + fork: Fork + port: number + } +> + +const mainnetFork = { + blockNumber: 19_258_213n, + url: process.env.VITE_MAINNET_FORK_URL ?? 'https://eth.merkle.io', +} as const satisfies Fork + +export const mainnet = { + ...viem_mainnet, + ...getRpcUrls({ port: 8545 }), + fork: mainnetFork, +} as const satisfies Chain + +export const mainnet2 = { + ...viem_mainnet, + ...getRpcUrls({ port: 8546 }), + id: 456, + nativeCurrency: { decimals: 18, name: 'wagmi', symbol: 'WAG' }, + fork: mainnetFork, +} as const satisfies Chain + +export const optimism = { + ...getRpcUrls({ port: 8547 }), + ...viem_optimism, + fork: { + blockNumber: 107_317_577n, + url: process.env.VITE_OPTIMISM_FORK_URL ?? 'https://mainnet.optimism.io', + }, +} as const satisfies Chain + +export const chain = { + mainnet, + mainnet2, + optimism, +} diff --git a/packages/test/src/clients.ts b/packages/test/src/clients.ts new file mode 100644 index 0000000000..5a2d86005a --- /dev/null +++ b/packages/test/src/clients.ts @@ -0,0 +1,62 @@ +import { + http, + type Account, + type Client, + type TestActions, + type TestRpcSchema, + type Transport, + createTestClient, +} from 'viem' + +import { type Chain, mainnet, mainnet2, optimism } from './chains.js' + +export const mainnetTestClient = createTestClient({ + mode: 'anvil', + cacheTime: 0, + chain: mainnet, + transport: http(), +}).extend(wagmiTestMethods) + +export const mainnet2TestClient = createTestClient({ + mode: 'anvil', + cacheTime: 0, + chain: mainnet2, + transport: http(), +}).extend(wagmiTestMethods) + +export const optimismTestClient = createTestClient({ + mode: 'anvil', + cacheTime: 0, + chain: optimism, + transport: http(), +}).extend(wagmiTestMethods) + +export const testClient = { + mainnet: mainnetTestClient, + mainnet2: mainnet2TestClient, + optimism: optimismTestClient, +} + +function wagmiTestMethods( + client: Client< + Transport, + Chain, + Account | undefined, + TestRpcSchema<'anvil'>, + TestActions + >, +) { + return { + /** Resets instance attached to chain. */ + async restart() { + return await fetch(`${client.chain.rpcUrls.default.http[0]}/restart`) + }, + /** Resets fork attached to chain at starting block number. */ + resetFork() { + return client.reset({ + jsonRpcUrl: client.chain.fork.url, + blockNumber: client.chain.fork.blockNumber, + }) + }, + } +} diff --git a/packages/test/src/config.ts b/packages/test/src/config.ts new file mode 100644 index 0000000000..a94cdf45de --- /dev/null +++ b/packages/test/src/config.ts @@ -0,0 +1,29 @@ +import { createConfig, mock } from '@wagmi/core' +import { http } from 'viem' + +import { mainnet, mainnet2, optimism } from './chains.js' +import { accounts } from './constants.js' + +export const config = createConfig({ + chains: [mainnet, mainnet2, optimism], + connectors: [mock({ accounts }), mock({ accounts: reverse(accounts) })], + pollingInterval: 100, + storage: null, + transports: { + [mainnet.id]: http(), + [mainnet2.id]: http(), + [optimism.id]: http(), + }, +}) + +type Reverse< + list extends readonly unknown[], + /// + result extends readonly unknown[] = [], +> = list extends readonly [infer head, ...infer tail] + ? Reverse + : result + +function reverse(list: list): Reverse { + return [...list].reverse() as Reverse +} diff --git a/packages/test/src/constants.ts b/packages/test/src/constants.ts new file mode 100644 index 0000000000..96ca5a9efa --- /dev/null +++ b/packages/test/src/constants.ts @@ -0,0 +1,318 @@ +import { type Address, parseAbi } from 'viem' + +import type { chain } from './chains.js' + +/** + * The id of the current test worker. + * + * This is used by the anvil proxy to route requests to the correct anvil instance. + */ +export const pool = Number(process.env.VITEST_POOL_ID ?? 1) + +// Test accounts +export const accounts = [ + '0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266', + '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + '0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC', + '0x90F79bf6EB2c4f870365E785982E1f101E93b906', + '0x15d34aaf54267db7d7c367839aaf71a00a2c6a65', + '0x9965507D1a55bcC2695C58ba16FB37d819B0A4dc', + '0x976EA74026E726554dB657fA54763abd0C3a0aa9', + '0x14dC79964da2C08b23698B3D3cc7Ca32193d9955', + '0x23618e81E3f5cdF7f54C3d65f7FBc0aBf5B21E8f', + '0xa0Ee7A142d267C1f36714E4a8F75612F20a79720', +] as const + +// for `'0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266'` +export const privateKey = + '0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80' + +export let walletConnectProjectId: string +if (process.env.VITE_WC_PROJECT_ID) + walletConnectProjectId = process.env.VITE_WC_PROJECT_ID +else walletConnectProjectId = 'foobarbaz' + +export const typedData = { + basic: { + domain: { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0x0000000000000000000000000000000000000000', + }, + types: { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], + }, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + }, + complex: { + domain: { + name: 'Ether Mail 🥵', + version: '1.1.1', + chainId: 1, + verifyingContract: '0x0000000000000000000000000000000000000000', + }, + types: { + Name: [ + { name: 'first', type: 'string' }, + { name: 'last', type: 'string' }, + ], + Person: [ + { name: 'name', type: 'Name' }, + { name: 'wallet', type: 'address' }, + { name: 'favoriteColors', type: 'string[3]' }, + { name: 'foo', type: 'uint256' }, + { name: 'age', type: 'uint8' }, + { name: 'isCool', type: 'bool' }, + ], + Mail: [ + { name: 'timestamp', type: 'uint256' }, + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + { name: 'hash', type: 'bytes' }, + ], + }, + message: { + timestamp: 1234567890n, + contents: 'Hello, Bob! 🖤', + hash: '0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef', + from: { + name: { + first: 'Cow', + last: 'Burns', + }, + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + age: 69, + foo: 123123123123123123n, + favoriteColors: ['red', 'green', 'blue'], + isCool: false, + }, + to: { + name: { first: 'Bob', last: 'Builder' }, + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + age: 70, + foo: 123123123123123123n, + favoriteColors: ['orange', 'yellow', 'green'], + isCool: true, + }, + }, + }, +} as const + +export const abi = { + erc20: parseAbi([ + 'event Approval(address indexed owner, address indexed spender, uint256 value)', + 'event Transfer(address indexed from, address indexed to, uint256 value)', + 'function allowance(address owner, address spender) view returns (uint256)', + 'function approve(address spender, uint256 amount) returns (bool)', + 'function balanceOf(address account) view returns (uint256)', + 'function decimals() view returns (uint8)', + 'function name() view returns (string)', + 'function symbol() view returns (string)', + 'function totalSupply() view returns (uint256)', + 'function transfer(address recipient, uint256 amount) returns (bool)', + 'function transferFrom(address sender, address recipient, uint256 amount) returns (bool)', + ]), + mloot: parseAbi([ + 'constructor()', + 'event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId)', + 'event ApprovalForAll(address indexed owner, address indexed operator, bool approved)', + 'event OwnershipTransferred(address indexed previousOwner, address indexed newOwner)', + 'event Transfer(address indexed from, address indexed to, uint256 indexed tokenId)', + 'function approve(address to, uint256 tokenId)', + 'function balanceOf(address owner) view returns (uint256)', + 'function claim(uint256 tokenId)', + 'function getApproved(uint256 tokenId) view returns (address)', + 'function getChest(uint256 tokenId) view returns (string)', + 'function getFoot(uint256 tokenId) view returns (string)', + 'function getHand(uint256 tokenId) view returns (string)', + 'function getHead(uint256 tokenId) view returns (string)', + 'function getNeck(uint256 tokenId) view returns (string)', + 'function getRing(uint256 tokenId) view returns (string)', + 'function getWaist(uint256 tokenId) view returns (string)', + 'function getWeapon(uint256 tokenId) view returns (string)', + 'function isApprovedForAll(address owner, address operator) view returns (bool)', + 'function name() view returns (string)', + 'function owner() view returns (address)', + 'function ownerOf(uint256 tokenId) view returns (address)', + 'function renounceOwnership()', + 'function safeTransferFrom(address from, address to, uint256 tokenId)', + 'function safeTransferFrom(address from, address to, uint256 tokenId, bytes _data)', + 'function setApprovalForAll(address operator, bool approved)', + 'function supportsInterface(bytes4 interfaceId) view returns (bool)', + 'function symbol() view returns (string)', + 'function tokenByIndex(uint256 index) view returns (uint256)', + 'function tokenOfOwnerByIndex(address owner, uint256 index) view returns (uint256)', + 'function tokenURI(uint256 tokenId) view returns (string)', + 'function totalSupply() view returns (uint256)', + 'function transferFrom(address from, address to, uint256 tokenId)', + 'function transferOwnership(address newOwner)', + ]), + shields: parseAbi([ + 'constructor(string name_, string symbol_, address _emblemWeaver, address makerBadgeRecipient, address granteeBadgeRecipient)', + 'event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId)', + 'event ApprovalForAll(address indexed owner, address indexed operator, bool approved)', + 'event OwnershipTransferred(address indexed previousOwner, address indexed newOwner)', + 'event ShieldBuilt(uint256 tokenId, uint16 field, uint16 hardware, uint16 frame, uint24[4] colors, uint8 shieldBadge)', + 'event Transfer(address indexed from, address indexed to, uint256 indexed tokenId)', + 'function approve(address to, uint256 tokenId)', + 'function balanceOf(address owner) view returns (uint256)', + 'function build(uint16 field, uint16 hardware, uint16 frame, uint24[4] colors, uint256 tokenId) payable', + 'function collectFees()', + 'function emblemWeaver() view returns (address)', + 'function getApproved(uint256 tokenId) view returns (address)', + 'function isApprovedForAll(address owner, address operator) view returns (bool)', + 'function mint(address to, uint8 count) payable', + 'function mythicFee() view returns (uint256)', + 'function name() view returns (string)', + 'function owner() view returns (address)', + 'function ownerOf(uint256 tokenId) view returns (address)', + 'function publicMintActive() view returns (bool)', + 'function publicMintPrice() view returns (uint256)', + 'function renounceOwnership()', + 'function safeTransferFrom(address from, address to, uint256 tokenId)', + 'function safeTransferFrom(address from, address to, uint256 tokenId, bytes _data)', + 'function setApprovalForAll(address operator, bool approved)', + 'function setPublicMintActive()', + 'function setPublicMintPrice(uint256 _publicMintPrice)', + 'function shieldHashes(bytes32) view returns (bool)', + 'function shields(uint256 tokenId) view returns (uint16 field, uint16 hardware, uint16 frame, uint24 color1, uint24 color2, uint24 color3, uint24 color4, uint8 shieldBadge)', + 'function specialFee() view returns (uint256)', + 'function supportsInterface(bytes4 interfaceId) view returns (bool)', + 'function symbol() view returns (string)', + 'function tokenURI(uint256 tokenId) view returns (string)', + 'function totalSupply() view returns (uint256)', + 'function transferFrom(address from, address to, uint256 tokenId)', + 'function transferOwnership(address newOwner)', + ]), + wagmigotchi: parseAbi([ + 'constructor()', + 'event CaretakerLoved(address indexed caretaker, uint256 indexed amount)', + 'function clean()', + 'function feed()', + 'function getAlive() view returns (bool)', + 'function getBoredom() view returns (uint256)', + 'function getHunger() view returns (uint256)', + 'function getSleepiness() view returns (uint256)', + 'function getStatus() view returns (string)', + 'function getUncleanliness() view returns (uint256)', + 'function love(address) view returns (uint256)', + 'function play()', + 'function sleep()', + ]), + wagmiMintExample: parseAbi([ + 'constructor()', + 'event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId)', + 'event ApprovalForAll(address indexed owner, address indexed operator, bool approved)', + 'event Transfer(address indexed from, address indexed to, uint256 indexed tokenId)', + 'function approve(address to, uint256 tokenId)', + 'function balanceOf(address owner) view returns (uint256)', + 'function getApproved(uint256 tokenId) view returns (address)', + 'function isApprovedForAll(address owner, address operator) view returns (bool)', + 'function mint()', + 'function name() view returns (string)', + 'function ownerOf(uint256 tokenId) view returns (address)', + 'function safeTransferFrom(address from, address to, uint256 tokenId)', + 'function safeTransferFrom(address from, address to, uint256 tokenId, bytes _data)', + 'function setApprovalForAll(address operator, bool approved)', + 'function supportsInterface(bytes4 interfaceId) view returns (bool)', + 'function symbol() view returns (string)', + 'function tokenURI(uint256 tokenId) pure returns (string)', + 'function totalSupply() view returns (uint256)', + 'function transferFrom(address from, address to, uint256 tokenId)', + ]), + viewOverloads: parseAbi([ + 'function foo() view returns (int8)', + 'function foo(address) view returns (string)', + 'function foo(address, address) view returns ((address foo, address bar))', + 'function bar() view returns (int8)', + ]), + writeOverloads: parseAbi([ + 'function foo() payable returns (int8)', + 'function foo(address) returns (string)', + 'function foo(address, address) returns ((address foo, address bar))', + 'function bar() payable returns (int8)', + ]), + bayc: parseAbi([ + 'constructor(string name, string symbol, uint256 maxNftSupply, uint256 saleStart)', + 'function mintApe(uint256 numberOfTokens) payable', + 'function reserveApes()', + 'function flipSaleState()', + 'function emergencySetStartingIndexBlock()', + 'function setStartingIndex()', + 'function setRevealTimestamp(uint256 revealTimeStamp)', + 'function setProvenanceHash(string provenanceHash)', + 'function setBaseURI(string baseURI)', + 'function startingIndex() view returns (uint256)', + 'function startingIndexBlock() view returns (uint256)', + 'function saleIsActive() view returns (bool)', + 'function maxApePurchase() view returns (uint256)', + 'function apePrice() view returns (uint256)', + 'function REVEAL_TIMESTAMP() view returns (uint256)', + 'function MAX_APES() view returns (uint256)', + 'function BAYC_PROVENANCE() view returns (string)', + 'function name() view returns (string)', + 'function symbol() view returns (string)', + 'function totalSupply() view returns (uint256)', + 'function balanceOf(address owner) view returns (uint256)', + 'function ownerOf(uint256 tokenId) view returns (address)', + 'function getApproved(uint256 tokenId) view returns (address)', + 'function isApprovedForAll(address owner, address operator) view returns (bool)', + 'function approve(address to, uint256 tokenId)', + 'function setApprovalForAll(address operator, bool approved)', + 'function safeTransferFrom(address from, address to, uint256 tokenId)', + 'function safeTransferFrom(address from, address to, uint256 tokenId, bytes _data)', + 'function tokenOfOwnerByIndex(address owner, uint256 index) view returns (uint256)', + 'function tokenByIndex(uint256 index) view returns (uint256)', + 'function tokenURI(uint256 tokenId) view returns (string)', + 'function supportsInterface(bytes4 interfaceId) view returns (bool)', + 'function transferFrom(address from, address to, uint256 tokenId)', + 'function renounceOwnership()', + 'function transferOwnership(address newOwner)', + 'function withdraw()', + ]), +} as const + +const mainnetAddress = { + mloot: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + shields: '0x0747118c9f44c7a23365b2476dcd05e03114c747', + usdc: '0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48', + usdcHolder: '0x5414d89a8bf7e99d732bc52f3e6a3ef461c0c078', + wagmigotchi: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + wagmiMintExample: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', +} as const + +export const address = { + ...mainnetAddress, + mainnet: mainnetAddress, + mainnet2: mainnetAddress, + optimism: { + usdc: '0x7f5c764cbc14f9669b88837ca1490cca17c31607', + }, +} as const satisfies Record & + Record> + +export const bytecode = { + bayc: '0x608060405260405180602001604052806000815250600b90805190602001906200002b92919062000484565b506000600f60006101000a81548160ff0219169083151502179055503480156200005457600080fd5b50604051620046d0380380620046d0833981810160405260808110156200007a57600080fd5b81019080805160405193929190846401000000008211156200009b57600080fd5b83820191506020820185811115620000b257600080fd5b8251866001820283011164010000000082111715620000d057600080fd5b8083526020830192505050908051906020019080838360005b8381101562000106578082015181840152602081019050620000e9565b50505050905090810190601f168015620001345780820380516001836020036101000a031916815260200191505b50604052602001805160405193929190846401000000008211156200015857600080fd5b838201915060208201858111156200016f57600080fd5b82518660018202830111640100000000821117156200018d57600080fd5b8083526020830192505050908051906020019080838360005b83811015620001c3578082015181840152602081019050620001a6565b50505050905090810190601f168015620001f15780820380516001836020036101000a031916815260200191505b5060405260200180519060200190929190805190602001909291905050508383620002296301ffc9a760e01b6200037360201b60201c565b81600690805190602001906200024192919062000484565b5080600790805190602001906200025a92919062000484565b50620002736380ac58cd60e01b6200037360201b60201c565b6200028b635b5e139f60e01b6200037360201b60201c565b620002a363780e9d6360e01b6200037360201b60201c565b50506000620002b76200047c60201b60201c565b905080600a60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35081600e81905550620bdd808101601081905550505050506200052a565b63ffffffff60e01b817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916141562000410576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601c8152602001807f4552433136353a20696e76616c696420696e746572666163652069640000000081525060200191505060405180910390fd5b6001600080837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200190815260200160002060006101000a81548160ff02191690831515021790555050565b600033905090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620004c757805160ff1916838001178555620004f8565b82800160010185558215620004f8579182015b82811115620004f7578251825591602001919060010190620004da565b5b5090506200050791906200050b565b5090565b5b80821115620005265760008160009055506001016200050c565b5090565b614196806200053a6000396000f3fe60806040526004361061021a5760003560e01c80636c0360eb11610123578063b0f67427116100ab578063e36d64981161006f578063e36d649814610ddf578063e985e9c514610e0a578063e986655014610e91578063eb8d244414610ea8578063f2fde38b14610ed55761021a565b8063b0f6742714610bac578063b88d4fde14610bc3578063bb8a16bd14610cd5578063c87b56dd14610d00578063cb774d4714610db45761021a565b80637d17fcbe116100f25780637d17fcbe14610a395780638da5cb5b14610a5057806395d89b4114610a91578063a22cb46514610b21578063a723533e14610b7e5761021a565b80636c0360eb1461090257806370a0823114610992578063715018a6146109f75780637a3f451e14610a0e5761021a565b80632f745c59116101a65780634f6ccce7116101755780634f6ccce7146106cb57806355f804b31461071a578063571dff3b146107e2578063607e20e31461080d5780636352211e1461089d5761021a565b80632f745c59146105b357806334918dfd146106225780633ccfd60b1461063957806342842e0e146106505761021a565b8063095ea7b3116101ed578063095ea7b3146103bf578063109695231461041a57806318160ddd146104e257806318e20a381461050d57806323b872dd146105385761021a565b8063018a2c371461021f57806301ffc9a71461025a57806306fdde03146102ca578063081812fc1461035a575b600080fd5b34801561022b57600080fd5b506102586004803603602081101561024257600080fd5b8101908080359060200190929190505050610f26565b005b34801561026657600080fd5b506102b26004803603602081101561027d57600080fd5b8101908080357bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19169060200190929190505050610fdf565b60405180821515815260200191505060405180910390f35b3480156102d657600080fd5b506102df611046565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561031f578082015181840152602081019050610304565b50505050905090810190601f16801561034c5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561036657600080fd5b506103936004803603602081101561037d57600080fd5b81019080803590602001909291905050506110e8565b604051808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b3480156103cb57600080fd5b50610418600480360360408110156103e257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611183565b005b34801561042657600080fd5b506104e06004803603602081101561043d57600080fd5b810190808035906020019064010000000081111561045a57600080fd5b82018360208201111561046c57600080fd5b8035906020019184600183028401116401000000008311171561048e57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f8201169050808301925050505050505091929192905050506112c7565b005b3480156104ee57600080fd5b506104f7611390565b6040518082815260200191505060405180910390f35b34801561051957600080fd5b506105226113a1565b6040518082815260200191505060405180910390f35b34801561054457600080fd5b506105b16004803603606081101561055b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506113a7565b005b3480156105bf57600080fd5b5061060c600480360360408110156105d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061141d565b6040518082815260200191505060405180910390f35b34801561062e57600080fd5b50610637611478565b005b34801561064557600080fd5b5061064e611553565b005b34801561065c57600080fd5b506106c96004803603606081101561067357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611651565b005b3480156106d757600080fd5b50610704600480360360208110156106ee57600080fd5b8101908080359060200190929190505050611671565b6040518082815260200191505060405180910390f35b34801561072657600080fd5b506107e06004803603602081101561073d57600080fd5b810190808035906020019064010000000081111561075a57600080fd5b82018360208201111561076c57600080fd5b8035906020019184600183028401116401000000008311171561078e57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f820116905080830192505050505050509192919290505050611694565b005b3480156107ee57600080fd5b506107f761174f565b6040518082815260200191505060405180910390f35b34801561081957600080fd5b50610822611754565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610862578082015181840152602081019050610847565b50505050905090810190601f16801561088f5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156108a957600080fd5b506108d6600480360360208110156108c057600080fd5b81019080803590602001909291905050506117f2565b604051808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561090e57600080fd5b50610917611829565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561095757808201518184015260208101905061093c565b50505050905090810190601f1680156109845780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561099e57600080fd5b506109e1600480360360208110156109b557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506118cb565b6040518082815260200191505060405180910390f35b348015610a0357600080fd5b50610a0c6119a0565b005b348015610a1a57600080fd5b50610a23611b10565b6040518082815260200191505060405180910390f35b348015610a4557600080fd5b50610a4e611b1c565b005b348015610a5c57600080fd5b50610a65611c4c565b604051808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b348015610a9d57600080fd5b50610aa6611c76565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610ae6578082015181840152602081019050610acb565b50505050905090810190601f168015610b135780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b348015610b2d57600080fd5b50610b7c60048036036040811015610b4457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803515159060200190929190505050611d18565b005b610baa60048036036020811015610b9457600080fd5b8101908080359060200190929190505050611ece565b005b348015610bb857600080fd5b50610bc1612127565b005b348015610bcf57600080fd5b50610cd360048036036080811015610be657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190640100000000811115610c4d57600080fd5b820183602082011115610c5f57600080fd5b80359060200191846001830284011164010000000083111715610c8157600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050919291929050505061220b565b005b348015610ce157600080fd5b50610cea612283565b6040518082815260200191505060405180910390f35b348015610d0c57600080fd5b50610d3960048036036020811015610d2357600080fd5b8101908080359060200190929190505050612289565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610d79578082015181840152602081019050610d5e565b50505050905090810190601f168015610da65780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b348015610dc057600080fd5b50610dc961255a565b6040518082815260200191505060405180910390f35b348015610deb57600080fd5b50610df4612560565b6040518082815260200191505060405180910390f35b348015610e1657600080fd5b50610e7960048036036040811015610e2d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612566565b60405180821515815260200191505060405180910390f35b348015610e9d57600080fd5b50610ea66125fa565b005b348015610eb457600080fd5b50610ebd612764565b60405180821515815260200191505060405180910390f35b348015610ee157600080fd5b50610f2460048036036020811015610ef857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612777565b005b610f2e61296c565b73ffffffffffffffffffffffffffffffffffffffff16610f4c611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614610fd5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b8060108190555050565b6000806000837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200190815260200160002060009054906101000a900460ff169050919050565b606060068054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156110de5780601f106110b3576101008083540402835291602001916110de565b820191906000526020600020905b8154815290600101906020018083116110c157829003601f168201915b5050505050905090565b60006110f382612974565b611148576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c81526020018061408b602c913960400191505060405180910390fd5b6004600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b600061118e826117f2565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415611215576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602181526020018061410f6021913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff1661123461296c565b73ffffffffffffffffffffffffffffffffffffffff16148061126357506112628161125d61296c565b612566565b5b6112b8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526038815260200180613f956038913960400191505060405180910390fd5b6112c28383612991565b505050565b6112cf61296c565b73ffffffffffffffffffffffffffffffffffffffff166112ed611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614611376576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b80600b908051906020019061138c929190613de6565b5050565b600061139c6002612a4a565b905090565b60105481565b6113b86113b261296c565b82612a5f565b61140d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260318152602001806141306031913960400191505060405180910390fd5b611418838383612b53565b505050565b600061147082600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020612d9690919063ffffffff16565b905092915050565b61148061296c565b73ffffffffffffffffffffffffffffffffffffffff1661149e611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614611527576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600f60009054906101000a900460ff1615600f60006101000a81548160ff021916908315150217905550565b61155b61296c565b73ffffffffffffffffffffffffffffffffffffffff16611579611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614611602576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b60004790503373ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f1935050505015801561164d573d6000803e3d6000fd5b5050565b61166c8383836040518060200160405280600081525061220b565b505050565b600080611688836002612db090919063ffffffff16565b50905080915050919050565b61169c61296c565b73ffffffffffffffffffffffffffffffffffffffff166116ba611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614611743576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b61174c81612ddc565b50565b601481565b600b8054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156117ea5780601f106117bf576101008083540402835291602001916117ea565b820191906000526020600020905b8154815290600101906020018083116117cd57829003601f168201915b505050505081565b600061182282604051806060016040528060298152602001613ff7602991396002612df69092919063ffffffff16565b9050919050565b606060098054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156118c15780601f10611896576101008083540402835291602001916118c1565b820191906000526020600020905b8154815290600101906020018083116118a457829003601f168201915b5050505050905090565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611952576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a815260200180613fcd602a913960400191505060405180910390fd5b611999600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020612e15565b9050919050565b6119a861296c565b73ffffffffffffffffffffffffffffffffffffffff166119c6611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614611a4f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff16600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a36000600a60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b67011c37937e08000081565b611b2461296c565b73ffffffffffffffffffffffffffffffffffffffff16611b42611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614611bcb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b6000600d5414611c43576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601d8152602001807f5374617274696e6720696e64657820697320616c72656164792073657400000081525060200191505060405180910390fd5b43600c81905550565b6000600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b606060078054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015611d0e5780601f10611ce357610100808354040283529160200191611d0e565b820191906000526020600020905b815481529060010190602001808311611cf157829003601f168201915b5050505050905090565b611d2061296c565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611dc1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260198152602001807f4552433732313a20617070726f766520746f2063616c6c65720000000000000081525060200191505060405180910390fd5b8060056000611dce61296c565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff16611e7b61296c565b73ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c318360405180821515815260200191505060405180910390a35050565b600f60009054906101000a900460ff16611f50576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f53616c65206d7573742062652061637469766520746f206d696e74204170650081525060200191505060405180910390fd5b6014811115611faa576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180613f746021913960400191505060405180910390fd5b600e54611fc782611fb9611390565b612e2a90919063ffffffff16565b111561201e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260288152602001806140426028913960400191505060405180910390fd5b3461203a8267011c37937e080000612eb290919063ffffffff16565b11156120ae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45746865722076616c75652073656e74206973206e6f7420636f72726563740081525060200191505060405180910390fd5b60005b818110156120ef5760006120c3611390565b9050600e546120d0611390565b10156120e1576120e03382612f38565b5b5080806001019150506120b1565b506000600c541480156121175750600e54612108611390565b148061211657506010544210155b5b156121245743600c819055505b50565b61212f61296c565b73ffffffffffffffffffffffffffffffffffffffff1661214d611c4c565b73ffffffffffffffffffffffffffffffffffffffff16146121d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b60006121e0611390565b905060005b601e811015612207576121fa33828401612f38565b80806001019150506121e5565b5050565b61221c61221661296c565b83612a5f565b612271576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260318152602001806141306031913960400191505060405180910390fd5b61227d84848484612f56565b50505050565b600e5481565b606061229482612974565b6122e9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602f8152602001806140e0602f913960400191505060405180910390fd5b6060600860008481526020019081526020016000208054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156123925780601f1061236757610100808354040283529160200191612392565b820191906000526020600020905b81548152906001019060200180831161237557829003601f168201915b5050505050905060606123a3611829565b90506000815114156123b9578192505050612555565b60008251111561248a5780826040516020018083805190602001908083835b602083106123fb57805182526020820191506020810190506020830392506123d8565b6001836020036101000a03801982511681845116808217855250505050505090500182805190602001908083835b6020831061244c5780518252602082019150602081019050602083039250612429565b6001836020036101000a0380198251168184511680821785525050505050509050019250505060405160208183030381529060405292505050612555565b8061249485612fc8565b6040516020018083805190602001908083835b602083106124ca57805182526020820191506020810190506020830392506124a7565b6001836020036101000a03801982511681845116808217855250505050505090500182805190602001908083835b6020831061251b57805182526020820191506020810190506020830392506124f8565b6001836020036101000a03801982511681845116808217855250505050505090500192505050604051602081830303815290604052925050505b919050565b600d5481565b600c5481565b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b6000600d5414612672576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601d8152602001807f5374617274696e6720696e64657820697320616c72656164792073657400000081525060200191505060405180910390fd5b6000600c5414156126eb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f5374617274696e6720696e64657820626c6f636b206d7573742062652073657481525060200191505060405180910390fd5b600e54600c544060001c816126fc57fe5b06600d8190555060ff61271a600c544361310f90919063ffffffff16565b111561273a57600e54600143034060001c8161273257fe5b06600d819055505b6000600d5414156127625761275b6001600d54612e2a90919063ffffffff16565b600d819055505b565b600f60009054906101000a900460ff1681565b61277f61296c565b73ffffffffffffffffffffffffffffffffffffffff1661279d611c4c565b73ffffffffffffffffffffffffffffffffffffffff1614612826576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614156128ac576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180613ed86026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff16600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a380600a60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600033905090565b600061298a82600261319290919063ffffffff16565b9050919050565b816004600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff16612a04836117f2565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000612a58826000016131ac565b9050919050565b6000612a6a82612974565b612abf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c815260200180613f48602c913960400191505060405180910390fd5b6000612aca836117f2565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161480612b3957508373ffffffffffffffffffffffffffffffffffffffff16612b21846110e8565b73ffffffffffffffffffffffffffffffffffffffff16145b80612b4a5750612b498185612566565b5b91505092915050565b8273ffffffffffffffffffffffffffffffffffffffff16612b73826117f2565b73ffffffffffffffffffffffffffffffffffffffff1614612bdf576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806140b76029913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415612c65576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526024815260200180613efe6024913960400191505060405180910390fd5b612c708383836131bd565b612c7b600082612991565b612ccc81600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206131c290919063ffffffff16565b50612d1e81600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206131dc90919063ffffffff16565b50612d35818360026131f69092919063ffffffff16565b50808273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4505050565b6000612da5836000018361322b565b60001c905092915050565b600080600080612dc386600001866132ae565b915091508160001c8160001c9350935050509250929050565b8060099080519060200190612df2929190613de6565b5050565b6000612e09846000018460001b84613347565b60001c90509392505050565b6000612e238260000161343d565b9050919050565b600080828401905083811015612ea8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600080831415612ec55760009050612f32565b6000828402905082848281612ed657fe5b0414612f2d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602181526020018061406a6021913960400191505060405180910390fd5b809150505b92915050565b612f5282826040518060200160405280600081525061344e565b5050565b612f61848484612b53565b612f6d848484846134bf565b612fc2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526032815260200180613ea66032913960400191505060405180910390fd5b50505050565b60606000821415613010576040518060400160405280600181526020017f3000000000000000000000000000000000000000000000000000000000000000815250905061310a565b600082905060005b6000821461303a578080600101915050600a828161303257fe5b049150613018565b60608167ffffffffffffffff8111801561305357600080fd5b506040519080825280601f01601f1916602001820160405280156130865781602001600182028036833780820191505090505b50905060006001830390508593505b6000841461310257600a84816130a757fe5b0660300160f81b828280600190039350815181106130c157fe5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600a84816130fa57fe5b049350613095565b819450505050505b919050565b600082821115613187576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601e8152602001807f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525060200191505060405180910390fd5b818303905092915050565b60006131a4836000018360001b6136d8565b905092915050565b600081600001805490509050919050565b505050565b60006131d4836000018360001b6136fb565b905092915050565b60006131ee836000018360001b6137e3565b905092915050565b6000613222846000018460001b8473ffffffffffffffffffffffffffffffffffffffff1660001b613853565b90509392505050565b60008183600001805490501161328c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180613e846022913960400191505060405180910390fd5b82600001828154811061329b57fe5b9060005260206000200154905092915050565b60008082846000018054905011613310576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806140206022913960400191505060405180910390fd5b600084600001848154811061332157fe5b906000526020600020906002020190508060000154816001015492509250509250929050565b6000808460010160008581526020019081526020016000205490506000811415839061340e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156133d35780820151818401526020810190506133b8565b50505050905090810190601f1680156134005780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5084600001600182038154811061342157fe5b9060005260206000209060020201600101549150509392505050565b600081600001805490509050919050565b613458838361392f565b61346560008484846134bf565b6134ba576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526032815260200180613ea66032913960400191505060405180910390fd5b505050565b60006134e08473ffffffffffffffffffffffffffffffffffffffff16613b23565b6134ed57600190506136d0565b606061365763150b7a0260e01b61350261296c565b888787604051602401808573ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff16815260200183815260200180602001828103825283818151815260200191508051906020019080838360005b8381101561358657808201518184015260208101905061356b565b50505050905090810190601f1680156135b35780820380516001836020036101000a031916815260200191505b5095505050505050604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050604051806060016040528060328152602001613ea6603291398773ffffffffffffffffffffffffffffffffffffffff16613b369092919063ffffffff16565b9050600081806020019051602081101561367057600080fd5b8101908080519060200190929190505050905063150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614925050505b949350505050565b600080836001016000848152602001908152602001600020541415905092915050565b600080836001016000848152602001908152602001600020549050600081146137d7576000600182039050600060018660000180549050039050600086600001828154811061374657fe5b906000526020600020015490508087600001848154811061376357fe5b906000526020600020018190555060018301876001016000838152602001908152602001600020819055508660000180548061379b57fe5b600190038181906000526020600020016000905590558660010160008781526020019081526020016000206000905560019450505050506137dd565b60009150505b92915050565b60006137ef8383613b4e565b61384857826000018290806001815401808255809150506001900390600052602060002001600090919091909150558260000180549050836001016000848152602001908152602001600020819055506001905061384d565b600090505b92915050565b60008084600101600085815260200190815260200160002054905060008114156138fa57846000016040518060400160405280868152602001858152509080600181540180825580915050600190039060005260206000209060020201600090919091909150600082015181600001556020820151816001015550508460000180549050856001016000868152602001908152602001600020819055506001915050613928565b8285600001600183038154811061390d57fe5b90600052602060002090600202016001018190555060009150505b9392505050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156139d2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4552433732313a206d696e7420746f20746865207a65726f206164647265737381525060200191505060405180910390fd5b6139db81612974565b15613a4e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601c8152602001807f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000081525060200191505060405180910390fd5b613a5a600083836131bd565b613aab81600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206131dc90919063ffffffff16565b50613ac2818360026131f69092919063ffffffff16565b50808273ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a45050565b600080823b905060008111915050919050565b6060613b458484600085613b71565b90509392505050565b600080836001016000848152602001908152602001600020541415905092915050565b606082471015613bcc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180613f226026913960400191505060405180910390fd5b613bd585613b23565b613c47576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601d8152602001807f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000081525060200191505060405180910390fd5b600060608673ffffffffffffffffffffffffffffffffffffffff1685876040518082805190602001908083835b60208310613c975780518252602082019150602081019050602083039250613c74565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d8060008114613cf9576040519150601f19603f3d011682016040523d82523d6000602084013e613cfe565b606091505b5091509150613d0e828286613d1a565b92505050949350505050565b60608315613d2a57829050613ddf565b600083511115613d3d5782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015613da4578082015181840152602081019050613d89565b50505050905090810190601f168015613dd15780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b9392505050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10613e2757805160ff1916838001178555613e55565b82800160010185558215613e55579182015b82811115613e54578251825591602001919060010190613e39565b5b509050613e629190613e66565b5090565b5b80821115613e7f576000816000905550600101613e67565b509056fe456e756d657261626c655365743a20696e646578206f7574206f6620626f756e64734552433732313a207472616e7366657220746f206e6f6e20455243373231526563656976657220696d706c656d656e7465724f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573734552433732313a207472616e7366657220746f20746865207a65726f2061646472657373416464726573733a20696e73756666696369656e742062616c616e636520666f722063616c6c4552433732313a206f70657261746f7220717565727920666f72206e6f6e6578697374656e7420746f6b656e43616e206f6e6c79206d696e7420323020746f6b656e7320617420612074696d654552433732313a20617070726f76652063616c6c6572206973206e6f74206f776e6572206e6f7220617070726f76656420666f7220616c6c4552433732313a2062616c616e636520717565727920666f7220746865207a65726f20616464726573734552433732313a206f776e657220717565727920666f72206e6f6e6578697374656e7420746f6b656e456e756d657261626c654d61703a20696e646578206f7574206f6620626f756e6473507572636861736520776f756c6420657863656564206d617820737570706c79206f662041706573536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f774552433732313a20617070726f76656420717565727920666f72206e6f6e6578697374656e7420746f6b656e4552433732313a207472616e73666572206f6620746f6b656e2074686174206973206e6f74206f776e4552433732314d657461646174613a2055524920717565727920666f72206e6f6e6578697374656e7420746f6b656e4552433732313a20617070726f76616c20746f2063757272656e74206f776e65724552433732313a207472616e736665722063616c6c6572206973206e6f74206f776e6572206e6f7220617070726f766564a2646970667358221220b0e64d1fa6c4dbeb9c6f54607d7e1996943fe27624a80652f57b53fda084621b64736f6c63430007000033000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000002710000000000000000000000000000000000000000000000000000000006080e6d70000000000000000000000000000000000000000000000000000000000000011426f7265644170655961636874436c756200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000044241594300000000000000000000000000000000000000000000000000000000', + wagmiMintExample: + '0x608060405260006007553480156200001657600080fd5b50604051806040016040528060058152602001647761676d6960d81b815250604051806040016040528060058152602001645741474d4960d81b81525081600090805190602001906200006b9291906200008a565b508051620000819060019060208401906200008a565b5050506200016c565b828054620000989062000130565b90600052602060002090601f016020900481019282620000bc576000855562000107565b82601f10620000d757805160ff191683800117855562000107565b8280016001018555821562000107579182015b8281111562000107578251825591602001919060010190620000ea565b506200011592915062000119565b5090565b5b808211156200011557600081556001016200011a565b600181811c908216806200014557607f821691505b6020821081036200016657634e487b7160e01b600052602260045260246000fd5b50919050565b6128c2806200017c6000396000f3fe608060405234801561001057600080fd5b50600436106101005760003560e01c80636352211e11610097578063a22cb46511610066578063a22cb46514610215578063b88d4fde14610228578063c87b56dd1461023b578063e985e9c51461024e57600080fd5b80636352211e146101d457806370a08231146101e757806395d89b41146101fa578063a0712d681461020257600080fd5b80631249c58b116100d35780631249c58b1461018f57806318160ddd1461019757806323b872dd146101ae57806342842e0e146101c157600080fd5b806301ffc9a71461010557806306fdde031461012d578063081812fc14610142578063095ea7b31461017a575b600080fd5b61011861011336600461178f565b610297565b60405190151581526020015b60405180910390f35b61013561037c565b6040516101249190611829565b61015561015036600461183c565b61040e565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610124565b61018d61018836600461187e565b6104d3565b005b61018d61062b565b6101a060065481565b604051908152602001610124565b61018d6101bc3660046118a8565b61067d565b61018d6101cf3660046118a8565b610704565b6101556101e236600461183c565b61071f565b6101a06101f53660046118e4565b6107b7565b61013561086b565b61018d61021036600461183c565b61087a565b61018d6102233660046118ff565b610902565b61018d61023636600461196a565b610911565b61013561024936600461183c565b61099f565b61011861025c366004611a64565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260056020908152604080832093909416825291909152205460ff1690565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f80ac58cd00000000000000000000000000000000000000000000000000000000148061032a57507fffffffff0000000000000000000000000000000000000000000000000000000082167f5b5e139f00000000000000000000000000000000000000000000000000000000145b8061037657507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b60606000805461038b90611a97565b80601f01602080910402602001604051908101604052809291908181526020018280546103b790611a97565b80156104045780601f106103d957610100808354040283529160200191610404565b820191906000526020600020905b8154815290600101906020018083116103e757829003601f168201915b5050505050905090565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff166104aa5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084015b60405180910390fd5b5060009081526004602052604090205473ffffffffffffffffffffffffffffffffffffffff1690565b60006104de8261071f565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16036105815760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f720000000000000000000000000000000000000000000000000000000000000060648201526084016104a1565b3373ffffffffffffffffffffffffffffffffffffffff821614806105aa57506105aa813361025c565b61061c5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c000000000000000060648201526084016104a1565b6106268383610b07565b505050565b6007545b60008181526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16156106615760010161062f565b61066b3382610ba7565b60068054600190810190915501600755565b6106873382610bc1565b6106f95760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f76656400000000000000000000000000000060648201526084016104a1565b610626838383610d17565b61062683838360405180602001604052806000815250610911565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff16806103765760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201527f656e7420746f6b656e000000000000000000000000000000000000000000000060648201526084016104a1565b600073ffffffffffffffffffffffffffffffffffffffff82166108425760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a6560448201527f726f20616464726573730000000000000000000000000000000000000000000060648201526084016104a1565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526003602052604090205490565b60606001805461038b90611a97565b60008181526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16156108ec5760405162461bcd60e51b815260206004820152601160248201527f546f6b656e2049442069732074616b656e00000000000000000000000000000060448201526064016104a1565b6108f63382610ba7565b50600680546001019055565b61090d338383610f4a565b5050565b61091b3383610bc1565b61098d5760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f76656400000000000000000000000000000060648201526084016104a1565b6109998484848461105d565b50505050565b6040517f666f726567726f756e64000000000000000000000000000000000000000000006020820152602a810182905260609060009061016890604a016040516020818303038152906040528051906020012060001c6109ff9190611b19565b6040517f6261636b67726f756e64000000000000000000000000000000000000000000006020820152602a810185905290915060009061016890604a016040516020818303038152906040528051906020012060001c610a5f9190611b19565b90506000610aba610a6f866110e6565b610aa9610a7b866110e6565b610a84866110e6565b604051602001610a95929190611b2d565b60405160208183030381529060405261121b565b604051602001610a959291906125ba565b9050600081604051602001610acf919061268b565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190529695505050505050565b600081815260046020526040902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84169081179091558190610b618261071f565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b61090d82826040518060200160405280600081525061136e565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff16610c585760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084016104a1565b6000610c638361071f565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161480610cd1575073ffffffffffffffffffffffffffffffffffffffff80821660009081526005602090815260408083209388168352929052205460ff165b80610d0f57508373ffffffffffffffffffffffffffffffffffffffff16610cf78461040e565b73ffffffffffffffffffffffffffffffffffffffff16145b949350505050565b8273ffffffffffffffffffffffffffffffffffffffff16610d378261071f565b73ffffffffffffffffffffffffffffffffffffffff1614610dc05760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201527f6f776e657200000000000000000000000000000000000000000000000000000060648201526084016104a1565b73ffffffffffffffffffffffffffffffffffffffff8216610e485760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f726573730000000000000000000000000000000000000000000000000000000060648201526084016104a1565b610e53600082610b07565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600360205260408120805460019290610e899084906126ff565b909155505073ffffffffffffffffffffffffffffffffffffffff82166000908152600360205260408120805460019290610ec4908490612716565b909155505060008181526002602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff86811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603610fc55760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c65720000000000000060448201526064016104a1565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526005602090815260408083209487168084529482529182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b611068848484610d17565b611074848484846113f7565b6109995760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e746572000000000000000000000000000060648201526084016104a1565b60608160000361112957505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b8115611153578061113d8161272e565b915061114c9050600a83612766565b915061112d565b60008167ffffffffffffffff81111561116e5761116e61193b565b6040519080825280601f01601f191660200182016040528015611198576020820181803683370190505b5090505b8415610d0f576111ad6001836126ff565b91506111ba600a86611b19565b6111c5906030612716565b60f81b8183815181106111da576111da61277a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611214600a86612766565b945061119c565b6060815160000361123a57505060408051602081019091526000815290565b600060405180606001604052806040815260200161284d60409139905060006003845160026112699190612716565b6112739190612766565b61127e9060046127a9565b67ffffffffffffffff8111156112965761129661193b565b6040519080825280601f01601f1916602001820160405280156112c0576020820181803683370190505b509050600182016020820185865187015b8082101561132c576003820191508151603f8160121c168501518453600184019350603f81600c1c168501518453600184019350603f8160061c168501518453600184019350603f81168501518453506001830192506112d1565b5050600386510660018114611348576002811461135b57611363565b603d6001830353603d6002830353611363565b603d60018303535b509195945050505050565b61137883836115d0565b61138560008484846113f7565b6106265760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e746572000000000000000000000000000060648201526084016104a1565b600073ffffffffffffffffffffffffffffffffffffffff84163b156115c5576040517f150b7a0200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85169063150b7a029061146e9033908990889088906004016127e6565b6020604051808303816000875af19250505080156114c7575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092526114c49181019061282f565b60015b61157a573d8080156114f5576040519150601f19603f3d011682016040523d82523d6000602084013e6114fa565b606091505b5080516000036115725760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e746572000000000000000000000000000060648201526084016104a1565b805181602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000167f150b7a0200000000000000000000000000000000000000000000000000000000149050610d0f565b506001949350505050565b73ffffffffffffffffffffffffffffffffffffffff82166116335760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016104a1565b60008181526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16156116a55760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060448201526064016104a1565b73ffffffffffffffffffffffffffffffffffffffff821660009081526003602052604081208054600192906116db908490612716565b909155505060008181526002602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b7fffffffff000000000000000000000000000000000000000000000000000000008116811461178c57600080fd5b50565b6000602082840312156117a157600080fd5b81356117ac8161175e565b9392505050565b60005b838110156117ce5781810151838201526020016117b6565b838111156109995750506000910152565b600081518084526117f78160208601602086016117b3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006117ac60208301846117df565b60006020828403121561184e57600080fd5b5035919050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461187957600080fd5b919050565b6000806040838503121561189157600080fd5b61189a83611855565b946020939093013593505050565b6000806000606084860312156118bd57600080fd5b6118c684611855565b92506118d460208501611855565b9150604084013590509250925092565b6000602082840312156118f657600080fd5b6117ac82611855565b6000806040838503121561191257600080fd5b61191b83611855565b91506020830135801515811461193057600080fd5b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000806000806080858703121561198057600080fd5b61198985611855565b935061199760208601611855565b925060408501359150606085013567ffffffffffffffff808211156119bb57600080fd5b818701915087601f8301126119cf57600080fd5b8135818111156119e1576119e161193b565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715611a2757611a2761193b565b816040528281528a6020848701011115611a4057600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215611a7757600080fd5b611a8083611855565b9150611a8e60208401611855565b90509250929050565b600181811c90821680611aab57607f821691505b602082108103611ae4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082611b2857611b28611aea565b500690565b7f3c73766720786d6c6e733d22687474703a2f2f7777772e77332e6f72672f323081527f30302f737667222077696474683d223130323422206865696768743d2231303260208201527f34222066696c6c3d226e6f6e65223e3c706174682066696c6c3d2268736c2800604082015260008351611bb181605f8501602088016117b3565b7f2c20313030252c20313025292220643d224d3020306831303234763130323448605f918401918201527f307a22202f3e3c672066696c6c3d2268736c2800000000000000000000000000607f8201528351611c148160928401602088016117b3565b7f2c20313030252c2039302529223e3c7061746820643d224d393033203433372e609292909101918201527f35633020392e3131332d372e3338382031362e352d31362e352031362e35732d60b28201527f31362e352d372e3338372d31362e352d31362e3520372e3338382d31362e352060d28201527f31362e352d31362e352031362e3520372e3338372031362e352031362e357a4d60f28201527f3639382e3532392035363663362e39323120302031322e35332d352e353936206101128201527f31322e35332d31322e35762d353063302d362e39303420352e3630392d31322e6101328201527f352031322e3532392d31322e356832352e30353963362e393220302031322e356101528201527f323920352e3539362031322e3532392031322e35763530633020362e393034206101728201527f352e3630392031322e352031322e35332031322e357331322e3532392d352e356101928201527f39362031322e3532392d31322e35762d353063302d362e39303420352e3630396101b28201527f2d31322e352031322e35332d31322e356832352e30353963362e3932203020316101d28201527f322e35323920352e3539362031322e3532392031322e35763530633020362e396101f28201527f303420352e3630392031322e352031322e3532392031322e356833372e3538396102128201527f63362e393220302031322e3532392d352e3539362031322e3532392d31322e356102328201527f762d373563302d362e3930342d352e3630392d31322e352d31322e3532392d316102528201527f322e35732d31322e353320352e3539362d31322e35332031322e357635362e326102728201527f3561362e32363420362e3236342030203120312d31322e3532392030563437386102928201527f2e3563302d362e3930342d352e3630392d31322e352d31322e35332d31322e356102b28201527f483639382e353239632d362e393220302d31322e35323920352e3539362d31326102d28201527f2e3532392031322e35763735633020362e39303420352e3630392031322e35206102f28201527f31322e3532392031322e357a22202f3e3c7061746820643d224d3135372e36356103128201527f3520353431632d362e39333220302d31322e3535322d352e3539362d31322e356103328201527f35322d31322e35762d353063302d362e3930342d352e3631392d31322e352d316103528201527f322e3535312d31322e3553313230203437312e35393620313230203437382e356103728201527f763735633020362e39303420352e36322031322e352031322e3535322031322e6103928201527f35683135302e363263362e39333320302031322e3535322d352e3539362031326103b28201527f2e3535322d31322e35762d353063302d362e39303420352e3631392d31322e356103d28201527f2031322e3535322d31322e35683134342e33343563332e343635203020362e326103f28201527f373620322e37393820362e32373620362e3235732d322e38313120362e32352d6104128201527f362e32373620362e3235483332302e383238632d362e39333320302d31322e356104328201527f353220352e3539362d31322e3535322031322e357633372e35633020362e39306104528201527f3420352e3631392031322e352031322e3535322031322e35683135302e3632636104728201527f362e39333320302031322e3535322d352e3539362031322e3535322d31322e356104928201527f762d373563302d362e3930342d352e3631392d31322e352d31322e3535322d316104b28201527f322e35483238332e313732632d362e39333220302d31322e35353120352e35396104d28201527f362d31322e3535312031322e35763530633020362e3930342d352e36313920316104f28201527f322e352d31322e3535322031322e35682d32352e313033632d362e39333320306105128201527f2d31322e3535322d352e3539362d31322e3535322d31322e35762d353063302d6105328201527f362e3930342d352e36322d31322e352d31322e3535322d31322e35732d31322e6105528201527f35353220352e3539362d31322e3535322031322e35763530633020362e3930346105728201527f2d352e3631392031322e352d31322e3535312031322e35682d32352e3130347a6105928201527f6d3330312e3234322d362e3235633020332e3435322d322e38313120362e32356105b28201527f2d362e32373620362e3235483333392e363535632d332e34363520302d362e326105d28201527f37362d322e3739382d362e3237362d362e323573322e3831312d362e323520366105f28201527f2e3237362d362e3235683131322e39363663332e343635203020362e323736206106128201527f322e37393820362e32373620362e32357a4d343937203535332e3831386330206106328201527f362e39323920352e3632382031322e3534362031322e3537312031322e3534366106528201527f6831333261362e323820362e323820302030203120362e32383620362e3237326106728201527f20362e323820362e32382030203020312d362e32383620362e323733682d31336106928201527f32632d362e39343320302d31322e35373120352e3631362d31322e35373120316106b28201527f322e3534364131322e35362031322e3536203020302030203530392e353731206106d28201527f363034683135302e38353863362e39343320302031322e3537312d352e3631366106f28201527f2031322e3537312d31322e353435762d3131322e393163302d362e3932382d356107128201527f2e3632382d31322e3534352d31322e3537312d31322e353435483530392e35376107328201527f31632d362e39343320302d31322e35373120352e3631372d31322e35373120316107528201527f322e3534357637352e3237337a6d33372e3731342d36322e373237632d362e396107728201527f343320302d31322e35373120352e3631372d31322e3537312031322e353435766107928201527f32352e303931633020362e39323920352e3632382031322e3534362031322e356107b28201527f37312031322e353436683130302e35373263362e39343320302031322e3537316107d28201527f2d352e3631372031322e3537312d31322e353436762d32352e30393163302d366107f28201527f2e3932382d352e3632382d31322e3534352d31322e3537312d31322e353435486108128201527f3533342e3731347a222066696c6c2d72756c653d226576656e6f646422202f3e6108328201527f3c2f673e3c2f7376673e0000000000000000000000000000000000000000000061085282015261085c01949350505050565b7f7b226e616d65223a20227761676d6920230000000000000000000000000000008152600083516125f28160118501602088016117b3565b7f222c2022696d616765223a2022646174613a696d6167652f7376672b786d6c3b6011918401918201527f6261736536342c00000000000000000000000000000000000000000000000000603182015283516126558160388401602088016117b3565b7f227d00000000000000000000000000000000000000000000000000000000000060389290910191820152603a01949350505050565b7f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c0000008152600082516126c381601d8501602087016117b3565b91909101601d0192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082821015612711576127116126d0565b500390565b60008219821115612729576127296126d0565b500190565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361275f5761275f6126d0565b5060010190565b60008261277557612775611aea565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156127e1576127e16126d0565b500290565b600073ffffffffffffffffffffffffffffffffffffffff80871683528086166020840152508360408301526080606083015261282560808301846117df565b9695505050505050565b60006020828403121561284157600080fd5b81516117ac8161175e56fe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa26469706673582212201665a4f9111990d7529375848d3fd02c0121091a940da59e763eba826e7b077064736f6c634300080d0033', +} as const diff --git a/packages/test/src/exports/index.test-d.ts b/packages/test/src/exports/index.test-d.ts new file mode 100644 index 0000000000..b056d56358 --- /dev/null +++ b/packages/test/src/exports/index.test-d.ts @@ -0,0 +1,4 @@ +import { expectTypeOf } from 'vitest' + +// noop test because vitest typecheck fails unless each workspace project has type test +expectTypeOf(1).toEqualTypeOf() diff --git a/packages/test/src/exports/index.test.ts b/packages/test/src/exports/index.test.ts new file mode 100644 index 0000000000..2a44ddbf8f --- /dev/null +++ b/packages/test/src/exports/index.test.ts @@ -0,0 +1,29 @@ +import { expect, test } from 'vitest' + +import * as react from './index.js' + +test('exports', () => { + expect(Object.keys(react)).toMatchInlineSnapshot(` + [ + "chain", + "mainnet", + "mainnet2", + "optimism", + "abi", + "accounts", + "address", + "bytecode", + "privateKey", + "typedData", + "walletConnectProjectId", + "testClient", + "mainnetTestClient", + "mainnet2TestClient", + "optimismTestClient", + "config", + "addressRegex", + "transactionHashRegex", + "wait", + ] + `) +}) diff --git a/packages/test/src/exports/index.ts b/packages/test/src/exports/index.ts new file mode 100644 index 0000000000..5844aeac01 --- /dev/null +++ b/packages/test/src/exports/index.ts @@ -0,0 +1,25 @@ +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { chain, mainnet, mainnet2, optimism } from '../chains.js' + +export { + abi, + accounts, + address, + bytecode, + privateKey, + typedData, + walletConnectProjectId, +} from '../constants.js' + +export { + testClient, + mainnetTestClient, + mainnet2TestClient, + optimismTestClient, +} from '../clients.js' + +export { config } from '../config.js' + +export { addressRegex, transactionHashRegex } from '../regex.js' + +export { wait } from '../utils.js' diff --git a/packages/test/src/exports/react.ts b/packages/test/src/exports/react.ts new file mode 100644 index 0000000000..f9dfe5c4b4 --- /dev/null +++ b/packages/test/src/exports/react.ts @@ -0,0 +1,63 @@ +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import { + type RenderHookOptions, + type RenderHookResult, + type RenderOptions, + type RenderResult, + render as rtl_render, + renderHook as rtl_renderHook, + waitFor as rtl_waitFor, + type waitForOptions, +} from '@testing-library/react' +import { type ReactElement, createElement } from 'react' +import { WagmiProvider } from 'wagmi' + +import { config } from '../config.js' + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { act, cleanup } from '@testing-library/react' + +export const queryClient = new QueryClient() + +export function createWrapper>( + Wrapper: TComponent, + props: Parameters[0], +) { + type Props = { children?: React.ReactNode | undefined } + return function CreatedWrapper({ children }: Props) { + return createElement( + Wrapper, + props, + createElement(QueryClientProvider, { client: queryClient }, children), + ) + } +} + +export function renderHook( + render: (props: Props) => Result, + options?: RenderHookOptions | undefined, +): RenderHookResult { + queryClient.clear() + return rtl_renderHook(render, { + wrapper: createWrapper(WagmiProvider, { config, reconnectOnMount: false }), + ...options, + }) +} + +export function render( + element: ReactElement, + options?: RenderOptions | undefined, +): RenderResult { + queryClient.clear() + return rtl_render(element, { + wrapper: createWrapper(WagmiProvider, { config, reconnectOnMount: false }), + ...options, + }) +} + +export function waitFor( + callback: () => Promise | T, + options?: waitForOptions | undefined, +): Promise { + return rtl_waitFor(callback, { timeout: 10_000, ...options }) +} diff --git a/packages/test/src/exports/vue.ts b/packages/test/src/exports/vue.ts new file mode 100644 index 0000000000..ac49b17a31 --- /dev/null +++ b/packages/test/src/exports/vue.ts @@ -0,0 +1,66 @@ +import { VueQueryPlugin } from '@tanstack/vue-query' +import { WagmiPlugin } from '@wagmi/vue' +import { type App, type Ref, createApp, watch } from 'vue' + +import { config } from '../config.js' + +export type RenderComposableReturnType unknown> = [ + ReturnType, + App, +] + +export function renderComposable unknown>( + composable: composable, + options: { attach?: (app: App) => void } | undefined = { + attach(app) { + app + .use(WagmiPlugin, { + config, + reconnectOnMount: false, + }) + .use(VueQueryPlugin, {}) + }, + }, +): RenderComposableReturnType { + let result = undefined + const app = createApp({ + setup() { + result = composable() + return () => {} + }, + }) + + options.attach?.(app) + app.mount(document.createElement('div')) + + return [result, app] as unknown as RenderComposableReturnType +} + +export type WaitForOptions = { + timeout?: number +} + +export function waitFor( + ref: ref, + predicate: (value: ref['value']) => boolean = (value) => value, + options: WaitForOptions = {}, +) { + const { timeout = 10_000 } = options + return new Promise((resolve, reject) => { + const timer = timeout + ? setTimeout(() => { + _unwatch() + if (predicate(ref.value)) resolve() + else reject(new Error(`\`waitFor\` timed out in ${timeout}ms.`)) + }, timeout) + : undefined + + const _unwatch = watch(ref, (value) => { + if (predicate(value)) { + if (timer) clearTimeout(timer) + _unwatch() + resolve() + } + }) + }) +} diff --git a/packages/test/src/globalSetup.ts b/packages/test/src/globalSetup.ts new file mode 100644 index 0000000000..f8248e8390 --- /dev/null +++ b/packages/test/src/globalSetup.ts @@ -0,0 +1,26 @@ +import { createServer } from 'prool' +import { anvil } from 'prool/instances' + +import { chain as chainLookup } from './chains.js' + +export default async function () { + const promises = [] + for (const chain of Object.values(chainLookup)) { + promises.push( + createServer({ + instance: anvil({ + chainId: chain.id, + forkUrl: chain.fork.url, + forkBlockNumber: chain.fork.blockNumber, + noMining: true, + }), + port: chain.port, + }).start(), + ) + } + const results = await Promise.all(promises) + + return async () => { + await Promise.all(results.map((stop) => stop())) + } +} diff --git a/packages/test/src/regex.ts b/packages/test/src/regex.ts new file mode 100644 index 0000000000..5998ea513e --- /dev/null +++ b/packages/test/src/regex.ts @@ -0,0 +1,3 @@ +export const addressRegex = /^0x([A-Fa-f0-9]{40})$/ + +export const transactionHashRegex = /^0x([A-Fa-f0-9]{64})$/ diff --git a/packages/test/src/setup.ts b/packages/test/src/setup.ts new file mode 100644 index 0000000000..1a41b7a6ed --- /dev/null +++ b/packages/test/src/setup.ts @@ -0,0 +1,8 @@ +import { afterAll } from 'vitest' + +import { testClient } from './clients.js' + +afterAll(async () => { + // If you are using a fork, you can reset your anvil instance to the initial fork block. + await Promise.all(Object.values(testClient).map((client) => client.restart())) +}) diff --git a/packages/test/src/utils.ts b/packages/test/src/utils.ts new file mode 100644 index 0000000000..85afe15c4b --- /dev/null +++ b/packages/test/src/utils.ts @@ -0,0 +1,25 @@ +const pool = + Number(process.env.VITEST_POOL_ID ?? 1) + Math.floor(Math.random() * 10000) + +export function getRpcUrls({ port }: { port: number }) { + return { + port, + rpcUrls: { + // These rpc urls are automatically used in the transports. + default: { + // Note how we append the worker id to the local rpc urls. + http: [`http://127.0.0.1:${port}/${pool}`], + webSocket: [`ws://127.0.0.1:${port}/${pool}`], + }, + public: { + // Note how we append the worker id to the local rpc urls. + http: [`http://127.0.0.1:${port}/${pool}`], + webSocket: [`ws://127.0.0.1:${port}/${pool}`], + }, + }, + } as const +} + +export async function wait(time: number) { + return new Promise((res) => setTimeout(res, time)) +} diff --git a/packages/test/tsconfig.build.json b/packages/test/tsconfig.build.json new file mode 100644 index 0000000000..fbed2b1036 --- /dev/null +++ b/packages/test/tsconfig.build.json @@ -0,0 +1,8 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["src/**/*.ts"], + "exclude": ["src/**/*.test.ts", "src/**/*.test-d.ts"], + "compilerOptions": { + "sourceMap": true + } +} diff --git a/packages/test/tsconfig.json b/packages/test/tsconfig.json new file mode 100644 index 0000000000..bd33919ac3 --- /dev/null +++ b/packages/test/tsconfig.json @@ -0,0 +1,5 @@ +{ + "extends": "./tsconfig.build.json", + "include": ["src/**/*.ts"], + "exclude": [] +} diff --git a/packages/utils/abi/CHANGELOG.md b/packages/utils/abi/CHANGELOG.md index 8194c38b89..5f57bf1ff0 100644 --- a/packages/utils/abi/CHANGELOG.md +++ b/packages/utils/abi/CHANGELOG.md @@ -1,559 +1,10 @@ # @0xsequence/abi -## 3.0.5 - -### Patch Changes - -- Account federation support - -## 3.0.4 - -### Patch Changes - -- id-token login support - -## 3.0.3 - -### Patch Changes - -- 3.0.3 - -## 3.0.2 - -### Patch Changes - -- allow native self transfer - -## 3.0.1 - -### Patch Changes - -- Network and session fixes - -## 3.0.0 - -### Patch Changes - -- f68be62: ethauth support -- 49d8a2f: New chains, minor fixes -- 3411232: Beta release with dapp connector fixes -- 23cb9e9: New chains, relayer rpc fix -- f5f6a7a: dapp-client updates -- e7de3b1: Fix signer 404 error, minor fixes -- 493836f: multicall3 optimization -- 30e1f1a: 3.0.0 beta -- d5017e8: Beta release for v3 -- 24a5fab: Final RC before 3.0.0 -- e5e1a03: Apple auth fixes -- 0b63113: Apple auth fix -- a89134a: Userdata service updates -- 7c6c811: 3.0.0-beta.3 with fixes -- 3.0.0 release -- 98ce38b: 3.0.0-beta.2 with identity instrument updates -- 747e6b5: Relayer fee options fix -- 40c19ff: dapp client updates for EOA login -- 6d5de25: 3.0.0-beta.1 -- 934acd1: RC5 upgrade - -## 3.0.0-beta.19 - -### Patch Changes - -- Final RC before 3.0.0 - -## 3.0.0-beta.18 - -### Patch Changes - -- multicall3 optimization - -## 3.0.0-beta.17 - -### Patch Changes - -- New chains, relayer rpc fix - -## 3.0.0-beta.16 - -### Patch Changes - -- ethauth support - -## 3.0.0-beta.15 - -### Patch Changes - -- New chains, minor fixes - -## 3.0.0-beta.14 - -### Patch Changes - -- Relayer fee options fix - -## 3.0.0-beta.13 - -### Patch Changes - -- Userdata service updates - -## 3.0.0-beta.12 - -### Patch Changes - -- Beta release with dapp connector fixes - -## 3.0.0-beta.11 - -### Patch Changes - -- 3.0.0 beta - -## 3.0.0-beta.10 - -### Patch Changes - -- dapp-client updates - -## 3.0.0-beta.9 - -### Patch Changes - -- dapp client updates for EOA login - -## 3.0.0-beta.8 - -### Patch Changes - -- Apple auth fixes - -## 3.0.0-beta.7 - -### Patch Changes - -- Apple auth fix - -## 3.0.0-beta.6 - -### Patch Changes - -- Fix signer 404 error, minor fixes - -## 3.0.0-beta.5 - -### Patch Changes - -- Beta release for v3 - -## 3.0.0-beta.4 - -### Patch Changes - -- RC5 upgrade - -## 3.0.0-beta.3 - -### Patch Changes - -- 3.0.0-beta.3 with fixes - -## 3.0.0-beta.2 - -### Patch Changes - -- 3.0.0-beta.2 with identity instrument updates - -## 3.0.0-beta.1 - -### Patch Changes - -- 3.0.0-beta.1 - -## 2.3.8 - -### Patch Changes - -- indexer: update clients - -## 2.3.7 - -### Patch Changes - -- Metadata updates - -## 2.3.6 - -### Patch Changes - -- New chains - -## 2.3.5 - -### Patch Changes - -- Add Frequency Testnet - -## 2.3.4 - -### Patch Changes - -- metadata: exclude deprecated methods on rpc client - -## 2.3.3 - -### Patch Changes - -- metadata: client update - -## 2.3.2 - -### Patch Changes - -- metadata: update rpc client - -## 2.3.1 - -### Patch Changes - -- indexer: update rpc client - -## 2.3.0 - -### Minor Changes - -- update metadata rpc client - -## 2.2.15 - -### Patch Changes - -- API updates - -## 2.2.14 - -### Patch Changes - -- Somnia Testnet and Monad Testnet - -## 2.2.13 - -### Patch Changes - -- Add XR1 to all networks - -## 2.2.12 - -### Patch Changes - -- Add XR1 - -## 2.2.11 - -### Patch Changes - -- Relayer updates - -## 2.2.10 - -### Patch Changes - -- Etherlink support - -## 2.2.9 - -### Patch Changes - -- Indexer gateway native token balances - -## 2.2.8 - -### Patch Changes - -- Add Moonbeam and Moonbase Alpha - -## 2.2.7 - -### Patch Changes - -- Update Builder package - -## 2.2.6 - -### Patch Changes - -- Update relayer package - -## 2.2.5 - -### Patch Changes - -- auth: fix sequence indexer gateway url -- account: immutable wallet proxy hook - -## 2.2.4 - -### Patch Changes - -- network: update soneium mainnet block explorer url -- waas: signTypedData intent support - -## 2.2.3 - -### Patch Changes - -- provider: updating initWallet to use connected network configs if they exist - -## 2.2.2 - -### Patch Changes - -- pass projectAccessKey to relayer at all times - -## 2.2.1 - -### Patch Changes - -- waas-ethers: sign typed data - -## 2.2.0 - -### Minor Changes - -- indexer: gateway client -- @0xsequence/builder -- upgrade puppeteer to v23.10.3 - -## 2.1.8 - -### Patch Changes - -- Add Soneium Mainnet - -## 2.1.7 - -### Patch Changes - -- guard: pass project access key to guard requests - -## 2.1.6 - -### Patch Changes - -- Add LAOS and Telos Testnet chains - -## 2.1.5 - -### Patch Changes - -- account: save presigned configuration with reference chain id 1 - -## 2.1.4 - -### Patch Changes - -- provider: pass projectAccessKey into MuxMessageProvider - -## 2.1.3 - -### Patch Changes - -- waas: time drift date fix due to strange browser quirk - -## 2.1.2 - -### Patch Changes - -- provider: export analytics correctly - -## 2.1.1 - -### Patch Changes - -- Add LAOS chain support - -## 2.1.0 - -### Minor Changes - -- account: forward project access key when estimating fees and sending transactions - -### Patch Changes - -- sessions: save signatures with reference chain id - -## 2.0.26 - -### Patch Changes - -- account: fix chain id comparison - -## 2.0.25 - -### Patch Changes - -- skale-nebula: deploy gas limit = 10m - -## 2.0.24 - -### Patch Changes - -- sessions: arweave: configurable gateway url -- waas: use /status to get time drift before sending any intents - -## 2.0.23 - -### Patch Changes - -- Add The Root Network support - -## 2.0.22 - -### Patch Changes - -- Add SKALE Nebula Mainnet support - -## 2.0.21 - -### Patch Changes - -- account: add publishWitnessFor - -## 2.0.20 - -### Patch Changes - -- upgrade deps, and improve waas session status handling - -## 2.0.19 - -### Patch Changes - -- Add Immutable zkEVM support - -## 2.0.18 - -### Patch Changes - -- waas: new contractCall transaction type -- sessions: add arweave owner - -## 2.0.17 - -### Patch Changes - -- update waas auth to clear session before signIn - -## 2.0.16 - -### Patch Changes - -- Removed Astar chains - -## 2.0.15 - -### Patch Changes - -- indexer: update bindings with token balance additions - -## 2.0.14 - -### Patch Changes - -- sessions: arweave config reader -- network: add b3 and apechain mainnet configs - -## 2.0.13 - -### Patch Changes - -- network: toy-testnet - -## 2.0.12 - -### Patch Changes - -- api: update bindings - -## 2.0.11 - -### Patch Changes - -- waas: intents test fix -- api: update bindings - -## 2.0.10 - -### Patch Changes - -- network: soneium minato testnet - -## 2.0.9 - -### Patch Changes - -- network: fix SKALE network name - -## 2.0.8 - -### Patch Changes - -- metadata: update bindings - -## 2.0.7 - -### Patch Changes - -- wallet request handler fix - -## 2.0.6 - -### Patch Changes - -- network: matic -> pol - -## 2.0.5 - -### Patch Changes - -- provider: update databeat to 0.9.2 - -## 2.0.4 - -### Patch Changes - -- network: add skale-nebula-testnet - -## 2.0.3 - -### Patch Changes - -- waas: check session status in SequenceWaaS.isSignedIn() - -## 2.0.2 - -### Patch Changes - -- sessions: property convert serialized bignumber hex value to bigint - -## 2.0.1 - -### Patch Changes - -- waas: http signature check for authenticator requests -- provider: unwrap legacy json rpc responses -- use json replacer and reviver for bigints - ## 2.0.0 ### Major Changes -- ethers v6 - -## 1.10.15 - -### Patch Changes - -- utils: extractProjectIdFromAccessKey +- changeset ## 1.10.14 @@ -1591,6 +1042,7 @@ - relayer: fix Relayer.wait() interface The interface for calling Relayer.wait() has changed. Instead of a single optional ill-defined timeout/delay parameter, there are three optional parameters, in order: + - timeout: the maximum time to wait for the transaction receipt - delay: the polling interval, i.e. the time to wait between requests - maxFails: the maximum number of hard failures to tolerate before giving up @@ -1929,6 +1381,7 @@ ### Minor Changes - major architectural changes in Sequence design + - only one API instance, API is no longer a per-chain service - separate per-chain indexer service, API no longer handles indexing - single contract metadata service, API no longer serves metadata diff --git a/packages/utils/abi/package.json b/packages/utils/abi/package.json index d70d75cdc6..738e1398cf 100644 --- a/packages/utils/abi/package.json +++ b/packages/utils/abi/package.json @@ -1,31 +1,28 @@ { "name": "@0xsequence/abi", - "version": "3.0.5", + "version": "3.0.0", "description": "abi sub-package for Sequence", - "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/utils/abi", - "author": "Sequence Platforms ULC", + "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/abi", + "author": "Sequence Platforms Inc.", "license": "Apache-2.0", "publishConfig": { "access": "public" }, - "type": "module", "scripts": { "build": "tsc", "dev": "tsc --watch", "test": "echo", - "typecheck": "tsc --noEmit", - "lint": "eslint . --max-warnings 0" + "typecheck": "tsc --noEmit" }, "exports": { ".": { - "types": "./dist/index.d.ts", + "types": "./src/index.ts", "default": "./dist/index.js" } }, "devDependencies": { - "@repo/eslint-config": "workspace:^", "@repo/typescript-config": "workspace:^", - "@types/node": "^25.3.0", - "typescript": "^5.9.3" + "@types/node": "^22.15.29", + "typescript": "^5.8.3" } } diff --git a/packages/vue/CHANGELOG.md b/packages/vue/CHANGELOG.md new file mode 100644 index 0000000000..324b962b29 --- /dev/null +++ b/packages/vue/CHANGELOG.md @@ -0,0 +1,706 @@ +# @wagmi/vue + +## 0.1.20 + +### Patch Changes + +- Updated dependencies [[`42b1fed58e9ac09da0f8ebf3e9271f98a707aaac`](https://github.com/wevm/wagmi/commit/42b1fed58e9ac09da0f8ebf3e9271f98a707aaac)]: + - @wagmi/connectors@5.8.3 + +## 0.1.19 + +### Patch Changes + +- Updated dependencies [[`29297a48af72b537173d948ccd2fe37d39914c66`](https://github.com/wevm/wagmi/commit/29297a48af72b537173d948ccd2fe37d39914c66), [`07370106d5fb6b8fe300992d93abf25b3d0eaf57`](https://github.com/wevm/wagmi/commit/07370106d5fb6b8fe300992d93abf25b3d0eaf57)]: + - @wagmi/core@2.17.2 + - @wagmi/connectors@5.8.2 + +## 0.1.18 + +### Patch Changes + +- Updated dependencies [[`01f64e64fa4f85cdd30023903f972f4f9023681f`](https://github.com/wevm/wagmi/commit/01f64e64fa4f85cdd30023903f972f4f9023681f)]: + - @wagmi/core@2.17.1 + - @wagmi/connectors@5.8.1 + +## 0.1.17 + +### Patch Changes + +- Updated dependencies [[`cc5517ff6880bb630f1b201930acc20dd1a0b451`](https://github.com/wevm/wagmi/commit/cc5517ff6880bb630f1b201930acc20dd1a0b451)]: + - @wagmi/connectors@5.8.0 + +## 0.1.16 + +### Patch Changes + +- Updated dependencies [[`88427b2bcd13ec375ef519e9ad1ccffef9f02a7b`](https://github.com/wevm/wagmi/commit/88427b2bcd13ec375ef519e9ad1ccffef9f02a7b), [`799ee4d4b23c2ecd64e3f3668e67634e81939719`](https://github.com/wevm/wagmi/commit/799ee4d4b23c2ecd64e3f3668e67634e81939719), [`3f8b2edc4f237cccff1009bcef03d51ca27a7324`](https://github.com/wevm/wagmi/commit/3f8b2edc4f237cccff1009bcef03d51ca27a7324)]: + - @wagmi/connectors@6.0.0 + - @wagmi/core@2.17.0 + +## 0.1.15 + +### Patch Changes + +- Updated dependencies [[`b59c024b23c69f5459b17390531207cfdf126ce4`](https://github.com/wevm/wagmi/commit/b59c024b23c69f5459b17390531207cfdf126ce4)]: + - @wagmi/connectors@5.7.12 + +## 0.1.14 + +### Patch Changes + +- Updated dependencies [[`a4bd0623eed28e3761a27295831a60ad835f0ee0`](https://github.com/wevm/wagmi/commit/a4bd0623eed28e3761a27295831a60ad835f0ee0)]: + - @wagmi/core@2.16.7 + - @wagmi/connectors@5.7.11 + +## 0.1.13 + +### Patch Changes + +- Updated dependencies [[`edf47477b2f6385a1c3ae01d36a8498c47f30a0b`](https://github.com/wevm/wagmi/commit/edf47477b2f6385a1c3ae01d36a8498c47f30a0b), [`e944812ebc234a72c1417b77cff341166f5e0fef`](https://github.com/wevm/wagmi/commit/e944812ebc234a72c1417b77cff341166f5e0fef)]: + - @wagmi/core@2.16.6 + - @wagmi/connectors@5.7.10 + +## 0.1.12 + +### Patch Changes + +- Updated dependencies [[`5b7101fddb61df56e34b2e02b46bc409e496eaf9`](https://github.com/wevm/wagmi/commit/5b7101fddb61df56e34b2e02b46bc409e496eaf9)]: + - @wagmi/connectors@5.7.9 + +## 0.1.11 + +### Patch Changes + +- Updated dependencies [[`d0c9a86921a4e939373cc6e763284e53f2a2e93c`](https://github.com/wevm/wagmi/commit/d0c9a86921a4e939373cc6e763284e53f2a2e93c)]: + - @wagmi/core@2.16.5 + - @wagmi/connectors@5.7.8 + +## 0.1.10 + +### Patch Changes + +- [`507f864d91238bfd423d0e36d3619eb9f6e52eec`](https://github.com/wevm/wagmi/commit/507f864d91238bfd423d0e36d3619eb9f6e52eec) Thanks [@jxom](https://github.com/jxom)! - Updated `@coinbase/wallet-sdk`. + +- Updated dependencies [[`507f864d91238bfd423d0e36d3619eb9f6e52eec`](https://github.com/wevm/wagmi/commit/507f864d91238bfd423d0e36d3619eb9f6e52eec)]: + - @wagmi/connectors@5.7.7 + - @wagmi/core@2.16.4 + +## 0.1.9 + +### Patch Changes + +- Updated dependencies [[`639952c97f0fe3927106f42d3c9f7f366cdf7f7a`](https://github.com/wevm/wagmi/commit/639952c97f0fe3927106f42d3c9f7f366cdf7f7a), [`5aa2c095f7bfb6dfcf91c6945c3e1f9c9dd05766`](https://github.com/wevm/wagmi/commit/5aa2c095f7bfb6dfcf91c6945c3e1f9c9dd05766)]: + - @wagmi/connectors@5.7.6 + +## 0.1.8 + +### Patch Changes + +- Updated dependencies [[`a257e8d4f97431a4af872cda1817b4ae17c7bbed`](https://github.com/wevm/wagmi/commit/a257e8d4f97431a4af872cda1817b4ae17c7bbed)]: + - @wagmi/connectors@5.7.5 + +## 0.1.7 + +### Patch Changes + +- Updated dependencies [[`c8a257e0f6d2ece013b873895c35769a8a804fdc`](https://github.com/wevm/wagmi/commit/c8a257e0f6d2ece013b873895c35769a8a804fdc)]: + - @wagmi/connectors@5.7.4 + +## 0.1.6 + +### Patch Changes + +- [#4480](https://github.com/wevm/wagmi/pull/4480) [`384a1d91597622eb59e1c05dc13ce25017c5b6d8`](https://github.com/wevm/wagmi/commit/384a1d91597622eb59e1c05dc13ce25017c5b6d8) Thanks [@RodeRickIsWatching](https://github.com/RodeRickIsWatching)! - Fixed invocation of default storage. + +- Updated dependencies [[`384a1d91597622eb59e1c05dc13ce25017c5b6d8`](https://github.com/wevm/wagmi/commit/384a1d91597622eb59e1c05dc13ce25017c5b6d8)]: + - @wagmi/core@2.16.3 + - @wagmi/connectors@5.7.3 + +## 0.1.5 + +### Patch Changes + +- [`012907032b532a438fce48f407470250cbc8f0c6`](https://github.com/wevm/wagmi/commit/012907032b532a438fce48f407470250cbc8f0c6) Thanks [@jxom](https://github.com/jxom)! - Fixed assignment in `getDefaultStorage`. + +- Updated dependencies [[`012907032b532a438fce48f407470250cbc8f0c6`](https://github.com/wevm/wagmi/commit/012907032b532a438fce48f407470250cbc8f0c6)]: + - @wagmi/core@2.16.2 + - @wagmi/connectors@5.7.2 + +## 0.1.4 + +### Patch Changes + +- Updated dependencies [[`9c8c35a3b829f2c58edcd3a29e2dcd99974d7470`](https://github.com/wevm/wagmi/commit/9c8c35a3b829f2c58edcd3a29e2dcd99974d7470), [`3892ebd21c06beef4b28ece4e70d2a38807bce6f`](https://github.com/wevm/wagmi/commit/3892ebd21c06beef4b28ece4e70d2a38807bce6f)]: + - @wagmi/connectors@5.7.1 + - @wagmi/core@2.16.1 + +## 0.1.3 + +### Patch Changes + +- Updated dependencies [[`e3f63a02c1f7d80481804584f262bc98dab0400d`](https://github.com/wevm/wagmi/commit/e3f63a02c1f7d80481804584f262bc98dab0400d)]: + - @wagmi/connectors@5.7.0 + +## 0.1.2 + +### Patch Changes + +- Updated dependencies [[`adf2253b10c6d4fc583e4bc9f01a8ef5ca267c85`](https://github.com/wevm/wagmi/commit/adf2253b10c6d4fc583e4bc9f01a8ef5ca267c85)]: + - @wagmi/connectors@5.6.2 + +## 0.1.1 + +### Patch Changes + +- Updated dependencies [[`987404f590c1d29ebb3cb68928f5e54aa032793d`](https://github.com/wevm/wagmi/commit/987404f590c1d29ebb3cb68928f5e54aa032793d)]: + - @wagmi/connectors@5.6.1 + +## 0.1.0 + +### Minor Changes + +- [#4453](https://github.com/wevm/wagmi/pull/4453) [`070e48480194c8d7f45bda1d7dd1346e6f5d7227`](https://github.com/wevm/wagmi/commit/070e48480194c8d7f45bda1d7dd1346e6f5d7227) Thanks [@tmm](https://github.com/tmm)! - Added support to `useConnect` for custom `connector.connect` parameters. + +### Patch Changes + +- Updated dependencies [[`afea6b67822a7a2b96901ec851441d27ee0f7a52`](https://github.com/wevm/wagmi/commit/afea6b67822a7a2b96901ec851441d27ee0f7a52), [`070e48480194c8d7f45bda1d7dd1346e6f5d7227`](https://github.com/wevm/wagmi/commit/070e48480194c8d7f45bda1d7dd1346e6f5d7227), [`8b0726c1106fce88b782e676498eabf0718b2619`](https://github.com/wevm/wagmi/commit/8b0726c1106fce88b782e676498eabf0718b2619)]: + - @wagmi/core@2.16.0 + - @wagmi/connectors@5.6.0 + +## 0.0.69 + +### Patch Changes + +- [`2f79a3da4872d6158569017b1927a07a1ff5e7ba`](https://github.com/wevm/wagmi/commit/2f79a3da4872d6158569017b1927a07a1ff5e7ba) Thanks [@tmm](https://github.com/tmm)! - Exported `injected` and `mock`. + +## 0.0.68 + +### Patch Changes + +- [#4433](https://github.com/wevm/wagmi/pull/4433) [`06e186cd679b27fe195309110e766fcf46d4efbc`](https://github.com/wevm/wagmi/commit/06e186cd679b27fe195309110e766fcf46d4efbc) Thanks [@Aerilym](https://github.com/Aerilym)! - Bumped Metamask SDK version to `0.31.1`. + +- Updated dependencies [[`06e186cd679b27fe195309110e766fcf46d4efbc`](https://github.com/wevm/wagmi/commit/06e186cd679b27fe195309110e766fcf46d4efbc)]: + - @wagmi/connectors@5.5.3 + - @wagmi/core@2.15.2 + +## 0.0.67 + +### Patch Changes + +- Updated dependencies [[`e563ef69130a511fd6f3f72ed4cd4fbe1390541f`](https://github.com/wevm/wagmi/commit/e563ef69130a511fd6f3f72ed4cd4fbe1390541f)]: + - @wagmi/connectors@5.5.2 + +## 0.0.66 + +### Patch Changes + +- [`b8bbb409f4934538e3dd6cac5aaf7346292d0693`](https://github.com/wevm/wagmi/commit/b8bbb409f4934538e3dd6cac5aaf7346292d0693) Thanks [@jxom](https://github.com/jxom)! - Fixed issue where `null` gas would accidentally pass through. + +- Updated dependencies [[`b8bbb409f4934538e3dd6cac5aaf7346292d0693`](https://github.com/wevm/wagmi/commit/b8bbb409f4934538e3dd6cac5aaf7346292d0693)]: + - @wagmi/core@2.15.1 + - @wagmi/connectors@5.5.1 + +## 0.0.65 + +### Minor Changes + +- [#4417](https://github.com/wevm/wagmi/pull/4417) [`42e65ea4fea99c639817088bba915e0933d17141`](https://github.com/wevm/wagmi/commit/42e65ea4fea99c639817088bba915e0933d17141) Thanks [@jxom](https://github.com/jxom)! - Removed simulation in `writeContract` & `sendTransaction`. + +### Patch Changes + +- Updated dependencies [[`42e65ea4fea99c639817088bba915e0933d17141`](https://github.com/wevm/wagmi/commit/42e65ea4fea99c639817088bba915e0933d17141)]: + - @wagmi/connectors@6.0.0 + - @wagmi/core@2.15.0 + +## 0.0.64 + +### Patch Changes + +- Updated dependencies [[`7ca62b44cd997d48f92c2b81343726a5908aa00b`](https://github.com/wevm/wagmi/commit/7ca62b44cd997d48f92c2b81343726a5908aa00b)]: + - @wagmi/connectors@5.4.0 + +## 0.0.63 + +### Patch Changes + +- Updated dependencies [[`a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3`](https://github.com/wevm/wagmi/commit/a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3), [`a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3`](https://github.com/wevm/wagmi/commit/a13aa8d7c38eb3cc8171a02d6302e6d12cf6bcb3)]: + - @wagmi/core@2.14.6 + - @wagmi/connectors@5.3.10 + +## 0.0.62 + +### Patch Changes + +- Updated dependencies [[`b12a04eeec985c48d2feac94b011d41fb29ca23e`](https://github.com/wevm/wagmi/commit/b12a04eeec985c48d2feac94b011d41fb29ca23e)]: + - @wagmi/connectors@5.3.9 + +## 0.0.61 + +### Patch Changes + +- Updated dependencies [[`6b9bbacdc7bffd44fc2165362a5e65fd434e7646`](https://github.com/wevm/wagmi/commit/6b9bbacdc7bffd44fc2165362a5e65fd434e7646), [`dac62dc99a0679fa632a0fae49873d6053d06b35`](https://github.com/wevm/wagmi/commit/dac62dc99a0679fa632a0fae49873d6053d06b35)]: + - @wagmi/core@2.14.5 + - @wagmi/connectors@5.3.8 + +## 0.0.60 + +### Patch Changes + +- Updated dependencies [[`e08681c81fbdf475213e2d0f4c5517d0abf4e743`](https://github.com/wevm/wagmi/commit/e08681c81fbdf475213e2d0f4c5517d0abf4e743)]: + - @wagmi/core@2.14.4 + - @wagmi/connectors@5.3.7 + +## 0.0.59 + +### Patch Changes + +- Updated dependencies [[`7558ff3133c11bc4c49473d08ee9a47eaa12df5b`](https://github.com/wevm/wagmi/commit/7558ff3133c11bc4c49473d08ee9a47eaa12df5b)]: + - @wagmi/connectors@5.3.6 + +## 0.0.58 + +### Patch Changes + +- Updated dependencies [[`cb7dd2ebb871d0be8f1a11a8cd8ce592cd74b7c7`](https://github.com/wevm/wagmi/commit/cb7dd2ebb871d0be8f1a11a8cd8ce592cd74b7c7), [`7fe78f2d09778fc01fd0cffe85ba198e64999275`](https://github.com/wevm/wagmi/commit/7fe78f2d09778fc01fd0cffe85ba198e64999275)]: + - @wagmi/core@2.14.3 + - @wagmi/connectors@5.3.5 + +## 0.0.57 + +### Patch Changes + +- Updated dependencies [[`b6861a4c378dab78d8751ae0ac2aa425f3c24b8f`](https://github.com/wevm/wagmi/commit/b6861a4c378dab78d8751ae0ac2aa425f3c24b8f), [`d0d0963bb5904a15cf0355862d62dd141ce0c31c`](https://github.com/wevm/wagmi/commit/d0d0963bb5904a15cf0355862d62dd141ce0c31c), [`ecac0ba36243d94c9199d0bd21937104c835d9a0`](https://github.com/wevm/wagmi/commit/ecac0ba36243d94c9199d0bd21937104c835d9a0)]: + - @wagmi/connectors@5.3.4 + - @wagmi/core@2.14.2 + +## 0.0.56 + +### Patch Changes + +- Updated dependencies [[`83c6d16b7d6dddfa6bda036e04f00ec313c6248c`](https://github.com/wevm/wagmi/commit/83c6d16b7d6dddfa6bda036e04f00ec313c6248c)]: + - @wagmi/connectors@5.3.3 + +## 0.0.55 + +### Patch Changes + +- Updated dependencies [[`8970cc51398e1ac713435533096215c6d31ffdf9`](https://github.com/wevm/wagmi/commit/8970cc51398e1ac713435533096215c6d31ffdf9)]: + - @wagmi/connectors@5.3.2 + +## 0.0.54 + +### Patch Changes + +- Updated dependencies [[`052e72e1f8c1c14fcbdce04a9f8fa7ec28d83702`](https://github.com/wevm/wagmi/commit/052e72e1f8c1c14fcbdce04a9f8fa7ec28d83702), [`b250fc21ee577b2a75c5a34ff684f62fb4ad771a`](https://github.com/wevm/wagmi/commit/b250fc21ee577b2a75c5a34ff684f62fb4ad771a)]: + - @wagmi/core@2.14.1 + - @wagmi/connectors@5.3.1 + +## 0.0.53 + +### Patch Changes + +- Updated dependencies [[`f43e074f473820b208a6295d7c97f847332f1a1d`](https://github.com/wevm/wagmi/commit/f43e074f473820b208a6295d7c97f847332f1a1d)]: + - @wagmi/connectors@6.0.0 + - @wagmi/core@2.14.0 + +## 0.0.52 + +### Patch Changes + +- Updated dependencies [[`c05caabc20c3ced9682cfc7ba1f3f7dcfece0703`](https://github.com/wevm/wagmi/commit/c05caabc20c3ced9682cfc7ba1f3f7dcfece0703), [`5ae49af590ff168426c9c283d54c34ae5148fcd9`](https://github.com/wevm/wagmi/commit/5ae49af590ff168426c9c283d54c34ae5148fcd9), [`f3182b22e6e454d9bd74f1b940ef34431fd9555d`](https://github.com/wevm/wagmi/commit/f3182b22e6e454d9bd74f1b940ef34431fd9555d)]: + - @wagmi/core@2.13.9 + - @wagmi/connectors@5.2.2 + +## 0.0.51 + +### Patch Changes + +- Updated dependencies [[`91a40f2db08e3a91db421b8732a5511a1e6c88fd`](https://github.com/wevm/wagmi/commit/91a40f2db08e3a91db421b8732a5511a1e6c88fd)]: + - @wagmi/connectors@5.2.1 + +## 0.0.50 + +### Patch Changes + +- Updated dependencies [[`34a0c3b7eea778aee7c27f7ace5e4b2be4e8a0a4`](https://github.com/wevm/wagmi/commit/34a0c3b7eea778aee7c27f7ace5e4b2be4e8a0a4)]: + - @wagmi/connectors@5.2.0 + +## 0.0.49 + +### Patch Changes + +- Updated dependencies [[`3b2123664b7ac66848390739e855c3b9702ab60c`](https://github.com/wevm/wagmi/commit/3b2123664b7ac66848390739e855c3b9702ab60c)]: + - @wagmi/connectors@5.1.15 + +## 0.0.48 + +### Patch Changes + +- Updated dependencies [[`56f2482508f2ba71bd6b0295c70c6abca7101e57`](https://github.com/wevm/wagmi/commit/56f2482508f2ba71bd6b0295c70c6abca7101e57)]: + - @wagmi/connectors@5.1.14 + - @wagmi/core@2.13.8 + +## 0.0.47 + +### Patch Changes + +- Updated dependencies [[`be75c2d4ef636d7362420ab0a106bfdf63f5d1e6`](https://github.com/wevm/wagmi/commit/be75c2d4ef636d7362420ab0a106bfdf63f5d1e6)]: + - @wagmi/core@2.13.7 + - @wagmi/connectors@5.1.13 + +## 0.0.46 + +### Patch Changes + +- Updated dependencies [[`edcbf5d6fbe92f639bead800502edda9e0aa39f1`](https://github.com/wevm/wagmi/commit/edcbf5d6fbe92f639bead800502edda9e0aa39f1)]: + - @wagmi/core@2.13.6 + - @wagmi/connectors@5.1.12 + +## 0.0.45 + +### Patch Changes + +- Updated dependencies [[`82404c960e04c83e0bae6e1e12459ef9debf9554`](https://github.com/wevm/wagmi/commit/82404c960e04c83e0bae6e1e12459ef9debf9554), [`d07ad7f63a018256908a673d078aaf79e47ac703`](https://github.com/wevm/wagmi/commit/d07ad7f63a018256908a673d078aaf79e47ac703)]: + - @wagmi/connectors@5.1.11 + +## 0.0.44 + +### Patch Changes + +- [#4262](https://github.com/wevm/wagmi/pull/4262) [`8531f83db3a1fbb8202c3e426b7f85679f587a52`](https://github.com/wevm/wagmi/commit/8531f83db3a1fbb8202c3e426b7f85679f587a52) Thanks [@nezouse](https://github.com/nezouse)! - Added experimental actions entrypoint. + +## 0.0.43 + +### Patch Changes + +- [#4260](https://github.com/wevm/wagmi/pull/4260) [`969a208a110b760a13fd7263360320f52440a9b6`](https://github.com/wevm/wagmi/commit/969a208a110b760a13fd7263360320f52440a9b6) Thanks [@tmm](https://github.com/tmm)! - Fixed `useReadContract` deployless reads support. + +- [#4259](https://github.com/wevm/wagmi/pull/4259) [`f47ce8f6d263e49fdff90b8edb3190142d2657bb`](https://github.com/wevm/wagmi/commit/f47ce8f6d263e49fdff90b8edb3190142d2657bb) Thanks [@tmm](https://github.com/tmm)! - Disabled `useConnectorClient` during reconnection if connector is not fully restored. + +- Updated dependencies [[`81de006e66121a18c61945c1f9b8426c83a5713c`](https://github.com/wevm/wagmi/commit/81de006e66121a18c61945c1f9b8426c83a5713c), [`f47ce8f6d263e49fdff90b8edb3190142d2657bb`](https://github.com/wevm/wagmi/commit/f47ce8f6d263e49fdff90b8edb3190142d2657bb)]: + - @wagmi/connectors@5.1.10 + - @wagmi/core@2.13.5 + +## 0.0.42 + +### Patch Changes + +- [#4252](https://github.com/wevm/wagmi/pull/4252) [`67defb516bbd9b2c7b03e376ecd3aca8a001d065`](https://github.com/wevm/wagmi/commit/67defb516bbd9b2c7b03e376ecd3aca8a001d065) Thanks [@tmm](https://github.com/tmm)! - Added `useWatchContractEvent`. + +## 0.0.41 + +### Patch Changes + +- Updated dependencies [[`21bd0e473d374cbbd7a01bececa6022d529026ba`](https://github.com/wevm/wagmi/commit/21bd0e473d374cbbd7a01bececa6022d529026ba), [`5c89c6853e616437a3be2b019db895451fecfb3c`](https://github.com/wevm/wagmi/commit/5c89c6853e616437a3be2b019db895451fecfb3c)]: + - @wagmi/connectors@5.1.9 + +## 0.0.40 + +### Patch Changes + +- Updated dependencies [[`b580ad4edff1721e0b9d138cf5ae2ec74d2374c7`](https://github.com/wevm/wagmi/commit/b580ad4edff1721e0b9d138cf5ae2ec74d2374c7)]: + - @wagmi/connectors@5.1.8 + +## 0.0.39 + +### Patch Changes + +- Updated dependencies [[`91fd81a068789c5020e891f539bcad8f54a7a52f`](https://github.com/wevm/wagmi/commit/91fd81a068789c5020e891f539bcad8f54a7a52f)]: + - @wagmi/connectors@5.1.7 + +## 0.0.38 + +### Patch Changes + +- Updated dependencies [[`3168616298cbb6135d0ffda771cba4126e83eba8`](https://github.com/wevm/wagmi/commit/3168616298cbb6135d0ffda771cba4126e83eba8), [`d7608ef9a79459465dc8c06a2ab740465c881907`](https://github.com/wevm/wagmi/commit/d7608ef9a79459465dc8c06a2ab740465c881907)]: + - @wagmi/connectors@5.1.6 + +## 0.0.37 + +### Patch Changes + +- Updated dependencies [[`b4c8971788c70b09479946ecfa998cff2f1b3953`](https://github.com/wevm/wagmi/commit/b4c8971788c70b09479946ecfa998cff2f1b3953)]: + - @wagmi/core@2.13.4 + - @wagmi/connectors@5.1.5 + +## 0.0.36 + +### Patch Changes + +- Updated dependencies [[`871dbdbfe59ac8ad01d1ec6150ea7b091b7b7de4`](https://github.com/wevm/wagmi/commit/871dbdbfe59ac8ad01d1ec6150ea7b091b7b7de4)]: + - @wagmi/core@2.13.3 + - @wagmi/connectors@5.1.4 + +## 0.0.35 + +### Patch Changes + +- Updated dependencies [[`1b9b523fa9b9dfe839aecdf4b40caa9547d7e594`](https://github.com/wevm/wagmi/commit/1b9b523fa9b9dfe839aecdf4b40caa9547d7e594)]: + - @wagmi/core@2.13.2 + - @wagmi/connectors@5.1.3 + +## 0.0.34 + +### Patch Changes + +- Updated dependencies [[`abb490dac4f0f02f46cb0878e7ca9a0db6aada56`](https://github.com/wevm/wagmi/commit/abb490dac4f0f02f46cb0878e7ca9a0db6aada56), [`28e0e5c9a4f856583f9d36a807502bd51a0c6ec2`](https://github.com/wevm/wagmi/commit/28e0e5c9a4f856583f9d36a807502bd51a0c6ec2)]: + - @wagmi/connectors@5.1.2 + +## 0.0.33 + +### Patch Changes + +- Updated dependencies [[`07c1227f306d0efb9421d4bb77a774f92f5fcf45`](https://github.com/wevm/wagmi/commit/07c1227f306d0efb9421d4bb77a774f92f5fcf45)]: + - @wagmi/core@2.13.1 + - @wagmi/connectors@5.1.1 + +## 0.0.32 + +### Patch Changes + +- [#4162](https://github.com/wevm/wagmi/pull/4162) [`a73a7737b756886b388f120ae423e72cca53e8a0`](https://github.com/wevm/wagmi/commit/a73a7737b756886b388f120ae423e72cca53e8a0) Thanks [@jxom](https://github.com/jxom)! - Added functionality for consumer-defined RPC URLs (`config.transports`) to be propagated to the WalletConnect & MetaMask Connectors. + +- Updated dependencies [[`a73a7737b756886b388f120ae423e72cca53e8a0`](https://github.com/wevm/wagmi/commit/a73a7737b756886b388f120ae423e72cca53e8a0)]: + - @wagmi/connectors@6.0.0 + - @wagmi/core@2.13.0 + +## 0.0.31 + +### Patch Changes + +- [#4124](https://github.com/wevm/wagmi/pull/4124) [`26616462db2e0140025f22c505c4541cfecb9308`](https://github.com/wevm/wagmi/commit/26616462db2e0140025f22c505c4541cfecb9308) Thanks [@t0rbik](https://github.com/t0rbik)! - Updated `useConnectorClient` to be enabled when status is `'reconnecting'` or `'connected'` (previously was also enabled when status was `'connecting'`). + +## 0.0.30 + +### Patch Changes + +- Updated dependencies [[`5bc8c8877810b2eec24a829df87dce40a51e6f20`](https://github.com/wevm/wagmi/commit/5bc8c8877810b2eec24a829df87dce40a51e6f20), [`8d81df5cc884d0a210dedd3c1ea0e2e9e52b83c5`](https://github.com/wevm/wagmi/commit/8d81df5cc884d0a210dedd3c1ea0e2e9e52b83c5)]: + - @wagmi/core@2.12.2 + - @wagmi/connectors@5.0.26 + +## 0.0.29 + +### Patch Changes + +- [#4146](https://github.com/wevm/wagmi/pull/4146) [`cc996e08e930c9e88cf753a1e874652059e81a3b`](https://github.com/wevm/wagmi/commit/cc996e08e930c9e88cf753a1e874652059e81a3b) Thanks [@jxom](https://github.com/jxom)! - Updated `@safe-global/safe-apps-sdk` + `@safe-global/safe-apps-provider` dependencies. + +- Updated dependencies [[`cc996e08e930c9e88cf753a1e874652059e81a3b`](https://github.com/wevm/wagmi/commit/cc996e08e930c9e88cf753a1e874652059e81a3b)]: + - @wagmi/connectors@5.0.25 + - @wagmi/core@2.12.1 + +## 0.0.28 + +### Patch Changes + +- [`b6cb1477e3e87984917b172a909f1968e0d77dc9`](https://github.com/wevm/wagmi/commit/b6cb1477e3e87984917b172a909f1968e0d77dc9) Thanks [@tmm](https://github.com/tmm)! - Added `useBytecode` composable. + +- Updated dependencies [[`5581a810ef70308e99c6f8b630cd4bca59f64afc`](https://github.com/wevm/wagmi/commit/5581a810ef70308e99c6f8b630cd4bca59f64afc)]: + - @wagmi/core@2.12.0 + - @wagmi/connectors@6.0.0 + +## 0.0.27 + +### Patch Changes + +- [`d3814ab4b88f9f0e052b53bc3d458df87b43f01d`](https://github.com/wevm/wagmi/commit/d3814ab4b88f9f0e052b53bc3d458df87b43f01d) Thanks [@jxom](https://github.com/jxom)! - Updated `mipd` dependency. + +- Updated dependencies [[`b08013eaa9ce97c02f8a7128ea400e3da7ef74bb`](https://github.com/wevm/wagmi/commit/b08013eaa9ce97c02f8a7128ea400e3da7ef74bb), [`d3814ab4b88f9f0e052b53bc3d458df87b43f01d`](https://github.com/wevm/wagmi/commit/d3814ab4b88f9f0e052b53bc3d458df87b43f01d)]: + - @wagmi/core@2.11.8 + - @wagmi/connectors@5.0.23 + +## 0.0.26 + +### Patch Changes + +- Updated dependencies [[`0bb8b562ae04ecfeb2d6b2f1b980ebae31dc127e`](https://github.com/wevm/wagmi/commit/0bb8b562ae04ecfeb2d6b2f1b980ebae31dc127e)]: + - @wagmi/connectors@5.0.22 + - @wagmi/core@2.11.7 + +## 0.0.25 + +### Patch Changes + +- [#4060](https://github.com/wevm/wagmi/pull/4060) [`95965c1f19d480b97f2b297a077a9e607dee32ad`](https://github.com/wevm/wagmi/commit/95965c1f19d480b97f2b297a077a9e607dee32ad) Thanks [@dalechyn](https://github.com/dalechyn)! - Bumped Tanstack Query dependencies to fix typing issues between exported Wagmi query options and TanStack Query suspense query methods (due to [`direction` property in `QueryFunctionContext` being deprecated](https://github.com/TanStack/query/pull/7410)). + +- Updated dependencies [[`ff0760b5900114bcfdf420a9fba3cc278ac95afe`](https://github.com/wevm/wagmi/commit/ff0760b5900114bcfdf420a9fba3cc278ac95afe), [`95965c1f19d480b97f2b297a077a9e607dee32ad`](https://github.com/wevm/wagmi/commit/95965c1f19d480b97f2b297a077a9e607dee32ad)]: + - @wagmi/connectors@5.0.21 + - @wagmi/core@2.11.6 + +## 0.0.24 + +### Patch Changes + +- Updated dependencies [[`43fa971d34cac57fa5a2898ad4d839b95d7af37c`](https://github.com/wevm/wagmi/commit/43fa971d34cac57fa5a2898ad4d839b95d7af37c)]: + - @wagmi/connectors@5.0.20 + +## 0.0.23 + +### Patch Changes + +- Updated dependencies [[`b7ad208030d9f2e3f89912ff76b16cdbd848feda`](https://github.com/wevm/wagmi/commit/b7ad208030d9f2e3f89912ff76b16cdbd848feda)]: + - @wagmi/connectors@5.0.19 + +## 0.0.22 + +### Patch Changes + +- Updated dependencies [[`44d24620c9e3957f3245d14d6a042736371df70b`](https://github.com/wevm/wagmi/commit/44d24620c9e3957f3245d14d6a042736371df70b)]: + - @wagmi/connectors@5.0.18 + +## 0.0.21 + +### Patch Changes + +- Updated dependencies [[`04f2b846b113f3d300d82c9fa75212f1805817c5`](https://github.com/wevm/wagmi/commit/04f2b846b113f3d300d82c9fa75212f1805817c5)]: + - @wagmi/core@2.11.5 + - @wagmi/connectors@5.0.17 + +## 0.0.20 + +### Patch Changes + +- Updated dependencies [[`9e8345cd56186b997b5e56deaa2cfc69b30d15f6`](https://github.com/wevm/wagmi/commit/9e8345cd56186b997b5e56deaa2cfc69b30d15f6), [`02c38c28d1aa0ad7a61c33775de603ed974c5c1b`](https://github.com/wevm/wagmi/commit/02c38c28d1aa0ad7a61c33775de603ed974c5c1b)]: + - @wagmi/core@2.11.4 + - @wagmi/connectors@5.0.16 + +## 0.0.19 + +### Patch Changes + +- Updated dependencies [[`8974e6269bb5d7bfaa90db0246bc7d13e8bff798`](https://github.com/wevm/wagmi/commit/8974e6269bb5d7bfaa90db0246bc7d13e8bff798)]: + - @wagmi/core@2.11.3 + - @wagmi/connectors@5.0.15 + +## 0.0.18 + +### Patch Changes + +- Updated dependencies [[`b4d9ef79deb554ee20fed6666a474be5e7cdd522`](https://github.com/wevm/wagmi/commit/b4d9ef79deb554ee20fed6666a474be5e7cdd522)]: + - @wagmi/core@2.11.2 + - @wagmi/connectors@5.0.14 + +## 0.0.17 + +### Patch Changes + +- Updated dependencies [[`9c862d8d63e3d692a22cef2a90782b74a9103f17`](https://github.com/wevm/wagmi/commit/9c862d8d63e3d692a22cef2a90782b74a9103f17)]: + - @wagmi/connectors@5.0.13 + - @wagmi/core@2.11.1 + +## 0.0.16 + +### Patch Changes + +- Updated dependencies [[`06bb598a7f04c7b167f5b7ff6d46bd15886a6a14`](https://github.com/wevm/wagmi/commit/06bb598a7f04c7b167f5b7ff6d46bd15886a6a14), [`24a45b269bd0214a29d6f82a84ac66ef8c3f3822`](https://github.com/wevm/wagmi/commit/24a45b269bd0214a29d6f82a84ac66ef8c3f3822)]: + - @wagmi/core@2.11.0 + - @wagmi/connectors@6.0.0 + +## 0.0.15 + +### Patch Changes + +- Updated dependencies [[`f2a7cefab96691ebed8b8e45ffde071c47b58dbe`](https://github.com/wevm/wagmi/commit/f2a7cefab96691ebed8b8e45ffde071c47b58dbe), [`f0ea0b2a7fe193dadfeb49a4c8031ee451c638b5`](https://github.com/wevm/wagmi/commit/f0ea0b2a7fe193dadfeb49a4c8031ee451c638b5), [`e3b124ce414b8fd1b2214e2c5a28dc72158a13d1`](https://github.com/wevm/wagmi/commit/e3b124ce414b8fd1b2214e2c5a28dc72158a13d1)]: + - @wagmi/core@2.10.6 + - @wagmi/connectors@5.0.11 + +## 0.0.14 + +### Patch Changes + +- Updated dependencies [[`560952acd4bfe33db6c7c07b35c613cef278677c`](https://github.com/wevm/wagmi/commit/560952acd4bfe33db6c7c07b35c613cef278677c)]: + - @wagmi/connectors@5.0.10 + +## 0.0.13 + +### Patch Changes + +- Updated dependencies [[`32cdd7b7dc5aff916c040628519562c3a99d418d`](https://github.com/wevm/wagmi/commit/32cdd7b7dc5aff916c040628519562c3a99d418d)]: + - @wagmi/connectors@5.0.9 + +## 0.0.12 + +### Patch Changes + +- Updated dependencies [[`c1952d1ff7f0a491dc88595a49159451b07b5621`](https://github.com/wevm/wagmi/commit/c1952d1ff7f0a491dc88595a49159451b07b5621)]: + - @wagmi/connectors@5.0.8 + +## 0.0.11 + +### Patch Changes + +- Updated dependencies [[`030c7c2cb380dfd67a2182f62e2aa7a6e1601898`](https://github.com/wevm/wagmi/commit/030c7c2cb380dfd67a2182f62e2aa7a6e1601898)]: + - @wagmi/core@2.10.5 + - @wagmi/connectors@5.0.7 + +## 0.0.10 + +### Patch Changes + +- Updated dependencies [[`51fde8a0433b4fff357c1a8d7e08b41b4c86c968`](https://github.com/wevm/wagmi/commit/51fde8a0433b4fff357c1a8d7e08b41b4c86c968)]: + - @wagmi/core@2.10.4 + - @wagmi/connectors@5.0.6 + +## 0.0.9 + +### Patch Changes + +- Updated dependencies [[`70dd28669dd8d2ce08217cd02e29a8fbba7a08d4`](https://github.com/wevm/wagmi/commit/70dd28669dd8d2ce08217cd02e29a8fbba7a08d4)]: + - @wagmi/connectors@5.0.5 + +## 0.0.8 + +### Patch Changes + +- Updated dependencies [[`be9e1b8a9818b92eb0654a20d9471e9e39329e7e`](https://github.com/wevm/wagmi/commit/be9e1b8a9818b92eb0654a20d9471e9e39329e7e)]: + - @wagmi/connectors@5.0.4 + +## 0.0.7 + +### Patch Changes + +- Updated dependencies [[`2804a8a583b1874271154898b4bae38756ef581c`](https://github.com/wevm/wagmi/commit/2804a8a583b1874271154898b4bae38756ef581c), [`2804a8a583b1874271154898b4bae38756ef581c`](https://github.com/wevm/wagmi/commit/2804a8a583b1874271154898b4bae38756ef581c)]: + - @wagmi/connectors@5.0.3 + - @wagmi/core@2.10.3 + +## 0.0.6 + +### Patch Changes + +- [`ec2f63f106fd468f28b43d3b88ab3e89aaf5e81a`](https://github.com/wevm/wagmi/commit/ec2f63f106fd468f28b43d3b88ab3e89aaf5e81a) Thanks [@tmm](https://github.com/tmm)! - Fixed `useSwitchChain` `chains` typing. + +## 0.0.5 + +### Patch Changes + +- [#3940](https://github.com/wevm/wagmi/pull/3940) [`a5071f581dfdfb961718873643a2fc629101c72a`](https://github.com/wevm/wagmi/commit/a5071f581dfdfb961718873643a2fc629101c72a) Thanks [@jxom](https://github.com/jxom)! - Fixed usage of `metaMask` connector in Vite environments. + +- Updated dependencies [[`a5071f581dfdfb961718873643a2fc629101c72a`](https://github.com/wevm/wagmi/commit/a5071f581dfdfb961718873643a2fc629101c72a)]: + - @wagmi/connectors@5.0.2 + - @wagmi/core@2.10.2 + +## 0.0.4 + +### Patch Changes + +- Updated dependencies []: + - @wagmi/connectors@5.0.1 + - @wagmi/core@2.10.1 + +## 0.0.3 + +### Patch Changes + +- Updated dependencies [[`3117e71825f9c58a0d718f3d1686f1a191fa9cb1`](https://github.com/wevm/wagmi/commit/3117e71825f9c58a0d718f3d1686f1a191fa9cb1), [`3117e71825f9c58a0d718f3d1686f1a191fa9cb1`](https://github.com/wevm/wagmi/commit/3117e71825f9c58a0d718f3d1686f1a191fa9cb1)]: + - @wagmi/connectors@5.0.0 + - @wagmi/core@2.10.0 + +## 0.0.2 + +### Patch Changes + +- [#3906](https://github.com/wevm/wagmi/pull/3906) [`32fcb4a31dde6b0206961d8ffe9c651f8a459c67`](https://github.com/wevm/wagmi/commit/32fcb4a31dde6b0206961d8ffe9c651f8a459c67) Thanks [@tmm](https://github.com/tmm)! - Added support for Vue. + +- Updated dependencies [[`32fcb4a31dde6b0206961d8ffe9c651f8a459c67`](https://github.com/wevm/wagmi/commit/32fcb4a31dde6b0206961d8ffe9c651f8a459c67)]: + - @wagmi/connectors@4.3.10 + - @wagmi/core@2.9.8 diff --git a/packages/vue/README.md b/packages/vue/README.md new file mode 100644 index 0000000000..10a4b805d5 --- /dev/null +++ b/packages/vue/README.md @@ -0,0 +1,14 @@ +# @wagmi/vue + +Vue Composables for Ethereum + +## Installation + +```bash +pnpm add @wagmi/vue viem @tanstack/vue-query +``` + +## Documentation + +For documentation and guides, visit [wagmi.sh](https://wagmi.sh). + diff --git a/packages/vue/package.json b/packages/vue/package.json new file mode 100644 index 0000000000..8f0a821301 --- /dev/null +++ b/packages/vue/package.json @@ -0,0 +1,113 @@ +{ + "name": "@wagmi/vue", + "description": "Vue Composables for Ethereum", + "version": "0.1.20", + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/wevm/wagmi.git", + "directory": "packages/vue" + }, + "scripts": { + "build": "pnpm run clean && pnpm run build:esm+types", + "build:esm+types": "tsc --project tsconfig.build.json --outDir ./dist/esm --declaration --declarationMap --declarationDir ./dist/types", + "check:types": "tsc --noEmit", + "clean": "rm -rf dist tsconfig.tsbuildinfo actions chains connectors nuxt query", + "test:build": "publint --strict && attw --pack --ignore-rules cjs-resolves-to-esm" + }, + "files": [ + "dist/**", + "!dist/**/*.tsbuildinfo", + "src/**/*.ts", + "!src/**/*.test.ts", + "!src/**/*.test-d.ts", + "/actions", + "/chains", + "/connectors", + "/nuxt", + "/query" + ], + "sideEffects": false, + "type": "module", + "main": "./dist/esm/exports/index.js", + "types": "./dist/types/exports/index.d.ts", + "typings": "./dist/types/exports/index.d.ts", + "exports": { + ".": { + "types": "./dist/types/exports/index.d.ts", + "default": "./dist/esm/exports/index.js" + }, + "./actions": { + "types": "./dist/types/exports/actions.d.ts", + "default": "./dist/esm/exports/actions.js" + }, + "./actions/experimental": { + "types": "./dist/types/exports/actions/experimental.d.ts", + "default": "./dist/esm/exports/actions/experimental.js" + }, + "./chains": { + "types": "./dist/types/exports/chains.d.ts", + "default": "./dist/esm/exports/chains.js" + }, + "./connectors": { + "types": "./dist/types/exports/connectors.d.ts", + "default": "./dist/esm/exports/connectors.js" + }, + "./nuxt": { + "types": "./dist/types/exports/nuxt.d.ts", + "default": "./dist/esm/exports/nuxt.js" + }, + "./query": { + "types": "./dist/types/exports/query.d.ts", + "default": "./dist/esm/exports/query.js" + }, + "./package.json": "./package.json" + }, + "typesVersions": { + "*": { + "actions": ["./dist/types/exports/actions.d.ts"], + "chains": ["./dist/types/exports/chains.d.ts"], + "connectors": ["./dist/types/exports/connectors.d.ts"], + "nuxt": ["./dist/types/exports/nuxt.d.ts"], + "query": ["./dist/types/exports/query.d.ts"] + } + }, + "peerDependencies": { + "@tanstack/vue-query": ">=5.0.0", + "nuxt": ">=3.0.0", + "typescript": ">=5.0.4", + "viem": "2.x", + "vue": ">=3" + }, + "peerDependenciesMeta": { + "nuxt": { + "optional": true + }, + "typescript": { + "optional": true + } + }, + "dependencies": { + "@wagmi/connectors": "workspace:*", + "@wagmi/core": "workspace:*" + }, + "devDependencies": { + "@nuxt/schema": "^3.11.2", + "@tanstack/vue-query": "catalog:", + "@vue/test-utils": "^2.4.6", + "nuxt": "^3.19.0", + "vue": "catalog:" + }, + "contributors": ["awkweb.eth ", "jxom.eth "], + "funding": "https://github.com/sponsors/wevm", + "keywords": [ + "wagmi", + "vue", + "composables", + "eth", + "ethereum", + "dapps", + "wallet", + "web3" + ] +} diff --git a/packages/vue/src/composables/useAccount.test-d.ts b/packages/vue/src/composables/useAccount.test-d.ts new file mode 100644 index 0000000000..cc0ef07dcc --- /dev/null +++ b/packages/vue/src/composables/useAccount.test-d.ts @@ -0,0 +1,69 @@ +import type { Connector } from '@wagmi/core' +import type { Address, Chain } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { deepUnref } from '../utils/cloneDeep.js' +import { useAccount } from './useAccount.js' + +test('states', () => { + const result = deepUnref(useAccount()) + + switch (result.status) { + case 'reconnecting': { + expectTypeOf(result).toMatchTypeOf<{ + address: Address | undefined + chain: Chain | undefined + chainId: number | undefined + connector: Connector | undefined + isConnected: boolean + isConnecting: false + isDisconnected: false + isReconnecting: true + status: 'reconnecting' + }>() + break + } + case 'connecting': { + expectTypeOf(result).toMatchTypeOf<{ + address: Address | undefined + chain: Chain | undefined + chainId: number | undefined + connector: Connector | undefined + isConnected: false + isReconnecting: false + isConnecting: true + isDisconnected: false + status: 'connecting' + }>() + break + } + case 'connected': { + expectTypeOf(result).toMatchTypeOf<{ + address: Address + chain: Chain | undefined + chainId: number + connector: Connector + isConnected: true + isConnecting: false + isDisconnected: false + isReconnecting: false + status: 'connected' + }>() + break + } + case 'disconnected': { + expectTypeOf(result).toMatchTypeOf<{ + address: undefined + chain: undefined + chainId: undefined + connector: undefined + isConnected: false + isReconnecting: false + isConnecting: false + isDisconnected: true + status: 'disconnected' + }>() + break + } + } +}) diff --git a/packages/vue/src/composables/useAccount.test.ts b/packages/vue/src/composables/useAccount.test.ts new file mode 100644 index 0000000000..773532857d --- /dev/null +++ b/packages/vue/src/composables/useAccount.test.ts @@ -0,0 +1,20 @@ +import { connect, disconnect } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderComposable } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { useAccount } from './useAccount.js' + +test('default', async () => { + const [account] = renderComposable(() => useAccount()) + + expect(account.address.value).not.toBeDefined() + expect(account.status.value).toEqual('disconnected') + + await connect(config, { connector: config.connectors[0]! }) + + expect(account.address.value).toBeDefined() + expect(account.status.value).toEqual('connected') + + await disconnect(config) +}) diff --git a/packages/vue/src/composables/useAccount.ts b/packages/vue/src/composables/useAccount.ts new file mode 100644 index 0000000000..136595fb20 --- /dev/null +++ b/packages/vue/src/composables/useAccount.ts @@ -0,0 +1,37 @@ +import { + type Config, + type GetAccountReturnType, + type ResolvedRegister, + getAccount, + watchAccount, +} from '@wagmi/core' +import { type ToRefs, onScopeDispose, reactive, readonly, toRefs } from 'vue' + +import type { ConfigParameter } from '../types/properties.js' +import { updateState } from '../utils/updateState.js' +import { useConfig } from './useConfig.js' + +export type UseAccountParameters = + ConfigParameter + +export type UseAccountReturnType = ToRefs< + GetAccountReturnType +> + +/** https://wagmi.sh/vue/api/composables/useAccount */ +export function useAccount( + parameters: UseAccountParameters = {}, +): UseAccountReturnType { + const config = useConfig(parameters) + + const account = reactive(getAccount(config)) + + const unsubscribe = watchAccount(config, { + onChange(data) { + updateState(account, data) + }, + }) + onScopeDispose(() => unsubscribe()) + + return toRefs(readonly(account)) as UseAccountReturnType +} diff --git a/packages/vue/src/composables/useAccountEffect.test.ts b/packages/vue/src/composables/useAccountEffect.test.ts new file mode 100644 index 0000000000..10ed7a3e37 --- /dev/null +++ b/packages/vue/src/composables/useAccountEffect.test.ts @@ -0,0 +1,75 @@ +import { VueQueryPlugin } from '@tanstack/vue-query' +import { mock } from '@wagmi/connectors' +import { http, connect, createConfig, disconnect } from '@wagmi/core' +import { accounts, chain } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test, vi } from 'vitest' +import type { App } from 'vue' + +import { WagmiPlugin } from '../plugin.js' +import { useAccount } from './useAccount.js' +import { useAccountEffect } from './useAccountEffect.js' +import { useConnect } from './useConnect.js' +import { useDisconnect } from './useDisconnect.js' + +test('behavior: connect and disconnect called once', async () => { + const onConnect = vi.fn() + const onDisconnect = vi.fn() + + renderComposable(() => useAccountEffect({ onConnect, onDisconnect })) + const [connect] = renderComposable(() => useConnect()) + const [disconnect] = renderComposable(() => useDisconnect()) + + connect.connect({ + connector: connect.connectors[0]!, + }) + await waitFor(connect.isSuccess) + connect.connect({ + connector: connect.connectors[0]!, + }) + + disconnect.disconnect() + await waitFor(disconnect.isSuccess) + disconnect.disconnect() + + expect(onConnect).toBeCalledTimes(1) + expect(onDisconnect).toBeCalledTimes(1) +}) + +test('behavior: connect called on reconnect', async () => { + const config = createConfig({ + chains: [chain.mainnet], + connectors: [ + mock({ + accounts, + features: { reconnect: true }, + }), + ], + transports: { [chain.mainnet.id]: http() }, + }) + + function attach(app: App) { + app + .use(WagmiPlugin, { + config, + reconnectOnMount: true, + }) + .use(VueQueryPlugin, {}) + } + + await connect(config, { connector: config.connectors[0]! }) + const onConnect = vi.fn((data) => { + expect(data.isReconnected).toBeTruthy() + }) + + renderComposable(() => useAccountEffect({ onConnect }), { + attach, + }) + const [account] = renderComposable(() => useAccount(), { attach }) + + await waitFor(account.status, (status) => status === 'connected') + + expect(onConnect).toBeCalledTimes(1) + + await disconnect(config) +}) diff --git a/packages/vue/src/composables/useAccountEffect.ts b/packages/vue/src/composables/useAccountEffect.ts new file mode 100644 index 0000000000..021624cea8 --- /dev/null +++ b/packages/vue/src/composables/useAccountEffect.ts @@ -0,0 +1,66 @@ +import { type GetAccountReturnType, watchAccount } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { watchEffect } from 'vue' + +import type { ConfigParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { useConfig } from './useConfig.js' + +export type UseAccountEffectParameters = Compute< + DeepMaybeRef< + { + onConnect?( + data: Compute< + Pick< + Extract, + 'address' | 'addresses' | 'chain' | 'chainId' | 'connector' + > & { + isReconnected: boolean + } + >, + ): void + onDisconnect?(): void + } & ConfigParameter + > +> + +/** https://wagmi.sh/vue/api/composables/useAccountEffect */ +export function useAccountEffect(parameters: UseAccountEffectParameters = {}) { + const config = useConfig(parameters) + + watchEffect((onCleanup) => { + const { onConnect, onDisconnect } = deepUnref(parameters) + + const unwatch = watchAccount(config, { + onChange(data, prevData) { + if ( + (prevData.status === 'reconnecting' || + (prevData.status === 'connecting' && + prevData.address === undefined)) && + data.status === 'connected' + ) { + const { address, addresses, chain, chainId, connector } = data + const isReconnected = + prevData.status === 'reconnecting' || + // if `previousAccount.status` is `undefined`, the connector connected immediately. + prevData.status === undefined + onConnect?.({ + address, + addresses, + chain, + chainId, + connector, + isReconnected, + }) + } else if ( + prevData.status === 'connected' && + data.status === 'disconnected' + ) + onDisconnect?.() + }, + }) + + onCleanup(() => unwatch()) + }) +} diff --git a/packages/vue/src/composables/useBalance.test-d.ts b/packages/vue/src/composables/useBalance.test-d.ts new file mode 100644 index 0000000000..44ba34ea48 --- /dev/null +++ b/packages/vue/src/composables/useBalance.test-d.ts @@ -0,0 +1,15 @@ +import { expectTypeOf, test } from 'vitest' +import type { Ref } from 'vue' + +import { useBalance } from './useBalance.js' + +test('select data', () => { + const result = useBalance({ + query: { + select(data) { + return data?.value + }, + }, + }) + expectTypeOf(result.data).toEqualTypeOf | Ref>() +}) diff --git a/packages/vue/src/composables/useBalance.test.ts b/packages/vue/src/composables/useBalance.test.ts new file mode 100644 index 0000000000..cf2662d302 --- /dev/null +++ b/packages/vue/src/composables/useBalance.test.ts @@ -0,0 +1,119 @@ +import { accounts, chain, testClient, wait } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { parseEther } from 'viem' +import { beforeEach, expect, test } from 'vitest' + +import { ref } from 'vue' +import { useBalance } from './useBalance.js' + +const address = accounts[0] + +beforeEach(async () => { + await testClient.mainnet.setBalance({ address, value: parseEther('10000') }) + await testClient.mainnet.mine({ blocks: 1 }) + await testClient.mainnet2.setBalance({ address, value: parseEther('69') }) + await testClient.mainnet2.mine({ blocks: 1 }) +}) + +test('default', async () => { + const [query] = renderComposable(() => useBalance({ address })) + + await waitFor(query.isSuccess) + + expect(query.data.value).toMatchObject( + expect.objectContaining({ + decimals: expect.any(Number), + formatted: expect.any(String), + symbol: expect.any(String), + value: expect.any(BigInt), + }), + ) +}) + +test('parameters: chainId', async () => { + const [query] = renderComposable(() => + useBalance({ address, chainId: chain.mainnet2.id }), + ) + + await waitFor(query.isSuccess) + + expect(query.data.value).toMatchInlineSnapshot(` + { + "decimals": 18, + "formatted": "69", + "symbol": "WAG", + "value": 69000000000000000000n, + } + `) +}) + +test('parameters: token', async () => { + const [query] = renderComposable(() => + useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + token: '0x6B175474E89094C44Da98b954EedeAC495271d0F', + }), + ) + + await waitFor(query.isSuccess) + + expect(query.data.value).toMatchInlineSnapshot(` + { + "decimals": 18, + "formatted": "0.559062564299199392", + "symbol": "DAI", + "value": 559062564299199392n, + } + `) +}) + +test('parameters: unit', async () => { + const [query] = renderComposable(() => + useBalance({ + address, + chainId: chain.mainnet2.id, + unit: 'wei', + }), + ) + + await waitFor(query.isSuccess) + + expect(query.data.value).toMatchInlineSnapshot(` + { + "decimals": 18, + "formatted": "69000000000000000000", + "symbol": "WAG", + "value": 69000000000000000000n, + } + `) +}) + +test('behavior: address: undefined -> defined', async () => { + const address = ref() + + const [query] = renderComposable(() => useBalance({ address })) + + await wait(100) + expect(query.fetchStatus.value).toMatchInlineSnapshot(`"idle"`) + + address.value = accounts[0] + + await waitFor(query.isSuccess) + + expect(query.data.value).toMatchInlineSnapshot(` + { + "decimals": 18, + "formatted": "10000", + "symbol": "ETH", + "value": 10000000000000000000000n, + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const [query] = renderComposable(() => useBalance({ address })) + + await wait(100) + + expect(query.fetchStatus.value).toMatchInlineSnapshot(`"idle"`) +}) diff --git a/packages/vue/src/composables/useBalance.ts b/packages/vue/src/composables/useBalance.ts new file mode 100644 index 0000000000..1fdcdc9450 --- /dev/null +++ b/packages/vue/src/composables/useBalance.ts @@ -0,0 +1,65 @@ +import type { Config, GetBalanceErrorType, ResolvedRegister } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetBalanceData, + type GetBalanceOptions, + type GetBalanceQueryKey, + getBalanceQueryOptions, +} from '@wagmi/core/query' +import type { GetBalanceQueryFnData } from '@wagmi/core/query' + +import { computed } from 'vue' +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseBalanceParameters< + config extends Config = Config, + selectData = GetBalanceData, +> = Compute< + DeepMaybeRef< + GetBalanceOptions & + ConfigParameter & + QueryParameter< + GetBalanceQueryFnData, + GetBalanceErrorType, + selectData, + GetBalanceQueryKey + > + > +> + +export type UseBalanceReturnType = + UseQueryReturnType + +/** https://wagmi.sh/vue/api/composables/useBalance */ +export function useBalance< + config extends Config = ResolvedRegister['config'], + selectData = GetBalanceData, +>( + parameters_: UseBalanceParameters = {}, +): UseBalanceReturnType { + const parameters = computed(() => deepUnref(parameters_)) + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + + const queryOptions = computed(() => { + const { + address, + chainId = configChainId.value, + query = {}, + } = parameters.value + const options = getBalanceQueryOptions(config, { + ...parameters.value, + chainId, + }) + const enabled = Boolean(address && (query.enabled ?? true)) + return { ...query, ...options, enabled } + }) + + return useQuery(queryOptions as any) as UseBalanceReturnType +} diff --git a/packages/vue/src/composables/useBlockNumber.test-d.ts b/packages/vue/src/composables/useBlockNumber.test-d.ts new file mode 100644 index 0000000000..255a1e02e8 --- /dev/null +++ b/packages/vue/src/composables/useBlockNumber.test-d.ts @@ -0,0 +1,65 @@ +import { http, createConfig, webSocket } from '@wagmi/core' +import { mainnet, optimism } from '@wagmi/core/chains' +import { expectTypeOf, test } from 'vitest' + +import { useBlockNumber } from './useBlockNumber.js' + +test('select data', () => { + const result = useBlockNumber({ + query: { + select(data) { + expectTypeOf(data).toEqualTypeOf() + return data?.toString() + }, + }, + }) + expectTypeOf(result.data.value).toEqualTypeOf() +}) + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + useBlockNumber({ + config, + watch: { + poll: false, + }, + }) + + useBlockNumber({ + config, + chainId: mainnet.id, + watch: { + poll: true, + }, + }) + useBlockNumber({ + config, + chainId: mainnet.id, + watch: { + // @ts-expect-error + poll: false, + }, + }) + + useBlockNumber({ + config, + chainId: optimism.id, + watch: { + poll: true, + }, + }) + useBlockNumber({ + config, + chainId: optimism.id, + watch: { + poll: false, + }, + }) +}) diff --git a/packages/vue/src/composables/useBlockNumber.test.ts b/packages/vue/src/composables/useBlockNumber.test.ts new file mode 100644 index 0000000000..68e7e6241c --- /dev/null +++ b/packages/vue/src/composables/useBlockNumber.test.ts @@ -0,0 +1,65 @@ +import { config, testClient } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' +import { ref } from 'vue' +import { useBlockNumber } from './useBlockNumber.js' + +test('default', async () => { + await testClient.mainnet.resetFork() + + const [blockNumberQuery] = renderComposable(() => useBlockNumber()) + + await waitFor(blockNumberQuery.status, (status) => status === 'success') + + expect(blockNumberQuery.data.value).toMatchInlineSnapshot('19258213n') +}) + +test('parameters: chainId', async () => { + config.setState((state) => ({ ...state, chainId: config.chains[0].id })) + + const [blockNumberQuery] = renderComposable(() => useBlockNumber()) + + await waitFor(blockNumberQuery.status, (status) => status === 'success') + expect(blockNumberQuery.data.value).toBeTypeOf('bigint') + + config.setState((state) => ({ ...state, chainId: config.chains[2].id })) + + await waitFor(blockNumberQuery.status, (status) => status === 'success') + expect(blockNumberQuery.data.value).toBeTypeOf('bigint') +}) + +test('parameters: watch', async () => { + const [blockNumberQuery] = renderComposable(() => + useBlockNumber({ watch: true }), + ) + + await waitFor(blockNumberQuery.status, (status) => status === 'success') + + const blockNumber = blockNumberQuery.data.value! + await testClient.mainnet.mine({ blocks: 1 }) + + await waitFor(blockNumberQuery.data, (data) => data === blockNumber + 1n) +}) + +test('parameters: watch (reactive)', async () => { + const watch = ref(true) + + const [blockNumberQuery] = renderComposable(() => useBlockNumber({ watch })) + + await waitFor(blockNumberQuery.status, (status) => status === 'success') + + const blockNumber = blockNumberQuery.data.value! + + await testClient.mainnet.mine({ blocks: 1 }) + await waitFor(blockNumberQuery.data, (data) => data === blockNumber + 1n) + + await testClient.mainnet.mine({ blocks: 1 }) + await waitFor(blockNumberQuery.data, (data) => data === blockNumber + 2n) + + watch.value = false + + await testClient.mainnet.mine({ blocks: 1 }) + await waitFor(blockNumberQuery.data, (data) => data === blockNumber + 2n, { + timeout: 1_000, + }) +}) diff --git a/packages/vue/src/composables/useBlockNumber.ts b/packages/vue/src/composables/useBlockNumber.ts new file mode 100644 index 0000000000..aadf04fb25 --- /dev/null +++ b/packages/vue/src/composables/useBlockNumber.ts @@ -0,0 +1,120 @@ +import { useQueryClient } from '@tanstack/vue-query' +import type { + Config, + GetBlockNumberErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { + Compute, + UnionCompute, + UnionStrictOmit, +} from '@wagmi/core/internal' +import { + type GetBlockNumberData, + type GetBlockNumberOptions, + type GetBlockNumberQueryFnData, + type GetBlockNumberQueryKey, + getBlockNumberQueryOptions, +} from '@wagmi/core/query' +import { computed } from 'vue' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import type { DeepMaybeRef, DeepUnwrapRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' +import { + type UseWatchBlockNumberParameters, + useWatchBlockNumber, +} from './useWatchBlockNumber.js' + +export type UseBlockNumberParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetBlockNumberData, +> = Compute< + DeepMaybeRef< + GetBlockNumberOptions & + ConfigParameter & + QueryParameter< + GetBlockNumberQueryFnData, + GetBlockNumberErrorType, + selectData, + GetBlockNumberQueryKey + > & { + watch?: + | boolean + | UnionCompute< + UnionStrictOmit< + DeepUnwrapRef>, + 'chainId' | 'config' | 'onBlockNumber' | 'onError' + > + > + | undefined + } + > +> + +export type UseBlockNumberReturnType = + UseQueryReturnType + +/** https://wagmi.sh/vue/api/composables/useBlockNumber */ +export function useBlockNumber< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetBlockNumberData, +>( + parameters_: UseBlockNumberParameters = {}, +): UseBlockNumberReturnType { + const parameters = computed(() => deepUnref(parameters_)) + + const config = useConfig(parameters) + const queryClient = useQueryClient() + const configChainId = useChainId({ config }) + + const queryOptions = computed(() => { + const { + chainId = configChainId.value, + query = {}, + watch: _, + ...rest + } = parameters.value + const options = getBlockNumberQueryOptions(config, { + ...deepUnref(rest), + chainId, + }) + return { + ...query, + ...options, + } + }) + + const watchBlockNumberArgs = computed(() => { + const { + config, + chainId = configChainId.value, + query, + watch, + } = parameters.value + return { + ...({ + config, + chainId, + ...(typeof watch === 'object' ? watch : {}), + } as UseWatchBlockNumberParameters), + enabled: + (query?.enabled ?? true) && + (typeof watch === 'object' ? watch.enabled : watch), + onBlockNumber(blockNumber) { + queryClient.setQueryData(queryOptions.value.queryKey, blockNumber) + }, + } satisfies UseWatchBlockNumberParameters + }) + + useWatchBlockNumber(watchBlockNumberArgs) + + return useQuery(queryOptions as any) as UseBlockNumberReturnType +} diff --git a/packages/vue/src/composables/useBytecode.test-d.ts b/packages/vue/src/composables/useBytecode.test-d.ts new file mode 100644 index 0000000000..16fb3a36ff --- /dev/null +++ b/packages/vue/src/composables/useBytecode.test-d.ts @@ -0,0 +1,16 @@ +import type { Hex } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { useBytecode } from './useBytecode.js' + +test('select data', () => { + const result = useBytecode({ + query: { + select(data) { + expectTypeOf(data).toEqualTypeOf() + return data + }, + }, + }) + expectTypeOf(result.data.value).toEqualTypeOf() +}) diff --git a/packages/vue/src/composables/useBytecode.test.ts b/packages/vue/src/composables/useBytecode.test.ts new file mode 100644 index 0000000000..f98eccc8db --- /dev/null +++ b/packages/vue/src/composables/useBytecode.test.ts @@ -0,0 +1,296 @@ +import { address, chain, wait } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { ref } from 'vue' +import { deepUnref } from '../utils/cloneDeep.js' +import { useBytecode } from './useBytecode.js' + +test('default', async () => { + const [result] = renderComposable(() => + useBytecode({ + address: address.wagmiMintExample, + }), + ) + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": "0x608060405234801561001057600080fd5b50600436106101005760003560e01c80636352211e11610097578063a22cb46511610066578063a22cb46514610215578063b88d4fde14610228578063c87b56dd1461023b578063e985e9c51461024e57600080fd5b80636352211e146101d457806370a08231146101e757806395d89b41146101fa578063a0712d681461020257600080fd5b80631249c58b116100d35780631249c58b1461018f57806318160ddd1461019757806323b872dd146101ae57806342842e0e146101c157600080fd5b806301ffc9a71461010557806306fdde031461012d578063081812fc14610142578063095ea7b31461017a575b600080fd5b61011861011336600461178f565b610297565b60405190151581526020015b60405180910390f35b61013561037c565b6040516101249190611829565b61015561015036600461183c565b61040e565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610124565b61018d61018836600461187e565b6104d3565b005b61018d61062b565b6101a060065481565b604051908152602001610124565b61018d6101bc3660046118a8565b61067d565b61018d6101cf3660046118a8565b610704565b6101556101e236600461183c565b61071f565b6101a06101f53660046118e4565b6107b7565b61013561086b565b61018d61021036600461183c565b61087a565b61018d6102233660046118ff565b610902565b61018d61023636600461196a565b610911565b61013561024936600461183c565b61099f565b61011861025c366004611a64565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260056020908152604080832093909416825291909152205460ff1690565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f80ac58cd00000000000000000000000000000000000000000000000000000000148061032a57507fffffffff0000000000000000000000000000000000000000000000000000000082167f5b5e139f00000000000000000000000000000000000000000000000000000000145b8061037657507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b60606000805461038b90611a97565b80601f01602080910402602001604051908101604052809291908181526020018280546103b790611a97565b80156104045780601f106103d957610100808354040283529160200191610404565b820191906000526020600020905b8154815290600101906020018083116103e757829003601f168201915b5050505050905090565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff166104aa5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084015b60405180910390fd5b5060009081526004602052604090205473ffffffffffffffffffffffffffffffffffffffff1690565b60006104de8261071f565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16036105815760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f720000000000000000000000000000000000000000000000000000000000000060648201526084016104a1565b3373ffffffffffffffffffffffffffffffffffffffff821614806105aa57506105aa813361025c565b61061c5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c000000000000000060648201526084016104a1565b6106268383610b07565b505050565b6007545b60008181526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16156106615760010161062f565b61066b3382610ba7565b60068054600190810190915501600755565b6106873382610bc1565b6106f95760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f76656400000000000000000000000000000060648201526084016104a1565b610626838383610d17565b61062683838360405180602001604052806000815250610911565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff16806103765760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201527f656e7420746f6b656e000000000000000000000000000000000000000000000060648201526084016104a1565b600073ffffffffffffffffffffffffffffffffffffffff82166108425760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a6560448201527f726f20616464726573730000000000000000000000000000000000000000000060648201526084016104a1565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526003602052604090205490565b60606001805461038b90611a97565b60008181526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16156108ec5760405162461bcd60e51b815260206004820152601160248201527f546f6b656e2049442069732074616b656e00000000000000000000000000000060448201526064016104a1565b6108f63382610ba7565b50600680546001019055565b61090d338383610f4a565b5050565b61091b3383610bc1565b61098d5760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f76656400000000000000000000000000000060648201526084016104a1565b6109998484848461105d565b50505050565b6040517f666f726567726f756e64000000000000000000000000000000000000000000006020820152602a810182905260609060009061016890604a016040516020818303038152906040528051906020012060001c6109ff9190611b19565b6040517f6261636b67726f756e64000000000000000000000000000000000000000000006020820152602a810185905290915060009061016890604a016040516020818303038152906040528051906020012060001c610a5f9190611b19565b90506000610aba610a6f866110e6565b610aa9610a7b866110e6565b610a84866110e6565b604051602001610a95929190611b2d565b60405160208183030381529060405261121b565b604051602001610a959291906125ba565b9050600081604051602001610acf919061268b565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190529695505050505050565b600081815260046020526040902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84169081179091558190610b618261071f565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b61090d82826040518060200160405280600081525061136e565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff16610c585760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084016104a1565b6000610c638361071f565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161480610cd1575073ffffffffffffffffffffffffffffffffffffffff80821660009081526005602090815260408083209388168352929052205460ff165b80610d0f57508373ffffffffffffffffffffffffffffffffffffffff16610cf78461040e565b73ffffffffffffffffffffffffffffffffffffffff16145b949350505050565b8273ffffffffffffffffffffffffffffffffffffffff16610d378261071f565b73ffffffffffffffffffffffffffffffffffffffff1614610dc05760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201527f6f776e657200000000000000000000000000000000000000000000000000000060648201526084016104a1565b73ffffffffffffffffffffffffffffffffffffffff8216610e485760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f726573730000000000000000000000000000000000000000000000000000000060648201526084016104a1565b610e53600082610b07565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600360205260408120805460019290610e899084906126ff565b909155505073ffffffffffffffffffffffffffffffffffffffff82166000908152600360205260408120805460019290610ec4908490612716565b909155505060008181526002602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff86811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603610fc55760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c65720000000000000060448201526064016104a1565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526005602090815260408083209487168084529482529182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b611068848484610d17565b611074848484846113f7565b6109995760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e746572000000000000000000000000000060648201526084016104a1565b60608160000361112957505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b8115611153578061113d8161272e565b915061114c9050600a83612766565b915061112d565b60008167ffffffffffffffff81111561116e5761116e61193b565b6040519080825280601f01601f191660200182016040528015611198576020820181803683370190505b5090505b8415610d0f576111ad6001836126ff565b91506111ba600a86611b19565b6111c5906030612716565b60f81b8183815181106111da576111da61277a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611214600a86612766565b945061119c565b6060815160000361123a57505060408051602081019091526000815290565b600060405180606001604052806040815260200161284d60409139905060006003845160026112699190612716565b6112739190612766565b61127e9060046127a9565b67ffffffffffffffff8111156112965761129661193b565b6040519080825280601f01601f1916602001820160405280156112c0576020820181803683370190505b509050600182016020820185865187015b8082101561132c576003820191508151603f8160121c168501518453600184019350603f81600c1c168501518453600184019350603f8160061c168501518453600184019350603f81168501518453506001830192506112d1565b5050600386510660018114611348576002811461135b57611363565b603d6001830353603d6002830353611363565b603d60018303535b509195945050505050565b61137883836115d0565b61138560008484846113f7565b6106265760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e746572000000000000000000000000000060648201526084016104a1565b600073ffffffffffffffffffffffffffffffffffffffff84163b156115c5576040517f150b7a0200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85169063150b7a029061146e9033908990889088906004016127e6565b6020604051808303816000875af19250505080156114c7575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092526114c49181019061282f565b60015b61157a573d8080156114f5576040519150601f19603f3d011682016040523d82523d6000602084013e6114fa565b606091505b5080516000036115725760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e746572000000000000000000000000000060648201526084016104a1565b805181602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000167f150b7a0200000000000000000000000000000000000000000000000000000000149050610d0f565b506001949350505050565b73ffffffffffffffffffffffffffffffffffffffff82166116335760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016104a1565b60008181526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16156116a55760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060448201526064016104a1565b73ffffffffffffffffffffffffffffffffffffffff821660009081526003602052604081208054600192906116db908490612716565b909155505060008181526002602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b7fffffffff000000000000000000000000000000000000000000000000000000008116811461178c57600080fd5b50565b6000602082840312156117a157600080fd5b81356117ac8161175e565b9392505050565b60005b838110156117ce5781810151838201526020016117b6565b838111156109995750506000910152565b600081518084526117f78160208601602086016117b3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006117ac60208301846117df565b60006020828403121561184e57600080fd5b5035919050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461187957600080fd5b919050565b6000806040838503121561189157600080fd5b61189a83611855565b946020939093013593505050565b6000806000606084860312156118bd57600080fd5b6118c684611855565b92506118d460208501611855565b9150604084013590509250925092565b6000602082840312156118f657600080fd5b6117ac82611855565b6000806040838503121561191257600080fd5b61191b83611855565b91506020830135801515811461193057600080fd5b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000806000806080858703121561198057600080fd5b61198985611855565b935061199760208601611855565b925060408501359150606085013567ffffffffffffffff808211156119bb57600080fd5b818701915087601f8301126119cf57600080fd5b8135818111156119e1576119e161193b565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715611a2757611a2761193b565b816040528281528a6020848701011115611a4057600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215611a7757600080fd5b611a8083611855565b9150611a8e60208401611855565b90509250929050565b600181811c90821680611aab57607f821691505b602082108103611ae4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082611b2857611b28611aea565b500690565b7f3c73766720786d6c6e733d22687474703a2f2f7777772e77332e6f72672f323081527f30302f737667222077696474683d223130323422206865696768743d2231303260208201527f34222066696c6c3d226e6f6e65223e3c706174682066696c6c3d2268736c2800604082015260008351611bb181605f8501602088016117b3565b7f2c20313030252c20313025292220643d224d3020306831303234763130323448605f918401918201527f307a22202f3e3c672066696c6c3d2268736c2800000000000000000000000000607f8201528351611c148160928401602088016117b3565b7f2c20313030252c2039302529223e3c7061746820643d224d393033203433372e609292909101918201527f35633020392e3131332d372e3338382031362e352d31362e352031362e35732d60b28201527f31362e352d372e3338372d31362e352d31362e3520372e3338382d31362e352060d28201527f31362e352d31362e352031362e3520372e3338372031362e352031362e357a4d60f28201527f3639382e3532392035363663362e39323120302031322e35332d352e353936206101128201527f31322e35332d31322e35762d353063302d362e39303420352e3630392d31322e6101328201527f352031322e3532392d31322e356832352e30353963362e393220302031322e356101528201527f323920352e3539362031322e3532392031322e35763530633020362e393034206101728201527f352e3630392031322e352031322e35332031322e357331322e3532392d352e356101928201527f39362031322e3532392d31322e35762d353063302d362e39303420352e3630396101b28201527f2d31322e352031322e35332d31322e356832352e30353963362e3932203020316101d28201527f322e35323920352e3539362031322e3532392031322e35763530633020362e396101f28201527f303420352e3630392031322e352031322e3532392031322e356833372e3538396102128201527f63362e393220302031322e3532392d352e3539362031322e3532392d31322e356102328201527f762d373563302d362e3930342d352e3630392d31322e352d31322e3532392d316102528201527f322e35732d31322e353320352e3539362d31322e35332031322e357635362e326102728201527f3561362e32363420362e3236342030203120312d31322e3532392030563437386102928201527f2e3563302d362e3930342d352e3630392d31322e352d31322e35332d31322e356102b28201527f483639382e353239632d362e393220302d31322e35323920352e3539362d31326102d28201527f2e3532392031322e35763735633020362e39303420352e3630392031322e35206102f28201527f31322e3532392031322e357a22202f3e3c7061746820643d224d3135372e36356103128201527f3520353431632d362e39333220302d31322e3535322d352e3539362d31322e356103328201527f35322d31322e35762d353063302d362e3930342d352e3631392d31322e352d316103528201527f322e3535312d31322e3553313230203437312e35393620313230203437382e356103728201527f763735633020362e39303420352e36322031322e352031322e3535322031322e6103928201527f35683135302e363263362e39333320302031322e3535322d352e3539362031326103b28201527f2e3535322d31322e35762d353063302d362e39303420352e3631392d31322e356103d28201527f2031322e3535322d31322e35683134342e33343563332e343635203020362e326103f28201527f373620322e37393820362e32373620362e3235732d322e38313120362e32352d6104128201527f362e32373620362e3235483332302e383238632d362e39333320302d31322e356104328201527f353220352e3539362d31322e3535322031322e357633372e35633020362e39306104528201527f3420352e3631392031322e352031322e3535322031322e35683135302e3632636104728201527f362e39333320302031322e3535322d352e3539362031322e3535322d31322e356104928201527f762d373563302d362e3930342d352e3631392d31322e352d31322e3535322d316104b28201527f322e35483238332e313732632d362e39333220302d31322e35353120352e35396104d28201527f362d31322e3535312031322e35763530633020362e3930342d352e36313920316104f28201527f322e352d31322e3535322031322e35682d32352e313033632d362e39333320306105128201527f2d31322e3535322d352e3539362d31322e3535322d31322e35762d353063302d6105328201527f362e3930342d352e36322d31322e352d31322e3535322d31322e35732d31322e6105528201527f35353220352e3539362d31322e3535322031322e35763530633020362e3930346105728201527f2d352e3631392031322e352d31322e3535312031322e35682d32352e3130347a6105928201527f6d3330312e3234322d362e3235633020332e3435322d322e38313120362e32356105b28201527f2d362e32373620362e3235483333392e363535632d332e34363520302d362e326105d28201527f37362d322e3739382d362e3237362d362e323573322e3831312d362e323520366105f28201527f2e3237362d362e3235683131322e39363663332e343635203020362e323736206106128201527f322e37393820362e32373620362e32357a4d343937203535332e3831386330206106328201527f362e39323920352e3632382031322e3534362031322e3537312031322e3534366106528201527f6831333261362e323820362e323820302030203120362e32383620362e3237326106728201527f20362e323820362e32382030203020312d362e32383620362e323733682d31336106928201527f32632d362e39343320302d31322e35373120352e3631362d31322e35373120316106b28201527f322e3534364131322e35362031322e3536203020302030203530392e353731206106d28201527f363034683135302e38353863362e39343320302031322e3537312d352e3631366106f28201527f2031322e3537312d31322e353435762d3131322e393163302d362e3932382d356107128201527f2e3632382d31322e3534352d31322e3537312d31322e353435483530392e35376107328201527f31632d362e39343320302d31322e35373120352e3631372d31322e35373120316107528201527f322e3534357637352e3237337a6d33372e3731342d36322e373237632d362e396107728201527f343320302d31322e35373120352e3631372d31322e3537312031322e353435766107928201527f32352e303931633020362e39323920352e3632382031322e3534362031322e356107b28201527f37312031322e353436683130302e35373263362e39343320302031322e3537316107d28201527f2d352e3631372031322e3537312d31322e353436762d32352e30393163302d366107f28201527f2e3932382d352e3632382d31322e3534352d31322e3537312d31322e353435486108128201527f3533342e3731347a222066696c6c2d72756c653d226576656e6f646422202f3e6108328201527f3c2f673e3c2f7376673e0000000000000000000000000000000000000000000061085282015261085c01949350505050565b7f7b226e616d65223a20227761676d6920230000000000000000000000000000008152600083516125f28160118501602088016117b3565b7f222c2022696d616765223a2022646174613a696d6167652f7376672b786d6c3b6011918401918201527f6261736536342c00000000000000000000000000000000000000000000000000603182015283516126558160388401602088016117b3565b7f227d00000000000000000000000000000000000000000000000000000000000060389290910191820152603a01949350505050565b7f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c0000008152600082516126c381601d8501602087016117b3565b91909101601d0192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082821015612711576127116126d0565b500390565b60008219821115612729576127296126d0565b500190565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361275f5761275f6126d0565b5060010190565b60008261277557612775611aea565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156127e1576127e16126d0565b500290565b600073ffffffffffffffffffffffffffffffffffffffff80871683528086166020840152508360408301526080606083015261282560808301846117df565b9695505050505050565b60006020828403121561284157600080fd5b81516117ac8161175e56fe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa26469706673582212201665a4f9111990d7529375848d3fd02c0121091a940da59e763eba826e7b077064736f6c634300080d0033", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) + +test('parameters: blockNumber', async () => { + const [result] = renderComposable(() => + useBytecode({ + address: address.wagmiMintExample, + blockNumber: 15564163n, + }), + ) + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": null, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "blockNumber": 15564163n, + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) + +test('parameters: blockTag', async () => { + const [result] = renderComposable(() => + useBytecode({ + address: address.wagmiMintExample, + blockTag: 'earliest', + }), + ) + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": null, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "blockTag": "earliest", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) + +test('parameters: chainId', async () => { + const [result] = renderComposable(() => + useBytecode({ + address: address.wagmiMintExample, + chainId: chain.optimism.id, + }), + ) + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": null, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getBytecode", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "chainId": 10, + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) + +test('behavior: address: undefined -> defined', async () => { + const contractAddress = ref() + + const [result] = renderComposable(() => + useBytecode({ address: contractAddress }), + ) + + await wait(100) + expect(result.fetchStatus.value).toBe('idle') + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "getBytecode", + { + "address": undefined, + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "pending", + "suspense": [Function], + } + `) + + contractAddress.value = address.wagmiMintExample + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": "0x608060405234801561001057600080fd5b50600436106101005760003560e01c80636352211e11610097578063a22cb46511610066578063a22cb46514610215578063b88d4fde14610228578063c87b56dd1461023b578063e985e9c51461024e57600080fd5b80636352211e146101d457806370a08231146101e757806395d89b41146101fa578063a0712d681461020257600080fd5b80631249c58b116100d35780631249c58b1461018f57806318160ddd1461019757806323b872dd146101ae57806342842e0e146101c157600080fd5b806301ffc9a71461010557806306fdde031461012d578063081812fc14610142578063095ea7b31461017a575b600080fd5b61011861011336600461178f565b610297565b60405190151581526020015b60405180910390f35b61013561037c565b6040516101249190611829565b61015561015036600461183c565b61040e565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610124565b61018d61018836600461187e565b6104d3565b005b61018d61062b565b6101a060065481565b604051908152602001610124565b61018d6101bc3660046118a8565b61067d565b61018d6101cf3660046118a8565b610704565b6101556101e236600461183c565b61071f565b6101a06101f53660046118e4565b6107b7565b61013561086b565b61018d61021036600461183c565b61087a565b61018d6102233660046118ff565b610902565b61018d61023636600461196a565b610911565b61013561024936600461183c565b61099f565b61011861025c366004611a64565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260056020908152604080832093909416825291909152205460ff1690565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f80ac58cd00000000000000000000000000000000000000000000000000000000148061032a57507fffffffff0000000000000000000000000000000000000000000000000000000082167f5b5e139f00000000000000000000000000000000000000000000000000000000145b8061037657507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b60606000805461038b90611a97565b80601f01602080910402602001604051908101604052809291908181526020018280546103b790611a97565b80156104045780601f106103d957610100808354040283529160200191610404565b820191906000526020600020905b8154815290600101906020018083116103e757829003601f168201915b5050505050905090565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff166104aa5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084015b60405180910390fd5b5060009081526004602052604090205473ffffffffffffffffffffffffffffffffffffffff1690565b60006104de8261071f565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16036105815760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f720000000000000000000000000000000000000000000000000000000000000060648201526084016104a1565b3373ffffffffffffffffffffffffffffffffffffffff821614806105aa57506105aa813361025c565b61061c5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c000000000000000060648201526084016104a1565b6106268383610b07565b505050565b6007545b60008181526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16156106615760010161062f565b61066b3382610ba7565b60068054600190810190915501600755565b6106873382610bc1565b6106f95760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f76656400000000000000000000000000000060648201526084016104a1565b610626838383610d17565b61062683838360405180602001604052806000815250610911565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff16806103765760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201527f656e7420746f6b656e000000000000000000000000000000000000000000000060648201526084016104a1565b600073ffffffffffffffffffffffffffffffffffffffff82166108425760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a6560448201527f726f20616464726573730000000000000000000000000000000000000000000060648201526084016104a1565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526003602052604090205490565b60606001805461038b90611a97565b60008181526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16156108ec5760405162461bcd60e51b815260206004820152601160248201527f546f6b656e2049442069732074616b656e00000000000000000000000000000060448201526064016104a1565b6108f63382610ba7565b50600680546001019055565b61090d338383610f4a565b5050565b61091b3383610bc1565b61098d5760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f76656400000000000000000000000000000060648201526084016104a1565b6109998484848461105d565b50505050565b6040517f666f726567726f756e64000000000000000000000000000000000000000000006020820152602a810182905260609060009061016890604a016040516020818303038152906040528051906020012060001c6109ff9190611b19565b6040517f6261636b67726f756e64000000000000000000000000000000000000000000006020820152602a810185905290915060009061016890604a016040516020818303038152906040528051906020012060001c610a5f9190611b19565b90506000610aba610a6f866110e6565b610aa9610a7b866110e6565b610a84866110e6565b604051602001610a95929190611b2d565b60405160208183030381529060405261121b565b604051602001610a959291906125ba565b9050600081604051602001610acf919061268b565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190529695505050505050565b600081815260046020526040902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84169081179091558190610b618261071f565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b61090d82826040518060200160405280600081525061136e565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff16610c585760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084016104a1565b6000610c638361071f565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161480610cd1575073ffffffffffffffffffffffffffffffffffffffff80821660009081526005602090815260408083209388168352929052205460ff165b80610d0f57508373ffffffffffffffffffffffffffffffffffffffff16610cf78461040e565b73ffffffffffffffffffffffffffffffffffffffff16145b949350505050565b8273ffffffffffffffffffffffffffffffffffffffff16610d378261071f565b73ffffffffffffffffffffffffffffffffffffffff1614610dc05760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201527f6f776e657200000000000000000000000000000000000000000000000000000060648201526084016104a1565b73ffffffffffffffffffffffffffffffffffffffff8216610e485760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f726573730000000000000000000000000000000000000000000000000000000060648201526084016104a1565b610e53600082610b07565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600360205260408120805460019290610e899084906126ff565b909155505073ffffffffffffffffffffffffffffffffffffffff82166000908152600360205260408120805460019290610ec4908490612716565b909155505060008181526002602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff86811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603610fc55760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c65720000000000000060448201526064016104a1565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526005602090815260408083209487168084529482529182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b611068848484610d17565b611074848484846113f7565b6109995760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e746572000000000000000000000000000060648201526084016104a1565b60608160000361112957505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b8115611153578061113d8161272e565b915061114c9050600a83612766565b915061112d565b60008167ffffffffffffffff81111561116e5761116e61193b565b6040519080825280601f01601f191660200182016040528015611198576020820181803683370190505b5090505b8415610d0f576111ad6001836126ff565b91506111ba600a86611b19565b6111c5906030612716565b60f81b8183815181106111da576111da61277a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611214600a86612766565b945061119c565b6060815160000361123a57505060408051602081019091526000815290565b600060405180606001604052806040815260200161284d60409139905060006003845160026112699190612716565b6112739190612766565b61127e9060046127a9565b67ffffffffffffffff8111156112965761129661193b565b6040519080825280601f01601f1916602001820160405280156112c0576020820181803683370190505b509050600182016020820185865187015b8082101561132c576003820191508151603f8160121c168501518453600184019350603f81600c1c168501518453600184019350603f8160061c168501518453600184019350603f81168501518453506001830192506112d1565b5050600386510660018114611348576002811461135b57611363565b603d6001830353603d6002830353611363565b603d60018303535b509195945050505050565b61137883836115d0565b61138560008484846113f7565b6106265760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e746572000000000000000000000000000060648201526084016104a1565b600073ffffffffffffffffffffffffffffffffffffffff84163b156115c5576040517f150b7a0200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85169063150b7a029061146e9033908990889088906004016127e6565b6020604051808303816000875af19250505080156114c7575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092526114c49181019061282f565b60015b61157a573d8080156114f5576040519150601f19603f3d011682016040523d82523d6000602084013e6114fa565b606091505b5080516000036115725760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e746572000000000000000000000000000060648201526084016104a1565b805181602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000167f150b7a0200000000000000000000000000000000000000000000000000000000149050610d0f565b506001949350505050565b73ffffffffffffffffffffffffffffffffffffffff82166116335760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016104a1565b60008181526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16156116a55760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060448201526064016104a1565b73ffffffffffffffffffffffffffffffffffffffff821660009081526003602052604081208054600192906116db908490612716565b909155505060008181526002602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b7fffffffff000000000000000000000000000000000000000000000000000000008116811461178c57600080fd5b50565b6000602082840312156117a157600080fd5b81356117ac8161175e565b9392505050565b60005b838110156117ce5781810151838201526020016117b6565b838111156109995750506000910152565b600081518084526117f78160208601602086016117b3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006117ac60208301846117df565b60006020828403121561184e57600080fd5b5035919050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461187957600080fd5b919050565b6000806040838503121561189157600080fd5b61189a83611855565b946020939093013593505050565b6000806000606084860312156118bd57600080fd5b6118c684611855565b92506118d460208501611855565b9150604084013590509250925092565b6000602082840312156118f657600080fd5b6117ac82611855565b6000806040838503121561191257600080fd5b61191b83611855565b91506020830135801515811461193057600080fd5b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000806000806080858703121561198057600080fd5b61198985611855565b935061199760208601611855565b925060408501359150606085013567ffffffffffffffff808211156119bb57600080fd5b818701915087601f8301126119cf57600080fd5b8135818111156119e1576119e161193b565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715611a2757611a2761193b565b816040528281528a6020848701011115611a4057600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215611a7757600080fd5b611a8083611855565b9150611a8e60208401611855565b90509250929050565b600181811c90821680611aab57607f821691505b602082108103611ae4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082611b2857611b28611aea565b500690565b7f3c73766720786d6c6e733d22687474703a2f2f7777772e77332e6f72672f323081527f30302f737667222077696474683d223130323422206865696768743d2231303260208201527f34222066696c6c3d226e6f6e65223e3c706174682066696c6c3d2268736c2800604082015260008351611bb181605f8501602088016117b3565b7f2c20313030252c20313025292220643d224d3020306831303234763130323448605f918401918201527f307a22202f3e3c672066696c6c3d2268736c2800000000000000000000000000607f8201528351611c148160928401602088016117b3565b7f2c20313030252c2039302529223e3c7061746820643d224d393033203433372e609292909101918201527f35633020392e3131332d372e3338382031362e352d31362e352031362e35732d60b28201527f31362e352d372e3338372d31362e352d31362e3520372e3338382d31362e352060d28201527f31362e352d31362e352031362e3520372e3338372031362e352031362e357a4d60f28201527f3639382e3532392035363663362e39323120302031322e35332d352e353936206101128201527f31322e35332d31322e35762d353063302d362e39303420352e3630392d31322e6101328201527f352031322e3532392d31322e356832352e30353963362e393220302031322e356101528201527f323920352e3539362031322e3532392031322e35763530633020362e393034206101728201527f352e3630392031322e352031322e35332031322e357331322e3532392d352e356101928201527f39362031322e3532392d31322e35762d353063302d362e39303420352e3630396101b28201527f2d31322e352031322e35332d31322e356832352e30353963362e3932203020316101d28201527f322e35323920352e3539362031322e3532392031322e35763530633020362e396101f28201527f303420352e3630392031322e352031322e3532392031322e356833372e3538396102128201527f63362e393220302031322e3532392d352e3539362031322e3532392d31322e356102328201527f762d373563302d362e3930342d352e3630392d31322e352d31322e3532392d316102528201527f322e35732d31322e353320352e3539362d31322e35332031322e357635362e326102728201527f3561362e32363420362e3236342030203120312d31322e3532392030563437386102928201527f2e3563302d362e3930342d352e3630392d31322e352d31322e35332d31322e356102b28201527f483639382e353239632d362e393220302d31322e35323920352e3539362d31326102d28201527f2e3532392031322e35763735633020362e39303420352e3630392031322e35206102f28201527f31322e3532392031322e357a22202f3e3c7061746820643d224d3135372e36356103128201527f3520353431632d362e39333220302d31322e3535322d352e3539362d31322e356103328201527f35322d31322e35762d353063302d362e3930342d352e3631392d31322e352d316103528201527f322e3535312d31322e3553313230203437312e35393620313230203437382e356103728201527f763735633020362e39303420352e36322031322e352031322e3535322031322e6103928201527f35683135302e363263362e39333320302031322e3535322d352e3539362031326103b28201527f2e3535322d31322e35762d353063302d362e39303420352e3631392d31322e356103d28201527f2031322e3535322d31322e35683134342e33343563332e343635203020362e326103f28201527f373620322e37393820362e32373620362e3235732d322e38313120362e32352d6104128201527f362e32373620362e3235483332302e383238632d362e39333320302d31322e356104328201527f353220352e3539362d31322e3535322031322e357633372e35633020362e39306104528201527f3420352e3631392031322e352031322e3535322031322e35683135302e3632636104728201527f362e39333320302031322e3535322d352e3539362031322e3535322d31322e356104928201527f762d373563302d362e3930342d352e3631392d31322e352d31322e3535322d316104b28201527f322e35483238332e313732632d362e39333220302d31322e35353120352e35396104d28201527f362d31322e3535312031322e35763530633020362e3930342d352e36313920316104f28201527f322e352d31322e3535322031322e35682d32352e313033632d362e39333320306105128201527f2d31322e3535322d352e3539362d31322e3535322d31322e35762d353063302d6105328201527f362e3930342d352e36322d31322e352d31322e3535322d31322e35732d31322e6105528201527f35353220352e3539362d31322e3535322031322e35763530633020362e3930346105728201527f2d352e3631392031322e352d31322e3535312031322e35682d32352e3130347a6105928201527f6d3330312e3234322d362e3235633020332e3435322d322e38313120362e32356105b28201527f2d362e32373620362e3235483333392e363535632d332e34363520302d362e326105d28201527f37362d322e3739382d362e3237362d362e323573322e3831312d362e323520366105f28201527f2e3237362d362e3235683131322e39363663332e343635203020362e323736206106128201527f322e37393820362e32373620362e32357a4d343937203535332e3831386330206106328201527f362e39323920352e3632382031322e3534362031322e3537312031322e3534366106528201527f6831333261362e323820362e323820302030203120362e32383620362e3237326106728201527f20362e323820362e32382030203020312d362e32383620362e323733682d31336106928201527f32632d362e39343320302d31322e35373120352e3631362d31322e35373120316106b28201527f322e3534364131322e35362031322e3536203020302030203530392e353731206106d28201527f363034683135302e38353863362e39343320302031322e3537312d352e3631366106f28201527f2031322e3537312d31322e353435762d3131322e393163302d362e3932382d356107128201527f2e3632382d31322e3534352d31322e3537312d31322e353435483530392e35376107328201527f31632d362e39343320302d31322e35373120352e3631372d31322e35373120316107528201527f322e3534357637352e3237337a6d33372e3731342d36322e373237632d362e396107728201527f343320302d31322e35373120352e3631372d31322e3537312031322e353435766107928201527f32352e303931633020362e39323920352e3632382031322e3534362031322e356107b28201527f37312031322e353436683130302e35373263362e39343320302031322e3537316107d28201527f2d352e3631372031322e3537312d31322e353436762d32352e30393163302d366107f28201527f2e3932382d352e3632382d31322e3534352d31322e3537312d31322e353435486108128201527f3533342e3731347a222066696c6c2d72756c653d226576656e6f646422202f3e6108328201527f3c2f673e3c2f7376673e0000000000000000000000000000000000000000000061085282015261085c01949350505050565b7f7b226e616d65223a20227761676d6920230000000000000000000000000000008152600083516125f28160118501602088016117b3565b7f222c2022696d616765223a2022646174613a696d6167652f7376672b786d6c3b6011918401918201527f6261736536342c00000000000000000000000000000000000000000000000000603182015283516126558160388401602088016117b3565b7f227d00000000000000000000000000000000000000000000000000000000000060389290910191820152603a01949350505050565b7f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c0000008152600082516126c381601d8501602087016117b3565b91909101601d0192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082821015612711576127116126d0565b500390565b60008219821115612729576127296126d0565b500190565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361275f5761275f6126d0565b5060010190565b60008261277557612775611aea565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156127e1576127e16126d0565b500290565b600073ffffffffffffffffffffffffffffffffffffffff80871683528086166020840152508360408301526080606083015261282560808301846117df565b9695505050505050565b60006020828403121561284157600080fd5b81516117ac8161175e56fe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa26469706673582212201665a4f9111990d7529375848d3fd02c0121091a940da59e763eba826e7b077064736f6c634300080d0033", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getBytecode", + { + "address": undefined, + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const [result] = renderComposable(() => useBytecode()) + + await wait(100) + expect(result.isPending.value).toBe(true) +}) diff --git a/packages/vue/src/composables/useBytecode.ts b/packages/vue/src/composables/useBytecode.ts new file mode 100644 index 0000000000..a697ff1a92 --- /dev/null +++ b/packages/vue/src/composables/useBytecode.ts @@ -0,0 +1,72 @@ +import type { + Config, + GetBytecodeErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetBytecodeData, + type GetBytecodeOptions, + type GetBytecodeQueryKey, + getBytecodeQueryOptions, +} from '@wagmi/core/query' +import type { GetBytecodeQueryFnData } from '@wagmi/core/query' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' + +import { computed } from 'vue' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseBytecodeParameters< + config extends Config = Config, + selectData = GetBytecodeData, +> = Compute< + DeepMaybeRef< + GetBytecodeOptions & + ConfigParameter & + QueryParameter< + GetBytecodeQueryFnData, + GetBytecodeErrorType, + selectData, + GetBytecodeQueryKey + > + > +> + +export type UseBytecodeReturnType = + UseQueryReturnType + +/** https://wagmi.sh/vue/api/hooks/useBytecode */ +export function useBytecode< + config extends Config = ResolvedRegister['config'], + selectData = GetBytecodeData, +>( + parameters_: UseBytecodeParameters = {}, +): UseBytecodeReturnType { + const parameters = computed(() => deepUnref(parameters_)) + + const config = useConfig(parameters) + const chainId = useChainId({ config }) + + const queryOptions = computed(() => { + const { + address: contractAddress, + chainId: parametersChainId, + query = {}, + } = parameters.value + + const options = getBytecodeQueryOptions(config, { + ...parameters.value, + address: contractAddress, + chainId: parametersChainId ?? chainId.value, + }) + const enabled = Boolean(contractAddress && (query.enabled ?? true)) + return { ...query, ...options, enabled } + }) + + return useQuery(queryOptions as any) as UseBytecodeReturnType +} diff --git a/packages/vue/src/composables/useChainId.test-d.ts b/packages/vue/src/composables/useChainId.test-d.ts new file mode 100644 index 0000000000..9f7d060c57 --- /dev/null +++ b/packages/vue/src/composables/useChainId.test-d.ts @@ -0,0 +1,14 @@ +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useChainId } from './useChainId.js' + +test('default', () => { + const chainId = useChainId() + expectTypeOf(chainId.value).toEqualTypeOf() +}) + +test('parameters: config', () => { + const chainId = useChainId({ config }) + expectTypeOf(chainId.value).toEqualTypeOf<1 | 456 | 10>() +}) diff --git a/packages/vue/src/composables/useChainId.test.ts b/packages/vue/src/composables/useChainId.test.ts new file mode 100644 index 0000000000..0a14370fc2 --- /dev/null +++ b/packages/vue/src/composables/useChainId.test.ts @@ -0,0 +1,22 @@ +import { config } from '@wagmi/test' +import { renderComposable } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { useChainId } from './useChainId.js' + +test('default', () => { + const [chainId] = renderComposable(() => useChainId()) + + expect(chainId.value).toMatchInlineSnapshot('1') + + config.setState((x) => ({ ...x, chainId: 456 })) + + expect(chainId.value).toMatchInlineSnapshot('456') +}) + +test('parameters: config', () => { + const [chainId] = renderComposable(() => useChainId({ config }), { + attach() {}, + }) + expect(chainId.value).toBeDefined() +}) diff --git a/packages/vue/src/composables/useChainId.ts b/packages/vue/src/composables/useChainId.ts new file mode 100644 index 0000000000..f459857ca9 --- /dev/null +++ b/packages/vue/src/composables/useChainId.ts @@ -0,0 +1,35 @@ +import { + type Config, + type GetChainIdReturnType, + type ResolvedRegister, + getChainId, + watchChainId, +} from '@wagmi/core' +import { type Ref, onScopeDispose, readonly, ref } from 'vue' + +import type { ConfigParameter } from '../types/properties.js' +import { useConfig } from './useConfig.js' + +export type UseChainIdParameters = + ConfigParameter + +export type UseChainIdReturnType = Ref< + GetChainIdReturnType +> + +/** https://wagmi.sh/vue/api/composables/useChainId */ +export function useChainId( + parameters: UseChainIdParameters = {}, +): UseChainIdReturnType { + const config = useConfig(parameters) + + const chainId = ref(getChainId(config)) + const unsubscribe = watchChainId(config, { + onChange(data) { + chainId.value = data + }, + }) + onScopeDispose(() => unsubscribe()) + + return readonly(chainId) +} diff --git a/packages/vue/src/composables/useChains.test.ts b/packages/vue/src/composables/useChains.test.ts new file mode 100644 index 0000000000..4ef51405a9 --- /dev/null +++ b/packages/vue/src/composables/useChains.test.ts @@ -0,0 +1,16 @@ +import { config } from '@wagmi/test' +import { renderComposable } from '@wagmi/test/vue' +import { celo } from 'viem/chains' +import { expect, test } from 'vitest' + +import { useChains } from './useChains.js' + +test('default', async () => { + const [chains] = renderComposable(() => useChains()) + + expect(chains.value.length).toBe(3) + + config._internal.chains.setState((x) => [...x, celo]) + + expect(chains.value.length).toBe(4) +}) diff --git a/packages/vue/src/composables/useChains.ts b/packages/vue/src/composables/useChains.ts new file mode 100644 index 0000000000..6cbada538b --- /dev/null +++ b/packages/vue/src/composables/useChains.ts @@ -0,0 +1,35 @@ +import { + type Config, + type GetChainsReturnType, + type ResolvedRegister, + getChains, +} from '@wagmi/core' +import { watchChains } from '@wagmi/core/internal' + +import { type Ref, onScopeDispose, readonly, ref } from 'vue' +import type { ConfigParameter } from '../types/properties.js' +import { useConfig } from './useConfig.js' + +export type UseChainsParameters = + ConfigParameter + +export type UseChainsReturnType = Ref< + GetChainsReturnType +> + +/** https://wagmi.sh/vue/api/composables/useChains */ +export function useChains( + parameters: UseChainsParameters = {}, +): UseChainsReturnType { + const config = useConfig(parameters) + + const chains = ref>(getChains(config)) + const unsubscribe = watchChains(config, { + onChange(data) { + chains.value = data as any + }, + }) + onScopeDispose(() => unsubscribe()) + + return readonly(chains) as UseChainsReturnType +} diff --git a/packages/vue/src/composables/useClient.test-d.ts b/packages/vue/src/composables/useClient.test-d.ts new file mode 100644 index 0000000000..3500f2a404 --- /dev/null +++ b/packages/vue/src/composables/useClient.test-d.ts @@ -0,0 +1,42 @@ +import { chain, config } from '@wagmi/test' +import type { Chain } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { useClient } from './useClient.js' + +test('default', () => { + const client = useClient({ config }) + expectTypeOf(client.value.chain).toEqualTypeOf< + (typeof config)['chains'][number] + >() + expectTypeOf(client.value.transport.type).toEqualTypeOf<'http'>() +}) + +test('parameters: chainId', () => { + const client = useClient({ + config, + chainId: chain.mainnet.id, + }) + expectTypeOf(client.value.chain).toEqualTypeOf() + expectTypeOf(client.value.chain).not.toEqualTypeOf() + expectTypeOf(client.value.transport.type).toEqualTypeOf<'http'>() +}) + +test('behavior: unconfigured chain', () => { + { + const client = useClient({ chainId: 123456 }) + if (client.value) { + expectTypeOf(client.value.chain).toEqualTypeOf() + expectTypeOf(client.value.transport.type).toEqualTypeOf() + } else { + expectTypeOf(client.value).toEqualTypeOf() + } + } + + const client = useClient({ + config, + // @ts-expect-error + chainId: 123456, + }) + expectTypeOf(client.value).toEqualTypeOf() +}) diff --git a/packages/vue/src/composables/useClient.test.ts b/packages/vue/src/composables/useClient.test.ts new file mode 100644 index 0000000000..0d9d2325b2 --- /dev/null +++ b/packages/vue/src/composables/useClient.test.ts @@ -0,0 +1,41 @@ +import { switchChain } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' +import { ref } from 'vue' + +import { useClient } from './useClient.js' + +test('default', async () => { + const [client] = renderComposable(() => useClient()) + + expect(client?.value?.chain.id).toEqual(1) + + await switchChain(config, { chainId: 456 }) + + expect(client.value?.chain?.id).toEqual(456) +}) + +test('parameters: config', () => { + const [chainId] = renderComposable(() => useClient({ config }), { + attach() {}, + }) + expect(chainId.value).toBeDefined() +}) + +test('behavior: controlled chainId', async () => { + const chainId = ref(456) + + const [client] = renderComposable(() => useClient({ chainId })) + + expect(client?.value?.chain.id).toEqual(456) + + chainId.value = 1 + + await waitFor(client, (client) => client?.chain.id === 1) +}) + +test('behavior: unconfigured chain', () => { + const [client] = renderComposable(() => useClient({ chainId: 123456 })) + expect(client.value).toBeUndefined() +}) diff --git a/packages/vue/src/composables/useClient.ts b/packages/vue/src/composables/useClient.ts new file mode 100644 index 0000000000..e29b38826b --- /dev/null +++ b/packages/vue/src/composables/useClient.ts @@ -0,0 +1,66 @@ +import { + type Config, + type GetClientParameters, + type GetClientReturnType, + type ResolvedRegister, + getClient, + watchClient, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type Ref, + computed, + onScopeDispose, + readonly, + ref, + watchEffect, +} from 'vue' + +import type { ConfigParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { useConfig } from './useConfig.js' + +export type UseClientParameters< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | number | undefined = + | config['chains'][number]['id'] + | undefined, +> = Compute< + DeepMaybeRef & ConfigParameter> +> + +export type UseClientReturnType< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | number | undefined = + | config['chains'][number]['id'] + | undefined, +> = Ref> + +/** https://wagmi.sh/vue/api/composables/useClient */ +export function useClient< + config extends Config = ResolvedRegister['config'], + chainId extends config['chains'][number]['id'] | number | undefined = + | config['chains'][number]['id'] + | undefined, +>( + parameters: UseClientParameters = {}, +): UseClientReturnType { + const params = computed(() => deepUnref(parameters)) + + const config = useConfig(params) + + const client = ref(getClient(config, params.value as GetClientParameters)) + watchEffect(() => { + client.value = getClient(config, params.value as GetClientParameters) + }) + const unsubscribe = watchClient(config, { + onChange(data) { + if (client.value?.uid === data?.uid) return + client.value = data + }, + }) + onScopeDispose(() => unsubscribe()) + + return readonly(client) as UseClientReturnType +} diff --git a/packages/vue/src/composables/useConfig.test-d.ts b/packages/vue/src/composables/useConfig.test-d.ts new file mode 100644 index 0000000000..f2b9d2bb31 --- /dev/null +++ b/packages/vue/src/composables/useConfig.test-d.ts @@ -0,0 +1,16 @@ +import type { Config } from '@wagmi/core' +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useConfig } from './useConfig.js' + +test('default', async () => { + const result = useConfig() + expectTypeOf(result).toEqualTypeOf() +}) + +test('parameters: config', async () => { + const result = useConfig({ config }) + expectTypeOf(result).not.toEqualTypeOf() + expectTypeOf(result).toEqualTypeOf() +}) diff --git a/packages/vue/src/composables/useConfig.test.ts b/packages/vue/src/composables/useConfig.test.ts new file mode 100644 index 0000000000..a7036b65e8 --- /dev/null +++ b/packages/vue/src/composables/useConfig.test.ts @@ -0,0 +1,24 @@ +import { renderComposable } from '@wagmi/test/vue' +import { expect, test, vi } from 'vitest' + +import { useConfig } from './useConfig.js' + +test('default', () => { + const [config] = renderComposable(() => useConfig()) + expect(config).toBeDefined() +}) + +test('behavior: throws when not provided via WagmiPlugin', () => { + vi.spyOn(console, 'error').mockImplementation(() => {}) + + try { + renderComposable(() => useConfig(), { attach() {} }) + } catch (error) { + expect(error).toMatchInlineSnapshot(` + [WagmiPluginNotFoundError: No \`config\` found in Vue context, use \`WagmiPlugin\` to properly initialize the library. + + Docs: https://wagmi.sh/vue/api/TODO.html + Version: @wagmi/vue@x.y.z] + `) + } +}) diff --git a/packages/vue/src/composables/useConfig.ts b/packages/vue/src/composables/useConfig.ts new file mode 100644 index 0000000000..a827f818a5 --- /dev/null +++ b/packages/vue/src/composables/useConfig.ts @@ -0,0 +1,34 @@ +import type { Config, ResolvedRegister } from '@wagmi/core' +import { hasInjectionContext, inject, unref } from 'vue' + +import { + WagmiInjectionContextError, + WagmiPluginNotFoundError, +} from '../errors/plugin.js' +import { configKey } from '../plugin.js' +import type { ConfigParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' + +export type UseConfigParameters = DeepMaybeRef< + ConfigParameter +> + +export type UseConfigReturnType = config + +/** https://wagmi.sh/vue/api/composables/useConfig */ +export function useConfig( + parameters_: UseConfigParameters = {}, +): UseConfigReturnType { + const parameters = unref(parameters_) + + // passthrough config if provided + if (parameters.config) return parameters.config as UseConfigReturnType + + // ensures that `inject()` can be used + if (!hasInjectionContext()) throw new WagmiInjectionContextError() + + const config = inject(configKey) + if (!config) throw new WagmiPluginNotFoundError() + + return config as UseConfigReturnType +} diff --git a/packages/vue/src/composables/useConnect.test-d.ts b/packages/vue/src/composables/useConnect.test-d.ts new file mode 100644 index 0000000000..44c7b6fdac --- /dev/null +++ b/packages/vue/src/composables/useConnect.test-d.ts @@ -0,0 +1,121 @@ +import type { + ConnectErrorType, + Connector, + CreateConnectorFn, +} from '@wagmi/core' +import { config } from '@wagmi/test' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { useConnect } from './useConnect.js' + +const connector = config.connectors[0]! +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { connect, context, data, error, variables } = useConnect({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: Connector | CreateConnectorFn + }>() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: Connector | CreateConnectorFn + }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: Connector | CreateConnectorFn + }>() + expectTypeOf(data).toEqualTypeOf<{ + accounts: readonly [Address, ...Address[]] + chainId: number + }>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: Connector | CreateConnectorFn + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data.value).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + } + | undefined + >() + expectTypeOf(error.value).toEqualTypeOf() + expectTypeOf(variables.value).toMatchTypeOf< + | { + chainId?: number | undefined + connector: Connector | CreateConnectorFn + } + | undefined + >() + expectTypeOf(context.value).toEqualTypeOf() + + connect( + { connector }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: typeof connector | CreateConnectorFn + foo?: string | undefined + }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: typeof connector | CreateConnectorFn + foo?: string | undefined + }>() + expectTypeOf(data).toEqualTypeOf<{ + accounts: readonly [Address, ...Address[]] + chainId: number + }>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ + chainId?: number | undefined + connector: typeof connector | CreateConnectorFn + foo?: string | undefined + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/vue/src/composables/useConnect.test.ts b/packages/vue/src/composables/useConnect.test.ts new file mode 100644 index 0000000000..206abd41ee --- /dev/null +++ b/packages/vue/src/composables/useConnect.test.ts @@ -0,0 +1,31 @@ +import { disconnect } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { afterEach, expect, test } from 'vitest' + +import { useAccount } from './useAccount.js' +import { useConnect } from './useConnect.js' + +const connector = config.connectors[0]! + +afterEach(async () => { + if (config.state.current === connector.uid) + await disconnect(config, { connector }) +}) + +test('default', async () => { + const [account] = renderComposable(() => useAccount()) + const [connect] = renderComposable(() => useConnect()) + + expect(account.address.value).not.toBeDefined() + expect(account.status.value).toEqual('disconnected') + + connect.connect({ + connector: connect.connectors[0]!, + }) + + await waitFor(account.isConnected, (isConnected) => Boolean(isConnected)) + + expect(account.address.value).toBeDefined() + expect(account.status.value).toEqual('connected') +}) diff --git a/packages/vue/src/composables/useConnect.ts b/packages/vue/src/composables/useConnect.ts new file mode 100644 index 0000000000..7659dc3411 --- /dev/null +++ b/packages/vue/src/composables/useConnect.ts @@ -0,0 +1,92 @@ +import { useMutation } from '@tanstack/vue-query' +import type { + Config, + ConnectErrorType, + GetConnectorsReturnType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type ConnectData, + type ConnectMutate, + type ConnectMutateAsync, + type ConnectVariables, + connectMutationOptions, +} from '@wagmi/core/query' +import { onScopeDispose } from 'vue' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' +import { useConnectors } from './useConnectors.js' + +export type UseConnectParameters< + config extends Config = Config, + context = unknown, +> = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + ConnectData, + ConnectErrorType, + ConnectVariables, + context + > + | undefined + } +> + +export type UseConnectReturnType< + config extends Config = Config, + context = unknown, +> = Compute< + UseMutationReturnType< + ConnectData, + ConnectErrorType, + ConnectVariables, + context + > & { + connect: ConnectMutate + connectAsync: ConnectMutateAsync + connectors: Compute | config['connectors'] + } +> + +/** https://wagmi.sh/vue/api/composables/useConnect */ +export function useConnect< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseConnectParameters = {}, +): UseConnectReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = connectMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + // Reset mutation back to an idle state when the connector disconnects. + const unsubscribe = config.subscribe( + ({ status }) => status, + (status, previousStatus) => { + if (previousStatus === 'connected' && status === 'disconnected') + result.reset() + }, + ) + onScopeDispose(() => unsubscribe()) + + type Return = UseConnectReturnType + return { + ...(result as Return), + connect: mutate as Return['connect'], + connectAsync: mutateAsync as Return['connectAsync'], + connectors: useConnectors({ config }).value, + } +} diff --git a/packages/vue/src/composables/useConnections.test.ts b/packages/vue/src/composables/useConnections.test.ts new file mode 100644 index 0000000000..d51401b427 --- /dev/null +++ b/packages/vue/src/composables/useConnections.test.ts @@ -0,0 +1,16 @@ +import { connect } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderComposable } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { useConnections } from './useConnections.js' + +test('default', async () => { + const [connections] = renderComposable(() => useConnections()) + + expect(connections.value).toEqual([]) + + await connect(config, { connector: config.connectors[0]! }) + + expect(connections.value.length).toBe(1) +}) diff --git a/packages/vue/src/composables/useConnections.ts b/packages/vue/src/composables/useConnections.ts new file mode 100644 index 0000000000..7bcc499498 --- /dev/null +++ b/packages/vue/src/composables/useConnections.ts @@ -0,0 +1,30 @@ +import { + type GetConnectionsReturnType, + getConnections, + watchConnections, +} from '@wagmi/core' +import { type Ref, onScopeDispose, readonly, ref } from 'vue' + +import type { ConfigParameter } from '../types/properties.js' +import { useConfig } from './useConfig.js' + +export type UseConnectionsParameters = ConfigParameter + +export type UseConnectionsReturnType = Ref + +/** https://wagmi.sh/vue/api/composables/useConnections */ +export function useConnections( + parameters: UseConnectionsParameters = {}, +): UseConnectionsReturnType { + const config = useConfig(parameters) + + const connections = ref(getConnections(config)) + const unsubscribe = watchConnections(config, { + onChange(data) { + connections.value = data + }, + }) + onScopeDispose(() => unsubscribe()) + + return readonly(connections) as UseConnectionsReturnType +} diff --git a/packages/vue/src/composables/useConnectorClient.test-d.ts b/packages/vue/src/composables/useConnectorClient.test-d.ts new file mode 100644 index 0000000000..710d8260d4 --- /dev/null +++ b/packages/vue/src/composables/useConnectorClient.test-d.ts @@ -0,0 +1,12 @@ +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useConnectorClient } from './useConnectorClient.js' + +test('parameters: config', async () => { + const client = useConnectorClient({ config }) + expectTypeOf(client.data?.value?.chain?.id!).toEqualTypeOf<1 | 456 | 10>() + + const client2 = useConnectorClient({ config, chainId: 1 }) + expectTypeOf(client2.data?.value?.chain?.id!).toEqualTypeOf<1>() +}) diff --git a/packages/vue/src/composables/useConnectorClient.test.ts b/packages/vue/src/composables/useConnectorClient.test.ts new file mode 100644 index 0000000000..7a361702ac --- /dev/null +++ b/packages/vue/src/composables/useConnectorClient.test.ts @@ -0,0 +1,156 @@ +import { connect, disconnect } from '@wagmi/core' +import { config, wait } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { deepUnref } from '../utils/cloneDeep.js' +import { useConnect } from './useConnect.js' +import { useConnectorClient } from './useConnectorClient.js' +import { useDisconnect } from './useDisconnect.js' +import { useSwitchChain } from './useSwitchChain.js' + +const connector = config.connectors[0]! + +test('default', async () => { + const [client] = renderComposable(() => useConnectorClient()) + + expect(deepUnref(client)).toMatchInlineSnapshot(` + { + "data": undefined, + "dataUpdatedAt": 0, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": false, + "isFetchedAfterMount": false, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": true, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": false, + "queryKey": [ + "connectorClient", + { + "chainId": 1, + "connectorUid": undefined, + }, + ], + "refetch": [Function], + "status": "pending", + "suspense": [Function], + } + `) +}) + +test('behavior: connected on mount', async () => { + await connect(config, { connector }) + + const [client] = renderComposable(() => useConnectorClient()) + + await waitFor(client.isSuccess, (isSuccess) => isSuccess === true) + + const { data, queryKey: _, ...rest } = deepUnref(client) + expect(data).toMatchObject( + expect.objectContaining({ + account: expect.any(Object), + chain: expect.any(Object), + }), + ) + expect(rest).toMatchInlineSnapshot(` + { + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": false, + "isSuccess": true, + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) + + await disconnect(config, { connector }) +}) + +test('behavior: connect and disconnect', async () => { + const [connect] = renderComposable(() => useConnect()) + const [client] = renderComposable(() => useConnectorClient()) + const [disconnect] = renderComposable(() => useDisconnect()) + + expect(client.data.value).not.toBeDefined() + + connect.connect({ + connector: connect.connectors[0]!, + }) + + await waitFor(client.data, (data) => data !== undefined) + + disconnect.disconnect() + + await waitFor(client.data, (data) => data === undefined) +}) + +test('behavior: switch chains', async () => { + await connect(config, { connector }) + + const [connectorClient] = renderComposable(() => useConnectorClient()) + const [switchChain] = renderComposable(() => useSwitchChain()) + + expect(connectorClient.data.value).not.toBeDefined() + + await waitFor(connectorClient.data, (data) => data !== undefined) + + switchChain.switchChain({ chainId: 456 }) + await waitFor(switchChain.isSuccess, (isSuccess) => isSuccess === true) + await waitFor(connectorClient.data, (data) => data !== undefined) + expect(connectorClient.data?.value?.chain.id).toEqual(456) + + switchChain.switchChain({ chainId: 1 }) + await waitFor(switchChain.isSuccess, (isSuccess) => isSuccess === true) + await waitFor(connectorClient.data, (data) => data !== undefined) + expect(connectorClient.data?.value?.chain.id).toEqual(1) + + await disconnect(config, { connector }) +}) + +test('behavior: disabled when properties missing', async () => { + const [connectorClient] = renderComposable(() => useConnectorClient()) + + await wait(100) + expect(connectorClient.isPending.value).toBe(true) +}) + +test('behavior: disabled when connecting', async () => { + const [connectorClient] = renderComposable(() => useConnectorClient()) + + config.setState((x) => ({ ...x, status: 'connecting' })) + + await wait(100) + expect(connectorClient.isLoading.value).not.toBeTruthy() +}) diff --git a/packages/vue/src/composables/useConnectorClient.ts b/packages/vue/src/composables/useConnectorClient.ts new file mode 100644 index 0000000000..08735718bf --- /dev/null +++ b/packages/vue/src/composables/useConnectorClient.ts @@ -0,0 +1,132 @@ +import { useQueryClient } from '@tanstack/vue-query' +import type { + Config, + Connector, + GetConnectorClientErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute, Omit } from '@wagmi/core/internal' +import { + type GetConnectorClientData, + type GetConnectorClientOptions, + type GetConnectorClientQueryFnData, + type GetConnectorClientQueryKey, + getConnectorClientQueryOptions, +} from '@wagmi/core/query' +import { computed, ref, watchEffect } from 'vue' + +import type { ConfigParameter } from '../types/properties.js' +import type { DeepMaybeRef, DeepUnwrapRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { + type UseQueryParameters, + type UseQueryReturnType, + useQuery, +} from '../utils/query.js' +import { useAccount } from './useAccount.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseConnectorClientParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetConnectorClientData, +> = Compute< + DeepMaybeRef< + GetConnectorClientOptions & + ConfigParameter & { + query?: + | Compute< + Omit< + DeepUnwrapRef< + UseQueryParameters< + GetConnectorClientQueryFnData, + GetConnectorClientErrorType, + selectData, + GetConnectorClientQueryKey + > + >, + 'gcTime' | 'staleTime' + > + > + | undefined + } + > +> + +export type UseConnectorClientReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetConnectorClientData, +> = UseQueryReturnType + +/** https://wagmi.sh/vue/api/composables/useConnectorClient */ +export function useConnectorClient< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetConnectorClientData, +>( + parameters_: UseConnectorClientParameters = {}, +): UseConnectorClientReturnType { + const parameters = computed(() => deepUnref(parameters_)) + + const config = useConfig(parameters) + const queryClient = useQueryClient() + const { + address, + connector: accountConnector, + status, + } = useAccount({ config }) + const configChainId = useChainId({ config }) + + const queryOptions = computed(() => { + const { + chainId = configChainId.value, + connector = accountConnector.value, + query = {}, + } = parameters.value + const { queryKey, ...options } = getConnectorClientQueryOptions< + config, + chainId + >(config as config, { + ...deepUnref(parameters), + chainId: chainId as chainId, + connector: connector as Connector, + }) + const enabled = Boolean( + (status.value === 'connected' || + (status.value === 'reconnecting' && connector?.getProvider)) && + (query.enabled ?? true), + ) + return { + ...query, + ...options, + queryKey, + enabled, + staleTime: Number.POSITIVE_INFINITY, + } + }) + + const addressRef = ref(address) + watchEffect(() => { + const previousAddress = addressRef.value + if (!address && previousAddress) { + // remove when account is disconnected + queryClient.removeQueries({ queryKey: queryOptions.value.queryKey }) + addressRef.value = undefined + } else if (address.value !== previousAddress) { + // invalidate when address changes + queryClient.invalidateQueries({ queryKey: queryOptions.value.queryKey }) + addressRef.value = address.value + } + }) + + return useQuery(queryOptions as any) as UseConnectorClientReturnType< + config, + chainId, + selectData + > +} diff --git a/packages/vue/src/composables/useConnectors.test.ts b/packages/vue/src/composables/useConnectors.test.ts new file mode 100644 index 0000000000..16fec78dfe --- /dev/null +++ b/packages/vue/src/composables/useConnectors.test.ts @@ -0,0 +1,21 @@ +import { mock } from '@wagmi/connectors' +import { accounts, config } from '@wagmi/test' +import { renderComposable } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { useConnectors } from './useConnectors.js' + +test('default', async () => { + const [connectors] = renderComposable(() => useConnectors()) + + const count = config.connectors.length + expect(connectors.value.length).toBe(count) + expect(connectors.value).toEqual(config.connectors) + + config._internal.connectors.setState(() => [ + ...config.connectors, + config._internal.connectors.setup(mock({ accounts })), + ]) + + expect(connectors.value.length).toBe(count + 1) +}) diff --git a/packages/vue/src/composables/useConnectors.ts b/packages/vue/src/composables/useConnectors.ts new file mode 100644 index 0000000000..4d12d81806 --- /dev/null +++ b/packages/vue/src/composables/useConnectors.ts @@ -0,0 +1,37 @@ +import { + type Config, + type GetConnectorsReturnType, + type ResolvedRegister, + getConnectors, + watchConnectors, +} from '@wagmi/core' +import { type Ref, onScopeDispose, ref } from 'vue' + +import type { ConfigParameter } from '../types/properties.js' +import { useConfig } from './useConfig.js' + +export type UseConnectorsParameters = + ConfigParameter + +export type UseConnectorsReturnType = Ref< + GetConnectorsReturnType +> + +/** https://wagmi.sh/vue/api/composables/useConnectors */ +export function useConnectors< + config extends Config = ResolvedRegister['config'], +>( + parameters: UseConnectorsParameters = {}, +): UseConnectorsReturnType { + const config = useConfig(parameters) + + const connectors = ref(getConnectors(config)) + const unsubscribe = watchConnectors(config, { + onChange(data) { + connectors.value = data as never + }, + }) + onScopeDispose(() => unsubscribe()) + + return connectors +} diff --git a/packages/vue/src/composables/useDisconnect.test-d.ts b/packages/vue/src/composables/useDisconnect.test-d.ts new file mode 100644 index 0000000000..3be3fe9488 --- /dev/null +++ b/packages/vue/src/composables/useDisconnect.test-d.ts @@ -0,0 +1,87 @@ +import type { Connector, DisconnectErrorType } from '@wagmi/core' +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useDisconnect } from './useDisconnect.js' + +const connector = config.connectors[0]! +const contextValue = { foo: 'bar' } as const + +test('parameter', () => { + expectTypeOf(useDisconnect().disconnect) + .parameter(0) + .toEqualTypeOf<{ connector?: Connector | undefined } | undefined>() + expectTypeOf(useDisconnect().disconnect) + .parameter(0) + .toEqualTypeOf<{ connector?: Connector | undefined } | undefined>() +}) + +test('context', () => { + const { context, data, disconnect, error, variables } = useDisconnect({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data.value).toEqualTypeOf() + expectTypeOf(error.value).toEqualTypeOf() + expectTypeOf(variables.value).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(context.value).toEqualTypeOf() + + disconnect( + { connector }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf< + { connector?: Connector | undefined } | undefined + >() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/vue/src/composables/useDisconnect.test.ts b/packages/vue/src/composables/useDisconnect.test.ts new file mode 100644 index 0000000000..935c75827d --- /dev/null +++ b/packages/vue/src/composables/useDisconnect.test.ts @@ -0,0 +1,30 @@ +import { connect } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { beforeEach, expect, test } from 'vitest' + +import { useAccount } from './useAccount.js' +import { useDisconnect } from './useDisconnect.js' + +const connector = config.connectors[0]! + +beforeEach(async () => { + await connect(config, { connector }) +}) + +test('default', async () => { + const [account] = renderComposable(() => useAccount()) + const [disconnect] = renderComposable(() => useDisconnect()) + + expect(account.address.value).toBeDefined() + expect(account.status.value).toEqual('connected') + + disconnect.disconnect() + + await waitFor(account.isDisconnected, (isDisconnected) => + Boolean(isDisconnected), + ) + + expect(account.address.value).not.toBeDefined() + expect(account.status.value).toEqual('disconnected') +}) diff --git a/packages/vue/src/composables/useDisconnect.ts b/packages/vue/src/composables/useDisconnect.ts new file mode 100644 index 0000000000..540e588124 --- /dev/null +++ b/packages/vue/src/composables/useDisconnect.ts @@ -0,0 +1,70 @@ +import { useMutation } from '@tanstack/vue-query' +import type { Connector, DisconnectErrorType } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type DisconnectData, + type DisconnectMutate, + type DisconnectMutateAsync, + type DisconnectVariables, + disconnectMutationOptions, +} from '@wagmi/core/query' +import { type Ref, computed } from 'vue' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' +import { useConnections } from './useConnections.js' + +export type UseDisconnectParameters = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + DisconnectData, + DisconnectErrorType, + DisconnectVariables, + context + > + | undefined + } +> + +export type UseDisconnectReturnType = Compute< + UseMutationReturnType< + DisconnectData, + DisconnectErrorType, + DisconnectVariables, + context + > & { + connectors: Ref + disconnect: DisconnectMutate + disconnectAsync: DisconnectMutateAsync + } +> + +/** https://wagmi.sh/vue/api/composables/useDisconnect */ +export function useDisconnect( + parameters: UseDisconnectParameters = {}, +): UseDisconnectReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + const connections = useConnections({ config }) + + const mutationOptions = disconnectMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + return { + ...result, + connectors: computed(() => + connections.value.map((connection) => connection.connector), + ), + disconnect: mutate, + disconnectAsync: mutateAsync, + } +} diff --git a/packages/vue/src/composables/useEnsAddress.test.ts b/packages/vue/src/composables/useEnsAddress.test.ts new file mode 100644 index 0000000000..01d35769b7 --- /dev/null +++ b/packages/vue/src/composables/useEnsAddress.test.ts @@ -0,0 +1,52 @@ +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { deepUnref } from '../utils/cloneDeep.js' +import { useEnsAddress } from './useEnsAddress.js' + +test('default', async () => { + const [result] = renderComposable(() => + useEnsAddress({ + name: 'wevm.eth', + }), + ) + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": "0xd2135CfB216b74109775236E36d4b433F1DF507B", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "ensAddress", + { + "chainId": 1, + "name": "wevm.eth", + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) diff --git a/packages/vue/src/composables/useEnsAddress.ts b/packages/vue/src/composables/useEnsAddress.ts new file mode 100644 index 0000000000..ecb27ac143 --- /dev/null +++ b/packages/vue/src/composables/useEnsAddress.ts @@ -0,0 +1,65 @@ +import type { + Config, + GetEnsAddressErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetEnsAddressData, + type GetEnsAddressOptions, + type GetEnsAddressQueryFnData, + type GetEnsAddressQueryKey, + getEnsAddressQueryOptions, +} from '@wagmi/core/query' +import { computed } from 'vue' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseEnsAddressParameters< + config extends Config = Config, + selectData = GetEnsAddressData, +> = Compute< + DeepMaybeRef< + GetEnsAddressOptions & + ConfigParameter & + QueryParameter< + GetEnsAddressQueryFnData, + GetEnsAddressErrorType, + selectData, + GetEnsAddressQueryKey + > + > +> + +export type UseEnsAddressReturnType = + UseQueryReturnType + +/** https://wagmi.sh/vue/api/composables/useEnsAddress */ +export function useEnsAddress< + config extends Config = ResolvedRegister['config'], + selectData = GetEnsAddressData, +>( + parameters_: UseEnsAddressParameters = {}, +): UseEnsAddressReturnType { + const parameters = computed(() => deepUnref(parameters_)) + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + + const queryOptions = computed(() => { + const { chainId = configChainId.value, name, query = {} } = parameters.value + const options = getEnsAddressQueryOptions(config, { + ...parameters.value, + chainId, + }) + const enabled = Boolean(name && (query.enabled ?? true)) + return { ...query, ...options, enabled } + }) + + return useQuery(queryOptions as any) as UseEnsAddressReturnType +} diff --git a/packages/vue/src/composables/useEnsAvatar.test.ts b/packages/vue/src/composables/useEnsAvatar.test.ts new file mode 100644 index 0000000000..ab024c89b5 --- /dev/null +++ b/packages/vue/src/composables/useEnsAvatar.test.ts @@ -0,0 +1,52 @@ +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { deepUnref } from '../utils/cloneDeep.js' +import { useEnsAvatar } from './useEnsAvatar.js' + +test('default', async () => { + const [result] = renderComposable(() => + useEnsAvatar({ + name: 'wevm.eth', + }), + ) + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": "https://euc.li/wevm.eth", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "ensAvatar", + { + "chainId": 1, + "name": "wevm.eth", + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) diff --git a/packages/vue/src/composables/useEnsAvatar.ts b/packages/vue/src/composables/useEnsAvatar.ts new file mode 100644 index 0000000000..ff328ad87c --- /dev/null +++ b/packages/vue/src/composables/useEnsAvatar.ts @@ -0,0 +1,65 @@ +import type { + Config, + GetEnsAvatarErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetEnsAvatarData, + type GetEnsAvatarOptions, + type GetEnsAvatarQueryFnData, + type GetEnsAvatarQueryKey, + getEnsAvatarQueryOptions, +} from '@wagmi/core/query' +import { computed } from 'vue' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseEnsAvatarParameters< + config extends Config = Config, + selectData = GetEnsAvatarData, +> = Compute< + DeepMaybeRef< + GetEnsAvatarOptions & + ConfigParameter & + QueryParameter< + GetEnsAvatarQueryFnData, + GetEnsAvatarErrorType, + selectData, + GetEnsAvatarQueryKey + > + > +> + +export type UseEnsAvatarReturnType = + UseQueryReturnType + +/** https://wagmi.sh/vue/api/composables/useEnsAvatar */ +export function useEnsAvatar< + config extends Config = ResolvedRegister['config'], + selectData = GetEnsAvatarData, +>( + parameters_: UseEnsAvatarParameters = {}, +): UseEnsAvatarReturnType { + const parameters = computed(() => deepUnref(parameters_)) + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + + const queryOptions = computed(() => { + const { chainId = configChainId.value, name, query = {} } = parameters.value + const options = getEnsAvatarQueryOptions(config, { + ...parameters.value, + chainId, + }) + const enabled = Boolean(name && (query.enabled ?? true)) + return { ...query, ...options, enabled } + }) + + return useQuery(queryOptions as any) as UseEnsAvatarReturnType +} diff --git a/packages/vue/src/composables/useEnsName.test.ts b/packages/vue/src/composables/useEnsName.test.ts new file mode 100644 index 0000000000..ee5b8cfab6 --- /dev/null +++ b/packages/vue/src/composables/useEnsName.test.ts @@ -0,0 +1,52 @@ +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { deepUnref } from '../utils/cloneDeep.js' +import { useEnsName } from './useEnsName.js' + +test('default', async () => { + const [result] = renderComposable(() => + useEnsName({ + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + }), + ) + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": "wevm.eth", + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "ensName", + { + "address": "0xd2135CfB216b74109775236E36d4b433F1DF507B", + "chainId": 1, + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) diff --git a/packages/vue/src/composables/useEnsName.ts b/packages/vue/src/composables/useEnsName.ts new file mode 100644 index 0000000000..ba251aa5a3 --- /dev/null +++ b/packages/vue/src/composables/useEnsName.ts @@ -0,0 +1,65 @@ +import type { Config, GetEnsNameErrorType, ResolvedRegister } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetEnsNameData, + type GetEnsNameOptions, + type GetEnsNameQueryFnData, + type GetEnsNameQueryKey, + getEnsNameQueryOptions, +} from '@wagmi/core/query' + +import { computed } from 'vue' +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseEnsNameParameters< + config extends Config = Config, + selectData = GetEnsNameData, +> = Compute< + DeepMaybeRef< + GetEnsNameOptions & + ConfigParameter & + QueryParameter< + GetEnsNameQueryFnData, + GetEnsNameErrorType, + selectData, + GetEnsNameQueryKey + > + > +> + +export type UseEnsNameReturnType = + UseQueryReturnType + +/** https://wagmi.sh/vue/api/composables/useEnsName */ +export function useEnsName< + config extends Config = ResolvedRegister['config'], + selectData = GetEnsNameData, +>( + parameters_: UseEnsNameParameters = {}, +): UseEnsNameReturnType { + const parameters = computed(() => deepUnref(parameters_)) + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + + const queryOptions = computed(() => { + const { + address, + chainId = configChainId.value, + query = {}, + } = parameters.value + const options = getEnsNameQueryOptions(config, { + ...parameters.value, + chainId, + }) + const enabled = Boolean(address && (query.enabled ?? true)) + return { ...query, ...options, enabled } + }) + + return useQuery(queryOptions as any) as UseEnsNameReturnType +} diff --git a/packages/vue/src/composables/useEstimateGas.test-d.ts b/packages/vue/src/composables/useEstimateGas.test-d.ts new file mode 100644 index 0000000000..ba084419d4 --- /dev/null +++ b/packages/vue/src/composables/useEstimateGas.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useEstimateGas } from './useEstimateGas.js' + +test('select data', () => { + const result = useEstimateGas({ + query: { + select(data) { + return data.toString() + }, + }, + }) + expectTypeOf(result.data.value).toEqualTypeOf() +}) diff --git a/packages/vue/src/composables/useEstimateGas.test.ts b/packages/vue/src/composables/useEstimateGas.test.ts new file mode 100644 index 0000000000..f8212f11da --- /dev/null +++ b/packages/vue/src/composables/useEstimateGas.test.ts @@ -0,0 +1,117 @@ +import { accounts, wait } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { ref } from 'vue' +import { deepUnref } from '../utils/cloneDeep.js' +import { useEstimateGas } from './useEstimateGas.js' + +test('default', async () => { + const [result] = renderComposable(() => + useEstimateGas({ + account: accounts[0], + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }), + ) + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": 21000n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "estimateGas", + { + "account": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "chainId": 1, + "to": "0xd2135CfB216b74109775236E36d4b433F1DF507B", + "value": 10000000000000000n, + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) + +test('behavior: address: undefined -> defined', async () => { + const address = ref() + + const [result] = renderComposable(() => + useEstimateGas({ + account: address, + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }), + ) + + await wait(100) + expect(result.fetchStatus.value).toBe('idle') + + address.value = accounts[0] + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": 21000n, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "estimateGas", + { + "account": undefined, + "chainId": 1, + "to": "0xd2135CfB216b74109775236E36d4b433F1DF507B", + "value": 10000000000000000n, + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) diff --git a/packages/vue/src/composables/useEstimateGas.ts b/packages/vue/src/composables/useEstimateGas.ts new file mode 100644 index 0000000000..fd885ec712 --- /dev/null +++ b/packages/vue/src/composables/useEstimateGas.ts @@ -0,0 +1,83 @@ +import type { + Config, + EstimateGasErrorType, + ResolvedRegister, +} from '@wagmi/core' +import { + type EstimateGasData, + type EstimateGasOptions, + type EstimateGasQueryFnData, + type EstimateGasQueryKey, + estimateGasQueryOptions, +} from '@wagmi/core/query' +import { computed } from 'vue' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' +import { useConnectorClient } from './useConnectorClient.js' + +export type UseEstimateGasParameters< + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = EstimateGasData, +> = DeepMaybeRef< + EstimateGasOptions & + ConfigParameter & + QueryParameter< + EstimateGasQueryFnData, + EstimateGasErrorType, + selectData, + EstimateGasQueryKey + > +> + +export type UseEstimateGasReturnType = + UseQueryReturnType + +/** https://wagmi.sh/react/api/hooks/useEstimateGas */ +export function useEstimateGas< + config extends Config = ResolvedRegister['config'], + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = EstimateGasData, +>( + parameters?: UseEstimateGasParameters, +): UseEstimateGasReturnType + +export function useEstimateGas( + parameters_: UseEstimateGasParameters = {}, +): UseEstimateGasReturnType { + const parameters = computed(() => deepUnref(parameters_)) + + const config = useConfig(parameters) + const { data: connectorClient } = useConnectorClient( + computed(() => ({ + connector: parameters.value.connector, + query: { enabled: parameters.value.account === undefined }, + })), + ) + + const configChainId = useChainId({ config }) + + const queryOptions = computed(() => { + const { + account = connectorClient?.value?.account, + chainId = configChainId.value, + connector, + query = {}, + } = parameters.value + const options = estimateGasQueryOptions(config, { + ...parameters.value, + account, + chainId, + connector, + }) + const enabled = Boolean((account || connector) && (query.enabled ?? true)) + return { ...query, ...options, enabled } + }) + + return useQuery(queryOptions) +} diff --git a/packages/vue/src/composables/useReadContract.test-d.ts b/packages/vue/src/composables/useReadContract.test-d.ts new file mode 100644 index 0000000000..0685dde8f4 --- /dev/null +++ b/packages/vue/src/composables/useReadContract.test-d.ts @@ -0,0 +1,99 @@ +import { abi } from '@wagmi/test' +import type { Address } from 'viem' +import { assertType, expectTypeOf, test } from 'vitest' + +import type { DeepUnwrapRef } from '../types/ref.js' +import { + type UseReadContractParameters, + type UseReadContractReturnType, + useReadContract, +} from './useReadContract.js' + +test('select data', () => { + const result = useReadContract({ + address: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + query: { + select(data) { + expectTypeOf(data).toEqualTypeOf() + return data?.toString() + }, + }, + }) + expectTypeOf(result.data.value).toEqualTypeOf() +}) + +test('UseReadContractParameters', () => { + type Result = DeepUnwrapRef< + UseReadContractParameters + > + expectTypeOf<{ + functionName?: + | 'symbol' + | 'name' + | 'allowance' + | 'balanceOf' + | 'decimals' + | 'totalSupply' + | undefined + args?: readonly [Address] | undefined + }>().toEqualTypeOf>() +}) + +test('UseReadContractReturnType', () => { + type Result = UseReadContractReturnType + expectTypeOf().toEqualTypeOf() +}) + +test('overloads', () => { + const result1 = useReadContract({ + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + }) + assertType(result1.data.value) + + const result2 = useReadContract({ + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: [], + }) + assertType(result2.data.value) + + const result3 = useReadContract({ + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x'], + }) + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + assertType(result3.data) + + const result4 = useReadContract({ + address: '0x', + abi: abi.viewOverloads, + functionName: 'foo', + args: ['0x', '0x'], + }) + assertType< + | { + foo: `0x${string}` + bar: `0x${string}` + } + | undefined + // @ts-ignore – TODO: Fix https://github.com/wevm/viem/issues/1916 + >(result4.data) +}) + +test('deployless read (bytecode)', () => { + const result = useReadContract({ + code: '0x', + abi: abi.erc20, + functionName: 'balanceOf', + args: ['0x'], + }) + expectTypeOf(result.data.value).toEqualTypeOf() +}) diff --git a/packages/vue/src/composables/useReadContract.test.ts b/packages/vue/src/composables/useReadContract.test.ts new file mode 100644 index 0000000000..2fe2fb7033 --- /dev/null +++ b/packages/vue/src/composables/useReadContract.test.ts @@ -0,0 +1,105 @@ +import { abi, address, bytecode, chain, wait } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' +import { ref } from 'vue' + +import { useReadContract } from './useReadContract.js' + +test('default', async () => { + const [result] = renderComposable(() => + useReadContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + }), + ) + + await waitFor(result.isSuccess) + + expect(result.data.value).toBe(4n) + expect(result.queryKey).toMatchInlineSnapshot(` + [ + "readContract", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": [ + "0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC", + ], + "chainId": 1, + "functionName": "balanceOf", + }, + ] + `) +}) + +test('parameters: chainId', async () => { + const [result] = renderComposable(() => + useReadContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'balanceOf', + args: ['0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC'], + chainId: chain.mainnet2.id, + }), + ) + + await waitFor(result.isSuccess) + + expect(result.data.value).toBe(4n) + expect(result.queryKey).toMatchInlineSnapshot(` + [ + "readContract", + { + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": [ + "0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC", + ], + "chainId": 456, + "functionName": "balanceOf", + }, + ] + `) +}) + +test('parameters: deployless read (bytecode)', async () => { + const [result] = renderComposable(() => + useReadContract({ + abi: abi.wagmiMintExample, + functionName: 'name', + code: bytecode.wagmiMintExample, + }), + ) + + await waitFor(result.isSuccess) + + expect(result.data.value).toMatchInlineSnapshot(`"wagmi"`) +}) + +test.skip('behavior: disabled when missing properties', async () => { + const addressRef = ref() + const abiRef = ref() + const functionNameRef = ref() + + const [result] = renderComposable(() => + useReadContract({ + abi: abiRef, + address: addressRef, + functionName: functionNameRef, + }), + ) + + await wait(100) + expect(result.fetchStatus.value).toBe('idle') + + addressRef.value = '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2' + + await wait(100) + expect(result.fetchStatus.value).toBe('idle') + + abiRef.value = abi.wagmiMintExample + functionNameRef.value = 'totalSupply' + + await wait(100) + expect(result.fetchStatus.value).toBe('fetching') +}) diff --git a/packages/vue/src/composables/useReadContract.ts b/packages/vue/src/composables/useReadContract.ts new file mode 100644 index 0000000000..10ecc859ff --- /dev/null +++ b/packages/vue/src/composables/useReadContract.ts @@ -0,0 +1,116 @@ +import type { + Config, + ReadContractErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { UnionCompute } from '@wagmi/core/internal' +import { + type ReadContractData, + type ReadContractOptions, + type ReadContractQueryFnData, + type ReadContractQueryKey, + readContractQueryOptions, + structuralSharing, +} from '@wagmi/core/query' +import type { Abi, ContractFunctionArgs, ContractFunctionName } from 'viem' +import { computed } from 'vue' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseReadContractParameters< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'pure' | 'view' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'pure' | 'view', + functionName + > = ContractFunctionArgs, + config extends Config = Config, + selectData = ReadContractData, +> = UnionCompute< + DeepMaybeRef< + ReadContractOptions & + ConfigParameter & + QueryParameter< + ReadContractQueryFnData, + ReadContractErrorType, + selectData, + ReadContractQueryKey + > + > +> + +export type UseReadContractReturnType< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'pure' | 'view' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'pure' | 'view', + functionName + > = ContractFunctionArgs, + selectData = ReadContractData, +> = UseQueryReturnType + +/** https://wagmi.sh/vue/api/hooks/useReadContract */ +export function useReadContract< + const abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs, + config extends Config = ResolvedRegister['config'], + selectData = ReadContractData, +>( + parameters_: UseReadContractParameters< + abi, + functionName, + args, + config, + selectData + > = {} as any, +): UseReadContractReturnType { + const parameters = computed(() => deepUnref(parameters_)) as any + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + + const queryOptions = computed(() => { + const { + abi, + address, + chainId = configChainId.value, + code, + functionName, + query = {}, + } = parameters.value + const options = readContractQueryOptions( + config as any, + { ...parameters.value, chainId }, + ) + const enabled = Boolean( + (address || code) && abi && functionName && (query.enabled ?? true), + ) + return { + ...query, + ...options, + enabled, + structuralSharing: query.structuralSharing ?? structuralSharing, + } + }) + + return useQuery(queryOptions) as UseReadContractReturnType< + abi, + functionName, + args, + selectData + > +} diff --git a/packages/vue/src/composables/useReconnect.test-d.ts b/packages/vue/src/composables/useReconnect.test-d.ts new file mode 100644 index 0000000000..bc4ecd8d8a --- /dev/null +++ b/packages/vue/src/composables/useReconnect.test-d.ts @@ -0,0 +1,154 @@ +import type { + Connector, + CreateConnectorFn, + ReconnectErrorType, +} from '@wagmi/core' +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import type { Address } from 'viem' +import { useReconnect } from './useReconnect.js' + +const connectors = [config.connectors[0]!] +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { context, data, error, reconnect, variables } = useReconnect({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + expectTypeOf(data).toEqualTypeOf< + { + accounts: readonly [Address, ...Address[]] + chainId: number + connector: Connector + }[] + >() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + connector: Connector + }[] + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data.value).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + connector: Connector + }[] + | undefined + >() + expectTypeOf(error.value).toEqualTypeOf() + expectTypeOf(variables.value).toEqualTypeOf< + | { + connectors?: readonly (CreateConnectorFn | Connector)[] | undefined + } + | undefined + >() + expectTypeOf(context.value).toEqualTypeOf() + + reconnect( + { connectors }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + expectTypeOf(data).toEqualTypeOf< + { + accounts: readonly [Address, ...Address[]] + chainId: number + connector: Connector + }[] + >() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + connector: Connector + }[] + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf< + | { + connectors?: + | readonly (CreateConnectorFn | Connector)[] + | undefined + } + | undefined + >() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/vue/src/composables/useReconnect.test.ts b/packages/vue/src/composables/useReconnect.test.ts new file mode 100644 index 0000000000..49cf7f73e5 --- /dev/null +++ b/packages/vue/src/composables/useReconnect.test.ts @@ -0,0 +1,81 @@ +import { mock } from '@wagmi/connectors' +import { connect, disconnect } from '@wagmi/core' +import { accounts, config } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { afterEach, expect, test } from 'vitest' + +import { useReconnect } from './useReconnect.js' + +const connector = config._internal.connectors.setup( + mock({ + accounts, + features: { reconnect: true }, + }), +) + +afterEach(async () => { + if (config.state.current) await disconnect(config) +}) + +test('default', async () => { + await connect(config, { connector }) + + const [reconnect] = renderComposable(() => useReconnect()) + + reconnect.reconnect() + await waitFor(reconnect.isSuccess) + + expect(reconnect.data.value).toStrictEqual([]) +}) + +test('parameters: connectors (Connector)', async () => { + await connect(config, { connector }) + + const [reconnect] = renderComposable(() => useReconnect()) + + reconnect.reconnect({ connectors: [connector] }) + await waitFor(reconnect.isSuccess) + + expect(reconnect.data.value).toMatchObject( + expect.arrayContaining([ + expect.objectContaining({ + accounts: expect.any(Array), + chainId: expect.any(Number), + }), + ]), + ) +}) + +test('parameters: connectors (CreateConnectorFn)', async () => { + const connector = mock({ + accounts, + features: { reconnect: true }, + }) + await connect(config, { connector }) + + const [reconnect] = renderComposable(() => useReconnect()) + + reconnect.reconnect({ connectors: [connector] }) + await waitFor(reconnect.isSuccess) + + expect(reconnect.data.value).toMatchObject( + expect.arrayContaining([ + expect.objectContaining({ + accounts: expect.any(Array), + chainId: expect.any(Number), + }), + ]), + ) +}) + +test("behavior: doesn't reconnect if already reconnecting", async () => { + const previousStatus = config.state.status + config.setState((x) => ({ ...x, status: 'reconnecting' })) + + const [reconnect] = renderComposable(() => useReconnect()) + + await expect( + reconnect.reconnectAsync({ connectors: [connector] }), + ).resolves.toStrictEqual([]) + config.setState((x) => ({ ...x, status: previousStatus })) +}) diff --git a/packages/vue/src/composables/useReconnect.ts b/packages/vue/src/composables/useReconnect.ts new file mode 100644 index 0000000000..cfab97d858 --- /dev/null +++ b/packages/vue/src/composables/useReconnect.ts @@ -0,0 +1,65 @@ +import { useMutation } from '@tanstack/vue-query' +import type { Connector, ReconnectErrorType } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type ReconnectData, + type ReconnectMutate, + type ReconnectMutateAsync, + type ReconnectVariables, + reconnectMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseReconnectParameters = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + ReconnectData, + ReconnectErrorType, + ReconnectVariables, + context + > + | undefined + } +> + +export type UseReconnectReturnType = Compute< + UseMutationReturnType< + ReconnectData, + ReconnectErrorType, + ReconnectVariables, + context + > & { + connectors: readonly Connector[] + reconnect: ReconnectMutate + reconnectAsync: ReconnectMutateAsync + } +> + +/** https://wagmi.sh/vue/api/composables/useReconnect */ +export function useReconnect( + parameters: UseReconnectParameters = {}, +): UseReconnectReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = reconnectMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + return { + ...result, + connectors: config.connectors, + reconnect: mutate, + reconnectAsync: mutateAsync, + } +} diff --git a/packages/vue/src/composables/useSendTransaction.test-d.ts b/packages/vue/src/composables/useSendTransaction.test-d.ts new file mode 100644 index 0000000000..4670e879cf --- /dev/null +++ b/packages/vue/src/composables/useSendTransaction.test-d.ts @@ -0,0 +1,78 @@ +import type { SendTransactionErrorType } from '@wagmi/core' +import type { Hash } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { useSendTransaction } from './useSendTransaction.js' + +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { context, data, error, sendTransaction, variables } = + useSendTransaction({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toMatchTypeOf< + { chainId?: number | undefined } | undefined + >() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + }>() + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data.value).toEqualTypeOf() + expectTypeOf(error.value).toEqualTypeOf() + expectTypeOf(variables.value).toMatchTypeOf< + { chainId?: number | undefined } | undefined + >() + expectTypeOf(context.value).toEqualTypeOf() + + sendTransaction( + { to: '0x' }, + { + onError(error, variables, context) { + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + }>() + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/vue/src/composables/useSendTransaction.test.ts b/packages/vue/src/composables/useSendTransaction.test.ts new file mode 100644 index 0000000000..ae069766ee --- /dev/null +++ b/packages/vue/src/composables/useSendTransaction.test.ts @@ -0,0 +1,25 @@ +import { connect, disconnect } from '@wagmi/core' +import { config, transactionHashRegex } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { parseEther } from 'viem' +import { expect, test } from 'vitest' + +import { useSendTransaction } from './useSendTransaction.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const [result] = renderComposable(() => useSendTransaction()) + + result.sendTransaction({ + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) + await waitFor(result.isSuccess) + + expect(result.data.value).toMatch(transactionHashRegex) + + await disconnect(config, { connector }) +}) diff --git a/packages/vue/src/composables/useSendTransaction.ts b/packages/vue/src/composables/useSendTransaction.ts new file mode 100644 index 0000000000..d5bc718337 --- /dev/null +++ b/packages/vue/src/composables/useSendTransaction.ts @@ -0,0 +1,76 @@ +import { useMutation } from '@tanstack/vue-query' +import type { + Config, + ResolvedRegister, + SendTransactionErrorType, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type SendTransactionData, + type SendTransactionMutate, + type SendTransactionMutateAsync, + type SendTransactionVariables, + sendTransactionMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseSendTransactionParameters< + config extends Config = Config, + context = unknown, +> = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + SendTransactionData, + SendTransactionErrorType, + SendTransactionVariables, + context + > + | undefined + } +> + +export type UseSendTransactionReturnType< + config extends Config = Config, + context = unknown, +> = Compute< + UseMutationReturnType< + SendTransactionData, + SendTransactionErrorType, + SendTransactionVariables, + context + > & { + sendTransaction: SendTransactionMutate + sendTransactionAsync: SendTransactionMutateAsync + } +> + +/** https://wagmi.sh/vue/api/composables/useSendTransaction */ +export function useSendTransaction< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseSendTransactionParameters = {}, +): UseSendTransactionReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = sendTransactionMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + return { + ...result, + sendTransaction: mutate, + sendTransactionAsync: mutateAsync, + } as UseSendTransactionReturnType +} diff --git a/packages/vue/src/composables/useSignMessage.test-d.ts b/packages/vue/src/composables/useSignMessage.test-d.ts new file mode 100644 index 0000000000..5c8da53bba --- /dev/null +++ b/packages/vue/src/composables/useSignMessage.test-d.ts @@ -0,0 +1,64 @@ +import type { SignMessageErrorType } from '@wagmi/core' +import type { SignMessageVariables } from '@wagmi/core/query' +import { expectTypeOf, test } from 'vitest' + +import { useSignMessage } from './useSignMessage.js' + +const message = 'hello world' +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { context, data, error, signMessage, variables } = useSignMessage({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(data).toEqualTypeOf<`0x${string}`>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf<`0x${string}` | undefined>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data.value).toEqualTypeOf<`0x${string}` | undefined>() + expectTypeOf(error.value).toEqualTypeOf() + expectTypeOf(variables.value).toEqualTypeOf< + SignMessageVariables | undefined + >() + expectTypeOf(context.value).toEqualTypeOf() + + signMessage( + { message }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(data).toEqualTypeOf<`0x${string}`>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf<`0x${string}` | undefined>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/vue/src/composables/useSignMessage.test.ts b/packages/vue/src/composables/useSignMessage.test.ts new file mode 100644 index 0000000000..a00691fb7f --- /dev/null +++ b/packages/vue/src/composables/useSignMessage.test.ts @@ -0,0 +1,43 @@ +import { connect, disconnect, getAccount } from '@wagmi/core' +import { config, privateKey } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { recoverMessageAddress } from 'viem' +import { expect, test } from 'vitest' + +import { privateKeyToAccount } from 'viem/accounts' +import { useSignMessage } from './useSignMessage.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const [result] = renderComposable(() => useSignMessage()) + + result.signMessage({ message: 'foo bar baz' }) + await waitFor(result.isSuccess) + + await expect( + recoverMessageAddress({ + message: 'foo bar baz', + signature: result.data.value!, + }), + ).resolves.toEqual(getAccount(config).address) + + await disconnect(config, { connector }) +}) + +test('behavior: local account', async () => { + const [result] = renderComposable(() => useSignMessage()) + + const account = privateKeyToAccount(privateKey) + result.signMessage({ account, message: 'foo bar baz' }) + await waitFor(result.isSuccess) + + await expect( + recoverMessageAddress({ + message: 'foo bar baz', + signature: result.data.value!, + }), + ).resolves.toEqual(account.address) +}) diff --git a/packages/vue/src/composables/useSignMessage.ts b/packages/vue/src/composables/useSignMessage.ts new file mode 100644 index 0000000000..2f7222b6a4 --- /dev/null +++ b/packages/vue/src/composables/useSignMessage.ts @@ -0,0 +1,63 @@ +import type { SignMessageErrorType } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type SignMessageData, + type SignMessageMutate, + type SignMessageMutateAsync, + type SignMessageVariables, + signMessageMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import { + type UseMutationParameters, + type UseMutationReturnType, + useMutation, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseSignMessageParameters = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + SignMessageData, + SignMessageErrorType, + SignMessageVariables, + context + > + | undefined + } +> + +export type UseSignMessageReturnType = Compute< + UseMutationReturnType< + SignMessageData, + SignMessageErrorType, + SignMessageVariables, + context + > & { + signMessage: SignMessageMutate + signMessageAsync: SignMessageMutateAsync + } +> + +/** https://wagmi.sh/vue/api/composables/useSignMessage */ +export function useSignMessage( + parameters: UseSignMessageParameters = {}, +): UseSignMessageReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = signMessageMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + return { + ...result, + signMessage: mutate, + signMessageAsync: mutateAsync, + } +} diff --git a/packages/vue/src/composables/useSignTypedData.test-d.ts b/packages/vue/src/composables/useSignTypedData.test-d.ts new file mode 100644 index 0000000000..ba5c253a8f --- /dev/null +++ b/packages/vue/src/composables/useSignTypedData.test-d.ts @@ -0,0 +1,95 @@ +import type { + SignTypedDataErrorType, + SignTypedDataReturnType, +} from '@wagmi/core' +import type { SignTypedDataVariables } from '@wagmi/core/query' +import { typedData } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useSignTypedData } from './useSignTypedData.js' + +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { context, data, error, signTypedData, variables } = useSignTypedData({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toMatchTypeOf() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toMatchTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toMatchTypeOf() + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data.value).toEqualTypeOf() + expectTypeOf(error.value).toEqualTypeOf() + expectTypeOf(variables.value).toMatchTypeOf< + SignTypedDataVariables | undefined + >() + expectTypeOf(context.value).toEqualTypeOf() + + signTypedData( + { + types: typedData.basic.types, + primaryType: 'Person', + message: { + name: 'Bob', + wallet: '0x', + }, + }, + { + onError(error, variables, context) { + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf<{ + types: typeof typedData.basic.types + primaryType: 'Person' + message: { + name: string + wallet: `0x${string}` + } + }>() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf<{ + types: typeof typedData.basic.types + primaryType: 'Person' + message: { + name: string + wallet: `0x${string}` + } + }>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toMatchTypeOf<{ + types: typeof typedData.basic.types + primaryType: 'Person' + message: { + name: string + wallet: `0x${string}` + } + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/vue/src/composables/useSignTypedData.test.ts b/packages/vue/src/composables/useSignTypedData.test.ts new file mode 100644 index 0000000000..e3636d21eb --- /dev/null +++ b/packages/vue/src/composables/useSignTypedData.test.ts @@ -0,0 +1,56 @@ +import { connect, disconnect, getAccount } from '@wagmi/core' +import { config, privateKey, typedData } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { recoverTypedDataAddress } from 'viem' +import { expect, test } from 'vitest' + +import { privateKeyToAccount } from 'viem/accounts' +import { useSignTypedData } from './useSignTypedData.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const [result] = renderComposable(() => useSignTypedData()) + + result.signTypedData({ + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + }) + await waitFor(result.isSuccess) + + await expect( + recoverTypedDataAddress({ + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + signature: result.data.value!, + }), + ).resolves.toEqual(getAccount(config).address) + + await disconnect(config, { connector }) +}) + +test('behavior: local account', async () => { + const [result] = renderComposable(() => useSignTypedData()) + + const account = privateKeyToAccount(privateKey) + result.signTypedData({ + account, + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + }) + await waitFor(result.isSuccess) + + await expect( + recoverTypedDataAddress({ + types: typedData.basic.types, + primaryType: 'Mail', + message: typedData.basic.message, + signature: result.data.value!, + }), + ).resolves.toEqual(account.address) +}) diff --git a/packages/vue/src/composables/useSignTypedData.ts b/packages/vue/src/composables/useSignTypedData.ts new file mode 100644 index 0000000000..f0bdbf6c64 --- /dev/null +++ b/packages/vue/src/composables/useSignTypedData.ts @@ -0,0 +1,64 @@ +import type { SignTypedDataErrorType } from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type SignTypedDataData, + type SignTypedDataMutate, + type SignTypedDataMutateAsync, + type SignTypedDataVariables, + signTypedDataMutationOptions, +} from '@wagmi/core/query' + +import type { ConfigParameter } from '../types/properties.js' +import { + type UseMutationParameters, + type UseMutationReturnType, + useMutation, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseSignTypedDataParameters = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + SignTypedDataData, + SignTypedDataErrorType, + SignTypedDataVariables, + context + > + | undefined + } +> + +export type UseSignTypedDataReturnType = Compute< + UseMutationReturnType< + SignTypedDataData, + SignTypedDataErrorType, + SignTypedDataVariables, + context + > & { + signTypedData: SignTypedDataMutate + signTypedDataAsync: SignTypedDataMutateAsync + } +> + +/** https://wagmi.sh/vue/api/composables/useSignTypedData */ +export function useSignTypedData( + parameters: UseSignTypedDataParameters = {}, +): UseSignTypedDataReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = signTypedDataMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + type Return = UseSignTypedDataReturnType + return { + ...result, + signTypedData: mutate as Return['signTypedData'], + signTypedDataAsync: mutateAsync as Return['signTypedDataAsync'], + } +} diff --git a/packages/vue/src/composables/useSimulateContract.test-d.ts b/packages/vue/src/composables/useSimulateContract.test-d.ts new file mode 100644 index 0000000000..e8d2451caa --- /dev/null +++ b/packages/vue/src/composables/useSimulateContract.test-d.ts @@ -0,0 +1,96 @@ +import { abi, type config } from '@wagmi/test' +import type { Address } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { + type UseSimulateContractReturnType, + useSimulateContract, +} from './useSimulateContract.js' + +test('default', () => { + const result = useSimulateContract({ + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + }) + + expectTypeOf(result.data.value).toMatchTypeOf< + | { + result: boolean + request: { + chainId?: undefined + abi: readonly [ + { + readonly name: 'transferFrom' + readonly type: 'function' + readonly stateMutability: 'nonpayable' + readonly inputs: readonly [ + { readonly type: 'address'; readonly name: 'sender' }, + { readonly type: 'address'; readonly name: 'recipient' }, + { readonly type: 'uint256'; readonly name: 'amount' }, + ] + readonly outputs: readonly [{ type: 'bool' }] + }, + ] + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + } + } + | undefined + >() +}) + +test('select data', () => { + // @ts-ignore TODO: Type instantiation is excessively deep and possibly infinite. + const result = useSimulateContract({ + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 1, + query: { + select(data) { + expectTypeOf(data.result).toEqualTypeOf() + return data.request.args + }, + }, + }) + expectTypeOf(result.data.value).toEqualTypeOf< + readonly [Address, Address, bigint] | undefined + >() +}) + +test('UseSimulateContractReturnType', () => { + type Result = UseSimulateContractReturnType< + typeof abi.erc20, + 'transferFrom', + ['0x', '0x', 123n], + typeof config, + 1 + > + expectTypeOf().toMatchTypeOf< + | { + result: boolean + request: { + chainId: number + abi: readonly [ + { + readonly name: 'transferFrom' + readonly type: 'function' + readonly stateMutability: 'nonpayable' + readonly inputs: readonly [ + { readonly type: 'address'; readonly name: 'sender' }, + { readonly type: 'address'; readonly name: 'recipient' }, + { readonly type: 'uint256'; readonly name: 'amount' }, + ] + readonly outputs: readonly [{ type: 'bool' }] + }, + ] + functionName: 'approve' | 'transfer' | 'transferFrom' + args: readonly [Address, Address, bigint] + } + } + | undefined + >() +}) diff --git a/packages/vue/src/composables/useSimulateContract.test.ts b/packages/vue/src/composables/useSimulateContract.test.ts new file mode 100644 index 0000000000..1118a51d68 --- /dev/null +++ b/packages/vue/src/composables/useSimulateContract.test.ts @@ -0,0 +1,59 @@ +import { connect, disconnect } from '@wagmi/core' +import { abi, address, config, wait } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { useSimulateContract } from './useSimulateContract.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const [result] = renderComposable(() => + useSimulateContract({ + address: address.wagmiMintExample, + abi: abi.wagmiMintExample, + functionName: 'mint', + }), + ) + + await waitFor(result.isSuccess) + + expect(result.data.value).toMatchInlineSnapshot(` + { + "chainId": 1, + "request": { + "abi": [ + { + "inputs": [], + "name": "mint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function", + }, + ], + "account": { + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", + "type": "json-rpc", + }, + "address": "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", + "args": undefined, + "chainId": 1, + "dataSuffix": undefined, + "functionName": "mint", + }, + "result": undefined, + } + `) + + await disconnect(config, { connector }) +}) + +test('behavior: disabled when properties missing', async () => { + const [result] = renderComposable(() => useSimulateContract()) + + await wait(100) + + expect(result.fetchStatus.value).toBe('idle') +}) diff --git a/packages/vue/src/composables/useSimulateContract.ts b/packages/vue/src/composables/useSimulateContract.ts new file mode 100644 index 0000000000..7ffce57b8e --- /dev/null +++ b/packages/vue/src/composables/useSimulateContract.ts @@ -0,0 +1,145 @@ +import type { + Config, + ResolvedRegister, + SimulateContractErrorType, +} from '@wagmi/core' +import { + type SimulateContractData, + type SimulateContractOptions, + type SimulateContractQueryFnData, + type SimulateContractQueryKey, + simulateContractQueryOptions, +} from '@wagmi/core/query' +import type { Abi, ContractFunctionArgs, ContractFunctionName } from 'viem' +import { type MaybeRef, computed } from 'vue' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' +import { useConnectorClient } from './useConnectorClient.js' + +export type UseSimulateContractParameters< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'nonpayable' | 'payable' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + > = ContractFunctionArgs, + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = SimulateContractData, +> = MaybeRef< + DeepMaybeRef< + SimulateContractOptions + > & + ConfigParameter & + QueryParameter< + SimulateContractQueryFnData, + SimulateContractErrorType, + selectData, + SimulateContractQueryKey + > +> + +export type UseSimulateContractReturnType< + abi extends Abi | readonly unknown[] = Abi, + functionName extends ContractFunctionName< + abi, + 'nonpayable' | 'payable' + > = ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + > = ContractFunctionArgs, + config extends Config = Config, + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = SimulateContractData, +> = UseQueryReturnType + +/** https://wagmi.sh/vue/api/composables/useSimulateContract */ +export function useSimulateContract< + const abi extends Abi | readonly unknown[], + functionName extends ContractFunctionName, + args extends ContractFunctionArgs< + abi, + 'nonpayable' | 'payable', + functionName + >, + config extends Config = ResolvedRegister['config'], + chainId extends config['chains'][number]['id'] | undefined = undefined, + selectData = SimulateContractData, +>( + parameters_: UseSimulateContractParameters< + abi, + functionName, + args, + config, + chainId, + selectData + > = {} as any, +): UseSimulateContractReturnType< + abi, + functionName, + args, + config, + chainId, + selectData +> { + const parameters = computed(() => deepUnref(parameters_)) as any + + const config = useConfig(parameters) + const { data: connectorClient } = useConnectorClient( + computed(() => ({ + connector: parameters.value.connector, + query: { enabled: parameters.value.account === undefined }, + })), + ) + const configChainId = useChainId({ config }) + + const queryOptions = computed(() => { + const { + abi, + account = connectorClient?.value?.account, + address, + chainId = configChainId.value, + functionName, + query = {}, + } = parameters.value + const options = simulateContractQueryOptions< + config, + abi, + functionName, + args, + chainId + >(config as any, { + ...parameters.value, + account, + chainId, + }) + const enabled = Boolean( + abi && address && functionName && (query.enabled ?? true), + ) + return { + ...query, + ...options, + enabled, + } + }) + + return useQuery(queryOptions as any) as UseSimulateContractReturnType< + abi, + functionName, + args, + config, + chainId, + selectData + > +} diff --git a/packages/vue/src/composables/useSwitchAccount.test-d.ts b/packages/vue/src/composables/useSwitchAccount.test-d.ts new file mode 100644 index 0000000000..d55e4b9d5e --- /dev/null +++ b/packages/vue/src/composables/useSwitchAccount.test-d.ts @@ -0,0 +1,89 @@ +import type { Connector, SwitchAccountErrorType } from '@wagmi/core' +import { config } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import type { Address } from 'viem' +import { useSwitchAccount } from './useSwitchAccount.js' + +const connector = config.connectors[0]! +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { context, data, error, switchAccount, variables } = useSwitchAccount({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + expectTypeOf(data).toEqualTypeOf<{ + accounts: readonly [Address, ...Address[]] + chainId: number + }>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(data.value).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + } + | undefined + >() + expectTypeOf(error.value).toEqualTypeOf() + expectTypeOf(variables.value).toEqualTypeOf< + { connector: Connector } | undefined + >() + expectTypeOf(context.value).toEqualTypeOf() + + switchAccount( + { connector }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + expectTypeOf(data).toEqualTypeOf<{ + accounts: readonly [Address, ...Address[]] + chainId: number + }>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf< + | { + accounts: readonly [Address, ...Address[]] + chainId: number + } + | undefined + >() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ connector: Connector }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/vue/src/composables/useSwitchAccount.test.ts b/packages/vue/src/composables/useSwitchAccount.test.ts new file mode 100644 index 0000000000..aade28e3d2 --- /dev/null +++ b/packages/vue/src/composables/useSwitchAccount.test.ts @@ -0,0 +1,42 @@ +import { connect, disconnect } from '@wagmi/core' +import { config } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { useAccount } from './useAccount.js' +import { useSwitchAccount } from './useSwitchAccount.js' + +const connector1 = config.connectors[0]! +const connector2 = config.connectors[1]! + +test('default', async () => { + const [account] = renderComposable(() => useAccount()) + const [switchAccount] = renderComposable(() => useSwitchAccount()) + + expect(switchAccount.connectors.value).toEqual([]) + + await connect(config, { connector: connector2 }) + await connect(config, { connector: connector1 }) + + expect(switchAccount.connectors.value.length).toEqual(2) + + const address1 = account.address.value + expect(address1).toBeDefined() + + switchAccount.switchAccount({ connector: connector2 }) + await waitFor(switchAccount.isSuccess) + + const address2 = account.address.value + expect(address2).toBeDefined() + expect(address1).not.toBe(address2) + + switchAccount.switchAccount({ connector: connector1 }) + await waitFor(switchAccount.isSuccess) + + const address3 = account.address.value + expect(address3).toBeDefined() + expect(address1).toBe(address3) + + await disconnect(config, { connector: connector1 }) + await disconnect(config, { connector: connector2 }) +}) diff --git a/packages/vue/src/composables/useSwitchAccount.ts b/packages/vue/src/composables/useSwitchAccount.ts new file mode 100644 index 0000000000..0c8f76a486 --- /dev/null +++ b/packages/vue/src/composables/useSwitchAccount.ts @@ -0,0 +1,84 @@ +import { useMutation } from '@tanstack/vue-query' +import type { + Config, + Connector, + ResolvedRegister, + SwitchAccountErrorType, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type SwitchAccountData, + type SwitchAccountMutate, + type SwitchAccountMutateAsync, + type SwitchAccountVariables, + switchAccountMutationOptions, +} from '@wagmi/core/query' +import { type Ref, computed } from 'vue' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' +import { useConnections } from './useConnections.js' + +export type UseSwitchAccountParameters< + config extends Config = Config, + context = unknown, +> = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + SwitchAccountData, + SwitchAccountErrorType, + SwitchAccountVariables, + context + > + | undefined + } +> + +export type UseSwitchAccountReturnType< + config extends Config = Config, + context = unknown, +> = Compute< + UseMutationReturnType< + SwitchAccountData, + SwitchAccountErrorType, + SwitchAccountVariables, + context + > & { + connectors: Ref + switchAccount: SwitchAccountMutate + switchAccountAsync: SwitchAccountMutateAsync + } +> + +/** https://wagmi.sh/vue/api/composables/useSwitchAccount */ +export function useSwitchAccount< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseSwitchAccountParameters = {}, +): UseSwitchAccountReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + const connections = useConnections({ config }) + + const mutationOptions = switchAccountMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + return { + ...result, + connectors: computed(() => + connections.value.map((connection) => connection.connector), + ), + switchAccount: mutate, + switchAccountAsync: mutateAsync, + } +} diff --git a/packages/vue/src/composables/useSwitchChain.test-d.ts b/packages/vue/src/composables/useSwitchChain.test-d.ts new file mode 100644 index 0000000000..e770460946 --- /dev/null +++ b/packages/vue/src/composables/useSwitchChain.test-d.ts @@ -0,0 +1,118 @@ +import type { Connector, SwitchChainErrorType } from '@wagmi/core' +import type { Chain } from '@wagmi/core/chains' +import type { Compute, ExactPartial } from '@wagmi/core/internal' +import { chain } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import type { AddEthereumChainParameter } from 'viem' +import { useSwitchChain } from './useSwitchChain.js' + +const chainId = chain.mainnet.id +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { chains, context, data, error, switchChain, variables } = + useSwitchChain({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + expectTypeOf(data).toEqualTypeOf>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf | undefined>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + }) + + expectTypeOf(chains.value).toEqualTypeOf() + expectTypeOf(data.value).toEqualTypeOf | undefined>() + expectTypeOf(error.value).toEqualTypeOf() + expectTypeOf(variables.value).toEqualTypeOf< + | { + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + } + | undefined + >() + expectTypeOf(context.value).toEqualTypeOf() + + switchChain( + { chainId }, + { + onError(error, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + }, + onSuccess(data, variables, context) { + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + expectTypeOf(data).toEqualTypeOf>() + expectTypeOf(context).toEqualTypeOf() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf | undefined>() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(variables).toEqualTypeOf<{ + addEthereumChainParameter?: + | ExactPartial> + | undefined + chainId: number + connector?: Connector | undefined + }>() + expectTypeOf(context).toEqualTypeOf() + }, + }, + ) +}) diff --git a/packages/vue/src/composables/useSwitchChain.test.ts b/packages/vue/src/composables/useSwitchChain.test.ts new file mode 100644 index 0000000000..12e7c21c2e --- /dev/null +++ b/packages/vue/src/composables/useSwitchChain.test.ts @@ -0,0 +1,35 @@ +import { connect, disconnect } from '@wagmi/core' +import { chain, config } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { useAccount } from './useAccount.js' +import { useSwitchChain } from './useSwitchChain.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const [account] = renderComposable(() => useAccount()) + const [switchChain] = renderComposable(() => useSwitchChain()) + + const chainId1 = account.chainId.value + expect(chainId1).toBeDefined() + + switchChain.switchChain({ chainId: chain.mainnet2.id }) + await waitFor(switchChain.isSuccess) + + const chainId2 = account.chainId.value + expect(chainId2).toBeDefined() + expect(chainId1).not.toBe(chainId2) + + switchChain.switchChain({ chainId: chain.mainnet.id }) + await waitFor(switchChain.isSuccess) + + const chainId3 = account.chainId.value + expect(chainId3).toBeDefined() + expect(chainId1).toBe(chainId3) + + await disconnect(config, { connector }) +}) diff --git a/packages/vue/src/composables/useSwitchChain.ts b/packages/vue/src/composables/useSwitchChain.ts new file mode 100644 index 0000000000..8ff43c0fa9 --- /dev/null +++ b/packages/vue/src/composables/useSwitchChain.ts @@ -0,0 +1,81 @@ +import { useMutation } from '@tanstack/vue-query' +import type { + Config, + ResolvedRegister, + SwitchChainErrorType, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type SwitchChainData, + type SwitchChainMutate, + type SwitchChainMutateAsync, + type SwitchChainVariables, + switchChainMutationOptions, +} from '@wagmi/core/query' +import type { Ref } from 'vue' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useChains } from './useChains.js' +import { useConfig } from './useConfig.js' + +export type UseSwitchChainParameters< + config extends Config = Config, + context = unknown, +> = Compute< + ConfigParameter & { + mutation?: + | UseMutationParameters< + SwitchChainData, + SwitchChainErrorType, + SwitchChainVariables, + context + > + | undefined + } +> + +export type UseSwitchChainReturnType< + config extends Config = Config, + context = unknown, +> = Compute< + UseMutationReturnType< + SwitchChainData, + SwitchChainErrorType, + SwitchChainVariables, + context + > & { + chains: Ref + switchChain: SwitchChainMutate + switchChainAsync: SwitchChainMutateAsync + } +> + +/** https://wagmi.sh/vue/api/composables/useSwitchChain */ +export function useSwitchChain< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseSwitchChainParameters = {}, +): UseSwitchChainReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = switchChainMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + type Return = UseSwitchChainReturnType + return { + ...result, + chains: useChains({ config }) as unknown as Ref, + switchChain: mutate as Return['switchChain'], + switchChainAsync: mutateAsync as Return['switchChainAsync'], + } as Return +} diff --git a/packages/vue/src/composables/useTransaction.test-d.ts b/packages/vue/src/composables/useTransaction.test-d.ts new file mode 100644 index 0000000000..bb795814e8 --- /dev/null +++ b/packages/vue/src/composables/useTransaction.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useTransaction } from './useTransaction.js' + +test('select data', () => { + const result = useTransaction({ + query: { + select(data) { + return data?.nonce + }, + }, + }) + expectTypeOf(result.data.value).toEqualTypeOf() +}) diff --git a/packages/vue/src/composables/useTransaction.test.ts b/packages/vue/src/composables/useTransaction.test.ts new file mode 100644 index 0000000000..06659958f2 --- /dev/null +++ b/packages/vue/src/composables/useTransaction.test.ts @@ -0,0 +1,74 @@ +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { deepUnref } from '../utils/cloneDeep.js' +import { useTransaction } from './useTransaction.js' + +test('default', async () => { + const [result] = renderComposable(() => + useTransaction({ + hash: '0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30', + }), + ) + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": { + "accessList": [], + "blockHash": "0xd725a38b51e5ceec8c5f6c9ccfdb2cc423af993bb650af5eedca5e4be7156ba7", + "blockNumber": 15189204n, + "chainId": 1, + "from": "0xa0cf798816d4b9b9866b5330eea46a18382f251e", + "gas": 21000n, + "gasPrice": 9371645552n, + "hash": "0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30", + "input": "0x", + "maxFeePerGas": 13644824566n, + "maxPriorityFeePerGas": 1500000000n, + "nonce": 86, + "r": "0x40174f9a38df876c1a7ce2587848819d4082ccd6d67a88aa5cabe59bf594e14f", + "s": "0x7c0c82f62a8a5a9b0e9cf30a54a72fdae8fc54b5b79ddafef0acd30e94e83872", + "to": "0xd2135cfb216b74109775236e36d4b433f1df507b", + "transactionIndex": 144, + "type": "eip1559", + "typeHex": "0x2", + "v": 0n, + "value": 100000000000000000n, + "yParity": 0, + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "transaction", + { + "chainId": 1, + "hash": "0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30", + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) diff --git a/packages/vue/src/composables/useTransaction.ts b/packages/vue/src/composables/useTransaction.ts new file mode 100644 index 0000000000..eea49e68c1 --- /dev/null +++ b/packages/vue/src/composables/useTransaction.ts @@ -0,0 +1,91 @@ +import type { + Config, + GetTransactionErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetTransactionData, + type GetTransactionOptions, + type GetTransactionQueryFnData, + type GetTransactionQueryKey, + getTransactionQueryOptions, +} from '@wagmi/core/query' + +import { computed } from 'vue' +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseTransactionParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetTransactionData, +> = Compute< + DeepMaybeRef< + GetTransactionOptions & + ConfigParameter & + QueryParameter< + GetTransactionQueryFnData, + GetTransactionErrorType, + selectData, + GetTransactionQueryKey + > + > +> + +export type UseTransactionReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetTransactionData, +> = UseQueryReturnType + +/** https://wagmi.sh/vue/api/composables/useTransaction */ +export function useTransaction< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetTransactionData, +>( + parameters_: UseTransactionParameters = {}, +): UseTransactionReturnType { + const parameters = computed(() => deepUnref(parameters_)) + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + + const queryOptions = computed(() => { + const { + blockHash, + blockNumber, + blockTag, + chainId = configChainId.value, + hash, + query = {}, + } = parameters.value + const options = getTransactionQueryOptions(config, { + ...parameters.value, + chainId, + }) + const enabled = Boolean( + !(blockHash && blockNumber && blockTag && hash) && + (query.enabled ?? true), + ) + return { + ...query, + ...options, + enabled, + } + }) + + return useQuery(queryOptions as any) as UseTransactionReturnType< + config, + chainId, + selectData + > +} diff --git a/packages/vue/src/composables/useTransactionReceipt.test-d.ts b/packages/vue/src/composables/useTransactionReceipt.test-d.ts new file mode 100644 index 0000000000..180d8354d8 --- /dev/null +++ b/packages/vue/src/composables/useTransactionReceipt.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useTransactionReceipt } from './useTransactionReceipt.js' + +test('select data', () => { + const result = useTransactionReceipt({ + query: { + select(data) { + return data?.blockNumber + }, + }, + }) + expectTypeOf(result.data.value).toEqualTypeOf() +}) diff --git a/packages/vue/src/composables/useTransactionReceipt.test.ts b/packages/vue/src/composables/useTransactionReceipt.test.ts new file mode 100644 index 0000000000..0092671427 --- /dev/null +++ b/packages/vue/src/composables/useTransactionReceipt.test.ts @@ -0,0 +1,208 @@ +import { chain, wait } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' +import { ref } from 'vue' +import { deepUnref } from '../utils/cloneDeep.js' +import { useTransactionReceipt } from './useTransactionReceipt.js' + +test('default', async () => { + const [result] = renderComposable(() => + useTransactionReceipt({ + hash: '0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871', + }), + ) + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": { + "blockHash": "0xb932f77cf770d1d1c8f861153eec1e990f5d56b6ffdb4ac06aef3cca51ef37d4", + "blockNumber": 16280769n, + "contractAddress": null, + "cumulativeGasUsed": 21000n, + "effectiveGasPrice": 33427926161n, + "from": "0x043022ef9fca1066024d19d681e2ccf44ff90de3", + "gasUsed": 21000n, + "logs": [], + "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "status": "success", + "to": "0x318a5fb4f1604fc46375a1db9a9018b6e423b345", + "transactionHash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + "transactionIndex": 0, + "type": "legacy", + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getTransactionReceipt", + { + "chainId": 1, + "hash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) + +test('parameters: chainId', async () => { + const [result] = renderComposable(() => + useTransactionReceipt({ + chainId: chain.mainnet2.id, + hash: '0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871', + }), + ) + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": { + "blockHash": "0xb932f77cf770d1d1c8f861153eec1e990f5d56b6ffdb4ac06aef3cca51ef37d4", + "blockNumber": 16280769n, + "contractAddress": null, + "cumulativeGasUsed": 21000n, + "effectiveGasPrice": 33427926161n, + "from": "0x043022ef9fca1066024d19d681e2ccf44ff90de3", + "gasUsed": 21000n, + "logs": [], + "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "status": "success", + "to": "0x318a5fb4f1604fc46375a1db9a9018b6e423b345", + "transactionHash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + "transactionIndex": 0, + "type": "legacy", + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getTransactionReceipt", + { + "chainId": 456, + "hash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) + +test('behavior: hash: undefined -> defined', async () => { + const hash = ref() + + const [result] = renderComposable(() => + useTransactionReceipt({ + hash, + }), + ) + + await wait(100) + expect(result.fetchStatus.value).toBe('idle') + + hash.value = + '0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871' + + await waitFor(result.isSuccess) + + expect(deepUnref(result)).toMatchInlineSnapshot(` + { + "data": { + "blockHash": "0xb932f77cf770d1d1c8f861153eec1e990f5d56b6ffdb4ac06aef3cca51ef37d4", + "blockNumber": 16280769n, + "contractAddress": null, + "cumulativeGasUsed": 21000n, + "effectiveGasPrice": 33427926161n, + "from": "0x043022ef9fca1066024d19d681e2ccf44ff90de3", + "gasUsed": 21000n, + "logs": [], + "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "status": "success", + "to": "0x318a5fb4f1604fc46375a1db9a9018b6e423b345", + "transactionHash": "0xbf7d27700d053765c9638d3b9d39eb3c56bfc48377583e8be483d61f9f18a871", + "transactionIndex": 0, + "type": "legacy", + }, + "dataUpdatedAt": 1675209600000, + "error": null, + "errorUpdateCount": 0, + "errorUpdatedAt": 0, + "failureCount": 0, + "failureReason": null, + "fetchStatus": "idle", + "isError": false, + "isFetched": true, + "isFetchedAfterMount": true, + "isFetching": false, + "isInitialLoading": false, + "isLoading": false, + "isLoadingError": false, + "isPaused": false, + "isPending": false, + "isPlaceholderData": false, + "isRefetchError": false, + "isRefetching": false, + "isStale": true, + "isSuccess": true, + "queryKey": [ + "getTransactionReceipt", + { + "chainId": 1, + "hash": undefined, + }, + ], + "refetch": [Function], + "status": "success", + "suspense": [Function], + } + `) +}) + +test('behavior: disabled when properties missing', async () => { + const [result] = renderComposable(() => useTransactionReceipt()) + + await wait(100) + expect(result.fetchStatus.value).toBe('idle') +}) diff --git a/packages/vue/src/composables/useTransactionReceipt.ts b/packages/vue/src/composables/useTransactionReceipt.ts new file mode 100644 index 0000000000..cba5c232ae --- /dev/null +++ b/packages/vue/src/composables/useTransactionReceipt.ts @@ -0,0 +1,85 @@ +import type { + Config, + GetTransactionReceiptErrorType, + ResolvedRegister, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type GetTransactionReceiptData, + type GetTransactionReceiptOptions, + type GetTransactionReceiptQueryKey, + getTransactionReceiptQueryOptions, +} from '@wagmi/core/query' +import type { GetTransactionReceiptQueryFnData } from '@wagmi/core/query' + +import { computed } from 'vue' +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseTransactionReceiptParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetTransactionReceiptData, +> = Compute< + DeepMaybeRef< + GetTransactionReceiptOptions & + ConfigParameter & + QueryParameter< + GetTransactionReceiptQueryFnData, + GetTransactionReceiptErrorType, + selectData, + GetTransactionReceiptQueryKey + > + > +> + +export type UseTransactionReceiptReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetTransactionReceiptData, +> = UseQueryReturnType + +/** https://wagmi.sh/vue/api/composables/useTransactionReceipt */ +export function useTransactionReceipt< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = GetTransactionReceiptData, +>( + parameters_: UseTransactionReceiptParameters< + config, + chainId, + selectData + > = {}, +): UseTransactionReceiptReturnType { + const parameters = computed(() => deepUnref(parameters_)) + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + + const queryOptions = computed(() => { + const { chainId = configChainId.value, hash, query = {} } = parameters.value + const options = getTransactionReceiptQueryOptions(config, { + ...parameters.value, + chainId, + }) + const enabled = Boolean(hash && (query.enabled ?? true)) + return { + ...(query as any), + ...options, + enabled, + } + }) + + return useQuery(queryOptions) as UseTransactionReceiptReturnType< + config, + chainId, + selectData + > +} diff --git a/packages/vue/src/composables/useWaitForTransactionReceipt.test-d.ts b/packages/vue/src/composables/useWaitForTransactionReceipt.test-d.ts new file mode 100644 index 0000000000..aa5dcad64f --- /dev/null +++ b/packages/vue/src/composables/useWaitForTransactionReceipt.test-d.ts @@ -0,0 +1,14 @@ +import { expectTypeOf, test } from 'vitest' + +import { useWaitForTransactionReceipt } from './useWaitForTransactionReceipt.js' + +test('select data', () => { + const result = useWaitForTransactionReceipt({ + query: { + select(data) { + return data?.blockNumber + }, + }, + }) + expectTypeOf(result.data.value).toEqualTypeOf() +}) diff --git a/packages/vue/src/composables/useWaitForTransactionReceipt.test.ts b/packages/vue/src/composables/useWaitForTransactionReceipt.test.ts new file mode 100644 index 0000000000..3cfcbe0feb --- /dev/null +++ b/packages/vue/src/composables/useWaitForTransactionReceipt.test.ts @@ -0,0 +1,46 @@ +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' +import { wait } from '../../../test/src/utils.js' +import { useWaitForTransactionReceipt } from './useWaitForTransactionReceipt.js' + +test('default', async () => { + const [result] = renderComposable(() => + useWaitForTransactionReceipt({ + hash: '0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30', + }), + ) + + await waitFor(result.isSuccess) + + expect(result.data.value).toMatchInlineSnapshot(` + { + "blockHash": "0xd725a38b51e5ceec8c5f6c9ccfdb2cc423af993bb650af5eedca5e4be7156ba7", + "blockNumber": 15189204n, + "chainId": 1, + "contractAddress": null, + "cumulativeGasUsed": 12949744n, + "effectiveGasPrice": 9371645552n, + "from": "0xa0cf798816d4b9b9866b5330eea46a18382f251e", + "gasUsed": 21000n, + "logs": [], + "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "status": "success", + "to": "0xd2135cfb216b74109775236e36d4b433f1df507b", + "transactionHash": "0x60668ed8c2dc110d61d945a936fcd45b8f13654e5c78481c8c825d1148c7ef30", + "transactionIndex": 144, + "type": "eip1559", + } + `) +}) + +test('disabled when hash is undefined', async () => { + const [result] = renderComposable(() => + useWaitForTransactionReceipt({ + hash: undefined, + }), + ) + + await wait(100) + + expect(result.isPending.value).toBe(true) +}) diff --git a/packages/vue/src/composables/useWaitForTransactionReceipt.ts b/packages/vue/src/composables/useWaitForTransactionReceipt.ts new file mode 100644 index 0000000000..6aea7d8e06 --- /dev/null +++ b/packages/vue/src/composables/useWaitForTransactionReceipt.ts @@ -0,0 +1,84 @@ +import type { + Config, + ResolvedRegister, + WaitForTransactionReceiptErrorType, +} from '@wagmi/core' +import type { Compute } from '@wagmi/core/internal' +import { + type WaitForTransactionReceiptData, + type WaitForTransactionReceiptOptions, + type WaitForTransactionReceiptQueryFnData, + type WaitForTransactionReceiptQueryKey, + waitForTransactionReceiptQueryOptions, +} from '@wagmi/core/query' +import { computed } from 'vue' + +import type { ConfigParameter, QueryParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { type UseQueryReturnType, useQuery } from '../utils/query.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseWaitForTransactionReceiptParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = WaitForTransactionReceiptData, +> = Compute< + DeepMaybeRef< + WaitForTransactionReceiptOptions & + ConfigParameter & + QueryParameter< + WaitForTransactionReceiptQueryFnData, + WaitForTransactionReceiptErrorType, + selectData, + WaitForTransactionReceiptQueryKey + > + > +> + +export type UseWaitForTransactionReceiptReturnType< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = WaitForTransactionReceiptData, +> = UseQueryReturnType + +/** https://wagmi.sh/vue/api/composables/useWaitForTransactionReceipt */ +export function useWaitForTransactionReceipt< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], + selectData = WaitForTransactionReceiptData, +>( + parameters_: UseWaitForTransactionReceiptParameters< + config, + chainId, + selectData + > = {}, +): UseWaitForTransactionReceiptReturnType { + const parameters = computed(() => deepUnref(parameters_)) + const config = useConfig(parameters_) + const configChainId = useChainId() + + const queryOptions = computed(() => { + const { chainId = configChainId.value, hash, query = {} } = parameters.value + + const options = waitForTransactionReceiptQueryOptions(config, { + ...parameters.value, + chainId, + }) + const enabled = Boolean(hash && (query.enabled ?? true)) + + return { + ...query, + ...options, + enabled, + } + }) + + return useQuery( + queryOptions as any, + ) as UseWaitForTransactionReceiptReturnType +} diff --git a/packages/vue/src/composables/useWatchBlockNumber.test-d.ts b/packages/vue/src/composables/useWatchBlockNumber.test-d.ts new file mode 100644 index 0000000000..6ab0347168 --- /dev/null +++ b/packages/vue/src/composables/useWatchBlockNumber.test-d.ts @@ -0,0 +1,75 @@ +import { createConfig } from '@wagmi/core' +import { http, webSocket } from 'viem' +import { mainnet, optimism } from 'viem/chains' +import { expectTypeOf, test } from 'vitest' + +import type { DeepUnwrapRef } from '../types/ref.js' +import { + type UseWatchBlockNumberParameters, + useWatchBlockNumber, +} from './useWatchBlockNumber.js' + +test('default', () => { + useWatchBlockNumber({ + poll: false, + onBlockNumber() {}, + }) +}) + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + type Result = DeepUnwrapRef< + UseWatchBlockNumberParameters< + typeof config, + typeof mainnet.id | typeof optimism.id + > + > + expectTypeOf().toEqualTypeOf() + useWatchBlockNumber({ + config, + poll: false, + onBlockNumber() {}, + }) + + type Result2 = DeepUnwrapRef< + UseWatchBlockNumberParameters + > + expectTypeOf().toEqualTypeOf() + useWatchBlockNumber({ + config, + chainId: mainnet.id, + poll: true, + onBlockNumber() {}, + }) + useWatchBlockNumber({ + config, + chainId: mainnet.id, + // @ts-expect-error + poll: false, + onBlockNumber() {}, + }) + + type Result3 = DeepUnwrapRef< + UseWatchBlockNumberParameters + > + expectTypeOf().toEqualTypeOf() + useWatchBlockNumber({ + config, + chainId: optimism.id, + poll: true, + onBlockNumber() {}, + }) + useWatchBlockNumber({ + config, + chainId: optimism.id, + poll: false, + onBlockNumber() {}, + }) +}) diff --git a/packages/vue/src/composables/useWatchBlockNumber.test.ts b/packages/vue/src/composables/useWatchBlockNumber.test.ts new file mode 100644 index 0000000000..1b074d766c --- /dev/null +++ b/packages/vue/src/composables/useWatchBlockNumber.test.ts @@ -0,0 +1,67 @@ +import { testClient, wait } from '@wagmi/test' +import { renderComposable } from '@wagmi/test/vue' +import { expect, test } from 'vitest' +import { ref } from 'vue' +import { useWatchBlockNumber } from './useWatchBlockNumber.js' + +test('default', async () => { + const blockNumbers: bigint[] = [] + renderComposable(() => + useWatchBlockNumber({ + onBlockNumber(blockNumber) { + blockNumbers.push(blockNumber) + }, + }), + ) + + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + + expect(blockNumbers.length).toBe(3) + expect( + blockNumbers.map((blockNumber) => blockNumber - blockNumbers[0]!), + ).toEqual([0n, 1n, 2n]) +}) + +test('parameters: enabled', async () => { + const enabled = ref(true) + + const blockNumbers: bigint[] = [] + renderComposable(() => + useWatchBlockNumber({ + enabled, + onBlockNumber(blockNumber) { + blockNumbers.push(blockNumber) + }, + }), + ) + + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + + expect(blockNumbers.length).toBe(3) + expect( + blockNumbers.map((blockNumber) => blockNumber - blockNumbers[0]!), + ).toEqual([0n, 1n, 2n]) + + enabled.value = false + + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + + expect( + blockNumbers.map((blockNumber) => blockNumber - blockNumbers[0]!), + ).toEqual([0n, 1n, 2n]) +}) diff --git a/packages/vue/src/composables/useWatchBlockNumber.ts b/packages/vue/src/composables/useWatchBlockNumber.ts new file mode 100644 index 0000000000..96dd437ec1 --- /dev/null +++ b/packages/vue/src/composables/useWatchBlockNumber.ts @@ -0,0 +1,63 @@ +import { + type Config, + type ResolvedRegister, + type WatchBlockNumberParameters, + watchBlockNumber, +} from '@wagmi/core' +import type { UnionCompute, UnionExactPartial } from '@wagmi/core/internal' +import { computed, watchEffect } from 'vue' + +import type { ConfigParameter, EnabledParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseWatchBlockNumberParameters< + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = DeepMaybeRef< + UnionCompute< + UnionExactPartial> & + ConfigParameter & + EnabledParameter + > +> + +export type UseWatchBlockNumberReturnType = void + +/** https://wagmi.sh/vue/api/composables/useWatchBlockNumber */ +export function useWatchBlockNumber< + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + parameters_: UseWatchBlockNumberParameters = {} as any, +): UseWatchBlockNumberReturnType { + const parameters = computed(() => deepUnref(parameters_)) + + const config = useConfig(parameters) + const configChainId = useChainId({ config }) + + watchEffect((onCleanup) => { + const { + chainId = configChainId.value, + enabled = true, + onBlockNumber, + config: _, + ...rest + } = parameters.value + + if (!enabled) return + if (!onBlockNumber) return + + const unwatch = watchBlockNumber(config, { + ...(rest as any), + chainId, + onBlockNumber, + emitOnBegin: true, + }) + onCleanup(unwatch) + }) +} diff --git a/packages/vue/src/composables/useWatchContractEvent.test-d.ts b/packages/vue/src/composables/useWatchContractEvent.test-d.ts new file mode 100644 index 0000000000..17568222dd --- /dev/null +++ b/packages/vue/src/composables/useWatchContractEvent.test-d.ts @@ -0,0 +1,126 @@ +import { http, createConfig, webSocket } from '@wagmi/core' +import { mainnet, optimism } from '@wagmi/core/chains' +import { abi } from '@wagmi/test' +import { expectTypeOf, test } from 'vitest' + +import { useWatchContractEvent } from './useWatchContractEvent.js' + +test('default', () => { + useWatchContractEvent({ + address: '0x', + abi: abi.erc20, + eventName: 'Transfer', + poll: false, + args: { + from: '0x', + to: '0x', + }, + onLogs(logs) { + expectTypeOf(logs[0]!.eventName).toEqualTypeOf<'Transfer'>() + expectTypeOf(logs[0]!.args).toEqualTypeOf<{ + from?: `0x${string}` | undefined + to?: `0x${string}` | undefined + value?: bigint | undefined + }>() + }, + }) +}) + +test('behavior: no eventName', () => { + useWatchContractEvent({ + address: '0x', + abi: abi.erc20, + args: { + // TODO: Figure out why this is not working + // @ts-ignore + from: '0x', + to: '0x', + }, + onLogs(logs) { + expectTypeOf(logs[0]!.eventName).toEqualTypeOf<'Transfer' | 'Approval'>() + expectTypeOf(logs[0]!.args).toEqualTypeOf< + | Record + | readonly unknown[] + | { + from?: `0x${string}` | undefined + to?: `0x${string}` | undefined + value?: bigint | undefined + } + | { + owner?: `0x${string}` | undefined + spender?: `0x${string}` | undefined + value?: bigint | undefined + } + >() + }, + }) +}) + +test('differing transports', () => { + const config = createConfig({ + chains: [mainnet, optimism], + transports: { + [mainnet.id]: http(), + [optimism.id]: webSocket(), + }, + }) + + // TODO: Fix inference for `poll` (`DeepMaybeRef` wrapping `UseWatchContractEventParameters` not working as expected) + // type Result = UseWatchContractEventParameters< + // typeof abi.erc20, + // 'Transfer' | 'Approval', + // true, + // typeof config, + // typeof mainnet.id | typeof optimism.id + // > + // expectTypeOf().toEqualTypeOf() + useWatchContractEvent({ + config, + poll: false, + address: '0x', + abi: abi.erc20, + onLogs() {}, + }) + + // type Result2 = UseWatchContractEventParameters< + // typeof abi.erc20, + // 'Transfer' | 'Approval', + // true, + // typeof config, + // typeof mainnet.id + // > + // expectTypeOf().toEqualTypeOf() + useWatchContractEvent({ + config, + chainId: mainnet.id, + poll: true, + address: '0x', + abi: abi.erc20, + onLogs() {}, + }) + + // type Result3 = UseWatchContractEventParameters< + // typeof abi.erc20, + // 'Transfer' | 'Approval', + // true, + // typeof config, + // typeof optimism.id + // > + // expectTypeOf().toEqualTypeOf() + useWatchContractEvent({ + config, + chainId: optimism.id, + poll: true, + address: '0x', + abi: abi.erc20, + onLogs() {}, + }) + useWatchContractEvent({ + config, + chainId: optimism.id, + poll: false, + address: '0x', + abi: abi.erc20, + onLogs() {}, + }) +}) diff --git a/packages/vue/src/composables/useWatchContractEvent.test.ts b/packages/vue/src/composables/useWatchContractEvent.test.ts new file mode 100644 index 0000000000..968c46d0cd --- /dev/null +++ b/packages/vue/src/composables/useWatchContractEvent.test.ts @@ -0,0 +1,106 @@ +import { connect, disconnect, getBalance, writeContract } from '@wagmi/core' +import { + abi, + accounts, + address, + config, + testClient, + transactionHashRegex, + wait, +} from '@wagmi/test' +import { renderComposable } from '@wagmi/test/vue' +import { http, createWalletClient, parseEther } from 'viem' +import type { WatchEventOnLogsParameter } from 'viem/actions' +import { expect, test } from 'vitest' + +import { ref } from 'vue' +import { useWatchContractEvent } from './useWatchContractEvent.js' + +const connector = config.connectors[0]! + +test('default', async () => { + const data = await connect(config, { connector }) + const connectedAddress = data.accounts[0] + + // impersonate usdc holder account and transfer usdc to connected account + await testClient.mainnet.impersonateAccount({ address: address.usdcHolder }) + await testClient.mainnet.setBalance({ + address: address.usdcHolder, + value: 10000000000000000000000n, + }) + await createWalletClient({ + account: address.usdcHolder, + chain: testClient.mainnet.chain, + transport: http(), + }).writeContract({ + address: address.usdc, + abi: abi.erc20, + functionName: 'transfer', + args: [connectedAddress, parseEther('10', 'gwei')], + }) + await testClient.mainnet.mine({ blocks: 1 }) + await testClient.mainnet.stopImpersonatingAccount({ + address: address.usdcHolder, + }) + + const balance = await getBalance(config, { + address: connectedAddress, + token: address.usdc, + }) + expect(balance.value).toBeGreaterThan(0n) + + // start watching transfer events + let logs: WatchEventOnLogsParameter = [] + renderComposable(() => + useWatchContractEvent({ + address: address.usdc, + abi: abi.erc20, + eventName: 'Transfer', + onLogs(next) { + logs = logs.concat(next) + }, + }), + ) + + await writeContract(config, { + address: address.usdc, + abi: abi.erc20, + functionName: 'transfer', + args: [accounts[1], parseEther('1', 'gwei')], + }) + + await writeContract(config, { + address: address.usdc, + abi: abi.erc20, + functionName: 'transfer', + args: [accounts[3], parseEther('1', 'gwei')], + }) + + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + await testClient.mainnet.mine({ blocks: 1 }) + await wait(100) + + expect(logs.length).toBe(2) + expect(logs[0]?.transactionHash).toMatch(transactionHashRegex) + + await disconnect(config, { connector }) +}) + +test('parameters: enabled', async () => { + const enabled = ref(true) + + renderComposable(() => + useWatchContractEvent({ + address: address.usdc, + abi: abi.erc20, + eventName: 'Transfer', + }), + ) + + renderComposable(() => + useWatchContractEvent({ + enabled, + }), + ) +}) diff --git a/packages/vue/src/composables/useWatchContractEvent.ts b/packages/vue/src/composables/useWatchContractEvent.ts new file mode 100644 index 0000000000..ffd988b40b --- /dev/null +++ b/packages/vue/src/composables/useWatchContractEvent.ts @@ -0,0 +1,77 @@ +import { + type Config, + type ResolvedRegister, + type WatchContractEventParameters, + watchContractEvent, +} from '@wagmi/core' +import type { UnionCompute, UnionExactPartial } from '@wagmi/core/internal' +import type { Abi, ContractEventName } from 'viem' +import { computed, watchEffect } from 'vue' + +import type { ConfigParameter, EnabledParameter } from '../types/properties.js' +import type { DeepMaybeRef } from '../types/ref.js' +import { deepUnref } from '../utils/cloneDeep.js' +import { useChainId } from './useChainId.js' +import { useConfig } from './useConfig.js' + +export type UseWatchContractEventParameters< + abi extends Abi | readonly unknown[] = Abi, + eventName extends ContractEventName = ContractEventName, + strict extends boolean | undefined = undefined, + config extends Config = Config, + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +> = DeepMaybeRef< + UnionCompute< + UnionExactPartial< + WatchContractEventParameters + > & + ConfigParameter & + EnabledParameter + > +> + +export type UseWatchContractEventReturnType = void + +/** https://wagmi.sh/vue/api/composables/useWatchContractEvent */ +export function useWatchContractEvent< + const abi extends Abi | readonly unknown[], + eventName extends ContractEventName, + strict extends boolean | undefined = undefined, + config extends Config = ResolvedRegister['config'], + chainId extends + config['chains'][number]['id'] = config['chains'][number]['id'], +>( + parameters: UseWatchContractEventParameters< + abi, + eventName, + strict, + config, + chainId + > = {} as any, +): UseWatchContractEventReturnType { + const parameters_ = computed(() => deepUnref(parameters)) + + const config = useConfig(parameters_) + const configChainId = useChainId({ config }) + + watchEffect((onCleanup) => { + const { + chainId = configChainId.value, + enabled = true, + onLogs, + config: _, + ...rest + } = parameters_.value + + if (!enabled) return + if (!onLogs) return + + const unwatch = watchContractEvent(config, { + ...(rest as any), + chainId, + onLogs, + }) + onCleanup(unwatch) + }) +} diff --git a/packages/vue/src/composables/useWriteContract.test-d.ts b/packages/vue/src/composables/useWriteContract.test-d.ts new file mode 100644 index 0000000000..33a9b14342 --- /dev/null +++ b/packages/vue/src/composables/useWriteContract.test-d.ts @@ -0,0 +1,136 @@ +import type { WriteContractErrorType } from '@wagmi/core' +import { abi } from '@wagmi/test' +import type { Abi, Address, Hash } from 'viem' +import { expectTypeOf, test } from 'vitest' + +import { useSimulateContract } from './useSimulateContract.js' +import { useWriteContract } from './useWriteContract.js' + +const contextValue = { foo: 'bar' } as const + +test('context', () => { + const { + context, + data, + error, + writeContract: write, + variables, + } = useWriteContract({ + mutation: { + onMutate(variables) { + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: Abi + functionName: string + args?: readonly unknown[] | undefined + }>() + return contextValue + }, + onError(error, variables, context) { + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: Abi + functionName: string + args?: readonly unknown[] | undefined + }>() + }, + onSuccess(data, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: Abi + functionName: string + args?: readonly unknown[] | undefined + }>() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: Abi + functionName: string + args?: readonly unknown[] | undefined + }>() + }, + }, + }) + + expectTypeOf(data.value).toEqualTypeOf() + expectTypeOf(error.value).toEqualTypeOf() + expectTypeOf(variables.value).toMatchTypeOf< + { chainId?: number | undefined } | undefined + >() + expectTypeOf(context.value).toEqualTypeOf() + + write( + { + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 1, + }, + { + onError(error, variables, context) { + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: typeof abi.erc20 + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + }>() + }, + onSuccess(data, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables.functionName).toEqualTypeOf<'transferFrom'>() + expectTypeOf(variables.args).toEqualTypeOf< + readonly [Address, Address, bigint] + >() + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: typeof abi.erc20 + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + }>() + }, + onSettled(data, error, variables, context) { + expectTypeOf(data).toEqualTypeOf() + expectTypeOf(error).toEqualTypeOf() + expectTypeOf(context).toEqualTypeOf() + + expectTypeOf(variables).toMatchTypeOf<{ + chainId?: number | undefined + abi: typeof abi.erc20 + functionName: 'transferFrom' + args: readonly [Address, Address, bigint] + }>() + }, + }, + ) +}) + +test('useSimulateContract', () => { + const { data } = useSimulateContract({ + address: '0x', + abi: abi.erc20, + functionName: 'transferFrom', + args: ['0x', '0x', 123n], + chainId: 1, + }) + const { writeContract } = useWriteContract() + + const request = data?.value?.request + if (request) writeContract(request) +}) diff --git a/packages/vue/src/composables/useWriteContract.test.ts b/packages/vue/src/composables/useWriteContract.test.ts new file mode 100644 index 0000000000..ba7c8cb4cb --- /dev/null +++ b/packages/vue/src/composables/useWriteContract.test.ts @@ -0,0 +1,25 @@ +import { connect, disconnect } from '@wagmi/core' +import { abi, address, config } from '@wagmi/test' +import { renderComposable, waitFor } from '@wagmi/test/vue' +import { expect, test } from 'vitest' + +import { useWriteContract } from './useWriteContract.js' + +const connector = config.connectors[0]! + +test('default', async () => { + await connect(config, { connector }) + + const [result] = renderComposable(() => useWriteContract()) + + result.writeContract({ + abi: abi.wagmiMintExample, + address: address.wagmiMintExample, + functionName: 'mint', + }) + await waitFor(result.isSuccess) + + expect(result.data.value).toBeDefined() + + await disconnect(config, { connector }) +}) diff --git a/packages/vue/src/composables/useWriteContract.ts b/packages/vue/src/composables/useWriteContract.ts new file mode 100644 index 0000000000..21ac3a82d4 --- /dev/null +++ b/packages/vue/src/composables/useWriteContract.ts @@ -0,0 +1,85 @@ +import { useMutation } from '@tanstack/vue-query' +import type { + Config, + ResolvedRegister, + WriteContractErrorType, +} from '@wagmi/core' +import { + type WriteContractData, + type WriteContractMutate, + type WriteContractMutateAsync, + type WriteContractVariables, + writeContractMutationOptions, +} from '@wagmi/core/query' +import type { Abi } from 'viem' + +import type { ConfigParameter } from '../types/properties.js' +import type { + UseMutationParameters, + UseMutationReturnType, +} from '../utils/query.js' +import { useConfig } from './useConfig.js' + +export type UseWriteContractParameters< + config extends Config = Config, + context = unknown, +> = ConfigParameter & { + mutation?: + | UseMutationParameters< + WriteContractData, + WriteContractErrorType, + WriteContractVariables< + Abi, + string, + readonly unknown[], + config, + config['chains'][number]['id'] + >, + context + > + | undefined +} + +export type UseWriteContractReturnType< + config extends Config = Config, + context = unknown, +> = UseMutationReturnType< + WriteContractData, + WriteContractErrorType, + WriteContractVariables< + Abi, + string, + readonly unknown[], + config, + config['chains'][number]['id'] + >, + context +> & { + writeContract: WriteContractMutate + writeContractAsync: WriteContractMutateAsync +} + +/** https://wagmi.sh/vue/api/composables/useWriteContract */ +export function useWriteContract< + config extends Config = ResolvedRegister['config'], + context = unknown, +>( + parameters: UseWriteContractParameters = {}, +): UseWriteContractReturnType { + const { mutation } = parameters + + const config = useConfig(parameters) + + const mutationOptions = writeContractMutationOptions(config) + const { mutate, mutateAsync, ...result } = useMutation({ + ...mutation, + ...mutationOptions, + }) + + type Return = UseWriteContractReturnType + return { + ...result, + writeContract: mutate as Return['writeContract'], + writeContractAsync: mutateAsync as Return['writeContractAsync'], + } +} diff --git a/packages/vue/src/errors/base.test.ts b/packages/vue/src/errors/base.test.ts new file mode 100644 index 0000000000..3457d4be1a --- /dev/null +++ b/packages/vue/src/errors/base.test.ts @@ -0,0 +1,155 @@ +import { expect, test } from 'vitest' + +import { BaseError } from './base.js' + +test('BaseError', () => { + expect(new BaseError('An error occurred.')).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Version: @wagmi/vue@x.y.z] + `) + + expect( + new BaseError('An error occurred.', { details: 'details' }), + ).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Details: details + Version: @wagmi/vue@x.y.z] + `) + + expect(new BaseError('', { details: 'details' })).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Details: details + Version: @wagmi/vue@x.y.z] + `) +}) + +test('BaseError (w/ docsPath)', () => { + expect( + new BaseError('An error occurred.', { + details: 'details', + docsPath: '/lol', + }), + ).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Docs: https://wagmi.sh/vue/lol.html + Details: details + Version: @wagmi/vue@x.y.z] + `) + expect( + new BaseError('An error occurred.', { + cause: new BaseError('error', { docsPath: '/docs' }), + }), + ).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Docs: https://wagmi.sh/vue/docs.html + Version: @wagmi/vue@x.y.z] + `) + expect( + new BaseError('An error occurred.', { + cause: new BaseError('error'), + docsPath: '/lol', + }), + ).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Docs: https://wagmi.sh/vue/lol.html + Version: @wagmi/vue@x.y.z] + `) + expect( + new BaseError('An error occurred.', { + details: 'details', + docsPath: '/lol', + docsSlug: 'test', + }), + ).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Docs: https://wagmi.sh/vue/lol.html#test + Details: details + Version: @wagmi/vue@x.y.z] + `) +}) + +test('BaseError (w/ metaMessages)', () => { + expect( + new BaseError('An error occurred.', { + details: 'details', + metaMessages: ['Reason: idk', 'Cause: lol'], + }), + ).toMatchInlineSnapshot(` + [WagmiError: An error occurred. + + Reason: idk + Cause: lol + + Details: details + Version: @wagmi/vue@x.y.z] + `) +}) + +test('inherited BaseError', () => { + const err = new BaseError('An error occurred.', { + details: 'details', + docsPath: '/lol', + }) + expect( + new BaseError('An internal error occurred.', { + cause: err, + }), + ).toMatchInlineSnapshot(` + [WagmiError: An internal error occurred. + + Docs: https://wagmi.sh/vue/lol.html + Details: details + Version: @wagmi/vue@x.y.z] + `) +}) + +test('inherited Error', () => { + const err = new Error('details') + expect( + new BaseError('An internal error occurred.', { + cause: err, + docsPath: '/lol', + }), + ).toMatchInlineSnapshot(` + [WagmiError: An internal error occurred. + + Docs: https://wagmi.sh/vue/lol.html + Details: details + Version: @wagmi/vue@x.y.z] + `) +}) + +test('walk: no predicate fn (walks to leaf)', () => { + class FooError extends BaseError {} + class BarError extends BaseError {} + + const err = new BaseError('test1', { + cause: new FooError('test2', { cause: new BarError('test3') }), + }) + expect(err.walk()).toMatchInlineSnapshot(` + [WagmiError: test3 + + Version: @wagmi/vue@x.y.z] + `) +}) + +test('walk: predicate fn', () => { + class FooError extends BaseError {} + class BarError extends BaseError {} + + const err = new BaseError('test1', { + cause: new FooError('test2', { cause: new BarError('test3') }), + }) + expect(err.walk((err) => err instanceof FooError)).toMatchInlineSnapshot(` + [WagmiError: test2 + + Version: @wagmi/vue@x.y.z] + `) +}) diff --git a/packages/vue/src/errors/base.ts b/packages/vue/src/errors/base.ts new file mode 100644 index 0000000000..bb65ac5fef --- /dev/null +++ b/packages/vue/src/errors/base.ts @@ -0,0 +1,14 @@ +import { BaseError as CoreError } from '@wagmi/core' + +import { getVersion } from '../utils/getVersion.js' + +export type BaseErrorType = BaseError & { name: 'WagmiError' } +export class BaseError extends CoreError { + override name = 'WagmiError' + override get docsBaseUrl() { + return 'https://wagmi.sh/vue' + } + override get version() { + return getVersion() + } +} diff --git a/packages/vue/src/errors/plugin.test.ts b/packages/vue/src/errors/plugin.test.ts new file mode 100644 index 0000000000..64ff3acda8 --- /dev/null +++ b/packages/vue/src/errors/plugin.test.ts @@ -0,0 +1,24 @@ +import { expect, test } from 'vitest' + +import { + WagmiInjectionContextError, + WagmiPluginNotFoundError, +} from './plugin.js' + +test('WagmiPluginNotFoundError', () => { + expect(new WagmiPluginNotFoundError()).toMatchInlineSnapshot(` + [WagmiPluginNotFoundError: No \`config\` found in Vue context, use \`WagmiPlugin\` to properly initialize the library. + + Docs: https://wagmi.sh/vue/api/TODO.html + Version: @wagmi/vue@x.y.z] + `) +}) + +test('WagmiInjectionContextError', () => { + expect(new WagmiInjectionContextError()).toMatchInlineSnapshot(` + [WagmiInjectionContextError: Wagmi composables can only be used inside \`setup()\` function or functions that support injection context. + + Docs: https://wagmi.sh/vue/api/TODO.html + Version: @wagmi/vue@x.y.z] + `) +}) diff --git a/packages/vue/src/errors/plugin.ts b/packages/vue/src/errors/plugin.ts new file mode 100644 index 0000000000..bed7cda47e --- /dev/null +++ b/packages/vue/src/errors/plugin.ts @@ -0,0 +1,31 @@ +import { BaseError } from './base.js' + +export type WagmiPluginNotFoundErrorType = WagmiPluginNotFoundError & { + name: 'WagmiPluginNotFoundError' +} +export class WagmiPluginNotFoundError extends BaseError { + override name = 'WagmiPluginNotFoundError' + constructor() { + super( + 'No `config` found in Vue context, use `WagmiPlugin` to properly initialize the library.', + { + docsPath: '/api/TODO', + }, + ) + } +} + +export type WagmiInjectionContextErrorType = WagmiInjectionContextError & { + name: 'WagmiInjectionContextError' +} +export class WagmiInjectionContextError extends BaseError { + override name = 'WagmiInjectionContextError' + constructor() { + super( + 'Wagmi composables can only be used inside `setup()` function or functions that support injection context.', + { + docsPath: '/api/TODO', + }, + ) + } +} diff --git a/packages/vue/src/exports/actions.test.ts b/packages/vue/src/exports/actions.test.ts new file mode 100644 index 0000000000..eaaedba14f --- /dev/null +++ b/packages/vue/src/exports/actions.test.ts @@ -0,0 +1,86 @@ +import { expect, test } from 'vitest' + +import * as actions from './actions.js' + +test('exports', () => { + expect(Object.keys(actions)).toMatchInlineSnapshot(` + [ + "call", + "connect", + "deployContract", + "disconnect", + "estimateGas", + "estimateFeesPerGas", + "estimateMaxPriorityFeePerGas", + "getAccount", + "getBalance", + "fetchBalance", + "getBlock", + "getBlockNumber", + "fetchBlockNumber", + "getBlockTransactionCount", + "getBytecode", + "getCallsStatus", + "getCapabilities", + "getChainId", + "getChains", + "getClient", + "getConnections", + "getConnectors", + "getConnectorClient", + "getEnsAddress", + "fetchEnsAddress", + "getEnsAvatar", + "fetchEnsAvatar", + "getEnsName", + "fetchEnsName", + "getEnsResolver", + "fetchEnsResolver", + "getEnsText", + "getFeeHistory", + "getGasPrice", + "getProof", + "getPublicClient", + "getStorageAt", + "getToken", + "fetchToken", + "getTransaction", + "fetchTransaction", + "getTransactionConfirmations", + "getTransactionCount", + "getTransactionReceipt", + "getWalletClient", + "multicall", + "prepareTransactionRequest", + "readContract", + "readContracts", + "reconnect", + "sendCalls", + "sendTransaction", + "showCallsStatus", + "signMessage", + "signTypedData", + "simulateContract", + "switchAccount", + "switchChain", + "switchNetwork", + "verifyMessage", + "verifyTypedData", + "waitForCallsStatus", + "watchAccount", + "watchAsset", + "watchBlocks", + "watchBlockNumber", + "watchChainId", + "watchClient", + "watchConnections", + "watchConnectors", + "watchContractEvent", + "watchPendingTransactions", + "watchPublicClient", + "waitForTransactionReceipt", + "waitForTransaction", + "writeContract", + ] + `) +}) diff --git a/packages/vue/src/exports/actions.ts b/packages/vue/src/exports/actions.ts new file mode 100644 index 0000000000..3ff9c743c5 --- /dev/null +++ b/packages/vue/src/exports/actions.ts @@ -0,0 +1,7 @@ +//////////////////////////////////////////////////////////////////////////////// +// @wagmi/core/actions +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from '@wagmi/core/actions' diff --git a/packages/vue/src/exports/actions/experimental.test.ts b/packages/vue/src/exports/actions/experimental.test.ts new file mode 100644 index 0000000000..7c4b92df8c --- /dev/null +++ b/packages/vue/src/exports/actions/experimental.test.ts @@ -0,0 +1,25 @@ +import { expect, test } from 'vitest' + +import * as experimentalActions from './experimental.js' + +test('exports', () => { + expect(Object.keys(experimentalActions)).toMatchInlineSnapshot(` + [ + "getCallsStatus", + "getCapabilities", + "sendCalls", + "showCallsStatus", + "waitForCallsStatus", + "writeContracts", + "getCallsStatusQueryOptions", + "getCallsStatusQueryKey", + "getCapabilitiesQueryOptions", + "getCapabilitiesQueryKey", + "sendCallsMutationOptions", + "showCallsStatusMutationOptions", + "waitForCallsStatusQueryKey", + "waitForCallsStatusQueryOptions", + "writeContractsMutationOptions", + ] + `) +}) diff --git a/packages/vue/src/exports/actions/experimental.ts b/packages/vue/src/exports/actions/experimental.ts new file mode 100644 index 0000000000..6ee0334af5 --- /dev/null +++ b/packages/vue/src/exports/actions/experimental.ts @@ -0,0 +1,7 @@ +//////////////////////////////////////////////////////////////////////////////// +// @wagmi/core/experimental +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from '@wagmi/core/experimental' diff --git a/packages/vue/src/exports/chains.ts b/packages/vue/src/exports/chains.ts new file mode 100644 index 0000000000..1fca7f537f --- /dev/null +++ b/packages/vue/src/exports/chains.ts @@ -0,0 +1,7 @@ +//////////////////////////////////////////////////////////////////////////////// +// viem/chains +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from 'viem/chains' diff --git a/packages/vue/src/exports/connectors.test.ts b/packages/vue/src/exports/connectors.test.ts new file mode 100644 index 0000000000..068db8227c --- /dev/null +++ b/packages/vue/src/exports/connectors.test.ts @@ -0,0 +1,17 @@ +import { expect, test } from 'vitest' + +import * as connectors from './connectors.js' + +test('exports', () => { + expect(Object.keys(connectors)).toMatchInlineSnapshot(` + [ + "injected", + "mock", + "coinbaseWallet", + "metaMask", + "safe", + "walletConnect", + "version", + ] + `) +}) diff --git a/packages/vue/src/exports/connectors.ts b/packages/vue/src/exports/connectors.ts new file mode 100644 index 0000000000..e10367e318 --- /dev/null +++ b/packages/vue/src/exports/connectors.ts @@ -0,0 +1,7 @@ +//////////////////////////////////////////////////////////////////////////////// +// @wagmi/connectors +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from '@wagmi/connectors' diff --git a/packages/vue/src/exports/index.test.ts b/packages/vue/src/exports/index.test.ts new file mode 100644 index 0000000000..bb8fb0a1bd --- /dev/null +++ b/packages/vue/src/exports/index.test.ts @@ -0,0 +1,74 @@ +import { expect, test } from 'vitest' + +import * as vue from './index.js' + +test('exports', () => { + expect(Object.keys(vue)).toMatchInlineSnapshot(` + [ + "configKey", + "WagmiPlugin", + "BaseError", + "WagmiPluginNotFoundError", + "WagmiInjectionContextError", + "useAccount", + "useAccountEffect", + "useBalance", + "useBlockNumber", + "useBytecode", + "useChainId", + "useClient", + "useConnectorClient", + "useChains", + "useConfig", + "useConnect", + "useConnections", + "useConnectors", + "useDisconnect", + "useEnsAddress", + "useEnsAvatar", + "useEnsName", + "useEstimateGas", + "useReadContract", + "useReconnect", + "useSendTransaction", + "useSignMessage", + "useSignTypedData", + "useSimulateContract", + "useSwitchAccount", + "useSwitchChain", + "useTransaction", + "useTransactionReceipt", + "useWatchBlockNumber", + "useWatchContractEvent", + "useWaitForTransactionReceipt", + "useWriteContract", + "createConfig", + "createConnector", + "injected", + "mock", + "ChainNotConfiguredError", + "ConnectorAlreadyConnectedError", + "ConnectorNotFoundError", + "ConnectorAccountNotFoundError", + "ConnectorChainMismatchError", + "ConnectorUnavailableReconnectingError", + "ProviderNotFoundError", + "SwitchChainNotSupportedError", + "createStorage", + "noopStorage", + "custom", + "fallback", + "http", + "webSocket", + "unstable_connector", + "cookieStorage", + "cookieToInitialState", + "deepEqual", + "deserialize", + "normalizeChainId", + "parseCookie", + "serialize", + "version", + ] + `) +}) diff --git a/packages/vue/src/exports/index.ts b/packages/vue/src/exports/index.ts new file mode 100644 index 0000000000..e7267878cf --- /dev/null +++ b/packages/vue/src/exports/index.ts @@ -0,0 +1,280 @@ +//////////////////////////////////////////////////////////////////////////////// +// Plugin +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +export { configKey, type WagmiPluginOptions, WagmiPlugin } from '../plugin.js' + +//////////////////////////////////////////////////////////////////////////////// +// Errors +//////////////////////////////////////////////////////////////////////////////// + +export { type BaseErrorType, BaseError } from '../errors/base.js' + +export { + type WagmiPluginNotFoundErrorType, + WagmiPluginNotFoundError, + type WagmiInjectionContextErrorType, + WagmiInjectionContextError, +} from '../errors/plugin.js' + +//////////////////////////////////////////////////////////////////////////////// +// Composables +//////////////////////////////////////////////////////////////////////////////// + +export { + type UseAccountParameters, + type UseAccountReturnType, + useAccount, +} from '../composables/useAccount.js' + +export { + type UseAccountEffectParameters, + useAccountEffect, +} from '../composables/useAccountEffect.js' + +export { + type UseBalanceParameters, + type UseBalanceReturnType, + useBalance, +} from '../composables/useBalance.js' + +export { + type UseBlockNumberParameters, + type UseBlockNumberReturnType, + useBlockNumber, +} from '../composables/useBlockNumber.js' + +export { + type UseBytecodeParameters, + type UseBytecodeReturnType, + useBytecode, +} from '../composables/useBytecode.js' + +export { + type UseChainIdParameters, + type UseChainIdReturnType, + useChainId, +} from '../composables/useChainId.js' + +export { + type UseClientParameters, + type UseClientReturnType, + useClient, +} from '../composables/useClient.js' + +export { + type UseConnectorClientParameters, + type UseConnectorClientReturnType, + useConnectorClient, +} from '../composables/useConnectorClient.js' + +export { + type UseChainsParameters, + type UseChainsReturnType, + useChains, +} from '../composables/useChains.js' + +export { + type UseConfigParameters, + type UseConfigReturnType, + useConfig, +} from '../composables/useConfig.js' + +export { + type UseConnectParameters, + type UseConnectReturnType, + useConnect, +} from '../composables/useConnect.js' + +export { + type UseConnectionsParameters, + type UseConnectionsReturnType, + useConnections, +} from '../composables/useConnections.js' + +export { + type UseConnectorsParameters, + type UseConnectorsReturnType, + useConnectors, +} from '../composables/useConnectors.js' + +export { + type UseDisconnectParameters, + type UseDisconnectReturnType, + useDisconnect, +} from '../composables/useDisconnect.js' + +export { + type UseEnsAddressParameters, + type UseEnsAddressReturnType, + useEnsAddress, +} from '../composables/useEnsAddress.js' + +export { + type UseEnsAvatarParameters, + type UseEnsAvatarReturnType, + useEnsAvatar, +} from '../composables/useEnsAvatar.js' + +export { + type UseEnsNameParameters, + type UseEnsNameReturnType, + useEnsName, +} from '../composables/useEnsName.js' + +export { + type UseEstimateGasParameters, + type UseEstimateGasReturnType, + useEstimateGas, +} from '../composables/useEstimateGas.js' + +export { + type UseReadContractParameters, + type UseReadContractReturnType, + useReadContract, +} from '../composables/useReadContract.js' + +export { + type UseReconnectParameters, + type UseReconnectReturnType, + useReconnect, +} from '../composables/useReconnect.js' + +export { + type UseSendTransactionParameters, + type UseSendTransactionReturnType, + useSendTransaction, +} from '../composables/useSendTransaction.js' + +export { + type UseSignMessageParameters, + type UseSignMessageReturnType, + useSignMessage, +} from '../composables/useSignMessage.js' + +export { + type UseSignTypedDataParameters, + type UseSignTypedDataReturnType, + useSignTypedData, +} from '../composables/useSignTypedData.js' + +export { + type UseSimulateContractParameters, + type UseSimulateContractReturnType, + useSimulateContract, +} from '../composables/useSimulateContract.js' + +export { + type UseSwitchAccountParameters, + type UseSwitchAccountReturnType, + useSwitchAccount, +} from '../composables/useSwitchAccount.js' + +export { + type UseSwitchChainParameters, + type UseSwitchChainReturnType, + useSwitchChain, +} from '../composables/useSwitchChain.js' + +export { + type UseTransactionParameters, + type UseTransactionReturnType, + useTransaction, +} from '../composables/useTransaction.js' + +export { + type UseTransactionReceiptParameters, + type UseTransactionReceiptReturnType, + useTransactionReceipt, +} from '../composables/useTransactionReceipt.js' + +export { + type UseWatchBlockNumberParameters, + type UseWatchBlockNumberReturnType, + useWatchBlockNumber, +} from '../composables/useWatchBlockNumber.js' + +export { + type UseWatchContractEventParameters, + type UseWatchContractEventReturnType, + useWatchContractEvent, +} from '../composables/useWatchContractEvent.js' + +export { + type UseWaitForTransactionReceiptParameters, + type UseWaitForTransactionReceiptReturnType, + useWaitForTransactionReceipt, +} from '../composables/useWaitForTransactionReceipt.js' + +export { + type UseWriteContractParameters, + type UseWriteContractReturnType, + useWriteContract, +} from '../composables/useWriteContract.js' + +//////////////////////////////////////////////////////////////////////////////// +// @wagmi/core +//////////////////////////////////////////////////////////////////////////////// + +export { + // Config + type Connection, + type Connector, + type Config, + type CreateConfigParameters, + type PartializedState, + type State, + createConfig, + // Connector + type ConnectorEventMap, + type CreateConnectorFn, + createConnector, + injected, + mock, + // Errors + type ChainNotConfiguredErrorType, + ChainNotConfiguredError, + type ConnectorAlreadyConnectedErrorType, + ConnectorAlreadyConnectedError, + type ConnectorNotFoundErrorType, + ConnectorNotFoundError, + type ConnectorAccountNotFoundErrorType, + ConnectorAccountNotFoundError, + type ConnectorChainMismatchErrorType, + ConnectorChainMismatchError, + type ConnectorUnavailableReconnectingErrorType, + ConnectorUnavailableReconnectingError, + type ProviderNotFoundErrorType, + ProviderNotFoundError, + type SwitchChainNotSupportedErrorType, + SwitchChainNotSupportedError, + // Storage + type CreateStorageParameters, + type Storage, + createStorage, + noopStorage, + // Transports + custom, + fallback, + http, + webSocket, + unstable_connector, + // Types + type Register, + type ResolvedRegister, + // Utilities + cookieStorage, + cookieToInitialState, + deepEqual, + deserialize, + normalizeChainId, + parseCookie, + serialize, +} from '@wagmi/core' + +//////////////////////////////////////////////////////////////////////////////// +// Version +//////////////////////////////////////////////////////////////////////////////// + +export { version } from '../version.js' diff --git a/packages/vue/src/exports/nuxt.test.ts b/packages/vue/src/exports/nuxt.test.ts new file mode 100644 index 0000000000..7e5ecf9588 --- /dev/null +++ b/packages/vue/src/exports/nuxt.test.ts @@ -0,0 +1,11 @@ +import { expect, test } from 'vitest' + +import * as nuxt from './nuxt.js' + +test('exports', () => { + expect(Object.keys(nuxt)).toMatchInlineSnapshot(` + [ + "default", + ] + `) +}) diff --git a/packages/vue/src/exports/nuxt.ts b/packages/vue/src/exports/nuxt.ts new file mode 100644 index 0000000000..e3e2e184a3 --- /dev/null +++ b/packages/vue/src/exports/nuxt.ts @@ -0,0 +1,4 @@ +import { wagmiModule } from '../nuxt/module.js' + +export type { WagmiModuleOptions } from '../nuxt/module.js' +export default wagmiModule diff --git a/packages/vue/src/exports/query.test.ts b/packages/vue/src/exports/query.test.ts new file mode 100644 index 0000000000..758d45c907 --- /dev/null +++ b/packages/vue/src/exports/query.test.ts @@ -0,0 +1,99 @@ +import { expect, test } from 'vitest' + +import * as query from './query.js' + +test('exports', () => { + expect(Object.keys(query)).toMatchInlineSnapshot(` + [ + "callQueryKey", + "callQueryOptions", + "connectMutationOptions", + "deployContractMutationOptions", + "disconnectMutationOptions", + "estimateFeesPerGasQueryKey", + "estimateFeesPerGasQueryOptions", + "estimateGasQueryKey", + "estimateGasQueryOptions", + "estimateMaxPriorityFeePerGasQueryKey", + "estimateMaxPriorityFeePerGasQueryOptions", + "getBalanceQueryKey", + "getBalanceQueryOptions", + "getBlockQueryKey", + "getBlockQueryOptions", + "getBlockNumberQueryKey", + "getBlockNumberQueryOptions", + "getBlockTransactionCountQueryKey", + "getBlockTransactionCountQueryOptions", + "getBytecodeQueryKey", + "getBytecodeQueryOptions", + "getCallsStatusQueryKey", + "getCallsStatusQueryOptions", + "getCapabilitiesQueryKey", + "getCapabilitiesQueryOptions", + "getConnectorClientQueryKey", + "getConnectorClientQueryOptions", + "getEnsAddressQueryKey", + "getEnsAddressQueryOptions", + "getEnsAvatarQueryKey", + "getEnsAvatarQueryOptions", + "getEnsNameQueryKey", + "getEnsNameQueryOptions", + "getEnsResolverQueryKey", + "getEnsResolverQueryOptions", + "getEnsTextQueryKey", + "getEnsTextQueryOptions", + "getFeeHistoryQueryKey", + "getFeeHistoryQueryOptions", + "getGasPriceQueryKey", + "getGasPriceQueryOptions", + "getProofQueryKey", + "getProofQueryOptions", + "getStorageAtQueryKey", + "getStorageAtQueryOptions", + "getTokenQueryKey", + "getTokenQueryOptions", + "getTransactionQueryKey", + "getTransactionQueryOptions", + "getTransactionConfirmationsQueryKey", + "getTransactionConfirmationsQueryOptions", + "getTransactionCountQueryKey", + "getTransactionCountQueryOptions", + "getTransactionReceiptQueryKey", + "getTransactionReceiptQueryOptions", + "getWalletClientQueryKey", + "getWalletClientQueryOptions", + "infiniteReadContractsQueryKey", + "infiniteReadContractsQueryOptions", + "prepareTransactionRequestQueryKey", + "prepareTransactionRequestQueryOptions", + "readContractQueryKey", + "readContractQueryOptions", + "readContractsQueryKey", + "readContractsQueryOptions", + "reconnectMutationOptions", + "sendCallsMutationOptions", + "showCallsStatusMutationOptions", + "sendTransactionMutationOptions", + "signMessageMutationOptions", + "signTypedDataMutationOptions", + "switchAccountMutationOptions", + "simulateContractQueryKey", + "simulateContractQueryOptions", + "switchChainMutationOptions", + "verifyMessageQueryKey", + "verifyMessageQueryOptions", + "verifyTypedDataQueryKey", + "verifyTypedDataQueryOptions", + "waitForCallsStatusQueryKey", + "waitForCallsStatusQueryOptions", + "waitForTransactionReceiptQueryKey", + "waitForTransactionReceiptQueryOptions", + "watchAssetMutationOptions", + "writeContractMutationOptions", + "hashFn", + "structuralSharing", + "useMutation", + "useQuery", + ] + `) +}) diff --git a/packages/vue/src/exports/query.ts b/packages/vue/src/exports/query.ts new file mode 100644 index 0000000000..cd9169c0e7 --- /dev/null +++ b/packages/vue/src/exports/query.ts @@ -0,0 +1,19 @@ +//////////////////////////////////////////////////////////////////////////////// +// @wagmi/core/query +//////////////////////////////////////////////////////////////////////////////// + +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from '@wagmi/core/query' + +export { + type UseMutationParameters, + type UseMutationReturnType, + useMutation, +} from '../utils/query.js' + +export { + type UseQueryParameters, + type UseQueryReturnType, + useQuery, +} from '../utils/query.js' diff --git a/packages/vue/src/nuxt/module.ts b/packages/vue/src/nuxt/module.ts new file mode 100644 index 0000000000..452dcefac4 --- /dev/null +++ b/packages/vue/src/nuxt/module.ts @@ -0,0 +1,60 @@ +import type { NuxtModule } from '@nuxt/schema' +import { addImports, createResolver, defineNuxtModule } from 'nuxt/kit' + +// biome-ignore lint/complexity/noBannedTypes: +export type WagmiModuleOptions = {} + +export const wagmiModule: NuxtModule = + defineNuxtModule({ + meta: { + name: '@wagmi/vue', + configKey: 'wagmi', + compatibility: { + nuxt: '^3.0.0', + }, + }, + setup(_options, nuxt) { + const { resolve } = createResolver(import.meta.url) + + // Add types + nuxt.hook('prepare:types', ({ references }) => { + references.push({ types: '@wagmi/vue/nuxt' }) + }) + + // Add auto imports + const composables = resolve('./runtime/composables') + const names = [ + 'useAccount', + 'useAccountEffect', + 'useBalance', + 'useBlockNumber', + 'useChainId', + 'useChains', + 'useClient', + 'useConfig', + 'useConnect', + 'useConnections', + 'useConnectorClient', + 'useConnectors', + 'useDisconnect', + 'useEnsAddress', + 'useEnsAvatar', + 'useEnsName', + 'useEstimateGas', + 'useReadContract', + 'useReconnect', + 'useSendTransaction', + 'useSignMessage', + 'useSignTypedData', + 'useSimulateContract', + 'useSwitchAccount', + 'useSwitchChain', + 'useTransaction', + 'useTransactionReceipt', + 'useWaitForTransactionReceipt', + 'useWatchBlockNumber', + 'useWriteContract', + ] + addImports(names.map((name) => ({ from: composables, name }))) + }, + }) diff --git a/packages/vue/src/nuxt/runtime/composables.ts b/packages/vue/src/nuxt/runtime/composables.ts new file mode 100644 index 0000000000..2340689357 --- /dev/null +++ b/packages/vue/src/nuxt/runtime/composables.ts @@ -0,0 +1,3 @@ +// biome-ignore lint/performance/noBarrelFile: entrypoint module +// biome-ignore lint/performance/noReExportAll: entrypoint module +export * from '../../exports/index.js' diff --git a/packages/vue/src/plugin.ts b/packages/vue/src/plugin.ts new file mode 100644 index 0000000000..ae0d7f919a --- /dev/null +++ b/packages/vue/src/plugin.ts @@ -0,0 +1,22 @@ +import { type ResolvedRegister, type State, hydrate } from '@wagmi/core' +import type { Plugin } from 'vue' + +export const configKey = Symbol() + +export type WagmiPluginOptions = { + config: ResolvedRegister['config'] + initialState?: State | undefined + reconnectOnMount?: boolean | undefined +} + +export const WagmiPlugin = { + install(app, options) { + const { config, reconnectOnMount = true } = options + app.provide(configKey, config) + // TODO: check this works in SSR env. + // - reconnect on mount. + // - hydrate initial state. + const { onMount } = hydrate(config, { ...options, reconnectOnMount }) + onMount() + }, +} satisfies Plugin diff --git a/packages/vue/src/types/properties.ts b/packages/vue/src/types/properties.ts new file mode 100644 index 0000000000..e09fdb0158 --- /dev/null +++ b/packages/vue/src/types/properties.ts @@ -0,0 +1,27 @@ +import type { DefaultError, QueryKey } from '@tanstack/vue-query' +import type { Config } from '@wagmi/core' +import type { MaybeRef } from 'vue' +import type { UseQueryParameters } from '../utils/query.js' +import type { DeepUnwrapRef } from './ref.js' + +export type ConfigParameter = { + config?: Config | config | undefined +} + +export type EnabledParameter = { + enabled?: MaybeRef | undefined +} + +export type QueryParameter< + queryFnData = unknown, + error = DefaultError, + data = queryFnData, + queryKey extends QueryKey = QueryKey, +> = { + query?: + | Omit< + DeepUnwrapRef>, + 'queryFn' | 'queryHash' | 'queryKey' | 'queryKeyHashFn' | 'throwOnError' + > + | undefined +} diff --git a/packages/vue/src/types/ref.ts b/packages/vue/src/types/ref.ts new file mode 100644 index 0000000000..d9cd8120ec --- /dev/null +++ b/packages/vue/src/types/ref.ts @@ -0,0 +1,39 @@ +// Credit: https://github.com/TanStack/query/blob/01ce023826b81e6c41e354f27691f65c9725af67/packages/vue-query/src/types.ts + +import type { Config, Connector } from '@wagmi/core' +import type { MaybeRef, Ref, UnwrapRef } from 'vue' + +type Primitive = string | number | boolean | bigint | symbol | undefined | null +type UnwrapLeaf = + | Primitive + // biome-ignore lint/complexity/noBannedTypes: we need to support all types + | Function + | Date + | Error + | RegExp + | Map + | WeakMap + | Set + | WeakSet + +export type DeepMaybeRef = MaybeRef< + // biome-ignore lint/complexity/noBannedTypes: + value extends Function | Config | Connector + ? value + : value extends object | any[] + ? { + [key in keyof value]: DeepMaybeRef + } + : value +> + +export type DeepUnwrapRef = T extends UnwrapLeaf + ? T + : T extends Ref + ? DeepUnwrapRef + : // biome-ignore lint/complexity/noBannedTypes: + T extends {} + ? { + [Property in keyof T]: DeepUnwrapRef + } + : UnwrapRef diff --git a/packages/vue/src/utils/cloneDeep.ts b/packages/vue/src/utils/cloneDeep.ts new file mode 100644 index 0000000000..0bbf48deb8 --- /dev/null +++ b/packages/vue/src/utils/cloneDeep.ts @@ -0,0 +1,44 @@ +// Credit: https://github.com/TanStack/query/blob/01ce023826b81e6c41e354f27691f65c9725af67/packages/vue-query/src/utils.ts + +import { isRef, unref } from 'vue' + +import type { DeepMaybeRef, DeepUnwrapRef } from '../types/ref.js' + +function cloneDeep( + value: DeepMaybeRef, + customize?: (val: DeepMaybeRef) => value | undefined, +): value { + if (customize) { + const result = customize(value) + // If it's a ref of undefined, return undefined + if (result === undefined && isRef(value)) return result as value + if (result !== undefined) return result + } + + if (Array.isArray(value)) + return value.map((val) => cloneDeep(val, customize)) as unknown as value + + if (typeof value === 'object' && isPlainObject(value)) { + const entries = Object.entries(value).map(([key, val]) => [ + key, + cloneDeep(val, customize), + ]) + return Object.fromEntries(entries) + } + + return value as value +} + +export function deepUnref(value: value): DeepUnwrapRef { + return cloneDeep(value as any, (val) => { + if (isRef(val)) return deepUnref(unref(val)) + return undefined + }) +} + +// biome-ignore lint/complexity/noBannedTypes: +function isPlainObject(value: unknown): value is Object { + if (Object.prototype.toString.call(value) !== '[object Object]') return false + const prototype = Object.getPrototypeOf(value) + return prototype === null || prototype === Object.prototype +} diff --git a/packages/vue/src/utils/getVersion.test.ts b/packages/vue/src/utils/getVersion.test.ts new file mode 100644 index 0000000000..a2ae6fb1c2 --- /dev/null +++ b/packages/vue/src/utils/getVersion.test.ts @@ -0,0 +1,7 @@ +import { expect, test } from 'vitest' + +import { getVersion } from './getVersion.js' + +test('default', () => { + expect(getVersion()).toMatchInlineSnapshot(`"@wagmi/vue@x.y.z"`) +}) diff --git a/packages/vue/src/utils/getVersion.ts b/packages/vue/src/utils/getVersion.ts new file mode 100644 index 0000000000..1c33c5302a --- /dev/null +++ b/packages/vue/src/utils/getVersion.ts @@ -0,0 +1,3 @@ +import { version } from '../version.js' + +export const getVersion = () => `@wagmi/vue@${version}` diff --git a/packages/vue/src/utils/query.ts b/packages/vue/src/utils/query.ts new file mode 100644 index 0000000000..0ea82af9b7 --- /dev/null +++ b/packages/vue/src/utils/query.ts @@ -0,0 +1,161 @@ +import { + type DefaultError, + type MutationObserverOptions, + type QueryKey, + type UseQueryOptions, + type UseMutationReturnType as tanstack_UseMutationReturnType, + type UseQueryReturnType as tanstack_UseQueryReturnType, + useQuery as tanstack_useQuery, + useMutation, +} from '@tanstack/vue-query' +import type { + Compute, + ExactPartial, + Omit, + UnionStrictOmit, +} from '@wagmi/core/internal' +import { hashFn } from '@wagmi/core/query' +import { type MaybeRef, computed, unref } from 'vue' + +import type { DeepMaybeRef, DeepUnwrapRef } from '../types/ref.js' + +export type UseMutationParameters< + data = unknown, + error = Error, + variables = void, + context = unknown, +> = Compute< + DeepMaybeRef< + Omit< + DeepUnwrapRef< + MutationObserverOptions, context> + >, + 'mutationFn' | 'mutationKey' | 'throwOnError' + > + > +> + +export type UseMutationReturnType< + data = unknown, + error = Error, + variables = void, + context = unknown, +> = Compute< + UnionStrictOmit< + tanstack_UseMutationReturnType, + 'mutate' | 'mutateAsync' + > +> + +export { useMutation } + +//////////////////////////////////////////////////////////////////////////////// + +export type UseQueryParameters< + queryFnData = unknown, + error = DefaultError, + data = queryFnData, + queryKey extends QueryKey = QueryKey, +> = Compute< + DeepMaybeRef< + ExactPartial< + Omit< + DeepUnwrapRef< + UseQueryOptions + >, + 'initialData' + > + > & { + // Fix `initialData` type + initialData?: + | DeepUnwrapRef< + UseQueryOptions + >['initialData'] + | undefined + } + > +> + +export type UseQueryReturnType = Compute< + tanstack_UseQueryReturnType & { + queryKey: QueryKey + } +> + +// Adding some basic customization. +// Ideally we don't have this function, but `import('@tanstack/vue-query').useQuery` currently has some quirks where it is super hard to +// pass down the inferred `initialData` type because of it's discriminated overload in the on `useQuery`. +export function useQuery( + parameters: MaybeRef< + UseQueryParameters & { + queryKey: QueryKey + } + >, +): UseQueryReturnType { + const options = computed(() => ({ + ...(unref(parameters) as any), + queryKeyHashFn: hashFn, + })) + const result = tanstack_useQuery(options) as UseQueryReturnType + result.queryKey = unref(options).queryKey as QueryKey + return result +} + +//////////////////////////////////////////////////////////////////////////////// + +// export type UseInfiniteQueryParameters< +// queryFnData = unknown, +// error = DefaultError, +// data = queryFnData, +// queryData = queryFnData, +// queryKey extends QueryKey = QueryKey, +// pageParam = unknown, +// > = Compute< +// Omit< +// UseInfiniteQueryOptions< +// queryFnData, +// error, +// data, +// queryData, +// queryKey, +// pageParam +// >, +// 'initialData' +// > & { +// // Fix `initialData` type +// initialData?: +// | UseInfiniteQueryOptions< +// queryFnData, +// error, +// data, +// queryKey +// >['initialData'] +// | undefined +// } +// > + +// export type UseInfiniteQueryReturnType< +// data = unknown, +// error = DefaultError, +// > = import('@tanstack/vue-query').UseInfiniteQueryReturnType & { +// queryKey: QueryKey +// } + +// // Adding some basic customization. +// export function useInfiniteQuery< +// queryFnData, +// error, +// data, +// queryKey extends QueryKey, +// >( +// parameters: UseInfiniteQueryParameters & { +// queryKey: QueryKey +// }, +// ): UseInfiniteQueryReturnType { +// const result = tanstack_useInfiniteQuery({ +// ...(parameters as any), +// queryKeyHashFn: hashFn, // for bigint support +// }) as UseInfiniteQueryReturnType +// result.queryKey = parameters.queryKey +// return result +// } diff --git a/packages/vue/src/utils/updateState.ts b/packages/vue/src/utils/updateState.ts new file mode 100644 index 0000000000..bcd53872d5 --- /dev/null +++ b/packages/vue/src/utils/updateState.ts @@ -0,0 +1,10 @@ +// Credit: https://github.com/TanStack/query/blob/01ce023826b81e6c41e354f27691f65c9725af67/packages/vue-query/src/utils.ts#L11-L18 + +export function updateState( + state: Record, + update: Record, +): void { + for (const key of Object.keys(state)) { + state[key] = update[key] + } +} diff --git a/packages/vue/src/version.ts b/packages/vue/src/version.ts new file mode 100644 index 0000000000..4a292eed46 --- /dev/null +++ b/packages/vue/src/version.ts @@ -0,0 +1 @@ +export const version = '0.1.20' diff --git a/packages/vue/test/setup.ts b/packages/vue/test/setup.ts new file mode 100644 index 0000000000..5c0dcc071d --- /dev/null +++ b/packages/vue/test/setup.ts @@ -0,0 +1,8 @@ +import { vi } from 'vitest' + +// Make dates stable across runs +Date.now = vi.fn(() => new Date(Date.UTC(2023, 1, 1)).valueOf()) + +vi.mock('../src/version.ts', () => { + return { version: 'x.y.z' } +}) diff --git a/packages/vue/tsconfig.build.json b/packages/vue/tsconfig.build.json new file mode 100644 index 0000000000..fbed2b1036 --- /dev/null +++ b/packages/vue/tsconfig.build.json @@ -0,0 +1,8 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["src/**/*.ts"], + "exclude": ["src/**/*.test.ts", "src/**/*.test-d.ts"], + "compilerOptions": { + "sourceMap": true + } +} diff --git a/packages/vue/tsconfig.json b/packages/vue/tsconfig.json new file mode 100644 index 0000000000..bacbc9228c --- /dev/null +++ b/packages/vue/tsconfig.json @@ -0,0 +1,5 @@ +{ + "extends": "./tsconfig.build.json", + "include": ["src/**/*.ts", "test/**/*.ts"], + "exclude": [] +} diff --git a/packages/wallet/core/eslint.config.js b/packages/wallet/core/eslint.config.js index d10bbd1e97..0c24ade422 100644 --- a/packages/wallet/core/eslint.config.js +++ b/packages/wallet/core/eslint.config.js @@ -4,7 +4,7 @@ import { config as baseConfig } from '@repo/eslint-config/base' export default [ ...baseConfig, { - // files: ['**/*.{test,spec}.ts'], + files: ['**/*.{test,spec}.ts'], rules: { '@typescript-eslint/no-explicit-any': 'off', }, diff --git a/packages/wallet/core/package.json b/packages/wallet/core/package.json index 4133157861..00fbbf56e5 100644 --- a/packages/wallet/core/package.json +++ b/packages/wallet/core/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/wallet-core", - "version": "3.0.5", + "version": "0.0.0", "license": "Apache-2.0", "type": "module", "publishConfig": { @@ -13,8 +13,7 @@ "test": "vitest run", "test:coverage": "vitest run --coverage", "typecheck": "tsc --noEmit", - "clean": "rimraf dist", - "lint": "eslint . --max-warnings 0" + "clean": "rimraf dist" }, "exports": { ".": { @@ -23,21 +22,20 @@ } }, "devDependencies": { - "@repo/eslint-config": "workspace:^", "@repo/typescript-config": "workspace:^", - "@types/node": "^25.3.0", - "@vitest/coverage-v8": "^4.0.18", - "dotenv": "^17.3.1", - "fake-indexeddb": "^6.2.5", - "typescript": "^5.9.3", - "vitest": "^4.0.18" + "@types/node": "^22.15.29", + "@vitest/coverage-v8": "^3.2.4", + "dotenv": "^16.5.0", + "fake-indexeddb": "^6.0.1", + "typescript": "^5.8.3", + "vitest": "^3.2.1" }, "dependencies": { "@0xsequence/guard": "workspace:^", "@0xsequence/relayer": "workspace:^", "@0xsequence/wallet-primitives": "workspace:^", "mipd": "^0.0.7", - "ox": "^0.9.17", - "viem": "^2.40.3" + "ox": "^0.7.2", + "viem": "^2.30.6" } } diff --git a/packages/wallet/core/src/index.ts b/packages/wallet/core/src/index.ts index 27c54b8f53..1bc32aed48 100644 --- a/packages/wallet/core/src/index.ts +++ b/packages/wallet/core/src/index.ts @@ -2,13 +2,7 @@ export * from './wallet.js' export * as Signers from './signers/index.js' export * as State from './state/index.js' -export * as Bundler from './bundler/index.js' +export * as Relayer from './relayer/index.js' export * as Envelope from './envelope.js' +export * as Preconditions from './preconditions/index.js' export * as Utils from './utils/index.js' -export * from './env.js' -export { - type ExplicitSessionConfig, - type ExplicitSession, - type ImplicitSession, - type Session, -} from './utils/session/types.js' diff --git a/packages/wallet/core/src/state/sequence/index.ts b/packages/wallet/core/src/state/sequence/index.ts index 0842111530..140b3f1ca8 100644 --- a/packages/wallet/core/src/state/sequence/index.ts +++ b/packages/wallet/core/src/state/sequence/index.ts @@ -9,17 +9,13 @@ import { TransactionRequest, } from 'ox' import { normalizeAddressKeys, Provider as ProviderInterface } from '../index.js' -import { Sessions, SignatureType, type Fetch } from './sessions.gen.js' +import { Sessions, SignatureType } from './sessions.gen.js' export class Provider implements ProviderInterface { private readonly service: Sessions - constructor(host = 'https://keymachine.sequence.app', fetcher?: Fetch) { - const resolvedFetch = fetcher ?? (globalThis as any).fetch - if (!resolvedFetch) { - throw new Error('fetch is not available') - } - this.service = new Sessions(host, resolvedFetch) + constructor(host = 'https://v3-keymachine.sequence-dev.app') { + this.service = new Sessions(host, fetch) } async getConfiguration(imageHash: Hex.Hex): Promise { @@ -190,9 +186,7 @@ export class Provider implements ProviderInterface { case SignatureType.SapientCompact: throw new Error(`unexpected compact sapient signature by ${signer}`) } - } catch { - // ignore - } + } catch {} } async getWitnessForSapient( @@ -227,9 +221,7 @@ export class Provider implements ProviderInterface { signature: { type: 'sapient_compact', address: signer, data: witness.signature }, } } - } catch { - // ignore - } + } catch {} } async getConfigurationUpdates( @@ -372,13 +364,9 @@ export class Provider implements ProviderInterface { } } -const passkeySigners = [ - Extensions.Dev1.passkeys, - Extensions.Dev2.passkeys, - Extensions.Rc3.passkeys, - Extensions.Rc4.passkeys, - Extensions.Rc5.passkeys, -].map(Address.checksum) +const passkeySigners = [Extensions.Dev1.passkeys, Extensions.Dev2.passkeys, Extensions.Rc3.passkeys].map( + Address.checksum, +) const recoverSapientSignatureCompactSignature = 'function recoverSapientSignatureCompact(bytes32 _digest, bytes _signature) view returns (bytes32)' @@ -386,14 +374,10 @@ const recoverSapientSignatureCompactSignature = const recoverSapientSignatureCompactFunction = AbiFunction.from(recoverSapientSignatureCompactSignature) class PasskeySignatureValidator implements oxProvider.Provider { - request: oxProvider.Provider['request'] = (async (request) => { - switch (request.method) { - case 'eth_call': { - if (!request.params || !Array.isArray(request.params) || request.params.length === 0) { - throw new Error('eth_call requires transaction parameters') - } - - const transaction: TransactionRequest.Rpc = request.params[0] + request: oxProvider.Provider['request'] = (({ method, params }: { method: string; params: unknown }) => { + switch (method) { + case 'eth_call': + const transaction: TransactionRequest.Rpc = (params as any)[0] if (!transaction.data?.startsWith(AbiFunction.getSelector(recoverSapientSignatureCompactFunction))) { throw new Error( @@ -414,18 +398,17 @@ class PasskeySignatureValidator implements oxProvider.Provider { } else { throw new Error(`invalid passkey signature ${signature} for digest ${digest}`) } - } default: - throw new Error(`method ${request.method} not implemented`) + throw new Error(`method ${method} not implemented`) } - }) as oxProvider.Provider['request'] + }) as any - on: oxProvider.Provider['on'] = (event: string) => { + on(event: string) { throw new Error(`unable to listen for ${event}: not implemented`) } - removeListener: oxProvider.Provider['removeListener'] = (event: string) => { + removeListener(event: string) { throw new Error(`unable to remove listener for ${event}: not implemented`) } } diff --git a/packages/wallet/dapp-client/package.json b/packages/wallet/dapp-client/package.json index 7ed1867e74..c48f42aea8 100644 --- a/packages/wallet/dapp-client/package.json +++ b/packages/wallet/dapp-client/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/dapp-client", - "version": "3.0.5", + "version": "0.0.0", "license": "Apache-2.0", "type": "module", "publishConfig": { @@ -11,8 +11,7 @@ "build": "tsc", "dev": "tsc --watch", "typecheck": "tsc --noEmit", - "clean": "rimraf dist", - "lint": "eslint . --max-warnings 0" + "clean": "rimraf dist" }, "exports": { ".": { @@ -21,21 +20,19 @@ } }, "devDependencies": { - "@repo/eslint-config": "workspace:^", "@repo/typescript-config": "workspace:^", - "@types/node": "^25.3.0", - "@vitest/coverage-v8": "^4.0.18", - "dotenv": "^17.3.1", - "fake-indexeddb": "^6.2.5", - "happy-dom": "^20.8.9", - "typescript": "^5.9.3", - "vitest": "^4.0.18" + "@types/node": "^22.15.29", + "@vitest/coverage-v8": "^3.2.4", + "dotenv": "^16.5.0", + "fake-indexeddb": "^6.0.1", + "happy-dom": "^17.2.2", + "typescript": "^5.8.3", + "vitest": "^3.2.1" }, "dependencies": { - "@0xsequence/guard": "workspace:^", - "@0xsequence/relayer": "workspace:^", "@0xsequence/wallet-core": "workspace:^", "@0xsequence/wallet-primitives": "workspace:^", - "ox": "^0.9.17" + "@0xsequence/guard": "workspace:^", + "ox": "^0.7.2" } } diff --git a/packages/wallet/dapp-client/src/ChainSessionManager.ts b/packages/wallet/dapp-client/src/ChainSessionManager.ts index a57e2c2324..76b62a3f3d 100644 --- a/packages/wallet/dapp-client/src/ChainSessionManager.ts +++ b/packages/wallet/dapp-client/src/ChainSessionManager.ts @@ -1,18 +1,8 @@ +import { Envelope, Relayer, Signers, State, Wallet } from '@0xsequence/wallet-core' +import { Attestation, Constants, Extensions, Payload, SessionConfig } from '@0xsequence/wallet-primitives' import * as Guard from '@0xsequence/guard' import { AbiFunction, Address, Hex, Provider, RpcTransport, Secp256k1 } from 'ox' -import { - Envelope, - Signers, - State, - Wallet, - Attestation, - Constants, - Extensions, - Payload, - SessionConfig, -} from './index.js' - import { DappTransport } from './DappTransport.js' import { @@ -28,27 +18,21 @@ import { SequenceStorage } from './utils/storage.js' import { getRelayerUrl, getRpcUrl } from './utils/index.js' import { - CreateNewSessionResponse, + AddExplicitSessionPayload, + CreateNewSessionPayload, + ConnectSuccessResponsePayload, ExplicitSessionEventListener, + ModifySessionPayload, + ModifySessionSuccessResponsePayload, LoginMethod, RandomPrivateKeyFn, RequestActionType, + Session, Transaction, TransportMode, GuardConfig, - CreateNewSessionPayload, - EthAuthSettings, - ModifyExplicitSessionPayload, - SessionResponse, - AddExplicitSessionPayload, - FeeOption, - OperationFailedStatus, - OperationStatus, - ETHAuthProof, } from './types/index.js' import { CACHE_DB_NAME, VALUE_FORWARDER_ADDRESS } from './utils/constants.js' -import { ExplicitSession, ImplicitSession, ExplicitSessionConfig } from './index.js' -import { Relayer } from '@0xsequence/relayer' interface ChainSessionManagerEventMap { explicitSessionResponse: ExplicitSessionEventListener @@ -70,14 +54,13 @@ export class ChainSessionManager { [K in keyof ChainSessionManagerEventMap]?: Set } = {} - private explicitSessions: ExplicitSession[] = [] - private implicitSession: ImplicitSession | null = null + private sessions: Session[] = [] private walletAddress: Address.Address | null = null private sessionManager: Signers.SessionManager | null = null private wallet: Wallet | null = null private provider: Provider.Provider | null = null - private relayer: Relayer.RpcRelayer + private relayer: Relayer.Standard.Rpc.RpcRelayer private readonly chainId: number public transport: DappTransport | null = null private sequenceStorage: SequenceStorage @@ -86,11 +69,6 @@ export class ChainSessionManager { public loginMethod: LoginMethod | null = null public userEmail: string | null = null private guard?: GuardConfig - private lastSignedCallCache?: { - fingerprint: string - signedCall: { to: Address.Address; data: Hex.Hex } - createdAtMs: number - } /** * @param chainId The ID of the chain this manager is responsible for. @@ -121,8 +99,7 @@ export class ChainSessionManager { const rpcUrl = getRpcUrl(chainId, nodesUrl, projectAccessKey) this.chainId = chainId - const canUseIndexedDbInEnv = canUseIndexedDb && typeof indexedDB !== 'undefined' - if (canUseIndexedDbInEnv) { + if (canUseIndexedDb) { this.stateProvider = new State.Cached({ source: new State.Sequence.Provider(keyMachineUrl), cache: new State.Local.Provider(new State.Local.IndexedDbStore(CACHE_DB_NAME)), @@ -132,12 +109,10 @@ export class ChainSessionManager { } this.guard = guard this.provider = Provider.from(RpcTransport.fromHttp(rpcUrl)) - this.relayer = new Relayer.RpcRelayer( + this.relayer = new Relayer.Standard.Rpc.RpcRelayer( getRelayerUrl(chainId, relayerUrl), this.chainId, getRpcUrl(chainId, nodesUrl, projectAccessKey), - undefined, - projectAccessKey, ) this.transport = transport @@ -158,11 +133,11 @@ export class ChainSessionManager { listener: ChainSessionManagerEventMap[K], ): () => void { if (!this.eventListeners[event]) { - this.eventListeners[event] = new Set() + this.eventListeners[event] = new Set() as any } - this.eventListeners[event].add(listener) + ;(this.eventListeners[event] as any).add(listener) return () => { - this.eventListeners[event]?.delete(listener) + ;(this.eventListeners[event] as any)?.delete(listener) } } @@ -187,7 +162,7 @@ export class ChainSessionManager { * @throws {InitializationError} If initialization fails. */ async initialize(): Promise<{ - loginMethod: LoginMethod | null + loginMethod: string | null userEmail: string | null } | void> { if (this.isInitializing) return @@ -229,7 +204,7 @@ export class ChainSessionManager { stateProvider: this.stateProvider, }) this.sessionManager = new Signers.SessionManager(this.wallet, { - sessionManagerAddress: Extensions.Rc5.sessions, + sessionManagerAddress: Extensions.Rc3.sessions, provider: this.provider!, }) this.isInitialized = true @@ -244,7 +219,7 @@ export class ChainSessionManager { const implicitSession = await this.sequenceStorage.getImplicitSession() - if (implicitSession) { + if (implicitSession && implicitSession.chainId === this.chainId) { await this._initializeImplicitSessionInternal( implicitSession.pk, walletAddress, @@ -275,54 +250,40 @@ export class ChainSessionManager { /** * Initiates the creation of a new session by sending a request to the wallet. - * @param origin The origin of the session. - * @param sessionConfig (Optional) Session configuration for an initial explicit session. + * @param permissions (Optional) Permissions for an initial explicit session. * @param options (Optional) Additional options like preferred login method. * @throws {InitializationError} If a session already exists or the transport fails to initialize. */ async createNewSession( origin: string, - sessionConfig?: ExplicitSessionConfig, + permissions?: Signers.Session.ExplicitParams, options: { preferredLoginMethod?: LoginMethod email?: string includeImplicitSession?: boolean - ethAuth?: EthAuthSettings } = {}, ): Promise { if (this.isInitialized) { throw new InitializationError('A session already exists. Disconnect first.') } - const shouldCreateSession = !!sessionConfig || (options.includeImplicitSession ?? false) - - const newPk = shouldCreateSession ? await this.randomPrivateKeyFn() : null - const newSignerAddress = - shouldCreateSession && newPk ? Address.fromPublicKey(Secp256k1.getPublicKey({ privateKey: newPk })) : null - const completeSession = - shouldCreateSession && newSignerAddress - ? { - sessionAddress: newSignerAddress, - ...sessionConfig, - } - : undefined + const newPk = await this.randomPrivateKeyFn() + const newSignerAddress = Address.fromPublicKey(Secp256k1.getPublicKey({ privateKey: newPk })) try { if (!this.transport) throw new InitializationError('Transport failed to initialize.') const payload: CreateNewSessionPayload = { + sessionAddress: newSignerAddress, origin, - session: completeSession as ExplicitSession | undefined, + permissions, includeImplicitSession: options.includeImplicitSession ?? false, - ethAuth: options.ethAuth, preferredLoginMethod: options.preferredLoginMethod, email: options.preferredLoginMethod === 'email' ? options.email : undefined, } if (this.transport.mode === TransportMode.REDIRECT) { - if (shouldCreateSession && newPk) { - await this.sequenceStorage.saveTempSessionPk(newPk) - } + await this.sequenceStorage.saveTempSessionPk(newPk) await this.sequenceStorage.savePendingRequest({ chainId: this.chainId, action: RequestActionType.CREATE_NEW_SESSION, @@ -331,7 +292,7 @@ export class ChainSessionManager { await this.sequenceStorage.setPendingRedirectRequest(true) } - const connectResponse = await this.transport.sendRequest( + const connectResponse = await this.transport.sendRequest( RequestActionType.CREATE_NEW_SESSION, this.redirectUrl, payload, @@ -341,48 +302,34 @@ export class ChainSessionManager { const receivedAddress = Address.from(connectResponse.walletAddress) const { attestation, signature, userEmail, loginMethod, guard } = connectResponse - if (shouldCreateSession) { + if (attestation && signature) { await this._resetStateAndClearCredentials() - this.loginMethod = null - this.userEmail = null - this.initializeWithWallet(receivedAddress) - if (attestation && signature && newPk) { - await this._initializeImplicitSessionInternal( - newPk, - receivedAddress, - attestation, - signature, - true, - loginMethod, - userEmail, - guard, - ) - } - - if (sessionConfig && newPk) { - await this._initializeExplicitSessionInternal(newPk, loginMethod, userEmail, guard, true) - await this.sequenceStorage.saveExplicitSession({ - pk: newPk, - walletAddress: receivedAddress, - chainId: this.chainId, - guard, - loginMethod, - userEmail, - }) - } - } else { - await this._resetStateAndClearCredentials() - this.initializeWithWallet(receivedAddress) - this.loginMethod = loginMethod ?? null - this.userEmail = userEmail ?? null - this.guard = guard + await this._initializeImplicitSessionInternal( + newPk, + receivedAddress, + attestation, + signature, + true, + loginMethod, + userEmail, + guard, + ) } - if (payload.ethAuth) { - await this._saveEthAuthProofIfProvided(connectResponse.ethAuthProof) + if (permissions) { + this.initializeWithWallet(receivedAddress) + await this._initializeExplicitSessionInternal(newPk, loginMethod, userEmail, guard, true) + await this.sequenceStorage.saveExplicitSession({ + pk: newPk, + walletAddress: receivedAddress, + chainId: this.chainId, + guard, + loginMethod, + userEmail, + }) } if (this.transport.mode === TransportMode.POPUP) { @@ -397,11 +344,11 @@ export class ChainSessionManager { /** * Initiates the addition of a new explicit session by sending a request to the wallet. - * @param explicitSessionConfig The explicit session configuration for the new explicit session. + * @param permissions The permissions for the new explicit session. * @throws {InitializationError} If the manager is not initialized. * @throws {AddExplicitSessionError} If adding the session fails. */ - async addExplicitSession(explicitSessionConfig: ExplicitSessionConfig): Promise { + async addExplicitSession(permissions: Signers.Session.ExplicitParams): Promise { if (!this.walletAddress) { throw new InitializationError( 'Cannot add an explicit session without a wallet address. Initialize the manager with a wallet address first.', @@ -416,7 +363,8 @@ export class ChainSessionManager { const newSignerAddress = Address.fromPublicKey(Secp256k1.getPublicKey({ privateKey: newPk })) const payload: AddExplicitSessionPayload = { - session: { ...explicitSessionConfig, sessionAddress: newSignerAddress, type: 'explicit' }, + sessionAddress: newSignerAddress, + permissions, } if (this.transport.mode === TransportMode.REDIRECT) { @@ -429,7 +377,7 @@ export class ChainSessionManager { await this.sequenceStorage.setPendingRedirectRequest(true) } - const response = await this.transport.sendRequest( + const response = await this.transport.sendRequest( RequestActionType.ADD_EXPLICIT_SESSION, this.redirectUrl, payload, @@ -459,7 +407,6 @@ export class ChainSessionManager { userEmail: response.userEmail, guard: response.guard, }) - await this.sequenceStorage.clearSessionlessConnection() } catch (err) { if (this.transport?.mode === TransportMode.POPUP) this.transport.closeWallet() throw new AddExplicitSessionError(`Adding explicit session failed: ${err}`) @@ -468,11 +415,15 @@ export class ChainSessionManager { /** * Initiates the modification of an existing explicit session by sending a request to the wallet. - * @param modifiedExplicitSession The modified explicit session. + * @param sessionAddress The address of the explicit session to modify. + * @param newPermissions The new permissions for the session. * @throws {InitializationError} If the manager is not initialized. * @throws {ModifyExplicitSessionError} If modifying the session fails. */ - async modifyExplicitSession(modifiedExplicitSession: ExplicitSession): Promise { + async modifyExplicitSession( + sessionAddress: Address.Address, + newPermissions: Signers.Session.ExplicitParams, + ): Promise { if (!this.walletAddress) { throw new InitializationError( 'Cannot modify an explicit session without a wallet address. Initialize the manager with a wallet address first.', @@ -482,22 +433,15 @@ export class ChainSessionManager { try { if (!this.transport) throw new InitializationError('Transport failed to initialize.') - if (!modifiedExplicitSession.sessionAddress) { - throw new ModifyExplicitSessionError('Session address is required.') - } - - const existingExplicitSession = this.explicitSessions.find((s) => - Address.isEqual(s.sessionAddress!, modifiedExplicitSession.sessionAddress!), - ) - if (!existingExplicitSession) { + const session = this.sessions.find((s) => Address.isEqual(s.address, sessionAddress)) + if (!session) { throw new ModifyExplicitSessionError('Session not found.') } - const payload: ModifyExplicitSessionPayload = { + const payload: ModifySessionPayload = { walletAddress: this.walletAddress, - session: { - ...modifiedExplicitSession, - }, + sessionAddress: sessionAddress, + permissions: newPermissions, } if (this.transport.mode === TransportMode.REDIRECT) { @@ -509,7 +453,7 @@ export class ChainSessionManager { await this.sequenceStorage.setPendingRedirectRequest(true) } - const response = await this.transport.sendRequest( + const response = await this.transport.sendRequest( RequestActionType.MODIFY_EXPLICIT_SESSION, this.redirectUrl, payload, @@ -518,14 +462,12 @@ export class ChainSessionManager { if ( !Address.isEqual(Address.from(response.walletAddress), this.walletAddress) && - !Address.isEqual(Address.from(response.sessionAddress), modifiedExplicitSession.sessionAddress) + !Address.isEqual(Address.from(response.sessionAddress), sessionAddress) ) { throw new ModifyExplicitSessionError('Wallet or session address mismatch.') } - existingExplicitSession.permissions = modifiedExplicitSession.permissions - existingExplicitSession.deadline = modifiedExplicitSession.deadline - existingExplicitSession.valueLimit = modifiedExplicitSession.valueLimit + session.permissions = newPermissions if (this.transport?.mode === TransportMode.POPUP) { this.transport?.closeWallet() @@ -542,38 +484,29 @@ export class ChainSessionManager { * @returns A promise resolving to true on success. */ private async _handleRedirectConnectionResponse(response: { - payload: CreateNewSessionResponse + payload: ConnectSuccessResponsePayload action: string }): Promise { + const tempPk = await this.sequenceStorage.getAndClearTempSessionPk() + if (!tempPk) { + throw new InitializationError('Failed to retrieve temporary session key after redirect.') + } + try { const connectResponse = response.payload const receivedAddress = Address.from(connectResponse.walletAddress) const { userEmail, loginMethod, guard } = connectResponse - const savedRequest = await this.sequenceStorage.peekPendingRequest() - const savedPayload = savedRequest?.payload as CreateNewSessionPayload | undefined - const explicitSessionRequested = (savedPayload?.session?.permissions?.length ?? 0) > 0 - const implicitSessionRequested = savedPayload?.includeImplicitSession ?? false - const needsTempPk = explicitSessionRequested || implicitSessionRequested - const tempPk = needsTempPk ? await this.sequenceStorage.getAndClearTempSessionPk() : null - - if (needsTempPk && !tempPk) { - throw new InitializationError('Failed to retrieve temporary session key after redirect.') - } if (response.action === RequestActionType.CREATE_NEW_SESSION) { const { attestation, signature } = connectResponse + const savedRequest = await this.sequenceStorage.peekPendingRequest() + const savedPayload = savedRequest?.payload as CreateNewSessionPayload | undefined await this._resetStateAndClearCredentials() - this.loginMethod = null - this.userEmail = null - this.initializeWithWallet(receivedAddress) - if (implicitSessionRequested) { - if (!attestation || !signature || !tempPk) { - throw new InitializationError('Missing implicit session data in redirect response.') - } + if (attestation && signature) { await this._initializeImplicitSessionInternal( tempPk, receivedAddress, @@ -586,7 +519,7 @@ export class ChainSessionManager { ) } - if (explicitSessionRequested && savedPayload?.session && tempPk) { + if (savedRequest && savedPayload && savedPayload.permissions) { await this._initializeExplicitSessionInternal(tempPk, loginMethod, userEmail, guard, true) await this.sequenceStorage.saveExplicitSession({ pk: tempPk, @@ -596,46 +529,29 @@ export class ChainSessionManager { userEmail, guard, }) - await this.sequenceStorage.clearSessionlessConnection() - } - - if (!explicitSessionRequested && !implicitSessionRequested) { - this.loginMethod = loginMethod ?? null - this.userEmail = userEmail ?? null - this.guard = guard - } - - if (savedPayload?.ethAuth) { - await this._saveEthAuthProofIfProvided(connectResponse.ethAuthProof) } } else if (response.action === RequestActionType.ADD_EXPLICIT_SESSION) { if (!this.walletAddress || !Address.isEqual(receivedAddress, this.walletAddress)) { throw new InitializationError('Received an explicit session for a wallet that is not active.') } - const explicitSessionPk = tempPk ?? (await this.sequenceStorage.getAndClearTempSessionPk()) - if (!explicitSessionPk) { - throw new InitializationError('Failed to retrieve temporary session key for explicit session.') - } - await this._initializeExplicitSessionInternal( - explicitSessionPk, + tempPk, this.loginMethod ?? undefined, this.userEmail ?? undefined, this.guard ?? undefined, true, ) await this.sequenceStorage.saveExplicitSession({ - pk: explicitSessionPk, + pk: tempPk, walletAddress: receivedAddress, chainId: this.chainId, loginMethod: this.loginMethod ?? undefined, userEmail: this.userEmail ?? undefined, guard: this.guard ?? undefined, }) - await this.sequenceStorage.clearSessionlessConnection() - const newSignerAddress = Address.fromPublicKey(Secp256k1.getPublicKey({ privateKey: explicitSessionPk })) + const newSignerAddress = Address.fromPublicKey(Secp256k1.getPublicKey({ privateKey: tempPk })) this.emit('explicitSessionResponse', { action: RequestActionType.ADD_EXPLICIT_SESSION, @@ -644,8 +560,6 @@ export class ChainSessionManager { sessionAddress: newSignerAddress, }, }) - } else { - throw new WalletRedirectError(`Received unhandled redirect action: ${response.action}`) } this.isInitialized = true return true @@ -699,10 +613,10 @@ export class ChainSessionManager { ) this.sessionManager = this.sessionManager.withImplicitSigner(implicitSigner) - this.implicitSession = { - sessionAddress: implicitSigner.address, - type: 'implicit', - } + this.sessions.push({ + address: implicitSigner.address, + isImplicit: true, + }) this.walletAddress = address if (saveSession) @@ -748,7 +662,7 @@ export class ChainSessionManager { for (let attempt = 1; attempt <= maxRetries; attempt++) { try { const tempManager = new Signers.SessionManager(this.wallet, { - sessionManagerAddress: Extensions.Rc5.sessions, + sessionManagerAddress: Extensions.Rc3.sessions, provider: this.provider, }) const topology = await tempManager.getTopology() @@ -765,13 +679,11 @@ export class ChainSessionManager { const explicitSigner = new Signers.Session.Explicit(pk, permissions) this.sessionManager = this.sessionManager.withExplicitSigner(explicitSigner) - this.explicitSessions.push({ - sessionAddress: explicitSigner.address, + this.sessions.push({ + address: explicitSigner.address, + isImplicit: false, chainId: this.chainId, - permissions: permissions.permissions, - valueLimit: permissions.valueLimit, - deadline: permissions.deadline, - type: 'explicit', + permissions, }) if (guard && !this.guard) this.guard = guard @@ -788,20 +700,6 @@ export class ChainSessionManager { throw new InitializationError(`Explicit session init failed after ${maxRetries} attempts: ${lastError.message}`) } - private async _refreshExplicitSession(expiredSignerAddress: Address.Address): Promise { - if (!this.wallet || !this.sessionManager || !this.provider || !this.isInitialized) - throw new InitializationError('Session is not initialized.') - // Find current explicit session - const explicitSigner = this.explicitSessions.find((s) => Address.isEqual(s.sessionAddress, expiredSignerAddress)) - if (!explicitSigner) throw new ModifyExplicitSessionError('Explicit session not found.') - // Update the deadline - const newExplicitSession = { - ...explicitSigner, - deadline: BigInt(Math.floor(Date.now() / 1000)) + BigInt(24 * 60 * 60), - } - await this.modifyExplicitSession(newExplicitSession) - } - /** * Checks if the current session has permission to execute a set of transactions. * @param transactions The transactions to check permissions for. @@ -843,7 +741,7 @@ export class ChainSessionManager { * @returns A promise that resolves with an array of fee options. * @throws {FeeOptionError} If fetching fee options fails. */ - async getFeeOptions(calls: Transaction[]): Promise { + async getFeeOptions(calls: Transaction[]): Promise { const callsToSend = calls.map((tx) => ({ to: tx.to, value: tx.value, @@ -855,17 +753,7 @@ export class ChainSessionManager { })) try { const signedCall = await this._buildAndSignCalls(callsToSend) - const fingerprint = this._fingerprintCalls(callsToSend) - if (fingerprint) { - this.lastSignedCallCache = { - fingerprint, - signedCall, - createdAtMs: Date.now(), - } - } - const walletAddress = this.walletAddress - if (!walletAddress) throw new InitializationError('Wallet is not initialized.') - const feeOptions = await this.relayer.feeOptions(walletAddress, this.chainId, signedCall.to, callsToSend) + const feeOptions = await this.relayer.feeOptions(signedCall.to, this.chainId, callsToSend) return feeOptions.options } catch (err) { throw new FeeOptionError(`Failed to get fee options: ${err instanceof Error ? err.message : String(err)}`) @@ -880,7 +768,7 @@ export class ChainSessionManager { * @throws {InitializationError} If the session is not initialized. * @throws {TransactionError} If the transaction fails at any stage. */ - async buildSignAndSendTransactions(transactions: Transaction[], feeOption?: FeeOption): Promise { + async buildSignAndSendTransactions(transactions: Transaction[], feeOption?: Relayer.FeeOption): Promise { if (!this.wallet || !this.sessionManager || !this.provider || !this.isInitialized) throw new InitializationError('Session is not initialized.') try { @@ -921,13 +809,13 @@ export class ChainSessionManager { callsToSend.unshift(transferCall) } } - const signedCalls = this._getCachedSignedCall(callsToSend) ?? (await this._buildAndSignCalls(callsToSend)) + const signedCalls = await this._buildAndSignCalls(callsToSend) const hash = await this.relayer.relay(signedCalls.to, signedCalls.data, this.chainId) const status = await this._waitForTransactionReceipt(hash.opHash, this.chainId) if (status.status === 'confirmed') { return status.transactionHash } else { - const failedStatus = status as OperationFailedStatus + const failedStatus = status as Relayer.OperationFailedStatus const reason = failedStatus.reason || `unexpected status ${status.status}` throw new TransactionError(`Transaction failed: ${reason}`) } @@ -965,7 +853,7 @@ export class ChainSessionManager { ) { return this._handleRedirectConnectionResponse(response) } else if (response.action === RequestActionType.MODIFY_EXPLICIT_SESSION) { - const modifyResponse = response.payload as SessionResponse + const modifyResponse = response.payload as ModifySessionSuccessResponsePayload if (!Address.isEqual(Address.from(modifyResponse.walletAddress), this.walletAddress!)) { throw new ModifyExplicitSessionError('Wallet address mismatch on redirect response.') } @@ -992,24 +880,12 @@ export class ChainSessionManager { return this.walletAddress } - getGuard(): GuardConfig | undefined { - return this.guard - } - /** - * Gets the sessions (signers) managed by this session manager. + * Gets the sessions (signers) managed by this instance. * @returns An array of session objects. */ - getExplicitSessions(): ExplicitSession[] { - return this.explicitSessions - } - - /** - * Gets the implicit session managed by this session manager. - * @returns An implicit session object or null if no implicit session is found. - */ - getImplicitSession(): ImplicitSession | null { - return this.implicitSession + getSessions(): Session[] { + return this.sessions } /** @@ -1079,7 +955,7 @@ export class ChainSessionManager { * @param chainId The chain ID of the transaction. * @returns The final status of the transaction. */ - private async _waitForTransactionReceipt(opHash: `0x${string}`, chainId: number): Promise { + private async _waitForTransactionReceipt(opHash: `0x${string}`, chainId: number): Promise { try { while (true) { const currentStatus = await this.relayer.status(opHash, chainId) @@ -1097,13 +973,11 @@ export class ChainSessionManager { * @private Resets the internal state of the manager without clearing stored credentials. */ private _resetState(): void { - this.explicitSessions = [] - this.implicitSession = null + this.sessions = [] this.walletAddress = null this.wallet = null this.sessionManager = null this.isInitialized = false - this.guard = undefined } /** @@ -1113,51 +987,5 @@ export class ChainSessionManager { this._resetState() await this.sequenceStorage.clearImplicitSession() await this.sequenceStorage.clearExplicitSessions() - await this.sequenceStorage.clearSessionlessConnection() - } - - private async _saveEthAuthProofIfProvided(ethAuthProof?: ETHAuthProof): Promise { - if (!ethAuthProof) { - return - } - await this.sequenceStorage.saveEthAuthProof(ethAuthProof) - } - - private _getCachedSignedCall(calls: Payload.Call[]): { to: Address.Address; data: Hex.Hex } | null { - if (!this.lastSignedCallCache) { - return null - } - const ttlMs = 30_000 - if (Date.now() - this.lastSignedCallCache.createdAtMs > ttlMs) { - this.lastSignedCallCache = undefined - return null - } - const fingerprint = this._fingerprintCalls(calls) - if (!fingerprint) { - return null - } - if (fingerprint !== this.lastSignedCallCache.fingerprint) { - return null - } - return this.lastSignedCallCache.signedCall - } - - private _fingerprintCalls(calls: Payload.Call[]): string | null { - try { - return JSON.stringify( - calls.map((call) => ({ - to: call.to, - value: call.value?.toString() ?? '0', - data: call.data ?? '0x', - gasLimit: call.gasLimit?.toString() ?? '0', - delegateCall: call.delegateCall ?? false, - onlyFallback: call.onlyFallback ?? false, - behaviorOnError: call.behaviorOnError ?? 'revert', - })), - ) - } catch (error) { - console.warn('ChainSessionManager._fingerprintCalls failed:', error) - return null - } } } diff --git a/packages/wallet/dapp-client/src/DappClient.ts b/packages/wallet/dapp-client/src/DappClient.ts index e580bd9127..4bff6bdb4a 100644 --- a/packages/wallet/dapp-client/src/DappClient.ts +++ b/packages/wallet/dapp-client/src/DappClient.ts @@ -1,25 +1,21 @@ +/* eslint-disable @typescript-eslint/no-explicit-any */ +import { Relayer, Signers } from '@0xsequence/wallet-core' import { Address, Hex } from 'ox' -import { type ExplicitSession, type ExplicitSessionConfig, type ImplicitSession, type Session } from './index.js' - import { ChainSessionManager } from './ChainSessionManager.js' import { DappTransport } from './DappTransport.js' -import { ConnectionError, InitializationError, SigningError, TransactionError } from './utils/errors.js' -import { SequenceStorage, WebStorage, type SessionlessConnectionData } from './utils/storage.js' +import { InitializationError, SigningError, TransactionError } from './utils/errors.js' +import { SequenceStorage, WebStorage } from './utils/storage.js' import { - CreateNewSessionResponse, DappClientExplicitSessionEventListener, DappClientWalletActionEventListener, - FeeOption, - GetFeeTokensResponse, GuardConfig, LoginMethod, - EthAuthSettings, RandomPrivateKeyFn, RequestActionType, - ETHAuthProof, SendWalletTransactionPayload, SequenceSessionStorage, + Session, SignMessagePayload, SignTypedDataPayload, Transaction, @@ -29,10 +25,8 @@ import { } from './types/index.js' import { TypedData } from 'ox/TypedData' import { KEYMACHINE_URL, NODES_URL, RELAYER_URL } from './utils/constants.js' -import { getRelayerUrl, getRpcUrl } from './utils/index.js' -import { Relayer } from '@0xsequence/relayer' -export type DappClientEventListener = (data?: unknown) => void +export type DappClientEventListener = (data?: any) => void interface DappClientEventMap { sessionsUpdated: () => void @@ -45,6 +39,8 @@ interface DappClientEventMap { * This client manages user sessions across multiple chains, handles connection * and disconnection, and provides methods for signing and sending transactions. * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client} for more detailed documentation. + * * @example * // It is recommended to manage a singleton instance of this client. * const dappClient = new DappClient('http://localhost:5173'); @@ -62,7 +58,7 @@ interface DappClientEventMap { export class DappClient { public isInitialized = false - public loginMethod: LoginMethod | null = null + public loginMethod: string | null = null public userEmail: string | null = null public guard?: GuardConfig @@ -71,8 +67,7 @@ export class DappClient { private chainSessionManagers: Map = new Map() private walletUrl: string - private transport: DappTransport | null = null - private transportModeSetting: TransportMode + private transport: DappTransport private projectAccessKey: string private nodesUrl: string private relayerUrl: string @@ -87,16 +82,10 @@ export class DappClient { private isInitializing = false private walletAddress: Address.Address | null = null - private hasSessionlessConnection = false - private cachedSessionlessConnection: SessionlessConnectionData | null = null private eventListeners: { [K in keyof DappClientEventMap]?: Set } = {} - private get isBrowser(): boolean { - return typeof window !== 'undefined' && typeof document !== 'undefined' - } - /** * @param walletUrl The URL of the Wallet Webapp. * @param origin The origin of the dapp @@ -141,8 +130,14 @@ export class DappClient { canUseIndexedDb = true, } = options || {} + this.transport = new DappTransport( + walletUrl, + transportMode, + undefined, + sequenceSessionStorage, + redirectActionHandler, + ) this.walletUrl = walletUrl - this.transportModeSetting = transportMode this.projectAccessKey = projectAccessKey this.nodesUrl = options?.nodesUrl || NODES_URL this.relayerUrl = options?.relayerUrl || RELAYER_URL @@ -160,7 +155,7 @@ export class DappClient { * @returns The transport mode of the client. {@link TransportMode} */ public get transportMode(): TransportMode { - return this.transport?.mode ?? this.transportModeSetting + return this.transport.mode } /** @@ -169,6 +164,8 @@ export class DappClient { * @param listener The listener to call when the event occurs. * @returns A function to remove the listener. * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client/on} for more detailed documentation. + * * @example * useEffect(() => { * const handleWalletAction = (response) => { @@ -182,12 +179,11 @@ export class DappClient { */ public on(event: K, listener: DappClientEventMap[K]): () => void { if (!this.eventListeners[event]) { - // @ts-expect-error - indexing into evenListeners will improperly create a union of all the possible types - this.eventListeners[event] = new Set() + this.eventListeners[event] = new Set() as any } - this.eventListeners[event].add(listener) + ;(this.eventListeners[event] as any).add(listener) return () => { - this.eventListeners[event]?.delete(listener) + ;(this.eventListeners[event] as any)?.delete(listener) } } @@ -195,6 +191,8 @@ export class DappClient { * Retrieves the wallet address of the current session. * @returns The wallet address of the current session, or null if not initialized. {@link Address.Address} * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client/get-wallet-address} for more detailed documentation. + * * @example * const dappClient = new DappClient('http://localhost:5173'); * await dappClient.initialize(); @@ -209,64 +207,31 @@ export class DappClient { } /** - * Retrieves a list of all active explicit sessions (signers) associated with the current wallet. - * @returns An array of all the active explicit sessions. {@link ExplicitSession[]} + * Retrieves a list of all active sessions (signers) associated with the current wallet. + * @returns An array of all the active sessions. {@link { address: Address.Address, isImplicit: boolean }[]} + * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client/get-all-sessions} for more detailed documentation. * * @example * const dappClient = new DappClient('http://localhost:5173'); * await dappClient.initialize(); * * if (dappClient.isInitialized) { - * const explicitSessions = dappClient.getAllExplicitSessions(); - * console.log('Sessions:', explicitSessions); + * const sessions = dappClient.getAllSessions(); + * console.log('Sessions:', sessions); * } */ - public getAllExplicitSessions(): ExplicitSession[] { - const allExplicitSessions = new Map() + public getAllSessions(): Session[] { + const allSessions = new Map() Array.from(this.chainSessionManagers.values()).forEach((chainSessionManager) => { - chainSessionManager.getExplicitSessions().forEach((session) => { - const uniqueKey = session.sessionAddress?.toLowerCase() - if (!allExplicitSessions.has(uniqueKey)) { - allExplicitSessions.set(uniqueKey, session) + chainSessionManager.getSessions().forEach((session) => { + const uniqueKey = `${session.address.toLowerCase()}-${session.isImplicit}` + if (!allSessions.has(uniqueKey)) { + allSessions.set(uniqueKey, session) } }) }) - return Array.from(allExplicitSessions.values()) - } - - /** - * Retrieves a list of all active implicit sessions (signers) associated with the current wallet. - * @note There can only be one implicit session per chain. - * @returns An array of all the active implicit sessions. {@link ImplicitSession[]} - * - * @example - * const dappClient = new DappClient('http://localhost:5173'); - * await dappClient.initialize(); - * - * if (dappClient.isInitialized) { - * const implicitSessions = dappClient.getAllImplicitSessions(); - * console.log('Sessions:', implicitSessions); - * } - */ - public getAllImplicitSessions(): ImplicitSession[] { - const allImplicitSessions = new Map() - Array.from(this.chainSessionManagers.values()).forEach((chainSessionManager) => { - const session = chainSessionManager.getImplicitSession() - if (!session) return - const uniqueKey = session?.sessionAddress?.toLowerCase() - if (uniqueKey && !allImplicitSessions.has(uniqueKey)) { - allImplicitSessions.set(uniqueKey, session) - } - }) - return Array.from(allImplicitSessions.values()) - } - - /** - * Gets all the sessions (explicit and implicit) managed by the client. - * @returns An array of session objects. {@link Session[]} - */ - public getAllSessions(): Session[] { - return [...this.getAllImplicitSessions(), ...this.getAllExplicitSessions()] + return Array.from(allSessions.values()) } /** @@ -276,42 +241,18 @@ export class DappClient { private async _loadStateFromStorage(): Promise { const implicitSession = await this.sequenceStorage.getImplicitSession() - const [explicitSessions, sessionlessConnection, sessionlessSnapshot] = await Promise.all([ - this.sequenceStorage.getExplicitSessions(), - this.sequenceStorage.getSessionlessConnection(), - this.sequenceStorage.getSessionlessConnectionSnapshot - ? this.sequenceStorage.getSessionlessConnectionSnapshot() - : Promise.resolve(null), - ]) - this.cachedSessionlessConnection = sessionlessSnapshot ?? null + const explicitSessions = await this.sequenceStorage.getExplicitSessions() const chainIdsToInitialize = new Set([ ...(implicitSession?.chainId !== undefined ? [implicitSession.chainId] : []), ...explicitSessions.map((s) => s.chainId), ]) if (chainIdsToInitialize.size === 0) { - if (sessionlessConnection) { - await this.applySessionlessConnectionState( - sessionlessConnection.walletAddress, - sessionlessConnection.loginMethod, - sessionlessConnection.userEmail, - sessionlessConnection.guard, - false, - ) - } else { - this.isInitialized = false - this.hasSessionlessConnection = false - this.walletAddress = null - this.loginMethod = null - this.userEmail = null - this.guard = undefined - this.emit('sessionsUpdated') - } + this.isInitialized = false + this.emit('sessionsUpdated') return } - this.hasSessionlessConnection = false - const initPromises = Array.from(chainIdsToInitialize).map((chainId) => this.getChainSessionManager(chainId).initialize(), ) @@ -322,11 +263,6 @@ export class DappClient { this.loginMethod = result[0]?.loginMethod || null this.userEmail = result[0]?.userEmail || null this.guard = implicitSession?.guard || explicitSessions.find((s) => !!s.guard)?.guard - await this.sequenceStorage.clearSessionlessConnection() - if (this.sequenceStorage.clearSessionlessConnectionSnapshot) { - await this.sequenceStorage.clearSessionlessConnectionSnapshot() - } - this.cachedSessionlessConnection = null this.isInitialized = true this.emit('sessionsUpdated') @@ -344,6 +280,8 @@ export class DappClient { * * @returns A promise that resolves when initialization is complete. * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client/initialize} for more detailed documentation. + * * @example * const dappClient = new DappClient('http://localhost:5173'); * await dappClient.initialize(); @@ -380,70 +318,6 @@ export class DappClient { } } - /** - * Indicates if there is cached sessionless connection data that can be restored. - */ - public async hasRestorableSessionlessConnection(): Promise { - if (this.cachedSessionlessConnection) return true - this.cachedSessionlessConnection = this.sequenceStorage.getSessionlessConnectionSnapshot - ? await this.sequenceStorage.getSessionlessConnectionSnapshot() - : null - return this.cachedSessionlessConnection !== null - } - - /** - * Returns the cached sessionless connection metadata without altering client state. - * @returns The cached sessionless connection or null if none is available. - */ - public async getSessionlessConnectionInfo(): Promise { - if (!this.cachedSessionlessConnection) { - this.cachedSessionlessConnection = this.sequenceStorage.getSessionlessConnectionSnapshot - ? await this.sequenceStorage.getSessionlessConnectionSnapshot() - : null - } - if (!this.cachedSessionlessConnection) return null - return { - walletAddress: this.cachedSessionlessConnection.walletAddress, - loginMethod: this.cachedSessionlessConnection.loginMethod, - userEmail: this.cachedSessionlessConnection.userEmail, - guard: this.cachedSessionlessConnection.guard, - } - } - - /** - * Returns the latest persisted ETHAuth proof, if one has been received from the wallet. - */ - public async getEthAuthProof(): Promise { - return this.sequenceStorage.getEthAuthProof() - } - - /** - * Restores a sessionless connection that was previously persisted via {@link disconnect} or a connect flow. - * @returns A promise that resolves to true if a sessionless connection was applied. - */ - public async restoreSessionlessConnection(): Promise { - const sessionlessConnection = - this.cachedSessionlessConnection ?? - (this.sequenceStorage.getSessionlessConnectionSnapshot - ? await this.sequenceStorage.getSessionlessConnectionSnapshot() - : null) - if (!sessionlessConnection) { - return false - } - - await this.applySessionlessConnectionState( - sessionlessConnection.walletAddress, - sessionlessConnection.loginMethod, - sessionlessConnection.userEmail, - sessionlessConnection.guard, - ) - if (this.sequenceStorage.clearSessionlessConnectionSnapshot) { - await this.sequenceStorage.clearSessionlessConnectionSnapshot() - } - this.cachedSessionlessConnection = null - return true - } - /** * Handles the redirect response from the Wallet. * This is called automatically on `initialize()` for web environments but can be called manually @@ -454,11 +328,7 @@ export class DappClient { public async handleRedirectResponse(url?: string): Promise { const pendingRequest = await this.sequenceStorage.peekPendingRequest() - if (!this.transport && this.transportMode === TransportMode.POPUP && !this.isBrowser) { - return - } - - const response = await this.ensureTransport().getRedirectResponse(true, url) + const response = await this.transport.getRedirectResponse(true, url) if (!response) { return } @@ -482,59 +352,8 @@ export class DappClient { } this.emit('walletActionResponse', eventPayload) } else if (chainId !== undefined) { - if ('error' in response && response.error && action === RequestActionType.CREATE_NEW_SESSION) { - await this.sequenceStorage.setPendingRedirectRequest(false) - await this.sequenceStorage.getAndClearTempSessionPk() - await this.sequenceStorage.getAndClearPendingRequest() - - if (this.hasSessionlessConnection) { - const sessionlessConnection = await this.sequenceStorage.getSessionlessConnection() - if (sessionlessConnection) { - await this.applySessionlessConnectionState( - sessionlessConnection.walletAddress, - sessionlessConnection.loginMethod, - sessionlessConnection.userEmail, - sessionlessConnection.guard, - false, - ) - } else if (this.walletAddress) { - await this.applySessionlessConnectionState( - this.walletAddress, - this.loginMethod, - this.userEmail, - this.guard, - false, - ) - } - } - return - } - const chainSessionManager = this.getChainSessionManager(chainId) - if (!chainSessionManager.isInitialized && this.walletAddress) { - chainSessionManager.initializeWithWallet(this.walletAddress) - } - const handled = await chainSessionManager.handleRedirectResponse(response) - if (handled && action === RequestActionType.CREATE_NEW_SESSION) { - const hasImplicit = !!chainSessionManager.getImplicitSession() - const hasExplicit = chainSessionManager.getExplicitSessions().length > 0 - if (hasImplicit || hasExplicit) { - this.hasSessionlessConnection = false - await this._loadStateFromStorage() - } else if ('payload' in response && response.payload) { - const payload = response.payload as CreateNewSessionResponse - const walletAddress = chainSessionManager.getWalletAddress() ?? Address.from(payload.walletAddress) - await this.applySessionlessConnectionState( - walletAddress, - chainSessionManager.loginMethod, - chainSessionManager.userEmail, - chainSessionManager.getGuard(), - ) - } - } else if (handled && action === RequestActionType.ADD_EXPLICIT_SESSION) { - this.hasSessionlessConnection = false - await this._loadStateFromStorage() - } + await chainSessionManager.handleRedirectResponse(response) } else { throw new InitializationError(`Could not find a pending request context for the redirect action: ${action}`) } @@ -543,33 +362,28 @@ export class DappClient { /** * Initiates a connection with the wallet and creates a new session. * @param chainId The primary chain ID for the new session. - * @param sessionConfig Session configuration {@link ExplicitSessionConfig} to request for an initial session. + * @param permissions (Optional) Permissions to request for an initial explicit session. {@link Signers.Session.ExplicitParams} * @param options (Optional) Connection options, such as a preferred login method or email for social or email logins. * @throws If the connection process fails. {@link ConnectionError} * @throws If a session already exists. {@link InitializationError} * * @returns A promise that resolves when the connection is established. * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client/connect} for more detailed documentation. + * * @example - * // Connect with an explicit session configuration - * const explicitSessionConfig: ExplicitSessionConfig = { - * valueLimit: 0n, - * deadline: BigInt(Date.now() + 1000 * 60 * 60), // 1 hour - * permissions: [...], - * chainId: 137 - * }; - * await dappClient.connect(137, explicitSessionConfig, { + * const dappClient = new DappClient('http://localhost:5173'); + * await dappClient.connect(137, window.location.origin, undefined, { * preferredLoginMethod: 'google', * }); */ async connect( chainId: number, - sessionConfig?: ExplicitSessionConfig, + permissions?: Signers.Session.ExplicitParams, options: { preferredLoginMethod?: LoginMethod email?: string includeImplicitSession?: boolean - ethAuth?: EthAuthSettings } = {}, ): Promise { if (this.isInitialized) { @@ -578,115 +392,16 @@ export class DappClient { try { const chainSessionManager = this.getChainSessionManager(chainId) - const shouldCreateSession = !!sessionConfig || (options.includeImplicitSession ?? false) - this.hasSessionlessConnection = false - await chainSessionManager.createNewSession(this.origin, sessionConfig, options) + await chainSessionManager.createNewSession(this.origin, permissions, options) // For popup mode, we need to manually update the state and emit an event. // For redirect mode, this code won't be reached; the page will navigate away. - if (this.transportMode === TransportMode.POPUP) { - const hasImplicitSession = !!chainSessionManager.getImplicitSession() - const hasExplicitSessions = chainSessionManager.getExplicitSessions().length > 0 - if (shouldCreateSession && (hasImplicitSession || hasExplicitSessions)) { - await this._loadStateFromStorage() - } else { - const walletAddress = chainSessionManager.getWalletAddress() - if (!walletAddress) { - throw new InitializationError('Wallet address missing after connect.') - } - await this.applySessionlessConnectionState( - walletAddress, - chainSessionManager.loginMethod, - chainSessionManager.userEmail, - chainSessionManager.getGuard(), - ) - } + if (this.transport.mode === TransportMode.POPUP) { + await this._loadStateFromStorage() } } catch (err) { await this.disconnect() - throw new ConnectionError(`Connection failed: ${err}`) - } - } - - /** - * Upgrades an existing sessionless connection by creating implicit and/or explicit sessions. - * @param chainId The chain ID to target for the new sessions. - * @param sessionConfig The explicit session configuration to request. {@link ExplicitSessionConfig} - * @param options Connection options such as preferred login method or email for social/email logins. - * @throws If no sessionless connection is available or the session upgrade fails. {@link InitializationError} - * @throws If neither an implicit nor explicit session is requested. {@link InitializationError} - * - * @returns A promise that resolves once the session upgrade completes. - */ - async upgradeSessionlessConnection( - chainId: number, - sessionConfig?: ExplicitSessionConfig, - options: { - preferredLoginMethod?: LoginMethod - email?: string - includeImplicitSession?: boolean - ethAuth?: EthAuthSettings - } = {}, - ): Promise { - if (!this.isInitialized || !this.hasSessionlessConnection || !this.walletAddress) { - throw new InitializationError('A sessionless connection is required before requesting new sessions.') - } - - const shouldCreateSession = !!sessionConfig || (options.includeImplicitSession ?? false) - if (!shouldCreateSession) { - throw new InitializationError( - 'Cannot upgrade a sessionless connection without requesting an implicit or explicit session.', - ) - } - - const sessionlessSnapshot = { - walletAddress: this.walletAddress, - loginMethod: this.loginMethod, - userEmail: this.userEmail, - guard: this.guard, - } - - try { - let chainSessionManager = this.chainSessionManagers.get(chainId) - if ( - chainSessionManager && - chainSessionManager.isInitialized && - !chainSessionManager.getImplicitSession() && - chainSessionManager.getExplicitSessions().length === 0 - ) { - this.chainSessionManagers.delete(chainId) - chainSessionManager = undefined - } - chainSessionManager = chainSessionManager ?? this.getChainSessionManager(chainId) - await chainSessionManager.createNewSession(this.origin, sessionConfig, options) - - if (this.transportMode === TransportMode.POPUP) { - const hasImplicitSession = !!chainSessionManager.getImplicitSession() - const hasExplicitSessions = chainSessionManager.getExplicitSessions().length > 0 - - if (shouldCreateSession && (hasImplicitSession || hasExplicitSessions)) { - await this._loadStateFromStorage() - } else { - const walletAddress = chainSessionManager.getWalletAddress() - if (!walletAddress) { - throw new InitializationError('Wallet address missing after connect.') - } - await this.applySessionlessConnectionState( - walletAddress, - chainSessionManager.loginMethod, - chainSessionManager.userEmail, - chainSessionManager.getGuard(), - ) - } - } - } catch (err) { - await this.applySessionlessConnectionState( - sessionlessSnapshot.walletAddress, - sessionlessSnapshot.loginMethod, - sessionlessSnapshot.userEmail, - sessionlessSnapshot.guard, - ) - throw new ConnectionError(`Connection failed: ${err}`) + throw err } } @@ -694,16 +409,19 @@ export class DappClient { * Adds a new explicit session for a given chain to an existing wallet. * @remarks * An `explicit session` is a session that can interact with any contract, subject to user-approved permissions. - * @param session The explicit session to add. {@link ExplicitSession} + * @param chainId The chain ID on which to add the explicit session. + * @param permissions The permissions to request for the new session. {@link Signers.Session.ExplicitParams} * * @throws If the session cannot be added. {@link AddExplicitSessionError} * @throws If the client or relevant chain is not initialized. {@link InitializationError} * * @returns A promise that resolves when the session is added. * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client/add-explicit-session} for more detailed documentation. + * * @example * ... - * import { ExplicitSession, Utils } from "@0xsequence/wallet-core"; + * import { Signers, Utils } from "@0xsequence/wallet-core"; * import { DappClient } from "@0xsequence/sessions"; * ... * @@ -715,61 +433,75 @@ export class DappClient { * * if (dappClient.isInitialized) { * // Allow Dapp (Session Signer) to transfer "amount" of USDC - * const explicitSession: ExplicitSession = { + * const permissions: Signers.Session.ExplicitParams = { * chainId: Number(chainId), * valueLimit: 0n, // Not allowed to transfer native tokens (ETH, etc) * deadline: BigInt(Date.now() + 1000 * 60 * 5000), // 5000 minutes from now * permissions: [Utils.ERC20PermissionBuilder.buildTransfer(USDC_ADDRESS, amount)] * }; - * await dappClient.addExplicitSession(explicitSession); + * await dappClient.addExplicitSession(1, permissions); * } */ - async addExplicitSession(explicitSessionConfig: ExplicitSessionConfig): Promise { + async addExplicitSession(chainId: number, permissions: Signers.Session.ExplicitParams): Promise { if (!this.isInitialized || !this.walletAddress) throw new InitializationError('Cannot add an explicit session without an existing wallet.') - const chainSessionManager = this.getChainSessionManager(explicitSessionConfig.chainId) + const chainSessionManager = this.getChainSessionManager(chainId) if (!chainSessionManager.isInitialized) { chainSessionManager.initializeWithWallet(this.walletAddress) } - await chainSessionManager.addExplicitSession(explicitSessionConfig) + await chainSessionManager.addExplicitSession(permissions) - if (this.transportMode === TransportMode.POPUP) { + if (this.transport.mode === TransportMode.POPUP) { await this._loadStateFromStorage() } } /** - * Modifies an explicit session for a given chain - * @param explicitSession The explicit session to modify. {@link ExplicitSession} + * Modifies the permissions of an existing explicit session for a given chain and session address. + * @param chainId The chain ID on which the explicit session exists. + * @param sessionAddress The address of the explicit session to modify. {@link Address.Address} + * @param permissions The new permissions to set for the session. {@link Signers.Session.ExplicitParams} * * @throws If the client or relevant chain is not initialized. {@link InitializationError} * @throws If something goes wrong while modifying the session. {@link ModifyExplicitSessionError} * * @returns A promise that resolves when the session permissions are updated. * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client/modify-explicit-session} for more detailed documentation. + * * @example * const dappClient = new DappClient('http://localhost:5173'); * await dappClient.initialize(); * * if (dappClient.isInitialized) { - * // Increase the deadline of the current session by 24 hours - * const currentExplicitSession = {...} - * const newExplicitSession = {...currentExplicitSession, deadline: currentExplicitSession.deadline + 24 * 60 * 60} - * await dappClient.modifyExplicitSession(newExplicitSession); + * // The address of an existing explicit session (Grants the Dapp permission to transfer 100 USDC for the user) + * const sessionAddress = '0x...'; + * // We create a new permission object where we can increase the granted transfer amount limit + * const permissions: Signers.Session.ExplicitParams = { + * chainId: Number(chainId), + * valueLimit: 0n, + * deadline: BigInt(Date.now() + 1000 * 60 * 5000), + * permissions: [Utils.ERC20PermissionBuilder.buildTransfer(USDC_ADDRESS, amount)] + * }; + * await dappClient.modifyExplicitSession(1, sessionAddress, permissions); * } */ - async modifyExplicitSession(explicitSession: ExplicitSession): Promise { + async modifyExplicitSession( + chainId: number, + sessionAddress: Address.Address, + permissions: Signers.Session.ExplicitParams, + ): Promise { if (!this.isInitialized || !this.walletAddress) throw new InitializationError('Cannot modify an explicit session without an existing wallet.') - const chainSessionManager = this.getChainSessionManager(explicitSession.chainId) + const chainSessionManager = this.getChainSessionManager(chainId) if (!chainSessionManager.isInitialized) { chainSessionManager.initializeWithWallet(this.walletAddress) } - await chainSessionManager.modifyExplicitSession(explicitSession) + await chainSessionManager.modifyExplicitSession(sessionAddress, permissions) - if (this.transportMode === TransportMode.POPUP) { + if (this.transport.mode === TransportMode.POPUP) { await this._loadStateFromStorage() } } @@ -781,7 +513,9 @@ export class DappClient { * @throws If the fee options cannot be fetched. {@link FeeOptionError} * @throws If the client or relevant chain is not initialized. {@link InitializationError} * - * @returns A promise that resolves with the fee options. {@link FeeOption[]} + * @returns A promise that resolves with the fee options. {@link Relayer.FeeOption[]} + * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client/get-fee-options} for more detailed documentation. * * @example * const dappClient = new DappClient('http://localhost:5173'); @@ -801,25 +535,14 @@ export class DappClient { * const txHash = await dappClient.sendTransaction(1, transactions, feeOption); * } */ - async getFeeOptions(chainId: number, transactions: Transaction[]): Promise { - const chainSessionManager = await this.getOrInitializeChainManager(chainId) + async getFeeOptions(chainId: number, transactions: Transaction[]): Promise { + if (!this.isInitialized) throw new InitializationError('Not initialized') + const chainSessionManager = this.getChainSessionManager(chainId) + if (!chainSessionManager.isInitialized) + throw new InitializationError(`ChainSessionManager for chain ${chainId} is not initialized.`) return await chainSessionManager.getFeeOptions(transactions) } - /** - * Fetches fee tokens for a chain. - * @returns A promise that resolves with the fee tokens response. {@link GetFeeTokensResponse} - * @throws If the fee tokens cannot be fetched. {@link InitializationError} - */ - async getFeeTokens(chainId: number): Promise { - const relayer = new Relayer.RpcRelayer( - getRelayerUrl(chainId, this.relayerUrl), - chainId, - getRpcUrl(chainId, this.nodesUrl, this.projectAccessKey), - ) - return await relayer.feeTokens() - } - /** * Checks if the current session has permission to execute a set of transactions on a specific chain. * @param chainId The chain ID on which to check the permissions. @@ -827,31 +550,25 @@ export class DappClient { * @returns A promise that resolves to true if the session has permission, otherwise false. */ async hasPermission(chainId: number, transactions: Transaction[]): Promise { - if (!this.isInitialized) { - return false - } - try { - const chainSessionManager = await this.getOrInitializeChainManager(chainId) - return await chainSessionManager.hasPermission(transactions) - } catch (error) { - console.warn( - `hasPermission check failed for chain ${chainId}:`, - error instanceof Error ? error.message : String(error), - ) + const chainSessionManager = this.chainSessionManagers.get(chainId) + if (!chainSessionManager || !chainSessionManager.isInitialized) { return false } + return await chainSessionManager.hasPermission(transactions) } /** * Signs and sends a transaction using an available session signer. * @param chainId The chain ID on which to send the transaction. * @param transactions An array of transactions to be executed atomically in a single batch. {@link Transaction} - * @param feeOption (Optional) The selected fee option to sponsor the transaction. {@link FeeOption} + * @param feeOption (Optional) The selected fee option to sponsor the transaction. {@link Relayer.FeeOption} * @throws {TransactionError} If the transaction fails to send or confirm. * @throws {InitializationError} If the client or relevant chain is not initialized. * * @returns A promise that resolves with the transaction hash. * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client/send-transaction} for more detailed documentation. + * * @example * const dappClient = new DappClient('http://localhost:5173'); * await dappClient.initialize(); @@ -865,8 +582,11 @@ export class DappClient { * * const txHash = await dappClient.sendTransaction(1, [transaction]); */ - async sendTransaction(chainId: number, transactions: Transaction[], feeOption?: FeeOption): Promise { - const chainSessionManager = await this.getOrInitializeChainManager(chainId) + async sendTransaction(chainId: number, transactions: Transaction[], feeOption?: Relayer.FeeOption): Promise { + if (!this.isInitialized) throw new InitializationError('Not initialized') + const chainSessionManager = this.getChainSessionManager(chainId) + if (!chainSessionManager.isInitialized) + throw new InitializationError(`ChainSessionManager for chain ${chainId} is not initialized.`) return await chainSessionManager.buildSignAndSendTransactions(transactions, feeOption) } @@ -879,6 +599,8 @@ export class DappClient { * * @returns A promise that resolves when the signing process is initiated. The signature is delivered via the `walletActionResponse` event listener. * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client/sign-message} for more detailed documentation. + * * @example * const dappClient = new DappClient('http://localhost:5173'); * await dappClient.initialize(); @@ -911,6 +633,8 @@ export class DappClient { * * @returns A promise that resolves when the signing process is initiated. The signature is returned in the `walletActionResponse` event listener. * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client/sign-typed-data} for more detailed documentation. + * * @example * const dappClient = new DappClient('http://localhost:5173'); * await dappClient.initialize(); @@ -962,57 +686,36 @@ export class DappClient { /** * Disconnects the client, clearing all session data from browser storage. * @remarks This action does not revoke the sessions on-chain. Sessions remain active until they expire or are manually revoked by the user in their wallet. - * @param options Options to control the disconnection behavior. - * @param options.keepSessionlessConnection When true, retains the latest wallet metadata so it can be restored later as a sessionless connection. Defaults to true. * @returns A promise that resolves when disconnection is complete. * + * @see {@link https://docs.sequence.xyz/sdk/typescript/v3/dapp-client/disconnect} for more detailed documentation. + * * @example * const dappClient = new DappClient('http://localhost:5173'); * await dappClient.initialize(); * * if (dappClient.isInitialized) { - * await dappClient.disconnect({ keepSessionlessConnection: true }); + * await dappClient.disconnect(); * } */ - async disconnect(options?: { keepSessionlessConnection?: boolean }): Promise { - const keepSessionlessConnection = options?.keepSessionlessConnection ?? true - - if (this.transport) { - this.transport.destroy() - } - this.transport = null + async disconnect(): Promise { + const transportMode = this.transport.mode + + this.transport.destroy() + this.transport = new DappTransport( + this.walletUrl, + transportMode, + undefined, + this.sequenceSessionStorage, + this.redirectActionHandler, + ) this.chainSessionManagers.clear() - const sessionlessSnapshot = - keepSessionlessConnection && this.walletAddress - ? { - walletAddress: this.walletAddress, - loginMethod: this.loginMethod ?? undefined, - userEmail: this.userEmail ?? undefined, - guard: this.guard, - } - : undefined - await this.sequenceStorage.clearAllData() - - if (sessionlessSnapshot) { - if (this.sequenceStorage.saveSessionlessConnectionSnapshot) { - await this.sequenceStorage.saveSessionlessConnectionSnapshot(sessionlessSnapshot) - } - this.cachedSessionlessConnection = sessionlessSnapshot - } else { - if (this.sequenceStorage.clearSessionlessConnectionSnapshot) { - await this.sequenceStorage.clearSessionlessConnectionSnapshot() - } - this.cachedSessionlessConnection = null - } - this.isInitialized = false this.walletAddress = null this.loginMethod = null this.userEmail = null - this.guard = undefined - this.hasSessionlessConnection = false this.emit('sessionsUpdated') } @@ -1028,47 +731,6 @@ export class DappClient { } } - private ensureTransport(): DappTransport { - if (!this.transport) { - if (this.transportModeSetting === TransportMode.POPUP && !this.isBrowser) { - throw new InitializationError('Popup transport requires a browser environment.') - } - this.transport = new DappTransport( - this.walletUrl, - this.transportModeSetting, - undefined, - this.sequenceSessionStorage, - this.redirectActionHandler, - ) - } - return this.transport - } - - private async applySessionlessConnectionState( - walletAddress: Address.Address, - loginMethod?: LoginMethod | null, - userEmail?: string | null, - guard?: GuardConfig, - persist: boolean = true, - ): Promise { - this.walletAddress = walletAddress - this.loginMethod = loginMethod ?? null - this.userEmail = userEmail ?? null - this.guard = guard - this.hasSessionlessConnection = true - this.isInitialized = true - this.cachedSessionlessConnection = null - this.emit('sessionsUpdated') - if (persist) { - await this.sequenceStorage.saveSessionlessConnection({ - walletAddress, - loginMethod: this.loginMethod ?? undefined, - userEmail: this.userEmail ?? undefined, - guard: this.guard, - }) - } - } - private async _requestWalletAction( action: (typeof RequestActionType)['SIGN_MESSAGE' | 'SIGN_TYPED_DATA' | 'SEND_WALLET_TRANSACTION'], payload: SignMessagePayload | SignTypedDataPayload | SendWalletTransactionPayload, @@ -1081,18 +743,17 @@ export class DappClient { try { const redirectUrl = this.origin + (this.redirectPath ? this.redirectPath : '') const path = action === RequestActionType.SEND_WALLET_TRANSACTION ? '/request/transaction' : '/request/sign' - const transport = this.ensureTransport() - if (transport.mode === TransportMode.REDIRECT) { + if (this.transport.mode === TransportMode.REDIRECT) { await this.sequenceStorage.savePendingRequest({ action, payload, chainId: chainId, }) await this.sequenceStorage.setPendingRedirectRequest(true) - await transport.sendRequest(action, redirectUrl, payload, { path }) + await this.transport.sendRequest(action, redirectUrl, payload, { path }) } else { - const response = await transport.sendRequest(action, redirectUrl, payload, { + const response = await this.transport.sendRequest(action, redirectUrl, payload, { path, }) this.emit('walletActionResponse', { action, response, chainId }) @@ -1102,34 +763,12 @@ export class DappClient { this.emit('walletActionResponse', { action, error, chainId }) throw error } finally { - if (this.transportMode === TransportMode.POPUP && this.transport) { + if (this.transport.mode === TransportMode.POPUP) { this.transport.closeWallet() } } } - /** - * @private Retrieves or creates and initializes a ChainSessionManager for a given chain ID. - * @param chainId The chain ID to get the ChainSessionManager for. - * @returns The initialized ChainSessionManager for the given chain ID. - */ - private async getOrInitializeChainManager(chainId: number): Promise { - if (!this.isInitialized || !this.walletAddress) { - throw new InitializationError('DappClient is not initialized.') - } - const manager = this.getChainSessionManager(chainId) - if (!manager.isInitialized) { - await manager.initialize() - } - if (!manager.isInitialized) { - throw new InitializationError(`ChainSessionManager for chain ${chainId} could not be initialized.`) - } - if (!manager.getImplicitSession() && manager.getExplicitSessions().length === 0) { - throw new InitializationError('No sessions are available for the requested action.') - } - return manager - } - /** * @private Retrieves or creates a ChainSessionManager for a given chain ID. * @param chainId The chain ID to get the ChainSessionManager for. @@ -1138,10 +777,9 @@ export class DappClient { private getChainSessionManager(chainId: number): ChainSessionManager { let chainSessionManager = this.chainSessionManagers.get(chainId) if (!chainSessionManager) { - const transport = this.ensureTransport() chainSessionManager = new ChainSessionManager( chainId, - transport, + this.transport, this.projectAccessKey, this.keymachineUrl, this.nodesUrl, diff --git a/packages/wallet/dapp-client/src/index.ts b/packages/wallet/dapp-client/src/index.ts index ce976c13d4..c920a0ac5b 100644 --- a/packages/wallet/dapp-client/src/index.ts +++ b/packages/wallet/dapp-client/src/index.ts @@ -4,30 +4,27 @@ export type { LoginMethod, GuardConfig, Transaction, - SignatureResponse, + SignatureSuccessResponse, + ChainSessionManagerEvent, SequenceSessionStorage, RandomPrivateKeyFn, + Session, SignMessagePayload, - SessionResponse, AddExplicitSessionPayload, + AddExplicitSessionSuccessResponsePayload, CreateNewSessionPayload, - CreateNewSessionResponse, SignTypedDataPayload, - ModifyExplicitSessionPayload, + ConnectSuccessResponsePayload, + ModifySessionSuccessResponsePayload, + ModifySessionPayload, DappClientWalletActionEventListener, DappClientExplicitSessionEventListener, TransactionRequest, SendWalletTransactionPayload, - SendWalletTransactionResponse, + SendWalletTransactionSuccessResponse, WalletActionResponse, - GetFeeTokensResponse, - FeeToken, - FeeOption, - TransportMessage, - EthAuthSettings, - ETHAuthProof, } from './types/index.js' -export { RequestActionType, TransportMode, MessageType } from './types/index.js' +export { RequestActionType, TransportMode } from './types/index.js' export { FeeOptionError, TransactionError, @@ -37,35 +34,15 @@ export { SigningError, ModifyExplicitSessionError, } from './utils/errors.js' -export { - createExplicitSessionConfig, - getExplorerUrl, - getNetwork, - getRelayerUrl, - getRpcUrl, - jsonReplacers, - jsonRevivers, - VALUE_FORWARDER_ADDRESS, -} from './utils/index.js' -export type { ExplicitSessionParams, NativeTokenSpending, SessionDuration } from './utils/index.js' +export { getExplorerUrl, jsonReplacers, jsonRevivers } from './utils/index.js' export type { SequenceStorage, ExplicitSessionData, ImplicitSessionData, - SessionlessConnectionData, PendingRequestContext, PendingPayload, } from './utils/storage.js' export { WebStorage } from './utils/storage.js' -export { - Attestation, - Permission, - Extensions, - SessionConfig, - Constants, - Payload, - Network, -} from '@0xsequence/wallet-primitives' -export type { ExplicitSessionConfig, ExplicitSession, ImplicitSession, Session } from '@0xsequence/wallet-core' -export { Signers, Wallet, Utils, Envelope, State } from '@0xsequence/wallet-core' +export { Permission, Extensions, SessionConfig } from '@0xsequence/wallet-primitives' +export { Signers, Wallet, Utils, Relayer } from '@0xsequence/wallet-core' diff --git a/packages/wallet/dapp-client/src/utils/storage.ts b/packages/wallet/dapp-client/src/utils/storage.ts index 8a56015ba9..a554f86fe6 100644 --- a/packages/wallet/dapp-client/src/utils/storage.ts +++ b/packages/wallet/dapp-client/src/utils/storage.ts @@ -1,23 +1,17 @@ +import { Attestation } from '@0xsequence/wallet-primitives' import { Address, Hex } from 'ox' import { jsonReplacers, jsonRevivers } from './index.js' import { + AddExplicitSessionPayload, + CreateNewSessionPayload, + ModifySessionPayload, LoginMethod, SignMessagePayload, SignTypedDataPayload, GuardConfig, - ETHAuthProof, SendWalletTransactionPayload, - ModifyExplicitSessionPayload, - CreateNewSessionPayload, - AddExplicitSessionPayload, } from '../types/index.js' -import { Attestation } from '../index.js' - -const isBrowser = typeof window !== 'undefined' -const hasSessionStorage = isBrowser && typeof sessionStorage !== 'undefined' -const hasIndexedDb = typeof indexedDB !== 'undefined' - export interface ExplicitSessionData { pk: Hex.Hex walletAddress: Address.Address @@ -38,17 +32,10 @@ export interface ImplicitSessionData { guard?: GuardConfig } -export interface SessionlessConnectionData { - walletAddress: Address.Address - loginMethod?: LoginMethod - userEmail?: string - guard?: GuardConfig -} - export type PendingPayload = | CreateNewSessionPayload | AddExplicitSessionPayload - | ModifyExplicitSessionPayload + | ModifySessionPayload | SignMessagePayload | SignTypedDataPayload | SendWalletTransactionPayload @@ -78,18 +65,6 @@ export interface SequenceStorage { getImplicitSession(): Promise clearImplicitSession(): Promise - saveSessionlessConnection(sessionData: SessionlessConnectionData): Promise - getSessionlessConnection(): Promise - clearSessionlessConnection(): Promise - - saveEthAuthProof(proof: ETHAuthProof): Promise - getEthAuthProof(): Promise - clearEthAuthProof(): Promise - - saveSessionlessConnectionSnapshot?(sessionData: SessionlessConnectionData): Promise - getSessionlessConnectionSnapshot?(): Promise - clearSessionlessConnectionSnapshot?(): Promise - clearAllData(): Promise } @@ -98,21 +73,13 @@ const DB_VERSION = 1 const STORE_NAME = 'userKeys' const IMPLICIT_SESSIONS_IDB_KEY = 'SequenceImplicitSession' const EXPLICIT_SESSIONS_IDB_KEY = 'SequenceExplicitSession' -const SESSIONLESS_CONNECTION_IDB_KEY = 'SequenceSessionlessConnection' -const ETH_AUTH_PROOF_IDB_KEY = 'SequenceEthAuthProof' -const SESSIONLESS_CONNECTION_SNAPSHOT_IDB_KEY = 'SequenceSessionlessConnectionSnapshot' const PENDING_REDIRECT_REQUEST_KEY = 'SequencePendingRedirect' const TEMP_SESSION_PK_KEY = 'SequencePendingTempSessionPk' const PENDING_REQUEST_CONTEXT_KEY = 'SequencePendingRequestContext' export class WebStorage implements SequenceStorage { - private inMemoryDb = new Map() - private openDB(): Promise { - if (!hasIndexedDb) { - return Promise.reject(new Error('IndexedDB is not available in this environment.')) - } return new Promise((resolve, reject) => { const request = indexedDB.open(DB_NAME, DB_VERSION) request.onerror = (event) => reject(`IndexedDB error: ${(event.target as IDBRequest).error}`) @@ -127,9 +94,6 @@ export class WebStorage implements SequenceStorage { } private async getIDBItem(key: IDBValidKey): Promise { - if (!hasIndexedDb) { - return this.inMemoryDb.get(key) as T | undefined - } const db = await this.openDB() return new Promise((resolve, reject) => { const request = db.transaction(STORE_NAME, 'readonly').objectStore(STORE_NAME).get(key) @@ -139,10 +103,6 @@ export class WebStorage implements SequenceStorage { } private async setIDBItem(key: IDBValidKey, value: unknown): Promise { - if (!hasIndexedDb) { - this.inMemoryDb.set(key, value) - return - } const db = await this.openDB() return new Promise((resolve, reject) => { const request = db.transaction(STORE_NAME, 'readwrite').objectStore(STORE_NAME).put(value, key) @@ -152,10 +112,6 @@ export class WebStorage implements SequenceStorage { } private async deleteIDBItem(key: IDBValidKey): Promise { - if (!hasIndexedDb) { - this.inMemoryDb.delete(key) - return - } const db = await this.openDB() return new Promise((resolve, reject) => { const request = db.transaction(STORE_NAME, 'readwrite').objectStore(STORE_NAME).delete(key) @@ -166,9 +122,11 @@ export class WebStorage implements SequenceStorage { async setPendingRedirectRequest(isPending: boolean): Promise { try { - if (!hasSessionStorage) return - if (isPending) sessionStorage.setItem(PENDING_REDIRECT_REQUEST_KEY, 'true') - else sessionStorage.removeItem(PENDING_REDIRECT_REQUEST_KEY) + if (isPending) { + sessionStorage.setItem(PENDING_REDIRECT_REQUEST_KEY, 'true') + } else { + sessionStorage.removeItem(PENDING_REDIRECT_REQUEST_KEY) + } } catch (error) { console.error('Failed to set pending redirect flag:', error) } @@ -176,7 +134,6 @@ export class WebStorage implements SequenceStorage { async isRedirectRequestPending(): Promise { try { - if (!hasSessionStorage) return false return sessionStorage.getItem(PENDING_REDIRECT_REQUEST_KEY) === 'true' } catch (error) { console.error('Failed to check pending redirect flag:', error) @@ -186,7 +143,6 @@ export class WebStorage implements SequenceStorage { async saveTempSessionPk(pk: Hex.Hex): Promise { try { - if (!hasSessionStorage) return sessionStorage.setItem(TEMP_SESSION_PK_KEY, pk) } catch (error) { console.error('Failed to save temp session PK:', error) @@ -195,7 +151,6 @@ export class WebStorage implements SequenceStorage { async getAndClearTempSessionPk(): Promise { try { - if (!hasSessionStorage) return null const pk = sessionStorage.getItem(TEMP_SESSION_PK_KEY) sessionStorage.removeItem(TEMP_SESSION_PK_KEY) return pk as Hex.Hex | null @@ -207,7 +162,6 @@ export class WebStorage implements SequenceStorage { async savePendingRequest(context: PendingRequestContext): Promise { try { - if (!hasSessionStorage) return sessionStorage.setItem(PENDING_REQUEST_CONTEXT_KEY, JSON.stringify(context, jsonReplacers)) } catch (error) { console.error('Failed to save pending request context:', error) @@ -216,7 +170,6 @@ export class WebStorage implements SequenceStorage { async getAndClearPendingRequest(): Promise { try { - if (!hasSessionStorage) return null const context = sessionStorage.getItem(PENDING_REQUEST_CONTEXT_KEY) if (!context) return null sessionStorage.removeItem(PENDING_REQUEST_CONTEXT_KEY) @@ -229,7 +182,6 @@ export class WebStorage implements SequenceStorage { async peekPendingRequest(): Promise { try { - if (!hasSessionStorage) return null const context = sessionStorage.getItem(PENDING_REQUEST_CONTEXT_KEY) if (!context) return null return JSON.parse(context, jsonRevivers) @@ -302,102 +254,16 @@ export class WebStorage implements SequenceStorage { } } - async saveSessionlessConnection(sessionData: SessionlessConnectionData): Promise { - try { - await this.setIDBItem(SESSIONLESS_CONNECTION_IDB_KEY, sessionData) - } catch (error) { - console.error('Failed to save sessionless connection:', error) - throw error - } - } - - async saveEthAuthProof(proof: ETHAuthProof): Promise { - try { - await this.setIDBItem(ETH_AUTH_PROOF_IDB_KEY, proof) - } catch (error) { - console.error('Failed to save ETHAuth proof:', error) - throw error - } - } - - async getSessionlessConnection(): Promise { - try { - return (await this.getIDBItem(SESSIONLESS_CONNECTION_IDB_KEY)) ?? null - } catch (error) { - console.error('Failed to retrieve sessionless connection:', error) - return null - } - } - - async getEthAuthProof(): Promise { - try { - return (await this.getIDBItem(ETH_AUTH_PROOF_IDB_KEY)) ?? null - } catch (error) { - console.error('Failed to retrieve ETHAuth proof:', error) - return null - } - } - - async clearSessionlessConnection(): Promise { - try { - await this.deleteIDBItem(SESSIONLESS_CONNECTION_IDB_KEY) - } catch (error) { - console.error('Failed to clear sessionless connection:', error) - throw error - } - } - - async clearEthAuthProof(): Promise { - try { - await this.deleteIDBItem(ETH_AUTH_PROOF_IDB_KEY) - } catch (error) { - console.error('Failed to clear ETHAuth proof:', error) - throw error - } - } - - async saveSessionlessConnectionSnapshot(sessionData: SessionlessConnectionData): Promise { - try { - await this.setIDBItem(SESSIONLESS_CONNECTION_SNAPSHOT_IDB_KEY, sessionData) - } catch (error) { - console.error('Failed to save sessionless connection snapshot:', error) - throw error - } - } - - async getSessionlessConnectionSnapshot(): Promise { - try { - return (await this.getIDBItem(SESSIONLESS_CONNECTION_SNAPSHOT_IDB_KEY)) ?? null - } catch (error) { - console.error('Failed to retrieve sessionless connection snapshot:', error) - return null - } - } - - async clearSessionlessConnectionSnapshot(): Promise { - try { - await this.deleteIDBItem(SESSIONLESS_CONNECTION_SNAPSHOT_IDB_KEY) - } catch (error) { - console.error('Failed to clear sessionless connection snapshot:', error) - throw error - } - } - async clearAllData(): Promise { try { // Clear all session storage items - if (hasSessionStorage) { - sessionStorage.removeItem(PENDING_REDIRECT_REQUEST_KEY) - sessionStorage.removeItem(TEMP_SESSION_PK_KEY) - sessionStorage.removeItem(PENDING_REQUEST_CONTEXT_KEY) - } + sessionStorage.removeItem(PENDING_REDIRECT_REQUEST_KEY) + sessionStorage.removeItem(TEMP_SESSION_PK_KEY) + sessionStorage.removeItem(PENDING_REQUEST_CONTEXT_KEY) // Clear all IndexedDB items await this.clearExplicitSessions() await this.clearImplicitSession() - await this.clearSessionlessConnection() - await this.clearEthAuthProof() - await this.clearSessionlessConnectionSnapshot() } catch (error) { console.error('Failed to clear all data:', error) throw error diff --git a/packages/wallet/primitives/package.json b/packages/wallet/primitives/package.json index e0e283de61..ead0a78231 100644 --- a/packages/wallet/primitives/package.json +++ b/packages/wallet/primitives/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/wallet-primitives", - "version": "3.0.5", + "version": "0.0.0", "license": "Apache-2.0", "type": "module", "publishConfig": { @@ -13,8 +13,7 @@ "test": "vitest run", "test:coverage": "vitest run --coverage", "typecheck": "tsc --noEmit", - "clean": "rimraf dist", - "lint": "eslint . --max-warnings 0" + "clean": "rimraf dist" }, "exports": { ".": { @@ -23,13 +22,12 @@ } }, "devDependencies": { - "@repo/eslint-config": "workspace:^", "@repo/typescript-config": "workspace:^", - "@vitest/coverage-v8": "^4.0.18", - "typescript": "^5.9.3", - "vitest": "^4.0.18" + "@vitest/coverage-v8": "^3.2.4", + "typescript": "^5.8.3", + "vitest": "^3.2.1" }, "dependencies": { - "ox": "^0.9.17" + "ox": "^0.7.2" } } diff --git a/packages/wallet/wdk/src/sequence/handlers/authcode-pkce.ts b/packages/wallet/wdk/src/sequence/handlers/authcode-pkce.ts index 308e2809fa..6029f41141 100644 --- a/packages/wallet/wdk/src/sequence/handlers/authcode-pkce.ts +++ b/packages/wallet/wdk/src/sequence/handlers/authcode-pkce.ts @@ -1,54 +1,45 @@ -import { Hex, Bytes } from 'ox' +import { Hex, Address, Bytes } from 'ox' import { Handler } from './handler.js' import * as Db from '../../dbs/index.js' import { Signatures } from '../signatures.js' import * as Identity from '@0xsequence/identity-instrument' import { IdentitySigner } from '../../identity/signer.js' import { AuthCodeHandler } from './authcode.js' -import type { WdkEnv } from '../../env.js' -import type { CommitAuthArgs } from '../../dbs/auth-commitments.js' export class AuthCodePkceHandler extends AuthCodeHandler implements Handler { constructor( - signupKind: 'google-pkce' | `custom-${string}`, + signupKind: 'google-pkce', issuer: string, - oauthUrl: string, audience: string, nitro: Identity.IdentityInstrument, signatures: Signatures, commitments: Db.AuthCommitments, authKeys: Db.AuthKeys, - env?: WdkEnv, ) { - super(signupKind, issuer, oauthUrl, audience, nitro, signatures, commitments, authKeys, env) + super(signupKind, issuer, audience, nitro, signatures, commitments, authKeys) } - public async commitAuth(target: string, args: CommitAuthArgs) { + public async commitAuth(target: string, isSignUp: boolean, state?: string, signer?: string) { let challenge = new Identity.AuthCodePkceChallenge(this.issuer, this.audience, this.redirectUri) - if (args.type === 'reauth') { - challenge = challenge.withSigner({ address: args.signer, keyType: Identity.KeyType.Ethereum_Secp256k1 }) + if (signer) { + challenge = challenge.withSigner({ address: signer, keyType: Identity.KeyType.Ethereum_Secp256k1 }) } const { verifier, loginHint, challenge: codeChallenge } = await this.nitroCommitVerifier(challenge) - const state = args.state ?? Hex.fromBytes(Bytes.random(32)) + if (!state) { + state = Hex.fromBytes(Bytes.random(32)) + } - const base = { + await this.commitments.set({ id: state, - kind: this.signupKind as Db.AuthCommitment['kind'], + kind: this.signupKind, verifier, challenge: codeChallenge, target, metadata: {}, - } - - if (args.type === 'reauth') { - await this.commitments.set({ ...base, type: 'reauth', signer: args.signer }) - } else if (args.type === 'add-signer') { - await this.commitments.set({ ...base, type: 'add-signer', wallet: args.wallet }) - } else { - await this.commitments.set({ ...base, type: 'auth' }) - } + isSignUp, + }) - const searchParams = this.serializeQuery({ + const searchParams = new URLSearchParams({ code_challenge: codeChallenge, code_challenge_method: 'S256', client_id: this.audience, @@ -59,7 +50,8 @@ export class AuthCodePkceHandler extends AuthCodeHandler implements Handler { state, }) - return `${this.oauthUrl}?${searchParams}` + const oauthUrl = this.oauthUrl() + return `${oauthUrl}?${searchParams.toString()}` } public async completeAuth( diff --git a/packages/wallet/wdk/src/sequence/handlers/authcode.ts b/packages/wallet/wdk/src/sequence/handlers/authcode.ts index 4b5d5922b5..bb8a1b315d 100644 --- a/packages/wallet/wdk/src/sequence/handlers/authcode.ts +++ b/packages/wallet/wdk/src/sequence/handlers/authcode.ts @@ -6,33 +6,23 @@ import * as Identity from '@0xsequence/identity-instrument' import { SignerUnavailable, SignerReady, SignerActionable, BaseSignatureRequest } from '../types/signature-request.js' import { IdentitySigner } from '../../identity/signer.js' import { IdentityHandler } from './identity.js' -import { Kinds } from '../types/signer.js' -import type { NavigationLike, WdkEnv } from '../../env.js' -import type { CommitAuthArgs } from '../../dbs/auth-commitments.js' export class AuthCodeHandler extends IdentityHandler implements Handler { protected redirectUri: string = '' constructor( - public readonly signupKind: 'apple' | 'google-pkce' | `custom-${string}`, + public readonly signupKind: 'apple' | 'google-pkce', public readonly issuer: string, - protected readonly oauthUrl: string, public readonly audience: string, nitro: Identity.IdentityInstrument, signatures: Signatures, protected readonly commitments: Db.AuthCommitments, authKeys: Db.AuthKeys, - env?: WdkEnv, ) { - super(nitro, authKeys, signatures, Identity.IdentityType.OIDC, env) + super(nitro, authKeys, signatures, Identity.IdentityType.OIDC) } public get kind() { - if (this.signupKind === 'google-pkce') { - // Keep Google PKCE on the canonical kind so Google signers created before - // canonicalization still resolve as `login-google`. - return Kinds.LoginGoogle - } return 'login-' + this.signupKind } @@ -40,33 +30,30 @@ export class AuthCodeHandler extends IdentityHandler implements Handler { this.redirectUri = redirectUri } - public async commitAuth(target: string, args: CommitAuthArgs) { - const state = args.state ?? Hex.fromBytes(Bytes.random(32)) + public async commitAuth(target: string, isSignUp: boolean, state?: string, signer?: string) { + if (!state) { + state = Hex.fromBytes(Bytes.random(32)) + } - const base = { + await this.commitments.set({ id: state, - kind: this.signupKind as Db.AuthCommitment['kind'], + kind: this.signupKind, + signer, target, metadata: {}, - } - - if (args.type === 'reauth') { - await this.commitments.set({ ...base, type: 'reauth', signer: args.signer }) - } else if (args.type === 'add-signer') { - await this.commitments.set({ ...base, type: 'add-signer', wallet: args.wallet }) - } else { - await this.commitments.set({ ...base, type: 'auth' }) - } + isSignUp, + }) - const searchParams = this.serializeQuery({ + const searchParams = new URLSearchParams({ client_id: this.audience, redirect_uri: this.redirectUri, response_type: 'code', + scope: 'openid', state, - ...(this.signupKind === 'apple' ? {} : { scope: 'openid profile email' }), }) - return `${this.oauthUrl}?${searchParams}` + const oauthUrl = this.oauthUrl() + return `${oauthUrl}?${searchParams.toString()}` } public async completeAuth( @@ -74,7 +61,7 @@ export class AuthCodeHandler extends IdentityHandler implements Handler { code: string, ): Promise<[IdentitySigner, { [key: string]: string }]> { let challenge = new Identity.AuthCodeChallenge(this.issuer, this.audience, this.redirectUri, code) - if (commitment.type === 'reauth') { + if (commitment.signer) { challenge = challenge.withSigner({ address: commitment.signer, keyType: Identity.KeyType.Ethereum_Secp256k1 }) } await this.nitroCommitVerifier(challenge) @@ -107,33 +94,21 @@ export class AuthCodeHandler extends IdentityHandler implements Handler { status: 'actionable', message: 'request-redirect', handle: async () => { - const navigation = this.getNavigation() - const url = await this.commitAuth(navigation.getPathname(), { - type: 'reauth', - state: request.id, - signer: address, - }) - navigation.redirect(url) + const url = await this.commitAuth(window.location.pathname, false, request.id, address) + window.location.href = url return true }, } } - protected serializeQuery(params: Record): string { - const searchParamsCtor = this.env.urlSearchParams ?? (globalThis as any).URLSearchParams - if (searchParamsCtor) { - return new searchParamsCtor(params).toString() - } - return Object.entries(params) - .map(([key, value]) => `${encodeURIComponent(key)}=${encodeURIComponent(value)}`) - .join('&') - } - - private getNavigation(): NavigationLike { - const navigation = this.env.navigation - if (!navigation) { - throw new Error('navigation is not available') + protected oauthUrl() { + switch (this.issuer) { + case 'https://accounts.google.com': + return 'https://accounts.google.com/o/oauth2/v2/auth' + case 'https://appleid.apple.com': + return 'https://appleid.apple.com/auth/authorize' + default: + throw new Error('unsupported-issuer') } - return navigation } } diff --git a/packages/wallet/wdk/src/sequence/manager.ts b/packages/wallet/wdk/src/sequence/manager.ts index c7eecf3294..0dbe84ef86 100644 --- a/packages/wallet/wdk/src/sequence/manager.ts +++ b/packages/wallet/wdk/src/sequence/manager.ts @@ -1,11 +1,10 @@ -import { Bundler, Signers as CoreSigners, State } from '@0xsequence/wallet-core' -import { Relayer } from '@0xsequence/relayer' +import { Signers as CoreSigners, Relayer, State } from '@0xsequence/wallet-core' + import { IdentityInstrument } from '@0xsequence/identity-instrument' import { createAttestationVerifyingFetch } from '@0xsequence/tee-verifier' import { Config, Constants, Context, Extensions, Network } from '@0xsequence/wallet-primitives' import { Address } from 'ox' import * as Db from '../dbs/index.js' -import { resolveWdkEnv, type WdkEnv } from '../env.js' import { Cron } from './cron.js' import { Devices } from './devices.js' import { Guards, GuardRole } from './guards.js' @@ -14,7 +13,6 @@ import { AuthCodePkceHandler, DevicesHandler, Handler, - IdTokenHandler, MnemonicHandler, OtpHandler, PasskeysHandler, @@ -29,34 +27,14 @@ import { Signers } from './signers.js' import { Transactions, TransactionsInterface } from './transactions.js' import { Kinds } from './types/signer.js' import { Wallets, WalletsInterface } from './wallets.js' -import { GuardHandler, PromptCodeHandler } from './handlers/guard.js' +import { GuardHandler } from './handlers/guard.js' import { PasskeyCredential } from '../dbs/index.js' -import { PromptMnemonicHandler } from './handlers/mnemonic.js' -import { PromptIdTokenHandler } from './handlers/idtoken.js' -import { PromptOtpHandler } from './handlers/otp.js' -import { defaultPasskeyProvider, type PasskeyProvider } from './passkeys-provider.js' - -type CustomIdentityProvider = - | { - kind: `custom-${string}` - authMethod: 'id-token' - issuer: string - clientId: string - } - | { - kind: `custom-${string}` - authMethod: 'authcode' | 'authcode-pkce' - issuer: string - oauthUrl: string - clientId: string - } export type ManagerOptions = { verbose?: boolean extensions?: Extensions.Extensions context?: Context.Context - context4337?: Context.Context guest?: Address.Address encryptedPksDb?: CoreSigners.Pk.Encrypted.EncryptedPksDb @@ -71,20 +49,14 @@ export type ManagerOptions = { dbPruningInterval?: number - env?: WdkEnv - passkeyProvider?: PasskeyProvider - stateProvider?: State.Provider networks?: Network.Network[] relayers?: Relayer.Relayer[] | (() => Relayer.Relayer[]) - bundlers?: Bundler.Bundler[] + bundlers?: Relayer.Bundler[] guardUrl?: string guardAddresses?: Record - nonWitnessableSigners?: Address.Address[] - - // The default guard topology MUST have a placeholder address for the guard address - defaultGuardTopology?: Config.Topology + defaultGuardTopology?: Config.SignerLeaf defaultRecoverySettings?: RecoverySettings // EIP-6963 support @@ -92,7 +64,7 @@ export type ManagerOptions = { identity?: { url?: string - fetch?: typeof fetch + fetch?: typeof window.fetch verifyAttestation?: boolean expectedPcr0?: string[] scope?: string @@ -102,85 +74,20 @@ export type ManagerOptions = { google?: { enabled: boolean clientId: string - authMethod?: 'authcode-pkce' | 'id-token' } apple?: { enabled: boolean clientId: string - authMethod?: 'authcode' | 'id-token' } - customProviders?: CustomIdentityProvider[] - } -} - -export type ResolvedIdentityOptions = { - url: string - fetch?: typeof fetch - verifyAttestation: boolean - expectedPcr0?: string[] - scope?: string - email: { - enabled: boolean } - google: { - enabled: boolean - clientId: string - authMethod: 'authcode-pkce' | 'id-token' - } - apple: { - enabled: boolean - clientId: string - authMethod: 'authcode' | 'id-token' - } - customProviders?: CustomIdentityProvider[] -} - -export type ResolvedManagerOptions = { - verbose: boolean - - extensions: Extensions.Extensions - context: Context.Context - context4337: Context.Context - guest: Address.Address - - encryptedPksDb: CoreSigners.Pk.Encrypted.EncryptedPksDb - managerDb: Db.Wallets - transactionsDb: Db.Transactions - signaturesDb: Db.Signatures - messagesDb: Db.Messages - authCommitmentsDb: Db.AuthCommitments - authKeysDb: Db.AuthKeys - recoveryDb: Db.Recovery - passkeyCredentialsDb: Db.PasskeyCredentials - - dbPruningInterval: number - - env: WdkEnv - passkeyProvider: PasskeyProvider - - stateProvider: State.Provider - networks: Network.Network[] - relayers: Relayer.Relayer[] | (() => Relayer.Relayer[]) - bundlers: Bundler.Bundler[] - guardUrl: string - guardAddresses: Record - - nonWitnessableSigners: Address.Address[] - - defaultGuardTopology: Config.Topology - defaultRecoverySettings: RecoverySettings - - multiInjectedProviderDiscovery: boolean - - identity: ResolvedIdentityOptions } export const ManagerOptionsDefaults = { verbose: false, - extensions: Extensions.Rc5, - context: Context.Rc5, - context4337: Context.Rc5_4337, + extensions: Extensions.Rc3, + context: Context.Rc3, + context4337: Context.Rc3_4337, guest: Constants.DefaultGuestAddress, encryptedPksDb: new CoreSigners.Pk.Encrypted.EncryptedPksDb(), @@ -195,46 +102,26 @@ export const ManagerOptionsDefaults = { dbPruningInterval: 1000 * 60 * 60 * 24, // 24 hours - passkeyProvider: defaultPasskeyProvider, - - stateProvider: typeof fetch !== 'undefined' ? new State.Sequence.Provider(undefined, fetch) : undefined, + stateProvider: new State.Sequence.Provider(), networks: Network.ALL, - relayers: () => { - if (typeof window !== 'undefined') { - return [Relayer.LocalRelayer.createFromWindow(window)].filter((r) => r !== undefined) - } - return [] - }, + relayers: () => [Relayer.Standard.LocalRelayer.createFromWindow(window)].filter((r) => r !== undefined), bundlers: [], - nonWitnessableSigners: [] as Address.Address[], - - guardUrl: 'https://guard.sequence.app', + guardUrl: 'https://dev-guard.sequence.app', guardAddresses: { - wallet: '0x26f3D30F41FA897309Ae804A2AFf15CEb1dA5742', - sessions: '0xF6Bc87F5F2edAdb66737E32D37b46423901dfEF1', - } as Record, + wallet: '0xa2e70CeaB3Eb145F32d110383B75B330fA4e288a', + sessions: '0x18002Fc09deF9A47437cc64e270843dE094f5984', + } as Record, // TODO: change to the actual guard address defaultGuardTopology: { - type: 'nested', + // TODO: Move this somewhere else + type: 'signer', + address: '0x0000000000000000000000000000000000000000', // will be replaced by the actual guard address weight: 1n, - threshold: 1n, - tree: [ - { - type: 'signer', - address: Constants.PlaceholderAddress, - weight: 1n, - }, - { - type: 'signer', - // Sequence dev multisig, as recovery guard signer - address: '0x007a47e6BF40C1e0ed5c01aE42fDC75879140bc4', - weight: 1n, - }, - ], - } as Config.NestedLeaf, + } as Config.SignerLeaf, defaultSessionsTopology: { + // TODO: Move this somewhere else type: 'sapient-signer', weight: 1n, } as Omit, @@ -242,14 +129,14 @@ export const ManagerOptionsDefaults = { defaultRecoverySettings: { requiredDeltaTime: 2592000n, // 30 days (in seconds) minTimestamp: 0n, - includeTestnets: false, }, multiInjectedProviderDiscovery: true, identity: { - url: 'https://identity.sequence.app', - fetch: typeof window !== 'undefined' ? window.fetch : undefined, + // TODO: change to prod url once deployed + url: 'https://dev-identity.sequence-dev.app', + fetch: window.fetch, verifyAttestation: true, email: { enabled: false, @@ -257,12 +144,10 @@ export const ManagerOptionsDefaults = { google: { enabled: false, clientId: '', - authMethod: 'authcode-pkce' as const, }, apple: { enabled: false, clientId: '', - authMethod: 'authcode' as const, }, }, } @@ -271,117 +156,17 @@ export const CreateWalletOptionsDefaults = { useGuard: false, } -export function applyManagerOptionsDefaults(options?: ManagerOptions): ResolvedManagerOptions { - const env = resolveWdkEnv(options?.env) - - const identity: ResolvedIdentityOptions = { - ...ManagerOptionsDefaults.identity, - ...options?.identity, - email: { ...ManagerOptionsDefaults.identity.email, ...options?.identity?.email }, - google: { ...ManagerOptionsDefaults.identity.google, ...options?.identity?.google }, - apple: { ...ManagerOptionsDefaults.identity.apple, ...options?.identity?.apple }, - } - - if (!identity.fetch && env.fetch) { - identity.fetch = env.fetch - } - - let encryptedPksDb = options?.encryptedPksDb ?? ManagerOptionsDefaults.encryptedPksDb - if (!options?.encryptedPksDb && options?.env) { - encryptedPksDb = new CoreSigners.Pk.Encrypted.EncryptedPksDb(undefined, undefined, env) - } - - let authKeysDb = options?.authKeysDb ?? ManagerOptionsDefaults.authKeysDb - if (!options?.authKeysDb && options?.env) { - authKeysDb = new Db.AuthKeys(undefined, env) - } - - let stateProvider = options?.stateProvider ?? ManagerOptionsDefaults.stateProvider - if (!options?.stateProvider && options?.env?.fetch) { - stateProvider = new State.Sequence.Provider(undefined, options.env.fetch) - } else if (!stateProvider && env.fetch) { - stateProvider = new State.Sequence.Provider(undefined, env.fetch) - } - - if (!stateProvider) { - throw new Error('stateProvider is required. Provide ManagerOptions.stateProvider or env.fetch') - } - - const extensions = options?.extensions ?? ManagerOptionsDefaults.extensions - const defaultGuardTopology = options?.defaultGuardTopology ?? ManagerOptionsDefaults.defaultGuardTopology - - // Merge and normalize non-witnessable signers. - // We always include the sessions extension address for the active extensions set. - const nonWitnessable = new Set() - for (const address of ManagerOptionsDefaults.nonWitnessableSigners ?? []) { - nonWitnessable.add(address.toLowerCase()) - } - for (const address of options?.nonWitnessableSigners ?? []) { - nonWitnessable.add(address.toLowerCase()) - } - nonWitnessable.add(extensions.sessions.toLowerCase()) - - // Include static signer leaves from the guard topology (e.g. recovery guard signer), - // but ignore the placeholder address that is later replaced per-role. - if (defaultGuardTopology) { - const guardTopologySigners = Config.getSigners(defaultGuardTopology) - for (const signer of guardTopologySigners.signers) { - if (Address.isEqual(signer, Constants.PlaceholderAddress)) { - continue - } - nonWitnessable.add(signer.toLowerCase()) - } - for (const signer of guardTopologySigners.sapientSigners) { - nonWitnessable.add(signer.address.toLowerCase()) - } - } - +export function applyManagerOptionsDefaults(options?: ManagerOptions) { return { - verbose: options?.verbose ?? ManagerOptionsDefaults.verbose, - - extensions, - context: options?.context ?? ManagerOptionsDefaults.context, - context4337: options?.context4337 ?? ManagerOptionsDefaults.context4337, - guest: options?.guest ?? ManagerOptionsDefaults.guest, - - encryptedPksDb, - managerDb: options?.managerDb ?? ManagerOptionsDefaults.managerDb, - transactionsDb: options?.transactionsDb ?? ManagerOptionsDefaults.transactionsDb, - signaturesDb: options?.signaturesDb ?? ManagerOptionsDefaults.signaturesDb, - messagesDb: options?.messagesDb ?? ManagerOptionsDefaults.messagesDb, - authCommitmentsDb: options?.authCommitmentsDb ?? ManagerOptionsDefaults.authCommitmentsDb, - recoveryDb: options?.recoveryDb ?? ManagerOptionsDefaults.recoveryDb, - authKeysDb, - passkeyCredentialsDb: options?.passkeyCredentialsDb ?? ManagerOptionsDefaults.passkeyCredentialsDb, - - dbPruningInterval: options?.dbPruningInterval ?? ManagerOptionsDefaults.dbPruningInterval, - - env, - passkeyProvider: options?.passkeyProvider ?? ManagerOptionsDefaults.passkeyProvider, - - stateProvider, - networks: options?.networks ?? ManagerOptionsDefaults.networks, - relayers: options?.relayers ?? ManagerOptionsDefaults.relayers, - bundlers: options?.bundlers ?? ManagerOptionsDefaults.bundlers, - guardUrl: options?.guardUrl ?? ManagerOptionsDefaults.guardUrl, - guardAddresses: options?.guardAddresses ?? ManagerOptionsDefaults.guardAddresses, - - nonWitnessableSigners: Array.from(nonWitnessable) as Address.Address[], - - defaultGuardTopology, - defaultRecoverySettings: options?.defaultRecoverySettings ?? ManagerOptionsDefaults.defaultRecoverySettings, - - multiInjectedProviderDiscovery: - options?.multiInjectedProviderDiscovery ?? ManagerOptionsDefaults.multiInjectedProviderDiscovery, - - identity, + ...ManagerOptionsDefaults, + ...options, + identity: { ...ManagerOptionsDefaults.identity, ...options?.identity }, } } export type RecoverySettings = { requiredDeltaTime: bigint minTimestamp: bigint - includeTestnets?: boolean } export type Databases = { @@ -408,11 +193,9 @@ export type Sequence = { readonly networks: Network.Network[] readonly relayers: Relayer.Relayer[] - readonly bundlers: Bundler.Bundler[] - - readonly nonWitnessableSigners: ReadonlySet + readonly bundlers: Relayer.Bundler[] - readonly defaultGuardTopology: Config.Topology + readonly defaultGuardTopology: Config.SignerLeaf readonly defaultRecoverySettings: RecoverySettings readonly guardUrl: string @@ -438,8 +221,6 @@ export type Shared = { readonly sequence: Sequence readonly databases: Databases - readonly env: WdkEnv - readonly passkeyProvider: PasskeyProvider readonly handlers: Map @@ -572,12 +353,12 @@ export class Manager { const ops = applyManagerOptionsDefaults(options) // Build relayers list - const relayers: Relayer.Relayer[] = [] + let relayers: Relayer.Relayer[] = [] // Add EIP-6963 relayers if enabled if (ops.multiInjectedProviderDiscovery) { try { - relayers.push(...Relayer.EIP6963.getRelayers()) + relayers.push(...Relayer.Standard.EIP6963.getRelayers()) } catch (error) { console.warn('Failed to initialize EIP-6963 relayers:', error) } @@ -601,10 +382,6 @@ export class Manager { relayers, bundlers: ops.bundlers, - nonWitnessableSigners: new Set( - (ops.nonWitnessableSigners ?? []).map((address) => address.toLowerCase() as Address.Address), - ), - defaultGuardTopology: ops.defaultGuardTopology, defaultRecoverySettings: ops.defaultRecoverySettings, @@ -626,9 +403,6 @@ export class Manager { pruningInterval: ops.dbPruningInterval, }, - env: ops.env, - passkeyProvider: ops.passkeyProvider, - modules: {} as any, handlers: new Map(), } @@ -661,7 +435,6 @@ export class Manager { modules.signatures, shared.sequence.extensions, shared.sequence.stateProvider, - shared.passkeyProvider, ) shared.handlers.set(Kinds.LoginPasskey, this.passkeysHandler) @@ -684,124 +457,36 @@ export class Manager { const identityInstrument = new IdentityInstrument(ops.identity.url, ops.identity.scope, verifyingFetch) if (ops.identity.email?.enabled) { - this.otpHandler = new OtpHandler(identityInstrument, modules.signatures, shared.databases.authKeys, shared.env) + this.otpHandler = new OtpHandler(identityInstrument, modules.signatures, shared.databases.authKeys) shared.handlers.set(Kinds.LoginEmailOtp, this.otpHandler) } if (ops.identity.google?.enabled) { - if (ops.identity.google.authMethod === 'id-token') { - shared.handlers.set( - Kinds.LoginGoogle, - new IdTokenHandler( - 'google-id-token', - 'https://accounts.google.com', - ops.identity.google.clientId, - identityInstrument, - modules.signatures, - shared.databases.authKeys, - shared.env, - ), - ) - } else { - shared.handlers.set( - Kinds.LoginGoogle, - new AuthCodePkceHandler( - 'google-pkce', - 'https://accounts.google.com', - 'https://accounts.google.com/o/oauth2/v2/auth', - ops.identity.google.clientId, - identityInstrument, - modules.signatures, - shared.databases.authCommitments, - shared.databases.authKeys, - shared.env, - ), - ) - } + shared.handlers.set( + Kinds.LoginGooglePkce, + new AuthCodePkceHandler( + 'google-pkce', + 'https://accounts.google.com', + ops.identity.google.clientId, + identityInstrument, + modules.signatures, + shared.databases.authCommitments, + shared.databases.authKeys, + ), + ) } if (ops.identity.apple?.enabled) { - if (ops.identity.apple.authMethod === 'id-token') { - shared.handlers.set( - Kinds.LoginApple, - new IdTokenHandler( - 'apple-id-token', - 'https://appleid.apple.com', - ops.identity.apple.clientId, - identityInstrument, - modules.signatures, - shared.databases.authKeys, - shared.env, - ), - ) - } else { - shared.handlers.set( - Kinds.LoginApple, - new AuthCodeHandler( - 'apple', - 'https://appleid.apple.com', - 'https://appleid.apple.com/auth/authorize', - ops.identity.apple.clientId, - identityInstrument, - modules.signatures, - shared.databases.authCommitments, - shared.databases.authKeys, - shared.env, - ), - ) - } - } - if (ops.identity.customProviders?.length) { - for (const provider of ops.identity.customProviders) { - switch (provider.authMethod) { - case 'id-token': - shared.handlers.set( - provider.kind, - new IdTokenHandler( - provider.kind, - provider.issuer, - provider.clientId, - identityInstrument, - modules.signatures, - shared.databases.authKeys, - shared.env, - ), - ) - break - case 'authcode': - shared.handlers.set( - provider.kind, - new AuthCodeHandler( - provider.kind, - provider.issuer, - provider.oauthUrl, - provider.clientId, - identityInstrument, - modules.signatures, - shared.databases.authCommitments, - shared.databases.authKeys, - shared.env, - ), - ) - break - case 'authcode-pkce': - shared.handlers.set( - provider.kind, - new AuthCodePkceHandler( - provider.kind, - provider.issuer, - provider.oauthUrl, - provider.clientId, - identityInstrument, - modules.signatures, - shared.databases.authCommitments, - shared.databases.authKeys, - shared.env, - ), - ) - break - default: - throw new Error('unsupported auth method') - } - } + shared.handlers.set( + Kinds.LoginApple, + new AuthCodeHandler( + 'apple', + 'https://appleid.apple.com', + ops.identity.apple.clientId, + identityInstrument, + modules.signatures, + shared.databases.authCommitments, + shared.databases.authKeys, + ), + ) } shared.modules = modules @@ -815,30 +500,18 @@ export class Manager { } } - public registerMnemonicUI(onPromptMnemonic: PromptMnemonicHandler) { + public registerMnemonicUI(onPromptMnemonic: (respond: (mnemonic: string) => Promise) => Promise) { return this.mnemonicHandler.registerUI(onPromptMnemonic) } - public registerOtpUI(onPromptOtp: PromptOtpHandler) { + public registerOtpUI(onPromptOtp: (recipient: string, respond: (otp: string) => Promise) => Promise) { return this.otpHandler?.registerUI(onPromptOtp) || (() => {}) } - public registerIdTokenUI(onPromptIdToken: PromptIdTokenHandler) { - const unregisters: (() => void)[] = [] - - this.shared.handlers.forEach((handler) => { - if (handler instanceof IdTokenHandler) { - unregisters.push(handler.registerUI(onPromptIdToken)) - } - }) - - return () => { - unregisters.forEach((unregister) => unregister()) - } - } - - public registerGuardUI(onPromptCode: PromptCodeHandler) { - return this.guardHandler?.registerUI(onPromptCode) || (() => {}) + public registerGuardUI( + onPromptOtp: (codeType: 'TOTP' | 'PIN', respond: (otp: string) => Promise) => Promise, + ) { + return this.guardHandler?.registerUI(onPromptOtp) || (() => {}) } public async setRedirectPrefix(prefix: string) { diff --git a/packages/wallet/wdk/test/test-ssr-safety.mjs b/packages/wallet/wdk/test/test-ssr-safety.mjs index 55ef7723db..71eb361702 100644 --- a/packages/wallet/wdk/test/test-ssr-safety.mjs +++ b/packages/wallet/wdk/test/test-ssr-safety.mjs @@ -1,12 +1,13 @@ #!/usr/bin/env node +/* global console, process */ /** * Comprehensive SSR Safety Test (Runtime Execution) - * + * * This script tests that the entire wdk package can be imported and used in a Node.js * environment (SSR context) without throwing errors about missing window. - * + * * It executes the code at runtime to catch any SSR issues. - * + * * Run with: node test-ssr-comprehensive.mjs */ @@ -52,24 +53,25 @@ try { // Use the package name from package.json const packageName = packageJson.name console.log(`Importing ${packageName}...`) - + // Try to resolve the package const packagePath = require.resolve(packageName) console.log(` Package resolved to: ${packagePath}`) - + // Import the package wdk = await import(packageName) console.log('✓ Successfully imported package') console.log(' Top-level exports:', Object.keys(wdk)) - } catch (error) { // Check if it's an SSR-related error - if (error.message.includes('window is not defined') || - error.message.includes('window') || - error.message.includes('document is not defined') || - error.message.includes('document') || - error.message.includes('localStorage') || - error.message.includes('sessionStorage')) { + if ( + error.message.includes('window is not defined') || + error.message.includes('window') || + error.message.includes('document is not defined') || + error.message.includes('document') || + error.message.includes('localStorage') || + error.message.includes('sessionStorage') + ) { errors.push(`SSR ERROR: Package accesses browser globals at module load time: ${error.message}`) if (error.stack) { console.error('\nError stack:') @@ -81,7 +83,7 @@ try { console.error('Stack:', error.stack) } } - + // Don't exit immediately - let the summary show the error if (errors.length > 0) { // Skip remaining tests if import failed @@ -98,83 +100,84 @@ if (!wdk) { console.log('Skipping - package import failed') } else { async function testExports(obj, path = '', depth = 0) { - if (depth > 5) return // Prevent infinite recursion - - for (const [key, value] of Object.entries(obj)) { - const currentPath = path ? `${path}.${key}` : key - - try { - // Skip if it's a circular reference or already tested - if (value === null || value === undefined) { - continue - } - - // Test accessing the value (this executes any getters) - const accessed = value - - // Test different types - if (typeof accessed === 'function') { - // Try to get function properties - try { - const props = Object.getOwnPropertyNames(accessed) - if (props.length > 0 && depth < 3) { - // Test static properties on functions - for (const prop of props.slice(0, 3)) { + if (depth > 5) return // Prevent infinite recursion + + for (const [key, value] of Object.entries(obj)) { + const currentPath = path ? `${path}.${key}` : key + + try { + // Skip if it's a circular reference or already tested + if (value === null || value === undefined) { + continue + } + + // Test accessing the value (this executes any getters) + const accessed = value + + // Test different types + if (typeof accessed === 'function') { + // Try to get function properties + try { + const props = Object.getOwnPropertyNames(accessed) + if (props.length > 0 && depth < 3) { + // Test static properties on functions + for (const prop of props.slice(0, 3)) { + try { + const propValue = accessed[prop] + if (typeof propValue === 'object' && propValue !== null && depth < 2) { + await testExports(propValue, `${currentPath}.${prop}`, depth + 1) + } + } catch (err) { + if (err.message.includes('window') || err.message.includes('document')) { + errors.push(`${currentPath}.${prop}: ${err.message}`) + } + } + } + } + } catch (err) { + if (err.message.includes('window') || err.message.includes('document')) { + errors.push(`${currentPath}: ${err.message}`) + } + } + } else if (typeof accessed === 'object' && accessed !== null) { + // Test object properties + if (Array.isArray(accessed)) { + // Test array elements + for (let i = 0; i < Math.min(accessed.length, 3); i++) { try { - const propValue = accessed[prop] - if (typeof propValue === 'object' && propValue !== null && depth < 2) { - await testExports(propValue, `${currentPath}.${prop}`, depth + 1) + const item = accessed[i] + if (typeof item === 'object' && item !== null && depth < 3) { + await testExports(item, `${currentPath}[${i}]`, depth + 1) } } catch (err) { if (err.message.includes('window') || err.message.includes('document')) { - errors.push(`${currentPath}.${prop}: ${err.message}`) + errors.push(`${currentPath}[${i}]: ${err.message}`) } } } - } - } catch (err) { - if (err.message.includes('window') || err.message.includes('document')) { - errors.push(`${currentPath}: ${err.message}`) + } else { + // Test object properties recursively + await testExports(accessed, currentPath, depth + 1) } } - } else if (typeof accessed === 'object' && accessed !== null) { - // Test object properties - if (Array.isArray(accessed)) { - // Test array elements - for (let i = 0; i < Math.min(accessed.length, 3); i++) { - try { - const item = accessed[i] - if (typeof item === 'object' && item !== null && depth < 3) { - await testExports(item, `${currentPath}[${i}]`, depth + 1) - } - } catch (err) { - if (err.message.includes('window') || err.message.includes('document')) { - errors.push(`${currentPath}[${i}]: ${err.message}`) - } - } - } - } else { - // Test object properties recursively - await testExports(accessed, currentPath, depth + 1) - } - } - - } catch (error) { - // Check if it's an SSR-related error - if (error.message.includes('window is not defined') || + } catch (error) { + // Check if it's an SSR-related error + if ( + error.message.includes('window is not defined') || error.message.includes('window') || error.message.includes('document is not defined') || error.message.includes('document') || error.message.includes('localStorage') || - error.message.includes('sessionStorage')) { - errors.push(`${currentPath}: ${error.message}`) - } else { - // Other errors are warnings (might be expected, like missing dependencies) - warnings.push(`${currentPath}: ${error.message}`) + error.message.includes('sessionStorage') + ) { + errors.push(`${currentPath}: ${error.message}`) + } else { + // Other errors are warnings (might be expected, like missing dependencies) + warnings.push(`${currentPath}: ${error.message}`) + } } } } -} // Test all top-level exports console.log('Testing all exports recursively...') @@ -191,43 +194,46 @@ if (!wdk) { } else { // Test ManagerOptionsDefaults try { - if (wdk.Sequence?.ManagerOptionsDefaults) { - console.log('Testing ManagerOptionsDefaults...') - const defaults = wdk.Sequence.ManagerOptionsDefaults - - // Access all properties - Object.keys(defaults).forEach(key => { - try { - const value = defaults[key] - console.log(` ✓ ${key}: ${typeof value}`) - - // If it's a function, try calling it - if (typeof value === 'function' && key === 'relayers') { - const result = value() - console.log(` Called ${key}(), returned:`, Array.isArray(result) ? `${result.length} items` : typeof result) - } - } catch (err) { - if (err.message.includes('window') || err.message.includes('document')) { - errors.push(`ManagerOptionsDefaults.${key}: ${err.message}`) + if (wdk.Sequence?.ManagerOptionsDefaults) { + console.log('Testing ManagerOptionsDefaults...') + const defaults = wdk.Sequence.ManagerOptionsDefaults + + // Access all properties + Object.keys(defaults).forEach((key) => { + try { + const value = defaults[key] + console.log(` ✓ ${key}: ${typeof value}`) + + // If it's a function, try calling it + if (typeof value === 'function' && key === 'relayers') { + const result = value() + console.log( + ` Called ${key}(), returned:`, + Array.isArray(result) ? `${result.length} items` : typeof result, + ) + } + } catch (err) { + if (err.message.includes('window') || err.message.includes('document')) { + errors.push(`ManagerOptionsDefaults.${key}: ${err.message}`) + } } - } - }) - } -} catch (err) { - if (err.message.includes('window') || err.message.includes('document')) { - errors.push(`ManagerOptionsDefaults: ${err.message}`) + }) + } + } catch (err) { + if (err.message.includes('window') || err.message.includes('document')) { + errors.push(`ManagerOptionsDefaults: ${err.message}`) + } } -} -// Test applyManagerOptionsDefaults function -try { - if (wdk.Sequence?.applyManagerOptionsDefaults) { - console.log('Testing applyManagerOptionsDefaults...') - const result = wdk.Sequence.applyManagerOptionsDefaults() - console.log(' ✓ Function executed successfully') - console.log(' Result keys:', Object.keys(result).slice(0, 5).join(', '), '...') - } -} catch (err) { + // Test applyManagerOptionsDefaults function + try { + if (wdk.Sequence?.applyManagerOptionsDefaults) { + console.log('Testing applyManagerOptionsDefaults...') + const result = wdk.Sequence.applyManagerOptionsDefaults() + console.log(' ✓ Function executed successfully') + console.log(' Result keys:', Object.keys(result).slice(0, 5).join(', '), '...') + } + } catch (err) { if (err.message.includes('window') || err.message.includes('document')) { errors.push(`applyManagerOptionsDefaults: ${err.message}`) } @@ -244,37 +250,37 @@ if (!wdk) { } else { // Get the package path and try importing from dist try { - const packagePath = require.resolve(packageJson.name) - const packageDir = dirname(packagePath) - - // Try to import from the exports field if available - if (packageJson.exports) { - for (const [exportPath, exportConfig] of Object.entries(packageJson.exports)) { - if (exportPath === '.') { - const modulePath = exportConfig.default || exportConfig.types - if (modulePath) { - try { - const fullPath = join(packageDir, '..', modulePath) - console.log(`Testing import from ${exportPath}...`) - const subModule = await import(fullPath) - console.log(` ✓ Imported successfully`) - - // Test accessing exports - const subExports = Object.keys(subModule) - if (subExports.length > 0) { - console.log(` Exports: ${subExports.slice(0, 5).join(', ')}${subExports.length > 5 ? '...' : ''}`) - } - } catch (err) { - if (err.message.includes('window') || err.message.includes('document')) { - errors.push(`Import ${exportPath}: ${err.message}`) - } else if (!err.message.includes('Cannot find module')) { - warnings.push(`Import ${exportPath}: ${err.message}`) + const packagePath = require.resolve(packageJson.name) + const packageDir = dirname(packagePath) + + // Try to import from the exports field if available + if (packageJson.exports) { + for (const [exportPath, exportConfig] of Object.entries(packageJson.exports)) { + if (exportPath === '.') { + const modulePath = exportConfig.default || exportConfig.types + if (modulePath) { + try { + const fullPath = join(packageDir, '..', modulePath) + console.log(`Testing import from ${exportPath}...`) + const subModule = await import(fullPath) + console.log(` ✓ Imported successfully`) + + // Test accessing exports + const subExports = Object.keys(subModule) + if (subExports.length > 0) { + console.log(` Exports: ${subExports.slice(0, 5).join(', ')}${subExports.length > 5 ? '...' : ''}`) + } + } catch (err) { + if (err.message.includes('window') || err.message.includes('document')) { + errors.push(`Import ${exportPath}: ${err.message}`) + } else if (!err.message.includes('Cannot find module')) { + warnings.push(`Import ${exportPath}: ${err.message}`) + } } } } } } - } } catch (err) { warnings.push(`Could not test sub-modules: ${err.message}`) } @@ -290,7 +296,7 @@ if (errors.length === 0) { console.log('The package can be safely imported and used in a Node.js/SSR environment.') if (warnings.length > 0) { console.log(`\n⚠️ ${warnings.length} warning(s) (non-SSR related):`) - warnings.slice(0, 5).forEach(warn => console.log(` - ${warn}`)) + warnings.slice(0, 5).forEach((warn) => console.log(` - ${warn}`)) if (warnings.length > 5) { console.log(` ... and ${warnings.length - 5} more`) } @@ -298,11 +304,11 @@ if (errors.length === 0) { process.exit(0) } else { console.log('\n❌ ERRORS FOUND:') - errors.forEach(err => console.log(` - ${err}`)) + errors.forEach((err) => console.log(` - ${err}`)) console.log('\n❌ SSR Safety Test FAILED!') if (warnings.length > 0) { console.log(`\n⚠️ ${warnings.length} warning(s):`) - warnings.slice(0, 5).forEach(warn => console.log(` - ${warn}`)) + warnings.slice(0, 5).forEach((warn) => console.log(` - ${warn}`)) } process.exit(1) } diff --git a/playgrounds/next/.gitignore b/playgrounds/next/.gitignore new file mode 100644 index 0000000000..8f322f0d8f --- /dev/null +++ b/playgrounds/next/.gitignore @@ -0,0 +1,35 @@ +# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. + +# dependencies +/node_modules +/.pnp +.pnp.js + +# testing +/coverage + +# next.js +/.next/ +/out/ + +# production +/build + +# misc +.DS_Store +*.pem + +# debug +npm-debug.log* +yarn-debug.log* +yarn-error.log* + +# local env files +.env*.local + +# vercel +.vercel + +# typescript +*.tsbuildinfo +next-env.d.ts diff --git a/playgrounds/next/next.config.mjs b/playgrounds/next/next.config.mjs new file mode 100644 index 0000000000..8831ff653a --- /dev/null +++ b/playgrounds/next/next.config.mjs @@ -0,0 +1,20 @@ +import bundleAnalyzer from '@next/bundle-analyzer' + +const withBundleAnalyzer = bundleAnalyzer({ + enabled: process.env.ANALYZE === 'true', +}) + +/** @type {import('next').NextConfig} */ +const nextConfig = { + experimental: { + externalDir: true, + }, + webpack(config) { + config.resolve.extensionAlias = { + '.js': ['.js', '.ts'], + } + return config + }, +} + +export default withBundleAnalyzer(nextConfig) diff --git a/playgrounds/next/package.json b/playgrounds/next/package.json new file mode 100644 index 0000000000..2cb3c92089 --- /dev/null +++ b/playgrounds/next/package.json @@ -0,0 +1,31 @@ +{ + "name": "next-app", + "private": true, + "scripts": { + "analyze": "ANALYZE=true next build", + "dev": "next dev", + "build": "next build", + "start": "next start", + "lint": "next lint" + }, + "dependencies": { + "@next/bundle-analyzer": "^15.2.4", + "@tanstack/react-query": ">=5.45.1", + "next": "15.4.10", + "react": ">=18.3.1", + "react-dom": ">=18.3.1", + "viem": "2.*", + "wagmi": "workspace:*" + }, + "devDependencies": { + "@types/node": "^22.14.1", + "@types/react": ">=18.3.1", + "@types/react-dom": ">=18.3.0", + "bufferutil": "^4.0.8", + "encoding": "^0.1.13", + "lokijs": "^1.5.12", + "pino-pretty": "^13.0.0", + "supports-color": "^9.4.0", + "utf-8-validate": "^6.0.5" + } +} diff --git a/playgrounds/next/src/app/contracts.ts b/playgrounds/next/src/app/contracts.ts new file mode 100644 index 0000000000..d7d66754a2 --- /dev/null +++ b/playgrounds/next/src/app/contracts.ts @@ -0,0 +1,202 @@ +export const wagmiContractConfig = { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: [ + { inputs: [], stateMutability: 'nonpayable', type: 'constructor' }, + { + anonymous: false, + inputs: [ + { + indexed: true, + name: 'owner', + type: 'address', + }, + { + indexed: true, + name: 'approved', + type: 'address', + }, + { + indexed: true, + name: 'tokenId', + type: 'uint256', + }, + ], + name: 'Approval', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + name: 'owner', + type: 'address', + }, + { + indexed: true, + name: 'operator', + type: 'address', + }, + { + indexed: false, + name: 'approved', + type: 'bool', + }, + ], + name: 'ApprovalForAll', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + name: 'from', + type: 'address', + }, + { indexed: true, name: 'to', type: 'address' }, + { + indexed: true, + name: 'tokenId', + type: 'uint256', + }, + ], + name: 'Transfer', + type: 'event', + }, + { + inputs: [ + { name: 'to', type: 'address' }, + { name: 'tokenId', type: 'uint256' }, + ], + name: 'approve', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ name: 'owner', type: 'address' }], + name: 'balanceOf', + outputs: [{ name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ name: 'tokenId', type: 'uint256' }], + name: 'getApproved', + outputs: [{ name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { name: 'owner', type: 'address' }, + { name: 'operator', type: 'address' }, + ], + name: 'isApprovedForAll', + outputs: [{ name: '', type: 'bool' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'mint', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: 'tokenId', type: 'uint256' }], + name: 'mint', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'name', + outputs: [{ name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ name: 'tokenId', type: 'uint256' }], + name: 'ownerOf', + outputs: [{ name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { name: 'from', type: 'address' }, + { name: 'to', type: 'address' }, + { name: 'tokenId', type: 'uint256' }, + ], + name: 'safeTransferFrom', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { name: 'from', type: 'address' }, + { name: 'to', type: 'address' }, + { name: 'tokenId', type: 'uint256' }, + { name: '_data', type: 'bytes' }, + ], + name: 'safeTransferFrom', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { name: 'operator', type: 'address' }, + { name: 'approved', type: 'bool' }, + ], + name: 'setApprovalForAll', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ name: 'interfaceId', type: 'bytes4' }], + name: 'supportsInterface', + outputs: [{ name: '', type: 'bool' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'symbol', + outputs: [{ name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ name: 'tokenId', type: 'uint256' }], + name: 'tokenURI', + outputs: [{ name: '', type: 'string' }], + stateMutability: 'pure', + type: 'function', + }, + { + inputs: [], + name: 'totalSupply', + outputs: [{ name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { name: 'from', type: 'address' }, + { name: 'to', type: 'address' }, + { name: 'tokenId', type: 'uint256' }, + ], + name: 'transferFrom', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + ], +} as const diff --git a/playgrounds/next/src/app/globals.css b/playgrounds/next/src/app/globals.css new file mode 100644 index 0000000000..0733a7ee6b --- /dev/null +++ b/playgrounds/next/src/app/globals.css @@ -0,0 +1,21 @@ +:root { + background-color: #181818; + color: rgba(255, 255, 255, 0.87); + color-scheme: light dark; + font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; + font-synthesis: none; + font-weight: 400; + line-height: 1.5; + text-rendering: optimizeLegibility; + + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + -webkit-text-size-adjust: 100%; +} + +@media (prefers-color-scheme: light) { + :root { + background-color: #f8f8f8; + color: #181818; + } +} diff --git a/playgrounds/next/src/app/layout.tsx b/playgrounds/next/src/app/layout.tsx new file mode 100644 index 0000000000..72ec934a03 --- /dev/null +++ b/playgrounds/next/src/app/layout.tsx @@ -0,0 +1,30 @@ +import type { Metadata } from 'next' +import { Inter } from 'next/font/google' +import { headers } from 'next/headers' +import type { ReactNode } from 'react' +import { cookieToInitialState } from 'wagmi' +import './globals.css' + +import { getConfig } from '../wagmi' +import { Providers } from './providers' + +const inter = Inter({ subsets: ['latin'] }) + +export const metadata: Metadata = { + title: 'Create Wagmi', + description: 'Generated by create-wagmi', +} + +export default async function RootLayout(props: { children: ReactNode }) { + const initialState = cookieToInitialState( + getConfig(), + (await headers()).get('cookie'), + ) + return ( + + + {props.children} + + + ) +} diff --git a/playgrounds/next/src/app/page.tsx b/playgrounds/next/src/app/page.tsx new file mode 100644 index 0000000000..33c1bf0abb --- /dev/null +++ b/playgrounds/next/src/app/page.tsx @@ -0,0 +1,412 @@ +'use client' + +import type { FormEvent } from 'react' +import { type Hex, formatEther, parseAbi, parseEther } from 'viem' +import { + type BaseError, + useAccount, + useAccountEffect, + useBalance, + useBlockNumber, + useChainId, + useConfig, + useConnect, + useConnections, + useConnectorClient, + useDisconnect, + useEnsName, + useReadContract, + useReadContracts, + useSendTransaction, + useSignMessage, + useSwitchAccount, + useSwitchChain, + useWaitForTransactionReceipt, + useWriteContract, +} from 'wagmi' +import { switchChain } from 'wagmi/actions' +import { optimism, sepolia } from 'wagmi/chains' + +import { wagmiContractConfig } from './contracts' + +export default function App() { + useAccountEffect({ + onConnect(_data) { + // console.log('onConnect', data) + }, + onDisconnect() { + // console.log('onDisconnect') + }, + }) + + return ( + <> + + + + + + + + + + + + + + + + ) +} + +function Account() { + const account = useAccount() + const { disconnect } = useDisconnect() + const { data: ensName } = useEnsName({ + address: account.address, + }) + + return ( +
+

Account

+ +
+ account: {account.address} {ensName} +
+ chainId: {account.chainId} +
+ status: {account.status} +
+ + {account.status === 'connected' && ( + + )} +
+ ) +} + +function Connect() { + const chainId = useChainId() + const { connectors, connect, status, error } = useConnect() + + return ( +
+

Connect

+ {connectors.map((connector) => ( + + ))} +
{status}
+
{error?.message}
+
+ ) +} + +function SwitchAccount() { + const account = useAccount() + const { connectors, switchAccount } = useSwitchAccount() + + return ( +
+

Switch Account

+ + {connectors.map((connector) => ( + + ))} +
+ ) +} + +function SwitchChain() { + const chainId = useChainId() + const { chains, switchChain, error } = useSwitchChain() + + return ( +
+

Switch Chain

+ + {chains.map((chain) => ( + + ))} + + {error?.message} +
+ ) +} + +function SignMessage() { + const { data, signMessage } = useSignMessage() + + return ( +
+

Sign Message

+ +
{ + event.preventDefault() + const formData = new FormData(event.target as HTMLFormElement) + signMessage({ message: formData.get('message') as string }) + }} + > + + +
+ + {data} +
+ ) +} + +function Connections() { + const connections = useConnections() + + return ( +
+

Connections

+ + {connections.map((connection) => ( +
+
connector {connection.connector.name}
+
accounts: {JSON.stringify(connection.accounts)}
+
chainId: {connection.chainId}
+
+ ))} +
+ ) +} + +function Balance() { + const { address } = useAccount() + + const { data: default_ } = useBalance({ address }) + const { data: account_ } = useBalance({ address }) + const { data: optimism_ } = useBalance({ + address, + chainId: optimism.id, + }) + + return ( +
+

Balance

+ +
+ Balance (Default Chain):{' '} + {!!default_?.value && formatEther(default_.value)} +
+
+ Balance (Account Chain):{' '} + {!!account_?.value && formatEther(account_.value)} +
+
+ Balance (Optimism Chain):{' '} + {!!optimism_?.value && formatEther(optimism_.value)} +
+
+ ) +} + +function BlockNumber() { + const { data: default_ } = useBlockNumber({ watch: true }) + const { data: account_ } = useBlockNumber({ + watch: true, + }) + const { data: optimism_ } = useBlockNumber({ + chainId: optimism.id, + watch: true, + }) + + return ( +
+

Block Number

+ +
Block Number (Default Chain): {default_?.toString()}
+
Block Number (Account Chain): {account_?.toString()}
+
Block Number (Optimism): {optimism_?.toString()}
+
+ ) +} + +function ConnectorClient() { + const { data, error } = useConnectorClient() + return ( +
+

Connector Client

+ client {data?.account?.address} {data?.chain?.id} + {error?.message} +
+ ) +} + +function SendTransaction() { + const { data: hash, error, isPending, sendTransaction } = useSendTransaction() + + async function submit(e: FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const to = formData.get('address') as Hex + const value = formData.get('value') as string + sendTransaction({ to, value: parseEther(value) }) + } + + const { isLoading: isConfirming, isSuccess: isConfirmed } = + useWaitForTransactionReceipt({ + hash, + }) + + return ( +
+

Send Transaction

+
+ + + +
+ {hash &&
Transaction Hash: {hash}
} + {isConfirming && 'Waiting for confirmation...'} + {isConfirmed && 'Transaction confirmed.'} + {error && ( +
Error: {(error as BaseError).shortMessage || error.message}
+ )} +
+ ) +} + +function ReadContract() { + const { data: balance } = useReadContract({ + ...wagmiContractConfig, + functionName: 'balanceOf', + args: ['0x03A71968491d55603FFe1b11A9e23eF013f75bCF'], + }) + + return ( +
+

Read Contract

+
Balance: {balance?.toString()}
+
+ ) +} + +function ReadContracts() { + const { data } = useReadContracts({ + allowFailure: false, + contracts: [ + { + ...wagmiContractConfig, + functionName: 'balanceOf', + args: ['0x03A71968491d55603FFe1b11A9e23eF013f75bCF'], + }, + { + ...wagmiContractConfig, + functionName: 'ownerOf', + args: [69n], + }, + { + ...wagmiContractConfig, + functionName: 'totalSupply', + }, + ], + }) + const [balance, ownerOf, totalSupply] = data || [] + + return ( +
+

Read Contract

+
Balance: {balance?.toString()}
+
Owner of Token 69: {ownerOf?.toString()}
+
Total Supply: {totalSupply?.toString()}
+
+ ) +} + +function WriteContract() { + const { data: hash, error, isPending, writeContract } = useWriteContract() + + async function submit(e: FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const tokenId = formData.get('tokenId') as string + writeContract({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: parseAbi(['function mint(uint256 tokenId)']), + functionName: 'mint', + args: [BigInt(tokenId)], + }) + } + + const { isLoading: isConfirming, isSuccess: isConfirmed } = + useWaitForTransactionReceipt({ + hash, + }) + + return ( +
+

Write Contract

+
+ + +
+ {hash &&
Transaction Hash: {hash}
} + {isConfirming && 'Waiting for confirmation...'} + {isConfirmed && 'Transaction confirmed.'} + {error && ( +
Error: {(error as BaseError).shortMessage || error.message}
+ )} +
+ ) +} + +function Repro() { + const config = useConfig() + const chainId = useChainId() + + // biome-ignore lint/suspicious/noConsoleLog: + console.log('chainId from useChainId is', chainId) + return ( +
+ Current Chain Id: {chainId} + + +
+ ) +} diff --git a/playgrounds/next/src/app/providers.tsx b/playgrounds/next/src/app/providers.tsx new file mode 100644 index 0000000000..3f0082dd22 --- /dev/null +++ b/playgrounds/next/src/app/providers.tsx @@ -0,0 +1,23 @@ +'use client' + +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import { type ReactNode, useState } from 'react' +import { type State, WagmiProvider } from 'wagmi' + +import { getConfig } from '../wagmi' + +export function Providers(props: { + children: ReactNode + initialState?: State +}) { + const [config] = useState(() => getConfig()) + const [queryClient] = useState(() => new QueryClient()) + + return ( + + + {props.children} + + + ) +} diff --git a/playgrounds/next/src/wagmi.ts b/playgrounds/next/src/wagmi.ts new file mode 100644 index 0000000000..0c9db90a5d --- /dev/null +++ b/playgrounds/next/src/wagmi.ts @@ -0,0 +1,31 @@ +import { http, cookieStorage, createConfig, createStorage } from 'wagmi' +import { mainnet, optimism, sepolia } from 'wagmi/chains' +import { injected, metaMask, walletConnect } from 'wagmi/connectors' + +export function getConfig() { + return createConfig({ + chains: [mainnet, sepolia, optimism], + connectors: [ + injected(), + walletConnect({ + projectId: process.env.NEXT_PUBLIC_WC_PROJECT_ID!, + }), + metaMask(), + ], + storage: createStorage({ + storage: cookieStorage, + }), + ssr: true, + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + [optimism.id]: http(), + }, + }) +} + +declare module 'wagmi' { + interface Register { + config: ReturnType + } +} diff --git a/playgrounds/next/tsconfig.json b/playgrounds/next/tsconfig.json new file mode 100644 index 0000000000..9eb40a20d5 --- /dev/null +++ b/playgrounds/next/tsconfig.json @@ -0,0 +1,24 @@ +{ + "compilerOptions": { + "target": "ESNext", + "lib": ["dom", "dom.iterable", "esnext"], + "allowJs": true, + "skipLibCheck": true, + "strict": true, + "noEmit": true, + "esModuleInterop": true, + "module": "esnext", + "moduleResolution": "bundler", + "resolveJsonModule": true, + "isolatedModules": true, + "jsx": "preserve", + "incremental": true, + "plugins": [ + { + "name": "next" + } + ] + }, + "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"], + "exclude": ["node_modules"] +} diff --git a/playgrounds/nuxt/.gitignore b/playgrounds/nuxt/.gitignore new file mode 100644 index 0000000000..4a7f73a2ed --- /dev/null +++ b/playgrounds/nuxt/.gitignore @@ -0,0 +1,24 @@ +# Nuxt dev/build outputs +.output +.data +.nuxt +.nitro +.cache +dist + +# Node dependencies +node_modules + +# Logs +logs +*.log + +# Misc +.DS_Store +.fleet +.idea + +# Local env files +.env +.env.* +!.env.example diff --git a/playgrounds/nuxt/app.vue b/playgrounds/nuxt/app.vue new file mode 100644 index 0000000000..98b46bf528 --- /dev/null +++ b/playgrounds/nuxt/app.vue @@ -0,0 +1,28 @@ + + + diff --git a/playgrounds/nuxt/components/Account.vue b/playgrounds/nuxt/components/Account.vue new file mode 100644 index 0000000000..33f1491dac --- /dev/null +++ b/playgrounds/nuxt/components/Account.vue @@ -0,0 +1,22 @@ + + + diff --git a/playgrounds/nuxt/components/Connect.vue b/playgrounds/nuxt/components/Connect.vue new file mode 100644 index 0000000000..93320448c0 --- /dev/null +++ b/playgrounds/nuxt/components/Connect.vue @@ -0,0 +1,19 @@ + + + diff --git a/playgrounds/nuxt/nuxt.config.ts b/playgrounds/nuxt/nuxt.config.ts new file mode 100644 index 0000000000..adfe7fd2d8 --- /dev/null +++ b/playgrounds/nuxt/nuxt.config.ts @@ -0,0 +1,7 @@ +import { defineNuxtConfig } from 'nuxt/config' + +// https://nuxt.com/docs/api/configuration/nuxt-config +export default defineNuxtConfig({ + devtools: { enabled: true }, + modules: ['@wagmi/vue/nuxt'], +}) diff --git a/playgrounds/nuxt/package.json b/playgrounds/nuxt/package.json new file mode 100644 index 0000000000..6f5ff9b1a6 --- /dev/null +++ b/playgrounds/nuxt/package.json @@ -0,0 +1,20 @@ +{ + "name": "nuxt-app", + "private": true, + "type": "module", + "scripts": { + "build": "nuxt build", + "dev": "nuxt dev", + "generate": "nuxt generate", + "preview": "nuxt preview", + "_postinstall": "nuxt prepare" + }, + "dependencies": { + "@tanstack/vue-query": ">=5.45.0", + "@wagmi/vue": "workspace:*", + "nuxt": "^3.19.0", + "viem": "2.*", + "vue": ">=3.4.21", + "vue-router": "^4.3.2" + } +} diff --git a/playgrounds/nuxt/plugins/wagmi.ts b/playgrounds/nuxt/plugins/wagmi.ts new file mode 100644 index 0000000000..b6abe5bcd2 --- /dev/null +++ b/playgrounds/nuxt/plugins/wagmi.ts @@ -0,0 +1,10 @@ +import { VueQueryPlugin } from '@tanstack/vue-query' +import { WagmiPlugin } from '@wagmi/vue' +import { defineNuxtPlugin } from 'nuxt/app' + +import { config } from '../wagmi' + +// TODO: Move to @wagmi/vue/nuxt nitro plugin +export default defineNuxtPlugin((nuxtApp) => { + nuxtApp.vueApp.use(WagmiPlugin, { config }).use(VueQueryPlugin, {}) +}) diff --git a/playgrounds/nuxt/public/favicon.ico b/playgrounds/nuxt/public/favicon.ico new file mode 100644 index 0000000000..18993ad91c Binary files /dev/null and b/playgrounds/nuxt/public/favicon.ico differ diff --git a/playgrounds/nuxt/server/tsconfig.json b/playgrounds/nuxt/server/tsconfig.json new file mode 100644 index 0000000000..b9ed69c19e --- /dev/null +++ b/playgrounds/nuxt/server/tsconfig.json @@ -0,0 +1,3 @@ +{ + "extends": "../.nuxt/tsconfig.server.json" +} diff --git a/playgrounds/nuxt/tsconfig.json b/playgrounds/nuxt/tsconfig.json new file mode 100644 index 0000000000..4b34df1571 --- /dev/null +++ b/playgrounds/nuxt/tsconfig.json @@ -0,0 +1,3 @@ +{ + "extends": "./.nuxt/tsconfig.json" +} diff --git a/playgrounds/nuxt/wagmi.ts b/playgrounds/nuxt/wagmi.ts new file mode 100644 index 0000000000..83e8569ea8 --- /dev/null +++ b/playgrounds/nuxt/wagmi.ts @@ -0,0 +1,29 @@ +import { http, cookieStorage, createConfig, createStorage } from '@wagmi/vue' +import { mainnet, optimism, sepolia } from '@wagmi/vue/chains' +import { injected, metaMask, walletConnect } from '@wagmi/vue/connectors' + +export const config = createConfig({ + chains: [mainnet, sepolia, optimism], + connectors: [ + injected(), + walletConnect({ + projectId: process.env.NUXT_PUBLIC_WC_PROJECT_ID!, + }), + metaMask(), + ], + storage: createStorage({ + storage: cookieStorage, + }), + ssr: true, + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + [optimism.id]: http(), + }, +}) + +declare module '@wagmi/vue' { + interface Register { + config: typeof config + } +} diff --git a/playgrounds/vite-core/.gitignore b/playgrounds/vite-core/.gitignore new file mode 100644 index 0000000000..a547bf36d8 --- /dev/null +++ b/playgrounds/vite-core/.gitignore @@ -0,0 +1,24 @@ +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +pnpm-debug.log* +lerna-debug.log* + +node_modules +dist +dist-ssr +*.local + +# Editor directories and files +.vscode/* +!.vscode/extensions.json +.idea +.DS_Store +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? diff --git a/playgrounds/vite-core/index.html b/playgrounds/vite-core/index.html new file mode 100644 index 0000000000..0e8cfb2692 --- /dev/null +++ b/playgrounds/vite-core/index.html @@ -0,0 +1,12 @@ + + + + + + Vite Core + + +
+ + + diff --git a/playgrounds/vite-core/package.json b/playgrounds/vite-core/package.json new file mode 100644 index 0000000000..c420b46e8e --- /dev/null +++ b/playgrounds/vite-core/package.json @@ -0,0 +1,24 @@ +{ + "name": "vite-core", + "private": true, + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "@wagmi/connectors": "workspace:*", + "@wagmi/core": "workspace:*", + "react": ">=18.3.1", + "react-dom": ">=18.3.1", + "viem": "2.*" + }, + "devDependencies": { + "@types/react": ">=18.3.1", + "@types/react-dom": ">=18.3.0", + "@vitejs/plugin-react": "^4.2.1", + "buffer": "^6.0.3", + "vite": "^7.3.0" + } +} diff --git a/playgrounds/vite-core/src/App.tsx b/playgrounds/vite-core/src/App.tsx new file mode 100644 index 0000000000..3c8646be39 --- /dev/null +++ b/playgrounds/vite-core/src/App.tsx @@ -0,0 +1,186 @@ +import { + type GetBalanceReturnType, + type GetBlockNumberReturnType, + connect, + disconnect, + getAccount, + getBalance, + getBlockNumber, + reconnect, + switchAccount, + watchAccount, + watchBlockNumber, +} from '@wagmi/core' +import { useEffect, useReducer, useState } from 'react' + +import { formatEther } from 'viem' +import { config } from './wagmi' + +function App() { + useEffect(() => { + reconnect(config) + }, []) + + return ( + <> + + + + + + + ) +} + +function Account() { + const [account, setAccount] = useState(getAccount(config)) + + useEffect(() => { + return watchAccount(config, { + onChange(data) { + setAccount(data) + }, + }) + }, []) + + return ( +
+

Account

+ +
+ account: {account.address} +
+ chainId: {account.chainId} +
+ status: {account.status} +
+ + {account.status === 'connected' && ( + + )} +
+ ) +} + +function Connect() { + const [, rerender] = useReducer((count) => count + 1, 0) + + useEffect(() => { + return config.subscribe(({ connections }) => connections, rerender) + }, []) + + return ( +
+

Connect

+ + {config.connectors.map((connector) => ( + + ))} +
+ ) +} + +function SwitchAccount() { + const [, rerender] = useReducer((count) => count + 1, 0) + + useEffect(() => { + return config.subscribe( + ({ connections, current }) => ({ connections, current }), + rerender, + ) + }, []) + + return ( +
+

SwitchAccount

+ + {config.connectors + .filter((connector) => config.state.connections.has(connector.uid)) + .map((connector) => ( + + ))} +
+ ) +} + +function Balance() { + const [account, setAccount] = useState(getAccount(config)) + + useEffect(() => { + return watchAccount(config, { + onChange(data) { + setAccount(data) + }, + }) + }, []) + + ///////////////////////////////////////////////////////// + + const [balance, setBalance] = useState() + + useEffect(() => { + if (!account.address) return + return watchBlockNumber(config, { + async onBlockNumber() { + try { + const balance = await getBalance(config, { + address: account.address!, + }) + setBalance(balance) + } catch (error) { + console.error('Error fetching balance', error) + } + }, + }) + }, [account.address]) + + return ( +
+

Balance

+ +
Balance: {!!balance?.value && formatEther(balance.value)}
+
+ ) +} + +function BlockNumber() { + const [blockNumber, setBlockNumber] = useState< + GetBlockNumberReturnType | undefined + >() + + useEffect(() => { + ;(async () => { + setBlockNumber(await getBlockNumber(config)) + + watchBlockNumber(config, { onBlockNumber: setBlockNumber }) + })() + }, []) + + return ( +
+

Block Number

+ +
Block Number (Default Chain): {blockNumber?.toString()}
+
+ ) +} + +export default App diff --git a/playgrounds/vite-core/src/index.css b/playgrounds/vite-core/src/index.css new file mode 100644 index 0000000000..0733a7ee6b --- /dev/null +++ b/playgrounds/vite-core/src/index.css @@ -0,0 +1,21 @@ +:root { + background-color: #181818; + color: rgba(255, 255, 255, 0.87); + color-scheme: light dark; + font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; + font-synthesis: none; + font-weight: 400; + line-height: 1.5; + text-rendering: optimizeLegibility; + + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + -webkit-text-size-adjust: 100%; +} + +@media (prefers-color-scheme: light) { + :root { + background-color: #f8f8f8; + color: #181818; + } +} diff --git a/playgrounds/vite-core/src/main.tsx b/playgrounds/vite-core/src/main.tsx new file mode 100644 index 0000000000..180d9e1fc0 --- /dev/null +++ b/playgrounds/vite-core/src/main.tsx @@ -0,0 +1,16 @@ +import React from 'react' +import ReactDOM from 'react-dom/client' +import './index.css' + +import { Buffer } from 'buffer' + +// `@coinbase-wallet/sdk` uses `Buffer` +globalThis.Buffer = Buffer + +import App from './App.tsx' + +ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render( + + + , +) diff --git a/playgrounds/vite-core/src/vite-env.d.ts b/playgrounds/vite-core/src/vite-env.d.ts new file mode 100644 index 0000000000..11f02fe2a0 --- /dev/null +++ b/playgrounds/vite-core/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/playgrounds/vite-core/src/wagmi.ts b/playgrounds/vite-core/src/wagmi.ts new file mode 100644 index 0000000000..d6152f9d24 --- /dev/null +++ b/playgrounds/vite-core/src/wagmi.ts @@ -0,0 +1,22 @@ +import { coinbaseWallet, metaMask, walletConnect } from '@wagmi/connectors' +import { http, createConfig, createStorage } from '@wagmi/core' +import { mainnet, optimism, sepolia } from '@wagmi/core/chains' + +export const config = createConfig({ + chains: [mainnet, sepolia, optimism], + connectors: [ + walletConnect({ projectId: import.meta.env.VITE_WC_PROJECT_ID }), + coinbaseWallet(), + metaMask(), + ], + storage: createStorage({ storage: localStorage, key: 'vite-core' }), + transports: { + [mainnet.id]: http( + 'https://eth-mainnet.g.alchemy.com/v2/StF61Ht3J9nXAojZX-b21LVt9l0qDL38', + ), + [sepolia.id]: http( + 'https://eth-sepolia.g.alchemy.com/v2/roJyEHxkj7XWg1T9wmYnxvktDodQrFAS', + ), + [optimism.id]: http(), + }, +}) diff --git a/playgrounds/vite-core/tsconfig.json b/playgrounds/vite-core/tsconfig.json new file mode 100644 index 0000000000..36d04ef376 --- /dev/null +++ b/playgrounds/vite-core/tsconfig.json @@ -0,0 +1,28 @@ +{ + "compilerOptions": { + "target": "ESNext", + "lib": ["DOM", "DOM.Iterable", "ESNext"], + "module": "ESNext", + "skipLibCheck": true, + + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "react-jsx", + + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true, + + "paths": { + "@wagmi/connectors": ["../../packages/connectors/src/exports"], + "@wagmi/core": ["../../packages/core/src/exports"], + "@wagmi/core/*": ["../../packages/core/src/exports/*"] + } + }, + "include": ["src"], + "references": [{ "path": "./tsconfig.node.json" }] +} diff --git a/playgrounds/vite-core/tsconfig.node.json b/playgrounds/vite-core/tsconfig.node.json new file mode 100644 index 0000000000..42872c59f5 --- /dev/null +++ b/playgrounds/vite-core/tsconfig.node.json @@ -0,0 +1,10 @@ +{ + "compilerOptions": { + "composite": true, + "skipLibCheck": true, + "module": "ESNext", + "moduleResolution": "bundler", + "allowSyntheticDefaultImports": true + }, + "include": ["vite.config.ts"] +} diff --git a/playgrounds/vite-core/vite.config.ts b/playgrounds/vite-core/vite.config.ts new file mode 100644 index 0000000000..36f7f4e1bc --- /dev/null +++ b/playgrounds/vite-core/vite.config.ts @@ -0,0 +1,7 @@ +import react from '@vitejs/plugin-react' +import { defineConfig } from 'vite' + +// https://vitejs.dev/config/ +export default defineConfig({ + plugins: [react()], +}) diff --git a/playgrounds/vite-react/.gitignore b/playgrounds/vite-react/.gitignore new file mode 100644 index 0000000000..1b226cc615 --- /dev/null +++ b/playgrounds/vite-react/.gitignore @@ -0,0 +1,26 @@ +src/generated.ts + +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +pnpm-debug.log* +lerna-debug.log* + +node_modules +dist +dist-ssr +*.local + +# Editor directories and files +.vscode/* +!.vscode/extensions.json +.idea +.DS_Store +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? diff --git a/playgrounds/vite-react/index.html b/playgrounds/vite-react/index.html new file mode 100644 index 0000000000..c29681356c --- /dev/null +++ b/playgrounds/vite-react/index.html @@ -0,0 +1,12 @@ + + + + + + Vite React + + +
+ + + diff --git a/playgrounds/vite-react/package.json b/playgrounds/vite-react/package.json new file mode 100644 index 0000000000..b4cbd89fd4 --- /dev/null +++ b/playgrounds/vite-react/package.json @@ -0,0 +1,29 @@ +{ + "name": "vite-react", + "private": true, + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "@tanstack/query-sync-storage-persister": "5.0.5", + "@tanstack/react-query": ">=5.45.1", + "@tanstack/react-query-persist-client": "5.0.5", + "idb-keyval": "^6.2.1", + "react": ">=18.3.1", + "react-dom": ">=18.3.1", + "viem": "2.*", + "wagmi": "workspace:*" + }, + "devDependencies": { + "@tanstack/react-query-devtools": "5.0.5", + "@types/react": ">=18.3.1", + "@types/react-dom": ">=18.3.0", + "@vitejs/plugin-react": "^4.2.1", + "@wagmi/cli": "workspace:*", + "buffer": "^6.0.3", + "vite": "^7.3.0" + } +} diff --git a/playgrounds/vite-react/public/manifest.json b/playgrounds/vite-react/public/manifest.json new file mode 100644 index 0000000000..c5d4517110 --- /dev/null +++ b/playgrounds/vite-react/public/manifest.json @@ -0,0 +1,5 @@ +{ + "name": "vite-react", + "description": "vite-react playground", + "iconPath": "favicon.ico" +} diff --git a/playgrounds/vite-react/src/App.tsx b/playgrounds/vite-react/src/App.tsx new file mode 100644 index 0000000000..ad2e36b06f --- /dev/null +++ b/playgrounds/vite-react/src/App.tsx @@ -0,0 +1,389 @@ +import type { FormEvent } from 'react' +import { type Hex, formatEther, parseAbi, parseEther } from 'viem' +import { + type BaseError, + useAccount, + useAccountEffect, + useBalance, + useBlockNumber, + useChainId, + useConnect, + useConnections, + useConnectorClient, + useDisconnect, + useEnsName, + useReadContract, + useReadContracts, + useSendTransaction, + useSignMessage, + useSwitchAccount, + useSwitchChain, + useWaitForTransactionReceipt, + useWriteContract, +} from 'wagmi' +import { optimism } from 'wagmi/chains' + +import { wagmiContractConfig } from './contracts' + +function App() { + useAccountEffect({ + onConnect(_data) { + // console.log('onConnect', data) + }, + onDisconnect() { + // console.log('onDisconnect') + }, + }) + + return ( + <> + + + + + + + + + + + + + + + ) +} + +function Account() { + const account = useAccount() + const { disconnect } = useDisconnect() + const { data: ensName } = useEnsName({ + address: account.address, + }) + + return ( +
+

Account

+ +
+ account: {account.address} {ensName} +
+ chainId: {account.chainId} +
+ status: {account.status} +
+ + {account.status !== 'disconnected' && ( + + )} +
+ ) +} + +function Connect() { + const chainId = useChainId() + const { connectors, connect, status, error } = useConnect() + + return ( +
+

Connect

+ {connectors.map((connector) => ( + + ))} +
{status}
+
{error?.message}
+
+ ) +} + +function SwitchAccount() { + const account = useAccount() + const { connectors, switchAccount } = useSwitchAccount() + + return ( +
+

Switch Account

+ + {connectors.map((connector) => ( + + ))} +
+ ) +} + +function SwitchChain() { + const chainId = useChainId() + const { chains, switchChain, error } = useSwitchChain() + + return ( +
+

Switch Chain

+ + {chains.map((chain) => ( + + ))} + + {error?.message} +
+ ) +} + +function SignMessage() { + const { data, signMessage } = useSignMessage() + + return ( +
+

Sign Message

+ +
{ + event.preventDefault() + const formData = new FormData(event.target as HTMLFormElement) + signMessage({ message: formData.get('message') as string }) + }} + > + + +
+ + {data} +
+ ) +} + +function Connections() { + const connections = useConnections() + + return ( +
+

Connections

+ + {connections.map((connection) => ( +
+
connector {connection.connector.name}
+
accounts: {JSON.stringify(connection.accounts)}
+
chainId: {connection.chainId}
+
+ ))} +
+ ) +} + +function Balance() { + const { address } = useAccount() + + const { data: default_ } = useBalance({ address }) + const { data: account_ } = useBalance({ address }) + const { data: optimism_ } = useBalance({ + address, + chainId: optimism.id, + }) + + return ( +
+

Balance

+ +
+ Balance (Default Chain):{' '} + {!!default_?.value && formatEther(default_.value)} +
+
+ Balance (Account Chain):{' '} + {!!account_?.value && formatEther(account_.value)} +
+
+ Balance (Optimism Chain):{' '} + {!!optimism_?.value && formatEther(optimism_.value)} +
+
+ ) +} + +function BlockNumber() { + const { data: default_ } = useBlockNumber({ watch: true }) + const { data: account_ } = useBlockNumber({ + watch: true, + }) + const { data: optimism_ } = useBlockNumber({ + chainId: optimism.id, + watch: true, + }) + + return ( +
+

Block Number

+ +
Block Number (Default Chain): {default_?.toString()}
+
Block Number (Account Chain): {account_?.toString()}
+
Block Number (Optimism): {optimism_?.toString()}
+
+ ) +} + +function ConnectorClient() { + const { data, error } = useConnectorClient() + return ( +
+

Connector Client

+ client {data?.account?.address} {data?.chain?.id} + {error?.message} +
+ ) +} + +function SendTransaction() { + const { data: hash, error, isPending, sendTransaction } = useSendTransaction() + + async function submit(e: FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const to = formData.get('address') as Hex + const value = formData.get('value') as string + sendTransaction({ to, value: parseEther(value) }) + } + + const { isLoading: isConfirming, isSuccess: isConfirmed } = + useWaitForTransactionReceipt({ + hash, + }) + + return ( +
+

Send Transaction

+
+ + + +
+ {hash &&
Transaction Hash: {hash}
} + {isConfirming && 'Waiting for confirmation...'} + {isConfirmed && 'Transaction confirmed.'} + {error && ( +
Error: {(error as BaseError).shortMessage || error.message}
+ )} +
+ ) +} + +function ReadContract() { + const { data: balance } = useReadContract({ + ...wagmiContractConfig, + functionName: 'balanceOf', + args: ['0x03A71968491d55603FFe1b11A9e23eF013f75bCF'], + }) + + return ( +
+

Read Contract

+
Balance: {balance?.toString()}
+
+ ) +} + +function ReadContracts() { + const { data } = useReadContracts({ + allowFailure: false, + contracts: [ + { + ...wagmiContractConfig, + functionName: 'balanceOf', + args: ['0x03A71968491d55603FFe1b11A9e23eF013f75bCF'], + }, + { + ...wagmiContractConfig, + functionName: 'ownerOf', + args: [69n], + }, + { + ...wagmiContractConfig, + functionName: 'totalSupply', + }, + ], + }) + const [balance, ownerOf, totalSupply] = data || [] + + return ( +
+

Read Contract

+
Balance: {balance?.toString()}
+
Owner of Token 69: {ownerOf?.toString()}
+
Total Supply: {totalSupply?.toString()}
+
+ ) +} + +function WriteContract() { + const { data: hash, error, isPending, writeContract } = useWriteContract() + + async function submit(e: FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const tokenId = formData.get('tokenId') as string + writeContract({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: parseAbi(['function mint(uint256 tokenId)']), + functionName: 'mint', + args: [BigInt(tokenId)], + }) + } + + const { isLoading: isConfirming, isSuccess: isConfirmed } = + useWaitForTransactionReceipt({ + hash, + }) + + return ( +
+

Write Contract

+
+ + +
+ {hash &&
Transaction Hash: {hash}
} + {isConfirming && 'Waiting for confirmation...'} + {isConfirmed && 'Transaction confirmed.'} + {error && ( +
Error: {(error as BaseError).shortMessage || error.message}
+ )} +
+ ) +} + +export default App diff --git a/playgrounds/vite-react/src/contracts.ts b/playgrounds/vite-react/src/contracts.ts new file mode 100644 index 0000000000..d7d66754a2 --- /dev/null +++ b/playgrounds/vite-react/src/contracts.ts @@ -0,0 +1,202 @@ +export const wagmiContractConfig = { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: [ + { inputs: [], stateMutability: 'nonpayable', type: 'constructor' }, + { + anonymous: false, + inputs: [ + { + indexed: true, + name: 'owner', + type: 'address', + }, + { + indexed: true, + name: 'approved', + type: 'address', + }, + { + indexed: true, + name: 'tokenId', + type: 'uint256', + }, + ], + name: 'Approval', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + name: 'owner', + type: 'address', + }, + { + indexed: true, + name: 'operator', + type: 'address', + }, + { + indexed: false, + name: 'approved', + type: 'bool', + }, + ], + name: 'ApprovalForAll', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + name: 'from', + type: 'address', + }, + { indexed: true, name: 'to', type: 'address' }, + { + indexed: true, + name: 'tokenId', + type: 'uint256', + }, + ], + name: 'Transfer', + type: 'event', + }, + { + inputs: [ + { name: 'to', type: 'address' }, + { name: 'tokenId', type: 'uint256' }, + ], + name: 'approve', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ name: 'owner', type: 'address' }], + name: 'balanceOf', + outputs: [{ name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ name: 'tokenId', type: 'uint256' }], + name: 'getApproved', + outputs: [{ name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { name: 'owner', type: 'address' }, + { name: 'operator', type: 'address' }, + ], + name: 'isApprovedForAll', + outputs: [{ name: '', type: 'bool' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'mint', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: 'tokenId', type: 'uint256' }], + name: 'mint', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'name', + outputs: [{ name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ name: 'tokenId', type: 'uint256' }], + name: 'ownerOf', + outputs: [{ name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { name: 'from', type: 'address' }, + { name: 'to', type: 'address' }, + { name: 'tokenId', type: 'uint256' }, + ], + name: 'safeTransferFrom', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { name: 'from', type: 'address' }, + { name: 'to', type: 'address' }, + { name: 'tokenId', type: 'uint256' }, + { name: '_data', type: 'bytes' }, + ], + name: 'safeTransferFrom', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { name: 'operator', type: 'address' }, + { name: 'approved', type: 'bool' }, + ], + name: 'setApprovalForAll', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ name: 'interfaceId', type: 'bytes4' }], + name: 'supportsInterface', + outputs: [{ name: '', type: 'bool' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'symbol', + outputs: [{ name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ name: 'tokenId', type: 'uint256' }], + name: 'tokenURI', + outputs: [{ name: '', type: 'string' }], + stateMutability: 'pure', + type: 'function', + }, + { + inputs: [], + name: 'totalSupply', + outputs: [{ name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { name: 'from', type: 'address' }, + { name: 'to', type: 'address' }, + { name: 'tokenId', type: 'uint256' }, + ], + name: 'transferFrom', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + ], +} as const diff --git a/playgrounds/vite-react/src/index.css b/playgrounds/vite-react/src/index.css new file mode 100644 index 0000000000..0733a7ee6b --- /dev/null +++ b/playgrounds/vite-react/src/index.css @@ -0,0 +1,21 @@ +:root { + background-color: #181818; + color: rgba(255, 255, 255, 0.87); + color-scheme: light dark; + font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; + font-synthesis: none; + font-weight: 400; + line-height: 1.5; + text-rendering: optimizeLegibility; + + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + -webkit-text-size-adjust: 100%; +} + +@media (prefers-color-scheme: light) { + :root { + background-color: #f8f8f8; + color: #181818; + } +} diff --git a/playgrounds/vite-react/src/main.tsx b/playgrounds/vite-react/src/main.tsx new file mode 100644 index 0000000000..ad801a958d --- /dev/null +++ b/playgrounds/vite-react/src/main.tsx @@ -0,0 +1,49 @@ +import { Buffer } from 'buffer' +import { createSyncStoragePersister } from '@tanstack/query-sync-storage-persister' +import { QueryClient } from '@tanstack/react-query' +import { ReactQueryDevtools } from '@tanstack/react-query-devtools' +import { PersistQueryClientProvider } from '@tanstack/react-query-persist-client' +import React from 'react' +import ReactDOM from 'react-dom/client' +import { WagmiProvider, deserialize, serialize } from 'wagmi' + +import './index.css' + +// `@coinbase-wallet/sdk` uses `Buffer` +globalThis.Buffer = Buffer + +import App from './App.tsx' +import { config } from './wagmi.ts' + +const queryClient = new QueryClient({ + defaultOptions: { + queries: { + gcTime: 1_000 * 60 * 60 * 24, // 24 hours + networkMode: 'offlineFirst', + refetchOnWindowFocus: false, + retry: 0, + }, + mutations: { networkMode: 'offlineFirst' }, + }, +}) + +const persister = createSyncStoragePersister({ + key: 'vite-react.cache', + serialize, + storage: window.localStorage, + deserialize, +}) + +ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render( + + + + + + + + , +) diff --git a/playgrounds/vite-react/src/vite-env.d.ts b/playgrounds/vite-react/src/vite-env.d.ts new file mode 100644 index 0000000000..11f02fe2a0 --- /dev/null +++ b/playgrounds/vite-react/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/playgrounds/vite-react/src/wagmi.ts b/playgrounds/vite-react/src/wagmi.ts new file mode 100644 index 0000000000..94b86f6fd7 --- /dev/null +++ b/playgrounds/vite-react/src/wagmi.ts @@ -0,0 +1,40 @@ +import { del, get, set } from 'idb-keyval' +import { http, createConfig } from 'wagmi' +import { celo, mainnet, optimism, sepolia } from 'wagmi/chains' +import { coinbaseWallet, metaMask, walletConnect } from 'wagmi/connectors' + +// biome-ignore lint/correctness/noUnusedVariables: +const indexedDBStorage = { + async getItem(name: string) { + return get(name) + }, + async setItem(name: string, value: string) { + await set(name, value) + }, + async removeItem(name: string) { + await del(name) + }, +} + +export const config = createConfig({ + chains: [mainnet, sepolia, optimism, celo], + connectors: [ + walletConnect({ + projectId: import.meta.env.VITE_WC_PROJECT_ID, + }), + coinbaseWallet(), + metaMask(), + ], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + [optimism.id]: http(), + [celo.id]: http(), + }, +}) + +declare module 'wagmi' { + interface Register { + config: typeof config + } +} diff --git a/playgrounds/vite-react/tsconfig.json b/playgrounds/vite-react/tsconfig.json new file mode 100644 index 0000000000..2a91e18f44 --- /dev/null +++ b/playgrounds/vite-react/tsconfig.json @@ -0,0 +1,30 @@ +{ + "compilerOptions": { + "target": "ESNext", + "lib": ["DOM", "DOM.Iterable", "ESNext"], + "module": "ESNext", + "skipLibCheck": true, + + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "react-jsx", + + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true, + + "paths": { + "@wagmi/connectors": ["../../packages/connectors/src/exports"], + "@wagmi/core": ["../../packages/core/src/exports"], + "@wagmi/core/*": ["../../packages/core/src/exports/*"], + "wagmi": ["../../packages/react/src/exports"], + "wagmi/*": ["../../packages/react/src/exports/*"] + } + }, + "include": ["src"], + "references": [{ "path": "./tsconfig.node.json" }] +} diff --git a/playgrounds/vite-react/tsconfig.node.json b/playgrounds/vite-react/tsconfig.node.json new file mode 100644 index 0000000000..42872c59f5 --- /dev/null +++ b/playgrounds/vite-react/tsconfig.node.json @@ -0,0 +1,10 @@ +{ + "compilerOptions": { + "composite": true, + "skipLibCheck": true, + "module": "ESNext", + "moduleResolution": "bundler", + "allowSyntheticDefaultImports": true + }, + "include": ["vite.config.ts"] +} diff --git a/playgrounds/vite-react/vite.config.ts b/playgrounds/vite-react/vite.config.ts new file mode 100644 index 0000000000..36f7f4e1bc --- /dev/null +++ b/playgrounds/vite-react/vite.config.ts @@ -0,0 +1,7 @@ +import react from '@vitejs/plugin-react' +import { defineConfig } from 'vite' + +// https://vitejs.dev/config/ +export default defineConfig({ + plugins: [react()], +}) diff --git a/playgrounds/vite-react/wagmi.config.ts b/playgrounds/vite-react/wagmi.config.ts new file mode 100644 index 0000000000..d524220b09 --- /dev/null +++ b/playgrounds/vite-react/wagmi.config.ts @@ -0,0 +1,17 @@ +import { defineConfig } from '@wagmi/cli' +import { foundry, hardhat } from '@wagmi/cli/plugins' + +export default defineConfig({ + out: 'src/generated.ts', + contracts: [], + plugins: [ + foundry({ + namePrefix: 'foundry', + project: '../../packages/cli/src/plugins/__fixtures__/foundry', + }), + hardhat({ + namePrefix: 'hardhat', + project: '../../packages/cli/src/plugins/__fixtures__/hardhat', + }), + ], +}) diff --git a/playgrounds/vite-vue/.gitignore b/playgrounds/vite-vue/.gitignore new file mode 100644 index 0000000000..a547bf36d8 --- /dev/null +++ b/playgrounds/vite-vue/.gitignore @@ -0,0 +1,24 @@ +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +pnpm-debug.log* +lerna-debug.log* + +node_modules +dist +dist-ssr +*.local + +# Editor directories and files +.vscode/* +!.vscode/extensions.json +.idea +.DS_Store +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? diff --git a/playgrounds/vite-vue/index.html b/playgrounds/vite-vue/index.html new file mode 100644 index 0000000000..3f59f59114 --- /dev/null +++ b/playgrounds/vite-vue/index.html @@ -0,0 +1,13 @@ + + + + + + + Vite Vue + + +
+ + + diff --git a/playgrounds/vite-vue/package.json b/playgrounds/vite-vue/package.json new file mode 100644 index 0000000000..61b1d81a01 --- /dev/null +++ b/playgrounds/vite-vue/package.json @@ -0,0 +1,22 @@ +{ + "name": "vite-vue", + "private": true, + "type": "module", + "scripts": { + "dev": "vite", + "build": "vue-tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "@tanstack/vue-query": ">=5.45.0", + "@wagmi/vue": "workspace:*", + "viem": "2.*", + "vue": ">=3.4.21" + }, + "devDependencies": { + "@vitejs/plugin-vue": "^5.0.4", + "buffer": "^6.0.3", + "vite": "^7.3.0", + "vue-tsc": "^2.0.6" + } +} diff --git a/playgrounds/vite-vue/public/vite.svg b/playgrounds/vite-vue/public/vite.svg new file mode 100644 index 0000000000..e7b8dfb1b2 --- /dev/null +++ b/playgrounds/vite-vue/public/vite.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/playgrounds/vite-vue/src/App.vue b/playgrounds/vite-vue/src/App.vue new file mode 100644 index 0000000000..5a7f194a02 --- /dev/null +++ b/playgrounds/vite-vue/src/App.vue @@ -0,0 +1,29 @@ + + + diff --git a/playgrounds/vite-vue/src/components/Account.vue b/playgrounds/vite-vue/src/components/Account.vue new file mode 100644 index 0000000000..33f1491dac --- /dev/null +++ b/playgrounds/vite-vue/src/components/Account.vue @@ -0,0 +1,22 @@ + + + diff --git a/playgrounds/vite-vue/src/components/Balance.vue b/playgrounds/vite-vue/src/components/Balance.vue new file mode 100644 index 0000000000..b064d45e9a --- /dev/null +++ b/playgrounds/vite-vue/src/components/Balance.vue @@ -0,0 +1,12 @@ + + + diff --git a/playgrounds/vite-vue/src/components/BlockNumber.vue b/playgrounds/vite-vue/src/components/BlockNumber.vue new file mode 100644 index 0000000000..25f8744a71 --- /dev/null +++ b/playgrounds/vite-vue/src/components/BlockNumber.vue @@ -0,0 +1,17 @@ + + + diff --git a/playgrounds/vite-vue/src/components/Client.vue b/playgrounds/vite-vue/src/components/Client.vue new file mode 100644 index 0000000000..52e7f12f7b --- /dev/null +++ b/playgrounds/vite-vue/src/components/Client.vue @@ -0,0 +1,14 @@ + + + diff --git a/playgrounds/vite-vue/src/components/Connect.vue b/playgrounds/vite-vue/src/components/Connect.vue new file mode 100644 index 0000000000..93320448c0 --- /dev/null +++ b/playgrounds/vite-vue/src/components/Connect.vue @@ -0,0 +1,19 @@ + + + diff --git a/playgrounds/vite-vue/src/components/Connections.vue b/playgrounds/vite-vue/src/components/Connections.vue new file mode 100644 index 0000000000..21405f2483 --- /dev/null +++ b/playgrounds/vite-vue/src/components/Connections.vue @@ -0,0 +1,15 @@ + + + diff --git a/playgrounds/vite-vue/src/components/ConnectorClient.vue b/playgrounds/vite-vue/src/components/ConnectorClient.vue new file mode 100644 index 0000000000..157156d3ee --- /dev/null +++ b/playgrounds/vite-vue/src/components/ConnectorClient.vue @@ -0,0 +1,14 @@ + + + diff --git a/playgrounds/vite-vue/src/components/ReadContract.vue b/playgrounds/vite-vue/src/components/ReadContract.vue new file mode 100644 index 0000000000..2f236ac9ed --- /dev/null +++ b/playgrounds/vite-vue/src/components/ReadContract.vue @@ -0,0 +1,16 @@ + + + diff --git a/playgrounds/vite-vue/src/components/SendTransaction.vue b/playgrounds/vite-vue/src/components/SendTransaction.vue new file mode 100644 index 0000000000..8a509b5e5f --- /dev/null +++ b/playgrounds/vite-vue/src/components/SendTransaction.vue @@ -0,0 +1,35 @@ + + + diff --git a/playgrounds/vite-vue/src/components/SwitchAccount.vue b/playgrounds/vite-vue/src/components/SwitchAccount.vue new file mode 100644 index 0000000000..bc1814bfa7 --- /dev/null +++ b/playgrounds/vite-vue/src/components/SwitchAccount.vue @@ -0,0 +1,20 @@ + + + diff --git a/playgrounds/vite-vue/src/components/SwitchChain.vue b/playgrounds/vite-vue/src/components/SwitchChain.vue new file mode 100644 index 0000000000..b385052049 --- /dev/null +++ b/playgrounds/vite-vue/src/components/SwitchChain.vue @@ -0,0 +1,22 @@ + + + diff --git a/playgrounds/vite-vue/src/components/WriteContract.vue b/playgrounds/vite-vue/src/components/WriteContract.vue new file mode 100644 index 0000000000..aa3102b3f1 --- /dev/null +++ b/playgrounds/vite-vue/src/components/WriteContract.vue @@ -0,0 +1,28 @@ + + + diff --git a/playgrounds/vite-vue/src/contracts.ts b/playgrounds/vite-vue/src/contracts.ts new file mode 100644 index 0000000000..d7d66754a2 --- /dev/null +++ b/playgrounds/vite-vue/src/contracts.ts @@ -0,0 +1,202 @@ +export const wagmiContractConfig = { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: [ + { inputs: [], stateMutability: 'nonpayable', type: 'constructor' }, + { + anonymous: false, + inputs: [ + { + indexed: true, + name: 'owner', + type: 'address', + }, + { + indexed: true, + name: 'approved', + type: 'address', + }, + { + indexed: true, + name: 'tokenId', + type: 'uint256', + }, + ], + name: 'Approval', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + name: 'owner', + type: 'address', + }, + { + indexed: true, + name: 'operator', + type: 'address', + }, + { + indexed: false, + name: 'approved', + type: 'bool', + }, + ], + name: 'ApprovalForAll', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + name: 'from', + type: 'address', + }, + { indexed: true, name: 'to', type: 'address' }, + { + indexed: true, + name: 'tokenId', + type: 'uint256', + }, + ], + name: 'Transfer', + type: 'event', + }, + { + inputs: [ + { name: 'to', type: 'address' }, + { name: 'tokenId', type: 'uint256' }, + ], + name: 'approve', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ name: 'owner', type: 'address' }], + name: 'balanceOf', + outputs: [{ name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ name: 'tokenId', type: 'uint256' }], + name: 'getApproved', + outputs: [{ name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { name: 'owner', type: 'address' }, + { name: 'operator', type: 'address' }, + ], + name: 'isApprovedForAll', + outputs: [{ name: '', type: 'bool' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'mint', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: 'tokenId', type: 'uint256' }], + name: 'mint', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'name', + outputs: [{ name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ name: 'tokenId', type: 'uint256' }], + name: 'ownerOf', + outputs: [{ name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { name: 'from', type: 'address' }, + { name: 'to', type: 'address' }, + { name: 'tokenId', type: 'uint256' }, + ], + name: 'safeTransferFrom', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { name: 'from', type: 'address' }, + { name: 'to', type: 'address' }, + { name: 'tokenId', type: 'uint256' }, + { name: '_data', type: 'bytes' }, + ], + name: 'safeTransferFrom', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { name: 'operator', type: 'address' }, + { name: 'approved', type: 'bool' }, + ], + name: 'setApprovalForAll', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ name: 'interfaceId', type: 'bytes4' }], + name: 'supportsInterface', + outputs: [{ name: '', type: 'bool' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'symbol', + outputs: [{ name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ name: 'tokenId', type: 'uint256' }], + name: 'tokenURI', + outputs: [{ name: '', type: 'string' }], + stateMutability: 'pure', + type: 'function', + }, + { + inputs: [], + name: 'totalSupply', + outputs: [{ name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { name: 'from', type: 'address' }, + { name: 'to', type: 'address' }, + { name: 'tokenId', type: 'uint256' }, + ], + name: 'transferFrom', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + ], +} as const diff --git a/playgrounds/vite-vue/src/main.ts b/playgrounds/vite-vue/src/main.ts new file mode 100644 index 0000000000..820eed3722 --- /dev/null +++ b/playgrounds/vite-vue/src/main.ts @@ -0,0 +1,17 @@ +import { Buffer } from 'buffer' +import { VueQueryPlugin } from '@tanstack/vue-query' +import { WagmiPlugin } from '@wagmi/vue' +import { createApp } from 'vue' + +// `@coinbase-wallet/sdk` uses `Buffer` +globalThis.Buffer = Buffer + +import App from './App.vue' +import './style.css' +import { config } from './wagmi' + +const app = createApp(App) + +app.use(WagmiPlugin, { config }).use(VueQueryPlugin, {}) + +app.mount('#app') diff --git a/playgrounds/vite-vue/src/style.css b/playgrounds/vite-vue/src/style.css new file mode 100644 index 0000000000..0733a7ee6b --- /dev/null +++ b/playgrounds/vite-vue/src/style.css @@ -0,0 +1,21 @@ +:root { + background-color: #181818; + color: rgba(255, 255, 255, 0.87); + color-scheme: light dark; + font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; + font-synthesis: none; + font-weight: 400; + line-height: 1.5; + text-rendering: optimizeLegibility; + + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + -webkit-text-size-adjust: 100%; +} + +@media (prefers-color-scheme: light) { + :root { + background-color: #f8f8f8; + color: #181818; + } +} diff --git a/playgrounds/vite-vue/src/vite-env.d.ts b/playgrounds/vite-vue/src/vite-env.d.ts new file mode 100644 index 0000000000..11f02fe2a0 --- /dev/null +++ b/playgrounds/vite-vue/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/playgrounds/vite-vue/src/wagmi.ts b/playgrounds/vite-vue/src/wagmi.ts new file mode 100644 index 0000000000..f5b3f286cc --- /dev/null +++ b/playgrounds/vite-vue/src/wagmi.ts @@ -0,0 +1,26 @@ +import { http, createConfig, createStorage } from '@wagmi/vue' +import { mainnet, optimism, sepolia } from '@wagmi/vue/chains' +import { coinbaseWallet, metaMask, walletConnect } from '@wagmi/vue/connectors' + +export const config = createConfig({ + chains: [mainnet, sepolia, optimism], + connectors: [ + walletConnect({ + projectId: import.meta.env.VITE_WC_PROJECT_ID, + }), + coinbaseWallet({ appName: 'Vite Vue Playground', darkMode: true }), + metaMask(), + ], + storage: createStorage({ storage: localStorage, key: 'vite-vue' }), + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + [optimism.id]: http(), + }, +}) + +declare module '@wagmi/vue' { + interface Register { + config: typeof config + } +} diff --git a/playgrounds/vite-vue/tsconfig.json b/playgrounds/vite-vue/tsconfig.json new file mode 100644 index 0000000000..18f095cd22 --- /dev/null +++ b/playgrounds/vite-vue/tsconfig.json @@ -0,0 +1,23 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "preserve", + + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true + }, + "include": ["src/**/*.ts", "src/**/*.tsx", "src/**/*.vue"], + "references": [{ "path": "./tsconfig.node.json" }] +} diff --git a/playgrounds/vite-vue/tsconfig.node.json b/playgrounds/vite-vue/tsconfig.node.json new file mode 100644 index 0000000000..97ede7ee6f --- /dev/null +++ b/playgrounds/vite-vue/tsconfig.node.json @@ -0,0 +1,11 @@ +{ + "compilerOptions": { + "composite": true, + "skipLibCheck": true, + "module": "ESNext", + "moduleResolution": "bundler", + "allowSyntheticDefaultImports": true, + "strict": true + }, + "include": ["vite.config.ts"] +} diff --git a/playgrounds/vite-vue/vite.config.ts b/playgrounds/vite-vue/vite.config.ts new file mode 100644 index 0000000000..c3fa62d865 --- /dev/null +++ b/playgrounds/vite-vue/vite.config.ts @@ -0,0 +1,7 @@ +import vue from '@vitejs/plugin-vue' +import { defineConfig } from 'vite' + +// https://vitejs.dev/config/ +export default defineConfig({ + plugins: [vue()], +}) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 37345facb4..f486582696 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1,1493 +1,926 @@ lockfileVersion: '9.0' settings: - autoInstallPeers: true + autoInstallPeers: false excludeLinksFromLockfile: false -overrides: - ox: ^0.9.17 - tmp@<=0.2.3: '>=0.2.4' - lodash@>=4.0.0 <=4.17.22: '>=4.17.23' - diff@>=4.0.0 <4.0.4: '>=4.0.4' - minimatch@<3.1.3: '>=3.1.3' - minimatch@>=9.0.0 <9.0.6: '>=9.0.6' - rollup@>=4.0.0 <4.59.0: '>=4.59.0' - basic-ftp@<5.2.0: '>=5.2.0' - minimatch@>=9.0.0 <9.0.7: '>=9.0.7' - minimatch@>=10.0.0 <10.2.3: '>=10.2.3' - minimatch@<3.1.4: '>=3.1.4' - ajv@<6.14.0: '>=6.14.0' - flatted@<3.4.0: '>=3.4.0' - next@>=9.5.0 <15.5.13: '>=15.5.13' - next@>=10.0.0 <16.1.7: '>=16.1.7' - yargs-parser@<=5.0.0: '>=5.0.1' - got@<11.8.5: '>=11.8.5' - node-fetch@<2.6.7: '>=2.6.7' - json5@<1.0.2: '>=1.0.2' - debug@>=3.2.0 <3.2.7: '>=3.2.7' - tar@<6.2.1: '>=6.2.1' - axios@>=0.8.1 <0.28.0: '>=0.28.0' - tough-cookie@<4.1.3: '>=4.1.3' - async@>=2.0.0 <2.6.4: '>=2.6.4' - braces@<3.0.3: '>=3.0.3' - ws@>=8.0.0 <8.17.1: '>=8.17.1' - ws@>=2.1.0 <5.2.4: '>=5.2.4' - micromatch@<4.0.8: '>=4.0.8' - elliptic@<=6.6.0: '>=6.6.1' - cookie@<0.7.0: '>=0.7.0' - form-data@<2.5.4: '>=2.5.4' - elliptic@>=4.0.0 <=6.5.6: '>=6.5.7' - elliptic@>=2.0.0 <=6.5.6: '>=6.5.7' - elliptic@>=5.2.1 <=6.5.6: '>=6.5.7' - underscore@>=1.3.2 <1.12.1: '>=1.12.1' - axios@<0.30.0: '>=0.30.0' - elliptic@<6.6.0: '>=6.6.0' - elliptic@<6.5.6: '>=6.5.6' - undici@<6.23.0: '>=6.23.0' - tar@<7.5.7: '>=7.5.7' - semver@>=2.0.0-alpha <5.7.2: '>=5.7.2' - axios@<=0.30.2: '>=0.30.3' - tar@<=7.5.2: '>=7.5.3' - tar@<7.5.8: '>=7.5.8' - bn.js@<4.12.3: '>=4.12.3' - serialize-javascript@<=7.0.2: '>=7.0.3' - qs@<6.14.1: '>=6.14.1' - underscore@<=1.13.7: '>=1.13.8' - tar@<=7.5.9: '>=7.5.10' - tar@<=7.5.10: '>=7.5.11' - undici@<6.24.0: '>=6.24.0' - tar@<=7.5.3: '>=7.5.4' - fast-xml-parser@>=4.0.0-beta.3 <=5.5.5: '>=5.5.6' +catalogs: + default: + '@tanstack/query-core': + specifier: 5.49.1 + version: 5.49.1 + '@tanstack/react-query': + specifier: 5.49.2 + version: 5.49.2 + '@tanstack/vue-query': + specifier: 5.49.1 + version: 5.49.1 + '@testing-library/dom': + specifier: 10.4.0 + version: 10.4.0 + '@testing-library/react': + specifier: 16.0.1 + version: 16.0.1 + '@types/react': + specifier: 18.3.1 + version: 18.3.1 + '@types/react-dom': + specifier: 18.3.0 + version: 18.3.0 + react: + specifier: 18.3.1 + version: 18.3.1 + react-dom: + specifier: 18.3.1 + version: 18.3.1 + vue: + specifier: 3.4.27 + version: 3.4.27 importers: .: - dependencies: - '@0xsequence/guard': - specifier: ^3.0.4 - version: 3.0.6(typescript@5.9.3) - '@0xsequence/indexer': - specifier: ^3.0.4 - version: 3.0.6 - '@0xsequence/wallet-contracts': - specifier: ^3.0.1 - version: 3.0.1(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3) - flag: - specifier: ^5.0.1 - version: 5.0.1(react@19.2.3) devDependencies: + '@arethetypeswrong/cli': + specifier: ^0.16.4 + version: 0.16.4 + '@biomejs/biome': + specifier: ^1.9.4 + version: 1.9.4 + '@changesets/changelog-github': + specifier: 0.4.6 + version: 0.4.6(encoding@0.1.13) '@changesets/cli': - specifier: ^2.30.0 - version: 2.31.0(@types/node@25.6.0) - '@types/node': - specifier: ^25.5.0 - version: 25.6.0 - lefthook: - specifier: ^2.1.4 - version: 2.1.6 - prettier: - specifier: ^3.8.1 - version: 3.8.1 - rimraf: - specifier: ^6.1.3 - version: 6.1.3 - syncpack: - specifier: ^14.2.0 - version: 14.3.0 - turbo: - specifier: ^2.8.19 - version: 2.9.6 + specifier: ^2.27.8 + version: 2.27.8 + '@types/bun': + specifier: ^1.1.10 + version: 1.1.10 + '@vitest/coverage-v8': + specifier: ^3.2.4 + version: 3.2.4(vitest@2.1.9(@edge-runtime/vm@3.2.0)(@types/node@24.0.1)(happy-dom@20.0.2)(lightningcss@1.30.2)(msw@2.4.9(typescript@5.8.3))(terser@5.44.1)) + '@wagmi/test': + specifier: workspace:* + version: link:packages/test + bun: + specifier: ^1.1.30 + version: 1.1.30 + happy-dom: + specifier: ^20.0.2 + version: 20.0.2 + knip: + specifier: ^5.30.6 + version: 5.30.6(@types/node@24.0.1)(typescript@5.8.3) + prool: + specifier: ^0.0.23 + version: 0.0.23 + publint: + specifier: ^0.3.0 + version: 0.3.12 + sherif: + specifier: ^1.0.0 + version: 1.0.0 + simple-git-hooks: + specifier: ^2.11.1 + version: 2.11.1 typescript: - specifier: ^5.9.3 - version: 5.9.3 - - extras/docs: - dependencies: - '@repo/ui': - specifier: workspace:^ - version: link:../../repo/ui - next: - specifier: '>=16.1.7' - version: 16.2.4(react-dom@19.2.3(react@19.2.3))(react@19.2.3) - react: - specifier: ^19.2.3 - version: 19.2.3 - react-dom: - specifier: ^19.2.3 - version: 19.2.3(react@19.2.3) + specifier: 5.8.3 + version: 5.8.3 + viem: + specifier: 2.31.4 + version: 2.31.4(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20) + vitest: + specifier: ^2.1.9 + version: 2.1.9(@edge-runtime/vm@3.2.0)(@types/node@24.0.1)(happy-dom@20.0.2)(lightningcss@1.30.2)(msw@2.4.9(typescript@5.8.3))(terser@5.44.1) + + packages/cli: + dependencies: + abitype: + specifier: ^1.0.4 + version: 1.0.4(typescript@5.9.3)(zod@3.25.20) + bundle-require: + specifier: ^5.1.0 + version: 5.1.0(esbuild@0.27.2) + cac: + specifier: ^6.7.14 + version: 6.7.14 + change-case: + specifier: ^5.4.4 + version: 5.4.4 + chokidar: + specifier: 4.0.3 + version: 4.0.3 + dedent: + specifier: ^1.5.3 + version: 1.6.0 + dotenv: + specifier: ^16.3.1 + version: 16.3.1 + dotenv-expand: + specifier: ^10.0.0 + version: 10.0.0 + esbuild: + specifier: ~0.27.0 + version: 0.27.2 + escalade: + specifier: 3.2.0 + version: 3.2.0 + fdir: + specifier: ^6.1.1 + version: 6.1.1(picomatch@4.0.2) + nanospinner: + specifier: 1.2.2 + version: 1.2.2 + pathe: + specifier: ^2.0.3 + version: 2.0.3 + picocolors: + specifier: ^1.0.0 + version: 1.0.0 + picomatch: + specifier: ^4.0.2 + version: 4.0.2 + prettier: + specifier: ^3.0.3 + version: 3.0.3 + viem: + specifier: 2.x + version: 2.10.8(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@6.0.5)(zod@3.25.20) + zod: + specifier: ^3.22.3 + version: 3.25.20 devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../repo/typescript-config + '@types/dedent': + specifier: ^0.7.2 + version: 0.7.2 '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - '@types/react': - specifier: ^19.2.7 - version: 19.2.7 - '@types/react-dom': - specifier: ^19.2.3 - version: 19.2.3(@types/react@19.2.7) - eslint: - specifier: ^9.39.2 - version: 9.39.2 - typescript: - specifier: ^5.9.3 - version: 5.9.3 + specifier: ^22.14.0 + version: 22.15.31 + fixturez: + specifier: ^1.1.0 + version: 1.1.0 + msw: + specifier: ^2.4.9 + version: 2.4.9(typescript@5.9.3) - extras/web: - dependencies: - '@repo/ui': - specifier: workspace:^ - version: link:../../repo/ui - next: - specifier: '>=16.1.7' - version: 16.2.4(react-dom@19.2.3(react@19.2.3))(react@19.2.3) - react: - specifier: ^19.2.3 - version: 19.2.3 - react-dom: - specifier: ^19.2.3 - version: 19.2.3(react@19.2.3) + packages/cli/src/plugins/__fixtures__/hardhat: devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - '@types/react': - specifier: ^19.2.7 - version: 19.2.7 - '@types/react-dom': - specifier: ^19.2.3 - version: 19.2.3(@types/react@19.2.7) - eslint: - specifier: ^9.39.2 - version: 9.39.2 - typescript: - specifier: ^5.9.3 - version: 5.9.3 - - packages/abi: {} - - packages/account: - dependencies: - '@0xsequence/abi': - specifier: workspace:* - version: link:../utils/abi - '@0xsequence/core': - specifier: workspace:* - version: link:../core - '@0xsequence/migration': - specifier: workspace:* - version: link:../migration - '@0xsequence/network': - specifier: workspace:* - version: link:../network - '@0xsequence/relayer': - specifier: workspace:* - version: link:../services/relayer - '@0xsequence/sessions': - specifier: workspace:* - version: link:../sessions - '@0xsequence/utils': - specifier: workspace:* - version: link:../utils - '@0xsequence/wallet': - specifier: workspace:* - version: link:../wallet - ethers: - specifier: ^5.5.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) + hardhat: + specifier: ^2.22.3 + version: 2.22.3(bufferutil@4.1.0)(ts-node@10.9.1(@types/node@24.0.1)(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@5.0.10) + + packages/connectors: + dependencies: + '@coinbase/wallet-sdk': + specifier: 4.3.0 + version: 4.3.0 + '@metamask/sdk': + specifier: 0.33.1 + version: 0.33.1(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@5.0.10) + '@safe-global/safe-apps-provider': + specifier: 0.18.6 + version: 0.18.6(bufferutil@4.1.0)(encoding@0.1.13)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@safe-global/safe-apps-sdk': + specifier: 9.1.0 + version: 9.1.0(bufferutil@4.1.0)(encoding@0.1.13)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@walletconnect/ethereum-provider': + specifier: 2.20.2 + version: 2.20.2(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + cbw-sdk: + specifier: npm:@coinbase/wallet-sdk@3.9.3 + version: '@coinbase/wallet-sdk@3.9.3' devDependencies: - '@0xsequence/signhub': - specifier: workspace:* - version: link:../signhub - '@0xsequence/tests': - specifier: workspace:* - version: link:../tests - '@istanbuljs/nyc-config-typescript': - specifier: ^1.0.2 - version: 1.0.2(nyc@15.1.0) - nyc: - specifier: ^15.1.0 - version: 15.1.0 - - packages/api: {} - - packages/auth: - dependencies: - '@0xsequence/abi': - specifier: workspace:* - version: link:../utils/abi - '@0xsequence/account': - specifier: workspace:* - version: link:../account - '@0xsequence/api': - specifier: workspace:* - version: link:../services/api - '@0xsequence/core': + '@wagmi/core': specifier: workspace:* version: link:../core - '@0xsequence/ethauth': - specifier: ^0.8.1 - version: 0.8.1(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/indexer': - specifier: workspace:* - version: link:../services/indexer - '@0xsequence/metadata': - specifier: workspace:* - version: link:../services/metadata - '@0xsequence/migration': - specifier: workspace:* - version: link:../migration - '@0xsequence/network': - specifier: workspace:* - version: link:../network - '@0xsequence/sessions': - specifier: workspace:* - version: link:../sessions - '@0xsequence/signhub': - specifier: workspace:* - version: link:../signhub - '@0xsequence/utils': - specifier: workspace:* - version: link:../utils - '@0xsequence/wallet': - specifier: workspace:* - version: link:../wallet - devDependencies: - '@0xsequence/tests': - specifier: workspace:* - version: link:../tests - '@0xsequence/wallet-contracts': - specifier: ^1.10.0 - version: 1.10.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - concurrently: - specifier: ^7.5.0 - version: 7.6.0 - ethers: - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - hardhat: - specifier: ^2.20.1 - version: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@5.0.10) - mockttp: - specifier: ^3.6.0 - version: 3.17.1(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@5.0.10) + msw: + specifier: ^2.4.9 + version: 2.4.9(typescript@5.9.3) packages/core: dependencies: - '@0xsequence/abi': - specifier: workspace:* - version: link:../utils/abi - ethers: - specifier: '>=5.5' - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) + eventemitter3: + specifier: 5.0.1 + version: 5.0.1 + mipd: + specifier: 0.0.7 + version: 0.0.7(typescript@5.9.3) + zustand: + specifier: 5.0.0 + version: 5.0.0(@types/react@18.3.27)(react@18.3.1)(use-sync-external-store@1.4.0(react@18.3.1)) devDependencies: - '@istanbuljs/nyc-config-typescript': - specifier: ^1.0.2 - version: 1.0.2(nyc@15.1.0) - nyc: - specifier: ^15.1.0 - version: 15.1.0 - - packages/deployer: - dependencies: - '@0xsequence/utils': - specifier: workspace:* - version: link:../utils + '@tanstack/query-core': + specifier: 'catalog:' + version: 5.49.1 + + packages/create-wagmi: + dependencies: + cac: + specifier: ^6.7.14 + version: 6.7.14 + cross-spawn: + specifier: ^7.0.5 + version: 7.0.6 + picocolors: + specifier: ^1.0.0 + version: 1.0.0 + prompts: + specifier: ^2.4.2 + version: 2.4.2 devDependencies: - '@ethersproject/abi': - specifier: ^5.7.0 - version: 5.8.0 - '@ethersproject/providers': - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@nomiclabs/hardhat-ethers': - specifier: ^2.2.1 - version: 2.2.3(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@5.0.10)) - '@nomiclabs/hardhat-web3': - specifier: ^2.0.0 - version: 2.1.2(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@5.0.10))(web3@1.10.4(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@5.0.10)) - '@typechain/ethers-v5': - specifier: ^10.1.1 - version: 10.2.1(@ethersproject/abi@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3) - dotenv: - specifier: ^16.0.3 - version: 16.6.1 - ethers: - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - typechain: - specifier: ^8.1.1 - version: 8.3.2(typescript@5.9.3) + '@types/cross-spawn': + specifier: ^6.0.6 + version: 6.0.6 + '@types/node': + specifier: ^20.12.10 + version: 20.12.10 + '@types/prompts': + specifier: ^2.4.9 + version: 2.4.9 - packages/estimator: + packages/react: dependencies: - '@0xsequence/abi': + '@wagmi/connectors': specifier: workspace:* - version: link:../utils/abi - '@0xsequence/core': + version: link:../connectors + '@wagmi/core': specifier: workspace:* version: link:../core - '@0xsequence/utils': - specifier: workspace:* - version: link:../utils - '@0xsequence/wallet-contracts': - specifier: ^1.10.0 - version: 1.10.0 + use-sync-external-store: + specifier: 1.4.0 + version: 1.4.0(react@18.3.1) devDependencies: - '@0xsequence/signhub': - specifier: workspace:* - version: link:../signhub - '@0xsequence/tests': - specifier: workspace:* - version: link:../tests - '@ethersproject/abstract-signer': - specifier: ^5.7.0 - version: 5.8.0 - '@ethersproject/properties': - specifier: ^5.7.0 - version: 5.8.0 - ethers: - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) + '@tanstack/react-query': + specifier: 'catalog:' + version: 5.49.2(react@18.3.1) + '@testing-library/dom': + specifier: 'catalog:' + version: 10.4.0 + '@testing-library/react': + specifier: 'catalog:' + version: 16.0.1(@testing-library/dom@10.4.0)(@types/react-dom@18.3.0)(@types/react@18.3.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@types/react': + specifier: 'catalog:' + version: 18.3.1 + '@types/react-dom': + specifier: 'catalog:' + version: 18.3.0 + '@types/use-sync-external-store': + specifier: ^0.0.6 + version: 0.0.6 + react: + specifier: 'catalog:' + version: 18.3.1 + react-dom: + specifier: 'catalog:' + version: 18.3.1(react@18.3.1) - packages/guard: + packages/register-tests/react: dependencies: - '@0xsequence/account': - specifier: workspace:* - version: link:../account - '@0xsequence/core': - specifier: workspace:* - version: link:../core - '@0xsequence/signhub': - specifier: workspace:* - version: link:../signhub - '@0xsequence/utils': + '@tanstack/react-query': + specifier: 'catalog:' + version: 5.49.2(react@18.3.1) + react: + specifier: 'catalog:' + version: 18.3.1 + wagmi: specifier: workspace:* - version: link:../utils - ethers: - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - - packages/indexer: {} - - packages/metadata: {} + version: link:../../react + devDependencies: + '@types/react': + specifier: 'catalog:' + version: 18.3.1 - packages/migration: + packages/register-tests/vue: dependencies: - '@0xsequence/abi': - specifier: workspace:* - version: link:../utils/abi - '@0xsequence/core': - specifier: workspace:* - version: link:../core - '@0xsequence/wallet': + '@tanstack/vue-query': + specifier: 'catalog:' + version: 5.49.1(vue@3.4.27(typescript@5.9.3)) + '@wagmi/vue': specifier: workspace:* - version: link:../wallet - ethers: - specifier: ^5.5.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - devDependencies: - '@istanbuljs/nyc-config-typescript': - specifier: ^1.0.2 - version: 1.0.2(nyc@15.1.0) - nyc: - specifier: ^15.1.0 - version: 15.1.0 + version: link:../../vue + vue: + specifier: 'catalog:' + version: 3.4.27(typescript@5.9.3) - packages/multicall: + packages/sequence-core-1.0.0: dependencies: - '@0xsequence/abi': - specifier: workspace:* - version: link:../utils/abi - '@0xsequence/network': - specifier: workspace:* - version: link:../network - '@0xsequence/utils': - specifier: workspace:* - version: link:../utils - devDependencies: + 0xsequence: + specifier: ^2.3.33 + version: 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/connect': + specifier: 0.0.0-20250924112110 + version: 0.0.0-20250924112110(@types/react-dom@18.3.0)(@types/react@18.3.27)(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(typescript@5.8.3)(utf-8-validate@6.0.5)(viem@2.43.5(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20))(wagmi@packages+react)(zod@3.25.20) + '@0xsequence/waas': + specifier: ^2.3.33 + version: 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/wallet': + specifier: ~2.3.33 + version: 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) '@0xsequence/wallet-contracts': - specifier: ^2.0.0 - version: 2.0.0(@ethersproject/abi@5.8.0)(@ethersproject/bytes@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3))(bufferutil@4.0.7)(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@6.0.3) - '@ethersproject/providers': - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3) - '@types/web3-provider-engine': - specifier: ^14.0.1 - version: 14.0.4 - eth-json-rpc-middleware: - specifier: ^9.0.1 - version: 9.0.1(encoding@0.1.13) + specifier: ~3.0.1 + version: 3.0.1(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5) + '@0xsequence/wallet-primitives': + specifier: 0.0.0-20250915145821 + version: 0.0.0-20250915145821(typescript@5.8.3)(zod@3.25.20) + '@vercel/analytics': + specifier: ^1.5.0 + version: 1.6.1(next@15.4.10(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react@18.3.1)(vue-router@4.6.4(vue@3.5.26(typescript@5.8.3)))(vue@3.5.26(typescript@5.8.3)) ethers: - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3) - ganache: - specifier: ^7.5.0 - version: 7.9.2 - json-rpc-engine: + specifier: ^6.15.0 + version: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + flag: + specifier: ^5.0.1 + version: 5.0.1(react@18.3.1) + prettier-plugin-solidity: + specifier: ^2.2.0 + version: 2.2.1(prettier@3.7.4) + vercel: + specifier: ^48.10.2 + version: 48.12.1(encoding@0.1.13)(rollup@4.54.0)(typescript@5.8.3) + devDependencies: + '@changesets/cli': + specifier: ^2.29.7 + version: 2.29.8(@types/node@24.0.1) + lefthook: + specifier: ^1.13.6 + version: 1.13.6 + prettier: + specifier: ^3.6.2 + version: 3.7.4 + rimraf: specifier: ^6.1.0 - version: 6.1.0 - web3: - specifier: ^1.8.1 - version: 1.10.4(bufferutil@4.0.7)(encoding@0.1.13)(utf-8-validate@6.0.3) - web3-provider-engine: - specifier: ^16.0.4 - version: 16.0.8(bufferutil@4.0.7)(encoding@0.1.13)(utf-8-validate@6.0.3) + version: 6.1.2 + turbo: + specifier: ^2.6.1 + version: 2.7.2 + typescript: + specifier: 5.8.3 + version: 5.8.3 - packages/network: - dependencies: - '@0xsequence/core': + packages/test: + devDependencies: + '@tanstack/react-query': + specifier: 'catalog:' + version: 5.49.2(react@18.3.1) + '@tanstack/vue-query': + specifier: 'catalog:' + version: 5.49.1(vue@3.4.27(typescript@5.9.3)) + '@testing-library/dom': + specifier: 'catalog:' + version: 10.4.0 + '@testing-library/react': + specifier: 'catalog:' + version: 16.0.1(@testing-library/dom@10.4.0)(@types/react-dom@18.3.0)(@types/react@18.3.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@types/react': + specifier: 'catalog:' + version: 18.3.1 + '@types/react-dom': + specifier: 'catalog:' + version: 18.3.0 + '@wagmi/core': specifier: workspace:* version: link:../core - '@0xsequence/indexer': + '@wagmi/vue': specifier: workspace:* - version: link:../services/indexer - '@0xsequence/relayer': - specifier: workspace:* - version: link:../services/relayer - '@0xsequence/utils': + version: link:../vue + react: + specifier: 'catalog:' + version: 18.3.1 + react-dom: + specifier: 'catalog:' + version: 18.3.1(react@18.3.1) + vue: + specifier: 'catalog:' + version: 3.4.27(typescript@5.9.3) + wagmi: specifier: workspace:* - version: link:../utils - devDependencies: - ethers: - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) + version: link:../react - packages/provider: + packages/vue: dependencies: - '@0xsequence/abi': - specifier: workspace:* - version: link:../utils/abi - '@0xsequence/account': + '@wagmi/connectors': specifier: workspace:* - version: link:../account - '@0xsequence/auth': - specifier: workspace:* - version: link:../auth - '@0xsequence/core': + version: link:../connectors + '@wagmi/core': specifier: workspace:* version: link:../core - '@0xsequence/migration': - specifier: workspace:* - version: link:../migration - '@0xsequence/network': - specifier: workspace:* - version: link:../network - '@0xsequence/relayer': - specifier: workspace:* - version: link:../services/relayer - '@0xsequence/utils': - specifier: workspace:* - version: link:../utils - '@0xsequence/wallet': - specifier: workspace:* - version: link:../wallet - '@databeat/tracker': - specifier: ^0.9.1 - version: 0.9.3 - eventemitter2: - specifier: ^6.4.5 - version: 6.4.9 - webextension-polyfill: - specifier: ^0.10.0 - version: 0.10.0 devDependencies: - '@types/webextension-polyfill': - specifier: ^0.10.0 - version: 0.10.7 - ethers: - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - hardhat: - specifier: ^2.20.1 - version: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@5.0.10) - - packages/react-native: - dependencies: - '@0xsequence/waas': + '@nuxt/schema': + specifier: ^3.11.2 + version: 3.11.2(rollup@4.54.0) + '@tanstack/vue-query': + specifier: 'catalog:' + version: 5.49.1(vue@3.4.27(typescript@5.9.3)) + '@vue/test-utils': + specifier: ^2.4.6 + version: 2.4.6 + nuxt: + specifier: ^3.19.0 + version: 3.19.0(@biomejs/biome@1.9.4)(@parcel/watcher@2.5.1)(@types/node@24.0.1)(@vercel/blob@1.0.2)(@vue/compiler-sfc@3.5.26)(bufferutil@4.1.0)(cac@6.7.14)(db0@0.3.4)(encoding@0.1.13)(idb-keyval@6.2.1)(ioredis@5.8.2)(lightningcss@1.30.2)(magicast@0.5.1)(rolldown@1.0.0-beta.35)(rollup@4.54.0)(terser@5.44.1)(tsx@4.19.2)(typescript@5.9.3)(utf-8-validate@6.0.5)(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(yaml@2.8.2) + vue: + specifier: 'catalog:' + version: 3.4.27(typescript@5.9.3) + + playgrounds/next: + dependencies: + '@next/bundle-analyzer': + specifier: ^15.2.4 + version: 15.3.3(bufferutil@4.0.8)(utf-8-validate@6.0.5) + '@tanstack/react-query': + specifier: '>=5.45.1' + version: 5.49.2(react@18.3.1) + next: + specifier: 15.4.10 + version: 15.4.10(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + react: + specifier: '>=18.3.1' + version: 18.3.1 + react-dom: + specifier: '>=18.3.1' + version: 18.3.1(react@18.3.1) + viem: + specifier: 2.* + version: 2.10.8(bufferutil@4.0.8)(typescript@5.9.3)(utf-8-validate@6.0.5)(zod@3.25.20) + wagmi: specifier: workspace:* - version: link:../waas - react-native-keychain: - specifier: ^8.2.0 - version: 8.2.0 + version: link:../../packages/react + devDependencies: + '@types/node': + specifier: ^22.14.1 + version: 22.15.31 + '@types/react': + specifier: '>=18.3.1' + version: 18.3.1 + '@types/react-dom': + specifier: '>=18.3.0' + version: 18.3.0 + bufferutil: + specifier: ^4.0.8 + version: 4.0.8 + encoding: + specifier: ^0.1.13 + version: 0.1.13 + lokijs: + specifier: ^1.5.12 + version: 1.5.12 + pino-pretty: + specifier: ^13.0.0 + version: 13.0.0 + supports-color: + specifier: ^9.4.0 + version: 9.4.0 + utf-8-validate: + specifier: ^6.0.5 + version: 6.0.5 - packages/relayer: + playgrounds/nuxt: dependencies: - '@0xsequence/abi': + '@tanstack/vue-query': + specifier: '>=5.45.0' + version: 5.49.1(vue@3.4.27(typescript@5.9.3)) + '@wagmi/vue': specifier: workspace:* - version: link:../utils/abi - '@0xsequence/core': + version: link:../../packages/vue + nuxt: + specifier: ^3.19.0 + version: 3.19.0(@biomejs/biome@1.9.4)(@parcel/watcher@2.5.1)(@types/node@24.0.1)(@vercel/blob@1.0.2)(@vue/compiler-sfc@3.5.26)(bufferutil@4.1.0)(cac@6.7.14)(db0@0.3.4)(encoding@0.1.13)(idb-keyval@6.2.1)(ioredis@5.8.2)(lightningcss@1.30.2)(magicast@0.5.1)(rolldown@1.0.0-beta.35)(rollup@4.54.0)(terser@5.44.1)(tsx@4.19.2)(typescript@5.9.3)(utf-8-validate@6.0.5)(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(yaml@2.8.2) + viem: + specifier: 2.* + version: 2.10.8(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@6.0.5)(zod@3.25.20) + vue: + specifier: '>=3.4.21' + version: 3.4.27(typescript@5.9.3) + vue-router: + specifier: ^4.3.2 + version: 4.3.2(vue@3.4.27(typescript@5.9.3)) + + playgrounds/vite-core: + dependencies: + '@wagmi/connectors': specifier: workspace:* - version: link:../core - '@0xsequence/utils': + version: link:../../packages/connectors + '@wagmi/core': specifier: workspace:* - version: link:../utils + version: link:../../packages/core + react: + specifier: '>=18.3.1' + version: 18.3.1 + react-dom: + specifier: '>=18.3.1' + version: 18.3.1(react@18.3.1) + viem: + specifier: 2.* + version: 2.10.8(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@6.0.5)(zod@3.25.20) devDependencies: - '@0xsequence/signhub': + '@types/react': + specifier: '>=18.3.1' + version: 18.3.1 + '@types/react-dom': + specifier: '>=18.3.0' + version: 18.3.0 + '@vitejs/plugin-react': + specifier: ^4.2.1 + version: 4.2.1(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2)) + buffer: + specifier: ^6.0.3 + version: 6.0.3 + vite: + specifier: ^7.3.0 + version: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + + playgrounds/vite-react: + dependencies: + '@tanstack/query-sync-storage-persister': + specifier: 5.0.5 + version: 5.0.5 + '@tanstack/react-query': + specifier: '>=5.45.1' + version: 5.49.2(react@18.3.1) + '@tanstack/react-query-persist-client': + specifier: 5.0.5 + version: 5.0.5(@tanstack/react-query@5.49.2(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + idb-keyval: + specifier: ^6.2.1 + version: 6.2.1 + react: + specifier: '>=18.3.1' + version: 18.3.1 + react-dom: + specifier: '>=18.3.1' + version: 18.3.1(react@18.3.1) + viem: + specifier: 2.* + version: 2.10.8(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@6.0.5)(zod@3.25.20) + wagmi: specifier: workspace:* - version: link:../signhub - '@0xsequence/tests': + version: link:../../packages/react + devDependencies: + '@tanstack/react-query-devtools': + specifier: 5.0.5 + version: 5.0.5(@tanstack/react-query@5.49.2(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@types/react': + specifier: '>=18.3.1' + version: 18.3.1 + '@types/react-dom': + specifier: '>=18.3.0' + version: 18.3.0 + '@vitejs/plugin-react': + specifier: ^4.2.1 + version: 4.2.1(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2)) + '@wagmi/cli': specifier: workspace:* - version: link:../tests - '@0xsequence/wallet-contracts': - specifier: ^1.10.0 - version: 1.10.0 - ethers: - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) + version: link:../../packages/cli + buffer: + specifier: ^6.0.3 + version: 6.0.3 + vite: + specifier: ^7.3.0 + version: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) - packages/replacer: + playgrounds/vite-vue: dependencies: - '@0xsequence/abi': - specifier: workspace:* - version: link:../utils/abi - '@0xsequence/core': + '@tanstack/vue-query': + specifier: '>=5.45.0' + version: 5.49.1(vue@3.4.27(typescript@5.9.3)) + '@wagmi/vue': specifier: workspace:* - version: link:../core - ethers: - specifier: '>=5.5' - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - - packages/services/api: + version: link:../../packages/vue + viem: + specifier: 2.* + version: 2.10.8(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@6.0.5)(zod@3.25.20) + vue: + specifier: '>=3.4.21' + version: 3.4.27(typescript@5.9.3) devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - typescript: - specifier: ^5.9.3 - version: 5.9.3 + '@vitejs/plugin-vue': + specifier: ^5.0.4 + version: 5.0.4(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(vue@3.4.27(typescript@5.9.3)) + buffer: + specifier: ^6.0.3 + version: 6.0.3 + vite: + specifier: ^7.3.0 + version: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + vue-tsc: + specifier: ^2.0.6 + version: 2.0.16(typescript@5.9.3) - packages/services/builder: + site: devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - typescript: - specifier: ^5.9.3 - version: 5.9.3 + '@shikijs/vitepress-twoslash': + specifier: 1.22.2 + version: 1.22.2(@nuxt/kit@3.20.2(magicast@0.5.1))(typescript@5.9.3) + '@tanstack/query-core': + specifier: 'catalog:' + version: 5.49.1 + '@tanstack/react-query': + specifier: 'catalog:' + version: 5.49.2(react@18.3.1) + '@tanstack/vue-query': + specifier: 'catalog:' + version: 5.49.1(vue@3.4.27(typescript@5.9.3)) + '@types/react': + specifier: 'catalog:' + version: 18.3.1 + '@wagmi/connectors': + specifier: workspace:* + version: link:../packages/connectors + '@wagmi/core': + specifier: workspace:* + version: link:../packages/core + '@wagmi/vue': + specifier: workspace:* + version: link:../packages/vue + abitype: + specifier: '*' + version: 1.0.2(typescript@5.9.3)(zod@3.25.20) + nuxt: + specifier: ^3.19.0 + version: 3.19.0(@biomejs/biome@1.9.4)(@parcel/watcher@2.5.1)(@types/node@24.0.1)(@vercel/blob@1.0.2)(@vue/compiler-sfc@3.5.26)(bufferutil@4.1.0)(cac@6.7.14)(db0@0.3.4)(encoding@0.1.13)(idb-keyval@6.2.1)(ioredis@5.8.2)(lightningcss@1.30.2)(magicast@0.5.1)(rolldown@1.0.0-beta.35)(rollup@4.54.0)(terser@5.44.1)(tsx@4.19.2)(typescript@5.9.3)(utf-8-validate@6.0.5)(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(yaml@2.8.2) + react: + specifier: 'catalog:' + version: 18.3.1 + unocss: + specifier: ^0.59.4 + version: 0.59.4(rollup@4.54.0) + viem: + specifier: 2.* + version: 2.10.8(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@6.0.5)(zod@3.25.20) + vitepress: + specifier: 1.5.0 + version: 1.5.0(@algolia/client-search@5.12.0)(@types/node@24.0.1)(@types/react@18.3.1)(change-case@5.4.4)(fuse.js@7.1.0)(idb-keyval@6.2.1)(jwt-decode@4.0.0)(lightningcss@1.30.2)(postcss@8.5.6)(qrcode@1.5.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(terser@5.44.1)(typescript@5.9.3) + vue: + specifier: 'catalog:' + version: 3.4.27(typescript@5.9.3) + wagmi: + specifier: workspace:* + version: link:../packages/react - packages/services/guard: - dependencies: - ox: - specifier: ^0.9.17 - version: 0.9.17(typescript@5.9.3)(zod@4.2.0) - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - typescript: - specifier: ^5.9.3 - version: 5.9.3 - vitest: - specifier: ^4.0.18 - version: 4.0.18(@types/node@25.3.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)) +packages: - packages/services/identity-instrument: - dependencies: - json-canonicalize: - specifier: ^2.0.0 - version: 2.0.0 - jwt-decode: - specifier: ^4.0.0 - version: 4.0.0 - ox: - specifier: ^0.9.17 - version: 0.9.17(typescript@5.9.3)(zod@4.2.0) - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - typescript: - specifier: ^5.9.3 - version: 5.9.3 - vitest: - specifier: ^4.0.18 - version: 4.0.18(@types/node@25.3.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)) + 0xsequence@2.3.39: + resolution: {integrity: sha512-P+Cu6gRjClOiQRBQzxp8EvX5X1aSbgKYM79f0lpZ76jTCwf8sbGT+A6ZZSPohEIZr2hTv4iOk9ERvaPAaiJ9qg==} + peerDependencies: + ethers: '>=6' - packages/services/indexer: - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - typescript: - specifier: ^5.9.3 - version: 5.9.3 + '@0xsequence/abi@2.3.39': + resolution: {integrity: sha512-MQxVIwwq84IYK2lRHO/lXJQRp21oP982oGyKl5mlkp1jzUE4+GGEMYuo4B3pnokdEeVmSkOJL7j/xJGVYxzlKw==} - packages/services/marketplace: - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - typescript: - specifier: ^5.9.3 - version: 5.9.3 + '@0xsequence/account@2.3.39': + resolution: {integrity: sha512-VgsmHLm7uOdd3SuXt1kykzpnQ1E/S0gQczJskPZIQXdfwGyyA1CnE+LXqzCWy0rr48ny9VktZ+f9ZqWixDuh+Q==} + peerDependencies: + ethers: '>=6' - packages/services/metadata: - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - typescript: - specifier: ^5.9.3 - version: 5.9.3 + '@0xsequence/api@2.3.39': + resolution: {integrity: sha512-Gdl6TfUANFy8S+/pUR+BjfgxyXDq2pVzDFkmS7xppa/lcxmwB4lRfrlkuehOqeTLeXgAKbERBWenOOMYctJBqg==} - packages/services/relayer: - dependencies: - '@0xsequence/wallet-primitives': - specifier: workspace:^ - version: link:../../wallet/primitives - mipd: - specifier: ^0.0.7 - version: 0.0.7(typescript@5.9.3) - ox: - specifier: ^0.9.17 - version: 0.9.17(typescript@5.9.3)(zod@4.2.0) - viem: - specifier: ^2.40.3 - version: 2.42.1(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@6.0.3)(zod@4.2.0) - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - typescript: - specifier: ^5.9.3 - version: 5.9.3 - vitest: - specifier: ^4.0.18 - version: 4.0.18(@types/node@25.3.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)) + '@0xsequence/auth@2.3.39': + resolution: {integrity: sha512-UaLM4NTcNPbR8A+Gf4/RxAfM4thjxjJe95OUo41ABeR/BRqDFbbWUmU79h1UU6iONspe1nlz022ZtPqwXKKKdw==} + peerDependencies: + ethers: '>=6' - packages/services/userdata: - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - typescript: - specifier: ^5.9.3 - version: 5.9.3 + '@0xsequence/connect@0.0.0-20250924112110': + resolution: {integrity: sha512-OssaxA1AuawEz26uMg0exl7elsHPnC6Hi15Lam6QTCdbMff4EPGSx6vmUPMP8b5XbSH+UwAbStpjvYHPTk6K1Q==} + peerDependencies: + ethers: '>=6.13.0' + react: '>= 17' + react-dom: '>= 17' + viem: ^2.33.3 + wagmi: 2.15.0 + + '@0xsequence/core@2.3.39': + resolution: {integrity: sha512-4noc1KW1b5g8telV1qac6yZbdkMD5x8gqRa5QnIvMmAVHsXC8qCYlFpy76csYKlWgFKGqxN8RWOwihnZbuyuRg==} + peerDependencies: + ethers: '>=6' - packages/sessions: - dependencies: - '@0xsequence/core': - specifier: workspace:* - version: link:../core - '@0xsequence/migration': - specifier: workspace:* - version: link:../migration - '@0xsequence/replacer': - specifier: workspace:* - version: link:../replacer - ethers: - specifier: ^5.5.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - idb: - specifier: ^7.1.1 - version: 7.1.1 - devDependencies: - '@0xsequence/signhub': - specifier: workspace:* - version: link:../signhub - '@0xsequence/tests': - specifier: workspace:* - version: link:../tests - '@istanbuljs/nyc-config-typescript': - specifier: ^1.0.2 - version: 1.0.2(nyc@15.1.0) - fake-indexeddb: - specifier: ^4.0.1 - version: 4.0.2 - nyc: - specifier: ^15.1.0 - version: 15.1.0 + '@0xsequence/dapp-client@git+https://git@github.com:0xsequence/sequence.js.git#6a3501096be6b465b65c034b648549c0b69f8990': + resolution: {commit: 6a3501096be6b465b65c034b648549c0b69f8990, repo: git@github.com:0xsequence/sequence.js.git, type: git} + version: 3.0.0-beta.1 - packages/signhub: - dependencies: - '@0xsequence/core': - specifier: workspace:* - version: link:../core - ethers: - specifier: ^5.5.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - devDependencies: - '@istanbuljs/nyc-config-typescript': - specifier: ^1.0.2 - version: 1.0.2(nyc@15.1.0) - nyc: - specifier: ^15.1.0 - version: 15.1.0 - - packages/simulator: - dependencies: - '@0xsequence/core': - specifier: workspace:* - version: link:../core - '@0xsequence/wallet-contracts': - specifier: ^1.10.0 - version: 1.10.0 - devDependencies: - '@0xsequence/signhub': - specifier: workspace:* - version: link:../signhub - '@0xsequence/tests': - specifier: workspace:* - version: link:../tests - ethers: - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - - packages/tests: - dependencies: - '@0xsequence/core': - specifier: workspace:* - version: link:../core - devDependencies: - '@istanbuljs/nyc-config-typescript': - specifier: ^1.0.1 - version: 1.0.2(nyc@15.1.0) - ethers: - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - web3: - specifier: ^1.8.1 - version: 1.10.4(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@6.0.3) - - packages/utils: - dependencies: - js-base64: - specifier: ^3.7.2 - version: 3.7.8 - devDependencies: - ethers: - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - - packages/utils/abi: - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - typescript: - specifier: ^5.9.3 - version: 5.9.3 - - packages/waas: - dependencies: - '@0xsequence/core': - specifier: workspace:* - version: link:../core - '@0xsequence/network': - specifier: workspace:* - version: link:../network - '@aws-sdk/client-cognito-identity-provider': - specifier: ^3.445.0 - version: 3.1037.0 - ethers: - specifier: '>=5.5' - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - idb: - specifier: ^7.1.1 - version: 7.1.1 - json-canonicalize: - specifier: ^1.0.6 - version: 1.2.0 - jwt-decode: - specifier: ^4.0.0 - version: 4.0.0 - devDependencies: - '@types/jwt-decode': - specifier: ^3.1.0 - version: 3.1.0 - fake-indexeddb: - specifier: ^4.0.1 - version: 4.0.2 - - packages/waas-ethers: - dependencies: - '@0xsequence/waas': - specifier: workspace:* - version: link:../waas - ethers: - specifier: '>=5.5' - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - - packages/wallet: - dependencies: - '@0xsequence/abi': - specifier: workspace:* - version: link:../utils/abi - '@0xsequence/core': - specifier: workspace:* - version: link:../core - '@0xsequence/network': - specifier: workspace:* - version: link:../network - '@0xsequence/relayer': - specifier: workspace:* - version: link:../services/relayer - '@0xsequence/signhub': - specifier: workspace:* - version: link:../signhub - '@0xsequence/utils': - specifier: workspace:* - version: link:../utils - devDependencies: - '@0xsequence/ethauth': - specifier: ^0.8.1 - version: 0.8.1(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3)) - '@0xsequence/tests': - specifier: workspace:* - version: link:../tests - '@0xsequence/wallet-contracts': - specifier: ^2.0.0 - version: 2.0.0(@ethersproject/abi@5.8.0)(@ethersproject/bytes@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3))(bufferutil@4.1.0)(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@6.0.3) - '@istanbuljs/nyc-config-typescript': - specifier: ^1.0.1 - version: 1.0.2(nyc@15.1.0) - ethers: - specifier: ^5.7.2 - version: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - web3: - specifier: ^1.8.1 - version: 1.10.4(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@6.0.3) - - packages/wallet/core: - dependencies: - '@0xsequence/guard': - specifier: workspace:^ - version: link:../../services/guard - '@0xsequence/relayer': - specifier: workspace:^ - version: link:../../services/relayer - '@0xsequence/wallet-primitives': - specifier: workspace:^ - version: link:../primitives - mipd: - specifier: ^0.0.7 - version: 0.0.7(typescript@5.9.3) - ox: - specifier: ^0.9.17 - version: 0.9.17(typescript@5.9.3)(zod@4.2.0) - viem: - specifier: ^2.40.3 - version: 2.42.1(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@6.0.3)(zod@4.2.0) - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - '@vitest/coverage-v8': - specifier: ^4.0.18 - version: 4.0.18(vitest@4.0.18(@types/node@25.3.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3))) - dotenv: - specifier: ^17.3.1 - version: 17.3.1 - fake-indexeddb: - specifier: ^6.2.5 - version: 6.2.5 - typescript: - specifier: ^5.9.3 - version: 5.9.3 - vitest: - specifier: ^4.0.18 - version: 4.0.18(@types/node@25.3.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)) - - packages/wallet/dapp-client: - dependencies: - '@0xsequence/guard': - specifier: workspace:^ - version: link:../../services/guard - '@0xsequence/relayer': - specifier: workspace:^ - version: link:../../services/relayer - '@0xsequence/wallet-core': - specifier: workspace:^ - version: link:../core - '@0xsequence/wallet-primitives': - specifier: workspace:^ - version: link:../primitives - ox: - specifier: ^0.9.17 - version: 0.9.17(typescript@5.9.3)(zod@4.2.0) - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - '@vitest/coverage-v8': - specifier: ^4.0.18 - version: 4.0.18(vitest@4.0.18(@types/node@25.3.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3))) - dotenv: - specifier: ^17.3.1 - version: 17.3.1 - fake-indexeddb: - specifier: ^6.2.5 - version: 6.2.5 - happy-dom: - specifier: ^20.8.9 - version: 20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3) - typescript: - specifier: ^5.9.3 - version: 5.9.3 - vitest: - specifier: ^4.0.18 - version: 4.0.18(@types/node@25.3.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)) - - packages/wallet/primitives: - dependencies: - ox: - specifier: ^0.9.17 - version: 0.9.17(typescript@5.9.3)(zod@4.2.0) - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@vitest/coverage-v8': - specifier: ^4.0.18 - version: 4.0.18(vitest@4.0.18(@types/node@25.6.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3))) - typescript: - specifier: ^5.9.3 - version: 5.9.3 - vitest: - specifier: ^4.0.18 - version: 4.0.18(@types/node@25.6.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)) - - packages/wallet/primitives-cli: - dependencies: - '@0xsequence/wallet-primitives': - specifier: workspace:^ - version: link:../primitives - ox: - specifier: ^0.9.17 - version: 0.9.17(typescript@5.9.3)(zod@4.2.0) - yargs: - specifier: ^18.0.0 - version: 18.0.0 - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - '@types/yargs': - specifier: ^17.0.35 - version: 17.0.35 - concurrently: - specifier: ^9.2.1 - version: 9.2.1 - esbuild: - specifier: ^0.27.3 - version: 0.27.3 - nodemon: - specifier: ^3.1.14 - version: 3.1.14 - typescript: - specifier: ^5.9.3 - version: 5.9.3 - - packages/wallet/wallet-contracts: - dependencies: - 0xsequence: - specifier: ^1.10.15 - version: 1.10.15(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - '@0xsequence/wallet': - specifier: ^2.3.33 - version: 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@typechain/ethers-v6': - specifier: ^0.5.1 - version: 0.5.1(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@4.9.5))(typescript@4.9.5) - ethers: - specifier: ^6.15.0 - version: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - keccak256: - specifier: ^1.0.6 - version: 1.0.6 - devDependencies: - '@nomicfoundation/hardhat-ethers': - specifier: ^4.0.3 - version: 4.0.9(bufferutil@4.1.0)(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - '@nomicfoundation/hardhat-verify': - specifier: ^3.0.7 - version: 3.0.15(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)) - '@nomiclabs/hardhat-truffle5': - specifier: ^3.0.0 - version: 3.0.0 - '@nomiclabs/hardhat-web3': - specifier: ^2.1.0 - version: 2.1.2(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))(web3@1.10.4(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@5.0.10)) - '@tenderly/hardhat-tenderly': - specifier: ^2.5.2 - version: 2.5.2(@types/node@25.6.0)(bufferutil@4.1.0)(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - '@types/chai': - specifier: ^4.3.20 - version: 4.3.20 - '@types/chai-as-promised': - specifier: ^7.1.8 - version: 7.1.8 - '@types/chai-string': - specifier: ^1.4.5 - version: 1.4.5 - '@types/mocha': - specifier: ^8.2.3 - version: 8.2.3 - '@typescript-eslint/eslint-plugin': - specifier: ^8.46.4 - version: 8.59.0(@typescript-eslint/parser@8.59.0(eslint@9.39.4)(typescript@4.9.5))(eslint@9.39.4)(typescript@4.9.5) - '@typescript-eslint/parser': - specifier: ^8.46.4 - version: 8.59.0(eslint@9.39.4)(typescript@4.9.5) - bn-chai: - specifier: ^1.0.1 - version: 1.0.1(chai@4.5.0) - chai: - specifier: ^4.5.0 - version: 4.5.0 - chai-as-promised: - specifier: ^7.1.2 - version: 7.1.2(chai@4.5.0) - chai-bignumber: - specifier: ^3.1.0 - version: 3.1.0 - chai-shallow-deep-equal: - specifier: ^1.4.6 - version: 1.4.6(chai@4.5.0) - chai-string: - specifier: ^1.6.0 - version: 1.6.0(chai@4.5.0) - child_process: - specifier: ^1.0.2 - version: 1.0.2 - dotenv: - specifier: ^8.6.0 - version: 8.6.0 - eslint: - specifier: ^9.39.2 - version: 9.39.4 - eslint-config-prettier: - specifier: ^8.10.2 - version: 8.10.2(eslint@9.39.4) - eslint-plugin-import: - specifier: ^2.32.0 - version: 2.32.0(@typescript-eslint/parser@8.59.0(eslint@9.39.4)(typescript@4.9.5))(eslint@9.39.4) - eslint-plugin-prettier: - specifier: ^3.4.1 - version: 3.4.1(eslint-config-prettier@8.10.2(eslint@9.39.4))(eslint@9.39.4)(prettier@3.8.1) - ethereum-waffle: - specifier: ^4.0.10 - version: 4.0.10(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(@ethersproject/abi@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(encoding@0.1.13)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(typescript@4.9.5) - ganache-cli: - specifier: 6.12.2 - version: 6.12.2 - hardhat: - specifier: ^2.27.0 - version: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10) - hardhat-gas-reporter: - specifier: 1.0.10 - version: 1.0.10(bufferutil@4.1.0)(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - husky: - specifier: ^9.1.7 - version: 9.1.7 - ora: - specifier: ^5.4.1 - version: 5.4.1 - rimraf: - specifier: ^3.0.2 - version: 3.0.2 - scrypt: - specifier: github:barrysteyn/node-scrypt#fb60a8d3c158fe115a624b5ffa7480f3a24b03fb - version: https://codeload.github.com/barrysteyn/node-scrypt/tar.gz/fb60a8d3c158fe115a624b5ffa7480f3a24b03fb - solhint: - specifier: ^3.6.2 - version: 3.6.2(typescript@4.9.5) - solidity-coverage: - specifier: ^0.8.17 - version: 0.8.17(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)) - threads: - specifier: ^1.7.0 - version: 1.7.0 - ts-node: - specifier: ^10.9.2 - version: 10.9.2(@types/node@25.6.0)(typescript@4.9.5) - typechain: - specifier: ^8.3.2 - version: 8.3.2(typescript@4.9.5) - typescript: - specifier: ^4.9.5 - version: 4.9.5 - yesno: - specifier: ^0.3.1 - version: 0.3.1 - - packages/wallet/wdk: - dependencies: - '@0xsequence/guard': - specifier: workspace:^ - version: link:../../services/guard - '@0xsequence/identity-instrument': - specifier: workspace:^ - version: link:../../services/identity-instrument - '@0xsequence/relayer': - specifier: workspace:^ - version: link:../../services/relayer - '@0xsequence/tee-verifier': - specifier: ^0.1.2 - version: 0.1.2 - '@0xsequence/wallet-core': - specifier: workspace:^ - version: link:../core - '@0xsequence/wallet-primitives': - specifier: workspace:^ - version: link:../primitives - idb: - specifier: ^8.0.3 - version: 8.0.3 - jwt-decode: - specifier: ^4.0.0 - version: 4.0.0 - ox: - specifier: ^0.9.17 - version: 0.9.17(typescript@5.9.3)(zod@4.2.0) - uuid: - specifier: ^14.0.0 - version: 14.0.0 - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../../../repo/eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../../../repo/typescript-config - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - '@vitest/coverage-v8': - specifier: ^4.0.18 - version: 4.0.18(vitest@4.0.18(@types/node@25.3.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3))) - dotenv: - specifier: ^17.3.1 - version: 17.3.1 - fake-indexeddb: - specifier: ^6.2.5 - version: 6.2.5 - happy-dom: - specifier: ^20.8.9 - version: 20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3) - typescript: - specifier: ^5.9.3 - version: 5.9.3 - vitest: - specifier: ^4.0.18 - version: 4.0.18(@types/node@25.3.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)) + '@0xsequence/design-system@2.1.11': + resolution: {integrity: sha512-wfuY9v2dNQxw9qAYyflwcKzuiiVqm4qqn2Jkoyw/CqxODcqQ3orUsGxjnbyvCWOwvHbH908c4LOZj/TBI6T0Fw==} + peerDependencies: + motion: '>= 12' + react: '>= 17' + react-dom: '>= 17' - repo/eslint-config: - devDependencies: - '@eslint/js': - specifier: ^9.39.2 - version: 9.39.2 - '@next/eslint-plugin-next': - specifier: ^15.5.9 - version: 15.5.9 - eslint: - specifier: ^9.39.2 - version: 9.39.2 - eslint-config-prettier: - specifier: ^10.1.8 - version: 10.1.8(eslint@9.39.2) - eslint-plugin-only-warn: - specifier: ^1.1.0 - version: 1.1.0 - eslint-plugin-react: - specifier: ^7.37.5 - version: 7.37.5(eslint@9.39.2) - eslint-plugin-react-hooks: - specifier: ^7.0.1 - version: 7.0.1(eslint@9.39.2) - eslint-plugin-turbo: - specifier: ^2.6.3 - version: 2.6.3(eslint@9.39.2)(turbo@2.9.6) - globals: - specifier: ^16.5.0 - version: 16.5.0 - typescript: - specifier: ^5.9.3 - version: 5.9.3 - typescript-eslint: - specifier: ^8.49.0 - version: 8.50.0(eslint@9.39.2)(typescript@5.9.3) + '@0xsequence/ethauth@1.0.0': + resolution: {integrity: sha512-piihXzbS8Sq7P670a+GyTm3igTJL3Ts6pqjJcC0Sv86yqeK6QD0pzJP4APP+/IQa5k+0s2l1SeZwMjR7gSPtCA==} + peerDependencies: + ethers: '>=6' - repo/typescript-config: {} + '@0xsequence/guard@2.3.39': + resolution: {integrity: sha512-XtM90alrUXA4A3wjFRG0CBJvmtf2X4SqAdojuJLJ84uRs2MFGriwS3X6GkHYndtwOpAuLlOFBcC80/BVnF4GNw==} + peerDependencies: + ethers: '>=6' - repo/ui: - dependencies: - react: - specifier: ^19.2.3 - version: 19.2.3 - react-dom: - specifier: ^19.2.3 - version: 19.2.3(react@19.2.3) - devDependencies: - '@repo/eslint-config': - specifier: workspace:^ - version: link:../eslint-config - '@repo/typescript-config': - specifier: workspace:^ - version: link:../typescript-config - '@turbo/gen': - specifier: ^1.13.4 - version: 1.13.4(@types/node@25.3.0)(typescript@5.9.3) - '@types/node': - specifier: ^25.3.0 - version: 25.3.0 - '@types/react': - specifier: ^19.2.7 - version: 19.2.7 - '@types/react-dom': - specifier: ^19.2.3 - version: 19.2.3(@types/react@19.2.7) - typescript: - specifier: ^5.9.3 - version: 5.9.3 + '@0xsequence/guard@git+https://git@github.com:0xsequence/sequence.js.git#501693a7bd7332ad10fd0f4a72e0dd153b44af0a': + resolution: {commit: 501693a7bd7332ad10fd0f4a72e0dd153b44af0a, repo: git@github.com:0xsequence/sequence.js.git, type: git} + version: 3.0.0-beta.1 -packages: + '@0xsequence/hooks@0.0.0-20250924112110': + resolution: {integrity: sha512-KMvUsP+ikXlj9sJEnlQOoX4XtBru/xBcQq4q7qncjAJ4jQAFqDWQNk/QI1M5jN1eWdwuj0edT4M5T/dPVqb/Eg==} + peerDependencies: + '@0xsequence/api': '>=2.3.23' + '@0xsequence/indexer': '>=2.3.23' + '@0xsequence/metadata': '>=2.3.23' + '@0xsequence/network': '>=2.3.23' + '@tanstack/react-query': '>= 5' + react: '>= 17' + react-dom: '>= 17' + viem: ^2.33.3 + + '@0xsequence/indexer@2.3.39': + resolution: {integrity: sha512-oiDcwNg84ZQkme7Xd9aV2RkHUHzybtqac45H887/AmEFaLFWOcnNBlhXPaUOxclofAnVENIYaVf6NscWrKEzng==} + + '@0xsequence/metadata@2.3.39': + resolution: {integrity: sha512-E+tpckzVKctCnNsskEu1PMoOzZojRg82wpiJZ9OOJxxZdLS8yj5meeLdo+76CU0zajsICTuwi7nbgHesvSPPwg==} + + '@0xsequence/migration@2.3.39': + resolution: {integrity: sha512-5qNemWMD3ZqvXhbxlgGhyKVZDev1v8XfTfBiqoib5yycVHm9fqZnaGXr9LKRsLGm8oMf55kisZjrZ3YiG8Hlig==} + peerDependencies: + ethers: '>=6' - 0xsequence@1.10.15: - resolution: {integrity: sha512-HtETUgbXS35vllu5buoiH8TrlV7boNQ+Odtae3mFQPTtsd/9Px81gFzHJhtCbcivK3QV6UC6+4nmK6KOKqInlw==} + '@0xsequence/network@2.3.39': + resolution: {integrity: sha512-ePVe5UfOEAhYOouZuPRd25IF6Lfe9HVCL2Dbp3Zm+hcAHv0Bl89A7TPg9+JQH9Eih0Z+N5uSNJuGfV+Xe+jAUg==} peerDependencies: - ethers: '>=5.5 < 6' + ethers: '>=6' - '@0xsequence/abi@1.10.15': - resolution: {integrity: sha512-nuh68P8tRDzIMIH7mnGX1Eab0jsYVGhZa7IlNIs8CfTnGoanxLS+MGk5ioZBa6+slzxb9VP8mnQ5QhAWeFySeg==} + '@0xsequence/provider@2.3.39': + resolution: {integrity: sha512-3YbyMqFk8oCFtyvyHaXYntgCzgYKLMNvolhq7ioUcxqEp2tzYGAB6bDhUVbVYOW2sPpVv4NuF/fpeAguQ2v8tQ==} + peerDependencies: + ethers: '>=6' - '@0xsequence/abi@2.3.43': - resolution: {integrity: sha512-ybWRT+knMPpOH/XBucw8/BviyqomLAgvbCxFTNB0WAaO3inVCdHEil2keBFXgPKGlEVozQ5ZhE0k6WQxb3bZSw==} + '@0xsequence/relayer@2.3.39': + resolution: {integrity: sha512-loVjpXqFLR9/Lu8mbTaTF1nf3YSQBvw4E+u+btrGz80aiTPKH8Q+BIWDLGtrXF1ian+yoAn4qdpgR3lZD3oYbg==} + peerDependencies: + ethers: '>=6' - '@0xsequence/account@1.10.15': - resolution: {integrity: sha512-NJhnOKWSRMj5YuI58HFTf3gC2Ld0FvUw6DUTikpF8JTx3xExWjafz5PJrQkJ/SpIYvS5GQJTB0Hjx6d6j1/dSQ==} + '@0xsequence/relayer@git+https://git@github.com:0xsequence/sequence.js.git#07221565e01c85b8cd0bcbb45ace5f9baf57f498': + resolution: {commit: 07221565e01c85b8cd0bcbb45ace5f9baf57f498, repo: git@github.com:0xsequence/sequence.js.git, type: git} + version: 3.0.0-beta.1 - '@0xsequence/api@1.10.15': - resolution: {integrity: sha512-FHzJLsOF/RU66pndfFP38yqLIaNiy46uv4f6DsJvnFSoHYfbkZjpx5m+M+vig0oN6RhtqU+sKL78z1IYF6JTkA==} + '@0xsequence/replacer@2.3.39': + resolution: {integrity: sha512-Z+FZu9iZRBPXfPo9KB2pT/lkG7mlDq5xDLNZ1D1E5GnKMHLCt7M8j4gvQMu6aWcmku9DNF98LrCMuKBlCgE7/w==} + peerDependencies: + ethers: '>=6' - '@0xsequence/auth@1.10.15': - resolution: {integrity: sha512-ZY8vf/l9J+1HWP4pIMNTRBDFVXgi22x8zmSLgE4xAo4JDZ6yiGAQPooJpRCs59gx1LtVI2Zt+KgvfW1qVxQDtQ==} + '@0xsequence/sessions@2.3.39': + resolution: {integrity: sha512-yALTne1Y5pYuUfxVQgXMzwmxRRq90yBQpJ13GX+Ha9w/w/HrHg0cNGCk/TpNsLxqYhusG9zP/2TsQEYEPQrdzw==} peerDependencies: - ethers: '>=5.5 < 6' + ethers: '>=6' - '@0xsequence/core@1.10.15': - resolution: {integrity: sha512-wrE5soJSqrhhm7pC+NxckLR0lJSOnsHPLKdDqWeTRmyuhtZ4e0DsrcoeoD40I/3Bd77tdZ1GGbq00CryV7JfFw==} + '@0xsequence/signhub@2.3.39': + resolution: {integrity: sha512-CyFWeyafgwQUo05Heq1sGX+t8QPdxQ5Q6g8E+j2VFaNFY8wxGcQxVddiGWUHfvCseIgtkZiyEzfeUkgqJtgpew==} peerDependencies: - ethers: '>=5.5' + ethers: '>=6' - '@0xsequence/core@2.3.43': - resolution: {integrity: sha512-kPJs8SS35fIYS0wrNJ/2ODW3YyBWKdEXq4mncyG4CvCO7zT6kohsYljC3uUyH4NwWGCYoMt1T8c1CKwnZBpJTQ==} + '@0xsequence/utils@2.3.39': + resolution: {integrity: sha512-0pePuw890L7LjCJvC2OM0Z5NprY/gwq8y7voHPe6hvFA6AnNKeRZPSyk1ysOhM6Ty9nciRjUt9xHG+fkDkdAug==} peerDependencies: ethers: '>=6' - '@0xsequence/ethauth@0.8.1': - resolution: {integrity: sha512-P21cxRSS+2mDAqFVAJt0lwQFtbObX+Ewlj8DMyDELp81+QbfHFh6LCyu8dTXNdBx6UbmRFOCSBno5Txd50cJPQ==} + '@0xsequence/waas@2.3.39': + resolution: {integrity: sha512-koDCmWCskVrxolZT09XOK25Na/zBD5e7eV+JQqNPJENwXNNB9Z/iqHJpQGmV3MZx0z1Is/K6ppyqWwlcB1cCPQ==} peerDependencies: - ethers: '>=5.5' + ethers: '>=6' - '@0xsequence/guard@1.10.15': - resolution: {integrity: sha512-YrHIrOXDGn+xOUcA7DI+ROW42cJqiL9WVaLKGAaGwjHLz/QKLiH1MmECWJMM76JczjA6Th8G9YZUFwO99Cpzpg==} + '@0xsequence/wallet-contracts@3.0.1': + resolution: {integrity: sha512-ZvZdXPE1KOYVjl9J6UdN/eBqEmuYHvlO4EUxDxG7VqCgrSiVP9S8k+mEN4aUMzOiYGwKcYY/HIkD211mvxseZQ==} - '@0xsequence/guard@3.0.6': - resolution: {integrity: sha512-codsLEGSh+PACHlAJOk1mBlrmYwuuolmLo2pzBfu9ekzUbtGIYbbaUebbzcK7r3ZSjcvMG3R+Mzqx5041WVK1Q==} + '@0xsequence/wallet-core@git+https://git@github.com:0xsequence/sequence.js.git#a623e7dad948e7b281119b34b5b6343bdf502eb8': + resolution: {commit: a623e7dad948e7b281119b34b5b6343bdf502eb8, repo: git@github.com:0xsequence/sequence.js.git, type: git} + version: 3.0.0-beta.1 - '@0xsequence/indexer@1.10.15': - resolution: {integrity: sha512-bc2gAIEplMcmWJMwLuXZZ0wifoxuV/zHyWzEdbQ5+9ruIXArxyoG0Ue9fMEzKWHfsAWyBKBJCCFbr4XJEQ5YjA==} + '@0xsequence/wallet-primitives@0.0.0-20250915145821': + resolution: {integrity: sha512-EiV2ke7XmPoamppXw3eVV8gsKWJTaYFq3zhP+vltaXMncBM+0MHhKuPRLMsdbB7V88olma9aafZtuuZhlSIwhQ==} - '@0xsequence/indexer@2.3.43': - resolution: {integrity: sha512-PBPEc+zsvEG8XOwvOOiMm+G1wmg2+20kfTTxOHD0TFMs6zx14gHbmhJjnfVMRTVVFoIrkSpy5g0g8Ia7yy8w6A==} + '@0xsequence/wallet-primitives@git+https://git@github.com:0xsequence/sequence.js.git#d2967108579e84603f3b5e05685c6f331c1f3db7': + resolution: {commit: d2967108579e84603f3b5e05685c6f331c1f3db7, repo: git@github.com:0xsequence/sequence.js.git, type: git} + version: 3.0.0-beta.1 - '@0xsequence/indexer@3.0.6': - resolution: {integrity: sha512-x1D16JUP1wefNrd/IIMyeiejqa1UnJt3eWYLS60VN8+uRfT/UEiL9ree6bvJ5a4GWqXtd9LnJQYr4dZWlMUvig==} + '@0xsequence/wallet@2.3.39': + resolution: {integrity: sha512-yBPdsw6HgD2txJXvYbknXSDGSTirtAKVD3d8QPZiVTyVVZIVbV60K1UGGLnVtF2HGph/gVOh9rd2SPVBHcP3DQ==} + peerDependencies: + ethers: '>=6' - '@0xsequence/metadata@1.10.15': - resolution: {integrity: sha512-eakkeV4ZtSkyo80JglSUdkUwOjYHAO5udCYAet6ekzHYgiF62dS9WcJdrrWkE2umAXn1sF94tQHf/OFZJGWwIg==} + '@adraffy/ens-normalize@1.10.0': + resolution: {integrity: sha512-nA9XHtlAkYfJxY7bce8DcN7eKxWWCWkU+1GR9d+U6MbNpfwQp8TI7vqOsBsMcHoT4mBu2kypKoSKnghEzOOq5Q==} - '@0xsequence/migration@1.10.15': - resolution: {integrity: sha512-muZllmKQOz3yEyJULrhDpycpML2IOH+KJiBN70reKPoMm/pxx/B4v4PAFOkd3oZ1ynSqcF0TkHqGmeyf5/SZ3g==} + '@adraffy/ens-normalize@1.10.1': + resolution: {integrity: sha512-96Z2IP3mYmF1Xg2cDm8f1gWGf/HUVedQ3FMifV4kG/PQ4yEP51xDtRAEfhVNt5f/uzpNkZHwWQuUcu6D6K+Ekw==} - '@0xsequence/multicall@1.10.15': - resolution: {integrity: sha512-yFTMDZR9tUvm3lefYyuxhohtx6mFzdpmn+qDFk9Bjo5TeEu0SGJLjdd6U2AK3rDIcPPw7rl7VvBXLweNJOMjfw==} - peerDependencies: - ethers: '>=5.5 < 6' + '@adraffy/ens-normalize@1.11.1': + resolution: {integrity: sha512-nhCBV3quEgesuf7c7KYfperqSS14T8bYuvJ8PcLJp6znkZpFc0AuW4qBtr8eKVyPPe/8RSr7sglCWPU5eaxwKQ==} - '@0xsequence/network@1.10.15': - resolution: {integrity: sha512-wHp8RGqFrncuoIh0ityO/jUobliargQ7SWlvZCf8Ez0T7uiXDEDokrFSN2F9FIl6i5a5NmcEpXhfhwS/L0pN2w==} - peerDependencies: - ethers: '>=5.5 < 6' + '@algolia/autocomplete-core@1.9.3': + resolution: {integrity: sha512-009HdfugtGCdC4JdXUbVJClA0q0zh24yyePn+KUGk3rP7j8FEe/m5Yo/z65gn6nP/cM39PxpzqKrL7A6fP6PPw==} - '@0xsequence/network@2.3.43': - resolution: {integrity: sha512-HLorxJ/UIKcRcUPyyTxy4yeaioxc2hmm0joqClfY8tvweO/ASKXXa4aXCdSDWaLFbVQlhmrn4i1FR/ykwQM57A==} + '@algolia/autocomplete-plugin-algolia-insights@1.9.3': + resolution: {integrity: sha512-a/yTUkcO/Vyy+JffmAnTWbr4/90cLzw+CC3bRbhnULr/EM0fGNvM13oQQ14f2moLMcVDyAx/leczLlAOovhSZg==} peerDependencies: - ethers: '>=6' + search-insights: '>= 1 < 3' - '@0xsequence/provider@1.10.15': - resolution: {integrity: sha512-oPntN3xWvwEnPuZ4LoxWL50v7FLhJa8guOP27FFltm4sjxydYCZ37griBR093YW5NKtWO8mtmnnnTZChJS8Euw==} + '@algolia/autocomplete-preset-algolia@1.17.6': + resolution: {integrity: sha512-Cvg5JENdSCMuClwhJ1ON1/jSuojaYMiUW2KePm18IkdCzPJj/NXojaOxw58RFtQFpJgfVW8h2E8mEoDtLlMdeA==} peerDependencies: - ethers: '>=5.5 < 6' + '@algolia/client-search': '>= 4.9.1 < 6' + algoliasearch: '>= 4.9.1 < 6' - '@0xsequence/relayer@1.10.15': - resolution: {integrity: sha512-QpNAzRjqCl9xJdXzErQA0kmv2jzEXPfVlPwutbgmrCEIj+rHdw3M+kiG0MWBnOqxoSEA98oJnxXmpBL5mkCA6g==} + '@algolia/autocomplete-shared@1.17.6': + resolution: {integrity: sha512-aq/3V9E00Tw2GC/PqgyPGXtqJUlVc17v4cn1EUhSc+O/4zd04Uwb3UmPm8KDaYQQOrkt1lwvCj2vG2wRE5IKhw==} peerDependencies: - ethers: '>=5.5 < 6' + '@algolia/client-search': '>= 4.9.1 < 6' + algoliasearch: '>= 4.9.1 < 6' - '@0xsequence/relayer@2.3.43': - resolution: {integrity: sha512-2Rs1e6LA9nLRGAlQEcaCFscEvRNhp9MkryXyqarwbrojCg0tYk0WmQcicyjHUOqiKAHhjTn+MepuwnFslKMPqQ==} + '@algolia/autocomplete-shared@1.9.3': + resolution: {integrity: sha512-Wnm9E4Ye6Rl6sTTqjoymD+l8DjSTHsHboVRYrKgEt8Q7UHm9nYbqhN/i0fhUYA3OAEH7WA8x3jfpnmJm3rKvaQ==} peerDependencies: - ethers: '>=6' + '@algolia/client-search': '>= 4.9.1 < 6' + algoliasearch: '>= 4.9.1 < 6' - '@0xsequence/replacer@1.10.15': - resolution: {integrity: sha512-ZV9cl/oDqCZf0cJUclGqTWY8iGuvGrXzUBT2w1AvneuQWjqYWIEzvXRBnscHVEtTEdOIV9sqBaC0MiK0TedC8Q==} - peerDependencies: - ethers: '>=5.5' + '@algolia/client-abtesting@5.12.0': + resolution: {integrity: sha512-hx4eVydkm3yrFCFxmcBtSzI/ykt0cZ6sDWch+v3JTgKpD2WtosMJU3Upv1AjQ4B6COSHCOWEX3vfFxW6OoH6aA==} + engines: {node: '>= 14.0.0'} + + '@algolia/client-analytics@5.12.0': + resolution: {integrity: sha512-EpTsSv6IW8maCfXCDIptgT7+mQJj7pImEkcNUnxR8yUKAHzTogTXv9yGm2WXOZFVuwstd2i0sImhQ1Vz8RH/hA==} + engines: {node: '>= 14.0.0'} - '@0xsequence/sessions@1.10.15': - resolution: {integrity: sha512-Zack16p3p92sO3ZFfZFz9Fa9Nlkxkt3ew48xnsnN3P3XCJFLX+MM7hoNOpkS3yQFVEb5QDhYrrAfE019U5hgww==} + '@algolia/client-common@5.12.0': + resolution: {integrity: sha512-od3WmO8qxyfNhKc+K3D17tvun3IMs/xMNmxCG9MiElAkYVbPPTRUYMkRneCpmJyQI0hNx2/EA4kZgzVfQjO86Q==} + engines: {node: '>= 14.0.0'} - '@0xsequence/signhub@1.10.15': - resolution: {integrity: sha512-9yZWb8d2aXoWOQp0XC81hkS+hLWxO/pZIyCRtNVdif0/SPA86v6e96xPmuj45KONYgiH33ROVDpeJEKhOEo0jg==} + '@algolia/client-insights@5.12.0': + resolution: {integrity: sha512-8alajmsYUd+7vfX5lpRNdxqv3Xx9clIHLUItyQK0Z6gwGMbVEFe6YYhgDtwslMAP0y6b0WeJEIZJMLgT7VYpRw==} + engines: {node: '>= 14.0.0'} - '@0xsequence/signhub@2.3.43': - resolution: {integrity: sha512-vG4fFupdOoXo9u1Q9eKvvcVSIx3hb2viNnblj5LudYUTxwLS/EvmKcvMYnC2bLkjP5rF/yqi7uY5d8v19FIw3Q==} - peerDependencies: - ethers: '>=6' + '@algolia/client-personalization@5.12.0': + resolution: {integrity: sha512-bUV9HtfkTBgpoVhxFrMkmVPG03ZN1Rtn51kiaEtukucdk3ggjR9Qu1YUfRSU2lFgxr9qJc8lTxwfvhjCeJRcqw==} + engines: {node: '>= 14.0.0'} - '@0xsequence/tee-verifier@0.1.2': - resolution: {integrity: sha512-7sKr8/T4newknx6LAukjlRI3siGiGhBnZohz2Z3jX0zb0EBQdKUq0L//A7CPSckHFPxTg/QvQU2v8e9x9GfkDw==} + '@algolia/client-query-suggestions@5.12.0': + resolution: {integrity: sha512-Q5CszzGWfxbIDs9DJ/QJsL7bP6h+lJMg27KxieEnI9KGCu0Jt5iFA3GkREkgRZxRdzlHbZKkrIzhtHVbSHw/rg==} + engines: {node: '>= 14.0.0'} - '@0xsequence/utils@1.10.15': - resolution: {integrity: sha512-LIrQS5J+3MOER+i7ajX7fiT6ga3QoDf8wsi5KY/2eFZS39sbCXGzg1ORxjtee++c/S/h4nuRYX1IRuseGYJWPw==} - peerDependencies: - ethers: '>=5.5 < 6' + '@algolia/client-search@5.12.0': + resolution: {integrity: sha512-R3qzEytgVLHOGNri+bpta6NtTt7YtkvUe/QBcAmMDjW4Jk1P0eBYIPfvnzIPbINRsLxIq9fZs9uAYBgsrts4Zg==} + engines: {node: '>= 14.0.0'} - '@0xsequence/utils@2.3.43': - resolution: {integrity: sha512-b5+8kNY1sEUU6yICOEoMZIoM4PNzgxIObKdOlk22d8SGb//VB7k9/gpG+u4LYVrA4t3LHlSuzzt62MEQ3mFMYA==} - peerDependencies: - ethers: '>=6' + '@algolia/ingestion@1.12.0': + resolution: {integrity: sha512-zpHo6qhR22tL8FsdSI4DvEraPDi/019HmMrCFB/TUX98yzh5ooAU7sNW0qPL1I7+S++VbBmNzJOEU9VI8tEC8A==} + engines: {node: '>= 14.0.0'} - '@0xsequence/wallet-contracts@1.10.0': - resolution: {integrity: sha512-NfPBJkp6/ApjVuTqQMgJvpN5lWyNc9bHm9ZITEi3X3nREf5126RLEXCyThChapkmcglHnQn+ndA8j6bfcpFEAg==} + '@algolia/monitoring@1.12.0': + resolution: {integrity: sha512-i2AJZED/zf4uhxezAJUhMKoL5QoepCBp2ynOYol0N76+TSoohaMADdPnWCqOULF4RzOwrG8wWynAwBlXsAI1RQ==} + engines: {node: '>= 14.0.0'} - '@0xsequence/wallet-contracts@2.0.0': - resolution: {integrity: sha512-PbKedYnBxgS7Qb5ca/xHUt++TmKK3yKIpVR1fX7HtAJiYOMSoZX4pVIFylUr6N7uBNpsPurFWCx7jTK+hBZnNA==} + '@algolia/recommend@5.12.0': + resolution: {integrity: sha512-0jmZyKvYnB/Bj5c7WKsKedOUjnr0UtXm0LVFUdQrxXfqOqvWv9n6Vpr65UjdYG4Q49kRQxhlwtal9WJYrYymXg==} + engines: {node: '>= 14.0.0'} - '@0xsequence/wallet-contracts@3.0.1': - resolution: {integrity: sha512-ZvZdXPE1KOYVjl9J6UdN/eBqEmuYHvlO4EUxDxG7VqCgrSiVP9S8k+mEN4aUMzOiYGwKcYY/HIkD211mvxseZQ==} + '@algolia/requester-browser-xhr@5.12.0': + resolution: {integrity: sha512-KxwleraFuVoEGCoeW6Y1RAEbgBMS7SavqeyzWdtkJc6mXeCOJXn1iZitb8Tyn2FcpMNUKlSm0adrUTt7G47+Ow==} + engines: {node: '>= 14.0.0'} - '@0xsequence/wallet@1.10.15': - resolution: {integrity: sha512-UhaIaiK3IF+bv1flg/N1yuGPZXos/orJlwAd9GbPDHOIBqkBsniyraDcO+xwBKWMBHhQL6NqfSDI9j/Zxv7ocg==} - peerDependencies: - ethers: '>=5.5 < 6' + '@algolia/requester-fetch@5.12.0': + resolution: {integrity: sha512-FuDZXUGU1pAg2HCnrt8+q1VGHKChV/LhvjvZlLOT7e56GJie6p+EuLu4/hMKPOVuQQ8XXtrTHKIU3Lw+7O5/bQ==} + engines: {node: '>= 14.0.0'} - '@0xsequence/wallet@2.3.43': - resolution: {integrity: sha512-zbS7p6SdZRaVU6nEVD72y6TOZlCny3s3JYx/pAn0gUxSKOuioidG+iO/pZ6Z8vmKAEAFyIUXWdcbefk+wi3ocw==} - peerDependencies: - ethers: '>=6' + '@algolia/requester-node-http@5.12.0': + resolution: {integrity: sha512-ncDDY7CxZhMs6LIoPl+vHFQceIBhYPY5EfuGF1V7beO0U38xfsCYEyutEFB2kRzf4D9Gqppn3iWX71sNtrKcuw==} + engines: {node: '>= 14.0.0'} - '@adraffy/ens-normalize@1.10.1': - resolution: {integrity: sha512-96Z2IP3mYmF1Xg2cDm8f1gWGf/HUVedQ3FMifV4kG/PQ4yEP51xDtRAEfhVNt5f/uzpNkZHwWQuUcu6D6K+Ekw==} + '@ampproject/remapping@2.2.1': + resolution: {integrity: sha512-lFMjJTrFL3j7L9yBxwYfCq2k6qqwHyzuUl/XBnif78PWTJYyL/dfowQHWE3sp6U6ZzqWiiIZnpTMO96zhkjwtg==} + engines: {node: '>=6.0.0'} - '@adraffy/ens-normalize@1.11.1': - resolution: {integrity: sha512-nhCBV3quEgesuf7c7KYfperqSS14T8bYuvJ8PcLJp6znkZpFc0AuW4qBtr8eKVyPPe/8RSr7sglCWPU5eaxwKQ==} + '@ampproject/remapping@2.3.0': + resolution: {integrity: sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==} + engines: {node: '>=6.0.0'} - '@aws-crypto/crc32@5.2.0': - resolution: {integrity: sha512-nLbCWqQNgUiwwtFsen1AdzAtvuLRsQS8rYgMuxCrdKf9kOssamGLuPwyTY9wyYblNr9+1XM8v6zoDTPPSIeANg==} - engines: {node: '>=16.0.0'} + '@andrewbranch/untar.js@1.0.3': + resolution: {integrity: sha512-Jh15/qVmrLGhkKJBdXlK1+9tY4lZruYjsgkDFj08ZmDiWVBLJcqkok7Z0/R0In+i1rScBpJlSvrTS2Lm41Pbnw==} + + '@antfu/install-pkg@0.1.1': + resolution: {integrity: sha512-LyB/8+bSfa0DFGC06zpCEfs89/XoWZwws5ygEa5D+Xsm3OfI+aXQ86VgVG7Acyef+rSZ5HE7J8rrxzrQeM3PjQ==} + + '@antfu/utils@0.7.7': + resolution: {integrity: sha512-gFPqTG7otEJ8uP6wrhDv6mqwGWYZKNvAcCq6u9hOj0c+IKCEsY4L1oC9trPq2SaWIzAfHvqfBDxF591JkMf+kg==} + + '@arethetypeswrong/cli@0.16.4': + resolution: {integrity: sha512-qMmdVlJon5FtA+ahn0c1oAVNxiq4xW5lqFiTZ21XHIeVwAVIQ+uRz4UEivqRMsjVV1grzRgJSKqaOrq1MvlVyQ==} + engines: {node: '>=18'} + hasBin: true + + '@arethetypeswrong/core@0.16.4': + resolution: {integrity: sha512-RI3HXgSuKTfcBf1hSEg1P9/cOvmI0flsMm6/QL3L3wju4AlHDqd55JFPfXs4pzgEAgy5L9pul4/HPPz99x2GvA==} + engines: {node: '>=18'} '@aws-crypto/sha256-browser@5.2.0': resolution: {integrity: sha512-AXfN/lGotSQwu6HNcEsIASo7kWXZ5HYWvfOmSNKDsEqC4OashTp8alTmaz+F7TC2L083SFv5RdB+qU3Vs1kZqw==} - '@aws-crypto/sha256-js@1.2.2': - resolution: {integrity: sha512-Nr1QJIbW/afYYGzYvrF70LtaHrIRtd4TNAglX8BvlfxJLZ45SAmueIKYl5tWoNBPzp65ymXGFK0Bb1vZUpuc9g==} - '@aws-crypto/sha256-js@5.2.0': resolution: {integrity: sha512-FFQQyu7edu4ufvIZ+OadFpHHOt+eSTBaYaki44c+akjg7qZg9oOQeLlk77F6tSYqjDAFClrHJk9tMf0HdVyOvA==} engines: {node: '>=16.0.0'} @@ -1495,182 +928,210 @@ packages: '@aws-crypto/supports-web-crypto@5.2.0': resolution: {integrity: sha512-iAvUotm021kM33eCdNfwIN//F77/IADDSs58i+MDaOqFrVjZo9bAal0NK7HurRuWLLpF1iLX7gbWrjHjeo+YFg==} - '@aws-crypto/util@1.2.2': - resolution: {integrity: sha512-H8PjG5WJ4wz0UXAFXeJjWCW1vkvIJ3qUUD+rGRwJ2/hj+xT58Qle2MTql/2MGzkU+1JLAFuR6aJpLAjHwhmwwg==} - '@aws-crypto/util@5.2.0': resolution: {integrity: sha512-4RkU9EsI6ZpBve5fseQlGNUWKMa1RLPQ1dnjnQoe07ldfIzcsGb5hC5W0Dm7u423KWzawlrpbjXBrXCEv9zazQ==} - '@aws-sdk/client-cognito-identity-provider@3.1037.0': - resolution: {integrity: sha512-w0HuaMNtzcj6bErBX8/TVGbOz0a8JNCzPHLMq2u/ll4uuxl9Xut0njuy7vyY0/pYCuNE+no4uq+yHwn8U3ptgw==} - engines: {node: '>=20.0.0'} - - '@aws-sdk/client-lambda@3.1037.0': - resolution: {integrity: sha512-QGlFTYge89OcrCJXO2fMkqbYrASOd5Ut3V58EYcuajGONIKOxxP6UYwrZE5vDMebNJi2mPLesDKaM7aH7oqcrA==} - engines: {node: '>=20.0.0'} - - '@aws-sdk/core@3.974.5': - resolution: {integrity: sha512-lMPlYlYfQdNZhlkJgnkmESwrY+hNh3PljmZ+37oAqLNdJ6rnILAwFSyc6B3bJeDOtMORNnMQIej0aTRuOlDyhQ==} - engines: {node: '>=20.0.0'} - - '@aws-sdk/credential-provider-env@3.972.31': - resolution: {integrity: sha512-X/yGB73LmDW/6MdDJGCDzZBUXnM3ys4vs9l+5ZTJmiEswDdP1OjeoAFlFjVGS9o4KB2wZWQ9KOfdVNSSK6Ep3w==} - engines: {node: '>=20.0.0'} + '@aws-sdk/client-cognito-identity-provider@3.958.0': + resolution: {integrity: sha512-EmgRcPfRQ6YWekZRI8Khg/lhu+/mmfplxNIJ4rGrFxUvw7yrTIQaynIiQ0/H30MACQHepnC0YXoIfwnr1Ucxtw==} + engines: {node: '>=18.0.0'} - '@aws-sdk/credential-provider-http@3.972.33': - resolution: {integrity: sha512-c0ZF+lwoWVvX5iCaGKL5T/4DnIw88CGqxA0BcBs3U86mIp5EZYPVg+KSPkMXOyokmADvNewiMUfSG2uFwjRp0g==} - engines: {node: '>=20.0.0'} + '@aws-sdk/client-sso@3.958.0': + resolution: {integrity: sha512-6qNCIeaMzKzfqasy2nNRuYnMuaMebCcCPP4J2CVGkA8QYMbIVKPlkn9bpB20Vxe6H/r3jtCCLQaOJjVTx/6dXg==} + engines: {node: '>=18.0.0'} - '@aws-sdk/credential-provider-ini@3.972.35': - resolution: {integrity: sha512-jsU4u/cRkKFLKQS0k918FQ27fzXLG5ENiLWQMYE6581zLeI2hWh04ptlrvZMB3wJT/5d+vSzJk74X1CMFr4y8Q==} - engines: {node: '>=20.0.0'} + '@aws-sdk/core@3.957.0': + resolution: {integrity: sha512-DrZgDnF1lQZv75a52nFWs6MExihJF2GZB6ETZRqr6jMwhrk2kbJPUtvgbifwcL7AYmVqHQDJBrR/MqkwwFCpiw==} + engines: {node: '>=18.0.0'} - '@aws-sdk/credential-provider-login@3.972.35': - resolution: {integrity: sha512-5oa3j0cA50jPqgNhZ9XdJVopuzUf1klRb28/2MfLYWWiPi9DRVvbrBWT+DidbHTT36520VuXZJahQwR+YgSjrg==} - engines: {node: '>=20.0.0'} + '@aws-sdk/credential-provider-env@3.957.0': + resolution: {integrity: sha512-475mkhGaWCr+Z52fOOVb/q2VHuNvqEDixlYIkeaO6xJ6t9qR0wpLt4hOQaR6zR1wfZV0SlE7d8RErdYq/PByog==} + engines: {node: '>=18.0.0'} - '@aws-sdk/credential-provider-node@3.972.36': - resolution: {integrity: sha512-4nT2T8Z7vH8KE9EdjEsuIlHpZSlcaK2PrKbQBjuUGU46BCCzF3WvP0u0Uiosni3Ykmmn4rWLVawoOCLotUtCbg==} - engines: {node: '>=20.0.0'} + '@aws-sdk/credential-provider-http@3.957.0': + resolution: {integrity: sha512-8dS55QHRxXgJlHkEYaCGZIhieCs9NU1HU1BcqQ4RfUdSsfRdxxktqUKgCnBnOOn0oD3PPA8cQOCAVgIyRb3Rfw==} + engines: {node: '>=18.0.0'} - '@aws-sdk/credential-provider-process@3.972.31': - resolution: {integrity: sha512-eKeT4MXumpBJsrDLCYcSzIkFPVTFn/es7It2oogp2OhU/ic7P/+xzFpQx9ZhwtXS57Mc5S42BPWi7lHmvs/nYg==} - engines: {node: '>=20.0.0'} + '@aws-sdk/credential-provider-ini@3.958.0': + resolution: {integrity: sha512-u7twvZa1/6GWmPBZs6DbjlegCoNzNjBsMS/6fvh5quByYrcJr/uLd8YEr7S3UIq4kR/gSnHqcae7y2nL2bqZdg==} + engines: {node: '>=18.0.0'} - '@aws-sdk/credential-provider-sso@3.972.35': - resolution: {integrity: sha512-bCuBdfnj0KGDMdLp6utMTLiJcFN2ek9EgZinxQZZSc3FxjJ/HSqeqab2cjbnoNfy8RM6suDCsRkmVY1izp9I+A==} - engines: {node: '>=20.0.0'} + '@aws-sdk/credential-provider-login@3.958.0': + resolution: {integrity: sha512-sDwtDnBSszUIbzbOORGh5gmXGl9aK25+BHb4gb1aVlqB+nNL2+IUEJA62+CE55lXSH8qXF90paivjK8tOHTwPA==} + engines: {node: '>=18.0.0'} - '@aws-sdk/credential-provider-web-identity@3.972.35': - resolution: {integrity: sha512-swW6Bwvl8lanyEMtZOWE/oR6yqcRQH4HTQZUVsnDVgoXvRjRywpYpLv2BWwjUFyjPrqsdX6FeTkf4tMSe/qFTQ==} - engines: {node: '>=20.0.0'} + '@aws-sdk/credential-provider-node@3.958.0': + resolution: {integrity: sha512-vdoZbNG2dt66I7EpN3fKCzi6fp9xjIiwEA/vVVgqO4wXCGw8rKPIdDUus4e13VvTr330uQs2W0UNg/7AgtquEQ==} + engines: {node: '>=18.0.0'} - '@aws-sdk/middleware-host-header@3.972.10': - resolution: {integrity: sha512-IJSsIMeVQ8MMCPbuh1AbltkFhLBLXn7aejzfX5YKT/VLDHn++Dcz8886tXckE+wQssyPUhaXrJhdakO2VilRhg==} - engines: {node: '>=20.0.0'} + '@aws-sdk/credential-provider-process@3.957.0': + resolution: {integrity: sha512-/KIz9kadwbeLy6SKvT79W81Y+hb/8LMDyeloA2zhouE28hmne+hLn0wNCQXAAupFFlYOAtZR2NTBs7HBAReJlg==} + engines: {node: '>=18.0.0'} - '@aws-sdk/middleware-logger@3.972.10': - resolution: {integrity: sha512-OOuGvvz1Dm20SjZo5oEBePFqxt5nf8AwkNDSyUHvD9/bfNASmstcYxFAHUowy4n6Io7mWUZ04JURZwSBvyQanQ==} - engines: {node: '>=20.0.0'} + '@aws-sdk/credential-provider-sso@3.958.0': + resolution: {integrity: sha512-CBYHJ5ufp8HC4q+o7IJejCUctJXWaksgpmoFpXerbjAso7/Fg7LLUu9inXVOxlHKLlvYekDXjIUBXDJS2WYdgg==} + engines: {node: '>=18.0.0'} - '@aws-sdk/middleware-recursion-detection@3.972.11': - resolution: {integrity: sha512-+zz6f79Kj9V5qFK2P+D8Ehjnw4AhphAlCAsPjUqEcInA9umtSSKMrHbSagEeOIsDNuvVrH98bjRHcyQukTrhaQ==} - engines: {node: '>=20.0.0'} + '@aws-sdk/credential-provider-web-identity@3.958.0': + resolution: {integrity: sha512-dgnvwjMq5Y66WozzUzxNkCFap+umHUtqMMKlr8z/vl9NYMLem/WUbWNpFFOVFWquXikc+ewtpBMR4KEDXfZ+KA==} + engines: {node: '>=18.0.0'} - '@aws-sdk/middleware-sdk-s3@3.972.34': - resolution: {integrity: sha512-/UL96JKjsjdodcRRMKl99tLQvK6Oi9ptLC9iU1yiTF/ruaDX0mtBBtnLNZDxIZRJOCVOtB49ed1YaTadqygk8Q==} - engines: {node: '>=20.0.0'} + '@aws-sdk/middleware-host-header@3.957.0': + resolution: {integrity: sha512-BBgKawVyfQZglEkNTuBBdC3azlyqNXsvvN4jPkWAiNYcY0x1BasaJFl+7u/HisfULstryweJq/dAvIZIxzlZaA==} + engines: {node: '>=18.0.0'} - '@aws-sdk/middleware-user-agent@3.972.35': - resolution: {integrity: sha512-hOFWNOjVmOocpRlrU04nYxjMOeoe0Obu5AXEuhB8zblMCPl3cG1hdluQCZERRKFyhMQjwZnDbhSHjoMUjetFGw==} - engines: {node: '>=20.0.0'} + '@aws-sdk/middleware-logger@3.957.0': + resolution: {integrity: sha512-w1qfKrSKHf9b5a8O76yQ1t69u6NWuBjr5kBX+jRWFx/5mu6RLpqERXRpVJxfosbep7k3B+DSB5tZMZ82GKcJtQ==} + engines: {node: '>=18.0.0'} - '@aws-sdk/nested-clients@3.997.3': - resolution: {integrity: sha512-SivE6GP228IVgfsrr2c/vqTg95X0Qj39Yw4uIrcddpkUzIltNMoNOR62leHOLhODfjv9K8X2mPTwS69A5kT0nQ==} - engines: {node: '>=20.0.0'} + '@aws-sdk/middleware-recursion-detection@3.957.0': + resolution: {integrity: sha512-D2H/WoxhAZNYX+IjkKTdOhOkWQaK0jjJrDBj56hKjU5c9ltQiaX/1PqJ4dfjHntEshJfu0w+E6XJ+/6A6ILBBA==} + engines: {node: '>=18.0.0'} - '@aws-sdk/region-config-resolver@3.972.13': - resolution: {integrity: sha512-CvJ2ZIjK/jVD/lbOpowBVElJyC1YxLTIJ13yM0AEo0t2v7swOzGjSA6lJGH+DwZXQhcjUjoYwc8bVYCX5MDr1A==} - engines: {node: '>=20.0.0'} + '@aws-sdk/middleware-user-agent@3.957.0': + resolution: {integrity: sha512-50vcHu96XakQnIvlKJ1UoltrFODjsq2KvtTgHiPFteUS884lQnK5VC/8xd1Msz/1ONpLMzdCVproCQqhDTtMPQ==} + engines: {node: '>=18.0.0'} - '@aws-sdk/signature-v4-multi-region@3.996.22': - resolution: {integrity: sha512-/rXhMXteD+BqhFd0nYprAgcZ/KtU+963uftPqd3tiFcFfooHZINXUGtOmo2SQjRVauCTNqIEzkwuSETdZFqTTA==} - engines: {node: '>=20.0.0'} + '@aws-sdk/nested-clients@3.958.0': + resolution: {integrity: sha512-/KuCcS8b5TpQXkYOrPLYytrgxBhv81+5pChkOlhegbeHttjM69pyUpQVJqyfDM/A7wPLnDrzCAnk4zaAOkY0Nw==} + engines: {node: '>=18.0.0'} - '@aws-sdk/token-providers@3.1036.0': - resolution: {integrity: sha512-aNSJ6jjDYayxN9ZA1JpycVScX93Lx03kKZ1EXt3DGOTahcWVLJj3oLAlop0xKP+vP2Ga2t49p1tEaMkTbCCaZA==} - engines: {node: '>=20.0.0'} + '@aws-sdk/region-config-resolver@3.957.0': + resolution: {integrity: sha512-V8iY3blh8l2iaOqXWW88HbkY5jDoWjH56jonprG/cpyqqCnprvpMUZWPWYJoI8rHRf2bqzZeql1slxG6EnKI7A==} + engines: {node: '>=18.0.0'} - '@aws-sdk/types@3.973.8': - resolution: {integrity: sha512-gjlAdtHMbtR9X5iIhVUvbVcy55KnznpC6bkDUWW9z915bi0ckdUr5cjf16Kp6xq0bP5HBD2xzgbL9F9Quv5vUw==} - engines: {node: '>=20.0.0'} + '@aws-sdk/token-providers@3.958.0': + resolution: {integrity: sha512-UCj7lQXODduD1myNJQkV+LYcGYJ9iiMggR8ow8Hva1g3A/Na5imNXzz6O67k7DAee0TYpy+gkNw+SizC6min8Q==} + engines: {node: '>=18.0.0'} - '@aws-sdk/util-arn-parser@3.972.3': - resolution: {integrity: sha512-HzSD8PMFrvgi2Kserxuff5VitNq2sgf3w9qxmskKDiDTThWfVteJxuCS9JXiPIPtmCrp+7N9asfIaVhBFORllA==} - engines: {node: '>=20.0.0'} + '@aws-sdk/types@3.957.0': + resolution: {integrity: sha512-wzWC2Nrt859ABk6UCAVY/WYEbAd7FjkdrQL6m24+tfmWYDNRByTJ9uOgU/kw9zqLCAwb//CPvrJdhqjTznWXAg==} + engines: {node: '>=18.0.0'} - '@aws-sdk/util-endpoints@3.996.8': - resolution: {integrity: sha512-oOZHcRDihk5iEe5V25NVWg45b3qEA8OpHWVdU/XQh8Zj4heVPAJqWvMphQnU7LkufmUo10EpvFPZuQMiFLJK3g==} - engines: {node: '>=20.0.0'} + '@aws-sdk/util-endpoints@3.957.0': + resolution: {integrity: sha512-xwF9K24mZSxcxKS3UKQFeX/dPYkEps9wF1b+MGON7EvnbcucrJGyQyK1v1xFPn1aqXkBTFi+SZaMRx5E5YCVFw==} + engines: {node: '>=18.0.0'} - '@aws-sdk/util-locate-window@3.965.5': - resolution: {integrity: sha512-WhlJNNINQB+9qtLtZJcpQdgZw3SCDCpXdUJP7cToGwHbCWCnRckGlc6Bx/OhWwIYFNAn+FIydY8SZ0QmVu3xTQ==} - engines: {node: '>=20.0.0'} + '@aws-sdk/util-locate-window@3.957.0': + resolution: {integrity: sha512-nhmgKHnNV9K+i9daumaIz8JTLsIIML9PE/HUks5liyrjUzenjW/aHoc7WJ9/Td/gPZtayxFnXQSJRb/fDlBuJw==} + engines: {node: '>=18.0.0'} - '@aws-sdk/util-user-agent-browser@3.972.10': - resolution: {integrity: sha512-FAzqXvfEssGdSIz8ejatan0bOdx1qefBWKF/gWmVBXIP1HkS7v/wjjaqrAGGKvyihrXTXW00/2/1nTJtxpXz7g==} + '@aws-sdk/util-user-agent-browser@3.957.0': + resolution: {integrity: sha512-exueuwxef0lUJRnGaVkNSC674eAiWU07ORhxBnevFFZEKisln+09Qrtw823iyv5I1N8T+wKfh95xvtWQrNKNQw==} - '@aws-sdk/util-user-agent-node@3.973.21': - resolution: {integrity: sha512-Av4UHTcAWgdvbN0IP9pbtf4Qa1+6LtJqQdZWj5pLn5J67w0pnJJAZZ+7JPPcj2KN3378zD2JDM9DwJKEyvyMTQ==} - engines: {node: '>=20.0.0'} + '@aws-sdk/util-user-agent-node@3.957.0': + resolution: {integrity: sha512-ycbYCwqXk4gJGp0Oxkzf2KBeeGBdTxz559D41NJP8FlzSej1Gh7Rk40Zo6AyTfsNWkrl/kVi1t937OIzC5t+9Q==} + engines: {node: '>=18.0.0'} peerDependencies: aws-crt: '>=1.0.0' peerDependenciesMeta: aws-crt: optional: true - '@aws-sdk/util-utf8-browser@3.259.0': - resolution: {integrity: sha512-UvFa/vR+e19XookZF8RzFZBrw2EUkQWxiBW0yYQAhvk3C+QVGl0H3ouca8LDBlBfQKXwmW3huo/59H8rwb1wJw==} - - '@aws-sdk/xml-builder@3.972.19': - resolution: {integrity: sha512-Cw8IOMdBUEIl8ZlhRC3Dc/E64D5B5/8JhV6vhPLiPfJwcRC84S6F8aBOIi/N4vR9ZyA4I5Cc0Ateb/9EHaJXeQ==} - engines: {node: '>=20.0.0'} + '@aws-sdk/xml-builder@3.957.0': + resolution: {integrity: sha512-Ai5iiQqS8kJ5PjzMhWcLKN0G2yasAkvpnPlq2EnqlIMdB48HsizElt62qcktdxp4neRMyGkFq4NzgmDbXnhRiA==} + engines: {node: '>=18.0.0'} - '@aws/lambda-invoke-store@0.2.4': - resolution: {integrity: sha512-iY8yvjE0y651BixKNPgmv1WrQc+GZ142sb0z4gYnChDDY2YqI4P/jsSopBWrKfAt7LOJAkOXt7rC/hms+WclQQ==} + '@aws/lambda-invoke-store@0.2.2': + resolution: {integrity: sha512-C0NBLsIqzDIae8HFw9YIrIBsbc0xTiOtt7fAukGPnqQ/+zZNaq+4jhuccltK0QuWHBnNm/a6kLIRA6GFiM10eg==} engines: {node: '>=18.0.0'} + '@babel/code-frame@7.24.2': + resolution: {integrity: sha512-y5+tLQyV8pg3fsiln67BVLD1P13Eg4lh5RW9mF0zUuvLrv9uIQ4MCL+CRT+FTsBlBjcIan6PGsLcBN0m3ClUyQ==} + engines: {node: '>=6.9.0'} + '@babel/code-frame@7.27.1': resolution: {integrity: sha512-cjQ7ZlQ0Mv3b47hABuTevyTuYN4i+loJKGeV9flcCgIK37cCXRh+L1bd3iBHlynerhQ7BhCkn2BPbQUL+rGqFg==} engines: {node: '>=6.9.0'} - '@babel/code-frame@7.29.0': - resolution: {integrity: sha512-9NhCeYjq9+3uxgdtp20LSiJXJvN0FeCtNGpJxuMFZ1Kv3cWUNb6DOhJwUvcVCzKGR66cw4njwM6hrJLqgOwbcw==} + '@babel/compat-data@7.24.4': + resolution: {integrity: sha512-vg8Gih2MLK+kOkHJp4gBEIkyaIi00jgWot2D9QOmmfLC8jINSOzmCLta6Bvz/JSBCqnegV0L80jhxkol5GWNfQ==} engines: {node: '>=6.9.0'} '@babel/compat-data@7.28.5': resolution: {integrity: sha512-6uFXyCayocRbqhZOB+6XcuZbkMNimwfVGFji8CTZnCzOHVGvDqzvitu1re2AU5LROliz7eQPhB8CpAMvnx9EjA==} engines: {node: '>=6.9.0'} - '@babel/compat-data@7.29.0': - resolution: {integrity: sha512-T1NCJqT/j9+cn8fvkt7jtwbLBfLC/1y1c7NtCeXFRgzGTsafi68MRv8yzkYSapBnFA6L3U2VSc02ciDzoAJhJg==} + '@babel/core@7.24.5': + resolution: {integrity: sha512-tVQRucExLQ02Boi4vdPp49svNGcfL2GhdTCT9aldhXgCJVAI21EtRfBettiuLUwce/7r6bFdgs6JFkcdTiFttA==} engines: {node: '>=6.9.0'} '@babel/core@7.28.5': resolution: {integrity: sha512-e7jT4DxYvIDLk1ZHmU/m/mB19rex9sv0c2ftBtjSBv+kVM/902eh0fINUzD7UwLLNR+jU585GxUJ8/EBfAM5fw==} engines: {node: '>=6.9.0'} - '@babel/core@7.29.0': - resolution: {integrity: sha512-CGOfOJqWjg2qW/Mb6zNsDm+u5vFQ8DxXfbM09z69p5Z6+mE1ikP2jUXw+j42Pf1XTYED2Rni5f95npYeuwMDQA==} + '@babel/generator@7.24.5': + resolution: {integrity: sha512-x32i4hEXvr+iI0NEoEfDKzlemF8AmtOP8CcrRaEcpzysWuoEb1KknpcvMsHKPONoKZiDuItklgWhB18xEhr9PA==} engines: {node: '>=6.9.0'} '@babel/generator@7.28.5': resolution: {integrity: sha512-3EwLFhZ38J4VyIP6WNtt2kUdW9dokXA9Cr4IVIFHuCpZ3H8/YFOl5JjZHisrn1fATPBmKKqXzDFvh9fUwHz6CQ==} engines: {node: '>=6.9.0'} - '@babel/generator@7.29.1': - resolution: {integrity: sha512-qsaF+9Qcm2Qv8SRIMMscAvG4O3lJ0F1GuMo5HR/Bp02LopNgnZBC/EkbevHFeGs4ls/oPz9v+Bsmzbkbe+0dUw==} + '@babel/helper-annotate-as-pure@7.22.5': + resolution: {integrity: sha512-LvBTxu8bQSQkcyKOU+a1btnNFQ1dMAd0R6PyW3arXes06F6QLWLIrd681bxRPIXlrMGR3XYnW9JyML7dP3qgxg==} + engines: {node: '>=6.9.0'} + + '@babel/helper-annotate-as-pure@7.27.3': + resolution: {integrity: sha512-fXSwMQqitTGeHLBC08Eq5yXz2m37E4pJX1qAU1+2cNedz/ifv/bVXft90VeSav5nFO61EcNgwr0aJxbyPaWBPg==} + engines: {node: '>=6.9.0'} + + '@babel/helper-compilation-targets@7.23.6': + resolution: {integrity: sha512-9JB548GZoQVmzrFgp8o7KxdgkTGm6xs9DW0o/Pim72UDjzr5ObUQ6ZzYPqA+g9OTS2bBQoctLJrky0RDCAWRgQ==} engines: {node: '>=6.9.0'} '@babel/helper-compilation-targets@7.27.2': resolution: {integrity: sha512-2+1thGUUWWjLTYTHZWK1n8Yga0ijBz1XAhUXcKy81rd5g6yh7hGqMp45v7cadSbEHc9G3OTv45SyneRN3ps4DQ==} engines: {node: '>=6.9.0'} - '@babel/helper-compilation-targets@7.28.6': - resolution: {integrity: sha512-JYtls3hqi15fcx5GaSNL7SCTJ2MNmjrkHXg4FSpOA/grxK8KwyZ5bubHsCq8FXCkua6xhuaaBit+3b7+VZRfcA==} + '@babel/helper-create-class-features-plugin@7.24.5': + resolution: {integrity: sha512-uRc4Cv8UQWnE4NXlYTIIdM7wfFkOqlFztcC/gVXDKohKoVB3OyonfelUBaJzSwpBntZ2KYGF/9S7asCHsXwW6g==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + + '@babel/helper-create-class-features-plugin@7.28.5': + resolution: {integrity: sha512-q3WC4JfdODypvxArsJQROfupPBq9+lMwjKq7C33GhbFYJsufD0yd/ziwD+hJucLeWsnFPWZjsU2DNFqBPE7jwQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + + '@babel/helper-environment-visitor@7.22.20': + resolution: {integrity: sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==} + engines: {node: '>=6.9.0'} + + '@babel/helper-function-name@7.23.0': + resolution: {integrity: sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==} engines: {node: '>=6.9.0'} '@babel/helper-globals@7.28.0': resolution: {integrity: sha512-+W6cISkXFa1jXsDEdYA8HeevQT/FULhxzR99pxphltZcVaugps53THCeiWA8SguxxpSp3gKPiuYfSWopkLQ4hw==} engines: {node: '>=6.9.0'} + '@babel/helper-hoist-variables@7.22.5': + resolution: {integrity: sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==} + engines: {node: '>=6.9.0'} + + '@babel/helper-member-expression-to-functions@7.24.5': + resolution: {integrity: sha512-4owRteeihKWKamtqg4JmWSsEZU445xpFRXPEwp44HbgbxdWlUV1b4Agg4lkA806Lil5XM/e+FJyS0vj5T6vmcA==} + engines: {node: '>=6.9.0'} + + '@babel/helper-member-expression-to-functions@7.28.5': + resolution: {integrity: sha512-cwM7SBRZcPCLgl8a7cY0soT1SptSzAlMH39vwiRpOQkJlh53r5hdHwLSCZpQdVLT39sZt+CRpNwYG4Y2v77atg==} + engines: {node: '>=6.9.0'} + + '@babel/helper-module-imports@7.24.3': + resolution: {integrity: sha512-viKb0F9f2s0BCS22QSF308z/+1YWKV/76mwt61NBzS5izMzDPwdq1pTrzf+Li3npBWX9KdQbkeCt1jSAM7lZqg==} + engines: {node: '>=6.9.0'} + '@babel/helper-module-imports@7.27.1': resolution: {integrity: sha512-0gSFWUPNXNopqtIPQvlD5WgXYI5GY2kP2cCvoT8kczjbfcfuIljTbcWrulD1CIPIX2gt1wghbDy08yE1p+/r3w==} engines: {node: '>=6.9.0'} - '@babel/helper-module-imports@7.28.6': - resolution: {integrity: sha512-l5XkZK7r7wa9LucGw9LwZyyCUscb4x37JWTPz7swwFE/0FMQAGpiWUZn8u9DzkSBWEcK25jmvubfpw2dnAMdbw==} + '@babel/helper-module-transforms@7.24.5': + resolution: {integrity: sha512-9GxeY8c2d2mdQUP1Dye0ks3VDyIMS98kt/llQ2nUId8IsWqTF0l1LkSX0/uP7l7MCDrzXS009Hyhe2gzTiGW8A==} engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 '@babel/helper-module-transforms@7.28.3': resolution: {integrity: sha512-gytXUbs8k2sXS9PnQptz5o0QnpLL51SwASIORY6XaBKF88nsOT0Zw9szLqlSGQDP/4TljBAD5y98p2U1fqkdsw==} @@ -1678,123 +1139,376 @@ packages: peerDependencies: '@babel/core': ^7.0.0 - '@babel/helper-module-transforms@7.28.6': - resolution: {integrity: sha512-67oXFAYr2cDLDVGLXTEABjdBJZ6drElUSI7WKp70NrpyISso3plG9SAGEF6y7zbha/wOzUByWWTJvEDVNIUGcA==} + '@babel/helper-optimise-call-expression@7.22.5': + resolution: {integrity: sha512-HBwaojN0xFRx4yIvpwGqxiV2tUfl7401jlok564NgB9EHS1y6QT17FmKWm4ztqjeVdXLuC4fSvHc5ePpQjoTbw==} + engines: {node: '>=6.9.0'} + + '@babel/helper-optimise-call-expression@7.27.1': + resolution: {integrity: sha512-URMGH08NzYFhubNSGJrpUEphGKQwMQYBySzat5cAByY1/YgIRkULnIy3tAMeszlL/so2HbeilYloUmSpd7GdVw==} + engines: {node: '>=6.9.0'} + + '@babel/helper-plugin-utils@7.24.5': + resolution: {integrity: sha512-xjNLDopRzW2o6ba0gKbkZq5YWEBaK3PCyTOY1K2P/O07LGMhMqlMXPxwN4S5/RhWuCobT8z0jrlKGlYmeR1OhQ==} + engines: {node: '>=6.9.0'} + + '@babel/helper-plugin-utils@7.27.1': + resolution: {integrity: sha512-1gn1Up5YXka3YYAHGKpbideQ5Yjf1tDa9qYcgysz+cNCXukyLl6DjPXhD3VRwSb8c0J9tA4b2+rHEZtc6R0tlw==} + engines: {node: '>=6.9.0'} + + '@babel/helper-replace-supers@7.24.1': + resolution: {integrity: sha512-QCR1UqC9BzG5vZl8BMicmZ28RuUBnHhAMddD8yHFHDRH9lLTZ9uUPehX8ctVPT8l0TKblJidqcgUUKGVrePleQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + + '@babel/helper-replace-supers@7.27.1': + resolution: {integrity: sha512-7EHz6qDZc8RYS5ElPoShMheWvEgERonFCs7IAonWLLUTXW59DP14bCZt89/GKyreYn8g3S83m21FelHKbeDCKA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 + '@babel/helper-simple-access@7.24.5': + resolution: {integrity: sha512-uH3Hmf5q5n7n8mz7arjUlDOCbttY/DW4DYhE6FUsjKJ/oYC1kQQUvwEQWxRwUpX9qQKRXeqLwWxrqilMrf32sQ==} + engines: {node: '>=6.9.0'} + + '@babel/helper-skip-transparent-expression-wrappers@7.27.1': + resolution: {integrity: sha512-Tub4ZKEXqbPjXgWLl2+3JpQAYBJ8+ikpQ2Ocj/q/r0LwE3UhENh7EUabyHjz2kCEsrRY83ew2DQdHluuiDQFzg==} + engines: {node: '>=6.9.0'} + + '@babel/helper-split-export-declaration@7.24.5': + resolution: {integrity: sha512-5CHncttXohrHk8GWOFCcCl4oRD9fKosWlIRgWm4ql9VYioKm52Mk2xsmoohvm7f3JoiLSM5ZgJuRaf5QZZYd3Q==} + engines: {node: '>=6.9.0'} + + '@babel/helper-string-parser@7.24.1': + resolution: {integrity: sha512-2ofRCjnnA9y+wk8b9IAREroeUP02KHp431N2mhKniy2yKIDKpbrHv9eXwm8cBeWQYcJmzv5qKCu65P47eCF7CQ==} + engines: {node: '>=6.9.0'} + + '@babel/helper-string-parser@7.25.9': + resolution: {integrity: sha512-4A/SCr/2KLd5jrtOMFzaKjVtAei3+2r/NChoBNoZ3EyP/+GlhoaEGoWOZUmFmoITP7zOJyHIMm+DYRd8o3PvHA==} + engines: {node: '>=6.9.0'} + '@babel/helper-string-parser@7.27.1': resolution: {integrity: sha512-qMlSxKbpRlAridDExk92nSobyDdpPijUq2DW6oDnUqd0iOGxmQjyqhMIihI9+zv4LPyZdRje2cavWPbCbWm3eA==} engines: {node: '>=6.9.0'} + '@babel/helper-validator-identifier@7.24.5': + resolution: {integrity: sha512-3q93SSKX2TWCG30M2G2kwaKeTYgEUp5Snjuj8qm729SObL6nbtUldAi37qbxkD5gg3xnBio+f9nqpSepGZMvxA==} + engines: {node: '>=6.9.0'} + + '@babel/helper-validator-identifier@7.25.9': + resolution: {integrity: sha512-Ed61U6XJc3CVRfkERJWDz4dJwKe7iLmmJsbOGu9wSloNSFttHV0I8g6UAgb7qnK5ly5bGLPd4oXZlxCdANBOWQ==} + engines: {node: '>=6.9.0'} + + '@babel/helper-validator-identifier@7.27.1': + resolution: {integrity: sha512-D2hP9eA+Sqx1kBZgzxZh0y1trbuU+JoDkiEwqhQ36nodYqJwyEIhPSdMNd7lOm/4io72luTPWH20Yda0xOuUow==} + engines: {node: '>=6.9.0'} + '@babel/helper-validator-identifier@7.28.5': resolution: {integrity: sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==} engines: {node: '>=6.9.0'} + '@babel/helper-validator-option@7.23.5': + resolution: {integrity: sha512-85ttAOMLsr53VgXkTbkx8oA6YTfT4q7/HzXSLEYmjcSTJPMPQtvq1BD79Byep5xMUYbGRzEpDsjUf3dyp54IKw==} + engines: {node: '>=6.9.0'} + '@babel/helper-validator-option@7.27.1': resolution: {integrity: sha512-YvjJow9FxbhFFKDSuFnVCe2WxXk1zWc22fFePVNEaWJEu8IrZVlda6N0uHwzZrUM1il7NC9Mlp4MaJYbYd9JSg==} engines: {node: '>=6.9.0'} + '@babel/helpers@7.24.5': + resolution: {integrity: sha512-CiQmBMMpMQHwM5m01YnrM6imUG1ebgYJ+fAIW4FZe6m4qHTPaRHti+R8cggAwkdz4oXhtO4/K9JWlh+8hIfR2Q==} + engines: {node: '>=6.9.0'} + '@babel/helpers@7.28.4': resolution: {integrity: sha512-HFN59MmQXGHVyYadKLVumYsA9dBFun/ldYxipEjzA4196jpLZd8UjEEBLkbEkvfYreDqJhZxYAWFPtrfhNpj4w==} engines: {node: '>=6.9.0'} - '@babel/helpers@7.29.2': - resolution: {integrity: sha512-HoGuUs4sCZNezVEKdVcwqmZN8GoHirLUcLaYVNBK2J0DadGtdcqgr3BCbvH8+XUo4NGjNl3VOtSjEKNzqfFgKw==} + '@babel/highlight@7.24.5': + resolution: {integrity: sha512-8lLmua6AVh/8SLJRRVD6V8p73Hir9w5mJrhE+IPpILG31KKlI9iz5zmBYKcWPS59qSfgP9RaSBQSHHE81WKuEw==} engines: {node: '>=6.9.0'} - '@babel/parser@7.28.5': - resolution: {integrity: sha512-KKBU1VGYR7ORr3At5HAtUQ+TV3SzRCXmA/8OdDZiLDBIZxVyzXuztPjfLd3BV1PRAQGCMWWSHYhL0F8d5uHBDQ==} + '@babel/parser@7.24.5': + resolution: {integrity: sha512-EOv5IK8arwh3LI47dz1b0tKUb/1uhHAnHJOrjgtQMIpu1uXd9mlFrJg9IUgGUgZ41Ch0K8REPTYpO7B76b4vJg==} + engines: {node: '>=6.0.0'} + hasBin: true + + '@babel/parser@7.26.2': + resolution: {integrity: sha512-DWMCZH9WA4Maitz2q21SRKHo9QXZxkDsbNZoVD62gusNtNBBqDg9i7uOhASfTfIGNzW+O+r7+jAlM8dwphcJKQ==} engines: {node: '>=6.0.0'} hasBin: true - '@babel/parser@7.29.2': - resolution: {integrity: sha512-4GgRzy/+fsBa72/RZVJmGKPmZu9Byn8o4MoLpmNe1m8ZfYnz5emHLQz3U4gLud6Zwl0RZIcgiLD7Uq7ySFuDLA==} + '@babel/parser@7.28.5': + resolution: {integrity: sha512-KKBU1VGYR7ORr3At5HAtUQ+TV3SzRCXmA/8OdDZiLDBIZxVyzXuztPjfLd3BV1PRAQGCMWWSHYhL0F8d5uHBDQ==} engines: {node: '>=6.0.0'} hasBin: true - '@babel/runtime-corejs3@7.28.4': - resolution: {integrity: sha512-h7iEYiW4HebClDEhtvFObtPmIvrd1SSfpI9EhOeKk4CtIK/ngBWFpuhCzhdmRKtg71ylcue+9I6dv54XYO1epQ==} + '@babel/plugin-syntax-jsx@7.24.1': + resolution: {integrity: sha512-2eCtxZXf+kbkMIsXS4poTvT4Yu5rXiRa+9xGVT56raghjmBTKMpFNc9R4IDiB4emao9eO22Ox7CxuJG7BgExqA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + + '@babel/plugin-syntax-jsx@7.27.1': + resolution: {integrity: sha512-y8YTNIeKoyhGd9O0Jiyzyyqk8gdjnumGTQPsz0xOZOQ2RmkVJeZ1vmmfIvFEKqucBG6axJGBZDE/7iI5suUI/w==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + + '@babel/plugin-syntax-typescript@7.27.1': + resolution: {integrity: sha512-xfYCBMxveHrRMnAWl1ZlPXOZjzkN82THFvLhQhFXFt81Z5HnN+EtUkZhv/zcKpmT3fzmWZB0ywiBrbC3vogbwQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + + '@babel/plugin-transform-modules-commonjs@7.24.1': + resolution: {integrity: sha512-szog8fFTUxBfw0b98gEWPaEqF42ZUD/T3bkynW/wtgx2p/XCP55WEsb+VosKceRSd6njipdZvNogqdtI4Q0chw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + + '@babel/plugin-transform-react-jsx-self@7.24.5': + resolution: {integrity: sha512-RtCJoUO2oYrYwFPtR1/jkoBEcFuI1ae9a9IMxeyAVa3a1Ap4AnxmyIKG2b2FaJKqkidw/0cxRbWN+HOs6ZWd1w==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + + '@babel/plugin-transform-react-jsx-source@7.24.1': + resolution: {integrity: sha512-1v202n7aUq4uXAieRTKcwPzNyphlCuqHHDcdSNc+vdhoTEZcFMh+L5yZuCmGaIO7bs1nJUNfHB89TZyoL48xNA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + + '@babel/plugin-transform-typescript@7.24.5': + resolution: {integrity: sha512-E0VWu/hk83BIFUWnsKZ4D81KXjN5L3MobvevOHErASk9IPwKHOkTgvqzvNo1yP/ePJWqqK2SpUR5z+KQbl6NVw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + + '@babel/plugin-transform-typescript@7.28.5': + resolution: {integrity: sha512-x2Qa+v/CuEoX7Dr31iAfr0IhInrVOWZU/2vJMJ00FOR/2nM0BcBEclpaf9sWCDc+v5e9dMrhSH8/atq/kX7+bA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + + '@babel/preset-typescript@7.24.1': + resolution: {integrity: sha512-1DBaMmRDpuYQBPWD8Pf/WEwCrtgRHxsZnP4mIy9G/X+hFfbI47Q2G4t1Paakld84+qsk2fSsUPMKg71jkoOOaQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + + '@babel/runtime@7.26.0': + resolution: {integrity: sha512-FDSOghenHTiToteC/QRlv2q3DhPZ/oOXTBoirfWNx1Cx3TMVcGWQtMMmQcSvb/JjpNeGzx8Pq/b4fKEJuWm1sw==} + engines: {node: '>=6.9.0'} + + '@babel/runtime@7.28.4': + resolution: {integrity: sha512-Q/N6JNWvIvPnLDvjlE1OUBLPQHH6l3CltCEsHIujp45zQUSSh8K+gHnaEX45yAT1nyngnINhvWtzN+Nb9D8RAQ==} engines: {node: '>=6.9.0'} - '@babel/runtime@7.29.2': - resolution: {integrity: sha512-JiDShH45zKHWyGe4ZNVRrCjBz8Nh9TMmZG1kh4QTK8hCBTWBi8Da+i7s1fJw7/lYpM4ccepSNfqzZ/QvABBi5g==} + '@babel/standalone@7.24.5': + resolution: {integrity: sha512-Sl8oN9bGfRlNUA2jzfzoHEZxFBDliBlwi5mPVCAWKSlBNkXXJOHpu7SDOqjF6mRoTa6GNX/1kAWG3Tr+YQ3N7A==} + engines: {node: '>=6.9.0'} + + '@babel/template@7.24.0': + resolution: {integrity: sha512-Bkf2q8lMB0AFpX0NFEqSbx1OkTHf0f+0j82mkw+ZpzBnkk7e9Ql0891vlfgi+kHwOk8tQjiQHpqh4LaSa0fKEA==} engines: {node: '>=6.9.0'} '@babel/template@7.27.2': resolution: {integrity: sha512-LPDZ85aEJyYSd18/DkjNh4/y1ntkE5KwUHWTiqgRxruuZL2F1yuHligVHLvcHY2vMHXttKFpJn6LwfI7cw7ODw==} engines: {node: '>=6.9.0'} - '@babel/template@7.28.6': - resolution: {integrity: sha512-YA6Ma2KsCdGb+WC6UpBVFJGXL58MDA6oyONbjyF/+5sBgxY/dwkhLogbMT2GXXyU84/IhRw/2D1Os1B/giz+BQ==} + '@babel/traverse@7.24.5': + resolution: {integrity: sha512-7aaBLeDQ4zYcUFDUD41lJc1fG8+5IU9DaNSJAgal866FGvmD5EbWQgnEC6kO1gGLsX0esNkfnJSndbTXA3r7UA==} engines: {node: '>=6.9.0'} '@babel/traverse@7.28.5': resolution: {integrity: sha512-TCCj4t55U90khlYkVV/0TfkJkAkUg3jZFA3Neb7unZT8CPok7iiRfaX0F+WnqWqt7OxhOn0uBKXCw4lbL8W0aQ==} engines: {node: '>=6.9.0'} - '@babel/traverse@7.29.0': - resolution: {integrity: sha512-4HPiQr0X7+waHfyXPZpWPfWL/J7dcN1mx9gL6WdQVMbPnF3+ZhSMs8tCxN7oHddJE9fhNE7+lxdnlyemKfJRuA==} + '@babel/types@7.24.5': + resolution: {integrity: sha512-6mQNsaLeXTw0nxYUYu+NSa4Hx4BlF1x1x8/PMFbiR+GBSr+2DkECc69b8hgy2frEodNcvPffeH8YfWd3LI6jhQ==} engines: {node: '>=6.9.0'} - '@babel/types@7.28.5': - resolution: {integrity: sha512-qQ5m48eI/MFLQ5PxQj4PFaprjyCTLI37ElWMmNs0K8Lk3dVeOdNpB3ks8jc7yM5CDmVC73eMVk/trk3fgmrUpA==} + '@babel/types@7.26.0': + resolution: {integrity: sha512-Z/yiTPj+lDVnF7lWeKCIJzaIkI0vYO87dMpZ4bg4TDrFe4XXLFWL1TbXU27gBP3QccxV9mZICCrnjnYlJjXHOA==} engines: {node: '>=6.9.0'} - '@babel/types@7.29.0': - resolution: {integrity: sha512-LwdZHpScM4Qz8Xw2iKSzS+cfglZzJGvofQICy7W7v4caru4EaAmyUuO6BGrbyQ2mYV11W0U8j5mBhd14dd3B0A==} + '@babel/types@7.27.1': + resolution: {integrity: sha512-+EzkxvLNfiUeKMgy/3luqfsCWFRXLb7U6wNQTk60tovuckwB15B191tJWvpp4HjiQWdJkCxO3Wbvc6jlk3Xb2Q==} + engines: {node: '>=6.9.0'} + + '@babel/types@7.28.5': + resolution: {integrity: sha512-qQ5m48eI/MFLQ5PxQj4PFaprjyCTLI37ElWMmNs0K8Lk3dVeOdNpB3ks8jc7yM5CDmVC73eMVk/trk3fgmrUpA==} engines: {node: '>=6.9.0'} '@bcoe/v8-coverage@1.0.2': resolution: {integrity: sha512-6zABk/ECA/QYSCQ1NGiVwwbQerUCZ+TQbp64Q3AgmfNvurHH0j8TtXa1qbShXA6qqkpAj4V5W8pP6mLe1mcMqA==} engines: {node: '>=18'} - '@bytecodealliance/preview2-shim@0.17.0': - resolution: {integrity: sha512-JorcEwe4ud0x5BS/Ar2aQWOQoFzjq/7jcnxYXCvSMh0oRm0dQXzOA+hqLDBnOMks1LLBA7dmiLLsEBl09Yd6iQ==} + '@biomejs/biome@1.9.4': + resolution: {integrity: sha512-1rkd7G70+o9KkTn5KLmDYXihGoTaIGO9PIIN2ZB7UJxFrWw04CZHPYiMRjYsaDvVV7hP1dYNRLxSANLaBFGpog==} + engines: {node: '>=14.21.3'} + hasBin: true + + '@biomejs/cli-darwin-arm64@1.9.4': + resolution: {integrity: sha512-bFBsPWrNvkdKrNCYeAp+xo2HecOGPAy9WyNyB/jKnnedgzl4W4Hb9ZMzYNbf8dMCGmUdSavlYHiR01QaYR58cw==} + engines: {node: '>=14.21.3'} + cpu: [arm64] + os: [darwin] + + '@biomejs/cli-darwin-x64@1.9.4': + resolution: {integrity: sha512-ngYBh/+bEedqkSevPVhLP4QfVPCpb+4BBe2p7Xs32dBgs7rh9nY2AIYUL6BgLw1JVXV8GlpKmb/hNiuIxfPfZg==} + engines: {node: '>=14.21.3'} + cpu: [x64] + os: [darwin] + + '@biomejs/cli-linux-arm64-musl@1.9.4': + resolution: {integrity: sha512-v665Ct9WCRjGa8+kTr0CzApU0+XXtRgwmzIf1SeKSGAv+2scAlW6JR5PMFo6FzqqZ64Po79cKODKf3/AAmECqA==} + engines: {node: '>=14.21.3'} + cpu: [arm64] + os: [linux] + + '@biomejs/cli-linux-arm64@1.9.4': + resolution: {integrity: sha512-fJIW0+LYujdjUgJJuwesP4EjIBl/N/TcOX3IvIHJQNsAqvV2CHIogsmA94BPG6jZATS4Hi+xv4SkBBQSt1N4/g==} + engines: {node: '>=14.21.3'} + cpu: [arm64] + os: [linux] + + '@biomejs/cli-linux-x64-musl@1.9.4': + resolution: {integrity: sha512-gEhi/jSBhZ2m6wjV530Yy8+fNqG8PAinM3oV7CyO+6c3CEh16Eizm21uHVsyVBEB6RIM8JHIl6AGYCv6Q6Q9Tg==} + engines: {node: '>=14.21.3'} + cpu: [x64] + os: [linux] + + '@biomejs/cli-linux-x64@1.9.4': + resolution: {integrity: sha512-lRCJv/Vi3Vlwmbd6K+oQ0KhLHMAysN8lXoCI7XeHlxaajk06u7G+UsFSO01NAs5iYuWKmVZjmiOzJ0OJmGsMwg==} + engines: {node: '>=14.21.3'} + cpu: [x64] + os: [linux] + + '@biomejs/cli-win32-arm64@1.9.4': + resolution: {integrity: sha512-tlbhLk+WXZmgwoIKwHIHEBZUwxml7bRJgk0X2sPyNR3S93cdRq6XulAZRQJ17FYGGzWne0fgrXBKpl7l4M87Hg==} + engines: {node: '>=14.21.3'} + cpu: [arm64] + os: [win32] + + '@biomejs/cli-win32-x64@1.9.4': + resolution: {integrity: sha512-8Y5wMhVIPaWe6jw2H+KlEm4wP/f7EW3810ZLmDlrEEy5KvBsb9ECEfu/kMWD484ijfQ8+nIi0giMgu9g1UAuuA==} + engines: {node: '>=14.21.3'} + cpu: [x64] + os: [win32] + + '@bomb.sh/tab@0.0.10': + resolution: {integrity: sha512-6ALS2rh/4LKn0Yxwm35V6LcgQuSiECHbqQo7+9g4rkgGyXZ0siOc8K+IuWIq/4u0Zkv2mevP9QSqgKhGIvLJMw==} + hasBin: true + peerDependencies: + cac: ^6.7.14 + citty: ^0.1.6 + commander: ^13.1.0 + peerDependenciesMeta: + cac: + optional: true + citty: + optional: true + commander: + optional: true + + '@bundled-es-modules/cookie@2.0.0': + resolution: {integrity: sha512-Or6YHg/kamKHpxULAdSqhGqnWFneIXu1NKvvfBBzKGwpVsYuFIQ5aBPHDnnoR3ghW1nvSkALd+EF9iMtY7Vjxw==} + + '@bundled-es-modules/statuses@1.0.1': + resolution: {integrity: sha512-yn7BklA5acgcBr+7w064fGV+SGIFySjCKpqjcWgBAIfrAkY+4GQTJJHQMeT3V/sgz23VTEVV8TtOmkvJAhFVfg==} + + '@bundled-es-modules/tough-cookie@0.1.6': + resolution: {integrity: sha512-dvMHbL464C0zI+Yqxbz6kZ5TOEp7GLW+pry/RWndAR8MJQAXZ2rPmIs8tziTZjeIyhSNZgZbCePtfSbdWqStJw==} + + '@bytecodealliance/preview2-shim@0.17.6': + resolution: {integrity: sha512-n3cM88gTen5980UOBAD6xDcNNL3ocTK8keab21bpx1ONdA+ARj7uD1qoFxOWCyKlkpSi195FH+GeAut7Oc6zZw==} - '@changesets/apply-release-plan@7.1.1': - resolution: {integrity: sha512-9qPCm/rLx/xoOFXIHGB229+4GOL76S4MC+7tyOuTsR6+1jYlfFDQORdvwR5hDA6y4FL2BPt3qpbcQIS+dW85LA==} + '@changesets/apply-release-plan@7.0.14': + resolution: {integrity: sha512-ddBvf9PHdy2YY0OUiEl3TV78mH9sckndJR14QAt87KLEbIov81XO0q0QAmvooBxXlqRRP8I9B7XOzZwQG7JkWA==} - '@changesets/assemble-release-plan@6.0.10': - resolution: {integrity: sha512-rSDcqdJ9KbVyjpBIuCidhvZNIiVt1XaIYp73ycVQRIA5n/j6wQaEk0ChRLMUQ1vkxZe51PTQ9OIhbg6HQMW45A==} + '@changesets/apply-release-plan@7.0.5': + resolution: {integrity: sha512-1cWCk+ZshEkSVEZrm2fSj1Gz8sYvxgUL4Q78+1ZZqeqfuevPTPk033/yUZ3df8BKMohkqqHfzj0HOOrG0KtXTw==} + + '@changesets/assemble-release-plan@6.0.4': + resolution: {integrity: sha512-nqICnvmrwWj4w2x0fOhVj2QEGdlUuwVAwESrUo5HLzWMI1rE5SWfsr9ln+rDqWB6RQ2ZyaMZHUcU7/IRaUJS+Q==} + + '@changesets/assemble-release-plan@6.0.9': + resolution: {integrity: sha512-tPgeeqCHIwNo8sypKlS3gOPmsS3wP0zHt67JDuL20P4QcXiw/O4Hl7oXiuLnP9yg+rXLQ2sScdV1Kkzde61iSQ==} + + '@changesets/changelog-git@0.2.0': + resolution: {integrity: sha512-bHOx97iFI4OClIT35Lok3sJAwM31VbUM++gnMBV16fdbtBhgYu4dxsphBF/0AZZsyAHMrnM0yFcj5gZM1py6uQ==} '@changesets/changelog-git@0.2.1': resolution: {integrity: sha512-x/xEleCFLH28c3bQeQIyeZf8lFXyDFVn1SgcBiR2Tw/r4IAWlk1fzxCEZ6NxQAjF2Nwtczoen3OA2qR+UawQ8Q==} - '@changesets/cli@2.31.0': - resolution: {integrity: sha512-AhI4enNTgHu2IZr6K4WZyf0EPch4XVMn1yOMFmCD9gsfBGqMYaHXls5HyDv6/CL5axVQABz68eG30eCtbr2wFg==} + '@changesets/changelog-github@0.4.6': + resolution: {integrity: sha512-ahR/+o3OPodzfG9kucEMU/tEtBgwy6QoJiWi1sDBPme8n3WjT6pBlbhqNYpWAJKilomwfjBGY0MTUTs6r9d1RQ==} + + '@changesets/cli@2.27.8': + resolution: {integrity: sha512-gZNyh+LdSsI82wBSHLQ3QN5J30P4uHKJ4fXgoGwQxfXwYFTJzDdvIJasZn8rYQtmKhyQuiBj4SSnLuKlxKWq4w==} hasBin: true - '@changesets/config@3.1.4': - resolution: {integrity: sha512-pf0bvD/v6WI2cRlZ6hzpjtZdSlXDXMAJ+Iz7xfFzV4ZxJ8OGGAON+1qYc99ZPrijnt4xp3VGG7eNvAOGS24V1Q==} + '@changesets/cli@2.29.8': + resolution: {integrity: sha512-1weuGZpP63YWUYjay/E84qqwcnt5yJMM0tep10Up7Q5cS/DGe2IZ0Uj3HNMxGhCINZuR7aO9WBMdKnPit5ZDPA==} + hasBin: true + + '@changesets/config@3.0.3': + resolution: {integrity: sha512-vqgQZMyIcuIpw9nqFIpTSNyc/wgm/Lu1zKN5vECy74u95Qx/Wa9g27HdgO4NkVAaq+BGA8wUc/qvbvVNs93n6A==} + + '@changesets/config@3.1.2': + resolution: {integrity: sha512-CYiRhA4bWKemdYi/uwImjPxqWNpqGPNbEBdX1BdONALFIDK7MCUj6FPkzD+z9gJcvDFUQJn9aDVf4UG7OT6Kog==} '@changesets/errors@0.2.0': resolution: {integrity: sha512-6BLOQUscTpZeGljvyQXlWOItQyU71kCdGz7Pi8H8zdw6BI0g3m43iL4xKUVPWtG+qrrL9DTjpdn8eYuCQSRpow==} - '@changesets/get-dependents-graph@2.1.4': - resolution: {integrity: sha512-ZsS00x6WvmHq3sQv8oCMwL0f/z3wbXCVuSVTJwCnnmbC/iBdNJGFx1EcbMG4PC6sXRyH69liM4A2WKXzn/kRPg==} + '@changesets/get-dependents-graph@2.1.2': + resolution: {integrity: sha512-sgcHRkiBY9i4zWYBwlVyAjEM9sAzs4wYVwJUdnbDLnVG3QwAaia1Mk5P8M7kraTOZN+vBET7n8KyB0YXCbFRLQ==} + + '@changesets/get-dependents-graph@2.1.3': + resolution: {integrity: sha512-gphr+v0mv2I3Oxt19VdWRRUxq3sseyUpX9DaHpTUmLj92Y10AGy+XOtV+kbM6L/fDcpx7/ISDFK6T8A/P3lOdQ==} - '@changesets/get-release-plan@4.0.16': - resolution: {integrity: sha512-2K5Om6CrMPm45rtvckfzWo7e9jOVCKLCnXia5eUPaURH7/LWzri7pK1TycdzAuAtehLkW7VPbWLCSExTHmiI6g==} + '@changesets/get-github-info@0.5.2': + resolution: {integrity: sha512-JppheLu7S114aEs157fOZDjFqUDpm7eHdq5E8SSR0gUBTEK0cNSHsrSR5a66xs0z3RWuo46QvA3vawp8BxDHvg==} + + '@changesets/get-release-plan@4.0.14': + resolution: {integrity: sha512-yjZMHpUHgl4Xl5gRlolVuxDkm4HgSJqT93Ri1Uz8kGrQb+5iJ8dkXJ20M2j/Y4iV5QzS2c5SeTxVSKX+2eMI0g==} + + '@changesets/get-release-plan@4.0.4': + resolution: {integrity: sha512-SicG/S67JmPTrdcc9Vpu0wSQt7IiuN0dc8iR5VScnnTVPfIaLvKmEGRvIaF0kcn8u5ZqLbormZNTO77bCEvyWw==} '@changesets/get-version-range-type@0.4.0': resolution: {integrity: sha512-hwawtob9DryoGTpixy1D3ZXbGgJu1Rhr+ySH2PvTLHvkZuQ7sRT4oQwMh0hbqZH1weAooedEjRsbrWcGLCeyVQ==} + '@changesets/git@3.0.1': + resolution: {integrity: sha512-pdgHcYBLCPcLd82aRcuO0kxCDbw/yISlOtkmwmE8Odo1L6hSiZrBOsRl84eYG7DRCab/iHnOkWqExqc4wxk2LQ==} + '@changesets/git@3.0.4': resolution: {integrity: sha512-BXANzRFkX+XcC1q/d27NKvlJ1yf7PSAgi8JG6dt8EfbHFHi4neau7mufcSca5zRhwOL8j9s6EqsxmT+s+/E6Sw==} '@changesets/logger@0.1.1': resolution: {integrity: sha512-OQtR36ZlnuTxKqoW4Sv6x5YIhOmClRd5pWsjZsddYxpWs517R0HkyiefQPIytCVh4ZcC5x9XaG8KTdd5iRQUfg==} - '@changesets/parse@0.4.3': - resolution: {integrity: sha512-ZDmNc53+dXdWEv7fqIUSgRQOLYoUom5Z40gmLgmATmYR9NbL6FJJHwakcCpzaeCy+1D0m0n7mT4jj2B/MQPl7A==} + '@changesets/parse@0.4.0': + resolution: {integrity: sha512-TS/9KG2CdGXS27S+QxbZXgr8uPsP4yNJYb4BC2/NeFUj80Rni3TeD2qwWmabymxmrLo7JEsytXH1FbpKTbvivw==} + + '@changesets/parse@0.4.2': + resolution: {integrity: sha512-Uo5MC5mfg4OM0jU3up66fmSn6/NE9INK+8/Vn/7sMVcdWg46zfbvvUSjD9EMonVqPi9fbrJH9SXHn48Tr1f2yA==} + + '@changesets/pre@2.0.1': + resolution: {integrity: sha512-vvBJ/If4jKM4tPz9JdY2kGOgWmCowUYOi5Ycv8dyLnEE8FgpYYUo1mgJZxcdtGGP3aG8rAQulGLyyXGSLkIMTQ==} '@changesets/pre@2.0.2': resolution: {integrity: sha512-HaL/gEyFVvkf9KFg6484wR9s0qjAXlZ8qWPDkTyKF6+zqjBe/I2mygg3MbpZ++hdi0ToqNUF8cjj7fBy0dg8Ug==} - '@changesets/read@0.6.7': - resolution: {integrity: sha512-D1G4AUYGrBEk8vj8MGwf75k9GpN6XL3wg8i42P2jZZwFLXnlr2Pn7r9yuQNbaMCarP7ZQWNJbV6XLeysAIMhTA==} + '@changesets/read@0.6.1': + resolution: {integrity: sha512-jYMbyXQk3nwP25nRzQQGa1nKLY0KfoOV7VLgwucI0bUO8t8ZLCr6LZmgjXsiKuRDc+5A6doKPr9w2d+FEJ55zQ==} + + '@changesets/read@0.6.6': + resolution: {integrity: sha512-P5QaN9hJSQQKJShzzpBT13FzOSPyHbqdoIBUd2DJdgvnECCyO6LmAOWSV+O8se2TaZJVwSXjL+v9yhb+a9JeJg==} + + '@changesets/should-skip-package@0.1.1': + resolution: {integrity: sha512-H9LjLbF6mMHLtJIc/eHR9Na+MifJ3VxtgP/Y+XLn4BF7tDTEN1HNYtH6QMcjP1uxp9sjaFYmW8xqloaCi/ckTg==} '@changesets/should-skip-package@0.1.2': resolution: {integrity: sha512-qAK/WrqWLNCP22UDdBTMPH5f41elVDlsNyat180A33dWxuUDyNpg6fPi/FyTZwRriVjg0L8gnjJn2F9XAoF0qw==} @@ -1802,12 +1516,37 @@ packages: '@changesets/types@4.1.0': resolution: {integrity: sha512-LDQvVDv5Kb50ny2s25Fhm3d9QSZimsoUGBsUioj6MC3qbMUCuC8GPIvk/M6IvXx3lYhAs0lwWUQLb+VIEUCECw==} + '@changesets/types@5.2.1': + resolution: {integrity: sha512-myLfHbVOqaq9UtUKqR/nZA/OY7xFjQMdfgfqeZIBK4d0hA6pgxArvdv8M+6NUzzBsjWLOtvApv8YHr4qM+Kpfg==} + + '@changesets/types@6.0.0': + resolution: {integrity: sha512-b1UkfNulgKoWfqyHtzKS5fOZYSJO+77adgL7DLRDr+/7jhChN+QcHnbjiQVOz/U+Ts3PGNySq7diAItzDgugfQ==} + '@changesets/types@6.1.0': resolution: {integrity: sha512-rKQcJ+o1nKNgeoYRHKOS07tAMNd3YSN0uHaJOZYjBAgxfV7TUE7JE+z4BzZdQwb5hKaYbayKN5KrYV7ODb2rAA==} + '@changesets/write@0.3.2': + resolution: {integrity: sha512-kDxDrPNpUgsjDbWBvUo27PzKX4gqeKOlhibaOXDJA6kuBisGqNHv/HwGJrAu8U/dSf8ZEFIeHIPtvSlZI1kULw==} + '@changesets/write@0.4.0': resolution: {integrity: sha512-CdTLvIOPiCNuH71pyDu3rA+Q0n65cmAbXnwWH84rKGiFumFzkmHNT8KHTMEchcxN+Kl8I54xGUhJ7l3E7X396Q==} + '@clack/core@1.0.0-alpha.7': + resolution: {integrity: sha512-3vdh6Ar09D14rVxJZIm3VQJkU+ZOKKT5I5cC0cOVazy70CNyYYjiwRj9unwalhESndgxx6bGc/m6Hhs4EKF5XQ==} + + '@clack/prompts@1.0.0-alpha.8': + resolution: {integrity: sha512-YZGC4BmTKSF5OturNKEz/y4xNjYGmGk6NI785CQucJ7OEdX0qbMmL/zok+9bL6c7qE3WSYffyK5grh2RnkGNtQ==} + + '@cloudflare/kv-asset-handler@0.4.1': + resolution: {integrity: sha512-Nu8ahitGFFJztxUml9oD/DLb7Z28C8cd8F46IVQ7y5Btz575pvMY8AqZsXkX7Gds29eCKdMgIHjIvzskHgPSFg==} + engines: {node: '>=18.0.0'} + + '@coinbase/wallet-sdk@3.9.3': + resolution: {integrity: sha512-N/A2DRIf0Y3PHc1XAMvbBUu4zisna6qAdqABMZwBMNEfWrXpAwx16pZGkYCLGE+Rvv1edbcB2LYDRnACNcmCiw==} + + '@coinbase/wallet-sdk@4.3.0': + resolution: {integrity: sha512-T3+SNmiCw4HzDm4we9wCHCxlP0pqCiwKe4sOwPH3YAK2KSKjxPRydKu6UQJrdONFVLG7ujXvbd/6ZqmvJb8rkw==} + '@colors/colors@1.5.0': resolution: {integrity: sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ==} engines: {node: '>=0.1.90'} @@ -1816,485 +1555,781 @@ packages: resolution: {integrity: sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==} engines: {node: '>=12'} - '@cypress/request@3.0.10': - resolution: {integrity: sha512-hauBrOdvu08vOsagkZ/Aju5XuiZx6ldsLfByg1htFeldhex+PeMrYauANzFsMJeAA0+dyPLbDoX2OYuvVoLDkQ==} - engines: {node: '>= 6'} - '@databeat/tracker@0.9.3': resolution: {integrity: sha512-eGsiNU/CRFujcNtUUqvBiqveCs6S6SiAhalXPDodbk74d3FzvLqHDn5k6WfOEJIhrP3CbYgfMXL0nk51s/rQsg==} - '@emnapi/runtime@1.10.0': - resolution: {integrity: sha512-ewvYlk86xUoGI0zQRNq/mC+16R1QeDlKQy21Ki3oSYXNgLb45GV1P6A0M+/s6nyCuNDqe5VpaY84BzXGwVbwFA==} + '@discoveryjs/json-ext@0.5.7': + resolution: {integrity: sha512-dBVuXR082gk3jsFp7Rd/JI4kytwGHecnCoTtXFb7DB6CNHp4rg5k1bhg0nWdLGLnOV71lmDzGQaLMy8iPLY0pw==} + engines: {node: '>=10.0.0'} - '@ensdomains/ens@0.4.5': - resolution: {integrity: sha512-JSvpj1iNMFjK6K+uVl4unqMoa9rf5jopb8cya5UGBWz23Nw8hSNT7efgUx4BTlAPAgpNlEioUfeTyQ6J9ZvTVw==} - deprecated: Please use @ensdomains/ens-contracts + '@docsearch/css@3.6.3': + resolution: {integrity: sha512-3uvbg8E7rhqE1C4oBAK3tGlS2qfhi9zpfZgH/yjDPF73vd9B41urVIKujF4rczcF4E3qs34SedhehiDJ4UdNBA==} - '@ensdomains/resolver@0.2.4': - resolution: {integrity: sha512-bvaTH34PMCbv6anRa9I/0zjLJgY4EuznbEMgbV77JBCQ9KNC46rzi0avuxpOfu+xDjPEtSFGqVEOr5GlUSGudA==} - deprecated: Please use @ensdomains/ens-contracts + '@docsearch/js@3.6.3': + resolution: {integrity: sha512-2mBFomaN6VijyQQGwieERDu9GeE0hlv9TQRZBTOYsPQW7/vqtd4hnHEkbBbaBRiS4PYcy+UhikbMuDExJs63UA==} - '@esbuild/aix-ppc64@0.27.3': - resolution: {integrity: sha512-9fJMTNFTWZMh5qwrBItuziu834eOCUcEqymSH7pY+zoMVEZg3gcPuBNxH1EvfVYe9h0x/Ptw8KBzv7qxb7l8dg==} - engines: {node: '>=18'} + '@docsearch/react@3.6.3': + resolution: {integrity: sha512-2munr4uBuZq1PG+Ge+F+ldIdxb3Wi8OmEIv2tQQb4RvEvvph+xtQkxwHzVIEnt5s+HecwucuXwB+3JhcZboFLg==} + peerDependencies: + '@types/react': '>= 16.8.0 < 19.0.0' + react: '>= 16.8.0 < 19.0.0' + react-dom: '>= 16.8.0 < 19.0.0' + search-insights: '>= 1 < 3' + peerDependenciesMeta: + '@types/react': + optional: true + react: + optional: true + react-dom: + optional: true + search-insights: + optional: true + + '@ecies/ciphers@0.2.5': + resolution: {integrity: sha512-GalEZH4JgOMHYYcYmVqnFirFsjZHeoGMDt9IxEnM9F7GRUUyUksJ7Ou53L83WHJq3RWKD3AcBpo0iQh0oMpf8A==} + engines: {bun: '>=1', deno: '>=2', node: '>=16'} + peerDependencies: + '@noble/ciphers': ^1.0.0 + + '@edge-runtime/format@2.2.1': + resolution: {integrity: sha512-JQTRVuiusQLNNLe2W9tnzBlV/GvSVcozLl4XZHk5swnRZ/v6jp8TqR8P7sqmJsQqblDZ3EztcWmLDbhRje/+8g==} + engines: {node: '>=16'} + + '@edge-runtime/node-utils@2.3.0': + resolution: {integrity: sha512-uUtx8BFoO1hNxtHjp3eqVPC/mWImGb2exOfGjMLUoipuWgjej+f4o/VP4bUI8U40gu7Teogd5VTeZUkGvJSPOQ==} + engines: {node: '>=16'} + + '@edge-runtime/ponyfill@2.4.2': + resolution: {integrity: sha512-oN17GjFr69chu6sDLvXxdhg0Qe8EZviGSuqzR9qOiKh4MhFYGdBBcqRNzdmYeAdeRzOW2mM9yil4RftUQ7sUOA==} + engines: {node: '>=16'} + + '@edge-runtime/primitives@4.1.0': + resolution: {integrity: sha512-Vw0lbJ2lvRUqc7/soqygUX216Xb8T3WBZ987oywz6aJqRxcwSVWwr9e+Nqo2m9bxobA9mdbWNNoRY6S9eko1EQ==} + engines: {node: '>=16'} + + '@edge-runtime/vm@3.2.0': + resolution: {integrity: sha512-0dEVyRLM/lG4gp1R/Ik5bfPl/1wX00xFwd5KcNH602tzBa09oF7pbTKETEhR1GjZ75K6OJnYFu8II2dyMhONMw==} + engines: {node: '>=16'} + + '@emnapi/core@1.7.1': + resolution: {integrity: sha512-o1uhUASyo921r2XtHYOHy7gdkGLge8ghBEQHMWmyJFoXlpU58kIrhhN3w26lpQb6dspetweapMn2CSNwQ8I4wg==} + + '@emnapi/runtime@1.7.1': + resolution: {integrity: sha512-PVtJr5CmLwYAU9PZDMITZoR5iAOShYREoR45EyyLrbntV50mdePTgUn4AmOw90Ifcj+x2kRjdzr1HP3RrNiHGA==} + + '@emnapi/wasi-threads@1.1.0': + resolution: {integrity: sha512-WI0DdZ8xFSbgMjR1sFsKABJ/C5OnRrjT06JXbZKexJGrDuPTzZdDYfFlsgcCXCyf+suG5QU2e/y1Wo2V/OapLQ==} + + '@esbuild/aix-ppc64@0.21.5': + resolution: {integrity: sha512-1SDgH6ZSPTlggy1yI6+Dbkiz8xzpHJEVAlF/AM1tHPLsf5STom9rwtjE4hKAF20FfXXNTFqEYXyJNWh1GiZedQ==} + engines: {node: '>=12'} cpu: [ppc64] os: [aix] - '@esbuild/android-arm64@0.27.3': - resolution: {integrity: sha512-YdghPYUmj/FX2SYKJ0OZxf+iaKgMsKHVPF1MAq/P8WirnSpCStzKJFjOjzsW0QQ7oIAiccHdcqjbHmJxRb/dmg==} + '@esbuild/aix-ppc64@0.23.1': + resolution: {integrity: sha512-6VhYk1diRqrhBAqpJEdjASR/+WVRtfjpqKuNw11cLiaWpAT/Uu+nokB+UJnevzy/P9C/ty6AOe0dwueMrGh/iQ==} engines: {node: '>=18'} - cpu: [arm64] - os: [android] + cpu: [ppc64] + os: [aix] - '@esbuild/android-arm@0.27.3': - resolution: {integrity: sha512-i5D1hPY7GIQmXlXhs2w8AWHhenb00+GxjxRncS2ZM7YNVGNfaMxgzSGuO8o8SJzRc/oZwU2bcScvVERk03QhzA==} + '@esbuild/aix-ppc64@0.25.12': + resolution: {integrity: sha512-Hhmwd6CInZ3dwpuGTF8fJG6yoWmsToE+vYgD4nytZVxcu1ulHpUQRAB1UJ8+N1Am3Mz4+xOByoQoSZf4D+CpkA==} engines: {node: '>=18'} - cpu: [arm] - os: [android] + cpu: [ppc64] + os: [aix] - '@esbuild/android-x64@0.27.3': - resolution: {integrity: sha512-IN/0BNTkHtk8lkOM8JWAYFg4ORxBkZQf9zXiEOfERX/CzxW3Vg1ewAhU7QSWQpVIzTW+b8Xy+lGzdYXV6UZObQ==} + '@esbuild/aix-ppc64@0.27.2': + resolution: {integrity: sha512-GZMB+a0mOMZs4MpDbj8RJp4cw+w1WV5NYD6xzgvzUJ5Ek2jerwfO2eADyI6ExDSUED+1X8aMbegahsJi+8mgpw==} engines: {node: '>=18'} - cpu: [x64] - os: [android] + cpu: [ppc64] + os: [aix] - '@esbuild/darwin-arm64@0.27.3': - resolution: {integrity: sha512-Re491k7ByTVRy0t3EKWajdLIr0gz2kKKfzafkth4Q8A5n1xTHrkqZgLLjFEHVD+AXdUGgQMq+Godfq45mGpCKg==} - engines: {node: '>=18'} + '@esbuild/android-arm64@0.21.5': + resolution: {integrity: sha512-c0uX9VAUBQ7dTDCjq+wdyGLowMdtR/GoC2U5IYk/7D1H1JYC0qseD7+11iMP2mRLN9RcCMRcjC4YMclCzGwS/A==} + engines: {node: '>=12'} cpu: [arm64] - os: [darwin] - - '@esbuild/darwin-x64@0.27.3': - resolution: {integrity: sha512-vHk/hA7/1AckjGzRqi6wbo+jaShzRowYip6rt6q7VYEDX4LEy1pZfDpdxCBnGtl+A5zq8iXDcyuxwtv3hNtHFg==} - engines: {node: '>=18'} - cpu: [x64] - os: [darwin] + os: [android] - '@esbuild/freebsd-arm64@0.27.3': - resolution: {integrity: sha512-ipTYM2fjt3kQAYOvo6vcxJx3nBYAzPjgTCk7QEgZG8AUO3ydUhvelmhrbOheMnGOlaSFUoHXB6un+A7q4ygY9w==} + '@esbuild/android-arm64@0.23.1': + resolution: {integrity: sha512-xw50ipykXcLstLeWH7WRdQuysJqejuAGPd30vd1i5zSyKK3WE+ijzHmLKxdiCMtH1pHz78rOg0BKSYOSB/2Khw==} engines: {node: '>=18'} cpu: [arm64] - os: [freebsd] + os: [android] - '@esbuild/freebsd-x64@0.27.3': - resolution: {integrity: sha512-dDk0X87T7mI6U3K9VjWtHOXqwAMJBNN2r7bejDsc+j03SEjtD9HrOl8gVFByeM0aJksoUuUVU9TBaZa2rgj0oA==} + '@esbuild/android-arm64@0.25.12': + resolution: {integrity: sha512-6AAmLG7zwD1Z159jCKPvAxZd4y/VTO0VkprYy+3N2FtJ8+BQWFXU+OxARIwA46c5tdD9SsKGZ/1ocqBS/gAKHg==} engines: {node: '>=18'} - cpu: [x64] - os: [freebsd] + cpu: [arm64] + os: [android] - '@esbuild/linux-arm64@0.27.3': - resolution: {integrity: sha512-sZOuFz/xWnZ4KH3YfFrKCf1WyPZHakVzTiqji3WDc0BCl2kBwiJLCXpzLzUBLgmp4veFZdvN5ChW4Eq/8Fc2Fg==} + '@esbuild/android-arm64@0.27.2': + resolution: {integrity: sha512-pvz8ZZ7ot/RBphf8fv60ljmaoydPU12VuXHImtAs0XhLLw+EXBi2BLe3OYSBslR4rryHvweW5gmkKFwTiFy6KA==} engines: {node: '>=18'} cpu: [arm64] - os: [linux] + os: [android] - '@esbuild/linux-arm@0.27.3': - resolution: {integrity: sha512-s6nPv2QkSupJwLYyfS+gwdirm0ukyTFNl3KTgZEAiJDd+iHZcbTPPcWCcRYH+WlNbwChgH2QkE9NSlNrMT8Gfw==} - engines: {node: '>=18'} + '@esbuild/android-arm@0.21.5': + resolution: {integrity: sha512-vCPvzSjpPHEi1siZdlvAlsPxXl7WbOVUBBAowWug4rJHb68Ox8KualB+1ocNvT5fjv6wpkX6o/iEpbDrf68zcg==} + engines: {node: '>=12'} cpu: [arm] - os: [linux] + os: [android] - '@esbuild/linux-ia32@0.27.3': - resolution: {integrity: sha512-yGlQYjdxtLdh0a3jHjuwOrxQjOZYD/C9PfdbgJJF3TIZWnm/tMd/RcNiLngiu4iwcBAOezdnSLAwQDPqTmtTYg==} + '@esbuild/android-arm@0.23.1': + resolution: {integrity: sha512-uz6/tEy2IFm9RYOyvKl88zdzZfwEfKZmnX9Cj1BHjeSGNuGLuMD1kR8y5bteYmwqKm1tj8m4cb/aKEorr6fHWQ==} engines: {node: '>=18'} - cpu: [ia32] - os: [linux] + cpu: [arm] + os: [android] - '@esbuild/linux-loong64@0.27.3': - resolution: {integrity: sha512-WO60Sn8ly3gtzhyjATDgieJNet/KqsDlX5nRC5Y3oTFcS1l0KWba+SEa9Ja1GfDqSF1z6hif/SkpQJbL63cgOA==} + '@esbuild/android-arm@0.25.12': + resolution: {integrity: sha512-VJ+sKvNA/GE7Ccacc9Cha7bpS8nyzVv0jdVgwNDaR4gDMC/2TTRc33Ip8qrNYUcpkOHUT5OZ0bUcNNVZQ9RLlg==} engines: {node: '>=18'} - cpu: [loong64] - os: [linux] + cpu: [arm] + os: [android] - '@esbuild/linux-mips64el@0.27.3': - resolution: {integrity: sha512-APsymYA6sGcZ4pD6k+UxbDjOFSvPWyZhjaiPyl/f79xKxwTnrn5QUnXR5prvetuaSMsb4jgeHewIDCIWljrSxw==} + '@esbuild/android-arm@0.27.2': + resolution: {integrity: sha512-DVNI8jlPa7Ujbr1yjU2PfUSRtAUZPG9I1RwW4F4xFB1Imiu2on0ADiI/c3td+KmDtVKNbi+nffGDQMfcIMkwIA==} engines: {node: '>=18'} - cpu: [mips64el] - os: [linux] + cpu: [arm] + os: [android] - '@esbuild/linux-ppc64@0.27.3': - resolution: {integrity: sha512-eizBnTeBefojtDb9nSh4vvVQ3V9Qf9Df01PfawPcRzJH4gFSgrObw+LveUyDoKU3kxi5+9RJTCWlj4FjYXVPEA==} - engines: {node: '>=18'} - cpu: [ppc64] - os: [linux] + '@esbuild/android-x64@0.21.5': + resolution: {integrity: sha512-D7aPRUUNHRBwHxzxRvp856rjUHRFW1SdQATKXH2hqA0kAZb1hKmi02OpYRacl0TxIGz/ZmXWlbZgjwWYaCakTA==} + engines: {node: '>=12'} + cpu: [x64] + os: [android] - '@esbuild/linux-riscv64@0.27.3': - resolution: {integrity: sha512-3Emwh0r5wmfm3ssTWRQSyVhbOHvqegUDRd0WhmXKX2mkHJe1SFCMJhagUleMq+Uci34wLSipf8Lagt4LlpRFWQ==} + '@esbuild/android-x64@0.23.1': + resolution: {integrity: sha512-nlN9B69St9BwUoB+jkyU090bru8L0NA3yFvAd7k8dNsVH8bi9a8cUAUSEcEEgTp2z3dbEDGJGfP6VUnkQnlReg==} engines: {node: '>=18'} - cpu: [riscv64] - os: [linux] + cpu: [x64] + os: [android] - '@esbuild/linux-s390x@0.27.3': - resolution: {integrity: sha512-pBHUx9LzXWBc7MFIEEL0yD/ZVtNgLytvx60gES28GcWMqil8ElCYR4kvbV2BDqsHOvVDRrOxGySBM9Fcv744hw==} + '@esbuild/android-x64@0.25.12': + resolution: {integrity: sha512-5jbb+2hhDHx5phYR2By8GTWEzn6I9UqR11Kwf22iKbNpYrsmRB18aX/9ivc5cabcUiAT/wM+YIZ6SG9QO6a8kg==} engines: {node: '>=18'} - cpu: [s390x] - os: [linux] + cpu: [x64] + os: [android] - '@esbuild/linux-x64@0.27.3': - resolution: {integrity: sha512-Czi8yzXUWIQYAtL/2y6vogER8pvcsOsk5cpwL4Gk5nJqH5UZiVByIY8Eorm5R13gq+DQKYg0+JyQoytLQas4dA==} + '@esbuild/android-x64@0.27.2': + resolution: {integrity: sha512-z8Ank4Byh4TJJOh4wpz8g2vDy75zFL0TlZlkUkEwYXuPSgX8yzep596n6mT7905kA9uHZsf/o2OJZubl2l3M7A==} engines: {node: '>=18'} cpu: [x64] - os: [linux] + os: [android] - '@esbuild/netbsd-arm64@0.27.3': - resolution: {integrity: sha512-sDpk0RgmTCR/5HguIZa9n9u+HVKf40fbEUt+iTzSnCaGvY9kFP0YKBWZtJaraonFnqef5SlJ8/TiPAxzyS+UoA==} - engines: {node: '>=18'} + '@esbuild/darwin-arm64@0.21.5': + resolution: {integrity: sha512-DwqXqZyuk5AiWWf3UfLiRDJ5EDd49zg6O9wclZ7kUMv2WRFr4HKjXp/5t8JZ11QbQfUS6/cRCKGwYhtNAY88kQ==} + engines: {node: '>=12'} cpu: [arm64] - os: [netbsd] + os: [darwin] - '@esbuild/netbsd-x64@0.27.3': - resolution: {integrity: sha512-P14lFKJl/DdaE00LItAukUdZO5iqNH7+PjoBm+fLQjtxfcfFE20Xf5CrLsmZdq5LFFZzb5JMZ9grUwvtVYzjiA==} + '@esbuild/darwin-arm64@0.23.1': + resolution: {integrity: sha512-YsS2e3Wtgnw7Wq53XXBLcV6JhRsEq8hkfg91ESVadIrzr9wO6jJDMZnCQbHm1Guc5t/CdDiFSSfWP58FNuvT3Q==} engines: {node: '>=18'} - cpu: [x64] - os: [netbsd] + cpu: [arm64] + os: [darwin] - '@esbuild/openbsd-arm64@0.27.3': - resolution: {integrity: sha512-AIcMP77AvirGbRl/UZFTq5hjXK+2wC7qFRGoHSDrZ5v5b8DK/GYpXW3CPRL53NkvDqb9D+alBiC/dV0Fb7eJcw==} + '@esbuild/darwin-arm64@0.25.12': + resolution: {integrity: sha512-N3zl+lxHCifgIlcMUP5016ESkeQjLj/959RxxNYIthIg+CQHInujFuXeWbWMgnTo4cp5XVHqFPmpyu9J65C1Yg==} engines: {node: '>=18'} cpu: [arm64] - os: [openbsd] + os: [darwin] - '@esbuild/openbsd-x64@0.27.3': - resolution: {integrity: sha512-DnW2sRrBzA+YnE70LKqnM3P+z8vehfJWHXECbwBmH/CU51z6FiqTQTHFenPlHmo3a8UgpLyH3PT+87OViOh1AQ==} + '@esbuild/darwin-arm64@0.27.2': + resolution: {integrity: sha512-davCD2Zc80nzDVRwXTcQP/28fiJbcOwvdolL0sOiOsbwBa72kegmVU0Wrh1MYrbuCL98Omp5dVhQFWRKR2ZAlg==} engines: {node: '>=18'} + cpu: [arm64] + os: [darwin] + + '@esbuild/darwin-x64@0.21.5': + resolution: {integrity: sha512-se/JjF8NlmKVG4kNIuyWMV/22ZaerB+qaSi5MdrXtd6R08kvs2qCN4C09miupktDitvh8jRFflwGFBQcxZRjbw==} + engines: {node: '>=12'} cpu: [x64] - os: [openbsd] + os: [darwin] - '@esbuild/openharmony-arm64@0.27.3': - resolution: {integrity: sha512-NinAEgr/etERPTsZJ7aEZQvvg/A6IsZG/LgZy+81wON2huV7SrK3e63dU0XhyZP4RKGyTm7aOgmQk0bGp0fy2g==} + '@esbuild/darwin-x64@0.23.1': + resolution: {integrity: sha512-aClqdgTDVPSEGgoCS8QDG37Gu8yc9lTHNAQlsztQ6ENetKEO//b8y31MMu2ZaPbn4kVsIABzVLXYLhCGekGDqw==} engines: {node: '>=18'} - cpu: [arm64] - os: [openharmony] + cpu: [x64] + os: [darwin] - '@esbuild/sunos-x64@0.27.3': - resolution: {integrity: sha512-PanZ+nEz+eWoBJ8/f8HKxTTD172SKwdXebZ0ndd953gt1HRBbhMsaNqjTyYLGLPdoWHy4zLU7bDVJztF5f3BHA==} + '@esbuild/darwin-x64@0.25.12': + resolution: {integrity: sha512-HQ9ka4Kx21qHXwtlTUVbKJOAnmG1ipXhdWTmNXiPzPfWKpXqASVcWdnf2bnL73wgjNrFXAa3yYvBSd9pzfEIpA==} engines: {node: '>=18'} cpu: [x64] - os: [sunos] + os: [darwin] - '@esbuild/win32-arm64@0.27.3': - resolution: {integrity: sha512-B2t59lWWYrbRDw/tjiWOuzSsFh1Y/E95ofKz7rIVYSQkUYBjfSgf6oeYPNWHToFRr2zx52JKApIcAS/D5TUBnA==} + '@esbuild/darwin-x64@0.27.2': + resolution: {integrity: sha512-ZxtijOmlQCBWGwbVmwOF/UCzuGIbUkqB1faQRf5akQmxRJ1ujusWsb3CVfk/9iZKr2L5SMU5wPBi1UWbvL+VQA==} engines: {node: '>=18'} + cpu: [x64] + os: [darwin] + + '@esbuild/freebsd-arm64@0.21.5': + resolution: {integrity: sha512-5JcRxxRDUJLX8JXp/wcBCy3pENnCgBR9bN6JsY4OmhfUtIHe3ZW0mawA7+RDAcMLrMIZaf03NlQiX9DGyB8h4g==} + engines: {node: '>=12'} cpu: [arm64] - os: [win32] + os: [freebsd] - '@esbuild/win32-ia32@0.27.3': - resolution: {integrity: sha512-QLKSFeXNS8+tHW7tZpMtjlNb7HKau0QDpwm49u0vUp9y1WOF+PEzkU84y9GqYaAVW8aH8f3GcBck26jh54cX4Q==} + '@esbuild/freebsd-arm64@0.23.1': + resolution: {integrity: sha512-h1k6yS8/pN/NHlMl5+v4XPfikhJulk4G+tKGFIOwURBSFzE8bixw1ebjluLOjfwtLqY0kewfjLSrO6tN2MgIhA==} engines: {node: '>=18'} - cpu: [ia32] - os: [win32] + cpu: [arm64] + os: [freebsd] - '@esbuild/win32-x64@0.27.3': - resolution: {integrity: sha512-4uJGhsxuptu3OcpVAzli+/gWusVGwZZHTlS63hh++ehExkVT8SgiEf7/uC/PclrPPkLhZqGgCTjd0VWLo6xMqA==} + '@esbuild/freebsd-arm64@0.25.12': + resolution: {integrity: sha512-gA0Bx759+7Jve03K1S0vkOu5Lg/85dou3EseOGUes8flVOGxbhDDh/iZaoek11Y8mtyKPGF3vP8XhnkDEAmzeg==} engines: {node: '>=18'} - cpu: [x64] - os: [win32] - - '@eslint-community/eslint-utils@4.9.0': - resolution: {integrity: sha512-ayVFHdtZ+hsq1t2Dy24wCmGXGe4q9Gu3smhLYALJrr473ZH27MsnSL+LKUlimp4BWJqMDMLmPpx/Q9R3OAlL4g==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - peerDependencies: - eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 + cpu: [arm64] + os: [freebsd] - '@eslint-community/eslint-utils@4.9.1': - resolution: {integrity: sha512-phrYmNiYppR7znFEdqgfWHXR6NCkZEK7hwWDHZUjit/2/U0r6XvkDl0SYnoM51Hq7FhCGdLDT6zxCCOY1hexsQ==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - peerDependencies: - eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 + '@esbuild/freebsd-arm64@0.27.2': + resolution: {integrity: sha512-lS/9CN+rgqQ9czogxlMcBMGd+l8Q3Nj1MFQwBZJyoEKI50XGxwuzznYdwcav6lpOGv5BqaZXqvBSiB/kJ5op+g==} + engines: {node: '>=18'} + cpu: [arm64] + os: [freebsd] - '@eslint-community/regexpp@4.12.2': - resolution: {integrity: sha512-EriSTlt5OC9/7SXkRSCAhfSxxoSUgBm33OH+IkwbdpgoqsSsUg7y3uh+IICI/Qg4BBWr3U2i39RpmycbxMq4ew==} - engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0} + '@esbuild/freebsd-x64@0.21.5': + resolution: {integrity: sha512-J95kNBj1zkbMXtHVH29bBriQygMXqoVQOQYA+ISs0/2l3T9/kj42ow2mpqerRBxDJnmkUDCaQT/dfNXWX/ZZCQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [freebsd] - '@eslint/config-array@0.21.1': - resolution: {integrity: sha512-aw1gNayWpdI/jSYVgzN5pL0cfzU02GT3NBpeT/DXbx1/1x7ZKxFPd9bwrzygx/qiwIQiJ1sw/zD8qY/kRvlGHA==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@esbuild/freebsd-x64@0.23.1': + resolution: {integrity: sha512-lK1eJeyk1ZX8UklqFd/3A60UuZ/6UVfGT2LuGo3Wp4/z7eRTRYY+0xOu2kpClP+vMTi9wKOfXi2vjUpO1Ro76g==} + engines: {node: '>=18'} + cpu: [x64] + os: [freebsd] - '@eslint/config-array@0.21.2': - resolution: {integrity: sha512-nJl2KGTlrf9GjLimgIru+V/mzgSK0ABCDQRvxw5BjURL7WfH5uoWmizbH7QB6MmnMBd8cIC9uceWnezL1VZWWw==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@esbuild/freebsd-x64@0.25.12': + resolution: {integrity: sha512-TGbO26Yw2xsHzxtbVFGEXBFH0FRAP7gtcPE7P5yP7wGy7cXK2oO7RyOhL5NLiqTlBh47XhmIUXuGciXEqYFfBQ==} + engines: {node: '>=18'} + cpu: [x64] + os: [freebsd] - '@eslint/config-helpers@0.4.2': - resolution: {integrity: sha512-gBrxN88gOIf3R7ja5K9slwNayVcZgK6SOUORm2uBzTeIEfeVaIhOpCtTox3P6R7o2jLFwLFTLnC7kU/RGcYEgw==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@esbuild/freebsd-x64@0.27.2': + resolution: {integrity: sha512-tAfqtNYb4YgPnJlEFu4c212HYjQWSO/w/h/lQaBK7RbwGIkBOuNKQI9tqWzx7Wtp7bTPaGC6MJvWI608P3wXYA==} + engines: {node: '>=18'} + cpu: [x64] + os: [freebsd] - '@eslint/core@0.17.0': - resolution: {integrity: sha512-yL/sLrpmtDaFEiUj1osRP4TI2MDz1AddJL+jZ7KSqvBuliN4xqYY54IfdN8qD8Toa6g1iloph1fxQNkjOxrrpQ==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@esbuild/linux-arm64@0.21.5': + resolution: {integrity: sha512-ibKvmyYzKsBeX8d8I7MH/TMfWDXBF3db4qM6sy+7re0YXya+K1cem3on9XgdT2EQGMu4hQyZhan7TeQ8XkGp4Q==} + engines: {node: '>=12'} + cpu: [arm64] + os: [linux] - '@eslint/eslintrc@3.3.3': - resolution: {integrity: sha512-Kr+LPIUVKz2qkx1HAMH8q1q6azbqBAsXJUxBl/ODDuVPX45Z9DfwB8tPjTi6nNZ8BuM3nbJxC5zCAg5elnBUTQ==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@esbuild/linux-arm64@0.23.1': + resolution: {integrity: sha512-/93bf2yxencYDnItMYV/v116zff6UyTjo4EtEQjUBeGiVpMmffDNUyD9UN2zV+V3LRV3/on4xdZ26NKzn6754g==} + engines: {node: '>=18'} + cpu: [arm64] + os: [linux] - '@eslint/eslintrc@3.3.5': - resolution: {integrity: sha512-4IlJx0X0qftVsN5E+/vGujTRIFtwuLbNsVUe7TO6zYPDR1O6nFwvwhIKEKSrl6dZchmYBITazxKoUYOjdtjlRg==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@esbuild/linux-arm64@0.25.12': + resolution: {integrity: sha512-8bwX7a8FghIgrupcxb4aUmYDLp8pX06rGh5HqDT7bB+8Rdells6mHvrFHHW2JAOPZUbnjUpKTLg6ECyzvas2AQ==} + engines: {node: '>=18'} + cpu: [arm64] + os: [linux] - '@eslint/js@9.39.2': - resolution: {integrity: sha512-q1mjIoW1VX4IvSocvM/vbTiveKC4k9eLrajNEuSsmjymSDEbpGddtpfOoN7YGAqBK3NG+uqo8ia4PDTt8buCYA==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@esbuild/linux-arm64@0.27.2': + resolution: {integrity: sha512-hYxN8pr66NsCCiRFkHUAsxylNOcAQaxSSkHMMjcpx0si13t1LHFphxJZUiGwojB1a/Hd5OiPIqDdXONia6bhTw==} + engines: {node: '>=18'} + cpu: [arm64] + os: [linux] - '@eslint/js@9.39.4': - resolution: {integrity: sha512-nE7DEIchvtiFTwBw4Lfbu59PG+kCofhjsKaCWzxTpt4lfRjRMqG6uMBzKXuEcyXhOHoUp9riAm7/aWYGhXZ9cw==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@esbuild/linux-arm@0.21.5': + resolution: {integrity: sha512-bPb5AHZtbeNGjCKVZ9UGqGwo8EUu4cLq68E95A53KlxAPRmUyYv2D6F0uUI65XisGOL1hBP5mTronbgo+0bFcA==} + engines: {node: '>=12'} + cpu: [arm] + os: [linux] - '@eslint/object-schema@2.1.7': - resolution: {integrity: sha512-VtAOaymWVfZcmZbp6E2mympDIHvyjXs/12LqWYjVw6qjrfF+VK+fyG33kChz3nnK+SU5/NeHOqrTEHS8sXO3OA==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@esbuild/linux-arm@0.23.1': + resolution: {integrity: sha512-CXXkzgn+dXAPs3WBwE+Kvnrf4WECwBdfjfeYHpMeVxWE0EceB6vhWGShs6wi0IYEqMSIzdOF1XjQ/Mkm5d7ZdQ==} + engines: {node: '>=18'} + cpu: [arm] + os: [linux] - '@eslint/plugin-kit@0.4.1': - resolution: {integrity: sha512-43/qtrDUokr7LJqoF2c3+RInu/t4zfrpYdoSDfYyhg52rwLV6TnOvdG4fXm7IkSB3wErkcmJS9iEhjVtOSEjjA==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@esbuild/linux-arm@0.25.12': + resolution: {integrity: sha512-lPDGyC1JPDou8kGcywY0YILzWlhhnRjdof3UlcoqYmS9El818LLfJJc3PXXgZHrHCAKs/Z2SeZtDJr5MrkxtOw==} + engines: {node: '>=18'} + cpu: [arm] + os: [linux] - '@ethereum-waffle/chai@4.0.10': - resolution: {integrity: sha512-X5RepE7Dn8KQLFO7HHAAe+KeGaX/by14hn90wePGBhzL54tq4Y8JscZFu+/LCwCl6TnkAAy5ebiMoqJ37sFtWw==} - engines: {node: '>=10.0'} - peerDependencies: - ethers: '*' + '@esbuild/linux-arm@0.27.2': + resolution: {integrity: sha512-vWfq4GaIMP9AIe4yj1ZUW18RDhx6EPQKjwe7n8BbIecFtCQG4CfHGaHuh7fdfq+y3LIA2vGS/o9ZBGVxIDi9hw==} + engines: {node: '>=18'} + cpu: [arm] + os: [linux] - '@ethereum-waffle/compiler@4.0.3': - resolution: {integrity: sha512-5x5U52tSvEVJS6dpCeXXKvRKyf8GICDwiTwUvGD3/WD+DpvgvaoHOL82XqpTSUHgV3bBq6ma5/8gKUJUIAnJCw==} - engines: {node: '>=10.0'} - peerDependencies: - ethers: '*' - solc: '*' - typechain: ^8.0.0 + '@esbuild/linux-ia32@0.21.5': + resolution: {integrity: sha512-YvjXDqLRqPDl2dvRODYmmhz4rPeVKYvppfGYKSNGdyZkA01046pLWyRKKI3ax8fbJoK5QbxblURkwK/MWY18Tg==} + engines: {node: '>=12'} + cpu: [ia32] + os: [linux] - '@ethereum-waffle/ens@4.0.3': - resolution: {integrity: sha512-PVLcdnTbaTfCrfSOrvtlA9Fih73EeDvFS28JQnT5M5P4JMplqmchhcZB1yg/fCtx4cvgHlZXa0+rOCAk2Jk0Jw==} - engines: {node: '>=10.0'} - peerDependencies: - '@ensdomains/ens': ^0.4.4 - '@ensdomains/resolver': ^0.2.4 - ethers: '*' + '@esbuild/linux-ia32@0.23.1': + resolution: {integrity: sha512-VTN4EuOHwXEkXzX5nTvVY4s7E/Krz7COC8xkftbbKRYAl96vPiUssGkeMELQMOnLOJ8k3BY1+ZY52tttZnHcXQ==} + engines: {node: '>=18'} + cpu: [ia32] + os: [linux] - '@ethereum-waffle/mock-contract@4.0.4': - resolution: {integrity: sha512-LwEj5SIuEe9/gnrXgtqIkWbk2g15imM/qcJcxpLyAkOj981tQxXmtV4XmQMZsdedEsZ/D/rbUAOtZbgwqgUwQA==} - engines: {node: '>=10.0'} - peerDependencies: - ethers: '*' + '@esbuild/linux-ia32@0.25.12': + resolution: {integrity: sha512-0y9KrdVnbMM2/vG8KfU0byhUN+EFCny9+8g202gYqSSVMonbsCfLjUO+rCci7pM0WBEtz+oK/PIwHkzxkyharA==} + engines: {node: '>=18'} + cpu: [ia32] + os: [linux] - '@ethereum-waffle/provider@4.0.5': - resolution: {integrity: sha512-40uzfyzcrPh+Gbdzv89JJTMBlZwzya1YLDyim8mVbEqYLP5VRYWoGp0JMyaizgV3hMoUFRqJKVmIUw4v7r3hYw==} - engines: {node: '>=10.0'} - peerDependencies: - ethers: '*' + '@esbuild/linux-ia32@0.27.2': + resolution: {integrity: sha512-MJt5BRRSScPDwG2hLelYhAAKh9imjHK5+NE/tvnRLbIqUWa+0E9N4WNMjmp/kXXPHZGqPLxggwVhz7QP8CTR8w==} + engines: {node: '>=18'} + cpu: [ia32] + os: [linux] - '@ethereumjs/block@3.6.3': - resolution: {integrity: sha512-CegDeryc2DVKnDkg5COQrE0bJfw/p0v3GBk2W5/Dj5dOVfEmb50Ux0GLnSPypooLnfqjwFaorGuT9FokWB3GRg==} + '@esbuild/linux-loong64@0.21.5': + resolution: {integrity: sha512-uHf1BmMG8qEvzdrzAqg2SIG/02+4/DHB6a9Kbya0XDvwDEKCoC8ZRWI5JJvNdUjtciBGFQ5PuBlpEOXQj+JQSg==} + engines: {node: '>=12'} + cpu: [loong64] + os: [linux] - '@ethereumjs/blockchain@5.5.3': - resolution: {integrity: sha512-bi0wuNJ1gw4ByNCV56H0Z4Q7D+SxUbwyG12Wxzbvqc89PXLRNR20LBcSUZRKpN0+YCPo6m0XZL/JLio3B52LTw==} + '@esbuild/linux-loong64@0.23.1': + resolution: {integrity: sha512-Vx09LzEoBa5zDnieH8LSMRToj7ir/Jeq0Gu6qJ/1GcBq9GkfoEAoXvLiW1U9J1qE/Y/Oyaq33w5p2ZWrNNHNEw==} + engines: {node: '>=18'} + cpu: [loong64] + os: [linux] - '@ethereumjs/common@2.6.0': - resolution: {integrity: sha512-Cq2qS0FTu6O2VU1sgg+WyU9Ps0M6j/BEMHN+hRaECXCV/r0aI78u4N6p52QW/BDVhwWZpCdrvG8X7NJdzlpNUA==} + '@esbuild/linux-loong64@0.25.12': + resolution: {integrity: sha512-h///Lr5a9rib/v1GGqXVGzjL4TMvVTv+s1DPoxQdz7l/AYv6LDSxdIwzxkrPW438oUXiDtwM10o9PmwS/6Z0Ng==} + engines: {node: '>=18'} + cpu: [loong64] + os: [linux] - '@ethereumjs/common@2.6.5': - resolution: {integrity: sha512-lRyVQOeCDaIVtgfbowla32pzeDv2Obr8oR8Put5RdUBNRGr1VGPGQNGP6elWIpgK3YdpzqTOh4GyUGOureVeeA==} + '@esbuild/linux-loong64@0.27.2': + resolution: {integrity: sha512-lugyF1atnAT463aO6KPshVCJK5NgRnU4yb3FUumyVz+cGvZbontBgzeGFO1nF+dPueHD367a2ZXe1NtUkAjOtg==} + engines: {node: '>=18'} + cpu: [loong64] + os: [linux] - '@ethereumjs/ethash@1.1.0': - resolution: {integrity: sha512-/U7UOKW6BzpA+Vt+kISAoeDie1vAvY4Zy2KF5JJb+So7+1yKmJeJEHOGSnQIj330e9Zyl3L5Nae6VZyh2TJnAA==} + '@esbuild/linux-mips64el@0.21.5': + resolution: {integrity: sha512-IajOmO+KJK23bj52dFSNCMsz1QP1DqM6cwLUv3W1QwyxkyIWecfafnI555fvSGqEKwjMXVLokcV5ygHW5b3Jbg==} + engines: {node: '>=12'} + cpu: [mips64el] + os: [linux] - '@ethereumjs/rlp@4.0.1': - resolution: {integrity: sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==} - engines: {node: '>=14'} - hasBin: true + '@esbuild/linux-mips64el@0.23.1': + resolution: {integrity: sha512-nrFzzMQ7W4WRLNUOU5dlWAqa6yVeI0P78WKGUo7lg2HShq/yx+UYkeNSE0SSfSure0SqgnsxPvmAUu/vu0E+3Q==} + engines: {node: '>=18'} + cpu: [mips64el] + os: [linux] - '@ethereumjs/rlp@5.0.2': - resolution: {integrity: sha512-DziebCdg4JpGlEqEdGgXmjqcFoJi+JGulUXwEjsZGAscAQ7MyD/7LE/GVCP29vEQxKc7AAwjT3A2ywHp2xfoCA==} + '@esbuild/linux-mips64el@0.25.12': + resolution: {integrity: sha512-iyRrM1Pzy9GFMDLsXn1iHUm18nhKnNMWscjmp4+hpafcZjrr2WbT//d20xaGljXDBYHqRcl8HnxbX6uaA/eGVw==} engines: {node: '>=18'} - hasBin: true + cpu: [mips64el] + os: [linux] - '@ethereumjs/tx@3.4.0': - resolution: {integrity: sha512-WWUwg1PdjHKZZxPPo274ZuPsJCWV3SqATrEKQP1n2DrVYVP1aZIYpo/mFaA0BDoE0tIQmBeimRCEA0Lgil+yYw==} + '@esbuild/linux-mips64el@0.27.2': + resolution: {integrity: sha512-nlP2I6ArEBewvJ2gjrrkESEZkB5mIoaTswuqNFRv/WYd+ATtUpe9Y09RnJvgvdag7he0OWgEZWhviS1OTOKixw==} + engines: {node: '>=18'} + cpu: [mips64el] + os: [linux] - '@ethereumjs/tx@3.5.2': - resolution: {integrity: sha512-gQDNJWKrSDGu2w7w0PzVXVBNMzb7wwdDOmOqczmhNjqFxFuIbhVJDwiGEnxFNC2/b8ifcZzY7MLcluizohRzNw==} + '@esbuild/linux-ppc64@0.21.5': + resolution: {integrity: sha512-1hHV/Z4OEfMwpLO8rp7CvlhBDnjsC3CttJXIhBi+5Aj5r+MBvy4egg7wCbe//hSsT+RvDAG7s81tAvpL2XAE4w==} + engines: {node: '>=12'} + cpu: [ppc64] + os: [linux] - '@ethereumjs/util@8.1.0': - resolution: {integrity: sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA==} - engines: {node: '>=14'} + '@esbuild/linux-ppc64@0.23.1': + resolution: {integrity: sha512-dKN8fgVqd0vUIjxuJI6P/9SSSe/mB9rvA98CSH2sJnlZ/OCZWO1DJvxj8jvKTfYUdGfcq2dDxoKaC6bHuTlgcw==} + engines: {node: '>=18'} + cpu: [ppc64] + os: [linux] - '@ethereumjs/util@9.1.0': - resolution: {integrity: sha512-XBEKsYqLGXLah9PNJbgdkigthkG7TAGvlD/sH12beMXEyHDyigfcbdvHhmLyDWgDyOJn4QwiQUaF7yeuhnjdog==} + '@esbuild/linux-ppc64@0.25.12': + resolution: {integrity: sha512-9meM/lRXxMi5PSUqEXRCtVjEZBGwB7P/D4yT8UG/mwIdze2aV4Vo6U5gD3+RsoHXKkHCfSxZKzmDssVlRj1QQA==} engines: {node: '>=18'} + cpu: [ppc64] + os: [linux] - '@ethereumjs/vm@5.6.0': - resolution: {integrity: sha512-J2m/OgjjiGdWF2P9bj/4LnZQ1zRoZhY8mRNVw/N3tXliGI8ai1sI1mlDPkLpeUUM4vq54gH6n0ZlSpz8U/qlYQ==} + '@esbuild/linux-ppc64@0.27.2': + resolution: {integrity: sha512-C92gnpey7tUQONqg1n6dKVbx3vphKtTHJaNG2Ok9lGwbZil6DrfyecMsp9CrmXGQJmZ7iiVXvvZH6Ml5hL6XdQ==} + engines: {node: '>=18'} + cpu: [ppc64] + os: [linux] - '@ethersproject/abi@5.8.0': - resolution: {integrity: sha512-b9YS/43ObplgyV6SlyQsG53/vkSal0MNA1fskSC4mbnCMi8R+NkcH8K9FPYNESf6jUefBUniE4SOKms0E/KK1Q==} + '@esbuild/linux-riscv64@0.21.5': + resolution: {integrity: sha512-2HdXDMd9GMgTGrPWnJzP2ALSokE/0O5HhTUvWIbD3YdjME8JwvSCnNGBnTThKGEB91OZhzrJ4qIIxk/SBmyDDA==} + engines: {node: '>=12'} + cpu: [riscv64] + os: [linux] - '@ethersproject/abstract-provider@5.8.0': - resolution: {integrity: sha512-wC9SFcmh4UK0oKuLJQItoQdzS/qZ51EJegK6EmAWlh+OptpQ/npECOR3QqECd8iGHC0RJb4WKbVdSfif4ammrg==} + '@esbuild/linux-riscv64@0.23.1': + resolution: {integrity: sha512-5AV4Pzp80fhHL83JM6LoA6pTQVWgB1HovMBsLQ9OZWLDqVY8MVobBXNSmAJi//Csh6tcY7e7Lny2Hg1tElMjIA==} + engines: {node: '>=18'} + cpu: [riscv64] + os: [linux] - '@ethersproject/abstract-signer@5.8.0': - resolution: {integrity: sha512-N0XhZTswXcmIZQdYtUnd79VJzvEwXQw6PK0dTl9VoYrEBxxCPXqS0Eod7q5TNKRxe1/5WUMuR0u0nqTF/avdCA==} + '@esbuild/linux-riscv64@0.25.12': + resolution: {integrity: sha512-Zr7KR4hgKUpWAwb1f3o5ygT04MzqVrGEGXGLnj15YQDJErYu/BGg+wmFlIDOdJp0PmB0lLvxFIOXZgFRrdjR0w==} + engines: {node: '>=18'} + cpu: [riscv64] + os: [linux] - '@ethersproject/address@5.6.1': - resolution: {integrity: sha512-uOgF0kS5MJv9ZvCz7x6T2EXJSzotiybApn4XlOgoTX0xdtyVIJ7pF+6cGPxiEq/dpBiTfMiw7Yc81JcwhSYA0Q==} + '@esbuild/linux-riscv64@0.27.2': + resolution: {integrity: sha512-B5BOmojNtUyN8AXlK0QJyvjEZkWwy/FKvakkTDCziX95AowLZKR6aCDhG7LeF7uMCXEJqwa8Bejz5LTPYm8AvA==} + engines: {node: '>=18'} + cpu: [riscv64] + os: [linux] - '@ethersproject/address@5.8.0': - resolution: {integrity: sha512-GhH/abcC46LJwshoN+uBNoKVFPxUuZm6dA257z0vZkKmU1+t8xTn8oK7B9qrj8W2rFRMch4gbJl6PmVxjxBEBA==} + '@esbuild/linux-s390x@0.21.5': + resolution: {integrity: sha512-zus5sxzqBJD3eXxwvjN1yQkRepANgxE9lgOW2qLnmr8ikMTphkjgXu1HR01K4FJg8h1kEEDAqDcZQtbrRnB41A==} + engines: {node: '>=12'} + cpu: [s390x] + os: [linux] - '@ethersproject/base64@5.8.0': - resolution: {integrity: sha512-lN0oIwfkYj9LbPx4xEkie6rAMJtySbpOAFXSDVQaBnAzYfB4X2Qr+FXJGxMoc3Bxp2Sm8OwvzMrywxyw0gLjIQ==} + '@esbuild/linux-s390x@0.23.1': + resolution: {integrity: sha512-9ygs73tuFCe6f6m/Tb+9LtYxWR4c9yg7zjt2cYkjDbDpV/xVn+68cQxMXCjUpYwEkze2RcU/rMnfIXNRFmSoDw==} + engines: {node: '>=18'} + cpu: [s390x] + os: [linux] - '@ethersproject/basex@5.8.0': - resolution: {integrity: sha512-PIgTszMlDRmNwW9nhS6iqtVfdTAKosA7llYXNmGPw4YAI1PUyMv28988wAb41/gHF/WqGdoLv0erHaRcHRKW2Q==} + '@esbuild/linux-s390x@0.25.12': + resolution: {integrity: sha512-MsKncOcgTNvdtiISc/jZs/Zf8d0cl/t3gYWX8J9ubBnVOwlk65UIEEvgBORTiljloIWnBzLs4qhzPkJcitIzIg==} + engines: {node: '>=18'} + cpu: [s390x] + os: [linux] - '@ethersproject/bignumber@5.8.0': - resolution: {integrity: sha512-ZyaT24bHaSeJon2tGPKIiHszWjD/54Sz8t57Toch475lCLljC6MgPmxk7Gtzz+ddNN5LuHea9qhAe0x3D+uYPA==} + '@esbuild/linux-s390x@0.27.2': + resolution: {integrity: sha512-p4bm9+wsPwup5Z8f4EpfN63qNagQ47Ua2znaqGH6bqLlmJ4bx97Y9JdqxgGZ6Y8xVTixUnEkoKSHcpRlDnNr5w==} + engines: {node: '>=18'} + cpu: [s390x] + os: [linux] - '@ethersproject/bytes@5.8.0': - resolution: {integrity: sha512-vTkeohgJVCPVHu5c25XWaWQOZ4v+DkGoC42/TS2ond+PARCxTJvgTFUNDZovyQ/uAQ4EcpqqowKydcdmRKjg7A==} + '@esbuild/linux-x64@0.21.5': + resolution: {integrity: sha512-1rYdTpyv03iycF1+BhzrzQJCdOuAOtaqHTWJZCWvijKD2N5Xu0TtVC8/+1faWqcP9iBCWOmjmhoH94dH82BxPQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [linux] - '@ethersproject/constants@5.8.0': - resolution: {integrity: sha512-wigX4lrf5Vu+axVTIvNsuL6YrV4O5AXl5ubcURKMEME5TnWBouUh0CDTWxZ2GpnRn1kcCgE7l8O5+VbV9QTTcg==} + '@esbuild/linux-x64@0.23.1': + resolution: {integrity: sha512-EV6+ovTsEXCPAp58g2dD68LxoP/wK5pRvgy0J/HxPGB009omFPv3Yet0HiaqvrIrgPTBuC6wCH1LTOY91EO5hQ==} + engines: {node: '>=18'} + cpu: [x64] + os: [linux] - '@ethersproject/contracts@5.8.0': - resolution: {integrity: sha512-0eFjGz9GtuAi6MZwhb4uvUM216F38xiuR0yYCjKJpNfSEy4HUM8hvqqBj9Jmm0IUz8l0xKEhWwLIhPgxNY0yvQ==} + '@esbuild/linux-x64@0.25.12': + resolution: {integrity: sha512-uqZMTLr/zR/ed4jIGnwSLkaHmPjOjJvnm6TVVitAa08SLS9Z0VM8wIRx7gWbJB5/J54YuIMInDquWyYvQLZkgw==} + engines: {node: '>=18'} + cpu: [x64] + os: [linux] - '@ethersproject/hash@5.8.0': - resolution: {integrity: sha512-ac/lBcTbEWW/VGJij0CNSw/wPcw9bSRgCB0AIBz8CvED/jfvDoV9hsIIiWfvWmFEi8RcXtlNwp2jv6ozWOsooA==} + '@esbuild/linux-x64@0.27.2': + resolution: {integrity: sha512-uwp2Tip5aPmH+NRUwTcfLb+W32WXjpFejTIOWZFw/v7/KnpCDKG66u4DLcurQpiYTiYwQ9B7KOeMJvLCu/OvbA==} + engines: {node: '>=18'} + cpu: [x64] + os: [linux] - '@ethersproject/hdnode@5.8.0': - resolution: {integrity: sha512-4bK1VF6E83/3/Im0ERnnUeWOY3P1BZml4ZD3wcH8Ys0/d1h1xaFt6Zc+Dh9zXf9TapGro0T4wvO71UTCp3/uoA==} + '@esbuild/netbsd-arm64@0.25.12': + resolution: {integrity: sha512-xXwcTq4GhRM7J9A8Gv5boanHhRa/Q9KLVmcyXHCTaM4wKfIpWkdXiMog/KsnxzJ0A1+nD+zoecuzqPmCRyBGjg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [netbsd] - '@ethersproject/json-wallets@5.8.0': - resolution: {integrity: sha512-HxblNck8FVUtNxS3VTEYJAcwiKYsBIF77W15HufqlBF9gGfhmYOJtYZp8fSDZtn9y5EaXTE87zDwzxRoTFk11w==} + '@esbuild/netbsd-arm64@0.27.2': + resolution: {integrity: sha512-Kj6DiBlwXrPsCRDeRvGAUb/LNrBASrfqAIok+xB0LxK8CHqxZ037viF13ugfsIpePH93mX7xfJp97cyDuTZ3cw==} + engines: {node: '>=18'} + cpu: [arm64] + os: [netbsd] - '@ethersproject/keccak256@5.8.0': - resolution: {integrity: sha512-A1pkKLZSz8pDaQ1ftutZoaN46I6+jvuqugx5KYNeQOPqq+JZ0Txm7dlWesCHB5cndJSu5vP2VKptKf7cksERng==} + '@esbuild/netbsd-x64@0.21.5': + resolution: {integrity: sha512-Woi2MXzXjMULccIwMnLciyZH4nCIMpWQAs049KEeMvOcNADVxo0UBIQPfSmxB3CWKedngg7sWZdLvLczpe0tLg==} + engines: {node: '>=12'} + cpu: [x64] + os: [netbsd] - '@ethersproject/logger@5.8.0': - resolution: {integrity: sha512-Qe6knGmY+zPPWTC+wQrpitodgBfH7XoceCGL5bJVejmH+yCS3R8jJm8iiWuvWbG76RUmyEG53oqv6GMVWqunjA==} + '@esbuild/netbsd-x64@0.23.1': + resolution: {integrity: sha512-aevEkCNu7KlPRpYLjwmdcuNz6bDFiE7Z8XC4CPqExjTvrHugh28QzUXVOZtiYghciKUacNktqxdpymplil1beA==} + engines: {node: '>=18'} + cpu: [x64] + os: [netbsd] - '@ethersproject/networks@5.8.0': - resolution: {integrity: sha512-egPJh3aPVAzbHwq8DD7Po53J4OUSsA1MjQp8Vf/OZPav5rlmWUaFLiq8cvQiGK0Z5K6LYzm29+VA/p4RL1FzNg==} + '@esbuild/netbsd-x64@0.25.12': + resolution: {integrity: sha512-Ld5pTlzPy3YwGec4OuHh1aCVCRvOXdH8DgRjfDy/oumVovmuSzWfnSJg+VtakB9Cm0gxNO9BzWkj6mtO1FMXkQ==} + engines: {node: '>=18'} + cpu: [x64] + os: [netbsd] - '@ethersproject/pbkdf2@5.8.0': - resolution: {integrity: sha512-wuHiv97BrzCmfEaPbUFpMjlVg/IDkZThp9Ri88BpjRleg4iePJaj2SW8AIyE8cXn5V1tuAaMj6lzvsGJkGWskg==} + '@esbuild/netbsd-x64@0.27.2': + resolution: {integrity: sha512-HwGDZ0VLVBY3Y+Nw0JexZy9o/nUAWq9MlV7cahpaXKW6TOzfVno3y3/M8Ga8u8Yr7GldLOov27xiCnqRZf0tCA==} + engines: {node: '>=18'} + cpu: [x64] + os: [netbsd] - '@ethersproject/properties@5.8.0': - resolution: {integrity: sha512-PYuiEoQ+FMaZZNGrStmN7+lWjlsoufGIHdww7454FIaGdbe/p5rnaCXTr5MtBYl3NkeoVhHZuyzChPeGeKIpQw==} + '@esbuild/openbsd-arm64@0.23.1': + resolution: {integrity: sha512-3x37szhLexNA4bXhLrCC/LImN/YtWis6WXr1VESlfVtVeoFJBRINPJ3f0a/6LV8zpikqoUg4hyXw0sFBt5Cr+Q==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openbsd] - '@ethersproject/providers@5.8.0': - resolution: {integrity: sha512-3Il3oTzEx3o6kzcg9ZzbE+oCZYyY+3Zh83sKkn4s1DZfTUjIegHnN2Cm0kbn9YFy45FDVcuCLLONhU7ny0SsCw==} + '@esbuild/openbsd-arm64@0.25.12': + resolution: {integrity: sha512-fF96T6KsBo/pkQI950FARU9apGNTSlZGsv1jZBAlcLL1MLjLNIWPBkj5NlSz8aAzYKg+eNqknrUJ24QBybeR5A==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openbsd] - '@ethersproject/random@5.8.0': - resolution: {integrity: sha512-E4I5TDl7SVqyg4/kkA/qTfuLWAQGXmSOgYyO01So8hLfwgKvYK5snIlzxJMk72IFdG/7oh8yuSqY2KX7MMwg+A==} + '@esbuild/openbsd-arm64@0.27.2': + resolution: {integrity: sha512-DNIHH2BPQ5551A7oSHD0CKbwIA/Ox7+78/AWkbS5QoRzaqlev2uFayfSxq68EkonB+IKjiuxBFoV8ESJy8bOHA==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openbsd] - '@ethersproject/rlp@5.8.0': - resolution: {integrity: sha512-LqZgAznqDbiEunaUvykH2JAoXTT9NV0Atqk8rQN9nx9SEgThA/WMx5DnW8a9FOufo//6FZOCHZ+XiClzgbqV9Q==} + '@esbuild/openbsd-x64@0.21.5': + resolution: {integrity: sha512-HLNNw99xsvx12lFBUwoT8EVCsSvRNDVxNpjZ7bPn947b8gJPzeHWyNVhFsaerc0n3TsbOINvRP2byTZ5LKezow==} + engines: {node: '>=12'} + cpu: [x64] + os: [openbsd] - '@ethersproject/sha2@5.8.0': - resolution: {integrity: sha512-dDOUrXr9wF/YFltgTBYS0tKslPEKr6AekjqDW2dbn1L1xmjGR+9GiKu4ajxovnrDbwxAKdHjW8jNcwfz8PAz4A==} + '@esbuild/openbsd-x64@0.23.1': + resolution: {integrity: sha512-aY2gMmKmPhxfU+0EdnN+XNtGbjfQgwZj43k8G3fyrDM/UdZww6xrWxmDkuz2eCZchqVeABjV5BpildOrUbBTqA==} + engines: {node: '>=18'} + cpu: [x64] + os: [openbsd] - '@ethersproject/signing-key@5.8.0': - resolution: {integrity: sha512-LrPW2ZxoigFi6U6aVkFN/fa9Yx/+4AtIUe4/HACTvKJdhm0eeb107EVCIQcrLZkxaSIgc/eCrX8Q1GtbH+9n3w==} + '@esbuild/openbsd-x64@0.25.12': + resolution: {integrity: sha512-MZyXUkZHjQxUvzK7rN8DJ3SRmrVrke8ZyRusHlP+kuwqTcfWLyqMOE3sScPPyeIXN/mDJIfGXvcMqCgYKekoQw==} + engines: {node: '>=18'} + cpu: [x64] + os: [openbsd] - '@ethersproject/solidity@5.8.0': - resolution: {integrity: sha512-4CxFeCgmIWamOHwYN9d+QWGxye9qQLilpgTU0XhYs1OahkclF+ewO+3V1U0mvpiuQxm5EHHmv8f7ClVII8EHsA==} + '@esbuild/openbsd-x64@0.27.2': + resolution: {integrity: sha512-/it7w9Nb7+0KFIzjalNJVR5bOzA9Vay+yIPLVHfIQYG/j+j9VTH84aNB8ExGKPU4AzfaEvN9/V4HV+F+vo8OEg==} + engines: {node: '>=18'} + cpu: [x64] + os: [openbsd] - '@ethersproject/strings@5.8.0': - resolution: {integrity: sha512-qWEAk0MAvl0LszjdfnZ2uC8xbR2wdv4cDabyHiBh3Cldq/T8dPH3V4BbBsAYJUeonwD+8afVXld274Ls+Y1xXg==} + '@esbuild/openharmony-arm64@0.25.12': + resolution: {integrity: sha512-rm0YWsqUSRrjncSXGA7Zv78Nbnw4XL6/dzr20cyrQf7ZmRcsovpcRBdhD43Nuk3y7XIoW2OxMVvwuRvk9XdASg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openharmony] - '@ethersproject/transactions@5.8.0': - resolution: {integrity: sha512-UglxSDjByHG0TuU17bDfCemZ3AnKO2vYrL5/2n2oXvKzvb7Cz+W9gOWXKARjp2URVwcWlQlPOEQyAviKwT4AHg==} + '@esbuild/openharmony-arm64@0.27.2': + resolution: {integrity: sha512-LRBbCmiU51IXfeXk59csuX/aSaToeG7w48nMwA6049Y4J4+VbWALAuXcs+qcD04rHDuSCSRKdmY63sruDS5qag==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openharmony] - '@ethersproject/units@5.8.0': - resolution: {integrity: sha512-lxq0CAnc5kMGIiWW4Mr041VT8IhNM+Pn5T3haO74XZWFulk7wH1Gv64HqE96hT4a7iiNMdOCFEBgaxWuk8ETKQ==} + '@esbuild/sunos-x64@0.21.5': + resolution: {integrity: sha512-6+gjmFpfy0BHU5Tpptkuh8+uw3mnrvgs+dSPQXQOv3ekbordwnzTVEb4qnIvQcYXq6gzkyTnoZ9dZG+D4garKg==} + engines: {node: '>=12'} + cpu: [x64] + os: [sunos] - '@ethersproject/wallet@5.8.0': - resolution: {integrity: sha512-G+jnzmgg6UxurVKRKvw27h0kvG75YKXZKdlLYmAHeF32TGUzHkOFd7Zn6QHOTYRFWnfjtSSFjBowKo7vfrXzPA==} + '@esbuild/sunos-x64@0.23.1': + resolution: {integrity: sha512-RBRT2gqEl0IKQABT4XTj78tpk9v7ehp+mazn2HbUeZl1YMdaGAQqhapjGTCe7uw7y0frDi4gS0uHzhvpFuI1sA==} + engines: {node: '>=18'} + cpu: [x64] + os: [sunos] - '@ethersproject/web@5.8.0': - resolution: {integrity: sha512-j7+Ksi/9KfGviws6Qtf9Q7KCqRhpwrYKQPs+JBA/rKVFF/yaWLHJEH3zfVP2plVu+eys0d2DlFmhoQJayFewcw==} + '@esbuild/sunos-x64@0.25.12': + resolution: {integrity: sha512-3wGSCDyuTHQUzt0nV7bocDy72r2lI33QL3gkDNGkod22EsYl04sMf0qLb8luNKTOmgF/eDEDP5BFNwoBKH441w==} + engines: {node: '>=18'} + cpu: [x64] + os: [sunos] - '@ethersproject/wordlists@5.8.0': - resolution: {integrity: sha512-2df9bbXicZws2Sb5S6ET493uJ0Z84Fjr3pC4tu/qlnZERibZCeUVuqdtt+7Tv9xxhUxHoIekIA7avrKUWHrezg==} + '@esbuild/sunos-x64@0.27.2': + resolution: {integrity: sha512-kMtx1yqJHTmqaqHPAzKCAkDaKsffmXkPHThSfRwZGyuqyIeBvf08KSsYXl+abf5HDAPMJIPnbBfXvP2ZC2TfHg==} + engines: {node: '>=18'} + cpu: [x64] + os: [sunos] - '@ganache/ethereum-address@0.1.4': - resolution: {integrity: sha512-sTkU0M9z2nZUzDeHRzzGlW724xhMLXo2LeX1hixbnjHWY1Zg1hkqORywVfl+g5uOO8ht8T0v+34IxNxAhmWlbw==} + '@esbuild/win32-arm64@0.21.5': + resolution: {integrity: sha512-Z0gOTd75VvXqyq7nsl93zwahcTROgqvuAcYDUr+vOv8uHhNSKROyU961kgtCD1e95IqPKSQKH7tBTslnS3tA8A==} + engines: {node: '>=12'} + cpu: [arm64] + os: [win32] - '@ganache/ethereum-options@0.1.4': - resolution: {integrity: sha512-i4l46taoK2yC41FPkcoDlEVoqHS52wcbHPqJtYETRWqpOaoj9hAg/EJIHLb1t6Nhva2CdTO84bG+qlzlTxjAHw==} + '@esbuild/win32-arm64@0.23.1': + resolution: {integrity: sha512-4O+gPR5rEBe2FpKOVyiJ7wNDPA8nGzDuJ6gN4okSA1gEOYZ67N8JPk58tkWtdtPeLz7lBnY6I5L3jdsr3S+A6A==} + engines: {node: '>=18'} + cpu: [arm64] + os: [win32] - '@ganache/ethereum-utils@0.1.4': - resolution: {integrity: sha512-FKXF3zcdDrIoCqovJmHLKZLrJ43234Em2sde/3urUT/10gSgnwlpFmrv2LUMAmSbX3lgZhW/aSs8krGhDevDAg==} + '@esbuild/win32-arm64@0.25.12': + resolution: {integrity: sha512-rMmLrur64A7+DKlnSuwqUdRKyd3UE7oPJZmnljqEptesKM8wx9J8gx5u0+9Pq0fQQW8vqeKebwNXdfOyP+8Bsg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [win32] - '@ganache/options@0.1.4': - resolution: {integrity: sha512-zAe/craqNuPz512XQY33MOAG6Si1Xp0hCvfzkBfj2qkuPcbJCq6W/eQ5MB6SbXHrICsHrZOaelyqjuhSEmjXRw==} + '@esbuild/win32-arm64@0.27.2': + resolution: {integrity: sha512-Yaf78O/B3Kkh+nKABUF++bvJv5Ijoy9AN1ww904rOXZFLWVc5OLOfL56W+C8F9xn5JQZa3UX6m+IktJnIb1Jjg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [win32] - '@ganache/rlp@0.1.4': - resolution: {integrity: sha512-Do3D1H6JmhikB+6rHviGqkrNywou/liVeFiKIpOBLynIpvZhRCgn3SEDxyy/JovcaozTo/BynHumfs5R085MFQ==} + '@esbuild/win32-ia32@0.21.5': + resolution: {integrity: sha512-SWXFF1CL2RVNMaVs+BBClwtfZSvDgtL//G/smwAc5oVK/UPu2Gu9tIaRgFmYFFKrmg3SyAjSrElf0TiJ1v8fYA==} + engines: {node: '>=12'} + cpu: [ia32] + os: [win32] - '@ganache/utils@0.1.4': - resolution: {integrity: sha512-oatUueU3XuXbUbUlkyxeLLH3LzFZ4y5aSkNbx6tjSIhVTPeh+AuBKYt4eQ73FFcTB3nj/gZoslgAh5CN7O369w==} + '@esbuild/win32-ia32@0.23.1': + resolution: {integrity: sha512-BcaL0Vn6QwCwre3Y717nVHZbAa4UBEigzFm6VdsVdT/MbZ38xoj1X9HPkZhbmaBGUD1W8vxAfffbDe8bA6AKnQ==} + engines: {node: '>=18'} + cpu: [ia32] + os: [win32] - '@graphql-tools/merge@8.3.1': - resolution: {integrity: sha512-BMm99mqdNZbEYeTPK3it9r9S6rsZsQKtlqJsSBknAclXq2pGEfOxjcIZi+kBSkHZKPKCRrYDd5vY0+rUmIHVLg==} - peerDependencies: - graphql: ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0 + '@esbuild/win32-ia32@0.25.12': + resolution: {integrity: sha512-HkqnmmBoCbCwxUKKNPBixiWDGCpQGVsrQfJoVGYLPT41XWF8lHuE5N6WhVia2n4o5QK5M4tYr21827fNhi4byQ==} + engines: {node: '>=18'} + cpu: [ia32] + os: [win32] - '@graphql-tools/schema@8.5.1': - resolution: {integrity: sha512-0Esilsh0P/qYcB5DKQpiKeQs/jevzIadNTaT0jeWklPMwNbT7yMX4EqZany7mbeRRlSRwMzNzL5olyFdffHBZg==} - peerDependencies: - graphql: ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0 + '@esbuild/win32-ia32@0.27.2': + resolution: {integrity: sha512-Iuws0kxo4yusk7sw70Xa2E2imZU5HoixzxfGCdxwBdhiDgt9vX9VUCBhqcwY7/uh//78A1hMkkROMJq9l27oLQ==} + engines: {node: '>=18'} + cpu: [ia32] + os: [win32] - '@graphql-tools/utils@8.13.1': - resolution: {integrity: sha512-qIh9yYpdUFmctVqovwMdheVNJqFh+DQNWIhX87FJStfXYnmweBUDATok9fWPleKeFwxnW8IapKmY8m8toJEkAw==} - peerDependencies: - graphql: ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0 + '@esbuild/win32-x64@0.21.5': + resolution: {integrity: sha512-tQd/1efJuzPC6rCFwEvLtci/xNFcTZknmXs98FYDfGE4wP9ClFV98nyKrzJKVPMhdDnjzLhdUyMX4PsQAPjwIw==} + engines: {node: '>=12'} + cpu: [x64] + os: [win32] - '@graphql-tools/utils@8.9.0': - resolution: {integrity: sha512-pjJIWH0XOVnYGXCqej8g/u/tsfV4LvLlj0eATKQu5zwnxd/TiTHq7Cg313qUPTFFHZ3PP5wJ15chYVtLDwaymg==} - peerDependencies: - graphql: ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0 + '@esbuild/win32-x64@0.23.1': + resolution: {integrity: sha512-BHpFFeslkWrXWyUPnbKm+xYYVYruCinGcftSBaa8zoF9hZO4BcSCFUvHVTtzpIY6YzUnYtuEhZ+C9iEXjxnasg==} + engines: {node: '>=18'} + cpu: [x64] + os: [win32] - '@httptoolkit/httpolyglot@2.2.2': - resolution: {integrity: sha512-Mm75bidN/jrUsuhBjHAMoQbmR52zQYi8xr/+0mQYGW+dQelg+sdJR/kGRKKZGeAoPgp/1rrZWJqdohZP0xm18g==} - engines: {node: '>=12.0.0'} + '@esbuild/win32-x64@0.25.12': + resolution: {integrity: sha512-alJC0uCZpTFrSL0CCDjcgleBXPnCrEAhTBILpeAp7M/OFgoqtAetfBzX0xM00MUsVVPpVjlPuMbREqnZCXaTnA==} + engines: {node: '>=18'} + cpu: [x64] + os: [win32] - '@httptoolkit/subscriptions-transport-ws@0.11.2': - resolution: {integrity: sha512-YB+gYYVjgYUeJrGkfS91ABeNWCFU7EVcn9Cflf2UXjsIiPJEI6yPxujPcjKv9wIJpM+33KQW/qVEmc+BdIDK2w==} - peerDependencies: - graphql: ^15.7.2 || ^16.0.0 + '@esbuild/win32-x64@0.27.2': + resolution: {integrity: sha512-sRdU18mcKf7F+YgheI/zGf5alZatMUTKj/jNS6l744f9u3WFu4v7twcUI9vu4mknF4Y9aDlblIie0IM+5xxaqQ==} + engines: {node: '>=18'} + cpu: [x64] + os: [win32] - '@httptoolkit/websocket-stream@6.0.1': - resolution: {integrity: sha512-A0NOZI+Glp3Xgcz6Na7i7o09+/+xm2m0UCU8gdtM2nIv6/cjLmhMZMqehSpTlgbx9omtLmV8LVqOskPEyWnmZQ==} + '@ethereumjs/common@3.2.0': + resolution: {integrity: sha512-pksvzI0VyLgmuEF2FA/JR/4/y6hcPq8OUail3/AvycBaW1d5VSauOZzqGvJ3RTmR4MU35lWE8KseKOsEhrFRBA==} - '@humanfs/core@0.19.1': - resolution: {integrity: sha512-5DyQ4+1JEUzejeK1JGICcideyfUbGixgS9jNgex5nqkW+cY7WZhxBigmieN5Qnw9ZosSNVC9KQKyb+GUaGyKUA==} - engines: {node: '>=18.18.0'} + '@ethereumjs/rlp@4.0.1': + resolution: {integrity: sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==} + engines: {node: '>=14'} + hasBin: true - '@humanfs/core@0.19.2': - resolution: {integrity: sha512-UhXNm+CFMWcbChXywFwkmhqjs3PRCmcSa/hfBgLIb7oQ5HNb1wS0icWsGtSAUNgefHeI+eBrA8I1fxmbHsGdvA==} - engines: {node: '>=18.18.0'} + '@ethereumjs/tx@4.2.0': + resolution: {integrity: sha512-1nc6VO4jtFd172BbSnTnDQVr9IYBFl1y4xPzZdtkrkKIncBCkdbgfdRV+MiTkJYAtTxvV12GRZLqBFT1PNK6Yw==} + engines: {node: '>=14'} - '@humanfs/node@0.16.7': - resolution: {integrity: sha512-/zUx+yOsIrG4Y43Eh2peDeKCxlRt/gET6aHfaKpuq267qXdYDFViVHfMaLyygZOnl0kGWxFIgsBy8QFuTLUXEQ==} - engines: {node: '>=18.18.0'} + '@ethereumjs/util@8.1.0': + resolution: {integrity: sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA==} + engines: {node: '>=14'} - '@humanfs/node@0.16.8': - resolution: {integrity: sha512-gE1eQNZ3R++kTzFUpdGlpmy8kDZD/MLyHqDwqjkVQI0JMdI1D51sy1H958PNXYkM2rAac7e5/CnIKZrHtPh3BQ==} - engines: {node: '>=18.18.0'} + '@ethersproject/abi@5.7.0': + resolution: {integrity: sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==} - '@humanfs/types@0.15.0': - resolution: {integrity: sha512-ZZ1w0aoQkwuUuC7Yf+7sdeaNfqQiiLcSRbfI08oAxqLtpXQr9AIVX7Ay7HLDuiLYAaFPu8oBYNq/QIi9URHJ3Q==} - engines: {node: '>=18.18.0'} + '@ethersproject/abstract-provider@5.7.0': + resolution: {integrity: sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==} + + '@ethersproject/abstract-signer@5.7.0': + resolution: {integrity: sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==} + + '@ethersproject/address@5.7.0': + resolution: {integrity: sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==} + + '@ethersproject/base64@5.7.0': + resolution: {integrity: sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==} + + '@ethersproject/bignumber@5.7.0': + resolution: {integrity: sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==} + + '@ethersproject/bytes@5.7.0': + resolution: {integrity: sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==} + + '@ethersproject/constants@5.7.0': + resolution: {integrity: sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==} + + '@ethersproject/hash@5.7.0': + resolution: {integrity: sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==} + + '@ethersproject/keccak256@5.7.0': + resolution: {integrity: sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==} + + '@ethersproject/logger@5.7.0': + resolution: {integrity: sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==} + + '@ethersproject/networks@5.7.1': + resolution: {integrity: sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==} + + '@ethersproject/properties@5.7.0': + resolution: {integrity: sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==} - '@humanwhocodes/module-importer@1.0.1': - resolution: {integrity: sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==} - engines: {node: '>=12.22'} + '@ethersproject/rlp@5.7.0': + resolution: {integrity: sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==} - '@humanwhocodes/retry@0.4.3': - resolution: {integrity: sha512-bV0Tgo9K4hfPCek+aMAn81RppFKv2ySDQeMoSZuvTASywNTnVJCArCZE2FWqpvIatKu7VMRLWlR1EazvVhDyhQ==} - engines: {node: '>=18.18'} + '@ethersproject/signing-key@5.7.0': + resolution: {integrity: sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==} - '@img/colour@1.1.0': - resolution: {integrity: sha512-Td76q7j57o/tLVdgS746cYARfSyxk8iEfRxewL9h4OMzYhbW4TAcppl0mT4eyqXddh6L/jwoM75mo7ixa/pCeQ==} + '@ethersproject/strings@5.7.0': + resolution: {integrity: sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==} + + '@ethersproject/transactions@5.7.0': + resolution: {integrity: sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==} + + '@ethersproject/web@5.7.1': + resolution: {integrity: sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==} + + '@fastify/busboy@2.1.0': + resolution: {integrity: sha512-+KpH+QxZU7O4675t3mnkQKcZZg56u+K/Ct2K+N2AZYNVK8kyeo/bI18tI8aPm3tvNNRyTWfj6s5tnGNlcbQRsA==} + engines: {node: '>=14'} + + '@fastify/busboy@2.1.1': + resolution: {integrity: sha512-vBZP4NlzfOlerQTnba4aqZoMhE/a9HY7HRqoOPaETQcSQuWEIyZMHGfVu6w9wGtGK5fED5qRs2DteVCjOH60sA==} + engines: {node: '>=14'} + + '@floating-ui/core@1.6.1': + resolution: {integrity: sha512-42UH54oPZHPdRHdw6BgoBD6cg/eVTmVrFcgeRDM3jbO7uxSoipVcmcIGFcA5jmOHO5apcyvBhkSKES3fQJnu7A==} + + '@floating-ui/core@1.7.3': + resolution: {integrity: sha512-sGnvb5dmrJaKEZ+LDIpguvdX3bDlEllmv4/ClQ9awcmCZrlx5jQyyMWFM5kBI+EyNOCDDiKk8il0zeuX3Zlg/w==} + + '@floating-ui/dom@1.1.1': + resolution: {integrity: sha512-TpIO93+DIujg3g7SykEAGZMDtbJRrmnYRCNYSjJlvIbGhBjRSNTLVbNeDQBrzy9qDgUbiWdc7KA0uZHZ2tJmiw==} + + '@floating-ui/dom@1.7.4': + resolution: {integrity: sha512-OOchDgh4F2CchOX94cRVqhvy7b3AFb+/rQXyswmzmGakRfkMgoWVjfnLWkRirfLEfuD4ysVW16eXzwt3jHIzKA==} + + '@floating-ui/react-dom@2.1.6': + resolution: {integrity: sha512-4JX6rEatQEvlmgU80wZyq9RT96HZJa88q8hp0pBd+LrczeDI4o6uA2M+uvxngVHo4Ihr8uibXxH6+70zhAFrVw==} + peerDependencies: + react: '>=16.8.0' + react-dom: '>=16.8.0' + + '@floating-ui/utils@0.2.10': + resolution: {integrity: sha512-aGTxbpbg8/b5JfU1HXSrbH3wXZuLPJcNEcZQFMxLs3oSzgtVu6nFPkbbGGUvBcUjKV2YyB9Wxxabo+HEH9tcRQ==} + + '@floating-ui/utils@0.2.2': + resolution: {integrity: sha512-J4yDIIthosAsRZ5CPYP/jQvUAQtlZTTD/4suA08/FEnlxqW3sKS9iAhgsa9VYLZ6vDHn/ixJgIqRQPotoBjxIw==} + + '@iarna/toml@2.2.5': + resolution: {integrity: sha512-trnsAYxU3xnS1gPHPyU961coFyLkh4gAD/0zQ5mymY4yOZ+CYvsPqUbOFSw0aDM4y0tV7tiFxL/1XfXPNC6IPg==} + + '@iconify-json/simple-icons@1.2.10': + resolution: {integrity: sha512-9OK1dsSjXlH36lhu5n+BlSoXuqFjHUErGLtNdzHpq0vHq4YFBuGYWtZ+vZTHLreRQ8ijPRv/6EsgkV+nf6AReQ==} + + '@iconify/types@2.0.0': + resolution: {integrity: sha512-+wluvCrRhXrhyOmRDJ3q8mux9JkKy5SJ/v8ol2tu4FVjyYvtEzkc/3pK15ET6RKg4b4w4BmTk1+gsCUhf21Ykg==} + + '@iconify/utils@2.1.23': + resolution: {integrity: sha512-YGNbHKM5tyDvdWZ92y2mIkrfvm5Fvhe6WJSkWu7vvOFhMtYDP0casZpoRz0XEHZCrYsR4stdGT3cZ52yp5qZdQ==} + + '@img/colour@1.0.0': + resolution: {integrity: sha512-A5P/LfWGFSl6nsckYtjw9da+19jB8hkJ6ACTGcDfEJ0aE+l2n2El7dsVM7UVHZQ9s2lmYMWlrS21YLy2IR1LUw==} engines: {node: '>=18'} '@img/sharp-darwin-arm64@0.34.5': @@ -2430,6 +2465,14 @@ packages: cpu: [x64] os: [win32] + '@inquirer/confirm@3.1.6': + resolution: {integrity: sha512-Mj4TU29g6Uy+37UtpA8UpEOI2icBfpCwSW1QDtfx60wRhUy90s/kHPif2OXSSvuwDQT1lhAYRWUfkNf9Tecxvg==} + engines: {node: '>=18'} + + '@inquirer/core@8.1.0': + resolution: {integrity: sha512-kfx0SU9nWgGe1f03ao/uXc85SFH1v2w3vQVH7QDGjKxdtJz+7vPitFtG++BTyJMYyYgH8MpXigutcXJeiQwVRw==} + engines: {node: '>=18'} + '@inquirer/external-editor@1.0.3': resolution: {integrity: sha512-RWbSrDiYmO4LbejWY7ttpxczuwQyZLBUyygsA9Nsv95hpzUWwnNTVQmAq3xuh7vNwCp07UTmE5i11XAEExx4RA==} engines: {node: '>=18'} @@ -2439,6 +2482,25 @@ packages: '@types/node': optional: true + '@inquirer/figures@1.0.1': + resolution: {integrity: sha512-mtup3wVKia3ZwULPHcbs4Mor8Voi+iIXEWD7wCNbIO6lYR62oPCTQyrddi5OMYVXHzeCSoneZwJuS8sBvlEwDw==} + engines: {node: '>=18'} + + '@inquirer/type@1.3.1': + resolution: {integrity: sha512-Pe3PFccjPVJV1vtlfVvm9OnlbxqdnP5QcscFEFEnK5quChf1ufZtM0r8mR5ToWHMxZOh0s8o/qp9ANGRTo/DAw==} + engines: {node: '>=18'} + + '@ioredis/commands@1.4.0': + resolution: {integrity: sha512-aFT2yemJJo+TZCmieA7qnYGQooOS7QfNmYrzGtsYd3g9j5iDP8AimYYAesf79ohjbLG12XxC4nG5DyEnC88AsQ==} + + '@isaacs/balanced-match@4.0.1': + resolution: {integrity: sha512-yzMTt9lEb8Gv7zRioUilSglI0c0smZ9k5D65677DLWLtWJaXIS3CqcGyUFByYKlnUj6TkjLVs54fBl6+TiGQDQ==} + engines: {node: 20 || >=22} + + '@isaacs/brace-expansion@5.0.0': + resolution: {integrity: sha512-ZT55BDLV0yv0RBm2czMiZ+SqCGO7AvmOM3G/w2xhVPH+te0aKgFjmBvGlL1dH+ql2tgGO3MVrbb3jCKyvpgnxA==} + engines: {node: 20 || >=22} + '@isaacs/cliui@8.0.2': resolution: {integrity: sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==} engines: {node: '>=12'} @@ -2447,118 +2509,238 @@ packages: resolution: {integrity: sha512-wgm9Ehl2jpeqP3zw/7mo3kRHFp5MEDhqAdwy1fTGkHAwnkGOVsgpvQhL8B5n1qlb01jV3n/bI0ZfZp5lWA1k4w==} engines: {node: '>=18.0.0'} - '@istanbuljs/load-nyc-config@1.1.0': - resolution: {integrity: sha512-VjeHSlIzpv/NyD3N0YuHfXOPDIixcA1q2ZV98wsMqcYlPmv2n3Yb2lYP9XMElnaFVXg5A7YLTeLu6V84uQDjmQ==} - engines: {node: '>=8'} - - '@istanbuljs/nyc-config-typescript@1.0.2': - resolution: {integrity: sha512-iKGIyMoyJuFnJRSVTZ78POIRvNnwZaWIf8vG4ZS3rQq58MMDrqEX2nnzx0R28V2X8JvmKYiqY9FP2hlJsm8A0w==} - engines: {node: '>=8'} - peerDependencies: - nyc: '>=15' - - '@istanbuljs/schema@0.1.6': - resolution: {integrity: sha512-+Sg6GCR/wy1oSmQDFq4LQDAhm3ETKnorxN+y5nbLULOR3P0c14f2Wurzj3/xqPXtasLFfHd5iRFQ7AJt4KH2cw==} + '@istanbuljs/schema@0.1.3': + resolution: {integrity: sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA==} engines: {node: '>=8'} '@jridgewell/gen-mapping@0.3.13': resolution: {integrity: sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA==} + '@jridgewell/gen-mapping@0.3.3': + resolution: {integrity: sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==} + engines: {node: '>=6.0.0'} + + '@jridgewell/gen-mapping@0.3.5': + resolution: {integrity: sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==} + engines: {node: '>=6.0.0'} + '@jridgewell/remapping@2.3.5': resolution: {integrity: sha512-LI9u/+laYG4Ds1TDKSJW2YPrIlcVYOwi2fUC6xB43lueCjgxV4lffOCZCtYFiH6TNOX+tQKXx97T4IKHbhyHEQ==} + '@jridgewell/resolve-uri@3.1.0': + resolution: {integrity: sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==} + engines: {node: '>=6.0.0'} + '@jridgewell/resolve-uri@3.1.2': resolution: {integrity: sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==} engines: {node: '>=6.0.0'} + '@jridgewell/set-array@1.1.2': + resolution: {integrity: sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==} + engines: {node: '>=6.0.0'} + + '@jridgewell/set-array@1.2.1': + resolution: {integrity: sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==} + engines: {node: '>=6.0.0'} + + '@jridgewell/source-map@0.3.11': + resolution: {integrity: sha512-ZMp1V8ZFcPG5dIWnQLr3NSI1MiCU7UETdS/A0G8V/XWHvJv3ZsFqutJn1Y5RPmAPX6F3BiE397OqveU/9NCuIA==} + + '@jridgewell/sourcemap-codec@1.4.14': + resolution: {integrity: sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==} + + '@jridgewell/sourcemap-codec@1.4.15': + resolution: {integrity: sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==} + + '@jridgewell/sourcemap-codec@1.5.0': + resolution: {integrity: sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==} + '@jridgewell/sourcemap-codec@1.5.5': resolution: {integrity: sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==} + '@jridgewell/trace-mapping@0.3.17': + resolution: {integrity: sha512-MCNzAp77qzKca9+W/+I0+sEpaUnZoeasnghNeVc41VZCEKaCH73Vq3BZZ/SzWIgrqE4H4ceI+p+b6C0mHf9T4g==} + + '@jridgewell/trace-mapping@0.3.25': + resolution: {integrity: sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==} + '@jridgewell/trace-mapping@0.3.31': resolution: {integrity: sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==} '@jridgewell/trace-mapping@0.3.9': resolution: {integrity: sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==} + '@kwsites/file-exists@1.1.1': + resolution: {integrity: sha512-m9/5YGR18lIwxSFDwfE3oA7bWuq9kdau6ugN4H2rJeyhFQZcG9AgSHkQtSD15a8WvTgfz9aikZMrKPHvbpqFiw==} + + '@kwsites/promise-deferred@1.1.1': + resolution: {integrity: sha512-GaHYm+c0O9MjZRu0ongGBRbinu8gVAMd2UZjji6jVmqKtZluZnptXGWhz1E8j8D2HJ3f/yMxKAUC0b+57wncIw==} + + '@lit-labs/ssr-dom-shim@1.3.0': + resolution: {integrity: sha512-nQIWonJ6eFAvUUrSlwyHDm/aE8PBDu5kRpL0vHMg6K8fK3Diq1xdPjTnsJSwxABhaZ+5eBi1btQB5ShUTKo4nQ==} + + '@lit/reactive-element@2.1.0': + resolution: {integrity: sha512-L2qyoZSQClcBmq0qajBVbhYEcG6iK0XfLn66ifLe/RfC0/ihpc+pl0Wdn8bJ8o+hj38cG0fGXRgSS20MuXn7qA==} + '@manypkg/find-root@1.1.0': resolution: {integrity: sha512-mki5uBvhHzO8kYYix/WRy2WX8S3B5wdVSc9D6KcU5lQNglP2yt58/VfLuAK49glRXChosY8ap2oJ1qgma3GUVA==} '@manypkg/get-packages@1.1.3': resolution: {integrity: sha512-fo+QhuU3qE/2TQMQmbVMqaQ6EWbMhi4ABWP+O4AM1NqPBuy0OrApV5LO6BrrgnhtAHS2NH6RrVk9OL181tTi8A==} - '@metamask/eth-json-rpc-infura@6.0.0': - resolution: {integrity: sha512-OJImmnGxWEPYpra1o9UAMCJUNA8UJ0hdiJ77i33v5h12n9/DCNh4fYpbuL/GZdHNWwCDjegmxdgJNwlScOYPfA==} - engines: {node: '>=12.0.0'} + '@mapbox/node-pre-gyp@2.0.3': + resolution: {integrity: sha512-uwPAhccfFJlsfCxMYTwOdVfOz3xqyj8xYL3zJj8f0pb30tLohnnFPhLuqp4/qoEz8sNxe4SESZedcBojRefIzg==} + engines: {node: '>=18'} + hasBin: true + + '@metamask/eth-json-rpc-provider@1.0.1': + resolution: {integrity: sha512-whiUMPlAOrVGmX8aKYVPvlKyG4CpQXiNNyt74vE1xb5sPvmx5oA7B/kOi/JdBvhGQq97U1/AVdXEdk2zkP8qyA==} + engines: {node: '>=14.0.0'} '@metamask/eth-sig-util@4.0.1': resolution: {integrity: sha512-tghyZKLHZjcdlDqCA3gNZmLeR0XvOE9U1qoQO9ohyAZT6Pya+H9vkBPcsyXytmYLNgVoin7CKCmweo/R43V+tQ==} engines: {node: '>=12.0.0'} - '@metamask/eth-sig-util@5.1.0': - resolution: {integrity: sha512-mlgziIHYlA9pi/XZerChqg4NocdOgBPB9NmxgXWQO2U2hH8RGOJQrz6j/AIKkYxgCMIE2PY000+joOwXfzeTDQ==} - engines: {node: '>=14.0.0'} + '@metamask/json-rpc-engine@7.3.3': + resolution: {integrity: sha512-dwZPq8wx9yV3IX2caLi9q9xZBw2XeIoYqdyihDDDpuHVCEiqadJLwqM3zy+uwf6F1QYQ65A8aOMQg1Uw7LMLNg==} + engines: {node: '>=16.0.0'} + + '@metamask/json-rpc-engine@8.0.2': + resolution: {integrity: sha512-IoQPmql8q7ABLruW7i4EYVHWUbF74yrp63bRuXV5Zf9BQwcn5H9Ww1eLtROYvI1bUXwOiHZ6qT5CWTrDc/t/AA==} + engines: {node: '>=16.0.0'} + + '@metamask/json-rpc-middleware-stream@7.0.2': + resolution: {integrity: sha512-yUdzsJK04Ev98Ck4D7lmRNQ8FPioXYhEUZOMS01LXW8qTvPGiRVXmVltj2p4wrLkh0vW7u6nv0mNl5xzC5Qmfg==} + engines: {node: '>=16.0.0'} + + '@metamask/object-multiplex@2.1.0': + resolution: {integrity: sha512-4vKIiv0DQxljcXwfpnbsXcfa5glMj5Zg9mqn4xpIWqkv6uJ2ma5/GtUfLFSxhlxnR8asRMv8dDmWya1Tc1sDFA==} + engines: {node: ^16.20 || ^18.16 || >=20} + + '@metamask/onboarding@1.0.1': + resolution: {integrity: sha512-FqHhAsCI+Vacx2qa5mAFcWNSrTcVGMNjzxVgaX8ECSny/BJ9/vgXP9V7WF/8vb9DltPeQkxr+Fnfmm6GHfmdTQ==} + + '@metamask/providers@16.1.0': + resolution: {integrity: sha512-znVCvux30+3SaUwcUGaSf+pUckzT5ukPRpcBmy+muBLC0yaWnBcvDqGfcsw6CBIenUdFrVoAFa8B6jsuCY/a+g==} + engines: {node: ^18.18 || >=20} + + '@metamask/rpc-errors@6.4.0': + resolution: {integrity: sha512-1ugFO1UoirU2esS3juZanS/Fo8C8XYocCuBpfZI5N7ECtoG+zu0wF+uWZASik6CkO6w9n/Iebt4iI4pT0vptpg==} + engines: {node: '>=16.0.0'} '@metamask/safe-event-emitter@2.0.0': resolution: {integrity: sha512-/kSXhY692qiV1MXu6EeOZvg5nECLclxNXcKCxJ3cXQgYuRymRHpdx/t7JXfsK+JLjwA1e1c1/SBrlQYpusC29Q==} - '@metamask/utils@3.6.0': - resolution: {integrity: sha512-9cIRrfkWvHblSiNDVXsjivqa9Ak0RYo/1H6tqTqTbAx+oBK2Sva0lWDHxGchOqA7bySGUJKAWSNJvH6gdHZ0gQ==} + '@metamask/safe-event-emitter@3.0.0': + resolution: {integrity: sha512-j6Z47VOmVyGMlnKXZmL0fyvWfEYtKWCA9yGZkU3FCsGZUT5lHGmvaV9JA5F2Y+010y7+ROtR3WMXIkvl/nVzqQ==} + engines: {node: '>=12.0.0'} + + '@metamask/safe-event-emitter@3.1.2': + resolution: {integrity: sha512-5yb2gMI1BDm0JybZezeoX/3XhPDOtTbcFvpTXM9kxsoZjPZFh4XciqRbpD6N86HYZqWDhEaKUDuOyR0sQHEjMA==} + engines: {node: '>=12.0.0'} + + '@metamask/sdk-analytics@0.0.5': + resolution: {integrity: sha512-fDah+keS1RjSUlC8GmYXvx6Y26s3Ax1U9hGpWb6GSY5SAdmTSIqp2CvYy6yW0WgLhnYhW+6xERuD0eVqV63QIQ==} + + '@metamask/sdk-communication-layer@0.33.1': + resolution: {integrity: sha512-0bI9hkysxcfbZ/lk0T2+aKVo1j0ynQVTuB3sJ5ssPWlz+Z3VwveCkP1O7EVu1tsVVCb0YV5WxK9zmURu2FIiaA==} + peerDependencies: + cross-fetch: ^4.0.0 + eciesjs: '*' + eventemitter2: ^6.4.9 + readable-stream: ^3.6.2 + socket.io-client: ^4.5.1 + + '@metamask/sdk-install-modal-web@0.32.1': + resolution: {integrity: sha512-MGmAo6qSjf1tuYXhCu2EZLftq+DSt5Z7fsIKr2P+lDgdTPWgLfZB1tJKzNcwKKOdf6q9Qmmxn7lJuI/gq5LrKw==} + + '@metamask/sdk@0.33.1': + resolution: {integrity: sha512-1mcOQVGr9rSrVcbKPNVzbZ8eCl1K0FATsYH3WJ/MH4WcZDWGECWrXJPNMZoEAkLxWiMe8jOQBumg2pmcDa9zpQ==} + + '@metamask/superstruct@3.2.1': + resolution: {integrity: sha512-fLgJnDOXFmuVlB38rUN5SmU7hAFQcCjrg3Vrxz67KTY7YHFnSNEKvX4avmEBdOI0yTCxZjwMCFEqsC8k2+Wd3g==} + engines: {node: '>=16.0.0'} + + '@metamask/utils@5.0.2': + resolution: {integrity: sha512-yfmE79bRQtnMzarnKfX7AEJBwFTxvTyw3nBQlu/5rmGXrjAeAMltoGxO62TFurxrQAFMNa/fEjIHNvungZp0+g==} engines: {node: '>=14.0.0'} - '@next/env@16.2.4': - resolution: {integrity: sha512-dKkkOzOSwFYe5RX6y26fZgkSpVAlIOJKQHIiydQcrWH6y/97+RceSOAdjZ14Qa3zLduVUy0TXcn+EiM6t4rPgw==} + '@metamask/utils@8.5.0': + resolution: {integrity: sha512-I6bkduevXb72TIM9q2LRO63JSsF9EXduh3sBr9oybNX2hNNpr/j1tEjXrsG0Uabm4MJ1xkGAQEMwifvKZIkyxQ==} + engines: {node: '>=16.0.0'} + + '@metamask/utils@9.3.0': + resolution: {integrity: sha512-w8CVbdkDrVXFJbfBSlDfafDR6BAkpDmv1bC1UJVCoVny5tW2RKAdn9i68Xf7asYT4TnUhl/hN4zfUiKQq9II4g==} + engines: {node: '>=16.0.0'} + + '@mswjs/interceptors@0.35.9': + resolution: {integrity: sha512-SSnyl/4ni/2ViHKkiZb8eajA/eN1DNFaHjhGiLUdZvDz6PKF4COSf/17xqSz64nOo2Ia29SA6B2KNCsyCbVmaQ==} + engines: {node: '>=18'} + + '@napi-rs/wasm-runtime@1.1.0': + resolution: {integrity: sha512-Fq6DJW+Bb5jaWE69/qOE0D1TUN9+6uWhCeZpdnSBk14pjLcCWR7Q8n49PTSPHazM37JqrsdpEthXy2xn6jWWiA==} + + '@napi-rs/wasm-runtime@1.1.1': + resolution: {integrity: sha512-p64ah1M1ld8xjWv3qbvFwHiFVWrq1yFvV4f7w+mzaqiR4IlSgkqhcRdHwsGgomwzBH51sRY4NEowLxnaBjcW/A==} + + '@next/bundle-analyzer@15.3.3': + resolution: {integrity: sha512-9gddnjACK6yOa5IkmeFyzcwZh2rscsb6ZspTd7tymPYKQM96fJuKjn9HrRtPNKiMm7ExKNadAJqREmHdBgHZ9A==} - '@next/eslint-plugin-next@15.5.9': - resolution: {integrity: sha512-kUzXx0iFiXw27cQAViE1yKWnz/nF8JzRmwgMRTMh8qMY90crNsdXJRh2e+R0vBpFR3kk1yvAR7wev7+fCCb79Q==} + '@next/env@15.4.10': + resolution: {integrity: sha512-knhmoJ0Vv7VRf6pZEPSnciUG1S4bIhWx+qTYBW/AjxEtlzsiNORPk8sFDCEvqLfmKuey56UB9FL1UdHEV3uBrg==} - '@next/swc-darwin-arm64@16.2.4': - resolution: {integrity: sha512-OXTFFox5EKN1Ym08vfrz+OXxmCcEjT4SFMbNRsWZE99dMqt2Kcusl5MqPXcW232RYkMLQTy0hqgAMEsfEd/l2A==} + '@next/swc-darwin-arm64@15.4.8': + resolution: {integrity: sha512-Pf6zXp7yyQEn7sqMxur6+kYcywx5up1J849psyET7/8pG2gQTVMjU3NzgIt8SeEP5to3If/SaWmaA6H6ysBr1A==} engines: {node: '>= 10'} cpu: [arm64] os: [darwin] - '@next/swc-darwin-x64@16.2.4': - resolution: {integrity: sha512-XhpVnUfmYWvD3YrXu55XdcAkQtOnvaI6wtQa8fuF5fGoKoxIUZ0kWPtcOfqJEWngFF/lOS9l3+O9CcownhiQxQ==} + '@next/swc-darwin-x64@15.4.8': + resolution: {integrity: sha512-xla6AOfz68a6kq3gRQccWEvFC/VRGJmA/QuSLENSO7CZX5WIEkSz7r1FdXUjtGCQ1c2M+ndUAH7opdfLK1PQbw==} engines: {node: '>= 10'} cpu: [x64] os: [darwin] - '@next/swc-linux-arm64-gnu@16.2.4': - resolution: {integrity: sha512-Mx/tjlNA3G8kg14QvuGAJ4xBwPk1tUHq56JxZ8CXnZwz1Etz714soCEzGQQzVMz4bEnGPowzkV6Xrp6wAkEWOQ==} + '@next/swc-linux-arm64-gnu@15.4.8': + resolution: {integrity: sha512-y3fmp+1Px/SJD+5ntve5QLZnGLycsxsVPkTzAc3zUiXYSOlTPqT8ynfmt6tt4fSo1tAhDPmryXpYKEAcoAPDJw==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] - '@next/swc-linux-arm64-musl@16.2.4': - resolution: {integrity: sha512-iVMMp14514u7Nup2umQS03nT/bN9HurK8ufylC3FZNykrwjtx7V1A7+4kvhbDSCeonTVqV3Txnv0Lu+m2oDXNg==} + '@next/swc-linux-arm64-musl@15.4.8': + resolution: {integrity: sha512-DX/L8VHzrr1CfwaVjBQr3GWCqNNFgyWJbeQ10Lx/phzbQo3JNAxUok1DZ8JHRGcL6PgMRgj6HylnLNndxn4Z6A==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] - '@next/swc-linux-x64-gnu@16.2.4': - resolution: {integrity: sha512-EZOvm1aQWgnI/N/xcWOlnS3RQBk0VtVav5Zo7n4p0A7UKyTDx047k8opDbXgBpHl4CulRqRfbw3QrX2w5UOXMQ==} + '@next/swc-linux-x64-gnu@15.4.8': + resolution: {integrity: sha512-9fLAAXKAL3xEIFdKdzG5rUSvSiZTLLTCc6JKq1z04DR4zY7DbAPcRvNm3K1inVhTiQCs19ZRAgUerHiVKMZZIA==} engines: {node: '>= 10'} cpu: [x64] os: [linux] - '@next/swc-linux-x64-musl@16.2.4': - resolution: {integrity: sha512-h9FxsngCm9cTBf71AR4fGznDEDx1hS7+kSEiIRjq5kO1oXWm07DxVGZjCvk0SGx7TSjlUqhI8oOyz7NfwAdPoA==} + '@next/swc-linux-x64-musl@15.4.8': + resolution: {integrity: sha512-s45V7nfb5g7dbS7JK6XZDcapicVrMMvX2uYgOHP16QuKH/JA285oy6HcxlKqwUNaFY/UC6EvQ8QZUOo19cBKSA==} engines: {node: '>= 10'} cpu: [x64] os: [linux] - '@next/swc-win32-arm64-msvc@16.2.4': - resolution: {integrity: sha512-3NdJV5OXMSOeJYijX+bjaLge3mJBlh4ybydbT4GFoB/2hAojWHtMhl3CYlYoMrjPuodp0nzFVi4Tj2+WaMg+Ow==} + '@next/swc-win32-arm64-msvc@15.4.8': + resolution: {integrity: sha512-KjgeQyOAq7t/HzAJcWPGA8X+4WY03uSCZ2Ekk98S9OgCFsb6lfBE3dbUzUuEQAN2THbwYgFfxX2yFTCMm8Kehw==} engines: {node: '>= 10'} cpu: [arm64] os: [win32] - '@next/swc-win32-x64-msvc@16.2.4': - resolution: {integrity: sha512-kMVGgsqhO5YTYODD9IPGGhA6iprWidQckK3LmPeW08PIFENRmgfb4MjXHO+p//d+ts2rpjvK5gXWzXSMrPl9cw==} + '@next/swc-win32-x64-msvc@15.4.8': + resolution: {integrity: sha512-Exsmf/+42fWVnLMaZHzshukTBxZrSwuuLKFvqhGHJ+mC1AokqieLY/XzAl3jc/CqhXLqLY3RRjkKJ9YnLPcRWg==} engines: {node: '>= 10'} cpu: [x64] os: [win32] + '@noble/ciphers@1.2.1': + resolution: {integrity: sha512-rONPWMC7PeExE077uLE4oqWrZ1IvAfz3oH9LibVAcVCopJiA9R62uavnbEzdkVmJYI6M6Zgkbeb07+tWjlq2XA==} + engines: {node: ^14.21.3 || >=16} + '@noble/ciphers@1.3.0': resolution: {integrity: sha512-2I0gnIVPtfnMw9ee9h1dJG7tp81+8Ob3OJb3Mv37rx5L40/b0i7djjCVvGOVqc9AEIQyvyu1i6ypKdFw8R8gQw==} engines: {node: ^14.21.3 || >=16} @@ -2566,17 +2748,32 @@ packages: '@noble/curves@1.2.0': resolution: {integrity: sha512-oYclrNgRaM9SsBUBVbb8M6DTV7ZHRTKugureoYEncY5c65HOmRzvSiTE3y5CYaPYJA/GVkrhXEoF0M3Ya9PMnw==} + '@noble/curves@1.4.0': + resolution: {integrity: sha512-p+4cb332SFCrReJkCYe8Xzm0OWi4Jji5jVdIZRL/PmacmDkFNw6MrrV+gGpiPxLHbV+zKFRywUWbaseT+tZRXg==} + '@noble/curves@1.4.2': resolution: {integrity: sha512-TavHr8qycMChk8UwMld0ZDRvatedkzWfH8IiaeGCfymOP5i0hSCozz9vHOL0nkwk7HRMlFnAiKpS2jrUmSybcw==} - '@noble/curves@1.8.2': - resolution: {integrity: sha512-vnI7V6lFNe0tLAuJMu+2sX+FcL14TaCWy1qiczg1VwRmPrpQCdq5ESXQMqUc2tluRNf6irBXrWbl1mGN8uaU/g==} + '@noble/curves@1.8.0': + resolution: {integrity: sha512-j84kjAbzEnQHaSIhRPUmB3/eVXu2k3dKPl2LOrR8fSOIL+89U+7lV117EWHtq/GHM3ReGHM46iRBdZfpc4HRUQ==} + engines: {node: ^14.21.3 || >=16} + + '@noble/curves@1.8.1': + resolution: {integrity: sha512-warwspo+UYUPep0Q+vtdVB4Ugn8GGQj8iyB3gnRWsztmUHTI3S1nhdiWNsPUGL0vud7JlRRk1XEu7Lq1KGTnMQ==} engines: {node: ^14.21.3 || >=16} '@noble/curves@1.9.1': resolution: {integrity: sha512-k11yZxZg+t+gWvBbIswW0yoJlu8cHOC7dhunwOzoWH/mXGBiYyR4YY6hAEK/3EUs4UpB8la1RfdRpeGsFHkWsA==} engines: {node: ^14.21.3 || >=16} + '@noble/curves@1.9.2': + resolution: {integrity: sha512-HxngEd2XUcg9xi20JkwlLCtYwfoFw4JGkuZpT+WlsPD4gB/cxkvTD8fSsoAnphGZhFdZYKeQIPCuFlWPm1uE0g==} + engines: {node: ^14.21.3 || >=16} + + '@noble/curves@1.9.7': + resolution: {integrity: sha512-gbKGcRUYIjA3/zCCNaWDciTMFI0dCkvou3TL8Zmy5Nc7sJ47a0jtOeZoTaMxkuqRo9cRhjOdZJXegxYE5FN/xw==} + engines: {node: ^14.21.3 || >=16} + '@noble/hashes@1.2.0': resolution: {integrity: sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ==} @@ -2588,8 +2785,16 @@ packages: resolution: {integrity: sha512-V1JJ1WTRUqHHrOSh597hURcMqVKVGL/ea3kv0gSnEdsEZ0/+VyPghM1lMNGc00z7CIQorSvbKpuJkxvuHbvdbg==} engines: {node: '>= 16'} - '@noble/hashes@1.7.2': - resolution: {integrity: sha512-biZ0NUSxyjLLqo6KxEJ1b+C2NAx0wtDoFvCaXHGgUkeHzf3Xc1xKumFKREuT7f7DARNZ/slvYUwFG6B0f2b6hQ==} + '@noble/hashes@1.5.0': + resolution: {integrity: sha512-1j6kQFb7QRru7eKN3ZDvRcP13rugwdxZqCjbiAVZfIJwgj2A65UmT4TgARXGlXgnRkORLTDTrO19ZErt7+QXgA==} + engines: {node: ^14.21.3 || >=16} + + '@noble/hashes@1.7.0': + resolution: {integrity: sha512-HXydb0DgzTpDPwbVeDGCG1gIu7X6+AuU6Zl6av/E/KG8LMsvPntvq+w17CHRpKBmN6Ybdrt1eP3k4cj8DJa78w==} + engines: {node: ^14.21.3 || >=16} + + '@noble/hashes@1.7.1': + resolution: {integrity: sha512-B8XBPsn4vT/KJAGqDzbwztd+6Yte3P4V7iafm24bxgDe/mlRuK6xmWPuCNrKt2vDafZ8MfJLlchDG/vYafQEjQ==} engines: {node: ^14.21.3 || >=16} '@noble/hashes@1.8.0': @@ -2599,9 +2804,6 @@ packages: '@noble/secp256k1@1.7.1': resolution: {integrity: sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw==} - '@nodable/entities@2.1.0': - resolution: {integrity: sha512-nyT7T3nbMyBI/lvr6L5TyWbFJAI9FTgVRakNoBqCD+PmID8DzFrrNdLLtHMwMszOtqZa8PAOV24ZqDnQrhQINA==} - '@nodelib/fs.scandir@2.1.5': resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==} engines: {node: '>= 8'} @@ -2614,10237 +2816,15118 @@ packages: resolution: {integrity: sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==} engines: {node: '>= 8'} - '@nomicfoundation/edr-darwin-arm64@0.12.0-next.23': - resolution: {integrity: sha512-Amh7mRoDzZyJJ4efqoePqdoZOzharmSOttZuJDlVE5yy07BoE8hL6ZRpa5fNYn0LCqn/KoWs8OHANWxhKDGhvQ==} - engines: {node: '>= 20'} + '@nomicfoundation/edr-darwin-arm64@0.3.7': + resolution: {integrity: sha512-6tK9Lv/lSfyBvpEQ4nsTfgxyDT1y1Uv/x8Wa+aB+E8qGo3ToexQ1BMVjxJk6PChXCDOWxB3B4KhqaZFjdhl3Ow==} + engines: {node: '>= 18'} + cpu: [arm64] + os: [darwin] - '@nomicfoundation/edr-darwin-x64@0.12.0-next.23': - resolution: {integrity: sha512-9wn489FIQm7m0UCD+HhktjWx6vskZzeZD9oDc2k9ZvbBzdXwPp5tiDqUBJ+eQpByAzCDfteAJwRn2lQCE0U+Iw==} - engines: {node: '>= 20'} + '@nomicfoundation/edr-darwin-x64@0.3.7': + resolution: {integrity: sha512-1RrQ/1JPwxrYO69e0tglFv5H+ggour5Ii3bb727+yBpBShrxtOTQ7fZyfxA5h62LCN+0Z9wYOPeQ7XFcVurMaQ==} + engines: {node: '>= 18'} + cpu: [x64] + os: [darwin] - '@nomicfoundation/edr-linux-arm64-gnu@0.12.0-next.23': - resolution: {integrity: sha512-nlk5EejSzEUfEngv0Jkhqq3/wINIfF2ED9wAofc22w/V1DV99ASh9l3/e/MIHOQFecIZ9MDqt0Em9/oDyB1Uew==} - engines: {node: '>= 20'} + '@nomicfoundation/edr-linux-arm64-gnu@0.3.7': + resolution: {integrity: sha512-ds/CKlBoVXIihjhflhgPn13EdKWed6r5bgvMs/YwRqT5wldQAQJZWAfA2+nYm0Yi2gMGh1RUpBcfkyl4pq7G+g==} + engines: {node: '>= 18'} + cpu: [arm64] + os: [linux] - '@nomicfoundation/edr-linux-arm64-musl@0.12.0-next.23': - resolution: {integrity: sha512-SJuPBp3Rc6vM92UtVTUxZQ/QlLhLfwTftt2XUiYohmGKB3RjGzpgduEFMCA0LEnucUckU6UHrJNFHiDm77C4PQ==} - engines: {node: '>= 20'} + '@nomicfoundation/edr-linux-arm64-musl@0.3.7': + resolution: {integrity: sha512-e29udiRaPujhLkM3+R6ju7QISrcyOqpcaxb2FsDWBkuD7H8uU9JPZEyyUIpEp5uIY0Jh1eEJPKZKIXQmQAEAuw==} + engines: {node: '>= 18'} + cpu: [arm64] + os: [linux] - '@nomicfoundation/edr-linux-x64-gnu@0.12.0-next.23': - resolution: {integrity: sha512-NU+Qs3u7Qt6t3bJFdmmjd5CsvgI2bPPzO31KifM2Ez96/jsXYho5debtTQnimlb5NAqiHTSlxjh/F8ROcptmeQ==} - engines: {node: '>= 20'} + '@nomicfoundation/edr-linux-x64-gnu@0.3.7': + resolution: {integrity: sha512-/xkjmTyv+bbJ4akBCW0qzFKxPOV4AqLOmqurov+s9umHb16oOv72osSa3SdzJED2gHDaKmpMITT4crxbar4Axg==} + engines: {node: '>= 18'} + cpu: [x64] + os: [linux] - '@nomicfoundation/edr-linux-x64-musl@0.12.0-next.23': - resolution: {integrity: sha512-F78fZA2h6/ssiCSZOovlgIu0dUeI7ItKPsDDF3UUlIibef052GCXmliMinC90jVPbrjUADMd1BUwjfI0Z8OllQ==} - engines: {node: '>= 20'} + '@nomicfoundation/edr-linux-x64-musl@0.3.7': + resolution: {integrity: sha512-QwBP9xlmsbf/ldZDGLcE4QiAb8Zt46E/+WLpxHBATFhGa7MrpJh6Zse+h2VlrT/SYLPbh2cpHgSmoSlqVxWG9g==} + engines: {node: '>= 18'} + cpu: [x64] + os: [linux] - '@nomicfoundation/edr-win32-x64-msvc@0.12.0-next.23': - resolution: {integrity: sha512-IfJZQJn7d/YyqhmguBIGoCKjE9dKjbu6V6iNEPApfwf5JyyjHYyyfkLU4rf7hygj57bfH4sl1jtQ6r8HnT62lw==} - engines: {node: '>= 20'} + '@nomicfoundation/edr-win32-x64-msvc@0.3.7': + resolution: {integrity: sha512-j/80DEnkxrF2ewdbk/gQ2EOPvgF0XSsg8D0o4+6cKhUVAW6XwtWKzIphNL6dyD2YaWEPgIrNvqiJK/aln0ww4Q==} + engines: {node: '>= 18'} + cpu: [x64] + os: [win32] - '@nomicfoundation/edr@0.12.0-next.23': - resolution: {integrity: sha512-F2/6HZh8Q9RsgkOIkRrckldbhPjIZY7d4mT9LYuW68miwGQ5l7CkAgcz9fRRiurA0+YJhtsbx/EyrD9DmX9BOw==} - engines: {node: '>= 20'} + '@nomicfoundation/edr@0.3.7': + resolution: {integrity: sha512-v2JFWnFKRsnOa6PDUrD+sr8amcdhxnG/YbL7LzmgRGU1odWEyOF4/EwNeUajQr4ZNKVWrYnJ6XjydXtUge5OBQ==} + engines: {node: '>= 18'} - '@nomicfoundation/hardhat-errors@3.0.11': - resolution: {integrity: sha512-XEKplQ+FhZD1PgIGSj62scoqB/y+uG8x+V+U68m1a+4L1I46y4/gZQGIuMLkRZeqhPHsLle6ykDB+vn8qtwqzw==} + '@nomicfoundation/ethereumjs-common@4.0.4': + resolution: {integrity: sha512-9Rgb658lcWsjiicr5GzNCjI1llow/7r0k50dLL95OJ+6iZJcVbi15r3Y0xh2cIO+zgX0WIHcbzIu6FeQf9KPrg==} - '@nomicfoundation/hardhat-ethers@3.1.3': - resolution: {integrity: sha512-208JcDeVIl+7Wu3MhFUUtiA8TJ7r2Rn3Wr+lSx9PfsDTKkbsAsWPY6N6wQ4mtzDv0/pB9nIbJhkjoHe1EsgNsA==} - peerDependencies: - ethers: ^6.14.0 - hardhat: ^2.28.0 + '@nomicfoundation/ethereumjs-rlp@5.0.4': + resolution: {integrity: sha512-8H1S3s8F6QueOc/X92SdrA4RDenpiAEqMg5vJH99kcQaCy/a3Q6fgseo75mgWlbanGJXSlAPtnCeG9jvfTYXlw==} + engines: {node: '>=18'} + hasBin: true - '@nomicfoundation/hardhat-ethers@4.0.9': - resolution: {integrity: sha512-0P6A2UeZjJQOf5xa9i8kkOf2LZ5C9kmLkYgLxXn67y7Ajd8+GOvKo4WZamIS9znRzALmoUH5Q5QLGs/iY2fXRA==} + '@nomicfoundation/ethereumjs-tx@5.0.4': + resolution: {integrity: sha512-Xjv8wAKJGMrP1f0n2PeyfFCCojHd7iS3s/Ab7qzF1S64kxZ8Z22LCMynArYsVqiFx6rzYy548HNVEyI+AYN/kw==} + engines: {node: '>=18'} peerDependencies: - hardhat: ^3.4.0 + c-kzg: ^2.1.2 + peerDependenciesMeta: + c-kzg: + optional: true - '@nomicfoundation/hardhat-ignition@0.15.16': - resolution: {integrity: sha512-T0JTnuib7QcpsWkHCPLT7Z6F483EjTdcdjb1e00jqS9zTGCPqinPB66LLtR/duDLdvgoiCVS6K8WxTQkA/xR1Q==} + '@nomicfoundation/ethereumjs-util@9.0.4': + resolution: {integrity: sha512-sLOzjnSrlx9Bb9EFNtHzK/FJFsfg2re6bsGqinFinH1gCqVfz9YYlXiMWwDM4C/L4ywuHFCYwfKTVr/QHQcU0Q==} + engines: {node: '>=18'} peerDependencies: - '@nomicfoundation/hardhat-verify': ^2.1.0 - hardhat: ^2.26.0 - - '@nomicfoundation/hardhat-utils@4.0.4': - resolution: {integrity: sha512-CClEwrfcHsAsF9CNJfqJIBRSNTDi2pgGc0s2Bo5qGtIuh8YwgI9mpkMyzJzi/lHFuDFtEA+Oi2AfX6qRDp+SIw==} + c-kzg: ^2.1.2 + peerDependenciesMeta: + c-kzg: + optional: true - '@nomicfoundation/hardhat-verify@2.1.3': - resolution: {integrity: sha512-danbGjPp2WBhLkJdQy9/ARM3WQIK+7vwzE0urNem1qZJjh9f54Kf5f1xuQv8DvqewUAkuPxVt/7q4Grz5WjqSg==} - peerDependencies: - hardhat: ^2.26.0 + '@nomicfoundation/slang@1.3.1': + resolution: {integrity: sha512-gh0+JDjazmevEYCcwVgtuyfBJcV1209gIORZNRjUxbGzbQN0MOhQO9T0ptkzHKCf854gUy27SMxPbAyAu63fvQ==} - '@nomicfoundation/hardhat-verify@3.0.15': - resolution: {integrity: sha512-6DO8Z0MzyU4p89lPJVhsCX0CsOopkYhptatdt0uSfsqHdNz6JOtZ/KTTRuNXDI4QpR+KPq2GDkD4KqfAMX9WfQ==} - peerDependencies: - hardhat: ^3.4.0 + '@nomicfoundation/solidity-analyzer-darwin-arm64@0.1.1': + resolution: {integrity: sha512-KcTodaQw8ivDZyF+D76FokN/HdpgGpfjc/gFCImdLUyqB6eSWVaZPazMbeAjmfhx3R0zm/NYVzxwAokFKgrc0w==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [darwin] - '@nomicfoundation/hardhat-zod-utils@3.0.4': - resolution: {integrity: sha512-yCiycXDEEjbNgNVQaUoGYOee6+ljYUnIOWMtYc/dYDuwlHutWr9xg/KgkgMkiZZ1R2WrZAEqsSaeZTnH7Oyz9Q==} - peerDependencies: - zod: ^3.23.8 + '@nomicfoundation/solidity-analyzer-darwin-x64@0.1.1': + resolution: {integrity: sha512-XhQG4BaJE6cIbjAVtzGOGbK3sn1BO9W29uhk9J8y8fZF1DYz0Doj8QDMfpMu+A6TjPDs61lbsmeYodIDnfveSA==} + engines: {node: '>= 10'} + cpu: [x64] + os: [darwin] - '@nomicfoundation/ignition-core@0.15.15': - resolution: {integrity: sha512-JdKFxYknTfOYtFXMN6iFJ1vALJPednuB+9p9OwGIRdoI6HYSh4ZBzyRURgyXtHFyaJ/SF9lBpsYV9/1zEpcYwg==} + '@nomicfoundation/solidity-analyzer-freebsd-x64@0.1.1': + resolution: {integrity: sha512-GHF1VKRdHW3G8CndkwdaeLkVBi5A9u2jwtlS7SLhBc8b5U/GcoL39Q+1CSO3hYqePNP+eV5YI7Zgm0ea6kMHoA==} + engines: {node: '>= 10'} + cpu: [x64] + os: [freebsd] - '@nomicfoundation/ignition-ui@0.15.13': - resolution: {integrity: sha512-HbTszdN1iDHCkUS9hLeooqnLEW2U45FaqFwFEYT8nIno2prFZhG+n68JEERjmfFCB5u0WgbuJwk3CgLoqtSL7Q==} + '@nomicfoundation/solidity-analyzer-linux-arm64-gnu@0.1.1': + resolution: {integrity: sha512-g4Cv2fO37ZsUENQ2vwPnZc2zRenHyAxHcyBjKcjaSmmkKrFr64yvzeNO8S3GBFCo90rfochLs99wFVGT/0owpg==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [linux] - '@nomicfoundation/slang@0.18.3': - resolution: {integrity: sha512-YqAWgckqbHM0/CZxi9Nlf4hjk9wUNLC9ngWCWBiqMxPIZmzsVKYuChdlrfeBPQyvQQBoOhbx+7C1005kLVQDZQ==} + '@nomicfoundation/solidity-analyzer-linux-arm64-musl@0.1.1': + resolution: {integrity: sha512-WJ3CE5Oek25OGE3WwzK7oaopY8xMw9Lhb0mlYuJl/maZVo+WtP36XoQTb7bW/i8aAdHW5Z+BqrHMux23pvxG3w==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [linux] - '@nomicfoundation/solidity-analyzer-darwin-arm64@0.1.2': - resolution: {integrity: sha512-JaqcWPDZENCvm++lFFGjrDd8mxtf+CtLd2MiXvMNTBD33dContTZ9TWETwNFwg7JTJT5Q9HEecH7FA+HTSsIUw==} - engines: {node: '>= 12'} + '@nomicfoundation/solidity-analyzer-linux-x64-gnu@0.1.1': + resolution: {integrity: sha512-5WN7leSr5fkUBBjE4f3wKENUy9HQStu7HmWqbtknfXkkil+eNWiBV275IOlpXku7v3uLsXTOKpnnGHJYI2qsdA==} + engines: {node: '>= 10'} + cpu: [x64] + os: [linux] - '@nomicfoundation/solidity-analyzer-darwin-x64@0.1.2': - resolution: {integrity: sha512-fZNmVztrSXC03e9RONBT+CiksSeYcxI1wlzqyr0L7hsQlK1fzV+f04g2JtQ1c/Fe74ZwdV6aQBdd6Uwl1052sw==} - engines: {node: '>= 12'} + '@nomicfoundation/solidity-analyzer-linux-x64-musl@0.1.1': + resolution: {integrity: sha512-KdYMkJOq0SYPQMmErv/63CwGwMm5XHenEna9X9aB8mQmhDBrYrlAOSsIPgFCUSL0hjxE3xHP65/EPXR/InD2+w==} + engines: {node: '>= 10'} + cpu: [x64] + os: [linux] - '@nomicfoundation/solidity-analyzer-linux-arm64-gnu@0.1.2': - resolution: {integrity: sha512-3d54oc+9ZVBuB6nbp8wHylk4xh0N0Gc+bk+/uJae+rUgbOBwQSfuGIbAZt1wBXs5REkSmynEGcqx6DutoK0tPA==} - engines: {node: '>= 12'} + '@nomicfoundation/solidity-analyzer-win32-arm64-msvc@0.1.1': + resolution: {integrity: sha512-VFZASBfl4qiBYwW5xeY20exWhmv6ww9sWu/krWSesv3q5hA0o1JuzmPHR4LPN6SUZj5vcqci0O6JOL8BPw+APg==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [win32] - '@nomicfoundation/solidity-analyzer-linux-arm64-musl@0.1.2': - resolution: {integrity: sha512-iDJfR2qf55vgsg7BtJa7iPiFAsYf2d0Tv/0B+vhtnI16+wfQeTbP7teookbGvAo0eJo7aLLm0xfS/GTkvHIucA==} - engines: {node: '>= 12'} + '@nomicfoundation/solidity-analyzer-win32-ia32-msvc@0.1.1': + resolution: {integrity: sha512-JnFkYuyCSA70j6Si6cS1A9Gh1aHTEb8kOTBApp/c7NRTFGNMH8eaInKlyuuiIbvYFhlXW4LicqyYuWNNq9hkpQ==} + engines: {node: '>= 10'} + cpu: [ia32] + os: [win32] - '@nomicfoundation/solidity-analyzer-linux-x64-gnu@0.1.2': - resolution: {integrity: sha512-9dlHMAt5/2cpWyuJ9fQNOUXFB/vgSFORg1jpjX1Mh9hJ/MfZXlDdHQ+DpFCs32Zk5pxRBb07yGvSHk9/fezL+g==} - engines: {node: '>= 12'} + '@nomicfoundation/solidity-analyzer-win32-x64-msvc@0.1.1': + resolution: {integrity: sha512-HrVJr6+WjIXGnw3Q9u6KQcbZCtk0caVWhCdFADySvRyUxJ8PnzlaP+MhwNE8oyT8OZ6ejHBRrrgjSqDCFXGirw==} + engines: {node: '>= 10'} + cpu: [x64] + os: [win32] - '@nomicfoundation/solidity-analyzer-linux-x64-musl@0.1.2': - resolution: {integrity: sha512-GzzVeeJob3lfrSlDKQw2bRJ8rBf6mEYaWY+gW0JnTDHINA0s2gPR4km5RLIj1xeZZOYz4zRw+AEeYgLRqB2NXg==} + '@nomicfoundation/solidity-analyzer@0.1.1': + resolution: {integrity: sha512-1LMtXj1puAxyFusBgUIy5pZk3073cNXYnXUpuNKFghHbIit/xZgbk0AokpUADbNm3gyD6bFWl3LRFh3dhVdREg==} engines: {node: '>= 12'} - '@nomicfoundation/solidity-analyzer-win32-x64-msvc@0.1.2': - resolution: {integrity: sha512-Fdjli4DCcFHb4Zgsz0uEJXZ2K7VEO+w5KVv7HmT7WO10iODdU9csC2az4jrhEsRtiR9Gfd74FlG0NYlw1BMdyA==} - engines: {node: '>= 12'} + '@nuxt/cli@3.31.3': + resolution: {integrity: sha512-K0T1ZpBXnlb41NU/RWf1F0U0C14KzlEXCoaSgD2y8BiLoCBWcgQ1UAlRtx4cThqWbJmIxaNZZTDL0NZ9d1U7ag==} + engines: {node: ^16.10.0 || >=18.0.0} + hasBin: true - '@nomicfoundation/solidity-analyzer@0.1.2': - resolution: {integrity: sha512-q4n32/FNKIhQ3zQGGw5CvPF6GTvDCpYwIf7bEY/dZTZbgfDsHyjJwURxUJf3VQuuJj+fDIFl4+KkBVbw4Ef6jA==} - engines: {node: '>= 12'} + '@nuxt/devalue@2.0.2': + resolution: {integrity: sha512-GBzP8zOc7CGWyFQS6dv1lQz8VVpz5C2yRszbXufwG/9zhStTIH50EtD87NmWbTMwXDvZLNg8GIpb1UFdH93JCA==} - '@nomiclabs/hardhat-ethers@2.2.3': - resolution: {integrity: sha512-YhzPdzb612X591FOe68q+qXVXGG2ANZRvDo0RRUtimev85rCrAlv/TLMEZw5c+kq9AbzocLTVX/h2jVIFPL9Xg==} + '@nuxt/devtools-kit@2.7.0': + resolution: {integrity: sha512-MIJdah6CF6YOW2GhfKnb8Sivu6HpcQheqdjOlZqShBr+1DyjtKQbAKSCAyKPaoIzZP4QOo2SmTFV6aN8jBeEIQ==} peerDependencies: - ethers: ^5.0.0 - hardhat: ^2.0.0 + vite: '>=6.0' - '@nomiclabs/hardhat-truffle5@3.0.0': - resolution: {integrity: sha512-hisTmBBKcUye5+XzFuWWcWLhs+KEIv9+hOwKAgB9fKfQgaa/0D11+u3M5KM5t5nKNgy9IJfv7zyiy99yncgufA==} + '@nuxt/devtools-wizard@2.7.0': + resolution: {integrity: sha512-iWuWR0U6BRpF7D6xrgq9ZkQ6ajsw2EA/gVmbU9V5JPKRUtV6DVpCPi+h34VFNeQ104Sf531XgvT0sl3h93AjXA==} + hasBin: true - '@nomiclabs/hardhat-web3@2.1.2': - resolution: {integrity: sha512-ChnUInQ5AES1iJSNXq00JfWfQZkVUIkkSt2dtrB/8r+CfW/XeBTkvE5G+OTJTVSMme7lgqk9aieOI7d6GU6v1g==} + '@nuxt/devtools@2.7.0': + resolution: {integrity: sha512-BtIklVYny14Ykek4SHeexAHoa28MEV9kz223ZzvoNYqE0f+YVV+cJP69ovZHf+HUVpxaAMJfWKLHXinWXiCZ4Q==} + hasBin: true peerDependencies: - hardhat: ^2.26.0 - web3: ^1.0.0-beta.36 + vite: '>=6.0' - '@npmcli/agent@2.2.2': - resolution: {integrity: sha512-OrcNPXdpSl9UX7qPVRWbmWMCSXrcDa2M9DvrbOTj7ao1S4PlqVFYv9/yLKMkrJKZ/V5A/kDBC690or307i26Og==} - engines: {node: ^16.14.0 || >=18.0.0} + '@nuxt/kit@3.19.0': + resolution: {integrity: sha512-kecjqWORKdy7xnsOf/X4NtsFMbn+hNiiYhsA+INYVbgoyhCdx1rpEURCJdQITzHehXy5QWINTqmjNGp//PO4CQ==} + engines: {node: '>=18.12.0'} - '@npmcli/fs@3.1.1': - resolution: {integrity: sha512-q9CRWjpHCMIh5sVyefoD1cA7PkvILqCZsnSOEUUivORLjxCO/Irmue2DprETiNgEqktDBZaM1Bi+jrarx1XdCg==} - engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} + '@nuxt/kit@3.20.2': + resolution: {integrity: sha512-laqfmMcWWNV1FsVmm1+RQUoGY8NIJvCRl0z0K8ikqPukoEry0LXMqlQ+xaf8xJRvoH2/78OhZmsEEsUBTXipcw==} + engines: {node: '>=18.12.0'} - '@npmcli/redact@2.0.1': - resolution: {integrity: sha512-YgsR5jCQZhVmTJvjduTOIHph0L73pK8xwMVaDY0PatySqVM9AZj93jpoXYSJqfHFxFkN9dmqTw6OiqExsS3LPw==} - engines: {node: ^16.14.0 || >=18.0.0} + '@nuxt/schema@3.11.2': + resolution: {integrity: sha512-Z0bx7N08itD5edtpkstImLctWMNvxTArsKXzS35ZuqyAyKBPcRjO1CU01slH0ahO30Gg9kbck3/RKNZPwfOjJg==} + engines: {node: ^14.18.0 || >=16.10.0} - '@openzeppelin/defender-sdk-base-client@2.7.1': - resolution: {integrity: sha512-7gFCteA+V3396A3McgqzmirwmbPXuHJYN896O3AbsHX9XcxInN74C5Zv3tFHld0GmIX/VlaIvILNMhOpdISZjA==} + '@nuxt/schema@3.19.0': + resolution: {integrity: sha512-V3vgqXFruyOe7s8nBt+6OD+yQ18tqq5aLF7KPNJ5OaBvdWy24S5s4SbhUfgCNJmVmmsXsbxgHi9amz5uRFiaIw==} + engines: {node: ^14.18.0 || >=16.10.0} - '@openzeppelin/defender-sdk-deploy-client@2.7.1': - resolution: {integrity: sha512-vFkDupn8ATW83KjZlY5U7UdsvSo9YZwOMQoVaHJO3S+Z6h0wa6cTzuQV9C0AKYq524quQkFsQ4AQq5CgsgdEkQ==} + '@nuxt/telemetry@2.6.6': + resolution: {integrity: sha512-Zh4HJLjzvm3Cq9w6sfzIFyH9ozK5ePYVfCUzzUQNiZojFsI2k1QkSBrVI9BGc6ArKXj/O6rkI6w7qQ+ouL8Cag==} + engines: {node: '>=18.12.0'} + hasBin: true - '@openzeppelin/defender-sdk-network-client@2.7.1': - resolution: {integrity: sha512-AWJKT9YKv9wH3/1AJZCztF3VIsg1sX+v8fjtyFLROqtVAzmhB8WKBRVt9GHAZ+PmsixAKDMOEbH6R1cipTIVHQ==} + '@nuxt/ui-templates@1.3.3': + resolution: {integrity: sha512-3BG5doAREcD50dbKyXgmjD4b1GzY8CUy3T41jMhHZXNDdaNwOd31IBq+D6dV00OSrDVhzrTVj0IxsUsnMyHvIQ==} - '@openzeppelin/hardhat-upgrades@3.9.1': - resolution: {integrity: sha512-pSDjlOnIpP+PqaJVe144dK6VVKZw2v6YQusyt0OOLiCsl+WUzfo4D0kylax7zjrOxqy41EK2ipQeIF4T+cCn2A==} - hasBin: true + '@nuxt/vite-builder@3.19.0': + resolution: {integrity: sha512-a7Zn4+smxMhZqXlDLE2fhHZfYBeOVYtjeg1s/yK/1T5LWOqHu9NGtNhJT7notYM491Mrp5eY9UaaiHlmTnI0dA==} + engines: {node: ^20.19.0 || >=22.12.0} peerDependencies: - '@nomicfoundation/hardhat-ethers': ^3.0.6 - '@nomicfoundation/hardhat-verify': ^2.0.14 - ethers: ^6.6.0 - hardhat: ^2.24.1 - peerDependenciesMeta: - '@nomicfoundation/hardhat-verify': - optional: true + vue: ^3.3.4 - '@openzeppelin/upgrades-core@1.44.2': - resolution: {integrity: sha512-m6iorjyhPK9ow5/trNs7qsBC/SOzJCO51pvvAF2W9nOiZ1t0RtCd+rlRmRmlWTv4M33V0wzIUeamJ2BPbzgUXA==} - hasBin: true + '@one-ini/wasm@0.1.1': + resolution: {integrity: sha512-XuySG1E38YScSJoMlqovLru4KTUNSjgVTIjyh7qMX6aNN5HY5Ct5LhRJdxO79JtTzKfzV/bnWpz+zquYrISsvw==} - '@pkgjs/parseargs@0.11.0': - resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==} - engines: {node: '>=14'} + '@open-draft/deferred-promise@2.2.0': + resolution: {integrity: sha512-CecwLWx3rhxVQF6V4bAgPS5t+So2sTbPgAzafKkVizyi7tlwpcFpdFqq+wqF2OwNBmqFuu6tOyouTuxgpMfzmA==} + + '@open-draft/logger@0.3.0': + resolution: {integrity: sha512-X2g45fzhxH238HKO4xbSr7+wBS8Fvw6ixhTDuvLd5mqh6bJJCFAPwU9mPDxbcrRtfxv4u5IHCEH77BmxvXmmxQ==} - '@resolver-engine/core@0.3.3': - resolution: {integrity: sha512-eB8nEbKDJJBi5p5SrvrvILn4a0h42bKtbCTri3ZxCGt6UvoQyp7HnGOfki944bUjBSHKK3RvgfViHn+kqdXtnQ==} + '@open-draft/until@2.1.0': + resolution: {integrity: sha512-U69T3ItWHvLwGg5eJ0n3I62nWuE6ilHlmz7zM0npLBRvPRd7e6NYmg54vvRtP5mZG7kZqZCFVdsTWo7BPtBujg==} - '@resolver-engine/fs@0.3.3': - resolution: {integrity: sha512-wQ9RhPUcny02Wm0IuJwYMyAG8fXVeKdmhm8xizNByD4ryZlx6PP6kRen+t/haF43cMfmaV7T3Cx6ChOdHEhFUQ==} + '@oven/bun-darwin-aarch64@1.1.30': + resolution: {integrity: sha512-D07QioP+QXlouvIqQIS+7r2zq4lTNd6he79rhKsRQRZGFf9i3NPu87zspUpCaFEu//DZ35DYTt+5anQpAzpoxA==} + cpu: [arm64] + os: [darwin] - '@resolver-engine/imports-fs@0.3.3': - resolution: {integrity: sha512-7Pjg/ZAZtxpeyCFlZR5zqYkz+Wdo84ugB5LApwriT8XFeQoLwGUj4tZFFvvCuxaNCcqZzCYbonJgmGObYBzyCA==} + '@oven/bun-darwin-x64-baseline@1.1.30': + resolution: {integrity: sha512-1kFUCxHx7WuEbLDmqm0m2UKBd3S4Ln6qKQ4gxU4umMLFkmvDJn6PszDruFInxGKFLoTAmbXNYNVWkkG/ekt/Lg==} + cpu: [x64] + os: [darwin] - '@resolver-engine/imports@0.3.3': - resolution: {integrity: sha512-anHpS4wN4sRMwsAbMXhMfOD/y4a4Oo0Cw/5+rue7hSwGWsDOQaAU1ClK1OxjUC35/peazxEl8JaSRRS+Xb8t3Q==} + '@oven/bun-darwin-x64@1.1.30': + resolution: {integrity: sha512-xZ4gTehS6QwN6bsJfDycCNneKoUMaFUQhQg24bJzXS4JPDxeKg1W7PS5AE+U9apz5Dx6//+D4RwVpAPG2LXt0w==} + cpu: [x64] + os: [darwin] - '@rollup/rollup-android-arm-eabi@4.60.2': - resolution: {integrity: sha512-dnlp69efPPg6Uaw2dVqzWRfAWRnYVb1XJ8CyyhIbZeaq4CA5/mLeZ1IEt9QqQxmbdvagjLIm2ZL8BxXv5lH4Yw==} - cpu: [arm] - os: [android] + '@oven/bun-linux-aarch64@1.1.30': + resolution: {integrity: sha512-SfHHLlph6fptDXyyChcUkeDbEZr2ww1p2BucV6OrvzwTOPi8pVmXA4360YT8ggR/3AHPp4GO36VaD+FU2Ocbxw==} + cpu: [arm64] + os: [linux] + + '@oven/bun-linux-x64-baseline@1.1.30': + resolution: {integrity: sha512-/b/VuNOaAYmsVk9MvfwKcCYARJPUg78hebxNyD5DSajAf3dqtUSnf7QYcq/3mxWH++N+gM7uRTrGksGS63+ZUw==} + cpu: [x64] + os: [linux] + + '@oven/bun-linux-x64@1.1.30': + resolution: {integrity: sha512-1mC39jQSaECytEKAZdCZmv3ZreMsp7aoxnBwmJtVd2Z7urnw17PKi4dKkZd/R+AubsNYtXtW4jeM8SEa5sUJRw==} + cpu: [x64] + os: [linux] - '@rollup/rollup-android-arm64@4.60.2': - resolution: {integrity: sha512-OqZTwDRDchGRHHm/hwLOL7uVPB9aUvI0am/eQuWMNyFHf5PSEQmyEeYYheA0EPPKUO/l0uigCp+iaTjoLjVoHg==} + '@oven/bun-windows-x64-baseline@1.1.30': + resolution: {integrity: sha512-ERQ4/ogzbFvHjpyHcnruc8bnryvDvUoiWi6vczfQ4M/idJc+Kg5VSEJiF5k7946rIZGamG6QWgRxtpIglD4/Zw==} + cpu: [x64] + os: [win32] + + '@oven/bun-windows-x64@1.1.30': + resolution: {integrity: sha512-mdRjNtD9NIA8CiH6N1zrIVE6oAtDko/c29H1s00UA+5O/WhXhg95G8IyInD8hN3vAEz8H2lGBgLG2EGfSFxnGg==} + cpu: [x64] + os: [win32] + + '@oxc-minify/binding-android-arm64@0.86.0': + resolution: {integrity: sha512-jOgbDgp6A1ax9sxHPRHBxUpxIzp2VTgbZ/6HPKIVUJ7IQqKVsELKFXIOEbCDlb1rUhZZtGf53MFypXf72kR5eQ==} + engines: {node: '>=14.0.0'} cpu: [arm64] os: [android] - '@rollup/rollup-darwin-arm64@4.60.2': - resolution: {integrity: sha512-UwRE7CGpvSVEQS8gUMBe1uADWjNnVgP3Iusyda1nSRwNDCsRjnGc7w6El6WLQsXmZTbLZx9cecegumcitNfpmA==} + '@oxc-minify/binding-darwin-arm64@0.86.0': + resolution: {integrity: sha512-LQkjIHhIzxVYnxfC2QV7MMe4hgqIbwK07j+zzEsNWWfdmWABw11Aa6FP0uIvERmoxstzsDT77F8c/+xhxswKiw==} + engines: {node: '>=14.0.0'} cpu: [arm64] os: [darwin] - '@rollup/rollup-darwin-x64@4.60.2': - resolution: {integrity: sha512-gjEtURKLCC5VXm1I+2i1u9OhxFsKAQJKTVB8WvDAHF+oZlq0GTVFOlTlO1q3AlCTE/DF32c16ESvfgqR7343/g==} + '@oxc-minify/binding-darwin-x64@0.86.0': + resolution: {integrity: sha512-AuLkeXIvJ535qOhFzZfHBkcEZA59SN1vKUblW2oN+6ClZfIMru0I2wr0cCHA9QDxIVDkI7swDu29qcn2AqKdrg==} + engines: {node: '>=14.0.0'} cpu: [x64] os: [darwin] - '@rollup/rollup-freebsd-arm64@4.60.2': - resolution: {integrity: sha512-Bcl6CYDeAgE70cqZaMojOi/eK63h5Me97ZqAQoh77VPjMysA/4ORQBRGo3rRy45x4MzVlU9uZxs8Uwy7ZaKnBw==} - cpu: [arm64] - os: [freebsd] - - '@rollup/rollup-freebsd-x64@4.60.2': - resolution: {integrity: sha512-LU+TPda3mAE2QB0/Hp5VyeKJivpC6+tlOXd1VMoXV/YFMvk/MNk5iXeBfB4MQGRWyOYVJ01625vjkr0Az98OJQ==} + '@oxc-minify/binding-freebsd-x64@0.86.0': + resolution: {integrity: sha512-UcXLcM8+iHW1EL+peHHV1HDBFUVdoxFMJC7HBc2U83q9oiF/K73TnAEgW/xteR+IvbV/9HD+cQsH+DX6oBXoQg==} + engines: {node: '>=14.0.0'} cpu: [x64] os: [freebsd] - '@rollup/rollup-linux-arm-gnueabihf@4.60.2': - resolution: {integrity: sha512-2QxQrM+KQ7DAW4o22j+XZ6RKdxjLD7BOWTP0Bv0tmjdyhXSsr2Ul1oJDQqh9Zf5qOwTuTc7Ek83mOFaKnodPjg==} + '@oxc-minify/binding-linux-arm-gnueabihf@0.86.0': + resolution: {integrity: sha512-UtSplQY10Idp//cLS5i2rFaunS71padZFavHLHygNAxJBt+37DPKDl/4kddpV6Kv2Mr6bhw2KpXGAVs0C3dIOw==} + engines: {node: '>=14.0.0'} cpu: [arm] os: [linux] - '@rollup/rollup-linux-arm-musleabihf@4.60.2': - resolution: {integrity: sha512-TbziEu2DVsTEOPif2mKWkMeDMLoYjx95oESa9fkQQK7r/Orta0gnkcDpzwufEcAO2BLBsD7mZkXGFqEdMRRwfw==} + '@oxc-minify/binding-linux-arm-musleabihf@0.86.0': + resolution: {integrity: sha512-P5efCOl9QiwqqJHrw1Q+4ssexvOz+MAmgTmBorbdEM3WJdIHR1CWGDj4GqcvKBlwpBqt4XilOuoN0QD8dfl85A==} + engines: {node: '>=14.0.0'} cpu: [arm] os: [linux] - '@rollup/rollup-linux-arm64-gnu@4.60.2': - resolution: {integrity: sha512-bO/rVDiDUuM2YfuCUwZ1t1cP+/yqjqz+Xf2VtkdppefuOFS2OSeAfgafaHNkFn0t02hEyXngZkxtGqXcXwO8Rg==} + '@oxc-minify/binding-linux-arm64-gnu@0.86.0': + resolution: {integrity: sha512-hwHahfs//g9iZLQmKldjQPmnpzq76eyHvfkmdnXXmPtwTHnwXL1hPlNbTIqakUirAsroBeQwXqzHm3I040R+mg==} + engines: {node: '>=14.0.0'} cpu: [arm64] os: [linux] - '@rollup/rollup-linux-arm64-musl@4.60.2': - resolution: {integrity: sha512-hr26p7e93Rl0Za+JwW7EAnwAvKkehh12BU1Llm9Ykiibg4uIr2rbpxG9WCf56GuvidlTG9KiiQT/TXT1yAWxTA==} + '@oxc-minify/binding-linux-arm64-musl@0.86.0': + resolution: {integrity: sha512-S2dL24nxWqDCwrq48xlZBvhSIBcEWOu3aDOiaccP4q73PiTLrf6rm1M11J7vQNSRiH6ao9UKr7ZMsepCZcOyfA==} + engines: {node: '>=14.0.0'} cpu: [arm64] os: [linux] - '@rollup/rollup-linux-loong64-gnu@4.60.2': - resolution: {integrity: sha512-pOjB/uSIyDt+ow3k/RcLvUAOGpysT2phDn7TTUB3n75SlIgZzM6NKAqlErPhoFU+npgY3/n+2HYIQVbF70P9/A==} - cpu: [loong64] - os: [linux] - - '@rollup/rollup-linux-loong64-musl@4.60.2': - resolution: {integrity: sha512-2/w+q8jszv9Ww1c+6uJT3OwqhdmGP2/4T17cu8WuwyUuuaCDDJ2ojdyYwZzCxx0GcsZBhzi3HmH+J5pZNXnd+Q==} - cpu: [loong64] - os: [linux] - - '@rollup/rollup-linux-ppc64-gnu@4.60.2': - resolution: {integrity: sha512-11+aL5vKheYgczxtPVVRhdptAM2H7fcDR5Gw4/bTcteuZBlH4oP9f5s9zYO9aGZvoGeBpqXI/9TZZihZ609wKw==} - cpu: [ppc64] - os: [linux] - - '@rollup/rollup-linux-ppc64-musl@4.60.2': - resolution: {integrity: sha512-i16fokAGK46IVZuV8LIIwMdtqhin9hfYkCh8pf8iC3QU3LpwL+1FSFGej+O7l3E/AoknL6Dclh2oTdnRMpTzFQ==} - cpu: [ppc64] - os: [linux] - - '@rollup/rollup-linux-riscv64-gnu@4.60.2': - resolution: {integrity: sha512-49FkKS6RGQoriDSK/6E2GkAsAuU5kETFCh7pG4yD/ylj9rKhTmO3elsnmBvRD4PgJPds5W2PkhC82aVwmUcJ7A==} - cpu: [riscv64] - os: [linux] - - '@rollup/rollup-linux-riscv64-musl@4.60.2': - resolution: {integrity: sha512-mjYNkHPfGpUR00DuM1ZZIgs64Hpf4bWcz9Z41+4Q+pgDx73UwWdAYyf6EG/lRFldmdHHzgrYyge5akFUW0D3mQ==} + '@oxc-minify/binding-linux-riscv64-gnu@0.86.0': + resolution: {integrity: sha512-itZ24A1a5NOw0ibbt6EYOHdBojfV4vbiC209d06Dwv5WLXtntHCjc8P4yfrCsC22uDmMPNkVa+UL+OM4mkUrwg==} + engines: {node: '>=14.0.0'} cpu: [riscv64] os: [linux] - '@rollup/rollup-linux-s390x-gnu@4.60.2': - resolution: {integrity: sha512-ALyvJz965BQk8E9Al/JDKKDLH2kfKFLTGMlgkAbbYtZuJt9LU8DW3ZoDMCtQpXAltZxwBHevXz5u+gf0yA0YoA==} + '@oxc-minify/binding-linux-s390x-gnu@0.86.0': + resolution: {integrity: sha512-/nJAwS/uit19qXNpaOybf7GYJI7modbXYVZ8q1pIFdxs6HkhZLxS1ZvcIzY3W75+37u+uKeZ4MbygawAN8kQpQ==} + engines: {node: '>=14.0.0'} cpu: [s390x] os: [linux] - '@rollup/rollup-linux-x64-gnu@4.60.2': - resolution: {integrity: sha512-UQjrkIdWrKI626Du8lCQ6MJp/6V1LAo2bOK9OTu4mSn8GGXIkPXk/Vsp4bLHCd9Z9Iz2OTEaokUE90VweJgIYQ==} + '@oxc-minify/binding-linux-x64-gnu@0.86.0': + resolution: {integrity: sha512-3qnWZB2cOj5Em/uEJqJ1qP/8lxtoi/Rf1U8fmdLzPW5zIaiTRUr/LklB4aJ+Vc/GU5g3HX5nFPQG3ZnEV3Ktzg==} + engines: {node: '>=14.0.0'} cpu: [x64] os: [linux] - '@rollup/rollup-linux-x64-musl@4.60.2': - resolution: {integrity: sha512-bTsRGj6VlSdn/XD4CGyzMnzaBs9bsRxy79eTqTCBsA8TMIEky7qg48aPkvJvFe1HyzQ5oMZdg7AnVlWQSKLTnw==} + '@oxc-minify/binding-linux-x64-musl@0.86.0': + resolution: {integrity: sha512-+ZqYG8IQSRq9dR2djrnyzGHlmwGRKdueVjHYbEOwngb/4h/+FxAOaNUbsoUsCthAfXTrZHVXiQMTKJ32r7j2Bg==} + engines: {node: '>=14.0.0'} cpu: [x64] os: [linux] - '@rollup/rollup-openbsd-x64@4.60.2': - resolution: {integrity: sha512-6d4Z3534xitaA1FcMWP7mQPq5zGwBmGbhphh2DwaA1aNIXUu3KTOfwrWpbwI4/Gr0uANo7NTtaykFyO2hPuFLg==} - cpu: [x64] - os: [openbsd] - - '@rollup/rollup-openharmony-arm64@4.60.2': - resolution: {integrity: sha512-NetAg5iO2uN7eB8zE5qrZ3CSil+7IJt4WDFLcC75Ymywq1VZVD6qJ6EvNLjZ3rEm6gB7XW5JdT60c6MN35Z85Q==} - cpu: [arm64] - os: [openharmony] + '@oxc-minify/binding-wasm32-wasi@0.86.0': + resolution: {integrity: sha512-ixeSZW7jzd3g9fh8MoR9AzGLQxMCo//Q2mVpO2S/4NmcPtMaJEog85KzHULgUvbs70RqxTHEUqtVgpnc/5lMWA==} + engines: {node: '>=14.0.0'} + cpu: [wasm32] - '@rollup/rollup-win32-arm64-msvc@4.60.2': - resolution: {integrity: sha512-NCYhOotpgWZ5kdxCZsv6Iudx0wX8980Q/oW4pNFNihpBKsDbEA1zpkfxJGC0yugsUuyDZ7gL37dbzwhR0VI7pQ==} + '@oxc-minify/binding-win32-arm64-msvc@0.86.0': + resolution: {integrity: sha512-cN309CnFVG8jeSRd+lQGnoMpZAVmz4bzH4fgqJM0NsMXVnFPGFceG/XiToLoBA1FigGQvkV0PJ7MQKWxBHPoUA==} + engines: {node: '>=14.0.0'} cpu: [arm64] os: [win32] - '@rollup/rollup-win32-ia32-msvc@4.60.2': - resolution: {integrity: sha512-RXsaOqXxfoUBQoOgvmmijVxJnW2IGB0eoMO7F8FAjaj0UTywUO/luSqimWBJn04WNgUkeNhh7fs7pESXajWmkg==} - cpu: [ia32] - os: [win32] - - '@rollup/rollup-win32-x64-gnu@4.60.2': - resolution: {integrity: sha512-qdAzEULD+/hzObedtmV6iBpdL5TIbKVztGiK7O3/KYSf+HIzU257+MX1EXJcyIiDbMAqmbwaufcYPvyRryeZtA==} - cpu: [x64] - os: [win32] - - '@rollup/rollup-win32-x64-msvc@4.60.2': - resolution: {integrity: sha512-Nd/SgG27WoA9e+/TdK74KnHz852TLa94ovOYySo/yMPuTmpckK/jIF2jSwS3g7ELSKXK13/cVdmg1Z/DaCWKxA==} + '@oxc-minify/binding-win32-x64-msvc@0.86.0': + resolution: {integrity: sha512-YAqCKtZ9KKhSW73d/Oa9Uut0myYnCEUL2D0buMjJ4p0PuK1PQsMCJsmX4ku0PgK31snanZneRwtEjjNFYNdX2A==} + engines: {node: '>=14.0.0'} cpu: [x64] os: [win32] - '@rtsao/scc@1.1.0': - resolution: {integrity: sha512-zt6OdqaDoOnJ1ZYsCYGt9YmWzDXl4vQdKTyJev62gFhRGKdx7mcT54V9KIjg+d2wi9EXsPvAPKe7i7WjfVWB8g==} + '@oxc-parser/binding-android-arm64@0.86.0': + resolution: {integrity: sha512-BfNFEWpRo4gqLHKvRuQmhbPGeJqB1Ka/hsPhKf1imAojwUcf/Dr/yRkZBuEi2yc1LWBjApKYJEqpsBUmtqSY1Q==} + engines: {node: '>=20.0.0'} + cpu: [arm64] + os: [android] - '@scure/base@1.1.9': - resolution: {integrity: sha512-8YKhl8GHiNI/pU2VMaofa2Tor7PJRAjwQLBBuilkJ9L5+13yVbC7JO/wS7piioAvPSwR3JKM1IJ/u4xQzbcXKg==} + '@oxc-parser/binding-darwin-arm64@0.86.0': + resolution: {integrity: sha512-gRSnEHcyNEfLdNj6v8XKcuHUaZnRpH2lOZFztuGEi23ENydPOQVEtiZYexuHOTeaLGgzw+93TgB4n/YkjYodug==} + engines: {node: '>=20.0.0'} + cpu: [arm64] + os: [darwin] - '@scure/base@1.2.6': - resolution: {integrity: sha512-g/nm5FgUa//MCj1gV09zTJTaM6KBAHqLN907YVQqf7zC49+DcO4B1so4ZX07Ef10Twr6nuqYEH9GEggFXA4Fmg==} + '@oxc-parser/binding-darwin-x64@0.86.0': + resolution: {integrity: sha512-6mdymm8i+VpLTJP19D3PSFumMmAyfhhhIRWcRHsc0bL7CSZjCWbvRb00ActKrGKWtsol/A/KKgqglJwpvjlzOA==} + engines: {node: '>=20.0.0'} + cpu: [x64] + os: [darwin] - '@scure/bip32@1.1.5': - resolution: {integrity: sha512-XyNh1rB0SkEqd3tXcXMi+Xe1fvg+kUIcoRIEujP1Jgv7DqW2r9lg3Ah0NkFaCs9sTkQAQA8kw7xiRXzENi9Rtw==} + '@oxc-parser/binding-freebsd-x64@0.86.0': + resolution: {integrity: sha512-mc2xYRPxhzFg4NX1iqfIWP+8ORtXiNpAkaomNDepegQFlIFUmrESa3IJrKJ/4vg77Tbti7omHbraOqwdTk849g==} + engines: {node: '>=20.0.0'} + cpu: [x64] + os: [freebsd] - '@scure/bip32@1.4.0': - resolution: {integrity: sha512-sVUpc0Vq3tXCkDGYVWGIZTRfnvu8LoTDaev7vbwh0omSvVORONr960MQWdKqJDCReIEmTj3PAr73O3aoxz7OPg==} + '@oxc-parser/binding-linux-arm-gnueabihf@0.86.0': + resolution: {integrity: sha512-LZzapjFhwGQMKefcFsn3lJc/mTY37fBlm0jjEvETgNCyd5pH4gDwOcrp/wZHAz2qw5uLWOHaa69I6ci5lBjJgA==} + engines: {node: '>=20.0.0'} + cpu: [arm] + os: [linux] - '@scure/bip32@1.7.0': - resolution: {integrity: sha512-E4FFX/N3f4B80AKWp5dP6ow+flD1LQZo/w8UnLGYZO674jS6YnYeepycOOksv+vLPSpgN35wgKgy+ybfTb2SMw==} + '@oxc-parser/binding-linux-arm-musleabihf@0.86.0': + resolution: {integrity: sha512-/rhJMpng7/Qgn8hE4sigxTRb04+zdO0K1kfAMZ3nONphk5r2Yk2RjyEpLLz17adysCyQw/KndaMHNv8GR8VMNg==} + engines: {node: '>=20.0.0'} + cpu: [arm] + os: [linux] - '@scure/bip39@1.1.1': - resolution: {integrity: sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg==} + '@oxc-parser/binding-linux-arm64-gnu@0.86.0': + resolution: {integrity: sha512-IXEZnk6O0zJg5gDn1Zvt5Qx62Z3E+ewrKwPgMfExqnNCLq+Ix2g7hQypevm/S6qxVgyz5HbiW+a/5ziMFXTCJQ==} + engines: {node: '>=20.0.0'} + cpu: [arm64] + os: [linux] - '@scure/bip39@1.3.0': - resolution: {integrity: sha512-disdg7gHuTDZtY+ZdkmLpPCk7fxZSu3gBiEGuoC1XYxv9cGx3Z6cpTggCgW6odSOOIXCiDjuGejW+aJKCY/pIQ==} + '@oxc-parser/binding-linux-arm64-musl@0.86.0': + resolution: {integrity: sha512-QG7DUVZ/AtBaUGMhgToB4glOdq0MGAEYU1MJQpNB5HqiEcOpteF9Pd+oPfscj2zrGPd47KNyljtJRBKJr6Ut0w==} + engines: {node: '>=20.0.0'} + cpu: [arm64] + os: [linux] - '@scure/bip39@1.6.0': - resolution: {integrity: sha512-+lF0BbLiJNwVlev4eKelw1WWLaiKXw7sSl8T6FvBlWkdX+94aGJ4o8XjUdlyhTCjd8c+B3KT3JfS8P0bLRNU6A==} + '@oxc-parser/binding-linux-riscv64-gnu@0.86.0': + resolution: {integrity: sha512-smz+J6riX2du2lp0IKeZSaOBIhhoE2N/L1IQdOLCpzB0ikjCDBoyNKdDM7te8ZDq3KDnRmJChmhQGd8P1/LGBQ==} + engines: {node: '>=20.0.0'} + cpu: [riscv64] + os: [linux] - '@sentry/core@5.30.0': - resolution: {integrity: sha512-TmfrII8w1PQZSZgPpUESqjB+jC6MvZJZdLtE/0hZ+SrnKhW3x5WlYLvTXZpcWePYBku7rl2wn1RZu6uT0qCTeg==} - engines: {node: '>=6'} + '@oxc-parser/binding-linux-s390x-gnu@0.86.0': + resolution: {integrity: sha512-vas1BOMWVdicuimmi5Y+xPj3csaYQquVA45Im9a/DtVsypVeh8RWYXBMO1qJNM5Fg5HD0QvYNqxvftx3c+f5pg==} + engines: {node: '>=20.0.0'} + cpu: [s390x] + os: [linux] - '@sentry/hub@5.30.0': - resolution: {integrity: sha512-2tYrGnzb1gKz2EkMDQcfLrDTvmGcQPuWxLnJKXJvYTQDGLlEvi2tWz1VIHjunmOvJrB5aIQLhm+dcMRwFZDCqQ==} - engines: {node: '>=6'} + '@oxc-parser/binding-linux-x64-gnu@0.86.0': + resolution: {integrity: sha512-3Fsi+JA3NwdZdrpC6AieOP48cuBrq0q59JgnR0mfoWfr9wHrbn2lt8EEubrj6EXpBUmu1Zii7S9NNRC6fl/d+w==} + engines: {node: '>=20.0.0'} + cpu: [x64] + os: [linux] - '@sentry/minimal@5.30.0': - resolution: {integrity: sha512-BwWb/owZKtkDX+Sc4zCSTNcvZUq7YcH3uAVlmh/gtR9rmUvbzAA3ewLuB3myi4wWRAMEtny6+J/FN/x+2wn9Xw==} - engines: {node: '>=6'} + '@oxc-parser/binding-linux-x64-musl@0.86.0': + resolution: {integrity: sha512-89/d43EW76wJagz8u5zcKW8itB2rnS/uN7un5APb8Ebme8TePBwDyxo64J6oY5rcJYkfJ6lEszSF/ovicsNVPw==} + engines: {node: '>=20.0.0'} + cpu: [x64] + os: [linux] - '@sentry/node@5.30.0': - resolution: {integrity: sha512-Br5oyVBF0fZo6ZS9bxbJZG4ApAjRqAnqFFurMVJJdunNb80brh7a5Qva2kjhm+U6r9NJAB5OmDyPkA1Qnt+QVg==} - engines: {node: '>=6'} + '@oxc-parser/binding-wasm32-wasi@0.86.0': + resolution: {integrity: sha512-gRrGmE2L27stNMeiAucy/ffHF9VjYr84MizuJzSYnnKmd5WXf3HelNdd0UYSJnpb7APBuyFSN2Oato+Qb6yAFw==} + engines: {node: '>=14.0.0'} + cpu: [wasm32] - '@sentry/tracing@5.30.0': - resolution: {integrity: sha512-dUFowCr0AIMwiLD7Fs314Mdzcug+gBVo/+NCMyDw8tFxJkwWAKl7Qa2OZxLQ0ZHjakcj1hNKfCQJ9rhyfOl4Aw==} - engines: {node: '>=6'} + '@oxc-parser/binding-win32-arm64-msvc@0.86.0': + resolution: {integrity: sha512-parTnpNviJYR3JIFLseDGip1KkYbhWLeuZG9OMek62gr6Omflddoytvb17s+qODoZqFAVjvuOmVipDdjTl9q3Q==} + engines: {node: '>=20.0.0'} + cpu: [arm64] + os: [win32] - '@sentry/types@5.30.0': - resolution: {integrity: sha512-R8xOqlSTZ+htqrfteCWU5Nk0CDN5ApUTvrlvBuiH1DyP6czDZ4ktbZB0hAgBlVcK0U+qpD3ag3Tqqpa5Q67rPw==} - engines: {node: '>=6'} + '@oxc-parser/binding-win32-x64-msvc@0.86.0': + resolution: {integrity: sha512-FTso24eQh3vPTe/SOTf0/RXfjJ13tsk5fw728fm+z5y6Rb+mmEBfyVT6XxyGhEwtdfnRSZawheX74/9caI1etw==} + engines: {node: '>=20.0.0'} + cpu: [x64] + os: [win32] - '@sentry/utils@5.30.0': - resolution: {integrity: sha512-zaYmoH0NWWtvnJjC9/CBseXMtKHm/tm40sz3YfJRxeQjyzRqNQPgivpd9R/oDJCYj999mzdW382p/qi2ypjLww==} - engines: {node: '>=6'} + '@oxc-project/runtime@0.82.3': + resolution: {integrity: sha512-LNh5GlJvYHAnMurO+EyA8jJwN1rki7l3PSHuosDh2I7h00T6/u9rCkUjg/SvPmT1CZzvhuW0y+gf7jcqUy/Usg==} + engines: {node: '>=6.9.0'} - '@sindresorhus/is@4.6.0': - resolution: {integrity: sha512-t09vSN3MdfsyCHoFcTRCH/iUtG7OJ0CsjzB8cjAmKc/va/kIgeDI/TxsigdncE/4be734m0cvIYwNaV4i2XqAw==} - engines: {node: '>=10'} + '@oxc-project/types@0.82.3': + resolution: {integrity: sha512-6nCUxBnGX0c6qfZW5MaF6/fmu5dHJDMiMPaioKHKs5mi5+8/FHQ7WGjgQIz1zxpmceMYfdIXkOaLYE+ejbuOtA==} - '@smithy/config-resolver@4.4.17': - resolution: {integrity: sha512-TzDZcAnhTyAHbXVxWZo7/tEcrIeFq20IBk8So3OLOetWpR8EwY/yEqBMBFaJMeyEiREDq4NfEl+qO3OAUD+vbQ==} - engines: {node: '>=18.0.0'} + '@oxc-project/types@0.86.0': + resolution: {integrity: sha512-bJ57vWNQnOnUe5ZxUkrWpLyExxqb0BoyQ+IRmI/V1uxHbBNBzFGMIjKIf5ECFsgS0KgUUl8TM3a4xpeAtAnvIA==} - '@smithy/core@3.23.17': - resolution: {integrity: sha512-x7BlLbUFL8NWCGjMF9C+1N5cVCxcPa7g6Tv9B4A2luWx3be3oU8hQ96wIwxe/s7OhIzvoJH73HAUSg5JXVlEtQ==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-android-arm64@0.86.0': + resolution: {integrity: sha512-025JJoCWi04alNef6WvLnGCbx2MH9Ld2xvr0168bpOcpBjxt8sOZawu0MPrZQhnNWWiX8rrwrhuUDasWCWHxFw==} + engines: {node: '>=14.0.0'} + cpu: [arm64] + os: [android] - '@smithy/credential-provider-imds@4.2.14': - resolution: {integrity: sha512-Au28zBN48ZAoXdooGUHemuVBrkE+Ie6RPmGNIAJsFqj33Vhb6xAgRifUydZ2aY+M+KaMAETAlKk5NC5h1G7wpg==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-darwin-arm64@0.86.0': + resolution: {integrity: sha512-dJls3eCO1Y2dc4zAdA+fiRbQwlvFFDmfRHRpGOllwS1FtvKQ7dMkRFKsHODEdxWakxISLvyabUmkGOhcJ47Dog==} + engines: {node: '>=14.0.0'} + cpu: [arm64] + os: [darwin] - '@smithy/eventstream-codec@4.2.14': - resolution: {integrity: sha512-erZq0nOIpzfeZdCyzZjdJb4nVSKLUmSkaQUVkRGQTXs30gyUGeKnrYEg+Xe1W5gE3aReS7IgsvANwVPxSzY6Pw==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-darwin-x64@0.86.0': + resolution: {integrity: sha512-udMZFZn6FEy36tVMs/yrczEqWyCJc+l/lqIMS4xYWsm/6qVafUWDSAZJLgcPilng16IdMnHINkc8NSz7Pp1EVw==} + engines: {node: '>=14.0.0'} + cpu: [x64] + os: [darwin] - '@smithy/eventstream-serde-browser@4.2.14': - resolution: {integrity: sha512-8IelTCtTctWRbb+0Dcy+C0aICh1qa0qWXqgjcXDmMuCvPJRnv26hiDZoAau2ILOniki65mCPKqOQs/BaWvO4CQ==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-freebsd-x64@0.86.0': + resolution: {integrity: sha512-41J5qSlypbE0HCOd+4poFD96+ZKoR8sfDn5qdaU0Hc5bT5Drwat/wv06s9Y5Lu86uXYTwPPj6kbbxHHsiV2irw==} + engines: {node: '>=14.0.0'} + cpu: [x64] + os: [freebsd] - '@smithy/eventstream-serde-config-resolver@4.3.14': - resolution: {integrity: sha512-sqHiHpYRYo3FJlaIxD1J8PhbcmJAm7IuM16mVnwSkCToD7g00IBZzKuiLNMGmftULmEUX6/UAz8/NN5uMP8bVA==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-linux-arm-gnueabihf@0.86.0': + resolution: {integrity: sha512-mrI+nKgwRsr4FYjb0pECrNTVnNvHAflukS3SFqFHI8n+3LJgrCYDcnbrFD/4VWKp2EUrkIZ//RhwgGsTiSXbng==} + engines: {node: '>=14.0.0'} + cpu: [arm] + os: [linux] - '@smithy/eventstream-serde-node@4.2.14': - resolution: {integrity: sha512-Ht/8BuGlKfFTy0H3+8eEu0vdpwGztCnaLLXtpXNdQqiR7Hj4vFScU3T436vRAjATglOIPjJXronY+1WxxNLSiw==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-linux-arm-musleabihf@0.86.0': + resolution: {integrity: sha512-FXWyvpxiEXBewA3L6HGFtEribqFjGOiounD8ke/4C1F5134+rH5rNrgK6vY116P4MtWKfZolMRdvlzaD3TaX0A==} + engines: {node: '>=14.0.0'} + cpu: [arm] + os: [linux] - '@smithy/eventstream-serde-universal@4.2.14': - resolution: {integrity: sha512-lWyt4T2XQZUZgK3tQ3Wn0w3XBvZsK/vjTuJl6bXbnGZBHH0ZUSONTYiK9TgjTTzU54xQr3DRFwpjmhp0oLm3gg==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-linux-arm64-gnu@0.86.0': + resolution: {integrity: sha512-gktU/9WLAc0d2hAq8yRi3K92xwkWoDt1gJmokMOfb1FU4fyDbzbt13jdZEd6KVn2xLaiQeaFTTfFTghFsJUM3A==} + engines: {node: '>=14.0.0'} + cpu: [arm64] + os: [linux] - '@smithy/fetch-http-handler@5.3.17': - resolution: {integrity: sha512-bXOvQzaSm6MnmLaWA1elgfQcAtN4UP3vXqV97bHuoOrHQOJiLT3ds6o9eo5bqd0TJfRFpzdGnDQdW3FACiAVdw==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-linux-arm64-musl@0.86.0': + resolution: {integrity: sha512-2w5e5qiTBYQ0xc1aSY1GNyAOP9BQFEjN43FI3OhrRWZXHOj3inqcVSlptO/hHGK3Q2bG26kWLfSNFOEylTX39A==} + engines: {node: '>=14.0.0'} + cpu: [arm64] + os: [linux] - '@smithy/hash-node@4.2.14': - resolution: {integrity: sha512-8ZBDY2DD4wr+GGjTpPtiglEsqr0lUP+KHqgZcWczFf6qeZ/YRjMIOoQWVQlmwu7EtxKTd8YXD8lblmYcpBIA1g==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-linux-riscv64-gnu@0.86.0': + resolution: {integrity: sha512-PfnTYm+vQ9X5VNXqs0Z3S67Xp2FoZj5RteYKUNwL+j/sxGi05eps+EWLVrcGsuN9x2GHFpTiqBz3lzERCn2USg==} + engines: {node: '>=14.0.0'} + cpu: [riscv64] + os: [linux] - '@smithy/invalid-dependency@4.2.14': - resolution: {integrity: sha512-c21qJiTSb25xvvOp+H2TNZzPCngrvl5vIPqPB8zQ/DmJF4QWXO19x1dWfMJZ6wZuuWUPPm0gV8C0cU3+ifcWuw==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-linux-s390x-gnu@0.86.0': + resolution: {integrity: sha512-uHgGN0rFfqDcdkLUITshqrpV34PRKAiRwsw6Jgkg7CRcRGIU8rOJc568EU0jfhTZ1zO5MJKt/S8D6cgIFJwe0A==} + engines: {node: '>=14.0.0'} + cpu: [s390x] + os: [linux] - '@smithy/is-array-buffer@2.2.0': - resolution: {integrity: sha512-GGP3O9QFD24uGeAXYUjwSTXARoqpZykHadOmA8G5vfJPK0/DC67qa//0qvqrJzL1xc8WQWX7/yc7fwudjPHPhA==} + '@oxc-transform/binding-linux-x64-gnu@0.86.0': + resolution: {integrity: sha512-MtrvfU2RkSD+oTnzG4Xle3jK8FXJPQa1MhYQm0ivcAMf0tUQDojTaqBtM/9E0iFr/4l1xZODJOHCGjLktdpykg==} engines: {node: '>=14.0.0'} + cpu: [x64] + os: [linux] - '@smithy/is-array-buffer@4.2.2': - resolution: {integrity: sha512-n6rQ4N8Jj4YTQO3YFrlgZuwKodf4zUFs7EJIWH86pSCWBaAtAGBFfCM7Wx6D2bBJ2xqFNxGBSrUWswT3M0VJow==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-linux-x64-musl@0.86.0': + resolution: {integrity: sha512-wTTTIPcnoS04SRJ7HuOL/VxIu1QzUtv2n6Mx0wPIEQobj2qPGum0qYGnFEMU0Njltp+8FAUg5EfX6u3udRQBbQ==} + engines: {node: '>=14.0.0'} + cpu: [x64] + os: [linux] - '@smithy/middleware-content-length@4.2.14': - resolution: {integrity: sha512-xhHq7fX4/3lv5NHxLUk3OeEvl0xZ+Ek3qIbWaCL4f9JwgDZEclPBElljaZCAItdGPQl/kSM4LPMOpy1MYgprpw==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-wasm32-wasi@0.86.0': + resolution: {integrity: sha512-g+0bf+ZA2DvBHQ+0u8TvEY8ERo86Brqvdghfv06Wph2qGTlhzSmrE0c0Zurr7yhtqI5yZjMaBr2HbqwW1kHFng==} + engines: {node: '>=14.0.0'} + cpu: [wasm32] - '@smithy/middleware-endpoint@4.4.32': - resolution: {integrity: sha512-ZZkgyjnJppiZbIm6Qbx92pbXYi1uzenIvGhBSCDlc7NwuAkiqSgS75j1czAD25ZLs2FjMjYy1q7gyRVWG6JA0Q==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-win32-arm64-msvc@0.86.0': + resolution: {integrity: sha512-dgBeU4qBEag0rhW3OT9YHgj4cvW51KZzrxhDQ1gAVX2fqgl+CeJnu0a9q+DMhefHrO3c8Yxwbt7NxUDmWGkEtg==} + engines: {node: '>=14.0.0'} + cpu: [arm64] + os: [win32] - '@smithy/middleware-retry@4.5.5': - resolution: {integrity: sha512-wnYOpB5vATFKWrY2Z9Alb0KhjZI6AbzU6Fbz3Hq2GnURdRYWB4q+qWivQtSTwXcmWUA3MZ6krfwL6Cq5MAbxsA==} - engines: {node: '>=18.0.0'} + '@oxc-transform/binding-win32-x64-msvc@0.86.0': + resolution: {integrity: sha512-M1eCl8xz7MmEatuqWdr+VdvNCUJ+d4ECF+HND39PqRCVkaH+Vl1rcyP5pLILb2CB/wTb2DMvZmb9RCt5+8S5TQ==} + engines: {node: '>=14.0.0'} + cpu: [x64] + os: [win32] - '@smithy/middleware-serde@4.2.20': - resolution: {integrity: sha512-Lx9JMO9vArPtiChE3wbEZ5akMIDQpWQtlu90lhACQmNOXcGXRbaDywMHDzuDZ2OkZzP+9wQfZi3YJT9F67zTQQ==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-android-arm64@2.5.1': + resolution: {integrity: sha512-KF8+j9nNbUN8vzOFDpRMsaKBHZ/mcjEjMToVMJOhTozkDonQFFrRcfdLWn6yWKCmJKmdVxSgHiYvTCef4/qcBA==} + engines: {node: '>= 10.0.0'} + cpu: [arm64] + os: [android] - '@smithy/middleware-stack@4.2.14': - resolution: {integrity: sha512-2dvkUKLuFdKsCRmOE4Mn63co0Djtsm+JMh0bYZQupN1pJwMeE8FmQmRLLzzEMN0dnNi7CDCYYH8F0EVwWiPBeA==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-darwin-arm64@2.5.1': + resolution: {integrity: sha512-eAzPv5osDmZyBhou8PoF4i6RQXAfeKL9tjb3QzYuccXFMQU0ruIc/POh30ePnaOyD1UXdlKguHBmsTs53tVoPw==} + engines: {node: '>= 10.0.0'} + cpu: [arm64] + os: [darwin] - '@smithy/node-config-provider@4.3.14': - resolution: {integrity: sha512-S+gFjyo/weSVL0P1b9Ts8C/CwIfNCgUPikk3sl6QVsfE/uUuO+QsF+NsE/JkpvWqqyz1wg7HFdiaZuj5CoBMRg==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-darwin-x64@2.5.1': + resolution: {integrity: sha512-1ZXDthrnNmwv10A0/3AJNZ9JGlzrF82i3gNQcWOzd7nJ8aj+ILyW1MTxVk35Db0u91oD5Nlk9MBiujMlwmeXZg==} + engines: {node: '>= 10.0.0'} + cpu: [x64] + os: [darwin] - '@smithy/node-http-handler@4.6.1': - resolution: {integrity: sha512-iB+orM4x3xrr57X3YaXazfKnntl0LHlZB1kcXSGzMV1Tt0+YwEjGlbjk/44qEGtBzXAz6yFDzkYTKSV6Pj2HUg==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-freebsd-x64@2.5.1': + resolution: {integrity: sha512-SI4eljM7Flp9yPuKi8W0ird8TI/JK6CSxju3NojVI6BjHsTyK7zxA9urjVjEKJ5MBYC+bLmMcbAWlZ+rFkLpJQ==} + engines: {node: '>= 10.0.0'} + cpu: [x64] + os: [freebsd] - '@smithy/property-provider@4.2.14': - resolution: {integrity: sha512-WuM31CgfsnQ/10i7NYr0PyxqknD72Y5uMfUMVSniPjbEPceiTErb4eIqJQ+pdxNEAUEWrewrGjIRjVbVHsxZiQ==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-linux-arm-glibc@2.5.1': + resolution: {integrity: sha512-RCdZlEyTs8geyBkkcnPWvtXLY44BCeZKmGYRtSgtwwnHR4dxfHRG3gR99XdMEdQ7KeiDdasJwwvNSF5jKtDwdA==} + engines: {node: '>= 10.0.0'} + cpu: [arm] + os: [linux] - '@smithy/protocol-http@5.3.14': - resolution: {integrity: sha512-dN5F8kHx8RNU0r+pCwNmFZyz6ChjMkzShy/zup6MtkRmmix4vZzJdW+di7x//b1LiynIev88FM18ie+wwPcQtQ==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-linux-arm-musl@2.5.1': + resolution: {integrity: sha512-6E+m/Mm1t1yhB8X412stiKFG3XykmgdIOqhjWj+VL8oHkKABfu/gjFj8DvLrYVHSBNC+/u5PeNrujiSQ1zwd1Q==} + engines: {node: '>= 10.0.0'} + cpu: [arm] + os: [linux] - '@smithy/querystring-builder@4.2.14': - resolution: {integrity: sha512-XYA5Z0IqTeF+5XDdh4BBmSA0HvbgVZIyv4cmOoUheDNR57K1HgBp9ukUMx3Cr3XpDHHpLBnexPE3LAtDsZkj2A==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-linux-arm64-glibc@2.5.1': + resolution: {integrity: sha512-LrGp+f02yU3BN9A+DGuY3v3bmnFUggAITBGriZHUREfNEzZh/GO06FF5u2kx8x+GBEUYfyTGamol4j3m9ANe8w==} + engines: {node: '>= 10.0.0'} + cpu: [arm64] + os: [linux] - '@smithy/querystring-parser@4.2.14': - resolution: {integrity: sha512-hr+YyqBD23GVvRxGGrcc/oOeNlK3PzT5Fu4dzrDXxzS1LpFiuL2PQQqKPs87M79aW7ziMs+nvB3qdw77SqE7Lw==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-linux-arm64-musl@2.5.1': + resolution: {integrity: sha512-cFOjABi92pMYRXS7AcQv9/M1YuKRw8SZniCDw0ssQb/noPkRzA+HBDkwmyOJYp5wXcsTrhxO0zq1U11cK9jsFg==} + engines: {node: '>= 10.0.0'} + cpu: [arm64] + os: [linux] - '@smithy/service-error-classification@4.3.0': - resolution: {integrity: sha512-9jKsBYQRPR0xBLgc2415RsA5PIcP2sis4oBdN9s0D13cg1B1284mNTjx9Yc+BEERXzuPm5ObktI96OxsKh8E9A==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-linux-x64-glibc@2.5.1': + resolution: {integrity: sha512-GcESn8NZySmfwlTsIur+49yDqSny2IhPeZfXunQi48DMugKeZ7uy1FX83pO0X22sHntJ4Ub+9k34XQCX+oHt2A==} + engines: {node: '>= 10.0.0'} + cpu: [x64] + os: [linux] - '@smithy/shared-ini-file-loader@4.4.9': - resolution: {integrity: sha512-495/V2I15SHgedSJoDPD23JuSfKAp726ZI1V0wtjB07Wh7q/0tri/0e0DLefZCHgxZonrGKt/OCTpAtP1wE1kQ==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-linux-x64-musl@2.5.1': + resolution: {integrity: sha512-n0E2EQbatQ3bXhcH2D1XIAANAcTZkQICBPVaxMeaCVBtOpBZpWJuf7LwyWPSBDITb7In8mqQgJ7gH8CILCURXg==} + engines: {node: '>= 10.0.0'} + cpu: [x64] + os: [linux] - '@smithy/signature-v4@5.3.14': - resolution: {integrity: sha512-1D9Y/nmlVjCeSivCbhZ7hgEpmHyY1h0GvpSZt3l0xcD9JjmjVC1CHOozS6+Gh+/ldMH8JuJ6cujObQqfayAVFA==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-wasm@2.4.1': + resolution: {integrity: sha512-/ZR0RxqxU/xxDGzbzosMjh4W6NdYFMqq2nvo2b8SLi7rsl/4jkL8S5stIikorNkdR50oVDvqb/3JT05WM+CRRA==} + engines: {node: '>= 10.0.0'} + bundledDependencies: + - napi-wasm - '@smithy/smithy-client@4.12.13': - resolution: {integrity: sha512-y/Pcj1V9+qG98gyu1gvftHB7rDpdh+7kIBIggs55yGm3JdtBV8GT8IFF3a1qxZ79QnaJHX9GXzvBG6tAd+czJA==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-wasm@2.5.1': + resolution: {integrity: sha512-RJxlQQLkaMMIuWRozy+z2vEqbaQlCuaCgVZIUCzQLYggY22LZbP5Y1+ia+FD724Ids9e+XIyOLXLrLgQSHIthw==} + engines: {node: '>= 10.0.0'} + bundledDependencies: + - napi-wasm - '@smithy/types@4.14.1': - resolution: {integrity: sha512-59b5HtSVrVR/eYNei3BUj3DCPKD/G7EtDDe7OEJE7i7FtQFugYo6MxbotS8mVJkLNVf8gYaAlEBwwtJ9HzhWSg==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-win32-arm64@2.5.1': + resolution: {integrity: sha512-RFzklRvmc3PkjKjry3hLF9wD7ppR4AKcWNzH7kXR7GUe0Igb3Nz8fyPwtZCSquGrhU5HhUNDr/mKBqj7tqA2Vw==} + engines: {node: '>= 10.0.0'} + cpu: [arm64] + os: [win32] - '@smithy/url-parser@4.2.14': - resolution: {integrity: sha512-p06BiBigJ8bTA3MgnOfCtDUWnAMY0YfedO/GRpmc7p+wg3KW8vbXy1xwSu5ASy0wV7rRYtlfZOIKH4XqfhjSQQ==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-win32-ia32@2.5.1': + resolution: {integrity: sha512-c2KkcVN+NJmuA7CGlaGD1qJh1cLfDnQsHjE89E60vUEMlqduHGCdCLJCID5geFVM0dOtA3ZiIO8BoEQmzQVfpQ==} + engines: {node: '>= 10.0.0'} + cpu: [ia32] + os: [win32] - '@smithy/util-base64@4.3.2': - resolution: {integrity: sha512-XRH6b0H/5A3SgblmMa5ErXQ2XKhfbQB+Fm/oyLZ2O2kCUrwgg55bU0RekmzAhuwOjA9qdN5VU2BprOvGGUkOOQ==} - engines: {node: '>=18.0.0'} + '@parcel/watcher-win32-x64@2.5.1': + resolution: {integrity: sha512-9lHBdJITeNR++EvSQVUcaZoWupyHfXe1jZvGZ06O/5MflPcuPLtEphScIBL+AiCWBO46tDSHzWyD0uDmmZqsgA==} + engines: {node: '>= 10.0.0'} + cpu: [x64] + os: [win32] - '@smithy/util-body-length-browser@4.2.2': - resolution: {integrity: sha512-JKCrLNOup3OOgmzeaKQwi4ZCTWlYR5H4Gm1r2uTMVBXoemo1UEghk5vtMi1xSu2ymgKVGW631e2fp9/R610ZjQ==} - engines: {node: '>=18.0.0'} + '@parcel/watcher@2.5.1': + resolution: {integrity: sha512-dfUnCxiN9H4ap84DvD2ubjw+3vUNpstxa0TneY/Paat8a3R4uQZDLSvWjmznAY/DoahqTHl9V46HF/Zs3F29pg==} + engines: {node: '>= 10.0.0'} - '@smithy/util-body-length-node@4.2.3': - resolution: {integrity: sha512-ZkJGvqBzMHVHE7r/hcuCxlTY8pQr1kMtdsVPs7ex4mMU+EAbcXppfo5NmyxMYi2XU49eqaz56j2gsk4dHHPG/g==} - engines: {node: '>=18.0.0'} + '@paulmillr/qr@0.2.1': + resolution: {integrity: sha512-IHnV6A+zxU7XwmKFinmYjUcwlyK9+xkG3/s9KcQhI9BjQKycrJ1JRO+FbNYPwZiPKW3je/DR0k7w8/gLa5eaxQ==} + deprecated: 'The package is now available as "qr": npm install qr' - '@smithy/util-buffer-from@2.2.0': - resolution: {integrity: sha512-IJdWBbTcMQ6DA0gdNhh/BwrLkDR+ADW5Kr1aZmd4k3DIF6ezMV4R2NIAmT08wQJ3yUK82thHWmC/TnK/wpMMIA==} - engines: {node: '>=14.0.0'} + '@pkgjs/parseargs@0.11.0': + resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==} + engines: {node: '>=14'} - '@smithy/util-buffer-from@4.2.2': - resolution: {integrity: sha512-FDXD7cvUoFWwN6vtQfEta540Y/YBe5JneK3SoZg9bThSoOAC/eGeYEua6RkBgKjGa/sz6Y+DuBZj3+YEY21y4Q==} - engines: {node: '>=18.0.0'} + '@polka/url@1.0.0-next.29': + resolution: {integrity: sha512-wwQAWhWSuHaag8c4q/KN/vCoeOJYshAIvMQwD4GpSb3OiZklFfvAgmj0VCBBImRpuF/aFgIRzllXlVX93Jevww==} - '@smithy/util-config-provider@4.2.2': - resolution: {integrity: sha512-dWU03V3XUprJwaUIFVv4iOnS1FC9HnMHDfUrlNDSh4315v0cWyaIErP8KiqGVbf5z+JupoVpNM7ZB3jFiTejvQ==} - engines: {node: '>=18.0.0'} + '@poppinss/colors@4.1.6': + resolution: {integrity: sha512-H9xkIdFswbS8n1d6vmRd8+c10t2Qe+rZITbbDHHkQixH5+2x1FDGmi/0K+WgWiqQFKPSlIYB7jlH6Kpfn6Fleg==} - '@smithy/util-defaults-mode-browser@4.3.49': - resolution: {integrity: sha512-a5bNrdiONYB/qE2BuKegvUMd/+ZDwdg4vsNuuSzYE8qs2EYAdK9CynL+Rzn29PbPiUqoz/cbpRbcLzD5lEevHw==} - engines: {node: '>=18.0.0'} + '@poppinss/dumper@0.6.5': + resolution: {integrity: sha512-NBdYIb90J7LfOI32dOewKI1r7wnkiH6m920puQ3qHUeZkxNkQiFnXVWoE6YtFSv6QOiPPf7ys6i+HWWecDz7sw==} - '@smithy/util-defaults-mode-node@4.2.54': - resolution: {integrity: sha512-g1cvrJvOnzeJgEdf7AE4luI7gp6L8weE0y9a9wQUSGtjb8QRHDbCJYuE4Sy0SD9N8RrnNPFsPltAz/OSoBR9Zw==} - engines: {node: '>=18.0.0'} + '@poppinss/exception@1.2.3': + resolution: {integrity: sha512-dCED+QRChTVatE9ibtoaxc+WkdzOSjYTKi/+uacHWIsfodVfpsueo3+DKpgU5Px8qXjgmXkSvhXvSCz3fnP9lw==} - '@smithy/util-endpoints@3.4.2': - resolution: {integrity: sha512-a55Tr+3OKld4TTtnT+RhKOQHyPxm3j/xL4OR83WBUhLJaKDS9dnJ7arRMOp3t31dcLhApwG9bgvrRXBHlLdIkg==} - engines: {node: '>=18.0.0'} + '@publint/pack@0.1.2': + resolution: {integrity: sha512-S+9ANAvUmjutrshV4jZjaiG8XQyuJIZ8a4utWmN/vW1sgQ9IfBnPndwkmQYw53QmouOIytT874u65HEmu6H5jw==} + engines: {node: '>=18'} - '@smithy/util-hex-encoding@4.2.2': - resolution: {integrity: sha512-Qcz3W5vuHK4sLQdyT93k/rfrUwdJ8/HZ+nMUOyGdpeGA1Wxt65zYwi3oEl9kOM+RswvYq90fzkNDahPS8K0OIg==} - engines: {node: '>=18.0.0'} + '@radix-ui/number@1.1.1': + resolution: {integrity: sha512-MkKCwxlXTgz6CFoJx3pCwn07GKp36+aZyu/u2Ln2VrA5DcdyCZkASEDBTd8x5whTQQL5CiYf4prXKLcgQdv29g==} - '@smithy/util-middleware@4.2.14': - resolution: {integrity: sha512-1Su2vj9RYNDEv/V+2E+jXkkwGsgR7dc4sfHn9Z7ruzQHJIEni9zzw5CauvRXlFJfmgcqYP8fWa0dkh2Q2YaQyw==} - engines: {node: '>=18.0.0'} + '@radix-ui/primitive@1.1.3': + resolution: {integrity: sha512-JTF99U/6XIjCBo0wqkU5sK10glYe27MRRsfwoiq5zzOEZLHU3A3KCMa5X/azekYRCJ0HlwI0crAXS/5dEHTzDg==} - '@smithy/util-retry@4.3.4': - resolution: {integrity: sha512-FY1UQQ1VFmMwiYp1GVS4MeaGD5O0blLNYK0xCRHU+mJgeoH/hSY8Ld8sJWKQ6uznkh14HveRGQJncgPyNl9J+A==} - engines: {node: '>=18.0.0'} + '@radix-ui/react-arrow@1.1.7': + resolution: {integrity: sha512-F+M1tLhO+mlQaOWspE8Wstg+z6PwxwRd8oQ8IXceWz92kfAmalTRf0EjrouQeo7QssEPfCn05B4Ihs1K9WQ/7w==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@smithy/util-stream@4.5.25': - resolution: {integrity: sha512-/PFpG4k8Ze8Ei+mMKj3oiPICYekthuzePZMgZbCqMiXIHHf4n2aZ4Ps0aSRShycFTGuj/J6XldmC0x0DwednIA==} - engines: {node: '>=18.0.0'} + '@radix-ui/react-aspect-ratio@1.1.8': + resolution: {integrity: sha512-5nZrJTF7gH+e0nZS7/QxFz6tJV4VimhQb1avEgtsJxvvIp5JilL+c58HICsKzPxghdwaDt48hEfPM1au4zGy+w==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@smithy/util-uri-escape@4.2.2': - resolution: {integrity: sha512-2kAStBlvq+lTXHyAZYfJRb/DfS3rsinLiwb+69SstC9Vb0s9vNWkRwpnj918Pfi85mzi42sOqdV72OLxWAISnw==} - engines: {node: '>=18.0.0'} + '@radix-ui/react-checkbox@1.3.3': + resolution: {integrity: sha512-wBbpv+NQftHDdG86Qc0pIyXk5IR3tM8Vd0nWLKDcX8nNn4nXFOFwsKuqw2okA/1D/mpaAkmuyndrPJTYDNZtFw==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@smithy/util-utf8@2.3.0': - resolution: {integrity: sha512-R8Rdn8Hy72KKcebgLiv8jQcQkXoLMOGGv5uI1/k0l+snqkOzQ1R0ChUBCxWMlBsFMekWjq0wRudIweFs7sKT5A==} - engines: {node: '>=14.0.0'} + '@radix-ui/react-collapsible@1.1.12': + resolution: {integrity: sha512-Uu+mSh4agx2ib1uIGPP4/CKNULyajb3p92LsVXmH2EHVMTfZWpll88XJ0j4W0z3f8NK1eYl1+Mf/szHPmcHzyA==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@smithy/util-utf8@4.2.2': - resolution: {integrity: sha512-75MeYpjdWRe8M5E3AW0O4Cx3UadweS+cwdXjwYGBW5h/gxxnbeZ877sLPX/ZJA9GVTlL/qG0dXP29JWFCD1Ayw==} - engines: {node: '>=18.0.0'} + '@radix-ui/react-collection@1.1.7': + resolution: {integrity: sha512-Fh9rGN0MoI4ZFUNyfFVNU4y9LUz93u9/0K+yLgA2bwRojxM8JU1DyvvMBabnZPBgMWREAJvU2jjVzq+LrFUglw==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@smithy/util-waiter@4.2.16': - resolution: {integrity: sha512-GtclrKoZ3Lt7jPQ7aTIYKfjY92OgceScftVnkTsG8e1KV8rkvZgN+ny6YSRhd9hxB8rZtwVbmln7NTvE5O3GmQ==} - engines: {node: '>=18.0.0'} + '@radix-ui/react-compose-refs@1.1.2': + resolution: {integrity: sha512-z4eqJvfiNnFMHIIvXP3CY57y2WJs5g2v3X0zm9mEJkrkNv4rDxu+sg9Jh8EkXyeqBkB7SOcboo9dMVqhyrACIg==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@smithy/uuid@1.1.2': - resolution: {integrity: sha512-O/IEdcCUKkubz60tFbGA7ceITTAJsty+lBjNoorP4Z6XRqaFb/OjQjZODophEcuq68nKm6/0r+6/lLQ+XVpk8g==} - engines: {node: '>=18.0.0'} + '@radix-ui/react-context@1.1.2': + resolution: {integrity: sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@solidity-parser/parser@0.14.5': - resolution: {integrity: sha512-6dKnHZn7fg/iQATVEzqyUOyEidbn05q7YA2mQ9hC0MMXhhV3/JrsxmFSYZAcr7j1yUP700LLhTruvJ3MiQmjJg==} + '@radix-ui/react-context@1.1.3': + resolution: {integrity: sha512-ieIFACdMpYfMEjF0rEf5KLvfVyIkOz6PDGyNnP+u+4xQ6jny3VCgA4OgXOwNx2aUkxn8zx9fiVcM8CfFYv9Lxw==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@solidity-parser/parser@0.16.2': - resolution: {integrity: sha512-PI9NfoA3P8XK2VBkK5oIfRgKDsicwDZfkVq9ZTBCQYGOP1N2owgY2dyLGyU5/J/hQs8KRk55kdmvTLjy3Mu3vg==} + '@radix-ui/react-dialog@1.1.15': + resolution: {integrity: sha512-TCglVRtzlffRNxRMEyR36DGBLJpeusFcgMVD9PZEzAKnUs1lKCgX5u9BmC2Yg+LL9MgZDugFFs1Vl+Jp4t/PGw==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@solidity-parser/parser@0.20.2': - resolution: {integrity: sha512-rbu0bzwNvMcwAjH86hiEAcOeRI2EeK8zCkHDrFykh/Al8mvJeFmjy3UrE7GYQjNwOgbGUUtCn5/k8CB8zIu7QA==} + '@radix-ui/react-direction@1.1.1': + resolution: {integrity: sha512-1UEWRX6jnOA2y4H5WczZ44gOOjTEmlqv1uNW4GAJEO5+bauCBhv8snY65Iw5/VOS/ghKN9gr2KjnLKxrsvoMVw==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@standard-schema/spec@1.0.0': - resolution: {integrity: sha512-m2bOd0f2RT9k8QJx1JN85cZYyH1RqFBdlwtkSlf4tBDYLCiiZnv1fIIwacK6cqwXavOydf0NPToMQgpKq+dVlA==} + '@radix-ui/react-dismissable-layer@1.1.11': + resolution: {integrity: sha512-Nqcp+t5cTB8BinFkZgXiMJniQH0PsUt2k51FUhbdfeKvc4ACcG2uQniY/8+h1Yv6Kza4Q7lD7PQV0z0oicE0Mg==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@streamparser/json-node@0.0.22': - resolution: {integrity: sha512-sJT2ptNRwqB1lIsQrQlCoWk5rF4tif9wDh+7yluAGijJamAhrHGYpFB/Zg3hJeceoZypi74ftXk8DHzwYpbZSg==} + '@radix-ui/react-dropdown-menu@2.1.16': + resolution: {integrity: sha512-1PLGQEynI/3OX/ftV54COn+3Sud/Mn8vALg2rWnBLnRaGtJDduNW/22XjlGgPdpcIbiQxjKtb7BkcjP00nqfJw==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@streamparser/json@0.0.22': - resolution: {integrity: sha512-b6gTSBjJ8G8SuO3Gbbj+zXbVx8NSs1EbpbMKpzGLWMdkR+98McH9bEjSz3+0mPJf68c5nxa3CrJHp5EQNXM6zQ==} + '@radix-ui/react-focus-guards@1.1.3': + resolution: {integrity: sha512-0rFg/Rj2Q62NCm62jZw0QX7a3sz6QCQU0LpZdNrJX8byRGaGVTqbrW9jAoIAHyMQqsNpeZ81YgSizOt5WXq0Pw==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@swc/helpers@0.5.15': - resolution: {integrity: sha512-JQ5TuMi45Owi4/BIMAJBoSQoOJu12oOk/gADqlcUL9JEdHB8vyjUSsxqeNXnmXHjYKMi2WcYtezGEEhqUI/E2g==} + '@radix-ui/react-focus-scope@1.1.7': + resolution: {integrity: sha512-t2ODlkXBQyn7jkl6TNaw/MtVEVvIGelJDCG41Okq/KwUsJBwQ4XVZsHAVUkK4mBv3ewiAS3PGuUWuY2BoK4ZUw==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@szmarczak/http-timer@4.0.6': - resolution: {integrity: sha512-4BAffykYOgO+5nzBWYwE3W90sBgLJoUPRWWcL8wlyiM8IB8ipJz3UMJ9KXQd1RKQXpKp8Tutn80HZtWsu2u76w==} - engines: {node: '>=10'} + '@radix-ui/react-id@1.1.1': + resolution: {integrity: sha512-kGkGegYIdQsOb4XjsfM97rXsiHaBwco+hFI66oO4s9LU+PLAC5oJ7khdOVFxkhsmlbpUqDAvXw11CluXP+jkHg==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@szmarczak/http-timer@5.0.1': - resolution: {integrity: sha512-+PmQX0PiAYPMeVYe237LJAYvOMYW1j2rH5YROyS3b4CTVJum34HfRvKvAzozHAQG0TnHNdUfY9nCeUyRAs//cw==} - engines: {node: '>=14.16'} + '@radix-ui/react-menu@2.1.16': + resolution: {integrity: sha512-72F2T+PLlphrqLcAotYPp0uJMr5SjP5SL01wfEspJbru5Zs5vQaSHb4VB3ZMJPimgHHCHG7gMOeOB9H3Hdmtxg==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@tenderly/api-client@1.1.0': - resolution: {integrity: sha512-kyye7TQ+RbDbJ7bSUjNf/O9fTtRYNUDIEUZQSrmNonowMw5/EpNi664eWaOoC00NEzxgttVrtme/GHvIOu7rNg==} + '@radix-ui/react-popper@1.2.8': + resolution: {integrity: sha512-0NJQ4LFFUuWkE7Oxf0htBKS6zLkkjBH+hM1uk7Ng705ReR8m/uelduy1DBo0PyBXPKVnBA6YBlU94MBGXrSBCw==} peerDependencies: - ts-node: '*' - typescript: '*' + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc peerDependenciesMeta: - ts-node: + '@types/react': optional: true - typescript: + '@types/react-dom': optional: true - '@tenderly/hardhat-integration@1.1.1': - resolution: {integrity: sha512-VHa380DrKv+KA1N4vbJGLDoghbVqMZ4wEozbxRfCzlkSs5V1keNgudRSUFK6lgfKhkoAWRO+dA8MZYnJOvUOkA==} + '@radix-ui/react-portal@1.1.9': + resolution: {integrity: sha512-bpIxvq03if6UNwXZ+HTK71JLh4APvnXntDc6XOX8UVq4XQOVl7lwok0AvIl+b8zgCw3fSaVTZMpAPPagXbKmHQ==} peerDependencies: - hardhat: ^2.22.6 + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@tenderly/hardhat-tenderly@2.5.2': - resolution: {integrity: sha512-JCG1UkFBRZE2fL8g4jfbKUsju7gK3Dg6CxksJO9Db9ckM1EkL4wCY9G5KTLwh/UL0cT04J8ZK1RmaZ6hG8wfKA==} + '@radix-ui/react-presence@1.1.5': + resolution: {integrity: sha512-/jfEwNDdQVBCNvjkGit4h6pMOzq8bHkopq458dPt2lMjx+eBQUohZNG9A7DtO/O5ukSbxuaNGXMjHicgwy6rQQ==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@tootallnate/quickjs-emscripten@0.23.0': - resolution: {integrity: sha512-C5Mc6rdnsaJDjO3UpGW/CQTHtCKaYlScZTly4JIu97Jxo/odCiH0ITnDXSJPTOrEKk/ycSZ0AOgTmkDtkOsvIA==} + '@radix-ui/react-primitive@2.1.3': + resolution: {integrity: sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@trufflesuite/bigint-buffer@1.1.9': - resolution: {integrity: sha512-bdM5cEGCOhDSwminryHJbRmXc1x7dPKg6Pqns3qyTwFlxsqUgxE29lsERS3PlIW1HTjoIGMUqsk1zQQwST1Yxw==} - engines: {node: '>= 10.0.0'} + '@radix-ui/react-primitive@2.1.4': + resolution: {integrity: sha512-9hQc4+GNVtJAIEPEqlYqW5RiYdrr8ea5XQ0ZOnD6fgru+83kqT15mq2OCcbe8KnjRZl5vF3ks69AKz3kh1jrhg==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@trufflesuite/uws-js-unofficial@20.30.0-unofficial.0': - resolution: {integrity: sha512-r5X0aOQcuT6pLwTRLD+mPnAM/nlKtvIK4Z+My++A8tTOR0qTjNRx8UB8jzRj3D+p9PMAp5LnpCUUGmz7/TppwA==} + '@radix-ui/react-progress@1.1.8': + resolution: {integrity: sha512-+gISHcSPUJ7ktBy9RnTqbdKW78bcGke3t6taawyZ71pio1JewwGSJizycs7rLhGTvMJYCQB1DBK4KQsxs7U8dA==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@tsconfig/node10@1.0.12': - resolution: {integrity: sha512-UCYBaeFvM11aU2y3YPZ//O5Rhj+xKyzy7mvcIoAjASbigy8mHMryP5cK7dgjlz2hWxh1g5pLw084E0a/wlUSFQ==} + '@radix-ui/react-radio-group@1.3.8': + resolution: {integrity: sha512-VBKYIYImA5zsxACdisNQ3BjCBfmbGH3kQlnFVqlWU4tXwjy7cGX8ta80BcrO+WJXIn5iBylEH3K6ZTlee//lgQ==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@tsconfig/node12@1.0.11': - resolution: {integrity: sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==} + '@radix-ui/react-roving-focus@1.1.11': + resolution: {integrity: sha512-7A6S9jSgm/S+7MdtNDSb+IU859vQqJ/QAtcYQcfFC6W8RS4IxIZDldLR0xqCFZ6DCyrQLjLPsxtTNch5jVA4lA==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@tsconfig/node14@1.0.3': - resolution: {integrity: sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==} + '@radix-ui/react-select@2.2.6': + resolution: {integrity: sha512-I30RydO+bnn2PQztvo25tswPH+wFBjehVGtmagkU78yMdwTwVf12wnAOF+AeP8S2N8xD+5UPbGhkUfPyvT+mwQ==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@tsconfig/node16@1.0.4': - resolution: {integrity: sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==} + '@radix-ui/react-slot@1.2.3': + resolution: {integrity: sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@turbo/darwin-64@2.9.6': - resolution: {integrity: sha512-X/56SnVXIQZBLKwniGTwEQTGmtE5brSACnKMBWpY3YafuxVYefrC2acamfjgxP7BG5w3I+6jf0UrLoSzgPcSJg==} - cpu: [x64] - os: [darwin] + '@radix-ui/react-slot@1.2.4': + resolution: {integrity: sha512-Jl+bCv8HxKnlTLVrcDE8zTMJ09R9/ukw4qBs/oZClOfoQk/cOTbDn+NceXfV7j09YPVQUryJPHurafcSg6EVKA==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@turbo/darwin-arm64@2.9.6': - resolution: {integrity: sha512-aalBeSl4agT/QtYGDyf/XLajedWzUC9Vg/pm/YO6QQ93vkQ91Vz5uK1ta5RbVRDozQSz4njxUNqRNmOXDzW+qw==} - cpu: [arm64] - os: [darwin] + '@radix-ui/react-switch@1.2.6': + resolution: {integrity: sha512-bByzr1+ep1zk4VubeEVViV592vu2lHE2BZY5OnzehZqOOgogN80+mNtCqPkhn2gklJqOpxWgPoYTSnhBCqpOXQ==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@turbo/gen@1.13.4': - resolution: {integrity: sha512-PK38N1fHhDUyjLi0mUjv0RbX0xXGwDLQeRSGsIlLcVpP1B5fwodSIwIYXc9vJok26Yne94BX5AGjueYsUT3uUw==} - hasBin: true + '@radix-ui/react-tabs@1.1.13': + resolution: {integrity: sha512-7xdcatg7/U+7+Udyoj2zodtI9H/IIopqo+YOIcZOq1nJwXWBZ9p8xiu5llXlekDbZkca79a/fozEYQXIA4sW6A==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@turbo/linux-64@2.9.6': - resolution: {integrity: sha512-YKi05jnNHaD7vevgYwahpzGwbsNNTwzU2c7VZdmdFm7+cGDP4oREUWSsainiMfRqjRuolQxBwRn8wf1jmu+YZA==} - cpu: [x64] - os: [linux] + '@radix-ui/react-toast@1.2.15': + resolution: {integrity: sha512-3OSz3TacUWy4WtOXV38DggwxoqJK4+eDkNMl5Z/MJZaoUPaP4/9lf81xXMe1I2ReTAptverZUpbPY4wWwWyL5g==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@turbo/linux-arm64@2.9.6': - resolution: {integrity: sha512-02o/ZS69cOYEDczXvOB2xmyrtzjQ2hVFtWZK1iqxXUfzMmTjZK4UumrfNnjckSg+gqeBfnPRHa0NstA173Ik3g==} - cpu: [arm64] - os: [linux] + '@radix-ui/react-tooltip@1.2.8': + resolution: {integrity: sha512-tY7sVt1yL9ozIxvmbtN5qtmH2krXcBCfjEiCgKGLqunJHvgvZG2Pcl2oQ3kbcZARb1BGEHdkLzcYGO8ynVlieg==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@turbo/windows-64@2.9.6': - resolution: {integrity: sha512-wVdQjvnBI15wB6JrA+43CtUtagjIMmX6XYO758oZHAsCNSxqRlJtdyujih0D8OCnwCRWiGWGI63zAxR0hO6s9g==} - cpu: [x64] - os: [win32] + '@radix-ui/react-use-callback-ref@1.1.1': + resolution: {integrity: sha512-FkBMwD+qbGQeMu1cOHnuGB6x4yzPjho8ap5WtbEJ26umhgqVXbhekKUQO+hZEL1vU92a3wHwdp0HAcqAUF5iDg==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@turbo/windows-arm64@2.9.6': - resolution: {integrity: sha512-1XUUyWW0W6FTSqGEhU8RHVqb2wP1SPkr7hIvBlMEwH9jr+sJQK5kqeosLJ/QaUv4ecSAd1ZhIrLoW7qslAzT4A==} - cpu: [arm64] - os: [win32] + '@radix-ui/react-use-controllable-state@1.2.2': + resolution: {integrity: sha512-BjasUjixPFdS+NKkypcyyN5Pmg83Olst0+c6vGov0diwTEo6mgdqVR6hxcEgFuh4QrAs7Rc+9KuGJ9TVCj0Zzg==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@turbo/workspaces@1.13.4': - resolution: {integrity: sha512-3uYg2b5TWCiupetbDFMbBFMHl33xQTvp5DNg0fZSYal73Z9AlFH9yWabHWMYw6ywmwM1evkYRpTVA2n7GgqT5A==} - hasBin: true + '@radix-ui/react-use-effect-event@0.0.2': + resolution: {integrity: sha512-Qp8WbZOBe+blgpuUT+lw2xheLP8q0oatc9UpmiemEICxGvFLYmHm9QowVZGHtJlGbS6A6yJ3iViad/2cVjnOiA==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@typechain/ethers-v5@10.2.1': - resolution: {integrity: sha512-n3tQmCZjRE6IU4h6lqUGiQ1j866n5MTCBJreNEHHVWXa2u9GJTaeYyU1/k+1qLutkyw+sS6VAN+AbeiTqsxd/A==} + '@radix-ui/react-use-escape-keydown@1.1.1': + resolution: {integrity: sha512-Il0+boE7w/XebUHyBjroE+DbByORGR9KKmITzbR7MyQ4akpORYP/ZmbhAr0DG7RmmBqoOnZdy2QlvajJ2QA59g==} peerDependencies: - '@ethersproject/abi': ^5.0.0 - '@ethersproject/providers': ^5.0.0 - ethers: ^5.1.3 - typechain: ^8.1.1 - typescript: '>=4.3.0' + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@typechain/ethers-v5@7.2.0': - resolution: {integrity: sha512-jfcmlTvaaJjng63QsT49MT6R1HFhtO/TBMWbyzPFSzMmVIqb2tL6prnKBs4ZJrSvmgIXWy+ttSjpaxCTq8D/Tw==} + '@radix-ui/react-use-layout-effect@1.1.1': + resolution: {integrity: sha512-RbJRS4UWQFkzHTTwVymMTUv8EqYhOp8dOOviLj2ugtTiXRaRQS7GLGxZTLL1jWhMeoSCf5zmcZkqTl9IiYfXcQ==} peerDependencies: - '@ethersproject/abi': ^5.0.0 - '@ethersproject/bytes': ^5.0.0 - '@ethersproject/providers': ^5.0.0 - ethers: ^5.1.3 - typechain: ^5.0.0 - typescript: '>=4.0.0' + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@typechain/ethers-v6@0.5.1': - resolution: {integrity: sha512-F+GklO8jBWlsaVV+9oHaPh5NJdd6rAKN4tklGfInX1Q7h0xPgVLP39Jl3eCulPB5qexI71ZFHwbljx4ZXNfouA==} + '@radix-ui/react-use-previous@1.1.1': + resolution: {integrity: sha512-2dHfToCj/pzca2Ck724OZ5L0EVrr3eHRNsG/b3xQJLA2hZpVCS99bLAX+hm1IHXDEnzU6by5z/5MIY794/a8NQ==} peerDependencies: - ethers: 6.x - typechain: ^8.3.2 - typescript: '>=4.7.0' + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@types/abstract-leveldown@7.2.5': - resolution: {integrity: sha512-/2B0nQF4UdupuxeKTJA2+Rj1D+uDemo6P4kMwKCpbfpnzeVaWSELTsAw4Lxn3VJD6APtRrZOCuYo+4nHUQfTfg==} + '@radix-ui/react-use-rect@1.1.1': + resolution: {integrity: sha512-QTYuDesS0VtuHNNvMh+CjlKJ4LJickCMUAqjlE3+j8w+RlRpwyX3apEQKGFzbZGdo7XNG1tXa+bQqIE7HIXT2w==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@types/bn.js@4.11.6': - resolution: {integrity: sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==} + '@radix-ui/react-use-size@1.1.1': + resolution: {integrity: sha512-ewrXRDTAqAXlkl6t/fkXWNAhFX9I+CkKlw6zjEwk86RSPKwZr3xpBRso655aqYafwtnbpHLj6toFzmd6xdVptQ==} + peerDependencies: + '@types/react': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - '@types/bn.js@5.2.0': - resolution: {integrity: sha512-DLbJ1BPqxvQhIGbeu8VbUC1DiAiahHtAYvA0ZEAa4P31F7IaArc8z3C3BRQdWX4mtLQuABG4yzp76ZrS02Ui1Q==} + '@radix-ui/react-visually-hidden@1.2.3': + resolution: {integrity: sha512-pzJq12tEaaIhqjbzpCuv/OypJY/BPavOofm+dbab+MHLajy277+1lLm6JFcGgF5eskJ6mquGirhXY2GD/8u8Ug==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@types/cacheable-request@6.0.3': - resolution: {integrity: sha512-IQ3EbTzGxIigb1I3qPZc1rWJnH0BmSKv5QYTalEwweFvyBDLSAe24zP0le/hyi7ecGfZVlIVAg4BZqb8WBwKqw==} + '@radix-ui/react-visually-hidden@1.2.4': + resolution: {integrity: sha512-kaeiyGCe844dkb9AVF+rb4yTyb1LiLN/e3es3nLiRyN4dC8AduBYPMnnNlDjX2VDOcvDEiPnRNMJeWCfsX0txg==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - '@types/chai-as-promised@7.1.8': - resolution: {integrity: sha512-ThlRVIJhr69FLlh6IctTXFkmhtP3NpMZ2QGq69StYLyKZFp/HOp1VdKZj7RvfNWYYcJ1xlbLGLLWj1UvP5u/Gw==} + '@radix-ui/rect@1.1.1': + resolution: {integrity: sha512-HPwpGIzkl28mWyZqG52jiqDJ12waP11Pa1lGoiyUkIEuMLBP0oeK/C89esbXrxsky5we7dfd8U58nm0SgAWpVw==} - '@types/chai-string@1.4.5': - resolution: {integrity: sha512-IecXRMSnpUvRnTztdpSdjcmcW7EdNme65bfDCQMi7XrSEPGmyDYYTEfc5fcactWDA6ioSm8o7NUqg9QxjBCCEw==} + '@react-oauth/google@0.11.1': + resolution: {integrity: sha512-tywZisXbsdaRBVbEu0VX6dRbOSL2I6DgY97woq5NMOOOz+xtDsm418vqq+Vx10KMtra3kdHMRMf0hXLWrk2RMg==} + peerDependencies: + react: '>=16.8.0' + react-dom: '>=16.8.0' - '@types/chai@4.3.20': - resolution: {integrity: sha512-/pC9HAB5I/xMlc5FP77qjCnI16ChlJfW0tGa0IUcFn38VJrTV6DeZ60NU5KZBtaOZqjdpwTWohz5HU1RrhiYxQ==} + '@reown/appkit-common@1.7.3': + resolution: {integrity: sha512-wKTr6N3z8ly17cc51xBEVkZK4zAd8J1m7RubgsdQ1olFY9YJGe61RYoNv9yFjt6tUVeYT+z7iMUwPhX2PziefQ==} - '@types/chai@5.2.3': - resolution: {integrity: sha512-Mw558oeA9fFbv65/y4mHtXDs9bPnFMZAL/jxdPFUpOHHIXX91mcgEHbS5Lahr+pwZFR8A7GQleRWeI6cGFC2UA==} + '@reown/appkit-controllers@1.7.3': + resolution: {integrity: sha512-aqAcX/nZe0gwqjncyCkVrAk3lEw0qZ9xGrdLOmA207RreO4J0Vxu8OJXCBn4C2AUI2OpBxCPah+vyuKTUJTeHQ==} - '@types/concat-stream@1.6.1': - resolution: {integrity: sha512-eHE4cQPoj6ngxBZMvVf6Hw7Mh4jMW4U9lpGmS5GBPB9RYxlFg+CHaVN7ErNY4W9XfLIEn20b4VDYaIrbq0q4uA==} + '@reown/appkit-polyfills@1.7.3': + resolution: {integrity: sha512-vQUiAyI7WiNTUV4iNwv27iigdeg8JJTEo6ftUowIrKZ2/gtE2YdMtGpavuztT/qrXhrIlTjDGp5CIyv9WOTu4g==} - '@types/cors@2.8.19': - resolution: {integrity: sha512-mFNylyeyqN93lfe/9CSxOGREz8cpzAhH+E93xJ4xWQf62V8sQ/24reV2nyzUWM6H6Xji+GGHpkbLe7pVoUEskg==} + '@reown/appkit-scaffold-ui@1.7.3': + resolution: {integrity: sha512-ssB15fcjmoKQ+VfoCo7JIIK66a4SXFpCH8uK1CsMmXmKIKqPN54ohLo291fniV6mKtnJxh5Xm68slGtGrO3bmA==} - '@types/debug@4.1.13': - resolution: {integrity: sha512-KSVgmQmzMwPlmtljOomayoR89W4FynCAi3E8PPs7vmDVPe84hT+vGPKkJfThkmXs0x0jAaa9U8uW8bbfyS2fWw==} + '@reown/appkit-ui@1.7.3': + resolution: {integrity: sha512-zKmFIjLp0X24pF9KtPtSHmdsh/RjEWIvz+faIbPGm4tQbwcxdg9A35HeoP0rMgKYx49SX51LgPwVXne2gYacqQ==} - '@types/deep-eql@4.0.2': - resolution: {integrity: sha512-c9h9dVVMigMPc4bwTvC5dxqtqJZwQPePsWjPlpSOnojbor6pGqdk541lfA7AqFQr5pB1BRdq0juY9db81BwyFw==} + '@reown/appkit-utils@1.7.3': + resolution: {integrity: sha512-8/MNhmfri+2uu8WzBhZ5jm5llofOIa1dyXDXRC/hfrmGmCFJdrQKPpuqOFYoimo2s2g70pK4PYefvOKgZOWzgg==} - '@types/estree@1.0.8': - resolution: {integrity: sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==} + '@reown/appkit-wallet@1.7.3': + resolution: {integrity: sha512-D0pExd0QUE71ursQPp3pq/0iFrz2oz87tOyFifrPANvH5X0RQCYn/34/kXr+BFVQzNFfCBDlYP+CniNA/S0KiQ==} - '@types/ethereum-protocol@1.0.5': - resolution: {integrity: sha512-4wr+t2rYbwMmDrT447SGzE/43Z0EN++zyHCBoruIx32fzXQDxVa1rnQbYwPO8sLP2OugE/L8KaAIJC5kieUuBg==} + '@reown/appkit@1.7.3': + resolution: {integrity: sha512-aA/UIwi/dVzxEB62xlw3qxHa3RK1YcPMjNxoGj/fHNCqL2qWmbcOXT7coCUa9RG7/Bh26FZ3vdVT2v71j6hebQ==} - '@types/form-data@0.0.33': - resolution: {integrity: sha512-8BSvG1kGm83cyJITQMZSulnl6QV8jqAGreJsc5tPu1Jq0vTSOiY/k24Wx82JRpWwZSqrala6sd5rWi6aNXvqcw==} + '@rolldown/binding-android-arm64@1.0.0-beta.35': + resolution: {integrity: sha512-zVTg0544Ib1ldJSWwjy8URWYHlLFJ98rLnj+2FIj5fRs4KqGKP4VgH/pVUbXNGxeLFjItie6NSK1Un7nJixneQ==} + cpu: [arm64] + os: [android] - '@types/glob@7.2.0': - resolution: {integrity: sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA==} + '@rolldown/binding-darwin-arm64@1.0.0-beta.35': + resolution: {integrity: sha512-WPy0qx22CABTKDldEExfpYHWHulRoPo+m/YpyxP+6ODUPTQexWl8Wp12fn1CVP0xi0rOBj7ugs6+kKMAJW56wQ==} + cpu: [arm64] + os: [darwin] - '@types/http-cache-semantics@4.2.0': - resolution: {integrity: sha512-L3LgimLHXtGkWikKnsPg0/VFx9OGZaC+eN1u4r+OB1XRqH3meBIAVC2zr1WdMH+RHmnRkqliQAOHNJ/E0j/e0Q==} + '@rolldown/binding-darwin-x64@1.0.0-beta.35': + resolution: {integrity: sha512-3k1TabJafF/GgNubXMkfp93d5p30SfIMOmQ5gm1tFwO+baMxxVPwDs3FDvSl+feCWwXxBA+bzemgkaDlInmp1Q==} + cpu: [x64] + os: [darwin] - '@types/inquirer@6.5.0': - resolution: {integrity: sha512-rjaYQ9b9y/VFGOpqBEXRavc3jh0a+e6evAbI31tMda8VlPaSy0AZJfXsvmIe3wklc7W6C3zCSfleuMXR7NOyXw==} + '@rolldown/binding-freebsd-x64@1.0.0-beta.35': + resolution: {integrity: sha512-GAiapN5YyIocnBVNEiOxMfWO9NqIeEKKWohj1sPLGc61P+9N1meXOOCiAPbLU+adXq0grtbYySid+Or7f2q+Mg==} + cpu: [x64] + os: [freebsd] - '@types/json-schema@7.0.15': - resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==} + '@rolldown/binding-linux-arm-gnueabihf@1.0.0-beta.35': + resolution: {integrity: sha512-okPKKIE73qkUMvq7dxDyzD0VIysdV4AirHqjf8tGTjuNoddUAl3WAtMYbuZCEKJwUyI67UINKO1peFVlYEb+8w==} + cpu: [arm] + os: [linux] - '@types/json5@0.0.29': - resolution: {integrity: sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==} + '@rolldown/binding-linux-arm64-gnu@1.0.0-beta.35': + resolution: {integrity: sha512-Nky8Q2cxyKVkEETntrvcmlzNir5khQbDfX3PflHPbZY7XVZalllRqw7+MW5vn+jTsk5BfKVeLsvrF4344IU55g==} + cpu: [arm64] + os: [linux] - '@types/jwt-decode@3.1.0': - resolution: {integrity: sha512-tthwik7TKkou3mVnBnvVuHnHElbjtdbM63pdBCbZTirCt3WAdM73Y79mOri7+ljsS99ZVwUFZHLMxJuJnv/z1w==} - deprecated: This is a stub types definition. jwt-decode provides its own type definitions, so you do not need this installed. + '@rolldown/binding-linux-arm64-musl@1.0.0-beta.35': + resolution: {integrity: sha512-8aHpWVSfZl3Dy2VNFG9ywmlCPAJx45g0z+qdOeqmYceY7PBAT4QGzii9ig1hPb1pY8K45TXH44UzQwr2fx352Q==} + cpu: [arm64] + os: [linux] - '@types/keyv@3.1.4': - resolution: {integrity: sha512-BQ5aZNSCpj7D6K2ksrRCTmKRLEpnPvWDiLPfoGyhZ++8YtiK9d/3DBKPJgry359X/P1PfruyYwvnvwFjuEiEIg==} + '@rolldown/binding-linux-x64-gnu@1.0.0-beta.35': + resolution: {integrity: sha512-1r1Ac/vTcm1q4kRiX/NB6qtorF95PhjdCxKH3Z5pb+bWMDZnmcz18fzFlT/3C6Qpj/ZqUF+EUrG4QEDXtVXGgg==} + cpu: [x64] + os: [linux] - '@types/level-errors@3.0.2': - resolution: {integrity: sha512-gyZHbcQ2X5hNXf/9KS2qGEmgDe9EN2WDM3rJ5Ele467C0nA1sLhtmv1bZiPMDYfAYCfPWft0uQIaTvXbASSTRA==} + '@rolldown/binding-linux-x64-musl@1.0.0-beta.35': + resolution: {integrity: sha512-AFl1LnuhUBDfX2j+cE6DlVGROv4qG7GCPDhR1kJqi2+OuXGDkeEjqRvRQOFErhKz1ckkP/YakvN7JheLJ2PKHQ==} + cpu: [x64] + os: [linux] - '@types/levelup@4.3.3': - resolution: {integrity: sha512-K+OTIjJcZHVlZQN1HmU64VtrC0jC3dXWQozuEIR9zVvltIk90zaGPM2AgT+fIkChpzHhFE3YnvFLCbLtzAmexA==} + '@rolldown/binding-openharmony-arm64@1.0.0-beta.35': + resolution: {integrity: sha512-Tuwb8vPs+TVJlHhyLik+nwln/burvIgaPDgg6wjNZ23F1ttjZi0w0rQSZfAgsX4jaUbylwCETXQmTp3w6vcJMw==} + cpu: [arm64] + os: [openharmony] - '@types/lru-cache@5.1.1': - resolution: {integrity: sha512-ssE3Vlrys7sdIzs5LOxCzTVMsU7i9oa/IaW92wF32JFb3CVczqOkru2xspuKczHEbG3nvmPY7IFqVmGGHdNbYw==} + '@rolldown/binding-wasm32-wasi@1.0.0-beta.35': + resolution: {integrity: sha512-rG0OozgqNUYcpu50MpICMlJflexRVtQfjlN9QYf6hoel46VvY0FbKGwBKoeUp2K5D4i8lV04DpEMfTZlzRjeiA==} + engines: {node: '>=14.0.0'} + cpu: [wasm32] - '@types/minimatch@6.0.0': - resolution: {integrity: sha512-zmPitbQ8+6zNutpwgcQuLcsEpn/Cj54Kbn7L5pX0Os5kdWplB7xPgEh/g+SWOB/qmows2gpuCaPyduq8ZZRnxA==} - deprecated: This is a stub types definition. minimatch provides its own type definitions, so you do not need this installed. + '@rolldown/binding-win32-arm64-msvc@1.0.0-beta.35': + resolution: {integrity: sha512-WeOfAZrycFo9+ZqTDp3YDCAOLolymtKGwImrr9n+OW0lpwI2UKyKXbAwGXRhydAYbfrNmuqWyfyoAnLh3X9Hjg==} + cpu: [arm64] + os: [win32] - '@types/mkdirp@0.5.2': - resolution: {integrity: sha512-U5icWpv7YnZYGsN4/cmh3WD2onMY0aJIiTE6+51TwJCttdHvtCYmkBNOobHlXwrJRL0nkH9jH4kD+1FAdMN4Tg==} + '@rolldown/binding-win32-ia32-msvc@1.0.0-beta.35': + resolution: {integrity: sha512-XkLT7ikKGiUDvLh7qtJHRukbyyP1BIrD1xb7A+w4PjIiOKeOH8NqZ+PBaO4plT7JJnLxx+j9g/3B7iylR1nTFQ==} + cpu: [ia32] + os: [win32] - '@types/mocha@8.2.3': - resolution: {integrity: sha512-ekGvFhFgrc2zYQoX4JeZPmVzZxw6Dtllga7iGHzfbYIYkAMUx/sAFP2GdFpLff+vdHXu5fl7WX9AT+TtqYcsyw==} + '@rolldown/binding-win32-x64-msvc@1.0.0-beta.35': + resolution: {integrity: sha512-rftASFKVzjbcQHTCYHaBIDrnQFzbeV50tm4hVugG3tPjd435RHZC2pbeGV5IPdKEqyJSuurM/GfbV3kLQ3LY/A==} + cpu: [x64] + os: [win32] - '@types/ms@2.1.0': - resolution: {integrity: sha512-GsCCIZDE/p3i96vtEqx+7dBUGXrc7zeSK3wwPHIaRThS+9OhWIXRqzs4d6k1SVU8g91DrNRWxWUGhp5KXQb2VA==} + '@rolldown/pluginutils@1.0.0-beta.35': + resolution: {integrity: sha512-slYrCpoxJUqzFDDNlvrOYRazQUNRvWPjXA17dAOISY3rDMxX6k8K4cj2H+hEYMHF81HO3uNd5rHVigAWRM5dSg==} - '@types/node-fetch@2.6.13': - resolution: {integrity: sha512-QGpRVpzSaUs30JBSGPjOg4Uveu384erbHBoT1zeONvyCfwQxIkUshLAOqN/k9EjGviPRmWTTe6aH2qySWKTVSw==} + '@rolldown/pluginutils@1.0.0-beta.53': + resolution: {integrity: sha512-vENRlFU4YbrwVqNDZ7fLvy+JR1CRkyr01jhSiDpE1u6py3OMzQfztQU2jxykW3ALNxO4kSlqIDeYyD0Y9RcQeQ==} - '@types/node@10.17.60': - resolution: {integrity: sha512-F0KIgDJfy2nA3zMLmWGKxcH2ZVEtCZXHHdOQs2gSaQ27+lNeEfGxzkIw90aXswATX7AZ33tahPbzy6KAfUreVw==} + '@rolldown/pluginutils@1.0.0-beta.57': + resolution: {integrity: sha512-aQNelgx14tGA+n2tNSa9x6/jeoCL9fkDeCei7nOKnHx0fEFRRMu5ReiITo+zZD5TzWDGGRjbSYCs93IfRIyTuQ==} - '@types/node@11.11.6': - resolution: {integrity: sha512-Exw4yUWMBXM3X+8oqzJNRqZSwUAaS4+7NdvHqQuFi/d+synz++xmX3QIf+BFqneW8N31R8Ky+sikfZUXq07ggQ==} + '@rollup/plugin-alias@5.1.1': + resolution: {integrity: sha512-PR9zDb+rOzkRb2VD+EuKB7UC41vU5DIwZ5qqCpk0KJudcWAyi8rvYOhS7+L5aZCspw1stTViLgN5v6FF1p5cgQ==} + engines: {node: '>=14.0.0'} + peerDependencies: + rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 + peerDependenciesMeta: + rollup: + optional: true - '@types/node@12.20.55': - resolution: {integrity: sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ==} + '@rollup/plugin-commonjs@28.0.9': + resolution: {integrity: sha512-PIR4/OHZ79romx0BVVll/PkwWpJ7e5lsqFa3gFfcrFPWwLXLV39JVUzQV9RKjWerE7B845Hqjj9VYlQeieZ2dA==} + engines: {node: '>=16.0.0 || 14 >= 14.17'} + peerDependencies: + rollup: ^2.68.0||^3.0.0||^4.0.0 + peerDependenciesMeta: + rollup: + optional: true - '@types/node@22.7.5': - resolution: {integrity: sha512-jML7s2NAzMWc//QSJ1a3prpk78cOPchGvXJsC3C6R6PSMoooztvRVQEz89gmBTBY1SPMaqo5teB4uNHPdetShQ==} + '@rollup/plugin-inject@5.0.5': + resolution: {integrity: sha512-2+DEJbNBoPROPkgTDNe8/1YXWcqxbN5DTjASVIOx8HS+pITXushyNiBV56RB08zuptzz8gT3YfkqriTBVycepg==} + engines: {node: '>=14.0.0'} + peerDependencies: + rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 + peerDependenciesMeta: + rollup: + optional: true - '@types/node@25.3.0': - resolution: {integrity: sha512-4K3bqJpXpqfg2XKGK9bpDTc6xO/xoUP/RBWS7AtRMug6zZFaRekiLzjVtAoZMquxoAbzBvy5nxQ7veS5eYzf8A==} + '@rollup/plugin-json@6.1.0': + resolution: {integrity: sha512-EGI2te5ENk1coGeADSIwZ7G2Q8CJS2sF120T7jLw4xFw9n7wIOXHo+kIYRAoVpJAN+kmqZSoO3Fp4JtoNF4ReA==} + engines: {node: '>=14.0.0'} + peerDependencies: + rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 + peerDependenciesMeta: + rollup: + optional: true - '@types/node@25.6.0': - resolution: {integrity: sha512-+qIYRKdNYJwY3vRCZMdJbPLJAtGjQBudzZzdzwQYkEPQd+PJGixUL5QfvCLDaULoLv+RhT3LDkwEfKaAkgSmNQ==} + '@rollup/plugin-node-resolve@16.0.3': + resolution: {integrity: sha512-lUYM3UBGuM93CnMPG1YocWu7X802BrNF3jW2zny5gQyLQgRFJhV1Sq0Zi74+dh/6NBx1DxFC4b4GXg9wUCG5Qg==} + engines: {node: '>=14.0.0'} + peerDependencies: + rollup: ^2.78.0||^3.0.0||^4.0.0 + peerDependenciesMeta: + rollup: + optional: true - '@types/node@8.10.66': - resolution: {integrity: sha512-tktOkFUA4kXx2hhhrB8bIFb5TbwzS4uOhKEmwiD+NoiL0qtP2OQ9mFldbgD4dV1djrlBYP6eBuQZiWjuHUpqFw==} + '@rollup/plugin-replace@6.0.3': + resolution: {integrity: sha512-J4RZarRvQAm5IF0/LwUUg+obsm+xZhYnbMXmXROyoSE1ATJe3oXSb9L5MMppdxP2ylNSjv6zFBwKYjcKMucVfA==} + engines: {node: '>=14.0.0'} + peerDependencies: + rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 + peerDependenciesMeta: + rollup: + optional: true - '@types/pbkdf2@3.1.2': - resolution: {integrity: sha512-uRwJqmiXmh9++aSu1VNEn3iIxWOhd8AHXNSdlaLfdAAdSTY9jYVeGWnzejM3dvrkbqE3/hyQkQQ29IFATEGlew==} + '@rollup/plugin-terser@0.4.4': + resolution: {integrity: sha512-XHeJC5Bgvs8LfukDwWZp7yeqin6ns8RTl2B9avbejt6tZqsqvVoWI7ZTQrcNsfKEDWBTnTxM8nMDkO2IFFbd0A==} + engines: {node: '>=14.0.0'} + peerDependencies: + rollup: ^2.0.0||^3.0.0||^4.0.0 + peerDependenciesMeta: + rollup: + optional: true - '@types/prettier@2.7.3': - resolution: {integrity: sha512-+68kP9yzs4LMp7VNh8gdzMSPZFL44MLGqiHWvttYJe+6qnuVr4Ek9wSBQoveqY/r+LwjCcU29kNVkidwim+kYA==} + '@rollup/pluginutils@5.1.0': + resolution: {integrity: sha512-XTIWOPPcpvyKI6L1NHo0lFlCyznUEyPmPY1mc3KpPVDYulHSTvyeLNVW00QTLIAFNhR3kYnJTQHeGqU4M3n09g==} + engines: {node: '>=14.0.0'} + peerDependencies: + rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 + peerDependenciesMeta: + rollup: + optional: true - '@types/prop-types@15.7.15': - resolution: {integrity: sha512-F6bEyamV9jKGAFBEmlQnesRPGOQqS2+Uwi0Em15xenOxHaf2hv6L8YCVn3rPdPJOiJfPiCnLIRyvwVaqMY3MIw==} + '@rollup/pluginutils@5.3.0': + resolution: {integrity: sha512-5EdhGZtnu3V88ces7s53hhfK5KSASnJZv8Lulpc04cWO3REESroJXg73DFsOmgbU2BhwV0E20bu2IDZb3VKW4Q==} + engines: {node: '>=14.0.0'} + peerDependencies: + rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 + peerDependenciesMeta: + rollup: + optional: true - '@types/qs@6.15.0': - resolution: {integrity: sha512-JawvT8iBVWpzTrz3EGw9BTQFg3BQNmwERdKE22vlTxawwtbyUSlMppvZYKLZzB5zgACXdXxbD3m1bXaMqP/9ow==} + '@rollup/rollup-android-arm-eabi@4.54.0': + resolution: {integrity: sha512-OywsdRHrFvCdvsewAInDKCNyR3laPA2mc9bRYJ6LBp5IyvF3fvXbbNR0bSzHlZVFtn6E0xw2oZlyjg4rKCVcng==} + cpu: [arm] + os: [android] - '@types/react-dom@19.2.3': - resolution: {integrity: sha512-jp2L/eY6fn+KgVVQAOqYItbF0VY/YApe5Mz2F0aykSO8gx31bYCZyvSeYxCHKvzHG5eZjc+zyaS5BrBWya2+kQ==} - peerDependencies: - '@types/react': ^19.2.0 + '@rollup/rollup-android-arm64@4.54.0': + resolution: {integrity: sha512-Skx39Uv+u7H224Af+bDgNinitlmHyQX1K/atIA32JP3JQw6hVODX5tkbi2zof/E69M1qH2UoN3Xdxgs90mmNYw==} + cpu: [arm64] + os: [android] - '@types/react@18.3.28': - resolution: {integrity: sha512-z9VXpC7MWrhfWipitjNdgCauoMLRdIILQsAEV+ZesIzBq/oUlxk0m3ApZuMFCXdnS4U7KrI+l3WRUEGQ8K1QKw==} + '@rollup/rollup-darwin-arm64@4.54.0': + resolution: {integrity: sha512-k43D4qta/+6Fq+nCDhhv9yP2HdeKeP56QrUUTW7E6PhZP1US6NDqpJj4MY0jBHlJivVJD5P8NxrjuobZBJTCRw==} + cpu: [arm64] + os: [darwin] - '@types/react@19.2.7': - resolution: {integrity: sha512-MWtvHrGZLFttgeEj28VXHxpmwYbor/ATPYbBfSFZEIRK0ecCFLl2Qo55z52Hss+UV9CRN7trSeq1zbgx7YDWWg==} + '@rollup/rollup-darwin-x64@4.54.0': + resolution: {integrity: sha512-cOo7biqwkpawslEfox5Vs8/qj83M/aZCSSNIWpVzfU2CYHa2G3P1UN5WF01RdTHSgCkri7XOlTdtk17BezlV3A==} + cpu: [x64] + os: [darwin] - '@types/responselike@1.0.3': - resolution: {integrity: sha512-H/+L+UkTV33uf49PH5pCAUBVPNj2nDBXTN+qS1dOwyyg24l3CcicicCA7ca+HMvJBZcFgl5r8e+RR6elsb4Lyw==} + '@rollup/rollup-freebsd-arm64@4.54.0': + resolution: {integrity: sha512-miSvuFkmvFbgJ1BevMa4CPCFt5MPGw094knM64W9I0giUIMMmRYcGW/JWZDriaw/k1kOBtsWh1z6nIFV1vPNtA==} + cpu: [arm64] + os: [freebsd] - '@types/secp256k1@4.0.7': - resolution: {integrity: sha512-Rcvjl6vARGAKRO6jHeKMatGrvOMGrR/AR11N1x2LqintPCyDZ7NBhrh238Z2VZc7aM7KIwnFpFQ7fnfK4H/9Qw==} + '@rollup/rollup-freebsd-x64@4.54.0': + resolution: {integrity: sha512-KGXIs55+b/ZfZsq9aR026tmr/+7tq6VG6MsnrvF4H8VhwflTIuYh+LFUlIsRdQSgrgmtM3fVATzEAj4hBQlaqQ==} + cpu: [x64] + os: [freebsd] - '@types/seedrandom@3.0.1': - resolution: {integrity: sha512-giB9gzDeiCeloIXDgzFBCgjj1k4WxcDrZtGl6h1IqmUPlxF+Nx8Ve+96QCyDZ/HseB/uvDsKbpib9hU5cU53pw==} + '@rollup/rollup-linux-arm-gnueabihf@4.54.0': + resolution: {integrity: sha512-EHMUcDwhtdRGlXZsGSIuXSYwD5kOT9NVnx9sqzYiwAc91wfYOE1g1djOEDseZJKKqtHAHGwnGPQu3kytmfaXLQ==} + cpu: [arm] + os: [linux] - '@types/through@0.0.33': - resolution: {integrity: sha512-HsJ+z3QuETzP3cswwtzt2vEIiHBk/dCcHGhbmG5X3ecnwFD/lPrMpliGXxSCg03L9AhrdwA4Oz/qfspkDW+xGQ==} + '@rollup/rollup-linux-arm-musleabihf@4.54.0': + resolution: {integrity: sha512-+pBrqEjaakN2ySv5RVrj/qLytYhPKEUwk+e3SFU5jTLHIcAtqh2rLrd/OkbNuHJpsBgxsD8ccJt5ga/SeG0JmA==} + cpu: [arm] + os: [linux] - '@types/tinycolor2@1.4.6': - resolution: {integrity: sha512-iEN8J0BoMnsWBqjVbWH/c0G0Hh7O21lpR2/+PrvAVgWdzL7eexIFm4JN/Wn10PTcmNdtS6U67r499mlWMXOxNw==} + '@rollup/rollup-linux-arm64-gnu@4.54.0': + resolution: {integrity: sha512-NSqc7rE9wuUaRBsBp5ckQ5CVz5aIRKCwsoa6WMF7G01sX3/qHUw/z4pv+D+ahL1EIKy6Enpcnz1RY8pf7bjwng==} + cpu: [arm64] + os: [linux] - '@types/web3-provider-engine@14.0.4': - resolution: {integrity: sha512-59wFvtceRmWXfQFoH8qtFIQZf6B7PqBwgBBmZLu4SjRK6pycnjV8K+jihbaGOFwHjTPcPFm15m+CS6I0BBm4lw==} + '@rollup/rollup-linux-arm64-musl@4.54.0': + resolution: {integrity: sha512-gr5vDbg3Bakga5kbdpqx81m2n9IX8M6gIMlQQIXiLTNeQW6CucvuInJ91EuCJ/JYvc+rcLLsDFcfAD1K7fMofg==} + cpu: [arm64] + os: [linux] - '@types/webextension-polyfill@0.10.7': - resolution: {integrity: sha512-10ql7A0qzBmFB+F+qAke/nP1PIonS0TXZAOMVOxEUsm+lGSW6uwVcISFNa0I4Oyj0884TZVWGGMIWeXOVSNFHw==} + '@rollup/rollup-linux-loong64-gnu@4.54.0': + resolution: {integrity: sha512-gsrtB1NA3ZYj2vq0Rzkylo9ylCtW/PhpLEivlgWe0bpgtX5+9j9EZa0wtZiCjgu6zmSeZWyI/e2YRX1URozpIw==} + cpu: [loong64] + os: [linux] - '@types/whatwg-mimetype@3.0.2': - resolution: {integrity: sha512-c2AKvDT8ToxLIOUlN51gTiHXflsfIFisS4pO7pDPoKouJCESkhZnEy623gwP9laCy5lnLDAw1vAzu2vM2YLOrA==} + '@rollup/rollup-linux-ppc64-gnu@4.54.0': + resolution: {integrity: sha512-y3qNOfTBStmFNq+t4s7Tmc9hW2ENtPg8FeUD/VShI7rKxNW7O4fFeaYbMsd3tpFlIg1Q8IapFgy7Q9i2BqeBvA==} + cpu: [ppc64] + os: [linux] - '@types/ws@8.18.1': - resolution: {integrity: sha512-ThVF6DCVhA8kUGy+aazFQ4kXQ7E1Ty7A3ypFOe0IcJV8O/M511G99AW24irKrW56Wt44yG9+ij8FaqoBGkuBXg==} + '@rollup/rollup-linux-riscv64-gnu@4.54.0': + resolution: {integrity: sha512-89sepv7h2lIVPsFma8iwmccN7Yjjtgz0Rj/Ou6fEqg3HDhpCa+Et+YSufy27i6b0Wav69Qv4WBNl3Rs6pwhebQ==} + cpu: [riscv64] + os: [linux] - '@types/yargs-parser@21.0.3': - resolution: {integrity: sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ==} + '@rollup/rollup-linux-riscv64-musl@4.54.0': + resolution: {integrity: sha512-ZcU77ieh0M2Q8Ur7D5X7KvK+UxbXeDHwiOt/CPSBTI1fBmeDMivW0dPkdqkT4rOgDjrDDBUed9x4EgraIKoR2A==} + cpu: [riscv64] + os: [linux] - '@types/yargs@17.0.35': - resolution: {integrity: sha512-qUHkeCyQFxMXg79wQfTtfndEC+N9ZZg76HJftDJp+qH2tV7Gj4OJi7l+PiWwJ+pWtW8GwSmqsDj/oymhrTWXjg==} + '@rollup/rollup-linux-s390x-gnu@4.54.0': + resolution: {integrity: sha512-2AdWy5RdDF5+4YfG/YesGDDtbyJlC9LHmL6rZw6FurBJ5n4vFGupsOBGfwMRjBYH7qRQowT8D/U4LoSvVwOhSQ==} + cpu: [s390x] + os: [linux] - '@typescript-eslint/eslint-plugin@8.50.0': - resolution: {integrity: sha512-O7QnmOXYKVtPrfYzMolrCTfkezCJS9+ljLdKW/+DCvRsc3UAz+sbH6Xcsv7p30+0OwUbeWfUDAQE0vpabZ3QLg==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - '@typescript-eslint/parser': ^8.50.0 - eslint: ^8.57.0 || ^9.0.0 - typescript: '>=4.8.4 <6.0.0' + '@rollup/rollup-linux-x64-gnu@4.54.0': + resolution: {integrity: sha512-WGt5J8Ij/rvyqpFexxk3ffKqqbLf9AqrTBbWDk7ApGUzaIs6V+s2s84kAxklFwmMF/vBNGrVdYgbblCOFFezMQ==} + cpu: [x64] + os: [linux] - '@typescript-eslint/eslint-plugin@8.59.0': - resolution: {integrity: sha512-HyAZtpdkgZwpq8Sz3FSUvCR4c+ScbuWa9AksK2Jweub7w4M3yTz4O11AqVJzLYjy/B9ZWPyc81I+mOdJU/bDQw==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - '@typescript-eslint/parser': ^8.59.0 - eslint: ^8.57.0 || ^9.0.0 || ^10.0.0 - typescript: '>=4.8.4 <6.1.0' + '@rollup/rollup-linux-x64-musl@4.54.0': + resolution: {integrity: sha512-JzQmb38ATzHjxlPHuTH6tE7ojnMKM2kYNzt44LO/jJi8BpceEC8QuXYA908n8r3CNuG/B3BV8VR3Hi1rYtmPiw==} + cpu: [x64] + os: [linux] - '@typescript-eslint/parser@8.50.0': - resolution: {integrity: sha512-6/cmF2piao+f6wSxUsJLZjck7OQsYyRtcOZS02k7XINSNlz93v6emM8WutDQSXnroG2xwYlEVHJI+cPA7CPM3Q==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - eslint: ^8.57.0 || ^9.0.0 - typescript: '>=4.8.4 <6.0.0' + '@rollup/rollup-openharmony-arm64@4.54.0': + resolution: {integrity: sha512-huT3fd0iC7jigGh7n3q/+lfPcXxBi+om/Rs3yiFxjvSxbSB6aohDFXbWvlspaqjeOh+hx7DDHS+5Es5qRkWkZg==} + cpu: [arm64] + os: [openharmony] - '@typescript-eslint/parser@8.59.0': - resolution: {integrity: sha512-TI1XGwKbDpo9tRW8UDIXCOeLk55qe9ZFGs8MTKU6/M08HWTw52DD/IYhfQtOEhEdPhLMT26Ka/x7p70nd3dzDg==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - eslint: ^8.57.0 || ^9.0.0 || ^10.0.0 - typescript: '>=4.8.4 <6.1.0' + '@rollup/rollup-win32-arm64-msvc@4.54.0': + resolution: {integrity: sha512-c2V0W1bsKIKfbLMBu/WGBz6Yci8nJ/ZJdheE0EwB73N3MvHYKiKGs3mVilX4Gs70eGeDaMqEob25Tw2Gb9Nqyw==} + cpu: [arm64] + os: [win32] - '@typescript-eslint/project-service@8.50.0': - resolution: {integrity: sha512-Cg/nQcL1BcoTijEWyx4mkVC56r8dj44bFDvBdygifuS20f3OZCHmFbjF34DPSi07kwlFvqfv/xOLnJ5DquxSGQ==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - typescript: '>=4.8.4 <6.0.0' + '@rollup/rollup-win32-ia32-msvc@4.54.0': + resolution: {integrity: sha512-woEHgqQqDCkAzrDhvDipnSirm5vxUXtSKDYTVpZG3nUdW/VVB5VdCYA2iReSj/u3yCZzXID4kuKG7OynPnB3WQ==} + cpu: [ia32] + os: [win32] - '@typescript-eslint/project-service@8.59.0': - resolution: {integrity: sha512-Lw5ITrR5s5TbC19YSvlr63ZfLaJoU6vtKTHyB0GQOpX0W7d5/Ir6vUahWi/8Sps/nOukZQ0IB3SmlxZnjaKVnw==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - typescript: '>=4.8.4 <6.1.0' + '@rollup/rollup-win32-x64-gnu@4.54.0': + resolution: {integrity: sha512-dzAc53LOuFvHwbCEOS0rPbXp6SIhAf2txMP5p6mGyOXXw5mWY8NGGbPMPrs4P1WItkfApDathBj/NzMLUZ9rtQ==} + cpu: [x64] + os: [win32] - '@typescript-eslint/scope-manager@8.50.0': - resolution: {integrity: sha512-xCwfuCZjhIqy7+HKxBLrDVT5q/iq7XBVBXLn57RTIIpelLtEIZHXAF/Upa3+gaCpeV1NNS5Z9A+ID6jn50VD4A==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@rollup/rollup-win32-x64-msvc@4.54.0': + resolution: {integrity: sha512-hYT5d3YNdSh3mbCU1gwQyPgQd3T2ne0A3KG8KSBdav5TiBg6eInVmV+TeR5uHufiIgSFg0XsOWGW5/RhNcSvPg==} + cpu: [x64] + os: [win32] - '@typescript-eslint/scope-manager@8.59.0': - resolution: {integrity: sha512-UzR16Ut8IpA3Mc4DbgAShlPPkVm8xXMWafXxB0BocaVRHs8ZGakAxGRskF7FId3sdk9lgGD73GSFaWmWFDE4dg==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@safe-global/safe-apps-provider@0.18.6': + resolution: {integrity: sha512-4LhMmjPWlIO8TTDC2AwLk44XKXaK6hfBTWyljDm0HQ6TWlOEijVWNrt2s3OCVMSxlXAcEzYfqyu1daHZooTC2Q==} - '@typescript-eslint/tsconfig-utils@8.50.0': - resolution: {integrity: sha512-vxd3G/ybKTSlm31MOA96gqvrRGv9RJ7LGtZCn2Vrc5htA0zCDvcMqUkifcjrWNNKXHUU3WCkYOzzVSFBd0wa2w==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - typescript: '>=4.8.4 <6.0.0' + '@safe-global/safe-apps-sdk@9.1.0': + resolution: {integrity: sha512-N5p/ulfnnA2Pi2M3YeWjULeWbjo7ei22JwU/IXnhoHzKq3pYCN6ynL9mJBOlvDVv892EgLPCWCOwQk/uBT2v0Q==} - '@typescript-eslint/tsconfig-utils@8.59.0': - resolution: {integrity: sha512-91Sbl3s4Kb3SybliIY6muFBmHVv+pYXfybC4Oolp3dvk8BvIE3wOPc+403CWIT7mJNkfQRGtdqghzs2+Z91Tqg==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - typescript: '>=4.8.4 <6.1.0' + '@safe-global/safe-gateway-typescript-sdk@3.8.0': + resolution: {integrity: sha512-CiGWIHgIaOdICpDxp05Jw3OPslWTu8AnL0PhrCT1xZgIO86NlMMLzkGbeycJ4FHpTjA999O791Oxp4bZPIjgHA==} - '@typescript-eslint/type-utils@8.50.0': - resolution: {integrity: sha512-7OciHT2lKCewR0mFoBrvZJ4AXTMe/sYOe87289WAViOocEmDjjv8MvIOT2XESuKj9jp8u3SZYUSh89QA4S1kQw==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - eslint: ^8.57.0 || ^9.0.0 - typescript: '>=4.8.4 <6.0.0' + '@scure/base@1.1.3': + resolution: {integrity: sha512-/+SgoRjLq7Xlf0CWuLHq2LUZeL/w65kfzAPG5NH9pcmBhs+nunQTn4gvdwgMTIXnt9b2C/1SeL2XiysZEyIC9Q==} - '@typescript-eslint/type-utils@8.59.0': - resolution: {integrity: sha512-3TRiZaQSltGqGeNrJzzr1+8YcEobKH9rHnqIp/1psfKFmhRQDNMGP5hBufanYTGznwShzVLs3Mz+gDN7HkWfXg==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - eslint: ^8.57.0 || ^9.0.0 || ^10.0.0 - typescript: '>=4.8.4 <6.1.0' + '@scure/base@1.1.9': + resolution: {integrity: sha512-8YKhl8GHiNI/pU2VMaofa2Tor7PJRAjwQLBBuilkJ9L5+13yVbC7JO/wS7piioAvPSwR3JKM1IJ/u4xQzbcXKg==} - '@typescript-eslint/types@8.50.0': - resolution: {integrity: sha512-iX1mgmGrXdANhhITbpp2QQM2fGehBse9LbTf0sidWK6yg/NE+uhV5dfU1g6EYPlcReYmkE9QLPq/2irKAmtS9w==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@scure/base@1.2.6': + resolution: {integrity: sha512-g/nm5FgUa//MCj1gV09zTJTaM6KBAHqLN907YVQqf7zC49+DcO4B1so4ZX07Ef10Twr6nuqYEH9GEggFXA4Fmg==} - '@typescript-eslint/types@8.59.0': - resolution: {integrity: sha512-nLzdsT1gdOgFxxxwrlNVUBzSNBEEHJ86bblmk4QAS6stfig7rcJzWKqCyxFy3YRRHXDWEkb2NralA1nOYkkm/A==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@scure/bip32@1.1.5': + resolution: {integrity: sha512-XyNh1rB0SkEqd3tXcXMi+Xe1fvg+kUIcoRIEujP1Jgv7DqW2r9lg3Ah0NkFaCs9sTkQAQA8kw7xiRXzENi9Rtw==} - '@typescript-eslint/typescript-estree@8.50.0': - resolution: {integrity: sha512-W7SVAGBR/IX7zm1t70Yujpbk+zdPq/u4soeFSknWFdXIFuWsBGBOUu/Tn/I6KHSKvSh91OiMuaSnYp3mtPt5IQ==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - typescript: '>=4.8.4 <6.0.0' + '@scure/bip32@1.3.2': + resolution: {integrity: sha512-N1ZhksgwD3OBlwTv3R6KFEcPojl/W4ElJOeCZdi+vuI5QmTFwLq3OFf2zd2ROpKvxFdgZ6hUpb0dx9bVNEwYCA==} - '@typescript-eslint/typescript-estree@8.59.0': - resolution: {integrity: sha512-O9Re9P1BmBLFJyikRbQpLku/QA3/AueZNO9WePLBwQrvkixTmDe8u76B6CYUAITRl/rHawggEqUGn5QIkVRLMw==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - typescript: '>=4.8.4 <6.1.0' + '@scure/bip32@1.4.0': + resolution: {integrity: sha512-sVUpc0Vq3tXCkDGYVWGIZTRfnvu8LoTDaev7vbwh0omSvVORONr960MQWdKqJDCReIEmTj3PAr73O3aoxz7OPg==} - '@typescript-eslint/utils@8.50.0': - resolution: {integrity: sha512-87KgUXET09CRjGCi2Ejxy3PULXna63/bMYv72tCAlDJC3Yqwln0HiFJ3VJMst2+mEtNtZu5oFvX4qJGjKsnAgg==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - eslint: ^8.57.0 || ^9.0.0 - typescript: '>=4.8.4 <6.0.0' + '@scure/bip32@1.6.2': + resolution: {integrity: sha512-t96EPDMbtGgtb7onKKqxRLfE5g05k7uHnHRM2xdE6BP/ZmxaLtPek4J4KfVn/90IQNrU1IOAqMgiDtUdtbe3nw==} - '@typescript-eslint/utils@8.59.0': - resolution: {integrity: sha512-I1R/K7V07XsMJ12Oaxg/O9GfrysGTmCRhvZJBv0RE0NcULMzjqVpR5kRRQjHsz3J/bElU7HwCO7zkqL+MSUz+g==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - eslint: ^8.57.0 || ^9.0.0 || ^10.0.0 - typescript: '>=4.8.4 <6.1.0' + '@scure/bip32@1.7.0': + resolution: {integrity: sha512-E4FFX/N3f4B80AKWp5dP6ow+flD1LQZo/w8UnLGYZO674jS6YnYeepycOOksv+vLPSpgN35wgKgy+ybfTb2SMw==} - '@typescript-eslint/visitor-keys@8.50.0': - resolution: {integrity: sha512-Xzmnb58+Db78gT/CCj/PVCvK+zxbnsw6F+O1oheYszJbBSdEjVhQi3C/Xttzxgi/GLmpvOggRs1RFpiJ8+c34Q==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@scure/bip39@1.1.1': + resolution: {integrity: sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg==} - '@typescript-eslint/visitor-keys@8.59.0': - resolution: {integrity: sha512-/uejZt4dSere1bx12WLlPfv8GktzcaDtuJ7s42/HEZ5zGj9oxRaD4bj7qwSunXkf+pbAhFt2zjpHYUiT5lHf0Q==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@scure/bip39@1.2.1': + resolution: {integrity: sha512-Z3/Fsz1yr904dduJD0NpiyRHhRYHdcnyh73FZWiV+/qhWi83wNJ3NWolYqCEN+ZWsUz2TWwajJggcRE9r1zUYg==} - '@vitest/coverage-v8@4.0.18': - resolution: {integrity: sha512-7i+N2i0+ME+2JFZhfuz7Tg/FqKtilHjGyGvoHYQ6iLV0zahbsJ9sljC9OcFcPDbhYKCet+sG8SsVqlyGvPflZg==} - peerDependencies: - '@vitest/browser': 4.0.18 - vitest: 4.0.18 - peerDependenciesMeta: - '@vitest/browser': - optional: true + '@scure/bip39@1.3.0': + resolution: {integrity: sha512-disdg7gHuTDZtY+ZdkmLpPCk7fxZSu3gBiEGuoC1XYxv9cGx3Z6cpTggCgW6odSOOIXCiDjuGejW+aJKCY/pIQ==} - '@vitest/expect@4.0.18': - resolution: {integrity: sha512-8sCWUyckXXYvx4opfzVY03EOiYVxyNrHS5QxX3DAIi5dpJAAkyJezHCP77VMX4HKA2LDT/Jpfo8i2r5BE3GnQQ==} + '@scure/bip39@1.5.4': + resolution: {integrity: sha512-TFM4ni0vKvCfBpohoh+/lY05i9gRbSwXWngAsF4CABQxoaOHijxuaZ2R6cStDQ5CHtHO9aGJTr4ksVJASRRyMA==} - '@vitest/mocker@4.0.18': - resolution: {integrity: sha512-HhVd0MDnzzsgevnOWCBj5Otnzobjy5wLBe4EdeeFGv8luMsGcYqDuFRMcttKWZA5vVO8RFjexVovXvAM4JoJDQ==} - peerDependencies: - msw: ^2.4.9 - vite: ^6.0.0 || ^7.0.0-0 - peerDependenciesMeta: - msw: - optional: true - vite: - optional: true + '@scure/bip39@1.6.0': + resolution: {integrity: sha512-+lF0BbLiJNwVlev4eKelw1WWLaiKXw7sSl8T6FvBlWkdX+94aGJ4o8XjUdlyhTCjd8c+B3KT3JfS8P0bLRNU6A==} - '@vitest/pretty-format@4.0.18': - resolution: {integrity: sha512-P24GK3GulZWC5tz87ux0m8OADrQIUVDPIjjj65vBXYG17ZeU3qD7r+MNZ1RNv4l8CGU2vtTRqixrOi9fYk/yKw==} + '@sec-ant/readable-stream@0.4.1': + resolution: {integrity: sha512-831qok9r2t8AlxLko40y2ebgSDhenenCatLVeW/uBtnHPyhHOvG0C7TvfgecV+wHzIm5KUICgzmVpWS+IMEAeg==} - '@vitest/runner@4.0.18': - resolution: {integrity: sha512-rpk9y12PGa22Jg6g5M3UVVnTS7+zycIGk9ZNGN+m6tZHKQb7jrP7/77WfZy13Y/EUDd52NDsLRQhYKtv7XfPQw==} + '@sentry/core@5.30.0': + resolution: {integrity: sha512-TmfrII8w1PQZSZgPpUESqjB+jC6MvZJZdLtE/0hZ+SrnKhW3x5WlYLvTXZpcWePYBku7rl2wn1RZu6uT0qCTeg==} + engines: {node: '>=6'} - '@vitest/snapshot@4.0.18': - resolution: {integrity: sha512-PCiV0rcl7jKQjbgYqjtakly6T1uwv/5BQ9SwBLekVg/EaYeQFPiXcgrC2Y7vDMA8dM1SUEAEV82kgSQIlXNMvA==} + '@sentry/hub@5.30.0': + resolution: {integrity: sha512-2tYrGnzb1gKz2EkMDQcfLrDTvmGcQPuWxLnJKXJvYTQDGLlEvi2tWz1VIHjunmOvJrB5aIQLhm+dcMRwFZDCqQ==} + engines: {node: '>=6'} - '@vitest/spy@4.0.18': - resolution: {integrity: sha512-cbQt3PTSD7P2OARdVW3qWER5EGq7PHlvE+QfzSC0lbwO+xnt7+XH06ZzFjFRgzUX//JmpxrCu92VdwvEPlWSNw==} + '@sentry/minimal@5.30.0': + resolution: {integrity: sha512-BwWb/owZKtkDX+Sc4zCSTNcvZUq7YcH3uAVlmh/gtR9rmUvbzAA3ewLuB3myi4wWRAMEtny6+J/FN/x+2wn9Xw==} + engines: {node: '>=6'} - '@vitest/utils@4.0.18': - resolution: {integrity: sha512-msMRKLMVLWygpK3u2Hybgi4MNjcYJvwTb0Ru09+fOyCXIgT5raYP041DRRdiJiI3k/2U6SEbAETB3YtBrUkCFA==} + '@sentry/node@5.30.0': + resolution: {integrity: sha512-Br5oyVBF0fZo6ZS9bxbJZG4ApAjRqAnqFFurMVJJdunNb80brh7a5Qva2kjhm+U6r9NJAB5OmDyPkA1Qnt+QVg==} + engines: {node: '>=6'} - abbrev@1.0.9: - resolution: {integrity: sha512-LEyx4aLEC3x6T0UguF6YILf+ntvmOaWsVfENmIW0E9H09vKlLDGelMjjSm0jkDHALj8A8quZ/HapKNigzwge+Q==} + '@sentry/tracing@5.30.0': + resolution: {integrity: sha512-dUFowCr0AIMwiLD7Fs314Mdzcug+gBVo/+NCMyDw8tFxJkwWAKl7Qa2OZxLQ0ZHjakcj1hNKfCQJ9rhyfOl4Aw==} + engines: {node: '>=6'} - abitype@1.1.0: - resolution: {integrity: sha512-6Vh4HcRxNMLA0puzPjM5GBgT4aAcFGKZzSgAXvuZ27shJP6NEpielTuqbBmZILR5/xd0PizkBGy5hReKz9jl5A==} - peerDependencies: - typescript: '>=5.0.4' - zod: ^3.22.0 || ^4.0.0 - peerDependenciesMeta: - typescript: - optional: true - zod: - optional: true + '@sentry/types@5.30.0': + resolution: {integrity: sha512-R8xOqlSTZ+htqrfteCWU5Nk0CDN5ApUTvrlvBuiH1DyP6czDZ4ktbZB0hAgBlVcK0U+qpD3ag3Tqqpa5Q67rPw==} + engines: {node: '>=6'} - abitype@1.2.2: - resolution: {integrity: sha512-4DOIMWscIB3j8hboLAUjLZCE8TMLdgecBpHFumfU4PdO/C1SBCVx4Nu1wPYXaL2iK8B0Jk3tiwnDLCpUtm3fZg==} - peerDependencies: - typescript: '>=5.0.4' - zod: ^3.22.0 || ^4.0.0 - peerDependenciesMeta: - typescript: - optional: true - zod: - optional: true + '@sentry/utils@5.30.0': + resolution: {integrity: sha512-zaYmoH0NWWtvnJjC9/CBseXMtKHm/tm40sz3YfJRxeQjyzRqNQPgivpd9R/oDJCYj999mzdW382p/qi2ypjLww==} + engines: {node: '>=6'} - abortcontroller-polyfill@1.7.8: - resolution: {integrity: sha512-9f1iZ2uWh92VcrU9Y8x+LdM4DLj75VE0MJB8zuF1iUnroEptStw+DQ8EQPMUdfe5k+PkB1uUfDQfWbhstH8LrQ==} + '@shikijs/core@1.22.2': + resolution: {integrity: sha512-bvIQcd8BEeR1yFvOYv6HDiyta2FFVePbzeowf5pPS1avczrPK+cjmaxxh0nx5QzbON7+Sv0sQfQVciO7bN72sg==} - abstract-level@1.0.3: - resolution: {integrity: sha512-t6jv+xHy+VYwc4xqZMn2Pa9DjcdzvzZmQGRjTFc8spIbRGHgBrEKbPq+rYXc7CCo0lxgYvSgKVg9qZAhpVQSjA==} - engines: {node: '>=12'} + '@shikijs/engine-javascript@1.22.2': + resolution: {integrity: sha512-iOvql09ql6m+3d1vtvP8fLCVCK7BQD1pJFmHIECsujB0V32BJ0Ab6hxk1ewVSMFA58FI0pR2Had9BKZdyQrxTw==} - abstract-leveldown@2.6.3: - resolution: {integrity: sha512-2++wDf/DYqkPR3o5tbfdhF96EfMApo1GpPfzOsR/ZYXdkSmELlvOOEAl9iKkRsktMPHdGjO4rtkBpf2I7TiTeA==} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + '@shikijs/engine-oniguruma@1.22.2': + resolution: {integrity: sha512-GIZPAGzQOy56mGvWMoZRPggn0dTlBf1gutV5TdceLCZlFNqWmuc7u+CzD0Gd9vQUTgLbrt0KLzz6FNprqYAxlA==} - abstract-leveldown@2.7.2: - resolution: {integrity: sha512-+OVvxH2rHVEhWLdbudP6p0+dNMXu8JA1CbhP19T8paTYAcX7oJ4OVjT+ZUVpv7mITxXHqDMej+GdqXBmXkw09w==} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + '@shikijs/transformers@1.22.2': + resolution: {integrity: sha512-8f78OiBa6pZDoZ53lYTmuvpFPlWtevn23bzG+azpPVvZg7ITax57o/K3TC91eYL3OMJOO0onPbgnQyZjRos8XQ==} - abstract-leveldown@6.2.3: - resolution: {integrity: sha512-BsLm5vFMRUrrLeCcRc+G0t2qOaTzpoJQLOubq2XM72eNpjF5UdU5o/5NvlNhx95XHcAvcl8OMXr4mlg/fRgUXQ==} - engines: {node: '>=6'} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + '@shikijs/twoslash@1.22.2': + resolution: {integrity: sha512-4R3A7aH/toZgtlveXHKk01nIsvn8hjAfPJ1aT550zcV4qK6vK/tfaEyYtaljOaY1wig2l5+8sKjNSEz3PcSiEw==} - abstract-leveldown@6.3.0: - resolution: {integrity: sha512-TU5nlYgta8YrBMNpc9FwQzRbiXsj49gsALsXadbGHt9CROPzX5fB0rWDR5mtdpOOKa5XqRFpbj1QroPAoPzVjQ==} - engines: {node: '>=6'} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + '@shikijs/types@1.22.2': + resolution: {integrity: sha512-NCWDa6LGZqTuzjsGfXOBWfjS/fDIbDdmVDug+7ykVe1IKT4c1gakrvlfFYp5NhAXH/lyqLM8wsAPo5wNy73Feg==} - abstract-leveldown@7.2.0: - resolution: {integrity: sha512-DnhQwcFEaYsvYDnACLZhMmCWd3rkOeEvglpa4q5i/5Jlm3UIsWaxVzuXvDLFCSCWRO3yy2/+V/G7FusFgejnfQ==} - engines: {node: '>=10'} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + '@shikijs/vitepress-twoslash@1.22.2': + resolution: {integrity: sha512-F4cS9l6QTt/ILlz+S871bOido2CK8Xwdnl4q9gHdnTuZlN1PHAMRZbAOvYAtokvouPp9aZ2W7NtNa+CNCn3yPQ==} - accepts@1.3.8: - resolution: {integrity: sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==} - engines: {node: '>= 0.6'} + '@shikijs/vscode-textmate@9.3.0': + resolution: {integrity: sha512-jn7/7ky30idSkd/O5yDBfAnVt+JJpepofP/POZ1iMOxK59cOfqIgg/Dj0eFsjOTMw+4ycJN0uhZH/Eb0bs/EUA==} - acorn-jsx@5.3.2: - resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==} - peerDependencies: - acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 + '@sinclair/typebox@0.25.24': + resolution: {integrity: sha512-XJfwUVUKDHF5ugKwIcxEgc9k8b7HbznCp6eUfWgu710hMPNIO4aw4/zB5RogDQz8nd6gyCDpU9O/m6qYEWY6yQ==} - acorn-walk@8.3.5: - resolution: {integrity: sha512-HEHNfbars9v4pgpW6SO1KSPkfoS0xVOM/9UzkJltjlsHZmJasxg8aXkuZa7SMf8vKGIBhpUsPluQSqhJFCqebw==} - engines: {node: '>=0.4.0'} + '@sindresorhus/is@4.6.0': + resolution: {integrity: sha512-t09vSN3MdfsyCHoFcTRCH/iUtG7OJ0CsjzB8cjAmKc/va/kIgeDI/TxsigdncE/4be734m0cvIYwNaV4i2XqAw==} + engines: {node: '>=10'} - acorn@8.15.0: - resolution: {integrity: sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg==} - engines: {node: '>=0.4.0'} - hasBin: true + '@sindresorhus/is@7.1.1': + resolution: {integrity: sha512-rO92VvpgMc3kfiTjGT52LEtJ8Yc5kCWhZjLQ3LwlA4pSgPpQO7bVpYXParOD8Jwf+cVQECJo3yP/4I8aZtUQTQ==} + engines: {node: '>=18'} - acorn@8.16.0: - resolution: {integrity: sha512-UVJyE9MttOsBQIDKw1skb9nAwQuR5wuGD3+82K6JgJlm/Y+KI92oNsMNGZCYdDsVtRHSak0pcV5Dno5+4jh9sw==} - engines: {node: '>=0.4.0'} - hasBin: true + '@sindresorhus/merge-streams@4.0.0': + resolution: {integrity: sha512-tlqY9xq5ukxTUZBmoOp+m61cqwQD5pHJtFY3Mn8CA8ps6yghLH/Hw8UPdqg4OLmFW3IFlcXnQNmo/dh8HzXYIQ==} + engines: {node: '>=18'} - adm-zip@0.4.16: - resolution: {integrity: sha512-TFi4HBKSGfIKsK5YCkKaaFG2m4PEDyViZmEwof3MTIgzimHLto6muaHVpbrljdIvIrFZzEq/p4nafOeLcYegrg==} - engines: {node: '>=0.3.0'} + '@smithy/abort-controller@4.2.7': + resolution: {integrity: sha512-rzMY6CaKx2qxrbYbqjXWS0plqEy7LOdKHS0bg4ixJ6aoGDPNUcLWk/FRNuCILh7GKLG9TFUXYYeQQldMBBwuyw==} + engines: {node: '>=18.0.0'} - aes-js@3.0.0: - resolution: {integrity: sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==} + '@smithy/config-resolver@4.4.5': + resolution: {integrity: sha512-HAGoUAFYsUkoSckuKbCPayECeMim8pOu+yLy1zOxt1sifzEbrsRpYa+mKcMdiHKMeiqOibyPG0sFJnmaV/OGEg==} + engines: {node: '>=18.0.0'} - aes-js@4.0.0-beta.5: - resolution: {integrity: sha512-G965FqalsNyrPqgEGON7nIx1e/OVENSgiEIzyC63haUMuvNnwIgIjMs52hlTCKhkBny7A2ORNlfY9Zu+jmGk1Q==} + '@smithy/core@3.20.0': + resolution: {integrity: sha512-WsSHCPq/neD5G/MkK4csLI5Y5Pkd9c1NMfpYEKeghSGaD4Ja1qLIohRQf2D5c1Uy5aXp76DeKHkzWZ9KAlHroQ==} + engines: {node: '>=18.0.0'} - agent-base@6.0.2: - resolution: {integrity: sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==} - engines: {node: '>= 6.0.0'} + '@smithy/credential-provider-imds@4.2.7': + resolution: {integrity: sha512-CmduWdCiILCRNbQWFR0OcZlUPVtyE49Sr8yYL0rZQ4D/wKxiNzBNS/YHemvnbkIWj623fplgkexUd/c9CAKdoA==} + engines: {node: '>=18.0.0'} - agent-base@7.1.4: - resolution: {integrity: sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==} - engines: {node: '>= 14'} + '@smithy/fetch-http-handler@5.3.8': + resolution: {integrity: sha512-h/Fi+o7mti4n8wx1SR6UHWLaakwHRx29sizvp8OOm7iqwKGFneT06GCSFhml6Bha5BT6ot5pj3CYZnCHhGC2Rg==} + engines: {node: '>=18.0.0'} - aggregate-error@3.1.0: - resolution: {integrity: sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==} - engines: {node: '>=8'} + '@smithy/hash-node@4.2.7': + resolution: {integrity: sha512-PU/JWLTBCV1c8FtB8tEFnY4eV1tSfBc7bDBADHfn1K+uRbPgSJ9jnJp0hyjiFN2PMdPzxsf1Fdu0eo9fJ760Xw==} + engines: {node: '>=18.0.0'} - ajv@6.15.0: - resolution: {integrity: sha512-fgFx7Hfoq60ytK2c7DhnF8jIvzYgOMxfugjLOSMHjLIPgenqa7S7oaagATUq99mV6IYvN2tRmC0wnTYX6iPbMw==} + '@smithy/invalid-dependency@4.2.7': + resolution: {integrity: sha512-ncvgCr9a15nPlkhIUx3CU4d7E7WEuVJOV7fS7nnK2hLtPK9tYRBkMHQbhXU1VvvKeBm/O0x26OEoBq+ngFpOEQ==} + engines: {node: '>=18.0.0'} - ajv@8.20.0: - resolution: {integrity: sha512-Thbli+OlOj+iMPYFBVBfJ3OmCAnaSyNn4M1vz9T6Gka5Jt9ba/HIR56joy65tY6kx/FCF5VXNB819Y7/GUrBGA==} + '@smithy/is-array-buffer@2.2.0': + resolution: {integrity: sha512-GGP3O9QFD24uGeAXYUjwSTXARoqpZykHadOmA8G5vfJPK0/DC67qa//0qvqrJzL1xc8WQWX7/yc7fwudjPHPhA==} + engines: {node: '>=14.0.0'} - amazon-cognito-identity-js@6.3.16: - resolution: {integrity: sha512-HPGSBGD6Q36t99puWh0LnptxO/4icnk2kqIQ9cTJ2tFQo5NMUnWQIgtrTAk8nm+caqUbjDzXzG56GBjI2tS6jQ==} + '@smithy/is-array-buffer@4.2.0': + resolution: {integrity: sha512-DZZZBvC7sjcYh4MazJSGiWMI2L7E0oCiRHREDzIxi/M2LY79/21iXt6aPLHge82wi5LsuRF5A06Ds3+0mlh6CQ==} + engines: {node: '>=18.0.0'} - amdefine@1.0.1: - resolution: {integrity: sha512-S2Hw0TtNkMJhIabBwIojKL9YHO5T0n5eNqWJ7Lrlel/zDbftQpxpapi8tZs3X1HWa+u+QeydGmzzNU0m09+Rcg==} - engines: {node: '>=0.4.2'} + '@smithy/middleware-content-length@4.2.7': + resolution: {integrity: sha512-GszfBfCcvt7kIbJ41LuNa5f0wvQCHhnGx/aDaZJCCT05Ld6x6U2s0xsc/0mBFONBZjQJp2U/0uSJ178OXOwbhg==} + engines: {node: '>=18.0.0'} - ansi-align@3.0.1: - resolution: {integrity: sha512-IOfwwBF5iczOjp/WeY4YxyjqAFMQoZufdQWDd19SEExbVLNXqvpzSJ/M7Za4/sCPmQ0+GRquoA7bGcINcxew6w==} + '@smithy/middleware-endpoint@4.4.1': + resolution: {integrity: sha512-gpLspUAoe6f1M6H0u4cVuFzxZBrsGZmjx2O9SigurTx4PbntYa4AJ+o0G0oGm1L2oSX6oBhcGHwrfJHup2JnJg==} + engines: {node: '>=18.0.0'} - ansi-colors@4.1.3: - resolution: {integrity: sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==} - engines: {node: '>=6'} + '@smithy/middleware-retry@4.4.17': + resolution: {integrity: sha512-MqbXK6Y9uq17h+4r0ogu/sBT6V/rdV+5NvYL7ZV444BKfQygYe8wAhDrVXagVebN6w2RE0Fm245l69mOsPGZzg==} + engines: {node: '>=18.0.0'} - ansi-escapes@4.3.2: - resolution: {integrity: sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==} - engines: {node: '>=8'} - - ansi-regex@2.1.1: - resolution: {integrity: sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==} - engines: {node: '>=0.10.0'} + '@smithy/middleware-serde@4.2.8': + resolution: {integrity: sha512-8rDGYen5m5+NV9eHv9ry0sqm2gI6W7mc1VSFMtn6Igo25S507/HaOX9LTHAS2/J32VXD0xSzrY0H5FJtOMS4/w==} + engines: {node: '>=18.0.0'} - ansi-regex@3.0.1: - resolution: {integrity: sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==} - engines: {node: '>=4'} + '@smithy/middleware-stack@4.2.7': + resolution: {integrity: sha512-bsOT0rJ+HHlZd9crHoS37mt8qRRN/h9jRve1SXUhVbkRzu0QaNYZp1i1jha4n098tsvROjcwfLlfvcFuJSXEsw==} + engines: {node: '>=18.0.0'} - ansi-regex@5.0.1: - resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} - engines: {node: '>=8'} + '@smithy/node-config-provider@4.3.7': + resolution: {integrity: sha512-7r58wq8sdOcrwWe+klL9y3bc4GW1gnlfnFOuL7CXa7UzfhzhxKuzNdtqgzmTV+53lEp9NXh5hY/S4UgjLOzPfw==} + engines: {node: '>=18.0.0'} - ansi-regex@6.2.2: - resolution: {integrity: sha512-Bq3SmSpyFHaWjPk8If9yc6svM8c56dB5BAtW4Qbw5jHTwwXXcTLoRMkpDJp6VL0XzlWaCHTXrkFURMYmD0sLqg==} - engines: {node: '>=12'} + '@smithy/node-http-handler@4.4.7': + resolution: {integrity: sha512-NELpdmBOO6EpZtWgQiHjoShs1kmweaiNuETUpuup+cmm/xJYjT4eUjfhrXRP4jCOaAsS3c3yPsP3B+K+/fyPCQ==} + engines: {node: '>=18.0.0'} - ansi-styles@3.2.1: - resolution: {integrity: sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==} - engines: {node: '>=4'} + '@smithy/property-provider@4.2.7': + resolution: {integrity: sha512-jmNYKe9MGGPoSl/D7JDDs1C8b3dC8f/w78LbaVfoTtWy4xAd5dfjaFG9c9PWPihY4ggMQNQSMtzU77CNgAJwmA==} + engines: {node: '>=18.0.0'} - ansi-styles@4.3.0: - resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==} - engines: {node: '>=8'} + '@smithy/protocol-http@5.3.7': + resolution: {integrity: sha512-1r07pb994I20dD/c2seaZhoCuNYm0rWrvBxhCQ70brNh11M5Ml2ew6qJVo0lclB3jMIXirD4s2XRXRe7QEi0xA==} + engines: {node: '>=18.0.0'} - ansi-styles@6.2.3: - resolution: {integrity: sha512-4Dj6M28JB+oAH8kFkTLUo+a2jwOFkuqb3yucU0CANcRRUbxS0cP0nZYCGjcc3BNXwRIsUVmDGgzawme7zvJHvg==} - engines: {node: '>=12'} + '@smithy/querystring-builder@4.2.7': + resolution: {integrity: sha512-eKONSywHZxK4tBxe2lXEysh8wbBdvDWiA+RIuaxZSgCMmA0zMgoDpGLJhnyj+c0leOQprVnXOmcB4m+W9Rw7sg==} + engines: {node: '>=18.0.0'} - antlr4@4.13.2: - resolution: {integrity: sha512-QiVbZhyy4xAZ17UPEuG3YTOt8ZaoeOR1CvEAqrEsDBsOqINslaB147i9xqljZqoyf5S+EUlGStaj+t22LT9MOg==} - engines: {node: '>=16'} + '@smithy/querystring-parser@4.2.7': + resolution: {integrity: sha512-3X5ZvzUHmlSTHAXFlswrS6EGt8fMSIxX/c3Rm1Pni3+wYWB6cjGocmRIoqcQF9nU5OgGmL0u7l9m44tSUpfj9w==} + engines: {node: '>=18.0.0'} - antlr4ts@0.5.0-alpha.4: - resolution: {integrity: sha512-WPQDt1B74OfPv/IMS2ekXAKkTZIHl88uMetg6q3OTqgFxZ/dxDXI0EWLyZid/1Pe6hTftyg5N7gel5wNAGxXyQ==} + '@smithy/service-error-classification@4.2.7': + resolution: {integrity: sha512-YB7oCbukqEb2Dlh3340/8g8vNGbs/QsNNRms+gv3N2AtZz9/1vSBx6/6tpwQpZMEJFs7Uq8h4mmOn48ZZ72MkA==} + engines: {node: '>=18.0.0'} - anymatch@3.1.3: - resolution: {integrity: sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==} - engines: {node: '>= 8'} + '@smithy/shared-ini-file-loader@4.4.2': + resolution: {integrity: sha512-M7iUUff/KwfNunmrgtqBfvZSzh3bmFgv/j/t1Y1dQ+8dNo34br1cqVEqy6v0mYEgi0DkGO7Xig0AnuOaEGVlcg==} + engines: {node: '>=18.0.0'} - append-transform@2.0.0: - resolution: {integrity: sha512-7yeyCEurROLQJFv5Xj4lEGTy0borxepjFv1g22oAdqFu//SrAlDl1O1Nxx15SH1RoliUml6p8dwJW9jvZughhg==} - engines: {node: '>=8'} + '@smithy/signature-v4@5.3.7': + resolution: {integrity: sha512-9oNUlqBlFZFOSdxgImA6X5GFuzE7V2H7VG/7E70cdLhidFbdtvxxt81EHgykGK5vq5D3FafH//X+Oy31j3CKOg==} + engines: {node: '>=18.0.0'} - archy@1.0.0: - resolution: {integrity: sha512-Xg+9RwCg/0p32teKdGMPTPnVXKD0w3DfHnFTficozsAgsvq2XenPJq/MYpzzQ/v8zrOyJn6Ds39VA4JIDwFfqw==} + '@smithy/smithy-client@4.10.2': + resolution: {integrity: sha512-D5z79xQWpgrGpAHb054Fn2CCTQZpog7JELbVQ6XAvXs5MNKWf28U9gzSBlJkOyMl9LA1TZEjRtwvGXfP0Sl90g==} + engines: {node: '>=18.0.0'} - arg@4.1.3: - resolution: {integrity: sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==} + '@smithy/types@4.11.0': + resolution: {integrity: sha512-mlrmL0DRDVe3mNrjTcVcZEgkFmufITfUAPBEA+AHYiIeYyJebso/He1qLbP3PssRe22KUzLRpQSdBPbXdgZ2VA==} + engines: {node: '>=18.0.0'} - argparse@1.0.10: - resolution: {integrity: sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==} + '@smithy/url-parser@4.2.7': + resolution: {integrity: sha512-/RLtVsRV4uY3qPWhBDsjwahAtt3x2IsMGnP5W1b2VZIe+qgCqkLxI1UOHDZp1Q1QSOrdOR32MF3Ph2JfWT1VHg==} + engines: {node: '>=18.0.0'} - argparse@2.0.1: - resolution: {integrity: sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==} + '@smithy/util-base64@4.3.0': + resolution: {integrity: sha512-GkXZ59JfyxsIwNTWFnjmFEI8kZpRNIBfxKjv09+nkAWPt/4aGaEWMM04m4sxgNVWkbt2MdSvE3KF/PfX4nFedQ==} + engines: {node: '>=18.0.0'} - array-back@3.1.0: - resolution: {integrity: sha512-TkuxA4UCOvxuDK6NZYXCalszEzj+TLszyASooky+i742l9TqsOdYCMJJupxRic61hwquNtppB3hgcuq9SVSH1Q==} - engines: {node: '>=6'} + '@smithy/util-body-length-browser@4.2.0': + resolution: {integrity: sha512-Fkoh/I76szMKJnBXWPdFkQJl2r9SjPt3cMzLdOB6eJ4Pnpas8hVoWPYemX/peO0yrrvldgCUVJqOAjUrOLjbxg==} + engines: {node: '>=18.0.0'} - array-back@4.0.2: - resolution: {integrity: sha512-NbdMezxqf94cnNfWLL7V/im0Ub+Anbb0IoZhvzie8+4HJ4nMQuzHuy49FkGYCJK2yAloZ3meiB6AVMClbrI1vg==} - engines: {node: '>=8'} + '@smithy/util-body-length-node@4.2.1': + resolution: {integrity: sha512-h53dz/pISVrVrfxV1iqXlx5pRg3V2YWFcSQyPyXZRrZoZj4R4DeWRDo1a7dd3CPTcFi3kE+98tuNyD2axyZReA==} + engines: {node: '>=18.0.0'} - array-buffer-byte-length@1.0.2: - resolution: {integrity: sha512-LHE+8BuR7RYGDKvnrmcuSq3tDcKv9OFEXQt/HpbZhY7V6h0zlUXutnAD82GiFx9rdieCMjkvtcsPqBwgUl1Iiw==} - engines: {node: '>= 0.4'} + '@smithy/util-buffer-from@2.2.0': + resolution: {integrity: sha512-IJdWBbTcMQ6DA0gdNhh/BwrLkDR+ADW5Kr1aZmd4k3DIF6ezMV4R2NIAmT08wQJ3yUK82thHWmC/TnK/wpMMIA==} + engines: {node: '>=14.0.0'} - array-flatten@1.1.1: - resolution: {integrity: sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==} + '@smithy/util-buffer-from@4.2.0': + resolution: {integrity: sha512-kAY9hTKulTNevM2nlRtxAG2FQ3B2OR6QIrPY3zE5LqJy1oxzmgBGsHLWTcNhWXKchgA0WHW+mZkQrng/pgcCew==} + engines: {node: '>=18.0.0'} - array-includes@3.1.9: - resolution: {integrity: sha512-FmeCCAenzH0KH381SPT5FZmiA/TmpndpcaShhfgEN9eCVjnFBqq3l1xrI42y8+PPLI6hypzou4GXw00WHmPBLQ==} - engines: {node: '>= 0.4'} + '@smithy/util-config-provider@4.2.0': + resolution: {integrity: sha512-YEjpl6XJ36FTKmD+kRJJWYvrHeUvm5ykaUS5xK+6oXffQPHeEM4/nXlZPe+Wu0lsgRUcNZiliYNh/y7q9c2y6Q==} + engines: {node: '>=18.0.0'} - array-union@2.1.0: - resolution: {integrity: sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==} - engines: {node: '>=8'} + '@smithy/util-defaults-mode-browser@4.3.16': + resolution: {integrity: sha512-/eiSP3mzY3TsvUOYMeL4EqUX6fgUOj2eUOU4rMMgVbq67TiRLyxT7Xsjxq0bW3OwuzK009qOwF0L2OgJqperAQ==} + engines: {node: '>=18.0.0'} - array-uniq@1.0.3: - resolution: {integrity: sha512-MNha4BWQ6JbwhFhj03YK552f7cb3AzoE8SzeljgChvL1dl3IcvggXVz1DilzySZkCja+CXuZbdW7yATchWn8/Q==} - engines: {node: '>=0.10.0'} + '@smithy/util-defaults-mode-node@4.2.19': + resolution: {integrity: sha512-3a4+4mhf6VycEJyHIQLypRbiwG6aJvbQAeRAVXydMmfweEPnLLabRbdyo/Pjw8Rew9vjsh5WCdhmDaHkQnhhhA==} + engines: {node: '>=18.0.0'} - array.prototype.findlast@1.2.5: - resolution: {integrity: sha512-CVvd6FHg1Z3POpBLxO6E6zr+rSKEQ9L6rZHAaY7lLfhKsWYUBBOuMs0e9o24oopj6H+geRCX0YJ+TJLBK2eHyQ==} - engines: {node: '>= 0.4'} + '@smithy/util-endpoints@3.2.7': + resolution: {integrity: sha512-s4ILhyAvVqhMDYREeTS68R43B1V5aenV5q/V1QpRQJkCXib5BPRo4s7uNdzGtIKxaPHCfU/8YkvPAEvTpxgspg==} + engines: {node: '>=18.0.0'} - array.prototype.findlastindex@1.2.6: - resolution: {integrity: sha512-F/TKATkzseUExPlfvmwQKGITM3DGTK+vkAsCZoDc5daVygbJBnjEUCbgkAvVFsgfXfX4YIqZ/27G3k3tdXrTxQ==} - engines: {node: '>= 0.4'} + '@smithy/util-hex-encoding@4.2.0': + resolution: {integrity: sha512-CCQBwJIvXMLKxVbO88IukazJD9a4kQ9ZN7/UMGBjBcJYvatpWk+9g870El4cB8/EJxfe+k+y0GmR9CAzkF+Nbw==} + engines: {node: '>=18.0.0'} - array.prototype.flat@1.3.3: - resolution: {integrity: sha512-rwG/ja1neyLqCuGZ5YYrznA62D4mZXg0i1cIskIUKSiqF3Cje9/wXAls9B9s1Wa2fomMsIv8czB8jZcPmxCXFg==} - engines: {node: '>= 0.4'} + '@smithy/util-middleware@4.2.7': + resolution: {integrity: sha512-i1IkpbOae6NvIKsEeLLM9/2q4X+M90KV3oCFgWQI4q0Qz+yUZvsr+gZPdAEAtFhWQhAHpTsJO8DRJPuwVyln+w==} + engines: {node: '>=18.0.0'} - array.prototype.flatmap@1.3.3: - resolution: {integrity: sha512-Y7Wt51eKJSyi80hFrJCePGGNo5ktJCslFuboqJsbf57CCPcm5zztluPlc4/aD8sWsKvlwatezpV4U1efk8kpjg==} - engines: {node: '>= 0.4'} + '@smithy/util-retry@4.2.7': + resolution: {integrity: sha512-SvDdsQyF5CIASa4EYVT02LukPHVzAgUA4kMAuZ97QJc2BpAqZfA4PINB8/KOoCXEw9tsuv/jQjMeaHFvxdLNGg==} + engines: {node: '>=18.0.0'} - array.prototype.tosorted@1.1.4: - resolution: {integrity: sha512-p6Fx8B7b7ZhL/gmUsAy0D15WhvDccw3mnGNbZpi3pmeJdxtWsj2jEaI4Y6oo3XiHfzuSgPwKc04MYt6KgvC/wA==} - engines: {node: '>= 0.4'} + '@smithy/util-stream@4.5.8': + resolution: {integrity: sha512-ZnnBhTapjM0YPGUSmOs0Mcg/Gg87k503qG4zU2v/+Js2Gu+daKOJMeqcQns8ajepY8tgzzfYxl6kQyZKml6O2w==} + engines: {node: '>=18.0.0'} - arraybuffer.prototype.slice@1.0.4: - resolution: {integrity: sha512-BNoCY6SXXPQ7gF2opIP4GBE+Xw7U+pHMYKuzjgCN3GwiaIR09UUeKfheyIry77QtrCBlC0KK0q5/TER/tYh3PQ==} - engines: {node: '>= 0.4'} + '@smithy/util-uri-escape@4.2.0': + resolution: {integrity: sha512-igZpCKV9+E/Mzrpq6YacdTQ0qTiLm85gD6N/IrmyDvQFA4UnU3d5g3m8tMT/6zG/vVkWSU+VxeUyGonL62DuxA==} + engines: {node: '>=18.0.0'} - asap@2.0.6: - resolution: {integrity: sha512-BSHWgDSAiKs50o2Re8ppvp3seVHXSRM44cdSsT9FfNEUUZLOGWVCsiWaRPWM1Znn+mqZ1OfVZ3z3DWEzSp7hRA==} + '@smithy/util-utf8@2.3.0': + resolution: {integrity: sha512-R8Rdn8Hy72KKcebgLiv8jQcQkXoLMOGGv5uI1/k0l+snqkOzQ1R0ChUBCxWMlBsFMekWjq0wRudIweFs7sKT5A==} + engines: {node: '>=14.0.0'} - asn1@0.2.6: - resolution: {integrity: sha512-ix/FxPn0MDjeyJ7i/yoHGFt/EX6LyNbxSEhPPXODPL+KB0VPk86UYfL0lMdy+KCnv+fmvIzySwaK5COwqVbWTQ==} + '@smithy/util-utf8@4.2.0': + resolution: {integrity: sha512-zBPfuzoI8xyBtR2P6WQj63Rz8i3AmfAaJLuNG8dWsfvPe8lO4aCPYLn879mEgHndZH1zQ2oXmG8O1GGzzaoZiw==} + engines: {node: '>=18.0.0'} - asn1js@3.0.7: - resolution: {integrity: sha512-uLvq6KJu04qoQM6gvBfKFjlh6Gl0vOKQuR5cJMDHQkmwfMOQeN3F3SHCv9SNYSL+CRoHvOGFfllDlVz03GQjvQ==} - engines: {node: '>=12.0.0'} + '@smithy/uuid@1.1.0': + resolution: {integrity: sha512-4aUIteuyxtBUhVdiQqcDhKFitwfd9hqoSDYY2KRXiWtgoWJ9Bmise+KfEPDiVHWeJepvF8xJO9/9+WDIciMFFw==} + engines: {node: '>=18.0.0'} - assert-plus@1.0.0: - resolution: {integrity: sha512-NfJ4UzBCcQGLDlQq7nHxH+tv3kyZ0hHQqF5BO6J7tNJeP5do1llPr8dZ8zHonfhAu0PHAdMkSo+8o0wxg9lZWw==} - engines: {node: '>=0.8'} + '@snyk/github-codeowners@1.1.0': + resolution: {integrity: sha512-lGFf08pbkEac0NYgVf4hdANpAgApRjNByLXB+WBip3qj1iendOIyAwP2GKkKbQMNVy2r1xxDf0ssfWscoiC+Vw==} + engines: {node: '>=8.10'} + hasBin: true - assertion-error@1.1.0: - resolution: {integrity: sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==} + '@socket.io/component-emitter@3.1.2': + resolution: {integrity: sha512-9BCxFwvbGg/RsZK9tjXd8s4UcwR0MWeFQ1XEKIQVVvAGJyINdrqKMcTRyLoK8Rse1GjzLV9cwjWV1olXRWEXVA==} - assertion-error@2.0.1: - resolution: {integrity: sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA==} - engines: {node: '>=12'} + '@solidity-parser/parser@0.20.2': + resolution: {integrity: sha512-rbu0bzwNvMcwAjH86hiEAcOeRI2EeK8zCkHDrFykh/Al8mvJeFmjy3UrE7GYQjNwOgbGUUtCn5/k8CB8zIu7QA==} - ast-parents@0.0.1: - resolution: {integrity: sha512-XHusKxKz3zoYk1ic8Un640joHbFMhbqneyoZfoKnEGtf2ey9Uh/IdpcQplODdO/kENaMIWsD0nJm4+wX3UNLHA==} + '@speed-highlight/core@1.2.12': + resolution: {integrity: sha512-uilwrK0Ygyri5dToHYdZSjcvpS2ZwX0w5aSt3GCEN9hrjxWCoeV4Z2DTXuxjwbntaLQIEEAlCeNQss5SoHvAEA==} - ast-types@0.13.4: - resolution: {integrity: sha512-x1FCFnFifvYDDzTaLII71vG5uvDwgtmDTEVWAxrgeiR8VjMONcCXJx7E+USjDtHlwFmt9MysbqgF9b9Vjr6w+w==} - engines: {node: '>=4'} + '@swc/helpers@0.5.15': + resolution: {integrity: sha512-JQ5TuMi45Owi4/BIMAJBoSQoOJu12oOk/gADqlcUL9JEdHB8vyjUSsxqeNXnmXHjYKMi2WcYtezGEEhqUI/E2g==} - ast-v8-to-istanbul@0.3.11: - resolution: {integrity: sha512-Qya9fkoofMjCBNVdWINMjB5KZvkYfaO9/anwkWnjxibpWUxo5iHl2sOdP7/uAqaRuUYuoo8rDwnbaaKVFxoUvw==} + '@tailwindcss/cli@4.1.18': + resolution: {integrity: sha512-sMZ+lZbDyxwjD2E0L7oRUjJ01Ffjtme5OtjvvnC+cV4CEDcbqzbp25TCpxHj6kWLU9+DlqJOiNgSOgctC2aZmg==} + hasBin: true - astral-regex@2.0.0: - resolution: {integrity: sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==} - engines: {node: '>=8'} + '@tailwindcss/node@4.1.18': + resolution: {integrity: sha512-DoR7U1P7iYhw16qJ49fgXUlry1t4CpXeErJHnQ44JgTSKMaZUdf17cfn5mHchfJ4KRBZRFA/Coo+MUF5+gOaCQ==} - async-eventemitter@0.2.4: - resolution: {integrity: sha512-pd20BwL7Yt1zwDFy+8MX8F1+WCT8aQeKj0kQnTrH9WaeRETlRamVhD0JtRPmrV4GfOJ2F9CvdQkZeZhnh2TuHw==} + '@tailwindcss/oxide-android-arm64@4.1.18': + resolution: {integrity: sha512-dJHz7+Ugr9U/diKJA0W6N/6/cjI+ZTAoxPf9Iz9BFRF2GzEX8IvXxFIi/dZBloVJX/MZGvRuFA9rqwdiIEZQ0Q==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [android] - async-function@1.0.0: - resolution: {integrity: sha512-hsU18Ae8CDTR6Kgu9DYf0EbCr/a5iGL0rytQDobUcdpYOKokk8LEjVphnXkDkgpi0wYVsqrXuP0bZxJaTqdgoA==} - engines: {node: '>= 0.4'} + '@tailwindcss/oxide-darwin-arm64@4.1.18': + resolution: {integrity: sha512-Gc2q4Qhs660bhjyBSKgq6BYvwDz4G+BuyJ5H1xfhmDR3D8HnHCmT/BSkvSL0vQLy/nkMLY20PQ2OoYMO15Jd0A==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [darwin] - async-mutex@0.2.6: - resolution: {integrity: sha512-Hs4R+4SPgamu6rSGW8C7cV9gaWUKEHykfzCCvIRuaVv636Ju10ZdeUbvb4TBEW0INuq2DHZqXbK4Nd3yG4RaRw==} + '@tailwindcss/oxide-darwin-x64@4.1.18': + resolution: {integrity: sha512-FL5oxr2xQsFrc3X9o1fjHKBYBMD1QZNyc1Xzw/h5Qu4XnEBi3dZn96HcHm41c/euGV+GRiXFfh2hUCyKi/e+yw==} + engines: {node: '>= 10'} + cpu: [x64] + os: [darwin] - async-mutex@0.5.0: - resolution: {integrity: sha512-1A94B18jkJ3DYq284ohPxoXbfTA5HsQ7/Mf4DEhcyLx3Bz27Rh59iScbB6EPiP+B+joue6YCxcMXSbFC1tZKwA==} + '@tailwindcss/oxide-freebsd-x64@4.1.18': + resolution: {integrity: sha512-Fj+RHgu5bDodmV1dM9yAxlfJwkkWvLiRjbhuO2LEtwtlYlBgiAT4x/j5wQr1tC3SANAgD+0YcmWVrj8R9trVMA==} + engines: {node: '>= 10'} + cpu: [x64] + os: [freebsd] - async-ref@0.1.6: - resolution: {integrity: sha512-gIvfC7ahv452pM+nwnxZJd/vhUh8UFMrd1DCvIvWjoy9WrRmYroXTTDxwg91oiD+4CqQKrg+11uCxZrzat4UvQ==} + '@tailwindcss/oxide-linux-arm-gnueabihf@4.1.18': + resolution: {integrity: sha512-Fp+Wzk/Ws4dZn+LV2Nqx3IilnhH51YZoRaYHQsVq3RQvEl+71VGKFpkfHrLM/Li+kt5c0DJe/bHXK1eHgDmdiA==} + engines: {node: '>= 10'} + cpu: [arm] + os: [linux] - async-retry@1.3.3: - resolution: {integrity: sha512-wfr/jstw9xNi/0teMHrRW7dsz3Lt5ARhYNZ2ewpadnhaIp5mbALhOAP+EAdsC7t4Z6wqsDVv9+W6gm1Dk9mEyw==} + '@tailwindcss/oxide-linux-arm64-gnu@4.1.18': + resolution: {integrity: sha512-S0n3jboLysNbh55Vrt7pk9wgpyTTPD0fdQeh7wQfMqLPM/Hrxi+dVsLsPrycQjGKEQk85Kgbx+6+QnYNiHalnw==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [linux] - async@1.5.2: - resolution: {integrity: sha512-nSVgobk4rv61R9PUSDtYt7mPVB2olxNR5RWJcAsH676/ef11bUZwvu7+RGYrYauVdDPcO519v68wRhXQtxsV9w==} + '@tailwindcss/oxide-linux-arm64-musl@4.1.18': + resolution: {integrity: sha512-1px92582HkPQlaaCkdRcio71p8bc8i/ap5807tPRDK/uw953cauQBT8c5tVGkOwrHMfc2Yh6UuxaH4vtTjGvHg==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [linux] - async@3.2.6: - resolution: {integrity: sha512-htCUDlxyyCLMgaM3xXg0C0LW2xqfuQ6p05pCEIsXuyQ+a1koYKTuBMzRNwmybfLgvJDMd0r1LTn4+E0Ti6C2AA==} + '@tailwindcss/oxide-linux-x64-gnu@4.1.18': + resolution: {integrity: sha512-v3gyT0ivkfBLoZGF9LyHmts0Isc8jHZyVcbzio6Wpzifg/+5ZJpDiRiUhDLkcr7f/r38SWNe7ucxmGW3j3Kb/g==} + engines: {node: '>= 10'} + cpu: [x64] + os: [linux] - asynckit@0.4.0: - resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==} + '@tailwindcss/oxide-linux-x64-musl@4.1.18': + resolution: {integrity: sha512-bhJ2y2OQNlcRwwgOAGMY0xTFStt4/wyU6pvI6LSuZpRgKQwxTec0/3Scu91O8ir7qCR3AuepQKLU/kX99FouqQ==} + engines: {node: '>= 10'} + cpu: [x64] + os: [linux] - available-typed-arrays@1.0.7: - resolution: {integrity: sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==} - engines: {node: '>= 0.4'} + '@tailwindcss/oxide-wasm32-wasi@4.1.18': + resolution: {integrity: sha512-LffYTvPjODiP6PT16oNeUQJzNVyJl1cjIebq/rWWBF+3eDst5JGEFSc5cWxyRCJ0Mxl+KyIkqRxk1XPEs9x8TA==} + engines: {node: '>=14.0.0'} + cpu: [wasm32] + bundledDependencies: + - '@napi-rs/wasm-runtime' + - '@emnapi/core' + - '@emnapi/runtime' + - '@tybys/wasm-util' + - '@emnapi/wasi-threads' + - tslib + + '@tailwindcss/oxide-win32-arm64-msvc@4.1.18': + resolution: {integrity: sha512-HjSA7mr9HmC8fu6bdsZvZ+dhjyGCLdotjVOgLA2vEqxEBZaQo9YTX4kwgEvPCpRh8o4uWc4J/wEoFzhEmjvPbA==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [win32] - aws-sign2@0.7.0: - resolution: {integrity: sha512-08kcGqnYf/YmjoRhfxyu+CLxBjUtHLXLXX/vUfx9l2LYzG3c1m61nrpyFUZI6zeS+Li/wWMMidD9KgrqtGq3mA==} + '@tailwindcss/oxide-win32-x64-msvc@4.1.18': + resolution: {integrity: sha512-bJWbyYpUlqamC8dpR7pfjA0I7vdF6t5VpUGMWRkXVE3AXgIZjYUYAK7II1GNaxR8J1SSrSrppRar8G++JekE3Q==} + engines: {node: '>= 10'} + cpu: [x64] + os: [win32] - aws4@1.13.2: - resolution: {integrity: sha512-lHe62zvbTB5eEABUVi/AwVh0ZKY9rMMDhmm+eeyuuUQbQ3+J+fONVQOZyj+DdrvD4BY33uYniyRJ4UJIaSKAfw==} + '@tailwindcss/oxide@4.1.18': + resolution: {integrity: sha512-EgCR5tTS5bUSKQgzeMClT6iCY3ToqE1y+ZB0AKldj809QXk1Y+3jB0upOYZrn9aGIzPtUsP7sX4QQ4XtjBB95A==} + engines: {node: '>= 10'} - axios@1.15.2: - resolution: {integrity: sha512-wLrXxPtcrPTsNlJmKjkPnNPK2Ihe0hn0wGSaTEiHRPxwjvJwT3hKmXF4dpqxmPO9SoNb2FsYXj/xEo0gHN+D5A==} + '@tanstack/match-sorter-utils@8.15.1': + resolution: {integrity: sha512-PnVV3d2poenUM31ZbZi/yXkBu3J7kd5k2u51CGwwNojag451AjTH9N6n41yjXz2fpLeewleyLBmNS6+HcGDlXw==} + engines: {node: '>=12'} - backo2@1.0.2: - resolution: {integrity: sha512-zj6Z6M7Eq+PBZ7PQxl5NT665MvJdAkzp0f60nAJ+sLaSCBPMwVak5ZegFbgVCzFcCJTKFoMizvM5Ld7+JrRJHA==} + '@tanstack/query-core@5.0.5': + resolution: {integrity: sha512-MThCETMkHDHTnFZHp71L+SqTtD5d6XHftFCVR1xRJdWM3qGrlQ2VCXaj0SKVcyJej2e1Opa2c7iknu1llxCDNQ==} - backoff@2.5.0: - resolution: {integrity: sha512-wC5ihrnUXmR2douXmXLCe5O3zg3GKIyvRi/hi58a/XyRxVI+3/yM0PYueQOZXPXQ9pxBislYkw+sF9b7C/RuMA==} - engines: {node: '>= 0.6'} + '@tanstack/query-core@5.49.1': + resolution: {integrity: sha512-JnC9ndmD1KKS01Rt/ovRUB1tmwO7zkyXAyIxN9mznuJrcNtOrkmOnQqdJF2ib9oHzc2VxHomnEG7xyfo54Npkw==} - balanced-match@1.0.2: - resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==} + '@tanstack/query-core@5.90.15': + resolution: {integrity: sha512-mInIZNUZftbERE+/Hbtswfse49uUQwch46p+27gP9DWJL927UjnaWEF2t3RMOqBcXbfMdcNkPe06VyUIAZTV1g==} - balanced-match@4.0.4: - resolution: {integrity: sha512-BLrgEcRTwX2o6gGxGOCNyMvGSp35YofuYzw9h1IMTRmKqttAZZVU67bdb9Pr2vUHA8+j3i2tJfjO6C6+4myGTA==} - engines: {node: 18 || 20 || >=22} + '@tanstack/query-devtools@5.0.5': + resolution: {integrity: sha512-xjuOhOrrO50sPoJ4WG9yPe3imQ0Ds/nutnmwdTqjM2ZTIkflh//p7q2iB6IxFBY9sB106h+PULlma8sgTuOKAQ==} - base-x@3.0.11: - resolution: {integrity: sha512-xz7wQ8xDhdyP7tQxwdteLYeFfS68tSMNCZ/Y37WJ4bhGfKPpqEIlmIyueQHqOyoPhE6xNUqjzRr8ra0eF9VRvA==} + '@tanstack/query-persist-client-core@5.0.5': + resolution: {integrity: sha512-xdxDiSN/gBG1QJBiyNZPv2y1DOBMrILvhrEd9PgtOzE1AswmgVUh96KENiD7QiABKCVVIihDtSDvJGj0ukbudg==} - base64-arraybuffer-es6@0.7.0: - resolution: {integrity: sha512-ESyU/U1CFZDJUdr+neHRhNozeCv72Y7Vm0m1DCbjX3KBjT6eYocvAJlSk6+8+HkVwXlT1FNxhGW6q3UKAlCvvw==} - engines: {node: '>=6.0.0'} + '@tanstack/query-sync-storage-persister@5.0.5': + resolution: {integrity: sha512-uk2/mcNf+YYVza3XaU61RSPCcIi/p+0DfsZWMyIim1yCxF7hzZ17zWheM/2v3zZbeTY/C6m1NIO9KIRiPAM9Mg==} - base64-arraybuffer@0.1.5: - resolution: {integrity: sha512-437oANT9tP582zZMwSvZGy2nmSeAb8DW2me3y+Uv1Wp2Rulr8Mqlyrv3E7MLxmsiaPSMMDmiDVzgE+e8zlMx9g==} - engines: {node: '>= 0.6.0'} + '@tanstack/react-query-devtools@5.0.5': + resolution: {integrity: sha512-vJyS7HXx2zw43TQjm3m4uyaNUgGizOpK2SZL9Lc+DZSuhFbuZ55UEYJTz8yudCbHdLXlkuVZwo6TWWOhXWJFeA==} + peerDependencies: + '@tanstack/react-query': ^5.0.5 + react: ^18.0.0 + react-dom: ^18.0.0 - base64-js@1.5.1: - resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==} + '@tanstack/react-query-persist-client@5.0.5': + resolution: {integrity: sha512-V/jIKdiw0WyJYpnzwnKS+O19jgJPWSBDzvx9qFaXAm98Jnt+lGWFBZdUR0MgY2ufM1fbeejXTjcorgwqjc3kaA==} + peerDependencies: + '@tanstack/react-query': ^5.0.5 + react: ^18.0.0 + react-dom: ^18.0.0 - baseline-browser-mapping@2.10.21: - resolution: {integrity: sha512-Q+rUQ7Uz8AHM7DEaNdwvfFCTq7a43lNTzuS94eiWqwyxfV/wJv+oUivef51T91mmRY4d4A1u9rcSvkeufCVXlA==} - engines: {node: '>=6.0.0'} - hasBin: true + '@tanstack/react-query@5.49.2': + resolution: {integrity: sha512-6rfwXDK9BvmHISbNFuGd+wY3P44lyW7lWiA9vIFGT/T0P9aHD1VkjTvcM4SDAIbAQ9ygEZZoLt7dlU1o3NjMVA==} + peerDependencies: + react: ^18.0.0 - basic-ftp@5.3.0: - resolution: {integrity: sha512-5K9eNNn7ywHPsYnFwjKgYH8Hf8B5emh7JKcPaVjjrMJFQQwGpwowEnZNEtHs7DfR7hCZsmaK3VA4HUK0YarT+w==} - engines: {node: '>=10.0.0'} + '@tanstack/react-query@5.90.15': + resolution: {integrity: sha512-uQvnDDcTOgJouNtAyrgRej+Azf0U5WDov3PXmHFUBc+t1INnAYhIlpZtCGNBLwCN41b43yO7dPNZu8xWkUFBwQ==} + peerDependencies: + react: ^18 || ^19 - bcrypt-pbkdf@1.0.2: - resolution: {integrity: sha512-qeFIXtP4MSoi6NLqO12WfqARWWuCKi2Rn/9hJLEmtB5yTNr9DqFWkJRCf2qShWzPeAMRnOgCrq0sg/KLv5ES9w==} + '@tanstack/vue-query@5.49.1': + resolution: {integrity: sha512-/nTqP8PNCRzMcqTGEuFQE3ntUD3A+K05r6Dw/0hNwNS3PLEaKUKlxytmAhIoaoloQwbbAghjLyKRQZ+CMWv90A==} + peerDependencies: + '@vue/composition-api': ^1.1.2 + vue: ^2.6.0 || ^3.3.0 + peerDependenciesMeta: + '@vue/composition-api': + optional: true - bech32@1.1.4: - resolution: {integrity: sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==} + '@testing-library/dom@10.4.0': + resolution: {integrity: sha512-pemlzrSESWbdAloYml3bAJMEfNh1Z7EduzqPKprCH5S341frlpYnUEW0H72dLxa6IsYr+mPno20GiSm+h9dEdQ==} + engines: {node: '>=18'} - better-path-resolve@1.0.0: - resolution: {integrity: sha512-pbnl5XzGBdrFU/wT4jqmJVPn2B6UHPBOhzMQkY/SPUPB6QtUXtmBHBIwCbXJol93mOpGMnQyP/+BB19q04xj7g==} - engines: {node: '>=4'} + '@testing-library/react@16.0.1': + resolution: {integrity: sha512-dSmwJVtJXmku+iocRhWOUFbrERC76TX2Mnf0ATODz8brzAZrMBbzLwQixlBSanZxR6LddK3eiwpSFZgDET1URg==} + engines: {node: '>=18'} + peerDependencies: + '@testing-library/dom': ^10.0.0 + '@types/react': ^18.0.0 + '@types/react-dom': ^18.0.0 + react: ^18.0.0 + react-dom: ^18.0.0 + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true - bignumber.js@7.2.1: - resolution: {integrity: sha512-S4XzBk5sMB+Rcb/LNcpzXr57VRTxgAvaAEDAl1AwRx27j00hT84O6OkteE7u8UB3NuaaygCRrEpqox4uDOrbdQ==} + '@tootallnate/once@2.0.0': + resolution: {integrity: sha512-XCuKFP5PS55gnMVu3dty8KPatLqUoy/ZYzDzAGCQ8JNFCkLXzmI7vNHCR+XpbZaMWQK/vQubr7PkYq8g470J/A==} + engines: {node: '>= 10'} - bignumber.js@9.3.1: - resolution: {integrity: sha512-Ko0uX15oIUS7wJ3Rb30Fs6SkVbLmPBAKdlm7q9+ak9bbIeFf0MwuBsQV6z7+X768/cHsfg+WlysDWJcmthjsjQ==} + '@ts-morph/common@0.11.1': + resolution: {integrity: sha512-7hWZS0NRpEsNV8vWJzg7FEz6V8MaLNeJOmwmghqUXTpzk16V1LLZhdo+4QvE/+zv4cVci0OviuJFnqhEfoV3+g==} - binary-extensions@2.3.0: - resolution: {integrity: sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==} - engines: {node: '>=8'} + '@tsconfig/node10@1.0.12': + resolution: {integrity: sha512-UCYBaeFvM11aU2y3YPZ//O5Rhj+xKyzy7mvcIoAjASbigy8mHMryP5cK7dgjlz2hWxh1g5pLw084E0a/wlUSFQ==} - bip39@3.0.4: - resolution: {integrity: sha512-YZKQlb752TrUWqHWj7XAwCSjYEgGAk+/Aas3V7NyjQeZYsztO8JnQUaCWhcnL4T+jL8nvB8typ2jRPzTlgugNw==} + '@tsconfig/node12@1.0.11': + resolution: {integrity: sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==} - bl@4.1.0: - resolution: {integrity: sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==} + '@tsconfig/node14@1.0.3': + resolution: {integrity: sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==} - blakejs@1.2.1: - resolution: {integrity: sha512-QXUSXI3QVc/gJME0dBpXrag1kbzOqCjCX8/b54ntNyW6sjtoqxqRk3LTmXzaJoh71zMsDCjM+47jS7XiwN/+fQ==} + '@tsconfig/node16@1.0.4': + resolution: {integrity: sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==} - bluebird@3.7.2: - resolution: {integrity: sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==} + '@tybys/wasm-util@0.10.1': + resolution: {integrity: sha512-9tTaPJLSiejZKx+Bmog4uSubteqTvFrVrURwkmHixBo0G4seD0zUxp98E1DzUBJxLQ3NPwXrGKDiVjwx/DpPsg==} - bn-chai@1.0.1: - resolution: {integrity: sha512-7rJXt21DwYiLLpvzLaACixBBoUGkRV1iuFD3wElEhw8Ji9IiY/QsJRtvW+c7ChRgEOyLQkGaSGFUUqBKm21SNA==} + '@typechain/ethers-v6@0.5.1': + resolution: {integrity: sha512-F+GklO8jBWlsaVV+9oHaPh5NJdd6rAKN4tklGfInX1Q7h0xPgVLP39Jl3eCulPB5qexI71ZFHwbljx4ZXNfouA==} peerDependencies: - chai: '>= 2.1.2 < 5' + ethers: 6.x + typechain: ^8.3.2 + typescript: '>=4.7.0' - bn.js@5.2.3: - resolution: {integrity: sha512-EAcmnPkxpntVL+DS7bO1zhcZNvCkxqtkd0ZY53h06GNQ3DEkkGZ/gKgmDv6DdZQGj9BgfSPKtJJ7Dp1GPP8f7w==} + '@types/aria-query@5.0.4': + resolution: {integrity: sha512-rfT93uj5s0PRL7EzccGMs3brplhcrghnDoV26NqKhCAS1hVo+WdNsPvE/yb6ilfr5hi2MEk6d5EWJTKdxg8jVw==} - body-parser@1.20.5: - resolution: {integrity: sha512-3grm+/2tUOvu2cjJkvsIxrv/wVpfXQW4PsQHYm7yk4vfpu7Ekl6nEsYBoJUL6qDwZUx8wUhQ8tR2qz+ad9c9OA==} - engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16} + '@types/babel__core@7.20.5': + resolution: {integrity: sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==} - bowser@2.14.1: - resolution: {integrity: sha512-tzPjzCxygAKWFOJP011oxFHs57HzIhOEracIgAePE4pqB3LikALKnSzUyU4MGs9/iCEUuHlAJTjTc5M+u7YEGg==} + '@types/babel__generator@7.6.5': + resolution: {integrity: sha512-h9yIuWbJKdOPLJTbmSpPzkF67e659PbQDba7ifWm5BJ8xTv+sDmS7rFmywkWOvXedGTivCdeGSIIX8WLcRTz8w==} - boxen@5.1.2: - resolution: {integrity: sha512-9gYgQKXx+1nP8mP7CzFyaUARhg7D3n1dF/FnErWmu9l6JvGpNUN278h0aSb+QjoiKSWG+iZ3uHrcqk0qrY9RQQ==} - engines: {node: '>=10'} + '@types/babel__template@7.4.2': + resolution: {integrity: sha512-/AVzPICMhMOMYoSx9MoKpGDKdBRsIXMNByh1PXSZoa+v6ZoLa8xxtsT/uLQ/NJm0XVAWl/BvId4MlDeXJaeIZQ==} - brace-expansion@1.1.14: - resolution: {integrity: sha512-MWPGfDxnyzKU7rNOW9SP/c50vi3xrmrua/+6hfPbCS2ABNWfx24vPidzvC7krjU/RTo235sV776ymlsMtGKj8g==} + '@types/babel__traverse@7.20.2': + resolution: {integrity: sha512-ojlGK1Hsfce93J0+kn3H5R73elidKUaZonirN33GSmgTUMpzI/MIFfSpF3haANe3G1bEBS9/9/QEqwTzwqFsKw==} - brace-expansion@2.1.0: - resolution: {integrity: sha512-TN1kCZAgdgweJhWWpgKYrQaMNHcDULHkWwQIspdtjV4Y5aurRdZpjAqn6yX3FPqTA9ngHCc4hJxMAMgGfve85w==} + '@types/bn.js@4.11.6': + resolution: {integrity: sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==} - brace-expansion@5.0.5: - resolution: {integrity: sha512-VZznLgtwhn+Mact9tfiwx64fA9erHH/MCXEUfB/0bX/6Fz6ny5EGTXYltMocqg4xFAQZtnO3DHWWXi8RiuN7cQ==} - engines: {node: 18 || 20 || >=22} + '@types/bn.js@5.1.5': + resolution: {integrity: sha512-V46N0zwKRF5Q00AZ6hWtN0T8gGmDUaUzLWQvHFo5yThtVwK/VCenFY3wXVbOvNfajEpsTfQM4IN9k/d6gUVX3A==} - braces@3.0.3: - resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==} - engines: {node: '>=8'} + '@types/bun@1.1.10': + resolution: {integrity: sha512-76KYVSwrHwr9zsnk6oLXOGs9KvyBg3U066GLO4rk6JZk1ypEPGCUDZ5yOiESyIHWs9cx9iC8r01utYN32XdmgA==} - brorand@1.1.0: - resolution: {integrity: sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==} + '@types/cookie@0.6.0': + resolution: {integrity: sha512-4Kh9a6B2bQciAhf7FSuMRRkUWecJgJu9nPnx3yzpsfXX/c50REIqpHY4C82bXP90qrLtXtkDxTZosYO3UpOwlA==} - brotli-wasm@3.0.1: - resolution: {integrity: sha512-U3K72/JAi3jITpdhZBqzSUq+DUY697tLxOuFXB+FpAE/Ug+5C3VZrv4uA674EUZHxNAuQ9wETXNqQkxZD6oL4A==} - engines: {node: '>=v18.0.0'} + '@types/cross-spawn@6.0.6': + resolution: {integrity: sha512-fXRhhUkG4H3TQk5dBhQ7m/JDdSNHKwR2BBia62lhwEIq9xGiQKLxd6LymNhn47SjXhsUEPmxi+PKw2OkW4LLjA==} - browser-stdout@1.3.1: - resolution: {integrity: sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==} + '@types/debug@4.1.12': + resolution: {integrity: sha512-vIChWdVG3LG1SMxEvI/AK+FWJthlrqlTu7fbrlywTkkaONwk/UAGaULXRlf8vkzFBLVm0zkMdCquhL5aOjhXPQ==} - browserify-aes@1.2.0: - resolution: {integrity: sha512-+7CHXqGuspUn/Sl5aO7Ea0xWGAtETPXNSAjHo48JfLdPWcMng33Xe4znFvQweqc/uzk5zSOI3H52CYnjCfb5hA==} + '@types/debug@4.1.7': + resolution: {integrity: sha512-9AonUzyTjXXhEOa0DnqpzZi6VHlqKMswga9EXjpXnnqxwLtdvPPtlO8evrI5D9S6asFRCQ6v+wpiUKbw+vKqyg==} - browserslist@4.28.1: - resolution: {integrity: sha512-ZC5Bd0LgJXgwGqUknZY/vkUQ04r8NXnJZ3yYi4vDmSiZmC/pdSN0NbNRPxZpbtO4uAfDUAFffO8IZoM3Gj8IkA==} - engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} - hasBin: true + '@types/dedent@0.7.2': + resolution: {integrity: sha512-kRiitIeUg1mPV9yH4VUJ/1uk2XjyANfeL8/7rH1tsjvHeO9PJLBHJIYsFWmAvmGj5u8rj+1TZx7PZzW2qLw3Lw==} - browserslist@4.28.2: - resolution: {integrity: sha512-48xSriZYYg+8qXna9kwqjIVzuQxi+KYWp2+5nCYnYKPTr0LvD89Jqk2Or5ogxz0NUMfIjhh2lIUX/LyX9B4oIg==} - engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} - hasBin: true + '@types/estree@1.0.5': + resolution: {integrity: sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==} - bs58@4.0.1: - resolution: {integrity: sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==} + '@types/estree@1.0.8': + resolution: {integrity: sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==} - bs58check@2.1.2: - resolution: {integrity: sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==} + '@types/hast@3.0.4': + resolution: {integrity: sha512-WPs+bbQw5aCj+x6laNGWLH3wviHtoCv/P3+otBhbOhJgG8qtpdAMlTCxLtsTWA7LH1Oh/bFCHsBn0TPS5m30EQ==} - btoa@1.2.1: - resolution: {integrity: sha512-SB4/MIGlsiVkMcHmT+pSmIPoNDoHg+7cMzmt3Uxt628MTz2487DKSqK/fuhFBrkuqrYv5UCEnACpF4dTFNKc/g==} - engines: {node: '>= 0.4.0'} - hasBin: true + '@types/json-schema@7.0.15': + resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==} - buffer-from@1.1.2: - resolution: {integrity: sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==} + '@types/linkify-it@5.0.0': + resolution: {integrity: sha512-sVDA58zAw4eWAffKOaQH5/5j3XeayukzDk+ewSsnv3p4yJEZHCCzMDiZM8e0OUrRvmpGZ85jf4yDHkHsgBNr9Q==} - buffer-to-arraybuffer@0.0.5: - resolution: {integrity: sha512-3dthu5CYiVB1DEJp61FtApNnNndTckcqe4pFcLdvHtrpG+kcyekCJKg4MRiDcFW7A6AODnXB9U4dwQiCW5kzJQ==} + '@types/lru-cache@5.1.1': + resolution: {integrity: sha512-ssE3Vlrys7sdIzs5LOxCzTVMsU7i9oa/IaW92wF32JFb3CVczqOkru2xspuKczHEbG3nvmPY7IFqVmGGHdNbYw==} - buffer-xor@1.0.3: - resolution: {integrity: sha512-571s0T7nZWK6vB67HI5dyUF7wXiNcfaPPPTl6zYCNApANjIvYJTg7hlud/+cJpdAhS7dVzqMLmfhfHR3rAcOjQ==} + '@types/markdown-it@14.1.2': + resolution: {integrity: sha512-promo4eFwuiW+TfGxhi+0x3czqTYJkG8qB17ZUJiVF10Xm7NLVRSLUsfRTU/6h1e24VvRnXCx+hG7li58lkzog==} - buffer-xor@2.0.2: - resolution: {integrity: sha512-eHslX0bin3GB+Lx2p7lEYRShRewuNZL3fUl4qlVJGGiwoPGftmt8JQgk2Y9Ji5/01TnVDo33E5b5O3vUB1HdqQ==} + '@types/mdast@4.0.3': + resolution: {integrity: sha512-LsjtqsyF+d2/yFOYaN22dHZI1Cpwkrj+g06G8+qtUKlhovPW89YhqSnfKtMbkgmEtYpH2gydRNULd6y8mciAFg==} - buffer@4.9.2: - resolution: {integrity: sha512-xq+q3SRMOxGivLhBNaUdC64hDTQwejJ+H0T/NB1XMtTVEwNTrfFF3gAxiyW0Bu/xWEGhjVKgUcMhCrUy2+uCWg==} + '@types/mdurl@2.0.0': + resolution: {integrity: sha512-RGdgjQUZba5p6QEFAVx2OGb8rQDL/cPRG7GiedRzMcJ1tYnUANBncjbSB1NRGwbvjcPeikRABz2nshyPk1bhWg==} - buffer@5.7.1: - resolution: {integrity: sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==} + '@types/ms@0.7.31': + resolution: {integrity: sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA==} - buffer@6.0.3: - resolution: {integrity: sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==} + '@types/ms@2.1.0': + resolution: {integrity: sha512-GsCCIZDE/p3i96vtEqx+7dBUGXrc7zeSK3wwPHIaRThS+9OhWIXRqzs4d6k1SVU8g91DrNRWxWUGhp5KXQb2VA==} - bufferutil@4.0.5: - resolution: {integrity: sha512-HTm14iMQKK2FjFLRTM5lAVcyaUzOnqbPtesFIvREgXpJHdQm8bWS+GkQgIkfaBYRHuCnea7w8UVNfwiAQhlr9A==} - engines: {node: '>=6.14.2'} + '@types/mute-stream@0.0.4': + resolution: {integrity: sha512-CPM9nzrCPPJHQNA9keH9CVkVI+WR5kMa+7XEs5jcGQ0VoAGnLv242w8lIVgwAEfmE4oufJRaTc9PNLQl0ioAow==} - bufferutil@4.0.7: - resolution: {integrity: sha512-kukuqc39WOHtdxtw4UScxF/WVnMFVSQVKhtx3AjZJzhd0RGZZldcrfSEbVsWWe6KNH253574cq5F+wpv0G9pJw==} - engines: {node: '>=6.14.2'} + '@types/node@12.20.55': + resolution: {integrity: sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ==} - bufferutil@4.1.0: - resolution: {integrity: sha512-ZMANVnAixE6AWWnPzlW2KpUrxhm9woycYvPOo67jWHyFowASTEd9s+QN1EIMsSDtwhIxN4sWE1jotpuDUIgyIw==} - engines: {node: '>=6.14.2'} + '@types/node@16.18.11': + resolution: {integrity: sha512-3oJbGBUWuS6ahSnEq1eN2XrCyf4YsWI8OyCvo7c64zQJNplk3mO84t53o8lfTk+2ji59g5ycfc6qQ3fdHliHuA==} - bytes@3.1.2: - resolution: {integrity: sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==} - engines: {node: '>= 0.8'} + '@types/node@20.12.10': + resolution: {integrity: sha512-Eem5pH9pmWBHoGAT8Dr5fdc5rYA+4NAovdM4EktRPVAAiJhmWWfQrA0cFhAbOsQdSfIHjAud6YdkbL69+zSKjw==} - bytestreamjs@2.0.1: - resolution: {integrity: sha512-U1Z/ob71V/bXfVABvNr/Kumf5VyeQRBEm6Txb0PQ6S7V5GpBM3w4Cbqz/xPDicR5tN0uvDifng8C+5qECeGwyQ==} - engines: {node: '>=6.0.0'} + '@types/node@20.12.14': + resolution: {integrity: sha512-scnD59RpYD91xngrQQLGkE+6UrHUPzeKZWhhjBSa3HSkwjbQc38+q3RoIVEwxQGRw3M+j5hpNAM+lgV3cVormg==} - cacache@18.0.4: - resolution: {integrity: sha512-B+L5iIa9mgcjLbliir2th36yEwPftrzteHYujzsx3dFP/31GCHcIeS8f5MGd80odLOjaOvSpU3EEAmRQptkxLQ==} - engines: {node: ^16.14.0 || >=18.0.0} + '@types/node@20.19.27': + resolution: {integrity: sha512-N2clP5pJhB2YnZJ3PIHFk5RkygRX5WO/5f0WC08tp0wd+sv0rsJk3MqWn3CbNmT2J505a5336jaQj4ph1AdMug==} - cacheable-lookup@5.0.4: - resolution: {integrity: sha512-2/kNscPhpcxrOigMZzbiWF7dz8ilhb/nIHU3EyZiXWXpeq/au8qJ8VhdftMkty3n7Gj6HIGalQG8oiBNB3AJgA==} - engines: {node: '>=10.6.0'} + '@types/node@22.15.31': + resolution: {integrity: sha512-jnVe5ULKl6tijxUhvQeNbQG/84fHfg+yMak02cT8QVhBx/F05rAVxCGBYYTh2EKz22D6JF5ktXuNwdx7b9iEGw==} - cacheable-lookup@6.1.0: - resolution: {integrity: sha512-KJ/Dmo1lDDhmW2XDPMo+9oiy/CeqosPguPCrgcVzKyZrL6pM1gU2GmPY/xo6OQPTUaA/c0kwHuywB4E6nmT9ww==} - engines: {node: '>=10.6.0'} + '@types/node@22.7.5': + resolution: {integrity: sha512-jML7s2NAzMWc//QSJ1a3prpk78cOPchGvXJsC3C6R6PSMoooztvRVQEz89gmBTBY1SPMaqo5teB4uNHPdetShQ==} - cacheable-request@7.0.4: - resolution: {integrity: sha512-v+p6ongsrp0yTGbJXjgxPow2+DL93DASP4kXCDKb8/bwRtt9OEF3whggkkDkGNzgcWy2XaF4a8nZglC7uElscg==} - engines: {node: '>=8'} + '@types/node@24.0.1': + resolution: {integrity: sha512-MX4Zioh39chHlDJbKmEgydJDS3tspMP/lnQC67G3SWsTnb9NeYVWOjkxpOSy4oMfPs4StcWHwBrvUb4ybfnuaw==} - caching-transform@4.0.0: - resolution: {integrity: sha512-kpqOvwXnjjN44D89K5ccQC+RUrsy7jB/XLlRrx0D7/2HNcTPqzsb6XgYoErwko6QsV184CA2YgS1fxDiiDZMWA==} - engines: {node: '>=8'} + '@types/parse-path@7.1.0': + resolution: {integrity: sha512-EULJ8LApcVEPbrfND0cRQqutIOdiIgJ1Mgrhpy755r14xMohPTEpkV/k28SJvuOs9bHRFW8x+KeDAEPiGQPB9Q==} + deprecated: This is a stub types definition. parse-path provides its own type definitions, so you do not need this installed. - call-bind-apply-helpers@1.0.2: - resolution: {integrity: sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==} - engines: {node: '>= 0.4'} + '@types/pbkdf2@3.1.2': + resolution: {integrity: sha512-uRwJqmiXmh9++aSu1VNEn3iIxWOhd8AHXNSdlaLfdAAdSTY9jYVeGWnzejM3dvrkbqE3/hyQkQQ29IFATEGlew==} - call-bind@1.0.8: - resolution: {integrity: sha512-oKlSFMcMwpUg2ednkhQ454wfWiU/ul3CkJe/PEHcTKuiX6RpbehUiFMXu13HalGZxfUwCQzZG747YXBn1im9ww==} - engines: {node: '>= 0.4'} + '@types/prompts@2.4.9': + resolution: {integrity: sha512-qTxFi6Buiu8+50/+3DGIWLHM6QuWsEKugJnnP6iv2Mc4ncxE4A/OJkjuVOA+5X0X1S/nq5VJRa8Lu+nwcvbrKA==} - call-bind@1.0.9: - resolution: {integrity: sha512-a/hy+pNsFUTR+Iz8TCJvXudKVLAnz/DyeSUo10I5yvFDQJBFU2s9uqQpoSrJlroHUKoKqzg+epxyP9lqFdzfBQ==} - engines: {node: '>= 0.4'} + '@types/prop-types@15.7.15': + resolution: {integrity: sha512-F6bEyamV9jKGAFBEmlQnesRPGOQqS2+Uwi0Em15xenOxHaf2hv6L8YCVn3rPdPJOiJfPiCnLIRyvwVaqMY3MIw==} - call-bound@1.0.4: - resolution: {integrity: sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==} - engines: {node: '>= 0.4'} + '@types/prop-types@15.7.5': + resolution: {integrity: sha512-JCB8C6SnDoQf0cNycqd/35A7MjcnK+ZTqE7judS6o7utxUCg6imJg3QK2qzHKszlTjcj2cn+NwMB2i96ubpj7w==} - callsites@3.1.0: - resolution: {integrity: sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==} - engines: {node: '>=6'} + '@types/react-dom@18.3.0': + resolution: {integrity: sha512-EhwApuTmMBmXuFOikhQLIBUn6uFg81SwLMOAUgodJF14SOBOCMdU04gDoYi0WOJJHD144TL32z4yDqCW3dnkQg==} - camel-case@3.0.0: - resolution: {integrity: sha512-+MbKztAYHXPr1jNTSKQF52VpcFjwY5RkR7fxksV8Doo4KAYc5Fl4UJRgthBbTmEx8C54DqahhbLJkDwjI3PI/w==} + '@types/react@18.3.1': + resolution: {integrity: sha512-V0kuGBX3+prX+DQ/7r2qsv1NsdfnCLnTgnRJ1pYnxykBhGMz+qj+box5lq7XsO5mtZsBqpjwwTu/7wszPfMBcw==} - camelcase@5.3.1: - resolution: {integrity: sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==} - engines: {node: '>=6'} + '@types/react@18.3.27': + resolution: {integrity: sha512-cisd7gxkzjBKU2GgdYrTdtQx1SORymWyaAFhaxQPK9bYO9ot3Y5OikQRvY0VYQtvwjeQnizCINJAenh/V7MK2w==} - camelcase@6.3.0: - resolution: {integrity: sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==} - engines: {node: '>=10'} + '@types/resolve@1.20.2': + resolution: {integrity: sha512-60BCwRFOZCQhDncwQdxxeOEEkbc5dIMccYLwbxsS4TUNeVECQ/pBJ0j09mrHOl/JJvpRPGwO9SvE4nR2Nb/a4Q==} - caniuse-lite@1.0.30001790: - resolution: {integrity: sha512-bOoxfJPyYo+ds6W0YfptaCWbFnJYjh2Y1Eow5lRv+vI2u8ganPZqNm1JwNh0t2ELQCqIWg4B3dWEusgAmsoyOw==} + '@types/secp256k1@4.0.3': + resolution: {integrity: sha512-Da66lEIFeIz9ltsdMZcpQvmrmmoqrfju8pm1BH8WbYjZSwUgCwXLb9C+9XYogwBITnbsSaMdVPb2ekf7TV+03w==} - caseless@0.12.0: - resolution: {integrity: sha512-4tYFyifaFfGacoiObjJegolkwSU4xQNGbVgUiNYVUxbQ2x2lUsFvY4hVgVzGiIe6WLOPqycWXA40l+PWsxthUw==} + '@types/semver@7.5.3': + resolution: {integrity: sha512-OxepLK9EuNEIPxWNME+C6WwbRAOOI2o2BaQEGzz5Lu2e4Z5eDnEo+/aVEDMIXywoJitJ7xWd641wrGLZdtwRyw==} - catering@2.1.1: - resolution: {integrity: sha512-K7Qy8O9p76sL3/3m7/zLKbRkyOlSZAgzEaLhyj2mXS8PsCud2Eo4hAb8aLtZqHh0QGqLcb9dlJSu6lHRVENm1w==} - engines: {node: '>=6'} + '@types/statuses@2.0.4': + resolution: {integrity: sha512-eqNDvZsCNY49OAXB0Firg/Sc2BgoWsntsLUdybGFOhAfCD6QJ2n9HXUIHGqt5qjrxmMv4wS8WLAw43ZkKcJ8Pw==} - cbor2@1.12.0: - resolution: {integrity: sha512-3Cco8XQhi27DogSp9Ri6LYNZLi/TBY/JVnDe+mj06NkBjW/ZYOtekaEU4wZ4xcRMNrFkDv8KNtOAqHyDfz3lYg==} - engines: {node: '>=18.7'} + '@types/tough-cookie@4.0.5': + resolution: {integrity: sha512-/Ad8+nIOV7Rl++6f1BdKxFSMgmoqEoYbHRpPcx3JEfv8VRsQe9Z4mCXeJBzxs7mbHY/XOZZuXlRNfhpVPbs6ZA==} - cbor@10.0.12: - resolution: {integrity: sha512-exQDevYd7ZQLP4moMQcZkKCVZsXLAtUSflObr3xTh4xzFIv/xBCdvCd6L259kQOUP2kcTC0jvC6PpZIf/WmRXA==} - engines: {node: '>=20'} + '@types/trusted-types@2.0.3': + resolution: {integrity: sha512-NfQ4gyz38SL8sDNrSixxU2Os1a5xcdFxipAFxYEuLUlvU2uDwS4NUpsImcf1//SlWItCVMMLiylsxbmNMToV/g==} - cbor@8.1.0: - resolution: {integrity: sha512-DwGjNW9omn6EwP70aXsn7FQJx5kO12tX0bZkaTjzdVFM6/7nhA4t0EENocKGx6D2Bch9PE2KzCUf5SceBdeijg==} - engines: {node: '>=12.19'} + '@types/unist@3.0.2': + resolution: {integrity: sha512-dqId9J8K/vGi5Zr7oo212BGii5m3q5Hxlkwy3WpYuKPklmBEvsbMYYyLxAQpSffdLl/gdW0XUpKWFvYmyoWCoQ==} - cbor@9.0.2: - resolution: {integrity: sha512-JPypkxsB10s9QOWwa6zwPzqE1Md3vqpPc+cai4sAecuCsRyAtAl/pMyhPlMbT/xtPnm2dznJZYRLui57qiRhaQ==} - engines: {node: '>=16'} + '@types/use-sync-external-store@0.0.6': + resolution: {integrity: sha512-zFDAD+tlpf2r4asuHEj0XH6pY6i0g5NeAHPn+15wk3BV6JA69eERFXC1gyGThDkVa1zCyKr5jox1+2LbV/AMLg==} + + '@types/web-bluetooth@0.0.20': + resolution: {integrity: sha512-g9gZnnXVq7gM7v3tJCWV/qw7w+KeOlSHAhgF9RytFyifW6AF61hdT2ucrYhPq9hLs5JIryeupHV3qGk95dH9ow==} + + '@types/whatwg-mimetype@3.0.2': + resolution: {integrity: sha512-c2AKvDT8ToxLIOUlN51gTiHXflsfIFisS4pO7pDPoKouJCESkhZnEy623gwP9laCy5lnLDAw1vAzu2vM2YLOrA==} + + '@types/wrap-ansi@3.0.0': + resolution: {integrity: sha512-ltIpx+kM7g/MLRZfkbL7EsCEjfzCcScLpkg37eXEtx5kmrAKBkTJwd1GIAjDSL8wTpM6Hzn5YO4pSb91BEwu1g==} + + '@types/ws@8.5.10': + resolution: {integrity: sha512-vmQSUcfalpIq0R9q7uTo2lXs6eGIpt9wtnLdMv9LVpIjCA/+ufZRozlVoVelIYixx1ugCBKDhn89vnsEGOCx9A==} - chai-as-promised@7.1.2: - resolution: {integrity: sha512-aBDHZxRzYnUYuIAIPBH2s511DjlKPzXNlXSGFC8CwmroWQLfrW0LtE1nK3MAwwNhJPa9raEjNCmRoFpG0Hurdw==} + '@typescript/vfs@1.6.0': + resolution: {integrity: sha512-hvJUjNVeBMp77qPINuUvYXj4FyWeeMMKZkxEATEU3hqBAQ7qdTBCUFT7Sp0Zu0faeEtFf+ldXxMEDr/bk73ISg==} peerDependencies: - chai: '>= 2.1.2 < 6' + typescript: '*' - chai-bignumber@3.1.0: - resolution: {integrity: sha512-omxEc80jAU+pZwRmoWr3aEzeLad4JW3iBhLRQlgISvghBdIxrMT7mVAGsDz4WSyCkKowENshH2j9OABAhld7QQ==} + '@ungap/structured-clone@1.2.0': + resolution: {integrity: sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==} - chai-shallow-deep-equal@1.4.6: - resolution: {integrity: sha512-2fBsQVRwrHdNO7IPYmoeH/V9+tuBDDg3k054NKdZ7tWeoi0URPzt8P+LNqcJioLVBTH/WiNM6a8CT5nWMebhPg==} - engines: {node: '>= 0.6.0'} + '@unhead/vue@2.1.1': + resolution: {integrity: sha512-WYa8ORhfv7lWDSoNpkMKhbW1Dbsux/3HqMcVkZS3xZ2/c/VrcChLj+IMadpCd1WNR0srITfRJhBYZ1i9hON5Qw==} peerDependencies: - chai: '>= 1.9.0' + vue: '>=3.5.18' - chai-string@1.6.0: - resolution: {integrity: sha512-sXV7whDmpax+8H++YaZelgin7aur1LGf9ZhjZa3ojETFJ0uPVuS4XEXuIagpZ/c8uVOtsSh4MwOjy5CBLjJSXA==} + '@unocss/astro@0.59.4': + resolution: {integrity: sha512-DU3OR5MMR1Uvvec4/wB9EetDASHRg19Moy6z/MiIhn8JWJ0QzWYgSeJcfUX8exomMYv6WUEQJL+CyLI34Wmn8w==} peerDependencies: - chai: ^4.1.2 + vite: ^2.9.0 || ^3.0.0-0 || ^4.0.0 || ^5.0.0-0 + peerDependenciesMeta: + vite: + optional: true - chai@4.5.0: - resolution: {integrity: sha512-RITGBfijLkBddZvnn8jdqoTypxvqbOLYQkGGxXzeFjVHvudaPw0HNFD9x928/eUwYWd2dPCugVqspGALTZZQKw==} - engines: {node: '>=4'} + '@unocss/cli@0.59.4': + resolution: {integrity: sha512-TT+WKedSifhsRqnpoYD2LfyYipVzEbzIU4DDGIaDNeDxGXYOGpb876zzkPDcvZSpI37IJ/efkkV7PGYpPBcQBQ==} + engines: {node: '>=14'} + hasBin: true - chai@6.2.2: - resolution: {integrity: sha512-NUPRluOfOiTKBKvWPtSD4PhFvWCqOi0BGStNWs57X9js7XGTprSmFoz5F0tWhR4WPjNeR9jXqdC7/UpSJTnlRg==} - engines: {node: '>=18'} + '@unocss/config@0.59.4': + resolution: {integrity: sha512-h3yhj+D5Ygn5R7gbK4wMrtXZX6FF5DF6YD517sSSb0XB3lxHD9PhhT4HaV1hpHknvu0cMFU3460M45+TN1TI0Q==} + engines: {node: '>=14'} - chalk@2.4.2: - resolution: {integrity: sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==} - engines: {node: '>=4'} + '@unocss/core@0.59.4': + resolution: {integrity: sha512-bBZ1sgcAtezQVZ1BST9IS3jqcsTLyqKNjiIf7FTnX3DHpfpYuMDFzSOtmkZDzBleOLO/CtcRWjT0HwTSQAmV0A==} - chalk@3.0.0: - resolution: {integrity: sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==} - engines: {node: '>=8'} + '@unocss/extractor-arbitrary-variants@0.59.4': + resolution: {integrity: sha512-RDe4FgMGJQ+tp9GLvhPHni7Cc2O0lHBRMElVlN8LoXJAdODMICdbrEPGJlEfrc+7x/QgVFoR895KpYJh3hIgGA==} - chalk@4.1.2: - resolution: {integrity: sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==} - engines: {node: '>=10'} + '@unocss/inspector@0.59.4': + resolution: {integrity: sha512-QczJFNDiggmekkJyNcbcZIUVwlhvxz7ZwjnSf0w7K4znxfjKkZ1hNUbqLviM1HumkTKOdT27VISW7saN/ysO4w==} - chalk@5.6.2: - resolution: {integrity: sha512-7NzBL0rN6fMUW+f7A6Io4h40qQlG+xGmtMxfbnH/K7TAtt8JQWVQK+6g0UXKMeVJoyV5EkkNsErQ8pVD3bLHbA==} - engines: {node: ^12.17.0 || ^14.13 || >=16.0.0} + '@unocss/postcss@0.59.4': + resolution: {integrity: sha512-KVz+AD7McHKp7VEWHbFahhyyVEo0oP/e1vnuNSuPlHthe+1V2zfH6lps+iJcvfL2072r5J+0PvD/1kOp5ryUSg==} + engines: {node: '>=14'} - change-case@3.1.0: - resolution: {integrity: sha512-2AZp7uJZbYEzRPsFoa+ijKdvp9zsrnnt6+yFokfwEpeJm0xuJDVoxiRCAaTzyJND8GJkofo2IcKWaUZ/OECVzw==} + '@unocss/preset-attributify@0.59.4': + resolution: {integrity: sha512-BeogWuYaIakC1gmOZFFCjFVWmu/m3AqEX8UYQS6tY6lAaK2L4Qf4AstYBlT2zAMxy9LNxPDxFQrvfSfFk5Klsg==} - chardet@0.7.0: - resolution: {integrity: sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==} + '@unocss/preset-icons@0.59.4': + resolution: {integrity: sha512-Afjwh5oC4KRE8TNZDUkRK6hvvV1wKLrS1e5trniE0B0AM9HK3PBolQaIU7QmzPv6WQrog+MZgIwafg1eqsPUCA==} - chardet@2.1.1: - resolution: {integrity: sha512-PsezH1rqdV9VvyNhxxOW32/d75r01NY7TQCmOqomRo15ZSOKbpTFVsfjghxo6JloQUCGnH4k1LGu0R4yCLlWQQ==} + '@unocss/preset-mini@0.59.4': + resolution: {integrity: sha512-ZLywGrXi1OCr4My5vX2rLUb5Xgx6ufR9WTQOvpQJGBdIV/jnZn/pyE5avCs476SnOq2K172lnd8mFmTK7/zArA==} - charenc@0.0.2: - resolution: {integrity: sha512-yrLQ/yVUFXkzg7EDQsPieE/53+0RlaWTs+wBrvW36cyilJ2SaDWfl4Yj7MtLTXleV9uEKefbAGUPv2/iWSooRA==} + '@unocss/preset-tagify@0.59.4': + resolution: {integrity: sha512-vWMdTUoghOSmTbdmZtERssffmdUdOuhh4vUdl0R8Kv6KxB0PkvEFCu2FItn97nRJdSPlZSFxxDkaOIg9w+STNQ==} - check-error@1.0.3: - resolution: {integrity: sha512-iKEoDYaRmd1mxM90a2OEfWhjsjPpYPuQ+lMYsoxB126+t8fw7ySEO48nmDg5COTjxDI65/Y2OWpeEHk3ZOe8zg==} + '@unocss/preset-typography@0.59.4': + resolution: {integrity: sha512-ZX9bxZUqlXK1qEDzO5lkK96ICt9itR/oNyn/7mMc1JPqwj263LumQMn5silocgzoLSUXEeq//L6GylqYjkL8GA==} - checkpoint-store@1.1.0: - resolution: {integrity: sha512-J/NdY2WvIx654cc6LWSq/IYFFCUf75fFTgwzFnmbqyORH4MwgiQCgswLLKBGzmsyTI5V7i5bp/So6sMbDWhedg==} + '@unocss/preset-uno@0.59.4': + resolution: {integrity: sha512-G1f8ZluplvXZ3bERj+sM/8zzY//XD++nNOlAQNKOANSVht3qEoJebrfEiMClNpA5qW5VWOZhEhPkh0M7GsXtnA==} - child_process@1.0.2: - resolution: {integrity: sha512-Wmza/JzL0SiWz7kl6MhIKT5ceIlnFPJX+lwUGj7Clhy5MMldsSoJR0+uvRzOS5Kv45Mq7t1PoE8TsOA9bzvb6g==} + '@unocss/preset-web-fonts@0.59.4': + resolution: {integrity: sha512-ehutTjKHnf2KPmdatN42N9a8+y+glKSU3UlcBRNsVIIXVIlaBQuPVGZSPhnMtrKD17IgWylXq2K6RJK+ab0hZA==} - chokidar@3.6.0: - resolution: {integrity: sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==} - engines: {node: '>= 8.10.0'} + '@unocss/preset-wind@0.59.4': + resolution: {integrity: sha512-CNX6w0ZpSQg/i1oF0/WKWzto8PtLqoknC5h8JmmcGb7VsyBQeV0oNnhbURxpbuMEhbv1MWVIGvk8a+P6y0rFkQ==} - chokidar@4.0.3: - resolution: {integrity: sha512-Qgzu8kfBvo+cA4962jnP1KkS6Dop5NS6g7R5LFYJr4b8Ub94PPQXUksCw9PvXoeXPRRddRNC5C1JQUR2SMGtnA==} - engines: {node: '>= 14.16.0'} + '@unocss/reset@0.59.4': + resolution: {integrity: sha512-Upy4xzdWl4RChbLAXBq1BoR4WqxXMoIfjvtcwSZcZK2sylXCFAseSWnyzJFdSiXPqNfmMuNgPXgiSxiQB+cmNA==} - chownr@3.0.0: - resolution: {integrity: sha512-+IxzY9BZOQd/XuYPRmrvEVjF/nqj5kgT4kEq7VofrDoM1MxoRjEWkrCC3EtLi59TVawxTAn+orJwFQcrqEN1+g==} - engines: {node: '>=18'} + '@unocss/rule-utils@0.59.4': + resolution: {integrity: sha512-1qoLJlBWAkS4D4sg73990S1MT7E8E5md/YhopKjTQuEC9SyeVmEg+5pR/Xd8xhPKMqbcuBPl/DS8b6l/GQO56A==} + engines: {node: '>=14'} - ci-info@2.0.0: - resolution: {integrity: sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ==} + '@unocss/scope@0.59.4': + resolution: {integrity: sha512-wBQJ39kw4Tfj4km7AoGvSIobPKVnRZVsgc0bema5Y0PL3g1NeVQ/LopBI2zEJWdpxGXUWxSDsXm7BZo6qVlD/A==} - cids@0.7.5: - resolution: {integrity: sha512-zT7mPeghoWAu+ppn8+BS1tQ5qGmbMfB4AregnQjA/qHY3GC1m1ptI9GkWNlgeu38r7CuRdXB47uY2XgAYt6QVA==} - engines: {node: '>=4.0.0', npm: '>=3.0.0'} - deprecated: This module has been superseded by the multiformats module + '@unocss/transformer-attributify-jsx-babel@0.59.4': + resolution: {integrity: sha512-xtCRSgeTaDBiNJLVX7oOSFe63JiFB5nrdK23PHn3IlZM9O7Bxx4ZxI3MQJtFZFQNE+INFko+DVyY1WiFEm1p/Q==} - cipher-base@1.0.7: - resolution: {integrity: sha512-Mz9QMT5fJe7bKI7MH31UilT5cEK5EHHRCccw/YRFsRY47AuNgaV6HY3rscp0/I4Q+tTW/5zoqpSeRRI54TkDWA==} - engines: {node: '>= 0.10'} + '@unocss/transformer-attributify-jsx@0.59.4': + resolution: {integrity: sha512-m4b83utzKMfUQH/45V2QkjJoXd8Tu2pRP1nic91Xf7QRceyKDD+BxoTneo2JNC2K274cQu7HqqotnCm2aFfEGw==} - class-is@1.1.0: - resolution: {integrity: sha512-rhjH9AG1fvabIDoGRVH587413LPjTZgmDF9fOFCbFJQV4yuocX1mHxxvXI4g3cGwbVY9wAYIoKlg1N79frJKQw==} + '@unocss/transformer-compile-class@0.59.4': + resolution: {integrity: sha512-Vgk2OCLPW0pU+Uzr1IgDtHVspSBb+gPrQFkV+5gxHk9ZdKi3oYKxLuufVWYDSwv7o9yfQGbYrMH9YLsjRsnA7Q==} - clean-stack@2.2.0: - resolution: {integrity: sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==} - engines: {node: '>=6'} + '@unocss/transformer-directives@0.59.4': + resolution: {integrity: sha512-nXUTEclUbs0vQ4KfLhKt4J/5SLSEq1az2FNlJmiXMmqmn75X89OrtCu2OJu9sGXhn+YyBApxgcSSdxmtpqMi1Q==} - cli-boxes@2.2.1: - resolution: {integrity: sha512-y4coMcylgSCdVinjiDBuR8PCC2bLjyGTwEmPb9NHR/QaNU6EUOXcTY/s6VjGMD6ENSEaeQYHCY0GNGS5jfMwPw==} - engines: {node: '>=6'} + '@unocss/transformer-variant-group@0.59.4': + resolution: {integrity: sha512-9XLixxn1NRgP62Kj4R/NC/rpqhql5F2s6ulJ8CAMTEbd/NylVhEANluPGDVUGcLJ4cj6E02hFa8C1PLGSm7/xw==} - cli-cursor@3.1.0: - resolution: {integrity: sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==} - engines: {node: '>=8'} + '@unocss/vite@0.59.4': + resolution: {integrity: sha512-q7GN7vkQYn79n7vYIUlaa7gXGwc7pk0Qo3z3ZFwWGE43/DtZnn2Hwl5UjgBAgi9McA+xqHJEHRsJnI7HJPHUYA==} + peerDependencies: + vite: ^2.9.0 || ^3.0.0-0 || ^4.0.0 || ^5.0.0-0 - cli-spinners@2.9.2: - resolution: {integrity: sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg==} - engines: {node: '>=6'} + '@vercel/analytics@1.6.1': + resolution: {integrity: sha512-oH9He/bEM+6oKlv3chWuOOcp8Y6fo6/PSro8hEkgCW3pu9/OiCXiUpRUogDh3Fs3LH2sosDrx8CxeOLBEE+afg==} + peerDependencies: + '@remix-run/react': ^2 + '@sveltejs/kit': ^1 || ^2 + next: '>= 13' + react: ^18 || ^19 || ^19.0.0-rc + svelte: '>= 4' + vue: ^3 + vue-router: ^4 + peerDependenciesMeta: + '@remix-run/react': + optional: true + '@sveltejs/kit': + optional: true + next: + optional: true + react: + optional: true + svelte: + optional: true + vue: + optional: true + vue-router: + optional: true - cli-table3@0.5.1: - resolution: {integrity: sha512-7Qg2Jrep1S/+Q3EceiZtQcDPWxhAvBw+ERf1162v4sikJrvojMHFqXt8QIVha8UlH9rgU0BeWPytZ9/TzYqlUw==} - engines: {node: '>=6'} + '@vercel/backends@0.0.14': + resolution: {integrity: sha512-4a4LQueJCvwqJhz+B9DBlEOZOdyl+BrIMkC1LZC3++YGbEA9KLhcBwS10WF7hndQR1jizpf7klMQbcU2FwaN/g==} - cli-table3@0.6.5: - resolution: {integrity: sha512-+W/5efTR7y5HRD7gACw9yQjqMVvEMLBHmboM/kPWam+H+Hmyrgjh6YncVKK122YZkXrLudzTuAukUw9FnMf7IQ==} - engines: {node: 10.* || >= 12.*} + '@vercel/blob@1.0.2': + resolution: {integrity: sha512-Im/KeFH4oPx7UsM+QiteimnE07bIUD7JK6CBafI9Z0jRFogaialTBMiZj8EKk/30ctUYsrpIIyP9iIY1YxWnUQ==} + engines: {node: '>=16.14'} - cli-width@3.0.0: - resolution: {integrity: sha512-FxqpkPPwu1HjuN93Omfm4h8uIanXofW0RxVEW3k5RKx+mJJYSthzNhp32Kzxxy3YAEZ/Dc/EWN1vZRY0+kOhbw==} - engines: {node: '>= 10'} + '@vercel/build-utils@13.2.2': + resolution: {integrity: sha512-VNGFd/bpjsrpMSHCkRhhcbzdaMJ1tRW9E3BW6uf5SpFB1zn3GUab+aNC6Zq23kHxtNhutjTmttybqWB2hYYTKQ==} - client-only@0.0.1: - resolution: {integrity: sha512-IV3Ou0jSMzZrd3pZ48nLkT9DA7Ag1pnPzaiQhpW7c3RbcqqzvzzVu+L8gfqMp/8IM2MQtSiqaCxrrcfu8I8rMA==} + '@vercel/cervel@0.0.6': + resolution: {integrity: sha512-IW/gXg17sozYYb7O/1ycjUj08c2EOCWaTFULNzPs5K2nZEgd1E6CQNmCcyRjHeVzIl3i40YXzytdhUBp2zH9sQ==} + hasBin: true + peerDependencies: + typescript: ^4.0.0 || ^5.0.0 - cliui@3.2.0: - resolution: {integrity: sha512-0yayqDxWQbqk3ojkYqUKqaAQ6AfNKeKWRNA8kR0WXzAsdHpP4BIaOmMAG87JGuO6qcobyW4GjxHd9PmhEd+T9w==} + '@vercel/detect-agent@1.0.0': + resolution: {integrity: sha512-AIPgNkmtFcDgPCl+xvTT1ga90OL7OTX2RKM4zu0PMpwBthPfN2DpdHy10n3bh8K+CA22GDU0/ncjzprZsrk0sw==} + engines: {node: '>=14'} - cliui@6.0.0: - resolution: {integrity: sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ==} + '@vercel/elysia@0.1.12': + resolution: {integrity: sha512-0+pUbwTP2n6ii2QMafoYhO7F6FcvxYyeKoPmKIeXKCFFRkwI25EJFDOICLviWnZg7ijNJQym/tqQg72eeHb9AQ==} - cliui@7.0.4: - resolution: {integrity: sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==} + '@vercel/error-utils@2.0.3': + resolution: {integrity: sha512-CqC01WZxbLUxoiVdh9B/poPbNpY9U+tO1N9oWHwTl5YAZxcqXmmWJ8KNMFItJCUUWdY3J3xv8LvAuQv2KZ5YdQ==} - cliui@8.0.1: - resolution: {integrity: sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==} - engines: {node: '>=12'} + '@vercel/express@0.1.17': + resolution: {integrity: sha512-FS/uBC6aeJJ3IvbUPiAupcgXkrX//3MVdZ7TsqxM7jPYNoJE1JFoonfZ4zIu9WKP5JdvvtnXzxeRsoSgpEMiCQ==} - cliui@9.0.1: - resolution: {integrity: sha512-k7ndgKhwoQveBL+/1tqGJYNz097I7WOvwbmmU2AR5+magtbjPWQTS1C5vzGkBC8Ym8UWRzfKUzUUqFLypY4Q+w==} - engines: {node: '>=20'} + '@vercel/fastify@0.1.15': + resolution: {integrity: sha512-FVL5pK9MvlT4cxnrJ7ELv1AdERloIGYZbwfbwPMqGasW3nPhoFQfGA8z1XdEvY+NfDJtjAzBfakC91qtDVAUIQ==} - clone-response@1.0.3: - resolution: {integrity: sha512-ROoL94jJH2dUVML2Y/5PEDNaSHgeOdSDicUyS7izcF63G6sTc/FTjLub4b8Il9S8S0beOfYt0TaA5qvFK+w0wA==} + '@vercel/fun@1.2.0': + resolution: {integrity: sha512-WSmS9qe2R+5roucDEwYB3atKhs9sUbkHV3laJGEUoqz25O83jLE/jqg/B/3yTunB0av1xqiCIBFFVKnXsqSc8w==} + engines: {node: '>= 18'} - clone@1.0.4: - resolution: {integrity: sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg==} - engines: {node: '>=0.8'} + '@vercel/gatsby-plugin-vercel-analytics@1.0.11': + resolution: {integrity: sha512-iTEA0vY6RBPuEzkwUTVzSHDATo1aF6bdLLspI68mQ/BTbi5UQEGjpjyzdKOVcSYApDtFU6M6vypZ1t4vIEnHvw==} - clone@2.1.2: - resolution: {integrity: sha512-3Pe/CF1Nn94hyhIYpjtiLhdCoEoz0DqQ+988E9gmeEdQZlojxnOb74wctFyuwWQHzqyf9X7C7MG8juUpqBJT8w==} - engines: {node: '>=0.8'} + '@vercel/gatsby-plugin-vercel-builder@2.0.112': + resolution: {integrity: sha512-35lLBlbXECEAX3BfPNMsT1W1rpz5gARjePjGwiTS/G1T54ptGCiAfxGBqCj0rilAkjhH3L4Oa07FMbkcGExEUQ==} - code-point-at@1.1.0: - resolution: {integrity: sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==} - engines: {node: '>=0.10.0'} + '@vercel/go@3.2.3': + resolution: {integrity: sha512-PErgHlV7cf8hyPq31aRsL4xm5t4rCSO6vN5AQLlAGSy3ctdgqG7sI6hq/CAKo3CfgIhVHUwNYapFJgGJB/s4OA==} - color-convert@1.9.3: - resolution: {integrity: sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==} + '@vercel/h3@0.1.21': + resolution: {integrity: sha512-a87vIJwqfy3M2eUC7dhFS7WbsE6lo9eaQZmyPGVzFgVrMjSMeko/fI/A4AldgEAUp2Jndo5IB+0HA6Gv8TPu9A==} - color-convert@2.0.1: - resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==} - engines: {node: '>=7.0.0'} + '@vercel/hono@0.2.15': + resolution: {integrity: sha512-syASDqf2ssUH92xr2Z0jvoIfmuMibcsYutvL02f6WFrsGyWnmX3JKvsLwieuqRjBBz47/kfArouH7IgLrMcwRw==} - color-name@1.1.3: - resolution: {integrity: sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==} + '@vercel/hydrogen@1.3.2': + resolution: {integrity: sha512-jI83xL0BnTo7XH5F0mDz7wwaio2oVnpzrj/NmT+5XXVozqdYFegY68HF7BQbzMsgZhZ6H1RwKCS1qb28C2RYuw==} - color-name@1.1.4: - resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==} + '@vercel/introspection@0.0.5': + resolution: {integrity: sha512-4v35gsQ7KczLQKXB8XovpPhr3wVT5rpXqK78J5sXpJHSa7LYPO2n4wSCpN+XBQ98Xi56ONZY4VXcBj+kpRxZfg==} - colors@1.4.0: - resolution: {integrity: sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA==} - engines: {node: '>=0.1.90'} + '@vercel/nestjs@0.2.16': + resolution: {integrity: sha512-VIpqtGsKy/TJi8VzUfJq+GB/jZ63MWYhUAOzM5kRU82E0+6PApxf3fj3C9xNg8OpeK5tHjx8QckS3wd4GHV8eg==} - combined-stream@1.0.8: - resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==} - engines: {node: '>= 0.8'} + '@vercel/next@4.15.7': + resolution: {integrity: sha512-h2Knaxq4DK0z1yoHdpDPnTIXZx9TvmJOMHU1A//vjoMO6cgq+Xv/pjTEdSn/OUtftFIwqA+hrd5PpXLyEdW/7Q==} - command-exists@1.2.9: - resolution: {integrity: sha512-LTQ/SGc+s0Xc0Fu5WaKnR0YiygZkm9eKFvyS+fRsU7/ZWFF8ykFM6Pc9aCVf1+xasOOZpO3BAVgVrKvsqKHV7w==} + '@vercel/nft@0.30.4': + resolution: {integrity: sha512-wE6eAGSXScra60N2l6jWvNtVK0m+sh873CpfZW4KI2v8EHuUQp+mSEi4T+IcdPCSEDgCdAS/7bizbhQlkjzrSA==} + engines: {node: '>=18'} + hasBin: true - command-line-args@5.2.1: - resolution: {integrity: sha512-H4UfQhZyakIjC74I9d34fGYDwk3XpSr17QhEd0Q3I9Xq1CETHo4Hcuo87WyWHpAF1aSLjLRf5lD9ZGX2qStUvg==} - engines: {node: '>=4.0.0'} + '@vercel/nft@1.1.1': + resolution: {integrity: sha512-mKMGa7CEUcXU75474kOeqHbtvK1kAcu4wiahhmlUenB5JbTQB8wVlDI8CyHR3rpGo0qlzoRWqcDzI41FUoBJCA==} + engines: {node: '>=20'} + hasBin: true - command-line-usage@6.1.3: - resolution: {integrity: sha512-sH5ZSPr+7UStsloltmDh7Ce5fb8XPlHyoPzTpyyMuYCtervL65+ubVZ6Q61cFtFl62UyJlc8/JwERRbAFPUqgw==} - engines: {node: '>=8.0.0'} + '@vercel/node@5.5.14': + resolution: {integrity: sha512-pEhGm8L1qbefx6P7rjm1F7vrWLN4vB1+UOD1xmWiLvWJSyzUDnk2nelaPPmgLSh6dObUnxucoSnWkoLpmZnL/Q==} - commander@10.0.1: - resolution: {integrity: sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==} - engines: {node: '>=14'} + '@vercel/python@6.1.0': + resolution: {integrity: sha512-I8ddjrpjY0WoJdFpALYqwydj40DM2YRD97798hN0DNnT9fMZtltyJar5mm7lxLWo4evKNqRkqtUeex2t8WxV6w==} - commander@8.3.0: - resolution: {integrity: sha512-OkTL9umf+He2DZkUq8f8J9of7yL6RJKI24dVITBmNfZBmri9zYZQrKkuXiKhyfPSu8tUhnVBB1iKXevvnlR4Ww==} - engines: {node: '>= 12'} + '@vercel/redwood@2.4.5': + resolution: {integrity: sha512-mFFZSFJ2ND3Sym6PDOISyaOChLY1AIXBW5ZQaSiNg/ZqFtcjwY6cYCw8xTvG/ThlAZE0/XqetLWJJqffoW2lxA==} - commander@9.5.0: - resolution: {integrity: sha512-KRs7WVDKg86PWiuAqhDrAQnTXZKraVcCc6vFdL14qrZ/DcWwuRo7VoiYXalXO7S5GKpqYiVEwCbgFDfxNHKJBQ==} - engines: {node: ^12.20.0 || >=14} + '@vercel/remix-builder@5.5.5': + resolution: {integrity: sha512-r1Hrt1UM3+GsQ1bpqEGrM/bU2NzbHk8MjyxwxcvdltWHnHvuQCWxUf79hUGa+vWjYJITit6Bqg/978R9vLr5nQ==} - common-tags@1.8.2: - resolution: {integrity: sha512-gk/Z852D2Wtb//0I+kRFNKKE9dIIVirjoqPoA1wJU+XePVXZfGeBpk45+A1rKO4Q43prqWBNY/MiIeRLbPWUaA==} - engines: {node: '>=4.0.0'} + '@vercel/ruby@2.2.2': + resolution: {integrity: sha512-PgO3kVPPmYw914BQpgi2/NQSgaXe4xoLLdNhYuI7tJxwfZzVfYizNvhjREyoOvn96LeuB4gNS5P7nbeJjHqb/w==} - commondir@1.0.1: - resolution: {integrity: sha512-W9pAhw0ja1Edb5GVdIF1mjZw/ASI0AlShXM83UUGe2DVr5TdAPEA1OA8m/g8zWp9x6On7gqufY+FatDbC3MDQg==} + '@vercel/rust@1.0.3': + resolution: {integrity: sha512-u0kh2ZafuxTelXPRbv2/tR6cC9MBjgRhrzVuKxOZk7GyLnFwNTDuNwoP4iJ03yF1k5GqGYB0v+0Zvty67isAAQ==} - compare-versions@6.1.1: - resolution: {integrity: sha512-4hm4VPpIecmlg59CHXnRDnqGplJFrbLG4aFEl5vl6cK1u76ws3LLvX7ikFnTDl5vo39sjWD6AaDPYodJp/NNHg==} + '@vercel/static-build@2.8.13': + resolution: {integrity: sha512-kppgO752q0ri+UKCFps91gSSwrEyXybqsJWfF/Amtavp0agx378wKHFXi/GhUS8FgidZe4928XFa2/tCjePWlw==} - concat-map@0.0.1: - resolution: {integrity: sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==} + '@vercel/static-config@3.1.2': + resolution: {integrity: sha512-2d+TXr6K30w86a+WbMbGm2W91O0UzO5VeemZYBBUJbCjk/5FLLGIi8aV6RS2+WmaRvtcqNTn2pUA7nCOK3bGcQ==} - concat-stream@1.6.2: - resolution: {integrity: sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw==} - engines: {'0': node >= 0.8} + '@vitejs/plugin-react@4.2.1': + resolution: {integrity: sha512-oojO9IDc4nCUUi8qIR11KoQm0XFFLIwsRBwHRR4d/88IWghn1y6ckz/bJ8GHDCsYEJee8mDzqtJxh15/cisJNQ==} + engines: {node: ^14.18.0 || >=16.0.0} + peerDependencies: + vite: ^4.2.0 || ^5.0.0 - concurrently@7.6.0: - resolution: {integrity: sha512-BKtRgvcJGeZ4XttiDiNcFiRlxoAeZOseqUvyYRUp/Vtd+9p1ULmeoSqGsDA+2ivdeDFpqrJvGvmI+StKfKl5hw==} - engines: {node: ^12.20.0 || ^14.13.0 || >=16.0.0} - hasBin: true + '@vitejs/plugin-vue-jsx@5.1.3': + resolution: {integrity: sha512-I6Zr8cYVr5WHMW5gNOP09DNqW9rgO8RX73Wa6Czgq/0ndpTfJM4vfDChfOT1+3KtdrNqilNBtNlFwVeB02ZzGw==} + engines: {node: ^20.19.0 || >=22.12.0} + peerDependencies: + vite: ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0 + vue: ^3.0.0 - concurrently@9.2.1: - resolution: {integrity: sha512-fsfrO0MxV64Znoy8/l1vVIjjHa29SZyyqPgQBwhiDcaW8wJc2W3XWVOGx4M3oJBnv/zdUZIIp1gDeS98GzP8Ng==} - engines: {node: '>=18'} - hasBin: true + '@vitejs/plugin-vue@5.0.4': + resolution: {integrity: sha512-WS3hevEszI6CEVEx28F8RjTX97k3KsrcY6kvTg7+Whm5y3oYvcqzVeGCU3hxSAn4uY2CLCkeokkGKpoctccilQ==} + engines: {node: ^18.0.0 || >=20.0.0} + peerDependencies: + vite: ^5.0.0 + vue: ^3.2.25 - connect@3.7.0: - resolution: {integrity: sha512-ZqRXc+tZukToSNmh5C2iWMSoV3X1YUcPbqEM4DkEG5tNQXrQUZCNVGGv3IuicnkMtPfGf3Xtp8WCXs295iQ1pQ==} - engines: {node: '>= 0.10.0'} + '@vitejs/plugin-vue@5.1.4': + resolution: {integrity: sha512-N2XSI2n3sQqp5w7Y/AN/L2XDjBIRGqXko+eDp42sydYSBeJuSm5a1sLf8zakmo8u7tA8NmBgoDLA1HeOESjp9A==} + engines: {node: ^18.0.0 || >=20.0.0} + peerDependencies: + vite: ^5.0.0 + vue: ^3.2.25 - constant-case@2.0.0: - resolution: {integrity: sha512-eS0N9WwmjTqrOmR3o83F5vW8Z+9R1HnVz3xmzT2PMFug9ly+Au/fxRWlEBSb6LcZwspSsEn9Xs1uw9YgzAg1EQ==} + '@vitejs/plugin-vue@6.0.3': + resolution: {integrity: sha512-TlGPkLFLVOY3T7fZrwdvKpjprR3s4fxRln0ORDo1VQ7HHyxJwTlrjKU3kpVWTlaAjIEuCTokmjkZnr8Tpc925w==} + engines: {node: ^20.19.0 || >=22.12.0} + peerDependencies: + vite: ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0 + vue: ^3.2.25 - content-disposition@0.5.4: - resolution: {integrity: sha512-FveZTNuGw04cxlAiWbzi6zTAL/lhehaWbTtgluJh4/E95DqMwTmha3KZN1aAWA8cFIhHzMZUvLevkw5Rqk+tSQ==} - engines: {node: '>= 0.6'} + '@vitest/coverage-v8@3.2.4': + resolution: {integrity: sha512-EyF9SXU6kS5Ku/U82E259WSnvg6c8KTjppUncuNdm5QHpe17mwREHnjDzozC8x9MZ0xfBUFSaLkRv4TMA75ALQ==} + peerDependencies: + '@vitest/browser': 3.2.4 + vitest: 3.2.4 + peerDependenciesMeta: + '@vitest/browser': + optional: true - content-hash@2.5.2: - resolution: {integrity: sha512-FvIQKy0S1JaWV10sMsA7TRx8bpU+pqPkhbsfvOJAdjRXvYxEckAwQWGwtRjiaJfh+E0DvcWUGqcdjwMGFjsSdw==} + '@vitest/expect@2.1.9': + resolution: {integrity: sha512-UJCIkTBenHeKT1TTlKMJWy1laZewsRIzYighyYiJKZreqtdxSos/S1t+ktRMQWu2CKqaarrkeszJx1cgC5tGZw==} - content-type@1.0.5: - resolution: {integrity: sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==} - engines: {node: '>= 0.6'} + '@vitest/mocker@2.1.9': + resolution: {integrity: sha512-tVL6uJgoUdi6icpxmdrn5YNo3g3Dxv+IHJBr0GXHaEdTcw3F+cPKnsXFhli6nO+f/6SDKPHEK1UN+k+TQv0Ehg==} + peerDependencies: + msw: ^2.4.9 + vite: ^5.0.0 + peerDependenciesMeta: + msw: + optional: true + vite: + optional: true - convert-source-map@1.9.0: - resolution: {integrity: sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==} + '@vitest/pretty-format@2.1.9': + resolution: {integrity: sha512-KhRIdGV2U9HOUzxfiHmY8IFHTdqtOhIzCpd8WRdJiE7D/HUcZVD0EgQCVjm+Q9gkUXWgBvMmTtZgIG48wq7sOQ==} - convert-source-map@2.0.0: - resolution: {integrity: sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==} + '@vitest/runner@2.1.9': + resolution: {integrity: sha512-ZXSSqTFIrzduD63btIfEyOmNcBmQvgOVsPNPe0jYtESiXkhd8u2erDLnMxmGrDCwHCCHE7hxwRDCT3pt0esT4g==} - cookie-signature@1.0.7: - resolution: {integrity: sha512-NXdYc3dLr47pBkpUCHtKSwIOQXLVn8dZEuywboCOJY/osA0wFSLlSawr3KN8qXJEyX66FcONTH8EIlVuK0yyFA==} + '@vitest/snapshot@2.1.9': + resolution: {integrity: sha512-oBO82rEjsxLNJincVhLhaxxZdEtV0EFHMK5Kmx5sJ6H9L183dHECjiefOAdnqpIgT5eZwT04PoggUnW88vOBNQ==} - cookie@0.7.2: - resolution: {integrity: sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==} - engines: {node: '>= 0.6'} + '@vitest/spy@2.1.9': + resolution: {integrity: sha512-E1B35FwzXXTs9FHNK6bDszs7mtydNi5MIfUWpceJ8Xbfb1gBMscAnwLbEu+B44ed6W3XjL9/ehLPHR1fkf1KLQ==} - cookie@1.1.1: - resolution: {integrity: sha512-ei8Aos7ja0weRpFzJnEA9UHJ/7XQmqglbRwnf2ATjcB9Wq874VKH9kfjjirM6UhU2/E5fFYadylyhFldcqSidQ==} - engines: {node: '>=18'} + '@vitest/utils@2.1.9': + resolution: {integrity: sha512-v0psaMSkNJ3A2NMrUEHFRzJtDPFn+/VWZ5WxImB21T9fjucJRmS7xCS3ppEnARb9y11OAzaD+P2Ps+b+BGX5iQ==} - core-js-pure@3.47.0: - resolution: {integrity: sha512-BcxeDbzUrRnXGYIVAGFtcGQVNpFcUhVjr6W7F8XktvQW2iJP9e66GP6xdKotCRFlrxBvNIBrhwKteRXqMV86Nw==} + '@volar/language-core@2.2.1': + resolution: {integrity: sha512-iHJAZKcYldZgyS8gx6DfIZApViVBeqbf6iPhqoZpG5A6F4zsZiFldKfwaKaBA3/wnOTWE2i8VUbXywI1WywCPg==} - core-js-pure@3.49.0: - resolution: {integrity: sha512-XM4RFka59xATyJv/cS3O3Kml72hQXUeGRuuTmMYFxwzc9/7C8OYTaIR/Ji+Yt8DXzsFLNhat15cE/JP15HrCgw==} + '@volar/language-core@2.4.27': + resolution: {integrity: sha512-DjmjBWZ4tJKxfNC1F6HyYERNHPYS7L7OPFyCrestykNdUZMFYzI9WTyvwPcaNaHlrEUwESHYsfEw3isInncZxQ==} - core-util-is@1.0.2: - resolution: {integrity: sha512-3lqz5YjWTYnW6dlDa5TLaTCcShfar1e40rmcJVwCBJC6mWlFuj0eCHIElmG1g5kyuJ/GD+8Wn4FFCcz4gJPfaQ==} + '@volar/language-core@2.4.8': + resolution: {integrity: sha512-K/GxMOXGq997bO00cdFhTNuR85xPxj0BEEAy+BaqqayTmy9Tmhfgmq2wpJcVspRhcwfgPoE2/mEJa26emUhG/g==} - core-util-is@1.0.3: - resolution: {integrity: sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==} + '@volar/source-map@2.2.1': + resolution: {integrity: sha512-w1Bgpguhbp7YTr7VUFu6gb4iAZjeEPsOX4zpgiuvlldbzvIWDWy4t0jVifsIsxZ99HAu+c3swiME7wt+GeNqhA==} - cors-gate@1.1.3: - resolution: {integrity: sha512-RFqvbbpj02lqKDhqasBEkgzmT3RseCH3DKy5sT2W9S1mhctABKQP3ktKcnKN0h8t4pJ2SneI3hPl3TGNi/VmZA==} + '@volar/source-map@2.4.27': + resolution: {integrity: sha512-ynlcBReMgOZj2i6po+qVswtDUeeBRCTgDurjMGShbm8WYZgJ0PA4RmtebBJ0BCYol1qPv3GQF6jK7C9qoVc7lg==} - cors@2.8.6: - resolution: {integrity: sha512-tJtZBBHA6vjIAaF6EnIaq6laBBP9aq/Y3ouVJjEfoHbRBcHBAHYcMh/w8LDrk2PvIMMq8gmopa5D4V8RmbrxGw==} - engines: {node: '>= 0.10'} + '@volar/source-map@2.4.8': + resolution: {integrity: sha512-jeWJBkC/WivdelMwxKkpFL811uH/jJ1kVxa+c7OvG48DXc3VrP7pplSWPP2W1dLMqBxD+awRlg55FQQfiup4cA==} - cosmiconfig@8.3.6: - resolution: {integrity: sha512-kcZ6+W5QzcJ3P1Mt+83OUv/oHFqZHIx8DuxG6eZ5RGMERoLqp4BuGjhHLYGK+Kf5XVkQvqBSmAy/nGWN3qDgEA==} - engines: {node: '>=14'} + '@volar/typescript@2.2.1': + resolution: {integrity: sha512-Z/tqluR7Hz5/5dCqQp7wo9C/6tSv/IYl+tTzgzUt2NjTq95bKSsuO4E+V06D0c+3aP9x5S9jggLqw451hpnc6Q==} + + '@vue-macros/common@3.0.0-beta.16': + resolution: {integrity: sha512-8O2gWxWFiaoNkk7PGi0+p7NPGe/f8xJ3/INUufvje/RZOs7sJvlI1jnR4lydtRFa/mU0ylMXUXXjSK0fHDEYTA==} + engines: {node: '>=20.18.0'} peerDependencies: - typescript: '>=4.9.5' + vue: ^2.7.0 || ^3.2.25 peerDependenciesMeta: - typescript: + vue: optional: true - crc-32@1.2.2: - resolution: {integrity: sha512-ROmzCKrTnOwybPcJApAA6WBWij23HVfGVNKqqrZpuyZOHqK2CwHSvpGuyt/UNNvaIjEd8X5IFGp4Mh+Ie1IHJQ==} - engines: {node: '>=0.8'} - hasBin: true + '@vue/babel-helper-vue-transform-on@2.0.1': + resolution: {integrity: sha512-uZ66EaFbnnZSYqYEyplWvn46GhZ1KuYSThdT68p+am7MgBNbQ3hphTL9L+xSIsWkdktwhPYLwPgVWqo96jDdRA==} - create-hash@1.2.0: - resolution: {integrity: sha512-z00bCGNHDG8mHAkP7CtT1qVu+bFQUPjYq/4Iv3C3kWjTFV10zIjfSoeqXo9Asws8gwSHDGj/hl2u4OGIjapeCg==} + '@vue/babel-plugin-jsx@2.0.1': + resolution: {integrity: sha512-a8CaLQjD/s4PVdhrLD/zT574ZNPnZBOY+IhdtKWRB4HRZ0I2tXBi5ne7d9eCfaYwp5gU5+4KIyFTV1W1YL9xZA==} + peerDependencies: + '@babel/core': ^7.0.0-0 + peerDependenciesMeta: + '@babel/core': + optional: true - create-hmac@1.1.7: - resolution: {integrity: sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg==} + '@vue/babel-plugin-resolve-type@2.0.1': + resolution: {integrity: sha512-ybwgIuRGRRBhOU37GImDoWQoz+TlSqap65qVI6iwg/J7FfLTLmMf97TS7xQH9I7Qtr/gp161kYVdhr1ZMraSYQ==} + peerDependencies: + '@babel/core': ^7.0.0-0 - create-require@1.1.1: - resolution: {integrity: sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==} + '@vue/compiler-core@3.4.27': + resolution: {integrity: sha512-E+RyqY24KnyDXsCuQrI+mlcdW3ALND6U7Gqa/+bVwbcpcR3BRRIckFoz7Qyd4TTlnugtwuI7YgjbvsLmxb+yvg==} - cross-fetch@3.2.0: - resolution: {integrity: sha512-Q+xVJLoGOeIMXZmbUK4HYk+69cQH6LudR0Vu/pRm2YlU/hDV9CiS0gKUMaWY5f2NeUH9C1nV3bsTlCo0FsTV1Q==} + '@vue/compiler-core@3.5.12': + resolution: {integrity: sha512-ISyBTRMmMYagUxhcpyEH0hpXRd/KqDU4ymofPgl2XAkY9ZhQ+h0ovEZJIiPop13UmR/54oA2cgMDjgroRelaEw==} - cross-fetch@4.1.0: - resolution: {integrity: sha512-uKm5PU+MHTootlWEY+mZ4vvXoCn4fLQxT9dSc1sXVMSFkINTJVN8cAQROpwcKm8bJ/c7rgZVIBWzH5T78sNZZw==} + '@vue/compiler-core@3.5.26': + resolution: {integrity: sha512-vXyI5GMfuoBCnv5ucIT7jhHKl55Y477yxP6fc4eUswjP8FG3FFVFd41eNDArR+Uk3QKn2Z85NavjaxLxOC19/w==} - cross-spawn@7.0.6: - resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==} - engines: {node: '>= 8'} + '@vue/compiler-dom@3.4.27': + resolution: {integrity: sha512-kUTvochG/oVgE1w5ViSr3KUBh9X7CWirebA3bezTbB5ZKBQZwR2Mwj9uoSKRMFcz4gSMzzLXBPD6KpCLb9nvWw==} - crypt@0.0.2: - resolution: {integrity: sha512-mCxBlsHFYh9C+HVpiEacem8FEBnMXgU9gy4zmNC+SXAZNB/1idgp/aulFJ4FgCi7GPEVbfyng092GqL2k2rmow==} + '@vue/compiler-dom@3.5.12': + resolution: {integrity: sha512-9G6PbJ03uwxLHKQ3P42cMTi85lDRvGLB2rSGOiQqtXELat6uI4n8cNz9yjfVHRPIu+MsK6TE418Giruvgptckg==} - csstype@3.2.3: - resolution: {integrity: sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==} + '@vue/compiler-dom@3.5.26': + resolution: {integrity: sha512-y1Tcd3eXs834QjswshSilCBnKGeQjQXB6PqFn/1nxcQw4pmG42G8lwz+FZPAZAby6gZeHSt/8LMPfZ4Rb+Bd/A==} - d@1.0.2: - resolution: {integrity: sha512-MOqHvMWF9/9MX6nza0KgvFH4HpMU0EF5uUDXqX/BtxtU8NfB0QzRtJ8Oe/6SuS4kbhyzVJwjd97EA4PKrzJ8bw==} - engines: {node: '>=0.12'} + '@vue/compiler-sfc@3.4.27': + resolution: {integrity: sha512-nDwntUEADssW8e0rrmE0+OrONwmRlegDA1pD6QhVeXxjIytV03yDqTey9SBDiALsvAd5U4ZrEKbMyVXhX6mCGA==} - dashdash@1.14.1: - resolution: {integrity: sha512-jRFi8UDGo6j+odZiEpjazZaWqEal3w/basFjQHQEwVtZJGDpxbH1MeYluwCS8Xq5wmLJooDlMgvVarmWfGM44g==} - engines: {node: '>=0.10'} + '@vue/compiler-sfc@3.5.12': + resolution: {integrity: sha512-2k973OGo2JuAa5+ZlekuQJtitI5CgLMOwgl94BzMCsKZCX/xiqzJYzapl4opFogKHqwJk34vfsaKpfEhd1k5nw==} - data-uri-to-buffer@4.0.1: - resolution: {integrity: sha512-0R9ikRb668HB7QDxT1vkpuUBtqc53YyAwMwGeUFKRojY/NWKvdZ+9UYtRfGmhqNbRkTSVpMbmyhXipFFv2cb/A==} - engines: {node: '>= 12'} + '@vue/compiler-sfc@3.5.26': + resolution: {integrity: sha512-egp69qDTSEZcf4bGOSsprUr4xI73wfrY5oRs6GSgXFTiHrWj4Y3X5Ydtip9QMqiCMCPVwLglB9GBxXtTadJ3mA==} - data-uri-to-buffer@6.0.2: - resolution: {integrity: sha512-7hvf7/GW8e86rW0ptuwS3OcBGDjIi6SZva7hCyWC0yYry2cOPmLIjXAUHI6DK2HsnwJd9ifmt57i8eV2n4YNpw==} - engines: {node: '>= 14'} + '@vue/compiler-ssr@3.4.27': + resolution: {integrity: sha512-CVRzSJIltzMG5FcidsW0jKNQnNRYC8bT21VegyMMtHmhW3UOI7knmUehzswXLrExDLE6lQCZdrhD4ogI7c+vuw==} - data-view-buffer@1.0.2: - resolution: {integrity: sha512-EmKO5V3OLXh1rtK2wgXRansaK1/mtVdTUEiEI0W8RkvgT05kfxaH29PliLnpLP73yYO6142Q72QNa8Wx/A5CqQ==} - engines: {node: '>= 0.4'} + '@vue/compiler-ssr@3.5.12': + resolution: {integrity: sha512-eLwc7v6bfGBSM7wZOGPmRavSWzNFF6+PdRhE+VFJhNCgHiF8AM7ccoqcv5kBXA2eWUfigD7byekvf/JsOfKvPA==} - data-view-byte-length@1.0.2: - resolution: {integrity: sha512-tuhGbE6CfTM9+5ANGf+oQb72Ky/0+s3xKUpHvShfiz2RxMFgFPjsXuRLBVMtvMs15awe45SRb83D6wH4ew6wlQ==} - engines: {node: '>= 0.4'} + '@vue/compiler-ssr@3.5.26': + resolution: {integrity: sha512-lZT9/Y0nSIRUPVvapFJEVDbEXruZh2IYHMk2zTtEgJSlP5gVOqeWXH54xDKAaFS4rTnDeDBQUYDtxKyoW9FwDw==} - data-view-byte-offset@1.0.1: - resolution: {integrity: sha512-BS8PfmtDGnrgYdOonGZQdLZslWIeCGFP9tpan0hi1Co2Zr2NKADsvGYA8XxuG/4UWgJ6Cjtv+YJnB6MM69QGlQ==} - engines: {node: '>= 0.4'} + '@vue/compiler-vue2@2.7.16': + resolution: {integrity: sha512-qYC3Psj9S/mfu9uVi5WvNZIzq+xnXMhOwbTFKKDD7b1lhpnn71jXSFdTQ+WsIEk0ONCd7VV2IMm7ONl6tbQ86A==} - date-fns@2.30.0: - resolution: {integrity: sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw==} - engines: {node: '>=0.11'} + '@vue/devtools-api@6.6.1': + resolution: {integrity: sha512-LgPscpE3Vs0x96PzSSB4IGVSZXZBZHpfxs+ZA1d+VEPwHdOXowy/Y2CsvCAIFrf+ssVU1pD1jidj505EpUnfbA==} - death@1.1.0: - resolution: {integrity: sha512-vsV6S4KVHvTGxbEcij7hkWRv0It+sGGWVOM67dQde/o5Xjnr+KmLjxWJii2uEObIrt1CcM9w0Yaovx+iOlIL+w==} + '@vue/devtools-api@6.6.4': + resolution: {integrity: sha512-sGhTPMuXqZ1rVOk32RylztWkfXTRhuS7vgAKv0zjqk8gbsHkJ7xfFf+jbySxt7tWObEJwyKaHMikV/WGDiQm8g==} - debug@2.6.9: - resolution: {integrity: sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==} + '@vue/devtools-api@7.6.2': + resolution: {integrity: sha512-NCT0ujqlwAhoFvCsAG7G5qS8w/A/dhvFSt2BhmNxyqgpYDrf9CG1zYyWLQkE3dsZ+5lCT6ULUic2VKNaE07Vzg==} + + '@vue/devtools-core@7.7.9': + resolution: {integrity: sha512-48jrBSwG4GVQRvVeeXn9p9+dlx+ISgasM7SxZZKczseohB0cBz+ITKr4YbLWjmJdy45UHL7UMPlR4Y0CWTRcSQ==} peerDependencies: - supports-color: '*' - peerDependenciesMeta: - supports-color: - optional: true + vue: ^3.0.0 + + '@vue/devtools-kit@7.6.2': + resolution: {integrity: sha512-k61BxHRmcTtIQZFouF9QWt9nCCNtSdw12lhg8VNtHq5/XOBGD+ewiK27a40UJ8UPYoCJvi80hbvbYr5E/Zeu1g==} - debug@3.2.7: - resolution: {integrity: sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==} + '@vue/devtools-kit@7.7.9': + resolution: {integrity: sha512-PyQ6odHSgiDVd4hnTP+aDk2X4gl2HmLDfiyEnn3/oV+ckFDuswRs4IbBT7vacMuGdwY/XemxBoh302ctbsptuA==} + + '@vue/devtools-shared@7.6.2': + resolution: {integrity: sha512-lcjyJ7hCC0W0kNwnCGMLVTMvDLoZgjcq9BvboPgS+6jQyDul7fpzRSKTGtGhCHoxrDox7qBAKGbAl2Rcf7GE1A==} + + '@vue/devtools-shared@7.7.9': + resolution: {integrity: sha512-iWAb0v2WYf0QWmxCGy0seZNDPdO3Sp5+u78ORnyeonS6MT4PC7VPrryX2BpMJrwlDeaZ6BD4vP4XKjK0SZqaeA==} + + '@vue/language-core@2.0.16': + resolution: {integrity: sha512-Bc2sexRH99pznOph8mLw2BlRZ9edm7tW51kcBXgx8adAoOcZUWJj3UNSsdQ6H9Y8meGz7BoazVrVo/jUukIsPw==} peerDependencies: - supports-color: '*' + typescript: '*' peerDependenciesMeta: - supports-color: + typescript: optional: true - debug@4.4.3: - resolution: {integrity: sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==} - engines: {node: '>=6.0'} + '@vue/language-core@2.1.10': + resolution: {integrity: sha512-DAI289d0K3AB5TUG3xDp9OuQ71CnrujQwJrQnfuZDwo6eGNf0UoRlPuaVNO+Zrn65PC3j0oB2i7mNmVPggeGeQ==} peerDependencies: - supports-color: '*' + typescript: '*' peerDependenciesMeta: - supports-color: + typescript: optional: true - decamelize@1.2.0: - resolution: {integrity: sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==} - engines: {node: '>=0.10.0'} + '@vue/language-core@3.2.1': + resolution: {integrity: sha512-g6oSenpnGMtpxHGAwKuu7HJJkNZpemK/zg3vZzZbJ6cnnXq1ssxuNrXSsAHYM3NvH8p4IkTw+NLmuxyeYz4r8A==} - decamelize@4.0.0: - resolution: {integrity: sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ==} - engines: {node: '>=10'} + '@vue/reactivity@3.4.27': + resolution: {integrity: sha512-kK0g4NknW6JX2yySLpsm2jlunZJl2/RJGZ0H9ddHdfBVHcNzxmQ0sS0b09ipmBoQpY8JM2KmUw+a6sO8Zo+zIA==} - decode-uri-component@0.2.2: - resolution: {integrity: sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ==} - engines: {node: '>=0.10'} + '@vue/reactivity@3.5.12': + resolution: {integrity: sha512-UzaN3Da7xnJXdz4Okb/BGbAaomRHc3RdoWqTzlvd9+WBR5m3J39J1fGcHes7U3za0ruYn/iYy/a1euhMEHvTAg==} - decompress-response@3.3.0: - resolution: {integrity: sha512-BzRPQuY1ip+qDonAOz42gRm/pg9F768C+npV/4JOsxRC2sq+Rlk+Q4ZCAsOhnIaMrgarILY+RMUIvMmmX1qAEA==} - engines: {node: '>=4'} + '@vue/reactivity@3.5.26': + resolution: {integrity: sha512-9EnYB1/DIiUYYnzlnUBgwU32NNvLp/nhxLXeWRhHUEeWNTn1ECxX8aGO7RTXeX6PPcxe3LLuNBFoJbV4QZ+CFQ==} - decompress-response@6.0.0: - resolution: {integrity: sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==} - engines: {node: '>=10'} + '@vue/runtime-core@3.4.27': + resolution: {integrity: sha512-7aYA9GEbOOdviqVvcuweTLe5Za4qBZkUY7SvET6vE8kyypxVgaT1ixHLg4urtOlrApdgcdgHoTZCUuTGap/5WA==} - deep-eql@4.1.4: - resolution: {integrity: sha512-SUwdGfqdKOwxCPeVYjwSyRpJ7Z+fhpwIAtmCUdZIWZ/YP5R9WAsyuSgpLVDi9bjWoN2LXHNss/dk3urXtdQxGg==} - engines: {node: '>=6'} + '@vue/runtime-core@3.5.12': + resolution: {integrity: sha512-hrMUYV6tpocr3TL3Ad8DqxOdpDe4zuQY4HPY3X/VRh+L2myQO8MFXPAMarIOSGNu0bFAjh1yBkMPXZBqCk62Uw==} - deep-extend@0.6.0: - resolution: {integrity: sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==} - engines: {node: '>=4.0.0'} + '@vue/runtime-core@3.5.26': + resolution: {integrity: sha512-xJWM9KH1kd201w5DvMDOwDHYhrdPTrAatn56oB/LRG4plEQeZRQLw0Bpwih9KYoqmzaxF0OKSn6swzYi84e1/Q==} - deep-is@0.1.4: - resolution: {integrity: sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==} + '@vue/runtime-dom@3.4.27': + resolution: {integrity: sha512-ScOmP70/3NPM+TW9hvVAz6VWWtZJqkbdf7w6ySsws+EsqtHvkhxaWLecrTorFxsawelM5Ys9FnDEMt6BPBDS0Q==} - default-require-extensions@3.0.1: - resolution: {integrity: sha512-eXTJmRbm2TIt9MgWTsOH1wEuhew6XGZcMeGKCtLedIg/NCsg1iBePXkceTdK4Fii7pzmN9tGsZhKzZ4h7O/fxw==} - engines: {node: '>=8'} + '@vue/runtime-dom@3.5.12': + resolution: {integrity: sha512-q8VFxR9A2MRfBr6/55Q3umyoN7ya836FzRXajPB6/Vvuv0zOPL+qltd9rIMzG/DbRLAIlREmnLsplEF/kotXKA==} - defaults@1.0.4: - resolution: {integrity: sha512-eFuaLoy/Rxalv2kr+lqMlUnrDWV+3j4pljOIJgLIhI058IQfWJ7vXhyEIHu+HtC738klGALYxOKDO0bQP3tg8A==} + '@vue/runtime-dom@3.5.26': + resolution: {integrity: sha512-XLLd/+4sPC2ZkN/6+V4O4gjJu6kSDbHAChvsyWgm1oGbdSO3efvGYnm25yCjtFm/K7rrSDvSfPDgN1pHgS4VNQ==} - defer-to-connect@2.0.1: - resolution: {integrity: sha512-4tvttepXG1VaYGrRibk5EwJd1t4udunSOVMdLSAL6mId1ix438oPwPZMALY41FCijukO1L0twNcGsdzS7dHgDg==} - engines: {node: '>=10'} + '@vue/server-renderer@3.4.27': + resolution: {integrity: sha512-dlAMEuvmeA3rJsOMJ2J1kXU7o7pOxgsNHVr9K8hB3ImIkSuBrIdy0vF66h8gf8Tuinf1TK3mPAz2+2sqyf3KzA==} + peerDependencies: + vue: 3.4.27 - deferred-leveldown@1.2.2: - resolution: {integrity: sha512-uukrWD2bguRtXilKt6cAWKyoXrTSMo5m7crUdLfWQmu8kIm88w3QZoUL+6nhpfKVmhHANER6Re3sKoNoZ3IKMA==} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + '@vue/server-renderer@3.5.12': + resolution: {integrity: sha512-I3QoeDDeEPZm8yR28JtY+rk880Oqmj43hreIBVTicisFTx/Dl7JpG72g/X7YF8hnQD3IFhkky5i2bPonwrTVPg==} + peerDependencies: + vue: 3.5.12 - deferred-leveldown@5.3.0: - resolution: {integrity: sha512-a59VOT+oDy7vtAbLRCZwWgxu2BaCfd5Hk7wxJd48ei7I+nsg8Orlb9CLG0PMZienk9BSUKgeAqkO2+Lw+1+Ukw==} - engines: {node: '>=6'} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + '@vue/server-renderer@3.5.26': + resolution: {integrity: sha512-TYKLXmrwWKSodyVuO1WAubucd+1XlLg4set0YoV+Hu8Lo79mp/YMwWV5mC5FgtsDxX3qo1ONrxFaTP1OQgy1uA==} + peerDependencies: + vue: 3.5.26 - define-data-property@1.1.4: - resolution: {integrity: sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==} - engines: {node: '>= 0.4'} + '@vue/shared@3.4.27': + resolution: {integrity: sha512-DL3NmY2OFlqmYYrzp39yi3LDkKxa5vZVwxWdQ3rG0ekuWscHraeIbnI8t+aZK7qhYqEqWKTUdijadunb9pnrgA==} - define-lazy-prop@2.0.0: - resolution: {integrity: sha512-Ds09qNh8yw3khSjiJjiUInaGX9xlqZDY7JVryGxdxV7NPeuqQfplOpQ66yJFZut3jLa5zOwkXw1g9EI2uKh4Og==} - engines: {node: '>=8'} + '@vue/shared@3.5.12': + resolution: {integrity: sha512-L2RPSAwUFbgZH20etwrXyVyCBu9OxRSi8T/38QsvnkJyvq2LufW2lDCOzm7t/U9C1mkhJGWYfCuFBCmIuNivrg==} - define-properties@1.2.1: - resolution: {integrity: sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==} - engines: {node: '>= 0.4'} + '@vue/shared@3.5.26': + resolution: {integrity: sha512-7Z6/y3uFI5PRoKeorTOSXKcDj0MSasfNNltcslbFrPpcw6aXRUALq4IfJlaTRspiWIUOEZbrpM+iQGmCOiWe4A==} - degenerator@5.0.1: - resolution: {integrity: sha512-TllpMR/t0M5sqCXfj85i4XaAzxmS5tVA16dqvdkMwGmzI+dXLXnw3J+3Vdv7VKw+ThlTMboK6i9rnZ6Nntj5CQ==} - engines: {node: '>= 14'} + '@vue/test-utils@2.4.6': + resolution: {integrity: sha512-FMxEjOpYNYiFe0GkaHsnJPXFHxQ6m4t8vI/ElPGpMWxZKpmRvQ33OIrvRXemy6yha03RxhOlQuy+gZMC3CQSow==} - del@5.1.0: - resolution: {integrity: sha512-wH9xOVHnczo9jN2IW68BabcecVPxacIA3g/7z6vhSU/4stOKQzeCRK0yD0A24WiAAUJmmVpWqrERcTxnLo3AnA==} - engines: {node: '>=8'} + '@vueuse/core@11.2.0': + resolution: {integrity: sha512-JIUwRcOqOWzcdu1dGlfW04kaJhW3EXnnjJJfLTtddJanymTL7lF1C0+dVVZ/siLfc73mWn+cGP1PE1PKPruRSA==} - delayed-stream@1.0.0: - resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==} - engines: {node: '>=0.4.0'} + '@vueuse/integrations@11.2.0': + resolution: {integrity: sha512-zGXz3dsxNHKwiD9jPMvR3DAxQEOV6VWIEYTGVSB9PNpk4pTWR+pXrHz9gvXWcP2sTk3W2oqqS6KwWDdntUvNVA==} + peerDependencies: + async-validator: ^4 + axios: ^1 + change-case: ^5 + drauu: ^0.4 + focus-trap: ^7 + fuse.js: ^7 + idb-keyval: ^6 + jwt-decode: ^4 + nprogress: ^0.2 + qrcode: ^1.5 + sortablejs: ^1 + universal-cookie: ^7 + peerDependenciesMeta: + async-validator: + optional: true + axios: + optional: true + change-case: + optional: true + drauu: + optional: true + focus-trap: + optional: true + fuse.js: + optional: true + idb-keyval: + optional: true + jwt-decode: + optional: true + nprogress: + optional: true + qrcode: + optional: true + sortablejs: + optional: true + universal-cookie: + optional: true - depd@2.0.0: - resolution: {integrity: sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==} - engines: {node: '>= 0.8'} + '@vueuse/metadata@11.2.0': + resolution: {integrity: sha512-L0ZmtRmNx+ZW95DmrgD6vn484gSpVeRbgpWevFKXwqqQxW9hnSi2Ppuh2BzMjnbv4aJRiIw8tQatXT9uOB23dQ==} - destroy@1.2.0: - resolution: {integrity: sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg==} - engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16} - - destroyable-server@1.1.1: - resolution: {integrity: sha512-7tjgU/99QVuYSqkMXr6XdQSvXj+8TjC9NiRVWNSyGytxklZ88m+qcSvWTJ3VysE3I9wurph7dTciLEEj8aUlaQ==} - engines: {node: '>=12.0.0'} + '@vueuse/shared@11.2.0': + resolution: {integrity: sha512-VxFjie0EanOudYSgMErxXfq6fo8vhr5ICI+BuE3I9FnX7ePllEsVrRQ7O6Q1TLgApeLuPKcHQxAXpP+KnlrJsg==} - detect-indent@6.1.0: - resolution: {integrity: sha512-reYkTUJAZb9gUuZ2RvVCNhVHdg62RHnJ7WJl8ftMi4diZ6NWlciOzQN88pUhSELEwflJht4oQDv0F0BMlwaYtA==} - engines: {node: '>=8'} + '@walletconnect/core@2.19.2': + resolution: {integrity: sha512-iu0mgLj51AXcKpdNj8+4EdNNBd/mkNjLEhZn6UMc/r7BM9WbmpPMEydA39WeRLbdLO4kbpmq4wTbiskI1rg+HA==} + engines: {node: '>=18'} - detect-libc@2.1.2: - resolution: {integrity: sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==} - engines: {node: '>=8'} + '@walletconnect/core@2.20.2': + resolution: {integrity: sha512-48XnarxQQrpJ0KZJOjit56DxuzfVRYUdL8XVMvUh/ZNUiX2FB5w6YuljUUeTLfYOf04Et6qhVGEUkmX3W+9/8w==} + engines: {node: '>=18'} - diff@5.2.2: - resolution: {integrity: sha512-vtcDfH3TOjP8UekytvnHH1o1P4FcUdt4eQ1Y+Abap1tk/OB2MWQvcwS2ClCd1zuIhc3JKOx6p3kod8Vfys3E+A==} - engines: {node: '>=0.3.1'} + '@walletconnect/environment@1.0.1': + resolution: {integrity: sha512-T426LLZtHj8e8rYnKfzsw1aG6+M0BT1ZxayMdv/p8yM0MU+eJDISqNY3/bccxRr4LrF9csq02Rhqt08Ibl0VRg==} - diff@9.0.0: - resolution: {integrity: sha512-svtcdpS8CgJyqAjEQIXdb3OjhFVVYjzGAPO8WGCmRbrml64SPw/jJD4GoE98aR7r25A0XcgrK3F02yw9R/vhQw==} - engines: {node: '>=0.3.1'} + '@walletconnect/ethereum-provider@2.20.2': + resolution: {integrity: sha512-fGNJtytHuBWZcmMXRIG1djlfEiPMvPJ0R3JlfJjAx2VfVN+O+1xdF6QSWcZxFizviIUFJV+f1zWt0V2VVD61Rg==} + deprecated: 'Reliability and performance improvements. See: https://github.com/WalletConnect/walletconnect-monorepo/releases' - difflib@0.2.4: - resolution: {integrity: sha512-9YVwmMb0wQHQNr5J9m6BSj6fk4pfGITGQOOs+D9Fl+INODWFOfvhIU1hNv6GgR1RBoC/9NJcwu77zShxV0kT7w==} + '@walletconnect/events@1.0.1': + resolution: {integrity: sha512-NPTqaoi0oPBVNuLv7qPaJazmGHs5JGyO8eEAk5VGKmJzDR7AHzD4k6ilox5kxk1iwiOnFopBOOMLs86Oa76HpQ==} - dir-glob@3.0.1: - resolution: {integrity: sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==} - engines: {node: '>=8'} + '@walletconnect/heartbeat@1.2.2': + resolution: {integrity: sha512-uASiRmC5MwhuRuf05vq4AT48Pq8RMi876zV8rr8cV969uTOzWdB/k+Lj5yI2PBtB1bGQisGen7MM1GcZlQTBXw==} - doctrine@2.1.0: - resolution: {integrity: sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==} - engines: {node: '>=0.10.0'} + '@walletconnect/jsonrpc-http-connection@1.0.8': + resolution: {integrity: sha512-+B7cRuaxijLeFDJUq5hAzNyef3e3tBDIxyaCNmFtjwnod5AGis3RToNqzFU33vpVcxFhofkpE7Cx+5MYejbMGw==} - dom-walk@0.1.2: - resolution: {integrity: sha512-6QvTW9mrGeIegrFXdtQi9pk7O/nSK6lSdXW2eqUspN5LWD7UTji2Fqw5V2YLjBpHEoU9Xl/eUWNpDeZvoyOv2w==} + '@walletconnect/jsonrpc-provider@1.0.14': + resolution: {integrity: sha512-rtsNY1XqHvWj0EtITNeuf8PHMvlCLiS3EjQL+WOkxEOA4KPxsohFnBDeyPYiNm4ZvkQdLnece36opYidmtbmow==} - domexception@1.0.1: - resolution: {integrity: sha512-raigMkn7CJNNo6Ihro1fzG7wr3fHuYVytzquZKX5n0yizGsTcYgzdIUwj1X9pK0VvjeihV+XiclP+DjwbsSKug==} - deprecated: Use your platform's native DOMException instead + '@walletconnect/jsonrpc-types@1.0.4': + resolution: {integrity: sha512-P6679fG/M+wuWg9TY8mh6xFSdYnFyFjwFelxyISxMDrlbXokorEVXYOxiqEbrU3x1BmBoCAJJ+vtEaEoMlpCBQ==} - dot-case@2.1.1: - resolution: {integrity: sha512-HnM6ZlFqcajLsyudHq7LeeLDr2rFAVYtDv/hV5qchQEidSck8j9OPUsXY9KwJv/lHMtYlX4DjRQqwFYa+0r8Ug==} + '@walletconnect/jsonrpc-utils@1.0.8': + resolution: {integrity: sha512-vdeb03bD8VzJUL6ZtzRYsFMq1eZQcM3EAzT0a3st59dyLfJ0wq+tKMpmGH7HlB7waD858UWgfIcudbPFsbzVdw==} - dotenv@16.0.3: - resolution: {integrity: sha512-7GO6HghkA5fYG9TYnNxi14/7K9f5occMlp3zXAuSxn7CKCxt9xbNWG7yF8hTCSUchlfWSe3uLmlPfigevRItzQ==} - engines: {node: '>=12'} + '@walletconnect/jsonrpc-ws-connection@1.0.16': + resolution: {integrity: sha512-G81JmsMqh5nJheE1mPst1W0WfVv0SG3N7JggwLLGnI7iuDZJq8cRJvQwLGKHn5H1WTW7DEPCo00zz5w62AbL3Q==} - dotenv@16.6.1: - resolution: {integrity: sha512-uBq4egWHTcTt33a72vpSG0z3HnPuIl6NqYcTrKEg2azoEyl2hpW0zqlxysq2pK9HlDIHyHyakeYaYnSAwd8bow==} - engines: {node: '>=12'} + '@walletconnect/keyvaluestorage@1.1.1': + resolution: {integrity: sha512-V7ZQq2+mSxAq7MrRqDxanTzu2RcElfK1PfNYiaVnJgJ7Q7G7hTVwF8voIBx92qsRyGHZihrwNPHuZd1aKkd0rA==} + peerDependencies: + '@react-native-async-storage/async-storage': 1.x + peerDependenciesMeta: + '@react-native-async-storage/async-storage': + optional: true - dotenv@17.3.1: - resolution: {integrity: sha512-IO8C/dzEb6O3F9/twg6ZLXz164a2fhTnEWb95H23Dm4OuN+92NmEAlTrupP9VW6Jm3sO26tQlqyvyi4CsnY9GA==} - engines: {node: '>=12'} + '@walletconnect/logger@2.1.2': + resolution: {integrity: sha512-aAb28I3S6pYXZHQm5ESB+V6rDqIYfsnHaQyzFbwUUBFY4H0OXx/YtTl8lvhUNhMMfb9UxbwEBS253TlXUYJWSw==} - dotenv@8.6.0: - resolution: {integrity: sha512-IrPdXQsk2BbzvCBGBOTmmSH5SodmqZNt4ERAZDmW4CT+tL8VtvinqywuANaFu4bOMWki16nqf0e4oC0QIaDr/g==} - engines: {node: '>=10'} + '@walletconnect/relay-api@1.0.11': + resolution: {integrity: sha512-tLPErkze/HmC9aCmdZOhtVmYZq1wKfWTJtygQHoWtgg722Jd4homo54Cs4ak2RUFUZIGO2RsOpIcWipaua5D5Q==} - dunder-proto@1.0.1: - resolution: {integrity: sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==} - engines: {node: '>= 0.4'} + '@walletconnect/relay-auth@1.1.0': + resolution: {integrity: sha512-qFw+a9uRz26jRCDgL7Q5TA9qYIgcNY8jpJzI1zAWNZ8i7mQjaijRnWFKsCHAU9CyGjvt6RKrRXyFtFOpWTVmCQ==} - duplexify@3.7.1: - resolution: {integrity: sha512-07z8uv2wMyS51kKhD1KsdXJg5WQ6t93RneqRxUHnskXVtlYYkLqM0gqStQZ3pj073g687jPCHrqNfCzawLYh5g==} + '@walletconnect/safe-json@1.0.2': + resolution: {integrity: sha512-Ogb7I27kZ3LPC3ibn8ldyUr5544t3/STow9+lzz7Sfo808YD7SBWk7SAsdBFlYgP2zDRy2hS3sKRcuSRM0OTmA==} - eastasianwidth@0.2.0: - resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==} + '@walletconnect/sign-client@2.19.2': + resolution: {integrity: sha512-a/K5PRIFPCjfHq5xx3WYKHAAF8Ft2I1LtxloyibqiQOoUtNLfKgFB1r8sdMvXM7/PADNPe4iAw4uSE6PrARrfg==} + deprecated: 'Reliability and performance improvements. See: https://github.com/WalletConnect/walletconnect-monorepo/releases' - ecc-jsbn@0.1.2: - resolution: {integrity: sha512-eh9O+hwRHNbG4BLTjEl3nw044CkGm5X6LoaCf7LPp7UU8Qrt47JYNi6nPX8xjW97TKGKm1ouctg0QSpZe9qrnw==} + '@walletconnect/sign-client@2.20.2': + resolution: {integrity: sha512-KyeDToypZ1OjCbij4Jx0cAg46bMwZ6zCKt0HzCkqENcex3Zchs7xBp9r8GtfEMGw+PUnXwqrhzmLBH0x/43oIQ==} + deprecated: 'Reliability and performance improvements. See: https://github.com/WalletConnect/walletconnect-monorepo/releases' - ee-first@1.1.1: - resolution: {integrity: sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==} + '@walletconnect/time@1.0.2': + resolution: {integrity: sha512-uzdd9woDcJ1AaBZRhqy5rNC9laqWGErfc4dxA9a87mPdKOgWMD85mcFo9dIYIts/Jwocfwn07EC6EzclKubk/g==} - electron-to-chromium@1.5.267: - resolution: {integrity: sha512-0Drusm6MVRXSOJpGbaSVgcQsuB4hEkMpHXaVstcPmhu5LIedxs1xNK/nIxmQIU/RPC0+1/o0AVZfBTkTNJOdUw==} + '@walletconnect/types@2.19.2': + resolution: {integrity: sha512-/LZWhkVCUN+fcTgQUxArxhn2R8DF+LSd/6Wh9FnpjeK/Sdupx1EPS8okWG6WPAqq2f404PRoNAfQytQ82Xdl3g==} - electron-to-chromium@1.5.344: - resolution: {integrity: sha512-4MxfbmNDm+KPh066EZy+eUnkcDPcZ35wNmOWzFuh/ijvHsve6kbLTLURy88uCNK5FbpN+yk2nQY6BYh1GEt+wg==} + '@walletconnect/types@2.20.2': + resolution: {integrity: sha512-XPPbJM/mGU05i6jUxhC3yI/YvhSF6TYJQ5SXTWM53lVe6hs6ukvlEhPctu9ZBTGwGFhwPXIjtK/eWx+v4WY5iw==} - elliptic@6.6.1: - resolution: {integrity: sha512-RaddvvMatK2LJHqFJ+YA4WysVN5Ita9E35botqIYspQ4TkRAlCicdzKOjlyv/1Za5RyTNn7di//eEV0uTAfe3g==} + '@walletconnect/universal-provider@2.19.2': + resolution: {integrity: sha512-LkKg+EjcSUpPUhhvRANgkjPL38wJPIWumAYD8OK/g4OFuJ4W3lS/XTCKthABQfFqmiNbNbVllmywiyE44KdpQg==} + deprecated: 'Reliability and performance improvements. See: https://github.com/WalletConnect/walletconnect-monorepo/releases' - emittery@0.10.0: - resolution: {integrity: sha512-AGvFfs+d0JKCJQ4o01ASQLGPmSCxgfU9RFXvzPvZdjKK8oscynksuJhWrSTSw7j7Ep/sZct5b5ZhYCi8S/t0HQ==} - engines: {node: '>=12'} + '@walletconnect/universal-provider@2.20.2': + resolution: {integrity: sha512-6uVu1E88tioaXEEJCbJKwCIQlOHif1nmfY092BznZEnBn2lli5ICzQh2bxtUDNmNNLKsMDI3FV1fODFeWMVJTQ==} + deprecated: 'Reliability and performance improvements. See: https://github.com/WalletConnect/walletconnect-monorepo/releases' - emoji-regex@10.6.0: - resolution: {integrity: sha512-toUI84YS5YmxW219erniWD0CIVOo46xGKColeNQRgOzDorgBi1v4D71/OFzgD9GO2UGKIv1C3Sp8DAn0+j5w7A==} + '@walletconnect/utils@2.19.2': + resolution: {integrity: sha512-VU5CcUF4sZDg8a2/ov29OJzT3KfLuZqJUM0GemW30dlipI5fkpb0VPenZK7TcdLPXc1LN+Q+7eyTqHRoAu/BIA==} - emoji-regex@8.0.0: - resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} + '@walletconnect/utils@2.20.2': + resolution: {integrity: sha512-2uRUDvpYSIJFYcr1WIuiFy6CEszLF030o6W8aDMkGk9/MfAZYEJQHMJcjWyaNMPHLJT0POR5lPaqkYOpuyPIQQ==} - emoji-regex@9.2.2: - resolution: {integrity: sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==} + '@walletconnect/window-getters@1.0.1': + resolution: {integrity: sha512-vHp+HqzGxORPAN8gY03qnbTMnhqIwjeRJNOMOAzePRg4xVEEE2WvYsI9G2NMjOknA8hnuYbU3/hwLcKbjhc8+Q==} - encode-utf8@1.0.3: - resolution: {integrity: sha512-ucAnuBEhUK4boH2HjVYG5Q2mQyPorvv0u/ocS+zhdw0S8AlHYY+GOFhP1Gio5z4icpP2ivFSvhtFjQi8+T9ppw==} + '@walletconnect/window-metadata@1.0.1': + resolution: {integrity: sha512-9koTqyGrM2cqFRW517BPY/iEtUDx2r1+Pwwu5m7sJ7ka79wi3EyqhqcICk/yDmv6jAS1rjKgTKXlEhanYjijcA==} - encodeurl@1.0.2: - resolution: {integrity: sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==} - engines: {node: '>= 0.8'} + abbrev@2.0.0: + resolution: {integrity: sha512-6/mh1E2u2YgEsCHdY0Yx5oW+61gZU+1vXaoiHHrpKeuRNNgFvS+/jrwHiQhB5apAf5oB7UB7E19ol2R2LKH8hQ==} + engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} - encodeurl@2.0.0: - resolution: {integrity: sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==} - engines: {node: '>= 0.8'} + abbrev@3.0.1: + resolution: {integrity: sha512-AO2ac6pjRB3SJmGJo+v5/aK6Omggp6fsLrs6wN9bd35ulu4cCwaAU9+7ZhXjeqHVkaHThLuzH0nZr0YpCDhygg==} + engines: {node: ^18.17.0 || >=20.5.0} - encoding-down@6.3.0: - resolution: {integrity: sha512-QKrV0iKR6MZVJV08QY0wp1e7vF6QbhnbQhb07bwpEyuz4uZiZgPlEGdkCROuFkUwdxlFaiPIhjyarH1ee/3vhw==} - engines: {node: '>=6'} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + abitype@1.0.0: + resolution: {integrity: sha512-NMeMah//6bJ56H5XRj8QCV4AwuW6hB6zqz2LnhhLdcWVQOsXki6/Pn3APeqxCma62nXIcmZWdu1DlHWS74umVQ==} + peerDependencies: + typescript: '>=5.0.4' + zod: ^3 >=3.22.0 + peerDependenciesMeta: + typescript: + optional: true + zod: + optional: true - encoding@0.1.13: - resolution: {integrity: sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==} + abitype@1.0.2: + resolution: {integrity: sha512-aFt4k2H+eiAKy/zxtnORa9iIb10BMBeWL18l8v4+QuwYEBXPxxjSB1bFZCzQmKPoj8m7j68K705l3uY+E2gAjg==} + peerDependencies: + typescript: '>=5.0.4' + zod: ^3 >=3.22.0 + peerDependenciesMeta: + typescript: + optional: true + zod: + optional: true - end-of-stream@1.4.5: - resolution: {integrity: sha512-ooEGc6HP26xXq/N+GCGOT0JKCLDGrq2bQUZrQ7gyrJiZANJ/8YDTxTpQBXGMn+WbIQXNVpyWymm7KYVICQnyOg==} + abitype@1.0.4: + resolution: {integrity: sha512-UivtYZOGJGE8rsrM/N5vdRkUpqEZVmuTumfTuolm7m/6O09wprd958rx8kUBwVAAAhQDveGAgD0GJdBuR8s6tw==} + peerDependencies: + typescript: '>=5.0.4' + zod: ^3 >=3.22.0 + peerDependenciesMeta: + typescript: + optional: true + zod: + optional: true - enquirer@2.4.1: - resolution: {integrity: sha512-rRqJg/6gd538VHvR3PSrdRBb/1Vy2YfzHqzvbhGIQpDRKIa4FgV/54b5Q1xYSxOOwKvjXweS26E0Q+nAMwp2pQ==} - engines: {node: '>=8.6'} + abitype@1.0.5: + resolution: {integrity: sha512-YzDhti7cjlfaBhHutMaboYB21Ha3rXR9QTkNJFzYC4kC8YclaiwPBBBJY8ejFdu2wnJeZCVZSMlQJ7fi8S6hsw==} + peerDependencies: + typescript: '>=5.0.4' + zod: ^3 >=3.22.0 + peerDependenciesMeta: + typescript: + optional: true + zod: + optional: true - entities@7.0.1: - resolution: {integrity: sha512-TWrgLOFUQTH994YUyl1yT4uyavY5nNB5muff+RtWaqNVCAK408b5ZnnbNAUEWLTCpum9w6arT70i1XdQ4UeOPA==} - engines: {node: '>=0.12'} + abitype@1.0.8: + resolution: {integrity: sha512-ZeiI6h3GnW06uYDLx0etQtX/p8E24UaHHBj57RSjK7YBFe7iuVn07EDpOeP451D06sF27VOz9JJPlIKJmXgkEg==} + peerDependencies: + typescript: '>=5.0.4' + zod: ^3 >=3.22.0 + peerDependenciesMeta: + typescript: + optional: true + zod: + optional: true - env-paths@2.2.1: - resolution: {integrity: sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==} - engines: {node: '>=6'} + abitype@1.2.3: + resolution: {integrity: sha512-Ofer5QUnuUdTFsBRwARMoWKOH1ND5ehwYhJ3OJ/BQO+StkwQjHw0XyVh4vDttzHB7QOFhPHa/o413PJ82gU/Tg==} + peerDependencies: + typescript: '>=5.0.4' + zod: ^3.22.0 || ^4.0.0 + peerDependenciesMeta: + typescript: + optional: true + zod: + optional: true - err-code@2.0.3: - resolution: {integrity: sha512-2bmlRpNKBxT/CRmPOlyISQpNj+qSeYvcym/uT0Jx2bMOlKLtSy1ZmLuVxSEKKyor/N5yhvp/ZiG1oE3DEYMSFA==} + abort-controller@3.0.0: + resolution: {integrity: sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==} + engines: {node: '>=6.5'} - errno@0.1.8: - resolution: {integrity: sha512-dJ6oBr5SQ1VSd9qkk7ByRgb/1SH4JZjCHSW/mr63/QcXO9zLVxvJ6Oy13nio03rxpSnVDDjFor75SjVeZWPW/A==} - hasBin: true + acorn-import-attributes@1.9.5: + resolution: {integrity: sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==} + peerDependencies: + acorn: ^8 - error-ex@1.3.4: - resolution: {integrity: sha512-sqQamAnR14VgCr1A618A3sGrygcpK+HEbenA/HiEAkkUwcZIIB/tgWqHFxWgOyDh4nB4JCRimh79dR5Ywc9MDQ==} + acorn-walk@8.3.4: + resolution: {integrity: sha512-ueEepnujpqee2o5aIYnvHU6C0A42MNdsIDeqy5BydrkuC5R1ZuUFnm27EeFJGoEHJQgn3uleRvmTXaJgfXbt4g==} + engines: {node: '>=0.4.0'} - es-abstract@1.24.1: - resolution: {integrity: sha512-zHXBLhP+QehSSbsS9Pt23Gg964240DPd6QCf8WpkqEXxQ7fhdZzYsocOr5u7apWonsS5EjZDmTF+/slGMyasvw==} - engines: {node: '>= 0.4'} + acorn@8.11.3: + resolution: {integrity: sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg==} + engines: {node: '>=0.4.0'} + hasBin: true - es-abstract@1.24.2: - resolution: {integrity: sha512-2FpH9Q5i2RRwyEP1AylXe6nYLR5OhaJTZwmlcP0dL/+JCbgg7yyEo/sEK6HeGZRf3dFpWwThaRHVApXSkW3xeg==} - engines: {node: '>= 0.4'} + acorn@8.15.0: + resolution: {integrity: sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg==} + engines: {node: '>=0.4.0'} + hasBin: true - es-define-property@1.0.1: - resolution: {integrity: sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==} - engines: {node: '>= 0.4'} + adm-zip@0.4.16: + resolution: {integrity: sha512-TFi4HBKSGfIKsK5YCkKaaFG2m4PEDyViZmEwof3MTIgzimHLto6muaHVpbrljdIvIrFZzEq/p4nafOeLcYegrg==} + engines: {node: '>=0.3.0'} - es-errors@1.3.0: - resolution: {integrity: sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==} - engines: {node: '>= 0.4'} + aes-js@4.0.0-beta.5: + resolution: {integrity: sha512-G965FqalsNyrPqgEGON7nIx1e/OVENSgiEIzyC63haUMuvNnwIgIjMs52hlTCKhkBny7A2ORNlfY9Zu+jmGk1Q==} - es-iterator-helpers@1.2.2: - resolution: {integrity: sha512-BrUQ0cPTB/IwXj23HtwHjS9n7O4h9FX94b4xc5zlTHxeLgTAdzYUDyy6KdExAl9lbN5rtfe44xpjpmj9grxs5w==} - engines: {node: '>= 0.4'} + agent-base@6.0.2: + resolution: {integrity: sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==} + engines: {node: '>= 6.0.0'} - es-module-lexer@1.7.0: - resolution: {integrity: sha512-jEQoCwk8hyb2AZziIOLhDqpm5+2ww5uIE6lkO/6jcOCusfk6LhMHpXXfBLXTZ7Ydyt0j4VoUQv6uGNYbdW+kBA==} + agent-base@7.1.4: + resolution: {integrity: sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==} + engines: {node: '>= 14'} - es-object-atoms@1.1.1: - resolution: {integrity: sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==} - engines: {node: '>= 0.4'} + aggregate-error@3.1.0: + resolution: {integrity: sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==} + engines: {node: '>=8'} - es-set-tostringtag@2.1.0: - resolution: {integrity: sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA==} - engines: {node: '>= 0.4'} + ajv@8.6.3: + resolution: {integrity: sha512-SMJOdDP6LqTkD0Uq8qLi+gMwSt0imXLSV080qFVwJCpH9U6Mb+SUGHAXM0KNbcBPguytWyvFxcHgMLe2D2XSpw==} - es-shim-unscopables@1.1.0: - resolution: {integrity: sha512-d9T8ucsEhh8Bi1woXCf+TIKDIROLG5WCkxg8geBCbvk22kzwC5G2OnXVMO6FUsvQlgUUXQ2itephWDLqDzbeCw==} - engines: {node: '>= 0.4'} + algoliasearch@5.12.0: + resolution: {integrity: sha512-psGBRYdGgik8I6m28iAB8xpubvjEt7UQU+w5MAJUA2324WHiGoHap5BPkkjB14rMaXeRts6pmOsrVIglGyOVwg==} + engines: {node: '>= 14.0.0'} - es-to-primitive@1.3.0: - resolution: {integrity: sha512-w+5mJ3GuFL+NjVtJlvydShqE1eN3h3PbI7/5LAsYJP/2qtuMXjfL2LpHSRqo4b4eSF5K/DH1JXKUAHSB2UW50g==} - engines: {node: '>= 0.4'} + alien-signals@0.2.0: + resolution: {integrity: sha512-StlonZhBBrsPPwrDjiPAiVTf/rolxffLxVPT60Qv/t88BZ81BvUVzHgGqEFvJ1ii8HXtm1+zU2Icr59tfWEcag==} - es5-ext@0.10.64: - resolution: {integrity: sha512-p2snDhiLaXe6dahss1LddxqEm+SkuDvV8dnIQG0MWjyHpcMNfXKPE+/Cc0y+PhxJX3A4xGNeFCj5oc0BUh6deg==} - engines: {node: '>=0.10'} + alien-signals@3.1.2: + resolution: {integrity: sha512-d9dYqZTS90WLiU0I5c6DHj/HcKkF8ZyGN3G5x8wSbslulz70KOxaqCT0hQCo9KOyhVqzqGojvNdJXoTumZOtcw==} - es6-error@4.1.1: - resolution: {integrity: sha512-Um/+FxMr9CISWh0bi5Zv0iOD+4cFh5qLeks1qhAopKVAJw3drgKbKySikp7wGhDL0HPeaja0P5ULZrxLkniUVg==} + ansi-align@3.0.1: + resolution: {integrity: sha512-IOfwwBF5iczOjp/WeY4YxyjqAFMQoZufdQWDd19SEExbVLNXqvpzSJ/M7Za4/sCPmQ0+GRquoA7bGcINcxew6w==} - es6-iterator@2.0.3: - resolution: {integrity: sha512-zw4SRzoUkd+cl+ZoE15A9o1oQd920Bb0iOJMQkQhl3jNc03YqVjAhG7scf9C5KWRU/R13Orf588uCC6525o02g==} + ansi-colors@4.1.1: + resolution: {integrity: sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==} + engines: {node: '>=6'} - es6-promise@4.2.8: - resolution: {integrity: sha512-HJDGx5daxeIvxdBxvG2cb9g4tEvwIk3i8+nhX0yGrYmZUzbkdg8QbDevheDB8gd0//uPj4c1EQua8Q+MViT0/w==} + ansi-colors@4.1.3: + resolution: {integrity: sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==} + engines: {node: '>=6'} - es6-symbol@3.1.4: - resolution: {integrity: sha512-U9bFFjX8tFiATgtkJ1zg25+KviIXpgRvRHS8sau3GfhVzThRQrOeksPeT0BWW2MNZs1OEWJ1DPXOQMn0KKRkvg==} - engines: {node: '>=0.12'} + ansi-escapes@4.3.2: + resolution: {integrity: sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==} + engines: {node: '>=8'} - esbuild@0.27.3: - resolution: {integrity: sha512-8VwMnyGCONIs6cWue2IdpHxHnAjzxnw2Zr7MkVxB2vjmQ2ivqGFb4LEG3SMnv0Gb2F/G/2yA8zUaiL1gywDCCg==} + ansi-escapes@7.0.0: + resolution: {integrity: sha512-GdYO7a61mR0fOlAsvC9/rIHf7L96sBc6dEWzeOu+KAea5bZyQRPIpojrVoI4AXGJS/ycu/fBTdLrUkA4ODrvjw==} engines: {node: '>=18'} - hasBin: true - escalade@3.2.0: - resolution: {integrity: sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==} - engines: {node: '>=6'} + ansi-regex@5.0.1: + resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} + engines: {node: '>=8'} - escape-html@1.0.3: - resolution: {integrity: sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==} + ansi-regex@6.2.2: + resolution: {integrity: sha512-Bq3SmSpyFHaWjPk8If9yc6svM8c56dB5BAtW4Qbw5jHTwwXXcTLoRMkpDJp6VL0XzlWaCHTXrkFURMYmD0sLqg==} + engines: {node: '>=12'} - escape-string-regexp@1.0.5: - resolution: {integrity: sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==} - engines: {node: '>=0.8.0'} + ansi-styles@3.2.1: + resolution: {integrity: sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==} + engines: {node: '>=4'} - escape-string-regexp@4.0.0: - resolution: {integrity: sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==} + ansi-styles@4.3.0: + resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==} + engines: {node: '>=8'} + + ansi-styles@5.2.0: + resolution: {integrity: sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==} engines: {node: '>=10'} - escodegen@1.8.1: - resolution: {integrity: sha512-yhi5S+mNTOuRvyW4gWlg5W1byMaQGWWSYHXsuFZ7GBo7tpyOwi2EdzMP/QWxh9hwkD2m+wDVHJsxhRIj+v/b/A==} - engines: {node: '>=0.12.0'} - hasBin: true + ansi-styles@6.2.1: + resolution: {integrity: sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==} + engines: {node: '>=12'} - escodegen@2.1.0: - resolution: {integrity: sha512-2NlIDTwUWJN0mRPQOdtQBzbUHvdGY2P1VXSyU83Q3xKxM7WHX2Ql8dKq782Q9TgQUNOLEzEYu9bzLNj1q88I5w==} - engines: {node: '>=6.0'} - hasBin: true + ansis@4.2.0: + resolution: {integrity: sha512-HqZ5rWlFjGiV0tDm3UxxgNRqsOTniqoKZu0pIAfh7TZQMGuZK+hH0drySty0si0QXj1ieop4+SkSfPZBPPkHig==} + engines: {node: '>=14'} - eslint-config-prettier@10.1.8: - resolution: {integrity: sha512-82GZUjRS0p/jganf6q1rEO25VSoHH0hKPCTrgillPjdI/3bgBhAE1QzHrHTizjpRvy6pGAvKjDJtk2pF9NDq8w==} - hasBin: true - peerDependencies: - eslint: '>=7.0.0' + any-promise@1.3.0: + resolution: {integrity: sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==} - eslint-config-prettier@8.10.2: - resolution: {integrity: sha512-/IGJ6+Dka158JnP5n5YFMOszjDWrXggGz1LaK/guZq9vZTmniaKlHcsscvkAhn9y4U+BU3JuUdYvtAMcv30y4A==} - hasBin: true - peerDependencies: - eslint: '>=7.0.0' + anymatch@3.1.3: + resolution: {integrity: sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==} + engines: {node: '>= 8'} - eslint-import-resolver-node@0.3.10: - resolution: {integrity: sha512-tRrKqFyCaKict5hOd244sL6EQFNycnMQnBe+j8uqGNXYzsImGbGUU4ibtoaBmv5FLwJwcFJNeg1GeVjQfbMrDQ==} + archiver-utils@5.0.2: + resolution: {integrity: sha512-wuLJMmIBQYCsGZgYLTy5FIB2pF6Lfb6cXMSF8Qywwk3t20zWnAi7zLcQFdKQmIB8wyZpY5ER38x08GbwtR2cLA==} + engines: {node: '>= 14'} - eslint-module-utils@2.12.1: - resolution: {integrity: sha512-L8jSWTze7K2mTg0vos/RuLRS5soomksDPoJLXIslC7c8Wmut3bx7CPpJijDcBZtxQ5lrbUdM+s0OlNbz0DCDNw==} - engines: {node: '>=4'} - peerDependencies: - '@typescript-eslint/parser': '*' - eslint: '*' - eslint-import-resolver-node: '*' - eslint-import-resolver-typescript: '*' - eslint-import-resolver-webpack: '*' - peerDependenciesMeta: - '@typescript-eslint/parser': - optional: true - eslint: - optional: true - eslint-import-resolver-node: - optional: true - eslint-import-resolver-typescript: - optional: true - eslint-import-resolver-webpack: - optional: true + archiver@7.0.1: + resolution: {integrity: sha512-ZcbTaIqJOfCc03QwD468Unz/5Ir8ATtvAHsK+FdXbDIbGfihqh9mrvdcYunQzqn4HrvWWaFyaxJhGZagaJJpPQ==} + engines: {node: '>= 14'} - eslint-plugin-import@2.32.0: - resolution: {integrity: sha512-whOE1HFo/qJDyX4SnXzP4N6zOWn79WhnCUY/iDR0mPfQZO8wcYE4JClzI2oZrhBnnMUCBCHZhO6VQyoBU95mZA==} - engines: {node: '>=4'} - peerDependencies: - '@typescript-eslint/parser': '*' - eslint: ^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8 || ^9 - peerDependenciesMeta: - '@typescript-eslint/parser': - optional: true + arg@4.1.0: + resolution: {integrity: sha512-ZWc51jO3qegGkVh8Hwpv636EkbesNV5ZNQPCtRa+0qytRYPEs9IYT9qITY9buezqUH5uqyzlWLcufrzU2rffdg==} - eslint-plugin-only-warn@1.1.0: - resolution: {integrity: sha512-2tktqUAT+Q3hCAU0iSf4xAN1k9zOpjK5WO8104mB0rT/dGhOa09582HN5HlbxNbPRZ0THV7nLGvzugcNOSjzfA==} - engines: {node: '>=6'} + arg@4.1.3: + resolution: {integrity: sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==} - eslint-plugin-prettier@3.4.1: - resolution: {integrity: sha512-htg25EUYUeIhKHXjOinK4BgCcDwtLHjqaxCDsMy5nbnUMkKFvIhMVCp+5GFUXQ4Nr8lBsPqtGAqBenbpFqAA2g==} - engines: {node: '>=6.0.0'} - peerDependencies: - eslint: '>=5.0.0' - eslint-config-prettier: '*' - prettier: '>=1.13.0' - peerDependenciesMeta: - eslint-config-prettier: - optional: true + argparse@1.0.10: + resolution: {integrity: sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==} - eslint-plugin-react-hooks@7.0.1: - resolution: {integrity: sha512-O0d0m04evaNzEPoSW+59Mezf8Qt0InfgGIBJnpC0h3NH/WjUAR7BIKUfysC6todmtiZ/A0oUVS8Gce0WhBrHsA==} - engines: {node: '>=18'} - peerDependencies: - eslint: ^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0 || ^9.0.0 + argparse@2.0.1: + resolution: {integrity: sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==} - eslint-plugin-react@7.37.5: - resolution: {integrity: sha512-Qteup0SqU15kdocexFNAJMvCJEfa2xUKNV4CC1xsVMrIIqEy3SQ/rqyxCWNzfrd3/ldy6HMlD2e0JDVpDg2qIA==} - engines: {node: '>=4'} - peerDependencies: - eslint: ^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9.7 + aria-hidden@1.2.6: + resolution: {integrity: sha512-ik3ZgC9dY/lYVVM++OISsaYDeg1tb0VtP5uL3ouh1koGOaUMDPpbFIei4JkFimWUFPn90sbMNMXQAIVOlnYKJA==} + engines: {node: '>=10'} - eslint-plugin-turbo@2.6.3: - resolution: {integrity: sha512-91WZ+suhT/pk+qNS0/rqT43xLUlUblsa3a8jKmAStGhkJCmR2uX0oWo/e0Edb+It8MdnteXuYpCkvsK4Vw8FtA==} - peerDependencies: - eslint: '>6.6.0' - turbo: '>2.0.0' + aria-query@5.3.0: + resolution: {integrity: sha512-b0P0sZPKtyu8HkeRAfCq0IfURZK+SuwMjY1UXGBU27wpAiTwQAIlq56IbIO+ytk/JjS1fMR14ee5WBBfKi5J6A==} - eslint-scope@8.4.0: - resolution: {integrity: sha512-sNXOfKCn74rt8RICKMvJS7XKV/Xk9kA7DyJr8mJik3S7Cwgy3qlkkmyS2uQB3jiJg6VNdZd/pDBJu0nvG2NlTg==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + array-union@1.0.2: + resolution: {integrity: sha512-Dxr6QJj/RdU/hCaBjOfxW+q6lyuVE6JFWIrAUpuOOhoJJoQ99cUn3igRaHVB5P9WrgFVN0FfArM3x0cueOU8ng==} + engines: {node: '>=0.10.0'} - eslint-visitor-keys@3.4.3: - resolution: {integrity: sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + array-union@2.1.0: + resolution: {integrity: sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==} + engines: {node: '>=8'} - eslint-visitor-keys@4.2.1: - resolution: {integrity: sha512-Uhdk5sfqcee/9H/rCOJikYz67o0a2Tw2hGRPOG2Y1R2dg7brRe1uG0yaNQDHu+TO/uQPF/5eCapvYSmHUjt7JQ==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + array-uniq@1.0.3: + resolution: {integrity: sha512-MNha4BWQ6JbwhFhj03YK552f7cb3AzoE8SzeljgChvL1dl3IcvggXVz1DilzySZkCja+CXuZbdW7yATchWn8/Q==} + engines: {node: '>=0.10.0'} - eslint-visitor-keys@5.0.1: - resolution: {integrity: sha512-tD40eHxA35h0PEIZNeIjkHoDR4YjjJp34biM0mDvplBe//mB+IHCqHDGV7pxF+7MklTvighcCPPZC7ynWyjdTA==} - engines: {node: ^20.19.0 || ^22.13.0 || >=24} + assertion-error@2.0.1: + resolution: {integrity: sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA==} + engines: {node: '>=12'} - eslint@9.39.2: - resolution: {integrity: sha512-LEyamqS7W5HB3ujJyvi0HQK/dtVINZvd5mAAp9eT5S/ujByGjiZLCzPcHVzuXbpJDJF/cxwHlfceVUDZ2lnSTw==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - hasBin: true - peerDependencies: - jiti: '*' - peerDependenciesMeta: - jiti: - optional: true + ast-kit@2.2.0: + resolution: {integrity: sha512-m1Q/RaVOnTp9JxPX+F+Zn7IcLYMzM8kZofDImfsKZd8MbR+ikdOzTeztStWqfrqIxZnYWryyI9ePm3NGjnZgGw==} + engines: {node: '>=20.19.0'} - eslint@9.39.4: - resolution: {integrity: sha512-XoMjdBOwe/esVgEvLmNsD3IRHkm7fbKIUGvrleloJXUZgDHig2IPWNniv+GwjyJXzuNqVjlr5+4yVUZjycJwfQ==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - hasBin: true - peerDependencies: - jiti: '*' - peerDependenciesMeta: - jiti: - optional: true + ast-v8-to-istanbul@0.3.9: + resolution: {integrity: sha512-dSC6tJeOJxbZrPzPbv5mMd6CMiQ1ugaVXXPRad2fXUSsy1kstFn9XQWemV9VW7Y7kpxgQ/4WMoZfwdH8XSU48w==} - esm@3.2.25: - resolution: {integrity: sha512-U1suiZ2oDVWv4zPO56S0NcR5QriEahGtdN2OR6FiOG4WJvcjBVFB0qI4+eKoWFH483PKGuLuu6V8Z4T5g63UVA==} - engines: {node: '>=6'} + ast-walker-scope@0.8.3: + resolution: {integrity: sha512-cbdCP0PGOBq0ASG+sjnKIoYkWMKhhz+F/h9pRexUdX2Hd38+WOlBkRKlqkGOSm0YQpcFMQBJeK4WspUAkwsEdg==} + engines: {node: '>=20.19.0'} - esniff@2.0.1: - resolution: {integrity: sha512-kTUIGKQ/mDPFoJ0oVfcmyJn4iBDRptjNVIzwIFR7tqWXdVI9xfA2RMwY/gbSpJG3lkdWNEjLap/NqVHZiJsdfg==} - engines: {node: '>=0.10'} + async-listen@1.2.0: + resolution: {integrity: sha512-CcEtRh/oc9Jc4uWeUwdpG/+Mb2YUHKmdaTf0gUr7Wa+bfp4xx70HOb3RuSTJMvqKNB1TkdTfjLdrcz2X4rkkZA==} - espree@10.4.0: - resolution: {integrity: sha512-j6PAQ2uUr79PZhBjP5C5fhl8e39FmRnOjsD5lGnWrFU8i2G776tBK7+nP8KuQUTTyAZUwfQqXAgrVH5MbH9CYQ==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + async-listen@3.0.0: + resolution: {integrity: sha512-V+SsTpDqkrWTimiotsyl33ePSjA5/KrithwupuvJ6ztsqPvGv6ge4OredFhPffVXiLN/QUWvE0XcqJaYgt6fOg==} + engines: {node: '>= 14'} - esprima@2.7.3: - resolution: {integrity: sha512-OarPfz0lFCiW4/AV2Oy1Rp9qu0iusTKqykwTspGCZtPxmF81JR4MmIebvF1F9+UOKth2ZubLQ4XGGaU+hSn99A==} - engines: {node: '>=0.10.0'} - hasBin: true + async-listen@3.0.1: + resolution: {integrity: sha512-cWMaNwUJnf37C/S5TfCkk/15MwbPRwVYALA2jtjkbHjCmAPiDXyNJy2q3p1KAZzDLHAWyarUWSujUoHR4pEgrA==} + engines: {node: '>= 14'} - esprima@4.0.1: - resolution: {integrity: sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==} - engines: {node: '>=4'} - hasBin: true - - esquery@1.6.0: - resolution: {integrity: sha512-ca9pw9fomFcKPvFLXhBKUK90ZvGibiGOvRJNbjljY7s7uq/5YO4BOzcYtJqExdx99rF6aAcnRxHmcUHcz6sQsg==} - engines: {node: '>=0.10'} - - esquery@1.7.0: - resolution: {integrity: sha512-Ap6G0WQwcU/LHsvLwON1fAQX9Zp0A2Y6Y/cJBl9r/JbW90Zyg4/zbG6zzKa2OTALELarYHmKu0GhpM5EO+7T0g==} - engines: {node: '>=0.10'} - - esrecurse@4.3.0: - resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==} - engines: {node: '>=4.0'} + async-mutex@0.2.6: + resolution: {integrity: sha512-Hs4R+4SPgamu6rSGW8C7cV9gaWUKEHykfzCCvIRuaVv636Ju10ZdeUbvb4TBEW0INuq2DHZqXbK4Nd3yG4RaRw==} - estraverse@1.9.3: - resolution: {integrity: sha512-25w1fMXQrGdoquWnScXZGckOv+Wes+JDnuN/+7ex3SauFRS72r2lFDec0EKPt2YD1wUJ/IrfEex+9yp4hfSOJA==} - engines: {node: '>=0.10.0'} + async-ref@0.1.6: + resolution: {integrity: sha512-gIvfC7ahv452pM+nwnxZJd/vhUh8UFMrd1DCvIvWjoy9WrRmYroXTTDxwg91oiD+4CqQKrg+11uCxZrzat4UvQ==} - estraverse@5.3.0: - resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==} - engines: {node: '>=4.0'} + async-retry@1.3.3: + resolution: {integrity: sha512-wfr/jstw9xNi/0teMHrRW7dsz3Lt5ARhYNZ2ewpadnhaIp5mbALhOAP+EAdsC7t4Z6wqsDVv9+W6gm1Dk9mEyw==} - estree-walker@3.0.3: - resolution: {integrity: sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==} + async-sema@3.1.1: + resolution: {integrity: sha512-tLRNUXati5MFePdAk8dw7Qt7DpxPB60ofAgn8WRhW6a2rcimZnYBP9oxHiv0OHy+Wz7kPMG+t4LGdt31+4EmGg==} - esutils@2.0.3: - resolution: {integrity: sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==} - engines: {node: '>=0.10.0'} + async@3.2.6: + resolution: {integrity: sha512-htCUDlxyyCLMgaM3xXg0C0LW2xqfuQ6p05pCEIsXuyQ+a1koYKTuBMzRNwmybfLgvJDMd0r1LTn4+E0Ti6C2AA==} - etag@1.8.1: - resolution: {integrity: sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==} - engines: {node: '>= 0.6'} + atomic-sleep@1.0.0: + resolution: {integrity: sha512-kNOjDqAh7px0XWNI+4QbzoiR/nTkHAWNud2uvnJquD1/x5a7EQZMJT0AczqK0Qn67oY/TTQ1LbUKajZpp3I9tQ==} + engines: {node: '>=8.0.0'} - eth-block-tracker@5.0.1: - resolution: {integrity: sha512-NVs+JDSux0FdmOrl3A2YDcQFkkYf9/qW9irvPmtC7bhMoPAe6oBlaqqe/m9Ixh5rkKqAox4mEyWGpsFmf/IsNw==} + autoprefixer@10.4.23: + resolution: {integrity: sha512-YYTXSFulfwytnjAPlw8QHncHJmlvFKtczb8InXaAx9Q0LbfDnfEYDE55omerIJKihhmU61Ft+cAOSzQVaBUmeA==} + engines: {node: ^10 || ^12 || >=14} + hasBin: true + peerDependencies: + postcss: ^8.1.0 - eth-ens-namehash@2.0.8: - resolution: {integrity: sha512-VWEI1+KJfz4Km//dadyvBBoBeSQ0MHTXPvr8UIXiLW6IanxvAV+DmlZAijZwAyggqGUfwQBeHf7tc9wzc1piSw==} + available-typed-arrays@1.0.7: + resolution: {integrity: sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==} + engines: {node: '>= 0.4'} - eth-gas-reporter@0.2.27: - resolution: {integrity: sha512-femhvoAM7wL0GcI8ozTdxfuBtBFJ9qsyIAsmKVjlWAHUbdnnXHt+lKzz/kmldM5lA9jLuNHGwuIxorNpLbR1Zw==} + b4a@1.7.3: + resolution: {integrity: sha512-5Q2mfq2WfGuFp3uS//0s6baOJLMoVduPYVeNmDYxu5OUA1/cBfvr2RIS7vi62LdNj/urk1hfmj867I3qt6uZ7Q==} peerDependencies: - '@codechecks/client': ^0.1.0 + react-native-b4a: '*' peerDependenciesMeta: - '@codechecks/client': + react-native-b4a: optional: true - eth-json-rpc-filters@5.0.0: - resolution: {integrity: sha512-oU05/bxJBUjEGO0ujSNALvgMwQ50uHuex0zkhsOCWnl3ISdWm0Ni4J0ZIjW44ZQrgXy8Nd1vkywGW2RFvcmE1w==} - engines: {node: '>=12.0.0'} + balanced-match@1.0.2: + resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==} - eth-json-rpc-middleware@6.0.0: - resolution: {integrity: sha512-qqBfLU2Uq1Ou15Wox1s+NX05S9OcAEL4JZ04VZox2NS0U+RtCMjSxzXhLFWekdShUPZ+P8ax3zCO2xcPrp6XJQ==} + bare-events@2.8.2: + resolution: {integrity: sha512-riJjyv1/mHLIPX4RwiK+oW9/4c3TEUeORHKefKAKnZ5kyslbN+HXowtbaVEqt4IMUB7OXlfixcs6gsFeo/jhiQ==} + peerDependencies: + bare-abort-controller: '*' + peerDependenciesMeta: + bare-abort-controller: + optional: true - eth-json-rpc-middleware@8.1.0: - resolution: {integrity: sha512-0ZZDr6KoddqN4N100a7YWzLTYrVN0P49DJ3Su1vsRavPpieq92rgZymnQcr0tLFBQDEJg1MVqLex46fA0GEkDA==} - engines: {node: '>=12.0.0'} + base-x@3.0.9: + resolution: {integrity: sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ==} - eth-json-rpc-middleware@9.0.1: - resolution: {integrity: sha512-5yLNjkedXA4LTIBzzU2f7aHFJqANPsc5qCdOZy6T2p7mlDLW+0q0YBQg6Lx4sHdamOWUnJwvm70qzPAqst5zSg==} - engines: {node: '>=14.0.0'} + base-x@5.0.1: + resolution: {integrity: sha512-M7uio8Zt++eg3jPj+rHMfCC+IuygQHHCOU+IYsVtik6FWjuYpVt/+MRKcgsAMHh8mMFAwnB+Bs+mTrFiXjMzKg==} - eth-lib@0.1.29: - resolution: {integrity: sha512-bfttrr3/7gG4E02HoWTDUcDDslN003OlOoBxk9virpAZQ1ja/jDgwkWB8QfJF7ojuEowrqy+lzp9VcJG7/k5bQ==} + base64-js@1.5.1: + resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==} - eth-lib@0.2.8: - resolution: {integrity: sha512-ArJ7x1WcWOlSpzdoTBX8vkwlkSQ85CjjifSZtV4co64vWxSV8geWfPI9x4SVYu3DSxnX4yWFVTtGL+j9DUFLNw==} + baseline-browser-mapping@2.9.11: + resolution: {integrity: sha512-Sg0xJUNDU1sJNGdfGWhVHX0kkZ+HWcvmVymJbj6NSgZZmW/8S9Y2HQ5euytnIgakgxN6papOAWiwDo1ctFDcoQ==} + hasBin: true - eth-query@2.1.2: - resolution: {integrity: sha512-srES0ZcvwkR/wd5OQBRA1bIJMww1skfGS0s8wlwK3/oNP4+wnds60krvu5R1QbpRQjMmpG5OMIWro5s7gvDPsA==} + better-path-resolve@1.0.0: + resolution: {integrity: sha512-pbnl5XzGBdrFU/wT4jqmJVPn2B6UHPBOhzMQkY/SPUPB6QtUXtmBHBIwCbXJol93mOpGMnQyP/+BB19q04xj7g==} + engines: {node: '>=4'} - eth-rpc-errors@3.0.0: - resolution: {integrity: sha512-iPPNHPrLwUlR9xCSYm7HHQjWBasor3+KZfRvwEWxMz3ca0yqnlBeJrnyphkGIXZ4J7AMAaOLmwy4AWhnxOiLxg==} + big.js@6.2.2: + resolution: {integrity: sha512-y/ie+Faknx7sZA5MfGA2xKlu0GDv8RWrXGsmlteyJQ2lvoKv9GBK/fpRMc2qlSoBAgNxrixICFCBefIq8WCQpQ==} - eth-rpc-errors@4.0.3: - resolution: {integrity: sha512-Z3ymjopaoft7JDoxZcEb3pwdGh7yiYMhOwm2doUt6ASXlMavpNlK6Cre0+IMl2VSGyEU9rkiperQhp5iRxn5Pg==} + binary-extensions@2.2.0: + resolution: {integrity: sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==} + engines: {node: '>=8'} - eth-sig-util@1.4.2: - resolution: {integrity: sha512-iNZ576iTOGcfllftB73cPB5AN+XUQAT/T8xzsILsghXC1o8gJUqe3RHlcDqagu+biFpYQ61KQrZZJza8eRSYqw==} - deprecated: Deprecated in favor of '@metamask/eth-sig-util' + bindings@1.5.0: + resolution: {integrity: sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==} - ethereum-bloom-filters@1.2.0: - resolution: {integrity: sha512-28hyiE7HVsWubqhpVLVmZXFd4ITeHi+BUu05o9isf0GUpMtzBUi+8/gFrGaGYzvGAJQmJ3JKj77Mk9G98T84rA==} + birpc@0.2.19: + resolution: {integrity: sha512-5WeXXAvTmitV1RqJFppT5QtUiz2p1mRSYU000Jkft5ZUCLJIk4uQriYNO50HknxKwM6jd8utNc66K1qGIwwWBQ==} - ethereum-cryptography@0.1.3: - resolution: {integrity: sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==} + birpc@2.9.0: + resolution: {integrity: sha512-KrayHS5pBi69Xi9JmvoqrIgYGDkD6mcSe/i6YKi3w5kekCLzrX4+nawcXqrj2tIp50Kw/mT/s3p+GVK0A0sKxw==} - ethereum-cryptography@1.2.0: - resolution: {integrity: sha512-6yFQC9b5ug6/17CQpCyE3k9eKBMdhyVjzUy1WkiuY/E4vj/SXDBbCw8QEIaXqf0Mf2SnY6RmpDcwlUmBSS0EJw==} + blakejs@1.2.1: + resolution: {integrity: sha512-QXUSXI3QVc/gJME0dBpXrag1kbzOqCjCX8/b54ntNyW6sjtoqxqRk3LTmXzaJoh71zMsDCjM+47jS7XiwN/+fQ==} - ethereum-cryptography@2.2.1: - resolution: {integrity: sha512-r/W8lkHSiTLxUxW8Rf3u4HGB0xQweG2RyETjywylKZSzLWoWAijRz8WCuOtJ6wah+avllXBqZuk29HCCvhEIRg==} + bn.js@4.12.0: + resolution: {integrity: sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==} - ethereum-waffle@4.0.10: - resolution: {integrity: sha512-iw9z1otq7qNkGDNcMoeNeLIATF9yKl1M8AIeu42ElfNBplq0e+5PeasQmm8ybY/elkZ1XyRO0JBQxQdVRb8bqQ==} - engines: {node: '>=10.0'} - hasBin: true - peerDependencies: - ethers: '*' + bn.js@4.12.2: + resolution: {integrity: sha512-n4DSx829VRTRByMRGdjQ9iqsN0Bh4OolPsFnaZBLcbi8iXcB+kJ9s7EnRt4wILZNV3kPLHkRVfOc/HvhC3ovDw==} - ethereumjs-abi@0.6.8: - resolution: {integrity: sha512-Tx0r/iXI6r+lRsdvkFDlut0N08jWMnKRZ6Gkq+Nmw75lZe4e6o3EkSnkaBP5NF6+m5PTGAr9JP43N3LyeoglsA==} - deprecated: This library has been deprecated and usage is discouraged. + bn.js@5.2.1: + resolution: {integrity: sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==} - ethereumjs-abi@https://codeload.github.com/ethereumjs/ethereumjs-abi/tar.gz/ee3994657fa7a427238e6ba92a84d0b529bbcde0: - resolution: {tarball: https://codeload.github.com/ethereumjs/ethereumjs-abi/tar.gz/ee3994657fa7a427238e6ba92a84d0b529bbcde0} - version: 0.6.8 + bn.js@5.2.2: + resolution: {integrity: sha512-v2YAxEmKaBLahNwE1mjp4WON6huMNeuDvagFZW+ASCuA/ku0bXR9hSMw0XpiqMoA3+rmnyck/tPRSFQkoC9Cuw==} - ethereumjs-account@2.0.5: - resolution: {integrity: sha512-bgDojnXGjhMwo6eXQC0bY6UK2liSFUSMwwylOmQvZbSl/D7NXQ3+vrGO46ZeOgjGfxXmgIeVNDIiHw7fNZM4VA==} + boolbase@1.0.0: + resolution: {integrity: sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww==} - ethereumjs-block@2.2.2: - resolution: {integrity: sha512-2p49ifhek3h2zeg/+da6XpdFR3GlqY3BIEiqxGF8j9aSRIgkb7M1Ky+yULBKJOu8PAZxfhsYA+HxUk2aCQp3vg==} - deprecated: 'New package name format for new versions: @ethereumjs/block. Please update.' + bowser@2.13.1: + resolution: {integrity: sha512-OHawaAbjwx6rqICCKgSG0SAnT05bzd7ppyKLVUITZpANBaaMFBAsaNkto3LoQ31tyFP5kNujE8Cdx85G9VzOkw==} - ethereumjs-common@1.5.2: - resolution: {integrity: sha512-hTfZjwGX52GS2jcVO6E2sx4YuFnf0Fhp5ylo4pEPhEffNln7vS59Hr5sLnp3/QCazFLluuBZ+FZ6J5HTp0EqCA==} - deprecated: 'New package name format for new versions: @ethereumjs/common. Please update.' + boxen@5.1.2: + resolution: {integrity: sha512-9gYgQKXx+1nP8mP7CzFyaUARhg7D3n1dF/FnErWmu9l6JvGpNUN278h0aSb+QjoiKSWG+iZ3uHrcqk0qrY9RQQ==} + engines: {node: '>=10'} - ethereumjs-tx@2.1.2: - resolution: {integrity: sha512-zZEK1onCeiORb0wyCXUvg94Ve5It/K6GD1K+26KfFKodiBiS6d9lfCXlUKGBBdQ+bv7Day+JK0tj1K+BeNFRAw==} - deprecated: 'New package name format for new versions: @ethereumjs/tx. Please update.' + brace-expansion@1.1.11: + resolution: {integrity: sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==} - ethereumjs-util@5.2.1: - resolution: {integrity: sha512-v3kT+7zdyCm1HIqWlLNrHGqHGLpGYIhjeHxQjnDXjLT2FyGJDsd3LWMYUo7pAFRrk86CR3nUJfhC81CCoJNNGQ==} + brace-expansion@2.0.1: + resolution: {integrity: sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==} - ethereumjs-util@6.2.1: - resolution: {integrity: sha512-W2Ktez4L01Vexijrm5EB6w7dg4n/TgpoYU4avuT5T3Vmnw/eCRtiBrJfQYS/DCSvDIOLn2k57GcHdeBcgVxAqw==} + brace-expansion@2.0.2: + resolution: {integrity: sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ==} - ethereumjs-util@7.1.3: - resolution: {integrity: sha512-y+82tEbyASO0K0X1/SRhbJJoAlfcvq8JbrG4a5cjrOks7HS/36efU/0j2flxCPOUM++HFahk33kr/ZxyC4vNuw==} - engines: {node: '>=10.0.0'} + braces@3.0.2: + resolution: {integrity: sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==} + engines: {node: '>=8'} - ethereumjs-util@7.1.5: - resolution: {integrity: sha512-SDl5kKrQAudFBUe5OJM9Ac6WmMyYmXX/6sTmLZ3ffG2eY6ZIGBes3pEDxNN6V72WyOw4CPD5RomKdsa8DAAwLg==} - engines: {node: '>=10.0.0'} + braces@3.0.3: + resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==} + engines: {node: '>=8'} - ethereumjs-vm@2.6.0: - resolution: {integrity: sha512-r/XIUik/ynGbxS3y+mvGnbOKnuLo40V5Mj1J25+HEO63aWYREIqvWeRO/hnROlMBE5WoniQmPmhiaN0ctiHaXw==} - deprecated: 'New package name format for new versions: @ethereumjs/vm. Please update.' + brorand@1.1.0: + resolution: {integrity: sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==} - ethers@5.8.0: - resolution: {integrity: sha512-DUq+7fHrCg1aPDFCHx6UIPb3nmt2XMpM7Y/g2gLhsl3lIBqeAfOJIl1qEvRf2uq3BiKxmh6Fh5pfp2ieyek7Kg==} + browser-stdout@1.3.1: + resolution: {integrity: sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==} - ethers@6.16.0: - resolution: {integrity: sha512-U1wulmetNymijEhpSEQ7Ct/P/Jw9/e7R1j5XIbPRydgV2DjLVMsULDlNksq3RQnFgKoLlZf88ijYtWEXcPa07A==} - engines: {node: '>=14.0.0'} + browserify-aes@1.2.0: + resolution: {integrity: sha512-+7CHXqGuspUn/Sl5aO7Ea0xWGAtETPXNSAjHo48JfLdPWcMng33Xe4znFvQweqc/uzk5zSOI3H52CYnjCfb5hA==} - ethjs-unit@0.1.6: - resolution: {integrity: sha512-/Sn9Y0oKl0uqQuvgFk/zQgR7aw1g36qX/jzSQ5lSwlO0GigPymk4eGQfeNTD03w1dPOqfz8V77Cy43jH56pagw==} - engines: {node: '>=6.5.0', npm: '>=3'} + browserslist@4.23.0: + resolution: {integrity: sha512-QW8HiM1shhT2GuzkvklfjcKDiWFXHOeFCIA/huJPwHsslwcydgk7X+z2zXpEijP98UCY7HbubZt5J2Zgvf0CaQ==} + engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} + hasBin: true - ethjs-util@0.1.6: - resolution: {integrity: sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==} - engines: {node: '>=6.5.0', npm: '>=3'} + browserslist@4.28.1: + resolution: {integrity: sha512-ZC5Bd0LgJXgwGqUknZY/vkUQ04r8NXnJZ3yYi4vDmSiZmC/pdSN0NbNRPxZpbtO4uAfDUAFffO8IZoM3Gj8IkA==} + engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} + hasBin: true - event-emitter@0.3.5: - resolution: {integrity: sha512-D9rRn9y7kLPnJ+hMq7S/nhvoKwwvVJahBi2BPmx3bvbsEdK3W9ii8cBSGjP+72/LnM4n6fo3+dkCX5FeTQruXA==} + bs58@4.0.1: + resolution: {integrity: sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==} - eventemitter2@6.4.9: - resolution: {integrity: sha512-JEPTiaOt9f04oa6NOkc4aH+nVp5I3wEjpHbIPqfgCdD5v5bUzy7xQqwcVO2aDQgOWhI28da57HksMrzK9HlRxg==} + bs58@6.0.0: + resolution: {integrity: sha512-PD0wEnEYg6ijszw/u8s+iI3H17cTymlrwkKhDhPZq+Sokl3AU4htyBFTjAeNAlCCmg0f53g6ih3jATyCKftTfw==} - eventemitter3@3.1.2: - resolution: {integrity: sha512-tvtQIeLVHjDkJYnzf2dgVMxfuSGJeM/7UCG17TT4EumTfNtF+0nebF/4zWOIkCreAbtNqhGEboB6BWrwqNaw4Q==} + bs58check@2.1.2: + resolution: {integrity: sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==} - eventemitter3@4.0.4: - resolution: {integrity: sha512-rlaVLnVxtxvoyLsQQFBx53YmXHDxRIzzTLbdfxqi4yocpSjAxXwkU0cScM5JgSKMqEhrZpnvQ2D9gjylR0AimQ==} + buffer-crc32@0.2.13: + resolution: {integrity: sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ==} - eventemitter3@5.0.1: - resolution: {integrity: sha512-GWkBvjiSZK87ELrYOSESUYeVIc9mvLLf/nXalMOS5dYrgZq9o5OVkbZAVM06CVxYsCwH9BDZFPlQTlPA1j4ahA==} + buffer-crc32@1.0.0: + resolution: {integrity: sha512-Db1SbgBS/fg/392AblrMJk97KggmvYhr4pB5ZIMTWtaivCPMWLkmb7m21cJvpvgK+J3nsU2CmmixNBZx4vFj/w==} + engines: {node: '>=8.0.0'} - events@3.3.0: - resolution: {integrity: sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==} - engines: {node: '>=0.8.x'} + buffer-from@1.1.2: + resolution: {integrity: sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==} - evp_bytestokey@1.0.3: - resolution: {integrity: sha512-/f2Go4TognH/KvCISP7OUsHn85hT9nUkxxA9BEWxFn+Oj9o8ZNLm/40hdlgSLyuOimsrTKLUMEorQexp/aPQeA==} + buffer-xor@1.0.3: + resolution: {integrity: sha512-571s0T7nZWK6vB67HI5dyUF7wXiNcfaPPPTl6zYCNApANjIvYJTg7hlud/+cJpdAhS7dVzqMLmfhfHR3rAcOjQ==} - execa@5.1.1: - resolution: {integrity: sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==} - engines: {node: '>=10'} + buffer@6.0.3: + resolution: {integrity: sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==} - expect-type@1.3.0: - resolution: {integrity: sha512-knvyeauYhqjOYvQ66MznSMs83wmHrCycNEN6Ao+2AeYEfxUIkuiVxdEa1qlGEPK+We3n0THiDciYSsCcgW/DoA==} - engines: {node: '>=12.0.0'} + bufferutil@4.0.8: + resolution: {integrity: sha512-4T53u4PdgsXqKaIctwF8ifXlRTTmEPJ8iEPWFdGZvcf7sbwYo6FKFEX9eNNAnzFZ7EzJAQ3CJeOtCRA4rDp7Pw==} + engines: {node: '>=6.14.2'} - express@4.22.1: - resolution: {integrity: sha512-F2X8g9P1X7uCPZMA3MVf9wcTqlyNp7IhH5qPCI0izhaOIYXaW9L535tGA3qmjRzpH+bZczqq7hVKxTR4NWnu+g==} - engines: {node: '>= 0.10.0'} + bufferutil@4.1.0: + resolution: {integrity: sha512-ZMANVnAixE6AWWnPzlW2KpUrxhm9woycYvPOo67jWHyFowASTEd9s+QN1EIMsSDtwhIxN4sWE1jotpuDUIgyIw==} + engines: {node: '>=6.14.2'} - ext@1.7.0: - resolution: {integrity: sha512-6hxeJYaL110a9b5TEJSj0gojyHQAmA2ch5Os+ySCiA1QGdS697XWY1pzsrSjqA9LDEEgdB/KypIlR59RcLuHYw==} + bun-types@1.1.29: + resolution: {integrity: sha512-En3/TzSPMPyl5UlUB1MHzHpcrZDakTm7mS203eLoX1fBoEa3PW+aSS8GAqVJ7Is/m34Z5ogL+ECniLY0uDaCPw==} - extend@3.0.2: - resolution: {integrity: sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==} + bun@1.1.30: + resolution: {integrity: sha512-ysRL1pq10Xba0jqVLPrKU3YIv0ohfp3cTajCPtpjCyppbn3lfiAVNpGoHfyaxS17OlPmWmR67UZRPw/EueQuug==} + cpu: [arm64, x64] + os: [darwin, linux, win32] + hasBin: true - extendable-error@0.1.7: - resolution: {integrity: sha512-UOiS2in6/Q0FK0R0q6UY9vYpQ21mr/Qn1KOnte7vsACuNJf514WvCCUHSRCPcgjPT2bAhNIJdlE6bVap1GKmeg==} + bundle-name@4.1.0: + resolution: {integrity: sha512-tjwM5exMg6BGRI+kNmTntNsvdZS1X8BFYS6tnJ2hdH0kVxM6/eVZ2xy+FqStSWvYmtfFMDLIxurorHwDKfDz5Q==} + engines: {node: '>=18'} - external-editor@3.1.0: - resolution: {integrity: sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==} - engines: {node: '>=4'} + bundle-require@5.1.0: + resolution: {integrity: sha512-3WrrOuZiyaaZPWiEt4G3+IffISVC9HYlWueJEBWED4ZH4aIAC2PnkdnuRrR94M+w6yGWn4AglWtJtBI8YqvgoA==} + engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + peerDependencies: + esbuild: '>=0.18' - extsprintf@1.3.0: - resolution: {integrity: sha512-11Ndz7Nv+mvAC1j0ktTa7fAb0vLyGGX+rMHNBYQviQDGU0Hw7lhctJANqbPhu9nV9/izT/IntTgZ7Im/9LJs9g==} - engines: {'0': node >=0.6.0} + bytes@3.1.0: + resolution: {integrity: sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg==} + engines: {node: '>= 0.8'} - fake-indexeddb@4.0.2: - resolution: {integrity: sha512-SdTwEhnakbgazc7W3WUXOJfGmhH0YfG4d+dRPOFoYDRTL6U5t8tvrmkf2W/C3W1jk2ylV7Wrnj44RASqpX/lEw==} + bytes@3.1.2: + resolution: {integrity: sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==} + engines: {node: '>= 0.8'} - fake-indexeddb@6.2.5: - resolution: {integrity: sha512-CGnyrvbhPlWYMngksqrSSUT1BAVP49dZocrHuK0SvtR0D5TMs5wP0o3j7jexDJW01KSadjBp1M/71o/KR3nD1w==} - engines: {node: '>=18'} + c12@3.3.3: + resolution: {integrity: sha512-750hTRvgBy5kcMNPdh95Qo+XUBeGo8C7nsKSmedDmaQI+E0r82DwHeM6vBewDe4rGFbnxoa4V9pw+sPh5+Iz8Q==} + peerDependencies: + magicast: '*' + peerDependenciesMeta: + magicast: + optional: true - fake-merkle-patricia-tree@1.0.1: - resolution: {integrity: sha512-Tgq37lkc9pUIgIKw5uitNUKcgcYL3R6JvXtKQbOf/ZSavXbidsksgp/pAY6p//uhw0I4yoMsvTSovvVIsk/qxA==} + cac@6.7.14: + resolution: {integrity: sha512-b6Ilus+c3RrdDk+JhLKUAQfzzgLEPy6wcXqS7f/xe1EETvsDP6GORG7SFuOs6cID5YkqchW/LXZbX5bc8j7ZcQ==} + engines: {node: '>=8'} - fast-base64-decode@1.0.0: - resolution: {integrity: sha512-qwaScUgUGBYeDNRnbc/KyllVU88Jk1pRHPStuF/lO7B0/RTRLj7U0lkdTAutlBblY08rwZDff6tNU9cjv6j//Q==} + call-bind-apply-helpers@1.0.2: + resolution: {integrity: sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==} + engines: {node: '>= 0.4'} - fast-deep-equal@3.1.3: - resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} + call-bind@1.0.8: + resolution: {integrity: sha512-oKlSFMcMwpUg2ednkhQ454wfWiU/ul3CkJe/PEHcTKuiX6RpbehUiFMXu13HalGZxfUwCQzZG747YXBn1im9ww==} + engines: {node: '>= 0.4'} - fast-diff@1.3.0: - resolution: {integrity: sha512-VxPP4NqbUjj6MaAOafWeUn2cXWLcCtljklUtZf0Ind4XQ+QPtmA0b18zZy0jIQx+ExRVCR/ZQpBmik5lXshNsw==} + call-bound@1.0.4: + resolution: {integrity: sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==} + engines: {node: '>= 0.4'} - fast-equals@5.4.0: - resolution: {integrity: sha512-jt2DW/aNFNwke7AUd+Z+e6pz39KO5rzdbbFCg2sGafS4mk13MI7Z8O5z9cADNn5lhGODIgLwug6TZO2ctf7kcw==} - engines: {node: '>=6.0.0'} + camelcase@5.3.1: + resolution: {integrity: sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==} + engines: {node: '>=6'} - fast-glob@3.3.1: - resolution: {integrity: sha512-kNFPyjhh5cKjrUltxs+wFx+ZkbRaxxmZ+X0ZU31SOsxCEtP9VPgtq2teZw1DebupL5GmDaNQ6yKMMVcM41iqDg==} - engines: {node: '>=8.6.0'} + camelcase@6.3.0: + resolution: {integrity: sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==} + engines: {node: '>=10'} - fast-glob@3.3.3: - resolution: {integrity: sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==} - engines: {node: '>=8.6.0'} + caniuse-api@3.0.0: + resolution: {integrity: sha512-bsTwuIg/BZZK/vreVTYYbSWoe2F+71P7K5QGEX+pT250DZbfU1MQ5prOKpPR+LL6uWKK3KMwMCAS74QB3Um1uw==} - fast-json-patch@3.1.1: - resolution: {integrity: sha512-vf6IHUX2SBcA+5/+4883dsIjpBTqmfBjmYiWK1savxQmFk4JfBMLa7ynTYOs1Rolp/T1betJxHiGD3g1Mn8lUQ==} + caniuse-lite@1.0.30001761: + resolution: {integrity: sha512-JF9ptu1vP2coz98+5051jZ4PwQgd2ni8A+gYSN7EA7dPKIMf0pDlSUxhdmVOaV3/fYK5uWBkgSXJaRLr4+3A6g==} - fast-json-stable-stringify@2.1.0: - resolution: {integrity: sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==} + ccount@2.0.1: + resolution: {integrity: sha512-eyrF0jiFpY+3drT6383f1qhkbGsLSifNAjA61IUjZjmLCWjItY6LB9ft9YhoDgwfmclB2zhu51Lc7+95b8NRAg==} - fast-levenshtein@2.0.6: - resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==} + chai@5.2.0: + resolution: {integrity: sha512-mCuXncKXk5iCLhfhwTc0izo0gtEmpz5CtG2y8GiOINBlMVS6v8TMRc5TaLWKS6692m9+dVVfzgeVxR5UxWHTYw==} + engines: {node: '>=12'} - fast-safe-stringify@2.1.1: - resolution: {integrity: sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA==} + chalk@2.4.2: + resolution: {integrity: sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==} + engines: {node: '>=4'} - fast-uri@3.1.0: - resolution: {integrity: sha512-iPeeDKJSWf4IEOasVVrknXpaBV0IApz/gp7S2bb7Z4Lljbl2MGJRqInZiUrQwV16cpzw/D3S5j5Julj/gT52AA==} + chalk@4.1.2: + resolution: {integrity: sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==} + engines: {node: '>=10'} - fast-xml-builder@1.1.5: - resolution: {integrity: sha512-4TJn/8FKLeslLAH3dnohXqE3QSoxkhvaMzepOIZytwJXZO69Bfz0HBdDHzOTOon6G59Zrk6VQ2bEiv1t61rfkA==} + chalk@5.3.0: + resolution: {integrity: sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w==} + engines: {node: ^12.17.0 || ^14.13 || >=16.0.0} - fast-xml-parser@5.7.1: - resolution: {integrity: sha512-8Cc3f8GUGUULg34pBch/KGyPLglS+OFs05deyOlY7fL2MTagYPKrVQNmR1fLF/yJ9PH5ZSTd3YDF6pnmeZU+zA==} - hasBin: true + change-case@5.4.4: + resolution: {integrity: sha512-HRQyTk2/YPEkt9TnUPbOpr64Uw3KOicFWPVBb+xiHvd6eBx/qPr9xqfBFDT8P2vWsvvz4jbEkfDe71W3VyNu2w==} - fastq@1.19.1: - resolution: {integrity: sha512-GwLTyxkCXjXbxqIhTsMI2Nui8huMPtnxg7krajPJAjnEG/iiOS7i+zCtWGZR9G0NBKbXKh6X9m9UIsYX/N6vvQ==} + char-regex@1.0.2: + resolution: {integrity: sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw==} + engines: {node: '>=10'} - fdir@6.5.0: - resolution: {integrity: sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==} - engines: {node: '>=12.0.0'} - peerDependencies: - picomatch: ^3 || ^4 - peerDependenciesMeta: - picomatch: - optional: true + character-entities-html4@2.1.0: + resolution: {integrity: sha512-1v7fgQRj6hnSwFpq1Eu0ynr/CDEw0rXo2B61qXrLNdHZmPKgb7fqS1a2JwF0rISo9q77jDI8VMEHoApn8qDoZA==} - fetch-blob@3.2.0: - resolution: {integrity: sha512-7yAQpD2UMJzLi1Dqv7qFYnPbaPx7ZfFK6PiIxQ4PfkGPyNyl2Ugx+a/umUonmKqjhM4DnfbMvdX6otXq83soQQ==} - engines: {node: ^12.20 || >= 14.13} + character-entities-legacy@3.0.0: + resolution: {integrity: sha512-RpPp0asT/6ufRm//AJVwpViZbGM/MkjQFxJccQRHmISF/22NBtsHqAWmL+/pmkPWoIUJdWyeVleTl1wydHATVQ==} - figures@3.2.0: - resolution: {integrity: sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==} - engines: {node: '>=8'} + character-entities@2.0.2: + resolution: {integrity: sha512-shx7oQ0Awen/BRIdkjkvz54PnEEI/EjwXDSIZp86/KKdbafHh1Df/RYGBhn4hbe2+uKC9FnT5UCEdyPz3ai9hQ==} - file-entry-cache@8.0.0: - resolution: {integrity: sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ==} - engines: {node: '>=16.0.0'} + chardet@0.7.0: + resolution: {integrity: sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==} - fill-range@7.1.1: - resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==} - engines: {node: '>=8'} + chardet@2.1.1: + resolution: {integrity: sha512-PsezH1rqdV9VvyNhxxOW32/d75r01NY7TQCmOqomRo15ZSOKbpTFVsfjghxo6JloQUCGnH4k1LGu0R4yCLlWQQ==} - finalhandler@1.1.2: - resolution: {integrity: sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA==} - engines: {node: '>= 0.8'} + check-error@2.1.1: + resolution: {integrity: sha512-OAlb+T7V4Op9OwdkjmguYRqncdlx5JiofwOAUkmTF+jNdHwzTaTs4sRAGpzLF3oOz5xAyDGrPgeIDFQmDOTiJw==} + engines: {node: '>= 16'} - finalhandler@1.3.2: - resolution: {integrity: sha512-aA4RyPcd3badbdABGDuTXCMTtOneUCAYH/gxoYRTZlIJdF0YPWuGqiAsIrhNnnqdXGswYk6dGujem4w80UJFhg==} - engines: {node: '>= 0.8'} + chokidar@3.5.3: + resolution: {integrity: sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==} + engines: {node: '>= 8.10.0'} - find-cache-dir@3.3.2: - resolution: {integrity: sha512-wXZV5emFEjrridIgED11OoUKLxiYjAcqot/NJdAkOhlJ+vGzwhOAfcG5OX1jP+S0PcjEn8bdMJv+g2jwQ3Onig==} - engines: {node: '>=8'} + chokidar@3.6.0: + resolution: {integrity: sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==} + engines: {node: '>= 8.10.0'} - find-replace@3.0.0: - resolution: {integrity: sha512-6Tb2myMioCAgv5kfvP5/PkZZ/ntTpVK39fHY7WkWBgvbeE+VHd/tZuZ4mrC+bxh4cfOZeYKVPaJIZtZXV7GNCQ==} - engines: {node: '>=4.0.0'} + chokidar@4.0.0: + resolution: {integrity: sha512-mxIojEAQcuEvT/lyXq+jf/3cO/KoA6z4CeNDGGevTybECPOMFCnQy3OPahluUkbqgPNGw5Bi78UC7Po6Lhy+NA==} + engines: {node: '>= 14.16.0'} - find-up@1.1.2: - resolution: {integrity: sha512-jvElSjyuo4EMQGoTwo1uJU5pQMwTW5lS1x05zzfJuTIyLR3zwO27LYrxNg+dlvKpGOuGy/MzBdXh80g0ve5+HA==} - engines: {node: '>=0.10.0'} + chokidar@4.0.3: + resolution: {integrity: sha512-Qgzu8kfBvo+cA4962jnP1KkS6Dop5NS6g7R5LFYJr4b8Ub94PPQXUksCw9PvXoeXPRRddRNC5C1JQUR2SMGtnA==} + engines: {node: '>= 14.16.0'} - find-up@4.1.0: - resolution: {integrity: sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==} - engines: {node: '>=8'} + chokidar@5.0.0: + resolution: {integrity: sha512-TQMmc3w+5AxjpL8iIiwebF73dRDF4fBIieAqGn9RGCWaEVwQ6Fb2cGe31Yns0RRIzii5goJ1Y7xbMwo1TxMplw==} + engines: {node: '>= 20.19.0'} - find-up@5.0.0: - resolution: {integrity: sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==} + chownr@2.0.0: + resolution: {integrity: sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==} engines: {node: '>=10'} - flag@5.0.1: - resolution: {integrity: sha512-4P/rvPGKcFBneboyYHMOKbKaJL5ZhNjScbY7bGToas7FgBvrTWbh76yxRaoSoFe3HSjWc6IJ0EajUwSadcP6Lg==} - peerDependencies: - react: ^18 + chownr@3.0.0: + resolution: {integrity: sha512-+IxzY9BZOQd/XuYPRmrvEVjF/nqj5kgT4kEq7VofrDoM1MxoRjEWkrCC3EtLi59TVawxTAn+orJwFQcrqEN1+g==} + engines: {node: '>=18'} - flat-cache@4.0.1: - resolution: {integrity: sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw==} - engines: {node: '>=16'} + ci-info@2.0.0: + resolution: {integrity: sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ==} - flat@5.0.2: - resolution: {integrity: sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==} - hasBin: true + ci-info@3.9.0: + resolution: {integrity: sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==} + engines: {node: '>=8'} - flatted@3.4.2: - resolution: {integrity: sha512-PjDse7RzhcPkIJwy5t7KPWQSZ9cAbzQXcafsetQoD7sOJRQlGikNbx7yZp2OotDnJyrDcbyRq3Ttb18iYOqkxA==} + cipher-base@1.0.4: + resolution: {integrity: sha512-Kkht5ye6ZGmwv40uUDZztayT2ThLQGfnj/T71N/XzeZeo3nf8foyW7zGTsPYkEya3m5f3cAypH+qe7YOrM1U2Q==} - fmix@0.1.0: - resolution: {integrity: sha512-Y6hyofImk9JdzU8k5INtTXX1cu8LDlePWDFU5sftm9H+zKCr5SGrVjdhkvsim646cw5zD0nADj8oHyXMZmCZ9w==} + citty@0.1.6: + resolution: {integrity: sha512-tskPPKEs8D2KPafUypv2gxwJP8h/OaJmC82QQGGDQcHvXX43xF2VDACcJVmZ0EuSxkpO9Kc4MlrA3q0+FG58AQ==} - follow-redirects@1.16.0: - resolution: {integrity: sha512-y5rN/uOsadFT/JfYwhxRS5R7Qce+g3zG97+JrtFZlC9klX/W5hD7iiLzScI4nZqUS7DNUdhPgw4xI8W2LuXlUw==} - engines: {node: '>=4.0'} - peerDependencies: - debug: '*' - peerDependenciesMeta: - debug: - optional: true + cjs-module-lexer@1.2.3: + resolution: {integrity: sha512-0TNiGstbQmCFwt4akjjBg5pLRTSyj/PkWQ1ZoO2zntmg9yLqSRxwEa4iCfQLGjqhiqBfOJa7W/E8wfGrTDmlZQ==} - for-each@0.3.5: - resolution: {integrity: sha512-dKx12eRCVIzqCxFGplyFKJMPvLEWgmNtUrpTiJIR5u97zEhRG8ySrtboPHZXx7daLxQVrl643cTzbab2tkQjxg==} - engines: {node: '>= 0.4'} + cjs-module-lexer@1.4.1: + resolution: {integrity: sha512-cuSVIHi9/9E/+821Qjdvngor+xpnlwnuwIyZOaLmHBVdXL+gP+I6QQB9VkO7RI77YIcTV+S1W9AreJ5eN63JBA==} - foreground-child@2.0.0: - resolution: {integrity: sha512-dCIq9FpEcyQyXKCkyzmlPTFNgrCzPudOe+mhvJU5zAtlBnGVy2yKxtfsxK2tQBThwq225jcvBjpw1Gr40uzZCA==} - engines: {node: '>=8.0.0'} + class-variance-authority@0.7.1: + resolution: {integrity: sha512-Ka+9Trutv7G8M6WT6SeiRWz792K5qEqIGEGzXKhAE6xOWAY6pPH8U+9IY3oCMv6kqTmLsv7Xh/2w2RigkePMsg==} - foreground-child@3.3.1: - resolution: {integrity: sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==} - engines: {node: '>=14'} + clean-stack@2.2.0: + resolution: {integrity: sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==} + engines: {node: '>=6'} - forever-agent@0.6.1: - resolution: {integrity: sha512-j0KLYPhm6zeac4lz3oJ3o65qvgQCcPubiyotZrXqEaG4hNagNYO8qdlUrX5vwqv9ohqeT/Z3j6+yW067yWWdUw==} + cli-boxes@2.2.1: + resolution: {integrity: sha512-y4coMcylgSCdVinjiDBuR8PCC2bLjyGTwEmPb9NHR/QaNU6EUOXcTY/s6VjGMD6ENSEaeQYHCY0GNGS5jfMwPw==} + engines: {node: '>=6'} - form-data-encoder@1.7.1: - resolution: {integrity: sha512-EFRDrsMm/kyqbTQocNvRXMLjc7Es2Vk+IQFx/YW7hkUH1eBl4J1fqiP34l74Yt0pFLCNpc06fkbVk00008mzjg==} + cli-highlight@2.1.11: + resolution: {integrity: sha512-9KDcoEVwyUXrjcJNvHD0NFc/hiwe/WPVYIleQh2O1N2Zro5gWJZ/K+3DGn8w8P/F6FxOgzyC5bxDyHIgCSPhGg==} + engines: {node: '>=8.0.0', npm: '>=5.0.0'} + hasBin: true - form-data@4.0.5: - resolution: {integrity: sha512-8RipRLol37bNs2bhoV67fiTEvdTrbMUYcFTiy3+wuuOnUog2QBHCZWXDRijWQfAkhBj2Uf5UnVaiWwA5vdd82w==} - engines: {node: '>= 6'} + cli-spinners@2.9.2: + resolution: {integrity: sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg==} + engines: {node: '>=6'} - formdata-polyfill@4.0.10: - resolution: {integrity: sha512-buewHzMvYL29jdeQTVILecSaZKnt/RJWjoZCF5OW60Z67/GmSLBkOFM7qh1PI3zFNtJbaZL5eQu1vLfazOwj4g==} - engines: {node: '>=12.20.0'} + cli-table3@0.6.5: + resolution: {integrity: sha512-+W/5efTR7y5HRD7gACw9yQjqMVvEMLBHmboM/kPWam+H+Hmyrgjh6YncVKK122YZkXrLudzTuAukUw9FnMf7IQ==} + engines: {node: 10.* || >= 12.*} - forwarded@0.2.0: - resolution: {integrity: sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==} - engines: {node: '>= 0.6'} + cli-width@4.1.0: + resolution: {integrity: sha512-ouuZd4/dm2Sw5Gmqy6bGyNNNe1qt9RpmxveLSO7KcgsTnU7RXfsw+/bukWGo1abgBiMAic068rclZsO4IWmmxQ==} + engines: {node: '>= 12'} - fp-ts@1.19.3: - resolution: {integrity: sha512-H5KQDspykdHuztLTg+ajGN0Z2qUjcEf3Ybxc6hLt0k7/zPkn29XnKnxlBPyW2XIddWrGaJBzBl4VLYOtk39yZg==} + client-only@0.0.1: + resolution: {integrity: sha512-IV3Ou0jSMzZrd3pZ48nLkT9DA7Ag1pnPzaiQhpW7c3RbcqqzvzzVu+L8gfqMp/8IM2MQtSiqaCxrrcfu8I8rMA==} - fresh@0.5.2: - resolution: {integrity: sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q==} - engines: {node: '>= 0.6'} + clipboardy@4.0.0: + resolution: {integrity: sha512-5mOlNS0mhX0707P2I0aZ2V/cmHUEO/fL7VFLqszkhUsxt7RwnmrInf/eEQKlf5GzvYeHIjT+Ov1HRfNmymlG0w==} + engines: {node: '>=18'} - fromentries@1.3.2: - resolution: {integrity: sha512-cHEpEQHUg0f8XdtZCc2ZAhrHzKzT0MrFUTcvx+hfxYu7rGMDc5SKoXFh+n4YigxsHXRzc6OrCshdR1bWH6HHyg==} + cliui@6.0.0: + resolution: {integrity: sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ==} - fs-extra@0.30.0: - resolution: {integrity: sha512-UvSPKyhMn6LEd/WpUaV9C9t3zATuqoqfWc3QdPhPLb58prN9tqYPlPWi8Krxi44loBoUzlobqZ3+8tGpxxSzwA==} + cliui@7.0.4: + resolution: {integrity: sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==} - fs-extra@10.1.0: - resolution: {integrity: sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==} + cliui@8.0.1: + resolution: {integrity: sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==} engines: {node: '>=12'} - fs-extra@4.0.3: - resolution: {integrity: sha512-q6rbdDd1o2mAnQreO7YADIxf/Whx4AHBiRf6d+/cVT8h44ss+lHgxf1FemcqDnQt9X3ct4McHr+JMGlYSsK7Cg==} + clone@1.0.4: + resolution: {integrity: sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg==} + engines: {node: '>=0.8'} - fs-extra@7.0.1: - resolution: {integrity: sha512-YJDaCJZEnBmcbw13fvdAM9AwNOJwOzrE4pqMqBq5nFiEqXUqHwlK4B+3pUw6JNvfSPtX05xFHtYy/1ni01eGCw==} - engines: {node: '>=6 <7 || >=8'} + clsx@1.2.1: + resolution: {integrity: sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg==} + engines: {node: '>=6'} - fs-extra@8.1.0: - resolution: {integrity: sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==} - engines: {node: '>=6 <7 || >=8'} + clsx@2.1.1: + resolution: {integrity: sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA==} + engines: {node: '>=6'} - fs-minipass@3.0.3: - resolution: {integrity: sha512-XUBA9XClHbnJWSfBzjkm6RvPsyg3sryZt06BEQoXcF7EK/xpGaQYJgQKDJSUH5SGZ76Y7pFx1QBnXz09rU5Fbw==} - engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} + cluster-key-slot@1.1.2: + resolution: {integrity: sha512-RMr0FhtfXemyinomL4hrWcYJxmX6deFdCxpJzhDttxgO1+bcCnkk+9drydLVDmAMG7NE6aN/fl4F7ucU/90gAA==} + engines: {node: '>=0.10.0'} - fs-readdir-recursive@1.1.0: - resolution: {integrity: sha512-GNanXlVr2pf02+sPN40XN8HG+ePaNcvM0q5mZBd668Obwb0yD5GiUbZOFgwn8kGMY6I3mdyDJzieUy3PTYyTRA==} + code-block-writer@10.1.1: + resolution: {integrity: sha512-67ueh2IRGst/51p0n6FvPrnRjAGHY5F8xdjkgrYE7DDzpJe6qA07RYQ9VcoUeo5ATOjSOiWpSL3SWBRRbempMw==} - fs.realpath@1.0.0: - resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} + color-convert@1.9.3: + resolution: {integrity: sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==} - fsevents@2.3.3: - resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} - engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} - os: [darwin] + color-convert@2.0.1: + resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==} + engines: {node: '>=7.0.0'} - function-bind@1.1.2: - resolution: {integrity: sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==} + color-name@1.1.3: + resolution: {integrity: sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==} - function.prototype.name@1.1.8: - resolution: {integrity: sha512-e5iwyodOHhbMr/yNrc7fDYG4qlbIvI5gajyzPnb5TCwyhjApznQh1BMFou9b30SevY43gCJKXycoCBjMbsuW0Q==} - engines: {node: '>= 0.4'} + color-name@1.1.4: + resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==} - functional-red-black-tree@1.0.1: - resolution: {integrity: sha512-dsKNQNdj6xA3T+QlADDA7mOSlX0qiMINjn0cgr+eGHGsbSHzTabcIogz2+p/iqP1Xs6EP/sS2SbqH+brGTbq0g==} + colord@2.9.3: + resolution: {integrity: sha512-jeC1axXpnb0/2nn/Y1LPuLdgXBLH7aDcHu4KEKfqw3CUhX7ZpfBSlPKyqXE6btIgEzfWtrX3/tyBCaCvXvMkOw==} - functions-have-names@1.2.3: - resolution: {integrity: sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==} + colorette@2.0.20: + resolution: {integrity: sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==} - ganache-cli@6.12.2: - resolution: {integrity: sha512-bnmwnJDBDsOWBUP8E/BExWf85TsdDEFelQSzihSJm9VChVO1SHp94YXLP5BlA4j/OTxp0wR4R1Tje9OHOuAJVw==} - deprecated: ganache-cli is now ganache; visit https://trfl.io/g7 for details - hasBin: true - bundledDependencies: - - source-map-support - - yargs - - ethereumjs-util + comma-separated-tokens@2.0.3: + resolution: {integrity: sha512-Fu4hJdvzeylCfQPp9SGWidpzrMs7tTrlu6Vb8XGaRGck8QSNZJJp538Wrb60Lax4fPwR64ViY468OIUTbRlGZg==} - ganache@7.4.3: - resolution: {integrity: sha512-RpEDUiCkqbouyE7+NMXG26ynZ+7sGiODU84Kz+FVoXUnQ4qQM4M8wif3Y4qUCt+D/eM1RVeGq0my62FPD6Y1KA==} - hasBin: true - bundledDependencies: - - '@trufflesuite/bigint-buffer' - - emittery - - keccak - - leveldown - - secp256k1 - - '@types/bn.js' - - '@types/lru-cache' - - '@types/seedrandom' - - ganache@7.9.2: - resolution: {integrity: sha512-7gsVVDpO9AhrFyDMWWl7SpMsPpqGcnAzjxz3k32LheIPNd64p2XsY9GYRdhWmKuryb60W1iaWPZWDkFKlbRWHA==} - hasBin: true - bundledDependencies: - - '@trufflesuite/bigint-buffer' - - keccak - - leveldown - - secp256k1 + command-exists@1.2.9: + resolution: {integrity: sha512-LTQ/SGc+s0Xc0Fu5WaKnR0YiygZkm9eKFvyS+fRsU7/ZWFF8ykFM6Pc9aCVf1+xasOOZpO3BAVgVrKvsqKHV7w==} - generator-function@2.0.1: - resolution: {integrity: sha512-SFdFmIJi+ybC0vjlHN0ZGVGHc3lgE0DxPAT0djjVg+kjOnSqclqmj0KQ7ykTOLP6YxoqOvuAODGdcHJn+43q3g==} - engines: {node: '>= 0.4'} + commander@10.0.1: + resolution: {integrity: sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==} + engines: {node: '>=14'} - gensync@1.0.0-beta.2: - resolution: {integrity: sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==} - engines: {node: '>=6.9.0'} + commander@11.1.0: + resolution: {integrity: sha512-yPVavfyCcRhmorC7rWlkHn15b4wDVgVmBA7kV4QVBsF7kv/9TKJAbAXVTxvTnwP8HHKjRCJDClKbciiYS7p0DQ==} + engines: {node: '>=16'} - get-caller-file@1.0.3: - resolution: {integrity: sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w==} + commander@2.20.3: + resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==} - get-caller-file@2.0.5: - resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} - engines: {node: 6.* || 8.* || >= 10.*} + commander@3.0.2: + resolution: {integrity: sha512-Gar0ASD4BDyKC4hl4DwHqDrmvjoxWKZigVnAbn5H1owvm4CxCPdb0HQDehwNYMJpla5+M2tPmPARzhtYuwpHow==} - get-east-asian-width@1.4.0: - resolution: {integrity: sha512-QZjmEOC+IT1uk6Rx0sX22V6uHWVwbdbxf1faPqJ1QhLdGgsRGCZoyaQBm/piRdJy/D2um6hM1UP7ZEeQ4EkP+Q==} - engines: {node: '>=18'} + commander@4.1.1: + resolution: {integrity: sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA==} + engines: {node: '>= 6'} - get-func-name@2.0.2: - resolution: {integrity: sha512-8vXOvuE167CtIc3OyItco7N/dpRtBbYOsPsXCz7X/PMnlGjYjSGuZJgM1Y7mmew7BKf9BqvLX2tnOVy1BBUsxQ==} + commander@7.2.0: + resolution: {integrity: sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==} + engines: {node: '>= 10'} - get-intrinsic@1.3.0: - resolution: {integrity: sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==} - engines: {node: '>= 0.4'} + commondir@1.0.1: + resolution: {integrity: sha512-W9pAhw0ja1Edb5GVdIF1mjZw/ASI0AlShXM83UUGe2DVr5TdAPEA1OA8m/g8zWp9x6On7gqufY+FatDbC3MDQg==} - get-package-type@0.1.0: - resolution: {integrity: sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==} - engines: {node: '>=8.0.0'} + compatx@0.2.0: + resolution: {integrity: sha512-6gLRNt4ygsi5NyMVhceOCFv14CIdDFN7fQjX1U4+47qVE/+kjPoXMK65KWK+dWxmFzMTuKazoQ9sch6pM0p5oA==} - get-port@3.2.0: - resolution: {integrity: sha512-x5UJKlgeUiNT8nyo/AcnwLnZuZNcSjSw0kogRB+Whd1fjjFq4B1hySFxSFWWSn4mIBzg3sRNUDFYc4g5gjPoLg==} - engines: {node: '>=4'} + compress-commons@6.0.2: + resolution: {integrity: sha512-6FqVXeETqWPoGcfzrXb37E50NP0LXT8kAMu5ooZayhWWdgEY4lBEEcbQNXtkuKQsGduxiIcI4gOTsxTmuq/bSg==} + engines: {node: '>= 14'} - get-proto@1.0.1: - resolution: {integrity: sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==} - engines: {node: '>= 0.4'} + computeds@0.0.1: + resolution: {integrity: sha512-7CEBgcMjVmitjYo5q8JTJVra6X5mQ20uTThdK+0kR7UEaDrAWEQcRiBtWJzga4eRpP6afNwwLsX2SET2JhVB1Q==} - get-stream@5.2.0: - resolution: {integrity: sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==} + concat-map@0.0.1: + resolution: {integrity: sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==} + + confbox@0.1.7: + resolution: {integrity: sha512-uJcB/FKZtBMCJpK8MQji6bJHgu1tixKPxRLeGkNzBoOZzpnZUJm0jm2/sBDWcuBx1dYgxV4JU+g5hmNxCyAmdA==} + + confbox@0.1.8: + resolution: {integrity: sha512-RMtmw0iFkeR4YV+fUOSucriAQNb9g8zFR52MWCtl+cCZOFRNL6zeB395vPzFhEjjn4fMxXudmELnl/KF/WrK6w==} + + confbox@0.2.2: + resolution: {integrity: sha512-1NB+BKqhtNipMsov4xI/NnhCKp9XG9NamYp5PVm9klAT0fsrNPjaFICsCFhNhwZJKNh7zB/3q8qXz0E9oaMNtQ==} + + config-chain@1.1.13: + resolution: {integrity: sha512-qj+f8APARXHrM0hraqXYb2/bOVSV4PvJQlNZ/DVj0QrmNM2q2euizkeuVckQ57J+W0mRH6Hvi+k50M4Jul2VRQ==} + + consola@3.2.3: + resolution: {integrity: sha512-I5qxpzLv+sJhTVEoLYNcTW+bThDCPsit0vLNKShZx6rLtpilNpmmeTPaeqJb9ZE9dV3DGaeby6Vuhrw38WjeyQ==} + engines: {node: ^14.18.0 || >=16.10.0} + + consola@3.4.2: + resolution: {integrity: sha512-5IKcdX0nnYavi6G7TtOhwkYzyjfJlatbjMjuLSfE2kYT5pMDOilZ4OvMhi637CcDICTmz3wARPoyhqyX1Y+XvA==} + engines: {node: ^14.18.0 || >=16.10.0} + + content-type@1.0.4: + resolution: {integrity: sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA==} + engines: {node: '>= 0.6'} + + convert-hrtime@3.0.0: + resolution: {integrity: sha512-7V+KqSvMiHp8yWDuwfww06XleMWVVB9b9tURBx+G7UTADuo5hYPuowKloz4OzOqbPezxgo+fdQ1522WzPG4OeA==} engines: {node: '>=8'} - get-stream@6.0.1: - resolution: {integrity: sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==} - engines: {node: '>=10'} + convert-source-map@2.0.0: + resolution: {integrity: sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==} - get-symbol-description@1.1.0: - resolution: {integrity: sha512-w9UMqWwJxHNOvoNzSJ2oPF5wvYcvP7jUvYzhp67yEhTi17ZDBBC1z9pTdGuzjD+EFIqLSYRweZjqfiPzQ06Ebg==} - engines: {node: '>= 0.4'} + cookie-es@1.2.2: + resolution: {integrity: sha512-+W7VmiVINB+ywl1HGXJXmrqkOhpKrIiVZV6tQuV54ZyQC7MMuBt81Vc336GMLoHBq5hV/F9eXgt5Mnx0Rha5Fg==} - get-uri@6.0.5: - resolution: {integrity: sha512-b1O07XYq8eRuVzBNgJLstU6FYc1tS6wnMtF1I1D9lE8LxZSOGZ7LhxN54yPP6mGw5f2CkXY2BQUL9Fx41qvcIg==} - engines: {node: '>= 14'} + cookie-es@2.0.0: + resolution: {integrity: sha512-RAj4E421UYRgqokKUmotqAwuplYw15qtdXfY+hGzgCJ/MBjCVZcSoHK/kH9kocfjRjcDME7IiDWR/1WX1TM2Pg==} - getpass@0.1.7: - resolution: {integrity: sha512-0fzj9JxOLfJ+XGLhR8ze3unN0KZCgZwiSSDz168VERjK8Wl8kVSdcu2kspd4s4wtAa1y/qrVRiAA0WclVsu0ng==} + cookie@0.4.2: + resolution: {integrity: sha512-aSWTXFzaKWkvHO1Ny/s+ePFpvKsPnjc551iI41v3ny/ow6tBG5Vd+FuqGNhh1LxOmVzOlGUriIlOaokOvhaStA==} + engines: {node: '>= 0.6'} - ghost-testrpc@0.0.2: - resolution: {integrity: sha512-i08dAEgJ2g8z5buJIrCTduwPIhih3DP+hOCTyyryikfV8T0bNvHnGXO67i0DD1H4GBDETTclPy9njZbfluQYrQ==} - hasBin: true + cookie@0.5.0: + resolution: {integrity: sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==} + engines: {node: '>= 0.6'} - glob-parent@5.1.2: - resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==} - engines: {node: '>= 6'} + copy-anything@3.0.5: + resolution: {integrity: sha512-yCEafptTtb4bk7GLEQoM8KVJpxAfdBJYaXyzQEgQQQgYrZiDp8SJmGKlYza6CYjEDNstAdNdKA3UuoULlEbS6w==} + engines: {node: '>=12.13'} - glob-parent@6.0.2: - resolution: {integrity: sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==} - engines: {node: '>=10.13.0'} + copy-anything@4.0.5: + resolution: {integrity: sha512-7Vv6asjS4gMOuILabD3l739tsaxFQmC+a7pLZm02zyvs8p977bL3zEgq3yDk5rn9B0PbYgIv++jmHcuUab4RhA==} + engines: {node: '>=18'} - glob@10.5.0: - resolution: {integrity: sha512-DfXN8DfhJ7NH3Oe7cFmu3NCu1wKbkReJ8TorzSAFbSKrlNaQSKfIzqYqVY8zlbs2NLBbWpRiU52GX2PbaBVNkg==} - deprecated: Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me + copy-paste@2.2.0: + resolution: {integrity: sha512-jqSL4r9DSeiIvJZStLzY/sMLt9ToTM7RsK237lYOTG+KcbQJHGala3R1TUpa8h1p9adswVgIdV4qGbseVhL4lg==} + + core-util-is@1.0.3: + resolution: {integrity: sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==} + + crc-32@1.2.2: + resolution: {integrity: sha512-ROmzCKrTnOwybPcJApAA6WBWij23HVfGVNKqqrZpuyZOHqK2CwHSvpGuyt/UNNvaIjEd8X5IFGp4Mh+Ie1IHJQ==} + engines: {node: '>=0.8'} hasBin: true - glob@13.0.6: - resolution: {integrity: sha512-Wjlyrolmm8uDpm/ogGyXZXb1Z+Ca2B8NbJwqBVg0axK9GbBeoS7yGV6vjXnYdGm6X53iehEuxxbyiKp8QmN4Vw==} - engines: {node: 18 || 20 || >=22} + crc32-stream@6.0.0: + resolution: {integrity: sha512-piICUB6ei4IlTv1+653yq5+KoqfBYmj9bw6LqXoOneTMDXk5nM1qt12mFW1caG3LlJXEKW1Bp0WggEmIfQB34g==} + engines: {node: '>= 14'} - glob@5.0.15: - resolution: {integrity: sha512-c9IPMazfRITpmAAKi22dK1VKxGDX9ehhqfABDriL/lzO92xcUKEJPQHrVA/2YHSNFB4iFlykVmWvwo48nr3OxA==} - deprecated: Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me + create-hash@1.2.0: + resolution: {integrity: sha512-z00bCGNHDG8mHAkP7CtT1qVu+bFQUPjYq/4Iv3C3kWjTFV10zIjfSoeqXo9Asws8gwSHDGj/hl2u4OGIjapeCg==} - glob@7.1.7: - resolution: {integrity: sha512-OvD9ENzPLbegENnYP5UUfJIirTg4+XwMWGaQfQTY0JenxNvvIKP3U3/tAQSPIu/lHxXYSZmpXlUHeqAIdKzBLQ==} - deprecated: Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me + create-hmac@1.1.7: + resolution: {integrity: sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg==} - glob@7.2.3: - resolution: {integrity: sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==} - deprecated: Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me + create-require@1.1.1: + resolution: {integrity: sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==} - glob@8.1.0: - resolution: {integrity: sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ==} - engines: {node: '>=12'} - deprecated: Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me + croner@9.1.0: + resolution: {integrity: sha512-p9nwwR4qyT5W996vBZhdvBCnMhicY5ytZkR4D1Xj0wuTDEiMnjwR57Q3RXYY/s0EpX6Ay3vgIcfaR+ewGHsi+g==} + engines: {node: '>=18.0'} - global-modules@2.0.0: - resolution: {integrity: sha512-NGbfmJBp9x8IxyJSd1P+otYK8vonoJactOogrVfFRIAEY1ukil8RSKDz2Yo7wh1oihl51l/r6W4epkeKJHqL8A==} - engines: {node: '>=6'} + cross-fetch@3.2.0: + resolution: {integrity: sha512-Q+xVJLoGOeIMXZmbUK4HYk+69cQH6LudR0Vu/pRm2YlU/hDV9CiS0gKUMaWY5f2NeUH9C1nV3bsTlCo0FsTV1Q==} - global-prefix@3.0.0: - resolution: {integrity: sha512-awConJSVCHVGND6x3tmMaKcQvwXLhjdkmomy2W+Goaui8YPgYgXJZewhg3fWC+DlfqqQuWg8AwqjGTD2nAPVWg==} - engines: {node: '>=6'} + cross-fetch@4.1.0: + resolution: {integrity: sha512-uKm5PU+MHTootlWEY+mZ4vvXoCn4fLQxT9dSc1sXVMSFkINTJVN8cAQROpwcKm8bJ/c7rgZVIBWzH5T78sNZZw==} - global@4.4.0: - resolution: {integrity: sha512-wv/LAoHdRE3BeTGz53FAamhGlPLhlssK45usmGFThIi4XqnBmjKQ16u+RNbP7WvigRZDxUsM0J3gcQ5yicaL0w==} + cross-spawn@5.1.0: + resolution: {integrity: sha512-pTgQJ5KC0d2hcY8eyL1IzlBPYjTkyH72XRZPnLyKus2mBfNjQs3klqbJU2VILqZryAZUt9JOb3h/mWMy23/f5A==} - globals@14.0.0: - resolution: {integrity: sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==} - engines: {node: '>=18'} + cross-spawn@7.0.6: + resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==} + engines: {node: '>= 8'} - globals@16.5.0: - resolution: {integrity: sha512-c/c15i26VrJ4IRt5Z89DnIzCGDn9EcebibhAOjw5ibqEHsE1wLUgkPn9RDmNcUKyU87GeaL633nyJ+pplFR2ZQ==} - engines: {node: '>=18'} + crossws@0.2.4: + resolution: {integrity: sha512-DAxroI2uSOgUKLz00NX6A8U/8EE3SZHmIND+10jkVSaypvyt57J5JEOxAQOL6lQxyzi/wZbTIwssU1uy69h5Vg==} + peerDependencies: + uWebSockets.js: '*' + peerDependenciesMeta: + uWebSockets.js: + optional: true - globalthis@1.0.4: - resolution: {integrity: sha512-DpLKbNU4WylpxJykQujfCcwYWiV/Jhm50Goo0wrVILAv5jOr9d+H+UR3PhSCD2rCCEIg0uc+G+muBTwD54JhDQ==} - engines: {node: '>= 0.4'} + crossws@0.3.5: + resolution: {integrity: sha512-ojKiDvcmByhwa8YYqbQI/hg7MEU0NC03+pSdEq4ZUnZR9xXpwk7E43SMNGkn+JxJGPFtNvQ48+vV2p+P1ml5PA==} - globby@10.0.2: - resolution: {integrity: sha512-7dUi7RvCoT/xast/o/dLN53oqND4yk0nsHkhRgn9w65C4PofCLOoJ39iSOg+qVDdWQPIEj+eszMHQ+aLVwwQSg==} - engines: {node: '>=8'} + crypto-random-string@1.0.0: + resolution: {integrity: sha512-GsVpkFPlycH7/fRR7Dhcmnoii54gV1nz7y4CWyeFS14N+JVBBhY+r8amRHE4BwSYal7BPTDp8isvAlCxyFt3Hg==} + engines: {node: '>=4'} - globby@11.1.0: - resolution: {integrity: sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==} - engines: {node: '>=10'} + css-declaration-sorter@7.3.0: + resolution: {integrity: sha512-LQF6N/3vkAMYF4xoHLJfG718HRJh34Z8BnNhd6bosOMIVjMlhuZK5++oZa3uYAgrI5+7x2o27gUqTR2U/KjUOQ==} + engines: {node: ^14 || ^16 || >=18} + peerDependencies: + postcss: ^8.0.9 - gopd@1.2.0: - resolution: {integrity: sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==} - engines: {node: '>= 0.4'} + css-select@5.2.2: + resolution: {integrity: sha512-TizTzUddG/xYLA3NXodFM0fSbNizXjOKhqiQQwvhlspadZokn1KDy0NZFS0wuEubIYAV5/c1/lAr0TaaFXEXzw==} - got@11.8.6: - resolution: {integrity: sha512-6tfZ91bOr7bOXnK7PRDCGBLa1H4U080YHNaAQ2KsMGlLEzRbk44nsZF2E1IeRc3vtJHPVbKCYgdFbaGO2ljd8g==} - engines: {node: '>=10.19.0'} + css-tree@2.2.1: + resolution: {integrity: sha512-OA0mILzGc1kCOCSJerOeqDxDQ4HOh+G8NbOJFOTgOCzpw7fCBubk0fEyxp8AgOL/jvLgYA/uV0cMbe43ElF1JA==} + engines: {node: ^10 || ^12.20.0 || ^14.13.0 || >=15.0.0, npm: '>=7.0.0'} - got@12.1.0: - resolution: {integrity: sha512-hBv2ty9QN2RdbJJMK3hesmSkFTjVIHyIDDbssCKnSmq62edGgImJWD10Eb1k77TiV1bxloxqcFAVK8+9pkhOig==} - engines: {node: '>=14.16'} + css-tree@2.3.1: + resolution: {integrity: sha512-6Fv1DV/TYw//QF5IzQdqsNDjx/wc8TrMBZsqjL9eW01tWb7R7k/mq+/VXfJCl7SoD5emsJop9cOByJZfs8hYIw==} + engines: {node: ^10 || ^12.20.0 || ^14.13.0 || >=15.0.0} - graceful-fs@4.2.11: - resolution: {integrity: sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==} + css-tree@3.1.0: + resolution: {integrity: sha512-0eW44TGN5SQXU1mWSkKwFstI/22X2bG1nYzZTYMAWjylYURhse752YgbE4Cx46AC+bAvI+/dYTPRk1LqSUnu6w==} + engines: {node: ^10 || ^12.20.0 || ^14.13.0 || >=15.0.0} - gradient-string@2.0.2: - resolution: {integrity: sha512-rEDCuqUQ4tbD78TpzsMtt5OIf0cBCSDWSJtUDaF6JsAh+k0v9r++NzxNEG87oDZx9ZwGhD8DaezR2L/yrw0Jdw==} - engines: {node: '>=10'} + css-what@6.2.2: + resolution: {integrity: sha512-u/O3vwbptzhMs3L1fQE82ZSLHQQfto5gyZzwteVIEyeaY5Fc7R4dapF/BvRoSYFeqfBk4m0V1Vafq5Pjv25wvA==} + engines: {node: '>= 6'} - graphql-http@1.22.4: - resolution: {integrity: sha512-OC3ucK988teMf+Ak/O+ZJ0N2ukcgrEurypp8ePyJFWq83VzwRAmHxxr+XxrMpxO/FIwI4a7m/Fzv3tWGJv0wPA==} - engines: {node: '>=12'} + cssesc@3.0.0: + resolution: {integrity: sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg==} + engines: {node: '>=4'} + hasBin: true + + cssnano-preset-default@7.0.10: + resolution: {integrity: sha512-6ZBjW0Lf1K1Z+0OKUAUpEN62tSXmYChXWi2NAA0afxEVsj9a+MbcB1l5qel6BHJHmULai2fCGRthCeKSFbScpA==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} peerDependencies: - graphql: '>=0.11 <=16' + postcss: ^8.4.32 - graphql-subscriptions@1.2.1: - resolution: {integrity: sha512-95yD/tKi24q8xYa7Q9rhQN16AYj5wPbrb8tmHGM3WRc9EBmWrG/0kkMl+tQG8wcEuE9ibR4zyOM31p5Sdr2v4g==} + cssnano-utils@5.0.1: + resolution: {integrity: sha512-ZIP71eQgG9JwjVZsTPSqhc6GHgEr53uJ7tK5///VfyWj6Xp2DBmixWHqJgPno+PqATzn48pL42ww9x5SSGmhZg==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} peerDependencies: - graphql: ^0.10.5 || ^0.11.3 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 + postcss: ^8.4.32 - graphql-tag@2.12.6: - resolution: {integrity: sha512-FdSNcu2QQcWnM2VNvSCCDCVS5PpPqpzgFT8+GXzqJuoDd0CBncxCY278u4mhRO7tMgo2JjgJA5aZ+nWSQ/Z+xg==} - engines: {node: '>=10'} + cssnano@7.1.2: + resolution: {integrity: sha512-HYOPBsNvoiFeR1eghKD5C3ASm64v9YVyJB4Ivnl2gqKoQYvjjN/G0rztvKQq8OxocUtC6sjqY8jwYngIB4AByA==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} peerDependencies: - graphql: ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 + postcss: ^8.4.32 - graphql@15.10.2: - resolution: {integrity: sha512-1PRqdDPAmViWr4h1GVBT8RoPZfWSGZa7kDzleTilOfVIslsgf+cia3Nl95v1KDmR4iERPaT7WzQ+tN4MJmbg3w==} - engines: {node: '>= 10.x'} + csso@5.0.5: + resolution: {integrity: sha512-0LrrStPOdJj+SPCCrGhzryycLjwcgUSHBtxNA8aIDxf0GLsRh1cKYhB00Gd1lDOS4yGH69+SNn13+TWbVHETFQ==} + engines: {node: ^10 || ^12.20.0 || ^14.13.0 || >=15.0.0, npm: '>=7.0.0'} - handlebars@4.7.8: - resolution: {integrity: sha512-vafaFqs8MZkRrSX7sFVUdo3ap/eNiLnb4IakshzvP56X5Nr1iGKAIqdX6tMlm6HcNRIkr6AxO5jFEoJzzpT8aQ==} - engines: {node: '>=0.4.7'} - hasBin: true + csstype@3.1.3: + resolution: {integrity: sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==} - handlebars@4.7.9: - resolution: {integrity: sha512-4E71E0rpOaQuJR2A3xDZ+GM1HyWYv1clR58tC8emQNeQe3RH7MAzSbat+V0wG78LQBo6m6bzSG/L4pBuCsgnUQ==} - engines: {node: '>=0.4.7'} - hasBin: true + csstype@3.2.3: + resolution: {integrity: sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==} - happy-dom@20.8.9: - resolution: {integrity: sha512-Tz23LR9T9jOGVZm2x1EPdXqwA37G/owYMxRwU0E4miurAtFsPMQ1d2Jc2okUaSjZqAFz2oEn3FLXC5a0a+siyA==} - engines: {node: '>=20.0.0'} + dataloader@1.4.0: + resolution: {integrity: sha512-68s5jYdlvasItOJnCuI2Q9s4q98g0pCyL3HrcKJu8KNugUl8ahgmZYg38ysLTgQjjXX3H8CJLkAvWrclWfcalw==} - har-schema@2.0.0: - resolution: {integrity: sha512-Oqluz6zhGX8cyRaTQlFMPw80bSJVG2x/cFb8ZPhUILGgHka9SsokCCOQgpveePerqidZOrT14ipqfJb7ILcW5Q==} - engines: {node: '>=4'} + date-fns@2.30.0: + resolution: {integrity: sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw==} + engines: {node: '>=0.11'} - har-validator@5.1.5: - resolution: {integrity: sha512-nmT2T0lljbxdQZfspsno9hgrG3Uir6Ks5afism62poxqBM6sDnMEuPmzTq8XN0OEwqKLLdh1jQI3qyE66Nzb3w==} - engines: {node: '>=6'} - deprecated: this library is no longer supported + dateformat@4.6.3: + resolution: {integrity: sha512-2P0p0pFGzHS5EMnhdxQi7aJN+iMheud0UhG4dlE1DLAlvL8JHjJJTX/CSm4JXwV0Ka5nGk3zC5mcb5bUQUxxMA==} - hardhat-deploy@0.11.45: - resolution: {integrity: sha512-aC8UNaq3JcORnEUIwV945iJuvBwi65tjHVDU3v6mOcqik7WAzHVCJ7cwmkkipsHrWysrB5YvGF1q9S1vIph83w==} + dayjs@1.11.13: + resolution: {integrity: sha512-oaMBel6gjolK862uaPQOVTA7q3TZhuSvuMQAAglQDOWYO9A91IrAOUJEyKVlqJlHE0vq5p5UXxzdPfMH/x6xNg==} - hardhat-gas-reporter@1.0.10: - resolution: {integrity: sha512-02N4+So/fZrzJ88ci54GqwVA3Zrf0C9duuTyGt0CFRIh/CdNwbnTgkXkRfojOMLBQ+6t+lBIkgbsOtqMvNwikA==} + db0@0.3.4: + resolution: {integrity: sha512-RiXXi4WaNzPTHEOu8UPQKMooIbqOEyqA1t7Z6MsdxSCeb8iUC9ko3LcmsLmeUt2SM5bctfArZKkRQggKZz7JNw==} peerDependencies: - hardhat: ^2.0.2 + '@electric-sql/pglite': '*' + '@libsql/client': '*' + better-sqlite3: '*' + drizzle-orm: '*' + mysql2: '*' + sqlite3: '*' + peerDependenciesMeta: + '@electric-sql/pglite': + optional: true + '@libsql/client': + optional: true + better-sqlite3: + optional: true + drizzle-orm: + optional: true + mysql2: + optional: true + sqlite3: + optional: true - hardhat@2.28.6: - resolution: {integrity: sha512-zQze7qe+8ltwHvhX5NQ8sN1N37WWZGw8L63y+2XcPxGwAjc/SMF829z3NS6o1krX0sryhAsVBK/xrwUqlsot4Q==} - hasBin: true + de-indent@1.0.2: + resolution: {integrity: sha512-e/1zu3xH5MQryN2zdVaF0OrdNLUbvWxzMbi+iNA6Bky7l1RoP8a2fIbRocyHclXt/arDrrR6lL3TqFD9pMQTsg==} + + debounce@1.2.1: + resolution: {integrity: sha512-XRRe6Glud4rd/ZGQfiV1ruXSfbvfJedlV9Y6zOlP+2K04vBYiJEte6stfFkCP03aMnY5tsipamumUjL14fofug==} + + debug@4.3.4: + resolution: {integrity: sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==} + engines: {node: '>=6.0'} peerDependencies: - ts-node: '*' - typescript: '*' + supports-color: '*' peerDependenciesMeta: - ts-node: + supports-color: optional: true - typescript: + + debug@4.4.1: + resolution: {integrity: sha512-KcKCqiftBJcZr++7ykoDIEwSa3XWowTfNPo92BYxjXiyYEVrUQh2aLyhxBCwww+heortUFxEJYcRzosstTEBYQ==} + engines: {node: '>=6.0'} + peerDependencies: + supports-color: '*' + peerDependenciesMeta: + supports-color: optional: true - has-bigints@1.1.0: - resolution: {integrity: sha512-R3pbpkcIqv2Pm3dUwgjclDRVmWpTJW2DcMzcIhEXEx1oh/CEMObMm3KLmRJOdvhM7o4uQBnwr8pzRK2sJWIqfg==} - engines: {node: '>= 0.4'} + debug@4.4.3: + resolution: {integrity: sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==} + engines: {node: '>=6.0'} + peerDependencies: + supports-color: '*' + peerDependenciesMeta: + supports-color: + optional: true - has-flag@1.0.0: - resolution: {integrity: sha512-DyYHfIYwAJmjAjSSPKANxI8bFY9YtFrgkAfinBojQ8YJTOuOuav64tMUJv584SES4xl74PmuaevIyaLESHdTAA==} + decamelize@1.2.0: + resolution: {integrity: sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==} engines: {node: '>=0.10.0'} - has-flag@3.0.0: - resolution: {integrity: sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==} - engines: {node: '>=4'} + decamelize@4.0.0: + resolution: {integrity: sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ==} + engines: {node: '>=10'} - has-flag@4.0.0: - resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} - engines: {node: '>=8'} + decode-named-character-reference@1.0.2: + resolution: {integrity: sha512-O8x12RzrUF8xyVcY0KJowWsmaJxQbmy0/EtnNtHRpsOcT7dFk5W598coHqBVpmWo1oQQfsCqfCmkZN5DJrZVdg==} - has-property-descriptors@1.0.2: - resolution: {integrity: sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==} + decode-uri-component@0.2.2: + resolution: {integrity: sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ==} + engines: {node: '>=0.10'} - has-proto@1.2.0: - resolution: {integrity: sha512-KIL7eQPfHQRC8+XluaIw7BHUwwqL19bQn4hzNgdr+1wXoU0KKj6rufu47lhY7KbJR2C6T6+PfyN0Ea7wkSS+qQ==} - engines: {node: '>= 0.4'} + dedent@1.6.0: + resolution: {integrity: sha512-F1Z+5UCFpmQUzJa11agbyPVMbpgT/qA3/SKyJ1jyBgm7dUcUEa8v9JwDkerSQXfakBwFljIxhOJqGkjUwZ9FSA==} + peerDependencies: + babel-plugin-macros: ^3.1.0 + peerDependenciesMeta: + babel-plugin-macros: + optional: true - has-symbols@1.1.0: - resolution: {integrity: sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==} - engines: {node: '>= 0.4'} + deep-eql@5.0.2: + resolution: {integrity: sha512-h5k/5U50IJJFpzfL6nO9jaaumfjO/f2NjK/oYB2Djzm4p9L+3T9qWpZqZ2hAbLPuuYq9wrU08WQyBTL5GbPk5Q==} + engines: {node: '>=6'} - has-tostringtag@1.0.2: - resolution: {integrity: sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==} - engines: {node: '>= 0.4'} + deepmerge@4.3.1: + resolution: {integrity: sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A==} + engines: {node: '>=0.10.0'} - hash-base@3.1.2: - resolution: {integrity: sha512-Bb33KbowVTIj5s7Ked1OsqHUeCpz//tPwR+E2zJgJKo9Z5XolZ9b6bdUgjmYlwnWhoOQKoTd1TYToZGn5mAYOg==} - engines: {node: '>= 0.8'} + default-browser-id@5.0.1: + resolution: {integrity: sha512-x1VCxdX4t+8wVfd1so/9w+vQ4vx7lKd2Qp5tDRutErwmR85OgmfX7RlLRMWafRMY7hbEiXIbudNrjOAPa/hL8Q==} + engines: {node: '>=18'} - hash.js@1.1.7: - resolution: {integrity: sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==} + default-browser@5.4.0: + resolution: {integrity: sha512-XDuvSq38Hr1MdN47EDvYtx3U0MTqpCEn+F6ft8z2vYDzMrvQhVp0ui9oQdqW3MvK3vqUETglt1tVGgjLuJ5izg==} + engines: {node: '>=18'} - hasha@5.2.2: - resolution: {integrity: sha512-Hrp5vIK/xr5SkeN2onO32H0MgNZ0f17HRNH39WfL0SYUNOTZ5Lz1TJ8Pajo/87dYGEFlLMm7mIc/k/s6Bvz9HQ==} - engines: {node: '>=8'} + defaults@1.0.4: + resolution: {integrity: sha512-eFuaLoy/Rxalv2kr+lqMlUnrDWV+3j4pljOIJgLIhI058IQfWJ7vXhyEIHu+HtC738klGALYxOKDO0bQP3tg8A==} - hasown@2.0.2: - resolution: {integrity: sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==} + define-data-property@1.1.4: + resolution: {integrity: sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==} engines: {node: '>= 0.4'} - hasown@2.0.3: - resolution: {integrity: sha512-ej4AhfhfL2Q2zpMmLo7U1Uv9+PyhIZpgQLGT1F9miIGmiCJIoCgSmczFdrc97mWT4kVY72KA+WnnhJ5pghSvSg==} - engines: {node: '>= 0.4'} + define-lazy-prop@2.0.0: + resolution: {integrity: sha512-Ds09qNh8yw3khSjiJjiUInaGX9xlqZDY7JVryGxdxV7NPeuqQfplOpQ66yJFZut3jLa5zOwkXw1g9EI2uKh4Og==} + engines: {node: '>=8'} - he@1.2.0: - resolution: {integrity: sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==} - hasBin: true + define-lazy-prop@3.0.0: + resolution: {integrity: sha512-N+MeXYoqr3pOgn8xfyRPREN7gHakLYjhsHhWGT3fWAiL4IkAt0iDw14QiiEm2bE30c5XX5q0FtAA3CK5f9/BUg==} + engines: {node: '>=12'} - header-case@1.0.1: - resolution: {integrity: sha512-i0q9mkOeSuhXw6bGgiQCCBgY/jlZuV/7dZXyZ9c6LcBrqwvT8eT719E9uxE5LiZftdl+z81Ugbg/VvXV4OJOeQ==} + defu@6.1.4: + resolution: {integrity: sha512-mEQCMmwJu317oSz8CwdIOdwf3xMif1ttiM8LTufzc3g6kR+9Pe236twL8j3IYT1F7GfRgGcW6MWxzZjLIkuHIg==} - heap@0.2.7: - resolution: {integrity: sha512-2bsegYkkHO+h/9MGbn6KWcE45cHZgPANo5LXF7EvWdT0yT2EguSVO1nDgU5c8+ZOPwp2vMNa7YFsJhVcDR9Sdg==} + denque@2.1.0: + resolution: {integrity: sha512-HVQE3AAb/pxF8fQAoiqpvg9i3evqug3hoiwakOyZAwJm+6vZehbkYXZ0l4JxS+I3QxM97v5aaRNhj8v5oBhekw==} + engines: {node: '>=0.10'} - hermes-estree@0.25.1: - resolution: {integrity: sha512-0wUoCcLp+5Ev5pDW2OriHC2MJCbwLwuRx+gAqMTOkGKJJiBCLjtrvy4PWUGn6MIVefecRpzoOZ/UV6iGdOr+Cw==} + depd@1.1.2: + resolution: {integrity: sha512-7emPTl6Dpo6JRXOXjLRxck+FlLRX5847cLKEn00PLAgc3g2hTZZgr+e4c2v6QpSmLeFP3n5yUo7ft6avBK/5jQ==} + engines: {node: '>= 0.6'} - hermes-parser@0.25.1: - resolution: {integrity: sha512-6pEjquH3rqaI6cYAXYPcz9MS4rY6R4ngRgrgfDshRptUZIc3lw0MCIJIGDj9++mfySOuPTHB4nrSW99BCvOPIA==} + depd@2.0.0: + resolution: {integrity: sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==} + engines: {node: '>= 0.8'} - hmac-drbg@1.0.1: - resolution: {integrity: sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==} - - hosted-git-info@2.8.9: - resolution: {integrity: sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==} + dequal@2.0.3: + resolution: {integrity: sha512-0je+qPKHEMohvfRTCEo3CrPG6cAzAYgmzKyxRiYSSDkS6eGJdyVJm7WaYA5ECaAD9wLB2T4EEeymA5aFVcYXCA==} + engines: {node: '>=6'} - hosted-git-info@7.0.2: - resolution: {integrity: sha512-puUZAUKT5m8Zzvs72XWy3HtvVbTWljRE66cP60bxJzAqf2DgICo7lYTY2IHUmLnNpjYvw5bvmoHvPc0QO2a62w==} - engines: {node: ^16.14.0 || >=18.0.0} + derive-valtio@0.1.0: + resolution: {integrity: sha512-OCg2UsLbXK7GmmpzMXhYkdO64vhJ1ROUUGaTFyHjVwEdMEcTTRj7W1TxLbSBxdY8QLBPCcp66MTyaSy0RpO17A==} + peerDependencies: + valtio: '*' - html-escaper@2.0.2: - resolution: {integrity: sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==} + destr@2.0.5: + resolution: {integrity: sha512-ugFTXCtDZunbzasqBxrK93Ik/DRYsO6S/fedkWEMKqt04xZ4csmnmwGDBAb07QWNaGMAmnTIemsYZCksjATwsA==} - http-basic@8.1.3: - resolution: {integrity: sha512-/EcDMwJZh3mABI2NhGfHOGOeOZITqfkEO4p/xK+l3NpyncIHUQBoMvCSF/b5GqvKtySC2srL/GGG3+EtlqlmCw==} - engines: {node: '>=6.0.0'} + detect-browser@5.3.0: + resolution: {integrity: sha512-53rsFbGdwMwlF7qvCt0ypLM5V5/Mbl0szB7GPN8y9NCcbknYOeVVXdrXEq+90IwAfrrzt6Hd+u2E2ntakICU8w==} - http-cache-semantics@4.2.0: - resolution: {integrity: sha512-dTxcvPXqPvXBQpq5dUr6mEMJX4oIEFv6bwom3FDwKRDsuIjjJGANqhBuoAn9c1RQJIdAKav33ED65E2ys+87QQ==} + detect-indent@6.1.0: + resolution: {integrity: sha512-reYkTUJAZb9gUuZ2RvVCNhVHdg62RHnJ7WJl8ftMi4diZ6NWlciOzQN88pUhSELEwflJht4oQDv0F0BMlwaYtA==} + engines: {node: '>=8'} - http-encoding@2.2.0: - resolution: {integrity: sha512-sotL89NNHWS7TjaoswmKkNKf57+nAYCg3fbGCclpNLriVGkOSgrAWQ9DLqahnwacY+gednJk+HFdZrpKw/Ff6w==} - engines: {node: '>=v18.0.0'} + detect-libc@1.0.3: + resolution: {integrity: sha512-pGjwhsmsp4kL2RTz08wcOlGN83otlqHeD/Z5T8GXZB+/YcpQ/dgo+lbU8ZsGxV0HIvqqxo9l7mqYwyYMD9bKDg==} + engines: {node: '>=0.10'} + hasBin: true - http-errors@2.0.1: - resolution: {integrity: sha512-4FbRdAX+bSdmo4AUFuS0WNiPz8NgFt+r8ThgNWmlrjQjt1Q7ZR9+zTlce2859x4KSXrwIsaeTqDoKQmtP8pLmQ==} - engines: {node: '>= 0.8'} + detect-libc@2.1.2: + resolution: {integrity: sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==} + engines: {node: '>=8'} - http-https@1.0.0: - resolution: {integrity: sha512-o0PWwVCSp3O0wS6FvNr6xfBCHgt0m1tvPLFOCc2iFDKTRAXhB7m8klDf7ErowFH8POa6dVdGatKU5I1YYwzUyg==} + detect-node-es@1.1.0: + resolution: {integrity: sha512-ypdmJU/TbBby2Dxibuv7ZLW3Bs1QEmM7nHjEANfohJLvE0XVujisn1qPJcZxg+qDucsr+bP6fLD1rPS3AhJ7EQ==} - http-proxy-agent@7.0.2: - resolution: {integrity: sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==} - engines: {node: '>= 14'} + devalue@5.6.1: + resolution: {integrity: sha512-jDwizj+IlEZBunHcOuuFVBnIMPAEHvTsJj0BcIp94xYguLRVBcXO853px/MyIJvbVzWdsGvrRweIUWJw8hBP7A==} - http-response-object@3.0.2: - resolution: {integrity: sha512-bqX0XTF6fnXSQcEJ2Iuyr75yVakyjIDCqroJQ/aHfSdlM743Cwqoi2nDYMzLGWUcuTWGWy8AAvOKXTfiv6q9RA==} + devlop@1.1.0: + resolution: {integrity: sha512-RWmIqhcFf1lRYBvNmr7qTNuyCt/7/ns2jbpp1+PalgE/rDQcBT0fioSMUpJ93irlUhC5hrg4cYqe6U+0ImW0rA==} - http-signature@1.2.0: - resolution: {integrity: sha512-CAbnr6Rz4CYQkLYUtSNXxQPUH2gK8f3iWexVlsnMeD+GjlsQ0Xsy1cOX+mN3dtxYomRy21CiOzU8Uhw6OwncEQ==} - engines: {node: '>=0.8', npm: '>=1.3.7'} + diff@4.0.2: + resolution: {integrity: sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==} + engines: {node: '>=0.3.1'} - http-signature@1.4.0: - resolution: {integrity: sha512-G5akfn7eKbpDN+8nPS/cb57YeA1jLTVxjpCj7tmm3QKPdyDy7T+qSC40e9ptydSWvkwjSXw1VbkpyEm39ukeAg==} - engines: {node: '>=0.10'} + diff@5.0.0: + resolution: {integrity: sha512-/VTCrvm5Z0JGty/BWHljh+BAiw3IK+2j87NGMu8Nwc/f48WoDAC395uomO9ZD117ZOBaHmkX1oyLvkVM/aIT3w==} + engines: {node: '>=0.3.1'} - http2-wrapper@1.0.3: - resolution: {integrity: sha512-V+23sDMr12Wnz7iTcDeJr3O6AIxlnvT/bmaAAAP/Xda35C90p9599p0F1eHR/N1KILWSoWVAiOMFjBBXaXSMxg==} - engines: {node: '>=10.19.0'} + diff@8.0.2: + resolution: {integrity: sha512-sSuxWU5j5SR9QQji/o2qMvqRNYRDOcBTgsJ/DeCf4iSN4gW+gNMXM7wFIP+fdXZxoNiAnHUTGjCr+TSWXdRDKg==} + engines: {node: '>=0.3.1'} - http2-wrapper@2.2.1: - resolution: {integrity: sha512-V5nVw1PAOgfI3Lmeaj2Exmeg7fenjhRUgz1lPSezy1CuhPYbgQtbQj4jZfEAEMlaL+vupsvhjqCyjzob0yxsmQ==} - engines: {node: '>=10.19.0'} + dijkstrajs@1.0.2: + resolution: {integrity: sha512-QV6PMaHTCNmKSeP6QoXhVTw9snc9VD8MulTT0Bd99Pacp4SS1cjcrYPgBPmibqKVtMJJfqC6XvOXgPMEEPH/fg==} - https-proxy-agent@5.0.1: - resolution: {integrity: sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==} - engines: {node: '>= 6'} + dir-glob@2.2.2: + resolution: {integrity: sha512-f9LBi5QWzIW3I6e//uxZoLBlUt9kcp66qo0sSCxL6YZKc75R1c4MFCoe/LaZiBGmgujvQdxc5Bn3QhfyvK5Hsw==} + engines: {node: '>=4'} - https-proxy-agent@7.0.6: - resolution: {integrity: sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==} - engines: {node: '>= 14'} + dir-glob@3.0.1: + resolution: {integrity: sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==} + engines: {node: '>=8'} - human-id@4.1.3: - resolution: {integrity: sha512-tsYlhAYpjCKa//8rXZ9DqKEawhPoSytweBC2eNvcaDK+57RZLHGqNs3PZTQO6yekLFSuvA6AlnAfrw1uBvtb+Q==} - hasBin: true + dom-accessibility-api@0.5.16: + resolution: {integrity: sha512-X7BJ2yElsnOJ30pZF4uIIDfBEVgF4XEBxL9Bxhy6dnrm5hkzqmsWHGTiHqRiITNhMyFLyAiWndIJP7Z1NTteDg==} - human-signals@2.1.0: - resolution: {integrity: sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==} - engines: {node: '>=10.17.0'} + dom-serializer@2.0.0: + resolution: {integrity: sha512-wIkAryiqt/nV5EQKqQpo3SToSOV9J0DnbJqwK7Wv/Trc92zIAYZ4FlMu+JPFW1DfGFt81ZTCGgDEabffXeLyJg==} - husky@9.1.7: - resolution: {integrity: sha512-5gs5ytaNjBrh5Ow3zrvdUUY+0VxIuWVL4i9irt6friV+BqdCfmV11CQTWMiBYWHbXhco+J1kHfTOUkePhCDvMA==} - engines: {node: '>=18'} - hasBin: true + domelementtype@2.3.0: + resolution: {integrity: sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==} - iconv-lite@0.4.24: - resolution: {integrity: sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==} - engines: {node: '>=0.10.0'} + domhandler@5.0.3: + resolution: {integrity: sha512-cgwlv/1iFQiFnU96XXgROh8xTeetsnJiDsTc7TYCLFd9+/WNkIqPTxiM/8pSd8VIrhXGTf1Ny1q1hquVqDJB5w==} + engines: {node: '>= 4'} - iconv-lite@0.6.3: - resolution: {integrity: sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==} - engines: {node: '>=0.10.0'} + domutils@3.2.2: + resolution: {integrity: sha512-6kZKyUajlDuqlHKVX1w7gyslj9MPIXzIFiz/rGu35uC1wMi+kMhQwGhl4lt9unC9Vb9INnY9Z3/ZA3+FhASLaw==} - iconv-lite@0.7.2: - resolution: {integrity: sha512-im9DjEDQ55s9fL4EYzOAv0yMqmMBSZp6G0VvFyTMPKWxiSBHUj9NW/qqLmXUwXrrM7AvqSlTCfvqRb0cM8yYqw==} - engines: {node: '>=0.10.0'} + dot-prop@10.1.0: + resolution: {integrity: sha512-MVUtAugQMOff5RnBy2d9N31iG0lNwg1qAoAOn7pOK5wf94WIaE3My2p3uwTQuvS2AcqchkcR3bHByjaM0mmi7Q==} + engines: {node: '>=20'} - idb@7.1.1: - resolution: {integrity: sha512-gchesWBzyvGHRO9W8tzUWFDycow5gwjvFKfyV9FF32Y7F50yZMp7mP+T2mJIWFx49zicqyC4uefHM17o6xKIVQ==} + dotenv-expand@10.0.0: + resolution: {integrity: sha512-GopVGCpVS1UKH75VKHGuQFqS1Gusej0z4FyQkPdwjil2gNIv+LNsqBlboOzpJFZKVT95GkCyWJbBSdFEFUWI2A==} + engines: {node: '>=12'} - idb@8.0.3: - resolution: {integrity: sha512-LtwtVyVYO5BqRvcsKuB2iUMnHwPVByPCXFXOpuU96IZPPoPN6xjOGxZQ74pgSVVLQWtUOYgyeL4GE98BY5D3wg==} + dotenv@16.3.1: + resolution: {integrity: sha512-IPzF4w4/Rd94bA9imS68tZBaYyBWSCE47V1RGuMrB94iyTOIEwRmVL2x/4An+6mETpLrKJ5hQkB8W4kFAadeIQ==} + engines: {node: '>=12'} - idna-uts46-hx@2.3.1: - resolution: {integrity: sha512-PWoF9Keq6laYdIRwwCdhTPl60xRqAloYNMQLiyUnG42VjT53oW07BXIRM+NK7eQjzXjAk2gUvX9caRxlnF9TAA==} - engines: {node: '>=4.0.0'} + dotenv@16.6.1: + resolution: {integrity: sha512-uBq4egWHTcTt33a72vpSG0z3HnPuIl6NqYcTrKEg2azoEyl2hpW0zqlxysq2pK9HlDIHyHyakeYaYnSAwd8bow==} + engines: {node: '>=12'} - ieee754@1.2.1: - resolution: {integrity: sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==} + dotenv@17.2.3: + resolution: {integrity: sha512-JVUnt+DUIzu87TABbhPmNfVdBDt18BLOWjMUFJMSi/Qqg7NTYtabbvSNJGOJ7afbRuv9D/lngizHtP7QyLQ+9w==} + engines: {node: '>=12'} - ignore-by-default@1.0.1: - resolution: {integrity: sha512-Ius2VYcGNk7T90CppJqcIkS5ooHUZyIQK+ClZfMfMNFEF9VSE73Fq+906u/CWu92x4gzZMWOwfFYckPObzdEbA==} + dotenv@8.6.0: + resolution: {integrity: sha512-IrPdXQsk2BbzvCBGBOTmmSH5SodmqZNt4ERAZDmW4CT+tL8VtvinqywuANaFu4bOMWki16nqf0e4oC0QIaDr/g==} + engines: {node: '>=10'} - ignore@5.3.2: - resolution: {integrity: sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==} - engines: {node: '>= 4'} + dunder-proto@1.0.1: + resolution: {integrity: sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==} + engines: {node: '>= 0.4'} - ignore@7.0.5: - resolution: {integrity: sha512-Hs59xBNfUIunMFgWAbGX5cq6893IbWg4KnrjbYwX3tx0ztorVgTDA6B2sxf8ejHJ4wz8BqGUMYlnzNBer5NvGg==} - engines: {node: '>= 4'} + duplexer@0.1.2: + resolution: {integrity: sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==} - immediate@3.2.3: - resolution: {integrity: sha512-RrGCXRm/fRVqMIhqXrGEX9rRADavPiDFSoMb/k64i9XMk8uH4r/Omi5Ctierj6XzNecwDbO4WuFbDD1zmpl3Tg==} + duplexify@4.1.2: + resolution: {integrity: sha512-fz3OjcNCHmRP12MJoZMPglx8m4rrFP8rovnk4vT8Fs+aonZoCwGg10dSsQsfP/E62eZcPTMSMP6686fu9Qlqtw==} - immediate@3.3.0: - resolution: {integrity: sha512-HR7EVodfFUdQCTIeySw+WDRFJlPcLOJbXfwwZ7Oom6tjsvZ3bOkCDJHehQC3nxJrv7+f9XecwazynjU8e4Vw3Q==} + eastasianwidth@0.2.0: + resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==} - immer@10.0.2: - resolution: {integrity: sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==} + easy-table@1.2.0: + resolution: {integrity: sha512-OFzVOv03YpvtcWGe5AayU5G2hgybsg3iqA6drU8UaoZyB9jLGMTrz9+asnLp/E+6qPh88yEI1gvyZFZ41dmgww==} - immutable@4.3.8: - resolution: {integrity: sha512-d/Ld9aLbKpNwyl0KiM2CT1WYvkitQ1TSvmRtkcV8FKStiDoA7Slzgjmb/1G2yhKM1p0XeNOieaTbFZmU1d3Xuw==} + eciesjs@0.4.16: + resolution: {integrity: sha512-dS5cbA9rA2VR4Ybuvhg6jvdmp46ubLn3E+px8cG/35aEDNclrqoCjg6mt0HYZ/M+OoESS3jSkCrqk1kWAEhWAw==} + engines: {bun: '>=1', deno: '>=2', node: '>=16'} - import-fresh@3.3.1: - resolution: {integrity: sha512-TR3KfrTZTYLPB6jUjfx6MF9WcWrHL9su5TObK4ZkYgBdWKPOFoSoQIdEuTuR82pmtxH2spWG9h6etwfr1pLBqQ==} - engines: {node: '>=6'} + edge-runtime@2.5.9: + resolution: {integrity: sha512-pk+k0oK0PVXdlT4oRp4lwh+unuKB7Ng4iZ2HB+EZ7QCEQizX360Rp/F4aRpgpRgdP2ufB35N+1KppHmYjqIGSg==} + engines: {node: '>=16'} + hasBin: true - imul@1.0.1: - resolution: {integrity: sha512-WFAgfwPLAjU66EKt6vRdTlKj4nAgIDQzh29JonLa4Bqtl6D8JrIMvWjCnx7xEjVNmP3U0fM5o8ZObk7d0f62bA==} - engines: {node: '>=0.10.0'} + editorconfig@1.0.4: + resolution: {integrity: sha512-L9Qe08KWTlqYMVvMcTIvMAdl1cDUubzRNYL+WfA4bLDMHe4nemKkpmYzkznE1FwLKu0EEmy6obgQKzMJrg4x9Q==} + engines: {node: '>=14'} + hasBin: true - imurmurhash@0.1.4: - resolution: {integrity: sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==} - engines: {node: '>=0.8.19'} + ee-first@1.1.1: + resolution: {integrity: sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==} - indent-string@4.0.0: - resolution: {integrity: sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==} - engines: {node: '>=8'} + electron-to-chromium@1.4.757: + resolution: {integrity: sha512-jftDaCknYSSt/+KKeXzH3LX5E2CvRLm75P3Hj+J/dv3CL0qUYcOt13d5FN1NiL5IJbbhzHrb3BomeG2tkSlZmw==} - inflight@1.0.6: - resolution: {integrity: sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==} - deprecated: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful. + electron-to-chromium@1.5.267: + resolution: {integrity: sha512-0Drusm6MVRXSOJpGbaSVgcQsuB4hEkMpHXaVstcPmhu5LIedxs1xNK/nIxmQIU/RPC0+1/o0AVZfBTkTNJOdUw==} - inherits@2.0.4: - resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} + elliptic@6.5.4: + resolution: {integrity: sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==} - ini@1.3.8: - resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==} + elliptic@6.6.0: + resolution: {integrity: sha512-dpwoQcLc/2WLQvJvLRHKZ+f9FgOdjnq11rurqwekGQygGPsYSK29OMMD2WalatiqQ+XGFDglTNixpPfI+lpaAA==} - inquirer@7.3.3: - resolution: {integrity: sha512-JG3eIAj5V9CwcGvuOmoo6LB9kbAYT8HXffUl6memuszlwDC/qvFAJw49XJ5NROSFNPxp3iQg1GqkFhaY/CR0IA==} - engines: {node: '>=8.0.0'} + elliptic@6.6.1: + resolution: {integrity: sha512-RaddvvMatK2LJHqFJ+YA4WysVN5Ita9E35botqIYspQ4TkRAlCicdzKOjlyv/1Za5RyTNn7di//eEV0uTAfe3g==} - inquirer@8.2.7: - resolution: {integrity: sha512-UjOaSel/iddGZJ5xP/Eixh6dY1XghiBw4XK13rCCIJcJfyhhoul/7KhLLUGtebEj6GDYM6Vnx/mVsjx2L/mFIA==} - engines: {node: '>=12.0.0'} + emoji-regex@8.0.0: + resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} - internal-slot@1.1.0: - resolution: {integrity: sha512-4gd7VpWNQNB4UKKCFFVcp1AVv+FMOgs9NKzjHKusc8jTMhd5eL1NqQqOpE0KzMds804/yHlglp3uxgluOqAPLw==} - engines: {node: '>= 0.4'} + emoji-regex@9.2.2: + resolution: {integrity: sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==} - interpret@1.4.0: - resolution: {integrity: sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA==} - engines: {node: '>= 0.10'} + emojilib@2.4.0: + resolution: {integrity: sha512-5U0rVMU5Y2n2+ykNLQqMoqklN9ICBT/KsvC1Gz6vqHbz2AXXGkG+Pm5rMWk/8Vjrr/mY9985Hi8DYzn1F09Nyw==} - invert-kv@1.0.0: - resolution: {integrity: sha512-xgs2NH9AE66ucSq4cNG1nhSFghr5l6tdL15Pk+jl46bmmBapgoaY/AacXyaDznAqmGL99TiLSQgO/XazFSKYeQ==} - engines: {node: '>=0.10.0'} + encode-utf8@1.0.3: + resolution: {integrity: sha512-ucAnuBEhUK4boH2HjVYG5Q2mQyPorvv0u/ocS+zhdw0S8AlHYY+GOFhP1Gio5z4icpP2ivFSvhtFjQi8+T9ppw==} - io-ts@1.10.4: - resolution: {integrity: sha512-b23PteSnYXSONJ6JQXRAlvJhuw8KOtkqa87W4wDtvMrud/DTJd5X+NpOOI+O/zZwVq6v0VLAaJ+1EDViKEuN9g==} + encodeurl@2.0.0: + resolution: {integrity: sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==} + engines: {node: '>= 0.8'} - ip-address@10.1.0: - resolution: {integrity: sha512-XXADHxXmvT9+CRxhXg56LJovE+bmWnEWB78LB83VZTprKTmaC5QfruXocxzTZ2Kl0DNwKuBdlIhjL8LeY8Sf8Q==} - engines: {node: '>= 12'} + encoding@0.1.13: + resolution: {integrity: sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==} - ipaddr.js@1.9.1: - resolution: {integrity: sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==} - engines: {node: '>= 0.10'} + end-of-stream@1.1.0: + resolution: {integrity: sha512-EoulkdKF/1xa92q25PbjuDcgJ9RDHYU2Rs3SCIvs2/dSQ3BpmxneNHmA/M7fe60M3PrV7nNGTTNbkK62l6vXiQ==} - is-arguments@1.2.0: - resolution: {integrity: sha512-7bVbi0huj/wrIAOzb8U1aszg9kdi3KN/CyU19CTI7tAoZYEZoL9yCDXpbXN+uPsuWnP02cyug1gleqq+TU+YCA==} - engines: {node: '>= 0.4'} + end-of-stream@1.4.4: + resolution: {integrity: sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==} - is-array-buffer@3.0.5: - resolution: {integrity: sha512-DDfANUiiG2wC1qawP66qlTugJeL5HyzMpfr8lLK+jMQirGzNod0B12cFB/9q838Ru27sBwfw78/rdoU7RERz6A==} - engines: {node: '>= 0.4'} + end-of-stream@1.4.5: + resolution: {integrity: sha512-ooEGc6HP26xXq/N+GCGOT0JKCLDGrq2bQUZrQ7gyrJiZANJ/8YDTxTpQBXGMn+WbIQXNVpyWymm7KYVICQnyOg==} - is-arrayish@0.2.1: - resolution: {integrity: sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==} + engine.io-client@6.6.4: + resolution: {integrity: sha512-+kjUJnZGwzewFDw951CDWcwj35vMNf2fcj7xQWOctq1F2i1jkDdVvdFG9kM/BEChymCH36KgjnW0NsL58JYRxw==} - is-async-function@2.1.1: - resolution: {integrity: sha512-9dgM/cZBnNvjzaMYHVoxxfPj2QXt22Ev7SuuPrs+xav0ukGB0S6d4ydZdEiM48kLx5kDV+QBPrpVnFyefL8kkQ==} - engines: {node: '>= 0.4'} + engine.io-parser@5.2.3: + resolution: {integrity: sha512-HqD3yTBfnBxIrbnM1DoD6Pcq8NECnh8d4As1Qgh0z5Gg3jRRIqijury0CL3ghu/edArpUYiYqQiDUQBIs4np3Q==} + engines: {node: '>=10.0.0'} - is-bigint@1.1.0: - resolution: {integrity: sha512-n4ZT37wG78iz03xPRKJrHTdZbe3IicyucEtdRsV5yglwc3GyUfbAfpSeD0FJ41NbUNSt5wbhqfp1fS+BgnvDFQ==} - engines: {node: '>= 0.4'} + enhanced-resolve@5.17.1: + resolution: {integrity: sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==} + engines: {node: '>=10.13.0'} - is-binary-path@2.1.0: - resolution: {integrity: sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==} - engines: {node: '>=8'} + enhanced-resolve@5.18.4: + resolution: {integrity: sha512-LgQMM4WXU3QI+SYgEc2liRgznaD5ojbmY3sb8LxyguVkIg5FxdpTkvk72te2R38/TGKxH634oLxXRGY6d7AP+Q==} + engines: {node: '>=10.13.0'} - is-boolean-object@1.2.2: - resolution: {integrity: sha512-wa56o2/ElJMYqjCjGkXri7it5FbebW5usLw/nPmCMs5DeZ7eziSYZhSmPRn0txqeW4LnAmQQU7FgqLpsEFKM4A==} - engines: {node: '>= 0.4'} + enquirer@2.3.6: + resolution: {integrity: sha512-yjNnPr315/FjS4zIsUxYguYUPP2e1NK4d7E7ZOLiyYCcbFBiTMyID+2wvm2w6+pZ/odMA7cRkjhsPbltwBOrLg==} + engines: {node: '>=8.6'} - is-buffer@2.0.5: - resolution: {integrity: sha512-i2R6zNFDwgEHJyQUtJEk0XFi1i0dPFn/oqjK3/vPCcDeJvW5NQ83V8QbicfF1SupOaB0h8ntgBC2YiE7dfyctQ==} - engines: {node: '>=4'} + enquirer@2.4.1: + resolution: {integrity: sha512-rRqJg/6gd538VHvR3PSrdRBb/1Vy2YfzHqzvbhGIQpDRKIa4FgV/54b5Q1xYSxOOwKvjXweS26E0Q+nAMwp2pQ==} + engines: {node: '>=8.6'} - is-callable@1.2.7: - resolution: {integrity: sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==} - engines: {node: '>= 0.4'} + entities@4.5.0: + resolution: {integrity: sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==} + engines: {node: '>=0.12'} - is-core-module@2.16.1: - resolution: {integrity: sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w==} - engines: {node: '>= 0.4'} + entities@7.0.0: + resolution: {integrity: sha512-FDWG5cmEYf2Z00IkYRhbFrwIwvdFKH07uV8dvNy0omp/Qb1xcyCWp2UDtcwJF4QZZvk0sLudP6/hAu42TaqVhQ==} + engines: {node: '>=0.12'} - is-data-view@1.0.2: - resolution: {integrity: sha512-RKtWF8pGmS87i2D6gqQu/l7EYRlVdfzemCJN/P3UOs//x1QE7mfhvzHIApBTRf7axvT6DMGwSwBXYCT0nfB9xw==} - engines: {node: '>= 0.4'} + env-paths@2.2.1: + resolution: {integrity: sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==} + engines: {node: '>=6'} - is-date-object@1.1.0: - resolution: {integrity: sha512-PwwhEakHVKTdRNVOw+/Gyh0+MzlCl4R6qKvkhuvLtPMggI1WAHt9sOwZxQLSGpUaDnrdyDsomoRgNnCfKNSXXg==} - engines: {node: '>= 0.4'} + environment@1.1.0: + resolution: {integrity: sha512-xUtoPkMggbz0MPyPiIWr1Kp4aeWJjDZ6SMvURhimjdZgsRuDplF5/s9hcgGhyXMhs+6vpnuoiZ2kFiu3FMnS8Q==} + engines: {node: '>=18'} - is-docker@2.2.1: - resolution: {integrity: sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==} - engines: {node: '>=8'} - hasBin: true + error-stack-parser-es@1.0.5: + resolution: {integrity: sha512-5qucVt2XcuGMcEGgWI7i+yZpmpByQ8J1lHhcL7PwqCwu9FPP3VUXzT4ltHe5i2z9dePwEHcDVOAfSnHsOlCXRA==} - is-extglob@2.1.1: - resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} - engines: {node: '>=0.10.0'} + errx@0.1.0: + resolution: {integrity: sha512-fZmsRiDNv07K6s2KkKFTiD2aIvECa7++PKyD5NC32tpRw46qZA3sOz+aM+/V9V0GDHxVTKLziveV4JhzBHDp9Q==} - is-finalizationregistry@1.1.1: - resolution: {integrity: sha512-1pC6N8qWJbWoPtEjgcL2xyhQOP491EQjeUo3qTKcmV8YSDDJrOepfG8pcC7h/QgnQHYSv0mJ3Z/ZWxmatVrysg==} + es-define-property@1.0.1: + resolution: {integrity: sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==} engines: {node: '>= 0.4'} - is-fn@1.0.0: - resolution: {integrity: sha512-XoFPJQmsAShb3jEQRfzf2rqXavq7fIqF/jOekp308JlThqrODnMpweVSGilKTCXELfLhltGP2AGgbQGVP8F1dg==} - engines: {node: '>=0.10.0'} - - is-fullwidth-code-point@1.0.0: - resolution: {integrity: sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==} - engines: {node: '>=0.10.0'} - - is-fullwidth-code-point@2.0.0: - resolution: {integrity: sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w==} - engines: {node: '>=4'} + es-errors@1.3.0: + resolution: {integrity: sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==} + engines: {node: '>= 0.4'} - is-fullwidth-code-point@3.0.0: - resolution: {integrity: sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==} - engines: {node: '>=8'} + es-module-lexer@1.4.1: + resolution: {integrity: sha512-cXLGjP0c4T3flZJKQSuziYoq7MlT+rnvfZjfp7h+I7K9BNX54kP9nyWvdbwjQ4u1iWbOL4u96fgeZLToQlZC7w==} - is-function@1.0.2: - resolution: {integrity: sha512-lw7DUp0aWXYg+CBCN+JKkcE0Q2RayZnSvnZBlwgxHBQhqt5pZNVy4Ri7H9GmmXkdu7LUthszM+Tor1u/2iBcpQ==} + es-module-lexer@1.7.0: + resolution: {integrity: sha512-jEQoCwk8hyb2AZziIOLhDqpm5+2ww5uIE6lkO/6jcOCusfk6LhMHpXXfBLXTZ7Ydyt0j4VoUQv6uGNYbdW+kBA==} - is-generator-function@1.1.2: - resolution: {integrity: sha512-upqt1SkGkODW9tsGNG5mtXTXtECizwtS2kA161M+gJPc1xdb/Ax629af6YrTwcOeQHbewrPNlE5Dx7kzvXTizA==} + es-object-atoms@1.1.1: + resolution: {integrity: sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==} engines: {node: '>= 0.4'} - is-glob@4.0.3: - resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==} - engines: {node: '>=0.10.0'} + es-toolkit@1.33.0: + resolution: {integrity: sha512-X13Q/ZSc+vsO1q600bvNK4bxgXMkHcf//RxCmYDaRY5DAcT+eoXjY5hoAPGMdRnWQjvyLEcyauG3b6hz76LNqg==} - is-hex-prefixed@1.0.0: - resolution: {integrity: sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==} - engines: {node: '>=6.5.0', npm: '>=3'} + esbuild-android-64@0.14.47: + resolution: {integrity: sha512-R13Bd9+tqLVFndncMHssZrPWe6/0Kpv2/dt4aA69soX4PRxlzsVpCvoJeFE8sOEoeVEiBkI0myjlkDodXlHa0g==} + engines: {node: '>=12'} + cpu: [x64] + os: [android] - is-interactive@1.0.0: - resolution: {integrity: sha512-2HvIEKRoqS62guEC+qBjpvRubdX910WCMuJTZ+I9yvqKU2/12eSL549HMwtabb4oupdj2sMP50k+XJfB/8JE6w==} - engines: {node: '>=8'} + esbuild-android-arm64@0.14.47: + resolution: {integrity: sha512-OkwOjj7ts4lBp/TL6hdd8HftIzOy/pdtbrNA4+0oVWgGG64HrdVzAF5gxtJufAPOsEjkyh1oIYvKAUinKKQRSQ==} + engines: {node: '>=12'} + cpu: [arm64] + os: [android] - is-lambda@1.0.1: - resolution: {integrity: sha512-z7CMFGNrENq5iFB9Bqo64Xk6Y9sg+epq1myIcdHaGnbMTYOxvzsEtdYqQUylB7LxfkvgrrjP32T6Ywciio9UIQ==} + esbuild-darwin-64@0.14.47: + resolution: {integrity: sha512-R6oaW0y5/u6Eccti/TS6c/2c1xYTb1izwK3gajJwi4vIfNs1s8B1dQzI1UiC9T61YovOQVuePDcfqHLT3mUZJA==} + engines: {node: '>=12'} + cpu: [x64] + os: [darwin] - is-lower-case@1.1.3: - resolution: {integrity: sha512-+5A1e/WJpLLXZEDlgz4G//WYSHyQBD32qa4Jd3Lw06qQlv3fJHnp3YIHjTQSGzHMgzmVKz2ZP3rBxTHkPw/lxA==} + esbuild-darwin-arm64@0.14.47: + resolution: {integrity: sha512-seCmearlQyvdvM/noz1L9+qblC5vcBrhUaOoLEDDoLInF/VQ9IkobGiLlyTPYP5dW1YD4LXhtBgOyevoIHGGnw==} + engines: {node: '>=12'} + cpu: [arm64] + os: [darwin] - is-map@2.0.3: - resolution: {integrity: sha512-1Qed0/Hr2m+YqxnM09CjA2d/i6YZNfF6R2oRAOj36eUdS6qIV/huPJNSEpKbupewFs+ZsJlxsjjPbc0/afW6Lw==} - engines: {node: '>= 0.4'} + esbuild-freebsd-64@0.14.47: + resolution: {integrity: sha512-ZH8K2Q8/Ux5kXXvQMDsJcxvkIwut69KVrYQhza/ptkW50DC089bCVrJZZ3sKzIoOx+YPTrmsZvqeZERjyYrlvQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [freebsd] - is-negative-zero@2.0.3: - resolution: {integrity: sha512-5KoIu2Ngpyek75jXodFvnafB6DJgr3u8uuK0LEZJjrU19DrMD3EVERaR8sjz8CCGgpZvxPl9SuE1GMVPFHx1mw==} - engines: {node: '>= 0.4'} + esbuild-freebsd-arm64@0.14.47: + resolution: {integrity: sha512-ZJMQAJQsIOhn3XTm7MPQfCzEu5b9STNC+s90zMWe2afy9EwnHV7Ov7ohEMv2lyWlc2pjqLW8QJnz2r0KZmeAEQ==} + engines: {node: '>=12'} + cpu: [arm64] + os: [freebsd] - is-number-object@1.1.1: - resolution: {integrity: sha512-lZhclumE1G6VYD8VHe35wFaIif+CTy5SJIi5+3y4psDgWu4wPDoBhF8NxUOinEc7pHgiTsT6MaBb92rKhhD+Xw==} - engines: {node: '>= 0.4'} + esbuild-linux-32@0.14.47: + resolution: {integrity: sha512-FxZOCKoEDPRYvq300lsWCTv1kcHgiiZfNrPtEhFAiqD7QZaXrad8LxyJ8fXGcWzIFzRiYZVtB3ttvITBvAFhKw==} + engines: {node: '>=12'} + cpu: [ia32] + os: [linux] - is-number@7.0.0: - resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==} - engines: {node: '>=0.12.0'} + esbuild-linux-64@0.14.47: + resolution: {integrity: sha512-nFNOk9vWVfvWYF9YNYksZptgQAdstnDCMtR6m42l5Wfugbzu11VpMCY9XrD4yFxvPo9zmzcoUL/88y0lfJZJJw==} + engines: {node: '>=12'} + cpu: [x64] + os: [linux] - is-observable@2.1.0: - resolution: {integrity: sha512-DailKdLb0WU+xX8K5w7VsJhapwHLZ9jjmazqCJq4X12CTgqq73TKnbRcnSLuXYPOoLQgV5IrD7ePiX/h1vnkBw==} - engines: {node: '>=8'} + esbuild-linux-arm64@0.14.47: + resolution: {integrity: sha512-ywfme6HVrhWcevzmsufjd4iT3PxTfCX9HOdxA7Hd+/ZM23Y9nXeb+vG6AyA6jgq/JovkcqRHcL9XwRNpWG6XRw==} + engines: {node: '>=12'} + cpu: [arm64] + os: [linux] - is-path-cwd@2.2.0: - resolution: {integrity: sha512-w942bTcih8fdJPJmQHFzkS76NEP8Kzzvmw92cXsazb8intwLqPibPPdXf4ANdKV3rYMuuQYGIWtvz9JilB3NFQ==} - engines: {node: '>=6'} + esbuild-linux-arm@0.14.47: + resolution: {integrity: sha512-ZGE1Bqg/gPRXrBpgpvH81tQHpiaGxa8c9Rx/XOylkIl2ypLuOcawXEAo8ls+5DFCcRGt/o3sV+PzpAFZobOsmA==} + engines: {node: '>=12'} + cpu: [arm] + os: [linux] - is-path-inside@3.0.3: - resolution: {integrity: sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==} - engines: {node: '>=8'} + esbuild-linux-mips64le@0.14.47: + resolution: {integrity: sha512-mg3D8YndZ1LvUiEdDYR3OsmeyAew4MA/dvaEJxvyygahWmpv1SlEEnhEZlhPokjsUMfRagzsEF/d/2XF+kTQGg==} + engines: {node: '>=12'} + cpu: [mips64el] + os: [linux] - is-plain-obj@2.1.0: - resolution: {integrity: sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==} - engines: {node: '>=8'} + esbuild-linux-ppc64le@0.14.47: + resolution: {integrity: sha512-WER+f3+szmnZiWoK6AsrTKGoJoErG2LlauSmk73LEZFQ/iWC+KhhDsOkn1xBUpzXWsxN9THmQFltLoaFEH8F8w==} + engines: {node: '>=12'} + cpu: [ppc64] + os: [linux] - is-regex@1.2.1: - resolution: {integrity: sha512-MjYsKHO5O7mCsmRGxWcLWheFqN9DJ/2TmngvjKXihe6efViPqc274+Fx/4fYj/r03+ESvBdTXK0V6tA3rgez1g==} - engines: {node: '>= 0.4'} + esbuild-linux-riscv64@0.14.47: + resolution: {integrity: sha512-1fI6bP3A3rvI9BsaaXbMoaOjLE3lVkJtLxsgLHqlBhLlBVY7UqffWBvkrX/9zfPhhVMd9ZRFiaqXnB1T7BsL2g==} + engines: {node: '>=12'} + cpu: [riscv64] + os: [linux] - is-set@2.0.3: - resolution: {integrity: sha512-iPAjerrse27/ygGLxw+EBR9agv9Y6uLeYVJMu+QNCoouJ1/1ri0mGrcWpfCqFZuzzx3WjtwxG098X+n4OuRkPg==} - engines: {node: '>= 0.4'} + esbuild-linux-s390x@0.14.47: + resolution: {integrity: sha512-eZrWzy0xFAhki1CWRGnhsHVz7IlSKX6yT2tj2Eg8lhAwlRE5E96Hsb0M1mPSE1dHGpt1QVwwVivXIAacF/G6mw==} + engines: {node: '>=12'} + cpu: [s390x] + os: [linux] - is-shared-array-buffer@1.0.4: - resolution: {integrity: sha512-ISWac8drv4ZGfwKl5slpHG9OwPNty4jOWPRIhBpxOoD+hqITiwuipOQ2bNthAzwA3B4fIjO4Nln74N0S9byq8A==} - engines: {node: '>= 0.4'} + esbuild-netbsd-64@0.14.47: + resolution: {integrity: sha512-Qjdjr+KQQVH5Q2Q1r6HBYswFTToPpss3gqCiSw2Fpq/ua8+eXSQyAMG+UvULPqXceOwpnPo4smyZyHdlkcPppQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [netbsd] - is-stream@2.0.1: - resolution: {integrity: sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==} - engines: {node: '>=8'} + esbuild-openbsd-64@0.14.47: + resolution: {integrity: sha512-QpgN8ofL7B9z8g5zZqJE+eFvD1LehRlxr25PBkjyyasakm4599iroUpaj96rdqRlO2ShuyqwJdr+oNqWwTUmQw==} + engines: {node: '>=12'} + cpu: [x64] + os: [openbsd] - is-string@1.1.1: - resolution: {integrity: sha512-BtEeSsoaQjlSPBemMQIrY1MY0uM6vnS1g5fmufYOtnxLGUZM2178PKbhsk7Ffv58IX+ZtcvoGwccYsh0PglkAA==} - engines: {node: '>= 0.4'} + esbuild-sunos-64@0.14.47: + resolution: {integrity: sha512-uOeSgLUwukLioAJOiGYm3kNl+1wJjgJA8R671GYgcPgCx7QR73zfvYqXFFcIO93/nBdIbt5hd8RItqbbf3HtAQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [sunos] - is-subdir@1.2.0: - resolution: {integrity: sha512-2AT6j+gXe/1ueqbW6fLZJiIw3F8iXGJtt0yDrZaBhAZEG1raiTxKWU+IPqMCzQAXOUCKdA4UDMgacKH25XG2Cw==} - engines: {node: '>=4'} + esbuild-windows-32@0.14.47: + resolution: {integrity: sha512-H0fWsLTp2WBfKLBgwYT4OTfFly4Im/8B5f3ojDv1Kx//kiubVY0IQunP2Koc/fr/0wI7hj3IiBDbSrmKlrNgLQ==} + engines: {node: '>=12'} + cpu: [ia32] + os: [win32] - is-symbol@1.1.1: - resolution: {integrity: sha512-9gGx6GTtCQM73BgmHQXfDmLtfjjTUDSyoxTCbp5WtoixAhfgsDirWIcVQ/IHpvI5Vgd5i/J5F7B9cN/WlVbC/w==} - engines: {node: '>= 0.4'} + esbuild-windows-64@0.14.47: + resolution: {integrity: sha512-/Pk5jIEH34T68r8PweKRi77W49KwanZ8X6lr3vDAtOlH5EumPE4pBHqkCUdELanvsT14yMXLQ/C/8XPi1pAtkQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [win32] - is-typed-array@1.1.15: - resolution: {integrity: sha512-p3EcsicXjit7SaskXHs1hA91QxgTw46Fv6EFKKGS5DRFLD8yKnohjF3hxoju94b/OcMZoQukzpPpBE9uLVKzgQ==} - engines: {node: '>= 0.4'} + esbuild-windows-arm64@0.14.47: + resolution: {integrity: sha512-HFSW2lnp62fl86/qPQlqw6asIwCnEsEoNIL1h2uVMgakddf+vUuMcCbtUY1i8sst7KkgHrVKCJQB33YhhOweCQ==} + engines: {node: '>=12'} + cpu: [arm64] + os: [win32] - is-typedarray@1.0.0: - resolution: {integrity: sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA==} + esbuild@0.14.47: + resolution: {integrity: sha512-wI4ZiIfFxpkuxB8ju4MHrGwGLyp1+awEHAHVpx6w7a+1pmYIq8T9FGEVVwFo0iFierDoMj++Xq69GXWYn2EiwA==} + engines: {node: '>=12'} + hasBin: true - is-unicode-supported@0.1.0: - resolution: {integrity: sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==} - engines: {node: '>=10'} + esbuild@0.21.5: + resolution: {integrity: sha512-mg3OPMV4hXywwpoDxu3Qda5xCKQi+vCTZq8S9J/EpkhB2HzKXq4SNFZE3+NK93JYxc8VMSep+lOUSC/RVKaBqw==} + engines: {node: '>=12'} + hasBin: true - is-upper-case@1.1.2: - resolution: {integrity: sha512-GQYSJMgfeAmVwh9ixyk888l7OIhNAGKtY6QA+IrWlu9MDTCaXmeozOZ2S9Knj7bQwBO/H6J2kb+pbyTUiMNbsw==} + esbuild@0.23.1: + resolution: {integrity: sha512-VVNz/9Sa0bs5SELtn3f7qhJCDPCF5oMEl5cO9/SSinpE9hbPVvxbd572HH5AKiP7WD8INO53GgfDDhRjkylHEg==} + engines: {node: '>=18'} + hasBin: true - is-url@1.2.4: - resolution: {integrity: sha512-ITvGim8FhRiYe4IQ5uHSkj7pVaPDrCTkNd3yq3cV7iZAcJdHTUMPMEHcqSOy9xZ9qFenQCvi+2wjH9a1nXqHww==} + esbuild@0.25.12: + resolution: {integrity: sha512-bbPBYYrtZbkt6Os6FiTLCTFxvq4tt3JKall1vRwshA3fdVztsLAatFaZobhkBC8/BrPetoa0oksYoKXoG4ryJg==} + engines: {node: '>=18'} + hasBin: true - is-utf8@0.2.1: - resolution: {integrity: sha512-rMYPYvCzsXywIsldgLaSoPlw5PfoB/ssr7hY4pLfcodrA5M/eArza1a9VmTiNIBNMjOGr1Ow9mTyU2o69U6U9Q==} + esbuild@0.27.2: + resolution: {integrity: sha512-HyNQImnsOC7X9PMNaCIeAm4ISCQXs5a5YasTXVliKv4uuBo1dKrG0A+uQS8M5eXjVMnLg3WgXaKvprHlFJQffw==} + engines: {node: '>=18'} + hasBin: true - is-weakmap@2.0.2: - resolution: {integrity: sha512-K5pXYOm9wqY1RgjpL3YTkF39tni1XajUIkawTLUo9EZEVUFga5gSQJF8nNS7ZwJQ02y+1YCNYcMh+HIf1ZqE+w==} - engines: {node: '>= 0.4'} + escalade@3.2.0: + resolution: {integrity: sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==} + engines: {node: '>=6'} - is-weakref@1.1.1: - resolution: {integrity: sha512-6i9mGWSlqzNMEqpCp93KwRS1uUOodk2OJ6b+sq7ZPDSy2WuI5NFIxp/254TytR8ftefexkWn5xNiHUNpPOfSew==} - engines: {node: '>= 0.4'} + escape-html@1.0.3: + resolution: {integrity: sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==} - is-weakset@2.0.4: - resolution: {integrity: sha512-mfcwb6IzQyOKTs84CQMrOwW4gQcaTOAWJ0zzJCl2WSPDrWk/OzDaImWFH3djXhb24g4eudZfLRozAvPGw4d9hQ==} - engines: {node: '>= 0.4'} + escape-string-regexp@1.0.5: + resolution: {integrity: sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==} + engines: {node: '>=0.8.0'} - is-windows@1.0.2: - resolution: {integrity: sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==} - engines: {node: '>=0.10.0'} + escape-string-regexp@4.0.0: + resolution: {integrity: sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==} + engines: {node: '>=10'} - is-wsl@2.2.0: - resolution: {integrity: sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==} - engines: {node: '>=8'} + escape-string-regexp@5.0.0: + resolution: {integrity: sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw==} + engines: {node: '>=12'} - isarray@0.0.1: - resolution: {integrity: sha512-D2S+3GLxWH+uhrNEcoh/fnmYeP8E8/zHl644d/jdA0g2uyXvy3sb0qxotE+ne0LtccHknQzWwZEzhak7oJ0COQ==} + esprima@4.0.1: + resolution: {integrity: sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==} + engines: {node: '>=4'} + hasBin: true - isarray@1.0.0: - resolution: {integrity: sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==} + estree-walker@2.0.2: + resolution: {integrity: sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==} - isarray@2.0.5: - resolution: {integrity: sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==} + estree-walker@3.0.3: + resolution: {integrity: sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==} - isbinaryfile@4.0.10: - resolution: {integrity: sha512-iHrqe5shvBUcFbmZq9zOQHBoeOhZJu6RQGrDpBgenUm/Am+F3JM2MgQj+rK3Z601fzrL5gLZWtAPH2OBaSVcyw==} - engines: {node: '>= 8.0.0'} + etag@1.8.1: + resolution: {integrity: sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==} + engines: {node: '>= 0.6'} - isexe@2.0.0: - resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==} + eth-block-tracker@7.1.0: + resolution: {integrity: sha512-8YdplnuE1IK4xfqpf4iU7oBxnOYAc35934o083G8ao+8WM8QQtt/mVlAY6yIAdY1eMeLqg4Z//PZjJGmWGPMRg==} + engines: {node: '>=14.0.0'} - isomorphic-unfetch@3.1.0: - resolution: {integrity: sha512-geDJjpoZ8N0kWexiwkX8F9NkTsXhetLPVbZFQ+JTW239QNOwvB0gniuR1Wc6f0AMTn7/mFGyXvHTifrCp/GH8Q==} + eth-json-rpc-filters@6.0.1: + resolution: {integrity: sha512-ITJTvqoCw6OVMLs7pI8f4gG92n/St6x80ACtHodeS+IXmO0w+t1T5OOzfSt7KLSMLRkVUoexV7tztLgDxg+iig==} + engines: {node: '>=14.0.0'} - isomorphic-ws@4.0.1: - resolution: {integrity: sha512-BhBvN2MBpWTaSHdWRb/bwdZJ1WaehQ2L1KngkCkfLUGF0mAWAT1sQUQacEmQ0jXkFw/czDXPNQSL5u2/Krsz1w==} - peerDependencies: - ws: '>=8.17.1' + eth-query@2.1.2: + resolution: {integrity: sha512-srES0ZcvwkR/wd5OQBRA1bIJMww1skfGS0s8wlwK3/oNP4+wnds60krvu5R1QbpRQjMmpG5OMIWro5s7gvDPsA==} - isows@1.0.7: - resolution: {integrity: sha512-I1fSfDCZL5P0v33sVqeTDSpcstAg/N+wF5HS033mogOVIp4B+oHC7oOCsA3axAbBSGTJ8QubbNmnIRN/h8U7hg==} - peerDependencies: - ws: '>=8.17.1' + eth-rpc-errors@4.0.3: + resolution: {integrity: sha512-Z3ymjopaoft7JDoxZcEb3pwdGh7yiYMhOwm2doUt6ASXlMavpNlK6Cre0+IMl2VSGyEU9rkiperQhp5iRxn5Pg==} - isstream@0.1.2: - resolution: {integrity: sha512-Yljz7ffyPbrLpLngrMtZ7NduUgVvi6wG9RJ9IUcyCd59YQ911PBJphODUcbOVbqYfxe1wuYf/LJ8PauMRwsM/g==} + ethereum-cryptography@0.1.3: + resolution: {integrity: sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==} - istanbul-lib-coverage@3.2.2: - resolution: {integrity: sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg==} - engines: {node: '>=8'} + ethereum-cryptography@1.2.0: + resolution: {integrity: sha512-6yFQC9b5ug6/17CQpCyE3k9eKBMdhyVjzUy1WkiuY/E4vj/SXDBbCw8QEIaXqf0Mf2SnY6RmpDcwlUmBSS0EJw==} - istanbul-lib-hook@3.0.0: - resolution: {integrity: sha512-Pt/uge1Q9s+5VAZ+pCo16TYMWPBIl+oaNIjgLQxcX0itS6ueeaA+pEfThZpH8WxhFgCiEb8sAJY6MdUKgiIWaQ==} - engines: {node: '>=8'} + ethereum-cryptography@2.2.1: + resolution: {integrity: sha512-r/W8lkHSiTLxUxW8Rf3u4HGB0xQweG2RyETjywylKZSzLWoWAijRz8WCuOtJ6wah+avllXBqZuk29HCCvhEIRg==} - istanbul-lib-instrument@4.0.3: - resolution: {integrity: sha512-BXgQl9kf4WTCPCCpmFGoJkz/+uhvm7h7PFKUYxh7qarQd3ER33vHG//qaE8eN25l07YqZPpHXU9I09l/RD5aGQ==} - engines: {node: '>=8'} + ethereumjs-abi@0.6.8: + resolution: {integrity: sha512-Tx0r/iXI6r+lRsdvkFDlut0N08jWMnKRZ6Gkq+Nmw75lZe4e6o3EkSnkaBP5NF6+m5PTGAr9JP43N3LyeoglsA==} + deprecated: This library has been deprecated and usage is discouraged. - istanbul-lib-processinfo@2.0.3: - resolution: {integrity: sha512-NkwHbo3E00oybX6NGJi6ar0B29vxyvNwoC7eJ4G4Yq28UfY758Hgn/heV8VRFhevPED4LXfFz0DQ8z/0kw9zMg==} - engines: {node: '>=8'} + ethereumjs-util@6.2.1: + resolution: {integrity: sha512-W2Ktez4L01Vexijrm5EB6w7dg4n/TgpoYU4avuT5T3Vmnw/eCRtiBrJfQYS/DCSvDIOLn2k57GcHdeBcgVxAqw==} - istanbul-lib-report@3.0.1: - resolution: {integrity: sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw==} - engines: {node: '>=10'} + ethers@6.16.0: + resolution: {integrity: sha512-U1wulmetNymijEhpSEQ7Ct/P/Jw9/e7R1j5XIbPRydgV2DjLVMsULDlNksq3RQnFgKoLlZf88ijYtWEXcPa07A==} + engines: {node: '>=14.0.0'} - istanbul-lib-source-maps@4.0.1: - resolution: {integrity: sha512-n3s8EwkdFIJCG3BPKBYvskgXGoy88ARzvegkitk60NxRdwltLOTaH7CUiMRXvwYorl0Q712iEjcWB+fK/MrWVw==} - engines: {node: '>=10'} + ethjs-util@0.1.6: + resolution: {integrity: sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==} + engines: {node: '>=6.5.0', npm: '>=3'} - istanbul-reports@3.2.0: - resolution: {integrity: sha512-HGYWWS/ehqTV3xN10i23tkPkpH46MLCIMFNCaaKNavAXTF1RkqxawEPtnjnGZ6XKSInBKkiOA5BKS+aZiY3AvA==} - engines: {node: '>=8'} + event-target-shim@5.0.1: + resolution: {integrity: sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ==} + engines: {node: '>=6'} - iterall@1.3.0: - resolution: {integrity: sha512-QZ9qOMdF+QLHxy1QIpUHUU1D5pS2CG2P69LF6L6CPjPYA/XMOmKV3PZpawHoAjHNyB0swdVTRxdYT4tbBbxqwg==} + eventemitter2@6.4.9: + resolution: {integrity: sha512-JEPTiaOt9f04oa6NOkc4aH+nVp5I3wEjpHbIPqfgCdD5v5bUzy7xQqwcVO2aDQgOWhI28da57HksMrzK9HlRxg==} - iterator.prototype@1.1.5: - resolution: {integrity: sha512-H0dkQoCa3b2VEeKQBOxFph+JAbcrQdE7KC0UkqwpLmv2EC4P41QXP+rqo9wYodACiG5/WM5s9oDApTU8utwj9g==} - engines: {node: '>= 0.4'} + eventemitter3@4.0.7: + resolution: {integrity: sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==} - jackspeak@3.4.3: - resolution: {integrity: sha512-OGlZQpz2yfahA/Rd1Y8Cd9SIEsqvXkLVoSw/cgwhnhFMDbsQFeZYoJJ7bIZBS9BcamUW96asq/npPWugM+RQBw==} + eventemitter3@5.0.1: + resolution: {integrity: sha512-GWkBvjiSZK87ELrYOSESUYeVIc9mvLLf/nXalMOS5dYrgZq9o5OVkbZAVM06CVxYsCwH9BDZFPlQTlPA1j4ahA==} - js-base64@3.7.8: - resolution: {integrity: sha512-hNngCeKxIUQiEUN3GPJOkz4wF/YvdUdbNL9hsBcMQTkKzboD7T/q3OYOuuPZLUE6dBxSGpwhk5mwuDud7JVAow==} + events-intercept@2.0.0: + resolution: {integrity: sha512-blk1va0zol9QOrdZt0rFXo5KMkNPVSp92Eju/Qz8THwKWKRKeE0T8Br/1aW6+Edkyq9xHYgYxn2QtOnUKPUp+Q==} - js-cookie@2.2.1: - resolution: {integrity: sha512-HvdH2LzI/EAZcUwA8+0nKNtWHqS+ZmijLA30RwZA0bo7ToCckjK5MkGhjED9KoRcXO6BaGI3I9UIzSA1FKFPOQ==} + events-universal@1.0.1: + resolution: {integrity: sha512-LUd5euvbMLpwOF8m6ivPCbhQeSiYVNb8Vs0fQ8QjXo0JTkEHpz8pxdQf0gStltaPpw0Cca8b39KxvK9cfKRiAw==} - js-sha3@0.5.7: - resolution: {integrity: sha512-GII20kjaPX0zJ8wzkTbNDYMY7msuZcTWk8S5UOh6806Jq/wz1J8/bnr8uGU0DAUmYDjj2Mr4X1cW8v/GLYnR+g==} + events@3.3.0: + resolution: {integrity: sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==} + engines: {node: '>=0.8.x'} - js-sha3@0.8.0: - resolution: {integrity: sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==} + evp_bytestokey@1.0.3: + resolution: {integrity: sha512-/f2Go4TognH/KvCISP7OUsHn85hT9nUkxxA9BEWxFn+Oj9o8ZNLm/40hdlgSLyuOimsrTKLUMEorQexp/aPQeA==} - js-tokens@10.0.0: - resolution: {integrity: sha512-lM/UBzQmfJRo9ABXbPWemivdCW8V2G8FHaHdypQaIy523snUjog0W71ayWXTjiR+ixeMyVHN2XcpnTd/liPg/Q==} + execa@3.2.0: + resolution: {integrity: sha512-kJJfVbI/lZE1PZYDI5VPxp8zXPO9rtxOkhpZ0jMKha56AI9y2gGVC6bkukStQf0ka5Rh15BA5m7cCCH4jmHqkw==} + engines: {node: ^8.12.0 || >=9.7.0} - js-tokens@4.0.0: - resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==} + execa@5.1.1: + resolution: {integrity: sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==} + engines: {node: '>=10'} - js-yaml@3.14.2: - resolution: {integrity: sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg==} - hasBin: true + execa@8.0.1: + resolution: {integrity: sha512-VyhnebXciFV2DESc+p6B+y0LjSm0krU4OgJN44qFAhBY0TJ+1V61tYD2+wHusZ6F9n5K+vl8k0sTy7PEfV4qpg==} + engines: {node: '>=16.17'} - js-yaml@4.1.1: - resolution: {integrity: sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==} - hasBin: true + execa@9.1.0: + resolution: {integrity: sha512-lSgHc4Elo2m6bUDhc3Hl/VxvUDJdQWI40RZ4KMY9bKRc+hgMOT7II/JjbNDhI8VnMtrCb7U/fhpJIkLORZozWw==} + engines: {node: '>=18'} - jsbn@0.1.1: - resolution: {integrity: sha512-UVU9dibq2JcFWxQPA6KCqj5O42VOmAY3zQUfEKxU0KpTGXwNoCjkX1e13eHNvw/xPynt6pU0rZ1htjWTNTSXsg==} + expect-type@1.2.1: + resolution: {integrity: sha512-/kP8CAwxzLVEeFrMm4kMmy4CCDlpipyA7MYLVrdJIkV0fYF0UaigQHRsxHiuY/GEea+bh4KSv3TIlgr+2UL6bw==} + engines: {node: '>=12.0.0'} - jsesc@3.1.0: - resolution: {integrity: sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA==} - engines: {node: '>=6'} - hasBin: true + exsolve@1.0.8: + resolution: {integrity: sha512-LmDxfWXwcTArk8fUEnOfSZpHOJ6zOMUJKOtFLFqJLoKJetuQG874Uc7/Kki7zFLzYybmZhp1M7+98pfMqeX8yA==} - json-bigint@1.0.0: - resolution: {integrity: sha512-SiPv/8VpZuWbvLSMtTDU8hEfrZWg/mH/nV/b4o0CYbSxu1UIQPLdwKOCIyLQX+VIPO5vrLX3i8qtqFyhdPSUSQ==} + extendable-error@0.1.7: + resolution: {integrity: sha512-UOiS2in6/Q0FK0R0q6UY9vYpQ21mr/Qn1KOnte7vsACuNJf514WvCCUHSRCPcgjPT2bAhNIJdlE6bVap1GKmeg==} - json-buffer@3.0.1: - resolution: {integrity: sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==} + extension-port-stream@3.0.0: + resolution: {integrity: sha512-an2S5quJMiy5bnZKEf6AkfH/7r8CzHvhchU40gxN+OM6HPhe7Z9T1FUychcf2M9PpPOO0Hf7BAEfJkw2TDIBDw==} + engines: {node: '>=12.0.0'} - json-canonicalize@1.2.0: - resolution: {integrity: sha512-TTdjBvqrqJKSADlEsY5rWbx8/1tOrVlTR/aSLU8N2VSInCTffP0p+byYB8Es+OmL4ZOeEftjUdvV+eJeSzJC/Q==} + external-editor@3.1.0: + resolution: {integrity: sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==} + engines: {node: '>=4'} - json-canonicalize@2.0.0: - resolution: {integrity: sha512-yyrnK/mEm6Na3ChbJUWueXdapueW0p380RUyTW87XGb1ww8l8hU0pRrGC3vSWHe9CxrbPHX2fGUOZpNiHR0IIg==} + externality@1.0.2: + resolution: {integrity: sha512-LyExtJWKxtgVzmgtEHyQtLFpw1KFhQphF9nTG8TpAIVkiI/xQ3FJh75tRFLYl4hkn7BNIIdLJInuDAavX35pMw==} - json-parse-even-better-errors@2.3.1: - resolution: {integrity: sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==} + fast-copy@3.0.2: + resolution: {integrity: sha512-dl0O9Vhju8IrcLndv2eU4ldt1ftXMqqfgN4H1cpmGV7P6jeB9FwpN9a2c8DPGE1Ys88rNUJVYDHq73CGAGOPfQ==} - json-rpc-engine@5.4.0: - resolution: {integrity: sha512-rAffKbPoNDjuRnXkecTjnsE3xLLrb00rEkdgalINhaYVYIxDwWtvYBr9UFbhTvPB1B2qUOLoFd/cV6f4Q7mh7g==} + fast-deep-equal@3.1.3: + resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} - json-rpc-engine@6.1.0: - resolution: {integrity: sha512-NEdLrtrq1jUZyfjkr9OCz9EzCNhnRyWtt1PAnvnhwy6e8XETS0Dtc+ZNCO2gvuAoKsIn2+vCSowXTYE4CkgnAQ==} - engines: {node: '>=10.0.0'} + fast-fifo@1.3.2: + resolution: {integrity: sha512-/d9sfos4yxzpwkDkuN7k2SqFKtYNmCTzgfEpz82x34IM9/zc8KGxQoXg1liNC/izpRM/MBdt44Nmx41ZWqk+FQ==} - json-rpc-random-id@1.0.1: - resolution: {integrity: sha512-RJ9YYNCkhVDBuP4zN5BBtYAzEl03yq/jIIsyif0JY9qyJuQQZNeDK7anAPKKlyEtLSj2s8h6hNh2F8zO5q7ScA==} + fast-glob@3.3.2: + resolution: {integrity: sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==} + engines: {node: '>=8.6.0'} - json-schema-traverse@0.4.1: - resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==} + fast-glob@3.3.3: + resolution: {integrity: sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==} + engines: {node: '>=8.6.0'} - json-schema-traverse@1.0.0: - resolution: {integrity: sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==} + fast-npm-meta@0.4.7: + resolution: {integrity: sha512-aZU3i3eRcSb2NCq8i6N6IlyiTyF6vqAqzBGl2NBF6ngNx/GIqfYbkLDIKZ4z4P0o/RmtsFnVqHwdrSm13o4tnQ==} - json-schema@0.4.0: - resolution: {integrity: sha512-es94M3nTIfsEPisRafak+HDLfHXnKBhV3vU5eqPcS3flIWqcxJWgXHXiey3YrpaNsanY5ei1VoYEbOzijuq9BA==} + fast-redact@3.1.2: + resolution: {integrity: sha512-+0em+Iya9fKGfEQGcd62Yv6onjBmmhV1uh86XVfOU8VwAe6kaFdQCWI9s0/Nnugx5Vd9tdbZ7e6gE2tR9dzXdw==} + engines: {node: '>=6'} - json-stable-stringify-without-jsonify@1.0.1: - resolution: {integrity: sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==} + fast-safe-stringify@2.1.1: + resolution: {integrity: sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA==} - json-stable-stringify@1.3.0: - resolution: {integrity: sha512-qtYiSSFlwot9XHtF9bD9c7rwKjr+RecWT//ZnPvSmEjpV5mmPOCN4j8UjY5hbjNkOwZ/jQv3J6R1/pL7RwgMsg==} - engines: {node: '>= 0.4'} + fast-xml-parser@5.2.5: + resolution: {integrity: sha512-pfX9uG9Ki0yekDHx2SiuRIyFdyAr1kMIMitPvb0YBo8SUfKvia7w7FIyd/l6av85pFYRhZscS75MwMnbvY+hcQ==} + hasBin: true - json-stream-stringify@3.1.6: - resolution: {integrity: sha512-x7fpwxOkbhFCaJDJ8vb1fBY3DdSa4AlITaz+HHILQJzdPMnHEFjxPwVUi1ALIbcIxDE0PNe/0i7frnY8QnBQog==} - engines: {node: '>=7.10.1'} + fastq@1.15.0: + resolution: {integrity: sha512-wBrocU2LCXXa+lWBt8RoIRD89Fi8OdABODa/kEnyeyjS5aZO5/GNvI5sEINADqP/h8M29UHTHUb53sUu5Ihqdw==} - json-stringify-safe@5.0.1: - resolution: {integrity: sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA==} + fd-slicer@1.1.0: + resolution: {integrity: sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g==} - json5@1.0.2: - resolution: {integrity: sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==} - hasBin: true + fdir@6.1.1: + resolution: {integrity: sha512-QfKBVg453Dyn3mr0Q0O+Tkr1r79lOTAKSi9f/Ot4+qVEwxWhav2Z+SudrG9vQjM2aYRMQQZ2/Q1zdA8ACM1pDg==} + peerDependencies: + picomatch: 3.x + peerDependenciesMeta: + picomatch: + optional: true - json5@2.2.3: - resolution: {integrity: sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==} - engines: {node: '>=6'} - hasBin: true + fdir@6.5.0: + resolution: {integrity: sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==} + engines: {node: '>=12.0.0'} + peerDependencies: + picomatch: ^3 || ^4 + peerDependenciesMeta: + picomatch: + optional: true - jsonfile@2.4.0: - resolution: {integrity: sha512-PKllAqbgLgxHaj8TElYymKCAgrASebJrWpTnEkOaTowt23VKXXN0sUeriJ+eh7y6ufb/CC5ap11pz71/cM0hUw==} + fflate@0.8.2: + resolution: {integrity: sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==} - jsonfile@4.0.0: - resolution: {integrity: sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==} + figures@6.1.0: + resolution: {integrity: sha512-d+l3qxjSesT4V7v2fh+QnmFnUWv9lSpjarhShNTgBOfA0ttejbQUAlHLitbjkoRiDulW0OPoQPYIGhIC8ohejg==} + engines: {node: '>=18'} - jsonfile@6.2.0: - resolution: {integrity: sha512-FGuPw30AdOIUTRMC2OMRtQV+jkVj2cfPqSeWXv1NEAJ1qZ5zb1X6z1mFhbfOB/iy3ssJCD+3KuZ8r8C3uVFlAg==} + file-uri-to-path@1.0.0: + resolution: {integrity: sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==} - jsonify@0.0.1: - resolution: {integrity: sha512-2/Ki0GcmuqSrgFyelQq9M05y7PS0mEwuIzrf3f1fPqkVDVRvZrPZtVSMHxdgo8Aq0sxAOb/cr2aqqA3LeWHVPg==} + fill-range@7.0.1: + resolution: {integrity: sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==} + engines: {node: '>=8'} - jsonparse@1.3.1: - resolution: {integrity: sha512-POQXvpdL69+CluYsillJ7SUhKvytYjW9vG/GKpnf+xP8UWgYEM/RaMzHHofbALDiKbbP1W8UEYmgGl39WkPZsg==} - engines: {'0': node >= 0.2.0} + fill-range@7.1.1: + resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==} + engines: {node: '>=8'} - jsonschema@1.5.0: - resolution: {integrity: sha512-K+A9hhqbn0f3pJX17Q/7H6yQfD/5OXgdrR5UE12gMXCiN9D5Xq2o5mddV2QEcX/bjla99ASsAAQUyMCCRWAEhw==} + filter-obj@1.1.0: + resolution: {integrity: sha512-8rXg1ZnX7xzy2NGDVkBVaAy+lSlPNwad13BtgSlLuxfIslyt5Vg64U7tFcCt4WS1R0hvtnQybT/IyCkGZ3DpXQ==} + engines: {node: '>=0.10.0'} - jsprim@1.4.2: - resolution: {integrity: sha512-P2bSOMAc/ciLz6DzgjVlGJP9+BrJWu5UDGK70C2iweC5QBIeFf0ZXRvGjEj2uYgrY2MkAAhsSWHDWlFtEroZWw==} - engines: {node: '>=0.6.0'} + find-up@2.1.0: + resolution: {integrity: sha512-NWzkk0jSJtTt08+FBFMvXoeZnOJD+jTtsRmBYbAIzJdX6l7dLgR7CTubCM5/eDdPUBvLCeVasP1brfVR/9/EZQ==} + engines: {node: '>=4'} - jsprim@2.0.2: - resolution: {integrity: sha512-gqXddjPqQ6G40VdnI6T6yObEC+pDNvyP95wdQhkWkg7crHH3km5qP1FsOXEkzEQwnz6gz5qGTn1c2Y52wP3OyQ==} - engines: {'0': node >=0.6.0} + find-up@4.1.0: + resolution: {integrity: sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==} + engines: {node: '>=8'} - jsx-ast-utils@3.3.5: - resolution: {integrity: sha512-ZZow9HBI5O6EPgSJLUb8n2NKgmVWTwCvHGwFuJlMjvLFqlGG6pjirPhtdsseaLZjSibD8eegzmYpUZwoIlj2cQ==} - engines: {node: '>=4.0'} + find-up@5.0.0: + resolution: {integrity: sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==} + engines: {node: '>=10'} - jwt-decode@4.0.0: - resolution: {integrity: sha512-+KJGIyHgkGuIq3IEBNftfhW/LfWhXUIY6OmyVWjliu5KH1y0fw7VQ8YndE2O4qZdMSd9SqbnC8GOcZEy0Om7sA==} - engines: {node: '>=18'} + fixturez@1.1.0: + resolution: {integrity: sha512-c4q9eZsAmCzj9gkrEO/YwIRlrHWt/TXQiX9jR9WeLFOqeeV6EyzdiiV28CpSzF6Ip+gyYrSv5UeOHqyzfcNTVA==} - keccak256@1.0.6: - resolution: {integrity: sha512-8GLiM01PkdJVGUhR1e6M/AvWnSqYS0HaERI+K/QtStGDGlSTx2B1zTqZk4Zlqu5TxHJNTxWAdP9Y+WI50OApUw==} + flag@5.0.1: + resolution: {integrity: sha512-4P/rvPGKcFBneboyYHMOKbKaJL5ZhNjScbY7bGToas7FgBvrTWbh76yxRaoSoFe3HSjWc6IJ0EajUwSadcP6Lg==} + peerDependencies: + react: ^18 - keccak@3.0.1: - resolution: {integrity: sha512-epq90L9jlFWCW7+pQa6JOnKn2Xgl2mtI664seYR6MHskvI9agt7AnDqmAlp9TqU4/caMYbA08Hi5DMZAl5zdkA==} - engines: {node: '>=10.0.0'} + flat@5.0.2: + resolution: {integrity: sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==} + hasBin: true - keccak@3.0.4: - resolution: {integrity: sha512-3vKuW0jV8J3XNTzvfyicFR5qvxrSAGl7KIhvgOu5cmWwM7tZRj3fMbj/pfIf4be7aznbc+prBWGjywox/g2Y6Q==} - engines: {node: '>=10.0.0'} + floating-vue@5.2.2: + resolution: {integrity: sha512-afW+h2CFafo+7Y9Lvw/xsqjaQlKLdJV7h1fCHfcYQ1C4SVMlu7OAekqWgu5d4SgvkBVU0pVpLlVsrSTBURFRkg==} + peerDependencies: + '@nuxt/kit': ^3.2.0 + vue: ^3.2.0 + peerDependenciesMeta: + '@nuxt/kit': + optional: true - keyv@4.5.4: - resolution: {integrity: sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==} + focus-trap@7.6.0: + resolution: {integrity: sha512-1td0l3pMkWJLFipobUcGaf+5DTY4PLDDrcqoSaKP8ediO/CoWCCYk/fT/Y2A4e6TNB+Sh6clRJCjOPPnKoNHnQ==} - kind-of@6.0.3: - resolution: {integrity: sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==} - engines: {node: '>=0.10.0'} + follow-redirects@1.15.2: + resolution: {integrity: sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==} + engines: {node: '>=4.0'} + peerDependencies: + debug: '*' + peerDependenciesMeta: + debug: + optional: true - klaw@1.3.1: - resolution: {integrity: sha512-TED5xi9gGQjGpNnvRWknrwAB1eL5GciPfVFOt3Vk1OJCVDQbzuSfrF3hkUQKlsgKrG1F+0t5W0m+Fje1jIt8rw==} + for-each@0.3.5: + resolution: {integrity: sha512-dKx12eRCVIzqCxFGplyFKJMPvLEWgmNtUrpTiJIR5u97zEhRG8ySrtboPHZXx7daLxQVrl643cTzbab2tkQjxg==} + engines: {node: '>= 0.4'} - kleur@3.0.3: - resolution: {integrity: sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==} - engines: {node: '>=6'} + foreground-child@3.3.1: + resolution: {integrity: sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==} + engines: {node: '>=14'} - lcid@1.0.0: - resolution: {integrity: sha512-YiGkH6EnGrDGqLMITnGjXtGmNtjoXw9SVUzcaos8RBi7Ps0VBylkq+vOcY9QE5poLasPCR849ucFUkl0UzUyOw==} - engines: {node: '>=0.10.0'} + fp-ts@1.19.3: + resolution: {integrity: sha512-H5KQDspykdHuztLTg+ajGN0Z2qUjcEf3Ybxc6hLt0k7/zPkn29XnKnxlBPyW2XIddWrGaJBzBl4VLYOtk39yZg==} - lefthook-darwin-arm64@2.1.6: - resolution: {integrity: sha512-hyB7eeiX78BS66f70byTJacDLC/xV1vgMv9n+idFUsrM7J3Udd/ag9Ag5NP3t0eN0EqQqAtrNnt35EH01lxnRQ==} - cpu: [arm64] - os: [darwin] + fraction.js@5.3.4: + resolution: {integrity: sha512-1X1NTtiJphryn/uLQz3whtY6jK3fTqoE3ohKs0tT+Ujr1W59oopxmoEh7Lu5p6vBaPbgoM0bzveAW4Qi5RyWDQ==} - lefthook-darwin-x64@2.1.6: - resolution: {integrity: sha512-5Ka6cFxiH83krt+OMRQtmS6zqoZR5SLXSudLjTbZA1c3ZqF0+dqkeb4XcB6plx6WR0GFizabuc6Bi3iXPIe1eQ==} - cpu: [x64] - os: [darwin] + framer-motion@12.23.26: + resolution: {integrity: sha512-cPcIhgR42xBn1Uj+PzOyheMtZ73H927+uWPDVhUMqxy8UHt6Okavb6xIz9J/phFUHUj0OncR6UvMfJTXoc/LKA==} + peerDependencies: + '@emotion/is-prop-valid': '*' + react: ^18.0.0 || ^19.0.0 + react-dom: ^18.0.0 || ^19.0.0 + peerDependenciesMeta: + '@emotion/is-prop-valid': + optional: true + react: + optional: true + react-dom: + optional: true - lefthook-freebsd-arm64@2.1.6: - resolution: {integrity: sha512-VswyOg5CVN3rMaOJ2HtnkltiMKgFHW/wouWxXsV8RxSa4tgWOKxM0EmSXi8qc2jX+LRga6B0uOY6toXS01zWxA==} - cpu: [arm64] - os: [freebsd] + fresh@2.0.0: + resolution: {integrity: sha512-Rx/WycZ60HOaqLKAi6cHRKKI7zxWbJ31MhntmtwMoaTeF7XFH9hhBp8vITaMidfljRQ6eYWCKkaTK+ykVJHP2A==} + engines: {node: '>= 0.8'} - lefthook-freebsd-x64@2.1.6: - resolution: {integrity: sha512-vXsCUFYuVwrVWwcypB7Zt2Hf+5pl1V1la7ZfvGYZaTRURu0zF/XUnMF/nOz/PebGv0f4x/iOWXWwP7E42xRWsg==} - cpu: [x64] - os: [freebsd] - - lefthook-linux-arm64@2.1.6: - resolution: {integrity: sha512-WDJiQhJdZOvKORZd+kF/ms2l6NSsXzdA9ahflyr65V90AC4jES223W8VtEMbGPUtHuGWMEZ/v/XvwlWv0Ioz9g==} - cpu: [arm64] - os: [linux] - - lefthook-linux-x64@2.1.6: - resolution: {integrity: sha512-C18nCd7nTX1AVL4TcvwMmLAO1VI1OuGluIOTjiPkBQ746Ls1HhL5rl//jMPACmT28YmxIQJ2ZcLPNmhvEVBZvw==} - cpu: [x64] - os: [linux] - - lefthook-openbsd-arm64@2.1.6: - resolution: {integrity: sha512-mZOMxM8HiPxVFXDO3PtCUbH4GB8rkveXhsgXF27oAZTYVzQ3gO9vT6r/pxit6msqRXz3fvcwimLVJgb8eRsa8A==} - cpu: [arm64] - os: [openbsd] - - lefthook-openbsd-x64@2.1.6: - resolution: {integrity: sha512-sG9ALLZSnnMOfXu+B7SmxFhJhuoAh4bqi5En5aaHJET48TqrLOcWWZuH+7ArFM6gr/U5KfSUvdmHFmY8WqCcIg==} - cpu: [x64] - os: [openbsd] - - lefthook-windows-arm64@2.1.6: - resolution: {integrity: sha512-lD8yFWY4Csuljd0Rqs7EQaySC0VvDf7V3rN1FhRMUISTRDHutebIom1Loc8ckQPvKYGC6mftT9k0GvipsS+Brw==} - cpu: [arm64] - os: [win32] - - lefthook-windows-x64@2.1.6: - resolution: {integrity: sha512-q4z2n3xucLscoWiyMwFViEj3N8MDSkPulMwcJYuCYFHoPhP1h+icqNu7QRLGYj6AnVrCQweiUJY3Tb2X+GbD/A==} - cpu: [x64] - os: [win32] - - lefthook@2.1.6: - resolution: {integrity: sha512-w9sBoR0mdN+kJc3SB85VzpiAAl451/rxdCRcZlwW71QLjkeH3EBQFgc4VMj5apePychYDHAlqEWTB8J8JK/j1Q==} - hasBin: true - - level-codec@7.0.1: - resolution: {integrity: sha512-Ua/R9B9r3RasXdRmOtd+t9TCOEIIlts+TN/7XTT2unhDaL6sJn83S3rUyljbr6lVtw49N3/yA0HHjpV6Kzb2aQ==} - deprecated: Superseded by level-transcoder (https://github.com/Level/community#faq) - - level-codec@9.0.2: - resolution: {integrity: sha512-UyIwNb1lJBChJnGfjmO0OR+ezh2iVu1Kas3nvBS/BzGnx79dv6g7unpKIDNPMhfdTEGoc7mC8uAu51XEtX+FHQ==} - engines: {node: '>=6'} - deprecated: Superseded by level-transcoder (https://github.com/Level/community#faq) - - level-concat-iterator@2.0.1: - resolution: {integrity: sha512-OTKKOqeav2QWcERMJR7IS9CUo1sHnke2C0gkSmcR7QuEtFNLLzHQAvnMw8ykvEcv0Qtkg0p7FOwP1v9e5Smdcw==} - engines: {node: '>=6'} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + fs-extra@0.30.0: + resolution: {integrity: sha512-UvSPKyhMn6LEd/WpUaV9C9t3zATuqoqfWc3QdPhPLb58prN9tqYPlPWi8Krxi44loBoUzlobqZ3+8tGpxxSzwA==} - level-concat-iterator@3.1.0: - resolution: {integrity: sha512-BWRCMHBxbIqPxJ8vHOvKUsaO0v1sLYZtjN3K2iZJsRBYtp+ONsY6Jfi6hy9K3+zolgQRryhIn2NRZjZnWJ9NmQ==} - engines: {node: '>=10'} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + fs-extra@11.1.0: + resolution: {integrity: sha512-0rcTq621PD5jM/e0a3EJoGC/1TC5ZBCERW82LQuwfGnCa1V8w7dpYH1yNu+SLb6E5dkeCBzKEyLGlFrnr+dUyw==} + engines: {node: '>=14.14'} - level-errors@1.0.5: - resolution: {integrity: sha512-/cLUpQduF6bNrWuAC4pwtUKA5t669pCsCi2XbmojG2tFeOr9j6ShtdDCtFFQO1DRt+EVZhx9gPzP9G2bUaG4ig==} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + fs-extra@5.0.0: + resolution: {integrity: sha512-66Pm4RYbjzdyeuqudYqhFiNBbCIuI9kgRqLPSHIlXHidW8NIQtVdkM1yeZ4lXwuhbTETv3EUGMNHAAw6hiundQ==} - level-errors@2.0.1: - resolution: {integrity: sha512-UVprBJXite4gPS+3VznfgDSU8PTRuVX0NXwoWW50KLxd2yw4Y1t2JUR5In1itQnudZqRMT9DlAM3Q//9NCjCFw==} - engines: {node: '>=6'} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + fs-extra@7.0.1: + resolution: {integrity: sha512-YJDaCJZEnBmcbw13fvdAM9AwNOJwOzrE4pqMqBq5nFiEqXUqHwlK4B+3pUw6JNvfSPtX05xFHtYy/1ni01eGCw==} + engines: {node: '>=6 <7 || >=8'} - level-iterator-stream@1.3.1: - resolution: {integrity: sha512-1qua0RHNtr4nrZBgYlpV0qHHeHpcRRWTxEZJ8xsemoHAXNL5tbooh4tPEEqIqsbWCAJBmUmkwYK/sW5OrFjWWw==} + fs-extra@8.1.0: + resolution: {integrity: sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==} + engines: {node: '>=6 <7 || >=8'} - level-iterator-stream@4.0.2: - resolution: {integrity: sha512-ZSthfEqzGSOMWoUGhTXdX9jv26d32XJuHz/5YnuHZzH6wldfWMOVwI9TBtKcya4BKTyTt3XVA0A3cF3q5CY30Q==} - engines: {node: '>=6'} + fs-minipass@2.1.0: + resolution: {integrity: sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==} + engines: {node: '>= 8'} - level-mem@5.0.1: - resolution: {integrity: sha512-qd+qUJHXsGSFoHTziptAKXoLX87QjR7v2KMbqncDXPxQuCdsQlzmyX+gwrEHhlzn08vkf8TyipYyMmiC6Gobzg==} - engines: {node: '>=6'} - deprecated: Superseded by memory-level (https://github.com/Level/community#faq) + fs.realpath@1.0.0: + resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} - level-packager@5.1.1: - resolution: {integrity: sha512-HMwMaQPlTC1IlcwT3+swhqf/NUO+ZhXVz6TY1zZIIZlIR0YSn8GtAAWmIvKjNY16ZkEg/JcpAuQskxsXqC0yOQ==} - engines: {node: '>=6'} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + fsevents@2.3.3: + resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} + engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} + os: [darwin] - level-supports@1.0.1: - resolution: {integrity: sha512-rXM7GYnW8gsl1vedTJIbzOrRv85c/2uCMpiiCzO2fndd06U/kUXEEU9evYn4zFggBOg36IsBW8LzqIpETwwQzg==} - engines: {node: '>=6'} + function-bind@1.1.2: + resolution: {integrity: sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==} - level-supports@2.1.0: - resolution: {integrity: sha512-E486g1NCjW5cF78KGPrMDRBYzPuueMZ6VBXHT6gC7A8UYWGiM14fGgp+s/L1oFfDWSPV/+SFkYCmZ0SiESkRKA==} + fuse.js@7.1.0: + resolution: {integrity: sha512-trLf4SzuuUxfusZADLINj+dE8clK1frKdmqiJNb1Es75fmI5oY6X2mxLVUciLLjxqw/xr72Dhy+lER6dGd02FQ==} engines: {node: '>=10'} - level-supports@4.0.1: - resolution: {integrity: sha512-PbXpve8rKeNcZ9C1mUicC9auIYFyGpkV9/i6g76tLgANwWhtG2v7I4xNBUlkn3lE2/dZF3Pi0ygYGtLc4RXXdA==} - engines: {node: '>=12'} + generator-function@2.0.1: + resolution: {integrity: sha512-SFdFmIJi+ybC0vjlHN0ZGVGHc3lgE0DxPAT0djjVg+kjOnSqclqmj0KQ7ykTOLP6YxoqOvuAODGdcHJn+43q3g==} + engines: {node: '>= 0.4'} - level-transcoder@1.0.1: - resolution: {integrity: sha512-t7bFwFtsQeD8cl8NIoQ2iwxA0CL/9IFw7/9gAjOonH0PWTTiRfY7Hq+Ejbsxh86tXobDQ6IOiddjNYIfOBs06w==} - engines: {node: '>=12'} + generic-pool@3.4.2: + resolution: {integrity: sha512-H7cUpwCQSiJmAHM4c/aFu6fUfrhWXW1ncyh8ftxEPMu6AiYkHw9K8br720TGPZJbk5eOH2bynjZD1yPvdDAmag==} + engines: {node: '>= 4'} - level-ws@0.0.0: - resolution: {integrity: sha512-XUTaO/+Db51Uiyp/t7fCMGVFOTdtLS/NIACxE/GHsij15mKzxksZifKVjlXDF41JMUP/oM1Oc4YNGdKnc3dVLw==} + gensync@1.0.0-beta.2: + resolution: {integrity: sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==} + engines: {node: '>=6.9.0'} - level-ws@2.0.0: - resolution: {integrity: sha512-1iv7VXx0G9ec1isqQZ7y5LmoZo/ewAsyDHNA8EFDW5hqH2Kqovm33nSFkSdnLLAK+I5FlT+lo5Cw9itGe+CpQA==} - engines: {node: '>=6'} + get-caller-file@2.0.5: + resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} + engines: {node: 6.* || 8.* || >= 10.*} - levelup@1.3.9: - resolution: {integrity: sha512-VVGHfKIlmw8w1XqpGOAGwq6sZm2WwWLmlDcULkKWQXEA5EopA8OBNJ2Ck2v6bdk8HeEZSbCSEgzXadyQFm76sQ==} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) + get-intrinsic@1.3.0: + resolution: {integrity: sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==} + engines: {node: '>= 0.4'} - levelup@4.4.0: - resolution: {integrity: sha512-94++VFO3qN95cM/d6eBXvd894oJE0w3cInq9USsyQzzoJxmiYzPAocNcuGCPGGjoXqDVJcr3C1jzt1TSjyaiLQ==} + get-nonce@1.0.1: + resolution: {integrity: sha512-FJhYRoDaiatfEkUK8HKlicmu/3SGFD51q3itKDGoSTysQJBnfOcxU5GxnhE1E6soB76MbT0MBtnKJuXyAx+96Q==} engines: {node: '>=6'} - deprecated: Superseded by abstract-level (https://github.com/Level/community#faq) - - levn@0.3.0: - resolution: {integrity: sha512-0OO4y2iOHix2W6ujICbKIaEQXvFQHue65vUG3pb5EUomzPI90z9hsA1VsO/dbIIpC53J8gxM9Q4Oho0jrCM/yA==} - engines: {node: '>= 0.8.0'} - levn@0.4.1: - resolution: {integrity: sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==} - engines: {node: '>= 0.8.0'} + get-port-please@3.2.0: + resolution: {integrity: sha512-I9QVvBw5U/hw3RmWpYKRumUeaDgxTPd401x364rLmWBJcOQ753eov1eTgzDqRG9bqFIfDc7gfzcQEWrUri3o1A==} - lines-and-columns@1.2.4: - resolution: {integrity: sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==} + get-port@7.1.0: + resolution: {integrity: sha512-QB9NKEeDg3xxVwCCwJQ9+xycaz6pBB6iQ76wiWMl1927n0Kir6alPiP+yuiICLLU4jpMe08dXfpebuQppFA2zw==} + engines: {node: '>=16'} - load-json-file@1.1.0: - resolution: {integrity: sha512-cy7ZdNRXdablkXYNI049pthVeXFurRyb9+hA/dZzerZ0pGTx42z+y+ssxBaVV2l70t1muq5IdKhn4UtcoGUY9A==} - engines: {node: '>=0.10.0'} + get-proto@1.0.1: + resolution: {integrity: sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==} + engines: {node: '>= 0.4'} - locate-path@5.0.0: - resolution: {integrity: sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==} + get-stream@5.2.0: + resolution: {integrity: sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==} engines: {node: '>=8'} - locate-path@6.0.0: - resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==} + get-stream@6.0.1: + resolution: {integrity: sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==} engines: {node: '>=10'} - lodash.assign@4.2.0: - resolution: {integrity: sha512-hFuH8TY+Yji7Eja3mGiuAxBqLagejScbG8GbG0j6o9vzn0YL14My+ktnqtZgFTosKymC9/44wP6s7xyuLfnClw==} - - lodash.camelcase@4.3.0: - resolution: {integrity: sha512-TwuEnCnxbc3rAvhf/LbG7tJUDzhqXyFnv3dtzLOPgCG/hODL7WFnsbwktkD7yUV0RrreP/l1PALq/YSg6VvjlA==} + get-stream@8.0.1: + resolution: {integrity: sha512-VaUJspBffn/LMCJVoMvSAdmscJyS1auj5Zulnn5UoYcY531UWmdwhRWkcGKnGU93m5HSXP9LP2usOryrBtQowA==} + engines: {node: '>=16'} - lodash.clonedeep@4.5.0: - resolution: {integrity: sha512-H5ZhCF25riFd9uB5UCkVKo61m3S/xZk1x4wA6yp/L3RFP6Z/eHH1ymQcGLo7J3GMPfm0V/7m1tryHuGVxpqEBQ==} + get-stream@9.0.1: + resolution: {integrity: sha512-kVCxPF3vQM/N0B1PmoqVUqgHP+EeVjmZSQn+1oCRPxd2P21P2F19lIgbR3HBosbB1PUhOAoctJnfEn2GbN2eZA==} + engines: {node: '>=18'} - lodash.flattendeep@4.4.0: - resolution: {integrity: sha512-uHaJFihxmJcEX3kT4I23ABqKKalJ/zDrDg0lsFtc1h+3uw49SIJ5beyhx5ExVRti3AvKoOJngIj7xz3oylPdWQ==} + get-tsconfig@4.13.0: + resolution: {integrity: sha512-1VKTZJCwBrvbd+Wn3AOgQP/2Av+TfTCOlE4AcRJE72W1ksZXbAx8PPBR9RzgTeSPzlPMHrbANMH3LbltH73wxQ==} - lodash.get@4.4.2: - resolution: {integrity: sha512-z+Uw/vLuy6gQe8cfaFWD7p0wVv8fJl3mbzXh33RS+0oW2wvUqiRXiQ69gLWSLpgB5/6sU+r6BlQR0MBILadqTQ==} - deprecated: This package is deprecated. Use the optional chaining (?.) operator instead. + giget@2.0.0: + resolution: {integrity: sha512-L5bGsVkxJbJgdnwyuheIunkGatUF/zssUoxxjACCseZYAVbaqdh9Tsmmlkl8vYan09H7sbvKt4pS8GqKLBrEzA==} + hasBin: true - lodash.isequal@4.5.0: - resolution: {integrity: sha512-pDo3lu8Jhfjqls6GkMgpahsF9kCyayhgykjyLMNFTKWrpVdAQtYyB4muAMWozBB4ig/dtWAmsMxLEI8wuz+DYQ==} - deprecated: This package is deprecated. Use require('node:util').isDeepStrictEqual instead. + git-up@8.1.1: + resolution: {integrity: sha512-FDenSF3fVqBYSaJoYy1KSc2wosx0gCvKP+c+PRBht7cAaiCeQlBtfBDX9vgnNOHmdePlSFITVcn4pFfcgNvx3g==} - lodash.merge@4.6.2: - resolution: {integrity: sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==} + git-url-parse@16.1.0: + resolution: {integrity: sha512-cPLz4HuK86wClEW7iDdeAKcCVlWXmrLpb2L+G9goW0Z1dtpNS6BXXSOckUTlJT/LDQViE1QZKstNORzHsLnobw==} - lodash.startcase@4.4.0: - resolution: {integrity: sha512-+WKqsK294HMSc2jEbNgpHpd0JfIBhp7rEV4aqXWqFr6AlXov+SlcgB1Fv01y2kGe3Gc8nMW7VA0SrGuSkRfIEg==} + glob-parent@5.1.2: + resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==} + engines: {node: '>= 6'} - lodash.truncate@4.4.2: - resolution: {integrity: sha512-jttmRe7bRse52OsWIMDLaXxWqRAmtIUccAQ3garviCqJjafXOfNMO0yMfNpdD6zbGaTU0P5Nz7e7gAT6cKmJRw==} + glob@10.5.0: + resolution: {integrity: sha512-DfXN8DfhJ7NH3Oe7cFmu3NCu1wKbkReJ8TorzSAFbSKrlNaQSKfIzqYqVY8zlbs2NLBbWpRiU52GX2PbaBVNkg==} + hasBin: true - lodash@4.18.1: - resolution: {integrity: sha512-dMInicTPVE8d1e5otfwmmjlxkZoUpiVLwyeTdUsi/Caj/gfzzblBcCE5sRHV/AsjuCmxWrte2TNGSYuCeCq+0Q==} + glob@13.0.0: + resolution: {integrity: sha512-tvZgpqk6fz4BaNZ66ZsRaZnbHvP/jG3uKJvAZOwEVUL4RTA5nJeeLYfyN9/VA8NX/V3IBG+hkeuGpKjvELkVhA==} + engines: {node: 20 || >=22} - log-symbols@3.0.0: - resolution: {integrity: sha512-dSkNGuI7iG3mfvDzUuYZyvk5dD9ocYCYzNU6CYDE6+Xqd+gwme6Z00NS3dUh8mq/73HaEtT7m6W+yUPtU6BZnQ==} - engines: {node: '>=8'} + glob@7.2.0: + resolution: {integrity: sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==} + deprecated: Glob versions prior to v9 are no longer supported - log-symbols@4.1.0: - resolution: {integrity: sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==} - engines: {node: '>=10'} + glob@7.2.3: + resolution: {integrity: sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==} + deprecated: Glob versions prior to v9 are no longer supported - loose-envify@1.4.0: - resolution: {integrity: sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==} - hasBin: true + global-directory@4.0.1: + resolution: {integrity: sha512-wHTUcDUoZ1H5/0iVqEudYW4/kAlN5cZ3j/bXn0Dpbizl9iaUVeWSHqiOjsgk6OW2bkLclbBjzewBz6weQ1zA2Q==} + engines: {node: '>=18'} - loupe@2.3.7: - resolution: {integrity: sha512-zSMINGVYkdpYSOBmLi0D1Uo7JU9nVdQKrHxC8eYlV+9YKK9WePqAlL7lSlorG/U2Fw1w0hTBmaa/jrQ3UbPHtA==} + globals@11.12.0: + resolution: {integrity: sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==} + engines: {node: '>=4'} - lower-case-first@1.0.2: - resolution: {integrity: sha512-UuxaYakO7XeONbKrZf5FEgkantPf5DUqDayzP5VXZrtRPdH86s4kN47I8B3TW10S4QKiE3ziHNf3kRN//okHjA==} + globby@11.1.0: + resolution: {integrity: sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==} + engines: {node: '>=10'} - lower-case@1.1.4: - resolution: {integrity: sha512-2Fgx1Ycm599x+WGpIYwJOvsjmXFzTSc34IwDWALRA/8AopUKAVPwfJ+h5+f85BCp0PWmmJcWzEpxOpoXycMpdA==} + globby@15.0.0: + resolution: {integrity: sha512-oB4vkQGqlMl682wL1IlWd02tXCbquGWM4voPEI85QmNKCaw8zGTm1f1rubFgkg3Eli2PtKlFgrnmUqasbQWlkw==} + engines: {node: '>=20'} - lowercase-keys@2.0.0: - resolution: {integrity: sha512-tqNXrS78oMOE73NMxK4EMLQsQowWf8jKooH9g7xPavRT706R6bkQJ6DY2Te7QukaZsulxa30wQ7bk0pm4XiHmA==} - engines: {node: '>=8'} + globby@7.1.1: + resolution: {integrity: sha512-yANWAN2DUcBtuus5Cpd+SKROzXHs2iVXFZt/Ykrfz6SAXqacLX25NZpltE+39ceMexYF4TtEadjuSTw8+3wX4g==} + engines: {node: '>=4'} - lowercase-keys@3.0.0: - resolution: {integrity: sha512-ozCC6gdQ+glXOQsveKD0YsDy8DSQFjDTz4zyzEHNV5+JP5D62LmfDZ6o1cycFx9ouG940M5dE8C8CTewdj2YWQ==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + gopd@1.2.0: + resolution: {integrity: sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==} + engines: {node: '>= 0.4'} - lru-cache@10.4.3: - resolution: {integrity: sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==} + graceful-fs@4.2.11: + resolution: {integrity: sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==} - lru-cache@11.3.5: - resolution: {integrity: sha512-NxVFwLAnrd9i7KUBxC4DrUhmgjzOs+1Qm50D3oF1/oL+r1NpZ4gA7xvG0/zJ8evR7zIKn4vLf7qTNduWFtCrRw==} - engines: {node: 20 || >=22} + graphql@16.8.1: + resolution: {integrity: sha512-59LZHPdGZVh695Ud9lRzPBVTtlX9ZCV150Er2W43ro37wVof0ctenSaskPPjN7lVTIN8mSZt8PHUNKZuNQUuxw==} + engines: {node: ^12.22.0 || ^14.16.0 || ^16.0.0 || >=17.0.0} - lru-cache@5.1.1: - resolution: {integrity: sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==} + gzip-size@6.0.0: + resolution: {integrity: sha512-ax7ZYomf6jqPTQ4+XCpUGyXKHk5WweS+e05MBO4/y3WJ5RkmPXNKvX+bx1behVILVwr6JSQvZAku021CHPXG3Q==} + engines: {node: '>=10'} - lru-cache@7.18.3: - resolution: {integrity: sha512-jumlc0BIUrS3qJGgIkWZsyfAM7NCWiBcCDhnd+3NNM5KbBmLTgHVfWBcg6W+rLUsIpzpERPsvwUP7CckAQSOoA==} - engines: {node: '>=12'} + gzip-size@7.0.0: + resolution: {integrity: sha512-O1Ld7Dr+nqPnmGpdhzLmMTQ4vAsD+rHwMm1NLUmoUFFymBOMKxCCrtDxqdBRYXdeEPEi3SyoR4TizJLQrnKBNA==} + engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - lru_map@0.3.3: - resolution: {integrity: sha512-Pn9cox5CsMYngeDbmChANltQl+5pi6XmTrraMSzhPmMBbmgcxmqWry0U3PGapCU1yB4/LqCcom7qhHZiF/jGfQ==} + h3@1.15.4: + resolution: {integrity: sha512-z5cFQWDffyOe4vQ9xIqNfCZdV4p//vy6fBnr8Q1AWnVZ0teurKMG66rLj++TKwKPUP3u7iMUvrvKaEUiQw2QWQ==} - ltgt@2.2.1: - resolution: {integrity: sha512-AI2r85+4MquTw9ZYqabu4nMwy9Oftlfa/e/52t9IjtfG+mGBbTNdAoZ3RQKLHR6r0wQnwZnPIEh/Ya6XTWAKNA==} + happy-dom@20.0.2: + resolution: {integrity: sha512-pYOyu624+6HDbY+qkjILpQGnpvZOusItCk+rvF5/V+6NkcgTKnbOldpIy22tBnxoaLtlM9nXgoqAcW29/B7CIw==} + engines: {node: '>=20.0.0'} - magic-string@0.30.21: - resolution: {integrity: sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ==} + hardhat@2.22.3: + resolution: {integrity: sha512-k8JV2ECWNchD6ahkg2BR5wKVxY0OiKot7fuxiIpRK0frRqyOljcR2vKwgWSLw6YIeDcNNA4xybj7Og7NSxr2hA==} + hasBin: true + peerDependencies: + ts-node: '*' + typescript: '*' + peerDependenciesMeta: + ts-node: + optional: true + typescript: + optional: true - magicast@0.5.1: - resolution: {integrity: sha512-xrHS24IxaLrvuo613F719wvOIv9xPHFWQHuvGUBmPnCA/3MQxKI3b+r7n1jAoDHmsbC5bRhTZYR77invLAxVnw==} + has-flag@3.0.0: + resolution: {integrity: sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==} + engines: {node: '>=4'} - make-dir@3.1.0: - resolution: {integrity: sha512-g3FeP20LNwhALb/6Cz6Dd4F2ngze0jz7tbzrD2wAV+o9FeNHe4rL+yK2md0J/fiSf1sa1ADhXqi5+oVwOM/eGw==} + has-flag@4.0.0: + resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} engines: {node: '>=8'} - make-dir@4.0.0: - resolution: {integrity: sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw==} - engines: {node: '>=10'} + has-property-descriptors@1.0.2: + resolution: {integrity: sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==} - make-error@1.3.6: - resolution: {integrity: sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==} + has-symbols@1.1.0: + resolution: {integrity: sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==} + engines: {node: '>= 0.4'} - make-fetch-happen@13.0.1: - resolution: {integrity: sha512-cKTUFc/rbKUd/9meOvgrpJ2WrNzymt6jfRDdwg5UCnVzv9dTpEj9JS5m3wtziXVCjluIXyL8pcaukYqezIzZQA==} - engines: {node: ^16.14.0 || >=18.0.0} + has-tostringtag@1.0.2: + resolution: {integrity: sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==} + engines: {node: '>= 0.4'} - markdown-table@1.1.3: - resolution: {integrity: sha512-1RUZVgQlpJSPWYbFSpmudq5nHY1doEIv89gBtF0s4gW1GF2XorxcA/70M5vq7rLv0a6mhOUccRsqkwhwLCIQ2Q==} + hash-base@3.1.0: + resolution: {integrity: sha512-1nmYp/rhMDiE7AYkDw+lLwlAzz0AntGIe51F3RfFfEqyQ3feY2eI/NcwC6umIQVOASPMsWJLJScWKSSvzL9IVA==} + engines: {node: '>=4'} - match-all@1.2.7: - resolution: {integrity: sha512-qSpsBKarh55r9KyXzFC3xBLRf2GlGasba2em9kbpRsSlGvdTAqjx3QD0r3FKSARiW+OE4iMHYsolM3aX9n5djw==} + hash.js@1.1.7: + resolution: {integrity: sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==} - math-intrinsics@1.1.0: - resolution: {integrity: sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==} + hasown@2.0.2: + resolution: {integrity: sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==} engines: {node: '>= 0.4'} - mcl-wasm@0.7.9: - resolution: {integrity: sha512-iJIUcQWA88IJB/5L15GnJVnSQJmf/YaxxV6zRavv83HILHaJQb6y0iFyDMdDO0gN8X37tdxmAOrH/P8B6RB8sQ==} - engines: {node: '>=8.9.0'} + hast-util-to-html@9.0.3: + resolution: {integrity: sha512-M17uBDzMJ9RPCqLMO92gNNUDuBSq10a25SDBI08iCCxmorf4Yy6sYHK57n9WAbRAAaU+DuR4W6GN9K4DFZesYg==} - md5.js@1.3.5: - resolution: {integrity: sha512-xitP+WxNPcTTOgnTJcrhM0xvdPepipPSf3I8EIpGKeFLjt3PlJLIDG3u8EX53ZIubkb+5U2+3rELYpEhHhzdkg==} + hast-util-whitespace@3.0.0: + resolution: {integrity: sha512-88JUN06ipLwsnv+dVn+OIYOvAuvBMy/Qoi6O7mQHxdPXpjy+Cd6xRkWwux7DKO+4sYILtLBRIKgsdpS2gQc7qw==} - media-typer@0.3.0: - resolution: {integrity: sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ==} - engines: {node: '>= 0.6'} + he@1.2.0: + resolution: {integrity: sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==} + hasBin: true - memdown@1.4.1: - resolution: {integrity: sha512-iVrGHZB8i4OQfM155xx8akvG9FIj+ht14DX5CQkCTG4EHzZ3d3sgckIf/Lm9ivZalEsFuEVnWv2B2WZvbrro2w==} - deprecated: Superseded by memory-level (https://github.com/Level/community#faq) + headers-polyfill@4.0.2: + resolution: {integrity: sha512-EWGTfnTqAO2L/j5HZgoM/3z82L7necsJ0pO9Tp0X1wil3PDLrkypTBRgVO2ExehEEvUycejZD3FuRaXpZZc3kw==} - memdown@5.1.0: - resolution: {integrity: sha512-B3J+UizMRAlEArDjWHTMmadet+UKwHd3UjMgGBkZcKAxAYVPS9o0Yeiha4qvz7iGiL2Sb3igUft6p7nbFWctpw==} - engines: {node: '>=6'} - deprecated: Superseded by memory-level (https://github.com/Level/community#faq) + help-me@5.0.0: + resolution: {integrity: sha512-7xgomUX6ADmcYzFik0HzAxh/73YlKR9bmFzf51CZwR+b6YtzU2m0u49hQCqV6SvlqIqsaxovfwdvbnsw3b/zpg==} - memorystream@0.3.1: - resolution: {integrity: sha512-S3UwM3yj5mtUSEfP41UZmt/0SCoVYUcU1rkXv+BQ5Ig8ndL4sPoJNBUJERafdPb5jjHJGuMgytgKvKIf58XNBw==} - engines: {node: '>= 0.10.0'} + highlight.js@10.7.3: + resolution: {integrity: sha512-tzcUFauisWKNHaRkN4Wjl/ZA07gENAjFl3J/c480dprkGTg5EQstgaNFqBfUqCq54kZRIEcreTsAgF/m2quD7A==} - merge-descriptors@1.0.3: - resolution: {integrity: sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==} + hmac-drbg@1.0.1: + resolution: {integrity: sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==} - merge-stream@2.0.0: - resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==} + hookable@5.5.3: + resolution: {integrity: sha512-Yc+BQe8SvoXH1643Qez1zqLRmbA5rCL+sSmk6TVos0LWVfNIB7PGncdlId77WzLGSIB5KaWgTaNTs2lNVEI6VQ==} - merge2@1.4.1: - resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==} - engines: {node: '>= 8'} + html-escaper@2.0.2: + resolution: {integrity: sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==} - merkle-patricia-tree@2.3.2: - resolution: {integrity: sha512-81PW5m8oz/pz3GvsAwbauj7Y00rqm81Tzad77tHBwU7pIAtN+TJnMSOJhxBKflSVYhptMMb9RskhqHqrSm1V+g==} + html-void-elements@3.0.0: + resolution: {integrity: sha512-bEqo66MRXsUGxWHV5IP0PUiAWwoEjba4VCzg0LjFJBpchPaTfyfCKTG6bc5F8ucKec3q5y6qOdGyYTSBEvhCrg==} - merkle-patricia-tree@4.2.4: - resolution: {integrity: sha512-eHbf/BG6eGNsqqfbLED9rIqbsF4+sykEaBn6OLNs71tjclbMcMOk1tEPmJKcNcNCLkvbpY/lwyOlizWsqPNo8w==} + http-errors@1.4.0: + resolution: {integrity: sha512-oLjPqve1tuOl5aRhv8GK5eHpqP1C9fb+Ol+XTLjKfLltE44zdDbEdjPSbU7Ch5rSNsVFqZn97SrMmZLdu1/YMw==} + engines: {node: '>= 0.6'} - methods@1.1.2: - resolution: {integrity: sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w==} + http-errors@1.7.3: + resolution: {integrity: sha512-ZTTX0MWrsQ2ZAhA1cejAwDLycFsd7I7nVtnkT3Ol0aqodaKW+0CTZDQ1uBv5whptCnc8e8HeRRJxRs0kmm/Qfw==} engines: {node: '>= 0.6'} - micro-eth-signer@0.14.0: - resolution: {integrity: sha512-5PLLzHiVYPWClEvZIXXFu5yutzpadb73rnQCpUqIHu3No3coFuWQNfE5tkBQJ7djuLYl6aRLaS0MgWJYGoqiBw==} + http-errors@2.0.0: + resolution: {integrity: sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ==} + engines: {node: '>= 0.8'} - micro-ftch@0.3.1: - resolution: {integrity: sha512-/0LLxhzP0tfiR5hcQebtudP56gUurs2CLkGarnCiB/OqEyUFQ6U3paQi/tgLv0hBJYt2rnr9MNpxz4fiiugstg==} + http-errors@2.0.1: + resolution: {integrity: sha512-4FbRdAX+bSdmo4AUFuS0WNiPz8NgFt+r8ThgNWmlrjQjt1Q7ZR9+zTlce2859x4KSXrwIsaeTqDoKQmtP8pLmQ==} + engines: {node: '>= 0.8'} - micro-packed@0.7.3: - resolution: {integrity: sha512-2Milxs+WNC00TRlem41oRswvw31146GiSaoCT7s3Xi2gMUglW5QBeqlQaZeHr5tJx9nm3i57LNXPqxOOaWtTYg==} + http-proxy@1.18.1: + resolution: {integrity: sha512-7mz/721AbnJwIVbnaSv1Cz3Am0ZLT/UBwkC92VlxhXv/k/BBQfM2fXElQNC27BVGr0uwUpplYPQM9LnaBMR5NQ==} + engines: {node: '>=8.0.0'} - micromatch@4.0.8: - resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==} - engines: {node: '>=8.6'} + http-shutdown@1.2.2: + resolution: {integrity: sha512-S9wWkJ/VSY9/k4qcjG318bqJNruzE4HySUhFYknwmu6LBP97KLLfwNf+n4V1BHurvFNkSKLFnK/RsuUnRTf9Vw==} + engines: {iojs: '>= 1.0.0', node: '>= 0.12.0'} - miller-rabin@4.0.1: - resolution: {integrity: sha512-115fLhvZVqWwHPbClyntxEVfVDfl9DLLTuJvq3g2O/Oxi8AiNouAHvDSzHS0viUJc+V5vm3eq91Xwqn9dp4jRA==} - hasBin: true + https-proxy-agent@5.0.1: + resolution: {integrity: sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==} + engines: {node: '>= 6'} - mime-db@1.52.0: - resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} - engines: {node: '>= 0.6'} + https-proxy-agent@7.0.6: + resolution: {integrity: sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==} + engines: {node: '>= 14'} - mime-types@2.1.35: - resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} - engines: {node: '>= 0.6'} + httpxy@0.1.7: + resolution: {integrity: sha512-pXNx8gnANKAndgga5ahefxc++tJvNL87CXoRwxn1cJE2ZkWEojF3tNfQIEhZX/vfpt+wzeAzpUI4qkediX1MLQ==} - mime@1.6.0: - resolution: {integrity: sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==} - engines: {node: '>=4'} + human-id@1.0.2: + resolution: {integrity: sha512-UNopramDEhHJD+VR+ehk8rOslwSfByxPIZyJRfV739NDhN5LF1fa1MqnzKm2lGTQRjNrjK19Q5fhkgIfjlVUKw==} + + human-id@4.1.3: + resolution: {integrity: sha512-tsYlhAYpjCKa//8rXZ9DqKEawhPoSytweBC2eNvcaDK+57RZLHGqNs3PZTQO6yekLFSuvA6AlnAfrw1uBvtb+Q==} hasBin: true - mimic-fn@2.1.0: - resolution: {integrity: sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==} - engines: {node: '>=6'} + human-signals@1.1.1: + resolution: {integrity: sha512-SEQu7vl8KjNL2eoGBLF3+wAjpsNfA9XMlXAYj/3EdaNfAlxKthD1xjEQfGOUhllCGGJVNY34bRr6lPINhNjyZw==} + engines: {node: '>=8.12.0'} - mimic-response@1.0.1: - resolution: {integrity: sha512-j5EctnkH7amfV/q5Hgmoal1g2QHFJRraOtmx0JpIqkxhBhI/lJSl1nMpQ45hVarwNETOoWEimndZ4QK0RHxuxQ==} - engines: {node: '>=4'} + human-signals@2.1.0: + resolution: {integrity: sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==} + engines: {node: '>=10.17.0'} - mimic-response@3.1.0: - resolution: {integrity: sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==} - engines: {node: '>=10'} + human-signals@5.0.0: + resolution: {integrity: sha512-AXcZb6vzzrFAUE61HnN4mpLqd/cSIwNQjtNWR0euPm6y0iqx3G4gOXaIDdtdDwZmhwe82LA6+zinmW4UBWVePQ==} + engines: {node: '>=16.17.0'} - min-document@2.19.2: - resolution: {integrity: sha512-8S5I8db/uZN8r9HSLFVWPdJCvYOejMcEC82VIzNUc6Zkklf/d1gg2psfE79/vyhWOj4+J8MtwmoOz3TmvaGu5A==} + human-signals@7.0.0: + resolution: {integrity: sha512-74kytxOUSvNbjrT9KisAbaTZ/eJwD/LrbM/kh5j0IhPuJzwuA19dWvniFGwBzN9rVjg+O/e+F310PjObDXS+9Q==} + engines: {node: '>=18.18.0'} - minimalistic-assert@1.0.1: - resolution: {integrity: sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==} + iconv-lite@0.4.24: + resolution: {integrity: sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==} + engines: {node: '>=0.10.0'} - minimalistic-crypto-utils@1.0.1: - resolution: {integrity: sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==} + iconv-lite@0.6.3: + resolution: {integrity: sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==} + engines: {node: '>=0.10.0'} - minimatch@10.2.5: - resolution: {integrity: sha512-MULkVLfKGYDFYejP07QOurDLLQpcjk7Fw+7jXS2R2czRQzR56yHRveU5NDJEOviH+hETZKSkIk5c+T23GjFUMg==} - engines: {node: 18 || 20 || >=22} + iconv-lite@0.7.1: + resolution: {integrity: sha512-2Tth85cXwGFHfvRgZWszZSvdo+0Xsqmw8k8ZwxScfcBneNUraK+dxRxRm24nszx80Y0TVio8kKLt5sLE7ZCLlw==} + engines: {node: '>=0.10.0'} - minimatch@3.1.5: - resolution: {integrity: sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w==} + idb-keyval@6.2.1: + resolution: {integrity: sha512-8Sb3veuYCyrZL+VBt9LJfZjLUPWVvqn8tG28VqYNFCo43KHcKuq+b4EiXGeuaLAQWL2YmyDgMp2aSpH9JHsEQg==} - minimatch@5.1.9: - resolution: {integrity: sha512-7o1wEA2RyMP7Iu7GNba9vc0RWWGACJOCZBJX2GJWip0ikV+wcOsgVuY9uE8CPiyQhkGFSlhuSkZPavN7u1c2Fw==} - engines: {node: '>=10'} + idb@7.1.1: + resolution: {integrity: sha512-gchesWBzyvGHRO9W8tzUWFDycow5gwjvFKfyV9FF32Y7F50yZMp7mP+T2mJIWFx49zicqyC4uefHM17o6xKIVQ==} - minimist@1.2.8: - resolution: {integrity: sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==} + ieee754@1.2.1: + resolution: {integrity: sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==} - minipass-collect@2.0.1: - resolution: {integrity: sha512-D7V8PO9oaz7PWGLbCACuI1qEOsq7UKfLotx/C0Aet43fCUB/wfQ7DYeq2oR/svFJGYDHPr38SHATeaj/ZoKHKw==} - engines: {node: '>=16 || 14 >=14.17'} + ignore@3.3.10: + resolution: {integrity: sha512-Pgs951kaMm5GXP7MOvxERINe3gsaVjUWFm+UZPSq9xYriQAksyhg0csnS0KXSNRD5NmNdapXEpjxG49+AKh/ug==} - minipass-fetch@3.0.5: - resolution: {integrity: sha512-2N8elDQAtSnFV0Dk7gt15KHsS0Fyz6CbYZ360h0WTYV1Ty46li3rAXVOQj1THMNLdmrD9Vt5pBPtWtVkpwGBqg==} - engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} + ignore@5.3.2: + resolution: {integrity: sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==} + engines: {node: '>= 4'} - minipass-flush@1.0.7: - resolution: {integrity: sha512-TbqTz9cUwWyHS2Dy89P3ocAGUGxKjjLuR9z8w4WUTGAVgEj17/4nhgo2Du56i0Fm3Pm30g4iA8Lcqctc76jCzA==} - engines: {node: '>= 8'} + ignore@7.0.5: + resolution: {integrity: sha512-Hs59xBNfUIunMFgWAbGX5cq6893IbWg4KnrjbYwX3tx0ztorVgTDA6B2sxf8ejHJ4wz8BqGUMYlnzNBer5NvGg==} + engines: {node: '>= 4'} - minipass-pipeline@1.2.4: - resolution: {integrity: sha512-xuIq7cIOt09RPRJ19gdi4b+RiNvDFYe5JH+ggNvBqGqpQXcru3PcRmOZuHBKWK1Txf9+cQ+HMVN4d6z46LZP7A==} - engines: {node: '>=8'} + image-meta@0.2.2: + resolution: {integrity: sha512-3MOLanc3sb3LNGWQl1RlQlNWURE5g32aUphrDyFeCsxBTk08iE3VNe4CwsUZ0Qs1X+EfX0+r29Sxdpza4B+yRA==} - minipass-sized@1.0.3: - resolution: {integrity: sha512-MbkQQ2CTiBMlA2Dm/5cY+9SWFEN8pzzOXi6rlM5Xxq0Yqbda5ZQy9sU75a673FE9ZK0Zsbr6Y5iP6u9nktfg2g==} - engines: {node: '>=8'} + immutable@4.3.5: + resolution: {integrity: sha512-8eabxkth9gZatlwl5TBuJnCsoTADlL6ftEr7A4qgdaTsPyreilDSnUk57SO+jfKcNtxPa22U5KK6DSeAYhpBJw==} - minipass@3.3.6: - resolution: {integrity: sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==} + impound@1.0.0: + resolution: {integrity: sha512-8lAJ+1Arw2sMaZ9HE2ZmL5zOcMnt18s6+7Xqgq2aUVy4P1nlzAyPtzCDxsk51KVFwHEEdc6OWvUyqwHwhRYaug==} + + indent-string@4.0.0: + resolution: {integrity: sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==} engines: {node: '>=8'} - minipass@7.1.3: - resolution: {integrity: sha512-tEBHqDnIoM/1rXME1zgka9g6Q2lcoCkxHLuc7ODJ5BxbP5d4c2Z5cGgtXAku59200Cx7diuHTOYfSBD8n6mm8A==} - engines: {node: '>=16 || 14 >=14.17'} + inflight@1.0.6: + resolution: {integrity: sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==} + deprecated: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful. - minizlib@2.1.2: - resolution: {integrity: sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==} - engines: {node: '>= 8'} + inherits@2.0.1: + resolution: {integrity: sha512-8nWq2nLTAwd02jTqJExUYFSD/fKq6VH9Y/oG2accc/kdI0V98Bag8d5a4gi3XHz73rDWa2PvTtvcWYquKqSENA==} - minizlib@3.1.0: - resolution: {integrity: sha512-KZxYo1BUkWD2TVFLr0MQoM8vUUigWD3LlD83a/75BqC+4qE0Hb1Vo5v1FgcfaNXvfXzr+5EhQ6ing/CaBijTlw==} - engines: {node: '>= 18'} + inherits@2.0.4: + resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} - mipd@0.0.7: - resolution: {integrity: sha512-aAPZPNDQ3uMTdKbuO2YmAw2TxLHO0moa4YKAyETM/DTj5FloZo+a+8tU+iv4GmW+sOxKLSRwcSFuczk+Cpt6fg==} - peerDependencies: - typescript: '>=5.0.4' - peerDependenciesMeta: - typescript: - optional: true + ini@1.3.8: + resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==} + + ini@4.1.1: + resolution: {integrity: sha512-QQnnxNyfvmHFIsj7gkPcYymR8Jdw/o7mp5ZFihxn6h8Ci6fh3Dx4E1gPjpQEpIuPo9XVNY/ZUwh4BPMjGyL01g==} + engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} + + io-ts@1.10.4: + resolution: {integrity: sha512-b23PteSnYXSONJ6JQXRAlvJhuw8KOtkqa87W4wDtvMrud/DTJd5X+NpOOI+O/zZwVq6v0VLAaJ+1EDViKEuN9g==} + + ioredis@5.8.2: + resolution: {integrity: sha512-C6uC+kleiIMmjViJINWk80sOQw5lEzse1ZmvD+S/s8p8CWapftSaC+kocGTx6xrbrJ4WmYQGC08ffHLr6ToR6Q==} + engines: {node: '>=12.22.0'} + + iron-webcrypto@1.2.1: + resolution: {integrity: sha512-feOM6FaSr6rEABp/eDfVseKyTMDt+KGpeB35SkVn9Tyn0CqvVsY3EwI0v5i8nMHyJnzCIQf7nsy3p41TPkJZhg==} + + is-arguments@1.2.0: + resolution: {integrity: sha512-7bVbi0huj/wrIAOzb8U1aszg9kdi3KN/CyU19CTI7tAoZYEZoL9yCDXpbXN+uPsuWnP02cyug1gleqq+TU+YCA==} + engines: {node: '>= 0.4'} - mkdirp-promise@5.0.1: - resolution: {integrity: sha512-Hepn5kb1lJPtVW84RFT40YG1OddBNTOVUZR2bzQUHc+Z03en8/3uX0+060JDhcEzyO08HmipsN9DcnFMxhIL9w==} + is-binary-path@2.1.0: + resolution: {integrity: sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==} + engines: {node: '>=8'} + + is-buffer@2.0.5: + resolution: {integrity: sha512-i2R6zNFDwgEHJyQUtJEk0XFi1i0dPFn/oqjK3/vPCcDeJvW5NQ83V8QbicfF1SupOaB0h8ntgBC2YiE7dfyctQ==} engines: {node: '>=4'} - deprecated: This package is broken and no longer maintained. 'mkdirp' itself supports promises now, please switch to that. - mkdirp@0.5.6: - resolution: {integrity: sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==} - hasBin: true + is-callable@1.2.7: + resolution: {integrity: sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==} + engines: {node: '>= 0.4'} - mkdirp@1.0.4: - resolution: {integrity: sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==} - engines: {node: '>=10'} + is-core-module@2.16.1: + resolution: {integrity: sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w==} + engines: {node: '>= 0.4'} + + is-docker@2.2.1: + resolution: {integrity: sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==} + engines: {node: '>=8'} hasBin: true - mkdirp@3.0.1: - resolution: {integrity: sha512-+NsyUUAZDmo6YVHzL/stxSu3t9YS1iljliy3BSDrXJ/dkn1KYdmtZODGGjLcc9XLgVVpH4KshHB8XmZgMhaBXg==} - engines: {node: '>=10'} + is-docker@3.0.0: + resolution: {integrity: sha512-eljcgEDlEns/7AXFosB5K/2nCM4P7FQPkGc/DWLy5rmFEWvZayGrik1d9/QIY5nJ4f9YsVvBkA6kJpHn9rISdQ==} + engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} hasBin: true - mnemonist@0.38.5: - resolution: {integrity: sha512-bZTFT5rrPKtPJxj8KSV0WkPyNxl72vQepqqVUAW2ARUpUSF2qXMB6jZj7hW5/k7C1rtpzqbD/IIbJwLXUjCHeg==} + is-extglob@2.1.1: + resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} + engines: {node: '>=0.10.0'} - mocha@10.8.2: - resolution: {integrity: sha512-VZlYo/WE8t1tstuRmqgeyBgCbJc/lEdopaa+axcKzTBJ+UIdlAB9XnmvTCAH4pwR4ElNInaedhEBmZD8iCSVEg==} - engines: {node: '>= 14.0.0'} - hasBin: true + is-fullwidth-code-point@3.0.0: + resolution: {integrity: sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==} + engines: {node: '>=8'} + + is-generator-function@1.1.2: + resolution: {integrity: sha512-upqt1SkGkODW9tsGNG5mtXTXtECizwtS2kA161M+gJPc1xdb/Ax629af6YrTwcOeQHbewrPNlE5Dx7kzvXTizA==} + engines: {node: '>= 0.4'} + + is-glob@4.0.3: + resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==} + engines: {node: '>=0.10.0'} - mock-fs@4.14.0: - resolution: {integrity: sha512-qYvlv/exQ4+svI3UOvPUpLDF0OMX5euvUH0Ny4N5QyRyhNdgAgUrVH3iUINSzEPLvx0kbo/Bp28GJKIqvE7URw==} + is-hex-prefixed@1.0.0: + resolution: {integrity: sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==} + engines: {node: '>=6.5.0', npm: '>=3'} - mockttp@3.17.1: - resolution: {integrity: sha512-sW6m4uaRIGJrtrQNZbUoSisTEAq91oS9C4cUyVFpHgMcpTwsG2ZvF94qOBt4PpEf9gGCiwkxvzkEEt4W/CPHHg==} - engines: {node: '>=14.14.0'} + is-inside-container@1.0.0: + resolution: {integrity: sha512-KIYLCCJghfHZxqjYBE7rEy0OBuTd5xCHS7tHVgvCLkx7StIoaxwNW3hCALgEUjFfeRk+MG/Qxmp/vtETEF3tRA==} + engines: {node: '>=14.16'} hasBin: true - module-error@1.0.2: - resolution: {integrity: sha512-0yuvsqSCv8LbaOKhnsQ/T5JhyFlCYLPXK3U2sgV10zoKQwzs/MyfuQUOZQ1V/6OCOJsK/TRgNVrPuPDqtdMFtA==} - engines: {node: '>=10'} + is-installed-globally@1.0.0: + resolution: {integrity: sha512-K55T22lfpQ63N4KEN57jZUAaAYqYHEe8veb/TycJRk9DdSCLLcovXz/mL6mOnhQaZsQGwPhuFopdQIlqGSEjiQ==} + engines: {node: '>=18'} - mri@1.2.0: - resolution: {integrity: sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA==} - engines: {node: '>=4'} + is-module@1.0.0: + resolution: {integrity: sha512-51ypPSPCoTEIN9dy5Oy+h4pShgJmPCygKfyRCISBI+JoWT/2oJvK8QPxmwv7b/p239jXrm9M1mlQbyKJ5A152g==} - ms@2.0.0: - resolution: {integrity: sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==} + is-node-process@1.2.0: + resolution: {integrity: sha512-Vg4o6/fqPxIjtxgUH5QLJhwZ7gW5diGCVlXpuUfELC62CuxM1iHcRe51f2W1FDy04Ai4KJkagKjx3XaqyfRKXw==} - ms@2.1.3: - resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} + is-number@7.0.0: + resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==} + engines: {node: '>=0.12.0'} - multibase@0.6.1: - resolution: {integrity: sha512-pFfAwyTjbbQgNc3G7D48JkJxWtoJoBMaR4xQUOuB8RnCgRqaYmWNFeJTTvrJ2w51bjLq2zTby6Rqj9TQ9elSUw==} - deprecated: This module has been superseded by the multiformats module + is-path-inside@4.0.0: + resolution: {integrity: sha512-lJJV/5dYS+RcL8uQdBDW9c9uWFLLBNRyFhnAKXw5tVqLlKZ4RMGZKv+YQ/IA3OhD+RpbJa1LLFM1FQPGyIXvOA==} + engines: {node: '>=12'} - multibase@0.7.0: - resolution: {integrity: sha512-TW8q03O0f6PNFTQDvh3xxH03c8CjGaaYrjkl9UQPG6rz53TQzzxJVCIWVjzcbN/Q5Y53Zd0IBQBMVktVgNx4Fg==} - deprecated: This module has been superseded by the multiformats module + is-plain-obj@2.1.0: + resolution: {integrity: sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==} + engines: {node: '>=8'} - multicodec@0.5.7: - resolution: {integrity: sha512-PscoRxm3f+88fAtELwUnZxGDkduE2HD9Q6GHUOywQLjOGT/HAdhjLDYNZ1e7VR0s0TP0EwZ16LNUTFpoBGivOA==} - deprecated: This module has been superseded by the multiformats module + is-plain-obj@4.1.0: + resolution: {integrity: sha512-+Pgi+vMuUNkJyExiMBt5IlFoMyKnr5zhJ4Uspz58WOhBF5QoIZkFyNHIbBAtHwzVAgk5RtndVNsDRN61/mmDqg==} + engines: {node: '>=12'} - multicodec@1.0.4: - resolution: {integrity: sha512-NDd7FeS3QamVtbgfvu5h7fd1IlbaC4EQ0/pgU4zqE2vdHCmBGsUa0TiM8/TdSeG6BMPC92OOCf8F1ocE/Wkrrg==} - deprecated: This module has been superseded by the multiformats module + is-plain-object@5.0.0: + resolution: {integrity: sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q==} + engines: {node: '>=0.10.0'} - multihashes@0.4.21: - resolution: {integrity: sha512-uVSvmeCWf36pU2nB4/1kzYZjsXD9vofZKpgudqkceYY5g2aZZXJ5r9lxuzoRLl1OAp28XljXsEJ/X/85ZsKmKw==} + is-reference@1.2.1: + resolution: {integrity: sha512-U82MsXXiFIrjCK4otLT+o2NA2Cd2g5MLoOVXUZjIOhLurrRxpEXzI8O0KZHr3IjLvlAH1kTPYSuqer5T9ZVBKQ==} - murmur-128@0.2.1: - resolution: {integrity: sha512-WseEgiRkI6aMFBbj8Cg9yBj/y+OdipwVC7zUo3W2W1JAJITwouUOtpqsmGSg67EQmwwSyod7hsVsWY5LsrfQVg==} + is-regex@1.2.1: + resolution: {integrity: sha512-MjYsKHO5O7mCsmRGxWcLWheFqN9DJ/2TmngvjKXihe6efViPqc274+Fx/4fYj/r03+ESvBdTXK0V6tA3rgez1g==} + engines: {node: '>= 0.4'} - mute-stream@0.0.8: - resolution: {integrity: sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==} + is-ssh@1.4.1: + resolution: {integrity: sha512-JNeu1wQsHjyHgn9NcWTaXq6zWSR6hqE0++zhfZlkFBbScNkyvxCdeV8sRkSBaeLKxmbpR21brail63ACNxJ0Tg==} - nan@2.26.2: - resolution: {integrity: sha512-0tTvBTYkt3tdGw22nrAy50x7gpbGCCFH3AFcyS5WiUu7Eu4vWlri1woE6qHBSfy11vksDqkiwjOnlR7WV8G1Hw==} + is-stream@2.0.1: + resolution: {integrity: sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==} + engines: {node: '>=8'} - nano-json-stream-parser@0.1.2: - resolution: {integrity: sha512-9MqxMH/BSJC7dnLsEMPyfN5Dvoo49IsPFYMcHw3Bcfc2kN0lpHRBSzlMSVx4HGyJ7s9B31CyBTVehWJoQ8Ctew==} + is-stream@3.0.0: + resolution: {integrity: sha512-LnQR4bZ9IADDRSkvpqMGvt/tEJWclzklNgSw48V5EAaAeDd6qGvN8ei6k5p0tvxSR171VmGyHuTiAOfxAbr8kA==} + engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - nanoid@3.3.11: - resolution: {integrity: sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==} - engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} - hasBin: true + is-stream@4.0.1: + resolution: {integrity: sha512-Dnz92NInDqYckGEUJv689RbRiTSEHCQ7wOVeALbkOz999YpqT46yMRIGtSNl2iCL1waAZSx40+h59NV/EwzV/A==} + engines: {node: '>=18'} - native-duplexpair@1.0.0: - resolution: {integrity: sha512-E7QQoM+3jvNtlmyfqRZ0/U75VFgCls+fSkbml2MpgWkWyz3ox8Y58gNhfuziuQYGNNQAbFZJQck55LHCnCK6CA==} + is-subdir@1.2.0: + resolution: {integrity: sha512-2AT6j+gXe/1ueqbW6fLZJiIw3F8iXGJtt0yDrZaBhAZEG1raiTxKWU+IPqMCzQAXOUCKdA4UDMgacKH25XG2Cw==} + engines: {node: '>=4'} - natural-compare@1.4.0: - resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==} + is-typed-array@1.1.15: + resolution: {integrity: sha512-p3EcsicXjit7SaskXHs1hA91QxgTw46Fv6EFKKGS5DRFLD8yKnohjF3hxoju94b/OcMZoQukzpPpBE9uLVKzgQ==} + engines: {node: '>= 0.4'} - ndjson@2.0.0: - resolution: {integrity: sha512-nGl7LRGrzugTtaFcJMhLbpzJM6XdivmbkdlaGcrk/LXg2KL/YBC6z1g70xh0/al+oFuVFP8N8kiWRucmeEH/qQ==} + is-unicode-supported@0.1.0: + resolution: {integrity: sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==} engines: {node: '>=10'} - hasBin: true - - negotiator@0.6.3: - resolution: {integrity: sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==} - engines: {node: '>= 0.6'} - negotiator@0.6.4: - resolution: {integrity: sha512-myRT3DiWPHqho5PrJaIRyaMv2kgYf0mUVgBNOYMuCH5Ki1yEiQaf/ZJuQ62nvpc44wL5WDbTX7yGJi1Neevw8w==} - engines: {node: '>= 0.6'} + is-unicode-supported@2.0.0: + resolution: {integrity: sha512-FRdAyx5lusK1iHG0TWpVtk9+1i+GjrzRffhDg4ovQ7mcidMQ6mj+MhKPmvh7Xwyv5gIS06ns49CA7Sqg7lC22Q==} + engines: {node: '>=18'} - neo-async@2.6.2: - resolution: {integrity: sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==} + is-what@4.1.16: + resolution: {integrity: sha512-ZhMwEosbFJkA0YhFnNDgTM4ZxDRsS6HqTo7qsZM08fehyRYIYa0yHu5R6mgo1n/8MgaPBXiPimPD77baVFYg+A==} + engines: {node: '>=12.13'} - netmask@2.1.1: - resolution: {integrity: sha512-eonl3sLUha+S1GzTPxychyhnUzKyeQkZ7jLjKrBagJgPla13F+uQ71HgpFefyHgqrjEbCPkDArxYsjY8/+gLKA==} - engines: {node: '>= 0.4.0'} + is-what@5.5.0: + resolution: {integrity: sha512-oG7cgbmg5kLYae2N5IVd3jm2s+vldjxJzK1pcu9LfpGuQ93MQSzo0okvRna+7y5ifrD+20FE8FvjusyGaz14fw==} + engines: {node: '>=18'} - next-tick@1.1.0: - resolution: {integrity: sha512-CXdUiJembsNjuToQvxayPZF9Vqht7hewsvy2sOWafLvi2awflj9mOC6bHIg50orX8IJvWKY9wYQ/zB2kogPslQ==} + is-windows@1.0.2: + resolution: {integrity: sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==} + engines: {node: '>=0.10.0'} - next@16.2.4: - resolution: {integrity: sha512-kPvz56wF5frc+FxlHI5qnklCzbq53HTwORaWBGdT0vNoKh1Aya9XC8aPauH4NJxqtzbWsS5mAbctm4cr+EkQ2Q==} - engines: {node: '>=20.9.0'} - hasBin: true - peerDependencies: - '@opentelemetry/api': ^1.1.0 - '@playwright/test': ^1.51.1 - babel-plugin-react-compiler: '*' - react: ^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0 - react-dom: ^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0 - sass: ^1.3.0 - peerDependenciesMeta: - '@opentelemetry/api': - optional: true - '@playwright/test': - optional: true - babel-plugin-react-compiler: - optional: true - sass: - optional: true + is-wsl@2.2.0: + resolution: {integrity: sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==} + engines: {node: '>=8'} - no-case@2.3.2: - resolution: {integrity: sha512-rmTZ9kz+f3rCvK2TD1Ue/oZlns7OGoIWP4fc3llxxRXlOkHKoWPPWJOfFYpITabSow43QJbRIoHQXtt10VldyQ==} + is-wsl@3.1.0: + resolution: {integrity: sha512-UcVfVfaK4Sc4m7X3dUSoHoozQGBEFeDC+zVo06t98xe8CzHSZZBekNXH+tu0NalHolcJ/QAGqS46Hef7QXBIMw==} + engines: {node: '>=16'} - node-addon-api@2.0.2: - resolution: {integrity: sha512-Ntyt4AIXyaLIuMHF6IOoTakB3K+RWxwtsHNRxllEoA6vPwP9o4866g6YWDLUdnucilZhmkxiHwHr11gAENw+QA==} + is64bit@2.0.0: + resolution: {integrity: sha512-jv+8jaWCl0g2lSBkNSVXdzfBA0npK1HGC2KtWM9FumFRoGS94g3NbCCLVnCYHLjp4GrW2KZeeSTMo5ddtznmGw==} + engines: {node: '>=18'} - node-addon-api@5.1.0: - resolution: {integrity: sha512-eh0GgfEkpnoWDq+VY8OyvYhFEzBk6jIYbRKdIlyTiAXIVJ8PyBaKb0rp7oDtoddbdoHWhq8wwr+XZ81F1rpNdA==} + isarray@0.0.1: + resolution: {integrity: sha512-D2S+3GLxWH+uhrNEcoh/fnmYeP8E8/zHl644d/jdA0g2uyXvy3sb0qxotE+ne0LtccHknQzWwZEzhak7oJ0COQ==} - node-domexception@1.0.0: - resolution: {integrity: sha512-/jKZoMpw0F8GRwl4/eLROPA3cfcXtLApP0QzLmUT/HuPCZWyB7IY9ZrMeKw2O/nFIqPQB3PVM9aYm0F312AXDQ==} - engines: {node: '>=10.5.0'} - deprecated: Use your platform's native DOMException instead + isarray@1.0.0: + resolution: {integrity: sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==} - node-emoji@1.11.0: - resolution: {integrity: sha512-wo2DpQkQp7Sjm2A0cq+sN7EHKO6Sl0ctXeBdFZrL9T9+UywORbufTcTZxom8YqpLQt/FqNMUkOpkZrJVYSKD3A==} + isexe@2.0.0: + resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==} - node-exports-info@1.6.0: - resolution: {integrity: sha512-pyFS63ptit/P5WqUkt+UUfe+4oevH+bFeIiPPdfb0pFeYEu/1ELnJu5l+5EcTKYL5M7zaAa7S8ddywgXypqKCw==} - engines: {node: '>= 0.4'} + isexe@3.1.1: + resolution: {integrity: sha512-LpB/54B+/2J5hqQ7imZHfdU31OlgQqx7ZicVlkm9kzg9/w8GKLEcFfJl/t7DCEDueOyBAD6zCCwTO6Fzs0NoEQ==} + engines: {node: '>=16'} - node-fetch@2.7.0: - resolution: {integrity: sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==} - engines: {node: 4.x || >=6.0.0} + isows@1.0.4: + resolution: {integrity: sha512-hEzjY+x9u9hPmBom9IIAqdJCwNLax+xrPb51vEPpERoFlIxgmZcHzsT5jKG06nvInKOBGvReAVz80Umed5CczQ==} peerDependencies: - encoding: ^0.1.0 - peerDependenciesMeta: - encoding: - optional: true + ws: '*' - node-fetch@3.3.2: - resolution: {integrity: sha512-dRB78srN/l6gqWulah9SrxeYnxeddIG30+GOqK/9OlLVyLg3HPnr6SqOWTWOXKRwC2eGYCkZ59NNuSgvSrpgOA==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + isows@1.0.6: + resolution: {integrity: sha512-lPHCayd40oW98/I0uvgaHKWCSvkzY27LjWLbtzOm64yQ+G3Q5npjjbdppU65iZXkK1Zt+kH9pfegli0AYfwYYw==} + peerDependencies: + ws: '*' - node-forge@1.4.0: - resolution: {integrity: sha512-LarFH0+6VfriEhqMMcLX2F7SwSXeWwnEAJEsYm5QKWchiVYVvJyV9v7UDvUv+w5HO23ZpQTXDv/GxdDdMyOuoQ==} - engines: {node: '>= 6.13.0'} + isows@1.0.7: + resolution: {integrity: sha512-I1fSfDCZL5P0v33sVqeTDSpcstAg/N+wF5HS033mogOVIp4B+oHC7oOCsA3axAbBSGTJ8QubbNmnIRN/h8U7hg==} + peerDependencies: + ws: '*' - node-gyp-build@4.3.0: - resolution: {integrity: sha512-iWjXZvmboq0ja1pUGULQBexmxq8CV4xBhX7VDOTbL7ZR4FOowwY/VOtRxBN/yKxmdGoIp4j5ysNT4u3S2pDQ3Q==} - hasBin: true + istanbul-lib-coverage@3.2.2: + resolution: {integrity: sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg==} + engines: {node: '>=8'} - node-gyp-build@4.8.4: - resolution: {integrity: sha512-LA4ZjwlnUblHVgq0oBF3Jl/6h/Nvs5fzBLwdEF4nuxnFdsfajde4WfxtJr3CaiH+F6ewcIB/q4jQ4UzPyid+CQ==} - hasBin: true + istanbul-lib-report@3.0.1: + resolution: {integrity: sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw==} + engines: {node: '>=10'} - node-plop@0.26.3: - resolution: {integrity: sha512-Cov028YhBZ5aB7MdMWJEmwyBig43aGL5WT4vdoB28Oitau1zZAcHUn8Sgfk9HM33TqhtLJ9PlM/O0Mv+QpV/4Q==} - engines: {node: '>=8.9.4'} + istanbul-lib-source-maps@5.0.6: + resolution: {integrity: sha512-yg2d+Em4KizZC5niWhQaIomgf5WlL4vOOjZ5xGCmF8SnPE/mDWWXgvRExdcpCgh9lLRRa1/fSYp2ymmbJ1pI+A==} + engines: {node: '>=10'} - node-preload@0.2.1: - resolution: {integrity: sha512-RM5oyBy45cLEoHqCeh+MNuFAxO0vTFBLskvQbOKnEE7YTTSN4tbN8QWDIPQ6L+WvKsB/qLEGpYe2ZZ9d4W9OIQ==} + istanbul-reports@3.2.0: + resolution: {integrity: sha512-HGYWWS/ehqTV3xN10i23tkPkpH46MLCIMFNCaaKNavAXTF1RkqxawEPtnjnGZ6XKSInBKkiOA5BKS+aZiY3AvA==} engines: {node: '>=8'} - node-releases@2.0.27: - resolution: {integrity: sha512-nmh3lCkYZ3grZvqcCH+fjmQ7X+H0OeZgP40OierEaAptX4XofMh5kwNbWh7lBduUzCcV/8kZ+NDLCwm2iorIlA==} - - node-releases@2.0.38: - resolution: {integrity: sha512-3qT/88Y3FbH/Kx4szpQQ4HzUbVrHPKTLVpVocKiLfoYvw9XSGOX2FmD2d6DrXbVYyAQTF2HeF6My8jmzx7/CRw==} + jackspeak@3.4.3: + resolution: {integrity: sha512-OGlZQpz2yfahA/Rd1Y8Cd9SIEsqvXkLVoSw/cgwhnhFMDbsQFeZYoJJ7bIZBS9BcamUW96asq/npPWugM+RQBw==} - nodemon@3.1.14: - resolution: {integrity: sha512-jakjZi93UtB3jHMWsXL68FXSAosbLfY0In5gtKq3niLSkrWznrVBzXFNOEMJUfc9+Ke7SHWoAZsiMkNP3vq6Jw==} - engines: {node: '>=10'} + jiti@1.21.0: + resolution: {integrity: sha512-gFqAIbuKyyso/3G2qhiO2OM6shY6EPP/R0+mkDbyspxKazh8BXDC5FiFsUjlczgdNz/vfra0da2y+aHrusLG/Q==} hasBin: true - nofilter@3.1.0: - resolution: {integrity: sha512-l2NNj07e9afPnhAhvgVrCD/oy2Ai1yfLpuo3EpiO1jFTsB4sFz6oIfAfSZyQzVpkZQ9xS8ZS5g1jCBgq4Hwo0g==} - engines: {node: '>=12.19'} + jiti@1.21.6: + resolution: {integrity: sha512-2yTgeWTWzMWkHu6Jp9NKgePDaYHbntiwvYuuJLbbN9vl7DC9DvXKOB2BC3ZZ92D3cvV/aflH0osDfwpHepQ53w==} + hasBin: true - nopt@3.0.6: - resolution: {integrity: sha512-4GUt3kSEYmk4ITxzB/b9vaIDfUVWN/Ml1Fwl11IlnIG2iaJ9O6WXZ9SrYM9NLI8OCBieN2Y8SWC2oJV0RQ7qYg==} + jiti@1.21.7: + resolution: {integrity: sha512-/imKNG4EbWNrVjoNC/1H5/9GFy+tqjGBHCaSsN+P2RnPqjsLmv6UD3Ej+Kj8nBWaRAwyk7kK5ZUc+OEatnTR3A==} hasBin: true - normalize-package-data@2.5.0: - resolution: {integrity: sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==} + jiti@2.6.1: + resolution: {integrity: sha512-ekilCSN1jwRvIbgeg/57YFh8qQDNbwDb9xT/qu2DAHbFFZUicIl4ygVaAvzveMhMVr3LnpSKTNnwt8PoOfmKhQ==} + hasBin: true - normalize-path@3.0.0: - resolution: {integrity: sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==} - engines: {node: '>=0.10.0'} + jose@5.9.6: + resolution: {integrity: sha512-AMlnetc9+CV9asI19zHmrgS/WYsWUwCn2R7RzlbJWD7F9eWYUTGyBmU9o6PxngtLGOiDGPRu+Uc4fhKzbpteZQ==} - normalize-url@6.1.0: - resolution: {integrity: sha512-DlL+XwOy3NxAQ8xuC0okPgK46iuVNAK01YN7RueYBqqFeGsBjV9XmCAzAdgt+667bCl5kPh9EqKKDwnaPG1I7A==} + joycon@3.1.1: + resolution: {integrity: sha512-34wB/Y7MW7bzjKRjUKTa46I2Z7eV62Rkhva+KkopW7Qvv/OSWBqvkSY7vusOPrNuZcUG3tApvdVgNB8POj3SPw==} engines: {node: '>=10'} - npm-package-arg@11.0.3: - resolution: {integrity: sha512-sHGJy8sOC1YraBywpzQlIKBE4pBbGbiF95U6Auspzyem956E0+FtDtsx1ZxlOJkQCZ1AFXAY/yuvtFYrOxF+Bw==} - engines: {node: ^16.14.0 || >=18.0.0} + js-base64@3.7.8: + resolution: {integrity: sha512-hNngCeKxIUQiEUN3GPJOkz4wF/YvdUdbNL9hsBcMQTkKzboD7T/q3OYOuuPZLUE6dBxSGpwhk5mwuDud7JVAow==} - npm-registry-fetch@17.1.0: - resolution: {integrity: sha512-5+bKQRH0J1xG1uZ1zMNvxW0VEyoNWgJpY9UDuluPFLKDfJ9u2JmmjmTJV1srBGQOROfdBMiVvnH2Zvpbm+xkVA==} - engines: {node: ^16.14.0 || >=18.0.0} + js-beautify@1.15.1: + resolution: {integrity: sha512-ESjNzSlt/sWE8sciZH8kBF8BPlwXPwhR6pWKAw8bw4Bwj+iZcnKW6ONWUutJ7eObuBZQpiIb8S7OYspWrKt7rA==} + engines: {node: '>=14'} + hasBin: true - npm-run-path@4.0.1: - resolution: {integrity: sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==} - engines: {node: '>=8'} + js-cookie@3.0.5: + resolution: {integrity: sha512-cEiJEAEoIbWfCZYKWhVwFuvPX1gETRYPw6LlaTKoxD3s2AkXzkCjnp6h0V77ozyqj0jakteJ4YqDJT830+lVGw==} + engines: {node: '>=14'} - number-is-nan@1.0.1: - resolution: {integrity: sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==} - engines: {node: '>=0.10.0'} + js-sha3@0.8.0: + resolution: {integrity: sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==} - number-to-bn@1.7.0: - resolution: {integrity: sha512-wsJ9gfSz1/s4ZsJN01lyonwuxA1tml6X1yBDnfpMglypcBRFZZkus26EdPSlqS5GJfYddVZa22p3VNb3z5m5Ig==} - engines: {node: '>=6.5.0', npm: '>=3'} + js-tokens@4.0.0: + resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==} - nyc@15.1.0: - resolution: {integrity: sha512-jMW04n9SxKdKi1ZMGhvUTHBN0EICCRkHemEoE5jm6mTYcqcdas0ATzgUgejlQUHMvpnOZqGB5Xxsv9KxJW1j8A==} - engines: {node: '>=8.9'} + js-tokens@9.0.1: + resolution: {integrity: sha512-mxa9E9ITFOt0ban3j6L5MpjwegGz6lBQmM1IJkWeBZGcMxto50+eWdjC/52xDbS2vy0k7vIMK0Fe2wfL9OQSpQ==} + + js-yaml@3.14.1: + resolution: {integrity: sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==} hasBin: true - oauth-sign@0.9.0: - resolution: {integrity: sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==} + js-yaml@4.1.0: + resolution: {integrity: sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==} + hasBin: true - object-assign@4.1.1: - resolution: {integrity: sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==} - engines: {node: '>=0.10.0'} + js-yaml@4.1.1: + resolution: {integrity: sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==} + hasBin: true - object-inspect@1.13.4: - resolution: {integrity: sha512-W67iLl4J2EXEGTbfeHCffrjDfitvLANg0UlX3wFUUSTx92KXRFegMHUVgSqE+wvhAbi4WqjGg9czysTV2Epbew==} - engines: {node: '>= 0.4'} + jsesc@2.5.2: + resolution: {integrity: sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==} + engines: {node: '>=4'} + hasBin: true - object-keys@0.4.0: - resolution: {integrity: sha512-ncrLw+X55z7bkl5PnUvHwFK9FcGuFYo9gtjws2XtSzL+aZ8tm830P60WJ0dSmFVaSalWieW5MD7kEdnXda9yJw==} + jsesc@3.1.0: + resolution: {integrity: sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA==} + engines: {node: '>=6'} + hasBin: true - object-keys@1.1.1: - resolution: {integrity: sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==} - engines: {node: '>= 0.4'} + json-canonicalize@1.2.0: + resolution: {integrity: sha512-TTdjBvqrqJKSADlEsY5rWbx8/1tOrVlTR/aSLU8N2VSInCTffP0p+byYB8Es+OmL4ZOeEftjUdvV+eJeSzJC/Q==} - object.assign@4.1.7: - resolution: {integrity: sha512-nK28WOo+QIjBkDduTINE4JkF/UJJKyf2EJxvJKfblDpyg0Q+pkOHNTL0Qwy6NP6FhE/EnzV73BxxqcJaXY9anw==} - engines: {node: '>= 0.4'} + json-rpc-engine@6.1.0: + resolution: {integrity: sha512-NEdLrtrq1jUZyfjkr9OCz9EzCNhnRyWtt1PAnvnhwy6e8XETS0Dtc+ZNCO2gvuAoKsIn2+vCSowXTYE4CkgnAQ==} + engines: {node: '>=10.0.0'} - object.entries@1.1.9: - resolution: {integrity: sha512-8u/hfXFRBD1O0hPUjioLhoWFHRmt6tKA4/vZPyckBr18l1KE9uHrFaFaUi8MDRTpi4uak2goyPTSNJLXX2k2Hw==} - engines: {node: '>= 0.4'} + json-rpc-random-id@1.0.1: + resolution: {integrity: sha512-RJ9YYNCkhVDBuP4zN5BBtYAzEl03yq/jIIsyif0JY9qyJuQQZNeDK7anAPKKlyEtLSj2s8h6hNh2F8zO5q7ScA==} - object.fromentries@2.0.8: - resolution: {integrity: sha512-k6E21FzySsSK5a21KRADBd/NGneRegFO5pLHfdQLpRDETUNJueLXs3WCzyQ3tFRDYgbq3KHGXfTbi2bs8WQ6rQ==} - engines: {node: '>= 0.4'} + json-schema-to-ts@1.6.4: + resolution: {integrity: sha512-pR4yQ9DHz6itqswtHCm26mw45FSNfQ9rEQjosaZErhn5J3J2sIViQiz8rDaezjKAhFGpmsoczYVBgGHzFw/stA==} - object.groupby@1.0.3: - resolution: {integrity: sha512-+Lhy3TQTuzXI5hevh8sBGqbmurHbbIjAi0Z4S63nthVLmLxfbj4T54a4CfZrXIrt9iP4mVAPYMo/v99taj3wjQ==} - engines: {node: '>= 0.4'} + json-schema-traverse@1.0.0: + resolution: {integrity: sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==} - object.values@1.2.1: - resolution: {integrity: sha512-gXah6aZrcUxjWg2zR2MwouP2eHlCBzdV4pygudehaKXSGW4v2AsRQUK+lwwXhii6KFZcunEnmSUoYp5CXibxtA==} - engines: {node: '>= 0.4'} + json5@2.2.3: + resolution: {integrity: sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==} + engines: {node: '>=6'} + hasBin: true - obliterator@2.0.5: - resolution: {integrity: sha512-42CPE9AhahZRsMNslczq0ctAEtqk8Eka26QofnqC346BZdHDySk3LWka23LI7ULIw11NmltpiLagIq8gBozxTw==} + jsonfile@2.4.0: + resolution: {integrity: sha512-PKllAqbgLgxHaj8TElYymKCAgrASebJrWpTnEkOaTowt23VKXXN0sUeriJ+eh7y6ufb/CC5ap11pz71/cM0hUw==} - oboe@2.1.5: - resolution: {integrity: sha512-zRFWiF+FoicxEs3jNI/WYUrVEgA7DeET/InK0XQuudGHRg8iIob3cNPrJTKaz4004uaA9Pbe+Dwa8iluhjLZWA==} + jsonfile@4.0.0: + resolution: {integrity: sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==} - observable-fns@0.6.1: - resolution: {integrity: sha512-9gRK4+sRWzeN6AOewNBTLXir7Zl/i3GB6Yl26gK4flxz8BXVpD3kt8amREmWNb0mxYOGDotvE5a4N+PtGGKdkg==} + jsonfile@6.2.0: + resolution: {integrity: sha512-FGuPw30AdOIUTRMC2OMRtQV+jkVj2cfPqSeWXv1NEAJ1qZ5zb1X6z1mFhbfOB/iy3ssJCD+3KuZ8r8C3uVFlAg==} - obug@2.1.1: - resolution: {integrity: sha512-uTqF9MuPraAQ+IsnPf366RG4cP9RtUi7MLO1N3KEc+wb0a6yKpeL0lmk2IB1jY5KHPAlTc6T/JRdC/YqxHNwkQ==} + jwt-decode@4.0.0: + resolution: {integrity: sha512-+KJGIyHgkGuIq3IEBNftfhW/LfWhXUIY6OmyVWjliu5KH1y0fw7VQ8YndE2O4qZdMSd9SqbnC8GOcZEy0Om7sA==} + engines: {node: '>=18'} - on-finished@2.3.0: - resolution: {integrity: sha512-ikqdkGAAyf/X/gPhXGvfgAytDZtDbr+bkNUJ0N9h5MI/dmdgCs3l6hoHrcUv41sRKew3jIwrp4qQDXiK99Utww==} - engines: {node: '>= 0.8'} + keccak256@1.0.6: + resolution: {integrity: sha512-8GLiM01PkdJVGUhR1e6M/AvWnSqYS0HaERI+K/QtStGDGlSTx2B1zTqZk4Zlqu5TxHJNTxWAdP9Y+WI50OApUw==} - on-finished@2.4.1: - resolution: {integrity: sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg==} - engines: {node: '>= 0.8'} + keccak@3.0.3: + resolution: {integrity: sha512-JZrLIAJWuZxKbCilMpNz5Vj7Vtb4scDG3dMXLOsbzBmQGyjwE61BbW7bJkfKKCShXiQZt3T6sBgALRtmd+nZaQ==} + engines: {node: '>=10.0.0'} - once@1.4.0: - resolution: {integrity: sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==} + keccak@3.0.4: + resolution: {integrity: sha512-3vKuW0jV8J3XNTzvfyicFR5qvxrSAGl7KIhvgOu5cmWwM7tZRj3fMbj/pfIf4be7aznbc+prBWGjywox/g2Y6Q==} + engines: {node: '>=10.0.0'} - onetime@5.1.2: - resolution: {integrity: sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==} + keyvaluestorage-interface@1.0.0: + resolution: {integrity: sha512-8t6Q3TclQ4uZynJY9IGr2+SsIGwK9JHcO6ootkHCGA0CrQCRy+VkouYNO2xicET6b9al7QKzpebNow+gkpCL8g==} + + klaw@1.3.1: + resolution: {integrity: sha512-TED5xi9gGQjGpNnvRWknrwAB1eL5GciPfVFOt3Vk1OJCVDQbzuSfrF3hkUQKlsgKrG1F+0t5W0m+Fje1jIt8rw==} + + kleur@3.0.3: + resolution: {integrity: sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==} engines: {node: '>=6'} - open@8.4.2: - resolution: {integrity: sha512-7x81NCL719oNbsq/3mh+hVrAWmFuEYUqrq/Iw3kUzH8ReypT9QQ0BLoJS7/G9k6N81XjW4qHWtjWwe/9eLy1EQ==} - engines: {node: '>=12'} + kleur@4.1.5: + resolution: {integrity: sha512-o+NO+8WrRiQEE4/7nwRJhN1HWpVmJm511pBHUxPLtp0BUISzlBplORYSmTclCnJvQq2tKu/sgl3xVpkc7ZWuQQ==} + engines: {node: '>=6'} - optionator@0.8.3: - resolution: {integrity: sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==} - engines: {node: '>= 0.8.0'} + klona@2.0.6: + resolution: {integrity: sha512-dhG34DXATL5hSxJbIexCft8FChFXtmskoZYnoPWjXQuebWYCNkVeV3KkGegCK9CP1oswI/vQibS2GY7Em/sJJA==} + engines: {node: '>= 8'} - optionator@0.9.4: - resolution: {integrity: sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==} - engines: {node: '>= 0.8.0'} + knip@5.30.6: + resolution: {integrity: sha512-YkcnRVl0N99xZ7eaXE7KlH/4cPTCn6BGuk9KxINEdCMFN3yita2vGBizApy97ZOHgghy8tb589gQ3xvLMFIO4w==} + engines: {node: '>=18.6.0'} + hasBin: true + peerDependencies: + '@types/node': '>=18' + typescript: '>=5.0.4' - ora@4.1.1: - resolution: {integrity: sha512-sjYP8QyVWBpBZWD6Vr1M/KwknSw6kJOz41tvGMlwWeClHBtYKTbHMki1PsLZnxKpXMPbTKv9b3pjQu3REib96A==} - engines: {node: '>=8'} + knitwork@1.3.0: + resolution: {integrity: sha512-4LqMNoONzR43B1W0ek0fhXMsDNW/zxa1NdFAVMY+k28pgZLovR4G3PB5MrpTxCy1QaZCqNoiaKPr5w5qZHfSNw==} - ora@5.4.1: - resolution: {integrity: sha512-5b6Y85tPxZZ7QytO+BQzysW31HJku27cRIlkbAXaNx+BdcVi+LlRFmVXzeF6a7JCwJpyw5c4b+YSVImQIrBpuQ==} - engines: {node: '>=10'} + kolorist@1.8.0: + resolution: {integrity: sha512-Y+60/zizpJ3HRH8DCss+q95yr6145JXZo46OTpFvDZWLfRCE4qChOyk1b26nMaNpfHHgxagk9dXT5OP0Tfe+dQ==} - os-locale@1.4.0: - resolution: {integrity: sha512-PRT7ZORmwu2MEFt4/fv3Q+mEfN4zetKxufQrkShY2oGvUms9r8otu5HfdyIFHkYXjO7laNsoVGmM2MANfuTA8g==} - engines: {node: '>=0.10.0'} + launch-editor@2.12.0: + resolution: {integrity: sha512-giOHXoOtifjdHqUamwKq6c49GzBdLjvxrd2D+Q4V6uOHopJv7p9VJxikDsQ/CBXZbEITgUqSVHXLTG3VhPP1Dg==} - outdent@0.5.0: - resolution: {integrity: sha512-/jHxFIzoMXdqPzTaCpFzAAWhpkSjZPF4Vsn6jAfNpmbH/ymsmd7Qc6VE9BGn0L6YMj6uwpQLxCECpus4ukKS9Q==} + lazystream@1.0.1: + resolution: {integrity: sha512-b94GiNHQNy6JNTrt5w6zNyffMrNkXZb3KTkCZJb2V1xaEGCk093vkZ2jk3tpaeP33/OiXC+WvK9AxUebnf5nbw==} + engines: {node: '>= 0.6.3'} - own-keys@1.0.1: - resolution: {integrity: sha512-qFOyK5PjiWZd+QQIh+1jhdb9LpxTF0qs7Pm8o5QHYZ0M3vKqSqzsZaEB6oWlxZ+q2sJBMI/Ktgd2N5ZwQoRHfg==} - engines: {node: '>= 0.4'} + lefthook-darwin-arm64@1.13.6: + resolution: {integrity: sha512-m6Lb77VGc84/Qo21Lhq576pEvcgFCnvloEiP02HbAHcIXD0RTLy9u2yAInrixqZeaz13HYtdDaI7OBYAAdVt8A==} + cpu: [arm64] + os: [darwin] - ox@0.9.17: - resolution: {integrity: sha512-rKAnhzhRU3Xh3hiko+i1ZxywZ55eWQzeS/Q4HRKLx2PqfHOolisZHErSsJVipGlmQKHW5qwOED/GighEw9dbLg==} - peerDependencies: - typescript: '>=5.4.0' - peerDependenciesMeta: - typescript: - optional: true + lefthook-darwin-x64@1.13.6: + resolution: {integrity: sha512-CoRpdzanu9RK3oXR1vbEJA5LN7iB+c7hP+sONeQJzoOXuq4PNKVtEaN84Gl1BrVtCNLHWFAvCQaZPPiiXSy8qg==} + cpu: [x64] + os: [darwin] - p-cancelable@2.1.1: - resolution: {integrity: sha512-BZOr3nRQHOntUjTrH8+Lh54smKHoHyur8We1V8DSMVrl5A2malOOwuJRnKRDjSnkoeBh4at6BwEnb5I7Jl31wg==} - engines: {node: '>=8'} + lefthook-freebsd-arm64@1.13.6: + resolution: {integrity: sha512-X4A7yfvAJ68CoHTqP+XvQzdKbyd935sYy0bQT6Ajz7FL1g7hFiro8dqHSdPdkwei9hs8hXeV7feyTXbYmfjKQQ==} + cpu: [arm64] + os: [freebsd] - p-cancelable@3.0.0: - resolution: {integrity: sha512-mlVgR3PGuzlo0MmTdk4cXqXWlwQDLnONTAg6sm62XkMJEiRxN3GL3SffkYvqwonbkJBcrI7Uvv5Zh9yjvn2iUw==} - engines: {node: '>=12.20'} + lefthook-freebsd-x64@1.13.6: + resolution: {integrity: sha512-ai2m+Sj2kGdY46USfBrCqLKe9GYhzeq01nuyDYCrdGISePeZ6udOlD1k3lQKJGQCHb0bRz4St0r5nKDSh1x/2A==} + cpu: [x64] + os: [freebsd] - p-filter@2.1.0: - resolution: {integrity: sha512-ZBxxZ5sL2HghephhpGAQdoskxplTwr7ICaehZwLIlfL6acuVgZPm8yBNuRAFBGEqtD/hmUeq9eqLg2ys9Xr/yw==} - engines: {node: '>=8'} + lefthook-linux-arm64@1.13.6: + resolution: {integrity: sha512-cbo4Wtdq81GTABvikLORJsAWPKAJXE8Q5RXsICFUVznh5PHigS9dFW/4NXywo0+jfFPCT6SYds2zz4tCx6DA0Q==} + cpu: [arm64] + os: [linux] - p-limit@2.3.0: - resolution: {integrity: sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==} - engines: {node: '>=6'} + lefthook-linux-x64@1.13.6: + resolution: {integrity: sha512-uJl9vjCIIBTBvMZkemxCE+3zrZHlRO7Oc+nZJ+o9Oea3fu+W82jwX7a7clw8jqNfaeBS+8+ZEQgiMHWCloTsGw==} + cpu: [x64] + os: [linux] - p-limit@3.1.0: - resolution: {integrity: sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==} - engines: {node: '>=10'} + lefthook-openbsd-arm64@1.13.6: + resolution: {integrity: sha512-7r153dxrNRQ9ytRs2PmGKKkYdvZYFPre7My7XToSTiRu5jNCq++++eAKVkoyWPduk97dGIA+YWiEr5Noe0TK2A==} + cpu: [arm64] + os: [openbsd] - p-locate@4.1.0: - resolution: {integrity: sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==} - engines: {node: '>=8'} + lefthook-openbsd-x64@1.13.6: + resolution: {integrity: sha512-Z+UhLlcg1xrXOidK3aLLpgH7KrwNyWYE3yb7ITYnzJSEV8qXnePtVu8lvMBHs/myzemjBzeIr/U/+ipjclR06g==} + cpu: [x64] + os: [openbsd] - p-locate@5.0.0: - resolution: {integrity: sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==} - engines: {node: '>=10'} + lefthook-windows-arm64@1.13.6: + resolution: {integrity: sha512-Uxef6qoDxCmUNQwk8eBvddYJKSBFglfwAY9Y9+NnnmiHpWTjjYiObE9gT2mvGVpEgZRJVAatBXc+Ha5oDD/OgQ==} + cpu: [arm64] + os: [win32] - p-map@2.1.0: - resolution: {integrity: sha512-y3b8Kpd8OAN444hxfBbFfj1FY/RjtTd8tzYwhUqNYXx0fXx2iX4maP4Qr6qhIKbQXI02wTLAda4fYUbDagTUFw==} - engines: {node: '>=6'} + lefthook-windows-x64@1.13.6: + resolution: {integrity: sha512-mOZoM3FQh3o08M8PQ/b3IYuL5oo36D9ehczIw1dAgp1Ly+Tr4fJ96A+4SEJrQuYeRD4mex9bR7Ps56I73sBSZA==} + cpu: [x64] + os: [win32] - p-map@3.0.0: - resolution: {integrity: sha512-d3qXVTF/s+W+CdJ5A29wywV2n8CQQYahlgz2bFiA+4eVNJbHJodPZ+/gXwPGh0bOqA+j8S+6+ckmvLGPk1QpxQ==} - engines: {node: '>=8'} + lefthook@1.13.6: + resolution: {integrity: sha512-ojj4/4IJ29Xn4drd5emqVgilegAPN3Kf0FQM2p/9+lwSTpU+SZ1v4Ig++NF+9MOa99UKY8bElmVrLhnUUNFh5g==} + hasBin: true - p-map@4.0.0: - resolution: {integrity: sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==} - engines: {node: '>=10'} + lightningcss-android-arm64@1.30.2: + resolution: {integrity: sha512-BH9sEdOCahSgmkVhBLeU7Hc9DWeZ1Eb6wNS6Da8igvUwAe0sqROHddIlvU06q3WyXVEOYDZ6ykBZQnjTbmo4+A==} + engines: {node: '>= 12.0.0'} + cpu: [arm64] + os: [android] - p-try@2.2.0: - resolution: {integrity: sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==} - engines: {node: '>=6'} + lightningcss-darwin-arm64@1.30.2: + resolution: {integrity: sha512-ylTcDJBN3Hp21TdhRT5zBOIi73P6/W0qwvlFEk22fkdXchtNTOU4Qc37SkzV+EKYxLouZ6M4LG9NfZ1qkhhBWA==} + engines: {node: '>= 12.0.0'} + cpu: [arm64] + os: [darwin] - pac-proxy-agent@7.2.0: - resolution: {integrity: sha512-TEB8ESquiLMc0lV8vcd5Ql/JAKAoyzHFXaStwjkzpOpC5Yv+pIzLfHvjTSdf3vpa2bMiUQrg9i6276yn8666aA==} - engines: {node: '>= 14'} + lightningcss-darwin-x64@1.30.2: + resolution: {integrity: sha512-oBZgKchomuDYxr7ilwLcyms6BCyLn0z8J0+ZZmfpjwg9fRVZIR5/GMXd7r9RH94iDhld3UmSjBM6nXWM2TfZTQ==} + engines: {node: '>= 12.0.0'} + cpu: [x64] + os: [darwin] - pac-resolver@7.0.1: - resolution: {integrity: sha512-5NPgf87AT2STgwa2ntRMr45jTKrYBGkVU36yT0ig/n/GMAa3oPqhZfIQ2kMEimReg0+t9kZViDVZ83qfVUlckg==} - engines: {node: '>= 14'} + lightningcss-freebsd-x64@1.30.2: + resolution: {integrity: sha512-c2bH6xTrf4BDpK8MoGG4Bd6zAMZDAXS569UxCAGcA7IKbHNMlhGQ89eRmvpIUGfKWNVdbhSbkQaWhEoMGmGslA==} + engines: {node: '>= 12.0.0'} + cpu: [x64] + os: [freebsd] - package-hash@4.0.0: - resolution: {integrity: sha512-whdkPIooSu/bASggZ96BWVvZTRMOFxnyUG5PnTSGKoJE2gd5mbVNmR2Nj20QFzxYYgAXpoqC+AiXzl+UMRh7zQ==} - engines: {node: '>=8'} + lightningcss-linux-arm-gnueabihf@1.30.2: + resolution: {integrity: sha512-eVdpxh4wYcm0PofJIZVuYuLiqBIakQ9uFZmipf6LF/HRj5Bgm0eb3qL/mr1smyXIS1twwOxNWndd8z0E374hiA==} + engines: {node: '>= 12.0.0'} + cpu: [arm] + os: [linux] - package-json-from-dist@1.0.1: - resolution: {integrity: sha512-UEZIS3/by4OC8vL3P2dTXRETpebLI2NiI5vIrjaD/5UtrkFX/tNbwjTSRAGC/+7CAo2pIcBaRgWmcBBHcsaCIw==} + lightningcss-linux-arm64-gnu@1.30.2: + resolution: {integrity: sha512-UK65WJAbwIJbiBFXpxrbTNArtfuznvxAJw4Q2ZGlU8kPeDIWEX1dg3rn2veBVUylA2Ezg89ktszWbaQnxD/e3A==} + engines: {node: '>= 12.0.0'} + cpu: [arm64] + os: [linux] - package-manager-detector@0.2.11: - resolution: {integrity: sha512-BEnLolu+yuz22S56CU1SUKq3XC3PkwD5wv4ikR4MfGvnRVcmzXR9DwSlW2fEamyTPyXHomBJRzgapeuBvRNzJQ==} + lightningcss-linux-arm64-musl@1.30.2: + resolution: {integrity: sha512-5Vh9dGeblpTxWHpOx8iauV02popZDsCYMPIgiuw97OJ5uaDsL86cnqSFs5LZkG3ghHoX5isLgWzMs+eD1YzrnA==} + engines: {node: '>= 12.0.0'} + cpu: [arm64] + os: [linux] - param-case@2.1.1: - resolution: {integrity: sha512-eQE845L6ot89sk2N8liD8HAuH4ca6Vvr7VWAWwt7+kvvG5aBcPmmphQ68JsEG2qa9n1TykS2DLeMt363AAH8/w==} + lightningcss-linux-x64-gnu@1.30.2: + resolution: {integrity: sha512-Cfd46gdmj1vQ+lR6VRTTadNHu6ALuw2pKR9lYq4FnhvgBc4zWY1EtZcAc6EffShbb1MFrIPfLDXD6Xprbnni4w==} + engines: {node: '>= 12.0.0'} + cpu: [x64] + os: [linux] - parent-module@1.0.1: - resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==} - engines: {node: '>=6'} + lightningcss-linux-x64-musl@1.30.2: + resolution: {integrity: sha512-XJaLUUFXb6/QG2lGIW6aIk6jKdtjtcffUT0NKvIqhSBY3hh9Ch+1LCeH80dR9q9LBjG3ewbDjnumefsLsP6aiA==} + engines: {node: '>= 12.0.0'} + cpu: [x64] + os: [linux] - parse-cache-control@1.0.1: - resolution: {integrity: sha512-60zvsJReQPX5/QP0Kzfd/VrpjScIQ7SHBW6bFCYfEP+fp0Eppr1SHhIO5nd1PjZtvclzSzES9D/p5nFJurwfWg==} + lightningcss-win32-arm64-msvc@1.30.2: + resolution: {integrity: sha512-FZn+vaj7zLv//D/192WFFVA0RgHawIcHqLX9xuWiQt7P0PtdFEVaxgF9rjM/IRYHQXNnk61/H/gb2Ei+kUQ4xQ==} + engines: {node: '>= 12.0.0'} + cpu: [arm64] + os: [win32] - parse-headers@2.0.6: - resolution: {integrity: sha512-Tz11t3uKztEW5FEVZnj1ox8GKblWn+PvHY9TmJV5Mll2uHEwRdR/5Li1OlXoECjLYkApdhWy44ocONwXLiKO5A==} + lightningcss-win32-x64-msvc@1.30.2: + resolution: {integrity: sha512-5g1yc73p+iAkid5phb4oVFMB45417DkRevRbt/El/gKXJk4jid+vPFF/AXbxn05Aky8PapwzZrdJShv5C0avjw==} + engines: {node: '>= 12.0.0'} + cpu: [x64] + os: [win32] - parse-json@2.2.0: - resolution: {integrity: sha512-QR/GGaKCkhwk1ePQNYDRKYZ3mwU9ypsKhB0XyFnLQdomyEqk3e8wpW3V5Jp88zbxK4n5ST1nqo+g9juTpownhQ==} - engines: {node: '>=0.10.0'} + lightningcss@1.30.2: + resolution: {integrity: sha512-utfs7Pr5uJyyvDETitgsaqSyjCb2qNRAtuqUeWIAKztsOYdcACf2KtARYXg2pSvhkt+9NfoaNY7fxjl6nuMjIQ==} + engines: {node: '>= 12.0.0'} - parse-json@5.2.0: - resolution: {integrity: sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==} - engines: {node: '>=8'} + lilconfig@3.1.3: + resolution: {integrity: sha512-/vlFKAoH5Cgt3Ie+JLhRbwOsCQePABiU3tJ1egGvyQ+33R/vcwM2Zl2QR/LzjsBeItPt3oSVXapn+m4nQDvpzw==} + engines: {node: '>=14'} - parse-multipart-data@1.5.0: - resolution: {integrity: sha512-ck5zaMF0ydjGfejNMnlo5YU2oJ+pT+80Jb1y4ybanT27j+zbVP/jkYmCrUGsEln0Ox/hZmuvgy8Ra7AxbXP2Mw==} + listhen@1.7.2: + resolution: {integrity: sha512-7/HamOm5YD9Wb7CFgAZkKgVPA96WwhcTQoqtm2VTZGVbVVn3IWKRBTgrU7cchA3Q8k9iCsG8Osoi9GX4JsGM9g==} + hasBin: true - parseurl@1.3.3: - resolution: {integrity: sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==} - engines: {node: '>= 0.8'} + listhen@1.9.0: + resolution: {integrity: sha512-I8oW2+QL5KJo8zXNWX046M134WchxsXC7SawLPvRQpogCbkyQIaFxPE89A2HiwR7vAK2Dm2ERBAmyjTYGYEpBg==} + hasBin: true - pascal-case@2.0.1: - resolution: {integrity: sha512-qjS4s8rBOJa2Xm0jmxXiyh1+OFf6ekCWOvUaRgAQSktzlTbMotS0nmG9gyYAybCWBcuP4fsBeRCKNwGBnMe2OQ==} + lit-element@4.2.0: + resolution: {integrity: sha512-MGrXJVAI5x+Bfth/pU9Kst1iWID6GHDLEzFEnyULB/sFiRLgkd8NPK/PeeXxktA3T6EIIaq8U3KcbTU5XFcP2Q==} - path-browserify@1.0.1: - resolution: {integrity: sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==} + lit-html@3.3.0: + resolution: {integrity: sha512-RHoswrFAxY2d8Cf2mm4OZ1DgzCoBKUKSPvA1fhtSELxUERq2aQQ2h05pO9j81gS1o7RIRJ+CePLogfyahwmynw==} - path-case@2.1.1: - resolution: {integrity: sha512-Ou0N05MioItesaLr9q8TtHVWmJ6fxWdqKB2RohFmNWVyJ+2zeKIeDNWAN6B/Pe7wpzWChhZX6nONYmOnMeJQ/Q==} + lit@3.1.0: + resolution: {integrity: sha512-rzo/hmUqX8zmOdamDAeydfjsGXbbdtAFqMhmocnh2j9aDYqbu0fjXygjCa0T99Od9VQ/2itwaGrjZz/ZELVl7w==} - path-exists@2.1.0: - resolution: {integrity: sha512-yTltuKuhtNeFJKa1PiRzfLAU5182q1y4Eb4XCJ3PBqyzEDkAZRzBrKKBct682ls9reBVHf9udYLN5Nd+K1B9BQ==} - engines: {node: '>=0.10.0'} + load-tsconfig@0.2.5: + resolution: {integrity: sha512-IXO6OCs9yg8tMKzfPZ1YmheJbZCiEsnBdcB03l0OcfK9prKnJb96siuHCr5Fl37/yo9DnKU+TLpxzTUspw9shg==} + engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - path-exists@4.0.0: - resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} - engines: {node: '>=8'} + local-pkg@0.5.0: + resolution: {integrity: sha512-ok6z3qlYyCDS4ZEU27HaU6x/xZa9Whf8jD4ptH5UZTQYZVYeb9bnZ3ojVhiJNLiXK1Hfc0GNbLXcmZ5plLDDBg==} + engines: {node: '>=14'} - path-expression-matcher@1.5.0: - resolution: {integrity: sha512-cbrerZV+6rvdQrrD+iGMcZFEiiSrbv9Tfdkvnusy6y0x0GKBXREFg/Y65GhIfm0tnLntThhzCnfKwp1WRjeCyQ==} - engines: {node: '>=14.0.0'} + local-pkg@0.5.1: + resolution: {integrity: sha512-9rrA30MRRP3gBD3HTGnC6cDFpaE1kVDWxWgqWJUN0RvDNAo+Nz/9GxB+nHOH0ifbVFy0hSA1V6vFDvnx54lTEQ==} + engines: {node: '>=14'} - path-is-absolute@1.0.1: - resolution: {integrity: sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==} - engines: {node: '>=0.10.0'} + local-pkg@1.1.2: + resolution: {integrity: sha512-arhlxbFRmoQHl33a0Zkle/YWlmNwoyt6QNZEIJcqNbdrsix5Lvc4HyyI3EnwxTYlZYc32EbYrQ8SzEZ7dqgg9A==} + engines: {node: '>=14'} - path-key@3.1.1: - resolution: {integrity: sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==} + locate-path@2.0.0: + resolution: {integrity: sha512-NCI2kiDkyR7VeEKm27Kda/iQHyKJe1Bu0FlTbYp3CqJu+9IFe9bLyAjMxf5ZDDbEg+iMPzB5zYyUTSm8wVTKmA==} + engines: {node: '>=4'} + + locate-path@5.0.0: + resolution: {integrity: sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==} engines: {node: '>=8'} - path-parse@1.0.7: - resolution: {integrity: sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==} + locate-path@6.0.0: + resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==} + engines: {node: '>=10'} - path-scurry@1.11.1: - resolution: {integrity: sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==} - engines: {node: '>=16 || 14 >=14.18'} + lodash.defaults@4.2.0: + resolution: {integrity: sha512-qjxPLHd3r5DnsdGacqOMU6pb/avJzdh9tFX2ymgoZE27BmjXrNy/y4LoaiTeAb+O3gL8AfpJGtqfX/ae2leYYQ==} - path-scurry@2.0.2: - resolution: {integrity: sha512-3O/iVVsJAPsOnpwWIeD+d6z/7PmqApyQePUtCndjatj/9I5LylHvt5qluFaBT3I5h3r1ejfR056c+FCv+NnNXg==} - engines: {node: 18 || 20 || >=22} + lodash.isarguments@3.1.0: + resolution: {integrity: sha512-chi4NHZlZqZD18a0imDHnZPrDeBbTtVN7GXMwuGdRH9qotxAjYs3aVLKc7zNOG9eddR5Ksd8rvFEBc9SsggPpg==} - path-to-regexp@0.1.13: - resolution: {integrity: sha512-A/AGNMFN3c8bOlvV9RreMdrv7jsmF9XIfDeCd87+I8RNg6s78BhJxMu69NEMHBSJFxKidViTEdruRwEk/WIKqA==} + lodash.memoize@4.1.2: + resolution: {integrity: sha512-t7j+NzmgnQzTAYXcsHYLgimltOV1MXHtlOWf6GjL9Kj8GK5FInw5JotxvbOs+IvV1/Dzo04/fCGfLVs7aXb4Ag==} - path-type@1.1.0: - resolution: {integrity: sha512-S4eENJz1pkiQn9Znv33Q+deTOKmbl+jj1Fl+qiP/vYezj+S8x+J3Uo0ISrx/QoEvIlOaDWJhPaRd1flJ9HXZqg==} - engines: {node: '>=0.10.0'} + lodash.startcase@4.4.0: + resolution: {integrity: sha512-+WKqsK294HMSc2jEbNgpHpd0JfIBhp7rEV4aqXWqFr6AlXov+SlcgB1Fv01y2kGe3Gc8nMW7VA0SrGuSkRfIEg==} - path-type@4.0.0: - resolution: {integrity: sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==} - engines: {node: '>=8'} + lodash.uniq@4.5.0: + resolution: {integrity: sha512-xfBaXQd9ryd9dlSDvnvI0lvxfLJlYAZzXomUYzLKtUeOQvOP5piqAWuGtrhWeqaXK9hhoM/iyJc5AV+XfsX3HQ==} - pathe@2.0.3: - resolution: {integrity: sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==} + lodash@4.17.21: + resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==} - pathval@1.1.1: - resolution: {integrity: sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ==} + log-symbols@4.1.0: + resolution: {integrity: sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==} + engines: {node: '>=10'} - pbkdf2@3.1.5: - resolution: {integrity: sha512-Q3CG/cYvCO1ye4QKkuH7EXxs3VC/rI1/trd+qX2+PolbaKG0H+bgcZzrTt96mMyRtejk+JMCiLUn3y29W8qmFQ==} - engines: {node: '>= 0.10'} + lokijs@1.5.12: + resolution: {integrity: sha512-Q5ALD6JiS6xAUWCwX3taQmgwxyveCtIIuL08+ml0nHwT3k0S/GIFJN+Hd38b1qYIMaE5X++iqsqWVksz7SYW+Q==} - performance-now@2.1.0: - resolution: {integrity: sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow==} + longest-streak@3.1.0: + resolution: {integrity: sha512-9Ri+o0JYgehTaVBBDoMqIl8GXtbWg711O3srftcHhZ0dqnETqLaoIK0x17fUw9rFSlK/0NlsKe0Ahhyl5pXE2g==} - picocolors@1.1.1: - resolution: {integrity: sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==} + loose-envify@1.4.0: + resolution: {integrity: sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==} + hasBin: true - picomatch@2.3.2: - resolution: {integrity: sha512-V7+vQEJ06Z+c5tSye8S+nHUfI51xoXIXjHQ99cQtKUkQqqO1kO/KCJUfZXuB47h/YBlDhah2H3hdUGXn8ie0oA==} - engines: {node: '>=8.6'} + loupe@3.1.3: + resolution: {integrity: sha512-kkIp7XSkP78ZxJEsSxW3712C6teJVoeHHwgo9zJ380de7IYyJ2ISlxojcH2pC5OFLewESmnRi/+XCDIEEVyoug==} - picomatch@4.0.3: - resolution: {integrity: sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==} - engines: {node: '>=12'} + lru-cache@10.2.2: + resolution: {integrity: sha512-9hp3Vp2/hFQUiIwKo8XCeFVnrg8Pk3TYNPIR7tJADKi5YfcF7vEaK7avFHTlSy3kOKYaJQaalfEo6YuXdceBOQ==} + engines: {node: 14 || >=16.14} - picomatch@4.0.4: - resolution: {integrity: sha512-QP88BAKvMam/3NxH6vj2o21R6MjxZUAd6nlwAS/pnGvN9IVLocLHxGYIzFhg6fUQ+5th6P4dv4eW9jX3DSIj7A==} - engines: {node: '>=12'} + lru-cache@10.4.3: + resolution: {integrity: sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==} - pify@2.3.0: - resolution: {integrity: sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog==} - engines: {node: '>=0.10.0'} + lru-cache@11.2.4: + resolution: {integrity: sha512-B5Y16Jr9LB9dHVkh6ZevG+vAbOsNOYCX+sXvFWFu7B3Iz5mijW3zdbMyhsh8ANd2mSWBYdJgnqi+mL7/LrOPYg==} + engines: {node: 20 || >=22} - pify@3.0.0: - resolution: {integrity: sha512-C3FsVNH1udSEX48gGX1xfvwTWfsYWj5U+8/uK15BGzIGrKoUpghX8hWZwa/OFnakBiiVNmBvemTJR5mcy7iPcg==} - engines: {node: '>=4'} + lru-cache@4.1.5: + resolution: {integrity: sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==} - pify@4.0.1: - resolution: {integrity: sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==} - engines: {node: '>=6'} + lru-cache@5.1.1: + resolution: {integrity: sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==} - pify@5.0.0: - resolution: {integrity: sha512-eW/gHNMlxdSP6dmG6uJip6FXN0EQBwm2clYYd8Wul42Cwu/DK8HEftzsapcNdYe2MfLiIwZqsDk2RDEsTE79hA==} + lru-cache@6.0.0: + resolution: {integrity: sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==} engines: {node: '>=10'} - pinkie-promise@2.0.1: - resolution: {integrity: sha512-0Gni6D4UcLTbv9c57DfxDGdr41XfgUjqWZu492f0cIGr16zDU06BWP/RAEvOuo7CQ0CNjHaLlM59YJJFm3NWlw==} - engines: {node: '>=0.10.0'} + lru_map@0.3.3: + resolution: {integrity: sha512-Pn9cox5CsMYngeDbmChANltQl+5pi6XmTrraMSzhPmMBbmgcxmqWry0U3PGapCU1yB4/LqCcom7qhHZiF/jGfQ==} - pinkie@2.0.4: - resolution: {integrity: sha512-MnUuEycAemtSaeFSjXKW/aroV7akBbY+Sv+RkyqFjgAe73F+MR0TBWKBRDkmfWq/HiFmdavfZ1G7h4SPZXaCSg==} - engines: {node: '>=0.10.0'} + lz-string@1.5.0: + resolution: {integrity: sha512-h5bgJWpxJNswbU7qCrV0tIKQCaS3blPDrqKWx+QxzuzL1zGUzij9XCWLrSLsJPu5t+eWA/ycetzYAO5IOMcWAQ==} + hasBin: true - pkg-dir@4.2.0: - resolution: {integrity: sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==} - engines: {node: '>=8'} + magic-regexp@0.10.0: + resolution: {integrity: sha512-Uly1Bu4lO1hwHUW0CQeSWuRtzCMNO00CmXtS8N6fyvB3B979GOEEeAkiTUDsmbYLAbvpUS/Kt5c4ibosAzVyVg==} - pkijs@3.3.3: - resolution: {integrity: sha512-+KD8hJtqQMYoTuL1bbGOqxb4z+nZkTAwVdNtWwe8Tc2xNbEmdJYIYoc6Qt0uF55e6YW6KuTHw1DjQ18gMhzepw==} - engines: {node: '>=16.0.0'} + magic-string-ast@1.0.3: + resolution: {integrity: sha512-CvkkH1i81zl7mmb94DsRiFeG9V2fR2JeuK8yDgS8oiZSFa++wWLEgZ5ufEOyLHbvSbD1gTRKv9NdX69Rnvr9JA==} + engines: {node: '>=20.19.0'} - pluralize@8.0.0: - resolution: {integrity: sha512-Nc3IT5yHzflTfbjgqWcCPpo7DaKy4FnpB0l/zCAW0Tc7jxAiuqSxHasntB3D7887LSrA93kDJ9IXovxJYxyLCA==} - engines: {node: '>=4'} + magic-string@0.30.10: + resolution: {integrity: sha512-iIRwTIf0QKV3UAnYK4PU8uiEc4SRh5jX0mwpIwETPpHdhVM4f53RSwS/vXvN1JhGX+Cs7B8qIq3d6AH49O5fAQ==} - portfinder@1.0.38: - resolution: {integrity: sha512-rEwq/ZHlJIKw++XtLAO8PPuOQA/zaPJOZJ37BVuN97nLpMJeuDVLVGRwbFoBgLudgdTMP2hdRJP++H+8QOA3vg==} - engines: {node: '>= 10.12'} + magic-string@0.30.12: + resolution: {integrity: sha512-Ea8I3sQMVXr8JhN4z+H/d8zwo+tYDgHE9+5G4Wnrwhs0gaK9fXTKx0Tw5Xwsd/bCPTTZNRAdpyzvoeORe9LYpw==} - possible-typed-array-names@1.1.0: - resolution: {integrity: sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg==} - engines: {node: '>= 0.4'} + magic-string@0.30.17: + resolution: {integrity: sha512-sNPKHvyjVf7gyjwS4xGTaW/mCnF8wnjtifKBEhxfZ7E/S8tQ0rssrwGNn6q8JH/ohItJfSQp9mBtQYuTlH5QnA==} - postcss@8.4.31: - resolution: {integrity: sha512-PS08Iboia9mts/2ygV3eLpY5ghnUcfLV/EXTOW1E2qYxJKGGBUtNjN76FYHnMs36RmARn41bC0AZmn+rR0OVpQ==} - engines: {node: ^10 || ^12 || >=14} + magic-string@0.30.21: + resolution: {integrity: sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ==} - postcss@8.5.10: - resolution: {integrity: sha512-pMMHxBOZKFU6HgAZ4eyGnwXF/EvPGGqUr0MnZ5+99485wwW41kW91A4LOGxSHhgugZmSChL5AlElNdwlNgcnLQ==} - engines: {node: ^10 || ^12 || >=14} + magicast@0.3.5: + resolution: {integrity: sha512-L0WhttDl+2BOsybvEOLK7fW3UA0OQ0IQ2d6Zl2x/a6vVRs3bAY0ECOSHHeL5jD+SbOpOCUEi0y1DgHEn9Qn1AQ==} - precond@0.2.3: - resolution: {integrity: sha512-QCYG84SgGyGzqJ/vlMsxeXd/pgL/I94ixdNFyh1PusWmTCyVfPJjZ1K1jvHtsbfnXQs2TSkEP2fR7QiMZAnKFQ==} - engines: {node: '>= 0.6'} + magicast@0.5.1: + resolution: {integrity: sha512-xrHS24IxaLrvuo613F719wvOIv9xPHFWQHuvGUBmPnCA/3MQxKI3b+r7n1jAoDHmsbC5bRhTZYR77invLAxVnw==} - prelude-ls@1.1.2: - resolution: {integrity: sha512-ESF23V4SKG6lVSGZgYNpbsiaAkdab6ZgOxe52p7+Kid3W3u3bxR4Vfd/o21dmN7jSt0IwgZ4v5MUd26FEtXE9w==} - engines: {node: '>= 0.8.0'} + make-dir@4.0.0: + resolution: {integrity: sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw==} + engines: {node: '>=10'} - prelude-ls@1.2.1: - resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} - engines: {node: '>= 0.8.0'} + make-error@1.3.6: + resolution: {integrity: sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==} - prettier-linter-helpers@1.0.1: - resolution: {integrity: sha512-SxToR7P8Y2lWmv/kTzVLC1t/GDI2WGjMwNhLLE9qtH8Q13C+aEmuRlzDst4Up4s0Wc8sF2M+J57iB3cMLqftfg==} - engines: {node: '>=6.0.0'} + mark.js@8.11.1: + resolution: {integrity: sha512-1I+1qpDt4idfgLQG+BNWmrqku+7/2bi5nLf4YwF8y8zXvmfiTBY3PV3ZibfrjBueCByROpuBjLLFCajqkgYoLQ==} - prettier@2.8.8: - resolution: {integrity: sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==} - engines: {node: '>=10.13.0'} - hasBin: true + markdown-table@3.0.3: + resolution: {integrity: sha512-Z1NL3Tb1M9wH4XESsCDEksWoKTdlUafKc4pt0GRwjUyXaCFZ+dc3g2erqB6zm3szA2IUSi7VnPI+o/9jnxh9hw==} - prettier@3.8.1: - resolution: {integrity: sha512-UOnG6LftzbdaHZcKoPFtOcCKztrQ57WkHDeRD9t/PTQtmT0NHSeWWepj6pS0z/N7+08BHFDQVUrfmfMRcZwbMg==} - engines: {node: '>=14'} + marked-terminal@7.1.0: + resolution: {integrity: sha512-+pvwa14KZL74MVXjYdPR3nSInhGhNvPce/3mqLVZT2oUvt654sL1XImFuLZ1pkA866IYZ3ikDTOFUIC7XzpZZg==} + engines: {node: '>=16.0.0'} + peerDependencies: + marked: '>=1 <14' + + marked@9.1.6: + resolution: {integrity: sha512-jcByLnIFkd5gSXZmjNvS1TlmRhCXZjIzHYlaGkPlLIekG55JDR2Z4va9tZwCiP+/RDERiNhMOFu01xd6O5ct1Q==} + engines: {node: '>= 16'} hasBin: true - proc-log@4.2.0: - resolution: {integrity: sha512-g8+OnU/L2v+wyiVK+D5fA34J7EH8jZ8DDlvwhRCMxmMj7UCBvxiO1mGeN+36JXIKF4zevU4kRBd8lVgG9vLelA==} - engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} + math-intrinsics@1.1.0: + resolution: {integrity: sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==} + engines: {node: '>= 0.4'} - process-nextick-args@2.0.1: - resolution: {integrity: sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==} + md5.js@1.3.5: + resolution: {integrity: sha512-xitP+WxNPcTTOgnTJcrhM0xvdPepipPSf3I8EIpGKeFLjt3PlJLIDG3u8EX53ZIubkb+5U2+3rELYpEhHhzdkg==} - process-on-spawn@1.1.0: - resolution: {integrity: sha512-JOnOPQ/8TZgjs1JIH/m9ni7FfimjNa/PRx7y/Wb5qdItsnhO0jE4AT7fC0HjC28DUQWDr50dwSYZLdRMlqDq3Q==} - engines: {node: '>=8'} + mdast-util-find-and-replace@3.0.1: + resolution: {integrity: sha512-SG21kZHGC3XRTSUhtofZkBzZTJNM5ecCi0SK2IMKmSXR8vO3peL+kb1O0z7Zl83jKtutG4k5Wv/W7V3/YHvzPA==} - process@0.11.10: - resolution: {integrity: sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A==} - engines: {node: '>= 0.6.0'} + mdast-util-from-markdown@2.0.2: + resolution: {integrity: sha512-uZhTV/8NBuw0WHkPTrCqDOl0zVe1BIng5ZtHoDk49ME1qqcjYmmLmOf0gELgcRMxN4w2iuIeVso5/6QymSrgmA==} - promise-retry@2.0.1: - resolution: {integrity: sha512-y+WKFlBR8BGXnsNlIHFGPZmyDf3DFMoLhaflAnyZgV6rG6xu+JwesTo2Q9R6XwYmtmwAFCkAk3e35jEdoeh/3g==} - engines: {node: '>=10'} + mdast-util-gfm-autolink-literal@2.0.0: + resolution: {integrity: sha512-FyzMsduZZHSc3i0Px3PQcBT4WJY/X/RCtEJKuybiC6sjPqLv7h1yqAkmILZtuxMSsUyaLUWNp71+vQH2zqp5cg==} - promise-to-callback@1.0.0: - resolution: {integrity: sha512-uhMIZmKM5ZteDMfLgJnoSq9GCwsNKrYau73Awf1jIy6/eUcuuZ3P+CD9zUv0kJsIUbU+x6uLNIhXhLHDs1pNPA==} - engines: {node: '>=0.10.0'} + mdast-util-gfm-footnote@2.0.0: + resolution: {integrity: sha512-5jOT2boTSVkMnQ7LTrd6n/18kqwjmuYqo7JUPe+tRCY6O7dAuTFMtTPauYYrMPpox9hlN0uOx/FL8XvEfG9/mQ==} - promise@8.3.0: - resolution: {integrity: sha512-rZPNPKTOYVNEEKFaq1HqTgOwZD+4/YHS5ukLzQCypkj+OkYx7iv0mA91lJlpPPZ8vMau3IIGj5Qlwrx+8iiSmg==} + mdast-util-gfm-strikethrough@2.0.0: + resolution: {integrity: sha512-mKKb915TF+OC5ptj5bJ7WFRPdYtuHv0yTRxK2tJvi+BDqbkiG7h7u/9SI89nRAYcmap2xHQL9D+QG/6wSrTtXg==} - prompts@2.4.2: - resolution: {integrity: sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==} - engines: {node: '>= 6'} + mdast-util-gfm-table@2.0.0: + resolution: {integrity: sha512-78UEvebzz/rJIxLvE7ZtDd/vIQ0RHv+3Mh5DR96p7cS7HsBhYIICDBCu8csTNWNO6tBWfqXPWekRuj2FNOGOZg==} - prop-types@15.8.1: - resolution: {integrity: sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==} + mdast-util-gfm-task-list-item@2.0.0: + resolution: {integrity: sha512-IrtvNvjxC1o06taBAVJznEnkiHxLFTzgonUdy8hzFVeDun0uTjxxrRGVaNFqkU1wJR3RBPEfsxmU6jDWPofrTQ==} - proper-lockfile@4.1.2: - resolution: {integrity: sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==} + mdast-util-gfm@3.0.0: + resolution: {integrity: sha512-dgQEX5Amaq+DuUqf26jJqSK9qgixgd6rYDHAv4aTBuA92cTknZlKpPfa86Z/s8Dj8xsAQpFfBmPUHWJBWqS4Bw==} - proxy-addr@2.0.7: - resolution: {integrity: sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==} - engines: {node: '>= 0.10'} + mdast-util-phrasing@4.1.0: + resolution: {integrity: sha512-TqICwyvJJpBwvGAMZjj4J2n0X8QWp21b9l0o7eXyVJ25YNWYbJDVIyD1bZXE6WtV6RmKJVYmQAKWa0zWOABz2w==} - proxy-agent@6.5.0: - resolution: {integrity: sha512-TmatMXdr2KlRiA2CyDu8GqR8EjahTG3aY3nXjdzFyoZbmB8hrBsTyMezhULIXKnC0jpfjlmiZ3+EaCzoInSu/A==} - engines: {node: '>= 14'} + mdast-util-to-hast@13.1.0: + resolution: {integrity: sha512-/e2l/6+OdGp/FB+ctrJ9Avz71AN/GRH3oi/3KAx/kMnoUsD6q0woXlDT8lLEeViVKE7oZxE7RXzvO3T8kF2/sA==} - proxy-from-env@1.1.0: - resolution: {integrity: sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg==} + mdast-util-to-hast@13.2.0: + resolution: {integrity: sha512-QGYKEuUsYT9ykKBCMOEDLsU5JRObWQusAolFMeko/tYPufNkRffBAQjIE+99jbA87xv6FgmjLtwjh9wBWajwAA==} - proxy-from-env@2.1.0: - resolution: {integrity: sha512-cJ+oHTW1VAEa8cJslgmUZrc+sjRKgAKl3Zyse6+PV38hZe/V6Z14TbCuXcan9F9ghlz4QrFr2c92TNF82UkYHA==} - engines: {node: '>=10'} + mdast-util-to-markdown@2.1.0: + resolution: {integrity: sha512-SR2VnIEdVNCJbP6y7kVTJgPLifdr8WEU440fQec7qHoHOUz/oJ2jmNRqdDQ3rbiStOXb2mCDGTuwsK5OPUgYlQ==} - prr@1.0.1: - resolution: {integrity: sha512-yPw4Sng1gWghHQWj0B3ZggWUm4qVbPwPFcRG8KyxiU7J2OHFSoEHKS+EZ3fv5l1t9CyCiop6l/ZYeWbrgoQejw==} + mdast-util-to-string@4.0.0: + resolution: {integrity: sha512-0H44vDimn51F0YwvxSJSm0eCDOJTRlmN0R1yBh4HLj9wiV1Dn0QoXGbvFAWj2hSItVTlCmBF1hqKlIyUBVFLPg==} - pstree.remy@1.1.8: - resolution: {integrity: sha512-77DZwxQmxKnu3aR542U+X8FypNzbfJ+C5XQDk3uWjWxn6151aIMGthWYRXTqT1E5oJvg+ljaa2OJi+VfvCOQ8w==} + mdn-data@2.0.28: + resolution: {integrity: sha512-aylIc7Z9y4yzHYAJNuESG3hfhC+0Ibp/MAMiaOZgNv4pmEdFyfZhhhny4MNiAfWdBQ1RQ2mfDWmM1x8SvGyp8g==} - pump@3.0.4: - resolution: {integrity: sha512-VS7sjc6KR7e1ukRFhQSY5LM2uBWAUPiOPa/A3mkKmiMwSmRFUITt0xuj+/lesgnCv+dPIEYlkzrcyXgquIHMcA==} + mdn-data@2.0.30: + resolution: {integrity: sha512-GaqWWShW4kv/G9IEucWScBx9G1/vsFZZJUO+tD26M8J8z3Kw5RDQjaoZe03YAClgeS/SWPOcb4nkFBTEi5DUEA==} - punycode@1.4.1: - resolution: {integrity: sha512-jmYNElW7yvO7TV33CjSmvSiE2yco3bV2czu/OzDKdMNVZQWfxCblURLhf+47syQRBntjfLdd/H0egrzIG+oaFQ==} + mdn-data@2.12.2: + resolution: {integrity: sha512-IEn+pegP1aManZuckezWCO+XZQDplx1366JoVhTpMpBB1sPey/SbveZQUosKiKiGYjg1wH4pMlNgXbCiYgihQA==} - punycode@2.1.0: - resolution: {integrity: sha512-Yxz2kRwT90aPiWEMHVYnEf4+rhwF1tBmmZ4KepCP+Wkium9JxtWnUm1nqGwpiAHr/tnTSeHqr3wb++jgSkXjhA==} - engines: {node: '>=6'} + memorystream@0.3.1: + resolution: {integrity: sha512-S3UwM3yj5mtUSEfP41UZmt/0SCoVYUcU1rkXv+BQ5Ig8ndL4sPoJNBUJERafdPb5jjHJGuMgytgKvKIf58XNBw==} + engines: {node: '>= 0.10.0'} - punycode@2.3.1: - resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==} - engines: {node: '>=6'} + merge-stream@2.0.0: + resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==} - pvtsutils@1.3.6: - resolution: {integrity: sha512-PLgQXQ6H2FWCaeRak8vvk1GW462lMxB5s3Jm673N82zI4vqtVUPuZdffdZbPDFRoU8kAhItWFtPCWiPpp4/EDg==} + merge2@1.4.1: + resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==} + engines: {node: '>= 8'} - pvutils@1.1.5: - resolution: {integrity: sha512-KTqnxsgGiQ6ZAzZCVlJH5eOjSnvlyEgx1m8bkRJfOhmGRqfo5KLvmAlACQkrjEtOQ4B7wF9TdSLIs9O90MX9xA==} - engines: {node: '>=16.0.0'} + micro-ftch@0.3.1: + resolution: {integrity: sha512-/0LLxhzP0tfiR5hcQebtudP56gUurs2CLkGarnCiB/OqEyUFQ6U3paQi/tgLv0hBJYt2rnr9MNpxz4fiiugstg==} - qs@6.14.2: - resolution: {integrity: sha512-V/yCWTTF7VJ9hIh18Ugr2zhJMP01MY7c5kh4J870L7imm6/DIzBsNLTXzMwUA3yZ5b/KBqLx8Kp3uRvd7xSe3Q==} - engines: {node: '>=0.6'} + micro@9.3.5-canary.3: + resolution: {integrity: sha512-viYIo9PefV+w9dvoIBh1gI44Mvx1BOk67B4BpC2QK77qdY0xZF0Q+vWLt/BII6cLkIc8rLmSIcJaB/OrXXKe1g==} + engines: {node: '>= 8.0.0'} + hasBin: true - qs@6.15.1: - resolution: {integrity: sha512-6YHEFRL9mfgcAvql/XhwTvf5jKcOiiupt2FiJxHkiX1z4j7WL8J/jRHYLluORvc1XxB5rV20KoeK00gVJamspg==} - engines: {node: '>=0.6'} + micromark-core-commonmark@2.0.1: + resolution: {integrity: sha512-CUQyKr1e///ZODyD1U3xit6zXwy1a8q2a1S1HKtIlmgvurrEpaw/Y9y6KSIbF8P59cn/NjzHyO+Q2fAyYLQrAA==} - quansync@0.2.11: - resolution: {integrity: sha512-AifT7QEbW9Nri4tAwR5M/uzpBuqfZf+zwaEM/QkzEjj7NBuFD2rBuy0K3dE+8wltbezDV7JMA0WfnCPYRSYbXA==} + micromark-factory-destination@2.0.0: + resolution: {integrity: sha512-j9DGrQLm/Uhl2tCzcbLhy5kXsgkHUrjJHg4fFAeoMRwJmJerT9aw4FEhIbZStWN8A3qMwOp1uzHr4UL8AInxtA==} - query-string@5.1.1: - resolution: {integrity: sha512-gjWOsm2SoGlgLEdAGt7a6slVOk9mGiXmPFMqrEhLQ68rhQuBnpfs3+EmlvqKyxnCo9/PPlF+9MtY02S1aFg+Jw==} - engines: {node: '>=0.10.0'} + micromark-factory-label@2.0.0: + resolution: {integrity: sha512-RR3i96ohZGde//4WSe/dJsxOX6vxIg9TimLAS3i4EhBAFx8Sm5SmqVfR8E87DPSR31nEAjZfbt91OMZWcNgdZw==} - queue-microtask@1.2.3: - resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==} + micromark-factory-space@2.0.0: + resolution: {integrity: sha512-TKr+LIDX2pkBJXFLzpyPyljzYK3MtmllMUMODTQJIUfDGncESaqB90db9IAUcz4AZAJFdd8U9zOp9ty1458rxg==} - quick-lru@5.1.1: - resolution: {integrity: sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA==} - engines: {node: '>=10'} + micromark-factory-title@2.0.0: + resolution: {integrity: sha512-jY8CSxmpWLOxS+t8W+FG3Xigc0RDQA9bKMY/EwILvsesiRniiVMejYTE4wumNc2f4UbAa4WsHqe3J1QS1sli+A==} - randombytes@2.1.0: - resolution: {integrity: sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==} + micromark-factory-whitespace@2.0.0: + resolution: {integrity: sha512-28kbwaBjc5yAI1XadbdPYHX/eDnqaUFVikLwrO7FDnKG7lpgxnvk/XGRhX/PN0mOZ+dBSZ+LgunHS+6tYQAzhA==} - range-parser@1.2.1: - resolution: {integrity: sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==} - engines: {node: '>= 0.6'} + micromark-util-character@2.1.0: + resolution: {integrity: sha512-KvOVV+X1yLBfs9dCBSopq/+G1PcgT3lAK07mC4BzXi5E7ahzMAF8oIupDDJ6mievI6F+lAATkbQQlQixJfT3aQ==} - raw-body@2.5.3: - resolution: {integrity: sha512-s4VSOf6yN0rvbRZGxs8Om5CWj6seneMwK3oDb4lWDH0UPhWcxwOWw5+qk24bxq87szX1ydrwylIOp2uG1ojUpA==} - engines: {node: '>= 0.8'} + micromark-util-chunked@2.0.0: + resolution: {integrity: sha512-anK8SWmNphkXdaKgz5hJvGa7l00qmcaUQoMYsBwDlSKFKjc6gjGXPDw3FNL3Nbwq5L8gE+RCbGqTw49FK5Qyvg==} - rc@1.2.8: - resolution: {integrity: sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==} - hasBin: true + micromark-util-classify-character@2.0.0: + resolution: {integrity: sha512-S0ze2R9GH+fu41FA7pbSqNWObo/kzwf8rN/+IGlW/4tC6oACOs8B++bh+i9bVyNnwCcuksbFwsBme5OCKXCwIw==} - react-dom@19.2.3: - resolution: {integrity: sha512-yELu4WmLPw5Mr/lmeEpox5rw3RETacE++JgHqQzd2dg+YbJuat3jH4ingc+WPZhxaoFzdv9y33G+F7Nl5O0GBg==} - peerDependencies: - react: ^19.2.3 + micromark-util-combine-extensions@2.0.0: + resolution: {integrity: sha512-vZZio48k7ON0fVS3CUgFatWHoKbbLTK/rT7pzpJ4Bjp5JjkZeasRfrS9wsBdDJK2cJLHMckXZdzPSSr1B8a4oQ==} - react-is@16.13.1: - resolution: {integrity: sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==} + micromark-util-decode-numeric-character-reference@2.0.1: + resolution: {integrity: sha512-bmkNc7z8Wn6kgjZmVHOX3SowGmVdhYS7yBpMnuMnPzDq/6xwVA604DuOXMZTO1lvq01g+Adfa0pE2UKGlxL1XQ==} - react-native-keychain@8.2.0: - resolution: {integrity: sha512-SkRtd9McIl1Ss2XSWNLorG+KMEbgeVqX+gV+t3u1EAAqT8q2/OpRmRbxpneT2vnb/dMhiU7g6K/pf3nxLUXRvA==} + micromark-util-decode-string@2.0.0: + resolution: {integrity: sha512-r4Sc6leeUTn3P6gk20aFMj2ntPwn6qpDZqWvYmAG6NgvFTIlj4WtrAudLi65qYoaGdXYViXYw2pkmn7QnIFasA==} - react@19.2.3: - resolution: {integrity: sha512-Ku/hhYbVjOQnXDZFv2+RibmLFGwFdeeKHFcOTlrt7xplBnya5OGn/hIRDsqDiSUcfORsDC7MPxwork8jBwsIWA==} - engines: {node: '>=0.10.0'} + micromark-util-encode@2.0.0: + resolution: {integrity: sha512-pS+ROfCXAGLWCOc8egcBvT0kf27GoWMqtdarNfDcjb6YLuV5cM3ioG45Ys2qOVqeqSbjaKg72vU+Wby3eddPsA==} - read-pkg-up@1.0.1: - resolution: {integrity: sha512-WD9MTlNtI55IwYUS27iHh9tK3YoIVhxis8yKhLpTqWtml739uXc9NWTpxoHkfZf3+DkCCsXox94/VWZniuZm6A==} - engines: {node: '>=0.10.0'} + micromark-util-html-tag-name@2.0.0: + resolution: {integrity: sha512-xNn4Pqkj2puRhKdKTm8t1YHC/BAjx6CEwRFXntTaRf/x16aqka6ouVoutm+QdkISTlT7e2zU7U4ZdlDLJd2Mcw==} - read-pkg@1.1.0: - resolution: {integrity: sha512-7BGwRHqt4s/uVbuyoeejRn4YmFnYZiFl4AuaeXHlgZf3sONF0SOGlxs2Pw8g6hCKupo08RafIO5YXFNOKTfwsQ==} - engines: {node: '>=0.10.0'} + micromark-util-normalize-identifier@2.0.0: + resolution: {integrity: sha512-2xhYT0sfo85FMrUPtHcPo2rrp1lwbDEEzpx7jiH2xXJLqBuy4H0GgXk5ToU8IEwoROtXuL8ND0ttVa4rNqYK3w==} - read-tls-client-hello@1.1.0: - resolution: {integrity: sha512-htV8ph2jXGCVnKRwW12V1UQdfwC2jPFrDrk8Qh9P+4R/t/Jef/BNmfdX5jsxlcakUMPskwiPZT/enVbjRQqtGQ==} - engines: {node: '>=12.0.0'} + micromark-util-resolve-all@2.0.0: + resolution: {integrity: sha512-6KU6qO7DZ7GJkaCgwBNtplXCvGkJToU86ybBAUdavvgsCiG8lSSvYxr9MhwmQ+udpzywHsl4RpGJsYWG1pDOcA==} - read-yaml-file@1.1.0: - resolution: {integrity: sha512-VIMnQi/Z4HT2Fxuwg5KrY174U1VdUIASQVWXXyqtNRtxSr9IYkn1rsI6Tb6HsrHCmB7gVpNwX6JxPTHcH6IoTA==} - engines: {node: '>=6'} + micromark-util-sanitize-uri@2.0.0: + resolution: {integrity: sha512-WhYv5UEcZrbAtlsnPuChHUAsu/iBPOVaEVsntLBIdpibO0ddy8OzavZz3iL2xVvBZOpolujSliP65Kq0/7KIYw==} - readable-stream@1.0.34: - resolution: {integrity: sha512-ok1qVCJuRkNmvebYikljxJA/UEsKwLl2nI1OmaqAu4/UE+h0wKCHok4XkL/gvi39OacXvw59RJUOFUkDib2rHg==} + micromark-util-subtokenize@2.0.1: + resolution: {integrity: sha512-jZNtiFl/1aY73yS3UGQkutD0UbhTt68qnRpw2Pifmz5wV9h8gOVsN70v+Lq/f1rKaU/W8pxRe8y8Q9FX1AOe1Q==} - readable-stream@1.1.14: - resolution: {integrity: sha512-+MeVjFf4L44XUkhM1eYbD8fyEsxcV81pqMSR5gblfcLCHfZvbrqy4/qYHE+/R5HoBUT11WV5O08Cr1n3YXkWVQ==} + micromark-util-symbol@2.0.0: + resolution: {integrity: sha512-8JZt9ElZ5kyTnO94muPxIGS8oyElRJaiJO8EzV6ZSyGQ1Is8xwl4Q45qU5UOg+bGH4AikWziz0iN4sFLWs8PGw==} - readable-stream@2.3.8: - resolution: {integrity: sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==} + micromark-util-types@2.0.0: + resolution: {integrity: sha512-oNh6S2WMHWRZrmutsRmDDfkzKtxF+bc2VxLC9dvtrDIRFln627VsFP6fLMgTryGDljgLPjkrzQSDcPrjPyDJ5w==} - readable-stream@3.6.2: - resolution: {integrity: sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==} - engines: {node: '>= 6'} + micromark@4.0.0: + resolution: {integrity: sha512-o/sd0nMof8kYff+TqcDx3VSrgBTcZpSvYcAHIfHhv5VAuNmisCxjhx6YmxS8PFEpb9z5WKWKPdzf0jM23ro3RQ==} - readdirp@3.6.0: - resolution: {integrity: sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==} - engines: {node: '>=8.10.0'} + micromatch@4.0.5: + resolution: {integrity: sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==} + engines: {node: '>=8.6'} - readdirp@4.1.2: - resolution: {integrity: sha512-GDhwkLfywWL2s6vEjyhri+eXmfH6j1L7JE27WhqLeYzoh/A3DBaYGEj2H/HFZCn/kMfim73FXxEJTw06WtxQwg==} - engines: {node: '>= 14.18.0'} + micromatch@4.0.8: + resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==} + engines: {node: '>=8.6'} + + mime-db@1.52.0: + resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} + engines: {node: '>= 0.6'} - realistic-structured-clone@3.0.0: - resolution: {integrity: sha512-rOjh4nuWkAqf9PWu6JVpOWD4ndI+JHfgiZeMmujYcPi+fvILUu7g6l26TC1K5aBIp34nV+jE1cDO75EKOfHC5Q==} - deprecated: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info. + mime-db@1.54.0: + resolution: {integrity: sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ==} + engines: {node: '>= 0.6'} - rechoir@0.6.2: - resolution: {integrity: sha512-HFM8rkZ+i3zrV+4LQjwQ0W+ez98pApMGM3HUrN04j3CqzPOzl9nmP15Y8YXNm8QHGv/eacOVEjqhmWpkRV0NAw==} - engines: {node: '>= 0.10'} + mime-types@2.1.35: + resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} + engines: {node: '>= 0.6'} - recursive-readdir@2.2.3: - resolution: {integrity: sha512-8HrF5ZsXk5FAH9dgsx3BlUer73nIhuj+9OrQwEbLTPOBzGkL1lsFCR01am+v+0m2Cmbs1nP12hLDl5FA7EszKA==} - engines: {node: '>=6.0.0'} + mime-types@3.0.2: + resolution: {integrity: sha512-Lbgzdk0h4juoQ9fCKXW4by0UJqj+nOOrI9MJ1sSj4nI8aI2eo1qmvQEie4VD1glsS250n15LsWsYtCugiStS5A==} + engines: {node: '>=18'} - reduce-flatten@2.0.0: - resolution: {integrity: sha512-EJ4UNY/U1t2P/2k6oqotuX2Cc3T6nxJwsM0N0asT7dhrtH1ltUxDn4NalSYmPE2rCkVpcf/X6R0wDwcFpzhd4w==} + mime@3.0.0: + resolution: {integrity: sha512-jSCU7/VB1loIWBZe14aEYHU/+1UMEHoaO7qxCOVJOw9GgH72VAWppxNcjU+x9a2k3GSIBXNKxXQFqRvvZ7vr3A==} + engines: {node: '>=10.0.0'} + hasBin: true + + mime@4.1.0: + resolution: {integrity: sha512-X5ju04+cAzsojXKes0B/S4tcYtFAJ6tTMuSPBEn9CPGlrWr8Fiw7qYeLT0XyH80HSoAoqWCaz+MWKh22P7G1cw==} + engines: {node: '>=16'} + hasBin: true + + mimic-fn@2.1.0: + resolution: {integrity: sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==} engines: {node: '>=6'} - reflect.getprototypeof@1.0.10: - resolution: {integrity: sha512-00o4I+DVrefhv+nX0ulyi3biSHCPDe+yLv5o/p6d/UVlirijB8E16FtfwSAi4g3tcqrQ4lRAqQSoFEZJehYEcw==} - engines: {node: '>= 0.4'} + mimic-fn@4.0.0: + resolution: {integrity: sha512-vqiC06CuhBTUdZH+RYl8sFrL096vA45Ok5ISO6sE/Mr1jRbGH4Csnhi8f3wKVl7x8mO4Au7Ir9D3Oyv1VYMFJw==} + engines: {node: '>=12'} - regexp.prototype.flags@1.5.4: - resolution: {integrity: sha512-dYqgNSZbDwkaJ2ceRd9ojCGjBq+mOm9LmtXnAnEGyHhN/5R7iDW2TRw3h+o/jCFxus3P2LfWIIiwowAjANm7IA==} - engines: {node: '>= 0.4'} + minimalistic-assert@1.0.1: + resolution: {integrity: sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==} - registry-auth-token@3.3.2: - resolution: {integrity: sha512-JL39c60XlzCVgNrO+qq68FoNb56w/m7JYvGR2jT5iR1xBrUA3Mfx5Twk5rqTThPmQKMWydGmq8oFtDlxfrmxnQ==} + minimalistic-crypto-utils@1.0.1: + resolution: {integrity: sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==} - registry-url@3.1.0: - resolution: {integrity: sha512-ZbgR5aZEdf4UKZVBPYIgaglBmSF2Hi94s2PcIHhRGFjKYu+chjJdYfHn4rt3hB6eCKLJ8giVIIfgMa1ehDfZKA==} - engines: {node: '>=0.10.0'} + minimatch@10.1.1: + resolution: {integrity: sha512-enIvLvRAFZYXJzkCYG5RKmPfrFArdLv+R+lbQ53BmIMLIry74bjKzX6iHAm8WYamJkhSSEabrWN5D97XnKObjQ==} + engines: {node: 20 || >=22} - release-zalgo@1.0.0: - resolution: {integrity: sha512-gUAyHVHPPC5wdqX/LG4LWtRYtgjxyX78oanFNTMMyFEfOqdC54s3eE82imuWKbOeqYht2CrNf64Qb8vgmmtZGA==} - engines: {node: '>=4'} + minimatch@3.1.2: + resolution: {integrity: sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==} - req-cwd@2.0.0: - resolution: {integrity: sha512-ueoIoLo1OfB6b05COxAA9UpeoscNpYyM+BqYlA7H6LVF4hKGPXQQSSaD2YmvDVJMkk4UDpAHIeU1zG53IqjvlQ==} - engines: {node: '>=4'} + minimatch@5.0.1: + resolution: {integrity: sha512-nLDxIFRyhDblz3qMuq+SoRZED4+miJ/G+tdDrjkkkRnjAsBexeGpgjLEQ0blJy7rHhR2b93rhQY4SvyWu9v03g==} + engines: {node: '>=10'} - req-from@2.0.0: - resolution: {integrity: sha512-LzTfEVDVQHBRfjOUMgNBA+V6DWsSnoeKzf42J7l0xa/B4jyPOuuF5MlNSmomLNGemWTnV2TIdjSSLnEn95fOQA==} - engines: {node: '>=4'} + minimatch@5.1.6: + resolution: {integrity: sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g==} + engines: {node: '>=10'} - request@2.88.2: - resolution: {integrity: sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw==} - engines: {node: '>= 6'} - deprecated: request has been deprecated, see https://github.com/request/request/issues/3142 + minimatch@9.0.1: + resolution: {integrity: sha512-0jWhJpD/MdhPXwPuiRkCbfYfSKp2qnn2eOc279qI7f+osl/l+prKSrvhg157zSYvx/1nmgn2NqdT6k2Z7zSH9w==} + engines: {node: '>=16 || 14 >=14.17'} - require-directory@2.1.1: - resolution: {integrity: sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==} - engines: {node: '>=0.10.0'} + minimatch@9.0.4: + resolution: {integrity: sha512-KqWh+VchfxcMNRAJjj2tnsSJdNbHsVgnkBhTNrW7AjVo6OvLtxw8zfT9oLw1JSohlFzJ8jCoTgaoXvJ+kHt6fw==} + engines: {node: '>=16 || 14 >=14.17'} - require-from-string@1.2.1: - resolution: {integrity: sha512-H7AkJWMobeskkttHyhTVtS0fxpFLjxhbfMa6Bk3wimP7sdPRGL3EyCg3sAQenFfAe+xQ+oAc85Nmtvq0ROM83Q==} - engines: {node: '>=0.10.0'} + minimatch@9.0.5: + resolution: {integrity: sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==} + engines: {node: '>=16 || 14 >=14.17'} - require-from-string@2.0.2: - resolution: {integrity: sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==} - engines: {node: '>=0.10.0'} + minimist@1.2.8: + resolution: {integrity: sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==} - require-main-filename@1.0.1: - resolution: {integrity: sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug==} + minipass@3.3.6: + resolution: {integrity: sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==} + engines: {node: '>=8'} - require-main-filename@2.0.0: - resolution: {integrity: sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==} + minipass@5.0.0: + resolution: {integrity: sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ==} + engines: {node: '>=8'} - resolve-alpn@1.2.1: - resolution: {integrity: sha512-0a1F4l73/ZFZOakJnQ3FvkJ2+gSTQWz/r2KE5OdDY0TxPm5h4GkqkWWfM47T7HsbnOtcJVEF4epCVy6u7Q3K+g==} + minipass@7.1.2: + resolution: {integrity: sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==} + engines: {node: '>=16 || 14 >=14.17'} - resolve-from@3.0.0: - resolution: {integrity: sha512-GnlH6vxLymXJNMBo7XP1fJIzBFbdYt49CuTwmB/6N53t+kMPRMFKz783LlQ4tv28XoQfMWinAJX6WCGf2IlaIw==} - engines: {node: '>=4'} + minisearch@7.1.0: + resolution: {integrity: sha512-tv7c/uefWdEhcu6hvrfTihflgeEi2tN6VV7HJnCjK6VxM75QQJh4t9FwJCsA2EsRS8LCnu3W87CuGPWMocOLCA==} - resolve-from@4.0.0: - resolution: {integrity: sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==} - engines: {node: '>=4'} + minizlib@2.1.2: + resolution: {integrity: sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==} + engines: {node: '>= 8'} - resolve-from@5.0.0: - resolution: {integrity: sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==} - engines: {node: '>=8'} + minizlib@3.0.1: + resolution: {integrity: sha512-umcy022ILvb5/3Djuu8LWeqUa8D68JaBzlttKeMWen48SjabqS3iY5w/vzeMzMUNhLDifyhbOwKDSznB1vvrwg==} + engines: {node: '>= 18'} - resolve@1.1.7: - resolution: {integrity: sha512-9znBF0vBcaSN3W2j7wKvdERPwqTxSpCq+if5C0WoTCyV9n24rua28jeuQ2pL/HOf+yUe/Mef+H/5p60K0Id3bg==} + minizlib@3.1.0: + resolution: {integrity: sha512-KZxYo1BUkWD2TVFLr0MQoM8vUUigWD3LlD83a/75BqC+4qE0Hb1Vo5v1FgcfaNXvfXzr+5EhQ6ing/CaBijTlw==} + engines: {node: '>= 18'} - resolve@1.17.0: - resolution: {integrity: sha512-ic+7JYiV8Vi2yzQGFWOkiZD5Z9z7O2Zhm9XMaTxdJExKasieFCr+yXZ/WmXsckHiKl12ar0y6XiXDx3m4RHn1w==} + mipd@0.0.7: + resolution: {integrity: sha512-aAPZPNDQ3uMTdKbuO2YmAw2TxLHO0moa4YKAyETM/DTj5FloZo+a+8tU+iv4GmW+sOxKLSRwcSFuczk+Cpt6fg==} + peerDependencies: + typescript: '>=5.0.4' + peerDependenciesMeta: + typescript: + optional: true - resolve@1.22.12: - resolution: {integrity: sha512-TyeJ1zif53BPfHootBGwPRYT1RUt6oGWsaQr8UyZW/eAm9bKoijtvruSDEmZHm92CwS9nj7/fWttqPCgzep8CA==} - engines: {node: '>= 0.4'} - hasBin: true + mitt@3.0.1: + resolution: {integrity: sha512-vKivATfr97l2/QBCYAkXYDbrIWPM2IIKEl7YPhjCvKlG3kE2gm+uBo6nEXK3M5/Ffh/FLpKExzOQ3JJoJGFKBw==} - resolve@2.0.0-next.5: - resolution: {integrity: sha512-U7WjGVG9sH8tvjW5SmGbQuui75FiyjAX72HX15DwBBwF9dNiQZRQAg9nnPhYy+TUnE0+VcrttuvNI8oSxZcocA==} + mkdirp@1.0.4: + resolution: {integrity: sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==} + engines: {node: '>=10'} hasBin: true - resolve@2.0.0-next.6: - resolution: {integrity: sha512-3JmVl5hMGtJ3kMmB3zi3DL25KfkCEyy3Tw7Gmw7z5w8M9WlwoPFnIvwChzu1+cF3iaK3sp18hhPz8ANeimdJfA==} - engines: {node: '>= 0.4'} + mkdirp@3.0.1: + resolution: {integrity: sha512-+NsyUUAZDmo6YVHzL/stxSu3t9YS1iljliy3BSDrXJ/dkn1KYdmtZODGGjLcc9XLgVVpH4KshHB8XmZgMhaBXg==} + engines: {node: '>=10'} hasBin: true - responselike@2.0.1: - resolution: {integrity: sha512-4gl03wn3hj1HP3yzgdI7d3lCkF95F21Pz4BPGvKHinyQzALR5CapwC8yIi0Rh58DEMQ/SguC03wFj2k0M/mHhw==} + mlly@1.7.0: + resolution: {integrity: sha512-U9SDaXGEREBYQgfejV97coK0UL1r+qnF2SyO9A3qcI8MzKnsIFKHNVEkrDyNncQTKQQumsasmeq84eNMdBfsNQ==} - restore-cursor@3.1.0: - resolution: {integrity: sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA==} - engines: {node: '>=8'} + mlly@1.8.0: + resolution: {integrity: sha512-l8D9ODSRWLe2KHJSifWGwBqpTZXIXTeo8mlKjY+E2HAakaTeNpqAyBZ8GSqLzHgw4XmHmC8whvpjJNMbFZN7/g==} - retry@0.12.0: - resolution: {integrity: sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==} - engines: {node: '>= 4'} + mnemonist@0.38.5: + resolution: {integrity: sha512-bZTFT5rrPKtPJxj8KSV0WkPyNxl72vQepqqVUAW2ARUpUSF2qXMB6jZj7hW5/k7C1rtpzqbD/IIbJwLXUjCHeg==} - retry@0.13.1: - resolution: {integrity: sha512-XQBQ3I8W1Cge0Seh+6gjj03LbmRFWuoszgK9ooCpwYIrhhoO80pfq4cUkU5DkknwfOfFteRwlZ56PYOGYyFWdg==} - engines: {node: '>= 4'} + mocha@10.2.0: + resolution: {integrity: sha512-IDY7fl/BecMwFHzoqF2sg/SHHANeBoMMXFlS9r0OXKDssYE1M5O43wUY/9BVPeIvfH2zmEbBfseqN9gBQZzXkg==} + engines: {node: '>= 14.0.0'} + hasBin: true - reusify@1.1.0: - resolution: {integrity: sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==} - engines: {iojs: '>=1.0.0', node: '>=0.10.0'} + mocked-exports@0.1.1: + resolution: {integrity: sha512-aF7yRQr/Q0O2/4pIXm6PZ5G+jAd7QS4Yu8m+WEeEHGnbo+7mE36CbLSDQiXYV8bVL3NfmdeqPJct0tUlnjVSnA==} - rfdc@1.4.1: - resolution: {integrity: sha512-q1b3N5QkRUWUl7iyylaaj3kOpIT0N2i9MqIEQXP73GVsN9cw3fdx8X63cEmWhJGi2PPCF23Ijp7ktmd39rawIA==} + motion-dom@12.23.23: + resolution: {integrity: sha512-n5yolOs0TQQBRUFImrRfs/+6X4p3Q4n1dUEqt/H58Vx7OW6RF+foWEgmTVDhIWJIMXOuNNL0apKH2S16en9eiA==} - rimraf@2.7.1: - resolution: {integrity: sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==} - deprecated: Rimraf versions prior to v4 are no longer supported - hasBin: true + motion-utils@12.23.6: + resolution: {integrity: sha512-eAWoPgr4eFEOFfg2WjIsMoqJTW6Z8MTUCgn/GZ3VRpClWBdnbjryiA3ZSNLyxCTmCQx4RmYX6jX1iWHbenUPNQ==} - rimraf@3.0.2: - resolution: {integrity: sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==} - deprecated: Rimraf versions prior to v4 are no longer supported - hasBin: true + motion@12.23.26: + resolution: {integrity: sha512-Ll8XhVxY8LXMVYTCfme27WH2GjBrCIzY4+ndr5QKxsK+YwCtOi2B/oBi5jcIbik5doXuWT/4KKDOVAZJkeY5VQ==} + peerDependencies: + '@emotion/is-prop-valid': '*' + react: ^18.0.0 || ^19.0.0 + react-dom: ^18.0.0 || ^19.0.0 + peerDependenciesMeta: + '@emotion/is-prop-valid': + optional: true + react: + optional: true + react-dom: + optional: true - rimraf@6.1.3: - resolution: {integrity: sha512-LKg+Cr2ZF61fkcaK1UdkH2yEBBKnYjTyWzTJT6KNPcSPaiT7HSdhtMXQuN5wkTX0Xu72KQ1l8S42rlmexS2hSA==} - engines: {node: 20 || >=22} - hasBin: true + mri@1.2.0: + resolution: {integrity: sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA==} + engines: {node: '>=4'} - ripemd160@2.0.3: - resolution: {integrity: sha512-5Di9UC0+8h1L6ZD2d7awM7E/T4uA1fJRlx6zk/NvdCCVEoAnFqvHmCuNeIKoCeIixBX/q8uM+6ycDvF8woqosA==} - engines: {node: '>= 0.8'} + mrmime@2.0.1: + resolution: {integrity: sha512-Y3wQdFg2Va6etvQ5I82yUhGdsKrcYox6p7FfL1LbK2J4V01F9TGlepTIhnK24t7koZibmg82KGglhA1XK5IsLQ==} + engines: {node: '>=10'} - rlp@2.2.6: - resolution: {integrity: sha512-HAfAmL6SDYNWPUOJNrM500x4Thn4PZsEy5pijPh40U9WfNk0z15hUYzO9xVIMAdIHdFtD8CBDHd75Td1g36Mjg==} - hasBin: true + ms@2.1.1: + resolution: {integrity: sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==} - rlp@2.2.7: - resolution: {integrity: sha512-d5gdPmgQ0Z+AklL2NVXr/IoSjNZFfTVvQWzL/AM2AOcSzYP2xjlb0AC8YyCLc41MSNf6P6QVtjgPdmVtzb+4lQ==} - hasBin: true + ms@2.1.2: + resolution: {integrity: sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==} - rollup@4.60.2: - resolution: {integrity: sha512-J9qZyW++QK/09NyN/zeO0dG/1GdGfyp9lV8ajHnRVLfo/uFsbji5mHnDgn/qYdUHyCkM2N+8VyspgZclfAh0eQ==} - engines: {node: '>=18.0.0', npm: '>=8.0.0'} + ms@2.1.3: + resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} + + msw@2.4.9: + resolution: {integrity: sha512-1m8xccT6ipN4PTqLinPwmzhxQREuxaEJYdx4nIbggxP8aM7r1e71vE7RtOUSQoAm1LydjGfZKy7370XD/tsuYg==} + engines: {node: '>=18'} hasBin: true + peerDependencies: + typescript: '>= 4.8.x' + peerDependenciesMeta: + typescript: + optional: true - run-async@2.4.1: - resolution: {integrity: sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ==} - engines: {node: '>=0.12.0'} + muggle-string@0.4.1: + resolution: {integrity: sha512-VNTrAak/KhO2i8dqqnqnAHOa3cYBwXEZe9h+D5h/1ZqFSTEFHdM65lR7RoIqq3tBBYavsOXV84NoHXZ0AkPyqQ==} - run-parallel@1.2.0: - resolution: {integrity: sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==} + multiformats@9.9.0: + resolution: {integrity: sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg==} - rustbn.js@0.2.0: - resolution: {integrity: sha512-4VlvkRUuCJvr2J6Y0ImW7NvTCriMi7ErOAqWk1y69vAdoNIzCF3yPmgeNzx+RQTLEDFq5sHfscn1MwHxP9hNfA==} + mute-stream@1.0.0: + resolution: {integrity: sha512-avsJQhyd+680gKXyG/sQc0nXaC6rBkPOfyHYcFb9+hdkqQkR9bdnkJ0AMZhke0oesPqIO+mFFJ+IdBc7mst4IA==} + engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} - rxjs@6.6.7: - resolution: {integrity: sha512-hTdwr+7yYNIT5n4AMYp85KA6yw2Va0FLa3Rguvbpa4W3I5xynaBZo41cM3XM+4Q6fRMj3sBYIR1VAmZMXYJvRQ==} - engines: {npm: '>=2.0.0'} + mz@2.7.0: + resolution: {integrity: sha512-z81GNO7nnYMEhrGh9LeymoE4+Yr0Wn5McHIZMK5cfQCl+NDX08sCZgUc9/6MHni9IWuFLm1Z3HTCXu2z9fN62Q==} - rxjs@7.8.2: - resolution: {integrity: sha512-dhKf903U/PQZY6boNNtAGdWbG85WAbjT/1xYoZIC7FAY0yWapOBQVsVrDl58W86//e1VpMNBtRV4MaXfdMySFA==} + nanoid@3.3.11: + resolution: {integrity: sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==} + engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} + hasBin: true - safe-array-concat@1.1.3: - resolution: {integrity: sha512-AURm5f0jYEOydBj7VQlVvDrjeFgthDdEF5H1dP+6mNpoXOMo1quQqJ4wvJDyRZ9+pO3kGWoOdmV08cSv2aJV6Q==} - engines: {node: '>=0.4'} + nanoid@3.3.3: + resolution: {integrity: sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w==} + engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} + hasBin: true - safe-array-concat@1.1.4: - resolution: {integrity: sha512-wtZlHyOje6OZTGqAoaDKxFkgRtkF9CnHAVnCHKfuj200wAgL+bSJhdsCD2l0Qx/2ekEXjPWcyKkfGb5CPboslg==} - engines: {node: '>=0.4'} + nanoid@3.3.7: + resolution: {integrity: sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==} + engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} + hasBin: true - safe-buffer@5.1.2: - resolution: {integrity: sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==} + nanoid@5.1.6: + resolution: {integrity: sha512-c7+7RQ+dMB5dPwwCp4ee1/iV/q2P6aK1mTZcfr1BTuVlyW9hJYiMPybJCcnBlQtuSmTIWNeazm/zqNoZSSElBg==} + engines: {node: ^18 || >=20} + hasBin: true - safe-buffer@5.2.1: - resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} + nanospinner@1.2.2: + resolution: {integrity: sha512-Zt/AmG6qRU3e+WnzGGLuMCEAO/dAu45stNbHY223tUxldaDAeE+FxSPsd9Q+j+paejmm0ZbrNVs5Sraqy3dRxA==} - safe-event-emitter@1.0.1: - resolution: {integrity: sha512-e1wFe99A91XYYxoQbcq2ZJUWurxEyP8vfz7A7vuUe1s95q8r5ebraVaA1BukYJcpM6V16ugWoD9vngi8Ccu5fg==} - deprecated: Renamed to @metamask/safe-event-emitter + nanotar@0.2.0: + resolution: {integrity: sha512-9ca1h0Xjvo9bEkE4UOxgAzLV0jHKe6LMaxo37ND2DAhhAtd0j8pR1Wxz+/goMrZO8AEZTWCmyaOsFI/W5AdpCQ==} - safe-push-apply@1.0.0: - resolution: {integrity: sha512-iKE9w/Z7xCzUMIZqdBsp6pEQvwuEebH4vdpjcDWnyzaI6yl6O9FHvVpmGelvEHNsoY6wGblkxR6Zty/h00WiSA==} - engines: {node: '>= 0.4'} + next@15.4.10: + resolution: {integrity: sha512-itVlc79QjpKMFMRhP+kbGKaSG/gZM6RCvwhEbwmCNF06CdDiNaoHcbeg0PqkEa2GOcn8KJ0nnc7+yL7EjoYLHQ==} + engines: {node: ^18.18.0 || ^19.8.0 || >= 20.0.0} + hasBin: true + peerDependencies: + '@opentelemetry/api': ^1.1.0 + '@playwright/test': ^1.51.1 + babel-plugin-react-compiler: '*' + react: ^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0 + react-dom: ^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0 + sass: ^1.3.0 + peerDependenciesMeta: + '@opentelemetry/api': + optional: true + '@playwright/test': + optional: true + babel-plugin-react-compiler: + optional: true + sass: + optional: true - safe-regex-test@1.1.0: - resolution: {integrity: sha512-x/+Cz4YrimQxQccJf5mKEbIa1NzeCRNI5Ecl/ekmlYaampdNLPalVyIcCZNNH3MvmqBugV5TMYZXv0ljslUlaw==} - engines: {node: '>= 0.4'} + nitropack@2.12.9: + resolution: {integrity: sha512-t6qqNBn2UDGMWogQuORjbL2UPevB8PvIPsPHmqvWpeGOlPr4P8Oc5oA8t3wFwGmaolM2M/s2SwT23nx9yARmOg==} + engines: {node: ^20.19.0 || >=22.12.0} + hasBin: true + peerDependencies: + xml2js: ^0.6.2 + peerDependenciesMeta: + xml2js: + optional: true - safer-buffer@2.1.2: - resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} + node-addon-api@2.0.2: + resolution: {integrity: sha512-Ntyt4AIXyaLIuMHF6IOoTakB3K+RWxwtsHNRxllEoA6vPwP9o4866g6YWDLUdnucilZhmkxiHwHr11gAENw+QA==} - sc-istanbul@0.4.6: - resolution: {integrity: sha512-qJFF/8tW/zJsbyfh/iT/ZM5QNHE3CXxtLJbZsL+CzdJLBsPD7SedJZoUA4d8iAcN2IoMp/Dx80shOOd2x96X/g==} - hasBin: true + node-addon-api@7.1.1: + resolution: {integrity: sha512-5m3bsyrjFWE1xf7nz7YXdN4udnVtXK6/Yfgn5qnahL6bCkf2yKt4k3nuTKAtT4r3IG8JNR2ncsIMdZuAzJjHQQ==} + + node-emoji@2.1.3: + resolution: {integrity: sha512-E2WEOVsgs7O16zsURJ/eH8BqhF029wGpEOnv7Urwdo2wmQanOACwJQh0devF9D9RhoZru0+9JXIS0dBXIAz+lA==} + engines: {node: '>=18'} - scheduler@0.27.0: - resolution: {integrity: sha512-eNv+WrVbKu1f3vbYJT/xtiF5syA5HPIMtf9IgY/nKg0sWqzAUEvqY/xm7OcZc/qafLx/iO9FgOmeSAp4v5ti/Q==} + node-fetch-native@1.6.4: + resolution: {integrity: sha512-IhOigYzAKHd244OC0JIMIUrjzctirCmPkaIfhDeGcEETWof5zKYUW7e7MYvChGWh/4CJeXEgsRyGzuF334rOOQ==} - scrypt-js@3.0.1: - resolution: {integrity: sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==} + node-fetch-native@1.6.7: + resolution: {integrity: sha512-g9yhqoedzIUm0nTnTqAQvueMPVOuIY16bqgAJJC8XOOubYFNwz6IER9qs0Gq2Xd0+CecCKFjtdDTMA4u4xG06Q==} - scrypt@https://codeload.github.com/barrysteyn/node-scrypt/tar.gz/fb60a8d3c158fe115a624b5ffa7480f3a24b03fb: - resolution: {tarball: https://codeload.github.com/barrysteyn/node-scrypt/tar.gz/fb60a8d3c158fe115a624b5ffa7480f3a24b03fb} - version: 6.0.3 - engines: {node: '>= 0.10'} + node-fetch@2.6.7: + resolution: {integrity: sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ==} + engines: {node: 4.x || >=6.0.0} + peerDependencies: + encoding: ^0.1.0 + peerDependenciesMeta: + encoding: + optional: true - secp256k1@4.0.4: - resolution: {integrity: sha512-6JfvwvjUOn8F/jUoBY2Q1v5WY5XS+rj8qSe0v8Y4ezH4InLgTEeOOPQsRll9OV429Pvo6BCHGavIyJfr3TAhsw==} - engines: {node: '>=18.0.0'} + node-fetch@2.6.9: + resolution: {integrity: sha512-DJm/CJkZkRjKKj4Zi4BsKVZh3ValV5IR5s7LVZnW+6YMh0W1BfNA8XSs6DLMGYlId5F3KnA70uu2qepcR08Qqg==} + engines: {node: 4.x || >=6.0.0} + peerDependencies: + encoding: ^0.1.0 + peerDependenciesMeta: + encoding: + optional: true - seedrandom@3.0.5: - resolution: {integrity: sha512-8OwmbklUNzwezjGInmZ+2clQmExQPvomqjL7LFqOYqtmuxRgQYqOD3mHaU+MvZn5FLUeVxVfQjwLZW/n/JFuqg==} + node-fetch@2.7.0: + resolution: {integrity: sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==} + engines: {node: 4.x || >=6.0.0} + peerDependencies: + encoding: ^0.1.0 + peerDependenciesMeta: + encoding: + optional: true - semaphore-async-await@1.5.1: - resolution: {integrity: sha512-b/ptP11hETwYWpeilHXXQiV5UJNJl7ZWWooKRE5eBIYWoom6dZ0SluCIdCtKycsMtZgKWE01/qAw6jblw1YVhg==} - engines: {node: '>=4.1'} + node-forge@1.3.1: + resolution: {integrity: sha512-dPEtOeMvF9VMcYV/1Wb8CPoVAXtp6MKMlcbAt4ddqmGqUJ6fQZFXkNZNkNlfevtNkGtaSoXf/vNNNSvgrdXwtA==} + engines: {node: '>= 6.13.0'} - semaphore@1.1.0: - resolution: {integrity: sha512-O4OZEaNtkMd/K0i6js9SL+gqy0ZCBMgUvlSqHKi4IBdjhe7wB8pwztUk1BbZ1fmrvpwFrPbHzqd2w5pTcJH6LA==} - engines: {node: '>=0.8.0'} + node-forge@1.3.3: + resolution: {integrity: sha512-rLvcdSyRCyouf6jcOIPe/BgwG/d7hKjzMKOas33/pHEr6gbq18IK9zV7DiPvzsz0oBJPme6qr6H6kGZuI9/DZg==} + engines: {node: '>= 6.13.0'} - semver@6.3.1: - resolution: {integrity: sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==} + node-gyp-build@4.6.0: + resolution: {integrity: sha512-NTZVKn9IylLwUzaKjkas1e4u2DLNcV4rdYagA4PWdPwW87Bi7z+BznyKSRwS/761tV/lzCGXplWsiaMjLqP2zQ==} hasBin: true - semver@7.7.4: - resolution: {integrity: sha512-vFKC2IEtQnVhpT78h1Yp8wzwrf8CM+MzKMHGJZfBtzhZNycRFnXsHk6E5TxIkkMsgNS7mdX3AGB7x2QM2di4lA==} - engines: {node: '>=10'} + node-gyp-build@4.8.4: + resolution: {integrity: sha512-LA4ZjwlnUblHVgq0oBF3Jl/6h/Nvs5fzBLwdEF4nuxnFdsfajde4WfxtJr3CaiH+F6ewcIB/q4jQ4UzPyid+CQ==} hasBin: true - send@0.19.2: - resolution: {integrity: sha512-VMbMxbDeehAxpOtWJXlcUS5E8iXh6QmN+BkRX1GARS3wRaXEEgzCcB10gTQazO42tpNIya8xIyNx8fll1OFPrg==} - engines: {node: '>= 0.8.0'} + node-mock-http@1.0.4: + resolution: {integrity: sha512-8DY+kFsDkNXy1sJglUfuODx1/opAGJGyrTuFqEoN90oRc2Vk0ZbD4K2qmKXBBEhZQzdKHIVfEJpDU8Ak2NJEvQ==} - sentence-case@2.1.1: - resolution: {integrity: sha512-ENl7cYHaK/Ktwk5OTD+aDbQ3uC8IByu/6Bkg+HDv8Mm+XnBnppVNalcfJTNsp1ibstKh030/JKQQWglDvtKwEQ==} + node-releases@2.0.14: + resolution: {integrity: sha512-y10wOWt8yZpqXmOgRo77WaHEmhYQYGNA6y421PKsKYWEK8aW+cqAphborZDhqfyKrbZEN92CN1X2KbafY2s7Yw==} - serialize-javascript@7.0.5: - resolution: {integrity: sha512-F4LcB0UqUl1zErq+1nYEEzSHJnIwb3AF2XWB94b+afhrekOUijwooAYqFyRbjYkm2PAKBabx6oYv/xDxNi8IBw==} - engines: {node: '>=20.0.0'} - - serve-static@1.16.3: - resolution: {integrity: sha512-x0RTqQel6g5SY7Lg6ZreMmsOzncHFU7nhnRWkKgWuMTu5NN0DR5oruckMqRvacAN9d5w6ARnRBXl9xhDCgfMeA==} - engines: {node: '>= 0.8.0'} + node-releases@2.0.27: + resolution: {integrity: sha512-nmh3lCkYZ3grZvqcCH+fjmQ7X+H0OeZgP40OierEaAptX4XofMh5kwNbWh7lBduUzCcV/8kZ+NDLCwm2iorIlA==} - servify@0.1.12: - resolution: {integrity: sha512-/xE6GvsKKqyo1BAY+KxOWXcLpPsUUyji7Qg3bVD7hh1eRze5bR1uYiuDA/k3Gof1s9BTzQZEJK8sNcNGFIzeWw==} - engines: {node: '>=6'} + nopt@7.2.1: + resolution: {integrity: sha512-taM24ViiimT/XntxbPyJQzCG+p4EKOpgD3mxFwW38mGjVUrfERQOeY4EDHjdnptttfHuHQXFx+lTP08Q+mLa/w==} + engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} + hasBin: true - set-blocking@2.0.0: - resolution: {integrity: sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==} + nopt@8.1.0: + resolution: {integrity: sha512-ieGu42u/Qsa4TFktmaKEwM6MQH0pOWnaB3htzh0JRtx84+Mebc0cbZYN5bC+6WTZ4+77xrL9Pn5m7CV6VIkV7A==} + engines: {node: ^18.17.0 || >=20.5.0} + hasBin: true - set-function-length@1.2.2: - resolution: {integrity: sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==} - engines: {node: '>= 0.4'} + normalize-path@3.0.0: + resolution: {integrity: sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==} + engines: {node: '>=0.10.0'} - set-function-name@2.0.2: - resolution: {integrity: sha512-7PGFlmtwsEADb0WYyvCMa1t+yke6daIG4Wirafur5kcf+MhUnPms1UeR0CKQdTZD81yESwMHbtn+TR+dMviakQ==} - engines: {node: '>= 0.4'} + npm-run-path@4.0.1: + resolution: {integrity: sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==} + engines: {node: '>=8'} - set-immediate-shim@1.0.1: - resolution: {integrity: sha512-Li5AOqrZWCVA2n5kryzEmqai6bKSIvpz5oUJHPVj6+dsbD3X1ixtsY5tEnsaNpH3pFAHmG8eIHUrtEtohrg+UQ==} - engines: {node: '>=0.10.0'} + npm-run-path@5.3.0: + resolution: {integrity: sha512-ppwTtiJZq0O/ai0z7yfudtBpWIoxM8yE6nHi1X47eFR2EWORqfbu6CnPlNsjeN683eT0qG6H/Pyf9fCcvjnnnQ==} + engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - set-proto@1.0.0: - resolution: {integrity: sha512-RJRdvCo6IAnPdsvP/7m6bsQqNnn1FCBX5ZNtFL98MmFF/4xAIJTIg1YbHW5DC2W5SKZanrC6i4HsJqlajw/dZw==} - engines: {node: '>= 0.4'} + npm-run-path@6.0.0: + resolution: {integrity: sha512-9qny7Z9DsQU8Ou39ERsPU4OZQlSTP47ShQzuKZ6PRXpYLtIFgl/DEBYEXKlvcEa+9tHVcK8CF81Y2V72qaZhWA==} + engines: {node: '>=18'} - setimmediate@1.0.5: - resolution: {integrity: sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==} + nth-check@2.1.1: + resolution: {integrity: sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==} - setprototypeof@1.2.0: - resolution: {integrity: sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==} + nuxt@3.19.0: + resolution: {integrity: sha512-gDXI7sL6dtdgHVh+D90UpI0El5LzQhKvwhIB6ppm8Zh3khG5WsFj3GZkPF0JVkN2BG9oAFgU14qsVajkOEXG3g==} + engines: {node: ^20.19.0 || >=22.12.0} + hasBin: true + peerDependencies: + '@parcel/watcher': ^2.1.0 + '@types/node': ^18.0.0 || ^20.0.0 || >=22.0.0 + peerDependenciesMeta: + '@parcel/watcher': + optional: true + '@types/node': + optional: true - sha.js@2.4.12: - resolution: {integrity: sha512-8LzC5+bvI45BjpfXU8V5fdU2mfeKiQe1D1gIMn7XUlF3OTUrpdJpPPH4EMAnF0DsHHdSZqCdSss5qCmJKuiO3w==} - engines: {node: '>= 0.10'} + nypm@0.6.2: + resolution: {integrity: sha512-7eM+hpOtrKrBDCh7Ypu2lJ9Z7PNZBdi/8AT3AX8xoCj43BBVHD0hPSTEvMtkMpfs8FCqBGhxB+uToIQimA111g==} + engines: {node: ^14.16.0 || >=16.10.0} hasBin: true - sha1@1.1.1: - resolution: {integrity: sha512-dZBS6OrMjtgVkopB1Gmo4RQCDKiZsqcpAQpkV/aaj+FCrCg8r4I4qMkDPQjBgLIxlmu9k4nUbWq6ohXahOneYA==} + obj-multiplex@1.0.0: + resolution: {integrity: sha512-0GNJAOsHoBHeNTvl5Vt6IWnpUEcc3uSRxzBri7EDyIcMgYvnY2JL2qdeV5zTMjWQX5OHcD5amcW2HFfDh0gjIA==} - sharp@0.34.5: - resolution: {integrity: sha512-Ou9I5Ft9WNcCbXrU9cMgPBcCK8LiwLqcbywW3t4oDV37n1pzpuNLsYiAV8eODnjbtQlSDwZ2cUEeQz4E54Hltg==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} + object-assign@4.1.1: + resolution: {integrity: sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==} + engines: {node: '>=0.10.0'} - shebang-command@2.0.0: - resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} - engines: {node: '>=8'} + obliterator@2.0.4: + resolution: {integrity: sha512-lgHwxlxV1qIg1Eap7LgIeoBWIMFibOjbrYPIPJZcI1mmGAI2m3lNYpK12Y+GBdPQ0U1hRwSord7GIaawz962qQ==} - shebang-regex@3.0.0: - resolution: {integrity: sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==} - engines: {node: '>=8'} + ofetch@1.5.1: + resolution: {integrity: sha512-2W4oUZlVaqAPAil6FUg/difl6YhqhUR7x2eZY4bQCko22UXg3hptq9KLQdqFClV+Wu85UX7hNtdGTngi/1BxcA==} - shell-quote@1.8.3: - resolution: {integrity: sha512-ObmnIF4hXNg1BqhnHmgbDETF8dLPCggZWBjkQfhZpbszZnYur5DUljTcCHii5LC3J5E0yeO/1LIMyH+UvHQgyw==} - engines: {node: '>= 0.4'} + ohash@2.0.11: + resolution: {integrity: sha512-RdR9FQrFwNBNXAr4GixM8YaRZRJ5PUWbKYbE5eOsrwAjJW0q2REGcf79oYPsLyskQCZG1PLN+S/K1V00joZAoQ==} - shelljs@0.8.5: - resolution: {integrity: sha512-TiwcRcrkhHvbrZbnRcFYMLl30Dfov3HKqzp5tO5b4pt6G/SezKcYhmDg15zXVBswHmctSAQKznqNW2LO5tTDow==} - engines: {node: '>=4'} - hasBin: true + on-change@5.0.1: + resolution: {integrity: sha512-n7THCP7RkyReRSLkJb8kUWoNsxUIBxTkIp3JKno+sEz6o/9AJ3w3P9fzQkITEkMwyTKJjZciF3v/pVoouxZZMg==} + engines: {node: '>=18'} - side-channel-list@1.0.0: - resolution: {integrity: sha512-FCLHtRD/gnpCiCHEiJLOwdmFP+wzCmDEkc9y7NsYxeF4u7Btsn1ZuwgwJGxImImHicJArLP4R0yX4c2KCrMrTA==} - engines: {node: '>= 0.4'} + on-exit-leak-free@0.2.0: + resolution: {integrity: sha512-dqaz3u44QbRXQooZLTUKU41ZrzYrcvLISVgbrzbyCMxpmSLJvZ3ZamIJIZ29P6OhZIkNIQKosdeM6t1LYbA9hg==} - side-channel-map@1.0.1: - resolution: {integrity: sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==} - engines: {node: '>= 0.4'} + on-exit-leak-free@2.1.2: + resolution: {integrity: sha512-0eJJY6hXLGf1udHwfNftBqH+g73EU4B504nZeKpz1sYRKafAghwxEJunB2O7rDZkL4PGfsMVnTXZ2EjibbqcsA==} + engines: {node: '>=14.0.0'} - side-channel-weakmap@1.0.2: - resolution: {integrity: sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==} - engines: {node: '>= 0.4'} + on-finished@2.4.1: + resolution: {integrity: sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg==} + engines: {node: '>= 0.8'} - side-channel@1.1.0: - resolution: {integrity: sha512-ZX99e6tRweoUXqR+VBrslhda51Nh5MTQwou5tnUDgbtyM0dBgmhEDtWGP/xbKn6hqfPRHujUNwz5fy/wbbhnpw==} - engines: {node: '>= 0.4'} + once@1.3.3: + resolution: {integrity: sha512-6vaNInhu+CHxtONf3zw3vq4SP2DOQhjBvIa3rNcG0+P7eKWlYH6Peu7rHizSloRU2EwMz6GraLieis9Ac9+p1w==} - siginfo@2.0.0: - resolution: {integrity: sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==} + once@1.4.0: + resolution: {integrity: sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==} - signal-exit@3.0.7: - resolution: {integrity: sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==} + onetime@5.1.2: + resolution: {integrity: sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==} + engines: {node: '>=6'} - signal-exit@4.1.0: - resolution: {integrity: sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==} - engines: {node: '>=14'} + onetime@6.0.0: + resolution: {integrity: sha512-1FlR+gjXK7X+AsAHso35MnyN5KqGwJRi/31ft6x0M194ht7S+rWAvd7PHss9xSKMzE0asv1pyIHaJYq+BbacAQ==} + engines: {node: '>=12'} - simple-concat@1.0.1: - resolution: {integrity: sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==} + oniguruma-to-js@0.4.3: + resolution: {integrity: sha512-X0jWUcAlxORhOqqBREgPMgnshB7ZGYszBNspP+tS9hPD3l13CdaXcHbgImoHUHlrvGx/7AvFEkTRhAGYh+jzjQ==} + deprecated: use oniguruma-to-es instead - simple-get@2.8.2: - resolution: {integrity: sha512-Ijd/rV5o+mSBBs4F/x9oDPtTx9Zb6X9brmnXvMW4J7IR15ngi9q5xxqWBKU744jTZiaXtxaPL7uHG6vtN8kUkw==} + open@10.2.0: + resolution: {integrity: sha512-YgBpdJHPyQ2UE5x+hlSXcnejzAvD0b22U2OuAP+8OnlJT+PjWPxtgmGqKKc+RgTM63U9gN0YzrYc71R2WT/hTA==} + engines: {node: '>=18'} - simple-update-notifier@2.0.0: - resolution: {integrity: sha512-a2B9Y0KlNXl9u/vsW6sTIu9vGEpfKu2wRV6l1H3XEas/0gUIzGzBoP/IouTcUQbm9JWZLH3COxyn03TYlFax6w==} - engines: {node: '>=10'} + open@8.4.2: + resolution: {integrity: sha512-7x81NCL719oNbsq/3mh+hVrAWmFuEYUqrq/Iw3kUzH8ReypT9QQ0BLoJS7/G9k6N81XjW4qHWtjWwe/9eLy1EQ==} + engines: {node: '>=12'} - sisteransi@1.0.5: - resolution: {integrity: sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==} + openapi-fetch@0.13.8: + resolution: {integrity: sha512-yJ4QKRyNxE44baQ9mY5+r/kAzZ8yXMemtNAOFwOzRXJscdjSxxzWSNlyBAr+o5JjkUw9Lc3W7OIoca0cY3PYnQ==} - slash@3.0.0: - resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==} - engines: {node: '>=8'} + openapi-typescript-helpers@0.0.15: + resolution: {integrity: sha512-opyTPaunsklCBpTK8JGef6mfPhLSnyy5a0IN9vKtx3+4aExf+KxEqYwIy3hqkedXIB97u357uLMJsOnm3GVjsw==} - slice-ansi@4.0.0: - resolution: {integrity: sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ==} - engines: {node: '>=10'} + opener@1.5.2: + resolution: {integrity: sha512-ur5UIdyw5Y7yEj9wLzhqXiy6GZ3Mwx0yGI+5sMn2r0N0v3cKJvUmFH5yPP+WXh9e0xfyzyJX95D8l088DNFj7A==} + hasBin: true - smart-buffer@4.2.0: - resolution: {integrity: sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg==} - engines: {node: '>= 6.0.0', npm: '>= 3.0.0'} + os-paths@4.4.0: + resolution: {integrity: sha512-wrAwOeXp1RRMFfQY8Sy7VaGVmPocaLwSFOYCGKSyo8qmJ+/yaafCl5BCA1IQZWqFSRBrKDYFeR9d/VyQzfH/jg==} + engines: {node: '>= 6.0'} - snake-case@2.1.0: - resolution: {integrity: sha512-FMR5YoPFwOLuh4rRz92dywJjyKYZNLpMn1R5ujVpIYkbA9p01fq8RMg0FkO4M+Yobt4MjHeLTJVm5xFFBHSV2Q==} + os-tmpdir@1.0.2: + resolution: {integrity: sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==} + engines: {node: '>=0.10.0'} - socks-proxy-agent@7.0.0: - resolution: {integrity: sha512-Fgl0YPZ902wEsAyiQ+idGd1A7rSFx/ayC1CQVMw5P+EQx2V0SgpGtf6OKFhVjPflPUl9YMmEOnmfjCdMUsygww==} - engines: {node: '>= 10'} + outdent@0.5.0: + resolution: {integrity: sha512-/jHxFIzoMXdqPzTaCpFzAAWhpkSjZPF4Vsn6jAfNpmbH/ymsmd7Qc6VE9BGn0L6YMj6uwpQLxCECpus4ukKS9Q==} - socks-proxy-agent@8.0.5: - resolution: {integrity: sha512-HehCEsotFqbPW9sJ8WVYB6UbmIMv7kUUORIF2Nncq4VQvBfNBLibW9YZR5dlYCSUhwcD628pRllm7n+E+YTzJw==} - engines: {node: '>= 14'} + outvariant@1.4.2: + resolution: {integrity: sha512-Ou3dJ6bA/UJ5GVHxah4LnqDwZRwAmWxrG3wtrHrbGnP4RnLCtA64A4F+ae7Y8ww660JaddSoArUR5HjipWSHAQ==} - socks@2.8.7: - resolution: {integrity: sha512-HLpt+uLy/pxB+bum/9DzAgiKS8CX1EvbWxI4zlmgGCExImLdiad2iCwXT5Z4c9c3Eq8rP2318mPW2c+QbtjK8A==} - engines: {node: '>= 10.0.0', npm: '>= 3.0.0'} + outvariant@1.4.3: + resolution: {integrity: sha512-+Sl2UErvtsoajRDKCE5/dBz4DIvHXQQnAxtQTF04OJxY0+DyZXSo5P5Bb7XYWOh81syohlYL24hbDwxedPUJCA==} - solc@0.4.26: - resolution: {integrity: sha512-o+c6FpkiHd+HPjmjEVpQgH7fqZ14tJpXhho+/bQXlXbliLIS/xjXb42Vxh+qQY1WCSTMQ0+a5vR9vi0MfhU6mA==} - hasBin: true + ox@0.11.1: + resolution: {integrity: sha512-1l1gOLAqg0S0xiN1dH5nkPna8PucrZgrIJOfS49MLNiMevxu07Iz4ZjuJS9N+xifvT+PsZyIptS7WHM8nC+0+A==} + peerDependencies: + typescript: '>=5.4.0' + peerDependenciesMeta: + typescript: + optional: true - solc@0.8.15: - resolution: {integrity: sha512-Riv0GNHNk/SddN/JyEuFKwbcWcEeho15iyupTSHw5Np6WuXA5D8kEHbyzDHi6sqmvLzu2l+8b1YmL8Ytple+8w==} - engines: {node: '>=10.0.0'} - hasBin: true + ox@0.6.7: + resolution: {integrity: sha512-17Gk/eFsFRAZ80p5eKqv89a57uXjd3NgIf1CaXojATPBuujVc/fQSVhBeAU9JCRB+k7J50WQAyWTxK19T9GgbA==} + peerDependencies: + typescript: '>=5.4.0' + peerDependenciesMeta: + typescript: + optional: true - solc@0.8.26: - resolution: {integrity: sha512-yiPQNVf5rBFHwN6SIf3TUUvVAFKcQqmSUFeq+fb6pNRCo0ZCgpYOZDi3BVoezCPIAcKrVYd/qXlBLUP9wVrZ9g==} - engines: {node: '>=10.0.0'} - hasBin: true + ox@0.7.2: + resolution: {integrity: sha512-JJHxdef3KqwQ8xW9H+UVLWaQiCUh/DeFN/Ii65XwbHTvSuXZveihTV2gs9hhLw5XEWPBrcH7sQBM0rqG7/QurQ==} + peerDependencies: + typescript: '>=5.4.0' + peerDependenciesMeta: + typescript: + optional: true - solhint@3.6.2: - resolution: {integrity: sha512-85EeLbmkcPwD+3JR7aEMKsVC9YrRSxd4qkXuMzrlf7+z2Eqdfm1wHWq1ffTuo5aDhoZxp2I9yF3QkxZOxOL7aQ==} - hasBin: true + ox@0.8.1: + resolution: {integrity: sha512-e+z5epnzV+Zuz91YYujecW8cF01mzmrUtWotJ0oEPym/G82uccs7q0WDHTYL3eiONbTUEvcZrptAKLgTBD3u2A==} + peerDependencies: + typescript: '>=5.4.0' + peerDependenciesMeta: + typescript: + optional: true - solidity-ast@0.4.62: - resolution: {integrity: sha512-jSC7msQCkJXIzM8LlDjRZ5cif5w40g6THlXHFk3zchbL5dm3YLoBETvqPGo5KndYkftjhcs5kz1fnTu4d34lVQ==} + oxc-minify@0.86.0: + resolution: {integrity: sha512-pjtM94KElw/RxF3R1ls1ADcBUyZcrCgn0qeL4nD8cOotfzeVFa0xXwQQeCkk+5GPiOqdRApNFuJvK//lQgpqJw==} + engines: {node: '>=14.0.0'} - solidity-coverage@0.8.17: - resolution: {integrity: sha512-5P8vnB6qVX9tt1MfuONtCTEaEGO/O4WuEidPHIAJjx4sktHHKhO3rFvnE0q8L30nWJPTrcqGQMT7jpE29B2qow==} - hasBin: true + oxc-parser@0.86.0: + resolution: {integrity: sha512-v9+uomgqyLSxlq3qlaMqJJtXg2+rUsa368p/zkmgi5OMGmcZAtZt5GIeSVFF84iNET+08Hdx/rUtd/FyIdfNFQ==} + engines: {node: '>=20.0.0'} + + oxc-transform@0.86.0: + resolution: {integrity: sha512-Ghgm/zzjPXROMpljLy4HYBcko/25sixWi2yJQJ6rDu/ltgFB1nEQ4JYCYV5F+ENt0McsJkcgmX5I4dRfDViyDA==} + engines: {node: '>=14.0.0'} + + oxc-walker@0.4.0: + resolution: {integrity: sha512-x5TJAZQD3kRnRBGZ+8uryMZUwkTYddwzBftkqyJIcmpBOXmoK/fwriRKATjZroR2d+aS7+2w1B0oz189bBTwfw==} peerDependencies: - hardhat: ^2.11.0 + oxc-parser: '>=0.72.0' - source-map-js@1.2.1: - resolution: {integrity: sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==} - engines: {node: '>=0.10.0'} + p-filter@2.1.0: + resolution: {integrity: sha512-ZBxxZ5sL2HghephhpGAQdoskxplTwr7ICaehZwLIlfL6acuVgZPm8yBNuRAFBGEqtD/hmUeq9eqLg2ys9Xr/yw==} + engines: {node: '>=8'} - source-map-support@0.5.21: - resolution: {integrity: sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==} + p-finally@2.0.1: + resolution: {integrity: sha512-vpm09aKwq6H9phqRQzecoDpD8TmVyGw70qmWlyq5onxY7tqyTTFVvxMykxQSQKILBSFlbXpypIw2T1Ml7+DDtw==} + engines: {node: '>=8'} - source-map@0.2.0: - resolution: {integrity: sha512-CBdZ2oa/BHhS4xj5DlhjWNHcan57/5YuvfdLf17iVmIpd9KRm+DFLmC6nBNj+6Ua7Kt3TmOjDpQT1aTYOQtoUA==} - engines: {node: '>=0.8.0'} + p-limit@1.3.0: + resolution: {integrity: sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==} + engines: {node: '>=4'} - source-map@0.6.1: - resolution: {integrity: sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==} - engines: {node: '>=0.10.0'} + p-limit@2.3.0: + resolution: {integrity: sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==} + engines: {node: '>=6'} + + p-limit@3.1.0: + resolution: {integrity: sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==} + engines: {node: '>=10'} - spawn-command@0.0.2: - resolution: {integrity: sha512-zC8zGoGkmc8J9ndvml8Xksr1Amk9qBujgbF0JAIWO7kXr43w0h/0GJNM/Vustixu+YE8N/MTrQ7N31FvHUACxQ==} + p-locate@2.0.0: + resolution: {integrity: sha512-nQja7m7gSKuewoVRen45CtVfODR3crN3goVQ0DDZ9N3yHxgpkuBhZqsaiotSQRrADUrne346peY7kT3TSACykg==} + engines: {node: '>=4'} - spawn-wrap@2.0.0: - resolution: {integrity: sha512-EeajNjfN9zMnULLwhZZQU3GWBoFNkbngTUPfaawT4RkMiviTxcX0qfhVbGey39mfctfDHkWtuecgQ8NJcyQWHg==} + p-locate@4.1.0: + resolution: {integrity: sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==} engines: {node: '>=8'} - spawndamnit@3.0.1: - resolution: {integrity: sha512-MmnduQUuHCoFckZoWnXsTg7JaiLBJrKFj9UI2MbRPGaJeVpsLcVBu6P/IGZovziM/YBsellCmsprgNA+w0CzVg==} + p-locate@5.0.0: + resolution: {integrity: sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==} + engines: {node: '>=10'} - spdx-correct@3.2.0: - resolution: {integrity: sha512-kN9dJbvnySHULIluDHy32WHRUu3Og7B9sbY7tsFLctQkIqnMh3hErYgdMjTYuqmcXX+lK5T1lnUt3G7zNswmZA==} + p-map@2.1.0: + resolution: {integrity: sha512-y3b8Kpd8OAN444hxfBbFfj1FY/RjtTd8tzYwhUqNYXx0fXx2iX4maP4Qr6qhIKbQXI02wTLAda4fYUbDagTUFw==} + engines: {node: '>=6'} - spdx-exceptions@2.5.0: - resolution: {integrity: sha512-PiU42r+xO4UbUS1buo3LPJkjlO7430Xn5SVAhdpzzsPHsjbYVflnnFdATgabnLude+Cqu25p6N+g2lw/PFsa4w==} + p-map@4.0.0: + resolution: {integrity: sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==} + engines: {node: '>=10'} - spdx-expression-parse@3.0.1: - resolution: {integrity: sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==} + p-try@1.0.0: + resolution: {integrity: sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww==} + engines: {node: '>=4'} - spdx-license-ids@3.0.23: - resolution: {integrity: sha512-CWLcCCH7VLu13TgOH+r8p1O/Znwhqv/dbb6lqWy67G+pT1kHmeD/+V36AVb/vq8QMIQwVShJ6Ssl5FPh0fuSdw==} + p-try@2.2.0: + resolution: {integrity: sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==} + engines: {node: '>=6'} - split2@3.2.2: - resolution: {integrity: sha512-9NThjpgZnifTkJpzTZ7Eue85S49QwpNhZTq6GRJwObb6jnLFNGB7Qm73V5HewTROPyxD0C29xqmaI68bQtV+hg==} + package-json-from-dist@1.0.1: + resolution: {integrity: sha512-UEZIS3/by4OC8vL3P2dTXRETpebLI2NiI5vIrjaD/5UtrkFX/tNbwjTSRAGC/+7CAo2pIcBaRgWmcBBHcsaCIw==} - sprintf-js@1.0.3: - resolution: {integrity: sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==} + package-manager-detector@0.2.0: + resolution: {integrity: sha512-E385OSk9qDcXhcM9LNSe4sdhx8a9mAPrZ4sMLW+tmxl5ZuGtPUcdFu+MPP2jbgiWAZ6Pfe5soGFMd+0Db5Vrog==} - sshpk@1.18.0: - resolution: {integrity: sha512-2p2KJZTSqQ/I3+HX42EpYOa2l3f8Erv8MWKsy2I9uf4wA7yFIkXRffYdsx86y6z4vHtV8u7g+pPlr8/4ouAxsQ==} - engines: {node: '>=0.10.0'} - hasBin: true + package-manager-detector@0.2.11: + resolution: {integrity: sha512-BEnLolu+yuz22S56CU1SUKq3XC3PkwD5wv4ikR4MfGvnRVcmzXR9DwSlW2fEamyTPyXHomBJRzgapeuBvRNzJQ==} - ssri@10.0.6: - resolution: {integrity: sha512-MGrFH9Z4NP9Iyhqn16sDtBpRRNJ0Y2hNa6D65h736fVSaPCHr4DM4sWUNvVaSuC+0OBGhwsrydQwmgfg5LncqQ==} - engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} + package-manager-detector@1.3.0: + resolution: {integrity: sha512-ZsEbbZORsyHuO00lY1kV3/t72yp6Ysay6Pd17ZAlNGuGwmWDLCJxFpRs0IzfXfj1o4icJOkUEioexFHzyPurSQ==} - stackback@0.0.2: - resolution: {integrity: sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==} + package-manager-detector@1.6.0: + resolution: {integrity: sha512-61A5ThoTiDG/C8s8UMZwSorAGwMJ0ERVGj2OjoW5pAalsNOg15+iQiPzrLJ4jhZ1HJzmC2PIHT2oEiH3R5fzNA==} - stacktrace-parser@0.1.11: - resolution: {integrity: sha512-WjlahMgHmCJpqzU8bIBy4qtsZdU9lRlcZE3Lvyej6t4tuOuv1vk57OW3MBrj6hXBFx/nNoC9MPMTcr5YA7NQbg==} + parse-ms@2.1.0: + resolution: {integrity: sha512-kHt7kzLoS9VBZfUsiKjv43mr91ea+U05EyKkEtqp7vNbHxmaVuEqN7XxeEVnGrMtYOAxGrDElSi96K7EgO1zCA==} engines: {node: '>=6'} - statuses@1.5.0: - resolution: {integrity: sha512-OpZ3zP+jT1PI7I8nemJX4AKmAX070ZkYPVWV/AaKTJl+tXCTGyVdC1a4SL8RUQYEwk/f34ZX8UTykN68FwrqAA==} - engines: {node: '>= 0.6'} + parse-ms@4.0.0: + resolution: {integrity: sha512-TXfryirbmq34y8QBwgqCVLi+8oA3oWx2eAnSn62ITyEhEYaWRlVZ2DvMM9eZbMs/RfxPu/PK/aBLyGj4IrqMHw==} + engines: {node: '>=18'} - statuses@2.0.2: - resolution: {integrity: sha512-DvEy55V3DB7uknRo+4iOGT5fP1slR8wQohVdknigZPMpMstaKJQWhwiYBACJE3Ul2pTnATihhBYnRhZQHGBiRw==} - engines: {node: '>= 0.8'} + parse-path@7.1.0: + resolution: {integrity: sha512-EuCycjZtfPcjWk7KTksnJ5xPMvWGA/6i4zrLYhRG0hGvC3GPU/jGUj3Cy+ZR0v30duV3e23R95T1lE2+lsndSw==} - std-env@3.10.0: - resolution: {integrity: sha512-5GS12FdOZNliM5mAOxFRg7Ir0pWz8MdpYm6AY6VPkGpbA7ZzmbzNcBJQ0GPvvyWgcY7QAhCgf9Uy89I03faLkg==} + parse-url@9.2.0: + resolution: {integrity: sha512-bCgsFI+GeGWPAvAiUv63ZorMeif3/U0zaXABGJbOWt5OH2KCaPHF6S+0ok4aqM9RuIPGyZdx9tR9l13PsW4AYQ==} + engines: {node: '>=14.13.0'} - stop-iteration-iterator@1.1.0: - resolution: {integrity: sha512-eLoXW/DHyl62zxY4SCaIgnRhuMr6ri4juEYARS8E6sCEqzKpOiE521Ucofdx+KnDZl5xmvGYaaKCk5FEOxJCoQ==} - engines: {node: '>= 0.4'} + parse5-htmlparser2-tree-adapter@6.0.1: + resolution: {integrity: sha512-qPuWvbLgvDGilKc5BoicRovlT4MtYT6JfJyBOMDsKoiT+GiuP5qyrPCnR9HcPECIJJmZh5jRndyNThnhhb/vlA==} - stream-shift@1.0.3: - resolution: {integrity: sha512-76ORR0DO1o1hlKwTbi/DM3EXWGf3ZJYO8cXX5RJwnul2DEg2oyoZyjLNoQM8WsvZiFKCRfC1O0J7iCvie3RZmQ==} + parse5@5.1.1: + resolution: {integrity: sha512-ugq4DFI0Ptb+WWjAdOK16+u/nHfiIrcE+sh8kZMaM0WllQKLI9rOUq6c2b7cwPkXdzfQESqvoqK6ug7U/Yyzug==} - strict-uri-encode@1.1.0: - resolution: {integrity: sha512-R3f198pcvnB+5IpnBlRkphuE9n46WyVl8I39W/ZUTZLz4nqSP/oLYUrcnJrw462Ds8he4YKMov2efsTIw1BDGQ==} - engines: {node: '>=0.10.0'} + parse5@6.0.1: + resolution: {integrity: sha512-Ofn/CTFzRGTTxwpNEs9PP93gXShHcTq255nzRYSKe8AkVpZY7e1fpmTfOyoIvjP5HG7Z2ZM7VS9PPhQGW2pOpw==} - string-format@2.0.0: - resolution: {integrity: sha512-bbEs3scLeYNXLecRRuk6uJxdXUSj6le/8rNPHChIJTn2V79aXVTR1EH2OH5zLKKoz0V02fOUKZZcw01pLUShZA==} + parseurl@1.3.3: + resolution: {integrity: sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==} + engines: {node: '>= 0.8'} - string-width@1.0.2: - resolution: {integrity: sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==} - engines: {node: '>=0.10.0'} + path-browserify@1.0.1: + resolution: {integrity: sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==} - string-width@2.1.1: - resolution: {integrity: sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==} + path-exists@3.0.0: + resolution: {integrity: sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==} engines: {node: '>=4'} - string-width@4.2.3: - resolution: {integrity: sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==} + path-exists@4.0.0: + resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} engines: {node: '>=8'} - string-width@5.1.2: - resolution: {integrity: sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==} - engines: {node: '>=12'} + path-is-absolute@1.0.1: + resolution: {integrity: sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==} + engines: {node: '>=0.10.0'} - string-width@7.2.0: - resolution: {integrity: sha512-tsaTIkKW9b4N+AEj+SVA+WhJzV7/zMhcSu78mLKWSk7cXMOSHsBKFWUs0fWwq8QyK3MgJBQRX6Gbi4kYbdvGkQ==} - engines: {node: '>=18'} + path-key@3.1.1: + resolution: {integrity: sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==} + engines: {node: '>=8'} - string.prototype.matchall@4.0.12: - resolution: {integrity: sha512-6CC9uyBL+/48dYizRf7H7VAYCMCNTBeM78x/VTUe9bFEaxBepPJDa1Ow99LqI/1yF7kuy7Q3cQsYMrcjGUcskA==} - engines: {node: '>= 0.4'} + path-key@4.0.0: + resolution: {integrity: sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ==} + engines: {node: '>=12'} - string.prototype.repeat@1.0.0: - resolution: {integrity: sha512-0u/TldDbKD8bFCQ/4f5+mNRrXwZ8hg2w7ZR8wa16e8z9XpePWl3eGEcUD0OXpEH/VJH/2G3gjUtR3ZOiBe2S/w==} + path-match@1.2.4: + resolution: {integrity: sha512-UWlehEdqu36jmh4h5CWJ7tARp1OEVKGHKm6+dg9qMq5RKUTV5WJrGgaZ3dN2m7WFAXDbjlHzvJvL/IUpy84Ktw==} + deprecated: This package is archived and no longer maintained. For support, visit https://github.com/expressjs/express/discussions - string.prototype.trim@1.2.10: - resolution: {integrity: sha512-Rs66F0P/1kedk5lyYyH9uBzuiI/kNRmwJAR9quK6VOtIpZ2G+hMZd+HQbbv25MgCA6gEffoMZYxlTod4WcdrKA==} - engines: {node: '>= 0.4'} + path-parse@1.0.7: + resolution: {integrity: sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==} - string.prototype.trimend@1.0.9: - resolution: {integrity: sha512-G7Ok5C6E/j4SGfyLCloXTrngQIQU3PWtXGst3yM7Bea9FRURf1S42ZHlZZtsNque2FN2PoUhfZXYLNWwEr4dLQ==} - engines: {node: '>= 0.4'} + path-scurry@1.11.1: + resolution: {integrity: sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==} + engines: {node: '>=16 || 14 >=14.18'} - string.prototype.trimstart@1.0.8: - resolution: {integrity: sha512-UXSH262CSZY1tfu3G3Secr6uGLCFVPMhIqHjlgCUtCCcgihYc/xKs9djMTMUOb2j1mVSeU8EU6NWc/iQKU6Gfg==} - engines: {node: '>= 0.4'} + path-scurry@2.0.1: + resolution: {integrity: sha512-oWyT4gICAu+kaA7QWk/jvCHWarMKNs6pXOGWKDTr7cw4IGcUbW+PeTfbaQiLGheFRpjo6O9J0PmyMfQPjH71oA==} + engines: {node: 20 || >=22} - string_decoder@0.10.31: - resolution: {integrity: sha512-ev2QzSzWPYmy9GuqfIVildA4OdcGLeFZQrq5ys6RtiuF+RQQiZWr8TZNyAcuVXyQRYfEO+MsoB/1BuQVhOJuoQ==} + path-to-regexp@1.9.0: + resolution: {integrity: sha512-xIp7/apCFJuUHdDLWe8O1HIkb0kQrOMb/0u6FXQjemHn/ii5LrIzU6bdECnsiTF/GjZkMEKg1xdiZwNqDYlZ6g==} - string_decoder@1.1.1: - resolution: {integrity: sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==} + path-to-regexp@6.1.0: + resolution: {integrity: sha512-h9DqehX3zZZDCEm+xbfU0ZmwCGFCAAraPJWMXJ4+v32NjZJilVg3k1TcKsRgIb8IQ/izZSaydDc1OhJCZvs2Dw==} - string_decoder@1.3.0: - resolution: {integrity: sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==} + path-to-regexp@6.3.0: + resolution: {integrity: sha512-Yhpw4T9C6hPpgPeA28us07OJeqZ5EzQTkbfwuhsUg0c237RomFoETJgmp2sa3F/41gfLE6G5cqcYwznmeEeOlQ==} - strip-ansi@3.0.1: - resolution: {integrity: sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==} - engines: {node: '>=0.10.0'} + path-to-regexp@8.3.0: + resolution: {integrity: sha512-7jdwVIRtsP8MYpdXSwOS0YdD0Du+qOoF/AEPIt88PcCFrZCzx41oxku1jD88hZBwbNUIEfpqvuhjFaMAqMTWnA==} - strip-ansi@4.0.0: - resolution: {integrity: sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow==} + path-type@3.0.0: + resolution: {integrity: sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg==} engines: {node: '>=4'} - strip-ansi@6.0.1: - resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} + path-type@4.0.0: + resolution: {integrity: sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==} engines: {node: '>=8'} - strip-ansi@7.1.2: - resolution: {integrity: sha512-gmBGslpoQJtgnMAvOVqGZpEz9dyoKTCzy2nfz/n8aIFhN/jCE/rCmcxabB6jOOHV+0WNnylOxaxBQPSvcWklhA==} - engines: {node: '>=12'} + path-type@6.0.0: + resolution: {integrity: sha512-Vj7sf++t5pBD637NSfkxpHSMfWaeig5+DKWLhcqIYx6mWQz5hdJTGDVMQiJcw1ZYkhs7AazKDGpRVji1LJCZUQ==} + engines: {node: '>=18'} - strip-ansi@7.2.0: - resolution: {integrity: sha512-yDPMNjp4WyfYBkHnjIRLfca1i6KMyGCtsVgoKe/z1+6vukgaENdgGBZt+ZmKPc4gavvEZ5OgHfHdrazhgNyG7w==} - engines: {node: '>=12'} + pathe@1.1.2: + resolution: {integrity: sha512-whLdWMYL2TwI08hn8/ZqAbrVemu0LNaNNJZX73O6qaIdCTfXutsLhMkjdENX0qhsQ9uIimo4/aQOmXkoon2nDQ==} - strip-bom@2.0.0: - resolution: {integrity: sha512-kwrX1y7czp1E69n2ajbG65mIo9dqvJ+8aBQXOGVxqwvNbsXdFM6Lq37dLAY3mknUwru8CfcCbfOLL/gMo+fi3g==} - engines: {node: '>=0.10.0'} + pathe@2.0.3: + resolution: {integrity: sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==} - strip-bom@3.0.0: - resolution: {integrity: sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==} - engines: {node: '>=4'} + pathval@2.0.0: + resolution: {integrity: sha512-vE7JKRyES09KiunauX7nd2Q9/L7lhok4smP9RZTDeD4MVs72Dp2qNFVz39Nz5a0FVEW0BJR6C0DYrq6unoziZA==} + engines: {node: '>= 14.16'} - strip-bom@4.0.0: - resolution: {integrity: sha512-3xurFv5tEgii33Zi8Jtp55wEIILR9eh34FAW00PZf+JnSsTmV/ioewSgQl97JHvgjoRGwPShsWm+IdrxB35d0w==} - engines: {node: '>=8'} + pbkdf2@3.1.2: + resolution: {integrity: sha512-iuh7L6jA7JEGu2WxDwtQP1ddOpaJNC4KlDEFfdQajSGgGPNi4OyDc2R7QnbY2bR9QjBVGwgvTdNJZoE7RaxUMA==} + engines: {node: '>=0.12'} - strip-final-newline@2.0.0: - resolution: {integrity: sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==} - engines: {node: '>=6'} + pend@1.2.0: + resolution: {integrity: sha512-F3asv42UuXchdzt+xXqfW1OGlVBe+mxa2mqI0pg5yAHZPvFmY3Y6drSf/GQ1A86WgWEN9Kzh/WrgKa6iGcHXLg==} - strip-hex-prefix@1.0.0: - resolution: {integrity: sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==} - engines: {node: '>=6.5.0', npm: '>=3'} + perfect-debounce@1.0.0: + resolution: {integrity: sha512-xCy9V055GLEqoFaHoC1SoLIaLmWctgCUaBaWxDZ7/Zx4CTyX7cJQLJOok/orfjZAh9kEYpjJa4d0KcJmCbctZA==} - strip-json-comments@2.0.1: - resolution: {integrity: sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==} - engines: {node: '>=0.10.0'} + perfect-debounce@2.0.0: + resolution: {integrity: sha512-fkEH/OBiKrqqI/yIgjR92lMfs2K8105zt/VT6+7eTjNwisrsh47CeIED9z58zI7DfKdH3uHAn25ziRZn3kgAow==} - strip-json-comments@3.1.1: - resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==} - engines: {node: '>=8'} + picocolors@1.0.0: + resolution: {integrity: sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==} - strnum@2.2.3: - resolution: {integrity: sha512-oKx6RUCuHfT3oyVjtnrmn19H1SiCqgJSg+54XqURKp5aCMbrXrhLjRN9TjuwMjiYstZ0MzDrHqkGZ5dFTKd+zg==} + picocolors@1.1.0: + resolution: {integrity: sha512-TQ92mBOW0l3LeMeyLV6mzy/kWr8lkd/hp3mTg7wYK7zJhuBStmGMBG0BdeDZS/dZx1IukaX6Bk11zcln25o1Aw==} - styled-jsx@5.1.6: - resolution: {integrity: sha512-qSVyDTeMotdvQYoHWLNGwRFJHC+i+ZvdBRYosOFgC+Wg1vx4frN2/RG/NA7SYqqvKNLf39P2LSRA2pu6n0XYZA==} - engines: {node: '>= 12.0.0'} - peerDependencies: - '@babel/core': '*' - babel-plugin-macros: '*' - react: '>= 16.8.0 || 17.x.x || ^18.0.0-0 || ^19.0.0-0' - peerDependenciesMeta: - '@babel/core': - optional: true - babel-plugin-macros: - optional: true + picocolors@1.1.1: + resolution: {integrity: sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==} - superstruct@1.0.4: - resolution: {integrity: sha512-7JpaAoX2NGyoFlI9NBh66BQXGONc+uE+MRS5i2iOBKuS4e+ccgMDjATgZldkah+33DakBxDHiss9kvUcGAO8UQ==} - engines: {node: '>=14.0.0'} + picomatch@2.3.1: + resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} + engines: {node: '>=8.6'} - supports-color@3.2.3: - resolution: {integrity: sha512-Jds2VIYDrlp5ui7t8abHN2bjAu4LV/q4N2KivFPpGH0lrka0BMq/33AmECUXlKPcHigkNaqfXRENFju+rlcy+A==} - engines: {node: '>=0.8.0'} + picomatch@4.0.2: + resolution: {integrity: sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg==} + engines: {node: '>=12'} - supports-color@5.5.0: - resolution: {integrity: sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==} + picomatch@4.0.3: + resolution: {integrity: sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==} + engines: {node: '>=12'} + + pify@3.0.0: + resolution: {integrity: sha512-C3FsVNH1udSEX48gGX1xfvwTWfsYWj5U+8/uK15BGzIGrKoUpghX8hWZwa/OFnakBiiVNmBvemTJR5mcy7iPcg==} engines: {node: '>=4'} - supports-color@7.2.0: - resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} - engines: {node: '>=8'} + pify@4.0.1: + resolution: {integrity: sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==} + engines: {node: '>=6'} - supports-color@8.1.1: - resolution: {integrity: sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==} + pify@5.0.0: + resolution: {integrity: sha512-eW/gHNMlxdSP6dmG6uJip6FXN0EQBwm2clYYd8Wul42Cwu/DK8HEftzsapcNdYe2MfLiIwZqsDk2RDEsTE79hA==} engines: {node: '>=10'} - supports-preserve-symlinks-flag@1.0.0: - resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==} - engines: {node: '>= 0.4'} - - swap-case@1.1.2: - resolution: {integrity: sha512-BAmWG6/bx8syfc6qXPprof3Mn5vQgf5dwdUNJhsNqU9WdPt5P+ES/wQ5bxfijy8zwZgZZHslC3iAsxsuQMCzJQ==} - - swarm-js@0.1.42: - resolution: {integrity: sha512-BV7c/dVlA3R6ya1lMlSSNPLYrntt0LUq4YMgy3iwpCIc6rZnS5W2wUoctarZ5pXlpKtxDDf9hNziEkcfrxdhqQ==} + pino-abstract-transport@0.5.0: + resolution: {integrity: sha512-+KAgmVeqXYbTtU2FScx1XS3kNyfZ5TrXY07V96QnUSFqo2gAqlvmaxH67Lj7SWazqsMabf+58ctdTcBgnOLUOQ==} - symbol-observable@1.2.0: - resolution: {integrity: sha512-e900nM8RRtGhlV36KGEU9k65K3mPb1WV70OdjfxlG2EAuM1noi/E/BaW/uMhL7bPEssK8QV57vN3esixjUvcXQ==} - engines: {node: '>=0.10.0'} - - sync-request@6.1.0: - resolution: {integrity: sha512-8fjNkrNlNCrVc/av+Jn+xxqfCjYaBoHqCsDz6mt030UMxJGr+GSfCV1dQt2gRtlL63+VPidwDVLr7V2OcTSdRw==} - engines: {node: '>=8.0.0'} - - sync-rpc@1.3.6: - resolution: {integrity: sha512-J8jTXuZzRlvU7HemDgHi3pGnh/rkoqR/OZSjhTyyZrEkkYQbk7Z33AXp37mkPfPpfdOuj7Ex3H/TJM1z48uPQw==} + pino-abstract-transport@2.0.0: + resolution: {integrity: sha512-F63x5tizV6WCh4R6RHyi2Ml+M70DNRXt/+HANowMflpgGFMAym/VKm6G7ZOQRjqN7XbGxK1Lg9t6ZrtzOaivMw==} - syncpack-darwin-arm64@14.3.0: - resolution: {integrity: sha512-gpbkBzO7yqa3BONc4EU3jY07yiPSZdoAxcpnz8REV9Bc6FkmKfOejCpYIh8RaogGPS4gOLJ/RUJEECqAaHTcjA==} - cpu: [arm64] - os: [darwin] + pino-pretty@13.0.0: + resolution: {integrity: sha512-cQBBIVG3YajgoUjo1FdKVRX6t9XPxwB9lcNJVD5GCnNM4Y6T12YYx8c6zEejxQsU0wrg9TwmDulcE9LR7qcJqA==} + hasBin: true - syncpack-darwin-x64@14.3.0: - resolution: {integrity: sha512-wTpl6Qj5qGIHrYhpCrlNnosmhQqvUoidqqmxtdM3f+j+b+OkTtpkUl2tdE28h3aeEEUPf9ClQnHuwRJMYNlrJw==} - cpu: [x64] - os: [darwin] + pino-std-serializers@4.0.0: + resolution: {integrity: sha512-cK0pekc1Kjy5w9V2/n+8MkZwusa6EyyxfeQCB799CQRhRt/CqYKiWs5adeu8Shve2ZNffvfC/7J64A2PJo1W/Q==} - syncpack-linux-arm64-musl@14.3.0: - resolution: {integrity: sha512-AezJ5dv0s+l/p1l4/wBatYhM6SZEKLcyNKggSOX5uISzqbSKwj/Aak13pBXWarzS+N6LnOl4PMcwRMJPOUfN/g==} - cpu: [arm64] - os: [linux] + pino@7.11.0: + resolution: {integrity: sha512-dMACeu63HtRLmCG8VKdy4cShCPKaYDR4youZqoSWLxl5Gu99HUw8bw75thbPv9Nip+H+QYX8o3ZJbTdVZZ2TVg==} + hasBin: true - syncpack-linux-arm64@14.3.0: - resolution: {integrity: sha512-Vcf9zWkJGRqb5mGPKi9E+s/mB/Tw08LmKGRaiyKJjK8bhd1Ds65O8A2lOidy3jg0NOOojqREmDsli74Xd0z6KA==} - cpu: [arm64] - os: [linux] + pkg-types@1.1.0: + resolution: {integrity: sha512-/RpmvKdxKf8uILTtoOhAgf30wYbP2Qw+L9p3Rvshx1JZVX+XQNZQFjlbmGHEGIm4CkVPlSn+NXmIM8+9oWQaSA==} - syncpack-linux-x64-musl@14.3.0: - resolution: {integrity: sha512-tIRF0lvBJcoIwcO05/Q6j30CAg0jzn+A5eQL+06Ncq8CE5i8fBWrVwN1U/QQ4fzT+tondNWH/2BR5zlaB1VUpQ==} - cpu: [x64] - os: [linux] + pkg-types@1.1.1: + resolution: {integrity: sha512-ko14TjmDuQJ14zsotODv7dBlwxKhUKQEhuhmbqo1uCi9BB0Z2alo/wAXg6q1dTR5TyuqYyWhjtfe/Tsh+X28jQ==} - syncpack-linux-x64@14.3.0: - resolution: {integrity: sha512-n/4iBJnoOCe5An+WYlaqfSxOKQ7Id3TZTpxOpI60Cucq3yqwq0JHQUielj6JBtVaxvo2rAsTwbCLyp2aB0SD2g==} - cpu: [x64] - os: [linux] + pkg-types@1.3.1: + resolution: {integrity: sha512-/Jm5M4RvtBFVkKWRu2BLUTNP8/M2a+UwuAX+ae4770q1qVGtfjG+WTCupoZixokjmHiry8uI+dlY8KXYV5HVVQ==} - syncpack-windows-arm64@14.3.0: - resolution: {integrity: sha512-ZTX0rSUTJZjIde3qPKLEqU7IEt4KxFsmq6gKLfESx5rB1rxk/B1Ljv6nTYph5QVItEzHQHUXDWnqa9yCb15myw==} - cpu: [arm64] - os: [win32] + pkg-types@2.3.0: + resolution: {integrity: sha512-SIqCzDRg0s9npO5XQ3tNZioRY1uK06lA41ynBC1YmFTmnY6FjUjVt6s4LoADmwoig1qqD0oK8h1p/8mlMx8Oig==} - syncpack-windows-x64@14.3.0: - resolution: {integrity: sha512-zvbphZw40wFZYeEW2oJYqA9Uw6IOwNIpgFmVNdWdGmShPF/Zu1cavHEcGwtQmvVzwuTEyiu67uxQ3hDC2q6vtg==} - cpu: [x64] - os: [win32] + pngjs@5.0.0: + resolution: {integrity: sha512-40QW5YalBNfQo5yRYmiw7Yz6TKKVr3h6970B2YE+3fQpsWcrbj1PzJgxeJ19DRQjhMbKPIuMY8rFaXc8moolVw==} + engines: {node: '>=10.13.0'} - syncpack@14.3.0: - resolution: {integrity: sha512-8/WtPPxxGFqE21JPFz6Bpw0m9BT3lzMYDcewJFj++EBPmCaDWowTnx0R4V7ofH/1z3HAIaAps6g2GHL76l1Y2g==} - engines: {node: '>=14.17.0'} - hasBin: true + pony-cause@2.1.11: + resolution: {integrity: sha512-M7LhCsdNbNgiLYiP4WjsfLUuFmCfnjdF6jKe2R9NKl4WFN+HZPGHJZ9lnLP7f9ZnKe3U9nuWD0szirmj+migUg==} + engines: {node: '>=12.0.0'} - table-layout@1.0.2: - resolution: {integrity: sha512-qd/R7n5rQTRFi+Zf2sk5XVVd9UQl6ZkduPFC3S7WEGJAmetDTjY3qPN50eSKzwuzEyQKy5TN2TiZdkIjos2L6A==} - engines: {node: '>=8.0.0'} + possible-typed-array-names@1.1.0: + resolution: {integrity: sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg==} + engines: {node: '>= 0.4'} - table@6.9.0: - resolution: {integrity: sha512-9kY+CygyYM6j02t5YFHbNz2FN5QmYGv9zAjVp4lCDjlCw7amdckXlEt/bjMhUIfj4ThGRE4gCUH5+yGnNuPo5A==} - engines: {node: '>=10.0.0'} + postcss-calc@10.1.1: + resolution: {integrity: sha512-NYEsLHh8DgG/PRH2+G9BTuUdtf9ViS+vdoQ0YA5OQdGsfN4ztiwtDWNtBl9EKeqNMFnIu8IKZ0cLxEQ5r5KVMw==} + engines: {node: ^18.12 || ^20.9 || >=22.0} + peerDependencies: + postcss: ^8.4.38 - tar@7.5.13: - resolution: {integrity: sha512-tOG/7GyXpFevhXVh8jOPJrmtRpOTsYqUIkVdVooZYJS/z8WhfQUX8RJILmeuJNinGAMSu1veBr4asSHFt5/hng==} - engines: {node: '>=18'} + postcss-colormin@7.0.5: + resolution: {integrity: sha512-ekIBP/nwzRWhEMmIxHHbXHcMdzd1HIUzBECaj5KEdLz9DVP2HzT065sEhvOx1dkLjYW7jyD0CngThx6bpFi2fA==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - term-size@2.2.1: - resolution: {integrity: sha512-wK0Ri4fOGjv/XPy8SBHZChl8CM7uMc5VML7SqiQ0zG7+J5Vr+RMQDoHa2CNT6KHUnTGIXH34UDMkPzAUyapBZg==} - engines: {node: '>=8'} + postcss-convert-values@7.0.8: + resolution: {integrity: sha512-+XNKuPfkHTCEo499VzLMYn94TiL3r9YqRE3Ty+jP7UX4qjewUONey1t7CG21lrlTLN07GtGM8MqFVp86D4uKJg==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - test-exclude@6.0.0: - resolution: {integrity: sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w==} - engines: {node: '>=8'} + postcss-discard-comments@7.0.5: + resolution: {integrity: sha512-IR2Eja8WfYgN5n32vEGSctVQ1+JARfu4UH8M7bgGh1bC+xI/obsPJXaBpQF7MAByvgwZinhpHpdrmXtvVVlKcQ==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - testrpc@0.0.1: - resolution: {integrity: sha512-afH1hO+SQ/VPlmaLUFj2636QMeDvPCeQMc/9RBMW0IfjNe9gFD9Ra3ShqYkB7py0do1ZcCna/9acHyzTJ+GcNA==} - deprecated: testrpc has been renamed to ganache-cli, please use this package from now on. + postcss-discard-duplicates@7.0.2: + resolution: {integrity: sha512-eTonaQvPZ/3i1ASDHOKkYwAybiM45zFIc7KXils4mQmHLqIswXD9XNOKEVxtTFnsmwYzF66u4LMgSr0abDlh5w==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - text-table@0.2.0: - resolution: {integrity: sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==} + postcss-discard-empty@7.0.1: + resolution: {integrity: sha512-cFrJKZvcg/uxB6Ijr4l6qmn3pXQBna9zyrPC+sK0zjbkDUZew+6xDltSF7OeB7rAtzaaMVYSdbod+sZOCWnMOg==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - then-request@6.0.2: - resolution: {integrity: sha512-3ZBiG7JvP3wbDzA9iNY5zJQcHL4jn/0BWtXIkagfz7QgOL/LqjCEOBQuJNZfu0XYnv5JhKh+cDxCPM4ILrqruA==} - engines: {node: '>=6.0.0'} + postcss-discard-overridden@7.0.1: + resolution: {integrity: sha512-7c3MMjjSZ/qYrx3uc1940GSOzN1Iqjtlqe8uoSg+qdVPYyRb0TILSqqmtlSFuE4mTDECwsm397Ya7iXGzfF7lg==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - threads@1.7.0: - resolution: {integrity: sha512-Mx5NBSHX3sQYR6iI9VYbgHKBLisyB+xROCBGjjWm1O9wb9vfLxdaGtmT/KCjUqMsSNW6nERzCW3T6H43LqjDZQ==} + postcss-merge-longhand@7.0.5: + resolution: {integrity: sha512-Kpu5v4Ys6QI59FxmxtNB/iHUVDn9Y9sYw66D6+SZoIk4QTz1prC4aYkhIESu+ieG1iylod1f8MILMs1Em3mmIw==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - through2@4.0.2: - resolution: {integrity: sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==} + postcss-merge-rules@7.0.7: + resolution: {integrity: sha512-njWJrd/Ms6XViwowaaCc+/vqhPG3SmXn725AGrnl+BgTuRPEacjiLEaGq16J6XirMJbtKkTwnt67SS+e2WGoew==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - through@2.3.8: - resolution: {integrity: sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==} + postcss-minify-font-values@7.0.1: + resolution: {integrity: sha512-2m1uiuJeTplll+tq4ENOQSzB8LRnSUChBv7oSyFLsJRtUgAAJGP6LLz0/8lkinTgxrmJSPOEhgY1bMXOQ4ZXhQ==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - timed-out@4.0.1: - resolution: {integrity: sha512-G7r3AhovYtr5YKOWQkta8RKAPb+J9IsO4uVmzjl8AZwfhs8UcUwTiD6gcJYSgOtzyjvQKrKYn41syHbUWMkafA==} - engines: {node: '>=0.10.0'} + postcss-minify-gradients@7.0.1: + resolution: {integrity: sha512-X9JjaysZJwlqNkJbUDgOclyG3jZEpAMOfof6PUZjPnPrePnPG62pS17CjdM32uT1Uq1jFvNSff9l7kNbmMSL2A==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tiny-worker@2.3.0: - resolution: {integrity: sha512-pJ70wq5EAqTAEl9IkGzA+fN0836rycEuz2Cn6yeZ6FRzlVS5IDOkFHpIoEsksPRQV34GDqXm65+OlnZqUSyK2g==} + postcss-minify-params@7.0.5: + resolution: {integrity: sha512-FGK9ky02h6Ighn3UihsyeAH5XmLEE2MSGH5Tc4tXMFtEDx7B+zTG6hD/+/cT+fbF7PbYojsmmWjyTwFwW1JKQQ==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tinybench@2.9.0: - resolution: {integrity: sha512-0+DUvqWMValLmha6lr4kD8iAMK1HzV0/aKnCtWb9v9641TnP/MFb7Pc2bxoxQjTXAErryXVgUOfv2YqNllqGeg==} + postcss-minify-selectors@7.0.5: + resolution: {integrity: sha512-x2/IvofHcdIrAm9Q+p06ZD1h6FPcQ32WtCRVodJLDR+WMn8EVHI1kvLxZuGKz/9EY5nAmI6lIQIrpo4tBy5+ug==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tinycolor2@1.6.0: - resolution: {integrity: sha512-XPaBkWQJdsf3pLKJV9p4qN/S+fm2Oj8AIPo1BTUhg5oxkvm9+SVEGFdhyOz7tTdUTfvxMiAs4sp6/eZO2Ew+pw==} + postcss-normalize-charset@7.0.1: + resolution: {integrity: sha512-sn413ofhSQHlZFae//m9FTOfkmiZ+YQXsbosqOWRiVQncU2BA3daX3n0VF3cG6rGLSFVc5Di/yns0dFfh8NFgQ==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tinyexec@1.0.2: - resolution: {integrity: sha512-W/KYk+NFhkmsYpuHq5JykngiOCnxeVL8v8dFnqxSD8qEEdRfXk1SDM6JzNqcERbcGYj9tMrDQBYV9cjgnunFIg==} - engines: {node: '>=18'} + postcss-normalize-display-values@7.0.1: + resolution: {integrity: sha512-E5nnB26XjSYz/mGITm6JgiDpAbVuAkzXwLzRZtts19jHDUBFxZ0BkXAehy0uimrOjYJbocby4FVswA/5noOxrQ==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tinyglobby@0.2.15: - resolution: {integrity: sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ==} - engines: {node: '>=12.0.0'} + postcss-normalize-positions@7.0.1: + resolution: {integrity: sha512-pB/SzrIP2l50ZIYu+yQZyMNmnAcwyYb9R1fVWPRxm4zcUFCY2ign7rcntGFuMXDdd9L2pPNUgoODDk91PzRZuQ==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tinyglobby@0.2.16: - resolution: {integrity: sha512-pn99VhoACYR8nFHhxqix+uvsbXineAasWm5ojXoN8xEwK5Kd3/TrhNn1wByuD52UxWRLy8pu+kRMniEi6Eq9Zg==} - engines: {node: '>=12.0.0'} + postcss-normalize-repeat-style@7.0.1: + resolution: {integrity: sha512-NsSQJ8zj8TIDiF0ig44Byo3Jk9e4gNt9x2VIlJudnQQ5DhWAHJPF4Tr1ITwyHio2BUi/I6Iv0HRO7beHYOloYQ==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tinygradient@1.1.5: - resolution: {integrity: sha512-8nIfc2vgQ4TeLnk2lFj4tRLvvJwEfQuabdsmvDdQPT0xlk9TaNtpGd6nNRxXoK6vQhN6RSzj+Cnp5tTQmpxmbw==} + postcss-normalize-string@7.0.1: + resolution: {integrity: sha512-QByrI7hAhsoze992kpbMlJSbZ8FuCEc1OT9EFbZ6HldXNpsdpZr+YXC5di3UEv0+jeZlHbZcoCADgb7a+lPmmQ==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tinyrainbow@3.0.3: - resolution: {integrity: sha512-PSkbLUoxOFRzJYjjxHJt9xro7D+iilgMX/C9lawzVuYiIdcihh9DXmVibBe8lmcFrRi/VzlPjBxbN7rH24q8/Q==} - engines: {node: '>=14.0.0'} + postcss-normalize-timing-functions@7.0.1: + resolution: {integrity: sha512-bHifyuuSNdKKsnNJ0s8fmfLMlvsQwYVxIoUBnowIVl2ZAdrkYQNGVB4RxjfpvkMjipqvbz0u7feBZybkl/6NJg==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - title-case@2.1.1: - resolution: {integrity: sha512-EkJoZ2O3zdCz3zJsYCsxyq2OC5hrxR9mfdd5I+w8h/tmFfeOxJ+vvkxsKxdmN0WtS9zLdHEgfgVOiMVgv+Po4Q==} + postcss-normalize-unicode@7.0.5: + resolution: {integrity: sha512-X6BBwiRxVaFHrb2WyBMddIeB5HBjJcAaUHyhLrM2FsxSq5TFqcHSsK7Zu1otag+o0ZphQGJewGH1tAyrD0zX1Q==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tldts-core@6.1.86: - resolution: {integrity: sha512-Je6p7pkk+KMzMv2XXKmAE3McmolOQFdxkKw0R8EYNr7sELW46JqnNeTX8ybPiQgvg1ymCoF8LXs5fzFaZvJPTA==} + postcss-normalize-url@7.0.1: + resolution: {integrity: sha512-sUcD2cWtyK1AOL/82Fwy1aIVm/wwj5SdZkgZ3QiUzSzQQofrbq15jWJ3BA7Z+yVRwamCjJgZJN0I9IS7c6tgeQ==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tldts-core@7.0.28: - resolution: {integrity: sha512-7W5Efjhsc3chVdFhqtaU0KtK32J37Zcr9RKtID54nG+tIpcY79CQK/veYPODxtD/LJ4Lue66jvrQzIX2Z2/pUQ==} + postcss-normalize-whitespace@7.0.1: + resolution: {integrity: sha512-vsbgFHMFQrJBJKrUFJNZ2pgBeBkC2IvvoHjz1to0/0Xk7sII24T0qFOiJzG6Fu3zJoq/0yI4rKWi7WhApW+EFA==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tldts@6.1.86: - resolution: {integrity: sha512-WMi/OQ2axVTf/ykqCQgXiIct+mSQDFdH2fkwhPwgEwvJ1kSzZRiinb0zF2Xb8u4+OqPChmyI6MEu4EezNJz+FQ==} - hasBin: true + postcss-ordered-values@7.0.2: + resolution: {integrity: sha512-AMJjt1ECBffF7CEON/Y0rekRLS6KsePU6PRP08UqYW4UGFRnTXNrByUzYK1h8AC7UWTZdQ9O3Oq9kFIhm0SFEw==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tldts@7.0.28: - resolution: {integrity: sha512-+Zg3vWhRUv8B1maGSTFdev9mjoo8Etn2Ayfs4cnjlD3CsGkxXX4QyW3j2WJ0wdjYcYmy7Lx2RDsZMhgCWafKIw==} - hasBin: true + postcss-reduce-initial@7.0.5: + resolution: {integrity: sha512-RHagHLidG8hTZcnr4FpyMB2jtgd/OcyAazjMhoy5qmWJOx1uxKh4ntk0Pb46ajKM0rkf32lRH4C8c9qQiPR6IA==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - tmp@0.2.5: - resolution: {integrity: sha512-voyz6MApa1rQGUxT3E+BK7/ROe8itEx7vD8/HEvt4xwXucvQ5G5oeEiHkmHZJuBO21RpOf+YYm9MOivj709jow==} - engines: {node: '>=14.14'} + postcss-reduce-transforms@7.0.1: + resolution: {integrity: sha512-MhyEbfrm+Mlp/36hvZ9mT9DaO7dbncU0CvWI8V93LRkY6IYlu38OPg3FObnuKTUxJ4qA8HpurdQOo5CyqqO76g==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - to-buffer@1.2.2: - resolution: {integrity: sha512-db0E3UJjcFhpDhAF4tLo03oli3pwl3dbnzXOUIlRKrp+ldk/VUxzpWYZENsw2SZiuBjHAk7DfB0VU7NKdpb6sw==} - engines: {node: '>= 0.4'} + postcss-selector-parser@7.1.1: + resolution: {integrity: sha512-orRsuYpJVw8LdAwqqLykBj9ecS5/cRHlI5+nvTo8LcCKmzDmqVORXtOIYEEQuL9D4BxtA1lm5isAqzQZCoQ6Eg==} + engines: {node: '>=4'} - to-regex-range@5.0.1: - resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} - engines: {node: '>=8.0'} + postcss-svgo@7.1.0: + resolution: {integrity: sha512-KnAlfmhtoLz6IuU3Sij2ycusNs4jPW+QoFE5kuuUOK8awR6tMxZQrs5Ey3BUz7nFCzT3eqyFgqkyrHiaU2xx3w==} + engines: {node: ^18.12.0 || ^20.9.0 || >= 18} + peerDependencies: + postcss: ^8.4.32 - toidentifier@1.0.1: - resolution: {integrity: sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==} - engines: {node: '>=0.6'} + postcss-unique-selectors@7.0.4: + resolution: {integrity: sha512-pmlZjsmEAG7cHd7uK3ZiNSW6otSZ13RHuZ/4cDN/bVglS5EpF2r2oxY99SuOHa8m7AWoBCelTS3JPpzsIs8skQ==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} + peerDependencies: + postcss: ^8.4.32 - touch@3.1.1: - resolution: {integrity: sha512-r0eojU4bI8MnHr8c5bNo7lJDdI2qXlWWJk6a9EAFG7vbhTjElYhBVS3/miuE0uOuoLdb8Mc/rVfsmm6eo5o9GA==} - hasBin: true + postcss-value-parser@4.2.0: + resolution: {integrity: sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==} - tough-cookie@5.1.2: - resolution: {integrity: sha512-FVDYdxtnj0G6Qm/DhNPSb8Ju59ULcup3tuJxkFb5K8Bv2pUXILbf0xZWU8PX8Ov19OXljbUyveOFwRMwkXzO+A==} - engines: {node: '>=16'} + postcss@8.4.31: + resolution: {integrity: sha512-PS08Iboia9mts/2ygV3eLpY5ghnUcfLV/EXTOW1E2qYxJKGGBUtNjN76FYHnMs36RmARn41bC0AZmn+rR0OVpQ==} + engines: {node: ^10 || ^12 || >=14} - tough-cookie@6.0.1: - resolution: {integrity: sha512-LktZQb3IeoUWB9lqR5EWTHgW/VTITCXg4D21M+lvybRVdylLrRMnqaIONLVb5mav8vM19m44HIcGq4qASeu2Qw==} - engines: {node: '>=16'} + postcss@8.4.47: + resolution: {integrity: sha512-56rxCq7G/XfB4EkXq9Egn5GCqugWvDFjafDOThIdMBsI15iqPqR5r15TfSr1YPYeEI19YeaXMCbY6u88Y76GLQ==} + engines: {node: ^10 || ^12 || >=14} - tr46@0.0.3: - resolution: {integrity: sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==} + postcss@8.5.6: + resolution: {integrity: sha512-3Ybi1tAuwAP9s0r1UQ2J4n5Y0G05bJkpUIO0/bI9MhwmD70S5aTWbXGBwxHrelT+XM1k6dM0pk+SwNkpTRN7Pg==} + engines: {node: ^10 || ^12 || >=14} - tr46@2.1.0: - resolution: {integrity: sha512-15Ih7phfcdP5YxqiB+iDtLoaTz4Nd35+IiAv0kQ5FNKHzXgdWqPoTIqEDDJmXceQt4JZk6lVPT8lnDlPpGDppw==} - engines: {node: '>=8'} + preact@10.17.1: + resolution: {integrity: sha512-X9BODrvQ4Ekwv9GURm9AKAGaomqXmip7NQTZgY7gcNmr7XE83adOMJvd3N42id1tMFU7ojiynRsYnY6/BRFxLA==} - tree-kill@1.2.2: - resolution: {integrity: sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==} - hasBin: true + preact@10.24.3: + resolution: {integrity: sha512-Z2dPnBnMUfyQfSQ+GBdsGa16hz35YmLmtTLhM169uW944hYL6xzTYkJjC07j+Wosz733pMWx0fgON3JNw1jJQA==} - ts-api-utils@2.5.0: - resolution: {integrity: sha512-OJ/ibxhPlqrMM0UiNHJ/0CKQkoKF243/AEmplt3qpRgkW8VG7IfOS41h7V8TjITqdByHzrjcS/2si+y4lIh8NA==} - engines: {node: '>=18.12'} + prettier-plugin-solidity@2.2.1: + resolution: {integrity: sha512-LOHfxECJ/gHsY7qi4D7vanz8cVsCf6yFotBapJ5O0qaX0ZR1sGUzbWfMd4JeQYOItFl+wXW9IcjZOdfr6bmSvQ==} + engines: {node: '>=20'} peerDependencies: - typescript: '>=4.8.4' + prettier: '>=3.0.0' - ts-command-line-args@2.5.1: - resolution: {integrity: sha512-H69ZwTw3rFHb5WYpQya40YAX2/w7Ut75uUECbgBIsLmM+BNuYnxsltfyyLMxy6sEeKxgijLTnQtLd0nKd6+IYw==} + prettier@2.8.8: + resolution: {integrity: sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==} + engines: {node: '>=10.13.0'} hasBin: true - ts-essentials@7.0.3: - resolution: {integrity: sha512-8+gr5+lqO3G84KdiTSMRLtuyJ+nTBVRKuCrK4lidMPdVeEp0uqC875uE5NMcaA7YYMN7XsNiFQuMvasF8HT/xQ==} - peerDependencies: - typescript: '>=3.7.0' + prettier@3.0.3: + resolution: {integrity: sha512-L/4pUDMxcNa8R/EthV08Zt42WBO4h1rarVtK0K+QJG0X187OLo7l699jWw0GKuwzkPQ//jMFA/8Xm6Fh3J/DAg==} + engines: {node: '>=14'} + hasBin: true - ts-node@10.9.2: - resolution: {integrity: sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ==} + prettier@3.7.4: + resolution: {integrity: sha512-v6UNi1+3hSlVvv8fSaoUbggEM5VErKmmpGA7Pl3HF8V6uKY7rvClBOJlH6yNwQtfTueNkGVpOv/mtWL9L4bgRA==} + engines: {node: '>=14'} hasBin: true - peerDependencies: - '@swc/core': '>=1.2.50' - '@swc/wasm': '>=1.2.50' - '@types/node': '*' - typescript: '>=2.7' - peerDependenciesMeta: - '@swc/core': - optional: true - '@swc/wasm': - optional: true - tsconfig-paths@3.15.0: - resolution: {integrity: sha512-2Ac2RgzDe/cn48GvOe3M+o82pEFewD3UPbyoUHHdKasHwJKjds4fLXWf/Ux5kATBKN20oaFGu+jbElp1pos0mg==} + pretty-bytes@7.1.0: + resolution: {integrity: sha512-nODzvTiYVRGRqAOvE84Vk5JDPyyxsVk0/fbA/bq7RqlnhksGpset09XTxbpvLTIjoaF7K8Z8DG8yHtKGTPSYRw==} + engines: {node: '>=20'} - tslib@1.14.1: - resolution: {integrity: sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==} + pretty-format@27.5.1: + resolution: {integrity: sha512-Qb1gy5OrP5+zDf2Bvnzdl3jsTf1qXVMazbvCoKhtKqVs4/YK4ozX4gKQJJVyNe+cajNPn0KoC0MC3FUmaHWEmQ==} + engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} - tslib@2.7.0: - resolution: {integrity: sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA==} + pretty-ms@7.0.1: + resolution: {integrity: sha512-973driJZvxiGOQ5ONsFhOF/DtzPMOMtgC11kCpUrPGMTgqp2q/1gwzCquocrN33is0VZ5GFHXZYMM9l6h67v2Q==} + engines: {node: '>=10'} - tslib@2.8.1: - resolution: {integrity: sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==} + pretty-ms@9.0.0: + resolution: {integrity: sha512-E9e9HJ9R9NasGOgPaPE8VMeiPKAyWR5jcFpNnwIejslIhWqdqOrb2wShBsncMPUb+BcCd2OPYfh7p2W6oemTng==} + engines: {node: '>=18'} - tslog@4.10.2: - resolution: {integrity: sha512-XuELoRpMR+sq8fuWwX7P0bcj+PRNiicOKDEb3fGNURhxWVyykCi9BNq7c4uVz7h7P0sj8qgBsr5SWS6yBClq3g==} - engines: {node: '>=16'} + process-nextick-args@2.0.1: + resolution: {integrity: sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==} - tsort@0.0.1: - resolution: {integrity: sha512-Tyrf5mxF8Ofs1tNoxA13lFeZ2Zrbd6cKbuH3V+MQ5sb6DtBj5FjrXVsRWT8YvNAQTqNoz66dz1WsbigI22aEnw==} + process-warning@1.0.0: + resolution: {integrity: sha512-du4wfLyj4yCZq1VupnVSZmRsPJsNuxoDQFdCFHLaYiEbFBD7QE0a+I4D7hOxrVnh78QE/YipFAj9lXHiXocV+Q==} - tunnel-agent@0.6.0: - resolution: {integrity: sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==} + process@0.11.10: + resolution: {integrity: sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A==} + engines: {node: '>= 0.6.0'} - turbo@2.9.6: - resolution: {integrity: sha512-+v2QJey7ZUeUiuigkU+uFfklvNUyPI2VO2vBpMYJA+a1hKFLFiKtUYlRHdb3P9CrAvMzi0upbjI4WT+zKtqkBg==} - hasBin: true + promisepipe@3.0.0: + resolution: {integrity: sha512-V6TbZDJ/ZswevgkDNpGt/YqNCiZP9ASfgU+p83uJE6NrGtvSGoOcHLiDCqkMs2+yg7F5qHdLV8d0aS8O26G/KA==} - tweetnacl-util@0.15.1: - resolution: {integrity: sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==} + prompts@2.4.2: + resolution: {integrity: sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==} + engines: {node: '>= 6'} - tweetnacl@0.14.5: - resolution: {integrity: sha512-KXXFFdAbFXY4geFIwoyNK+f5Z1b7swfXABfL7HXCmoIWMKU3dmS26672A4EeQtDzLKy7SXmfBu51JolvEKwtGA==} + prool@0.0.23: + resolution: {integrity: sha512-r1d0DIiVsp7aXqGiNGKmgrqJZa8GjMGEjsgjQO22DEClYYvK+HMPZTQ9diBqleGuwfiRk3lnsWRMbFTRmFbk9g==} + engines: {node: '>=22'} + peerDependencies: + '@pimlico/alto': '*' + peerDependenciesMeta: + '@pimlico/alto': + optional: true - tweetnacl@1.0.3: - resolution: {integrity: sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==} + property-information@6.5.0: + resolution: {integrity: sha512-PgTgs/BlvHxOu8QuEN7wi5A0OmXaBcHpmCSTehcs6Uuu9IkDIEo13Hy7n898RHfrQ49vKCoGeWZSaAK01nwVig==} - type-check@0.3.2: - resolution: {integrity: sha512-ZCmOJdvOWDBYJlzAoFkC+Q0+bUyEOS1ltgp1MGU03fqHG+dbi9tBFU2Rd9QKiDZFAYrhPh2JUf7rZRIuHRKtOg==} - engines: {node: '>= 0.8.0'} + proto-list@1.2.4: + resolution: {integrity: sha512-vtK/94akxsTMhe0/cbfpR+syPuszcuwhqVjJq26CuNDgFGj682oRBXOP5MJpv2r7JtE8MsiepGIqvvOTBwn2vA==} - type-check@0.4.0: - resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} - engines: {node: '>= 0.8.0'} + protocols@2.0.2: + resolution: {integrity: sha512-hHVTzba3wboROl0/aWRRG9dMytgH6ow//STBZh43l/wQgmMhYhOFi0EHWAPtoCz9IAUymsyP0TSBHkhgMEGNnQ==} - type-detect@4.1.0: - resolution: {integrity: sha512-Acylog8/luQ8L7il+geoSxhEkazvkslg7PSNKOX59mbB9cOveP5aq9h74Y7YU8yDpJwetzQQrfIwtf4Wp4LKcw==} - engines: {node: '>=4'} + proxy-compare@2.6.0: + resolution: {integrity: sha512-8xuCeM3l8yqdmbPoYeLbrAXCBWu19XEYc5/F28f5qOaoAIMyfmBUkl5axiK+x9olUvRlcekvnm98AP9RDngOIw==} - type-fest@0.20.2: - resolution: {integrity: sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==} - engines: {node: '>=10'} + pseudomap@1.0.2: + resolution: {integrity: sha512-b/YwNhb8lk1Zz2+bXXpS/LK9OisiZZ1SNsSLxN1x2OXVEhW2Ckr/7mWE5vrC1ZTiJlD9g19jWszTmJsB+oEpFQ==} - type-fest@0.21.3: - resolution: {integrity: sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==} - engines: {node: '>=10'} + psl@1.9.0: + resolution: {integrity: sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag==} - type-fest@0.7.1: - resolution: {integrity: sha512-Ne2YiiGN8bmrmJJEuTWTLJR32nh/JdL1+PSicowtNb0WFpn59GK8/lfD61bVtzguz7b3PBt74nxpv/Pw5po5Rg==} - engines: {node: '>=8'} + publint@0.3.12: + resolution: {integrity: sha512-1w3MMtL9iotBjm1mmXtG3Nk06wnq9UhGNRpQ2j6n1Zq7YAD6gnxMMZMIxlRPAydVjVbjSm+n0lhwqsD1m4LD5w==} + engines: {node: '>=18'} + hasBin: true - type-fest@0.8.1: - resolution: {integrity: sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==} - engines: {node: '>=8'} + pump@3.0.2: + resolution: {integrity: sha512-tUPXtzlGM8FE3P0ZL6DVs/3P58k9nk8/jZeQCurTJylQA8qFYzHFfhBJkuqyE0FifOsQ0uKWekiZ5g8wtr28cw==} - type-is@1.6.18: - resolution: {integrity: sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==} - engines: {node: '>= 0.6'} + pump@3.0.3: + resolution: {integrity: sha512-todwxLMY7/heScKmntwQG8CXVkWUOdYxIvY2s0VWAAMh/nd8SoYiRaKjlr7+iCs984f2P8zvrfWcDDYVb73NfA==} - type@2.7.3: - resolution: {integrity: sha512-8j+1QmAbPvLZow5Qpi6NCaN8FB60p/6x8/vfNqOk/hC+HuvFZhL4+WfekuhQLiqFZXOgQdrs3B+XxEmCc6b3FQ==} + punycode@2.3.1: + resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==} + engines: {node: '>=6'} - typechain@8.3.2: - resolution: {integrity: sha512-x/sQYr5w9K7yv3es7jo4KTX05CLxOf7TRWwoHlrjRh8H82G64g+k7VuWPJlgMo6qrjfCulOdfBjiaDtmhFYD/Q==} + qrcode@1.5.3: + resolution: {integrity: sha512-puyri6ApkEHYiVl4CFzo1tDkAZ+ATcnbJrJ6RiBM1Fhctdn/ix9MTE3hRph33omisEbC/2fcfemsseiKgBPKZg==} + engines: {node: '>=10.13.0'} hasBin: true - peerDependencies: - typescript: '>=4.3.0' - typed-array-buffer@1.0.3: - resolution: {integrity: sha512-nAYYwfY3qnzX30IkA6AQZjVbtK6duGontcQm1WSG1MD94YLqK0515GNApXkoxKOWMusVssAHWLh9SeaoefYFGw==} - engines: {node: '>= 0.4'} + quansync@0.2.11: + resolution: {integrity: sha512-AifT7QEbW9Nri4tAwR5M/uzpBuqfZf+zwaEM/QkzEjj7NBuFD2rBuy0K3dE+8wltbezDV7JMA0WfnCPYRSYbXA==} - typed-array-byte-length@1.0.3: - resolution: {integrity: sha512-BaXgOuIxz8n8pIq3e7Atg/7s+DpiYrxn4vdot3w9KbnBhcRQq6o3xemQdIfynqSeXeDrF32x+WvfzmOjPiY9lg==} - engines: {node: '>= 0.4'} + query-string@7.1.3: + resolution: {integrity: sha512-hh2WYhq4fi8+b+/2Kg9CEge4fDPvHS534aOOvOZeQ3+Vf2mCFsaFBYj0i+iXcAq6I9Vzp5fjMFBlONvayDC1qg==} + engines: {node: '>=6'} - typed-array-byte-offset@1.0.4: - resolution: {integrity: sha512-bTlAFB/FBYMcuX81gbL4OcpH5PmlFHqlCCpAl8AlEzMz5k53oNDvN8p1PNOWLEmI2x4orp3raOFB51tv9X+MFQ==} - engines: {node: '>= 0.4'} + querystringify@2.2.0: + resolution: {integrity: sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==} - typed-array-length@1.0.7: - resolution: {integrity: sha512-3KS2b+kL7fsuk/eJZ7EQdnEmQoaho/r6KUef7hxvltNA5DR8NAUM+8wJMbJyZ4G9/7i3v5zPBIMN5aybAh2/Jg==} - engines: {node: '>= 0.4'} + queue-microtask@1.2.3: + resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==} - typed-error@3.2.3: - resolution: {integrity: sha512-xmXIbAyEOYeRg11jY3AzjyB9clkxVfzBlHs3JgD3N6vPMMVBX+xNtQft4pKb1oM9lASdTISA+pOj1EejFr2SgQ==} - engines: {node: '>=6.0.0', npm: '>=3.0.0'} + quick-format-unescaped@4.0.4: + resolution: {integrity: sha512-tYC1Q1hgyRuHgloV/YXs2w15unPVh8qfu/qCTfhTYamaw7fyhumKa2yGpdSo87vY32rIclj+4fWYQXUMs9EHvg==} - typedarray-to-buffer@3.1.5: - resolution: {integrity: sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==} + radix3@1.1.2: + resolution: {integrity: sha512-b484I/7b8rDEdSDKckSSBA8knMpcdsXudlE/LNL639wFoHKwLbEkQFZHWEYwDC0wa0FKUcCY+GAF73Z7wxNVFA==} - typedarray@0.0.6: - resolution: {integrity: sha512-/aCDEGatGvZ2BIk+HmLf4ifCJFwvKFNb9/JeZPMulfgFracn9QFcAf5GO8B/mweUjSoblS5In0cWhqpfs/5PQA==} + randombytes@2.1.0: + resolution: {integrity: sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==} - typescript-eslint@8.50.0: - resolution: {integrity: sha512-Q1/6yNUmCpH94fbgMUMg2/BSAr/6U7GBk61kZTv1/asghQOWOjTlp9K8mixS5NcJmm2creY+UFfGeW/+OcA64A==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - eslint: ^8.57.0 || ^9.0.0 - typescript: '>=4.8.4 <6.0.0' + range-parser@1.2.1: + resolution: {integrity: sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==} + engines: {node: '>= 0.6'} - typescript@4.9.5: - resolution: {integrity: sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==} - engines: {node: '>=4.2.0'} - hasBin: true + raw-body@2.4.1: + resolution: {integrity: sha512-9WmIKF6mkvA0SLmA2Knm9+qj89e+j1zqgyn8aXGd7+nAduPoqgI9lO57SAZNn/Byzo5P7JhXTyg9PzaJbH73bA==} + engines: {node: '>= 0.8'} - typescript@5.9.3: - resolution: {integrity: sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==} - engines: {node: '>=14.17'} - hasBin: true + raw-body@2.5.1: + resolution: {integrity: sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==} + engines: {node: '>= 0.8'} - typeson-registry@1.0.0-alpha.39: - resolution: {integrity: sha512-NeGDEquhw+yfwNhguLPcZ9Oj0fzbADiX4R0WxvoY8nGhy98IbzQy1sezjoEFWOywOboj/DWehI+/aUlRVrJnnw==} - engines: {node: '>=10.0.0'} + rc9@2.1.2: + resolution: {integrity: sha512-btXCnMmRIBINM2LDZoEmOogIZU7Qe7zn4BpomSKZ/ykbLObuBdvG+mFq11DL6fjH1DRwHhrlgtYWG96bJiC7Cg==} - typeson@6.1.0: - resolution: {integrity: sha512-6FTtyGr8ldU0pfbvW/eOZrEtEkczHRUtduBnA90Jh9kMPCiFNnXIon3vF41N0S4tV1HHQt4Hk1j4srpESziCaA==} - engines: {node: '>=0.1.14'} + react-apple-signin-auth@1.1.2: + resolution: {integrity: sha512-E5bPu4LtNR3IDsd08A/f1Y0HyuHfjqQpRNRCtQQ3JSVby2JK50FoixyK8EwUh6cbu8N4qrJStL77dEb51Ny5uA==} + peerDependencies: + react: '>= 16.8.0' + react-dom: '>= 16.8.0' - typical@4.0.0: - resolution: {integrity: sha512-VAH4IvQ7BDFYglMd7BPRDfLgxZZX4O4TFcRDA6EN5X7erNJJq+McIEp8np9aVtxrCJ6qx4GTYVfOWNjcqwZgRw==} - engines: {node: '>=8'} + react-dom@18.3.1: + resolution: {integrity: sha512-5m4nQKp+rZRb09LNH59GM4BxTh9251/ylbKIbpe7TpGxfJ+9kv6BLkLBXIjjspbgbnIBNqlI23tRnTWT0snUIw==} + peerDependencies: + react: ^18.3.1 - typical@5.2.0: - resolution: {integrity: sha512-dvdQgNDNJo+8B2uBQoqdb11eUCE1JQXhvjC/CZtgvZseVd5TYMXnq0+vuUemXbd/Se29cTaUuPX3YIc2xgbvIg==} - engines: {node: '>=8'} + react-hook-form@7.69.0: + resolution: {integrity: sha512-yt6ZGME9f4F6WHwevrvpAjh42HMvocuSnSIHUGycBqXIJdhqGSPQzTpGF+1NLREk/58IdPxEMfPcFCjlMhclGw==} + engines: {node: '>=18.0.0'} + peerDependencies: + react: ^16.8.0 || ^17 || ^18 || ^19 - uglify-js@3.19.3: - resolution: {integrity: sha512-v3Xu+yuwBXisp6QYTcH4UbH+xYJXqnq2m/LtQVWKWzYc1iehYnLixoQDN9FH6/j9/oybfd6W9Ghwkl8+UMKTKQ==} - engines: {node: '>=0.8.0'} - hasBin: true + react-is@17.0.2: + resolution: {integrity: sha512-w2GsyukL62IJnlaff/nRegPQR94C/XXamvMWmSHRJ4y7Ts/4ocGRmTHvOs8PSE6pB3dWOrD/nueuU5sduBsQ4w==} - unbox-primitive@1.1.0: - resolution: {integrity: sha512-nWJ91DjeOkej/TA8pXQ3myruKpKEYgqvpw9lz4OPHj/NWFNluYrjbz9j01CJ8yKQd2g4jFoOkINCTW2I5LEEyw==} - engines: {node: '>= 0.4'} + react-refresh@0.14.0: + resolution: {integrity: sha512-wViHqhAd8OHeLS/IRMJjTSDHF3U9eWi62F/MledQGPdJGDhodXJ9PBLNGr6WWL7qlH12Mt3TyTpbS+hGXMjCzQ==} + engines: {node: '>=0.10.0'} - undefsafe@2.0.5: - resolution: {integrity: sha512-WxONCrssBM8TSPRqN5EmsjVrsv4A8X12J4ArBiiayv3DyyG3ZlIg6yysuuSYdZsVz3TKcTg2fd//Ujd4CHV1iA==} + react-remove-scroll-bar@2.3.8: + resolution: {integrity: sha512-9r+yi9+mgU33AKcj6IbT9oRCO78WriSj6t/cF8DWBZJ9aOGPOTEDvdUDz1FwKim7QXWwmHqtdHnRJfhAxEG46Q==} + engines: {node: '>=10'} + peerDependencies: + '@types/react': '*' + react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 + peerDependenciesMeta: + '@types/react': + optional: true - undici-types@6.19.8: - resolution: {integrity: sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==} + react-remove-scroll@2.7.2: + resolution: {integrity: sha512-Iqb9NjCCTt6Hf+vOdNIZGdTiH1QSqr27H/Ek9sv/a97gfueI/5h1s3yRi1nngzMUaOOToin5dI1dXKdXiF+u0Q==} + engines: {node: '>=10'} + peerDependencies: + '@types/react': '*' + react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - undici-types@7.18.2: - resolution: {integrity: sha512-AsuCzffGHJybSaRrmr5eHr81mwJU3kjw6M+uprWvCXiNeN9SOGwQ3Jn8jb8m3Z6izVgknn1R0FTCEAP2QrLY/w==} + react-style-singleton@2.2.3: + resolution: {integrity: sha512-b6jSvxvVnyptAiLjbkWLE/lOnR4lfTtDAl+eUC7RZy+QQWc6wRzIV2CE6xBuMmDxc2qIihtDCZD5NPOFl7fRBQ==} + engines: {node: '>=10'} + peerDependencies: + '@types/react': '*' + react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true - undici-types@7.19.2: - resolution: {integrity: sha512-qYVnV5OEm2AW8cJMCpdV20CDyaN3g0AjDlOGf1OW4iaDEx8MwdtChUp4zu4H0VP3nDRF/8RKWH+IPp9uW0YGZg==} + react@18.3.1: + resolution: {integrity: sha512-wS+hAgJShR0KhEvPJArfuPVN1+Hz1t0Y6n5jLrGQbkb4urgPE/0Rve+1kMB1v/oWgHgm4WIcV+i7F2pTVj+2iQ==} + engines: {node: '>=0.10.0'} - undici@8.1.0: - resolution: {integrity: sha512-E9MkTS4xXLnRPYqxH2e6Hr2/49e7WFDKczKcCaFH4VaZs2iNvHMqeIkyUAD9vM8kujy9TjVrRlQ5KkdEJxB2pw==} - engines: {node: '>=22.19.0'} + read-yaml-file@1.1.0: + resolution: {integrity: sha512-VIMnQi/Z4HT2Fxuwg5KrY174U1VdUIASQVWXXyqtNRtxSr9IYkn1rsI6Tb6HsrHCmB7gVpNwX6JxPTHcH6IoTA==} + engines: {node: '>=6'} - unfetch@4.2.0: - resolution: {integrity: sha512-F9p7yYCn6cIW9El1zi0HI6vqpeIvBsr3dSuRO6Xuppb1u5rXpCPmMvLSyECLhybr9isec8Ohl0hPekMVrEinDA==} - - unique-filename@3.0.0: - resolution: {integrity: sha512-afXhuC55wkAmZ0P18QsVE6kp8JaxrEokN2HGIoIVv2ijHQd419H0+6EigAFcIzXeMIkcIkNBpB3L/DXB3cTS/g==} - engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} - - unique-slug@4.0.0: - resolution: {integrity: sha512-WrcA6AyEfqDX5bWige/4NQfPZMtASNVxdmWR76WESYQVAACSgWcR6e9i0mofqqBxYFtL4oAxPIptY73/0YE1DQ==} - engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} - - universalify@0.1.2: - resolution: {integrity: sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==} - engines: {node: '>= 4.0.0'} + readable-stream@2.3.8: + resolution: {integrity: sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==} - universalify@2.0.1: - resolution: {integrity: sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==} - engines: {node: '>= 10.0.0'} + readable-stream@3.6.2: + resolution: {integrity: sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==} + engines: {node: '>= 6'} - unpipe@1.0.0: - resolution: {integrity: sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==} - engines: {node: '>= 0.8'} + readable-stream@4.7.0: + resolution: {integrity: sha512-oIGGmcpTLwPga8Bn6/Z75SVaH1z5dUut2ibSyAMVhmUggWpmDn2dapB0n7f8nwaSiRtepAsfJyfXIO5DCVAODg==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - update-browserslist-db@1.2.2: - resolution: {integrity: sha512-E85pfNzMQ9jpKkA7+TJAi4TJN+tBCuWh5rUcS/sv6cFi+1q9LYDwDI5dpUL0u/73EElyQ8d3TEaeW4sPedBqYA==} - hasBin: true - peerDependencies: - browserslist: '>= 4.21.0' + readdir-glob@1.1.3: + resolution: {integrity: sha512-v05I2k7xN8zXvPD9N+z/uhXPaj0sUFCe2rcWZIpBsqxfP7xXFQ0tipAd/wjj1YxWyWtUS5IDJpOG82JKt2EAVA==} - update-browserslist-db@1.2.3: - resolution: {integrity: sha512-Js0m9cx+qOgDxo0eMiFGEueWztz+d4+M3rGlmKPT+T4IS/jP4ylw3Nwpu6cpTTP8R1MAC1kF4VbdLt3ARf209w==} - hasBin: true - peerDependencies: - browserslist: '>= 4.21.0' + readdirp@3.6.0: + resolution: {integrity: sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==} + engines: {node: '>=8.10.0'} - update-check@1.5.4: - resolution: {integrity: sha512-5YHsflzHP4t1G+8WGPlvKbJEbAJGCgw+Em+dGR1KmBUbr1J36SJBqlHLjR7oob7sco5hWHGQVcr9B2poIVDDTQ==} + readdirp@4.1.2: + resolution: {integrity: sha512-GDhwkLfywWL2s6vEjyhri+eXmfH6j1L7JE27WhqLeYzoh/A3DBaYGEj2H/HFZCn/kMfim73FXxEJTw06WtxQwg==} + engines: {node: '>= 14.18.0'} - upper-case-first@1.1.2: - resolution: {integrity: sha512-wINKYvI3Db8dtjikdAqoBbZoP6Q+PZUyfMR7pmwHzjC2quzSkUq5DmPrTtPEqHaz8AGtmsB4TqwapMTM1QAQOQ==} + readdirp@5.0.0: + resolution: {integrity: sha512-9u/XQ1pvrQtYyMpZe7DXKv2p5CNvyVwzUB6uhLAnQwHMSgKMBR62lc7AHljaeteeHXn11XTAaLLUVZYVZyuRBQ==} + engines: {node: '>= 20.19.0'} - upper-case@1.1.3: - resolution: {integrity: sha512-WRbjgmYzgXkCV7zNVpy5YgrHgbBv126rMALQQMrmzOVC4GM2waQ9x7xtm8VU+1yF2kWyPzI9zbZ48n4vSxwfSA==} + real-require@0.1.0: + resolution: {integrity: sha512-r/H9MzAWtrv8aSVjPCMFpDMl5q66GqtmmRkRjpHTsp4zBAa+snZyiQNlMONiUmEJcsnaw0wCauJ2GWODr/aFkg==} + engines: {node: '>= 12.13.0'} - uri-js@4.4.1: - resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==} + redis-errors@1.2.0: + resolution: {integrity: sha512-1qny3OExCf0UvUV/5wpYKf2YwPcOqXzkwKKSmKHiE6ZMQs5heeE/c8eXK+PNllPvmjgAbfnsbpkGZWy8cBpn9w==} + engines: {node: '>=4'} - url-set-query@1.0.0: - resolution: {integrity: sha512-3AChu4NiXquPfeckE5R5cGdiHCMWJx1dwCWOmWIL4KHAziJNOFIYJlpGFeKDvwLPHovZRCxK3cYlwzqI9Vp+Gg==} + redis-parser@3.0.0: + resolution: {integrity: sha512-DJnGAeenTdpMEH6uAJRK/uiyEIH9WVsUmoLwzudwGJUwZPp80PDBWPHXSAGNPwNvIXAbe7MSUB1zQFugFml66A==} + engines: {node: '>=4'} - url@0.11.4: - resolution: {integrity: sha512-oCwdVC7mTuWiPyjLUz/COz5TLk6wgp0RCsN+wHZ2Ekneac9w8uuV0njcbbie2ME+Vs+d6duwmYuR3HgQXs1fOg==} - engines: {node: '>= 0.4'} + regenerator-runtime@0.14.0: + resolution: {integrity: sha512-srw17NI0TUWHuGa5CFGGmhfNIeja30WMBfbslPNhf6JrqQlLN5gcrvig1oqPxiVaXb0oW0XRKtH6Nngs5lKCIA==} - urlpattern-polyfill@8.0.2: - resolution: {integrity: sha512-Qp95D4TPJl1kC9SKigDcqgyM2VDVO4RiJc2d4qe5GrYm+zbIQCWWKAFaJNQ4BhdFeDGwBmAxqJBwWSJDb9T3BQ==} + regex@4.4.0: + resolution: {integrity: sha512-uCUSuobNVeqUupowbdZub6ggI5/JZkYyJdDogddJr60L764oxC2pMZov1fQ3wM9bdyzUILDG+Sqx6NAKAz9rKQ==} - utf-8-validate@5.0.10: - resolution: {integrity: sha512-Z6czzLq4u8fPOyx7TU6X3dvUZVvoJmxSQ+IcrlmagKhilxlhZgxPK6C5Jqbkw1IDUmFTM+cz9QDnnLTwDz/2gQ==} - engines: {node: '>=6.14.2'} + regexp-tree@0.1.27: + resolution: {integrity: sha512-iETxpjK6YoRWJG5o6hXLwvjYAoW+FEZn9os0PD/b6AP6xQwsa/Y7lCVgIixBbUPMfhu+i2LtdeAqVTgGlQarfA==} + hasBin: true - utf-8-validate@5.0.7: - resolution: {integrity: sha512-vLt1O5Pp+flcArHGIyKEQq883nBt8nN8tVBcoL0qUXj2XT1n7p70yGIq2VK98I5FdZ1YHc0wk/koOnHjnXWk1Q==} - engines: {node: '>=6.14.2'} + remove-accents@0.5.0: + resolution: {integrity: sha512-8g3/Otx1eJaVD12e31UbJj1YzdtVvzH85HV7t+9MJYk/u3XmkOUJ5Ys9wQrf9PCPK8+xn4ymzqYCiZl6QWKn+A==} - utf-8-validate@6.0.3: - resolution: {integrity: sha512-uIuGf9TWQ/y+0Lp+KGZCMuJWc3N9BHA+l/UmHd/oUHwJJDeysyTRxNQVkbzsIWfGFbRe3OcgML/i0mvVRPOyDA==} - engines: {node: '>=6.14.2'} + require-directory@2.1.1: + resolution: {integrity: sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==} + engines: {node: '>=0.10.0'} - utf8@3.0.0: - resolution: {integrity: sha512-E8VjFIQ/TyQgp+TZfS6l8yp/xWppSAHzidGiRrqe4bK4XP9pTRyKFgGJpO3SN7zdX4DeomTrwaseCHovfpFcqQ==} + require-from-string@2.0.2: + resolution: {integrity: sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==} + engines: {node: '>=0.10.0'} - util-deprecate@1.0.2: - resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==} + require-main-filename@2.0.0: + resolution: {integrity: sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==} - util@0.12.5: - resolution: {integrity: sha512-kZf/K6hEIrWHI6XqOFUiiMa+79wE/D8Q+NCNAWclkyg3b4d2k7s0QGepNjiABc+aR3N1PAyHL7p6UcLY6LmrnA==} + requires-port@1.0.0: + resolution: {integrity: sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==} - utils-merge@1.0.1: - resolution: {integrity: sha512-pMZTvIkT1d+TFGvDOqodOclx0QWkkgi6Tdoa8gC8ffGAAqz9pzPTZWAybbsHHoED/ztMtkv/VoYTYyShUn81hA==} - engines: {node: '>= 0.4.0'} + resolve-from@5.0.0: + resolution: {integrity: sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==} + engines: {node: '>=8'} - uuid@14.0.0: - resolution: {integrity: sha512-Qo+uWgilfSmAhXCMav1uYFynlQO7fMFiMVZsQqZRMIXp0O7rR7qjkj+cPvBHLgBqi960QCoo/PH2/6ZtVqKvrg==} - hasBin: true + resolve-pkg-maps@1.0.0: + resolution: {integrity: sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==} - uuid@3.4.0: - resolution: {integrity: sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A==} - deprecated: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. - hasBin: true + resolve@1.17.0: + resolution: {integrity: sha512-ic+7JYiV8Vi2yzQGFWOkiZD5Z9z7O2Zhm9XMaTxdJExKasieFCr+yXZ/WmXsckHiKl12ar0y6XiXDx3m4RHn1w==} - uuid@8.3.2: - resolution: {integrity: sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==} + resolve@1.22.11: + resolution: {integrity: sha512-RfqAvLnMl313r7c9oclB1HhUEAezcpLjz95wFH4LVuhk9JF/r22qmVP9AMmOU4vMX7Q8pN8jwNg/CSpdFnMjTQ==} + engines: {node: '>= 0.4'} hasBin: true - uuid@9.0.1: - resolution: {integrity: sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==} - hasBin: true + retry@0.13.1: + resolution: {integrity: sha512-XQBQ3I8W1Cge0Seh+6gjj03LbmRFWuoszgK9ooCpwYIrhhoO80pfq4cUkU5DkknwfOfFteRwlZ56PYOGYyFWdg==} + engines: {node: '>= 4'} - v8-compile-cache-lib@3.0.1: - resolution: {integrity: sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==} + reusify@1.0.4: + resolution: {integrity: sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==} + engines: {iojs: '>=1.0.0', node: '>=0.10.0'} - validate-npm-package-license@3.0.4: - resolution: {integrity: sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==} + rfdc@1.4.1: + resolution: {integrity: sha512-q1b3N5QkRUWUl7iyylaaj3kOpIT0N2i9MqIEQXP73GVsN9cw3fdx8X63cEmWhJGi2PPCF23Ijp7ktmd39rawIA==} - validate-npm-package-name@5.0.1: - resolution: {integrity: sha512-OljLrQ9SQdOUqTaQxqL5dEfZWrXExyyWsozYlAWFawPVNuD83igl7uJD2RTkNMbniIYgt8l81eCJGIdQF7avLQ==} - engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} + rimraf@2.7.1: + resolution: {integrity: sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==} + deprecated: Rimraf versions prior to v4 are no longer supported + hasBin: true - value-or-promise@1.0.11: - resolution: {integrity: sha512-41BrgH+dIbCFXClcSapVs5M6GkENd3gQOJpEfPDNa71LsUGMXDL0jMWpI/Rh7WhX+Aalfz2TTS3Zt5pUsbnhLg==} - engines: {node: '>=12'} + rimraf@5.0.10: + resolution: {integrity: sha512-l0OE8wL34P4nJH/H2ffoaniAokM2qSmrtXHmlpvYr5AVVX8msAyW0l8NVJFDxlSK4u3Uh/f41cQheDVdnYijwQ==} + hasBin: true - varint@5.0.2: - resolution: {integrity: sha512-lKxKYG6H03yCZUpAGOPOsMcGxd1RHCu1iKvEHYDPmTyq2HueGhD73ssNBqqQWfvYs04G9iUFRvmAVLW20Jw6ow==} + rimraf@6.1.2: + resolution: {integrity: sha512-cFCkPslJv7BAXJsYlK1dZsbP8/ZNLkCAQ0bi1hf5EKX2QHegmDFEFA6QhuYJlk7UDdc+02JjO80YSOrWPpw06g==} + engines: {node: 20 || >=22} + hasBin: true - vary@1.1.2: - resolution: {integrity: sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==} - engines: {node: '>= 0.8'} + ripemd160@2.0.2: + resolution: {integrity: sha512-ii4iagi25WusVoiC4B4lq7pbXfAp3D9v5CwfkY33vffw2+pkDjY1D8GaN7spsxvCSx8dkPqOZCEZyfxcmJG2IA==} - verror@1.10.0: - resolution: {integrity: sha512-ZZKSmDAEFOijERBLkmYfJ+vmk3w+7hOLYDNkRCuRuMJGEmqYNCNLyBBFwWKVMhfwaEF3WOd0Zlw86U/WC/+nYw==} - engines: {'0': node >=0.6.0} + rlp@2.2.7: + resolution: {integrity: sha512-d5gdPmgQ0Z+AklL2NVXr/IoSjNZFfTVvQWzL/AM2AOcSzYP2xjlb0AC8YyCLc41MSNf6P6QVtjgPdmVtzb+4lQ==} + hasBin: true - viem@2.42.1: - resolution: {integrity: sha512-NzT/f54jT+b0Um6pYzN/uAGMLg+3twhricAzXS+XH8pVIREzPEh7P25rlhPQnLYiPWzQd9mrFcvnm73Sc8bx+A==} - peerDependencies: - typescript: '>=5.0.4' - peerDependenciesMeta: - typescript: - optional: true + rolldown@1.0.0-beta.35: + resolution: {integrity: sha512-gJATyqcsJe0Cs8RMFO8XgFjfTc0lK1jcSvirDQDSIfsJE+vt53QH/Ob+OBSJsXb98YtZXHfP/bHpELpPwCprow==} + hasBin: true - vite@7.3.0: - resolution: {integrity: sha512-dZwN5L1VlUBewiP6H9s2+B3e3Jg96D0vzN+Ry73sOefebhYr9f94wwkMNN/9ouoU8pV1BqA1d1zGk8928cx0rg==} - engines: {node: ^20.19.0 || >=22.12.0} + rollup-plugin-visualizer@6.0.5: + resolution: {integrity: sha512-9+HlNgKCVbJDs8tVtjQ43US12eqaiHyyiLMdBwQ7vSZPiHMysGNo2E88TAp1si5wx8NAoYriI2A5kuKfIakmJg==} + engines: {node: '>=18'} hasBin: true peerDependencies: - '@types/node': ^20.19.0 || >=22.12.0 - jiti: '>=1.21.0' - less: ^4.0.0 - lightningcss: ^1.21.0 - sass: ^1.70.0 - sass-embedded: ^1.70.0 - stylus: '>=0.54.8' - sugarss: ^5.0.0 - terser: ^5.16.0 - tsx: ^4.8.1 - yaml: ^2.4.2 + rolldown: 1.x || ^1.0.0-beta + rollup: 2.x || 3.x || 4.x peerDependenciesMeta: - '@types/node': - optional: true - jiti: - optional: true - less: - optional: true - lightningcss: - optional: true - sass: - optional: true - sass-embedded: - optional: true - stylus: - optional: true - sugarss: - optional: true - terser: - optional: true - tsx: + rolldown: optional: true - yaml: + rollup: optional: true - vitest@4.0.18: - resolution: {integrity: sha512-hOQuK7h0FGKgBAas7v0mSAsnvrIgAvWmRFjmzpJ7SwFHH3g1k2u37JtYwOwmEKhK6ZO3v9ggDBBm0La1LCK4uQ==} - engines: {node: ^20.0.0 || ^22.0.0 || >=24.0.0} + rollup@4.54.0: + resolution: {integrity: sha512-3nk8Y3a9Ea8szgKhinMlGMhGMw89mqule3KWczxhIzqudyHdCIOHw8WJlj/r329fACjKLEh13ZSk7oE22kyeIw==} + engines: {node: '>=18.0.0', npm: '>=8.0.0'} hasBin: true - peerDependencies: - '@edge-runtime/vm': '*' - '@opentelemetry/api': ^1.9.0 - '@types/node': ^20.0.0 || ^22.0.0 || >=24.0.0 - '@vitest/browser-playwright': 4.0.18 - '@vitest/browser-preview': 4.0.18 - '@vitest/browser-webdriverio': 4.0.18 - '@vitest/ui': 4.0.18 - happy-dom: '*' - jsdom: '*' - peerDependenciesMeta: - '@edge-runtime/vm': - optional: true - '@opentelemetry/api': - optional: true - '@types/node': - optional: true - '@vitest/browser-playwright': - optional: true - '@vitest/browser-preview': - optional: true - '@vitest/browser-webdriverio': - optional: true - '@vitest/ui': - optional: true - happy-dom: - optional: true - jsdom: - optional: true - wcwidth@1.0.1: - resolution: {integrity: sha512-XHPEwS0q6TaxcvG85+8EYkbiCux2XtWG2mkc47Ng2A77BQu9+DqIOJldST4HgPkuea7dvKSj5VgX3P1d4rW8Tg==} + run-applescript@7.1.0: + resolution: {integrity: sha512-DPe5pVFaAsinSaV6QjQ6gdiedWDcRCbUuiQfQa2wmWV7+xC9bGulGI8+TdRmoFkAPaBXk8CrAbnlY2ISniJ47Q==} + engines: {node: '>=18'} - web-streams-polyfill@3.3.3: - resolution: {integrity: sha512-d2JWLCivmZYTSIoge9MsgFCZrt571BikcWGYkjC1khllbTeDlGqZ2D8vD8E/lJa8WGWbb7Plm8/XJYV7IJHZZw==} - engines: {node: '>= 8'} + run-parallel@1.2.0: + resolution: {integrity: sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==} - web3-bzz@1.10.4: - resolution: {integrity: sha512-ZZ/X4sJ0Uh2teU9lAGNS8EjveEppoHNQiKlOXAjedsrdWuaMErBPdLQjXfcrYvN6WM6Su9PMsAxf3FXXZ+HwQw==} - engines: {node: '>=8.0.0'} + sade@1.8.1: + resolution: {integrity: sha512-xal3CZX1Xlo/k4ApwCFrHVACi9fBqJ7V+mwhBsuf/1IOKbBy098Fex+Wa/5QMubw09pSZ/u8EY8PWgevJsXp1A==} + engines: {node: '>=6'} - web3-core-helpers@1.10.4: - resolution: {integrity: sha512-r+L5ylA17JlD1vwS8rjhWr0qg7zVoVMDvWhajWA5r5+USdh91jRUYosp19Kd1m2vE034v7Dfqe1xYRoH2zvG0g==} - engines: {node: '>=8.0.0'} + safe-buffer@5.1.2: + resolution: {integrity: sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==} - web3-core-method@1.10.4: - resolution: {integrity: sha512-uZTb7flr+Xl6LaDsyTeE2L1TylokCJwTDrIVfIfnrGmnwLc6bmTWCCrm71sSrQ0hqs6vp/MKbQYIYqUN0J8WyA==} - engines: {node: '>=8.0.0'} + safe-buffer@5.2.1: + resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} - web3-core-promievent@1.10.4: - resolution: {integrity: sha512-2de5WnJQ72YcIhYwV/jHLc4/cWJnznuoGTJGD29ncFQHAfwW/MItHFSVKPPA5v8AhJe+r6y4Y12EKvZKjQVBvQ==} - engines: {node: '>=8.0.0'} + safe-regex-test@1.1.0: + resolution: {integrity: sha512-x/+Cz4YrimQxQccJf5mKEbIa1NzeCRNI5Ecl/ekmlYaampdNLPalVyIcCZNNH3MvmqBugV5TMYZXv0ljslUlaw==} + engines: {node: '>= 0.4'} - web3-core-requestmanager@1.10.4: - resolution: {integrity: sha512-vqP6pKH8RrhT/2MoaU+DY/OsYK9h7HmEBNCdoMj+4ZwujQtw/Mq2JifjwsJ7gits7Q+HWJwx8q6WmQoVZAWugg==} - engines: {node: '>=8.0.0'} + safe-stable-stringify@2.4.3: + resolution: {integrity: sha512-e2bDA2WJT0wxseVd4lsDP4+3ONX6HpMXQa1ZhFQ7SU+GjvORCmShbCMltrtIDfkYhVHrOcPtj+KhmDBdPdZD1g==} + engines: {node: '>=10'} - web3-core-subscriptions@1.10.4: - resolution: {integrity: sha512-o0lSQo/N/f7/L76C0HV63+S54loXiE9fUPfHFcTtpJRQNDBVsSDdWRdePbWwR206XlsBqD5VHApck1//jEafTw==} - engines: {node: '>=8.0.0'} + safer-buffer@2.1.2: + resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} - web3-core@1.10.4: - resolution: {integrity: sha512-B6elffYm81MYZDTrat7aEhnhdtVE3lDBUZft16Z8awYMZYJDbnykEbJVS+l3mnA7AQTnSDr/1MjWofGDLBJPww==} - engines: {node: '>=8.0.0'} + sax@1.4.3: + resolution: {integrity: sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==} - web3-eth-abi@1.10.4: - resolution: {integrity: sha512-cZ0q65eJIkd/jyOlQPDjr8X4fU6CRL1eWgdLwbWEpo++MPU/2P4PFk5ZLAdye9T5Sdp+MomePPJ/gHjLMj2VfQ==} - engines: {node: '>=8.0.0'} + scheduler@0.23.2: + resolution: {integrity: sha512-UOShsPwz7NrMUqhR6t0hWjFduvOzbtv7toDH1/hIrfRNIDBnnBWd0CwJTGvTpngVlmwGCdP9/Zl/tVrDqcuYzQ==} - web3-eth-accounts@1.10.4: - resolution: {integrity: sha512-ysy5sVTg9snYS7tJjxVoQAH6DTOTkRGR8emEVCWNGLGiB9txj+qDvSeT0izjurS/g7D5xlMAgrEHLK1Vi6I3yg==} - engines: {node: '>=8.0.0'} + scrypt-js@3.0.1: + resolution: {integrity: sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==} - web3-eth-contract@1.10.4: - resolution: {integrity: sha512-Q8PfolOJ4eV9TvnTj1TGdZ4RarpSLmHnUnzVxZ/6/NiTfe4maJz99R0ISgwZkntLhLRtw0C7LRJuklzGYCNN3A==} - engines: {node: '>=8.0.0'} + scule@1.3.0: + resolution: {integrity: sha512-6FtHJEvt+pVMIB9IBY+IcCJ6Z5f1iQnytgyfKMhDKgmzYG+TeH/wx1y3l27rshSbLiSanrR9ffZDrEsmjlQF2g==} - web3-eth-ens@1.10.4: - resolution: {integrity: sha512-LLrvxuFeVooRVZ9e5T6OWKVflHPFgrVjJ/jtisRWcmI7KN/b64+D/wJzXqgmp6CNsMQcE7rpmf4CQmJCrTdsgg==} - engines: {node: '>=8.0.0'} + secp256k1@4.0.3: + resolution: {integrity: sha512-NLZVf+ROMxwtEj3Xa562qgv2BK5e2WNmXPiOdVIPLgs6lyTzMvBq0aWTYMI5XCP9jZMVKOcqZLw/Wc4vDkuxhA==} + engines: {node: '>=10.0.0'} - web3-eth-iban@1.10.4: - resolution: {integrity: sha512-0gE5iNmOkmtBmbKH2aTodeompnNE8jEyvwFJ6s/AF6jkw9ky9Op9cqfzS56AYAbrqEFuClsqB/AoRves7LDELw==} - engines: {node: '>=8.0.0'} + secure-json-parse@2.7.0: + resolution: {integrity: sha512-6aU+Rwsezw7VR8/nyvKTx8QpWH9FrcYiXXlqC4z5d5XQBDRqtbfsRjnwGyqbi3gddNtWHuEk9OANUotL26qKUw==} - web3-eth-personal@1.10.4: - resolution: {integrity: sha512-BRa/hs6jU1hKHz+AC/YkM71RP3f0Yci1dPk4paOic53R4ZZG4MgwKRkJhgt3/GPuPliwS46f/i5A7fEGBT4F9w==} - engines: {node: '>=8.0.0'} + semver@5.7.1: + resolution: {integrity: sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==} + hasBin: true - web3-eth@1.10.4: - resolution: {integrity: sha512-Sql2kYKmgt+T/cgvg7b9ce24uLS7xbFrxE4kuuor1zSCGrjhTJ5rRNG8gTJUkAJGKJc7KgnWmgW+cOfMBPUDSA==} - engines: {node: '>=8.0.0'} + semver@6.3.1: + resolution: {integrity: sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==} + hasBin: true - web3-net@1.10.4: - resolution: {integrity: sha512-mKINnhOOnZ4koA+yV2OT5s5ztVjIx7IY9a03w6s+yao/BUn+Luuty0/keNemZxTr1E8Ehvtn28vbOtW7Ids+Ow==} - engines: {node: '>=8.0.0'} + semver@7.5.4: + resolution: {integrity: sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==} + engines: {node: '>=10'} + hasBin: true - web3-provider-engine@16.0.8: - resolution: {integrity: sha512-Pq70Ch+PHDKcy0dycenDLTDPZh3y7Wf1XmDtrpm61q+0MlROJs1uP1BxJmP8t4KZHHj7ZWTE+jJ3SbVQ2Fd27g==} - engines: {node: '>=12.0.0'} + semver@7.6.2: + resolution: {integrity: sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==} + engines: {node: '>=10'} + hasBin: true - web3-providers-http@1.10.4: - resolution: {integrity: sha512-m2P5Idc8hdiO0l60O6DSCPw0kw64Zgi0pMjbEFRmxKIck2Py57RQMu4bxvkxJwkF06SlGaEQF8rFZBmuX7aagQ==} - engines: {node: '>=8.0.0'} + semver@7.7.3: + resolution: {integrity: sha512-SdsKMrI9TdgjdweUSR9MweHA4EJ8YxHn8DFaDisvhVlUOe4BF1tLD7GAj0lIqWVl+dPb/rExr0Btby5loQm20Q==} + engines: {node: '>=10'} + hasBin: true - web3-providers-ipc@1.10.4: - resolution: {integrity: sha512-YRF/bpQk9z3WwjT+A6FI/GmWRCASgd+gC0si7f9zbBWLXjwzYAKG73bQBaFRAHex1hl4CVcM5WUMaQXf3Opeuw==} - engines: {node: '>=8.0.0'} + send@1.2.1: + resolution: {integrity: sha512-1gnZf7DFcoIcajTjTwjwuDjzuz4PPcY2StKPlsGAQ1+YH20IRVrBaXSWmdjowTJ6u8Rc01PoYOGHXfP1mYcZNQ==} + engines: {node: '>= 18'} - web3-providers-ws@1.10.4: - resolution: {integrity: sha512-j3FBMifyuFFmUIPVQR4pj+t5ILhAexAui0opgcpu9R5LxQrLRUZxHSnU+YO25UycSOa/NAX8A+qkqZNpcFAlxA==} - engines: {node: '>=8.0.0'} + serialize-javascript@6.0.0: + resolution: {integrity: sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag==} - web3-shh@1.10.4: - resolution: {integrity: sha512-cOH6iFFM71lCNwSQrC3niqDXagMqrdfFW85hC9PFUrAr3PUrIem8TNstTc3xna2bwZeWG6OBy99xSIhBvyIACw==} - engines: {node: '>=8.0.0'} + serialize-javascript@6.0.2: + resolution: {integrity: sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==} - web3-utils@1.10.4: - resolution: {integrity: sha512-tsu8FiKJLk2PzhDl9fXbGUWTkkVXYhtTA+SmEFkKft+9BgwLxfCRpU96sWv7ICC8zixBNd3JURVoiR3dUXgP8A==} - engines: {node: '>=8.0.0'} + serve-placeholder@2.0.2: + resolution: {integrity: sha512-/TMG8SboeiQbZJWRlfTCqMs2DD3SZgWp0kDQePz9yUuCnDfDh/92gf7/PxGhzXTKBIPASIHxFcZndoNbp6QOLQ==} - web3@1.10.4: - resolution: {integrity: sha512-kgJvQZjkmjOEKimx/tJQsqWfRDPTTcBfYPa9XletxuHLpHcXdx67w8EFn5AW3eVxCutE9dTVHgGa9VYe8vgsEA==} - engines: {node: '>=8.0.0'} + serve-static@2.2.1: + resolution: {integrity: sha512-xRXBn0pPqQTVQiC8wyQrKs2MOlX24zQ0POGaj0kultvoOCstBQM5yvOhAVSUwOMjQtTvsPWoNCHfPGwaaQJhTw==} + engines: {node: '>= 18'} - webextension-polyfill@0.10.0: - resolution: {integrity: sha512-c5s35LgVa5tFaHhrZDnr3FpQpjj1BB+RXhLTYUxGqBVN460HkbM8TBtEqdXWbpTKfzwCcjAZVF7zXCYSKtcp9g==} + set-blocking@2.0.0: + resolution: {integrity: sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==} - webidl-conversions@3.0.1: - resolution: {integrity: sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==} + set-function-length@1.2.2: + resolution: {integrity: sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==} + engines: {node: '>= 0.4'} - webidl-conversions@4.0.2: - resolution: {integrity: sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg==} + setimmediate@1.0.5: + resolution: {integrity: sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==} - webidl-conversions@6.1.0: - resolution: {integrity: sha512-qBIvFLGiBpLjfwmYAaHPXsn+ho5xZnGvyGvsarywGNc8VyQJUMHJ8OBKGGrPER0okBeMDaan4mNBlgBROxuI8w==} - engines: {node: '>=10.4'} + setprototypeof@1.1.1: + resolution: {integrity: sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw==} - websocket@1.0.35: - resolution: {integrity: sha512-/REy6amwPZl44DDzvRCkaI1q1bIiQB0mEFQLUrhz3z2EK91cp3n72rAjUlrTP0zV22HJIUOVHQGPxhFRjxjt+Q==} - engines: {node: '>=4.0.0'} + setprototypeof@1.2.0: + resolution: {integrity: sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==} - whatwg-mimetype@3.0.0: - resolution: {integrity: sha512-nt+N2dzIutVRxARx1nghPKGv1xHikU7HKdfafKkLNLindmPU/ch3U31NOCGGA/dmPcmb1VlofO0vnKAcsm0o/Q==} - engines: {node: '>=12'} + sha.js@2.4.11: + resolution: {integrity: sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ==} + hasBin: true - whatwg-url@5.0.0: - resolution: {integrity: sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==} + sharp@0.34.5: + resolution: {integrity: sha512-Ou9I5Ft9WNcCbXrU9cMgPBcCK8LiwLqcbywW3t4oDV37n1pzpuNLsYiAV8eODnjbtQlSDwZ2cUEeQz4E54Hltg==} + engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - whatwg-url@8.7.0: - resolution: {integrity: sha512-gAojqb/m9Q8a5IV96E3fHJM70AzCkgt4uXYX2O7EmuyOnLrViCQlsEBmF9UQIu3/aeAIp2U17rtbpZWNntQqdg==} - engines: {node: '>=10'} + shebang-command@1.2.0: + resolution: {integrity: sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg==} + engines: {node: '>=0.10.0'} - which-boxed-primitive@1.1.1: - resolution: {integrity: sha512-TbX3mj8n0odCBFVlY8AxkqcHASw3L60jIuF8jFP78az3C2YhmGvqbHBpAjTRH2/xqYunrJ9g1jSyjCjpoWzIAA==} - engines: {node: '>= 0.4'} + shebang-command@2.0.0: + resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} + engines: {node: '>=8'} - which-builtin-type@1.2.1: - resolution: {integrity: sha512-6iBczoX+kDQ7a3+YJBnh3T+KZRxM/iYNPXicqk66/Qfm1b93iu+yOImkg0zHbj5LNOcNv1TEADiZ0xa34B4q6Q==} - engines: {node: '>= 0.4'} + shebang-regex@1.0.0: + resolution: {integrity: sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ==} + engines: {node: '>=0.10.0'} - which-collection@1.0.2: - resolution: {integrity: sha512-K4jVyjnBdgvc86Y6BkaLZEN933SwYOuBFkdmBu9ZfkcAbdVbpITnDmjvZ/aQjRXQrv5EPkTnD1s39GiiqbngCw==} - engines: {node: '>= 0.4'} + shebang-regex@3.0.0: + resolution: {integrity: sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==} + engines: {node: '>=8'} - which-module@1.0.0: - resolution: {integrity: sha512-F6+WgncZi/mJDrammbTuHe1q0R5hOXv/mBaiNA2TCNT/LTHusX0V+CJnj9XT8ki5ln2UZyyddDgHfCzyrOH7MQ==} + shell-quote@1.8.3: + resolution: {integrity: sha512-ObmnIF4hXNg1BqhnHmgbDETF8dLPCggZWBjkQfhZpbszZnYur5DUljTcCHii5LC3J5E0yeO/1LIMyH+UvHQgyw==} + engines: {node: '>= 0.4'} - which-module@2.0.1: - resolution: {integrity: sha512-iBdZ57RDvnOR9AGBhML2vFZf7h8vmBjhoaZqODJBFWHVtKkDmKuHai3cx5PgVMrX5YDNp27AofYbAwctSS+vhQ==} + sherif-darwin-arm64@1.0.0: + resolution: {integrity: sha512-BRzDsWGjdZ6JqaDQ0HdcpapfHcnZyN24wUWpnFkljZOH78N+vB4qr+wwhmM7oyePJiO4pZWEoIBvzVT4cn1+3g==} + cpu: [arm64] + os: [darwin] - which-typed-array@1.1.19: - resolution: {integrity: sha512-rEvr90Bck4WZt9HHFC4DJMsjvu7x+r6bImz0/BrbWb7A2djJ8hnZMrWnHo9F8ssv0OMErasDhftrfROTyqSDrw==} - engines: {node: '>= 0.4'} + sherif-darwin-x64@1.0.0: + resolution: {integrity: sha512-forkTw6v2N2sjvDdHGL+MqSPdLc0e7Z0v9BsmSdIKv5kdCPncVn6tRv/4xfAE7q+Xqa2a2bH9EEXppGb4gR3Tw==} + cpu: [x64] + os: [darwin] - which-typed-array@1.1.20: - resolution: {integrity: sha512-LYfpUkmqwl0h9A2HL09Mms427Q1RZWuOHsukfVcKRq9q95iQxdw0ix1JQrqbcDR9PH1QDwf5Qo8OZb5lksZ8Xg==} - engines: {node: '>= 0.4'} + sherif-linux-arm64@1.0.0: + resolution: {integrity: sha512-psjD3YupFQtphWbwptM8EnU2jRkS6cnhxdxqJhMG9/yJpGsk99JD4tEmrDq0j/+T9UXZ5g7kXvQZXzocl3J62A==} + cpu: [arm64] + os: [linux] - which@1.3.1: - resolution: {integrity: sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==} + sherif-linux-x64@1.0.0: + resolution: {integrity: sha512-4VM2Z0xfKOEEkZ2bZppq4PAxP4RYC2eWyUq23Jl/nQFeoPMQpA9IkF51UGzxZT4WZ2kZDFftgyJeB09yPvd1CA==} + cpu: [x64] + os: [linux] + + sherif-windows-arm64@1.0.0: + resolution: {integrity: sha512-tSEzytTz3guhKLtdMCKWWru6UtmuCXD+0RsUWcqOMpzPBZZwvSr7OrTc83z8Oabmo8k6SJ5fvQeg33JSthgTqw==} + cpu: [arm64] + os: [win32] + + sherif-windows-x64@1.0.0: + resolution: {integrity: sha512-R/KXUHBWVPU9hSlWS+Gea/ogP1h/3q/Dm/quqGrVq+MN/F+fiRsJlU52EAjAJ6G5r/4RsvQddD1ova8MKsffdw==} + cpu: [x64] + os: [win32] + + sherif@1.0.0: + resolution: {integrity: sha512-x5gZqXmBT0G6Xnr2N63FwbMjaOikk/mPszl2bl3pnDMMyRi89w1ynAfcdIJpOyqZXW445418zkMIXAkQEfEtHw==} hasBin: true - which@2.0.2: - resolution: {integrity: sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==} - engines: {node: '>= 8'} + shiki@1.22.2: + resolution: {integrity: sha512-3IZau0NdGKXhH2bBlUk4w1IHNxPh6A5B2sUpyY+8utLu2j/h1QpFkAaUA1bAMxOWWGtTWcAh531vnS4NJKS/lA==} + + siginfo@2.0.0: + resolution: {integrity: sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==} + + signal-exit@3.0.7: + resolution: {integrity: sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==} + + signal-exit@4.0.2: + resolution: {integrity: sha512-MY2/qGx4enyjprQnFaZsHib3Yadh3IXyV2C321GY0pjGfVBu4un0uDJkwgdxqO+Rdx8JMT8IfJIRwbYVz3Ob3Q==} + engines: {node: '>=14'} + + signal-exit@4.1.0: + resolution: {integrity: sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==} + engines: {node: '>=14'} + + simple-git-hooks@2.11.1: + resolution: {integrity: sha512-tgqwPUMDcNDhuf1Xf6KTUsyeqGdgKMhzaH4PAZZuzguOgTl5uuyeYe/8mWgAr6IBxB5V06uqEf6Dy37gIWDtDg==} hasBin: true - why-is-node-running@2.3.0: - resolution: {integrity: sha512-hUrmaWBdVDcxvYqnyh09zunKzROWjbZTiNy8dBEjkS7ehEDQibXJ7XvlmtbwuTclUiIyN+CyXQD4Vmko8fNm8w==} + simple-git@3.30.0: + resolution: {integrity: sha512-q6lxyDsCmEal/MEGhP1aVyQ3oxnagGlBDOVSIB4XUVLl1iZh0Pah6ebC9V4xBap/RfgP2WlI8EKs0WS0rMEJHg==} + + sirv@2.0.4: + resolution: {integrity: sha512-94Bdh3cC2PKrbgSOUqTiGPWVZeSiXfKOVZNJniWoqrWrRkB1CJzBU3NEbiTsPcYy1lDsANA/THzS+9WBiy5nfQ==} + engines: {node: '>= 10'} + + sirv@3.0.2: + resolution: {integrity: sha512-2wcC/oGxHis/BoHkkPwldgiPSYcpZK3JU28WoMVv55yHJgcZ8rlXvuG9iZggz+sU1d4bRgIGASwyWqjxu3FM0g==} + engines: {node: '>=18'} + + sisteransi@1.0.5: + resolution: {integrity: sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==} + + skin-tone@2.0.0: + resolution: {integrity: sha512-kUMbT1oBJCpgrnKoSr0o6wPtvRWT9W9UKvGLwfJYO2WuahZRHOpEyL1ckyMGgMWh0UdpmaoFqKKD29WTomNEGA==} engines: {node: '>=8'} - hasBin: true - widest-line@3.1.0: - resolution: {integrity: sha512-NsmoXalsWVDMGupxZ5R08ka9flZjjiLvHVAWYOKtiKM8ujtZWr9cRffak+uSE48+Ob8ObalXpwyeUiyDD6QFgg==} + slash@1.0.0: + resolution: {integrity: sha512-3TYDR7xWt4dIqV2JauJr+EJeW356RXijHeUlO+8djJ+uBXPn8/2dpzBc8yQhh583sVvc9CvFAeQVgijsH+PNNg==} + engines: {node: '>=0.10.0'} + + slash@3.0.0: + resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==} engines: {node: '>=8'} - window-size@0.2.0: - resolution: {integrity: sha512-UD7d8HFA2+PZsbKyaOCEy8gMh1oDtHgJh1LfgjQ4zVXmYjAT/kvz3PueITKuqDiIXQe7yzpPnxX3lNc+AhQMyw==} - engines: {node: '>= 0.10.0'} - hasBin: true + slash@5.1.0: + resolution: {integrity: sha512-ZA6oR3T/pEyuqwMgAKT0/hAv8oAXckzbkmR0UkUosQ+Mc4RxGoJkRmwHgHufaenlyAgE1Mxgpdcrf75y6XcnDg==} + engines: {node: '>=14.16'} - word-wrap@1.2.5: - resolution: {integrity: sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==} - engines: {node: '>=0.10.0'} + smob@1.5.0: + resolution: {integrity: sha512-g6T+p7QO8npa+/hNx9ohv1E5pVCmWrVCUzUXJyLdMmftX6ER0oiWY/w9knEonLpnOp6b6FenKnMfR8gqwWdwig==} - wordwrap@1.0.0: - resolution: {integrity: sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q==} + smol-toml@1.3.0: + resolution: {integrity: sha512-tWpi2TsODPScmi48b/OQZGi2lgUmBCHy6SZrhi/FdnnHiU1GwebbCfuQuxsC3nHaLwtYeJGPrDZDIeodDOc4pA==} + engines: {node: '>= 18'} + + socket.io-client@4.8.3: + resolution: {integrity: sha512-uP0bpjWrjQmUt5DTHq9RuoCBdFJF10cdX9X+a368j/Ft0wmaVgxlrjvK3kjvgCODOMMOz9lcaRzxmso0bTWZ/g==} + engines: {node: '>=10.0.0'} + + socket.io-parser@4.2.5: + resolution: {integrity: sha512-bPMmpy/5WWKHea5Y/jYAP6k74A+hvmRCQaJuJB6I/ML5JZq/KfNieUVo/3Mh7SAqn7TyFdIo6wqYHInG1MU1bQ==} + engines: {node: '>=10.0.0'} - wordwrapjs@4.0.1: - resolution: {integrity: sha512-kKlNACbvHrkpIw6oPeYDSmdCTu2hdMHoyXLTcUKala++lx5Y+wjJ/e474Jqv5abnVmwxw08DiTuHmw69lJGksA==} + solc@0.7.3: + resolution: {integrity: sha512-GAsWNAjGzIDg7VxzP6mPjdurby3IkGCjQcM8GFYZT6RyaoUZKmMU6Y7YwG+tFGhv7dwZ8rmR4iwFDrrD99JwqA==} engines: {node: '>=8.0.0'} + hasBin: true - workerpool@6.5.1: - resolution: {integrity: sha512-Fs4dNYcsdpYSAfVxhnl1L5zTksjvOJxtC5hzMNl+1t9B8hTJTdKDyZ5ju7ztgPy+ft9tBFXoOlDNiOT9WUXZlA==} + sonic-boom@2.8.0: + resolution: {integrity: sha512-kuonw1YOYYNOve5iHdSahXPOK49GqwA+LZhI6Wz/l0rP57iKyXXIHaRagOBHAPmGwJC6od2Z9zgvZ5loSgMlVg==} - wrap-ansi@2.1.0: - resolution: {integrity: sha512-vAaEaDM946gbNpH5pLVNR+vX2ht6n0Bt3GXwVB1AuAqZosOvHNF3P7wDnh8KLkSqgUh0uh77le7Owgoz+Z9XBw==} + sonic-boom@4.2.0: + resolution: {integrity: sha512-INb7TM37/mAcsGmc9hyyI6+QR3rR1zVRu36B0NeGXKnOOLiZOfER5SA+N7X7k3yUYRzLWafduTDvJAfDswwEww==} + + source-map-js@1.2.1: + resolution: {integrity: sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==} engines: {node: '>=0.10.0'} - wrap-ansi@6.2.0: - resolution: {integrity: sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==} - engines: {node: '>=8'} + source-map-support@0.5.21: + resolution: {integrity: sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==} - wrap-ansi@7.0.0: - resolution: {integrity: sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==} - engines: {node: '>=10'} + source-map@0.6.1: + resolution: {integrity: sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==} + engines: {node: '>=0.10.0'} - wrap-ansi@8.1.0: - resolution: {integrity: sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==} - engines: {node: '>=12'} + source-map@0.7.6: + resolution: {integrity: sha512-i5uvt8C3ikiWeNZSVZNWcfZPItFQOsYTUAOkcUPGd8DqDy1uOUikjt5dG+uRlwyvR108Fb9DOd4GvXfT0N2/uQ==} + engines: {node: '>= 12'} - wrap-ansi@9.0.2: - resolution: {integrity: sha512-42AtmgqjV+X1VpdOfyTGOYRi0/zsoLqtXQckTmqTeybT+BDIbM/Guxo7x3pE2vtpr1ok6xRqM9OpBe+Jyoqyww==} - engines: {node: '>=18'} + space-separated-tokens@2.0.2: + resolution: {integrity: sha512-PEGlAwrG8yXGXRjW32fGbg66JAlOAwbObuqVoJpv/mRgoWDQfgH1wDPvtzWyUSNAXBGSk8h755YDbbcEy3SH2Q==} - wrappy@1.0.2: - resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} + spawndamnit@2.0.0: + resolution: {integrity: sha512-j4JKEcncSjFlqIwU5L/rp2N5SIPsdxaRsIv678+TZxZ0SRDJTm8JrxJMjE/XuiEZNEir3S8l0Fa3Ke339WI4qA==} - write-file-atomic@3.0.3: - resolution: {integrity: sha512-AvHcyZ5JnSfq3ioSyjrBkH9yW4m7Ayk8/9My/DD9onKeu/94fwrMocemO2QAJFAlnnDN+ZDS+ZjAR5ua1/PV/Q==} + spawndamnit@3.0.1: + resolution: {integrity: sha512-MmnduQUuHCoFckZoWnXsTg7JaiLBJrKFj9UI2MbRPGaJeVpsLcVBu6P/IGZovziM/YBsellCmsprgNA+w0CzVg==} - ws@7.5.10: - resolution: {integrity: sha512-+dbF1tHwZpXcbOJdVOkzLDxZP1ailvSxM6ZweXTegylPny803bFhA+vqBYw4s31NSAk4S2Qz+AKXK9a4wkdjcQ==} - engines: {node: '>=8.3.0'} - peerDependencies: - bufferutil: ^4.0.1 - utf-8-validate: ^5.0.2 - peerDependenciesMeta: - bufferutil: - optional: true - utf-8-validate: - optional: true + speakingurl@14.0.1: + resolution: {integrity: sha512-1POYv7uv2gXoyGFpBCmpDVSNV74IfsWlDW216UPjbWufNf+bSU6GdbDsxdcxtfwb4xlI3yxzOTKClUosxARYrQ==} + engines: {node: '>=0.10.0'} - ws@8.17.1: - resolution: {integrity: sha512-6XQFvXTkbfUOZOKKILFG1PDK2NDQs4azKQl26T0YS5CxqWLgXajbPZ+h4gZekJyRqFU8pvnbAbbs/3TgRPy+GQ==} - engines: {node: '>=10.0.0'} - peerDependencies: - bufferutil: ^4.0.1 - utf-8-validate: '>=5.0.2' - peerDependenciesMeta: - bufferutil: - optional: true - utf-8-validate: - optional: true + split-on-first@1.1.0: + resolution: {integrity: sha512-43ZssAJaMusuKWL8sKUBQXHWOpq8d6CfN/u1p4gUzfJkM05C8rxTmYrkIPTXapZpORA6LkkzcUulJ8FqA7Uudw==} + engines: {node: '>=6'} - ws@8.18.0: - resolution: {integrity: sha512-8VbfWfHLbbwu3+N6OKsOMpBdT4kXPDDB9cJk2bJ6mh9ucxdlnNvH1e+roYkKmN9Nxw2yjz7VzeO9oOz2zJ04Pw==} - engines: {node: '>=10.0.0'} - peerDependencies: - bufferutil: ^4.0.1 - utf-8-validate: '>=5.0.2' - peerDependenciesMeta: - bufferutil: - optional: true - utf-8-validate: - optional: true + split2@4.2.0: + resolution: {integrity: sha512-UcjcJOWknrNkF6PLX83qcHM6KHgVKNkV62Y8a5uYDVv9ydGQVwAHMKqHdJje1VTWpljG0WYpCDhrCdAOYH4TWg==} + engines: {node: '>= 10.x'} - ws@8.18.3: - resolution: {integrity: sha512-PEIGCY5tSlUt50cqyMXfCzX+oOPqN0vuGqWzbcJ2xvnkzkq46oOpz7dQaTDBdfICb4N14+GARUDw2XV2N4tvzg==} - engines: {node: '>=10.0.0'} - peerDependencies: - bufferutil: ^4.0.1 - utf-8-validate: '>=5.0.2' - peerDependenciesMeta: - bufferutil: - optional: true - utf-8-validate: - optional: true + sprintf-js@1.0.3: + resolution: {integrity: sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==} - ws@8.20.0: - resolution: {integrity: sha512-sAt8BhgNbzCtgGbt2OxmpuryO63ZoDk/sqaB/znQm94T4fCEsy/yV+7CdC1kJhOU9lboAEU7R3kquuycDoibVA==} - engines: {node: '>=10.0.0'} - peerDependencies: - bufferutil: ^4.0.1 - utf-8-validate: '>=5.0.2' - peerDependenciesMeta: - bufferutil: - optional: true - utf-8-validate: - optional: true + srvx@0.8.9: + resolution: {integrity: sha512-wYc3VLZHRzwYrWJhkEqkhLb31TI0SOkfYZDkUhXdp3NoCnNS0FqajiQszZZjfow/VYEuc6Q5sZh9nM6kPy2NBQ==} + engines: {node: '>=20.16.0'} + hasBin: true - xhr-request-promise@0.1.3: - resolution: {integrity: sha512-YUBytBsuwgitWtdRzXDDkWAXzhdGB8bYm0sSzMPZT7Z2MBjMSTHFsyCT1yCRATY+XC69DUrQraRAEgcoCRaIPg==} + srvx@0.9.8: + resolution: {integrity: sha512-RZaxTKJEE/14HYn8COLuUOJAt0U55N9l1Xf6jj+T0GoA01EUH1Xz5JtSUOI+EHn+AEgPCVn7gk6jHJffrr06fQ==} + engines: {node: '>=20.16.0'} + hasBin: true - xhr-request@1.1.0: - resolution: {integrity: sha512-Y7qzEaR3FDtL3fP30k9wO/e+FBnBByZeybKOhASsGP30NIkRAAkKD/sCnLvgEfAIEC1rcmK7YG8f4oEnIrrWzA==} + stackback@0.0.2: + resolution: {integrity: sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==} - xhr@2.6.0: - resolution: {integrity: sha512-/eCGLb5rxjx5e3mF1A7s+pLlR6CGyqWN91fv1JgER5mVWg1MZmlhBvy9kjcsOdRk8RrIujotWyJamfyrp+WIcA==} + stacktrace-parser@0.1.10: + resolution: {integrity: sha512-KJP1OCML99+8fhOHxwwzyWrlUuVX5GQ0ZpJTd1DFXhdkrvg1szxfHhawXUZ3g9TkXORQd4/WG68jMlQZ2p8wlg==} + engines: {node: '>=6'} - xtend@2.1.2: - resolution: {integrity: sha512-vMNKzr2rHP9Dp/e1NQFnLQlwlhp9L/LfvnsVdHxN1f+uggyVI3i08uD14GPvCToPkdsRfyPqIyYGmIk58V98ZQ==} - engines: {node: '>=0.4'} + standard-as-callback@2.1.0: + resolution: {integrity: sha512-qoRRSyROncaz1z0mvYqIE4lCd9p2R90i6GxW3uZv5ucSu8tU7B5HXUP1gG8pVZsYNVaXjk8ClXHPttLyxAL48A==} - xtend@4.0.2: - resolution: {integrity: sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==} - engines: {node: '>=0.4'} + stat-mode@0.3.0: + resolution: {integrity: sha512-QjMLR0A3WwFY2aZdV0okfFEJB5TRjkggXZjxP3A1RsWsNHNu3YPv8btmtc6iCFZ0Rul3FE93OYogvhOUClU+ng==} - y18n@3.2.2: - resolution: {integrity: sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ==} + statuses@1.5.0: + resolution: {integrity: sha512-OpZ3zP+jT1PI7I8nemJX4AKmAX070ZkYPVWV/AaKTJl+tXCTGyVdC1a4SL8RUQYEwk/f34ZX8UTykN68FwrqAA==} + engines: {node: '>= 0.6'} - y18n@4.0.3: - resolution: {integrity: sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ==} + statuses@2.0.1: + resolution: {integrity: sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==} + engines: {node: '>= 0.8'} - y18n@5.0.8: - resolution: {integrity: sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==} - engines: {node: '>=10'} + statuses@2.0.2: + resolution: {integrity: sha512-DvEy55V3DB7uknRo+4iOGT5fP1slR8wQohVdknigZPMpMstaKJQWhwiYBACJE3Ul2pTnATihhBYnRhZQHGBiRw==} + engines: {node: '>= 0.8'} - yaeti@0.0.6: - resolution: {integrity: sha512-MvQa//+KcZCUkBTIC9blM+CU9J2GzuTytsOUwf2lidtvkx/6gnEp1QvJv34t9vdjhFmha/mUiNDbN0D0mJWdug==} - engines: {node: '>=0.10.32'} - deprecated: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info. + std-env@3.10.0: + resolution: {integrity: sha512-5GS12FdOZNliM5mAOxFRg7Ir0pWz8MdpYm6AY6VPkGpbA7ZzmbzNcBJQ0GPvvyWgcY7QAhCgf9Uy89I03faLkg==} - yallist@3.1.1: - resolution: {integrity: sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==} + std-env@3.7.0: + resolution: {integrity: sha512-JPbdCEQLj1w5GilpiHAx3qJvFndqybBysA3qUOnznweH4QbNYUsW/ea8QzSrnh0vNsezMMw5bcVool8lM0gwzg==} - yallist@4.0.0: - resolution: {integrity: sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==} + std-env@3.9.0: + resolution: {integrity: sha512-UGvjygr6F6tpH7o2qyqR6QYpwraIjKSdtzyBdyytFOHmPZY917kwdwLG0RbOjWOnKmnm3PeHjaoLLMie7kPLQw==} - yallist@5.0.0: - resolution: {integrity: sha512-YgvUTfwqyc7UXVMrB+SImsVYSmTS8X/tSrtdNZMImM+n7+QTriRXyXim0mBrTXNeqzVF0KWGgHPeiyViFFrNDw==} - engines: {node: '>=18'} + stream-shift@1.0.1: + resolution: {integrity: sha512-AiisoFqQ0vbGcZgQPY1cdP2I76glaVA/RauYR4G4thNFgkTqr90yXTo4LYX60Jl+sIlPNHHdGSwo01AvbKUSVQ==} - yargs-parser@18.1.3: - resolution: {integrity: sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==} - engines: {node: '>=6'} + stream-to-array@2.3.0: + resolution: {integrity: sha512-UsZtOYEn4tWU2RGLOXr/o/xjRBftZRlG3dEWoaHr8j4GuypJ3isitGbVyjQKAuMu+xbiop8q224TjiZWc4XTZA==} - yargs-parser@20.2.9: - resolution: {integrity: sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==} - engines: {node: '>=10'} + stream-to-promise@2.2.0: + resolution: {integrity: sha512-HAGUASw8NT0k8JvIVutB2Y/9iBk7gpgEyAudXwNJmZERdMITGdajOa4VJfD/kNiA3TppQpTP4J+CtcHwdzKBAw==} - yargs-parser@21.1.1: - resolution: {integrity: sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==} + streamx@2.23.0: + resolution: {integrity: sha512-kn+e44esVfn2Fa/O0CPFcex27fjIL6MkVae0Mm6q+E6f0hWv578YCERbv+4m02cjxvDsPKLnmxral/rR6lBMAg==} + + strict-event-emitter@0.5.1: + resolution: {integrity: sha512-vMgjE/GGEPEFnhFub6pa4FmJBRBVOLpIII2hvCZ8Kzb7K0hlHo7mQv6xYrBvCL2LtAIBwFUK8wvuJgTVSQ5MFQ==} + + strict-uri-encode@2.0.0: + resolution: {integrity: sha512-QwiXZgpRcKkhTj2Scnn++4PKtWsH0kpzZ62L2R6c/LUVYv7hVnZqcg2+sMuT6R7Jusu1vviK/MFsu6kNJfWlEQ==} + engines: {node: '>=4'} + + string-width@4.2.3: + resolution: {integrity: sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==} + engines: {node: '>=8'} + + string-width@5.1.2: + resolution: {integrity: sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==} engines: {node: '>=12'} - yargs-parser@22.0.0: - resolution: {integrity: sha512-rwu/ClNdSMpkSrUb+d6BRsSkLUq1fmfsY6TOpYzTwvwkg1/NRG85KBy3kq++A8LKQwX6lsu+aWad+2khvuXrqw==} - engines: {node: ^20.19.0 || ^22.12.0 || >=23} + string_decoder@1.1.1: + resolution: {integrity: sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==} - yargs-unparser@2.0.0: - resolution: {integrity: sha512-7pRTIA9Qc1caZ0bZ6RYRGbHJthJWuakf+WmHK0rVeLkNrrGhfoabBNdue6kdINI6r4if7ocq9aD/n7xwKOdzOA==} - engines: {node: '>=10'} + string_decoder@1.3.0: + resolution: {integrity: sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==} - yargs@15.4.1: - resolution: {integrity: sha512-aePbxDmcYW++PaqBsJ+HYUFwCdv4LVvdnhBy78E57PIor8/OVvhMrADFFEDh8DHDFRv/O9i3lPhsENjO7QX0+A==} + stringify-entities@4.0.4: + resolution: {integrity: sha512-IwfBptatlO+QCJUo19AqvrPNqlVMpW9YEL2LIVY+Rpv2qsjCGxaDLNRgeGsQWJhfItebuJhsGSLjaBbNSQ+ieg==} + + strip-ansi@6.0.1: + resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} engines: {node: '>=8'} - yargs@16.2.0: - resolution: {integrity: sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==} - engines: {node: '>=10'} + strip-ansi@7.1.2: + resolution: {integrity: sha512-gmBGslpoQJtgnMAvOVqGZpEz9dyoKTCzy2nfz/n8aIFhN/jCE/rCmcxabB6jOOHV+0WNnylOxaxBQPSvcWklhA==} + engines: {node: '>=12'} - yargs@17.7.2: - resolution: {integrity: sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==} + strip-bom@3.0.0: + resolution: {integrity: sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==} + engines: {node: '>=4'} + + strip-final-newline@2.0.0: + resolution: {integrity: sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==} + engines: {node: '>=6'} + + strip-final-newline@3.0.0: + resolution: {integrity: sha512-dOESqjYr96iWYylGObzd39EuNTa5VJxyvVAEm5Jnh7KGo75V43Hk1odPQkNDyXNmUR6k+gEiDVXnjB8HJ3crXw==} engines: {node: '>=12'} - yargs@18.0.0: - resolution: {integrity: sha512-4UEqdc2RYGHZc7Doyqkrqiln3p9X2DZVxaGbwhn2pi7MrRagKaOcIKe8L3OxYcbhXLgLFUS3zAYuQjKBQgmuNg==} - engines: {node: ^20.19.0 || ^22.12.0 || >=23} + strip-final-newline@4.0.0: + resolution: {integrity: sha512-aulFJcD6YK8V1G7iRB5tigAP4TsHBZZrOV8pjV++zdUwmeV8uzbY7yn6h9MswN62adStNZFuCIx4haBnRuMDaw==} + engines: {node: '>=18'} + + strip-hex-prefix@1.0.0: + resolution: {integrity: sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==} + engines: {node: '>=6.5.0', npm: '>=3'} - yargs@4.8.1: - resolution: {integrity: sha512-LqodLrnIDM3IFT+Hf/5sxBnEGECrfdC1uIbgZeJmESCSo4HoCAaKEus8MylXHAkdacGc0ye+Qa+dpkuom8uVYA==} + strip-json-comments@3.1.1: + resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==} + engines: {node: '>=8'} - yesno@0.3.1: - resolution: {integrity: sha512-7RbCXegyu6DykWPWU0YEtW8gFJH8KBL2d5l2fqB0XpkH0Y9rk59YSSWpzEv7yNJBGAouPc67h3kkq0CZkpBdFw==} + strip-json-comments@5.0.1: + resolution: {integrity: sha512-0fk9zBqO67Nq5M/m45qHCJxylV/DhBlIOVExqgOMiCCrzrhU6tCibRXNqE3jwJLftzE9SNuZtYbpzcO+i9FiKw==} + engines: {node: '>=14.16'} - yn@3.1.1: - resolution: {integrity: sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==} - engines: {node: '>=6'} + strip-literal@1.3.0: + resolution: {integrity: sha512-PugKzOsyXpArk0yWmUwqOZecSO0GH0bPoctLcqNDH9J04pVW3lflYE0ujElBGTloevcxF5MofAOZ7C5l2b+wLg==} - yocto-queue@0.1.0: - resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} - engines: {node: '>=10'} + strip-literal@3.1.0: + resolution: {integrity: sha512-8r3mkIM/2+PpjHoOtiAW8Rg3jJLHaV7xPwG+YRGrv6FP0wwk/toTpATxWYOW0BKdWwl82VT2tFYi5DlROa0Mxg==} - zksync-web3@0.14.4: - resolution: {integrity: sha512-kYehMD/S6Uhe1g434UnaMN+sBr9nQm23Ywn0EUP5BfQCsbjcr3ORuS68PosZw8xUTu3pac7G6YMSnNHk+fwzvg==} - deprecated: This package has been deprecated in favor of zksync-ethers@5.0.0 + strnum@2.1.2: + resolution: {integrity: sha512-l63NF9y/cLROq/yqKXSLtcMeeyOfnSQlfMSlzFt/K73oIaD8DGaQWd7Z34X9GPiKqP5rbSh84Hl4bOlLcjiSrQ==} + + structured-clone-es@1.0.0: + resolution: {integrity: sha512-FL8EeKFFyNQv5cMnXI31CIMCsFarSVI2bF0U0ImeNE3g/F1IvJQyqzOXxPBRXiwQfyBTlbNe88jh1jFW0O/jiQ==} + + styled-jsx@5.1.6: + resolution: {integrity: sha512-qSVyDTeMotdvQYoHWLNGwRFJHC+i+ZvdBRYosOFgC+Wg1vx4frN2/RG/NA7SYqqvKNLf39P2LSRA2pu6n0XYZA==} + engines: {node: '>= 12.0.0'} peerDependencies: - ethers: ^5.7.0 + '@babel/core': '*' + babel-plugin-macros: '*' + react: '>= 16.8.0 || 17.x.x || ^18.0.0-0 || ^19.0.0-0' + peerDependenciesMeta: + '@babel/core': + optional: true + babel-plugin-macros: + optional: true - zod-validation-error@4.0.2: - resolution: {integrity: sha512-Q6/nZLe6jxuU80qb/4uJ4t5v2VEZ44lzQjPDhYJNztRQ4wyWc6VF3D3Kb/fAuPetZQnhS3hnajCf9CsWesghLQ==} - engines: {node: '>=18.0.0'} + stylehacks@7.0.7: + resolution: {integrity: sha512-bJkD0JkEtbRrMFtwgpJyBbFIwfDDONQ1Ov3sDLZQP8HuJ73kBOyx66H4bOcAbVWmnfLdvQ0AJwXxOMkpujcO6g==} + engines: {node: ^18.12.0 || ^20.9.0 || >=22.0} peerDependencies: - zod: ^3.25.0 || ^4.0.0 + postcss: ^8.4.32 - zod@3.25.76: - resolution: {integrity: sha512-gzUt/qt81nXsFGKIFcC3YnfEAx5NkunCfnDlvuBSSFS02bcXu4Lmea0AFIUwbLWxWPx3d9p8S5QoaujKcNQxcQ==} + summary@2.1.0: + resolution: {integrity: sha512-nMIjMrd5Z2nuB2RZCKJfFMjgS3fygbeyGk9PxPPaJR1RIcyN9yn4A63Isovzm3ZtQuEkLBVgMdPup8UeLH7aQw==} - zod@4.2.0: - resolution: {integrity: sha512-Bd5fw9wlIhtqCCxotZgdTOMwGm1a0u75wARVEY9HMs1X17trvA/lMi4+MGK5EUfYkXVTbX8UDiDKW4OgzHVUZw==} + superjson@2.2.1: + resolution: {integrity: sha512-8iGv75BYOa0xRJHK5vRLEjE2H/i4lulTjzpUXic3Eg8akftYjkmQDa8JARQ42rlczXyFR3IeRoeFCc7RxHsYZA==} + engines: {node: '>=16'} - zstd-codec@0.1.5: - resolution: {integrity: sha512-v3fyjpK8S/dpY/X5WxqTK3IoCnp/ZOLxn144GZVlNUjtwAchzrVo03h+oMATFhCIiJ5KTr4V3vDQQYz4RU684g==} + superjson@2.2.6: + resolution: {integrity: sha512-H+ue8Zo4vJmV2nRjpx86P35lzwDT3nItnIsocgumgr0hHMQ+ZGq5vrERg9kJBo5AWGmxZDhzDo+WVIJqkB0cGA==} + engines: {node: '>=16'} -snapshots: + superstruct@1.0.3: + resolution: {integrity: sha512-8iTn3oSS8nRGn+C2pgXSKPI3jmpm6FExNazNpjvqS6ZUJQCej3PUXEKM8NjHBOs54ExM+LPW/FBRhymrdcCiSg==} + engines: {node: '>=14.0.0'} - 0xsequence@1.10.15(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10): - dependencies: - '@0xsequence/abi': 1.10.15 - '@0xsequence/account': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/api': 1.10.15 - '@0xsequence/auth': 1.10.15(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - '@0xsequence/core': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/guard': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/indexer': 1.10.15 - '@0xsequence/metadata': 1.10.15 - '@0xsequence/migration': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/multicall': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/network': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/provider': 1.10.15(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - '@0xsequence/relayer': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/sessions': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/signhub': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/utils': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/wallet': 1.10.15(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - transitivePeerDependencies: - - bufferutil - - utf-8-validate + supports-color@10.2.2: + resolution: {integrity: sha512-SS+jx45GF1QjgEXQx4NJZV9ImqmO2NPz5FNsIHrsDjh2YsHnawpan7SNQ1o8NuhrbHZy9AZhIoCUiCeaW/C80g==} + engines: {node: '>=18'} - '@0xsequence/abi@1.10.15': {} + supports-color@5.5.0: + resolution: {integrity: sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==} + engines: {node: '>=4'} - '@0xsequence/abi@2.3.43': {} + supports-color@7.2.0: + resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} + engines: {node: '>=8'} - '@0xsequence/account@1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10)': - dependencies: - '@0xsequence/abi': 1.10.15 - '@0xsequence/core': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/migration': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/network': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/relayer': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/sessions': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/utils': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/wallet': 1.10.15(bufferutil@4.1.0)(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - transitivePeerDependencies: - - bufferutil - - utf-8-validate + supports-color@8.1.1: + resolution: {integrity: sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==} + engines: {node: '>=10'} + + supports-color@9.4.0: + resolution: {integrity: sha512-VL+lNrEoIXww1coLPOmiEmK/0sGigko5COxI09KzHc2VJXJsQ37UaQ+8quuxjDeA7+KnLGTWRyOXSLLR2Wb4jw==} + engines: {node: '>=12'} + + supports-hyperlinks@3.0.0: + resolution: {integrity: sha512-QBDPHyPQDRTy9ku4URNGY5Lah8PAaXs6tAAwp55sL5WCsSW7GIfdf6W5ixfziW+t7wh3GVvHyHHyQ1ESsoRvaA==} + engines: {node: '>=14.18'} + + supports-preserve-symlinks-flag@1.0.0: + resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==} + engines: {node: '>= 0.4'} + + svgo@4.0.0: + resolution: {integrity: sha512-VvrHQ+9uniE+Mvx3+C9IEe/lWasXCU0nXMY2kZeLrHNICuRiC8uMPyM14UEaMOFA5mhyQqEkB02VoQ16n3DLaw==} + engines: {node: '>=16'} + hasBin: true + + system-architecture@0.1.0: + resolution: {integrity: sha512-ulAk51I9UVUyJgxlv9M6lFot2WP3e7t8Kz9+IS6D4rVba1tR9kON+Ey69f+1R4Q8cd45Lod6a4IcJIxnzGc/zA==} + engines: {node: '>=18'} + + tabbable@6.2.0: + resolution: {integrity: sha512-Cat63mxsVJlzYvN51JmVXIgNoUokrIaT2zLclCXjRd8boZ0004U4KCs/sToJ75C6sdlByWxpYnb5Boif1VSFew==} + + tagged-tag@1.0.0: + resolution: {integrity: sha512-yEFYrVhod+hdNyx7g5Bnkkb0G6si8HJurOoOEgC8B/O0uXLHlaey/65KRv6cuWBNhBgHKAROVpc7QyYqE5gFng==} + engines: {node: '>=20'} + + tailwind-merge@3.4.0: + resolution: {integrity: sha512-uSaO4gnW+b3Y2aWoWfFpX62vn2sR3skfhbjsEnaBI81WD1wBLlHZe5sWf0AqjksNdYTbGBEd0UasQMT3SNV15g==} + + tailwindcss@4.1.18: + resolution: {integrity: sha512-4+Z+0yiYyEtUVCScyfHCxOYP06L5Ne+JiHhY2IjR2KWMIWhJOYZKLSGZaP5HkZ8+bY0cxfzwDE5uOmzFXyIwxw==} + + tapable@2.2.1: + resolution: {integrity: sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ==} + engines: {node: '>=6'} + + tapable@2.3.0: + resolution: {integrity: sha512-g9ljZiwki/LfxmQADO3dEY1CbpmXT5Hm2fJ+QaGKwSXUylMybePR7/67YW7jOrrvjEgL1Fmz5kzyAjWVWLlucg==} + engines: {node: '>=6'} + + tar-stream@3.1.7: + resolution: {integrity: sha512-qJj60CXt7IU1Ffyc3NJMjh6EkuCFej46zUqJ4J7pqYlThyd9bO0XBTmcOIhSzZJVWfsLks0+nle/j538YAW9RQ==} + + tar@6.2.1: + resolution: {integrity: sha512-DZ4yORTwrbTj/7MZYq2w+/ZFdI6OZ/f9SFHR+71gIVUZhOQPHzVCLpvRnPgyaMpfWxxk/4ONva3GQSyNIKRv6A==} + engines: {node: '>=10'} + + tar@7.2.0: + resolution: {integrity: sha512-hctwP0Nb4AB60bj8WQgRYaMOuJYRAPMGiQUAotms5igN8ppfQM+IvjQ5HcKu1MaZh2Wy2KWVTe563Yj8dfc14w==} + engines: {node: '>=18'} + + tar@7.5.2: + resolution: {integrity: sha512-7NyxrTE4Anh8km8iEy7o0QYPs+0JKBTj5ZaqHg6B39erLg0qYXN3BijtShwbsNSvQ+LN75+KV+C4QR/f6Gwnpg==} + engines: {node: '>=18'} + + temp-dir@1.0.0: + resolution: {integrity: sha512-xZFXEGbG7SNC3itwBzI3RYjq/cEhBkx2hJuKGIUOcEULmkQExXiHat2z/qkISYsuR+IKumhEfKKbV5qXmhICFQ==} + engines: {node: '>=4'} + + tempy@0.2.1: + resolution: {integrity: sha512-LB83o9bfZGrntdqPuRdanIVCPReam9SOZKW0fOy5I9X3A854GGWi0tjCqoXEk84XIEYBc/x9Hq3EFop/H5wJaw==} + engines: {node: '>=4'} + + term-size@2.2.1: + resolution: {integrity: sha512-wK0Ri4fOGjv/XPy8SBHZChl8CM7uMc5VML7SqiQ0zG7+J5Vr+RMQDoHa2CNT6KHUnTGIXH34UDMkPzAUyapBZg==} + engines: {node: '>=8'} + + terser@5.44.1: + resolution: {integrity: sha512-t/R3R/n0MSwnnazuPpPNVO60LX0SKL45pyl9YlvxIdkH0Of7D5qM2EVe+yASRIlY5pZ73nclYJfNANGWPwFDZw==} + engines: {node: '>=10'} + hasBin: true + + test-exclude@7.0.1: + resolution: {integrity: sha512-pFYqmTw68LXVjeWJMST4+borgQP2AyMNbg1BpZh9LbyhUeNkeaPF9gzfPGUAnSMV3qPYdWUwDIjjCLiSDOl7vg==} + engines: {node: '>=18'} + + text-decoder@1.2.3: + resolution: {integrity: sha512-3/o9z3X0X0fTupwsYvR03pJ/DjWuqqrfwBgTQzdWDiQSm9KitAyz/9WqsT2JQW7KV2m+bC2ol/zqpW37NHxLaA==} + + thenify-all@1.6.0: + resolution: {integrity: sha512-RNxQH/qI8/t3thXJDwcstUO4zeqo64+Uy/+sNVRBx4Xn2OX+OZ9oP+iJnNFqplFra2ZUVeKCSa2oVWi3T4uVmA==} + engines: {node: '>=0.8'} + + thenify@3.3.1: + resolution: {integrity: sha512-RVZSIV5IG10Hk3enotrhvz0T9em6cyHBLkH/YAZuKqd8hRkKhSfCGIcP2KUY0EPxndzANBmNllzWPwak+bheSw==} + + thread-stream@0.15.2: + resolution: {integrity: sha512-UkEhKIg2pD+fjkHQKyJO3yoIvAP3N6RlNFt2dUhcS1FGvCD1cQa1M/PGknCLFIyZdtJOWQjejp7bdNqmN7zwdA==} + + throttleit@2.1.0: + resolution: {integrity: sha512-nt6AMGKW1p/70DF/hGBdJB57B8Tspmbp5gfJ8ilhLnt7kkr2ye7hzD6NVG8GGErk2HWF34igrL2CXmNIkzKqKw==} + engines: {node: '>=18'} + + time-span@4.0.0: + resolution: {integrity: sha512-MyqZCTGLDZ77u4k+jqg4UlrzPTPZ49NDlaekU6uuFaJLzPIN1woaRXCbGeqOfxwc3Y37ZROGAJ614Rdv7Olt+g==} + engines: {node: '>=10'} + + tiny-invariant@1.3.3: + resolution: {integrity: sha512-+FbBPE1o9QAYvviau/qC5SE3caw21q3xkvWKBtja5vgqOWIHHJ3ioaq1VPfn/Szqctz2bU/oYeKd9/z5BL+PVg==} + + tinybench@2.9.0: + resolution: {integrity: sha512-0+DUvqWMValLmha6lr4kD8iAMK1HzV0/aKnCtWb9v9641TnP/MFb7Pc2bxoxQjTXAErryXVgUOfv2YqNllqGeg==} + + tinyexec@0.3.2: + resolution: {integrity: sha512-KQQR9yN7R5+OSwaK0XQoj22pwHoTlgYqmUscPYoknOoWCWfj/5/ABTMRi69FrKU5ffPVh5QcFikpWJI/P1ocHA==} + + tinyexec@1.0.2: + resolution: {integrity: sha512-W/KYk+NFhkmsYpuHq5JykngiOCnxeVL8v8dFnqxSD8qEEdRfXk1SDM6JzNqcERbcGYj9tMrDQBYV9cjgnunFIg==} + engines: {node: '>=18'} + + tinyglobby@0.2.14: + resolution: {integrity: sha512-tX5e7OM1HnYr2+a2C/4V0htOcSQcoSTH9KgJnVvNm5zm/cyEWKJ7j7YutsH9CxMdtOkkLFy2AHrMci9IM8IPZQ==} + engines: {node: '>=12.0.0'} + + tinyglobby@0.2.15: + resolution: {integrity: sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ==} + engines: {node: '>=12.0.0'} + + tinypool@1.0.2: + resolution: {integrity: sha512-al6n+QEANGFOMf/dmUMsuS5/r9B06uwlyNjZZql/zv8J7ybHCgoihBNORZCY2mzUuAnomQa2JdhyHKzZxPCrFA==} + engines: {node: ^18.0.0 || >=20.0.0} + + tinyrainbow@1.2.0: + resolution: {integrity: sha512-weEDEq7Z5eTHPDh4xjX789+fHfF+P8boiFB+0vbWzpbnbsEr/GRaohi/uMKxg8RZMXnl1ItAi/IUHWMsjDV7kQ==} + engines: {node: '>=14.0.0'} + + tinyrainbow@2.0.0: + resolution: {integrity: sha512-op4nsTR47R6p0vMUUoYl/a+ljLFVtlfaXkLQmqfLR1qHma1h/ysYk4hEXZ880bf2CYgTskvTa/e196Vd5dDQXw==} + engines: {node: '>=14.0.0'} + + tinyspy@3.0.2: + resolution: {integrity: sha512-n1cw8k1k0x4pgA2+9XrOkFydTerNcJ1zWCO5Nn9scWHTD+5tp8dghT2x1uduQePZTZgd3Tupf+x9BxJjeJi77Q==} + engines: {node: '>=14.0.0'} + + tmp@0.0.33: + resolution: {integrity: sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==} + engines: {node: '>=0.6.0'} + + to-fast-properties@2.0.0: + resolution: {integrity: sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==} + engines: {node: '>=4'} + + to-regex-range@5.0.1: + resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} + engines: {node: '>=8.0'} + + toidentifier@1.0.0: + resolution: {integrity: sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==} + engines: {node: '>=0.6'} + + toidentifier@1.0.1: + resolution: {integrity: sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==} + engines: {node: '>=0.6'} + + totalist@3.0.1: + resolution: {integrity: sha512-sf4i37nQ2LBx4m3wB74y+ubopq6W/dIzXg0FDGjsYnZHVa1Da8FH853wlL2gtUhg+xJXjfk3kUZS3BRoQeoQBQ==} + engines: {node: '>=6'} + + tough-cookie@4.1.4: + resolution: {integrity: sha512-Loo5UUvLD9ScZ6jh8beX1T6sO1w2/MpCRpEP7V280GKMVUQ0Jzar2U3UJPsrdbziLEMMhu3Ujnq//rhiFuIeag==} + engines: {node: '>=6'} + + tr46@0.0.3: + resolution: {integrity: sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==} + + tree-kill@1.2.2: + resolution: {integrity: sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==} + hasBin: true + + trim-lines@3.0.1: + resolution: {integrity: sha512-kRj8B+YHZCc9kQYdWfJB2/oUl9rA99qbowYYBtr4ui4mZyAQ2JpvVBd/6U2YloATfqBhBTSMhTpgBHtU0Mf3Rg==} + + ts-essentials@7.0.3: + resolution: {integrity: sha512-8+gr5+lqO3G84KdiTSMRLtuyJ+nTBVRKuCrK4lidMPdVeEp0uqC875uE5NMcaA7YYMN7XsNiFQuMvasF8HT/xQ==} + peerDependencies: + typescript: '>=3.7.0' + + ts-morph@12.0.0: + resolution: {integrity: sha512-VHC8XgU2fFW7yO1f/b3mxKDje1vmyzFXHWzOYmKEkCEwcLjDtbdLgBQviqj4ZwP4MJkQtRo6Ha2I29lq/B+VxA==} + + ts-node@10.9.1: + resolution: {integrity: sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==} + hasBin: true + peerDependencies: + '@swc/core': '>=1.2.50' + '@swc/wasm': '>=1.2.50' + '@types/node': '*' + typescript: '>=2.7' + peerDependenciesMeta: + '@swc/core': + optional: true + '@swc/wasm': + optional: true + + ts-toolbelt@6.15.5: + resolution: {integrity: sha512-FZIXf1ksVyLcfr7M317jbB67XFJhOO1YqdTcuGaq9q5jLUoTikukZ+98TPjKiP2jC5CgmYdWWYs0s2nLSU0/1A==} + + tslib@1.14.1: + resolution: {integrity: sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==} + + tslib@2.7.0: + resolution: {integrity: sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA==} + + tslib@2.8.1: + resolution: {integrity: sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==} + + tsort@0.0.1: + resolution: {integrity: sha512-Tyrf5mxF8Ofs1tNoxA13lFeZ2Zrbd6cKbuH3V+MQ5sb6DtBj5FjrXVsRWT8YvNAQTqNoz66dz1WsbigI22aEnw==} + + tsx@4.19.2: + resolution: {integrity: sha512-pOUl6Vo2LUq/bSa8S5q7b91cgNSjctn9ugq/+Mvow99qW6x/UZYwzxy/3NmqoT66eHYfCVvFvACC58UBPFf28g==} + engines: {node: '>=18.0.0'} + hasBin: true + + turbo-darwin-64@2.7.2: + resolution: {integrity: sha512-dxY3X6ezcT5vm3coK6VGixbrhplbQMwgNsCsvZamS/+/6JiebqW9DKt4NwpgYXhDY2HdH00I7FWs3wkVuan4rA==} + cpu: [x64] + os: [darwin] + + turbo-darwin-arm64@2.7.2: + resolution: {integrity: sha512-1bXmuwPLqNFt3mzrtYcVx1sdJ8UYb124Bf48nIgcpMCGZy3kDhgxNv1503kmuK/37OGOZbsWSQFU4I08feIuSg==} + cpu: [arm64] + os: [darwin] + + turbo-linux-64@2.7.2: + resolution: {integrity: sha512-kP+TiiMaiPugbRlv57VGLfcjFNsFbo8H64wMBCPV2270Or2TpDCBULMzZrvEsvWFjT3pBFvToYbdp8/Kw0jAQg==} + cpu: [x64] + os: [linux] + + turbo-linux-arm64@2.7.2: + resolution: {integrity: sha512-VDJwQ0+8zjAfbyY6boNaWfP6RIez4ypKHxwkuB6SrWbOSk+vxTyW5/hEjytTwK8w/TsbKVcMDyvpora8tEsRFw==} + cpu: [arm64] + os: [linux] + + turbo-windows-64@2.7.2: + resolution: {integrity: sha512-rPjqQXVnI6A6oxgzNEE8DNb6Vdj2Wwyhfv3oDc+YM3U9P7CAcBIlKv/868mKl4vsBtz4ouWpTQNXG8vljgJO+w==} + cpu: [x64] + os: [win32] + + turbo-windows-arm64@2.7.2: + resolution: {integrity: sha512-tcnHvBhO515OheIFWdxA+qUvZzNqqcHbLVFc1+n+TJ1rrp8prYicQtbtmsiKgMvr/54jb9jOabU62URAobnB7g==} + cpu: [arm64] + os: [win32] + + turbo@2.7.2: + resolution: {integrity: sha512-5JIA5aYBAJSAhrhbyag1ZuMSgUZnHtI+Sq3H8D3an4fL8PeF+L1yYvbEJg47akP1PFfATMf5ehkqFnxfkmuwZQ==} + hasBin: true + + tweetnacl-util@0.15.1: + resolution: {integrity: sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==} + + tweetnacl@1.0.3: + resolution: {integrity: sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==} + + twoslash-protocol@0.2.12: + resolution: {integrity: sha512-5qZLXVYfZ9ABdjqbvPc4RWMr7PrpPaaDSeaYY55vl/w1j6H6kzsWK/urAEIXlzYlyrFmyz1UbwIt+AA0ck+wbg==} + + twoslash-vue@0.2.12: + resolution: {integrity: sha512-kxH60DLn2QBcN2wjqxgMDkyRgmPXsytv7fJIlsyFMDPSkm1/lMrI/UMrNAshNaRHcI+hv8x3h/WBgcvlb2RNAQ==} + peerDependencies: + typescript: '*' + + twoslash@0.2.12: + resolution: {integrity: sha512-tEHPASMqi7kqwfJbkk7hc/4EhlrKCSLcur+TcvYki3vhIfaRMXnXjaYFgXpoZRbT6GdprD4tGuVBEmTpUgLBsw==} + peerDependencies: + typescript: '*' + + type-fest@0.20.2: + resolution: {integrity: sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==} + engines: {node: '>=10'} + + type-fest@0.21.3: + resolution: {integrity: sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==} + engines: {node: '>=10'} + + type-fest@0.7.1: + resolution: {integrity: sha512-Ne2YiiGN8bmrmJJEuTWTLJR32nh/JdL1+PSicowtNb0WFpn59GK8/lfD61bVtzguz7b3PBt74nxpv/Pw5po5Rg==} + engines: {node: '>=8'} + + type-fest@4.18.2: + resolution: {integrity: sha512-+suCYpfJLAe4OXS6+PPXjW3urOS4IoP9waSiLuXfLgqZODKw/aWwASvzqE886wA0kQgGy0mIWyhd87VpqIy6Xg==} + engines: {node: '>=16'} + + type-fest@5.3.1: + resolution: {integrity: sha512-VCn+LMHbd4t6sF3wfU/+HKT63C9OoyrSIf4b+vtWHpt2U7/4InZG467YDNMFMR70DdHjAdpPWmw2lzRdg0Xqqg==} + engines: {node: '>=20'} + + type-level-regexp@0.1.17: + resolution: {integrity: sha512-wTk4DH3cxwk196uGLK/E9pE45aLfeKJacKmcEgEOA/q5dnPGNxXt0cfYdFxb57L+sEpf1oJH4Dnx/pnRcku9jg==} + + typescript@4.9.5: + resolution: {integrity: sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==} + engines: {node: '>=4.2.0'} + hasBin: true + + typescript@5.6.1-rc: + resolution: {integrity: sha512-E3b2+1zEFu84jB0YQi9BORDjz9+jGbwwy1Zi3G0LUNw7a7cePUrHMRNy8aPh53nXpkFGVHSxIZo5vKTfYaFiBQ==} + engines: {node: '>=14.17'} + hasBin: true + + typescript@5.8.3: + resolution: {integrity: sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==} + engines: {node: '>=14.17'} + hasBin: true + + typescript@5.9.3: + resolution: {integrity: sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==} + engines: {node: '>=14.17'} + hasBin: true + + ufo@1.5.3: + resolution: {integrity: sha512-Y7HYmWaFwPUmkoQCUIAYpKqkOf+SbVj/2fJJZ4RJMCfZp0rTGwRbzQD+HghfnhKOjL9E01okqz+ncJskGYfBNw==} + + ufo@1.6.1: + resolution: {integrity: sha512-9a4/uxlTWJ4+a5i0ooc1rU7C7YOw3wT+UGqdeNNHWnOF9qcMBgLRS+4IYUqbczewFx4mLEig6gawh7X6mFlEkA==} + + uid-promise@1.0.0: + resolution: {integrity: sha512-R8375j0qwXyIu/7R0tjdF06/sElHqbmdmWC9M2qQHpEVbvE4I5+38KJI7LUUmQMp7NVq4tKHiBMkT0NFM453Ig==} + + uint8arrays@3.1.0: + resolution: {integrity: sha512-ei5rfKtoRO8OyOIor2Rz5fhzjThwIHJZ3uyDPnDHTXbP0aMQ1RN/6AI5B5d9dBxJOU+BvOAk7ZQ1xphsX8Lrog==} + + uint8arrays@3.1.1: + resolution: {integrity: sha512-+QJa8QRnbdXVpHYjLoTpJIdCTiw9Ir62nocClWuXIq2JIh4Uta0cQsTSpFL678p2CN8B+XSApwcU+pQEqVpKWg==} + + ultrahtml@1.6.0: + resolution: {integrity: sha512-R9fBn90VTJrqqLDwyMph+HGne8eqY1iPfYhPzZrvKpIfwkWZbcYlfpsb8B9dTvBfpy1/hqAD7Wi8EKfP9e8zdw==} + + unconfig@0.3.13: + resolution: {integrity: sha512-N9Ph5NC4+sqtcOjPfHrRcHekBCadCXWTBzp2VYYbySOHW0PfD9XLCeXshTXjkPYwLrBr9AtSeU0CZmkYECJhng==} + + uncrypto@0.1.3: + resolution: {integrity: sha512-Ql87qFHB3s/De2ClA9e0gsnS6zXG27SkTiSJwjCc9MebbfapQfuPzumMIUMi38ezPZVNFcHI9sUIepeQfw8J8Q==} + + unctx@2.5.0: + resolution: {integrity: sha512-p+Rz9x0R7X+CYDkT+Xg8/GhpcShTlU8n+cf9OtOEf7zEQsNcCZO1dPKNRDqvUTaq+P32PMMkxWHwfrxkqfqAYg==} + + undici-types@5.26.5: + resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} + + undici-types@6.19.8: + resolution: {integrity: sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==} + + undici-types@6.21.0: + resolution: {integrity: sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==} + + undici-types@7.8.0: + resolution: {integrity: sha512-9UJ2xGDvQ43tYyVMpuHlsgApydB8ZKfVYTsLDhXkFL/6gfkp+U8xTGdh8pMJv1SpZna0zxG1DwsKZsreLbXBxw==} + + undici@5.28.3: + resolution: {integrity: sha512-3ItfzbrhDlINjaP0duwnNsKpDQk3acHI3gVJ1z4fmwMK31k5G9OVIAMLSIaP6w4FaGkaAkN6zaQO9LUvZ1t7VA==} + engines: {node: '>=14.0'} + + undici@5.28.4: + resolution: {integrity: sha512-72RFADWFqKmUb2hmmvNODKL3p9hcB6Gt2DOQMis1SEBaV6a4MH8soBvzg+95CYhCKPFedut2JY9bMfrDl9D23g==} + engines: {node: '>=14.0'} + + undici@5.29.0: + resolution: {integrity: sha512-raqeBD6NQK4SkWhQzeYKd1KmIG6dllBOTt55Rmkt4HtI9mwdWtJljnrXjAFUBLTSN67HWrOIZ3EPF4kjUw80Bg==} + engines: {node: '>=14.0'} + + unenv@2.0.0-rc.24: + resolution: {integrity: sha512-i7qRCmY42zmCwnYlh9H2SvLEypEFGye5iRmEMKjcGi7zk9UquigRjFtTLz0TYqr0ZGLZhaMHl/foy1bZR+Cwlw==} + + unhead@2.1.1: + resolution: {integrity: sha512-NOt8n2KybAOxSLfNXegAVai4SGU8bPKqWnqCzNAvnRH2i8mW+0bbFjN/L75LBgCSTiOjJSpANe5w2V34Grr7Cw==} + + unicode-emoji-modifier-base@1.0.0: + resolution: {integrity: sha512-yLSH4py7oFH3oG/9K+XWrz1pSi3dfUrWEnInbxMfArOfc1+33BlGPQtLsOYwvdMy11AwUBetYuaRxSPqgkq+8g==} + engines: {node: '>=4'} + + unicorn-magic@0.3.0: + resolution: {integrity: sha512-+QBBXBCvifc56fsbuxZQ6Sic3wqqc3WWaqxs58gvJrcOuN83HGTCwz3oS5phzU9LthRNE9VrJCFCLUgHeeFnfA==} + engines: {node: '>=18'} + + unimport@3.7.1: + resolution: {integrity: sha512-V9HpXYfsZye5bPPYUgs0Otn3ODS1mDUciaBlXljI4C2fTwfFpvFZRywmlOu943puN9sncxROMZhsZCjNXEpzEQ==} + + unimport@5.6.0: + resolution: {integrity: sha512-8rqAmtJV8o60x46kBAJKtHpJDJWkA2xcBqWKPI14MgUb05o1pnpnCnXSxedUXyeq7p8fR5g3pTo2BaswZ9lD9A==} + engines: {node: '>=18.12.0'} + + unique-string@1.0.0: + resolution: {integrity: sha512-ODgiYu03y5g76A1I9Gt0/chLCzQjvzDy7DsZGsLOE/1MrF6wriEskSncj1+/C58Xk/kPZDppSctDybCwOSaGAg==} + engines: {node: '>=4'} + + unist-util-is@6.0.0: + resolution: {integrity: sha512-2qCTHimwdxLfz+YzdGfkqNlH0tLi9xjTnHddPmJwtIG9MGsdbutfTc4P+haPD7l7Cjxf/WZj+we5qfVPvvxfYw==} + + unist-util-position@5.0.0: + resolution: {integrity: sha512-fucsC7HjXvkB5R3kTCO7kUjRdrS0BJt3M/FPxmHMBOm8JQi2BsHAHFsy27E0EolP8rp0NzXsJ+jNPyDWvOJZPA==} + + unist-util-stringify-position@4.0.0: + resolution: {integrity: sha512-0ASV06AAoKCDkS2+xw5RXJywruurpbC4JZSm7nr7MOt1ojAzvyyaO+UxZf18j8FCF6kmzCZKcAgN/yu2gm2XgQ==} + + unist-util-visit-parents@6.0.1: + resolution: {integrity: sha512-L/PqWzfTP9lzzEa6CKs0k2nARxTdZduw3zyh8d2NVBnsyvHjSX4TWse388YrrQKbvI8w20fGjGlhgT96WwKykw==} + + unist-util-visit@5.0.0: + resolution: {integrity: sha512-MR04uvD+07cwl/yhVuVWAtw+3GOR/knlL55Nd/wAdblk27GCVt3lqpTivy/tkJcZoNPzTwS1Y+KMojlLDhoTzg==} + + universalify@0.1.2: + resolution: {integrity: sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==} + engines: {node: '>= 4.0.0'} + + universalify@0.2.0: + resolution: {integrity: sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg==} + engines: {node: '>= 4.0.0'} + + universalify@2.0.1: + resolution: {integrity: sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==} + engines: {node: '>= 10.0.0'} + + unocss@0.59.4: + resolution: {integrity: sha512-QmCVjRObvVu/gsGrJGVt0NnrdhFFn314BUZn2WQyXV9rIvHLRmG5bIu0j5vibJkj7ZhFchTrnTM1pTFXP1xt5g==} + engines: {node: '>=14'} + peerDependencies: + '@unocss/webpack': 0.59.4 + vite: ^2.9.0 || ^3.0.0-0 || ^4.0.0 || ^5.0.0-0 + peerDependenciesMeta: + '@unocss/webpack': + optional: true + vite: + optional: true + + unpipe@1.0.0: + resolution: {integrity: sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==} + engines: {node: '>= 0.8'} + + unplugin-utils@0.2.5: + resolution: {integrity: sha512-gwXJnPRewT4rT7sBi/IvxKTjsms7jX7QIDLOClApuZwR49SXbrB1z2NLUZ+vDHyqCj/n58OzRRqaW+B8OZi8vg==} + engines: {node: '>=18.12.0'} + + unplugin-utils@0.3.1: + resolution: {integrity: sha512-5lWVjgi6vuHhJ526bI4nlCOmkCIF3nnfXkCMDeMJrtdvxTs6ZFCM8oNufGTsDbKv/tJ/xj8RpvXjRuPBZJuJog==} + engines: {node: '>=20.19.0'} + + unplugin-vue-router@0.15.0: + resolution: {integrity: sha512-PyGehCjd9Ny9h+Uer4McbBjjib3lHihcyUEILa7pHKl6+rh8N7sFyw4ZkV+N30Oq2zmIUG7iKs3qpL0r+gXAaQ==} + peerDependencies: + '@vue/compiler-sfc': ^3.5.17 + vue-router: ^4.5.1 + peerDependenciesMeta: + vue-router: + optional: true + + unplugin@1.10.1: + resolution: {integrity: sha512-d6Mhq8RJeGA8UfKCu54Um4lFA0eSaRa3XxdAJg8tIdxbu1ubW0hBCZUL7yI2uGyYCRndvbK8FLHzqy2XKfeMsg==} + engines: {node: '>=14.0.0'} + + unplugin@2.3.11: + resolution: {integrity: sha512-5uKD0nqiYVzlmCRs01Fhs2BdkEgBS3SAVP6ndrBsuK42iC2+JHyxM05Rm9G8+5mkmRtzMZGY8Ct5+mliZxU/Ww==} + engines: {node: '>=18.12.0'} + + unstorage@1.10.2: + resolution: {integrity: sha512-cULBcwDqrS8UhlIysUJs2Dk0Mmt8h7B0E6mtR+relW9nZvsf/u4SkAYyNliPiPW7XtFNb5u3IUMkxGxFTTRTgQ==} + peerDependencies: + '@azure/app-configuration': ^1.5.0 + '@azure/cosmos': ^4.0.0 + '@azure/data-tables': ^13.2.2 + '@azure/identity': ^4.0.1 + '@azure/keyvault-secrets': ^4.8.0 + '@azure/storage-blob': ^12.17.0 + '@capacitor/preferences': ^5.0.7 + '@netlify/blobs': ^6.5.0 || ^7.0.0 + '@planetscale/database': ^1.16.0 + '@upstash/redis': ^1.28.4 + '@vercel/kv': ^1.0.1 + idb-keyval: ^6.2.1 + ioredis: ^5.3.2 + peerDependenciesMeta: + '@azure/app-configuration': + optional: true + '@azure/cosmos': + optional: true + '@azure/data-tables': + optional: true + '@azure/identity': + optional: true + '@azure/keyvault-secrets': + optional: true + '@azure/storage-blob': + optional: true + '@capacitor/preferences': + optional: true + '@netlify/blobs': + optional: true + '@planetscale/database': + optional: true + '@upstash/redis': + optional: true + '@vercel/kv': + optional: true + idb-keyval: + optional: true + ioredis: + optional: true + + unstorage@1.17.3: + resolution: {integrity: sha512-i+JYyy0DoKmQ3FximTHbGadmIYb8JEpq7lxUjnjeB702bCPum0vzo6oy5Mfu0lpqISw7hCyMW2yj4nWC8bqJ3Q==} + peerDependencies: + '@azure/app-configuration': ^1.8.0 + '@azure/cosmos': ^4.2.0 + '@azure/data-tables': ^13.3.0 + '@azure/identity': ^4.6.0 + '@azure/keyvault-secrets': ^4.9.0 + '@azure/storage-blob': ^12.26.0 + '@capacitor/preferences': ^6.0.3 || ^7.0.0 + '@deno/kv': '>=0.9.0' + '@netlify/blobs': ^6.5.0 || ^7.0.0 || ^8.1.0 || ^9.0.0 || ^10.0.0 + '@planetscale/database': ^1.19.0 + '@upstash/redis': ^1.34.3 + '@vercel/blob': '>=0.27.1' + '@vercel/functions': ^2.2.12 || ^3.0.0 + '@vercel/kv': ^1.0.1 + aws4fetch: ^1.0.20 + db0: '>=0.2.1' + idb-keyval: ^6.2.1 + ioredis: ^5.4.2 + uploadthing: ^7.4.4 + peerDependenciesMeta: + '@azure/app-configuration': + optional: true + '@azure/cosmos': + optional: true + '@azure/data-tables': + optional: true + '@azure/identity': + optional: true + '@azure/keyvault-secrets': + optional: true + '@azure/storage-blob': + optional: true + '@capacitor/preferences': + optional: true + '@deno/kv': + optional: true + '@netlify/blobs': + optional: true + '@planetscale/database': + optional: true + '@upstash/redis': + optional: true + '@vercel/blob': + optional: true + '@vercel/functions': + optional: true + '@vercel/kv': + optional: true + aws4fetch: + optional: true + db0: + optional: true + idb-keyval: + optional: true + ioredis: + optional: true + uploadthing: + optional: true + + untun@0.1.3: + resolution: {integrity: sha512-4luGP9LMYszMRZwsvyUd9MrxgEGZdZuZgpVQHEEX0lCYFESasVRvZd0EYpCkOIbJKHMuv0LskpXc/8Un+MJzEQ==} + hasBin: true + + untyped@1.4.2: + resolution: {integrity: sha512-nC5q0DnPEPVURPhfPQLahhSTnemVtPzdx7ofiRxXpOB2SYnb3MfdU3DVGyJdS8Lx+tBWeAePO8BfU/3EgksM7Q==} + hasBin: true + + untyped@2.0.0: + resolution: {integrity: sha512-nwNCjxJTjNuLCgFr42fEak5OcLuB3ecca+9ksPFNvtfYSLpjf+iJqSIaSnIile6ZPbKYxI5k2AfXqeopGudK/g==} + hasBin: true + + unwasm@0.3.11: + resolution: {integrity: sha512-Vhp5gb1tusSQw5of/g3Q697srYgMXvwMgXMjcG4ZNga02fDX9coxJ9fAb0Ci38hM2Hv/U1FXRPGgjP2BYqhNoQ==} + + update-browserslist-db@1.0.15: + resolution: {integrity: sha512-K9HWH62x3/EalU1U6sjSZiylm9C8tgq2mSvshZpqc7QE69RaA2qjhkW2HlNA0tFpEbtyFz7HTqbSdN4MSwUodA==} + hasBin: true + peerDependencies: + browserslist: '>= 4.21.0' + + update-browserslist-db@1.2.3: + resolution: {integrity: sha512-Js0m9cx+qOgDxo0eMiFGEueWztz+d4+M3rGlmKPT+T4IS/jP4ylw3Nwpu6cpTTP8R1MAC1kF4VbdLt3ARf209w==} + hasBin: true + peerDependencies: + browserslist: '>= 4.21.0' + + uqr@0.1.2: + resolution: {integrity: sha512-MJu7ypHq6QasgF5YRTjqscSzQp/W11zoUk6kvmlH+fmWEs63Y0Eib13hYFwAzagRJcVY8WVnlV+eBDUGMJ5IbA==} + + uri-js@4.4.1: + resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==} + + url-parse@1.5.10: + resolution: {integrity: sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==} + + use-callback-ref@1.3.3: + resolution: {integrity: sha512-jQL3lRnocaFtu3V00JToYz/4QkNWswxijDaCVNZRiRTO3HQDLsdu1ZtmIUvV4yPp+rvWm5j0y0TG/S61cuijTg==} + engines: {node: '>=10'} + peerDependencies: + '@types/react': '*' + react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + + use-sidecar@1.1.3: + resolution: {integrity: sha512-Fedw0aZvkhynoPYlA5WXrMCAMm+nSWdZt6lzJQ7Ok8S6Q+VsHmHpRWndVRJ8Be0ZbkfPc5LRYH+5XrzXcEeLRQ==} + engines: {node: '>=10'} + peerDependencies: + '@types/react': '*' + react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc + peerDependenciesMeta: + '@types/react': + optional: true + + use-sync-external-store@1.2.0: + resolution: {integrity: sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==} + peerDependencies: + react: ^16.8.0 || ^17.0.0 || ^18.0.0 + + use-sync-external-store@1.4.0: + resolution: {integrity: sha512-9WXSPC5fMv61vaupRkCKCxsPxBocVnwakBEkMIHHpkTTg6icbJtg6jzgtLDm4bl3cSHAca52rYWih0k4K3PfHw==} + peerDependencies: + react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 + + utf-8-validate@5.0.10: + resolution: {integrity: sha512-Z6czzLq4u8fPOyx7TU6X3dvUZVvoJmxSQ+IcrlmagKhilxlhZgxPK6C5Jqbkw1IDUmFTM+cz9QDnnLTwDz/2gQ==} + engines: {node: '>=6.14.2'} + + utf-8-validate@6.0.5: + resolution: {integrity: sha512-EYZR+OpIXp9Y1eG1iueg8KRsY8TuT8VNgnanZ0uA3STqhHQTLwbl+WX76/9X5OY12yQubymBpaBSmMPkSTQcKA==} + engines: {node: '>=6.14.2'} + + util-deprecate@1.0.2: + resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==} + + util@0.12.5: + resolution: {integrity: sha512-kZf/K6hEIrWHI6XqOFUiiMa+79wE/D8Q+NCNAWclkyg3b4d2k7s0QGepNjiABc+aR3N1PAyHL7p6UcLY6LmrnA==} + + uuid@10.0.0: + resolution: {integrity: sha512-8XkAphELsDnEGrDxUOHB3RGvXz6TeuYSGEZBOjtTtPm2lwhGBjLgOzLHB63IUWfBpNucQjND6d3AOudO+H3RWQ==} + hasBin: true + + uuid@8.3.2: + resolution: {integrity: sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==} + hasBin: true + + uuid@9.0.1: + resolution: {integrity: sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==} + hasBin: true + + v8-compile-cache-lib@3.0.1: + resolution: {integrity: sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==} + + validate-npm-package-name@5.0.1: + resolution: {integrity: sha512-OljLrQ9SQdOUqTaQxqL5dEfZWrXExyyWsozYlAWFawPVNuD83igl7uJD2RTkNMbniIYgt8l81eCJGIdQF7avLQ==} + engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} + + valtio@1.13.2: + resolution: {integrity: sha512-Qik0o+DSy741TmkqmRfjq+0xpZBXi/Y6+fXZLn0xNF1z/waFMbE3rkivv5Zcf9RrMUp6zswf2J7sbh2KBlba5A==} + engines: {node: '>=12.20.0'} + peerDependencies: + '@types/react': '>=16.8' + react: '>=16.8' + peerDependenciesMeta: + '@types/react': + optional: true + react: + optional: true + + vercel@48.12.1: + resolution: {integrity: sha512-+lMj+qIXI/Iy7UXKu1wpFCwCaeV1lmrUdBbYQWXBM1/9XsX8vUfohHLkPrPSam8tDyVghKmaYu1ZD5uuHgo5uw==} + engines: {node: '>= 18'} + hasBin: true + + vfile-message@4.0.2: + resolution: {integrity: sha512-jRDZ1IMLttGj41KcZvlrYAaI3CfqpLpfpf+Mfig13viT6NKvRzWZ+lXz0Y5D60w6uJIBAOGq9mSHf0gktF0duw==} + + vfile@6.0.1: + resolution: {integrity: sha512-1bYqc7pt6NIADBJ98UiG0Bn/CHIVOoZ/IyEkqIruLg0mE1BKzkOXY2D6CSqQIcKqgadppE5lrxgWXJmXd7zZJw==} + + viem@2.10.8: + resolution: {integrity: sha512-ttCXlDmjjcZ8M/eJezXFzDtHj+RFOjEQ3elmXnCC7suXo/y8CuIM1LrIoyUFk7LKIE5E+bzmWUErS4u/MQBtpQ==} + peerDependencies: + typescript: '>=5.0.4' + peerDependenciesMeta: + typescript: + optional: true + + viem@2.17.0: + resolution: {integrity: sha512-+gaVlsfDsHL1oYdjpatdRxW1WK/slLYVvpOws3fEdLfQFUToezKI6YLC9l1g2uKm4Hg3OdGX1KQy/G7/58tTKQ==} + peerDependencies: + typescript: '>=5.0.4' + peerDependenciesMeta: + typescript: + optional: true + + viem@2.23.2: + resolution: {integrity: sha512-NVmW/E0c5crMOtbEAqMF0e3NmvQykFXhLOc/CkLIXOlzHSA6KXVz3CYVmaKqBF8/xtjsjHAGjdJN3Ru1kFJLaA==} + peerDependencies: + typescript: '>=5.0.4' + peerDependenciesMeta: + typescript: + optional: true + + viem@2.31.4: + resolution: {integrity: sha512-0UZ/asvzl6p44CIBRDbwEcn3HXIQQurBZcMo5qmLhQ8s27Ockk+RYohgTLlpLvkYs8/t4UUEREAbHLuek1kXcw==} + peerDependencies: + typescript: '>=5.0.4' + peerDependenciesMeta: + typescript: + optional: true + + viem@2.43.3: + resolution: {integrity: sha512-zM251fspfSjENCtfmT7cauuD+AA/YAlkFU7cksdEQJxj7wDuO0XFRWRH+RMvfmTFza88B9kug5cKU+Wk2nAjJg==} + peerDependencies: + typescript: '>=5.0.4' + peerDependenciesMeta: + typescript: + optional: true + + viem@2.43.5: + resolution: {integrity: sha512-QuJpuEMEPM3EreN+vX4mVY68Sci0+zDxozYfbh/WfV+SSy/Gthm74PH8XmitXdty1xY54uTCJ+/Gbbd1IiMPSA==} + peerDependencies: + typescript: '>=5.0.4' + peerDependenciesMeta: + typescript: + optional: true + + vite-dev-rpc@1.1.0: + resolution: {integrity: sha512-pKXZlgoXGoE8sEKiKJSng4hI1sQ4wi5YT24FCrwrLt6opmkjlqPPVmiPWWJn8M8byMxRGzp1CrFuqQs4M/Z39A==} + peerDependencies: + vite: ^2.9.0 || ^3.0.0-0 || ^4.0.0-0 || ^5.0.0-0 || ^6.0.1 || ^7.0.0-0 + + vite-hot-client@2.1.0: + resolution: {integrity: sha512-7SpgZmU7R+dDnSmvXE1mfDtnHLHQSisdySVR7lO8ceAXvM0otZeuQQ6C8LrS5d/aYyP/QZ0hI0L+dIPrm4YlFQ==} + peerDependencies: + vite: ^2.6.0 || ^3.0.0 || ^4.0.0 || ^5.0.0-0 || ^6.0.0-0 || ^7.0.0-0 + + vite-node@2.1.9: + resolution: {integrity: sha512-AM9aQ/IPrW/6ENLQg3AGY4K1N2TGZdR5e4gu/MmmR2xR3Ll1+dib+nook92g4TV3PXVyeyxdWwtaCAiUL0hMxA==} + engines: {node: ^18.0.0 || >=20.0.0} + hasBin: true + + vite-node@3.2.4: + resolution: {integrity: sha512-EbKSKh+bh1E1IFxeO0pg1n4dvoOTt0UDiXMd/qn++r98+jPO1xtJilvXldeuQ8giIB5IkpjCgMleHMNEsGH6pg==} + engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0} + hasBin: true + + vite-plugin-checker@0.10.3: + resolution: {integrity: sha512-f4sekUcDPF+T+GdbbE8idb1i2YplBAoH+SfRS0e/WRBWb2rYb1Jf5Pimll0Rj+3JgIYWwG2K5LtBPCXxoibkLg==} + engines: {node: '>=14.16'} + peerDependencies: + '@biomejs/biome': '>=1.7' + eslint: '>=7' + meow: ^13.2.0 + optionator: ^0.9.4 + stylelint: '>=16' + typescript: '*' + vite: '>=2.0.0' + vls: '*' + vti: '*' + vue-tsc: ~2.2.10 || ^3.0.0 + peerDependenciesMeta: + '@biomejs/biome': + optional: true + eslint: + optional: true + meow: + optional: true + optionator: + optional: true + stylelint: + optional: true + typescript: + optional: true + vls: + optional: true + vti: + optional: true + vue-tsc: + optional: true + + vite-plugin-inspect@11.3.3: + resolution: {integrity: sha512-u2eV5La99oHoYPHE6UvbwgEqKKOQGz86wMg40CCosP6q8BkB6e5xPneZfYagK4ojPJSj5anHCrnvC20DpwVdRA==} + engines: {node: '>=14'} + peerDependencies: + '@nuxt/kit': '*' + vite: ^6.0.0 || ^7.0.0-0 + peerDependenciesMeta: + '@nuxt/kit': + optional: true + + vite-plugin-vue-tracer@1.2.0: + resolution: {integrity: sha512-a9Z/TLpxwmoE9kIcv28wqQmiszM7ec4zgndXWEsVD/2lEZLRGzcg7ONXmplzGF/UP5W59QNtS809OdywwpUWQQ==} + peerDependencies: + vite: ^6.0.0 || ^7.0.0 + vue: ^3.5.0 + + vite@5.4.21: + resolution: {integrity: sha512-o5a9xKjbtuhY6Bi5S3+HvbRERmouabWbyUcpXXUA1u+GNUKoROi9byOJ8M0nHbHYHkYICiMlqxkg1KkYmm25Sw==} + engines: {node: ^18.0.0 || >=20.0.0} + hasBin: true + peerDependencies: + '@types/node': ^18.0.0 || >=20.0.0 + less: '*' + lightningcss: ^1.21.0 + sass: '*' + sass-embedded: '*' + stylus: '*' + sugarss: '*' + terser: ^5.4.0 + peerDependenciesMeta: + '@types/node': + optional: true + less: + optional: true + lightningcss: + optional: true + sass: + optional: true + sass-embedded: + optional: true + stylus: + optional: true + sugarss: + optional: true + terser: + optional: true + + vite@7.3.0: + resolution: {integrity: sha512-dZwN5L1VlUBewiP6H9s2+B3e3Jg96D0vzN+Ry73sOefebhYr9f94wwkMNN/9ouoU8pV1BqA1d1zGk8928cx0rg==} + engines: {node: ^20.19.0 || >=22.12.0} + hasBin: true + peerDependencies: + '@types/node': ^20.19.0 || >=22.12.0 + jiti: '>=1.21.0' + less: ^4.0.0 + lightningcss: ^1.21.0 + sass: ^1.70.0 + sass-embedded: ^1.70.0 + stylus: '>=0.54.8' + sugarss: ^5.0.0 + terser: ^5.16.0 + tsx: ^4.8.1 + yaml: ^2.4.2 + peerDependenciesMeta: + '@types/node': + optional: true + jiti: + optional: true + less: + optional: true + lightningcss: + optional: true + sass: + optional: true + sass-embedded: + optional: true + stylus: + optional: true + sugarss: + optional: true + terser: + optional: true + tsx: + optional: true + yaml: + optional: true + + vitepress@1.5.0: + resolution: {integrity: sha512-q4Q/G2zjvynvizdB3/bupdYkCJe2umSAMv9Ju4d92E6/NXJ59z70xB0q5p/4lpRyAwflDsbwy1mLV9Q5+nlB+g==} + hasBin: true + peerDependencies: + markdown-it-mathjax3: ^4 + postcss: ^8 + peerDependenciesMeta: + markdown-it-mathjax3: + optional: true + postcss: + optional: true + + vitest@2.1.9: + resolution: {integrity: sha512-MSmPM9REYqDGBI8439mA4mWhV5sKmDlBKWIYbA3lRb2PTHACE0mgKwA8yQ2xq9vxDTuk4iPrECBAEW2aoFXY0Q==} + engines: {node: ^18.0.0 || >=20.0.0} + hasBin: true + peerDependencies: + '@edge-runtime/vm': '*' + '@types/node': ^18.0.0 || >=20.0.0 + '@vitest/browser': 2.1.9 + '@vitest/ui': 2.1.9 + happy-dom: '*' + jsdom: '*' + peerDependenciesMeta: + '@edge-runtime/vm': + optional: true + '@types/node': + optional: true + '@vitest/browser': + optional: true + '@vitest/ui': + optional: true + happy-dom: + optional: true + jsdom: + optional: true + + vscode-uri@3.1.0: + resolution: {integrity: sha512-/BpdSx+yCQGnCvecbyXdxHDkuk55/G3xwnC0GqY4gmQ3j+A+g8kzzgB4Nk/SINjqn6+waqw3EgbVF2QKExkRxQ==} + + vue-bundle-renderer@2.2.0: + resolution: {integrity: sha512-sz/0WEdYH1KfaOm0XaBmRZOWgYTEvUDt6yPYaUzl4E52qzgWLlknaPPTTZmp6benaPTlQAI/hN1x3tAzZygycg==} + + vue-component-type-helpers@2.0.16: + resolution: {integrity: sha512-qisL/iAfdO++7w+SsfYQJVPj6QKvxp4i1MMxvsNO41z/8zu3KuAw9LkhKUfP/kcOWGDxESp+pQObWppXusejCA==} + + vue-demi@0.14.10: + resolution: {integrity: sha512-nMZBOwuzabUO0nLgIcc6rycZEebF6eeUfaiQx9+WSk8e29IbLvPU9feI6tqW4kTo3hvoYAJkMh8n8D0fuISphg==} + engines: {node: '>=12'} + hasBin: true + peerDependencies: + '@vue/composition-api': ^1.0.0-rc.1 + vue: ^3.0.0-0 || ^2.6.0 + peerDependenciesMeta: + '@vue/composition-api': + optional: true + + vue-devtools-stub@0.1.0: + resolution: {integrity: sha512-RutnB7X8c5hjq39NceArgXg28WZtZpGc3+J16ljMiYnFhKvd8hITxSWQSQ5bvldxMDU6gG5mkxl1MTQLXckVSQ==} + + vue-resize@2.0.0-alpha.1: + resolution: {integrity: sha512-7+iqOueLU7uc9NrMfrzbG8hwMqchfVfSzpVlCMeJQe4pyibqyoifDNbKTZvwxZKDvGkB+PdFeKvnGZMoEb8esg==} + peerDependencies: + vue: ^3.0.0 + + vue-router@4.3.2: + resolution: {integrity: sha512-hKQJ1vDAZ5LVkKEnHhmm1f9pMiWIBNGF5AwU67PdH7TyXCj/a4hTccuUuYCAMgJK6rO/NVYtQIEN3yL8CECa7Q==} + peerDependencies: + vue: ^3.2.0 + + vue-router@4.6.4: + resolution: {integrity: sha512-Hz9q5sa33Yhduglwz6g9skT8OBPii+4bFn88w6J+J4MfEo4KRRpmiNG/hHHkdbRFlLBOqxN8y8gf2Fb0MTUgVg==} + peerDependencies: + vue: ^3.5.0 + + vue-template-compiler@2.7.16: + resolution: {integrity: sha512-AYbUWAJHLGGQM7+cNTELw+KsOG9nl2CnSv467WobS5Cv9uk3wFcnr1Etsz2sEIHEZvw1U+o9mRlEO6QbZvUPGQ==} + + vue-tsc@2.0.16: + resolution: {integrity: sha512-/gHAWJa216PeEhfxtAToIbxdWgw01wuQzo48ZUqMYVEyNqDp+OYV9xMO5HaPS2P3Ls0+EsjguMZLY4cGobX4Ew==} + hasBin: true + peerDependencies: + typescript: '*' + + vue@3.4.27: + resolution: {integrity: sha512-8s/56uK6r01r1icG/aEOHqyMVxd1bkYcSe9j8HcKtr/xTOFWvnzIVTehNW+5Yt89f+DLBe4A569pnZLS5HzAMA==} + peerDependencies: + typescript: '*' + peerDependenciesMeta: + typescript: + optional: true + + vue@3.5.12: + resolution: {integrity: sha512-CLVZtXtn2ItBIi/zHZ0Sg1Xkb7+PU32bJJ8Bmy7ts3jxXTcbfsEfBivFYYWz1Hur+lalqGAh65Coin0r+HRUfg==} + peerDependencies: + typescript: '*' + peerDependenciesMeta: + typescript: + optional: true + + vue@3.5.26: + resolution: {integrity: sha512-SJ/NTccVyAoNUJmkM9KUqPcYlY+u8OVL1X5EW9RIs3ch5H2uERxyyIUI4MRxVCSOiEcupX9xNGde1tL9ZKpimA==} + peerDependencies: + typescript: '*' + peerDependenciesMeta: + typescript: + optional: true + + wcwidth@1.0.1: + resolution: {integrity: sha512-XHPEwS0q6TaxcvG85+8EYkbiCux2XtWG2mkc47Ng2A77BQu9+DqIOJldST4HgPkuea7dvKSj5VgX3P1d4rW8Tg==} + + web-vitals@0.2.4: + resolution: {integrity: sha512-6BjspCO9VriYy12z356nL6JBS0GYeEcA457YyRzD+dD6XYCQ75NKhcOHUMHentOE7OcVCIXXDvOm0jKFfQG2Gg==} + + webextension-polyfill@0.10.0: + resolution: {integrity: sha512-c5s35LgVa5tFaHhrZDnr3FpQpjj1BB+RXhLTYUxGqBVN460HkbM8TBtEqdXWbpTKfzwCcjAZVF7zXCYSKtcp9g==} + + webidl-conversions@3.0.1: + resolution: {integrity: sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==} + + webpack-bundle-analyzer@4.10.1: + resolution: {integrity: sha512-s3P7pgexgT/HTUSYgxJyn28A+99mmLq4HsJepMPzu0R8ImJc52QNqaFYW1Z2z2uIb1/J3eYgaAWVpaC+v/1aAQ==} + engines: {node: '>= 10.13.0'} + hasBin: true + + webpack-sources@3.2.3: + resolution: {integrity: sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w==} + engines: {node: '>=10.13.0'} + + webpack-virtual-modules@0.6.1: + resolution: {integrity: sha512-poXpCylU7ExuvZK8z+On3kX+S8o/2dQ/SVYueKA0D4WEMXROXgY8Ez50/bQEUmvoSMMrWcrJqCHuhAbsiwg7Dg==} + + webpack-virtual-modules@0.6.2: + resolution: {integrity: sha512-66/V2i5hQanC51vBQKPH4aI8NMAcBW59FVBs+rC7eGHupMyfn34q7rZIE+ETlJ+XTevqfUhVVBgSUNSW2flEUQ==} + + whatwg-mimetype@3.0.0: + resolution: {integrity: sha512-nt+N2dzIutVRxARx1nghPKGv1xHikU7HKdfafKkLNLindmPU/ch3U31NOCGGA/dmPcmb1VlofO0vnKAcsm0o/Q==} + engines: {node: '>=12'} + + whatwg-url@5.0.0: + resolution: {integrity: sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==} + + which-module@2.0.0: + resolution: {integrity: sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q==} + + which-typed-array@1.1.19: + resolution: {integrity: sha512-rEvr90Bck4WZt9HHFC4DJMsjvu7x+r6bImz0/BrbWb7A2djJ8hnZMrWnHo9F8ssv0OMErasDhftrfROTyqSDrw==} + engines: {node: '>= 0.4'} + + which@1.3.1: + resolution: {integrity: sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==} + hasBin: true + + which@2.0.2: + resolution: {integrity: sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==} + engines: {node: '>= 8'} + hasBin: true + + which@5.0.0: + resolution: {integrity: sha512-JEdGzHwwkrbWoGOlIHqQ5gtprKGOenpDHpxE9zVR1bWbOtYRyPPHMe9FaP6x61CmNaTThSkb0DAJte5jD+DmzQ==} + engines: {node: ^18.17.0 || >=20.5.0} + hasBin: true + + why-is-node-running@2.3.0: + resolution: {integrity: sha512-hUrmaWBdVDcxvYqnyh09zunKzROWjbZTiNy8dBEjkS7ehEDQibXJ7XvlmtbwuTclUiIyN+CyXQD4Vmko8fNm8w==} + engines: {node: '>=8'} + hasBin: true + + widest-line@3.1.0: + resolution: {integrity: sha512-NsmoXalsWVDMGupxZ5R08ka9flZjjiLvHVAWYOKtiKM8ujtZWr9cRffak+uSE48+Ob8ObalXpwyeUiyDD6QFgg==} + engines: {node: '>=8'} + + workerpool@6.2.1: + resolution: {integrity: sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw==} + + wrap-ansi@6.2.0: + resolution: {integrity: sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==} + engines: {node: '>=8'} + + wrap-ansi@7.0.0: + resolution: {integrity: sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==} + engines: {node: '>=10'} + + wrap-ansi@8.1.0: + resolution: {integrity: sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==} + engines: {node: '>=12'} + + wrappy@1.0.2: + resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} + + ws@7.5.10: + resolution: {integrity: sha512-+dbF1tHwZpXcbOJdVOkzLDxZP1ailvSxM6ZweXTegylPny803bFhA+vqBYw4s31NSAk4S2Qz+AKXK9a4wkdjcQ==} + engines: {node: '>=8.3.0'} + peerDependencies: + bufferutil: ^4.0.1 + utf-8-validate: ^5.0.2 + peerDependenciesMeta: + bufferutil: + optional: true + utf-8-validate: + optional: true + + ws@7.5.9: + resolution: {integrity: sha512-F+P9Jil7UiSKSkppIiD94dN07AwvFixvLIj1Og1Rl9GGMuNipJnV9JzjD6XuqmAeiswGvUmNLjr5cFuXwNS77Q==} + engines: {node: '>=8.3.0'} + peerDependencies: + bufferutil: ^4.0.1 + utf-8-validate: ^5.0.2 + peerDependenciesMeta: + bufferutil: + optional: true + utf-8-validate: + optional: true + + ws@8.13.0: + resolution: {integrity: sha512-x9vcZYTrFPC7aSIbj7sRCYo7L/Xb8Iy+pW0ng0wt2vCJv7M9HOMy0UoN3rr+IFC7hb7vXoqS+P9ktyLLLhO+LA==} + engines: {node: '>=10.0.0'} + peerDependencies: + bufferutil: ^4.0.1 + utf-8-validate: '>=5.0.2' + peerDependenciesMeta: + bufferutil: + optional: true + utf-8-validate: + optional: true + + ws@8.17.1: + resolution: {integrity: sha512-6XQFvXTkbfUOZOKKILFG1PDK2NDQs4azKQl26T0YS5CxqWLgXajbPZ+h4gZekJyRqFU8pvnbAbbs/3TgRPy+GQ==} + engines: {node: '>=10.0.0'} + peerDependencies: + bufferutil: ^4.0.1 + utf-8-validate: '>=5.0.2' + peerDependenciesMeta: + bufferutil: + optional: true + utf-8-validate: + optional: true + + ws@8.18.0: + resolution: {integrity: sha512-8VbfWfHLbbwu3+N6OKsOMpBdT4kXPDDB9cJk2bJ6mh9ucxdlnNvH1e+roYkKmN9Nxw2yjz7VzeO9oOz2zJ04Pw==} + engines: {node: '>=10.0.0'} + peerDependencies: + bufferutil: ^4.0.1 + utf-8-validate: '>=5.0.2' + peerDependenciesMeta: + bufferutil: + optional: true + utf-8-validate: + optional: true + + ws@8.18.2: + resolution: {integrity: sha512-DMricUmwGZUVr++AEAe2uiVM7UoO9MAVZMDu05UQOaUII0lp+zOzLLU4Xqh/JvTqklB1T4uELaaPBKyjE1r4fQ==} + engines: {node: '>=10.0.0'} + peerDependencies: + bufferutil: ^4.0.1 + utf-8-validate: '>=5.0.2' + peerDependenciesMeta: + bufferutil: + optional: true + utf-8-validate: + optional: true + + ws@8.18.3: + resolution: {integrity: sha512-PEIGCY5tSlUt50cqyMXfCzX+oOPqN0vuGqWzbcJ2xvnkzkq46oOpz7dQaTDBdfICb4N14+GARUDw2XV2N4tvzg==} + engines: {node: '>=10.0.0'} + peerDependencies: + bufferutil: ^4.0.1 + utf-8-validate: '>=5.0.2' + peerDependenciesMeta: + bufferutil: + optional: true + utf-8-validate: + optional: true + + wsl-utils@0.1.0: + resolution: {integrity: sha512-h3Fbisa2nKGPxCpm89Hk33lBLsnaGBvctQopaBSOW/uIs6FTe1ATyAnKFJrzVs9vpGdsTe73WF3V4lIsk4Gacw==} + engines: {node: '>=18'} + + xdg-app-paths@5.1.0: + resolution: {integrity: sha512-RAQ3WkPf4KTU1A8RtFx3gWywzVKe00tfOPFfl2NDGqbIFENQO4kqAJp7mhQjNj/33W5x5hiWWUdyfPq/5SU3QA==} + engines: {node: '>=6'} + + xdg-portable@7.3.0: + resolution: {integrity: sha512-sqMMuL1rc0FmMBOzCpd0yuy9trqF2yTTVe+E9ogwCSWQCdDEtQUwrZPT6AxqtsFGRNxycgncbP/xmOOSPw5ZUw==} + engines: {node: '>= 6.0'} + + xmlhttprequest-ssl@2.1.2: + resolution: {integrity: sha512-TEU+nJVUUnA4CYJFLvK5X9AOeH4KvDvhIfm0vV1GaQRtchnG0hgK5p8hw/xjv8cunWYCsiPCSDzObPyhEwq3KQ==} + engines: {node: '>=0.4.0'} + + xtend@4.0.2: + resolution: {integrity: sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==} + engines: {node: '>=0.4'} + + y18n@4.0.3: + resolution: {integrity: sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ==} + + y18n@5.0.8: + resolution: {integrity: sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==} + engines: {node: '>=10'} + + yallist@2.1.2: + resolution: {integrity: sha512-ncTzHV7NvsQZkYe1DW7cbDLm0YpzHmZF5r/iyP3ZnQtMiJ+pjzisCiMNI+Sj+xQF5pXhSHxSB3uDbsBTzY/c2A==} + + yallist@3.1.1: + resolution: {integrity: sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==} + + yallist@4.0.0: + resolution: {integrity: sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==} + + yallist@5.0.0: + resolution: {integrity: sha512-YgvUTfwqyc7UXVMrB+SImsVYSmTS8X/tSrtdNZMImM+n7+QTriRXyXim0mBrTXNeqzVF0KWGgHPeiyViFFrNDw==} + engines: {node: '>=18'} + + yaml@2.8.2: + resolution: {integrity: sha512-mplynKqc1C2hTVYxd0PU2xQAc22TI1vShAYGksCCfxbn/dFwnHTNi1bvYsBTkhdUNtGIf5xNOg938rrSSYvS9A==} + engines: {node: '>= 14.6'} + hasBin: true + + yargs-parser@18.1.3: + resolution: {integrity: sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==} + engines: {node: '>=6'} + + yargs-parser@20.2.4: + resolution: {integrity: sha512-WOkpgNhPTlE73h4VFAFsOnomJVaovO8VqLDzy5saChRBFQFBoMYirowyW+Q9HB4HFF4Z7VZTiG3iSzJJA29yRA==} + engines: {node: '>=10'} + + yargs-parser@21.1.1: + resolution: {integrity: sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==} + engines: {node: '>=12'} + + yargs-unparser@2.0.0: + resolution: {integrity: sha512-7pRTIA9Qc1caZ0bZ6RYRGbHJthJWuakf+WmHK0rVeLkNrrGhfoabBNdue6kdINI6r4if7ocq9aD/n7xwKOdzOA==} + engines: {node: '>=10'} + + yargs@15.4.1: + resolution: {integrity: sha512-aePbxDmcYW++PaqBsJ+HYUFwCdv4LVvdnhBy78E57PIor8/OVvhMrADFFEDh8DHDFRv/O9i3lPhsENjO7QX0+A==} + engines: {node: '>=8'} + + yargs@16.2.0: + resolution: {integrity: sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==} + engines: {node: '>=10'} + + yargs@17.7.2: + resolution: {integrity: sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==} + engines: {node: '>=12'} + + yauzl-clone@1.0.4: + resolution: {integrity: sha512-igM2RRCf3k8TvZoxR2oguuw4z1xasOnA31joCqHIyLkeWrvAc2Jgay5ISQ2ZplinkoGaJ6orCz56Ey456c5ESA==} + engines: {node: '>=6'} + + yauzl-promise@2.1.3: + resolution: {integrity: sha512-A1pf6fzh6eYkK0L4Qp7g9jzJSDrM6nN0bOn5T0IbY4Yo3w+YkWlHFkJP7mzknMXjqusHFHlKsK2N+4OLsK2MRA==} + engines: {node: '>=6'} + + yauzl@2.10.0: + resolution: {integrity: sha512-p4a9I6X6nu6IhoGmBqAcbJy1mlC4j27vEPZX9F4L4/vZT3Lyq1VkFHw/V/PUcB9Buo+DG3iHkT0x3Qya58zc3g==} + + yn@3.1.1: + resolution: {integrity: sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==} + engines: {node: '>=6'} + + yocto-queue@0.1.0: + resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} + engines: {node: '>=10'} + + yoctocolors@2.0.2: + resolution: {integrity: sha512-Ct97huExsu7cWeEjmrXlofevF8CvzUglJ4iGUet5B8xn1oumtAZBpHU4GzYuoE6PVqcZ5hghtBrSlhwHuR1Jmw==} + engines: {node: '>=18'} + + youch-core@0.3.3: + resolution: {integrity: sha512-ho7XuGjLaJ2hWHoK8yFnsUGy2Y5uDpqSTq1FkHLK4/oqKtyUU1AFbOOxY4IpC9f0fTLjwYbslUz0Po5BpD1wrA==} + + youch@4.1.0-beta.13: + resolution: {integrity: sha512-3+AG1Xvt+R7M7PSDudhbfbwiyveW6B8PLBIwTyEC598biEYIjHhC89i6DBEvR0EZUjGY3uGSnC429HpIa2Z09g==} + + zip-stream@6.0.1: + resolution: {integrity: sha512-zK7YHHz4ZXpW89AHXUPbQVGKI7uvkd3hzusTdotCg1UxyaVtg0zFJSTfW/Dq5f7OBBVnq6cZIaC8Ti4hb6dtCA==} + engines: {node: '>= 14'} + + zod-validation-error@3.2.0: + resolution: {integrity: sha512-cYlPR6zuyrgmu2wRTdumEAJGuwI7eHVHGT+VyneAQxmRAKtGRL1/7pjz4wfLhz4J05f5qoSZc3rGacswgyTjjw==} + engines: {node: '>=18.0.0'} + peerDependencies: + zod: ^3.18.0 + + zod@3.22.4: + resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} + + zod@3.25.20: + resolution: {integrity: sha512-z03fqpTMDF1G02VLKUMt6vyACE7rNWkh3gpXVHgPTw28NPtDFRGvcpTtPwn2kMKtQ0idtYJUTxchytmnqYswcw==} + + zustand@5.0.0: + resolution: {integrity: sha512-LE+VcmbartOPM+auOjCCLQOsQ05zUTp8RkgwRzefUk+2jISdMMFnxvyTjA4YNWr5ZGXYbVsEMZosttuxUBkojQ==} + engines: {node: '>=12.20.0'} + peerDependencies: + '@types/react': '>=18.0.0' + immer: '>=9.0.6' + react: '>=18.0.0' + use-sync-external-store: '>=1.2.0' + peerDependenciesMeta: + '@types/react': + optional: true + immer: + optional: true + react: + optional: true + use-sync-external-store: + optional: true + + zwitch@2.0.4: + resolution: {integrity: sha512-bXE4cR/kVZhKZX/RjPEflHaKVhUVl85noU3v6b8apfQEc1x4A+zBxjZ4lN8LqGd6WZ3dl98pY4o717VFmoPp+A==} + +snapshots: + + 0xsequence@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)): + dependencies: + '@0xsequence/abi': 2.3.39 + '@0xsequence/account': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/api': 2.3.39 + '@0xsequence/auth': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/guard': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/indexer': 2.3.39 + '@0xsequence/metadata': 2.3.39 + '@0xsequence/migration': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/network': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/provider': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/relayer': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/sessions': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/signhub': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/utils': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/wallet': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + + '@0xsequence/abi@2.3.39': {} + + '@0xsequence/account@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/abi': 2.3.39 + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/migration': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/network': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/relayer': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/sessions': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/utils': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/wallet': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + + '@0xsequence/api@2.3.39': {} + + '@0xsequence/auth@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/abi': 2.3.39 + '@0xsequence/account': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/api': 2.3.39 + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/ethauth': 1.0.0(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/indexer': 2.3.39 + '@0xsequence/metadata': 2.3.39 + '@0xsequence/migration': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/network': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/sessions': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/signhub': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/utils': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/wallet': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + + '@0xsequence/connect@0.0.0-20250924112110(@types/react-dom@18.3.0)(@types/react@18.3.27)(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(typescript@5.8.3)(utf-8-validate@6.0.5)(viem@2.43.5(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20))(wagmi@packages+react)(zod@3.25.20)': + dependencies: + 0xsequence: 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/api': 2.3.39 + '@0xsequence/auth': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/dapp-client': git+https://git@github.com:0xsequence/sequence.js.git#6a3501096be6b465b65c034b648549c0b69f8990(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20) + '@0xsequence/design-system': 2.1.11(@types/react-dom@18.3.0)(@types/react@18.3.27)(motion@12.23.26(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@0xsequence/ethauth': 1.0.0(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/hooks': 0.0.0-20250924112110(@0xsequence/api@2.3.39)(@0xsequence/indexer@2.3.39)(@0xsequence/metadata@2.3.39)(@0xsequence/network@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)))(@tanstack/react-query@5.90.15(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(viem@2.43.5(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20)) + '@0xsequence/indexer': 2.3.39 + '@0xsequence/metadata': 2.3.39 + '@0xsequence/network': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/provider': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/utils': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/waas': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@databeat/tracker': 0.9.3 + '@react-oauth/google': 0.11.1(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@tailwindcss/cli': 4.1.18 + '@tanstack/react-query': 5.90.15(react@18.3.1) + clsx: 2.1.1 + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + fuse.js: 7.1.0 + motion: 12.23.26(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + react: 18.3.1 + react-apple-signin-auth: 1.1.2(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + react-dom: 18.3.1(react@18.3.1) + tailwindcss: 4.1.18 + uuid: 10.0.0 + viem: 2.43.5(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20) + wagmi: link:packages/react + transitivePeerDependencies: + - '@emotion/is-prop-valid' + - '@types/react' + - '@types/react-dom' + - aws-crt + - bufferutil + - typescript + - utf-8-validate + - zod + + '@0xsequence/core@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/abi': 2.3.39 + '@0xsequence/utils': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + + '@0xsequence/dapp-client@git+https://git@github.com:0xsequence/sequence.js.git#6a3501096be6b465b65c034b648549c0b69f8990(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20)': + dependencies: + '@0xsequence/guard': git+https://git@github.com:0xsequence/sequence.js.git#501693a7bd7332ad10fd0f4a72e0dd153b44af0a(typescript@5.8.3)(zod@3.25.20) + '@0xsequence/relayer': git+https://git@github.com:0xsequence/sequence.js.git#07221565e01c85b8cd0bcbb45ace5f9baf57f498(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20) + '@0xsequence/wallet-core': git+https://git@github.com:0xsequence/sequence.js.git#a623e7dad948e7b281119b34b5b6343bdf502eb8(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20) + '@0xsequence/wallet-primitives': git+https://git@github.com:0xsequence/sequence.js.git#d2967108579e84603f3b5e05685c6f331c1f3db7(typescript@5.8.3)(zod@3.25.20) + ox: 0.7.2(typescript@5.8.3)(zod@3.25.20) + transitivePeerDependencies: + - bufferutil + - typescript + - utf-8-validate + - zod + + '@0xsequence/design-system@2.1.11(@types/react-dom@18.3.0)(@types/react@18.3.27)(motion@12.23.26(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/react-aspect-ratio': 1.1.8(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-checkbox': 1.3.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-collapsible': 1.1.12(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-dialog': 1.1.15(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-dropdown-menu': 2.1.16(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-progress': 1.1.8(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-radio-group': 1.3.8(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-select': 2.2.6(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-slot': 1.2.4(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-switch': 1.2.6(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-tabs': 1.1.13(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-toast': 1.2.15(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-tooltip': 1.2.8(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-visually-hidden': 1.2.4(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + class-variance-authority: 0.7.1 + clsx: 2.1.1 + motion: 12.23.26(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + react-hook-form: 7.69.0(react@18.3.1) + tailwind-merge: 3.4.0 + transitivePeerDependencies: + - '@types/react' + - '@types/react-dom' + + '@0xsequence/ethauth@1.0.0(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + js-base64: 3.7.8 + + '@0xsequence/guard@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/account': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/signhub': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/utils': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + + '@0xsequence/guard@git+https://git@github.com:0xsequence/sequence.js.git#501693a7bd7332ad10fd0f4a72e0dd153b44af0a(typescript@5.8.3)(zod@3.25.20)': + dependencies: + ox: 0.7.2(typescript@5.8.3)(zod@3.25.20) + transitivePeerDependencies: + - typescript + - zod + + '@0xsequence/hooks@0.0.0-20250924112110(@0xsequence/api@2.3.39)(@0xsequence/indexer@2.3.39)(@0xsequence/metadata@2.3.39)(@0xsequence/network@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)))(@tanstack/react-query@5.90.15(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(viem@2.43.5(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20))': + dependencies: + '@0xsequence/api': 2.3.39 + '@0xsequence/indexer': 2.3.39 + '@0xsequence/metadata': 2.3.39 + '@0xsequence/network': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@tanstack/react-query': 5.90.15(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + viem: 2.43.5(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20) + + '@0xsequence/indexer@2.3.39': {} + + '@0xsequence/metadata@2.3.39': {} + + '@0xsequence/migration@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/abi': 2.3.39 + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/wallet': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + + '@0xsequence/network@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/indexer': 2.3.39 + '@0xsequence/relayer': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/utils': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + + '@0xsequence/provider@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/abi': 2.3.39 + '@0xsequence/account': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/auth': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/migration': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/network': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/relayer': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/utils': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/wallet': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@databeat/tracker': 0.9.3 + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + eventemitter2: 6.4.9 + webextension-polyfill: 0.10.0 + + '@0xsequence/relayer@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/abi': 2.3.39 + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/utils': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + + '@0xsequence/relayer@git+https://git@github.com:0xsequence/sequence.js.git#07221565e01c85b8cd0bcbb45ace5f9baf57f498(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20)': + dependencies: + '@0xsequence/wallet-primitives': git+https://git@github.com:0xsequence/sequence.js.git#d2967108579e84603f3b5e05685c6f331c1f3db7(typescript@5.8.3)(zod@3.25.20) + mipd: 0.0.7(typescript@5.8.3) + ox: 0.7.2(typescript@5.8.3)(zod@3.25.20) + viem: 2.43.5(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20) + transitivePeerDependencies: + - bufferutil + - typescript + - utf-8-validate + - zod + + '@0xsequence/replacer@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/abi': 2.3.39 + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + + '@0xsequence/sessions@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/migration': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/replacer': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/utils': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + idb: 7.1.1 + + '@0xsequence/signhub@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + + '@0xsequence/utils@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + js-base64: 3.7.8 + + '@0xsequence/waas@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/network': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/utils': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@aws-sdk/client-cognito-identity-provider': 3.958.0 + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + idb: 7.1.1 + json-canonicalize: 1.2.0 + jwt-decode: 4.0.0 + transitivePeerDependencies: + - aws-crt + + '@0xsequence/wallet-contracts@3.0.1(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)': + dependencies: + '@typechain/ethers-v6': 0.5.1(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))(typescript@5.8.3) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + keccak256: 1.0.6 + transitivePeerDependencies: + - bufferutil + - typechain + - typescript + - utf-8-validate + + '@0xsequence/wallet-core@git+https://git@github.com:0xsequence/sequence.js.git#a623e7dad948e7b281119b34b5b6343bdf502eb8(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20)': + dependencies: + '@0xsequence/guard': git+https://git@github.com:0xsequence/sequence.js.git#501693a7bd7332ad10fd0f4a72e0dd153b44af0a(typescript@5.8.3)(zod@3.25.20) + '@0xsequence/relayer': git+https://git@github.com:0xsequence/sequence.js.git#07221565e01c85b8cd0bcbb45ace5f9baf57f498(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20) + '@0xsequence/wallet-primitives': git+https://git@github.com:0xsequence/sequence.js.git#d2967108579e84603f3b5e05685c6f331c1f3db7(typescript@5.8.3)(zod@3.25.20) + mipd: 0.0.7(typescript@5.8.3) + ox: 0.7.2(typescript@5.8.3)(zod@3.25.20) + viem: 2.31.4(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20) + transitivePeerDependencies: + - bufferutil + - typescript + - utf-8-validate + - zod + + '@0xsequence/wallet-primitives@0.0.0-20250915145821(typescript@5.8.3)(zod@3.25.20)': + dependencies: + ox: 0.7.2(typescript@5.8.3)(zod@3.25.20) + transitivePeerDependencies: + - typescript + - zod + + '@0xsequence/wallet-primitives@git+https://git@github.com:0xsequence/sequence.js.git#d2967108579e84603f3b5e05685c6f331c1f3db7(typescript@5.8.3)(zod@3.25.20)': + dependencies: + ox: 0.7.2(typescript@5.8.3)(zod@3.25.20) + transitivePeerDependencies: + - typescript + - zod + + '@0xsequence/wallet@2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))': + dependencies: + '@0xsequence/abi': 2.3.39 + '@0xsequence/core': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/network': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/relayer': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/signhub': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + '@0xsequence/utils': 2.3.39(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + + '@adraffy/ens-normalize@1.10.0': {} + + '@adraffy/ens-normalize@1.10.1': {} + + '@adraffy/ens-normalize@1.11.1': {} + + '@algolia/autocomplete-core@1.9.3(@algolia/client-search@5.12.0)(algoliasearch@5.12.0)': + dependencies: + '@algolia/autocomplete-plugin-algolia-insights': 1.9.3(@algolia/client-search@5.12.0)(algoliasearch@5.12.0) + '@algolia/autocomplete-shared': 1.9.3(@algolia/client-search@5.12.0)(algoliasearch@5.12.0) + transitivePeerDependencies: + - '@algolia/client-search' + - algoliasearch + - search-insights + + '@algolia/autocomplete-plugin-algolia-insights@1.9.3(@algolia/client-search@5.12.0)(algoliasearch@5.12.0)': + dependencies: + '@algolia/autocomplete-shared': 1.9.3(@algolia/client-search@5.12.0)(algoliasearch@5.12.0) + transitivePeerDependencies: + - '@algolia/client-search' + - algoliasearch + + '@algolia/autocomplete-preset-algolia@1.17.6(@algolia/client-search@5.12.0)(algoliasearch@5.12.0)': + dependencies: + '@algolia/autocomplete-shared': 1.17.6(@algolia/client-search@5.12.0)(algoliasearch@5.12.0) + '@algolia/client-search': 5.12.0 + algoliasearch: 5.12.0 + + '@algolia/autocomplete-shared@1.17.6(@algolia/client-search@5.12.0)(algoliasearch@5.12.0)': + dependencies: + '@algolia/client-search': 5.12.0 + algoliasearch: 5.12.0 + + '@algolia/autocomplete-shared@1.9.3(@algolia/client-search@5.12.0)(algoliasearch@5.12.0)': + dependencies: + '@algolia/client-search': 5.12.0 + algoliasearch: 5.12.0 + + '@algolia/client-abtesting@5.12.0': + dependencies: + '@algolia/client-common': 5.12.0 + '@algolia/requester-browser-xhr': 5.12.0 + '@algolia/requester-fetch': 5.12.0 + '@algolia/requester-node-http': 5.12.0 + + '@algolia/client-analytics@5.12.0': + dependencies: + '@algolia/client-common': 5.12.0 + '@algolia/requester-browser-xhr': 5.12.0 + '@algolia/requester-fetch': 5.12.0 + '@algolia/requester-node-http': 5.12.0 + + '@algolia/client-common@5.12.0': {} + + '@algolia/client-insights@5.12.0': + dependencies: + '@algolia/client-common': 5.12.0 + '@algolia/requester-browser-xhr': 5.12.0 + '@algolia/requester-fetch': 5.12.0 + '@algolia/requester-node-http': 5.12.0 + + '@algolia/client-personalization@5.12.0': + dependencies: + '@algolia/client-common': 5.12.0 + '@algolia/requester-browser-xhr': 5.12.0 + '@algolia/requester-fetch': 5.12.0 + '@algolia/requester-node-http': 5.12.0 + + '@algolia/client-query-suggestions@5.12.0': + dependencies: + '@algolia/client-common': 5.12.0 + '@algolia/requester-browser-xhr': 5.12.0 + '@algolia/requester-fetch': 5.12.0 + '@algolia/requester-node-http': 5.12.0 + + '@algolia/client-search@5.12.0': + dependencies: + '@algolia/client-common': 5.12.0 + '@algolia/requester-browser-xhr': 5.12.0 + '@algolia/requester-fetch': 5.12.0 + '@algolia/requester-node-http': 5.12.0 + + '@algolia/ingestion@1.12.0': + dependencies: + '@algolia/client-common': 5.12.0 + '@algolia/requester-browser-xhr': 5.12.0 + '@algolia/requester-fetch': 5.12.0 + '@algolia/requester-node-http': 5.12.0 + + '@algolia/monitoring@1.12.0': + dependencies: + '@algolia/client-common': 5.12.0 + '@algolia/requester-browser-xhr': 5.12.0 + '@algolia/requester-fetch': 5.12.0 + '@algolia/requester-node-http': 5.12.0 + + '@algolia/recommend@5.12.0': + dependencies: + '@algolia/client-common': 5.12.0 + '@algolia/requester-browser-xhr': 5.12.0 + '@algolia/requester-fetch': 5.12.0 + '@algolia/requester-node-http': 5.12.0 + + '@algolia/requester-browser-xhr@5.12.0': + dependencies: + '@algolia/client-common': 5.12.0 + + '@algolia/requester-fetch@5.12.0': + dependencies: + '@algolia/client-common': 5.12.0 + + '@algolia/requester-node-http@5.12.0': + dependencies: + '@algolia/client-common': 5.12.0 + + '@ampproject/remapping@2.2.1': + dependencies: + '@jridgewell/gen-mapping': 0.3.3 + '@jridgewell/trace-mapping': 0.3.17 + + '@ampproject/remapping@2.3.0': + dependencies: + '@jridgewell/gen-mapping': 0.3.13 + '@jridgewell/trace-mapping': 0.3.31 + + '@andrewbranch/untar.js@1.0.3': {} + + '@antfu/install-pkg@0.1.1': + dependencies: + execa: 5.1.1 + find-up: 5.0.0 + + '@antfu/utils@0.7.7': {} + + '@arethetypeswrong/cli@0.16.4': + dependencies: + '@arethetypeswrong/core': 0.16.4 + chalk: 4.1.2 + cli-table3: 0.6.5 + commander: 10.0.1 + marked: 9.1.6 + marked-terminal: 7.1.0(marked@9.1.6) + semver: 7.6.2 + + '@arethetypeswrong/core@0.16.4': + dependencies: + '@andrewbranch/untar.js': 1.0.3 + cjs-module-lexer: 1.4.1 + fflate: 0.8.2 + lru-cache: 10.4.3 + semver: 7.7.3 + typescript: 5.6.1-rc + validate-npm-package-name: 5.0.1 + + '@aws-crypto/sha256-browser@5.2.0': + dependencies: + '@aws-crypto/sha256-js': 5.2.0 + '@aws-crypto/supports-web-crypto': 5.2.0 + '@aws-crypto/util': 5.2.0 + '@aws-sdk/types': 3.957.0 + '@aws-sdk/util-locate-window': 3.957.0 + '@smithy/util-utf8': 2.3.0 + tslib: 2.8.1 + + '@aws-crypto/sha256-js@5.2.0': + dependencies: + '@aws-crypto/util': 5.2.0 + '@aws-sdk/types': 3.957.0 + tslib: 2.8.1 + + '@aws-crypto/supports-web-crypto@5.2.0': + dependencies: + tslib: 2.8.1 + + '@aws-crypto/util@5.2.0': + dependencies: + '@aws-sdk/types': 3.957.0 + '@smithy/util-utf8': 2.3.0 + tslib: 2.8.1 + + '@aws-sdk/client-cognito-identity-provider@3.958.0': + dependencies: + '@aws-crypto/sha256-browser': 5.2.0 + '@aws-crypto/sha256-js': 5.2.0 + '@aws-sdk/core': 3.957.0 + '@aws-sdk/credential-provider-node': 3.958.0 + '@aws-sdk/middleware-host-header': 3.957.0 + '@aws-sdk/middleware-logger': 3.957.0 + '@aws-sdk/middleware-recursion-detection': 3.957.0 + '@aws-sdk/middleware-user-agent': 3.957.0 + '@aws-sdk/region-config-resolver': 3.957.0 + '@aws-sdk/types': 3.957.0 + '@aws-sdk/util-endpoints': 3.957.0 + '@aws-sdk/util-user-agent-browser': 3.957.0 + '@aws-sdk/util-user-agent-node': 3.957.0 + '@smithy/config-resolver': 4.4.5 + '@smithy/core': 3.20.0 + '@smithy/fetch-http-handler': 5.3.8 + '@smithy/hash-node': 4.2.7 + '@smithy/invalid-dependency': 4.2.7 + '@smithy/middleware-content-length': 4.2.7 + '@smithy/middleware-endpoint': 4.4.1 + '@smithy/middleware-retry': 4.4.17 + '@smithy/middleware-serde': 4.2.8 + '@smithy/middleware-stack': 4.2.7 + '@smithy/node-config-provider': 4.3.7 + '@smithy/node-http-handler': 4.4.7 + '@smithy/protocol-http': 5.3.7 + '@smithy/smithy-client': 4.10.2 + '@smithy/types': 4.11.0 + '@smithy/url-parser': 4.2.7 + '@smithy/util-base64': 4.3.0 + '@smithy/util-body-length-browser': 4.2.0 + '@smithy/util-body-length-node': 4.2.1 + '@smithy/util-defaults-mode-browser': 4.3.16 + '@smithy/util-defaults-mode-node': 4.2.19 + '@smithy/util-endpoints': 3.2.7 + '@smithy/util-middleware': 4.2.7 + '@smithy/util-retry': 4.2.7 + '@smithy/util-utf8': 4.2.0 + tslib: 2.8.1 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/client-sso@3.958.0': + dependencies: + '@aws-crypto/sha256-browser': 5.2.0 + '@aws-crypto/sha256-js': 5.2.0 + '@aws-sdk/core': 3.957.0 + '@aws-sdk/middleware-host-header': 3.957.0 + '@aws-sdk/middleware-logger': 3.957.0 + '@aws-sdk/middleware-recursion-detection': 3.957.0 + '@aws-sdk/middleware-user-agent': 3.957.0 + '@aws-sdk/region-config-resolver': 3.957.0 + '@aws-sdk/types': 3.957.0 + '@aws-sdk/util-endpoints': 3.957.0 + '@aws-sdk/util-user-agent-browser': 3.957.0 + '@aws-sdk/util-user-agent-node': 3.957.0 + '@smithy/config-resolver': 4.4.5 + '@smithy/core': 3.20.0 + '@smithy/fetch-http-handler': 5.3.8 + '@smithy/hash-node': 4.2.7 + '@smithy/invalid-dependency': 4.2.7 + '@smithy/middleware-content-length': 4.2.7 + '@smithy/middleware-endpoint': 4.4.1 + '@smithy/middleware-retry': 4.4.17 + '@smithy/middleware-serde': 4.2.8 + '@smithy/middleware-stack': 4.2.7 + '@smithy/node-config-provider': 4.3.7 + '@smithy/node-http-handler': 4.4.7 + '@smithy/protocol-http': 5.3.7 + '@smithy/smithy-client': 4.10.2 + '@smithy/types': 4.11.0 + '@smithy/url-parser': 4.2.7 + '@smithy/util-base64': 4.3.0 + '@smithy/util-body-length-browser': 4.2.0 + '@smithy/util-body-length-node': 4.2.1 + '@smithy/util-defaults-mode-browser': 4.3.16 + '@smithy/util-defaults-mode-node': 4.2.19 + '@smithy/util-endpoints': 3.2.7 + '@smithy/util-middleware': 4.2.7 + '@smithy/util-retry': 4.2.7 + '@smithy/util-utf8': 4.2.0 + tslib: 2.8.1 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/core@3.957.0': + dependencies: + '@aws-sdk/types': 3.957.0 + '@aws-sdk/xml-builder': 3.957.0 + '@smithy/core': 3.20.0 + '@smithy/node-config-provider': 4.3.7 + '@smithy/property-provider': 4.2.7 + '@smithy/protocol-http': 5.3.7 + '@smithy/signature-v4': 5.3.7 + '@smithy/smithy-client': 4.10.2 + '@smithy/types': 4.11.0 + '@smithy/util-base64': 4.3.0 + '@smithy/util-middleware': 4.2.7 + '@smithy/util-utf8': 4.2.0 + tslib: 2.8.1 + + '@aws-sdk/credential-provider-env@3.957.0': + dependencies: + '@aws-sdk/core': 3.957.0 + '@aws-sdk/types': 3.957.0 + '@smithy/property-provider': 4.2.7 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + + '@aws-sdk/credential-provider-http@3.957.0': + dependencies: + '@aws-sdk/core': 3.957.0 + '@aws-sdk/types': 3.957.0 + '@smithy/fetch-http-handler': 5.3.8 + '@smithy/node-http-handler': 4.4.7 + '@smithy/property-provider': 4.2.7 + '@smithy/protocol-http': 5.3.7 + '@smithy/smithy-client': 4.10.2 + '@smithy/types': 4.11.0 + '@smithy/util-stream': 4.5.8 + tslib: 2.8.1 + + '@aws-sdk/credential-provider-ini@3.958.0': + dependencies: + '@aws-sdk/core': 3.957.0 + '@aws-sdk/credential-provider-env': 3.957.0 + '@aws-sdk/credential-provider-http': 3.957.0 + '@aws-sdk/credential-provider-login': 3.958.0 + '@aws-sdk/credential-provider-process': 3.957.0 + '@aws-sdk/credential-provider-sso': 3.958.0 + '@aws-sdk/credential-provider-web-identity': 3.958.0 + '@aws-sdk/nested-clients': 3.958.0 + '@aws-sdk/types': 3.957.0 + '@smithy/credential-provider-imds': 4.2.7 + '@smithy/property-provider': 4.2.7 + '@smithy/shared-ini-file-loader': 4.4.2 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/credential-provider-login@3.958.0': + dependencies: + '@aws-sdk/core': 3.957.0 + '@aws-sdk/nested-clients': 3.958.0 + '@aws-sdk/types': 3.957.0 + '@smithy/property-provider': 4.2.7 + '@smithy/protocol-http': 5.3.7 + '@smithy/shared-ini-file-loader': 4.4.2 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/credential-provider-node@3.958.0': + dependencies: + '@aws-sdk/credential-provider-env': 3.957.0 + '@aws-sdk/credential-provider-http': 3.957.0 + '@aws-sdk/credential-provider-ini': 3.958.0 + '@aws-sdk/credential-provider-process': 3.957.0 + '@aws-sdk/credential-provider-sso': 3.958.0 + '@aws-sdk/credential-provider-web-identity': 3.958.0 + '@aws-sdk/types': 3.957.0 + '@smithy/credential-provider-imds': 4.2.7 + '@smithy/property-provider': 4.2.7 + '@smithy/shared-ini-file-loader': 4.4.2 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/credential-provider-process@3.957.0': + dependencies: + '@aws-sdk/core': 3.957.0 + '@aws-sdk/types': 3.957.0 + '@smithy/property-provider': 4.2.7 + '@smithy/shared-ini-file-loader': 4.4.2 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + + '@aws-sdk/credential-provider-sso@3.958.0': + dependencies: + '@aws-sdk/client-sso': 3.958.0 + '@aws-sdk/core': 3.957.0 + '@aws-sdk/token-providers': 3.958.0 + '@aws-sdk/types': 3.957.0 + '@smithy/property-provider': 4.2.7 + '@smithy/shared-ini-file-loader': 4.4.2 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/credential-provider-web-identity@3.958.0': + dependencies: + '@aws-sdk/core': 3.957.0 + '@aws-sdk/nested-clients': 3.958.0 + '@aws-sdk/types': 3.957.0 + '@smithy/property-provider': 4.2.7 + '@smithy/shared-ini-file-loader': 4.4.2 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/middleware-host-header@3.957.0': + dependencies: + '@aws-sdk/types': 3.957.0 + '@smithy/protocol-http': 5.3.7 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + + '@aws-sdk/middleware-logger@3.957.0': + dependencies: + '@aws-sdk/types': 3.957.0 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + + '@aws-sdk/middleware-recursion-detection@3.957.0': + dependencies: + '@aws-sdk/types': 3.957.0 + '@aws/lambda-invoke-store': 0.2.2 + '@smithy/protocol-http': 5.3.7 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + + '@aws-sdk/middleware-user-agent@3.957.0': + dependencies: + '@aws-sdk/core': 3.957.0 + '@aws-sdk/types': 3.957.0 + '@aws-sdk/util-endpoints': 3.957.0 + '@smithy/core': 3.20.0 + '@smithy/protocol-http': 5.3.7 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + + '@aws-sdk/nested-clients@3.958.0': + dependencies: + '@aws-crypto/sha256-browser': 5.2.0 + '@aws-crypto/sha256-js': 5.2.0 + '@aws-sdk/core': 3.957.0 + '@aws-sdk/middleware-host-header': 3.957.0 + '@aws-sdk/middleware-logger': 3.957.0 + '@aws-sdk/middleware-recursion-detection': 3.957.0 + '@aws-sdk/middleware-user-agent': 3.957.0 + '@aws-sdk/region-config-resolver': 3.957.0 + '@aws-sdk/types': 3.957.0 + '@aws-sdk/util-endpoints': 3.957.0 + '@aws-sdk/util-user-agent-browser': 3.957.0 + '@aws-sdk/util-user-agent-node': 3.957.0 + '@smithy/config-resolver': 4.4.5 + '@smithy/core': 3.20.0 + '@smithy/fetch-http-handler': 5.3.8 + '@smithy/hash-node': 4.2.7 + '@smithy/invalid-dependency': 4.2.7 + '@smithy/middleware-content-length': 4.2.7 + '@smithy/middleware-endpoint': 4.4.1 + '@smithy/middleware-retry': 4.4.17 + '@smithy/middleware-serde': 4.2.8 + '@smithy/middleware-stack': 4.2.7 + '@smithy/node-config-provider': 4.3.7 + '@smithy/node-http-handler': 4.4.7 + '@smithy/protocol-http': 5.3.7 + '@smithy/smithy-client': 4.10.2 + '@smithy/types': 4.11.0 + '@smithy/url-parser': 4.2.7 + '@smithy/util-base64': 4.3.0 + '@smithy/util-body-length-browser': 4.2.0 + '@smithy/util-body-length-node': 4.2.1 + '@smithy/util-defaults-mode-browser': 4.3.16 + '@smithy/util-defaults-mode-node': 4.2.19 + '@smithy/util-endpoints': 3.2.7 + '@smithy/util-middleware': 4.2.7 + '@smithy/util-retry': 4.2.7 + '@smithy/util-utf8': 4.2.0 + tslib: 2.8.1 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/region-config-resolver@3.957.0': + dependencies: + '@aws-sdk/types': 3.957.0 + '@smithy/config-resolver': 4.4.5 + '@smithy/node-config-provider': 4.3.7 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + + '@aws-sdk/token-providers@3.958.0': + dependencies: + '@aws-sdk/core': 3.957.0 + '@aws-sdk/nested-clients': 3.958.0 + '@aws-sdk/types': 3.957.0 + '@smithy/property-provider': 4.2.7 + '@smithy/shared-ini-file-loader': 4.4.2 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/types@3.957.0': + dependencies: + '@smithy/types': 4.11.0 + tslib: 2.8.1 + + '@aws-sdk/util-endpoints@3.957.0': + dependencies: + '@aws-sdk/types': 3.957.0 + '@smithy/types': 4.11.0 + '@smithy/url-parser': 4.2.7 + '@smithy/util-endpoints': 3.2.7 + tslib: 2.8.1 + + '@aws-sdk/util-locate-window@3.957.0': + dependencies: + tslib: 2.8.1 + + '@aws-sdk/util-user-agent-browser@3.957.0': + dependencies: + '@aws-sdk/types': 3.957.0 + '@smithy/types': 4.11.0 + bowser: 2.13.1 + tslib: 2.8.1 + + '@aws-sdk/util-user-agent-node@3.957.0': + dependencies: + '@aws-sdk/middleware-user-agent': 3.957.0 + '@aws-sdk/types': 3.957.0 + '@smithy/node-config-provider': 4.3.7 + '@smithy/types': 4.11.0 + tslib: 2.8.1 + + '@aws-sdk/xml-builder@3.957.0': + dependencies: + '@smithy/types': 4.11.0 + fast-xml-parser: 5.2.5 + tslib: 2.8.1 + + '@aws/lambda-invoke-store@0.2.2': {} + + '@babel/code-frame@7.24.2': + dependencies: + '@babel/highlight': 7.24.5 + picocolors: 1.1.1 + + '@babel/code-frame@7.27.1': + dependencies: + '@babel/helper-validator-identifier': 7.28.5 + js-tokens: 4.0.0 + picocolors: 1.1.1 + + '@babel/compat-data@7.24.4': {} + + '@babel/compat-data@7.28.5': {} + + '@babel/core@7.24.5': + dependencies: + '@ampproject/remapping': 2.2.1 + '@babel/code-frame': 7.24.2 + '@babel/generator': 7.24.5 + '@babel/helper-compilation-targets': 7.23.6 + '@babel/helper-module-transforms': 7.24.5(@babel/core@7.24.5) + '@babel/helpers': 7.24.5 + '@babel/parser': 7.24.5 + '@babel/template': 7.24.0 + '@babel/traverse': 7.24.5 + '@babel/types': 7.24.5 + convert-source-map: 2.0.0 + debug: 4.4.3 + gensync: 1.0.0-beta.2 + json5: 2.2.3 + semver: 6.3.1 + transitivePeerDependencies: + - supports-color + + '@babel/core@7.28.5': + dependencies: + '@babel/code-frame': 7.27.1 + '@babel/generator': 7.28.5 + '@babel/helper-compilation-targets': 7.27.2 + '@babel/helper-module-transforms': 7.28.3(@babel/core@7.28.5) + '@babel/helpers': 7.28.4 + '@babel/parser': 7.28.5 + '@babel/template': 7.27.2 + '@babel/traverse': 7.28.5 + '@babel/types': 7.28.5 + '@jridgewell/remapping': 2.3.5 + convert-source-map: 2.0.0 + debug: 4.4.3 + gensync: 1.0.0-beta.2 + json5: 2.2.3 + semver: 6.3.1 + transitivePeerDependencies: + - supports-color + + '@babel/generator@7.24.5': + dependencies: + '@babel/types': 7.27.1 + '@jridgewell/gen-mapping': 0.3.5 + '@jridgewell/trace-mapping': 0.3.25 + jsesc: 2.5.2 + + '@babel/generator@7.28.5': + dependencies: + '@babel/parser': 7.28.5 + '@babel/types': 7.28.5 + '@jridgewell/gen-mapping': 0.3.13 + '@jridgewell/trace-mapping': 0.3.31 + jsesc: 3.1.0 + + '@babel/helper-annotate-as-pure@7.22.5': + dependencies: + '@babel/types': 7.28.5 + + '@babel/helper-annotate-as-pure@7.27.3': + dependencies: + '@babel/types': 7.28.5 + + '@babel/helper-compilation-targets@7.23.6': + dependencies: + '@babel/compat-data': 7.24.4 + '@babel/helper-validator-option': 7.23.5 + browserslist: 4.23.0 + lru-cache: 5.1.1 + semver: 6.3.1 + + '@babel/helper-compilation-targets@7.27.2': + dependencies: + '@babel/compat-data': 7.28.5 + '@babel/helper-validator-option': 7.27.1 + browserslist: 4.28.1 + lru-cache: 5.1.1 + semver: 6.3.1 + + '@babel/helper-create-class-features-plugin@7.24.5(@babel/core@7.24.5)': + dependencies: + '@babel/core': 7.24.5 + '@babel/helper-annotate-as-pure': 7.27.3 + '@babel/helper-environment-visitor': 7.22.20 + '@babel/helper-function-name': 7.23.0 + '@babel/helper-member-expression-to-functions': 7.24.5 + '@babel/helper-optimise-call-expression': 7.22.5 + '@babel/helper-replace-supers': 7.24.1(@babel/core@7.24.5) + '@babel/helper-skip-transparent-expression-wrappers': 7.27.1 + '@babel/helper-split-export-declaration': 7.24.5 + semver: 6.3.1 + transitivePeerDependencies: + - supports-color + + '@babel/helper-create-class-features-plugin@7.28.5(@babel/core@7.28.5)': + dependencies: + '@babel/core': 7.28.5 + '@babel/helper-annotate-as-pure': 7.27.3 + '@babel/helper-member-expression-to-functions': 7.28.5 + '@babel/helper-optimise-call-expression': 7.27.1 + '@babel/helper-replace-supers': 7.27.1(@babel/core@7.28.5) + '@babel/helper-skip-transparent-expression-wrappers': 7.27.1 + '@babel/traverse': 7.28.5 + semver: 6.3.1 + transitivePeerDependencies: + - supports-color + + '@babel/helper-environment-visitor@7.22.20': {} + + '@babel/helper-function-name@7.23.0': + dependencies: + '@babel/template': 7.24.0 + '@babel/types': 7.28.5 + + '@babel/helper-globals@7.28.0': {} + + '@babel/helper-hoist-variables@7.22.5': + dependencies: + '@babel/types': 7.28.5 + + '@babel/helper-member-expression-to-functions@7.24.5': + dependencies: + '@babel/types': 7.28.5 + + '@babel/helper-member-expression-to-functions@7.28.5': + dependencies: + '@babel/traverse': 7.28.5 + '@babel/types': 7.28.5 + transitivePeerDependencies: + - supports-color + + '@babel/helper-module-imports@7.24.3': + dependencies: + '@babel/types': 7.28.5 + + '@babel/helper-module-imports@7.27.1': + dependencies: + '@babel/traverse': 7.28.5 + '@babel/types': 7.28.5 + transitivePeerDependencies: + - supports-color + + '@babel/helper-module-transforms@7.24.5(@babel/core@7.24.5)': + dependencies: + '@babel/core': 7.24.5 + '@babel/helper-environment-visitor': 7.22.20 + '@babel/helper-module-imports': 7.24.3 + '@babel/helper-simple-access': 7.24.5 + '@babel/helper-split-export-declaration': 7.24.5 + '@babel/helper-validator-identifier': 7.24.5 + + '@babel/helper-module-transforms@7.28.3(@babel/core@7.28.5)': + dependencies: + '@babel/core': 7.28.5 + '@babel/helper-module-imports': 7.27.1 + '@babel/helper-validator-identifier': 7.28.5 + '@babel/traverse': 7.28.5 + transitivePeerDependencies: + - supports-color + + '@babel/helper-optimise-call-expression@7.22.5': + dependencies: + '@babel/types': 7.28.5 + + '@babel/helper-optimise-call-expression@7.27.1': + dependencies: + '@babel/types': 7.28.5 + + '@babel/helper-plugin-utils@7.24.5': {} + + '@babel/helper-plugin-utils@7.27.1': {} + + '@babel/helper-replace-supers@7.24.1(@babel/core@7.24.5)': + dependencies: + '@babel/core': 7.24.5 + '@babel/helper-environment-visitor': 7.22.20 + '@babel/helper-member-expression-to-functions': 7.28.5 + '@babel/helper-optimise-call-expression': 7.27.1 + transitivePeerDependencies: + - supports-color + + '@babel/helper-replace-supers@7.27.1(@babel/core@7.28.5)': + dependencies: + '@babel/core': 7.28.5 + '@babel/helper-member-expression-to-functions': 7.28.5 + '@babel/helper-optimise-call-expression': 7.27.1 + '@babel/traverse': 7.28.5 + transitivePeerDependencies: + - supports-color + + '@babel/helper-simple-access@7.24.5': + dependencies: + '@babel/types': 7.28.5 + + '@babel/helper-skip-transparent-expression-wrappers@7.27.1': + dependencies: + '@babel/traverse': 7.28.5 + '@babel/types': 7.28.5 + transitivePeerDependencies: + - supports-color + + '@babel/helper-split-export-declaration@7.24.5': + dependencies: + '@babel/types': 7.28.5 + + '@babel/helper-string-parser@7.24.1': {} + + '@babel/helper-string-parser@7.25.9': {} + + '@babel/helper-string-parser@7.27.1': {} + + '@babel/helper-validator-identifier@7.24.5': {} + + '@babel/helper-validator-identifier@7.25.9': {} + + '@babel/helper-validator-identifier@7.27.1': {} + + '@babel/helper-validator-identifier@7.28.5': {} + + '@babel/helper-validator-option@7.23.5': {} + + '@babel/helper-validator-option@7.27.1': {} + + '@babel/helpers@7.24.5': + dependencies: + '@babel/template': 7.24.0 + '@babel/traverse': 7.24.5 + '@babel/types': 7.27.1 + transitivePeerDependencies: + - supports-color + + '@babel/helpers@7.28.4': + dependencies: + '@babel/template': 7.27.2 + '@babel/types': 7.28.5 + + '@babel/highlight@7.24.5': + dependencies: + '@babel/helper-validator-identifier': 7.25.9 + chalk: 2.4.2 + js-tokens: 4.0.0 + picocolors: 1.1.1 + + '@babel/parser@7.24.5': + dependencies: + '@babel/types': 7.27.1 + + '@babel/parser@7.26.2': + dependencies: + '@babel/types': 7.26.0 + + '@babel/parser@7.28.5': + dependencies: + '@babel/types': 7.28.5 + + '@babel/plugin-syntax-jsx@7.24.1(@babel/core@7.24.5)': + dependencies: + '@babel/core': 7.24.5 + '@babel/helper-plugin-utils': 7.24.5 + + '@babel/plugin-syntax-jsx@7.27.1(@babel/core@7.28.5)': + dependencies: + '@babel/core': 7.28.5 + '@babel/helper-plugin-utils': 7.27.1 + + '@babel/plugin-syntax-typescript@7.27.1(@babel/core@7.24.5)': + dependencies: + '@babel/core': 7.24.5 + '@babel/helper-plugin-utils': 7.27.1 + + '@babel/plugin-syntax-typescript@7.27.1(@babel/core@7.28.5)': + dependencies: + '@babel/core': 7.28.5 + '@babel/helper-plugin-utils': 7.27.1 + + '@babel/plugin-transform-modules-commonjs@7.24.1(@babel/core@7.24.5)': + dependencies: + '@babel/core': 7.24.5 + '@babel/helper-module-transforms': 7.24.5(@babel/core@7.24.5) + '@babel/helper-plugin-utils': 7.24.5 + '@babel/helper-simple-access': 7.24.5 + + '@babel/plugin-transform-react-jsx-self@7.24.5(@babel/core@7.24.5)': + dependencies: + '@babel/core': 7.24.5 + '@babel/helper-plugin-utils': 7.24.5 + + '@babel/plugin-transform-react-jsx-source@7.24.1(@babel/core@7.24.5)': + dependencies: + '@babel/core': 7.24.5 + '@babel/helper-plugin-utils': 7.24.5 + + '@babel/plugin-transform-typescript@7.24.5(@babel/core@7.24.5)': + dependencies: + '@babel/core': 7.24.5 + '@babel/helper-annotate-as-pure': 7.22.5 + '@babel/helper-create-class-features-plugin': 7.24.5(@babel/core@7.24.5) + '@babel/helper-plugin-utils': 7.24.5 + '@babel/plugin-syntax-typescript': 7.27.1(@babel/core@7.24.5) + transitivePeerDependencies: + - supports-color + + '@babel/plugin-transform-typescript@7.28.5(@babel/core@7.28.5)': + dependencies: + '@babel/core': 7.28.5 + '@babel/helper-annotate-as-pure': 7.27.3 + '@babel/helper-create-class-features-plugin': 7.28.5(@babel/core@7.28.5) + '@babel/helper-plugin-utils': 7.27.1 + '@babel/helper-skip-transparent-expression-wrappers': 7.27.1 + '@babel/plugin-syntax-typescript': 7.27.1(@babel/core@7.28.5) + transitivePeerDependencies: + - supports-color + + '@babel/preset-typescript@7.24.1(@babel/core@7.24.5)': + dependencies: + '@babel/core': 7.24.5 + '@babel/helper-plugin-utils': 7.24.5 + '@babel/helper-validator-option': 7.23.5 + '@babel/plugin-syntax-jsx': 7.24.1(@babel/core@7.24.5) + '@babel/plugin-transform-modules-commonjs': 7.24.1(@babel/core@7.24.5) + '@babel/plugin-transform-typescript': 7.24.5(@babel/core@7.24.5) + transitivePeerDependencies: + - supports-color + + '@babel/runtime@7.26.0': + dependencies: + regenerator-runtime: 0.14.0 + + '@babel/runtime@7.28.4': {} + + '@babel/standalone@7.24.5': {} + + '@babel/template@7.24.0': + dependencies: + '@babel/code-frame': 7.24.2 + '@babel/parser': 7.26.2 + '@babel/types': 7.27.1 + + '@babel/template@7.27.2': + dependencies: + '@babel/code-frame': 7.27.1 + '@babel/parser': 7.28.5 + '@babel/types': 7.28.5 + + '@babel/traverse@7.24.5': + dependencies: + '@babel/code-frame': 7.24.2 + '@babel/generator': 7.24.5 + '@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.24.5 + '@babel/parser': 7.26.2 + '@babel/types': 7.27.1 + debug: 4.4.3 + globals: 11.12.0 + transitivePeerDependencies: + - supports-color + + '@babel/traverse@7.28.5': + dependencies: + '@babel/code-frame': 7.27.1 + '@babel/generator': 7.28.5 + '@babel/helper-globals': 7.28.0 + '@babel/parser': 7.28.5 + '@babel/template': 7.27.2 + '@babel/types': 7.28.5 + debug: 4.4.3 + transitivePeerDependencies: + - supports-color + + '@babel/types@7.24.5': + dependencies: + '@babel/helper-string-parser': 7.24.1 + '@babel/helper-validator-identifier': 7.24.5 + to-fast-properties: 2.0.0 + + '@babel/types@7.26.0': + dependencies: + '@babel/helper-string-parser': 7.25.9 + '@babel/helper-validator-identifier': 7.25.9 + + '@babel/types@7.27.1': + dependencies: + '@babel/helper-string-parser': 7.27.1 + '@babel/helper-validator-identifier': 7.27.1 + + '@babel/types@7.28.5': + dependencies: + '@babel/helper-string-parser': 7.27.1 + '@babel/helper-validator-identifier': 7.28.5 + + '@bcoe/v8-coverage@1.0.2': {} + + '@biomejs/biome@1.9.4': + optionalDependencies: + '@biomejs/cli-darwin-arm64': 1.9.4 + '@biomejs/cli-darwin-x64': 1.9.4 + '@biomejs/cli-linux-arm64': 1.9.4 + '@biomejs/cli-linux-arm64-musl': 1.9.4 + '@biomejs/cli-linux-x64': 1.9.4 + '@biomejs/cli-linux-x64-musl': 1.9.4 + '@biomejs/cli-win32-arm64': 1.9.4 + '@biomejs/cli-win32-x64': 1.9.4 + + '@biomejs/cli-darwin-arm64@1.9.4': + optional: true + + '@biomejs/cli-darwin-x64@1.9.4': + optional: true + + '@biomejs/cli-linux-arm64-musl@1.9.4': + optional: true + + '@biomejs/cli-linux-arm64@1.9.4': + optional: true + + '@biomejs/cli-linux-x64-musl@1.9.4': + optional: true + + '@biomejs/cli-linux-x64@1.9.4': + optional: true + + '@biomejs/cli-win32-arm64@1.9.4': + optional: true + + '@biomejs/cli-win32-x64@1.9.4': + optional: true + + '@bomb.sh/tab@0.0.10(cac@6.7.14)(citty@0.1.6)': + optionalDependencies: + cac: 6.7.14 + citty: 0.1.6 + + '@bundled-es-modules/cookie@2.0.0': + dependencies: + cookie: 0.5.0 + + '@bundled-es-modules/statuses@1.0.1': + dependencies: + statuses: 2.0.1 + + '@bundled-es-modules/tough-cookie@0.1.6': + dependencies: + '@types/tough-cookie': 4.0.5 + tough-cookie: 4.1.4 + + '@bytecodealliance/preview2-shim@0.17.6': {} + + '@changesets/apply-release-plan@7.0.14': + dependencies: + '@changesets/config': 3.1.2 + '@changesets/get-version-range-type': 0.4.0 + '@changesets/git': 3.0.4 + '@changesets/should-skip-package': 0.1.2 + '@changesets/types': 6.1.0 + '@manypkg/get-packages': 1.1.3 + detect-indent: 6.1.0 + fs-extra: 7.0.1 + lodash.startcase: 4.4.0 + outdent: 0.5.0 + prettier: 2.8.8 + resolve-from: 5.0.0 + semver: 7.7.3 + + '@changesets/apply-release-plan@7.0.5': + dependencies: + '@changesets/config': 3.0.3 + '@changesets/get-version-range-type': 0.4.0 + '@changesets/git': 3.0.1 + '@changesets/should-skip-package': 0.1.1 + '@changesets/types': 6.0.0 + '@manypkg/get-packages': 1.1.3 + detect-indent: 6.1.0 + fs-extra: 7.0.1 + lodash.startcase: 4.4.0 + outdent: 0.5.0 + prettier: 2.8.8 + resolve-from: 5.0.0 + semver: 7.7.3 + + '@changesets/assemble-release-plan@6.0.4': + dependencies: + '@changesets/errors': 0.2.0 + '@changesets/get-dependents-graph': 2.1.2 + '@changesets/should-skip-package': 0.1.1 + '@changesets/types': 6.0.0 + '@manypkg/get-packages': 1.1.3 + semver: 7.7.3 + + '@changesets/assemble-release-plan@6.0.9': + dependencies: + '@changesets/errors': 0.2.0 + '@changesets/get-dependents-graph': 2.1.3 + '@changesets/should-skip-package': 0.1.2 + '@changesets/types': 6.1.0 + '@manypkg/get-packages': 1.1.3 + semver: 7.7.3 + + '@changesets/changelog-git@0.2.0': + dependencies: + '@changesets/types': 6.0.0 + + '@changesets/changelog-git@0.2.1': + dependencies: + '@changesets/types': 6.1.0 + + '@changesets/changelog-github@0.4.6(encoding@0.1.13)': + dependencies: + '@changesets/get-github-info': 0.5.2(encoding@0.1.13) + '@changesets/types': 5.2.1 + dotenv: 8.6.0 + transitivePeerDependencies: + - encoding + + '@changesets/cli@2.27.8': + dependencies: + '@changesets/apply-release-plan': 7.0.5 + '@changesets/assemble-release-plan': 6.0.4 + '@changesets/changelog-git': 0.2.0 + '@changesets/config': 3.0.3 + '@changesets/errors': 0.2.0 + '@changesets/get-dependents-graph': 2.1.2 + '@changesets/get-release-plan': 4.0.4 + '@changesets/git': 3.0.1 + '@changesets/logger': 0.1.1 + '@changesets/pre': 2.0.1 + '@changesets/read': 0.6.1 + '@changesets/should-skip-package': 0.1.1 + '@changesets/types': 6.0.0 + '@changesets/write': 0.3.2 + '@manypkg/get-packages': 1.1.3 + '@types/semver': 7.5.3 + ansi-colors: 4.1.3 + ci-info: 3.9.0 + enquirer: 2.3.6 + external-editor: 3.1.0 + fs-extra: 7.0.1 + mri: 1.2.0 + outdent: 0.5.0 + p-limit: 2.3.0 + package-manager-detector: 0.2.0 + picocolors: 1.1.0 + resolve-from: 5.0.0 + semver: 7.6.2 + spawndamnit: 2.0.0 + term-size: 2.2.1 + + '@changesets/cli@2.29.8(@types/node@24.0.1)': + dependencies: + '@changesets/apply-release-plan': 7.0.14 + '@changesets/assemble-release-plan': 6.0.9 + '@changesets/changelog-git': 0.2.1 + '@changesets/config': 3.1.2 + '@changesets/errors': 0.2.0 + '@changesets/get-dependents-graph': 2.1.3 + '@changesets/get-release-plan': 4.0.14 + '@changesets/git': 3.0.4 + '@changesets/logger': 0.1.1 + '@changesets/pre': 2.0.2 + '@changesets/read': 0.6.6 + '@changesets/should-skip-package': 0.1.2 + '@changesets/types': 6.1.0 + '@changesets/write': 0.4.0 + '@inquirer/external-editor': 1.0.3(@types/node@24.0.1) + '@manypkg/get-packages': 1.1.3 + ansi-colors: 4.1.3 + ci-info: 3.9.0 + enquirer: 2.4.1 + fs-extra: 7.0.1 + mri: 1.2.0 + p-limit: 2.3.0 + package-manager-detector: 0.2.11 + picocolors: 1.1.1 + resolve-from: 5.0.0 + semver: 7.7.3 + spawndamnit: 3.0.1 + term-size: 2.2.1 + transitivePeerDependencies: + - '@types/node' + + '@changesets/config@3.0.3': + dependencies: + '@changesets/errors': 0.2.0 + '@changesets/get-dependents-graph': 2.1.2 + '@changesets/logger': 0.1.1 + '@changesets/types': 6.0.0 + '@manypkg/get-packages': 1.1.3 + fs-extra: 7.0.1 + micromatch: 4.0.5 + + '@changesets/config@3.1.2': + dependencies: + '@changesets/errors': 0.2.0 + '@changesets/get-dependents-graph': 2.1.3 + '@changesets/logger': 0.1.1 + '@changesets/types': 6.1.0 + '@manypkg/get-packages': 1.1.3 + fs-extra: 7.0.1 + micromatch: 4.0.8 + + '@changesets/errors@0.2.0': + dependencies: + extendable-error: 0.1.7 + + '@changesets/get-dependents-graph@2.1.2': + dependencies: + '@changesets/types': 6.0.0 + '@manypkg/get-packages': 1.1.3 + picocolors: 1.1.0 + semver: 7.7.3 + + '@changesets/get-dependents-graph@2.1.3': + dependencies: + '@changesets/types': 6.1.0 + '@manypkg/get-packages': 1.1.3 + picocolors: 1.1.1 + semver: 7.7.3 + + '@changesets/get-github-info@0.5.2(encoding@0.1.13)': + dependencies: + dataloader: 1.4.0 + node-fetch: 2.6.9(encoding@0.1.13) + transitivePeerDependencies: + - encoding + + '@changesets/get-release-plan@4.0.14': + dependencies: + '@changesets/assemble-release-plan': 6.0.9 + '@changesets/config': 3.1.2 + '@changesets/pre': 2.0.2 + '@changesets/read': 0.6.6 + '@changesets/types': 6.1.0 + '@manypkg/get-packages': 1.1.3 + + '@changesets/get-release-plan@4.0.4': + dependencies: + '@changesets/assemble-release-plan': 6.0.4 + '@changesets/config': 3.0.3 + '@changesets/pre': 2.0.1 + '@changesets/read': 0.6.1 + '@changesets/types': 6.0.0 + '@manypkg/get-packages': 1.1.3 + + '@changesets/get-version-range-type@0.4.0': {} + + '@changesets/git@3.0.1': + dependencies: + '@changesets/errors': 0.2.0 + '@manypkg/get-packages': 1.1.3 + is-subdir: 1.2.0 + micromatch: 4.0.5 + spawndamnit: 2.0.0 + + '@changesets/git@3.0.4': + dependencies: + '@changesets/errors': 0.2.0 + '@manypkg/get-packages': 1.1.3 + is-subdir: 1.2.0 + micromatch: 4.0.8 + spawndamnit: 3.0.1 + + '@changesets/logger@0.1.1': + dependencies: + picocolors: 1.1.0 + + '@changesets/parse@0.4.0': + dependencies: + '@changesets/types': 6.0.0 + js-yaml: 3.14.1 + + '@changesets/parse@0.4.2': + dependencies: + '@changesets/types': 6.1.0 + js-yaml: 4.1.1 + + '@changesets/pre@2.0.1': + dependencies: + '@changesets/errors': 0.2.0 + '@changesets/types': 6.0.0 + '@manypkg/get-packages': 1.1.3 + fs-extra: 7.0.1 + + '@changesets/pre@2.0.2': + dependencies: + '@changesets/errors': 0.2.0 + '@changesets/types': 6.1.0 + '@manypkg/get-packages': 1.1.3 + fs-extra: 7.0.1 + + '@changesets/read@0.6.1': + dependencies: + '@changesets/git': 3.0.1 + '@changesets/logger': 0.1.1 + '@changesets/parse': 0.4.0 + '@changesets/types': 6.0.0 + fs-extra: 7.0.1 + p-filter: 2.1.0 + picocolors: 1.1.0 + + '@changesets/read@0.6.6': + dependencies: + '@changesets/git': 3.0.4 + '@changesets/logger': 0.1.1 + '@changesets/parse': 0.4.2 + '@changesets/types': 6.1.0 + fs-extra: 7.0.1 + p-filter: 2.1.0 + picocolors: 1.1.1 + + '@changesets/should-skip-package@0.1.1': + dependencies: + '@changesets/types': 6.0.0 + '@manypkg/get-packages': 1.1.3 + + '@changesets/should-skip-package@0.1.2': + dependencies: + '@changesets/types': 6.1.0 + '@manypkg/get-packages': 1.1.3 + + '@changesets/types@4.1.0': {} + + '@changesets/types@5.2.1': {} + + '@changesets/types@6.0.0': {} + + '@changesets/types@6.1.0': {} + + '@changesets/write@0.3.2': + dependencies: + '@changesets/types': 6.0.0 + fs-extra: 7.0.1 + human-id: 1.0.2 + prettier: 2.8.8 + + '@changesets/write@0.4.0': + dependencies: + '@changesets/types': 6.1.0 + fs-extra: 7.0.1 + human-id: 4.1.3 + prettier: 2.8.8 + + '@clack/core@1.0.0-alpha.7': + dependencies: + picocolors: 1.1.1 + sisteransi: 1.0.5 + + '@clack/prompts@1.0.0-alpha.8': + dependencies: + '@clack/core': 1.0.0-alpha.7 + picocolors: 1.1.1 + sisteransi: 1.0.5 + + '@cloudflare/kv-asset-handler@0.4.1': + dependencies: + mime: 3.0.0 + + '@coinbase/wallet-sdk@3.9.3': + dependencies: + bn.js: 5.2.1 + buffer: 6.0.3 + clsx: 1.2.1 + eth-block-tracker: 7.1.0 + eth-json-rpc-filters: 6.0.1 + eventemitter3: 5.0.1 + keccak: 3.0.3 + preact: 10.17.1 + sha.js: 2.4.11 + transitivePeerDependencies: + - supports-color + + '@coinbase/wallet-sdk@4.3.0': + dependencies: + '@noble/hashes': 1.5.0 + clsx: 1.2.1 + eventemitter3: 5.0.1 + preact: 10.24.3 + + '@colors/colors@1.5.0': + optional: true + + '@cspotcode/source-map-support@0.8.1': + dependencies: + '@jridgewell/trace-mapping': 0.3.9 + + '@databeat/tracker@0.9.3': + dependencies: + '@noble/hashes': 1.8.0 + + '@discoveryjs/json-ext@0.5.7': {} + + '@docsearch/css@3.6.3': {} + + '@docsearch/js@3.6.3(@algolia/client-search@5.12.0)(@types/react@18.3.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@docsearch/react': 3.6.3(@algolia/client-search@5.12.0)(@types/react@18.3.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + preact: 10.24.3 + transitivePeerDependencies: + - '@algolia/client-search' + - '@types/react' + - react + - react-dom + - search-insights + + '@docsearch/react@3.6.3(@algolia/client-search@5.12.0)(@types/react@18.3.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@algolia/autocomplete-core': 1.9.3(@algolia/client-search@5.12.0)(algoliasearch@5.12.0) + '@algolia/autocomplete-preset-algolia': 1.17.6(@algolia/client-search@5.12.0)(algoliasearch@5.12.0) + '@docsearch/css': 3.6.3 + algoliasearch: 5.12.0 + optionalDependencies: + '@types/react': 18.3.1 + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + transitivePeerDependencies: + - '@algolia/client-search' + + '@ecies/ciphers@0.2.5(@noble/ciphers@1.3.0)': + dependencies: + '@noble/ciphers': 1.3.0 + + '@edge-runtime/format@2.2.1': {} + + '@edge-runtime/node-utils@2.3.0': {} + + '@edge-runtime/ponyfill@2.4.2': {} + + '@edge-runtime/primitives@4.1.0': {} + + '@edge-runtime/vm@3.2.0': + dependencies: + '@edge-runtime/primitives': 4.1.0 + + '@emnapi/core@1.7.1': + dependencies: + '@emnapi/wasi-threads': 1.1.0 + tslib: 2.8.1 + optional: true + + '@emnapi/runtime@1.7.1': + dependencies: + tslib: 2.8.1 + optional: true + + '@emnapi/wasi-threads@1.1.0': + dependencies: + tslib: 2.8.1 + optional: true + + '@esbuild/aix-ppc64@0.21.5': + optional: true + + '@esbuild/aix-ppc64@0.23.1': + optional: true + + '@esbuild/aix-ppc64@0.25.12': + optional: true + + '@esbuild/aix-ppc64@0.27.2': + optional: true + + '@esbuild/android-arm64@0.21.5': + optional: true + + '@esbuild/android-arm64@0.23.1': + optional: true + + '@esbuild/android-arm64@0.25.12': + optional: true + + '@esbuild/android-arm64@0.27.2': + optional: true + + '@esbuild/android-arm@0.21.5': + optional: true + + '@esbuild/android-arm@0.23.1': + optional: true + + '@esbuild/android-arm@0.25.12': + optional: true + + '@esbuild/android-arm@0.27.2': + optional: true + + '@esbuild/android-x64@0.21.5': + optional: true + + '@esbuild/android-x64@0.23.1': + optional: true + + '@esbuild/android-x64@0.25.12': + optional: true + + '@esbuild/android-x64@0.27.2': + optional: true + + '@esbuild/darwin-arm64@0.21.5': + optional: true + + '@esbuild/darwin-arm64@0.23.1': + optional: true + + '@esbuild/darwin-arm64@0.25.12': + optional: true + + '@esbuild/darwin-arm64@0.27.2': + optional: true + + '@esbuild/darwin-x64@0.21.5': + optional: true + + '@esbuild/darwin-x64@0.23.1': + optional: true + + '@esbuild/darwin-x64@0.25.12': + optional: true + + '@esbuild/darwin-x64@0.27.2': + optional: true + + '@esbuild/freebsd-arm64@0.21.5': + optional: true + + '@esbuild/freebsd-arm64@0.23.1': + optional: true + + '@esbuild/freebsd-arm64@0.25.12': + optional: true + + '@esbuild/freebsd-arm64@0.27.2': + optional: true + + '@esbuild/freebsd-x64@0.21.5': + optional: true + + '@esbuild/freebsd-x64@0.23.1': + optional: true + + '@esbuild/freebsd-x64@0.25.12': + optional: true + + '@esbuild/freebsd-x64@0.27.2': + optional: true + + '@esbuild/linux-arm64@0.21.5': + optional: true + + '@esbuild/linux-arm64@0.23.1': + optional: true + + '@esbuild/linux-arm64@0.25.12': + optional: true + + '@esbuild/linux-arm64@0.27.2': + optional: true + + '@esbuild/linux-arm@0.21.5': + optional: true + + '@esbuild/linux-arm@0.23.1': + optional: true + + '@esbuild/linux-arm@0.25.12': + optional: true + + '@esbuild/linux-arm@0.27.2': + optional: true + + '@esbuild/linux-ia32@0.21.5': + optional: true + + '@esbuild/linux-ia32@0.23.1': + optional: true + + '@esbuild/linux-ia32@0.25.12': + optional: true + + '@esbuild/linux-ia32@0.27.2': + optional: true + + '@esbuild/linux-loong64@0.21.5': + optional: true + + '@esbuild/linux-loong64@0.23.1': + optional: true + + '@esbuild/linux-loong64@0.25.12': + optional: true + + '@esbuild/linux-loong64@0.27.2': + optional: true + + '@esbuild/linux-mips64el@0.21.5': + optional: true + + '@esbuild/linux-mips64el@0.23.1': + optional: true + + '@esbuild/linux-mips64el@0.25.12': + optional: true + + '@esbuild/linux-mips64el@0.27.2': + optional: true + + '@esbuild/linux-ppc64@0.21.5': + optional: true + + '@esbuild/linux-ppc64@0.23.1': + optional: true + + '@esbuild/linux-ppc64@0.25.12': + optional: true + + '@esbuild/linux-ppc64@0.27.2': + optional: true + + '@esbuild/linux-riscv64@0.21.5': + optional: true + + '@esbuild/linux-riscv64@0.23.1': + optional: true + + '@esbuild/linux-riscv64@0.25.12': + optional: true + + '@esbuild/linux-riscv64@0.27.2': + optional: true + + '@esbuild/linux-s390x@0.21.5': + optional: true + + '@esbuild/linux-s390x@0.23.1': + optional: true + + '@esbuild/linux-s390x@0.25.12': + optional: true + + '@esbuild/linux-s390x@0.27.2': + optional: true + + '@esbuild/linux-x64@0.21.5': + optional: true + + '@esbuild/linux-x64@0.23.1': + optional: true + + '@esbuild/linux-x64@0.25.12': + optional: true + + '@esbuild/linux-x64@0.27.2': + optional: true + + '@esbuild/netbsd-arm64@0.25.12': + optional: true + + '@esbuild/netbsd-arm64@0.27.2': + optional: true + + '@esbuild/netbsd-x64@0.21.5': + optional: true + + '@esbuild/netbsd-x64@0.23.1': + optional: true + + '@esbuild/netbsd-x64@0.25.12': + optional: true + + '@esbuild/netbsd-x64@0.27.2': + optional: true + + '@esbuild/openbsd-arm64@0.23.1': + optional: true + + '@esbuild/openbsd-arm64@0.25.12': + optional: true + + '@esbuild/openbsd-arm64@0.27.2': + optional: true + + '@esbuild/openbsd-x64@0.21.5': + optional: true + + '@esbuild/openbsd-x64@0.23.1': + optional: true + + '@esbuild/openbsd-x64@0.25.12': + optional: true + + '@esbuild/openbsd-x64@0.27.2': + optional: true + + '@esbuild/openharmony-arm64@0.25.12': + optional: true + + '@esbuild/openharmony-arm64@0.27.2': + optional: true + + '@esbuild/sunos-x64@0.21.5': + optional: true + + '@esbuild/sunos-x64@0.23.1': + optional: true + + '@esbuild/sunos-x64@0.25.12': + optional: true + + '@esbuild/sunos-x64@0.27.2': + optional: true + + '@esbuild/win32-arm64@0.21.5': + optional: true + + '@esbuild/win32-arm64@0.23.1': + optional: true + + '@esbuild/win32-arm64@0.25.12': + optional: true + + '@esbuild/win32-arm64@0.27.2': + optional: true + + '@esbuild/win32-ia32@0.21.5': + optional: true + + '@esbuild/win32-ia32@0.23.1': + optional: true + + '@esbuild/win32-ia32@0.25.12': + optional: true + + '@esbuild/win32-ia32@0.27.2': + optional: true + + '@esbuild/win32-x64@0.21.5': + optional: true + + '@esbuild/win32-x64@0.23.1': + optional: true + + '@esbuild/win32-x64@0.25.12': + optional: true + + '@esbuild/win32-x64@0.27.2': + optional: true + + '@ethereumjs/common@3.2.0': + dependencies: + '@ethereumjs/util': 8.1.0 + crc-32: 1.2.2 + + '@ethereumjs/rlp@4.0.1': {} + + '@ethereumjs/tx@4.2.0': + dependencies: + '@ethereumjs/common': 3.2.0 + '@ethereumjs/rlp': 4.0.1 + '@ethereumjs/util': 8.1.0 + ethereum-cryptography: 2.2.1 + + '@ethereumjs/util@8.1.0': + dependencies: + '@ethereumjs/rlp': 4.0.1 + ethereum-cryptography: 2.2.1 + micro-ftch: 0.3.1 + + '@ethersproject/abi@5.7.0': + dependencies: + '@ethersproject/address': 5.7.0 + '@ethersproject/bignumber': 5.7.0 + '@ethersproject/bytes': 5.7.0 + '@ethersproject/constants': 5.7.0 + '@ethersproject/hash': 5.7.0 + '@ethersproject/keccak256': 5.7.0 + '@ethersproject/logger': 5.7.0 + '@ethersproject/properties': 5.7.0 + '@ethersproject/strings': 5.7.0 + + '@ethersproject/abstract-provider@5.7.0': + dependencies: + '@ethersproject/bignumber': 5.7.0 + '@ethersproject/bytes': 5.7.0 + '@ethersproject/logger': 5.7.0 + '@ethersproject/networks': 5.7.1 + '@ethersproject/properties': 5.7.0 + '@ethersproject/transactions': 5.7.0 + '@ethersproject/web': 5.7.1 + + '@ethersproject/abstract-signer@5.7.0': + dependencies: + '@ethersproject/abstract-provider': 5.7.0 + '@ethersproject/bignumber': 5.7.0 + '@ethersproject/bytes': 5.7.0 + '@ethersproject/logger': 5.7.0 + '@ethersproject/properties': 5.7.0 + + '@ethersproject/address@5.7.0': + dependencies: + '@ethersproject/bignumber': 5.7.0 + '@ethersproject/bytes': 5.7.0 + '@ethersproject/keccak256': 5.7.0 + '@ethersproject/logger': 5.7.0 + '@ethersproject/rlp': 5.7.0 + + '@ethersproject/base64@5.7.0': + dependencies: + '@ethersproject/bytes': 5.7.0 + + '@ethersproject/bignumber@5.7.0': + dependencies: + '@ethersproject/bytes': 5.7.0 + '@ethersproject/logger': 5.7.0 + bn.js: 5.2.1 + + '@ethersproject/bytes@5.7.0': + dependencies: + '@ethersproject/logger': 5.7.0 + + '@ethersproject/constants@5.7.0': + dependencies: + '@ethersproject/bignumber': 5.7.0 + + '@ethersproject/hash@5.7.0': + dependencies: + '@ethersproject/abstract-signer': 5.7.0 + '@ethersproject/address': 5.7.0 + '@ethersproject/base64': 5.7.0 + '@ethersproject/bignumber': 5.7.0 + '@ethersproject/bytes': 5.7.0 + '@ethersproject/keccak256': 5.7.0 + '@ethersproject/logger': 5.7.0 + '@ethersproject/properties': 5.7.0 + '@ethersproject/strings': 5.7.0 + + '@ethersproject/keccak256@5.7.0': + dependencies: + '@ethersproject/bytes': 5.7.0 + js-sha3: 0.8.0 + + '@ethersproject/logger@5.7.0': {} - '@0xsequence/api@1.10.15': {} - - '@0xsequence/auth@1.10.15(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10)': - dependencies: - '@0xsequence/abi': 1.10.15 - '@0xsequence/account': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/api': 1.10.15 - '@0xsequence/core': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/ethauth': 0.8.1(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/indexer': 1.10.15 - '@0xsequence/metadata': 1.10.15 - '@0xsequence/migration': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/network': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/sessions': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/signhub': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/utils': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/wallet': 1.10.15(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@ethersproject/networks@5.7.1': + dependencies: + '@ethersproject/logger': 5.7.0 + + '@ethersproject/properties@5.7.0': + dependencies: + '@ethersproject/logger': 5.7.0 + + '@ethersproject/rlp@5.7.0': + dependencies: + '@ethersproject/bytes': 5.7.0 + '@ethersproject/logger': 5.7.0 + + '@ethersproject/signing-key@5.7.0': + dependencies: + '@ethersproject/bytes': 5.7.0 + '@ethersproject/logger': 5.7.0 + '@ethersproject/properties': 5.7.0 + bn.js: 5.2.2 + elliptic: 6.5.4 + hash.js: 1.1.7 + + '@ethersproject/strings@5.7.0': + dependencies: + '@ethersproject/bytes': 5.7.0 + '@ethersproject/constants': 5.7.0 + '@ethersproject/logger': 5.7.0 + + '@ethersproject/transactions@5.7.0': + dependencies: + '@ethersproject/address': 5.7.0 + '@ethersproject/bignumber': 5.7.0 + '@ethersproject/bytes': 5.7.0 + '@ethersproject/constants': 5.7.0 + '@ethersproject/keccak256': 5.7.0 + '@ethersproject/logger': 5.7.0 + '@ethersproject/properties': 5.7.0 + '@ethersproject/rlp': 5.7.0 + '@ethersproject/signing-key': 5.7.0 + + '@ethersproject/web@5.7.1': + dependencies: + '@ethersproject/base64': 5.7.0 + '@ethersproject/bytes': 5.7.0 + '@ethersproject/logger': 5.7.0 + '@ethersproject/properties': 5.7.0 + '@ethersproject/strings': 5.7.0 + + '@fastify/busboy@2.1.0': {} + + '@fastify/busboy@2.1.1': {} + + '@floating-ui/core@1.6.1': + dependencies: + '@floating-ui/utils': 0.2.2 + + '@floating-ui/core@1.7.3': + dependencies: + '@floating-ui/utils': 0.2.10 + + '@floating-ui/dom@1.1.1': + dependencies: + '@floating-ui/core': 1.6.1 + + '@floating-ui/dom@1.7.4': + dependencies: + '@floating-ui/core': 1.7.3 + '@floating-ui/utils': 0.2.10 + + '@floating-ui/react-dom@2.1.6(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@floating-ui/dom': 1.7.4 + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + + '@floating-ui/utils@0.2.10': {} + + '@floating-ui/utils@0.2.2': {} + + '@iarna/toml@2.2.5': {} + + '@iconify-json/simple-icons@1.2.10': + dependencies: + '@iconify/types': 2.0.0 + + '@iconify/types@2.0.0': {} + + '@iconify/utils@2.1.23': + dependencies: + '@antfu/install-pkg': 0.1.1 + '@antfu/utils': 0.7.7 + '@iconify/types': 2.0.0 + debug: 4.4.3 + kolorist: 1.8.0 + local-pkg: 0.5.1 + mlly: 1.8.0 transitivePeerDependencies: - - bufferutil - - utf-8-validate + - supports-color + + '@img/colour@1.0.0': + optional: true + + '@img/sharp-darwin-arm64@0.34.5': + optionalDependencies: + '@img/sharp-libvips-darwin-arm64': 1.2.4 + optional: true + + '@img/sharp-darwin-x64@0.34.5': + optionalDependencies: + '@img/sharp-libvips-darwin-x64': 1.2.4 + optional: true + + '@img/sharp-libvips-darwin-arm64@1.2.4': + optional: true + + '@img/sharp-libvips-darwin-x64@1.2.4': + optional: true + + '@img/sharp-libvips-linux-arm64@1.2.4': + optional: true + + '@img/sharp-libvips-linux-arm@1.2.4': + optional: true + + '@img/sharp-libvips-linux-ppc64@1.2.4': + optional: true + + '@img/sharp-libvips-linux-riscv64@1.2.4': + optional: true + + '@img/sharp-libvips-linux-s390x@1.2.4': + optional: true + + '@img/sharp-libvips-linux-x64@1.2.4': + optional: true + + '@img/sharp-libvips-linuxmusl-arm64@1.2.4': + optional: true + + '@img/sharp-libvips-linuxmusl-x64@1.2.4': + optional: true + + '@img/sharp-linux-arm64@0.34.5': + optionalDependencies: + '@img/sharp-libvips-linux-arm64': 1.2.4 + optional: true + + '@img/sharp-linux-arm@0.34.5': + optionalDependencies: + '@img/sharp-libvips-linux-arm': 1.2.4 + optional: true + + '@img/sharp-linux-ppc64@0.34.5': + optionalDependencies: + '@img/sharp-libvips-linux-ppc64': 1.2.4 + optional: true + + '@img/sharp-linux-riscv64@0.34.5': + optionalDependencies: + '@img/sharp-libvips-linux-riscv64': 1.2.4 + optional: true + + '@img/sharp-linux-s390x@0.34.5': + optionalDependencies: + '@img/sharp-libvips-linux-s390x': 1.2.4 + optional: true + + '@img/sharp-linux-x64@0.34.5': + optionalDependencies: + '@img/sharp-libvips-linux-x64': 1.2.4 + optional: true + + '@img/sharp-linuxmusl-arm64@0.34.5': + optionalDependencies: + '@img/sharp-libvips-linuxmusl-arm64': 1.2.4 + optional: true + + '@img/sharp-linuxmusl-x64@0.34.5': + optionalDependencies: + '@img/sharp-libvips-linuxmusl-x64': 1.2.4 + optional: true + + '@img/sharp-wasm32@0.34.5': + dependencies: + '@emnapi/runtime': 1.7.1 + optional: true + + '@img/sharp-win32-arm64@0.34.5': + optional: true + + '@img/sharp-win32-ia32@0.34.5': + optional: true + + '@img/sharp-win32-x64@0.34.5': + optional: true + + '@inquirer/confirm@3.1.6': + dependencies: + '@inquirer/core': 8.1.0 + '@inquirer/type': 1.3.1 + + '@inquirer/core@8.1.0': + dependencies: + '@inquirer/figures': 1.0.1 + '@inquirer/type': 1.3.1 + '@types/mute-stream': 0.0.4 + '@types/node': 20.19.27 + '@types/wrap-ansi': 3.0.0 + ansi-escapes: 4.3.2 + chalk: 4.1.2 + cli-spinners: 2.9.2 + cli-width: 4.1.0 + mute-stream: 1.0.0 + signal-exit: 4.1.0 + strip-ansi: 6.0.1 + wrap-ansi: 6.2.0 + + '@inquirer/external-editor@1.0.3(@types/node@24.0.1)': + dependencies: + chardet: 2.1.1 + iconv-lite: 0.7.1 + optionalDependencies: + '@types/node': 24.0.1 + + '@inquirer/figures@1.0.1': {} + + '@inquirer/type@1.3.1': {} + + '@ioredis/commands@1.4.0': {} + + '@isaacs/balanced-match@4.0.1': {} + + '@isaacs/brace-expansion@5.0.0': + dependencies: + '@isaacs/balanced-match': 4.0.1 + + '@isaacs/cliui@8.0.2': + dependencies: + string-width: 5.1.2 + string-width-cjs: string-width@4.2.3 + strip-ansi: 7.1.2 + strip-ansi-cjs: strip-ansi@6.0.1 + wrap-ansi: 8.1.0 + wrap-ansi-cjs: wrap-ansi@7.0.0 + + '@isaacs/fs-minipass@4.0.1': + dependencies: + minipass: 7.1.2 + + '@istanbuljs/schema@0.1.3': {} + + '@jridgewell/gen-mapping@0.3.13': + dependencies: + '@jridgewell/sourcemap-codec': 1.5.5 + '@jridgewell/trace-mapping': 0.3.31 + + '@jridgewell/gen-mapping@0.3.3': + dependencies: + '@jridgewell/set-array': 1.1.2 + '@jridgewell/sourcemap-codec': 1.5.5 + '@jridgewell/trace-mapping': 0.3.31 + + '@jridgewell/gen-mapping@0.3.5': + dependencies: + '@jridgewell/set-array': 1.2.1 + '@jridgewell/sourcemap-codec': 1.5.5 + '@jridgewell/trace-mapping': 0.3.31 + + '@jridgewell/remapping@2.3.5': + dependencies: + '@jridgewell/gen-mapping': 0.3.13 + '@jridgewell/trace-mapping': 0.3.31 + + '@jridgewell/resolve-uri@3.1.0': {} + + '@jridgewell/resolve-uri@3.1.2': {} + + '@jridgewell/set-array@1.1.2': {} + + '@jridgewell/set-array@1.2.1': {} + + '@jridgewell/source-map@0.3.11': + dependencies: + '@jridgewell/gen-mapping': 0.3.13 + '@jridgewell/trace-mapping': 0.3.31 - '@0xsequence/core@1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': - dependencies: - '@0xsequence/abi': 1.10.15 - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@jridgewell/sourcemap-codec@1.4.14': {} - '@0xsequence/core@1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': - dependencies: - '@0xsequence/abi': 1.10.15 - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@jridgewell/sourcemap-codec@1.4.15': {} - '@0xsequence/core@2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': - dependencies: - '@0xsequence/abi': 2.3.43 - '@0xsequence/utils': 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@jridgewell/sourcemap-codec@1.5.0': {} + + '@jridgewell/sourcemap-codec@1.5.5': {} - '@0xsequence/ethauth@0.8.1(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@jridgewell/trace-mapping@0.3.17': dependencies: - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - js-base64: 3.7.8 + '@jridgewell/resolve-uri': 3.1.0 + '@jridgewell/sourcemap-codec': 1.4.14 - '@0xsequence/ethauth@0.8.1(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3))': + '@jridgewell/trace-mapping@0.3.25': dependencies: - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - js-base64: 3.7.8 + '@jridgewell/resolve-uri': 3.1.0 + '@jridgewell/sourcemap-codec': 1.5.5 - '@0xsequence/ethauth@0.8.1(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@jridgewell/trace-mapping@0.3.31': dependencies: - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - js-base64: 3.7.8 + '@jridgewell/resolve-uri': 3.1.2 + '@jridgewell/sourcemap-codec': 1.5.5 - '@0xsequence/guard@1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10)': + '@jridgewell/trace-mapping@0.3.9': dependencies: - '@0xsequence/account': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/core': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/signhub': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/utils': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - transitivePeerDependencies: - - bufferutil - - utf-8-validate + '@jridgewell/resolve-uri': 3.1.2 + '@jridgewell/sourcemap-codec': 1.5.5 - '@0xsequence/guard@3.0.6(typescript@5.9.3)': + '@kwsites/file-exists@1.1.1': dependencies: - ox: 0.9.17(typescript@5.9.3)(zod@4.2.0) + debug: 4.4.3 transitivePeerDependencies: - - typescript - - zod - - '@0xsequence/indexer@1.10.15': {} + - supports-color - '@0xsequence/indexer@2.3.43': {} + '@kwsites/promise-deferred@1.1.1': {} - '@0xsequence/indexer@3.0.6': {} + '@lit-labs/ssr-dom-shim@1.3.0': {} - '@0xsequence/metadata@1.10.15': {} + '@lit/reactive-element@2.1.0': + dependencies: + '@lit-labs/ssr-dom-shim': 1.3.0 - '@0xsequence/migration@1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10)': + '@manypkg/find-root@1.1.0': dependencies: - '@0xsequence/abi': 1.10.15 - '@0xsequence/core': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/wallet': 1.10.15(bufferutil@4.1.0)(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - transitivePeerDependencies: - - bufferutil - - utf-8-validate + '@babel/runtime': 7.28.4 + '@types/node': 12.20.55 + find-up: 4.1.0 + fs-extra: 8.1.0 - '@0xsequence/multicall@1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@manypkg/get-packages@1.1.3': dependencies: - '@0xsequence/abi': 1.10.15 - '@0xsequence/network': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/utils': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@babel/runtime': 7.28.4 + '@changesets/types': 4.1.0 + '@manypkg/find-root': 1.1.0 + fs-extra: 8.1.0 + globby: 11.1.0 + read-yaml-file: 1.1.0 - '@0xsequence/network@1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@mapbox/node-pre-gyp@2.0.3(encoding@0.1.13)': dependencies: - '@0xsequence/core': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/indexer': 1.10.15 - '@0xsequence/relayer': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/utils': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + consola: 3.4.2 + detect-libc: 2.1.2 + https-proxy-agent: 7.0.6 + node-fetch: 2.7.0(encoding@0.1.13) + nopt: 8.1.0 + semver: 7.7.3 + tar: 7.5.2 + transitivePeerDependencies: + - encoding + - supports-color - '@0xsequence/network@1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@metamask/eth-json-rpc-provider@1.0.1': dependencies: - '@0xsequence/core': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/indexer': 1.10.15 - '@0xsequence/relayer': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/utils': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@metamask/json-rpc-engine': 7.3.3 + '@metamask/safe-event-emitter': 3.1.2 + '@metamask/utils': 5.0.2 + transitivePeerDependencies: + - supports-color - '@0xsequence/network@2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@metamask/eth-sig-util@4.0.1': dependencies: - '@0xsequence/core': 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/indexer': 2.3.43 - '@0xsequence/relayer': 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/utils': 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + ethereumjs-abi: 0.6.8 + ethereumjs-util: 6.2.1 + ethjs-util: 0.1.6 + tweetnacl: 1.0.3 + tweetnacl-util: 0.15.1 - '@0xsequence/provider@1.10.15(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10)': + '@metamask/json-rpc-engine@7.3.3': dependencies: - '@0xsequence/abi': 1.10.15 - '@0xsequence/account': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/auth': 1.10.15(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - '@0xsequence/core': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/migration': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/network': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/relayer': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/utils': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/wallet': 1.10.15(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - '@databeat/tracker': 0.9.3 - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - eventemitter2: 6.4.9 - webextension-polyfill: 0.10.0 + '@metamask/rpc-errors': 6.4.0 + '@metamask/safe-event-emitter': 3.1.2 + '@metamask/utils': 8.5.0 transitivePeerDependencies: - - bufferutil - - utf-8-validate + - supports-color - '@0xsequence/relayer@1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@metamask/json-rpc-engine@8.0.2': dependencies: - '@0xsequence/abi': 1.10.15 - '@0xsequence/core': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/utils': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@metamask/rpc-errors': 6.4.0 + '@metamask/safe-event-emitter': 3.1.2 + '@metamask/utils': 8.5.0 + transitivePeerDependencies: + - supports-color - '@0xsequence/relayer@1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@metamask/json-rpc-middleware-stream@7.0.2': dependencies: - '@0xsequence/abi': 1.10.15 - '@0xsequence/core': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/utils': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@metamask/json-rpc-engine': 8.0.2 + '@metamask/safe-event-emitter': 3.1.2 + '@metamask/utils': 8.5.0 + readable-stream: 3.6.2 + transitivePeerDependencies: + - supports-color - '@0xsequence/relayer@2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@metamask/object-multiplex@2.1.0': dependencies: - '@0xsequence/abi': 2.3.43 - '@0xsequence/core': 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/utils': 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + once: 1.4.0 + readable-stream: 3.6.2 - '@0xsequence/replacer@1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@metamask/onboarding@1.0.1': dependencies: - '@0xsequence/abi': 1.10.15 - '@0xsequence/core': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + bowser: 2.13.1 - '@0xsequence/sessions@1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10)': + '@metamask/providers@16.1.0': dependencies: - '@0xsequence/core': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/migration': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/replacer': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - idb: 7.1.1 + '@metamask/json-rpc-engine': 8.0.2 + '@metamask/json-rpc-middleware-stream': 7.0.2 + '@metamask/object-multiplex': 2.1.0 + '@metamask/rpc-errors': 6.4.0 + '@metamask/safe-event-emitter': 3.1.2 + '@metamask/utils': 8.5.0 + detect-browser: 5.3.0 + extension-port-stream: 3.0.0 + fast-deep-equal: 3.1.3 + is-stream: 2.0.1 + readable-stream: 3.6.2 + webextension-polyfill: 0.10.0 transitivePeerDependencies: - - bufferutil - - utf-8-validate + - supports-color - '@0xsequence/signhub@1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10)': + '@metamask/rpc-errors@6.4.0': dependencies: - '@0xsequence/core': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@metamask/utils': 9.3.0 + fast-safe-stringify: 2.1.1 transitivePeerDependencies: - - bufferutil - - utf-8-validate + - supports-color - '@0xsequence/signhub@2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': - dependencies: - '@0xsequence/core': 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@metamask/safe-event-emitter@2.0.0': {} - '@0xsequence/tee-verifier@0.1.2': - dependencies: - cbor2: 1.12.0 - pkijs: 3.3.3 + '@metamask/safe-event-emitter@3.0.0': {} - '@0xsequence/utils@1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@metamask/safe-event-emitter@3.1.2': {} + + '@metamask/sdk-analytics@0.0.5': dependencies: - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - js-base64: 3.7.8 + openapi-fetch: 0.13.8 - '@0xsequence/utils@1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@metamask/sdk-communication-layer@0.33.1(cross-fetch@4.1.0(encoding@0.1.13))(eciesjs@0.4.16)(eventemitter2@6.4.9)(readable-stream@3.6.2)(socket.io-client@4.8.3(bufferutil@4.1.0)(utf-8-validate@5.0.10))': dependencies: - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - js-base64: 3.7.8 + '@metamask/sdk-analytics': 0.0.5 + bufferutil: 4.1.0 + cross-fetch: 4.1.0(encoding@0.1.13) + date-fns: 2.30.0 + debug: 4.3.4(supports-color@8.1.1) + eciesjs: 0.4.16 + eventemitter2: 6.4.9 + readable-stream: 3.6.2 + socket.io-client: 4.8.3(bufferutil@4.1.0)(utf-8-validate@5.0.10) + utf-8-validate: 5.0.10 + uuid: 8.3.2 + transitivePeerDependencies: + - supports-color - '@0xsequence/utils@2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@metamask/sdk-install-modal-web@0.32.1': dependencies: - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - js-base64: 3.7.8 + '@paulmillr/qr': 0.2.1 - '@0xsequence/wallet-contracts@1.10.0': - optionalDependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/providers': 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - ethers: 5.8.0 + '@metamask/sdk@0.33.1(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@5.0.10)': + dependencies: + '@babel/runtime': 7.28.4 + '@metamask/onboarding': 1.0.1 + '@metamask/providers': 16.1.0 + '@metamask/sdk-analytics': 0.0.5 + '@metamask/sdk-communication-layer': 0.33.1(cross-fetch@4.1.0(encoding@0.1.13))(eciesjs@0.4.16)(eventemitter2@6.4.9)(readable-stream@3.6.2)(socket.io-client@4.8.3(bufferutil@4.1.0)(utf-8-validate@5.0.10)) + '@metamask/sdk-install-modal-web': 0.32.1 + '@paulmillr/qr': 0.2.1 + bowser: 2.13.1 + cross-fetch: 4.1.0(encoding@0.1.13) + debug: 4.3.4(supports-color@8.1.1) + eciesjs: 0.4.16 + eth-rpc-errors: 4.0.3 + eventemitter2: 6.4.9 + obj-multiplex: 1.0.0 + pump: 3.0.3 + readable-stream: 3.6.2 + socket.io-client: 4.8.3(bufferutil@4.1.0)(utf-8-validate@5.0.10) + tslib: 2.8.1 + util: 0.12.5 + uuid: 8.3.2 transitivePeerDependencies: - bufferutil + - encoding + - supports-color - utf-8-validate - '@0xsequence/wallet-contracts@1.10.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)': - optionalDependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/providers': 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - transitivePeerDependencies: - - bufferutil - - utf-8-validate + '@metamask/superstruct@3.2.1': {} - '@0xsequence/wallet-contracts@2.0.0(@ethersproject/abi@5.8.0)(@ethersproject/bytes@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3))(bufferutil@4.0.7)(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@6.0.3)': + '@metamask/utils@5.0.2': dependencies: - '@typechain/ethers-v5': 7.2.0(@ethersproject/abi@5.8.0)(@ethersproject/bytes@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3))(ethers@5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3))(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3) - ethers: 5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3) - keccak256: 1.0.6 + '@ethereumjs/tx': 4.2.0 + '@types/debug': 4.1.7 + debug: 4.4.3 + semver: 7.7.3 + superstruct: 1.0.3 transitivePeerDependencies: - - '@ethersproject/abi' - - '@ethersproject/bytes' - - '@ethersproject/providers' - - bufferutil - - typechain - - typescript - - utf-8-validate + - supports-color - '@0xsequence/wallet-contracts@2.0.0(@ethersproject/abi@5.8.0)(@ethersproject/bytes@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3))(bufferutil@4.1.0)(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@6.0.3)': + '@metamask/utils@8.5.0': dependencies: - '@typechain/ethers-v5': 7.2.0(@ethersproject/abi@5.8.0)(@ethersproject/bytes@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3))(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3))(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - keccak256: 1.0.6 + '@ethereumjs/tx': 4.2.0 + '@metamask/superstruct': 3.2.1 + '@noble/hashes': 1.8.0 + '@scure/base': 1.2.6 + '@types/debug': 4.1.12 + debug: 4.3.4(supports-color@8.1.1) + pony-cause: 2.1.11 + semver: 7.7.3 + uuid: 9.0.1 transitivePeerDependencies: - - '@ethersproject/abi' - - '@ethersproject/bytes' - - '@ethersproject/providers' - - bufferutil - - typechain - - typescript - - utf-8-validate + - supports-color - '@0xsequence/wallet-contracts@3.0.1(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3)': + '@metamask/utils@9.3.0': dependencies: - '@typechain/ethers-v6': 0.5.1(ethers@6.16.0)(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - keccak256: 1.0.6 + '@ethereumjs/tx': 4.2.0 + '@metamask/superstruct': 3.2.1 + '@noble/hashes': 1.8.0 + '@scure/base': 1.2.6 + '@types/debug': 4.1.12 + debug: 4.3.4(supports-color@8.1.1) + pony-cause: 2.1.11 + semver: 7.7.3 + uuid: 9.0.1 transitivePeerDependencies: - - bufferutil - - typechain - - typescript - - utf-8-validate + - supports-color - '@0xsequence/wallet@1.10.15(bufferutil@4.1.0)(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10)': + '@mswjs/interceptors@0.35.9': dependencies: - '@0xsequence/abi': 1.10.15 - '@0xsequence/core': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/network': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/relayer': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/signhub': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/utils': 1.10.15(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - transitivePeerDependencies: - - bufferutil - - utf-8-validate + '@open-draft/deferred-promise': 2.2.0 + '@open-draft/logger': 0.3.0 + '@open-draft/until': 2.1.0 + is-node-process: 1.2.0 + outvariant: 1.4.3 + strict-event-emitter: 0.5.1 + + '@napi-rs/wasm-runtime@1.1.0': + dependencies: + '@emnapi/core': 1.7.1 + '@emnapi/runtime': 1.7.1 + '@tybys/wasm-util': 0.10.1 + optional: true - '@0xsequence/wallet@1.10.15(bufferutil@4.1.0)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10)': + '@napi-rs/wasm-runtime@1.1.1': dependencies: - '@0xsequence/abi': 1.10.15 - '@0xsequence/core': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/network': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/relayer': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/signhub': 1.10.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@0xsequence/utils': 1.10.15(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@emnapi/core': 1.7.1 + '@emnapi/runtime': 1.7.1 + '@tybys/wasm-util': 0.10.1 + optional: true + + '@next/bundle-analyzer@15.3.3(bufferutil@4.0.8)(utf-8-validate@6.0.5)': + dependencies: + webpack-bundle-analyzer: 4.10.1(bufferutil@4.0.8)(utf-8-validate@6.0.5) transitivePeerDependencies: - bufferutil - utf-8-validate - '@0xsequence/wallet@2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': - dependencies: - '@0xsequence/abi': 2.3.43 - '@0xsequence/core': 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/network': 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/relayer': 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/signhub': 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@0xsequence/utils': 2.3.43(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@next/env@15.4.10': {} - '@adraffy/ens-normalize@1.10.1': {} + '@next/swc-darwin-arm64@15.4.8': + optional: true - '@adraffy/ens-normalize@1.11.1': {} + '@next/swc-darwin-x64@15.4.8': + optional: true - '@aws-crypto/crc32@5.2.0': - dependencies: - '@aws-crypto/util': 5.2.0 - '@aws-sdk/types': 3.973.8 - tslib: 2.8.1 + '@next/swc-linux-arm64-gnu@15.4.8': + optional: true - '@aws-crypto/sha256-browser@5.2.0': + '@next/swc-linux-arm64-musl@15.4.8': + optional: true + + '@next/swc-linux-x64-gnu@15.4.8': + optional: true + + '@next/swc-linux-x64-musl@15.4.8': + optional: true + + '@next/swc-win32-arm64-msvc@15.4.8': + optional: true + + '@next/swc-win32-x64-msvc@15.4.8': + optional: true + + '@noble/ciphers@1.2.1': {} + + '@noble/ciphers@1.3.0': {} + + '@noble/curves@1.2.0': dependencies: - '@aws-crypto/sha256-js': 5.2.0 - '@aws-crypto/supports-web-crypto': 5.2.0 - '@aws-crypto/util': 5.2.0 - '@aws-sdk/types': 3.973.8 - '@aws-sdk/util-locate-window': 3.965.5 - '@smithy/util-utf8': 2.3.0 - tslib: 2.8.1 + '@noble/hashes': 1.3.2 - '@aws-crypto/sha256-js@1.2.2': + '@noble/curves@1.4.0': dependencies: - '@aws-crypto/util': 1.2.2 - '@aws-sdk/types': 3.973.8 - tslib: 1.14.1 + '@noble/hashes': 1.4.0 - '@aws-crypto/sha256-js@5.2.0': + '@noble/curves@1.4.2': dependencies: - '@aws-crypto/util': 5.2.0 - '@aws-sdk/types': 3.973.8 - tslib: 2.8.1 + '@noble/hashes': 1.4.0 - '@aws-crypto/supports-web-crypto@5.2.0': + '@noble/curves@1.8.0': dependencies: - tslib: 2.8.1 + '@noble/hashes': 1.7.0 - '@aws-crypto/util@1.2.2': + '@noble/curves@1.8.1': dependencies: - '@aws-sdk/types': 3.973.8 - '@aws-sdk/util-utf8-browser': 3.259.0 - tslib: 1.14.1 + '@noble/hashes': 1.7.1 - '@aws-crypto/util@5.2.0': + '@noble/curves@1.9.1': dependencies: - '@aws-sdk/types': 3.973.8 - '@smithy/util-utf8': 2.3.0 - tslib: 2.8.1 + '@noble/hashes': 1.8.0 - '@aws-sdk/client-cognito-identity-provider@3.1037.0': + '@noble/curves@1.9.2': dependencies: - '@aws-crypto/sha256-browser': 5.2.0 - '@aws-crypto/sha256-js': 5.2.0 - '@aws-sdk/core': 3.974.5 - '@aws-sdk/credential-provider-node': 3.972.36 - '@aws-sdk/middleware-host-header': 3.972.10 - '@aws-sdk/middleware-logger': 3.972.10 - '@aws-sdk/middleware-recursion-detection': 3.972.11 - '@aws-sdk/middleware-user-agent': 3.972.35 - '@aws-sdk/region-config-resolver': 3.972.13 - '@aws-sdk/types': 3.973.8 - '@aws-sdk/util-endpoints': 3.996.8 - '@aws-sdk/util-user-agent-browser': 3.972.10 - '@aws-sdk/util-user-agent-node': 3.973.21 - '@smithy/config-resolver': 4.4.17 - '@smithy/core': 3.23.17 - '@smithy/fetch-http-handler': 5.3.17 - '@smithy/hash-node': 4.2.14 - '@smithy/invalid-dependency': 4.2.14 - '@smithy/middleware-content-length': 4.2.14 - '@smithy/middleware-endpoint': 4.4.32 - '@smithy/middleware-retry': 4.5.5 - '@smithy/middleware-serde': 4.2.20 - '@smithy/middleware-stack': 4.2.14 - '@smithy/node-config-provider': 4.3.14 - '@smithy/node-http-handler': 4.6.1 - '@smithy/protocol-http': 5.3.14 - '@smithy/smithy-client': 4.12.13 - '@smithy/types': 4.14.1 - '@smithy/url-parser': 4.2.14 - '@smithy/util-base64': 4.3.2 - '@smithy/util-body-length-browser': 4.2.2 - '@smithy/util-body-length-node': 4.2.3 - '@smithy/util-defaults-mode-browser': 4.3.49 - '@smithy/util-defaults-mode-node': 4.2.54 - '@smithy/util-endpoints': 3.4.2 - '@smithy/util-middleware': 4.2.14 - '@smithy/util-retry': 4.3.4 - '@smithy/util-utf8': 4.2.2 - tslib: 2.8.1 - transitivePeerDependencies: - - aws-crt + '@noble/hashes': 1.8.0 - '@aws-sdk/client-lambda@3.1037.0': + '@noble/curves@1.9.7': dependencies: - '@aws-crypto/sha256-browser': 5.2.0 - '@aws-crypto/sha256-js': 5.2.0 - '@aws-sdk/core': 3.974.5 - '@aws-sdk/credential-provider-node': 3.972.36 - '@aws-sdk/middleware-host-header': 3.972.10 - '@aws-sdk/middleware-logger': 3.972.10 - '@aws-sdk/middleware-recursion-detection': 3.972.11 - '@aws-sdk/middleware-user-agent': 3.972.35 - '@aws-sdk/region-config-resolver': 3.972.13 - '@aws-sdk/types': 3.973.8 - '@aws-sdk/util-endpoints': 3.996.8 - '@aws-sdk/util-user-agent-browser': 3.972.10 - '@aws-sdk/util-user-agent-node': 3.973.21 - '@smithy/config-resolver': 4.4.17 - '@smithy/core': 3.23.17 - '@smithy/eventstream-serde-browser': 4.2.14 - '@smithy/eventstream-serde-config-resolver': 4.3.14 - '@smithy/eventstream-serde-node': 4.2.14 - '@smithy/fetch-http-handler': 5.3.17 - '@smithy/hash-node': 4.2.14 - '@smithy/invalid-dependency': 4.2.14 - '@smithy/middleware-content-length': 4.2.14 - '@smithy/middleware-endpoint': 4.4.32 - '@smithy/middleware-retry': 4.5.5 - '@smithy/middleware-serde': 4.2.20 - '@smithy/middleware-stack': 4.2.14 - '@smithy/node-config-provider': 4.3.14 - '@smithy/node-http-handler': 4.6.1 - '@smithy/protocol-http': 5.3.14 - '@smithy/smithy-client': 4.12.13 - '@smithy/types': 4.14.1 - '@smithy/url-parser': 4.2.14 - '@smithy/util-base64': 4.3.2 - '@smithy/util-body-length-browser': 4.2.2 - '@smithy/util-body-length-node': 4.2.3 - '@smithy/util-defaults-mode-browser': 4.3.49 - '@smithy/util-defaults-mode-node': 4.2.54 - '@smithy/util-endpoints': 3.4.2 - '@smithy/util-middleware': 4.2.14 - '@smithy/util-retry': 4.3.4 - '@smithy/util-stream': 4.5.25 - '@smithy/util-utf8': 4.2.2 - '@smithy/util-waiter': 4.2.16 - tslib: 2.8.1 - transitivePeerDependencies: - - aws-crt + '@noble/hashes': 1.8.0 - '@aws-sdk/core@3.974.5': - dependencies: - '@aws-sdk/types': 3.973.8 - '@aws-sdk/xml-builder': 3.972.19 - '@smithy/core': 3.23.17 - '@smithy/node-config-provider': 4.3.14 - '@smithy/property-provider': 4.2.14 - '@smithy/protocol-http': 5.3.14 - '@smithy/signature-v4': 5.3.14 - '@smithy/smithy-client': 4.12.13 - '@smithy/types': 4.14.1 - '@smithy/util-base64': 4.3.2 - '@smithy/util-middleware': 4.2.14 - '@smithy/util-retry': 4.3.4 - '@smithy/util-utf8': 4.2.2 - tslib: 2.8.1 + '@noble/hashes@1.2.0': {} - '@aws-sdk/credential-provider-env@3.972.31': - dependencies: - '@aws-sdk/core': 3.974.5 - '@aws-sdk/types': 3.973.8 - '@smithy/property-provider': 4.2.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@noble/hashes@1.3.2': {} - '@aws-sdk/credential-provider-http@3.972.33': - dependencies: - '@aws-sdk/core': 3.974.5 - '@aws-sdk/types': 3.973.8 - '@smithy/fetch-http-handler': 5.3.17 - '@smithy/node-http-handler': 4.6.1 - '@smithy/property-provider': 4.2.14 - '@smithy/protocol-http': 5.3.14 - '@smithy/smithy-client': 4.12.13 - '@smithy/types': 4.14.1 - '@smithy/util-stream': 4.5.25 - tslib: 2.8.1 + '@noble/hashes@1.4.0': {} - '@aws-sdk/credential-provider-ini@3.972.35': - dependencies: - '@aws-sdk/core': 3.974.5 - '@aws-sdk/credential-provider-env': 3.972.31 - '@aws-sdk/credential-provider-http': 3.972.33 - '@aws-sdk/credential-provider-login': 3.972.35 - '@aws-sdk/credential-provider-process': 3.972.31 - '@aws-sdk/credential-provider-sso': 3.972.35 - '@aws-sdk/credential-provider-web-identity': 3.972.35 - '@aws-sdk/nested-clients': 3.997.3 - '@aws-sdk/types': 3.973.8 - '@smithy/credential-provider-imds': 4.2.14 - '@smithy/property-provider': 4.2.14 - '@smithy/shared-ini-file-loader': 4.4.9 - '@smithy/types': 4.14.1 - tslib: 2.8.1 - transitivePeerDependencies: - - aws-crt + '@noble/hashes@1.5.0': {} - '@aws-sdk/credential-provider-login@3.972.35': - dependencies: - '@aws-sdk/core': 3.974.5 - '@aws-sdk/nested-clients': 3.997.3 - '@aws-sdk/types': 3.973.8 - '@smithy/property-provider': 4.2.14 - '@smithy/protocol-http': 5.3.14 - '@smithy/shared-ini-file-loader': 4.4.9 - '@smithy/types': 4.14.1 - tslib: 2.8.1 - transitivePeerDependencies: - - aws-crt + '@noble/hashes@1.7.0': {} - '@aws-sdk/credential-provider-node@3.972.36': - dependencies: - '@aws-sdk/credential-provider-env': 3.972.31 - '@aws-sdk/credential-provider-http': 3.972.33 - '@aws-sdk/credential-provider-ini': 3.972.35 - '@aws-sdk/credential-provider-process': 3.972.31 - '@aws-sdk/credential-provider-sso': 3.972.35 - '@aws-sdk/credential-provider-web-identity': 3.972.35 - '@aws-sdk/types': 3.973.8 - '@smithy/credential-provider-imds': 4.2.14 - '@smithy/property-provider': 4.2.14 - '@smithy/shared-ini-file-loader': 4.4.9 - '@smithy/types': 4.14.1 - tslib: 2.8.1 - transitivePeerDependencies: - - aws-crt + '@noble/hashes@1.7.1': {} - '@aws-sdk/credential-provider-process@3.972.31': - dependencies: - '@aws-sdk/core': 3.974.5 - '@aws-sdk/types': 3.973.8 - '@smithy/property-provider': 4.2.14 - '@smithy/shared-ini-file-loader': 4.4.9 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@noble/hashes@1.8.0': {} - '@aws-sdk/credential-provider-sso@3.972.35': - dependencies: - '@aws-sdk/core': 3.974.5 - '@aws-sdk/nested-clients': 3.997.3 - '@aws-sdk/token-providers': 3.1036.0 - '@aws-sdk/types': 3.973.8 - '@smithy/property-provider': 4.2.14 - '@smithy/shared-ini-file-loader': 4.4.9 - '@smithy/types': 4.14.1 - tslib: 2.8.1 - transitivePeerDependencies: - - aws-crt + '@noble/secp256k1@1.7.1': {} - '@aws-sdk/credential-provider-web-identity@3.972.35': + '@nodelib/fs.scandir@2.1.5': dependencies: - '@aws-sdk/core': 3.974.5 - '@aws-sdk/nested-clients': 3.997.3 - '@aws-sdk/types': 3.973.8 - '@smithy/property-provider': 4.2.14 - '@smithy/shared-ini-file-loader': 4.4.9 - '@smithy/types': 4.14.1 - tslib: 2.8.1 - transitivePeerDependencies: - - aws-crt + '@nodelib/fs.stat': 2.0.5 + run-parallel: 1.2.0 - '@aws-sdk/middleware-host-header@3.972.10': - dependencies: - '@aws-sdk/types': 3.973.8 - '@smithy/protocol-http': 5.3.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@nodelib/fs.stat@2.0.5': {} - '@aws-sdk/middleware-logger@3.972.10': + '@nodelib/fs.walk@1.2.8': dependencies: - '@aws-sdk/types': 3.973.8 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@nodelib/fs.scandir': 2.1.5 + fastq: 1.15.0 - '@aws-sdk/middleware-recursion-detection@3.972.11': - dependencies: - '@aws-sdk/types': 3.973.8 - '@aws/lambda-invoke-store': 0.2.4 - '@smithy/protocol-http': 5.3.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@nomicfoundation/edr-darwin-arm64@0.3.7': + optional: true - '@aws-sdk/middleware-sdk-s3@3.972.34': - dependencies: - '@aws-sdk/core': 3.974.5 - '@aws-sdk/types': 3.973.8 - '@aws-sdk/util-arn-parser': 3.972.3 - '@smithy/core': 3.23.17 - '@smithy/node-config-provider': 4.3.14 - '@smithy/protocol-http': 5.3.14 - '@smithy/signature-v4': 5.3.14 - '@smithy/smithy-client': 4.12.13 - '@smithy/types': 4.14.1 - '@smithy/util-config-provider': 4.2.2 - '@smithy/util-middleware': 4.2.14 - '@smithy/util-stream': 4.5.25 - '@smithy/util-utf8': 4.2.2 - tslib: 2.8.1 + '@nomicfoundation/edr-darwin-x64@0.3.7': + optional: true - '@aws-sdk/middleware-user-agent@3.972.35': - dependencies: - '@aws-sdk/core': 3.974.5 - '@aws-sdk/types': 3.973.8 - '@aws-sdk/util-endpoints': 3.996.8 - '@smithy/core': 3.23.17 - '@smithy/protocol-http': 5.3.14 - '@smithy/types': 4.14.1 - '@smithy/util-retry': 4.3.4 - tslib: 2.8.1 + '@nomicfoundation/edr-linux-arm64-gnu@0.3.7': + optional: true - '@aws-sdk/nested-clients@3.997.3': - dependencies: - '@aws-crypto/sha256-browser': 5.2.0 - '@aws-crypto/sha256-js': 5.2.0 - '@aws-sdk/core': 3.974.5 - '@aws-sdk/middleware-host-header': 3.972.10 - '@aws-sdk/middleware-logger': 3.972.10 - '@aws-sdk/middleware-recursion-detection': 3.972.11 - '@aws-sdk/middleware-user-agent': 3.972.35 - '@aws-sdk/region-config-resolver': 3.972.13 - '@aws-sdk/signature-v4-multi-region': 3.996.22 - '@aws-sdk/types': 3.973.8 - '@aws-sdk/util-endpoints': 3.996.8 - '@aws-sdk/util-user-agent-browser': 3.972.10 - '@aws-sdk/util-user-agent-node': 3.973.21 - '@smithy/config-resolver': 4.4.17 - '@smithy/core': 3.23.17 - '@smithy/fetch-http-handler': 5.3.17 - '@smithy/hash-node': 4.2.14 - '@smithy/invalid-dependency': 4.2.14 - '@smithy/middleware-content-length': 4.2.14 - '@smithy/middleware-endpoint': 4.4.32 - '@smithy/middleware-retry': 4.5.5 - '@smithy/middleware-serde': 4.2.20 - '@smithy/middleware-stack': 4.2.14 - '@smithy/node-config-provider': 4.3.14 - '@smithy/node-http-handler': 4.6.1 - '@smithy/protocol-http': 5.3.14 - '@smithy/smithy-client': 4.12.13 - '@smithy/types': 4.14.1 - '@smithy/url-parser': 4.2.14 - '@smithy/util-base64': 4.3.2 - '@smithy/util-body-length-browser': 4.2.2 - '@smithy/util-body-length-node': 4.2.3 - '@smithy/util-defaults-mode-browser': 4.3.49 - '@smithy/util-defaults-mode-node': 4.2.54 - '@smithy/util-endpoints': 3.4.2 - '@smithy/util-middleware': 4.2.14 - '@smithy/util-retry': 4.3.4 - '@smithy/util-utf8': 4.2.2 - tslib: 2.8.1 - transitivePeerDependencies: - - aws-crt + '@nomicfoundation/edr-linux-arm64-musl@0.3.7': + optional: true - '@aws-sdk/region-config-resolver@3.972.13': - dependencies: - '@aws-sdk/types': 3.973.8 - '@smithy/config-resolver': 4.4.17 - '@smithy/node-config-provider': 4.3.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@nomicfoundation/edr-linux-x64-gnu@0.3.7': + optional: true - '@aws-sdk/signature-v4-multi-region@3.996.22': - dependencies: - '@aws-sdk/middleware-sdk-s3': 3.972.34 - '@aws-sdk/types': 3.973.8 - '@smithy/protocol-http': 5.3.14 - '@smithy/signature-v4': 5.3.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@nomicfoundation/edr-linux-x64-musl@0.3.7': + optional: true + + '@nomicfoundation/edr-win32-x64-msvc@0.3.7': + optional: true - '@aws-sdk/token-providers@3.1036.0': + '@nomicfoundation/edr@0.3.7': + optionalDependencies: + '@nomicfoundation/edr-darwin-arm64': 0.3.7 + '@nomicfoundation/edr-darwin-x64': 0.3.7 + '@nomicfoundation/edr-linux-arm64-gnu': 0.3.7 + '@nomicfoundation/edr-linux-arm64-musl': 0.3.7 + '@nomicfoundation/edr-linux-x64-gnu': 0.3.7 + '@nomicfoundation/edr-linux-x64-musl': 0.3.7 + '@nomicfoundation/edr-win32-x64-msvc': 0.3.7 + + '@nomicfoundation/ethereumjs-common@4.0.4': dependencies: - '@aws-sdk/core': 3.974.5 - '@aws-sdk/nested-clients': 3.997.3 - '@aws-sdk/types': 3.973.8 - '@smithy/property-provider': 4.2.14 - '@smithy/shared-ini-file-loader': 4.4.9 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@nomicfoundation/ethereumjs-util': 9.0.4 transitivePeerDependencies: - - aws-crt + - c-kzg - '@aws-sdk/types@3.973.8': - dependencies: - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@nomicfoundation/ethereumjs-rlp@5.0.4': {} - '@aws-sdk/util-arn-parser@3.972.3': + '@nomicfoundation/ethereumjs-tx@5.0.4': dependencies: - tslib: 2.8.1 + '@nomicfoundation/ethereumjs-common': 4.0.4 + '@nomicfoundation/ethereumjs-rlp': 5.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + ethereum-cryptography: 0.1.3 - '@aws-sdk/util-endpoints@3.996.8': + '@nomicfoundation/ethereumjs-util@9.0.4': dependencies: - '@aws-sdk/types': 3.973.8 - '@smithy/types': 4.14.1 - '@smithy/url-parser': 4.2.14 - '@smithy/util-endpoints': 3.4.2 - tslib: 2.8.1 + '@nomicfoundation/ethereumjs-rlp': 5.0.4 + ethereum-cryptography: 0.1.3 - '@aws-sdk/util-locate-window@3.965.5': + '@nomicfoundation/slang@1.3.1': dependencies: - tslib: 2.8.1 + '@bytecodealliance/preview2-shim': 0.17.6 - '@aws-sdk/util-user-agent-browser@3.972.10': - dependencies: - '@aws-sdk/types': 3.973.8 - '@smithy/types': 4.14.1 - bowser: 2.14.1 - tslib: 2.8.1 + '@nomicfoundation/solidity-analyzer-darwin-arm64@0.1.1': + optional: true - '@aws-sdk/util-user-agent-node@3.973.21': - dependencies: - '@aws-sdk/middleware-user-agent': 3.972.35 - '@aws-sdk/types': 3.973.8 - '@smithy/node-config-provider': 4.3.14 - '@smithy/types': 4.14.1 - '@smithy/util-config-provider': 4.2.2 - tslib: 2.8.1 + '@nomicfoundation/solidity-analyzer-darwin-x64@0.1.1': + optional: true - '@aws-sdk/util-utf8-browser@3.259.0': - dependencies: - tslib: 2.8.1 + '@nomicfoundation/solidity-analyzer-freebsd-x64@0.1.1': + optional: true - '@aws-sdk/xml-builder@3.972.19': - dependencies: - '@smithy/types': 4.14.1 - fast-xml-parser: 5.7.1 - tslib: 2.8.1 + '@nomicfoundation/solidity-analyzer-linux-arm64-gnu@0.1.1': + optional: true - '@aws/lambda-invoke-store@0.2.4': {} + '@nomicfoundation/solidity-analyzer-linux-arm64-musl@0.1.1': + optional: true - '@babel/code-frame@7.27.1': - dependencies: - '@babel/helper-validator-identifier': 7.28.5 - js-tokens: 4.0.0 - picocolors: 1.1.1 + '@nomicfoundation/solidity-analyzer-linux-x64-gnu@0.1.1': + optional: true - '@babel/code-frame@7.29.0': - dependencies: - '@babel/helper-validator-identifier': 7.28.5 - js-tokens: 4.0.0 - picocolors: 1.1.1 + '@nomicfoundation/solidity-analyzer-linux-x64-musl@0.1.1': + optional: true - '@babel/compat-data@7.28.5': {} + '@nomicfoundation/solidity-analyzer-win32-arm64-msvc@0.1.1': + optional: true - '@babel/compat-data@7.29.0': {} + '@nomicfoundation/solidity-analyzer-win32-ia32-msvc@0.1.1': + optional: true - '@babel/core@7.28.5': - dependencies: - '@babel/code-frame': 7.27.1 - '@babel/generator': 7.28.5 - '@babel/helper-compilation-targets': 7.27.2 - '@babel/helper-module-transforms': 7.28.3(@babel/core@7.28.5) - '@babel/helpers': 7.28.4 - '@babel/parser': 7.28.5 - '@babel/template': 7.27.2 - '@babel/traverse': 7.28.5 - '@babel/types': 7.28.5 - '@jridgewell/remapping': 2.3.5 - convert-source-map: 2.0.0 - debug: 4.4.3(supports-color@5.5.0) - gensync: 1.0.0-beta.2 - json5: 2.2.3 - semver: 6.3.1 - transitivePeerDependencies: - - supports-color + '@nomicfoundation/solidity-analyzer-win32-x64-msvc@0.1.1': + optional: true - '@babel/core@7.29.0': - dependencies: - '@babel/code-frame': 7.29.0 - '@babel/generator': 7.29.1 - '@babel/helper-compilation-targets': 7.28.6 - '@babel/helper-module-transforms': 7.28.6(@babel/core@7.29.0) - '@babel/helpers': 7.29.2 - '@babel/parser': 7.29.2 - '@babel/template': 7.28.6 - '@babel/traverse': 7.29.0 - '@babel/types': 7.29.0 - '@jridgewell/remapping': 2.3.5 - convert-source-map: 2.0.0 - debug: 4.4.3(supports-color@5.5.0) - gensync: 1.0.0-beta.2 - json5: 2.2.3 - semver: 6.3.1 + '@nomicfoundation/solidity-analyzer@0.1.1': + optionalDependencies: + '@nomicfoundation/solidity-analyzer-darwin-arm64': 0.1.1 + '@nomicfoundation/solidity-analyzer-darwin-x64': 0.1.1 + '@nomicfoundation/solidity-analyzer-freebsd-x64': 0.1.1 + '@nomicfoundation/solidity-analyzer-linux-arm64-gnu': 0.1.1 + '@nomicfoundation/solidity-analyzer-linux-arm64-musl': 0.1.1 + '@nomicfoundation/solidity-analyzer-linux-x64-gnu': 0.1.1 + '@nomicfoundation/solidity-analyzer-linux-x64-musl': 0.1.1 + '@nomicfoundation/solidity-analyzer-win32-arm64-msvc': 0.1.1 + '@nomicfoundation/solidity-analyzer-win32-ia32-msvc': 0.1.1 + '@nomicfoundation/solidity-analyzer-win32-x64-msvc': 0.1.1 + + '@nuxt/cli@3.31.3(cac@6.7.14)(magicast@0.5.1)': + dependencies: + '@bomb.sh/tab': 0.0.10(cac@6.7.14)(citty@0.1.6) + '@clack/prompts': 1.0.0-alpha.8 + c12: 3.3.3(magicast@0.5.1) + citty: 0.1.6 + confbox: 0.2.2 + consola: 3.4.2 + copy-paste: 2.2.0 + debug: 4.4.3 + defu: 6.1.4 + exsolve: 1.0.8 + fuse.js: 7.1.0 + giget: 2.0.0 + jiti: 2.6.1 + listhen: 1.9.0 + nypm: 0.6.2 + ofetch: 1.5.1 + ohash: 2.0.11 + pathe: 2.0.3 + perfect-debounce: 2.0.0 + pkg-types: 2.3.0 + scule: 1.3.0 + semver: 7.7.3 + srvx: 0.9.8 + std-env: 3.10.0 + tinyexec: 1.0.2 + ufo: 1.6.1 + youch: 4.1.0-beta.13 transitivePeerDependencies: + - cac + - commander + - magicast - supports-color - '@babel/generator@7.28.5': - dependencies: - '@babel/parser': 7.28.5 - '@babel/types': 7.28.5 - '@jridgewell/gen-mapping': 0.3.13 - '@jridgewell/trace-mapping': 0.3.31 - jsesc: 3.1.0 + '@nuxt/devalue@2.0.2': {} - '@babel/generator@7.29.1': + '@nuxt/devtools-kit@2.7.0(magicast@0.3.5)(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))': dependencies: - '@babel/parser': 7.29.2 - '@babel/types': 7.29.0 - '@jridgewell/gen-mapping': 0.3.13 - '@jridgewell/trace-mapping': 0.3.31 - jsesc: 3.1.0 + '@nuxt/kit': 3.20.2(magicast@0.3.5) + execa: 8.0.1 + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + transitivePeerDependencies: + - magicast - '@babel/helper-compilation-targets@7.27.2': + '@nuxt/devtools-wizard@2.7.0': dependencies: - '@babel/compat-data': 7.28.5 - '@babel/helper-validator-option': 7.27.1 - browserslist: 4.28.1 - lru-cache: 5.1.1 - semver: 6.3.1 + consola: 3.4.2 + diff: 8.0.2 + execa: 8.0.1 + magicast: 0.3.5 + pathe: 2.0.3 + pkg-types: 2.3.0 + prompts: 2.4.2 + semver: 7.7.3 + + '@nuxt/devtools@2.7.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(vue@3.5.26(typescript@5.9.3))': + dependencies: + '@nuxt/devtools-kit': 2.7.0(magicast@0.3.5)(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2)) + '@nuxt/devtools-wizard': 2.7.0 + '@nuxt/kit': 3.20.2(magicast@0.3.5) + '@vue/devtools-core': 7.7.9(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(vue@3.5.26(typescript@5.9.3)) + '@vue/devtools-kit': 7.7.9 + birpc: 2.9.0 + consola: 3.4.2 + destr: 2.0.5 + error-stack-parser-es: 1.0.5 + execa: 8.0.1 + fast-npm-meta: 0.4.7 + get-port-please: 3.2.0 + hookable: 5.5.3 + image-meta: 0.2.2 + is-installed-globally: 1.0.0 + launch-editor: 2.12.0 + local-pkg: 1.1.2 + magicast: 0.3.5 + nypm: 0.6.2 + ohash: 2.0.11 + pathe: 2.0.3 + perfect-debounce: 1.0.0 + pkg-types: 2.3.0 + semver: 7.7.3 + simple-git: 3.30.0 + sirv: 3.0.2 + structured-clone-es: 1.0.0 + tinyglobby: 0.2.15 + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + vite-plugin-inspect: 11.3.3(@nuxt/kit@3.20.2(magicast@0.3.5))(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2)) + vite-plugin-vue-tracer: 1.2.0(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(vue@3.5.26(typescript@5.9.3)) + which: 5.0.0 + ws: 8.18.3(bufferutil@4.1.0)(utf-8-validate@6.0.5) + transitivePeerDependencies: + - bufferutil + - supports-color + - utf-8-validate + - vue - '@babel/helper-compilation-targets@7.28.6': + '@nuxt/kit@3.19.0(magicast@0.5.1)': dependencies: - '@babel/compat-data': 7.29.0 - '@babel/helper-validator-option': 7.27.1 - browserslist: 4.28.2 - lru-cache: 5.1.1 - semver: 6.3.1 - - '@babel/helper-globals@7.28.0': {} + c12: 3.3.3(magicast@0.5.1) + consola: 3.4.2 + defu: 6.1.4 + destr: 2.0.5 + errx: 0.1.0 + exsolve: 1.0.8 + ignore: 7.0.5 + jiti: 2.6.1 + klona: 2.0.6 + knitwork: 1.3.0 + mlly: 1.8.0 + ohash: 2.0.11 + pathe: 2.0.3 + pkg-types: 2.3.0 + rc9: 2.1.2 + scule: 1.3.0 + semver: 7.7.3 + std-env: 3.10.0 + tinyglobby: 0.2.15 + ufo: 1.6.1 + unctx: 2.5.0 + unimport: 5.6.0 + untyped: 2.0.0 + transitivePeerDependencies: + - magicast - '@babel/helper-module-imports@7.27.1': + '@nuxt/kit@3.20.2(magicast@0.3.5)': dependencies: - '@babel/traverse': 7.28.5 - '@babel/types': 7.28.5 + c12: 3.3.3(magicast@0.3.5) + consola: 3.4.2 + defu: 6.1.4 + destr: 2.0.5 + errx: 0.1.0 + exsolve: 1.0.8 + ignore: 7.0.5 + jiti: 2.6.1 + klona: 2.0.6 + knitwork: 1.3.0 + mlly: 1.8.0 + ohash: 2.0.11 + pathe: 2.0.3 + pkg-types: 2.3.0 + rc9: 2.1.2 + scule: 1.3.0 + semver: 7.7.3 + tinyglobby: 0.2.15 + ufo: 1.6.1 + unctx: 2.5.0 + untyped: 2.0.0 transitivePeerDependencies: - - supports-color + - magicast - '@babel/helper-module-imports@7.28.6': + '@nuxt/kit@3.20.2(magicast@0.5.1)': dependencies: - '@babel/traverse': 7.29.0 - '@babel/types': 7.29.0 + c12: 3.3.3(magicast@0.5.1) + consola: 3.4.2 + defu: 6.1.4 + destr: 2.0.5 + errx: 0.1.0 + exsolve: 1.0.8 + ignore: 7.0.5 + jiti: 2.6.1 + klona: 2.0.6 + knitwork: 1.3.0 + mlly: 1.8.0 + ohash: 2.0.11 + pathe: 2.0.3 + pkg-types: 2.3.0 + rc9: 2.1.2 + scule: 1.3.0 + semver: 7.7.3 + tinyglobby: 0.2.15 + ufo: 1.6.1 + unctx: 2.5.0 + untyped: 2.0.0 + transitivePeerDependencies: + - magicast + + '@nuxt/schema@3.11.2(rollup@4.54.0)': + dependencies: + '@nuxt/ui-templates': 1.3.3 + consola: 3.2.3 + defu: 6.1.4 + hookable: 5.5.3 + pathe: 1.1.2 + pkg-types: 1.1.1 + scule: 1.3.0 + std-env: 3.7.0 + ufo: 1.5.3 + unimport: 3.7.1(rollup@4.54.0) + untyped: 1.4.2 transitivePeerDependencies: + - rollup - supports-color - '@babel/helper-module-transforms@7.28.3(@babel/core@7.28.5)': + '@nuxt/schema@3.19.0': dependencies: - '@babel/core': 7.28.5 - '@babel/helper-module-imports': 7.27.1 - '@babel/helper-validator-identifier': 7.28.5 - '@babel/traverse': 7.28.5 - transitivePeerDependencies: - - supports-color + '@vue/shared': 3.5.26 + consola: 3.4.2 + defu: 6.1.4 + pathe: 2.0.3 + std-env: 3.10.0 + ufo: 1.6.1 - '@babel/helper-module-transforms@7.28.6(@babel/core@7.29.0)': + '@nuxt/telemetry@2.6.6(magicast@0.5.1)': dependencies: - '@babel/core': 7.29.0 - '@babel/helper-module-imports': 7.28.6 - '@babel/helper-validator-identifier': 7.28.5 - '@babel/traverse': 7.29.0 + '@nuxt/kit': 3.20.2(magicast@0.5.1) + citty: 0.1.6 + consola: 3.4.2 + destr: 2.0.5 + dotenv: 16.6.1 + git-url-parse: 16.1.0 + is-docker: 3.0.0 + ofetch: 1.5.1 + package-manager-detector: 1.6.0 + pathe: 2.0.3 + rc9: 2.1.2 + std-env: 3.10.0 + transitivePeerDependencies: + - magicast + + '@nuxt/ui-templates@1.3.3': {} + + '@nuxt/vite-builder@3.19.0(@biomejs/biome@1.9.4)(@types/node@24.0.1)(lightningcss@1.30.2)(magicast@0.5.1)(rolldown@1.0.0-beta.35)(rollup@4.54.0)(terser@5.44.1)(tsx@4.19.2)(typescript@5.9.3)(vue@3.5.26(typescript@5.9.3))(yaml@2.8.2)': + dependencies: + '@nuxt/kit': 3.19.0(magicast@0.5.1) + '@rollup/plugin-replace': 6.0.3(rollup@4.54.0) + '@vitejs/plugin-vue': 6.0.3(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(vue@3.5.26(typescript@5.9.3)) + '@vitejs/plugin-vue-jsx': 5.1.3(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(vue@3.5.26(typescript@5.9.3)) + autoprefixer: 10.4.23(postcss@8.5.6) + consola: 3.4.2 + cssnano: 7.1.2(postcss@8.5.6) + defu: 6.1.4 + esbuild: 0.25.12 + escape-string-regexp: 5.0.0 + exsolve: 1.0.8 + externality: 1.0.2 + get-port-please: 3.2.0 + h3: 1.15.4 + jiti: 2.6.1 + knitwork: 1.3.0 + magic-string: 0.30.21 + mlly: 1.8.0 + mocked-exports: 0.1.1 + ohash: 2.0.11 + pathe: 2.0.3 + perfect-debounce: 2.0.0 + pkg-types: 2.3.0 + postcss: 8.5.6 + rollup-plugin-visualizer: 6.0.5(rolldown@1.0.0-beta.35)(rollup@4.54.0) + std-env: 3.10.0 + ufo: 1.6.1 + unenv: 2.0.0-rc.24 + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + vite-node: 3.2.4(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + vite-plugin-checker: 0.10.3(@biomejs/biome@1.9.4)(typescript@5.9.3)(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2)) + vue: 3.5.26(typescript@5.9.3) + vue-bundle-renderer: 2.2.0 transitivePeerDependencies: + - '@biomejs/biome' + - '@types/node' + - eslint + - less + - lightningcss + - magicast + - meow + - optionator + - rolldown + - rollup + - sass + - sass-embedded + - stylelint + - stylus + - sugarss - supports-color + - terser + - tsx + - typescript + - vls + - vti + - vue-tsc + - yaml - '@babel/helper-string-parser@7.27.1': {} - - '@babel/helper-validator-identifier@7.28.5': {} - - '@babel/helper-validator-option@7.27.1': {} - - '@babel/helpers@7.28.4': - dependencies: - '@babel/template': 7.27.2 - '@babel/types': 7.28.5 + '@one-ini/wasm@0.1.1': {} - '@babel/helpers@7.29.2': - dependencies: - '@babel/template': 7.28.6 - '@babel/types': 7.29.0 + '@open-draft/deferred-promise@2.2.0': {} - '@babel/parser@7.28.5': + '@open-draft/logger@0.3.0': dependencies: - '@babel/types': 7.28.5 + is-node-process: 1.2.0 + outvariant: 1.4.3 - '@babel/parser@7.29.2': - dependencies: - '@babel/types': 7.29.0 + '@open-draft/until@2.1.0': {} - '@babel/runtime-corejs3@7.28.4': - dependencies: - core-js-pure: 3.47.0 + '@oven/bun-darwin-aarch64@1.1.30': + optional: true - '@babel/runtime@7.29.2': {} + '@oven/bun-darwin-x64-baseline@1.1.30': + optional: true - '@babel/template@7.27.2': - dependencies: - '@babel/code-frame': 7.27.1 - '@babel/parser': 7.28.5 - '@babel/types': 7.28.5 + '@oven/bun-darwin-x64@1.1.30': + optional: true - '@babel/template@7.28.6': - dependencies: - '@babel/code-frame': 7.29.0 - '@babel/parser': 7.29.2 - '@babel/types': 7.29.0 + '@oven/bun-linux-aarch64@1.1.30': + optional: true - '@babel/traverse@7.28.5': - dependencies: - '@babel/code-frame': 7.27.1 - '@babel/generator': 7.28.5 - '@babel/helper-globals': 7.28.0 - '@babel/parser': 7.28.5 - '@babel/template': 7.27.2 - '@babel/types': 7.28.5 - debug: 4.4.3(supports-color@5.5.0) - transitivePeerDependencies: - - supports-color + '@oven/bun-linux-x64-baseline@1.1.30': + optional: true - '@babel/traverse@7.29.0': - dependencies: - '@babel/code-frame': 7.29.0 - '@babel/generator': 7.29.1 - '@babel/helper-globals': 7.28.0 - '@babel/parser': 7.29.2 - '@babel/template': 7.28.6 - '@babel/types': 7.29.0 - debug: 4.4.3(supports-color@5.5.0) - transitivePeerDependencies: - - supports-color + '@oven/bun-linux-x64@1.1.30': + optional: true - '@babel/types@7.28.5': - dependencies: - '@babel/helper-string-parser': 7.27.1 - '@babel/helper-validator-identifier': 7.28.5 + '@oven/bun-windows-x64-baseline@1.1.30': + optional: true - '@babel/types@7.29.0': - dependencies: - '@babel/helper-string-parser': 7.27.1 - '@babel/helper-validator-identifier': 7.28.5 + '@oven/bun-windows-x64@1.1.30': + optional: true - '@bcoe/v8-coverage@1.0.2': {} + '@oxc-minify/binding-android-arm64@0.86.0': + optional: true - '@bytecodealliance/preview2-shim@0.17.0': {} + '@oxc-minify/binding-darwin-arm64@0.86.0': + optional: true - '@changesets/apply-release-plan@7.1.1': - dependencies: - '@changesets/config': 3.1.4 - '@changesets/get-version-range-type': 0.4.0 - '@changesets/git': 3.0.4 - '@changesets/should-skip-package': 0.1.2 - '@changesets/types': 6.1.0 - '@manypkg/get-packages': 1.1.3 - detect-indent: 6.1.0 - fs-extra: 7.0.1 - lodash.startcase: 4.4.0 - outdent: 0.5.0 - prettier: 2.8.8 - resolve-from: 5.0.0 - semver: 7.7.4 + '@oxc-minify/binding-darwin-x64@0.86.0': + optional: true - '@changesets/assemble-release-plan@6.0.10': - dependencies: - '@changesets/errors': 0.2.0 - '@changesets/get-dependents-graph': 2.1.4 - '@changesets/should-skip-package': 0.1.2 - '@changesets/types': 6.1.0 - '@manypkg/get-packages': 1.1.3 - semver: 7.7.4 + '@oxc-minify/binding-freebsd-x64@0.86.0': + optional: true - '@changesets/changelog-git@0.2.1': - dependencies: - '@changesets/types': 6.1.0 + '@oxc-minify/binding-linux-arm-gnueabihf@0.86.0': + optional: true - '@changesets/cli@2.31.0(@types/node@25.6.0)': - dependencies: - '@changesets/apply-release-plan': 7.1.1 - '@changesets/assemble-release-plan': 6.0.10 - '@changesets/changelog-git': 0.2.1 - '@changesets/config': 3.1.4 - '@changesets/errors': 0.2.0 - '@changesets/get-dependents-graph': 2.1.4 - '@changesets/get-release-plan': 4.0.16 - '@changesets/git': 3.0.4 - '@changesets/logger': 0.1.1 - '@changesets/pre': 2.0.2 - '@changesets/read': 0.6.7 - '@changesets/should-skip-package': 0.1.2 - '@changesets/types': 6.1.0 - '@changesets/write': 0.4.0 - '@inquirer/external-editor': 1.0.3(@types/node@25.6.0) - '@manypkg/get-packages': 1.1.3 - ansi-colors: 4.1.3 - enquirer: 2.4.1 - fs-extra: 7.0.1 - mri: 1.2.0 - package-manager-detector: 0.2.11 - picocolors: 1.1.1 - resolve-from: 5.0.0 - semver: 7.7.4 - spawndamnit: 3.0.1 - term-size: 2.2.1 - transitivePeerDependencies: - - '@types/node' + '@oxc-minify/binding-linux-arm-musleabihf@0.86.0': + optional: true - '@changesets/config@3.1.4': - dependencies: - '@changesets/errors': 0.2.0 - '@changesets/get-dependents-graph': 2.1.4 - '@changesets/logger': 0.1.1 - '@changesets/should-skip-package': 0.1.2 - '@changesets/types': 6.1.0 - '@manypkg/get-packages': 1.1.3 - fs-extra: 7.0.1 - micromatch: 4.0.8 + '@oxc-minify/binding-linux-arm64-gnu@0.86.0': + optional: true - '@changesets/errors@0.2.0': - dependencies: - extendable-error: 0.1.7 + '@oxc-minify/binding-linux-arm64-musl@0.86.0': + optional: true - '@changesets/get-dependents-graph@2.1.4': - dependencies: - '@changesets/types': 6.1.0 - '@manypkg/get-packages': 1.1.3 - picocolors: 1.1.1 - semver: 7.7.4 + '@oxc-minify/binding-linux-riscv64-gnu@0.86.0': + optional: true - '@changesets/get-release-plan@4.0.16': - dependencies: - '@changesets/assemble-release-plan': 6.0.10 - '@changesets/config': 3.1.4 - '@changesets/pre': 2.0.2 - '@changesets/read': 0.6.7 - '@changesets/types': 6.1.0 - '@manypkg/get-packages': 1.1.3 + '@oxc-minify/binding-linux-s390x-gnu@0.86.0': + optional: true - '@changesets/get-version-range-type@0.4.0': {} + '@oxc-minify/binding-linux-x64-gnu@0.86.0': + optional: true - '@changesets/git@3.0.4': - dependencies: - '@changesets/errors': 0.2.0 - '@manypkg/get-packages': 1.1.3 - is-subdir: 1.2.0 - micromatch: 4.0.8 - spawndamnit: 3.0.1 + '@oxc-minify/binding-linux-x64-musl@0.86.0': + optional: true - '@changesets/logger@0.1.1': + '@oxc-minify/binding-wasm32-wasi@0.86.0': dependencies: - picocolors: 1.1.1 + '@napi-rs/wasm-runtime': 1.1.0 + optional: true - '@changesets/parse@0.4.3': - dependencies: - '@changesets/types': 6.1.0 - js-yaml: 4.1.1 + '@oxc-minify/binding-win32-arm64-msvc@0.86.0': + optional: true - '@changesets/pre@2.0.2': - dependencies: - '@changesets/errors': 0.2.0 - '@changesets/types': 6.1.0 - '@manypkg/get-packages': 1.1.3 - fs-extra: 7.0.1 + '@oxc-minify/binding-win32-x64-msvc@0.86.0': + optional: true - '@changesets/read@0.6.7': - dependencies: - '@changesets/git': 3.0.4 - '@changesets/logger': 0.1.1 - '@changesets/parse': 0.4.3 - '@changesets/types': 6.1.0 - fs-extra: 7.0.1 - p-filter: 2.1.0 - picocolors: 1.1.1 + '@oxc-parser/binding-android-arm64@0.86.0': + optional: true - '@changesets/should-skip-package@0.1.2': - dependencies: - '@changesets/types': 6.1.0 - '@manypkg/get-packages': 1.1.3 + '@oxc-parser/binding-darwin-arm64@0.86.0': + optional: true - '@changesets/types@4.1.0': {} + '@oxc-parser/binding-darwin-x64@0.86.0': + optional: true - '@changesets/types@6.1.0': {} + '@oxc-parser/binding-freebsd-x64@0.86.0': + optional: true - '@changesets/write@0.4.0': - dependencies: - '@changesets/types': 6.1.0 - fs-extra: 7.0.1 - human-id: 4.1.3 - prettier: 2.8.8 + '@oxc-parser/binding-linux-arm-gnueabihf@0.86.0': + optional: true - '@colors/colors@1.5.0': + '@oxc-parser/binding-linux-arm-musleabihf@0.86.0': optional: true - '@cspotcode/source-map-support@0.8.1': - dependencies: - '@jridgewell/trace-mapping': 0.3.9 + '@oxc-parser/binding-linux-arm64-gnu@0.86.0': + optional: true - '@cypress/request@3.0.10': - dependencies: - aws-sign2: 0.7.0 - aws4: 1.13.2 - caseless: 0.12.0 - combined-stream: 1.0.8 - extend: 3.0.2 - forever-agent: 0.6.1 - form-data: 4.0.5 - http-signature: 1.4.0 - is-typedarray: 1.0.0 - isstream: 0.1.2 - json-stringify-safe: 5.0.1 - mime-types: 2.1.35 - performance-now: 2.1.0 - qs: 6.14.2 - safe-buffer: 5.2.1 - tough-cookie: 5.1.2 - tunnel-agent: 0.6.0 - uuid: 8.3.2 + '@oxc-parser/binding-linux-arm64-musl@0.86.0': + optional: true - '@databeat/tracker@0.9.3': - dependencies: - '@noble/hashes': 1.8.0 + '@oxc-parser/binding-linux-riscv64-gnu@0.86.0': + optional: true - '@emnapi/runtime@1.10.0': - dependencies: - tslib: 2.8.1 + '@oxc-parser/binding-linux-s390x-gnu@0.86.0': + optional: true + + '@oxc-parser/binding-linux-x64-gnu@0.86.0': + optional: true + + '@oxc-parser/binding-linux-x64-musl@0.86.0': optional: true - '@ensdomains/ens@0.4.5': + '@oxc-parser/binding-wasm32-wasi@0.86.0': dependencies: - bluebird: 3.7.2 - eth-ens-namehash: 2.0.8 - solc: 0.4.26 - testrpc: 0.0.1 - web3-utils: 1.10.4 + '@napi-rs/wasm-runtime': 1.1.0 + optional: true - '@ensdomains/resolver@0.2.4': {} + '@oxc-parser/binding-win32-arm64-msvc@0.86.0': + optional: true - '@esbuild/aix-ppc64@0.27.3': + '@oxc-parser/binding-win32-x64-msvc@0.86.0': optional: true - '@esbuild/android-arm64@0.27.3': + '@oxc-project/runtime@0.82.3': {} + + '@oxc-project/types@0.82.3': {} + + '@oxc-project/types@0.86.0': {} + + '@oxc-transform/binding-android-arm64@0.86.0': optional: true - '@esbuild/android-arm@0.27.3': + '@oxc-transform/binding-darwin-arm64@0.86.0': optional: true - '@esbuild/android-x64@0.27.3': + '@oxc-transform/binding-darwin-x64@0.86.0': optional: true - '@esbuild/darwin-arm64@0.27.3': + '@oxc-transform/binding-freebsd-x64@0.86.0': optional: true - '@esbuild/darwin-x64@0.27.3': + '@oxc-transform/binding-linux-arm-gnueabihf@0.86.0': optional: true - '@esbuild/freebsd-arm64@0.27.3': + '@oxc-transform/binding-linux-arm-musleabihf@0.86.0': optional: true - '@esbuild/freebsd-x64@0.27.3': + '@oxc-transform/binding-linux-arm64-gnu@0.86.0': optional: true - '@esbuild/linux-arm64@0.27.3': + '@oxc-transform/binding-linux-arm64-musl@0.86.0': optional: true - '@esbuild/linux-arm@0.27.3': + '@oxc-transform/binding-linux-riscv64-gnu@0.86.0': optional: true - '@esbuild/linux-ia32@0.27.3': + '@oxc-transform/binding-linux-s390x-gnu@0.86.0': optional: true - '@esbuild/linux-loong64@0.27.3': + '@oxc-transform/binding-linux-x64-gnu@0.86.0': optional: true - '@esbuild/linux-mips64el@0.27.3': + '@oxc-transform/binding-linux-x64-musl@0.86.0': optional: true - '@esbuild/linux-ppc64@0.27.3': + '@oxc-transform/binding-wasm32-wasi@0.86.0': + dependencies: + '@napi-rs/wasm-runtime': 1.1.0 optional: true - '@esbuild/linux-riscv64@0.27.3': + '@oxc-transform/binding-win32-arm64-msvc@0.86.0': optional: true - '@esbuild/linux-s390x@0.27.3': + '@oxc-transform/binding-win32-x64-msvc@0.86.0': optional: true - '@esbuild/linux-x64@0.27.3': + '@parcel/watcher-android-arm64@2.5.1': optional: true - '@esbuild/netbsd-arm64@0.27.3': + '@parcel/watcher-darwin-arm64@2.5.1': optional: true - '@esbuild/netbsd-x64@0.27.3': + '@parcel/watcher-darwin-x64@2.5.1': optional: true - '@esbuild/openbsd-arm64@0.27.3': + '@parcel/watcher-freebsd-x64@2.5.1': optional: true - '@esbuild/openbsd-x64@0.27.3': + '@parcel/watcher-linux-arm-glibc@2.5.1': optional: true - '@esbuild/openharmony-arm64@0.27.3': + '@parcel/watcher-linux-arm-musl@2.5.1': optional: true - '@esbuild/sunos-x64@0.27.3': + '@parcel/watcher-linux-arm64-glibc@2.5.1': optional: true - '@esbuild/win32-arm64@0.27.3': + '@parcel/watcher-linux-arm64-musl@2.5.1': optional: true - '@esbuild/win32-ia32@0.27.3': + '@parcel/watcher-linux-x64-glibc@2.5.1': optional: true - '@esbuild/win32-x64@0.27.3': + '@parcel/watcher-linux-x64-musl@2.5.1': optional: true - '@eslint-community/eslint-utils@4.9.0(eslint@9.39.2)': + '@parcel/watcher-wasm@2.4.1': dependencies: - eslint: 9.39.2 - eslint-visitor-keys: 3.4.3 + is-glob: 4.0.3 + micromatch: 4.0.8 - '@eslint-community/eslint-utils@4.9.1(eslint@9.39.2)': + '@parcel/watcher-wasm@2.5.1': dependencies: - eslint: 9.39.2 - eslint-visitor-keys: 3.4.3 + is-glob: 4.0.3 + micromatch: 4.0.8 - '@eslint-community/eslint-utils@4.9.1(eslint@9.39.4)': - dependencies: - eslint: 9.39.4 - eslint-visitor-keys: 3.4.3 + '@parcel/watcher-win32-arm64@2.5.1': + optional: true - '@eslint-community/regexpp@4.12.2': {} + '@parcel/watcher-win32-ia32@2.5.1': + optional: true - '@eslint/config-array@0.21.1': - dependencies: - '@eslint/object-schema': 2.1.7 - debug: 4.4.3(supports-color@5.5.0) - minimatch: 10.2.5 - transitivePeerDependencies: - - supports-color + '@parcel/watcher-win32-x64@2.5.1': + optional: true - '@eslint/config-array@0.21.2': + '@parcel/watcher@2.5.1': dependencies: - '@eslint/object-schema': 2.1.7 - debug: 4.4.3(supports-color@5.5.0) - minimatch: 3.1.5 - transitivePeerDependencies: - - supports-color + detect-libc: 1.0.3 + is-glob: 4.0.3 + micromatch: 4.0.8 + node-addon-api: 7.1.1 + optionalDependencies: + '@parcel/watcher-android-arm64': 2.5.1 + '@parcel/watcher-darwin-arm64': 2.5.1 + '@parcel/watcher-darwin-x64': 2.5.1 + '@parcel/watcher-freebsd-x64': 2.5.1 + '@parcel/watcher-linux-arm-glibc': 2.5.1 + '@parcel/watcher-linux-arm-musl': 2.5.1 + '@parcel/watcher-linux-arm64-glibc': 2.5.1 + '@parcel/watcher-linux-arm64-musl': 2.5.1 + '@parcel/watcher-linux-x64-glibc': 2.5.1 + '@parcel/watcher-linux-x64-musl': 2.5.1 + '@parcel/watcher-win32-arm64': 2.5.1 + '@parcel/watcher-win32-ia32': 2.5.1 + '@parcel/watcher-win32-x64': 2.5.1 + + '@paulmillr/qr@0.2.1': {} - '@eslint/config-helpers@0.4.2': - dependencies: - '@eslint/core': 0.17.0 + '@pkgjs/parseargs@0.11.0': + optional: true + + '@polka/url@1.0.0-next.29': {} - '@eslint/core@0.17.0': + '@poppinss/colors@4.1.6': dependencies: - '@types/json-schema': 7.0.15 + kleur: 4.1.5 - '@eslint/eslintrc@3.3.3': + '@poppinss/dumper@0.6.5': dependencies: - ajv: 8.20.0 - debug: 4.4.3(supports-color@5.5.0) - espree: 10.4.0 - globals: 14.0.0 - ignore: 5.3.2 - import-fresh: 3.3.1 - js-yaml: 4.1.1 - minimatch: 10.2.5 - strip-json-comments: 3.1.1 - transitivePeerDependencies: - - supports-color + '@poppinss/colors': 4.1.6 + '@sindresorhus/is': 7.1.1 + supports-color: 10.2.2 - '@eslint/eslintrc@3.3.5': + '@poppinss/exception@1.2.3': {} + + '@publint/pack@0.1.2': {} + + '@radix-ui/number@1.1.1': {} + + '@radix-ui/primitive@1.1.3': {} + + '@radix-ui/react-arrow@1.1.7(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - ajv: 6.15.0 - debug: 4.4.3(supports-color@5.5.0) - espree: 10.4.0 - globals: 14.0.0 - ignore: 5.3.2 - import-fresh: 3.3.1 - js-yaml: 4.1.1 - minimatch: 3.1.5 - strip-json-comments: 3.1.1 - transitivePeerDependencies: - - supports-color + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@eslint/js@9.39.2': {} + '@radix-ui/react-aspect-ratio@1.1.8(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/react-primitive': 2.1.4(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 + + '@radix-ui/react-checkbox@1.3.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-presence': 1.1.5(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-use-controllable-state': 1.2.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-previous': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-size': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 + + '@radix-ui/react-collapsible@1.1.12(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-id': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-presence': 1.1.5(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-use-controllable-state': 1.2.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-layout-effect': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@eslint/js@9.39.4': {} + '@radix-ui/react-collection@1.1.7(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-slot': 1.2.3(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@eslint/object-schema@2.1.7': {} + '@radix-ui/react-compose-refs@1.1.2(@types/react@18.3.27)(react@18.3.1)': + dependencies: + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@eslint/plugin-kit@0.4.1': + '@radix-ui/react-context@1.1.2(@types/react@18.3.27)(react@18.3.1)': dependencies: - '@eslint/core': 0.17.0 - levn: 0.4.1 + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@ethereum-waffle/chai@4.0.10(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@radix-ui/react-context@1.1.3(@types/react@18.3.27)(react@18.3.1)': dependencies: - '@ethereum-waffle/provider': 4.0.5(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - debug: 4.4.3(supports-color@5.5.0) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - json-bigint: 1.0.0 - transitivePeerDependencies: - - '@ensdomains/ens' - - '@ensdomains/resolver' - - supports-color + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 + + '@radix-ui/react-dialog@1.1.15(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-dismissable-layer': 1.1.11(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-focus-guards': 1.1.3(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-focus-scope': 1.1.7(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-id': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-portal': 1.1.9(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-presence': 1.1.5(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-slot': 1.2.3(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-controllable-state': 1.2.2(@types/react@18.3.27)(react@18.3.1) + aria-hidden: 1.2.6 + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + react-remove-scroll: 2.7.2(@types/react@18.3.27)(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@ethereum-waffle/compiler@4.0.3(@ethersproject/abi@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(encoding@0.1.13)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(solc@0.8.15)(typechain@8.3.2(typescript@4.9.5))(typescript@4.9.5)': + '@radix-ui/react-direction@1.1.1(@types/react@18.3.27)(react@18.3.1)': dependencies: - '@resolver-engine/imports': 0.3.3 - '@resolver-engine/imports-fs': 0.3.3 - '@typechain/ethers-v5': 10.2.1(@ethersproject/abi@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@4.9.5))(typescript@4.9.5) - '@types/mkdirp': 0.5.2 - '@types/node-fetch': 2.6.13 - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - mkdirp: 0.5.6 - node-fetch: 2.7.0(encoding@0.1.13) - solc: 0.8.15 - typechain: 8.3.2(typescript@4.9.5) - transitivePeerDependencies: - - '@ethersproject/abi' - - '@ethersproject/providers' - - encoding - - supports-color - - typescript + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@ethereum-waffle/ens@4.0.3(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@radix-ui/react-dismissable-layer@1.1.11(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - '@ensdomains/ens': 0.4.5 - '@ensdomains/resolver': 0.2.4 - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-use-callback-ref': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-escape-keydown': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 + + '@radix-ui/react-dropdown-menu@2.1.16(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-id': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-menu': 2.1.16(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-use-controllable-state': 1.2.2(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@ethereum-waffle/mock-contract@4.0.4(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@radix-ui/react-focus-guards@1.1.3(@types/react@18.3.27)(react@18.3.1)': dependencies: - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@ethereum-waffle/provider@4.0.5(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))': + '@radix-ui/react-focus-scope@1.1.7(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - '@ethereum-waffle/ens': 4.0.3(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@ganache/ethereum-options': 0.1.4 - debug: 4.4.3(supports-color@5.5.0) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - ganache: 7.4.3 - transitivePeerDependencies: - - '@ensdomains/ens' - - '@ensdomains/resolver' - - supports-color + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-use-callback-ref': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@ethereumjs/block@3.6.3': + '@radix-ui/react-id@1.1.1(@types/react@18.3.27)(react@18.3.1)': dependencies: - '@ethereumjs/common': 2.6.5 - '@ethereumjs/tx': 3.5.2 - ethereumjs-util: 7.1.5 - merkle-patricia-tree: 4.2.4 + '@radix-ui/react-use-layout-effect': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 + + '@radix-ui/react-menu@2.1.16(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-collection': 1.1.7(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-direction': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-dismissable-layer': 1.1.11(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-focus-guards': 1.1.3(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-focus-scope': 1.1.7(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-id': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-popper': 1.2.8(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-portal': 1.1.9(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-presence': 1.1.5(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-roving-focus': 1.1.11(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-slot': 1.2.3(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-callback-ref': 1.1.1(@types/react@18.3.27)(react@18.3.1) + aria-hidden: 1.2.6 + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + react-remove-scroll: 2.7.2(@types/react@18.3.27)(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 + + '@radix-ui/react-popper@1.2.8(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@floating-ui/react-dom': 2.1.6(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-arrow': 1.1.7(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-use-callback-ref': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-layout-effect': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-rect': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-size': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/rect': 1.1.1 + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@ethereumjs/blockchain@5.5.3': + '@radix-ui/react-portal@1.1.9(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - '@ethereumjs/block': 3.6.3 - '@ethereumjs/common': 2.6.5 - '@ethereumjs/ethash': 1.1.0 - debug: 4.4.3(supports-color@5.5.0) - ethereumjs-util: 7.1.5 - level-mem: 5.0.1 - lru-cache: 5.1.1 - semaphore-async-await: 1.5.1 - transitivePeerDependencies: - - supports-color + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-use-layout-effect': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@ethereumjs/common@2.6.0': + '@radix-ui/react-presence@1.1.5(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - crc-32: 1.2.2 - ethereumjs-util: 7.1.3 + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-layout-effect': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@ethereumjs/common@2.6.5': + '@radix-ui/react-primitive@2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - crc-32: 1.2.2 - ethereumjs-util: 7.1.5 + '@radix-ui/react-slot': 1.2.3(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@ethereumjs/ethash@1.1.0': + '@radix-ui/react-primitive@2.1.4(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - '@ethereumjs/block': 3.6.3 - '@types/levelup': 4.3.3 - buffer-xor: 2.0.2 - ethereumjs-util: 7.1.5 - miller-rabin: 4.0.1 + '@radix-ui/react-slot': 1.2.4(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@ethereumjs/rlp@4.0.1': {} + '@radix-ui/react-progress@1.1.8(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/react-context': 1.1.3(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-primitive': 2.1.4(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 + + '@radix-ui/react-radio-group@1.3.8(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-direction': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-presence': 1.1.5(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-roving-focus': 1.1.11(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-use-controllable-state': 1.2.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-previous': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-size': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 + + '@radix-ui/react-roving-focus@1.1.11(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-collection': 1.1.7(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-direction': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-id': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-use-callback-ref': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-controllable-state': 1.2.2(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 + + '@radix-ui/react-select@2.2.6(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/number': 1.1.1 + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-collection': 1.1.7(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-direction': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-dismissable-layer': 1.1.11(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-focus-guards': 1.1.3(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-focus-scope': 1.1.7(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-id': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-popper': 1.2.8(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-portal': 1.1.9(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-slot': 1.2.3(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-callback-ref': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-controllable-state': 1.2.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-layout-effect': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-previous': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-visually-hidden': 1.2.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + aria-hidden: 1.2.6 + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + react-remove-scroll: 2.7.2(@types/react@18.3.27)(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@ethereumjs/rlp@5.0.2': {} + '@radix-ui/react-slot@1.2.3(@types/react@18.3.27)(react@18.3.1)': + dependencies: + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@ethereumjs/tx@3.4.0': + '@radix-ui/react-slot@1.2.4(@types/react@18.3.27)(react@18.3.1)': dependencies: - '@ethereumjs/common': 2.6.0 - ethereumjs-util: 7.1.3 + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 + + '@radix-ui/react-switch@1.2.6(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-use-controllable-state': 1.2.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-previous': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-size': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 + + '@radix-ui/react-tabs@1.1.13(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-direction': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-id': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-presence': 1.1.5(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-roving-focus': 1.1.11(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-use-controllable-state': 1.2.2(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 + + '@radix-ui/react-toast@1.2.15(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-collection': 1.1.7(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-dismissable-layer': 1.1.11(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-portal': 1.1.9(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-presence': 1.1.5(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-use-callback-ref': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-controllable-state': 1.2.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-layout-effect': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-visually-hidden': 1.2.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 + + '@radix-ui/react-tooltip@1.2.8(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + dependencies: + '@radix-ui/primitive': 1.1.3 + '@radix-ui/react-compose-refs': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-context': 1.1.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-dismissable-layer': 1.1.11(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-id': 1.1.1(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-popper': 1.2.8(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-portal': 1.1.9(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-presence': 1.1.5(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@radix-ui/react-slot': 1.2.3(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-controllable-state': 1.2.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-visually-hidden': 1.2.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@ethereumjs/tx@3.5.2': + '@radix-ui/react-use-callback-ref@1.1.1(@types/react@18.3.27)(react@18.3.1)': dependencies: - '@ethereumjs/common': 2.6.5 - ethereumjs-util: 7.1.5 + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@ethereumjs/util@8.1.0': + '@radix-ui/react-use-controllable-state@1.2.2(@types/react@18.3.27)(react@18.3.1)': dependencies: - '@ethereumjs/rlp': 4.0.1 - ethereum-cryptography: 2.2.1 - micro-ftch: 0.3.1 + '@radix-ui/react-use-effect-event': 0.0.2(@types/react@18.3.27)(react@18.3.1) + '@radix-ui/react-use-layout-effect': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@ethereumjs/util@9.1.0': + '@radix-ui/react-use-effect-event@0.0.2(@types/react@18.3.27)(react@18.3.1)': dependencies: - '@ethereumjs/rlp': 5.0.2 - ethereum-cryptography: 2.2.1 + '@radix-ui/react-use-layout-effect': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@ethereumjs/vm@5.6.0': - dependencies: - '@ethereumjs/block': 3.6.3 - '@ethereumjs/blockchain': 5.5.3 - '@ethereumjs/common': 2.6.0 - '@ethereumjs/tx': 3.4.0 - async-eventemitter: 0.2.4 - core-js-pure: 3.49.0 - debug: 2.6.9 - ethereumjs-util: 7.1.3 - functional-red-black-tree: 1.0.1 - mcl-wasm: 0.7.9 - merkle-patricia-tree: 4.2.4 - rustbn.js: 0.2.0 - transitivePeerDependencies: - - supports-color + '@radix-ui/react-use-escape-keydown@1.1.1(@types/react@18.3.27)(react@18.3.1)': + dependencies: + '@radix-ui/react-use-callback-ref': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@ethersproject/abi@5.8.0': + '@radix-ui/react-use-layout-effect@1.1.1(@types/react@18.3.27)(react@18.3.1)': dependencies: - '@ethersproject/address': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/hash': 5.8.0 - '@ethersproject/keccak256': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/strings': 5.8.0 + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@ethersproject/abstract-provider@5.8.0': + '@radix-ui/react-use-previous@1.1.1(@types/react@18.3.27)(react@18.3.1)': dependencies: - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/networks': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/transactions': 5.8.0 - '@ethersproject/web': 5.8.0 - - '@ethersproject/abstract-signer@5.8.0': - dependencies: - '@ethersproject/abstract-provider': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/properties': 5.8.0 - - '@ethersproject/address@5.6.1': - dependencies: - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/keccak256': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/rlp': 5.8.0 - - '@ethersproject/address@5.8.0': - dependencies: - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/keccak256': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/rlp': 5.8.0 - - '@ethersproject/base64@5.8.0': - dependencies: - '@ethersproject/bytes': 5.8.0 - - '@ethersproject/basex@5.8.0': - dependencies: - '@ethersproject/bytes': 5.8.0 - '@ethersproject/properties': 5.8.0 - - '@ethersproject/bignumber@5.8.0': - dependencies: - '@ethersproject/bytes': 5.8.0 - '@ethersproject/logger': 5.8.0 - bn.js: 5.2.3 - - '@ethersproject/bytes@5.8.0': - dependencies: - '@ethersproject/logger': 5.8.0 - - '@ethersproject/constants@5.8.0': - dependencies: - '@ethersproject/bignumber': 5.8.0 - - '@ethersproject/contracts@5.8.0': - dependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/abstract-provider': 5.8.0 - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/address': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/transactions': 5.8.0 - - '@ethersproject/hash@5.8.0': - dependencies: - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/address': 5.8.0 - '@ethersproject/base64': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/keccak256': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/strings': 5.8.0 - - '@ethersproject/hdnode@5.8.0': - dependencies: - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/basex': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/pbkdf2': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/sha2': 5.8.0 - '@ethersproject/signing-key': 5.8.0 - '@ethersproject/strings': 5.8.0 - '@ethersproject/transactions': 5.8.0 - '@ethersproject/wordlists': 5.8.0 - - '@ethersproject/json-wallets@5.8.0': - dependencies: - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/address': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/hdnode': 5.8.0 - '@ethersproject/keccak256': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/pbkdf2': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/random': 5.8.0 - '@ethersproject/strings': 5.8.0 - '@ethersproject/transactions': 5.8.0 - aes-js: 3.0.0 - scrypt-js: 3.0.1 + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@ethersproject/keccak256@5.8.0': + '@radix-ui/react-use-rect@1.1.1(@types/react@18.3.27)(react@18.3.1)': dependencies: - '@ethersproject/bytes': 5.8.0 - js-sha3: 0.8.0 + '@radix-ui/rect': 1.1.1 + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@ethersproject/logger@5.8.0': {} + '@radix-ui/react-use-size@1.1.1(@types/react@18.3.27)(react@18.3.1)': + dependencies: + '@radix-ui/react-use-layout-effect': 1.1.1(@types/react@18.3.27)(react@18.3.1) + react: 18.3.1 + optionalDependencies: + '@types/react': 18.3.27 - '@ethersproject/networks@5.8.0': + '@radix-ui/react-visually-hidden@1.2.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - '@ethersproject/logger': 5.8.0 + '@radix-ui/react-primitive': 2.1.3(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 - '@ethersproject/pbkdf2@5.8.0': + '@radix-ui/react-visually-hidden@1.2.4(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - '@ethersproject/bytes': 5.8.0 - '@ethersproject/sha2': 5.8.0 + '@radix-ui/react-primitive': 2.1.4(@types/react-dom@18.3.0)(@types/react@18.3.27)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + '@types/react-dom': 18.3.0 + + '@radix-ui/rect@1.1.1': {} - '@ethersproject/properties@5.8.0': + '@react-oauth/google@0.11.1(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - '@ethersproject/logger': 5.8.0 + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) - '@ethersproject/providers@5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3)': + '@reown/appkit-common@1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.22.4)': dependencies: - '@ethersproject/abstract-provider': 5.8.0 - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/address': 5.8.0 - '@ethersproject/base64': 5.8.0 - '@ethersproject/basex': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/hash': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/networks': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/random': 5.8.0 - '@ethersproject/rlp': 5.8.0 - '@ethersproject/sha2': 5.8.0 - '@ethersproject/strings': 5.8.0 - '@ethersproject/transactions': 5.8.0 - '@ethersproject/web': 5.8.0 - bech32: 1.1.4 - ws: 8.18.0(bufferutil@4.0.7)(utf-8-validate@6.0.3) + big.js: 6.2.2 + dayjs: 1.11.13 + viem: 2.43.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.22.4) transitivePeerDependencies: - bufferutil + - typescript - utf-8-validate + - zod - '@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)': - dependencies: - '@ethersproject/abstract-provider': 5.8.0 - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/address': 5.8.0 - '@ethersproject/base64': 5.8.0 - '@ethersproject/basex': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/hash': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/networks': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/random': 5.8.0 - '@ethersproject/rlp': 5.8.0 - '@ethersproject/sha2': 5.8.0 - '@ethersproject/strings': 5.8.0 - '@ethersproject/transactions': 5.8.0 - '@ethersproject/web': 5.8.0 - bech32: 1.1.4 - ws: 8.18.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@reown/appkit-common@1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': + dependencies: + big.js: 6.2.2 + dayjs: 1.11.13 + viem: 2.43.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) transitivePeerDependencies: - bufferutil + - typescript - utf-8-validate + - zod - '@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3)': - dependencies: - '@ethersproject/abstract-provider': 5.8.0 - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/address': 5.8.0 - '@ethersproject/base64': 5.8.0 - '@ethersproject/basex': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/hash': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/networks': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/random': 5.8.0 - '@ethersproject/rlp': 5.8.0 - '@ethersproject/sha2': 5.8.0 - '@ethersproject/strings': 5.8.0 - '@ethersproject/transactions': 5.8.0 - '@ethersproject/web': 5.8.0 - bech32: 1.1.4 - ws: 8.18.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) + '@reown/appkit-controllers@1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': + dependencies: + '@reown/appkit-common': 1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-wallet': 1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10) + '@walletconnect/universal-provider': 2.19.2(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + valtio: 1.13.2(@types/react@18.3.27)(react@18.3.1) + viem: 2.43.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@types/react' + - '@upstash/redis' + - '@vercel/kv' - bufferutil + - encoding + - ioredis + - react + - typescript + - uWebSockets.js - utf-8-validate + - zod - '@ethersproject/random@5.8.0': + '@reown/appkit-polyfills@1.7.3': dependencies: - '@ethersproject/bytes': 5.8.0 - '@ethersproject/logger': 5.8.0 + buffer: 6.0.3 - '@ethersproject/rlp@5.8.0': + '@reown/appkit-scaffold-ui@1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': dependencies: - '@ethersproject/bytes': 5.8.0 - '@ethersproject/logger': 5.8.0 + '@reown/appkit-common': 1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-controllers': 1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-ui': 1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-utils': 1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-wallet': 1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10) + lit: 3.1.0 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@types/react' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - encoding + - ioredis + - react + - typescript + - uWebSockets.js + - utf-8-validate + - zod - '@ethersproject/sha2@5.8.0': + '@reown/appkit-ui@1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': dependencies: - '@ethersproject/bytes': 5.8.0 - '@ethersproject/logger': 5.8.0 - hash.js: 1.1.7 + '@reown/appkit-common': 1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-controllers': 1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-wallet': 1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10) + lit: 3.1.0 + qrcode: 1.5.3 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@types/react' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - encoding + - ioredis + - react + - typescript + - uWebSockets.js + - utf-8-validate + - zod - '@ethersproject/signing-key@5.8.0': + '@reown/appkit-utils@1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': dependencies: - '@ethersproject/bytes': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/properties': 5.8.0 - bn.js: 5.2.3 - elliptic: 6.6.1 - hash.js: 1.1.7 - - '@ethersproject/solidity@5.8.0': - dependencies: - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/keccak256': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/sha2': 5.8.0 - '@ethersproject/strings': 5.8.0 - - '@ethersproject/strings@5.8.0': - dependencies: - '@ethersproject/bytes': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/logger': 5.8.0 - - '@ethersproject/transactions@5.8.0': - dependencies: - '@ethersproject/address': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/keccak256': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/rlp': 5.8.0 - '@ethersproject/signing-key': 5.8.0 - - '@ethersproject/units@5.8.0': - dependencies: - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/logger': 5.8.0 - - '@ethersproject/wallet@5.8.0': - dependencies: - '@ethersproject/abstract-provider': 5.8.0 - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/address': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/hash': 5.8.0 - '@ethersproject/hdnode': 5.8.0 - '@ethersproject/json-wallets': 5.8.0 - '@ethersproject/keccak256': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/random': 5.8.0 - '@ethersproject/signing-key': 5.8.0 - '@ethersproject/transactions': 5.8.0 - '@ethersproject/wordlists': 5.8.0 - - '@ethersproject/web@5.8.0': - dependencies: - '@ethersproject/base64': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/strings': 5.8.0 - - '@ethersproject/wordlists@5.8.0': - dependencies: - '@ethersproject/bytes': 5.8.0 - '@ethersproject/hash': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/strings': 5.8.0 - - '@ganache/ethereum-address@0.1.4': - dependencies: - '@ganache/utils': 0.1.4 - - '@ganache/ethereum-options@0.1.4': - dependencies: - '@ganache/ethereum-address': 0.1.4 - '@ganache/ethereum-utils': 0.1.4 - '@ganache/options': 0.1.4 - '@ganache/utils': 0.1.4 - bip39: 3.0.4 - seedrandom: 3.0.5 + '@reown/appkit-common': 1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-controllers': 1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-polyfills': 1.7.3 + '@reown/appkit-wallet': 1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10) + '@walletconnect/logger': 2.1.2 + '@walletconnect/universal-provider': 2.19.2(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + valtio: 1.13.2(@types/react@18.3.27)(react@18.3.1) + viem: 2.43.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) transitivePeerDependencies: - - supports-color + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@types/react' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - encoding + - ioredis + - react + - typescript + - uWebSockets.js + - utf-8-validate + - zod - '@ganache/ethereum-utils@0.1.4': + '@reown/appkit-wallet@1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)': dependencies: - '@ethereumjs/common': 2.6.0 - '@ethereumjs/tx': 3.4.0 - '@ethereumjs/vm': 5.6.0 - '@ganache/ethereum-address': 0.1.4 - '@ganache/rlp': 0.1.4 - '@ganache/utils': 0.1.4 - emittery: 0.10.0 - ethereumjs-abi: 0.6.8 - ethereumjs-util: 7.1.3 + '@reown/appkit-common': 1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.22.4) + '@reown/appkit-polyfills': 1.7.3 + '@walletconnect/logger': 2.1.2 + zod: 3.22.4 transitivePeerDependencies: - - supports-color + - bufferutil + - typescript + - utf-8-validate - '@ganache/options@0.1.4': + '@reown/appkit@1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': + dependencies: + '@reown/appkit-common': 1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-controllers': 1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-polyfills': 1.7.3 + '@reown/appkit-scaffold-ui': 1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-ui': 1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-utils': 1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@reown/appkit-wallet': 1.7.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10) + '@walletconnect/types': 2.19.2(ioredis@5.8.2) + '@walletconnect/universal-provider': 2.19.2(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + bs58: 6.0.0 + valtio: 1.13.2(@types/react@18.3.27)(react@18.3.1) + viem: 2.43.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@types/react' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - encoding + - ioredis + - react + - typescript + - uWebSockets.js + - utf-8-validate + - zod + + '@rolldown/binding-android-arm64@1.0.0-beta.35': + optional: true + + '@rolldown/binding-darwin-arm64@1.0.0-beta.35': + optional: true + + '@rolldown/binding-darwin-x64@1.0.0-beta.35': + optional: true + + '@rolldown/binding-freebsd-x64@1.0.0-beta.35': + optional: true + + '@rolldown/binding-linux-arm-gnueabihf@1.0.0-beta.35': + optional: true + + '@rolldown/binding-linux-arm64-gnu@1.0.0-beta.35': + optional: true + + '@rolldown/binding-linux-arm64-musl@1.0.0-beta.35': + optional: true + + '@rolldown/binding-linux-x64-gnu@1.0.0-beta.35': + optional: true + + '@rolldown/binding-linux-x64-musl@1.0.0-beta.35': + optional: true + + '@rolldown/binding-openharmony-arm64@1.0.0-beta.35': + optional: true + + '@rolldown/binding-wasm32-wasi@1.0.0-beta.35': dependencies: - '@ganache/utils': 0.1.4 - bip39: 3.0.4 - seedrandom: 3.0.5 + '@napi-rs/wasm-runtime': 1.1.1 + optional: true + + '@rolldown/binding-win32-arm64-msvc@1.0.0-beta.35': + optional: true + + '@rolldown/binding-win32-ia32-msvc@1.0.0-beta.35': + optional: true - '@ganache/rlp@0.1.4': - dependencies: - '@ganache/utils': 0.1.4 - rlp: 2.2.6 + '@rolldown/binding-win32-x64-msvc@1.0.0-beta.35': + optional: true - '@ganache/utils@0.1.4': - dependencies: - emittery: 0.10.0 - keccak: 3.0.1 - seedrandom: 3.0.5 - optionalDependencies: - '@trufflesuite/bigint-buffer': 1.1.9 + '@rolldown/pluginutils@1.0.0-beta.35': {} - '@graphql-tools/merge@8.3.1(graphql@15.10.2)': - dependencies: - '@graphql-tools/utils': 8.9.0(graphql@15.10.2) - graphql: 15.10.2 - tslib: 2.8.1 + '@rolldown/pluginutils@1.0.0-beta.53': {} - '@graphql-tools/schema@8.5.1(graphql@15.10.2)': - dependencies: - '@graphql-tools/merge': 8.3.1(graphql@15.10.2) - '@graphql-tools/utils': 8.9.0(graphql@15.10.2) - graphql: 15.10.2 - tslib: 2.8.1 - value-or-promise: 1.0.11 + '@rolldown/pluginutils@1.0.0-beta.57': {} - '@graphql-tools/utils@8.13.1(graphql@15.10.2)': - dependencies: - graphql: 15.10.2 - tslib: 2.8.1 + '@rollup/plugin-alias@5.1.1(rollup@4.54.0)': + optionalDependencies: + rollup: 4.54.0 - '@graphql-tools/utils@8.9.0(graphql@15.10.2)': + '@rollup/plugin-commonjs@28.0.9(rollup@4.54.0)': dependencies: - graphql: 15.10.2 - tslib: 2.8.1 + '@rollup/pluginutils': 5.3.0(rollup@4.54.0) + commondir: 1.0.1 + estree-walker: 2.0.2 + fdir: 6.5.0(picomatch@4.0.3) + is-reference: 1.2.1 + magic-string: 0.30.21 + picomatch: 4.0.3 + optionalDependencies: + rollup: 4.54.0 - '@httptoolkit/httpolyglot@2.2.2': + '@rollup/plugin-inject@5.0.5(rollup@4.54.0)': dependencies: - '@types/node': 25.6.0 + '@rollup/pluginutils': 5.3.0(rollup@4.54.0) + estree-walker: 2.0.2 + magic-string: 0.30.21 + optionalDependencies: + rollup: 4.54.0 - '@httptoolkit/subscriptions-transport-ws@0.11.2(bufferutil@4.1.0)(graphql@15.10.2)(utf-8-validate@5.0.10)': + '@rollup/plugin-json@6.1.0(rollup@4.54.0)': dependencies: - backo2: 1.0.2 - eventemitter3: 3.1.2 - graphql: 15.10.2 - iterall: 1.3.0 - symbol-observable: 1.2.0 - ws: 8.20.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - transitivePeerDependencies: - - bufferutil - - utf-8-validate + '@rollup/pluginutils': 5.3.0(rollup@4.54.0) + optionalDependencies: + rollup: 4.54.0 - '@httptoolkit/websocket-stream@6.0.1(bufferutil@4.1.0)(utf-8-validate@5.0.10)': + '@rollup/plugin-node-resolve@16.0.3(rollup@4.54.0)': dependencies: - '@types/ws': 8.18.1 - duplexify: 3.7.1 - inherits: 2.0.4 - isomorphic-ws: 4.0.1(ws@8.20.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - readable-stream: 2.3.8 - safe-buffer: 5.2.1 - ws: 8.20.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - xtend: 4.0.2 - transitivePeerDependencies: - - bufferutil - - utf-8-validate - - '@humanfs/core@0.19.1': {} + '@rollup/pluginutils': 5.3.0(rollup@4.54.0) + '@types/resolve': 1.20.2 + deepmerge: 4.3.1 + is-module: 1.0.0 + resolve: 1.22.11 + optionalDependencies: + rollup: 4.54.0 - '@humanfs/core@0.19.2': + '@rollup/plugin-replace@6.0.3(rollup@4.54.0)': dependencies: - '@humanfs/types': 0.15.0 + '@rollup/pluginutils': 5.3.0(rollup@4.54.0) + magic-string: 0.30.21 + optionalDependencies: + rollup: 4.54.0 - '@humanfs/node@0.16.7': + '@rollup/plugin-terser@0.4.4(rollup@4.54.0)': dependencies: - '@humanfs/core': 0.19.1 - '@humanwhocodes/retry': 0.4.3 + serialize-javascript: 6.0.2 + smob: 1.5.0 + terser: 5.44.1 + optionalDependencies: + rollup: 4.54.0 - '@humanfs/node@0.16.8': + '@rollup/pluginutils@5.1.0(rollup@4.54.0)': dependencies: - '@humanfs/core': 0.19.2 - '@humanfs/types': 0.15.0 - '@humanwhocodes/retry': 0.4.3 - - '@humanfs/types@0.15.0': {} - - '@humanwhocodes/module-importer@1.0.1': {} - - '@humanwhocodes/retry@0.4.3': {} - - '@img/colour@1.1.0': - optional: true - - '@img/sharp-darwin-arm64@0.34.5': + '@types/estree': 1.0.5 + estree-walker: 2.0.2 + picomatch: 2.3.1 optionalDependencies: - '@img/sharp-libvips-darwin-arm64': 1.2.4 - optional: true + rollup: 4.54.0 - '@img/sharp-darwin-x64@0.34.5': + '@rollup/pluginutils@5.3.0(rollup@4.54.0)': + dependencies: + '@types/estree': 1.0.8 + estree-walker: 2.0.2 + picomatch: 4.0.3 optionalDependencies: - '@img/sharp-libvips-darwin-x64': 1.2.4 - optional: true + rollup: 4.54.0 - '@img/sharp-libvips-darwin-arm64@1.2.4': + '@rollup/rollup-android-arm-eabi@4.54.0': optional: true - '@img/sharp-libvips-darwin-x64@1.2.4': + '@rollup/rollup-android-arm64@4.54.0': optional: true - '@img/sharp-libvips-linux-arm64@1.2.4': + '@rollup/rollup-darwin-arm64@4.54.0': optional: true - '@img/sharp-libvips-linux-arm@1.2.4': + '@rollup/rollup-darwin-x64@4.54.0': optional: true - '@img/sharp-libvips-linux-ppc64@1.2.4': + '@rollup/rollup-freebsd-arm64@4.54.0': optional: true - '@img/sharp-libvips-linux-riscv64@1.2.4': + '@rollup/rollup-freebsd-x64@4.54.0': optional: true - '@img/sharp-libvips-linux-s390x@1.2.4': + '@rollup/rollup-linux-arm-gnueabihf@4.54.0': optional: true - '@img/sharp-libvips-linux-x64@1.2.4': + '@rollup/rollup-linux-arm-musleabihf@4.54.0': optional: true - '@img/sharp-libvips-linuxmusl-arm64@1.2.4': + '@rollup/rollup-linux-arm64-gnu@4.54.0': optional: true - '@img/sharp-libvips-linuxmusl-x64@1.2.4': + '@rollup/rollup-linux-arm64-musl@4.54.0': optional: true - '@img/sharp-linux-arm64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linux-arm64': 1.2.4 + '@rollup/rollup-linux-loong64-gnu@4.54.0': optional: true - '@img/sharp-linux-arm@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linux-arm': 1.2.4 + '@rollup/rollup-linux-ppc64-gnu@4.54.0': optional: true - '@img/sharp-linux-ppc64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linux-ppc64': 1.2.4 + '@rollup/rollup-linux-riscv64-gnu@4.54.0': optional: true - '@img/sharp-linux-riscv64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linux-riscv64': 1.2.4 + '@rollup/rollup-linux-riscv64-musl@4.54.0': optional: true - '@img/sharp-linux-s390x@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linux-s390x': 1.2.4 + '@rollup/rollup-linux-s390x-gnu@4.54.0': optional: true - '@img/sharp-linux-x64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linux-x64': 1.2.4 + '@rollup/rollup-linux-x64-gnu@4.54.0': optional: true - '@img/sharp-linuxmusl-arm64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linuxmusl-arm64': 1.2.4 + '@rollup/rollup-linux-x64-musl@4.54.0': optional: true - '@img/sharp-linuxmusl-x64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linuxmusl-x64': 1.2.4 + '@rollup/rollup-openharmony-arm64@4.54.0': optional: true - '@img/sharp-wasm32@0.34.5': - dependencies: - '@emnapi/runtime': 1.10.0 + '@rollup/rollup-win32-arm64-msvc@4.54.0': optional: true - '@img/sharp-win32-arm64@0.34.5': + '@rollup/rollup-win32-ia32-msvc@4.54.0': optional: true - '@img/sharp-win32-ia32@0.34.5': + '@rollup/rollup-win32-x64-gnu@4.54.0': optional: true - '@img/sharp-win32-x64@0.34.5': + '@rollup/rollup-win32-x64-msvc@4.54.0': optional: true - '@inquirer/external-editor@1.0.3(@types/node@25.3.0)': - dependencies: - chardet: 2.1.1 - iconv-lite: 0.7.2 - optionalDependencies: - '@types/node': 25.3.0 - - '@inquirer/external-editor@1.0.3(@types/node@25.6.0)': + '@safe-global/safe-apps-provider@0.18.6(bufferutil@4.1.0)(encoding@0.1.13)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': dependencies: - chardet: 2.1.1 - iconv-lite: 0.7.2 - optionalDependencies: - '@types/node': 25.6.0 + '@safe-global/safe-apps-sdk': 9.1.0(bufferutil@4.1.0)(encoding@0.1.13)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + events: 3.3.0 + transitivePeerDependencies: + - bufferutil + - encoding + - typescript + - utf-8-validate + - zod - '@isaacs/cliui@8.0.2': + '@safe-global/safe-apps-sdk@9.1.0(bufferutil@4.1.0)(encoding@0.1.13)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': dependencies: - string-width: 5.1.2 - string-width-cjs: string-width@4.2.3 - strip-ansi: 7.2.0 - strip-ansi-cjs: strip-ansi@6.0.1 - wrap-ansi: 8.1.0 - wrap-ansi-cjs: wrap-ansi@7.0.0 + '@safe-global/safe-gateway-typescript-sdk': 3.8.0(encoding@0.1.13) + viem: 2.17.0(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + transitivePeerDependencies: + - bufferutil + - encoding + - typescript + - utf-8-validate + - zod - '@isaacs/fs-minipass@4.0.1': + '@safe-global/safe-gateway-typescript-sdk@3.8.0(encoding@0.1.13)': dependencies: - minipass: 7.1.3 + cross-fetch: 3.2.0(encoding@0.1.13) + transitivePeerDependencies: + - encoding - '@istanbuljs/load-nyc-config@1.1.0': - dependencies: - camelcase: 5.3.1 - find-up: 4.1.0 - get-package-type: 0.1.0 - js-yaml: 3.14.2 - resolve-from: 5.0.0 + '@scure/base@1.1.3': {} - '@istanbuljs/nyc-config-typescript@1.0.2(nyc@15.1.0)': - dependencies: - '@istanbuljs/schema': 0.1.6 - nyc: 15.1.0 + '@scure/base@1.1.9': {} - '@istanbuljs/schema@0.1.6': {} + '@scure/base@1.2.6': {} - '@jridgewell/gen-mapping@0.3.13': + '@scure/bip32@1.1.5': dependencies: - '@jridgewell/sourcemap-codec': 1.5.5 - '@jridgewell/trace-mapping': 0.3.31 + '@noble/hashes': 1.2.0 + '@noble/secp256k1': 1.7.1 + '@scure/base': 1.1.9 - '@jridgewell/remapping@2.3.5': + '@scure/bip32@1.3.2': dependencies: - '@jridgewell/gen-mapping': 0.3.13 - '@jridgewell/trace-mapping': 0.3.31 - - '@jridgewell/resolve-uri@3.1.2': {} - - '@jridgewell/sourcemap-codec@1.5.5': {} + '@noble/curves': 1.2.0 + '@noble/hashes': 1.3.2 + '@scure/base': 1.1.3 - '@jridgewell/trace-mapping@0.3.31': + '@scure/bip32@1.4.0': dependencies: - '@jridgewell/resolve-uri': 3.1.2 - '@jridgewell/sourcemap-codec': 1.5.5 + '@noble/curves': 1.4.0 + '@noble/hashes': 1.4.0 + '@scure/base': 1.1.9 - '@jridgewell/trace-mapping@0.3.9': + '@scure/bip32@1.6.2': dependencies: - '@jridgewell/resolve-uri': 3.1.2 - '@jridgewell/sourcemap-codec': 1.5.5 + '@noble/curves': 1.8.1 + '@noble/hashes': 1.7.1 + '@scure/base': 1.2.6 - '@manypkg/find-root@1.1.0': + '@scure/bip32@1.7.0': dependencies: - '@babel/runtime': 7.29.2 - '@types/node': 12.20.55 - find-up: 4.1.0 - fs-extra: 8.1.0 + '@noble/curves': 1.9.2 + '@noble/hashes': 1.8.0 + '@scure/base': 1.2.6 - '@manypkg/get-packages@1.1.3': + '@scure/bip39@1.1.1': dependencies: - '@babel/runtime': 7.29.2 - '@changesets/types': 4.1.0 - '@manypkg/find-root': 1.1.0 - fs-extra: 8.1.0 - globby: 11.1.0 - read-yaml-file: 1.1.0 + '@noble/hashes': 1.2.0 + '@scure/base': 1.1.9 - '@metamask/eth-json-rpc-infura@6.0.0(encoding@0.1.13)': + '@scure/bip39@1.2.1': dependencies: - eth-json-rpc-middleware: 8.1.0(encoding@0.1.13) - eth-rpc-errors: 4.0.3 - json-rpc-engine: 6.1.0 - node-fetch: 2.7.0(encoding@0.1.13) - transitivePeerDependencies: - - encoding + '@noble/hashes': 1.3.2 + '@scure/base': 1.1.3 - '@metamask/eth-sig-util@4.0.1': + '@scure/bip39@1.3.0': dependencies: - ethereumjs-abi: 0.6.8 - ethereumjs-util: 6.2.1 - ethjs-util: 0.1.6 - tweetnacl: 1.0.3 - tweetnacl-util: 0.15.1 + '@noble/hashes': 1.4.0 + '@scure/base': 1.1.9 - '@metamask/eth-sig-util@5.1.0': + '@scure/bip39@1.5.4': dependencies: - '@ethereumjs/util': 8.1.0 - bn.js: 5.2.3 - ethereum-cryptography: 2.2.1 - ethjs-util: 0.1.6 - tweetnacl: 1.0.3 - tweetnacl-util: 0.15.1 - - '@metamask/safe-event-emitter@2.0.0': {} + '@noble/hashes': 1.7.1 + '@scure/base': 1.2.6 - '@metamask/utils@3.6.0': + '@scure/bip39@1.6.0': dependencies: - '@types/debug': 4.1.13 - debug: 4.4.3(supports-color@5.5.0) - semver: 7.7.4 - superstruct: 1.0.4 - transitivePeerDependencies: - - supports-color + '@noble/hashes': 1.8.0 + '@scure/base': 1.2.6 - '@next/env@16.2.4': {} + '@sec-ant/readable-stream@0.4.1': {} - '@next/eslint-plugin-next@15.5.9': + '@sentry/core@5.30.0': dependencies: - fast-glob: 3.3.1 - - '@next/swc-darwin-arm64@16.2.4': - optional: true - - '@next/swc-darwin-x64@16.2.4': - optional: true - - '@next/swc-linux-arm64-gnu@16.2.4': - optional: true - - '@next/swc-linux-arm64-musl@16.2.4': - optional: true - - '@next/swc-linux-x64-gnu@16.2.4': - optional: true - - '@next/swc-linux-x64-musl@16.2.4': - optional: true - - '@next/swc-win32-arm64-msvc@16.2.4': - optional: true - - '@next/swc-win32-x64-msvc@16.2.4': - optional: true - - '@noble/ciphers@1.3.0': {} + '@sentry/hub': 5.30.0 + '@sentry/minimal': 5.30.0 + '@sentry/types': 5.30.0 + '@sentry/utils': 5.30.0 + tslib: 1.14.1 - '@noble/curves@1.2.0': + '@sentry/hub@5.30.0': dependencies: - '@noble/hashes': 1.3.2 + '@sentry/types': 5.30.0 + '@sentry/utils': 5.30.0 + tslib: 1.14.1 - '@noble/curves@1.4.2': + '@sentry/minimal@5.30.0': dependencies: - '@noble/hashes': 1.4.0 + '@sentry/hub': 5.30.0 + '@sentry/types': 5.30.0 + tslib: 1.14.1 - '@noble/curves@1.8.2': + '@sentry/node@5.30.0': dependencies: - '@noble/hashes': 1.7.2 + '@sentry/core': 5.30.0 + '@sentry/hub': 5.30.0 + '@sentry/tracing': 5.30.0 + '@sentry/types': 5.30.0 + '@sentry/utils': 5.30.0 + cookie: 0.4.2 + https-proxy-agent: 5.0.1 + lru_map: 0.3.3 + tslib: 1.14.1 + transitivePeerDependencies: + - supports-color - '@noble/curves@1.9.1': + '@sentry/tracing@5.30.0': dependencies: - '@noble/hashes': 1.8.0 - - '@noble/hashes@1.2.0': {} - - '@noble/hashes@1.3.2': {} - - '@noble/hashes@1.4.0': {} + '@sentry/hub': 5.30.0 + '@sentry/minimal': 5.30.0 + '@sentry/types': 5.30.0 + '@sentry/utils': 5.30.0 + tslib: 1.14.1 - '@noble/hashes@1.7.2': {} + '@sentry/types@5.30.0': {} - '@noble/hashes@1.8.0': {} + '@sentry/utils@5.30.0': + dependencies: + '@sentry/types': 5.30.0 + tslib: 1.14.1 - '@noble/secp256k1@1.7.1': {} + '@shikijs/core@1.22.2': + dependencies: + '@shikijs/engine-javascript': 1.22.2 + '@shikijs/engine-oniguruma': 1.22.2 + '@shikijs/types': 1.22.2 + '@shikijs/vscode-textmate': 9.3.0 + '@types/hast': 3.0.4 + hast-util-to-html: 9.0.3 - '@nodable/entities@2.1.0': {} + '@shikijs/engine-javascript@1.22.2': + dependencies: + '@shikijs/types': 1.22.2 + '@shikijs/vscode-textmate': 9.3.0 + oniguruma-to-js: 0.4.3 - '@nodelib/fs.scandir@2.1.5': + '@shikijs/engine-oniguruma@1.22.2': dependencies: - '@nodelib/fs.stat': 2.0.5 - run-parallel: 1.2.0 + '@shikijs/types': 1.22.2 + '@shikijs/vscode-textmate': 9.3.0 - '@nodelib/fs.stat@2.0.5': {} + '@shikijs/transformers@1.22.2': + dependencies: + shiki: 1.22.2 - '@nodelib/fs.walk@1.2.8': + '@shikijs/twoslash@1.22.2(typescript@5.9.3)': dependencies: - '@nodelib/fs.scandir': 2.1.5 - fastq: 1.19.1 + '@shikijs/core': 1.22.2 + '@shikijs/types': 1.22.2 + twoslash: 0.2.12(typescript@5.9.3) + transitivePeerDependencies: + - supports-color + - typescript - '@nomicfoundation/edr-darwin-arm64@0.12.0-next.23': {} + '@shikijs/types@1.22.2': + dependencies: + '@shikijs/vscode-textmate': 9.3.0 + '@types/hast': 3.0.4 - '@nomicfoundation/edr-darwin-x64@0.12.0-next.23': {} + '@shikijs/vitepress-twoslash@1.22.2(@nuxt/kit@3.20.2(magicast@0.5.1))(typescript@5.9.3)': + dependencies: + '@shikijs/twoslash': 1.22.2(typescript@5.9.3) + floating-vue: 5.2.2(@nuxt/kit@3.20.2(magicast@0.5.1))(vue@3.5.12(typescript@5.9.3)) + mdast-util-from-markdown: 2.0.2 + mdast-util-gfm: 3.0.0 + mdast-util-to-hast: 13.2.0 + shiki: 1.22.2 + twoslash: 0.2.12(typescript@5.9.3) + twoslash-vue: 0.2.12(typescript@5.9.3) + vue: 3.5.12(typescript@5.9.3) + transitivePeerDependencies: + - '@nuxt/kit' + - supports-color + - typescript - '@nomicfoundation/edr-linux-arm64-gnu@0.12.0-next.23': {} + '@shikijs/vscode-textmate@9.3.0': {} - '@nomicfoundation/edr-linux-arm64-musl@0.12.0-next.23': {} + '@sinclair/typebox@0.25.24': {} - '@nomicfoundation/edr-linux-x64-gnu@0.12.0-next.23': {} + '@sindresorhus/is@4.6.0': {} - '@nomicfoundation/edr-linux-x64-musl@0.12.0-next.23': {} + '@sindresorhus/is@7.1.1': {} - '@nomicfoundation/edr-win32-x64-msvc@0.12.0-next.23': {} + '@sindresorhus/merge-streams@4.0.0': {} - '@nomicfoundation/edr@0.12.0-next.23': + '@smithy/abort-controller@4.2.7': dependencies: - '@nomicfoundation/edr-darwin-arm64': 0.12.0-next.23 - '@nomicfoundation/edr-darwin-x64': 0.12.0-next.23 - '@nomicfoundation/edr-linux-arm64-gnu': 0.12.0-next.23 - '@nomicfoundation/edr-linux-arm64-musl': 0.12.0-next.23 - '@nomicfoundation/edr-linux-x64-gnu': 0.12.0-next.23 - '@nomicfoundation/edr-linux-x64-musl': 0.12.0-next.23 - '@nomicfoundation/edr-win32-x64-msvc': 0.12.0-next.23 + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@nomicfoundation/hardhat-errors@3.0.11': + '@smithy/config-resolver@4.4.5': dependencies: - '@nomicfoundation/hardhat-utils': 4.0.4 - transitivePeerDependencies: - - supports-color + '@smithy/node-config-provider': 4.3.7 + '@smithy/types': 4.11.0 + '@smithy/util-config-provider': 4.2.0 + '@smithy/util-endpoints': 3.2.7 + '@smithy/util-middleware': 4.2.7 + tslib: 2.8.1 + + '@smithy/core@3.20.0': + dependencies: + '@smithy/middleware-serde': 4.2.8 + '@smithy/protocol-http': 5.3.7 + '@smithy/types': 4.11.0 + '@smithy/util-base64': 4.3.0 + '@smithy/util-body-length-browser': 4.2.0 + '@smithy/util-middleware': 4.2.7 + '@smithy/util-stream': 4.5.8 + '@smithy/util-utf8': 4.2.0 + '@smithy/uuid': 1.1.0 + tslib: 2.8.1 - '@nomicfoundation/hardhat-ethers@3.1.3(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))': + '@smithy/credential-provider-imds@4.2.7': dependencies: - debug: 4.4.3(supports-color@5.5.0) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - hardhat: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10) - lodash.isequal: 4.5.0 - transitivePeerDependencies: - - supports-color + '@smithy/node-config-provider': 4.3.7 + '@smithy/property-provider': 4.2.7 + '@smithy/types': 4.11.0 + '@smithy/url-parser': 4.2.7 + tslib: 2.8.1 - '@nomicfoundation/hardhat-ethers@4.0.9(bufferutil@4.1.0)(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10)': + '@smithy/fetch-http-handler@5.3.8': dependencies: - '@nomicfoundation/hardhat-errors': 3.0.11 - '@nomicfoundation/hardhat-utils': 4.0.4 - debug: 4.4.3(supports-color@5.5.0) - ethereum-cryptography: 2.2.1 - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - hardhat: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10) - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate + '@smithy/protocol-http': 5.3.7 + '@smithy/querystring-builder': 4.2.7 + '@smithy/types': 4.11.0 + '@smithy/util-base64': 4.3.0 + tslib: 2.8.1 - '@nomicfoundation/hardhat-ignition@0.15.16(@nomicfoundation/hardhat-verify@2.1.3(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)))(bufferutil@4.1.0)(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10)': + '@smithy/hash-node@4.2.7': dependencies: - '@nomicfoundation/hardhat-verify': 2.1.3(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)) - '@nomicfoundation/ignition-core': 0.15.15(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@nomicfoundation/ignition-ui': 0.15.13 - chalk: 4.1.2 - debug: 4.4.3(supports-color@5.5.0) - fs-extra: 10.1.0 - hardhat: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10) - json5: 2.2.3 - prompts: 2.4.2 - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate + '@smithy/types': 4.11.0 + '@smithy/util-buffer-from': 4.2.0 + '@smithy/util-utf8': 4.2.0 + tslib: 2.8.1 - '@nomicfoundation/hardhat-utils@4.0.4': + '@smithy/invalid-dependency@4.2.7': dependencies: - '@streamparser/json-node': 0.0.22 - debug: 4.4.3(supports-color@5.5.0) - env-paths: 2.2.1 - ethereum-cryptography: 2.2.1 - fast-equals: 5.4.0 - json-stream-stringify: 3.1.6 - rfdc: 1.4.1 - undici: 8.1.0 - transitivePeerDependencies: - - supports-color + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@nomicfoundation/hardhat-verify@2.1.3(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))': + '@smithy/is-array-buffer@2.2.0': dependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/address': 5.8.0 - cbor: 8.1.0 - debug: 4.4.3(supports-color@5.5.0) - hardhat: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10) - lodash.clonedeep: 4.5.0 - picocolors: 1.1.1 - semver: 6.3.1 - table: 6.9.0 - undici: 8.1.0 - transitivePeerDependencies: - - supports-color + tslib: 2.8.1 - '@nomicfoundation/hardhat-verify@3.0.15(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))': - dependencies: - '@ethersproject/abi': 5.8.0 - '@nomicfoundation/hardhat-errors': 3.0.11 - '@nomicfoundation/hardhat-utils': 4.0.4 - '@nomicfoundation/hardhat-zod-utils': 3.0.4(zod@3.25.76) - cbor2: 1.12.0 - chalk: 5.6.2 - debug: 4.4.3(supports-color@5.5.0) - hardhat: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10) - semver: 7.7.4 - zod: 3.25.76 - transitivePeerDependencies: - - supports-color + '@smithy/is-array-buffer@4.2.0': + dependencies: + tslib: 2.8.1 - '@nomicfoundation/hardhat-zod-utils@3.0.4(zod@3.25.76)': + '@smithy/middleware-content-length@4.2.7': dependencies: - '@nomicfoundation/hardhat-errors': 3.0.11 - '@nomicfoundation/hardhat-utils': 4.0.4 - zod: 3.25.76 - transitivePeerDependencies: - - supports-color + '@smithy/protocol-http': 5.3.7 + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@nomicfoundation/ignition-core@0.15.15(bufferutil@4.1.0)(utf-8-validate@5.0.10)': - dependencies: - '@ethersproject/address': 5.6.1 - '@nomicfoundation/solidity-analyzer': 0.1.2 - cbor: 9.0.2 - debug: 4.4.3(supports-color@5.5.0) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - fs-extra: 10.1.0 - immer: 10.0.2 - lodash: 4.18.1 - ndjson: 2.0.0 - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate + '@smithy/middleware-endpoint@4.4.1': + dependencies: + '@smithy/core': 3.20.0 + '@smithy/middleware-serde': 4.2.8 + '@smithy/node-config-provider': 4.3.7 + '@smithy/shared-ini-file-loader': 4.4.2 + '@smithy/types': 4.11.0 + '@smithy/url-parser': 4.2.7 + '@smithy/util-middleware': 4.2.7 + tslib: 2.8.1 - '@nomicfoundation/ignition-ui@0.15.13': {} + '@smithy/middleware-retry@4.4.17': + dependencies: + '@smithy/node-config-provider': 4.3.7 + '@smithy/protocol-http': 5.3.7 + '@smithy/service-error-classification': 4.2.7 + '@smithy/smithy-client': 4.10.2 + '@smithy/types': 4.11.0 + '@smithy/util-middleware': 4.2.7 + '@smithy/util-retry': 4.2.7 + '@smithy/uuid': 1.1.0 + tslib: 2.8.1 - '@nomicfoundation/slang@0.18.3': + '@smithy/middleware-serde@4.2.8': dependencies: - '@bytecodealliance/preview2-shim': 0.17.0 + '@smithy/protocol-http': 5.3.7 + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@nomicfoundation/solidity-analyzer-darwin-arm64@0.1.2': - optional: true + '@smithy/middleware-stack@4.2.7': + dependencies: + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@nomicfoundation/solidity-analyzer-darwin-x64@0.1.2': - optional: true + '@smithy/node-config-provider@4.3.7': + dependencies: + '@smithy/property-provider': 4.2.7 + '@smithy/shared-ini-file-loader': 4.4.2 + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@nomicfoundation/solidity-analyzer-linux-arm64-gnu@0.1.2': - optional: true + '@smithy/node-http-handler@4.4.7': + dependencies: + '@smithy/abort-controller': 4.2.7 + '@smithy/protocol-http': 5.3.7 + '@smithy/querystring-builder': 4.2.7 + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@nomicfoundation/solidity-analyzer-linux-arm64-musl@0.1.2': - optional: true + '@smithy/property-provider@4.2.7': + dependencies: + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@nomicfoundation/solidity-analyzer-linux-x64-gnu@0.1.2': - optional: true + '@smithy/protocol-http@5.3.7': + dependencies: + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@nomicfoundation/solidity-analyzer-linux-x64-musl@0.1.2': - optional: true + '@smithy/querystring-builder@4.2.7': + dependencies: + '@smithy/types': 4.11.0 + '@smithy/util-uri-escape': 4.2.0 + tslib: 2.8.1 - '@nomicfoundation/solidity-analyzer-win32-x64-msvc@0.1.2': - optional: true + '@smithy/querystring-parser@4.2.7': + dependencies: + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@nomicfoundation/solidity-analyzer@0.1.2': - optionalDependencies: - '@nomicfoundation/solidity-analyzer-darwin-arm64': 0.1.2 - '@nomicfoundation/solidity-analyzer-darwin-x64': 0.1.2 - '@nomicfoundation/solidity-analyzer-linux-arm64-gnu': 0.1.2 - '@nomicfoundation/solidity-analyzer-linux-arm64-musl': 0.1.2 - '@nomicfoundation/solidity-analyzer-linux-x64-gnu': 0.1.2 - '@nomicfoundation/solidity-analyzer-linux-x64-musl': 0.1.2 - '@nomicfoundation/solidity-analyzer-win32-x64-msvc': 0.1.2 + '@smithy/service-error-classification@4.2.7': + dependencies: + '@smithy/types': 4.11.0 - '@nomiclabs/hardhat-ethers@2.2.3(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@5.0.10))': + '@smithy/shared-ini-file-loader@4.4.2': dependencies: - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - hardhat: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@5.0.10) + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@nomiclabs/hardhat-truffle5@3.0.0': {} + '@smithy/signature-v4@5.3.7': + dependencies: + '@smithy/is-array-buffer': 4.2.0 + '@smithy/protocol-http': 5.3.7 + '@smithy/types': 4.11.0 + '@smithy/util-hex-encoding': 4.2.0 + '@smithy/util-middleware': 4.2.7 + '@smithy/util-uri-escape': 4.2.0 + '@smithy/util-utf8': 4.2.0 + tslib: 2.8.1 - '@nomiclabs/hardhat-web3@2.1.2(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))(web3@1.10.4(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@5.0.10))': + '@smithy/smithy-client@4.10.2': dependencies: - hardhat: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10) - web3: 1.10.4(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@5.0.10) + '@smithy/core': 3.20.0 + '@smithy/middleware-endpoint': 4.4.1 + '@smithy/middleware-stack': 4.2.7 + '@smithy/protocol-http': 5.3.7 + '@smithy/types': 4.11.0 + '@smithy/util-stream': 4.5.8 + tslib: 2.8.1 - '@nomiclabs/hardhat-web3@2.1.2(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@5.0.10))(web3@1.10.4(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@5.0.10))': + '@smithy/types@4.11.0': dependencies: - hardhat: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@5.0.10) - web3: 1.10.4(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@5.0.10) + tslib: 2.8.1 - '@npmcli/agent@2.2.2': + '@smithy/url-parser@4.2.7': dependencies: - agent-base: 7.1.4 - http-proxy-agent: 7.0.2 - https-proxy-agent: 7.0.6 - lru-cache: 10.4.3 - socks-proxy-agent: 8.0.5 - transitivePeerDependencies: - - supports-color + '@smithy/querystring-parser': 4.2.7 + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@npmcli/fs@3.1.1': + '@smithy/util-base64@4.3.0': dependencies: - semver: 7.7.4 + '@smithy/util-buffer-from': 4.2.0 + '@smithy/util-utf8': 4.2.0 + tslib: 2.8.1 - '@npmcli/redact@2.0.1': {} + '@smithy/util-body-length-browser@4.2.0': + dependencies: + tslib: 2.8.1 - '@openzeppelin/defender-sdk-base-client@2.7.1(debug@4.4.3)': + '@smithy/util-body-length-node@4.2.1': dependencies: - '@aws-sdk/client-lambda': 3.1037.0 - amazon-cognito-identity-js: 6.3.16 - async-retry: 1.3.3 - axios: 1.15.2(debug@4.4.3) - transitivePeerDependencies: - - aws-crt - - debug + tslib: 2.8.1 - '@openzeppelin/defender-sdk-deploy-client@2.7.1(debug@4.4.3)': + '@smithy/util-buffer-from@2.2.0': dependencies: - '@openzeppelin/defender-sdk-base-client': 2.7.1(debug@4.4.3) - axios: 1.15.2(debug@4.4.3) - lodash: 4.18.1 - transitivePeerDependencies: - - aws-crt - - debug + '@smithy/is-array-buffer': 2.2.0 + tslib: 2.8.1 - '@openzeppelin/defender-sdk-network-client@2.7.1(debug@4.4.3)': + '@smithy/util-buffer-from@4.2.0': dependencies: - '@openzeppelin/defender-sdk-base-client': 2.7.1(debug@4.4.3) - axios: 1.15.2(debug@4.4.3) - lodash: 4.18.1 - transitivePeerDependencies: - - aws-crt - - debug + '@smithy/is-array-buffer': 4.2.0 + tslib: 2.8.1 - '@openzeppelin/hardhat-upgrades@3.9.1(@nomicfoundation/hardhat-ethers@3.1.3(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)))(@nomicfoundation/hardhat-verify@2.1.3(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)))(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))': + '@smithy/util-config-provider@4.2.0': dependencies: - '@nomicfoundation/hardhat-ethers': 3.1.3(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)) - '@openzeppelin/defender-sdk-base-client': 2.7.1(debug@4.4.3) - '@openzeppelin/defender-sdk-deploy-client': 2.7.1(debug@4.4.3) - '@openzeppelin/defender-sdk-network-client': 2.7.1(debug@4.4.3) - '@openzeppelin/upgrades-core': 1.44.2 - chalk: 4.1.2 - debug: 4.4.3(supports-color@5.5.0) - ethereumjs-util: 7.1.5 - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - hardhat: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10) - proper-lockfile: 4.1.2 - undici: 8.1.0 - optionalDependencies: - '@nomicfoundation/hardhat-verify': 2.1.3(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)) - transitivePeerDependencies: - - aws-crt - - supports-color + tslib: 2.8.1 - '@openzeppelin/upgrades-core@1.44.2': + '@smithy/util-defaults-mode-browser@4.3.16': dependencies: - '@nomicfoundation/slang': 0.18.3 - bignumber.js: 9.3.1 - cbor: 10.0.12 - chalk: 4.1.2 - compare-versions: 6.1.1 - debug: 4.4.3(supports-color@5.5.0) - ethereumjs-util: 7.1.5 - minimatch: 10.2.5 - minimist: 1.2.8 - proper-lockfile: 4.1.2 - solidity-ast: 0.4.62 - transitivePeerDependencies: - - supports-color + '@smithy/property-provider': 4.2.7 + '@smithy/smithy-client': 4.10.2 + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@pkgjs/parseargs@0.11.0': - optional: true + '@smithy/util-defaults-mode-node@4.2.19': + dependencies: + '@smithy/config-resolver': 4.4.5 + '@smithy/credential-provider-imds': 4.2.7 + '@smithy/node-config-provider': 4.3.7 + '@smithy/property-provider': 4.2.7 + '@smithy/smithy-client': 4.10.2 + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@resolver-engine/core@0.3.3': + '@smithy/util-endpoints@3.2.7': dependencies: - debug: 4.4.3(supports-color@5.5.0) - is-url: 1.2.4 - request: 2.88.2 - transitivePeerDependencies: - - supports-color + '@smithy/node-config-provider': 4.3.7 + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@resolver-engine/fs@0.3.3': + '@smithy/util-hex-encoding@4.2.0': dependencies: - '@resolver-engine/core': 0.3.3 - debug: 4.4.3(supports-color@5.5.0) - transitivePeerDependencies: - - supports-color + tslib: 2.8.1 - '@resolver-engine/imports-fs@0.3.3': + '@smithy/util-middleware@4.2.7': dependencies: - '@resolver-engine/fs': 0.3.3 - '@resolver-engine/imports': 0.3.3 - debug: 4.4.3(supports-color@5.5.0) - transitivePeerDependencies: - - supports-color + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@resolver-engine/imports@0.3.3': + '@smithy/util-retry@4.2.7': dependencies: - '@resolver-engine/core': 0.3.3 - debug: 4.4.3(supports-color@5.5.0) - hosted-git-info: 2.8.9 - path-browserify: 1.0.1 - url: 0.11.4 - transitivePeerDependencies: - - supports-color + '@smithy/service-error-classification': 4.2.7 + '@smithy/types': 4.11.0 + tslib: 2.8.1 - '@rollup/rollup-android-arm-eabi@4.60.2': - optional: true + '@smithy/util-stream@4.5.8': + dependencies: + '@smithy/fetch-http-handler': 5.3.8 + '@smithy/node-http-handler': 4.4.7 + '@smithy/types': 4.11.0 + '@smithy/util-base64': 4.3.0 + '@smithy/util-buffer-from': 4.2.0 + '@smithy/util-hex-encoding': 4.2.0 + '@smithy/util-utf8': 4.2.0 + tslib: 2.8.1 - '@rollup/rollup-android-arm64@4.60.2': - optional: true + '@smithy/util-uri-escape@4.2.0': + dependencies: + tslib: 2.8.1 - '@rollup/rollup-darwin-arm64@4.60.2': - optional: true + '@smithy/util-utf8@2.3.0': + dependencies: + '@smithy/util-buffer-from': 2.2.0 + tslib: 2.8.1 - '@rollup/rollup-darwin-x64@4.60.2': - optional: true + '@smithy/util-utf8@4.2.0': + dependencies: + '@smithy/util-buffer-from': 4.2.0 + tslib: 2.8.1 - '@rollup/rollup-freebsd-arm64@4.60.2': - optional: true + '@smithy/uuid@1.1.0': + dependencies: + tslib: 2.8.1 - '@rollup/rollup-freebsd-x64@4.60.2': - optional: true + '@snyk/github-codeowners@1.1.0': + dependencies: + commander: 4.1.1 + ignore: 5.3.2 + p-map: 4.0.0 - '@rollup/rollup-linux-arm-gnueabihf@4.60.2': - optional: true + '@socket.io/component-emitter@3.1.2': {} - '@rollup/rollup-linux-arm-musleabihf@4.60.2': - optional: true + '@solidity-parser/parser@0.20.2': {} - '@rollup/rollup-linux-arm64-gnu@4.60.2': - optional: true + '@speed-highlight/core@1.2.12': {} - '@rollup/rollup-linux-arm64-musl@4.60.2': - optional: true + '@swc/helpers@0.5.15': + dependencies: + tslib: 2.8.1 - '@rollup/rollup-linux-loong64-gnu@4.60.2': - optional: true + '@tailwindcss/cli@4.1.18': + dependencies: + '@parcel/watcher': 2.5.1 + '@tailwindcss/node': 4.1.18 + '@tailwindcss/oxide': 4.1.18 + enhanced-resolve: 5.18.4 + mri: 1.2.0 + picocolors: 1.1.1 + tailwindcss: 4.1.18 - '@rollup/rollup-linux-loong64-musl@4.60.2': - optional: true + '@tailwindcss/node@4.1.18': + dependencies: + '@jridgewell/remapping': 2.3.5 + enhanced-resolve: 5.18.4 + jiti: 2.6.1 + lightningcss: 1.30.2 + magic-string: 0.30.21 + source-map-js: 1.2.1 + tailwindcss: 4.1.18 - '@rollup/rollup-linux-ppc64-gnu@4.60.2': + '@tailwindcss/oxide-android-arm64@4.1.18': optional: true - '@rollup/rollup-linux-ppc64-musl@4.60.2': + '@tailwindcss/oxide-darwin-arm64@4.1.18': optional: true - '@rollup/rollup-linux-riscv64-gnu@4.60.2': + '@tailwindcss/oxide-darwin-x64@4.1.18': optional: true - '@rollup/rollup-linux-riscv64-musl@4.60.2': + '@tailwindcss/oxide-freebsd-x64@4.1.18': optional: true - '@rollup/rollup-linux-s390x-gnu@4.60.2': + '@tailwindcss/oxide-linux-arm-gnueabihf@4.1.18': optional: true - '@rollup/rollup-linux-x64-gnu@4.60.2': + '@tailwindcss/oxide-linux-arm64-gnu@4.1.18': optional: true - '@rollup/rollup-linux-x64-musl@4.60.2': + '@tailwindcss/oxide-linux-arm64-musl@4.1.18': optional: true - '@rollup/rollup-openbsd-x64@4.60.2': + '@tailwindcss/oxide-linux-x64-gnu@4.1.18': optional: true - '@rollup/rollup-openharmony-arm64@4.60.2': + '@tailwindcss/oxide-linux-x64-musl@4.1.18': optional: true - '@rollup/rollup-win32-arm64-msvc@4.60.2': + '@tailwindcss/oxide-wasm32-wasi@4.1.18': optional: true - '@rollup/rollup-win32-ia32-msvc@4.60.2': + '@tailwindcss/oxide-win32-arm64-msvc@4.1.18': optional: true - '@rollup/rollup-win32-x64-gnu@4.60.2': + '@tailwindcss/oxide-win32-x64-msvc@4.1.18': optional: true - '@rollup/rollup-win32-x64-msvc@4.60.2': - optional: true + '@tailwindcss/oxide@4.1.18': + optionalDependencies: + '@tailwindcss/oxide-android-arm64': 4.1.18 + '@tailwindcss/oxide-darwin-arm64': 4.1.18 + '@tailwindcss/oxide-darwin-x64': 4.1.18 + '@tailwindcss/oxide-freebsd-x64': 4.1.18 + '@tailwindcss/oxide-linux-arm-gnueabihf': 4.1.18 + '@tailwindcss/oxide-linux-arm64-gnu': 4.1.18 + '@tailwindcss/oxide-linux-arm64-musl': 4.1.18 + '@tailwindcss/oxide-linux-x64-gnu': 4.1.18 + '@tailwindcss/oxide-linux-x64-musl': 4.1.18 + '@tailwindcss/oxide-wasm32-wasi': 4.1.18 + '@tailwindcss/oxide-win32-arm64-msvc': 4.1.18 + '@tailwindcss/oxide-win32-x64-msvc': 4.1.18 - '@rtsao/scc@1.1.0': {} + '@tanstack/match-sorter-utils@8.15.1': + dependencies: + remove-accents: 0.5.0 - '@scure/base@1.1.9': {} + '@tanstack/query-core@5.0.5': {} - '@scure/base@1.2.6': {} + '@tanstack/query-core@5.49.1': {} - '@scure/bip32@1.1.5': - dependencies: - '@noble/hashes': 1.2.0 - '@noble/secp256k1': 1.7.1 - '@scure/base': 1.1.9 + '@tanstack/query-core@5.90.15': {} - '@scure/bip32@1.4.0': - dependencies: - '@noble/curves': 1.4.2 - '@noble/hashes': 1.4.0 - '@scure/base': 1.1.9 + '@tanstack/query-devtools@5.0.5': {} - '@scure/bip32@1.7.0': + '@tanstack/query-persist-client-core@5.0.5': dependencies: - '@noble/curves': 1.9.1 - '@noble/hashes': 1.8.0 - '@scure/base': 1.2.6 + '@tanstack/query-core': 5.0.5 - '@scure/bip39@1.1.1': + '@tanstack/query-sync-storage-persister@5.0.5': dependencies: - '@noble/hashes': 1.2.0 - '@scure/base': 1.1.9 + '@tanstack/query-core': 5.0.5 + '@tanstack/query-persist-client-core': 5.0.5 - '@scure/bip39@1.3.0': + '@tanstack/react-query-devtools@5.0.5(@tanstack/react-query@5.49.2(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - '@noble/hashes': 1.4.0 - '@scure/base': 1.1.9 + '@tanstack/query-devtools': 5.0.5 + '@tanstack/react-query': 5.49.2(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) - '@scure/bip39@1.6.0': + '@tanstack/react-query-persist-client@5.0.5(@tanstack/react-query@5.49.2(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - '@noble/hashes': 1.8.0 - '@scure/base': 1.2.6 + '@tanstack/query-persist-client-core': 5.0.5 + '@tanstack/react-query': 5.49.2(react@18.3.1) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) - '@sentry/core@5.30.0': + '@tanstack/react-query@5.49.2(react@18.3.1)': dependencies: - '@sentry/hub': 5.30.0 - '@sentry/minimal': 5.30.0 - '@sentry/types': 5.30.0 - '@sentry/utils': 5.30.0 - tslib: 1.14.1 + '@tanstack/query-core': 5.49.1 + react: 18.3.1 - '@sentry/hub@5.30.0': + '@tanstack/react-query@5.90.15(react@18.3.1)': dependencies: - '@sentry/types': 5.30.0 - '@sentry/utils': 5.30.0 - tslib: 1.14.1 + '@tanstack/query-core': 5.90.15 + react: 18.3.1 - '@sentry/minimal@5.30.0': + '@tanstack/vue-query@5.49.1(vue@3.4.27(typescript@5.9.3))': dependencies: - '@sentry/hub': 5.30.0 - '@sentry/types': 5.30.0 - tslib: 1.14.1 + '@tanstack/match-sorter-utils': 8.15.1 + '@tanstack/query-core': 5.49.1 + '@vue/devtools-api': 6.6.1 + vue: 3.4.27(typescript@5.9.3) + vue-demi: 0.14.10(vue@3.4.27(typescript@5.9.3)) - '@sentry/node@5.30.0': + '@testing-library/dom@10.4.0': dependencies: - '@sentry/core': 5.30.0 - '@sentry/hub': 5.30.0 - '@sentry/tracing': 5.30.0 - '@sentry/types': 5.30.0 - '@sentry/utils': 5.30.0 - cookie: 1.1.1 - https-proxy-agent: 5.0.1 - lru_map: 0.3.3 - tslib: 1.14.1 - transitivePeerDependencies: - - supports-color + '@babel/code-frame': 7.24.2 + '@babel/runtime': 7.26.0 + '@types/aria-query': 5.0.4 + aria-query: 5.3.0 + chalk: 4.1.2 + dom-accessibility-api: 0.5.16 + lz-string: 1.5.0 + pretty-format: 27.5.1 - '@sentry/tracing@5.30.0': + '@testing-library/react@16.0.1(@testing-library/dom@10.4.0)(@types/react-dom@18.3.0)(@types/react@18.3.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: - '@sentry/hub': 5.30.0 - '@sentry/minimal': 5.30.0 - '@sentry/types': 5.30.0 - '@sentry/utils': 5.30.0 - tslib: 1.14.1 + '@babel/runtime': 7.26.0 + '@testing-library/dom': 10.4.0 + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.1 + '@types/react-dom': 18.3.0 - '@sentry/types@5.30.0': {} + '@tootallnate/once@2.0.0': {} - '@sentry/utils@5.30.0': + '@ts-morph/common@0.11.1': dependencies: - '@sentry/types': 5.30.0 - tslib: 1.14.1 + fast-glob: 3.3.3 + minimatch: 3.1.2 + mkdirp: 1.0.4 + path-browserify: 1.0.1 - '@sindresorhus/is@4.6.0': {} + '@tsconfig/node10@1.0.12': {} - '@smithy/config-resolver@4.4.17': - dependencies: - '@smithy/node-config-provider': 4.3.14 - '@smithy/types': 4.14.1 - '@smithy/util-config-provider': 4.2.2 - '@smithy/util-endpoints': 3.4.2 - '@smithy/util-middleware': 4.2.14 - tslib: 2.8.1 + '@tsconfig/node12@1.0.11': {} - '@smithy/core@3.23.17': - dependencies: - '@smithy/protocol-http': 5.3.14 - '@smithy/types': 4.14.1 - '@smithy/url-parser': 4.2.14 - '@smithy/util-base64': 4.3.2 - '@smithy/util-body-length-browser': 4.2.2 - '@smithy/util-middleware': 4.2.14 - '@smithy/util-stream': 4.5.25 - '@smithy/util-utf8': 4.2.2 - '@smithy/uuid': 1.1.2 - tslib: 2.8.1 + '@tsconfig/node14@1.0.3': {} - '@smithy/credential-provider-imds@4.2.14': - dependencies: - '@smithy/node-config-provider': 4.3.14 - '@smithy/property-provider': 4.2.14 - '@smithy/types': 4.14.1 - '@smithy/url-parser': 4.2.14 - tslib: 2.8.1 + '@tsconfig/node16@1.0.4': {} - '@smithy/eventstream-codec@4.2.14': + '@tybys/wasm-util@0.10.1': dependencies: - '@aws-crypto/crc32': 5.2.0 - '@smithy/types': 4.14.1 - '@smithy/util-hex-encoding': 4.2.2 tslib: 2.8.1 + optional: true - '@smithy/eventstream-serde-browser@4.2.14': + '@typechain/ethers-v6@0.5.1(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5))(typescript@5.8.3)': dependencies: - '@smithy/eventstream-serde-universal': 4.2.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + lodash: 4.17.21 + ts-essentials: 7.0.3(typescript@5.8.3) + typescript: 5.8.3 - '@smithy/eventstream-serde-config-resolver@4.3.14': + '@types/aria-query@5.0.4': {} + + '@types/babel__core@7.20.5': dependencies: - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@babel/parser': 7.24.5 + '@babel/types': 7.24.5 + '@types/babel__generator': 7.6.5 + '@types/babel__template': 7.4.2 + '@types/babel__traverse': 7.20.2 - '@smithy/eventstream-serde-node@4.2.14': + '@types/babel__generator@7.6.5': dependencies: - '@smithy/eventstream-serde-universal': 4.2.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@babel/types': 7.27.1 - '@smithy/eventstream-serde-universal@4.2.14': + '@types/babel__template@7.4.2': dependencies: - '@smithy/eventstream-codec': 4.2.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@babel/parser': 7.26.2 + '@babel/types': 7.27.1 - '@smithy/fetch-http-handler@5.3.17': + '@types/babel__traverse@7.20.2': dependencies: - '@smithy/protocol-http': 5.3.14 - '@smithy/querystring-builder': 4.2.14 - '@smithy/types': 4.14.1 - '@smithy/util-base64': 4.3.2 - tslib: 2.8.1 + '@babel/types': 7.27.1 - '@smithy/hash-node@4.2.14': + '@types/bn.js@4.11.6': dependencies: - '@smithy/types': 4.14.1 - '@smithy/util-buffer-from': 4.2.2 - '@smithy/util-utf8': 4.2.2 - tslib: 2.8.1 + '@types/node': 22.15.31 - '@smithy/invalid-dependency@4.2.14': + '@types/bn.js@5.1.5': dependencies: - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@types/node': 24.0.1 - '@smithy/is-array-buffer@2.2.0': + '@types/bun@1.1.10': dependencies: - tslib: 2.8.1 + bun-types: 1.1.29 - '@smithy/is-array-buffer@4.2.2': + '@types/cookie@0.6.0': {} + + '@types/cross-spawn@6.0.6': dependencies: - tslib: 2.8.1 + '@types/node': 20.12.10 - '@smithy/middleware-content-length@4.2.14': + '@types/debug@4.1.12': dependencies: - '@smithy/protocol-http': 5.3.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@types/ms': 2.1.0 - '@smithy/middleware-endpoint@4.4.32': + '@types/debug@4.1.7': dependencies: - '@smithy/core': 3.23.17 - '@smithy/middleware-serde': 4.2.20 - '@smithy/node-config-provider': 4.3.14 - '@smithy/shared-ini-file-loader': 4.4.9 - '@smithy/types': 4.14.1 - '@smithy/url-parser': 4.2.14 - '@smithy/util-middleware': 4.2.14 - tslib: 2.8.1 + '@types/ms': 0.7.31 - '@smithy/middleware-retry@4.5.5': - dependencies: - '@smithy/core': 3.23.17 - '@smithy/node-config-provider': 4.3.14 - '@smithy/protocol-http': 5.3.14 - '@smithy/service-error-classification': 4.3.0 - '@smithy/smithy-client': 4.12.13 - '@smithy/types': 4.14.1 - '@smithy/util-middleware': 4.2.14 - '@smithy/util-retry': 4.3.4 - '@smithy/uuid': 1.1.2 - tslib: 2.8.1 + '@types/dedent@0.7.2': {} + + '@types/estree@1.0.5': {} + + '@types/estree@1.0.8': {} - '@smithy/middleware-serde@4.2.20': + '@types/hast@3.0.4': dependencies: - '@smithy/core': 3.23.17 - '@smithy/protocol-http': 5.3.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@types/unist': 3.0.2 + + '@types/json-schema@7.0.15': {} - '@smithy/middleware-stack@4.2.14': + '@types/linkify-it@5.0.0': {} + + '@types/lru-cache@5.1.1': {} + + '@types/markdown-it@14.1.2': dependencies: - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@types/linkify-it': 5.0.0 + '@types/mdurl': 2.0.0 - '@smithy/node-config-provider@4.3.14': + '@types/mdast@4.0.3': dependencies: - '@smithy/property-provider': 4.2.14 - '@smithy/shared-ini-file-loader': 4.4.9 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@types/unist': 3.0.2 + + '@types/mdurl@2.0.0': {} + + '@types/ms@0.7.31': {} + + '@types/ms@2.1.0': {} - '@smithy/node-http-handler@4.6.1': + '@types/mute-stream@0.0.4': dependencies: - '@smithy/protocol-http': 5.3.14 - '@smithy/querystring-builder': 4.2.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@types/node': 22.15.31 + + '@types/node@12.20.55': {} - '@smithy/property-provider@4.2.14': + '@types/node@16.18.11': {} + + '@types/node@20.12.10': dependencies: - '@smithy/types': 4.14.1 - tslib: 2.8.1 + undici-types: 5.26.5 - '@smithy/protocol-http@5.3.14': + '@types/node@20.12.14': dependencies: - '@smithy/types': 4.14.1 - tslib: 2.8.1 + undici-types: 5.26.5 - '@smithy/querystring-builder@4.2.14': + '@types/node@20.19.27': dependencies: - '@smithy/types': 4.14.1 - '@smithy/util-uri-escape': 4.2.2 - tslib: 2.8.1 + undici-types: 6.21.0 - '@smithy/querystring-parser@4.2.14': + '@types/node@22.15.31': dependencies: - '@smithy/types': 4.14.1 - tslib: 2.8.1 + undici-types: 6.21.0 - '@smithy/service-error-classification@4.3.0': + '@types/node@22.7.5': dependencies: - '@smithy/types': 4.14.1 + undici-types: 6.19.8 - '@smithy/shared-ini-file-loader@4.4.9': + '@types/node@24.0.1': dependencies: - '@smithy/types': 4.14.1 - tslib: 2.8.1 + undici-types: 7.8.0 - '@smithy/signature-v4@5.3.14': + '@types/parse-path@7.1.0': dependencies: - '@smithy/is-array-buffer': 4.2.2 - '@smithy/protocol-http': 5.3.14 - '@smithy/types': 4.14.1 - '@smithy/util-hex-encoding': 4.2.2 - '@smithy/util-middleware': 4.2.14 - '@smithy/util-uri-escape': 4.2.2 - '@smithy/util-utf8': 4.2.2 - tslib: 2.8.1 + parse-path: 7.1.0 - '@smithy/smithy-client@4.12.13': + '@types/pbkdf2@3.1.2': dependencies: - '@smithy/core': 3.23.17 - '@smithy/middleware-endpoint': 4.4.32 - '@smithy/middleware-stack': 4.2.14 - '@smithy/protocol-http': 5.3.14 - '@smithy/types': 4.14.1 - '@smithy/util-stream': 4.5.25 - tslib: 2.8.1 + '@types/node': 22.15.31 - '@smithy/types@4.14.1': + '@types/prompts@2.4.9': dependencies: - tslib: 2.8.1 + '@types/node': 20.12.10 + kleur: 3.0.3 + + '@types/prop-types@15.7.15': {} + + '@types/prop-types@15.7.5': {} - '@smithy/url-parser@4.2.14': + '@types/react-dom@18.3.0': dependencies: - '@smithy/querystring-parser': 4.2.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@types/react': 18.3.1 - '@smithy/util-base64@4.3.2': + '@types/react@18.3.1': dependencies: - '@smithy/util-buffer-from': 4.2.2 - '@smithy/util-utf8': 4.2.2 - tslib: 2.8.1 + '@types/prop-types': 15.7.5 + csstype: 3.1.3 - '@smithy/util-body-length-browser@4.2.2': + '@types/react@18.3.27': dependencies: - tslib: 2.8.1 + '@types/prop-types': 15.7.15 + csstype: 3.2.3 + + '@types/resolve@1.20.2': {} - '@smithy/util-body-length-node@4.2.3': + '@types/secp256k1@4.0.3': dependencies: - tslib: 2.8.1 + '@types/node': 22.15.31 - '@smithy/util-buffer-from@2.2.0': + '@types/semver@7.5.3': {} + + '@types/statuses@2.0.4': {} + + '@types/tough-cookie@4.0.5': {} + + '@types/trusted-types@2.0.3': {} + + '@types/unist@3.0.2': {} + + '@types/use-sync-external-store@0.0.6': {} + + '@types/web-bluetooth@0.0.20': {} + + '@types/whatwg-mimetype@3.0.2': {} + + '@types/wrap-ansi@3.0.0': {} + + '@types/ws@8.5.10': dependencies: - '@smithy/is-array-buffer': 2.2.0 - tslib: 2.8.1 + '@types/node': 22.15.31 - '@smithy/util-buffer-from@4.2.2': + '@typescript/vfs@1.6.0(typescript@5.9.3)': dependencies: - '@smithy/is-array-buffer': 4.2.2 - tslib: 2.8.1 + debug: 4.4.3 + typescript: 5.9.3 + transitivePeerDependencies: + - supports-color - '@smithy/util-config-provider@4.2.2': + '@ungap/structured-clone@1.2.0': {} + + '@unhead/vue@2.1.1(vue@3.5.26(typescript@5.9.3))': dependencies: - tslib: 2.8.1 + hookable: 5.5.3 + unhead: 2.1.1 + vue: 3.5.26(typescript@5.9.3) - '@smithy/util-defaults-mode-browser@4.3.49': + '@unocss/astro@0.59.4(rollup@4.54.0)': dependencies: - '@smithy/property-provider': 4.2.14 - '@smithy/smithy-client': 4.12.13 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@unocss/core': 0.59.4 + '@unocss/reset': 0.59.4 + '@unocss/vite': 0.59.4(rollup@4.54.0) + transitivePeerDependencies: + - rollup - '@smithy/util-defaults-mode-node@4.2.54': + '@unocss/cli@0.59.4(rollup@4.54.0)': dependencies: - '@smithy/config-resolver': 4.4.17 - '@smithy/credential-provider-imds': 4.2.14 - '@smithy/node-config-provider': 4.3.14 - '@smithy/property-provider': 4.2.14 - '@smithy/smithy-client': 4.12.13 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@ampproject/remapping': 2.3.0 + '@rollup/pluginutils': 5.1.0(rollup@4.54.0) + '@unocss/config': 0.59.4 + '@unocss/core': 0.59.4 + '@unocss/preset-uno': 0.59.4 + cac: 6.7.14 + chokidar: 3.6.0 + colorette: 2.0.20 + consola: 3.4.2 + fast-glob: 3.3.2 + magic-string: 0.30.21 + pathe: 1.1.2 + perfect-debounce: 1.0.0 + transitivePeerDependencies: + - rollup - '@smithy/util-endpoints@3.4.2': + '@unocss/config@0.59.4': dependencies: - '@smithy/node-config-provider': 4.3.14 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@unocss/core': 0.59.4 + unconfig: 0.3.13 + + '@unocss/core@0.59.4': {} - '@smithy/util-hex-encoding@4.2.2': + '@unocss/extractor-arbitrary-variants@0.59.4': dependencies: - tslib: 2.8.1 + '@unocss/core': 0.59.4 - '@smithy/util-middleware@4.2.14': + '@unocss/inspector@0.59.4': dependencies: - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@unocss/core': 0.59.4 + '@unocss/rule-utils': 0.59.4 + gzip-size: 6.0.0 + sirv: 2.0.4 - '@smithy/util-retry@4.3.4': + '@unocss/postcss@0.59.4': dependencies: - '@smithy/service-error-classification': 4.3.0 - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@unocss/config': 0.59.4 + '@unocss/core': 0.59.4 + '@unocss/rule-utils': 0.59.4 + css-tree: 2.3.1 + fast-glob: 3.3.2 + magic-string: 0.30.21 + postcss: 8.5.6 - '@smithy/util-stream@4.5.25': + '@unocss/preset-attributify@0.59.4': dependencies: - '@smithy/fetch-http-handler': 5.3.17 - '@smithy/node-http-handler': 4.6.1 - '@smithy/types': 4.14.1 - '@smithy/util-base64': 4.3.2 - '@smithy/util-buffer-from': 4.2.2 - '@smithy/util-hex-encoding': 4.2.2 - '@smithy/util-utf8': 4.2.2 - tslib: 2.8.1 + '@unocss/core': 0.59.4 - '@smithy/util-uri-escape@4.2.2': + '@unocss/preset-icons@0.59.4': dependencies: - tslib: 2.8.1 + '@iconify/utils': 2.1.23 + '@unocss/core': 0.59.4 + ofetch: 1.5.1 + transitivePeerDependencies: + - supports-color - '@smithy/util-utf8@2.3.0': + '@unocss/preset-mini@0.59.4': dependencies: - '@smithy/util-buffer-from': 2.2.0 - tslib: 2.8.1 + '@unocss/core': 0.59.4 + '@unocss/extractor-arbitrary-variants': 0.59.4 + '@unocss/rule-utils': 0.59.4 - '@smithy/util-utf8@4.2.2': + '@unocss/preset-tagify@0.59.4': dependencies: - '@smithy/util-buffer-from': 4.2.2 - tslib: 2.8.1 + '@unocss/core': 0.59.4 - '@smithy/util-waiter@4.2.16': + '@unocss/preset-typography@0.59.4': dependencies: - '@smithy/types': 4.14.1 - tslib: 2.8.1 + '@unocss/core': 0.59.4 + '@unocss/preset-mini': 0.59.4 - '@smithy/uuid@1.1.2': + '@unocss/preset-uno@0.59.4': dependencies: - tslib: 2.8.1 + '@unocss/core': 0.59.4 + '@unocss/preset-mini': 0.59.4 + '@unocss/preset-wind': 0.59.4 + '@unocss/rule-utils': 0.59.4 - '@solidity-parser/parser@0.14.5': + '@unocss/preset-web-fonts@0.59.4': dependencies: - antlr4ts: 0.5.0-alpha.4 + '@unocss/core': 0.59.4 + ofetch: 1.5.1 - '@solidity-parser/parser@0.16.2': + '@unocss/preset-wind@0.59.4': dependencies: - antlr4ts: 0.5.0-alpha.4 + '@unocss/core': 0.59.4 + '@unocss/preset-mini': 0.59.4 + '@unocss/rule-utils': 0.59.4 - '@solidity-parser/parser@0.20.2': {} + '@unocss/reset@0.59.4': {} + + '@unocss/rule-utils@0.59.4': + dependencies: + '@unocss/core': 0.59.4 + magic-string: 0.30.21 - '@standard-schema/spec@1.0.0': {} + '@unocss/scope@0.59.4': {} - '@streamparser/json-node@0.0.22': + '@unocss/transformer-attributify-jsx-babel@0.59.4': dependencies: - '@streamparser/json': 0.0.22 + '@babel/core': 7.24.5 + '@babel/plugin-syntax-jsx': 7.24.1(@babel/core@7.24.5) + '@babel/preset-typescript': 7.24.1(@babel/core@7.24.5) + '@unocss/core': 0.59.4 + transitivePeerDependencies: + - supports-color - '@streamparser/json@0.0.22': {} + '@unocss/transformer-attributify-jsx@0.59.4': + dependencies: + '@unocss/core': 0.59.4 - '@swc/helpers@0.5.15': + '@unocss/transformer-compile-class@0.59.4': dependencies: - tslib: 2.8.1 + '@unocss/core': 0.59.4 - '@szmarczak/http-timer@4.0.6': + '@unocss/transformer-directives@0.59.4': dependencies: - defer-to-connect: 2.0.1 + '@unocss/core': 0.59.4 + '@unocss/rule-utils': 0.59.4 + css-tree: 2.3.1 - '@szmarczak/http-timer@5.0.1': + '@unocss/transformer-variant-group@0.59.4': dependencies: - defer-to-connect: 2.0.1 + '@unocss/core': 0.59.4 - '@tenderly/api-client@1.1.0(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@5.9.3)': + '@unocss/vite@0.59.4(rollup@4.54.0)': dependencies: - axios: 1.15.2(debug@4.4.3) - cli-table3: 0.6.5 - commander: 9.5.0 - dotenv: 16.6.1 - js-yaml: 4.1.1 - open: 8.4.2 - prompts: 2.4.2 - tslog: 4.10.2 + '@ampproject/remapping': 2.3.0 + '@rollup/pluginutils': 5.1.0(rollup@4.54.0) + '@unocss/config': 0.59.4 + '@unocss/core': 0.59.4 + '@unocss/inspector': 0.59.4 + '@unocss/scope': 0.59.4 + '@unocss/transformer-directives': 0.59.4 + chokidar: 3.6.0 + fast-glob: 3.3.2 + magic-string: 0.30.21 + transitivePeerDependencies: + - rollup + + '@vercel/analytics@1.6.1(next@15.4.10(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react@18.3.1)(vue-router@4.6.4(vue@3.5.26(typescript@5.8.3)))(vue@3.5.26(typescript@5.8.3))': optionalDependencies: - ts-node: 10.9.2(@types/node@25.6.0)(typescript@4.9.5) - typescript: 5.9.3 + next: 15.4.10(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + react: 18.3.1 + vue: 3.5.26(typescript@5.8.3) + vue-router: 4.6.4(vue@3.5.26(typescript@5.8.3)) + + '@vercel/backends@0.0.14(encoding@0.1.13)(rollup@4.54.0)(typescript@5.8.3)': + dependencies: + '@vercel/cervel': 0.0.6(typescript@5.8.3) + '@vercel/introspection': 0.0.5 + '@vercel/nft': 1.1.1(encoding@0.1.13)(rollup@4.54.0) + '@vercel/static-config': 3.1.2 + fs-extra: 11.1.0 + rolldown: 1.0.0-beta.35 transitivePeerDependencies: - - debug + - encoding + - rollup + - supports-color + - typescript - '@tenderly/hardhat-integration@1.1.1(@types/node@25.6.0)(bufferutil@4.1.0)(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10)': + '@vercel/blob@1.0.2': dependencies: - '@tenderly/api-client': 1.1.0(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@5.9.3) - axios: 1.15.2(debug@4.4.3) - dotenv: 16.6.1 - fs-extra: 10.1.0 - hardhat: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10) - hardhat-deploy: 0.11.45(bufferutil@4.1.0)(utf-8-validate@5.0.10) - npm-registry-fetch: 17.1.0 - semver: 7.7.4 - ts-node: 10.9.2(@types/node@25.6.0)(typescript@5.9.3) - tslog: 4.10.2 - typescript: 5.9.3 + async-retry: 1.3.3 + is-buffer: 2.0.5 + is-node-process: 1.2.0 + throttleit: 2.1.0 + undici: 5.29.0 + + '@vercel/build-utils@13.2.2': {} + + '@vercel/cervel@0.0.6(typescript@5.8.3)': + dependencies: + execa: 3.2.0 + rolldown: 1.0.0-beta.35 + srvx: 0.8.9 + tsx: 4.19.2 + typescript: 5.8.3 + + '@vercel/detect-agent@1.0.0': {} + + '@vercel/elysia@0.1.12(encoding@0.1.13)(rollup@4.54.0)': + dependencies: + '@vercel/node': 5.5.14(encoding@0.1.13)(rollup@4.54.0) + '@vercel/static-config': 3.1.2 transitivePeerDependencies: - '@swc/core' - '@swc/wasm' - - '@types/node' - - bufferutil - - debug + - encoding + - rollup - supports-color - - utf-8-validate - '@tenderly/hardhat-tenderly@2.5.2(@types/node@25.6.0)(bufferutil@4.1.0)(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10)': + '@vercel/error-utils@2.0.3': {} + + '@vercel/express@0.1.17(encoding@0.1.13)(rollup@4.54.0)(typescript@5.8.3)': dependencies: - '@ethersproject/bignumber': 5.8.0 - '@nomicfoundation/hardhat-ethers': 3.1.3(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)) - '@nomicfoundation/hardhat-ignition': 0.15.16(@nomicfoundation/hardhat-verify@2.1.3(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)))(bufferutil@4.1.0)(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - '@nomicfoundation/hardhat-verify': 2.1.3(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)) - '@openzeppelin/hardhat-upgrades': 3.9.1(@nomicfoundation/hardhat-ethers@3.1.3(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)))(@nomicfoundation/hardhat-verify@2.1.3(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)))(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)) - '@openzeppelin/upgrades-core': 1.44.2 - '@tenderly/hardhat-integration': 1.1.1(@types/node@25.6.0)(bufferutil@4.1.0)(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) - dotenv: 16.6.1 - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@vercel/cervel': 0.0.6(typescript@5.8.3) + '@vercel/nft': 1.1.1(encoding@0.1.13)(rollup@4.54.0) + '@vercel/node': 5.5.14(encoding@0.1.13)(rollup@4.54.0) + '@vercel/static-config': 3.1.2 + fs-extra: 11.1.0 + path-to-regexp: 8.3.0 + rolldown: 1.0.0-beta.35 + ts-morph: 12.0.0 + zod: 3.22.4 transitivePeerDependencies: - '@swc/core' - '@swc/wasm' - - '@types/node' - - aws-crt - - bufferutil - - debug - - hardhat + - encoding + - rollup + - supports-color + - typescript + + '@vercel/fastify@0.1.15(encoding@0.1.13)(rollup@4.54.0)': + dependencies: + '@vercel/node': 5.5.14(encoding@0.1.13)(rollup@4.54.0) + '@vercel/static-config': 3.1.2 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + - encoding + - rollup - supports-color - - utf-8-validate - '@tootallnate/quickjs-emscripten@0.23.0': {} + '@vercel/fun@1.2.0(encoding@0.1.13)': + dependencies: + '@tootallnate/once': 2.0.0 + async-listen: 1.2.0 + debug: 4.3.4(supports-color@8.1.1) + generic-pool: 3.4.2 + micro: 9.3.5-canary.3 + ms: 2.1.1 + node-fetch: 2.6.7(encoding@0.1.13) + path-match: 1.2.4 + promisepipe: 3.0.0 + semver: 7.5.4 + stat-mode: 0.3.0 + stream-to-promise: 2.2.0 + tar: 6.2.1 + tinyexec: 0.3.2 + tree-kill: 1.2.2 + uid-promise: 1.0.0 + xdg-app-paths: 5.1.0 + yauzl-promise: 2.1.3 + transitivePeerDependencies: + - encoding + - supports-color - '@trufflesuite/bigint-buffer@1.1.9': + '@vercel/gatsby-plugin-vercel-analytics@1.0.11': dependencies: - node-gyp-build: 4.3.0 - optional: true + web-vitals: 0.2.4 - '@trufflesuite/uws-js-unofficial@20.30.0-unofficial.0': + '@vercel/gatsby-plugin-vercel-builder@2.0.112': dependencies: - ws: 8.20.0(bufferutil@4.0.7)(utf-8-validate@6.0.3) - optionalDependencies: - bufferutil: 4.0.7 - utf-8-validate: 6.0.3 + '@sinclair/typebox': 0.25.24 + '@vercel/build-utils': 13.2.2 + esbuild: 0.14.47 + etag: 1.8.1 + fs-extra: 11.1.0 - '@tsconfig/node10@1.0.12': {} + '@vercel/go@3.2.3': {} - '@tsconfig/node12@1.0.11': {} + '@vercel/h3@0.1.21(encoding@0.1.13)(rollup@4.54.0)': + dependencies: + '@vercel/node': 5.5.14(encoding@0.1.13)(rollup@4.54.0) + '@vercel/static-config': 3.1.2 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + - encoding + - rollup + - supports-color - '@tsconfig/node14@1.0.3': {} + '@vercel/hono@0.2.15(encoding@0.1.13)(rollup@4.54.0)': + dependencies: + '@vercel/nft': 1.1.1(encoding@0.1.13)(rollup@4.54.0) + '@vercel/node': 5.5.14(encoding@0.1.13)(rollup@4.54.0) + '@vercel/static-config': 3.1.2 + fs-extra: 11.1.0 + path-to-regexp: 8.3.0 + rolldown: 1.0.0-beta.35 + ts-morph: 12.0.0 + zod: 3.22.4 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + - encoding + - rollup + - supports-color - '@tsconfig/node16@1.0.4': {} + '@vercel/hydrogen@1.3.2': + dependencies: + '@vercel/static-config': 3.1.2 + ts-morph: 12.0.0 - '@turbo/darwin-64@2.9.6': - optional: true + '@vercel/introspection@0.0.5': + dependencies: + path-to-regexp: 8.3.0 + zod: 3.22.4 - '@turbo/darwin-arm64@2.9.6': - optional: true + '@vercel/nestjs@0.2.16(encoding@0.1.13)(rollup@4.54.0)': + dependencies: + '@vercel/node': 5.5.14(encoding@0.1.13)(rollup@4.54.0) + '@vercel/static-config': 3.1.2 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + - encoding + - rollup + - supports-color - '@turbo/gen@1.13.4(@types/node@25.3.0)(typescript@5.9.3)': + '@vercel/next@4.15.7(encoding@0.1.13)(rollup@4.54.0)': dependencies: - '@turbo/workspaces': 1.13.4(@types/node@25.3.0) - chalk: 2.4.2 - commander: 10.0.1 - fs-extra: 10.1.0 - inquirer: 8.2.7(@types/node@25.3.0) - minimatch: 10.2.5 - node-plop: 0.26.3 - proxy-agent: 6.5.0 - ts-node: 10.9.2(@types/node@25.3.0)(typescript@5.9.3) - update-check: 1.5.4 - validate-npm-package-name: 5.0.1 + '@vercel/nft': 1.1.1(encoding@0.1.13)(rollup@4.54.0) + transitivePeerDependencies: + - encoding + - rollup + - supports-color + + '@vercel/nft@0.30.4(encoding@0.1.13)(rollup@4.54.0)': + dependencies: + '@mapbox/node-pre-gyp': 2.0.3(encoding@0.1.13) + '@rollup/pluginutils': 5.3.0(rollup@4.54.0) + acorn: 8.15.0 + acorn-import-attributes: 1.9.5(acorn@8.15.0) + async-sema: 3.1.1 + bindings: 1.5.0 + estree-walker: 2.0.2 + glob: 10.5.0 + graceful-fs: 4.2.11 + node-gyp-build: 4.8.4 + picomatch: 4.0.3 + resolve-from: 5.0.0 + transitivePeerDependencies: + - encoding + - rollup + - supports-color + + '@vercel/nft@1.1.1(encoding@0.1.13)(rollup@4.54.0)': + dependencies: + '@mapbox/node-pre-gyp': 2.0.3(encoding@0.1.13) + '@rollup/pluginutils': 5.3.0(rollup@4.54.0) + acorn: 8.15.0 + acorn-import-attributes: 1.9.5(acorn@8.15.0) + async-sema: 3.1.1 + bindings: 1.5.0 + estree-walker: 2.0.2 + glob: 13.0.0 + graceful-fs: 4.2.11 + node-gyp-build: 4.8.4 + picomatch: 4.0.3 + resolve-from: 5.0.0 + transitivePeerDependencies: + - encoding + - rollup + - supports-color + + '@vercel/node@5.5.14(encoding@0.1.13)(rollup@4.54.0)': + dependencies: + '@edge-runtime/node-utils': 2.3.0 + '@edge-runtime/primitives': 4.1.0 + '@edge-runtime/vm': 3.2.0 + '@types/node': 16.18.11 + '@vercel/build-utils': 13.2.2 + '@vercel/error-utils': 2.0.3 + '@vercel/nft': 1.1.1(encoding@0.1.13)(rollup@4.54.0) + '@vercel/static-config': 3.1.2 + async-listen: 3.0.0 + cjs-module-lexer: 1.2.3 + edge-runtime: 2.5.9 + es-module-lexer: 1.4.1 + esbuild: 0.14.47 + etag: 1.8.1 + mime-types: 2.1.35 + node-fetch: 2.6.9(encoding@0.1.13) + path-to-regexp: 6.1.0 + path-to-regexp-updated: path-to-regexp@6.3.0 + ts-morph: 12.0.0 + ts-node: 10.9.1(@types/node@16.18.11)(typescript@4.9.5) + typescript: 4.9.5 + typescript5: typescript@5.9.3 + undici: 5.28.4 transitivePeerDependencies: - '@swc/core' - '@swc/wasm' - - '@types/node' + - encoding + - rollup - supports-color - - typescript - '@turbo/linux-64@2.9.6': - optional: true + '@vercel/python@6.1.0': {} - '@turbo/linux-arm64@2.9.6': - optional: true + '@vercel/redwood@2.4.5(encoding@0.1.13)(rollup@4.54.0)': + dependencies: + '@vercel/nft': 1.1.1(encoding@0.1.13)(rollup@4.54.0) + '@vercel/static-config': 3.1.2 + semver: 6.3.1 + ts-morph: 12.0.0 + transitivePeerDependencies: + - encoding + - rollup + - supports-color - '@turbo/windows-64@2.9.6': - optional: true + '@vercel/remix-builder@5.5.5(encoding@0.1.13)(rollup@4.54.0)': + dependencies: + '@vercel/error-utils': 2.0.3 + '@vercel/nft': 1.1.1(encoding@0.1.13)(rollup@4.54.0) + '@vercel/static-config': 3.1.2 + path-to-regexp: 6.1.0 + path-to-regexp-updated: path-to-regexp@6.3.0 + ts-morph: 12.0.0 + transitivePeerDependencies: + - encoding + - rollup + - supports-color + + '@vercel/ruby@2.2.2': {} + + '@vercel/rust@1.0.3': + dependencies: + '@iarna/toml': 2.2.5 + execa: 5.1.1 + + '@vercel/static-build@2.8.13': + dependencies: + '@vercel/gatsby-plugin-vercel-analytics': 1.0.11 + '@vercel/gatsby-plugin-vercel-builder': 2.0.112 + '@vercel/static-config': 3.1.2 + ts-morph: 12.0.0 + + '@vercel/static-config@3.1.2': + dependencies: + ajv: 8.6.3 + json-schema-to-ts: 1.6.4 + ts-morph: 12.0.0 - '@turbo/windows-arm64@2.9.6': - optional: true + '@vitejs/plugin-react@4.2.1(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))': + dependencies: + '@babel/core': 7.24.5 + '@babel/plugin-transform-react-jsx-self': 7.24.5(@babel/core@7.24.5) + '@babel/plugin-transform-react-jsx-source': 7.24.1(@babel/core@7.24.5) + '@types/babel__core': 7.20.5 + react-refresh: 0.14.0 + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + transitivePeerDependencies: + - supports-color - '@turbo/workspaces@1.13.4(@types/node@25.3.0)': + '@vitejs/plugin-vue-jsx@5.1.3(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(vue@3.5.26(typescript@5.9.3))': dependencies: - chalk: 2.4.2 - commander: 10.0.1 - execa: 5.1.1 - fast-glob: 3.3.3 - fs-extra: 10.1.0 - gradient-string: 2.0.2 - inquirer: 8.2.7(@types/node@25.3.0) - js-yaml: 4.1.1 - ora: 4.1.1 - rimraf: 3.0.2 - semver: 7.7.4 - update-check: 1.5.4 + '@babel/core': 7.28.5 + '@babel/plugin-syntax-typescript': 7.27.1(@babel/core@7.28.5) + '@babel/plugin-transform-typescript': 7.28.5(@babel/core@7.28.5) + '@rolldown/pluginutils': 1.0.0-beta.57 + '@vue/babel-plugin-jsx': 2.0.1(@babel/core@7.28.5) + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + vue: 3.5.26(typescript@5.9.3) transitivePeerDependencies: - - '@types/node' + - supports-color - '@typechain/ethers-v5@10.2.1(@ethersproject/abi@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3)': + '@vitejs/plugin-vue@5.0.4(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(vue@3.4.27(typescript@5.9.3))': dependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/providers': 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - lodash: 4.18.1 - ts-essentials: 7.0.3(typescript@5.9.3) - typechain: 8.3.2(typescript@5.9.3) - typescript: 5.9.3 + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + vue: 3.4.27(typescript@5.9.3) - '@typechain/ethers-v5@10.2.1(@ethersproject/abi@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@4.9.5))(typescript@4.9.5)': + '@vitejs/plugin-vue@5.1.4(vite@5.4.21(@types/node@24.0.1)(lightningcss@1.30.2)(terser@5.44.1))(vue@3.5.12(typescript@5.9.3))': dependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/providers': 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - lodash: 4.18.1 - ts-essentials: 7.0.3(typescript@4.9.5) - typechain: 8.3.2(typescript@4.9.5) - typescript: 4.9.5 + vite: 5.4.21(@types/node@24.0.1)(lightningcss@1.30.2)(terser@5.44.1) + vue: 3.5.12(typescript@5.9.3) - '@typechain/ethers-v5@7.2.0(@ethersproject/abi@5.8.0)(@ethersproject/bytes@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3))(ethers@5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3))(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3)': + '@vitejs/plugin-vue@6.0.3(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(vue@3.5.26(typescript@5.9.3))': dependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/providers': 5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3) - ethers: 5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3) - lodash: 4.18.1 - ts-essentials: 7.0.3(typescript@5.9.3) - typechain: 8.3.2(typescript@5.9.3) - typescript: 5.9.3 + '@rolldown/pluginutils': 1.0.0-beta.53 + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + vue: 3.5.26(typescript@5.9.3) - '@typechain/ethers-v5@7.2.0(@ethersproject/abi@5.8.0)(@ethersproject/bytes@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3))(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3))(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3)': + '@vitest/coverage-v8@3.2.4(vitest@2.1.9(@edge-runtime/vm@3.2.0)(@types/node@24.0.1)(happy-dom@20.0.2)(lightningcss@1.30.2)(msw@2.4.9(typescript@5.8.3))(terser@5.44.1))': dependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/providers': 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - lodash: 4.18.1 - ts-essentials: 7.0.3(typescript@5.9.3) - typechain: 8.3.2(typescript@5.9.3) - typescript: 5.9.3 + '@ampproject/remapping': 2.3.0 + '@bcoe/v8-coverage': 1.0.2 + ast-v8-to-istanbul: 0.3.9 + debug: 4.4.3 + istanbul-lib-coverage: 3.2.2 + istanbul-lib-report: 3.0.1 + istanbul-lib-source-maps: 5.0.6 + istanbul-reports: 3.2.0 + magic-string: 0.30.21 + magicast: 0.3.5 + std-env: 3.10.0 + test-exclude: 7.0.1 + tinyrainbow: 2.0.0 + vitest: 2.1.9(@edge-runtime/vm@3.2.0)(@types/node@24.0.1)(happy-dom@20.0.2)(lightningcss@1.30.2)(msw@2.4.9(typescript@5.8.3))(terser@5.44.1) + transitivePeerDependencies: + - supports-color - '@typechain/ethers-v6@0.5.1(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@4.9.5))(typescript@4.9.5)': + '@vitest/expect@2.1.9': dependencies: - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - lodash: 4.18.1 - ts-essentials: 7.0.3(typescript@4.9.5) - typechain: 8.3.2(typescript@4.9.5) - typescript: 4.9.5 + '@vitest/spy': 2.1.9 + '@vitest/utils': 2.1.9 + chai: 5.2.0 + tinyrainbow: 1.2.0 - '@typechain/ethers-v6@0.5.1(ethers@6.16.0)(typechain@8.3.2(typescript@5.9.3))(typescript@5.9.3)': + '@vitest/mocker@2.1.9(msw@2.4.9(typescript@5.8.3))(vite@5.4.21(@types/node@24.0.1)(lightningcss@1.30.2)(terser@5.44.1))': dependencies: - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - lodash: 4.18.1 - ts-essentials: 7.0.3(typescript@5.9.3) - typechain: 8.3.2(typescript@5.9.3) - typescript: 5.9.3 + '@vitest/spy': 2.1.9 + estree-walker: 3.0.3 + magic-string: 0.30.21 + optionalDependencies: + msw: 2.4.9(typescript@5.8.3) + vite: 5.4.21(@types/node@24.0.1)(lightningcss@1.30.2)(terser@5.44.1) - '@types/abstract-leveldown@7.2.5': {} + '@vitest/pretty-format@2.1.9': + dependencies: + tinyrainbow: 1.2.0 - '@types/bn.js@4.11.6': + '@vitest/runner@2.1.9': dependencies: - '@types/node': 25.6.0 + '@vitest/utils': 2.1.9 + pathe: 1.1.2 - '@types/bn.js@5.2.0': + '@vitest/snapshot@2.1.9': dependencies: - '@types/node': 25.6.0 + '@vitest/pretty-format': 2.1.9 + magic-string: 0.30.21 + pathe: 1.1.2 - '@types/cacheable-request@6.0.3': + '@vitest/spy@2.1.9': dependencies: - '@types/http-cache-semantics': 4.2.0 - '@types/keyv': 3.1.4 - '@types/node': 12.20.55 - '@types/responselike': 1.0.3 + tinyspy: 3.0.2 - '@types/chai-as-promised@7.1.8': + '@vitest/utils@2.1.9': dependencies: - '@types/chai': 4.3.20 + '@vitest/pretty-format': 2.1.9 + loupe: 3.1.3 + tinyrainbow: 1.2.0 - '@types/chai-string@1.4.5': + '@volar/language-core@2.2.1': dependencies: - '@types/chai': 4.3.20 + '@volar/source-map': 2.2.1 - '@types/chai@4.3.20': {} + '@volar/language-core@2.4.27': + dependencies: + '@volar/source-map': 2.4.27 - '@types/chai@5.2.3': + '@volar/language-core@2.4.8': dependencies: - '@types/deep-eql': 4.0.2 - assertion-error: 2.0.1 + '@volar/source-map': 2.4.8 - '@types/concat-stream@1.6.1': + '@volar/source-map@2.2.1': dependencies: - '@types/node': 8.10.66 + muggle-string: 0.4.1 - '@types/cors@2.8.19': + '@volar/source-map@2.4.27': {} + + '@volar/source-map@2.4.8': {} + + '@volar/typescript@2.2.1': dependencies: - '@types/node': 25.6.0 + '@volar/language-core': 2.2.1 + path-browserify: 1.0.1 - '@types/debug@4.1.13': + '@vue-macros/common@3.0.0-beta.16(vue@3.5.26(typescript@5.9.3))': dependencies: - '@types/ms': 2.1.0 + '@vue/compiler-sfc': 3.5.26 + ast-kit: 2.2.0 + local-pkg: 1.1.2 + magic-string-ast: 1.0.3 + unplugin-utils: 0.2.5 + optionalDependencies: + vue: 3.5.26(typescript@5.9.3) - '@types/deep-eql@4.0.2': {} + '@vue/babel-helper-vue-transform-on@2.0.1': {} - '@types/estree@1.0.8': {} + '@vue/babel-plugin-jsx@2.0.1(@babel/core@7.28.5)': + dependencies: + '@babel/helper-module-imports': 7.27.1 + '@babel/helper-plugin-utils': 7.27.1 + '@babel/plugin-syntax-jsx': 7.27.1(@babel/core@7.28.5) + '@babel/template': 7.27.2 + '@babel/traverse': 7.28.5 + '@babel/types': 7.28.5 + '@vue/babel-helper-vue-transform-on': 2.0.1 + '@vue/babel-plugin-resolve-type': 2.0.1(@babel/core@7.28.5) + '@vue/shared': 3.5.26 + optionalDependencies: + '@babel/core': 7.28.5 + transitivePeerDependencies: + - supports-color - '@types/ethereum-protocol@1.0.5': + '@vue/babel-plugin-resolve-type@2.0.1(@babel/core@7.28.5)': dependencies: - bignumber.js: 7.2.1 + '@babel/code-frame': 7.27.1 + '@babel/core': 7.28.5 + '@babel/helper-module-imports': 7.27.1 + '@babel/helper-plugin-utils': 7.27.1 + '@babel/parser': 7.28.5 + '@vue/compiler-sfc': 3.5.26 + transitivePeerDependencies: + - supports-color - '@types/form-data@0.0.33': + '@vue/compiler-core@3.4.27': dependencies: - '@types/node': 8.10.66 + '@babel/parser': 7.26.2 + '@vue/shared': 3.4.27 + entities: 4.5.0 + estree-walker: 2.0.2 + source-map-js: 1.2.1 - '@types/glob@7.2.0': + '@vue/compiler-core@3.5.12': dependencies: - '@types/minimatch': 6.0.0 - '@types/node': 25.6.0 + '@babel/parser': 7.28.5 + '@vue/shared': 3.5.12 + entities: 4.5.0 + estree-walker: 2.0.2 + source-map-js: 1.2.1 - '@types/http-cache-semantics@4.2.0': {} + '@vue/compiler-core@3.5.26': + dependencies: + '@babel/parser': 7.28.5 + '@vue/shared': 3.5.26 + entities: 7.0.0 + estree-walker: 2.0.2 + source-map-js: 1.2.1 - '@types/inquirer@6.5.0': + '@vue/compiler-dom@3.4.27': dependencies: - '@types/through': 0.0.33 - rxjs: 6.6.7 + '@vue/compiler-core': 3.4.27 + '@vue/shared': 3.4.27 - '@types/json-schema@7.0.15': {} + '@vue/compiler-dom@3.5.12': + dependencies: + '@vue/compiler-core': 3.5.12 + '@vue/shared': 3.5.12 - '@types/json5@0.0.29': {} + '@vue/compiler-dom@3.5.26': + dependencies: + '@vue/compiler-core': 3.5.26 + '@vue/shared': 3.5.26 - '@types/jwt-decode@3.1.0': + '@vue/compiler-sfc@3.4.27': dependencies: - jwt-decode: 4.0.0 + '@babel/parser': 7.26.2 + '@vue/compiler-core': 3.4.27 + '@vue/compiler-dom': 3.4.27 + '@vue/compiler-ssr': 3.4.27 + '@vue/shared': 3.4.27 + estree-walker: 2.0.2 + magic-string: 0.30.12 + postcss: 8.4.47 + source-map-js: 1.2.1 - '@types/keyv@3.1.4': + '@vue/compiler-sfc@3.5.12': dependencies: - '@types/node': 12.20.55 + '@babel/parser': 7.26.2 + '@vue/compiler-core': 3.5.12 + '@vue/compiler-dom': 3.5.12 + '@vue/compiler-ssr': 3.5.12 + '@vue/shared': 3.5.12 + estree-walker: 2.0.2 + magic-string: 0.30.21 + postcss: 8.5.6 + source-map-js: 1.2.1 - '@types/level-errors@3.0.2': {} + '@vue/compiler-sfc@3.5.26': + dependencies: + '@babel/parser': 7.28.5 + '@vue/compiler-core': 3.5.26 + '@vue/compiler-dom': 3.5.26 + '@vue/compiler-ssr': 3.5.26 + '@vue/shared': 3.5.26 + estree-walker: 2.0.2 + magic-string: 0.30.21 + postcss: 8.5.6 + source-map-js: 1.2.1 - '@types/levelup@4.3.3': + '@vue/compiler-ssr@3.4.27': dependencies: - '@types/abstract-leveldown': 7.2.5 - '@types/level-errors': 3.0.2 - '@types/node': 25.6.0 + '@vue/compiler-dom': 3.4.27 + '@vue/shared': 3.4.27 - '@types/lru-cache@5.1.1': {} + '@vue/compiler-ssr@3.5.12': + dependencies: + '@vue/compiler-dom': 3.5.12 + '@vue/shared': 3.5.12 - '@types/minimatch@6.0.0': + '@vue/compiler-ssr@3.5.26': dependencies: - minimatch: 10.2.5 + '@vue/compiler-dom': 3.5.26 + '@vue/shared': 3.5.26 - '@types/mkdirp@0.5.2': + '@vue/compiler-vue2@2.7.16': dependencies: - '@types/node': 25.6.0 + de-indent: 1.0.2 + he: 1.2.0 - '@types/mocha@8.2.3': {} + '@vue/devtools-api@6.6.1': {} - '@types/ms@2.1.0': {} + '@vue/devtools-api@6.6.4': {} - '@types/node-fetch@2.6.13': + '@vue/devtools-api@7.6.2': dependencies: - '@types/node': 25.6.0 - form-data: 4.0.5 + '@vue/devtools-kit': 7.6.2 - '@types/node@10.17.60': {} + '@vue/devtools-core@7.7.9(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(vue@3.5.26(typescript@5.9.3))': + dependencies: + '@vue/devtools-kit': 7.7.9 + '@vue/devtools-shared': 7.7.9 + mitt: 3.0.1 + nanoid: 5.1.6 + pathe: 2.0.3 + vite-hot-client: 2.1.0(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2)) + vue: 3.5.26(typescript@5.9.3) + transitivePeerDependencies: + - vite - '@types/node@11.11.6': {} + '@vue/devtools-kit@7.6.2': + dependencies: + '@vue/devtools-shared': 7.6.2 + birpc: 0.2.19 + hookable: 5.5.3 + mitt: 3.0.1 + perfect-debounce: 1.0.0 + speakingurl: 14.0.1 + superjson: 2.2.1 - '@types/node@12.20.55': {} + '@vue/devtools-kit@7.7.9': + dependencies: + '@vue/devtools-shared': 7.7.9 + birpc: 2.9.0 + hookable: 5.5.3 + mitt: 3.0.1 + perfect-debounce: 1.0.0 + speakingurl: 14.0.1 + superjson: 2.2.6 - '@types/node@22.7.5': + '@vue/devtools-shared@7.6.2': dependencies: - undici-types: 6.19.8 + rfdc: 1.4.1 - '@types/node@25.3.0': + '@vue/devtools-shared@7.7.9': dependencies: - undici-types: 7.18.2 + rfdc: 1.4.1 - '@types/node@25.6.0': + '@vue/language-core@2.0.16(typescript@5.9.3)': dependencies: - undici-types: 7.19.2 + '@volar/language-core': 2.2.1 + '@vue/compiler-dom': 3.5.12 + '@vue/shared': 3.5.26 + computeds: 0.0.1 + minimatch: 9.0.4 + path-browserify: 1.0.1 + vue-template-compiler: 2.7.16 + optionalDependencies: + typescript: 5.9.3 - '@types/node@8.10.66': {} + '@vue/language-core@2.1.10(typescript@5.9.3)': + dependencies: + '@volar/language-core': 2.4.8 + '@vue/compiler-dom': 3.5.26 + '@vue/compiler-vue2': 2.7.16 + '@vue/shared': 3.5.26 + alien-signals: 0.2.0 + minimatch: 9.0.5 + muggle-string: 0.4.1 + path-browserify: 1.0.1 + optionalDependencies: + typescript: 5.9.3 - '@types/pbkdf2@3.1.2': + '@vue/language-core@3.2.1': dependencies: - '@types/node': 25.6.0 + '@volar/language-core': 2.4.27 + '@vue/compiler-dom': 3.5.26 + '@vue/shared': 3.5.26 + alien-signals: 3.1.2 + muggle-string: 0.4.1 + path-browserify: 1.0.1 + picomatch: 4.0.3 - '@types/prettier@2.7.3': {} + '@vue/reactivity@3.4.27': + dependencies: + '@vue/shared': 3.4.27 - '@types/prop-types@15.7.15': {} + '@vue/reactivity@3.5.12': + dependencies: + '@vue/shared': 3.5.12 - '@types/qs@6.15.0': {} + '@vue/reactivity@3.5.26': + dependencies: + '@vue/shared': 3.5.26 - '@types/react-dom@19.2.3(@types/react@19.2.7)': + '@vue/runtime-core@3.4.27': dependencies: - '@types/react': 19.2.7 + '@vue/reactivity': 3.4.27 + '@vue/shared': 3.4.27 - '@types/react@18.3.28': + '@vue/runtime-core@3.5.12': dependencies: - '@types/prop-types': 15.7.15 - csstype: 3.2.3 + '@vue/reactivity': 3.5.12 + '@vue/shared': 3.5.12 - '@types/react@19.2.7': + '@vue/runtime-core@3.5.26': dependencies: - csstype: 3.2.3 + '@vue/reactivity': 3.5.26 + '@vue/shared': 3.5.26 - '@types/responselike@1.0.3': + '@vue/runtime-dom@3.4.27': dependencies: - '@types/node': 12.20.55 + '@vue/runtime-core': 3.4.27 + '@vue/shared': 3.4.27 + csstype: 3.1.3 - '@types/secp256k1@4.0.7': + '@vue/runtime-dom@3.5.12': dependencies: - '@types/node': 25.6.0 + '@vue/reactivity': 3.5.12 + '@vue/runtime-core': 3.5.12 + '@vue/shared': 3.5.12 + csstype: 3.2.3 - '@types/seedrandom@3.0.1': {} + '@vue/runtime-dom@3.5.26': + dependencies: + '@vue/reactivity': 3.5.26 + '@vue/runtime-core': 3.5.26 + '@vue/shared': 3.5.26 + csstype: 3.2.3 - '@types/through@0.0.33': + '@vue/server-renderer@3.4.27(vue@3.4.27(typescript@5.9.3))': dependencies: - '@types/node': 25.3.0 + '@vue/compiler-ssr': 3.4.27 + '@vue/shared': 3.4.27 + vue: 3.4.27(typescript@5.9.3) - '@types/tinycolor2@1.4.6': {} + '@vue/server-renderer@3.5.12(vue@3.5.12(typescript@5.9.3))': + dependencies: + '@vue/compiler-ssr': 3.5.12 + '@vue/shared': 3.5.12 + vue: 3.5.12(typescript@5.9.3) - '@types/web3-provider-engine@14.0.4': + '@vue/server-renderer@3.5.26(vue@3.5.26(typescript@5.8.3))': dependencies: - '@types/ethereum-protocol': 1.0.5 + '@vue/compiler-ssr': 3.5.26 + '@vue/shared': 3.5.26 + vue: 3.5.26(typescript@5.8.3) + optional: true - '@types/webextension-polyfill@0.10.7': {} + '@vue/server-renderer@3.5.26(vue@3.5.26(typescript@5.9.3))': + dependencies: + '@vue/compiler-ssr': 3.5.26 + '@vue/shared': 3.5.26 + vue: 3.5.26(typescript@5.9.3) - '@types/whatwg-mimetype@3.0.2': {} + '@vue/shared@3.4.27': {} - '@types/ws@8.18.1': - dependencies: - '@types/node': 25.3.0 + '@vue/shared@3.5.12': {} - '@types/yargs-parser@21.0.3': {} + '@vue/shared@3.5.26': {} - '@types/yargs@17.0.35': + '@vue/test-utils@2.4.6': dependencies: - '@types/yargs-parser': 21.0.3 + js-beautify: 1.15.1 + vue-component-type-helpers: 2.0.16 - '@typescript-eslint/eslint-plugin@8.50.0(@typescript-eslint/parser@8.50.0(eslint@9.39.2)(typescript@5.9.3))(eslint@9.39.2)(typescript@5.9.3)': + '@vueuse/core@11.2.0(vue@3.5.12(typescript@5.9.3))': dependencies: - '@eslint-community/regexpp': 4.12.2 - '@typescript-eslint/parser': 8.50.0(eslint@9.39.2)(typescript@5.9.3) - '@typescript-eslint/scope-manager': 8.50.0 - '@typescript-eslint/type-utils': 8.50.0(eslint@9.39.2)(typescript@5.9.3) - '@typescript-eslint/utils': 8.50.0(eslint@9.39.2)(typescript@5.9.3) - '@typescript-eslint/visitor-keys': 8.50.0 - eslint: 9.39.2 - ignore: 7.0.5 - natural-compare: 1.4.0 - ts-api-utils: 2.5.0(typescript@5.9.3) - typescript: 5.9.3 + '@types/web-bluetooth': 0.0.20 + '@vueuse/metadata': 11.2.0 + '@vueuse/shared': 11.2.0(vue@3.5.12(typescript@5.9.3)) + vue-demi: 0.14.10(vue@3.5.12(typescript@5.9.3)) transitivePeerDependencies: - - supports-color + - '@vue/composition-api' + - vue - '@typescript-eslint/eslint-plugin@8.59.0(@typescript-eslint/parser@8.59.0(eslint@9.39.4)(typescript@4.9.5))(eslint@9.39.4)(typescript@4.9.5)': + '@vueuse/integrations@11.2.0(change-case@5.4.4)(focus-trap@7.6.0)(fuse.js@7.1.0)(idb-keyval@6.2.1)(jwt-decode@4.0.0)(qrcode@1.5.3)(vue@3.5.12(typescript@5.9.3))': dependencies: - '@eslint-community/regexpp': 4.12.2 - '@typescript-eslint/parser': 8.59.0(eslint@9.39.4)(typescript@4.9.5) - '@typescript-eslint/scope-manager': 8.59.0 - '@typescript-eslint/type-utils': 8.59.0(eslint@9.39.4)(typescript@4.9.5) - '@typescript-eslint/utils': 8.59.0(eslint@9.39.4)(typescript@4.9.5) - '@typescript-eslint/visitor-keys': 8.59.0 - eslint: 9.39.4 - ignore: 7.0.5 - natural-compare: 1.4.0 - ts-api-utils: 2.5.0(typescript@4.9.5) - typescript: 4.9.5 + '@vueuse/core': 11.2.0(vue@3.5.12(typescript@5.9.3)) + '@vueuse/shared': 11.2.0(vue@3.5.12(typescript@5.9.3)) + vue-demi: 0.14.10(vue@3.5.12(typescript@5.9.3)) + optionalDependencies: + change-case: 5.4.4 + focus-trap: 7.6.0 + fuse.js: 7.1.0 + idb-keyval: 6.2.1 + jwt-decode: 4.0.0 + qrcode: 1.5.3 transitivePeerDependencies: - - supports-color + - '@vue/composition-api' + - vue - '@typescript-eslint/parser@8.50.0(eslint@9.39.2)(typescript@5.9.3)': - dependencies: - '@typescript-eslint/scope-manager': 8.50.0 - '@typescript-eslint/types': 8.50.0 - '@typescript-eslint/typescript-estree': 8.50.0(typescript@5.9.3) - '@typescript-eslint/visitor-keys': 8.50.0 - debug: 4.4.3(supports-color@5.5.0) - eslint: 9.39.2 - typescript: 5.9.3 - transitivePeerDependencies: - - supports-color + '@vueuse/metadata@11.2.0': {} - '@typescript-eslint/parser@8.59.0(eslint@9.39.4)(typescript@4.9.5)': + '@vueuse/shared@11.2.0(vue@3.5.12(typescript@5.9.3))': dependencies: - '@typescript-eslint/scope-manager': 8.59.0 - '@typescript-eslint/types': 8.59.0 - '@typescript-eslint/typescript-estree': 8.59.0(typescript@4.9.5) - '@typescript-eslint/visitor-keys': 8.59.0 - debug: 4.4.3(supports-color@5.5.0) - eslint: 9.39.4 - typescript: 4.9.5 + vue-demi: 0.14.10(vue@3.5.12(typescript@5.9.3)) transitivePeerDependencies: - - supports-color - - '@typescript-eslint/project-service@8.50.0(typescript@5.9.3)': - dependencies: - '@typescript-eslint/tsconfig-utils': 8.50.0(typescript@5.9.3) - '@typescript-eslint/types': 8.50.0 - debug: 4.4.3(supports-color@5.5.0) - typescript: 5.9.3 + - '@vue/composition-api' + - vue + + '@walletconnect/core@2.19.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': + dependencies: + '@walletconnect/heartbeat': 1.2.2 + '@walletconnect/jsonrpc-provider': 1.0.14 + '@walletconnect/jsonrpc-types': 1.0.4 + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/jsonrpc-ws-connection': 1.0.16(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@walletconnect/keyvaluestorage': 1.1.1(ioredis@5.8.2) + '@walletconnect/logger': 2.1.2 + '@walletconnect/relay-api': 1.0.11 + '@walletconnect/relay-auth': 1.1.0 + '@walletconnect/safe-json': 1.0.2 + '@walletconnect/time': 1.0.2 + '@walletconnect/types': 2.19.2(ioredis@5.8.2) + '@walletconnect/utils': 2.19.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@walletconnect/window-getters': 1.0.1 + es-toolkit: 1.33.0 + events: 3.3.0 + uint8arrays: 3.1.0 transitivePeerDependencies: - - supports-color + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - ioredis + - typescript + - uWebSockets.js + - utf-8-validate + - zod - '@typescript-eslint/project-service@8.59.0(typescript@4.9.5)': - dependencies: - '@typescript-eslint/tsconfig-utils': 8.59.0(typescript@4.9.5) - '@typescript-eslint/types': 8.59.0 - debug: 4.4.3(supports-color@5.5.0) - typescript: 4.9.5 + '@walletconnect/core@2.20.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': + dependencies: + '@walletconnect/heartbeat': 1.2.2 + '@walletconnect/jsonrpc-provider': 1.0.14 + '@walletconnect/jsonrpc-types': 1.0.4 + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/jsonrpc-ws-connection': 1.0.16(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@walletconnect/keyvaluestorage': 1.1.1(ioredis@5.8.2) + '@walletconnect/logger': 2.1.2 + '@walletconnect/relay-api': 1.0.11 + '@walletconnect/relay-auth': 1.1.0 + '@walletconnect/safe-json': 1.0.2 + '@walletconnect/time': 1.0.2 + '@walletconnect/types': 2.20.2(ioredis@5.8.2) + '@walletconnect/utils': 2.20.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@walletconnect/window-getters': 1.0.1 + es-toolkit: 1.33.0 + events: 3.3.0 + uint8arrays: 3.1.0 transitivePeerDependencies: - - supports-color + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - ioredis + - typescript + - uWebSockets.js + - utf-8-validate + - zod - '@typescript-eslint/scope-manager@8.50.0': + '@walletconnect/environment@1.0.1': dependencies: - '@typescript-eslint/types': 8.50.0 - '@typescript-eslint/visitor-keys': 8.50.0 + tslib: 1.14.1 - '@typescript-eslint/scope-manager@8.59.0': - dependencies: - '@typescript-eslint/types': 8.59.0 - '@typescript-eslint/visitor-keys': 8.59.0 + '@walletconnect/ethereum-provider@2.20.2(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': + dependencies: + '@reown/appkit': 1.7.3(@types/react@18.3.27)(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(react@18.3.1)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@walletconnect/jsonrpc-http-connection': 1.0.8(encoding@0.1.13) + '@walletconnect/jsonrpc-provider': 1.0.14 + '@walletconnect/jsonrpc-types': 1.0.4 + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/keyvaluestorage': 1.1.1(ioredis@5.8.2) + '@walletconnect/sign-client': 2.20.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@walletconnect/types': 2.20.2(ioredis@5.8.2) + '@walletconnect/universal-provider': 2.20.2(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@walletconnect/utils': 2.20.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + events: 3.3.0 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@types/react' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - encoding + - ioredis + - react + - typescript + - uWebSockets.js + - utf-8-validate + - zod - '@typescript-eslint/tsconfig-utils@8.50.0(typescript@5.9.3)': + '@walletconnect/events@1.0.1': dependencies: - typescript: 5.9.3 + keyvaluestorage-interface: 1.0.0 + tslib: 1.14.1 - '@typescript-eslint/tsconfig-utils@8.59.0(typescript@4.9.5)': + '@walletconnect/heartbeat@1.2.2': dependencies: - typescript: 4.9.5 + '@walletconnect/events': 1.0.1 + '@walletconnect/time': 1.0.2 + events: 3.3.0 - '@typescript-eslint/type-utils@8.50.0(eslint@9.39.2)(typescript@5.9.3)': + '@walletconnect/jsonrpc-http-connection@1.0.8(encoding@0.1.13)': dependencies: - '@typescript-eslint/types': 8.50.0 - '@typescript-eslint/typescript-estree': 8.50.0(typescript@5.9.3) - '@typescript-eslint/utils': 8.50.0(eslint@9.39.2)(typescript@5.9.3) - debug: 4.4.3(supports-color@5.5.0) - eslint: 9.39.2 - ts-api-utils: 2.5.0(typescript@5.9.3) - typescript: 5.9.3 + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/safe-json': 1.0.2 + cross-fetch: 3.2.0(encoding@0.1.13) + events: 3.3.0 transitivePeerDependencies: - - supports-color + - encoding - '@typescript-eslint/type-utils@8.59.0(eslint@9.39.4)(typescript@4.9.5)': + '@walletconnect/jsonrpc-provider@1.0.14': dependencies: - '@typescript-eslint/types': 8.59.0 - '@typescript-eslint/typescript-estree': 8.59.0(typescript@4.9.5) - '@typescript-eslint/utils': 8.59.0(eslint@9.39.4)(typescript@4.9.5) - debug: 4.4.3(supports-color@5.5.0) - eslint: 9.39.4 - ts-api-utils: 2.5.0(typescript@4.9.5) - typescript: 4.9.5 - transitivePeerDependencies: - - supports-color - - '@typescript-eslint/types@8.50.0': {} - - '@typescript-eslint/types@8.59.0': {} + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/safe-json': 1.0.2 + events: 3.3.0 - '@typescript-eslint/typescript-estree@8.50.0(typescript@5.9.3)': + '@walletconnect/jsonrpc-types@1.0.4': dependencies: - '@typescript-eslint/project-service': 8.50.0(typescript@5.9.3) - '@typescript-eslint/tsconfig-utils': 8.50.0(typescript@5.9.3) - '@typescript-eslint/types': 8.50.0 - '@typescript-eslint/visitor-keys': 8.50.0 - debug: 4.4.3(supports-color@5.5.0) - minimatch: 10.2.5 - semver: 7.7.4 - tinyglobby: 0.2.16 - ts-api-utils: 2.5.0(typescript@5.9.3) - typescript: 5.9.3 - transitivePeerDependencies: - - supports-color + events: 3.3.0 + keyvaluestorage-interface: 1.0.0 - '@typescript-eslint/typescript-estree@8.59.0(typescript@4.9.5)': - dependencies: - '@typescript-eslint/project-service': 8.59.0(typescript@4.9.5) - '@typescript-eslint/tsconfig-utils': 8.59.0(typescript@4.9.5) - '@typescript-eslint/types': 8.59.0 - '@typescript-eslint/visitor-keys': 8.59.0 - debug: 4.4.3(supports-color@5.5.0) - minimatch: 10.2.5 - semver: 7.7.4 - tinyglobby: 0.2.16 - ts-api-utils: 2.5.0(typescript@4.9.5) - typescript: 4.9.5 - transitivePeerDependencies: - - supports-color + '@walletconnect/jsonrpc-utils@1.0.8': + dependencies: + '@walletconnect/environment': 1.0.1 + '@walletconnect/jsonrpc-types': 1.0.4 + tslib: 1.14.1 - '@typescript-eslint/utils@8.50.0(eslint@9.39.2)(typescript@5.9.3)': + '@walletconnect/jsonrpc-ws-connection@1.0.16(bufferutil@4.1.0)(utf-8-validate@5.0.10)': dependencies: - '@eslint-community/eslint-utils': 4.9.1(eslint@9.39.2) - '@typescript-eslint/scope-manager': 8.50.0 - '@typescript-eslint/types': 8.50.0 - '@typescript-eslint/typescript-estree': 8.50.0(typescript@5.9.3) - eslint: 9.39.2 - typescript: 5.9.3 + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/safe-json': 1.0.2 + events: 3.3.0 + ws: 7.5.10(bufferutil@4.1.0)(utf-8-validate@5.0.10) transitivePeerDependencies: - - supports-color + - bufferutil + - utf-8-validate - '@typescript-eslint/utils@8.59.0(eslint@9.39.4)(typescript@4.9.5)': + '@walletconnect/keyvaluestorage@1.1.1(ioredis@5.8.2)': dependencies: - '@eslint-community/eslint-utils': 4.9.1(eslint@9.39.4) - '@typescript-eslint/scope-manager': 8.59.0 - '@typescript-eslint/types': 8.59.0 - '@typescript-eslint/typescript-estree': 8.59.0(typescript@4.9.5) - eslint: 9.39.4 - typescript: 4.9.5 + '@walletconnect/safe-json': 1.0.2 + idb-keyval: 6.2.1 + unstorage: 1.10.2(idb-keyval@6.2.1)(ioredis@5.8.2) transitivePeerDependencies: - - supports-color + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@upstash/redis' + - '@vercel/kv' + - ioredis + - uWebSockets.js - '@typescript-eslint/visitor-keys@8.50.0': + '@walletconnect/logger@2.1.2': dependencies: - '@typescript-eslint/types': 8.50.0 - eslint-visitor-keys: 4.2.1 + '@walletconnect/safe-json': 1.0.2 + pino: 7.11.0 - '@typescript-eslint/visitor-keys@8.59.0': + '@walletconnect/relay-api@1.0.11': dependencies: - '@typescript-eslint/types': 8.59.0 - eslint-visitor-keys: 5.0.1 + '@walletconnect/jsonrpc-types': 1.0.4 - '@vitest/coverage-v8@4.0.18(vitest@4.0.18(@types/node@25.3.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)))': + '@walletconnect/relay-auth@1.1.0': dependencies: - '@bcoe/v8-coverage': 1.0.2 - '@vitest/utils': 4.0.18 - ast-v8-to-istanbul: 0.3.11 - istanbul-lib-coverage: 3.2.2 - istanbul-lib-report: 3.0.1 - istanbul-reports: 3.2.0 - magicast: 0.5.1 - obug: 2.1.1 - std-env: 3.10.0 - tinyrainbow: 3.0.3 - vitest: 4.0.18(@types/node@25.3.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)) + '@noble/curves': 1.8.0 + '@noble/hashes': 1.7.0 + '@walletconnect/safe-json': 1.0.2 + '@walletconnect/time': 1.0.2 + uint8arrays: 3.1.1 - '@vitest/coverage-v8@4.0.18(vitest@4.0.18(@types/node@25.6.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)))': + '@walletconnect/safe-json@1.0.2': dependencies: - '@bcoe/v8-coverage': 1.0.2 - '@vitest/utils': 4.0.18 - ast-v8-to-istanbul: 0.3.11 - istanbul-lib-coverage: 3.2.2 - istanbul-lib-report: 3.0.1 - istanbul-reports: 3.2.0 - magicast: 0.5.1 - obug: 2.1.1 - std-env: 3.10.0 - tinyrainbow: 3.0.3 - vitest: 4.0.18(@types/node@25.6.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)) + tslib: 1.14.1 - '@vitest/expect@4.0.18': + '@walletconnect/sign-client@2.19.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': dependencies: - '@standard-schema/spec': 1.0.0 - '@types/chai': 5.2.3 - '@vitest/spy': 4.0.18 - '@vitest/utils': 4.0.18 - chai: 6.2.2 - tinyrainbow: 3.0.3 + '@walletconnect/core': 2.19.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@walletconnect/events': 1.0.1 + '@walletconnect/heartbeat': 1.2.2 + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/logger': 2.1.2 + '@walletconnect/time': 1.0.2 + '@walletconnect/types': 2.19.2(ioredis@5.8.2) + '@walletconnect/utils': 2.19.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + events: 3.3.0 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - ioredis + - typescript + - uWebSockets.js + - utf-8-validate + - zod - '@vitest/mocker@4.0.18(vite@7.3.0(@types/node@25.3.0))': + '@walletconnect/sign-client@2.20.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': dependencies: - '@vitest/spy': 4.0.18 - estree-walker: 3.0.3 - magic-string: 0.30.21 - optionalDependencies: - vite: 7.3.0(@types/node@25.3.0) + '@walletconnect/core': 2.20.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@walletconnect/events': 1.0.1 + '@walletconnect/heartbeat': 1.2.2 + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/logger': 2.1.2 + '@walletconnect/time': 1.0.2 + '@walletconnect/types': 2.20.2(ioredis@5.8.2) + '@walletconnect/utils': 2.20.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + events: 3.3.0 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - ioredis + - typescript + - uWebSockets.js + - utf-8-validate + - zod - '@vitest/mocker@4.0.18(vite@7.3.0(@types/node@25.6.0))': + '@walletconnect/time@1.0.2': dependencies: - '@vitest/spy': 4.0.18 - estree-walker: 3.0.3 - magic-string: 0.30.21 - optionalDependencies: - vite: 7.3.0(@types/node@25.6.0) + tslib: 1.14.1 - '@vitest/pretty-format@4.0.18': + '@walletconnect/types@2.19.2(ioredis@5.8.2)': dependencies: - tinyrainbow: 3.0.3 + '@walletconnect/events': 1.0.1 + '@walletconnect/heartbeat': 1.2.2 + '@walletconnect/jsonrpc-types': 1.0.4 + '@walletconnect/keyvaluestorage': 1.1.1(ioredis@5.8.2) + '@walletconnect/logger': 2.1.2 + events: 3.3.0 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@upstash/redis' + - '@vercel/kv' + - ioredis + - uWebSockets.js + + '@walletconnect/types@2.20.2(ioredis@5.8.2)': + dependencies: + '@walletconnect/events': 1.0.1 + '@walletconnect/heartbeat': 1.2.2 + '@walletconnect/jsonrpc-types': 1.0.4 + '@walletconnect/keyvaluestorage': 1.1.1(ioredis@5.8.2) + '@walletconnect/logger': 2.1.2 + events: 3.3.0 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@upstash/redis' + - '@vercel/kv' + - ioredis + - uWebSockets.js + + '@walletconnect/universal-provider@2.19.2(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': + dependencies: + '@walletconnect/events': 1.0.1 + '@walletconnect/jsonrpc-http-connection': 1.0.8(encoding@0.1.13) + '@walletconnect/jsonrpc-provider': 1.0.14 + '@walletconnect/jsonrpc-types': 1.0.4 + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/keyvaluestorage': 1.1.1(ioredis@5.8.2) + '@walletconnect/logger': 2.1.2 + '@walletconnect/sign-client': 2.19.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@walletconnect/types': 2.19.2(ioredis@5.8.2) + '@walletconnect/utils': 2.19.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + es-toolkit: 1.33.0 + events: 3.3.0 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - encoding + - ioredis + - typescript + - uWebSockets.js + - utf-8-validate + - zod + + '@walletconnect/universal-provider@2.20.2(bufferutil@4.1.0)(encoding@0.1.13)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': + dependencies: + '@walletconnect/events': 1.0.1 + '@walletconnect/jsonrpc-http-connection': 1.0.8(encoding@0.1.13) + '@walletconnect/jsonrpc-provider': 1.0.14 + '@walletconnect/jsonrpc-types': 1.0.4 + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/keyvaluestorage': 1.1.1(ioredis@5.8.2) + '@walletconnect/logger': 2.1.2 + '@walletconnect/sign-client': 2.20.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + '@walletconnect/types': 2.20.2(ioredis@5.8.2) + '@walletconnect/utils': 2.20.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + es-toolkit: 1.33.0 + events: 3.3.0 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - encoding + - ioredis + - typescript + - uWebSockets.js + - utf-8-validate + - zod + + '@walletconnect/utils@2.19.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': + dependencies: + '@noble/ciphers': 1.2.1 + '@noble/curves': 1.8.1 + '@noble/hashes': 1.7.1 + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/keyvaluestorage': 1.1.1(ioredis@5.8.2) + '@walletconnect/relay-api': 1.0.11 + '@walletconnect/relay-auth': 1.1.0 + '@walletconnect/safe-json': 1.0.2 + '@walletconnect/time': 1.0.2 + '@walletconnect/types': 2.19.2(ioredis@5.8.2) + '@walletconnect/window-getters': 1.0.1 + '@walletconnect/window-metadata': 1.0.1 + bs58: 6.0.0 + detect-browser: 5.3.0 + query-string: 7.1.3 + uint8arrays: 3.1.0 + viem: 2.23.2(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - ioredis + - typescript + - uWebSockets.js + - utf-8-validate + - zod + + '@walletconnect/utils@2.20.2(bufferutil@4.1.0)(ioredis@5.8.2)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20)': + dependencies: + '@noble/ciphers': 1.2.1 + '@noble/curves': 1.8.1 + '@noble/hashes': 1.7.1 + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/keyvaluestorage': 1.1.1(ioredis@5.8.2) + '@walletconnect/relay-api': 1.0.11 + '@walletconnect/relay-auth': 1.1.0 + '@walletconnect/safe-json': 1.0.2 + '@walletconnect/time': 1.0.2 + '@walletconnect/types': 2.20.2(ioredis@5.8.2) + '@walletconnect/window-getters': 1.0.1 + '@walletconnect/window-metadata': 1.0.1 + bs58: 6.0.0 + detect-browser: 5.3.0 + query-string: 7.1.3 + uint8arrays: 3.1.0 + viem: 2.23.2(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20) + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - ioredis + - typescript + - uWebSockets.js + - utf-8-validate + - zod - '@vitest/runner@4.0.18': + '@walletconnect/window-getters@1.0.1': dependencies: - '@vitest/utils': 4.0.18 - pathe: 2.0.3 + tslib: 1.14.1 - '@vitest/snapshot@4.0.18': + '@walletconnect/window-metadata@1.0.1': dependencies: - '@vitest/pretty-format': 4.0.18 - magic-string: 0.30.21 - pathe: 2.0.3 + '@walletconnect/window-getters': 1.0.1 + tslib: 1.14.1 - '@vitest/spy@4.0.18': {} + abbrev@2.0.0: {} - '@vitest/utils@4.0.18': - dependencies: - '@vitest/pretty-format': 4.0.18 - tinyrainbow: 3.0.3 + abbrev@3.0.1: {} - abbrev@1.0.9: {} + abitype@1.0.0(typescript@5.9.3)(zod@3.25.20): + optionalDependencies: + typescript: 5.9.3 + zod: 3.25.20 - abitype@1.1.0(typescript@5.9.3)(zod@4.2.0): + abitype@1.0.2(typescript@5.9.3)(zod@3.25.20): optionalDependencies: typescript: 5.9.3 - zod: 4.2.0 + zod: 3.25.20 - abitype@1.2.2(typescript@5.9.3)(zod@4.2.0): + abitype@1.0.4(typescript@5.9.3)(zod@3.25.20): optionalDependencies: typescript: 5.9.3 - zod: 4.2.0 + zod: 3.25.20 - abortcontroller-polyfill@1.7.8: {} + abitype@1.0.5(typescript@5.9.3)(zod@3.25.20): + optionalDependencies: + typescript: 5.9.3 + zod: 3.25.20 - abstract-level@1.0.3: - dependencies: - buffer: 6.0.3 - catering: 2.1.1 - is-buffer: 2.0.5 - level-supports: 4.0.1 - level-transcoder: 1.0.1 - module-error: 1.0.2 - queue-microtask: 1.2.3 + abitype@1.0.8(typescript@5.8.3)(zod@3.25.20): + optionalDependencies: + typescript: 5.8.3 + zod: 3.25.20 - abstract-leveldown@2.6.3: - dependencies: - xtend: 4.0.2 + abitype@1.0.8(typescript@5.9.3)(zod@3.25.20): + optionalDependencies: + typescript: 5.9.3 + zod: 3.25.20 - abstract-leveldown@2.7.2: - dependencies: - xtend: 4.0.2 + abitype@1.2.3(typescript@5.8.3)(zod@3.25.20): + optionalDependencies: + typescript: 5.8.3 + zod: 3.25.20 - abstract-leveldown@6.2.3: - dependencies: - buffer: 5.7.1 - immediate: 3.2.3 - level-concat-iterator: 2.0.1 - level-supports: 1.0.1 - xtend: 4.0.2 + abitype@1.2.3(typescript@5.9.3)(zod@3.22.4): + optionalDependencies: + typescript: 5.9.3 + zod: 3.22.4 - abstract-leveldown@6.3.0: - dependencies: - buffer: 5.7.1 - immediate: 3.3.0 - level-concat-iterator: 2.0.1 - level-supports: 1.0.1 - xtend: 4.0.2 + abitype@1.2.3(typescript@5.9.3)(zod@3.25.20): + optionalDependencies: + typescript: 5.9.3 + zod: 3.25.20 - abstract-leveldown@7.2.0: + abort-controller@3.0.0: dependencies: - buffer: 6.0.3 - catering: 2.1.1 - is-buffer: 2.0.5 - level-concat-iterator: 3.1.0 - level-supports: 2.1.0 - queue-microtask: 1.2.3 + event-target-shim: 5.0.1 - accepts@1.3.8: + acorn-import-attributes@1.9.5(acorn@8.15.0): dependencies: - mime-types: 2.1.35 - negotiator: 0.6.3 + acorn: 8.15.0 - acorn-jsx@5.3.2(acorn@8.15.0): + acorn-walk@8.3.4: dependencies: acorn: 8.15.0 - acorn-walk@8.3.5: - dependencies: - acorn: 8.16.0 + acorn@8.11.3: {} acorn@8.15.0: {} - acorn@8.16.0: {} - adm-zip@0.4.16: {} - aes-js@3.0.0: {} - aes-js@4.0.0-beta.5: {} agent-base@6.0.2: dependencies: - debug: 4.4.3(supports-color@5.5.0) + debug: 4.4.3 transitivePeerDependencies: - supports-color @@ -12855,44 +17938,48 @@ snapshots: clean-stack: 2.2.0 indent-string: 4.0.0 - ajv@6.15.0: + ajv@8.6.3: dependencies: fast-deep-equal: 3.1.3 - fast-json-stable-stringify: 2.1.0 - json-schema-traverse: 0.4.1 - uri-js: 4.4.1 - - ajv@8.20.0: - dependencies: - fast-deep-equal: 3.1.3 - fast-uri: 3.1.0 json-schema-traverse: 1.0.0 require-from-string: 2.0.2 + uri-js: 4.4.1 - amazon-cognito-identity-js@6.3.16: + algoliasearch@5.12.0: dependencies: - '@aws-crypto/sha256-js': 1.2.2 - buffer: 4.9.2 - fast-base64-decode: 1.0.0 - isomorphic-unfetch: 3.1.0 - js-cookie: 2.2.1 + '@algolia/client-abtesting': 5.12.0 + '@algolia/client-analytics': 5.12.0 + '@algolia/client-common': 5.12.0 + '@algolia/client-insights': 5.12.0 + '@algolia/client-personalization': 5.12.0 + '@algolia/client-query-suggestions': 5.12.0 + '@algolia/client-search': 5.12.0 + '@algolia/ingestion': 1.12.0 + '@algolia/monitoring': 1.12.0 + '@algolia/recommend': 5.12.0 + '@algolia/requester-browser-xhr': 5.12.0 + '@algolia/requester-fetch': 5.12.0 + '@algolia/requester-node-http': 5.12.0 - amdefine@1.0.1: - optional: true + alien-signals@0.2.0: {} + + alien-signals@3.1.2: {} ansi-align@3.0.1: dependencies: string-width: 4.2.3 + ansi-colors@4.1.1: {} + ansi-colors@4.1.3: {} ansi-escapes@4.3.2: dependencies: type-fest: 0.21.3 - ansi-regex@2.1.1: {} - - ansi-regex@3.0.1: {} + ansi-escapes@7.0.0: + dependencies: + environment: 1.1.0 ansi-regex@5.0.1: {} @@ -12906,22 +17993,43 @@ snapshots: dependencies: color-convert: 2.0.1 - ansi-styles@6.2.3: {} + ansi-styles@5.2.0: {} - antlr4@4.13.2: {} + ansi-styles@6.2.1: {} - antlr4ts@0.5.0-alpha.4: {} + ansis@4.2.0: {} + + any-promise@1.3.0: {} anymatch@3.1.3: dependencies: normalize-path: 3.0.0 - picomatch: 2.3.2 + picomatch: 2.3.1 + + archiver-utils@5.0.2: + dependencies: + glob: 10.5.0 + graceful-fs: 4.2.11 + is-stream: 2.0.1 + lazystream: 1.0.1 + lodash: 4.17.21 + normalize-path: 3.0.0 + readable-stream: 4.7.0 - append-transform@2.0.0: + archiver@7.0.1: dependencies: - default-require-extensions: 3.0.1 + archiver-utils: 5.0.2 + async: 3.2.6 + buffer-crc32: 1.0.0 + readable-stream: 4.7.0 + readdir-glob: 1.1.3 + tar-stream: 3.1.7 + zip-stream: 6.0.1 + transitivePeerDependencies: + - bare-abort-controller + - react-native-b4a - archy@1.0.0: {} + arg@4.1.0: {} arg@4.1.3: {} @@ -12931,126 +18039,47 @@ snapshots: argparse@2.0.1: {} - array-back@3.1.0: {} - - array-back@4.0.2: {} - - array-buffer-byte-length@1.0.2: + aria-hidden@1.2.6: dependencies: - call-bound: 1.0.4 - is-array-buffer: 3.0.5 + tslib: 2.8.1 - array-flatten@1.1.1: {} + aria-query@5.3.0: + dependencies: + dequal: 2.0.3 - array-includes@3.1.9: + array-union@1.0.2: dependencies: - call-bind: 1.0.9 - call-bound: 1.0.4 - define-properties: 1.2.1 - es-abstract: 1.24.2 - es-object-atoms: 1.1.1 - get-intrinsic: 1.3.0 - is-string: 1.1.1 - math-intrinsics: 1.1.0 + array-uniq: 1.0.3 array-union@2.1.0: {} array-uniq@1.0.3: {} - array.prototype.findlast@1.2.5: - dependencies: - call-bind: 1.0.8 - define-properties: 1.2.1 - es-abstract: 1.24.1 - es-errors: 1.3.0 - es-object-atoms: 1.1.1 - es-shim-unscopables: 1.1.0 - - array.prototype.findlastindex@1.2.6: - dependencies: - call-bind: 1.0.9 - call-bound: 1.0.4 - define-properties: 1.2.1 - es-abstract: 1.24.2 - es-errors: 1.3.0 - es-object-atoms: 1.1.1 - es-shim-unscopables: 1.1.0 - - array.prototype.flat@1.3.3: - dependencies: - call-bind: 1.0.9 - define-properties: 1.2.1 - es-abstract: 1.24.2 - es-shim-unscopables: 1.1.0 - - array.prototype.flatmap@1.3.3: - dependencies: - call-bind: 1.0.9 - define-properties: 1.2.1 - es-abstract: 1.24.2 - es-shim-unscopables: 1.1.0 - - array.prototype.tosorted@1.1.4: - dependencies: - call-bind: 1.0.8 - define-properties: 1.2.1 - es-abstract: 1.24.1 - es-errors: 1.3.0 - es-shim-unscopables: 1.1.0 - - arraybuffer.prototype.slice@1.0.4: - dependencies: - array-buffer-byte-length: 1.0.2 - call-bind: 1.0.9 - define-properties: 1.2.1 - es-abstract: 1.24.2 - es-errors: 1.3.0 - get-intrinsic: 1.3.0 - is-array-buffer: 3.0.5 - - asap@2.0.6: {} - - asn1@0.2.6: - dependencies: - safer-buffer: 2.1.2 - - asn1js@3.0.7: - dependencies: - pvtsutils: 1.3.6 - pvutils: 1.1.5 - tslib: 2.8.1 - - assert-plus@1.0.0: {} - - assertion-error@1.1.0: {} - assertion-error@2.0.1: {} - ast-parents@0.0.1: {} - - ast-types@0.13.4: + ast-kit@2.2.0: dependencies: - tslib: 2.8.1 + '@babel/parser': 7.28.5 + pathe: 2.0.3 - ast-v8-to-istanbul@0.3.11: + ast-v8-to-istanbul@0.3.9: dependencies: '@jridgewell/trace-mapping': 0.3.31 estree-walker: 3.0.3 - js-tokens: 10.0.0 + js-tokens: 9.0.1 - astral-regex@2.0.0: {} - - async-eventemitter@0.2.4: + ast-walker-scope@0.8.3: dependencies: - async: 3.2.6 + '@babel/parser': 7.28.5 + ast-kit: 2.2.0 - async-function@1.0.0: {} + async-listen@1.2.0: {} - async-mutex@0.2.6: - dependencies: - tslib: 2.8.1 + async-listen@3.0.0: {} - async-mutex@0.5.0: + async-listen@3.0.1: {} + + async-mutex@0.2.6: dependencies: tslib: 2.8.1 @@ -13060,109 +18089,70 @@ snapshots: dependencies: retry: 0.13.1 - async@1.5.2: {} + async-sema@3.1.1: {} async@3.2.6: {} - asynckit@0.4.0: {} + atomic-sleep@1.0.0: {} - available-typed-arrays@1.0.7: + autoprefixer@10.4.23(postcss@8.5.6): dependencies: - possible-typed-array-names: 1.1.0 - - aws-sign2@0.7.0: {} - - aws4@1.13.2: {} + browserslist: 4.28.1 + caniuse-lite: 1.0.30001761 + fraction.js: 5.3.4 + picocolors: 1.1.1 + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - axios@1.15.2(debug@4.4.3): + available-typed-arrays@1.0.7: dependencies: - follow-redirects: 1.16.0(debug@4.4.3) - form-data: 4.0.5 - proxy-from-env: 2.1.0 - transitivePeerDependencies: - - debug - - backo2@1.0.2: {} + possible-typed-array-names: 1.1.0 - backoff@2.5.0: - dependencies: - precond: 0.2.3 + b4a@1.7.3: {} balanced-match@1.0.2: {} - balanced-match@4.0.4: {} + bare-events@2.8.2: {} - base-x@3.0.11: + base-x@3.0.9: dependencies: safe-buffer: 5.2.1 - base64-arraybuffer-es6@0.7.0: {} - - base64-arraybuffer@0.1.5: {} + base-x@5.0.1: {} base64-js@1.5.1: {} - baseline-browser-mapping@2.10.21: {} - - basic-ftp@5.3.0: {} - - bcrypt-pbkdf@1.0.2: - dependencies: - tweetnacl: 0.14.5 - - bech32@1.1.4: {} + baseline-browser-mapping@2.9.11: {} better-path-resolve@1.0.0: dependencies: is-windows: 1.0.2 - bignumber.js@7.2.1: {} - - bignumber.js@9.3.1: {} + big.js@6.2.2: {} - binary-extensions@2.3.0: {} + binary-extensions@2.2.0: {} - bip39@3.0.4: + bindings@1.5.0: dependencies: - '@types/node': 11.11.6 - create-hash: 1.2.0 - pbkdf2: 3.1.5 - randombytes: 2.1.0 + file-uri-to-path: 1.0.0 - bl@4.1.0: - dependencies: - buffer: 5.7.1 - inherits: 2.0.4 - readable-stream: 3.6.2 + birpc@0.2.19: {} + + birpc@2.9.0: {} blakejs@1.2.1: {} - bluebird@3.7.2: {} + bn.js@4.12.0: {} - bn-chai@1.0.1(chai@4.5.0): - dependencies: - chai: 4.5.0 + bn.js@4.12.2: {} - bn.js@5.2.3: {} + bn.js@5.2.1: {} - body-parser@1.20.5: - dependencies: - bytes: 3.1.2 - content-type: 1.0.5 - debug: 2.6.9 - depd: 2.0.0 - destroy: 1.2.0 - http-errors: 2.0.1 - iconv-lite: 0.4.24 - on-finished: 2.4.1 - qs: 6.15.1 - raw-body: 2.5.3 - type-is: 1.6.18 - unpipe: 1.0.0 - transitivePeerDependencies: - - supports-color + bn.js@5.2.2: {} - bowser@2.14.1: {} + boolbase@1.0.0: {} + + bowser@2.13.1: {} boxen@5.1.2: dependencies: @@ -13175,18 +18165,22 @@ snapshots: widest-line: 3.1.0 wrap-ansi: 7.0.0 - brace-expansion@1.1.14: + brace-expansion@1.1.11: dependencies: balanced-match: 1.0.2 concat-map: 0.0.1 - brace-expansion@2.1.0: + brace-expansion@2.0.1: + dependencies: + balanced-match: 1.0.2 + + brace-expansion@2.0.2: dependencies: balanced-match: 1.0.2 - brace-expansion@5.0.5: + braces@3.0.2: dependencies: - balanced-match: 4.0.4 + fill-range: 7.0.1 braces@3.0.3: dependencies: @@ -13194,38 +18188,39 @@ snapshots: brorand@1.1.0: {} - brotli-wasm@3.0.1: {} - browser-stdout@1.3.1: {} browserify-aes@1.2.0: dependencies: buffer-xor: 1.0.3 - cipher-base: 1.0.7 + cipher-base: 1.0.4 create-hash: 1.2.0 evp_bytestokey: 1.0.3 inherits: 2.0.4 safe-buffer: 5.2.1 + browserslist@4.23.0: + dependencies: + caniuse-lite: 1.0.30001761 + electron-to-chromium: 1.4.757 + node-releases: 2.0.14 + update-browserslist-db: 1.0.15(browserslist@4.23.0) + browserslist@4.28.1: dependencies: - baseline-browser-mapping: 2.10.21 - caniuse-lite: 1.0.30001790 + baseline-browser-mapping: 2.9.11 + caniuse-lite: 1.0.30001761 electron-to-chromium: 1.5.267 node-releases: 2.0.27 - update-browserslist-db: 1.2.2(browserslist@4.28.1) + update-browserslist-db: 1.2.3(browserslist@4.28.1) - browserslist@4.28.2: + bs58@4.0.1: dependencies: - baseline-browser-mapping: 2.10.21 - caniuse-lite: 1.0.30001790 - electron-to-chromium: 1.5.344 - node-releases: 2.0.38 - update-browserslist-db: 1.2.3(browserslist@4.28.2) + base-x: 3.0.9 - bs58@4.0.1: + bs58@6.0.0: dependencies: - base-x: 3.0.11 + base-x: 5.0.1 bs58check@2.1.2: dependencies: @@ -13233,87 +18228,91 @@ snapshots: create-hash: 1.2.0 safe-buffer: 5.2.1 - btoa@1.2.1: {} + buffer-crc32@0.2.13: {} - buffer-from@1.1.2: {} + buffer-crc32@1.0.0: {} - buffer-to-arraybuffer@0.0.5: {} + buffer-from@1.1.2: {} buffer-xor@1.0.3: {} - buffer-xor@2.0.2: - dependencies: - safe-buffer: 5.2.1 - - buffer@4.9.2: - dependencies: - base64-js: 1.5.1 - ieee754: 1.2.1 - isarray: 1.0.0 - - buffer@5.7.1: - dependencies: - base64-js: 1.5.1 - ieee754: 1.2.1 - buffer@6.0.3: dependencies: base64-js: 1.5.1 ieee754: 1.2.1 - bufferutil@4.0.5: + bufferutil@4.0.8: dependencies: - node-gyp-build: 4.8.4 - optional: true + node-gyp-build: 4.6.0 - bufferutil@4.0.7: + bufferutil@4.1.0: dependencies: node-gyp-build: 4.8.4 - optional: true - bufferutil@4.1.0: + bun-types@1.1.29: dependencies: - node-gyp-build: 4.8.4 + '@types/node': 20.12.14 + '@types/ws': 8.5.10 - bytes@3.1.2: {} + bun@1.1.30: + optionalDependencies: + '@oven/bun-darwin-aarch64': 1.1.30 + '@oven/bun-darwin-x64': 1.1.30 + '@oven/bun-darwin-x64-baseline': 1.1.30 + '@oven/bun-linux-aarch64': 1.1.30 + '@oven/bun-linux-x64': 1.1.30 + '@oven/bun-linux-x64-baseline': 1.1.30 + '@oven/bun-windows-x64': 1.1.30 + '@oven/bun-windows-x64-baseline': 1.1.30 - bytestreamjs@2.0.1: {} + bundle-name@4.1.0: + dependencies: + run-applescript: 7.1.0 - cacache@18.0.4: + bundle-require@5.1.0(esbuild@0.27.2): dependencies: - '@npmcli/fs': 3.1.1 - fs-minipass: 3.0.3 - glob: 10.5.0 - lru-cache: 10.4.3 - minipass: 7.1.3 - minipass-collect: 2.0.1 - minipass-flush: 1.0.7 - minipass-pipeline: 1.2.4 - p-map: 4.0.0 - ssri: 10.0.6 - tar: 7.5.13 - unique-filename: 3.0.0 + esbuild: 0.27.2 + load-tsconfig: 0.2.5 - cacheable-lookup@5.0.4: {} + bytes@3.1.0: {} - cacheable-lookup@6.1.0: {} + bytes@3.1.2: {} - cacheable-request@7.0.4: + c12@3.3.3(magicast@0.3.5): dependencies: - clone-response: 1.0.3 - get-stream: 5.2.0 - http-cache-semantics: 4.2.0 - keyv: 4.5.4 - lowercase-keys: 2.0.0 - normalize-url: 6.1.0 - responselike: 2.0.1 + chokidar: 5.0.0 + confbox: 0.2.2 + defu: 6.1.4 + dotenv: 17.2.3 + exsolve: 1.0.8 + giget: 2.0.0 + jiti: 2.6.1 + ohash: 2.0.11 + pathe: 2.0.3 + perfect-debounce: 2.0.0 + pkg-types: 2.3.0 + rc9: 2.1.2 + optionalDependencies: + magicast: 0.3.5 + + c12@3.3.3(magicast@0.5.1): + dependencies: + chokidar: 5.0.0 + confbox: 0.2.2 + defu: 6.1.4 + dotenv: 17.2.3 + exsolve: 1.0.8 + giget: 2.0.0 + jiti: 2.6.1 + ohash: 2.0.11 + pathe: 2.0.3 + perfect-debounce: 2.0.0 + pkg-types: 2.3.0 + rc9: 2.1.2 + optionalDependencies: + magicast: 0.5.1 - caching-transform@4.0.0: - dependencies: - hasha: 5.2.2 - make-dir: 3.1.0 - package-hash: 4.0.0 - write-file-atomic: 3.0.3 + cac@6.7.14: {} call-bind-apply-helpers@1.0.2: dependencies: @@ -13327,75 +18326,33 @@ snapshots: get-intrinsic: 1.3.0 set-function-length: 1.2.2 - call-bind@1.0.9: - dependencies: - call-bind-apply-helpers: 1.0.2 - es-define-property: 1.0.1 - get-intrinsic: 1.3.0 - set-function-length: 1.2.2 - call-bound@1.0.4: dependencies: call-bind-apply-helpers: 1.0.2 get-intrinsic: 1.3.0 - callsites@3.1.0: {} - - camel-case@3.0.0: - dependencies: - no-case: 2.3.2 - upper-case: 1.1.3 - camelcase@5.3.1: {} camelcase@6.3.0: {} - caniuse-lite@1.0.30001790: {} - - caseless@0.12.0: {} - - catering@2.1.1: {} - - cbor2@1.12.0: {} - - cbor@10.0.12: - dependencies: - nofilter: 3.1.0 - - cbor@8.1.0: - dependencies: - nofilter: 3.1.0 - - cbor@9.0.2: - dependencies: - nofilter: 3.1.0 - - chai-as-promised@7.1.2(chai@4.5.0): + caniuse-api@3.0.0: dependencies: - chai: 4.5.0 - check-error: 1.0.3 - - chai-bignumber@3.1.0: {} + browserslist: 4.28.1 + caniuse-lite: 1.0.30001761 + lodash.memoize: 4.1.2 + lodash.uniq: 4.5.0 - chai-shallow-deep-equal@1.4.6(chai@4.5.0): - dependencies: - chai: 4.5.0 + caniuse-lite@1.0.30001761: {} - chai-string@1.6.0(chai@4.5.0): - dependencies: - chai: 4.5.0 + ccount@2.0.1: {} - chai@4.5.0: + chai@5.2.0: dependencies: - assertion-error: 1.1.0 - check-error: 1.0.3 - deep-eql: 4.1.4 - get-func-name: 2.0.2 - loupe: 2.3.7 - pathval: 1.1.1 - type-detect: 4.1.0 - - chai@6.2.2: {} + assertion-error: 2.0.1 + check-error: 2.1.1 + deep-eql: 5.0.2 + loupe: 3.1.3 + pathval: 2.0.0 chalk@2.4.2: dependencies: @@ -13403,59 +18360,45 @@ snapshots: escape-string-regexp: 1.0.5 supports-color: 5.5.0 - chalk@3.0.0: - dependencies: - ansi-styles: 4.3.0 - supports-color: 7.2.0 - chalk@4.1.2: dependencies: ansi-styles: 4.3.0 supports-color: 7.2.0 - chalk@5.6.2: {} - - change-case@3.1.0: - dependencies: - camel-case: 3.0.0 - constant-case: 2.0.0 - dot-case: 2.1.1 - header-case: 1.0.1 - is-lower-case: 1.1.3 - is-upper-case: 1.1.2 - lower-case: 1.1.4 - lower-case-first: 1.0.2 - no-case: 2.3.2 - param-case: 2.1.1 - pascal-case: 2.0.1 - path-case: 2.1.1 - sentence-case: 2.1.1 - snake-case: 2.1.0 - swap-case: 1.1.2 - title-case: 2.1.1 - upper-case: 1.1.3 - upper-case-first: 1.1.2 + chalk@5.3.0: {} + + change-case@5.4.4: {} + + char-regex@1.0.2: {} + + character-entities-html4@2.1.0: {} + + character-entities-legacy@3.0.0: {} + + character-entities@2.0.2: {} chardet@0.7.0: {} chardet@2.1.1: {} - charenc@0.0.2: {} - - check-error@1.0.3: - dependencies: - get-func-name: 2.0.2 + check-error@2.1.1: {} - checkpoint-store@1.1.0: + chokidar@3.5.3: dependencies: - functional-red-black-tree: 1.0.1 - - child_process@1.0.2: {} + anymatch: 3.1.3 + braces: 3.0.2 + glob-parent: 5.1.2 + is-binary-path: 2.1.0 + is-glob: 4.0.3 + normalize-path: 3.0.0 + readdirp: 3.6.0 + optionalDependencies: + fsevents: 2.3.3 chokidar@3.6.0: dependencies: anymatch: 3.1.3 - braces: 3.0.3 + braces: 3.0.2 glob-parent: 5.1.2 is-binary-path: 2.1.0 is-glob: 4.0.3 @@ -13464,62 +18407,73 @@ snapshots: optionalDependencies: fsevents: 2.3.3 + chokidar@4.0.0: + dependencies: + readdirp: 4.1.2 + chokidar@4.0.3: dependencies: readdirp: 4.1.2 + chokidar@5.0.0: + dependencies: + readdirp: 5.0.0 + + chownr@2.0.0: {} + chownr@3.0.0: {} ci-info@2.0.0: {} - cids@0.7.5: - dependencies: - buffer: 5.7.1 - class-is: 1.1.0 - multibase: 0.6.1 - multicodec: 1.0.4 - multihashes: 0.4.21 + ci-info@3.9.0: {} - cipher-base@1.0.7: + cipher-base@1.0.4: dependencies: inherits: 2.0.4 safe-buffer: 5.2.1 - to-buffer: 1.2.2 - class-is@1.1.0: {} + citty@0.1.6: + dependencies: + consola: 3.4.2 + + cjs-module-lexer@1.2.3: {} + + cjs-module-lexer@1.4.1: {} + + class-variance-authority@0.7.1: + dependencies: + clsx: 2.1.1 clean-stack@2.2.0: {} cli-boxes@2.2.1: {} - cli-cursor@3.1.0: + cli-highlight@2.1.11: dependencies: - restore-cursor: 3.1.0 + chalk: 4.1.2 + highlight.js: 10.7.3 + mz: 2.7.0 + parse5: 5.1.1 + parse5-htmlparser2-tree-adapter: 6.0.1 + yargs: 16.2.0 cli-spinners@2.9.2: {} - cli-table3@0.5.1: - dependencies: - object-assign: 4.1.1 - string-width: 2.1.1 - optionalDependencies: - colors: 1.4.0 - cli-table3@0.6.5: dependencies: string-width: 4.2.3 optionalDependencies: '@colors/colors': 1.5.0 - cli-width@3.0.0: {} + cli-width@4.1.0: {} client-only@0.0.1: {} - cliui@3.2.0: + clipboardy@4.0.0: dependencies: - string-width: 1.0.2 - strip-ansi: 3.0.1 - wrap-ansi: 2.1.0 + execa: 8.0.1 + is-wsl: 3.1.0 + is64bit: 2.0.0 cliui@6.0.0: dependencies: @@ -13539,21 +18493,16 @@ snapshots: strip-ansi: 6.0.1 wrap-ansi: 7.0.0 - cliui@9.0.1: - dependencies: - string-width: 7.2.0 - strip-ansi: 7.1.2 - wrap-ansi: 9.0.2 + clone@1.0.4: + optional: true - clone-response@1.0.3: - dependencies: - mimic-response: 1.0.1 + clsx@1.2.1: {} - clone@1.0.4: {} + clsx@2.1.1: {} - clone@2.1.2: {} + cluster-key-slot@1.1.2: {} - code-point-at@1.1.0: {} + code-block-writer@10.1.1: {} color-convert@1.9.3: dependencies: @@ -13567,151 +18516,113 @@ snapshots: color-name@1.1.4: {} - colors@1.4.0: {} - - combined-stream@1.0.8: - dependencies: - delayed-stream: 1.0.0 + colord@2.9.3: {} - command-exists@1.2.9: {} + colorette@2.0.20: {} - command-line-args@5.2.1: - dependencies: - array-back: 3.1.0 - find-replace: 3.0.0 - lodash.camelcase: 4.3.0 - typical: 4.0.0 + comma-separated-tokens@2.0.3: {} - command-line-usage@6.1.3: - dependencies: - array-back: 4.0.2 - chalk: 2.4.2 - table-layout: 1.0.2 - typical: 5.2.0 + command-exists@1.2.9: {} commander@10.0.1: {} - commander@8.3.0: {} + commander@11.1.0: {} - commander@9.5.0: {} + commander@2.20.3: {} - common-tags@1.8.2: {} + commander@3.0.2: {} - commondir@1.0.1: {} + commander@4.1.1: {} - compare-versions@6.1.1: {} + commander@7.2.0: {} - concat-map@0.0.1: {} + commondir@1.0.1: {} - concat-stream@1.6.2: - dependencies: - buffer-from: 1.1.2 - inherits: 2.0.4 - readable-stream: 2.3.8 - typedarray: 0.0.6 + compatx@0.2.0: {} - concurrently@7.6.0: + compress-commons@6.0.2: dependencies: - chalk: 4.1.2 - date-fns: 2.30.0 - lodash: 4.18.1 - rxjs: 7.8.2 - shell-quote: 1.8.3 - spawn-command: 0.0.2 - supports-color: 8.1.1 - tree-kill: 1.2.2 - yargs: 17.7.2 + crc-32: 1.2.2 + crc32-stream: 6.0.0 + is-stream: 2.0.1 + normalize-path: 3.0.0 + readable-stream: 4.7.0 - concurrently@9.2.1: - dependencies: - chalk: 4.1.2 - rxjs: 7.8.2 - shell-quote: 1.8.3 - supports-color: 8.1.1 - tree-kill: 1.2.2 - yargs: 17.7.2 + computeds@0.0.1: {} - connect@3.7.0: - dependencies: - debug: 2.6.9 - finalhandler: 1.1.2 - parseurl: 1.3.3 - utils-merge: 1.0.1 - transitivePeerDependencies: - - supports-color + concat-map@0.0.1: {} - constant-case@2.0.0: - dependencies: - snake-case: 2.1.0 - upper-case: 1.1.3 + confbox@0.1.7: {} - content-disposition@0.5.4: - dependencies: - safe-buffer: 5.2.1 + confbox@0.1.8: {} - content-hash@2.5.2: - dependencies: - cids: 0.7.5 - multicodec: 0.5.7 - multihashes: 0.4.21 + confbox@0.2.2: {} - content-type@1.0.5: {} + config-chain@1.1.13: + dependencies: + ini: 1.3.8 + proto-list: 1.2.4 - convert-source-map@1.9.0: {} + consola@3.2.3: {} - convert-source-map@2.0.0: {} + consola@3.4.2: {} - cookie-signature@1.0.7: {} + content-type@1.0.4: {} - cookie@0.7.2: {} + convert-hrtime@3.0.0: {} - cookie@1.1.1: {} + convert-source-map@2.0.0: {} - core-js-pure@3.47.0: {} + cookie-es@1.2.2: {} - core-js-pure@3.49.0: {} + cookie-es@2.0.0: {} - core-util-is@1.0.2: {} + cookie@0.4.2: {} - core-util-is@1.0.3: {} + cookie@0.5.0: {} - cors-gate@1.1.3: {} + copy-anything@3.0.5: + dependencies: + is-what: 4.1.16 - cors@2.8.6: + copy-anything@4.0.5: dependencies: - object-assign: 4.1.1 - vary: 1.1.2 + is-what: 5.5.0 - cosmiconfig@8.3.6(typescript@4.9.5): + copy-paste@2.2.0: dependencies: - import-fresh: 3.3.1 - js-yaml: 4.1.1 - parse-json: 5.2.0 - path-type: 4.0.0 - optionalDependencies: - typescript: 4.9.5 + iconv-lite: 0.4.24 + + core-util-is@1.0.3: {} crc-32@1.2.2: {} + crc32-stream@6.0.0: + dependencies: + crc-32: 1.2.2 + readable-stream: 4.7.0 + create-hash@1.2.0: dependencies: - cipher-base: 1.0.7 + cipher-base: 1.0.4 inherits: 2.0.4 md5.js: 1.3.5 - ripemd160: 2.0.3 - sha.js: 2.4.12 + ripemd160: 2.0.2 + sha.js: 2.4.11 create-hmac@1.1.7: dependencies: - cipher-base: 1.0.7 + cipher-base: 1.0.4 create-hash: 1.2.0 inherits: 2.0.4 - ripemd160: 2.0.3 + ripemd160: 2.0.2 safe-buffer: 5.2.1 - sha.js: 2.4.12 + sha.js: 2.4.11 create-require@1.1.1: {} + croner@9.1.0: {} + cross-fetch@3.2.0(encoding@0.1.13): dependencies: node-fetch: 2.7.0(encoding@0.1.13) @@ -13724,113 +18635,166 @@ snapshots: transitivePeerDependencies: - encoding + cross-spawn@5.1.0: + dependencies: + lru-cache: 4.1.5 + shebang-command: 1.2.0 + which: 1.3.1 + cross-spawn@7.0.6: dependencies: path-key: 3.1.1 shebang-command: 2.0.0 which: 2.0.2 - crypt@0.0.2: {} - - csstype@3.2.3: {} + crossws@0.2.4: {} - d@1.0.2: + crossws@0.3.5: dependencies: - es5-ext: 0.10.64 - type: 2.7.3 + uncrypto: 0.1.3 + + crypto-random-string@1.0.0: {} - dashdash@1.14.1: + css-declaration-sorter@7.3.0(postcss@8.5.6): dependencies: - assert-plus: 1.0.0 + postcss: 8.5.6 - data-uri-to-buffer@4.0.1: {} + css-select@5.2.2: + dependencies: + boolbase: 1.0.0 + css-what: 6.2.2 + domhandler: 5.0.3 + domutils: 3.2.2 + nth-check: 2.1.1 - data-uri-to-buffer@6.0.2: {} + css-tree@2.2.1: + dependencies: + mdn-data: 2.0.28 + source-map-js: 1.2.1 - data-view-buffer@1.0.2: + css-tree@2.3.1: dependencies: - call-bound: 1.0.4 - es-errors: 1.3.0 - is-data-view: 1.0.2 + mdn-data: 2.0.30 + source-map-js: 1.2.1 - data-view-byte-length@1.0.2: + css-tree@3.1.0: dependencies: - call-bound: 1.0.4 - es-errors: 1.3.0 - is-data-view: 1.0.2 + mdn-data: 2.12.2 + source-map-js: 1.2.1 + + css-what@6.2.2: {} - data-view-byte-offset@1.0.1: + cssesc@3.0.0: {} + + cssnano-preset-default@7.0.10(postcss@8.5.6): dependencies: - call-bound: 1.0.4 - es-errors: 1.3.0 - is-data-view: 1.0.2 + browserslist: 4.28.1 + css-declaration-sorter: 7.3.0(postcss@8.5.6) + cssnano-utils: 5.0.1(postcss@8.5.6) + postcss: 8.5.6 + postcss-calc: 10.1.1(postcss@8.5.6) + postcss-colormin: 7.0.5(postcss@8.5.6) + postcss-convert-values: 7.0.8(postcss@8.5.6) + postcss-discard-comments: 7.0.5(postcss@8.5.6) + postcss-discard-duplicates: 7.0.2(postcss@8.5.6) + postcss-discard-empty: 7.0.1(postcss@8.5.6) + postcss-discard-overridden: 7.0.1(postcss@8.5.6) + postcss-merge-longhand: 7.0.5(postcss@8.5.6) + postcss-merge-rules: 7.0.7(postcss@8.5.6) + postcss-minify-font-values: 7.0.1(postcss@8.5.6) + postcss-minify-gradients: 7.0.1(postcss@8.5.6) + postcss-minify-params: 7.0.5(postcss@8.5.6) + postcss-minify-selectors: 7.0.5(postcss@8.5.6) + postcss-normalize-charset: 7.0.1(postcss@8.5.6) + postcss-normalize-display-values: 7.0.1(postcss@8.5.6) + postcss-normalize-positions: 7.0.1(postcss@8.5.6) + postcss-normalize-repeat-style: 7.0.1(postcss@8.5.6) + postcss-normalize-string: 7.0.1(postcss@8.5.6) + postcss-normalize-timing-functions: 7.0.1(postcss@8.5.6) + postcss-normalize-unicode: 7.0.5(postcss@8.5.6) + postcss-normalize-url: 7.0.1(postcss@8.5.6) + postcss-normalize-whitespace: 7.0.1(postcss@8.5.6) + postcss-ordered-values: 7.0.2(postcss@8.5.6) + postcss-reduce-initial: 7.0.5(postcss@8.5.6) + postcss-reduce-transforms: 7.0.1(postcss@8.5.6) + postcss-svgo: 7.1.0(postcss@8.5.6) + postcss-unique-selectors: 7.0.4(postcss@8.5.6) + + cssnano-utils@5.0.1(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + + cssnano@7.1.2(postcss@8.5.6): + dependencies: + cssnano-preset-default: 7.0.10(postcss@8.5.6) + lilconfig: 3.1.3 + postcss: 8.5.6 + + csso@5.0.5: + dependencies: + css-tree: 2.2.1 + + csstype@3.1.3: {} + + csstype@3.2.3: {} + + dataloader@1.4.0: {} date-fns@2.30.0: dependencies: - '@babel/runtime': 7.29.2 + '@babel/runtime': 7.28.4 - death@1.1.0: {} + dateformat@4.6.3: {} - debug@2.6.9: - dependencies: - ms: 2.0.0 + dayjs@1.11.13: {} + + db0@0.3.4: {} + + de-indent@1.0.2: {} - debug@3.2.7: + debounce@1.2.1: {} + + debug@4.3.4(supports-color@8.1.1): dependencies: - ms: 2.1.3 + ms: 2.1.2 + optionalDependencies: + supports-color: 8.1.1 - debug@4.4.3(supports-color@5.5.0): + debug@4.4.1: dependencies: ms: 2.1.3 - optionalDependencies: - supports-color: 5.5.0 - debug@4.4.3(supports-color@8.1.1): + debug@4.4.3: dependencies: ms: 2.1.3 - optionalDependencies: - supports-color: 8.1.1 decamelize@1.2.0: {} decamelize@4.0.0: {} - decode-uri-component@0.2.2: {} - - decompress-response@3.3.0: + decode-named-character-reference@1.0.2: dependencies: - mimic-response: 1.0.1 + character-entities: 2.0.2 - decompress-response@6.0.0: - dependencies: - mimic-response: 3.1.0 + decode-uri-component@0.2.2: {} - deep-eql@4.1.4: - dependencies: - type-detect: 4.1.0 + dedent@1.6.0: {} - deep-extend@0.6.0: {} + deep-eql@5.0.2: {} - deep-is@0.1.4: {} + deepmerge@4.3.1: {} - default-require-extensions@3.0.1: + default-browser-id@5.0.1: {} + + default-browser@5.4.0: dependencies: - strip-bom: 4.0.0 + bundle-name: 4.1.0 + default-browser-id: 5.0.1 defaults@1.0.4: dependencies: clone: 1.0.4 - - defer-to-connect@2.0.1: {} - - deferred-leveldown@1.2.2: - dependencies: - abstract-leveldown: 2.6.3 - - deferred-leveldown@5.3.0: - dependencies: - abstract-leveldown: 6.2.3 - inherits: 2.0.4 + optional: true define-data-property@1.1.4: dependencies: @@ -13840,75 +18804,87 @@ snapshots: define-lazy-prop@2.0.0: {} - define-properties@1.2.1: - dependencies: - define-data-property: 1.1.4 - has-property-descriptors: 1.0.2 - object-keys: 1.1.1 + define-lazy-prop@3.0.0: {} - degenerator@5.0.1: - dependencies: - ast-types: 0.13.4 - escodegen: 2.1.0 - esprima: 4.0.1 + defu@6.1.4: {} - del@5.1.0: - dependencies: - globby: 10.0.2 - graceful-fs: 4.2.11 - is-glob: 4.0.3 - is-path-cwd: 2.2.0 - is-path-inside: 3.0.3 - p-map: 3.0.0 - rimraf: 3.0.2 - slash: 3.0.0 + denque@2.1.0: {} - delayed-stream@1.0.0: {} + depd@1.1.2: {} depd@2.0.0: {} - destroy@1.2.0: {} + dequal@2.0.3: {} - destroyable-server@1.1.1: + derive-valtio@0.1.0(valtio@1.13.2(@types/react@18.3.27)(react@18.3.1)): dependencies: - '@types/node': 25.6.0 + valtio: 1.13.2(@types/react@18.3.27)(react@18.3.1) + + destr@2.0.5: {} + + detect-browser@5.3.0: {} detect-indent@6.1.0: {} - detect-libc@2.1.2: - optional: true + detect-libc@1.0.3: {} + + detect-libc@2.1.2: {} - diff@5.2.2: {} + detect-node-es@1.1.0: {} - diff@9.0.0: {} + devalue@5.6.1: {} - difflib@0.2.4: + devlop@1.1.0: dependencies: - heap: 0.2.7 + dequal: 2.0.3 + + diff@4.0.2: {} + + diff@5.0.0: {} + + diff@8.0.2: {} + + dijkstrajs@1.0.2: {} + + dir-glob@2.2.2: + dependencies: + path-type: 3.0.0 dir-glob@3.0.1: dependencies: path-type: 4.0.0 - doctrine@2.1.0: + dom-accessibility-api@0.5.16: {} + + dom-serializer@2.0.0: dependencies: - esutils: 2.0.3 + domelementtype: 2.3.0 + domhandler: 5.0.3 + entities: 4.5.0 + + domelementtype@2.3.0: {} - dom-walk@0.1.2: {} + domhandler@5.0.3: + dependencies: + domelementtype: 2.3.0 - domexception@1.0.1: + domutils@3.2.2: dependencies: - webidl-conversions: 4.0.2 + dom-serializer: 2.0.0 + domelementtype: 2.3.0 + domhandler: 5.0.3 - dot-case@2.1.1: + dot-prop@10.1.0: dependencies: - no-case: 2.3.2 + type-fest: 5.3.1 + + dotenv-expand@10.0.0: {} - dotenv@16.0.3: {} + dotenv@16.3.1: {} dotenv@16.6.1: {} - dotenv@17.3.1: {} + dotenv@17.2.3: {} dotenv@8.6.0: {} @@ -13918,29 +18894,58 @@ snapshots: es-errors: 1.3.0 gopd: 1.2.0 - duplexify@3.7.1: + duplexer@0.1.2: {} + + duplexify@4.1.2: dependencies: end-of-stream: 1.4.5 inherits: 2.0.4 - readable-stream: 2.3.8 - stream-shift: 1.0.3 + readable-stream: 3.6.2 + stream-shift: 1.0.1 eastasianwidth@0.2.0: {} - ecc-jsbn@0.1.2: + easy-table@1.2.0: dependencies: - jsbn: 0.1.1 - safer-buffer: 2.1.2 + ansi-regex: 5.0.1 + optionalDependencies: + wcwidth: 1.0.1 + + eciesjs@0.4.16: + dependencies: + '@ecies/ciphers': 0.2.5(@noble/ciphers@1.3.0) + '@noble/ciphers': 1.3.0 + '@noble/curves': 1.9.7 + '@noble/hashes': 1.8.0 + + edge-runtime@2.5.9: + dependencies: + '@edge-runtime/format': 2.2.1 + '@edge-runtime/ponyfill': 2.4.2 + '@edge-runtime/vm': 3.2.0 + async-listen: 3.0.1 + mri: 1.2.0 + picocolors: 1.0.0 + pretty-ms: 7.0.1 + signal-exit: 4.0.2 + time-span: 4.0.0 + + editorconfig@1.0.4: + dependencies: + '@one-ini/wasm': 0.1.1 + commander: 10.0.1 + minimatch: 9.0.1 + semver: 7.7.3 ee-first@1.1.1: {} - electron-to-chromium@1.5.267: {} + electron-to-chromium@1.4.757: {} - electron-to-chromium@1.5.344: {} + electron-to-chromium@1.5.267: {} - elliptic@6.6.1: + elliptic@6.5.4: dependencies: - bn.js: 5.2.3 + bn.js: 4.12.2 brorand: 1.1.0 hash.js: 1.1.7 hmac-drbg: 1.0.1 @@ -13948,697 +18953,368 @@ snapshots: minimalistic-assert: 1.0.1 minimalistic-crypto-utils: 1.0.1 - emittery@0.10.0: {} + elliptic@6.6.0: + dependencies: + bn.js: 4.12.0 + brorand: 1.1.0 + hash.js: 1.1.7 + hmac-drbg: 1.0.1 + inherits: 2.0.4 + minimalistic-assert: 1.0.1 + minimalistic-crypto-utils: 1.0.1 - emoji-regex@10.6.0: {} + elliptic@6.6.1: + dependencies: + bn.js: 4.12.2 + brorand: 1.1.0 + hash.js: 1.1.7 + hmac-drbg: 1.0.1 + inherits: 2.0.4 + minimalistic-assert: 1.0.1 + minimalistic-crypto-utils: 1.0.1 emoji-regex@8.0.0: {} emoji-regex@9.2.2: {} - encode-utf8@1.0.3: {} + emojilib@2.4.0: {} - encodeurl@1.0.2: {} + encode-utf8@1.0.3: {} encodeurl@2.0.0: {} - encoding-down@6.3.0: - dependencies: - abstract-leveldown: 6.3.0 - inherits: 2.0.4 - level-codec: 9.0.2 - level-errors: 2.0.1 - encoding@0.1.13: dependencies: iconv-lite: 0.6.3 - optional: true - end-of-stream@1.4.5: + end-of-stream@1.1.0: dependencies: - once: 1.4.0 + once: 1.3.3 - enquirer@2.4.1: + end-of-stream@1.4.4: dependencies: - ansi-colors: 4.1.3 - strip-ansi: 6.0.1 - - entities@7.0.1: {} - - env-paths@2.2.1: {} - - err-code@2.0.3: {} + once: 1.4.0 - errno@0.1.8: + end-of-stream@1.4.5: dependencies: - prr: 1.0.1 + once: 1.4.0 - error-ex@1.3.4: + engine.io-client@6.6.4(bufferutil@4.1.0)(utf-8-validate@5.0.10): dependencies: - is-arrayish: 0.2.1 + '@socket.io/component-emitter': 3.1.2 + debug: 4.4.3 + engine.io-parser: 5.2.3 + ws: 8.18.3(bufferutil@4.1.0)(utf-8-validate@5.0.10) + xmlhttprequest-ssl: 2.1.2 + transitivePeerDependencies: + - bufferutil + - supports-color + - utf-8-validate - es-abstract@1.24.1: - dependencies: - array-buffer-byte-length: 1.0.2 - arraybuffer.prototype.slice: 1.0.4 - available-typed-arrays: 1.0.7 - call-bind: 1.0.8 - call-bound: 1.0.4 - data-view-buffer: 1.0.2 - data-view-byte-length: 1.0.2 - data-view-byte-offset: 1.0.1 - es-define-property: 1.0.1 - es-errors: 1.3.0 - es-object-atoms: 1.1.1 - es-set-tostringtag: 2.1.0 - es-to-primitive: 1.3.0 - function.prototype.name: 1.1.8 - get-intrinsic: 1.3.0 - get-proto: 1.0.1 - get-symbol-description: 1.1.0 - globalthis: 1.0.4 - gopd: 1.2.0 - has-property-descriptors: 1.0.2 - has-proto: 1.2.0 - has-symbols: 1.1.0 - hasown: 2.0.2 - internal-slot: 1.1.0 - is-array-buffer: 3.0.5 - is-callable: 1.2.7 - is-data-view: 1.0.2 - is-negative-zero: 2.0.3 - is-regex: 1.2.1 - is-set: 2.0.3 - is-shared-array-buffer: 1.0.4 - is-string: 1.1.1 - is-typed-array: 1.1.15 - is-weakref: 1.1.1 - math-intrinsics: 1.1.0 - object-inspect: 1.13.4 - object-keys: 1.1.1 - object.assign: 4.1.7 - own-keys: 1.0.1 - regexp.prototype.flags: 1.5.4 - safe-array-concat: 1.1.3 - safe-push-apply: 1.0.0 - safe-regex-test: 1.1.0 - set-proto: 1.0.0 - stop-iteration-iterator: 1.1.0 - string.prototype.trim: 1.2.10 - string.prototype.trimend: 1.0.9 - string.prototype.trimstart: 1.0.8 - typed-array-buffer: 1.0.3 - typed-array-byte-length: 1.0.3 - typed-array-byte-offset: 1.0.4 - typed-array-length: 1.0.7 - unbox-primitive: 1.1.0 - which-typed-array: 1.1.19 + engine.io-parser@5.2.3: {} - es-abstract@1.24.2: + enhanced-resolve@5.17.1: dependencies: - array-buffer-byte-length: 1.0.2 - arraybuffer.prototype.slice: 1.0.4 - available-typed-arrays: 1.0.7 - call-bind: 1.0.9 - call-bound: 1.0.4 - data-view-buffer: 1.0.2 - data-view-byte-length: 1.0.2 - data-view-byte-offset: 1.0.1 - es-define-property: 1.0.1 - es-errors: 1.3.0 - es-object-atoms: 1.1.1 - es-set-tostringtag: 2.1.0 - es-to-primitive: 1.3.0 - function.prototype.name: 1.1.8 - get-intrinsic: 1.3.0 - get-proto: 1.0.1 - get-symbol-description: 1.1.0 - globalthis: 1.0.4 - gopd: 1.2.0 - has-property-descriptors: 1.0.2 - has-proto: 1.2.0 - has-symbols: 1.1.0 - hasown: 2.0.3 - internal-slot: 1.1.0 - is-array-buffer: 3.0.5 - is-callable: 1.2.7 - is-data-view: 1.0.2 - is-negative-zero: 2.0.3 - is-regex: 1.2.1 - is-set: 2.0.3 - is-shared-array-buffer: 1.0.4 - is-string: 1.1.1 - is-typed-array: 1.1.15 - is-weakref: 1.1.1 - math-intrinsics: 1.1.0 - object-inspect: 1.13.4 - object-keys: 1.1.1 - object.assign: 4.1.7 - own-keys: 1.0.1 - regexp.prototype.flags: 1.5.4 - safe-array-concat: 1.1.4 - safe-push-apply: 1.0.0 - safe-regex-test: 1.1.0 - set-proto: 1.0.0 - stop-iteration-iterator: 1.1.0 - string.prototype.trim: 1.2.10 - string.prototype.trimend: 1.0.9 - string.prototype.trimstart: 1.0.8 - typed-array-buffer: 1.0.3 - typed-array-byte-length: 1.0.3 - typed-array-byte-offset: 1.0.4 - typed-array-length: 1.0.7 - unbox-primitive: 1.1.0 - which-typed-array: 1.1.20 - - es-define-property@1.0.1: {} - - es-errors@1.3.0: {} + graceful-fs: 4.2.11 + tapable: 2.2.1 - es-iterator-helpers@1.2.2: + enhanced-resolve@5.18.4: dependencies: - call-bind: 1.0.8 - call-bound: 1.0.4 - define-properties: 1.2.1 - es-abstract: 1.24.1 - es-errors: 1.3.0 - es-set-tostringtag: 2.1.0 - function-bind: 1.1.2 - get-intrinsic: 1.3.0 - globalthis: 1.0.4 - gopd: 1.2.0 - has-property-descriptors: 1.0.2 - has-proto: 1.2.0 - has-symbols: 1.1.0 - internal-slot: 1.1.0 - iterator.prototype: 1.1.5 - safe-array-concat: 1.1.3 - - es-module-lexer@1.7.0: {} + graceful-fs: 4.2.11 + tapable: 2.3.0 - es-object-atoms@1.1.1: + enquirer@2.3.6: dependencies: - es-errors: 1.3.0 + ansi-colors: 4.1.3 - es-set-tostringtag@2.1.0: + enquirer@2.4.1: dependencies: - es-errors: 1.3.0 - get-intrinsic: 1.3.0 - has-tostringtag: 1.0.2 - hasown: 2.0.2 + ansi-colors: 4.1.3 + strip-ansi: 6.0.1 - es-shim-unscopables@1.1.0: - dependencies: - hasown: 2.0.3 + entities@4.5.0: {} - es-to-primitive@1.3.0: - dependencies: - is-callable: 1.2.7 - is-date-object: 1.1.0 - is-symbol: 1.1.1 + entities@7.0.0: {} - es5-ext@0.10.64: - dependencies: - es6-iterator: 2.0.3 - es6-symbol: 3.1.4 - esniff: 2.0.1 - next-tick: 1.1.0 + env-paths@2.2.1: {} - es6-error@4.1.1: {} + environment@1.1.0: {} - es6-iterator@2.0.3: - dependencies: - d: 1.0.2 - es5-ext: 0.10.64 - es6-symbol: 3.1.4 + error-stack-parser-es@1.0.5: {} - es6-promise@4.2.8: {} + errx@0.1.0: {} - es6-symbol@3.1.4: - dependencies: - d: 1.0.2 - ext: 1.7.0 + es-define-property@1.0.1: {} - esbuild@0.27.3: - optionalDependencies: - '@esbuild/aix-ppc64': 0.27.3 - '@esbuild/android-arm': 0.27.3 - '@esbuild/android-arm64': 0.27.3 - '@esbuild/android-x64': 0.27.3 - '@esbuild/darwin-arm64': 0.27.3 - '@esbuild/darwin-x64': 0.27.3 - '@esbuild/freebsd-arm64': 0.27.3 - '@esbuild/freebsd-x64': 0.27.3 - '@esbuild/linux-arm': 0.27.3 - '@esbuild/linux-arm64': 0.27.3 - '@esbuild/linux-ia32': 0.27.3 - '@esbuild/linux-loong64': 0.27.3 - '@esbuild/linux-mips64el': 0.27.3 - '@esbuild/linux-ppc64': 0.27.3 - '@esbuild/linux-riscv64': 0.27.3 - '@esbuild/linux-s390x': 0.27.3 - '@esbuild/linux-x64': 0.27.3 - '@esbuild/netbsd-arm64': 0.27.3 - '@esbuild/netbsd-x64': 0.27.3 - '@esbuild/openbsd-arm64': 0.27.3 - '@esbuild/openbsd-x64': 0.27.3 - '@esbuild/openharmony-arm64': 0.27.3 - '@esbuild/sunos-x64': 0.27.3 - '@esbuild/win32-arm64': 0.27.3 - '@esbuild/win32-ia32': 0.27.3 - '@esbuild/win32-x64': 0.27.3 + es-errors@1.3.0: {} - escalade@3.2.0: {} + es-module-lexer@1.4.1: {} - escape-html@1.0.3: {} + es-module-lexer@1.7.0: {} - escape-string-regexp@1.0.5: {} + es-object-atoms@1.1.1: + dependencies: + es-errors: 1.3.0 - escape-string-regexp@4.0.0: {} + es-toolkit@1.33.0: {} - escodegen@1.8.1: - dependencies: - esprima: 2.7.3 - estraverse: 1.9.3 - esutils: 2.0.3 - optionator: 0.8.3 - optionalDependencies: - source-map: 0.2.0 + esbuild-android-64@0.14.47: + optional: true - escodegen@2.1.0: - dependencies: - esprima: 4.0.1 - estraverse: 5.3.0 - esutils: 2.0.3 - optionalDependencies: - source-map: 0.6.1 + esbuild-android-arm64@0.14.47: + optional: true - eslint-config-prettier@10.1.8(eslint@9.39.2): - dependencies: - eslint: 9.39.2 + esbuild-darwin-64@0.14.47: + optional: true - eslint-config-prettier@8.10.2(eslint@9.39.4): - dependencies: - eslint: 9.39.4 + esbuild-darwin-arm64@0.14.47: + optional: true - eslint-import-resolver-node@0.3.10: - dependencies: - debug: 3.2.7 - is-core-module: 2.16.1 - resolve: 2.0.0-next.6 - transitivePeerDependencies: - - supports-color + esbuild-freebsd-64@0.14.47: + optional: true - eslint-module-utils@2.12.1(@typescript-eslint/parser@8.59.0(eslint@9.39.4)(typescript@4.9.5))(eslint-import-resolver-node@0.3.10)(eslint@9.39.4): - dependencies: - debug: 3.2.7 - optionalDependencies: - '@typescript-eslint/parser': 8.59.0(eslint@9.39.4)(typescript@4.9.5) - eslint: 9.39.4 - eslint-import-resolver-node: 0.3.10 - transitivePeerDependencies: - - supports-color + esbuild-freebsd-arm64@0.14.47: + optional: true - eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.59.0(eslint@9.39.4)(typescript@4.9.5))(eslint@9.39.4): - dependencies: - '@rtsao/scc': 1.1.0 - array-includes: 3.1.9 - array.prototype.findlastindex: 1.2.6 - array.prototype.flat: 1.3.3 - array.prototype.flatmap: 1.3.3 - debug: 3.2.7 - doctrine: 2.1.0 - eslint: 9.39.4 - eslint-import-resolver-node: 0.3.10 - eslint-module-utils: 2.12.1(@typescript-eslint/parser@8.59.0(eslint@9.39.4)(typescript@4.9.5))(eslint-import-resolver-node@0.3.10)(eslint@9.39.4) - hasown: 2.0.3 - is-core-module: 2.16.1 - is-glob: 4.0.3 - minimatch: 10.2.5 - object.fromentries: 2.0.8 - object.groupby: 1.0.3 - object.values: 1.2.1 - semver: 6.3.1 - string.prototype.trimend: 1.0.9 - tsconfig-paths: 3.15.0 - optionalDependencies: - '@typescript-eslint/parser': 8.59.0(eslint@9.39.4)(typescript@4.9.5) - transitivePeerDependencies: - - eslint-import-resolver-typescript - - eslint-import-resolver-webpack - - supports-color + esbuild-linux-32@0.14.47: + optional: true - eslint-plugin-only-warn@1.1.0: {} + esbuild-linux-64@0.14.47: + optional: true - eslint-plugin-prettier@3.4.1(eslint-config-prettier@8.10.2(eslint@9.39.4))(eslint@9.39.4)(prettier@3.8.1): - dependencies: - eslint: 9.39.4 - prettier: 3.8.1 - prettier-linter-helpers: 1.0.1 - optionalDependencies: - eslint-config-prettier: 8.10.2(eslint@9.39.4) + esbuild-linux-arm64@0.14.47: + optional: true - eslint-plugin-react-hooks@7.0.1(eslint@9.39.2): - dependencies: - '@babel/core': 7.28.5 - '@babel/parser': 7.28.5 - eslint: 9.39.2 - hermes-parser: 0.25.1 - zod: 4.2.0 - zod-validation-error: 4.0.2(zod@4.2.0) - transitivePeerDependencies: - - supports-color + esbuild-linux-arm@0.14.47: + optional: true - eslint-plugin-react@7.37.5(eslint@9.39.2): - dependencies: - array-includes: 3.1.9 - array.prototype.findlast: 1.2.5 - array.prototype.flatmap: 1.3.3 - array.prototype.tosorted: 1.1.4 - doctrine: 2.1.0 - es-iterator-helpers: 1.2.2 - eslint: 9.39.2 - estraverse: 5.3.0 - hasown: 2.0.2 - jsx-ast-utils: 3.3.5 - minimatch: 10.2.5 - object.entries: 1.1.9 - object.fromentries: 2.0.8 - object.values: 1.2.1 - prop-types: 15.8.1 - resolve: 2.0.0-next.5 - semver: 6.3.1 - string.prototype.matchall: 4.0.12 - string.prototype.repeat: 1.0.0 + esbuild-linux-mips64le@0.14.47: + optional: true - eslint-plugin-turbo@2.6.3(eslint@9.39.2)(turbo@2.9.6): - dependencies: - dotenv: 16.0.3 - eslint: 9.39.2 - turbo: 2.9.6 + esbuild-linux-ppc64le@0.14.47: + optional: true - eslint-scope@8.4.0: - dependencies: - esrecurse: 4.3.0 - estraverse: 5.3.0 + esbuild-linux-riscv64@0.14.47: + optional: true - eslint-visitor-keys@3.4.3: {} + esbuild-linux-s390x@0.14.47: + optional: true - eslint-visitor-keys@4.2.1: {} + esbuild-netbsd-64@0.14.47: + optional: true - eslint-visitor-keys@5.0.1: {} + esbuild-openbsd-64@0.14.47: + optional: true - eslint@9.39.2: - dependencies: - '@eslint-community/eslint-utils': 4.9.0(eslint@9.39.2) - '@eslint-community/regexpp': 4.12.2 - '@eslint/config-array': 0.21.1 - '@eslint/config-helpers': 0.4.2 - '@eslint/core': 0.17.0 - '@eslint/eslintrc': 3.3.3 - '@eslint/js': 9.39.2 - '@eslint/plugin-kit': 0.4.1 - '@humanfs/node': 0.16.7 - '@humanwhocodes/module-importer': 1.0.1 - '@humanwhocodes/retry': 0.4.3 - '@types/estree': 1.0.8 - ajv: 8.20.0 - chalk: 4.1.2 - cross-spawn: 7.0.6 - debug: 4.4.3(supports-color@5.5.0) - escape-string-regexp: 4.0.0 - eslint-scope: 8.4.0 - eslint-visitor-keys: 4.2.1 - espree: 10.4.0 - esquery: 1.6.0 - esutils: 2.0.3 - fast-deep-equal: 3.1.3 - file-entry-cache: 8.0.0 - find-up: 5.0.0 - glob-parent: 6.0.2 - ignore: 5.3.2 - imurmurhash: 0.1.4 - is-glob: 4.0.3 - json-stable-stringify-without-jsonify: 1.0.1 - lodash.merge: 4.6.2 - minimatch: 10.2.5 - natural-compare: 1.4.0 - optionator: 0.9.4 - transitivePeerDependencies: - - supports-color + esbuild-sunos-64@0.14.47: + optional: true - eslint@9.39.4: - dependencies: - '@eslint-community/eslint-utils': 4.9.1(eslint@9.39.4) - '@eslint-community/regexpp': 4.12.2 - '@eslint/config-array': 0.21.2 - '@eslint/config-helpers': 0.4.2 - '@eslint/core': 0.17.0 - '@eslint/eslintrc': 3.3.5 - '@eslint/js': 9.39.4 - '@eslint/plugin-kit': 0.4.1 - '@humanfs/node': 0.16.8 - '@humanwhocodes/module-importer': 1.0.1 - '@humanwhocodes/retry': 0.4.3 - '@types/estree': 1.0.8 - ajv: 6.15.0 - chalk: 4.1.2 - cross-spawn: 7.0.6 - debug: 4.4.3(supports-color@5.5.0) - escape-string-regexp: 4.0.0 - eslint-scope: 8.4.0 - eslint-visitor-keys: 4.2.1 - espree: 10.4.0 - esquery: 1.7.0 - esutils: 2.0.3 - fast-deep-equal: 3.1.3 - file-entry-cache: 8.0.0 - find-up: 5.0.0 - glob-parent: 6.0.2 - ignore: 5.3.2 - imurmurhash: 0.1.4 - is-glob: 4.0.3 - json-stable-stringify-without-jsonify: 1.0.1 - lodash.merge: 4.6.2 - minimatch: 3.1.5 - natural-compare: 1.4.0 - optionator: 0.9.4 - transitivePeerDependencies: - - supports-color + esbuild-windows-32@0.14.47: + optional: true - esm@3.2.25: + esbuild-windows-64@0.14.47: optional: true - esniff@2.0.1: - dependencies: - d: 1.0.2 - es5-ext: 0.10.64 - event-emitter: 0.3.5 - type: 2.7.3 + esbuild-windows-arm64@0.14.47: + optional: true - espree@10.4.0: - dependencies: - acorn: 8.15.0 - acorn-jsx: 5.3.2(acorn@8.15.0) - eslint-visitor-keys: 4.2.1 + esbuild@0.14.47: + optionalDependencies: + esbuild-android-64: 0.14.47 + esbuild-android-arm64: 0.14.47 + esbuild-darwin-64: 0.14.47 + esbuild-darwin-arm64: 0.14.47 + esbuild-freebsd-64: 0.14.47 + esbuild-freebsd-arm64: 0.14.47 + esbuild-linux-32: 0.14.47 + esbuild-linux-64: 0.14.47 + esbuild-linux-arm: 0.14.47 + esbuild-linux-arm64: 0.14.47 + esbuild-linux-mips64le: 0.14.47 + esbuild-linux-ppc64le: 0.14.47 + esbuild-linux-riscv64: 0.14.47 + esbuild-linux-s390x: 0.14.47 + esbuild-netbsd-64: 0.14.47 + esbuild-openbsd-64: 0.14.47 + esbuild-sunos-64: 0.14.47 + esbuild-windows-32: 0.14.47 + esbuild-windows-64: 0.14.47 + esbuild-windows-arm64: 0.14.47 + + esbuild@0.21.5: + optionalDependencies: + '@esbuild/aix-ppc64': 0.21.5 + '@esbuild/android-arm': 0.21.5 + '@esbuild/android-arm64': 0.21.5 + '@esbuild/android-x64': 0.21.5 + '@esbuild/darwin-arm64': 0.21.5 + '@esbuild/darwin-x64': 0.21.5 + '@esbuild/freebsd-arm64': 0.21.5 + '@esbuild/freebsd-x64': 0.21.5 + '@esbuild/linux-arm': 0.21.5 + '@esbuild/linux-arm64': 0.21.5 + '@esbuild/linux-ia32': 0.21.5 + '@esbuild/linux-loong64': 0.21.5 + '@esbuild/linux-mips64el': 0.21.5 + '@esbuild/linux-ppc64': 0.21.5 + '@esbuild/linux-riscv64': 0.21.5 + '@esbuild/linux-s390x': 0.21.5 + '@esbuild/linux-x64': 0.21.5 + '@esbuild/netbsd-x64': 0.21.5 + '@esbuild/openbsd-x64': 0.21.5 + '@esbuild/sunos-x64': 0.21.5 + '@esbuild/win32-arm64': 0.21.5 + '@esbuild/win32-ia32': 0.21.5 + '@esbuild/win32-x64': 0.21.5 + + esbuild@0.23.1: + optionalDependencies: + '@esbuild/aix-ppc64': 0.23.1 + '@esbuild/android-arm': 0.23.1 + '@esbuild/android-arm64': 0.23.1 + '@esbuild/android-x64': 0.23.1 + '@esbuild/darwin-arm64': 0.23.1 + '@esbuild/darwin-x64': 0.23.1 + '@esbuild/freebsd-arm64': 0.23.1 + '@esbuild/freebsd-x64': 0.23.1 + '@esbuild/linux-arm': 0.23.1 + '@esbuild/linux-arm64': 0.23.1 + '@esbuild/linux-ia32': 0.23.1 + '@esbuild/linux-loong64': 0.23.1 + '@esbuild/linux-mips64el': 0.23.1 + '@esbuild/linux-ppc64': 0.23.1 + '@esbuild/linux-riscv64': 0.23.1 + '@esbuild/linux-s390x': 0.23.1 + '@esbuild/linux-x64': 0.23.1 + '@esbuild/netbsd-x64': 0.23.1 + '@esbuild/openbsd-arm64': 0.23.1 + '@esbuild/openbsd-x64': 0.23.1 + '@esbuild/sunos-x64': 0.23.1 + '@esbuild/win32-arm64': 0.23.1 + '@esbuild/win32-ia32': 0.23.1 + '@esbuild/win32-x64': 0.23.1 + + esbuild@0.25.12: + optionalDependencies: + '@esbuild/aix-ppc64': 0.25.12 + '@esbuild/android-arm': 0.25.12 + '@esbuild/android-arm64': 0.25.12 + '@esbuild/android-x64': 0.25.12 + '@esbuild/darwin-arm64': 0.25.12 + '@esbuild/darwin-x64': 0.25.12 + '@esbuild/freebsd-arm64': 0.25.12 + '@esbuild/freebsd-x64': 0.25.12 + '@esbuild/linux-arm': 0.25.12 + '@esbuild/linux-arm64': 0.25.12 + '@esbuild/linux-ia32': 0.25.12 + '@esbuild/linux-loong64': 0.25.12 + '@esbuild/linux-mips64el': 0.25.12 + '@esbuild/linux-ppc64': 0.25.12 + '@esbuild/linux-riscv64': 0.25.12 + '@esbuild/linux-s390x': 0.25.12 + '@esbuild/linux-x64': 0.25.12 + '@esbuild/netbsd-arm64': 0.25.12 + '@esbuild/netbsd-x64': 0.25.12 + '@esbuild/openbsd-arm64': 0.25.12 + '@esbuild/openbsd-x64': 0.25.12 + '@esbuild/openharmony-arm64': 0.25.12 + '@esbuild/sunos-x64': 0.25.12 + '@esbuild/win32-arm64': 0.25.12 + '@esbuild/win32-ia32': 0.25.12 + '@esbuild/win32-x64': 0.25.12 + + esbuild@0.27.2: + optionalDependencies: + '@esbuild/aix-ppc64': 0.27.2 + '@esbuild/android-arm': 0.27.2 + '@esbuild/android-arm64': 0.27.2 + '@esbuild/android-x64': 0.27.2 + '@esbuild/darwin-arm64': 0.27.2 + '@esbuild/darwin-x64': 0.27.2 + '@esbuild/freebsd-arm64': 0.27.2 + '@esbuild/freebsd-x64': 0.27.2 + '@esbuild/linux-arm': 0.27.2 + '@esbuild/linux-arm64': 0.27.2 + '@esbuild/linux-ia32': 0.27.2 + '@esbuild/linux-loong64': 0.27.2 + '@esbuild/linux-mips64el': 0.27.2 + '@esbuild/linux-ppc64': 0.27.2 + '@esbuild/linux-riscv64': 0.27.2 + '@esbuild/linux-s390x': 0.27.2 + '@esbuild/linux-x64': 0.27.2 + '@esbuild/netbsd-arm64': 0.27.2 + '@esbuild/netbsd-x64': 0.27.2 + '@esbuild/openbsd-arm64': 0.27.2 + '@esbuild/openbsd-x64': 0.27.2 + '@esbuild/openharmony-arm64': 0.27.2 + '@esbuild/sunos-x64': 0.27.2 + '@esbuild/win32-arm64': 0.27.2 + '@esbuild/win32-ia32': 0.27.2 + '@esbuild/win32-x64': 0.27.2 - esprima@2.7.3: {} + escalade@3.2.0: {} - esprima@4.0.1: {} + escape-html@1.0.3: {} - esquery@1.6.0: - dependencies: - estraverse: 5.3.0 + escape-string-regexp@1.0.5: {} - esquery@1.7.0: - dependencies: - estraverse: 5.3.0 + escape-string-regexp@4.0.0: {} - esrecurse@4.3.0: - dependencies: - estraverse: 5.3.0 + escape-string-regexp@5.0.0: {} - estraverse@1.9.3: {} + esprima@4.0.1: {} - estraverse@5.3.0: {} + estree-walker@2.0.2: {} estree-walker@3.0.3: dependencies: '@types/estree': 1.0.8 - esutils@2.0.3: {} - etag@1.8.1: {} - eth-block-tracker@5.0.1: + eth-block-tracker@7.1.0: dependencies: - '@metamask/safe-event-emitter': 2.0.0 + '@metamask/eth-json-rpc-provider': 1.0.1 + '@metamask/safe-event-emitter': 3.0.0 + '@metamask/utils': 5.0.2 json-rpc-random-id: 1.0.1 pify: 3.0.0 - - eth-ens-namehash@2.0.8: - dependencies: - idna-uts46-hx: 2.3.1 - js-sha3: 0.5.7 - - eth-gas-reporter@0.2.27(bufferutil@4.1.0)(utf-8-validate@5.0.10): - dependencies: - '@solidity-parser/parser': 0.14.5 - axios: 1.15.2(debug@4.4.3) - cli-table3: 0.5.1 - colors: 1.4.0 - ethereum-cryptography: 1.2.0 - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - fs-readdir-recursive: 1.1.0 - lodash: 4.18.1 - markdown-table: 1.1.3 - mocha: 10.8.2 - req-cwd: 2.0.0 - sha1: 1.1.1 - sync-request: 6.1.0 transitivePeerDependencies: - - bufferutil - - debug - - utf-8-validate + - supports-color - eth-json-rpc-filters@5.0.0: + eth-json-rpc-filters@6.0.1: dependencies: - '@metamask/safe-event-emitter': 2.0.0 + '@metamask/safe-event-emitter': 3.0.0 async-mutex: 0.2.6 - eth-json-rpc-middleware: 6.0.0 eth-query: 2.1.2 json-rpc-engine: 6.1.0 pify: 5.0.0 - eth-json-rpc-middleware@6.0.0: - dependencies: - btoa: 1.2.1 - clone: 2.1.2 - eth-query: 2.1.2 - eth-rpc-errors: 3.0.0 - eth-sig-util: 1.4.2 - ethereumjs-util: 5.2.1 - json-rpc-engine: 5.4.0 - json-stable-stringify: 1.3.0 - node-fetch: 3.3.2 - pify: 3.0.0 - safe-event-emitter: 1.0.1 - - eth-json-rpc-middleware@8.1.0(encoding@0.1.13): - dependencies: - '@metamask/safe-event-emitter': 2.0.0 - btoa: 1.2.1 - clone: 2.1.2 - eth-block-tracker: 5.0.1 - eth-rpc-errors: 4.0.3 - eth-sig-util: 1.4.2 - json-rpc-engine: 6.1.0 - json-stable-stringify: 1.3.0 - node-fetch: 2.7.0(encoding@0.1.13) - pify: 3.0.0 - transitivePeerDependencies: - - encoding - - eth-json-rpc-middleware@9.0.1(encoding@0.1.13): - dependencies: - '@metamask/eth-sig-util': 5.1.0 - '@metamask/safe-event-emitter': 2.0.0 - '@metamask/utils': 3.6.0 - btoa: 1.2.1 - clone: 2.1.2 - eth-block-tracker: 5.0.1 - eth-rpc-errors: 4.0.3 - json-rpc-engine: 6.1.0 - json-stable-stringify: 1.3.0 - node-fetch: 2.7.0(encoding@0.1.13) - pify: 3.0.0 - transitivePeerDependencies: - - encoding - - supports-color - - eth-lib@0.1.29(bufferutil@4.0.7)(utf-8-validate@6.0.3): - dependencies: - bn.js: 5.2.3 - elliptic: 6.6.1 - nano-json-stream-parser: 0.1.2 - servify: 0.1.12 - ws: 8.20.0(bufferutil@4.0.7)(utf-8-validate@6.0.3) - xhr-request-promise: 0.1.3 - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate - - eth-lib@0.1.29(bufferutil@4.1.0)(utf-8-validate@5.0.10): - dependencies: - bn.js: 5.2.3 - elliptic: 6.6.1 - nano-json-stream-parser: 0.1.2 - servify: 0.1.12 - ws: 8.20.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - xhr-request-promise: 0.1.3 - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate - - eth-lib@0.1.29(bufferutil@4.1.0)(utf-8-validate@6.0.3): - dependencies: - bn.js: 5.2.3 - elliptic: 6.6.1 - nano-json-stream-parser: 0.1.2 - servify: 0.1.12 - ws: 8.20.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - xhr-request-promise: 0.1.3 - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate - - eth-lib@0.2.8: - dependencies: - bn.js: 5.2.3 - elliptic: 6.6.1 - xhr-request-promise: 0.1.3 - eth-query@2.1.2: dependencies: json-rpc-random-id: 1.0.1 xtend: 4.0.2 - eth-rpc-errors@3.0.0: - dependencies: - fast-safe-stringify: 2.1.1 - eth-rpc-errors@4.0.3: dependencies: fast-safe-stringify: 2.1.1 - eth-sig-util@1.4.2: - dependencies: - ethereumjs-abi: https://codeload.github.com/ethereumjs/ethereumjs-abi/tar.gz/ee3994657fa7a427238e6ba92a84d0b529bbcde0 - ethereumjs-util: 5.2.1 - - ethereum-bloom-filters@1.2.0: - dependencies: - '@noble/hashes': 1.8.0 - ethereum-cryptography@0.1.3: dependencies: '@types/pbkdf2': 3.1.2 - '@types/secp256k1': 4.0.7 + '@types/secp256k1': 4.0.3 blakejs: 1.2.1 browserify-aes: 1.2.0 bs58check: 2.1.2 create-hash: 1.2.0 create-hmac: 1.1.7 hash.js: 1.1.7 - keccak: 3.0.4 - pbkdf2: 3.1.5 + keccak: 3.0.3 + pbkdf2: 3.1.2 randombytes: 2.1.0 safe-buffer: 5.2.1 scrypt-js: 3.0.1 - secp256k1: 4.0.4 + secp256k1: 4.0.3 setimmediate: 1.0.5 ethereum-cryptography@1.2.0: @@ -14655,252 +19331,22 @@ snapshots: '@scure/bip32': 1.4.0 '@scure/bip39': 1.3.0 - ethereum-waffle@4.0.10(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(@ethersproject/abi@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(encoding@0.1.13)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(typescript@4.9.5): - dependencies: - '@ethereum-waffle/chai': 4.0.10(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@ethereum-waffle/compiler': 4.0.3(@ethersproject/abi@5.8.0)(@ethersproject/providers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(encoding@0.1.13)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10))(solc@0.8.15)(typechain@8.3.2(typescript@4.9.5))(typescript@4.9.5) - '@ethereum-waffle/mock-contract': 4.0.4(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - '@ethereum-waffle/provider': 4.0.5(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - ethers: 6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - solc: 0.8.15 - typechain: 8.3.2(typescript@4.9.5) - transitivePeerDependencies: - - '@ensdomains/ens' - - '@ensdomains/resolver' - - '@ethersproject/abi' - - '@ethersproject/providers' - - debug - - encoding - - supports-color - - typescript - ethereumjs-abi@0.6.8: dependencies: - bn.js: 5.2.3 - ethereumjs-util: 6.2.1 - - ethereumjs-abi@https://codeload.github.com/ethereumjs/ethereumjs-abi/tar.gz/ee3994657fa7a427238e6ba92a84d0b529bbcde0: - dependencies: - bn.js: 5.2.3 - ethereumjs-util: 6.2.1 - - ethereumjs-account@2.0.5: - dependencies: - ethereumjs-util: 5.2.1 - rlp: 2.2.7 - safe-buffer: 5.2.1 - - ethereumjs-block@2.2.2: - dependencies: - async: 3.2.6 - ethereumjs-common: 1.5.2 - ethereumjs-tx: 2.1.2 - ethereumjs-util: 5.2.1 - merkle-patricia-tree: 2.3.2 - - ethereumjs-common@1.5.2: {} - - ethereumjs-tx@2.1.2: - dependencies: - ethereumjs-common: 1.5.2 + bn.js: 4.12.0 ethereumjs-util: 6.2.1 - ethereumjs-util@5.2.1: - dependencies: - bn.js: 5.2.3 - create-hash: 1.2.0 - elliptic: 6.6.1 - ethereum-cryptography: 0.1.3 - ethjs-util: 0.1.6 - rlp: 2.2.7 - safe-buffer: 5.2.1 - ethereumjs-util@6.2.1: dependencies: '@types/bn.js': 4.11.6 - bn.js: 5.2.3 + bn.js: 4.12.0 create-hash: 1.2.0 - elliptic: 6.6.1 + elliptic: 6.6.0 ethereum-cryptography: 0.1.3 ethjs-util: 0.1.6 rlp: 2.2.7 - ethereumjs-util@7.1.3: - dependencies: - '@types/bn.js': 5.2.0 - bn.js: 5.2.3 - create-hash: 1.2.0 - ethereum-cryptography: 0.1.3 - rlp: 2.2.7 - - ethereumjs-util@7.1.5: - dependencies: - '@types/bn.js': 5.2.0 - bn.js: 5.2.3 - create-hash: 1.2.0 - ethereum-cryptography: 0.1.3 - rlp: 2.2.7 - - ethereumjs-vm@2.6.0: - dependencies: - async: 3.2.6 - async-eventemitter: 0.2.4 - ethereumjs-account: 2.0.5 - ethereumjs-block: 2.2.2 - ethereumjs-common: 1.5.2 - ethereumjs-util: 6.2.1 - fake-merkle-patricia-tree: 1.0.1 - functional-red-black-tree: 1.0.1 - merkle-patricia-tree: 2.3.2 - rustbn.js: 0.2.0 - safe-buffer: 5.2.1 - - ethers@5.8.0: - dependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/abstract-provider': 5.8.0 - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/address': 5.8.0 - '@ethersproject/base64': 5.8.0 - '@ethersproject/basex': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/contracts': 5.8.0 - '@ethersproject/hash': 5.8.0 - '@ethersproject/hdnode': 5.8.0 - '@ethersproject/json-wallets': 5.8.0 - '@ethersproject/keccak256': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/networks': 5.8.0 - '@ethersproject/pbkdf2': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/providers': 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - '@ethersproject/random': 5.8.0 - '@ethersproject/rlp': 5.8.0 - '@ethersproject/sha2': 5.8.0 - '@ethersproject/signing-key': 5.8.0 - '@ethersproject/solidity': 5.8.0 - '@ethersproject/strings': 5.8.0 - '@ethersproject/transactions': 5.8.0 - '@ethersproject/units': 5.8.0 - '@ethersproject/wallet': 5.8.0 - '@ethersproject/web': 5.8.0 - '@ethersproject/wordlists': 5.8.0 - transitivePeerDependencies: - - bufferutil - - utf-8-validate - optional: true - - ethers@5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3): - dependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/abstract-provider': 5.8.0 - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/address': 5.8.0 - '@ethersproject/base64': 5.8.0 - '@ethersproject/basex': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/contracts': 5.8.0 - '@ethersproject/hash': 5.8.0 - '@ethersproject/hdnode': 5.8.0 - '@ethersproject/json-wallets': 5.8.0 - '@ethersproject/keccak256': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/networks': 5.8.0 - '@ethersproject/pbkdf2': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/providers': 5.8.0(bufferutil@4.0.7)(utf-8-validate@6.0.3) - '@ethersproject/random': 5.8.0 - '@ethersproject/rlp': 5.8.0 - '@ethersproject/sha2': 5.8.0 - '@ethersproject/signing-key': 5.8.0 - '@ethersproject/solidity': 5.8.0 - '@ethersproject/strings': 5.8.0 - '@ethersproject/transactions': 5.8.0 - '@ethersproject/units': 5.8.0 - '@ethersproject/wallet': 5.8.0 - '@ethersproject/web': 5.8.0 - '@ethersproject/wordlists': 5.8.0 - transitivePeerDependencies: - - bufferutil - - utf-8-validate - - ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10): - dependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/abstract-provider': 5.8.0 - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/address': 5.8.0 - '@ethersproject/base64': 5.8.0 - '@ethersproject/basex': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/contracts': 5.8.0 - '@ethersproject/hash': 5.8.0 - '@ethersproject/hdnode': 5.8.0 - '@ethersproject/json-wallets': 5.8.0 - '@ethersproject/keccak256': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/networks': 5.8.0 - '@ethersproject/pbkdf2': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/providers': 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@ethersproject/random': 5.8.0 - '@ethersproject/rlp': 5.8.0 - '@ethersproject/sha2': 5.8.0 - '@ethersproject/signing-key': 5.8.0 - '@ethersproject/solidity': 5.8.0 - '@ethersproject/strings': 5.8.0 - '@ethersproject/transactions': 5.8.0 - '@ethersproject/units': 5.8.0 - '@ethersproject/wallet': 5.8.0 - '@ethersproject/web': 5.8.0 - '@ethersproject/wordlists': 5.8.0 - transitivePeerDependencies: - - bufferutil - - utf-8-validate - - ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3): - dependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/abstract-provider': 5.8.0 - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/address': 5.8.0 - '@ethersproject/base64': 5.8.0 - '@ethersproject/basex': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/contracts': 5.8.0 - '@ethersproject/hash': 5.8.0 - '@ethersproject/hdnode': 5.8.0 - '@ethersproject/json-wallets': 5.8.0 - '@ethersproject/keccak256': 5.8.0 - '@ethersproject/logger': 5.8.0 - '@ethersproject/networks': 5.8.0 - '@ethersproject/pbkdf2': 5.8.0 - '@ethersproject/properties': 5.8.0 - '@ethersproject/providers': 5.8.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - '@ethersproject/random': 5.8.0 - '@ethersproject/rlp': 5.8.0 - '@ethersproject/sha2': 5.8.0 - '@ethersproject/signing-key': 5.8.0 - '@ethersproject/solidity': 5.8.0 - '@ethersproject/strings': 5.8.0 - '@ethersproject/transactions': 5.8.0 - '@ethersproject/units': 5.8.0 - '@ethersproject/wallet': 5.8.0 - '@ethersproject/web': 5.8.0 - '@ethersproject/wordlists': 5.8.0 - transitivePeerDependencies: - - bufferutil - - utf-8-validate - - ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@5.0.10): + ethers@6.16.0(bufferutil@4.1.0)(utf-8-validate@6.0.5): dependencies: '@adraffy/ens-normalize': 1.10.1 '@noble/curves': 1.2.0 @@ -14908,34 +19354,32 @@ snapshots: '@types/node': 22.7.5 aes-js: 4.0.0-beta.5 tslib: 2.7.0 - ws: 8.17.1(bufferutil@4.1.0)(utf-8-validate@5.0.10) + ws: 8.17.1(bufferutil@4.1.0)(utf-8-validate@6.0.5) transitivePeerDependencies: - bufferutil - utf-8-validate - ethjs-unit@0.1.6: - dependencies: - bn.js: 5.2.3 - number-to-bn: 1.7.0 - ethjs-util@0.1.6: dependencies: is-hex-prefixed: 1.0.0 strip-hex-prefix: 1.0.0 - event-emitter@0.3.5: - dependencies: - d: 1.0.2 - es5-ext: 0.10.64 + event-target-shim@5.0.1: {} eventemitter2@6.4.9: {} - eventemitter3@3.1.2: {} - - eventemitter3@4.0.4: {} + eventemitter3@4.0.7: {} eventemitter3@5.0.1: {} + events-intercept@2.0.0: {} + + events-universal@1.0.1: + dependencies: + bare-events: 2.8.2 + transitivePeerDependencies: + - bare-abort-controller + events@3.3.0: {} evp_bytestokey@1.0.3: @@ -14943,6 +19387,19 @@ snapshots: md5.js: 1.3.5 safe-buffer: 5.2.1 + execa@3.2.0: + dependencies: + cross-spawn: 7.0.6 + get-stream: 5.2.0 + human-signals: 1.1.1 + is-stream: 2.0.1 + merge-stream: 2.0.0 + npm-run-path: 4.0.1 + onetime: 5.1.2 + p-finally: 2.0.1 + signal-exit: 3.0.7 + strip-final-newline: 2.0.0 + execa@5.1.1: dependencies: cross-spawn: 7.0.6 @@ -14955,85 +19412,70 @@ snapshots: signal-exit: 3.0.7 strip-final-newline: 2.0.0 - expect-type@1.3.0: {} - - express@4.22.1: + execa@8.0.1: dependencies: - accepts: 1.3.8 - array-flatten: 1.1.1 - body-parser: 1.20.5 - content-disposition: 0.5.4 - content-type: 1.0.5 - cookie: 0.7.2 - cookie-signature: 1.0.7 - debug: 2.6.9 - depd: 2.0.0 - encodeurl: 2.0.0 - escape-html: 1.0.3 - etag: 1.8.1 - finalhandler: 1.3.2 - fresh: 0.5.2 - http-errors: 2.0.1 - merge-descriptors: 1.0.3 - methods: 1.1.2 - on-finished: 2.4.1 - parseurl: 1.3.3 - path-to-regexp: 0.1.13 - proxy-addr: 2.0.7 - qs: 6.15.1 - range-parser: 1.2.1 - safe-buffer: 5.2.1 - send: 0.19.2 - serve-static: 1.16.3 - setprototypeof: 1.2.0 - statuses: 2.0.2 - type-is: 1.6.18 - utils-merge: 1.0.1 - vary: 1.1.2 - transitivePeerDependencies: - - supports-color + cross-spawn: 7.0.6 + get-stream: 8.0.1 + human-signals: 5.0.0 + is-stream: 3.0.0 + merge-stream: 2.0.0 + npm-run-path: 5.3.0 + onetime: 6.0.0 + signal-exit: 4.1.0 + strip-final-newline: 3.0.0 - ext@1.7.0: + execa@9.1.0: dependencies: - type: 2.7.3 + '@sindresorhus/merge-streams': 4.0.0 + cross-spawn: 7.0.6 + figures: 6.1.0 + get-stream: 9.0.1 + human-signals: 7.0.0 + is-plain-obj: 4.1.0 + is-stream: 4.0.1 + npm-run-path: 5.3.0 + pretty-ms: 9.0.0 + signal-exit: 4.1.0 + strip-final-newline: 4.0.0 + yoctocolors: 2.0.2 - extend@3.0.2: {} + expect-type@1.2.1: {} + + exsolve@1.0.8: {} extendable-error@0.1.7: {} + extension-port-stream@3.0.0: + dependencies: + readable-stream: 4.7.0 + webextension-polyfill: 0.10.0 + external-editor@3.1.0: dependencies: chardet: 0.7.0 iconv-lite: 0.4.24 - tmp: 0.2.5 + tmp: 0.0.33 - extsprintf@1.3.0: {} - - fake-indexeddb@4.0.2: - dependencies: - realistic-structured-clone: 3.0.0 - - fake-indexeddb@6.2.5: {} - - fake-merkle-patricia-tree@1.0.1: + externality@1.0.2: dependencies: - checkpoint-store: 1.1.0 + enhanced-resolve: 5.18.4 + mlly: 1.8.0 + pathe: 1.1.2 + ufo: 1.6.1 - fast-base64-decode@1.0.0: {} + fast-copy@3.0.2: {} fast-deep-equal@3.1.3: {} - fast-diff@1.3.0: {} + fast-fifo@1.3.2: {} - fast-equals@5.4.0: {} - - fast-glob@3.3.1: + fast-glob@3.3.2: dependencies: '@nodelib/fs.stat': 2.0.5 '@nodelib/fs.walk': 1.2.8 glob-parent: 5.1.2 merge2: 1.4.1 - micromatch: 4.0.8 + micromatch: 4.0.5 fast-glob@3.3.3: dependencies: @@ -15043,94 +19485,53 @@ snapshots: merge2: 1.4.1 micromatch: 4.0.8 - fast-json-patch@3.1.1: {} + fast-npm-meta@0.4.7: {} - fast-json-stable-stringify@2.1.0: {} - - fast-levenshtein@2.0.6: {} + fast-redact@3.1.2: {} fast-safe-stringify@2.1.1: {} - fast-uri@3.1.0: {} - - fast-xml-builder@1.1.5: + fast-xml-parser@5.2.5: dependencies: - path-expression-matcher: 1.5.0 + strnum: 2.1.2 - fast-xml-parser@5.7.1: + fastq@1.15.0: dependencies: - '@nodable/entities': 2.1.0 - fast-xml-builder: 1.1.5 - path-expression-matcher: 1.5.0 - strnum: 2.2.3 + reusify: 1.0.4 - fastq@1.19.1: + fd-slicer@1.1.0: dependencies: - reusify: 1.1.0 + pend: 1.2.0 + + fdir@6.1.1(picomatch@4.0.2): + optionalDependencies: + picomatch: 4.0.2 fdir@6.5.0(picomatch@4.0.3): optionalDependencies: picomatch: 4.0.3 - fdir@6.5.0(picomatch@4.0.4): - optionalDependencies: - picomatch: 4.0.4 + fflate@0.8.2: {} - fetch-blob@3.2.0: + figures@6.1.0: dependencies: - node-domexception: 1.0.0 - web-streams-polyfill: 3.3.3 + is-unicode-supported: 2.0.0 - figures@3.2.0: - dependencies: - escape-string-regexp: 1.0.5 + file-uri-to-path@1.0.0: {} - file-entry-cache@8.0.0: + fill-range@7.0.1: dependencies: - flat-cache: 4.0.1 + to-regex-range: 5.0.1 fill-range@7.1.1: dependencies: to-regex-range: 5.0.1 - finalhandler@1.1.2: - dependencies: - debug: 2.6.9 - encodeurl: 1.0.2 - escape-html: 1.0.3 - on-finished: 2.3.0 - parseurl: 1.3.3 - statuses: 1.5.0 - unpipe: 1.0.0 - transitivePeerDependencies: - - supports-color - - finalhandler@1.3.2: - dependencies: - debug: 2.6.9 - encodeurl: 2.0.0 - escape-html: 1.0.3 - on-finished: 2.4.1 - parseurl: 1.3.3 - statuses: 2.0.2 - unpipe: 1.0.0 - transitivePeerDependencies: - - supports-color - - find-cache-dir@3.3.2: - dependencies: - commondir: 1.0.1 - make-dir: 3.1.0 - pkg-dir: 4.2.0 - - find-replace@3.0.0: - dependencies: - array-back: 3.1.0 + filter-obj@1.1.0: {} - find-up@1.1.2: + find-up@2.1.0: dependencies: - path-exists: 2.1.0 - pinkie-promise: 2.0.1 + locate-path: 2.0.0 find-up@4.1.0: dependencies: @@ -15142,66 +19543,60 @@ snapshots: locate-path: 6.0.0 path-exists: 4.0.0 - flag@5.0.1(react@19.2.3): + fixturez@1.1.0: dependencies: - '@types/react': 18.3.28 - async-ref: 0.1.6 - react: 19.2.3 + fs-extra: 5.0.0 + globby: 7.1.1 + signal-exit: 3.0.7 + tempy: 0.2.1 - flat-cache@4.0.1: + flag@5.0.1(react@18.3.1): dependencies: - flatted: 3.4.2 - keyv: 4.5.4 + '@types/react': 18.3.27 + async-ref: 0.1.6 + react: 18.3.1 flat@5.0.2: {} - flatted@3.4.2: {} + floating-vue@5.2.2(@nuxt/kit@3.20.2(magicast@0.5.1))(vue@3.5.12(typescript@5.9.3)): + dependencies: + '@floating-ui/dom': 1.1.1 + vue: 3.5.12(typescript@5.9.3) + vue-resize: 2.0.0-alpha.1(vue@3.5.12(typescript@5.9.3)) + optionalDependencies: + '@nuxt/kit': 3.20.2(magicast@0.5.1) - fmix@0.1.0: + focus-trap@7.6.0: dependencies: - imul: 1.0.1 + tabbable: 6.2.0 - follow-redirects@1.16.0(debug@4.4.3): + follow-redirects@1.15.2(debug@4.3.4): optionalDependencies: - debug: 4.4.3(supports-color@5.5.0) + debug: 4.3.4(supports-color@8.1.1) for-each@0.3.5: dependencies: is-callable: 1.2.7 - foreground-child@2.0.0: - dependencies: - cross-spawn: 7.0.6 - signal-exit: 3.0.7 - foreground-child@3.3.1: dependencies: cross-spawn: 7.0.6 signal-exit: 4.1.0 - forever-agent@0.6.1: {} - - form-data-encoder@1.7.1: {} + fp-ts@1.19.3: {} - form-data@4.0.5: - dependencies: - asynckit: 0.4.0 - combined-stream: 1.0.8 - es-set-tostringtag: 2.1.0 - hasown: 2.0.3 - mime-types: 2.1.35 + fraction.js@5.3.4: {} - formdata-polyfill@4.0.10: + framer-motion@12.23.26(react-dom@18.3.1(react@18.3.1))(react@18.3.1): dependencies: - fetch-blob: 3.2.0 - - forwarded@0.2.0: {} - - fp-ts@1.19.3: {} - - fresh@0.5.2: {} + motion-dom: 12.23.23 + motion-utils: 12.23.6 + tslib: 2.8.1 + optionalDependencies: + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) - fromentries@1.3.2: {} + fresh@2.0.0: {} fs-extra@0.30.0: dependencies: @@ -15211,13 +19606,13 @@ snapshots: path-is-absolute: 1.0.1 rimraf: 2.7.1 - fs-extra@10.1.0: + fs-extra@11.1.0: dependencies: graceful-fs: 4.2.11 jsonfile: 6.2.0 universalify: 2.0.1 - fs-extra@4.0.3: + fs-extra@5.0.0: dependencies: graceful-fs: 4.2.11 jsonfile: 4.0.0 @@ -15235,11 +19630,9 @@ snapshots: jsonfile: 4.0.0 universalify: 0.1.2 - fs-minipass@3.0.3: + fs-minipass@2.1.0: dependencies: - minipass: 7.1.3 - - fs-readdir-recursive@1.1.0: {} + minipass: 3.3.6 fs.realpath@1.0.0: {} @@ -15248,52 +19641,16 @@ snapshots: function-bind@1.1.2: {} - function.prototype.name@1.1.8: - dependencies: - call-bind: 1.0.9 - call-bound: 1.0.4 - define-properties: 1.2.1 - functions-have-names: 1.2.3 - hasown: 2.0.3 - is-callable: 1.2.7 - - functional-red-black-tree@1.0.1: {} - - functions-have-names@1.2.3: {} - - ganache-cli@6.12.2: {} - - ganache@7.4.3: - optionalDependencies: - bufferutil: 4.0.5 - utf-8-validate: 5.0.7 - - ganache@7.9.2: - dependencies: - '@trufflesuite/uws-js-unofficial': 20.30.0-unofficial.0 - '@types/bn.js': 5.2.0 - '@types/lru-cache': 5.1.1 - '@types/seedrandom': 3.0.1 - abstract-level: 1.0.3 - abstract-leveldown: 7.2.0 - async-eventemitter: 0.2.4 - emittery: 0.10.0 - optionalDependencies: - bufferutil: 4.0.5 - utf-8-validate: 5.0.7 + fuse.js@7.1.0: {} generator-function@2.0.1: {} - gensync@1.0.0-beta.2: {} + generic-pool@3.4.2: {} - get-caller-file@1.0.3: {} + gensync@1.0.0-beta.2: {} get-caller-file@2.0.5: {} - get-east-asian-width@1.4.0: {} - - get-func-name@2.0.2: {} - get-intrinsic@1.3.0: dependencies: call-bind-apply-helpers: 1.0.2 @@ -15304,12 +19661,14 @@ snapshots: get-proto: 1.0.1 gopd: 1.2.0 has-symbols: 1.1.0 - hasown: 2.0.3 + hasown: 2.0.2 math-intrinsics: 1.1.0 - get-package-type@0.1.0: {} + get-nonce@1.0.1: {} - get-port@3.2.0: {} + get-port-please@3.2.0: {} + + get-port@7.1.0: {} get-proto@1.0.1: dependencies: @@ -15318,38 +19677,40 @@ snapshots: get-stream@5.2.0: dependencies: - pump: 3.0.4 + pump: 3.0.3 get-stream@6.0.1: {} - get-symbol-description@1.1.0: + get-stream@8.0.1: {} + + get-stream@9.0.1: dependencies: - call-bound: 1.0.4 - es-errors: 1.3.0 - get-intrinsic: 1.3.0 + '@sec-ant/readable-stream': 0.4.1 + is-stream: 4.0.1 - get-uri@6.0.5: + get-tsconfig@4.13.0: dependencies: - basic-ftp: 5.3.0 - data-uri-to-buffer: 6.0.2 - debug: 4.4.3(supports-color@5.5.0) - transitivePeerDependencies: - - supports-color + resolve-pkg-maps: 1.0.0 - getpass@0.1.7: + giget@2.0.0: dependencies: - assert-plus: 1.0.0 + citty: 0.1.6 + consola: 3.4.2 + defu: 6.1.4 + node-fetch-native: 1.6.7 + nypm: 0.6.2 + pathe: 2.0.3 - ghost-testrpc@0.0.2: + git-up@8.1.1: dependencies: - chalk: 2.4.2 - node-emoji: 1.11.0 + is-ssh: 1.4.1 + parse-url: 9.2.0 - glob-parent@5.1.2: + git-url-parse@16.1.0: dependencies: - is-glob: 4.0.3 + git-up: 8.1.1 - glob-parent@6.0.2: + glob-parent@5.1.2: dependencies: is-glob: 4.0.3 @@ -15357,31 +19718,23 @@ snapshots: dependencies: foreground-child: 3.3.1 jackspeak: 3.4.3 - minimatch: 10.2.5 - minipass: 7.1.3 + minimatch: 9.0.5 + minipass: 7.1.2 package-json-from-dist: 1.0.1 path-scurry: 1.11.1 - glob@13.0.6: - dependencies: - minimatch: 10.2.5 - minipass: 7.1.3 - path-scurry: 2.0.2 - - glob@5.0.15: + glob@13.0.0: dependencies: - inflight: 1.0.6 - inherits: 2.0.4 - minimatch: 10.2.5 - once: 1.4.0 - path-is-absolute: 1.0.1 + minimatch: 10.1.1 + minipass: 7.1.2 + path-scurry: 2.0.1 - glob@7.1.7: + glob@7.2.0: dependencies: fs.realpath: 1.0.0 inflight: 1.0.6 inherits: 2.0.4 - minimatch: 10.2.5 + minimatch: 3.1.2 once: 1.4.0 path-is-absolute: 1.0.1 @@ -15390,299 +19743,129 @@ snapshots: fs.realpath: 1.0.0 inflight: 1.0.6 inherits: 2.0.4 - minimatch: 10.2.5 + minimatch: 3.1.2 once: 1.4.0 path-is-absolute: 1.0.1 - glob@8.1.0: - dependencies: - fs.realpath: 1.0.0 - inflight: 1.0.6 - inherits: 2.0.4 - minimatch: 5.1.9 - once: 1.4.0 - - global-modules@2.0.0: - dependencies: - global-prefix: 3.0.0 - - global-prefix@3.0.0: - dependencies: - ini: 1.3.8 - kind-of: 6.0.3 - which: 1.3.1 - - global@4.4.0: + global-directory@4.0.1: dependencies: - min-document: 2.19.2 - process: 0.11.10 - - globals@14.0.0: {} + ini: 4.1.1 - globals@16.5.0: {} - - globalthis@1.0.4: - dependencies: - define-properties: 1.2.1 - gopd: 1.2.0 + globals@11.12.0: {} - globby@10.0.2: + globby@11.1.0: dependencies: - '@types/glob': 7.2.0 array-union: 2.1.0 dir-glob: 3.0.1 fast-glob: 3.3.3 - glob: 7.2.3 ignore: 5.3.2 merge2: 1.4.1 slash: 3.0.0 - globby@11.1.0: + globby@15.0.0: dependencies: - array-union: 2.1.0 - dir-glob: 3.0.1 + '@sindresorhus/merge-streams': 4.0.0 fast-glob: 3.3.3 - ignore: 5.3.2 - merge2: 1.4.1 - slash: 3.0.0 - - gopd@1.2.0: {} + ignore: 7.0.5 + path-type: 6.0.0 + slash: 5.1.0 + unicorn-magic: 0.3.0 - got@11.8.6: + globby@7.1.1: dependencies: - '@sindresorhus/is': 4.6.0 - '@szmarczak/http-timer': 4.0.6 - '@types/cacheable-request': 6.0.3 - '@types/responselike': 1.0.3 - cacheable-lookup: 5.0.4 - cacheable-request: 7.0.4 - decompress-response: 6.0.0 - http2-wrapper: 1.0.3 - lowercase-keys: 2.0.0 - p-cancelable: 2.1.1 - responselike: 2.0.1 - - got@12.1.0: - dependencies: - '@sindresorhus/is': 4.6.0 - '@szmarczak/http-timer': 5.0.1 - '@types/cacheable-request': 6.0.3 - '@types/responselike': 1.0.3 - cacheable-lookup: 6.1.0 - cacheable-request: 7.0.4 - decompress-response: 6.0.0 - form-data-encoder: 1.7.1 - get-stream: 6.0.1 - http2-wrapper: 2.2.1 - lowercase-keys: 3.0.0 - p-cancelable: 3.0.0 - responselike: 2.0.1 - - graceful-fs@4.2.11: {} + array-union: 1.0.2 + dir-glob: 2.2.2 + glob: 7.2.3 + ignore: 3.3.10 + pify: 3.0.0 + slash: 1.0.0 - gradient-string@2.0.2: - dependencies: - chalk: 4.1.2 - tinygradient: 1.1.5 + gopd@1.2.0: {} - graphql-http@1.22.4(graphql@15.10.2): - dependencies: - graphql: 15.10.2 + graceful-fs@4.2.11: {} - graphql-subscriptions@1.2.1(graphql@15.10.2): - dependencies: - graphql: 15.10.2 - iterall: 1.3.0 + graphql@16.8.1: {} - graphql-tag@2.12.6(graphql@15.10.2): + gzip-size@6.0.0: dependencies: - graphql: 15.10.2 - tslib: 2.8.1 - - graphql@15.10.2: {} + duplexer: 0.1.2 - handlebars@4.7.8: + gzip-size@7.0.0: dependencies: - minimist: 1.2.8 - neo-async: 2.6.2 - source-map: 0.6.1 - wordwrap: 1.0.0 - optionalDependencies: - uglify-js: 3.19.3 + duplexer: 0.1.2 - handlebars@4.7.9: + h3@1.15.4: dependencies: - minimist: 1.2.8 - neo-async: 2.6.2 - source-map: 0.6.1 - wordwrap: 1.0.0 - optionalDependencies: - uglify-js: 3.19.3 + cookie-es: 1.2.2 + crossws: 0.3.5 + defu: 6.1.4 + destr: 2.0.5 + iron-webcrypto: 1.2.1 + node-mock-http: 1.0.4 + radix3: 1.1.2 + ufo: 1.6.1 + uncrypto: 0.1.3 - happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3): + happy-dom@20.0.2: dependencies: - '@types/node': 25.3.0 + '@types/node': 20.19.27 '@types/whatwg-mimetype': 3.0.2 - '@types/ws': 8.18.1 - entities: 7.0.1 whatwg-mimetype: 3.0.0 - ws: 8.20.0(bufferutil@4.1.0)(utf-8-validate@6.0.3) - transitivePeerDependencies: - - bufferutil - - utf-8-validate - - har-schema@2.0.0: {} - - har-validator@5.1.5: - dependencies: - ajv: 8.20.0 - har-schema: 2.0.0 - - hardhat-deploy@0.11.45(bufferutil@4.1.0)(utf-8-validate@5.0.10): - dependencies: - '@ethersproject/abi': 5.8.0 - '@ethersproject/abstract-signer': 5.8.0 - '@ethersproject/address': 5.8.0 - '@ethersproject/bignumber': 5.8.0 - '@ethersproject/bytes': 5.8.0 - '@ethersproject/constants': 5.8.0 - '@ethersproject/contracts': 5.8.0 - '@ethersproject/providers': 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@ethersproject/solidity': 5.8.0 - '@ethersproject/transactions': 5.8.0 - '@ethersproject/wallet': 5.8.0 - '@types/qs': 6.15.0 - axios: 1.15.2(debug@4.4.3) - chalk: 4.1.2 - chokidar: 3.6.0 - debug: 4.4.3(supports-color@5.5.0) - enquirer: 2.4.1 - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - form-data: 4.0.5 - fs-extra: 10.1.0 - match-all: 1.2.7 - murmur-128: 0.2.1 - qs: 6.15.1 - zksync-web3: 0.14.4(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate - - hardhat-gas-reporter@1.0.10(bufferutil@4.1.0)(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10): - dependencies: - array-uniq: 1.0.3 - eth-gas-reporter: 0.2.27(bufferutil@4.1.0)(utf-8-validate@5.0.10) - hardhat: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10) - sha1: 1.1.1 - transitivePeerDependencies: - - '@codechecks/client' - - bufferutil - - debug - - utf-8-validate - - hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10): - dependencies: - '@ethereumjs/util': 9.1.0 - '@ethersproject/abi': 5.8.0 - '@nomicfoundation/edr': 0.12.0-next.23 - '@nomicfoundation/solidity-analyzer': 0.1.2 - '@sentry/node': 5.30.0 - adm-zip: 0.4.16 - aggregate-error: 3.1.0 - ansi-escapes: 4.3.2 - boxen: 5.1.2 - chokidar: 4.0.3 - ci-info: 2.0.0 - debug: 4.4.3(supports-color@5.5.0) - enquirer: 2.4.1 - env-paths: 2.2.1 - ethereum-cryptography: 1.2.0 - find-up: 5.0.0 - fp-ts: 1.19.3 - fs-extra: 7.0.1 - immutable: 4.3.8 - io-ts: 1.10.4 - json-stream-stringify: 3.1.6 - keccak: 3.0.4 - lodash: 4.18.1 - micro-eth-signer: 0.14.0 - mnemonist: 0.38.5 - mocha: 10.8.2 - p-map: 4.0.0 - picocolors: 1.1.1 - raw-body: 2.5.3 - resolve: 1.17.0 - semver: 6.3.1 - solc: 0.8.26(debug@4.4.3) - source-map-support: 0.5.21 - stacktrace-parser: 0.1.11 - tinyglobby: 0.2.16 - tsort: 0.0.1 - undici: 8.1.0 - uuid: 8.3.2 - ws: 7.5.10(bufferutil@4.1.0)(utf-8-validate@5.0.10) - optionalDependencies: - ts-node: 10.9.2(@types/node@25.6.0)(typescript@4.9.5) - typescript: 4.9.5 - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate - hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@5.0.10): + hardhat@2.22.3(bufferutil@4.1.0)(ts-node@10.9.1(@types/node@24.0.1)(typescript@5.9.3))(typescript@5.9.3)(utf-8-validate@5.0.10): dependencies: - '@ethereumjs/util': 9.1.0 - '@ethersproject/abi': 5.8.0 - '@nomicfoundation/edr': 0.12.0-next.23 - '@nomicfoundation/solidity-analyzer': 0.1.2 + '@ethersproject/abi': 5.7.0 + '@metamask/eth-sig-util': 4.0.1 + '@nomicfoundation/edr': 0.3.7 + '@nomicfoundation/ethereumjs-common': 4.0.4 + '@nomicfoundation/ethereumjs-tx': 5.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + '@nomicfoundation/solidity-analyzer': 0.1.1 '@sentry/node': 5.30.0 + '@types/bn.js': 5.1.5 + '@types/lru-cache': 5.1.1 adm-zip: 0.4.16 aggregate-error: 3.1.0 ansi-escapes: 4.3.2 boxen: 5.1.2 - chokidar: 4.0.3 + chalk: 2.4.2 + chokidar: 3.6.0 ci-info: 2.0.0 - debug: 4.4.3(supports-color@5.5.0) - enquirer: 2.4.1 + debug: 4.3.4(supports-color@8.1.1) + enquirer: 2.3.6 env-paths: 2.2.1 ethereum-cryptography: 1.2.0 - find-up: 5.0.0 + ethereumjs-abi: 0.6.8 + find-up: 2.1.0 fp-ts: 1.19.3 fs-extra: 7.0.1 - immutable: 4.3.8 + glob: 7.2.0 + immutable: 4.3.5 io-ts: 1.10.4 - json-stream-stringify: 3.1.6 - keccak: 3.0.4 - lodash: 4.18.1 - micro-eth-signer: 0.14.0 + keccak: 3.0.3 + lodash: 4.17.21 mnemonist: 0.38.5 - mocha: 10.8.2 + mocha: 10.2.0 p-map: 4.0.0 - picocolors: 1.1.1 - raw-body: 2.5.3 + raw-body: 2.5.1 resolve: 1.17.0 semver: 6.3.1 - solc: 0.8.26(debug@4.4.3) + solc: 0.7.3(debug@4.3.4) source-map-support: 0.5.21 - stacktrace-parser: 0.1.11 - tinyglobby: 0.2.16 + stacktrace-parser: 0.1.10 tsort: 0.0.1 - undici: 8.1.0 + undici: 5.28.3 uuid: 8.3.2 - ws: 7.5.10(bufferutil@4.1.0)(utf-8-validate@5.0.10) + ws: 7.5.9(bufferutil@4.1.0)(utf-8-validate@5.0.10) optionalDependencies: - ts-node: 10.9.2(@types/node@25.6.0)(typescript@5.9.3) + ts-node: 10.9.1(@types/node@24.0.1)(typescript@5.9.3) typescript: 5.9.3 transitivePeerDependencies: - bufferutil + - c-kzg - supports-color - utf-8-validate - has-bigints@1.1.0: {} - - has-flag@1.0.0: {} - has-flag@3.0.0: {} has-flag@4.0.0: {} @@ -15691,55 +19874,52 @@ snapshots: dependencies: es-define-property: 1.0.1 - has-proto@1.2.0: - dependencies: - dunder-proto: 1.0.1 - has-symbols@1.1.0: {} has-tostringtag@1.0.2: dependencies: has-symbols: 1.1.0 - hash-base@3.1.2: + hash-base@3.1.0: dependencies: inherits: 2.0.4 - readable-stream: 2.3.8 + readable-stream: 3.6.2 safe-buffer: 5.2.1 - to-buffer: 1.2.2 hash.js@1.1.7: dependencies: inherits: 2.0.4 minimalistic-assert: 1.0.1 - hasha@5.2.2: - dependencies: - is-stream: 2.0.1 - type-fest: 0.8.1 - hasown@2.0.2: dependencies: function-bind: 1.1.2 - hasown@2.0.3: + hast-util-to-html@9.0.3: dependencies: - function-bind: 1.1.2 - - he@1.2.0: {} + '@types/hast': 3.0.4 + '@types/unist': 3.0.2 + ccount: 2.0.1 + comma-separated-tokens: 2.0.3 + hast-util-whitespace: 3.0.0 + html-void-elements: 3.0.0 + mdast-util-to-hast: 13.1.0 + property-information: 6.5.0 + space-separated-tokens: 2.0.2 + stringify-entities: 4.0.4 + zwitch: 2.0.4 - header-case@1.0.1: + hast-util-whitespace@3.0.0: dependencies: - no-case: 2.3.2 - upper-case: 1.1.3 + '@types/hast': 3.0.4 - heap@0.2.7: {} + he@1.2.0: {} - hermes-estree@0.25.1: {} + headers-polyfill@4.0.2: {} - hermes-parser@0.25.1: - dependencies: - hermes-estree: 0.25.1 + help-me@5.0.0: {} + + highlight.js@10.7.3: {} hmac-drbg@1.0.1: dependencies: @@ -15747,91 +19927,78 @@ snapshots: minimalistic-assert: 1.0.1 minimalistic-crypto-utils: 1.0.1 - hosted-git-info@2.8.9: {} - - hosted-git-info@7.0.2: - dependencies: - lru-cache: 10.4.3 + hookable@5.5.3: {} html-escaper@2.0.2: {} - http-basic@8.1.3: - dependencies: - caseless: 0.12.0 - concat-stream: 1.6.2 - http-response-object: 3.0.2 - parse-cache-control: 1.0.1 + html-void-elements@3.0.0: {} - http-cache-semantics@4.2.0: {} + http-errors@1.4.0: + dependencies: + inherits: 2.0.1 + statuses: 1.5.0 - http-encoding@2.2.0: + http-errors@1.7.3: dependencies: - brotli-wasm: 3.0.1 - pify: 5.0.0 - zstd-codec: 0.1.5 + depd: 1.1.2 + inherits: 2.0.4 + setprototypeof: 1.1.1 + statuses: 1.5.0 + toidentifier: 1.0.0 - http-errors@2.0.1: + http-errors@2.0.0: dependencies: depd: 2.0.0 inherits: 2.0.4 setprototypeof: 1.2.0 - statuses: 2.0.2 + statuses: 2.0.1 toidentifier: 1.0.1 - http-https@1.0.0: {} - - http-proxy-agent@7.0.2: - dependencies: - agent-base: 7.1.4 - debug: 4.4.3(supports-color@5.5.0) - transitivePeerDependencies: - - supports-color - - http-response-object@3.0.2: - dependencies: - '@types/node': 10.17.60 - - http-signature@1.2.0: - dependencies: - assert-plus: 1.0.0 - jsprim: 1.4.2 - sshpk: 1.18.0 - - http-signature@1.4.0: + http-errors@2.0.1: dependencies: - assert-plus: 1.0.0 - jsprim: 2.0.2 - sshpk: 1.18.0 + depd: 2.0.0 + inherits: 2.0.4 + setprototypeof: 1.2.0 + statuses: 2.0.2 + toidentifier: 1.0.1 - http2-wrapper@1.0.3: + http-proxy@1.18.1: dependencies: - quick-lru: 5.1.1 - resolve-alpn: 1.2.1 + eventemitter3: 4.0.7 + follow-redirects: 1.15.2(debug@4.3.4) + requires-port: 1.0.0 + transitivePeerDependencies: + - debug - http2-wrapper@2.2.1: - dependencies: - quick-lru: 5.1.1 - resolve-alpn: 1.2.1 + http-shutdown@1.2.2: {} https-proxy-agent@5.0.1: dependencies: agent-base: 6.0.2 - debug: 4.4.3(supports-color@5.5.0) + debug: 4.4.3 transitivePeerDependencies: - supports-color https-proxy-agent@7.0.6: dependencies: agent-base: 7.1.4 - debug: 4.4.3(supports-color@5.5.0) + debug: 4.4.3 transitivePeerDependencies: - supports-color + httpxy@0.1.7: {} + + human-id@1.0.2: {} + human-id@4.1.3: {} + human-signals@1.1.1: {} + human-signals@2.1.0: {} - husky@9.1.7: {} + human-signals@5.0.0: {} + + human-signals@7.0.0: {} iconv-lite@0.4.24: dependencies: @@ -15840,44 +20007,34 @@ snapshots: iconv-lite@0.6.3: dependencies: safer-buffer: 2.1.2 - optional: true - iconv-lite@0.7.2: + iconv-lite@0.7.1: dependencies: safer-buffer: 2.1.2 - idb@7.1.1: {} - - idb@8.0.3: {} + idb-keyval@6.2.1: {} - idna-uts46-hx@2.3.1: - dependencies: - punycode: 2.1.0 + idb@7.1.1: {} ieee754@1.2.1: {} - ignore-by-default@1.0.1: {} + ignore@3.3.10: {} ignore@5.3.2: {} ignore@7.0.5: {} - immediate@3.2.3: {} - - immediate@3.3.0: {} - - immer@10.0.2: {} + image-meta@0.2.2: {} - immutable@4.3.8: {} + immutable@4.3.5: {} - import-fresh@3.3.1: + impound@1.0.0: dependencies: - parent-module: 1.0.1 - resolve-from: 4.0.0 - - imul@1.0.1: {} - - imurmurhash@0.1.4: {} + exsolve: 1.0.8 + mocked-exports: 0.1.1 + pathe: 2.0.3 + unplugin: 2.3.11 + unplugin-utils: 0.2.5 indent-string@4.0.0: {} @@ -15886,97 +20043,42 @@ snapshots: once: 1.4.0 wrappy: 1.0.2 + inherits@2.0.1: {} + inherits@2.0.4: {} ini@1.3.8: {} - inquirer@7.3.3: - dependencies: - ansi-escapes: 4.3.2 - chalk: 4.1.2 - cli-cursor: 3.1.0 - cli-width: 3.0.0 - external-editor: 3.1.0 - figures: 3.2.0 - lodash: 4.18.1 - mute-stream: 0.0.8 - run-async: 2.4.1 - rxjs: 6.6.7 - string-width: 4.2.3 - strip-ansi: 6.0.1 - through: 2.3.8 - - inquirer@8.2.7(@types/node@25.3.0): - dependencies: - '@inquirer/external-editor': 1.0.3(@types/node@25.3.0) - ansi-escapes: 4.3.2 - chalk: 4.1.2 - cli-cursor: 3.1.0 - cli-width: 3.0.0 - figures: 3.2.0 - lodash: 4.18.1 - mute-stream: 0.0.8 - ora: 5.4.1 - run-async: 2.4.1 - rxjs: 7.8.2 - string-width: 4.2.3 - strip-ansi: 6.0.1 - through: 2.3.8 - wrap-ansi: 6.2.0 - transitivePeerDependencies: - - '@types/node' - - internal-slot@1.1.0: - dependencies: - es-errors: 1.3.0 - hasown: 2.0.2 - side-channel: 1.1.0 - - interpret@1.4.0: {} - - invert-kv@1.0.0: {} + ini@4.1.1: {} io-ts@1.10.4: dependencies: fp-ts: 1.19.3 - ip-address@10.1.0: {} + ioredis@5.8.2: + dependencies: + '@ioredis/commands': 1.4.0 + cluster-key-slot: 1.1.2 + debug: 4.4.3 + denque: 2.1.0 + lodash.defaults: 4.2.0 + lodash.isarguments: 3.1.0 + redis-errors: 1.2.0 + redis-parser: 3.0.0 + standard-as-callback: 2.1.0 + transitivePeerDependencies: + - supports-color - ipaddr.js@1.9.1: {} + iron-webcrypto@1.2.1: {} is-arguments@1.2.0: dependencies: call-bound: 1.0.4 has-tostringtag: 1.0.2 - is-array-buffer@3.0.5: - dependencies: - call-bind: 1.0.9 - call-bound: 1.0.4 - get-intrinsic: 1.3.0 - - is-arrayish@0.2.1: {} - - is-async-function@2.1.1: - dependencies: - async-function: 1.0.0 - call-bound: 1.0.4 - get-proto: 1.0.1 - has-tostringtag: 1.0.2 - safe-regex-test: 1.1.0 - - is-bigint@1.1.0: - dependencies: - has-bigints: 1.1.0 - is-binary-path@2.1.0: dependencies: - binary-extensions: 2.3.0 - - is-boolean-object@1.2.2: - dependencies: - call-bound: 1.0.4 - has-tostringtag: 1.0.2 + binary-extensions: 2.2.0 is-buffer@2.0.5: {} @@ -15984,39 +20086,16 @@ snapshots: is-core-module@2.16.1: dependencies: - hasown: 2.0.3 - - is-data-view@1.0.2: - dependencies: - call-bound: 1.0.4 - get-intrinsic: 1.3.0 - is-typed-array: 1.1.15 - - is-date-object@1.1.0: - dependencies: - call-bound: 1.0.4 - has-tostringtag: 1.0.2 + hasown: 2.0.2 is-docker@2.2.1: {} - is-extglob@2.1.1: {} - - is-finalizationregistry@1.1.1: - dependencies: - call-bound: 1.0.4 - - is-fn@1.0.0: {} - - is-fullwidth-code-point@1.0.0: - dependencies: - number-is-nan: 1.0.1 + is-docker@3.0.0: {} - is-fullwidth-code-point@2.0.0: {} + is-extglob@2.1.1: {} is-fullwidth-code-point@3.0.0: {} - is-function@1.0.2: {} - is-generator-function@1.1.2: dependencies: call-bound: 1.0.4 @@ -16031,144 +20110,117 @@ snapshots: is-hex-prefixed@1.0.0: {} - is-interactive@1.0.0: {} - - is-lambda@1.0.1: {} - - is-lower-case@1.1.3: + is-inside-container@1.0.0: dependencies: - lower-case: 1.1.4 + is-docker: 3.0.0 - is-map@2.0.3: {} + is-installed-globally@1.0.0: + dependencies: + global-directory: 4.0.1 + is-path-inside: 4.0.0 - is-negative-zero@2.0.3: {} + is-module@1.0.0: {} - is-number-object@1.1.1: - dependencies: - call-bound: 1.0.4 - has-tostringtag: 1.0.2 + is-node-process@1.2.0: {} is-number@7.0.0: {} - is-observable@2.1.0: {} + is-path-inside@4.0.0: {} + + is-plain-obj@2.1.0: {} - is-path-cwd@2.2.0: {} + is-plain-obj@4.1.0: {} - is-path-inside@3.0.3: {} + is-plain-object@5.0.0: {} - is-plain-obj@2.1.0: {} + is-reference@1.2.1: + dependencies: + '@types/estree': 1.0.8 is-regex@1.2.1: dependencies: call-bound: 1.0.4 gopd: 1.2.0 has-tostringtag: 1.0.2 - hasown: 2.0.3 - - is-set@2.0.3: {} + hasown: 2.0.2 - is-shared-array-buffer@1.0.4: + is-ssh@1.4.1: dependencies: - call-bound: 1.0.4 + protocols: 2.0.2 is-stream@2.0.1: {} - is-string@1.1.1: - dependencies: - call-bound: 1.0.4 - has-tostringtag: 1.0.2 + is-stream@3.0.0: {} + + is-stream@4.0.1: {} is-subdir@1.2.0: dependencies: better-path-resolve: 1.0.0 - is-symbol@1.1.1: - dependencies: - call-bound: 1.0.4 - has-symbols: 1.1.0 - safe-regex-test: 1.1.0 - is-typed-array@1.1.15: dependencies: - which-typed-array: 1.1.20 - - is-typedarray@1.0.0: {} + which-typed-array: 1.1.19 is-unicode-supported@0.1.0: {} - is-upper-case@1.1.2: - dependencies: - upper-case: 1.1.3 + is-unicode-supported@2.0.0: {} - is-url@1.2.4: {} + is-what@4.1.16: {} - is-utf8@0.2.1: {} + is-what@5.5.0: {} - is-weakmap@2.0.2: {} + is-windows@1.0.2: {} - is-weakref@1.1.1: + is-wsl@2.2.0: dependencies: - call-bound: 1.0.4 + is-docker: 2.2.1 - is-weakset@2.0.4: + is-wsl@3.1.0: dependencies: - call-bound: 1.0.4 - get-intrinsic: 1.3.0 - - is-windows@1.0.2: {} + is-inside-container: 1.0.0 - is-wsl@2.2.0: + is64bit@2.0.0: dependencies: - is-docker: 2.2.1 + system-architecture: 0.1.0 isarray@0.0.1: {} isarray@1.0.0: {} - isarray@2.0.5: {} - - isbinaryfile@4.0.10: {} - isexe@2.0.0: {} - isomorphic-unfetch@3.1.0: - dependencies: - node-fetch: 3.3.2 - unfetch: 4.2.0 + isexe@3.1.1: {} - isomorphic-ws@4.0.1(ws@8.20.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)): + isows@1.0.4(ws@8.13.0(bufferutil@4.0.8)(utf-8-validate@6.0.5)): dependencies: - ws: 8.20.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + ws: 8.13.0(bufferutil@4.0.8)(utf-8-validate@6.0.5) - isows@1.0.7(ws@8.18.3(bufferutil@4.1.0)(utf-8-validate@6.0.3)): + isows@1.0.4(ws@8.13.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)): dependencies: - ws: 8.18.3(bufferutil@4.1.0)(utf-8-validate@6.0.3) + ws: 8.13.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) - isstream@0.1.2: {} + isows@1.0.4(ws@8.17.1(bufferutil@4.1.0)(utf-8-validate@5.0.10)): + dependencies: + ws: 8.17.1(bufferutil@4.1.0)(utf-8-validate@5.0.10) - istanbul-lib-coverage@3.2.2: {} + isows@1.0.6(ws@8.18.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)): + dependencies: + ws: 8.18.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - istanbul-lib-hook@3.0.0: + isows@1.0.7(ws@8.18.2(bufferutil@4.1.0)(utf-8-validate@6.0.5)): dependencies: - append-transform: 2.0.0 + ws: 8.18.2(bufferutil@4.1.0)(utf-8-validate@6.0.5) - istanbul-lib-instrument@4.0.3: + isows@1.0.7(ws@8.18.3(bufferutil@4.1.0)(utf-8-validate@5.0.10)): dependencies: - '@babel/core': 7.29.0 - '@istanbuljs/schema': 0.1.6 - istanbul-lib-coverage: 3.2.2 - semver: 6.3.1 - transitivePeerDependencies: - - supports-color + ws: 8.18.3(bufferutil@4.1.0)(utf-8-validate@5.0.10) - istanbul-lib-processinfo@2.0.3: + isows@1.0.7(ws@8.18.3(bufferutil@4.1.0)(utf-8-validate@6.0.5)): dependencies: - archy: 1.0.0 - cross-spawn: 7.0.6 - istanbul-lib-coverage: 3.2.2 - p-map: 3.0.0 - rimraf: 3.0.2 - uuid: 8.3.2 + ws: 8.18.3(bufferutil@4.1.0)(utf-8-validate@6.0.5) + + istanbul-lib-coverage@3.2.2: {} istanbul-lib-report@3.0.1: dependencies: @@ -16176,11 +20228,11 @@ snapshots: make-dir: 4.0.0 supports-color: 7.2.0 - istanbul-lib-source-maps@4.0.1: + istanbul-lib-source-maps@5.0.6: dependencies: - debug: 4.4.3(supports-color@5.5.0) + '@jridgewell/trace-mapping': 0.3.31 + debug: 4.4.3 istanbul-lib-coverage: 3.2.2 - source-map: 0.6.1 transitivePeerDependencies: - supports-color @@ -16189,65 +20241,61 @@ snapshots: html-escaper: 2.0.2 istanbul-lib-report: 3.0.1 - iterall@1.3.0: {} - - iterator.prototype@1.1.5: - dependencies: - define-data-property: 1.1.4 - es-object-atoms: 1.1.1 - get-intrinsic: 1.3.0 - get-proto: 1.0.1 - has-symbols: 1.1.0 - set-function-name: 2.0.2 - jackspeak@3.4.3: dependencies: '@isaacs/cliui': 8.0.2 optionalDependencies: '@pkgjs/parseargs': 0.11.0 + jiti@1.21.0: {} + + jiti@1.21.6: {} + + jiti@1.21.7: {} + + jiti@2.6.1: {} + + jose@5.9.6: {} + + joycon@3.1.1: {} + js-base64@3.7.8: {} - js-cookie@2.2.1: {} + js-beautify@1.15.1: + dependencies: + config-chain: 1.1.13 + editorconfig: 1.0.4 + glob: 10.5.0 + js-cookie: 3.0.5 + nopt: 7.2.1 - js-sha3@0.5.7: {} + js-cookie@3.0.5: {} js-sha3@0.8.0: {} - js-tokens@10.0.0: {} - js-tokens@4.0.0: {} - js-yaml@3.14.2: + js-tokens@9.0.1: {} + + js-yaml@3.14.1: dependencies: argparse: 1.0.10 esprima: 4.0.1 + js-yaml@4.1.0: + dependencies: + argparse: 2.0.1 + js-yaml@4.1.1: dependencies: argparse: 2.0.1 - jsbn@0.1.1: {} + jsesc@2.5.2: {} jsesc@3.1.0: {} - json-bigint@1.0.0: - dependencies: - bignumber.js: 9.3.1 - - json-buffer@3.0.1: {} - json-canonicalize@1.2.0: {} - json-canonicalize@2.0.0: {} - - json-parse-even-better-errors@2.3.1: {} - - json-rpc-engine@5.4.0: - dependencies: - eth-rpc-errors: 3.0.0 - safe-event-emitter: 1.0.1 - json-rpc-engine@6.1.0: dependencies: '@metamask/safe-event-emitter': 2.0.0 @@ -16255,29 +20303,12 @@ snapshots: json-rpc-random-id@1.0.1: {} - json-schema-traverse@0.4.1: {} - - json-schema-traverse@1.0.0: {} - - json-schema@0.4.0: {} - - json-stable-stringify-without-jsonify@1.0.1: {} - - json-stable-stringify@1.3.0: + json-schema-to-ts@1.6.4: dependencies: - call-bind: 1.0.9 - call-bound: 1.0.4 - isarray: 2.0.5 - jsonify: 0.0.1 - object-keys: 1.1.1 - - json-stream-stringify@3.1.6: {} - - json-stringify-safe@5.0.1: {} + '@types/json-schema': 7.0.15 + ts-toolbelt: 6.15.5 - json5@1.0.2: - dependencies: - minimist: 1.2.8 + json-schema-traverse@1.0.0: {} json5@2.2.3: {} @@ -16295,45 +20326,19 @@ snapshots: optionalDependencies: graceful-fs: 4.2.11 - jsonify@0.0.1: {} - - jsonparse@1.3.1: {} - - jsonschema@1.5.0: {} - - jsprim@1.4.2: - dependencies: - assert-plus: 1.0.0 - extsprintf: 1.3.0 - json-schema: 0.4.0 - verror: 1.10.0 - - jsprim@2.0.2: - dependencies: - assert-plus: 1.0.0 - extsprintf: 1.3.0 - json-schema: 0.4.0 - verror: 1.10.0 - - jsx-ast-utils@3.3.5: - dependencies: - array-includes: 3.1.9 - array.prototype.flat: 1.3.3 - object.assign: 4.1.7 - object.values: 1.2.1 - jwt-decode@4.0.0: {} keccak256@1.0.6: dependencies: - bn.js: 5.2.3 + bn.js: 5.2.2 buffer: 6.0.3 keccak: 3.0.4 - keccak@3.0.1: + keccak@3.0.3: dependencies: node-addon-api: 2.0.2 - node-gyp-build: 4.8.4 + node-gyp-build: 4.6.0 + readable-stream: 3.6.2 keccak@3.0.4: dependencies: @@ -16341,11 +20346,7 @@ snapshots: node-gyp-build: 4.8.4 readable-stream: 3.6.2 - keyv@4.5.4: - dependencies: - json-buffer: 3.0.1 - - kind-of@6.0.3: {} + keyvaluestorage-interface@1.0.0: {} klaw@1.3.1: optionalDependencies: @@ -16353,633 +20354,1021 @@ snapshots: kleur@3.0.3: {} - lcid@1.0.0: + kleur@4.1.5: {} + + klona@2.0.6: {} + + knip@5.30.6(@types/node@24.0.1)(typescript@5.8.3): + dependencies: + '@nodelib/fs.walk': 1.2.8 + '@snyk/github-codeowners': 1.1.0 + '@types/node': 24.0.1 + easy-table: 1.2.0 + enhanced-resolve: 5.17.1 + fast-glob: 3.3.2 + jiti: 1.21.6 + js-yaml: 4.1.0 + minimist: 1.2.8 + picocolors: 1.1.0 + picomatch: 4.0.2 + pretty-ms: 9.0.0 + smol-toml: 1.3.0 + strip-json-comments: 5.0.1 + summary: 2.1.0 + typescript: 5.8.3 + zod: 3.25.20 + zod-validation-error: 3.2.0(zod@3.25.20) + + knitwork@1.3.0: {} + + kolorist@1.8.0: {} + + launch-editor@2.12.0: + dependencies: + picocolors: 1.1.1 + shell-quote: 1.8.3 + + lazystream@1.0.1: dependencies: - invert-kv: 1.0.0 + readable-stream: 2.3.8 + + lefthook-darwin-arm64@1.13.6: + optional: true + + lefthook-darwin-x64@1.13.6: + optional: true + + lefthook-freebsd-arm64@1.13.6: + optional: true + + lefthook-freebsd-x64@1.13.6: + optional: true + + lefthook-linux-arm64@1.13.6: + optional: true + + lefthook-linux-x64@1.13.6: + optional: true + + lefthook-openbsd-arm64@1.13.6: + optional: true + + lefthook-openbsd-x64@1.13.6: + optional: true + + lefthook-windows-arm64@1.13.6: + optional: true + + lefthook-windows-x64@1.13.6: + optional: true + + lefthook@1.13.6: + optionalDependencies: + lefthook-darwin-arm64: 1.13.6 + lefthook-darwin-x64: 1.13.6 + lefthook-freebsd-arm64: 1.13.6 + lefthook-freebsd-x64: 1.13.6 + lefthook-linux-arm64: 1.13.6 + lefthook-linux-x64: 1.13.6 + lefthook-openbsd-arm64: 1.13.6 + lefthook-openbsd-x64: 1.13.6 + lefthook-windows-arm64: 1.13.6 + lefthook-windows-x64: 1.13.6 + + lightningcss-android-arm64@1.30.2: + optional: true + + lightningcss-darwin-arm64@1.30.2: + optional: true + + lightningcss-darwin-x64@1.30.2: + optional: true + + lightningcss-freebsd-x64@1.30.2: + optional: true + + lightningcss-linux-arm-gnueabihf@1.30.2: + optional: true + + lightningcss-linux-arm64-gnu@1.30.2: + optional: true + + lightningcss-linux-arm64-musl@1.30.2: + optional: true + + lightningcss-linux-x64-gnu@1.30.2: + optional: true - lefthook-darwin-arm64@2.1.6: + lightningcss-linux-x64-musl@1.30.2: optional: true - lefthook-darwin-x64@2.1.6: + lightningcss-win32-arm64-msvc@1.30.2: optional: true - lefthook-freebsd-arm64@2.1.6: + lightningcss-win32-x64-msvc@1.30.2: optional: true - lefthook-freebsd-x64@2.1.6: - optional: true + lightningcss@1.30.2: + dependencies: + detect-libc: 2.1.2 + optionalDependencies: + lightningcss-android-arm64: 1.30.2 + lightningcss-darwin-arm64: 1.30.2 + lightningcss-darwin-x64: 1.30.2 + lightningcss-freebsd-x64: 1.30.2 + lightningcss-linux-arm-gnueabihf: 1.30.2 + lightningcss-linux-arm64-gnu: 1.30.2 + lightningcss-linux-arm64-musl: 1.30.2 + lightningcss-linux-x64-gnu: 1.30.2 + lightningcss-linux-x64-musl: 1.30.2 + lightningcss-win32-arm64-msvc: 1.30.2 + lightningcss-win32-x64-msvc: 1.30.2 + + lilconfig@3.1.3: {} + + listhen@1.7.2: + dependencies: + '@parcel/watcher': 2.5.1 + '@parcel/watcher-wasm': 2.4.1 + citty: 0.1.6 + clipboardy: 4.0.0 + consola: 3.4.2 + crossws: 0.2.4 + defu: 6.1.4 + get-port-please: 3.2.0 + h3: 1.15.4 + http-shutdown: 1.2.2 + jiti: 1.21.7 + mlly: 1.8.0 + node-forge: 1.3.1 + pathe: 1.1.2 + std-env: 3.10.0 + ufo: 1.6.1 + untun: 0.1.3 + uqr: 0.1.2 + transitivePeerDependencies: + - uWebSockets.js + + listhen@1.9.0: + dependencies: + '@parcel/watcher': 2.5.1 + '@parcel/watcher-wasm': 2.5.1 + citty: 0.1.6 + clipboardy: 4.0.0 + consola: 3.4.2 + crossws: 0.3.5 + defu: 6.1.4 + get-port-please: 3.2.0 + h3: 1.15.4 + http-shutdown: 1.2.2 + jiti: 2.6.1 + mlly: 1.8.0 + node-forge: 1.3.3 + pathe: 1.1.2 + std-env: 3.10.0 + ufo: 1.6.1 + untun: 0.1.3 + uqr: 0.1.2 + + lit-element@4.2.0: + dependencies: + '@lit-labs/ssr-dom-shim': 1.3.0 + '@lit/reactive-element': 2.1.0 + lit-html: 3.3.0 + + lit-html@3.3.0: + dependencies: + '@types/trusted-types': 2.0.3 + + lit@3.1.0: + dependencies: + '@lit/reactive-element': 2.1.0 + lit-element: 4.2.0 + lit-html: 3.3.0 + + load-tsconfig@0.2.5: {} + + local-pkg@0.5.0: + dependencies: + mlly: 1.8.0 + pkg-types: 1.3.1 + + local-pkg@0.5.1: + dependencies: + mlly: 1.8.0 + pkg-types: 1.3.1 + + local-pkg@1.1.2: + dependencies: + mlly: 1.8.0 + pkg-types: 2.3.0 + quansync: 0.2.11 + + locate-path@2.0.0: + dependencies: + p-locate: 2.0.0 + path-exists: 3.0.0 - lefthook-linux-arm64@2.1.6: - optional: true + locate-path@5.0.0: + dependencies: + p-locate: 4.1.0 - lefthook-linux-x64@2.1.6: - optional: true + locate-path@6.0.0: + dependencies: + p-locate: 5.0.0 - lefthook-openbsd-arm64@2.1.6: - optional: true + lodash.defaults@4.2.0: {} - lefthook-openbsd-x64@2.1.6: - optional: true + lodash.isarguments@3.1.0: {} - lefthook-windows-arm64@2.1.6: - optional: true + lodash.memoize@4.1.2: {} - lefthook-windows-x64@2.1.6: - optional: true + lodash.startcase@4.4.0: {} - lefthook@2.1.6: - optionalDependencies: - lefthook-darwin-arm64: 2.1.6 - lefthook-darwin-x64: 2.1.6 - lefthook-freebsd-arm64: 2.1.6 - lefthook-freebsd-x64: 2.1.6 - lefthook-linux-arm64: 2.1.6 - lefthook-linux-x64: 2.1.6 - lefthook-openbsd-arm64: 2.1.6 - lefthook-openbsd-x64: 2.1.6 - lefthook-windows-arm64: 2.1.6 - lefthook-windows-x64: 2.1.6 + lodash.uniq@4.5.0: {} - level-codec@7.0.1: {} + lodash@4.17.21: {} - level-codec@9.0.2: + log-symbols@4.1.0: dependencies: - buffer: 5.7.1 + chalk: 4.1.2 + is-unicode-supported: 0.1.0 - level-concat-iterator@2.0.1: {} + lokijs@1.5.12: {} - level-concat-iterator@3.1.0: - dependencies: - catering: 2.1.1 + longest-streak@3.1.0: {} - level-errors@1.0.5: + loose-envify@1.4.0: dependencies: - errno: 0.1.8 + js-tokens: 4.0.0 - level-errors@2.0.1: - dependencies: - errno: 0.1.8 + loupe@3.1.3: {} - level-iterator-stream@1.3.1: - dependencies: - inherits: 2.0.4 - level-errors: 1.0.5 - readable-stream: 1.1.14 - xtend: 4.0.2 + lru-cache@10.2.2: {} - level-iterator-stream@4.0.2: - dependencies: - inherits: 2.0.4 - readable-stream: 3.6.2 - xtend: 4.0.2 + lru-cache@10.4.3: {} + + lru-cache@11.2.4: {} - level-mem@5.0.1: + lru-cache@4.1.5: dependencies: - level-packager: 5.1.1 - memdown: 5.1.0 + pseudomap: 1.0.2 + yallist: 2.1.2 - level-packager@5.1.1: + lru-cache@5.1.1: dependencies: - encoding-down: 6.3.0 - levelup: 4.4.0 + yallist: 3.1.1 - level-supports@1.0.1: + lru-cache@6.0.0: dependencies: - xtend: 4.0.2 + yallist: 4.0.0 - level-supports@2.1.0: {} + lru_map@0.3.3: {} - level-supports@4.0.1: {} + lz-string@1.5.0: {} - level-transcoder@1.0.1: + magic-regexp@0.10.0: dependencies: - buffer: 6.0.3 - module-error: 1.0.2 + estree-walker: 3.0.3 + magic-string: 0.30.21 + mlly: 1.8.0 + regexp-tree: 0.1.27 + type-level-regexp: 0.1.17 + ufo: 1.6.1 + unplugin: 2.3.11 - level-ws@0.0.0: + magic-string-ast@1.0.3: dependencies: - readable-stream: 1.0.34 - xtend: 2.1.2 + magic-string: 0.30.21 - level-ws@2.0.0: + magic-string@0.30.10: dependencies: - inherits: 2.0.4 - readable-stream: 3.6.2 - xtend: 4.0.2 + '@jridgewell/sourcemap-codec': 1.4.15 - levelup@1.3.9: + magic-string@0.30.12: dependencies: - deferred-leveldown: 1.2.2 - level-codec: 7.0.1 - level-errors: 1.0.5 - level-iterator-stream: 1.3.1 - prr: 1.0.1 - semver: 7.7.4 - xtend: 4.0.2 + '@jridgewell/sourcemap-codec': 1.5.0 - levelup@4.4.0: + magic-string@0.30.17: dependencies: - deferred-leveldown: 5.3.0 - level-errors: 2.0.1 - level-iterator-stream: 4.0.2 - level-supports: 1.0.1 - xtend: 4.0.2 + '@jridgewell/sourcemap-codec': 1.5.0 - levn@0.3.0: + magic-string@0.30.21: dependencies: - prelude-ls: 1.1.2 - type-check: 0.3.2 + '@jridgewell/sourcemap-codec': 1.5.5 - levn@0.4.1: + magicast@0.3.5: dependencies: - prelude-ls: 1.2.1 - type-check: 0.4.0 - - lines-and-columns@1.2.4: {} + '@babel/parser': 7.28.5 + '@babel/types': 7.28.5 + source-map-js: 1.2.1 - load-json-file@1.1.0: + magicast@0.5.1: dependencies: - graceful-fs: 4.2.11 - parse-json: 2.2.0 - pify: 2.3.0 - pinkie-promise: 2.0.1 - strip-bom: 2.0.0 + '@babel/parser': 7.28.5 + '@babel/types': 7.28.5 + source-map-js: 1.2.1 - locate-path@5.0.0: + make-dir@4.0.0: dependencies: - p-locate: 4.1.0 + semver: 7.7.3 - locate-path@6.0.0: - dependencies: - p-locate: 5.0.0 + make-error@1.3.6: {} - lodash.assign@4.2.0: {} + mark.js@8.11.1: {} - lodash.camelcase@4.3.0: {} + markdown-table@3.0.3: {} - lodash.clonedeep@4.5.0: {} + marked-terminal@7.1.0(marked@9.1.6): + dependencies: + ansi-escapes: 7.0.0 + chalk: 5.3.0 + cli-highlight: 2.1.11 + cli-table3: 0.6.5 + marked: 9.1.6 + node-emoji: 2.1.3 + supports-hyperlinks: 3.0.0 - lodash.flattendeep@4.4.0: {} + marked@9.1.6: {} - lodash.get@4.4.2: {} + math-intrinsics@1.1.0: {} - lodash.isequal@4.5.0: {} + md5.js@1.3.5: + dependencies: + hash-base: 3.1.0 + inherits: 2.0.4 + safe-buffer: 5.2.1 - lodash.merge@4.6.2: {} + mdast-util-find-and-replace@3.0.1: + dependencies: + '@types/mdast': 4.0.3 + escape-string-regexp: 5.0.0 + unist-util-is: 6.0.0 + unist-util-visit-parents: 6.0.1 + + mdast-util-from-markdown@2.0.2: + dependencies: + '@types/mdast': 4.0.3 + '@types/unist': 3.0.2 + decode-named-character-reference: 1.0.2 + devlop: 1.1.0 + mdast-util-to-string: 4.0.0 + micromark: 4.0.0 + micromark-util-decode-numeric-character-reference: 2.0.1 + micromark-util-decode-string: 2.0.0 + micromark-util-normalize-identifier: 2.0.0 + micromark-util-symbol: 2.0.0 + micromark-util-types: 2.0.0 + unist-util-stringify-position: 4.0.0 + transitivePeerDependencies: + - supports-color - lodash.startcase@4.4.0: {} + mdast-util-gfm-autolink-literal@2.0.0: + dependencies: + '@types/mdast': 4.0.3 + ccount: 2.0.1 + devlop: 1.1.0 + mdast-util-find-and-replace: 3.0.1 + micromark-util-character: 2.1.0 - lodash.truncate@4.4.2: {} + mdast-util-gfm-footnote@2.0.0: + dependencies: + '@types/mdast': 4.0.3 + devlop: 1.1.0 + mdast-util-from-markdown: 2.0.2 + mdast-util-to-markdown: 2.1.0 + micromark-util-normalize-identifier: 2.0.0 + transitivePeerDependencies: + - supports-color - lodash@4.18.1: {} + mdast-util-gfm-strikethrough@2.0.0: + dependencies: + '@types/mdast': 4.0.3 + mdast-util-from-markdown: 2.0.2 + mdast-util-to-markdown: 2.1.0 + transitivePeerDependencies: + - supports-color - log-symbols@3.0.0: + mdast-util-gfm-table@2.0.0: dependencies: - chalk: 2.4.2 + '@types/mdast': 4.0.3 + devlop: 1.1.0 + markdown-table: 3.0.3 + mdast-util-from-markdown: 2.0.2 + mdast-util-to-markdown: 2.1.0 + transitivePeerDependencies: + - supports-color - log-symbols@4.1.0: + mdast-util-gfm-task-list-item@2.0.0: dependencies: - chalk: 4.1.2 - is-unicode-supported: 0.1.0 + '@types/mdast': 4.0.3 + devlop: 1.1.0 + mdast-util-from-markdown: 2.0.2 + mdast-util-to-markdown: 2.1.0 + transitivePeerDependencies: + - supports-color - loose-envify@1.4.0: + mdast-util-gfm@3.0.0: dependencies: - js-tokens: 4.0.0 + mdast-util-from-markdown: 2.0.2 + mdast-util-gfm-autolink-literal: 2.0.0 + mdast-util-gfm-footnote: 2.0.0 + mdast-util-gfm-strikethrough: 2.0.0 + mdast-util-gfm-table: 2.0.0 + mdast-util-gfm-task-list-item: 2.0.0 + mdast-util-to-markdown: 2.1.0 + transitivePeerDependencies: + - supports-color + + mdast-util-phrasing@4.1.0: + dependencies: + '@types/mdast': 4.0.3 + unist-util-is: 6.0.0 - loupe@2.3.7: + mdast-util-to-hast@13.1.0: dependencies: - get-func-name: 2.0.2 + '@types/hast': 3.0.4 + '@types/mdast': 4.0.3 + '@ungap/structured-clone': 1.2.0 + devlop: 1.1.0 + micromark-util-sanitize-uri: 2.0.0 + trim-lines: 3.0.1 + unist-util-position: 5.0.0 + unist-util-visit: 5.0.0 + vfile: 6.0.1 - lower-case-first@1.0.2: + mdast-util-to-hast@13.2.0: dependencies: - lower-case: 1.1.4 + '@types/hast': 3.0.4 + '@types/mdast': 4.0.3 + '@ungap/structured-clone': 1.2.0 + devlop: 1.1.0 + micromark-util-sanitize-uri: 2.0.0 + trim-lines: 3.0.1 + unist-util-position: 5.0.0 + unist-util-visit: 5.0.0 + vfile: 6.0.1 - lower-case@1.1.4: {} + mdast-util-to-markdown@2.1.0: + dependencies: + '@types/mdast': 4.0.3 + '@types/unist': 3.0.2 + longest-streak: 3.1.0 + mdast-util-phrasing: 4.1.0 + mdast-util-to-string: 4.0.0 + micromark-util-decode-string: 2.0.0 + unist-util-visit: 5.0.0 + zwitch: 2.0.4 - lowercase-keys@2.0.0: {} + mdast-util-to-string@4.0.0: + dependencies: + '@types/mdast': 4.0.3 - lowercase-keys@3.0.0: {} + mdn-data@2.0.28: {} - lru-cache@10.4.3: {} + mdn-data@2.0.30: {} - lru-cache@11.3.5: {} + mdn-data@2.12.2: {} - lru-cache@5.1.1: - dependencies: - yallist: 3.1.1 + memorystream@0.3.1: {} - lru-cache@7.18.3: {} + merge-stream@2.0.0: {} - lru_map@0.3.3: {} + merge2@1.4.1: {} - ltgt@2.2.1: {} + micro-ftch@0.3.1: {} - magic-string@0.30.21: + micro@9.3.5-canary.3: dependencies: - '@jridgewell/sourcemap-codec': 1.5.5 + arg: 4.1.0 + content-type: 1.0.4 + raw-body: 2.4.1 - magicast@0.5.1: + micromark-core-commonmark@2.0.1: dependencies: - '@babel/parser': 7.28.5 - '@babel/types': 7.28.5 - source-map-js: 1.2.1 + decode-named-character-reference: 1.0.2 + devlop: 1.1.0 + micromark-factory-destination: 2.0.0 + micromark-factory-label: 2.0.0 + micromark-factory-space: 2.0.0 + micromark-factory-title: 2.0.0 + micromark-factory-whitespace: 2.0.0 + micromark-util-character: 2.1.0 + micromark-util-chunked: 2.0.0 + micromark-util-classify-character: 2.0.0 + micromark-util-html-tag-name: 2.0.0 + micromark-util-normalize-identifier: 2.0.0 + micromark-util-resolve-all: 2.0.0 + micromark-util-subtokenize: 2.0.1 + micromark-util-symbol: 2.0.0 + micromark-util-types: 2.0.0 - make-dir@3.1.0: + micromark-factory-destination@2.0.0: dependencies: - semver: 6.3.1 + micromark-util-character: 2.1.0 + micromark-util-symbol: 2.0.0 + micromark-util-types: 2.0.0 - make-dir@4.0.0: + micromark-factory-label@2.0.0: dependencies: - semver: 7.7.4 + devlop: 1.1.0 + micromark-util-character: 2.1.0 + micromark-util-symbol: 2.0.0 + micromark-util-types: 2.0.0 - make-error@1.3.6: {} - - make-fetch-happen@13.0.1: - dependencies: - '@npmcli/agent': 2.2.2 - cacache: 18.0.4 - http-cache-semantics: 4.2.0 - is-lambda: 1.0.1 - minipass: 7.1.3 - minipass-fetch: 3.0.5 - minipass-flush: 1.0.7 - minipass-pipeline: 1.2.4 - negotiator: 0.6.4 - proc-log: 4.2.0 - promise-retry: 2.0.1 - ssri: 10.0.6 - transitivePeerDependencies: - - supports-color + micromark-factory-space@2.0.0: + dependencies: + micromark-util-character: 2.1.0 + micromark-util-types: 2.0.0 - markdown-table@1.1.3: {} + micromark-factory-title@2.0.0: + dependencies: + micromark-factory-space: 2.0.0 + micromark-util-character: 2.1.0 + micromark-util-symbol: 2.0.0 + micromark-util-types: 2.0.0 - match-all@1.2.7: {} + micromark-factory-whitespace@2.0.0: + dependencies: + micromark-factory-space: 2.0.0 + micromark-util-character: 2.1.0 + micromark-util-symbol: 2.0.0 + micromark-util-types: 2.0.0 - math-intrinsics@1.1.0: {} + micromark-util-character@2.1.0: + dependencies: + micromark-util-symbol: 2.0.0 + micromark-util-types: 2.0.0 - mcl-wasm@0.7.9: {} + micromark-util-chunked@2.0.0: + dependencies: + micromark-util-symbol: 2.0.0 - md5.js@1.3.5: + micromark-util-classify-character@2.0.0: dependencies: - hash-base: 3.1.2 - inherits: 2.0.4 - safe-buffer: 5.2.1 + micromark-util-character: 2.1.0 + micromark-util-symbol: 2.0.0 + micromark-util-types: 2.0.0 - media-typer@0.3.0: {} + micromark-util-combine-extensions@2.0.0: + dependencies: + micromark-util-chunked: 2.0.0 + micromark-util-types: 2.0.0 - memdown@1.4.1: + micromark-util-decode-numeric-character-reference@2.0.1: dependencies: - abstract-leveldown: 2.7.2 - functional-red-black-tree: 1.0.1 - immediate: 3.3.0 - inherits: 2.0.4 - ltgt: 2.2.1 - safe-buffer: 5.1.2 + micromark-util-symbol: 2.0.0 - memdown@5.1.0: + micromark-util-decode-string@2.0.0: dependencies: - abstract-leveldown: 6.2.3 - functional-red-black-tree: 1.0.1 - immediate: 3.2.3 - inherits: 2.0.4 - ltgt: 2.2.1 - safe-buffer: 5.2.1 + decode-named-character-reference: 1.0.2 + micromark-util-character: 2.1.0 + micromark-util-decode-numeric-character-reference: 2.0.1 + micromark-util-symbol: 2.0.0 - memorystream@0.3.1: {} + micromark-util-encode@2.0.0: {} - merge-descriptors@1.0.3: {} + micromark-util-html-tag-name@2.0.0: {} - merge-stream@2.0.0: {} + micromark-util-normalize-identifier@2.0.0: + dependencies: + micromark-util-symbol: 2.0.0 - merge2@1.4.1: {} + micromark-util-resolve-all@2.0.0: + dependencies: + micromark-util-types: 2.0.0 - merkle-patricia-tree@2.3.2: + micromark-util-sanitize-uri@2.0.0: dependencies: - async: 1.5.2 - ethereumjs-util: 5.2.1 - level-ws: 0.0.0 - levelup: 1.3.9 - memdown: 1.4.1 - readable-stream: 2.3.8 - rlp: 2.2.7 - semaphore: 1.1.0 + micromark-util-character: 2.1.0 + micromark-util-encode: 2.0.0 + micromark-util-symbol: 2.0.0 - merkle-patricia-tree@4.2.4: + micromark-util-subtokenize@2.0.1: dependencies: - '@types/levelup': 4.3.3 - ethereumjs-util: 7.1.5 - level-mem: 5.0.1 - level-ws: 2.0.0 - readable-stream: 3.6.2 - semaphore-async-await: 1.5.1 + devlop: 1.1.0 + micromark-util-chunked: 2.0.0 + micromark-util-symbol: 2.0.0 + micromark-util-types: 2.0.0 - methods@1.1.2: {} + micromark-util-symbol@2.0.0: {} - micro-eth-signer@0.14.0: - dependencies: - '@noble/curves': 1.8.2 - '@noble/hashes': 1.7.2 - micro-packed: 0.7.3 + micromark-util-types@2.0.0: {} - micro-ftch@0.3.1: {} + micromark@4.0.0: + dependencies: + '@types/debug': 4.1.7 + debug: 4.4.3 + decode-named-character-reference: 1.0.2 + devlop: 1.1.0 + micromark-core-commonmark: 2.0.1 + micromark-factory-space: 2.0.0 + micromark-util-character: 2.1.0 + micromark-util-chunked: 2.0.0 + micromark-util-combine-extensions: 2.0.0 + micromark-util-decode-numeric-character-reference: 2.0.1 + micromark-util-encode: 2.0.0 + micromark-util-normalize-identifier: 2.0.0 + micromark-util-resolve-all: 2.0.0 + micromark-util-sanitize-uri: 2.0.0 + micromark-util-subtokenize: 2.0.1 + micromark-util-symbol: 2.0.0 + micromark-util-types: 2.0.0 + transitivePeerDependencies: + - supports-color - micro-packed@0.7.3: + micromatch@4.0.5: dependencies: - '@scure/base': 1.2.6 + braces: 3.0.2 + picomatch: 2.3.1 micromatch@4.0.8: dependencies: braces: 3.0.3 - picomatch: 2.3.2 - - miller-rabin@4.0.1: - dependencies: - bn.js: 5.2.3 - brorand: 1.1.0 + picomatch: 2.3.1 mime-db@1.52.0: {} + mime-db@1.54.0: {} + mime-types@2.1.35: dependencies: mime-db: 1.52.0 - mime@1.6.0: {} + mime-types@3.0.2: + dependencies: + mime-db: 1.54.0 - mimic-fn@2.1.0: {} + mime@3.0.0: {} - mimic-response@1.0.1: {} + mime@4.1.0: {} - mimic-response@3.1.0: {} + mimic-fn@2.1.0: {} - min-document@2.19.2: - dependencies: - dom-walk: 0.1.2 + mimic-fn@4.0.0: {} minimalistic-assert@1.0.1: {} minimalistic-crypto-utils@1.0.1: {} - minimatch@10.2.5: + minimatch@10.1.1: dependencies: - brace-expansion: 5.0.5 + '@isaacs/brace-expansion': 5.0.0 - minimatch@3.1.5: + minimatch@3.1.2: dependencies: - brace-expansion: 1.1.14 + brace-expansion: 1.1.11 - minimatch@5.1.9: + minimatch@5.0.1: dependencies: - brace-expansion: 2.1.0 + brace-expansion: 2.0.1 - minimist@1.2.8: {} - - minipass-collect@2.0.1: + minimatch@5.1.6: dependencies: - minipass: 7.1.3 + brace-expansion: 2.0.2 - minipass-fetch@3.0.5: + minimatch@9.0.1: dependencies: - minipass: 7.1.3 - minipass-sized: 1.0.3 - minizlib: 2.1.2 - optionalDependencies: - encoding: 0.1.13 + brace-expansion: 2.0.1 - minipass-flush@1.0.7: + minimatch@9.0.4: dependencies: - minipass: 3.3.6 + brace-expansion: 2.0.1 - minipass-pipeline@1.2.4: + minimatch@9.0.5: dependencies: - minipass: 3.3.6 + brace-expansion: 2.0.2 - minipass-sized@1.0.3: - dependencies: - minipass: 3.3.6 + minimist@1.2.8: {} minipass@3.3.6: dependencies: yallist: 4.0.0 - minipass@7.1.3: {} + minipass@5.0.0: {} + + minipass@7.1.2: {} + + minisearch@7.1.0: {} minizlib@2.1.2: dependencies: minipass: 3.3.6 yallist: 4.0.0 + minizlib@3.0.1: + dependencies: + minipass: 7.1.2 + rimraf: 5.0.10 + minizlib@3.1.0: dependencies: - minipass: 7.1.3 + minipass: 7.1.2 + + mipd@0.0.7(typescript@5.8.3): + optionalDependencies: + typescript: 5.8.3 mipd@0.0.7(typescript@5.9.3): optionalDependencies: typescript: 5.9.3 - mkdirp-promise@5.0.1: - dependencies: - mkdirp: 3.0.1 - - mkdirp@0.5.6: - dependencies: - minimist: 1.2.8 + mitt@3.0.1: {} mkdirp@1.0.4: {} mkdirp@3.0.1: {} + mlly@1.7.0: + dependencies: + acorn: 8.11.3 + pathe: 1.1.2 + pkg-types: 1.3.1 + ufo: 1.6.1 + + mlly@1.8.0: + dependencies: + acorn: 8.15.0 + pathe: 2.0.3 + pkg-types: 1.3.1 + ufo: 1.6.1 + mnemonist@0.38.5: dependencies: - obliterator: 2.0.5 + obliterator: 2.0.4 - mocha@10.8.2: + mocha@10.2.0: dependencies: - ansi-colors: 4.1.3 + ansi-colors: 4.1.1 browser-stdout: 1.3.1 - chokidar: 3.6.0 - debug: 4.4.3(supports-color@8.1.1) - diff: 5.2.2 + chokidar: 3.5.3 + debug: 4.3.4(supports-color@8.1.1) + diff: 5.0.0 escape-string-regexp: 4.0.0 find-up: 5.0.0 - glob: 8.1.0 + glob: 7.2.0 he: 1.2.0 - js-yaml: 4.1.1 + js-yaml: 4.1.0 log-symbols: 4.1.0 - minimatch: 5.1.9 + minimatch: 5.0.1 ms: 2.1.3 - serialize-javascript: 7.0.5 + nanoid: 3.3.3 + serialize-javascript: 6.0.0 strip-json-comments: 3.1.1 supports-color: 8.1.1 - workerpool: 6.5.1 + workerpool: 6.2.1 yargs: 16.2.0 - yargs-parser: 20.2.9 + yargs-parser: 20.2.4 yargs-unparser: 2.0.0 - mock-fs@4.14.0: {} - - mockttp@3.17.1(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@5.0.10): - dependencies: - '@graphql-tools/schema': 8.5.1(graphql@15.10.2) - '@graphql-tools/utils': 8.13.1(graphql@15.10.2) - '@httptoolkit/httpolyglot': 2.2.2 - '@httptoolkit/subscriptions-transport-ws': 0.11.2(bufferutil@4.1.0)(graphql@15.10.2)(utf-8-validate@5.0.10) - '@httptoolkit/websocket-stream': 6.0.1(bufferutil@4.1.0)(utf-8-validate@5.0.10) - '@types/cors': 2.8.19 - '@types/node': 25.6.0 - async-mutex: 0.5.0 - base64-arraybuffer: 0.1.5 - body-parser: 1.20.5 - cacheable-lookup: 6.1.0 - common-tags: 1.8.2 - connect: 3.7.0 - cors: 2.8.6 - cors-gate: 1.1.3 - cross-fetch: 3.2.0(encoding@0.1.13) - destroyable-server: 1.1.1 - express: 4.22.1 - fast-json-patch: 3.1.1 - graphql: 15.10.2 - graphql-http: 1.22.4(graphql@15.10.2) - graphql-subscriptions: 1.2.1(graphql@15.10.2) - graphql-tag: 2.12.6(graphql@15.10.2) - http-encoding: 2.2.0 - http2-wrapper: 2.2.1 - https-proxy-agent: 5.0.1 - isomorphic-ws: 4.0.1(ws@8.20.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) - lodash: 4.18.1 - lru-cache: 7.18.3 - native-duplexpair: 1.0.0 - node-forge: 1.4.0 - pac-proxy-agent: 7.2.0 - parse-multipart-data: 1.5.0 - performance-now: 2.1.0 - portfinder: 1.0.38 - read-tls-client-hello: 1.1.0 - semver: 7.7.4 - socks-proxy-agent: 7.0.0 - typed-error: 3.2.3 - urlpattern-polyfill: 8.0.2 - uuid: 8.3.2 - ws: 8.20.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) - transitivePeerDependencies: - - bufferutil - - encoding - - supports-color - - utf-8-validate + mocked-exports@0.1.1: {} - module-error@1.0.2: {} + motion-dom@12.23.23: + dependencies: + motion-utils: 12.23.6 - mri@1.2.0: {} + motion-utils@12.23.6: {} - ms@2.0.0: {} + motion@12.23.26(react-dom@18.3.1(react@18.3.1))(react@18.3.1): + dependencies: + framer-motion: 12.23.26(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + tslib: 2.8.1 + optionalDependencies: + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) - ms@2.1.3: {} + mri@1.2.0: {} - multibase@0.6.1: - dependencies: - base-x: 3.0.11 - buffer: 5.7.1 + mrmime@2.0.1: {} - multibase@0.7.0: - dependencies: - base-x: 3.0.11 - buffer: 5.7.1 + ms@2.1.1: {} - multicodec@0.5.7: - dependencies: - varint: 5.0.2 + ms@2.1.2: {} - multicodec@1.0.4: - dependencies: - buffer: 5.7.1 - varint: 5.0.2 + ms@2.1.3: {} - multihashes@0.4.21: + msw@2.4.9(typescript@5.8.3): dependencies: - buffer: 5.7.1 - multibase: 0.7.0 - varint: 5.0.2 + '@bundled-es-modules/cookie': 2.0.0 + '@bundled-es-modules/statuses': 1.0.1 + '@bundled-es-modules/tough-cookie': 0.1.6 + '@inquirer/confirm': 3.1.6 + '@mswjs/interceptors': 0.35.9 + '@open-draft/until': 2.1.0 + '@types/cookie': 0.6.0 + '@types/statuses': 2.0.4 + chalk: 4.1.2 + graphql: 16.8.1 + headers-polyfill: 4.0.2 + is-node-process: 1.2.0 + outvariant: 1.4.2 + path-to-regexp: 6.3.0 + strict-event-emitter: 0.5.1 + type-fest: 4.18.2 + yargs: 17.7.2 + optionalDependencies: + typescript: 5.8.3 + optional: true - murmur-128@0.2.1: + msw@2.4.9(typescript@5.9.3): dependencies: - encode-utf8: 1.0.3 - fmix: 0.1.0 - imul: 1.0.1 - - mute-stream@0.0.8: {} - - nan@2.26.2: {} - - nano-json-stream-parser@0.1.2: {} + '@bundled-es-modules/cookie': 2.0.0 + '@bundled-es-modules/statuses': 1.0.1 + '@bundled-es-modules/tough-cookie': 0.1.6 + '@inquirer/confirm': 3.1.6 + '@mswjs/interceptors': 0.35.9 + '@open-draft/until': 2.1.0 + '@types/cookie': 0.6.0 + '@types/statuses': 2.0.4 + chalk: 4.1.2 + graphql: 16.8.1 + headers-polyfill: 4.0.2 + is-node-process: 1.2.0 + outvariant: 1.4.2 + path-to-regexp: 6.3.0 + strict-event-emitter: 0.5.1 + type-fest: 4.18.2 + yargs: 17.7.2 + optionalDependencies: + typescript: 5.9.3 - nanoid@3.3.11: {} + muggle-string@0.4.1: {} - native-duplexpair@1.0.0: {} + multiformats@9.9.0: {} - natural-compare@1.4.0: {} + mute-stream@1.0.0: {} - ndjson@2.0.0: + mz@2.7.0: dependencies: - json-stringify-safe: 5.0.1 - minimist: 1.2.8 - readable-stream: 3.6.2 - split2: 3.2.2 - through2: 4.0.2 + any-promise: 1.3.0 + object-assign: 4.1.1 + thenify-all: 1.6.0 + + nanoid@3.3.11: {} - negotiator@0.6.3: {} + nanoid@3.3.3: {} - negotiator@0.6.4: {} + nanoid@3.3.7: {} - neo-async@2.6.2: {} + nanoid@5.1.6: {} - netmask@2.1.1: {} + nanospinner@1.2.2: + dependencies: + picocolors: 1.1.1 - next-tick@1.1.0: {} + nanotar@0.2.0: {} - next@16.2.4(react-dom@19.2.3(react@19.2.3))(react@19.2.3): + next@15.4.10(react-dom@18.3.1(react@18.3.1))(react@18.3.1): dependencies: - '@next/env': 16.2.4 + '@next/env': 15.4.10 '@swc/helpers': 0.5.15 - baseline-browser-mapping: 2.10.21 - caniuse-lite: 1.0.30001790 + caniuse-lite: 1.0.30001761 postcss: 8.4.31 - react: 19.2.3 - react-dom: 19.2.3(react@19.2.3) - styled-jsx: 5.1.6(react@19.2.3) + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + styled-jsx: 5.1.6(react@18.3.1) optionalDependencies: - '@next/swc-darwin-arm64': 16.2.4 - '@next/swc-darwin-x64': 16.2.4 - '@next/swc-linux-arm64-gnu': 16.2.4 - '@next/swc-linux-arm64-musl': 16.2.4 - '@next/swc-linux-x64-gnu': 16.2.4 - '@next/swc-linux-x64-musl': 16.2.4 - '@next/swc-win32-arm64-msvc': 16.2.4 - '@next/swc-win32-x64-msvc': 16.2.4 + '@next/swc-darwin-arm64': 15.4.8 + '@next/swc-darwin-x64': 15.4.8 + '@next/swc-linux-arm64-gnu': 15.4.8 + '@next/swc-linux-arm64-musl': 15.4.8 + '@next/swc-linux-x64-gnu': 15.4.8 + '@next/swc-linux-x64-musl': 15.4.8 + '@next/swc-win32-arm64-msvc': 15.4.8 + '@next/swc-win32-x64-msvc': 15.4.8 sharp: 0.34.5 transitivePeerDependencies: - '@babel/core' - babel-plugin-macros - no-case@2.3.2: - dependencies: - lower-case: 1.1.4 + nitropack@2.12.9(@vercel/blob@1.0.2)(encoding@0.1.13)(idb-keyval@6.2.1)(rolldown@1.0.0-beta.35): + dependencies: + '@cloudflare/kv-asset-handler': 0.4.1 + '@rollup/plugin-alias': 5.1.1(rollup@4.54.0) + '@rollup/plugin-commonjs': 28.0.9(rollup@4.54.0) + '@rollup/plugin-inject': 5.0.5(rollup@4.54.0) + '@rollup/plugin-json': 6.1.0(rollup@4.54.0) + '@rollup/plugin-node-resolve': 16.0.3(rollup@4.54.0) + '@rollup/plugin-replace': 6.0.3(rollup@4.54.0) + '@rollup/plugin-terser': 0.4.4(rollup@4.54.0) + '@vercel/nft': 0.30.4(encoding@0.1.13)(rollup@4.54.0) + archiver: 7.0.1 + c12: 3.3.3(magicast@0.5.1) + chokidar: 4.0.3 + citty: 0.1.6 + compatx: 0.2.0 + confbox: 0.2.2 + consola: 3.4.2 + cookie-es: 2.0.0 + croner: 9.1.0 + crossws: 0.3.5 + db0: 0.3.4 + defu: 6.1.4 + destr: 2.0.5 + dot-prop: 10.1.0 + esbuild: 0.25.12 + escape-string-regexp: 5.0.0 + etag: 1.8.1 + exsolve: 1.0.8 + globby: 15.0.0 + gzip-size: 7.0.0 + h3: 1.15.4 + hookable: 5.5.3 + httpxy: 0.1.7 + ioredis: 5.8.2 + jiti: 2.6.1 + klona: 2.0.6 + knitwork: 1.3.0 + listhen: 1.9.0 + magic-string: 0.30.21 + magicast: 0.5.1 + mime: 4.1.0 + mlly: 1.8.0 + node-fetch-native: 1.6.7 + node-mock-http: 1.0.4 + ofetch: 1.5.1 + ohash: 2.0.11 + pathe: 2.0.3 + perfect-debounce: 2.0.0 + pkg-types: 2.3.0 + pretty-bytes: 7.1.0 + radix3: 1.1.2 + rollup: 4.54.0 + rollup-plugin-visualizer: 6.0.5(rolldown@1.0.0-beta.35)(rollup@4.54.0) + scule: 1.3.0 + semver: 7.7.3 + serve-placeholder: 2.0.2 + serve-static: 2.2.1 + source-map: 0.7.6 + std-env: 3.10.0 + ufo: 1.6.1 + ultrahtml: 1.6.0 + uncrypto: 0.1.3 + unctx: 2.5.0 + unenv: 2.0.0-rc.24 + unimport: 5.6.0 + unplugin-utils: 0.3.1 + unstorage: 1.17.3(@vercel/blob@1.0.2)(db0@0.3.4)(idb-keyval@6.2.1)(ioredis@5.8.2) + untyped: 2.0.0 + unwasm: 0.3.11 + youch: 4.1.0-beta.13 + youch-core: 0.3.3 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@deno/kv' + - '@electric-sql/pglite' + - '@libsql/client' + - '@netlify/blobs' + - '@planetscale/database' + - '@upstash/redis' + - '@vercel/blob' + - '@vercel/functions' + - '@vercel/kv' + - aws4fetch + - bare-abort-controller + - better-sqlite3 + - drizzle-orm + - encoding + - idb-keyval + - mysql2 + - react-native-b4a + - rolldown + - sqlite3 + - supports-color + - uploadthing node-addon-api@2.0.2: {} - node-addon-api@5.1.0: {} + node-addon-api@7.1.1: {} + + node-emoji@2.1.3: + dependencies: + '@sindresorhus/is': 4.6.0 + char-regex: 1.0.2 + emojilib: 2.4.0 + skin-tone: 2.0.0 + + node-fetch-native@1.6.4: {} - node-domexception@1.0.0: {} + node-fetch-native@1.6.7: {} - node-emoji@1.11.0: + node-fetch@2.6.7(encoding@0.1.13): dependencies: - lodash: 4.18.1 + whatwg-url: 5.0.0 + optionalDependencies: + encoding: 0.1.13 - node-exports-info@1.6.0: + node-fetch@2.6.9(encoding@0.1.13): dependencies: - array.prototype.flatmap: 1.3.3 - es-errors: 1.3.0 - object.entries: 1.1.9 - semver: 6.3.1 + whatwg-url: 5.0.0 + optionalDependencies: + encoding: 0.1.13 node-fetch@2.7.0(encoding@0.1.13): dependencies: @@ -16987,197 +21376,214 @@ snapshots: optionalDependencies: encoding: 0.1.13 - node-fetch@3.3.2: - dependencies: - data-uri-to-buffer: 4.0.1 - fetch-blob: 3.2.0 - formdata-polyfill: 4.0.10 + node-forge@1.3.1: {} - node-forge@1.4.0: {} + node-forge@1.3.3: {} - node-gyp-build@4.3.0: - optional: true + node-gyp-build@4.6.0: {} node-gyp-build@4.8.4: {} - node-plop@0.26.3: - dependencies: - '@babel/runtime-corejs3': 7.28.4 - '@types/inquirer': 6.5.0 - change-case: 3.1.0 - del: 5.1.0 - globby: 10.0.2 - handlebars: 4.7.8 - inquirer: 7.3.3 - isbinaryfile: 4.0.10 - lodash.get: 4.4.2 - mkdirp: 0.5.6 - resolve: 1.22.12 - - node-preload@0.2.1: - dependencies: - process-on-spawn: 1.1.0 - - node-releases@2.0.27: {} - - node-releases@2.0.38: {} + node-mock-http@1.0.4: {} - nodemon@3.1.14: - dependencies: - chokidar: 3.6.0 - debug: 4.4.3(supports-color@5.5.0) - ignore-by-default: 1.0.1 - minimatch: 10.2.5 - pstree.remy: 1.1.8 - semver: 7.7.4 - simple-update-notifier: 2.0.0 - supports-color: 5.5.0 - touch: 3.1.1 - undefsafe: 2.0.5 + node-releases@2.0.14: {} - nofilter@3.1.0: {} + node-releases@2.0.27: {} - nopt@3.0.6: + nopt@7.2.1: dependencies: - abbrev: 1.0.9 + abbrev: 2.0.0 - normalize-package-data@2.5.0: + nopt@8.1.0: dependencies: - hosted-git-info: 2.8.9 - resolve: 1.22.12 - semver: 7.7.4 - validate-npm-package-license: 3.0.4 + abbrev: 3.0.1 normalize-path@3.0.0: {} - normalize-url@6.1.0: {} - - npm-package-arg@11.0.3: + npm-run-path@4.0.1: dependencies: - hosted-git-info: 7.0.2 - proc-log: 4.2.0 - semver: 7.7.4 - validate-npm-package-name: 5.0.1 + path-key: 3.1.1 - npm-registry-fetch@17.1.0: + npm-run-path@5.3.0: dependencies: - '@npmcli/redact': 2.0.1 - jsonparse: 1.3.1 - make-fetch-happen: 13.0.1 - minipass: 7.1.3 - minipass-fetch: 3.0.5 - minizlib: 2.1.2 - npm-package-arg: 11.0.3 - proc-log: 4.2.0 - transitivePeerDependencies: - - supports-color + path-key: 4.0.0 - npm-run-path@4.0.1: + npm-run-path@6.0.0: dependencies: - path-key: 3.1.1 - - number-is-nan@1.0.1: {} + path-key: 4.0.0 + unicorn-magic: 0.3.0 - number-to-bn@1.7.0: + nth-check@2.1.1: dependencies: - bn.js: 5.2.3 - strip-hex-prefix: 1.0.0 + boolbase: 1.0.0 - nyc@15.1.0: + nuxt@3.19.0(@biomejs/biome@1.9.4)(@parcel/watcher@2.5.1)(@types/node@24.0.1)(@vercel/blob@1.0.2)(@vue/compiler-sfc@3.5.26)(bufferutil@4.1.0)(cac@6.7.14)(db0@0.3.4)(encoding@0.1.13)(idb-keyval@6.2.1)(ioredis@5.8.2)(lightningcss@1.30.2)(magicast@0.5.1)(rolldown@1.0.0-beta.35)(rollup@4.54.0)(terser@5.44.1)(tsx@4.19.2)(typescript@5.9.3)(utf-8-validate@6.0.5)(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(yaml@2.8.2): dependencies: - '@istanbuljs/load-nyc-config': 1.1.0 - '@istanbuljs/schema': 0.1.6 - caching-transform: 4.0.0 - convert-source-map: 1.9.0 - decamelize: 1.2.0 - find-cache-dir: 3.3.2 - find-up: 4.1.0 - foreground-child: 2.0.0 - get-package-type: 0.1.0 - glob: 7.2.3 - istanbul-lib-coverage: 3.2.2 - istanbul-lib-hook: 3.0.0 - istanbul-lib-instrument: 4.0.3 - istanbul-lib-processinfo: 2.0.3 - istanbul-lib-report: 3.0.1 - istanbul-lib-source-maps: 4.0.1 - istanbul-reports: 3.2.0 - make-dir: 3.1.0 - node-preload: 0.2.1 - p-map: 3.0.0 - process-on-spawn: 1.1.0 - resolve-from: 5.0.0 - rimraf: 3.0.2 - signal-exit: 3.0.7 - spawn-wrap: 2.0.0 - test-exclude: 6.0.0 - yargs: 15.4.1 + '@nuxt/cli': 3.31.3(cac@6.7.14)(magicast@0.5.1) + '@nuxt/devalue': 2.0.2 + '@nuxt/devtools': 2.7.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(vue@3.5.26(typescript@5.9.3)) + '@nuxt/kit': 3.19.0(magicast@0.5.1) + '@nuxt/schema': 3.19.0 + '@nuxt/telemetry': 2.6.6(magicast@0.5.1) + '@nuxt/vite-builder': 3.19.0(@biomejs/biome@1.9.4)(@types/node@24.0.1)(lightningcss@1.30.2)(magicast@0.5.1)(rolldown@1.0.0-beta.35)(rollup@4.54.0)(terser@5.44.1)(tsx@4.19.2)(typescript@5.9.3)(vue@3.5.26(typescript@5.9.3))(yaml@2.8.2) + '@unhead/vue': 2.1.1(vue@3.5.26(typescript@5.9.3)) + '@vue/shared': 3.5.26 + c12: 3.3.3(magicast@0.5.1) + chokidar: 4.0.3 + compatx: 0.2.0 + consola: 3.4.2 + cookie-es: 2.0.0 + defu: 6.1.4 + destr: 2.0.5 + devalue: 5.6.1 + errx: 0.1.0 + esbuild: 0.25.12 + escape-string-regexp: 5.0.0 + estree-walker: 3.0.3 + exsolve: 1.0.8 + h3: 1.15.4 + hookable: 5.5.3 + ignore: 7.0.5 + impound: 1.0.0 + jiti: 2.6.1 + klona: 2.0.6 + knitwork: 1.3.0 + magic-string: 0.30.21 + mlly: 1.8.0 + mocked-exports: 0.1.1 + nanotar: 0.2.0 + nitropack: 2.12.9(@vercel/blob@1.0.2)(encoding@0.1.13)(idb-keyval@6.2.1)(rolldown@1.0.0-beta.35) + nypm: 0.6.2 + ofetch: 1.5.1 + ohash: 2.0.11 + on-change: 5.0.1 + oxc-minify: 0.86.0 + oxc-parser: 0.86.0 + oxc-transform: 0.86.0 + oxc-walker: 0.4.0(oxc-parser@0.86.0) + pathe: 2.0.3 + perfect-debounce: 2.0.0 + pkg-types: 2.3.0 + radix3: 1.1.2 + scule: 1.3.0 + semver: 7.7.3 + std-env: 3.10.0 + strip-literal: 3.1.0 + tinyglobby: 0.2.14 + ufo: 1.6.1 + ultrahtml: 1.6.0 + uncrypto: 0.1.3 + unctx: 2.5.0 + unimport: 5.6.0 + unplugin: 2.3.11 + unplugin-vue-router: 0.15.0(@vue/compiler-sfc@3.5.26)(vue-router@4.6.4(vue@3.5.26(typescript@5.9.3)))(vue@3.5.26(typescript@5.9.3)) + unstorage: 1.17.3(@vercel/blob@1.0.2)(db0@0.3.4)(idb-keyval@6.2.1)(ioredis@5.8.2) + untyped: 2.0.0 + vue: 3.5.26(typescript@5.9.3) + vue-bundle-renderer: 2.2.0 + vue-devtools-stub: 0.1.0 + vue-router: 4.6.4(vue@3.5.26(typescript@5.9.3)) + optionalDependencies: + '@parcel/watcher': 2.5.1 + '@types/node': 24.0.1 transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@biomejs/biome' + - '@capacitor/preferences' + - '@deno/kv' + - '@electric-sql/pglite' + - '@libsql/client' + - '@netlify/blobs' + - '@planetscale/database' + - '@upstash/redis' + - '@vercel/blob' + - '@vercel/functions' + - '@vercel/kv' + - '@vue/compiler-sfc' + - aws4fetch + - bare-abort-controller + - better-sqlite3 + - bufferutil + - cac + - commander + - db0 + - drizzle-orm + - encoding + - eslint + - idb-keyval + - ioredis + - less + - lightningcss + - magicast + - meow + - mysql2 + - optionator + - react-native-b4a + - rolldown + - rollup + - sass + - sass-embedded + - sqlite3 + - stylelint + - stylus + - sugarss - supports-color + - terser + - tsx + - typescript + - uploadthing + - utf-8-validate + - vite + - vls + - vti + - vue-tsc + - xml2js + - yaml - oauth-sign@0.9.0: {} - - object-assign@4.1.1: {} - - object-inspect@1.13.4: {} - - object-keys@0.4.0: {} - - object-keys@1.1.1: {} - - object.assign@4.1.7: + nypm@0.6.2: dependencies: - call-bind: 1.0.9 - call-bound: 1.0.4 - define-properties: 1.2.1 - es-object-atoms: 1.1.1 - has-symbols: 1.1.0 - object-keys: 1.1.1 + citty: 0.1.6 + consola: 3.4.2 + pathe: 2.0.3 + pkg-types: 2.3.0 + tinyexec: 1.0.2 - object.entries@1.1.9: + obj-multiplex@1.0.0: dependencies: - call-bind: 1.0.8 - call-bound: 1.0.4 - define-properties: 1.2.1 - es-object-atoms: 1.1.1 + end-of-stream: 1.4.5 + once: 1.4.0 + readable-stream: 2.3.8 - object.fromentries@2.0.8: - dependencies: - call-bind: 1.0.9 - define-properties: 1.2.1 - es-abstract: 1.24.2 - es-object-atoms: 1.1.1 + object-assign@4.1.1: {} - object.groupby@1.0.3: - dependencies: - call-bind: 1.0.9 - define-properties: 1.2.1 - es-abstract: 1.24.2 + obliterator@2.0.4: {} - object.values@1.2.1: + ofetch@1.5.1: dependencies: - call-bind: 1.0.9 - call-bound: 1.0.4 - define-properties: 1.2.1 - es-object-atoms: 1.1.1 + destr: 2.0.5 + node-fetch-native: 1.6.7 + ufo: 1.6.1 - obliterator@2.0.5: {} + ohash@2.0.11: {} - oboe@2.1.5: - dependencies: - http-https: 1.0.0 + on-change@5.0.1: {} - observable-fns@0.6.1: {} + on-exit-leak-free@0.2.0: {} - obug@2.1.1: {} + on-exit-leak-free@2.1.2: {} - on-finished@2.3.0: + on-finished@2.4.1: dependencies: ee-first: 1.1.1 - on-finished@2.4.1: + once@1.3.3: dependencies: - ee-first: 1.1.1 + wrappy: 1.0.2 once@1.4.0: dependencies: @@ -17187,66 +21593,76 @@ snapshots: dependencies: mimic-fn: 2.1.0 + onetime@6.0.0: + dependencies: + mimic-fn: 4.0.0 + + oniguruma-to-js@0.4.3: + dependencies: + regex: 4.4.0 + + open@10.2.0: + dependencies: + default-browser: 5.4.0 + define-lazy-prop: 3.0.0 + is-inside-container: 1.0.0 + wsl-utils: 0.1.0 + open@8.4.2: dependencies: define-lazy-prop: 2.0.0 is-docker: 2.2.1 is-wsl: 2.2.0 - optionator@0.8.3: + openapi-fetch@0.13.8: dependencies: - deep-is: 0.1.4 - fast-levenshtein: 2.0.6 - levn: 0.3.0 - prelude-ls: 1.1.2 - type-check: 0.3.2 - word-wrap: 1.2.5 + openapi-typescript-helpers: 0.0.15 - optionator@0.9.4: - dependencies: - deep-is: 0.1.4 - fast-levenshtein: 2.0.6 - levn: 0.4.1 - prelude-ls: 1.2.1 - type-check: 0.4.0 - word-wrap: 1.2.5 + openapi-typescript-helpers@0.0.15: {} - ora@4.1.1: - dependencies: - chalk: 3.0.0 - cli-cursor: 3.1.0 - cli-spinners: 2.9.2 - is-interactive: 1.0.0 - log-symbols: 3.0.0 - mute-stream: 0.0.8 - strip-ansi: 6.0.1 - wcwidth: 1.0.1 + opener@1.5.2: {} - ora@5.4.1: - dependencies: - bl: 4.1.0 - chalk: 4.1.2 - cli-cursor: 3.1.0 - cli-spinners: 2.9.2 - is-interactive: 1.0.0 - is-unicode-supported: 0.1.0 - log-symbols: 4.1.0 - strip-ansi: 6.0.1 - wcwidth: 1.0.1 + os-paths@4.4.0: {} - os-locale@1.4.0: - dependencies: - lcid: 1.0.0 + os-tmpdir@1.0.2: {} outdent@0.5.0: {} - own-keys@1.0.1: + outvariant@1.4.2: {} + + outvariant@1.4.3: {} + + ox@0.11.1(typescript@5.8.3)(zod@3.25.20): dependencies: - get-intrinsic: 1.3.0 - object-keys: 1.1.1 - safe-push-apply: 1.0.0 + '@adraffy/ens-normalize': 1.11.1 + '@noble/ciphers': 1.3.0 + '@noble/curves': 1.9.1 + '@noble/hashes': 1.8.0 + '@scure/bip32': 1.7.0 + '@scure/bip39': 1.6.0 + abitype: 1.2.3(typescript@5.8.3)(zod@3.25.20) + eventemitter3: 5.0.1 + optionalDependencies: + typescript: 5.8.3 + transitivePeerDependencies: + - zod + + ox@0.11.1(typescript@5.9.3)(zod@3.22.4): + dependencies: + '@adraffy/ens-normalize': 1.11.1 + '@noble/ciphers': 1.3.0 + '@noble/curves': 1.9.1 + '@noble/hashes': 1.8.0 + '@scure/bip32': 1.7.0 + '@scure/bip39': 1.6.0 + abitype: 1.2.3(typescript@5.9.3)(zod@3.22.4) + eventemitter3: 5.0.1 + optionalDependencies: + typescript: 5.9.3 + transitivePeerDependencies: + - zod - ox@0.9.17(typescript@5.9.3)(zod@4.2.0): + ox@0.11.1(typescript@5.9.3)(zod@3.25.20): dependencies: '@adraffy/ens-normalize': 1.11.1 '@noble/ciphers': 1.3.0 @@ -17254,21 +21670,129 @@ snapshots: '@noble/hashes': 1.8.0 '@scure/bip32': 1.7.0 '@scure/bip39': 1.6.0 - abitype: 1.2.2(typescript@5.9.3)(zod@4.2.0) + abitype: 1.2.3(typescript@5.9.3)(zod@3.25.20) + eventemitter3: 5.0.1 + optionalDependencies: + typescript: 5.9.3 + transitivePeerDependencies: + - zod + + ox@0.6.7(typescript@5.9.3)(zod@3.25.20): + dependencies: + '@adraffy/ens-normalize': 1.11.1 + '@noble/curves': 1.8.1 + '@noble/hashes': 1.7.1 + '@scure/bip32': 1.6.2 + '@scure/bip39': 1.5.4 + abitype: 1.0.8(typescript@5.9.3)(zod@3.25.20) eventemitter3: 5.0.1 optionalDependencies: typescript: 5.9.3 transitivePeerDependencies: - zod - p-cancelable@2.1.1: {} + ox@0.7.2(typescript@5.8.3)(zod@3.25.20): + dependencies: + '@adraffy/ens-normalize': 1.11.1 + '@noble/ciphers': 1.3.0 + '@noble/curves': 1.9.7 + '@noble/hashes': 1.8.0 + '@scure/bip32': 1.7.0 + '@scure/bip39': 1.6.0 + abitype: 1.2.3(typescript@5.8.3)(zod@3.25.20) + eventemitter3: 5.0.1 + optionalDependencies: + typescript: 5.8.3 + transitivePeerDependencies: + - zod + + ox@0.8.1(typescript@5.8.3)(zod@3.25.20): + dependencies: + '@adraffy/ens-normalize': 1.11.1 + '@noble/ciphers': 1.3.0 + '@noble/curves': 1.9.2 + '@noble/hashes': 1.8.0 + '@scure/bip32': 1.7.0 + '@scure/bip39': 1.6.0 + abitype: 1.0.8(typescript@5.8.3)(zod@3.25.20) + eventemitter3: 5.0.1 + optionalDependencies: + typescript: 5.8.3 + transitivePeerDependencies: + - zod - p-cancelable@3.0.0: {} + oxc-minify@0.86.0: + optionalDependencies: + '@oxc-minify/binding-android-arm64': 0.86.0 + '@oxc-minify/binding-darwin-arm64': 0.86.0 + '@oxc-minify/binding-darwin-x64': 0.86.0 + '@oxc-minify/binding-freebsd-x64': 0.86.0 + '@oxc-minify/binding-linux-arm-gnueabihf': 0.86.0 + '@oxc-minify/binding-linux-arm-musleabihf': 0.86.0 + '@oxc-minify/binding-linux-arm64-gnu': 0.86.0 + '@oxc-minify/binding-linux-arm64-musl': 0.86.0 + '@oxc-minify/binding-linux-riscv64-gnu': 0.86.0 + '@oxc-minify/binding-linux-s390x-gnu': 0.86.0 + '@oxc-minify/binding-linux-x64-gnu': 0.86.0 + '@oxc-minify/binding-linux-x64-musl': 0.86.0 + '@oxc-minify/binding-wasm32-wasi': 0.86.0 + '@oxc-minify/binding-win32-arm64-msvc': 0.86.0 + '@oxc-minify/binding-win32-x64-msvc': 0.86.0 + + oxc-parser@0.86.0: + dependencies: + '@oxc-project/types': 0.86.0 + optionalDependencies: + '@oxc-parser/binding-android-arm64': 0.86.0 + '@oxc-parser/binding-darwin-arm64': 0.86.0 + '@oxc-parser/binding-darwin-x64': 0.86.0 + '@oxc-parser/binding-freebsd-x64': 0.86.0 + '@oxc-parser/binding-linux-arm-gnueabihf': 0.86.0 + '@oxc-parser/binding-linux-arm-musleabihf': 0.86.0 + '@oxc-parser/binding-linux-arm64-gnu': 0.86.0 + '@oxc-parser/binding-linux-arm64-musl': 0.86.0 + '@oxc-parser/binding-linux-riscv64-gnu': 0.86.0 + '@oxc-parser/binding-linux-s390x-gnu': 0.86.0 + '@oxc-parser/binding-linux-x64-gnu': 0.86.0 + '@oxc-parser/binding-linux-x64-musl': 0.86.0 + '@oxc-parser/binding-wasm32-wasi': 0.86.0 + '@oxc-parser/binding-win32-arm64-msvc': 0.86.0 + '@oxc-parser/binding-win32-x64-msvc': 0.86.0 + + oxc-transform@0.86.0: + optionalDependencies: + '@oxc-transform/binding-android-arm64': 0.86.0 + '@oxc-transform/binding-darwin-arm64': 0.86.0 + '@oxc-transform/binding-darwin-x64': 0.86.0 + '@oxc-transform/binding-freebsd-x64': 0.86.0 + '@oxc-transform/binding-linux-arm-gnueabihf': 0.86.0 + '@oxc-transform/binding-linux-arm-musleabihf': 0.86.0 + '@oxc-transform/binding-linux-arm64-gnu': 0.86.0 + '@oxc-transform/binding-linux-arm64-musl': 0.86.0 + '@oxc-transform/binding-linux-riscv64-gnu': 0.86.0 + '@oxc-transform/binding-linux-s390x-gnu': 0.86.0 + '@oxc-transform/binding-linux-x64-gnu': 0.86.0 + '@oxc-transform/binding-linux-x64-musl': 0.86.0 + '@oxc-transform/binding-wasm32-wasi': 0.86.0 + '@oxc-transform/binding-win32-arm64-msvc': 0.86.0 + '@oxc-transform/binding-win32-x64-msvc': 0.86.0 + + oxc-walker@0.4.0(oxc-parser@0.86.0): + dependencies: + estree-walker: 3.0.3 + magic-regexp: 0.10.0 + oxc-parser: 0.86.0 p-filter@2.1.0: dependencies: p-map: 2.1.0 + p-finally@2.0.1: {} + + p-limit@1.3.0: + dependencies: + p-try: 1.0.0 + p-limit@2.3.0: dependencies: p-try: 2.2.0 @@ -17277,6 +21801,10 @@ snapshots: dependencies: yocto-queue: 0.1.0 + p-locate@2.0.0: + dependencies: + p-limit: 1.3.0 + p-locate@4.1.0: dependencies: p-limit: 2.3.0 @@ -17287,179 +21815,360 @@ snapshots: p-map@2.1.0: {} - p-map@3.0.0: - dependencies: - aggregate-error: 3.1.0 - p-map@4.0.0: dependencies: aggregate-error: 3.1.0 + p-try@1.0.0: {} + p-try@2.2.0: {} - pac-proxy-agent@7.2.0: + package-json-from-dist@1.0.1: {} + + package-manager-detector@0.2.0: {} + + package-manager-detector@0.2.11: dependencies: - '@tootallnate/quickjs-emscripten': 0.23.0 - agent-base: 7.1.4 - debug: 4.4.3(supports-color@5.5.0) - get-uri: 6.0.5 - http-proxy-agent: 7.0.2 - https-proxy-agent: 7.0.6 - pac-resolver: 7.0.1 - socks-proxy-agent: 8.0.5 - transitivePeerDependencies: - - supports-color + quansync: 0.2.11 + + package-manager-detector@1.3.0: {} + + package-manager-detector@1.6.0: {} + + parse-ms@2.1.0: {} - pac-resolver@7.0.1: + parse-ms@4.0.0: {} + + parse-path@7.1.0: dependencies: - degenerator: 5.0.1 - netmask: 2.1.1 + protocols: 2.0.2 - package-hash@4.0.0: + parse-url@9.2.0: dependencies: - graceful-fs: 4.2.11 - hasha: 5.2.2 - lodash.flattendeep: 4.4.0 - release-zalgo: 1.0.0 + '@types/parse-path': 7.1.0 + parse-path: 7.1.0 - package-json-from-dist@1.0.1: {} + parse5-htmlparser2-tree-adapter@6.0.1: + dependencies: + parse5: 6.0.1 - package-manager-detector@0.2.11: + parse5@5.1.1: {} + + parse5@6.0.1: {} + + parseurl@1.3.3: {} + + path-browserify@1.0.1: {} + + path-exists@3.0.0: {} + + path-exists@4.0.0: {} + + path-is-absolute@1.0.1: {} + + path-key@3.1.1: {} + + path-key@4.0.0: {} + + path-match@1.2.4: dependencies: - quansync: 0.2.11 + http-errors: 1.4.0 + path-to-regexp: 1.9.0 - param-case@2.1.1: + path-parse@1.0.7: {} + + path-scurry@1.11.1: + dependencies: + lru-cache: 10.4.3 + minipass: 7.1.2 + + path-scurry@2.0.1: dependencies: - no-case: 2.3.2 + lru-cache: 11.2.4 + minipass: 7.1.2 - parent-module@1.0.1: + path-to-regexp@1.9.0: dependencies: - callsites: 3.1.0 + isarray: 0.0.1 + + path-to-regexp@6.1.0: {} - parse-cache-control@1.0.1: {} + path-to-regexp@6.3.0: {} - parse-headers@2.0.6: {} + path-to-regexp@8.3.0: {} - parse-json@2.2.0: + path-type@3.0.0: dependencies: - error-ex: 1.3.4 + pify: 3.0.0 + + path-type@4.0.0: {} + + path-type@6.0.0: {} + + pathe@1.1.2: {} + + pathe@2.0.3: {} + + pathval@2.0.0: {} - parse-json@5.2.0: + pbkdf2@3.1.2: dependencies: - '@babel/code-frame': 7.29.0 - error-ex: 1.3.4 - json-parse-even-better-errors: 2.3.1 - lines-and-columns: 1.2.4 + create-hash: 1.2.0 + create-hmac: 1.1.7 + ripemd160: 2.0.2 + safe-buffer: 5.2.1 + sha.js: 2.4.11 - parse-multipart-data@1.5.0: {} + pend@1.2.0: {} - parseurl@1.3.3: {} + perfect-debounce@1.0.0: {} + + perfect-debounce@2.0.0: {} + + picocolors@1.0.0: {} + + picocolors@1.1.0: {} + + picocolors@1.1.1: {} + + picomatch@2.3.1: {} + + picomatch@4.0.2: {} + + picomatch@4.0.3: {} + + pify@3.0.0: {} + + pify@4.0.1: {} + + pify@5.0.0: {} - pascal-case@2.0.1: + pino-abstract-transport@0.5.0: dependencies: - camel-case: 3.0.0 - upper-case-first: 1.1.2 + duplexify: 4.1.2 + split2: 4.2.0 - path-browserify@1.0.1: {} + pino-abstract-transport@2.0.0: + dependencies: + split2: 4.2.0 - path-case@2.1.1: + pino-pretty@13.0.0: dependencies: - no-case: 2.3.2 + colorette: 2.0.20 + dateformat: 4.6.3 + fast-copy: 3.0.2 + fast-safe-stringify: 2.1.1 + help-me: 5.0.0 + joycon: 3.1.1 + minimist: 1.2.8 + on-exit-leak-free: 2.1.2 + pino-abstract-transport: 2.0.0 + pump: 3.0.2 + secure-json-parse: 2.7.0 + sonic-boom: 4.2.0 + strip-json-comments: 3.1.1 - path-exists@2.1.0: + pino-std-serializers@4.0.0: {} + + pino@7.11.0: dependencies: - pinkie-promise: 2.0.1 + atomic-sleep: 1.0.0 + fast-redact: 3.1.2 + on-exit-leak-free: 0.2.0 + pino-abstract-transport: 0.5.0 + pino-std-serializers: 4.0.0 + process-warning: 1.0.0 + quick-format-unescaped: 4.0.4 + real-require: 0.1.0 + safe-stable-stringify: 2.4.3 + sonic-boom: 2.8.0 + thread-stream: 0.15.2 - path-exists@4.0.0: {} + pkg-types@1.1.0: + dependencies: + confbox: 0.1.7 + mlly: 1.8.0 + pathe: 1.1.2 - path-expression-matcher@1.5.0: {} + pkg-types@1.1.1: + dependencies: + confbox: 0.1.7 + mlly: 1.7.0 + pathe: 1.1.2 - path-is-absolute@1.0.1: {} + pkg-types@1.3.1: + dependencies: + confbox: 0.1.8 + mlly: 1.8.0 + pathe: 2.0.3 - path-key@3.1.1: {} + pkg-types@2.3.0: + dependencies: + confbox: 0.2.2 + exsolve: 1.0.8 + pathe: 2.0.3 + + pngjs@5.0.0: {} + + pony-cause@2.1.11: {} + + possible-typed-array-names@1.1.0: {} + + postcss-calc@10.1.1(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + postcss-selector-parser: 7.1.1 + postcss-value-parser: 4.2.0 + + postcss-colormin@7.0.5(postcss@8.5.6): + dependencies: + browserslist: 4.28.1 + caniuse-api: 3.0.0 + colord: 2.9.3 + postcss: 8.5.6 + postcss-value-parser: 4.2.0 + + postcss-convert-values@7.0.8(postcss@8.5.6): + dependencies: + browserslist: 4.28.1 + postcss: 8.5.6 + postcss-value-parser: 4.2.0 + + postcss-discard-comments@7.0.5(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + postcss-selector-parser: 7.1.1 - path-parse@1.0.7: {} + postcss-discard-duplicates@7.0.2(postcss@8.5.6): + dependencies: + postcss: 8.5.6 - path-scurry@1.11.1: + postcss-discard-empty@7.0.1(postcss@8.5.6): dependencies: - lru-cache: 10.4.3 - minipass: 7.1.3 + postcss: 8.5.6 - path-scurry@2.0.2: + postcss-discard-overridden@7.0.1(postcss@8.5.6): dependencies: - lru-cache: 11.3.5 - minipass: 7.1.3 + postcss: 8.5.6 - path-to-regexp@0.1.13: {} + postcss-merge-longhand@7.0.5(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + postcss-value-parser: 4.2.0 + stylehacks: 7.0.7(postcss@8.5.6) - path-type@1.1.0: + postcss-merge-rules@7.0.7(postcss@8.5.6): dependencies: - graceful-fs: 4.2.11 - pify: 2.3.0 - pinkie-promise: 2.0.1 + browserslist: 4.28.1 + caniuse-api: 3.0.0 + cssnano-utils: 5.0.1(postcss@8.5.6) + postcss: 8.5.6 + postcss-selector-parser: 7.1.1 - path-type@4.0.0: {} + postcss-minify-font-values@7.0.1(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - pathe@2.0.3: {} + postcss-minify-gradients@7.0.1(postcss@8.5.6): + dependencies: + colord: 2.9.3 + cssnano-utils: 5.0.1(postcss@8.5.6) + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - pathval@1.1.1: {} + postcss-minify-params@7.0.5(postcss@8.5.6): + dependencies: + browserslist: 4.28.1 + cssnano-utils: 5.0.1(postcss@8.5.6) + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - pbkdf2@3.1.5: + postcss-minify-selectors@7.0.5(postcss@8.5.6): dependencies: - create-hash: 1.2.0 - create-hmac: 1.1.7 - ripemd160: 2.0.3 - safe-buffer: 5.2.1 - sha.js: 2.4.12 - to-buffer: 1.2.2 + cssesc: 3.0.0 + postcss: 8.5.6 + postcss-selector-parser: 7.1.1 - performance-now@2.1.0: {} + postcss-normalize-charset@7.0.1(postcss@8.5.6): + dependencies: + postcss: 8.5.6 - picocolors@1.1.1: {} + postcss-normalize-display-values@7.0.1(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - picomatch@2.3.2: {} + postcss-normalize-positions@7.0.1(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - picomatch@4.0.3: {} + postcss-normalize-repeat-style@7.0.1(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - picomatch@4.0.4: {} + postcss-normalize-string@7.0.1(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - pify@2.3.0: {} + postcss-normalize-timing-functions@7.0.1(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - pify@3.0.0: {} + postcss-normalize-unicode@7.0.5(postcss@8.5.6): + dependencies: + browserslist: 4.28.1 + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - pify@4.0.1: {} + postcss-normalize-url@7.0.1(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - pify@5.0.0: {} + postcss-normalize-whitespace@7.0.1(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - pinkie-promise@2.0.1: + postcss-ordered-values@7.0.2(postcss@8.5.6): dependencies: - pinkie: 2.0.4 + cssnano-utils: 5.0.1(postcss@8.5.6) + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - pinkie@2.0.4: {} + postcss-reduce-initial@7.0.5(postcss@8.5.6): + dependencies: + browserslist: 4.28.1 + caniuse-api: 3.0.0 + postcss: 8.5.6 - pkg-dir@4.2.0: + postcss-reduce-transforms@7.0.1(postcss@8.5.6): dependencies: - find-up: 4.1.0 + postcss: 8.5.6 + postcss-value-parser: 4.2.0 - pkijs@3.3.3: + postcss-selector-parser@7.1.1: dependencies: - '@noble/hashes': 1.4.0 - asn1js: 3.0.7 - bytestreamjs: 2.0.1 - pvtsutils: 1.3.6 - pvutils: 1.1.5 - tslib: 2.8.1 + cssesc: 3.0.0 + util-deprecate: 1.0.2 - pluralize@8.0.0: {} + postcss-svgo@7.1.0(postcss@8.5.6): + dependencies: + postcss: 8.5.6 + postcss-value-parser: 4.2.0 + svgo: 4.0.0 - portfinder@1.0.38: + postcss-unique-selectors@7.0.4(postcss@8.5.6): dependencies: - async: 3.2.6 - debug: 4.4.3(supports-color@5.5.0) - transitivePeerDependencies: - - supports-color + postcss: 8.5.6 + postcss-selector-parser: 7.1.1 - possible-typed-array-names@1.1.0: {} + postcss-value-parser@4.2.0: {} postcss@8.4.31: dependencies: @@ -17467,129 +22176,129 @@ snapshots: picocolors: 1.1.1 source-map-js: 1.2.1 - postcss@8.5.10: + postcss@8.4.47: dependencies: - nanoid: 3.3.11 + nanoid: 3.3.7 picocolors: 1.1.1 source-map-js: 1.2.1 - precond@0.2.3: {} + postcss@8.5.6: + dependencies: + nanoid: 3.3.11 + picocolors: 1.1.1 + source-map-js: 1.2.1 - prelude-ls@1.1.2: {} + preact@10.17.1: {} - prelude-ls@1.2.1: {} + preact@10.24.3: {} - prettier-linter-helpers@1.0.1: + prettier-plugin-solidity@2.2.1(prettier@3.7.4): dependencies: - fast-diff: 1.3.0 + '@nomicfoundation/slang': 1.3.1 + '@solidity-parser/parser': 0.20.2 + prettier: 3.7.4 + semver: 7.7.3 prettier@2.8.8: {} - prettier@3.8.1: {} + prettier@3.0.3: {} - proc-log@4.2.0: {} + prettier@3.7.4: {} - process-nextick-args@2.0.1: {} + pretty-bytes@7.1.0: {} - process-on-spawn@1.1.0: + pretty-format@27.5.1: dependencies: - fromentries: 1.3.2 - - process@0.11.10: {} + ansi-regex: 5.0.1 + ansi-styles: 5.2.0 + react-is: 17.0.2 - promise-retry@2.0.1: + pretty-ms@7.0.1: dependencies: - err-code: 2.0.3 - retry: 0.12.0 + parse-ms: 2.1.0 - promise-to-callback@1.0.0: + pretty-ms@9.0.0: dependencies: - is-fn: 1.0.0 - set-immediate-shim: 1.0.1 + parse-ms: 4.0.0 - promise@8.3.0: - dependencies: - asap: 2.0.6 + process-nextick-args@2.0.1: {} + + process-warning@1.0.0: {} + + process@0.11.10: {} + + promisepipe@3.0.0: {} prompts@2.4.2: dependencies: kleur: 3.0.3 sisteransi: 1.0.5 - prop-types@15.8.1: + prool@0.0.23: dependencies: - loose-envify: 1.4.0 - object-assign: 4.1.1 - react-is: 16.13.1 + change-case: 5.4.4 + eventemitter3: 5.0.1 + execa: 9.1.0 + get-port: 7.1.0 + http-proxy: 1.18.1 + tar: 7.2.0 + transitivePeerDependencies: + - debug - proper-lockfile@4.1.2: - dependencies: - graceful-fs: 4.2.11 - retry: 0.12.0 - signal-exit: 3.0.7 + property-information@6.5.0: {} - proxy-addr@2.0.7: - dependencies: - forwarded: 0.2.0 - ipaddr.js: 1.9.1 + proto-list@1.2.4: {} - proxy-agent@6.5.0: - dependencies: - agent-base: 7.1.4 - debug: 4.4.3(supports-color@5.5.0) - http-proxy-agent: 7.0.2 - https-proxy-agent: 7.0.6 - lru-cache: 7.18.3 - pac-proxy-agent: 7.2.0 - proxy-from-env: 1.1.0 - socks-proxy-agent: 8.0.5 - transitivePeerDependencies: - - supports-color + protocols@2.0.2: {} - proxy-from-env@1.1.0: {} + proxy-compare@2.6.0: {} - proxy-from-env@2.1.0: {} + pseudomap@1.0.2: {} - prr@1.0.1: {} + psl@1.9.0: {} - pstree.remy@1.1.8: {} + publint@0.3.12: + dependencies: + '@publint/pack': 0.1.2 + package-manager-detector: 1.3.0 + picocolors: 1.1.1 + sade: 1.8.1 - pump@3.0.4: + pump@3.0.2: dependencies: - end-of-stream: 1.4.5 + end-of-stream: 1.4.4 once: 1.4.0 - punycode@1.4.1: {} - - punycode@2.1.0: {} - - punycode@2.3.1: {} - - pvtsutils@1.3.6: + pump@3.0.3: dependencies: - tslib: 2.8.1 - - pvutils@1.1.5: {} + end-of-stream: 1.4.5 + once: 1.4.0 - qs@6.14.2: - dependencies: - side-channel: 1.1.0 + punycode@2.3.1: {} - qs@6.15.1: + qrcode@1.5.3: dependencies: - side-channel: 1.1.0 + dijkstrajs: 1.0.2 + encode-utf8: 1.0.3 + pngjs: 5.0.0 + yargs: 15.4.1 quansync@0.2.11: {} - query-string@5.1.1: + query-string@7.1.3: dependencies: decode-uri-component: 0.2.2 - object-assign: 4.1.1 - strict-uri-encode: 1.1.0 + filter-obj: 1.1.0 + split-on-first: 1.1.0 + strict-uri-encode: 2.0.0 + + querystringify@2.2.0: {} queue-microtask@1.2.3: {} - quick-lru@5.1.1: {} + quick-format-unescaped@4.0.4: {} + + radix3@1.1.2: {} randombytes@2.1.0: dependencies: @@ -17597,67 +22306,82 @@ snapshots: range-parser@1.2.1: {} - raw-body@2.5.3: + raw-body@2.4.1: + dependencies: + bytes: 3.1.0 + http-errors: 1.7.3 + iconv-lite: 0.4.24 + unpipe: 1.0.0 + + raw-body@2.5.1: dependencies: bytes: 3.1.2 - http-errors: 2.0.1 + http-errors: 2.0.0 iconv-lite: 0.4.24 unpipe: 1.0.0 - rc@1.2.8: + rc9@2.1.2: dependencies: - deep-extend: 0.6.0 - ini: 1.3.8 - minimist: 1.2.8 - strip-json-comments: 2.0.1 + defu: 6.1.4 + destr: 2.0.5 + + react-apple-signin-auth@1.1.2(react-dom@18.3.1(react@18.3.1))(react@18.3.1): + dependencies: + react: 18.3.1 + react-dom: 18.3.1(react@18.3.1) + + react-dom@18.3.1(react@18.3.1): + dependencies: + loose-envify: 1.4.0 + react: 18.3.1 + scheduler: 0.23.2 - react-dom@19.2.3(react@19.2.3): + react-hook-form@7.69.0(react@18.3.1): dependencies: - react: 19.2.3 - scheduler: 0.27.0 + react: 18.3.1 - react-is@16.13.1: {} + react-is@17.0.2: {} - react-native-keychain@8.2.0: {} + react-refresh@0.14.0: {} - react@19.2.3: {} + react-remove-scroll-bar@2.3.8(@types/react@18.3.27)(react@18.3.1): + dependencies: + react: 18.3.1 + react-style-singleton: 2.2.3(@types/react@18.3.27)(react@18.3.1) + tslib: 2.8.1 + optionalDependencies: + '@types/react': 18.3.27 - read-pkg-up@1.0.1: + react-remove-scroll@2.7.2(@types/react@18.3.27)(react@18.3.1): dependencies: - find-up: 1.1.2 - read-pkg: 1.1.0 + react: 18.3.1 + react-remove-scroll-bar: 2.3.8(@types/react@18.3.27)(react@18.3.1) + react-style-singleton: 2.2.3(@types/react@18.3.27)(react@18.3.1) + tslib: 2.8.1 + use-callback-ref: 1.3.3(@types/react@18.3.27)(react@18.3.1) + use-sidecar: 1.1.3(@types/react@18.3.27)(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 - read-pkg@1.1.0: + react-style-singleton@2.2.3(@types/react@18.3.27)(react@18.3.1): dependencies: - load-json-file: 1.1.0 - normalize-package-data: 2.5.0 - path-type: 1.1.0 + get-nonce: 1.0.1 + react: 18.3.1 + tslib: 2.8.1 + optionalDependencies: + '@types/react': 18.3.27 - read-tls-client-hello@1.1.0: + react@18.3.1: dependencies: - '@types/node': 25.6.0 + loose-envify: 1.4.0 read-yaml-file@1.1.0: dependencies: graceful-fs: 4.2.11 - js-yaml: 3.14.2 + js-yaml: 3.14.1 pify: 4.0.1 strip-bom: 3.0.0 - readable-stream@1.0.34: - dependencies: - core-util-is: 1.0.3 - inherits: 2.0.4 - isarray: 0.0.1 - string_decoder: 0.10.31 - - readable-stream@1.1.14: - dependencies: - core-util-is: 1.0.3 - inherits: 2.0.4 - isarray: 0.0.1 - string_decoder: 0.10.31 - readable-stream@2.3.8: dependencies: core-util-is: 1.0.3 @@ -17674,317 +22398,215 @@ snapshots: string_decoder: 1.3.0 util-deprecate: 1.0.2 - readdirp@3.6.0: - dependencies: - picomatch: 2.3.2 - - readdirp@4.1.2: {} - - realistic-structured-clone@3.0.0: + readable-stream@4.7.0: dependencies: - domexception: 1.0.1 - typeson: 6.1.0 - typeson-registry: 1.0.0-alpha.39 + abort-controller: 3.0.0 + buffer: 6.0.3 + events: 3.3.0 + process: 0.11.10 + string_decoder: 1.3.0 - rechoir@0.6.2: + readdir-glob@1.1.3: dependencies: - resolve: 1.22.12 + minimatch: 5.1.6 - recursive-readdir@2.2.3: + readdirp@3.6.0: dependencies: - minimatch: 10.2.5 + picomatch: 2.3.1 - reduce-flatten@2.0.0: {} + readdirp@4.1.2: {} - reflect.getprototypeof@1.0.10: - dependencies: - call-bind: 1.0.9 - define-properties: 1.2.1 - es-abstract: 1.24.2 - es-errors: 1.3.0 - es-object-atoms: 1.1.1 - get-intrinsic: 1.3.0 - get-proto: 1.0.1 - which-builtin-type: 1.2.1 + readdirp@5.0.0: {} - regexp.prototype.flags@1.5.4: - dependencies: - call-bind: 1.0.8 - define-properties: 1.2.1 - es-errors: 1.3.0 - get-proto: 1.0.1 - gopd: 1.2.0 - set-function-name: 2.0.2 + real-require@0.1.0: {} - registry-auth-token@3.3.2: - dependencies: - rc: 1.2.8 - safe-buffer: 5.2.1 + redis-errors@1.2.0: {} - registry-url@3.1.0: + redis-parser@3.0.0: dependencies: - rc: 1.2.8 + redis-errors: 1.2.0 - release-zalgo@1.0.0: - dependencies: - es6-error: 4.1.1 + regenerator-runtime@0.14.0: {} - req-cwd@2.0.0: - dependencies: - req-from: 2.0.0 + regex@4.4.0: {} - req-from@2.0.0: - dependencies: - resolve-from: 3.0.0 + regexp-tree@0.1.27: {} - request@2.88.2: - dependencies: - aws-sign2: 0.7.0 - aws4: 1.13.2 - caseless: 0.12.0 - combined-stream: 1.0.8 - extend: 3.0.2 - forever-agent: 0.6.1 - form-data: 4.0.5 - har-validator: 5.1.5 - http-signature: 1.2.0 - is-typedarray: 1.0.0 - isstream: 0.1.2 - json-stringify-safe: 5.0.1 - mime-types: 2.1.35 - oauth-sign: 0.9.0 - performance-now: 2.1.0 - qs: 6.15.1 - safe-buffer: 5.2.1 - tough-cookie: 6.0.1 - tunnel-agent: 0.6.0 - uuid: 3.4.0 + remove-accents@0.5.0: {} require-directory@2.1.1: {} - require-from-string@1.2.1: {} - require-from-string@2.0.2: {} - require-main-filename@1.0.1: {} - require-main-filename@2.0.0: {} - resolve-alpn@1.2.1: {} - - resolve-from@3.0.0: {} - - resolve-from@4.0.0: {} + requires-port@1.0.0: {} resolve-from@5.0.0: {} - resolve@1.1.7: {} + resolve-pkg-maps@1.0.0: {} resolve@1.17.0: dependencies: path-parse: 1.0.7 - resolve@1.22.12: - dependencies: - es-errors: 1.3.0 - is-core-module: 2.16.1 - path-parse: 1.0.7 - supports-preserve-symlinks-flag: 1.0.0 - - resolve@2.0.0-next.5: - dependencies: - is-core-module: 2.16.1 - path-parse: 1.0.7 - supports-preserve-symlinks-flag: 1.0.0 - - resolve@2.0.0-next.6: + resolve@1.22.11: dependencies: - es-errors: 1.3.0 is-core-module: 2.16.1 - node-exports-info: 1.6.0 - object-keys: 1.1.1 path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 - responselike@2.0.1: - dependencies: - lowercase-keys: 2.0.0 - - restore-cursor@3.1.0: - dependencies: - onetime: 5.1.2 - signal-exit: 3.0.7 - - retry@0.12.0: {} - retry@0.13.1: {} - reusify@1.1.0: {} + reusify@1.0.4: {} rfdc@1.4.1: {} rimraf@2.7.1: dependencies: - glob: 7.2.3 + glob: 7.2.0 - rimraf@3.0.2: + rimraf@5.0.10: dependencies: - glob: 7.2.3 + glob: 10.5.0 - rimraf@6.1.3: + rimraf@6.1.2: dependencies: - glob: 13.0.6 + glob: 13.0.0 package-json-from-dist: 1.0.1 - ripemd160@2.0.3: + ripemd160@2.0.2: dependencies: - hash-base: 3.1.2 + hash-base: 3.1.0 inherits: 2.0.4 - rlp@2.2.6: + rlp@2.2.7: dependencies: - bn.js: 5.2.3 + bn.js: 5.2.2 - rlp@2.2.7: + rolldown@1.0.0-beta.35: + dependencies: + '@oxc-project/runtime': 0.82.3 + '@oxc-project/types': 0.82.3 + '@rolldown/pluginutils': 1.0.0-beta.35 + ansis: 4.2.0 + optionalDependencies: + '@rolldown/binding-android-arm64': 1.0.0-beta.35 + '@rolldown/binding-darwin-arm64': 1.0.0-beta.35 + '@rolldown/binding-darwin-x64': 1.0.0-beta.35 + '@rolldown/binding-freebsd-x64': 1.0.0-beta.35 + '@rolldown/binding-linux-arm-gnueabihf': 1.0.0-beta.35 + '@rolldown/binding-linux-arm64-gnu': 1.0.0-beta.35 + '@rolldown/binding-linux-arm64-musl': 1.0.0-beta.35 + '@rolldown/binding-linux-x64-gnu': 1.0.0-beta.35 + '@rolldown/binding-linux-x64-musl': 1.0.0-beta.35 + '@rolldown/binding-openharmony-arm64': 1.0.0-beta.35 + '@rolldown/binding-wasm32-wasi': 1.0.0-beta.35 + '@rolldown/binding-win32-arm64-msvc': 1.0.0-beta.35 + '@rolldown/binding-win32-ia32-msvc': 1.0.0-beta.35 + '@rolldown/binding-win32-x64-msvc': 1.0.0-beta.35 + + rollup-plugin-visualizer@6.0.5(rolldown@1.0.0-beta.35)(rollup@4.54.0): dependencies: - bn.js: 5.2.3 + open: 8.4.2 + picomatch: 4.0.3 + source-map: 0.7.6 + yargs: 17.7.2 + optionalDependencies: + rolldown: 1.0.0-beta.35 + rollup: 4.54.0 - rollup@4.60.2: + rollup@4.54.0: dependencies: '@types/estree': 1.0.8 optionalDependencies: - '@rollup/rollup-android-arm-eabi': 4.60.2 - '@rollup/rollup-android-arm64': 4.60.2 - '@rollup/rollup-darwin-arm64': 4.60.2 - '@rollup/rollup-darwin-x64': 4.60.2 - '@rollup/rollup-freebsd-arm64': 4.60.2 - '@rollup/rollup-freebsd-x64': 4.60.2 - '@rollup/rollup-linux-arm-gnueabihf': 4.60.2 - '@rollup/rollup-linux-arm-musleabihf': 4.60.2 - '@rollup/rollup-linux-arm64-gnu': 4.60.2 - '@rollup/rollup-linux-arm64-musl': 4.60.2 - '@rollup/rollup-linux-loong64-gnu': 4.60.2 - '@rollup/rollup-linux-loong64-musl': 4.60.2 - '@rollup/rollup-linux-ppc64-gnu': 4.60.2 - '@rollup/rollup-linux-ppc64-musl': 4.60.2 - '@rollup/rollup-linux-riscv64-gnu': 4.60.2 - '@rollup/rollup-linux-riscv64-musl': 4.60.2 - '@rollup/rollup-linux-s390x-gnu': 4.60.2 - '@rollup/rollup-linux-x64-gnu': 4.60.2 - '@rollup/rollup-linux-x64-musl': 4.60.2 - '@rollup/rollup-openbsd-x64': 4.60.2 - '@rollup/rollup-openharmony-arm64': 4.60.2 - '@rollup/rollup-win32-arm64-msvc': 4.60.2 - '@rollup/rollup-win32-ia32-msvc': 4.60.2 - '@rollup/rollup-win32-x64-gnu': 4.60.2 - '@rollup/rollup-win32-x64-msvc': 4.60.2 + '@rollup/rollup-android-arm-eabi': 4.54.0 + '@rollup/rollup-android-arm64': 4.54.0 + '@rollup/rollup-darwin-arm64': 4.54.0 + '@rollup/rollup-darwin-x64': 4.54.0 + '@rollup/rollup-freebsd-arm64': 4.54.0 + '@rollup/rollup-freebsd-x64': 4.54.0 + '@rollup/rollup-linux-arm-gnueabihf': 4.54.0 + '@rollup/rollup-linux-arm-musleabihf': 4.54.0 + '@rollup/rollup-linux-arm64-gnu': 4.54.0 + '@rollup/rollup-linux-arm64-musl': 4.54.0 + '@rollup/rollup-linux-loong64-gnu': 4.54.0 + '@rollup/rollup-linux-ppc64-gnu': 4.54.0 + '@rollup/rollup-linux-riscv64-gnu': 4.54.0 + '@rollup/rollup-linux-riscv64-musl': 4.54.0 + '@rollup/rollup-linux-s390x-gnu': 4.54.0 + '@rollup/rollup-linux-x64-gnu': 4.54.0 + '@rollup/rollup-linux-x64-musl': 4.54.0 + '@rollup/rollup-openharmony-arm64': 4.54.0 + '@rollup/rollup-win32-arm64-msvc': 4.54.0 + '@rollup/rollup-win32-ia32-msvc': 4.54.0 + '@rollup/rollup-win32-x64-gnu': 4.54.0 + '@rollup/rollup-win32-x64-msvc': 4.54.0 fsevents: 2.3.3 - run-async@2.4.1: {} + run-applescript@7.1.0: {} run-parallel@1.2.0: dependencies: queue-microtask: 1.2.3 - rustbn.js@0.2.0: {} - - rxjs@6.6.7: - dependencies: - tslib: 1.14.1 - - rxjs@7.8.2: - dependencies: - tslib: 2.8.1 - - safe-array-concat@1.1.3: - dependencies: - call-bind: 1.0.8 - call-bound: 1.0.4 - get-intrinsic: 1.3.0 - has-symbols: 1.1.0 - isarray: 2.0.5 - - safe-array-concat@1.1.4: + sade@1.8.1: dependencies: - call-bind: 1.0.9 - call-bound: 1.0.4 - get-intrinsic: 1.3.0 - has-symbols: 1.1.0 - isarray: 2.0.5 + mri: 1.2.0 safe-buffer@5.1.2: {} safe-buffer@5.2.1: {} - safe-event-emitter@1.0.1: - dependencies: - events: 3.3.0 - - safe-push-apply@1.0.0: - dependencies: - es-errors: 1.3.0 - isarray: 2.0.5 - safe-regex-test@1.1.0: dependencies: call-bound: 1.0.4 es-errors: 1.3.0 is-regex: 1.2.1 + safe-stable-stringify@2.4.3: {} + safer-buffer@2.1.2: {} - sc-istanbul@0.4.6: - dependencies: - abbrev: 1.0.9 - async: 1.5.2 - escodegen: 1.8.1 - esprima: 2.7.3 - glob: 5.0.15 - handlebars: 4.7.9 - js-yaml: 3.14.2 - mkdirp: 0.5.6 - nopt: 3.0.6 - once: 1.4.0 - resolve: 1.1.7 - supports-color: 3.2.3 - which: 1.3.1 - wordwrap: 1.0.0 + sax@1.4.3: {} - scheduler@0.27.0: {} + scheduler@0.23.2: + dependencies: + loose-envify: 1.4.0 scrypt-js@3.0.1: {} - scrypt@https://codeload.github.com/barrysteyn/node-scrypt/tar.gz/fb60a8d3c158fe115a624b5ffa7480f3a24b03fb: - dependencies: - nan: 2.26.2 + scule@1.3.0: {} - secp256k1@4.0.4: + secp256k1@4.0.3: dependencies: elliptic: 6.6.1 - node-addon-api: 5.1.0 + node-addon-api: 2.0.2 node-gyp-build: 4.8.4 - seedrandom@3.0.5: {} - - semaphore-async-await@1.5.1: {} + secure-json-parse@2.7.0: {} - semaphore@1.1.0: {} + semver@5.7.1: {} semver@6.3.1: {} - semver@7.7.4: {} + semver@7.5.4: + dependencies: + lru-cache: 6.0.0 + + semver@7.6.2: {} - send@0.19.2: + semver@7.7.3: {} + + send@1.2.1: dependencies: - debug: 2.6.9 - depd: 2.0.0 - destroy: 1.2.0 + debug: 4.4.3 encodeurl: 2.0.0 escape-html: 1.0.3 etag: 1.8.1 - fresh: 0.5.2 + fresh: 2.0.0 http-errors: 2.0.1 - mime: 1.6.0 + mime-types: 3.0.2 ms: 2.1.3 on-finished: 2.4.1 range-parser: 1.2.1 @@ -17992,29 +22614,24 @@ snapshots: transitivePeerDependencies: - supports-color - sentence-case@2.1.1: + serialize-javascript@6.0.0: + dependencies: + randombytes: 2.1.0 + + serialize-javascript@6.0.2: dependencies: - no-case: 2.3.2 - upper-case-first: 1.1.2 + randombytes: 2.1.0 - serialize-javascript@7.0.5: {} + serve-placeholder@2.0.2: + dependencies: + defu: 6.1.4 - serve-static@1.16.3: + serve-static@2.2.1: dependencies: encodeurl: 2.0.0 escape-html: 1.0.3 parseurl: 1.3.3 - send: 0.19.2 - transitivePeerDependencies: - - supports-color - - servify@0.1.12: - dependencies: - body-parser: 1.20.5 - cors: 2.8.6 - express: 4.22.1 - request: 2.88.2 - xhr: 2.6.0 + send: 1.2.1 transitivePeerDependencies: - supports-color @@ -18029,41 +22646,22 @@ snapshots: gopd: 1.2.0 has-property-descriptors: 1.0.2 - set-function-name@2.0.2: - dependencies: - define-data-property: 1.1.4 - es-errors: 1.3.0 - functions-have-names: 1.2.3 - has-property-descriptors: 1.0.2 - - set-immediate-shim@1.0.1: {} - - set-proto@1.0.0: - dependencies: - dunder-proto: 1.0.1 - es-errors: 1.3.0 - es-object-atoms: 1.1.1 - setimmediate@1.0.5: {} + setprototypeof@1.1.1: {} + setprototypeof@1.2.0: {} - sha.js@2.4.12: + sha.js@2.4.11: dependencies: inherits: 2.0.4 safe-buffer: 5.2.1 - to-buffer: 1.2.2 - - sha1@1.1.1: - dependencies: - charenc: 0.0.2 - crypt: 0.0.2 sharp@0.34.5: dependencies: - '@img/colour': 1.1.0 + '@img/colour': 1.0.0 detect-libc: 2.1.2 - semver: 7.7.4 + semver: 7.7.3 optionalDependencies: '@img/sharp-darwin-arm64': 0.34.5 '@img/sharp-darwin-x64': 0.34.5 @@ -18091,183 +22689,141 @@ snapshots: '@img/sharp-win32-x64': 0.34.5 optional: true + shebang-command@1.2.0: + dependencies: + shebang-regex: 1.0.0 + shebang-command@2.0.0: dependencies: shebang-regex: 3.0.0 + shebang-regex@1.0.0: {} + shebang-regex@3.0.0: {} shell-quote@1.8.3: {} - shelljs@0.8.5: - dependencies: - glob: 7.2.3 - interpret: 1.4.0 - rechoir: 0.6.2 + sherif-darwin-arm64@1.0.0: + optional: true - side-channel-list@1.0.0: - dependencies: - es-errors: 1.3.0 - object-inspect: 1.13.4 + sherif-darwin-x64@1.0.0: + optional: true - side-channel-map@1.0.1: - dependencies: - call-bound: 1.0.4 - es-errors: 1.3.0 - get-intrinsic: 1.3.0 - object-inspect: 1.13.4 + sherif-linux-arm64@1.0.0: + optional: true + + sherif-linux-x64@1.0.0: + optional: true - side-channel-weakmap@1.0.2: - dependencies: - call-bound: 1.0.4 - es-errors: 1.3.0 - get-intrinsic: 1.3.0 - object-inspect: 1.13.4 - side-channel-map: 1.0.1 + sherif-windows-arm64@1.0.0: + optional: true - side-channel@1.1.0: - dependencies: - es-errors: 1.3.0 - object-inspect: 1.13.4 - side-channel-list: 1.0.0 - side-channel-map: 1.0.1 - side-channel-weakmap: 1.0.2 + sherif-windows-x64@1.0.0: + optional: true + + sherif@1.0.0: + optionalDependencies: + sherif-darwin-arm64: 1.0.0 + sherif-darwin-x64: 1.0.0 + sherif-linux-arm64: 1.0.0 + sherif-linux-x64: 1.0.0 + sherif-windows-arm64: 1.0.0 + sherif-windows-x64: 1.0.0 + + shiki@1.22.2: + dependencies: + '@shikijs/core': 1.22.2 + '@shikijs/engine-javascript': 1.22.2 + '@shikijs/engine-oniguruma': 1.22.2 + '@shikijs/types': 1.22.2 + '@shikijs/vscode-textmate': 9.3.0 + '@types/hast': 3.0.4 siginfo@2.0.0: {} signal-exit@3.0.7: {} + signal-exit@4.0.2: {} + signal-exit@4.1.0: {} - simple-concat@1.0.1: {} + simple-git-hooks@2.11.1: {} - simple-get@2.8.2: + simple-git@3.30.0: dependencies: - decompress-response: 3.3.0 - once: 1.4.0 - simple-concat: 1.0.1 + '@kwsites/file-exists': 1.1.1 + '@kwsites/promise-deferred': 1.1.1 + debug: 4.4.3 + transitivePeerDependencies: + - supports-color + + sirv@2.0.4: + dependencies: + '@polka/url': 1.0.0-next.29 + mrmime: 2.0.1 + totalist: 3.0.1 - simple-update-notifier@2.0.0: + sirv@3.0.2: dependencies: - semver: 7.7.4 + '@polka/url': 1.0.0-next.29 + mrmime: 2.0.1 + totalist: 3.0.1 sisteransi@1.0.5: {} + skin-tone@2.0.0: + dependencies: + unicode-emoji-modifier-base: 1.0.0 + + slash@1.0.0: {} + slash@3.0.0: {} - slice-ansi@4.0.0: - dependencies: - ansi-styles: 4.3.0 - astral-regex: 2.0.0 - is-fullwidth-code-point: 3.0.0 + slash@5.1.0: {} - smart-buffer@4.2.0: {} + smob@1.5.0: {} - snake-case@2.1.0: - dependencies: - no-case: 2.3.2 + smol-toml@1.3.0: {} - socks-proxy-agent@7.0.0: + socket.io-client@4.8.3(bufferutil@4.1.0)(utf-8-validate@5.0.10): dependencies: - agent-base: 6.0.2 - debug: 4.4.3(supports-color@5.5.0) - socks: 2.8.7 + '@socket.io/component-emitter': 3.1.2 + debug: 4.4.3 + engine.io-client: 6.6.4(bufferutil@4.1.0)(utf-8-validate@5.0.10) + socket.io-parser: 4.2.5 transitivePeerDependencies: + - bufferutil - supports-color + - utf-8-validate - socks-proxy-agent@8.0.5: + socket.io-parser@4.2.5: dependencies: - agent-base: 7.1.4 - debug: 4.4.3(supports-color@5.5.0) - socks: 2.8.7 + '@socket.io/component-emitter': 3.1.2 + debug: 4.4.3 transitivePeerDependencies: - supports-color - socks@2.8.7: - dependencies: - ip-address: 10.1.0 - smart-buffer: 4.2.0 - - solc@0.4.26: - dependencies: - fs-extra: 0.30.0 - memorystream: 0.3.1 - require-from-string: 1.2.1 - semver: 7.7.4 - yargs: 4.8.1 - - solc@0.8.15: - dependencies: - command-exists: 1.2.9 - commander: 8.3.0 - follow-redirects: 1.16.0(debug@4.4.3) - js-sha3: 0.8.0 - memorystream: 0.3.1 - semver: 7.7.4 - tmp: 0.2.5 - transitivePeerDependencies: - - debug - - solc@0.8.26(debug@4.4.3): + solc@0.7.3(debug@4.3.4): dependencies: command-exists: 1.2.9 - commander: 8.3.0 - follow-redirects: 1.16.0(debug@4.4.3) + commander: 3.0.2 + follow-redirects: 1.15.2(debug@4.3.4) + fs-extra: 0.30.0 js-sha3: 0.8.0 memorystream: 0.3.1 - semver: 6.3.1 - tmp: 0.2.5 + require-from-string: 2.0.2 + semver: 5.7.1 + tmp: 0.0.33 transitivePeerDependencies: - debug - solhint@3.6.2(typescript@4.9.5): + sonic-boom@2.8.0: dependencies: - '@solidity-parser/parser': 0.16.2 - ajv: 8.20.0 - antlr4: 4.13.2 - ast-parents: 0.0.1 - chalk: 4.1.2 - commander: 10.0.1 - cosmiconfig: 8.3.6(typescript@4.9.5) - fast-diff: 1.3.0 - glob: 8.1.0 - ignore: 5.3.2 - js-yaml: 4.1.1 - lodash: 4.18.1 - pluralize: 8.0.0 - semver: 7.7.4 - strip-ansi: 6.0.1 - table: 6.9.0 - text-table: 0.2.0 - optionalDependencies: - prettier: 2.8.8 - transitivePeerDependencies: - - typescript - - solidity-ast@0.4.62: {} + atomic-sleep: 1.0.0 - solidity-coverage@0.8.17(hardhat@2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10)): + sonic-boom@4.2.0: dependencies: - '@ethersproject/abi': 5.8.0 - '@solidity-parser/parser': 0.20.2 - chalk: 2.4.2 - death: 1.1.0 - difflib: 0.2.4 - fs-extra: 8.1.0 - ghost-testrpc: 0.0.2 - global-modules: 2.0.0 - globby: 10.0.2 - hardhat: 2.28.6(bufferutil@4.1.0)(ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5))(typescript@4.9.5)(utf-8-validate@5.0.10) - jsonschema: 1.5.0 - lodash: 4.18.1 - mocha: 10.8.2 - node-emoji: 1.11.0 - pify: 4.0.1 - recursive-readdir: 2.2.3 - sc-istanbul: 0.4.6 - semver: 7.7.4 - shelljs: 0.8.5 - web3-utils: 1.10.4 + atomic-sleep: 1.0.0 source-map-js@1.2.1: {} @@ -18276,98 +22832,82 @@ snapshots: buffer-from: 1.1.2 source-map: 0.6.1 - source-map@0.2.0: - dependencies: - amdefine: 1.0.1 - optional: true - source-map@0.6.1: {} - spawn-command@0.0.2: {} + source-map@0.7.6: {} + + space-separated-tokens@2.0.2: {} - spawn-wrap@2.0.0: + spawndamnit@2.0.0: dependencies: - foreground-child: 2.0.0 - is-windows: 1.0.2 - make-dir: 3.1.0 - rimraf: 3.0.2 + cross-spawn: 5.1.0 signal-exit: 3.0.7 - which: 2.0.2 spawndamnit@3.0.1: dependencies: cross-spawn: 7.0.6 signal-exit: 4.1.0 - spdx-correct@3.2.0: - dependencies: - spdx-expression-parse: 3.0.1 - spdx-license-ids: 3.0.23 - - spdx-exceptions@2.5.0: {} - - spdx-expression-parse@3.0.1: - dependencies: - spdx-exceptions: 2.5.0 - spdx-license-ids: 3.0.23 + speakingurl@14.0.1: {} - spdx-license-ids@3.0.23: {} + split-on-first@1.1.0: {} - split2@3.2.2: - dependencies: - readable-stream: 3.6.2 + split2@4.2.0: {} sprintf-js@1.0.3: {} - sshpk@1.18.0: + srvx@0.8.9: dependencies: - asn1: 0.2.6 - assert-plus: 1.0.0 - bcrypt-pbkdf: 1.0.2 - dashdash: 1.14.1 - ecc-jsbn: 0.1.2 - getpass: 0.1.7 - jsbn: 0.1.1 - safer-buffer: 2.1.2 - tweetnacl: 0.14.5 + cookie-es: 2.0.0 - ssri@10.0.6: - dependencies: - minipass: 7.1.3 + srvx@0.9.8: {} stackback@0.0.2: {} - stacktrace-parser@0.1.11: + stacktrace-parser@0.1.10: dependencies: type-fest: 0.7.1 + standard-as-callback@2.1.0: {} + + stat-mode@0.3.0: {} + statuses@1.5.0: {} + statuses@2.0.1: {} + statuses@2.0.2: {} std-env@3.10.0: {} - stop-iteration-iterator@1.1.0: - dependencies: - es-errors: 1.3.0 - internal-slot: 1.1.0 + std-env@3.7.0: {} - stream-shift@1.0.3: {} + std-env@3.9.0: {} - strict-uri-encode@1.1.0: {} + stream-shift@1.0.1: {} - string-format@2.0.0: {} + stream-to-array@2.3.0: + dependencies: + any-promise: 1.3.0 - string-width@1.0.2: + stream-to-promise@2.2.0: dependencies: - code-point-at: 1.1.0 - is-fullwidth-code-point: 1.0.0 - strip-ansi: 3.0.1 + any-promise: 1.3.0 + end-of-stream: 1.1.0 + stream-to-array: 2.3.0 - string-width@2.1.1: + streamx@2.23.0: dependencies: - is-fullwidth-code-point: 2.0.0 - strip-ansi: 4.0.0 + events-universal: 1.0.1 + fast-fifo: 1.3.2 + text-decoder: 1.2.3 + transitivePeerDependencies: + - bare-abort-controller + - react-native-b4a + + strict-event-emitter@0.5.1: {} + + strict-uri-encode@2.0.0: {} string-width@4.2.3: dependencies: @@ -18379,60 +22919,8 @@ snapshots: dependencies: eastasianwidth: 0.2.0 emoji-regex: 9.2.2 - strip-ansi: 7.2.0 - - string-width@7.2.0: - dependencies: - emoji-regex: 10.6.0 - get-east-asian-width: 1.4.0 strip-ansi: 7.1.2 - string.prototype.matchall@4.0.12: - dependencies: - call-bind: 1.0.8 - call-bound: 1.0.4 - define-properties: 1.2.1 - es-abstract: 1.24.1 - es-errors: 1.3.0 - es-object-atoms: 1.1.1 - get-intrinsic: 1.3.0 - gopd: 1.2.0 - has-symbols: 1.1.0 - internal-slot: 1.1.0 - regexp.prototype.flags: 1.5.4 - set-function-name: 2.0.2 - side-channel: 1.1.0 - - string.prototype.repeat@1.0.0: - dependencies: - define-properties: 1.2.1 - es-abstract: 1.24.1 - - string.prototype.trim@1.2.10: - dependencies: - call-bind: 1.0.9 - call-bound: 1.0.4 - define-data-property: 1.1.4 - define-properties: 1.2.1 - es-abstract: 1.24.2 - es-object-atoms: 1.1.1 - has-property-descriptors: 1.0.2 - - string.prototype.trimend@1.0.9: - dependencies: - call-bind: 1.0.9 - call-bound: 1.0.4 - define-properties: 1.2.1 - es-object-atoms: 1.1.1 - - string.prototype.trimstart@1.0.8: - dependencies: - call-bind: 1.0.9 - define-properties: 1.2.1 - es-object-atoms: 1.1.1 - - string_decoder@0.10.31: {} - string_decoder@1.1.1: dependencies: safe-buffer: 5.1.2 @@ -18441,13 +22929,10 @@ snapshots: dependencies: safe-buffer: 5.2.1 - strip-ansi@3.0.1: + stringify-entities@4.0.4: dependencies: - ansi-regex: 2.1.1 - - strip-ansi@4.0.0: - dependencies: - ansi-regex: 3.0.1 + character-entities-html4: 2.1.0 + character-entities-legacy: 3.0.0 strip-ansi@6.0.1: dependencies: @@ -18457,40 +22942,58 @@ snapshots: dependencies: ansi-regex: 6.2.2 - strip-ansi@7.2.0: - dependencies: - ansi-regex: 6.2.2 - - strip-bom@2.0.0: - dependencies: - is-utf8: 0.2.1 - strip-bom@3.0.0: {} - strip-bom@4.0.0: {} - strip-final-newline@2.0.0: {} + strip-final-newline@3.0.0: {} + + strip-final-newline@4.0.0: {} + strip-hex-prefix@1.0.0: dependencies: is-hex-prefixed: 1.0.0 - strip-json-comments@2.0.1: {} - strip-json-comments@3.1.1: {} - strnum@2.2.3: {} + strip-json-comments@5.0.1: {} + + strip-literal@1.3.0: + dependencies: + acorn: 8.11.3 + + strip-literal@3.1.0: + dependencies: + js-tokens: 9.0.1 + + strnum@2.1.2: {} - styled-jsx@5.1.6(react@19.2.3): + structured-clone-es@1.0.0: {} + + styled-jsx@5.1.6(react@18.3.1): dependencies: client-only: 0.0.1 - react: 19.2.3 + react: 18.3.1 + + stylehacks@7.0.7(postcss@8.5.6): + dependencies: + browserslist: 4.28.1 + postcss: 8.5.6 + postcss-selector-parser: 7.1.1 - superstruct@1.0.4: {} + summary@2.1.0: {} - supports-color@3.2.3: + superjson@2.2.1: dependencies: - has-flag: 1.0.0 + copy-anything: 3.0.5 + + superjson@2.2.6: + dependencies: + copy-anything: 4.0.5 + + superstruct@1.0.3: {} + + supports-color@10.2.2: {} supports-color@5.5.0: dependencies: @@ -18504,381 +23007,287 @@ snapshots: dependencies: has-flag: 4.0.0 - supports-preserve-symlinks-flag@1.0.0: {} - - swap-case@1.1.2: - dependencies: - lower-case: 1.1.4 - upper-case: 1.1.3 - - swarm-js@0.1.42(bufferutil@4.0.7)(utf-8-validate@6.0.3): - dependencies: - bluebird: 3.7.2 - buffer: 5.7.1 - eth-lib: 0.1.29(bufferutil@4.0.7)(utf-8-validate@6.0.3) - fs-extra: 4.0.3 - got: 11.8.6 - mime-types: 2.1.35 - mkdirp-promise: 5.0.1 - mock-fs: 4.14.0 - setimmediate: 1.0.5 - tar: 7.5.13 - xhr-request: 1.1.0 - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate - - swarm-js@0.1.42(bufferutil@4.1.0)(utf-8-validate@5.0.10): - dependencies: - bluebird: 3.7.2 - buffer: 5.7.1 - eth-lib: 0.1.29(bufferutil@4.1.0)(utf-8-validate@5.0.10) - fs-extra: 4.0.3 - got: 11.8.6 - mime-types: 2.1.35 - mkdirp-promise: 5.0.1 - mock-fs: 4.14.0 - setimmediate: 1.0.5 - tar: 7.5.13 - xhr-request: 1.1.0 - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate + supports-color@9.4.0: {} - swarm-js@0.1.42(bufferutil@4.1.0)(utf-8-validate@6.0.3): + supports-hyperlinks@3.0.0: dependencies: - bluebird: 3.7.2 - buffer: 5.7.1 - eth-lib: 0.1.29(bufferutil@4.1.0)(utf-8-validate@6.0.3) - fs-extra: 4.0.3 - got: 11.8.6 - mime-types: 2.1.35 - mkdirp-promise: 5.0.1 - mock-fs: 4.14.0 - setimmediate: 1.0.5 - tar: 7.5.13 - xhr-request: 1.1.0 - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate + has-flag: 4.0.0 + supports-color: 7.2.0 - symbol-observable@1.2.0: {} + supports-preserve-symlinks-flag@1.0.0: {} - sync-request@6.1.0: + svgo@4.0.0: dependencies: - http-response-object: 3.0.2 - sync-rpc: 1.3.6 - then-request: 6.0.2 + commander: 11.1.0 + css-select: 5.2.2 + css-tree: 3.1.0 + css-what: 6.2.2 + csso: 5.0.5 + picocolors: 1.1.1 + sax: 1.4.3 - sync-rpc@1.3.6: - dependencies: - get-port: 3.2.0 + system-architecture@0.1.0: {} - syncpack-darwin-arm64@14.3.0: - optional: true + tabbable@6.2.0: {} - syncpack-darwin-x64@14.3.0: - optional: true + tagged-tag@1.0.0: {} - syncpack-linux-arm64-musl@14.3.0: - optional: true + tailwind-merge@3.4.0: {} - syncpack-linux-arm64@14.3.0: - optional: true + tailwindcss@4.1.18: {} - syncpack-linux-x64-musl@14.3.0: - optional: true + tapable@2.2.1: {} - syncpack-linux-x64@14.3.0: - optional: true + tapable@2.3.0: {} - syncpack-windows-arm64@14.3.0: - optional: true + tar-stream@3.1.7: + dependencies: + b4a: 1.7.3 + fast-fifo: 1.3.2 + streamx: 2.23.0 + transitivePeerDependencies: + - bare-abort-controller + - react-native-b4a - syncpack-windows-x64@14.3.0: - optional: true + tar@6.2.1: + dependencies: + chownr: 2.0.0 + fs-minipass: 2.1.0 + minipass: 5.0.0 + minizlib: 2.1.2 + mkdirp: 1.0.4 + yallist: 4.0.0 - syncpack@14.3.0: - optionalDependencies: - syncpack-darwin-arm64: 14.3.0 - syncpack-darwin-x64: 14.3.0 - syncpack-linux-arm64: 14.3.0 - syncpack-linux-arm64-musl: 14.3.0 - syncpack-linux-x64: 14.3.0 - syncpack-linux-x64-musl: 14.3.0 - syncpack-windows-arm64: 14.3.0 - syncpack-windows-x64: 14.3.0 - - table-layout@1.0.2: - dependencies: - array-back: 4.0.2 - deep-extend: 0.6.0 - typical: 5.2.0 - wordwrapjs: 4.0.1 - - table@6.9.0: - dependencies: - ajv: 8.20.0 - lodash.truncate: 4.4.2 - slice-ansi: 4.0.0 - string-width: 4.2.3 - strip-ansi: 6.0.1 + tar@7.2.0: + dependencies: + '@isaacs/fs-minipass': 4.0.1 + chownr: 3.0.0 + minipass: 7.1.2 + minizlib: 3.0.1 + mkdirp: 3.0.1 + yallist: 5.0.0 - tar@7.5.13: + tar@7.5.2: dependencies: '@isaacs/fs-minipass': 4.0.1 chownr: 3.0.0 - minipass: 7.1.3 + minipass: 7.1.2 minizlib: 3.1.0 yallist: 5.0.0 - term-size@2.2.1: {} + temp-dir@1.0.0: {} - test-exclude@6.0.0: + tempy@0.2.1: dependencies: - '@istanbuljs/schema': 0.1.6 - glob: 7.2.3 - minimatch: 10.2.5 + temp-dir: 1.0.0 + unique-string: 1.0.0 - testrpc@0.0.1: {} + term-size@2.2.1: {} - text-table@0.2.0: {} + terser@5.44.1: + dependencies: + '@jridgewell/source-map': 0.3.11 + acorn: 8.15.0 + commander: 2.20.3 + source-map-support: 0.5.21 - then-request@6.0.2: + test-exclude@7.0.1: dependencies: - '@types/concat-stream': 1.6.1 - '@types/form-data': 0.0.33 - '@types/node': 8.10.66 - '@types/qs': 6.15.0 - caseless: 0.12.0 - concat-stream: 1.6.2 - form-data: 4.0.5 - http-basic: 8.1.3 - http-response-object: 3.0.2 - promise: 8.3.0 - qs: 6.15.1 + '@istanbuljs/schema': 0.1.3 + glob: 10.5.0 + minimatch: 9.0.5 - threads@1.7.0: + text-decoder@1.2.3: dependencies: - callsites: 3.1.0 - debug: 4.4.3(supports-color@5.5.0) - is-observable: 2.1.0 - observable-fns: 0.6.1 - optionalDependencies: - tiny-worker: 2.3.0 + b4a: 1.7.3 transitivePeerDependencies: - - supports-color + - react-native-b4a - through2@4.0.2: + thenify-all@1.6.0: dependencies: - readable-stream: 3.6.2 + thenify: 3.3.1 + + thenify@3.3.1: + dependencies: + any-promise: 1.3.0 - through@2.3.8: {} + thread-stream@0.15.2: + dependencies: + real-require: 0.1.0 - timed-out@4.0.1: {} + throttleit@2.1.0: {} - tiny-worker@2.3.0: + time-span@4.0.0: dependencies: - esm: 3.2.25 - optional: true + convert-hrtime: 3.0.0 + + tiny-invariant@1.3.3: {} tinybench@2.9.0: {} - tinycolor2@1.6.0: {} + tinyexec@0.3.2: {} tinyexec@1.0.2: {} - tinyglobby@0.2.15: + tinyglobby@0.2.14: dependencies: fdir: 6.5.0(picomatch@4.0.3) picomatch: 4.0.3 - tinyglobby@0.2.16: - dependencies: - fdir: 6.5.0(picomatch@4.0.4) - picomatch: 4.0.4 - - tinygradient@1.1.5: + tinyglobby@0.2.15: dependencies: - '@types/tinycolor2': 1.4.6 - tinycolor2: 1.6.0 - - tinyrainbow@3.0.3: {} + fdir: 6.5.0(picomatch@4.0.3) + picomatch: 4.0.3 - title-case@2.1.1: - dependencies: - no-case: 2.3.2 - upper-case: 1.1.3 + tinypool@1.0.2: {} - tldts-core@6.1.86: {} + tinyrainbow@1.2.0: {} - tldts-core@7.0.28: {} + tinyrainbow@2.0.0: {} - tldts@6.1.86: - dependencies: - tldts-core: 6.1.86 + tinyspy@3.0.2: {} - tldts@7.0.28: + tmp@0.0.33: dependencies: - tldts-core: 7.0.28 + os-tmpdir: 1.0.2 - tmp@0.2.5: {} - - to-buffer@1.2.2: - dependencies: - isarray: 2.0.5 - safe-buffer: 5.2.1 - typed-array-buffer: 1.0.3 + to-fast-properties@2.0.0: {} to-regex-range@5.0.1: dependencies: is-number: 7.0.0 - toidentifier@1.0.1: {} + toidentifier@1.0.0: {} - touch@3.1.1: {} + toidentifier@1.0.1: {} - tough-cookie@5.1.2: - dependencies: - tldts: 6.1.86 + totalist@3.0.1: {} - tough-cookie@6.0.1: + tough-cookie@4.1.4: dependencies: - tldts: 7.0.28 + psl: 1.9.0 + punycode: 2.3.1 + universalify: 0.2.0 + url-parse: 1.5.10 tr46@0.0.3: {} - tr46@2.1.0: - dependencies: - punycode: 2.3.1 - tree-kill@1.2.2: {} - ts-api-utils@2.5.0(typescript@4.9.5): - dependencies: - typescript: 4.9.5 - - ts-api-utils@2.5.0(typescript@5.9.3): - dependencies: - typescript: 5.9.3 - - ts-command-line-args@2.5.1: - dependencies: - chalk: 4.1.2 - command-line-args: 5.2.1 - command-line-usage: 6.1.3 - string-format: 2.0.0 - - ts-essentials@7.0.3(typescript@4.9.5): - dependencies: - typescript: 4.9.5 + trim-lines@3.0.1: {} - ts-essentials@7.0.3(typescript@5.9.3): + ts-essentials@7.0.3(typescript@5.8.3): dependencies: - typescript: 5.9.3 + typescript: 5.8.3 - ts-node@10.9.2(@types/node@25.3.0)(typescript@5.9.3): + ts-morph@12.0.0: dependencies: - '@cspotcode/source-map-support': 0.8.1 - '@tsconfig/node10': 1.0.12 - '@tsconfig/node12': 1.0.11 - '@tsconfig/node14': 1.0.3 - '@tsconfig/node16': 1.0.4 - '@types/node': 25.3.0 - acorn: 8.16.0 - acorn-walk: 8.3.5 - arg: 4.1.3 - create-require: 1.1.1 - diff: 9.0.0 - make-error: 1.3.6 - typescript: 5.9.3 - v8-compile-cache-lib: 3.0.1 - yn: 3.1.1 + '@ts-morph/common': 0.11.1 + code-block-writer: 10.1.1 - ts-node@10.9.2(@types/node@25.6.0)(typescript@4.9.5): + ts-node@10.9.1(@types/node@16.18.11)(typescript@4.9.5): dependencies: '@cspotcode/source-map-support': 0.8.1 '@tsconfig/node10': 1.0.12 '@tsconfig/node12': 1.0.11 '@tsconfig/node14': 1.0.3 '@tsconfig/node16': 1.0.4 - '@types/node': 25.6.0 - acorn: 8.16.0 - acorn-walk: 8.3.5 + '@types/node': 16.18.11 + acorn: 8.15.0 + acorn-walk: 8.3.4 arg: 4.1.3 create-require: 1.1.1 - diff: 9.0.0 + diff: 4.0.2 make-error: 1.3.6 typescript: 4.9.5 v8-compile-cache-lib: 3.0.1 yn: 3.1.1 - ts-node@10.9.2(@types/node@25.6.0)(typescript@5.9.3): + ts-node@10.9.1(@types/node@24.0.1)(typescript@5.9.3): dependencies: '@cspotcode/source-map-support': 0.8.1 '@tsconfig/node10': 1.0.12 '@tsconfig/node12': 1.0.11 '@tsconfig/node14': 1.0.3 '@tsconfig/node16': 1.0.4 - '@types/node': 25.6.0 - acorn: 8.16.0 - acorn-walk: 8.3.5 + '@types/node': 24.0.1 + acorn: 8.15.0 + acorn-walk: 8.3.4 arg: 4.1.3 create-require: 1.1.1 - diff: 9.0.0 + diff: 4.0.2 make-error: 1.3.6 typescript: 5.9.3 v8-compile-cache-lib: 3.0.1 yn: 3.1.1 + optional: true - tsconfig-paths@3.15.0: - dependencies: - '@types/json5': 0.0.29 - json5: 1.0.2 - minimist: 1.2.8 - strip-bom: 3.0.0 + ts-toolbelt@6.15.5: {} + + tslib@1.14.1: {} + + tslib@2.7.0: {} + + tslib@2.8.1: {} + + tsort@0.0.1: {} + + tsx@4.19.2: + dependencies: + esbuild: 0.23.1 + get-tsconfig: 4.13.0 + optionalDependencies: + fsevents: 2.3.3 - tslib@1.14.1: {} + turbo-darwin-64@2.7.2: + optional: true - tslib@2.7.0: {} + turbo-darwin-arm64@2.7.2: + optional: true - tslib@2.8.1: {} + turbo-linux-64@2.7.2: + optional: true - tslog@4.10.2: {} + turbo-linux-arm64@2.7.2: + optional: true - tsort@0.0.1: {} + turbo-windows-64@2.7.2: + optional: true - tunnel-agent@0.6.0: - dependencies: - safe-buffer: 5.2.1 + turbo-windows-arm64@2.7.2: + optional: true - turbo@2.9.6: + turbo@2.7.2: optionalDependencies: - '@turbo/darwin-64': 2.9.6 - '@turbo/darwin-arm64': 2.9.6 - '@turbo/linux-64': 2.9.6 - '@turbo/linux-arm64': 2.9.6 - '@turbo/windows-64': 2.9.6 - '@turbo/windows-arm64': 2.9.6 + turbo-darwin-64: 2.7.2 + turbo-darwin-arm64: 2.7.2 + turbo-linux-64: 2.7.2 + turbo-linux-arm64: 2.7.2 + turbo-windows-64: 2.7.2 + turbo-windows-arm64: 2.7.2 tweetnacl-util@0.15.1: {} - tweetnacl@0.14.5: {} - tweetnacl@1.0.3: {} - type-check@0.3.2: - dependencies: - prelude-ls: 1.1.2 + twoslash-protocol@0.2.12: {} - type-check@0.4.0: + twoslash-vue@0.2.12(typescript@5.9.3): dependencies: - prelude-ls: 1.2.1 + '@vue/language-core': 2.1.10(typescript@5.9.3) + twoslash: 0.2.12(typescript@5.9.3) + twoslash-protocol: 0.2.12 + typescript: 5.9.3 + transitivePeerDependencies: + - supports-color - type-detect@4.1.0: {} + twoslash@0.2.12(typescript@5.9.3): + dependencies: + '@typescript/vfs': 1.6.0(typescript@5.9.3) + twoslash-protocol: 0.2.12 + typescript: 5.9.3 + transitivePeerDependencies: + - supports-color type-fest@0.20.2: {} @@ -18886,202 +23295,351 @@ snapshots: type-fest@0.7.1: {} - type-fest@0.8.1: {} + type-fest@4.18.2: {} - type-is@1.6.18: + type-fest@5.3.1: dependencies: - media-typer: 0.3.0 - mime-types: 2.1.35 + tagged-tag: 1.0.0 + + type-level-regexp@0.1.17: {} + + typescript@4.9.5: {} + + typescript@5.6.1-rc: {} + + typescript@5.8.3: {} + + typescript@5.9.3: {} - type@2.7.3: {} + ufo@1.5.3: {} - typechain@8.3.2(typescript@4.9.5): + ufo@1.6.1: {} + + uid-promise@1.0.0: {} + + uint8arrays@3.1.0: dependencies: - '@types/prettier': 2.7.3 - debug: 4.4.3(supports-color@5.5.0) - fs-extra: 7.0.1 - glob: 7.1.7 - js-sha3: 0.8.0 - lodash: 4.18.1 - mkdirp: 1.0.4 - prettier: 2.8.8 - ts-command-line-args: 2.5.1 - ts-essentials: 7.0.3(typescript@4.9.5) - typescript: 4.9.5 - transitivePeerDependencies: - - supports-color + multiformats: 9.9.0 - typechain@8.3.2(typescript@5.9.3): + uint8arrays@3.1.1: dependencies: - '@types/prettier': 2.7.3 - debug: 4.4.3(supports-color@5.5.0) - fs-extra: 7.0.1 - glob: 7.1.7 - js-sha3: 0.8.0 - lodash: 4.18.1 - mkdirp: 1.0.4 - prettier: 2.8.8 - ts-command-line-args: 2.5.1 - ts-essentials: 7.0.3(typescript@5.9.3) - typescript: 5.9.3 - transitivePeerDependencies: - - supports-color + multiformats: 9.9.0 - typed-array-buffer@1.0.3: + ultrahtml@1.6.0: {} + + unconfig@0.3.13: dependencies: - call-bound: 1.0.4 - es-errors: 1.3.0 - is-typed-array: 1.1.15 + '@antfu/utils': 0.7.7 + defu: 6.1.4 + jiti: 1.21.7 - typed-array-byte-length@1.0.3: + uncrypto@0.1.3: {} + + unctx@2.5.0: dependencies: - call-bind: 1.0.9 - for-each: 0.3.5 - gopd: 1.2.0 - has-proto: 1.2.0 - is-typed-array: 1.1.15 + acorn: 8.15.0 + estree-walker: 3.0.3 + magic-string: 0.30.21 + unplugin: 2.3.11 + + undici-types@5.26.5: {} + + undici-types@6.19.8: {} + + undici-types@6.21.0: {} + + undici-types@7.8.0: {} - typed-array-byte-offset@1.0.4: + undici@5.28.3: dependencies: - available-typed-arrays: 1.0.7 - call-bind: 1.0.9 - for-each: 0.3.5 - gopd: 1.2.0 - has-proto: 1.2.0 - is-typed-array: 1.1.15 - reflect.getprototypeof: 1.0.10 + '@fastify/busboy': 2.1.0 - typed-array-length@1.0.7: + undici@5.28.4: dependencies: - call-bind: 1.0.9 - for-each: 0.3.5 - gopd: 1.2.0 - is-typed-array: 1.1.15 - possible-typed-array-names: 1.1.0 - reflect.getprototypeof: 1.0.10 + '@fastify/busboy': 2.1.1 - typed-error@3.2.3: {} + undici@5.29.0: + dependencies: + '@fastify/busboy': 2.1.1 + + unenv@2.0.0-rc.24: + dependencies: + pathe: 2.0.3 - typedarray-to-buffer@3.1.5: + unhead@2.1.1: dependencies: - is-typedarray: 1.0.0 + hookable: 5.5.3 - typedarray@0.0.6: {} + unicode-emoji-modifier-base@1.0.0: {} - typescript-eslint@8.50.0(eslint@9.39.2)(typescript@5.9.3): + unicorn-magic@0.3.0: {} + + unimport@3.7.1(rollup@4.54.0): dependencies: - '@typescript-eslint/eslint-plugin': 8.50.0(@typescript-eslint/parser@8.50.0(eslint@9.39.2)(typescript@5.9.3))(eslint@9.39.2)(typescript@5.9.3) - '@typescript-eslint/parser': 8.50.0(eslint@9.39.2)(typescript@5.9.3) - '@typescript-eslint/typescript-estree': 8.50.0(typescript@5.9.3) - '@typescript-eslint/utils': 8.50.0(eslint@9.39.2)(typescript@5.9.3) - eslint: 9.39.2 - typescript: 5.9.3 + '@rollup/pluginutils': 5.1.0(rollup@4.54.0) + acorn: 8.11.3 + escape-string-regexp: 5.0.0 + estree-walker: 3.0.3 + fast-glob: 3.3.2 + local-pkg: 0.5.0 + magic-string: 0.30.10 + mlly: 1.7.0 + pathe: 1.1.2 + pkg-types: 1.1.0 + scule: 1.3.0 + strip-literal: 1.3.0 + unplugin: 1.10.1 transitivePeerDependencies: - - supports-color + - rollup - typescript@4.9.5: {} - - typescript@5.9.3: {} + unimport@5.6.0: + dependencies: + acorn: 8.15.0 + escape-string-regexp: 5.0.0 + estree-walker: 3.0.3 + local-pkg: 1.1.2 + magic-string: 0.30.21 + mlly: 1.8.0 + pathe: 2.0.3 + picomatch: 4.0.3 + pkg-types: 2.3.0 + scule: 1.3.0 + strip-literal: 3.1.0 + tinyglobby: 0.2.15 + unplugin: 2.3.11 + unplugin-utils: 0.3.1 - typeson-registry@1.0.0-alpha.39: + unique-string@1.0.0: dependencies: - base64-arraybuffer-es6: 0.7.0 - typeson: 6.1.0 - whatwg-url: 8.7.0 + crypto-random-string: 1.0.0 - typeson@6.1.0: {} + unist-util-is@6.0.0: + dependencies: + '@types/unist': 3.0.2 - typical@4.0.0: {} + unist-util-position@5.0.0: + dependencies: + '@types/unist': 3.0.2 - typical@5.2.0: {} + unist-util-stringify-position@4.0.0: + dependencies: + '@types/unist': 3.0.2 - uglify-js@3.19.3: - optional: true + unist-util-visit-parents@6.0.1: + dependencies: + '@types/unist': 3.0.2 + unist-util-is: 6.0.0 - unbox-primitive@1.1.0: + unist-util-visit@5.0.0: dependencies: - call-bound: 1.0.4 - has-bigints: 1.1.0 - has-symbols: 1.1.0 - which-boxed-primitive: 1.1.1 + '@types/unist': 3.0.2 + unist-util-is: 6.0.0 + unist-util-visit-parents: 6.0.1 - undefsafe@2.0.5: {} + universalify@0.1.2: {} - undici-types@6.19.8: {} + universalify@0.2.0: {} - undici-types@7.18.2: {} + universalify@2.0.1: {} - undici-types@7.19.2: {} + unocss@0.59.4(rollup@4.54.0): + dependencies: + '@unocss/astro': 0.59.4(rollup@4.54.0) + '@unocss/cli': 0.59.4(rollup@4.54.0) + '@unocss/core': 0.59.4 + '@unocss/extractor-arbitrary-variants': 0.59.4 + '@unocss/postcss': 0.59.4 + '@unocss/preset-attributify': 0.59.4 + '@unocss/preset-icons': 0.59.4 + '@unocss/preset-mini': 0.59.4 + '@unocss/preset-tagify': 0.59.4 + '@unocss/preset-typography': 0.59.4 + '@unocss/preset-uno': 0.59.4 + '@unocss/preset-web-fonts': 0.59.4 + '@unocss/preset-wind': 0.59.4 + '@unocss/reset': 0.59.4 + '@unocss/transformer-attributify-jsx': 0.59.4 + '@unocss/transformer-attributify-jsx-babel': 0.59.4 + '@unocss/transformer-compile-class': 0.59.4 + '@unocss/transformer-directives': 0.59.4 + '@unocss/transformer-variant-group': 0.59.4 + '@unocss/vite': 0.59.4(rollup@4.54.0) + transitivePeerDependencies: + - rollup + - supports-color - undici@8.1.0: {} + unpipe@1.0.0: {} - unfetch@4.2.0: {} + unplugin-utils@0.2.5: + dependencies: + pathe: 2.0.3 + picomatch: 4.0.3 - unique-filename@3.0.0: + unplugin-utils@0.3.1: dependencies: - unique-slug: 4.0.0 + pathe: 2.0.3 + picomatch: 4.0.3 - unique-slug@4.0.0: + unplugin-vue-router@0.15.0(@vue/compiler-sfc@3.5.26)(vue-router@4.6.4(vue@3.5.26(typescript@5.9.3)))(vue@3.5.26(typescript@5.9.3)): dependencies: - imurmurhash: 0.1.4 + '@vue-macros/common': 3.0.0-beta.16(vue@3.5.26(typescript@5.9.3)) + '@vue/compiler-sfc': 3.5.26 + '@vue/language-core': 3.2.1 + ast-walker-scope: 0.8.3 + chokidar: 4.0.3 + json5: 2.2.3 + local-pkg: 1.1.2 + magic-string: 0.30.21 + mlly: 1.8.0 + muggle-string: 0.4.1 + pathe: 2.0.3 + picomatch: 4.0.3 + scule: 1.3.0 + tinyglobby: 0.2.15 + unplugin: 2.3.11 + unplugin-utils: 0.2.5 + yaml: 2.8.2 + optionalDependencies: + vue-router: 4.6.4(vue@3.5.26(typescript@5.9.3)) + transitivePeerDependencies: + - vue - universalify@0.1.2: {} + unplugin@1.10.1: + dependencies: + acorn: 8.11.3 + chokidar: 3.6.0 + webpack-sources: 3.2.3 + webpack-virtual-modules: 0.6.1 - universalify@2.0.1: {} + unplugin@2.3.11: + dependencies: + '@jridgewell/remapping': 2.3.5 + acorn: 8.15.0 + picomatch: 4.0.3 + webpack-virtual-modules: 0.6.2 - unpipe@1.0.0: {} + unstorage@1.10.2(idb-keyval@6.2.1)(ioredis@5.8.2): + dependencies: + anymatch: 3.1.3 + chokidar: 3.6.0 + destr: 2.0.5 + h3: 1.15.4 + listhen: 1.7.2 + lru-cache: 10.2.2 + mri: 1.2.0 + node-fetch-native: 1.6.4 + ofetch: 1.5.1 + ufo: 1.6.1 + optionalDependencies: + idb-keyval: 6.2.1 + ioredis: 5.8.2 + transitivePeerDependencies: + - uWebSockets.js - update-browserslist-db@1.2.2(browserslist@4.28.1): + unstorage@1.17.3(@vercel/blob@1.0.2)(db0@0.3.4)(idb-keyval@6.2.1)(ioredis@5.8.2): dependencies: - browserslist: 4.28.1 - escalade: 3.2.0 - picocolors: 1.1.1 + anymatch: 3.1.3 + chokidar: 4.0.3 + destr: 2.0.5 + h3: 1.15.4 + lru-cache: 10.4.3 + node-fetch-native: 1.6.7 + ofetch: 1.5.1 + ufo: 1.6.1 + optionalDependencies: + '@vercel/blob': 1.0.2 + db0: 0.3.4 + idb-keyval: 6.2.1 + ioredis: 5.8.2 - update-browserslist-db@1.2.3(browserslist@4.28.2): + untun@0.1.3: dependencies: - browserslist: 4.28.2 - escalade: 3.2.0 - picocolors: 1.1.1 + citty: 0.1.6 + consola: 3.4.2 + pathe: 1.1.2 + + untyped@1.4.2: + dependencies: + '@babel/core': 7.24.5 + '@babel/standalone': 7.24.5 + '@babel/types': 7.24.5 + defu: 6.1.4 + jiti: 1.21.0 + mri: 1.2.0 + scule: 1.3.0 + transitivePeerDependencies: + - supports-color + + untyped@2.0.0: + dependencies: + citty: 0.1.6 + defu: 6.1.4 + jiti: 2.6.1 + knitwork: 1.3.0 + scule: 1.3.0 + + unwasm@0.3.11: + dependencies: + knitwork: 1.3.0 + magic-string: 0.30.21 + mlly: 1.8.0 + pathe: 2.0.3 + pkg-types: 2.3.0 + unplugin: 2.3.11 - update-check@1.5.4: + update-browserslist-db@1.0.15(browserslist@4.23.0): dependencies: - registry-auth-token: 3.3.2 - registry-url: 3.1.0 + browserslist: 4.23.0 + escalade: 3.2.0 + picocolors: 1.1.1 - upper-case-first@1.1.2: + update-browserslist-db@1.2.3(browserslist@4.28.1): dependencies: - upper-case: 1.1.3 + browserslist: 4.28.1 + escalade: 3.2.0 + picocolors: 1.1.1 - upper-case@1.1.3: {} + uqr@0.1.2: {} uri-js@4.4.1: dependencies: punycode: 2.3.1 - url-set-query@1.0.0: {} + url-parse@1.5.10: + dependencies: + querystringify: 2.2.0 + requires-port: 1.0.0 + + use-callback-ref@1.3.3(@types/react@18.3.27)(react@18.3.1): + dependencies: + react: 18.3.1 + tslib: 2.8.1 + optionalDependencies: + '@types/react': 18.3.27 - url@0.11.4: + use-sidecar@1.1.3(@types/react@18.3.27)(react@18.3.1): dependencies: - punycode: 1.4.1 - qs: 6.15.1 + detect-node-es: 1.1.0 + react: 18.3.1 + tslib: 2.8.1 + optionalDependencies: + '@types/react': 18.3.27 - urlpattern-polyfill@8.0.2: {} + use-sync-external-store@1.2.0(react@18.3.1): + dependencies: + react: 18.3.1 - utf-8-validate@5.0.10: + use-sync-external-store@1.4.0(react@18.3.1): dependencies: - node-gyp-build: 4.8.4 + react: 18.3.1 - utf-8-validate@5.0.7: + utf-8-validate@5.0.10: dependencies: node-gyp-build: 4.8.4 - optional: true - utf-8-validate@6.0.3: + utf-8-validate@6.0.5: dependencies: node-gyp-build: 4.8.4 - optional: true - - utf8@3.0.0: {} util-deprecate@1.0.2: {} @@ -19091,13 +23649,9 @@ snapshots: is-arguments: 1.2.0 is-generator-function: 1.1.2 is-typed-array: 1.1.15 - which-typed-array: 1.1.20 - - utils-merge@1.0.1: {} - - uuid@14.0.0: {} + which-typed-array: 1.1.19 - uuid@3.4.0: {} + uuid@10.0.0: {} uuid@8.3.2: {} @@ -19105,35 +23659,173 @@ snapshots: v8-compile-cache-lib@3.0.1: {} - validate-npm-package-license@3.0.4: + validate-npm-package-name@5.0.1: {} + + valtio@1.13.2(@types/react@18.3.27)(react@18.3.1): + dependencies: + derive-valtio: 0.1.0(valtio@1.13.2(@types/react@18.3.27)(react@18.3.1)) + proxy-compare: 2.6.0 + use-sync-external-store: 1.2.0(react@18.3.1) + optionalDependencies: + '@types/react': 18.3.27 + react: 18.3.1 + + vercel@48.12.1(encoding@0.1.13)(rollup@4.54.0)(typescript@5.8.3): + dependencies: + '@vercel/backends': 0.0.14(encoding@0.1.13)(rollup@4.54.0)(typescript@5.8.3) + '@vercel/blob': 1.0.2 + '@vercel/build-utils': 13.2.2 + '@vercel/detect-agent': 1.0.0 + '@vercel/elysia': 0.1.12(encoding@0.1.13)(rollup@4.54.0) + '@vercel/express': 0.1.17(encoding@0.1.13)(rollup@4.54.0)(typescript@5.8.3) + '@vercel/fastify': 0.1.15(encoding@0.1.13)(rollup@4.54.0) + '@vercel/fun': 1.2.0(encoding@0.1.13) + '@vercel/go': 3.2.3 + '@vercel/h3': 0.1.21(encoding@0.1.13)(rollup@4.54.0) + '@vercel/hono': 0.2.15(encoding@0.1.13)(rollup@4.54.0) + '@vercel/hydrogen': 1.3.2 + '@vercel/nestjs': 0.2.16(encoding@0.1.13)(rollup@4.54.0) + '@vercel/next': 4.15.7(encoding@0.1.13)(rollup@4.54.0) + '@vercel/node': 5.5.14(encoding@0.1.13)(rollup@4.54.0) + '@vercel/python': 6.1.0 + '@vercel/redwood': 2.4.5(encoding@0.1.13)(rollup@4.54.0) + '@vercel/remix-builder': 5.5.5(encoding@0.1.13)(rollup@4.54.0) + '@vercel/ruby': 2.2.2 + '@vercel/rust': 1.0.3 + '@vercel/static-build': 2.8.13 + chokidar: 4.0.0 + jose: 5.9.6 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + - encoding + - rollup + - supports-color + - typescript + + vfile-message@4.0.2: dependencies: - spdx-correct: 3.2.0 - spdx-expression-parse: 3.0.1 + '@types/unist': 3.0.2 + unist-util-stringify-position: 4.0.0 - validate-npm-package-name@5.0.1: {} + vfile@6.0.1: + dependencies: + '@types/unist': 3.0.2 + unist-util-stringify-position: 4.0.0 + vfile-message: 4.0.2 + + viem@2.10.8(bufferutil@4.0.8)(typescript@5.9.3)(utf-8-validate@6.0.5)(zod@3.25.20): + dependencies: + '@adraffy/ens-normalize': 1.10.0 + '@noble/curves': 1.2.0 + '@noble/hashes': 1.3.2 + '@scure/bip32': 1.3.2 + '@scure/bip39': 1.2.1 + abitype: 1.0.0(typescript@5.9.3)(zod@3.25.20) + isows: 1.0.4(ws@8.13.0(bufferutil@4.0.8)(utf-8-validate@6.0.5)) + ws: 8.13.0(bufferutil@4.0.8)(utf-8-validate@6.0.5) + optionalDependencies: + typescript: 5.9.3 + transitivePeerDependencies: + - bufferutil + - utf-8-validate + - zod + + viem@2.10.8(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@6.0.5)(zod@3.25.20): + dependencies: + '@adraffy/ens-normalize': 1.10.0 + '@noble/curves': 1.2.0 + '@noble/hashes': 1.3.2 + '@scure/bip32': 1.3.2 + '@scure/bip39': 1.2.1 + abitype: 1.0.0(typescript@5.9.3)(zod@3.25.20) + isows: 1.0.4(ws@8.13.0(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ws: 8.13.0(bufferutil@4.1.0)(utf-8-validate@6.0.5) + optionalDependencies: + typescript: 5.9.3 + transitivePeerDependencies: + - bufferutil + - utf-8-validate + - zod - value-or-promise@1.0.11: {} + viem@2.17.0(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20): + dependencies: + '@adraffy/ens-normalize': 1.10.0 + '@noble/curves': 1.4.0 + '@noble/hashes': 1.4.0 + '@scure/bip32': 1.4.0 + '@scure/bip39': 1.3.0 + abitype: 1.0.5(typescript@5.9.3)(zod@3.25.20) + isows: 1.0.4(ws@8.17.1(bufferutil@4.1.0)(utf-8-validate@5.0.10)) + ws: 8.17.1(bufferutil@4.1.0)(utf-8-validate@5.0.10) + optionalDependencies: + typescript: 5.9.3 + transitivePeerDependencies: + - bufferutil + - utf-8-validate + - zod - varint@5.0.2: {} + viem@2.23.2(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20): + dependencies: + '@noble/curves': 1.8.1 + '@noble/hashes': 1.7.1 + '@scure/bip32': 1.6.2 + '@scure/bip39': 1.5.4 + abitype: 1.0.8(typescript@5.9.3)(zod@3.25.20) + isows: 1.0.6(ws@8.18.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)) + ox: 0.6.7(typescript@5.9.3)(zod@3.25.20) + ws: 8.18.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + optionalDependencies: + typescript: 5.9.3 + transitivePeerDependencies: + - bufferutil + - utf-8-validate + - zod - vary@1.1.2: {} + viem@2.31.4(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20): + dependencies: + '@noble/curves': 1.9.2 + '@noble/hashes': 1.8.0 + '@scure/bip32': 1.7.0 + '@scure/bip39': 1.6.0 + abitype: 1.0.8(typescript@5.8.3)(zod@3.25.20) + isows: 1.0.7(ws@8.18.2(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ox: 0.8.1(typescript@5.8.3)(zod@3.25.20) + ws: 8.18.2(bufferutil@4.1.0)(utf-8-validate@6.0.5) + optionalDependencies: + typescript: 5.8.3 + transitivePeerDependencies: + - bufferutil + - utf-8-validate + - zod - verror@1.10.0: + viem@2.43.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.22.4): dependencies: - assert-plus: 1.0.0 - core-util-is: 1.0.2 - extsprintf: 1.3.0 + '@noble/curves': 1.9.1 + '@noble/hashes': 1.8.0 + '@scure/bip32': 1.7.0 + '@scure/bip39': 1.6.0 + abitype: 1.2.3(typescript@5.9.3)(zod@3.22.4) + isows: 1.0.7(ws@8.18.3(bufferutil@4.1.0)(utf-8-validate@5.0.10)) + ox: 0.11.1(typescript@5.9.3)(zod@3.22.4) + ws: 8.18.3(bufferutil@4.1.0)(utf-8-validate@5.0.10) + optionalDependencies: + typescript: 5.9.3 + transitivePeerDependencies: + - bufferutil + - utf-8-validate + - zod - viem@2.42.1(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@6.0.3)(zod@4.2.0): + viem@2.43.3(bufferutil@4.1.0)(typescript@5.9.3)(utf-8-validate@5.0.10)(zod@3.25.20): dependencies: '@noble/curves': 1.9.1 '@noble/hashes': 1.8.0 '@scure/bip32': 1.7.0 '@scure/bip39': 1.6.0 - abitype: 1.1.0(typescript@5.9.3)(zod@4.2.0) - isows: 1.0.7(ws@8.18.3(bufferutil@4.1.0)(utf-8-validate@6.0.3)) - ox: 0.9.17(typescript@5.9.3)(zod@4.2.0) - ws: 8.18.3(bufferutil@4.1.0)(utf-8-validate@6.0.3) + abitype: 1.2.3(typescript@5.9.3)(zod@3.25.20) + isows: 1.0.7(ws@8.18.3(bufferutil@4.1.0)(utf-8-validate@5.0.10)) + ox: 0.11.1(typescript@5.9.3)(zod@3.25.20) + ws: 8.18.3(bufferutil@4.1.0)(utf-8-validate@5.0.10) optionalDependencies: typescript: 5.9.3 transitivePeerDependencies: @@ -19141,415 +23833,356 @@ snapshots: - utf-8-validate - zod - vite@7.3.0(@types/node@25.3.0): + viem@2.43.5(bufferutil@4.1.0)(typescript@5.8.3)(utf-8-validate@6.0.5)(zod@3.25.20): dependencies: - esbuild: 0.27.3 - fdir: 6.5.0(picomatch@4.0.3) - picomatch: 4.0.3 - postcss: 8.5.10 - rollup: 4.60.2 - tinyglobby: 0.2.15 + '@noble/curves': 1.9.1 + '@noble/hashes': 1.8.0 + '@scure/bip32': 1.7.0 + '@scure/bip39': 1.6.0 + abitype: 1.2.3(typescript@5.8.3)(zod@3.25.20) + isows: 1.0.7(ws@8.18.3(bufferutil@4.1.0)(utf-8-validate@6.0.5)) + ox: 0.11.1(typescript@5.8.3)(zod@3.25.20) + ws: 8.18.3(bufferutil@4.1.0)(utf-8-validate@6.0.5) optionalDependencies: - '@types/node': 25.3.0 - fsevents: 2.3.3 + typescript: 5.8.3 + transitivePeerDependencies: + - bufferutil + - utf-8-validate + - zod - vite@7.3.0(@types/node@25.6.0): + vite-dev-rpc@1.1.0(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2)): dependencies: - esbuild: 0.27.3 - fdir: 6.5.0(picomatch@4.0.3) - picomatch: 4.0.3 - postcss: 8.5.10 - rollup: 4.60.2 - tinyglobby: 0.2.15 - optionalDependencies: - '@types/node': 25.6.0 - fsevents: 2.3.3 + birpc: 2.9.0 + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + vite-hot-client: 2.1.0(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2)) + + vite-hot-client@2.1.0(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2)): + dependencies: + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) - vitest@4.0.18(@types/node@25.3.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)): + vite-node@2.1.9(@types/node@24.0.1)(lightningcss@1.30.2)(terser@5.44.1): dependencies: - '@vitest/expect': 4.0.18 - '@vitest/mocker': 4.0.18(vite@7.3.0(@types/node@25.3.0)) - '@vitest/pretty-format': 4.0.18 - '@vitest/runner': 4.0.18 - '@vitest/snapshot': 4.0.18 - '@vitest/spy': 4.0.18 - '@vitest/utils': 4.0.18 + cac: 6.7.14 + debug: 4.4.3 es-module-lexer: 1.7.0 - expect-type: 1.3.0 - magic-string: 0.30.21 - obug: 2.1.1 - pathe: 2.0.3 - picomatch: 4.0.3 - std-env: 3.10.0 - tinybench: 2.9.0 - tinyexec: 1.0.2 - tinyglobby: 0.2.15 - tinyrainbow: 3.0.3 - vite: 7.3.0(@types/node@25.3.0) - why-is-node-running: 2.3.0 - optionalDependencies: - '@types/node': 25.3.0 - happy-dom: 20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3) + pathe: 1.1.2 + vite: 5.4.21(@types/node@24.0.1)(lightningcss@1.30.2)(terser@5.44.1) transitivePeerDependencies: - - jiti + - '@types/node' - less - lightningcss - - msw - sass - sass-embedded - stylus - sugarss + - supports-color - terser - - tsx - - yaml - vitest@4.0.18(@types/node@25.6.0)(happy-dom@20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3)): + vite-node@3.2.4(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2): dependencies: - '@vitest/expect': 4.0.18 - '@vitest/mocker': 4.0.18(vite@7.3.0(@types/node@25.6.0)) - '@vitest/pretty-format': 4.0.18 - '@vitest/runner': 4.0.18 - '@vitest/snapshot': 4.0.18 - '@vitest/spy': 4.0.18 - '@vitest/utils': 4.0.18 + cac: 6.7.14 + debug: 4.4.3 es-module-lexer: 1.7.0 - expect-type: 1.3.0 - magic-string: 0.30.21 - obug: 2.1.1 pathe: 2.0.3 - picomatch: 4.0.3 - std-env: 3.10.0 - tinybench: 2.9.0 - tinyexec: 1.0.2 - tinyglobby: 0.2.15 - tinyrainbow: 3.0.3 - vite: 7.3.0(@types/node@25.6.0) - why-is-node-running: 2.3.0 - optionalDependencies: - '@types/node': 25.6.0 - happy-dom: 20.8.9(bufferutil@4.1.0)(utf-8-validate@6.0.3) + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) transitivePeerDependencies: + - '@types/node' - jiti - less - lightningcss - - msw - sass - sass-embedded - stylus - sugarss + - supports-color - terser - tsx - yaml - wcwidth@1.0.1: + vite-plugin-checker@0.10.3(@biomejs/biome@1.9.4)(typescript@5.9.3)(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2)): dependencies: - defaults: 1.0.4 - - web-streams-polyfill@3.3.3: {} + '@babel/code-frame': 7.27.1 + chokidar: 4.0.3 + npm-run-path: 6.0.0 + picocolors: 1.1.1 + picomatch: 4.0.3 + strip-ansi: 7.1.2 + tiny-invariant: 1.3.3 + tinyglobby: 0.2.15 + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + vscode-uri: 3.1.0 + optionalDependencies: + '@biomejs/biome': 1.9.4 + typescript: 5.9.3 - web3-bzz@1.10.4(bufferutil@4.0.7)(utf-8-validate@6.0.3): - dependencies: - '@types/node': 12.20.55 - got: 12.1.0 - swarm-js: 0.1.42(bufferutil@4.0.7)(utf-8-validate@6.0.3) + vite-plugin-inspect@11.3.3(@nuxt/kit@3.20.2(magicast@0.3.5))(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2)): + dependencies: + ansis: 4.2.0 + debug: 4.4.3 + error-stack-parser-es: 1.0.5 + ohash: 2.0.11 + open: 10.2.0 + perfect-debounce: 2.0.0 + sirv: 3.0.2 + unplugin-utils: 0.3.1 + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + vite-dev-rpc: 1.1.0(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2)) + optionalDependencies: + '@nuxt/kit': 3.20.2(magicast@0.3.5) transitivePeerDependencies: - - bufferutil - supports-color - - utf-8-validate - web3-bzz@1.10.4(bufferutil@4.1.0)(utf-8-validate@5.0.10): + vite-plugin-vue-tracer@1.2.0(vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2))(vue@3.5.26(typescript@5.9.3)): dependencies: - '@types/node': 12.20.55 - got: 12.1.0 - swarm-js: 0.1.42(bufferutil@4.1.0)(utf-8-validate@5.0.10) - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate + estree-walker: 3.0.3 + exsolve: 1.0.8 + magic-string: 0.30.21 + pathe: 2.0.3 + source-map-js: 1.2.1 + vite: 7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2) + vue: 3.5.26(typescript@5.9.3) - web3-bzz@1.10.4(bufferutil@4.1.0)(utf-8-validate@6.0.3): + vite@5.4.21(@types/node@24.0.1)(lightningcss@1.30.2)(terser@5.44.1): dependencies: - '@types/node': 12.20.55 - got: 12.1.0 - swarm-js: 0.1.42(bufferutil@4.1.0)(utf-8-validate@6.0.3) - transitivePeerDependencies: - - bufferutil - - supports-color - - utf-8-validate + esbuild: 0.21.5 + postcss: 8.5.6 + rollup: 4.54.0 + optionalDependencies: + '@types/node': 24.0.1 + fsevents: 2.3.3 + lightningcss: 1.30.2 + terser: 5.44.1 - web3-core-helpers@1.10.4: + vite@7.3.0(@types/node@24.0.1)(jiti@2.6.1)(lightningcss@1.30.2)(terser@5.44.1)(tsx@4.19.2)(yaml@2.8.2): dependencies: - web3-eth-iban: 1.10.4 - web3-utils: 1.10.4 + esbuild: 0.27.2 + fdir: 6.5.0(picomatch@4.0.3) + picomatch: 4.0.3 + postcss: 8.5.6 + rollup: 4.54.0 + tinyglobby: 0.2.15 + optionalDependencies: + '@types/node': 24.0.1 + fsevents: 2.3.3 + jiti: 2.6.1 + lightningcss: 1.30.2 + terser: 5.44.1 + tsx: 4.19.2 + yaml: 2.8.2 + + vitepress@1.5.0(@algolia/client-search@5.12.0)(@types/node@24.0.1)(@types/react@18.3.1)(change-case@5.4.4)(fuse.js@7.1.0)(idb-keyval@6.2.1)(jwt-decode@4.0.0)(lightningcss@1.30.2)(postcss@8.5.6)(qrcode@1.5.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(terser@5.44.1)(typescript@5.9.3): + dependencies: + '@docsearch/css': 3.6.3 + '@docsearch/js': 3.6.3(@algolia/client-search@5.12.0)(@types/react@18.3.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@iconify-json/simple-icons': 1.2.10 + '@shikijs/core': 1.22.2 + '@shikijs/transformers': 1.22.2 + '@shikijs/types': 1.22.2 + '@types/markdown-it': 14.1.2 + '@vitejs/plugin-vue': 5.1.4(vite@5.4.21(@types/node@24.0.1)(lightningcss@1.30.2)(terser@5.44.1))(vue@3.5.12(typescript@5.9.3)) + '@vue/devtools-api': 7.6.2 + '@vue/shared': 3.5.12 + '@vueuse/core': 11.2.0(vue@3.5.12(typescript@5.9.3)) + '@vueuse/integrations': 11.2.0(change-case@5.4.4)(focus-trap@7.6.0)(fuse.js@7.1.0)(idb-keyval@6.2.1)(jwt-decode@4.0.0)(qrcode@1.5.3)(vue@3.5.12(typescript@5.9.3)) + focus-trap: 7.6.0 + mark.js: 8.11.1 + minisearch: 7.1.0 + shiki: 1.22.2 + vite: 5.4.21(@types/node@24.0.1)(lightningcss@1.30.2)(terser@5.44.1) + vue: 3.5.12(typescript@5.9.3) + optionalDependencies: + postcss: 8.5.6 + transitivePeerDependencies: + - '@algolia/client-search' + - '@types/node' + - '@types/react' + - '@vue/composition-api' + - async-validator + - axios + - change-case + - drauu + - fuse.js + - idb-keyval + - jwt-decode + - less + - lightningcss + - nprogress + - qrcode + - react + - react-dom + - sass + - sass-embedded + - search-insights + - sortablejs + - stylus + - sugarss + - terser + - typescript + - universal-cookie + + vitest@2.1.9(@edge-runtime/vm@3.2.0)(@types/node@24.0.1)(happy-dom@20.0.2)(lightningcss@1.30.2)(msw@2.4.9(typescript@5.8.3))(terser@5.44.1): + dependencies: + '@vitest/expect': 2.1.9 + '@vitest/mocker': 2.1.9(msw@2.4.9(typescript@5.8.3))(vite@5.4.21(@types/node@24.0.1)(lightningcss@1.30.2)(terser@5.44.1)) + '@vitest/pretty-format': 2.1.9 + '@vitest/runner': 2.1.9 + '@vitest/snapshot': 2.1.9 + '@vitest/spy': 2.1.9 + '@vitest/utils': 2.1.9 + chai: 5.2.0 + debug: 4.4.1 + expect-type: 1.2.1 + magic-string: 0.30.17 + pathe: 1.1.2 + std-env: 3.9.0 + tinybench: 2.9.0 + tinyexec: 0.3.2 + tinypool: 1.0.2 + tinyrainbow: 1.2.0 + vite: 5.4.21(@types/node@24.0.1)(lightningcss@1.30.2)(terser@5.44.1) + vite-node: 2.1.9(@types/node@24.0.1)(lightningcss@1.30.2)(terser@5.44.1) + why-is-node-running: 2.3.0 + optionalDependencies: + '@edge-runtime/vm': 3.2.0 + '@types/node': 24.0.1 + happy-dom: 20.0.2 + transitivePeerDependencies: + - less + - lightningcss + - msw + - sass + - sass-embedded + - stylus + - sugarss + - supports-color + - terser - web3-core-method@1.10.4: - dependencies: - '@ethersproject/transactions': 5.8.0 - web3-core-helpers: 1.10.4 - web3-core-promievent: 1.10.4 - web3-core-subscriptions: 1.10.4 - web3-utils: 1.10.4 + vscode-uri@3.1.0: {} - web3-core-promievent@1.10.4: + vue-bundle-renderer@2.2.0: dependencies: - eventemitter3: 4.0.4 + ufo: 1.6.1 - web3-core-requestmanager@1.10.4(encoding@0.1.13): - dependencies: - util: 0.12.5 - web3-core-helpers: 1.10.4 - web3-providers-http: 1.10.4(encoding@0.1.13) - web3-providers-ipc: 1.10.4 - web3-providers-ws: 1.10.4 - transitivePeerDependencies: - - encoding - - supports-color + vue-component-type-helpers@2.0.16: {} - web3-core-subscriptions@1.10.4: + vue-demi@0.14.10(vue@3.4.27(typescript@5.9.3)): dependencies: - eventemitter3: 4.0.4 - web3-core-helpers: 1.10.4 + vue: 3.4.27(typescript@5.9.3) - web3-core@1.10.4(encoding@0.1.13): + vue-demi@0.14.10(vue@3.5.12(typescript@5.9.3)): dependencies: - '@types/bn.js': 5.2.0 - '@types/node': 12.20.55 - bignumber.js: 9.3.1 - web3-core-helpers: 1.10.4 - web3-core-method: 1.10.4 - web3-core-requestmanager: 1.10.4(encoding@0.1.13) - web3-utils: 1.10.4 - transitivePeerDependencies: - - encoding - - supports-color + vue: 3.5.12(typescript@5.9.3) - web3-eth-abi@1.10.4: - dependencies: - '@ethersproject/abi': 5.8.0 - web3-utils: 1.10.4 + vue-devtools-stub@0.1.0: {} - web3-eth-accounts@1.10.4(encoding@0.1.13): + vue-resize@2.0.0-alpha.1(vue@3.5.12(typescript@5.9.3)): dependencies: - '@ethereumjs/common': 2.6.5 - '@ethereumjs/tx': 3.5.2 - '@ethereumjs/util': 8.1.0 - eth-lib: 0.2.8 - scrypt-js: 3.0.1 - uuid: 9.0.1 - web3-core: 1.10.4(encoding@0.1.13) - web3-core-helpers: 1.10.4 - web3-core-method: 1.10.4 - web3-utils: 1.10.4 - transitivePeerDependencies: - - encoding - - supports-color + vue: 3.5.12(typescript@5.9.3) - web3-eth-contract@1.10.4(encoding@0.1.13): + vue-router@4.3.2(vue@3.4.27(typescript@5.9.3)): dependencies: - '@types/bn.js': 5.2.0 - web3-core: 1.10.4(encoding@0.1.13) - web3-core-helpers: 1.10.4 - web3-core-method: 1.10.4 - web3-core-promievent: 1.10.4 - web3-core-subscriptions: 1.10.4 - web3-eth-abi: 1.10.4 - web3-utils: 1.10.4 - transitivePeerDependencies: - - encoding - - supports-color + '@vue/devtools-api': 6.6.1 + vue: 3.4.27(typescript@5.9.3) - web3-eth-ens@1.10.4(encoding@0.1.13): + vue-router@4.6.4(vue@3.5.26(typescript@5.8.3)): dependencies: - content-hash: 2.5.2 - eth-ens-namehash: 2.0.8 - web3-core: 1.10.4(encoding@0.1.13) - web3-core-helpers: 1.10.4 - web3-core-promievent: 1.10.4 - web3-eth-abi: 1.10.4 - web3-eth-contract: 1.10.4(encoding@0.1.13) - web3-utils: 1.10.4 - transitivePeerDependencies: - - encoding - - supports-color + '@vue/devtools-api': 6.6.4 + vue: 3.5.26(typescript@5.8.3) + optional: true - web3-eth-iban@1.10.4: + vue-router@4.6.4(vue@3.5.26(typescript@5.9.3)): dependencies: - bn.js: 5.2.3 - web3-utils: 1.10.4 + '@vue/devtools-api': 6.6.4 + vue: 3.5.26(typescript@5.9.3) - web3-eth-personal@1.10.4(encoding@0.1.13): + vue-template-compiler@2.7.16: dependencies: - '@types/node': 12.20.55 - web3-core: 1.10.4(encoding@0.1.13) - web3-core-helpers: 1.10.4 - web3-core-method: 1.10.4 - web3-net: 1.10.4(encoding@0.1.13) - web3-utils: 1.10.4 - transitivePeerDependencies: - - encoding - - supports-color - - web3-eth@1.10.4(encoding@0.1.13): - dependencies: - web3-core: 1.10.4(encoding@0.1.13) - web3-core-helpers: 1.10.4 - web3-core-method: 1.10.4 - web3-core-subscriptions: 1.10.4 - web3-eth-abi: 1.10.4 - web3-eth-accounts: 1.10.4(encoding@0.1.13) - web3-eth-contract: 1.10.4(encoding@0.1.13) - web3-eth-ens: 1.10.4(encoding@0.1.13) - web3-eth-iban: 1.10.4 - web3-eth-personal: 1.10.4(encoding@0.1.13) - web3-net: 1.10.4(encoding@0.1.13) - web3-utils: 1.10.4 - transitivePeerDependencies: - - encoding - - supports-color + de-indent: 1.0.2 + he: 1.2.0 - web3-net@1.10.4(encoding@0.1.13): + vue-tsc@2.0.16(typescript@5.9.3): dependencies: - web3-core: 1.10.4(encoding@0.1.13) - web3-core-method: 1.10.4 - web3-utils: 1.10.4 - transitivePeerDependencies: - - encoding - - supports-color + '@volar/typescript': 2.2.1 + '@vue/language-core': 2.0.16(typescript@5.9.3) + semver: 7.5.4 + typescript: 5.9.3 - web3-provider-engine@16.0.8(bufferutil@4.0.7)(encoding@0.1.13)(utf-8-validate@6.0.3): + vue@3.4.27(typescript@5.9.3): dependencies: - '@cypress/request': 3.0.10 - '@ethereumjs/tx': 3.5.2 - '@metamask/eth-json-rpc-infura': 6.0.0(encoding@0.1.13) - '@metamask/eth-sig-util': 4.0.1 - async: 3.2.6 - backoff: 2.5.0 - clone: 2.1.2 - eth-block-tracker: 5.0.1 - eth-json-rpc-filters: 5.0.0 - eth-json-rpc-middleware: 8.1.0(encoding@0.1.13) - eth-rpc-errors: 4.0.3 - ethereumjs-block: 2.2.2 - ethereumjs-util: 7.1.5 - ethereumjs-vm: 2.6.0 - json-stable-stringify: 1.3.0 - promise-to-callback: 1.0.0 - readable-stream: 2.3.8 - semaphore: 1.1.0 - ws: 7.5.10(bufferutil@4.0.7)(utf-8-validate@6.0.3) - xhr: 2.6.0 - xtend: 4.0.2 - transitivePeerDependencies: - - bufferutil - - encoding - - utf-8-validate + '@vue/compiler-dom': 3.4.27 + '@vue/compiler-sfc': 3.4.27 + '@vue/runtime-dom': 3.4.27 + '@vue/server-renderer': 3.4.27(vue@3.4.27(typescript@5.9.3)) + '@vue/shared': 3.4.27 + optionalDependencies: + typescript: 5.9.3 - web3-providers-http@1.10.4(encoding@0.1.13): + vue@3.5.12(typescript@5.9.3): dependencies: - abortcontroller-polyfill: 1.7.8 - cross-fetch: 4.1.0(encoding@0.1.13) - es6-promise: 4.2.8 - web3-core-helpers: 1.10.4 - transitivePeerDependencies: - - encoding + '@vue/compiler-dom': 3.5.12 + '@vue/compiler-sfc': 3.5.12 + '@vue/runtime-dom': 3.5.12 + '@vue/server-renderer': 3.5.12(vue@3.5.12(typescript@5.9.3)) + '@vue/shared': 3.5.12 + optionalDependencies: + typescript: 5.9.3 - web3-providers-ipc@1.10.4: + vue@3.5.26(typescript@5.8.3): dependencies: - oboe: 2.1.5 - web3-core-helpers: 1.10.4 + '@vue/compiler-dom': 3.5.26 + '@vue/compiler-sfc': 3.5.26 + '@vue/runtime-dom': 3.5.26 + '@vue/server-renderer': 3.5.26(vue@3.5.26(typescript@5.8.3)) + '@vue/shared': 3.5.26 + optionalDependencies: + typescript: 5.8.3 + optional: true - web3-providers-ws@1.10.4: + vue@3.5.26(typescript@5.9.3): dependencies: - eventemitter3: 4.0.4 - web3-core-helpers: 1.10.4 - websocket: 1.0.35 - transitivePeerDependencies: - - supports-color + '@vue/compiler-dom': 3.5.26 + '@vue/compiler-sfc': 3.5.26 + '@vue/runtime-dom': 3.5.26 + '@vue/server-renderer': 3.5.26(vue@3.5.26(typescript@5.9.3)) + '@vue/shared': 3.5.26 + optionalDependencies: + typescript: 5.9.3 - web3-shh@1.10.4(encoding@0.1.13): + wcwidth@1.0.1: dependencies: - web3-core: 1.10.4(encoding@0.1.13) - web3-core-method: 1.10.4 - web3-core-subscriptions: 1.10.4 - web3-net: 1.10.4(encoding@0.1.13) - transitivePeerDependencies: - - encoding - - supports-color + defaults: 1.0.4 + optional: true - web3-utils@1.10.4: - dependencies: - '@ethereumjs/util': 8.1.0 - bn.js: 5.2.3 - ethereum-bloom-filters: 1.2.0 - ethereum-cryptography: 2.2.1 - ethjs-unit: 0.1.6 - number-to-bn: 1.7.0 - randombytes: 2.1.0 - utf8: 3.0.0 + web-vitals@0.2.4: {} - web3@1.10.4(bufferutil@4.0.7)(encoding@0.1.13)(utf-8-validate@6.0.3): - dependencies: - web3-bzz: 1.10.4(bufferutil@4.0.7)(utf-8-validate@6.0.3) - web3-core: 1.10.4(encoding@0.1.13) - web3-eth: 1.10.4(encoding@0.1.13) - web3-eth-personal: 1.10.4(encoding@0.1.13) - web3-net: 1.10.4(encoding@0.1.13) - web3-shh: 1.10.4(encoding@0.1.13) - web3-utils: 1.10.4 - transitivePeerDependencies: - - bufferutil - - encoding - - supports-color - - utf-8-validate + webextension-polyfill@0.10.0: {} - web3@1.10.4(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@5.0.10): - dependencies: - web3-bzz: 1.10.4(bufferutil@4.1.0)(utf-8-validate@5.0.10) - web3-core: 1.10.4(encoding@0.1.13) - web3-eth: 1.10.4(encoding@0.1.13) - web3-eth-personal: 1.10.4(encoding@0.1.13) - web3-net: 1.10.4(encoding@0.1.13) - web3-shh: 1.10.4(encoding@0.1.13) - web3-utils: 1.10.4 - transitivePeerDependencies: - - bufferutil - - encoding - - supports-color - - utf-8-validate + webidl-conversions@3.0.1: {} - web3@1.10.4(bufferutil@4.1.0)(encoding@0.1.13)(utf-8-validate@6.0.3): + webpack-bundle-analyzer@4.10.1(bufferutil@4.0.8)(utf-8-validate@6.0.5): dependencies: - web3-bzz: 1.10.4(bufferutil@4.1.0)(utf-8-validate@6.0.3) - web3-core: 1.10.4(encoding@0.1.13) - web3-eth: 1.10.4(encoding@0.1.13) - web3-eth-personal: 1.10.4(encoding@0.1.13) - web3-net: 1.10.4(encoding@0.1.13) - web3-shh: 1.10.4(encoding@0.1.13) - web3-utils: 1.10.4 + '@discoveryjs/json-ext': 0.5.7 + acorn: 8.15.0 + acorn-walk: 8.3.4 + commander: 7.2.0 + debounce: 1.2.1 + escape-string-regexp: 4.0.0 + gzip-size: 6.0.0 + html-escaper: 2.0.2 + is-plain-object: 5.0.0 + opener: 1.5.2 + picocolors: 1.1.1 + sirv: 2.0.4 + ws: 7.5.10(bufferutil@4.0.8)(utf-8-validate@6.0.5) transitivePeerDependencies: - bufferutil - - encoding - - supports-color - utf-8-validate - webextension-polyfill@0.10.0: {} - - webidl-conversions@3.0.1: {} - - webidl-conversions@4.0.2: {} + webpack-sources@3.2.3: {} - webidl-conversions@6.1.0: {} + webpack-virtual-modules@0.6.1: {} - websocket@1.0.35: - dependencies: - bufferutil: 4.1.0 - debug: 2.6.9 - es5-ext: 0.10.64 - typedarray-to-buffer: 3.1.5 - utf-8-validate: 5.0.10 - yaeti: 0.0.6 - transitivePeerDependencies: - - supports-color + webpack-virtual-modules@0.6.2: {} whatwg-mimetype@3.0.0: {} @@ -19558,46 +24191,7 @@ snapshots: tr46: 0.0.3 webidl-conversions: 3.0.1 - whatwg-url@8.7.0: - dependencies: - lodash: 4.18.1 - tr46: 2.1.0 - webidl-conversions: 6.1.0 - - which-boxed-primitive@1.1.1: - dependencies: - is-bigint: 1.1.0 - is-boolean-object: 1.2.2 - is-number-object: 1.1.1 - is-string: 1.1.1 - is-symbol: 1.1.1 - - which-builtin-type@1.2.1: - dependencies: - call-bound: 1.0.4 - function.prototype.name: 1.1.8 - has-tostringtag: 1.0.2 - is-async-function: 2.1.1 - is-date-object: 1.1.0 - is-finalizationregistry: 1.1.1 - is-generator-function: 1.1.2 - is-regex: 1.2.1 - is-weakref: 1.1.1 - isarray: 2.0.5 - which-boxed-primitive: 1.1.1 - which-collection: 1.0.2 - which-typed-array: 1.1.20 - - which-collection@1.0.2: - dependencies: - is-map: 2.0.3 - is-set: 2.0.3 - is-weakmap: 2.0.2 - is-weakset: 2.0.4 - - which-module@1.0.0: {} - - which-module@2.0.1: {} + which-module@2.0.0: {} which-typed-array@1.1.19: dependencies: @@ -19609,16 +24203,6 @@ snapshots: gopd: 1.2.0 has-tostringtag: 1.0.2 - which-typed-array@1.1.20: - dependencies: - available-typed-arrays: 1.0.7 - call-bind: 1.0.9 - call-bound: 1.0.4 - for-each: 0.3.5 - get-proto: 1.0.1 - gopd: 1.2.0 - has-tostringtag: 1.0.2 - which@1.3.1: dependencies: isexe: 2.0.0 @@ -19627,6 +24211,10 @@ snapshots: dependencies: isexe: 2.0.0 + which@5.0.0: + dependencies: + isexe: 3.1.1 + why-is-node-running@2.3.0: dependencies: siginfo: 2.0.0 @@ -19636,23 +24224,7 @@ snapshots: dependencies: string-width: 4.2.3 - window-size@0.2.0: {} - - word-wrap@1.2.5: {} - - wordwrap@1.0.0: {} - - wordwrapjs@4.0.1: - dependencies: - reduce-flatten: 2.0.0 - typical: 5.2.0 - - workerpool@6.5.1: {} - - wrap-ansi@2.1.0: - dependencies: - string-width: 1.0.2 - strip-ansi: 3.0.1 + workerpool@6.2.1: {} wrap-ansi@6.2.0: dependencies: @@ -19668,109 +24240,88 @@ snapshots: wrap-ansi@8.1.0: dependencies: - ansi-styles: 6.2.3 + ansi-styles: 6.2.1 string-width: 5.1.2 - strip-ansi: 7.2.0 - - wrap-ansi@9.0.2: - dependencies: - ansi-styles: 6.2.3 - string-width: 7.2.0 strip-ansi: 7.1.2 wrappy@1.0.2: {} - write-file-atomic@3.0.3: - dependencies: - imurmurhash: 0.1.4 - is-typedarray: 1.0.0 - signal-exit: 3.0.7 - typedarray-to-buffer: 3.1.5 - - ws@7.5.10(bufferutil@4.0.7)(utf-8-validate@6.0.3): + ws@7.5.10(bufferutil@4.0.8)(utf-8-validate@6.0.5): optionalDependencies: - bufferutil: 4.0.7 - utf-8-validate: 6.0.3 + bufferutil: 4.0.8 + utf-8-validate: 6.0.5 ws@7.5.10(bufferutil@4.1.0)(utf-8-validate@5.0.10): optionalDependencies: bufferutil: 4.1.0 utf-8-validate: 5.0.10 - ws@8.17.1(bufferutil@4.1.0)(utf-8-validate@5.0.10): + ws@7.5.9(bufferutil@4.1.0)(utf-8-validate@5.0.10): optionalDependencies: bufferutil: 4.1.0 utf-8-validate: 5.0.10 - ws@8.18.0(bufferutil@4.0.7)(utf-8-validate@6.0.3): + ws@8.13.0(bufferutil@4.0.8)(utf-8-validate@6.0.5): optionalDependencies: - bufferutil: 4.0.7 - utf-8-validate: 6.0.3 + bufferutil: 4.0.8 + utf-8-validate: 6.0.5 - ws@8.18.0(bufferutil@4.1.0)(utf-8-validate@5.0.10): + ws@8.13.0(bufferutil@4.1.0)(utf-8-validate@6.0.5): + optionalDependencies: + bufferutil: 4.1.0 + utf-8-validate: 6.0.5 + + ws@8.17.1(bufferutil@4.1.0)(utf-8-validate@5.0.10): optionalDependencies: bufferutil: 4.1.0 utf-8-validate: 5.0.10 - ws@8.18.0(bufferutil@4.1.0)(utf-8-validate@6.0.3): + ws@8.17.1(bufferutil@4.1.0)(utf-8-validate@6.0.5): optionalDependencies: bufferutil: 4.1.0 - utf-8-validate: 6.0.3 + utf-8-validate: 6.0.5 - ws@8.18.3(bufferutil@4.1.0)(utf-8-validate@6.0.3): + ws@8.18.0(bufferutil@4.1.0)(utf-8-validate@5.0.10): optionalDependencies: bufferutil: 4.1.0 - utf-8-validate: 6.0.3 + utf-8-validate: 5.0.10 - ws@8.20.0(bufferutil@4.0.7)(utf-8-validate@6.0.3): + ws@8.18.2(bufferutil@4.1.0)(utf-8-validate@6.0.5): optionalDependencies: - bufferutil: 4.0.7 - utf-8-validate: 6.0.3 + bufferutil: 4.1.0 + utf-8-validate: 6.0.5 - ws@8.20.0(bufferutil@4.1.0)(utf-8-validate@5.0.10): + ws@8.18.3(bufferutil@4.1.0)(utf-8-validate@5.0.10): optionalDependencies: bufferutil: 4.1.0 utf-8-validate: 5.0.10 - ws@8.20.0(bufferutil@4.1.0)(utf-8-validate@6.0.3): + ws@8.18.3(bufferutil@4.1.0)(utf-8-validate@6.0.5): optionalDependencies: bufferutil: 4.1.0 - utf-8-validate: 6.0.3 + utf-8-validate: 6.0.5 - xhr-request-promise@0.1.3: + wsl-utils@0.1.0: dependencies: - xhr-request: 1.1.0 + is-wsl: 3.1.0 - xhr-request@1.1.0: + xdg-app-paths@5.1.0: dependencies: - buffer-to-arraybuffer: 0.0.5 - object-assign: 4.1.1 - query-string: 5.1.1 - simple-get: 2.8.2 - timed-out: 4.0.1 - url-set-query: 1.0.0 - xhr: 2.6.0 + xdg-portable: 7.3.0 - xhr@2.6.0: + xdg-portable@7.3.0: dependencies: - global: 4.4.0 - is-function: 1.0.2 - parse-headers: 2.0.6 - xtend: 4.0.2 + os-paths: 4.4.0 - xtend@2.1.2: - dependencies: - object-keys: 0.4.0 + xmlhttprequest-ssl@2.1.2: {} xtend@4.0.2: {} - y18n@3.2.2: {} - y18n@4.0.3: {} y18n@5.0.8: {} - yaeti@0.0.6: {} + yallist@2.1.2: {} yallist@3.1.1: {} @@ -19778,17 +24329,17 @@ snapshots: yallist@5.0.0: {} + yaml@2.8.2: {} + yargs-parser@18.1.3: dependencies: camelcase: 5.3.1 decamelize: 1.2.0 - yargs-parser@20.2.9: {} + yargs-parser@20.2.4: {} yargs-parser@21.1.1: {} - yargs-parser@22.0.0: {} - yargs-unparser@2.0.0: dependencies: camelcase: 6.3.0 @@ -19806,7 +24357,7 @@ snapshots: require-main-filename: 2.0.0 set-blocking: 2.0.0 string-width: 4.2.3 - which-module: 2.0.1 + which-module: 2.0.0 y18n: 4.0.3 yargs-parser: 18.1.3 @@ -19818,7 +24369,7 @@ snapshots: require-directory: 2.1.1 string-width: 4.2.3 y18n: 5.0.8 - yargs-parser: 20.2.9 + yargs-parser: 20.2.4 yargs@17.7.2: dependencies: @@ -19830,48 +24381,57 @@ snapshots: y18n: 5.0.8 yargs-parser: 21.1.1 - yargs@18.0.0: + yauzl-clone@1.0.4: dependencies: - cliui: 9.0.1 - escalade: 3.2.0 - get-caller-file: 2.0.5 - string-width: 7.2.0 - y18n: 5.0.8 - yargs-parser: 22.0.0 + events-intercept: 2.0.0 - yargs@4.8.1: + yauzl-promise@2.1.3: dependencies: - cliui: 3.2.0 - decamelize: 1.2.0 - get-caller-file: 1.0.3 - lodash.assign: 4.2.0 - os-locale: 1.4.0 - read-pkg-up: 1.0.1 - require-directory: 2.1.1 - require-main-filename: 1.0.1 - set-blocking: 2.0.0 - string-width: 1.0.2 - which-module: 1.0.0 - window-size: 0.2.0 - y18n: 3.2.2 - yargs-parser: 22.0.0 + yauzl: 2.10.0 + yauzl-clone: 1.0.4 - yesno@0.3.1: {} + yauzl@2.10.0: + dependencies: + buffer-crc32: 0.2.13 + fd-slicer: 1.1.0 yn@3.1.1: {} yocto-queue@0.1.0: {} - zksync-web3@0.14.4(ethers@5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10)): + yoctocolors@2.0.2: {} + + youch-core@0.3.3: + dependencies: + '@poppinss/exception': 1.2.3 + error-stack-parser-es: 1.0.5 + + youch@4.1.0-beta.13: dependencies: - ethers: 5.8.0(bufferutil@4.1.0)(utf-8-validate@5.0.10) + '@poppinss/colors': 4.1.6 + '@poppinss/dumper': 0.6.5 + '@speed-highlight/core': 1.2.12 + cookie-es: 2.0.0 + youch-core: 0.3.3 - zod-validation-error@4.0.2(zod@4.2.0): + zip-stream@6.0.1: dependencies: - zod: 4.2.0 + archiver-utils: 5.0.2 + compress-commons: 6.0.2 + readable-stream: 4.7.0 - zod@3.25.76: {} + zod-validation-error@3.2.0(zod@3.25.20): + dependencies: + zod: 3.25.20 + + zod@3.22.4: {} - zod@4.2.0: {} + zod@3.25.20: {} + + zustand@5.0.0(@types/react@18.3.27)(react@18.3.1)(use-sync-external-store@1.4.0(react@18.3.1)): + optionalDependencies: + '@types/react': 18.3.27 + react: 18.3.1 + use-sync-external-store: 1.4.0(react@18.3.1) - zstd-codec@0.1.5: {} + zwitch@2.0.4: {} diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml index f761c6831d..b1f32102e6 100644 --- a/pnpm-workspace.yaml +++ b/pnpm-workspace.yaml @@ -1,67 +1,19 @@ packages: - - extras/* - packages/* - - packages/services/* - - packages/utils/* - - packages/wallet/* - - repo/* - - test/* + - "!packages/register-tests" + - packages/cli/src/plugins/__fixtures__/hardhat + - packages/register-tests/* + - playgrounds/* + - site -onlyBuiltDependencies: - - '@parcel/watcher' - - '@prisma/engines' - - '@tailwindcss/oxide' - - bufferutil - - core-js-pure - - esbuild - - keccak - - lefthook - - prisma - - protobufjs - - secp256k1 - - sharp - - utf-8-validate - - web3 - - web3-bzz - -overrides: - 0xsequence.js.git: link:.local/share/pnpm/global/5/node_modules/https:/github.com/Dargon789/0xsequence.js.git - Rabby.git: link:.local/share/pnpm/global/5/node_modules/git@github.com:Dargon789/Rabby.git - braces@<3.0.3: '>=3.0.3' - cookie@<0.7.0: '>=0.7.0' - diff@<4.0.4: '>=4.0.4' - diff@>=5.0.0 <5.2.2: '>=5.2.2' - esbuild@<=0.24.2: '>=0.25.0' - fast-xml-parser@>=4.3.6 <=5.3.3: '>=5.3.4' - form-data@<2.5.4: '>=2.5.4' - happy-dom@<20.0.0: '>=20.0.0' - hardhat-project.git: link:.local/share/pnpm/global/5/node_modules/git@github.com:Dargon789/hardhat-project.git - hono@<4.11.7: '>=4.11.7' - http-proxy-middleware@<2.0.7: '>=2.0.7' - lodash@>=4.0.0 <=4.17.22: '>=4.17.23' - micromatch@<4.0.8: '>=4.0.8' - next@>=15.6.0-canary.0 <16.1.5: '>=16.1.5' - next@>=16.0.0-beta.0 <16.1.5: '>=16.1.5' - next@>=16.1.0-canary.0 <16.1.5: '>=16.1.5' - node-forge@<1.0.0: '>=1.0.0' - node-forge@<1.3.0: '>=1.3.0' - node-forge@<1.3.2: '>=1.3.2' - qs@<6.14.1: '>=6.14.1' - semver@<5.7.2: '>=5.7.2' - tar@<6.2.1: '>=6.2.1' - tar@<=7.5.2: '>=7.5.3' - thirdweb-dev.git: link:.local/share/pnpm/global/5/node_modules/git@github.com:Dargon789/thirdweb-dev.git - tmp@<=0.2.3: '>=0.2.4' - tough-cookie@<4.1.3: '>=4.1.3' - undici@<5.29.0: '>=5.29.0' - undici@<6.23.0: '>=6.23.0' - undici@>=4.5.0 <5.28.5: '>=5.28.5' - wallet-contracts.git: link:.local/share/pnpm/global/5/node_modules/https:/github.com/Dargon789/wallet-contracts.git - webpack-dev-middleware@<=5.3.3: '>=5.3.4' - webpack-dev-server@<=5.2.0: '>=5.2.1' - ws@>=2.1.0 <5.2.4: '>=5.2.4' - ws@>=8.0.0 <8.17.1: '>=8.17.1' - xml2js@<0.5.0: '>=0.5.0' - -publicHoistPattern: - - eslint +catalog: + "@tanstack/query-core": "5.49.1" + "@tanstack/react-query": "5.49.2" + "@tanstack/vue-query": "5.49.1" + "@testing-library/dom": "10.4.0" + "@testing-library/react": "16.0.1" + "@types/react": "18.3.1" + "@types/react-dom": "18.3.0" + react-dom: "18.3.1" + react: "18.3.1" + vue: "3.4.27" diff --git a/scripts/formatPackageJson.ts b/scripts/formatPackageJson.ts new file mode 100644 index 0000000000..a4d5a13e39 --- /dev/null +++ b/scripts/formatPackageJson.ts @@ -0,0 +1,36 @@ +import path from 'node:path' + +// Generates package.json files to be published to NPM with only the necessary fields. + +console.log('Formatting package.json files.') + +// Get all package.json files +const packagePaths = await Array.fromAsync( + new Bun.Glob('packages/**/package.json').scan(), +) + +let count = 0 +for (const packagePath of packagePaths) { + type Package = Record & { + name?: string | undefined + private?: boolean | undefined + } + const file = Bun.file(packagePath) + const packageJson = (await file.json()) as Package + + // Skip private packages + if (packageJson.private) continue + + count += 1 + console.log(`${packageJson.name} — ${path.dirname(packagePath)}`) + + await Bun.write( + `${packagePath}.tmp`, + `${JSON.stringify(packageJson, undefined, 2)}\n`, + ) + + const { devDependencies: _dD, scripts: _s, ...rest } = packageJson + await Bun.write(packagePath, `${JSON.stringify(rest, undefined, 2)}\n`) +} + +console.log(`Done. Formatted ${count} ${count === 1 ? 'file' : 'files'}.`) diff --git a/scripts/generateProxyPackages.ts b/scripts/generateProxyPackages.ts new file mode 100644 index 0000000000..a53a7167b3 --- /dev/null +++ b/scripts/generateProxyPackages.ts @@ -0,0 +1,57 @@ +import fs from 'node:fs/promises' +import path from 'node:path' + +// Generates proxy packages for package.json#exports. + +console.log('Generating proxy packages.') + +// Get all package.json files +const packagePaths = await Array.fromAsync( + new Bun.Glob('packages/**/package.json').scan(), +) + +let count = 0 +for (const packagePath of packagePaths) { + type Package = Record & { + name?: string | undefined + private?: boolean | undefined + exports?: + | Record + | undefined + } + const file = Bun.file(packagePath) + const packageJson = (await file.json()) as Package + + // Skip private packages + if (packageJson.private) continue + if (!packageJson.exports) continue + + count += 1 + console.log(`${packageJson.name} — ${path.dirname(packagePath)}`) + + const dir = path.resolve(path.dirname(packagePath)) + + for (const [key, exports] of Object.entries(packageJson.exports)) { + // Skip `package.json` export + if (/package\.json$/.test(key)) continue + if (key === '.') continue + if (typeof exports === 'string') continue + if (!exports.default) continue + + const proxyDir = path.resolve(dir, key) + await fs.mkdir(proxyDir, { recursive: true }) + + const types = path.relative(key, exports.types) + const main = path.relative(key, exports.default) + await Bun.write( + `${proxyDir}/package.json`, + `${JSON.stringify({ type: 'module', types, main }, undefined, 2)}\n`, + ) + } +} + +console.log( + `Done. Generated proxy packages for ${count} ${ + count === 1 ? 'package' : 'packages' + }.`, +) diff --git a/scripts/preconstruct.ts b/scripts/preconstruct.ts new file mode 100644 index 0000000000..9580924f1f --- /dev/null +++ b/scripts/preconstruct.ts @@ -0,0 +1,87 @@ +import fs from 'node:fs/promises' +import path from 'node:path' + +// Symlinks package sources to dist for local development + +console.log('Setting up packages for development.') + +// Get all package.json files +const packagePaths = await Array.fromAsync( + new Bun.Glob('**/package.json').scan(), +) + +let count = 0 +for (const packagePath of packagePaths) { + type Package = { + bin?: Record | undefined + exports?: + | Record + | undefined + name?: string | undefined + private?: boolean | undefined + } + const file = Bun.file(packagePath) + const packageJson = (await file.json()) as Package + + // Skip private packages + if (packageJson.private && packageJson.name !== '@wagmi/test') continue + if (!packageJson.exports) continue + if (packageJson.bin) continue + + count += 1 + console.log(`${packageJson.name} — ${path.dirname(packagePath)}`) + + const dir = path.resolve(path.dirname(packagePath)) + + // Empty dist directory + const dist = path.resolve(dir, 'dist') + let files: string[] = [] + try { + files = await fs.readdir(dist) + } catch { + await fs.mkdir(dist) + } + + const promises = [] + for (const file of files) { + promises.push( + fs.rm(path.join(dist, file), { recursive: true, force: true }), + ) + } + await Promise.all(promises) + + // Link exports to dist locations + for (const [key, exports] of Object.entries(packageJson.exports)) { + // Skip `package.json` exports + if (/package\.json$/.test(key)) continue + if (typeof exports === 'string') continue + + // Link exports to dist locations + for (const [type, value] of Object.entries(exports) as [ + type: 'types' | 'default', + value: string, + ][]) { + const srcDir = path.resolve( + dir, + path + .dirname(value) + .replace(`dist/${type === 'default' ? 'esm' : type}`, 'src'), + ) + let srcFileName: string + if (key === '.') srcFileName = 'index.ts' + else srcFileName = path.basename(`${key}.ts`) + const srcFilePath = path.resolve(srcDir, srcFileName) + + const distDir = path.resolve(dir, path.dirname(value)) + const distFileName = path.basename(value) + const distFilePath = path.resolve(distDir, distFileName) + + await fs.mkdir(distDir, { recursive: true }) + + // Symlink src to dist file + await fs.symlink(srcFilePath, distFilePath, 'file') + } + } +} + +console.log(`Done. Set up ${count} ${count === 1 ? 'package' : 'packages'}.`) diff --git a/scripts/restorePackageJson.ts b/scripts/restorePackageJson.ts new file mode 100644 index 0000000000..c0019a340f --- /dev/null +++ b/scripts/restorePackageJson.ts @@ -0,0 +1,29 @@ +import fs from 'node:fs/promises' +import path from 'node:path' + +// Restores package.json files from package.json.tmp files. + +console.log('Restoring package.json files.') + +// Get all package.json files +const packagePaths = await Array.fromAsync( + new Bun.Glob('packages/**/package.json.tmp').scan(), +) + +let count = 0 +for (const packagePath of packagePaths) { + type Package = { name?: string | undefined } & Record + const file = Bun.file(packagePath) + const packageJson = (await file.json()) as Package + + count += 1 + console.log(`${packageJson.name} — ${path.dirname(packagePath)}`) + + await Bun.write( + packagePath.replace('.tmp', ''), + `${JSON.stringify(packageJson, undefined, 2)}\n`, + ) + await fs.rm(packagePath) +} + +console.log(`Done. Restored ${count} ${count === 1 ? 'file' : 'files'}.`) diff --git a/scripts/updateBlockExplorerPluginChains.ts b/scripts/updateBlockExplorerPluginChains.ts new file mode 100644 index 0000000000..d61790fd36 --- /dev/null +++ b/scripts/updateBlockExplorerPluginChains.ts @@ -0,0 +1,53 @@ +// Fetches supported chains for Etherscan and Sourcify + +console.log('Updating block explorer plugins chains.') + +let count = 0 +{ + console.log('etherscan - https://api.etherscan.io/v2/chainlist') + const res = (await fetch('https://api.etherscan.io/v2/chainlist').then( + (res) => res.json(), + )) as { + totalcount: number + result: { + chainname: string + chainid: number + blockexplorer: string + apiurl: string + status: 0 | 1 + }[] + } + + let content = 'type ChainId =\n' + for (const chain of res.result) + content += ` | ${chain.chainid} // ${chain.chainname}\n` + + await writeContent('./packages/cli/src/plugins/etherscan.ts', content) + count += 1 +} + +{ + console.log('sourcify - https://sourcify.dev/server/chains') + const res = (await fetch('https://sourcify.dev/server/chains').then((res) => + res.json(), + )) as { + name: string + chainId: number + }[] + + let content = 'type ChainId =\n' + for (const chain of res) content += ` | ${chain.chainId} // ${chain.name}\n` + + await writeContent('./packages/cli/src/plugins/sourcify.ts', content) + count += 1 +} + +console.log(`Done. Updated chains for ${count} plugins.`) + +async function writeContent(pluginPath: string, content: string) { + const file = Bun.file(pluginPath) + const text = await file + .text() + .then((text) => text.replace(/type ChainId =[\s\S]*$/, content)) + await Bun.write(pluginPath, text) +} diff --git a/scripts/updateVersion.ts b/scripts/updateVersion.ts new file mode 100644 index 0000000000..4ec949cc10 --- /dev/null +++ b/scripts/updateVersion.ts @@ -0,0 +1,43 @@ +import path from 'node:path' + +// Updates package version.ts files (so you can use the version in code without importing package.json). + +console.log('Updating version files.') + +// Get all package.json files +const packagePaths = await Array.fromAsync( + new Bun.Glob('**/package.json').scan(), +) + +let count = 0 +for (const packagePath of packagePaths) { + type Package = { + name?: string | undefined + private?: boolean | undefined + version?: string | undefined + } + const file = Bun.file(packagePath) + const packageJson = (await file.json()) as Package + + // Skip private packages + if (packageJson.private) continue + + count += 1 + console.log(`${packageJson.name} — ${packageJson.version}`) + + const versionFilePath = path.resolve( + path.dirname(packagePath), + 'src', + 'version.ts', + ) + await Bun.write( + versionFilePath, + `export const version = '${packageJson.version}'\n`, + ) +} + +console.log( + `Done. Updated version file for ${count} ${ + count === 1 ? 'package' : 'packages' + }.`, +) diff --git a/scripts/updateViemVersion.ts b/scripts/updateViemVersion.ts new file mode 100644 index 0000000000..5731394bad --- /dev/null +++ b/scripts/updateViemVersion.ts @@ -0,0 +1,44 @@ +// Updates viem version in Vitest snapshots, etc. + +console.log('Updating Viem version.') + +const file = Bun.file('package.json') +const packageJson = await file.json() +const viemVersion = packageJson.devDependencies.viem + +// Update Vitest snapshots +// Get all *.test.ts files +const testPaths = await Array.fromAsync( + new Bun.Glob('packages/**/*.test.ts').scan(), +) + +let count = 0 +for (const testPath of testPaths) { + const file = Bun.file(testPath) + const testFile = await file.text() + + // Skip files that don't contain viem version + if (!testFile.includes('Version: viem@')) continue + // Skip files that contain current version + if (testFile.includes(`Version: viem@${viemVersion}`)) continue + + console.log(testPath) + const updatedTestFile = testFile.replace( + /Version: viem@[A-Za-z0-9\-\.]+/g, + `Version: viem@${viemVersion}`, + ) + await Bun.write(testPath, updatedTestFile) + + count += 1 +} + +// // Update package.json#pnpm.overrides.viem +// if (packageJson.pnpm?.overrides?.viem !== viemVersion) { +// const path = 'package.json' +// console.log(path) +// packageJson.pnpm.overrides.viem = viemVersion +// await Bun.write(path, `${JSON.stringify(packageJson, undefined, 2)}\n`) +// count += 1 +// } + +console.log(`Done. Updated ${count} ${count === 1 ? 'file' : 'files'}.`) diff --git a/site/.vitepress/config.ts b/site/.vitepress/config.ts new file mode 100644 index 0000000000..77f242cb09 --- /dev/null +++ b/site/.vitepress/config.ts @@ -0,0 +1,151 @@ +import { + defaultHoverInfoProcessor, + transformerTwoslash, +} from '@shikijs/vitepress-twoslash' +import { presetAttributify, presetIcons, presetUno } from 'unocss' +import Unocss from 'unocss/vite' +import { defineConfig } from 'vitepress' + +import { farcasterIcon } from './constants' +import { getSidebar } from './sidebar' + +// https://vitepress.dev/reference/site-config +export default defineConfig({ + cleanUrls: true, + description: 'Reactivity for Ethereum apps', + head: [ + [ + 'meta', + { + name: 'keywords', + content: 'react, ethereum, typescript, react, react hooks, open source', + }, + ], + ['link', { rel: 'icon', href: '/favicon.svg' }], + ['meta', { name: 'theme-color', content: '#646cff' }], + // Open Graph + ['meta', { property: 'og:type', content: 'website' }], + ['meta', { property: 'og:image', content: 'https://wagmi.sh/og.png' }], + ['meta', { property: 'og:url', content: 'https://wagmi.sh' }], + // Twitter + ['meta', { name: 'twitter:card', content: 'summary_large_image' }], + ['meta', { name: 'twitter:creator', content: '@wevm_dev' }], + ['meta', { name: 'twitter:image', content: 'https://wagmi.sh/og.png' }], + ['meta', { name: 'twitter:site', content: 'wagmi.sh' }], + // Fathom + [ + 'script', + { + src: 'https://cdn.usefathom.com/script.js', + 'data-site': 'QWAXSUPT', + defer: '', + }, + ], + ], + ignoreDeadLinks: false, + lang: 'en-US', + lastUpdated: true, + markdown: { + codeTransformers: [ + transformerTwoslash({ + processHoverInfo(info) { + return ( + defaultHoverInfoProcessor(info) + // Remove shiki_core namespace + .replace(/_shikijs_core[\w_]*\./g, '') + ) + }, + }), + ], + theme: { + light: 'vitesse-light', + dark: 'vitesse-dark', + }, + }, + themeConfig: { + editLink: { + pattern: 'https://github.com/wevm/wagmi/edit/main/site/:path', + text: 'Suggest changes to this page', + }, + footer: { + message: + 'Released under the MIT License.', + copyright: 'Copyright © 2022-present Weth, LLC', + }, + logo: { + light: '/logo-light.svg', + dark: '/logo-dark.svg', + alt: 'wagmi logo', + }, + nav: [ + { text: 'React', link: '/react/getting-started' }, + { text: 'Vue', link: '/vue/getting-started' }, + { text: 'Core', link: '/core/getting-started' }, + { text: 'CLI', link: '/cli/getting-started' }, + // { text: 'Examples', link: '/examples/connect-wallet' }, + { + text: 'More', + items: [ + { + text: 'Discussions ', + link: 'https://github.com/wevm/wagmi/discussions', + }, + { + text: 'Release Notes ', + link: 'https://github.com/wevm/wagmi/releases', + }, + { + text: 'Contributing ', + link: '/dev/contributing', + }, + ], + }, + ], + outline: [2, 3], + search: { + provider: 'local', + options: { + _render(src, env, md) { + const html = md.render(src, env) + if (env.frontmatter?.search === false) return '' + if (env.relativePath.startsWith('shared')) return '' + return html + }, + }, + }, + sidebar: getSidebar(), + siteTitle: false, + socialLinks: [ + { + icon: 'github', + link: 'https://github.com/wevm/wagmi', + }, + { icon: 'bluesky', link: 'https://bsky.app/profile/wevm.dev' }, + { icon: 'x', link: 'https://twitter.com/wevm_dev' }, + { icon: { svg: farcasterIcon }, link: 'https://warpcast.com/wevm' }, + { icon: 'discord', link: 'https://discord.gg/9zHPXuBpqy' }, + ], + }, + title: 'Wagmi', + vite: { + plugins: [ + Unocss({ + shortcuts: [ + [ + 'btn', + 'px-4 py-1 rounded inline-flex justify-center gap-2 text-white leading-30px children:mya !no-underline cursor-pointer disabled:cursor-default disabled:bg-gray-600 disabled:opacity-50', + ], + ], + presets: [ + presetUno({ + dark: 'media', + }), + presetAttributify(), + presetIcons({ + scale: 1.2, + }), + ], + }), + ], + }, +}) diff --git a/site/.vitepress/constants.ts b/site/.vitepress/constants.ts new file mode 100644 index 0000000000..981f8df3e1 --- /dev/null +++ b/site/.vitepress/constants.ts @@ -0,0 +1,2 @@ +export const farcasterIcon = + '' diff --git a/site/.vitepress/sidebar.ts b/site/.vitepress/sidebar.ts new file mode 100644 index 0000000000..29ea14bc52 --- /dev/null +++ b/site/.vitepress/sidebar.ts @@ -0,0 +1,1085 @@ +import type { DefaultTheme } from 'vitepress' + +export function getSidebar() { + return { + '/react': [ + { + text: 'Introduction', + items: [ + { text: 'Why Wagmi', link: '/react/why' }, + { text: 'Installation', link: '/react/installation' }, + { text: 'Getting Started', link: '/react/getting-started' }, + { text: 'TypeScript', link: '/react/typescript' }, + { text: 'Comparisons', link: '/react/comparisons' }, + ], + }, + { + text: 'Guides', + items: [ + { + text: 'TanStack Query', + link: '/react/guides/tanstack-query', + }, + { + text: 'Viem', + link: '/react/guides/viem', + }, + { + text: 'Error Handling', + link: '/react/guides/error-handling', + }, + { + text: 'Ethers.js Adapters', + link: '/react/guides/ethers', + }, + // { + // text: 'Testing', + // link: '/react/guides/testing', + // }, + { + text: 'Chain Properties', + link: '/react/guides/chain-properties', + }, + { + text: 'SSR', + link: '/react/guides/ssr', + }, + { + text: 'Connect Wallet', + link: '/react/guides/connect-wallet', + }, + { + text: 'Send Transaction', + link: '/react/guides/send-transaction', + }, + { + text: 'Read from Contract', + link: '/react/guides/read-from-contract', + }, + { + text: 'Write to Contract', + link: '/react/guides/write-to-contract', + }, + { + text: 'FAQ / Troubleshooting', + link: '/react/guides/faq', + }, + { + text: 'Migrate from v1 to v2', + link: '/react/guides/migrate-from-v1-to-v2', + }, + ], + }, + { + text: 'Configuration', + items: [ + { text: 'createConfig', link: '/react/api/createConfig' }, + { text: 'createStorage', link: '/react/api/createStorage' }, + { text: 'Chains', link: '/react/api/chains' }, + { + text: 'Connectors', + collapsed: true, + link: '/react/api/connectors', + items: [ + { + text: 'coinbaseWallet', + link: '/react/api/connectors/coinbaseWallet', + }, + { text: 'injected', link: '/react/api/connectors/injected' }, + { + text: 'metaMask', + link: '/react/api/connectors/metaMask', + }, + { + text: 'mock', + link: '/react/api/connectors/mock', + }, + { + text: 'safe', + link: '/react/api/connectors/safe', + }, + { + text: 'walletConnect', + link: '/react/api/connectors/walletConnect', + }, + ], + }, + { + text: 'Transports', + collapsed: true, + link: '/react/api/transports', + items: [ + { + text: 'custom (EIP-1193)', + link: '/react/api/transports/custom', + }, + { + text: 'fallback', + link: '/react/api/transports/fallback', + }, + { + text: 'http', + link: '/react/api/transports/http', + }, + { + text: 'unstable_connector', + link: '/react/api/transports/unstable_connector', + }, + { + text: 'webSocket', + link: '/react/api/transports/webSocket', + }, + ], + }, + { text: 'WagmiProvider', link: '/react/api/WagmiProvider' }, + ], + }, + { + text: 'Hooks', + link: '/react/api/hooks', + items: [ + { text: 'useAccount', link: '/react/api/hooks/useAccount' }, + { + text: 'useAccountEffect', + link: '/react/api/hooks/useAccountEffect', + }, + { text: 'useBalance', link: '/react/api/hooks/useBalance' }, + { + text: 'useBlockNumber', + link: '/react/api/hooks/useBlockNumber', + }, + { + text: 'useBlock', + link: '/react/api/hooks/useBlock', + }, + { + text: 'useBlockTransactionCount', + link: '/react/api/hooks/useBlockTransactionCount', + }, + { + text: 'useBytecode', + link: '/react/api/hooks/useBytecode', + }, + { text: 'useCall', link: '/react/api/hooks/useCall' }, + { + text: 'useCallsStatus', + link: '/react/api/hooks/useCallsStatus', + }, + { + text: 'useCapabilities', + link: '/react/api/hooks/useCapabilities', + }, + { text: 'useChainId', link: '/react/api/hooks/useChainId' }, + { text: 'useChains', link: '/react/api/hooks/useChains' }, + { text: 'useClient', link: '/react/api/hooks/useClient' }, + { text: 'useConfig', link: '/react/api/hooks/useConfig' }, + { text: 'useConnect', link: '/react/api/hooks/useConnect' }, + { + text: 'useConnections', + link: '/react/api/hooks/useConnections', + }, + { + text: 'useConnectorClient', + link: '/react/api/hooks/useConnectorClient', + }, + { + text: 'useConnectors', + link: '/react/api/hooks/useConnectors', + }, + { + text: 'useDeployContract', + link: '/react/api/hooks/useDeployContract', + }, + { text: 'useDisconnect', link: '/react/api/hooks/useDisconnect' }, + { text: 'useEnsAddress', link: '/react/api/hooks/useEnsAddress' }, + { text: 'useEnsAvatar', link: '/react/api/hooks/useEnsAvatar' }, + { text: 'useEnsName', link: '/react/api/hooks/useEnsName' }, + { + text: 'useEnsResolver', + link: '/react/api/hooks/useEnsResolver', + }, + { + text: 'useEnsText', + link: '/react/api/hooks/useEnsText', + }, + { + text: 'useFeeHistory', + link: '/react/api/hooks/useFeeHistory', + }, + { + text: 'useProof', + link: '/react/api/hooks/useProof', + }, + { + text: 'usePublicClient', + link: '/react/api/hooks/usePublicClient', + }, + { + text: 'useEstimateFeesPerGas', + link: '/react/api/hooks/useEstimateFeesPerGas', + }, + { + text: 'useEstimateGas', + link: '/react/api/hooks/useEstimateGas', + }, + { + text: 'useEstimateMaxPriorityFeePerGas', + link: '/react/api/hooks/useEstimateMaxPriorityFeePerGas', + }, + { + text: 'useGasPrice', + link: '/react/api/hooks/useGasPrice', + }, + { + text: 'useInfiniteReadContracts', + link: '/react/api/hooks/useInfiniteReadContracts', + }, + { + text: 'usePrepareTransactionRequest', + link: '/react/api/hooks/usePrepareTransactionRequest', + }, + { + text: 'useReadContract', + link: '/react/api/hooks/useReadContract', + }, + { + text: 'useReadContracts', + link: '/react/api/hooks/useReadContracts', + }, + { text: 'useReconnect', link: '/react/api/hooks/useReconnect' }, + { + text: 'useSendCalls', + link: '/react/api/hooks/useSendCalls', + }, + { + text: 'useSendTransaction', + link: '/react/api/hooks/useSendTransaction', + }, + { + text: 'useShowCallsStatus', + link: '/react/api/hooks/useShowCallsStatus', + }, + { + text: 'useSignMessage', + link: '/react/api/hooks/useSignMessage', + }, + { + text: 'useSignTypedData', + link: '/react/api/hooks/useSignTypedData', + }, + { + text: 'useSimulateContract', + link: '/react/api/hooks/useSimulateContract', + }, + { + text: 'useStorageAt', + link: '/react/api/hooks/useStorageAt', + }, + { + text: 'useSwitchAccount', + link: '/react/api/hooks/useSwitchAccount', + }, + { + text: 'useSwitchChain', + link: '/react/api/hooks/useSwitchChain', + }, + { + text: 'useTransaction', + link: '/react/api/hooks/useTransaction', + }, + { + text: 'useTransactionConfirmations', + link: '/react/api/hooks/useTransactionConfirmations', + }, + { + text: 'useTransactionCount', + link: '/react/api/hooks/useTransactionCount', + }, + { + text: 'useTransactionReceipt', + link: '/react/api/hooks/useTransactionReceipt', + }, + { + text: 'useToken', + link: '/react/api/hooks/useToken', + }, + { + text: 'useWaitForCallsStatus', + link: '/react/api/hooks/useWaitForCallsStatus', + }, + { + text: 'useWaitForTransactionReceipt', + link: '/react/api/hooks/useWaitForTransactionReceipt', + }, + { + text: 'useVerifyMessage', + link: '/react/api/hooks/useVerifyMessage', + }, + { + text: 'useVerifyTypedData', + link: '/react/api/hooks/useVerifyTypedData', + }, + { + text: 'useWalletClient', + link: '/react/api/hooks/useWalletClient', + }, + { + text: 'useWatchAsset', + link: '/react/api/hooks/useWatchAsset', + }, + { + text: 'useWatchBlocks', + link: '/react/api/hooks/useWatchBlocks', + }, + { + text: 'useWatchBlockNumber', + link: '/react/api/hooks/useWatchBlockNumber', + }, + { + text: 'useWatchContractEvent', + link: '/react/api/hooks/useWatchContractEvent', + }, + { + text: 'useWatchPendingTransactions', + link: '/react/api/hooks/useWatchPendingTransactions', + }, + { + text: 'useWriteContract', + link: '/react/api/hooks/useWriteContract', + }, + ], + }, + { + text: 'Miscellaneous', + items: [ + { text: 'Actions', link: '/react/api/actions' }, + { text: 'Errors', link: '/react/api/errors' }, + { + text: 'Utilities', + collapsed: true, + items: [ + { + text: 'cookieToInitialState', + link: '/react/api/utilities/cookieToInitialState', + }, + { text: 'deserialize', link: '/react/api/utilities/deserialize' }, + { + text: 'normalizeChainId', + link: '/react/api/utilities/normalizeChainId', + }, + { text: 'serialize', link: '/react/api/utilities/serialize' }, + ], + }, + ], + }, + ], + '/vue': [ + { + text: 'Introduction', + items: [ + { text: 'Why Wagmi', link: '/vue/why' }, + { text: 'Installation', link: '/vue/installation' }, + { text: 'Getting Started', link: '/vue/getting-started' }, + { text: 'TypeScript', link: '/vue/typescript' }, + ], + }, + { + text: 'Guides', + items: [ + { + text: 'TanStack Query', + link: '/vue/guides/tanstack-query', + }, + { + text: 'Viem', + link: '/vue/guides/viem', + }, + { + text: 'Error Handling', + link: '/vue/guides/error-handling', + }, + { + text: 'Chain Properties', + link: '/vue/guides/chain-properties', + }, + { + text: 'SSR', + link: '/vue/guides/ssr', + }, + { + text: 'Connect Wallet', + link: '/vue/guides/connect-wallet', + }, + { + text: 'Send Transaction', + link: '/vue/guides/send-transaction', + }, + { + text: 'Read from Contract', + link: '/vue/guides/read-from-contract', + }, + { + text: 'Write to Contract', + link: '/vue/guides/write-to-contract', + }, + { + text: 'FAQ / Troubleshooting', + link: '/vue/guides/faq', + }, + ], + }, + { + text: 'Configuration', + items: [ + { text: 'createConfig', link: '/vue/api/createConfig' }, + { text: 'createStorage', link: '/vue/api/createStorage' }, + { text: 'Chains', link: '/vue/api/chains' }, + { + text: 'Connectors', + collapsed: true, + link: '/vue/api/connectors', + items: [ + { + text: 'coinbaseWallet', + link: '/vue/api/connectors/coinbaseWallet', + }, + { text: 'injected', link: '/vue/api/connectors/injected' }, + { + text: 'metaMask', + link: '/vue/api/connectors/metaMask', + }, + { + text: 'mock', + link: '/vue/api/connectors/mock', + }, + { + text: 'safe', + link: '/vue/api/connectors/safe', + }, + { + text: 'walletConnect', + link: '/vue/api/connectors/walletConnect', + }, + ], + }, + { + text: 'Transports', + collapsed: true, + link: '/vue/api/transports', + items: [ + { + text: 'custom (EIP-1193)', + link: '/vue/api/transports/custom', + }, + { + text: 'fallback', + link: '/vue/api/transports/fallback', + }, + { + text: 'http', + link: '/vue/api/transports/http', + }, + { + text: 'unstable_connector', + link: '/vue/api/transports/unstable_connector', + }, + { + text: 'webSocket', + link: '/vue/api/transports/webSocket', + }, + ], + }, + { text: 'WagmiPlugin', link: '/vue/api/WagmiPlugin' }, + { text: 'Nuxt', link: '/vue/api/Nuxt' }, + ], + }, + { + text: 'Composables', + link: '/vue/api/composables', + items: [ + { text: 'useAccount', link: '/vue/api/composables/useAccount' }, + { + text: 'useAccountEffect', + link: '/vue/api/composables/useAccountEffect', + }, + { + text: 'useBalance', + link: '/vue/api/composables/useBalance', + }, + { + text: 'useBlockNumber', + link: '/vue/api/composables/useBlockNumber', + }, + { + text: 'useBytecode', + link: '/vue/api/composables/useBytecode', + }, + { text: 'useChainId', link: '/vue/api/composables/useChainId' }, + { text: 'useChains', link: '/vue/api/composables/useChains' }, + { text: 'useClient', link: '/vue/api/composables/useClient' }, + { text: 'useConfig', link: '/vue/api/composables/useConfig' }, + { text: 'useConnect', link: '/vue/api/composables/useConnect' }, + { + text: 'useConnections', + link: '/vue/api/composables/useConnections', + }, + { + text: 'useConnectorClient', + link: '/vue/api/composables/useConnectorClient', + }, + { + text: 'useConnectors', + link: '/vue/api/composables/useConnectors', + }, + { + text: 'useDisconnect', + link: '/vue/api/composables/useDisconnect', + }, + { + text: 'useEnsAddress', + link: '/vue/api/composables/useEnsAddress', + }, + { + text: 'useEnsAvatar', + link: '/vue/api/composables/useEnsAvatar', + }, + { + text: 'useEstimateGas', + link: '/vue/api/composables/useEstimateGas', + }, + { + text: 'useReadContract', + link: '/vue/api/composables/useReadContract', + }, + { + text: 'useReconnect', + link: '/vue/api/composables/useReconnect', + }, + { + text: 'useSendTransaction', + link: '/vue/api/composables/useSendTransaction', + }, + { + text: 'useSignMessage', + link: '/vue/api/composables/useSignMessage', + }, + { + text: 'useSignTypedData', + link: '/vue/api/composables/useSignTypedData', + }, + { + text: 'useSimulateContract', + link: '/vue/api/composables/useSimulateContract', + }, + { + text: 'useSwitchAccount', + link: '/vue/api/composables/useSwitchAccount', + }, + { + text: 'useSwitchChain', + link: '/vue/api/composables/useSwitchChain', + }, + { + text: 'useTransaction', + link: '/vue/api/composables/useTransaction', + }, + { + text: 'useTransactionReceipt', + link: '/vue/api/composables/useTransactionReceipt', + }, + { + text: 'useWaitForTransactionReceipt', + link: '/vue/api/composables/useWaitForTransactionReceipt', + }, + { + text: 'useWatchBlockNumber', + link: '/vue/api/composables/useWatchBlockNumber', + }, + { + text: 'useWatchContractEvent', + link: '/vue/api/composables/useWatchContractEvent', + }, + { + text: 'useWriteContract', + link: '/vue/api/composables/useWriteContract', + }, + ], + }, + { + text: 'Miscellaneous', + items: [ + { text: 'Actions', link: '/vue/api/actions' }, + { text: 'Errors', link: '/vue/api/errors' }, + { + text: 'Utilities', + collapsed: true, + items: [ + { + text: 'deserialize', + link: '/vue/api/utilities/deserialize', + }, + { text: 'serialize', link: '/vue/api/utilities/serialize' }, + ], + }, + ], + }, + ], + '/core': [ + { + text: 'Introduction', + items: [ + { text: 'Why Wagmi', link: '/core/why' }, + { text: 'Installation', link: '/core/installation' }, + { text: 'Getting Started', link: '/core/getting-started' }, + { text: 'TypeScript', link: '/core/typescript' }, + ], + }, + { + text: 'Guides', + items: [ + { + text: 'Viem', + link: '/core/guides/viem', + }, + { + text: 'Framework Adapters', + link: '/core/guides/framework-adapters', + }, + { + text: 'Error Handling', + link: '/core/guides/error-handling', + }, + { + text: 'Ethers.js Adapters', + link: '/core/guides/ethers', + }, + // { + // text: 'Testing', + // link: '/core/guides/testing', + // }, + { + text: 'Chain Properties', + link: '/core/guides/chain-properties', + }, + { + text: 'FAQ / Troubleshooting', + link: '/core/guides/faq', + }, + { + text: 'Migrate from v1 to v2', + link: '/core/guides/migrate-from-v1-to-v2', + }, + ], + }, + { + text: 'Configuration', + items: [ + { text: 'createConfig', link: '/core/api/createConfig' }, + { text: 'createConnector', link: '/core/api/createConnector' }, + { text: 'createStorage', link: '/core/api/createStorage' }, + { text: 'Chains', link: '/core/api/chains' }, + { + text: 'Connectors', + collapsed: true, + link: '/core/api/connectors', + items: [ + { + text: 'coinbaseWallet', + link: '/core/api/connectors/coinbaseWallet', + }, + { text: 'injected', link: '/core/api/connectors/injected' }, + { + text: 'metaMask', + link: '/core/api/connectors/metaMask', + }, + { + text: 'mock', + link: '/core/api/connectors/mock', + }, + { + text: 'safe', + link: '/core/api/connectors/safe', + }, + { + text: 'walletConnect', + link: '/core/api/connectors/walletConnect', + }, + ], + }, + { + text: 'Transports', + collapsed: true, + link: '/core/api/transports', + items: [ + { + text: 'custom (EIP-1193)', + link: '/core/api/transports/custom', + }, + { + text: 'fallback', + link: '/core/api/transports/fallback', + }, + { + text: 'http', + link: '/core/api/transports/http', + }, + { + text: 'unstable_connector', + link: '/core/api/transports/unstable_connector', + }, + { + text: 'webSocket', + link: '/core/api/transports/webSocket', + }, + ], + }, + ], + }, + { + text: 'Actions', + link: '/core/api/actions', + items: [ + { + text: 'call', + link: '/core/api/actions/call', + }, + { text: 'connect', link: '/core/api/actions/connect' }, + { text: 'deployContract', link: '/core/api/actions/deployContract' }, + { text: 'disconnect', link: '/core/api/actions/disconnect' }, + { + text: 'estimateFeesPerGas', + link: '/core/api/actions/estimateFeesPerGas', + }, + { text: 'estimateGas', link: '/core/api/actions/estimateGas' }, + { + text: 'estimateMaxPriorityFeePerGas', + link: '/core/api/actions/estimateMaxPriorityFeePerGas', + }, + { text: 'getAccount', link: '/core/api/actions/getAccount' }, + { text: 'getBalance', link: '/core/api/actions/getBalance' }, + { + text: 'getBlock', + link: '/core/api/actions/getBlock', + }, + { + text: 'getBlockNumber', + link: '/core/api/actions/getBlockNumber', + }, + { + text: 'getBlockTransactionCount', + link: '/core/api/actions/getBlockTransactionCount', + }, + { + text: 'getBytecode', + link: '/core/api/actions/getBytecode', + }, + { + text: 'getCallsStatus', + link: '/core/api/actions/getCallsStatus', + }, + { + text: 'getCapabilities', + link: '/core/api/actions/getCapabilities', + }, + { text: 'getChainId', link: '/core/api/actions/getChainId' }, + { text: 'getChains', link: '/core/api/actions/getChains' }, + { + text: 'getClient', + link: '/core/api/actions/getClient', + }, + { + text: 'getConnections', + link: '/core/api/actions/getConnections', + }, + { + text: 'getConnectorClient', + link: '/core/api/actions/getConnectorClient', + }, + { + text: 'getConnectors', + link: '/core/api/actions/getConnectors', + }, + { + text: 'getEnsAddress', + link: '/core/api/actions/getEnsAddress', + }, + { text: 'getEnsAvatar', link: '/core/api/actions/getEnsAvatar' }, + { text: 'getEnsName', link: '/core/api/actions/getEnsName' }, + { + text: 'getEnsResolver', + link: '/core/api/actions/getEnsResolver', + }, + { + text: 'getEnsText', + link: '/core/api/actions/getEnsText', + }, + { + text: 'getFeeHistory', + link: '/core/api/actions/getFeeHistory', + }, + { + text: 'getGasPrice', + link: '/core/api/actions/getGasPrice', + }, + { + text: 'getProof', + link: '/core/api/actions/getProof', + }, + { + text: 'getPublicClient', + link: '/core/api/actions/getPublicClient', + }, + { + text: 'getStorageAt', + link: '/core/api/actions/getStorageAt', + }, + { text: 'getToken', link: '/core/api/actions/getToken' }, + { + text: 'getTransaction', + link: '/core/api/actions/getTransaction', + }, + { + text: 'getTransactionConfirmations', + link: '/core/api/actions/getTransactionConfirmations', + }, + { + text: 'getTransactionCount', + link: '/core/api/actions/getTransactionCount', + }, + { + text: 'getTransactionReceipt', + link: '/core/api/actions/getTransactionReceipt', + }, + { + text: 'getWalletClient', + link: '/core/api/actions/getWalletClient', + }, + { + text: 'multicall', + link: '/core/api/actions/multicall', + }, + { + text: 'prepareTransactionRequest', + link: '/core/api/actions/prepareTransactionRequest', + }, + { text: 'reconnect', link: '/core/api/actions/reconnect' }, + { + text: 'readContract', + link: '/core/api/actions/readContract', + }, + { + text: 'readContracts', + link: '/core/api/actions/readContracts', + }, + { + text: 'sendCalls', + link: '/core/api/actions/sendCalls', + }, + { + text: 'sendTransaction', + link: '/core/api/actions/sendTransaction', + }, + { + text: 'showCallsStatus', + link: '/core/api/actions/showCallsStatus', + }, + { + text: 'signMessage', + link: '/core/api/actions/signMessage', + }, + { + text: 'signTypedData', + link: '/core/api/actions/signTypedData', + }, + { + text: 'simulateContract', + link: '/core/api/actions/simulateContract', + }, + { + text: 'switchAccount', + link: '/core/api/actions/switchAccount', + }, + { + text: 'switchChain', + link: '/core/api/actions/switchChain', + }, + { + text: 'verifyMessage', + link: '/core/api/actions/verifyMessage', + }, + { + text: 'verifyTypedData', + link: '/core/api/actions/verifyTypedData', + }, + { + text: 'waitForCallsStatus', + link: '/core/api/actions/waitForCallsStatus', + }, + { + text: 'waitForTransactionReceipt', + link: '/core/api/actions/waitForTransactionReceipt', + }, + { + text: 'watchAccount', + link: '/core/api/actions/watchAccount', + }, + { + text: 'watchAsset', + link: '/core/api/actions/watchAsset', + }, + { + text: 'watchBlocks', + link: '/core/api/actions/watchBlocks', + }, + { + text: 'watchBlockNumber', + link: '/core/api/actions/watchBlockNumber', + }, + { + text: 'watchChainId', + link: '/core/api/actions/watchChainId', + }, + { + text: 'watchClient', + link: '/core/api/actions/watchClient', + }, + { + text: 'watchConnections', + link: '/core/api/actions/watchConnections', + }, + { + text: 'watchConnectors', + link: '/core/api/actions/watchConnectors', + }, + { + text: 'watchContractEvent', + link: '/core/api/actions/watchContractEvent', + }, + { + text: 'watchPendingTransactions', + link: '/core/api/actions/watchPendingTransactions', + }, + { + text: 'watchPublicClient', + link: '/core/api/actions/watchPublicClient', + }, + { + text: 'writeContract', + link: '/core/api/actions/writeContract', + }, + ], + }, + { + text: 'Miscellaneous', + items: [ + { text: 'Errors', link: '/core/api/errors' }, + { + text: 'Utilities', + collapsed: true, + items: [ + { + text: 'cookieToInitialState', + link: '/core/api/utilities/cookieToInitialState', + }, + { text: 'deserialize', link: '/core/api/utilities/deserialize' }, + { + text: 'normalizeChainId', + link: '/core/api/utilities/normalizeChainId', + }, + { text: 'serialize', link: '/core/api/utilities/serialize' }, + ], + }, + ], + }, + ], + '/cli': [ + { + text: 'Introduction', + items: [ + { text: 'Why Wagmi CLI', link: '/cli/why' }, + { text: 'Installation', link: '/cli/installation' }, + { text: 'Getting Started', link: '/cli/getting-started' }, + ], + }, + { + text: 'Guides', + items: [ + { + text: 'Migrate from v1 to v2', + link: '/cli/guides/migrate-from-v1-to-v2', + }, + ], + }, + { + text: 'Config File', + items: [ + { + text: 'Configuring CLI', + link: '/cli/config/configuring-cli', + }, + { text: 'Config Options', link: '/cli/config/options' }, + ], + }, + { + text: 'Commands', + link: '/cli/api/commands', + items: [ + { + text: 'generate', + link: '/cli/api/commands/generate', + }, + { + text: 'init', + link: '/cli/api/commands/init', + }, + ], + }, + { + text: 'Plugins', + link: '/cli/api/plugins', + items: [ + { text: 'actions', link: '/cli/api/plugins/actions' }, + { text: 'blockExplorer', link: '/cli/api/plugins/blockExplorer' }, + { text: 'etherscan', link: '/cli/api/plugins/etherscan' }, + { text: 'fetch', link: '/cli/api/plugins/fetch' }, + { text: 'foundry', link: '/cli/api/plugins/foundry' }, + { text: 'hardhat', link: '/cli/api/plugins/hardhat' }, + { text: 'react', link: '/cli/api/plugins/react' }, + { text: 'sourcify', link: '/cli/api/plugins/sourcify' }, + ], + }, + { + text: 'create-wagmi', + link: '/cli/create-wagmi', + }, + ], + '/dev': [ + { + text: 'Dev', + items: [ + { text: 'Contributing', link: '/dev/contributing' }, + { text: 'Creating Connectors', link: '/dev/creating-connectors' }, + ], + }, + ], + '/examples': [ + { + text: 'React', + items: [ + { text: 'Connect Wallet', link: '/examples/connect-wallet' }, + { text: 'Send Transaction', link: '/examples/send-transaction' }, + { text: 'Write Contract', link: '/examples/contract-write' }, + { + text: 'Write Contract (Dynamic Args)', + link: '/examples/contract-write-dynamic', + }, + { text: 'Sign Message', link: '/examples/sign-message' }, + { + text: 'Sign In With Ethereum', + link: '/examples/sign-in-with-ethereum', + }, + ], + }, + ], + } satisfies DefaultTheme.Sidebar +} diff --git a/site/.vitepress/theme/components/AsideSponsors.vue b/site/.vitepress/theme/components/AsideSponsors.vue new file mode 100644 index 0000000000..09e1075abb --- /dev/null +++ b/site/.vitepress/theme/components/AsideSponsors.vue @@ -0,0 +1,27 @@ + + + + diff --git a/site/.vitepress/theme/components/Banner.vue b/site/.vitepress/theme/components/Banner.vue new file mode 100644 index 0000000000..14ccf48b91 --- /dev/null +++ b/site/.vitepress/theme/components/Banner.vue @@ -0,0 +1,16 @@ +// TODO: Dismissable, a11y, etc. +// https://github.com/faker-js/faker/pull/1487 + + + + diff --git a/site/.vitepress/theme/components/HomeBanner.vue b/site/.vitepress/theme/components/HomeBanner.vue new file mode 100644 index 0000000000..dbbf1c4f89 --- /dev/null +++ b/site/.vitepress/theme/components/HomeBanner.vue @@ -0,0 +1,13 @@ + + + + diff --git a/site/.vitepress/theme/components/HomePage.vue b/site/.vitepress/theme/components/HomePage.vue new file mode 100644 index 0000000000..31e1e10574 --- /dev/null +++ b/site/.vitepress/theme/components/HomePage.vue @@ -0,0 +1,118 @@ + + + + + diff --git a/site/.vitepress/theme/composables/useSponsors.ts b/site/.vitepress/theme/composables/useSponsors.ts new file mode 100644 index 0000000000..571a2b7df6 --- /dev/null +++ b/site/.vitepress/theme/composables/useSponsors.ts @@ -0,0 +1,212 @@ +import { onMounted, ref } from 'vue' + +type Sponsor = { + name: string + img: string + url: string +} + +type Data = { + size: 'big' | 'medium' | 'small' + items: Sponsor[] + tier: string + type: 'platinum' | 'gold' | 'silver' +}[] + +// shared data across instances so we load only once. +const data = ref() + +// TODO: Data powered +// const dataHost = 'https://sponsors.vuejs.org' +// const dataUrl = `${dataHost}/vite.json` + +export function useSponsors() { + onMounted(async () => { + if (data.value) return + + // const result = await fetch(dataUrl) + // const json = await result.json() + // console.log(json) + const sponsors = { + platinum: [ + { + name: 'Paradigm', + url: 'https://paradigm.xyz', + img: 'paradigm-light.svg', + }, + { + name: 'Ithaca', + url: 'https://ithaca.xyz', + img: 'ithaca-light.svg', + }, + ], + gold: [ + { + name: 'Stripe', + url: 'https://www.stripe.com', + img: 'stripe-light.svg', + }, + { + name: 'zkSync', + url: 'https://zksync.io', + img: 'zksync-light.svg', + }, + { + name: 'Linea', + url: 'https://linea.build', + img: 'linea-light.svg', + }, + { + name: 'Routescan', + url: 'https://routescan.io', + img: 'routescan-light.svg', + }, + ], + silver: [ + { + name: 'Family', + url: 'https://twitter.com/family', + img: 'family-light.svg', + }, + { + name: 'Context', + url: 'https://twitter.com/context', + img: 'context-light.svg', + }, + { + name: 'WalletConnect', + url: 'https://walletconnect.com', + img: 'walletconnect-light.svg', + }, + { + name: 'PartyDAO', + url: 'https://twitter.com/prtyDAO', + img: 'partydao-light.svg', + }, + { + name: 'SushiSwap', + url: 'https://www.sushi.com', + img: 'sushi-light.svg', + }, + { + name: 'Dynamic', + url: 'https://www.dynamic.xyz', + img: 'dynamic-light.svg', + }, + { + name: 'Privy', + url: 'https://privy.io', + img: 'privy-light.svg', + }, + { + name: 'PancakeSwap', + url: 'https://pancakeswap.finance', + img: 'pancake-light.svg', + }, + { + name: 'Celo', + url: 'https://celo.org', + img: 'celo-light.svg', + }, + { + name: 'Rainbow', + url: 'https://rainbow.me', + img: 'rainbow-light.svg', + }, + { + name: 'Pimlico', + url: 'https://pimlico.io', + img: 'pimlico-light.svg', + }, + { + name: 'Zora', + url: 'https://zora.co', + img: 'zora-light.svg', + }, + { + name: 'Lattice', + url: 'https://lattice.xyz', + img: 'lattice-light.svg', + }, + { + name: 'Supa', + url: 'https://twitter.com/supafinance', + img: 'supa-light.svg', + }, + { + name: 'Syndicate', + url: 'https://syndicate.io', + img: 'syndicate-light.svg', + }, + { + name: 'Reservoir', + url: 'https://reservoir.tools', + img: 'reservoir-light.svg', + }, + { + name: 'Uniswap', + url: 'https://uniswap.org', + img: 'uniswap-light.svg', + }, + { + name: 'Biconomy', + url: 'https://biconomy.io', + img: 'biconomy-light.svg', + }, + { + name: 'Thirdweb', + url: 'https://thirdweb.com', + img: 'thirdweb-light.svg', + }, + { + name: 'Polymarket', + url: 'https://polymarket.com', + img: 'polymarket-light.svg', + }, + { + name: 'Sequence', + url: 'https://sequence.xyz', + img: 'sequence-light.svg', + }, + ], + } + + data.value = mapSponsors(sponsors) + }) + + return { data } +} + +function mapSponsors(sponsors: { + platinum: Sponsor[] + gold: Sponsor[] + silver: Sponsor[] +}) { + return [ + { + size: 'big', + items: mapImgPath(sponsors.platinum), + tier: 'Collaborators', + type: 'platinum', + }, + { + size: 'medium', + items: mapImgPath(sponsors.gold), + tier: 'Large Enterprises', + type: 'gold', + }, + { + size: 'small', + items: mapImgPath(sponsors.silver), + tier: 'Small Enterprises', + type: 'silver', + }, + ] satisfies Data +} + +function mapImgPath(sponsors: Sponsor[]) { + return sponsors.map((sponsor) => ({ + ...sponsor, + img: `https://raw.githubusercontent.com/wevm/.github/main/content/sponsors/${sponsor.img}`, + })) +} diff --git a/site/.vitepress/theme/index.ts b/site/.vitepress/theme/index.ts new file mode 100644 index 0000000000..abcc802176 --- /dev/null +++ b/site/.vitepress/theme/index.ts @@ -0,0 +1,30 @@ +import TwoslashFloatingVue from '@shikijs/vitepress-twoslash/client' +import type { Theme } from 'vitepress' +import DefaultTheme from 'vitepress/theme' +// https://vitepress.dev/guide/custom-theme +import { h } from 'vue' + +import '@shikijs/vitepress-twoslash/style.css' +import 'uno.css' +import './style.css' + +import AsideSponsors from './components/AsideSponsors.vue' +// import Banner from './components/Banner.vue' +import HomeBanner from './components/HomeBanner.vue' +import HomePage from './components/HomePage.vue' + +export default { + extends: DefaultTheme, + Layout() { + return h(DefaultTheme.Layout, null, { + // https://vitepress.dev/guide/extending-default-theme#layout-slots + 'aside-ads-before': () => h(AsideSponsors), + // 'doc-before': () => h(Banner), + 'home-features-after': () => h(HomePage), + 'home-hero-before': () => h(HomeBanner), + }) + }, + enhanceApp({ app }) { + app.use(TwoslashFloatingVue) + }, +} satisfies Theme diff --git a/site/.vitepress/theme/style.css b/site/.vitepress/theme/style.css new file mode 100644 index 0000000000..4ec569cf05 --- /dev/null +++ b/site/.vitepress/theme/style.css @@ -0,0 +1,148 @@ +/** + * Customize default theme styling by overriding CSS variables: + * https://github.com/vuejs/vitepress/blob/main/src/client/theme-default/styles/vars.css + */ + +/** + * Colors + * + * Each colors have exact same color scale system with 3 levels of solid + * colors with different brightness, and 1 soft color. + * + * - `XXX-1`: The most solid color used mainly for colored text. It must + * satisfy the contrast ratio against when used on top of `XXX-soft`. + * + * - `XXX-2`: The color used mainly for hover state of the button. + * + * - `XXX-3`: The color for solid background, such as bg color of the button. + * It must satisfy the contrast ratio with pure white (#ffffff) text on + * top of it. + * + * - `XXX-soft`: The color used for subtle background such as custom container + * or badges. It must satisfy the contrast ratio when putting `XXX-1` colors + * on top of it. + * + * The soft color must be semi transparent alpha channel. This is crucial + * because it allows adding multiple "soft" colors on top of each other + * to create a accent, such as when having inline code block inside + * custom containers. + * + * - `default`: The color used purely for subtle indication without any + * special meanings attached to it such as bg color for menu hover state. + * + * - `brand`: Used for primary brand colors, such as link text, button with + * brand theme, etc. + * + * - `tip`: Used to indicate useful information. The default theme uses the + * brand color for this by default. + * + * - `warning`: Used to indicate warning to the users. Used in custom + * container, badges, etc. + * + * - `danger`: Used to show error, or dangerous message to the users. Used + * in custom container, badges, etc. + * -------------------------------------------------------------------------- */ + +:root { + --vp-c-default-1: var(--vp-c-gray-1); + --vp-c-default-2: var(--vp-c-gray-2); + --vp-c-default-3: var(--vp-c-gray-3); + --vp-c-default-soft: var(--vp-c-gray-soft); + + --vp-c-brand-1: var(--vp-c-indigo-1); + --vp-c-brand-2: var(--vp-c-indigo-2); + --vp-c-brand-3: var(--vp-c-indigo-3); + --vp-c-brand-soft: var(--vp-c-indigo-soft); + + --vp-c-tip-1: var(--vp-c-brand-1); + --vp-c-tip-2: var(--vp-c-brand-2); + --vp-c-tip-3: var(--vp-c-brand-3); + --vp-c-tip-soft: var(--vp-c-brand-soft); + + --vp-c-warning-1: var(--vp-c-yellow-1); + --vp-c-warning-2: var(--vp-c-yellow-2); + --vp-c-warning-3: var(--vp-c-yellow-3); + --vp-c-warning-soft: var(--vp-c-yellow-soft); + + --vp-c-danger-1: var(--vp-c-red-1); + --vp-c-danger-2: var(--vp-c-red-2); + --vp-c-danger-3: var(--vp-c-red-3); + --vp-c-danger-soft: var(--vp-c-red-soft); +} + +/** + * Component: Button + * -------------------------------------------------------------------------- */ + +:root { + --vp-button-brand-border: transparent; + --vp-button-brand-text: var(--vp-c-white); + --vp-button-brand-bg: var(--vp-c-brand-3); + --vp-button-brand-hover-border: transparent; + --vp-button-brand-hover-text: var(--vp-c-white); + --vp-button-brand-hover-bg: var(--vp-c-brand-2); + --vp-button-brand-active-border: transparent; + --vp-button-brand-active-text: var(--vp-c-white); + --vp-button-brand-active-bg: var(--vp-c-brand-1); +} + +/** + * Component: Home + * -------------------------------------------------------------------------- */ + +:root { + --vp-home-hero-name-color: transparent; + --vp-home-hero-name-background: -webkit-linear-gradient( + 120deg, + #bd34fe 30%, + #41d1ff + ); + + --vp-home-hero-image-background-image: linear-gradient( + -45deg, + #bd34fe 50%, + #47caff 50% + ); + --vp-home-hero-image-filter: blur(44px); +} + +@media (min-width: 640px) { + :root { + --vp-home-hero-image-filter: blur(56px); + } +} + +@media (min-width: 960px) { + :root { + --vp-home-hero-image-filter: blur(68px); + } +} + +/** + * Component: Custom Block + * -------------------------------------------------------------------------- */ + +:root { + --vp-custom-block-tip-border: transparent; + --vp-custom-block-tip-text: var(--vp-c-text-1); + --vp-custom-block-tip-bg: var(--vp-c-brand-soft); + --vp-custom-block-tip-code-bg: var(--vp-c-brand-soft); +} + +/** + * Component: Algolia + * -------------------------------------------------------------------------- */ + +.DocSearch { + --docsearch-primary-color: var(--vp-c-brand-1) !important; +} + +.vp-doc [class*="language-"] .has-focused-lines .line:not(.has-focus) { + filter: unset; + opacity: 0.3; +} + +.twoslash-error-line { + max-width: min-content; + white-space: wrap; +} diff --git a/site/cli/api/commands.md b/site/cli/api/commands.md new file mode 100644 index 0000000000..643397560b --- /dev/null +++ b/site/cli/api/commands.md @@ -0,0 +1,53 @@ +# Commands + +## Available Commands + +- [`init`](/cli/api/commands/init) Creates configuration file. +- [`generate`](/cli/api/commands/generate) Generates code based on configuration, using `contracts` and `plugins`. + +## Display Info + +### `-h`, `--help` + +Show help message when `-h`, `--help` flags appear. + +::: code-group +```bash [pnpm] +pnpm wagmi --help +``` + +```bash [npm] +npx wagmi --help +``` + +```bash [yarn] +yarn wagmi --help +``` + +```bash [bun] +bun wagmi --help +``` +::: + +### `-v`, `--version` + +Show version number when `-v`, `--version` flags appear. + +::: code-group +```bash [pnpm] +pnpm wagmi --version +``` + +```bash [npm] +npx wagmi --version +``` + +```bash [yarn] +yarn wagmi --version +``` + +```bash [bun] +bun wagmi --version +``` +::: + diff --git a/site/cli/api/commands/generate.md b/site/cli/api/commands/generate.md new file mode 100644 index 0000000000..d1f88e90a0 --- /dev/null +++ b/site/cli/api/commands/generate.md @@ -0,0 +1,49 @@ +# generate + +Generates code based on configuration, using `contracts` and `plugins`. + +## Usage + +```bash +wagmi generate +``` + +## Options + +### -c, --config \ + +`string` + +Path to config file. + +```bash +wagmi generate --config wagmi.config.ts +``` + +### -r, --root \ + +`string` + +Root path to resolve config from. + +```bash +wagmi generate --root path/to/root +``` + +### -w, --watch + +`boolean` + +Watch for changes (for plugins that support watch mode). + +```bash +wagmi generate --watch +``` + +### -h, --help + +Displays help message. + +```bash +wagmi generate --help +``` \ No newline at end of file diff --git a/site/cli/api/commands/init.md b/site/cli/api/commands/init.md new file mode 100644 index 0000000000..440315e9c7 --- /dev/null +++ b/site/cli/api/commands/init.md @@ -0,0 +1,40 @@ +# init + +Creates configuration file. If TypeScript is detected, the config file will use TypeScript and be named `wagmi.config.ts`. Otherwise, the config file will use JavaScript and be named `wagmi.config.js`. + +## Usage + +```bash +wagmi init +``` + +## Options + +### -c, --config \ + +`string` + +Path to config file. + +```bash +wagmi init --config wagmi.config.ts +``` + +### -r, --root \ + +`string` + +Root path to resolve config from. + +```bash +wagmi init --root path/to/root +``` + +### -h, --help + +Displays help message. + +```bash +wagmi init --help +``` + diff --git a/site/cli/api/plugins.md b/site/cli/api/plugins.md new file mode 100644 index 0000000000..54afdb19e1 --- /dev/null +++ b/site/cli/api/plugins.md @@ -0,0 +1,42 @@ +# Plugins + +Plugins for managing ABIs, generating code, and more. + +## Import + +Import via the `'@wagmi/cli/plugins'` entrypoint. + +```ts +import { etherscan } from '@wagmi/cli/plugins' +``` + +## Available Plugins + +- [`actions`](/cli/api/plugins/actions) Generate type-safe VanillaJS actions from configuration `contracts`. +- [`blockExplorer`](/cli/api/plugins/blockExplorer) Fetch ABIs from Block Explorers that support `?module=contract&action=getabi`. +- [`etherscan`](/cli/api/plugins/etherscan) Fetch ABIs from Etherscan and add into configuration. +- [`fetch`](/cli/api/plugins/fetch) Fetch and parse ABIs from network resource with `fetch`. +- [`foundry`](/cli/api/plugins/foundry) Generate ABIs and watch for Foundry project changes. +- [`hardhat`](/cli/api/plugins/hardhat) Generate ABIs and watch for Hardhat projects changes. +- [`react`](/cli/api/plugins/react) Generate type-safe React Hooks from configuration `contracts`. +- [`sourcify`](/cli/api/plugins/sourcify) Fetch ABIs from Sourcify from configuration `contracts`. + +## Create Plugin + +Creating plugins to hook into the CLI is quite simple. Plugins most commonly inject contracts into `contracts` config, e.g. [`etherscan`](/cli/api/plugins/etherscan), and/or generate code using the `run` option, e.g. [`react`](/cli/api/plugins/react). All you need to do is write a function that returns the `Plugin` type. + +```ts{3-8} +import { type Plugin, defineConfig } from '@wagmi/cli' + +function myPlugin(): Plugin { + // `name` is the only required property. + name: 'MyPlugin', + // You likely want to at least include `contracts` or `run`. + // ... +} + +export default defineConfig({ + out: 'src/generated.ts', + plugins: [myPlugin()], +}) +``` diff --git a/site/cli/api/plugins/actions.md b/site/cli/api/plugins/actions.md new file mode 100644 index 0000000000..d62a29a6b7 --- /dev/null +++ b/site/cli/api/plugins/actions.md @@ -0,0 +1,72 @@ +# actions + +Plugin for type-safe VanillaJS actions. + +## Import + +```ts +import { actions } from '@wagmi/cli/plugins' +``` + +## Usage + +```ts{2,6} +import { defineConfig } from '@wagmi/cli' +import { actions } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + actions(), + ], +}) +``` + +## Configuration + +```ts +import { type ActionsConfig } from '@wagmi/cli/plugins' +``` + +### getActionName + +`` 'legacy' | ((options: { contractName: string; type: 'read' | 'simulate' | 'watch' | 'write' }) => `use${string}`) `` + +- Function for setting custom hook names. +- Defaults to `` `${type}${contractName}` ``. For example, `readErc20`, `simulateErc20`, `watchErc20Event`, `writeErc20`. +- When `'legacy'` (deprecated), hook names are set to `@wagmi/cli@1` format. + +```ts +import { defineConfig } from '@wagmi/cli' +import { actions } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + actions({ + getActionName({ contractName, type }) { // [!code focus] + return `${contractName}__${type}` // [!code focus] + }, // [!code focus] + }), + ], +}) +``` + +### overridePackageName + +`'@wagmi/core' | 'wagmi'` + +- Override detected import source. +- Defaults to `'wagmi'` or `'@wagmi/core'` depending on which package is installed. + +```ts +import { defineConfig } from '@wagmi/cli' +import { actions } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + actions({ + overridePackageName: 'wagmi', // [!code focus] + }), + ], +}) +``` + diff --git a/site/cli/api/plugins/blockExplorer.md b/site/cli/api/plugins/blockExplorer.md new file mode 100644 index 0000000000..462e37bddd --- /dev/null +++ b/site/cli/api/plugins/blockExplorer.md @@ -0,0 +1,223 @@ +# blockExplorer + +Plugin for fetching ABIs from block explorers that supports the `?module=contract&action=getabi` API format. + +## Import + +```ts +import { blockExplorer } from '@wagmi/cli/plugins' +``` + +## Usage + +```ts{2,6-14} +import { defineConfig } from '@wagmi/cli' +import { blockExplorer } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + blockExplorer({ + baseUrl: 'https://api.etherscan.io/v2/api', + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + }), + ], +}) +``` + +## Configuration + +```ts +import { type BlockExplorerConfig } from '@wagmi/cli/plugins' +``` + +### apiKey + +`string | undefined` + +API key for block explorer. Appended to the request URL as query param `&apikey=${apiKey}`. + +```ts +import { defineConfig } from '@wagmi/cli' +import { blockExplorer } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + blockExplorer({ + apiKey: process.env.ETHERSCAN_API_KEY, // [!code focus] + baseUrl: 'https://api.etherscan.io/v2/api', + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + }), + ], +}) +``` + +### baseUrl + +`string` + +Base URL for block explorer. + +```ts +import { defineConfig } from '@wagmi/cli' +import { blockExplorer } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + blockExplorer({ + baseUrl: 'https://api.etherscan.io/v2/api', // [!code focus] + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + }), + ], +}) +``` + +### cacheDuration + +`number | undefined` + +Duration in milliseconds to cache ABIs. Defaults to `1_800_000` (30 minutes). + +```ts +import { defineConfig } from '@wagmi/cli' +import { blockExplorer } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + blockExplorer({ + baseUrl: 'https://api.etherscan.io/v2/api', + cacheDuration: 300_000, // [!code focus] + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + }), + ], +}) +``` + +### chainId + +`number | undefined` + +Chain ID for block explorer. Appended to the request URL as query param `&chainId=${chainId}`. + +```ts +import { defineConfig } from '@wagmi/cli' +import { blockExplorer } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + blockExplorer({ + apiKey: process.env.ETHERSCAN_API_KEY, + baseUrl: 'https://api.etherscan.io/v2/api', + chainId: 1, // [!code focus] + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + }), + ], +}) +``` + + +### contracts + +`{ name: string; address?: Address | Record | undefined }[]` + +Contracts to fetch ABIs for. + +```ts +import { defineConfig } from '@wagmi/cli' +import { blockExplorer } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + blockExplorer({ + baseUrl: 'https://api.etherscan.io/v2/api', + contracts: [ // [!code focus] + { // [!code focus] + name: 'Wagmigotchi', // [!code focus] + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', // [!code focus] + }, // [!code focus] + ], // [!code focus] + }), + ], +}) +``` + +### getAddress + +`((config: { address: Address | Record }) => Address) | undefined` + +- Function to get address from contract config. +- Defaults to `({ address }) => typeof address === 'string' ? address : Object.values(address)[0]`. + +```ts +import { defineConfig } from '@wagmi/cli' +import { blockExplorer } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + blockExplorer({ + baseUrl: 'https://api.etherscan.io/v2/api', + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + getAddress({ address }) { // [!code focus] + if (typeof address === 'string') return address // [!code focus] + return Object.values(address)[0] // [!code focus] + }, // [!code focus] + }), + ], +}) +``` + +### name + +`string` + +- Name of source. +- Defaults to `'Block Explorer'`. + +```ts +import { defineConfig } from '@wagmi/cli' +import { blockExplorer } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + blockExplorer({ + baseUrl: 'https://api.etherscan.io/v2/api', + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + name: 'Etherscan', // [!code focus] + }), + ], +}) +``` diff --git a/site/cli/api/plugins/etherscan.md b/site/cli/api/plugins/etherscan.md new file mode 100644 index 0000000000..ec52fd6796 --- /dev/null +++ b/site/cli/api/plugins/etherscan.md @@ -0,0 +1,182 @@ +# etherscan + +Plugin for fetching ABIs from [Etherscan](https://etherscan.io) and adding into `contracts` config. + +## Import + +```ts +import { etherscan } from '@wagmi/cli/plugins' +``` + +## Usage + +```ts{2,6-14} +import { defineConfig } from '@wagmi/cli' +import { etherscan } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + etherscan({ + apiKey: process.env.ETHERSCAN_API_KEY, + chainId: 1, + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + }), + ], +}) +``` + +## Configuration + +```ts +import { type EtherscanConfig } from '@wagmi/cli/plugins' +``` + +### apiKey + +`string` + +Etherscan API key. Etherscan API keys are specific per network and include testnets (e.g. Ethereum Mainnet and Sepolia share same API key). + +```ts +import { defineConfig } from '@wagmi/cli' +import { etherscan } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + etherscan({ + apiKey: process.env.ETHERSCAN_API_KEY, // [!code focus] + chainId: 1, + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + }), + ], +}) +``` + +### cacheDuration + +`number | undefined` + +- Duration in milliseconds to cache ABIs. +- Defaults to `1_800_000` (30 minutes). + +```ts +import { defineConfig } from '@wagmi/cli' +import { etherscan } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + etherscan({ + apiKey: process.env.ETHERSCAN_API_KEY, + cacheDuration: 300_000, // [!code focus] + chainId: 1, + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + }), + ], +}) +``` + +### chainId + +`number` + +Chain ID to use for fetching ABI. If [`address`](/cli/config/options#address) is an object, `chainId` is used to select the address. + +View supported chains on the [Etherscan docs](https://docs.etherscan.io/etherscan-v2/getting-started/supported-chains). + +```ts +import { defineConfig } from '@wagmi/cli' +import { blockExplorer } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + etherscan({ + apiKey: process.env.ETHERSCAN_API_KEY, + chainId: 1, // [!code focus] + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + { + name: 'EnsRegistry', + address: { + 1: '0x314159265dd8dbb310642f98f50c066173c1259b', + 5: '0x112234455c3a32fd11230c42e7bccd4a84e02010', + }, + }, + ], + }), + ], +}) +``` + +### contracts + +`{ name: string; address?: Address | Record | undefined }[]` + +Contracts to fetch ABIs for. + +```ts +import { defineConfig } from '@wagmi/cli' +import { etherscan } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + etherscan({ + apiKey: process.env.ETHERSCAN_API_KEY, + chainId: 1, + contracts: [ // [!code focus] + { // [!code focus] + name: 'Wagmigotchi', // [!code focus] + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', // [!code focus] + }, // [!code focus] + ], // [!code focus] + }), + ], +}) +``` + +### tryFetchProxyImplementation + +`boolean | undefined` + +- Whether to try fetching proxy implementation address of the contract. +- Defaults to `false`. + +```ts +import { defineConfig } from '@wagmi/cli' +import { blockExplorer } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + etherscan({ + apiKey: process.env.ETHERSCAN_API_KEY, + chainId: 1, + contracts: [ + { + name: 'FiatToken', + address: '0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48', + }, + ], + tryFetchProxyImplementation: true, // [!code focus] + }), + ], +}) +``` + + diff --git a/site/cli/api/plugins/fetch.md b/site/cli/api/plugins/fetch.md new file mode 100644 index 0000000000..8d463a7ab6 --- /dev/null +++ b/site/cli/api/plugins/fetch.md @@ -0,0 +1,269 @@ +# fetch + +Plugin for fetching and parsing ABIs from network resource with `fetch`. + +## Import + +```ts +import { fetch } from '@wagmi/cli/plugins' +``` + +## Usage + +```ts{2,6-23} +import { defineConfig } from '@wagmi/cli' +import { fetch } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + fetch({ + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + request(contract) { + if (!contract.address) throw new Error('address is required') + const address = + typeof contract.address === 'string' + ? contract.address + : Object.values(contract.address)[0] + return { + url: `https://api.etherscan.io/api?module=contract&action=getabi&address=${address}`, + } + }, + }), + ], +}) +``` + + +## Configuration + +```ts +import { type FetchConfig } from '@wagmi/cli/plugins' +``` + +### cacheDuration + +`number | undefined` + +- Duration in milliseconds to cache ABIs. +- Defaults to `1_800_000` (30 minutes). + +```ts +import { defineConfig } from '@wagmi/cli' +import { fetch } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + fetch({ + cacheDuration: 300_000, // [!code focus] + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + request(contract) { + if (!contract.address) throw new Error('address is required') + const address = + typeof contract.address === 'string' + ? contract.address + : Object.values(contract.address)[0] + return { + url: `https://api.etherscan.io/api?module=contract&action=getabi&address=${address}`, + } + }, + }), + ], +}) +``` + +### contracts + +`{ name: string; address?: Address | Record | undefined }[]` + +Contracts to fetch ABIs for. + +```ts +import { defineConfig } from '@wagmi/cli' +import { fetch } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + fetch({ + contracts: [ // [!code focus] + { // [!code focus] + name: 'Wagmigotchi', // [!code focus] + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', // [!code focus] + }, // [!code focus] + ], // [!code focus] + request(contract) { + if (!contract.address) throw new Error('address is required') + const address = + typeof contract.address === 'string' + ? contract.address + : Object.values(contract.address)[0] + return { + url: `https://api.etherscan.io/api?module=contract&action=getabi&address=${address}`, + } + }, + }), + ], +}) + +``` + +### getCacheKey + +`((config: { contract: { address: Address | Record | undefined; name: string } }) => string) | undefined` + +- Function for creating a cache key for contract. Contract data is cached at `~/.wagmi-cli/plugins/fetch/cache/`. +- Defaults to `({ contract }) => JSON.stringify(contract)`. + +```ts +import { defineConfig } from '@wagmi/cli' +import { fetch } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + fetch({ + contracts: [ + { + name: 'wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + getCacheKey({ contract }) { // [!code focus] + if (typeof contract.address === 'string') // [!code focus] + return `${name}:${contract.address}` // [!code focus] + return `${name}:${JSON.stringify(contract.address)}` // [!code focus] + }, // [!code focus] + request(contract) { + if (!contract.address) throw new Error('address is required') + const address = + typeof contract.address === 'string' + ? contract.address + : Object.values(contract.address)[0] + return { + url: `https://api.etherscan.io/api?module=contract&action=getabi&address=${address}`, + } + }, + }), + ], +}) + +``` + +### name + +`string` + +- Name of source. +- Defaults to `'Fetch'`. + +```ts +import { defineConfig } from '@wagmi/cli' +import { fetch } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + fetch({ + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + name: 'Etherscan', // [!code focus] + request(contract) { + if (!contract.address) throw new Error('address is required') + const address = + typeof contract.address === 'string' + ? contract.address + : Object.values(contract.address)[0] + return { + url: `https://api.etherscan.io/api?module=contract&action=getabi&address=${address}`, + } + }, + }), + ], +}) +``` + +### parse + +`((config: { response: Response }) => Abi | Promise) | undefined` + +- Function for parsing ABI from fetch response. +- Defaults to `({ response }) => response.json()` + +```ts +import { defineConfig } from '@wagmi/cli' +import { fetch } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + fetch({ + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + async parse({ response }) { // [!code focus] + const json = await response.json() // [!code focus] + if (json.status === '0') throw new Error(json.message) // [!code focus] + return json.result // [!code focus] + }, // [!code focus] + request(contract) { + if (!contract.address) throw new Error('address is required') + const address = + typeof contract.address === 'string' + ? contract.address + : Object.values(contract.address)[0] + return { + url: `https://api.etherscan.io/api?module=contract&action=getabi&address=${address}`, + } + }, + }), + ], +}) +``` + +### request + +`(config: { address?: Address | Record | undefined }) => { url: RequestInfo; init?: RequestInit | undefined } | Promise<{ url: RequestInfo; init?: RequestInit | undefined }>` + +Function for returning a request to fetch ABI from. + +```ts +import { defineConfig } from '@wagmi/cli' +import { fetch } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + fetch({ + contracts: [ + { + name: 'Wagmigotchi', + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + }, + ], + request(contract) { // [!code focus] + if (!contract.address) throw new Error('address is required') // [!code focus] + const address = // [!code focus] + typeof contract.address === 'string' // [!code focus] + ? contract.address // [!code focus] + : Object.values(contract.address)[0] // [!code focus] + return { // [!code focus] + url: `https://api.etherscan.io/api?module=contract&action=getabi&address=${address}`, // [!code focus] + } // [!code focus] + }, // [!code focus] + }), + ], +}) + +``` diff --git a/site/cli/api/plugins/foundry.md b/site/cli/api/plugins/foundry.md new file mode 100644 index 0000000000..d24677b5c0 --- /dev/null +++ b/site/cli/api/plugins/foundry.md @@ -0,0 +1,217 @@ +# foundry + +Plugin for resolving ABIs from [Foundry](https://github.com/foundry-rs/foundry) projects. Supports [`watch`](/cli/api/commands/generate#w-watch) mode. + +## Import + +```ts +import { foundry } from '@wagmi/cli/plugins' +``` + +## Usage + +```ts{2,6-8} +import { defineConfig } from '@wagmi/cli' +import { foundry } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + foundry({ + project: '../hello_foundry', + }), + ], +}) +``` + +## Configuration + +```ts +import { type FoundryConfig } from '@wagmi/cli/plugins' +``` + +### artifacts + +`string | undefined` + +- Project's artifacts directory. Same as your `foundry.toml`/`forge`s `--out` (`-o`) option. +- Defaults to `'out/'`. + +```ts +import { defineConfig } from '@wagmi/cli' +import { foundry } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + foundry({ + artifacts: 'out/', // [!code focus] + }), + ], +}) +``` + +### deployments + +`{ [key: string]: address?: Address | Record | undefined } | undefined` + +Mapping of addresses to attach to artifacts. + +```ts +import { defineConfig } from '@wagmi/cli' +import { foundry } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + foundry({ + deployments: { // [!code focus] + Counter: { // [!code focus] + 1: '0x314159265dd8dbb310642f98f50c066173c1259b', // [!code focus] + 5: '0x112234455c3a32fd11230c42e7bccd4a84e02010', // [!code focus] + }, // [!code focus] + }, // [!code focus] + }), + ], +}) +``` + +### exclude + +`string[] | undefined` + +Artifact files to exclude relative to `artifacts`. Supports glob patterns. + +```ts +import { defineConfig } from '@wagmi/cli' +import { foundry } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + foundry({ + exclude: [ // [!code focus] + // the following patterns are excluded by default // [!code focus] + 'Common.sol/**', // [!code focus] + 'Components.sol/**', // [!code focus] + 'Script.sol/**', // [!code focus] + 'StdAssertions.sol/**', // [!code focus] + 'StdInvariant.sol/**', // [!code focus] + 'StdError.sol/**', // [!code focus] + 'StdCheats.sol/**', // [!code focus] + 'StdMath.sol/**', // [!code focus] + 'StdJson.sol/**', // [!code focus] + 'StdStorage.sol/**', // [!code focus] + 'StdUtils.sol/**', // [!code focus] + 'Vm.sol/**', // [!code focus] + 'console.sol/**', // [!code focus] + 'console2.sol/**', // [!code focus] + 'test.sol/**', // [!code focus] + '**.s.sol/*.json', // [!code focus] + '**.t.sol/*.json', // [!code focus] + ], // [!code focus] + }), + ], +}) +``` + +### forge + +`{ clean?: boolean | undefined; build?: boolean | undefined; path?: string | undefined; rebuild?: boolean | undefined } | undefined` + +Options for `forge`. + +```ts +import { defineConfig } from '@wagmi/cli' +import { foundry } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + foundry({ + forge: { // [!code focus] + clean: true, // [!code focus] + build: true, // [!code focus] + path: 'path/to/forge', // [!code focus] + rebuild: true, // [!code focus] + }, // [!code focus] + }), + ], +}) +``` + +#### clean + +- Remove build artifacts and cache directories on start up. +- Defaults to `false`. + +#### build + +- Build Foundry project before fetching artifacts. +- Defaults to `true`. + +#### path + +- Path to `forge` executable command. +- Defaults to `forge`. + +#### rebuild + +- Rebuild every time a watched file or directory is changed. Used for setting up [`watch`](/cli/api/commands/generate#w-watch) mode. +- Defaults to `true`. + +### include + +`string[] | undefined` + +Artifact files to include relative to `artifacts`. Supports glob patterns. + +```ts +import { defineConfig } from '@wagmi/cli' +import { foundry } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + foundry({ + include: [ // [!code focus] + // the following patterns are included by default // [!code focus] + '*.json', // [!code focus] + ], // [!code focus] + }), + ], +}) +``` + +### namePrefix + +`string | undefined` + +Prefix to prepend to artifact names. Useful for preventing name collisions between contracts from other sources. + +```ts +import { defineConfig } from '@wagmi/cli' +import { foundry } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + foundry({ // [!code focus] + namePrefix: 'HelloFoundry', // [!code focus] + }), // [!code focus] + ], +}) +``` + +### project + +`string | undefined` + +- Path to Foundry project. +- Defaults to Foundry configuration using `forge config --json` command. + +```ts +import { defineConfig } from '@wagmi/cli' +import { foundry } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + foundry({ // [!code focus] + project: '../hello_foundry', // [!code focus] + }), // [!code focus] + ], +}) +``` \ No newline at end of file diff --git a/site/cli/api/plugins/hardhat.md b/site/cli/api/plugins/hardhat.md new file mode 100644 index 0000000000..38cca9aebe --- /dev/null +++ b/site/cli/api/plugins/hardhat.md @@ -0,0 +1,199 @@ +# hardhat + +Plugin for resolving ABIs from [Hardhat](https://hardhat.org) projects. Supports [`watch`](/cli/api/commands/generate#w-watch) mode. + +```ts +import { hardhat } from '@wagmi/cli/plugins' +``` + +## Usage + +```ts{2,6-8} +import { defineConfig } from '@wagmi/cli' +import { hardhat } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + hardhat({ + project: '../hello_hardhat', + }), + ], +}) +``` + +## Configuration + +```ts +import { type HardhatConfig } from '@wagmi/cli/plugins' +``` + +### artifacts + +`string | undefined` + +- Project's artifacts directory. Same as your project's `artifacts` [path configuration](https://hardhat.org/hardhat-runner/docs/config#path-configuration) option. +- Defaults to `'artifacts/'`. + +```ts +import { defineConfig } from '@wagmi/cli' +import { hardhat } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + hardhat({ + artifacts: 'out/', // [!code focus] + project: '../hello_hardhat', + }), + ], +}) +``` + +### deployments + +`{ [key: string]: address?: Address | Record | undefined } | undefined` + +Mapping of addresses to attach to artifacts. + +```ts +import { defineConfig } from '@wagmi/cli' +import { hardhat } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + hardhat({ + project: '../hello_hardhat', + deployments: { // [!code focus] + Counter: { // [!code focus] + 1: '0x314159265dd8dbb310642f98f50c066173c1259b', // [!code focus] + 5: '0x112234455c3a32fd11230c42e7bccd4a84e02010', // [!code focus] + }, // [!code focus] + }, // [!code focus] + }), + ], +}) +``` + +### exclude + +`string[] | undefined` + +Artifact files to exclude relative to `artifacts`. Supports glob patterns. + +```ts +import { defineConfig } from '@wagmi/cli' +import { hardhat } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + hardhat({ + exclude: [ // [!code focus] + // the following patterns are excluded by default // [!code focus] + 'build-info/**', // [!code focus] + '*.dbg.json', // [!code focus] + ], // [!code focus] + project: '../hello_hardhat', + }), + ], +}) +``` + +### commands + +`{ clean?: string | boolean | undefined; build?: string | boolean | undefined; rebuild?: string | boolean | undefined } | undefined` + +Hardhat command options. + +```ts +import { defineConfig } from '@wagmi/cli' +import { hardhat } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + hardhat({ + commands: { // [!code focus] + clean: 'pnpm hardhat clean', // [!code focus] + build: 'pnpm hardhat compile', // [!code focus] + rebuild: 'pnpm hardhat compile', // [!code focus] + }, // [!code focus] + project: '../hello_hardhat', + }), + ], +}) +``` + +#### clean + +- Remove build artifacts and cache directories on start up. +- Defaults to `'${packageManger} hardhat clean'`. + +#### build + +- Build Foundry project before fetching artifacts. +- Defaults to `'${packageManger} hardhat compile'`. + +#### rebuild + +- Command to run when watched file or directory is changed. Used for setting up [`watch`](/cli/api/commands/generate#w-watch) mode. +- Defaults to `'${packageManger} hardhat compile'`. + +### include + +`string[] | undefined` + +Artifact files to include relative to `artifacts`. Supports glob patterns. + +```ts +import { defineConfig } from '@wagmi/cli' +import { hardhat } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + hardhat({ + include: [ // [!code focus] + // the following patterns are included by default // [!code focus] + '*.json', // [!code focus] + ], // [!code focus] + project: '../hello_hardhat', + }), + ], +}) +``` + +### namePrefix + +`string | undefined` + +Prefix to prepend to artifact names. Useful for preventing name collisions between contracts from other sources. + +```ts +import { defineConfig } from '@wagmi/cli' +import { hardhat } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + hardhat({ + namePrefix: 'HelloHardhat', // [!code focus] + project: '../hello_hardhat', + }), + ], +}) +``` + +### project + +`string` + +Path to Hardhat project. + +```ts +import { defineConfig } from '@wagmi/cli' +import { hardhat } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + hardhat({ + project: '../hello_hardhat', // [!code focus] + }), + ], +}) +``` \ No newline at end of file diff --git a/site/cli/api/plugins/react.md b/site/cli/api/plugins/react.md new file mode 100644 index 0000000000..e78f782c6d --- /dev/null +++ b/site/cli/api/plugins/react.md @@ -0,0 +1,52 @@ +# react + +Plugin for generating type-safe [Wagmi Hooks](/react/api/hooks). + +## Import + +```ts +import { react } from '@wagmi/cli/plugins' +``` + +## Usage + +```ts{2,6} +import { defineConfig } from '@wagmi/cli' +import { react } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + react(), + ], +}) +``` + +## Configuration + +```ts +import { type ReactConfig } from '@wagmi/cli/plugins' +``` + +### getHookName + +`` 'legacy' | ((options: { contractName: string; type: 'read' | 'simulate' | 'watch' | 'write' }) => `use${string}`) `` + +- Function for setting custom hook names. +- Defaults to `` `use${type}${contractName}` ``. For example, `useReadErc20`, `useSimulateErc20`, `useWatchErc20Event`, `useWriteErc20`. +- When `'legacy'` (deprecated), hook names are set to `@wagmi/cli@1` format. + +```ts +import { defineConfig } from '@wagmi/cli' +import { react } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + react({ + getHookName({ contractName, type }) { // [!code focus] + return `use${contractName}__${type}` // [!code focus] + }, // [!code focus] + }), + ], +}) +``` + diff --git a/site/cli/api/plugins/sourcify.md b/site/cli/api/plugins/sourcify.md new file mode 100644 index 0000000000..d965fdde02 --- /dev/null +++ b/site/cli/api/plugins/sourcify.md @@ -0,0 +1,115 @@ +# sourcify + +Plugin for fetching ABIs from [Sourcify](https://sourcify.dev/). Sourcify is a decentralized, open-source, smart contract verification and metadata repository. + +## Import + +```ts +import { sourcify } from '@wagmi/cli/plugins' +``` + +## Usage + +```ts{2,6-13} +import { defineConfig } from '@wagmi/cli' +import { sourcify } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + sourcify({ + contracts: [ + { + name: 'deposit', + address: '0x00000000219ab540356cbb839cbe05303d7705fa', + }, + ], + }), + ], +}) +``` + +## Configuration + +```ts +import { type SourcifyConfig } from '@wagmi/cli/plugins' +``` + +### cacheDuration + +`number | undefined` + +- Duration in milliseconds to cache ABIs. +- Defaults to `1_800_000` (30 minutes). + +```ts +import { defineConfig } from '@wagmi/cli' +import { sourcify } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + sourcify({ + cacheDuration: 300_000, // [!code focus] + chainId: 100, + contracts: [ + { + name: 'Deposit', + address: '0x00000000219ab540356cbb839cbe05303d7705fa', + }, + ], + }), + ], +}) +``` + +### chainId + +`number` + +Chain ID to use for fetching ABI. If `address` is an object, `chainId` is used to select the address. See [Sourcify docs](https://docs.sourcify.dev/docs/chains) for supported chains. + +```ts +import { defineConfig } from '@wagmi/cli' +import { sourcify } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + sourcify({ + chainId: 100, // [!code focus] + contracts: [ + { + name: 'Community', + address: { + 100: '0xC4c622862a8F548997699bE24EA4bc504e5cA865', + 137: '0xC4c622862a8F548997699bE24EA4bc504e5cA865', + }, + }, + ], + }), + ], +}) +``` + +### contracts + +`{ name: string; address?: Address | Record | undefined }[]` + +Contracts to fetch ABIs for. + +```ts +import { defineConfig } from '@wagmi/cli' +import { sourcify } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + sourcify({ + chainId: 100, + contracts: [ // [!code focus] + { // [!code focus] + name: 'Deposit', // [!code focus] + address: '0x00000000219ab540356cbb839cbe05303d7705fa', // [!code focus] + }, // [!code focus] + ], // [!code focus] + }), + ], +}) +``` diff --git a/site/cli/config/configuring-cli.md b/site/cli/config/configuring-cli.md new file mode 100644 index 0000000000..9e8e11fae3 --- /dev/null +++ b/site/cli/config/configuring-cli.md @@ -0,0 +1,124 @@ +# Configuring CLI + +When running `wagmi` from the command line, `@wagmi/cli` will automatically try to resolve a config file named `wagmi.config.js` or `wagmi.config.ts` inside the project root. The most basic config file looks like this: + +::: code-group +```js [wagmi.config.js] +export default { + // config options +} +``` +::: + +Note `@wagmi/cli` supports using ES modules syntax in the config file even if the project is not using native Node ESM, e.g. `"type": "module"` in package.json. In this case, the config file is auto pre-processed before load. + +You can also explicitly specify a config file to use with the `--config`/`-c` CLI option (resolved relative to the current directory): + +```bash +wagmi --config my-config.js +``` + +To scaffold a config file quickly, check out the [`init`](/cli/api/commands/init) command. + +## Config Intellisense + +Since Wagmi CLI ships with TypeScript typings, you can use your editor's intellisense with [JSDoc](https://jsdoc.app) type hints: + +::: code-group +```js [wagmi.config.js] +/** @type {import('@wagmi/cli').Config} */ +export default { + // ... +} +``` +::: + +Alternatively, you can use the `defineConfig` utility which should provide intellisense without the need for JSDoc annotations: + +::: code-group +```js [wagmi.config.js] +import { defineConfig } from '@wagmi/cli' + +export default defineConfig({ + // ... +}) +``` +::: + +Wagmi CLI also directly supports TypeScript config files. You can use `wagmi.config.ts` with the `defineConfig` helper as well. + +## Conditional Config + +If the config needs to conditionally determine options based on the environment, it can export a function instead: + +::: code-group +```js [wagmi.config.js] +export default defineConfig(() => { + if (process.env.NODE_ENV === 'dev') { + return { + // dev specific config + } + } else { + return { + // production specific config + } + } +}) +``` +::: + +## Async Config + +If the config needs to call async function, it can export a async function instead: + +::: code-group +```js [wagmi.config.js] +export default defineConfig(async () => { + const data = await asyncFunction() + return { + // ... + } +}) +``` +::: + +This can be useful for resolving external resources from the network or filesystem that are required for configuration ahead of running a command. + +## Array Config + +The config can also be represented either as a pre-defined array or returned as an array from a function: + +::: code-group +```js [wagmi.config.js] +export default defineConfig([ + { + // config 1 + }, + { + // config 2 + }, +]) +``` +::: + +## Environment Variables + +Environmental Variables can be obtained from `process.env` as usual. + +Note that Wagmi CLI doesn't load `.env` files by default as the files to load can only be determined after evaluating the config. However, you can use the exported `loadEnv` utility to load the specific `.env` files if needed. + +::: code-group +```js [wagmi.config.js] +import { defineConfig, loadEnv } from '@wagmi/cli' + +export default defineConfig(() => { + const env = loadEnv({ + mode: process.env.NODE_ENV, + envDir: process.cwd(), + }) + return { + // ... + } +}) +``` +::: \ No newline at end of file diff --git a/site/cli/config/options.md b/site/cli/config/options.md new file mode 100644 index 0000000000..04a2cd2d56 --- /dev/null +++ b/site/cli/config/options.md @@ -0,0 +1,132 @@ +# Config Options + +Configuration options for Wagmi CLI. + +## contracts + +`ContractConfig[] | undefined` + +Array of contracts to use when running [commands](/cli/api/commands). `abi` and `name` are required, all other properties are optional. + +### address + +`Address | Record | undefined` + +Contract address or addresses. Accepts an object `{ [chainId]: address }` for targeting specific chains. + +::: code-group +```ts {6,11-14} [wagmi.config.ts] +export default { + out: 'src/generated.ts', + contracts: [ + { + abi: […], + address: '0x…', + name: 'MyCoolContract', + }, + { + abi: […], + address: { + 1: '0xfoo…', + 5: '0xbar…', + }, + name: 'MyCoolMultichainContract' + } + ], +} +``` +::: + +### abi + +`Abi` + +ABI for contract. Used by [plugins](/cli/api/plugins) to generate code base on properties. + +::: code-group +```ts {5} [wagmi.config.ts] +export default { + out: 'src/generated.ts', + contracts: [ + { + abi: […], + name: 'MyCoolContract' + }, + ], +} +``` +::: + +### name + +`string` + +Name of contract. Must be unique. Used by [plugins](/cli/api/plugins) to name generated code. + +::: code-group +```ts {6} [wagmi.config.ts] +export default { + out: 'src/generated.ts', + contracts: [ + { + abi: […], + name: 'MyCoolContract' + }, + ], +} +``` +::: + +## out + +`string` + +Path to output generated code. Must be unique per config. Use an [Array Config](/cli/config/configuring-cli#array-config) for multiple outputs. + +::: code-group +```ts {2} [wagmi.config.ts] +export default { + out: 'src/generated.ts', + contracts: [ + { + abi: […], + name: 'MyCoolContract' + }, + ], +} +``` +::: + +## plugins + +`Plugin[] | undefined` + +Plugins to use and their configuration. + +Wagmi CLI has multiple [built-in plugins](/cli/api/plugins) that are used to manage ABIs, generate code, etc. + +::: code-group +```ts {1,5-20} [wagmi.config.ts] +import { etherscan, react } from '@wagmi/cli/plugins' + +export default { + out: 'src/generated.js', + plugins: [ + etherscan({ + apiKey: process.env.ETHERSCAN_API_KEY, + chainId: 5, + contracts: [ + { + name: 'EnsRegistry', + address: { + 1: '0x314159265dd8dbb310642f98f50c066173c1259b', + 5: '0x112234455c3a32fd11230c42e7bccd4a84e02010', + }, + }, + ], + }), + react(), + ], +} +``` +::: diff --git a/site/cli/create-wagmi.md b/site/cli/create-wagmi.md new file mode 100644 index 0000000000..bdf8dda308 --- /dev/null +++ b/site/cli/create-wagmi.md @@ -0,0 +1,75 @@ +# create-wagmi + +## Overview + +create-wagmi is a command line interface (CLI) for scaffolding new Wagmi projects. + +## Usage + +::: code-group +```bash [pnpm] +pnpm create wagmi +``` +```bash [npm] +npm create wagmi@latest +``` +```bash [yarn] +yarn create wagmi +``` +```bash [bun] +bun create wagmi +``` +::: + +## Options + +### `-t`, `--template` + +You can specify a custom [template](#templates) by passing the `--template`/`-t` flag: + +::: code-group +```bash [pnpm] +pnpm create wagmi --template next +``` +```bash [npm] +npm create wagmi@latest --template next +``` +```bash [yarn] +yarn create wagmi --template next +``` +```bash [bun] +bun create wagmi --template next +``` +::: + +### `--bun`/`--npm`/`--pnpm`/`--yarn` + +Use a specific package manager to install dependencies. By default, `create-wagmi` will use the package manager you used to run the command. + +### `-h`, `--help` + +Prints the help message. + +### `-v`, `--version` + +Prints the CLI version. + +## Templates + +`create-wagmi` currently comes with the following templates: + +- `next`: A Next.js Wagmi project. +- `nuxt`: A Nuxt Wagmi project. +- `vite-react`: A Vite (React) Wagmi project. +- `vite-vanilla`: A Vite Wagmi Core project. +- `vite-vue`: A Vite (Vue) Wagmi project. + +If you do not specify the template on the command line, you will be prompted to select a framework and variant. + +- **React** : A React project. + - **Vite** : A React + Vite Wagmi project (`vite-react`). + - **Next** : A React + Next Wagmi project (`next`). +- **Vue**: A Vue project. + - **Vite**: A Vue + Vite Wagmi project (`vite-vue`). + - **Nuxt**: A Vue + Nuxt Wagmi project (`nuxt`). +- **Vanilla**: A Vite Wagmi project without React (`vite-vanilla`). diff --git a/site/cli/getting-started.md b/site/cli/getting-started.md new file mode 100644 index 0000000000..ccf2d2b606 --- /dev/null +++ b/site/cli/getting-started.md @@ -0,0 +1,167 @@ +# Getting Started + +## Overview + +Wagmi CLI is a command line interface for managing ABIs (from Etherscan/block explorers, Foundry/Hardhat projects, etc.), generating code (e.g. React Hooks), and much more. It makes working with Ethereum easier by automating manual work so you can build faster. You can learn more about the rationale behind the project in the [Why Wagmi CLI](/cli/why) section. + +## Manual Installation + +To manually add Wagmi CLI to your project, install the required packages. + +::: code-group +```bash [pnpm] +pnpm add -D @wagmi/cli +``` + +```bash [npm] +npm install --save-dev @wagmi/cli +``` + +```bash [yarn] +yarn add -D @wagmi/cli +``` + +```bash [bun] +bun add -D @wagmi/cli +``` +::: + +## Create Config File + +Run the `init` command to generate a configuration file: either `wagmi.config.ts` if TypeScript is detected, otherwise `wagmi.config.js`. You can also create the configuration file manually. See [Configuring CLI](/cli/config/configuring-cli) for more info. + +::: code-group +```bash [pnpm] +pnpm wagmi init +``` + +```bash [npm] +npx wagmi init +``` + +```bash [yarn] +yarn wagmi init +``` + +```bash [bun] +bun wagmi init +``` +::: + +The generated configuration file will look something like this: + +::: code-group +```ts [wagmi.config.ts] +import { defineConfig } from '@wagmi/cli' + +export default defineConfig({ + out: 'src/generated.ts', + contracts: [], + plugins: [], +}) +``` +::: + +## Add Contracts And Plugins + +Once the configuration file is set up, you can add contracts and plugins to it. These contracts and plugins are used to manage ABIs (fetch from block explorers, resolve from the file system, etc.), generate code (React hooks, etc.), and much more! + +For example, we can add the ERC-20 contract from Viem, and the [`etherscan`](/cli/api/plugins/etherscan) and [`react`](/cli/api/plugins/react) plugins. + +::: code-group +```ts{2,3,9-12,15-27,28} [wagmi.config.ts] +import { defineConfig } from '@wagmi/cli' +import { etherscan, react } from '@wagmi/cli/plugins' +import { erc20Abi } from 'viem' +import { mainnet, sepolia } from 'wagmi/chains' + +export default defineConfig({ + out: 'src/generated.ts', + contracts: [ + { + name: 'erc20', + abi: erc20Abi, + }, + ], + plugins: [ + etherscan({ + apiKey: process.env.ETHERSCAN_API_KEY!, + chainId: mainnet.id, + contracts: [ + { + name: 'EnsRegistry', + address: { + [mainnet.id]: '0x314159265dd8dbb310642f98f50c066173c1259b', + [sepolia.id]: '0x112234455c3a32fd11230c42e7bccd4a84e02010', + }, + }, + ], + }), + react(), + ], +}) +``` +::: + +## Run Code Generation + +Now that we added a few contracts and plugins to the configuration file, we can run the [`generate`](/cli/api/commands/generate) command to resolve ABIs and generate code to the `out` file. + +::: code-group +```bash [pnpm] +pnpm wagmi generate +``` + +```bash [npm] +npx wagmi generate +``` + +```bash [yarn] +yarn wagmi generate +``` + +```bash [bun] +bun wagmi generate +``` +::: + +In this example, the `generate` command will do the following: + +- Validate the `etherscan` and `react` plugins +- Fetch and cache the ENS Registry ABI from the Mainnet Etherscan API +- Pull in the `erc20Abi` using the name `'ERC20'` +- Generate React Hooks for both ABIs +- Save ABIs, ENS Registry deployment addresses, and React Hooks to the `out` file + +## Use Generated Code + +Once `out` is created, you can start using the generated code in your project. + +```ts +import { useReadErc20, useReadErc20BalanceOf } from './generated' + +// Use the generated ERC-20 read hook +const { data } = useReadErc20({ + address: '0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48', + functionName: 'balanceOf', + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e'], +}) + +// Use the generated ERC-20 "balanceOf" hook +const { data } = useReadErc20BalanceOf({ + address: '0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48', + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e'], +}) +``` + +::: tip +Instead of committing the `out` file, you likely want to add `out` to your `.gitignore` and run `generate` during the build process or before you start your dev server in a `"predev"` script. +::: + +## Next Steps + +For more information on what to do next, check out the following topics. + +- [**Configuring CLI**](/cli/config/configuring-cli) Learn how to configure the CLI to work best for your project. +- [**Commands**](/cli/api/commands) Learn more about the CLI commands and how to use them. +- [**Plugins**](/cli/api/plugins) Browse the collection of plugins and set them up with your config. diff --git a/site/cli/guides/migrate-from-v1-to-v2.md b/site/cli/guides/migrate-from-v1-to-v2.md new file mode 100644 index 0000000000..2db0fef568 --- /dev/null +++ b/site/cli/guides/migrate-from-v1-to-v2.md @@ -0,0 +1,51 @@ +--- +title: Migrate from v1 to v2 +titleTemplate: Wagmi CLI +description: Guide for migrating from Wagmi CLI v1 to v2. +--- + +# Migrate from v1 to v2 + +To get started, install the latest version of the Wagmi CLI. + +::: code-group +```bash-vue [pnpm] +pnpm add @wagmi/cli +``` + +```bash-vue [npm] +npm install @wagmi/cli +``` + +```bash-vue [yarn] +yarn add @wagmi/cli +``` + +```bash-vue [bun] +bun add @wagmi/cli +``` +::: + +::: info Not ready to migrate yet? +The Wagmi CLI v1 docs are still available at [1.x.wagmi.sh/cli](https://1.x.wagmi.sh/cli). +::: + +## Changed generated action and hook names + +Generated action and hook names now align with [Wagmi v2 naming conventions](/react/guides/migrate-from-v1-to-v2#renamed-hooks). If you want hooks to still follow Wagmi v1 naming conventions, set [`getActionName`](/cli/api/plugins/actions#getactionname) and [`getHookName`](/cli/api/plugins/react#gethookname) to `'legacy'`. + +```ts +import { defineConfig } from '@wagmi/cli' +import { actions, react } from '@wagmi/cli/plugins' + +export default defineConfig({ + plugins: [ + actions({ + getActionName: 'legacy', // [!code focus] + }), + react({ + getHookName: 'legacy', // [!code focus] + }), + ], +}) +``` diff --git a/site/cli/installation.md b/site/cli/installation.md new file mode 100644 index 0000000000..649565ca34 --- /dev/null +++ b/site/cli/installation.md @@ -0,0 +1,60 @@ +# Installation + +Install Wagmi CLI via your package manager. + +## Package Manager + +Install the required package. + +::: code-group +```bash [pnpm] +pnpm add @wagmi/cli +``` + +```bash [npm] +npm install @wagmi/cli +``` + +```bash [yarn] +yarn add @wagmi/cli +``` + +```bash [bun] +bun add @wagmi/cli +``` +::: + +## Using Unreleased Commits + +If you can't wait for a new release to test the latest features, you can either install from the `canary` tag (tracks the [`main`](https://github.com/wevm/wagmi/tree/main) branch). + +::: code-group +```bash [pnpm] +pnpm add @wagmi/cli@canary +``` + +```bash [npm] +npm install @wagmi/cli@canary +``` + +```bash [yarn] +yarn add @wagmi/cli@canary +``` + +```bash [bun] +bun add @wagmi/cli@canary +``` +::: + +Or clone the [Wagmi repo](https://github.com/wevm/wagmi) to your local machine, build, and link it yourself. + +```bash +git clone https://github.com/wevm/wagmi.git +cd wagmi +pnpm install +pnpm build +cd packages/cli +pnpm link --global +``` + +Then go to the project where you are using the Wagmi CLI and run `pnpm link --global @wagmi/cli` (or the package manager that you used to link Wagmi CLI globally). \ No newline at end of file diff --git a/site/cli/why.md b/site/cli/why.md new file mode 100644 index 0000000000..a626c46006 --- /dev/null +++ b/site/cli/why.md @@ -0,0 +1,92 @@ +# Why Wagmi CLI + +## The Problem + +The most common way to interact with smart contracts is through [Application Binary Interfaces](https://docs.soliditylang.org/en/latest/abi-spec.html). ABIs describe smart contracts' public functionality (e.g. functions, events, errors) as well as how to encode and decode related data (e.g. arguments and results). + +While ABIs are extremely powerful, there isn't a uniform way developers manage them in their apps. Developers do a bunch of different things, like: + +- Publish packages on npm containing ABIs +- Write custom scripts to fetch ABIs from external sources +- Compile contracts into application project +- Copy and paste ABIs from local projects or block explorers + +All these approaches take time that you could spend doing more important things, like interacting with your smart contracts! + +## The Solution + +The Wagmi CLI is an attempt to automate manual work so you can build faster. In short, the CLI manages ABIs and generates code. It takes ABIs as inputs and outputs ABIs and generated code. For example, the [Etherscan plugin](/cli/api/plugins/etherscan) allows you to fetch ABIs across multiple chains and deployments and immediately start importing them into your project. + +Code generation is another big advantage of the CLI. Using the [React plugin](/cli/api/plugins/react), you can generate [Wagmi Hooks](/react/api/hooks) for ABIs. When you combine this with the CLI's different ABI sources, like Etherscan, Foundry/Hardhat, and more, you reduce a lot of boilerplate code. + +::: code-group +```ts [Diff] +import { useReadContract, useWriteContract } from 'wagmi' // [!code --] +import { froggyFriendsAbi, froggyFriendsAddress } from './generated' // [!code --] +import { useReadFroggyFriends, useWriteFroggyFriends } from './generated' // [!code ++] + +function App() { + const { data } = useReadContract({ // [!code --] + const { data } = useReadFroggyFriends({ // [!code ++] + abi: froggyFriendsAbi, // [!code --] + address: froggyFriendsAddress, // [!code --] + functionName: 'tokenURI', + args: [123n], + }) + + const { write } = useWriteContract() // [!code --] + const { write } = useWriteFroggyFriends() // [!code ++] + const onClick = React.useCallback(() => { + write({ + abi: froggyFriendsAbi, // [!code --] + address: froggyFriendsAddress, // [!code --] + functionName: 'mint', + args: ['foo', 123n], + }) + }, [write]) +} +``` +```ts [Before] +import { useReadContract, useWriteContract } from 'wagmi' +import { froggyFriendsAbi, froggyFriendsAddress } from './generated' + +function App() { + const { data } = useReadContract({ + abi: froggyFriendsAbi, + address: froggyFriendsAddress, + functionName: 'tokenURI', + args: [123n], + }) + + const { write } = useWriteContract() + const onClick = React.useCallback(() => { + write({ + abi: froggyFriendsAbi, + address: froggyFriendsAddress, + functionName: 'mint', + args: ['foo', 123n], + }) + }, [write]) +} +``` +```ts [After] +import { useReadFroggyFriends, useWriteFroggyFriends } from './generated' + +function App() { + const { data } = useReadFroggyFriends({ + functionName: 'tokenURI', + args: [123n], + }) + + const { write } = useWriteFroggyFriends() + const onClick = React.useCallback(() => { + write({ + functionName: 'mint', + args: ['foo', 123n], + }) + }, [write]) +} +``` +::: + +Finally, the Wagmi CLI supports popular smart contract development tools, [Foundry](/cli/api/plugins/foundry) and [Hardhat](/cli/api/plugins/hardhat). You can run the CLI in [watch mode](/cli/api/commands/generate#w-watch), make changes to your contracts, and the CLI will automatically pick up ABI changes and run plugins over those changes. A major boon to working a monorepo and shortening the feedback loop across your stack. diff --git a/site/components/Browsers.vue b/site/components/Browsers.vue new file mode 100644 index 0000000000..4367018bc9 --- /dev/null +++ b/site/components/Browsers.vue @@ -0,0 +1,9 @@ + + + diff --git a/site/components/SearchChains.vue b/site/components/SearchChains.vue new file mode 100644 index 0000000000..b649a6202e --- /dev/null +++ b/site/components/SearchChains.vue @@ -0,0 +1,82 @@ + + + + + diff --git a/site/core/api/actions.md b/site/core/api/actions.md new file mode 100644 index 0000000000..664cd9a86a --- /dev/null +++ b/site/core/api/actions.md @@ -0,0 +1,25 @@ + + +# Actions + +Actions for accounts, wallets, contracts, transactions, signing, ENS, and more. + +## Import + +```ts +import { getAccount } from '@wagmi/core' +``` + +## Available Actions + + diff --git a/site/core/api/actions/call.md b/site/core/api/actions/call.md new file mode 100644 index 0000000000..52f202a570 --- /dev/null +++ b/site/core/api/actions/call.md @@ -0,0 +1,340 @@ + + +# call + +Action for executing a new message call immediately without submitting a transaction to the network. + +## Import + +```ts +import { call } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { config } from './config' + +await call(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts twoslash +import { type CallParameters } from '@wagmi/core' +``` + +### account + +`Account | Address | undefined` + +The Account to call from. + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { config } from './config' + +await call(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', // [!code focus] + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### data + +`` `0x${string}` | undefined `` + +A contract hashed method call with encoded args. + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { config } from './config' + +await call(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### to + +`Address | undefined` + +The contract address or recipient. + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { config } from './config' + +await call(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### accessList + +`AccessList | undefined` + +The access list. + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { config } from './config' + +await call(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + accessList: [ // [!code focus:6] + { + address: '0x1', + storageKeys: ['0x1'], + }, + ], + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### gas + +`bigint | undefined` + +The gas provided for transaction execution. + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { config } from './config' + +await call(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + gas: 1_000_000n, // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### gasPrice + +`bigint | undefined` + +The price (in wei) to pay per gas. Only applies to [Legacy Transactions](https://viem.sh/docs/glossary/terms.html#legacy-transaction). + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { parseGwei } from 'viem' +import { config } from './config' + +await call(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + gasPrice: parseGwei('20'), // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### maxFeePerGas + +`bigint | undefined` + +Total fee per gas (in wei), inclusive of `maxPriorityFeePerGas`. Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { parseGwei } from 'viem' +import { config } from './config' + +await call(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + maxFeePerGas: parseGwei('20'), // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### maxPriorityFeePerGas + +`bigint | undefined` + +Max priority fee per gas (in wei). Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { parseGwei } from 'viem' +import { config } from './config' + +await call(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + maxFeePerGas: parseGwei('20'), + maxPriorityFeePerGas: parseGwei('2'), // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### nonce + +`number | undefined` + +Unique number identifying this transaction. + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { config } from './config' + +await call(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + nonce: 420, // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### value + +`bigint | undefined` + +Value (in wei) sent with this transaction. + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +await call(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockNumber + +`number | undefined` + +The block number to perform the call against. + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { config } from './config' + +await call(config, { + blockNumber: 15121123n, // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +The block tag to perform the call against. + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { config } from './config' + +await call(config, { + blockTag: 'safe', // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +The block tag to perform the call against. + +::: code-group +```ts [index.ts] +import { call } from '@wagmi/core' +import { config } from './config' +import { mainnet } from '@wagmi/core/chains' + +await call(config, { + chainId: mainnet.id, // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts twoslash +import { type CallReturnType } from '@wagmi/core' +``` + +`{ data: 0x${string} }` + +The call data. + +## Error + +```ts twoslash +import { type CallErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`call`](https://viem.sh/docs/actions/public/call.html) diff --git a/site/core/api/actions/connect.md b/site/core/api/actions/connect.md new file mode 100644 index 0000000000..30d04a85e3 --- /dev/null +++ b/site/core/api/actions/connect.md @@ -0,0 +1,102 @@ + + +# connect + +Action for connecting accounts with [connectors](/core/api/connectors). + +## Import + +```ts +import { connect } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { connect } from '@wagmi/core' +import { injected } from '@wagmi/connectors' +import { config } from './config' + +const result = await connect(config, { connector: injected() }) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type ConnectParameters } from '@wagmi/core' +``` + +### chainId + +`number | undefined` + +Chain ID to connect to. + +Not all connectors support connecting directly to a `chainId` (e.g. they don't support programmatic chain switching). In those cases, the connector will connect to whatever chain the connector's provider is connected to. + +::: code-group +```ts [index.ts] +import { connect } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { injected } from '@wagmi/connectors' +import { config } from './config' + +const result = await connect(config, { + chainId: mainnet.id, // [!code focus] + connector: injected(), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`CreateConnectorFn | Connector` + +[Connector](/core/api/connectors) to connect with. + +::: code-group +```ts [index.ts] +import { connect } from '@wagmi/core' +import { injected } from '@wagmi/connectors' // [!code focus] +import { config } from './config' + +const result = await connect(config, { + connector: injected(), // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type ConnectReturnType } from '@wagmi/core' +``` + +### accounts + +`readonly [Address, ...Address[]]` + +Connected accounts from connector. + +### chainId + +`number` + +Connected chain ID from connector. + +## Error + +```ts +import { type ConnectErrorType } from '@wagmi/core' +``` + + diff --git a/site/core/api/actions/deployContract.md b/site/core/api/actions/deployContract.md new file mode 100644 index 0000000000..3cdbfd130f --- /dev/null +++ b/site/core/api/actions/deployContract.md @@ -0,0 +1,264 @@ + + +# deployContract + +Action for deploying a contract to the network, given bytecode, and constructor arguments. + +## Import + +```ts +import { deployContract } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { deployContract } from '@wagmi/core' +import { wagmiAbi } from './abi' +import { config } from './config' + +const result = await deployContract(config, { + abi: wagmiAbi, + bytecode: '0x608060405260405161083e38038061083e833981016040819052610...', +}) +``` +```ts [abi.ts] +export const wagmiAbi = [ + ... + { + inputs: [], + stateMutability: "nonpayable", + type: "constructor", + }, + ... +] as const +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Deploying with Constructor Args + +::: code-group +```ts [index.ts] +import { deployContract } from '@wagmi/core' +import { wagmiAbi } from './abi' +import { config } from './config' + +const result = await deployContract(config, { + abi: wagmiAbi, + args: [69420], + bytecode: '0x608060405260405161083e38038061083e833981016040819052610...', +}) +``` +```ts [abi.ts] +export const wagmiAbi = [ + ... + { + inputs: [{ name: "x", type: "uint32" }], + stateMutability: "nonpayable", + type: "constructor", + }, + ... +] as const; +``` +<<< @/snippets/core/config.ts[config.ts] +::: + + +## Parameters + +```ts +import { type DeployContractParameters } from '@wagmi/core' +``` + +### abi + +`Abi` + +The contract's ABI. + +::: code-group +```ts [index.ts] +import { deployContract } from '@wagmi/core' +import { wagmiAbi } from './abi' +import { config } from './config' + +const result = await deployContract(config, { + abi: wagmiAbi, // [!code focus] + args: [69420], + bytecode: '0x608060405260405161083e38038061083e833981016040819052610...', +}) +``` +```ts [abi.ts] +export const wagmiAbi = [ + ... + { + inputs: [{ name: "x", type: "uint32" }], + stateMutability: "nonpayable", + type: "constructor", + }, + ... +] as const; +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### account + +`Address | Account | undefined` + +Account to use when deploying a contract. Throws if account is not found on [`connector`](#connector). + +::: code-group +```ts [index.ts] +import { deployContract } from '@wagmi/core' +import { wagmiAbi } from './abi' +import { config } from './config' + +const result = await deployContract(config, { + abi: wagmiAbi, + account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + args: [69420], + bytecode: '0x608060405260405161083e38038061083e833981016040819052610...', +}) +``` +```ts [abi.ts] +export const wagmiAbi = [ + ... + { + inputs: [{ name: "x", type: "uint32" }], + stateMutability: "nonpayable", + type: "constructor", + }, + ... +] as const; +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### args + +`readonly unknown[] | undefined` + +- Arguments to pass when deploying the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```ts [index.ts] +import { deployContract } from '@wagmi/core' +import { wagmiAbi } from './abi' +import { config } from './config' + +const result = await deployContract(config, { + abi: wagmiAbi, + args: [69420], // [!code focus] + bytecode: '0x608060405260405161083e38038061083e833981016040819052610...', +}) +``` +```ts [abi.ts] +export const wagmiAbi = [ + ... + { + inputs: [{ name: "x", type: "uint32" }], + stateMutability: "nonpayable", + type: "constructor", + }, + ... +] as const; +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### bytecode + +`Hex` + +The contract's bytecode. + +::: code-group +```ts [index.ts] +import { deployContract } from '@wagmi/core' +import { wagmiAbi } from './abi' +import { config } from './config' + +const result = await deployContract(config, { + abi: wagmiAbi, + args: [69420], + bytecode: '0x608060405260405161083e38038061083e833981016040819052610...', // [!code focus] +}) +``` +```ts [abi.ts] +export const wagmiAbi = [ + ... + { + inputs: [{ name: "x", type: "uint32" }], + stateMutability: "nonpayable", + type: "constructor", + }, + ... +] as const; +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +- Connector to use when deploying a contract. +- Defaults to current connector. + +::: code-group +```ts [index.ts] +import { getAccount, deployContract } from '@wagmi/core' +import { wagmiAbi } from './abi' +import { config } from './config' + +const { connector } = getAccount(config) +const result = await deployContract(config, { + abi: wagmiAbi, + args: [69420], + bytecode: '0x608060405260405161083e38038061083e833981016040819052610...', + connector, // [!code focus] +}) +``` +```ts [abi.ts] +export const wagmiAbi = [ + ... + { + inputs: [{ name: "x", type: "uint32" }], + stateMutability: "nonpayable", + type: "constructor", + }, + ... +] as const; +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type DeployContractReturnType } from '@wagmi/core' +``` + +[`Hash`](https://viem.sh/docs/glossary/types.html#hash) + +Transaction hash. + +## Error + +```ts +import { type DeployContractErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`deployContract`](https://viem.sh/docs/contract/deployContract) diff --git a/site/core/api/actions/disconnect.md b/site/core/api/actions/disconnect.md new file mode 100644 index 0000000000..6c77fb5c74 --- /dev/null +++ b/site/core/api/actions/disconnect.md @@ -0,0 +1,60 @@ + + +# disconnect + +Action for disconnecting connections. + +## Import + +```ts +import { disconnect } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { disconnect } from '@wagmi/core' +import { config } from './config' + +await disconnect(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type DisconnectParameters } from '@wagmi/core' +``` + +### connector + +`Connector | undefined` + +[Connector](/core/api/connectors) to disconnect with. + +::: code-group +```ts [index.ts] +import { disconnect, getAccount } from '@wagmi/core' +import { config } from './config' + +const { connector } = getAccount(config) +const result = await disconnect(config, { + connector, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Error + +```ts +import { type DisconnectErrorType } from '@wagmi/core' +``` + + diff --git a/site/core/api/actions/estimateFeesPerGas.md b/site/core/api/actions/estimateFeesPerGas.md new file mode 100644 index 0000000000..ce804efeb9 --- /dev/null +++ b/site/core/api/actions/estimateFeesPerGas.md @@ -0,0 +1,139 @@ + + +# estimateFeesPerGas + +Returns an estimate for the fees per gas (in wei) for a transaction to be likely included in the next block. + +## Import + +```ts +import { estimateFeesPerGas } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { estimateFeesPerGas } from '@wagmi/core' +import { config } from './config' + +const result = await estimateFeesPerGas(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type EstimateFeesPerGasParameters } from '@wagmi/core' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { estimateFeesPerGas } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const result = await estimateFeesPerGas(config, { + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### formatUnits + +`'ether' | 'gwei' | 'wei' | number | undefined` + +- Units to use when formatting result. +- Defaults to `'ether'`. + +::: code-group +```ts [index.ts] +import { estimateFeesPerGas } from '@wagmi/core' +import { config } from './config' + +const feesPerGas = estimateFeesPerGas(config, { + formatUnits: 'ether', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### type + +`'legacy' | 'eip1559'` + +- Fee value type. +- Defaults to `'eip1559'` + +::: code-group +```ts [index.ts] +import { estimateFeesPerGas } from '@wagmi/core' +import { config } from './config' + +const result = estimateFeesPerGas(config, { + type: 'legacy', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type EstimateFeesPerGasReturnType } from '@wagmi/core' +``` + +[`FeeValues`](https://viem.sh/docs/glossary/types.html#feevalues) + +An estimate (in wei) for the fees per gas. + +### formatted + +`{ gasPrice: string | undefined; maxFeePerGas: string | undefined; maxPriorityFeePerGas: string | undefined; }` + +Object of formatted values using [`formatUnits`](#formatunits). + +### gasPrice + +`bigint | undefined` + +- Gas price. +- When [`type`](#type) is `'eip1559'`, value is `undefined`. + +### maxFeePerGas + +`bigint | undefined` + +- Max fee per gas. +- When [`type`](#type) is `'legacy'`, value is `undefined`. + +### maxPriorityFeePerGas + +`bigint | undefined` + +- Max priority fee per gas. +- When [`type`](#type) is `'legacy'`, value is `undefined`. + +## Error + +```ts +import { type EstimateFeesPerGasErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`estimateFeesPerGas`](https://viem.sh/docs/actions/public/estimateFeesPerGas.html) diff --git a/site/core/api/actions/estimateGas.md b/site/core/api/actions/estimateGas.md new file mode 100644 index 0000000000..cbeb1ba40d --- /dev/null +++ b/site/core/api/actions/estimateGas.md @@ -0,0 +1,340 @@ + + +# estimateGas + +Action for estimating the gas necessary to complete a transaction without submitting it to the network. + +## Import + +```ts +import { estimateGas } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type EstimateGasParameters } from '@wagmi/core' +``` + +### accessList + +`AccessList | undefined` + +The access list. + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + accessList: [{ // [!code focus] + address: '0x1', // [!code focus] + storageKeys: ['0x1'], // [!code focus] + }], // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### account + +`Address | Account | undefined` + +Account to use when estimating gas. + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + account: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +Chain ID to target when estimating gas. + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + chainId: mainnet.id, // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +Connector to estimate with. If no [`account`](#account) is provided, will use default account from connector. + +::: code-group +```ts [index.ts] +import { getConnections, estimateGas } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const connections = getConnections(config) +const result = await estimateGas(config, { + connector: connections[0]?.connector, // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### data + +`` `0x${string}` | undefined `` + +A contract hashed method call with encoded args. + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### gas + +`bigint | undefined` + +Gas provided for transaction execution. + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + gas: parseGwei('20'), // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### gasPrice + +`bigint | undefined` + +The price in wei to pay per gas. Only applies to [Legacy Transactions](https://viem.sh/docs/glossary/terms.html#legacy-transaction). + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + gasPrice: parseGwei('20'), // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### maxFeePerGas + +`bigint | undefined` + +Total fee per gas in wei, inclusive of [`maxPriorityFeePerGas`](#maxPriorityFeePerGas). Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + maxFeePerGas: parseGwei('20'), // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### maxPriorityFeePerGas + +`bigint | undefined` + +Max priority fee per gas in wei. Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + maxFeePerGas: parseGwei('20'), + maxPriorityFeePerGas: parseGwei('2'), // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### nonce + +`number` + +Unique number identifying this transaction. + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + nonce: 123, // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### to + +`Address | undefined` + +The transaction recipient or contract address. + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### type + +`'legacy' | 'eip1559' | 'eip2930' | undefined` + +Optional transaction request type to narrow parameters. + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + type: 'eip1559', // [!code focus] + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### value + +`bigint | undefined` + +Value in wei sent with this transaction. + +::: code-group +```ts [index.ts] +import { estimateGas } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await estimateGas(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type EstimateGasReturnType } from '@wagmi/core' +``` + +`bigint` + +The gas estimate in wei. + +## Error + +```ts +import { type EstimateGasErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`estimateGas`](https://viem.sh/docs/actions/public/estimateGas.html) diff --git a/site/core/api/actions/estimateMaxPriorityFeePerGas.md b/site/core/api/actions/estimateMaxPriorityFeePerGas.md new file mode 100644 index 0000000000..906e98b931 --- /dev/null +++ b/site/core/api/actions/estimateMaxPriorityFeePerGas.md @@ -0,0 +1,74 @@ + + +# estimateMaxPriorityFeePerGas + +Returns an estimate for the max priority fee per gas (in wei) for a transaction to be likely included in the next block. + +## Import + +```ts +import { estimateMaxPriorityFeePerGas } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { estimateMaxPriorityFeePerGas } from '@wagmi/core' +import { config } from './config' + +const result = await estimateMaxPriorityFeePerGas(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type EstimateFeesPerGasParameters } from '@wagmi/core' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { estimateMaxPriorityFeePerGas } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const result = await estimateMaxPriorityFeePerGas(config, { + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type EstimateFeesPerGasReturnType } from '@wagmi/core' +``` + +`bigint` + +An estimate (in wei) for the max priority fee per gas. + +## Error + +```ts +import { type EstimateFeesPerGasErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`estimateMaxPriorityFeePerGas`](https://viem.sh/docs/actions/public/estimateMaxPriorityFeePerGas.html) diff --git a/site/core/api/actions/getAccount.md b/site/core/api/actions/getAccount.md new file mode 100644 index 0000000000..a8dde7602e --- /dev/null +++ b/site/core/api/actions/getAccount.md @@ -0,0 +1,29 @@ +# getAccount + +Action for getting current account. + +## Import + +```ts +import { getAccount } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getAccount } from '@wagmi/core' +import { config } from './config' + +const account = getAccount(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetAccountReturnType } from '@wagmi/core' +``` + + diff --git a/site/core/api/actions/getBalance.md b/site/core/api/actions/getBalance.md new file mode 100644 index 0000000000..192d5a69ce --- /dev/null +++ b/site/core/api/actions/getBalance.md @@ -0,0 +1,197 @@ + + +# getBalance + +Action for fetching native currency or token balance. + +## Import + +```ts +import { getBalance } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getBalance } from '@wagmi/core' +import { config } from './config' + +const balance = getBalance(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetBalanceParameters } from '@wagmi/core' +``` + +### address + +`Address` + +Address to get balance for. + +::: code-group +```ts [index.ts] +import { getBalance } from '@wagmi/core' +import { config } from './config' + +const balance = getBalance(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get balance at. + +::: code-group +```ts [index.ts] +import { getBalance } from '@wagmi/core' +import { config } from './config' + +const balance = getBalance(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + blockNumber: 17829139n, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get balance at. + +::: code-group +```ts [index.ts] +import { getBalance } from '@wagmi/core' +import { config } from './config' + +const balance = getBalance(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + blockTag: 'latest', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getBalance } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const balance = await getBalance(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### token + +`Address | undefined` + +ERC-20 token address to get balance for. + +::: code-group +```ts [index.ts] +import { getBalance } from '@wagmi/core' +import { config } from './config' + +const balance = getBalance(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + token: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### unit + +`'ether' | 'gwei' | 'wei' | number | undefined` + +- Units to use when formatting result. +- Defaults to `'ether'`. + +::: code-group +```ts [index.ts] +import { getBalance } from '@wagmi/core' +import { config } from './config' + +const balance = getBalance(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + unit: 'ether', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetBalanceReturnType } from '@wagmi/core' +``` + +### decimals + +`number` + +Number of decimals for balance [`value`](#value). + +### formatted + +`string` + +Formatted value of balance using [`unit`](#unit). + +### symbol + +`string` + +Symbol of native currency or token. + +### value + +`bigint` + +Raw value of balance. + +## Error + +```ts +import { type GetBalanceErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getBalance`](https://viem.sh/docs/actions/public/getBalance.html) for native currency balances +- [`multicall`](https://viem.sh/docs/actions/public/multicall.html) for token balances diff --git a/site/core/api/actions/getBlock.md b/site/core/api/actions/getBlock.md new file mode 100644 index 0000000000..980b026247 --- /dev/null +++ b/site/core/api/actions/getBlock.md @@ -0,0 +1,146 @@ + + +# getBlock + +Action for fetching information about a block at a block number, hash or tag. + +## Import + +```ts +import { getBlock } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getBlock } from '@wagmi/core' +import { config } from './config' + +const blockNumber = await getBlock(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetBlockParameters } from '@wagmi/core' +``` + +### blockHash + +`` `0x${string}` `` + +Information at a given block hash. + +::: code-group +```ts [index.ts] +import { getBlock } from '@wagmi/core' +import { config } from './config' + +const blockNumber = await getBlock(config, { + blockHash: '0x89644bbd5c8d682a2e9611170e6c1f02573d866d286f006cbf517eec7254ec2d' // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockNumber + +`` bigint `` + +Information at a given block number. + +::: code-group +```ts [index.ts] +import { getBlock } from '@wagmi/core' +import { config } from './config' + +const blockNumber = await getBlock(config, { + blockNumber: 42069n // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`` 'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' `` + +Information at a given block tag. Defaults to `'latest'`. + +::: code-group +```ts [index.ts] +import { getBlock } from '@wagmi/core' +import { config } from './config' + +const blockNumber = await getBlock(config, { + blockTag: 'pending' // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getBlock } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const blockNumber = await getBlock(config, { + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### includeTransactions + +`boolean` + +Whether or not to include transactions as objects. + +::: code-group +```ts [index.ts] +import { getBlock } from '@wagmi/core' +import { config } from './config' + +const blockNumber = await getBlock(config, { + includeTransactions: true // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetBlockReturnType } from '@wagmi/core' +``` + +[`Block`](https://viem.sh/docs/glossary/types.html#block) + +Information about the block. + +## Error + +```ts +import { type GetBlockErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getBlock`](https://viem.sh/docs/actions/public/getBlock.html) diff --git a/site/core/api/actions/getBlockNumber.md b/site/core/api/actions/getBlockNumber.md new file mode 100644 index 0000000000..ce13cbb14e --- /dev/null +++ b/site/core/api/actions/getBlockNumber.md @@ -0,0 +1,93 @@ + + +# getBlockNumber + +Action for fetching the number of the most recent block seen. + +## Import + +```ts +import { getBlockNumber } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getBlockNumber } from '@wagmi/core' +import { config } from './config' + +const blockNumber = await getBlockNumber(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetBlockNumberParameters } from '@wagmi/core' +``` + +### cacheTime + +`number | undefined` + +Time in milliseconds that cached block number will remain in memory. + +::: code-group +```ts [index.ts] +import { getBlockNumber } from '@wagmi/core' +import { config } from './config' + +const blockNumber = await getBlockNumber(config, { + cacheTime: 4_000, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getBlockNumber } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const blockNumber = await getBlockNumber(config, { + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetBlockNumberReturnType } from '@wagmi/core' +``` + +`bigint` + +Most recent block number seen. + +## Error + +```ts +import { type GetBlockNumberErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getBlockNumber`](https://viem.sh/docs/actions/public/getBlockNumber.html) +- [`watchBlockNumber`](https://viem.sh/docs/actions/public/watchBlockNumber.html) diff --git a/site/core/api/actions/getBlockTransactionCount.md b/site/core/api/actions/getBlockTransactionCount.md new file mode 100644 index 0000000000..c351272209 --- /dev/null +++ b/site/core/api/actions/getBlockTransactionCount.md @@ -0,0 +1,92 @@ + + +# getBlockTransactionCount + +Action for fetching the number of Transactions at a block number, hash or tag. + +## Import + +```ts +import { getBlockTransactionCount } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getBlockTransactionCount } from '@wagmi/core' +import { config } from './config' + +const blockTransactionCount = await getBlockTransactionCount(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetBlockTransactionCountParameters } from '@wagmi/core' +``` + +### cacheTime + +`number | undefined` + +Time in milliseconds that cached block transaction count will remain in memory. + +::: code-group +```ts [index.ts] +import { getBlockTransactionCount } from '@wagmi/core' +import { config } from './config' + +const blockTransactionCount = await getBlockTransactionCount(config, { + cacheTime: 4_000, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getBlockTransactionCount } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const blockTransactionCount = await getBlockTransactionCount(config, { + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetBlockTransactionCountReturnType } from '@wagmi/core' +``` + +`number` + +The number of Transactions at a block number + +## Error + +```ts +import { type GetBlockTransactionCountErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getBlockTransactionCount`](https://viem.sh/docs/actions/public/getBlockTransactionCount.html) diff --git a/site/core/api/actions/getBytecode.md b/site/core/api/actions/getBytecode.md new file mode 100644 index 0000000000..3a926d6eea --- /dev/null +++ b/site/core/api/actions/getBytecode.md @@ -0,0 +1,133 @@ + + +# getBytecode + +Action for retrieving the bytecode at an address. + +## Import + +```ts +import { getBytecode } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getBytecode } from '@wagmi/core' +import { config } from './config' + +await getBytecode(config, { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetBytecodeParameters } from '@wagmi/core' +``` + +### address + +`Address` + +The contract address. + +::: code-group +```ts [index.ts] +import { getBytecode } from '@wagmi/core' +import { config } from './config' + +await getBytecode(config, { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +The block number to check the bytecode at. + +::: code-group +```ts [index.ts] +import { getBytecode } from '@wagmi/core' +import { config } from './config' + +await getBytecode(config, { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + blockNumber: 16280770n, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +The block tag to check the bytecode at. + +::: code-group +```ts [index.ts] +import { getBytecode } from '@wagmi/core' +import { config } from './config' + +await getBytecode(config, { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + blockTag: 'safe', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +The chain ID to check the bytecode at. + +::: code-group +```ts [index.ts] +import { getBytecode } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +await getBytecode(config, { + chainId: mainnet.id, // [!code focus] + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetBytecodeReturnType } from '@wagmi/core' +``` + +`Hex` + +The contract's bytecode. + +## Error + +```ts +import { type GetBytecodeErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getCode`](https://viem.sh/docs/contract/getCode) diff --git a/site/core/api/actions/getCallsStatus.md b/site/core/api/actions/getCallsStatus.md new file mode 100644 index 0000000000..dc03862b19 --- /dev/null +++ b/site/core/api/actions/getCallsStatus.md @@ -0,0 +1,97 @@ + + +# getCallsStatus + +Action to fetch the status and receipts of a call batch that was sent via [`sendCalls`](/core/api/actions/sendCalls). + +[Read more.](https://github.com/ethereum/EIPs/blob/1663ea2e7a683285f977eda51c32cec86553f585/EIPS/eip-5792.md#wallet_getcallsstatus) + +## Import + +```ts +import { getCallsStatus } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getCallsStatus } from '@wagmi/core' +import { config } from './config' + +const status = await getCallsStatus(config, { + id: '0x1234567890abcdef', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetCallsStatusParameters } from '@wagmi/core' +``` + +### connector + +`Connector | undefined` + +Connector to get call statuses with. + +::: code-group +```ts [index.ts] +import { getConnections, getCallsStatus } from '@wagmi/core' +import { config } from './config' + +const connections = getConnections(config) +const status = await getCallsStatus(config, { + connector: connections[0]?.connector, // [!code focus] + id: '0x1234567890abcdef', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### id + +`string` + +Identifier of the call batch. + +::: code-group +```ts [index.ts] +import { getCallsStatus } from '@wagmi/core' +import { config } from './config' + +const status = await getCallsStatus(config, { + id: '0x1234567890abcdef', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetCallsStatusReturnType } from '@wagmi/core' +``` + +`{ status: 'PENDING' | 'CONFIRMED', receipts: TransactionReceipt[] }` + +The status and receipts of the call batch. + +## Error + +```ts +import { type GetCallsStatusErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getCallsStatus`](https://viem.sh/experimental/eip5792/getCallsStatus) diff --git a/site/core/api/actions/getCapabilities.md b/site/core/api/actions/getCapabilities.md new file mode 100644 index 0000000000..36bad2bdda --- /dev/null +++ b/site/core/api/actions/getCapabilities.md @@ -0,0 +1,96 @@ + + +# getCapabilities + +Action to extract capabilities (grouped by chain ID) that a connected wallet supports (e.g. paymasters, session keys, etc). + +[Read more.](https://github.com/ethereum/EIPs/blob/815028dc634463e1716fc5ce44c019a6040f0bef/EIPS/eip-5792.md#wallet_getcapabilities) + + + +## Import + +```ts +import { getCapabilities } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getCapabilities } from '@wagmi/core' +import { config } from './config' + +const capabilities = await getCapabilities(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetCapabilitiesParameters } from '@wagmi/core' +``` + +### account + +`Account | Address | undefined` + +Fetch capabilities for the provided account. + +::: code-group +```ts [index.ts] +import { getCapabilities } from '@wagmi/core' +import { config } from './config' + +const capabilities = await getCapabilities(config, { + account: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +Connector to get capabilities from. + +::: code-group +```ts [index.ts] +import { getConnections, getCapabilities } from '@wagmi/core' +import { config } from './config' + +const connections = getConnections(config) +const capabilities = await getCapabilities(config, { + connector: connections[0]?.connector, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetCapabilitiesReturnType } from '@wagmi/core' +``` + +`bigint` + +Most recent block number seen. + +## Error + +```ts +import { type GetCapabilitiesErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getCapabilities`](https://viem.sh/experimental/eip5792/getCapabilities) diff --git a/site/core/api/actions/getChainId.md b/site/core/api/actions/getChainId.md new file mode 100644 index 0000000000..9d03f8468e --- /dev/null +++ b/site/core/api/actions/getChainId.md @@ -0,0 +1,38 @@ +# getChainId + +Action for getting current chain ID. + + +## Import + +```ts +import { getChainId } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getChainId } from '@wagmi/core' +import { config } from './config' + +const chainId = getChainId(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetChainIdReturnType } from '@wagmi/core' +``` + +`number` + +Current chain ID from [`config.state.chainId`](/core/api/createConfig#chainid). + +::: info +Only returns chain IDs for chains configured via `createConfig`'s [`chains`](/core/api/createConfig#chains) parameter. + +If the active [connection](/core/api/createConfig#connection) [`chainId`](/core/api/createConfig#chainid-1) is not from a chain included in your Wagmi `Config`, `getChainId` will return the last configured chain ID. +::: diff --git a/site/core/api/actions/getChains.md b/site/core/api/actions/getChains.md new file mode 100644 index 0000000000..c70334e027 --- /dev/null +++ b/site/core/api/actions/getChains.md @@ -0,0 +1,31 @@ +# getChains + +Action for getting configured chains. + +## Import + +```ts +import { getChains } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getChains } from '@wagmi/core' +import { config } from './config' + +const chains = getChains(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetChainsReturnType } from '@wagmi/core' +``` + +`readonly [Chain, ...Chain[]]` + +Chains from [`config.chains`](/core/api/createConfig#chains). diff --git a/site/core/api/actions/getClient.md b/site/core/api/actions/getClient.md new file mode 100644 index 0000000000..9f29f73236 --- /dev/null +++ b/site/core/api/actions/getClient.md @@ -0,0 +1,56 @@ +# getClient + +Action for getting Viem [`Client`](https://viem.sh/docs/clients/custom.html) instance. + +## Import + +```ts +import { getClient } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getClient } from '@wagmi/core' +import { config } from './config' + +const client = getClient(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetClientParameters } from '@wagmi/core' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when getting Viem Client. + +::: code-group +```ts [index.ts] +import { getClient } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const client = await getClient(config, { + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetClientReturnType } from '@wagmi/core' +``` + +`Client` + +Viem [`Client`](https://viem.sh/docs/clients/custom.html) instance. diff --git a/site/core/api/actions/getConnections.md b/site/core/api/actions/getConnections.md new file mode 100644 index 0000000000..513d0d017d --- /dev/null +++ b/site/core/api/actions/getConnections.md @@ -0,0 +1,31 @@ +# getConnections + +Action for getting active connections. + +## Import + +```ts +import { getConnections } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getConnections } from '@wagmi/core' +import { config } from './config' + +const connections = getConnections(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetConnectionsReturnType } from '@wagmi/core' +``` + +[`Connection[]`](/core/api/createConfig#connection) + +Active connections. diff --git a/site/core/api/actions/getConnectorClient.md b/site/core/api/actions/getConnectorClient.md new file mode 100644 index 0000000000..46d2795c7a --- /dev/null +++ b/site/core/api/actions/getConnectorClient.md @@ -0,0 +1,108 @@ + + +# getConnectorClient + +Action for getting a Viem [`Client`](https://viem.sh/docs/clients/custom.html) object for the current or provided connector. + +## Import + +```ts +import { getConnectorClient } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getConnectorClient } from '@wagmi/core' +import { config } from './config' + +const client = await getConnectorClient(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetConnectorClientParameters } from '@wagmi/core' +``` + +### account + +`Address | Account | undefined` + +Account to use with client. Throws if account is not found on [`connector`](#connector). + +::: code-group +```ts [index.ts] +import { getConnectorClient } from '@wagmi/core' +import { config } from './config' + +const client = await getConnectorClient(config, { + account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use with client. + +::: code-group +```ts [index.ts] +import { getConnectorClient } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const client = await getConnectorClient(config, { + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +- Connector to get client for. +- Defaults to current connector. + +::: code-group +```ts [index.ts] +import { getConnections, getConnectorClient } from '@wagmi/core' +import { config } from './config' + +const connections = getConnections(config) +const client = await getConnectorClient(config, { + connector: connections[0]?.connector, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetChainIdReturnType } from '@wagmi/core' +``` + +`Client` + +Viem [`Client`](https://viem.sh/docs/clients/custom.html) object for the current or provided connector. + +## Error + +```ts +import { type GetConnectorClientErrorType } from '@wagmi/core' +``` + + diff --git a/site/core/api/actions/getConnectors.md b/site/core/api/actions/getConnectors.md new file mode 100644 index 0000000000..ddbb049be9 --- /dev/null +++ b/site/core/api/actions/getConnectors.md @@ -0,0 +1,31 @@ +# getConnectors + +Action for getting configured connectors. + +## Import + +```ts +import { getConnectors } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getConnectors } from '@wagmi/core' +import { config } from './config' + +const connectors = getConnectors(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetConnectorsReturnType } from '@wagmi/core' +``` + +`readonly Connector[]` + +Connectors from [`config.connectors`](/core/api/createConfig#connectors-1). diff --git a/site/core/api/actions/getEnsAddress.md b/site/core/api/actions/getEnsAddress.md new file mode 100644 index 0000000000..dc44dbb732 --- /dev/null +++ b/site/core/api/actions/getEnsAddress.md @@ -0,0 +1,187 @@ + + +# getEnsAddress + +Action for fetching ENS address for name. + +## Import + +```ts +import { getEnsAddress } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getEnsAddress } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAddress = getEnsAddress(config, { + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +::: warning +Since ENS names prohibit certain forbidden characters (e.g. underscore) and have other validation rules, you likely want to [normalize ENS names](https://docs.ens.domains/contract-api-reference/name-processing#normalising-names) with [UTS-46 normalization](https://unicode.org/reports/tr46) before passing them to `getEnsAddress`. You can use Viem's built-in [`normalize`](https://viem.sh/docs/ens/utilities/normalize) function for this. +::: + +## Parameters + +```ts +import { type GetEnsAddressParameters } from '@wagmi/core' +``` + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get ENS address at. + +::: code-group +```ts [index.ts] +import { getEnsAddress } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAddress = getEnsAddress(config, { + blockNumber: 17829139n, // [!code focus] + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get ENS address at. + +::: code-group +```ts [index.ts] +import { getEnsAddress } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAddress = getEnsAddress(config, { + blockTag: 'latest', // [!code focus] + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getEnsAddress } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAddress = await getEnsAddress(config, { + chainId: mainnet.id, // [!code focus] + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### coinType + +`number | undefined` + +The [ENSIP-9](https://docs.ens.domains/ens-improvement-proposals/ensip-9-multichain-address-resolution) coin type to fetch the address for. + +::: code-group +```ts [index.ts] +import { getEnsAddress } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAddress = await getEnsAddress(config, { + coinType: 60, // [!code focus] + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### name + +`string` + +Name to get the address for. + +::: code-group +```ts [index.ts] +import { getEnsAddress } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAddress = await getEnsAddress(config, { + name: normalize('wevm.eth'), // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Address of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```ts [index.ts] +import { getEnsAddress } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAddress = await getEnsAddress(config, { + name: normalize('wevm.eth'), + universalResolverAddress: '0x74E20Bd2A1fE0cdbe45b9A1d89cb7e0a45b36376', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetEnsAddressReturnType } from '@wagmi/core' +``` + +`string` + +ENS address. + +## Error + +```ts +import { type GetEnsAddressErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getEnsAddress`](https://viem.sh/docs/ens/actions/getEnsAddress.html) diff --git a/site/core/api/actions/getEnsAvatar.md b/site/core/api/actions/getEnsAvatar.md new file mode 100644 index 0000000000..b7da4aa0f0 --- /dev/null +++ b/site/core/api/actions/getEnsAvatar.md @@ -0,0 +1,210 @@ + + +# getEnsAvatar + +Action for fetching ENS address for avatar. + +## Import + +```ts +import { getEnsAvatar } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getEnsAvatar } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAvatar = await getEnsAvatar(config, { + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +::: warning +Since ENS names prohibit certain forbidden characters (e.g. underscore) and have other validation rules, you likely want to [normalize ENS names](https://docs.ens.domains/contract-api-reference/name-processing#normalising-names) with [UTS-46 normalization](https://unicode.org/reports/tr46) before passing them to `getEnsAvatar`. You can use Viem's built-in [`normalize`](https://viem.sh/docs/ens/utilities/normalize) function for this. +::: + +## Parameters + +```ts +import { type GetEnsAvatarParameters } from '@wagmi/core' +``` + +--- + +### assetGatewayUrls + +`{ ipfs?: string | undefined; arweave?: string | undefined } | undefined` + +Gateway urls to resolve IPFS and/or Arweave assets. + +::: code-group +```ts [index.ts] +import { getEnsAvatar } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAvatar = await getEnsAvatar(config, { + assetGatewayUrls: { // [!code focus] + ipfs: 'https://cloudflare-ipfs.com', // [!code focus] + }, // [!code focus] + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + + +### blockNumber + +`bigint | undefined` + +Block number to get avatar at. + +::: code-group +```ts [index.ts] +import { getEnsAvatar } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAvatar = await getEnsAvatar(config, { + blockNumber: 17829139n, // [!code focus] + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get avatar at. + +::: code-group +```ts [index.ts] +import { getEnsAvatar } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAvatar = await getEnsAvatar(config, { + blockTag: 'latest', // [!code focus] + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getEnsAvatar } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAvatar = await getEnsAvatar(config, { + chainId: mainnet.id, // [!code focus] + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### gatewayUrls + +`string[] | undefined` + +A set of Universal Resolver gateways, used for resolving CCIP-Read requests made through the ENS Universal Resolver Contract. + +::: code-group +```ts [index.ts] +import { getEnsAvatar } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAvatar = await getEnsAvatar(config, { + gatewayUrls: ['https://cloudflare-ipfs.com'] { // [!code focus] + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### name + +`string` + +Name to get the avatar for. + +::: code-group +```ts [index.ts] +import { getEnsAvatar } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAvatar = await getEnsAvatar(config, { + name: normalize('wevm.eth'), // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Address of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```ts [index.ts] +import { getEnsAvatar } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensAvatar = await getEnsAvatar(config, { + name: normalize('wevm.eth'), + universalResolverAddress: '0x74E20Bd2A1fE0cdbe45b9A1d89cb7e0a45b36376', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetEnsAvatarReturnType } from '@wagmi/core' +``` + +`string | null` + +The avatar URI for ENS name. + +## Error + +```ts +import { type getEnsAvatarError } from '@wagmi/core' +``` + + + +## Viem + +- [`getEnsAvatar`](https://viem.sh/docs/ens/actions/getEnsAvatar.html) diff --git a/site/core/api/actions/getEnsName.md b/site/core/api/actions/getEnsName.md new file mode 100644 index 0000000000..f663923f94 --- /dev/null +++ b/site/core/api/actions/getEnsName.md @@ -0,0 +1,157 @@ + + +# getEnsName + +Action for fetching primary ENS name for address. + +## Import + +```ts +import { getEnsName } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getEnsName } from '@wagmi/core' +import { config } from './config' + +const ensName = getEnsName(config, { + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetEnsNameParameters } from '@wagmi/core' +``` + +### address + +`Address` + +Address to get the name for. + +::: code-group +```ts [index.ts] +import { getEnsName } from '@wagmi/core' +import { config } from './config' + +const ensName = await getEnsName(config, { + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get name at. + +::: code-group +```ts [index.ts] +import { getEnsName } from '@wagmi/core' +import { config } from './config' + +const ensName = getEnsName(config, { + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + blockNumber: 17829139n, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get name at. + +::: code-group +```ts [index.ts] +import { getEnsName } from '@wagmi/core' +import { config } from './config' + +const ensName = getEnsName(config, { + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + blockTag: 'latest', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getEnsName } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const ensName = await getEnsName(config, { + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Address of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```ts [index.ts] +import { getEnsName } from '@wagmi/core' +import { config } from './config' + +const ensName = await getEnsName(config, { + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + universalResolverName: '0x74E20Bd2A1fE0cdbe45b9A1d89cb7e0a45b36376', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetEnsNameReturnType } from '@wagmi/core' +``` + +`string | null` + +The primary ENS name for the address. Returns `null` if address does not have primary name assigned. + +## Error + +```ts +import { type GetEnsNameErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getEnsName`](https://viem.sh/docs/ens/actions/getEnsName.html) diff --git a/site/core/api/actions/getEnsResolver.md b/site/core/api/actions/getEnsResolver.md new file mode 100644 index 0000000000..c73301e071 --- /dev/null +++ b/site/core/api/actions/getEnsResolver.md @@ -0,0 +1,167 @@ + + +# getEnsResolver + +Action for fetching ENS resolver for name. + +## Import + +```ts +import { getEnsResolver } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getEnsResolver } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensResolver = getEnsResolver(config, { + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +::: warning +Since ENS names prohibit certain forbidden characters (e.g. underscore) and have other validation rules, you likely want to [normalize ENS names](https://docs.ens.domains/contract-api-reference/name-processing#normalising-names) with [UTS-46 normalization](https://unicode.org/reports/tr46) before passing them to `getEnsResolver`. You can use Viem's built-in [`normalize`](https://viem.sh/docs/ens/utilities/normalize) function for this. +::: + +## Parameters + +```ts +import { type GetEnsResolverParameters } from '@wagmi/core' +``` + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get resolver at. + +::: code-group +```ts [index.ts] +import { getEnsResolver } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensResolver = getEnsResolver(config, { + blockNumber: 17829139n, // [!code focus] + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get resolver at. + +::: code-group +```ts [index.ts] +import { getEnsResolver } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensResolver = getEnsResolver(config, { + blockTag: 'latest', // [!code focus] + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getEnsResolver } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensResolver = await getEnsResolver(config, { + chainId: mainnet.id, // [!code focus] + name: normalize('wevm.eth'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### name + +`string` + +Name to get the resolver for. + +::: code-group +```ts [index.ts] +import { getEnsResolver } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensResolver = await getEnsResolver(config, { + name: normalize('wevm.eth'), // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Address of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```ts [index.ts] +import { getEnsResolver } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensResolver = await getEnsResolver(config, { + name: normalize('wevm.eth'), + universalResolverAddress: '0x74E20Bd2A1fE0cdbe45b9A1d89cb7e0a45b36376', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetEnsResolverReturnType } from '@wagmi/core' +``` + +`Address` + +The address of the resolver. + +## Error + +```ts +import { type getEnsResolverError } from '@wagmi/core' +``` + + + +## Viem + +- [`getEnsResolver`](https://viem.sh/docs/ens/actions/getEnsResolver.html) diff --git a/site/core/api/actions/getEnsText.md b/site/core/api/actions/getEnsText.md new file mode 100644 index 0000000000..a5ffb8ed5a --- /dev/null +++ b/site/core/api/actions/getEnsText.md @@ -0,0 +1,195 @@ + + +# getEnsText + +Action for fetching a text record for a specified ENS name and key. + +## Import + +```ts +import { getEnsText } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getEnsText } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensText = getEnsText(config, { + name: normalize('wevm.eth'), + key: 'com.twitter', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +::: warning +Since ENS names prohibit certain forbidden characters (e.g. underscore) and have other validation rules, you likely want to [normalize ENS names](https://docs.ens.domains/contract-api-reference/name-processing#normalising-names) with [UTS-46 normalization](https://unicode.org/reports/tr46) before passing them to `getEnsText`. You can use Viem's built-in [`normalize`](https://viem.sh/docs/ens/utilities/normalize) function for this. +::: + +## Parameters + +```ts +import { type GetEnsTextParameters } from '@wagmi/core' +``` + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get the text at. + +::: code-group +```ts [index.ts] +import { getEnsText } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensText = getEnsText(config, { + blockNumber: 17829139n, // [!code focus] + name: normalize('wevm.eth'), + key: 'com.twitter', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get the text at. + +::: code-group +```ts [index.ts] +import { getEnsText } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensText = getEnsText(config, { + blockTag: 'latest', // [!code focus] + name: normalize('wevm.eth'), + key: 'com.twitter', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getEnsText } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensText = await getEnsText(config, { + chainId: mainnet.id, // [!code focus] + name: normalize('wevm.eth'), + key: 'com.twitter', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### key + +`string` + +ENS key to get Text for. + +::: code-group +```ts [index.ts] +import { getEnsText } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensText = await getEnsText(config, { + name: normalize('wevm.eth'), + key: 'com.twitter', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### name + +`string` + +Name to get the text for. + +::: code-group +```ts [index.ts] +import { getEnsText } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensText = await getEnsText(config, { + name: normalize('wevm.eth'), // [!code focus] + key: 'com.twitter', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Address of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```ts [index.ts] +import { getEnsText } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +const ensText = await getEnsText(config, { + name: normalize('wevm.eth'), + key: 'com.twitter', + universalResolverAddress: '0x74E20Bd2A1fE0cdbe45b9A1d89cb7e0a45b36376', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetEnsTextReturnType } from '@wagmi/core' +``` + +`string | null` + +The text record for ENS name. + +Returns `null` if name does not have text assigned. + +## Error + +```ts +import { type getEnsTextError } from '@wagmi/core' +``` + + + +## Viem + +- [`getEnsText`](https://viem.sh/docs/ens/actions/getEnsText.html) diff --git a/site/core/api/actions/getFeeHistory.md b/site/core/api/actions/getFeeHistory.md new file mode 100644 index 0000000000..3787d8f66b --- /dev/null +++ b/site/core/api/actions/getFeeHistory.md @@ -0,0 +1,157 @@ + + +# getFeeHistory + +Action for fetching a collection of historical gas information. + +## Import + +```ts +import { getFeeHistory } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getFeeHistory } from '@wagmi/core' +import { config } from './config' + +const feeHistory = await getFeeHistory(config, { + blockCount: 4, + rewardPercentiles: [25, 75] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetFeeHistoryParameters } from '@wagmi/core' +``` + +### blockCount + +`number` + +Number of blocks in the requested range. Between 1 and 1024 blocks can be requested in a single query. Less than requested may be returned if not all blocks are available. + +::: code-group +```ts [index.ts] +import { getFeeHistory } from '@wagmi/core' +import { config } from './config' + +const feeHistory = await getFeeHistory(config, { + blockCount: 4, // [!code focus] + rewardPercentiles: [25, 75] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### rewardPercentiles + +`number[]` + +A monotonically increasing list of percentile values to sample from each block's effective priority fees per gas in ascending order, weighted by gas used. + +::: code-group +```ts [index.ts] +import { getFeeHistory } from '@wagmi/core' +import { config } from './config' + +const feeHistory = await getFeeHistory(config, { + blockCount: 4, + rewardPercentiles: [25, 75] // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +Highest number block of the requested range. + +::: code-group +```ts [index.ts] +import { getFeeHistory } from '@wagmi/core' +import { config } from './config' + +const feeHistory = await getFeeHistory(config, { + blockCount: 4, + blockNumber: 1551231n, // [!code focus] + rewardPercentiles: [25, 75], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag of the highest number block of the requested range. + +::: code-group +```ts [index.ts] +import { getFeeHistory } from '@wagmi/core' +import { config } from './config' + +const feeHistory = await getFeeHistory(config, { + blockCount: 4, + blockTag: 'safe', // [!code focus] + rewardPercentiles: [25, 75], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getFeeHistory } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const feeHistory = await getFeeHistory(config, { + blockCount: 4, + chainId: mainnet.id, // [!code focus] + rewardPercentiles: [25, 75], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetFeeHistoryReturnType } from '@wagmi/core' +``` + +[`FeeHistory`](https://viem.sh/docs/glossary/types.html#feehistory) + +The fee history. + +## Error + +```ts +import { type GetFeeHistoryErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getFeeHistory`](https://viem.sh/docs/actions/public/getFeeHistory.html) diff --git a/site/core/api/actions/getGasPrice.md b/site/core/api/actions/getGasPrice.md new file mode 100644 index 0000000000..106829fcfd --- /dev/null +++ b/site/core/api/actions/getGasPrice.md @@ -0,0 +1,74 @@ + + +# getGasPrice + +Action for fetching the current price of gas (in wei). + +## Import + +```ts +import { getGasPrice } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getGasPrice } from '@wagmi/core' +import { config } from './config' + +const gasPrice = await getGasPrice(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetGasPriceParameters } from '@wagmi/core' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getGasPrice } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const gasPrice = await getGasPrice(config, { + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetGasPriceReturnType } from '@wagmi/core' +``` + +`bigint` + +Current price of gas (in wei). + +## Error + +```ts +import { type GetGasPriceErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getGasPrice`](https://viem.sh/docs/actions/public/getGasPrice.html) diff --git a/site/core/api/actions/getProof.md b/site/core/api/actions/getProof.md new file mode 100644 index 0000000000..60cd493260 --- /dev/null +++ b/site/core/api/actions/getProof.md @@ -0,0 +1,169 @@ + + +# getProof + +Action for return the account and storage values of the specified account including the Merkle-proof. + +## Import + +```ts +import { getProof } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getProof } from '@wagmi/core' +import { config } from './config' + +await getProof(config, { + address: '0x4200000000000000000000000000000000000016', + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetProofParameters } from '@wagmi/core' +``` + +### address + +`Address` + +The account address to get the proof for. + +::: code-group +```ts [index.ts] +import { getProof } from '@wagmi/core' +import { config } from './config' + +await getProof(config, { + address: '0x4200000000000000000000000000000000000016', // [!code focus] + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### storageKeys + +`` `0x${string}`[] `` + +Array of storage-keys that should be proofed and included. + +::: code-group +```ts [index.ts] +import { getProof } from '@wagmi/core' +import { config } from './config' + +await getProof(config, { + address: '0x4200000000000000000000000000000000000016', + storageKeys: [ // [!code focus:3] + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +Proof at a given block number. + +::: code-group +```ts [index.ts] +import { getProof } from '@wagmi/core' +import { config } from './config' + +await getProof(config, { + address: '0x4200000000000000000000000000000000000016', + blockNumber: 42069n, // [!code focus] + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Proof at a given block tag. + +::: code-group +```ts [index.ts] +import { getProof } from '@wagmi/core' +import { config } from './config' + +await getProof(config, { + address: '0x4200000000000000000000000000000000000016', + blockTag: 'latest', // [!code focus] + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +The ID of chain to get the proof for. + +::: code-group +```ts [index.ts] +import { getProof } from '@wagmi/core' +import { config } from './config' +import { optimism } from '@wagmi/core/chains' + +await getProof(config, { + chainId: optimism.id, // [!code focus] + address: '0x4200000000000000000000000000000000000016', + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetProofReturnType } from '@wagmi/core' +``` + +`Proof` + +Proof data. + +## Error + +```ts +import { type GetProofErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getProof`](https://viem.sh/docs/actions/public/getProof.html) diff --git a/site/core/api/actions/getPublicClient.md b/site/core/api/actions/getPublicClient.md new file mode 100644 index 0000000000..437104aa78 --- /dev/null +++ b/site/core/api/actions/getPublicClient.md @@ -0,0 +1,60 @@ +# getPublicClient + +Action for getting Viem [`PublicClient`](https://viem.sh/docs/clients/public.html) instance. + +## Import + +```ts +import { getPublicClient } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getPublicClient } from '@wagmi/core' +import { config } from './config' + +const client = getPublicClient(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +::: warning +If you want to optimize bundle size, you should use [`getClient`](/core/api/actions/getClient) along with Viem's [tree-shakable actions](https://viem.sh/docs/clients/custom.html#tree-shaking) instead. Since Public Client has all public actions attached directly to it. +::: + +## Parameters + +```ts +import { type GetClientParameters } from '@wagmi/core' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when getting Viem Public Client. + +::: code-group +```ts [index.ts] +import { getPublicClient } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const client = getPublicClient(config, { + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetPublicClientReturnType } from '@wagmi/core' +``` + +`PublicClient | undefined` + +Viem [`PublicClient`](https://viem.sh/docs/clients/public.html) instance. diff --git a/site/core/api/actions/getStorageAt.md b/site/core/api/actions/getStorageAt.md new file mode 100644 index 0000000000..23a5dc1d2f --- /dev/null +++ b/site/core/api/actions/getStorageAt.md @@ -0,0 +1,157 @@ + + +# getStorageAt + +Action for returning the value from a storage slot at a given address. + +## Import + +```ts +import { getStorageAt } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getStorageAt } from '@wagmi/core' +import { config } from './config' + +await getStorageAt(config, { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + slot: '0x0', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetStorageAtParameters } from '@wagmi/core' +``` + +### address + +`Address` + +The contract address. + +::: code-group +```ts [index.ts] +import { getStorageAt } from '@wagmi/core' +import { config } from './config' + +await getStorageAt(config, { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', // [!code focus] + slot: '0x0', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### slot + +`Hex` + +The storage position (as a hex encoded value). + +::: code-group +```ts [index.ts] +import { getStorageAt } from '@wagmi/core' +import { config } from './config' + +await getStorageAt(config, { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + slot: '0x0', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +The block number to check the storage at. + +::: code-group +```ts [index.ts] +import { getStorageAt } from '@wagmi/core' +import { config } from './config' + +await getStorageAt(config, { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + blockNumber: 16280770n, // [!code focus] + slot: '0x0', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +The block tag to check the storage at. + +::: code-group +```ts [index.ts] +import { getStorageAt } from '@wagmi/core' +import { config } from './config' + +await getStorageAt(config, { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + blockTag: 'safe', // [!code focus] + slot: '0x0', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +The chain ID to check the storage at. + +::: code-group +```ts [index.ts] +import { getStorageAt } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +await getStorageAt(config, { + chainId: mainnet.id, // [!code focus] + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + slot: '0x0', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetStorageAtReturnType } from '@wagmi/core' +``` + +`Hex` + +The value of the storage slot. + +## Error + +```ts +import { type GetStorageAtErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getStorageAt`](https://viem.sh/docs/contract/getStorageAt) diff --git a/site/core/api/actions/getToken.md b/site/core/api/actions/getToken.md new file mode 100644 index 0000000000..b37805cff0 --- /dev/null +++ b/site/core/api/actions/getToken.md @@ -0,0 +1,141 @@ + + +# getToken + +Action for fetching token info. + +## Import + +```ts +import { getToken } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getToken } from '@wagmi/core' +import { config } from './config' + +const token = getToken(config, { + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetTokenParameters } from '@wagmi/core' +``` + +### address + +`Address` + +Address to get token for. + +::: code-group +```ts [index.ts] +import { getToken } from '@wagmi/core' +import { config } from './config' + +const token = getToken(config, { + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getToken } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const token = await getToken(config, { + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### formatUnits + +`'ether' | 'gwei' | 'wei' | number | undefined` + +- Units to use when formatting result. +- Defaults to `'ether'`. + +::: code-group +```ts [index.ts] +import { getToken } from '@wagmi/core' +import { config } from './config' + +const token = getToken(config, { + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', + formatUnits: 'ether', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetTokenReturnType } from '@wagmi/core' +``` + +### address + +`Address` + +Address of token. + +### decimals + +`number` + +Number of decimals for token. + +### name + +`string | undefined` + +Name of token. + +### symbol + +`string | undefined` + +Symbol of token. + +### totalSupply + +`{ formatted: string; value: bigint; }` + +Total supply of token. `formatted` is formatted using [`formatUnits`](#formatunits). + +## Error + +```ts +import { type GetTokenErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`multicall`](https://viem.sh/docs/contract/multicall) diff --git a/site/core/api/actions/getTransaction.md b/site/core/api/actions/getTransaction.md new file mode 100644 index 0000000000..8ebe770990 --- /dev/null +++ b/site/core/api/actions/getTransaction.md @@ -0,0 +1,173 @@ + + +# getTransaction + +Action for fetching transactions given hashes or block identifiers. + +## Import + +```ts +import { getTransaction } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getTransaction } from '@wagmi/core' +import { config } from './config' + +const transaction = getTransaction(config, { + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetTransactionParameters } from '@wagmi/core' +``` + +--- + +### blockHash + +`bigint | undefined` + +Block hash to get transaction at (with [`index`](#index)). + +::: code-group +```ts [index.ts] +import { getTransaction } from '@wagmi/core' +import { config } from './config' + +const transaction = getTransaction(config, { + blockHash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', // [!code focus] + index: 0, +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +Block number to get transaction at (with [`index`](#index)). + +::: code-group +```ts [index.ts] +import { getTransaction } from '@wagmi/core' +import { config } from './config' + +const transaction = getTransaction(config, { + blockNumber: 17829139n, // [!code focus] + index: 0, +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get transaction at (with [`index`](#index)). + +::: code-group +```ts [index.ts] +import { getTransaction } from '@wagmi/core' +import { config } from './config' + +const transaction = getTransaction(config, { + blockTag: 'safe', // [!code focus] + index: 0, +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getTransaction } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const transaction = await getTransaction(config, { + chainId: mainnet.id, // [!code focus] + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### hash + +`` `0x${string}` | undefined `` + +Hash to get transaction. + +::: code-group +```ts [index.ts] +import { getTransaction } from '@wagmi/core' +import { config } from './config' + +const transaction = getTransaction(config, { + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### index + +`number | undefined` + +An index to be used with a block identifier ([hash](#blockhash), [number](#blocknumber), or [tag](#blocktag)). + +::: code-group +```ts [index.ts] +import { getTransaction } from '@wagmi/core' +import { config } from './config' + +const transaction = getTransaction(config, { + blockTag: 'safe', + index: 0 // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetTransactionReturnType } from '@wagmi/core' +``` + +[`Transaction`](https://viem.sh/docs/glossary/types.html#transaction) + +## Error + +```ts +import { type GetTransactionErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getTransaction`](https://viem.sh/docs/actions/public/getTransaction.html) diff --git a/site/core/api/actions/getTransactionConfirmations.md b/site/core/api/actions/getTransactionConfirmations.md new file mode 100644 index 0000000000..eb42df19ac --- /dev/null +++ b/site/core/api/actions/getTransactionConfirmations.md @@ -0,0 +1,117 @@ + + +# getTransactionConfirmations + +Action for fetching the number of blocks passed (confirmations) since the transaction was processed on a block. If confirmations is 0, then the Transaction has not been confirmed & processed yet. + +## Import + +```ts +import { getTransactionConfirmations } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getTransactionConfirmations } from '@wagmi/core' +import { config } from './config' + +const transaction = getTransactionConfirmations(config, { + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetTransactionConfirmationsParameters } from '@wagmi/core' +``` + +--- + +### hash + +`` `0x${string}` | undefined `` + +The hash of the transaction. + +::: code-group +```ts [index.ts] +import { getTransactionConfirmations } from '@wagmi/core' +import { config } from './config' + +const transaction = getTransactionConfirmations(config, { + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### transactionReceipt + +`TransactionReceipt | undefined` + +The transaction receipt. + +::: code-group +```ts [index.ts] +import { getTransactionConfirmations } from '@wagmi/core' +import { config } from './config' + +const transaction = getTransactionConfirmations(config, { + transactionReceipt: { ... }, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getTransactionConfirmations } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const transaction = await getTransactionConfirmations(config, { + chainId: mainnet.id, // [!code focus] + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetTransactionConfirmationsReturnType } from '@wagmi/core' +``` + +`bigint` + +The number of blocks passed since the transaction was processed. If confirmations is 0, then the Transaction has not been confirmed & processed yet. + +## Error + +```ts +import { type GetTransactionConfirmationsErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getTransactionConfirmations`](https://viem.sh/docs/actions/public/getTransactionConfirmations.html) diff --git a/site/core/api/actions/getTransactionCount.md b/site/core/api/actions/getTransactionCount.md new file mode 100644 index 0000000000..d08987c84d --- /dev/null +++ b/site/core/api/actions/getTransactionCount.md @@ -0,0 +1,139 @@ + + +# getTransactionCount + +Action for fetching the number of transactions an Account has sent. + +## Import + +```ts +import { getTransactionCount } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getTransactionCount } from '@wagmi/core' +import { config } from './config' + +const transactionCount = getTransactionCount(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetTransactionCountParameters } from '@wagmi/core' +``` + +--- + +### address + +`Address` + +The address of the account. + +::: code-group +```ts [index.ts] +import { getTransactionCount } from '@wagmi/core' +import { config } from './config' + +const transactionCount = getTransactionCount(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Get the count at a block number. + +::: code-group +```ts [index.ts] +import { getTransactionCount } from '@wagmi/core' +import { config } from './config' + +const transactionCount = getTransactionCount(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + blockNumber: 17829139n, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Get the count at a block tag. + +::: code-group +```ts [index.ts] +import { getTransactionCount } from '@wagmi/core' +import { config } from './config' + +const transactionCount = getTransactionCount(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + blockTag: 'latest', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { getTransactionCount } from '@wagmi/core' +import { config } from './config' + +const transactionCount = getTransactionCount(config, { + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + + +## Return Type + +```ts +import { type GetTransactionCountReturnType } from '@wagmi/core' +``` + +`number` + +The number of transactions an account has sent. + +## Error + +```ts +import { type GetTransactionCountErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getTransactionCount`](https://viem.sh/docs/actions/public/getTransactionCount.html) diff --git a/site/core/api/actions/getTransactionReceipt.md b/site/core/api/actions/getTransactionReceipt.md new file mode 100644 index 0000000000..d0687ac63e --- /dev/null +++ b/site/core/api/actions/getTransactionReceipt.md @@ -0,0 +1,95 @@ + + +# getTransactionReceipt + +Action for return the [Transaction Receipt](https://viem.sh/docs/glossary/terms.html#transaction-receipt) given a [Transaction](https://viem.sh/docs/glossary/terms.html#transaction) hash. + +## Import + +```ts +import { getTransactionReceipt } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getTransactionReceipt } from '@wagmi/core' +import { config } from './config' + +await getTransactionReceipt(config, { + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type GetTransactionReceiptParameters } from '@wagmi/core' +``` + +### hash + +`` `0x${string}` `` + +A transaction hash. + +::: code-group +```ts [index.ts] +import { getTransactionReceipt } from '@wagmi/core' +import { config } from './config' + +await getTransactionReceipt(config, { + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +The ID of chain to return the transaction receipt from. + +::: code-group +```ts [index.ts] +import { getTransactionReceipt } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +await getTransactionReceipt(config, { + chainId: mainnet.id, // [!code focus] + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetTransactionReceiptReturnType } from '@wagmi/core' +``` + +[`TransactionReceipt`](https://viem.sh/docs/glossary/types.html#transactionreceipt) + +The transaction receipt. + +## Error + +```ts +import { type GetTransactionReceiptErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`getTransactionReceipt`](https://viem.sh/docs/actions/public/getTransactionReceipt.html) diff --git a/site/core/api/actions/getWalletClient.md b/site/core/api/actions/getWalletClient.md new file mode 100644 index 0000000000..a321b3637c --- /dev/null +++ b/site/core/api/actions/getWalletClient.md @@ -0,0 +1,112 @@ + + +# getWalletClient + +Action for getting a Viem [`WalletClient`](https://viem.sh/docs/clients/wallet.html) object for the current or provided connector. + +## Import + +```ts +import { getWalletClient } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getWalletClient } from '@wagmi/core' +import { config } from './config' + +const client = getWalletClient(config) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +::: warning +If you want to optimize bundle size, you should use [`getConnectorClient`](/core/api/actions/getConnectorClient) along with Viem's [tree-shakable actions](https://viem.sh/docs/clients/custom.html#tree-shaking) instead. Since Wallet Client has all wallet actions attached directly to it. +::: + +## Parameters + +```ts +import { type GetWalletClientParameters } from '@wagmi/core' +``` + +### account + +`Address | Account | undefined` + +Account to use with client. Throws if account is not found on [`connector`](#connector). + +::: code-group +```ts [index.ts] +import { getWalletClient } from '@wagmi/core' +import { config } from './config' + +const client = getWalletClient(config, { + account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use with client. + +::: code-group +```ts [index.ts] +import { getWalletClient } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const client = getWalletClient(config, { + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +- Connector to get client for. +- Defaults to current connector. + +::: code-group +```ts [index.ts] +import { getConnections, getWalletClient } from '@wagmi/core' +import { config } from './config' + +const connections = getConnections(config) +const client = getWalletClient(config, { + connector: connections[0]?.connector, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type GetChainIdReturnType } from '@wagmi/core' +``` + +`WalletClient` + +Viem [`WalletClient`](https://viem.sh/docs/clients/wallet.html) object for the current or provided connector. + +## Error + +```ts +import { type GetWalletClientErrorType } from '@wagmi/core' +``` + + \ No newline at end of file diff --git a/site/core/api/actions/multicall.md b/site/core/api/actions/multicall.md new file mode 100644 index 0000000000..ec46368d17 --- /dev/null +++ b/site/core/api/actions/multicall.md @@ -0,0 +1,355 @@ +# multicall + +Action for batching up multiple functions on a contract in a single RPC call via the [Multicall3 contract](https://github.com/mds1/multicall). + +## Import + +```ts +import { multicall } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { multicall } from '@wagmi/core' +import { config } from './config' + +const wagmigotchiContract = { + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + abi: wagmigotchiABI, +} as const +const mlootContract = { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, +} as const + +const result = await multicall(config, { + contracts: [ + { + ...wagmigotchiContract, + functionName: 'getAlive', + }, + { + ...wagmigotchiContract, + functionName: 'getBoredom', + }, + { + ...mlootContract, + functionName: 'getChest', + args: [69], + }, + { + ...mlootContract, + functionName: 'getWaist', + args: [69], + }, + ], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type MulticallParameters } from '@wagmi/core' +``` + +### contracts + +`readonly Contract[]` + +Set of contracts to call. + +#### abi + +`Abi | undefined` + +The contract's ABI. Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```tsx [index.tsx] +import { multicall } from '@wagmi/core' +import { config } from './config' + +const result = await multicall(config, { + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, // [!code hl] + functionName: 'getChest', + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +#### address + +`Address | undefined` + +The contract's address. + +::: code-group +```tsx [index.tsx] +import { multicall } from '@wagmi/core' +import { config } from './config' + +const result = await multicall(config, { + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', // [!code hl] + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +#### args + +`readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`functionName`](#functionname). + +::: code-group +```tsx [index.tsx] +import { multicall } from '@wagmi/core' +import { config } from './config' + +const result = await multicall(config, { + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], // [!code hl] + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +#### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { multicall } from '@wagmi/core' +import { config } from './config' + +const result = await multicall(config, { + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + chainId: 1, // [!code hl] + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + +#### functionName + +`string | undefined` + +- Function to call on the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```tsx [index.tsx] +import { multicall } from '@wagmi/core' +import { config } from './config' + +const result = await multicall(config, { + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', // [!code hl] + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### allowFailure + +`boolean` + +Whether or not the Hook should throw if a call reverts. If set to `true` (default), and a call reverts, then `multicall` will fail silently and its error will be logged in the results array. Defaults to `true`. + +::: code-group +```tsx [index.tsx] +import { multicall } from '@wagmi/core' +import { config } from './config' + +const result = await multicall(config, { + allowFailure: false, // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### batchSize + +`number` + +The maximum size (in bytes) for each calldata chunk. Set to `0` to disable the size limit. Defaults to `1024`. + +> Note: Some RPC Providers limit the amount of calldata (`data`) that can be sent in a single `eth_call` request. It is best to check with your RPC Provider to see if there are any calldata size limits to `eth_call` requests. + +::: code-group +```tsx [index.tsx] +import { multicall } from '@wagmi/core' +import { config } from './config' + +const result = await multicall(config, { + batchSize: 1_024, // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`number` + +The block number to perform the read against. + +::: code-group +```tsx [index.tsx] +import { multicall } from '@wagmi/core' +import { config } from './config' + +const result = await multicall(config, { + blockNumber: 69420n, // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to read against. + +::: code-group +```tsx [index.tsx] +import { multicall } from '@wagmi/core' +import { config } from './config' + +const result = await multicall(config, { + blockTag: 'safe', // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### multicallAddress + +`Address` + +Address of multicall contract. + +::: code-group +```tsx [index.tsx] +import { multicall } from '@wagmi/core' +import { config } from './config' + +const result = await multicall(config, { + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], + multicallAddress: '0xca11bde05977b3631167028862be2a173976ca11', // [!code hl] +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + +## Return Type + +```ts +import { type MulticallReturnType } from '@wagmi/core' +``` + +## Type Inference + +With [`contracts[number]['abi']`](#abi) setup correctly, TypeScript will infer the correct types for [`functionName`](#functionname), [`args`](#args), and the return type. See the Wagmi [TypeScript docs](/core/typescript) for more information. + +## Error + +```ts +import { type MulticallErrorType } from '@wagmi/core' +``` + +## Viem + +- [`multicall`](https://viem.sh/docs/actions/public/multicall.html) diff --git a/site/core/api/actions/prepareTransactionRequest.md b/site/core/api/actions/prepareTransactionRequest.md new file mode 100644 index 0000000000..1a1f1fc207 --- /dev/null +++ b/site/core/api/actions/prepareTransactionRequest.md @@ -0,0 +1,307 @@ + + +# prepareTransactionRequest + +Action for preparing a transaction request for signing by populating a nonce, gas limit, fee values, and a transaction type. + +## Import + +```ts +import { prepareTransactionRequest } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { prepareTransactionRequest } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +await prepareTransactionRequest(config, { + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type PrepareTransactionRequestParameters } from '@wagmi/core' +``` + +### account + +`Account | Address | undefined` + +The Account to send the transaction from. + +::: code-group +```ts [index.ts] +import { prepareTransactionRequest } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +await prepareTransactionRequest(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### to + +`` `0x${string}` | undefined `` + +The transaction recipient or contract address. + +::: code-group +```ts [index.ts] +import { prepareTransactionRequest } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +await prepareTransactionRequest(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', // [!code focus] + value: parseEther('1'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### accessList + +`AccessList | undefined` + +The access list. + +::: code-group +```ts [index.ts] +import { prepareTransactionRequest } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +await prepareTransactionRequest(config, { + accessList: [ // [!code focus:6] + { + address: '0x1', + storageKeys: ['0x1'], + }, + ], + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +Chain ID to prepare the transaction request for. + +::: code-group +```ts [index.ts] +import { prepareTransactionRequest } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { parseEther } from 'viem' +import { config } from './config' + +await prepareTransactionRequest(config, { + chainId: mainnet.id, // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### data + +`` `0x${string}` | undefined `` + +A contract hashed method call with encoded args. + +::: code-group +```ts [index.ts] +import { prepareTransactionRequest } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +await prepareTransactionRequest(config, { + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### gasPrice + +`bigint | undefined` + +The price (in wei) to pay per gas. Only applies to [Legacy Transactions](https://viem.sh/docs/glossary/terms.html#legacy-transaction). + +::: code-group +```ts [index.ts] +import { prepareTransactionRequest } from '@wagmi/core' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +await prepareTransactionRequest(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + gasPrice: parseGwei('20'), // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### maxFeePerGas + +`bigint | undefined` + +Total fee per gas (in wei), inclusive of `maxPriorityFeePerGas`. Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { prepareTransactionRequest } from '@wagmi/core' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +await prepareTransactionRequest(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + maxFeePerGas: parseGwei('20'), // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### maxPriorityFeePerGas + +`bigint | undefined` + +Max priority fee per gas (in wei). Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { prepareTransactionRequest } from '@wagmi/core' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +await prepareTransactionRequest(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + maxFeePerGas: parseGwei('20'), + maxPriorityFeePerGas: parseGwei('2'), // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### nonce + +`number | undefined` + +Unique number identifying this transaction. + +::: code-group +```ts [index.ts] +import { prepareTransactionRequest } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +await prepareTransactionRequest(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + nonce: 5, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### parameters + +`("fees" | "gas" | "nonce" | "type")[] | undefined` + +Parameters to prepare. + +For instance, if `["gas", "nonce"]` is provided, then only the `gas` and `nonce` parameters will be prepared. + +::: code-group +```ts [index.ts] +import { prepareTransactionRequest } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +await prepareTransactionRequest(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + parameters: ['gas', 'nonce'], // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### value + +`bigint | undefined` + +The transaction recipient or contract address. + +::: code-group +```ts [index.ts] +import { prepareTransactionRequest } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +await prepareTransactionRequest(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type PrepareTransactionRequestReturnType } from '@wagmi/core' +``` + +[`TransactionRequest`](https://viem.sh/docs/glossary/types.html#transactionrequest) + +The transaction request. + +## Error + +```ts +import { type PrepareTransactionRequestErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`prepareTransactionRequest`](https://viem.sh/docs/actions/wallet/prepareTransactionRequest.html) diff --git a/site/core/api/actions/readContract.md b/site/core/api/actions/readContract.md new file mode 100644 index 0000000000..80dfbb0b2e --- /dev/null +++ b/site/core/api/actions/readContract.md @@ -0,0 +1,258 @@ + + +# readContract + +Action for calling a **read-only** function on a contract, and returning the response. + +A **read-only** function (constant function) on a Solidity contract is denoted by a pure or view keyword. They can only read the state of the contract, and cannot make any changes to it. Since read-only methods do not change the state of the contract, they do not require any gas to be executed, and can be called by any user without the need to pay for gas. + +## Import + +```ts +import { readContract } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { readContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await readContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'totalSupply', +}) +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type ReadContractParameters } from '@wagmi/core' +``` + +### abi + +`Abi` + +The contract's ABI. Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```ts [index.ts] +import { readContract } from '@wagmi/core' +import { abi } from './abi' // [!code focus] +import { config } from './config' + +const result = await readContract(config, { + abi, // [!code focus] + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'totalSupply', +}) +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### account + +`Account | undefined` + +Account to use when calling the contract (`msg.sender`). + +::: code-group +```ts [index.ts] +import { readContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await readContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'balanceOf', + args: ['0xd2135CfB216b74109775236E36d4b433F1DF507B'], + account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] +}) +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### address + +`Address` + +The contract's address. + +::: code-group +```ts [index.ts] +import { readContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await readContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', // [!code focus] + functionName: 'totalSupply', +}) +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### args + +`readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`functionName`](#functionname). + +::: code-group +```ts [index.ts] +import { readContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await readContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'balanceOf', + args: ['0xd2135CfB216b74109775236E36d4b433F1DF507B'], // [!code focus] +}) +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to call contract at. + +::: code-group +```ts [index.ts] +import { readContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await readContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'totalSupply', + blockNumber: 17829139n, // [!code focus] +}) +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to call contract at. + +::: code-group +```ts [index.ts] +import { readContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await readContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'totalSupply', + blockTag: 'safe', // [!code focus] +}) +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { readContract } from '@wagmi/core' +import { mainnet } from 'wagmi/chains' // [!code focus] +import { abi } from './abi' +import { config } from './config' + +const result = await readContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'totalSupply', + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### functionName + +`string` + +- Function to call on the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```ts [index.ts] +import { readContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await readContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'balanceOf', // [!code focus] + args: ['0xd2135CfB216b74109775236E36d4b433F1DF507B'], +}) +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type ReadContractReturnType } from '@wagmi/core' +``` + +`unknown` + +- Result of contract read-only function. +- Inferred from [`abi`](#abi), [`functionName`](#functionname), and [`args`](#args). + +## Type Inference + +With [`abi`](#abi) setup correctly, TypeScript will infer the correct types for [`functionName`](#functionname), [`args`](#args), and the return type. See the Wagmi [TypeScript docs](/core/typescript) for more information. + +## Error + +```ts +import { type ReadContractErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`readContract`](https://viem.sh/docs/contract/readContract.html) diff --git a/site/core/api/actions/readContracts.md b/site/core/api/actions/readContracts.md new file mode 100644 index 0000000000..67cbdf65af --- /dev/null +++ b/site/core/api/actions/readContracts.md @@ -0,0 +1,363 @@ + + +# readContracts + +Action for calling multiple read methods on a contract. + +## Import + +```ts +import { readContracts } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { readContracts } from '@wagmi/core' +import { config } from './config' + +const wagmigotchiContract = { + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + abi: wagmigotchiABI, +} as const +const mlootContract = { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, +} as const + +const result = await readContracts(config, { + contracts: [ + { + ...wagmigotchiContract, + functionName: 'getAlive', + }, + { + ...wagmigotchiContract, + functionName: 'getBoredom', + }, + { + ...mlootContract, + functionName: 'getChest', + args: [69], + }, + { + ...mlootContract, + functionName: 'getWaist', + args: [69], + }, + ], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type ReadContractsParameters } from '@wagmi/core' +``` + +### contracts + +`readonly Contract[]` + +Set of contracts to call. + +#### abi + +`Abi | undefined` + +The contract's ABI. Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```tsx [index.tsx] +import { readContracts } from '@wagmi/core' +import { config } from './config' + +const result = await readContracts(config, { + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, // [!code hl] + functionName: 'getChest', + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +#### address + +`Address | undefined` + +The contract's address. + +::: code-group +```tsx [index.tsx] +import { readContracts } from '@wagmi/core' +import { config } from './config' + +const result = await readContracts(config, { + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', // [!code hl] + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +#### args + +`readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`functionName`](#functionname). + +::: code-group +```tsx [index.tsx] +import { readContracts } from '@wagmi/core' +import { config } from './config' + +const result = await readContracts(config, { + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], // [!code hl] + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +#### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { readContracts } from '@wagmi/core' +import { config } from './config' + +const result = await readContracts(config, { + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + chainId: 1, // [!code hl] + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + +#### functionName + +`string | undefined` + +- Function to call on the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```tsx [index.tsx] +import { readContracts } from '@wagmi/core' +import { config } from './config' + +const result = await readContracts(config, { + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', // [!code hl] + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### allowFailure + +`boolean` + +Whether or not the Hook should throw if a call reverts. If set to `true` (default), and a call reverts, then `readContracts` will fail silently and its error will be logged in the results array. Defaults to `true`. + +::: code-group +```tsx [index.tsx] +import { readContracts } from '@wagmi/core' +import { config } from './config' + +const result = await readContracts(config, { + allowFailure: false, // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### batchSize + +`number` + +The maximum size (in bytes) for each calldata chunk. Set to `0` to disable the size limit. Defaults to `1024`. + +> Note: Some RPC Providers limit the amount of calldata (`data`) that can be sent in a single `eth_call` request. It is best to check with your RPC Provider to see if there are any calldata size limits to `eth_call` requests. + +::: code-group +```tsx [index.tsx] +import { readContracts } from '@wagmi/core' +import { config } from './config' + +const result = await readContracts(config, { + batchSize: 1_024, // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`number` + +The block number to perform the read against. + +::: code-group +```tsx [index.tsx] +import { readContracts } from '@wagmi/core' +import { config } from './config' + +const result = await readContracts(config, { + blockNumber: 69420n, // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to read against. + +::: code-group +```tsx [index.tsx] +import { readContracts } from '@wagmi/core' +import { config } from './config' + +const result = await readContracts(config, { + blockTag: 'safe', // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### multicallAddress + +`Address` + +Address of multicall contract. + +::: code-group +```tsx [index.tsx] +import { readContracts } from '@wagmi/core' +import { config } from './config' + +const result = await readContracts(config, { + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], + multicallAddress: '0xca11bde05977b3631167028862be2a173976ca11', // [!code hl] +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type ReadContractsReturnType } from '@wagmi/core' +``` + +## Type Inference + +With [`contracts[number]['abi']`](#abi) setup correctly, TypeScript will infer the correct types for [`functionName`](#functionname), [`args`](#args), and the return type. See the Wagmi [TypeScript docs](/core/typescript) for more information. + +## Error + +```ts +import { type ReadContractsErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`multicall`](https://viem.sh/docs/actions/public/multicall.html) when supported by current chain. +- [`readContract`](https://viem.sh/docs/contract/readContract.html) when multicall is not supported. diff --git a/site/core/api/actions/reconnect.md b/site/core/api/actions/reconnect.md new file mode 100644 index 0000000000..983be9aa76 --- /dev/null +++ b/site/core/api/actions/reconnect.md @@ -0,0 +1,72 @@ + + +# reconnect + +Action for reconnecting [connectors](/core/api/connectors). + +## Import + +```ts +import { reconnect } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { reconnect } from '@wagmi/core' +import { injected } from '@wagmi/connectors' +import { config } from './config' + +const result = await reconnect(config, { connectors: [injected()] }) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type ReconnectParameters } from '@wagmi/core' +``` + +### connectors + +`(CreateConnectorFn | Connector)[] | undefined` + +- [Connectors](/core/api/connectors) to reconnect to. +- Defaults to [`Config['connectors']`](/core/api/createConfig#connectors). + +::: code-group +```ts [index.ts] +import { reconnect } from '@wagmi/core' +import { injected } from '@wagmi/connectors' +import { config } from './config' + +const result = await reconnect(config, { + connectors: [injected()], // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type ReconnectReturnType } from '@wagmi/core' +``` + +`Connection[]` + +[Connections](/core/api/createConfig#connection) that were successfully reconnected. + +## Error + +```ts +import { type ReconnectErrorType } from '@wagmi/core' +``` + + diff --git a/site/core/api/actions/sendCalls.md b/site/core/api/actions/sendCalls.md new file mode 100644 index 0000000000..8e65890e5e --- /dev/null +++ b/site/core/api/actions/sendCalls.md @@ -0,0 +1,223 @@ + + +# sendCalls + +Action that requests for the wallet to sign and broadcast a batch of calls (transactions) to the network. + +[Read more.](https://github.com/ethereum/EIPs/blob/815028dc634463e1716fc5ce44c019a6040f0bef/EIPS/eip-5792.md#wallet_sendcalls) + + + +## Import + +```ts +import { sendCalls } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { parseEther } from 'viem' +import { sendCalls } from '@wagmi/core' +import { config } from './config' + +const id = await sendCalls(config, { + calls: [ + { + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1') + }, + { + data: '0xdeadbeef', + to: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + }, + ] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type SendCallsParameters } from '@wagmi/core' +``` + +### account + +`Account | Address | null | undefined` + +Account to execute the calls. + +If set to `null`, it is assumed that the wallet will handle filling the sender of the calls. + +::: code-group +```ts [index.ts] +import { parseEther } from 'viem' +import { sendCalls } from '@wagmi/core' +import { config } from './config' + +const id = await sendCalls(config, { + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', // [!code focus] + calls: [ + { + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1') + }, + { + data: '0xdeadbeef', + to: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + }, + ], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### calls + +`{ to: Hex, data?: Hex, value?: bigint }[]` + +Calls to execute. + +::: code-group +```ts [index.ts] +import { parseEther } from 'viem' +import { sendCalls } from '@wagmi/core' +import { config } from './config' + +const id = await sendCalls(config, { + calls: [ // [!code focus] + { // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', // [!code focus] + value: parseEther('1') // [!code focus] + }, // [!code focus] + { // [!code focus] + data: '0xdeadbeef', // [!code focus] + to: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', // [!code focus] + }, // [!code focus] + ], // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### capabilities + +`WalletCapabilities | undefined` + +Capability metadata for the calls (e.g. specifying a paymaster). + +::: code-group +```ts [index.ts] +import { parseEther } from 'viem' +import { sendCalls } from '@wagmi/core' +import { config } from './config' + +const id = await sendCalls(config, { + calls: [ + { + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1') + }, + { + data: '0xdeadbeef', + to: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + }, + ], + capabilities: { // [!code focus] + paymasterService: { // [!code focus] + url: 'https://...' // [!code focus] + } // [!code focus] + } // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`number | undefined` + +The target chain ID to broadcast the calls. + +::: code-group +```ts [index.ts] +import { parseEther } from 'viem' +import { sendCalls } from '@wagmi/core' +import { config } from './config' + +const id = await sendCalls(config, { + calls: [ + { + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1') + }, + { + data: '0xdeadbeef', + to: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + }, + ], + chainId: 10, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +Connector to get send the calls with. + +::: code-group +```ts [index.ts] +import { parseEther } from 'viem' +import { getConnections } from '@wagmi/core' +import { sendCalls } from '@wagmi/core' +import { config } from './config' + +const connections = getConnections(config) +const id = await sendCalls(config, { + calls: [ + { + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1') + }, + { + data: '0xdeadbeef', + to: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + }, + ], + connector: connections[0]?.connector, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type SendCallsReturnType } from '@wagmi/core' +``` + +`bigint` + +Most recent block number seen. + +## Error + +```ts +import { type SendCallsErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`sendCalls`](https://viem.sh/experimental/eip5792/sendCalls) diff --git a/site/core/api/actions/sendTransaction.md b/site/core/api/actions/sendTransaction.md new file mode 100644 index 0000000000..e02e1908dc --- /dev/null +++ b/site/core/api/actions/sendTransaction.md @@ -0,0 +1,341 @@ + + +# sendTransaction + +Action for creating, signing, and sending transactions to networks. + +## Import + +```ts +import { sendTransaction } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type SendTransactionParameters } from '@wagmi/core' +``` + +### accessList + +`AccessList | undefined` + +The access list. + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + accessList: [{ // [!code focus] + address: '0x1', // [!code focus] + storageKeys: ['0x1'], // [!code focus] + }], // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### account + +`Address | Account | undefined` + +Account to use when sending transaction. Throws if account is not found on [`connector`](#connector). + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + account: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +Chain ID to validate against before sending transaction. + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + chainId: mainnet.id, // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +- Connector to send transaction with. +- Defaults to current connector. + +::: code-group +```ts [index.ts] +import { getConnections, sendTransaction } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const connections = getConnections(config) +const result = await sendTransaction(config, { + connector: connections[0]?.connector, // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### data + +`` `0x${string}` | undefined `` + +A contract hashed method call with encoded args. + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### gas + +`bigint | undefined | null` + +Gas provided for transaction execution. + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + gas: parseGwei('20'), // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### gasPrice + +`bigint | undefined` + +The price in wei to pay per gas. Only applies to [Legacy Transactions](https://viem.sh/docs/glossary/terms.html#legacy-transaction). + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + gasPrice: parseGwei('20'), // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### maxFeePerGas + +`bigint | undefined` + +Total fee per gas in wei, inclusive of [`maxPriorityFeePerGas`](#maxPriorityFeePerGas). Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + maxFeePerGas: parseGwei('20'), // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### maxPriorityFeePerGas + +`bigint | undefined` + +Max priority fee per gas in wei. Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + maxFeePerGas: parseGwei('20'), + maxPriorityFeePerGas: parseGwei('2'), // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### nonce + +`number` + +Unique number identifying this transaction. + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + nonce: 123, // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### to + +`Address` + +The transaction recipient or contract address. + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### type + +`'legacy' | 'eip1559' | 'eip2930' | undefined` + +Optional transaction request type to narrow parameters. + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + type: 'eip1559', // [!code focus] + value: parseEther('0.01'), +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### value + +`bigint | undefined` + +Value in wei sent with this transaction. + +::: code-group +```ts [index.ts] +import { sendTransaction } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +const result = await sendTransaction(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type SendTransactionReturnType } from '@wagmi/core' +``` + +[`Hash`](https://viem.sh/docs/glossary/types.html#hash) + +Transaction hash. + +## Error + +```ts +import { type SendTransactionErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`sendTransaction`](https://viem.sh/docs/actions/wallet/sendTransaction.html) diff --git a/site/core/api/actions/showCallsStatus.md b/site/core/api/actions/showCallsStatus.md new file mode 100644 index 0000000000..c47d1fb88d --- /dev/null +++ b/site/core/api/actions/showCallsStatus.md @@ -0,0 +1,99 @@ + + +# showCallsStatus + +Action to request for the wallet to show information about a call batch that was sent via `showCalls`. + +[Read more.](https://github.com/ethereum/EIPs/blob/1663ea2e7a683285f977eda51c32cec86553f585/EIPS/eip-5792.md#wallet_showcallsstatus) + + + +## Import + +```ts +import { showCallsStatus } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { showCallsStatus } from '@wagmi/core' +import { config } from './config' + +await showCallsStatus(config, { + id: '0x1234567890abcdef', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type ShowCallsStatusParameters } from '@wagmi/core' +``` + +### connector + +`Connector | undefined` + +Connector to show call statuses with. + +::: code-group +```ts [index.ts] +import { getConnections, showCallsStatus } from '@wagmi/core' +import { config } from './config' + +const connections = getConnections(config) +await showCallsStatus(config, { + connector: connections[0]?.connector, // [!code focus] + id: '0x1234567890abcdef', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### id + +`string` + +Identifier of the call batch. + +::: code-group +```ts [index.ts] +import { showCallsStatus } from '@wagmi/core' +import { config } from './config' + +await showCallsStatus(config, { + id: '0x1234567890abcdef', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type ShowCallsStatusReturnType } from '@wagmi/core' +``` + +`bigint` + +Most recent block number seen. + +## Error + +```ts +import { type ShowCallsStatusErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`showCallsStatus`](https://viem.sh/experimental/eip5792/showCallsStatus) diff --git a/site/core/api/actions/signMessage.md b/site/core/api/actions/signMessage.md new file mode 100644 index 0000000000..23569146ac --- /dev/null +++ b/site/core/api/actions/signMessage.md @@ -0,0 +1,125 @@ + + +# signMessage + +Action for signing messages. + +## Import + +```ts +import { signMessage } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { signMessage } from '@wagmi/core' +import { config } from './config' + +await signMessage(config, { message: 'hello world' }) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type SignMessageParameters } from '@wagmi/core' +``` + +### account + +`Address | Account | undefined` + +Account to use when signing message. Throws if account is not found on [`connector`](#connector). + +::: code-group +```ts [index.ts] +import { signMessage } from '@wagmi/core' +import { config } from './config' + +const result = await signMessage(config, { + account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + message: 'hello world', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +[Connector](/core/api/connectors) to sign message with. + +::: code-group +```ts [index.ts] +import { getAccount, signMessage } from '@wagmi/core' +import { config } from './config' + +const { connector } = getAccount(config) +const result = await signMessage(config, { + connector, // [!code focus] + message: 'hello world', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### message + +`string | { raw: Hex | ByteArray }` + +Message to sign. + +::: code-group +```ts [index.ts] +import { signMessage } from '@wagmi/core' +import { config } from './config' + +const result = await signMessage(config, { + message: 'hello world', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +::: tip +By default, viem signs the UTF-8 representation of the message. To sign the data representation of the message, you can use the `raw` attribute. + +```ts +import { signMessage } from '@wagmi/core' +import { config } from './config' + +const result = await signMessage(config, { + message: { raw: '0x68656c6c6f20776f726c64' }, // [!code focus] +}) +``` +::: + +## Return Type + +```ts +import { type SignMessageReturnType } from '@wagmi/core' +``` + +[`Hex`](https://viem.sh/docs/glossary/types.html#hex) + +The signed message. + +## Error + +```ts +import { type SignMessageErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`signMessage`](https://viem.sh/docs/actions/wallet/signMessage.html) diff --git a/site/core/api/actions/signTypedData.md b/site/core/api/actions/signTypedData.md new file mode 100644 index 0000000000..757c87160f --- /dev/null +++ b/site/core/api/actions/signTypedData.md @@ -0,0 +1,409 @@ + + +# signTypedData + +Action for signing typed data and calculating an Ethereum-specific [EIP-712](https://eips.ethereum.org/EIPS/eip-712) signature. + +## Import + +```ts +import { signTypedData } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { signTypedData } from '@wagmi/core' +import { config } from './config' + +const result = await signTypedData(config, { + types: { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], + }, + primaryType: 'Mail', + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type SignTypedDataParameters } from '@wagmi/core' +``` + +### account + +`Address | Account | undefined` + +Account to use when signing data. Throws if account is not found on [`connector`](#connector). + +::: code-group +```ts [index.ts] +import { signTypedData } from '@wagmi/core' +import { config } from './config' +import { types } from './typedData' + +const result = await signTypedData(config, { + account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + types, + primaryType: 'Mail', + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, +}) +``` +<<< @/snippets/typedData.ts[typedData.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +[Connector](/core/api/connectors) to sign data with. + +::: code-group +```ts [index.ts] +import { getAccount, signTypedData } from '@wagmi/core' +import { config } from './config' +import { types } from './typedData' + +const { connector } = getAccount(config) +const result = await signTypedData(config, { + connector, // [!code focus] + types, + primaryType: 'Mail', + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, +}) +``` +<<< @/snippets/typedData.ts[typedData.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### domain + +`TypedDataDomain | undefined` + +- The typed data domain. +- If `EIP712Domain` key exists in [`types`](#types), `domain` schema is inferred from it. + +::: code-group +```ts [index.ts] +import { signTypedData } from '@wagmi/core' +import { config } from './config' +import { types } from './typedData' + +const result = await signTypedData(config, { + domain: { // [!code focus] + name: 'Ether Mail', // [!code focus] + chainId: 1, // [!code focus] + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', // [!code focus] + version: '1', // [!code focus] + }, // [!code focus] + types, + primaryType: 'Mail', + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, +}) +``` +<<< @/snippets/typedData.ts[typedData.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### message + +`Record` + +- Data to sign. +- Type inferred from [`types`](#types) and [`primaryType`](#primarytype). + +::: code-group +```ts [index.ts] +import { signTypedData } from '@wagmi/core' +import { config } from './config' +import { types } from './typedData' + +const result = await signTypedData(config, { + types, + primaryType: 'Mail', + message: { // [!code focus] + from: { // [!code focus] + name: 'Cow', // [!code focus] + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', // [!code focus] + }, // [!code focus] + to: { // [!code focus] + name: 'Bob', // [!code focus] + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', // [!code focus] + }, // [!code focus] + contents: 'Hello, Bob!', // [!code focus] + }, // [!code focus] +}) +``` +<<< @/snippets/typedData.ts[typedData.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### primaryType + +`string` + +- The primary type to extract from [`types`](#types) and use in [`message`](#message). +- Type inferred from [`types`](#types). + +::: code-group +```ts [index.ts] +import { signTypedData } from '@wagmi/core' +import { config } from './config' +import { types } from './typedData' + +const result = await signTypedData(config, { + types, + primaryType: 'Mail', // [!code focus] + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, +}) +``` +<<< @/snippets/typedData.ts[typedData.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### types + +`TypedData` + +- The type definitions for the typed data. +- By defining inline or adding a [const assertion](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-4.html#const-assertions) to `types`, TypeScript will infer the correct types for [`message`](#message) and [`primaryType`](#primarytype). See the Wagmi [TypeScript docs](/core/typescript) for more information. + +::: code-group +```ts [index.ts] +import { signTypedData } from '@wagmi/core' +import { config } from './config' + +const result = await signTypedData(config, { + types: { // [!code focus] + Person: [ // [!code focus] + { name: 'name', type: 'string' }, // [!code focus] + { name: 'wallet', type: 'address' }, // [!code focus] + ], // [!code focus] + Mail: [ // [!code focus] + { name: 'from', type: 'Person' }, // [!code focus] + { name: 'to', type: 'Person' }, // [!code focus] + { name: 'contents', type: 'string' }, // [!code focus] + ], // [!code focus] + }, // [!code focus] + primaryType: 'Mail', + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type SignTypedDataReturnType } from '@wagmi/core' +``` + +[`Hex`](https://viem.sh/docs/glossary/types.html#hex) + +The signed data. + +## Type Inference + +With [`types`](#types) setup correctly, TypeScript will infer the correct types for [`domain`](#domain), [`message`](#message), and [`primaryType`](#primarytype). See the Wagmi [TypeScript docs](/core/typescript) for more information. + +::: code-group +```ts twoslash [Inline] +import { createConfig, http, signTypedData } from '@wagmi/core' +import { mainnet, sepolia } from '@wagmi/core/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +// ---cut--- +const result = await signTypedData(config, { + types: { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], + }, + primaryType: 'Mail', + // ^? + + + message: { + // ^? + + + + + + + + + + + + + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, +}) +``` +```ts twoslash [Const-Asserted] +import { createConfig, http, signTypedData } from '@wagmi/core' +import { mainnet, sepolia } from '@wagmi/core/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +// ---cut--- +const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const + +const result = await signTypedData(config, { + types, + primaryType: 'Mail', + // ^? + + + message: { + // ^? + + + + + + + + + + + + + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, +}) +``` +::: + +## Error + +```ts +import { type SignTypedDataErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`signTypedData`](https://viem.sh/docs/actions/wallet/signTypedData.html) diff --git a/site/core/api/actions/simulateContract.md b/site/core/api/actions/simulateContract.md new file mode 100644 index 0000000000..b7884ef713 --- /dev/null +++ b/site/core/api/actions/simulateContract.md @@ -0,0 +1,598 @@ + + +# simulateContract + +Action for simulating/validating a contract interaction. + +## Import + +```ts +import { simulateContract } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type SimulateContractParameters } from '@wagmi/core' +``` + +### abi + +`Abi` + +The contract's ABI. Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { abi } from './abi' // [!code focus] +import { config } from './config' + +const result = await simulateContract(config, { + abi, // [!code focus] + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### accessList + +`AccessList | undefined` + +The access list. + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + accessList: [{ // [!code focus] + address: '0x1', // [!code focus] + storageKeys: ['0x1'], // [!code focus] + }], // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### account + +`Address | Account | undefined` + +Account to use when signing data. Throws if account is not found on [`connector`](#connector). + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### address + +`Address` + +The contract's address. + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', // [!code focus] + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + + +### args + +`readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`functionName`](#functionname). + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ // [!code focus] + '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', // [!code focus] + 123n, // [!code focus] + ], // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to simulate against. + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + blockNumber: 17829139n, // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to simulate against. + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + blockTag: 'safe', // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +Chain ID to validate against before sending transaction. + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { mainnet } from 'wagmi/chains' // [!code focus] +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +[Connector](/core/api/connectors) to simulate transaction with. + +::: code-group +```ts [index.ts] +import { getAccount, simulateContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const { connector } = getAccount(config) +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + connector, // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### dataSuffix + +`` `0x${string}` | undefined `` + +Data to append to the end of the calldata. Useful for adding a ["domain" tag](https://opensea.notion.site/opensea/Seaport-Order-Attributions-ec2d69bf455041a5baa490941aad307f). + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + dataSuffix: '0xdeadbeef', // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### functionName + +`string` + +- Function to call on the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'approve', // [!code focus] + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', 123n] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### gas + +`bigint | undefined` + +Gas provided for transaction execution. + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + gas: parseGwei('20'), // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### gasPrice + +`bigint | undefined` + +The price in wei to pay per gas. Only applies to [Legacy Transactions](https://viem.sh/docs/glossary/terms.html#legacy-transaction). + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + gasPrice: parseGwei('20'), // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### maxFeePerGas + +`bigint | undefined` + +Total fee per gas in wei, inclusive of [`maxPriorityFeePerGas`](#maxPriorityFeePerGas). Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + maxFeePerGas: parseGwei('20'), // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### maxPriorityFeePerGas + +`bigint | undefined` + +Max priority fee per gas in wei. Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + maxFeePerGas: parseGwei('20'), + maxPriorityFeePerGas: parseGwei('2'), // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### nonce + +`number` + +Unique number identifying this transaction. + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + nonce: 123, // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### type + +`'legacy' | 'eip1559' | 'eip2930' | undefined` + +Optional transaction request type to narrow parameters. + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + type: 'eip1559', // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### value + +`bigint | undefined` + +Value in wei sent with this transaction. + +::: code-group +```ts [index.ts] +import { simulateContract } from '@wagmi/core' +import { parseEther } from 'viem' +import { abi } from './abi' +import { config } from './config' + +const result = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + value: parseEther('0.01'), // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type SimulateContractReturnType } from '@wagmi/core' +``` + +The simulation result and write request. + +### request + +Write request that includes [parameters](#parameters). + +### response + +`unknown` + +- Result of contract simulation. +- Inferred from [`abi`](#abi), [`functionName`](#functionname), and [`args`](#args). + +## Type Inference + +With [`abi`](#abi) setup correctly, TypeScript will infer the correct types for [`functionName`](#functionname), [`args`](#args), and [`value`](#value). See the Wagmi [TypeScript docs](/core/typescript) for more information. + +## Error + +```ts +import { type SimulateContractErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`simulateContract`](https://viem.sh/docs/contract/simulateContract.html) diff --git a/site/core/api/actions/switchAccount.md b/site/core/api/actions/switchAccount.md new file mode 100644 index 0000000000..8d0f629c13 --- /dev/null +++ b/site/core/api/actions/switchAccount.md @@ -0,0 +1,81 @@ + + +# switchAccount + +Action for switching the current account. + +## Import + +```ts +import { switchAccount } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { getConnections, switchAccount } from '@wagmi/core' +import { config } from './config' + +const connections = getConnections(config) +const result = await switchAccount(config, { + connector: connections[0]?.connector, +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type SwitchAccountParameters } from '@wagmi/core' +``` + +### connector + +`Connector` + +[Connector](/core/api/connectors) to switch to. + +::: code-group +```ts [index.ts] +import { getConnections, switchAccount } from '@wagmi/core' +import { config } from './config' + +const connections = getConnections(config) +const result = await switchAccount(config, { + connector: connections[0]?.connector, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type SwitchAccountReturnType } from '@wagmi/core' +``` + +### accounts + +`readonly [Address, ...Address[]]` + +Connected accounts from connector. + +### chainId + +`number` + +Connected chain ID from connector. + +## Error + +```ts +import { type SwitchAccountErrorType } from '@wagmi/core' +``` + + diff --git a/site/core/api/actions/switchChain.md b/site/core/api/actions/switchChain.md new file mode 100644 index 0000000000..c741e801c8 --- /dev/null +++ b/site/core/api/actions/switchChain.md @@ -0,0 +1,122 @@ + + +# switchChain + +Action for switching the target chain for a connector or the Wagmi [`Config`](/core/api/createConfig#config). + +## Import + +```ts +import { switchChain } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { switchChain } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +await switchChain(config, { chainId: mainnet.id }) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +::: tip +When connected, `switchChain` will switch the target chain for the connector. When not connected, `switchChain` will switch the target chain for the Wagmi [`Config`](/core/api/createConfig#config). +::: + +## Parameters + +```ts +import { type SwitchChainParameters } from '@wagmi/core' +``` + +### addEthereumChainParameter + +`{ chainName: string; nativeCurrency?: { name: string; symbol: string; decimals: number } | undefined; rpcUrls: readonly string[]; blockExplorerUrls?: string[] | undefined; iconUrls?: string[] | undefined } | undefined` + +[EIP-3085 parameters](https://eips.ethereum.org/EIPS/eip-3085) to use when adding chain to connector (when supported). + +::: code-group +```ts [index.ts] +import { switchChain } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const result = await switchChain(config, { + addEthereumChainParameter: { // [!code focus] + iconUrls: ['https://example.com/icon.png'], // [!code focus] + }, // [!code focus] + chainId: mainnet.id, +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to switch to. + +::: code-group +```ts [index.ts] +import { switchChain } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const result = await switchChain(config, { + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector` + +[Connector](/core/api/connectors) to switch chain with. + +::: code-group +```ts [index.ts] +import { getConnections, switchAccount } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const connections = getConnections(config) +const result = await switchChain(config, { + chainId: mainnet.id, + connector: connections[0]?.connector, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type SwitchChainReturnType } from '@wagmi/core' +``` + +`Chain` + +Chain that was switched to. + +## Error + +```ts +import { type SwitchChainErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`switchChain`](https://viem.sh/docs/actions/wallet/switchChain.html) when connected. diff --git a/site/core/api/actions/verifyMessage.md b/site/core/api/actions/verifyMessage.md new file mode 100644 index 0000000000..93d46992b9 --- /dev/null +++ b/site/core/api/actions/verifyMessage.md @@ -0,0 +1,200 @@ + + +# verifyMessage + +Action for verify that a message was signed by the provided address. It supports verifying messages that were signed by either a Smart Contract Account or Externally Owned Account. + +## Import + +```ts +import { verifyMessage } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { verifyMessage } from '@wagmi/core' +import { config } from './config' + +await verifyMessage(config, { + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type VerifyMessageParameters } from '@wagmi/core' +``` + +### address + +`Address` + +The Ethereum address that signed the original message. + +::: code-group +```ts [index.ts] +import { verifyMessage } from '@wagmi/core' +import { config } from './config' + +await verifyMessage(config, { + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', // [!code focus] + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### message + +`string | { raw: Hex | ByteArray }` + +The message to be verified. + +By default, wagmi verifies the UTF-8 representation of the message. + +::: code-group +```ts [index.ts] +import { getAccount, verifyMessage } from '@wagmi/core' +import { config } from './config' + +await verifyMessage(config, { + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', // [!code focus] + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +::: tip +By default, viem signs the UTF-8 representation of the message. To sign the data representation of the message, you can use the `raw` attribute. + +```ts +import { verifyMessage } from '@wagmi/core' +import { config } from './config' + +await verifyMessage(config, { + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: { raw: '0x68656c6c6f20776f726c64' } // [!code focus] + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +``` +::: + +### signature + +`Hex | ByteArray ` + +The signature that was generated by signing the message with the address's signer. + +::: code-group +```ts [index.ts] +import { verifyMessage } from '@wagmi/core' +import { config } from './config' + +await verifyMessage(config, { + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +Only used when verifying a message that was signed by a Smart Contract Account. The ID of chain to check if the contract was already deployed. + +::: code-group +```ts [index.ts] +import { verifyMessage } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +await verifyMessage(config, { + chainId: mainnet.id, // [!code focus] + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +Only used when verifying a message that was signed by a Smart Contract Account. The block number to check if the contract was already deployed. + +::: code-group +```ts [index.ts] +import { verifyMessage } from '@wagmi/core' +import { config } from './config' + +await verifyMessage(config, { + blockNumber: 12345678n, // [!code focus] + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Only used when verifying a message that was signed by a Smart Contract Account. The block tag to check if the contract was already deployed. + +::: code-group +```ts [index.ts] +import { verifyMessage } from '@wagmi/core' +import { config } from './config' + +await verifyMessage(config, { + blockTag: 'latest', // [!code focus] + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type VerifyMessageReturnType } from '@wagmi/core' +``` + +`boolean` + +Whether the signed message is valid for the given address. + +## Error + +```ts +import { type VerifyMessageErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`verifyMessage`](https://viem.sh/docs/actions/public/verifyMessage.html) diff --git a/site/core/api/actions/verifyTypedData.md b/site/core/api/actions/verifyTypedData.md new file mode 100644 index 0000000000..e9afa17ad4 --- /dev/null +++ b/site/core/api/actions/verifyTypedData.md @@ -0,0 +1,595 @@ + + +# verifyTypedData + +Action for verify that a typed data was signed by the provided address. It supports verifying typed data that were signed by either a Smart Contract Account or Externally Owned Account. + +## Import + +```ts +import { verifyTypedData } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { verifyTypedData } from '@wagmi/core' +import { domain, types } from './data' +import { config } from './config' + +const valid = await verifyTypedData(config, { + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +// true +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type VerifyTypedDataParameters } from '@wagmi/core' +``` + +### address + +`Address` + +The Ethereum address that signed the original typed data. + +::: code-group +```ts [index.ts] +import { verifyTypedData } from '@wagmi/core' +import { domain, types } from './data' +import { config } from './config' + +const valid = await verifyTypedData(config, { + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', // [!code focus] + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +// true +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### domain + +`TypedDataDomain` + +The typed data domain. + +::: code-group +```ts [index.ts] +import { verifyTypedData } from '@wagmi/core' +import { types } from './data' +import { config } from './config' + +const valid = await verifyTypedData(config, { + domain: { // [!code focus:6] + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', + }, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +// true +``` +```ts [data.ts] +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### types + +The type definitions for the typed data. + +::: code-group +```ts [index.ts] +import { verifyTypedData } from '@wagmi/core' +import { domain } from './data' +import { config } from './config' + +const valid = await verifyTypedData(config, { + domain, + types: { // [!code focus:11] + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +// true +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### primaryType + +`string` + +The primary `type` to extract from types and use in `value`. + +::: code-group +```ts [index.ts] +import { verifyTypedData } from '@wagmi/core' +import { domain } from './data' +import { config } from './config' + +const valid = await verifyTypedData(config, { + domain, + types: { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ // [!code focus:5] + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], + }, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', // [!code focus] + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +// true +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### message + +Type inferred from `types` & `primaryType`. + +The message to be verified. + +::: code-group +```ts [index.ts] +import { verifyTypedData } from '@wagmi/core' +import { domain, types } from './data' +import { config } from './config' + +const valid = await verifyTypedData(config, { + domain, + types, + message: { // [!code focus:11] + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +// true +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### signature + +`Hex | ByteArray` + +The signature that was generated by signing the typed data with the address's signer. + +::: code-group +```ts [index.ts] +import { verifyTypedData } from '@wagmi/core' +import { domain, types } from './data' +import { config } from './config' + +const valid = await verifyTypedData(config, { + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', // [!code focus] +}) +// true +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +Only used when verifying a typed data that was signed by a Smart Contract Account. The ID of chain to check if the contract was already deployed. + +::: code-group +```ts [index.ts] +import { verifyTypedData } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { domain, types } from './data' +import { config } from './config' + +const valid = await verifyTypedData(config, { + chainId: mainnet.id, // [!code focus] + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +// true +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +Only used when verifying a typed data that was signed by a Smart Contract Account. The block number to check if the contract was already deployed. + +::: code-group +```ts [index.ts] +import { verifyTypedData } from '@wagmi/core' +import { domain, types } from './data' +import { config } from './config' + +const valid = await verifyTypedData(config, { + blockNumber: 12345678n, // [!code focus] + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +// true +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Only used when verifying a typed data that was signed by a Smart Contract Account. The block number to check if the contract was already deployed. + +::: code-group +```ts [index.ts] +import { verifyTypedData } from '@wagmi/core' +import { domain, types } from './data' +import { config } from './config' + +const valid = await verifyTypedData(config, { + blockTag: 'latest', // [!code focus] + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', +}) +// true +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type VerifyTypedDataReturnType } from '@wagmi/core' +``` + +`boolean` + +Whether the signed message is valid for the given address. + +## Type Inference + +With [`types`](#types) setup correctly, TypeScript will infer the correct types for [`domain`](#domain), [`message`](#message), and [`primaryType`](#primarytype). See the Wagmi [TypeScript docs](/core/typescript) for more information. + +## Error + +```ts +import { type VerifyTypedDataErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`verifyTypedData`](https://viem.sh/docs/actions/public/verifyTypedData.html) diff --git a/site/core/api/actions/waitForCallsStatus.md b/site/core/api/actions/waitForCallsStatus.md new file mode 100644 index 0000000000..8261801046 --- /dev/null +++ b/site/core/api/actions/waitForCallsStatus.md @@ -0,0 +1,143 @@ + + +# waitForCallsStatus + +Waits for a call bundle to be confirmed & included on a block before returning the status & receipts. + + + +## Import + +```ts +import { waitForCallsStatus } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { parseEther } from 'viem' +import { sendCalls, waitForCallsStatus } from '@wagmi/core' +import { config } from './config' + +const id = await sendCalls(config, { + calls: [{ + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1') + }] +}) + +const { status, receipts } = await waitForCallsStatus(config, { // [!code focus] + id, // [!code focus] +}) // [!code focus] +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WaitForCallsStatusParameters } from '@wagmi/core' +``` + +### connector + +`Connector | undefined` + +Connector to get call statuses with. + +::: code-group +```ts [index.ts] +import { getConnections, waitForCallsStatus } from '@wagmi/core' +import { config } from './config' + +const connections = getConnections(config) +const status = await waitForCallsStatus(config, { + connector: connections[0]?.connector, // [!code focus] + id: '0x1234567890abcdef', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### id + +`string` + +Identifier of the call batch. + +::: code-group +```ts [index.ts] +import { waitForCallsStatus } from '@wagmi/core' +import { config } from './config' + +const status = await waitForCallsStatus(config, { + id: '0x1234567890abcdef', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### pollingInterval + +`number` + +Polling interval in milliseconds. + +::: code-group +```ts [index.ts] +import { waitForCallsStatus } from '@wagmi/core' +import { config } from './config' + +const status = await waitForCallsStatus(config, { + id: '0x1234567890abcdef', + pollingInterval: 1_000, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### timeout + +`number` + +Timeout in milliseconds before `waitForCallsStatus` stops polling. + +::: code-group +```ts [index.ts] +import { waitForCallsStatus } from '@wagmi/core' +import { config } from './config' + +const status = await waitForCallsStatus(config, { + id: '0x1234567890abcdef', + timeout: 10_000, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WaitForCallsStatusReturnType } from '@wagmi/core' +``` + +`{ status: 'PENDING' | 'CONFIRMED', receipts: TransactionReceipt[] }` + +The status and receipts of the call batch. + +## Error + +```ts +import { type WaitForCallsStatusErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`waitForCallsStatus`](https://viem.sh/experimental/eip5792/waitForCallsStatus) diff --git a/site/core/api/actions/waitForTransactionReceipt.md b/site/core/api/actions/waitForTransactionReceipt.md new file mode 100644 index 0000000000..853189055d --- /dev/null +++ b/site/core/api/actions/waitForTransactionReceipt.md @@ -0,0 +1,155 @@ + + +# waitForTransactionReceipt + +Action that waits for the transaction to be included on a block, and then returns the transaction receipt. If the transaction reverts, then the action will throw an error. Replacement detection (e.g. sped up transactions) is also supported. + +## Import + +```ts +import { waitForTransactionReceipt } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { waitForTransactionReceipt } from '@wagmi/core' +import { config } from './config' + +const transactionReceipt = waitForTransactionReceipt(config, { + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WaitForTransactionReceiptParameters } from '@wagmi/core' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { waitForTransactionReceipt } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const transactionReceipt = await waitForTransactionReceipt(config, { + chainId: mainnet.id, // [!code focus] + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### confirmations + +`number | undefined` + +The number of confirmations (blocks that have passed) to wait before resolving. + +::: code-group +```ts [index.ts] +import { waitForTransactionReceipt } from '@wagmi/core' +import { config } from './config' + +const transactionReceipt = await waitForTransactionReceipt(config, { + confirmations: 2, // [!code focus] + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### onReplaced + +` +(({ reason: 'replaced' | 'repriced' | 'cancelled'; replacedTransaction: Transaction; transaction: Transaction; transactionReceipt: TransactionReceipt }) => void) | undefined +` + +Optional callback to emit if the transaction has been replaced. + +::: code-group +```ts [index.ts] +import { waitForTransactionReceipt } from '@wagmi/core' +import { config } from './config' + +const transactionReceipt = await waitForTransactionReceipt(config, { + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', + onReplaced: replacement => console.log(replacement), // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### hash + +`` `0x${string}` `` + +The transaction hash to wait for. + +::: code-group +```ts [index.ts] +import { waitForTransactionReceipt } from '@wagmi/core' +import { config } from './config' + +const transactionReceipt = await waitForTransactionReceipt(config, { + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/core/api/createConfig#pollinginterval). + +::: code-group +```ts [index.ts] +import { waitForTransactionReceipt } from '@wagmi/core' +import { config } from './config' + +const transactionReceipt = await waitForTransactionReceipt(config, { + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', + pollingInterval: 1_000, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WaitForTransactionReceiptReturnType } from '@wagmi/core' +``` + +[`TransactionReceipt`](https://viem.sh/docs/glossary/types.html#transactionreceipt) + +The transaction receipt. + +## Error + +```ts +import { type WaitForTransactionReceiptErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`waitForTransactionReceipt`](https://viem.sh/docs/actions/public/waitForTransactionReceipt.html) diff --git a/site/core/api/actions/watchAccount.md b/site/core/api/actions/watchAccount.md new file mode 100644 index 0000000000..a71ca4d161 --- /dev/null +++ b/site/core/api/actions/watchAccount.md @@ -0,0 +1,61 @@ +# watchAccount + +Subscribe to account changes. + +## Import + +```ts +import { watchAccount } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { watchAccount } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchAccount(config, { + onChange(data) { + console.log('Account changed!', data) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WatchAccountParameters } from '@wagmi/core' +``` + +### onChange + +`onChange(account: GetAccountReturnType, prevAccount: GetAccountReturnType): void` + +Callback function called when account changes. + +::: code-group +```ts [index.ts] +import { watchAccount } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchAccount(config, { + onChange(account) { // [!code focus:3] + console.log('Account changed!', account) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WatchAccountReturnType } from '@wagmi/core' +``` + +Function for cleaning up watcher. \ No newline at end of file diff --git a/site/core/api/actions/watchAsset.md b/site/core/api/actions/watchAsset.md new file mode 100644 index 0000000000..394dadd7ae --- /dev/null +++ b/site/core/api/actions/watchAsset.md @@ -0,0 +1,134 @@ + + +# watchAsset + +Action for requesting user tracks the token in their wallet. Returns a boolean indicating if the token was successfully added. + +## Import + +```ts +import { watchAsset } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { watchAsset } from '@wagmi/core' +import { config } from './config' + +await watchAsset(config, { + type: 'ERC20', + options: { + address: '0x0000000000000000000000000000000000000000', + symbol: 'WAGMI', + decimals: 18, + }, +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WatchAssetParameters } from '@wagmi/core' +``` + +### connector + +`Connector | undefined` + +[Connector](/core/api/connectors) to sign message with. + +::: code-group +```ts [index.ts] +import { getAccount, watchAsset } from '@wagmi/core' +import { config } from './config' + +const { connector } = getAccount(config) +const result = await watchAsset(config, { + connector, // [!code focus] + options: { + address: '0x0000000000000000000000000000000000000000', + symbol: 'WAGMI', + decimals: 18, + }, + type: 'ERC20', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### options + +`{ address: string; symbol: string; decimals: number; image?: string | undefined; }` + +Asset options. + +::: code-group +```ts [index.ts] +import { watchAsset } from '@wagmi/core' +import { config } from './config' + +const result = await watchAsset(config, { + options: { // [!code focus] + address: '0x0000000000000000000000000000000000000000', // [!code focus] + symbol: 'WAGMI', // [!code focus] + decimals: 18, // [!code focus] + }, // [!code focus] + type: 'ERC20', +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### type + +`'ERC20'` + +Type of asset. + +::: code-group +```ts [index.ts] +import { watchAsset } from '@wagmi/core' +import { config } from './config' + +const result = await watchAsset(config, { + options: { + address: '0x0000000000000000000000000000000000000000', + symbol: 'WAGMI', + decimals: 18, + }, + type: 'ERC20', // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WatchAssetReturnType } from '@wagmi/core' +``` + +`boolean` + +Returns a boolean indicating if the token was successfully added. + +## Error + +```ts +import { type WatchAssetErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`watchAsset`](https://viem.sh/docs/actions/wallet/watchAsset.html) + diff --git a/site/core/api/actions/watchBlockNumber.md b/site/core/api/actions/watchBlockNumber.md new file mode 100644 index 0000000000..098fd6613e --- /dev/null +++ b/site/core/api/actions/watchBlockNumber.md @@ -0,0 +1,226 @@ +# watchBlockNumber + +Action that watches for block number changes. + +## Import + +```ts +import { watchBlockNumber } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { watchBlockNumber } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlockNumber(config, { + onBlockNumber(blockNumber) { + console.log('Block number changed!', blockNumber) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WatchBlockNumberParameters } from '@wagmi/core' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { watchBlockNumber } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const unwatch = watchBlockNumber(config, { + chainId: mainnet.id, // [!code focus] + onBlockNumber(blockNumber) { + console.log('Block number changed!', blockNumber) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### emitOnBegin + +`boolean | undefined` + +Whether or not to emit the latest block number to the callback when the subscription opens. + +::: code-group +```ts [index.ts] +import { watchBlockNumber } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlockNumber(config, { + emitOnBegin: true, // [!code focus] + onBlockNumber(blockNumber) { + console.log('Block number changed!', blockNumber) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### emitMissed + +`boolean | undefined` + +Whether or not to emit the missed block numbers to the callback. + +::: code-group +```ts [index.ts] +import { watchBlockNumber } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlockNumber(config, { + emitMissed: true, // [!code focus] + onBlockNumber(blockNumber) { + console.log('Block number changed!', blockNumber) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + + +### onBlockNumber + +`(blockNumber: bigint, prevBlockNumber: bigint | undefined) => void` + +Callback for when block number changes. + +::: code-group +```ts [index.ts] +import { watchBlockNumber } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlockNumber(config, { + onBlockNumber(blockNumber) { // [!code focus] + console.log('Block number changed!', blockNumber) // [!code focus] + }, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### onError + +`((error: Error) => void) | undefined` + +Error thrown from getting the block number. + +::: code-group +```ts [index.ts] +import { watchBlockNumber } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlockNumber(config, { + onBlockNumber(blockNumber) { + console.log('Block number changed!', blockNumber) + }, + onError(error) { // [!code focus] + console.error('Block number error', error) // [!code focus] + }, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### poll + +`boolean | undefined` + +- Whether or not to use a polling mechanism to check for new blocks instead of a WebSocket subscription. +- Defaults to `false` for WebSocket Clients, and `true` for non-WebSocket Clients. + +::: code-group +```ts [index.ts] +import { watchBlockNumber } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlockNumber(config, { + onBlockNumber(blockNumber) { + console.log('Block number changed!', blockNumber) + }, + poll: true, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/core/api/createConfig#pollinginterval). + +::: code-group +```ts [index.ts] +import { watchBlockNumber } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlockNumber(config, { + onBlockNumber(blockNumber) { + console.log('Block number changed!', blockNumber) + }, + pollingInterval: 1_000, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### syncConnectedChain + +`boolean | undefined` + +- Set up subscriber for connected chain changes. +- Defaults to [`Config['syncConnectedChain']`](/core/api/createConfig#syncconnectedchain). + +::: code-group +```ts [index.ts] +import { watchBlockNumber } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlockNumber(config, { + onBlockNumber(blockNumber) { + console.log('Block number changed!', blockNumber) + }, + syncConnectedChain: false, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WatchBlockNumberReturnType } from '@wagmi/core' +``` + +Function for cleaning up watcher. + +## Viem + +- [`watchBlockNumber`](https://viem.sh/docs/actions/public/watchBlockNumber.html) diff --git a/site/core/api/actions/watchBlocks.md b/site/core/api/actions/watchBlocks.md new file mode 100644 index 0000000000..892ef0005f --- /dev/null +++ b/site/core/api/actions/watchBlocks.md @@ -0,0 +1,249 @@ +# watchBlocks + +Action that watches for block changes. + +## Import + +```ts +import { watchBlocks } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { watchBlocks } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlocks(config, { + onBlock(block) { + console.log('Block changed!', block) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WatchBlocksParameters } from '@wagmi/core' +``` + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized'` + +Watch for new blocks on a given tag. Defaults to `'latest'`. + +::: code-group +```ts [index.ts] +import { watchBlocks } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlocks(config, { + blockTag: 'pending', // [!code focus] + onBlock(block) { + console.log('Block changed!', block) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { watchBlocks } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const unwatch = watchBlocks(config, { + chainId: mainnet.id, // [!code focus] + onBlock(block) { + console.log('Block changed!', block) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### emitMissed + +`boolean` + +Whether or not to emit missed blocks to the callback. Defaults to `false`. + +Missed blocks may occur in instances where internet connection is lost, or the block time is lesser than the polling interval of the client. + +::: code-group +```ts [index.ts] +import { watchBlocks } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlocks(config, { + emitMissed: true, // [!code focus] + onBlock(block) { + console.log('Block changed!', block) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### emitOnBegin + +`boolean` + +Whether or not to emit the block to the callback when the subscription opens. Defaults to `false`. + +::: code-group +```ts [index.ts] +import { watchBlocks } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlocks(config, { + emitOnBegin: true, // [!code focus] + onBlock(block) { + console.log('Block changed!', block) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### onBlock + +`(block: Block, prevblock: Block | undefined) => void` + +Callback for when block changes. + +::: code-group +```ts [index.ts] +import { watchBlocks } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlocks(config, { + onBlock(block) { // [!code focus] + console.log('Block changed!', block) // [!code focus] + }, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### onError + +`((error: Error) => void) | undefined` + +Error thrown from getting the block. + +::: code-group +```ts [index.ts] +import { watchBlocks } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlocks(config, { + onBlock(block) { + console.log('Block changed!', block) + }, + onError(error) { // [!code focus] + console.error('Block error', error) // [!code focus] + }, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### poll + +`boolean | undefined` + +- Whether or not to use a polling mechanism to check for new blocks instead of a WebSocket subscription. +- Defaults to `false` for WebSocket Clients, and `true` for non-WebSocket Clients. + +::: code-group +```ts [index.ts] +import { watchBlocks } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlocks(config, { + poll: true, // [!code focus] + onBlock(block) { + console.log('Block changed!', block) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/core/api/createConfig#pollinginterval). + +::: code-group +```ts [index.ts] +import { watchBlocks } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlocks(config, { + pollingInterval: 1_000, // [!code focus] + onBlock(block) { + console.log('Block changed!', block) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### syncConnectedChain + +`boolean | undefined` + +- Set up subscriber for connected chain changes. +- Defaults to [`Config['syncConnectedChain']`](/core/api/createConfig#syncconnectedchain). + +::: code-group +```ts [index.ts] +import { watchBlocks } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchBlocks(config, { + onBlock(block) { + console.log('Block changed!', block) + }, + syncConnectedChain: false, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WatchBlocksReturnType } from '@wagmi/core' +``` + +Function for cleaning up watcher. + +## Viem + +- [`watchBlocks`](https://viem.sh/docs/actions/public/watchBlocks.html) diff --git a/site/core/api/actions/watchChainId.md b/site/core/api/actions/watchChainId.md new file mode 100644 index 0000000000..a003fd16dc --- /dev/null +++ b/site/core/api/actions/watchChainId.md @@ -0,0 +1,61 @@ +# watchChainId + +Subscribe to chain ID changes. + +## Import + +```ts +import { watchChainId } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { watchChainId } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchChainId(config, { + onChange(chainId) { + console.log('Chain ID changed!', chainId) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WatchChainIdParameters } from '@wagmi/core' +``` + +### onChange + +`onChange(chainId: GetChainIdReturnType, prevChainId: GetChainIdReturnType): void` + +Callback function called when chain ID changes. + +::: code-group +```ts [index.ts] +import { watchChainId } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchChainId(config, { + onChange(chainId) { // [!code focus:3] + console.log('Chain ID changed!', chainId) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WatchChainIdReturnType } from '@wagmi/core' +``` + +Function for cleaning up watcher. \ No newline at end of file diff --git a/site/core/api/actions/watchClient.md b/site/core/api/actions/watchClient.md new file mode 100644 index 0000000000..aa3087c0d0 --- /dev/null +++ b/site/core/api/actions/watchClient.md @@ -0,0 +1,61 @@ +# watchClient + +Subscribe to Client changes. + +## Import + +```ts +import { watchClient } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { watchClient } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchClient(config, { + onChange(client) { + console.log('Client changed!', client) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WatchClientParameters } from '@wagmi/core' +``` + +### onChange + +`onChange(client: GetClientReturnType, prevClient: GetClientReturnType): void` + +Callback function called when Client changes. + +::: code-group +```ts [index.ts] +import { watchClient } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchClient(config, { + onChange(client) { // [!code focus:3] + console.log('Client changed!', client) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WatchClientReturnType } from '@wagmi/core' +``` + +Function for cleaning up watcher. \ No newline at end of file diff --git a/site/core/api/actions/watchConnections.md b/site/core/api/actions/watchConnections.md new file mode 100644 index 0000000000..11cb0a617b --- /dev/null +++ b/site/core/api/actions/watchConnections.md @@ -0,0 +1,61 @@ +# watchConnections + +Subscribe to connections changes. + +## Import + +```ts +import { watchConnections } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { watchConnections } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchConnections(config, { + onChange(data) { + console.log('Connections changed!', data) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WatchConnectionsParameters } from '@wagmi/core' +``` + +### onChange + +`onChange(connections: GetConnectionsReturnType, prevConnections: GetConnectionsReturnType): void` + +Callback function called when connections changes. + +::: code-group +```ts [index.ts] +import { watchConnections } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchConnections(config, { + onChange(data) { // [!code focus:3] + console.log('Connections changed!', data) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WatchConnectionsReturnType } from '@wagmi/core' +``` + +Function for cleaning up watcher. \ No newline at end of file diff --git a/site/core/api/actions/watchConnectors.md b/site/core/api/actions/watchConnectors.md new file mode 100644 index 0000000000..0b951a4584 --- /dev/null +++ b/site/core/api/actions/watchConnectors.md @@ -0,0 +1,61 @@ +# watchConnectors + +Subscribe to connectors changes. + +## Import + +```ts +import { watchConnectors } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { watchConnectors } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchConnectors(config, { + onChange(connectors) { + console.log('Connectors changed!', connectors) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WatchConnectorsParameters } from '@wagmi/core' +``` + +### onChange + +`onChange(connectors: GetConnectorsReturnType, prevConnectors: GetConnectorsReturnType): void` + +Callback function called when connectors changes. + +::: code-group +```ts [index.ts] +import { watchConnectors } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchConnectors(config, { + onChange(connectors) { // [!code focus:3] + console.log('Connectors changed!', connectors) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WatchConnectorsReturnType } from '@wagmi/core' +``` + +Function for cleaning up watcher. \ No newline at end of file diff --git a/site/core/api/actions/watchContractEvent.md b/site/core/api/actions/watchContractEvent.md new file mode 100644 index 0000000000..91498f1784 --- /dev/null +++ b/site/core/api/actions/watchContractEvent.md @@ -0,0 +1,376 @@ + + +# watchContractEvent + +Action that watches and returns emitted contract event logs. + +## Import + +```ts +import { watchContractEvent } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const unwatch = watchContractEvent(config, { + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WatchContractEventParameters } from '@wagmi/core' +``` + +### abi + +`Abi` + +The contract's ABI. Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { abi } from './abi' // [!code focus] +import { config } from './config' + +const unwatch = watchContractEvent(config, { + abi, // [!code focus] + onLogs(logs) { + console.log('Logs changed!', logs) + }, +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### address + +`Address | undefined` + +The contract's address. + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const unwatch = watchContractEvent(config, { + address: '0x6b175474e89094c44da98b954eedeac495271d0f', // [!code focus] + abi, + onLogs(logs) { + console.log('Logs changed!', logs) + }, +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### args + +`object | readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`eventName`](#eventname). + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const unwatch = watchContractEvent(config, { + abi, + args: { // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + }, // [!code focus] + onLogs(logs) { + console.log('Logs changed!', logs) + }, +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### batch + +`boolean | undefined` + +- Whether or not the events should be batched on each invocation. +- Defaults to `true`. + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const unwatch = watchContractEvent(config, { + abi, + batch: false, // [!code focus] + onLogs(logs) { + console.log('Logs changed!', logs) + }, +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { abi } from './abi' +import { config } from './config' + +const unwatch = watchContractEvent(config, { + abi, + chainId: mainnet.id, // [!code focus] + onLogs(logs) { + console.log('Logs changed!', logs) + }, +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### eventName + +`string` + +- Event to listen for the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const unwatch = watchContractEvent(config, { + abi, + eventName: 'Approval', // [!code focus] + onLogs(logs) { + console.log('Logs changed!', logs) + }, +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### onError + +`((error: Error) => void) | undefined` + +Error thrown from getting the block number. + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const unwatch = watchContractEvent(config, { + abi, + onLogs(logs) { + console.log('Logs changed!', logs) + }, + onError(error) { // [!code focus] + console.error('Logs error', error) // [!code focus] + }, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### onLogs + +`(logs: Log[], prevLogs: Log[] | undefined) => void` + +Callback for when logs changes. + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const unwatch = watchContractEvent(config, { + abi, + onLogs(logs) { // [!code focus] + console.log('Logs changed!', logs) // [!code focus] + }, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### poll + +`boolean | undefined` + +- Whether or not to use a polling mechanism to check for new blocks instead of a WebSocket subscription. +- Defaults to `false` for WebSocket Clients, and `true` for non-WebSocket Clients. + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const unwatch = watchContractEvent(config, { + abi, + onLogs(logs) { + console.log('Logs changed!', logs) + }, + poll: true, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/core/api/createConfig#pollinginterval). + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const unwatch = watchContractEvent(config, { + abi, + onLogs(logs) { + console.log('Logs changed!', logs) + }, + pollingInterval: 1_000, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### strict + +`boolean | undefined` + +- Defaults to `false`. + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const unwatch = watchContractEvent(config, { + abi, + onLogs(logs) { + console.log('Logs changed!', logs) + }, + strict: true, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### syncConnectedChain + +`boolean | undefined` + +- Set up subscriber for connected chain changes. +- Defaults to [`Config['syncConnectedChain']`](/core/api/createConfig#syncconnectedchain). + +::: code-group +```ts [index.ts] +import { watchContractEvent } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const unwatch = watchContractEvent(config, { + abi, + onLogs(logs) { + console.log('Logs changed!', logs) + }, + syncConnectedChain: false, // [!code focus] +}) +unwatch() +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WatchContractEventReturnType } from '@wagmi/core' +``` + +Function for cleaning up watcher. + +## Type Inference + +With [`abi`](#abi) setup correctly, TypeScript will infer the correct types for [`eventName`](#eventname), [`args`](#args), and [`onLogs`](#onlogs) parameters. See the Wagmi [TypeScript docs](/core/typescript) for more information. + +## Error + +```ts +import { type WatchContractEventError } from '@wagmi/core' +``` + + + +## Viem + +- [`watchContractEvent`](https://viem.sh/docs/contract/watchContractEvent.html) diff --git a/site/core/api/actions/watchPendingTransactions.md b/site/core/api/actions/watchPendingTransactions.md new file mode 100644 index 0000000000..fe0e5c3885 --- /dev/null +++ b/site/core/api/actions/watchPendingTransactions.md @@ -0,0 +1,207 @@ + + +# watchPendingTransactions + +Action that watches and returns pending transaction hashes. + +## Import + +```ts +import { watchPendingTransactions } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { watchPendingTransactions } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchPendingTransactions(config, { + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WatchPendingTransactionsParameters } from '@wagmi/core' +``` + +### batch + +`boolean | undefined` + +- Whether or not the transactions should be batched on each invocation. +- Defaults to `true`. + +::: code-group +```ts [index.ts] +import { watchPendingTransactions } from '@wagmi/core' + +const unwatch = watchPendingTransactions(config, { + batch: false, // [!code focus] + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```ts [index.ts] +import { watchPendingTransactions } from '@wagmi/core' +import { mainnet } from '@wagmi/core/chains' +import { config } from './config' + +const unwatch = watchPendingTransactions(config, { + chainId: mainnet.id, // [!code focus] + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### onError + +`((error: Error) => void) | undefined` + +Error thrown from watching pending transactions. + +::: code-group +```ts [index.ts] +import { watchPendingTransactions } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchPendingTransactions(config, { + onError(error) { // [!code focus] + console.log('Error', error) // [!code focus] + }, // [!code focus] + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### onTransactions + +`(transactions: Hash[], prevTransactions: Hash[] | undefined) => void` + +Callback when new incoming pending transactions are detected. + +::: code-group +```ts [index.ts] +import { watchPendingTransactions } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchPendingTransactions(config, { + onTransactions(transactions) { // [!code focus] + console.log('New transactions!', transactions) // [!code focus] + }, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### poll + +`boolean | undefined` + +- Whether or not to use a polling mechanism to check for new pending transactions instead of a WebSocket subscription. +- Defaults to `false` for WebSocket Clients, and `true` for non-WebSocket Clients. + +::: code-group +```ts [index.ts] +import { watchPendingTransactions } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchPendingTransactions(config, { + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, + poll: false, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/core/api/createConfig#pollinginterval). + +::: code-group +```ts [index.ts] +import { watchPendingTransactions } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchPendingTransactions(config, { + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, + pollingInterval: 1_000, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### syncConnectedChain + +`boolean | undefined` + +- Set up subscriber for connected chain changes. +- Defaults to [`Config['syncConnectedChain']`](/core/api/createConfig#syncconnectedchain). + +::: code-group +```ts [index.ts] +import { watchPendingTransactions } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchPendingTransactions(config, { + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, + syncConnectedChain: false, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WatchPendingTransactionsReturnType } from '@wagmi/core' +``` + +Function to unsubscribe from pending transaction listener. + +## Error + +```ts +import { type WatchPendingTransactionsError } from '@wagmi/core' +``` + +## Viem + +- [`watchPendingTransactions`](https://viem.sh/docs/actions/public/watchPendingTransactions.html) diff --git a/site/core/api/actions/watchPublicClient.md b/site/core/api/actions/watchPublicClient.md new file mode 100644 index 0000000000..7363fc3deb --- /dev/null +++ b/site/core/api/actions/watchPublicClient.md @@ -0,0 +1,61 @@ +# watchPublicClient + +Subscribe to Public Client changes. + +## Import + +```ts +import { watchPublicClient } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { watchPublicClient } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchPublicClient(config, { + onChange(client) { + console.log('Public Client changed!', client) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WatchPublicClientParameters } from '@wagmi/core' +``` + +### onChange + +`onChange(client: GetPublicClientReturnType, prevClient: GetPublicClientReturnType): void` + +Callback function called when Public Client changes. + +::: code-group +```ts [index.ts] +import { watchPublicClient } from '@wagmi/core' +import { config } from './config' + +const unwatch = watchPublicClient(config, { + onChange(client) { // [!code focus:3] + console.log('Public Client changed!', client) + }, +}) +unwatch() +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WatchPublicClientReturnType } from '@wagmi/core' +``` + +Function for cleaning up watcher. \ No newline at end of file diff --git a/site/core/api/actions/writeContract.md b/site/core/api/actions/writeContract.md new file mode 100644 index 0000000000..34000d9d32 --- /dev/null +++ b/site/core/api/actions/writeContract.md @@ -0,0 +1,560 @@ + + +# writeContract + +Action for executing a write function on a contract. + +A "write" function on a Solidity contract modifies the state of the blockchain. These types of functions require gas to be executed, hence a transaction is broadcasted in order to change the state. + +## Import + +```ts +import { writeContract } from '@wagmi/core' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +::::tip Pairing with `simulateContract` + +Pairing [`simulateContract`](/core/api/actions/simulateContract) with `writeContract` allows you to validate if the transaction will succeed ahead of time. If the simulate succeeds, `writeContract` can execute the transaction. + +::: code-group +```ts [index.ts] +import { simulateContract, writeContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const { request } = await simulateContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], +}) +const hash = await writeContract(config, request) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: +:::: + + +## Parameters + +```ts +import { type WriteContractParameters } from '@wagmi/core' +``` + +### abi + +`Abi` + +The contract's ABI. Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { abi } from './abi' // [!code focus] +import { config } from './config' + +const result = await writeContract(config, { + abi, // [!code focus] + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### accessList + +`AccessList | undefined` + +The access list. + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + accessList: [{ // [!code focus] + address: '0x1', // [!code focus] + storageKeys: ['0x1'], // [!code focus] + }], // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### account + +`Address | Account | undefined` + +Account to use when signing data. Throws if account is not found on [`connector`](#connector). + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### address + +`Address` + +The contract's address. + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', // [!code focus] + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + + +### args + +`readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`functionName`](#functionname). + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ // [!code focus] + '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', // [!code focus] + 123n, // [!code focus] + ] // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +Chain ID to validate against before sending transaction. + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { mainnet } from 'wagmi/chains' // [!code focus] +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + chainId: mainnet.id, // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +[Connector](/core/api/connectors) to sign data with. + +::: code-group +```ts [index.ts] +import { getAccount, writeContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const { connector } = getAccount(config) +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + connector, // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### dataSuffix + +`` `0x${string}` | undefined `` + +Data to append to the end of the calldata. Useful for adding a ["domain" tag](https://opensea.notion.site/opensea/Seaport-Order-Attributions-ec2d69bf455041a5baa490941aad307f). + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + dataSuffix: '0xdeadbeef', // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### functionName + +`string` + +- Function to call on the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'approve', // [!code focus] + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', 123n] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + + +### gas + +`bigint | undefined` + +Gas provided for transaction execution. + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + gas: parseGwei('20'), // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### gasPrice + +`bigint | undefined` + +The price in wei to pay per gas. Only applies to [Legacy Transactions](https://viem.sh/docs/glossary/terms.html#legacy-transaction). + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + gasPrice: parseGwei('20'), // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### maxFeePerGas + +`bigint | undefined` + +Total fee per gas in wei, inclusive of [`maxPriorityFeePerGas`](#maxPriorityFeePerGas). Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + maxFeePerGas: parseGwei('20'), // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### maxPriorityFeePerGas + +`bigint | undefined` + +Max priority fee per gas in wei. Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + maxFeePerGas: parseGwei('20'), + maxPriorityFeePerGas: parseGwei('2'), // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +--- + +### nonce + +`number` + +Unique number identifying this transaction. + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + nonce: 123, // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### type + +`'legacy' | 'eip1559' | 'eip2930' | undefined` + +Optional transaction request type to narrow parameters. + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + type: 'eip1559', // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +### value + +`bigint | undefined` + +Value in wei sent with this transaction. + +::: code-group +```ts [index.ts] +import { writeContract } from '@wagmi/core' +import { parseEther } from 'viem' +import { abi } from './abi' +import { config } from './config' + +const result = await writeContract(config, { + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + value: parseEther('0.01'), // [!code focus] +}) +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WriteContractReturnType } from '@wagmi/core' +``` + +[`Hash`](https://viem.sh/docs/glossary/types.html#hash) + +The transaction hash. + +## Type Inference + +With [`abi`](#abi) setup correctly, TypeScript will infer the correct types for [`functionName`](#functionname), [`args`](#args), and [`value`](#value). See the Wagmi [TypeScript docs](/core/typescript) for more information. + +## Error + +```ts +import { type WriteContractErrorType } from '@wagmi/core' +``` + + + +## Viem + +- [`writeContract`](https://viem.sh/docs/contract/writeContract.html) diff --git a/site/core/api/actions/writeContracts.md b/site/core/api/actions/writeContracts.md new file mode 100644 index 0000000000..a6afe42ff6 --- /dev/null +++ b/site/core/api/actions/writeContracts.md @@ -0,0 +1,317 @@ + + +# writeContracts + +Action that requests for the wallet to sign and broadcast a batch of write contract calls (transactions) to the network. + +[Read more.](https://github.com/ethereum/EIPs/blob/815028dc634463e1716fc5ce44c019a6040f0bef/EIPS/eip-5792.md#wallet_sendcalls) + + + +## Import + +```ts +import { writeContracts } from '@wagmi/core/experimental' +``` + +## Usage + +::: code-group +```ts [index.ts] +import { parseAbi } from 'viem' +import { writeContracts } from '@wagmi/core/experimental' +import { config } from './config' + +const abi = parseAbi([ + 'function approve(address, uint256) returns (bool)', + 'function transferFrom(address, address, uint256) returns (bool)', +]) + +const id = await writeContracts(config, { + contracts: [ + { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'approve', + args: [ + '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + 100n + ], + }, + { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'transferFrom', + args: [ + '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + '0x0000000000000000000000000000000000000000', + 100n + ], + }, + ], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WriteContractsParameters } from '@wagmi/core/experimental' +``` + +### account + +`Account | Address | undefined` + +Account to execute the calls. + +::: code-group +```ts [index.ts] +import { parseAbi } from 'viem' +import { writeContracts } from '@wagmi/core/experimental' +import { config } from './config' + +const abi = parseAbi([ + 'function approve(address, uint256) returns (bool)', + 'function transferFrom(address, address, uint256) returns (bool)', +]) + +const id = await writeContracts(config, { + account: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', // [!code focus] + contracts: [ + { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'approve', + args: [ + '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + 100n + ], + }, + { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'transferFrom', + args: [ + '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + '0x0000000000000000000000000000000000000000', + 100n + ], + }, + ], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### contracts + +`{ to: Hex, data?: Hex, value?: bigint }[]` + +Calls to execute. + +::: code-group +```ts [index.ts] +import { parseAbi } from 'viem' +import { writeContracts } from '@wagmi/core/experimental' +import { config } from './config' + +const abi = parseAbi([ + 'function approve(address, uint256) returns (bool)', + 'function transferFrom(address, address, uint256) returns (bool)', +]) + +const id = await writeContracts(config, { + contracts: [ // [!code focus] + { // [!code focus] + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', // [!code focus] + abi, // [!code focus] + functionName: 'approve', // [!code focus] + args: [ // [!code focus] + '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', // [!code focus] + 100n // [!code focus] + ], // [!code focus] + }, // [!code focus] + { // [!code focus] + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', // [!code focus] + abi, // [!code focus] + functionName: 'transferFrom', // [!code focus] + args: [ // [!code focus] + '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', // [!code focus] + '0x0000000000000000000000000000000000000000', // [!code focus] + 100n // [!code focus] + ], // [!code focus] + }, // [!code focus] + ], // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### capabilities + +`WalletCapabilities | undefined` + +Capability metadata for the calls (e.g. specifying a paymaster). + +::: code-group +```ts [index.ts] +import { parseAbi } from 'viem' +import { writeContracts } from '@wagmi/core/experimental' +import { config } from './config' + +const abi = parseAbi([ + 'function approve(address, uint256) returns (bool)', + 'function transferFrom(address, address, uint256) returns (bool)', +]) + +const id = await writeContracts(config, { + contracts: [ + { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'approve', + args: [ + '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + 100n + ], + }, + { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'transferFrom', + args: [ + '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + '0x0000000000000000000000000000000000000000', + 100n + ], + }, + ], + capabilities: { // [!code focus] + paymasterService: { // [!code focus] + url: 'https://...' // [!code focus] + } // [!code focus] + } // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`number | undefined` + +The target chain ID to broadcast the calls. + +::: code-group +```ts [index.ts] +import { parseAbi } from 'viem' +import { writeContracts } from '@wagmi/core/experimental' +import { config } from './config' + +const abi = parseAbi([ + 'function approve(address, uint256) returns (bool)', + 'function transferFrom(address, address, uint256) returns (bool)', +]) + +const id = await writeContracts(config, { + contracts: [ + { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'approve', + args: [ + '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + 100n + ], + }, + { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'transferFrom', + args: [ + '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + '0x0000000000000000000000000000000000000000', + 100n + ], + }, + ], + chainId: 10, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +Connector to get send the calls with. + +::: code-group +```ts [index.ts] +import { parseAbi } from 'viem' +import { getConnections } from '@wagmi/core' +import { writeContracts } from '@wagmi/core/experimental' +import { config } from './config' + +const abi = parseAbi([ + 'function approve(address, uint256) returns (bool)', + 'function transferFrom(address, address, uint256) returns (bool)', +]) + +const connections = getConnections(config) +const id = await writeContracts(config, { + contracts: [ + { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'approve', + args: [ + '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + 100n + ], + }, + { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'transferFrom', + args: [ + '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + '0x0000000000000000000000000000000000000000', + 100n + ], + }, + ], + connector: connections[0]?.connector, // [!code focus] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type WriteContractsReturnType } from '@wagmi/core/experimental' +``` + +`bigint` + +Most recent block number seen. + +## Error + +```ts +import { type WriteContractsErrorType } from '@wagmi/core/experimental' +``` + + + +## Viem + +- [`writeContracts`](https://viem.sh/experimental/eip5792/writeContracts) diff --git a/site/core/api/chains.md b/site/core/api/chains.md new file mode 100644 index 0000000000..6bdd81de6a --- /dev/null +++ b/site/core/api/chains.md @@ -0,0 +1,24 @@ + + +# Chains + +## Import + +Import via the `'@wagmi/core/chains'` entrypoint (proxies all chains from `'viem/chains'`). + +```ts +import { mainnet } from '@wagmi/core/chains' +``` + +## Available Chains + +Chain definitions as of `viem@{{viemVersion}}`. For `viem@latest`, visit the [Viem repo](https://github.com/wevm/viem/blob/main/src/chains/index.ts). + + + + diff --git a/site/core/api/connectors.md b/site/core/api/connectors.md new file mode 100644 index 0000000000..d68718b25b --- /dev/null +++ b/site/core/api/connectors.md @@ -0,0 +1,28 @@ + + +# Connectors + +Connectors for popular wallet providers and protocols. + +## Import + +```ts +import { injected } from 'wagmi/connectors' +``` + +## Built-In Connectors + +Available via the `'wagmi/connectors'` entrypoint. + + diff --git a/site/core/api/connectors/coinbaseWallet.md b/site/core/api/connectors/coinbaseWallet.md new file mode 100644 index 0000000000..d8968eac7d --- /dev/null +++ b/site/core/api/connectors/coinbaseWallet.md @@ -0,0 +1,6 @@ + + + \ No newline at end of file diff --git a/site/core/api/connectors/injected.md b/site/core/api/connectors/injected.md new file mode 100644 index 0000000000..6e874baef3 --- /dev/null +++ b/site/core/api/connectors/injected.md @@ -0,0 +1,7 @@ + + + diff --git a/site/core/api/connectors/metaMask.md b/site/core/api/connectors/metaMask.md new file mode 100644 index 0000000000..5553c2b34a --- /dev/null +++ b/site/core/api/connectors/metaMask.md @@ -0,0 +1,7 @@ + + + diff --git a/site/core/api/connectors/mock.md b/site/core/api/connectors/mock.md new file mode 100644 index 0000000000..d085d93cb4 --- /dev/null +++ b/site/core/api/connectors/mock.md @@ -0,0 +1,6 @@ + + + diff --git a/site/core/api/connectors/safe.md b/site/core/api/connectors/safe.md new file mode 100644 index 0000000000..cc800dcc90 --- /dev/null +++ b/site/core/api/connectors/safe.md @@ -0,0 +1,6 @@ + + + diff --git a/site/core/api/connectors/walletConnect.md b/site/core/api/connectors/walletConnect.md new file mode 100644 index 0000000000..ba65cbda96 --- /dev/null +++ b/site/core/api/connectors/walletConnect.md @@ -0,0 +1,6 @@ + + + diff --git a/site/core/api/createConfig.md b/site/core/api/createConfig.md new file mode 100644 index 0000000000..26df850162 --- /dev/null +++ b/site/core/api/createConfig.md @@ -0,0 +1,7 @@ + + + diff --git a/site/core/api/createConnector.md b/site/core/api/createConnector.md new file mode 100644 index 0000000000..7cdbd00bdd --- /dev/null +++ b/site/core/api/createConnector.md @@ -0,0 +1,31 @@ +# createConnector + +Creates new [`CreateConnectorFn`](#parameters). + +## Import + +```ts +import { createConnector } from '@wagmi/core' +``` + +## Usage + +```ts +import { createConnector } from '@wagmi/core' + +export type InjectedParameters = {} + +export function injected(parameters: InjectedParameters = {}) { + return createConnector((config) => ({ + // ... + })) +} +``` + +## Parameters + +```ts +import { type CreateConnectorFn } from '@wagmi/core' +``` + +Read [Creating Connectors](/dev/creating-connectors) for more info on the `CreateConnectorFn` type. \ No newline at end of file diff --git a/site/core/api/createStorage.md b/site/core/api/createStorage.md new file mode 100644 index 0000000000..f547a9a609 --- /dev/null +++ b/site/core/api/createStorage.md @@ -0,0 +1,6 @@ + + + diff --git a/site/core/api/errors.md b/site/core/api/errors.md new file mode 100644 index 0000000000..4a29a1c30f --- /dev/null +++ b/site/core/api/errors.md @@ -0,0 +1,11 @@ + + +# Errors + +Error classes used by Wagmi. + + + diff --git a/site/core/api/transports.md b/site/core/api/transports.md new file mode 100644 index 0000000000..cfaa9a6021 --- /dev/null +++ b/site/core/api/transports.md @@ -0,0 +1,28 @@ + + +# Transports + +[`createConfig`](/core/api/createConfig) can be instantiated with a set of Transports for each chain. A Transport is the intermediary layer that is responsible for executing outgoing JSON-RPC requests to the RPC Provider (e.g. Alchemy, Infura, etc). + +## Import + +```ts +import { http } from '@wagmi/core' +``` + +## Built-In Transports + +Available via the `'@wagmi/core'` entrypoint. + + diff --git a/site/core/api/transports/custom.md b/site/core/api/transports/custom.md new file mode 100644 index 0000000000..487c3ae930 --- /dev/null +++ b/site/core/api/transports/custom.md @@ -0,0 +1,5 @@ + + + diff --git a/site/core/api/transports/fallback.md b/site/core/api/transports/fallback.md new file mode 100644 index 0000000000..cefffa734e --- /dev/null +++ b/site/core/api/transports/fallback.md @@ -0,0 +1,5 @@ + + + diff --git a/site/core/api/transports/http.md b/site/core/api/transports/http.md new file mode 100644 index 0000000000..7fed8c6d72 --- /dev/null +++ b/site/core/api/transports/http.md @@ -0,0 +1,5 @@ + + + diff --git a/site/core/api/transports/unstable_connector.md b/site/core/api/transports/unstable_connector.md new file mode 100644 index 0000000000..19a9b43575 --- /dev/null +++ b/site/core/api/transports/unstable_connector.md @@ -0,0 +1,6 @@ + + + diff --git a/site/core/api/transports/webSocket.md b/site/core/api/transports/webSocket.md new file mode 100644 index 0000000000..4ed1ae3273 --- /dev/null +++ b/site/core/api/transports/webSocket.md @@ -0,0 +1,5 @@ + + + diff --git a/site/core/api/utilities/cookieToInitialState.md b/site/core/api/utilities/cookieToInitialState.md new file mode 100644 index 0000000000..c0470295c9 --- /dev/null +++ b/site/core/api/utilities/cookieToInitialState.md @@ -0,0 +1,5 @@ + + + diff --git a/site/core/api/utilities/deserialize.md b/site/core/api/utilities/deserialize.md new file mode 100644 index 0000000000..4f051cdc53 --- /dev/null +++ b/site/core/api/utilities/deserialize.md @@ -0,0 +1,5 @@ + + + diff --git a/site/core/api/utilities/normalizeChainId.md b/site/core/api/utilities/normalizeChainId.md new file mode 100644 index 0000000000..9dd43935bb --- /dev/null +++ b/site/core/api/utilities/normalizeChainId.md @@ -0,0 +1,5 @@ + + + diff --git a/site/core/api/utilities/serialize.md b/site/core/api/utilities/serialize.md new file mode 100644 index 0000000000..3672a67c17 --- /dev/null +++ b/site/core/api/utilities/serialize.md @@ -0,0 +1,5 @@ + + + diff --git a/site/core/getting-started.md b/site/core/getting-started.md new file mode 100644 index 0000000000..f5759957a5 --- /dev/null +++ b/site/core/getting-started.md @@ -0,0 +1,71 @@ + + +# Getting Started + +## Overview + +Wagmi Core is a VanillaJS library for Ethereum. You can learn more about the rationale behind the project in the [Why Wagmi](/core/why) section. + +## Manual Installation + +To manually add Wagmi to your project, install the required packages. + +::: code-group +```bash-vue [pnpm] +pnpm add @wagmi/core @wagmi/connectors viem@{{viemVersion}} +``` + +```bash-vue [npm] +npm install @wagmi/core @wagmi/connectors viem@{{viemVersion}} +``` + +```bash-vue [yarn] +yarn add @wagmi/core @wagmi/connectors viem@{{viemVersion}} +``` + +```bash-vue [bun] +bun add @wagmi/core @wagmi/connectors viem@{{viemVersion}} +``` +::: + +- [Wagmi Connectors](/core/api/connectors) is a collection of interfaces for linking accounts/wallets to Wagmi. +- [Viem](https://viem.sh) is a TypeScript interface for Ethereum that performs blockchain operations. +- [TypeScript](/react/typescript) is optional, but highly recommended. Learn more about [TypeScript support](/core/typescript). + +### Create Config + +Create and export a new Wagmi config using `createConfig`. + +::: code-group +<<< @/snippets/core/config.ts[config.ts] +::: + +In this example, Wagmi is configured to use the Mainnet and Sepolia chains. Check out the [`createConfig` docs](/core/api/createConfig) for more configuration options. + +### Use Wagmi + +Now that everything is set up, you can pass the `config` to use actions. + +::: code-group +```tsx [index.ts] +import { getAccount, getEnsName } from '@wagmi/core' +import { config } from './config' + +const { address } = getAccount(config) +const ensName = await getEnsName(config, { address }) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Next Steps + +For more information on what to do next, check out the following topics. + +- [**TypeScript**](/core/typescript) Learn how to get the most out of Wagmi's type-safety and inference for an enlightened developer experience. +- [**Actions**](/core/api/actions) Browse the collection of actions and learn how to use them. +- [**Framework Adapters**](/core/guides/framework-adapters) Learn how to create a Wagmi-like adapter for your favorite framework. +- [**Viem docs**](https://viem.sh) Wagmi Core is a wrapper around Viem that manages account and client reactivity. Learn more about Viem and how to use it. diff --git a/site/core/guides/chain-properties.md b/site/core/guides/chain-properties.md new file mode 100644 index 0000000000..4f0b480fe0 --- /dev/null +++ b/site/core/guides/chain-properties.md @@ -0,0 +1,91 @@ +# Chain Properties + +Some chains support additional properties related to blocks and transactions. This is powered by Viem's [formatters](https://viem.sh/docs/chains/formatters) and [serializers](https://viem.sh/docs/chains/serializers). For example, Celo, ZkSync, OP Stack chains support all additional properties. In order to use these properties in a type-safe way, there are a few things you should be aware of. + +## Narrowing Parameters + +When you pass your `config` to an action, you are ready to access chain-specific properties! For example, Celo's `feeCurrency` is available. + +::: code-group +```ts [index.ts] +import { parseEther } from 'viem' +import { simulateContract } from '@wagmi/core' +import { config } from './config' + +const result = await simulateContract(config, { + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + feeCurrency: '0x…', // [!code focus] +}) +``` +<<< @/snippets/core/config-chain-properties.ts[config.ts] +::: + +This is great, but if you have multiple chains that support additional properties, your autocomplete could be overwhelmed with all of them. By setting the `chainId` property to a specific value (e.g. `celo.id`), you can narrow parameters to a single chain. + +::: code-group +```ts [index.ts] +import { parseEther } from 'viem' +import { simulateContract } from '@wagmi/core' +import { celo } from 'wagmi/chains' + +const result = await simulateContract({ + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + chainId: celo.id, // [!code focus] + feeCurrency: '0x…', // [!code focus] + // ^? (property) feeCurrency?: `0x${string}` | undefined // [!code focus] +}) +``` +<<< @/snippets/core/config-chain-properties.ts[config.ts] +::: + +## Narrowing Return Types + +Return types can also have chain-specific properties attached to them. There are a couple approaches for extracting these properties. + +### `chainId` Parameter + +Not only can you use the `chainId` parameter to [narrow parameters](#narrowing-parameters), you can also use it to narrow the return type. + +::: code-group +```ts [index.tsx] +import { waitForTransactionReceipt } from '@wagmi/core' +import { zkSync } from '@wagmi/core/chains' + +const result = await waitForTransactionReceipt({ + chainId: zkSync.id, + hash: '0x16854fcdd0219cacf5aec5e4eb2154dac9e406578a1510a6fc48bd0b67e69ea9', +}) + +result.logs +// ^? (property) logs: ZkSyncLog[] | undefined +``` +<<< @/snippets/core/config-chain-properties.ts[config.ts] +::: + +### `chainId` Data Property + +Wagmi internally will set a `chainId` property on return types that you can use to narrow results. The `chainId` is determined from the `chainId` parameter or global state (e.g. connector). You can use this property to help TypeScript narrow the type. + +::: code-group +```ts [index.tsx] +import { waitForTransactionReceipt } from '@wagmi/core' +import { zkSync } from '@wagmi/core/chains' + +const result = await waitForTransactionReceipt({ + hash: '0x16854fcdd0219cacf5aec5e4eb2154dac9e406578a1510a6fc48bd0b67e69ea9', +}) + +if (result.chainId === zkSync.id) { + result.logs + // ^? (property) logs: ZkSyncLog[] | undefined +} +``` +<<< @/snippets/core/config-chain-properties.ts[config.ts] +::: + +## Troubleshooting + +If chain properties aren't working, make sure [TypeScript](/core/guides/faq#type-inference-doesn-t-work) is configured correctly. Not all chains have additional properties, to check which ones do, see the [Viem repo](https://github.com/wevm/viem/tree/main/src/chains) (chains that have a top-level directory under [`src/chains`](https://github.com/wevm/viem/tree/main/src/chains) support additional properties). + diff --git a/site/core/guides/error-handling.md b/site/core/guides/error-handling.md new file mode 100644 index 0000000000..bac34a1d2c --- /dev/null +++ b/site/core/guides/error-handling.md @@ -0,0 +1,37 @@ +# Error Handling + +Every module in Wagmi Core exports an accompanying error type which you can use to strongly type your `catch` statements. + +These types come in the form of `ErrorType`. For example, the `getBlockNumber` action exports a `GetBlockNumberErrorType` type. + +Unfortunately, [TypeScript doesn't have an abstraction for typed exceptions](https://github.com/microsoft/TypeScript/issues/13219), so the most pragmatic & vanilla approach would be to explicitly cast error types in the `catch` statement. + +::: code-group +```tsx [index.tsx] +import { type GetBlockNumberErrorType, getBlockNumber } from '@wagmi/core' +import { config } from './config' + +try { + const blockNumber = await getBlockNumber(config) +} catch (e) { + const error = e as GetBlockNumberErrorType + error.name + // ^? (property) name: "Error" | "ChainDisconnectedError" | "HttpRequestError" | "InternalRpcError" | "InvalidInputRpcError" | "InvalidParamsRpcError" | "InvalidRequestRpcError" | "JsonRpcVersionUnsupportedError" | ... 16 more ... | "WebSocketRequestError" + + if (error.name === 'InternalRpcError') + error.code + // ^? (property) code: -32603 + + if (error.name === 'HttpRequestError') + error.headers + // ^? (property) headers: Headers + error.status + // ^? (property) status: number +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +::: tip +If you are using [Wagmi Hooks](/react/api/hooks), errors are [already strongly typed](/react/guides/error-handling) via the `error` property. +::: \ No newline at end of file diff --git a/site/core/guides/ethers.md b/site/core/guides/ethers.md new file mode 100644 index 0000000000..c99598a362 --- /dev/null +++ b/site/core/guides/ethers.md @@ -0,0 +1,306 @@ +# Ethers.js Adapters + +It is recommended for projects to migrate to [Viem](https://viem.sh) when using Wagmi, but there are some cases where you might still need to use [Ethers.js](https://ethers.org) in your project: + +- You may want to **incrementally migrate** Ethers.js usage to Viem +- Some **third-party libraries & SDKs** may only support Ethers.js +- Personal preference + +We have provided reference implementations for Viem → Ethers.js adapters that you can copy + paste in your project. + +## Client → Provider + +### Reference Implementation + +Copy the following reference implementation into a file of your choice: + +::: code-group + +```ts [Ethers v5] +import { type Config, getClient } from '@wagmi/core' +import { providers } from 'ethers' +import type { Client, Chain, Transport } from 'viem' + +export function clientToProvider(client: Client) { + const { chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + if (transport.type === 'fallback') + return new providers.FallbackProvider( + (transport.transports as ReturnType[]).map( + ({ value }) => new providers.JsonRpcProvider(value?.url, network), + ), + ) + return new providers.JsonRpcProvider(transport.url, network) +} + +/** Action to convert a viem Public Client to an ethers.js Provider. */ +export function getEthersProvider( + config: Config, + { chainId }: { chainId?: number } = {}, +) { + const client = getClient(config, { chainId }) + if (!client) return + return clientToProvider(client) +} +``` + +```ts [Ethers v6] +import { type Config, getClient } from '@wagmi/core' +import { FallbackProvider, JsonRpcProvider } from 'ethers' +import type { Client, Chain, Transport } from 'viem' + +export function clientToProvider(client: Client) { + const { chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + if (transport.type === 'fallback') { + const providers = (transport.transports as ReturnType[]).map( + ({ value }) => new JsonRpcProvider(value?.url, network), + ) + if (providers.length === 1) return providers[0] + return new FallbackProvider(providers) + } + return new JsonRpcProvider(transport.url, network) +} + +/** Action to convert a viem Client to an ethers.js Provider. */ +export function getEthersProvider( + config: Config, + { chainId }: { chainId?: number } = {}, +) { + const client = getClient(config, { chainId }) + if (!client) return + return clientToProvider(client) +} +``` + +::: + +### Usage + +Now you can use the `getEthersProvider` function in your components: + +::: code-group + +```ts [example.ts] +import { getEthersProvider } from './ethers' +import { config } from './config' + +function example() { + const provider = getEthersProvider(config) + ... +} +``` + +```ts [ethers.ts (Ethers v5)] +import { type Config, getClient } from '@wagmi/core' +import { providers } from 'ethers' +import type { Client, Chain, Transport } from 'viem' + +export function clientToProvider(client: Client) { + const { chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + if (transport.type === 'fallback') + return new providers.FallbackProvider( + (transport.transports as ReturnType[]).map( + ({ value }) => new providers.JsonRpcProvider(value?.url, network), + ), + ) + return new providers.JsonRpcProvider(transport.url, network) +} + +/** Action to convert a viem Public Client to an ethers.js Provider. */ +export function getEthersProvider( + config: Config, + { chainId }: { chainId?: number } = {}, +) { + const client = getClient(config, { chainId }) + if (!client) return + return clientToProvider(client) +} + +``` + +```ts [ethers.ts (Ethers v6)] +import { type Config, getClient } from '@wagmi/core' +import { FallbackProvider, JsonRpcProvider } from 'ethers' +import type { Client, Chain, Transport } from 'viem' + +export function clientToProvider(client: Client) { + const { chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + if (transport.type === 'fallback') { + const providers = (transport.transports as ReturnType[]).map( + ({ value }) => new JsonRpcProvider(value?.url, network), + ) + if (providers.length === 1) return providers[0] + return new FallbackProvider(providers) + } + return new JsonRpcProvider(transport.url, network) +} + +/** Action to convert a viem Client to an ethers.js Provider. */ +export function getEthersProvider( + config: Config, + { chainId }: { chainId?: number } = {}, +) { + const client = getClient(config, { chainId }) + if (!client) return + return clientToProvider(client) +} +``` + +::: + +## Connector Client → Signer + +### Reference Implementation + +Copy the following reference implementation into a file of your choice: + +::: code-group + +```ts [Ethers v5] +import { Config, getConnectorClient } from '@wagmi/core' +import { providers } from 'ethers' +import type { Account, Chain, Client, Transport } from 'viem' + +export function clientToSigner(client: Client) { + const { account, chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + const provider = new providers.Web3Provider(transport, network) + const signer = provider.getSigner(account.address) + return signer +} + +/** Action to convert a Viem Client to an ethers.js Signer. */ +export async function getEthersSigner( + config: Config, + { chainId }: { chainId?: number } = {}, +) { + const client = await getConnectorClient(config, { chainId }) + return clientToSigner(client) +} +``` + +```ts [Ethers v6] +import { Config, getConnectorClient } from '@wagmi/core' +import { BrowserProvider, JsonRpcSigner } from 'ethers' +import type { Account, Chain, Client, Transport } from 'viem' + +export function clientToSigner(client: Client) { + const { account, chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + const provider = new BrowserProvider(transport, network) + const signer = new JsonRpcSigner(provider, account.address) + return signer +} + +/** Action to convert a viem Wallet Client to an ethers.js Signer. */ +export async function getEthersSigner( + config: Config, + { chainId }: { chainId?: number } = {}, +) { + const client = await getConnectorClient(config, { chainId }) + return clientToSigner(client) +} + +``` + +::: + +### Usage + +Now you can use the `getEthersSigner` function in your components: + +::: code-group + +```ts [example.ts] +import { getEthersSigner } from './ethers' +import { config } from './config' + +function example() { + const provider = getEthersSigner(config) + ... +} +``` + +```ts [ethers.ts (Ethers v5)] +import { Config, getConnectorClient } from '@wagmi/core' +import { providers } from 'ethers' +import type { Account, Chain, Client, Transport } from 'viem' + +export function clientToSigner(client: Client) { + const { account, chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + const provider = new providers.Web3Provider(transport, network) + const signer = provider.getSigner(account.address) + return signer +} + +/** Action to convert a Viem Client to an ethers.js Signer. */ +export async function getEthersSigner( + config: Config, + { chainId }: { chainId?: number } = {}, +) { + const client = await getConnectorClient(config, { chainId }) + return clientToSigner(client) +} +``` + +```ts [ethers.ts (Ethers v6)] +import { Config, getConnectorClient } from '@wagmi/core' +import { BrowserProvider, JsonRpcSigner } from 'ethers' +import type { Account, Chain, Client, Transport } from 'viem' + +export function clientToSigner(client: Client) { + const { account, chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + const provider = new BrowserProvider(transport, network) + const signer = new JsonRpcSigner(provider, account.address) + return signer +} + +/** Action to convert a viem Wallet Client to an ethers.js Signer. */ +export async function getEthersSigner( + config: Config, + { chainId }: { chainId?: number } = {}, +) { + const client = await getConnectorClient(config, { chainId }) + return clientToSigner(client) +} + +``` + +::: diff --git a/site/core/guides/faq.md b/site/core/guides/faq.md new file mode 100644 index 0000000000..7e3ca47e10 --- /dev/null +++ b/site/core/guides/faq.md @@ -0,0 +1,9 @@ + + +# FAQ / Troubleshooting + +Collection of frequently asked questions with ideas on how to troubleshoot and resolve them. + + diff --git a/site/core/guides/framework-adapters.md b/site/core/guides/framework-adapters.md new file mode 100644 index 0000000000..1e45ba63ec --- /dev/null +++ b/site/core/guides/framework-adapters.md @@ -0,0 +1,35 @@ +# Framework Adapters + +Folks often ask if they can use Wagmi with other frameworks, like Svelte, Solid.js, and more. + +The short answer is — you already can! Wagmi Core is pure VanillaJS that you can use with any framework. For some, this answer is (understandably) unsatisfying as they want a tight integration between Wagmi Core and their favorite framework's reactivity system, e.g. what Wagmi is for React and Vue. + +Someday, we would love to support additional frameworks, but unfortunately the core team doesn't have time to build and support them in a high-quality way at the moment. This could change in the future with additional [sponsors](https://github.com/sponsors/wevm), reshuffling of the roadmap, or if someone from the community wants to lead the effort. + +In the meantime, here are some tips on how to create tighter bonds between Wagmi Core and other frameworks. + +## Dependency Injection + +Once you create a Wagmi Config, you'll need to make sure your framework has access to it inside your higher-level functions (e.g. hooks for React, composables for Vue). For example, Wagmi uses [React Context](https://react.dev/learn/passing-data-deeply-with-context) to inject the Config into React Hooks and update it if it changes. This makes it so your users don't need to pass a Config object every time they use a hook. + +## Reactivity Layer + +All frameworks approach reactivity in a different way. To hook into your favorite frameworks, reactivity system, it's often helpful to see what other popular libraries for your framework are doing. + +The most important thing to hook up Wagmi Core with your framework is to make sure changes to the Wagmi Config are tracked. This enables behavior, like switching chains or connecting accounts, to propagate throughout your app and update state. Check out [`useAccount`](https://github.com/wevm/wagmi/blob/main/packages/react/src/hooks/useAccount.ts), [`useChainId`](https://github.com/wevm/wagmi/blob/main/packages/react/src/hooks/useChainId.ts), [`useClient`](https://github.com/wevm/wagmi/blob/main/packages/react/src/hooks/useClient.ts), and [`useConnectorClient`](https://github.com/wevm/wagmi/blob/main/packages/react/src/hooks/useConnectorClient.ts) — versions of these for your framework are important to get right as they power a lot of internals. + +## TanStack Query + +Wagmi uses [TanStack Query](https://tanstack.com/query) to enable caching, deduplication, persistence, and more in React and Vue applications. Normally, you would need to find a similar library for your framework, but the good news is TanStack Query supports other frameworks! (Svelte, Solid, and Angular at the time of writing.) + +To get started with your framework, install and set up the related TanStack Query adapter. Next, import query keys/functions and mutation functions from the `'@wagmi/core/query'` entrypoint. You can plug these directly into your framework's TanStack Query adapter functions. + +If you are building a library, you'll also want to make sure that you wire up generics correctly so type-inference and safety work correctly. The best way to make sure you are doing this correctly, is to see how we do this for React with Wagmi by checking out the [source code](https://github.com/wevm/wagmi/tree/main/packages/react/src/hooks). + +## Testing + +If you are building a library, you'll want to write tests. Wagmi uses [React Testing Library](https://testing-library.com/docs/react-testing-library/intro) to test hooks. [Testing Library](https://testing-library.com) also supports other frameworks, like Svelte, Solid, and more. You can take a look at how the React tests work and do something similar for your code. + +## Proxy Exports + +Wagmi proxies exports directly from Wagmi Core and [Viem](https://viem.sh) to make importing easier. You'll likely want to imitate this behavior for your framework. diff --git a/site/core/guides/migrate-from-v1-to-v2.md b/site/core/guides/migrate-from-v1-to-v2.md new file mode 100644 index 0000000000..6807ebafcd --- /dev/null +++ b/site/core/guides/migrate-from-v1-to-v2.md @@ -0,0 +1,585 @@ +--- +title: Migrate from v1 to v2 +titleTemplate: Wagmi Core +description: Guide for migrating from Wagmi Core v1 to v2. +--- + + + +# Migrate from v1 to v2 + +Wagmi Core v2 redesigns the core APIs to mesh better with [Viem](https://viem.sh). This major version transforms Wagmi into a light wrapper around Viem, sprinkling in multichain support and account management. As such, there are some breaking changes and deprecations to be aware of outlined in this guide. + +To get started, install the latest version of Wagmi and it's required peer dependencies. + +::: code-group +```bash-vue [pnpm] +pnpm add @wagmi/core viem@{{viemVersion}} @wagmi/connectors +``` + +```bash-vue [npm] +npm install @wagmi/core viem@{{viemVersion}} @wagmi/connectors +``` + +```bash-vue [yarn] +yarn add @wagmi/core viem@{{viemVersion}} @wagmi/connectors +``` + +```bash-vue [bun] +bun add @wagmi/core viem@{{viemVersion}} @wagmi/connectors +``` +::: + +::: info Wagmi Core v2 should be the last major version that will have this many actionable breaking changes. +Moving forward, new functionality will be opt-in with old functionality being deprecated alongside the new features. This means upgrading to the latest major versions will not require immediate changes. +::: + +::: info Not ready to migrate yet? +The Wagmi Core v1 docs are still available at [1.x.wagmi.sh/core](https://1.x.wagmi.sh/core). +::: + +## Dependencies + +### Dropped CommonJS support + +Wagmi v2 no longer publishes a separate `cjs` tag since very few people use this tag and ESM is the future. See [Sindre Sorhus' guide](https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c) for more info about switching to ESM. + +## Actions + +### Removed `config` singleton + +Before v2, when you called [`createConfig`](/core/api/createConfig), it set a global `config` singleton that was used internally by actions. For v2, `config` is now a required first parameter for actions. + +::: code-group +```ts [index.ts] +import { getAccount, readContract } from '@wagmi/core' +import { parseAbi } from 'viem' +import { config } from './config' // [!code ++] + +const account = getAccount() // [!code --] +const account = getAccount(config) // [!code ++] + +const balanceOf = readContract({ // [!code --] +const balanceOf = readContract(config, { // [!code ++] + address: '0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48', + abi: parseAbi(['function balanceOf(address) view returns (uint256)']), + functionName: 'balanceOf', + args: ['0xd2135CfB216b74109775236E36d4b433F1DF507B'], +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +The previous global `config` singleton made it so you couldn't use multiple `Config` objects in the same project. In addition, we think passing `config` is more explicit and makes it easier to understand what's going on. Finally, types can be inferred directly from the `config`, like [chain properties](/core/guides/chain-properties) and more. + +### Removed `getContract` + +Removed `getContract` export. Use Viem's [`getContract`](https://viem.sh/docs/contract/getContract.html) instead. + +```ts +import { getContract } from '@wagmi/core' // [!code --] +import { getContract } from 'viem' // [!code ++] + +const contract = getContract() // [!code --] +const contract = getContract() // [!code ++] +``` + +### Removed `getNetwork` and `watchNetwork` + +The `getNetwork` and `watchNetwork` actions were removed since the connected chain is typically based on the connected account. + +- Use [`config.chains`](/core/api/createConfig#chains-1) instead to get `chains`. + + ::: code-group + ```ts [index.ts] + import { getNetwork } from '@wagmi/core' // [!code --] + + const { chains } = getNetwork() // [!code --] + const chains = config.chains // [!code ++] + ``` + <<< @/snippets/core/config.ts[config.ts] + ::: + +- Use [`getAccount`](/core/api/actions/getAccount) and `config.chains` instead to get `chain`. + + ::: code-group + ```ts [index.ts] + import { getNetwork } from '@wagmi/core' // [!code --] + import { getAccount } from '@wagmi/core' // [!code ++] + import { config } from './config' // [!code ++] + + const { chain } = getNetwork() // [!code --] + const { chainId } = getAccount(config) // [!code ++] + const chain = chains.find(chain => chain.id === chainId) // [!code ++] + ``` + <<< @/snippets/core/config.ts[config.ts] + ::: + + Before v2, `getNetwork().chain` could result in an invalid chain if the active connector's `chainId` was not configured in the list of `config.chains`. Using `getAccount` and `config.chains` is more work, but ensures that chain is either valid or not defined. You can also use `getAccount(config).chain` if you don't care about the chain being `undefined` when not configured. + +- Use `watchAccount` instead of `watchNetwork`. + + ::: code-group + ```ts [index.ts] + import { watchNetwork } from '@wagmi/core' // [!code --] + import { watchAccount } from '@wagmi/core' // [!code ++] + import { config } from './config' // [!code ++] + + const unwatch = watchNetwork((data) => console.log('Changed!', data)) // [!code --] + const unwatch = watchAccount(config, { // [!code ++] + onChange(data) { // [!code ++] + const chains = config.chains // [!code ++] + const chain = chains.find(chain => chain.id === data.chainId) // [!code ++] + }, // [!code ++] + }) // [!code ++] + ``` + <<< @/snippets/core/config.ts[config.ts] + ::: + +### Removed `getWebSocketPublicClient` and `watchWebSocketPublicClient` + +Viem [Transports](https://viem.sh/docs/clients/intro.html#transports) now determine the type of client that is returned. You can use [`getPublicClient`](/core/api/actions/getPublicClient) and [`watchPublicClient`](/core/api/actions/watchPublicClient) to retrieve Viem [`PublicClient`](https://viem.sh/docs/clients/public.html) instances. + +Alternatively, you can use [`getClient`](/core/api/actions/getClient) and [`watchClient`](/core/api/actions/watchClient) to retrieve plain Viem [`Client`](https://viem.sh/docs/clients/custom.html) instances. This is a better option for users that care about optimizing bundle size to be as small as possible. + +### Removed `watchReadContract`, `watchReadContracts`, and `watchReadMulticall` + +Use [`watchBlockNumber`](/core/api/actions/watchBlockNumber) along with [`readContract`](/core/api/actions/readContract), [`readContracts`](/core/api/actions/readContracts), and [`multicall`](/core/api/actions/multicall) actions instead. Before v2, `watchReadContract`, `watchReadContracts`, and `watchReadMulticall` were all wrappers around `watchBlockNumber` and this simplifies the API. + +::: code-group +```ts [index.ts] +import { watchReadContract } from '@wagmi/core' // [!code --] +import { watchBlockNumber, readContract } from '@wagmi/core' // [!code ++] +import { config } from './config' // [!code ++] + +const unwatch = watchReadContract( // [!code --] + { // [!code --] + address: '0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48', // [!code --] + abi: parseAbi(['function balanceOf(address) view returns (uint256)']), // [!code --] + functionName: 'balanceOf', // [!code --] + args: ['0xd2135CfB216b74109775236E36d4b433F1DF507B'], // [!code --] + }, // [!code --] + (result) => console.log('Changed!', result), // [!code --] +) // [!code --] +const unwatch = watchBlockNumber(config, { // [!code ++] + onBlockNumber() { // [!code ++] + const balanceOf = readContract(config, { // [!code ++] + address: '0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48', // [!code ++] + abi: parseAbi(['function balanceOf(address) view returns (uint256)']), // [!code ++] + functionName: 'balanceOf', // [!code ++] + args: ['0xd2135CfB216b74109775236E36d4b433F1DF507B'], // [!code ++] + }) // [!code ++] + console.log('Changed!', balanceOf)// [!code ++] + }, // [!code ++] +}) // [!code ++] +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### Removed `fetchFeeData` + +Removed `fetchFeeData`. Use [`estimateFeesPerGas`](/core/api/actions/estimateFeesPerGas) instead. + +::: code-group +```ts [index.ts] +import { fetchFeeData } from '@wagmi/core' // [!code --] +import { estimateFeesPerGas } from '@wagmi/core' // [!code ++] +import { config } from './config' // [!code ++] + +const result = await fetchFeeData() // [!code --] +const result = await estimateFeesPerGas(config) // [!code ++] +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### Removed `prepareWriteContract` + +Removed `prepareWriteContract`. Use [`simulateContract`](/core/api/actions/simulateContract) instead. + +::: code-group +```ts [index.ts] +import { prepareWriteContract } from '@wagmi/core' // [!code --] +import { simulateContract } from '@wagmi/core' // [!code ++] +import { config } from './config' // [!code ++] + +const result = await prepareWriteContract({ ... }) // [!code --] +const result = await simulateContract(config, { ... }) // [!code ++] +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### Removed `prepareSendTransaction` + +Removed `prepareSendTransaction`. Use [`estimateGas`](/core/api/actions/estimateGas) instead. + +::: code-group +```ts [index.ts] +import { prepareSendTransaction } from '@wagmi/core' // [!code --] +import { estimateGas } from '@wagmi/core' // [!code ++] +import { config } from './config' // [!code ++] + +const result = await prepareSendTransaction({ ... }) // [!code --] +const result = await estimateGas(config, { ... }) // [!code ++] +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### Updated `sendTransaction` and `writeContract` return type + +Updated [`sendTransaction`](/core/api/actions/sendTransaction) and [`writeContract`](/core/api/actions/writeContract) return type from `` { hash: `0x${string}` } `` to `` `0x${string}` ``. + +```ts +const result = await sendTransaction({ hash: '0x...' }) +result.hash // [!code --] +result // [!code ++] +``` + +### Updated `connect` return type + +Updated [`connect`](/core/api/actions/connect) return type from `` { account: Address; chain: { id: number; unsupported?: boolean }; connector: Connector } `` to `` { accounts: readonly Address[]; chainId: number } ``. This better reflects the ability to have multiple accounts per connector. + +### Renamed parameters and return types + +All hook parameters and return types follow the naming pattern of `[PascalCaseActionName]Parameters` and `[PascalCaseActionName]ReturnType`. For example, `GetAccountParameters` and `GetAccountReturnType`. + +```ts +import { GetAccountConfig, GetAccountResult } from '@wagmi/core' // [!code --] +import { GetAccountParameters, GetAccountReturnType } from '@wagmi/core' // [!code ++] +``` + +## Connectors + +### Moved Wagmi Connectors to peer dependencies + +Wagmi Core v2 no longer exports connectors via the `'@wagmi/core/connectors/*'` entrypoints. Instead, you should install the `@wagmi/connectors` package. + +::: code-group +```bash-vue [pnpm] +pnpm add @wagmi/connectors +``` + +```bash-vue [npm] +npm install @wagmi/connectors +``` + +```bash-vue [yarn] +yarn add @wagmi/connectors +``` + +```bash-vue [bun] +bun add @wagmi/connectors +``` +::: + +And import connectors from there. + +```ts +import { injected } from '@wagmi/connectors' +``` + +See the [connectors documentation](/core/api/connectors) for more information. + +### Updated connector API + +In order to maximize type-safety and ease of creating connectors, the connector API changed. Follow the [Creating Connectors guide](/dev/creating-connectors) for more info on creating new connectors and converting Wagmi v1 connectors. + +### Removed individual entrypoints + +Previously, each connector had its own entrypoint to optimize tree-shaking. Since all connectors now have [`package.json#sideEffects`](https://webpack.js.org/guides/tree-shaking/#mark-the-file-as-side-effect-free) enabled, this is no longer necessary and the entrypoint is unified. Use the `'@wagmi/connectors'` package instead. + +```ts +import { InjectedConnector } from '@wagmi/core/connectors/injected' // [!code --] +import { CoinbaseWalletConnector } from '@wagmi/core/connectors/coinbaseWallet' // [!code --] +import { coinbaseWallet, injected } from '@wagmi/connectors' // [!code ++] +``` + +### Removed `MetaMaskConnector` + +The `MetaMaskConnector` was removed since it was nearly the same thing as the `InjectedConnector`. Use the [`injected`](/core/api/connectors/injected) connector instead, along with the [`target`](/core/api/connectors/injected#target) parameter set to `'metaMask'`, for the same behavior. + +```ts +import { MetaMaskConnector } from '@wagmi/core/connectors/metaMask' // [!code --] +import { injected } from '@wagmi/connectors' // [!code ++] + +const connector = new MetaMaskConnector() // [!code --] +const connector = injected({ target: 'metaMask' }) // [!code ++] +``` + +### Renamed connectors + +In Wagmi v1, connectors were classes you needed to instantiate. In Wagmi v2, connectors are functions. As a result, the API has changed. Connectors have the following new names: + +- `CoinbaseWalletConnector` is now [`coinbaseWallet`](/core/api/connectors/coinbaseWallet). +- `InjectedConnector` is now [`injected`](/core/api/connectors/injected). +- `SafeConnector` is now [`safe`](/core/api/connectors/safe). +- `WalletConnectConnector` is now [`walletConnect`](/core/api/connectors/walletConnect). + +To create a connector, you now call the connector function with parameters. + +```ts +import { WalletConnectConnector } from '@wagmi/core/connectors/walletConnect' // [!code --] +import { walletConnect } from '@wagmi/connectors' // [!code ++] + +const connector = new WalletConnectConnector({ // [!code --] +const connector = walletConnect({ // [!code ++] + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', +}) +``` + +### Removed `WalletConnectLegacyConnector` + +WalletConnect v1 was sunset June 28, 2023. Use the [`walletConnect`](/core/api/connectors/walletConnect) connector instead. + +```ts +import { WalletConnectLegacyConnector } from '@wagmi/core/connectors/walletConnectLegacy' // [!code --] +import { walletConnect } from '@wagmi/connectors' // [!code ++] + +const connector = new WalletConnectLegacyConnector({ // [!code --] +const connector = walletConnect({ // [!code ++] + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', +}) +``` + +## Chains + +### Updated `'@wagmi/core/chains'` entrypoint + +Chains now live in the [Viem repository](https://github.com/wevm/viem). As a result, the `'@wagmi/core/chains'` entrypoint now proxies all chains from `'viem/chains'` directly. + +### Removed `mainnet` and `sepolia` from main entrypoint + +Since the `'@wagmi/core/chains'` entrypoint now proxies `'viem/chains'`, `mainnet` and `sepolia` were removed from the main entrypoint. Use the `'@wagmi/core/chains'` entrypoint instead. + +```ts +import { mainnet, sepolia } from '@wagmi/core' // [!code --] +import { mainnet, sepolia } from '@wagmi/core/chains' // [!code ++] +``` + +## Errors + +A number of errors were renamed to better reflect their functionality or replaced by Viem errors. + +## Miscellaneous + +### Removed internal ENS normalization + +Before v2, Wagmi handled ENS name normalization internally for `getEnsAddress`, `getEnsAvatar`, and `getEnsResolver`, using Viem's [`normalize`](https://viem.sh/docs/ens/utilities/normalize.html) function. This added extra bundle size as full normalization is quite heavy. For v2, you must normalize ENS names yourself before passing them to these actions. You can use Viem's `normalize` function or any other function that performs [UTS-46 normalization](https://unicode.org/reports/tr46). + + +::: code-group +```ts [index.ts] +import { getEnsAddress } from '@wagmi/core' +import { normalize } from 'viem' // [!code ++] +import { config } from './config' + +const result = await getEnsAddress(config, { + name: 'wevm.eth', // [!code --] + name: normalize('wevm.eth'), // [!code ++] +}) +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +By inverting control, Wagmi lets you choose how much normalization to do. For example, maybe your project only allows ENS names that are numeric so no normalization is not needed. Check out the [ENS documentation](https://docs.ens.domains/contract-api-reference/name-processing#normalising-names) for more information on normalizing names. + +### Removed `configureChains` + +The Wagmi v2 `Config` now has native multichain support using the [`chains`](/core/api/createConfig) parameter so the `configureChains` function is no longer required. + +```ts +import { configureChains, createConfig } from '@wagmi/core' // [!code --] +import { http, createConfig } from '@wagmi/core' // [!code ++] +import { mainnet, sepolia } from '@wagmi/core/chains' + +const { chains, publicClient } = configureChains( // [!code --] + [mainnet, sepolia], // [!code --] + [publicProvider(), publicProvider()], // [!code --] +) // [!code --] + +export const config = createConfig({ + publicClient, // [!code --] + chains: [mainnet, sepolia], // [!code ++] + transports: { // [!code ++] + [mainnet.id]: http(), // [!code ++] + [sepolia.id]: http(), // [!code ++] + }, // [!code ++] +}) +``` + +### Removed ABI exports + +Import from Viem instead. + +```ts +import { erc20ABI } from '@wagmi/core' // [!code --] +import { erc20Abi } from 'viem' // [!code ++] +``` + +### Removed `'@wagmi/core/providers/*` entrypoints + +It never made sense that we would have provider URLs hardcoded in the Wagmi codebase. Use [Viem transports](https://viem.sh/docs/clients/intro.html#transports) along with RPC provider URLs instead. + +```ts +import { alchemyProvider } from '@wagmi/core/providers/alchemy' // [!code --] +import { http } from 'viem' // [!code ++] + +const transport = http('https://mainnet.example.com') +``` + +### Updated `createConfig` parameters + +- Removed `autoConnect`. The reconnecting behavior must be managed manually and is not related to the Wagmi `Config`. Use the [`reconnect`](/core/api/actions/reconnect) action instead. +- Removed `publicClient` and `webSocketPublicClient`. Use [`transports`](/core/api/createConfig#transports) or [`client`](/core/api/createConfig#client) instead. +- Removed `logger`. Wagmi no longer logs debug information to console. + +### Updated `Config` object + +- Removed `config.connector`. Use `config.state.connections.get(config.state.current)?.connector` instead. +- Removed `config.data`. Use `config.state.connections.get(config.state.current)` instead. +- Removed `config.error`. Was unused and not needed. +- Removed `config.lastUsedChainId`. Use `config.state.connections.get(config.state.current)?.chainId` instead. +- Removed `config.publicClient`. Use [`config.getClient()`](/core/api/createConfig#getclient) or [`getPublicClient`](/core/api/actions/getPublicClient) instead. +- Removed `config.status`. Use [`config.state.status`](/core/api/createConfig#status) instead. +- Removed `config.webSocketClient`. Use [`config.getClient()`](/core/api/createConfig#getclient) or [`getPublicClient`](/core/api/actions/getPublicClient) instead. +- Removed `config.clearState`. Was unused and not needed. +- Removed `config.autoConnect()`. Use [`reconnect`](/core/api/actions/reconnect) action instead. +- Renamed `config.setConnectors`. Use `config._internal.setConnectors` instead. +- Removed `config.setLastUsedConnector`. Use `config.storage?.setItem('recentConnectorId', connectorId)` instead. +- Removed `getConfig`. `config` should be passed explicitly to actions instead of using global `config`. + +## Deprecations + +### Deprecated `getBalance` `token` parameter + +Moving forward, `getBalance` will only work for native currencies, thus the `token` parameter is no longer supported. Use [`readContracts`](/core/api/actions/readContracts) instead. + +```ts +import { getBalance } from '@wagmi/core' // [!code --] +import { readContracts } from '@wagmi/core' // [!code ++] +import { erc20Abi } from 'viem' // [!code ++] +import { config } from './config' // [!code ++] + +const result = await getBalance(config, { // [!code --] + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', // [!code --] + token: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code --] +}) // [!code --] +const result = await readContracts(config, { // [!code ++] + allowFailure: false, // [!code ++] + contracts: [ // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'balanceOf', // [!code ++] + args: ['0x4557B18E779944BFE9d78A672452331C186a9f48'], // [!code ++] + }, // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'decimals', // [!code ++] + }, // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'symbol', // [!code ++] + }, // [!code ++] + ] // [!code ++] +}) // [!code ++] +``` + +### Deprecated `getBalance` `unit` parameter and `formatted` return value + +Moving forward, `getBalance` will not accept the `unit` parameter or return a `formatted` value. Instead you can call `formatUnits` from Viem directly or use another number formatting library, like [dnum](https://github.com/bpierre/dnum) instead. + +```ts +import { formatUnits } from 'viem' // [!code ++] +import { getBalance } from '@wagmi/core' + +const result = await getBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + unit: 'ether', // [!code --] +}) +result.formatted // [!code --] +formatUnits(result.value, result.decimals) // [!code ++] +``` + +### Deprecated `getToken` + +Moving forward, `getToken` is no longer supported. Use [`readContracts`](/core/api/actions/readContracts) instead. + +```ts +import { getToken } from '@wagmi/core' // [!code --] +import { readContracts } from '@wagmi/core' // [!code ++] +import { erc20Abi } from 'viem' // [!code ++] +import { config } from './config' // [!code ++] + +const result = await getToken(config, { // [!code --] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code --] +}) // [!code --] +const result = await readContracts(config, { // [!code ++] + allowFailure: false, // [!code ++] + contracts: [ // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'decimals', // [!code ++] + }, // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'name', // [!code ++] + }, // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'symbol', // [!code ++] + }, // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'totalSupply', // [!code ++] + }, // [!code ++] + ] // [!code ++] +}) // [!code ++] +``` + +### Deprecated `formatUnits` parameters and return values + +The `formatUnits` parameter and related return values (e.g. `result.formatted`) are deprecated for the following actions: + +- [`estimateFeesPerGas`](/core/api/actions/estimateFeesPerGas) +- [`getToken`](/core/api/actions/getToken) + +Instead you can call `formatUnits` from Viem directly or use another number formatting library, like [dnum](https://github.com/bpierre/dnum) instead. + +```ts +import { formatUnits } from 'viem' // [!code ++] +import { getToken } from '@wagmi/core' + +const result = await getToken({ + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', + formatUnits: 'ether', +}) +result.totalSupply.formatted // [!code --] +formatUnits(result.totalSupply.value, 18) // [!code ++] +``` + +This allows us to invert control to users so they can handle number formatting however they want, taking into account precision, localization, and more. + +### Renamed actions + +The following actions were renamed to better reflect their functionality and underlying [Viem](https://viem.sh) actions: + +- `fetchBalance` is now [`getBalance`](/core/api/actions/getBalance) +- `fetchBlockNumber` is now [`getBlockNumber`](/core/api/actions/getBlockNumber) +- `fetchEnsAddress` is now [`getEnsAddress`](/core/api/actions/getEnsAddress) +- `fetchEnsAvatar` is now [`getEnsAvatar`](/core/api/actions/getEnsAvatar) +- `fetchEnsName` is now [`getEnsName`](/core/api/actions/getEnsName) +- `fetchEnsResolver` is now [`getEnsResolver`](/core/api/actions/getEnsResolver) +- `fetchToken` is now [`getToken`](/core/api/actions/getToken) +- `fetchTransaction` is now [`getTransaction`](/core/api/actions/getTransaction) +- `switchNetwork` is now [`switchChain`](/core/api/actions/switchChain) +- `waitForTransaction` is now [`waitForTransactionReceipt`](/core/api/actions/waitForTransactionReceipt) diff --git a/site/core/guides/testing.md b/site/core/guides/testing.md new file mode 100644 index 0000000000..383062dbea --- /dev/null +++ b/site/core/guides/testing.md @@ -0,0 +1,3 @@ +# Testing + + diff --git a/site/core/guides/viem.md b/site/core/guides/viem.md new file mode 100644 index 0000000000..275ed86949 --- /dev/null +++ b/site/core/guides/viem.md @@ -0,0 +1,197 @@ +# Viem + +[Viem](https://viem.sh) is a low-level TypeScript Interface for Ethereum that enables developers to interact with the Ethereum blockchain, including: JSON-RPC API abstractions, Smart Contract interaction, wallet & signing implementations, coding/parsing utilities and more. + +**Wagmi Core** is essentially a wrapper over **Viem** that provides multi-chain functionality via [Wagmi Config](/core/api/createConfig) and automatic account management via [Connectors](/core/api/connectors). + +## Leveraging Viem Actions + +All of the core [Wagmi Actions](/core/api/actions) are friendly wrappers around [Viem Actions](https://viem.sh/docs/actions/public/introduction.html) that inject a multi-chain and connector aware [Wagmi Config](/core/api/createConfig). + +There may be cases where you might want to dig deeper and utilize Viem Actions directly (maybe an Action doesn't exist in Wagmi yet). In these cases, you can import Viem Actions directly via `viem/actions` and plug in a Viem Client returned by the [`getClient` Action](/core/api/actions/getClient). + +The example below demonstrates two different ways to utilize Viem Actions: + +1. **Tree-shakable Actions (recommended):** Uses `getClient` (for public actions) and `getConnectorClient` (for wallet actions). +2. **Client Actions:** Uses `getPublicClient` (for public actions) and `getWalletClient` (for wallet actions). + +::: tip + +It is highly recommended to use the **tree-shakable** method to ensure that you are only pulling modules you use, and keep your bundle size low. + +::: + +::: code-group + +```tsx [Tree-shakable Actions] +// 1. Import modules. +import { http, createConfig, getClient, getConnectorClient } from '@wagmi/core' +import { base, mainnet, optimism, zora } from '@wagmi/core/chains' +import { getLogs, watchAsset } from 'viem/actions' // [!code hl] + +// 2. Set up a Wagmi Config +export const config = createConfig({ + chains: [base, mainnet, optimism, zora], + transports: { + [base.id]: http(), + [mainnet.id]: http(), + [optimism.id]: http(), + [zora.id]: http(), + }, +}) + +// 3. Extract a Viem Client for the current active chain. +const publicClient = getClient(config) +const logs = await getLogs(publicClient, /* ... */) // [!code hl] + +// 4. Extract a Viem Client for the current active chain & account. +const walletClient = getConnectorClient(config) +const success = await watchAsset(walletClient, /* ... */) // [!code hl] +``` + +```tsx [Client Actions] +// 1. Import modules. +import { http, createConfig, getPublicClient, getWalletClient } from '@wagmi/core' +import { base, mainnet, optimism, zora } from '@wagmi/core/chains' + +// 2. Set up a Wagmi Config +export const config = createConfig({ + chains: [base, mainnet, optimism, zora], + transports: { + [base.id]: http(), + [mainnet.id]: http(), + [optimism.id]: http(), + [zora.id]: http(), + }, +}) + +// 3. Extract a Viem Public Client for the current active chain. +const publicClient = getPublicClient(config) +const logs = await publicClient.getLogs(publicClient, /* ... */) // [!code hl] + +// 4. Extract a Viem Wallet Client for the current active chain & account. +const walletClient = getWalletClient(config) +const success = await walletClient.watchAsset(walletClient, /* ... */) // [!code hl] +``` + +::: + +## Multi-chain Viem Client + +The [Viem Client](https://viem.sh/docs/client) provides an interface to interact with an JSON-RPC Provider. By nature, JSON-RPC Providers are single-chain, so the Viem Client is designed to be instantiated with a single `chain`. As a result, setting up Viem to be multi-chain aware can get a bit verbose. + +The good news is that you can create a **"multi-chain Viem Client"** with **Wagmi** by utilizing [`createConfig`](/core/api/createConfig) and [`getClient`](/core/api/actions/getClient). + +::: code-group + +```tsx [Wagmi Usage] +// 1. Import modules. +import { http, createConfig, getClient, getConnectorClient } from '@wagmi/core' +import { base, mainnet, optimism, zora } from '@wagmi/core/chains' +import { getBlockNumber, sendTransaction } from 'viem/actions' // [!code hl] + +// 2. Set up a Wagmi Config +export const config = createConfig({ + chains: [base, mainnet, optimism, zora], + transports: { + [base.id]: http(), + [mainnet.id]: http(), + [optimism.id]: http(), + [zora.id]: http(), + }, +}) + +// 3. Extract a Viem Client for the current active chain. +const publicClient = getClient(config) +const blockNumber = await getBlockNumber(publicClient) // [!code hl] + +// 4. Extract a Viem Client for the current active chain & account. +const walletClient = getConnectorClient(config) +const hash = await sendTransaction(walletClient, /* ... */) // [!code hl] +``` + +```tsx [Viem Usage] +// Manually set up Viem Clients without wagmi. Don't do this, it's only here +// to demonstrate the amount of boilerplate required. + +import { createPublicClient, createWalletClient, http } from 'viem' +import { base, mainnet, optimism, zora } from 'viem/chains' + +const publicClient = { + base: createPublicClient({ + chain: base, + transport: http() + }), + mainnet: createPublicClient({ + chain: mainnet, + transport: http() + }), + optimism: createPublicClient({ + chain: optimism, + transport: http() + }), + zora: createPublicClient({ + chain: zora, + transport: http() + }) +} as const + +const walletClient = { + base: createWalletClient({ + chain: base, + transport: custom(window.ethereum) + }), + mainnet: createWalletClient({ + chain: mainnet, + transport: custom(window.ethereum) + }), + optimism: createWalletClient({ + chain: optimism, + transport: custom(window.ethereum) + }), + zora: createWalletClient({ + chain: zora, + transport: custom(window.ethereum) + }) +} as const + +const blockNumber = await publicClient.mainnet.getBlockNumber() +const hash = await walletClient.mainnet.sendTransaction(/* ... */) +``` + +::: + +## Private Key & Mnemonic Accounts + +It is possible to utilize Viem's [Private Key & Mnemonic Accounts](https://viem.sh/docs/accounts/local.html) with Wagmi by explicitly passing through the account via the `account` argument on Wagmi Actions. + +```tsx +import { http, createConfig, sendTransaction } from '@wagmi/core' +import { base, mainnet, optimism, zora } from '@wagmi/core/chains' +import { parseEther } from 'viem' +import { privateKeyToAccount } from 'viem/accounts' + +export const config = createConfig({ + chains: [base, mainnet, optimism, zora], + transports: { + [base.id]: http(), + [mainnet.id]: http(), + [optimism.id]: http(), + [zora.id]: http(), + }, +}) + +const account = privateKeyToAccount('0x...') // [!code hl] + +const hash = await sendTransaction({ + account, // [!code hl] + to: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + value: parseEther('0.001') +}) +``` + +::: info + +Wagmi currently does not support hoisting Private Key & Mnemonic Accounts to the top-level Wagmi Config – meaning you have to explicitly pass through the account to every Action. If you feel like this is a feature that should be added, please [open a discussion](https://github.com/wevm/wagmi/discussions/new?category=ideas). + +::: diff --git a/site/core/installation.md b/site/core/installation.md new file mode 100644 index 0000000000..858ebc6879 --- /dev/null +++ b/site/core/installation.md @@ -0,0 +1,52 @@ + + +# Installation + +Install Wagmi Core via your package manager, a ` +``` + + diff --git a/site/core/typescript.md b/site/core/typescript.md new file mode 100644 index 0000000000..e41d942828 --- /dev/null +++ b/site/core/typescript.md @@ -0,0 +1,241 @@ + + +# TypeScript + +## Requirements + +Wagmi Core is designed to be as type-safe as possible! Things to keep in mind: + +- Types currently require using TypeScript {{typescriptVersion}}. +- [TypeScript doesn't follow semver](https://www.learningtypescript.com/articles/why-typescript-doesnt-follow-strict-semantic-versioning) and often introduces breaking changes in minor releases. +- Changes to types in this repository are considered non-breaking and are usually released as patch changes (otherwise every type enhancement would be a major version!). +- It is highly recommended that you lock your `@wagmi/core` and `typescript` versions to specific patch releases and upgrade with the expectation that types may be fixed or upgraded between any release. +- The non-type-related public API of Wagmi Core still follows semver very strictly. + +To ensure everything works correctly, make sure your `tsconfig.json` has [`strict`](https://www.typescriptlang.org/tsconfig#strict) mode set to `true`. + +::: code-group +```json [tsconfig.json] +{ + "compilerOptions": { + "strict": true + } +} +``` +::: + +## Const-Assert ABIs & Typed Data + +Wagmi Core can infer types based on [ABIs](https://docs.soliditylang.org/en/latest/abi-spec.html#json) and [EIP-712](https://eips.ethereum.org/EIPS/eip-712) Typed Data definitions, powered by [Viem](https://viem.sh) and [ABIType](https://github.com/wevm/abitype). This achieves full end-to-end type-safety from your contracts to your frontend and enlightened developer experience by autocompleting ABI item names, catching misspellings, inferring argument and return types (including overloads), and more. + +For this to work, you must either [const-assert](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-4.html#const-assertions) ABIs and Typed Data (more info below) or define them inline. For example, `useReadContract`'s `abi` configuration parameter: + +```ts +const result = await readContract({ + abi: […], // <--- defined inline // [!code focus] +}) +``` + +```ts +const abi = […] as const // <--- const assertion // [!code focus] +const result = readContract({ abi }) +``` + +If type inference isn't working, it's likely you forgot to add a `const` assertion or define the configuration parameter inline. Also, make sure your ABIs, Typed Data definitions, and [TypeScript configuration](#requirements) are valid and set up correctly. + +::: tip +Unfortunately [TypeScript doesn't support importing JSON `as const` yet](https://github.com/microsoft/TypeScript/issues/32063). Check out the [Wagmi CLI](/cli/getting-started) to help with this! It can automatically fetch ABIs from Etherscan and other block explorers, resolve ABIs from your Foundry/Hardhat projects, and more. +::: + +Anywhere you see the `abi` or `types` configuration property, you can likely use const-asserted or inline ABIs and Typed Data to get type-safety and inference. These properties are also called out in the docs. + +Here's what [`readContract`](/core/api/actions/readContract) looks like with and without a const-asserted `abi` property. + +::: code-group +```ts twoslash [Const-Asserted] +import { createConfig, http } from '@wagmi/core' +import { mainnet, sepolia } from '@wagmi/core/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) + +const erc721Abi = [ + { + name: 'balanceOf', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'address', name: 'owner' }], + outputs: [{ type: 'uint256' }], + }, + { + name: 'isApprovedForAll', + type: 'function', + stateMutability: 'view', + inputs: [ + { type: 'address', name: 'owner' }, + { type: 'address', name: 'operator' }, + ], + outputs: [{ type: 'bool' }], + }, + { + name: 'getApproved', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'address' }], + }, + { + name: 'ownerOf', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'address' }], + }, + { + name: 'tokenURI', + type: 'function', + stateMutability: 'pure', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'string' }], + }, +] as const +// ---cut--- +import { readContract } from '@wagmi/core' + +const result = await readContract(config, { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: erc721Abi, + functionName: 'balanceOf', + // ^? + + + + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e'], + // ^? +}) + +result +// ^? +``` +```ts twoslash [Not Const-Asserted] +import { createConfig, http } from '@wagmi/core' +import { mainnet, sepolia } from '@wagmi/core/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) + +declare const erc721Abi: { + name: string; + type: string; + stateMutability: string; + inputs: { + type: string; + name: string; + }[]; + outputs: { + type: string; + }[]; +}[] +// ---cut--- +import { readContract } from '@wagmi/core' + +const result = await readContract(config, { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: erc721Abi, + functionName: 'balanceOf', + // ^? + + + + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e'], + // ^? +}) + +result +// ^? +``` +::: + +You can prevent runtime errors and be more productive by making sure your ABIs and Typed Data definitions are set up appropriately. 🎉 + +```ts twoslash +// @errors: 2820 +import { createConfig, http } from '@wagmi/core' +import { mainnet, sepolia } from '@wagmi/core/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) + +const erc721Abi = [ + { + name: 'balanceOf', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'address', name: 'owner' }], + outputs: [{ type: 'uint256' }], + }, + { + name: 'isApprovedForAll', + type: 'function', + stateMutability: 'view', + inputs: [ + { type: 'address', name: 'owner' }, + { type: 'address', name: 'operator' }, + ], + outputs: [{ type: 'bool' }], + }, + { + name: 'getApproved', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'address' }], + }, + { + name: 'ownerOf', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'address' }], + }, + { + name: 'tokenURI', + type: 'function', + stateMutability: 'pure', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'string' }], + }, +] as const +// ---cut--- +import { readContract } from '@wagmi/core' + +readContract(config, { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: erc721Abi, + functionName: 'balanecOf', + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e'], +}) +``` + +## Configure Internal Types + +For advanced use-cases, you may want to configure wagmi's internal types. Most of wagmi's types relating to ABIs and EIP-712 Typed Data are powered by [ABIType](https://github.com/wevm/abitype). See the [ABIType docs](https://abitype.dev) for more info on how to configure types. diff --git a/site/core/why.md b/site/core/why.md new file mode 100644 index 0000000000..d7ed951f02 --- /dev/null +++ b/site/core/why.md @@ -0,0 +1,46 @@ +# Why Wagmi Core + +## The Problems + +Building Ethereum applications is hard. Apps need to support connecting wallets, multiple chains, signing messages and data, sending transactions, listening for events and state changes, refreshing stale blockchain data, and much more. This is all on top of solving for app-specific use-cases and providing polished user experiences. + +The ecosystem is also continuously evolving, meaning you need to adapt to new improvements or get left behind. App developers should not need to worry about connecting tens of different wallets, the intricacies of multi-chain support, typos accidentally sending an order of magnitude more ETH or calling a misspelled contract function, or accidentally spamming their RPC provider, costing thousands in compute units. + +Wagmi Core solves all these problems and more — allowing app developers to focus on building high-quality and performant experiences for Ethereum — by focusing on **developer experience**, **performance**, **feature coverage**, and **stability.** + +## Developer Experience + +Wagmi Core delivers a great developer experience through modular and composable APIs, automatic type safety and inference, and comprehensive documentation. + +It provides developers with intuitive building blocks to build their Ethereum apps. While Wagmi Core's APIs might seem more verbose at first, it makes Wagmi Core's modular building blocks extremely flexible. Easy to move around, change, and remove. It also allows developers to better understand Ethereum concepts as well as understand _what_ and _why_ certain properties are being passed through. Learning how to use Wagmi Core is a great way to learn how to interact with Ethereum in general. + +Wagmi Core also provides [strongly typed APIs](/core/typescript), allowing consumers to get the best possible experience through [autocomplete](https://twitter.com/awkweb/status/1555678944770367493), [type inference](https://twitter.com/jakemoxey/status/1570244174502588417?s=20), as well as static validation. You often just need to provide an ABI and Wagmi Core can help you autocomplete your way to success, identify type errors before your users do, drill into blockchain errors [at compile and runtimes](/core/guides/error-handling) with surgical precision, and much more. + +The API documentation is comprehensive and contains usage info for _every_ module in Wagmi Core. The core team uses a [documentation](https://gist.github.com/zsup/9434452) and [test driven](https://en.wikipedia.org/wiki/Test-driven_development#:~:text=Test%2Ddriven%20development%20(TDD),software%20against%20all%20test%20cases.) development approach to building modules, which leads to predictable and stable APIs. + +## Performance + +Performance is critical for applications on all sizes. Slow page load and interactions can cause users to stop using applications. Wagmi Core uses and is built by the same team behind [Viem](https://viem.sh), the most performant production-ready Ethereum library. + +End users should not be required to download a module of over 100kB in order to interact with Ethereum. Wagmi Core is optimized for tree-shaking and dead-code elimination, allowing apps to minimize bundle size for fast page load times. + +Data layer performance is also critical. Slow, unnecessary, and manual data fetching can make apps unusable and cost thousands in RPC compute units. Wagmi Core supports caching, deduplication, persistence, and much more through [TanStack Query](/react/guides/tanstack-query) via the `'@wagmi/core/query'` entrypoint so you can [plug it into your framework](/core/guides/framework-adapters) of choice, like Vue, Svelte, and more. + +## Feature Coverage + +Wagmi Core supports the most popular and commonly-used Ethereum features out of the box with 40+ VanillaJS Actions for accounts, wallets, contracts, transactions, signing, ENS, and more. Wagmi Core also supports just about any wallet out there through its official [connectors](/core/api/connectors), [EIP-6963 support](/core/api/createConfig#multiinjectedproviderdiscovery), and [extensible API](/dev/creating-connectors). + +If you need lower-level control, you can always drop down to [Viem](https://viem.sh), which Wagmi Core uses internally to perform blockchain operations. Wagmi Core also manages multi-chain support automatically so developers can focus on their applications instead of adding custom code. + +Finally, Wagmi Core has a [CLI](/cli/getting-started) to manage ABIs as well as a robust ecosystem of third-party libraries, like [ConnectKit](https://docs.family.co/connectkit), [RainbowKit](https://www.rainbowkit.com), [AppKit](https://walletconnect.com/appkit), [Dynamic](https://www.dynamic.xyz), [Privy](https://privy.io), and many more, so you can get started quickly without needing to build everything from scratch. + +## Stability + +Stability is a fundamental principle for Wagmi Core. Many organizations, large and small, rely heavily on Wagmi Core and expect it to be entirely stable for their users and applications. + +Wagmi Core's test suite runs against forked Ethereum nodes to make sure functions work across chains. The test suite also runs type tests against many different versions of peer dependencies, like TypeScript, to ensure compatibility with the latest releases of other popular software. + +Wagmi Core follows semver so developers can upgrade between versions with confidence. Starting with Wagmi Core v2, new functionality will be opt-in with old functionality being deprecated alongside the new features. This means upgrading to the latest major versions will not require immediate changes. + +Lastly, the core team works full-time on Wagmi Core and [related projects](https://github.com/wevm), and is constantly improving Wagmi Core and keeping it up-to-date with industry trends and changes. + diff --git a/site/dev/contributing.md b/site/dev/contributing.md new file mode 100644 index 0000000000..f5c0d8335a --- /dev/null +++ b/site/dev/contributing.md @@ -0,0 +1,171 @@ + + +# Contributing + +Thanks for your interest in contributing to Wagmi! Please take a moment to review this document **before submitting a pull request.** + +## Overview + +This guide is intended to help you get started with contributing. By following these steps, you will understand the development process and workflow. If you want to contribute, but aren't sure where to start, you can create a [new discussion](https://github.com/wevm/wagmi/discussions/new/choose). + +:::warning +**Please ask first before starting work on any significant new features. This includes things like adding new hooks, actions, connectors, etc.** + +It's never a fun experience to have your pull request declined after investing time and effort into a new feature. To avoid this from happening, we request that contributors first create a [feature request](https://github.com/wevm/wagmi/discussions/new?category=ideas) to discuss any API changes or significant new ideas. +::: + +## 1. Cloning the repository + +To start contributing to the project, clone it to your local machine using git: + +```bash +git clone https://github.com/wevm/wagmi.git +``` + +Or the [GitHub CLI](https://cli.github.com): + +```bash +gh repo clone wevm/wagmi +``` + +## 2. Installing Node.js and pnpm + +Wagmi uses Node.js with [pnpm workspaces](https://pnpm.io/workspaces) to manage multiple projects. You can run the following command in your terminal to check your local Node.js version. + +```bash +node -v +``` + +If **`node@{{nodeVersion}}`** is not installed, you can install via [fnm](https://github.com/Schniz/fnm) or from the [official website](https://nodejs.org). + +Once Node.js is installed, run the following to install [Corepack](https://nodejs.org/api/corepack.html). Corepack automatically installs and manages **`{{packageManager}}`**. + +```bash +corepack enable +``` + +## 3. Installing dependencies + +Once in the project's root directory, run the following command to install pnpm (via Corepack) and the project's dependencies: + +```bash +pnpm install +``` + +After the install completes, pnpm links packages across the project for development and [git hooks](https://github.com/toplenboren/simple-git-hooks) are set up. + +## 4. Adding the env variables + +The [dev playgrounds](#_5-running-the-dev-playgrounds) and [test suite](#_6-running-the-test-suite) require environment variables to be set. Copy over the following environment variables to `.env`, and fill them out. + +```bash +VITE_MAINNET_FORK_URL=https://eth.merkle.io +VITE_OPTIMISM_FORK_URL=https://mainnet.optimism.io + +NEXT_PUBLIC_WC_PROJECT_ID=3fbb6bba6f1de962d911bb5b5c9dba88 +NUXT_PUBLIC_WC_PROJECT_ID=3fbb6bba6f1de962d911bb5b5c9dba88 +VITE_WC_PROJECT_ID=3fbb6bba6f1de962d911bb5b5c9dba88 + +NEXT_TELEMETRY_DISABLED=1 +NUXT_TELEMETRY_DISABLED=1 +``` + +You might want to change `*_FORK_URL` to a paid RPC provider for better performance. + +## 5. Running the dev playgrounds + +To start the local development playgrounds, run one of the following commands. These commands run playground apps, located at `./playgrounds`, that are set up for trying out code while making changes. + +```bash +pnpm dev # `wagmi` playground +pnpm dev:core # `@wagmi/core` playground +pnpm dev:create-wagmi # `create-wagmi` cli tool +pnpm dev:cli # `@wagmi/cli` tool +pnpm dev:next # `wagmi` playground with Next.js +pnpm dev:nuxt # `@wagmi/vue` playground with Nuxt.js +pnpm dev:react # `wagmi` playground (same as `pnpm dev`) +pnpm dev:vue # `@wagmi/vue` playground +``` + +Once a playground dev server is running, you can make changes to any of the package source files (e.g. `packages/react`) and it will automatically update the playground. + +## 6. Running the test suite + +Wagmi uses [Vitest](https://vitest.dev) to run tests and [Prool](https://github.com/wevm/prool) to execute tests against locally running chain forks. First, install [Anvil](https://github.com/foundry-rs/foundry/tree/master/crates/anvil) via [Foundryup](https://book.getfoundry.sh/getting-started/installation). + +```bash +curl -L https://foundry.paradigm.xyz | bash +foundryup +``` + +Next, make sure you have set up your [env variables](#_4-adding-the-env-variables). Now you are ready to run the tests! You have the following options for running tests: + +- `pnpm test [package?]` — runs tests in watch mode +- `pnpm test:cov` — runs tests and reports coverage +- `pnpm test:core` — runs `@wagmi/core` tests +- `pnpm test:react` — runs `wagmi` tests +- `pnpm test:vue` — runs `@wagmi/vue` tests + +When adding new features or fixing bugs, it's important to add test cases to cover the new or updated behavior. If snapshot tests fail, you can run the `test:update` command to update the snapshots. + +## 7. Writing documentation + +Documentation is crucial to helping developers of all experience levels use Wagmi. Wagmi uses [VitePress](https://vitepress.dev) for the documentation site (located at `./site`). To start the site in dev mode, run: + +```bash +pnpm docs:dev +``` + +Try to keep documentation brief and use plain language so folks of all experience levels can understand. If you think something is unclear or could be explained better, you are welcome to open a pull request. + +## 8. Submitting a pull request + +When you're ready to submit a pull request, you can follow these naming conventions: + +- Pull request titles use the [Imperative Mood](https://en.wikipedia.org/wiki/Imperative_mood) (e.g., `Add something`, `Fix something`). +- [Changesets](#versioning) use past tense verbs (e.g., `Added something`, `Fixed something`). + +When you submit a pull request, GitHub will automatically lint, build, and test your changes. If you see an ❌, it's most likely a bug in your code. Please, inspect the logs through the GitHub UI to find the cause. + +**Please make sure that "Allow edits from maintainers" is enabled so the core team can make updates to your pull request if necessary.** + +## 9. Versioning + +When adding new features or fixing bugs, we'll need to bump the package versions. We use [Changesets](https://github.com/changesets/changesets) to do this. + +::: tip +Only changes to the codebase that affect the public API or existing behavior (e.g. bugs) need changesets. +::: + +Each changeset defines which packages should be published and whether the change should be a major/minor/patch release, as well as providing release notes that will be added to the changelog upon release. + +To create a new changeset, run `pnpm changeset`. This will run the Changesets CLI, prompting you for details about the change. You’ll be able to edit the file after it’s created — don’t worry about getting everything perfect up front. + +Even though you can technically use any markdown formatting you like, headings should be avoided since each changeset will ultimately be nested within a bullet list. Instead, bold text should be used as section headings. + +If your PR is making changes to an area that already has a changeset (e.g. there’s an existing changeset covering theme API changes but you’re making further changes to the same API), you should update the existing changeset in your PR rather than creating a new one. + +### Releasing to npm + +The first time a PR with a changeset is merged after a release, a new PR will automatically be created called `chore: version packages`. Any subsequent PRs with changesets will automatically update this existing version packages PR. Merging this PR triggers the release process by publishing to npm and cleaning up the changeset files. + +### Creating a snapshot release + +If a PR has changesets, you can create a [snapshot release](https://github.com/changesets/changesets/blob/main/docs/snapshot-releases.md) by [manually dispatching](https://github.com/wevm/wagmi/actions/workflows/canary.yml) the Canary workflow. This publishes a tagged version to npm with the PR branch name and timestamp. + +## 10. Updating dependencies + +Use [Taze](https://github.com/antfu/taze) by running: + +```bash +pnpm deps # prints outdated deps +pnpm deps patch # print outdated deps with new patch versions +pnpm deps -w # updates deps (best done with clean working tree) +``` + +[Socket](https://socket.dev) checks pull requests for vulnerabilities when new dependencies and versions are added, but you should also be vigilant! When updating dependencies, you should check release notes and source code as well as lock versions when possible. diff --git a/site/dev/creating-connectors.md b/site/dev/creating-connectors.md new file mode 100644 index 0000000000..c9e82b04b1 --- /dev/null +++ b/site/dev/creating-connectors.md @@ -0,0 +1,155 @@ +# Creating Connectors + +Thanks for your interest in adding a new connector to Wagmi! Please take a moment to review this document **before starting work on a new connector.** + +## Overview + +This guide details how to create new connectors and upstream them back into Wagmi. By following these steps, you will understand the development process, workflow, and requirements for new connectors. **Not all connectors will be accepted into Wagmi** for a variety of reasons outlined in this document. + +In addition, for connector requests to be accepted, the team creating the connector must [sponsor Wagmi](https://github.com/sponsors/wevm). It takes time and effort to maintain third-party connectors. Wagmi is an OSS project that depends on sponsors and grants to continue our work. Please get in touch via [dev@wevm.dev](mailto:dev@wevm.dev) if you have questions about sponsoring. + +::: warning **Please ask first before starting work on a new connector.** +To avoid having your pull request declined after investing time and effort into a new connector, we ask that contributors create a [Connector Request](https://github.com/wevm/wagmi/discussions/new?category=connector-request) before starting work. This ensures the connector solves for an important or general use-case of interest to Wagmi users and is well supported by the Wagmi and connector teams. +::: + +## 1. Follow the contributing guide + +Check out the [Contributing Guide](/dev/contributing) to get your local development environment set up and learn more about the contributing workflow. + +## 2. Create a new file for the connector + +Create a new file in `packages/connector/src` named after the connector you want to add. + +For example, if you want to add Foo, you would create a file named `foo.ts`. File names should be camel-cased and as short as possible. + +## 3. Create the connector object. + +Import `createConnector` from `@wagmi/core` and export a new function that accepts a parameters object and returns the `createConnector` result. This is the base of all connectors. The name of the connector name should be the same as the file name. + +```ts +import { createConnector } from '@wagmi/core' + +export type FooBarBazParameters = {} + +export function fooBarBaz(parameters: FooBarBazParameters = {}) { + return createConnector((config) => ({})) +} +``` + +## 4. Add the missing properties to the object + +Now that the base of the connector is set up, you should see a type error that looks something like this: + +```ts twoslash +// @errors: 2740 +import { createConnector } from '@wagmi/core' +// ---cut--- +createConnector((config) => ({})) +``` + +The type error tells you what properties are missing from `createConnector`'s return type. Add them all in! + +#### Properties + +- `icon`: Optional icon URL for the connector. +- `id`: The ID for the connector. This should be camel-cased and as short as possible. Example: `fooBarBaz`. +- `name`: Human-readable name for the connector. Example: `'Foo Bar Baz'`. +- `rdns`: Optional reverse DNS for the connector. This is used to filter out duplicate [EIP-6963](https://eips.ethereum.org/EIPS/eip-6963) injected providers when `createConfig#multiInjectedProviderDiscovery` is enabled. + +#### Methods + +- `connect`: Function for connecting the connector. +- `disconnect`: Function for disconnecting the connector. +- `getAccounts`: Function that returns the connected accounts for the connector. +- `getChainId`: Function that returns the connected chain ID for the connector. +- `getProvider`: Function that returns the underlying provider interface for internal use throughout the connector. +- `isAuthorized`: Function that returns whether the connector has connected previously and is still authorized. +- `setup`: Optional function for running when the connector is first created. +- `switchChain`: Optional function for switching the connector's active chain. + +#### Events + +- `onAccountsChanged`: Function for subscribing to account changes internally in the connector. +- `onChainChanged`: Function for subscribing to chain changes internally in the connector. +- `onConnect`: Function for subscribing to connection events internally in the connector. +- `onDisconnect`: Function for subscribing to disconnection events internally in the connector. +- `onMessage`: Optional function for subscribing to messages internally in the connector. + +#### Parameters + +`createConnector` also has the following config properties you can use within the connector: + +- `chains`: List of chains configured by the user. +- `emitter`: Emitter for emitting events. Used to sync connector state with Wagmi `Config`. The following events are available: + - `change`: Emitted when the connected accounts or chain changes. + - `connect`: Emitted when the connector connects. + - `disconnect`: Emitted when the connector disconnects. + - `error`: Emitted when the connector receives an error. + - `message`: Emitted when the connector receives a message. +- `storage`: Optional storage configured by the user. Defaults to wrapper around localStorage. + +::: tip +If you plan to use a third-party SDK, it should have minimal dependencies (limit bundle size, supply chain attacks, etc.) and use the most permissive license possible (ideally MIT). Any third-party packages, should also have [`"sideEffects": false`](https://webpack.js.org/guides/tree-shaking/#mark-the-file-as-side-effect-free) in their `package.json` file for maximum tree-shakability support. +::: + +::: tip +All address values returned and emitted by the connector should be checksummed using Viem's [`getAddress`](https://viem.sh/docs/utilities/getAddress). +::: + +## 5. Export the connector + +Export the connector from `packages/connector/src/exports/index.ts` in alphabetic order. + +```ts +export { fooBarBaz } from './fooBarBaz.js' +``` + +## 6. Try out the connector and add tests + +While building a connector, it can be useful to try it out with Wagmi. You can use the [development playgrounds](/dev/contributing#_5-running-the-dev-playgrounds) for testing your changes. + +Ideally, you should also be able to add tests for the connector in a `connectorName.test.ts` file. This isn't always easy so at a minimum please create a test file with instructions for how to test the connector manually. The test file should include actual tests or "instruction tests" for the following: + +- How to connect the connector. +- How to disconnect the connector. +- How to switch the connector's active chain (if applicable). + +Remember to include all info required to test the connector, like software to install (browser extension, mobile app, etc.), smart contracts to interact with/deploy, etc. + +Finally, you should also update the test file in `packages/connectors/src/exports/index.test.ts` to include the new connector. You can do this manually or by running: + +```bash +pnpm test:update packages/connectors/src/exports/index.test.ts +``` + +## 7. Add your team to CODEOWNERS + +It is critical that connectors are updated in a timely manner and actively maintained so that users of Wagmi can rely on them in production settings. + +The Wagmi core team will provide as much assistance as possible to keep connectors up-to-date with breaking changes from Wagmi, but it is your responsibility to ensure that any dependencies and issues/discussions related to the connector are handled in a timely manner. If issues are not resolved in a timely manner, the connector may be removed from Wagmi. + +In support of this goal, add at least one member of your team to the [CODEOWNERS](https://github.com/wevm/wagmi/blob/main/.github/CODEOWNERS) file so that you get notified of pull requests, issues, etc. related to the connector. You can add your team like this: + +``` +/packages/connectors/src/fooBarBaz @tmm @jxom +``` + +For more info about GitHub code owners, check out the [GitHub Documentation](https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners). + +## 8. Document the connector + +The connector should be documented. Follow the step on [writing documentation](/dev/contributing#_7-writing-documentation) to get set up with running the docs site locally and add the required pages. + +## 9. Create a changeset + +Now that the connector works and has tests, it's time to create a changeset to prepare for release. Run the following to create a changeset: + +```bash +pnpm changeset +``` + +The changeset should be a `patch` applied to the `@wagmi/connectors` repository with the description `Added [ConnectorName]`, For example, `Added Foo Bar Baz`. + +## 10. Create a pull request + +The connector is ready to go! Create a [pull request](/dev/contributing#_8-submitting-a-pull-request) and the connector should make it into a future release of Wagmi after some review. diff --git a/site/index.md b/site/index.md new file mode 100644 index 0000000000..23b40a7f13 --- /dev/null +++ b/site/index.md @@ -0,0 +1,58 @@ +--- +# https://vitepress.dev/reference/default-theme-home-page +layout: home + +description: Type Safe, Extensible, and Modular by design. Build high-performance blockchain frontends. +title: 'Wagmi | Reactivity for Ethereum apps' +titleTemplate: false + +hero: + name: Wagmi + text: Reactivity for Ethereum apps + tagline: Type Safe, Extensible, and Modular by design. Build high-performance blockchain frontends. + actions: + - theme: brand + text: Get Started + link: /react/getting-started + - theme: alt + text: Why Wagmi + link: /react/why + - theme: alt + text: View on GitHub + link: https://github.com/wevm/wagmi + image: + src: /logo-dark.svg + alt: Wagmi Logo + +features: + - icon: 🚀 + title: 20+ React Hooks + details: React Hooks for accounts, wallets, contracts, transactions, signing, ENS, and more. + link: /react/api/hooks + linkText: See all hooks + - icon: 🦄 + title: TypeScript Ready + details: Infer types from ABIs and EIP-712 Typed Data and autocomplete your way to productivity. + link: /react/typescript + linkText: Learn about TypeScript support + - icon: 💼 + title: Connect Wallet + details: Official connectors for MetaMask, EIP-6963, WalletConnect, Coinbase Wallet, and more. + link: /react/api/connectors + linkText: See all connectors + - icon: 👟 + title: Caching. Deduplication. Persistence. + details: Built-in caching, deduplication, persistence powered by TanStack Query. + link: /react/guides/tanstack-query + linkText: How to use TanStack Query + - icon: 🌳 + title: Modular By Design + details: Don't use React or Vue? Use VanillaJS or build an adapter for your favorite framework. + link: /core/getting-started + linkText: Learn about Wagmi Core + - icon: ✌️ + title: Built on Viem + details: The modern, low-level TypeScript interface for Ethereum that performs blockchain operations. + link: https://viem.sh + linkText: Check out Viem +--- diff --git a/site/package.json b/site/package.json new file mode 100644 index 0000000000..f032eeab66 --- /dev/null +++ b/site/package.json @@ -0,0 +1,28 @@ +{ + "name": "site", + "private": true, + "type": "module", + "scripts": { + "dev": "vitepress dev", + "build": "vitepress build", + "preview": "vitepress preview" + }, + "devDependencies": { + "@shikijs/vitepress-twoslash": "1.22.2", + "@tanstack/query-core": "catalog:", + "@tanstack/react-query": "catalog:", + "@tanstack/vue-query": "catalog:", + "@types/react": "catalog:", + "@wagmi/connectors": "workspace:*", + "@wagmi/core": "workspace:*", + "@wagmi/vue": "workspace:*", + "abitype": "*", + "nuxt": "^3.19.0", + "react": "catalog:", + "unocss": "^0.59.4", + "viem": "2.*", + "vitepress": "1.5.0", + "vue": "catalog:", + "wagmi": "workspace:*" + } +} diff --git a/site/public/browsers/chrome.png b/site/public/browsers/chrome.png new file mode 100644 index 0000000000..3024356395 Binary files /dev/null and b/site/public/browsers/chrome.png differ diff --git a/site/public/browsers/edge.png b/site/public/browsers/edge.png new file mode 100644 index 0000000000..931cb1c1bf Binary files /dev/null and b/site/public/browsers/edge.png differ diff --git a/site/public/browsers/firefox.png b/site/public/browsers/firefox.png new file mode 100644 index 0000000000..fc7123205a Binary files /dev/null and b/site/public/browsers/firefox.png differ diff --git a/site/public/browsers/opera.png b/site/public/browsers/opera.png new file mode 100644 index 0000000000..472a152348 Binary files /dev/null and b/site/public/browsers/opera.png differ diff --git a/site/public/browsers/safari.png b/site/public/browsers/safari.png new file mode 100644 index 0000000000..aba5f86d1f Binary files /dev/null and b/site/public/browsers/safari.png differ diff --git a/site/public/favicon.svg b/site/public/favicon.svg new file mode 100644 index 0000000000..48c440d660 --- /dev/null +++ b/site/public/favicon.svg @@ -0,0 +1,10 @@ + + + + + + + + + + \ No newline at end of file diff --git a/site/public/logo-dark.svg b/site/public/logo-dark.svg new file mode 100644 index 0000000000..df0c2945ce --- /dev/null +++ b/site/public/logo-dark.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/site/public/logo-light.svg b/site/public/logo-light.svg new file mode 100644 index 0000000000..cc571bc094 --- /dev/null +++ b/site/public/logo-light.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/site/public/og.png b/site/public/og.png new file mode 100644 index 0000000000..8b3a05f556 Binary files /dev/null and b/site/public/og.png differ diff --git a/site/react/api/WagmiProvider.md b/site/react/api/WagmiProvider.md new file mode 100644 index 0000000000..7330f4569b --- /dev/null +++ b/site/react/api/WagmiProvider.md @@ -0,0 +1,112 @@ +# WagmiProvider + +React Context Provider for Wagmi. + +## Import + +```ts +import { WagmiProvider } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [app.tsx] +import { WagmiProvider } from 'wagmi' +import { config } from './config' + +function App() { + return ( + + {/** ... */} + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WagmiProviderProps } from 'wagmi' +``` + +### config + +[`Config`](/react/api/createConfig#config) object to inject with context. + +::: code-group +```tsx [app.tsx] +import { WagmiProvider } from 'wagmi' +import { config } from './config' + +function App() { + return ( + + {/** ... */} + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### initialState + +`State | undefined` + +- Initial state to hydrate into the [Wagmi Config](/react/api/createConfig). Useful for SSR. + +::: code-group +```tsx [app.tsx] +import { WagmiProvider } from 'wagmi' +import { config } from './config' + +function App() { + return ( + + {/** ... */} + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### reconnectOnMount + +`boolean | undefined` + +- Whether or not to reconnect previously connected [connectors](/react/api/createConfig#connectors) on mount. +- Defaults to `true`. + +::: code-group +```tsx [app.tsx] +import { WagmiProvider } from 'wagmi' +import { config } from './config' + +function App() { + return ( + + {/** ... */} + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Context + +```ts +import { type WagmiContext } from 'wagmi' +``` diff --git a/site/react/api/actions.md b/site/react/api/actions.md new file mode 100644 index 0000000000..af367bb025 --- /dev/null +++ b/site/react/api/actions.md @@ -0,0 +1,28 @@ +# Actions + +Sometimes the declarative nature of React Hooks doesn't work for parts of your app. For those cases, you can use Wagmi Core Actions directly! + +All the Wagmi Core Actions are importable using the `wagmi/actions` entrypoint. For example, you can use the `watchBlockNumber` action to watch for block number changes. + +::: code-group +```ts [index.tsx] +import { useConfig } from 'wagmi' +import { watchBlockNumber } from 'wagmi/actions' +import { useEffect } from 'react' + +function App() { + const config = useConfig() + + useEffect(() => { + return watchBlockNumber(config, { + onBlockNumber(blockNumber) { + console.log('Block number changed!', blockNumber) + }, + }) + }, []) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +See the [Wagmi Core docs](/core/api/actions) for more info on what actions are available. diff --git a/site/react/api/chains.md b/site/react/api/chains.md new file mode 100644 index 0000000000..4a7e600447 --- /dev/null +++ b/site/react/api/chains.md @@ -0,0 +1,26 @@ + + +# Chains + +Viem `Chain` objects. More info at the [Viem docs](https://viem.sh/docs/chains/introduction). + +## Import + +Import via the `'wagmi/chains'` entrypoint (proxies all chains from `'viem/chains'`). + +```ts +import { mainnet } from 'wagmi/chains' +``` + +## Available Chains + +Chain definitions as of `viem@{{viemVersion}}`. For `viem@latest`, visit the [Viem repo](https://github.com/wevm/viem/blob/main/src/chains/index.ts). + + + + diff --git a/site/react/api/connectors.md b/site/react/api/connectors.md new file mode 100644 index 0000000000..49096a1641 --- /dev/null +++ b/site/react/api/connectors.md @@ -0,0 +1,28 @@ + + +# Connectors + +Connectors for popular wallet providers and protocols. + +## Import + +Import via the `'wagmi/connectors'` entrypoint. + +```ts +import { injected } from 'wagmi/connectors' +``` + +## Available Connectors + + diff --git a/site/react/api/connectors/coinbaseWallet.md b/site/react/api/connectors/coinbaseWallet.md new file mode 100644 index 0000000000..b8597b11ae --- /dev/null +++ b/site/react/api/connectors/coinbaseWallet.md @@ -0,0 +1,6 @@ + + + \ No newline at end of file diff --git a/site/react/api/connectors/injected.md b/site/react/api/connectors/injected.md new file mode 100644 index 0000000000..56573881f4 --- /dev/null +++ b/site/react/api/connectors/injected.md @@ -0,0 +1,7 @@ + + + diff --git a/site/react/api/connectors/metaMask.md b/site/react/api/connectors/metaMask.md new file mode 100644 index 0000000000..e16d849037 --- /dev/null +++ b/site/react/api/connectors/metaMask.md @@ -0,0 +1,7 @@ + + + diff --git a/site/react/api/connectors/mock.md b/site/react/api/connectors/mock.md new file mode 100644 index 0000000000..3a111297a1 --- /dev/null +++ b/site/react/api/connectors/mock.md @@ -0,0 +1,6 @@ + + + diff --git a/site/react/api/connectors/safe.md b/site/react/api/connectors/safe.md new file mode 100644 index 0000000000..375ddb7b2d --- /dev/null +++ b/site/react/api/connectors/safe.md @@ -0,0 +1,6 @@ + + + diff --git a/site/react/api/connectors/walletConnect.md b/site/react/api/connectors/walletConnect.md new file mode 100644 index 0000000000..3e1a4a5c24 --- /dev/null +++ b/site/react/api/connectors/walletConnect.md @@ -0,0 +1,6 @@ + + + diff --git a/site/react/api/createConfig.md b/site/react/api/createConfig.md new file mode 100644 index 0000000000..f42bec2539 --- /dev/null +++ b/site/react/api/createConfig.md @@ -0,0 +1,7 @@ + + + diff --git a/site/react/api/createStorage.md b/site/react/api/createStorage.md new file mode 100644 index 0000000000..738e998f0b --- /dev/null +++ b/site/react/api/createStorage.md @@ -0,0 +1,6 @@ + + + diff --git a/site/react/api/errors.md b/site/react/api/errors.md new file mode 100644 index 0000000000..d431a6c4fe --- /dev/null +++ b/site/react/api/errors.md @@ -0,0 +1,20 @@ + + +# Errors + +Error classes used by Wagmi. + + + +## React + +### WagmiProviderNotFoundError + +When a Wagmi hook is used outside of a [`WagmiProvider`](/react/api/WagmiProvider). + +```ts +import { WagmiProviderNotFoundError } from 'wagmi' +``` \ No newline at end of file diff --git a/site/react/api/hooks.md b/site/react/api/hooks.md new file mode 100644 index 0000000000..9d8a65c718 --- /dev/null +++ b/site/react/api/hooks.md @@ -0,0 +1,25 @@ + + +# Hooks + +React Hooks for accounts, wallets, contracts, transactions, signing, ENS, and more. + +## Import + +```ts +import { useAccount } from 'wagmi' +``` + +## Available Hooks + + diff --git a/site/react/api/hooks/useAccount.md b/site/react/api/hooks/useAccount.md new file mode 100644 index 0000000000..d5b9e2964c --- /dev/null +++ b/site/react/api/hooks/useAccount.md @@ -0,0 +1,65 @@ +--- +title: useAccount +description: Hook for getting current account. +--- + +# useAccount + +Hook for getting current account. + +## Import + +```ts +import { useAccount } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useAccount } from 'wagmi' + +function App() { + const account = useAccount() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseAccountParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useAccount } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const account = useAccount({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseAccountReturnType } from 'wagmi' +``` + + + +## Action + +- [`getAccount`](/core/api/actions/getAccount) diff --git a/site/react/api/hooks/useAccountEffect.md b/site/react/api/hooks/useAccountEffect.md new file mode 100644 index 0000000000..6636f4bbaa --- /dev/null +++ b/site/react/api/hooks/useAccountEffect.md @@ -0,0 +1,113 @@ +--- +title: useAccountEffect +description: Hook for listening to account lifecycle events. +--- + +# useAccountEffect + +Hook for listening to account lifecycle events. + +## Import + +```ts +import { useAccountEffect } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useAccountEffect } from 'wagmi' + +function App() { + useAccountEffect({ + onConnect(data) { + console.log('Connected!', data) + }, + onDisconnect() { + console.log('Disconnected!') + }, + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseAccountEffectParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useAccountEffect } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + useAccountEffect({ + config, // [!code focus] + onConnect(data) { + console.log('Connected!', data) + }, + onDisconnect() { + console.log('Disconnected!') + }, + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### onConnect + +`` ((data: { address: `0x${string}`; addresses: readonly [`0x${string}`, ...`0x${string}`[]]; chain: Chain | undefined chainId: number; connector: Connector; isReconnected: boolean }) => void) | undefined `` + +Callback that is called when accounts are connected. + +::: code-group +```tsx [index.tsx] +import { useAccountEffect } from 'wagmi' + +function App() { + useAccountEffect({ + onConnect(data) { // [!code focus] + console.log('Connected!', data) // [!code focus] + }, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### onDisconnect + +`(() => void) | undefined` + +Callback that is called when no more accounts are connected. + +::: code-group +```tsx [index.tsx] +import { useAccountEffect } from 'wagmi' + +function App() { + useAccountEffect({ + onDisconnect() { // [!code focus] + console.log('Disconnected!') // [!code focus] + }, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Action + +- [`getAccount`](/core/api/actions/getAccount) +- [`watchAccount`](/core/api/actions/watchAccount) diff --git a/site/react/api/hooks/useBalance.md b/site/react/api/hooks/useBalance.md new file mode 100644 index 0000000000..deddbb720d --- /dev/null +++ b/site/react/api/hooks/useBalance.md @@ -0,0 +1,226 @@ +--- +title: useBalance +description: Hook for fetching native currency or token balance. +--- + + + +# useBalance + +Hook for fetching native currency or token balance. + +## Import + +```ts +import { useBalance } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useBalance } from 'wagmi' + +function App() { + const result = useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseBalanceParameters } from 'wagmi' +``` + +### address + +`Address | undefined` + +Address to get balance for. [`enabled`](#enabled) set to `false` if `address` is `undefined`. + +::: code-group +```tsx [index.tsx] +import { useBalance } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +function App() { + const result = useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get balance at. + +::: code-group +```ts [index.ts] +import { useBalance } from 'wagmi' + +function App() { + const result = useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + blockNumber: 17829139n, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get balance at. + +::: code-group +```ts [index.ts] +import { useBalance } from 'wagmi' + +function App() { + const result = useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + blockTag: 'latest', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useBalance } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] + +function App() { + const result = useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useBalance } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useBalance } from 'wagmi' + +function App() { + const result = useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### token [deprecated](/react/guides/migrate-from-v1-to-v2#deprecated-usebalance-token-parameter) + +`Address | undefined` + +ERC-20 token address to get balance for. + +::: code-group +```ts [index.ts] +import { useBalance } from 'wagmi' + +function App() { + const result = useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + token: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### unit [deprecated](/react/guides/migrate-from-v1-to-v2#deprecated-usebalance-unit-parameter-and-formatted-return-value) + +`'ether' | 'gwei' | 'wei' | number | undefined` + +- Units to use when formatting result. +- Defaults to `'ether'`. + +::: code-group +```ts [index.ts] +import { useBalance } from 'wagmi' + +function App() { + const result = useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + unit: 'ether', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseBalanceReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getBalance`](/core/api/actions/getBalance) diff --git a/site/react/api/hooks/useBlock.md b/site/react/api/hooks/useBlock.md new file mode 100644 index 0000000000..f0962ee4c1 --- /dev/null +++ b/site/react/api/hooks/useBlock.md @@ -0,0 +1,227 @@ +--- +title: useBlock +description: Hook for fetching information about a block at a block number, hash or tag. +--- + + + +# useBlock + +Hook for fetching information about a block at a block number, hash or tag. + +## Import + +```ts +import { useBlock } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' + +function App() { + const result = useBlock() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseBlockParameters } from 'wagmi' +``` + +### blockHash + +`` `0x${string}` `` + +Information at a given block hash. + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' + +function App() { + const result = useBlock({ + blockHash: '0x89644bbd5c8d682a2e9611170e6c1f02573d866d286f006cbf517eec7254ec2d' // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`` bigint `` + +Information at a given block number. + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' + +function App() { + const result = useBlock({ + blockNumber: 42069n // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`` 'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' `` + +Information at a given block tag. Defaults to `'latest'`. + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' + +function App() { + const result = useBlock({ + blockTag: 'pending' // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] + +function App() { + const result = useBlock({ + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useBlock({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### includeTransactions + +`boolean` + +Whether or not to include transactions as objects. + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' +import { config } from './config' + +function App() { + const result = useBlock({ + includeTransactions: true // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' +import { config } from './config' + +function App() { + const result = useBlock({ + scopeKey: 'foo' // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### watch + +`boolean | UseWatchBlockParameters | undefined` + +- Enables/disables listening for block changes. +- Can pass a subset of [`UseWatchBlocksParameters`](/react/api/hooks/useWatchBlocks#parameters) directly to [`useWatchBlocks`](/react/api/hooks/useWatchBlocks). + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' + +function App() { + const result = useBlock({ + watch: true, // [!code focus] + }) +} +``` + +```tsx [index-2.tsx] +import { useBlock } from 'wagmi' + +function App() { + const result = useBlock({ + watch: { // [!code focus] + pollingInterval: 4_000, // [!code focus] + }, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseBlockReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getBlock`](/core/api/actions/getBlock) +- [`watchBlockNumber`](/core/api/actions/watchBlockNumber) diff --git a/site/react/api/hooks/useBlockNumber.md b/site/react/api/hooks/useBlockNumber.md new file mode 100644 index 0000000000..e0c6ff7242 --- /dev/null +++ b/site/react/api/hooks/useBlockNumber.md @@ -0,0 +1,169 @@ +--- +title: useBlockNumber +description: Hook for fetching the number of the most recent block seen. +--- + + + +# useBlockNumber + +Hook for fetching the number of the most recent block seen. + +## Import + +```ts +import { useBlockNumber } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useBlockNumber } from 'wagmi' + +function App() { + const result = useBlockNumber() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseBlockNumberParameters } from 'wagmi' +``` + +### cacheTime + +`number | undefined` + +Time in milliseconds that cached block number will remain in memory. + +::: code-group +```tsx [index.tsx] +import { useBlockNumber } from 'wagmi' + +function App() { + const result = useBlockNumber({ + cacheTime: 4_000, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useBlockNumber } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] + +function App() { + const result = useBlockNumber({ + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useBlockNumber } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useBlockNumber({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useBlockNumber } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useBlockNumber({ + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### watch + +`boolean | UseWatchBlockNumberParameters | undefined` + +- Enables/disables listening for block number changes. +- Can pass a subset of [`UseWatchBlockNumberParameters`](/react/api/hooks/useWatchBlockNumber#parameters)directly to [`useWatchBlockNumber`](/react/api/hooks/useWatchBlockNumber). + +::: code-group +```tsx [index.tsx] +import { useBlockNumber } from 'wagmi' + +function App() { + const result = useBlockNumber({ + watch: true, // [!code focus] + }) +} +``` + +```tsx [index-2.tsx] +import { useBlockNumber } from 'wagmi' + +function App() { + const result = useBlockNumber({ + watch: { // [!code focus] + pollingInterval: 4_000, // [!code focus] + }, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseBlockNumberReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getBlockNumber`](/core/api/actions/getBlockNumber) +- [`watchBlockNumber`](/core/api/actions/watchBlockNumber) diff --git a/site/react/api/hooks/useBlockTransactionCount.md b/site/react/api/hooks/useBlockTransactionCount.md new file mode 100644 index 0000000000..80cb99de32 --- /dev/null +++ b/site/react/api/hooks/useBlockTransactionCount.md @@ -0,0 +1,175 @@ +--- +title: useBlockTransactionCount +description: Hook for fetching the number of Transactions at a block number, hash or tag. +--- + + + +# useBlockTransactionCount + +Hook for fetching the number of Transactions at a block number, hash or tag. + +## Import + +```ts +import { useBlockTransactionCount } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useBlockTransactionCount } from 'wagmi' + +function App() { + const result = useBlockTransactionCount() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseBlockTransactionCountParameters } from 'wagmi' +``` + +### blockHash + +`` `0x${string}` `` + +Transaction count at a given block hash. + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' + +function App() { + const result = useBlock({ + blockHash: '0x89644bbd5c8d682a2e9611170e6c1f02573d866d286f006cbf517eec7254ec2d' // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`` bigint `` + +Transaction count at a given block number. + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' + +function App() { + const result = useBlock({ + blockNumber: 42069n // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`` 'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' `` + +Transaction count at a given block tag. Defaults to `'latest'`. + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' + +function App() { + const result = useBlock({ + blockTag: 'pending' // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] + +function App() { + const result = useBlock({ + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useBlockTransactionCount } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useBlockTransactionCount({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useBlockTransactionCount } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useBlockTransactionCount({ + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + + +## Return Type + +```ts +import { type UseBlockTransactionCountReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getBlockTransactionCount`](/core/api/actions/getBlockTransactionCount) diff --git a/site/react/api/hooks/useBytecode.md b/site/react/api/hooks/useBytecode.md new file mode 100644 index 0000000000..573cee32c0 --- /dev/null +++ b/site/react/api/hooks/useBytecode.md @@ -0,0 +1,181 @@ +--- +title: useBytecode +description: Hook for retrieving the bytecode at an address. +--- + + + +# useBytecode + +Hook for retrieving the bytecode at an address. + +## Import + +```ts +import { useBytecode } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useBytecode } from 'wagmi' + +function App() { + const result = useBytecode({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseBytecodeParameters } from 'wagmi' +``` + +### address + +`Address | undefined` + +The contract address. + +::: code-group +```tsx [index.tsx] +import { useBytecode } from 'wagmi' + +function App() { + const result = useBytecode({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +The block number to check the bytecode at. + +::: code-group +```tsx [index.tsx] +import { useBytecode } from 'wagmi' + +function App() { + const result = useBytecode({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + blockNumber: 16280770n, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +The block tag to check the bytecode at. + +::: code-group +```tsx [index.tsx] +import { useBytecode } from 'wagmi' + +function App() { + const result = useBytecode({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + blockTag: 'safe', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +The chain ID to check the bytecode at. + +::: code-group +```tsx [index.tsx] +import { useBytecode } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +function App() { + const result = useBytecode({ + chainId: mainnet.id, // [!code focus] + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useBytecode } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useBytecode({ + config, // [!code focus] + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useBytecode } from 'wagmi' +import { config } from './config' + +function App() { + const result = useBytecode({ + scopeKey: 'foo' // [!code focus] + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseBytecodeReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getBytecode`](/core/api/actions/getBytecode) diff --git a/site/react/api/hooks/useCall.md b/site/react/api/hooks/useCall.md new file mode 100644 index 0000000000..9bc2250cf2 --- /dev/null +++ b/site/react/api/hooks/useCall.md @@ -0,0 +1,397 @@ +--- +title: useCall +description: Hook for executing a new message call immediately without submitting a transaction to the network. +--- + + + +# useCall + +Hook for executing a new message call immediately without submitting a transaction to the network. + +## Import + +```ts +import { useCall } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseCallParameters } from 'wagmi' +``` + +### account + +`Account | Address | undefined` + +The Account to call from. + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', // [!code focus] + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### data + +`0x${string} | undefined` + +A contract hashed method call with encoded args. + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### to + +`Address | undefined` + +The contract address or recipient. + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### accessList + +`AccessList | undefined` + +The access list. + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + accessList: [ // [!code focus:6] + { + address: '0x1', + storageKeys: ['0x1'], + }, + ], + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### gas + +`bigint | undefined` + +The gas provided for transaction execution. + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + gas: 1_000_000n, // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### gasPrice + +`bigint | undefined` + +The price (in wei) to pay per gas. Only applies to [Legacy Transactions](https://viem.sh/docs/glossary/terms.html#legacy-transaction). + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + gasPrice: parseGwei('20'), // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### maxFeePerGas + +`bigint | undefined` + +Total fee per gas (in wei), inclusive of `maxPriorityFeePerGas`. Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + maxFeePerGas: parseGwei('20'), // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### maxPriorityFeePerGas + +`bigint | undefined` + +Max priority fee per gas (in wei). Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + maxFeePerGas: parseGwei('20'), + maxPriorityFeePerGas: parseGwei('2'), // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### nonce + +`number | undefined` + +Unique number identifying this transaction. + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + nonce: 420, // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### value + +`bigint | undefined` + +Value (in wei) sent with this transaction. + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`number | undefined` + +The block number to perform the call against. + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + blockNumber: 15121123n, // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +The block tag to perform the call against. + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' + +function App() { + const result = useCall({ + blockTag: 'safe', // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +The block tag to perform the call against. + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' +import { mainnet } from '@wagmi/core/chains' + +function App() { + const result = useCall({ + chainId: mainnet.id, // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useCall({ + config, // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useCall } from 'wagmi' +import { config } from './config' + +function App() { + const result = useCall({ + scopeKey: 'foo' // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseCallReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`call`](/core/api/actions/call) diff --git a/site/react/api/hooks/useCallsStatus.md b/site/react/api/hooks/useCallsStatus.md new file mode 100644 index 0000000000..48135c53eb --- /dev/null +++ b/site/react/api/hooks/useCallsStatus.md @@ -0,0 +1,143 @@ +--- +title: useCallsStatus +description: Hook for fetching the number of the most recent block seen. +--- + + + +# useCallsStatus + +Hook to fetch the status and receipts of a call batch that was sent via [`useSendCalls`](/react/api/hooks/useSendCalls). + + + +## Import + +```ts +import { useCallsStatus } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useCallsStatus } from 'wagmi' + +function App() { + const result = useCallsStatus({ + id: '0x...', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseCallsStatusParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useCallsStatus } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useCallsStatus({ + config, // [!code focus] + id: '0x...', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +Connector to get call statuses with. + +::: code-group +```tsx [index.tsx] +import { useCallsStatus, useConnections } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const connections = useConnections() + const result = useCallsStatus({ + connector: connections[0]?.connector, // [!code focus] + id: '0x...', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### id + +`string` + +Identifier of the call batch. + +::: code-group +```ts [index.ts] +import { useCallsStatus } from '@wagmi/core' +import { config } from './config' + +const status = await useCallsStatus({ + id: '0x1234567890abcdef', // [!code focus] +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useCallsStatus } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useCallsStatus({ + id: '0x...', + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseCallsStatusReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getCallsStatus`](https://viem.sh/experimental/eip5792/getCallsStatus) \ No newline at end of file diff --git a/site/react/api/hooks/useCapabilities.md b/site/react/api/hooks/useCapabilities.md new file mode 100644 index 0000000000..d9d6fc74a7 --- /dev/null +++ b/site/react/api/hooks/useCapabilities.md @@ -0,0 +1,138 @@ +--- +title: useCapabilities +description: Hook for fetching the number of the most recent block seen. +--- + + + +# useCapabilities + +Hook to extract capabilities (grouped by chain ID) that a connected wallet supports (e.g. paymasters, session keys, etc). + +[Read more.](https://github.com/ethereum/EIPs/blob/815028dc634463e1716fc5ce44c019a6040f0bef/EIPS/eip-5792.md#wallet_getcapabilities) + +## Import + +```ts +import { useCapabilities } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useCapabilities } from 'wagmi' + +function App() { + const result = useCapabilities() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseCapabilitiesParameters } from 'wagmi' +``` + +### account + +`Account | Address | undefined` + +Fetch capabilities for the provided account. + +::: code-group +```ts [index.ts] +import { useCapabilities } from '@wagmi/core' +import { config } from './config' + +const status = await useCapabilities({ + account: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', // [!code focus] +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useCapabilities } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useCapabilities({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +Connector to get call statuses with. + +::: code-group +```tsx [index.tsx] +import { useCapabilities, useConnections } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const connections = useConnections() + const result = useCapabilities({ + connector: connections[0]?.connector, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useCapabilities } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useCapabilities({ + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseCapabilitiesReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getCapabilities`](https://viem.sh/experimental/eip5792/getCapabilities) \ No newline at end of file diff --git a/site/react/api/hooks/useChainId.md b/site/react/api/hooks/useChainId.md new file mode 100644 index 0000000000..509f5a1e4c --- /dev/null +++ b/site/react/api/hooks/useChainId.md @@ -0,0 +1,74 @@ +--- +title: useChainId +description: Hook for getting current chain ID. +--- + +# useChainId + +Hook for getting current chain ID. + +## Import + +```ts +import { useChainId } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useChainId } from 'wagmi' + +function App() { + const chainId = useChainId() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseChainIdParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useChainId } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const chainId = useChainId({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseChainIdReturnType } from 'wagmi' +``` + +`number` + +Current chain ID from [`config.state.chainId`](/react/api/createConfig#chainid). + +::: info +Only returns chain IDs for chains configured via `createConfig`'s [`chains`](/react/api/createConfig#chains) parameter. + +If the active [connection](/react/api/createConfig#connection) [`chainId`](/react/api/createConfig#chainid-1) is not from a chain included in your Wagmi `Config`, `useChainId` will return the last configured chain ID. +::: + +## Action + +- [`getChainId`](/core/api/actions/getChainId) +- [`watchChainId`](/core/api/actions/watchChainId) diff --git a/site/react/api/hooks/useChains.md b/site/react/api/hooks/useChains.md new file mode 100644 index 0000000000..286f794276 --- /dev/null +++ b/site/react/api/hooks/useChains.md @@ -0,0 +1,67 @@ +--- +title: useChains +description: Hook for getting configured chains +--- + +# useChains + +Hook for getting configured chains + +## Import + +```ts +import { useChains } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useChains } from 'wagmi' + +function App() { + const chains = useChains() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseChainsParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useChains } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const chains = useChains({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseChainsReturnType } from 'wagmi' +``` + +`readonly [Chain, ...Chain[]]` + +Chains from [`config.chains`](/react/api/createConfig#chains). + +## Action + +- [`getChains`](/core/api/actions/getChains) diff --git a/site/react/api/hooks/useClient.md b/site/react/api/hooks/useClient.md new file mode 100644 index 0000000000..fc87a15e47 --- /dev/null +++ b/site/react/api/hooks/useClient.md @@ -0,0 +1,89 @@ +--- +title: useClient +description: Hook for getting Viem `Client` instance. +--- + +# useClient + +Hook for getting Viem [`Client`](https://viem.sh/docs/clients/custom.html) instance. + +## Import + +```ts +import { useClient } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useClient } from 'wagmi' + +function App() { + const client = useClient() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseClientParameters } from 'wagmi' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when getting Viem Client. + +::: code-group +```ts [index.ts] +import { useClient } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] +import { config } from './config' + +function App() { + const client = useClient({ + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useClient } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const client = useClient({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseClientReturnType } from 'wagmi' +``` + +`Client | undefined` + +Viem [`Client`](https://viem.sh/docs/clients/custom.html) instance. + +## Action + +- [`getClient`](/core/api/actions/getClient) +- [`watchClient`](/core/api/actions/watchClient) diff --git a/site/react/api/hooks/useConfig.md b/site/react/api/hooks/useConfig.md new file mode 100644 index 0000000000..6f70b6e821 --- /dev/null +++ b/site/react/api/hooks/useConfig.md @@ -0,0 +1,75 @@ +--- +title: useConfig +description: Hook for getting `Config` from nearest `WagmiProvider`. +--- + +# useConfig + +Hook for getting [`Config`](/react/api/createConfig#config) from nearest [`WagmiProvider`](/react/api/WagmiProvider). + +## Import + +```ts +import { useConfig } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useConfig } from 'wagmi' + +function App() { + const config = useConfig() +} +``` + +::: + +## Return Type + +```ts +import { type UseConfigReturnType } from 'wagmi' +``` + +If you use TypeScript and [register your `Config`](/react/typescript#register-config), the return type will be inferred. + +::: code-group +```ts twoslash [index.tsx] +import { type Config } from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' + +declare module 'wagmi' { + interface Register { + config: Config + } +} +// ---cut--- +import { useConfig } from 'wagmi' + +function App() { + const config = useConfig() + // ^? +} +``` + +```ts [config.ts] +import { createConfig, http } from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' + +declare module 'wagmi' { + interface Register { + config: typeof config + } +} + +export const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +::: diff --git a/site/react/api/hooks/useConnect.md b/site/react/api/hooks/useConnect.md new file mode 100644 index 0000000000..ba52ee2aaf --- /dev/null +++ b/site/react/api/hooks/useConnect.md @@ -0,0 +1,117 @@ +--- +title: useConnect +description: Hook for connecting accounts with connectors. +--- + + + +# useConnect + +Hook for connecting accounts with [connectors](/react/api/connectors). + +## Import + +```ts +import { useConnect } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useConnect } from 'wagmi' +import { injected } from 'wagmi/connectors' + +function App() { + const { connect } = useConnect() + + return ( + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseConnectParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useConnect } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useConnect({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseConnectReturnType } from 'wagmi' +``` + +### connectors + +`readonly Connector[]` + +Globally configured connectors via [`createConfig`](/react/api/createConfig#connectors). Useful for rendering a list of available connectors. + +::: code-group +```tsx [index.tsx] +import { useConnect } from 'wagmi' + +function App() { + const { connect, connectors } = useConnect() + + return ( +
+ {connectors.map((connector) => ( + + ))} +
+ ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +::: tip +Not all connectors support connecting directly to a `chainId` (e.g. they don't support programmatic chain switching). In those cases, the connector will connect to whatever chain the connector's provider (e.g. wallet) is connected to. +::: + + + +## Action + +- [`connect`](/core/api/actions/connect) diff --git a/site/react/api/hooks/useConnections.md b/site/react/api/hooks/useConnections.md new file mode 100644 index 0000000000..f6f18b14fa --- /dev/null +++ b/site/react/api/hooks/useConnections.md @@ -0,0 +1,64 @@ +--- +title: useConnections +description: Hook for getting active connections. +--- + +# useConnections + +Hook for getting active connections. + +## Import + +```ts +import { useConnections } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useConnections } from 'wagmi' + +function App() { + const connections = useConnections() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseConnectionsParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useConnections } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const connections = useConnections({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseConnectionsReturnType } from 'wagmi' +``` + +## Action + +- [`getConnections`](/core/api/actions/getConnections) +- [`watchConnections`](/core/api/actions/watchConnections) diff --git a/site/react/api/hooks/useConnectorClient.md b/site/react/api/hooks/useConnectorClient.md new file mode 100644 index 0000000000..60aa74b77d --- /dev/null +++ b/site/react/api/hooks/useConnectorClient.md @@ -0,0 +1,128 @@ +--- +title: useConnectorClient +description: Hook for getting a Viem `Client` object for the current or provided connector. +--- + + + +# useConnectorClient + +Hook for getting a Viem [`Client`](https://viem.sh/docs/clients/custom.html) object for the current or provided connector. + +## Import + +```ts +import { useConnectorClient } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useConnectorClient } from 'wagmi' + +function App() { + const result = useConnectorClient() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseConnectorClientParameters } from 'wagmi' +``` + +### account + +`Address | Account | undefined` + +Account to use with client. Throws if account is not found on [`connector`](#connector). + +```ts +import { useConnectorClient } from 'wagmi' + +function App() { + const result = useConnectorClient({ + account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + }) +} +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use with client. + +```ts +import { useConnectorClient } from 'wagmi' + +function App() { + const result = useConnectorClient({ + chainId: mainnet.id, // [!code focus] + }) +} +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useConnectorClient } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useConnectorClient({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +- Connector to get client for. +- Defaults to current connector. + +```ts +import { useConnections, useConnectorClient } from 'wagmi' + +function App() { + const connections = useConnections(config) + const result = useConnectorClient({ + connector: connections[0]?.connector, // [!code focus] + }) +} +``` + + + +## Return Type + +```ts +import { type UseConnectorClientReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getConnectorClient`](/core/api/actions/getConnectorClient) diff --git a/site/react/api/hooks/useConnectors.md b/site/react/api/hooks/useConnectors.md new file mode 100644 index 0000000000..f02e2dfd2f --- /dev/null +++ b/site/react/api/hooks/useConnectors.md @@ -0,0 +1,41 @@ +--- +title: useConnectors +description: Hook for getting configured connectors. +--- + +# useConnectors + +Hook for getting configured connectors. + +## Import + +```ts +import { useConnectors } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useConnectors } from 'wagmi' + +function App() { + const connectors = useConnectors() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseConnectorsReturnType } from 'wagmi' +``` + +`readonly Connector[]` + +Connectors from [`config.connectors`](/react/api/createConfig#connectors-1). + +## Action + +- [`getConnectors`](/core/api/actions/getConnectors) diff --git a/site/react/api/hooks/useDeployContract.md b/site/react/api/hooks/useDeployContract.md new file mode 100644 index 0000000000..42b2e9ffe3 --- /dev/null +++ b/site/react/api/hooks/useDeployContract.md @@ -0,0 +1,145 @@ +--- +title: useDeployContract +description: Hook for deploying a contract to the network, given bytecode & constructor arguments. +--- + + + +# useDeployContract + +Hook for deploying a contract to the network, given bytecode, and constructor arguments. + +## Import + +```ts +import { useDeployContract } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useDeployContract } from 'wagmi' +import { parseEther } from 'viem' +import { wagmiAbi } from './abi' + +function App() { + const { deployContract } = useDeployContract() + + return ( + + ) +} +``` +```ts [abi.ts] +export const wagmiAbi = [ + ... + { + inputs: [], + stateMutability: "nonpayable", + type: "constructor", + }, + ... +] as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Deploying with Constructor Args + +::: code-group +```tsx [index.tsx] +import { useDeployContract } from 'wagmi' +import { parseEther } from 'viem' +import { wagmiAbi } from './abi' + +function App() { + const { deployContract } = useDeployContract() + + return ( + + ) +} +``` +```ts [abi.ts] +export const wagmiAbi = [ + ... + { + inputs: [{ name: "x", type: "uint32" }], + stateMutability: "nonpayable", + type: "constructor", + }, + ... +] as const; +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type useDeployContractParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useDeployContract } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useDeployContract({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type useDeployContractReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`deployContract`](/core/api/actions/deployContract) diff --git a/site/react/api/hooks/useDisconnect.md b/site/react/api/hooks/useDisconnect.md new file mode 100644 index 0000000000..5e537a846d --- /dev/null +++ b/site/react/api/hooks/useDisconnect.md @@ -0,0 +1,113 @@ +--- +title: useDisconnect +description: Hook for disconnecting connections. +--- + + + +# useDisconnect + +Hook for disconnecting connections. + +## Import + +```ts +import { useDisconnect } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useDisconnect } from 'wagmi' + +function App() { + const { disconnect } = useDisconnect() + + return ( + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseDisconnectParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useDisconnect } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useDisconnect({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseDisconnectReturnType } from 'wagmi' +``` + +### connectors + +`readonly Connector[]` + +Connectors that are currently connected. Useful for rendering a list of connectors to disconnect. + +::: code-group +```tsx [index.tsx] +import { useDisconnect } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +function App() { + const { connectors, disconnect } = useDisconnect() + + return ( +
+ {connectors.map((connector) => ( + + ))} +
+ ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + + + +## Action + +- [`disconnect`](/core/api/actions/disconnect) diff --git a/site/react/api/hooks/useEnsAddress.md b/site/react/api/hooks/useEnsAddress.md new file mode 100644 index 0000000000..b4807384f1 --- /dev/null +++ b/site/react/api/hooks/useEnsAddress.md @@ -0,0 +1,238 @@ +--- +title: useEnsAddress +description: Hook for fetching ENS address for name. +--- + + + +# useEnsAddress + +Hook for fetching ENS address for name. + +## Import + +```ts +import { useEnsAddress } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useEnsAddress } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAddress({ + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +::: warning +Since ENS names prohibit certain forbidden characters (e.g. underscore) and have other validation rules, you likely want to [normalize ENS names](https://docs.ens.domains/contract-api-reference/name-processing#normalising-names) with [UTS-46 normalization](https://unicode.org/reports/tr46) before passing them to `useEnsAddress`. You can use Viem's built-in [`normalize`](https://viem.sh/docs/ens/utilities/normalize) function for this. +::: + +## Parameters + +```ts +import { type UseEnsAddressParameters } from 'wagmi' +``` + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get ENS address at. + +::: code-group +```ts [index.ts] +import { useEnsAddress } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAddress({ + blockNumber: 17829139n, // [!code focus] + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get ENS address at. + +::: code-group +```ts [index.ts] +import { useEnsAddress } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAddress({ + name: normalize('wevm.eth'), + blockTag: 'latest', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useEnsAddress } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAddress({ + chainId: mainnet.id, // [!code focus] + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### coinType + +`number | undefined` + +The [ENSIP-9](https://docs.ens.domains/ens-improvement-proposals/ensip-9-multichain-address-resolution) coin type to fetch the address for. + +::: code-group +```ts [index.ts] +import { useEnsAddress } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAddress({ + coinType: 60, // [!code focus] + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useEnsAddress } from 'wagmi' +import { normalize } from 'viem/ens' +import { config } from './config' // [!code focus] + +function App() { + const result = useEnsAddress({ + config, // [!code focus] + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### name + +`string | undefined` + +Name to get the address for. [`enabled`](#enabled) set to `false` if `name` is `undefined`. + +::: code-group +```ts [index.ts] +import { useEnsAddress } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAddress({ + name: normalize('wevm.eth'), // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```ts [index.ts] +import { useEnsAddress } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAddress({ + name: normalize('wevm.eth'), + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Address of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```ts [index.ts] +import { useEnsAddress } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAddress({ + name: normalize('wevm.eth'), + universalResolverAddress: '0x74E20Bd2A1fE0cdbe45b9A1d89cb7e0a45b36376', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseEnsAddressReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getEnsAddress`](/core/api/actions/getEnsAddress) diff --git a/site/react/api/hooks/useEnsAvatar.md b/site/react/api/hooks/useEnsAvatar.md new file mode 100644 index 0000000000..ec09af5e31 --- /dev/null +++ b/site/react/api/hooks/useEnsAvatar.md @@ -0,0 +1,262 @@ +--- +title: useEnsAvatar +description: Hook for fetching ENS avatar for name. +--- + + + +# useEnsAvatar + +Hook for fetching ENS avatar for name. + +## Import + +```ts +import { useEnsAvatar } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useEnsAvatar } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAvatar({ + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +::: warning +Since ENS names prohibit certain forbidden characters (e.g. underscore) and have other validation rules, you likely want to [normalize ENS names](https://docs.ens.domains/contract-api-reference/name-processing#normalising-names) with [UTS-46 normalization](https://unicode.org/reports/tr46) before passing them to `useEnsAvatar`. You can use Viem's built-in [`normalize`](https://viem.sh/docs/ens/utilities/normalize) function for this. +::: + +## Parameters + +```ts +import { type UseEnsAvatarParameters } from 'wagmi' +``` + +--- + +### assetGatewayUrls + +`{ ipfs?: string | undefined; arweave?: string | undefined } | undefined` + +Gateway urls to resolve IPFS and/or Arweave assets. + +::: code-group +```ts [index.ts] +import { getEnsAvatar } from '@wagmi/core' +import { normalize } from 'viem/ens' +import { config } from './config' + +function App() { + const result = useEnsAvatar({ + assetGatewayUrls: { // [!code focus] + ipfs: 'https://cloudflare-ipfs.com', // [!code focus] + }, // [!code focus] + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +Block number to get ENS avatar at. + +::: code-group +```ts [index.ts] +import { useEnsAvatar } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAvatar({ + blockNumber: 17829139n, // [!code focus] + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get ENS avatar at. + +::: code-group +```ts [index.ts] +import { useEnsAvatar } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAvatar({ + name: normalize('wevm.eth'), + blockTag: 'latest', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useEnsAvatar } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAvatar({ + chainId: mainnet.id, // [!code focus], + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useEnsAvatar } from 'wagmi' +import { normalize } from 'viem/ens' +import { config } from './config' // [!code focus] + +function App() { + const result = useEnsAvatar({ + config, // [!code focus] + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### gatewayUrls + +`string[] | undefined` + +A set of Universal Resolver gateways, used for resolving CCIP-Read requests made through the ENS Universal Resolver Contract. + +::: code-group +```ts [index.ts] +import { useEnsAvatar } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAvatar({ + gatewayUrls: ['https://cloudflare-ipfs.com'] { // [!code focus] + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### name + +`string | undefined` + +Name to get the avatar for. [`enabled`](#enabled) set to `false` if `name` is `undefined`. + +::: code-group +```ts [index.ts] +import { useEnsAvatar } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAvatar({ + name: normalize('wevm.eth'), // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```ts [index.ts] +import { useEnsAvatar } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAvatar({ + name: normalize('wevm.eth'), + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Address of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```ts [index.ts] +import { useEnsAvatar } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsAvatar({ + name: normalize('wevm.eth'), + universalResolverAddress: '0x74E20Bd2A1fE0cdbe45b9A1d89cb7e0a45b36376', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseEnsAvatarReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getEnsAvatar`](/core/api/actions/getEnsAvatar) diff --git a/site/react/api/hooks/useEnsName.md b/site/react/api/hooks/useEnsName.md new file mode 100644 index 0000000000..71d128b1bf --- /dev/null +++ b/site/react/api/hooks/useEnsName.md @@ -0,0 +1,206 @@ +--- +title: useEnsName +description: Hook for fetching primary ENS name for address. +--- + + + +# useEnsName + +Hook for fetching primary ENS name for address. + +## Import + +```ts +import { useEnsName } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useEnsName } from 'wagmi' + +function App() { + const result = useEnsName({ + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseEnsNameParameters } from 'wagmi' +``` + +### address + +`Address | undefined` + +Name to get the resolver for. [`enabled`](#enabled) set to `false` if `address` is `undefined`. + +::: code-group +```ts [index.ts] +import { useEnsName } from 'wagmi' + +function App() { + const result = useEnsName({ + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get ENS name at. + +::: code-group +```ts [index.ts] +import { useEnsName } from 'wagmi' + +function App() { + const result = useEnsName({ + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + blockNumber: 17829139n, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get ENS name at. + +::: code-group +```ts [index.ts] +import { useEnsName } from 'wagmi' + +function App() { + const result = useEnsName({ + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + blockTag: 'latest', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useEnsName } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] + +function App() { + const result = useEnsName({ + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useEnsName } from 'wagmi' +import { normalize } from 'viem/ens' +import { config } from './config' // [!code focus] + +function App() { + const result = useEnsName({ + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```ts [index.ts] +import { useEnsName } from 'wagmi' + +function App() { + const result = useEnsName({ + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Address of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```ts [index.ts] +import { useEnsName } from 'wagmi' + +function App() { + const result = useEnsName({ + address: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + universalResolverAddress: '0x74E20Bd2A1fE0cdbe45b9A1d89cb7e0a45b36376', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseEnsNameReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getEnsName`](/core/api/actions/getEnsName) diff --git a/site/react/api/hooks/useEnsResolver.md b/site/react/api/hooks/useEnsResolver.md new file mode 100644 index 0000000000..b66e17fa03 --- /dev/null +++ b/site/react/api/hooks/useEnsResolver.md @@ -0,0 +1,217 @@ +--- +title: useEnsResolver +description: Hook for fetching ENS resolver for name. +--- + + + +# useEnsResolver + +Hook for fetching ENS resolver for name. + +## Import + +```ts +import { useEnsResolver } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useEnsResolver } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsResolver({ + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +::: warning +Since ENS names prohibit certain forbidden characters (e.g. underscore) and have other validation rules, you likely want to [normalize ENS names](https://docs.ens.domains/contract-api-reference/name-processing#normalising-names) with [UTS-46 normalization](https://unicode.org/reports/tr46) before passing them to `useEnsResolver`. You can use Viem's built-in [`normalize`](https://viem.sh/docs/ens/utilities/normalize) function for this. +::: + +## Parameters + +```ts +import { type UseEnsResolverParameters } from 'wagmi' +``` + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get ENS resolver at. + +::: code-group +```ts [index.ts] +import { useEnsResolver } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsResolver({ + blockNumber: 17829139n, // [!code focus] + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get ENS resolver at. + +::: code-group +```ts [index.ts] +import { useEnsResolver } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsResolver({ + name: normalize('wevm.eth'), + blockTag: 'latest', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useEnsResolver } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsResolver({ + chainId: mainnet.id, // [!code focus] + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useEnsResolver } from 'wagmi' +import { normalize } from 'viem/ens' +import { config } from './config' // [!code focus] + +function App() { + const result = useEnsResolver({ + config, // [!code focus] + name: normalize('wevm.eth'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### name + +`string | undefined` + +Name to get the resolver for. [`enabled`](#enabled) set to `false` if `name` is `undefined`. + +::: code-group +```ts [index.ts] +import { useEnsResolver } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsResolver({ + name: normalize('wevm.eth'), // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```ts [index.ts] +import { useEnsResolver } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsResolver({ + name: normalize('wevm.eth'), + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Resolver of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```ts [index.ts] +import { useEnsResolver } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsResolver({ + name: normalize('wevm.eth'), + universalResolverAddress: '0x74E20Bd2A1fE0cdbe45b9A1d89cb7e0a45b36376', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseEnsResolverReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getEnsResolver`](/core/api/actions/getEnsResolver) diff --git a/site/react/api/hooks/useEnsText.md b/site/react/api/hooks/useEnsText.md new file mode 100644 index 0000000000..769bae66ce --- /dev/null +++ b/site/react/api/hooks/useEnsText.md @@ -0,0 +1,247 @@ +--- +title: useEnsText +description: Hook for fetching a text record for a specified ENS name and key. +--- + + + +# useEnsText + +Hook for fetching a text record for a specified ENS name and key. + +## Import + +```ts +import { useEnsText } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useEnsText } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsText({ + name: normalize('wevm.eth'), + key: 'com.twitter', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +::: warning +Since ENS names prohibit certain forbidden characters (e.g. underscore) and have other validation rules, you likely want to [normalize ENS names](https://docs.ens.domains/contract-api-reference/name-processing#normalising-names) with [UTS-46 normalization](https://unicode.org/reports/tr46) before passing them to `useEnsText`. You can use Viem's built-in [`normalize`](https://viem.sh/docs/ens/utilities/normalize) function for this. +::: + +## Parameters + +```ts +import { type UseEnsTextParameters } from 'wagmi' +``` + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get the text at. + +::: code-group +```ts [index.ts] +import { useEnsText } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsText({ + blockNumber: 17829139n, // [!code focus] + name: normalize('wevm.eth'), + key: 'com.twitter', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get the text at. + +::: code-group +```ts [index.ts] +import { useEnsText } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsText({ + blockTag: 'latest', // [!code focus] + name: normalize('wevm.eth'), + key: 'com.twitter', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useEnsText } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsText({ + chainId: mainnet.id, // [!code focus] + name: normalize('wevm.eth'), + key: 'com.twitter', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### key + +`string | undefined` + +ENS key to get Text for. + +::: code-group +```ts [index.ts] +import { useEnsText } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsText({ + name: normalize('wevm.eth'), + key: 'com.twitter', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + +### name + +`string | undefined` + +Name to get the text for. [`enabled`](#enabled) set to `false` if `name` is `undefined`. + +::: code-group +```ts [index.ts] +import { useEnsText } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsText({ + name: normalize('wevm.eth'), // [!code focus] + key: 'com.twitter', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useEnsText } from 'wagmi' +import { normalize } from 'viem/ens' +import { config } from './config' // [!code focus] + +function App() { + const result = useEnsText({ + config, // [!code focus] + name: normalize('wevm.eth'), + key: 'com.twitter', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```ts [index.ts] +import { useEnsText } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsText({ + scopeKey: 'foo', // [!code focus] + name: normalize('wevm.eth'), + key: 'com.twitter', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Resolver of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```ts [index.ts] +import { useEnsText } from 'wagmi' +import { normalize } from 'viem/ens' + +function App() { + const result = useEnsText({ + name: normalize('wevm.eth'), + key: 'com.twitter', + universalResolverAddress: '0x74E20Bd2A1fE0cdbe45b9A1d89cb7e0a45b36376', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseEnsTextReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getEnsText`](/core/api/actions/getEnsText) diff --git a/site/react/api/hooks/useEstimateFeesPerGas.md b/site/react/api/hooks/useEstimateFeesPerGas.md new file mode 100644 index 0000000000..29b8711673 --- /dev/null +++ b/site/react/api/hooks/useEstimateFeesPerGas.md @@ -0,0 +1,155 @@ +--- +title: useEstimateFeesPerGas +description: Hook for fetching an estimate for the fees per gas (in wei) for a transaction to be likely included in the next block. +--- + + + +# useEstimateFeesPerGas + +Hook for fetching an estimate for the fees per gas (in wei) for a transaction to be likely included in the next block. + +## Import + +```ts +import { useEstimateFeesPerGas } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useEstimateFeesPerGas } from 'wagmi' + +function App() { + const result = useEstimateFeesPerGas() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseEstimateFeesPerGas } from 'wagmi' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useEstimateFeesPerGas } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] + +function App() { + const result = useEstimateFeesPerGas({ + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useEstimateFeesPerGas } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useEstimateFeesPerGas({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### formatUnits + +`'ether' | 'gwei' | 'wei' | number | undefined` + +- Units to use when formatting result. +- Defaults to `'ether'`. + +::: code-group +```ts [index.ts] +import { useEstimateFeesPerGas } from 'wagmi' + +function App() { + const result = useEstimateFeesPerGas({ + formatUnits: 'ether', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```ts [index.ts] +import { useEstimateFeesPerGas } from 'wagmi' + +function App() { + const result = useEstimateFeesPerGas({ + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### type + +`'legacy' | 'eip1559'` + +- Defaults to `'eip1559'` + +::: code-group +```ts [index.ts] +import { useEstimateFeesPerGas } from 'wagmi' + +function App() { + const result = useEstimateFeesPerGas({ + type: 'legacy', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseEstimateFeesPerGasReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`estimateFeesPerGas`](/core/api/actions/estimateFeesPerGas) diff --git a/site/react/api/hooks/useEstimateGas.md b/site/react/api/hooks/useEstimateGas.md new file mode 100644 index 0000000000..db0707ca1a --- /dev/null +++ b/site/react/api/hooks/useEstimateGas.md @@ -0,0 +1,387 @@ +--- +title: useEstimateGas +description: Hook for estimating the gas necessary to complete a transaction without submitting it to the network. +--- + + + +# useEstimateGas + +Hook for estimating the gas necessary to complete a transaction without submitting it to the network. + +## Import + +```ts +import { useEstimateGas } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useEstimateGas } from 'wagmi' + +function App() { + const result = useEstimateGas() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseEstimateGasParameters } from 'wagmi' +``` + +### accessList + +`AccessList | undefined` + +The access list. + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { parseEther } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + accessList: [{ // [!code focus] + address: '0x1', // [!code focus] + storageKeys: ['0x1'], // [!code focus] + }], // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### account + +`Address | Account | undefined` + +Account to use when estimating gas. + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { parseEther } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + account: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +Chain ID to target when estimating gas. + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { mainnet } from '@wagmi/core/chains' +import { parseEther } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + chainId: mainnet.id, // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +Connector to estimate with. If no [`account`](#account) is provided, will use default account from connector. + +::: code-group +```ts [index.ts] +import { getConnections, estimateGas } from '@wagmi/core' +import { parseEther } from 'viem' +import { config } from './config' + +function App() { + const connections = getConnections(config) + const result = useEstimateGas({ + connector: connections[0]?.connector, // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### data + +`` `0x${string}` | undefined `` + +A contract hashed method call with encoded function data. + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { parseEther } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### gas + +`bigint | undefined` + +Gas provided for transaction execution. + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + gas: parseGwei('20'), // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### gasPrice + +`bigint | undefined` + +The price in wei to pay per gas. Only applies to [Legacy Transactions](https://viem.sh/docs/glossary/terms.html#legacy-transaction). + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + gasPrice: parseGwei('20'), // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### maxFeePerGas + +`bigint | undefined` + +Total fee per gas in wei, inclusive of [`maxPriorityFeePerGas`](#maxPriorityFeePerGas). Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + maxFeePerGas: parseGwei('20'), // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### maxPriorityFeePerGas + +`bigint | undefined` + +Max priority fee per gas in wei. Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { parseEther, parseGwei } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + maxFeePerGas: parseGwei('20'), + maxPriorityFeePerGas: parseGwei('2'), // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### nonce + +`number` + +Unique number identifying this transaction. + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { parseEther } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + nonce: 123, // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { parseEther } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + scopeKey: 'foo', // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### to + +`Address | undefined` + +The transaction recipient or contract address. + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { parseEther } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### type + +`'legacy' | 'eip1559' | 'eip2930' | undefined` + +Optional transaction request type to narrow parameters. + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { parseEther } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + type: 'eip1559', // [!code focus] + value: parseEther('0.01'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### value + +`bigint | undefined` + +Value in wei sent with this transaction. + +::: code-group +```ts [index.ts] +import { useEstimateGas } from 'wagmi' +import { parseEther } from 'viem' +import { config } from './config' + +function App() { + const result = useEstimateGas({ + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseEstimateGasReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`estimateGas`](/core/api/actions/estimateGas) diff --git a/site/react/api/hooks/useEstimateMaxPriorityFeePerGas.md b/site/react/api/hooks/useEstimateMaxPriorityFeePerGas.md new file mode 100644 index 0000000000..affb165711 --- /dev/null +++ b/site/react/api/hooks/useEstimateMaxPriorityFeePerGas.md @@ -0,0 +1,116 @@ +--- +title: useEstimateMaxPriorityFeePerGas +description: Hook for fetching an estimate for the max priority fee per gas (in wei) for a transaction to be likely included in the next block. +--- + + + +# useEstimateMaxPriorityFeePerGas + +Hook for fetching an estimate for the fees per gas (in wei) for a transaction to be likely included in the next block. + +## Import + +```ts +import { useEstimateMaxPriorityFeePerGas } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useEstimateMaxPriorityFeePerGas } from 'wagmi' + +function App() { + const result = useEstimateMaxPriorityFeePerGas() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseEstimateMaxPriorityFeePerGas } from 'wagmi' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useEstimateMaxPriorityFeePerGas } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] + +function App() { + const result = useEstimateMaxPriorityFeePerGas({ + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useEstimateMaxPriorityFeePerGas } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useEstimateMaxPriorityFeePerGas({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```ts [index.ts] +import { useEstimateMaxPriorityFeePerGas } from 'wagmi' + +function App() { + const result = useEstimateMaxPriorityFeePerGas({ + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseEstimateMaxPriorityFeePerGasReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`estimateMaxPriorityFeePerGas`](/core/api/actions/estimateMaxPriorityFeePerGas) diff --git a/site/react/api/hooks/useFeeHistory.md b/site/react/api/hooks/useFeeHistory.md new file mode 100644 index 0000000000..42bf60d89f --- /dev/null +++ b/site/react/api/hooks/useFeeHistory.md @@ -0,0 +1,210 @@ +--- +title: useFeeHistory +description: Hook for fetching a collection of historical gas information. +--- + + + +# useFeeHistory + +Hook for fetching a collection of historical gas information. + +## Import + +```ts +import { useFeeHistory } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useFeeHistory } from 'wagmi' + +function App() { + const result = useFeeHistory({ + blockCount: 4, + rewardPercentiles: [25, 75] +}) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseFeeHistoryParameters } from 'wagmi' +``` + +### blockCount + +`number | undefined` + +Number of blocks in the requested range. Between 1 and 1024 blocks can be requested in a single query. Less than requested may be returned if not all blocks are available. + +::: code-group +```tsx [index.tsx] +import { useFeeHistory } from 'wagmi' + +function App() { + const result = useFeeHistory({ + blockCount: 4, // [!code focus] + rewardPercentiles: [25, 75] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### rewardPercentiles + +`number[] | undefined` + +A monotonically increasing list of percentile values to sample from each block's effective priority fees per gas in ascending order, weighted by gas used. + +::: code-group +```tsx [index.tsx] +import { useFeeHistory } from 'wagmi' + +function App() { + const result = useFeeHistory({ + blockCount: 4, + rewardPercentiles: [25, 75] // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +Highest number block of the requested range. + + +::: code-group +```tsx [index.tsx] +import { useFeeHistory } from 'wagmi' + +function App() { + const result = useFeeHistory({ + blockCount: 4, + blockNumber: 1551231n, // [!code focus] + rewardPercentiles: [25, 75] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag of the highest number block of the requested range. + +::: code-group +```tsx [index.tsx] +import { useFeeHistory } from 'wagmi' + +function App() { + const result = useFeeHistory({ + blockCount: 4, + blockTag: 'safe', // [!code focus] + rewardPercentiles: [25, 75] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + + +::: code-group +```tsx [index.tsx] +import { useFeeHistory } from 'wagmi' +import { mainnet } from '@wagmi/core/chains' + +function App() { + const result = useFeeHistory({ + blockCount: 4, + chainId: mainnet.id, // [!code focus] + rewardPercentiles: [25, 75] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useFeeHistory } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useFeeHistory({ + blockCount: 4, + rewardPercentiles: [25, 75] + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useFeeHistory } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useFeeHistory({ + blockCount: 4, + rewardPercentiles: [25, 75] + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseFeeHistoryReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getFeeHistory`](/core/api/actions/getFeeHistory) diff --git a/site/react/api/hooks/useGasPrice.md b/site/react/api/hooks/useGasPrice.md new file mode 100644 index 0000000000..2dfa13aa19 --- /dev/null +++ b/site/react/api/hooks/useGasPrice.md @@ -0,0 +1,117 @@ +--- +title: useGasPrice +description: Hook for fetching the current price of gas (in wei). +--- + + + +# useGasPrice + +Hook for fetching the current price of gas (in wei). + +## Import + +```ts +import { useGasPrice } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useGasPrice } from 'wagmi' + +function App() { + const result = useGasPrice() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseGasPriceParameters } from 'wagmi' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useGasPrice } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] + +function App() { + const result = useGasPrice({ + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useGasPrice } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useGasPrice({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useGasPrice } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useGasPrice({ + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseGasPriceReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getGasPrice`](/core/api/actions/getGasPrice) diff --git a/site/react/api/hooks/useInfiniteReadContracts.md b/site/react/api/hooks/useInfiniteReadContracts.md new file mode 100644 index 0000000000..bc25df59f8 --- /dev/null +++ b/site/react/api/hooks/useInfiniteReadContracts.md @@ -0,0 +1,358 @@ +--- +title: useInfiniteReadContracts +description: Hook for calling multiple read methods on a contract with "infinite scroll"/"fetch more" support. +--- + + + +# useInfiniteReadContracts + +Hook for calling multiple contract read-only methods with "infinite scrolling"/"fetch more" support. + +## Import + +```ts +import { useInfiniteReadContracts } from 'wagmi' +``` + +## Usage + +The example below shows how to demonstrate how to fetch a set of [mloot](https://etherscan.io/address/0x1dfe7ca09e99d10835bf73044a23b73fc20623df) attributes (chestwear, footwear, and handwear) with "fetch more" support. + +::: code-group +```tsx [index.tsx] +import { useInfiniteReadContracts } from 'wagmi' +import { abi } from './abi' + +const mlootContractConfig = { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi, +} as const + +function App() { + const result = useInfiniteReadContracts({ + cacheKey: 'mlootAttributes', + contracts(pageParam) { + const args = [pageParam] as const + return [ + { ...mlootContractConfig, functionName: 'getChest', args }, + { ...mlootContractConfig, functionName: 'getFoot', args }, + { ...mlootContractConfig, functionName: 'getHand', args }, + ] + } + query: { + initialPageParam: 0, + getNextPageParam: (_lastPage, _allPages, lastPageParam) => { + return lastPageParam + 1 + } + } + }) +} +``` +<<< @/snippets/abi-infinite-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +In the above example, we are setting a few things: + +- [`cacheKey`](#cachekey): A unique key to store the data in the cache. +- [`query.initialPageParam`](#initialpageparam): An initial page parameter to use when fetching the first set of contracts. +- [`query.getNextPageParam`](#getnextpageparam): A function that returns the next page parameter to use when fetching the next set of contracts. +- [`contracts`](#contracts): A function that provides `pageParam` (derived from the above) as an argument and expects to return an array of contracts. + +### Paginated Parameters + +We can also leverage properties like `getNextPageParam` with a custom `limit` variable to achieve "pagination" of parameters. For example, we can fetch the first 10 contract functions, then fetch the next 10 contract functions, and so on. + +::: code-group +```tsx [index.tsx] +import { useInfiniteReadContracts } from 'wagmi' +import { abi } from './abi' + +function Example({ limit = 10 }: { limit?: number } = {}) { + const result = useInfiniteReadContracts({ + cacheKey: 'mlootAttributes', + contracts(pageParam) { + return [...new Array(limit)].map( + (_, i) => + ({ + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi, + functionName: 'getHand', + args: [BigInt(pageParam + i)], + }) as const, + ) + }, + query: { + initialPageParam: 1, + getNextPageParam(_lastPage, _allPages, lastPageParam) { + return lastPageParam + limit + }, + } + }) +} +``` +<<< @/snippets/abi-infinite-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + + +## Parameters + +```ts +import { type UseInfiniteReadContractsParameters } from 'wagmi' +``` + +### cacheKey + +`string` + +A unique key to store the data in the cache. + +::: code-group +```tsx [index.tsx] +import { useInfiniteReadContracts } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useInfiniteReadContracts({ + cacheKey: 'mlootAttributes', // [!code hl] + contracts(pageParam) { + // ... + } + query: { + initialPageParam: 0, + getNextPageParam: (_lastPage, _allPages, lastPageParam) => { + return lastPageParam + 1 + } + } + }) +} +``` +<<< @/snippets/abi-infinite-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### contracts + +`(pageParam: {{TPageParam}}) => Contract[]` + +A function that provides `pageParam` (derived from the above) as an argument and expects to return an array of contracts. + +#### abi + +`Abi | undefined` + +The contract's ABI. Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```tsx [index.tsx] +import { useInfiniteReadContracts } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useInfiniteReadContracts({ + cacheKey: 'mlootAttributes', + contracts(pageParam) { + const args = [pageParam] as const + return [ + // ... + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi, // [!code hl] + functionName: 'getChest', + args + }, + // ... + ] + } + query: { + initialPageParam: 0, + getNextPageParam: (_lastPage, _allPages, lastPageParam) => { + return lastPageParam + 1 + } + } + }) +} +``` +<<< @/snippets/abi-infinite-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +#### address + +`Address | undefined` + +The contract's address. + +::: code-group +```tsx [index.tsx] +import { useInfiniteReadContracts } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useInfiniteReadContracts({ + cacheKey: 'mlootAttributes', + contracts(pageParam) { + const args = [pageParam] as const + return [ + // ... + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', // [!code hl] + abi, + functionName: 'getChest', + args + }, + // ... + ] + } + query: { + initialPageParam: 0, + getNextPageParam: (_lastPage, _allPages, lastPageParam) => { + return lastPageParam + 1 + } + } + }) +} +``` +<<< @/snippets/abi-infinite-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +#### functionName + +`string | undefined` + +- Function to call on the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```tsx [index.tsx] +import { useInfiniteReadContracts } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useInfiniteReadContracts({ + cacheKey: 'mlootAttributes', + contracts(pageParam) { + const args = [pageParam] as const + return [ + // ... + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi, + functionName: 'getChest', // [!code hl] + args + }, + // ... + ] + } + query: { + initialPageParam: 0, + getNextPageParam: (_lastPage, _allPages, lastPageParam) => { + return lastPageParam + 1 + } + } + }) +} +``` +<<< @/snippets/abi-infinite-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +#### args + +`readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`functionName`](#functionname). + +::: code-group +```tsx [index.tsx] +import { useInfiniteReadContracts } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useInfiniteReadContracts({ + cacheKey: 'mlootAttributes', + contracts(pageParam) { + return [ + // ... + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi, + functionName: 'getChest', + args: [pageParam] // [!code hl] + }, + // ... + ] + } + query: { + initialPageParam: 0, + getNextPageParam: (_lastPage, _allPages, lastPageParam) => { + return lastPageParam + 1 + } + } + }) +} +``` +<<< @/snippets/abi-infinite-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +#### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useInfiniteReadContracts } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useInfiniteReadContracts({ + cacheKey: 'mlootAttributes', + contracts(pageParam) { + const args = [pageParam] as const + return [ + // ... + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi, + functionName: 'getChest', + args, + chainId: 1 // [!code hl] + }, + // ... + ] + } + query: { + initialPageParam: 0, + getNextPageParam: (_lastPage, _allPages, lastPageParam) => { + return lastPageParam + 1 + } + } + }) +} +``` +<<< @/snippets/abi-infinite-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseInfiniteReadContractsReturnType } from 'wagmi' +``` + + \ No newline at end of file diff --git a/site/react/api/hooks/usePrepareTransactionRequest.md b/site/react/api/hooks/usePrepareTransactionRequest.md new file mode 100644 index 0000000000..431fdda482 --- /dev/null +++ b/site/react/api/hooks/usePrepareTransactionRequest.md @@ -0,0 +1,368 @@ +--- +title: usePrepareTransactionRequest +description: Hook for preparing a transaction request for signing by populating a nonce, gas limit, fee values, and a transaction type. +--- + + + +# usePrepareTransactionRequest + +Hook for preparing a transaction request for signing by populating a nonce, gas limit, fee values, and a transaction type. + +## Import + +```ts +import { usePrepareTransactionRequest } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther } from 'viem' + +function App() { + const result = usePrepareTransactionRequest({ + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UsePrepareTransactionRequestParameters } from 'wagmi' +``` + +### account + +`Account | Address | undefined` + +The Account to send the transaction from. + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther } from 'viem' + +function App() { + const result = usePrepareTransactionRequest({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### to + +`` `0x${string}` | undefined `` + +The transaction recipient or contract address. + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther } from 'viem' + +function App() { + const result = usePrepareTransactionRequest({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', // [!code focus] + value: parseEther('1'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### accessList + +`AccessList | undefined` + +The access list. + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther } from 'viem' + +function App() { + const result = usePrepareTransactionRequest({ + accessList: [ // [!code focus:6] + { + address: '0x1', + storageKeys: ['0x1'], + }, + ], + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +Chain ID to prepare the transaction request for. + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther } from 'viem' + +function App() { + const result = usePrepareTransactionRequest({ + chainId: mainnet.id, // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### data + +`` `0x${string}` | undefined `` + +A contract hashed method call with encoded args. + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther } from 'viem' + +function App() { + const result = usePrepareTransactionRequest({ + data: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### gasPrice + +`bigint | undefined` + +The price (in wei) to pay per gas. Only applies to [Legacy Transactions](https://viem.sh/docs/glossary/terms.html#legacy-transaction). + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther, parseGwei } from 'viem' + +function App() { + const result = usePrepareTransactionRequest({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + gasPrice: parseGwei('20'), // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### maxFeePerGas + +`bigint | undefined` + +Total fee per gas (in wei), inclusive of `maxPriorityFeePerGas`. Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther, parseGwei } from 'viem' + +function App() { + const result = usePrepareTransactionRequest({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + maxFeePerGas: parseGwei('20'), // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### maxPriorityFeePerGas + +`bigint | undefined` + +Max priority fee per gas (in wei). Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther, parseGwei } from 'viem' + +function App() { + const result = usePrepareTransactionRequest({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + maxFeePerGas: parseGwei('20'), + maxPriorityFeePerGas: parseGwei('2'), // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### nonce + +`number | undefined` + +Unique number identifying this transaction. + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther } from 'viem' + +function App() { + const result = usePrepareTransactionRequest({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + nonce: 5, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### parameters + +`("fees" | "gas" | "nonce" | "type")[] | undefined` + +Parameters to prepare. + +For instance, if `["gas", "nonce"]` is provided, then only the `gas` and `nonce` parameters will be prepared. + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther } from 'viem' + +function App() { + const result = usePrepareTransactionRequest({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + parameters: ['gas', 'nonce'], // [!code focus] + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### value + +`bigint | undefined` + +Value in wei sent with this transaction. + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther } from 'viem' + +function App() { + const result = usePrepareTransactionRequest({ + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther } from 'viem' +import { config } from './config' // [!code focus] + +function App() { + const result = usePrepareTransactionRequest({ + config, // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { usePrepareTransactionRequest } from 'wagmi' +import { parseEther } from 'viem' +import { config } from './config' + +function App() { + const result = usePrepareTransactionRequest({ + scopeKey: 'foo' // [!code focus] + account: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + to: '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + value: parseEther('1'), + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UsePrepareTransactionRequestReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`prepareTransactionRequest`](/core/api/actions/prepareTransactionRequest) diff --git a/site/react/api/hooks/useProof.md b/site/react/api/hooks/useProof.md new file mode 100644 index 0000000000..76adcdca4d --- /dev/null +++ b/site/react/api/hooks/useProof.md @@ -0,0 +1,224 @@ +--- +title: useProof +description: Hook for return the account and storage values of the specified account including the Merkle-proof. +--- + + + +# useProof + +Hook for return the account and storage values of the specified account including the Merkle-proof. + +## Import + +```ts +import { useProof } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useProof } from 'wagmi' + +function App() { + const result = useProof({ + address: '0x4200000000000000000000000000000000000016', + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseProofParameters } from 'wagmi' +``` + +### address + +`Address | undefined` + +The account address to get the proof for. + +::: code-group +```tsx [index.tsx] +import { useProof } from 'wagmi' + +function App() { + const result = useProof({ + address: '0x4200000000000000000000000000000000000016', // [!code focus] + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### storageKeys + +`` `0x${string}`[] | undefined `` + +Array of storage-keys that should be proofed and included. + +::: code-group +```tsx [index.tsx] +import { useProof } from 'wagmi' + +function App() { + const result = useProof({ + address: '0x4200000000000000000000000000000000000016', + storageKeys: [ // [!code focus:3] + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +Proof at a given block number. + +::: code-group +```tsx [index.tsx] +import { useProof } from 'wagmi' + +function App() { + const result = useProof({ + address: '0x4200000000000000000000000000000000000016', + blockNumber: 42069n, // [!code focus] + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Proof at a given block tag. + +::: code-group +```tsx [index.tsx] +import { useProof } from 'wagmi' + +function App() { + const result = useProof({ + address: '0x4200000000000000000000000000000000000016', + blockTag: 'latest', // [!code focus] + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +The ID of chain to get the proof for. + +::: code-group +```tsx [index.tsx] +import { useProof } from 'wagmi' +import { optimism } from 'wagmi/chains' + +function App() { + const result = useProof({ + chainId: optimism.id, // [!code focus] + address: '0x4200000000000000000000000000000000000016', + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useProof } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useProof({ + config, // [!code focus] + address: '0x4200000000000000000000000000000000000016', + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useProof } from 'wagmi' +import { config } from './config' + +function App() { + const result = useProof({ + scopeKey: 'foo' // [!code focus] + address: '0x4200000000000000000000000000000000000016', + storageKeys: [ + '0x4a932049252365b3eedbc5190e18949f2ec11f39d3bef2d259764799a1b27d99', + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseProofReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getProof`](/core/api/actions/getProof) diff --git a/site/react/api/hooks/usePublicClient.md b/site/react/api/hooks/usePublicClient.md new file mode 100644 index 0000000000..9f0411055b --- /dev/null +++ b/site/react/api/hooks/usePublicClient.md @@ -0,0 +1,93 @@ +--- +title: usePublicClient +description: Hook for getting Viem `PublicClient` instance. +--- + +# usePublicClient + +Hook for getting Viem [`PublicClient`](https://viem.sh/docs/clients/public.html) instance. + +## Import + +```ts +import { usePublicClient } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { usePublicClient } from 'wagmi' + +function App() { + const client = usePublicClient() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +::: warning +If you want to optimize bundle size, you should use [`useClient`](/react/api/hooks/useClient) along with Viem's [tree-shakable actions](https://viem.sh/docs/clients/custom.html#tree-shaking) instead. Since Public Client has all public actions attached directly to it. +::: + +## Parameters + +```ts +import { type UsePublicClientParameters } from 'wagmi' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when getting Viem Public Client. + +::: code-group +```ts [index.ts] +import { usePublicClient } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] +import { config } from './config' + +function App() { + const client = usePublicClient({ + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { usePublicClient } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const client = usePublicClient({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UsePublicClientReturnType } from 'wagmi' +``` + +`PublicClient | undefined` + +Viem [`PublicClient`](https://viem.sh/docs/clients/public.html) instance. + +## Action + +- [`getPublicClient`](/core/api/actions/getPublicClient) +- [`watchPublicClient`](/core/api/actions/watchPublicClient) diff --git a/site/react/api/hooks/useReadContract.md b/site/react/api/hooks/useReadContract.md new file mode 100644 index 0000000000..07be91e010 --- /dev/null +++ b/site/react/api/hooks/useReadContract.md @@ -0,0 +1,406 @@ +--- +title: useReadContract +description: Hook for calling a read-only function on a contract, and returning the response. +--- + + + +# useReadContract + +Hook for calling a **read-only** function on a contract, and returning the response. + +A **read-only** function (constant function) on a Solidity contract is denoted by a pure or view keyword. They can only read the state of the contract, and cannot make any changes to it. Since read-only methods do not change the state of the contract, they do not require any gas to be executed, and can be called by any user without the need to pay for gas. + +## Import + +```ts +import { useReadContract } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useReadContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useReadContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'totalSupply', + }) +} +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseReadContractParameters } from 'wagmi' +``` + +### abi + +`Abi | undefined` + +The contract's ABI. Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```tsx [index.tsx] +import { useReadContract } from 'wagmi' +import { abi } from './abi' // [!code focus] + +function App() { + const result = useReadContract({ + abi, // [!code focus] + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'totalSupply', + }) +} +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### account + +`Account | undefined` + +Account to use when calling the contract (`msg.sender`). + +::: code-group +```tsx [index.tsx] +import { useReadContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useReadContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'balanceOf', + args: ['0x6b175474e89094c44da98b954eedeac495271d0f'], + account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + }) +} +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### address + +`Address | undefined` + +The contract's address. + +::: code-group +```tsx [index.tsx] +import { useReadContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useReadContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', // [!code focus] + functionName: 'totalSupply', + }) +} +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### args + +`readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`functionName`](#functionname). + +::: code-group +```tsx [index.tsx] +import { useReadContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useReadContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'balanceOf', + args: ['0x6b175474e89094c44da98b954eedeac495271d0f'], // [!code focus] + }) +} +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to call contract at. + +::: code-group +```tsx [index.tsx] +import { useReadContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useReadContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'totalSupply', + blockNumber: 17829139n, // [!code focus] + }) +} +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to call contract at. + +::: code-group +```tsx [index.tsx] +import { useReadContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useReadContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'totalSupply', + blockTag: 'safe', // [!code focus] + }) +} +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useReadContract } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] +import { abi } from './abi' + +function App() { + const result = useReadContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'totalSupply', + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useReadContract } from 'wagmi' +import { abi } from './abi' +import { config } from './config' // [!code focus] + +function App() { + const result = useReadContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'totalSupply', + config, // [!code focus] + }) +} +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### functionName + +`string | undefined` + +- Function to call on the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```tsx [index.tsx] +import { useReadContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useReadContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'balanceOf', // [!code focus] + args: ['0x6b175474e89094c44da98b954eedeac495271d0f'], + }) +} +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useReadContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useReadContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'balanceOf', + args: ['0x6b175474e89094c44da98b954eedeac495271d0f'], + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseReadContractReturnType } from 'wagmi' +``` + +The return type's [`data`](#data) property is inferrable via the combination of [`abi`](#abi), [`functionName`](#functionname), and [`args`](#args). Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for more info. + + + +## Type Inference + +With [`abi`](#abi) setup correctly, TypeScript will infer the correct types for [`functionName`](#functionname), [`args`](#args), and the return type. See the Wagmi [TypeScript docs](/react/typescript) for more information. + +::: code-group +```ts twoslash [Inline] +import { createConfig, http, useReadContract } from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +// ---cut--- +const result = useReadContract({ + abi: [ + { + type: 'function', + name: 'balanceOf', + stateMutability: 'view', + inputs: [{ name: 'account', type: 'address' }], + outputs: [{ type: 'uint256' }], + }, + { + type: 'function', + name: 'totalSupply', + stateMutability: 'view', + inputs: [], + outputs: [{ name: 'supply', type: 'uint256' }], + }, + ], + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'balanceOf', + // ^? + + + args: ['0x6b175474e89094c44da98b954eedeac495271d0f'], + // ^? +}) + +result.data +// ^? +``` +```ts twoslash [Const-Asserted] +import { createConfig, http, useReadContract } from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +// ---cut--- +const abi = [ + { + type: 'function', + name: 'balanceOf', + stateMutability: 'view', + inputs: [{ name: 'account', type: 'address' }], + outputs: [{ type: 'uint256' }], + }, + { + type: 'function', + name: 'totalSupply', + stateMutability: 'view', + inputs: [], + outputs: [{ name: 'supply', type: 'uint256' }], + }, +] as const + +const result = useReadContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'balanceOf', + // ^? + + + args: ['0x6b175474e89094c44da98b954eedeac495271d0f'], + // ^? +}) + +result.data +// ^? +``` +::: + + + +## Action + +- [`readContract`](/core/api/actions/readContract) diff --git a/site/react/api/hooks/useReadContracts.md b/site/react/api/hooks/useReadContracts.md new file mode 100644 index 0000000000..48436c9362 --- /dev/null +++ b/site/react/api/hooks/useReadContracts.md @@ -0,0 +1,394 @@ +--- +title: useReadContracts +description: Hook for calling multiple read methods on a contract. +--- + +# useReadContracts + +Hook for calling multiple read methods on a contract. + +## Import + +```ts +import { useReadContracts } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useReadContracts } from 'wagmi' + +const wagmigotchiContract = { + address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1', + abi: wagmigotchiABI, +} as const +const mlootContract = { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, +} as const + +function App() { + const result = useReadContracts({ + contracts: [ + { + ...wagmigotchiContract, + functionName: 'getAlive', + }, + { + ...wagmigotchiContract, + functionName: 'getBoredom', + }, + { + ...mlootContract, + functionName: 'getChest', + args: [69], + }, + { + ...mlootContract, + functionName: 'getWaist', + args: [69], + }, + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseReadContractsParameters } from 'wagmi' +``` + +### contracts + +`readonly Contract[]` + +Set of contracts to call. + +#### abi + +`Abi | undefined` + +The contract's ABI. Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```tsx [index.tsx] +import { useReadContracts } from 'wagmi' + +function App() { + const result = useReadContracts({ + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, // [!code hl] + functionName: 'getChest', + args: [69], + }, + // ... + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +#### address + +`Address | undefined` + +The contract's address. + +::: code-group +```tsx [index.tsx] +import { useReadContracts } from 'wagmi' + +function App() { + const result = useReadContracts({ + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', // [!code hl] + abi: mlootABI, + functionName: 'getChest', + args: [69], + }, + // ... + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +#### functionName + +`string | undefined` + +- Function to call on the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```tsx [index.tsx] +import { useReadContracts } from 'wagmi' + +function App() { + const result = useReadContracts({ + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', // [!code hl] + args: [69], + }, + // ... + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +#### args + +`readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`functionName`](#functionname). + +::: code-group +```tsx [index.tsx] +import { useReadContracts } from 'wagmi' + +function App() { + const result = useReadContracts({ + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], // [!code hl] + }, + // ... + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +#### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useReadContracts } from 'wagmi' + +function App() { + const result = useReadContracts({ + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69], + chainId: 1 // [!code hl] + }, + // ... + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + +### allowFailure + +`boolean` + +Whether or not the Hook should throw if a call reverts. If set to `true` (default), and a call reverts, then `useReadContracts` will fail silently and its error will be logged in the results array. Defaults to `true`. + +::: code-group +```tsx [index.tsx] +import { useReadContracts } from 'wagmi' + +function App() { + const result = useReadContracts({ + allowFailure: false, // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69] + }, + // ... + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + +### batchSize + +`number` + +The maximum size (in bytes) for each calldata chunk. Set to `0` to disable the size limit. Defaults to `1024`. + +> Note: Some RPC Providers limit the amount of calldata (`data`) that can be sent in a single `eth_call` request. It is best to check with your RPC Provider to see if there are any calldata size limits to `eth_call` requests. + +::: code-group +```tsx [index.tsx] +import { useReadContracts } from 'wagmi' + +function App() { + const result = useReadContracts({ + batchSize: 1024, // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69] + }, + // ... + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`number` + +The block number to perform the read against. + +::: code-group +```tsx [index.tsx] +import { useReadContracts } from 'wagmi' + +function App() { + const result = useReadContracts({ + blockNumber: 69420n, // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69] + }, + // ... + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to read against. + +::: code-group +```tsx [index.tsx] +import { useReadContracts } from 'wagmi' + +function App() { + const result = useReadContracts({ + blockTag: 'safe', // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69] + }, + // ... + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useReadContracts } from 'wagmi' +import { config } from './config' + +function App() { + const result = useReadContracts({ + config, // [!code hl] + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69] + }, + // ... + ], + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### multicallAddress + +`Address` + +Address of multicall contract. + +::: code-group +```tsx [index.tsx] +import { useReadContracts } from 'wagmi' + +function App() { + const result = useReadContracts({ + contracts: [ + { + address: '0x1dfe7ca09e99d10835bf73044a23b73fc20623df', + abi: mlootABI, + functionName: 'getChest', + args: [69] + }, + // ... + ], + multicallAddress: '0xca11bde05977b3631167028862be2a173976ca11', // [!code hl] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseReadContractsReturnType } from 'wagmi' +``` + + + +## Action + +- [`readContracts`](/core/api/actions/readContracts) diff --git a/site/react/api/hooks/useReconnect.md b/site/react/api/hooks/useReconnect.md new file mode 100644 index 0000000000..7aff4945c9 --- /dev/null +++ b/site/react/api/hooks/useReconnect.md @@ -0,0 +1,111 @@ +--- +title: useReconnect +description: Hook for reconnecting connectors. +--- + + + +# useReconnect + +Hook for reconnecting [connectors](/core/api/connectors). + +## Import + +```ts +import { useReconnect } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useReconnect } from 'wagmi' +import { useEffect } from 'react' + +function App() { + const { reconnect } = useReconnect() + + useEffect(() => { + reconnect() + }, []) +} +``` + +::: + +::: tip +When [`WagmiProvider['reconnectOnMount']`](/react/api/WagmiProvider#reconnectonmount) is `true`, `reconnect` is called automatically on mount. +::: + +## Parameters + +```ts +import { type UseReconnectParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useReconnect } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useReconnect({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseReconnectReturnType } from 'wagmi' +``` + +### connectors + +`readonly Connector[]` + +Globally configured connectors via [`createConfig`](/react/api/createConfig#connectors). + +::: code-group +```tsx [index.tsx] +import { useReconnect } from 'wagmi' +import { mainnet } from 'wagmi/chains' +import { useEffect } from 'react' + +function App() { + const { reconnect, connectors } = useReconnect() + + useEffect(() => { + reconnect({ connectors }) + }, []) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + + + +## Action + +- [`reconnect`](/core/api/actions/reconnect) diff --git a/site/react/api/hooks/useSendCalls.md b/site/react/api/hooks/useSendCalls.md new file mode 100644 index 0000000000..d7020fd8bf --- /dev/null +++ b/site/react/api/hooks/useSendCalls.md @@ -0,0 +1,103 @@ +--- +title: useSendCalls +description: Hook that requests for the wallet to sign and broadcast a batch of calls (transactions) to the network. +--- + + + +# useSendCalls + +Hook that requests for the wallet to sign and broadcast a batch of calls (transactions) to the network. + +[Read more.](https://github.com/ethereum/EIPs/blob/815028dc634463e1716fc5ce44c019a6040f0bef/EIPS/eip-5792.md#wallet_sendcalls) + +## Import + +```ts +import { useSendCalls } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useSendCalls } from 'wagmi' +import { parseEther } from 'viem' + +function App() { + const { sendCalls } = useSendCalls() + + return ( + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseSendCallsParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useSendCalls } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useSendCalls({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSendCallsReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`sendCalls`](/core/api/actions/sendCalls) diff --git a/site/react/api/hooks/useSendTransaction.md b/site/react/api/hooks/useSendTransaction.md new file mode 100644 index 0000000000..c9d4bf441b --- /dev/null +++ b/site/react/api/hooks/useSendTransaction.md @@ -0,0 +1,93 @@ +--- +title: useSendTransaction +description: Hook for creating, signing, and sending transactions to networks. +--- + + + +# useSendTransaction + +Hook for creating, signing, and sending transactions to networks. + +## Import + +```ts +import { useSendTransaction } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useSendTransaction } from 'wagmi' +import { parseEther } from 'viem' + +function App() { + const { sendTransaction } = useSendTransaction() + + return ( + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseSendTransactionParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useSendTransaction } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useSendTransaction({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSendTransactionReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`sendTransaction`](/core/api/actions/sendTransaction) diff --git a/site/react/api/hooks/useShowCallsStatus.md b/site/react/api/hooks/useShowCallsStatus.md new file mode 100644 index 0000000000..6fb26e9f05 --- /dev/null +++ b/site/react/api/hooks/useShowCallsStatus.md @@ -0,0 +1,96 @@ +--- +title: useShowCallsStatus +description: Action to request for the wallet to show information about a call batch +--- + + + +# useShowCallsStatus + +Action to request for the wallet to show information about a call batch that was sent via `useShowCalls`. + +[Read more.](https://github.com/ethereum/EIPs/blob/1663ea2e7a683285f977eda51c32cec86553f585/EIPS/eip-5792.md#wallet_showcallsstatus) + + + +## Import + +```ts +import { useShowCallsStatus } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useShowCallsStatus } from 'wagmi' +import { parseEther } from 'viem' + +function App() { + const { showCallsStatus } = useShowCallsStatus() + + return ( + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseShowCallsStatusParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useShowCallsStatus } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useShowCallsStatus({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseShowCallsStatusReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`showCallsStatus`](/core/api/actions/showCallsStatus) diff --git a/site/react/api/hooks/useSignMessage.md b/site/react/api/hooks/useSignMessage.md new file mode 100644 index 0000000000..7b0ffb3a4a --- /dev/null +++ b/site/react/api/hooks/useSignMessage.md @@ -0,0 +1,85 @@ +--- +title: useSignMessage +description: Hook for signing messages. +--- + + + +# useSignMessage + +Hook for signing messages. + +## Import + +```ts +import { useSignMessage } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useSignMessage } from 'wagmi' + +function App() { + const { signMessage } = useSignMessage() + + return ( + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseSignMessageParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useSignMessage } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useSignMessage({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSignMessageReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`signMessage`](/core/api/actions/signMessage) diff --git a/site/react/api/hooks/useSignTypedData.md b/site/react/api/hooks/useSignTypedData.md new file mode 100644 index 0000000000..140b0e86a3 --- /dev/null +++ b/site/react/api/hooks/useSignTypedData.md @@ -0,0 +1,217 @@ +--- +title: useSignTypedData +description: Hook for signing typed data and calculating an Ethereum-specific EIP-712 signature. +--- + + + +# useSignTypedData + +Hook for signing typed data and calculating an Ethereum-specific [EIP-712](https://eips.ethereum.org/EIPS/eip-712) signature. + +## Import + +```ts +import { useSignTypedData } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useSignTypedData } from 'wagmi' + + +function App() { + const { signTypedData } = useSignTypedData() + + return ( + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseSignTypedDataParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useSignTypedData } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useSignTypedData({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSignTypedDataReturnType } from 'wagmi' +``` + + + +## Type Inference + +With [`types`](/core/api/actions/signTypedData#types) setup correctly, TypeScript will infer the correct types for [`domain`](/core/api/actions/signTypedData#domain), [`message`](/core/api/actions/signTypedData#message), and [`primaryType`](/core/api/actions/signTypedData#primarytype). See the Wagmi [TypeScript docs](/react/typescript) for more information. + +::: code-group +```ts twoslash [Inline] +import { useSignTypedData } from 'wagmi' +// ---cut--- +const { signTypedData } = useSignTypedData() + +signTypedData({ + types: { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], + }, + primaryType: 'Mail', + // ^? + + + message: { + // ^? + + + + + + + + + + + + + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, +}) +``` +```ts twoslash [Const-Asserted] +import { useSignTypedData } from 'wagmi' +// ---cut--- +const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const + +const { signTypedData } = useSignTypedData() + +signTypedData({ + types, + primaryType: 'Mail', + // ^? + + + message: { + // ^? + + + + + + + + + + + + + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, +}) +``` +::: + + + +## Action + +- [`signTypedData`](/core/api/actions/signTypedData) diff --git a/site/react/api/hooks/useSimulateContract.md b/site/react/api/hooks/useSimulateContract.md new file mode 100644 index 0000000000..03872f53e5 --- /dev/null +++ b/site/react/api/hooks/useSimulateContract.md @@ -0,0 +1,686 @@ +--- +title: useSimulateContract +description: Hook for simulating/validating a contract interaction. +--- + + + +# useSimulateContract + +Hook for simulating/validating a contract interaction. + +## Import + +```ts +import { useSimulateContract } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Parameters + +```ts +import { type UseSimulateContractParameters } from 'wagmi' +``` + +### abi + +`Abi | undefined` + +The contract's ABI. Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```tsx [index.tsx] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' // [!code focus] + +function App() { + const result = useSimulateContract({ + abi, // [!code focus] + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### accessList + +`AccessList | undefined` + +The access list. + +::: code-group +```tsx [index.ts] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' +import { config } from './config' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + accessList: [{ // [!code focus] + address: '0x1', // [!code focus] + storageKeys: ['0x1'], // [!code focus] + }], // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### account + +`Account | undefined` + +Account to use when calling the contract (`msg.sender`). Throws if account is not found on [`connector`](#connector). + +::: code-group +```tsx [index.tsx] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### address + +`Address | undefined` + +The contract's address. + +::: code-group +```tsx [index.tsx] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', // [!code focus] + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### args + +`readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`functionName`](#functionname). + +::: code-group +```tsx [index.tsx] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ // [!code focus] + '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', // [!code focus] + 123n, // [!code focus] + ], // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to call contract at. + +::: code-group +```tsx [index.tsx] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + blockNumber: 17829139n, // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to call contract at. + +::: code-group +```tsx [index.tsx] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + blockTag: 'safe', // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useSimulateContract } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] +import { abi } from './abi' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' +import { config } from './config' // [!code focus] + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + config, // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +[Connector](/react/api/connectors) to simulate transaction with. + +::: code-group +```tsx [index.ts] +import { useConnectorClient, useSimulateContract } from 'wagmi' +import { abi } from './abi' +import { config } from './config' + +function App() { + const { data: connector } = useConnectorClient() + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + connector, // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### dataSuffix + +`` `0x${string}` | undefined `` + +Data to append to the end of the calldata. Useful for adding a ["domain" tag](https://opensea.notion.site/opensea/Seaport-Order-Attributions-ec2d69bf455041a5baa490941aad307f). + +::: code-group +```tsx [index.ts] +import { useSimulateContract } from 'wagmi' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + dataSuffix: '0xdeadbeef', // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### functionName + +`string | undefined` + +- Function to call on the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```tsx [index.tsx] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', // [!code focus] + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### gas + +`bigint | undefined` + +Gas provided for transaction execution. + +::: code-group +```tsx [index.ts] +import { useSimulateContract } from 'wagmi' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + gas: parseGwei('20'), // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### gasPrice + +`bigint | undefined` + +The price in wei to pay per gas. Only applies to [Legacy Transactions](https://viem.sh/docs/glossary/terms.html#legacy-transaction). + +::: code-group +```tsx [index.ts] +import { useSimulateContract } from 'wagmi' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + gasPrice: parseGwei('20'), // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### maxFeePerGas + +`bigint | undefined` + +Total fee per gas in wei, inclusive of [`maxPriorityFeePerGas`](#maxPriorityFeePerGas). Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```tsx [index.ts] +import { useSimulateContract } from 'wagmi' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + maxFeePerGas: parseGwei('20'), // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### maxPriorityFeePerGas + +`bigint | undefined` + +Max priority fee per gas in wei. Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```tsx [index.ts] +import { useSimulateContract } from 'wagmi' +import { parseGwei } from 'viem' +import { abi } from './abi' +import { config } from './config' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + maxFeePerGas: parseGwei('20'), + maxPriorityFeePerGas: parseGwei('2'), // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### nonce + +`number` + +Unique number identifying this transaction. + +::: code-group +```tsx [index.ts] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' +import { config } from './config' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + nonce: 123, // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### type + +`'legacy' | 'eip1559' | 'eip2930' | undefined` + +Optional transaction request type to narrow parameters. + +::: code-group +```tsx [index.ts] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' +import { config } from './config' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + type: 'eip1559', // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### value + +`bigint | undefined` + +Value in wei sent with this transaction. + +::: code-group +```tsx [index.ts] +import { useSimulateContract } from 'wagmi' +import { parseEther } from 'viem' +import { abi } from './abi' +import { config } from './config' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + value: parseEther('0.01'), // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.ts] +import { useSimulateContract } from 'wagmi' +import { abi } from './abi' +import { config } from './config' + +function App() { + const result = useSimulateContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'transferFrom', + args: [ + '0xd2135CfB216b74109775236E36d4b433F1DF507B', + '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', + 123n, + ], + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSimulateContractReturnType } from 'wagmi' +``` + +The return type's [`data`](#data) property is inferrable via the combination of [`abi`](#abi), [`functionName`](#functionname), and [`args`](#args). Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for more info. + + + +## Type Inference + +With [`abi`](#abi) setup correctly, TypeScript will infer the correct types for [`functionName`](#functionname), [`args`](#args), and [`value`](#value). See the Wagmi [TypeScript docs](/react/typescript) for more information. + + + +## Action + +- [`simulateContract`](/core/api/actions/simulateContract) diff --git a/site/react/api/hooks/useStorageAt.md b/site/react/api/hooks/useStorageAt.md new file mode 100644 index 0000000000..12c524ac1e --- /dev/null +++ b/site/react/api/hooks/useStorageAt.md @@ -0,0 +1,208 @@ +--- +title: useStorageAt +description: Hook for returning the value from a storage slot at a given address. +--- + + + +# useStorageAt + +Hook for for returning the value from a storage slot at a given address. + +## Import + +```ts +import { useStorageAt } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useStorageAt } from 'wagmi' + +function App() { + const result = useStorageAt({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + slot: '0x0', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseStorageAtParameters } from 'wagmi' +``` + +### address + +`Address | undefined` + +The contract address. + +::: code-group +```tsx [index.tsx] +import { useStorageAt } from 'wagmi' + +function App() { + const result = useStorageAt({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', // [!code focus] + slot: '0x0', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### slot + +`Hex | undefined` + +The storage position (as a hex encoded value). + +::: code-group +```tsx [index.tsx] +import { useStorageAt } from 'wagmi' + +function App() { + const result = useStorageAt({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + slot: '0x0', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## blockNumber + +`bigint | undefined` + +The block number to check the storage at. + +::: code-group +```tsx [index.tsx] +import { useStorageAt } from 'wagmi' + +function App() { + const result = useStorageAt({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + blockNumber: 16280770n, // [!code focus] + slot: '0x0', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +The block tag to check the storage at. + +::: code-group +```tsx [index.tsx] +import { useStorageAt } from 'wagmi' + +function App() { + const result = useStorageAt({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + blockTag: 'safe', // [!code focus] + slot: '0x0', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +The chain ID to check the storage at. + +::: code-group +```tsx [index.tsx] +import { useStorageAt } from 'wagmi' +import { mainnet } from '@wagmi/core/chains' + +function App() { + const result = useStorageAt({ + chainId: mainnet.id, // [!code focus] + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + slot: '0x0', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useStorageAt } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useStorageAt({ + config, // [!code focus] + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + slot: '0x0', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useStorageAt } from 'wagmi' +import { config } from './config' + +function App() { + const result = useStorageAt({ + scopeKey: 'foo' // [!code focus] + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + slot: '0x0', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseStorageAtReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getStorageAt`](/core/api/actions/getStorageAt) diff --git a/site/react/api/hooks/useSwitchAccount.md b/site/react/api/hooks/useSwitchAccount.md new file mode 100644 index 0000000000..8dc3395a70 --- /dev/null +++ b/site/react/api/hooks/useSwitchAccount.md @@ -0,0 +1,116 @@ +--- +title: useSwitchAccount +description: Hook for switching the current account. +--- + + + +# useSwitchAccount + +Hook for switching the current account. + +## Import + +```ts +import { useSwitchAccount } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useSwitchAccount } from 'wagmi' + +function App() { + const { connectors, switchAccount } = useSwitchAccount() + + return ( +
+ {connectors.map((connector) => ( + + ))} +
+ ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseSwitchAccountParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useSwitchAccount } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useSwitchAccount({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSwitchAccountReturnType } from 'wagmi' +``` + +### connectors + +`readonly Connector[]` + +Globally configured and actively connected connectors. Useful for rendering a list of available connectors to switch to. + +::: code-group +```tsx [index.tsx] +import { useSwitchAccount } from 'wagmi' + +function App() { + const { connectors, switchAccount } = useSwitchAccount() + + return ( +
+ {connectors.map((connector) => ( + + ))} +
+ ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + + + +## Action + +- [`switchAccount`](/core/api/actions/switchAccount) diff --git a/site/react/api/hooks/useSwitchChain.md b/site/react/api/hooks/useSwitchChain.md new file mode 100644 index 0000000000..3b139bd701 --- /dev/null +++ b/site/react/api/hooks/useSwitchChain.md @@ -0,0 +1,120 @@ +--- +title: useSwitchChain +description: Hook for switching the target chain for a connector or the Wagmi `Config`. +--- + + + +# useSwitchChain + +Hook for switching the target chain for a connector or the Wagmi [`Config`](/react/api/createConfig#config). + +## Import + +```ts +import { useSwitchChain } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useSwitchChain } from 'wagmi' + +function App() { + const { chains, switchChain } = useSwitchChain() + + return ( +
+ {chains.map((chain) => ( + + ))} +
+ ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +::: tip +When connected, `switchChain` will switch the target chain for the connector. When not connected, `switchChain` will switch the target chain for the Wagmi [`Config`](/react/api/createConfig#config). +::: + +## Parameters + +```ts +import { type UseSwitchChainParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useSwitchChain } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useSwitchChain({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSwitchChainReturnType } from 'wagmi' +``` + +### chains + +`readonly [Chain, ...Chain[]]` + +Globally configured chains. Useful for rendering a list of available chains to switch to. + +::: code-group +```tsx [index.tsx] +import { useSwitchChain } from 'wagmi' + +function App() { + const { chains, switchChain } = useSwitchChain() + + return ( +
+ {chains.map((chain) => ( + + ))} +
+ ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + + + +## Action + +- [`switchChain`](/core/api/actions/switchChain) diff --git a/site/react/api/hooks/useToken.md b/site/react/api/hooks/useToken.md new file mode 100644 index 0000000000..cd4c6dbec2 --- /dev/null +++ b/site/react/api/hooks/useToken.md @@ -0,0 +1,162 @@ +--- +title: useToken +description: Hook for fetching token info. +--- + + + +# useToken [deprecated](/react/guides/migrate-from-v1-to-v2#deprecated-usetoken) + +Hook for fetching token info. + +## Import + +```ts +import { useToken } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useToken } from 'wagmi' + +function App() { + const result = useToken({ + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseTokenParameters } from 'wagmi' +``` + +### address + +`Address | undefined` + +Address to get token for. [`enabled`](#enabled) set to `false` if `address` is `undefined`. + +::: code-group +```tsx [index.tsx] +import { useToken } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +function App() { + const result = useToken({ + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useToken } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] + +function App() { + const result = useToken({ + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useToken } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useToken({ + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### formatUnits + +`'ether' | 'gwei' | 'wei' | number | undefined` + +- Units to use when formatting result. +- Defaults to `'ether'`. + +::: code-group +```ts [index.ts] +import { useToken } from 'wagmi' + +function App() { + const result = useToken({ + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', + formatUnits: 'ether', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```ts [index.ts] +import { useToken } from 'wagmi' + +function App() { + const result = useToken({ + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseTokenReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getToken`](/core/api/actions/getToken) diff --git a/site/react/api/hooks/useTransaction.md b/site/react/api/hooks/useTransaction.md new file mode 100644 index 0000000000..391f5bf802 --- /dev/null +++ b/site/react/api/hooks/useTransaction.md @@ -0,0 +1,184 @@ +--- +title: useTransaction +description: Hook for fetching transactions given hashes or block identifiers. +--- + + + +# useTransaction + +Hook for fetching transactions given hashes or block identifiers. + +## Import + +```ts +import { useTransaction } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useTransaction } from 'wagmi' + +function App() { + const result = useTransaction({ + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseTransactionParameters } from 'wagmi' +``` + +--- + +### blockHash + +`bigint | undefined` + +Block hash to get transaction at (with [`index`](#index)). + +```ts +import { useTransaction } from 'wagmi' + +function App() { + const result = useTransaction({ + blockHash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', // [!code focus] + index: 0, + }) +} +``` + +### blockNumber + +`bigint | undefined` + +Block number to get transaction at (with [`index`](#index)). + +```ts +import { useTransaction } from 'wagmi' + +function App() { + const result = useTransaction({ + blockNumber: 17829139n, // [!code focus] + index: 0, + }) +} +``` + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get transaction at (with [`index`](#index)). + +```ts +import { useTransaction } from 'wagmi' + +function App() { + const result = useTransaction({ + blockTag: 'safe', // [!code focus] + index: 0, + }) +} +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +```ts +import { useTransaction } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +function App() { + const result = useTransaction({ + chainId: mainnet.id, // [!code focus] + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', + }) +} +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useTransaction } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useTransaction({ + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### hash + +`` `0x${string}` | undefined `` + +Hash to get transaction. [`enabled`](#enabled) set to `false` if `hash` and [`index`](#index) are `undefined`. + +```ts +import { useTransaction } from 'wagmi' + +function App() { + const result = useTransaction({ + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', // [!code focus] + }) +} +``` + +### index + +`number | undefined` + +An index to be used with a block identifier ([hash](#blockhash), [number](#blocknumber), or [tag](#blocktag)). [`enabled`](#enabled) set to `false` if `index` and [`hash`](#hash) are `undefined`. + +```ts +import { useTransaction } from 'wagmi' + +function App() { + const result = useTransaction({ + blockTag: 'safe', + index: 0 // [!code focus] + }) +} +``` + + + +## Return Type + +```ts +import { type UseTransactionReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getTransaction`](/core/api/actions/getTransaction) diff --git a/site/react/api/hooks/useTransactionConfirmations.md b/site/react/api/hooks/useTransactionConfirmations.md new file mode 100644 index 0000000000..6dec7c1319 --- /dev/null +++ b/site/react/api/hooks/useTransactionConfirmations.md @@ -0,0 +1,153 @@ +--- +title: useTransactionConfirmations +description: Hook for fetching the number of blocks passed (confirmations) since the transaction was processed on a block. +--- + + + +# useTransactionConfirmations + +Hook for fetching the number of blocks passed (confirmations) since the transaction was processed on a block. If confirmations is 0, then the Transaction has not been confirmed & processed yet. + +## Import + +```ts +import { useTransactionConfirmations } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useTransactionConfirmations } from 'wagmi' + +function App() { + const result = useTransactionConfirmations({ + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseTransactionConfirmationsParameters } from 'wagmi' +``` + +--- + +### hash + +`` `0x${string}` | undefined `` + +The hash of the transaction. + +```ts +import { useTransactionConfirmations } from 'wagmi' + +function App() { + const result = useTransactionConfirmations({ + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', // [!code focus] + }) +} +``` + +### transactionReceipt + +`TransactionReceipt | undefined` + +The transaction receipt. + +```ts +import { useTransactionConfirmations } from 'wagmi' + +function App() { + const result = useTransactionConfirmations({ + transactionReceipt: { ... }, // [!code focus] + }) +} +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +```ts +import { useTransactionConfirmations } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +function App() { + const result = useTransactionConfirmations({ + chainId: mainnet.id, // [!code focus] + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', + }) +} +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useTransactionConfirmations } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useTransactionConfirmations({ + config, // [!code focus] + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useBlock } from 'wagmi' +import { config } from './config' + +function App() { + const result = useTransactionConfirmations({ + scopeKey: 'foo' // [!code focus] + hash: '0x0fa64daeae54e207aa98613e308c2ba8abfe274f75507e741508cc4db82c8cb5', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseTransactionConfirmationsReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getTransactionConfirmations`](/core/api/actions/getTransactionConfirmations) diff --git a/site/react/api/hooks/useTransactionCount.md b/site/react/api/hooks/useTransactionCount.md new file mode 100644 index 0000000000..142453af4b --- /dev/null +++ b/site/react/api/hooks/useTransactionCount.md @@ -0,0 +1,185 @@ +--- +title: useTransactionCount +description: Hook for fetching the number of transactions an Account has broadcast / sent. +--- + + + +# useTransactionCount + +Hook for fetching the number of transactions an Account has sent. + +## Import + +```ts +import { useTransactionCount } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useTransactionCount } from 'wagmi' + +function App() { + const result = useTransactionCount({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseTransactionCountParameters } from 'wagmi' +``` + +### address + +`Address | undefined` + +Address to get the transaction count for. [`enabled`](#enabled) set to `false` if `address` is `undefined`. + +::: code-group +```tsx [index.tsx] +import { useTransactionCount } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +function App() { + const result = useTransactionCount({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get the transaction count at. + +::: code-group +```ts [index.ts] +import { useTransactionCount } from 'wagmi' + +function App() { + const result = useTransactionCount({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + blockNumber: 17829139n, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get the transaction count at. + +::: code-group +```ts [index.ts] +import { useTransactionCount } from 'wagmi' + +function App() { + const result = useTransactionCount({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + blockTag: 'latest', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useTransactionCount } from 'wagmi' +import { mainnet } from 'wagmi/chains' // [!code focus] + +function App() { + const result = useTransactionCount({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + chainId: mainnet.id, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useTransactionCount } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useTransactionCount({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useTransactionCount } from 'wagmi' + +function App() { + const result = useTransactionCount({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseTransactionCountReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getTransactionCount`](/core/api/actions/getTransactionCount) diff --git a/site/react/api/hooks/useTransactionReceipt.md b/site/react/api/hooks/useTransactionReceipt.md new file mode 100644 index 0000000000..2f909ee891 --- /dev/null +++ b/site/react/api/hooks/useTransactionReceipt.md @@ -0,0 +1,142 @@ +--- +title: useTransactionReceipt +description: Hook for return the Transaction Receipt given a Transaction hash. +--- + + + +# useTransactionReceipt + +Hook for return the [Transaction Receipt](https://viem.sh/docs/glossary/terms.html#transaction-receipt) given a [Transaction](https://viem.sh/docs/glossary/terms.html#transaction) hash. + +## Import + +```ts +import { useTransactionReceipt } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useTransactionReceipt } from 'wagmi' + +function App() { + const result = useTransactionReceipt({ + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseTransactionReceiptParameters } from 'wagmi' +``` + +### hash + +`` `0x${string}` | undefined `` + +A transaction hash. + +::: code-group +```tsx [index.tsx] +import { useTransactionReceipt } from 'wagmi' + +function App() { + const result = useTransactionReceipt({ + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +The ID of chain to return the transaction receipt from. + +::: code-group +```tsx [index.tsx] +import { useTransactionReceipt } from 'wagmi' +import { mainnet } from 'wagmi/chains' + + +function App() { + const result = useTransactionReceipt({ + chainId: mainnet.id, // [!code focus] + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useTransactionReceipt } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useTransactionReceipt({ + config, // [!code focus] + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useTransactionReceipt } from 'wagmi' +import { config } from './config' + +function App() { + const result = useTransactionReceipt({ + scopeKey: 'foo' // [!code focus] + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseTransactionReceiptReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getTransactionReceipt`](/core/api/actions/getTransactionReceipt) diff --git a/site/react/api/hooks/useVerifyMessage.md b/site/react/api/hooks/useVerifyMessage.md new file mode 100644 index 0000000000..e7750d79f3 --- /dev/null +++ b/site/react/api/hooks/useVerifyMessage.md @@ -0,0 +1,257 @@ +--- +title: useVerifyMessage +description: Hook for verify that a message was signed by the provided address. +--- + + + +# useVerifyMessage + +Hook for verify that a message was signed by the provided address. It supports verifying messages that were signed by either a Smart Contract Account or Externally Owned Account. + +## Import + +```ts +import { useVerifyMessage } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useVerifyMessage } from 'wagmi' + +function App() { + const result = useVerifyMessage({ + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseVerifyMessageParameters } from 'wagmi' +``` + +### address + +`Address | undefined` + +The Ethereum address that signed the original message. + +::: code-group +```tsx [index.tsx] +import { useVerifyMessage } from 'wagmi' + +function App() { + const result = useVerifyMessage({ + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', // [!code focus] + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### message + +`string | { raw: Hex | ByteArray } | undefined` + +The message to be verified. + +By default, wagmi verifies the UTF-8 representation of the message. + +::: code-group +```tsx [index.tsx] +import { useVerifyMessage } from 'wagmi' + +function App() { + const result = useVerifyMessage({ + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', // [!code focus] + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +::: tip +By default, viem signs the UTF-8 representation of the message. To sign the data representation of the message, you can use the `raw` attribute. + +```ts +import { useVerifyMessage } from 'wagmi' + +function App() { + const result = useVerifyMessage({ + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: { raw: '0x68656c6c6f20776f726c64' } // [!code focus] + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +::: + +### signature + +`Hex | ByteArray | undefined` + +The signature that was generated by signing the message with the address's signer. + +::: code-group +```tsx [index.tsx] +import { useVerifyMessage } from 'wagmi' + +function App() { + const result = useVerifyMessage({ + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +Only used when verifying a message that was signed by a Smart Contract Account. The ID of chain to check if the contract was already deployed. + +::: code-group +```tsx [index.tsx] +import { useVerifyMessage } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +function App() { + const result = useVerifyMessage({ + chainId: mainnet.id, // [!code focus] + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +Only used when verifying a message that was signed by a Smart Contract Account. The block number to check if the contract was already deployed. + +::: code-group +```tsx [index.tsx] +import { useVerifyMessage } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +function App() { + const result = useVerifyMessage({ + blockNumber: 12345678n, // [!code focus] + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Only used when verifying a message that was signed by a Smart Contract Account. The block tag to check if the contract was already deployed. + +::: code-group +```tsx [index.tsx] +import { useVerifyMessage } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +function App() { + const result = useVerifyMessage({ + blockTag: 'pending', // [!code focus] + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useVerifyMessage } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useVerifyMessage({ + config, // [!code focus] + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useVerifyMessage } from 'wagmi' +import { config } from './config' + +function App() { + const result = useVerifyMessage({ + scopeKey: 'foo' // [!code focus] + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + message: 'hello world', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseVerifyMessageReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`verifyMessage`](/core/api/actions/verifyMessage) diff --git a/site/react/api/hooks/useVerifyTypedData.md b/site/react/api/hooks/useVerifyTypedData.md new file mode 100644 index 0000000000..4d9f8bc24e --- /dev/null +++ b/site/react/api/hooks/useVerifyTypedData.md @@ -0,0 +1,724 @@ +--- +title: useVerifyTypedData +description: Hook for verify that a typed data was signed by the provided address. +--- + + + +# useVerifyTypedData + +Hook for verify that a typed data was signed by the provided address. It supports verifying typed data that were signed by either a Smart Contract Account or Externally Owned Account. + +## Import + +```ts +import { useVerifyTypedData } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { domain, types } from './data' +import { useVerifyTypedData } from 'wagmi' + +function App() { + const result = useVerifyTypedData({ + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseVerifyTypedDataParameters } from 'wagmi' +``` + +### address + +`Address | undefined` + +The Ethereum address that signed the original typed data. + +::: code-group +```tsx [index.tsx] +import { domain, types } from './data' +import { useVerifyTypedData } from 'wagmi' + +function App() { + const result = useVerifyTypedData({ + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', // [!code focus] + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### domain + +`TypedDataDomain | undefined` + +The typed data domain. + +::: code-group +```tsx [index.tsx] +import { types } from './data' +import { useVerifyTypedData } from 'wagmi' + +function App() { + const result = useVerifyTypedData({ + domain: { // [!code focus:6] + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', + }, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +```ts [data.ts] +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### types + +The type definitions for the typed data. + +::: code-group +```tsx [index.tsx] +import { domain } from './data' +import { useVerifyTypedData } from 'wagmi' + +function App() { + const result = useVerifyTypedData({ + domain, + types: { // [!code focus:11] + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], + }, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### primaryType + +`string | undefined` + +The primary `type` to extract from types and use in `value`. + +::: code-group +```tsx [index.tsx] +import { domain } from './data' +import { useVerifyTypedData } from 'wagmi' + +function App() { + const result = useVerifyTypedData({ + domain, + types: { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ // [!code focus:5] + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], + }, + primaryType: 'Mail', // [!code focus] + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### message + +Type inferred from `types` & `primaryType`. + +The message to be verified. + +::: code-group +```tsx [index.tsx] +import { domain, types } from './data' +import { useVerifyTypedData } from 'wagmi' + +function App() { + const result = useVerifyTypedData({ + domain, + types, + message: { // [!code focus:11] + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### signature + +`Hex | ByteArray | undefined` + +The signature that was generated by signing the typed data with the address's signer. + +::: code-group +```tsx [index.tsx] +import { domain, types } from './data' +import { useVerifyTypedData } from 'wagmi' + +function App() { + const result = useVerifyTypedData({ + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', // [!code focus] + }) +} +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +Only used when verifying a typed data that was signed by a Smart Contract Account. The ID of chain to check if the contract was already deployed. + +::: code-group +```tsx [index.tsx] +import { domain, types } from './data' +import { useVerifyTypedData } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +function App() { + const result = useVerifyTypedData({ + chainId: mainnet.id, // [!code focus] + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +Only used when verifying a typed data that was signed by a Smart Contract Account. The block number to check if the contract was already deployed. + +::: code-group +```tsx [index.tsx] +import { domain, types } from './data' +import { useVerifyTypedData } from 'wagmi' + +function App() { + const result = useVerifyTypedData({ + blockNumber: 12345678n, // [!code focus] + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Only used when verifying a typed data that was signed by a Smart Contract Account. The block tag to check if the contract was already deployed. + +::: code-group +```tsx [index.tsx] +import { domain, types } from './data' +import { useVerifyTypedData } from 'wagmi' + +function App() { + const result = useVerifyTypedData({ + blockTag: 'latest', // [!code focus] + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { domain, types } from './data' +import { useVerifyTypedData } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useVerifyTypedData({ + config, // [!code focus] + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { domain, types } from './data' +import { useVerifyTypedData } from 'wagmi' + +function App() { + const result = useVerifyTypedData({ + scopeKey: 'foo' // [!code focus] + domain, + types, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, + primaryType: 'Mail', + address: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', + signature: '0x66edc32e2ab001213321ab7d959a2207fcef5190cc9abb6da5b0d2a8a9af2d4d2b0700e2c317c4106f337fd934fbbb0bf62efc8811a78603b33a8265d3b8f8cb1c', + }) +} +``` +```ts [data.ts] +// All properties on a domain are optional +export const domain = { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', +} as const + +// The named list of all type definitions +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseVerifyTypedDataReturnType } from 'wagmi' +``` + + + +## Type Inference + +With [`types`](#types) setup correctly, TypeScript will infer the correct types for [`domain`](#domain), [`message`](#message), and [`primaryType`](#primarytype). See the Wagmi [TypeScript docs](/react/typescript) for more information. + + + +## Action + +- [`verifyTypedData`](/core/api/actions/verifyTypedData) diff --git a/site/react/api/hooks/useWaitForCallsStatus.md b/site/react/api/hooks/useWaitForCallsStatus.md new file mode 100644 index 0000000000..39e520de52 --- /dev/null +++ b/site/react/api/hooks/useWaitForCallsStatus.md @@ -0,0 +1,181 @@ +--- +title: useWaitForCallsStatus +description: Waits for a call bundle to be confirmed & included on a block. +--- + + + +# useWaitForCallsStatus + +Waits for a call bundle to be confirmed & included on a block before returning the status & receipts. + + + +## Import + +```ts +import { useWaitForCallsStatus } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useWaitForCallsStatus } from 'wagmi' + +function App() { + const result = useWaitForCallsStatus({ + id: '0x...', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseWaitForCallsStatusParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useWaitForCallsStatus } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useWaitForCallsStatus({ + config, // [!code focus] + id: '0x...', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +Connector to get call statuses with. + +::: code-group +```tsx [index.tsx] +import { useWaitForCallsStatus, useConnections } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const connections = useConnections() + const result = useWaitForCallsStatus({ + connector: connections[0]?.connector, // [!code focus] + id: '0x...', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### id + +`string` + +Identifier of the call batch. + +::: code-group +```ts [index.ts] +import { useWaitForCallsStatus } from '@wagmi/core' +import { config } from './config' + +const status = await useWaitForCallsStatus({ + id: '0x1234567890abcdef', // [!code focus] +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### pollingInterval + +`number | undefined` + +Polling interval in milliseconds. + +::: code-group +```ts [index.ts] +import { useWaitForCallsStatus } from '@wagmi/core' +import { config } from './config' + +const status = await useWaitForCallsStatus({ + id: '0x1234567890abcdef', + pollingInterval: 1_000, // [!code focus] +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```tsx [index.tsx] +import { useWaitForCallsStatus } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useWaitForCallsStatus({ + id: '0x...', + scopeKey: 'foo', // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### timeout + +`number | undefined` + +Timeout in milliseconds. + +::: code-group +```ts [index.ts] +import { useWaitForCallsStatus } from '@wagmi/core' +import { config } from './config' + +const status = await useWaitForCallsStatus({ + id: '0x1234567890abcdef', + timeout: 10_000, // [!code focus] +}) +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseWaitForCallsStatusReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`waitForCallsStatus`](https://viem.sh/experimental/eip5792/waitForCallsStatus) \ No newline at end of file diff --git a/site/react/api/hooks/useWaitForTransactionReceipt.md b/site/react/api/hooks/useWaitForTransactionReceipt.md new file mode 100644 index 0000000000..78dbe7bc54 --- /dev/null +++ b/site/react/api/hooks/useWaitForTransactionReceipt.md @@ -0,0 +1,168 @@ +--- +title: useWaitForTransactionReceipt +description: Hook that waits for the transaction to be included on a block, and then returns the transaction receipt. If the transaction reverts, then the action will throw an error. Replacement detection (e.g. sped up transactions) is also supported. +--- + + + +# useWaitForTransactionReceipt + +Hook that waits for the transaction to be included on a block, and then returns the transaction receipt. If the transaction reverts, then the action will throw an error. Replacement detection (e.g. sped up transactions) is also supported. + +## Import + +```ts +import { useWaitForTransactionReceipt } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useWaitForTransactionReceipt } from 'wagmi' + +function App() { + const result = useWaitForTransactionReceipt({ + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseWaitForTransactionReceiptParameters } from 'wagmi' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +```ts [index.ts] +import { useWaitForTransactionReceipt } from 'wagmi' +import { mainnet } from 'wagmi/chains' + +function App() { + const result = useWaitForTransactionReceipt({ + chainId: mainnet.id, // [!code focus] + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', + }) +} +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useWaitForTransactionReceipt } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useWaitForTransactionReceipt({ + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### confirmations + +`number | undefined` + +The number of confirmations (blocks that have passed) to wait before resolving. + +```ts [index.ts] +import { useWaitForTransactionReceipt } from 'wagmi' + +function App() { + const result = useWaitForTransactionReceipt({ + confirmations: 2, // [!code focus] + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', + }) +} +``` + +### onReplaced + +` +(({ reason: 'replaced' | 'repriced' | 'cancelled'; replacedTransaction: Transaction; transaction: Transaction; transactionReceipt: TransactionReceipt }) => void) | undefined +` + +Optional callback to emit if the transaction has been replaced. + +```ts [index.ts] +import { useWaitForTransactionReceipt } from 'wagmi' + +function App() { + const result = useWaitForTransactionReceipt({ + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', + onReplaced: replacement => console.log(replacement), // [!code focus] + }) +} +``` + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/react/api/createConfig#pollinginterval). + +```ts [index.ts] +import { useWaitForTransactionReceipt } from 'wagmi' + +function App() { + const result = useWaitForTransactionReceipt({ + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', + pollingInterval: 1_000, // [!code focus] + }) +} +``` + +### hash + +`` `0x${string}` | undefined `` + +The transaction hash to wait for. [`enabled`](#enabled) set to `false` if `hash` is `undefined`. + +```ts [index.ts] +import { useWaitForTransactionReceipt } from 'wagmi' + +function App() { + const result = useWaitForTransactionReceipt({ + hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d', // [!code focus] + }) +} +``` + + + +## Return Type + +```ts +import { type UseWaitForTransactionReceiptReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`waitForTransactionReceipt`](/core/api/actions/waitForTransactionReceipt) diff --git a/site/react/api/hooks/useWalletClient.md b/site/react/api/hooks/useWalletClient.md new file mode 100644 index 0000000000..e6ee792c25 --- /dev/null +++ b/site/react/api/hooks/useWalletClient.md @@ -0,0 +1,132 @@ +--- +title: useWalletClient +description: Hook for getting a Viem `WalletClient` object for the current or provided connector. +--- + + + +# useWalletClient + +Hook for getting a Viem [`WalletClient`](https://viem.sh/docs/clients/wallet.html) object for the current or provided connector. + +## Import + +```ts +import { useWalletClient } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useWalletClient } from 'wagmi' + +function App() { + const result = useWalletClient() +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +::: warning +If you want to optimize bundle size, you should use [`useConnectorClient`](/react/api/hooks/useConnectorClient) along with Viem's [tree-shakable actions](https://viem.sh/docs/clients/custom.html#tree-shaking) instead. Since Wallet Client has all wallet actions attached directly to it. +::: + +## Parameters + +```ts +import { type UseWalletClientParameters } from 'wagmi' +``` + +### account + +`Address | Account | undefined` + +Account to use with client. Throws if account is not found on [`connector`](#connector). + +```ts +import { useWalletClient } from 'wagmi' + +function App() { + const result = useWalletClient({ + account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus] + }) +} +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use with client. + +```ts +import { useWalletClient } from 'wagmi' + +function App() { + const result = useWalletClient({ + chainId: mainnet.id, // [!code focus] + }) +} +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useWalletClient } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useWalletClient({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +- Connector to get client for. +- Defaults to current connector. + +```ts +import { useConnections, useWalletClient } from 'wagmi' + +function App() { + const connections = useConnections(config) + const result = useWalletClient({ + connector: connections[0]?.connector, // [!code focus] + }) +} +``` + + + +## Return Type + +```ts +import { type UseWalletClientReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`getWalletClient`](/core/api/actions/getWalletClient) diff --git a/site/react/api/hooks/useWatchAsset.md b/site/react/api/hooks/useWatchAsset.md new file mode 100644 index 0000000000..03f756d569 --- /dev/null +++ b/site/react/api/hooks/useWatchAsset.md @@ -0,0 +1,94 @@ +--- +title: useWatchAsset +description: Hook for requesting user tracks the token in their wallet. Returns a boolean indicating if the token was successfully added. +--- + + + +# useWatchAsset + +Hook for requesting user tracks the token in their wallet. Returns a boolean indicating if the token was successfully added. + +## Import + +```ts +import { useWatchAsset } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useWatchAsset } from 'wagmi' + +function App() { + const { watchAsset } = useWatchAsset() + + return ( + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseWatchAssetParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useWatchAsset } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useWatchAsset({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseWatchAssetReturnType } from 'wagmi' +``` + + + + + +## Action + +- [`watchAsset`](/core/api/actions/watchAsset) diff --git a/site/react/api/hooks/useWatchBlockNumber.md b/site/react/api/hooks/useWatchBlockNumber.md new file mode 100644 index 0000000000..925dddfc1a --- /dev/null +++ b/site/react/api/hooks/useWatchBlockNumber.md @@ -0,0 +1,276 @@ +--- +title: useWatchBlockNumber +description: Hook that watches for block number changes. +--- + +# useWatchBlockNumber + +Hook that watches for block number changes. + +## Import + +```ts +import { useWatchBlockNumber } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useWatchBlockNumber } from 'wagmi' + +function App() { + useWatchBlockNumber({ + onBlockNumber(blockNumber) { + console.log('Block number changed!', blockNumber) + }, + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseWatchBlockNumberParameters } from 'wagmi' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to watch blocks at. + +::: code-group +```ts [index.ts] +import { useWatchBlockNumber } from 'wagmi' + +function App() { + useWatchBlockNumber({ + chainId: 1, // [!code focus] + onBlockNumber(blockNumber) { + console.log('New block number', blockNumber) + }, + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```ts [index.ts] +import { useWatchBlockNumber } from 'wagmi' +import { config } from './config' + +function App() { + useWatchBlockNumber({ + config, // [!code focus] + onBlockNumber(blockNumber) { + console.log('New block number', blockNumber) + }, + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### emitMissed + +`boolean` + +Whether or not to emit missed blocks to the callback. Defaults to `false`. + +Missed blocks may occur in instances where internet connection is lost, or the block time is lesser than the polling interval of the client. + +::: code-group +```ts [index.ts] +import { useWatchBlockNumber } from 'wagmi' + +function App() { + useWatchBlockNumber({ + emitMissed: true, // [!code focus] + onBlockNumber(blockNumber) { + console.log('New block number', blockNumber) + }, + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### emitOnBegin + +`boolean` + +Whether or not to emit the block to the callback when the subscription opens. Defaults to `false`. + +::: code-group +```ts [index.ts] +import { useWatchBlockNumber } from 'wagmi' + +function App() { + useWatchBlockNumber({ + emitOnBegin: true, // [!code focus] + onBlockNumber(blockNumber) { + console.log('New block number', blockNumber) + }, + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### enabled + +`boolean` + +Whether or not to watch for blocks. Defaults to `true`. + +::: code-group +```ts [index.ts] +import { useWatchBlockNumber } from 'wagmi' + +function App() { + useWatchBlockNumber({ + enabled: false, // [!code focus] + onBlockNumber(blockNumber) { + console.log('New block number', blockNumber) + }, + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### onBlockNumber + +`(block: Block, prevblock: Block | undefined) => void` + +Callback for when block changes. + +::: code-group +```ts [index.ts] +import { useWatchBlockNumber } from 'wagmi' + +function App() { + useWatchBlockNumber({ + onBlockNumber(blockNumber) { // [!code focus] + console.log('New block number', blockNumber) // [!code focus] + }, // [!code focus] + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### onError + +`((error: Error) => void) | undefined` + +Error thrown from getting the block. + +::: code-group +```ts [index.ts] +import { useWatchBlockNumber } from 'wagmi' + +function App() { + useWatchBlockNumber({ + onBlockNumber(blockNumber) { + console.log('New block number', blockNumber) + }, + onError(error) { // [!code focus] + console.error('Block error', error) // [!code focus] + }, // [!code focus] + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### poll + +`boolean | undefined` + +- Whether or not to use a polling mechanism to check for new blocks instead of a WebSocket subscription. +- Defaults to `false` for WebSocket Clients, and `true` for non-WebSocket Clients. + +::: code-group +```ts [index.ts] +import { useWatchBlockNumber } from 'wagmi' + +function App() { + useWatchBlockNumber({ + onBlockNumber(blockNumber) { + console.log('New block number', blockNumber) + } + poll: true, // [!code focus] + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/core/api/createConfig#pollinginterval). + +::: code-group +```ts [index.ts] +import { useWatchBlockNumber } from 'wagmi' + +function App() { + useWatchBlockNumber({ + onBlockNumber(blockNumber) { + console.log('New block number', blockNumber) + } + pollingInterval: 1_000, // [!code focus] + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### syncConnectedChain + +`boolean | undefined` + +- Set up subscriber for connected chain changes. +- Defaults to [`Config['syncConnectedChain']`](/core/api/createConfig#syncconnectedchain). + +::: code-group +```ts [index.ts] +import { useWatchBlockNumber } from 'wagmi' + +function App() { + useWatchBlockNumber({ + onBlockNumber(blockNumber) { + console.log('New block number', blockNumber) + } + syncConnectedChain: false, // [!code focus] + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseWatchBlockNumberReturnType } from 'wagmi' +``` + +Function for cleaning up watcher. + +## Action + +- [`watchBlockNumber`](/core/api/actions/watchBlockNumber) diff --git a/site/react/api/hooks/useWatchBlocks.md b/site/react/api/hooks/useWatchBlocks.md new file mode 100644 index 0000000000..ec2b17326c --- /dev/null +++ b/site/react/api/hooks/useWatchBlocks.md @@ -0,0 +1,318 @@ +--- +title: useWatchBlocks +description: Hook that watches for block changes. +--- + +# useWatchBlocks + +Hook that watches for block changes. + +## Import + +```ts +import { useWatchBlocks } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useWatchBlocks } from 'wagmi' + +function App() { + useWatchBlocks({ + onBlock(block) { + console.log('New block', block.number) + }, + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseWatchBlocksParameters } from 'wagmi' +``` + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to watch blocks at. + +::: code-group +```ts [index.ts] +import { useWatchBlocks } from 'wagmi' + +function App() { + useWatchBlocks({ + blockTag: 'latest', // [!code focus] + onBlock(block) { + console.log('New block', block.number) + }, + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to watch blocks at. + +::: code-group +```ts [index.ts] +import { useWatchBlocks } from 'wagmi' + +function App() { + useWatchBlocks({ + chainId: 1, // [!code focus] + onBlock(block) { + console.log('New block', block.number) + }, + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```ts [index.ts] +import { useWatchBlocks } from 'wagmi' +import { config } from './config' + +function App() { + useWatchBlocks({ + config, // [!code focus] + onBlock(block) { + console.log('New block', block.number) + }, + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### emitMissed + +`boolean` + +Whether or not to emit missed blocks to the callback. Defaults to `false`. + +Missed blocks may occur in instances where internet connection is lost, or the block time is lesser than the polling interval of the client. + +::: code-group +```ts [index.ts] +import { useWatchBlocks } from 'wagmi' + +function App() { + useWatchBlocks({ + emitMissed: true, // [!code focus] + onBlock(block) { + console.log('New block', block.number) + }, + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### emitOnBegin + +`boolean` + +Whether or not to emit the block to the callback when the subscription opens. Defaults to `false`. + +::: code-group +```ts [index.ts] +import { useWatchBlocks } from 'wagmi' + +function App() { + useWatchBlocks({ + emitOnBegin: true, // [!code focus] + onBlock(block) { + console.log('New block', block.number) + }, + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### enabled + +`boolean` + +Whether or not to watch for blocks. Defaults to `true`. + +::: code-group +```ts [index.ts] +import { useWatchBlocks } from 'wagmi' + +function App() { + useWatchBlocks({ + enabled: false, // [!code focus] + onBlock(block) { + console.log('New block', block.number) + }, + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### includeTransactions + +`boolean` + +Whether or not to unwrap transactions as objects (instead of hashes) in blocks. Defaults to `false`. + +::: code-group +```ts [index.ts] +import { useWatchBlocks } from 'wagmi' + +function App() { + useWatchBlocks({ + includeTransactions: true, // [!code focus] + onBlock(block) { + console.log('New block', block.number) + }, + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### onBlock + +`(block: Block, prevblock: Block | undefined) => void` + +Callback for when block changes. + +::: code-group +```ts [index.ts] +import { useWatchBlocks } from 'wagmi' + +function App() { + useWatchBlocks({ + onBlock(block) { // [!code focus] + console.log('New block', block.number) // [!code focus] + }, // [!code focus] + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### onError + +`((error: Error) => void) | undefined` + +Error thrown from getting the block. + +::: code-group +```ts [index.ts] +import { useWatchBlocks } from 'wagmi' + +function App() { + useWatchBlocks({ + onBlock(block) { + console.log('New block', block.number) + }, + onError(error) { // [!code focus] + console.error('Block error', error) // [!code focus] + }, // [!code focus] + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### poll + +`boolean | undefined` + +- Whether or not to use a polling mechanism to check for new blocks instead of a WebSocket subscription. +- Defaults to `false` for WebSocket Clients, and `true` for non-WebSocket Clients. + +::: code-group +```ts [index.ts] +import { useWatchBlocks } from 'wagmi' + +function App() { + useWatchBlocks({ + onBlock(block) { + console.log('New block', block.number) + } + poll: true, // [!code focus] + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/core/api/createConfig#pollinginterval). + +::: code-group +```ts [index.ts] +import { useWatchBlocks } from 'wagmi' + +function App() { + useWatchBlocks({ + onBlock(block) { + console.log('New block', block.number) + } + pollingInterval: 1_000, // [!code focus] + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +### syncConnectedChain + +`boolean | undefined` + +- Set up subscriber for connected chain changes. +- Defaults to [`Config['syncConnectedChain']`](/core/api/createConfig#syncconnectedchain). + +::: code-group +```ts [index.ts] +import { useWatchBlocks } from 'wagmi' + +function App() { + useWatchBlocks({ + onBlock(block) { + console.log('New block', block.number) + } + syncConnectedChain: false, // [!code focus] + }) +} +``` +<<< @/snippets/core/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseWatchBlocksReturnType } from 'wagmi' +``` + +## Action + +- [`watchBlocks`](/core/api/actions/watchBlocks) diff --git a/site/react/api/hooks/useWatchContractEvent.md b/site/react/api/hooks/useWatchContractEvent.md new file mode 100644 index 0000000000..1bdcfb2622 --- /dev/null +++ b/site/react/api/hooks/useWatchContractEvent.md @@ -0,0 +1,413 @@ +--- +title: useWatchContractEvent +description: Hook that watches and returns emitted contract event logs. +--- + +# useWatchContractEvent + +Hook that watches and returns emitted contract event logs. + +## Import + +```ts +import { useWatchContractEvent } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseWatchContractEventParameters } from 'wagmi' +``` + +### abi + +`Abi` + +The contract's ABI. Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, // [!code focus] + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### address + +`Address | undefined` + +The contract's address. + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', // [!code focus] + abi, + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### args + +`object | readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`eventName`](#eventname). + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + args: { // [!code focus] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B' // [!code focus] + } // [!code focus] + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### batch + +`boolean | undefined` + +- Whether or not the events should be batched on each invocation. +- Defaults to `true`. + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + batch: false, // [!code focus] + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + chainId: 1, // [!code focus] + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' +import { config } from './config' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + config, // [!code focus] + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### eventName + +`string` + +- Event to listen for the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' +import { config } from './config' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + eventName: 'Transfer', // [!code focus] + onLogs(logs) { + console.log('New logs!', logs) + }, + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### onError + +`((error: Error) => void) | undefined` + +Error thrown from getting the block number. + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, + onError(error) { // [!code focus] + console.log('Error', error) // [!code focus] + } // [!code focus] + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### onLogs + +`(logs: Log[], prevLogs: Log[] | undefined) => void` + +Callback for when logs changes. + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + eventName: 'Transfer', + onLogs(logs) { // [!code focus] + console.log('New logs!', logs) // [!code focus] + } // [!code focus] + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### poll + +`boolean | undefined` + +- Whether or not to use a polling mechanism to check for new blocks instead of a WebSocket subscription. +- Defaults to `false` for WebSocket Clients, and `true` for non-WebSocket Clients. + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, + poll: true // [!code focus] + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/core/api/createConfig#pollinginterval). + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, + pollingInterval: 1_000 // [!code focus] + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### strict + +`boolean | undefined` + +- Defaults to `false`. + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, + strict: true // [!code focus] + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +### syncConnectedChain + +`boolean | undefined` + +- Set up subscriber for connected chain changes. +- Defaults to [`Config['syncConnectedChain']`](/core/api/createConfig#syncconnectedchain). + +::: code-group +```tsx [index.tsx] +import { useWatchContractEvent } from 'wagmi' +import { abi } from './abi' + +function App() { + useWatchContractEvent({ + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + abi, + eventName: 'Transfer', + onLogs(logs) { + console.log('New logs!', logs) + }, + syncConnectedChain: true // [!code focus] + }) +} +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseWatchContractEventReturnType } from 'wagmi' +``` + +Hook returns `void` + +## Action + +- [`watchContractEvent`](/core/api/actions/watchContractEvent) diff --git a/site/react/api/hooks/useWatchPendingTransactions.md b/site/react/api/hooks/useWatchPendingTransactions.md new file mode 100644 index 0000000000..0bfbb8136d --- /dev/null +++ b/site/react/api/hooks/useWatchPendingTransactions.md @@ -0,0 +1,229 @@ +--- +title: useWatchPendingTransactions +description: Hook that watches and returns pending transaction hashes. +--- + +# useWatchPendingTransactions + +Hook that watches and returns pending transaction hashes. + +## Import + +```ts +import { useWatchPendingTransactions } from 'wagmi' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useWatchPendingTransactions } from 'wagmi' + +function App() { + useWatchPendingTransactions({ + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseWatchPendingTransactionsParameters } from 'wagmi' +``` + +### batch + +`boolean | undefined` + +- Whether or not the transactions should be batched on each invocation. +- Defaults to `true`. + +::: code-group +```tsx [index.tsx] +import { useWatchPendingTransactions } from 'wagmi' + +function App() { + useWatchPendingTransactions({ + batch: true // [!code focus] + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```tsx [index.tsx] +import { useWatchPendingTransactions } from 'wagmi' + +function App() { + useWatchPendingTransactions({ + chainId: 1 // [!code focus] + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useWatchPendingTransactions } from 'wagmi' +import { config } from './config' + +function App() { + useWatchPendingTransactions({ + config // [!code focus] + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### onError + +`((error: Error) => void) | undefined` + +Error thrown from watching pending transactions. + +::: code-group +```tsx [index.tsx] +import { useWatchPendingTransactions } from 'wagmi' + +function App() { + useWatchPendingTransactions({ + onError(error) { // [!code focus] + console.log('Error', error) // [!code focus] + }, // [!code focus] + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### onTransactions + +`(transactions: Hash[], prevTransactions: Hash[] | undefined) => void` + +Callback when new incoming pending transactions are detected. + +::: code-group +```tsx [index.tsx] +import { useWatchPendingTransactions } from 'wagmi' + +function App() { + useWatchPendingTransactions({ + onTransactions(transactions) { // [!code focus] + console.log('New transactions!', transactions) // [!code focus] + }, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### poll + +`boolean | undefined` + +- Whether or not to use a polling mechanism to check for new pending transactions instead of a WebSocket subscription. +- Defaults to `false` for WebSocket Clients, and `true` for non-WebSocket Clients. + +::: code-group +```tsx [index.tsx] +import { useWatchPendingTransactions } from 'wagmi' + +function App() { + useWatchPendingTransactions({ + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, + poll: true, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/core/api/createConfig#pollinginterval). + +::: code-group +```tsx [index.tsx] +import { useWatchPendingTransactions } from 'wagmi' + +function App() { + useWatchPendingTransactions({ + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, + pollingInterval: 1_000, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### syncConnectedChain + +`boolean | undefined` + +- Set up subscriber for connected chain changes. +- Defaults to [`Config['syncConnectedChain']`](/core/api/createConfig#syncconnectedchain). + +::: code-group +```tsx [index.tsx] +import { useWatchPendingTransactions } from 'wagmi' + +function App() { + useWatchPendingTransactions({ + onTransactions(transactions) { + console.log('New transactions!', transactions) + }, + syncConnectedChain: false, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseWatchPendingTransactionsReturnType } from 'wagmi' +``` + +## Action + +- [`watchPendingTransactions`](/core/api/actions/watchPendingTransactions) diff --git a/site/react/api/hooks/useWriteContract.md b/site/react/api/hooks/useWriteContract.md new file mode 100644 index 0000000000..bc575ce88b --- /dev/null +++ b/site/react/api/hooks/useWriteContract.md @@ -0,0 +1,116 @@ +--- +title: useWriteContract +description: Action for executing a write function on a contract. +--- + + + +# useWriteContract + +Action for executing a write function on a contract. + +A "write" function on a Solidity contract modifies the state of the blockchain. These types of functions require gas to be executed, hence a transaction is broadcasted in order to change the state. + +## Import + +```ts +import { useWriteContract } from 'wagmi' +``` + +## Usage + +::: code-group + +```tsx [index.tsx] +import { useWriteContract } from 'wagmi' +import { abi } from './abi' + +function App() { + const { writeContract } = useWriteContract() + + return ( + + ) +} +``` + +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/react/config.ts[config.ts] +::: + + + + + +## Parameters + +```ts +import { type UseWriteContractParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group + +```tsx [index.tsx] +import { useWriteContract } from 'wagmi' +import { config } from './config' // [!code focus] + +function App() { + const result = useWriteContract({ + config, // [!code focus] + }) +} +``` + +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseWriteContractReturnType } from 'wagmi' +``` + +The return type's [`data`](#data) property is inferrable via the combination of [`abi`](#abi), [`functionName`](#functionname), and [`args`](#args). Check out the [TypeScript docs](/react/typescript#const-assert-abis-typed-data) for more info. + + + +## Type Inference + +With [`abi`](/core/api/actions/writeContract#abi) setup correctly, TypeScript will infer the correct types for [`functionName`](/core/api/actions/writeContract#functionname), [`args`](/core/api/actions/writeContract#args), and the [`value`](/core/api/actions/writeContract##value). See the Wagmi [TypeScript docs](/react/typescript) for more information. + + + +## Action + +- [`writeContract`](/core/api/actions/writeContract) diff --git a/site/react/api/hooks/useWriteContracts.md b/site/react/api/hooks/useWriteContracts.md new file mode 100644 index 0000000000..0e8e94aa79 --- /dev/null +++ b/site/react/api/hooks/useWriteContracts.md @@ -0,0 +1,119 @@ +--- +title: useWriteContracts +description: Hook that requests for the wallet to sign and broadcast a batch of calls (transactions) to the network. +--- + + + +# useWriteContracts + +Hook that requests for the wallet to sign and broadcast a batch of write contract calls (transactions) to the network. + +[Read more.](https://github.com/ethereum/EIPs/blob/815028dc634463e1716fc5ce44c019a6040f0bef/EIPS/eip-5792.md#wallet_sendcalls) + +## Import + +```ts +import { useWriteContracts } from 'wagmi/experimental' +``` + +## Usage + +::: code-group +```tsx [index.tsx] +import { useWriteContracts } from 'wagmi/experimental' +import { parseAbi } from 'viem' + +const abi = parseAbi([ + 'function approve(address, uint256) returns (bool)', + 'function transferFrom(address, address, uint256) returns (bool)', +]) + +function App() { + const { writeContracts } = useWriteContracts() + + return ( + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseWriteContractsParameters } from 'wagmi/experimental' +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```tsx [index.tsx] +import { useWriteContracts } from 'wagmi/experimental' +import { config } from './config' // [!code focus] + +function App() { + const result = useWriteContracts({ + config, // [!code focus] + }) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseWriteContractsReturnType } from 'wagmi/experimental' +``` + + + + + +## Action + +- [`writeContracts`](/core/api/actions/writeContracts) diff --git a/site/react/api/transports.md b/site/react/api/transports.md new file mode 100644 index 0000000000..5620b3c115 --- /dev/null +++ b/site/react/api/transports.md @@ -0,0 +1,28 @@ + + +# Transports + +[`createConfig`](/react/api/createConfig) can be instantiated with a set of Transports for each chain. A Transport is the intermediary layer that is responsible for executing outgoing JSON-RPC requests to the RPC Provider (e.g. Alchemy, Infura, etc). + +## Import + +```ts +import { http } from 'wagmi' +``` + +## Built-In Transports + +Available via the `'wagmi'` entrypoint. + + diff --git a/site/react/api/transports/custom.md b/site/react/api/transports/custom.md new file mode 100644 index 0000000000..d2ba5de554 --- /dev/null +++ b/site/react/api/transports/custom.md @@ -0,0 +1,5 @@ + + + diff --git a/site/react/api/transports/fallback.md b/site/react/api/transports/fallback.md new file mode 100644 index 0000000000..cffcd08f05 --- /dev/null +++ b/site/react/api/transports/fallback.md @@ -0,0 +1,5 @@ + + + diff --git a/site/react/api/transports/http.md b/site/react/api/transports/http.md new file mode 100644 index 0000000000..31d80d8a8d --- /dev/null +++ b/site/react/api/transports/http.md @@ -0,0 +1,5 @@ + + + diff --git a/site/react/api/transports/unstable_connector.md b/site/react/api/transports/unstable_connector.md new file mode 100644 index 0000000000..008b9aa3d4 --- /dev/null +++ b/site/react/api/transports/unstable_connector.md @@ -0,0 +1,6 @@ + + + diff --git a/site/react/api/transports/webSocket.md b/site/react/api/transports/webSocket.md new file mode 100644 index 0000000000..6eacdaabed --- /dev/null +++ b/site/react/api/transports/webSocket.md @@ -0,0 +1,5 @@ + + + diff --git a/site/react/api/utilities/cookieToInitialState.md b/site/react/api/utilities/cookieToInitialState.md new file mode 100644 index 0000000000..98363c60e6 --- /dev/null +++ b/site/react/api/utilities/cookieToInitialState.md @@ -0,0 +1,5 @@ + + + diff --git a/site/react/api/utilities/deserialize.md b/site/react/api/utilities/deserialize.md new file mode 100644 index 0000000000..24e9aa22c4 --- /dev/null +++ b/site/react/api/utilities/deserialize.md @@ -0,0 +1,5 @@ + + + diff --git a/site/react/api/utilities/normalizeChainId.md b/site/react/api/utilities/normalizeChainId.md new file mode 100644 index 0000000000..deceae7a4e --- /dev/null +++ b/site/react/api/utilities/normalizeChainId.md @@ -0,0 +1,5 @@ + + + diff --git a/site/react/api/utilities/serialize.md b/site/react/api/utilities/serialize.md new file mode 100644 index 0000000000..9ff2ff3225 --- /dev/null +++ b/site/react/api/utilities/serialize.md @@ -0,0 +1,5 @@ + + + diff --git a/site/react/comparisons.md b/site/react/comparisons.md new file mode 100644 index 0000000000..8c614ed552 --- /dev/null +++ b/site/react/comparisons.md @@ -0,0 +1,90 @@ +# Comparison + +There are multiple options when it comes to React libraries for Ethereum that help manage wallet connections, provide utility methods/hooks, etc. + +::: tip +Comparisons strive to be as accurate and as unbiased as possible. If you use any of these libraries and feel the information could be improved, feel free to suggest changes. +::: + +## Overview + +| | [wagmi](https://github.com/wagmi-dev/wagmi) | [web3-react](https://github.com/NoahZinsmeister/web3-react) | [useDApp](https://github.com/EthWorks/useDApp) | +| -------------------- | :---------------------------------------------------------------------------------------------- | :------------------------------------------------------------------------------------------------------ | :------------------------------------------------------------------------------------------------- | +| GitHub Stars | ![wagmi star count](https://img.shields.io/github/stars/wagmi-dev/wagmi?colorB=27292E&label=) | ![web3-react star count](https://img.shields.io/github/stars/Uniswap/web3-react?colorB=27292E&label=) | ![useDApp star count](https://img.shields.io/github/stars/EthWorks/useDApp?colorB=27292E&label=) | +| Open Issues | ![wagmi issue count](https://img.shields.io/github/issues/wagmi-dev/wagmi?colorB=27292E&label=) | ![web3-react issue count](https://img.shields.io/github/issues/Uniswap/web3-react?colorB=27292E&label=) | ![useDApp issue count](https://img.shields.io/github/issues/EthWorks/useDApp?colorB=27292E&label=) | +| Downloads | ![wagmi downloads](https://img.shields.io/npm/dw/wagmi?colorB=27292E&label=) | ![web3-react downloads](https://img.shields.io/npm/dw/@web3-react/core?colorB=27292E&label=) | ![useDApp downloads](https://img.shields.io/npm/dw/@usedapp/core?colorB=27292E&label=) | +| License | ![wagmi license](https://img.shields.io/github/license/wagmi-dev/wagmi?colorB=27292E&label=) | ![web3-react license](https://img.shields.io/github/license/Uniswap/web3-react?colorB=27292E&label=) | ![useDApp license](https://img.shields.io/github/license/EthWorks/useDApp?colorB=27292E&label=) | +| Their Comparison | – | none | none | +| Supported Frameworks | React, Vanilla JS | React | React | +| Documentation | ✅ | 🛑 | ✅ | +| TypeScript | ✅ | 🔶 | 🔶 | +| EIP-6963 Support | ✅ | 🔴 | 🔴 | +| Test Suite | ✅ | 🔶 | 🔶 | +| Examples | ✅ | 🔶 | ✅ | + +::: details Comparison Key + +1. Documentation + - Comprehensive documentation for all library features ✅ + - No documentation 🔴 +2. Typescript + - Infer types from ABIs, EIP-712 Typed Data, etc. ✅ + - Can add types with explicit generics, type annotations, etc. 🔶 +3. Test Suite + - Runs against forked Ethereum network(s) ✅ + - Mocking functionality (i.e. RPC calls) is 🔶 +4. EIP-6963 Support + - Fully compatible with EIP-6963 ✅ + - Not compatible with EIP-6963 🔴 +5. Examples + - Has multiple examples ✅ + - Has single example 🔶 +::: + +## [Wagmi](https://github.com/wagmi-dev/wagmi) + +### Pros + +- 20+ hooks for working with wallets, ENS, contracts, transactions, signing, etc. +- Built-in wallet connectors for injected providers (EIP-6963 support), WalletConnect, MetaMask, Coinbase Wallet +- Caching, request deduplication, and persistence powered by TanStack Query +- Auto-refresh data on wallet, block, and network changes +- Multicall support +- Test suite running against forked Ethereum networks +- TypeScript ready (infer types from ABIs and EIP-712 Typed Data) +- Extensive documentation and examples +- Used by Coinbase, Stripe, Shopify, Uniswap, Optimism, ENS, Sushi, and [many more](https://github.com/wagmi-dev/wagmi/discussions/201) +- MIT License + +### Cons + +- Not as many built-in connectors as `web3-react` + +## [web3-react](https://github.com/Uniswap/web3-react) + +### Pros + +- Supports many different connectors (conceptually similar to Wagmi's connectors) +- Basic hooks for managing account + +### Cons + +- Need to set up connectors and method for connecting wallet on your own +- Need to install connectors separately +- Almost no tests or documentation; infrequent updates +- GPL-3.0 License + +## [useDApp](https://github.com/EthWorks/useDApp) + +### Pros + +- Auto-refresh on new blocks and wallet changes +- Multicall support +- Transaction notifications +- Chrome extension and Firefox add-on +- MIT License + +### Cons + +- Non-standard hook API + diff --git a/site/react/getting-started.md b/site/react/getting-started.md new file mode 100644 index 0000000000..3e4111cb49 --- /dev/null +++ b/site/react/getting-started.md @@ -0,0 +1,214 @@ + + +# Getting Started + +## Overview + +Wagmi is a React Hooks library for Ethereum. You can learn more about the rationale behind the project in the [Why Wagmi](/react/why) section. + +## Automatic Installation + +For new projects, it is recommended to set up your Wagmi app using the [`create-wagmi`](/cli/create-wagmi) command line interface (CLI). This will create a new Wagmi project using TypeScript and install the required dependencies. + +::: code-group +```bash [pnpm] +pnpm create wagmi +``` + +```bash [npm] +npm create wagmi@latest +``` + +```bash [yarn] +yarn create wagmi +``` + +```bash [bun] +bun create wagmi +``` +::: + +Once the command runs, you'll see some prompts to complete. + +```ansi +Project name: wagmi-project +Select a framework: React / Vanilla +... +``` + +After the prompts, `create-wagmi` will create a directory with your project name and install the required dependencies. Check out the `README.md` for further instructions (if required). + +## Manual Installation + +To manually add Wagmi to your project, install the required packages. + +::: code-group +```bash-vue [pnpm] +pnpm add wagmi viem@{{viemVersion}} @tanstack/react-query +``` + +```bash-vue [npm] +npm install wagmi viem@{{viemVersion}} @tanstack/react-query +``` + +```bash-vue [yarn] +yarn add wagmi viem@{{viemVersion}} @tanstack/react-query +``` + +```bash-vue [bun] +bun add wagmi viem@{{viemVersion}} @tanstack/react-query +``` +::: + +- [Viem](https://viem.sh) is a TypeScript interface for Ethereum that performs blockchain operations. +- [TanStack Query](https://tanstack.com/query/v5) is an async state manager that handles requests, caching, and more. +- [TypeScript](/react/typescript) is optional, but highly recommended. Learn more about [TypeScript support](/react/typescript). + +### Create Config + +Create and export a new Wagmi config using `createConfig`. + +::: code-group +<<< @/snippets/react/config.ts[config.ts] +::: + +In this example, Wagmi is configured to use the Mainnet and Sepolia chains, and `injected` connector. Check out the [`createConfig` docs](/react/api/createConfig) for more configuration options. + + +::: details TypeScript Tip +If you are using TypeScript, you can "register" the Wagmi config or use the hook `config` property to get strong type-safety across React Context in places that wouldn't normally have type info. + +::: code-group +```ts twoslash [register config] +// @errors: 2322 +import { type Config } from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' + +declare const config: Config +// ---cut--- +import { useBlockNumber } from 'wagmi' + +useBlockNumber({ chainId: 123 }) + +declare module 'wagmi' { + interface Register { + config: typeof config + } +} +``` + +```ts twoslash [hook config property] +// @errors: 2322 +import { type Config } from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' + +declare const config: Config +// ---cut--- +import { useBlockNumber } from 'wagmi' + +useBlockNumber({ chainId: 123, config }) +``` + +By registering or using the hook `config` property, `useBlockNumber`'s `chainId` is strongly typed to only allow Mainnet and Sepolia IDs. Learn more by reading the [TypeScript docs](/react/typescript#config-types). +::: + +### Wrap App in Context Provider + +Wrap your app in the `WagmiProvider` React Context Provider and pass the `config` you created earlier to the `config` property. + +::: code-group +```tsx [app.tsx] +import { WagmiProvider } from 'wagmi' // [!code focus] +import { config } from './config' // [!code focus] + +function App() { + return ( + // [!code focus] + {/** ... */} // [!code focus] + // [!code focus] + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +Check out the [`WagmiProvider` docs](/react/api/WagmiProvider) to learn more about React Context in Wagmi. + +### Setup TanStack Query + +Inside the `WagmiProvider`, wrap your app in a TanStack Query React Context Provider, e.g. `QueryClientProvider`, and pass a new `QueryClient` instance to the `client` property. + +::: code-group +```tsx [app.tsx] +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' // [!code focus] +import { WagmiProvider } from 'wagmi' +import { config } from './config' + +const queryClient = new QueryClient() // [!code focus] + +function App() { + return ( + + // [!code focus] + {/** ... */} // [!code focus] + // [!code focus] + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +Check out the [TanStack Query docs](https://tanstack.com/query/latest/docs/framework/react) to learn about the library, APIs, and more. + +### Use Wagmi + +Now that everything is set up, every component inside the Wagmi and TanStack Query Providers can use Wagmi React Hooks. + +::: code-group +```tsx [profile.tsx] +import { useAccount, useEnsName } from 'wagmi' + +export function Profile() { + const { address } = useAccount() + const { data, error, status } = useEnsName({ address }) + if (status === 'pending') return
Loading ENS name
+ if (status === 'error') + return
Error fetching ENS name: {error.message}
+ return
ENS name: {data}
+} +``` + +```tsx [app.tsx] +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import { WagmiProvider } from 'wagmi' +import { config } from './config' +import { Profile } from './profile' + +const queryClient = new QueryClient() + +function App() { + return ( + + + + + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Next Steps + +For more information on what to do next, check out the following topics. + +- [**TypeScript**](/react/typescript) Learn how to get the most out of Wagmi's type-safety and inference for an enlightened developer experience. +- [**Connect Wallet**](/react/guides/connect-wallet) Learn how to enable wallets to connect to and disconnect from your apps and display information about connected accounts. +- [**React Hooks**](/react/api/hooks) Browse the collection of React Hooks and learn how to use them. +- [**Viem**](/react/guides/viem) Learn about Viem and how it works with Wagmi. diff --git a/site/react/guides/chain-properties.md b/site/react/guides/chain-properties.md new file mode 100644 index 0000000000..9e4667a6e3 --- /dev/null +++ b/site/react/guides/chain-properties.md @@ -0,0 +1,97 @@ +# Chain Properties + +Some chains support additional properties related to blocks and transactions. This is powered by Viem's [formatters](https://viem.sh/docs/chains/formatters) and [serializers](https://viem.sh/docs/chains/serializers). For example, Celo, ZkSync, OP Stack chains all support additional properties. In order to use these properties in a type-safe way, there are a few things you should be aware of. + +
+ +::: tip +Make sure you follow the TypeScript guide's [Config Types](/react/typescript#config-types) section before moving on. The easiest way to do this is to use [Declaration Merging](/react/typescript#declaration-merging) to "register" your `config` globally with TypeScript. + +<<< @/snippets/react/config-chain-properties.ts[config.ts] +::: + +## Narrowing Parameters + +Once your Config is registered with TypeScript, you are ready to access chain-specific properties! For example, Celo's `feeCurrency` is available. + +::: code-group +```ts [index.tsx] +import { parseEther } from 'viem' +import { useSimulateContract } from 'wagmi' + +const result = useSimulateContract({ + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + feeCurrency: '0x…', // [!code focus] +}) +``` +<<< @/snippets/react/config-chain-properties.ts[config.ts] +::: + +This is great, but if you have multiple chains that support additional properties, your autocomplete could be overwhelmed with all of them. By setting the `chainId` property to a specific value (e.g. `celo.id`), you can narrow parameters to a single chain. + +::: code-group +```ts [index.tsx] +import { parseEther } from 'viem' +import { useSimulateContract } from 'wagmi' +import { celo } from 'wagmi/chains' + +const result = useSimulateContract({ + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + chainId: celo.id, // [!code focus] + feeCurrency: '0x…', // [!code focus] + // ^? (property) feeCurrency?: `0x${string}` | undefined // [!code focus] +}) +``` +<<< @/snippets/react/config-chain-properties.ts[config.ts] +::: + +## Narrowing Return Types + +Return types can also have chain-specific properties attached to them. There are a couple approaches for extracting these properties. + +### `chainId` Parameter + +Not only can you use the `chainId` parameter to [narrow parameters](#narrowing-parameters), you can also use it to narrow the return type. + +::: code-group +```ts [index.tsx] +import { useWaitForTransactionReceipt } from 'wagmi' +import { zkSync } from 'wagmi/chains' + +const { data } = useWaitForTransactionReceipt({ + chainId: zkSync.id, + hash: '0x16854fcdd0219cacf5aec5e4eb2154dac9e406578a1510a6fc48bd0b67e69ea9', +}) + +data?.logs +// ^? (property) logs: ZkSyncLog[] | undefined +``` +<<< @/snippets/react/config-chain-properties.ts[config.ts] +::: + +### `chainId` Data Property + +Wagmi internally will set a `chainId` property on return types that you can use to narrow results. The `chainId` is determined from the `chainId` parameter or global state (e.g. connector). You can use this property to help TypeScript narrow the type. + +::: code-group +```ts [index.tsx] +import { useWaitForTransactionReceipt } from 'wagmi' +import { zkSync } from 'wagmi/chains' + +const { data } = useWaitForTransactionReceipt({ + hash: '0x16854fcdd0219cacf5aec5e4eb2154dac9e406578a1510a6fc48bd0b67e69ea9', +}) + +if (data?.chainId === zkSync.id) { + data?.logs + // ^? (property) logs: ZkSyncLog[] | undefined +} +``` +<<< @/snippets/react/config-chain-properties.ts[config.ts] +::: + +## Troubleshooting + +If chain properties aren't working, make sure [TypeScript](/react/guides/faq#type-inference-doesn-t-work) is configured correctly. Not all chains have additional properties, to check which ones do, see the [Viem repo](https://github.com/wevm/viem/tree/main/src/chains) (chains that have a top-level directory under [`src/chains`](https://github.com/wevm/viem/tree/main/src/chains) support additional properties). diff --git a/site/react/guides/connect-wallet.md b/site/react/guides/connect-wallet.md new file mode 100644 index 0000000000..34a7e7bea3 --- /dev/null +++ b/site/react/guides/connect-wallet.md @@ -0,0 +1,421 @@ +# Connect Wallet + +The ability for a user to connect their wallet is a core function for any Dapp. It allows users to perform tasks such as: writing to contracts, signing messages, or sending transactions. + +Wagmi contains everything you need to get started with building a Connect Wallet module. To get started, you can either use a [third-party library](#third-party-libraries) or [build your own](#build-your-own). + +## Third-party Libraries + +You can use a pre-built Connect Wallet module from a third-party library such as: + +- [ConnectKit](https://docs.family.co/connectkit) - [Guide](https://docs.family.co/connectkit/getting-started) +- [AppKit](https://reown.com/appkit) - [Guide](https://docs.reown.com/appkit/next/core/installation) +- [RainbowKit](https://www.rainbowkit.com/) - [Guide](https://www.rainbowkit.com/docs/installation) +- [Dynamic](https://www.dynamic.xyz/) - [Guide](https://docs.dynamic.xyz/quickstart) +- [Privy](https://privy.io) - [Guide](https://docs.privy.io/guide/react/wallets/usage/wagmi) + +The above libraries are all built on top of Wagmi, handle all the edge cases around wallet connection, and provide a seamless Connect Wallet UX that you can use in your Dapp. + +## Build Your Own + +Wagmi provides you with the Hooks to get started building your own Connect Wallet module. + +It takes less than five minutes to get up and running with Browser Wallets, WalletConnect, and Coinbase Wallet. + +### 1. Configure Wagmi + +Before we get started with building the functionality of the Connect Wallet module, we will need to set up the Wagmi configuration. + +Let's create a `config.ts` file and export a `config` object. + +::: code-group + +```tsx [config.ts] +import { http, createConfig } from 'wagmi' +import { base, mainnet, optimism } from 'wagmi/chains' +import { injected, metaMask, safe, walletConnect } from 'wagmi/connectors' + +const projectId = '' + +export const config = createConfig({ + chains: [mainnet, base], + connectors: [ + injected(), + walletConnect({ projectId }), + metaMask(), + safe(), + ], + transports: { + [mainnet.id]: http(), + [base.id]: http(), + }, +}) +``` + +::: + +In the above configuration, we want to set up connectors for Injected (browser), WalletConnect (browser + mobile), MetaMask, and Safe wallets. This configuration uses the **Mainnet** and **Base** chains, but you can use whatever you want. + +::: warning + +Make sure to replace the `projectId` with your own WalletConnect Project ID, if you wish to use WalletConnect! + +[Get your Project ID](https://cloud.reown.com/) + +::: + +### 2. Wrap App in Context Provider + +Next, we will need to wrap our React App with Context so that our application is aware of Wagmi & React Query's reactive state and in-memory caching. + +::: code-group + +```tsx [app.tsx] + // 1. Import modules +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import { WagmiProvider } from 'wagmi' +import { config } from './config' + +// 2. Set up a React Query client. +const queryClient = new QueryClient() + +function App() { + // 3. Wrap app with Wagmi and React Query context. + return ( + + + {/** ... */} + + + ) +} +``` + +```tsx [config.ts] +import { http, createConfig } from 'wagmi' +import { base, mainnet, optimism } from 'wagmi/chains' +import { injected, metaMask, safe, walletConnect } from 'wagmi/connectors' + +const projectId = '' + +export const config = createConfig({ + chains: [mainnet, base], + connectors: [ + injected(), + walletConnect({ projectId }), + metaMask(), + safe(), + ], + transports: { + [mainnet.id]: http(), + [base.id]: http(), + }, +}) +``` + +::: + +### 3. Display Wallet Options + +After that, we will create a `WalletOptions` component that will display our connectors. This will allow users to select a wallet and connect. + +Below, we are rendering a list of `connectors` retrieved from `useConnect`. When the user clicks on a connector, the `connect` function will connect the users' wallet. + +::: code-group + +```tsx [wallet-options.tsx] +import * as React from 'react' +import { Connector, useConnect } from 'wagmi' + +export function WalletOptions() { + const { connectors, connect } = useConnect() + + return connectors.map((connector) => ( + + )) +} +``` + +```tsx [app.tsx] + // 1. Import modules +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import { WagmiProvider } from 'wagmi' +import { config } from './config' + +// 2. Set up a React Query client. +const queryClient = new QueryClient() + +function App() { + // 3. Wrap app with Wagmi and React Query context. + return ( + + + {/* ... */} + + + ) +} +``` + +```tsx [config.ts] +import { http, createConfig } from 'wagmi' +import { base, mainnet, optimism } from 'wagmi/chains' +import { injected, metaMask, safe, walletConnect } from 'wagmi/connectors' + +const projectId = '' + +export const config = createConfig({ + chains: [mainnet, base], + connectors: [ + injected(), + walletConnect({ projectId }), + metaMask(), + safe(), + ], + transports: { + [mainnet.id]: http(), + [base.id]: http(), + }, +}) +``` + +::: + +### 4. Display Connected Account + +Lastly, if an account is connected, we want to show some basic information, like the connected address and ENS name and avatar. + +Below, we are using hooks like `useAccount`, `useEnsAvatar` and `useEnsName` to extract this information. + +We are also utilizing `useDisconnect` to show a "Disconnect" button so a user can disconnect their wallet. + +::: code-group + +```tsx [account.tsx] +import { useAccount, useDisconnect, useEnsAvatar, useEnsName } from 'wagmi' + +export function Account() { + const { address } = useAccount() + const { disconnect } = useDisconnect() + const { data: ensName } = useEnsName({ address }) + const { data: ensAvatar } = useEnsAvatar({ name: ensName! }) + + return ( +
+ {ensAvatar && ENS Avatar} + {address &&
{ensName ? `${ensName} (${address})` : address}
} + +
+ ) +} +``` + +```tsx [wallet-options.tsx] +import * as React from 'react' +import { Connector, useConnect } from 'wagmi' + +export function WalletOptions() { + const { connectors, connect } = useConnect() + + return connectors.map((connector) => ( + connect({ connector })} + /> + )) +} + +function WalletOption({ + connector, + onClick, +}: { + connector: Connector + onClick: () => void +}) { + const [ready, setReady] = React.useState(false) + + React.useEffect(() => { + ;(async () => { + const provider = await connector.getProvider() + setReady(!!provider) + })() + }, [connector]) + + return ( + + ) +} +``` + +```tsx [app.tsx] + // 1. Import modules +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import { WagmiProvider } from 'wagmi' +import { config } from './config' + +// 2. Set up a React Query client. +const queryClient = new QueryClient() + +function App() { + // 3. Wrap app with Wagmi and React Query context. + return ( + + + {/* ... */} + + + ) +} +``` + +```tsx [config.ts] +import { http, createConfig } from 'wagmi' +import { base, mainnet, optimism } from 'wagmi/chains' +import { injected, metaMask, safe, walletConnect } from 'wagmi/connectors' + +const projectId = '' + +export const config = createConfig({ + chains: [mainnet, base], + connectors: [ + injected(), + walletConnect({ projectId }), + metaMask(), + safe(), + ], + transports: { + [mainnet.id]: http(), + [base.id]: http(), + }, +}) +``` + +::: + +### 5. Wire it up! + +Finally, we can wire up our Wallet Options and Account components to our application's entrypoint. + +::: code-group + +```tsx [app.tsx] +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import { WagmiProvider, useAccount } from 'wagmi' +import { config } from './config' +import { Account } from './account' // [!code ++] +import { WalletOptions } from './wallet-options' // [!code ++] + +const queryClient = new QueryClient() + +function ConnectWallet() { // [!code ++] + const { isConnected } = useAccount() // [!code ++] + if (isConnected) return // [!code ++] + return // [!code ++] +} // [!code ++] + +function App() { + return ( + + + // [!code ++] + + + ) +} +``` + +```tsx [account.tsx] +import { useAccount, useDisconnect, useEnsAvatar, useEnsName } from 'wagmi' + +export function Account() { + const { address } = useAccount() + const { disconnect } = useDisconnect() + const { data: ensName } = useEnsName({ address }) + const { data: ensAvatar } = useEnsAvatar({ name: ensName! }) + + return ( +
+ {ensAvatar && ENS Avatar} + {address &&
{ensName ? `${ensName} (${address})` : address}
} + +
+ ) +} +``` + +```tsx [wallet-options.tsx] +import * as React from 'react' +import { Connector, useConnect } from 'wagmi' + +export function WalletOptions() { + const { connectors, connect } = useConnect() + + return connectors.map((connector) => ( + connect({ connector })} + /> + )) +} + +function WalletOption({ + connector, + onClick, +}: { + connector: Connector + onClick: () => void +}) { + const [ready, setReady] = React.useState(false) + + React.useEffect(() => { + ;(async () => { + const provider = await connector.getProvider() + setReady(!!provider) + })() + }, [connector]) + + return ( + + ) +} +``` + +```tsx [config.ts] +import { http, createConfig } from 'wagmi' +import { base, mainnet, optimism } from 'wagmi/chains' +import { injected, metaMask, safe, walletConnect } from 'wagmi/connectors' + +const projectId = '' + +export const config = createConfig({ + chains: [mainnet, base], + connectors: [ + injected(), + walletConnect({ projectId }), + metaMask(), + safe(), + ], + transports: { + [mainnet.id]: http(), + [base.id]: http(), + }, +}) +``` + +::: + +### Playground + +Want to see the above steps all wired up together in an end-to-end example? Check out the below StackBlitz playground. + +
+ + diff --git a/site/react/guides/error-handling.md b/site/react/guides/error-handling.md new file mode 100644 index 0000000000..62dae72b52 --- /dev/null +++ b/site/react/guides/error-handling.md @@ -0,0 +1,42 @@ +# Error Handling + +The `error` property in Wagmi Hooks is strongly typed with it's corresponding error type. This enables you to have granular precision with handling errors in your application. + +You can discriminate the error type by using the `name` property on the error object. + +::: code-group +```tsx twoslash [index.tsx] +// @noErrors +import { useBlockNumber } from 'wagmi' + +function App() { + const { data, error } = useBlockNumber() + // ^? + + error?.name + // ^? + + + + + + + if (error?.name === 'HttpRequestError') { + const { status } = error + // ^? + + + return
A HTTP error occurred. Status: {status}
+ } + if (error?.name === 'LimitExceededRpcError') { + const { code } = error + // ^? + + + return
Rate limit exceeded. Code: {code}
+ } + // ... +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: diff --git a/site/react/guides/ethers.md b/site/react/guides/ethers.md new file mode 100644 index 0000000000..fe1b2ad597 --- /dev/null +++ b/site/react/guides/ethers.md @@ -0,0 +1,285 @@ +# Ethers.js Adapters + +It is recommended for projects to migrate to [Viem](https://viem.sh) when using Wagmi, but there are some cases where you might still need to use [Ethers.js](https://ethers.org) in your project: + +- You may want to **incrementally migrate** Ethers.js usage to Viem +- Some **third-party libraries & SDKs** may only support Ethers.js +- Personal preference + +We have provided reference implementations for Viem → Ethers.js adapters that you can copy + paste in your project. + +## Client → Provider + +### Reference Implementation + +Copy the following reference implementation into a file of your choice: + +::: code-group + +```ts [Ethers v5] +import { providers } from 'ethers' +import { useMemo } from 'react' +import type { Chain, Client, Transport } from 'viem' +import { Config, useClient } from 'wagmi' + +export function clientToProvider(client: Client) { + const { chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + if (transport.type === 'fallback') + return new providers.FallbackProvider( + (transport.transports as ReturnType[]).map( + ({ value }) => new providers.JsonRpcProvider(value?.url, network), + ), + ) + return new providers.JsonRpcProvider(transport.url, network) +} + +/** Hook to convert a viem Client to an ethers.js Provider. */ +export function useEthersProvider({ + chainId, +}: { chainId?: number | undefined } = {}) { + const client = useClient({ chainId }) + return useMemo(() => (client ? clientToProvider(client) : undefined), [client]) +} +``` + +```ts [Ethers v6] +import { FallbackProvider, JsonRpcProvider } from 'ethers' +import { useMemo } from 'react' +import type { Chain, Client, Transport } from 'viem' +import { type Config, useClient } from 'wagmi' + +export function clientToProvider(client: Client) { + const { chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + if (transport.type === 'fallback') { + const providers = (transport.transports as ReturnType[]).map( + ({ value }) => new JsonRpcProvider(value?.url, network), + ) + if (providers.length === 1) return providers[0] + return new FallbackProvider(providers) + } + return new JsonRpcProvider(transport.url, network) +} + +/** Action to convert a viem Client to an ethers.js Provider. */ +export function useEthersProvider({ chainId }: { chainId?: number } = {}) { + const client = useClient({ chainId }) + return useMemo(() => (client ? clientToProvider(client) : undefined), [client]) +} +``` + +::: + +### Usage + +Now you can use the `useEthersProvider` function in your components: + +::: code-group + +```ts [example.ts] +import { useEthersProvider } from './ethers' + +function Example() { + const provider = useEthersProvider() + ... +} +``` + +```ts [ethers.ts (Ethers v5)] +import { providers } from 'ethers' +import { useMemo } from 'react' +import type { Chain, Client, Transport } from 'viem' +import { Config, useClient } from 'wagmi' + +export function clientToProvider(client: Client) { + const { chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + if (transport.type === 'fallback') + return new providers.FallbackProvider( + (transport.transports as ReturnType[]).map( + ({ value }) => new providers.JsonRpcProvider(value?.url, network), + ), + ) + return new providers.JsonRpcProvider(transport.url, network) +} + +/** Hook to convert a viem Client to an ethers.js Provider. */ +export function useEthersProvider({ + chainId, +}: { chainId?: number | undefined } = {}) { + const client = useClient({ chainId }) + return useMemo(() => (client ? clientToProvider(client) : undefined), [client]) +} +``` + +```ts [ethers.ts (Ethers v6)] +import { FallbackProvider, JsonRpcProvider } from 'ethers' +import { useMemo } from 'react' +import type { Chain, Client, Transport } from 'viem' +import { type Config, useClient } from 'wagmi' + +export function clientToProvider(client: Client) { + const { chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + if (transport.type === 'fallback') { + const providers = (transport.transports as ReturnType[]).map( + ({ value }) => new JsonRpcProvider(value?.url, network), + ) + if (providers.length === 1) return providers[0] + return new FallbackProvider(providers) + } + return new JsonRpcProvider(transport.url, network) +} + +/** Action to convert a viem Client to an ethers.js Provider. */ +export function useEthersProvider({ chainId }: { chainId?: number } = {}) { + const client = useClient({ chainId }) + return useMemo(() => (client ? clientToProvider(client) : undefined), [client]) +} +``` + +::: + +## Connector Client → Signer + +### Reference Implementation + +Copy the following reference implementation into a file of your choice: + +::: code-group + +```ts [Ethers v5] +import { providers } from 'ethers' +import { useMemo } from 'react' +import type { Account, Chain, Client, Transport } from 'viem' +import { Config, useConnectorClient } from 'wagmi' + +export function clientToSigner(client: Client) { + const { account, chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + const provider = new providers.Web3Provider(transport, network) + const signer = provider.getSigner(account.address) + return signer +} + +/** Hook to convert a Viem Client to an ethers.js Signer. */ +export function useEthersSigner({ chainId }: { chainId?: number } = {}) { + const { data: client } = useConnectorClient({ chainId }) + return useMemo(() => (client ? clientToSigner(client) : undefined), [client]) +} +``` + +```ts [Ethers v6] +import { BrowserProvider, JsonRpcSigner } from 'ethers' +import { useMemo } from 'react' +import type { Account, Chain, Client, Transport } from 'viem' +import { type Config, useConnectorClient } from 'wagmi' + +export function clientToSigner(client: Client) { + const { account, chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + const provider = new BrowserProvider(transport, network) + const signer = new JsonRpcSigner(provider, account.address) + return signer +} + +/** Hook to convert a viem Wallet Client to an ethers.js Signer. */ +export function useEthersSigner({ chainId }: { chainId?: number } = {}) { + const { data: client } = useConnectorClient({ chainId }) + return useMemo(() => (client ? clientToSigner(client) : undefined), [client]) +} +``` + +::: + +### Usage + +Now you can use the `useEthersSigner` function in your components: + +::: code-group + +```ts [example.ts] +import { useEthersSigner } from './ethers' + +function example() { + const signer = useEthersSigner() + ... +} +``` + +```ts [ethers.ts (Ethers v5)] +import { providers } from 'ethers' +import { useMemo } from 'react' +import type { Account, Chain, Client, Transport } from 'viem' +import { Config, useConnectorClient } from 'wagmi' + +export function clientToSigner(client: Client) { + const { account, chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + const provider = new providers.Web3Provider(transport, network) + const signer = provider.getSigner(account.address) + return signer +} + +/** Action to convert a Viem Client to an ethers.js Signer. */ +export function useEthersSigner({ chainId }: { chainId?: number } = {}) { + const { data: client } = useConnectorClient({ chainId }) + return useMemo(() => (client ? clientToSigner(client) : undefined), [client]) +} +``` + +```ts [ethers.ts (Ethers v6)] +import { BrowserProvider, JsonRpcSigner } from 'ethers' +import { useMemo } from 'react' +import type { Account, Chain, Client, Transport } from 'viem' +import { type Config, useConnectorClient } from 'wagmi' + +export function clientToSigner(client: Client) { + const { account, chain, transport } = client + const network = { + chainId: chain.id, + name: chain.name, + ensAddress: chain.contracts?.ensRegistry?.address, + } + const provider = new BrowserProvider(transport, network) + const signer = new JsonRpcSigner(provider, account.address) + return signer +} + +/** Hook to convert a viem Wallet Client to an ethers.js Signer. */ +export function useEthersSigner({ chainId }: { chainId?: number } = {}) { + const { data: client } = useConnectorClient({ chainId }) + return useMemo(() => (client ? clientToSigner(client) : undefined), [client]) +} +``` + +::: diff --git a/site/react/guides/faq.md b/site/react/guides/faq.md new file mode 100644 index 0000000000..8628c5b1b3 --- /dev/null +++ b/site/react/guides/faq.md @@ -0,0 +1,24 @@ + + +# FAQ / Troubleshooting + +Collection of frequently asked questions with ideas on how to troubleshoot and resolve them. + + + +## How does Wagmi work? + +Until there's a more in-depth write-up about Wagmi internals, here is the gist: + +- Wagmi is essentially a wrapper around [Viem](https://viem.sh) and TanStack Query that adds connector and multichain support. +- [Connectors](/react/api/connectors) allow Wagmi and Ethereum accounts to communicate with each other. +- The Wagmi [`Config`](/react/api/createConfig#config) manages connections established between Wagmi and Connectors, as well as some global state. [Connections](/react/api/createConfig#connection) come with one or more addresses and a chain ID. + - If there are connections, the Wagmi `Config` listens for connection changes and updates the [`chainId`](/react/api/createConfig#chainid) based on the ["current" connection](/react/api/createConfig#current). (The Wagmi `Config` can have [many connections established](/react/api/createConfig#connections) at once, but only one connection can be the "current" connection. Usually this is the connection from the last connector that is connected, but can change based on event emitted from other connectors or through the [`useSwitchAccount`](/react/api/hooks/useSwitchAccount) hook and [`switchAccount`](/core/api/actions/switchAccount) action.) + - If there are no connections, the Wagmi `Config` defaults the global state `chainId` to the first chain it was created with or last established connection. + - The global `chainId` can be changed directly using the [`useSwitchChain`](/react/api/hooks/useSwitchChain) hook and [`switchChain`](/core/api/actions/switchChain) action. This works when there are no connections as well as for most connectors (not all connectors support chain switching). +- Wagmi uses the global `chainId` (from the "current" connection or global state) to internally create Viem Client's, which are used by hooks and actions. +- Hooks are constructed by TanStack Query options helpers, exported by the `'@wagmi/core/query'` entrypoint, and some additional code to wire up type parameters, hook into React Context, etc. +- There are three types of hooks: query hooks, mutation hooks, and config hooks. Query hooks, like [`useCall`](/react/api/hooks/useCall), generally read blockchain state and mutation hooks, like [`useSendTransaction`](/react/api/hooks/useSendTransaction), usually change state through sending transactions via the "current" connection. Config hooks are for getting data from and managing the Wagmi `Config` instance, e.g. [`useChainId`](/react/api/hooks/useChainId) and `useSwitchAccount`. Query and mutation hooks usually have corresponding [Viem actions.](https://viem.sh) + diff --git a/site/react/guides/migrate-from-v1-to-v2.md b/site/react/guides/migrate-from-v1-to-v2.md new file mode 100644 index 0000000000..1374fd6eef --- /dev/null +++ b/site/react/guides/migrate-from-v1-to-v2.md @@ -0,0 +1,658 @@ +--- +title: Migrate from v1 to v2 +description: Guide for migrating from Wagmi v1 to v2. +--- + + + +# Migrate from v1 to v2 + +## Overview + +Wagmi v2 redesigns the core APIs to mesh better with [Viem](https://viem.sh) and [TanStack Query](https://tanstack.com/query/v5/docs/react). This major version transforms Wagmi into a light wrapper around these libraries, sprinkling in multichain support and account management. As such, there are some breaking changes and deprecations to be aware of outlined in this guide. + +To get started, install the latest version of Wagmi and it's required peer dependencies. + +::: code-group +```bash-vue [pnpm] +pnpm add wagmi viem@{{viemVersion}} @tanstack/react-query +``` + +```bash-vue [npm] +npm install wagmi viem@{{viemVersion}} @tanstack/react-query +``` + +```bash-vue [yarn] +yarn add wagmi viem@{{viemVersion}} @tanstack/react-query +``` + +```bash-vue [bun] +bun add wagmi viem@{{viemVersion}} @tanstack/react-query +``` +::: + +::: info Wagmi v2 should be the last major version that will have this many actionable breaking changes. +Moving forward after Wagmi v2, new functionality will be opt-in with old functionality being deprecated alongside the new features. This means upgrading to the latest major versions will not require immediate changes. +::: + +::: info Not ready to migrate yet? +The Wagmi v1 docs are still available at [1.x.wagmi.sh/react](https://1.x.wagmi.sh/react). +::: + +## Dependencies + +### Moved TanStack Query to peer dependencies + +Wagmi uses [TanStack Query](https://tanstack.com/query/v5/docs/react) to manage async state, handling requests, caching, and more. With Wagmi v1, TanStack Query was an internal implementation detail. With Wagmi v2, TanStack Query is a peer dependency. A lot of Wagmi users also use TanStack Query in their apps so making it a peer dependency gives them more control and removes some custom Wagmi code internally. + +If you don't normally use TanStack Query, all you need to do is set it up and mostly forget about it (we'll provide guidance around version updates). + +::: code-group +```tsx [app.tsx] +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' // [!code ++] +import { WagmiProvider } from 'wagmi' +import { config } from './config' + +const queryClient = new QueryClient() // [!code ++] + +function App() { + return ( + + // [!code ++] + {/** ... */} + // [!code ++] + + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +For more information on setting up TanStack Query for Wagmi, follow the [Getting Started docs](/react/getting-started#setup-tanstack-query). If you want to set up persistence for your query cache (default behavior before Wagmi v2), check out the [TanStack Query docs](https://tanstack.com/query/v5/docs/react/plugins/persistQueryClient#usage-with-react). + +### Dropped CommonJS support + +Wagmi v2 no longer publishes a separate `cjs` tag since very few people use this tag and ESM is the future. See [Sindre Sorhus' guide](https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c) for more info about switching to ESM. + +## Hooks + +### Removed mutation setup arguments + +Mutation hooks are hooks that change network or application state, sign data, or perform write operations through mutation functions. With Wagmi v1, you could pass arguments directly to these hooks instead of using them with their mutation functions. For example: + +```ts{3} +// Wagmi v1 +const { signMessage } = useSignMessage({ + message: 'foo bar baz', +}) +``` + +With Wagmi v2, you must pass arguments to the mutation function instead. This follows the same behavior as [TanStack Query](https://tanstack.com/query/v5/docs/react/guides/mutations) mutations and improves type-safety. + +```tsx +import { useSignMessage } from 'wagmi' + +const { signMessage } = useSignMessage({ message: 'foo bar baz' }) // [!code --] +const { signMessage } = useSignMessage() // [!code ++] + + +``` + +### Moved TanStack Query parameters to `query` property + +Previously, you could pass TanStack Query parameters, like `enabled` and `staleTime`, directly to hooks. In Wagmi v2, TanStack Query parameters are now moved to the `query` property. This allows Wagmi to better support TanStack Query type inference, control for future breaking changes since [TanStack Query is now a peer dependency](#moved-tanstack-query-to-peer-dependencies), and expose Wagmi-related hook property at the top-level of editor features, like autocomplete. + +```tsx +useReadContract({ + enabled: false, // [!code --] + staleTime: 1_000, // [!code --] + query: { // [!code ++] + enabled: false, // [!code ++] + staleTime: 1_000, // [!code ++] + }, // [!code ++] +}) +``` + +### Removed watch property + +The `watch` property was removed from all hooks besides [`useBlock`](/react/api/hooks/useBlock) and [`useBlockNumber`](/react/api/hooks/useBlockNumber). This property allowed hooks to internally listen for block changes and automatically refresh their data. In Wagmi v2, you can compose `useBlock` or `useBlockNumber` along with [`React.useEffect`](https://react.dev/reference/react/useEffect) to achieve the same behavior. Two different approaches are outlined for `useBalance` below. + +::: code-group +```ts [invalidateQueries] +import { useQueryClient } from '@tanstack/react-query' // [!code ++] +import { useEffect } from 'react' // [!code ++] +import { useBlockNumber, useBalance } from 'wagmi' // [!code ++] + +const queryClient = useQueryClient() // [!code ++] +const { data: blockNumber } = useBlockNumber({ watch: true }) // [!code ++] +const { data: balance, queryKey } = useBalance({ // [!code ++] + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + watch: true, // [!code --] +}) + +useEffect(() => { // [!code ++] + queryClient.invalidateQueries({ queryKey }) // [!code ++] +}, [blockNumber, queryClient]) // [!code ++] +``` +```ts [refetch] +import { useEffect } from 'react' // [!code ++] +import { useBlockNumber, useBalance } from 'wagmi' // [!code ++] + +const { data: blockNumber } = useBlockNumber({ watch: true }) // [!code ++] +const { data: balance, refetch } = useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + watch: true, // [!code --] +}) + +useEffect(() => { // [!code ++] + refetch() // [!code ++] +}, [blockNumber]) // [!code ++] +``` +::: + +This is a bit more code, but removes a lot of internal code from hooks that can slow down your app when not used and gives you more control. For example, you can easily refresh data every five blocks instead of every block. + +```ts +const { data: blockNumber } = useBlockNumber({ watch: true }) +const { data: balance, queryKey } = useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', +}) + +useEffect(() => { + if (blockNumber % 5 === 0) // [!code focus] + queryClient.invalidateQueries({ queryKey }) // [!code focus] +}, [blockNumber, queryClient]) +``` + +### Removed suspense property + +Wagmi used to support an experimental `suspense` property via TanStack Query. Since TanStack Query [removed `suspense`](https://tanstack.com/query/v5/docs/react/guides/migrating-to-v5#new-hooks-for-suspense) from its `useQuery` hook, it is no longer supported by Wagmi Hooks. + +Instead, you can use `useSuspenseQuery` along with TanStack Query-related exports from the `'wagmi/query'` entrypoint. + +```ts +import { useSuspenseQuery } from '@tanstack/react-query' // [!code ++] +import { useConfig } from 'wagmi' // [!code ++] +import { getBalanceQueryOptions } from 'wagmi/query' // [!code ++] +import { useBalance } from 'wagmi' // [!code --] + +const config = useConfig() // [!code ++] +const options = getBalanceQueryOptions(config, { address: '0x…' }) // [!code ++] +const result = useSuspenseQuery(options) // [!code ++] +const result = useBalance({ // [!code --] + address: '0x…', // [!code --] + suspense: true, // [!code --] +}) // [!code --] +``` + +### Removed prepare hooks + +`usePrepareContractWrite` and `usePrepareSendTransaction` were removed and replaced with idiomatic Viem alternatives. For `usePrepareContractWrite`, use [`useSimulateContract`](/react/api/hooks/useSimulateContract). Similar to `usePrepareContractWrite`, `useSimulateContract` composes well with `useWriteContract` + +```tsx +import { usePrepareContractWrite, useWriteContract } from 'wagmi' // [!code --] +import { useSimulateContract, useWriteContract } from 'wagmi' // [!code ++] + +const { config } = usePrepareContractWrite({ // [!code --] +const { data } = useSimulateContract({ // [!code ++] + address: '0x', + abi: [{ + type: 'function', + name: 'transferFrom', + stateMutability: 'nonpayable', + inputs: [ + { name: 'sender', type: 'address' }, + { name: 'recipient', type: 'address' }, + { name: 'amount', type: 'uint256' }, + ], + outputs: [{ type: 'bool' }], + }], + functionName: 'transferFrom', + args: ['0x', '0x', 123n], +}) +const { write } = useWriteContract(config) // [!code --] +const { writeContract } = useWriteContract() // [!code ++] + + +``` + +Instead of `usePrepareSendTransaction`, use [`useEstimateGas`](/react/api/hooks/useEstimateGas). You can pass `useEstimateGas` `data` to `useSendTransaction` to compose the two hooks. + +```tsx +import { usePrepareSendTransaction, useSendTransaction } from 'wagmi' // [!code --] +import { useEstimateGas, useSendTransaction } from 'wagmi' // [!code ++] +import { parseEther } from 'viem' + +const { config } = usePrepareSendTransaction({ // [!code --] +const { data } = useEstimateGas({ // [!code ++] + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), +}) +const { sendTransaction } = useSendTransaction(config) // [!code --] +const { sendTransaction } = useSendTransaction() // [!code ++] + + +``` + +This might seem like more work, but it gives you more control and is more accurate representation of what is happening under the hood. + +### Removed `useNetwork` hook + +The `useNetwork` hook was removed since the connected chain is typically based on the connected account. Use [`useAccount`](/react/api/hooks/useAccount) to get the connected `chain`. + +```ts +import { useNetwork } from 'wagmi' // [!code --] +import { useAccount } from 'wagmi' // [!code ++] + +const { chain } = useNetwork() // [!code --] +const { chain } = useAccount() // [!code ++] +``` + +Use `useConfig` for the list of `chains` set up with the Wagmi [`Config`](/react/api/createConfig#chains). + +```ts +import { useNetwork } from 'wagmi' // [!code --] +import { useConfig } from 'wagmi' // [!code ++] + +const { chains } = useNetwork() // [!code --] +const { chains } = useConfig() // [!code ++] +``` + +### Removed `onConnect` and `onDisconnect` callbacks from `useAccount` + +The `onConnect` and `onDisconnect` callbacks were removed from the `useAccount` hook since it is frequently used without these callbacks so it made sense to extract these into a new API, [`useAccountEffect`](/react/api/hooks/useAccountEffect), rather than clutter the `useAccount` hook. + +```ts +import { useAccount } from 'wagmi' // [!code --] +import { useAccountEffect } from 'wagmi' // [!code ++] + +useAccount({ // [!code --] +useAccountEffect({ // [!code ++] + onConnect(data) { + console.log('connected', data) + }, + onDisconnect() { + console.log('disconnected') + }, +}) +``` + +### Removed `useWebSocketPublicClient` + +The Wagmi [`Config`](/react/api/createConfig) does not separate transport types anymore. Simply use Viem's [`webSocket`](https://viem.sh/docs/clients/transports/websocket.html) transport instead when setting up your Wagmi `Config`. You can get Viem `Client` instance with this transport attached by using [`useClient`](/react/api/hooks/useClient) or [`usePublicClient`](/react/api/hooks/usePublicClient). + +### Removed `useInfiniteReadContracts` `paginatedIndexesConfig` + +In the spirit of removing unnecessary abstractions, `paginatedIndexesConfig` was removed. Use `useInfiniteReadContracts`'s `initialPageParam` and `getNextPageParam` parameters along with `fetchNextPage`/`fetchPreviousPage` from the result instead or copy `paginatedIndexesConfig`'s implementation to your codebase. + +See the [TanStack Query docs](https://tanstack.com/query/v5/docs/react/guides/infinite-queries) for more information on infinite queries. + +### Updated `useSendTransaction` and `useWriteContract` return type + +Updated [`useSendTransaction`](/react/api/hooks/useSendTransaction) and [`useWriteContract`](/react/api/hooks/useWriteContract) return type from `` { hash: `0x${string}` } `` to `` `0x${string}` ``. + +```ts +const result = useSendTransaction() +result.data?.hash // [!code --] +result.data // [!code ++] +``` + +### Updated `useConnect` return type + +Updated [`useConnect`](/react/api/hooks/useConnect) return type from `` { account: Address; chain: { id: number; unsupported?: boolean }; connector: Connector } `` to `` { accounts: readonly Address[]; chainId: number } ``. This better reflects the ability to have multiple accounts per connector. + +### Renamed parameters and return types + +All hook parameters and return types follow the naming pattern of `[PascalCaseHookName]Parameters` and `[PascalCaseHookName]ReturnType`. For example, `UseAccountParameters` and `UseAccountReturnType`. + +```ts +import { UseAccountConfig, UseAccountResult } from 'wagmi' // [!code --] +import { UseAccountParameters, UseAccountReturnType } from 'wagmi' // [!code ++] +``` + +## Connectors + +### Updated connector API + +In order to maximize type-safety and ease of creating connectors, the connector API changed. Follow the [Creating Connectors guide](/dev/creating-connectors) for more info on creating new connectors and converting Wagmi v1 connectors. + +### Removed individual entrypoints + +Previously, each connector had it's own entrypoint to optimize tree-shaking. Since all connectors now have [`package.json#sideEffects`](https://webpack.js.org/guides/tree-shaking/#mark-the-file-as-side-effect-free) enabled, this is no longer necessary and the entrypoint is unified. Use the `'wagmi/connectors'` entrypoint instead. + +```ts +import { InjectedConnector } from 'wagmi/connectors/injected' // [!code --] +import { CoinbaseWalletConnector } from 'wagmi/connectors/coinbaseWallet' // [!code --] +import { coinbaseWallet, injected } from 'wagmi/connectors' // [!code ++] +``` + +### Removed `MetaMaskConnector` + +The `MetaMaskConnector` was removed since it was nearly the same thing as the `InjectedConnector`. Use the [`injected`](/react/api/connectors/injected) connector instead, along with the [`target`](/react/api/connectors/injected#target) parameter set to `'metaMask'`, for the same behavior. + +```ts +import { MetaMaskConnector } from 'wagmi/connectors/metaMask' // [!code --] +import { injected } from 'wagmi/connectors' // [!code ++] + +const connector = new MetaMaskConnector() // [!code --] +const connector = injected({ target: 'metaMask' }) // [!code ++] +``` +### Renamed connectors + +In Wagmi v1, connectors were classes you needed to instantiate. In Wagmi v2, connectors are functions. As a result, the API has changed. Connectors have the following new names: + +- `CoinbaseWalletConnector` is now [`coinbaseWallet`](/react/api/connectors/coinbaseWallet). +- `InjectedConnector` is now [`injected`](/react/api/connectors/injected). +- `SafeConnector` is now [`safe`](/react/api/connectors/safe). +- `WalletConnectConnector` is now [`walletConnect`](/react/api/connectors/walletConnect). + +To create a connector, you now call the connector function with parameters. + +```ts +import { WalletConnectConnector } from 'wagmi/connectors/walletConnect' // [!code --] +import { walletConnect } from 'wagmi/connectors' // [!code ++] + +const connector = new WalletConnectConnector({ // [!code --] +const connector = walletConnect({ // [!code ++] + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', +}) +``` + +### Removed `WalletConnectLegacyConnector` + +WalletConnect v1 was sunset June 28, 2023. Use the [`walletConnect`](/react/api/connectors/walletConnect) connector instead. + +```ts +import { WalletConnectLegacyConnector } from 'wagmi/connectors/walletConnectLegacy' // [!code --] +import { walletConnect } from 'wagmi/connectors' // [!code ++] + +const connector = new WalletConnectLegacyConnector({ // [!code --] +const connector = walletConnect({ // [!code ++] + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', +}) +``` + +## Chains + +### Updated `'wagmi/chains'` entrypoint + +Chains now live in the [Viem repository](https://github.com/wevm/viem). As a result, the `'wagmi/chains'` entrypoint now proxies all chains from `'viem/chains'` directly. + +### Removed `mainnet` and `sepolia` from main entrypoint + +Since the `'wagmi/chains'` entrypoint now proxies `'viem/chains'`, `mainnet` and `sepolia` were removed from the main entrypoint. Use the `'wagmi/chains'` entrypoint instead. + +```ts +import { mainnet, sepolia } from 'wagmi' // [!code --] +import { mainnet, sepolia } from 'wagmi/chains' // [!code ++] +``` + +## Errors + +A number of errors were renamed to better reflect their functionality or replaced by Viem errors. + +## Miscellaneous + +### Removed internal ENS name normalization + +Before v2, Wagmi handled ENS name normalization internally for `useEnsAddress`, `useEnsAvatar`, and `useEnsResolver`, using Viem's [`normalize`](https://viem.sh/docs/ens/utilities/normalize.html) function. This added extra bundle size as full normalization is quite heavy. For v2, you must normalize ENS names yourself before passing them to these hooks. You can use Viem's `normalize` function or any other function that performs [UTS-46 normalization](https://unicode.org/reports/tr46). + +```ts +import { useEnsAddress } from 'wagmi' +import { normalize } from 'viem/ens' // [!code ++] + +const result = useEnsAddress({ + name: 'wevm.eth', // [!code --] + name: normalize('wevm.eth'), // [!code ++] +}) +``` + +By inverting control, Wagmi let's you choose how much normalization to do. For example, maybe your project only allows ENS names that are numeric so no normalization is not needed. Check out the [ENS documentation](https://docs.ens.domains/contract-api-reference/name-processing#normalising-names) for more information on normalizing names. + +### Removed `configureChains` + +The Wagmi v2 `Config` now has native multichain support using the [`chains`](/react/api/createConfig) parameter so the `configureChains` function is no longer required. + +```ts +import { configureChains, createConfig } from 'wagmi' // [!code --] +import { http, createConfig } from 'wagmi' // [!code ++] +import { mainnet, sepolia } from 'wagmi/chains' + +const { chains, publicClient } = configureChains( // [!code --] + [mainnet, sepolia], // [!code --] + [publicProvider(), publicProvider()], // [!code --] +) // [!code --] + +export const config = createConfig({ + publicClient, // [!code --] + chains: [mainnet, sepolia], // [!code ++] + transports: { // [!code ++] + [mainnet.id]: http(), // [!code ++] + [sepolia.id]: http(), // [!code ++] + }, // [!code ++] +}) +``` + +### Removed ABI exports + +Import from Viem instead. + +```ts +import { erc20ABI } from 'wagmi' // [!code --] +import { erc20Abi } from 'viem' // [!code ++] +``` + +### Removed `'wagmi/providers/*` entrypoints + +It never made sense that we would have provider URLs hardcoded in the Wagmi codebase. Use [Viem transports](https://viem.sh/docs/clients/intro.html#transports) along with RPC provider URLs instead. + +```ts +import { alchemyProvider } from 'wagmi/providers/alchemy' // [!code --] +import { http } from 'viem' // [!code ++] + +const transport = http('https://mainnet.example.com') +``` + +### Updated `createConfig` parameters + +- Removed `autoConnect`. The reconnecting behavior is now managed by React and not related to the Wagmi `Config`. Use `WagmiProvider` [`reconnectOnMount`](/react/api/WagmiProvider#reconnectonmount) or [`useReconnect`](/react/api/hooks/useReconnect) hook instead. +- Removed `publicClient` and `webSocketPublicClient`. Use [`transports`](/react/api/createConfig#transports) or [`client`](/react/api/createConfig#client) instead. +- Removed `logger`. Wagmi no longer logs debug information to console. + +### Updated `Config` object + +- Removed `config.connector`. Use `config.state.connections.get(config.state.current)?.connector` instead. +- Removed `config.data`. Use `config.state.connections.get(config.state.current)` instead. +- Removed `config.error`. Was unused and not needed. +- Removed `config.lastUsedChainId`. Use `config.state.connections.get(config.state.current)?.chainId` instead. +- Removed `config.publicClient`. Use [`config.getClient()`](/react/api/createConfig#getclient) or [`getPublicClient`](/core/api/actions/getPublicClient) instead. +- Removed `config.status`. Use [`config.state.status`](/react/api/createConfig#status) instead. +- Removed `config.webSocketClient`. Use [`config.getClient()`](/react/api/createConfig#getclient) or [`getPublicClient`](/core/api/actions/getPublicClient) instead. +- Removed `config.clearState`. Was unused and not needed. +- Removed `config.autoConnect()`. Use [`reconnect`](/core/api/actions/reconnect) action instead. +- Renamed `config.setConnectors`. Use `config._internal.setConnectors` instead. +- Removed `config.setLastUsedConnector`. Use `config.storage?.setItem('recentConnectorId', connectorId)` instead. +- Removed `getConfig`. `config` should be passed explicitly to actions instead of using global `config`. + +## Deprecations + +### Renamed `WagmiConfig` + +`WagmiConfig` was renamed to [`WagmiProvider`](/react/api/WagmiProvider) to reduce confusion with the Wagmi [`Config`](/react/api/createConfig) type. React Context Providers usually follow the naming schema `*Provider` so this is a more idiomatic name. Now that Wagmi no longer uses Ethers.js (since Wagmi v1), the term "Provider" is less overloaded. + +::: code-group +```tsx [app.tsx] +import { WagmiConfig } from 'wagmi' // [!code --] +import { WagmiProvider } from 'wagmi' // [!code ++] +import { config } from './config' + +function App() { + return ( + // [!code --] + // [!code ++] + {/** ... */} + // [!code ++] + // [!code --] + ) +} +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### Deprecated `useBalance` `token` parameter + +Moving forward, `useBalance` will only work for native currencies, thus the `token` parameter is no longer supported. Use [`useReadContracts`](/react/api/hooks/useReadContracts) instead. + +```ts +import { useBalance } from 'wagmi' // [!code --] +import { useReadContracts } from 'wagmi' // [!code ++] +import { erc20Abi } from 'viem' // [!code ++] + +const result = useBalance({ // [!code --] + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', // [!code --] + token: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code --] +}) // [!code --] +const result = useReadContracts({ // [!code ++] + allowFailure: false, // [!code ++] + contracts: [ // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'balanceOf', // [!code ++] + args: ['0x4557B18E779944BFE9d78A672452331C186a9f48'], // [!code ++] + }, // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'decimals', // [!code ++] + }, // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'symbol', // [!code ++] + }, // [!code ++] + ] // [!code ++] +}) // [!code ++] +``` + +### Deprecated `useBalance` `unit` parameter and `formatted` return value + +Moving forward, `useBalance` will not accept the `unit` parameter or return a `formatted` value. Instead you can call `formatUnits` from Viem directly or use another number formatting library, like [dnum](https://github.com/bpierre/dnum) instead. + +```ts +import { formatUnits } from 'viem' // [!code ++] +import { useBalance } from 'wagmi' + +const result = useBalance({ + address: '0x4557B18E779944BFE9d78A672452331C186a9f48', + unit: 'ether', // [!code --] +}) +result.data!.formatted // [!code --] +formatUnits(result.data!.value, result.data!.decimals) // [!code ++] +``` + +### Deprecated `useToken` + +Moving forward, `useToken` is no longer supported. Use [`useReadContracts`](/react/api/hooks/useReadContracts) instead. + +```ts +import { useToken } from 'wagmi' // [!code --] +import { useReadContracts } from 'wagmi' // [!code ++] +import { erc20Abi } from 'viem' // [!code ++] + +const result = useToken({ // [!code --] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code --] +}) // [!code --] +const result = useReadContracts({ // [!code ++] + allowFailure: false, // [!code ++] + contracts: [ // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'decimals', // [!code ++] + }, // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'name', // [!code ++] + }, // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'symbol', // [!code ++] + }, // [!code ++] + { // [!code ++] + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', // [!code ++] + abi: erc20Abi, // [!code ++] + functionName: 'totalSupply', // [!code ++] + }, // [!code ++] + ] // [!code ++] +}) // [!code ++] +``` + +### Deprecated `formatUnits` parameters and return values + +The `formatUnits` parameter and related return values (e.g. `result.formatted`) are deprecated for the following hooks: + +- [`useEstimateFeesPerGas`](/react/api/hooks/useEstimateFeesPerGas) +- [`useToken`](/react/api/hooks/useToken) + +Instead you can call `formatUnits` from Viem directly or use another number formatting library, like [dnum](https://github.com/bpierre/dnum) instead. + +```ts +import { formatUnits } from 'viem' // [!code ++] + +const result = useToken({ + address: '0x6B175474E89094C44Da98b954EedeAC495271d0F', + formatUnits: 'ether', +}) +result.data!.totalSupply.formatted // [!code --] +formatUnits(result.data!.totalSupply.value, 18) // [!code ++] +``` + +This allows us to invert control to users so they can handle number formatting however they want, taking into account precision, localization, and more. + +### Renamed hooks + +The following hooks were renamed to better reflect their functionality and underlying [Viem](https://viem.sh) actions: + +- `useContractRead` is now [`useReadContract`](/react/api/hooks/useReadContract) +- `useContractReads` is now [`useReadContracts`](/react/api/hooks/useReadContracts) +- `useContractWrite` is now [`useWriteContract`](/react/api/hooks/useWriteContract) +- `useContractEvent` is now [`useWatchContractEvent`](/react/api/hooks/useWatchContractEvent) +- `useContractInfiniteReads` is now [`useInfiniteReadContracts`](/react/api/hooks/useInfiniteReadContracts) +- `useFeeData` is now [`useEstimateFeesPerGas`](/react/api/hooks/useEstimateFeesPerGas) +- `useSwitchNetwork` is now [`useSwitchChain`](/react/api/hooks/useSwitchChain) +- `useWaitForTransaction` is now [`useWaitForTransactionReceipt`](/react/api/hooks/useWaitForTransactionReceipt) + +### Miscellaneous + +- `WagmiConfigProps` renamed to [`WagmiProviderProps`](/react/api/WagmiProvider#parameters). +- `Context` renamed to [`WagmiContext`](/react/api/WagmiProvider#context). diff --git a/site/react/guides/read-from-contract.md b/site/react/guides/read-from-contract.md new file mode 100644 index 0000000000..b41f5c569d --- /dev/null +++ b/site/react/guides/read-from-contract.md @@ -0,0 +1,202 @@ +# Read from Contract + +The [`useReadContract` Hook](/react/api/hooks/useReadContract) allows you to read data on a smart contract, from a `view` or `pure` (read-only) function. They can only read the state of the contract, and cannot make any changes to it. Since read-only methods do not change the state of the contract, they do not require any gas to be executed, and can be called by any user without the need to pay for gas. + +The component below shows how to retrieve the token balance of an address from the [Wagmi Example](https://etherscan.io/token/0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2) contract + +:::code-group +```tsx [read-contract.tsx] +import { useReadContract } from 'wagmi' +import { wagmiContractConfig } from './contracts' + +function ReadContract() { + const { data: balance } = useReadContract({ + ...wagmiContractConfig, + functionName: 'balanceOf', + args: ['0x03A71968491d55603FFe1b11A9e23eF013f75bCF'], + }) + + return ( +
Balance: {balance?.toString()}
+ ) +} +``` +```ts [contracts.ts] +export const wagmiContractConfig = { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: [ + { + type: 'function', + name: 'balanceOf', + stateMutability: 'view', + inputs: [{ name: 'account', type: 'address' }], + outputs: [{ type: 'uint256' }], + }, + { + type: 'function', + name: 'totalSupply', + stateMutability: 'view', + inputs: [], + outputs: [{ name: 'supply', type: 'uint256' }], + }, + ], +} as const +``` +::: + +If `useReadContract` depends on another value (`address` in the example below), you can use the [`query.enabled`](/react/api/hooks/useReadContract#enabled) option to prevent the query from running until the dependency is ready. + +```tsx +const { data: balance } = useReadContract({ + ...wagmiContractConfig, + functionName: 'balanceOf', + args: [address], + query: { // [!code focus] + enabled: !!address, // [!code focus] + }, // [!code focus] +}) +``` + +## Loading & Error States + +The [`useReadContract` Hook](/react/api/hooks/useReadContract) also returns loading & error states, which can be used to display a loading indicator while the data is being fetched, or an error message if contract execution reverts. + +:::code-group + +```tsx [read-contract.tsx] +import { type BaseError, useReadContract } from 'wagmi' + +function ReadContract() { + const { + data: balance, + error, // [!code ++] + isPending // [!code ++] + } = useReadContract({ + ...wagmiContractConfig, + functionName: 'balanceOf', + args: ['0x03A71968491d55603FFe1b11A9e23eF013f75bCF'], + }) + + if (isPending) return
Loading...
// [!code ++] + + if (error) // [!code ++] + return ( // [!code ++] +
// [!code ++] + Error: {(error as BaseError).shortMessage || error.message} // [!code ++] +
// [!code ++] + ) // [!code ++] + + return ( +
Balance: {balance?.toString()}
+ ) +} +``` + +## Refetching On Blocks + +The [`useBlockNumber` Hook](/react/api/hooks/useBlockNumber) can be utilized to refetch or [invalidate](https://tanstack.com/query/latest/docs/framework/react/guides/query-invalidation) the contract data on a specific block interval. + +:::code-group +```tsx [read-contract.tsx (refetch)] +import { useEffect } from 'react' +import { useBlockNumber, useReadContract } from 'wagmi' + +function ReadContract() { + const { data: balance, refetch } = useReadContract({ + ...wagmiContractConfig, + functionName: 'balanceOf', + args: ['0x03A71968491d55603FFe1b11A9e23eF013f75bCF'], + }) + const { data: blockNumber } = useBlockNumber({ watch: true }) + + useEffect(() => { + // want to refetch every `n` block instead? use the modulo operator! + // if (blockNumber % 5 === 0) refetch() // refetch every 5 blocks + refetch() + }, [blockNumber]) + + return ( +
Balance: {balance?.toString()}
+ ) +} +``` +```tsx [read-contract.tsx (invalidate)] +import { useQueryClient } from '@tanstack/react-query' +import { useEffect } from 'react' +import { useBlockNumber, useReadContract } from 'wagmi' + +function ReadContract() { + const queryClient = useQueryClient() + const { data: balance, refetch } = useReadContract({ + ...wagmiContractConfig, + functionName: 'balanceOf', + args: ['0x03A71968491d55603FFe1b11A9e23eF013f75bCF'], + }) + const { data: blockNumber } = useBlockNumber({ watch: true }) + + useEffect(() => { + // if `useReadContract` is in a different hook/component, + // you can import `readContractQueryKey` from `'wagmi/query'` and + // construct a one-off query key to use for invalidation + queryClient.invalidateQueries({ queryKey }) + }, [blockNumber, queryClient]) + + return ( +
Balance: {balance?.toString()}
+ ) +} +``` +::: + +## Calling Multiple Functions + +We can use the [`useReadContract` Hook](/react/api/hooks/useReadContract) multiple times in a single component to call multiple functions on the same contract, but this ends up being hard to manage as the number of functions increases, especially when we also want to deal with loading & error states. + +Luckily, to make this easier, we can use the [`useReadContracts` Hook](/react/api/hooks/useReadContracts) to call multiple functions in a single call. + +:::code-group + +```tsx [read-contract.tsx] +import { type BaseError, useReadContracts } from 'wagmi' + +function ReadContract() { + const { + data, + error, + isPending + } = useReadContracts({ + contracts: [{ + ...wagmiContractConfig, + functionName: 'balanceOf', + args: ['0x03A71968491d55603FFe1b11A9e23eF013f75bCF'], + }, { + ...wagmiContractConfig, + functionName: 'ownerOf', + args: [69n], + }, { + ...wagmiContractConfig, + functionName: 'totalSupply', + }] + }) + const [balance, ownerOf, totalSupply] = data || [] + + if (isPending) return
Loading...
+ + if (error) + return ( +
+ Error: {(error as BaseError).shortMessage || error.message} +
+ ) + + return ( + <> +
Balance: {balance?.toString()}
+
Owner of Token 69: {ownerOf?.toString()}
+
Total Supply: {totalSupply?.toString()}
+ + ) +} +``` + +::: diff --git a/site/react/guides/send-transaction.md b/site/react/guides/send-transaction.md new file mode 100644 index 0000000000..a6c5c1887a --- /dev/null +++ b/site/react/guides/send-transaction.md @@ -0,0 +1,362 @@ +# Send Transaction + +The following guide teaches you how to send transactions in Wagmi. The example below builds on the [Connect Wallet guide](/react/guides/connect-wallet) and uses the [useSendTransaction](/react/api/hooks/useSendTransaction) & [useWaitForTransaction](/react/api/hooks/useWaitForTransactionReceipt) hooks. + +## Example + +Feel free to check out the example before moving on: + + + +## Steps + +### 1. Connect Wallet + +Follow the [Connect Wallet guide](/react/guides/connect-wallet) guide to get this set up. + +### 2. Create a new component + +Create your `SendTransaction` component that will contain the send transaction logic. + +::: code-group + +```tsx [send-transaction.tsx] +import * as React from 'react' + +export function SendTransaction() { + return ( +
+ + + +
+ ) +} +``` + +::: + +### 3. Add a form handler + +Next, we will need to add a handler to the form that will send the transaction when the user hits "Send". This will be a basic handler in this step. + +::: code-group + +```tsx [send-transaction.tsx] +import * as React from 'react' + +export function SendTransaction() { + async function submit(e: React.FormEvent) { // [!code ++] + e.preventDefault() // [!code ++] + const formData = new FormData(e.target as HTMLFormElement) // [!code ++] + const to = formData.get('address') as `0x${string}` // [!code ++] + const value = formData.get('value') as string // [!code ++] + } // [!code ++] + + return ( +
// [!code --] + // [!code ++] + + + +
+ ) +} +``` + +::: + +### 4. Hook up the `useSendTransaction` Hook + +Now that we have the form handler, we can hook up the [`useSendTransaction` Hook](/react/api/hooks/useSendTransaction) to send the transaction. + +::: code-group + +```tsx [send-transaction.tsx] +import * as React from 'react' +import { useSendTransaction } from 'wagmi' // [!code ++] +import { parseEther } from 'viem' // [!code ++] + +export function SendTransaction() { + const { data: hash, sendTransaction } = useSendTransaction() // [!code ++] + + async function submit(e: React.FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const to = formData.get('address') as `0x${string}` + const value = formData.get('value') as string + sendTransaction({ to, value: parseEther(value) }) // [!code ++] + } + + return ( +
+ + + + {hash &&
Transaction Hash: {hash}
} // [!code ++] +
+ ) +} +``` + +::: + +### 5. Add loading state (optional) + +We can optionally add a loading state to the "Send" button while we are waiting confirmation from the user's wallet. + +::: code-group + +```tsx [send-transaction.tsx] +import * as React from 'react' +import { useSendTransaction } from 'wagmi' +import { parseEther } from 'viem' + +export function SendTransaction() { + const { + data: hash, + isPending, // [!code ++] + sendTransaction + } = useSendTransaction() + + async function submit(e: React.FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const to = formData.get('address') as `0x${string}` + const value = formData.get('value') as string + sendTransaction({ to, value: parseEther(value) }) + } + + return ( +
+ + + + {hash &&
Transaction Hash: {hash}
} +
+ ) +} +``` + +::: + +### 6. Wait for transaction receipt (optional) + +We can also display the transaction confirmation status to the user by using the [`useWaitForTransactionReceipt` Hook](/react/api/hooks/useWaitForTransactionReceipt). + +::: code-group + +```tsx [send-transaction.tsx] +import * as React from 'react' +import { + useSendTransaction, + useWaitForTransactionReceipt // [!code ++] +} from 'wagmi' +import { parseEther } from 'viem' + +export function SendTransaction() { + const { + data: hash, + isPending, + sendTransaction + } = useSendTransaction() + + async function submit(e: React.FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const to = formData.get('address') as `0x${string}` + const value = formData.get('value') as string + sendTransaction({ to, value: parseEther(value) }) + } + + const { isLoading: isConfirming, isSuccess: isConfirmed } = // [!code ++] + useWaitForTransactionReceipt({ // [!code ++] + hash, // [!code ++] + }) // [!code ++] + + return ( +
+ + + + {hash &&
Transaction Hash: {hash}
} + {isConfirming &&
Waiting for confirmation...
} // [!code ++] + {isConfirmed &&
Transaction confirmed.
} // [!code ++] +
+ ) +} +``` + +::: + +### 7. Handle errors (optional) + +If the user rejects the transaction, or the user does not have enough funds to cover the transaction, we can display an error message to the user. + +::: code-group + +```tsx [send-transaction.tsx] +import * as React from 'react' +import { + type BaseError, // [!code ++] + useSendTransaction, + useWaitForTransactionReceipt +} from 'wagmi' +import { parseEther } from 'viem' + +export function SendTransaction() { + const { + data: hash, + error, // [!code ++] + isPending, + sendTransaction + } = useSendTransaction() + + async function submit(e: React.FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const to = formData.get('address') as `0x${string}` + const value = formData.get('value') as string + sendTransaction({ to, value: parseEther(value) }) + } + + const { isLoading: isConfirming, isSuccess: isConfirmed } = + useWaitForTransactionReceipt({ + hash, + }) + + return ( +
+ + + + {hash &&
Transaction Hash: {hash}
} + {isConfirming &&
Waiting for confirmation...
} + {isConfirmed &&
Transaction confirmed.
} + {error && ( // [!code ++] +
Error: {(error as BaseError).shortMessage || error.message}
// [!code ++] + )} // [!code ++] +
+ ) +} +``` + +::: + +### 8. Wire it up! + +Finally, we can wire up our Send Transaction component to our application's entrypoint. + +::: code-group + +```tsx [app.tsx] +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import { WagmiProvider, useAccount } from 'wagmi' +import { config } from './config' +import { SendTransaction } from './send-transaction' // [!code ++] + +const queryClient = new QueryClient() + +function App() { + return ( + + + // [!code ++] + + + ) +} +``` + +```tsx [send-transaction.tsx] +import * as React from 'react' +import { + type BaseError, + useSendTransaction, + useWaitForTransactionReceipt +} from 'wagmi' +import { parseEther } from 'viem' + +export function SendTransaction() { + const { + data: hash, + error, + isPending, + sendTransaction + } = useSendTransaction() + + async function submit(e: React.FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const to = formData.get('address') as `0x${string}` + const value = formData.get('value') as string + sendTransaction({ to, value: parseEther(value) }) + } + + const { isLoading: isConfirming, isSuccess: isConfirmed } = + useWaitForTransactionReceipt({ + hash, + }) + + return ( +
+ + + + {hash &&
Transaction Hash: {hash}
} + {isConfirming &&
Waiting for confirmation...
} + {isConfirmed &&
Transaction confirmed.
} + {error && ( +
Error: {(error as BaseError).shortMessage || error.message}
+ )} +
+ ) +} +``` + +```tsx [config.ts] +import { http, createConfig } from 'wagmi' +import { base, mainnet, optimism } from 'wagmi/chains' +import { injected, metaMask, safe, walletConnect } from 'wagmi/connectors' + +const projectId = '' + +export const config = createConfig({ + chains: [mainnet, base], + connectors: [ + injected(), + walletConnect({ projectId }), + metaMask(), + safe(), + ], + transports: { + [mainnet.id]: http(), + [base.id]: http(), + }, +}) +``` + +::: + +[See the Example.](#example) diff --git a/site/react/guides/ssr.md b/site/react/guides/ssr.md new file mode 100644 index 0000000000..131be1a2b7 --- /dev/null +++ b/site/react/guides/ssr.md @@ -0,0 +1,168 @@ +--- +outline: deep +--- + +# SSR + +Wagmi uses client-only external stores (such as `localStorage` and `mipd`) to show the user the most relevant data as quickly as possible on first render. + +However, the caveat of using these external client stores is that frameworks which incorporate SSR (such as Next.js) will throw hydration warnings on the client when it identifies mismatches between the server-rendered HTML and the client-rendered HTML. + +To stop this from happening, you can toggle on the [`ssr`](/react/api/createConfig#ssr) property in the Wagmi Config. + +```tsx +import { createConfig, http } from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' + +const config = createConfig({ // [!code focus:99] + chains: [mainnet, sepolia], + ssr: true, // [!code ++] + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +Turning on the `ssr` property means that content from the external stores will be hydrated on the client after the initial mount. + +## Persistence using Cookies + +As a result of turning on the `ssr` property, external persistent stores like `localStorage` will be hydrated on the client **after the initial mount**. + +This means that you will still see a flash of "empty" data on the client (e.g. a `"disconnected"` account instead of a `"reconnecting"` account, or an empty address instead of the last connected address) until after the first mount, when the store hydrates. + +In order to persist data between the server and the client, you can use cookies. + +### 1. Set up cookie storage + +First, we will set up cookie storage in the Wagmi Config. + +```tsx +import { + createConfig, + http, + cookieStorage, // [!code ++] + createStorage // [!code ++] +} from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' + +export function getConfig() { + return createConfig({ + chains: [mainnet, sepolia], + ssr: true, + storage: createStorage({ // [!code ++] + storage: cookieStorage, // [!code ++] + }), // [!code ++] + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, + }) +} +``` + +### 2. Hydrate the cookie + +Next, we will need to add some mechanisms to hydrate the stored cookie in Wagmi. + +#### Next.js App Directory + +In our `app/layout.tsx` file (a [Server Component](https://nextjs.org/docs/app/building-your-application/rendering/server-components)), we will need to extract the cookie from the `headers` function and pass it to [`cookieToInitialState`](/react/api/utilities/cookieToInitialState). + +We will need to pass this result to the [`initialState` property](/react/api/WagmiProvider#initialstate) of the `WagmiProvider`. The `WagmiProvider` **must** be in a Client Component tagged with `"use client"` (see `app/providers.tsx` tab). + +::: code-group +```tsx [app/layout.tsx] +import { type ReactNode } from 'react' +import { headers } from 'next/headers' // [!code ++] +import { cookieToInitialState } from 'wagmi' // [!code ++] + +import { getConfig } from './config' +import { Providers } from './providers' + +export default async function Layout({ children }: { children: ReactNode }) { + const initialState = cookieToInitialState( // [!code ++] + getConfig(), // [!code ++] + (await headers()).get('cookie') // [!code ++] + ) // [!code ++] + return ( + + + // [!code --] + // [!code ++] + {children} + + + + ) +} + +``` + +```tsx [app/providers.tsx] +'use client' + +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import { type ReactNode, useState } from 'react' +import { type State, WagmiProvider } from 'wagmi' + +import { getConfig } from './config' + +type Props = { + children: ReactNode, + initialState: State | undefined, // [!code ++] +} + +export function Providers({ children }: Props) { // [!code --] +export function Providers({ children, initialState }: Props) { // [!code ++] + const [config] = useState(() => getConfig()) + const [queryClient] = useState(() => new QueryClient()) + + return ( + // [!code --] + // [!code ++] + + {children} + + + ) +} + +``` + +```tsx [app/config.ts] +import { + createConfig, + http, + cookieStorage, + createStorage +} from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' + +export function getConfig() { + return createConfig({ + chains: [mainnet, sepolia], + ssr: true, + storage: createStorage({ // [!code ++] + storage: cookieStorage, // [!code ++] + }), // [!code ++] + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, + }) +} +``` +::: + +#### Next.js Pages Directory + +Would you like to contribute this content? Feel free to [open a Pull Request](https://github.com/wevm/wagmi/pulls)! + + +#### Vanilla SSR + +Would you like to contribute this content? Feel free to [open a Pull Request](https://github.com/wevm/wagmi/pulls)! + + diff --git a/site/react/guides/tanstack-query.md b/site/react/guides/tanstack-query.md new file mode 100644 index 0000000000..e491695d71 --- /dev/null +++ b/site/react/guides/tanstack-query.md @@ -0,0 +1,403 @@ +# TanStack Query + +Wagmi Hooks are not only a wrapper around the core [Wagmi Actions](/core/api/actions), but they also utilize [TanStack Query](https://tanstack.com/query/v5) to enable trivial and intuitive fetching, caching, synchronizing, and updating of asynchronous data in your React applications. + +Without an asynchronous data fetching abstraction, you would need to handle all the negative side-effects that comes as a result, such as: representing finite states (loading, error, success), handling race conditions, caching against a deterministic identifier, etc. + +## Queries & Mutations + +Wagmi Hooks represent either a **Query** or a **Mutation**. + +**Queries** are used for fetching data (e.g. fetching a block number, reading from a contract, etc), and are typically invoked on mount by default. All queries are coupled to a unique [Query Key](#query-keys), and can be used for further operations such as refetching, prefetching, or modifying the cached data. + +**Mutations** are used for mutating data (e.g. connecting/disconnecting accounts, writing to a contract, switching chains, etc), and are typically invoked in response to a user interaction. Unlike **Queries**, they are not coupled with a query key. + +## Terms + +- **Query**: An asynchronous data fetching (e.g. read data) operation that is tied against a unique Query Key. +- **Mutation**: An asynchronous mutating (e.g. create/update/delete data or side-effect) operation. +- **Query Key**: A unique identifier that is used to deterministically identify a query. It is typically a tuple of the query name and the query arguments. +- **Stale Data**: Data that is unused or inactive after a certain period of time. +- **Query Fetching**: The process of invoking an async query function. +- **Query Refetching**: The process of refetching **rendered** queries. +- **[Query Invalidation](https://tanstack.com/query/v5/docs/react/guides/query-invalidation)**: The process of marking query data as stale (e.g. inactive/unused), and refetching **rendered** queries. +- **[Query Prefetching](https://tanstack.com/query/v5/docs/react/guides/prefetching)**: The process of prefetching queries and seeding the cache. + +## Persistence via External Stores + +By default, TanStack Query persists all query data in-memory. This means that if you refresh the page, all in-memory query data will be lost. + +If you want to persist query data to an external storage, you can utilize TanStack Query's [`createSyncStoragePersister`](https://tanstack.com/query/v5/docs/react/plugins/createSyncStoragePersister) or [`createAsyncStoragePersister`](https://tanstack.com/query/v5/docs/react/plugins/createAsyncStoragePersister) to plug external storage like `localStorage`, `sessionStorage`, [IndexedDB](https://developer.mozilla.org/en-US/docs/Web/API/IndexedDB_API) or [`AsyncStorage`](https://reactnative.dev/docs/asyncstorage) (React Native). + +### Sync Storage + +Below is an example of how to set up Wagmi + TanStack Query with sync external storage like `localStorage` or `sessionStorage`. + +#### Install + +::: code-group +```bash [pnpm] +pnpm i @tanstack/query-sync-storage-persister @tanstack/react-query-persist-client +``` + +```bash [npm] +npm i @tanstack/query-sync-storage-persister @tanstack/react-query-persist-client +``` + +```bash [yarn] +yarn add @tanstack/query-sync-storage-persister @tanstack/react-query-persist-client +``` + +```bash [bun] +bun i @tanstack/query-sync-storage-persister @tanstack/react-query-persist-client +``` +::: + +#### Usage + +```tsx +// 1. Import modules. // [!code hl] +import { createSyncStoragePersister } from '@tanstack/query-sync-storage-persister' // [!code hl] +import { QueryClient } from '@tanstack/react-query' // [!code hl] +import { PersistQueryClientProvider } from '@tanstack/react-query-persist-client' // [!code hl] +import { WagmiProvider, deserialize, serialize } from 'wagmi' // [!code hl] + +// 2. Create a new Query Client with a default `gcTime`. // [!code hl] +const queryClient = new QueryClient({ // [!code hl] + defaultOptions: { // [!code hl] + queries: { // [!code hl] + gcTime: 1_000 * 60 * 60 * 24, // 24 hours // [!code hl] + }, // [!code hl] + }, // [!code hl] +}) // [!code hl] + +// 3. Set up the persister. // [!code hl] +const persister = createSyncStoragePersister({ // [!code hl] + serialize, // [!code hl] + storage: window.localStorage, // [!code hl] + deserialize, // [!code hl] +}) // [!code hl] + +function App() { + return ( + + {/* 4. Wrap app in PersistQueryClientProvider */} // [!code hl] + // [!code hl] + {/* ... */} + // [!code hl] + + ) +} +``` + +Read more about [Sync Storage Persistence](https://tanstack.com/query/v5/docs/react/plugins/createSyncStoragePersister). + +### Async Storage + +Below is an example of how to set up Wagmi + TanStack Query with async external storage like [`IndexedDB`](https://developer.mozilla.org/en-US/docs/Web/API/IndexedDB_API) or [`AsyncStorage`](https://reactnative.dev/docs/asyncstorage). + +#### Install + +::: code-group +```bash [pnpm] +pnpm i @tanstack/query-async-storage-persister @tanstack/react-query-persist-client +``` + +```bash [npm] +npm i @tanstack/query-async-storage-persister @tanstack/react-query-persist-client +``` + +```bash [yarn] +yarn add @tanstack/query-async-storage-persister @tanstack/react-query-persist-client +``` + +```bash [bun] +bun i @tanstack/query-async-storage-persister @tanstack/react-query-persist-client +``` +::: + +#### Usage + +```tsx +// 1. Import modules. // [!code hl] +import AsyncStorage from '@react-native-async-storage/async-storage' // [!code hl] +import { createAsyncStoragePersister } from '@tanstack/query-async-storage-persister' // [!code hl] +import { QueryClient } from '@tanstack/react-query' // [!code hl] +import { PersistQueryClientProvider } from '@tanstack/react-query-persist-client' // [!code hl] +import { WagmiProvider, deserialize, serialize } from 'wagmi' // [!code hl] + +// 2. Create a new Query Client with a default `gcTime`. // [!code hl] +const queryClient = new QueryClient({ // [!code hl] + defaultOptions: { // [!code hl] + queries: { // [!code hl] + gcTime: 1_000 * 60 * 60 * 24, // 24 hours // [!code hl] + }, // [!code hl] + }, // [!code hl] +}) // [!code hl] + +// 3. Set up the persister. // [!code hl] +const persister = createAsyncStoragePersister({ // [!code hl] + serialize, // [!code hl] + storage: AsyncStorage, // [!code hl] + deserialize, // [!code hl] +}) // [!code hl] + +function App() { + return ( + + {/* 4. Wrap app in PersistQueryClientProvider */} // [!code hl] + // [!code hl] + {/* ... */} + // [!code hl] + + ) +} +``` + +Read more about [Async Storage Persistence](https://tanstack.com/query/v5/docs/react/plugins/createAsyncStoragePersister). + +## Query Keys + +Query Keys are typically used to perform advanced operations on the query such as: invalidation, refetching, prefetching, etc. + +Wagmi exports Query Keys for every Hook, and they can be retrieved via the [Hook (React)](#hook-react) or via an [Import (Vanilla JS)](#import-vanilla-js). + +Read more about **Query Keys** on the [TanStack Query docs.](https://tanstack.com/query/v5/docs/react/guides/query-keys) + +### Hook (React) + +Each Hook returns a `queryKey` value. You would use this approach when you want to utilize the query key in a React component as it handles reactivity for you, unlike the [Import](#import-vanilla-js) method below. + +```ts +import { useBlock } from 'wagmi' // [!code hl] + +function App() { + const { queryKey } = useBlock() // [!code hl] +} +``` + +### Import (Vanilla JS) + +Each Hook has a corresponding `getQueryOptions` function that returns a query key. You would use this method when you want to utilize the query key outside of a React component in a Vanilla JS context, like in a utility function. + +```ts +import { getBlockQueryOptions } from 'wagmi/query' // [!code hl] +import { config } from './config' + +function perform() { + const { queryKey } = getBlockQueryOptions(config, { // [!code hl] + chainId: config.state.chainId // [!code hl] + }) // [!code hl] +} +``` + +::: warning + +The caveat of this method is that it does not handle reactivity for you (e.g. active account/chain changes, argument changes, etc). You would need to handle this yourself by explicitly passing through the arguments to `getQueryOptions`. + +::: + +## Invalidating Queries + +Invalidating a query is the process of marking the query data as stale (e.g. inactive/unused), and refetching the queries that are already rendered. + +Read more about **Invalidating Queries** on the [TanStack Query docs.](https://tanstack.com/query/v5/docs/react/guides/query-invalidation) + +#### Example: Watching a Users' Balance + +You may want to "watch" a users' balance, and invalidate the balance after each incoming block. We can invoke `invalidateQueries` inside a `useEffect` with the block number as it's only dependency – this will refetch all rendered balance queries when the `blockNumber` changes. + +```tsx +import { useQueryClient } from '@tanstack/react-query' +import { useEffect } from 'react' +import { useBlockNumber, useBalance } from 'wagmi' + +function App() { + const queryClient = useQueryClient() + const { data: blockNumber } = useBlockNumber({ watch: true }) // [!code hl] + const { data: balance, queryKey } = useBalance() // [!code hl] + + useEffect(() => { // [!code hl] + queryClient.invalidateQueries({ queryKey }) // [!code hl] + }, [blockNumber]) // [!code hl] + + return
{balance}
+} +``` + +#### Example: After User Interaction + +Maybe you want to invalidate a users' balance after some interaction. This would mark the balance as stale, and consequently refetch all rendered balance queries. + +```tsx +import { useBalance } from 'wagmi' + +function App() { + // 1. Extract `queryKey` from the useBalance Hook. // [!code hl] + const { queryKey } = useBalance() // [!code hl] + + return ( + + ) +} + +function Example() { + // 3. Other `useBalance` Hooks in your rendered React tree will be refetched! // [!code hl] + const { data: balance } = useBalance() // [!code hl] + + return
{balance}
+} +``` + +## Fetching Queries + +Fetching a query is the process of invoking the query function to retrieve data. If the query exists and the data is not invalidated or older than a given `staleTime`, then the data from the cache will be returned. Otherwise, the query will fetch for the latest data. + +::: code-group +```tsx [example.tsx] +import { getBlockQueryOptions } from 'wagmi' +import { queryClient } from './app' +import { config } from './config' + +export async function fetchBlockData() { + return queryClient.fetchQuery( // [!code hl] + getBlockQueryOptions(config, { // [!code hl] + chainId: config.state.chainId, // [!code hl] + } // [!code hl] + )) // [!code hl] +} +``` +<<< @/snippets/react/app.tsx[app.tsx] +<<< @/snippets/react/config.ts[config.ts] +::: + +## Retrieving & Updating Query Data + +You can retrieve and update query data imperatively with `getQueryData` and `setQueryData`. This is useful for scenarios where you want to retrieve or update a query outside of a React component. + +Note that these functions do not invalidate or refetch queries. + +::: code-group +```tsx [example.tsx] +import { getBlockQueryOptions } from 'wagmi' +import type { Block } from 'viem' +import { queryClient } from './app' +import { config } from './config' + +export function getPendingBlockData() { + return queryClient.getQueryData( // [!code hl] + getBlockQueryOptions(config, { // [!code hl] + chainId: config.state.chainId, // [!code hl] + tag: 'pending' // [!code hl] + } // [!code hl] + )) // [!code hl] +} + +export function setPendingBlockData(data: Block) { + return queryClient.setQueryData( // [!code hl] + getBlockQueryOptions(config, { // [!code hl] + chainId: config.state.chainId, // [!code hl] + tag: 'pending' // [!code hl] + }, // [!code hl] + data // [!code hl] + )) // [!code hl] +} +``` +<<< @/snippets/react/app.tsx[app.tsx] +<<< @/snippets/react/config.ts[config.ts] +::: + +## Prefetching Queries + +Prefetching a query is the process of fetching the data ahead of time and seeding the cache with the returned data. This is useful for scenarios where you want to fetch data before the user navigates to a page, or fetching data on the server to be reused on client hydration. + +Read more about **Prefetching Queries** on the [TanStack Query docs.](https://tanstack.com/query/v5/docs/react/guides/prefetching) + +#### Example: Prefetching in Event Handler + +```tsx +import { Link } from 'next/link' +import { getBlockQueryOptions } from 'wagmi' + +function App() { + const config = useConfig() + const chainId = useChainId() + + // 1. Set up a function to prefetch the block data. // [!code hl] + const prefetch = () => // [!code hl] + queryClient.prefetchQuery(getBlockQueryOptions(config, { chainId })) // [!code hl] + + + return ( + + Block details + + ) +} +``` + +## SSR + +It is possible to utilize TanStack Query's SSR strategies with Wagmi Hooks & Query Keys. Check out the [Server Rendering & Hydration](https://tanstack.com/query/v5/docs/react/guides/ssr) & [Advanced Server Rendering](https://tanstack.com/query/v5/docs/react/guides/advanced-ssr) guides. + +## Devtools + +TanStack Query includes dedicated [Devtools](https://tanstack.com/query/latest/docs/framework/react/devtools) that assist in visualizing and debugging your queries, their cache states, and much more. You will have to pass a custom `queryKeyFn` to your `QueryClient` for Devtools to correctly serialize BigInt values for display. Alternatively, You can use the `hashFn` from `@wagmi/core/query`, which already handles this serialization. + +#### Install + +::: code-group +```bash [pnpm] +pnpm i @tanstack/react-query-devtools +``` + +```bash [npm] +npm i @tanstack/react-query-devtools +``` + +```bash [yarn] +yarn add @tanstack/react-query-devtools +``` + +```bash [bun] +bun i @tanstack/react-query-devtools +``` +::: + +#### Usage + +```tsx +import { + QueryClient, + QueryClientProvider, +} from "@tanstack/react-query"; +import { ReactQueryDevtools } from "@tanstack/react-query-devtools"; // [!code hl] +import { hashFn } from "@wagmi/core/query"; // [!code hl] + +const queryClient = new QueryClient({ + defaultOptions: { // [!code hl] + queries: { // [!code hl] + queryKeyHashFn: hashFn, // [!code hl] + }, // [!code hl] + }, // [!code hl] +}); +``` diff --git a/site/react/guides/testing.md b/site/react/guides/testing.md new file mode 100644 index 0000000000..fd198fa058 --- /dev/null +++ b/site/react/guides/testing.md @@ -0,0 +1,2 @@ +# Testing + diff --git a/site/react/guides/viem.md b/site/react/guides/viem.md new file mode 100644 index 0000000000..6539b3fe61 --- /dev/null +++ b/site/react/guides/viem.md @@ -0,0 +1,150 @@ +# Viem + +[Viem](https://viem.sh) is a low-level TypeScript Interface for Ethereum that enables developers to interact with the Ethereum blockchain, including: JSON-RPC API abstractions, Smart Contract interaction, wallet & signing implementations, coding/parsing utilities and more. + +**Wagmi Core** is essentially a wrapper over **Viem** that provides multi-chain functionality via [Wagmi Config](/react/api/createConfig) and automatic account management via [Connectors](/react/api/connectors). + +## Leveraging Viem Actions + +All of the core [Wagmi Hooks](/react/api/actions) are friendly wrappers around [Viem Actions](https://viem.sh/docs/actions/public/introduction.html) that inject a multi-chain and connector aware [Wagmi Config](/react/api/createConfig). + +There may be cases where you might want to dig deeper and utilize Viem Actions directly (maybe a Hook doesn't exist in Wagmi yet). In these cases, you can create your own custom Wagmi Hook by importing Viem Actions directly via `viem/actions` and plugging in a Viem Client returned by the [`useClient` Hook](/react/api/hooks/useClient). + +The example below demonstrates two different ways to utilize Viem Actions: + +1. **Tree-shakable Actions (recommended):** Uses `useClient` (for public actions) and `useConnectorClient` (for wallet actions). +2. **Client Actions:** Uses `usePublicClient` (for public actions) and `useWalletClient` (for wallet actions). + +::: tip + +It is highly recommended to use the **tree-shakable** method to ensure that you are only pulling modules you use, and keep your bundle size low. + +::: + +::: code-group + +```tsx [Tree-shakable Actions] +// 1. Import modules. +import { useMutation, useQuery } from '@tanstack/react-query' +import { http, createConfig, useClient, useConnectorClient } from 'wagmi' +import { base, mainnet, optimism, zora } from 'wagmi/chains' +import { getLogs, watchAsset } from 'viem/actions' + +// 2. Set up a Wagmi Config +export const config = createConfig({ + chains: [base, mainnet, optimism, zora], + transports: { + [base.id]: http(), + [mainnet.id]: http(), + [optimism.id]: http(), + [zora.id]: http(), + }, +}) + +function Example() { + // 3. Extract a Viem Client for the current active chain. // [!code hl] + const publicClient = useClient({ config }) // [!code hl] + + // 4. Create a "custom" Query Hook that utilizes the Client. // [!code hl] + const { data: logs } = useQuery({ // [!code hl] + queryKey: ['logs', publicClient.uid], // [!code hl] + queryFn: () => getLogs(publicClient, /* ... */) // [!code hl] + }) // [!code hl] + + // 5. Extract a Viem Client for the current active chain & account. // [!code hl] + const { data: walletClient } = useConnectorClient({ config }) // [!code hl] + + // 6. Create a "custom" Mutation Hook that utilizes the Client. // [!code hl] + const { mutate } = useMutation({ // [!code hl] + mutationFn: (asset) => watchAsset(walletClient, asset) // [!code hl] + }) // [!code hl] + + return ( +
+ {/* ... */} +
+ ) +} +``` + +```tsx [Client Actions] +// 1. Import modules. +import { useMutation, useQuery } from '@tanstack/react-query' +import { http, createConfig, useClient, useConnectorClient } from 'wagmi' +import { base, mainnet, optimism, zora } from 'wagmi/chains' + +// 2. Set up a Wagmi Config +export const config = createConfig({ + chains: [base, mainnet, optimism, zora], + transports: { + [base.id]: http(), + [mainnet.id]: http(), + [optimism.id]: http(), + [zora.id]: http(), + }, +}) + +function Example() { + // 3. Extract a Viem Client for the current active chain. // [!code hl] + const publicClient = useClient({ config }) // [!code hl] + + // 4. Create a "custom" Query Hook that utilizes the Client. // [!code hl] + const { data: logs } = useQuery({ // [!code hl] + queryKey: ['logs', publicClient.uid], // [!code hl] + queryFn: () => publicClient.getLogs(/* ... */) // [!code hl] + }) // [!code hl] + + // 5. Extract a Viem Client for the current active chain & account. // [!code hl] + const { data: walletClient } = useConnectorClient({ config }) // [!code hl] + + // 6. Create a "custom" Mutation Hook that utilizes the Client. // [!code hl] + const { mutate } = useMutation({ // [!code hl] + mutationFn: (asset) => walletClient.watchAsset(asset) // [!code hl] + }) // [!code hl] + + return ( +
+ {/* ... */} +
+ ) +} +``` + +::: + +## Private Key & Mnemonic Accounts + +It is possible to utilize Viem's [Private Key & Mnemonic Accounts](https://viem.sh/docs/accounts/local.html) with Wagmi by explicitly passing through the account via the `account` argument on Wagmi Actions. + +```tsx +import { http, createConfig, useSendTransaction } from 'wagmi' +import { base, mainnet, optimism, zora } from 'wagmi/chains' +import { parseEther } from 'viem' +import { privateKeyToAccount } from 'viem/accounts' + +export const config = createConfig({ + chains: [base, mainnet, optimism, zora], + transports: { + [base.id]: http(), + [mainnet.id]: http(), + [optimism.id]: http(), + [zora.id]: http(), + }, +}) + +const account = privateKeyToAccount('0x...') // [!code hl] + +function Example() { + const { data: hash } = useSendTransaction({ + account, // [!code hl] + to: '0xa5cc3c03994DB5b0d9A5eEdD10CabaB0813678AC', + value: parseEther('0.001') + }) +} +``` + +::: info + +Wagmi currently does not support hoisting Private Key & Mnemonic Accounts to the top-level Wagmi Config – meaning you have to explicitly pass through the account to every Action. If you feel like this is a feature that should be added, please [open an discussion](https://github.com/wevm/wagmi/discussions/new?category=ideas). + +::: diff --git a/site/react/guides/write-to-contract.md b/site/react/guides/write-to-contract.md new file mode 100644 index 0000000000..65914ae981 --- /dev/null +++ b/site/react/guides/write-to-contract.md @@ -0,0 +1,438 @@ +# Write to Contract + +The [`useWriteContract` Hook](/react/api/hooks/useWriteContract) allows you to mutate data on a smart contract, from a `payable` or `nonpayable` (write) function. These types of functions require gas to be executed, hence a transaction is broadcasted in order to change the state. + +In the guide below, we will teach you how to implement a "Mint NFT" form that takes in a dynamic argument (token ID) using Wagmi. The example below builds on the [Connect Wallet guide](/react/guides/connect-wallet) and uses the [useWriteContract](/react/api/hooks/useWriteContract) & [useWaitForTransaction](/react/api/hooks/useWaitForTransactionReceipt) hooks. + +If you have already completed the [Sending Transactions guide](/react/guides/send-transaction), this guide will look very similar! That's because writing to a contract internally broadcasts & sends a transaction. + +## Example + +Feel free to check out the example before moving on: + + + +## Steps + +### 1. Connect Wallet + +Follow the [Connect Wallet guide](/react/guides/connect-wallet) guide to get this set up. + +### 2. Create a new component + +Create your `MintNFT` component that will contain the Mint NFT logic. + +::: code-group + +```tsx [mint-nft.tsx] +import * as React from 'react' + +export function MintNFT() { + return ( +
+ + +
+ ) +} +``` + +::: + +### 3. Add a form handler + +Next, we will need to add a handler to the form that will send the transaction when the user hits "Mint". This will be a basic handler in this step. + +::: code-group + +```tsx [mint-nft.tsx] +import * as React from 'react' + +export function MintNFT() { + async function submit(e: React.FormEvent) { // [!code ++] + e.preventDefault() // [!code ++] + const formData = new FormData(e.target as HTMLFormElement) // [!code ++] + const tokenId = formData.get('tokenId') as string // [!code ++] + } // [!code ++] + + return ( +
// [!code --] + // [!code ++] + + +
+ ) +} +``` + +::: + +### 4. Hook up the `useWriteContract` Hook + +Now that we have the form handler, we can hook up the [`useWriteContract` Hook](/react/api/hooks/useWriteContract) to send the transaction. + +::: code-group + +```tsx [mint-nft.tsx] +import * as React from 'react' +import { useWriteContract } from 'wagmi' // [!code ++] +import { abi } from './abi' // [!code ++] + +export function MintNFT() { + const { data: hash, writeContract } = useWriteContract() // [!code ++] + + async function submit(e: React.FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const tokenId = formData.get('tokenId') as string + writeContract({ // [!code ++] + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', // [!code ++] + abi, // [!code ++] + functionName: 'mint', // [!code ++] + args: [BigInt(tokenId)], // [!code ++] + }) // [!code ++] + } + + return ( +
+ + + {hash &&
Transaction Hash: {hash}
} // [!code ++] +
+ ) +} +``` + +```ts [abi.ts] +export const abi = [ + { + name: 'mint', + type: 'function', + stateMutability: 'nonpayable', + inputs: [{ internalType: 'uint32', name: 'tokenId', type: 'uint32' }], + outputs: [], + }, +] as const +``` + +::: + +### 5. Add loading state (optional) + +We can optionally add a loading state to the "Mint" button while we are waiting confirmation from the user's wallet. + +::: code-group + +```tsx [mint-nft.tsx] +import * as React from 'react' +import { useWriteContract } from 'wagmi' +import { abi } from './abi' + +export function MintNFT() { + const { + data: hash, + isPending, // [!code ++] + writeContract + } = useWriteContract() + + async function submit(e: React.FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const tokenId = formData.get('tokenId') as string + writeContract({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'mint', + args: [BigInt(tokenId)], + }) + } + + return ( +
+ + + {hash &&
Transaction Hash: {hash}
} +
+ ) +} +``` + +```ts [abi.ts] +export const abi = [ + { + name: 'mint', + type: 'function', + stateMutability: 'nonpayable', + inputs: [{ internalType: 'uint32', name: 'tokenId', type: 'uint32' }], + outputs: [], + }, +] as const +``` + +::: + +### 6. Wait for transaction receipt (optional) + +We can also display the transaction confirmation status to the user by using the [`useWaitForTransactionReceipt` Hook](/react/api/hooks/useWaitForTransactionReceipt). + +::: code-group + +```tsx [mint-nft.tsx] +import * as React from 'react' +import { + useWaitForTransactionReceipt, // [!code ++] + useWriteContract +} from 'wagmi' +import { abi } from './abi' + +export function MintNFT() { + const { + data: hash, + isPending, + writeContract + } = useWriteContract() + + async function submit(e: React.FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const tokenId = formData.get('tokenId') as string + writeContract({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'mint', + args: [BigInt(tokenId)], + }) + } + + const { isLoading: isConfirming, isSuccess: isConfirmed } = // [!code ++] + useWaitForTransactionReceipt({ // [!code ++] + hash, // [!code ++] + }) // [!code ++] + + return ( +
+ + + {hash &&
Transaction Hash: {hash}
} + {isConfirming &&
Waiting for confirmation...
} // [!code ++] + {isConfirmed &&
Transaction confirmed.
} // [!code ++] +
+ ) +} +``` + +```ts [abi.ts] +export const abi = [ + { + name: 'mint', + type: 'function', + stateMutability: 'nonpayable', + inputs: [{ internalType: 'uint32', name: 'tokenId', type: 'uint32' }], + outputs: [], + }, +] as const +``` + +::: + +### 7. Handle errors (optional) + +If the user rejects the transaction, or the contract reverts, we can display an error message to the user. + +::: code-group + +```tsx [mint-nft.tsx] +import * as React from 'react' +import { + type BaseError, // [!code ++] + useWaitForTransactionReceipt, + useWriteContract +} from 'wagmi' +import { abi } from './abi' + +export function MintNFT() { + const { + data: hash, + error, // [!code ++] + isPending, + writeContract + } = useWriteContract() + + async function submit(e: React.FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const tokenId = formData.get('tokenId') as string + writeContract({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'mint', + args: [BigInt(tokenId)], + }) + } + + const { isLoading: isConfirming, isSuccess: isConfirmed } = + useWaitForTransactionReceipt({ + hash, + }) + + return ( +
+ + + {hash &&
Transaction Hash: {hash}
} + {isConfirming &&
Waiting for confirmation...
} + {isConfirmed &&
Transaction confirmed.
} + {error && ( // [!code ++] +
Error: {(error as BaseError).shortMessage || error.message}
// [!code ++] + )} // [!code ++] +
+ ) +} +``` + +```ts [abi.ts] +export const abi = [ + { + name: 'mint', + type: 'function', + stateMutability: 'nonpayable', + inputs: [{ internalType: 'uint32', name: 'tokenId', type: 'uint32' }], + outputs: [], + }, +] as const +``` + +::: + +### 8. Wire it up! + +Finally, we can wire up our Mint NFT component to our application's entrypoint. + +::: code-group + +```tsx [app.tsx] +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import { WagmiProvider, useAccount } from 'wagmi' +import { config } from './config' +import { MintNft } from './mint-nft' // [!code ++] + +const queryClient = new QueryClient() + +function App() { + return ( + + + // [!code ++] + + + ) +} +``` + +```tsx [mint-nft.tsx] +import * as React from 'react' +import { + type BaseError, + useWaitForTransactionReceipt, + useWriteContract +} from 'wagmi' +import { abi } from './abi' + +export function MintNFT() { + const { + data: hash, + error, + isPending, + writeContract + } = useWriteContract() + + async function submit(e: React.FormEvent) { + e.preventDefault() + const formData = new FormData(e.target as HTMLFormElement) + const tokenId = formData.get('tokenId') as string + writeContract({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi, + functionName: 'mint', + args: [BigInt(tokenId)], + }) + } + + const { isLoading: isConfirming, isSuccess: isConfirmed } = + useWaitForTransactionReceipt({ + hash, + }) + + return ( +
+ + + {hash &&
Transaction Hash: {hash}
} + {isConfirming &&
Waiting for confirmation...
} + {isConfirmed &&
Transaction confirmed.
} + {error && ( +
Error: {(error as BaseError).shortMessage || error.message}
+ )} +
+ ) +} +``` + +```ts [abi.ts] +export const abi = [ + { + name: 'mint', + type: 'function', + stateMutability: 'nonpayable', + inputs: [{ internalType: 'uint32', name: 'tokenId', type: 'uint32' }], + outputs: [], + }, +] as const +``` + +```tsx [config.ts] +import { http, createConfig } from 'wagmi' +import { base, mainnet, optimism } from 'wagmi/chains' +import { injected, metaMask, safe, walletConnect } from 'wagmi/connectors' + +const projectId = '' + +export const config = createConfig({ + chains: [mainnet, base], + connectors: [ + injected(), + walletConnect({ projectId }), + metaMask(), + safe(), + ], + transports: { + [mainnet.id]: http(), + [base.id]: http(), + }, +}) +``` + +::: + +[See the Example.](#example) diff --git a/site/react/installation.md b/site/react/installation.md new file mode 100644 index 0000000000..7dd8306796 --- /dev/null +++ b/site/react/installation.md @@ -0,0 +1,56 @@ + + +# Installation + +Install Wagmi via your package manager, a ` +``` + +Check out the React docs for info on how to use [React without JSX](https://react.dev/reference/react/createElement#creating-an-element-without-jsx). + + diff --git a/site/react/typescript.md b/site/react/typescript.md new file mode 100644 index 0000000000..1ed9d4246e --- /dev/null +++ b/site/react/typescript.md @@ -0,0 +1,302 @@ + + +# TypeScript + +## Requirements + +Wagmi is designed to be as type-safe as possible! Things to keep in mind: + +- Types currently require using TypeScript {{typescriptVersion}}. +- [TypeScript doesn't follow semver](https://www.learningtypescript.com/articles/why-typescript-doesnt-follow-strict-semantic-versioning) and often introduces breaking changes in minor releases. +- Changes to types in this repository are considered non-breaking and are usually released as patch changes (otherwise every type enhancement would be a major version!). +- It is highly recommended that you lock your `wagmi` and `typescript` versions to specific patch releases and upgrade with the expectation that types may be fixed or upgraded between any release. +- The non-type-related public API of Wagmi still follows semver very strictly. + +To ensure everything works correctly, make sure your `tsconfig.json` has [`strict`](https://www.typescriptlang.org/tsconfig#strict) mode set to `true`. + +::: code-group +```json [tsconfig.json] +{ + "compilerOptions": { + "strict": true + } +} +``` +::: + +## Config Types + +By default React Context does not work well with type inference. To support strong type-safety across the React Context boundary, there are two options available: + +- Declaration merging to "register" your `config` globally with TypeScript. +- `config` property to pass your `config` directly to hooks. + +### Declaration Merging + +[Declaration merging](https://www.typescriptlang.org/docs/handbook/declaration-merging.html) allows you to "register" your `config` globally with TypeScript. The `Register` type enables Wagmi to infer types in places that wouldn't normally have access to type info via React Context alone. + +To set this up, add the following declaration to your project. Below, we co-locate the declaration merging and the `config` set up. + +```ts +import { createConfig, http } from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' + +declare module 'wagmi' { // [!code focus] + interface Register { // [!code focus] + config: typeof config // [!code focus] + } // [!code focus] +} // [!code focus] + +export const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +Since the `Register` type is global, you only need to add it once in your project. Once set up, you will get strong type-safety across your entire project. For example, query hooks will type `chainId` based on your `config`'s `chains`. + +```ts twoslash +// @errors: 2322 +import { type Config } from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' + +declare module 'wagmi' { + interface Register { + config: Config + } +} +// ---cut--- +import { useBlockNumber } from 'wagmi' + +useBlockNumber({ chainId: 123 }) +``` + +You just saved yourself a runtime error and you didn't even need to pass your `config`. 🎉 + +### Hook `config` Property + +For cases where you have more than one Wagmi `config` or don't want to use the declaration merging approach, you can pass a specific `config` directly to hooks via the `config` property. + +```ts +import { createConfig, http } from 'wagmi' +import { mainnet, optimism } from 'wagmi/chains' + +export const configA = createConfig({ // [!code focus] + chains: [mainnet], // [!code focus] + transports: { // [!code focus] + [mainnet.id]: http(), // [!code focus] + }, // [!code focus] +}) // [!code focus] + +export const configB = createConfig({ // [!code focus] + chains: [optimism], // [!code focus] + transports: { // [!code focus] + [optimism.id]: http(), // [!code focus] + }, // [!code focus] +}) // [!code focus] +``` + +As you expect, `chainId` is inferred correctly for each `config`. + +```ts twoslash +// @errors: 2322 +import { type Config } from 'wagmi' +import { mainnet, optimism } from 'wagmi/chains' + +declare const configA: Config +declare const configB: Config +// ---cut--- +import { useBlockNumber } from 'wagmi' + +useBlockNumber({ chainId: 123, config: configA }) +useBlockNumber({ chainId: 123, config: configB }) +``` + +This approach is more explicit, but works well for advanced use-cases, if you don't want to use React Context or declaration merging, etc. + +## Const-Assert ABIs & Typed Data + +Wagmi can infer types based on [ABIs](https://docs.soliditylang.org/en/latest/abi-spec.html#json) and [EIP-712](https://eips.ethereum.org/EIPS/eip-712) Typed Data definitions, powered by [Viem](https://viem.sh) and [ABIType](https://github.com/wevm/abitype). This achieves full end-to-end type-safety from your contracts to your frontend and enlightened developer experience by autocompleting ABI item names, catching misspellings, inferring argument and return types (including overloads), and more. + +For this to work, you must either [const-assert](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-4.html#const-assertions) ABIs and Typed Data (more info below) or define them inline. For example, `useReadContract`'s `abi` configuration parameter: + +```ts +const { data } = useReadContract({ + abi: […], // <--- defined inline // [!code focus] +}) +``` + +```ts +const abi = […] as const // <--- const assertion // [!code focus] +const { data } = useReadContract({ abi }) +``` + +If type inference isn't working, it's likely you forgot to add a `const` assertion or define the configuration parameter inline. Also, make sure your ABIs, Typed Data definitions, and [TypeScript configuration](#requirements) are valid and set up correctly. + +::: tip +Unfortunately [TypeScript doesn't support importing JSON `as const` yet](https://github.com/microsoft/TypeScript/issues/32063). Check out the [Wagmi CLI](/cli/getting-started) to help with this! It can automatically fetch ABIs from Etherscan and other block explorers, resolve ABIs from your Foundry/Hardhat projects, generate React Hooks, and more. +::: + +Anywhere you see the `abi` or `types` configuration property, you can likely use const-asserted or inline ABIs and Typed Data to get type-safety and inference. These properties are also called out in the docs. + +Here's what [`useReadContract`](/react/api/hooks/useReadContract) looks like with and without a const-asserted `abi` property. + +::: code-group +```ts twoslash [Const-Asserted] +const erc721Abi = [ + { + name: 'balanceOf', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'address', name: 'owner' }], + outputs: [{ type: 'uint256' }], + }, + { + name: 'isApprovedForAll', + type: 'function', + stateMutability: 'view', + inputs: [ + { type: 'address', name: 'owner' }, + { type: 'address', name: 'operator' }, + ], + outputs: [{ type: 'bool' }], + }, + { + name: 'getApproved', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'address' }], + }, + { + name: 'ownerOf', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'address' }], + }, + { + name: 'tokenURI', + type: 'function', + stateMutability: 'pure', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'string' }], + }, +] as const +// ---cut--- +import { useReadContract } from 'wagmi' + +const { data } = useReadContract({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: erc721Abi, + functionName: 'balanceOf', + // ^? + + + + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e'], + // ^? +}) + +data +// ^? +``` +```ts twoslash [Not Const-Asserted] +declare const erc721Abi: { + name: string; + type: string; + stateMutability: string; + inputs: { + type: string; + name: string; + }[]; + outputs: { + type: string; + }[]; +}[] +// ---cut--- +import { useReadContract } from 'wagmi' + +const { data } = useReadContract({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: erc721Abi, + functionName: 'balanceOf', + // ^? + + + + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e'], + // ^? +}) + +data +// ^? +``` +::: + +
+
+ +You can prevent runtime errors and be more productive by making sure your ABIs and Typed Data definitions are set up appropriately. 🎉 + +```ts twoslash +// @errors: 2820 +const erc721Abi = [ + { + name: 'balanceOf', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'address', name: 'owner' }], + outputs: [{ type: 'uint256' }], + }, + { + name: 'isApprovedForAll', + type: 'function', + stateMutability: 'view', + inputs: [ + { type: 'address', name: 'owner' }, + { type: 'address', name: 'operator' }, + ], + outputs: [{ type: 'bool' }], + }, + { + name: 'getApproved', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'address' }], + }, + { + name: 'ownerOf', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'address' }], + }, + { + name: 'tokenURI', + type: 'function', + stateMutability: 'pure', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'string' }], + }, +] as const +// ---cut--- +import { useReadContract } from 'wagmi' + +useReadContract({ + abi: erc721Abi, + functionName: 'balanecOf', +}) +``` + +## Configure Internal Types + +For advanced use-cases, you may want to configure Wagmi's internal types. Most of Wagmi's types relating to ABIs and EIP-712 Typed Data are powered by [ABIType](https://github.com/wevm/abitype). See the [ABIType docs](https://abitype.dev) for more info on how to configure types. diff --git a/site/react/why.md b/site/react/why.md new file mode 100644 index 0000000000..3b4bf2b89b --- /dev/null +++ b/site/react/why.md @@ -0,0 +1,46 @@ +# Why Wagmi + +## The Problems + +Building Ethereum applications is hard. Apps need to support connecting wallets, multiple chains, signing messages and data, sending transactions, listening for events and state changes, refreshing stale blockchain data, and much more. This is all on top of solving for app-specific use-cases and providing polished user experiences. + +The ecosystem is also continuously evolving, meaning you need to adapt to new improvements or get left behind. App developers should not need to worry about connecting tens of different wallets, the intricacies of multi-chain support, typos accidentally sending an order of magnitude more ETH or calling a misspelled contract function, or accidentally spamming their RPC provider, costing thousands in compute units. + +Wagmi solves all these problems and more — allowing app developers to focus on building high-quality and performant experiences for Ethereum — by focusing on **developer experience**, **performance**, **feature coverage**, and **stability.** + +## Developer Experience + +Wagmi delivers a great developer experience through modular and composable APIs, automatic type safety and inference, and comprehensive documentation. + +It provides developers with intuitive building blocks to build their Ethereum apps. While Wagmi's APIs might seem more verbose at first, it makes Wagmi's modular building blocks extremely flexible. Easy to move around, change, and remove. It also allows developers to better understand Ethereum concepts as well as understand _what_ and _why_ certain properties are being passed through. Learning how to use Wagmi is a great way to learn how to interact with Ethereum in general. + +Wagmi also provides [strongly typed APIs](/react/typescript), allowing consumers to get the best possible experience through [autocomplete](https://twitter.com/awkweb/status/1555678944770367493), [type inference](https://twitter.com/jakemoxey/status/1570244174502588417?s=20), as well as static validation. You often just need to provide an ABI and Wagmi can help you autocomplete your way to success, identify type errors before your users do, drill into blockchain errors [at compile and runtimes](/react/guides/error-handling) with surgical precision, and much more. + +The API documentation is comprehensive and contains usage info for _every_ module in Wagmi. The core team uses a [documentation](https://gist.github.com/zsup/9434452) and [test driven](https://en.wikipedia.org/wiki/Test-driven_development#:~:text=Test%2Ddriven%20development%20(TDD),software%20against%20all%20test%20cases.) development approach to building modules, which leads to predictable and stable APIs. + +## Performance + +Performance is critical for applications on all sizes. Slow page load and interactions can cause users to stop using applications. Wagmi uses and is built by the same team behind [Viem](https://viem.sh), the most performant production-ready Ethereum library. + +End users should not be required to download a module of over 100kB in order to interact with Ethereum. Wagmi is optimized for tree-shaking and dead-code elimination, allowing apps to minimize bundle size for fast page load times. + +Data layer performance is also critical. Slow, unnecessary, and manual data fetching can make apps unusable and cost thousands in RPC compute units. Wagmi supports caching, deduplication, persistence, and much more through [TanStack Query](/react/guides/tanstack-query). + +## Feature Coverage + +Wagmi supports the most popular and commonly-used Ethereum features out of the box with 40+ React Hooks for accounts, wallets, contracts, transactions, signing, ENS, and more. Wagmi also supports just about any wallet out there through official [connectors](/react/api/connectors), [EIP-6963 support](/react/api/createConfig#multiinjectedproviderdiscovery), and [extensible API](/dev/creating-connectors). + +If you need lower-level control, you can always drop down to [Wagmi Core](/core/getting-started) or [Viem](https://viem.sh), which Wagmi uses internally to perform blockchain operations. Wagmi also manages multi-chain support automatically so developers can focus on their applications instead of adding custom code. + +Finally, Wagmi has a [CLI](/cli/getting-started) to manage ABIs as well as a robust ecosystem of third-party libraries, like [ConnectKit](https://docs.family.co/connectkit), [RainbowKit](https://www.rainbowkit.com), [AppKit](https://walletconnect.com/appkit), [Dynamic](https://www.dynamic.xyz), [Privy](https://privy.io), and many more, so you can get started quickly without needing to build everything from scratch. + +## Stability + +Stability is a fundamental principle for Wagmi. Many organizations, large and small, rely heavily on Wagmi and expect it to be entirely stable for their users and applications. + +Wagmi's test suite runs against forked Ethereum nodes to make sure functions work across chains. The test suite also runs type tests against many different versions of peer dependencies, like TypeScript, to ensure compatibility with the latest releases of other popular software. + +Wagmi follows semver so developers can upgrade between versions with confidence. Starting with Wagmi v2, new functionality will be opt-in with old functionality being deprecated alongside the new features. This means upgrading to the latest major versions will not require immediate changes. + +Lastly, the core team works full-time on Wagmi and [related projects](https://github.com/wevm), and is constantly improving Wagmi and keeping it up-to-date with industry trends and changes. + diff --git a/site/shared/connectors/coinbaseWallet.md b/site/shared/connectors/coinbaseWallet.md new file mode 100644 index 0000000000..de70807aef --- /dev/null +++ b/site/shared/connectors/coinbaseWallet.md @@ -0,0 +1,160 @@ + + +# coinbaseWallet + +Connector for the [Coinbase Wallet SDK](https://github.com/coinbase/coinbase-wallet-sdk). + +## Import + +```ts-vue +import { coinbaseWallet } from '{{connectorsPackageName}}' +``` + +## Usage + +```ts-vue +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' +import { coinbaseWallet } from '{{connectorsPackageName}}' // [!code hl] + +export const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [coinbaseWallet()], // [!code hl] + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +:::warning +Before going to production, it is highly recommended to set an [`appName`](#appname) and [`appLogoUrl`](#applogourl) for your application that can be displayed upon connection to the wallet. +::: + +## Parameters + +```ts-vue +import { type CoinbaseWalletParameters } from '{{connectorsPackageName}}' +``` + +Check out the [Coinbase Wallet SDK docs](https://github.com/coinbase/coinbase-wallet-sdk) for more info. + +### appName + +`string` + +Application name. + +```ts-vue +import { coinbaseWallet } from '{{connectorsPackageName}}' + +const connector = coinbaseWallet({ + appName: 'My Wagmi App', // [!code focus] +}) +``` + +### appLogoUrl + +`string | null | undefined` + +Application logo image URL; favicon is used if unspecified. + +```ts-vue +import { coinbaseWallet } from '{{connectorsPackageName}}' + +const connector = coinbaseWallet({ + appName: 'My Wagmi App', + appLogoUrl: 'https://example.com/myLogoUrl.png', // [!code focus] +}) +``` + +### headlessMode + +`boolean | undefined` + +- Whether or not onboarding overlay popup should be displayed. +- `headlessMode` will be removed in the next major version. Upgrade to [`version: '4'`](#version). + +```ts-vue +import { coinbaseWallet } from '{{connectorsPackageName}}' + +const connector = coinbaseWallet({ + appName: 'My Wagmi App', + headlessMode: false, // [!code focus] +}) +``` + +### preference + +`"all" | "eoaOnly" | "smartWalletOnly"` + +Preference for the type of wallet to display. + +- `'eoaOnly'`: Uses EOA Browser Extension or Mobile Coinbase Wallet. +- `'smartWalletOnly'`: Displays Smart Wallet popup. +- `'all'` (default): Supports both `'eoaOnly'` and `'smartWalletOnly'` based on context. + +```ts-vue +import { coinbaseWallet } from '{{connectorsPackageName}}' + +const connector = coinbaseWallet({ + appName: 'My Wagmi App', + preference: 'smartWalletOnly', // [!code focus] +}) +``` + +::: warning +Passing `preference` as a string is deprecated and will be removed in the next major version. Instead you should use [`preference#options`](#options). +::: + +```ts-vue +import { coinbaseWallet } from '{{connectorsPackageName}}' + +const connector = coinbaseWallet({ + appName: 'My Wagmi App', + preference: { // [!code focus] + options: 'smartWalletOnly' // [!code focus] + }, // [!code focus] +}) +``` + +#### attribution + +`` { auto?: boolean | undefined; dataSuffix?: `0x${string}` | undefined } `` + +This option only applies to Coinbase Smart Wallet. When a valid data suffix is supplied, it is appended to the `initCode` and `executeBatch` calldata. Coinbase Smart Wallet expects a 16 byte hex string. If the data suffix is not a 16 byte hex string, the Smart Wallet will ignore the property. If auto is true, the Smart Wallet will generate a 16 byte hex string from the apps origin. + +#### keysUrl + +`string` + +- The URL for the keys popup. +- By default, `https://keys.coinbase.com/connect` is used for production. Use `https://keys-dev.coinbase.com/connect` for development environments. + +#### options + +`"all" | "eoaOnly" | "smartWalletOnly"` + +Preference for the type of wallet to display. + +- `'eoaOnly'`: Uses EOA Browser Extension or Mobile Coinbase Wallet. +- `'smartWalletOnly'`: Displays Smart Wallet popup. +- `'all'` (default): Supports both `'eoaOnly'` and `'smartWalletOnly'` based on context. + +### version + +- Coinbase Wallet SDK version +- Defaults to `'4'`. If [`headlessMode: true`](#headlessmode), defaults to `'3'`. + +```ts-vue +import { coinbaseWallet } from '{{connectorsPackageName}}' + +const connector = coinbaseWallet({ + appName: 'My Wagmi App', + version: '4', // [!code focus] +}) +``` + diff --git a/site/shared/connectors/injected.md b/site/shared/connectors/injected.md new file mode 100644 index 0000000000..36583b4d83 --- /dev/null +++ b/site/shared/connectors/injected.md @@ -0,0 +1,89 @@ + + +# injected + +Connector for [EIP-1193](https://eips.ethereum.org/EIPS/eip-1193) Ethereum Providers. + +## Import + +```ts-vue +import { injected } from '{{connectorsPackageName}}' +``` + +## Usage + +```ts-vue{3,7} +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' +import { injected } from '{{connectorsPackageName}}' + +export const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [injected()], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +## Parameters + +```ts-vue +import { type InjectedParameters } from '{{connectorsPackageName}}' +``` + +### shimDisconnect + +`boolean | undefined` + +- MetaMask and other injected providers do not support programmatic disconnect. +- This flag simulates the disconnect behavior by keeping track of connection status in storage. See [GitHub issue](https://github.com/MetaMask/metamask-extension/issues/10353) for more info. +- Defaults to `true`. + +```ts-vue +import { injected } from '{{connectorsPackageName}}' + +const connector = injected({ + shimDisconnect: false, // [!code focus] +}) +``` + +### target + +`TargetId | (TargetMap[TargetId] & { id: string }) | (() => (TargetMap[TargetId] & { id: string }) | undefined) | undefined` + +- [EIP-1193](https://eips.ethereum.org/EIPS/eip-1193) Ethereum Provider to target. +- [EIP-6963](https://eips.ethereum.org/EIPS/eip-6963) supported via `createConfig`'s `multiInjectedProviderDiscovery` property. + +```ts-vue +import { injected } from '{{connectorsPackageName}}' + +const connector = injected({ + target() { // [!code focus] + return { // [!code focus] + id: 'windowProvider', // [!code focus] + name: 'Window Provider', // [!code focus] + provider: window.ethereum, // [!code focus] + } // [!code focus] + }, // [!code focus] +}) +``` + +### unstable_shimAsyncInject + +`boolean | number | undefined` + +Watches for async provider injection via the `ethereum#initialized` event. When `true`, defaults to `1_000` milliseconds. Otherwise, uses a provided value of milliseconds. + +```ts-vue +import { injected } from '{{connectorsPackageName}}' + +const connector = injected({ + unstable_shimAsyncInject: 2_000, // [!code focus] +}) +``` diff --git a/site/shared/connectors/metaMask.md b/site/shared/connectors/metaMask.md new file mode 100644 index 0000000000..08a6f4f9cd --- /dev/null +++ b/site/shared/connectors/metaMask.md @@ -0,0 +1,124 @@ + + +# metaMask + +Connector for [MetaMask SDK](https://github.com/MetaMask/metamask-sdk). + +Check out the [MetaMask SDK docs](https://docs.metamask.io/wallet/connect/metamask-sdk/javascript) for more information. + +## Import + +```ts-vue +import { metaMask } from '{{connectorsPackageName}}' +``` + +## Usage + +```ts-vue{3,7} +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' +import { metaMask } from '{{connectorsPackageName}}' + +export const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [metaMask()], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +## Parameters + +```ts-vue +import { type MetaMaskParameters } from '{{connectorsPackageName}}' +``` + +Check out the [MetaMask SDK docs](https://docs.metamask.io/wallet/connect/3rd-party-libraries/wagmi/) for more info. A few options are omitted that Wagmi manages internally. + +### dappMetadata + +`DappMetadata | undefined` + +Metadata is used to fill details for the UX on confirmation screens in MetaMask, including the following fields: + +- `name`: `string` - The name of the dapp. +- `url`: `string` - URL of the dapp (defaults to `window.location.origin`). +- `iconUrl`: `string` - URL to the dapp's favicon or icon. + +```ts-vue +import { metaMask } from '{{connectorsPackageName}}' + +const connector = metaMask({ + dappMetadata: { // [!code focus] + name: 'My Wagmi App', // [!code focus] + url: 'https://example.com', // [!code focus] + iconUrl: 'https://example.com/favicon.ico', // [!code focus] + } +}) +``` + +### logging + +`SDKLoggingOptions | undefined` + +Enables SDK-side logging to provide visibility into: + +- RPC methods being called. +- Events received for syncing the chain or active account. +- Raw RPC responses. + +In this context, this is especially useful to observe what calls are made through Wagmi hooks. + +Relevant options: + +```ts +{ + developerMode: boolean, // Enables developer mode logs + sdk: boolean // Enables SDK-specific logs +} +``` + +```ts +import { metaMask } from '{{connectorsPackageName}}' + +const connector = metaMask({ + logging: { developerMode: true, sdk: true } // [!code focus] +}) +``` + +### headless + +`boolean | undefined` + +- Enables headless mode, disabling MetaMask's built-in modal. +- Allows developers to create their own modal, such as for displaying a QR code. + +This is particularly relevant for web-only setups using Wagmi, where developers want complete control over the UI. + +To get the deeplink to display in the QR code, listen to the `display_uri` event. + +The default is `false`. + +```ts-vue +import { metaMask } from '{{connectorsPackageName}}' + +const connector = metaMask({ + headless: true // [!code focus] +}) +``` + +## Advanced + +By default, if the EIP-6963 MetaMask injected provider is detected, this connector will replace it. + +EIP-6963 defines a standard way for dapps to interact with multiple wallets simultaneously by injecting providers into the browser. Wallets that implement this standard can make their presence known to dapps in a consistent and predictable manner. + +When MetaMask SDK detects an EIP-6963-compliant provider (such as MetaMask itself), the connector will automatically replace the default injected provider (like `window.ethereum`) with the one provided by MetaMask SDK. + +See the [`rdns` property](https://wagmi.sh/dev/creating-connectors#properties) for more information. diff --git a/site/shared/connectors/mock.md b/site/shared/connectors/mock.md new file mode 100644 index 0000000000..90d87b0b3e --- /dev/null +++ b/site/shared/connectors/mock.md @@ -0,0 +1,128 @@ + + +# mock + +Connector for mocking Wagmi functionality. + +## Import + +```ts-vue +import { mock } from '{{connectorsPackageName}}' +``` + +## Usage + +```ts-vue{3,8-14} +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' +import { mock } from '{{connectorsPackageName}}' + +export const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [ + mock({ + accounts: [ + '0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266', + '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + '0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC', + ], + }), + ], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +## Parameters + +```ts-vue +import { type MockParameters } from '{{connectorsPackageName}}' +``` + +### accounts + +`readonly [Address, ...Address[]]` + +Accounts to use with the connector. + +```ts-vue +import { mock } from '{{connectorsPackageName}}' + +const connector = mock({ + accounts: [ // [!code focus] + '0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266', // [!code focus] + '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', // [!code focus] + '0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC', // [!code focus] + '0x90F79bf6EB2c4f870365E785982E1f101E93b906', // [!code focus] + '0x15d34aaf54267db7d7c367839aaf71a00a2c6a65', // [!code focus] + '0x9965507D1a55bcC2695C58ba16FB37d819B0A4dc', // [!code focus] + '0x976EA74026E726554dB657fA54763abd0C3a0aa9', // [!code focus] + '0x14dC79964da2C08b23698B3D3cc7Ca32193d9955', // [!code focus] + '0x23618e81E3f5cdF7f54C3d65f7FBc0aBf5B21E8f', // [!code focus] + '0xa0Ee7A142d267C1f36714E4a8F75612F20a79720', // [!code focus] + ], // [!code focus] +}) +``` + +### features + +`{ connectError?: boolean | Error | undefined; reconnect?: boolean | undefined; signMessageError?: boolean | Error | undefined; signTypedDataError?: boolean | Error | undefined; switchChainError?: boolean | Error | undefined; } | undefined` + +Feature flags that change behavior of Wagmi internals. + +```ts-vue +import { mock } from '{{connectorsPackageName}}' +import { UserRejectedRequestError } from 'viem' + +const connector = mock({ + accounts: [ + '0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266', + '0x70997970c51812dc3a010c7d01b50e0d17dc79c8', + '0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC', + ], + features: { // [!code focus] + connectError: new UserRejectedRequestError(new Error('Failed to connect.')), // [!code focus] + reconnect: false, // [!code focus] + }, // [!code focus] +}) +``` +#### defaultConnected + +`boolean | undefined` + +Whether the connector is connected by default. + +#### connectError + +`boolean | Error | undefined` + +Whether to throw an error when `connector.connect` is called. + +#### reconnect + +`boolean | undefined` + +Enables reconnecting to connector. + +#### signMessageError + +`boolean | Error | undefined` + +Whether to throw an error when `'personal_sign'` is called. + +#### signTypedDataError + +`boolean | Error | undefined` + +Whether to throw an error when `'eth_signTypedData_v4'` is called. + +#### switchChainError + +`boolean | Error | undefined` + +Whether to throw an error when `connector.switchChain` is called. diff --git a/site/shared/connectors/safe.md b/site/shared/connectors/safe.md new file mode 100644 index 0000000000..171010214b --- /dev/null +++ b/site/shared/connectors/safe.md @@ -0,0 +1,77 @@ + + +# safe + +Connector for [Safe Apps SDK](https://github.com/safe-global/safe-apps-sdk). + +## Import + +```ts-vue +import { safe } from '{{connectorsPackageName}}' +``` + +## Usage + +```ts-vue{3,7} +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' +import { safe } from '{{connectorsPackageName}}' + +export const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [safe()], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +## Parameters + +```ts-vue +import { type SafeParameters } from '{{connectorsPackageName}}' +``` + +Check out the [Safe docs](https://github.com/safe-global/safe-apps-sdk/tree/main/packages/safe-apps-sdk) for more info. +### allowedDomains + +`RegExp[] | undefined` + +```ts-vue +import { safe } from '{{connectorsPackageName}}' + +const connector = safe({ + allowedDomains: [/app.safe.global$/], // [!code focus] +}) +``` + +### debug + +`boolean | undefined` + +```ts-vue +import { safe } from '{{connectorsPackageName}}' + +const connector = safe({ + debug: true, // [!code focus] +}) +``` + +### shimDisconnect + +`boolean | undefined` + +- This flag simulates disconnect behavior by keeping track of connection status in storage. +- Defaults to `false`. + +```ts-vue +import { safe } from '{{connectorsPackageName}}' + +const connector = safe({ + shimDisconnect: true, // [!code focus] +}) +``` diff --git a/site/shared/connectors/walletConnect.md b/site/shared/connectors/walletConnect.md new file mode 100644 index 0000000000..48e7fcb950 --- /dev/null +++ b/site/shared/connectors/walletConnect.md @@ -0,0 +1,215 @@ + + +# walletConnect + +Connector for [WalletConnect](https://walletconnect.com). + +## Import + +```ts-vue +import { walletConnect } from '{{connectorsPackageName}}' +``` + +## Usage + +```ts-vue{3,8-10} +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' +import { walletConnect } from '{{connectorsPackageName}}' + +export const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [ + walletConnect({ + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', + }), + ], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +## Parameters + +```ts-vue +import { type WalletConnectParameters } from '{{connectorsPackageName}}' +``` + +Check out the [WalletConnect docs](https://github.com/WalletConnect/walletconnect-monorepo/tree/v2.0/providers/ethereum-provider) for more info. A few options are omitted that Wagmi manages internally. + +### customStoragePrefix + +`string | undefined` + +Custom storage prefix for persisting provider state. + +```ts-vue +import { walletConnect } from '{{connectorsPackageName}}' + +const connector = walletConnect({ + customStoragePrefix: 'wagmi', // [!code focus] + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', +}) +``` + +### disableProviderPing + +`boolean | undefined` + +```ts-vue +import { walletConnect } from '{{connectorsPackageName}}' + +const connector = walletConnect({ + disableProviderPing: false, // [!code focus] + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', +}) +``` + +### isNewChainsStale + +`boolean | undefined` + +- If a new chain is added to a previously existing configured connector `chains`, this flag +will determine if that chain should be considered as stale. A stale chain is a chain that +WalletConnect has yet to establish a relationship with (e.g. the user has not approved or +rejected the chain). +- Defaults to `true`. + +```ts-vue +import { walletConnect } from '{{connectorsPackageName}}' + +const connector = walletConnect({ + isNewChainsStale: true, // [!code focus] + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', +}) +``` + +::: details More info +Preface: Whereas WalletConnect v1 supported dynamic chain switching, WalletConnect v2 requires +the user to pre-approve a set of chains up-front. This comes with consequent UX nuances (see below) when +a user tries to switch to a chain that they have not approved. + +This flag mainly affects the behavior when a wallet does not support dynamic chain authorization +with WalletConnect v2. + +If `true` (default), the new chain will be treated as a stale chain. If the user +has yet to establish a relationship (approved/rejected) with this chain in their WalletConnect +session, the connector will disconnect upon the dapp auto-connecting, and the user will have to +reconnect to the dapp (revalidate the chain) in order to approve the newly added chain. +This is the default behavior to avoid an unexpected error upon switching chains which may +be a confusing user experience (e.g. the user will not know they have to reconnect +unless the dapp handles these types of errors). + +If `false`, the new chain will be treated as a validated chain. This means that if the user +has yet to establish a relationship with the chain in their WalletConnect session, wagmi will successfully +auto-connect the user. This comes with the trade-off that the connector will throw an error +when attempting to switch to the unapproved chain. This may be useful in cases where a dapp constantly +modifies their configured chains, and they do not want to disconnect the user upon +auto-connecting. If the user decides to switch to the unapproved chain, it is important that the +dapp handles this error and prompts the user to reconnect to the dapp in order to approve +the newly added chain. +::: + +### metadata + +`CoreTypes.Metadata | undefined` + +Metadata related to the app requesting the connection. + +```ts-vue +import { walletConnect } from '{{connectorsPackageName}}' + +const connector = walletConnect({ + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', + metadata: { // [!code focus] + name: 'Example', // [!code focus] + description: 'Example website', // [!code focus] + url: 'https://example.com', // [!code focus] + }, // [!code focus] +}) +``` + +### projectId + +`string` + +WalletConnect Cloud project identifier. You can find your `projectId` on your [WalletConnect dashboard](https://cloud.reown.com/sign-in). + +```ts-vue +import { walletConnect } from '{{connectorsPackageName}}' + +const connector = walletConnect({ + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', // [!code focus] +}) +``` + +### qrModalOptions + +`QrModalOptions | undefined` + +Options for rendering QR modal. + +```ts-vue +import { walletConnect } from '{{connectorsPackageName}}' + +const connector = walletConnect({ + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', + qrModalOptions: { // [!code focus] + themeMode: 'dark', // [!code focus] + }, // [!code focus] +}) +``` + +### relayUrl + +`string | undefined` + +- WalletConnect relay URL to use. +- Defaults to `'wss://relay.walletconnect.com'`. + +```ts-vue +import { walletConnect } from '{{connectorsPackageName}}' + +const connector = walletConnect({ + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', + relayUrl: 'wss://relay.walletconnect.org', // [!code focus] +}) +``` + +### storageOptions + +`KeyValueStorageOptions | undefined` + +```ts-vue +import { walletConnect } from '{{connectorsPackageName}}' + +const connector = walletConnect({ + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', + storageOptions: {}, // [!code focus] +}) +``` + +### showQrModal + +`boolean | undefined` + +- Whether to show the QR code modal upon calling `connector.connect()`. +- Defaults to `true`. + +```ts-vue +import { walletConnect } from '{{connectorsPackageName}}' + +const connector = walletConnect({ + projectId: '3fcc6bba6f1de962d911bb5b5c3dba68', + showQrModal: true, // [!code focus] +}) +``` + +::: tip +This can be disabled and you can listen for a `'message'` event with payload `{ type: 'display_uri'; data: string }` if you want to render your own QR code. +::: diff --git a/site/shared/create-chain.md b/site/shared/create-chain.md new file mode 100644 index 0000000000..da2a7194cd --- /dev/null +++ b/site/shared/create-chain.md @@ -0,0 +1,93 @@ +## Create Chain + +Import the `Chain` type from Viem and create a new object that is asserted `as const` and `satisfies` the type. You can also use the `defineChain` function from Viem. + +::: code-group +```ts twoslash [as const satisfies Chain] +// @errors: 1360 +import { type Chain } from 'viem' + +export const mainnet = {} as const satisfies Chain +``` +```ts twoslash [defineChain] +// @errors: 2345 +import { defineChain } from 'viem' + +export const mainnet = defineChain({}) +``` +::: + +Now, add the missing required properties to the object until the error goes away. + +::: code-group +```ts twoslash [as const satisfies Chain] +import { type Chain } from 'viem' + +export const mainnet = { + id: 1, + name: 'Ethereum', + nativeCurrency: { name: 'Ether', symbol: 'ETH', decimals: 18 }, + rpcUrls: { + default: { http: ['https://eth.merkle.io'] }, + }, + blockExplorers: { + default: { name: 'Etherscan', url: 'https://etherscan.io' }, + }, + contracts: { + ensRegistry: { + address: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e', + }, + ensUniversalResolver: { + address: '0xE4Acdd618deED4e6d2f03b9bf62dc6118FC9A4da', + blockCreated: 16773775, + }, + multicall3: { + address: '0xca11bde05977b3631167028862be2a173976ca11', + blockCreated: 14353601, + }, + }, +} as const satisfies Chain +``` +```ts twoslash [defineChain] +import { defineChain } from 'viem' + +export const mainnet = defineChain({ + id: 1, + name: 'Ethereum', + nativeCurrency: { name: 'Ether', symbol: 'ETH', decimals: 18 }, + rpcUrls: { + default: { http: ['https://eth.merkle.io'] }, + }, + blockExplorers: { + default: { name: 'Etherscan', url: 'https://etherscan.io' }, + }, + contracts: { + ensRegistry: { + address: '0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e', + }, + ensUniversalResolver: { + address: '0xE4Acdd618deED4e6d2f03b9bf62dc6118FC9A4da', + blockCreated: 16773775, + }, + multicall3: { + address: '0xca11bde05977b3631167028862be2a173976ca11', + blockCreated: 14353601, + }, + }, +}) +``` +::: + +The more properties you add, the better the chain will be to use with Wagmi. Most of these attributes exist within the [`ethereum-lists/chains` repository](https://github.com/ethereum-lists/chains/tree/3fbd4eeac7ce116579634bd042b84e2b1d89886a/_data/chains). + +- `id`: The chain ID for the network. This can be found by typing the network name into [ChainList](https://chainlist.org). Example: "Ethereum Mainnet" has a Chain ID of `1`. +- `name`: Human-readable name for the chain. Example: "Ethereum Mainnet" +- `nativeCurrency`: The native currency of the chain. Found from [`ethereum-lists/chains`](https://github.com/ethereum-lists/chains/blob/3fbd4eeac7ce116579634bd042b84e2b1d89886a/_data/chains/eip155-56.json#L20-L24). +- `rpcUrls`: At least one public, credible RPC URL. Found from [`ethereum-lists/chains`](https://github.com/ethereum-lists/chains/blob/3fbd4eeac7ce116579634bd042b84e2b1d89886a/_data/chains/eip155-56.json#L4-L18). +- `blockExplorers`: A set of block explorers for the chain. Found from [`ethereum-lists/chains`](https://github.com/ethereum-lists/chains/blob/3fbd4eeac7ce116579634bd042b84e2b1d89886a/_data/chains/eip155-56.json#L30-L36). +- `contracts`: A set of deployed contracts for the chain. If you are deploying one of the following contracts yourself, make sure it is verified. + - `multicall3` is optional, but it's address is most likely `0xca11bde05977b3631167028862be2a173976ca11` – you can find the deployed block number on the block explorer. Check out [`mds1/multicall`](https://github.com/mds1/multicall#multicall3-contract-addresses) for more info. + - `ensRegistry` is optional – not all Chains have a ENS Registry. See [ENS Deployments](https://docs.ens.domains/ens-deployments) for more info. + - `ensUniversalResolver` is optional – not all Chains have a ENS Universal Resolver. +- `sourceId`: Source Chain ID (e.g. the L1 chain). +- `testnet`: Whether or not the chain is a testnet. \ No newline at end of file diff --git a/site/shared/createConfig.md b/site/shared/createConfig.md new file mode 100644 index 0000000000..bde2601794 --- /dev/null +++ b/site/shared/createConfig.md @@ -0,0 +1,485 @@ + + +# createConfig + +Creates new [`Config`](#config) object. + +## Import + +```ts-vue +import { createConfig } from '{{packageName}}' +``` + +## Usage + +```ts-vue +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +::: tip Integrating a Viem Client + +Instead of using [`transports`](#transports), it's possible to provide a function that returns a Viem [`Client`](https://viem.sh/docs/clients/custom.html) via the [`client`](#client) property for more fine-grained control over Wagmi's internal `Client` creation. + +```ts-vue {3,7-9} +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' +import { createClient } from 'viem' + +const config = createConfig({ + chains: [mainnet, sepolia], + client({ chain }) { + return createClient({ chain, transport: http() }) + }, +}) +``` +::: + +## Parameters + +```ts-vue +import { type CreateConfigParameters } from '{{packageName}}' +``` + +### chains + +`readonly [Chain, ...Chain[]]` + +- Chains used by the `Config`. +- See Chains for more details about built-in chains and the `Chain` type. + +```ts-vue +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], // [!code focus] + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +### connectors + +`CreateConnectorFn[] | undefined` + +Connectors used by the `Config`. + +```ts-vue +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' +import { injected } from '{{connectorsPackageName}}' // [!code focus] + +const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [injected()], // [!code focus] + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +### multiInjectedProviderDiscovery + +`boolean | undefined` + +- Enables discovery of injected providers via [EIP-6963](https://eips.ethereum.org/EIPS/eip-6963) using the [`mipd`](https://github.com/wevm/mipd) library and converting to injected connectors. +- Defaults to `true`. + +```ts-vue +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + multiInjectedProviderDiscovery: false, // [!code focus] + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +### ssr + +`boolean | undefined` + +Flag to indicate if the config is being used in a server-side rendering environment. Defaults to `false`. + +```ts-vue +import { createConfig, http } from '{{packageName}}' // [!code focus] +import { mainnet, sepolia } from '{{packageName}}/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + ssr: true, // [!code focus] + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +### storage + +`Storage | null | undefined` + +- `Storage` used by the config. Persists `Config`'s [`State`](#state-1) between sessions. +- Defaults to `createStorage({ storage: typeof window !== 'undefined' && window.localStorage ? window.localStorage : noopStorage })`. + +```ts-vue +import { createConfig, createStorage, http } from '{{packageName}}' // [!code focus] +import { mainnet, sepolia } from '{{packageName}}/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + storage: createStorage({ storage: window.localStorage }), // [!code focus] + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +### syncConnectedChain + +`boolean | undefined` + +- Keep the [`State['chainId']`](#chainid) in sync with the current connection. +- Defaults to `true`. + +```ts-vue +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + syncConnectedChain: false, // [!code focus] + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +--- + +### batch + +`{ multicall?: boolean | { batchSize?: number | undefined; wait?: number | undefined } | undefined } | { [_ in chains[number]["id"]]?: { multicall?: boolean | { batchSize?: number | undefined; wait?: number | undefined } | undefined } | undefined } | undefined` + +- Batch settings. See [Viem docs](https://viem.sh/docs/clients/custom.html#batch-optional) for more info. +- Defaults to `{ multicall: true }`. + +```ts-vue +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + batch: { multicall: true }, // [!code focus] + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +### cacheTime + +`number | { [_ in chains[number]['id']]?: number | undefined } | undefined` + +- Frequency in milliseconds for polling enabled features. See [Viem docs](https://viem.sh/docs/clients/public.html#cachetime-optional) for more info. +- Defaults to [`pollingInterval`](#pollinginterval) or `4_000`. + +```ts-vue +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + cacheTime: 4_000, // [!code focus] + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +### pollingInterval + +`number | { [_ in chains[number]['id']]?: number | undefined } | undefined` + +- Frequency in milliseconds for polling enabled features. See [Viem docs](https://viem.sh/docs/clients/custom.html#pollinginterval-optional) for more info. +- Defaults to `4_000`. + +```ts-vue +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + pollingInterval: 4_000, // [!code focus] + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +### transports + +`Record` + +Mapping of [chain IDs](#chains) to `Transport`s. This mapping is used internally when creating chain-aware Viem [`Client`](https://viem.sh/docs/clients/custom.html) objects. See the Transport docs for more info. + +```ts-vue +import { createConfig, fallback, http } from '{{packageName}}' // [!code focus] +import { mainnet, sepolia } from '{{packageName}}/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + transports: { // [!code focus] + [mainnet.id]: fallback([ // [!code focus] + http('https://...'), // [!code focus] + http('https://...'), // [!code focus] + ]), // [!code focus] + [sepolia.id]: http('https://...'), // [!code focus] + }, // [!code focus] +}) +``` + +--- + +### client + +`(parameters: { chain: chains[number] }) => Client` + +Function for creating new Viem [`Client`](https://viem.sh/docs/clients/custom.html) to be used internally. Exposes more control over the internal `Client` creation logic versus using the [`transports`](#transports) property. + +```ts-vue +import { createClient, http } from 'viem' // [!code focus] +import { createConfig } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + client({ chain }) { // [!code focus] + return createClient({ chain, transport: http('https://...') }) // [!code focus] + }, // [!code focus] +}) +``` + +::: warning +When using this option, you likely want to pass `parameters.chain` straight through to [`createClient`](https://viem.sh/docs/clients/custom.html#createclient) to ensure the Viem `Client` is in sync with any active connections. +::: + +## Return Type + +```ts-vue +import { type Config } from '{{packageName}}' +``` + +## Config + +Object responsible for managing Wagmi state and internals. + +```ts-vue +import { type Config } from '{{packageName}}' +``` + +### chains + +`readonly [Chain, ...Chain[]]` + +[`chains`](#chains) passed to `createConfig`. + +### connectors + +`readonly Connector[]` + +Connectors set up from passing [`connectors`](#connectors) and [`multiInjectedProviderDiscovery`](#multiinjectedproviderdiscovery) to `createConfig`. + +### state + +`State` + +The `Config` object's internal state. See [`State`](#state-1) for more info. + +### storage + +`Storage | null` + +[`storage`](#storage) passed to `createConfig`. + +### getClient + +`(parameters?: { chainId?: chainId | chains[number]['id'] | undefined }): Client>` + +Creates new Viem [`Client`](https://viem.sh/docs/clients/custom.html) object. + +::: code-group +```ts-vue [index.ts] +import { config } from './config' + +const client = config.getClient({ chainId: 1 }) +``` + +```ts-vue [config.ts] +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +export const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +::: + +### setState + +`(value: State | ((state: State) => State)) => void` + +Updates the `Config` object's internal state. See [`State`](#state-1) for more info. + +::: code-group +```ts-vue [index.ts] +import { mainnet } from '{{packageName}}/chains' +import { config } from './config' + +config.setState((x) => ({ + ...x, + chainId: x.current ? x.chainId : mainnet.id, +})) +``` + +```ts-vue [config.ts] +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +export const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +::: + +::: warning +Exercise caution when using this method. It is intended for internal and advanced use-cases only. Manually setting state can cause unexpected behavior. +::: + +### subscribe + +`(selector: (state: State) => state, listener: (selectedState: state, previousSelectedState: state) => void, options?: { emitImmediately?: boolean | undefined; equalityFn?: ((a: state, b: state) => boolean) | undefined } | undefined) => (() => void)` + +Listens for state changes matching the `selector` function. Returns a function that can be called to unsubscribe the listener. + +::: code-group +```ts-vue [index.ts] +import { config } from './config' + +const unsubscribe = config.subscribe( + (state) => state.chainId, + (chainId) => console.log(`Chain ID changed to ${chainId}`), +) +unsubscribe() +``` + +```ts-vue [config.ts] +import { createConfig, http } from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +export const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http('https://mainnet.example.com'), + [sepolia.id]: http('https://sepolia.example.com'), + }, +}) +``` + +::: + +## State + +```ts-vue +import { type State } from '{{packageName}}' +``` + +### chainId + +`chains[number]['id']` + +Current chain ID. When `syncConnectedChain` is `true`, `chainId` is kept in sync with the current connection. Defaults to first chain in [`chains`](#chains). + +### connections + +`Map` + +Mapping of unique connector identifier to [`Connection`](#connection) object. + +### current + +`string | undefined` + +Unique identifier of the current connection. + +### status + +`'connected' | 'connecting' | 'disconnected' | 'reconnecting'` + +Current connection status. + +- `'connecting'` attempting to establish connection. +- `'reconnecting'` attempting to re-establish connection to one or more connectors. +- `'connected'` at least one connector is connected. +- `'disconnected'` no connection to any connector. + +## Connection + +```ts-vue +import { type Connection } from '{{packageName}}' +``` + +### accounts + +`readonly [Address, ...Address[]]` + +Array of addresses associated with the connection. + +### chainId + +`number` + +Chain ID associated with the connection. + +### connector + +`Connector` + +Connector associated with the connection. diff --git a/site/shared/createStorage.md b/site/shared/createStorage.md new file mode 100644 index 0000000000..fe758569d2 --- /dev/null +++ b/site/shared/createStorage.md @@ -0,0 +1,161 @@ + + +# createStorage + +Creates new [`Storage`](#storage) object. + +## Import + +```ts-vue +import { createStorage } from '{{packageName}}' +``` + +## Usage + +```ts-vue +import { createStorage } from '{{packageName}}' + +const storage = createStorage({ storage: localStorage }) +``` + +## Parameters + +```ts-vue +import { type CreateStorageParameters } from '{{packageName}}' +``` + +### deserialize + +`((value: string) => T) | undefined` + +- Function to deserialize data from storage. +- Defaults to `deserialize`. + +```ts-vue +import { createStorage, deserialize } from '{{packageName}}' // [!code focus] + +const storage = createStorage({ + deserialize, // [!code focus] + storage: localStorage, +}) +``` + +::: warning +If you use a custom `deserialize` function, make sure it can handle `bigint` and `Map` values. +::: + +### key + +`string | undefined` + +- Key prefix to use when persisting data. +- Defaults to `'wagmi'`. + +```ts-vue +import { createStorage } from '{{packageName}}' + +const storage = createStorage({ + key: 'my-app', // [!code focus] + storage: localStorage, +}) +``` + +### serialize + +`((value: T) => string) | undefined` + +- Function to serialize data for storage. +- Defaults to `serialize`. + +```ts-vue +import { createStorage, serialize } from '{{packageName}}' // [!code focus] + +const storage = createStorage({ + serialize, // [!code focus] + storage: localStorage, +}) +``` + +::: warning +If you use a custom `serialize` function, make sure it can handle `bigint` and `Map` values. +::: + +### storage + +`{ getItem(key: string): string | null | undefined | Promise; setItem(key: string, value: string): void | Promise; removeItem(key: string): void | Promise; }` + +- Storage interface to use for persisting data. +- Defaults to `localStorage`. +- Supports synchronous and asynchronous storage methods. + +```ts-vue +import { createStorage } from '{{packageName}}' +// Using IndexedDB via https://github.com/jakearchibald/idb-keyval // [!code focus] +import { del, get, set } from 'idb-keyval' // [!code focus] + +const storage = createStorage({ + storage: { // [!code focus] + async getItem(name) { // [!code focus] + return get(name)// [!code focus] + }, // [!code focus] + async setItem(name, value) { // [!code focus] + await set(name, value) // [!code focus] + }, // [!code focus] + async removeItem(name) { // [!code focus] + await del(name) // [!code focus] + }, // [!code focus] + }, // [!code focus] +}) +``` + +## Return Type + +```ts-vue +import { type Storage } from '{{packageName}}' +``` + +## Storage + +Object responsible for persisting Wagmi `State` and other data. + +```ts-vue +import { type Storage } from '{{packageName}}' +``` + +### getItem + +`getItem(key: string, defaultValue?: value | null | undefined): value | null | Promise` + +```ts-vue +import { createStorage } from '{{packageName}}' + +const storage = createStorage({ storage: localStorage }) +const recentConnectorId = storage.getItem('recentConnectorId') // [!code focus] +``` + +### setItem + +`setItem(key: string, value: any): void | Promise` + +```ts-vue +import { createStorage } from '{{packageName}}' + +const storage = createStorage({ storage: localStorage }) +storage.setItem('recentConnectorId', 'foo') // [!code focus] +``` + +### removeItem + +`removeItem(key: string): void | Promise` + +```ts-vue +import { createStorage } from '{{packageName}}' + +const storage = createStorage({ storage: localStorage }) +storage.removeItem('recentConnectorId') // [!code focus] +``` \ No newline at end of file diff --git a/site/shared/errors.md b/site/shared/errors.md new file mode 100644 index 0000000000..c518172fc7 --- /dev/null +++ b/site/shared/errors.md @@ -0,0 +1,90 @@ + + +## BaseError + +Error class extended by all errors. + +```ts-vue +import { BaseError } from '{{packageName}}' +``` + +## Config + +### ConnectorAccountNotFoundError + +When an account does not exist on the connector or is unable to be used. + +```ts-vue +import { ConnectorAccountNotFoundError } from '{{packageName}}' +``` + +### ConnectorAlreadyConnectedError + +When a connector is already connected. + +```ts-vue +import { ConnectorAlreadyConnectedError } from '{{packageName}}' +``` + +### ConnectorChainMismatchError + +When the Wagmi Config is out-of-sync with the connector's active chain ID. This is rare and likely an upstream wallet issue. + +```ts-vue +import { ConnectorChainMismatchError } from '{{packageName}}' +``` + +### ChainNotConfiguredError + +When a chain is not configured. You likely need to add the chain to `Config['chains']`. + +```ts-vue +import { ChainNotConfiguredError } from '{{packageName}}' +``` + +### ConnectorNotConnectedError + +When a connector is not connected. + +```ts-vue +import { ConnectorNotConnectedError } from '{{packageName}}' +``` + +### ConnectorNotFoundError + +When a connector is not found or able to be used. + +```ts-vue +import { ConnectorNotFoundError } from '{{packageName}}' +``` + +### ConnectorUnavailableReconnectingError + +During the reconnection step, the only connector methods guaranteed to be available are: `id`, `name`, `type`, `uuid`. All other methods are not guaranteed to be available until reconnection completes and connectors are fully restored. This error commonly occurs for connectors that asynchronously inject after reconnection has already started. + +```ts-vue +import { ConnectorUnavailableReconnectingError } from '{{packageName}}' +``` + +## Connector + +### ProviderNotFoundError + +When a connector's provider is not found or able to be used. + +```ts-vue +import { ProviderNotFoundError } from '{{packageName}}' +``` + +### SwitchChainNotSupportedError + +When switching chains is not supported by connectors. + +```ts-vue +import { SwitchChainNotSupportedError } from '{{packageName}}' +``` diff --git a/site/shared/faq.md b/site/shared/faq.md new file mode 100644 index 0000000000..03e17693ee --- /dev/null +++ b/site/shared/faq.md @@ -0,0 +1,81 @@ + + +## Type inference doesn't work + +- Check that you set up TypeScript correctly with `"strict": true` in your `tsconfig.json` (TypeScript docs) +- Check that you const-asserted any ABIs or Typed Data you are using. +- Restart your language server or IDE, and check for type errors in your code. + +## My wallet doesn't work + +If you run into issues with a specific wallet, try another before opening up an issue. There are many different wallets and it's likely that the issue is with the wallet itself, not Wagmi. For example, if you are using Wallet X and sending a transaction doesn't work, try Wallet Y and see if it works. + +## `BigInt` Serialization + +Using native `BigInt` with `JSON.stringify` will raise a `TypeError` as +[`BigInt` values are not serializable](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/BigInt#use_within_json). There are two techniques to mitigate this: + +#### Lossless serialization + +Lossless serialization means that `BigInt` will be converted to a format that can be deserialized later (e.g. `69420n` → `"#bigint.69420"`). The trade-off is that these values are not human-readable and are not intended to be displayed to the user. + +Lossless serialization can be achieved with wagmi's `serialize` and `deserialize` utilities. + +```tsx +import { serialize, deserialize } from 'wagmi' + +const serialized = serialize({ value: 69420n }) +// '{"value":"#bigint.69420"}' + +const deserialized = deserialize(serialized) +// { value: 69420n } +``` + +#### Lossy serialization + +Lossy serialization means that the `BigInt` will be converted to a normal display string (e.g. `69420n` → `'69420'`). +The trade-off is that you will not be able to deserialize the `BigInt` with `JSON.parse` as it can not distinguish between a normal string and a `BigInt`. + +This method can be achieved by modifying `JSON.stringify` to include a BigInt `replacer`: + +```tsx +const replacer = (key, value) => + typeof value === 'bigint' ? value.toString() : value + +JSON.stringify({ value: 69420n }, replacer) +// '{"value":"69420"}' +``` + +## How do I support the project? + +Wagmi is an open source software project and free to use. If you enjoy using Wagmi or would like to support Wagmi development, you can: + +- [Become a sponsor on GitHub](https://github.com/sponsors/wevm) +- Send us crypto + - Mainnet: 0x4557B18E779944BFE9d78A672452331C186a9f48 + - Multichain: 0xd2135CfB216b74109775236E36d4b433F1DF507B +- [Become a supporter on Drips](https://www.drips.network/app/projects/github/wevm/wagmi) + +If you use Wagmi at work, consider asking your company to sponsor Wagmi. This may not be easy, but **business sponsorships typically make a much larger impact on the sustainability of OSS projects** than individual donations, so you will help us much more if you succeed. + +## Is Wagmi production ready? + +Yes. Wagmi is very stable and is used in production by thousands of organizations, like [Stripe](https://stripe.com), [Shopify](https://shopify.com), [Coinbase](https://coinbase.com), [Uniswap](https://uniswap.org), [ENS](https://ens.domains), [Optimism](https://optimism.com). + +## Is Wagmi strict with semver? + +Yes, Wagmi is very strict with [semantic versioning](https://semver.org) and we will never introduce breaking changes to the runtime API in a minor version bump. + +For exported types, we try our best to not introduce breaking changes in non-major versions, however, [TypeScript doesn't follow semver](https://www.learningtypescript.com/articles/why-typescript-doesnt-follow-strict-semantic-versioning) and often introduces breaking changes in minor releases that can cause Wagmi type issues. See the TypeScript docs for more information. + +## How can I contribute to Wagmi? + +The Wagmi team accepts all sorts of contributions. Check out the [Contributing](/dev/contributing) guide to get started. If you are interested in adding a new connector to Wagmi, check out the [Creating Connectors](/dev/creating-connectors) guide. + +## Anything else you want to know? + +Please create a new [GitHub Discussion thread](https://github.com/wevm/wagmi). You're also free to suggest changes to this or any other page on the site using the "Suggest changes to this page" button at the bottom of the page. diff --git a/site/shared/getAccount-return-type.md b/site/shared/getAccount-return-type.md new file mode 100644 index 0000000000..315728261b --- /dev/null +++ b/site/shared/getAccount-return-type.md @@ -0,0 +1,107 @@ + + +### address + +`Address | undefined` + +- Connected address from connector. +- Defaults to first address in [`addresses`](#addresses). + +### addresses + +`readonly Address[] | undefined` + +Connected addresses from connector. + +### chain + +`Chain | undefined` + +Connected chain from connector. If chain is not configured by config, it will be `undefined`. + +### chainId + +`number | undefined` + +Connected chain id from connector. + +### connector + +`Connector | undefined` + +Connected connector. + +### isConnecting / isReconnecting / isConnected / isDisconnected + +`boolean` + +Boolean variables derived from [`status`](#status). + +### status + +`'connecting' | 'reconnecting' | 'connected' | 'disconnected'` + +- `'connecting'` attempting to establish connection. +- `'reconnecting'` attempting to re-establish connection to one or more connectors. +- `'connected'` at least one connector is connected. +- `'disconnected'` no connection to any connector. + +::: info You can use `status` to narrow the return type. +For example, when `status` is `'connected'` properties like `address` are guaranteed to be defined. + +```ts twoslash +import { type GetAccountReturnType } from '@wagmi/core' +const account = {} as GetAccountReturnType +// ---cut--- +if (account.status === 'connected') { + account + // ^? + + + + + + + + + + + + + + + +} +``` + +Or when status is `'disconnected'` properties like `address` are guaranteed to be `undefined`: + +```ts twoslash +import { type GetAccountReturnType } from '@wagmi/core' +const account = {} as GetAccountReturnType +// ---cut--- +if (account.status === 'disconnected') { + account + // ^? + + + + + + + + + + + + + + + +} +``` +::: diff --git a/site/shared/installation.md b/site/shared/installation.md new file mode 100644 index 0000000000..c96c14def0 --- /dev/null +++ b/site/shared/installation.md @@ -0,0 +1,62 @@ + + +## Requirements + +Wagmi is optimized for modern browsers. It is compatible with the latest versions of the following browsers. + + + +::: tip +Depending on your environment, you might need to add polyfills. See [Viem Platform Compatibility](https://viem.sh/docs/compatibility.html) for more info. +::: + +## Using Unreleased Commits + +If you can't wait for a new release to test the latest features, you can either install from the `canary` tag (tracks the [`main`](https://github.com/wevm/wagmi/tree/main) branch). + +::: code-group +```bash-vue [pnpm] +pnpm add {{packageName}}@canary +``` + +```bash-vue [npm] +npm install {{packageName}}@canary +``` + +```bash-vue [yarn] +yarn add {{packageName}}@canary +``` + +```bash-vue [bun] +bun add {{packageName}}@canary +``` +::: + +Or clone the [Wagmi repo](https://github.com/wevm/wagmi) to your local machine, build, and link it yourself. + +```bash-vue +gh repo clone wevm/wagmi +cd wagmi +pnpm install +pnpm build +cd packages/{{packageDir}} +pnpm link --global +``` + +Then go to the project where you are using Wagmi and run `pnpm link --global {{packageName}}` (or the package manager that you used to link Wagmi globally). Make sure you installed any [required peer dependencies](#package-manager) and their versions are correct. + +## Security + +Ethereum-related projects are often targeted in attacks to steal users' assets. Make sure you follow security best-practices for your project. Some quick things to get started. + +- Pin package versions, upgrade mindfully, and inspect lockfile changes to minimize the risk of [supply-chain attacks](https://nodejs.org/en/guides/security/#supply-chain-attacks). +- Install the [Socket Security](https://socket.dev) [GitHub App](https://github.com/apps/socket-security) to help detect and block supply-chain attacks. +- Add a [Content Security Policy](https://cheatsheetseries.owasp.org/cheatsheets/Content_Security_Policy_Cheat_Sheet.html) to defend against external scripts running in your app. +- Pin [GitHub Action](https://x.com/paulmillr/status/1900948425325031448) versions to commits instead of tags. diff --git a/site/shared/mutation-imports.md b/site/shared/mutation-imports.md new file mode 100644 index 0000000000..b538dcfab6 --- /dev/null +++ b/site/shared/mutation-imports.md @@ -0,0 +1,19 @@ + + +## TanStack Query + +```ts-vue +import { + type {{typeName}}Data, + type {{typeName}}Variables, + type {{typeName}}Mutate, + type {{typeName}}MutateAsync, + {{actionName}}MutationOptions, +} from '{{packageName}}/query' +``` \ No newline at end of file diff --git a/site/shared/mutation-options.md b/site/shared/mutation-options.md new file mode 100644 index 0000000000..b1eae45250 --- /dev/null +++ b/site/shared/mutation-options.md @@ -0,0 +1,89 @@ + + +
+ +--- + +### mutation + +TanStack Query parameters. See the [TanStack Query mutation docs](https://tanstack.com/query/v5/docs/react/reference/useMutation) for more info. + +::: info Wagmi does not support passing all TanStack Query parameters +TanStack Query parameters, like `mutationFn` and `mutationKey`, are used internally to make Wagmi work and you cannot override them. Check out the [source](https://github.com/wevm/wagmi/blob/main/packages/react/src/utils/query.ts#L30) to see what parameters are not supported. All parameters listed below are supported. +::: + +#### gcTime + +`number | Infinity | undefined` + +- The time in milliseconds that unused/inactive cache data remains in memory. When a mutation's cache becomes unused or inactive, that cache data will be garbage collected after this duration. When different cache times are specified, the longest one will be used. +- If set to `Infinity`, will disable garbage collection + +#### meta + +`Record | undefined` + +If set, stores additional information on the mutation cache entry that can be used as needed. It will be accessible wherever [`{{mutate}}`](#mutate) is available (e.g. [`onError`](#onerror), [`onSuccess`](#onsuccess) functions). + +#### networkMode + +`'online' | 'always' | 'offlineFirst' | undefined` + +- defaults to `'online'` +- see [Network Mode](https://tanstack.com/query/v5/docs/react/guides/network-mode) for more information. + +#### onError + +`((error: {{TError}}, variables: {{TVariables}}, context?: context | undefined) => Promise | unknown) | undefined` + +This function will fire if the mutation encounters an error and will be passed the error. + +#### onMutate + +`((variables: {{TVariables}}) => Promise | context | void) | undefined` + +- This function will fire before the mutation function is fired and is passed the same variables the mutation function would receive +- Useful to perform optimistic updates to a resource in hopes that the mutation succeeds +- The value returned from this function will be passed to both the `onError` and `onSettled` functions in the event of a mutation failure and can be useful for rolling back optimistic updates. + +#### onSuccess + +`((data: {{TData}}, variables: {{TVariables}}, context?: context | undefined) => Promise | unknown) | undefined` + +This function will fire when the mutation is successful and will be passed the mutation's result. + +#### onSettled + +`((data: {{TData}}, error: {{TError}}, variables: {{TVariables}}, context?: context | undefined) => Promise | unknown) | undefined` + +This function will fire when the mutation is either successfully fetched or encounters an error and be passed either the data or error + +#### queryClient + +`QueryClient` + +Use this to use a custom `QueryClient`. Otherwise, the one from the nearest context will be used. + +#### retry + +`boolean | number | ((failureCount: number, error: {{TError}}) => boolean) | undefined` + +- Defaults to `0`. +- If `false`, failed mutations will not retry. +- If `true`, failed mutations will retry infinitely. +- If set to an `number`, e.g. `3`, failed mutations will retry until the failed mutations count meets that number. + +#### retryDelay + +`number | ((retryAttempt: number, error: {{TError}}) => number) | undefined` + +- This function receives a `retryAttempt` integer and the actual Error and returns the delay to apply before the next attempt in milliseconds. +- A function like `attempt => Math.min(attempt > 1 ? 2 ** attempt * 1000 : 1000, 30 * 1000)` applies exponential backoff. +- A function like `attempt => attempt * 1000` applies linear backoff. diff --git a/site/shared/mutation-result.md b/site/shared/mutation-result.md new file mode 100644 index 0000000000..3dfaa2d709 --- /dev/null +++ b/site/shared/mutation-result.md @@ -0,0 +1,122 @@ + + +
+ +--- + +[TanStack Query mutation docs](https://tanstack.com/query/v5/docs/react/reference/useMutation) + +### {{mutate}} + +`(variables: {{TVariables}}, { onSuccess, onSettled, onError }) => void` + +The mutation function you can call with variables to trigger the mutation and optionally hooks on additional callback options. + +- #### variables + + `{{TVariables}}` + + The variables object to pass to the `{{mutate}}` action. + +- #### onSuccess + + `(data: {{TData}}, variables: {{TVariables}}, context: TContext) => void` + + This function will fire when the mutation is successful and will be passed the mutation's result. + +- #### onError + + `(error: {{TError}}, variables: {{TVariables}}, context: TContext | undefined) => void` + + This function will fire if the mutation encounters an error and will be passed the error. + +- #### onSettled + + `(data: {{TData}} | undefined, error: {{TError}} | null, variables: {{TVariables}}, context: TContext | undefined) => void` + + - This function will fire when the mutation is either successfully fetched or encounters an error and be passed either the data or error + - If you make multiple requests, `onSuccess` will fire only after the latest call you've made. + +### {{mutate}}Async + +`(variables: {{TVariables}}, { onSuccess, onSettled, onError }) => Promise<{{TData}}>` + +Similar to [`{{mutate}}`](#mutate) but returns a promise which can be awaited. + +### data + +`{{TData}} | undefined` + +- `{{mutate}}` return type +- Defaults to `undefined` +- The last successfully resolved data for the mutation. + +### error + +`{{TError}} | null` + +The error object for the mutation, if an error was encountered. + +### failureCount + +`number` + +- The failure count for the mutation. +- Incremented every time the mutation fails. +- Reset to `0` when the mutation succeeds. + +### failureReason + +`{{TError}} | null` + +- The failure reason for the mutation retry. +- Reset to `null` when the mutation succeeds. + +### isError / isIdle / isPending / isSuccess + +`boolean` + +Boolean variables derived from [`status`](#status). + +### isPaused + +`boolean` + +- will be `true` if the mutation has been `paused`. +- see [Network Mode](https://tanstack.com/query/v5/docs/react/guides/network-mode) for more information. + +### reset + +`() => void` + +A function to clean the mutation internal state (e.g. it resets the mutation to its initial state). + +### status + +`'idle' | 'pending' | 'error' | 'success'` + +- `'idle'` initial status prior to the mutation function executing. +- `'pending'` if the mutation is currently executing. +- `'error'` if the last mutation attempt resulted in an error. +- `'success'` if the last mutation attempt was successful. + +### submittedAt + +`number` + +- The timestamp for when the mutation was submitted. +- Defaults to `0`. + +### variables + +`{{TVariables}} | undefined` + +- The variables object passed to [`{{mutate}}`](#mutate). +- Defaults to `undefined`. diff --git a/site/shared/query-imports.md b/site/shared/query-imports.md new file mode 100644 index 0000000000..20eed55a01 --- /dev/null +++ b/site/shared/query-imports.md @@ -0,0 +1,20 @@ + + +## TanStack Query + +```ts-vue +import { + type {{typeName}}Data, + type {{typeName}}Options, + type {{typeName}}QueryFnData, + type {{typeName}}QueryKey, + {{actionName}}QueryKey, + {{actionName}}QueryOptions, +} from '{{packageName}}/query' +``` \ No newline at end of file diff --git a/site/shared/query-options.md b/site/shared/query-options.md new file mode 100644 index 0000000000..ac6f3f51f5 --- /dev/null +++ b/site/shared/query-options.md @@ -0,0 +1,208 @@ + + +
+ +--- + +### query + +TanStack Query parameters. See the [TanStack Query query docs](https://tanstack.com/query/v5/docs/react/reference/useQuery) for more info. + +::: info Wagmi does not support passing all TanStack Query parameters +TanStack Query parameters, like `queryFn` and `queryKey`, are used internally to make Wagmi work and you cannot override them. Check out the [source](https://github.com/wevm/wagmi/blob/main/packages/react/src/types/properties.ts#L27) to see what parameters are not supported. All parameters listed below are supported. +::: + +#### enabled + +`boolean | undefined` + +- Set this to `false` to disable this query from automatically running. +- Can be used for [Dependent Queries](https://tanstack.com/query/v5/docs/react/guides/dependent-queries). + +
+ +#### gcTime + +`number | Infinity | undefined` + +- Defaults to `5 * 60 * 1000` (5 minutes) or `Infinity` during SSR +- The time in milliseconds that unused/inactive cache data remains in memory. When a query's cache becomes unused or inactive, that cache data will be garbage collected after this duration. When different garbage collection times are specified, the longest one will be used. +- If set to `Infinity`, will disable garbage collection + +
+ +#### initialData + +`{{TData}} | (() => {{TData}}) | undefined` + +- If set, this value will be used as the initial data for the query cache (as long as the query hasn't been created or cached yet) +- If set to a function, the function will be called **once** during the shared/root query initialization, and be expected to synchronously return the initialData +- Initial data is considered stale by default unless a `staleTime` has been set. +- `initialData` **is persisted** to the cache + +#### initialDataUpdatedAt + +`number | ((() => number | undefined)) | undefined` + +If set, this value will be used as the time (in milliseconds) of when the `initialData` itself was last updated. + +
+ +#### initialPageParam + +`{{TPageParam}}` + +The initial page parameter to be passed to the query function. + +#### getPreviousPageParam + +This function can be set to automatically get the previous cursor for infinite queries. +The result will also be used to determine the value of `hasPreviousPage`. + +`(firstPage: {{TData}}, allPages: {{TData}}[], firstPageParam: {{TPageParam}}, allPageParams: {{TPageParam}}[]) => {{TPageParam}} | undefined | null` + +#### getNextPageParam + +This function can be set to automatically get the previous cursor for infinite queries. +The result will also be used to determine the value of `hasPreviousPage`. + +`(lastPage: {{TData}}, allPages: {{TData}}[], lastPageParam: {{TPageParam}}, allPageParams: {{TPageParam}}[]) => {{TPageParam}} | undefined | null` + +
+ +#### meta + +`Record | undefined` + +If set, stores additional information on the query cache entry that can be used as needed. It will be accessible wherever the `query` is available, and is also part of the `QueryFunctionContext` provided to the `queryFn`. + +#### networkMode + +`online' | 'always' | 'offlineFirst' | undefined` + +- Defaults to `'online'` +- see [Network Mode](https://tanstack.com/query/v5/docs/react/guides/network-mode) for more information. + +#### notifyOnChangeProps + +`string[] | 'all' | (() => string[] | 'all') | undefined` + +- If set, the component will only re-render if any of the listed properties change. +- If set to `['data', 'error']` for example, the component will only re-render when the `data` or `error` properties change. +- If set to `'all'`, the component will opt-out of smart tracking and re-render whenever a query is updated. +- If set to a function, the function will be executed to compute the list of properties. +- By default, access to properties will be tracked, and the component will only re-render when one of the tracked properties change. + +#### placeholderData + +`{{TData}} | ((previousValue: {{TData}} | undefined; previousQuery: Query | undefined) => {{TData}}) | undefined` + +- If set, this value will be used as the placeholder data for this particular query observer while the query is still in the `pending` state. +- `placeholderData` is **not persisted** to the cache +- If you provide a function for `placeholderData`, as a first argument you will receive previously watched query data if available, and the second argument will be the complete previousQuery instance. + +#### queryClient + +`QueryClient | undefined` + +Use this to use a custom `QueryClient`. Otherwise, the one from the nearest context will be used. + +#### refetchInterval + +`number | false | ((data: {{TData}} | undefined, query: Query) => number | false | undefined) | undefined` + +- If set to a number, all queries will continuously refetch at this frequency in milliseconds +- If set to a function, the function will be executed with the latest data and query to compute a frequency + +#### refetchIntervalInBackground + +`boolean | undefined` + +If set to `true`, queries that are set to continuously refetch with a `refetchInterval` will continue to refetch while their tab/window is in the background + +#### refetchOnMount + +`boolean | 'always' | ((query: Query) => boolean | 'always') | undefined` + +- Defaults to `true` +- If set to `true`, the query will refetch on mount if the data is stale. +- If set to `false`, the query will not refetch on mount. +- If set to `'always'`, the query will always refetch on mount. +- If set to a function, the function will be executed with the query to compute the value + +#### refetchOnReconnect + +`boolean | 'always' | ((query: Query) => boolean | 'always') | undefined` + +- Defaults to `true` +- If set to `true`, the query will refetch on reconnect if the data is stale. +- If set to `false`, the query will not refetch on reconnect. +- If set to `'always'`, the query will always refetch on reconnect. +- If set to a function, the function will be executed with the query to compute the value + +#### refetchOnWindowFocus + +`boolean | 'always' | ((query: Query) => boolean | 'always') | undefined` + +- Defaults to `true` +- If set to `true`, the query will refetch on window focus if the data is stale. +- If set to `false`, the query will not refetch on window focus. +- If set to `'always'`, the query will always refetch on window focus. +- If set to a function, the function will be executed with the query to compute the value + +#### retry + +`boolean | number | ((failureCount: number, error: {{TError}}) => boolean) | undefined` + +- If `false`, failed queries will not retry by default. +- If `true`, failed queries will retry infinitely. +- If set to a `number`, e.g. `3`, failed queries will retry until the failed query count meets that number. +- Defaults to `3` on the client and `0` on the server + +#### retryDelay + +`number | ((retryAttempt: number, error: {{TError}}) => number) | undefined` + +- This function receives a `retryAttempt` integer and the actual Error and returns the delay to apply before the next attempt in milliseconds. +- A function like `attempt => Math.min(attempt > 1 ? 2 ** attempt * 1000 : 1000, 30 * 1000)` applies exponential backoff. +- A function like `attempt => attempt * 1000` applies linear backoff. + +#### retryOnMount + +`boolean | undefined` + +If set to `false`, the query will not be retried on mount if it contains an error. Defaults to `true`. + +#### select + +`((data: {{TData}}) => unknown) | undefined` + +This option can be used to transform or select a part of the data returned by the query function. It affects the returned `data` value, but does not affect what gets stored in the query cache. + +
+ +#### staleTime + +`number | Infinity | undefined` + +- Defaults to `0` +- The time in milliseconds after data is considered stale. This value only applies to the hook it is defined on. +- If set to `Infinity`, the data will never be considered stale + +
+ +#### structuralSharing + +`boolean | (((oldData: {{TData}} | undefined, newData: {{TData}}) => {{TData}})) | undefined` + +- Defaults to `true` +- If set to `false`, structural sharing between query results will be disabled. +- If set to a function, the old and new data values will be passed through this function, which should combine them into resolved data for the query. This way, you can retain references from the old data to improve performance even when that data contains non-serializable values. diff --git a/site/shared/query-result.md b/site/shared/query-result.md new file mode 100644 index 0000000000..34e4b8e733 --- /dev/null +++ b/site/shared/query-result.md @@ -0,0 +1,193 @@ + + +
+ +--- + +[TanStack Query query docs](https://tanstack.com/query/v5/docs/react/reference/useQuery) + +### data + +`{{TData}}` + +- The last successfully resolved data for the query. +- Defaults to `undefined`. + +### dataUpdatedAt + +`number` + +The timestamp for when the query most recently returned the `status` as `'success'`. + +### error + +`null | {{TError}}` + +- The error object for the query, if an error was thrown. +- Defaults to `null` + +### errorUpdatedAt + +`number` + +The timestamp for when the query most recently returned the `status` as `'error'`. + +### errorUpdateCount + +`number` + +The sum of all errors. + +### failureCount + +`number` + +- The failure count for the query. +- Incremented every time the query fails. +- Reset to `0` when the query succeeds. + +### failureReason + +`null | {{TError}}` + +- The failure reason for the query retry. +- Reset to `null` when the query succeeds. + +
+ +### fetchNextPage + +`(options?: FetchNextPageOptions) => Promise>` + +This function allows you to fetch the next "page" of results. + +### fetchPreviousPage + +`(options?: FetchPreviousPageOptions) => Promise>` + +This function allows you to fetch the previous "page" of results. + +### hasNextPage + +`boolean` + +This will be `true` if there is a next page to be fetched (known via the `getNextPageParam` option). + +### hasPreviousPage + +`boolean` + +This will be `true` if there is a previous page to be fetched (known via the `getPreviousPageParam` option). + +### isFetchingNextPage + +`boolean` + +Will be `true` while fetching the next page with `fetchNextPage`. + +### isFetchingPreviousPage + +`boolean` + +Will be `true` while fetching the previous page with `fetchPreviousPage`. + +
+ +### fetchStatus + +`'fetching' | 'idle' | 'paused'` + +- `fetching` Is `true` whenever the queryFn is executing, which includes initial `pending` as well as background refetches. +- `paused` The query wanted to fetch, but has been `paused`. +- `idle` The query is not fetching. +- See [Network Mode](https://tanstack.com/query/v5/docs/react/guides/network-mode) for more information. + +### isError / isPending / isSuccess + +`boolean` + +Boolean variables derived from [`status`](#status). + +### isFetched + +`boolean` + +Will be `true` if the query has been fetched. + +### isFetchedAfterMount + +`boolean` + +- Will be `true` if the query has been fetched after the component mounted. +- This property can be used to not show any previously cached data. + +### isFetching / isPaused + +`boolean` + +Boolean variables derived from [`fetchStatus`](#fetchstatus). + +### isLoading + +`boolean` + +- Is `true` whenever the first fetch for a query is in-flight +- Is the same as `isFetching && isPending` + +### isLoadingError + +`boolean` + +Will be `true` if the query failed while fetching for the first time. + +### isPlaceholderData + +`boolean` + +Will be `true` if the data shown is the placeholder data. + +### isRefetchError + +`boolean` + +Will be `true` if the query failed while refetching. + +### isRefetching + +`boolean` + +- Is `true` whenever a background refetch is in-flight, which _does not_ include initial `'pending'`. +- Is the same as `isFetching && !isPending` + +### isStale + +`boolean` + +Will be `true` if the data in the cache is invalidated or if the data is older than the given `staleTime`. + +### refetch + +`(options: { cancelRefetch?: boolean | undefined; throwOnError?: boolean | undefined }) => Promise>` + +- A function to manually refetch the query. +- `throwOnError` + - When set to `true`, an error will be thrown if the query fails. + - When set to `false`, an error will be logged if the query fails. +- `cancelRefetch` + - When set to `true`, a currently running request will be cancelled before a new request is made. + - When set to `false`, no refetch will be made if there is already a request running. + - Defaults to `true` + +### status + +`'error' | 'pending' | 'success'` + +- `pending` if there's no cached data and no query attempt was finished yet. +- `error` if the query attempt resulted in an error. The corresponding `error` property has the error received from the attempted fetch +- `success` if the query has received a response with no errors and is ready to display its data. The corresponding `data` property on the query is the data received from the successful fetch or if the query's `enabled` property is set to `false` and has not been fetched yet `data` is the first `initialData` supplied to the query on initialization. diff --git a/site/shared/transports/custom.md b/site/shared/transports/custom.md new file mode 100644 index 0000000000..dee391608a --- /dev/null +++ b/site/shared/transports/custom.md @@ -0,0 +1,110 @@ + + +# custom + +The `custom` Transport connects to a JSON-RPC API via custom. Wraps Viem's [`custom` Transport](https://viem.sh/docs/clients/transports/custom.html). + +## Import + +```ts-vue +import { custom } from '{{packageName}}' +``` + +## Usage + +```ts-vue +import { + createConfig, + custom // [!code hl] +} from '{{packageName}}' +import { mainnet } from '{{packageName}}/chains' +import { customRpc } from './rpc' + +export const config = createConfig({ + chains: [mainnet], + connectors: [injected()], + transports: { + [mainnet.id]: custom({ // [!code hl] + async request({ method, params }) { // [!code hl] + const response = await customRpc.request(method, params) // [!code hl] + return response // [!code hl] + } // [!code hl] + }) // [!code hl] + }, +}) +``` + +## Parameters + +### provider + +`{ request({ method: string, params: unknown[] }): Promise }` + +An [EIP-1193 `request` function](https://eips.ethereum.org/EIPS/eip-1193#request) function. + +```ts +import { customRpc } from './rpc' + +const transport = custom({ + async request({ method, params }) { // [!code focus:3] + const response = await customRpc.request(method, params) + return response + } +}) +``` + +### key (optional) + +`string` + +A key for the Transport. Defaults to `"custom"`. + +```ts +const transport = custom( + provider, + { + key: 'windowProvider', // [!code focus] + } +) +``` + +### name (optional) + +`string` + +A name for the Transport. Defaults to `"Ethereum Provider"`. + +```ts +const transport = custom( + provider, + { + name: 'Window Ethereum Provider', // [!code focus] + } +) +``` + +### retryCount (optional) + +`number` + +The max number of times to retry when a request fails. Defaults to `3`. + +```ts +const transport = custom(provider, { + retryCount: 5, // [!code focus] +}) +``` + +### retryDelay (optional) + +`number` + +The base delay (in ms) between retries. By default, the Transport will use [exponential backoff](https://en.wikipedia.org/wiki/Exponential_backoff) (`~~(1 << count) * retryDelay`), which means the time between retries is not constant. + +```ts +const transport = custom(provider, { + retryDelay: 100, // [!code focus] +}) +``` \ No newline at end of file diff --git a/site/shared/transports/fallback.md b/site/shared/transports/fallback.md new file mode 100644 index 0000000000..befe9395e3 --- /dev/null +++ b/site/shared/transports/fallback.md @@ -0,0 +1,36 @@ + + +# fallback + +The `fallback` Transport consumes **multiple** Transports. If a Transport request fails, it will fall back to the next one in the list. Wraps Viem's [`fallback` Transport](https://viem.sh/docs/clients/transports/fallback.html). + +## Import + +```ts-vue +import { fallback } from '{{packageName}}' +``` + +## Usage + +```ts-vue +import { + createConfig, + fallback, // [!code hl] + http, +} from '{{packageName}}' +import { mainnet } from '{{packageName}}/chains' + +export const config = createConfig({ + chains: [mainnet], + connectors: [injected()], + transports: { + [mainnet.id]: fallback([ // [!code hl] + http('https://foo-bar-baz.quiknode.pro/...'), // [!code hl] + http('https://mainnet.infura.io/v3/...'), // [!code hl] + ]) // [!code hl] + }, +}) +``` + diff --git a/site/shared/transports/http.md b/site/shared/transports/http.md new file mode 100644 index 0000000000..1a1d864063 --- /dev/null +++ b/site/shared/transports/http.md @@ -0,0 +1,178 @@ + + +# http + +The `http` Transport connects to a JSON-RPC API via HTTP. Wraps Viem's [`http` Transport](https://viem.sh/docs/clients/transports/http.html). + +## Import + +```ts-vue +import { http } from '{{packageName}}' +``` + +## Usage + +```ts-vue +import { + createConfig, + http // [!code hl] +} from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +export const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [injected()], + transports: { + [mainnet.id]: http('https://foo-bar-baz.quiknode.pro/...'), // [!code hl] + [sepolia.id]: http('https://foo-bar-sep.quiknode.pro/...'), // [!code hl] + }, +}) +``` + +::: warning +If no URL is provided, then the transport will fall back to a public RPC URL on the chain. It is highly recommended to provide an authenticated RPC URL to prevent rate-limiting. +::: + +### Batch JSON-RPC + +The `http` Transport supports Batch JSON-RPC. This means that multiple JSON-RPC requests can be sent in a single HTTP request. + +The Transport will batch up Actions over a given period and execute them in a single Batch JSON-RPC HTTP request. By default, this period is a [zero delay](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Event_loop#zero_delays) meaning that the batch request will be executed at the end of the current [JavaScript message queue](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Event_loop#queue). Consumers can specify a custom time period `wait` (in ms). + +You can enable Batch JSON-RPC by setting the `batch` flag to `true`: + +```ts +const transport = http('https://foo-bar-baz.quiknode.pro/...', { + batch: true // [!code hl] +}) +``` + +## Parameters + +### url + +`string` + +URL of the JSON-RPC API. Defaults to `chain.rpcUrls.default.http[0]`. + +```ts +const transport = http('https://foo-bar-baz.quiknode.pro/...') +``` + +### batch + +`boolean | BatchOptions` + +Toggle to enable Batch JSON-RPC. Defaults to `false` + +```ts +const transport = http('https://foo-bar-baz.quiknode.pro/...', { + batch: true // [!code focus] +}) +``` + +### batch.batchSize + +`number` + +The maximum number of JSON-RPC requests to send in a batch. Defaults to `1_000`. + +```ts +const transport = http('https://foo-bar-baz.quiknode.pro/...', { + batch: { + batchSize: 2_000 // [!code focus] + } +}) +``` + +### batch.wait + +`number` + +The maximum number of milliseconds to wait before sending a batch. Defaults to `0` ([zero delay](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Event_loop#zero_delays)). + +```ts +const transport = http('https://foo-bar-baz.quiknode.pro/...', { + batch: { + wait: 16 // [!code focus] + } +}) +``` + +### fetchOptions + +[`RequestInit`](https://developer.mozilla.org/en-US/docs/Web/API/fetch) + +[Fetch options](https://developer.mozilla.org/en-US/docs/Web/API/fetch) to pass to the internal `fetch` function. Useful for passing auth headers or cache options. + +```ts +const transport = http('https://foo-bar-baz.quiknode.pro/...', { + fetchOptions: { // [!code focus:5] + headers: { + 'Authorization': 'Bearer ...' + } + } +}) +``` + +### key + +`string` + +A key for the Transport. Defaults to `"http"`. + +```ts +const transport = http('https://foo-bar-baz.quiknode.pro/...', { + key: 'alchemy', // [!code focus] +}) +``` + +### name + +`string` + +A name for the Transport. Defaults to `"HTTP JSON-RPC"`. + +```ts +const transport = http('https://foo-bar-baz.quiknode.pro/...', { + name: 'Alchemy HTTP Provider', // [!code focus] +}) +``` + +### retryCount + +`number` + +The max number of times to retry when a request fails. Defaults to `3`. + +```ts +const transport = http('https://foo-bar-baz.quiknode.pro/...', { + retryCount: 5, // [!code focus] +}) +``` + +### retryDelay + +`number` + +The base delay (in ms) between retries. By default, the Transport will use [exponential backoff](https://en.wikipedia.org/wiki/Exponential_backoff) (`~~(1 << count) * retryDelay`), which means the time between retries is not constant. + +```ts +const transport = http('https://foo-bar-baz.quiknode.pro/...', { + retryDelay: 100, // [!code focus] +}) +``` + +### timeout + +`number` + +The timeout for requests. Defaults to `10_000`. + +```ts +const transport = http('https://foo-bar-baz.quiknode.pro/...', { + timeout: 60_000, // [!code focus] +}) +``` diff --git a/site/shared/transports/unstable_connector.md b/site/shared/transports/unstable_connector.md new file mode 100644 index 0000000000..f858421c90 --- /dev/null +++ b/site/shared/transports/unstable_connector.md @@ -0,0 +1,123 @@ + + +# unstable_connector + +The `unstable_connector` Transport connects to a JSON-RPC API via the provided Connector. + +For example, if the provided Connector is `injected` and the end-user uses MetaMask, then outgoing JSON-RPC requests will be sent via the MetaMask EIP-1193 Provider (`window.ethereum`). + +## Import + +```ts-vue +import { unstable_connector } from '{{packageName}}' +``` + +## Usage + +```ts-vue +import { + createConfig, + fallback, + unstable_connector, // [!code hl] +} from '{{packageName}}' +import { mainnet } from '{{packageName}}/chains' + +export const config = createConfig({ + chains: [mainnet], + connectors: [injected()], + transports: { + [mainnet.id]: fallback([ + unstable_connector(injected), // [!code hl] + http('https://foo-bar-baz.quiknode.pro/...') + ]) + }, +}) +``` + +::: warning +It is **highly recommended** to use the `unstable_connector` Transport inside of a `fallback` Transport. This ensures that if the Connector request fails, the Transport will fall back to a different Transport in the fallback set. + +Some common cases for a Connector request to fail are: + +- Chain ID mismatches, +- Connector RPC not supporting the requested method and/or only supporting a subset of methods for connected accounts, +- Rate-limiting of Connector RPC. +::: + +## Parameters + +### connector + +`Connector` + +The Connector to use for the Transport. + +```ts +import { unstable_connector } from 'wagmi' +import { safe } from 'wagmi/connectors' + +const transport = unstable_connector(safe) // [!code focus] +``` + +### key (optional) + +`string` + +A key for the Transport. Defaults to `"connector"`. + +```ts +import { unstable_connector } from 'wagmi' +import { injected } from 'wagmi/connectors' + +const transport = unstable_connector(injected, { + key: 'injected', // [!code focus] +}) +``` + +### name (optional) + +`string` + +A name for the Transport. Defaults to `"Connector"`. + +```ts +import { unstable_connector } from 'wagmi' +import { injected } from 'wagmi/connectors' + +const transport = unstable_connector(injected, { + name: 'Injected', // [!code focus] +}) +``` + +### retryCount (optional) + +`number` + +The max number of times to retry when a request fails. Defaults to `3`. + +```ts +import { unstable_connector } from 'wagmi' +import { injected } from 'wagmi/connectors' + +const transport = unstable_connector(injected, { + retryCount: 5, // [!code focus] +}) +``` + +### retryDelay (optional) + +`number` + +The base delay (in ms) between retries. By default, the Transport will use [exponential backoff](https://en.wikipedia.org/wiki/Exponential_backoff) (`~~(1 << count) * retryDelay`), which means the time between retries is not constant. + +```ts +import { unstable_connector } from 'wagmi' +import { injected } from 'wagmi/connectors' + +const transport = unstable_connector(injected, { + retryDelay: 100, // [!code focus] +}) +``` diff --git a/site/shared/transports/webSocket.md b/site/shared/transports/webSocket.md new file mode 100644 index 0000000000..0b79117400 --- /dev/null +++ b/site/shared/transports/webSocket.md @@ -0,0 +1,108 @@ + + +# webSocket + +The `webSocket` Transport connects to a JSON-RPC API via a WebSocket. Wraps Viem's [`webSocket` Transport](https://viem.sh/docs/clients/transports/websocket). + +## Import + +```ts-vue +import { webSocket } from '{{packageName}}' +``` + +## Usage + +```ts-vue +import { + createConfig, + webSocket // [!code hl] +} from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +export const config = createConfig({ + chains: [mainnet, sepolia], + connectors: [injected()], + transports: { + [mainnet.id]: webSocket('wss://foo-bar-baz.quiknode.pro/...'), // [!code hl] + [sepolia.id]: webSocket('wss://foo-bar-sep.quiknode.pro/...'), // [!code hl] + }, +}) +``` + +::: warning +If no URL is provided, then the transport will fall back to a public RPC URL on the chain. It is highly recommended to provide an authenticated RPC URL to prevent rate-limiting. +::: + +## Parameters + +### url + +`string` + +URL of the JSON-RPC API. + +```ts +const transport = webSocket('wss://foo-bar-baz.quiknode.pro/...') +``` + +### key (optional) + +`string` + +A key for the Transport. Defaults to `"webSocket"`. + +```ts +const transport = webSocket('wss://foo-bar-baz.quiknode.pro/...', { + key: 'alchemy', // [!code focus] +}) +``` + +### name (optional) + +`string` + +A name for the Transport. Defaults to `"WebSocket JSON-RPC"`. + +```ts +const transport = webSocket('wss://foo-bar-baz.quiknode.pro/...', { + name: 'Alchemy WebSocket Provider', // [!code focus] +}) +``` + +### retryCount (optional) + +`number` + +The max number of times to retry when a request fails. Defaults to `3`. + +```ts +const transport = webSocket('wss://foo-bar-baz.quiknode.pro/...', { + retryCount: 5, // [!code focus] +}) +``` + +### retryDelay (optional) + +`number` + +The base delay (in ms) between retries. By default, the Transport will use [exponential backoff](https://en.wikipedia.org/wiki/Exponential_backoff) (`~~(1 << count) * retryDelay`), which means the time between retries is not constant. + +```ts +const transport = webSocket('wss://foo-bar-baz.quiknode.pro/...', { + retryDelay: 100, // [!code focus] +}) +``` + +### timeout (optional) + +`number` + +The timeout for async WebSocket requests. Defaults to `10_000`. + +```ts +const transport = webSocket('wss://foo-bar-baz.quiknode.pro/...', { + timeout: 60_000, // [!code focus] +}) +``` diff --git a/site/shared/utilities/cookieToInitialState.md b/site/shared/utilities/cookieToInitialState.md new file mode 100644 index 0000000000..0850b45020 --- /dev/null +++ b/site/shared/utilities/cookieToInitialState.md @@ -0,0 +1,74 @@ + + +# cookieToInitialState + +Helper to convert a cookie string into [initial state](/react/api/WagmiProvider#initialstate). + +## Import + +```ts-vue +import { cookieToInitialState } from '{{packageName}}' +``` + +## Usage + +::: code-group + +```ts-vue [server.ts] +import { cookieToInitialState } from '{{packageName}}' +import config from './config' + +function handler(req: Request) { + const initialState = cookieToInitialState(config, req.headers.cookie) + // ... +} +``` + +```ts-vue [config.ts] +import { + createConfig, + http, + cookieStorage, + createStorage +} from '{{packageName}}' +import { mainnet, sepolia } from '{{packageName}}/chains' + +export const config = createConfig({ + chains: [mainnet, sepolia], + ssr: true, + storage: createStorage({ + storage: cookieStorage, + }), + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +::: + +## Parameters + +### config + +`Config` + +Wagmi Config + + +### cookie + +`string | null | undefined` + +The cookie string. + +## Return Type + +`State` + +Initial state. \ No newline at end of file diff --git a/site/shared/utilities/deserialize.md b/site/shared/utilities/deserialize.md new file mode 100644 index 0000000000..c355e5a15b --- /dev/null +++ b/site/shared/utilities/deserialize.md @@ -0,0 +1,44 @@ + + +# deserialize + +Deserialize function that supports `bigint` and `Map`. + +## Import + +```ts-vue +import { deserialize } from '{{packageName}}' +``` + +## Usage + +```ts-vue +import { deserialize } from '{{packageName}}' + +const result = deserialize('{"foo":"wagmi","bar":{"__type":"bigint","value":"123"}}') +``` + +## Parameters + +### value + +`string` + +The string to deserialize. + + +### reviver + +`(key: string, value: any) => any` + +A custom reviver function for handling standard values. + +## Return Type + +`unknown` + +Parsed value. \ No newline at end of file diff --git a/site/shared/utilities/normalizeChainId.md b/site/shared/utilities/normalizeChainId.md new file mode 100644 index 0000000000..6cc1cad75d --- /dev/null +++ b/site/shared/utilities/normalizeChainId.md @@ -0,0 +1,56 @@ + + +# normalizeChainId + +Normalizes a chain ID to a number. + +## Import + +```ts-vue +import { normalizeChainId } from '{{packageName}}' +``` + +## Usage + +:::warning Deprecated +Use `Number` instead. + +```ts-vue +import { normalizeChainId } from '{{packageName}}' // [!code --] +const chainId = normalizeChainId(123n) // [!code --] +const chainId = Number(123n) // [!code ++] +``` +::: + +```ts-vue +import { normalizeChainId } from '{{packageName}}' + +const result = normalizeChainId('0x1') +``` + +## Parameters + + +### chainId + +`bigint | number | string` + +The chain ID to normalize. + +```ts-vue +import { normalizeChainId } from '{{packageName}}' + +normalizeChainId(1n) +normalizeChainId(1) +normalizeChainId('0x1') +``` + +## Return Type + +`number` + +The normalized chain ID. diff --git a/site/shared/utilities/serialize.md b/site/shared/utilities/serialize.md new file mode 100644 index 0000000000..9ce6608e7b --- /dev/null +++ b/site/shared/utilities/serialize.md @@ -0,0 +1,53 @@ + + +# serialize + +Serialize function that supports `bigint` and `Map`. + +## Import + +```ts-vue +import { serialize } from '{{packageName}}' +``` + +## Usage + +```ts-vue +import { serialize } from '{{packageName}}' + +const result = serialize({ foo: 'wagmi', bar: 123n }) +``` + +## Parameters + +### value + +`any` + +The value to stringify. + +### replacer + +`(key: string, value: any) => any` + +A custom replacer function for handling standard values. + +### indent + +`number | null | undefined` + +The number of spaces to indent the output by. + +### circularReplacer + +A custom replacer function for handling circular values. + +## Return Type + +`string` + +Stringified value. \ No newline at end of file diff --git a/site/snippets/abi-event.ts b/site/snippets/abi-event.ts new file mode 100644 index 0000000000..2d5b344ae9 --- /dev/null +++ b/site/snippets/abi-event.ts @@ -0,0 +1,20 @@ +export const abi = [ + { + type: 'event', + name: 'Approval', + inputs: [ + { indexed: true, name: 'owner', type: 'address' }, + { indexed: true, name: 'spender', type: 'address' }, + { indexed: false, name: 'value', type: 'uint256' }, + ], + }, + { + type: 'event', + name: 'Transfer', + inputs: [ + { indexed: true, name: 'from', type: 'address' }, + { indexed: true, name: 'to', type: 'address' }, + { indexed: false, name: 'value', type: 'uint256' }, + ], + }, +] as const diff --git a/site/snippets/abi-infinite-read.ts b/site/snippets/abi-infinite-read.ts new file mode 100644 index 0000000000..7e0a2b28ed --- /dev/null +++ b/site/snippets/abi-infinite-read.ts @@ -0,0 +1,23 @@ +export const abi = [ + { + inputs: [{ internalType: 'uint256', name: 'tokenId', type: 'uint256' }], + name: 'getChest', + outputs: [{ internalType: 'string', name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: 'tokenId', type: 'uint256' }], + name: 'getFoot', + outputs: [{ internalType: 'string', name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: 'tokenId', type: 'uint256' }], + name: 'getHand', + outputs: [{ internalType: 'string', name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, +] as const diff --git a/site/snippets/abi-read.ts b/site/snippets/abi-read.ts new file mode 100644 index 0000000000..f893ed2b20 --- /dev/null +++ b/site/snippets/abi-read.ts @@ -0,0 +1,16 @@ +export const abi = [ + { + type: 'function', + name: 'balanceOf', + stateMutability: 'view', + inputs: [{ name: 'account', type: 'address' }], + outputs: [{ type: 'uint256' }], + }, + { + type: 'function', + name: 'totalSupply', + stateMutability: 'view', + inputs: [], + outputs: [{ name: 'supply', type: 'uint256' }], + }, +] as const diff --git a/site/snippets/abi-write.ts b/site/snippets/abi-write.ts new file mode 100644 index 0000000000..93c1b8bb8e --- /dev/null +++ b/site/snippets/abi-write.ts @@ -0,0 +1,23 @@ +export const abi = [ + { + type: 'function', + name: 'approve', + stateMutability: 'nonpayable', + inputs: [ + { name: 'spender', type: 'address' }, + { name: 'amount', type: 'uint256' }, + ], + outputs: [{ type: 'bool' }], + }, + { + type: 'function', + name: 'transferFrom', + stateMutability: 'nonpayable', + inputs: [ + { name: 'sender', type: 'address' }, + { name: 'recipient', type: 'address' }, + { name: 'amount', type: 'uint256' }, + ], + outputs: [{ type: 'bool' }], + }, +] as const diff --git a/site/snippets/core/config-chain-properties.ts b/site/snippets/core/config-chain-properties.ts new file mode 100644 index 0000000000..d9d407cff1 --- /dev/null +++ b/site/snippets/core/config-chain-properties.ts @@ -0,0 +1,11 @@ +import { http, createConfig } from '@wagmi/core' +import { base, celo, mainnet } from '@wagmi/core/chains' + +export const config = createConfig({ + chains: [base, celo, mainnet], + transports: { + [base.id]: http(), + [celo.id]: http(), + [mainnet.id]: http(), + }, +}) diff --git a/site/snippets/core/config.ts b/site/snippets/core/config.ts new file mode 100644 index 0000000000..956f6efa06 --- /dev/null +++ b/site/snippets/core/config.ts @@ -0,0 +1,10 @@ +import { http, createConfig } from '@wagmi/core' +import { mainnet, sepolia } from '@wagmi/core/chains' + +export const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) diff --git a/site/snippets/react/app.tsx b/site/snippets/react/app.tsx new file mode 100644 index 0000000000..6fb247a541 --- /dev/null +++ b/site/snippets/react/app.tsx @@ -0,0 +1,16 @@ +import { QueryClient, QueryClientProvider } from '@tanstack/react-query' +import * as React from 'react' +import { WagmiProvider } from 'wagmi' +import { config } from './config' + +export const queryClient = new QueryClient() + +export function App() { + return ( + + + {/** ... */} + + + ) +} diff --git a/site/snippets/react/config-chain-properties.ts b/site/snippets/react/config-chain-properties.ts new file mode 100644 index 0000000000..9c71331028 --- /dev/null +++ b/site/snippets/react/config-chain-properties.ts @@ -0,0 +1,17 @@ +import { http, createConfig } from 'wagmi' +import { base, celo, mainnet } from 'wagmi/chains' + +export const config = createConfig({ + chains: [base, celo, mainnet], + transports: { + [base.id]: http(), + [celo.id]: http(), + [mainnet.id]: http(), + }, +}) + +declare module 'wagmi' { + interface Register { + config: typeof config + } +} diff --git a/site/snippets/react/config.ts b/site/snippets/react/config.ts new file mode 100644 index 0000000000..9739c926ce --- /dev/null +++ b/site/snippets/react/config.ts @@ -0,0 +1,10 @@ +import { http, createConfig } from 'wagmi' +import { mainnet, sepolia } from 'wagmi/chains' + +export const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) diff --git a/site/snippets/typedData.ts b/site/snippets/typedData.ts new file mode 100644 index 0000000000..90f01a4155 --- /dev/null +++ b/site/snippets/typedData.ts @@ -0,0 +1,13 @@ +import type { TypedData } from 'viem' + +export const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const satisfies TypedData diff --git a/site/snippets/vue/App.vue b/site/snippets/vue/App.vue new file mode 100644 index 0000000000..ae2a44fd79 --- /dev/null +++ b/site/snippets/vue/App.vue @@ -0,0 +1,5 @@ + + + \ No newline at end of file diff --git a/site/snippets/vue/config-chain-properties.ts b/site/snippets/vue/config-chain-properties.ts new file mode 100644 index 0000000000..3c3a9bcaff --- /dev/null +++ b/site/snippets/vue/config-chain-properties.ts @@ -0,0 +1,17 @@ +import { http, createConfig } from '@wagmi/vue' +import { base, celo, mainnet } from '@wagmi/vue/chains' + +export const config = createConfig({ + chains: [base, celo, mainnet], + transports: { + [base.id]: http(), + [celo.id]: http(), + [mainnet.id]: http(), + }, +}) + +declare module '@wagmi/vue' { + interface Register { + config: typeof config + } +} diff --git a/site/snippets/vue/config.ts b/site/snippets/vue/config.ts new file mode 100644 index 0000000000..558ae12e36 --- /dev/null +++ b/site/snippets/vue/config.ts @@ -0,0 +1,10 @@ +import { http, createConfig } from '@wagmi/vue' +import { mainnet, sepolia } from '@wagmi/vue/chains' + +export const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) diff --git a/site/snippets/vue/main.ts b/site/snippets/vue/main.ts new file mode 100644 index 0000000000..27ca843af0 --- /dev/null +++ b/site/snippets/vue/main.ts @@ -0,0 +1,13 @@ +import { QueryClient, VueQueryPlugin } from '@tanstack/vue-query' +import { WagmiPlugin } from '@wagmi/vue' +import { createApp } from 'vue' + +import App from './App.vue' +import { config } from './config' + +export const queryClient = new QueryClient() + +createApp(App) + .use(WagmiPlugin, { config }) + .use(VueQueryPlugin, { queryClient }) + .mount('#app') diff --git a/site/tsconfig.json b/site/tsconfig.json new file mode 100644 index 0000000000..053a800ac2 --- /dev/null +++ b/site/tsconfig.json @@ -0,0 +1,23 @@ +{ + "compilerOptions": { + "baseUrl": ".", + "esModuleInterop": true, + "forceConsistentCasingInFileNames": true, + "jsx": "preserve", + "lib": ["DOM", "ESNext"], + "module": "ESNext", + "moduleResolution": "node", + "noUnusedLocals": true, + "paths": { + "~/*": ["src/*"] + }, + "resolveJsonModule": true, + "skipLibCheck": true, + "strict": true, + "strictNullChecks": true, + "target": "esnext", + "types": ["vite/client", "vitepress"] + }, + "include": ["./*.ts", "./.vitepress/**/*.ts", "./.vitepress/**/*.vue"], + "exclude": ["dist", "node_modules", "snippets"] +} diff --git a/site/vercel.json b/site/vercel.json new file mode 100644 index 0000000000..f7abbb9989 --- /dev/null +++ b/site/vercel.json @@ -0,0 +1,148 @@ +{ + "cleanUrls": true, + "redirects": [ + { + "source": "/cli", + "destination": "/cli/getting-started", + "permanent": true + }, + + { + "source": "/core", + "destination": "/core/getting-started", + "permanent": true + }, + { + "source": "/core/migration-guide", + "destination": "/core/guides/migrate-from-v1-to-v2", + "permanent": true + }, + { + "source": "/core/:name(faq)", + "destination": "/core/guides/:name", + "permanent": true + }, + { + "source": "/core/ethers-adapters", + "destination": "/core/guides/ethers-web3", + "permanent": true + }, + { + "source": "/core/:section(chains)", + "destination": "/core/api/:section", + "permanent": true + }, + { + "source": "/core/:section(actions|connectors)/:name", + "destination": "/core/api/:section/:name", + "permanent": true + }, + { + "source": "/core/config", + "destination": "/core/api/createConfig", + "permanent": true + }, + + { + "source": "/react", + "destination": "/react/getting-started", + "permanent": true + }, + { + "source": "/react/comparison", + "destination": "/react/comparisons", + "permanent": true + }, + { + "source": "/react/migration-guide", + "destination": "/react/guides/migrate-from-v1-to-v2", + "permanent": true + }, + { + "source": "/react/:name(faq)", + "destination": "/react/guides/:name", + "permanent": true + }, + { + "source": "/react/ethers-adapters", + "destination": "/react/guides/ethers", + "permanent": true + }, + { + "source": "/react/:section(actions|chains)", + "destination": "/react/api/:section", + "permanent": true + }, + { + "source": "/react/:section(connectors|hooks)/:name", + "destination": "/react/api/:section/:name", + "permanent": true + }, + { + "source": "/react/config", + "destination": "/react/api/createConfig", + "permanent": true + }, + { + "source": "/react/WagmiConfig", + "destination": "/react/api/WagmiProvider", + "permanent": true + }, + { + "source": "/react/prepare-hooks/usePrepareContractWrite", + "destination": "/react/api/hooks/useSimulateContract", + "permanent": true + }, + { + "source": "/react/prepare-hooks/usePrepareSendTransaction", + "destination": "/react/api/hooks/useEstimateFeesPerGas", + "permanent": true + }, + + { + "source": "/examples/connect-wallet", + "destination": "/react/guides/connect-wallet", + "permanent": true + }, + { + "source": "/examples/send-transaction", + "destination": "/react/guides/send-transaction", + "permanent": true + }, + { + "source": "/react/guides/sending-transactions", + "destination": "/react/guides/send-transaction", + "permanent": true + }, + { + "source": "/react/guides/reading-contracts", + "destination": "/react/guides/read-from-contract", + "permanent": true + }, + { + "source": "/examples/contract-write(-dynamic)?", + "destination": "/react/guides/write-to-contract", + "permanent": true + }, + { + "source": "/react/guides/writing-to-contracts", + "destination": "/react/guides/write-to-contract", + "permanent": true + }, + { + "source": "/examples/custom-connector", + "destination": "/dev/creating-connectors", + "permanent": true + }, + { + "source": "/examples/sign-message", + "destination": "https://1.x.wagmi.sh/examples/sign-message", + "permanent": false + }, + { + "source": "/examples/sign-in-with-ethereum", + "destination": "https://1.x.wagmi.sh/examples/sign-in-with-ethereum", + "permanent": false + } + ] +} diff --git a/site/vue/api/Nuxt.md b/site/vue/api/Nuxt.md new file mode 100644 index 0000000000..e785cfd702 --- /dev/null +++ b/site/vue/api/Nuxt.md @@ -0,0 +1,27 @@ +# Nuxt + +[Nuxt Module](https://nuxt.com/docs/guide/concepts/modules) for Wagmi. Adds all [Composables](/vue/api/composables) as [auto-imports](https://nuxt.com/docs/guide/concepts/auto-imports). + +## Usage + +::: code-group +```ts twoslash [nuxt.config.ts] +import { defineNuxtConfig } from 'nuxt/config' + +export default defineNuxtConfig({ + modules: ['@wagmi/vue/nuxt'], +}) +``` +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + diff --git a/site/vue/api/WagmiPlugin.md b/site/vue/api/WagmiPlugin.md new file mode 100644 index 0000000000..96d2dff971 --- /dev/null +++ b/site/vue/api/WagmiPlugin.md @@ -0,0 +1,113 @@ +# WagmiPlugin + +[Vue Plugin](https://vuejs.org/guide/reusability/plugins.html#plugins) for Wagmi. + +## Import + +```ts +import { WagmiPlugin } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```ts [main.ts] +import { createApp } from 'vue' +import { WagmiPlugin } from '@wagmi/vue' + +import App from './App.vue' +import { config } from './config' + +createApp(App) + .use(WagmiPlugin, { config }) + .mount('#app') +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WagmiPluginProps } from '@wagmi/vue' +``` + +### config + +[`Config`](/vue/api/createConfig#config) object to inject with context. + +::: code-group +```ts [main.ts] +import { createApp } from 'vue' +import { WagmiPlugin } from '@wagmi/vue' + +import App from './App.vue' +import { config } from './config' + +createApp(App) + .use(WagmiPlugin, { + config // [!code focus] + }) + .mount('#app') +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### initialState + +`State | undefined` + +- Initial state to hydrate into the [Wagmi Config](/vue/api/createConfig). Useful for SSR. + +::: code-group +```ts [main.ts] +import { createApp } from 'vue' +import { WagmiPlugin } from '@wagmi/vue' + +import App from './App.vue' +import { config } from './config' + +createApp(App) + .use(WagmiPlugin, { + config, + initialState: /* ... */ // [!code focus] + }) + .mount('#app') +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### reconnectOnMount + +`boolean | undefined` + +- Whether or not to reconnect previously connected [connectors](/vue/api/createConfig#connectors) on mount. +- Defaults to `true`. + +::: code-group +```ts [main.ts] +import { createApp } from 'vue' +import { WagmiPlugin } from '@wagmi/vue' + +import App from './App.vue' +import { config } from './config' + +createApp(App) + .use(WagmiPlugin, { + config, + reconnectOnMount: false // [!code focus] + }) + .mount('#app') +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## configKey + +Key to use to provide/inject `Config` via `WagmiPlugin`. + +```ts +import { configKey, type Config } from '@wagmi/vue' +import { inject } from 'vue' + +inject(configKey) +``` diff --git a/site/vue/api/actions.md b/site/vue/api/actions.md new file mode 100644 index 0000000000..fa47b78a44 --- /dev/null +++ b/site/vue/api/actions.md @@ -0,0 +1,30 @@ +# Actions + +Sometimes the declarative nature of Vue Composables doesn't work for parts of your app. For those cases, you can use Wagmi Core Actions directly! + +All the Wagmi Core Actions are importable using the `@wagmi/vue/actions` entrypoint. For example, you can use the `watchBlockNumber` action to watch for block number changes. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +See the [Wagmi Core docs](/core/api/actions) for more info on what actions are available. diff --git a/site/vue/api/chains.md b/site/vue/api/chains.md new file mode 100644 index 0000000000..5693e95547 --- /dev/null +++ b/site/vue/api/chains.md @@ -0,0 +1,26 @@ + + +# Chains + +Viem `Chain` objects. More info at the [Viem docs](https://viem.sh/docs/chains/introduction). + +## Import + +Import via the `'@wagmi/vue/chains'` entrypoint (proxies all chains from `'viem/chains'`). + +```ts +import { mainnet } from '@wagmi/vue/chains' +``` + +## Available Chains + +Chain definitions as of `viem@{{viemVersion}}`. For `viem@latest`, visit the [Viem repo](https://github.com/wevm/viem/blob/main/src/chains/index.ts). + + + + diff --git a/site/vue/api/composables.md b/site/vue/api/composables.md new file mode 100644 index 0000000000..8d1babb981 --- /dev/null +++ b/site/vue/api/composables.md @@ -0,0 +1,25 @@ + + +# Composables + +Vue Composables for accounts, wallets, contracts, transactions, signing, ENS, and more. + +## Import + +```ts +import { useAccount } from '@wagmi/vue' +``` + +## Available Composables + + diff --git a/site/vue/api/composables/useAccount.md b/site/vue/api/composables/useAccount.md new file mode 100644 index 0000000000..41bf8727c3 --- /dev/null +++ b/site/vue/api/composables/useAccount.md @@ -0,0 +1,80 @@ +--- +title: useAccount +description: Composable for getting current account. +--- + +# useAccount + +Composable for getting current account. + +## Import + +```ts +import { useAccount } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue twoslash [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts twoslash +import { type UseAccountParameters } from '@wagmi/vue' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Return Type + +```ts twoslash +import { type UseAccountReturnType } from '@wagmi/vue' +``` + + + +## Action + +- [`getAccount`](/core/api/actions/getAccount) diff --git a/site/vue/api/composables/useAccountEffect.md b/site/vue/api/composables/useAccountEffect.md new file mode 100644 index 0000000000..8f42d593d2 --- /dev/null +++ b/site/vue/api/composables/useAccountEffect.md @@ -0,0 +1,113 @@ +--- +title: useAccountEffect +description: Composable for listening to account lifecycle events. +--- + +# useAccountEffect + +Composable for listening to account lifecycle events. + +## Import + +```ts +import { useAccountEffect } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type useAccountEffectParameters } from '@wagmi/vue' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### onConnect + +`` MaybeRef<((data: { address: `0x${string}`; addresses: readonly [`0x${string}`, ...`0x${string}`[]]; chain: Chain | undefined chainId: number; connector: Connector; isReconnected: boolean }) => void)> | undefined `` + +Callback that is called when accounts are connected. + +::: code-group +```tsx [index.tsx] +import { useAccountEffect } from '@wagmi/vue' + +function App() { + useAccountEffect({ + onConnect(data) { // [!code focus] + console.log('Connected!', data) // [!code focus] + }, // [!code focus] + }) +} +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### onDisconnect + +`MaybeRef<(() => void)> | undefined` + +Callback that is called when no more accounts are connected. + +::: code-group +```tsx [index.tsx] +import { useAccountEffect } from '@wagmi/vue' + +function App() { + useAccountEffect({ + onDisconnect() { // [!code focus] + console.log('Disconnected!') // [!code focus] + }, // [!code focus] + }) +} +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Action + +- [`getAccount`](/core/api/actions/getAccount) +- [`watchAccount`](/core/api/actions/watchAccount) diff --git a/site/vue/api/composables/useBalance.md b/site/vue/api/composables/useBalance.md new file mode 100644 index 0000000000..a84f6ba886 --- /dev/null +++ b/site/vue/api/composables/useBalance.md @@ -0,0 +1,226 @@ +--- +title: useBalance +description: Composable for fetching native currency or token balance. +--- + + + +# useBalance + +Composable for fetching native currency or token balance. + +## Import + +```ts +import { useBalance } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseBalanceParameters } from '@wagmi/vue' +``` + +### address + +`Address | undefined` + +Address to get balance for. [`enabled`](#enabled) set to `false` if `address` is `undefined`. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get balance at. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get balance at. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### token + +`Address | undefined` + +ERC-20 token address to get balance for. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### unit + +`'ether' | 'gwei' | 'wei' | number | undefined` + +- Units to use when formatting result. +- Defaults to `'ether'`. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseBalanceReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`getBalance`](/core/api/actions/getBalance) diff --git a/site/vue/api/composables/useBlockNumber.md b/site/vue/api/composables/useBlockNumber.md new file mode 100644 index 0000000000..ae8d8956ee --- /dev/null +++ b/site/vue/api/composables/useBlockNumber.md @@ -0,0 +1,172 @@ +--- +title: useBlockNumber +description: Composable for fetching the number of the most recent block seen. +--- + + + +# useBlockNumber + +Composable for fetching the number of the most recent block seen. + +## Import + +```ts +import { useBlockNumber } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseBlockNumberParameters } from '@wagmi/vue' +``` + +### cacheTime + +`MaybeRef | undefined` + +Time in milliseconds that cached block number will remain in memory. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### chainId + +`MaybeRef | undefined` + +ID of chain to use when fetching data. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### scopeKey + +`MaybeRef | undefined` + +Scopes the cache to a given context. Composables that have identical context will share the same cache. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### watch + +`MaybeRef | undefined` + +- Enables/disables listening for block number changes. +- Can pass a subset of [`UseWatchBlockNumberParameters`](/vue/api/composables/useWatchBlockNumber#parameters) directly to [`useWatchBlockNumber`](/vue/api/composables/useWatchBlockNumber). + +::: code-group +```vue [index.vue] + +``` + +```vue [index-2.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseBlockNumberReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`getBlockNumber`](/core/api/actions/getBlockNumber) +- [`watchBlockNumber`](/core/api/actions/watchBlockNumber) diff --git a/site/vue/api/composables/useBytecode.md b/site/vue/api/composables/useBytecode.md new file mode 100644 index 0000000000..a6aa3cca6d --- /dev/null +++ b/site/vue/api/composables/useBytecode.md @@ -0,0 +1,209 @@ +--- +title: useBytecode +description: Composable for retrieving the bytecode at an address. +--- + + + +# useBytecode + +Composable for retrieving the bytecode at an address. + +## Import + +```ts +import { useBytecode } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseBytecodeParameters } from '@wagmi/vue' +``` + +### address + +`Address | undefined` + +The contract address. + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +The block number to check the bytecode at. + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +The block tag to check the bytecode at. + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +The chain ID to check the bytecode at. + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/react/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Hooks that have identical context will share the same cache. + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/react/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseBytecodeReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`getBytecode`](/core/api/actions/getBytecode) diff --git a/site/vue/api/composables/useChainId.md b/site/vue/api/composables/useChainId.md new file mode 100644 index 0000000000..1419148744 --- /dev/null +++ b/site/vue/api/composables/useChainId.md @@ -0,0 +1,74 @@ +--- +title: useChainId +description: Composable for getting current chain ID. +--- + +# useChainId + +Composable for getting current chain ID. + +## Import + +```ts +import { useChainId } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseChainIdParameters } from '@wagmi/vue' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseChainIdReturnType } from '@wagmi/vue' +``` + +`number` + +Current chain ID from [`config.state.chainId`](/vue/api/createConfig#chainid). + +::: info +Only returns chain IDs for chains configured via `createConfig`'s [`chains`](/vue/api/createConfig#chains) parameter. + +If the active [connection](/vue/api/createConfig#connection) [`chainId`](/vue/api/createConfig#chainid-1) is not from a chain included in your Wagmi `Config`, `useChainId` will return the last configured chain ID. +::: + +## Action + +- [`getChainId`](/core/api/actions/getChainId) +- [`watchChainId`](/core/api/actions/watchChainId) diff --git a/site/vue/api/composables/useChains.md b/site/vue/api/composables/useChains.md new file mode 100644 index 0000000000..52daf66021 --- /dev/null +++ b/site/vue/api/composables/useChains.md @@ -0,0 +1,67 @@ +--- +title: useChains +description: Composable for getting configured chains +--- + +# useChains + +Composable for getting configured chains + +## Import + +```ts +import { useChains } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseChainsParameters } from '@wagmi/vue' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseChainsReturnType } from '@wagmi/vue' +``` + +`readonly [Chain, ...Chain[]]` + +Chains from [`config.chains`](/vue/api/createConfig#chains). + +## Action + +- [`getChains`](/core/api/actions/getChains) diff --git a/site/vue/api/composables/useClient.md b/site/vue/api/composables/useClient.md new file mode 100644 index 0000000000..18b3ca91fc --- /dev/null +++ b/site/vue/api/composables/useClient.md @@ -0,0 +1,89 @@ +--- +title: useClient +description: Composable for getting Viem `Client` instance. +--- + +# useClient + +Composable for getting Viem [`Client`](https://viem.sh/docs/clients/custom.html) instance. + +## Import + +```ts +import { useClient } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseClientParameters } from '@wagmi/vue' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when getting Viem Client. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseClientReturnType } from '@wagmi/vue' +``` + +`Client | undefined` + +Viem [`Client`](https://viem.sh/docs/clients/custom.html) instance. + +## Action + +- [`getClient`](/core/api/actions/getClient) +- [`watchClient`](/core/api/actions/watchClient) diff --git a/site/vue/api/composables/useConfig.md b/site/vue/api/composables/useConfig.md new file mode 100644 index 0000000000..7555043352 --- /dev/null +++ b/site/vue/api/composables/useConfig.md @@ -0,0 +1,33 @@ +--- +title: useConfig +description: Composable for getting `Config` from the `WagmiPlugin`. +--- + +# useConfig + +Composable for getting [`Config`](/vue/api/createConfig#config) from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +## Import + +```ts +import { useConfig } from 'wagmi' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` + +::: + +## Return Type + +```ts +import { type UseConfigReturnType } from 'wagmi' +``` diff --git a/site/vue/api/composables/useConnect.md b/site/vue/api/composables/useConnect.md new file mode 100644 index 0000000000..d1d586c561 --- /dev/null +++ b/site/vue/api/composables/useConnect.md @@ -0,0 +1,115 @@ +--- +title: useConnect +description: Composable for connecting accounts with connectors. +--- + + + +# useConnect + +Composable for connecting accounts with [connectors](/vue/api/connectors). + +## Import + +```ts +import { useConnect } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseConnectParameters } from '@wagmi/vue' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseConnectReturnType } from '@wagmi/vue' +``` + +### connectors + +`readonly Connector[]` + +Globally configured connectors via [`createConfig`](/vue/api/createConfig#connectors). Useful for rendering a list of available connectors. + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +::: tip +Not all connectors support connecting directly to a `chainId` (e.g. they don't support programmatic chain switching). In those cases, the connector will connect to whatever chain the connector's provider (e.g. wallet) is connected to. +::: + + + +## Action + +- [`connect`](/core/api/actions/connect) diff --git a/site/vue/api/composables/useConnections.md b/site/vue/api/composables/useConnections.md new file mode 100644 index 0000000000..c6fa350f90 --- /dev/null +++ b/site/vue/api/composables/useConnections.md @@ -0,0 +1,64 @@ +--- +title: useConnections +description: Composable for getting active connections. +--- + +# useConnections + +Composable for getting active connections. + +## Import + +```ts +import { useConnections } from 'wagmi' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseConnectionsParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseConnectionsReturnType } from 'wagmi' +``` + +## Action + +- [`getConnections`](/core/api/actions/getConnections) +- [`watchConnections`](/core/api/actions/watchConnections) diff --git a/site/vue/api/composables/useConnectorClient.md b/site/vue/api/composables/useConnectorClient.md new file mode 100644 index 0000000000..61f56ca616 --- /dev/null +++ b/site/vue/api/composables/useConnectorClient.md @@ -0,0 +1,128 @@ +--- +title: useConnectorClient +description: Composable for getting a Viem `Client` object for the current or provided connector. +--- + + + +# useConnectorClient + +Composable for getting a Viem [`Client`](https://viem.sh/docs/clients/custom.html) object for the current or provided connector. + +## Import + +```ts +import { useConnectorClient } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseConnectorClientParameters } from '@wagmi/vue' +``` + +### account + +`Address | Account | undefined` + +Account to use with client. Throws if account is not found on [`connector`](#connector). + +```vue + +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use with client. + +```vue + +``` + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +- Connector to get client for. +- Defaults to current connector. + +```vue + +``` + + + +## Return Type + +```ts +import { type UseConnectorClientReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`getConnectorClient`](/core/api/actions/getConnectorClient) diff --git a/site/vue/api/composables/useConnectors.md b/site/vue/api/composables/useConnectors.md new file mode 100644 index 0000000000..c05bc3d381 --- /dev/null +++ b/site/vue/api/composables/useConnectors.md @@ -0,0 +1,41 @@ +--- +title: useConnectors +description: Composable for getting configured connectors. +--- + +# useConnectors + +Composable for getting configured connectors. + +## Import + +```ts +import { useConnectors } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Return Type + +```ts +import { type UseConnectorsReturnType } from '@wagmi/vue' +``` + +`readonly Connector[]` + +Connectors from [`config.connectors`](/vue/api/createConfig#connectors-1). + +## Action + +- [`getConnectors`](/core/api/actions/getConnectors) diff --git a/site/vue/api/composables/useDisconnect.md b/site/vue/api/composables/useDisconnect.md new file mode 100644 index 0000000000..66635c3c05 --- /dev/null +++ b/site/vue/api/composables/useDisconnect.md @@ -0,0 +1,111 @@ +--- +title: useDisconnect +description: Composable for disconnecting connections. +--- + + + +# useDisconnect + +Composable for disconnecting connections. + +## Import + +```ts +import { useDisconnect } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseDisconnectParameters } from '@wagmi/vue' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseDisconnectReturnType } from '@wagmi/vue' +``` + +### connectors + +`readonly Connector[]` + +Connectors that are currently connected. Useful for rendering a list of connectors to disconnect. + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + + + +## Action + +- [`disconnect`](/core/api/actions/connect) diff --git a/site/vue/api/composables/useEnsAddress.md b/site/vue/api/composables/useEnsAddress.md new file mode 100644 index 0000000000..7aa72eed65 --- /dev/null +++ b/site/vue/api/composables/useEnsAddress.md @@ -0,0 +1,238 @@ +--- +title: useEnsAddress +description: Composable for fetching ENS address for name. +--- + + + +# useEnsAddress + +Composable for fetching ENS address for name. + +## Import + +```ts +import { useEnsAddress } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +::: warning +Since ENS names prohibit certain forbidden characters (e.g. underscore) and have other validation rules, you likely want to [normalize ENS names](https://docs.ens.domains/contract-api-reference/name-processing#normalising-names) with [UTS-46 normalization](https://unicode.org/reports/tr46) before passing them to `useEnsAddress`. You can use Viem's built-in [`normalize`](https://viem.sh/docs/ens/utilities/normalize) function for this. +::: + +## Parameters + +```ts +import { type UseEnsAddressParameters } from '@wagmi/vue' +``` + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get ENS address at. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get ENS address at. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### coinType + +`number | undefined` + +The [ENSIP-9](https://docs.ens.domains/ens-improvement-proposals/ensip-9-multichain-address-resolution) coin type to fetch the address for. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### name + +`string | undefined` + +Name to get the address for. [`enabled`](#enabled) set to `false` if `name` is `undefined`. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Composables that have identical context will share the same cache. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Address of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseEnsAddressReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`getEnsAddress`](/core/api/actions/getEnsAddress) diff --git a/site/vue/api/composables/useEnsAvatar.md b/site/vue/api/composables/useEnsAvatar.md new file mode 100644 index 0000000000..5f352e2559 --- /dev/null +++ b/site/vue/api/composables/useEnsAvatar.md @@ -0,0 +1,262 @@ +--- +title: useEnsAvatar +description: Composable for fetching ENS avatar for name. +--- + + + +# useEnsAvatar + +Composable for fetching ENS avatar for name. + +## Import + +```ts +import { useEnsAvatar } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +::: warning +Since ENS names prohibit certain forbidden characters (e.g. underscore) and have other validation rules, you likely want to [normalize ENS names](https://docs.ens.domains/contract-api-reference/name-processing#normalising-names) with [UTS-46 normalization](https://unicode.org/reports/tr46) before passing them to `useEnsAvatar`. You can use Viem's built-in [`normalize`](https://viem.sh/docs/ens/utilities/normalize) function for this. +::: + +## Parameters + +```ts +import { type UseEnsAvatarParameters } from '@wagmi/vue' +``` + +--- + +### assetGatewayUrls + +`{ ipfs?: string | undefined; arweave?: string | undefined } | undefined` + +Gateway urls to resolve IPFS and/or Arweave assets. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### blockNumber + +`bigint | undefined` + +Block number to get ENS avatar at. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get ENS avatar at. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### gatewayUrls + +`string[] | undefined` + +A set of Universal Resolver gateways, used for resolving CCIP-Read requests made through the ENS Universal Resolver Contract. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### name + +`string | undefined` + +Name to get the avatar for. [`enabled`](#enabled) set to `false` if `name` is `undefined`. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Composables that have identical context will share the same cache. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Address of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseEnsAvatarReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`getEnsAvatar`](/core/api/actions/getEnsAvatar) diff --git a/site/vue/api/composables/useEnsName.md b/site/vue/api/composables/useEnsName.md new file mode 100644 index 0000000000..74461c9964 --- /dev/null +++ b/site/vue/api/composables/useEnsName.md @@ -0,0 +1,206 @@ +--- +title: useEnsName +description: Composable for fetching primary ENS name for address. +--- + + + +# useEnsName + +Composable for fetching primary ENS name for address. + +## Import + +```ts +import { useEnsName } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseEnsNameParameters } from '@wagmi/vue' +``` + +### address + +`Address | undefined` + +Name to get the resolver for. [`enabled`](#enabled) set to `false` if `address` is `undefined`. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to get ENS name at. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get ENS name at. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Composables that have identical context will share the same cache. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### universalResolverAddress + +`Address | undefined` + +- Address of ENS Universal Resolver Contract. +- Defaults to current chain's Universal Resolver Contract address. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseEnsNameReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`getEnsName`](/core/api/actions/getEnsName) diff --git a/site/vue/api/composables/useEstimateGas.md b/site/vue/api/composables/useEstimateGas.md new file mode 100644 index 0000000000..4c05fa7674 --- /dev/null +++ b/site/vue/api/composables/useEstimateGas.md @@ -0,0 +1,387 @@ +--- +title: useEstimateGas +description: Composable for estimating the gas necessary to complete a transaction without submitting it to the network. +--- + + + +# useEstimateGas + +Composable for estimating the gas necessary to complete a transaction without submitting it to the network. + +## Import + +```ts +import { useEstimateGas } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseEstimateGasParameters } from '@wagmi/vue' +``` + +### accessList + +`AccessList | undefined` + +The access list. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### account + +`Address | Account | undefined` + +Account to use when estimating gas. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +Chain ID to target when estimating gas. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +Connector to estimate with. If no [`account`](#account) is provided, will use default account from connector. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### data + +`` `0x${string}` | undefined `` + +A contract hashed method call with encoded function data. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### gas + +`bigint | undefined` + +Gas provided for transaction execution. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### gasPrice + +`bigint | undefined` + +The price in wei to pay per gas. Only applies to [Legacy Transactions](https://viem.sh/docs/glossary/terms.html#legacy-transaction). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### maxFeePerGas + +`bigint | undefined` + +Total fee per gas in wei, inclusive of [`maxPriorityFeePerGas`](#maxPriorityFeePerGas). Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### maxPriorityFeePerGas + +`bigint | undefined` + +Max priority fee per gas in wei. Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### nonce + +`number` + +Unique number identifying this transaction. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Composables that have identical context will share the same cache. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### to + +`Address | undefined` + +The transaction recipient or contract address. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### type + +`'legacy' | 'eip1559' | 'eip2930' | undefined` + +Optional transaction request type to narrow parameters. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### value + +`bigint | undefined` + +Value in wei sent with this transaction. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseEstimateGasReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`estimateGas`](/core/api/actions/estimateGas) diff --git a/site/vue/api/composables/useReadContract.md b/site/vue/api/composables/useReadContract.md new file mode 100644 index 0000000000..98e44af8c1 --- /dev/null +++ b/site/vue/api/composables/useReadContract.md @@ -0,0 +1,410 @@ +--- +title: useReadContract +description: Composable for calling a read-only function on a contract, and returning the response. +--- + + + +# useReadContract + +Composable for calling a **read-only** function on a contract, and returning the response. + +A **read-only** function (constant function) on a Solidity contract is denoted by a pure or view keyword. They can only read the state of the contract, and cannot make any changes to it. Since read-only methods do not change the state of the contract, they do not require any gas to be executed, and can be called by any user without the need to pay for gas. + +## Import + +```ts +import { useReadContract } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseReadContractParameters } from '@wagmi/vue' +``` + +### abi + +`Abi | undefined` + +The contract's ABI. Check out the [TypeScript docs](/vue/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### account + +`Account | undefined` + +Account to use when calling the contract (`msg.sender`). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### address + +`Address | undefined` + +The contract's address. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### args + +`readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`functionName`](#functionname). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to call contract at. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to call contract at. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### functionName + +`string | undefined` + +- Function to call on the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Composables that have identical context will share the same cache. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-read.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseReadContractReturnType } from '@wagmi/vue' +``` + +The return type's [`data`](#data) property is inferrable via the combination of [`abi`](#abi), [`functionName`](#functionname), and [`args`](#args). Check out the [TypeScript docs](/vue/typescript#const-assert-abis-typed-data) for more info. + + + +## Type Inference + +With [`abi`](#abi) setup correctly, TypeScript will infer the correct types for [`functionName`](#functionname), [`args`](#args), and the return type. See the Wagmi [TypeScript docs](/vue/typescript) for more information. + +::: code-group +```ts twoslash [Inline] +import { createConfig, http, useReadContract } from '@wagmi/vue' +import { mainnet, sepolia } from 'wagmi/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +// ---cut--- +const result = useReadContract({ + abi: [ + { + type: 'function', + name: 'balanceOf', + stateMutability: 'view', + inputs: [{ name: 'account', type: 'address' }], + outputs: [{ type: 'uint256' }], + }, + { + type: 'function', + name: 'totalSupply', + stateMutability: 'view', + inputs: [], + outputs: [{ name: 'supply', type: 'uint256' }], + }, + ], + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'balanceOf', + // ^? + + + args: ['0x6b175474e89094c44da98b954eedeac495271d0f'], + // ^? + + + +}) + +result.data +// ^? +``` + +```ts twoslash [Const-Asserted] +import { createConfig, http, useReadContract } from '@wagmi/vue' +import { mainnet, sepolia } from 'wagmi/chains' + +const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +// ---cut--- +const abi = [ + { + type: 'function', + name: 'balanceOf', + stateMutability: 'view', + inputs: [{ name: 'account', type: 'address' }], + outputs: [{ type: 'uint256' }], + }, + { + type: 'function', + name: 'totalSupply', + stateMutability: 'view', + inputs: [], + outputs: [{ name: 'supply', type: 'uint256' }], + }, +] as const + +const result = useReadContract({ + abi, + address: '0x6b175474e89094c44da98b954eedeac495271d0f', + functionName: 'balanceOf', + // ^? + + + args: ['0x6b175474e89094c44da98b954eedeac495271d0f'], + // ^? +}) + +result.data +// ^? +``` +::: + + + +## Action + +- [`readContract`](/core/api/actions/readContract) diff --git a/site/vue/api/composables/useReconnect.md b/site/vue/api/composables/useReconnect.md new file mode 100644 index 0000000000..56316fee5f --- /dev/null +++ b/site/vue/api/composables/useReconnect.md @@ -0,0 +1,106 @@ +--- +title: useReconnect +description: Composable for reconnecting connectors. +--- + + + +# useReconnect + +Composable for reconnecting [connectors](/core/api/connectors). + +## Import + +```ts +import { useReconnect } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` + +::: + +::: tip +When [`WagmiPlugin['reconnectOnMount']`](/vue/api/WagmiPlugin#reconnectonmount) is `true`, `reconnect` is called automatically on mount. +::: + +## Parameters + +```ts +import { type UseReconnectParameters } from '@wagmi/vue' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseReconnectReturnType } from '@wagmi/vue' +``` + +### connectors + +`readonly Connector[]` + +Globally configured connectors via [`createConfig`](/vue/api/createConfig#connectors). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + + + +## Action + +- [`reconnect`](/core/api/actions/reconnect) diff --git a/site/vue/api/composables/useSendTransaction.md b/site/vue/api/composables/useSendTransaction.md new file mode 100644 index 0000000000..62f581143a --- /dev/null +++ b/site/vue/api/composables/useSendTransaction.md @@ -0,0 +1,91 @@ +--- +title: useSendTransaction +description: Composable for creating, signing, and sending transactions to networks. +--- + + + +# useSendTransaction + +Composable for creating, signing, and sending transactions to networks. + +## Import + +```ts +import { useSendTransaction } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseSendTransactionParameters } from '@wagmi/vue' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSendTransactionReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`sendTransaction`](/core/api/actions/sendTransaction) diff --git a/site/vue/api/composables/useSignMessage.md b/site/vue/api/composables/useSignMessage.md new file mode 100644 index 0000000000..dacbc6153c --- /dev/null +++ b/site/vue/api/composables/useSignMessage.md @@ -0,0 +1,85 @@ +--- +title: useSignMessage +description: Composable for signing messages. +--- + + + +# useSignMessage + +Composable for signing messages. + +## Import + +```ts +import { useSignMessage } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseSignMessageParameters } from '@wagmi/vue' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSignMessageReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`signMessage`](/core/api/actions/signMessage) diff --git a/site/vue/api/composables/useSignTypedData.md b/site/vue/api/composables/useSignTypedData.md new file mode 100644 index 0000000000..6c21a09012 --- /dev/null +++ b/site/vue/api/composables/useSignTypedData.md @@ -0,0 +1,214 @@ +--- +title: useSignTypedData +description: Composable for signing typed data and calculating an Ethereum-specific EIP-712 signature. +--- + + + +# useSignTypedData + +Composable for signing typed data and calculating an Ethereum-specific [EIP-712](https://eips.ethereum.org/EIPS/eip-712) signature. + +## Import + +```ts +import { useSignTypedData } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseSignTypedDataParameters } from '@wagmi/vue' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSignTypedDataReturnType } from '@wagmi/vue' +``` + + + +## Type Inference + +With [`types`](/core/api/actions/signTypedData#types) setup correctly, TypeScript will infer the correct types for [`domain`](/core/api/actions/signTypedData#domain), [`message`](/core/api/actions/signTypedData#message), and [`primaryType`](/core/api/actions/signTypedData#primarytype). See the Wagmi [TypeScript docs](/vue/typescript) for more information. + +::: code-group +```ts twoslash [Inline] +import { useSignTypedData } from '@wagmi/vue' +// ---cut--- +const { signTypedData } = useSignTypedData() + +signTypedData({ + types: { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], + }, + primaryType: 'Mail', + // ^? + + + message: { + // ^? + + + + + + + + + + + + + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, +}) +``` +```ts twoslash [Const-Asserted] +import { useSignTypedData } from '@wagmi/vue' +// ---cut--- +const types = { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' }, + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'contents', type: 'string' }, + ], +} as const + +const { signTypedData } = useSignTypedData() + +signTypedData({ + types, + primaryType: 'Mail', + // ^? + + + message: { + // ^? + + + + + + + + + + + + + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826', + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB', + }, + contents: 'Hello, Bob!', + }, +}) +``` +::: + + + +## Action + +- [`signTypedData`](/core/api/actions/signTypedData) diff --git a/site/vue/api/composables/useSimulateContract.md b/site/vue/api/composables/useSimulateContract.md new file mode 100644 index 0000000000..7e10c486d6 --- /dev/null +++ b/site/vue/api/composables/useSimulateContract.md @@ -0,0 +1,686 @@ +--- +title: useSimulateContract +description: Composable for simulating/validating a contract interaction. +--- + + + +# useSimulateContract + +Composable for simulating/validating a contract interaction. + +## Import + +```ts +import { useSimulateContract } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Parameters + +```ts +import { type UseSimulateContractParameters } from '@wagmi/vue' +``` + +### abi + +`Abi | undefined` + +The contract's ABI. Check out the [TypeScript docs](/vue/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### accessList + +`AccessList | undefined` + +The access list. + +::: code-group +```vue [index.ts] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### account + +`Account | undefined` + +Account to use when calling the contract (`msg.sender`). Throws if account is not found on [`connector`](#connector). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### address + +`Address | undefined` + +The contract's address. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### args + +`readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`functionName`](#functionname). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### blockNumber + +`bigint | undefined` + +Block number to call contract at. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to call contract at. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### connector + +`Connector | undefined` + +[Connector](/vue/api/connectors) to simulate transaction with. + +::: code-group +```vue [index.ts] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### dataSuffix + +`` `0x${string}` | undefined `` + +Data to append to the end of the calldata. Useful for adding a ["domain" tag](https://opensea.notion.site/opensea/Seaport-Order-Attributions-ec2d69bf455041a5baa490941aad307f). + +::: code-group +```vue [index.ts] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### functionName + +`string | undefined` + +- Function to call on the contract. +- Inferred from [`abi`](#abi). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### gas + +`bigint | undefined` + +Gas provided for transaction execution. + +::: code-group +```vue [index.ts] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### gasPrice + +`bigint | undefined` + +The price in wei to pay per gas. Only applies to [Legacy Transactions](https://viem.sh/docs/glossary/terms.html#legacy-transaction). + +::: code-group +```vue [index.ts] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### maxFeePerGas + +`bigint | undefined` + +Total fee per gas in wei, inclusive of [`maxPriorityFeePerGas`](#maxPriorityFeePerGas). Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```vue [index.ts] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### maxPriorityFeePerGas + +`bigint | undefined` + +Max priority fee per gas in wei. Only applies to [EIP-1559 Transactions](https://viem.sh/docs/glossary/terms.html#eip-1559-transaction). + +::: code-group +```vue [index.ts] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +--- + +### nonce + +`number` + +Unique number identifying this transaction. + +::: code-group +```vue [index.ts] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### type + +`'legacy' | 'eip1559' | 'eip2930' | undefined` + +Optional transaction request type to narrow parameters. + +::: code-group +```vue [index.ts] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### value + +`bigint | undefined` + +Value in wei sent with this transaction. + +::: code-group +```vue [index.ts] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Composables that have identical context will share the same cache. + +::: code-group +```vue [index.ts] + +``` +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSimulateContractReturnType } from '@wagmi/vue' +``` + +The return type's [`data`](#data) property is inferrable via the combination of [`abi`](#abi), [`functionName`](#functionname), and [`args`](#args). Check out the [TypeScript docs](/vue/typescript#const-assert-abis-typed-data) for more info. + + + +## Type Inference + +With [`abi`](#abi) setup correctly, TypeScript will infer the correct types for [`functionName`](#functionname), [`args`](#args), and [`value`](#value). See the Wagmi [TypeScript docs](/vue/typescript) for more information. + + + +## Action + +- [`simulateContract`](/core/api/actions/simulateContract) diff --git a/site/vue/api/composables/useSwitchAccount.md b/site/vue/api/composables/useSwitchAccount.md new file mode 100644 index 0000000000..bf965bbebb --- /dev/null +++ b/site/vue/api/composables/useSwitchAccount.md @@ -0,0 +1,120 @@ +--- +title: useSwitchAccount +description: Composable for switching the current account. +--- + + + +# useSwitchAccount + +Composable for switching the current account. + +## Import + +```ts +import { useSwitchAccount } from 'wagmi' +``` + +## Usage + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseSwitchAccountParameters } from 'wagmi' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSwitchAccountReturnType } from 'wagmi' +``` + +### connectors + +`readonly Connector[]` + +Globally configured and actively connected connectors. Useful for rendering a list of available connectors to switch to. + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + + + +## Action + +- [`switchAccount`](/core/api/actions/switchAccount) diff --git a/site/vue/api/composables/useSwitchChain.md b/site/vue/api/composables/useSwitchChain.md new file mode 100644 index 0000000000..c7dace93ef --- /dev/null +++ b/site/vue/api/composables/useSwitchChain.md @@ -0,0 +1,124 @@ +--- +title: useSwitchChain +description: Composable for switching the target chain for a connector or the Wagmi `Config`. +--- + + + +# useSwitchChain + +Composable for switching the target chain for a connector or the Wagmi [`Config`](/vue/api/createConfig#config). + +## Import + +```ts +import { useSwitchChain } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +::: tip +When connected, `switchChain` will switch the target chain for the connector. When not connected, `switchChain` will switch the target chain for the Wagmi [`Config`](/vue/api/createConfig#config). +::: + +## Parameters + +```ts +import { type UseSwitchChainParameters } from '@wagmi/vue' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseSwitchChainReturnType } from '@wagmi/vue' +``` + +### chains + +`readonly [Chain, ...Chain[]]` + +Globally configured chains. Useful for rendering a list of available chains to switch to. + +::: code-group +```vue [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + + + +## Action + +- [`switchChain`](/core/api/actions/switchChain) diff --git a/site/vue/api/composables/useTransaction.md b/site/vue/api/composables/useTransaction.md new file mode 100644 index 0000000000..80fedc53d3 --- /dev/null +++ b/site/vue/api/composables/useTransaction.md @@ -0,0 +1,184 @@ +--- +title: useTransaction +description: Composable for fetching transactions given hashes or block identifiers. +--- + + + +# useTransaction + +Composable for fetching transactions given hashes or block identifiers. + +## Import + +```ts +import { useTransaction } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseTransactionParameters } from '@wagmi/vue' +``` + +--- + +### blockHash + +`bigint | undefined` + +Block hash to get transaction at (with [`index`](#index)). + +```vue + +``` + +### blockNumber + +`bigint | undefined` + +Block number to get transaction at (with [`index`](#index)). + +```vue + +``` + +### blockTag + +`'latest' | 'earliest' | 'pending' | 'safe' | 'finalized' | undefined` + +Block tag to get transaction at (with [`index`](#index)). + +```vue + +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +```vue + +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### hash + +`` `0x${string}` | undefined `` + +Hash to get transaction. [`enabled`](#enabled) set to `false` if `hash` and [`index`](#index) are `undefined`. + +```vue + +``` + +### index + +`number | undefined` + +An index to be used with a block identifier ([hash](#blockhash), [number](#blocknumber), or [tag](#blocktag)). [`enabled`](#enabled) set to `false` if `index` and [`hash`](#hash) are `undefined`. + +```vue + +``` + + + +## Return Type + +```ts +import { type UseTransactionReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`getTransaction`](/core/api/actions/getTransaction) diff --git a/site/vue/api/composables/useTransactionReceipt.md b/site/vue/api/composables/useTransactionReceipt.md new file mode 100644 index 0000000000..e610c23840 --- /dev/null +++ b/site/vue/api/composables/useTransactionReceipt.md @@ -0,0 +1,141 @@ +--- +title: useTransactionReceipt +description: Composable for return the Transaction Receipt given a Transaction hash. +--- + + + +# useTransactionReceipt + +Composable for return the [Transaction Receipt](https://viem.sh/docs/glossary/terms.html#transaction-receipt) given a [Transaction](https://viem.sh/docs/glossary/terms.html#transaction) hash. + +## Import + +```ts +import { useTransactionReceipt } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseTransactionReceiptParameters } from '@wagmi/vue' +``` + +### hash + +`` `0x${string}` | undefined `` + +A transaction hash. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### chainId + +`config['chains'][number]['id'] | undefined` + +The ID of chain to return the transaction receipt from. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### scopeKey + +`string | undefined` + +Scopes the cache to a given context. Composables that have identical context will share the same cache. + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseTransactionReceiptReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`getTransactionReceipt`](/core/api/actions/getTransactionReceipt) diff --git a/site/vue/api/composables/useWaitForTransactionReceipt.md b/site/vue/api/composables/useWaitForTransactionReceipt.md new file mode 100644 index 0000000000..80c887a8f7 --- /dev/null +++ b/site/vue/api/composables/useWaitForTransactionReceipt.md @@ -0,0 +1,168 @@ +--- +title: useWaitForTransactionReceipt +description: Composable that waits for the transaction to be included on a block, and then returns the transaction receipt. If the transaction reverts, then the action will throw an error. Replacement detection (e.g. sped up transactions) is also supported. +--- + + + +# useWaitForTransactionReceipt + +Composable that waits for the transaction to be included on a block, and then returns the transaction receipt. If the transaction reverts, then the action will throw an error. Replacement detection (e.g. sped up transactions) is also supported. + +## Import + +```ts +import { useWaitForTransactionReceipt } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type WaitForTransactionReceiptParameters } from '@wagmi/core' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +```vue [index.vue] + +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group +```vue [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +### confirmations + +`number | undefined` + +The number of confirmations (blocks that have passed) to wait before resolving. + +```vue [index.vue] + +``` + +### onReplaced + +` +(({ reason: 'replaced' | 'repriced' | 'cancelled'; replacedTransaction: Transaction; transaction: Transaction; transactionReceipt: TransactionReceipt }) => void) | undefined +` + +Optional callback to emit if the transaction has been replaced. + +```vue [index.vue] + +``` + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/vue/api/createConfig#pollinginterval). + +```vue [index.vue] + +``` + +### hash + +`` `0x${string}` | undefined `` + +The transaction hash to wait for. [`enabled`](#enabled) set to `false` if `hash` is `undefined`. + +```vue [index.vue] + +``` + + + +## Return Type + +```ts +import { type UseWaitForTransactionReceiptReturnType } from '@wagmi/vue' +``` + + + + + +## Action + +- [`waitForTransactionReceipt`](/core/api/actions/waitForTransactionReceipt) diff --git a/site/vue/api/composables/useWatchBlockNumber.md b/site/vue/api/composables/useWatchBlockNumber.md new file mode 100644 index 0000000000..5d0a561cd1 --- /dev/null +++ b/site/vue/api/composables/useWatchBlockNumber.md @@ -0,0 +1,109 @@ +# useWatchBlockNumber + +Composable that watches for block number changes. + +## Import + +```ts +import { useWatchBlockNumber } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```ts [index.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseWatchBlockNumberParameters } from '@wagmi/vue' +``` + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to watch blocks at. + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +### emitMissed + +`boolean` + +Whether or not to emit missed blocks to the callback. Defaults to `false`. + +Missed blocks may occur in instances where internet connection is lost, or the block time is lesser than the polling interval of the client. + +### emitOnBegin + +`boolean` + +Whether or not to emit the block to the callback when the subscription opens. Defaults to `false`. + +### enabled + +`boolean` + +Whether or not to watch for blocks. Defaults to `true`. + +### onBlockNumber + +`(block: Block, prevblock: Block | undefined) => void` + +Callback for when block changes. + +### onError + +`((error: Error) => void) | undefined` + +Error thrown from getting the block. + +### poll + +`boolean | undefined` + +- Whether or not to use a polling mechanism to check for new blocks instead of a WebSocket subscription. +- Defaults to `false` for WebSocket Clients, and `true` for non-WebSocket Clients. + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/core/api/createConfig#pollinginterval). + +### syncConnectedChain + +`boolean | undefined` + +- Set up subscriber for connected chain changes. +- Defaults to [`Config['syncConnectedChain']`](/core/api/createConfig#syncconnectedchain). + +## Return Type + +```ts +import { type UseWatchBlockNumberReturnType } from '@wagmi/vue' +``` + +Function for cleaning up watcher. + +## Action + +- [`watchBlockNumber`](/core/api/actions/watchBlockNumber) diff --git a/site/vue/api/composables/useWatchContractEvent.md b/site/vue/api/composables/useWatchContractEvent.md new file mode 100644 index 0000000000..5467c49a50 --- /dev/null +++ b/site/vue/api/composables/useWatchContractEvent.md @@ -0,0 +1,134 @@ +# useWatchContractEvent + +Composable that watches and returns emitted contract event logs. + +## Import + +```ts +import { useWatchContractEvent } from '@wagmi/vue' +``` + +## Usage + +::: code-group +```ts [index.vue] + +``` +<<< @/snippets/abi-event.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Parameters + +```ts +import { type UseWatchContractEventParameters } from '@wagmi/vue' +``` + +### abi + +`Abi` + +The contract's ABI. Check out the [TypeScript docs](/vue/typescript#const-assert-abis-typed-data) for how to set up ABIs for maximum type inference and safety. + +### address + +`Address | undefined` + +The contract's address. + +### args + +`object | readonly unknown[] | undefined` + +- Arguments to pass when calling the contract. +- Inferred from [`abi`](#abi) and [`eventName`](#eventname). + +### batch + +`boolean | undefined` + +- Whether or not the events should be batched on each invocation. +- Defaults to `true`. + +### chainId + +`config['chains'][number]['id'] | undefined` + +ID of chain to use when fetching data. + +### config + +`Config | undefined` + +[`Config`](/react/api/createConfig#config) to use instead of retrieving from the nearest [`WagmiProvider`](/react/api/WagmiProvider). + +### eventName + +`string` + +- Event to listen for the contract. +- Inferred from [`abi`](#abi). + +### onError + +`((error: Error) => void) | undefined` + +Error thrown from getting the block number. + +### onLogs + +`(logs: Log[], prevLogs: Log[] | undefined) => void` + +Callback for when logs changes. + +### poll + +`boolean | undefined` + +- Whether or not to use a polling mechanism to check for new blocks instead of a WebSocket subscription. +- Defaults to `false` for WebSocket Clients, and `true` for non-WebSocket Clients. + +### pollingInterval + +`number | undefined` + +- Polling frequency (in milliseconds). +- Defaults to the [Config's `pollingInterval` config](/core/api/createConfig#pollinginterval). + +### strict + +`boolean | undefined` + +- Defaults to `false`. + +### syncConnectedChain + +`boolean | undefined` + +- Set up subscriber for connected chain changes. +- Defaults to [`Config['syncConnectedChain']`](/core/api/createConfig#syncconnectedchain). + +## Return Type + +```ts +import { type UseWatchContractEventReturnType } from '@wagmi/vue' +``` + +Hook returns `void` + +## Action + +- [`watchContractEvent`](/core/api/actions/watchContractEvent) + diff --git a/site/vue/api/composables/useWriteContract.md b/site/vue/api/composables/useWriteContract.md new file mode 100644 index 0000000000..1221345851 --- /dev/null +++ b/site/vue/api/composables/useWriteContract.md @@ -0,0 +1,112 @@ +--- +title: useWriteContract +description: Composable for executing a write function on a contract. +--- + + + +# useWriteContract + +Composable for executing a write function on a contract. + +A "write" function on a Solidity contract modifies the state of the blockchain. These types of functions require gas to be executed, hence a transaction is broadcasted in order to change the state. + +## Import + +```ts +import { useWriteContract } from '@wagmi/vue' +``` + +## Usage + +::: code-group + +```vue [index.vue] + + + +``` + +<<< @/snippets/abi-write.ts[abi.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + + + + + +## Parameters + +```ts +import { type UseWriteContractParameters } from '@wagmi/vue' +``` + +### config + +`Config | undefined` + +[`Config`](/vue/api/createConfig#config) to use instead of retrieving from the [`WagmiPlugin`](/vue/api/WagmiPlugin). + +::: code-group + +```vue [index.vue] + +``` + +<<< @/snippets/vue/config.ts[config.ts] +::: + + + +## Return Type + +```ts +import { type UseWriteContractReturnType } from '@wagmi/vue' +``` + +The return type's [`data`](#data) property is inferrable via the combination of [`abi`](#abi), [`functionName`](#functionname), and [`args`](#args). Check out the [TypeScript docs](/vue/typescript#const-assert-abis-typed-data) for more info. + + + +## Type Inference + +With [`abi`](/core/api/actions/writeContract#abi) setup correctly, TypeScript will infer the correct types for [`functionName`](/core/api/actions/writeContract#functionname), [`args`](/core/api/actions/writeContract#args), and the [`value`](/core/api/actions/writeContract##value). See the Wagmi [TypeScript docs](/vue/typescript) for more information. + + + +## Action + +- [`writeContract`](/core/api/actions/writeContract) diff --git a/site/vue/api/connectors.md b/site/vue/api/connectors.md new file mode 100644 index 0000000000..6d3a189936 --- /dev/null +++ b/site/vue/api/connectors.md @@ -0,0 +1,28 @@ + + +# Connectors + +Connectors for popular wallet providers and protocols. + +## Import + +Import via the `'@wagmi/vue/connectors'` entrypoint. + +```ts +import { injected } from '@wagmi/vue/connectors' +``` + +## Available Connectors + + diff --git a/site/vue/api/connectors/coinbaseWallet.md b/site/vue/api/connectors/coinbaseWallet.md new file mode 100644 index 0000000000..839a80f567 --- /dev/null +++ b/site/vue/api/connectors/coinbaseWallet.md @@ -0,0 +1,6 @@ + + + \ No newline at end of file diff --git a/site/vue/api/connectors/injected.md b/site/vue/api/connectors/injected.md new file mode 100644 index 0000000000..45c5e158e0 --- /dev/null +++ b/site/vue/api/connectors/injected.md @@ -0,0 +1,7 @@ + + + diff --git a/site/vue/api/connectors/metaMask.md b/site/vue/api/connectors/metaMask.md new file mode 100644 index 0000000000..30d15d7794 --- /dev/null +++ b/site/vue/api/connectors/metaMask.md @@ -0,0 +1,7 @@ + + + diff --git a/site/vue/api/connectors/mock.md b/site/vue/api/connectors/mock.md new file mode 100644 index 0000000000..532cc19fbf --- /dev/null +++ b/site/vue/api/connectors/mock.md @@ -0,0 +1,6 @@ + + + diff --git a/site/vue/api/connectors/safe.md b/site/vue/api/connectors/safe.md new file mode 100644 index 0000000000..85fb516ca7 --- /dev/null +++ b/site/vue/api/connectors/safe.md @@ -0,0 +1,6 @@ + + + diff --git a/site/vue/api/connectors/walletConnect.md b/site/vue/api/connectors/walletConnect.md new file mode 100644 index 0000000000..c3840c3979 --- /dev/null +++ b/site/vue/api/connectors/walletConnect.md @@ -0,0 +1,6 @@ + + + diff --git a/site/vue/api/createConfig.md b/site/vue/api/createConfig.md new file mode 100644 index 0000000000..8210634c08 --- /dev/null +++ b/site/vue/api/createConfig.md @@ -0,0 +1,7 @@ + + + diff --git a/site/vue/api/createStorage.md b/site/vue/api/createStorage.md new file mode 100644 index 0000000000..f4901773c1 --- /dev/null +++ b/site/vue/api/createStorage.md @@ -0,0 +1,6 @@ + + + diff --git a/site/vue/api/errors.md b/site/vue/api/errors.md new file mode 100644 index 0000000000..d914152150 --- /dev/null +++ b/site/vue/api/errors.md @@ -0,0 +1,10 @@ + + +# Errors + +Error classes used by Wagmi. + + \ No newline at end of file diff --git a/site/vue/api/transports.md b/site/vue/api/transports.md new file mode 100644 index 0000000000..c35d06b631 --- /dev/null +++ b/site/vue/api/transports.md @@ -0,0 +1,28 @@ + + +# Transports + +[`createConfig`](/vue/api/createConfig) can be instantiated with a set of Transports for each chain. A Transport is the intermediary layer that is responsible for executing outgoing JSON-RPC requests to the RPC Provider (e.g. Alchemy, Infura, etc). + +## Import + +```ts +import { http } from '@wagmi/vue' +``` + +## Built-In Transports + +Available via the `'@wagmi/vue'` entrypoint. + + diff --git a/site/vue/api/transports/custom.md b/site/vue/api/transports/custom.md new file mode 100644 index 0000000000..4ece9d2d46 --- /dev/null +++ b/site/vue/api/transports/custom.md @@ -0,0 +1,5 @@ + + + diff --git a/site/vue/api/transports/fallback.md b/site/vue/api/transports/fallback.md new file mode 100644 index 0000000000..084762db3b --- /dev/null +++ b/site/vue/api/transports/fallback.md @@ -0,0 +1,5 @@ + + + diff --git a/site/vue/api/transports/http.md b/site/vue/api/transports/http.md new file mode 100644 index 0000000000..93e1fc3c93 --- /dev/null +++ b/site/vue/api/transports/http.md @@ -0,0 +1,5 @@ + + + diff --git a/site/vue/api/transports/unstable_connector.md b/site/vue/api/transports/unstable_connector.md new file mode 100644 index 0000000000..8bb1bfc52f --- /dev/null +++ b/site/vue/api/transports/unstable_connector.md @@ -0,0 +1,6 @@ + + + diff --git a/site/vue/api/transports/webSocket.md b/site/vue/api/transports/webSocket.md new file mode 100644 index 0000000000..3559e6ff89 --- /dev/null +++ b/site/vue/api/transports/webSocket.md @@ -0,0 +1,5 @@ + + + diff --git a/site/vue/api/utilities/deserialize.md b/site/vue/api/utilities/deserialize.md new file mode 100644 index 0000000000..871aabe907 --- /dev/null +++ b/site/vue/api/utilities/deserialize.md @@ -0,0 +1,5 @@ + + + diff --git a/site/vue/api/utilities/serialize.md b/site/vue/api/utilities/serialize.md new file mode 100644 index 0000000000..63abbda162 --- /dev/null +++ b/site/vue/api/utilities/serialize.md @@ -0,0 +1,5 @@ + + + diff --git a/site/vue/getting-started.md b/site/vue/getting-started.md new file mode 100644 index 0000000000..c36bceab02 --- /dev/null +++ b/site/vue/getting-started.md @@ -0,0 +1,217 @@ + + +# Getting Started + +## Overview + +Wagmi is a collection of Vue composition utilities for Ethereum. You can learn more about the rationale behind the project in the [Why Wagmi](/vue/why) section. + +## Automatic Installation + +For new projects, it is recommended to set up your Wagmi app using the [`create-wagmi`](/cli/create-wagmi) command line interface (CLI). This will create a new Wagmi project using TypeScript and install the required dependencies. + +::: code-group +```bash [pnpm] +pnpm create wagmi +``` + +```bash [npm] +npm create wagmi@latest +``` + +```bash [yarn] +yarn create wagmi +``` + +```bash [bun] +bun create wagmi +``` +::: + +Once the command runs, you'll see some prompts to complete. + +```ansi +Project name: wagmi-project +Select a framework: Vue / Vanilla +... +``` + +After the prompts, `create-wagmi` will create a directory with your project name and install the required dependencies. Check out the `README.md` for further instructions (if required). + +## Manual Installation + +To manually add Wagmi to your project, install the required packages. + +::: code-group +```bash-vue [pnpm] +pnpm add @wagmi/vue viem@{{viemVersion}} @tanstack/vue-query +``` + +```bash-vue [npm] +npm install @wagmi/vue viem@{{viemVersion}} @tanstack/vue-query +``` + +```bash-vue [yarn] +yarn add @wagmi/vue viem@{{viemVersion}} @tanstack/vue-query +``` + +```bash-vue [bun] +bun add @wagmi/vue viem@{{viemVersion}} @tanstack/vue-query +``` +::: + +- [Viem](https://viem.sh) is a TypeScript interface for Ethereum that performs blockchain operations. +- [TanStack Query](https://tanstack.com/query/v5) is an async state manager that handles requests, caching, and more. +- [TypeScript](/vue/typescript) is optional, but highly recommended. Learn more about [TypeScript support](/vue/typescript). + +### Create Config + +Create and export a new Wagmi config using `createConfig`. + +::: code-group +<<< @/snippets/vue/config.ts[config.ts] +::: + +In this example, Wagmi is configured to use the Mainnet and Sepolia chains, and `injected` connector. Check out the [`createConfig` docs](/vue/api/createConfig) for more configuration options. + +::: details TypeScript Tip +If you are using TypeScript, you can "register" the Wagmi config or use the hook `config` property to get strong type-safety in places that wouldn't normally have type info. + +::: code-group +```ts twoslash [register config] +// @errors: 2322 +import { type Config } from '@wagmi/vue' +import { mainnet, sepolia } from '@wagmi/vue/chains' + +declare const config: Config +// ---cut--- +import { useBlockNumber } from '@wagmi/vue' + +useBlockNumber({ chainId: 123 }) + +declare module '@wagmi/vue' { + interface Register { + config: typeof config + } +} +``` + +```ts twoslash [hook config property] +// @errors: 2322 +import { type Config } from '@wagmi/vue' +import { mainnet, sepolia } from '@wagmi/vue/chains' + +declare const config: Config +// ---cut--- +import { useBlockNumber } from '@wagmi/vue' + +useBlockNumber({ chainId: 123, config }) +``` + +By registering or using the hook `config` property, `useBlockNumber`'s `chainId` is strongly typed to only allow Mainnet and Sepolia IDs. Learn more by reading the [TypeScript docs](/vue/typescript#config-types). +::: + +### Add Plugin to App + +Add the `WagmiPlugin` to your app instance and pass the `config` you created earlier to the plugin options. + +::: code-group +```tsx [main.ts] +import { WagmiPlugin } from '@wagmi/vue' // [!code focus] +import { createApp } from 'vue' +import { config } from './config' // [!code focus] +import App from './App.vue' + +createApp(App) + .use(WagmiPlugin, { config }) // [!code focus] + .mount('#app') +``` +```vue [App.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +Check out the [`WagmiPlugin` docs](/vue/api/WagmiPlugin) to learn more about the plugin API. + +### Setup TanStack Query + +After the `WagmiPlugin`, attach the `VueQueryPlugin` to your app, and pass a new `QueryClient` instance to the `queryClient` property. + +::: code-group +```tsx [main.ts] +import { QueryClient, VueQueryPlugin } from '@tanstack/vue-query' // [!code focus] +import { WagmiPlugin } from '@wagmi/vue' +import { createApp } from 'vue' +import { config } from './config' +import App from './App.vue' + +const queryClient = new QueryClient() // [!code focus] + +createApp(App) + .use(WagmiPlugin, { config }) + .use(VueQueryPlugin, { queryClient }) // [!code focus] + .mount('#app') +``` +```vue [App.vue] + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + +Check out the [TanStack Query docs](https://tanstack.com/query/latest/docs/framework/vue) to learn about the library, APIs, and more. + +### Use Wagmi + +Now that everything is set up, every component inside your app can use Wagmi Vue Composables. + +::: code-group +```vue [App.vue] + + + +``` +```tsx [main.ts] +import { QueryClient, VueQueryPlugin } from '@tanstack/vue-query' +import { WagmiPlugin } from '@wagmi/vue' +import { createApp } from 'vue' +import { config } from './config' +import App from './App.vue' + +const queryClient = new QueryClient() + +createApp(App) + .use(WagmiPlugin, { config }) + .use(VueQueryPlugin, { queryClient }) + .mount('#app') +``` +<<< @/snippets/vue/config.ts[config.ts] +::: + + +## Next Steps + +For more information on what to do next, check out the following topics. + +- [**TypeScript**](/vue/typescript) Learn how to get the most out of Wagmi's type-safety and inference for an enlightened developer experience. +- [**Connect Wallet**](/vue/guides/connect-wallet) Learn how to enable wallets to connect to and disconnect from your apps and display information about connected accounts. +- [**Vue Composables**](/vue/api/composables) Browse the collection of Vue Composables and learn how to use them. +- [**Viem**](/vue/guides/viem) Learn about Viem and how it works with Wagmi. + diff --git a/site/vue/guides/chain-properties.md b/site/vue/guides/chain-properties.md new file mode 100644 index 0000000000..0f41ef41c9 --- /dev/null +++ b/site/vue/guides/chain-properties.md @@ -0,0 +1,97 @@ +# Chain Properties + +Some chains support additional properties related to blocks and transactions. This is powered by Viem's [formatters](https://viem.sh/docs/chains/formatters) and [serializers](https://viem.sh/docs/chains/serializers). For example, Celo, ZkSync, OP Stack chains support all support additional properties. In order to use these properties in a type-safe way, there are a few things you should be aware of. + +
+ +::: tip +Make sure you follow the TypeScript guide's [Config Types](/vue/typescript#config-types) section before moving on. The easiest way to do this is to use [Declaration Merging](/vue/typescript#declaration-merging) to "register" your `config` globally with TypeScript. + +<<< @/snippets/vue/config-chain-properties.ts[config.ts] +::: + +## Narrowing Parameters + +Once your Config is registered with TypeScript, you are ready to access chain-specific properties! For example, Celo's `feeCurrency` is available. + +::: code-group +```ts [index.tsx] +import { parseEther } from 'viem' +import { useSimulateContract } from '@wagmi/vue' + +const result = useSimulateContract({ + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + feeCurrency: '0x…', // [!code focus] +}) +``` +<<< @/snippets/vue/config-chain-properties.ts[config.ts] +::: + +This is great, but if you have multiple chains that support additional properties, your autocomplete could be overwhelmed with all of them. By setting the `chainId` property to a specific value (e.g. `celo.id`), you can narrow parameters to a single chain. + +::: code-group +```ts [index.tsx] +import { parseEther } from 'viem' +import { useSimulateContract } from '@wagmi/vue' +import { celo } from '@wagmi/vue/chains' + +const result = useSimulateContract({ + to: '0xd2135CfB216b74109775236E36d4b433F1DF507B', + value: parseEther('0.01'), + chainId: celo.id, // [!code focus] + feeCurrency: '0x…', // [!code focus] + // ^? (property) feeCurrency?: `0x${string}` | undefined // [!code focus] +}) +``` +<<< @/snippets/vue/config-chain-properties.ts[config.ts] +::: + +## Narrowing Return Types + +Return types can also have chain-specific properties attached to them. There are a couple approaches for extracting these properties. + +### `chainId` Parameter + +Not only can you use the `chainId` parameter to [narrow parameters](#narrowing-parameters), you can also use it to narrow the return type. + +::: code-group +```ts [index.tsx] +import { useWaitForTransactionReceipt } from '@wagmi/vue' +import { zkSync } from '@wagmi/vue/chains' + +const { data } = useWaitForTransactionReceipt({ + chainId: zkSync.id, + hash: '0x16854fcdd0219cacf5aec5e4eb2154dac9e406578a1510a6fc48bd0b67e69ea9', +}) + +data?.logs +// ^? (property) logs: ZkSyncLog[] | undefined +``` +<<< @/snippets/vue/config-chain-properties.ts[config.ts] +::: + +### `chainId` Data Property + +Wagmi internally will set a `chainId` property on return types that you can use to narrow results. The `chainId` is determined from the `chainId` parameter or global state (e.g. connector). You can use this property to help TypeScript narrow the type. + +::: code-group +```ts [index.tsx] +import { useWaitForTransactionReceipt } from '@wagmi/vue' +import { zkSync } from '@wagmi/vue/chains' + +const { data } = useWaitForTransactionReceipt({ + hash: '0x16854fcdd0219cacf5aec5e4eb2154dac9e406578a1510a6fc48bd0b67e69ea9', +}) + +if (data?.chainId === zkSync.id) { + data?.logs + // ^? (property) logs: ZkSyncLog[] | undefined +} +``` +<<< @/snippets/vue/config-chain-properties.ts[config.ts] +::: + +## Troubleshooting + +If chain properties aren't working, make sure [TypeScript](/vue/guides/faq#type-inference-doesn-t-work) is configured correctly. Not all chains have additional properties, to check which ones do, see the [Viem repo](https://github.com/wevm/viem/tree/main/src/chains) (chains that have a top-level directory under [`src/chains`](https://github.com/wevm/viem/tree/main/src/chains) support additional properties). diff --git a/site/vue/guides/connect-wallet.md b/site/vue/guides/connect-wallet.md new file mode 100644 index 0000000000..89e795ac72 --- /dev/null +++ b/site/vue/guides/connect-wallet.md @@ -0,0 +1,387 @@ +# Connect Wallet + +The ability for a user to connect their wallet is a core function for any Dapp. It allows users to perform tasks such as: writing to contracts, signing messages, or sending transactions. + +Wagmi contains everything you need to get started with building a Connect Wallet module. To get started, you can either use a [third-party library](#third-party-libraries) or [build your own](#build-your-own). + +## Third-party Libraries + +You can use a pre-built Connect Wallet module from a third-party library such as: + +- [AppKit](https://walletconnect.com/appkit) - [Guide](https://docs.walletconnect.com/appkit/vue/core/installation) + +The above libraries are all built on top of Wagmi, handle all the edge cases around wallet connection, and provide a seamless Connect Wallet UX that you can use in your Dapp. + +## Build Your Own + +Wagmi provides you with the Composables to get started building your own Connect Wallet module. + +It takes less than five minutes to get up and running with Browser Wallets, WalletConnect, and Coinbase Wallet. + +### 1. Configure Wagmi + +Before we get started with building the functionality of the Connect Wallet module, we will need to set up the Wagmi configuration. + +Let's create a `config.ts` file and export a `config` object. + +::: code-group + +```tsx [config.ts] +import { http, createConfig } from '@wagmi/vue' +import { base, mainnet, optimism } from '@wagmi/vue/chains' +import { injected, metaMask, safe, walletConnect } from '@wagmi/vue/connectors' + +const projectId = '' + +export const config = createConfig({ + chains: [mainnet, base], + connectors: [ + injected(), + walletConnect({ projectId }), + metaMask(), + safe(), + ], + transports: { + [mainnet.id]: http(), + [base.id]: http(), + }, +}) +``` + +::: + +In the above configuration, we want to set up connectors for Injected (browser), WalletConnect (browser + mobile), MetaMask, and Safe wallets. This configuration uses the **Mainnet** and **Base** chains, but you can use whatever you want. + +::: warning + +Make sure to replace the `projectId` with your own WalletConnect Project ID, if you wish to use WalletConnect! + +[Get your Project ID](https://cloud.walletconnect.com/) + +::: + +### 2. Inject the WagmiPlugin onto your App + +Next, we will need to inject our App with plugins so that our application is aware of Wagmi & Vue Query's reactive state and in-memory caching. + +::: code-group + +```ts [main.ts] +// 1. Import modules. +import { VueQueryPlugin } from '@tanstack/vue-query'; +import { WagmiPlugin } from '@wagmi/vue'; +import { createApp } from 'vue'; + +import App from './App.vue'; +import { config } from './wagmi'; + +createApp(App) + // 2. Inject the Wagmi plugin. + .use(WagmiPlugin, { config }) + // 3. Inject the Vue Query plugin. + .use(VueQueryPlugin, {}) + .mount('#app'); +``` + +```vue [App.vue] + + + +``` + +```ts [config.ts] +import { http, createConfig } from '@wagmi/vue' +import { base, mainnet, optimism } from '@wagmi/vue/chains' +import { injected, metaMask, safe, walletConnect } from '@wagmi/vue/connectors' + +const projectId = '' + +export const config = createConfig({ + chains: [mainnet, base], + connectors: [ + injected(), + walletConnect({ projectId }), + metaMask(), + safe(), + ], + transports: { + [mainnet.id]: http(), + [base.id]: http(), + }, +}) +``` + +::: + +### 3. Display Wallet Options + +After that, we will create a `Connect` component that will display our connectors. This will allow users to select a wallet and connect. + +Below, we are rendering a list of `connectors` retrieved from `useConnect`. When the user clicks on a connector, the `connect` function will connect the users' wallet. + +::: code-group + +```vue [Connect.vue] + + + +``` + +```vue [App.vue] + + + +``` + +```ts [main.ts] +// 1. Import modules. +import { VueQueryPlugin } from '@tanstack/vue-query'; +import { WagmiPlugin } from '@wagmi/vue'; +import { createApp } from 'vue'; + +import App from './App.vue'; +import { config } from './wagmi'; + +createApp(App) + // 2. Inject the Wagmi plugin. + .use(WagmiPlugin, { config }) + // 3. Inject the Vue Query plugin. + .use(VueQueryPlugin, {}) + .mount('#app'); +``` + +```ts [config.ts] +import { http, createConfig } from '@wagmi/vue' +import { base, mainnet, optimism } from '@wagmi/vue/chains' +import { injected, metaMask, safe, walletConnect } from '@wagmi/vue/connectors' + +const projectId = '' + +export const config = createConfig({ + chains: [mainnet, base], + connectors: [ + injected(), + walletConnect({ projectId }), + metaMask(), + safe(), + ], + transports: { + [mainnet.id]: http(), + [base.id]: http(), + }, +}) +``` + +::: + +### 4. Display Connected Account + +Lastly, if an account is connected, we want to show some basic information, like the connected address and ENS name and avatar. + +Below, we are using hooks like `useAccount`, `useEnsAvatar` and `useEnsName` to extract this information. + +We are also utilizing `useDisconnect` to show a "Disconnect" button so a user can disconnect their wallet. + +::: code-group + +```vue [Account.vue] + + + +``` + +```vue [Connect.vue] + + + +``` + +```vue [App.vue] + + + +``` + +```ts [main.ts] +// 1. Import modules. +import { VueQueryPlugin } from '@tanstack/vue-query'; +import { WagmiPlugin } from '@wagmi/vue'; +import { createApp } from 'vue'; + +import App from './App.vue'; +import { config } from './wagmi'; + +createApp(App) + // 2. Inject the Wagmi plugin. + .use(WagmiPlugin, { config }) + // 3. Inject the Vue Query plugin. + .use(VueQueryPlugin, {}) + .mount('#app'); +``` + +```ts [config.ts] +import { http, createConfig } from '@wagmi/vue' +import { base, mainnet, optimism } from '@wagmi/vue/chains' +import { injected, metaMask, safe, walletConnect } from '@wagmi/vue/connectors' + +const projectId = '' + +export const config = createConfig({ + chains: [mainnet, base], + connectors: [ + injected(), + walletConnect({ projectId }), + metaMask(), + safe(), + ], + transports: { + [mainnet.id]: http(), + [base.id]: http(), + }, +}) +``` + +::: + +### 5. Wire it up! + +Finally, we can wire up our Connect and Account components to our application's entrypoint. + +::: code-group + +```vue [App.vue] + + + + +``` + +```vue [Account.vue] + + + +``` + +```vue [Connect.vue] + + + +``` + +```ts [main.ts] +// 1. Import modules. +import { VueQueryPlugin } from '@tanstack/vue-query'; +import { WagmiPlugin } from '@wagmi/vue'; +import { createApp } from 'vue'; + +import App from './App.vue'; +import { config } from './wagmi'; + +createApp(App) + // 2. Inject the Wagmi plugin. + .use(WagmiPlugin, { config }) + // 3. Inject the Vue Query plugin. + .use(VueQueryPlugin, {}) + .mount('#app'); +``` + +```ts [config.ts] +import { http, createConfig } from '@wagmi/vue' +import { base, mainnet, optimism } from '@wagmi/vue/chains' +import { injected, metaMask, safe, walletConnect } from '@wagmi/vue/connectors' + +const projectId = '' + +export const config = createConfig({ + chains: [mainnet, base], + connectors: [ + injected(), + walletConnect({ projectId }), + metaMask(), + safe(), + ], + transports: { + [mainnet.id]: http(), + [base.id]: http(), + }, +}) +``` + +::: + +### Playground + +Want to see the above steps all wired up together in an end-to-end example? Check out the below StackBlitz playground. + +
+ + diff --git a/site/vue/guides/error-handling.md b/site/vue/guides/error-handling.md new file mode 100644 index 0000000000..8cb7e9b507 --- /dev/null +++ b/site/vue/guides/error-handling.md @@ -0,0 +1,39 @@ +# Error Handling + +The `error` property in Wagmi Composables is strongly typed with it's corresponding error type. This enables you to have granular precision with handling errors in your application. + +You can discriminate the error type by using the `name` property on the error object. + +::: code-group +```vue twoslash [index.vue] + + + +``` +<<< @/snippets/vue/config.ts[config.ts] +::: diff --git a/site/vue/guides/faq.md b/site/vue/guides/faq.md new file mode 100644 index 0000000000..61def1c79d --- /dev/null +++ b/site/vue/guides/faq.md @@ -0,0 +1,9 @@ + + +# FAQ / Troubleshooting + +Collection of frequently asked questions with ideas on how to troubleshoot and resolve them. + + diff --git a/site/vue/guides/read-from-contract.md b/site/vue/guides/read-from-contract.md new file mode 100644 index 0000000000..8bf78acc91 --- /dev/null +++ b/site/vue/guides/read-from-contract.md @@ -0,0 +1,206 @@ +# Read from Contract + +## Overview + +The [`useReadContract` Composable](/vue/api/composables/useReadContract) allows you to read data on a smart contract, from a `view` or `pure` (read-only) function. They can only read the state of the contract, and cannot make any changes to it. Since read-only methods do not change the state of the contract, they do not require any gas to be executed, and can be called by any user without the need to pay for gas. + +The component below shows how to retrieve the token balance of an address from the [Wagmi Example](https://etherscan.io/token/0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2) contract + +:::code-group + +```vue [ReadContract.vue] + + + +``` +```ts [contracts.ts] +export const wagmiContractConfig = { + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: [ + { + type: 'function', + name: 'balanceOf', + stateMutability: 'view', + inputs: [{ name: 'account', type: 'address' }], + outputs: [{ type: 'uint256' }], + }, + { + type: 'function', + name: 'totalSupply', + stateMutability: 'view', + inputs: [], + outputs: [{ name: 'supply', type: 'uint256' }], + }, + ], +} as const +``` +::: + + +If `useReadContract` depends on another value (`address` in the example below), you can use the [`query.enabled`](/vue/api/composables/useReadContract#enabled) option to prevent the query from running until the dependency is ready. + +```tsx +const { data: balance } = useReadContract({ + ...wagmiContractConfig, + functionName: 'balanceOf', + args: [address], + query: { // [!code focus] + enabled: !!address, // [!code focus] + }, // [!code focus] +}) +``` + + +## Loading & Error States + +The [`useReadContract` Composable](/vue/api/composables/useReadContract) also returns loading & error states, which can be used to display a loading indicator while the data is being fetched, or an error message if contract execution reverts. + +:::code-group + +```vue [ReadContract.vue] + + + +``` + +::: + + + + diff --git a/site/vue/guides/send-transaction.md b/site/vue/guides/send-transaction.md new file mode 100644 index 0000000000..6686e720be --- /dev/null +++ b/site/vue/guides/send-transaction.md @@ -0,0 +1,311 @@ +# Send Transaction + +The following guide teaches you how to send transactions in Wagmi. The example below builds on the [Connect Wallet guide](/vue/guides/connect-wallet) and uses the [useSendTransaction](/vue/api/composables/useSendTransaction) & [useWaitForTransaction](/vue/api/composables/useWaitForTransactionReceipt) composables. + +## Example + +Feel free to check out the example before moving on: + + + +## Steps + +### 1. Connect Wallet + +Follow the [Connect Wallet guide](/vue/guides/connect-wallet) guide to get this set up. + +### 2. Create a new component + +Create your `SendTransaction` component that will contain the send transaction logic. + +::: code-group + +```tsx [SendTransaction.vue] + + + +``` + +::: + +### 3. Add a form handler + +Next, we will need to add a handler to the form that will send the transaction when the user hits "Send". This will be a basic handler in this step. + +::: code-group + +```vue [SendTransaction.vue] + + + +``` + +::: + +### 4. Hook up the `useSendTransaction` Composable + +Now that we have the form handler, we can hook up the [`useSendTransaction` Composable](/vue/api/composables/useSendTransaction) to send the transaction. + +::: code-group + +```vue [SendTransaction.vue] + + + +``` + +::: + +### 5. Add loading state (optional) + +We can optionally add a loading state to the "Send" button while we are waiting confirmation from the user's wallet. + +::: code-group + +```vue [SendTransaction.vue] + + + +``` + +::: + +### 6. Wait for transaction receipt (optional) + +We can also display the transaction confirmation status to the user by using the [`useWaitForTransactionReceipt` Composable](/vue/api/composables/useWaitForTransactionReceipt). + +::: code-group + +```vue [SendTransaction.vue] + + + +``` + +::: + +### 7. Handle errors (optional) + +If the user rejects the transaction, or the user does not have enough funds to cover the transaction, we can display an error message to the user. + +::: code-group + +```vue [SendTransaction.vue] + + + +``` + +::: + +### 8. Wire it up! + +Finally, we can wire up our Send Transaction component to our application's entrypoint. + +:::code-group +```vue [App.vue] + + + +``` +```vue [SendTransaction.vue] + + + +``` +::: + +[See the Example.](#example) diff --git a/site/vue/guides/ssr.md b/site/vue/guides/ssr.md new file mode 100644 index 0000000000..bf6fc4e2e9 --- /dev/null +++ b/site/vue/guides/ssr.md @@ -0,0 +1,77 @@ +--- +outline: deep +--- + +# SSR + +Wagmi uses client-only external stores (such as `localStorage` and `mipd`) to show the user the most relevant data as quickly as possible on first render. + +However, the caveat of using these external client stores is that frameworks which incorporate SSR (such as Next.js) will throw hydration warnings on the client when it identifies mismatches between the server-rendered HTML and the client-rendered HTML. + +To stop this from happening, you can toggle on the [`ssr`](/vue/api/createConfig#ssr) property in the Wagmi Config. + +```tsx +import { createConfig, http } from '@wagmi/vue' +import { mainnet, sepolia } from '@wagmi/vue/chains' + +const config = createConfig({ // [!code focus:99] + chains: [mainnet, sepolia], + ssr: true, // [!code ++] + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +Turning on the `ssr` property means that content from the external stores will be hydrated on the client after the initial mount. + +## Persistence using Cookies + +As a result of turning on the `ssr` property, external persistent stores like `localStorage` will be hydrated on the client **after the initial mount**. + +This means that you will still see a flash of "empty" data on the client (e.g. a `"disconnected"` account instead of a `"reconnecting"` account, or an empty address instead of the last connected address) until after the first mount, when the store hydrates. + +In order to persist data between the server and the client, you can use cookies. + +### 1. Set up cookie storage + +First, we will set up cookie storage in the Wagmi Config. + +```tsx +import { + createConfig, + http, + cookieStorage, // [!code ++] + createStorage // [!code ++] +} from '@wagmi/vue' +import { mainnet, sepolia } from '@wagmi/vue/chains' + +export const config = createConfig({ + chains: [mainnet, sepolia], + ssr: true, + storage: createStorage({ // [!code ++] + storage: cookieStorage, // [!code ++] + }), // [!code ++] + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +### 2. Hydrate the cookie + +Next, we will need to add some mechanisms to hydrate the stored cookie in Wagmi. + +#### Nuxt.js + +Would you like to contribute this content? Feel free to [open a Pull Request](https://github.com/wevm/wagmi/pulls)! + + +#### Vanilla SSR + +Would you like to contribute this content? Feel free to [open a Pull Request](https://github.com/wevm/wagmi/pulls)! + + + diff --git a/site/vue/guides/tanstack-query.md b/site/vue/guides/tanstack-query.md new file mode 100644 index 0000000000..9d5efb4d7a --- /dev/null +++ b/site/vue/guides/tanstack-query.md @@ -0,0 +1,287 @@ +# TanStack Query + +Wagmi Composables are not only a wrapper around the core [Wagmi Actions](/core/api/actions), but they also utilize [TanStack Query](https://tanstack.com/query/v5) to enable trivial and intuitive fetching, caching, synchronizing, and updating of asynchronous data in your Vue applications. + +Without an asynchronous data fetching abstraction, you would need to handle all the negative side-effects that comes as a result, such as: representing finite states (loading, error, success), handling race conditions, caching against a deterministic identifier, etc. + +## Queries & Mutations + +Wagmi Composables represent either a **Query** or a **Mutation**. + +**Queries** are used for fetching data (e.g. fetching a block number, reading from a contract, etc), and are typically invoked on mount by default. All queries are coupled to a unique [Query Key](#query-keys), and can be used for further operations such as refetching, prefetching, or modifying the cached data. + +**Mutations** are used for mutating data (e.g. connecting/disconnecting accounts, writing to a contract, switching chains, etc), and are typically invoked in response to a user interaction. Unlike **Queries**, they are not coupled with a query key. + +## Terms + +- **Query**: An asynchronous data fetching (e.g. read data) operation that is tied against a unique Query Key. +- **Mutation**: An asynchronous mutating (e.g. create/update/delete data or side-effect) operation. +- **Query Key**: A unique identifier that is used to deterministically identify a query. It is typically a tuple of the query name and the query arguments. +- **Stale Data**: Data that is unused or inactive after a certain period of time. +- **Query Fetching**: The process of invoking an async query function. +- **Query Refetching**: The process of refetching **rendered** queries. +- **[Query Invalidation](https://tanstack.com/query/v5/docs/vue/guides/query-invalidation)**: The process of marking query data as stale (e.g. inactive/unused), and refetching **rendered** queries. +- **[Query Prefetching](https://tanstack.com/query/v5/docs/vue/guides/prefetching)**: The process of prefetching queries and seeding the cache. + + + +## Query Keys + +Query Keys are typically used to perform advanced operations on the query such as: invalidation, refetching, prefetching, etc. + +Wagmi exports Query Keys for every Composable, and they can be retrieved via the [Composable (Vue)](#composable-vue) or via an [Import (Vanilla JS)](#import-vanilla-js). + +Read more about **Query Keys** on the [TanStack Query docs.](https://tanstack.com/query/v5/docs/vue/guides/query-keys) + +### Composable (Vue) + +Each Composable returns a `queryKey` value. You would use this approach when you want to utilize the query key in a Vue component as it handles reactivity for you, unlike the [Import](#import-vanilla-js) method below. + +```vue [index.vue] + + + +``` + +### Import (Vanilla JS) + +Each Hook has a corresponding `getQueryOptions` function that returns a query key. You would use this method when you want to utilize the query key outside of a Vue component in a Vanilla JS context, like in a utility function. + +```ts +import { getBalanceQueryOptions } from '@wagmi/vue/query' // [!code hl] +import { config } from './config' + +function perform() { + const { queryKey } = getBalanceQueryOptions(config, { // [!code hl] + chainId: config.state.chainId // [!code hl] + }) // [!code hl] +} +``` + +::: warning + +The caveat of this method is that it does not handle reactivity for you (e.g. active account/chain changes, argument changes, etc). You would need to handle this yourself by explicitly passing through the arguments to `getQueryOptions`. + +::: + +## Invalidating Queries + +Invalidating a query is the process of marking the query data as stale (e.g. inactive/unused), and refetching the queries that are already rendered. + +Read more about **Invalidating Queries** on the [TanStack Query docs.](https://tanstack.com/query/v5/docs/vue/guides/query-invalidation) + +#### Example: Watching a Users' Balance + +You may want to "watch" a users' balance, and invalidate the balance after each incoming block. We can invoke `invalidateQueries` inside a `watchEffect` – this will refetch all rendered balance queries when the `blockNumber` changes. + +```vue + + + +``` + +#### Example: After User Interaction + +Maybe you want to invalidate a users' balance after some interaction. This would mark the balance as stale, and consequently refetch all rendered balance queries. + +```vue + + + +``` + +```vue + + + +``` + +## Fetching Queries + +Fetching a query is the process of invoking the query function to retrieve data. If the query exists and the data is not invalidated or older than a given `staleTime`, then the data from the cache will be returned. Otherwise, the query will fetch for the latest data. + +::: code-group +```tsx [example.tsx] +import { getBlockQueryOptions } from '@wagmi/vue/query' +import { queryClient } from './main' +import { config } from './config' + +export async function fetchBlockData() { + return queryClient.fetchQuery( // [!code hl] + getBlockQueryOptions(config, { // [!code hl] + chainId: config.state.chainId, // [!code hl] + } // [!code hl] + )) // [!code hl] +} +``` +<<< @/snippets/vue/main.ts[main.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Retrieving & Updating Query Data + +You can retrieve and update query data imperatively with `getQueryData` and `setQueryData`. This is useful for scenarios where you want to retrieve or update a query outside of a Vue component. + +Note that these functions do not invalidate or refetch queries. + +::: code-group +```tsx [example.tsx] +import type { GetBalanceReturnType } from '@wagmi/vue/actions' +import { getBalanceQueryOptions } from '@wagmi/vue/query' +import { queryClient } from './app' +import { config } from './config' + +export function getBalanceData() { + return queryClient.getQueryData( // [!code hl] + getBalanceQueryOptions(config, { // [!code hl] + chainId: config.state.chainId, // [!code hl] + } // [!code hl] + )) // [!code hl] +} + +export function setBalanceData(parameters: Partial) { + return queryClient.setQueryData( // [!code hl] + getBalanceQueryOptions(config, { // [!code hl] + chainId: config.state.chainId, // [!code hl] + }, // [!code hl] + data => ({ ...data, ...parameters }) // [!code hl] + )) // [!code hl] +} +``` +<<< @/snippets/vue/main.ts[main.ts] +<<< @/snippets/vue/config.ts[config.ts] +::: + +## Prefetching Queries + +Prefetching a query is the process of fetching the data ahead of time and seeding the cache with the returned data. This is useful for scenarios where you want to fetch data before the user navigates to a page, or fetching data on the server to be reused on client hydration. + +Read more about **Prefetching Queries** on the [TanStack Query docs.](https://tanstack.com/query/v5/docs/vue/guides/prefetching) + +#### Example: Prefetching in Event Handler + +```vue + + + +``` + +## SSR + +It is possible to utilize TanStack Query's SSR strategies with Wagmi Composables & Query Keys. Check out the [SSR guide](https://tanstack.com/query/latest/docs/framework/vue/guides/ssr). + +## Devtools + +TanStack Query includes dedicated [Devtools](https://tanstack.com/query/latest/docs/framework/vue/devtools) that assist in visualizing and debugging your queries, their cache states, and much more. You will have to pass a custom `queryKeyFn` to your `QueryClient` for Devtools to correctly serialize BigInt values for display. Alternatively, You can use the `hashFn` from `@wagmi/core/query`, which already handles this serialization. + +#### Install + +::: code-group +```bash [pnpm] +pnpm i @tanstack/vue-query-devtools +``` + +```bash [npm] +npm i @tanstack/vue-query-devtools +``` + +```bash [yarn] +yarn add @tanstack/vue-query-devtools +``` + +```bash [bun] +bun i @tanstack/vue-query-devtools +``` +::: + +#### Usage + +::: code-group +```vue [App.vue] + + + +``` + +```vue [main.vue] + +``` +::: \ No newline at end of file diff --git a/site/vue/guides/viem.md b/site/vue/guides/viem.md new file mode 100644 index 0000000000..a4b7da32d0 --- /dev/null +++ b/site/vue/guides/viem.md @@ -0,0 +1,94 @@ +# Viem + +[Viem](https://viem.sh) is a low-level TypeScript Interface for Ethereum that enables developers to interact with the Ethereum blockchain, including: JSON-RPC API abstractions, Smart Contract interaction, wallet & signing implementations, coding/parsing utilities and more. + +**Wagmi Core** is essentially a wrapper over **Viem** that provides multi-chain functionality via [Wagmi Config](/react/api/createConfig) and automatic account management via [Connectors](/react/api/connectors). + +## Leveraging Viem Actions + +All of the core [Wagmi Composables](/vue/api/composables) are friendly wrappers around [Viem Actions](https://viem.sh/docs/actions/public/introduction.html) that inject a multi-chain and connector aware [Wagmi Config](/vue/api/createConfig). + +There may be cases where you might want to dig deeper and utilize Viem Actions directly (maybe a Composable doesn't exist in Wagmi yet). In these cases, you can create your own custom Wagmi Composable by importing Viem Actions directly via `viem/actions` and plugging in a Viem Client returned by the [`useClient` Composable](/vue/api/composables/useClient). + +There are two categories of Viem Actions: + +- **[Public Actions](https://viem.sh/docs/actions/public/introduction):** Actions that are "read-only" and do not require a wallet connection. +- **[Wallet Actions](https://viem.sh/docs/actions/wallet/introduction):** Actions that interface with a Wallet and require a wallet connection. + +While it is not mandatory, it is also recommended to pair Actions with either `useQuery` or `useMutation` to effectively leverage the reactivity and caching capabilities of [Tanstack Query](/vue/guides/tanstack-query). + +### Public Actions + +The example below demonstrates how to utilize Viem's `getLogs` Action with a `useQuery` Composable to create your own abstraction akin to a `useLogs` Composable. + +```vue + +``` + +### Wallet Actions + +The example below demonstrates how to utilize Viem's `watchAsset` Action with a `useMutation` Composable to create your own abstraction akin to a `useWatchAsset` Composable. + +```vue + +``` + +## Private Key & Mnemonic Accounts + +It is possible to utilize Viem's [Private Key & Mnemonic Accounts](https://viem.sh/docs/accounts/local.html) with Wagmi by explicitly passing through the account via the `account` argument on Wagmi Actions. + +```vue + +``` + +::: info + +Wagmi currently does not support hoisting Private Key & Mnemonic Accounts to the top-level Wagmi Config – meaning you have to explicitly pass through the account to every Action. If you feel like this is a feature that should be added, please [open an discussion](https://github.com/wevm/wagmi/discussions/new?category=ideas). + +::: diff --git a/site/vue/guides/write-to-contract.md b/site/vue/guides/write-to-contract.md new file mode 100644 index 0000000000..9bdc788428 --- /dev/null +++ b/site/vue/guides/write-to-contract.md @@ -0,0 +1,387 @@ +# Write to Contract + +The [`useWriteContract` Composable](/vue/api/composables/useWriteContract) allows you to mutate data on a smart contract, from a `payable` or `nonpayable` (write) function. These types of functions require gas to be executed, hence a transaction is broadcasted in order to change the state. + +In the guide below, we will teach you how to implement a "Mint NFT" form that takes in a dynamic argument (token ID) using Wagmi. The example below builds on the [Connect Wallet guide](/vue/guides/connect-wallet) and uses the [useWriteContract](/vue/api/composables/useWriteContract) & [useWaitForTransaction](/vue/api/composables/useWaitForTransactionReceipt) composables. + +If you have already completed the [Sending Transactions guide](/vue/guides/send-transaction), this guide will look very similar! That's because writing to a contract internally broadcasts & sends a transaction. + +## Example + +Feel free to check out the example before moving on: + + + +## Steps + +### 1. Connect Wallet + +Follow the [Connect Wallet guide](/vue/guides/connect-wallet) guide to get this set up. + +### 2. Create a new component + +Create your `MintNft` component that will contain the Mint NFT logic. + +::: code-group + +```vue [MintNft.vue] + + + +``` + +::: + +### 3. Add a form handler + +Next, we will need to add a handler to the form that will send the transaction when the user hits "Mint". This will be a basic handler in this step. + +::: code-group + +```vue [MintNft.vue] + + + +``` + +::: + +### 4. Hook up the `useWriteContract` Composable + +Now that we have the form handler, we can hook up the [`useWriteContract` Composable](/vue/api/composables/useWriteContract) to send the transaction. + +::: code-group + +```vue [MintNft.vue] + + + +``` + +```ts [abi.ts] +export const abi = [ + { + name: 'mint', + type: 'function', + stateMutability: 'nonpayable', + inputs: [{ internalType: 'uint32', name: 'tokenId', type: 'uint32' }], + outputs: [], + }, +] as const +``` + +::: + +### 5. Add loading state (optional) + +We can optionally add a loading state to the "Mint" button while we are waiting confirmation from the user's wallet. + +::: code-group + +```vue [MintNft.vue] + + + +``` + +```ts [abi.ts] +export const abi = [ + { + name: 'mint', + type: 'function', + stateMutability: 'nonpayable', + inputs: [{ internalType: 'uint32', name: 'tokenId', type: 'uint32' }], + outputs: [], + }, +] as const +``` + +::: + +### 6. Wait for transaction receipt (optional) + +We can also display the transaction confirmation status to the user by using the [`useWaitForTransactionReceipt` Composable](/vue/api/composables/useWaitForTransactionReceipt). + +::: code-group + +```vue [MintNft.vue] + + + +``` + +```ts [abi.ts] +export const abi = [ + { + name: 'mint', + type: 'function', + stateMutability: 'nonpayable', + inputs: [{ internalType: 'uint32', name: 'tokenId', type: 'uint32' }], + outputs: [], + }, +] as const +``` + +::: + +### 7. Handle errors (optional) + +If the user rejects the transaction, or the user does not have enough funds to cover the transaction, we can display an error message to the user. + +::: code-group + +```vue [MintNft.vue] + + + +``` + +```ts [abi.ts] +export const abi = [ + { + name: 'mint', + type: 'function', + stateMutability: 'nonpayable', + inputs: [{ internalType: 'uint32', name: 'tokenId', type: 'uint32' }], + outputs: [], + }, +] as const +``` + +::: + +### 8. Wire it up! + +Finally, we can wire up our Send Transaction component to our application's entrypoint. + +:::code-group +```vue [App.vue] + + + +``` + +```vue [MintNft.vue] + + + +``` + +```ts [abi.ts] +export const abi = [ + { + name: 'mint', + type: 'function', + stateMutability: 'nonpayable', + inputs: [{ internalType: 'uint32', name: 'tokenId', type: 'uint32' }], + outputs: [], + }, +] as const +``` +::: + +[See the Example.](#example) \ No newline at end of file diff --git a/site/vue/installation.md b/site/vue/installation.md new file mode 100644 index 0000000000..82676c43fa --- /dev/null +++ b/site/vue/installation.md @@ -0,0 +1,41 @@ + + +# Installation + +Install Wagmi via your package manager, a ` + +# TypeScript + +## Requirements + +Wagmi is designed to be as type-safe as possible! Things to keep in mind: + +- Types currently require using TypeScript {{typescriptVersion}}. +- [TypeScript doesn't follow semver](https://www.learningtypescript.com/articles/why-typescript-doesnt-follow-strict-semantic-versioning) and often introduces breaking changes in minor releases. +- Changes to types in this repository are considered non-breaking and are usually released as patch changes (otherwise every type enhancement would be a major version!). +- It is highly recommended that you lock your `wagmi` and `typescript` versions to specific patch releases and upgrade with the expectation that types may be fixed or upgraded between any release. +- The non-type-related public API of Wagmi still follows semver very strictly. + +To ensure everything works correctly, make sure your `tsconfig.json` has [`strict`](https://www.typescriptlang.org/tsconfig#strict) mode set to `true`. + +::: code-group +```json [tsconfig.json] +{ + "compilerOptions": { + "strict": true + } +} +``` +::: + +## Config Types + +By default Vue Plugins does not work well with type inference. To support strong type-safety across the Vue Plugins boundary, there are two options available: + +- Declaration merging to "register" your `config` globally with TypeScript. +- `config` property to pass your `config` directly to composables. + +### Declaration Merging + +[Declaration merging](https://www.typescriptlang.org/docs/handbook/declaration-merging.html) allows you to "register" your `config` globally with TypeScript. The `Register` type enables Wagmi to infer types in places that wouldn't normally have access to type info via a Vue Plugin alone. + +To set this up, add the following declaration to your project. Below, we co-locate the declaration merging and the `config` set up. + +```ts +import { createConfig, http } from '@wagmi/vue' +import { mainnet, sepolia } from 'wagmi/chains' + +declare module '@wagmi/vue' { // [!code focus] + interface Register { // [!code focus] + config: typeof config // [!code focus] + } // [!code focus] +} // [!code focus] + +export const config = createConfig({ + chains: [mainnet, sepolia], + transports: { + [mainnet.id]: http(), + [sepolia.id]: http(), + }, +}) +``` + +Since the `Register` type is global, you only need to add it once in your project. Once set up, you will get strong type-safety across your entire project. For example, query composables will type `chainId` based on your `config`'s `chains`. + +```ts twoslash +// @errors: 2322 +import { type Config } from '@wagmi/vue' +import { mainnet, sepolia } from 'wagmi/chains' + +declare module '@wagmi/vue' { + interface Register { + config: Config + } +} +// ---cut--- +import { useBlockNumber } from '@wagmi/vue' + +useBlockNumber({ chainId: 123 }) +``` + +You just saved yourself a runtime error and you didn't even need to pass your `config`. 🎉 + +### Hook `config` Property + +For cases where you have more than one Wagmi `config` or don't want to use the declaration merging approach, you can pass a specific `config` directly to composables via the `config` property. + +```ts +import { createConfig, http } from '@wagmi/vue' +import { mainnet, optimism } from '@wagmi/vue/chains' + +export const configA = createConfig({ // [!code focus] + chains: [mainnet], // [!code focus] + transports: { // [!code focus] + [mainnet.id]: http(), // [!code focus] + }, // [!code focus] +}) // [!code focus] + +export const configB = createConfig({ // [!code focus] + chains: [optimism], // [!code focus] + transports: { // [!code focus] + [optimism.id]: http(), // [!code focus] + }, // [!code focus] +}) // [!code focus] +``` + +As you expect, `chainId` is inferred correctly for each `config`. + +```ts twoslash +// @errors: 2322 +import { type Config } from '@wagmi/vue' +import { mainnet, optimism } from '@wagmi/vue/chains' + +declare const configA: Config +declare const configB: Config +// ---cut--- +import { useBlockNumber } from '@wagmi/vue' + +useBlockNumber({ chainId: 123, config: configA }) +useBlockNumber({ chainId: 123, config: configB }) +``` + +This approach is more explicit, but works well for advanced use-cases, if you don't want to use a Vue Plugin or declaration merging, etc. + +## Const-Assert ABIs & Typed Data + +Wagmi can infer types based on [ABIs](https://docs.soliditylang.org/en/latest/abi-spec.html#json) and [EIP-712](https://eips.ethereum.org/EIPS/eip-712) Typed Data definitions, powered by [Viem](https://viem.sh) and [ABIType](https://github.com/wevm/abitype). This achieves full end-to-end type-safety from your contracts to your frontend and enlightened developer experience by autocompleting ABI item names, catching misspellings, inferring argument and return types (including overloads), and more. + +For this to work, you must either [const-assert](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-4.html#const-assertions) ABIs and Typed Data (more info below) or define them inline. For example, `useReadContract`'s `abi` configuration parameter: + +```ts +const { data } = useReadContract({ + abi: […], // <--- defined inline // [!code focus] +}) +``` + +```ts +const abi = […] as const // <--- const assertion // [!code focus] +const { data } = useReadContract({ abi }) +``` + +If type inference isn't working, it's likely you forgot to add a `const` assertion or define the configuration parameter inline. Also, make sure your ABIs, Typed Data definitions, and [TypeScript configuration](#requirements) are valid and set up correctly. + +::: tip +Unfortunately [TypeScript doesn't support importing JSON `as const` yet](https://github.com/microsoft/TypeScript/issues/32063). Check out the [Wagmi CLI](/cli/getting-started) to help with this! It can automatically fetch ABIs from Etherscan and other block explorers, resolve ABIs from your Foundry/Hardhat projects, generate Vue Composables, and more. +::: + +Anywhere you see the `abi` or `types` configuration property, you can likely use const-asserted or inline ABIs and Typed Data to get type-safety and inference. These properties are also called out in the docs. + +Here's what [`useReadContract`](/vue/api/composables/useReadContract) looks like with and without a const-asserted `abi` property. + +::: code-group +```ts twoslash [Const-Asserted] +const erc721Abi = [ + { + name: 'balanceOf', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'address', name: 'owner' }], + outputs: [{ type: 'uint256' }], + }, + { + name: 'isApprovedForAll', + type: 'function', + stateMutability: 'view', + inputs: [ + { type: 'address', name: 'owner' }, + { type: 'address', name: 'operator' }, + ], + outputs: [{ type: 'bool' }], + }, + { + name: 'getApproved', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'address' }], + }, + { + name: 'ownerOf', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'address' }], + }, + { + name: 'tokenURI', + type: 'function', + stateMutability: 'pure', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'string' }], + }, +] as const +// ---cut--- +import { useReadContract } from '@wagmi/vue' + +const { data } = useReadContract({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: erc721Abi, + functionName: 'balanceOf', + // ^? + + + + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e'], + // ^? +}) + +data +// ^? +``` +```ts twoslash [Not Const-Asserted] +declare const erc721Abi: { + name: string; + type: string; + stateMutability: string; + inputs: { + type: string; + name: string; + }[]; + outputs: { + type: string; + }[]; +}[] +// ---cut--- +import { useReadContract } from '@wagmi/vue' + +const { data } = useReadContract({ + address: '0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2', + abi: erc721Abi, + functionName: 'balanceOf', + // ^? + + + + args: ['0xA0Cf798816D4b9b9866b5330EEa46a18382f251e'], + // ^? +}) + +data +// ^? +``` +::: + +
+
+ +You can prevent runtime errors and be more productive by making sure your ABIs and Typed Data definitions are set up appropriately. 🎉 + +```ts twoslash +// @errors: 2820 +const erc721Abi = [ + { + name: 'balanceOf', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'address', name: 'owner' }], + outputs: [{ type: 'uint256' }], + }, + { + name: 'isApprovedForAll', + type: 'function', + stateMutability: 'view', + inputs: [ + { type: 'address', name: 'owner' }, + { type: 'address', name: 'operator' }, + ], + outputs: [{ type: 'bool' }], + }, + { + name: 'getApproved', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'address' }], + }, + { + name: 'ownerOf', + type: 'function', + stateMutability: 'view', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'address' }], + }, + { + name: 'tokenURI', + type: 'function', + stateMutability: 'pure', + inputs: [{ type: 'uint256', name: 'tokenId' }], + outputs: [{ type: 'string' }], + }, +] as const +// ---cut--- +import { useReadContract } from '@wagmi/vue' + +useReadContract({ + abi: erc721Abi, + functionName: 'balanecOf', +}) +``` + +## Configure Internal Types + +For advanced use-cases, you may want to configure Wagmi's internal types. Most of Wagmi's types relating to ABIs and EIP-712 Typed Data are powered by [ABIType](https://github.com/wevm/abitype). See the [ABIType docs](https://abitype.dev) for more info on how to configure types. diff --git a/site/vue/why.md b/site/vue/why.md new file mode 100644 index 0000000000..4a3560c13f --- /dev/null +++ b/site/vue/why.md @@ -0,0 +1,46 @@ +# Why Wagmi + +## The Problems + +Building Ethereum applications is hard. Apps need to support connecting wallets, multiple chains, signing messages and data, sending transactions, listening for events and state changes, refreshing stale blockchain data, and much more. This is all on top of solving for app-specific use-cases and providing polished user experiences. + +The ecosystem is also continuously evolving, meaning you need to adapt to new improvements or get left behind. App developers should not need to worry about connecting tens of different wallets, the intricacies of multi-chain support, typos accidentally sending an order of magnitude more ETH or calling a misspelled contract function, or accidentally spamming their RPC provider, costing thousands in compute units. + +Wagmi solves all these problems and more — allowing app developers to focus on building high-quality and performant experiences for Ethereum — by focusing on **developer experience**, **performance**, **feature coverage**, and **stability.** + +## Developer Experience + +Wagmi delivers a great developer experience through modular and composable APIs, automatic type safety and inference, and comprehensive documentation. + +It provides developers with intuitive building blocks to build their Ethereum apps. While Wagmi's APIs might seem more verbose at first, it makes Wagmi's modular building blocks extremely flexible. Easy to move around, change, and remove. It also allows developers to better understand Ethereum concepts as well as understand _what_ and _why_ certain properties are being passed through. Learning how to use Wagmi is a great way to learn how to interact with Ethereum in general. + +Wagmi also provides [strongly typed APIs](/vue/typescript), allowing consumers to get the best possible experience through [autocomplete](https://twitter.com/awkweb/status/1555678944770367493), [type inference](https://twitter.com/jakemoxey/status/1570244174502588417?s=20), as well as static validation. You often just need to provide an ABI and Wagmi can help you autocomplete your way to success, identify type errors before your users do, drill into blockchain errors [at compile and runtimes](/vue/guides/error-handling) with surgical precision, and much more. + +The API documentation is comprehensive and contains usage info for _every_ module in Wagmi. The core team uses a [documentation](https://gist.github.com/zsup/9434452) and [test driven](https://en.wikipedia.org/wiki/Test-driven_development#:~:text=Test%2Ddriven%20development%20(TDD),software%20against%20all%20test%20cases.) development approach to building modules, which leads to predictable and stable APIs. + +## Performance + +Performance is critical for applications on all sizes. Slow page load and interactions can cause users to stop using applications. Wagmi uses and is built by the same team behind [Viem](https://viem.sh), the most performant production-ready Ethereum library. + +End users should not be required to download a module of over 100kB in order to interact with Ethereum. Wagmi is optimized for tree-shaking and dead-code elimination, allowing apps to minimize bundle size for fast page load times. + +Data layer performance is also critical. Slow, unnecessary, and manual data fetching can make apps unusable and cost thousands in RPC compute units. Wagmi supports caching, deduplication, persistence, and much more through [TanStack Query](/vue/guides/tanstack-query). + +## Feature Coverage + +Wagmi supports the most popular and commonly-used Ethereum features out of the box with 40+ Vue Composables for accounts, wallets, contracts, transactions, signing, ENS, and more. Wagmi also supports just about any wallet out there through it's official [connectors](/vue/api/connectors), [EIP-6963 support](/vue/api/createConfig#multiinjectedproviderdiscovery), and [extensible API](/dev/creating-connectors). + +If you need lower-level control, you can always drop down to [Wagmi Core](/core/getting-started) or [Viem](https://viem.sh), which Wagmi uses internally to perform blockchain operations. Wagmi also manages multi-chain support automatically so developers can focus on their applications instead of adding custom code. + +Finally, Wagmi has a [CLI](/cli/getting-started) to manage ABIs as well as a robust ecosystem of third-party libraries, like [ConnectKit](https://docs.family.co/connectkit), [RainbowKit](https://www.rainbowkit.com), [AppKit](https://walletconnect.com/appkit), [Dynamic](https://www.dynamic.xyz), [Privy](https://privy.io), and many more, so you can get started quickly without needing to build everything from scratch. + +## Stability + +Stability is a fundamental principle for Wagmi. Many organizations, large and small, rely heavily on Wagmi and expect it to be entirely stable for their users and applications. + +Wagmi's test suite runs against forked Ethereum nodes to make sure functions work across chains. The test suite also runs type tests against many different versions of peer dependencies, like TypeScript, to ensure compatibility with the latest releases of other popular software. + +Wagmi follows semver so developers can upgrade between versions with confidence. Starting with Wagmi v2, new functionality will be opt-in with old functionality being deprecated alongside the new features. This means upgrading to the latest major versions will not require immediate changes. + +Lastly, the core team works full-time on Wagmi and [related projects](https://github.com/wevm), and is constantly improving Wagmi and keeping it up-to-date with industry trends and changes. + diff --git a/src/App.tsx b/src/App.tsx new file mode 100644 index 0000000000..9f245fc45f --- /dev/null +++ b/src/App.tsx @@ -0,0 +1,1362 @@ +import { AnimatePresence } from 'framer-motion' +import React, { useState, useEffect, useMemo, SetStateAction } from 'react' +import { ethers } from 'ethers' +import { sequence } from '0xsequence' +import { walletContracts } from '@0xsequence/abi' +import { + Box, + Image, + Text, + Button, + ExternalLinkIcon, + Divider, + Card, + TransactionIcon, + Select, + TokenImage, + TextInput, + Modal +} from '@0xsequence/design-system' +import { ETHAuth } from '@0xsequence/ethauth' +import { configureLogger } from '@0xsequence/utils' +import { ConnectOptions, OpenWalletIntent, Settings } from '@0xsequence/provider' +import { ChainId, NetworkType } from '@0xsequence/network' + +import { ERC_20_ABI } from './constants/abi' +import { Console } from './components/Console' +import { Group } from './components/Group' +import { getDefaultChainId, toHexString } from './helpers' +import logoUrl from './images/logo.svg' +import skyweaverBannerUrl from './images/skyweaver-banner.png' +import skyweaverBannerLargeUrl from './images/skyweaver-banner-large.png' + +configureLogger({ logLevel: 'DEBUG' }) + +interface Environment { + name: string + walletUrl: string + projectAccessKey: string +} + +const environments: Environment[] = [ + { + name: 'production', + walletUrl: 'https://sequence.app', + projectAccessKey: 'AQAAAAAAAAbvrgpWEC2Aefg5qYStQmwjBpA' + }, + { + name: 'development', + walletUrl: 'https://dev.sequence.app', + //projectAccessKey: 'AQAAAAAAAAVBNfoB30kz7Ph4I_Qs5mkYuDc', + projectAccessKey: 'AQAAAAAAAAVCXiQ9f_57R44MjorZ4SmGdhA' + }, + { + name: 'local', + walletUrl: 'http://localhost:3333', + projectAccessKey: 'AQAAAAAAAAVCXiQ9f_57R44MjorZ4SmGdhA' + }, + { + name: 'custom', + walletUrl: '', + projectAccessKey: '' + } +] + +const DEFAULT_API_URL = 'https://api.sequence.app' + +// Specify your desired default chain id. NOTE: you can communicate to multiple +// chains at the same time without even having to switch the network, but a default +// chain is required. +const defaultChainId = getDefaultChainId() || ChainId.MAINNET +// const defaultChainId = ChainId.POLYGON +// const defaultChainId = ChainId.GOERLI +// const defaultChainId = ChainId.ARBITRUM +// const defaultChainId = ChainId.AVALANCHE +// etc.. see the full list here: https://docs.sequence.xyz/multi-chain-support + +// For Sequence core dev team -- app developers can ignore +// a custom wallet app url can specified in the query string +const urlParams = new URLSearchParams(window.location.search) + +const env = urlParams.get('env') ?? 'production' +const envConfig = environments.find(x => x.name === env) ?? environments.find(x => x.name === 'production') +if (!envConfig) { + throw new Error('Invalid environment configuration.') +} +const walletAppURL = urlParams.get('walletAppURL') ?? envConfig.walletUrl +const projectAccessKey = urlParams.get('projectAccessKey') ?? envConfig.projectAccessKey +const showProhibitedActions = urlParams.has('showProhibitedActions') + +const isCustom = walletAppURL !== envConfig.walletUrl || projectAccessKey !== envConfig.projectAccessKey + +if (walletAppURL && walletAppURL.length > 0) { + // Wallet can point to a custom wallet app url + // NOTICE: this is not needed, unless testing an alpha version of the wallet + sequence.initWallet(projectAccessKey, { defaultNetwork: defaultChainId, transports: { walletAppURL } }) +} else { + // Init the sequence wallet library at the top-level of your project with + // your designed default chain id + sequence.initWallet(projectAccessKey, { defaultNetwork: defaultChainId, transports: { walletAppURL } }) +} + +// App component +const App = () => { + const [consoleMsg, setConsoleMsg] = useState(null) + const [email, setEmail] = useState(null) + const [consoleLoading, setConsoleLoading] = useState(false) + const [isWalletConnected, setIsWalletConnected] = useState(false) + + const wallet = sequence.getWallet().getProvider() + + const [showChainId, setShowChainId] = useState(wallet.getChainId()) + const [isOpen, toggleModal] = useState(false) + const [warning, setWarning] = useState(false) + + useEffect(() => { + const handleChainChanged = (chainId: string) => { + setShowChainId(Number(BigInt(chainId))) + } + wallet.on('chainChanged', handleChainChanged) + return () => { + wallet.off('chainChanged', handleChainChanged) + } + }, [wallet]) + + useEffect(() => { + setIsWalletConnected(wallet.isConnected()) + }, [wallet]) + + useEffect(() => { + consoleWelcomeMessage() + // eslint-disable-next-line + }, [isWalletConnected]) + + useEffect(() => { + // Wallet events + const onOpen = () => { + console.log('wallet window opened') + } + wallet.client.on('open', onOpen) + + const onClose = () => { + console.log('wallet window closed') + } + wallet.client.on('close', onClose) + + return () => { + wallet.client.off('open', onOpen) + wallet.client.off('close', onClose) + } + }, [wallet]) + + const defaultConnectOptions: ConnectOptions = { + app: 'Demo Dapp', + askForEmail: true + // keepWalletOpened: true, + } + + // Methods + const connect = async (connectOptions: ConnectOptions = { app: 'Demo dapp' }) => { + if (isWalletConnected) { + resetConsole() + appendConsoleLine('Wallet already connected!') + setConsoleLoading(false) + return + } + + connectOptions = { + ...defaultConnectOptions, + ...connectOptions, + settings: { + ...defaultConnectOptions.settings, + ...connectOptions.settings + } + } + + try { + resetConsole() + appendConsoleLine('Connecting') + const wallet = sequence.getWallet() + + const connectDetails = await wallet.connect(connectOptions) + + // Example of how to verify using ETHAuth via Sequence API + if (connectOptions.authorize && connectDetails.connected && connectDetails.proof) { + let apiUrl = urlParams.get('apiUrl') + + if (!apiUrl || apiUrl.length === 0) { + apiUrl = DEFAULT_API_URL + } + + const api = new sequence.api.SequenceAPIClient(apiUrl) + // or just + // const api = new sequence.api.SequenceAPIClient('https://api.sequence.app') + + const { isValid } = await api.isValidETHAuthProof({ + chainId: connectDetails.chainId, + walletAddress: connectDetails.session.accountAddress, + ethAuthProofString: connectDetails.proof.proofString + }) + + appendConsoleLine(`isValid (API)?: ${isValid}`) + } + + // Example of how to verify using ETHAuth directl on the client + if (connectOptions.authorize) { + const ethAuth = new ETHAuth() + + if (connectDetails.proof) { + const decodedProof = await ethAuth.decodeProof(connectDetails.proof.proofString, true) + + const isValid = await wallet.utils.isValidTypedDataSignature( + wallet.getAddress(), + connectDetails.proof.typedData, + decodedProof.signature, + Number(BigInt(connectDetails.chainId)) + ) + + appendConsoleLine(`connected using chainId: ${BigInt(connectDetails.chainId).toString()}`) + appendConsoleLine(`isValid (client)?: ${isValid}`) + } + } + + setConsoleLoading(false) + if (connectDetails.connected) { + appendConsoleLine('Wallet connected!') + appendConsoleLine(`shared email: ${connectDetails.email}`) + setIsWalletConnected(true) + } else { + appendConsoleLine('Failed to connect wallet - ' + connectDetails.error) + } + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const disconnect = () => { + const wallet = sequence.getWallet() + wallet.disconnect() + consoleWelcomeMessage() + setIsWalletConnected(false) + } + + const openWallet = () => { + const wallet = sequence.getWallet() + wallet.openWallet() + } + + const openWalletWithSettings = () => { + const wallet = sequence.getWallet() + + const settings: Settings = { + theme: 'light', + includedPaymentProviders: ['moonpay', 'ramp'], + defaultFundingCurrency: 'eth', + defaultPurchaseAmount: 400, + lockFundingCurrencyToDefault: false + } + + const intent: OpenWalletIntent = { + type: 'openWithOptions', + options: { + app: 'Demo Dapp', + settings + } + } + + const path = 'wallet/add-funds' + wallet.openWallet(path, intent) + } + + const closeWallet = () => { + const wallet = sequence.getWallet() + wallet.closeWallet() + } + + const isConnected = async () => { + resetConsole() + const wallet = sequence.getWallet() + appendConsoleLine(`isConnected?: ${wallet.isConnected()}`) + setConsoleLoading(false) + } + + const isOpened = async () => { + resetConsole() + const wallet = sequence.getWallet() + appendConsoleLine(`isOpened?: ${wallet.isOpened()}`) + setConsoleLoading(false) + } + + const getChainID = async () => { + try { + resetConsole() + + const topChainId = wallet.getChainId() + appendConsoleLine(`top chainId: ${topChainId}`) + + const provider = wallet.getProvider() + const providerChainId = provider!.getChainId() + appendConsoleLine(`provider.getChainId(): ${providerChainId}`) + + const signer = wallet.getSigner() + const signerChainId = await signer.getChainId() + appendConsoleLine(`signer.getChainId(): ${signerChainId}`) + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const getAccounts = async () => { + try { + resetConsole() + + const wallet = sequence.getWallet() + const address = wallet.getAddress() + appendConsoleLine(`getAddress(): ${address}`) + + const provider = wallet.getProvider() + const accountList = provider.listAccounts() + appendConsoleLine(`accounts: ${JSON.stringify(accountList)}`) + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const getBalance = async () => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + const provider = wallet.getProvider() + const account = wallet.getAddress() + const balanceChk1 = await provider!.getBalance(account) + appendConsoleLine(`balance check 1: ${balanceChk1.toString()}`) + + const signer = wallet.getSigner() + const balanceChk2 = await signer.getBalance() + appendConsoleLine(`balance check 2: ${balanceChk2.toString()}`) + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const getNetworks = async () => { + try { + resetConsole() + + const wallet = sequence.getWallet() + const networks = await wallet.getNetworks() + + appendConsoleLine(`networks: ${JSON.stringify(networks, null, 2)}`) + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const signMessageString = async () => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + appendConsoleLine('signing message...') + const signer = wallet.getSigner() + + const message = `1915 Robert Frost +The Road Not Taken + +Two roads diverged in a yellow wood, +And sorry I could not travel both +And be one traveler, long I stood +And looked down one as far as I could +To where it bent in the undergrowth + +Then took the other, as just as fair, +And having perhaps the better claim, +Because it was grassy and wanted wear +Though as for that the passing there +Had worn them really about the same, + +And both that morning equally lay +In leaves no step had trodden black. +Oh, I kept the first for another day! +Yet knowing how way leads on to way, +I doubted if I should ever come back. + +I shall be telling this with a sigh +Somewhere ages and ages hence: +Two roads diverged in a wood, and I— +I took the one less traveled by, +And that has made all the difference. + +\u2601 \u2600 \u2602` + + // sign + const sig = await signer.signMessage(message) + appendConsoleLine(`signature: ${sig}`) + + const isValid = await wallet.utils.isValidMessageSignature(wallet.getAddress(), message, sig, await signer.getChainId()) + appendConsoleLine(`isValid?: ${isValid}`) + if (!isValid) throw new Error('sig invalid') + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const signMessageHex = async () => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + appendConsoleLine('signing message...') + const signer = wallet.getSigner() + + // Message in hex + const message = ethers.hexlify(ethers.toUtf8Bytes('Hello, world!')) + + // sign + const sig = await signer.signMessage(message) + appendConsoleLine(`signature: ${sig}`) + + const isValid = await wallet.utils.isValidMessageSignature(wallet.getAddress(), message, sig, await signer.getChainId()) + appendConsoleLine(`isValid?: ${isValid}`) + if (!isValid) throw new Error('sig invalid') + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const signMessageBytes = async () => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + appendConsoleLine('signing message...') + const signer = wallet.getSigner() + + // Message in hex + const message = ethers.toUtf8Bytes('Hello, world!') + + // sign + const sig = await signer.signMessage(message) + appendConsoleLine(`signature: ${sig}`) + + const isValid = await wallet.utils.isValidMessageSignature(wallet.getAddress(), message, sig, await signer.getChainId()) + appendConsoleLine(`isValid?: ${isValid}`) + if (!isValid) throw new Error('sig invalid') + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const signTypedData = async () => { + try { + resetConsole() + const wallet = sequence.getWallet() + + appendConsoleLine('signing typedData...') + + const typedData: sequence.utils.TypedData = { + types: { + Person: [ + { name: 'name', type: 'string' }, + { name: 'wallet', type: 'address' } + ], + Mail: [ + { name: 'from', type: 'Person' }, + { name: 'to', type: 'Person' }, + { name: 'cc', type: 'Person[]' }, + { name: 'contents', type: 'string' }, + { name: 'attachements', type: 'string[]' } + ] + }, + primaryType: 'Mail', + domain: { + name: 'Ether Mail', + version: '1', + chainId: 1, + verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC' + }, + message: { + from: { + name: 'Cow', + wallet: '0xCD2a3d9F938E13CD947Ec05AbC7FE734Df8DD826' + }, + to: { + name: 'Bob', + wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB' + }, + cc: [ + { name: 'Dev Team', wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB' }, + { name: 'Accounting', wallet: '0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB' } + ], + contents: 'Hello, Bob!', + attachements: ['cat.png', 'dog.png'] + } + } + + const signer = wallet.getSigner() + + const sig = await signer.signTypedData(typedData.domain, typedData.types, typedData.message) + appendConsoleLine(`signature: ${sig}`) + + // validate + const isValid = await wallet.utils.isValidTypedDataSignature(wallet.getAddress(), typedData, sig, await signer.getChainId()) + appendConsoleLine(`isValid?: ${isValid}`) + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const estimateUnwrapGas = async () => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + const wmaticContractAddress = '0x0d500B1d8E8eF31E21C99d1Db9A6444d3ADf1270' + const wmaticInterface = new ethers.Interface(['function withdraw(uint256 amount)']) + + const tx: sequence.transactions.Transaction = { + to: wmaticContractAddress, + data: wmaticInterface.encodeFunctionData('withdraw', ['1000000000000000000']) + } + + const provider = wallet.getProvider() + const estimate = await provider.estimateGas(tx) + + appendConsoleLine(`estimated gas needed for wmatic withdrawal : ${estimate.toString()}`) + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const sendETH = async (signer?: sequence.provider.SequenceSigner) => { + try { + resetConsole() + const wallet = sequence.getWallet() + + signer = signer || wallet.getSigner() + + appendConsoleLine(`Transfer txn on ${signer.getChainId()} chainId`) + + // NOTE: on mainnet, the balance will be of ETH value + // and on matic, the balance will be of MATIC value + + // Sending the funds to the wallet itself + // so we don't lose any funds ;-) + // (of course, you can send anywhere) + const toAddress = await signer.getAddress() + + const tx1: sequence.transactions.Transaction = { + delegateCall: false, + revertOnError: false, + gasLimit: '0x55555', + to: toAddress, + value: ethers.parseEther('1.234'), + data: '0x' + } + + const tx2: sequence.transactions.Transaction = { + delegateCall: false, + revertOnError: false, + gasLimit: '0x55555', + to: toAddress, + value: ethers.parseEther('0.4242'), + data: '0x' + } + + const provider = signer.provider + + const balance1 = await provider.getBalance(toAddress) + appendConsoleLine(`balance of ${toAddress}, before: ${balance1}`) + + const txnResp = await signer.sendTransaction([tx1, tx2]) + appendConsoleLine(`txnResponse: ${JSON.stringify(txnResp)}`) + + const balance2 = await provider.getBalance(toAddress) + appendConsoleLine(`balance of ${toAddress}, after: ${balance2}`) + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const sendSepoliaUSDC = async (signer?: sequence.provider.SequenceSigner) => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + signer = signer || wallet.getSigner() // select DefaultChain signer by default + + // Sending the funds to the wallet itself + // so we don't lose any funds ;-) + // (of course, you can send anywhere) + const toAddress = await signer.getAddress() + + const amount = ethers.parseUnits('1', 1) + + // (USDC address on Sepolia) + const usdcAddress = '0x07865c6e87b9f70255377e024ace6630c1eaa37f' + + const tx: sequence.transactions.Transaction = { + delegateCall: false, + revertOnError: false, + gasLimit: '0x55555', + to: usdcAddress, + value: 0, + data: new ethers.Interface(ERC_20_ABI).encodeFunctionData('transfer', [toAddress, toHexString(amount)]) + } + + const txnResp = await signer.sendTransaction([tx], { chainId: ChainId.SEPOLIA }) + appendConsoleLine(`txnResponse: ${JSON.stringify(txnResp)}`) + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const sendDAI = async (signer?: sequence.provider.SequenceSigner) => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + signer = signer || wallet.getSigner() // select DefaultChain signer by default + + // Sending the funds to the wallet itself + // so we don't lose any funds ;-) + // (of course, you can send anywhere) + const toAddress = await signer.getAddress() + + const amount = ethers.parseUnits('0.05', 18) + const daiContractAddress = '0x8f3Cf7ad23Cd3CaDbD9735AFf958023239c6A063' // (DAI address on Polygon) + + const tx: sequence.transactions.Transaction = { + delegateCall: false, + revertOnError: false, + gasLimit: '0x55555', + to: daiContractAddress, + value: 0, + data: new ethers.Interface(ERC_20_ABI).encodeFunctionData('transfer', [toAddress, toHexString(amount)]) + } + + const txnResp = await signer.sendTransaction([tx]) + appendConsoleLine(`txnResponse: ${JSON.stringify(txnResp)}`) + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const sendETHSidechain = async () => { + try { + const wallet = sequence.getWallet() + + // Send either to Arbitrum or Optimism + // just pick one that is not the current chainId + const pick = wallet.getChainId() === ChainId.ARBITRUM ? ChainId.OPTIMISM : ChainId.ARBITRUM + sendETH(wallet.getSigner(pick)) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const send1155Tokens = async () => { + try { + resetConsole() + appendConsoleLine('TODO') + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const contractExample = async (signer?: sequence.provider.SequenceSigner) => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + signer = signer || wallet.getSigner() + + const abi = [ + 'function balanceOf(address owner) view returns (uint256)', + 'function decimals() view returns (uint8)', + 'function symbol() view returns (string)', + 'function transfer(address to, uint amount) returns (bool)', + 'event Transfer(address indexed from, address indexed to, uint amount)' + ] + + // USD Coin (PoS) on Polygon + const address = '0x2791bca1f2de4661ed88a30c99a7a9449aa84174' + + const usdc = new ethers.Contract(address, abi) + + const usdSymbol = await usdc.symbol() + appendConsoleLine(`Token symbol: ${usdSymbol}`) + + const balance = await usdc.balanceOf(await signer.getAddress()) + appendConsoleLine(`Token Balance: ${balance.toString()}`) + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const fetchTokenBalances = async () => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + const signer = wallet.getSigner() + const accountAddress = await signer.getAddress() + const networks = await wallet.getNetworks() + const network = networks.find(network => network.chainId === ChainId.POLYGON) + + if (!network) { + throw new Error(`Could not find Polygon network in networks list`) + } + + const indexer = new sequence.indexer.SequenceIndexer(network.indexerUrl) + + const tokenBalances = await indexer.getTokenBalances({ + accountAddress: accountAddress, + includeMetadata: true + }) + + appendConsoleLine(`tokens in your account: ${JSON.stringify(tokenBalances)}`) + + // NOTE: you can put any NFT/collectible address in the `contractAddress` field and it will return all of the balances + metadata. + // We use the Skyweaver production contract address here for demo purposes, but try another one :) + const skyweaverCollectibles = await indexer.getTokenBalances({ + accountAddress: accountAddress, + includeMetadata: true, + contractAddress: '0x631998e91476DA5B870D741192fc5Cbc55F5a52E' + }) + appendConsoleLine(`skyweaver collectibles in your account: ${JSON.stringify(skyweaverCollectibles)}`) + + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const updateImplementation = async (signer?: sequence.provider.SequenceSigner) => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + signer = signer || wallet.getSigner() // select DefaultChain signer by default + + const transaction: sequence.transactions.Transaction = { + to: wallet.getAddress(), + data: new ethers.Interface(walletContracts.mainModule.abi).encodeFunctionData('updateImplementation', [ + ethers.ZeroAddress + ]) + } + + const response = await signer.sendTransaction(transaction) + appendConsoleLine(`response: ${JSON.stringify(response)}`) + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const updateImageHash = async (signer?: sequence.provider.SequenceSigner) => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + signer = signer || wallet.getSigner() // select DefaultChain signer by default + + const transaction: sequence.transactions.Transaction = { + to: wallet.getAddress(), + data: new ethers.Interface(walletContracts.mainModuleUpgradable.abi).encodeFunctionData('updateImageHash', [ + ethers.ZeroHash + ]) + } + + const response = await signer.sendTransaction(transaction) + appendConsoleLine(`response: ${JSON.stringify(response)}`) + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const delegateCall = async (signer?: sequence.provider.SequenceSigner) => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + signer = signer || wallet.getSigner() // select DefaultChain signer by default + + const transaction: sequence.transactions.Transaction = { + to: wallet.getAddress(), + delegateCall: true + } + + const response = await signer.sendTransaction(transaction) + appendConsoleLine(`response: ${JSON.stringify(response)}`) + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const addHook = async (signer?: sequence.provider.SequenceSigner) => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + signer = signer || wallet.getSigner() // select DefaultChain signer by default + + const transaction: sequence.transactions.Transaction = { + to: wallet.getAddress(), + data: new ethers.Interface(['function addHook(bytes4 _signature, address _implementation)']).encodeFunctionData( + 'addHook', + ['0x01234567', ethers.ZeroAddress] + ) + } + + const response = await signer.sendTransaction(transaction) + appendConsoleLine(`response: ${JSON.stringify(response)}`) + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const setExtraImageHash = async (signer?: sequence.provider.SequenceSigner) => { + try { + resetConsole() + + const wallet = sequence.getWallet() + + signer = signer || wallet.getSigner() // select DefaultChain signer by default + + const transaction: sequence.transactions.Transaction = { + to: wallet.getAddress(), + data: new ethers.Interface(['function setExtraImageHash(bytes32 _imageHash, uint256 _expiration)']).encodeFunctionData( + 'setExtraImageHash', + [ethers.ZeroHash, ethers.MaxUint256] + ) + } + + const response = await signer.sendTransaction(transaction) + appendConsoleLine(`response: ${JSON.stringify(response)}`) + setConsoleLoading(false) + } catch (e) { + console.error(e) + consoleErrorMessage() + } + } + + const appendConsoleLine = (message: string, clear = false) => { + console.log(message) + + if (clear) { + return setConsoleMsg(message) + } + + return setConsoleMsg(prevState => { + return `${prevState}\n\n${message}` + }) + } + + const resetConsole = () => { + setConsoleLoading(true) + } + + const consoleWelcomeMessage = () => { + setConsoleLoading(false) + + if (isWalletConnected) { + setConsoleMsg('Status: Wallet is connected :)') + } else { + setConsoleMsg('Status: Wallet not connected. Please connect wallet first.') + } + } + + const consoleErrorMessage = () => { + setConsoleLoading(false) + setConsoleMsg('An error occurred') + } + + // networks list, filtered and sorted + const omitNetworks = [ + ChainId.RINKEBY, + ChainId.HARDHAT, + ChainId.HARDHAT_2, + ChainId.KOVAN, + ChainId.ROPSTEN, + ChainId.HOMEVERSE_TESTNET, + ChainId.BASE_GOERLI + ] + + const mainnets = Object.values(sequence.network.networks) + .filter(network => network.type === NetworkType.MAINNET) + .sort((a, b) => a.chainId - b.chainId) + const testnets = Object.values(sequence.network.networks) + .filter(network => network.type === NetworkType.TESTNET) + .sort((a, b) => a.chainId - b.chainId) + const networks = [...mainnets, ...testnets].filter(network => !network.deprecated && !omitNetworks.includes(network.chainId)) + + useEffect(() => { + if (email && !isOpen) { + console.log(email) + connect({ + app: 'Demo Dapp', + authorize: true, + settings: { + // Specify signInWithEmail with an email address to allow user automatically sign in with the email option. + signInWithEmail: email, + theme: 'dark', + bannerUrl: `${window.location.origin}${skyweaverBannerUrl}` + } + }) + setEmail(null) + } + }, [email, isOpen]) + + const sanitizeEmail = (email: string) => { + // Trim unnecessary spaces + email = email.trim() + + // Check if the email matches the pattern of a typical email + const emailRegex = /^[a-zA-Z0-9._-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,6}$/ + if (emailRegex.test(email)) { + return true + } + + return false + } + + return ( + + + + logo + + + + + + Demo Dapp + + + + + + A dapp example on how to use the Sequence Wallet. This covers how to connect, sign messages and send transctions. + + + + + + + Please open your browser dev inspector to view output of functions below. + + + + + + {!isCustom && ( + + wallet.setDefaultChainId(Number(value))} + value={String(showChainId)} + options={[ + ...Object.values(networks).map(network => ({ + label: ( + + + {network.title!} + + ), + value: String(network.chainId) + })) + ]} + /> + + + +